@luigi-project/core-modular 0.0.7 → 0.0.8

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/luigi.js CHANGED
@@ -1,41 +1,81 @@
1
- class $v{constructor(n){this.$subscribers=new Set,this.$value=n}set(n){this.$value=n,this.$subscribers.forEach(r=>{r(n)})}update(n){this.set(n(this.$value))}subscribe(n){return this.$subscribers.add(n),n(this.$value),()=>{this.$subscribers.delete(n)}}}function ac(i){return i.$value}function ns(i){return new $v(i)}var Ki=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},Br={exports:{}};var Dv=Br.exports,Ml;function Mv(){return Ml||(Ml=1,(function(i,n){(function(){var r,a="4.18.1",u=200,c="Unsupported core-js use. Try https://npms.io/search?q=ponyfill.",l="Expected a function",d="Invalid `variable` option passed into `_.template`",p="Invalid `imports` option passed into `_.template`",_="__lodash_hash_undefined__",R=500,T="__lodash_placeholder__",E=1,C=2,A=4,N=1,H=2,W=1,ie=2,Oe=4,Ie=8,Qe=16,xe=32,Je=64,ye=128,Re=256,ve=512,be=30,$="...",Zt=800,wt=16,$e=1,En=2,L=3,ot=1/0,oe=9007199254740991,ke=17976931348623157e292,Jt=NaN,Lt=4294967295,Kc=Lt-1,Yc=Lt>>>1,Xc=[["ary",ye],["bind",W],["bindKey",ie],["curry",Ie],["curryRight",Qe],["flip",ve],["partial",xe],["partialRight",Je],["rearg",Re]],Vn="[object Arguments]",ri="[object Array]",Zc="[object AsyncFunction]",Er="[object Boolean]",Cr="[object Date]",Jc="[object DOMException]",ii="[object Error]",si="[object Function]",ro="[object GeneratorFunction]",St="[object Map]",Tr="[object Number]",jc="[object Null]",kt="[object Object]",io="[object Promise]",eh="[object Proxy]",yr="[object RegExp]",Et="[object Set]",Rr="[object String]",ai="[object Symbol]",th="[object Undefined]",br="[object WeakMap]",nh="[object WeakSet]",Ar="[object ArrayBuffer]",Bn="[object DataView]",cs="[object Float32Array]",hs="[object Float64Array]",fs="[object Int8Array]",ds="[object Int16Array]",gs="[object Int32Array]",ps="[object Uint8Array]",_s="[object Uint8ClampedArray]",ms="[object Uint16Array]",vs="[object Uint32Array]",rh=/\b__p \+= '';/g,ih=/\b(__p \+=) '' \+/g,sh=/(__e\(.*?\)|\b__t\)) \+\n'';/g,so=/&(?:amp|lt|gt|quot|#39);/g,ao=/[&<>"']/g,ah=RegExp(so.source),oh=RegExp(ao.source),uh=/<%-([\s\S]+?)%>/g,lh=/<%([\s\S]+?)%>/g,oo=/<%=([\s\S]+?)%>/g,ch=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,hh=/^\w*$/,fh=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,ws=/[\\^$.*+?()[\]{}|]/g,dh=RegExp(ws.source),Ss=/^\s+/,gh=/\s/,ph=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,_h=/\{\n\/\* \[wrapped with (.+)\] \*/,mh=/,? & /,vh=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,uo=/[()=,{}\[\]\/\s]/,wh=/\\(\\)?/g,Sh=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,lo=/\w*$/,Eh=/^[-+]0x[0-9a-f]+$/i,Ch=/^0b[01]+$/i,Th=/^\[object .+?Constructor\]$/,yh=/^0o[0-7]+$/i,Rh=/^(?:0|[1-9]\d*)$/,bh=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,oi=/($^)/,Ah=/['\n\r\u2028\u2029\\]/g,ui="\\ud800-\\udfff",Ph="\\u0300-\\u036f",Ih="\\ufe20-\\ufe2f",xh="\\u20d0-\\u20ff",co=Ph+Ih+xh,ho="\\u2700-\\u27bf",fo="a-z\\xdf-\\xf6\\xf8-\\xff",Lh="\\xac\\xb1\\xd7\\xf7",Nh="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",Uh="\\u2000-\\u206f",Oh=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",go="A-Z\\xc0-\\xd6\\xd8-\\xde",po="\\ufe0e\\ufe0f",_o=Lh+Nh+Uh+Oh,Es="['’]",$h="["+ui+"]",mo="["+_o+"]",li="["+co+"]",vo="\\d+",Dh="["+ho+"]",wo="["+fo+"]",So="[^"+ui+_o+vo+ho+fo+go+"]",Cs="\\ud83c[\\udffb-\\udfff]",Mh="(?:"+li+"|"+Cs+")",Eo="[^"+ui+"]",Ts="(?:\\ud83c[\\udde6-\\uddff]){2}",ys="[\\ud800-\\udbff][\\udc00-\\udfff]",Gn="["+go+"]",Co="\\u200d",To="(?:"+wo+"|"+So+")",Fh="(?:"+Gn+"|"+So+")",yo="(?:"+Es+"(?:d|ll|m|re|s|t|ve))?",Ro="(?:"+Es+"(?:D|LL|M|RE|S|T|VE))?",bo=Mh+"?",Ao="["+po+"]?",kh="(?:"+Co+"(?:"+[Eo,Ts,ys].join("|")+")"+Ao+bo+")*",Hh="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",Wh="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",Po=Ao+bo+kh,Vh="(?:"+[Dh,Ts,ys].join("|")+")"+Po,Bh="(?:"+[Eo+li+"?",li,Ts,ys,$h].join("|")+")",Gh=RegExp(Es,"g"),Qh=RegExp(li,"g"),Rs=RegExp(Cs+"(?="+Cs+")|"+Bh+Po,"g"),qh=RegExp([Gn+"?"+wo+"+"+yo+"(?="+[mo,Gn,"$"].join("|")+")",Fh+"+"+Ro+"(?="+[mo,Gn+To,"$"].join("|")+")",Gn+"?"+To+"+"+yo,Gn+"+"+Ro,Wh,Hh,vo,Vh].join("|"),"g"),zh=RegExp("["+Co+ui+co+po+"]"),Kh=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,Yh=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],Xh=-1,he={};he[cs]=he[hs]=he[fs]=he[ds]=he[gs]=he[ps]=he[_s]=he[ms]=he[vs]=!0,he[Vn]=he[ri]=he[Ar]=he[Er]=he[Bn]=he[Cr]=he[ii]=he[si]=he[St]=he[Tr]=he[kt]=he[yr]=he[Et]=he[Rr]=he[br]=!1;var ce={};ce[Vn]=ce[ri]=ce[Ar]=ce[Bn]=ce[Er]=ce[Cr]=ce[cs]=ce[hs]=ce[fs]=ce[ds]=ce[gs]=ce[St]=ce[Tr]=ce[kt]=ce[yr]=ce[Et]=ce[Rr]=ce[ai]=ce[ps]=ce[_s]=ce[ms]=ce[vs]=!0,ce[ii]=ce[si]=ce[br]=!1;var Zh={À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",Ç:"C",ç:"c",Ð:"D",ð:"d",È:"E",É:"E",Ê:"E",Ë:"E",è:"e",é:"e",ê:"e",ë:"e",Ì:"I",Í:"I",Î:"I",Ï:"I",ì:"i",í:"i",î:"i",ï:"i",Ñ:"N",ñ:"n",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ù:"U",Ú:"U",Û:"U",Ü:"U",ù:"u",ú:"u",û:"u",ü:"u",Ý:"Y",ý:"y",ÿ:"y",Æ:"Ae",æ:"ae",Þ:"Th",þ:"th",ß:"ss",Ā:"A",Ă:"A",Ą:"A",ā:"a",ă:"a",ą:"a",Ć:"C",Ĉ:"C",Ċ:"C",Č:"C",ć:"c",ĉ:"c",ċ:"c",č:"c",Ď:"D",Đ:"D",ď:"d",đ:"d",Ē:"E",Ĕ:"E",Ė:"E",Ę:"E",Ě:"E",ē:"e",ĕ:"e",ė:"e",ę:"e",ě:"e",Ĝ:"G",Ğ:"G",Ġ:"G",Ģ:"G",ĝ:"g",ğ:"g",ġ:"g",ģ:"g",Ĥ:"H",Ħ:"H",ĥ:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Į:"I",İ:"I",ĩ:"i",ī:"i",ĭ:"i",į:"i",ı:"i",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",ĸ:"k",Ĺ:"L",Ļ:"L",Ľ:"L",Ŀ:"L",Ł:"L",ĺ:"l",ļ:"l",ľ:"l",ŀ:"l",ł:"l",Ń:"N",Ņ:"N",Ň:"N",Ŋ:"N",ń:"n",ņ:"n",ň:"n",ŋ:"n",Ō:"O",Ŏ:"O",Ő:"O",ō:"o",ŏ:"o",ő:"o",Ŕ:"R",Ŗ:"R",Ř:"R",ŕ:"r",ŗ:"r",ř:"r",Ś:"S",Ŝ:"S",Ş:"S",Š:"S",ś:"s",ŝ:"s",ş:"s",š:"s",Ţ:"T",Ť:"T",Ŧ:"T",ţ:"t",ť:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Ů:"U",Ű:"U",Ų:"U",ũ:"u",ū:"u",ŭ:"u",ů:"u",ű:"u",ų:"u",Ŵ:"W",ŵ:"w",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Ź:"Z",Ż:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",IJ:"IJ",ij:"ij",Œ:"Oe",œ:"oe",ʼn:"'n",ſ:"s"},Jh={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"},jh={"&amp;":"&","&lt;":"<","&gt;":">","&quot;":'"',"&#39;":"'"},ef={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},tf=parseFloat,nf=parseInt,Io=typeof Ki=="object"&&Ki&&Ki.Object===Object&&Ki,rf=typeof self=="object"&&self&&self.Object===Object&&self,Le=Io||rf||Function("return this")(),bs=n&&!n.nodeType&&n,Cn=bs&&!0&&i&&!i.nodeType&&i,xo=Cn&&Cn.exports===bs,As=xo&&Io.process,ut=(function(){try{var w=Cn&&Cn.require&&Cn.require("util").types;return w||As&&As.binding&&As.binding("util")}catch{}})(),Lo=ut&&ut.isArrayBuffer,No=ut&&ut.isDate,Uo=ut&&ut.isMap,Oo=ut&&ut.isRegExp,$o=ut&&ut.isSet,Do=ut&&ut.isTypedArray;function je(w,b,y){switch(y.length){case 0:return w.call(b);case 1:return w.call(b,y[0]);case 2:return w.call(b,y[0],y[1]);case 3:return w.call(b,y[0],y[1],y[2])}return w.apply(b,y)}function sf(w,b,y,F){for(var Q=-1,re=w==null?0:w.length;++Q<re;){var we=w[Q];b(F,we,y(we),w)}return F}function et(w,b){for(var y=-1,F=w==null?0:w.length;++y<F&&b(w[y],y,w)!==!1;);return w}function af(w,b){for(var y=w==null?0:w.length;y--&&b(w[y],y,w)!==!1;);return w}function Mo(w,b){for(var y=-1,F=w==null?0:w.length;++y<F;)if(!b(w[y],y,w))return!1;return!0}function jt(w,b){for(var y=-1,F=w==null?0:w.length,Q=0,re=[];++y<F;){var we=w[y];b(we,y,w)&&(re[Q++]=we)}return re}function ci(w,b){var y=w==null?0:w.length;return!!y&&Qn(w,b,0)>-1}function Ps(w,b,y){for(var F=-1,Q=w==null?0:w.length;++F<Q;)if(y(b,w[F]))return!0;return!1}function fe(w,b){for(var y=-1,F=w==null?0:w.length,Q=Array(F);++y<F;)Q[y]=b(w[y],y,w);return Q}function en(w,b){for(var y=-1,F=b.length,Q=w.length;++y<F;)w[Q+y]=b[y];return w}function Is(w,b,y,F){var Q=-1,re=w==null?0:w.length;for(F&&re&&(y=w[++Q]);++Q<re;)y=b(y,w[Q],Q,w);return y}function of(w,b,y,F){var Q=w==null?0:w.length;for(F&&Q&&(y=w[--Q]);Q--;)y=b(y,w[Q],Q,w);return y}function xs(w,b){for(var y=-1,F=w==null?0:w.length;++y<F;)if(b(w[y],y,w))return!0;return!1}var uf=Ls("length");function lf(w){return w.split("")}function cf(w){return w.match(vh)||[]}function Fo(w,b,y){var F;return y(w,function(Q,re,we){if(b(Q,re,we))return F=re,!1}),F}function hi(w,b,y,F){for(var Q=w.length,re=y+(F?1:-1);F?re--:++re<Q;)if(b(w[re],re,w))return re;return-1}function Qn(w,b,y){return b===b?Cf(w,b,y):hi(w,ko,y)}function hf(w,b,y,F){for(var Q=y-1,re=w.length;++Q<re;)if(F(w[Q],b))return Q;return-1}function ko(w){return w!==w}function Ho(w,b){var y=w==null?0:w.length;return y?Us(w,b)/y:Jt}function Ls(w){return function(b){return b==null?r:b[w]}}function Ns(w){return function(b){return w==null?r:w[b]}}function Wo(w,b,y,F,Q){return Q(w,function(re,we,le){y=F?(F=!1,re):b(y,re,we,le)}),y}function ff(w,b){var y=w.length;for(w.sort(b);y--;)w[y]=w[y].value;return w}function Us(w,b){for(var y,F=-1,Q=w.length;++F<Q;){var re=b(w[F]);re!==r&&(y=y===r?re:y+re)}return y}function Os(w,b){for(var y=-1,F=Array(w);++y<w;)F[y]=b(y);return F}function df(w,b){return fe(b,function(y){return[y,w[y]]})}function Vo(w){return w&&w.slice(0,qo(w)+1).replace(Ss,"")}function tt(w){return function(b){return w(b)}}function $s(w,b){return fe(b,function(y){return w[y]})}function Pr(w,b){return w.has(b)}function Bo(w,b){for(var y=-1,F=w.length;++y<F&&Qn(b,w[y],0)>-1;);return y}function Go(w,b){for(var y=w.length;y--&&Qn(b,w[y],0)>-1;);return y}function gf(w,b){for(var y=w.length,F=0;y--;)w[y]===b&&++F;return F}var pf=Ns(Zh),_f=Ns(Jh);function mf(w){return"\\"+ef[w]}function vf(w,b){return w==null?r:w[b]}function qn(w){return zh.test(w)}function wf(w){return Kh.test(w)}function Sf(w){for(var b,y=[];!(b=w.next()).done;)y.push(b.value);return y}function Ds(w){var b=-1,y=Array(w.size);return w.forEach(function(F,Q){y[++b]=[Q,F]}),y}function Qo(w,b){return function(y){return w(b(y))}}function tn(w,b){for(var y=-1,F=w.length,Q=0,re=[];++y<F;){var we=w[y];(we===b||we===T)&&(w[y]=T,re[Q++]=y)}return re}function fi(w){var b=-1,y=Array(w.size);return w.forEach(function(F){y[++b]=F}),y}function Ef(w){var b=-1,y=Array(w.size);return w.forEach(function(F){y[++b]=[F,F]}),y}function Cf(w,b,y){for(var F=y-1,Q=w.length;++F<Q;)if(w[F]===b)return F;return-1}function Tf(w,b,y){for(var F=y+1;F--;)if(w[F]===b)return F;return F}function zn(w){return qn(w)?Rf(w):uf(w)}function Ct(w){return qn(w)?bf(w):lf(w)}function qo(w){for(var b=w.length;b--&&gh.test(w.charAt(b)););return b}var yf=Ns(jh);function Rf(w){for(var b=Rs.lastIndex=0;Rs.test(w);)++b;return b}function bf(w){return w.match(Rs)||[]}function Af(w){return w.match(qh)||[]}var Pf=(function w(b){b=b==null?Le:Kn.defaults(Le.Object(),b,Kn.pick(Le,Yh));var y=b.Array,F=b.Date,Q=b.Error,re=b.Function,we=b.Math,le=b.Object,Ms=b.RegExp,If=b.String,lt=b.TypeError,di=y.prototype,xf=re.prototype,Yn=le.prototype,gi=b["__core-js_shared__"],pi=xf.toString,se=Yn.hasOwnProperty,Lf=0,zo=(function(){var e=/[^.]+$/.exec(gi&&gi.keys&&gi.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""})(),_i=Yn.toString,Nf=pi.call(le),Uf=Le._,Of=Ms("^"+pi.call(se).replace(ws,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),mi=xo?b.Buffer:r,nn=b.Symbol,vi=b.Uint8Array,Ko=mi?mi.allocUnsafe:r,wi=Qo(le.getPrototypeOf,le),Yo=le.create,Xo=Yn.propertyIsEnumerable,Si=di.splice,Zo=nn?nn.isConcatSpreadable:r,Ir=nn?nn.iterator:r,Tn=nn?nn.toStringTag:r,Ei=(function(){try{var e=Pn(le,"defineProperty");return e({},"",{}),e}catch{}})(),$f=b.clearTimeout!==Le.clearTimeout&&b.clearTimeout,Df=F&&F.now!==Le.Date.now&&F.now,Mf=b.setTimeout!==Le.setTimeout&&b.setTimeout,Ci=we.ceil,Ti=we.floor,Fs=le.getOwnPropertySymbols,Ff=mi?mi.isBuffer:r,Jo=b.isFinite,kf=di.join,Hf=Qo(le.keys,le),Se=we.max,De=we.min,Wf=F.now,Vf=b.parseInt,jo=we.random,Bf=di.reverse,ks=Pn(b,"DataView"),xr=Pn(b,"Map"),Hs=Pn(b,"Promise"),Xn=Pn(b,"Set"),Lr=Pn(b,"WeakMap"),Nr=Pn(le,"create"),yi=Lr&&new Lr,Zn={},Gf=In(ks),Qf=In(xr),qf=In(Hs),zf=In(Xn),Kf=In(Lr),Ri=nn?nn.prototype:r,Ur=Ri?Ri.valueOf:r,eu=Ri?Ri.toString:r;function f(e){if(ge(e)&&!z(e)&&!(e instanceof ee)){if(e instanceof ct)return e;if(se.call(e,"__wrapped__"))return tl(e)}return new ct(e)}var Jn=(function(){function e(){}return function(t){if(!de(t))return{};if(Yo)return Yo(t);e.prototype=t;var s=new e;return e.prototype=r,s}})();function bi(){}function ct(e,t){this.__wrapped__=e,this.__actions__=[],this.__chain__=!!t,this.__index__=0,this.__values__=r}f.templateSettings={escape:uh,evaluate:lh,interpolate:oo,variable:"",imports:{_:f}},f.prototype=bi.prototype,f.prototype.constructor=f,ct.prototype=Jn(bi.prototype),ct.prototype.constructor=ct;function ee(e){this.__wrapped__=e,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=Lt,this.__views__=[]}function Yf(){var e=new ee(this.__wrapped__);return e.__actions__=qe(this.__actions__),e.__dir__=this.__dir__,e.__filtered__=this.__filtered__,e.__iteratees__=qe(this.__iteratees__),e.__takeCount__=this.__takeCount__,e.__views__=qe(this.__views__),e}function Xf(){if(this.__filtered__){var e=new ee(this);e.__dir__=-1,e.__filtered__=!0}else e=this.clone(),e.__dir__*=-1;return e}function Zf(){var e=this.__wrapped__.value(),t=this.__dir__,s=z(e),o=t<0,h=s?e.length:0,g=lg(0,h,this.__views__),m=g.start,v=g.end,S=v-m,P=o?v:m-1,I=this.__iteratees__,x=I.length,D=0,k=De(S,this.__takeCount__);if(!s||!o&&h==S&&k==S)return yu(e,this.__actions__);var G=[];e:for(;S--&&D<k;){P+=t;for(var Y=-1,V=e[P];++Y<x;){var J=I[Y],te=J.iteratee,it=J.type,Ve=te(V);if(it==En)V=Ve;else if(!Ve){if(it==$e)continue e;break e}}G[D++]=V}return G}ee.prototype=Jn(bi.prototype),ee.prototype.constructor=ee;function yn(e){var t=-1,s=e==null?0:e.length;for(this.clear();++t<s;){var o=e[t];this.set(o[0],o[1])}}function Jf(){this.__data__=Nr?Nr(null):{},this.size=0}function jf(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}function ed(e){var t=this.__data__;if(Nr){var s=t[e];return s===_?r:s}return se.call(t,e)?t[e]:r}function td(e){var t=this.__data__;return Nr?t[e]!==r:se.call(t,e)}function nd(e,t){var s=this.__data__;return this.size+=this.has(e)?0:1,s[e]=Nr&&t===r?_:t,this}yn.prototype.clear=Jf,yn.prototype.delete=jf,yn.prototype.get=ed,yn.prototype.has=td,yn.prototype.set=nd;function Ht(e){var t=-1,s=e==null?0:e.length;for(this.clear();++t<s;){var o=e[t];this.set(o[0],o[1])}}function rd(){this.__data__=[],this.size=0}function id(e){var t=this.__data__,s=Ai(t,e);if(s<0)return!1;var o=t.length-1;return s==o?t.pop():Si.call(t,s,1),--this.size,!0}function sd(e){var t=this.__data__,s=Ai(t,e);return s<0?r:t[s][1]}function ad(e){return Ai(this.__data__,e)>-1}function od(e,t){var s=this.__data__,o=Ai(s,e);return o<0?(++this.size,s.push([e,t])):s[o][1]=t,this}Ht.prototype.clear=rd,Ht.prototype.delete=id,Ht.prototype.get=sd,Ht.prototype.has=ad,Ht.prototype.set=od;function Wt(e){var t=-1,s=e==null?0:e.length;for(this.clear();++t<s;){var o=e[t];this.set(o[0],o[1])}}function ud(){this.size=0,this.__data__={hash:new yn,map:new(xr||Ht),string:new yn}}function ld(e){var t=ki(this,e).delete(e);return this.size-=t?1:0,t}function cd(e){return ki(this,e).get(e)}function hd(e){return ki(this,e).has(e)}function fd(e,t){var s=ki(this,e),o=s.size;return s.set(e,t),this.size+=s.size==o?0:1,this}Wt.prototype.clear=ud,Wt.prototype.delete=ld,Wt.prototype.get=cd,Wt.prototype.has=hd,Wt.prototype.set=fd;function Rn(e){var t=-1,s=e==null?0:e.length;for(this.__data__=new Wt;++t<s;)this.add(e[t])}function dd(e){return this.__data__.set(e,_),this}function gd(e){return this.__data__.has(e)}Rn.prototype.add=Rn.prototype.push=dd,Rn.prototype.has=gd;function Tt(e){var t=this.__data__=new Ht(e);this.size=t.size}function pd(){this.__data__=new Ht,this.size=0}function _d(e){var t=this.__data__,s=t.delete(e);return this.size=t.size,s}function md(e){return this.__data__.get(e)}function vd(e){return this.__data__.has(e)}function wd(e,t){var s=this.__data__;if(s instanceof Ht){var o=s.__data__;if(!xr||o.length<u-1)return o.push([e,t]),this.size=++s.size,this;s=this.__data__=new Wt(o)}return s.set(e,t),this.size=s.size,this}Tt.prototype.clear=pd,Tt.prototype.delete=_d,Tt.prototype.get=md,Tt.prototype.has=vd,Tt.prototype.set=wd;function tu(e,t){var s=z(e),o=!s&&xn(e),h=!s&&!o&&un(e),g=!s&&!o&&!h&&nr(e),m=s||o||h||g,v=m?Os(e.length,If):[],S=v.length;for(var P in e)(t||se.call(e,P))&&!(m&&(P=="length"||h&&(P=="offset"||P=="parent")||g&&(P=="buffer"||P=="byteLength"||P=="byteOffset")||Gt(P,S)))&&v.push(P);return v}function nu(e){var t=e.length;return t?e[Zs(0,t-1)]:r}function Sd(e,t){return Hi(qe(e),bn(t,0,e.length))}function Ed(e){return Hi(qe(e))}function Ws(e,t,s){(s!==r&&!Rt(e[t],s)||s===r&&!(t in e))&&Nt(e,t,s)}function Or(e,t,s){var o=e[t];(!(se.call(e,t)&&Rt(o,s))||s===r&&!(t in e))&&Nt(e,t,s)}function Ai(e,t){for(var s=e.length;s--;)if(Rt(e[s][0],t))return s;return-1}function Cd(e,t,s,o){return rn(e,function(h,g,m){t(o,h,s(h),m)}),o}function ru(e,t){return e&&Ot(t,Ae(t),e)}function Td(e,t){return e&&Ot(t,Ke(t),e)}function Nt(e,t,s){t=="__proto__"&&Ei?Ei(e,t,{configurable:!0,enumerable:!0,value:s,writable:!0}):e[t]=s}function Vs(e,t){for(var s=-1,o=t.length,h=y(o),g=e==null;++s<o;)h[s]=g?r:Ta(e,t[s]);return h}function bn(e,t,s){return e===e&&(s!==r&&(e=e<=s?e:s),t!==r&&(e=e>=t?e:t)),e}function ht(e,t,s,o,h,g){var m,v=t&E,S=t&C,P=t&A;if(s&&(m=h?s(e,o,h,g):s(e)),m!==r)return m;if(!de(e))return e;var I=z(e);if(I){if(m=hg(e),!v)return qe(e,m)}else{var x=Me(e),D=x==si||x==ro;if(un(e))return Au(e,v);if(x==kt||x==Vn||D&&!h){if(m=S||D?{}:qu(e),!v)return S?eg(e,Td(m,e)):jd(e,ru(m,e))}else{if(!ce[x])return h?e:{};m=fg(e,x,v)}}g||(g=new Tt);var k=g.get(e);if(k)return k;g.set(e,m),El(e)?e.forEach(function(V){m.add(ht(V,t,s,V,e,g))}):wl(e)&&e.forEach(function(V,J){m.set(J,ht(V,t,s,J,e,g))});var G=P?S?ua:oa:S?Ke:Ae,Y=I?r:G(e);return et(Y||e,function(V,J){Y&&(J=V,V=e[J]),Or(m,J,ht(V,t,s,J,e,g))}),m}function yd(e){var t=Ae(e);return function(s){return iu(s,e,t)}}function iu(e,t,s){var o=s.length;if(e==null)return!o;for(e=le(e);o--;){var h=s[o],g=t[h],m=e[h];if(m===r&&!(h in e)||!g(m))return!1}return!0}function su(e,t,s){if(typeof e!="function")throw new lt(l);return Wr(function(){e.apply(r,s)},t)}function $r(e,t,s,o){var h=-1,g=ci,m=!0,v=e.length,S=[],P=t.length;if(!v)return S;s&&(t=fe(t,tt(s))),o?(g=Ps,m=!1):t.length>=u&&(g=Pr,m=!1,t=new Rn(t));e:for(;++h<v;){var I=e[h],x=s==null?I:s(I);if(I=o||I!==0?I:0,m&&x===x){for(var D=P;D--;)if(t[D]===x)continue e;S.push(I)}else g(t,x,o)||S.push(I)}return S}var rn=Nu(Ut),au=Nu(Gs,!0);function Rd(e,t){var s=!0;return rn(e,function(o,h,g){return s=!!t(o,h,g),s}),s}function Pi(e,t,s){for(var o=-1,h=e.length;++o<h;){var g=e[o],m=t(g);if(m!=null&&(v===r?m===m&&!rt(m):s(m,v)))var v=m,S=g}return S}function bd(e,t,s,o){var h=e.length;for(s=K(s),s<0&&(s=-s>h?0:h+s),o=o===r||o>h?h:K(o),o<0&&(o+=h),o=s>o?0:Tl(o);s<o;)e[s++]=t;return e}function ou(e,t){var s=[];return rn(e,function(o,h,g){t(o,h,g)&&s.push(o)}),s}function Ne(e,t,s,o,h){var g=-1,m=e.length;for(s||(s=gg),h||(h=[]);++g<m;){var v=e[g];t>0&&s(v)?t>1?Ne(v,t-1,s,o,h):en(h,v):o||(h[h.length]=v)}return h}var Bs=Uu(),uu=Uu(!0);function Ut(e,t){return e&&Bs(e,t,Ae)}function Gs(e,t){return e&&uu(e,t,Ae)}function Ii(e,t){return jt(t,function(s){return Qt(e[s])})}function An(e,t){t=an(t,e);for(var s=0,o=t.length;e!=null&&s<o;)e=e[yt(t[s++])];return s&&s==o?e:r}function lu(e,t,s){var o=t(e);return z(e)?o:en(o,s(e))}function He(e){return e==null?e===r?th:jc:Tn&&Tn in le(e)?ug(e):Eg(e)}function Qs(e,t){return e>t}function Ad(e,t){return e!=null&&se.call(e,t)}function Pd(e,t){return e!=null&&t in le(e)}function Id(e,t,s){return e>=De(t,s)&&e<Se(t,s)}function qs(e,t,s){for(var o=s?Ps:ci,h=e[0].length,g=e.length,m=g,v=y(g),S=1/0,P=[];m--;){var I=e[m];m&&t&&(I=fe(I,tt(t))),S=De(I.length,S),v[m]=!s&&(t||h>=120&&I.length>=120)?new Rn(m&&I):r}I=e[0];var x=-1,D=v[0];e:for(;++x<h&&P.length<S;){var k=I[x],G=t?t(k):k;if(k=s||k!==0?k:0,!(D?Pr(D,G):o(P,G,s))){for(m=g;--m;){var Y=v[m];if(!(Y?Pr(Y,G):o(e[m],G,s)))continue e}D&&D.push(G),P.push(k)}}return P}function xd(e,t,s,o){return Ut(e,function(h,g,m){t(o,s(h),g,m)}),o}function Dr(e,t,s){t=an(t,e),e=Xu(e,t);var o=e==null?e:e[yt(dt(t))];return o==null?r:je(o,e,s)}function cu(e){return ge(e)&&He(e)==Vn}function Ld(e){return ge(e)&&He(e)==Ar}function Nd(e){return ge(e)&&He(e)==Cr}function Mr(e,t,s,o,h){return e===t?!0:e==null||t==null||!ge(e)&&!ge(t)?e!==e&&t!==t:Ud(e,t,s,o,Mr,h)}function Ud(e,t,s,o,h,g){var m=z(e),v=z(t),S=m?ri:Me(e),P=v?ri:Me(t);S=S==Vn?kt:S,P=P==Vn?kt:P;var I=S==kt,x=P==kt,D=S==P;if(D&&un(e)){if(!un(t))return!1;m=!0,I=!1}if(D&&!I)return g||(g=new Tt),m||nr(e)?Bu(e,t,s,o,h,g):ag(e,t,S,s,o,h,g);if(!(s&N)){var k=I&&se.call(e,"__wrapped__"),G=x&&se.call(t,"__wrapped__");if(k||G){var Y=k?e.value():e,V=G?t.value():t;return g||(g=new Tt),h(Y,V,s,o,g)}}return D?(g||(g=new Tt),og(e,t,s,o,h,g)):!1}function Od(e){return ge(e)&&Me(e)==St}function zs(e,t,s,o){var h=s.length,g=h,m=!o;if(e==null)return!g;for(e=le(e);h--;){var v=s[h];if(m&&v[2]?v[1]!==e[v[0]]:!(v[0]in e))return!1}for(;++h<g;){v=s[h];var S=v[0],P=e[S],I=v[1];if(m&&v[2]){if(P===r&&!(S in e))return!1}else{var x=new Tt;if(o)var D=o(P,I,S,e,t,x);if(!(D===r?Mr(I,P,N|H,o,x):D))return!1}}return!0}function hu(e){if(!de(e)||_g(e))return!1;var t=Qt(e)?Of:Th;return t.test(In(e))}function $d(e){return ge(e)&&He(e)==yr}function Dd(e){return ge(e)&&Me(e)==Et}function Md(e){return ge(e)&&qi(e.length)&&!!he[He(e)]}function fu(e){return typeof e=="function"?e:e==null?Ye:typeof e=="object"?z(e)?pu(e[0],e[1]):gu(e):$l(e)}function Ks(e){if(!Hr(e))return Hf(e);var t=[];for(var s in le(e))se.call(e,s)&&s!="constructor"&&t.push(s);return t}function Fd(e){if(!de(e))return Sg(e);var t=Hr(e),s=[];for(var o in e)o=="constructor"&&(t||!se.call(e,o))||s.push(o);return s}function Ys(e,t){return e<t}function du(e,t){var s=-1,o=ze(e)?y(e.length):[];return rn(e,function(h,g,m){o[++s]=t(h,g,m)}),o}function gu(e){var t=ca(e);return t.length==1&&t[0][2]?Ku(t[0][0],t[0][1]):function(s){return s===e||zs(s,e,t)}}function pu(e,t){return fa(e)&&zu(t)?Ku(yt(e),t):function(s){var o=Ta(s,e);return o===r&&o===t?ya(s,e):Mr(t,o,N|H)}}function xi(e,t,s,o,h){e!==t&&Bs(t,function(g,m){if(h||(h=new Tt),de(g))kd(e,t,m,s,xi,o,h);else{var v=o?o(ga(e,m),g,m+"",e,t,h):r;v===r&&(v=g),Ws(e,m,v)}},Ke)}function kd(e,t,s,o,h,g,m){var v=ga(e,s),S=ga(t,s),P=m.get(S);if(P){Ws(e,s,P);return}var I=g?g(v,S,s+"",e,t,m):r,x=I===r;if(x){var D=z(S),k=!D&&un(S),G=!D&&!k&&nr(S);I=S,D||k||G?z(v)?I=v:_e(v)?I=qe(v):k?(x=!1,I=Au(S,!0)):G?(x=!1,I=Pu(S,!0)):I=[]:Vr(S)||xn(S)?(I=v,xn(v)?I=yl(v):(!de(v)||Qt(v))&&(I=qu(S))):x=!1}x&&(m.set(S,I),h(I,S,o,g,m),m.delete(S)),Ws(e,s,I)}function _u(e,t){var s=e.length;if(s)return t+=t<0?s:0,Gt(t,s)?e[t]:r}function mu(e,t,s){t.length?t=fe(t,function(g){return z(g)?function(m){return An(m,g.length===1?g[0]:g)}:g}):t=[Ye];var o=-1;t=fe(t,tt(B()));var h=du(e,function(g,m,v){var S=fe(t,function(P){return P(g)});return{criteria:S,index:++o,value:g}});return ff(h,function(g,m){return Jd(g,m,s)})}function Hd(e,t){return vu(e,t,function(s,o){return ya(e,o)})}function vu(e,t,s){for(var o=-1,h=t.length,g={};++o<h;){var m=t[o],v=An(e,m);s(v,m)&&Fr(g,an(m,e),v)}return g}function Wd(e){return function(t){return An(t,e)}}function Xs(e,t,s,o){var h=o?hf:Qn,g=-1,m=t.length,v=e;for(e===t&&(t=qe(t)),s&&(v=fe(e,tt(s)));++g<m;)for(var S=0,P=t[g],I=s?s(P):P;(S=h(v,I,S,o))>-1;)v!==e&&Si.call(v,S,1),Si.call(e,S,1);return e}function wu(e,t){for(var s=e?t.length:0,o=s-1;s--;){var h=t[s];if(s==o||h!==g){var g=h;Gt(h)?Si.call(e,h,1):ea(e,h)}}return e}function Zs(e,t){return e+Ti(jo()*(t-e+1))}function Vd(e,t,s,o){for(var h=-1,g=Se(Ci((t-e)/(s||1)),0),m=y(g);g--;)m[o?g:++h]=e,e+=s;return m}function Js(e,t){var s="";if(!e||t<1||t>oe)return s;do t%2&&(s+=e),t=Ti(t/2),t&&(e+=e);while(t);return s}function X(e,t){return pa(Yu(e,t,Ye),e+"")}function Bd(e){return nu(rr(e))}function Gd(e,t){var s=rr(e);return Hi(s,bn(t,0,s.length))}function Fr(e,t,s,o){if(!de(e))return e;t=an(t,e);for(var h=-1,g=t.length,m=g-1,v=e;v!=null&&++h<g;){var S=yt(t[h]),P=s;if(S==="__proto__"||S==="constructor"||S==="prototype")return e;if(h!=m){var I=v[S];P=o?o(I,S,v):r,P===r&&(P=de(I)?I:Gt(t[h+1])?[]:{})}Or(v,S,P),v=v[S]}return e}var Su=yi?function(e,t){return yi.set(e,t),e}:Ye,Qd=Ei?function(e,t){return Ei(e,"toString",{configurable:!0,enumerable:!1,value:ba(t),writable:!0})}:Ye;function qd(e){return Hi(rr(e))}function ft(e,t,s){var o=-1,h=e.length;t<0&&(t=-t>h?0:h+t),s=s>h?h:s,s<0&&(s+=h),h=t>s?0:s-t>>>0,t>>>=0;for(var g=y(h);++o<h;)g[o]=e[o+t];return g}function zd(e,t){var s;return rn(e,function(o,h,g){return s=t(o,h,g),!s}),!!s}function Li(e,t,s){var o=0,h=e==null?o:e.length;if(typeof t=="number"&&t===t&&h<=Yc){for(;o<h;){var g=o+h>>>1,m=e[g];m!==null&&!rt(m)&&(s?m<=t:m<t)?o=g+1:h=g}return h}return js(e,t,Ye,s)}function js(e,t,s,o){var h=0,g=e==null?0:e.length;if(g===0)return 0;t=s(t);for(var m=t!==t,v=t===null,S=rt(t),P=t===r;h<g;){var I=Ti((h+g)/2),x=s(e[I]),D=x!==r,k=x===null,G=x===x,Y=rt(x);if(m)var V=o||G;else P?V=G&&(o||D):v?V=G&&D&&(o||!k):S?V=G&&D&&!k&&(o||!Y):k||Y?V=!1:V=o?x<=t:x<t;V?h=I+1:g=I}return De(g,Kc)}function Eu(e,t){for(var s=-1,o=e.length,h=0,g=[];++s<o;){var m=e[s],v=t?t(m):m;if(!s||!Rt(v,S)){var S=v;g[h++]=m===0?0:m}}return g}function Cu(e){return typeof e=="number"?e:rt(e)?Jt:+e}function nt(e){if(typeof e=="string")return e;if(z(e))return fe(e,nt)+"";if(rt(e))return eu?eu.call(e):"";var t=e+"";return t=="0"&&1/e==-ot?"-0":t}function sn(e,t,s){var o=-1,h=ci,g=e.length,m=!0,v=[],S=v;if(s)m=!1,h=Ps;else if(g>=u){var P=t?null:ig(e);if(P)return fi(P);m=!1,h=Pr,S=new Rn}else S=t?[]:v;e:for(;++o<g;){var I=e[o],x=t?t(I):I;if(I=s||I!==0?I:0,m&&x===x){for(var D=S.length;D--;)if(S[D]===x)continue e;t&&S.push(x),v.push(I)}else h(S,x,s)||(S!==v&&S.push(x),v.push(I))}return v}function ea(e,t){t=an(t,e);var s=-1,o=t.length;if(!o)return!0;for(;++s<o;){var h=yt(t[s]);if(h==="__proto__"&&!se.call(e,"__proto__")||(h==="constructor"||h==="prototype")&&s<o-1)return!1}var g=Xu(e,t);return g==null||delete g[yt(dt(t))]}function Tu(e,t,s,o){return Fr(e,t,s(An(e,t)),o)}function Ni(e,t,s,o){for(var h=e.length,g=o?h:-1;(o?g--:++g<h)&&t(e[g],g,e););return s?ft(e,o?0:g,o?g+1:h):ft(e,o?g+1:0,o?h:g)}function yu(e,t){var s=e;return s instanceof ee&&(s=s.value()),Is(t,function(o,h){return h.func.apply(h.thisArg,en([o],h.args))},s)}function ta(e,t,s){var o=e.length;if(o<2)return o?sn(e[0]):[];for(var h=-1,g=y(o);++h<o;)for(var m=e[h],v=-1;++v<o;)v!=h&&(g[h]=$r(g[h]||m,e[v],t,s));return sn(Ne(g,1),t,s)}function Ru(e,t,s){for(var o=-1,h=e.length,g=t.length,m={};++o<h;){var v=o<g?t[o]:r;s(m,e[o],v)}return m}function na(e){return _e(e)?e:[]}function ra(e){return typeof e=="function"?e:Ye}function an(e,t){return z(e)?e:fa(e,t)?[e]:el(ae(e))}var Kd=X;function on(e,t,s){var o=e.length;return s=s===r?o:s,!t&&s>=o?e:ft(e,t,s)}var bu=$f||function(e){return Le.clearTimeout(e)};function Au(e,t){if(t)return e.slice();var s=e.length,o=Ko?Ko(s):new e.constructor(s);return e.copy(o),o}function ia(e){var t=new e.constructor(e.byteLength);return new vi(t).set(new vi(e)),t}function Yd(e,t){var s=t?ia(e.buffer):e.buffer;return new e.constructor(s,e.byteOffset,e.byteLength)}function Xd(e){var t=new e.constructor(e.source,lo.exec(e));return t.lastIndex=e.lastIndex,t}function Zd(e){return Ur?le(Ur.call(e)):{}}function Pu(e,t){var s=t?ia(e.buffer):e.buffer;return new e.constructor(s,e.byteOffset,e.length)}function Iu(e,t){if(e!==t){var s=e!==r,o=e===null,h=e===e,g=rt(e),m=t!==r,v=t===null,S=t===t,P=rt(t);if(!v&&!P&&!g&&e>t||g&&m&&S&&!v&&!P||o&&m&&S||!s&&S||!h)return 1;if(!o&&!g&&!P&&e<t||P&&s&&h&&!o&&!g||v&&s&&h||!m&&h||!S)return-1}return 0}function Jd(e,t,s){for(var o=-1,h=e.criteria,g=t.criteria,m=h.length,v=s.length;++o<m;){var S=Iu(h[o],g[o]);if(S){if(o>=v)return S;var P=s[o];return S*(P=="desc"?-1:1)}}return e.index-t.index}function xu(e,t,s,o){for(var h=-1,g=e.length,m=s.length,v=-1,S=t.length,P=Se(g-m,0),I=y(S+P),x=!o;++v<S;)I[v]=t[v];for(;++h<m;)(x||h<g)&&(I[s[h]]=e[h]);for(;P--;)I[v++]=e[h++];return I}function Lu(e,t,s,o){for(var h=-1,g=e.length,m=-1,v=s.length,S=-1,P=t.length,I=Se(g-v,0),x=y(I+P),D=!o;++h<I;)x[h]=e[h];for(var k=h;++S<P;)x[k+S]=t[S];for(;++m<v;)(D||h<g)&&(x[k+s[m]]=e[h++]);return x}function qe(e,t){var s=-1,o=e.length;for(t||(t=y(o));++s<o;)t[s]=e[s];return t}function Ot(e,t,s,o){var h=!s;s||(s={});for(var g=-1,m=t.length;++g<m;){var v=t[g],S=o?o(s[v],e[v],v,s,e):r;S===r&&(S=e[v]),h?Nt(s,v,S):Or(s,v,S)}return s}function jd(e,t){return Ot(e,ha(e),t)}function eg(e,t){return Ot(e,Gu(e),t)}function Ui(e,t){return function(s,o){var h=z(s)?sf:Cd,g=t?t():{};return h(s,e,B(o,2),g)}}function jn(e){return X(function(t,s){var o=-1,h=s.length,g=h>1?s[h-1]:r,m=h>2?s[2]:r;for(g=e.length>3&&typeof g=="function"?(h--,g):r,m&&We(s[0],s[1],m)&&(g=h<3?r:g,h=1),t=le(t);++o<h;){var v=s[o];v&&e(t,v,o,g)}return t})}function Nu(e,t){return function(s,o){if(s==null)return s;if(!ze(s))return e(s,o);for(var h=s.length,g=t?h:-1,m=le(s);(t?g--:++g<h)&&o(m[g],g,m)!==!1;);return s}}function Uu(e){return function(t,s,o){for(var h=-1,g=le(t),m=o(t),v=m.length;v--;){var S=m[e?v:++h];if(s(g[S],S,g)===!1)break}return t}}function tg(e,t,s){var o=t&W,h=kr(e);function g(){var m=this&&this!==Le&&this instanceof g?h:e;return m.apply(o?s:this,arguments)}return g}function Ou(e){return function(t){t=ae(t);var s=qn(t)?Ct(t):r,o=s?s[0]:t.charAt(0),h=s?on(s,1).join(""):t.slice(1);return o[e]()+h}}function er(e){return function(t){return Is(Ul(Nl(t).replace(Gh,"")),e,"")}}function kr(e){return function(){var t=arguments;switch(t.length){case 0:return new e;case 1:return new e(t[0]);case 2:return new e(t[0],t[1]);case 3:return new e(t[0],t[1],t[2]);case 4:return new e(t[0],t[1],t[2],t[3]);case 5:return new e(t[0],t[1],t[2],t[3],t[4]);case 6:return new e(t[0],t[1],t[2],t[3],t[4],t[5]);case 7:return new e(t[0],t[1],t[2],t[3],t[4],t[5],t[6])}var s=Jn(e.prototype),o=e.apply(s,t);return de(o)?o:s}}function ng(e,t,s){var o=kr(e);function h(){for(var g=arguments.length,m=y(g),v=g,S=tr(h);v--;)m[v]=arguments[v];var P=g<3&&m[0]!==S&&m[g-1]!==S?[]:tn(m,S);if(g-=P.length,g<s)return ku(e,t,Oi,h.placeholder,r,m,P,r,r,s-g);var I=this&&this!==Le&&this instanceof h?o:e;return je(I,this,m)}return h}function $u(e){return function(t,s,o){var h=le(t);if(!ze(t)){var g=B(s,3);t=Ae(t),s=function(v){return g(h[v],v,h)}}var m=e(t,s,o);return m>-1?h[g?t[m]:m]:r}}function Du(e){return Bt(function(t){var s=t.length,o=s,h=ct.prototype.thru;for(e&&t.reverse();o--;){var g=t[o];if(typeof g!="function")throw new lt(l);if(h&&!m&&Fi(g)=="wrapper")var m=new ct([],!0)}for(o=m?o:s;++o<s;){g=t[o];var v=Fi(g),S=v=="wrapper"?la(g):r;S&&da(S[0])&&S[1]==(ye|Ie|xe|Re)&&!S[4].length&&S[9]==1?m=m[Fi(S[0])].apply(m,S[3]):m=g.length==1&&da(g)?m[v]():m.thru(g)}return function(){var P=arguments,I=P[0];if(m&&P.length==1&&z(I))return m.plant(I).value();for(var x=0,D=s?t[x].apply(this,P):I;++x<s;)D=t[x].call(this,D);return D}})}function Oi(e,t,s,o,h,g,m,v,S,P){var I=t&ye,x=t&W,D=t&ie,k=t&(Ie|Qe),G=t&ve,Y=D?r:kr(e);function V(){for(var J=arguments.length,te=y(J),it=J;it--;)te[it]=arguments[it];if(k)var Ve=tr(V),st=gf(te,Ve);if(o&&(te=xu(te,o,h,k)),g&&(te=Lu(te,g,m,k)),J-=st,k&&J<P){var me=tn(te,Ve);return ku(e,t,Oi,V.placeholder,s,te,me,v,S,P-J)}var bt=x?s:this,zt=D?bt[e]:e;return J=te.length,v?te=Cg(te,v):G&&J>1&&te.reverse(),I&&S<J&&(te.length=S),this&&this!==Le&&this instanceof V&&(zt=Y||kr(zt)),zt.apply(bt,te)}return V}function Mu(e,t){return function(s,o){return xd(s,e,t(o),{})}}function $i(e,t){return function(s,o){var h;if(s===r&&o===r)return t;if(s!==r&&(h=s),o!==r){if(h===r)return o;typeof s=="string"||typeof o=="string"?(s=nt(s),o=nt(o)):(s=Cu(s),o=Cu(o)),h=e(s,o)}return h}}function sa(e){return Bt(function(t){return t=fe(t,tt(B())),X(function(s){var o=this;return e(t,function(h){return je(h,o,s)})})})}function Di(e,t){t=t===r?" ":nt(t);var s=t.length;if(s<2)return s?Js(t,e):t;var o=Js(t,Ci(e/zn(t)));return qn(t)?on(Ct(o),0,e).join(""):o.slice(0,e)}function rg(e,t,s,o){var h=t&W,g=kr(e);function m(){for(var v=-1,S=arguments.length,P=-1,I=o.length,x=y(I+S),D=this&&this!==Le&&this instanceof m?g:e;++P<I;)x[P]=o[P];for(;S--;)x[P++]=arguments[++v];return je(D,h?s:this,x)}return m}function Fu(e){return function(t,s,o){return o&&typeof o!="number"&&We(t,s,o)&&(s=o=r),t=qt(t),s===r?(s=t,t=0):s=qt(s),o=o===r?t<s?1:-1:qt(o),Vd(t,s,o,e)}}function Mi(e){return function(t,s){return typeof t=="string"&&typeof s=="string"||(t=gt(t),s=gt(s)),e(t,s)}}function ku(e,t,s,o,h,g,m,v,S,P){var I=t&Ie,x=I?m:r,D=I?r:m,k=I?g:r,G=I?r:g;t|=I?xe:Je,t&=~(I?Je:xe),t&Oe||(t&=-4);var Y=[e,t,h,k,x,G,D,v,S,P],V=s.apply(r,Y);return da(e)&&Zu(V,Y),V.placeholder=o,Ju(V,e,t)}function aa(e){var t=we[e];return function(s,o){if(s=gt(s),o=o==null?0:De(K(o),292),o&&Jo(s)){var h=(ae(s)+"e").split("e"),g=t(h[0]+"e"+(+h[1]+o));return h=(ae(g)+"e").split("e"),+(h[0]+"e"+(+h[1]-o))}return t(s)}}var ig=Xn&&1/fi(new Xn([,-0]))[1]==ot?function(e){return new Xn(e)}:Ia;function Hu(e){return function(t){var s=Me(t);return s==St?Ds(t):s==Et?Ef(t):df(t,e(t))}}function Vt(e,t,s,o,h,g,m,v){var S=t&ie;if(!S&&typeof e!="function")throw new lt(l);var P=o?o.length:0;if(P||(t&=-97,o=h=r),m=m===r?m:Se(K(m),0),v=v===r?v:K(v),P-=h?h.length:0,t&Je){var I=o,x=h;o=h=r}var D=S?r:la(e),k=[e,t,s,o,h,I,x,g,m,v];if(D&&wg(k,D),e=k[0],t=k[1],s=k[2],o=k[3],h=k[4],v=k[9]=k[9]===r?S?0:e.length:Se(k[9]-P,0),!v&&t&(Ie|Qe)&&(t&=-25),!t||t==W)var G=tg(e,t,s);else t==Ie||t==Qe?G=ng(e,t,v):(t==xe||t==(W|xe))&&!h.length?G=rg(e,t,s,o):G=Oi.apply(r,k);var Y=D?Su:Zu;return Ju(Y(G,k),e,t)}function Wu(e,t,s,o){return e===r||Rt(e,Yn[s])&&!se.call(o,s)?t:e}function Vu(e,t,s,o,h,g){return de(e)&&de(t)&&(g.set(t,e),xi(e,t,r,Vu,g),g.delete(t)),e}function sg(e){return Vr(e)?r:e}function Bu(e,t,s,o,h,g){var m=s&N,v=e.length,S=t.length;if(v!=S&&!(m&&S>v))return!1;var P=g.get(e),I=g.get(t);if(P&&I)return P==t&&I==e;var x=-1,D=!0,k=s&H?new Rn:r;for(g.set(e,t),g.set(t,e);++x<v;){var G=e[x],Y=t[x];if(o)var V=m?o(Y,G,x,t,e,g):o(G,Y,x,e,t,g);if(V!==r){if(V)continue;D=!1;break}if(k){if(!xs(t,function(J,te){if(!Pr(k,te)&&(G===J||h(G,J,s,o,g)))return k.push(te)})){D=!1;break}}else if(!(G===Y||h(G,Y,s,o,g))){D=!1;break}}return g.delete(e),g.delete(t),D}function ag(e,t,s,o,h,g,m){switch(s){case Bn:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case Ar:return!(e.byteLength!=t.byteLength||!g(new vi(e),new vi(t)));case Er:case Cr:case Tr:return Rt(+e,+t);case ii:return e.name==t.name&&e.message==t.message;case yr:case Rr:return e==t+"";case St:var v=Ds;case Et:var S=o&N;if(v||(v=fi),e.size!=t.size&&!S)return!1;var P=m.get(e);if(P)return P==t;o|=H,m.set(e,t);var I=Bu(v(e),v(t),o,h,g,m);return m.delete(e),I;case ai:if(Ur)return Ur.call(e)==Ur.call(t)}return!1}function og(e,t,s,o,h,g){var m=s&N,v=oa(e),S=v.length,P=oa(t),I=P.length;if(S!=I&&!m)return!1;for(var x=S;x--;){var D=v[x];if(!(m?D in t:se.call(t,D)))return!1}var k=g.get(e),G=g.get(t);if(k&&G)return k==t&&G==e;var Y=!0;g.set(e,t),g.set(t,e);for(var V=m;++x<S;){D=v[x];var J=e[D],te=t[D];if(o)var it=m?o(te,J,D,t,e,g):o(J,te,D,e,t,g);if(!(it===r?J===te||h(J,te,s,o,g):it)){Y=!1;break}V||(V=D=="constructor")}if(Y&&!V){var Ve=e.constructor,st=t.constructor;Ve!=st&&"constructor"in e&&"constructor"in t&&!(typeof Ve=="function"&&Ve instanceof Ve&&typeof st=="function"&&st instanceof st)&&(Y=!1)}return g.delete(e),g.delete(t),Y}function Bt(e){return pa(Yu(e,r,il),e+"")}function oa(e){return lu(e,Ae,ha)}function ua(e){return lu(e,Ke,Gu)}var la=yi?function(e){return yi.get(e)}:Ia;function Fi(e){for(var t=e.name+"",s=Zn[t],o=se.call(Zn,t)?s.length:0;o--;){var h=s[o],g=h.func;if(g==null||g==e)return h.name}return t}function tr(e){var t=se.call(f,"placeholder")?f:e;return t.placeholder}function B(){var e=f.iteratee||Aa;return e=e===Aa?fu:e,arguments.length?e(arguments[0],arguments[1]):e}function ki(e,t){var s=e.__data__;return pg(t)?s[typeof t=="string"?"string":"hash"]:s.map}function ca(e){for(var t=Ae(e),s=t.length;s--;){var o=t[s],h=e[o];t[s]=[o,h,zu(h)]}return t}function Pn(e,t){var s=vf(e,t);return hu(s)?s:r}function ug(e){var t=se.call(e,Tn),s=e[Tn];try{e[Tn]=r;var o=!0}catch{}var h=_i.call(e);return o&&(t?e[Tn]=s:delete e[Tn]),h}var ha=Fs?function(e){return e==null?[]:(e=le(e),jt(Fs(e),function(t){return Xo.call(e,t)}))}:xa,Gu=Fs?function(e){for(var t=[];e;)en(t,ha(e)),e=wi(e);return t}:xa,Me=He;(ks&&Me(new ks(new ArrayBuffer(1)))!=Bn||xr&&Me(new xr)!=St||Hs&&Me(Hs.resolve())!=io||Xn&&Me(new Xn)!=Et||Lr&&Me(new Lr)!=br)&&(Me=function(e){var t=He(e),s=t==kt?e.constructor:r,o=s?In(s):"";if(o)switch(o){case Gf:return Bn;case Qf:return St;case qf:return io;case zf:return Et;case Kf:return br}return t});function lg(e,t,s){for(var o=-1,h=s.length;++o<h;){var g=s[o],m=g.size;switch(g.type){case"drop":e+=m;break;case"dropRight":t-=m;break;case"take":t=De(t,e+m);break;case"takeRight":e=Se(e,t-m);break}}return{start:e,end:t}}function cg(e){var t=e.match(_h);return t?t[1].split(mh):[]}function Qu(e,t,s){t=an(t,e);for(var o=-1,h=t.length,g=!1;++o<h;){var m=yt(t[o]);if(!(g=e!=null&&s(e,m)))break;e=e[m]}return g||++o!=h?g:(h=e==null?0:e.length,!!h&&qi(h)&&Gt(m,h)&&(z(e)||xn(e)))}function hg(e){var t=e.length,s=new e.constructor(t);return t&&typeof e[0]=="string"&&se.call(e,"index")&&(s.index=e.index,s.input=e.input),s}function qu(e){return typeof e.constructor=="function"&&!Hr(e)?Jn(wi(e)):{}}function fg(e,t,s){var o=e.constructor;switch(t){case Ar:return ia(e);case Er:case Cr:return new o(+e);case Bn:return Yd(e,s);case cs:case hs:case fs:case ds:case gs:case ps:case _s:case ms:case vs:return Pu(e,s);case St:return new o;case Tr:case Rr:return new o(e);case yr:return Xd(e);case Et:return new o;case ai:return Zd(e)}}function dg(e,t){var s=t.length;if(!s)return e;var o=s-1;return t[o]=(s>1?"& ":"")+t[o],t=t.join(s>2?", ":" "),e.replace(ph,`{
2
- /* [wrapped with `+t+`] */
3
- `)}function gg(e){return z(e)||xn(e)||!!(Zo&&e&&e[Zo])}function Gt(e,t){var s=typeof e;return t=t??oe,!!t&&(s=="number"||s!="symbol"&&Rh.test(e))&&e>-1&&e%1==0&&e<t}function We(e,t,s){if(!de(s))return!1;var o=typeof t;return(o=="number"?ze(s)&&Gt(t,s.length):o=="string"&&t in s)?Rt(s[t],e):!1}function fa(e,t){if(z(e))return!1;var s=typeof e;return s=="number"||s=="symbol"||s=="boolean"||e==null||rt(e)?!0:hh.test(e)||!ch.test(e)||t!=null&&e in le(t)}function pg(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}function da(e){var t=Fi(e),s=f[t];if(typeof s!="function"||!(t in ee.prototype))return!1;if(e===s)return!0;var o=la(s);return!!o&&e===o[0]}function _g(e){return!!zo&&zo in e}var mg=gi?Qt:La;function Hr(e){var t=e&&e.constructor,s=typeof t=="function"&&t.prototype||Yn;return e===s}function zu(e){return e===e&&!de(e)}function Ku(e,t){return function(s){return s==null?!1:s[e]===t&&(t!==r||e in le(s))}}function vg(e){var t=Gi(e,function(o){return s.size===R&&s.clear(),o}),s=t.cache;return t}function wg(e,t){var s=e[1],o=t[1],h=s|o,g=h<(W|ie|ye),m=o==ye&&s==Ie||o==ye&&s==Re&&e[7].length<=t[8]||o==(ye|Re)&&t[7].length<=t[8]&&s==Ie;if(!(g||m))return e;o&W&&(e[2]=t[2],h|=s&W?0:Oe);var v=t[3];if(v){var S=e[3];e[3]=S?xu(S,v,t[4]):v,e[4]=S?tn(e[3],T):t[4]}return v=t[5],v&&(S=e[5],e[5]=S?Lu(S,v,t[6]):v,e[6]=S?tn(e[5],T):t[6]),v=t[7],v&&(e[7]=v),o&ye&&(e[8]=e[8]==null?t[8]:De(e[8],t[8])),e[9]==null&&(e[9]=t[9]),e[0]=t[0],e[1]=h,e}function Sg(e){var t=[];if(e!=null)for(var s in le(e))t.push(s);return t}function Eg(e){return _i.call(e)}function Yu(e,t,s){return t=Se(t===r?e.length-1:t,0),function(){for(var o=arguments,h=-1,g=Se(o.length-t,0),m=y(g);++h<g;)m[h]=o[t+h];h=-1;for(var v=y(t+1);++h<t;)v[h]=o[h];return v[t]=s(m),je(e,this,v)}}function Xu(e,t){return t.length<2?e:An(e,ft(t,0,-1))}function Cg(e,t){for(var s=e.length,o=De(t.length,s),h=qe(e);o--;){var g=t[o];e[o]=Gt(g,s)?h[g]:r}return e}function ga(e,t){if(!(t==="constructor"&&typeof e[t]=="function")&&t!="__proto__")return e[t]}var Zu=ju(Su),Wr=Mf||function(e,t){return Le.setTimeout(e,t)},pa=ju(Qd);function Ju(e,t,s){var o=t+"";return pa(e,dg(o,Tg(cg(o),s)))}function ju(e){var t=0,s=0;return function(){var o=Wf(),h=wt-(o-s);if(s=o,h>0){if(++t>=Zt)return arguments[0]}else t=0;return e.apply(r,arguments)}}function Hi(e,t){var s=-1,o=e.length,h=o-1;for(t=t===r?o:t;++s<t;){var g=Zs(s,h),m=e[g];e[g]=e[s],e[s]=m}return e.length=t,e}var el=vg(function(e){var t=[];return e.charCodeAt(0)===46&&t.push(""),e.replace(fh,function(s,o,h,g){t.push(h?g.replace(wh,"$1"):o||s)}),t});function yt(e){if(typeof e=="string"||rt(e))return e;var t=e+"";return t=="0"&&1/e==-ot?"-0":t}function In(e){if(e!=null){try{return pi.call(e)}catch{}try{return e+""}catch{}}return""}function Tg(e,t){return et(Xc,function(s){var o="_."+s[0];t&s[1]&&!ci(e,o)&&e.push(o)}),e.sort()}function tl(e){if(e instanceof ee)return e.clone();var t=new ct(e.__wrapped__,e.__chain__);return t.__actions__=qe(e.__actions__),t.__index__=e.__index__,t.__values__=e.__values__,t}function yg(e,t,s){(s?We(e,t,s):t===r)?t=1:t=Se(K(t),0);var o=e==null?0:e.length;if(!o||t<1)return[];for(var h=0,g=0,m=y(Ci(o/t));h<o;)m[g++]=ft(e,h,h+=t);return m}function Rg(e){for(var t=-1,s=e==null?0:e.length,o=0,h=[];++t<s;){var g=e[t];g&&(h[o++]=g)}return h}function bg(){var e=arguments.length;if(!e)return[];for(var t=y(e-1),s=arguments[0],o=e;o--;)t[o-1]=arguments[o];return en(z(s)?qe(s):[s],Ne(t,1))}var Ag=X(function(e,t){return _e(e)?$r(e,Ne(t,1,_e,!0)):[]}),Pg=X(function(e,t){var s=dt(t);return _e(s)&&(s=r),_e(e)?$r(e,Ne(t,1,_e,!0),B(s,2)):[]}),Ig=X(function(e,t){var s=dt(t);return _e(s)&&(s=r),_e(e)?$r(e,Ne(t,1,_e,!0),r,s):[]});function xg(e,t,s){var o=e==null?0:e.length;return o?(t=s||t===r?1:K(t),ft(e,t<0?0:t,o)):[]}function Lg(e,t,s){var o=e==null?0:e.length;return o?(t=s||t===r?1:K(t),t=o-t,ft(e,0,t<0?0:t)):[]}function Ng(e,t){return e&&e.length?Ni(e,B(t,3),!0,!0):[]}function Ug(e,t){return e&&e.length?Ni(e,B(t,3),!0):[]}function Og(e,t,s,o){var h=e==null?0:e.length;return h?(s&&typeof s!="number"&&We(e,t,s)&&(s=0,o=h),bd(e,t,s,o)):[]}function nl(e,t,s){var o=e==null?0:e.length;if(!o)return-1;var h=s==null?0:K(s);return h<0&&(h=Se(o+h,0)),hi(e,B(t,3),h)}function rl(e,t,s){var o=e==null?0:e.length;if(!o)return-1;var h=o-1;return s!==r&&(h=K(s),h=s<0?Se(o+h,0):De(h,o-1)),hi(e,B(t,3),h,!0)}function il(e){var t=e==null?0:e.length;return t?Ne(e,1):[]}function $g(e){var t=e==null?0:e.length;return t?Ne(e,ot):[]}function Dg(e,t){var s=e==null?0:e.length;return s?(t=t===r?1:K(t),Ne(e,t)):[]}function Mg(e){for(var t=-1,s=e==null?0:e.length,o={};++t<s;){var h=e[t];Nt(o,h[0],h[1])}return o}function sl(e){return e&&e.length?e[0]:r}function Fg(e,t,s){var o=e==null?0:e.length;if(!o)return-1;var h=s==null?0:K(s);return h<0&&(h=Se(o+h,0)),Qn(e,t,h)}function kg(e){var t=e==null?0:e.length;return t?ft(e,0,-1):[]}var Hg=X(function(e){var t=fe(e,na);return t.length&&t[0]===e[0]?qs(t):[]}),Wg=X(function(e){var t=dt(e),s=fe(e,na);return t===dt(s)?t=r:s.pop(),s.length&&s[0]===e[0]?qs(s,B(t,2)):[]}),Vg=X(function(e){var t=dt(e),s=fe(e,na);return t=typeof t=="function"?t:r,t&&s.pop(),s.length&&s[0]===e[0]?qs(s,r,t):[]});function Bg(e,t){return e==null?"":kf.call(e,t)}function dt(e){var t=e==null?0:e.length;return t?e[t-1]:r}function Gg(e,t,s){var o=e==null?0:e.length;if(!o)return-1;var h=o;return s!==r&&(h=K(s),h=h<0?Se(o+h,0):De(h,o-1)),t===t?Tf(e,t,h):hi(e,ko,h,!0)}function Qg(e,t){return e&&e.length?_u(e,K(t)):r}var qg=X(al);function al(e,t){return e&&e.length&&t&&t.length?Xs(e,t):e}function zg(e,t,s){return e&&e.length&&t&&t.length?Xs(e,t,B(s,2)):e}function Kg(e,t,s){return e&&e.length&&t&&t.length?Xs(e,t,r,s):e}var Yg=Bt(function(e,t){var s=e==null?0:e.length,o=Vs(e,t);return wu(e,fe(t,function(h){return Gt(h,s)?+h:h}).sort(Iu)),o});function Xg(e,t){var s=[];if(!(e&&e.length))return s;var o=-1,h=[],g=e.length;for(t=B(t,3);++o<g;){var m=e[o];t(m,o,e)&&(s.push(m),h.push(o))}return wu(e,h),s}function _a(e){return e==null?e:Bf.call(e)}function Zg(e,t,s){var o=e==null?0:e.length;return o?(s&&typeof s!="number"&&We(e,t,s)?(t=0,s=o):(t=t==null?0:K(t),s=s===r?o:K(s)),ft(e,t,s)):[]}function Jg(e,t){return Li(e,t)}function jg(e,t,s){return js(e,t,B(s,2))}function ep(e,t){var s=e==null?0:e.length;if(s){var o=Li(e,t);if(o<s&&Rt(e[o],t))return o}return-1}function tp(e,t){return Li(e,t,!0)}function np(e,t,s){return js(e,t,B(s,2),!0)}function rp(e,t){var s=e==null?0:e.length;if(s){var o=Li(e,t,!0)-1;if(Rt(e[o],t))return o}return-1}function ip(e){return e&&e.length?Eu(e):[]}function sp(e,t){return e&&e.length?Eu(e,B(t,2)):[]}function ap(e){var t=e==null?0:e.length;return t?ft(e,1,t):[]}function op(e,t,s){return e&&e.length?(t=s||t===r?1:K(t),ft(e,0,t<0?0:t)):[]}function up(e,t,s){var o=e==null?0:e.length;return o?(t=s||t===r?1:K(t),t=o-t,ft(e,t<0?0:t,o)):[]}function lp(e,t){return e&&e.length?Ni(e,B(t,3),!1,!0):[]}function cp(e,t){return e&&e.length?Ni(e,B(t,3)):[]}var hp=X(function(e){return sn(Ne(e,1,_e,!0))}),fp=X(function(e){var t=dt(e);return _e(t)&&(t=r),sn(Ne(e,1,_e,!0),B(t,2))}),dp=X(function(e){var t=dt(e);return t=typeof t=="function"?t:r,sn(Ne(e,1,_e,!0),r,t)});function gp(e){return e&&e.length?sn(e):[]}function pp(e,t){return e&&e.length?sn(e,B(t,2)):[]}function _p(e,t){return t=typeof t=="function"?t:r,e&&e.length?sn(e,r,t):[]}function ma(e){if(!(e&&e.length))return[];var t=0;return e=jt(e,function(s){if(_e(s))return t=Se(s.length,t),!0}),Os(t,function(s){return fe(e,Ls(s))})}function ol(e,t){if(!(e&&e.length))return[];var s=ma(e);return t==null?s:fe(s,function(o){return je(t,r,o)})}var mp=X(function(e,t){return _e(e)?$r(e,t):[]}),vp=X(function(e){return ta(jt(e,_e))}),wp=X(function(e){var t=dt(e);return _e(t)&&(t=r),ta(jt(e,_e),B(t,2))}),Sp=X(function(e){var t=dt(e);return t=typeof t=="function"?t:r,ta(jt(e,_e),r,t)}),Ep=X(ma);function Cp(e,t){return Ru(e||[],t||[],Or)}function Tp(e,t){return Ru(e||[],t||[],Fr)}var yp=X(function(e){var t=e.length,s=t>1?e[t-1]:r;return s=typeof s=="function"?(e.pop(),s):r,ol(e,s)});function ul(e){var t=f(e);return t.__chain__=!0,t}function Rp(e,t){return t(e),e}function Wi(e,t){return t(e)}var bp=Bt(function(e){var t=e.length,s=t?e[0]:0,o=this.__wrapped__,h=function(g){return Vs(g,e)};return t>1||this.__actions__.length||!(o instanceof ee)||!Gt(s)?this.thru(h):(o=o.slice(s,+s+(t?1:0)),o.__actions__.push({func:Wi,args:[h],thisArg:r}),new ct(o,this.__chain__).thru(function(g){return t&&!g.length&&g.push(r),g}))});function Ap(){return ul(this)}function Pp(){return new ct(this.value(),this.__chain__)}function Ip(){this.__values__===r&&(this.__values__=Cl(this.value()));var e=this.__index__>=this.__values__.length,t=e?r:this.__values__[this.__index__++];return{done:e,value:t}}function xp(){return this}function Lp(e){for(var t,s=this;s instanceof bi;){var o=tl(s);o.__index__=0,o.__values__=r,t?h.__wrapped__=o:t=o;var h=o;s=s.__wrapped__}return h.__wrapped__=e,t}function Np(){var e=this.__wrapped__;if(e instanceof ee){var t=e;return this.__actions__.length&&(t=new ee(this)),t=t.reverse(),t.__actions__.push({func:Wi,args:[_a],thisArg:r}),new ct(t,this.__chain__)}return this.thru(_a)}function Up(){return yu(this.__wrapped__,this.__actions__)}var Op=Ui(function(e,t,s){se.call(e,s)?++e[s]:Nt(e,s,1)});function $p(e,t,s){var o=z(e)?Mo:Rd;return s&&We(e,t,s)&&(t=r),o(e,B(t,3))}function Dp(e,t){var s=z(e)?jt:ou;return s(e,B(t,3))}var Mp=$u(nl),Fp=$u(rl);function kp(e,t){return Ne(Vi(e,t),1)}function Hp(e,t){return Ne(Vi(e,t),ot)}function Wp(e,t,s){return s=s===r?1:K(s),Ne(Vi(e,t),s)}function ll(e,t){var s=z(e)?et:rn;return s(e,B(t,3))}function cl(e,t){var s=z(e)?af:au;return s(e,B(t,3))}var Vp=Ui(function(e,t,s){se.call(e,s)?e[s].push(t):Nt(e,s,[t])});function Bp(e,t,s,o){e=ze(e)?e:rr(e),s=s&&!o?K(s):0;var h=e.length;return s<0&&(s=Se(h+s,0)),zi(e)?s<=h&&e.indexOf(t,s)>-1:!!h&&Qn(e,t,s)>-1}var Gp=X(function(e,t,s){var o=-1,h=typeof t=="function",g=ze(e)?y(e.length):[];return rn(e,function(m){g[++o]=h?je(t,m,s):Dr(m,t,s)}),g}),Qp=Ui(function(e,t,s){Nt(e,s,t)});function Vi(e,t){var s=z(e)?fe:du;return s(e,B(t,3))}function qp(e,t,s,o){return e==null?[]:(z(t)||(t=t==null?[]:[t]),s=o?r:s,z(s)||(s=s==null?[]:[s]),mu(e,t,s))}var zp=Ui(function(e,t,s){e[s?0:1].push(t)},function(){return[[],[]]});function Kp(e,t,s){var o=z(e)?Is:Wo,h=arguments.length<3;return o(e,B(t,4),s,h,rn)}function Yp(e,t,s){var o=z(e)?of:Wo,h=arguments.length<3;return o(e,B(t,4),s,h,au)}function Xp(e,t){var s=z(e)?jt:ou;return s(e,Qi(B(t,3)))}function Zp(e){var t=z(e)?nu:Bd;return t(e)}function Jp(e,t,s){(s?We(e,t,s):t===r)?t=1:t=K(t);var o=z(e)?Sd:Gd;return o(e,t)}function jp(e){var t=z(e)?Ed:qd;return t(e)}function e_(e){if(e==null)return 0;if(ze(e))return zi(e)?zn(e):e.length;var t=Me(e);return t==St||t==Et?e.size:Ks(e).length}function t_(e,t,s){var o=z(e)?xs:zd;return s&&We(e,t,s)&&(t=r),o(e,B(t,3))}var n_=X(function(e,t){if(e==null)return[];var s=t.length;return s>1&&We(e,t[0],t[1])?t=[]:s>2&&We(t[0],t[1],t[2])&&(t=[t[0]]),mu(e,Ne(t,1),[])}),Bi=Df||function(){return Le.Date.now()};function r_(e,t){if(typeof t!="function")throw new lt(l);return e=K(e),function(){if(--e<1)return t.apply(this,arguments)}}function hl(e,t,s){return t=s?r:t,t=e&&t==null?e.length:t,Vt(e,ye,r,r,r,r,t)}function fl(e,t){var s;if(typeof t!="function")throw new lt(l);return e=K(e),function(){return--e>0&&(s=t.apply(this,arguments)),e<=1&&(t=r),s}}var va=X(function(e,t,s){var o=W;if(s.length){var h=tn(s,tr(va));o|=xe}return Vt(e,o,t,s,h)}),dl=X(function(e,t,s){var o=W|ie;if(s.length){var h=tn(s,tr(dl));o|=xe}return Vt(t,o,e,s,h)});function gl(e,t,s){t=s?r:t;var o=Vt(e,Ie,r,r,r,r,r,t);return o.placeholder=gl.placeholder,o}function pl(e,t,s){t=s?r:t;var o=Vt(e,Qe,r,r,r,r,r,t);return o.placeholder=pl.placeholder,o}function _l(e,t,s){var o,h,g,m,v,S,P=0,I=!1,x=!1,D=!0;if(typeof e!="function")throw new lt(l);t=gt(t)||0,de(s)&&(I=!!s.leading,x="maxWait"in s,g=x?Se(gt(s.maxWait)||0,t):g,D="trailing"in s?!!s.trailing:D);function k(me){var bt=o,zt=h;return o=h=r,P=me,m=e.apply(zt,bt),m}function G(me){return P=me,v=Wr(J,t),I?k(me):m}function Y(me){var bt=me-S,zt=me-P,Dl=t-bt;return x?De(Dl,g-zt):Dl}function V(me){var bt=me-S,zt=me-P;return S===r||bt>=t||bt<0||x&&zt>=g}function J(){var me=Bi();if(V(me))return te(me);v=Wr(J,Y(me))}function te(me){return v=r,D&&o?k(me):(o=h=r,m)}function it(){v!==r&&bu(v),P=0,o=S=h=v=r}function Ve(){return v===r?m:te(Bi())}function st(){var me=Bi(),bt=V(me);if(o=arguments,h=this,S=me,bt){if(v===r)return G(S);if(x)return bu(v),v=Wr(J,t),k(S)}return v===r&&(v=Wr(J,t)),m}return st.cancel=it,st.flush=Ve,st}var i_=X(function(e,t){return su(e,1,t)}),s_=X(function(e,t,s){return su(e,gt(t)||0,s)});function a_(e){return Vt(e,ve)}function Gi(e,t){if(typeof e!="function"||t!=null&&typeof t!="function")throw new lt(l);var s=function(){var o=arguments,h=t?t.apply(this,o):o[0],g=s.cache;if(g.has(h))return g.get(h);var m=e.apply(this,o);return s.cache=g.set(h,m)||g,m};return s.cache=new(Gi.Cache||Wt),s}Gi.Cache=Wt;function Qi(e){if(typeof e!="function")throw new lt(l);return function(){var t=arguments;switch(t.length){case 0:return!e.call(this);case 1:return!e.call(this,t[0]);case 2:return!e.call(this,t[0],t[1]);case 3:return!e.call(this,t[0],t[1],t[2])}return!e.apply(this,t)}}function o_(e){return fl(2,e)}var u_=Kd(function(e,t){t=t.length==1&&z(t[0])?fe(t[0],tt(B())):fe(Ne(t,1),tt(B()));var s=t.length;return X(function(o){for(var h=-1,g=De(o.length,s);++h<g;)o[h]=t[h].call(this,o[h]);return je(e,this,o)})}),wa=X(function(e,t){var s=tn(t,tr(wa));return Vt(e,xe,r,t,s)}),ml=X(function(e,t){var s=tn(t,tr(ml));return Vt(e,Je,r,t,s)}),l_=Bt(function(e,t){return Vt(e,Re,r,r,r,t)});function c_(e,t){if(typeof e!="function")throw new lt(l);return t=t===r?t:K(t),X(e,t)}function h_(e,t){if(typeof e!="function")throw new lt(l);return t=t==null?0:Se(K(t),0),X(function(s){var o=s[t],h=on(s,0,t);return o&&en(h,o),je(e,this,h)})}function f_(e,t,s){var o=!0,h=!0;if(typeof e!="function")throw new lt(l);return de(s)&&(o="leading"in s?!!s.leading:o,h="trailing"in s?!!s.trailing:h),_l(e,t,{leading:o,maxWait:t,trailing:h})}function d_(e){return hl(e,1)}function g_(e,t){return wa(ra(t),e)}function p_(){if(!arguments.length)return[];var e=arguments[0];return z(e)?e:[e]}function __(e){return ht(e,A)}function m_(e,t){return t=typeof t=="function"?t:r,ht(e,A,t)}function v_(e){return ht(e,E|A)}function w_(e,t){return t=typeof t=="function"?t:r,ht(e,E|A,t)}function S_(e,t){return t==null||iu(e,t,Ae(t))}function Rt(e,t){return e===t||e!==e&&t!==t}var E_=Mi(Qs),C_=Mi(function(e,t){return e>=t}),xn=cu((function(){return arguments})())?cu:function(e){return ge(e)&&se.call(e,"callee")&&!Xo.call(e,"callee")},z=y.isArray,T_=Lo?tt(Lo):Ld;function ze(e){return e!=null&&qi(e.length)&&!Qt(e)}function _e(e){return ge(e)&&ze(e)}function y_(e){return e===!0||e===!1||ge(e)&&He(e)==Er}var un=Ff||La,R_=No?tt(No):Nd;function b_(e){return ge(e)&&e.nodeType===1&&!Vr(e)}function A_(e){if(e==null)return!0;if(ze(e)&&(z(e)||typeof e=="string"||typeof e.splice=="function"||un(e)||nr(e)||xn(e)))return!e.length;var t=Me(e);if(t==St||t==Et)return!e.size;if(Hr(e))return!Ks(e).length;for(var s in e)if(se.call(e,s))return!1;return!0}function P_(e,t){return Mr(e,t)}function I_(e,t,s){s=typeof s=="function"?s:r;var o=s?s(e,t):r;return o===r?Mr(e,t,r,s):!!o}function Sa(e){if(!ge(e))return!1;var t=He(e);return t==ii||t==Jc||typeof e.message=="string"&&typeof e.name=="string"&&!Vr(e)}function x_(e){return typeof e=="number"&&Jo(e)}function Qt(e){if(!de(e))return!1;var t=He(e);return t==si||t==ro||t==Zc||t==eh}function vl(e){return typeof e=="number"&&e==K(e)}function qi(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=oe}function de(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}function ge(e){return e!=null&&typeof e=="object"}var wl=Uo?tt(Uo):Od;function L_(e,t){return e===t||zs(e,t,ca(t))}function N_(e,t,s){return s=typeof s=="function"?s:r,zs(e,t,ca(t),s)}function U_(e){return Sl(e)&&e!=+e}function O_(e){if(mg(e))throw new Q(c);return hu(e)}function $_(e){return e===null}function D_(e){return e==null}function Sl(e){return typeof e=="number"||ge(e)&&He(e)==Tr}function Vr(e){if(!ge(e)||He(e)!=kt)return!1;var t=wi(e);if(t===null)return!0;var s=se.call(t,"constructor")&&t.constructor;return typeof s=="function"&&s instanceof s&&pi.call(s)==Nf}var Ea=Oo?tt(Oo):$d;function M_(e){return vl(e)&&e>=-oe&&e<=oe}var El=$o?tt($o):Dd;function zi(e){return typeof e=="string"||!z(e)&&ge(e)&&He(e)==Rr}function rt(e){return typeof e=="symbol"||ge(e)&&He(e)==ai}var nr=Do?tt(Do):Md;function F_(e){return e===r}function k_(e){return ge(e)&&Me(e)==br}function H_(e){return ge(e)&&He(e)==nh}var W_=Mi(Ys),V_=Mi(function(e,t){return e<=t});function Cl(e){if(!e)return[];if(ze(e))return zi(e)?Ct(e):qe(e);if(Ir&&e[Ir])return Sf(e[Ir]());var t=Me(e),s=t==St?Ds:t==Et?fi:rr;return s(e)}function qt(e){if(!e)return e===0?e:0;if(e=gt(e),e===ot||e===-ot){var t=e<0?-1:1;return t*ke}return e===e?e:0}function K(e){var t=qt(e),s=t%1;return t===t?s?t-s:t:0}function Tl(e){return e?bn(K(e),0,Lt):0}function gt(e){if(typeof e=="number")return e;if(rt(e))return Jt;if(de(e)){var t=typeof e.valueOf=="function"?e.valueOf():e;e=de(t)?t+"":t}if(typeof e!="string")return e===0?e:+e;e=Vo(e);var s=Ch.test(e);return s||yh.test(e)?nf(e.slice(2),s?2:8):Eh.test(e)?Jt:+e}function yl(e){return Ot(e,Ke(e))}function B_(e){return e?bn(K(e),-oe,oe):e===0?e:0}function ae(e){return e==null?"":nt(e)}var G_=jn(function(e,t){if(Hr(t)||ze(t)){Ot(t,Ae(t),e);return}for(var s in t)se.call(t,s)&&Or(e,s,t[s])}),Rl=jn(function(e,t){Ot(t,Ke(t),e)}),bl=jn(function(e,t,s,o){Ot(t,Ke(t),e,o)}),Ca=jn(function(e,t,s,o){Ot(t,Ae(t),e,o)}),Q_=Bt(Vs);function q_(e,t){var s=Jn(e);return t==null?s:ru(s,t)}var z_=X(function(e,t){e=le(e);var s=-1,o=t.length,h=o>2?t[2]:r;for(h&&We(t[0],t[1],h)&&(o=1);++s<o;)for(var g=t[s],m=Ke(g),v=-1,S=m.length;++v<S;){var P=m[v],I=e[P];(I===r||Rt(I,Yn[P])&&!se.call(e,P))&&(e[P]=g[P])}return e}),K_=X(function(e){return e.push(r,Vu),je(Al,r,e)});function Y_(e,t){return Fo(e,B(t,3),Ut)}function X_(e,t){return Fo(e,B(t,3),Gs)}function Z_(e,t){return e==null?e:Bs(e,B(t,3),Ke)}function J_(e,t){return e==null?e:uu(e,B(t,3),Ke)}function j_(e,t){return e&&Ut(e,B(t,3))}function em(e,t){return e&&Gs(e,B(t,3))}function tm(e){return e==null?[]:Ii(e,Ae(e))}function nm(e){return e==null?[]:Ii(e,Ke(e))}function Ta(e,t,s){var o=e==null?r:An(e,t);return o===r?s:o}function rm(e,t){return e!=null&&Qu(e,t,Ad)}function ya(e,t){return e!=null&&Qu(e,t,Pd)}var im=Mu(function(e,t,s){t!=null&&typeof t.toString!="function"&&(t=_i.call(t)),e[t]=s},ba(Ye)),sm=Mu(function(e,t,s){t!=null&&typeof t.toString!="function"&&(t=_i.call(t)),se.call(e,t)?e[t].push(s):e[t]=[s]},B),am=X(Dr);function Ae(e){return ze(e)?tu(e):Ks(e)}function Ke(e){return ze(e)?tu(e,!0):Fd(e)}function om(e,t){var s={};return t=B(t,3),Ut(e,function(o,h,g){Nt(s,t(o,h,g),o)}),s}function um(e,t){var s={};return t=B(t,3),Ut(e,function(o,h,g){Nt(s,h,t(o,h,g))}),s}var lm=jn(function(e,t,s){xi(e,t,s)}),Al=jn(function(e,t,s,o){xi(e,t,s,o)}),cm=Bt(function(e,t){var s={};if(e==null)return s;var o=!1;t=fe(t,function(g){return g=an(g,e),o||(o=g.length>1),g}),Ot(e,ua(e),s),o&&(s=ht(s,E|C|A,sg));for(var h=t.length;h--;)ea(s,t[h]);return s});function hm(e,t){return Pl(e,Qi(B(t)))}var fm=Bt(function(e,t){return e==null?{}:Hd(e,t)});function Pl(e,t){if(e==null)return{};var s=fe(ua(e),function(o){return[o]});return t=B(t),vu(e,s,function(o,h){return t(o,h[0])})}function dm(e,t,s){t=an(t,e);var o=-1,h=t.length;for(h||(h=1,e=r);++o<h;){var g=e==null?r:e[yt(t[o])];g===r&&(o=h,g=s),e=Qt(g)?g.call(e):g}return e}function gm(e,t,s){return e==null?e:Fr(e,t,s)}function pm(e,t,s,o){return o=typeof o=="function"?o:r,e==null?e:Fr(e,t,s,o)}var Il=Hu(Ae),xl=Hu(Ke);function _m(e,t,s){var o=z(e),h=o||un(e)||nr(e);if(t=B(t,4),s==null){var g=e&&e.constructor;h?s=o?new g:[]:de(e)?s=Qt(g)?Jn(wi(e)):{}:s={}}return(h?et:Ut)(e,function(m,v,S){return t(s,m,v,S)}),s}function mm(e,t){return e==null?!0:ea(e,t)}function vm(e,t,s){return e==null?e:Tu(e,t,ra(s))}function wm(e,t,s,o){return o=typeof o=="function"?o:r,e==null?e:Tu(e,t,ra(s),o)}function rr(e){return e==null?[]:$s(e,Ae(e))}function Sm(e){return e==null?[]:$s(e,Ke(e))}function Em(e,t,s){return s===r&&(s=t,t=r),s!==r&&(s=gt(s),s=s===s?s:0),t!==r&&(t=gt(t),t=t===t?t:0),bn(gt(e),t,s)}function Cm(e,t,s){return t=qt(t),s===r?(s=t,t=0):s=qt(s),e=gt(e),Id(e,t,s)}function Tm(e,t,s){if(s&&typeof s!="boolean"&&We(e,t,s)&&(t=s=r),s===r&&(typeof t=="boolean"?(s=t,t=r):typeof e=="boolean"&&(s=e,e=r)),e===r&&t===r?(e=0,t=1):(e=qt(e),t===r?(t=e,e=0):t=qt(t)),e>t){var o=e;e=t,t=o}if(s||e%1||t%1){var h=jo();return De(e+h*(t-e+tf("1e-"+((h+"").length-1))),t)}return Zs(e,t)}var ym=er(function(e,t,s){return t=t.toLowerCase(),e+(s?Ll(t):t)});function Ll(e){return Ra(ae(e).toLowerCase())}function Nl(e){return e=ae(e),e&&e.replace(bh,pf).replace(Qh,"")}function Rm(e,t,s){e=ae(e),t=nt(t);var o=e.length;s=s===r?o:bn(K(s),0,o);var h=s;return s-=t.length,s>=0&&e.slice(s,h)==t}function bm(e){return e=ae(e),e&&oh.test(e)?e.replace(ao,_f):e}function Am(e){return e=ae(e),e&&dh.test(e)?e.replace(ws,"\\$&"):e}var Pm=er(function(e,t,s){return e+(s?"-":"")+t.toLowerCase()}),Im=er(function(e,t,s){return e+(s?" ":"")+t.toLowerCase()}),xm=Ou("toLowerCase");function Lm(e,t,s){e=ae(e),t=K(t);var o=t?zn(e):0;if(!t||o>=t)return e;var h=(t-o)/2;return Di(Ti(h),s)+e+Di(Ci(h),s)}function Nm(e,t,s){e=ae(e),t=K(t);var o=t?zn(e):0;return t&&o<t?e+Di(t-o,s):e}function Um(e,t,s){e=ae(e),t=K(t);var o=t?zn(e):0;return t&&o<t?Di(t-o,s)+e:e}function Om(e,t,s){return s||t==null?t=0:t&&(t=+t),Vf(ae(e).replace(Ss,""),t||0)}function $m(e,t,s){return(s?We(e,t,s):t===r)?t=1:t=K(t),Js(ae(e),t)}function Dm(){var e=arguments,t=ae(e[0]);return e.length<3?t:t.replace(e[1],e[2])}var Mm=er(function(e,t,s){return e+(s?"_":"")+t.toLowerCase()});function Fm(e,t,s){return s&&typeof s!="number"&&We(e,t,s)&&(t=s=r),s=s===r?Lt:s>>>0,s?(e=ae(e),e&&(typeof t=="string"||t!=null&&!Ea(t))&&(t=nt(t),!t&&qn(e))?on(Ct(e),0,s):e.split(t,s)):[]}var km=er(function(e,t,s){return e+(s?" ":"")+Ra(t)});function Hm(e,t,s){return e=ae(e),s=s==null?0:bn(K(s),0,e.length),t=nt(t),e.slice(s,s+t.length)==t}function Wm(e,t,s){var o=f.templateSettings;s&&We(e,t,s)&&(t=r),e=ae(e),t=Ca({},t,o,Wu);var h=Ca({},t.imports,o.imports,Wu),g=Ae(h),m=$s(h,g);et(g,function(V){if(uo.test(V))throw new Q(p)});var v,S,P=0,I=t.interpolate||oi,x="__p += '",D=Ms((t.escape||oi).source+"|"+I.source+"|"+(I===oo?Sh:oi).source+"|"+(t.evaluate||oi).source+"|$","g"),k="//# sourceURL="+(se.call(t,"sourceURL")?(t.sourceURL+"").replace(/\s/g," "):"lodash.templateSources["+ ++Xh+"]")+`
4
- `;e.replace(D,function(V,J,te,it,Ve,st){return te||(te=it),x+=e.slice(P,st).replace(Ah,mf),J&&(v=!0,x+=`' +
5
- __e(`+J+`) +
6
- '`),Ve&&(S=!0,x+=`';
7
- `+Ve+`;
8
- __p += '`),te&&(x+=`' +
9
- ((__t = (`+te+`)) == null ? '' : __t) +
10
- '`),P=st+V.length,V}),x+=`';
11
- `;var G=se.call(t,"variable")&&t.variable;if(!G)x=`with (obj) {
12
- `+x+`
1
+ class nE{constructor(t){this.$subscribers=new Set,this.$value=t}set(t){this.$value=t,this.$subscribers.forEach(n=>{n(t)})}update(t){this.set(t(this.$value))}subscribe(t){return this.$subscribers.add(t),t(this.$value),()=>{this.$subscribers.delete(t)}}}function Bh(r){return r.$value}function ka(r){return new nE(r)}var ya=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},as={exports:{}};var rE=as.exports,ah;function iE(){return ah||(ah=1,(function(r,t){(function(){var n,s="4.18.1",a=200,l="Unsupported core-js use. Try https://npms.io/search?q=ponyfill.",u="Expected a function",f="Invalid `variable` option passed into `_.template`",h="Invalid `imports` option passed into `_.template`",g="__lodash_hash_undefined__",_=500,w="__lodash_placeholder__",m=1,E=2,b=4,R=1,I=2,N=1,$=2,J=4,de=8,_e=16,pe=32,oe=64,me=128,Re=256,ae=512,ut=30,ct="...",jt=800,W=16,Gn=1,mr=2,wt=3,Xe=1/0,St=9007199254740991,Yr=17976931348623157e292,O=NaN,Ae=4294967295,ne=Ae-1,ze=Ae>>>1,dn=[["ary",me],["bind",N],["bindKey",$],["curry",de],["curryRight",_e],["flip",ae],["partial",pe],["partialRight",oe],["rearg",Re]],Lt="[object Arguments]",yt="[object Array]",wr="[object AsyncFunction]",Rn="[object Boolean]",Sr="[object Date]",Nt="[object DOMException]",yr="[object Error]",An="[object Function]",Ru="[object GeneratorFunction]",Yt="[object Map]",Hi="[object Number]",yg="[object Null]",Pn="[object Object]",Au="[object Promise]",Eg="[object Proxy]",Vi="[object RegExp]",Jt="[object Set]",Wi="[object String]",Os="[object Symbol]",Cg="[object Undefined]",Bi="[object WeakMap]",bg="[object WeakSet]",Gi="[object ArrayBuffer]",Jr="[object DataView]",Xa="[object Float32Array]",Za="[object Float64Array]",eo="[object Int8Array]",to="[object Int16Array]",no="[object Int32Array]",ro="[object Uint8Array]",io="[object Uint8ClampedArray]",so="[object Uint16Array]",ao="[object Uint32Array]",Tg=/\b__p \+= '';/g,Rg=/\b(__p \+=) '' \+/g,Ag=/(__e\(.*?\)|\b__t\)) \+\n'';/g,Pu=/&(?:amp|lt|gt|quot|#39);/g,Iu=/[&<>"']/g,Pg=RegExp(Pu.source),Ig=RegExp(Iu.source),xg=/<%-([\s\S]+?)%>/g,Lg=/<%([\s\S]+?)%>/g,xu=/<%=([\s\S]+?)%>/g,Ng=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,Og=/^\w*$/,Ug=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,oo=/[\\^$.*+?()[\]{}|]/g,Dg=RegExp(oo.source),lo=/^\s+/,Mg=/\s/,kg=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,$g=/\{\n\/\* \[wrapped with (.+)\] \*/,Fg=/,? & /,Hg=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,Lu=/[()=,{}\[\]\/\s]/,Vg=/\\(\\)?/g,Wg=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,Nu=/\w*$/,Bg=/^[-+]0x[0-9a-f]+$/i,Gg=/^0b[01]+$/i,Qg=/^\[object .+?Constructor\]$/,qg=/^0o[0-7]+$/i,zg=/^(?:0|[1-9]\d*)$/,Kg=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,Us=/($^)/,jg=/['\n\r\u2028\u2029\\]/g,Ds="\\ud800-\\udfff",Yg="\\u0300-\\u036f",Jg="\\ufe20-\\ufe2f",Xg="\\u20d0-\\u20ff",Ou=Yg+Jg+Xg,Uu="\\u2700-\\u27bf",Du="a-z\\xdf-\\xf6\\xf8-\\xff",Zg="\\xac\\xb1\\xd7\\xf7",ep="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",tp="\\u2000-\\u206f",np=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",Mu="A-Z\\xc0-\\xd6\\xd8-\\xde",ku="\\ufe0e\\ufe0f",$u=Zg+ep+tp+np,uo="['’]",rp="["+Ds+"]",Fu="["+$u+"]",Ms="["+Ou+"]",Hu="\\d+",ip="["+Uu+"]",Vu="["+Du+"]",Wu="[^"+Ds+$u+Hu+Uu+Du+Mu+"]",co="\\ud83c[\\udffb-\\udfff]",sp="(?:"+Ms+"|"+co+")",Bu="[^"+Ds+"]",fo="(?:\\ud83c[\\udde6-\\uddff]){2}",ho="[\\ud800-\\udbff][\\udc00-\\udfff]",Xr="["+Mu+"]",Gu="\\u200d",Qu="(?:"+Vu+"|"+Wu+")",ap="(?:"+Xr+"|"+Wu+")",qu="(?:"+uo+"(?:d|ll|m|re|s|t|ve))?",zu="(?:"+uo+"(?:D|LL|M|RE|S|T|VE))?",Ku=sp+"?",ju="["+ku+"]?",op="(?:"+Gu+"(?:"+[Bu,fo,ho].join("|")+")"+ju+Ku+")*",lp="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",up="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",Yu=ju+Ku+op,cp="(?:"+[ip,fo,ho].join("|")+")"+Yu,fp="(?:"+[Bu+Ms+"?",Ms,fo,ho,rp].join("|")+")",hp=RegExp(uo,"g"),dp=RegExp(Ms,"g"),go=RegExp(co+"(?="+co+")|"+fp+Yu,"g"),gp=RegExp([Xr+"?"+Vu+"+"+qu+"(?="+[Fu,Xr,"$"].join("|")+")",ap+"+"+zu+"(?="+[Fu,Xr+Qu,"$"].join("|")+")",Xr+"?"+Qu+"+"+qu,Xr+"+"+zu,up,lp,Hu,cp].join("|"),"g"),pp=RegExp("["+Gu+Ds+Ou+ku+"]"),vp=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,_p=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],mp=-1,Pe={};Pe[Xa]=Pe[Za]=Pe[eo]=Pe[to]=Pe[no]=Pe[ro]=Pe[io]=Pe[so]=Pe[ao]=!0,Pe[Lt]=Pe[yt]=Pe[Gi]=Pe[Rn]=Pe[Jr]=Pe[Sr]=Pe[yr]=Pe[An]=Pe[Yt]=Pe[Hi]=Pe[Pn]=Pe[Vi]=Pe[Jt]=Pe[Wi]=Pe[Bi]=!1;var Te={};Te[Lt]=Te[yt]=Te[Gi]=Te[Jr]=Te[Rn]=Te[Sr]=Te[Xa]=Te[Za]=Te[eo]=Te[to]=Te[no]=Te[Yt]=Te[Hi]=Te[Pn]=Te[Vi]=Te[Jt]=Te[Wi]=Te[Os]=Te[ro]=Te[io]=Te[so]=Te[ao]=!0,Te[yr]=Te[An]=Te[Bi]=!1;var wp={À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",Ç:"C",ç:"c",Ð:"D",ð:"d",È:"E",É:"E",Ê:"E",Ë:"E",è:"e",é:"e",ê:"e",ë:"e",Ì:"I",Í:"I",Î:"I",Ï:"I",ì:"i",í:"i",î:"i",ï:"i",Ñ:"N",ñ:"n",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ù:"U",Ú:"U",Û:"U",Ü:"U",ù:"u",ú:"u",û:"u",ü:"u",Ý:"Y",ý:"y",ÿ:"y",Æ:"Ae",æ:"ae",Þ:"Th",þ:"th",ß:"ss",Ā:"A",Ă:"A",Ą:"A",ā:"a",ă:"a",ą:"a",Ć:"C",Ĉ:"C",Ċ:"C",Č:"C",ć:"c",ĉ:"c",ċ:"c",č:"c",Ď:"D",Đ:"D",ď:"d",đ:"d",Ē:"E",Ĕ:"E",Ė:"E",Ę:"E",Ě:"E",ē:"e",ĕ:"e",ė:"e",ę:"e",ě:"e",Ĝ:"G",Ğ:"G",Ġ:"G",Ģ:"G",ĝ:"g",ğ:"g",ġ:"g",ģ:"g",Ĥ:"H",Ħ:"H",ĥ:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Į:"I",İ:"I",ĩ:"i",ī:"i",ĭ:"i",į:"i",ı:"i",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",ĸ:"k",Ĺ:"L",Ļ:"L",Ľ:"L",Ŀ:"L",Ł:"L",ĺ:"l",ļ:"l",ľ:"l",ŀ:"l",ł:"l",Ń:"N",Ņ:"N",Ň:"N",Ŋ:"N",ń:"n",ņ:"n",ň:"n",ŋ:"n",Ō:"O",Ŏ:"O",Ő:"O",ō:"o",ŏ:"o",ő:"o",Ŕ:"R",Ŗ:"R",Ř:"R",ŕ:"r",ŗ:"r",ř:"r",Ś:"S",Ŝ:"S",Ş:"S",Š:"S",ś:"s",ŝ:"s",ş:"s",š:"s",Ţ:"T",Ť:"T",Ŧ:"T",ţ:"t",ť:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Ů:"U",Ű:"U",Ų:"U",ũ:"u",ū:"u",ŭ:"u",ů:"u",ű:"u",ų:"u",Ŵ:"W",ŵ:"w",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Ź:"Z",Ż:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",IJ:"IJ",ij:"ij",Œ:"Oe",œ:"oe",ʼn:"'n",ſ:"s"},Sp={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"},yp={"&amp;":"&","&lt;":"<","&gt;":">","&quot;":'"',"&#39;":"'"},Ep={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},Cp=parseFloat,bp=parseInt,Ju=typeof ya=="object"&&ya&&ya.Object===Object&&ya,Tp=typeof self=="object"&&self&&self.Object===Object&&self,Ke=Ju||Tp||Function("return this")(),po=t&&!t.nodeType&&t,Er=po&&!0&&r&&!r.nodeType&&r,Xu=Er&&Er.exports===po,vo=Xu&&Ju.process,Ot=(function(){try{var C=Er&&Er.require&&Er.require("util").types;return C||vo&&vo.binding&&vo.binding("util")}catch{}})(),Zu=Ot&&Ot.isArrayBuffer,ec=Ot&&Ot.isDate,tc=Ot&&Ot.isMap,nc=Ot&&Ot.isRegExp,rc=Ot&&Ot.isSet,ic=Ot&&Ot.isTypedArray;function Et(C,P,A){switch(A.length){case 0:return C.call(P);case 1:return C.call(P,A[0]);case 2:return C.call(P,A[0],A[1]);case 3:return C.call(P,A[0],A[1],A[2])}return C.apply(P,A)}function Rp(C,P,A,V){for(var Y=-1,ve=C==null?0:C.length;++Y<ve;){var Ve=C[Y];P(V,Ve,A(Ve),C)}return V}function Ct(C,P){for(var A=-1,V=C==null?0:C.length;++A<V&&P(C[A],A,C)!==!1;);return C}function Ap(C,P){for(var A=C==null?0:C.length;A--&&P(C[A],A,C)!==!1;);return C}function sc(C,P){for(var A=-1,V=C==null?0:C.length;++A<V;)if(!P(C[A],A,C))return!1;return!0}function Qn(C,P){for(var A=-1,V=C==null?0:C.length,Y=0,ve=[];++A<V;){var Ve=C[A];P(Ve,A,C)&&(ve[Y++]=Ve)}return ve}function ks(C,P){var A=C==null?0:C.length;return!!A&&Zr(C,P,0)>-1}function _o(C,P,A){for(var V=-1,Y=C==null?0:C.length;++V<Y;)if(A(P,C[V]))return!0;return!1}function xe(C,P){for(var A=-1,V=C==null?0:C.length,Y=Array(V);++A<V;)Y[A]=P(C[A],A,C);return Y}function qn(C,P){for(var A=-1,V=P.length,Y=C.length;++A<V;)C[Y+A]=P[A];return C}function mo(C,P,A,V){var Y=-1,ve=C==null?0:C.length;for(V&&ve&&(A=C[++Y]);++Y<ve;)A=P(A,C[Y],Y,C);return A}function Pp(C,P,A,V){var Y=C==null?0:C.length;for(V&&Y&&(A=C[--Y]);Y--;)A=P(A,C[Y],Y,C);return A}function wo(C,P){for(var A=-1,V=C==null?0:C.length;++A<V;)if(P(C[A],A,C))return!0;return!1}var Ip=So("length");function xp(C){return C.split("")}function Lp(C){return C.match(Hg)||[]}function ac(C,P,A){var V;return A(C,function(Y,ve,Ve){if(P(Y,ve,Ve))return V=ve,!1}),V}function $s(C,P,A,V){for(var Y=C.length,ve=A+(V?1:-1);V?ve--:++ve<Y;)if(P(C[ve],ve,C))return ve;return-1}function Zr(C,P,A){return P===P?Bp(C,P,A):$s(C,oc,A)}function Np(C,P,A,V){for(var Y=A-1,ve=C.length;++Y<ve;)if(V(C[Y],P))return Y;return-1}function oc(C){return C!==C}function lc(C,P){var A=C==null?0:C.length;return A?Eo(C,P)/A:O}function So(C){return function(P){return P==null?n:P[C]}}function yo(C){return function(P){return C==null?n:C[P]}}function uc(C,P,A,V,Y){return Y(C,function(ve,Ve,Ce){A=V?(V=!1,ve):P(A,ve,Ve,Ce)}),A}function Op(C,P){var A=C.length;for(C.sort(P);A--;)C[A]=C[A].value;return C}function Eo(C,P){for(var A,V=-1,Y=C.length;++V<Y;){var ve=P(C[V]);ve!==n&&(A=A===n?ve:A+ve)}return A}function Co(C,P){for(var A=-1,V=Array(C);++A<C;)V[A]=P(A);return V}function Up(C,P){return xe(P,function(A){return[A,C[A]]})}function cc(C){return C&&C.slice(0,gc(C)+1).replace(lo,"")}function bt(C){return function(P){return C(P)}}function bo(C,P){return xe(P,function(A){return C[A]})}function Qi(C,P){return C.has(P)}function fc(C,P){for(var A=-1,V=C.length;++A<V&&Zr(P,C[A],0)>-1;);return A}function hc(C,P){for(var A=C.length;A--&&Zr(P,C[A],0)>-1;);return A}function Dp(C,P){for(var A=C.length,V=0;A--;)C[A]===P&&++V;return V}var Mp=yo(wp),kp=yo(Sp);function $p(C){return"\\"+Ep[C]}function Fp(C,P){return C==null?n:C[P]}function ei(C){return pp.test(C)}function Hp(C){return vp.test(C)}function Vp(C){for(var P,A=[];!(P=C.next()).done;)A.push(P.value);return A}function To(C){var P=-1,A=Array(C.size);return C.forEach(function(V,Y){A[++P]=[Y,V]}),A}function dc(C,P){return function(A){return C(P(A))}}function zn(C,P){for(var A=-1,V=C.length,Y=0,ve=[];++A<V;){var Ve=C[A];(Ve===P||Ve===w)&&(C[A]=w,ve[Y++]=A)}return ve}function Fs(C){var P=-1,A=Array(C.size);return C.forEach(function(V){A[++P]=V}),A}function Wp(C){var P=-1,A=Array(C.size);return C.forEach(function(V){A[++P]=[V,V]}),A}function Bp(C,P,A){for(var V=A-1,Y=C.length;++V<Y;)if(C[V]===P)return V;return-1}function Gp(C,P,A){for(var V=A+1;V--;)if(C[V]===P)return V;return V}function ti(C){return ei(C)?qp(C):Ip(C)}function Xt(C){return ei(C)?zp(C):xp(C)}function gc(C){for(var P=C.length;P--&&Mg.test(C.charAt(P)););return P}var Qp=yo(yp);function qp(C){for(var P=go.lastIndex=0;go.test(C);)++P;return P}function zp(C){return C.match(go)||[]}function Kp(C){return C.match(gp)||[]}var jp=(function C(P){P=P==null?Ke:ni.defaults(Ke.Object(),P,ni.pick(Ke,_p));var A=P.Array,V=P.Date,Y=P.Error,ve=P.Function,Ve=P.Math,Ce=P.Object,Ro=P.RegExp,Yp=P.String,Ut=P.TypeError,Hs=A.prototype,Jp=ve.prototype,ri=Ce.prototype,Vs=P["__core-js_shared__"],Ws=Jp.toString,we=ri.hasOwnProperty,Xp=0,pc=(function(){var e=/[^.]+$/.exec(Vs&&Vs.keys&&Vs.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""})(),Bs=ri.toString,Zp=Ws.call(Ce),ev=Ke._,tv=Ro("^"+Ws.call(we).replace(oo,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),Gs=Xu?P.Buffer:n,Kn=P.Symbol,Qs=P.Uint8Array,vc=Gs?Gs.allocUnsafe:n,qs=dc(Ce.getPrototypeOf,Ce),_c=Ce.create,mc=ri.propertyIsEnumerable,zs=Hs.splice,wc=Kn?Kn.isConcatSpreadable:n,qi=Kn?Kn.iterator:n,Cr=Kn?Kn.toStringTag:n,Ks=(function(){try{var e=Pr(Ce,"defineProperty");return e({},"",{}),e}catch{}})(),nv=P.clearTimeout!==Ke.clearTimeout&&P.clearTimeout,rv=V&&V.now!==Ke.Date.now&&V.now,iv=P.setTimeout!==Ke.setTimeout&&P.setTimeout,js=Ve.ceil,Ys=Ve.floor,Ao=Ce.getOwnPropertySymbols,sv=Gs?Gs.isBuffer:n,Sc=P.isFinite,av=Hs.join,ov=dc(Ce.keys,Ce),We=Ve.max,Ze=Ve.min,lv=V.now,uv=P.parseInt,yc=Ve.random,cv=Hs.reverse,Po=Pr(P,"DataView"),zi=Pr(P,"Map"),Io=Pr(P,"Promise"),ii=Pr(P,"Set"),Ki=Pr(P,"WeakMap"),ji=Pr(Ce,"create"),Js=Ki&&new Ki,si={},fv=Ir(Po),hv=Ir(zi),dv=Ir(Io),gv=Ir(ii),pv=Ir(Ki),Xs=Kn?Kn.prototype:n,Yi=Xs?Xs.valueOf:n,Ec=Xs?Xs.toString:n;function p(e){if(De(e)&&!X(e)&&!(e instanceof ce)){if(e instanceof Dt)return e;if(we.call(e,"__wrapped__"))return bf(e)}return new Dt(e)}var ai=(function(){function e(){}return function(i){if(!Ne(i))return{};if(_c)return _c(i);e.prototype=i;var o=new e;return e.prototype=n,o}})();function Zs(){}function Dt(e,i){this.__wrapped__=e,this.__actions__=[],this.__chain__=!!i,this.__index__=0,this.__values__=n}p.templateSettings={escape:xg,evaluate:Lg,interpolate:xu,variable:"",imports:{_:p}},p.prototype=Zs.prototype,p.prototype.constructor=p,Dt.prototype=ai(Zs.prototype),Dt.prototype.constructor=Dt;function ce(e){this.__wrapped__=e,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=Ae,this.__views__=[]}function vv(){var e=new ce(this.__wrapped__);return e.__actions__=ft(this.__actions__),e.__dir__=this.__dir__,e.__filtered__=this.__filtered__,e.__iteratees__=ft(this.__iteratees__),e.__takeCount__=this.__takeCount__,e.__views__=ft(this.__views__),e}function _v(){if(this.__filtered__){var e=new ce(this);e.__dir__=-1,e.__filtered__=!0}else e=this.clone(),e.__dir__*=-1;return e}function mv(){var e=this.__wrapped__.value(),i=this.__dir__,o=X(e),c=i<0,d=o?e.length:0,v=x_(0,d,this.__views__),S=v.start,y=v.end,T=y-S,x=c?y:S-1,L=this.__iteratees__,U=L.length,F=0,B=Ze(T,this.__takeCount__);if(!o||!c&&d==T&&B==T)return qc(e,this.__actions__);var K=[];e:for(;T--&&F<B;){x+=i;for(var ie=-1,Q=e[x];++ie<U;){var le=L[ie],he=le.iteratee,At=le.type,at=he(Q);if(At==mr)Q=at;else if(!at){if(At==Gn)continue e;break e}}K[F++]=Q}return K}ce.prototype=ai(Zs.prototype),ce.prototype.constructor=ce;function br(e){var i=-1,o=e==null?0:e.length;for(this.clear();++i<o;){var c=e[i];this.set(c[0],c[1])}}function wv(){this.__data__=ji?ji(null):{},this.size=0}function Sv(e){var i=this.has(e)&&delete this.__data__[e];return this.size-=i?1:0,i}function yv(e){var i=this.__data__;if(ji){var o=i[e];return o===g?n:o}return we.call(i,e)?i[e]:n}function Ev(e){var i=this.__data__;return ji?i[e]!==n:we.call(i,e)}function Cv(e,i){var o=this.__data__;return this.size+=this.has(e)?0:1,o[e]=ji&&i===n?g:i,this}br.prototype.clear=wv,br.prototype.delete=Sv,br.prototype.get=yv,br.prototype.has=Ev,br.prototype.set=Cv;function In(e){var i=-1,o=e==null?0:e.length;for(this.clear();++i<o;){var c=e[i];this.set(c[0],c[1])}}function bv(){this.__data__=[],this.size=0}function Tv(e){var i=this.__data__,o=ea(i,e);if(o<0)return!1;var c=i.length-1;return o==c?i.pop():zs.call(i,o,1),--this.size,!0}function Rv(e){var i=this.__data__,o=ea(i,e);return o<0?n:i[o][1]}function Av(e){return ea(this.__data__,e)>-1}function Pv(e,i){var o=this.__data__,c=ea(o,e);return c<0?(++this.size,o.push([e,i])):o[c][1]=i,this}In.prototype.clear=bv,In.prototype.delete=Tv,In.prototype.get=Rv,In.prototype.has=Av,In.prototype.set=Pv;function xn(e){var i=-1,o=e==null?0:e.length;for(this.clear();++i<o;){var c=e[i];this.set(c[0],c[1])}}function Iv(){this.size=0,this.__data__={hash:new br,map:new(zi||In),string:new br}}function xv(e){var i=ha(this,e).delete(e);return this.size-=i?1:0,i}function Lv(e){return ha(this,e).get(e)}function Nv(e){return ha(this,e).has(e)}function Ov(e,i){var o=ha(this,e),c=o.size;return o.set(e,i),this.size+=o.size==c?0:1,this}xn.prototype.clear=Iv,xn.prototype.delete=xv,xn.prototype.get=Lv,xn.prototype.has=Nv,xn.prototype.set=Ov;function Tr(e){var i=-1,o=e==null?0:e.length;for(this.__data__=new xn;++i<o;)this.add(e[i])}function Uv(e){return this.__data__.set(e,g),this}function Dv(e){return this.__data__.has(e)}Tr.prototype.add=Tr.prototype.push=Uv,Tr.prototype.has=Dv;function Zt(e){var i=this.__data__=new In(e);this.size=i.size}function Mv(){this.__data__=new In,this.size=0}function kv(e){var i=this.__data__,o=i.delete(e);return this.size=i.size,o}function $v(e){return this.__data__.get(e)}function Fv(e){return this.__data__.has(e)}function Hv(e,i){var o=this.__data__;if(o instanceof In){var c=o.__data__;if(!zi||c.length<a-1)return c.push([e,i]),this.size=++o.size,this;o=this.__data__=new xn(c)}return o.set(e,i),this.size=o.size,this}Zt.prototype.clear=Mv,Zt.prototype.delete=kv,Zt.prototype.get=$v,Zt.prototype.has=Fv,Zt.prototype.set=Hv;function Cc(e,i){var o=X(e),c=!o&&xr(e),d=!o&&!c&&Zn(e),v=!o&&!c&&!d&&ci(e),S=o||c||d||v,y=S?Co(e.length,Yp):[],T=y.length;for(var x in e)(i||we.call(e,x))&&!(S&&(x=="length"||d&&(x=="offset"||x=="parent")||v&&(x=="buffer"||x=="byteLength"||x=="byteOffset")||On(x,T)))&&y.push(x);return y}function bc(e){var i=e.length;return i?e[Ho(0,i-1)]:n}function Vv(e,i){return da(ft(e),Rr(i,0,e.length))}function Wv(e){return da(ft(e))}function xo(e,i,o){(o!==n&&!tn(e[i],o)||o===n&&!(i in e))&&gn(e,i,o)}function Ji(e,i,o){var c=e[i];(!(we.call(e,i)&&tn(c,o))||o===n&&!(i in e))&&gn(e,i,o)}function ea(e,i){for(var o=e.length;o--;)if(tn(e[o][0],i))return o;return-1}function Bv(e,i,o,c){return jn(e,function(d,v,S){i(c,d,o(d),S)}),c}function Tc(e,i){return e&&vn(i,Be(i),e)}function Gv(e,i){return e&&vn(i,dt(i),e)}function gn(e,i,o){i=="__proto__"&&Ks?Ks(e,i,{configurable:!0,enumerable:!0,value:o,writable:!0}):e[i]=o}function Lo(e,i){for(var o=-1,c=i.length,d=A(c),v=e==null;++o<c;)d[o]=v?n:hl(e,i[o]);return d}function Rr(e,i,o){return e===e&&(o!==n&&(e=e<=o?e:o),i!==n&&(e=e>=i?e:i)),e}function Mt(e,i,o,c,d,v){var S,y=i&m,T=i&E,x=i&b;if(o&&(S=d?o(e,c,d,v):o(e)),S!==n)return S;if(!Ne(e))return e;var L=X(e);if(L){if(S=N_(e),!y)return ft(e,S)}else{var U=et(e),F=U==An||U==Ru;if(Zn(e))return jc(e,y);if(U==Pn||U==Lt||F&&!d){if(S=T||F?{}:pf(e),!y)return T?y_(e,Gv(S,e)):S_(e,Tc(S,e))}else{if(!Te[U])return d?e:{};S=O_(e,U,y)}}v||(v=new Zt);var B=v.get(e);if(B)return B;v.set(e,S),Gf(e)?e.forEach(function(Q){S.add(Mt(Q,i,o,Q,e,v))}):Wf(e)&&e.forEach(function(Q,le){S.set(le,Mt(Q,i,o,le,e,v))});var K=x?T?Jo:Yo:T?dt:Be,ie=L?n:K(e);return Ct(ie||e,function(Q,le){ie&&(le=Q,Q=e[le]),Ji(S,le,Mt(Q,i,o,le,e,v))}),S}function Qv(e){var i=Be(e);return function(o){return Rc(o,e,i)}}function Rc(e,i,o){var c=o.length;if(e==null)return!c;for(e=Ce(e);c--;){var d=o[c],v=i[d],S=e[d];if(S===n&&!(d in e)||!v(S))return!1}return!0}function Ac(e,i,o){if(typeof e!="function")throw new Ut(u);return is(function(){e.apply(n,o)},i)}function Xi(e,i,o,c){var d=-1,v=ks,S=!0,y=e.length,T=[],x=i.length;if(!y)return T;o&&(i=xe(i,bt(o))),c?(v=_o,S=!1):i.length>=a&&(v=Qi,S=!1,i=new Tr(i));e:for(;++d<y;){var L=e[d],U=o==null?L:o(L);if(L=c||L!==0?L:0,S&&U===U){for(var F=x;F--;)if(i[F]===U)continue e;T.push(L)}else v(i,U,c)||T.push(L)}return T}var jn=ef(pn),Pc=ef(Oo,!0);function qv(e,i){var o=!0;return jn(e,function(c,d,v){return o=!!i(c,d,v),o}),o}function ta(e,i,o){for(var c=-1,d=e.length;++c<d;){var v=e[c],S=i(v);if(S!=null&&(y===n?S===S&&!Rt(S):o(S,y)))var y=S,T=v}return T}function zv(e,i,o,c){var d=e.length;for(o=re(o),o<0&&(o=-o>d?0:d+o),c=c===n||c>d?d:re(c),c<0&&(c+=d),c=o>c?0:qf(c);o<c;)e[o++]=i;return e}function Ic(e,i){var o=[];return jn(e,function(c,d,v){i(c,d,v)&&o.push(c)}),o}function je(e,i,o,c,d){var v=-1,S=e.length;for(o||(o=D_),d||(d=[]);++v<S;){var y=e[v];i>0&&o(y)?i>1?je(y,i-1,o,c,d):qn(d,y):c||(d[d.length]=y)}return d}var No=tf(),xc=tf(!0);function pn(e,i){return e&&No(e,i,Be)}function Oo(e,i){return e&&xc(e,i,Be)}function na(e,i){return Qn(i,function(o){return Un(e[o])})}function Ar(e,i){i=Jn(i,e);for(var o=0,c=i.length;e!=null&&o<c;)e=e[en(i[o++])];return o&&o==c?e:n}function Lc(e,i,o){var c=i(e);return X(e)?c:qn(c,o(e))}function it(e){return e==null?e===n?Cg:yg:Cr&&Cr in Ce(e)?I_(e):W_(e)}function Uo(e,i){return e>i}function Kv(e,i){return e!=null&&we.call(e,i)}function jv(e,i){return e!=null&&i in Ce(e)}function Yv(e,i,o){return e>=Ze(i,o)&&e<We(i,o)}function Do(e,i,o){for(var c=o?_o:ks,d=e[0].length,v=e.length,S=v,y=A(v),T=1/0,x=[];S--;){var L=e[S];S&&i&&(L=xe(L,bt(i))),T=Ze(L.length,T),y[S]=!o&&(i||d>=120&&L.length>=120)?new Tr(S&&L):n}L=e[0];var U=-1,F=y[0];e:for(;++U<d&&x.length<T;){var B=L[U],K=i?i(B):B;if(B=o||B!==0?B:0,!(F?Qi(F,K):c(x,K,o))){for(S=v;--S;){var ie=y[S];if(!(ie?Qi(ie,K):c(e[S],K,o)))continue e}F&&F.push(K),x.push(B)}}return x}function Jv(e,i,o,c){return pn(e,function(d,v,S){i(c,o(d),v,S)}),c}function Zi(e,i,o){i=Jn(i,e),e=wf(e,i);var c=e==null?e:e[en($t(i))];return c==null?n:Et(c,e,o)}function Nc(e){return De(e)&&it(e)==Lt}function Xv(e){return De(e)&&it(e)==Gi}function Zv(e){return De(e)&&it(e)==Sr}function es(e,i,o,c,d){return e===i?!0:e==null||i==null||!De(e)&&!De(i)?e!==e&&i!==i:e_(e,i,o,c,es,d)}function e_(e,i,o,c,d,v){var S=X(e),y=X(i),T=S?yt:et(e),x=y?yt:et(i);T=T==Lt?Pn:T,x=x==Lt?Pn:x;var L=T==Pn,U=x==Pn,F=T==x;if(F&&Zn(e)){if(!Zn(i))return!1;S=!0,L=!1}if(F&&!L)return v||(v=new Zt),S||ci(e)?hf(e,i,o,c,d,v):A_(e,i,T,o,c,d,v);if(!(o&R)){var B=L&&we.call(e,"__wrapped__"),K=U&&we.call(i,"__wrapped__");if(B||K){var ie=B?e.value():e,Q=K?i.value():i;return v||(v=new Zt),d(ie,Q,o,c,v)}}return F?(v||(v=new Zt),P_(e,i,o,c,d,v)):!1}function t_(e){return De(e)&&et(e)==Yt}function Mo(e,i,o,c){var d=o.length,v=d,S=!c;if(e==null)return!v;for(e=Ce(e);d--;){var y=o[d];if(S&&y[2]?y[1]!==e[y[0]]:!(y[0]in e))return!1}for(;++d<v;){y=o[d];var T=y[0],x=e[T],L=y[1];if(S&&y[2]){if(x===n&&!(T in e))return!1}else{var U=new Zt;if(c)var F=c(x,L,T,e,i,U);if(!(F===n?es(L,x,R|I,c,U):F))return!1}}return!0}function Oc(e){if(!Ne(e)||k_(e))return!1;var i=Un(e)?tv:Qg;return i.test(Ir(e))}function n_(e){return De(e)&&it(e)==Vi}function r_(e){return De(e)&&et(e)==Jt}function i_(e){return De(e)&&wa(e.length)&&!!Pe[it(e)]}function Uc(e){return typeof e=="function"?e:e==null?gt:typeof e=="object"?X(e)?kc(e[0],e[1]):Mc(e):ih(e)}function ko(e){if(!rs(e))return ov(e);var i=[];for(var o in Ce(e))we.call(e,o)&&o!="constructor"&&i.push(o);return i}function s_(e){if(!Ne(e))return V_(e);var i=rs(e),o=[];for(var c in e)c=="constructor"&&(i||!we.call(e,c))||o.push(c);return o}function $o(e,i){return e<i}function Dc(e,i){var o=-1,c=ht(e)?A(e.length):[];return jn(e,function(d,v,S){c[++o]=i(d,v,S)}),c}function Mc(e){var i=Zo(e);return i.length==1&&i[0][2]?_f(i[0][0],i[0][1]):function(o){return o===e||Mo(o,e,i)}}function kc(e,i){return tl(e)&&vf(i)?_f(en(e),i):function(o){var c=hl(o,e);return c===n&&c===i?dl(o,e):es(i,c,R|I)}}function ra(e,i,o,c,d){e!==i&&No(i,function(v,S){if(d||(d=new Zt),Ne(v))a_(e,i,S,o,ra,c,d);else{var y=c?c(rl(e,S),v,S+"",e,i,d):n;y===n&&(y=v),xo(e,S,y)}},dt)}function a_(e,i,o,c,d,v,S){var y=rl(e,o),T=rl(i,o),x=S.get(T);if(x){xo(e,o,x);return}var L=v?v(y,T,o+"",e,i,S):n,U=L===n;if(U){var F=X(T),B=!F&&Zn(T),K=!F&&!B&&ci(T);L=T,F||B||K?X(y)?L=y:ke(y)?L=ft(y):B?(U=!1,L=jc(T,!0)):K?(U=!1,L=Yc(T,!0)):L=[]:ss(T)||xr(T)?(L=y,xr(y)?L=zf(y):(!Ne(y)||Un(y))&&(L=pf(T))):U=!1}U&&(S.set(T,L),d(L,T,c,v,S),S.delete(T)),xo(e,o,L)}function $c(e,i){var o=e.length;if(o)return i+=i<0?o:0,On(i,o)?e[i]:n}function Fc(e,i,o){i.length?i=xe(i,function(v){return X(v)?function(S){return Ar(S,v.length===1?v[0]:v)}:v}):i=[gt];var c=-1;i=xe(i,bt(z()));var d=Dc(e,function(v,S,y){var T=xe(i,function(x){return x(v)});return{criteria:T,index:++c,value:v}});return Op(d,function(v,S){return w_(v,S,o)})}function o_(e,i){return Hc(e,i,function(o,c){return dl(e,c)})}function Hc(e,i,o){for(var c=-1,d=i.length,v={};++c<d;){var S=i[c],y=Ar(e,S);o(y,S)&&ts(v,Jn(S,e),y)}return v}function l_(e){return function(i){return Ar(i,e)}}function Fo(e,i,o,c){var d=c?Np:Zr,v=-1,S=i.length,y=e;for(e===i&&(i=ft(i)),o&&(y=xe(e,bt(o)));++v<S;)for(var T=0,x=i[v],L=o?o(x):x;(T=d(y,L,T,c))>-1;)y!==e&&zs.call(y,T,1),zs.call(e,T,1);return e}function Vc(e,i){for(var o=e?i.length:0,c=o-1;o--;){var d=i[o];if(o==c||d!==v){var v=d;On(d)?zs.call(e,d,1):Bo(e,d)}}return e}function Ho(e,i){return e+Ys(yc()*(i-e+1))}function u_(e,i,o,c){for(var d=-1,v=We(js((i-e)/(o||1)),0),S=A(v);v--;)S[c?v:++d]=e,e+=o;return S}function Vo(e,i){var o="";if(!e||i<1||i>St)return o;do i%2&&(o+=e),i=Ys(i/2),i&&(e+=e);while(i);return o}function se(e,i){return il(mf(e,i,gt),e+"")}function c_(e){return bc(fi(e))}function f_(e,i){var o=fi(e);return da(o,Rr(i,0,o.length))}function ts(e,i,o,c){if(!Ne(e))return e;i=Jn(i,e);for(var d=-1,v=i.length,S=v-1,y=e;y!=null&&++d<v;){var T=en(i[d]),x=o;if(T==="__proto__"||T==="constructor"||T==="prototype")return e;if(d!=S){var L=y[T];x=c?c(L,T,y):n,x===n&&(x=Ne(L)?L:On(i[d+1])?[]:{})}Ji(y,T,x),y=y[T]}return e}var Wc=Js?function(e,i){return Js.set(e,i),e}:gt,h_=Ks?function(e,i){return Ks(e,"toString",{configurable:!0,enumerable:!1,value:pl(i),writable:!0})}:gt;function d_(e){return da(fi(e))}function kt(e,i,o){var c=-1,d=e.length;i<0&&(i=-i>d?0:d+i),o=o>d?d:o,o<0&&(o+=d),d=i>o?0:o-i>>>0,i>>>=0;for(var v=A(d);++c<d;)v[c]=e[c+i];return v}function g_(e,i){var o;return jn(e,function(c,d,v){return o=i(c,d,v),!o}),!!o}function ia(e,i,o){var c=0,d=e==null?c:e.length;if(typeof i=="number"&&i===i&&d<=ze){for(;c<d;){var v=c+d>>>1,S=e[v];S!==null&&!Rt(S)&&(o?S<=i:S<i)?c=v+1:d=v}return d}return Wo(e,i,gt,o)}function Wo(e,i,o,c){var d=0,v=e==null?0:e.length;if(v===0)return 0;i=o(i);for(var S=i!==i,y=i===null,T=Rt(i),x=i===n;d<v;){var L=Ys((d+v)/2),U=o(e[L]),F=U!==n,B=U===null,K=U===U,ie=Rt(U);if(S)var Q=c||K;else x?Q=K&&(c||F):y?Q=K&&F&&(c||!B):T?Q=K&&F&&!B&&(c||!ie):B||ie?Q=!1:Q=c?U<=i:U<i;Q?d=L+1:v=L}return Ze(v,ne)}function Bc(e,i){for(var o=-1,c=e.length,d=0,v=[];++o<c;){var S=e[o],y=i?i(S):S;if(!o||!tn(y,T)){var T=y;v[d++]=S===0?0:S}}return v}function Gc(e){return typeof e=="number"?e:Rt(e)?O:+e}function Tt(e){if(typeof e=="string")return e;if(X(e))return xe(e,Tt)+"";if(Rt(e))return Ec?Ec.call(e):"";var i=e+"";return i=="0"&&1/e==-Xe?"-0":i}function Yn(e,i,o){var c=-1,d=ks,v=e.length,S=!0,y=[],T=y;if(o)S=!1,d=_o;else if(v>=a){var x=i?null:T_(e);if(x)return Fs(x);S=!1,d=Qi,T=new Tr}else T=i?[]:y;e:for(;++c<v;){var L=e[c],U=i?i(L):L;if(L=o||L!==0?L:0,S&&U===U){for(var F=T.length;F--;)if(T[F]===U)continue e;i&&T.push(U),y.push(L)}else d(T,U,o)||(T!==y&&T.push(U),y.push(L))}return y}function Bo(e,i){i=Jn(i,e);var o=-1,c=i.length;if(!c)return!0;for(;++o<c;){var d=en(i[o]);if(d==="__proto__"&&!we.call(e,"__proto__")||(d==="constructor"||d==="prototype")&&o<c-1)return!1}var v=wf(e,i);return v==null||delete v[en($t(i))]}function Qc(e,i,o,c){return ts(e,i,o(Ar(e,i)),c)}function sa(e,i,o,c){for(var d=e.length,v=c?d:-1;(c?v--:++v<d)&&i(e[v],v,e););return o?kt(e,c?0:v,c?v+1:d):kt(e,c?v+1:0,c?d:v)}function qc(e,i){var o=e;return o instanceof ce&&(o=o.value()),mo(i,function(c,d){return d.func.apply(d.thisArg,qn([c],d.args))},o)}function Go(e,i,o){var c=e.length;if(c<2)return c?Yn(e[0]):[];for(var d=-1,v=A(c);++d<c;)for(var S=e[d],y=-1;++y<c;)y!=d&&(v[d]=Xi(v[d]||S,e[y],i,o));return Yn(je(v,1),i,o)}function zc(e,i,o){for(var c=-1,d=e.length,v=i.length,S={};++c<d;){var y=c<v?i[c]:n;o(S,e[c],y)}return S}function Qo(e){return ke(e)?e:[]}function qo(e){return typeof e=="function"?e:gt}function Jn(e,i){return X(e)?e:tl(e,i)?[e]:Cf(Se(e))}var p_=se;function Xn(e,i,o){var c=e.length;return o=o===n?c:o,!i&&o>=c?e:kt(e,i,o)}var Kc=nv||function(e){return Ke.clearTimeout(e)};function jc(e,i){if(i)return e.slice();var o=e.length,c=vc?vc(o):new e.constructor(o);return e.copy(c),c}function zo(e){var i=new e.constructor(e.byteLength);return new Qs(i).set(new Qs(e)),i}function v_(e,i){var o=i?zo(e.buffer):e.buffer;return new e.constructor(o,e.byteOffset,e.byteLength)}function __(e){var i=new e.constructor(e.source,Nu.exec(e));return i.lastIndex=e.lastIndex,i}function m_(e){return Yi?Ce(Yi.call(e)):{}}function Yc(e,i){var o=i?zo(e.buffer):e.buffer;return new e.constructor(o,e.byteOffset,e.length)}function Jc(e,i){if(e!==i){var o=e!==n,c=e===null,d=e===e,v=Rt(e),S=i!==n,y=i===null,T=i===i,x=Rt(i);if(!y&&!x&&!v&&e>i||v&&S&&T&&!y&&!x||c&&S&&T||!o&&T||!d)return 1;if(!c&&!v&&!x&&e<i||x&&o&&d&&!c&&!v||y&&o&&d||!S&&d||!T)return-1}return 0}function w_(e,i,o){for(var c=-1,d=e.criteria,v=i.criteria,S=d.length,y=o.length;++c<S;){var T=Jc(d[c],v[c]);if(T){if(c>=y)return T;var x=o[c];return T*(x=="desc"?-1:1)}}return e.index-i.index}function Xc(e,i,o,c){for(var d=-1,v=e.length,S=o.length,y=-1,T=i.length,x=We(v-S,0),L=A(T+x),U=!c;++y<T;)L[y]=i[y];for(;++d<S;)(U||d<v)&&(L[o[d]]=e[d]);for(;x--;)L[y++]=e[d++];return L}function Zc(e,i,o,c){for(var d=-1,v=e.length,S=-1,y=o.length,T=-1,x=i.length,L=We(v-y,0),U=A(L+x),F=!c;++d<L;)U[d]=e[d];for(var B=d;++T<x;)U[B+T]=i[T];for(;++S<y;)(F||d<v)&&(U[B+o[S]]=e[d++]);return U}function ft(e,i){var o=-1,c=e.length;for(i||(i=A(c));++o<c;)i[o]=e[o];return i}function vn(e,i,o,c){var d=!o;o||(o={});for(var v=-1,S=i.length;++v<S;){var y=i[v],T=c?c(o[y],e[y],y,o,e):n;T===n&&(T=e[y]),d?gn(o,y,T):Ji(o,y,T)}return o}function S_(e,i){return vn(e,el(e),i)}function y_(e,i){return vn(e,df(e),i)}function aa(e,i){return function(o,c){var d=X(o)?Rp:Bv,v=i?i():{};return d(o,e,z(c,2),v)}}function oi(e){return se(function(i,o){var c=-1,d=o.length,v=d>1?o[d-1]:n,S=d>2?o[2]:n;for(v=e.length>3&&typeof v=="function"?(d--,v):n,S&&st(o[0],o[1],S)&&(v=d<3?n:v,d=1),i=Ce(i);++c<d;){var y=o[c];y&&e(i,y,c,v)}return i})}function ef(e,i){return function(o,c){if(o==null)return o;if(!ht(o))return e(o,c);for(var d=o.length,v=i?d:-1,S=Ce(o);(i?v--:++v<d)&&c(S[v],v,S)!==!1;);return o}}function tf(e){return function(i,o,c){for(var d=-1,v=Ce(i),S=c(i),y=S.length;y--;){var T=S[e?y:++d];if(o(v[T],T,v)===!1)break}return i}}function E_(e,i,o){var c=i&N,d=ns(e);function v(){var S=this&&this!==Ke&&this instanceof v?d:e;return S.apply(c?o:this,arguments)}return v}function nf(e){return function(i){i=Se(i);var o=ei(i)?Xt(i):n,c=o?o[0]:i.charAt(0),d=o?Xn(o,1).join(""):i.slice(1);return c[e]()+d}}function li(e){return function(i){return mo(nh(th(i).replace(hp,"")),e,"")}}function ns(e){return function(){var i=arguments;switch(i.length){case 0:return new e;case 1:return new e(i[0]);case 2:return new e(i[0],i[1]);case 3:return new e(i[0],i[1],i[2]);case 4:return new e(i[0],i[1],i[2],i[3]);case 5:return new e(i[0],i[1],i[2],i[3],i[4]);case 6:return new e(i[0],i[1],i[2],i[3],i[4],i[5]);case 7:return new e(i[0],i[1],i[2],i[3],i[4],i[5],i[6])}var o=ai(e.prototype),c=e.apply(o,i);return Ne(c)?c:o}}function C_(e,i,o){var c=ns(e);function d(){for(var v=arguments.length,S=A(v),y=v,T=ui(d);y--;)S[y]=arguments[y];var x=v<3&&S[0]!==T&&S[v-1]!==T?[]:zn(S,T);if(v-=x.length,v<o)return lf(e,i,oa,d.placeholder,n,S,x,n,n,o-v);var L=this&&this!==Ke&&this instanceof d?c:e;return Et(L,this,S)}return d}function rf(e){return function(i,o,c){var d=Ce(i);if(!ht(i)){var v=z(o,3);i=Be(i),o=function(y){return v(d[y],y,d)}}var S=e(i,o,c);return S>-1?d[v?i[S]:S]:n}}function sf(e){return Nn(function(i){var o=i.length,c=o,d=Dt.prototype.thru;for(e&&i.reverse();c--;){var v=i[c];if(typeof v!="function")throw new Ut(u);if(d&&!S&&fa(v)=="wrapper")var S=new Dt([],!0)}for(c=S?c:o;++c<o;){v=i[c];var y=fa(v),T=y=="wrapper"?Xo(v):n;T&&nl(T[0])&&T[1]==(me|de|pe|Re)&&!T[4].length&&T[9]==1?S=S[fa(T[0])].apply(S,T[3]):S=v.length==1&&nl(v)?S[y]():S.thru(v)}return function(){var x=arguments,L=x[0];if(S&&x.length==1&&X(L))return S.plant(L).value();for(var U=0,F=o?i[U].apply(this,x):L;++U<o;)F=i[U].call(this,F);return F}})}function oa(e,i,o,c,d,v,S,y,T,x){var L=i&me,U=i&N,F=i&$,B=i&(de|_e),K=i&ae,ie=F?n:ns(e);function Q(){for(var le=arguments.length,he=A(le),At=le;At--;)he[At]=arguments[At];if(B)var at=ui(Q),Pt=Dp(he,at);if(c&&(he=Xc(he,c,d,B)),v&&(he=Zc(he,v,S,B)),le-=Pt,B&&le<x){var $e=zn(he,at);return lf(e,i,oa,Q.placeholder,o,he,$e,y,T,x-le)}var nn=U?o:this,Mn=F?nn[e]:e;return le=he.length,y?he=B_(he,y):K&&le>1&&he.reverse(),L&&T<le&&(he.length=T),this&&this!==Ke&&this instanceof Q&&(Mn=ie||ns(Mn)),Mn.apply(nn,he)}return Q}function af(e,i){return function(o,c){return Jv(o,e,i(c),{})}}function la(e,i){return function(o,c){var d;if(o===n&&c===n)return i;if(o!==n&&(d=o),c!==n){if(d===n)return c;typeof o=="string"||typeof c=="string"?(o=Tt(o),c=Tt(c)):(o=Gc(o),c=Gc(c)),d=e(o,c)}return d}}function Ko(e){return Nn(function(i){return i=xe(i,bt(z())),se(function(o){var c=this;return e(i,function(d){return Et(d,c,o)})})})}function ua(e,i){i=i===n?" ":Tt(i);var o=i.length;if(o<2)return o?Vo(i,e):i;var c=Vo(i,js(e/ti(i)));return ei(i)?Xn(Xt(c),0,e).join(""):c.slice(0,e)}function b_(e,i,o,c){var d=i&N,v=ns(e);function S(){for(var y=-1,T=arguments.length,x=-1,L=c.length,U=A(L+T),F=this&&this!==Ke&&this instanceof S?v:e;++x<L;)U[x]=c[x];for(;T--;)U[x++]=arguments[++y];return Et(F,d?o:this,U)}return S}function of(e){return function(i,o,c){return c&&typeof c!="number"&&st(i,o,c)&&(o=c=n),i=Dn(i),o===n?(o=i,i=0):o=Dn(o),c=c===n?i<o?1:-1:Dn(c),u_(i,o,c,e)}}function ca(e){return function(i,o){return typeof i=="string"&&typeof o=="string"||(i=Ft(i),o=Ft(o)),e(i,o)}}function lf(e,i,o,c,d,v,S,y,T,x){var L=i&de,U=L?S:n,F=L?n:S,B=L?v:n,K=L?n:v;i|=L?pe:oe,i&=~(L?oe:pe),i&J||(i&=-4);var ie=[e,i,d,B,U,K,F,y,T,x],Q=o.apply(n,ie);return nl(e)&&Sf(Q,ie),Q.placeholder=c,yf(Q,e,i)}function jo(e){var i=Ve[e];return function(o,c){if(o=Ft(o),c=c==null?0:Ze(re(c),292),c&&Sc(o)){var d=(Se(o)+"e").split("e"),v=i(d[0]+"e"+(+d[1]+c));return d=(Se(v)+"e").split("e"),+(d[0]+"e"+(+d[1]-c))}return i(o)}}var T_=ii&&1/Fs(new ii([,-0]))[1]==Xe?function(e){return new ii(e)}:ml;function uf(e){return function(i){var o=et(i);return o==Yt?To(i):o==Jt?Wp(i):Up(i,e(i))}}function Ln(e,i,o,c,d,v,S,y){var T=i&$;if(!T&&typeof e!="function")throw new Ut(u);var x=c?c.length:0;if(x||(i&=-97,c=d=n),S=S===n?S:We(re(S),0),y=y===n?y:re(y),x-=d?d.length:0,i&oe){var L=c,U=d;c=d=n}var F=T?n:Xo(e),B=[e,i,o,c,d,L,U,v,S,y];if(F&&H_(B,F),e=B[0],i=B[1],o=B[2],c=B[3],d=B[4],y=B[9]=B[9]===n?T?0:e.length:We(B[9]-x,0),!y&&i&(de|_e)&&(i&=-25),!i||i==N)var K=E_(e,i,o);else i==de||i==_e?K=C_(e,i,y):(i==pe||i==(N|pe))&&!d.length?K=b_(e,i,o,c):K=oa.apply(n,B);var ie=F?Wc:Sf;return yf(ie(K,B),e,i)}function cf(e,i,o,c){return e===n||tn(e,ri[o])&&!we.call(c,o)?i:e}function ff(e,i,o,c,d,v){return Ne(e)&&Ne(i)&&(v.set(i,e),ra(e,i,n,ff,v),v.delete(i)),e}function R_(e){return ss(e)?n:e}function hf(e,i,o,c,d,v){var S=o&R,y=e.length,T=i.length;if(y!=T&&!(S&&T>y))return!1;var x=v.get(e),L=v.get(i);if(x&&L)return x==i&&L==e;var U=-1,F=!0,B=o&I?new Tr:n;for(v.set(e,i),v.set(i,e);++U<y;){var K=e[U],ie=i[U];if(c)var Q=S?c(ie,K,U,i,e,v):c(K,ie,U,e,i,v);if(Q!==n){if(Q)continue;F=!1;break}if(B){if(!wo(i,function(le,he){if(!Qi(B,he)&&(K===le||d(K,le,o,c,v)))return B.push(he)})){F=!1;break}}else if(!(K===ie||d(K,ie,o,c,v))){F=!1;break}}return v.delete(e),v.delete(i),F}function A_(e,i,o,c,d,v,S){switch(o){case Jr:if(e.byteLength!=i.byteLength||e.byteOffset!=i.byteOffset)return!1;e=e.buffer,i=i.buffer;case Gi:return!(e.byteLength!=i.byteLength||!v(new Qs(e),new Qs(i)));case Rn:case Sr:case Hi:return tn(+e,+i);case yr:return e.name==i.name&&e.message==i.message;case Vi:case Wi:return e==i+"";case Yt:var y=To;case Jt:var T=c&R;if(y||(y=Fs),e.size!=i.size&&!T)return!1;var x=S.get(e);if(x)return x==i;c|=I,S.set(e,i);var L=hf(y(e),y(i),c,d,v,S);return S.delete(e),L;case Os:if(Yi)return Yi.call(e)==Yi.call(i)}return!1}function P_(e,i,o,c,d,v){var S=o&R,y=Yo(e),T=y.length,x=Yo(i),L=x.length;if(T!=L&&!S)return!1;for(var U=T;U--;){var F=y[U];if(!(S?F in i:we.call(i,F)))return!1}var B=v.get(e),K=v.get(i);if(B&&K)return B==i&&K==e;var ie=!0;v.set(e,i),v.set(i,e);for(var Q=S;++U<T;){F=y[U];var le=e[F],he=i[F];if(c)var At=S?c(he,le,F,i,e,v):c(le,he,F,e,i,v);if(!(At===n?le===he||d(le,he,o,c,v):At)){ie=!1;break}Q||(Q=F=="constructor")}if(ie&&!Q){var at=e.constructor,Pt=i.constructor;at!=Pt&&"constructor"in e&&"constructor"in i&&!(typeof at=="function"&&at instanceof at&&typeof Pt=="function"&&Pt instanceof Pt)&&(ie=!1)}return v.delete(e),v.delete(i),ie}function Nn(e){return il(mf(e,n,Af),e+"")}function Yo(e){return Lc(e,Be,el)}function Jo(e){return Lc(e,dt,df)}var Xo=Js?function(e){return Js.get(e)}:ml;function fa(e){for(var i=e.name+"",o=si[i],c=we.call(si,i)?o.length:0;c--;){var d=o[c],v=d.func;if(v==null||v==e)return d.name}return i}function ui(e){var i=we.call(p,"placeholder")?p:e;return i.placeholder}function z(){var e=p.iteratee||vl;return e=e===vl?Uc:e,arguments.length?e(arguments[0],arguments[1]):e}function ha(e,i){var o=e.__data__;return M_(i)?o[typeof i=="string"?"string":"hash"]:o.map}function Zo(e){for(var i=Be(e),o=i.length;o--;){var c=i[o],d=e[c];i[o]=[c,d,vf(d)]}return i}function Pr(e,i){var o=Fp(e,i);return Oc(o)?o:n}function I_(e){var i=we.call(e,Cr),o=e[Cr];try{e[Cr]=n;var c=!0}catch{}var d=Bs.call(e);return c&&(i?e[Cr]=o:delete e[Cr]),d}var el=Ao?function(e){return e==null?[]:(e=Ce(e),Qn(Ao(e),function(i){return mc.call(e,i)}))}:wl,df=Ao?function(e){for(var i=[];e;)qn(i,el(e)),e=qs(e);return i}:wl,et=it;(Po&&et(new Po(new ArrayBuffer(1)))!=Jr||zi&&et(new zi)!=Yt||Io&&et(Io.resolve())!=Au||ii&&et(new ii)!=Jt||Ki&&et(new Ki)!=Bi)&&(et=function(e){var i=it(e),o=i==Pn?e.constructor:n,c=o?Ir(o):"";if(c)switch(c){case fv:return Jr;case hv:return Yt;case dv:return Au;case gv:return Jt;case pv:return Bi}return i});function x_(e,i,o){for(var c=-1,d=o.length;++c<d;){var v=o[c],S=v.size;switch(v.type){case"drop":e+=S;break;case"dropRight":i-=S;break;case"take":i=Ze(i,e+S);break;case"takeRight":e=We(e,i-S);break}}return{start:e,end:i}}function L_(e){var i=e.match($g);return i?i[1].split(Fg):[]}function gf(e,i,o){i=Jn(i,e);for(var c=-1,d=i.length,v=!1;++c<d;){var S=en(i[c]);if(!(v=e!=null&&o(e,S)))break;e=e[S]}return v||++c!=d?v:(d=e==null?0:e.length,!!d&&wa(d)&&On(S,d)&&(X(e)||xr(e)))}function N_(e){var i=e.length,o=new e.constructor(i);return i&&typeof e[0]=="string"&&we.call(e,"index")&&(o.index=e.index,o.input=e.input),o}function pf(e){return typeof e.constructor=="function"&&!rs(e)?ai(qs(e)):{}}function O_(e,i,o){var c=e.constructor;switch(i){case Gi:return zo(e);case Rn:case Sr:return new c(+e);case Jr:return v_(e,o);case Xa:case Za:case eo:case to:case no:case ro:case io:case so:case ao:return Yc(e,o);case Yt:return new c;case Hi:case Wi:return new c(e);case Vi:return __(e);case Jt:return new c;case Os:return m_(e)}}function U_(e,i){var o=i.length;if(!o)return e;var c=o-1;return i[c]=(o>1?"& ":"")+i[c],i=i.join(o>2?", ":" "),e.replace(kg,`{
2
+ /* [wrapped with `+i+`] */
3
+ `)}function D_(e){return X(e)||xr(e)||!!(wc&&e&&e[wc])}function On(e,i){var o=typeof e;return i=i??St,!!i&&(o=="number"||o!="symbol"&&zg.test(e))&&e>-1&&e%1==0&&e<i}function st(e,i,o){if(!Ne(o))return!1;var c=typeof i;return(c=="number"?ht(o)&&On(i,o.length):c=="string"&&i in o)?tn(o[i],e):!1}function tl(e,i){if(X(e))return!1;var o=typeof e;return o=="number"||o=="symbol"||o=="boolean"||e==null||Rt(e)?!0:Og.test(e)||!Ng.test(e)||i!=null&&e in Ce(i)}function M_(e){var i=typeof e;return i=="string"||i=="number"||i=="symbol"||i=="boolean"?e!=="__proto__":e===null}function nl(e){var i=fa(e),o=p[i];if(typeof o!="function"||!(i in ce.prototype))return!1;if(e===o)return!0;var c=Xo(o);return!!c&&e===c[0]}function k_(e){return!!pc&&pc in e}var $_=Vs?Un:Sl;function rs(e){var i=e&&e.constructor,o=typeof i=="function"&&i.prototype||ri;return e===o}function vf(e){return e===e&&!Ne(e)}function _f(e,i){return function(o){return o==null?!1:o[e]===i&&(i!==n||e in Ce(o))}}function F_(e){var i=_a(e,function(c){return o.size===_&&o.clear(),c}),o=i.cache;return i}function H_(e,i){var o=e[1],c=i[1],d=o|c,v=d<(N|$|me),S=c==me&&o==de||c==me&&o==Re&&e[7].length<=i[8]||c==(me|Re)&&i[7].length<=i[8]&&o==de;if(!(v||S))return e;c&N&&(e[2]=i[2],d|=o&N?0:J);var y=i[3];if(y){var T=e[3];e[3]=T?Xc(T,y,i[4]):y,e[4]=T?zn(e[3],w):i[4]}return y=i[5],y&&(T=e[5],e[5]=T?Zc(T,y,i[6]):y,e[6]=T?zn(e[5],w):i[6]),y=i[7],y&&(e[7]=y),c&me&&(e[8]=e[8]==null?i[8]:Ze(e[8],i[8])),e[9]==null&&(e[9]=i[9]),e[0]=i[0],e[1]=d,e}function V_(e){var i=[];if(e!=null)for(var o in Ce(e))i.push(o);return i}function W_(e){return Bs.call(e)}function mf(e,i,o){return i=We(i===n?e.length-1:i,0),function(){for(var c=arguments,d=-1,v=We(c.length-i,0),S=A(v);++d<v;)S[d]=c[i+d];d=-1;for(var y=A(i+1);++d<i;)y[d]=c[d];return y[i]=o(S),Et(e,this,y)}}function wf(e,i){return i.length<2?e:Ar(e,kt(i,0,-1))}function B_(e,i){for(var o=e.length,c=Ze(i.length,o),d=ft(e);c--;){var v=i[c];e[c]=On(v,o)?d[v]:n}return e}function rl(e,i){if(!(i==="constructor"&&typeof e[i]=="function")&&i!="__proto__")return e[i]}var Sf=Ef(Wc),is=iv||function(e,i){return Ke.setTimeout(e,i)},il=Ef(h_);function yf(e,i,o){var c=i+"";return il(e,U_(c,G_(L_(c),o)))}function Ef(e){var i=0,o=0;return function(){var c=lv(),d=W-(c-o);if(o=c,d>0){if(++i>=jt)return arguments[0]}else i=0;return e.apply(n,arguments)}}function da(e,i){var o=-1,c=e.length,d=c-1;for(i=i===n?c:i;++o<i;){var v=Ho(o,d),S=e[v];e[v]=e[o],e[o]=S}return e.length=i,e}var Cf=F_(function(e){var i=[];return e.charCodeAt(0)===46&&i.push(""),e.replace(Ug,function(o,c,d,v){i.push(d?v.replace(Vg,"$1"):c||o)}),i});function en(e){if(typeof e=="string"||Rt(e))return e;var i=e+"";return i=="0"&&1/e==-Xe?"-0":i}function Ir(e){if(e!=null){try{return Ws.call(e)}catch{}try{return e+""}catch{}}return""}function G_(e,i){return Ct(dn,function(o){var c="_."+o[0];i&o[1]&&!ks(e,c)&&e.push(c)}),e.sort()}function bf(e){if(e instanceof ce)return e.clone();var i=new Dt(e.__wrapped__,e.__chain__);return i.__actions__=ft(e.__actions__),i.__index__=e.__index__,i.__values__=e.__values__,i}function Q_(e,i,o){(o?st(e,i,o):i===n)?i=1:i=We(re(i),0);var c=e==null?0:e.length;if(!c||i<1)return[];for(var d=0,v=0,S=A(js(c/i));d<c;)S[v++]=kt(e,d,d+=i);return S}function q_(e){for(var i=-1,o=e==null?0:e.length,c=0,d=[];++i<o;){var v=e[i];v&&(d[c++]=v)}return d}function z_(){var e=arguments.length;if(!e)return[];for(var i=A(e-1),o=arguments[0],c=e;c--;)i[c-1]=arguments[c];return qn(X(o)?ft(o):[o],je(i,1))}var K_=se(function(e,i){return ke(e)?Xi(e,je(i,1,ke,!0)):[]}),j_=se(function(e,i){var o=$t(i);return ke(o)&&(o=n),ke(e)?Xi(e,je(i,1,ke,!0),z(o,2)):[]}),Y_=se(function(e,i){var o=$t(i);return ke(o)&&(o=n),ke(e)?Xi(e,je(i,1,ke,!0),n,o):[]});function J_(e,i,o){var c=e==null?0:e.length;return c?(i=o||i===n?1:re(i),kt(e,i<0?0:i,c)):[]}function X_(e,i,o){var c=e==null?0:e.length;return c?(i=o||i===n?1:re(i),i=c-i,kt(e,0,i<0?0:i)):[]}function Z_(e,i){return e&&e.length?sa(e,z(i,3),!0,!0):[]}function em(e,i){return e&&e.length?sa(e,z(i,3),!0):[]}function tm(e,i,o,c){var d=e==null?0:e.length;return d?(o&&typeof o!="number"&&st(e,i,o)&&(o=0,c=d),zv(e,i,o,c)):[]}function Tf(e,i,o){var c=e==null?0:e.length;if(!c)return-1;var d=o==null?0:re(o);return d<0&&(d=We(c+d,0)),$s(e,z(i,3),d)}function Rf(e,i,o){var c=e==null?0:e.length;if(!c)return-1;var d=c-1;return o!==n&&(d=re(o),d=o<0?We(c+d,0):Ze(d,c-1)),$s(e,z(i,3),d,!0)}function Af(e){var i=e==null?0:e.length;return i?je(e,1):[]}function nm(e){var i=e==null?0:e.length;return i?je(e,Xe):[]}function rm(e,i){var o=e==null?0:e.length;return o?(i=i===n?1:re(i),je(e,i)):[]}function im(e){for(var i=-1,o=e==null?0:e.length,c={};++i<o;){var d=e[i];gn(c,d[0],d[1])}return c}function Pf(e){return e&&e.length?e[0]:n}function sm(e,i,o){var c=e==null?0:e.length;if(!c)return-1;var d=o==null?0:re(o);return d<0&&(d=We(c+d,0)),Zr(e,i,d)}function am(e){var i=e==null?0:e.length;return i?kt(e,0,-1):[]}var om=se(function(e){var i=xe(e,Qo);return i.length&&i[0]===e[0]?Do(i):[]}),lm=se(function(e){var i=$t(e),o=xe(e,Qo);return i===$t(o)?i=n:o.pop(),o.length&&o[0]===e[0]?Do(o,z(i,2)):[]}),um=se(function(e){var i=$t(e),o=xe(e,Qo);return i=typeof i=="function"?i:n,i&&o.pop(),o.length&&o[0]===e[0]?Do(o,n,i):[]});function cm(e,i){return e==null?"":av.call(e,i)}function $t(e){var i=e==null?0:e.length;return i?e[i-1]:n}function fm(e,i,o){var c=e==null?0:e.length;if(!c)return-1;var d=c;return o!==n&&(d=re(o),d=d<0?We(c+d,0):Ze(d,c-1)),i===i?Gp(e,i,d):$s(e,oc,d,!0)}function hm(e,i){return e&&e.length?$c(e,re(i)):n}var dm=se(If);function If(e,i){return e&&e.length&&i&&i.length?Fo(e,i):e}function gm(e,i,o){return e&&e.length&&i&&i.length?Fo(e,i,z(o,2)):e}function pm(e,i,o){return e&&e.length&&i&&i.length?Fo(e,i,n,o):e}var vm=Nn(function(e,i){var o=e==null?0:e.length,c=Lo(e,i);return Vc(e,xe(i,function(d){return On(d,o)?+d:d}).sort(Jc)),c});function _m(e,i){var o=[];if(!(e&&e.length))return o;var c=-1,d=[],v=e.length;for(i=z(i,3);++c<v;){var S=e[c];i(S,c,e)&&(o.push(S),d.push(c))}return Vc(e,d),o}function sl(e){return e==null?e:cv.call(e)}function mm(e,i,o){var c=e==null?0:e.length;return c?(o&&typeof o!="number"&&st(e,i,o)?(i=0,o=c):(i=i==null?0:re(i),o=o===n?c:re(o)),kt(e,i,o)):[]}function wm(e,i){return ia(e,i)}function Sm(e,i,o){return Wo(e,i,z(o,2))}function ym(e,i){var o=e==null?0:e.length;if(o){var c=ia(e,i);if(c<o&&tn(e[c],i))return c}return-1}function Em(e,i){return ia(e,i,!0)}function Cm(e,i,o){return Wo(e,i,z(o,2),!0)}function bm(e,i){var o=e==null?0:e.length;if(o){var c=ia(e,i,!0)-1;if(tn(e[c],i))return c}return-1}function Tm(e){return e&&e.length?Bc(e):[]}function Rm(e,i){return e&&e.length?Bc(e,z(i,2)):[]}function Am(e){var i=e==null?0:e.length;return i?kt(e,1,i):[]}function Pm(e,i,o){return e&&e.length?(i=o||i===n?1:re(i),kt(e,0,i<0?0:i)):[]}function Im(e,i,o){var c=e==null?0:e.length;return c?(i=o||i===n?1:re(i),i=c-i,kt(e,i<0?0:i,c)):[]}function xm(e,i){return e&&e.length?sa(e,z(i,3),!1,!0):[]}function Lm(e,i){return e&&e.length?sa(e,z(i,3)):[]}var Nm=se(function(e){return Yn(je(e,1,ke,!0))}),Om=se(function(e){var i=$t(e);return ke(i)&&(i=n),Yn(je(e,1,ke,!0),z(i,2))}),Um=se(function(e){var i=$t(e);return i=typeof i=="function"?i:n,Yn(je(e,1,ke,!0),n,i)});function Dm(e){return e&&e.length?Yn(e):[]}function Mm(e,i){return e&&e.length?Yn(e,z(i,2)):[]}function km(e,i){return i=typeof i=="function"?i:n,e&&e.length?Yn(e,n,i):[]}function al(e){if(!(e&&e.length))return[];var i=0;return e=Qn(e,function(o){if(ke(o))return i=We(o.length,i),!0}),Co(i,function(o){return xe(e,So(o))})}function xf(e,i){if(!(e&&e.length))return[];var o=al(e);return i==null?o:xe(o,function(c){return Et(i,n,c)})}var $m=se(function(e,i){return ke(e)?Xi(e,i):[]}),Fm=se(function(e){return Go(Qn(e,ke))}),Hm=se(function(e){var i=$t(e);return ke(i)&&(i=n),Go(Qn(e,ke),z(i,2))}),Vm=se(function(e){var i=$t(e);return i=typeof i=="function"?i:n,Go(Qn(e,ke),n,i)}),Wm=se(al);function Bm(e,i){return zc(e||[],i||[],Ji)}function Gm(e,i){return zc(e||[],i||[],ts)}var Qm=se(function(e){var i=e.length,o=i>1?e[i-1]:n;return o=typeof o=="function"?(e.pop(),o):n,xf(e,o)});function Lf(e){var i=p(e);return i.__chain__=!0,i}function qm(e,i){return i(e),e}function ga(e,i){return i(e)}var zm=Nn(function(e){var i=e.length,o=i?e[0]:0,c=this.__wrapped__,d=function(v){return Lo(v,e)};return i>1||this.__actions__.length||!(c instanceof ce)||!On(o)?this.thru(d):(c=c.slice(o,+o+(i?1:0)),c.__actions__.push({func:ga,args:[d],thisArg:n}),new Dt(c,this.__chain__).thru(function(v){return i&&!v.length&&v.push(n),v}))});function Km(){return Lf(this)}function jm(){return new Dt(this.value(),this.__chain__)}function Ym(){this.__values__===n&&(this.__values__=Qf(this.value()));var e=this.__index__>=this.__values__.length,i=e?n:this.__values__[this.__index__++];return{done:e,value:i}}function Jm(){return this}function Xm(e){for(var i,o=this;o instanceof Zs;){var c=bf(o);c.__index__=0,c.__values__=n,i?d.__wrapped__=c:i=c;var d=c;o=o.__wrapped__}return d.__wrapped__=e,i}function Zm(){var e=this.__wrapped__;if(e instanceof ce){var i=e;return this.__actions__.length&&(i=new ce(this)),i=i.reverse(),i.__actions__.push({func:ga,args:[sl],thisArg:n}),new Dt(i,this.__chain__)}return this.thru(sl)}function ew(){return qc(this.__wrapped__,this.__actions__)}var tw=aa(function(e,i,o){we.call(e,o)?++e[o]:gn(e,o,1)});function nw(e,i,o){var c=X(e)?sc:qv;return o&&st(e,i,o)&&(i=n),c(e,z(i,3))}function rw(e,i){var o=X(e)?Qn:Ic;return o(e,z(i,3))}var iw=rf(Tf),sw=rf(Rf);function aw(e,i){return je(pa(e,i),1)}function ow(e,i){return je(pa(e,i),Xe)}function lw(e,i,o){return o=o===n?1:re(o),je(pa(e,i),o)}function Nf(e,i){var o=X(e)?Ct:jn;return o(e,z(i,3))}function Of(e,i){var o=X(e)?Ap:Pc;return o(e,z(i,3))}var uw=aa(function(e,i,o){we.call(e,o)?e[o].push(i):gn(e,o,[i])});function cw(e,i,o,c){e=ht(e)?e:fi(e),o=o&&!c?re(o):0;var d=e.length;return o<0&&(o=We(d+o,0)),Sa(e)?o<=d&&e.indexOf(i,o)>-1:!!d&&Zr(e,i,o)>-1}var fw=se(function(e,i,o){var c=-1,d=typeof i=="function",v=ht(e)?A(e.length):[];return jn(e,function(S){v[++c]=d?Et(i,S,o):Zi(S,i,o)}),v}),hw=aa(function(e,i,o){gn(e,o,i)});function pa(e,i){var o=X(e)?xe:Dc;return o(e,z(i,3))}function dw(e,i,o,c){return e==null?[]:(X(i)||(i=i==null?[]:[i]),o=c?n:o,X(o)||(o=o==null?[]:[o]),Fc(e,i,o))}var gw=aa(function(e,i,o){e[o?0:1].push(i)},function(){return[[],[]]});function pw(e,i,o){var c=X(e)?mo:uc,d=arguments.length<3;return c(e,z(i,4),o,d,jn)}function vw(e,i,o){var c=X(e)?Pp:uc,d=arguments.length<3;return c(e,z(i,4),o,d,Pc)}function _w(e,i){var o=X(e)?Qn:Ic;return o(e,ma(z(i,3)))}function mw(e){var i=X(e)?bc:c_;return i(e)}function ww(e,i,o){(o?st(e,i,o):i===n)?i=1:i=re(i);var c=X(e)?Vv:f_;return c(e,i)}function Sw(e){var i=X(e)?Wv:d_;return i(e)}function yw(e){if(e==null)return 0;if(ht(e))return Sa(e)?ti(e):e.length;var i=et(e);return i==Yt||i==Jt?e.size:ko(e).length}function Ew(e,i,o){var c=X(e)?wo:g_;return o&&st(e,i,o)&&(i=n),c(e,z(i,3))}var Cw=se(function(e,i){if(e==null)return[];var o=i.length;return o>1&&st(e,i[0],i[1])?i=[]:o>2&&st(i[0],i[1],i[2])&&(i=[i[0]]),Fc(e,je(i,1),[])}),va=rv||function(){return Ke.Date.now()};function bw(e,i){if(typeof i!="function")throw new Ut(u);return e=re(e),function(){if(--e<1)return i.apply(this,arguments)}}function Uf(e,i,o){return i=o?n:i,i=e&&i==null?e.length:i,Ln(e,me,n,n,n,n,i)}function Df(e,i){var o;if(typeof i!="function")throw new Ut(u);return e=re(e),function(){return--e>0&&(o=i.apply(this,arguments)),e<=1&&(i=n),o}}var ol=se(function(e,i,o){var c=N;if(o.length){var d=zn(o,ui(ol));c|=pe}return Ln(e,c,i,o,d)}),Mf=se(function(e,i,o){var c=N|$;if(o.length){var d=zn(o,ui(Mf));c|=pe}return Ln(i,c,e,o,d)});function kf(e,i,o){i=o?n:i;var c=Ln(e,de,n,n,n,n,n,i);return c.placeholder=kf.placeholder,c}function $f(e,i,o){i=o?n:i;var c=Ln(e,_e,n,n,n,n,n,i);return c.placeholder=$f.placeholder,c}function Ff(e,i,o){var c,d,v,S,y,T,x=0,L=!1,U=!1,F=!0;if(typeof e!="function")throw new Ut(u);i=Ft(i)||0,Ne(o)&&(L=!!o.leading,U="maxWait"in o,v=U?We(Ft(o.maxWait)||0,i):v,F="trailing"in o?!!o.trailing:F);function B($e){var nn=c,Mn=d;return c=d=n,x=$e,S=e.apply(Mn,nn),S}function K($e){return x=$e,y=is(le,i),L?B($e):S}function ie($e){var nn=$e-T,Mn=$e-x,sh=i-nn;return U?Ze(sh,v-Mn):sh}function Q($e){var nn=$e-T,Mn=$e-x;return T===n||nn>=i||nn<0||U&&Mn>=v}function le(){var $e=va();if(Q($e))return he($e);y=is(le,ie($e))}function he($e){return y=n,F&&c?B($e):(c=d=n,S)}function At(){y!==n&&Kc(y),x=0,c=T=d=y=n}function at(){return y===n?S:he(va())}function Pt(){var $e=va(),nn=Q($e);if(c=arguments,d=this,T=$e,nn){if(y===n)return K(T);if(U)return Kc(y),y=is(le,i),B(T)}return y===n&&(y=is(le,i)),S}return Pt.cancel=At,Pt.flush=at,Pt}var Tw=se(function(e,i){return Ac(e,1,i)}),Rw=se(function(e,i,o){return Ac(e,Ft(i)||0,o)});function Aw(e){return Ln(e,ae)}function _a(e,i){if(typeof e!="function"||i!=null&&typeof i!="function")throw new Ut(u);var o=function(){var c=arguments,d=i?i.apply(this,c):c[0],v=o.cache;if(v.has(d))return v.get(d);var S=e.apply(this,c);return o.cache=v.set(d,S)||v,S};return o.cache=new(_a.Cache||xn),o}_a.Cache=xn;function ma(e){if(typeof e!="function")throw new Ut(u);return function(){var i=arguments;switch(i.length){case 0:return!e.call(this);case 1:return!e.call(this,i[0]);case 2:return!e.call(this,i[0],i[1]);case 3:return!e.call(this,i[0],i[1],i[2])}return!e.apply(this,i)}}function Pw(e){return Df(2,e)}var Iw=p_(function(e,i){i=i.length==1&&X(i[0])?xe(i[0],bt(z())):xe(je(i,1),bt(z()));var o=i.length;return se(function(c){for(var d=-1,v=Ze(c.length,o);++d<v;)c[d]=i[d].call(this,c[d]);return Et(e,this,c)})}),ll=se(function(e,i){var o=zn(i,ui(ll));return Ln(e,pe,n,i,o)}),Hf=se(function(e,i){var o=zn(i,ui(Hf));return Ln(e,oe,n,i,o)}),xw=Nn(function(e,i){return Ln(e,Re,n,n,n,i)});function Lw(e,i){if(typeof e!="function")throw new Ut(u);return i=i===n?i:re(i),se(e,i)}function Nw(e,i){if(typeof e!="function")throw new Ut(u);return i=i==null?0:We(re(i),0),se(function(o){var c=o[i],d=Xn(o,0,i);return c&&qn(d,c),Et(e,this,d)})}function Ow(e,i,o){var c=!0,d=!0;if(typeof e!="function")throw new Ut(u);return Ne(o)&&(c="leading"in o?!!o.leading:c,d="trailing"in o?!!o.trailing:d),Ff(e,i,{leading:c,maxWait:i,trailing:d})}function Uw(e){return Uf(e,1)}function Dw(e,i){return ll(qo(i),e)}function Mw(){if(!arguments.length)return[];var e=arguments[0];return X(e)?e:[e]}function kw(e){return Mt(e,b)}function $w(e,i){return i=typeof i=="function"?i:n,Mt(e,b,i)}function Fw(e){return Mt(e,m|b)}function Hw(e,i){return i=typeof i=="function"?i:n,Mt(e,m|b,i)}function Vw(e,i){return i==null||Rc(e,i,Be(i))}function tn(e,i){return e===i||e!==e&&i!==i}var Ww=ca(Uo),Bw=ca(function(e,i){return e>=i}),xr=Nc((function(){return arguments})())?Nc:function(e){return De(e)&&we.call(e,"callee")&&!mc.call(e,"callee")},X=A.isArray,Gw=Zu?bt(Zu):Xv;function ht(e){return e!=null&&wa(e.length)&&!Un(e)}function ke(e){return De(e)&&ht(e)}function Qw(e){return e===!0||e===!1||De(e)&&it(e)==Rn}var Zn=sv||Sl,qw=ec?bt(ec):Zv;function zw(e){return De(e)&&e.nodeType===1&&!ss(e)}function Kw(e){if(e==null)return!0;if(ht(e)&&(X(e)||typeof e=="string"||typeof e.splice=="function"||Zn(e)||ci(e)||xr(e)))return!e.length;var i=et(e);if(i==Yt||i==Jt)return!e.size;if(rs(e))return!ko(e).length;for(var o in e)if(we.call(e,o))return!1;return!0}function jw(e,i){return es(e,i)}function Yw(e,i,o){o=typeof o=="function"?o:n;var c=o?o(e,i):n;return c===n?es(e,i,n,o):!!c}function ul(e){if(!De(e))return!1;var i=it(e);return i==yr||i==Nt||typeof e.message=="string"&&typeof e.name=="string"&&!ss(e)}function Jw(e){return typeof e=="number"&&Sc(e)}function Un(e){if(!Ne(e))return!1;var i=it(e);return i==An||i==Ru||i==wr||i==Eg}function Vf(e){return typeof e=="number"&&e==re(e)}function wa(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=St}function Ne(e){var i=typeof e;return e!=null&&(i=="object"||i=="function")}function De(e){return e!=null&&typeof e=="object"}var Wf=tc?bt(tc):t_;function Xw(e,i){return e===i||Mo(e,i,Zo(i))}function Zw(e,i,o){return o=typeof o=="function"?o:n,Mo(e,i,Zo(i),o)}function eS(e){return Bf(e)&&e!=+e}function tS(e){if($_(e))throw new Y(l);return Oc(e)}function nS(e){return e===null}function rS(e){return e==null}function Bf(e){return typeof e=="number"||De(e)&&it(e)==Hi}function ss(e){if(!De(e)||it(e)!=Pn)return!1;var i=qs(e);if(i===null)return!0;var o=we.call(i,"constructor")&&i.constructor;return typeof o=="function"&&o instanceof o&&Ws.call(o)==Zp}var cl=nc?bt(nc):n_;function iS(e){return Vf(e)&&e>=-St&&e<=St}var Gf=rc?bt(rc):r_;function Sa(e){return typeof e=="string"||!X(e)&&De(e)&&it(e)==Wi}function Rt(e){return typeof e=="symbol"||De(e)&&it(e)==Os}var ci=ic?bt(ic):i_;function sS(e){return e===n}function aS(e){return De(e)&&et(e)==Bi}function oS(e){return De(e)&&it(e)==bg}var lS=ca($o),uS=ca(function(e,i){return e<=i});function Qf(e){if(!e)return[];if(ht(e))return Sa(e)?Xt(e):ft(e);if(qi&&e[qi])return Vp(e[qi]());var i=et(e),o=i==Yt?To:i==Jt?Fs:fi;return o(e)}function Dn(e){if(!e)return e===0?e:0;if(e=Ft(e),e===Xe||e===-Xe){var i=e<0?-1:1;return i*Yr}return e===e?e:0}function re(e){var i=Dn(e),o=i%1;return i===i?o?i-o:i:0}function qf(e){return e?Rr(re(e),0,Ae):0}function Ft(e){if(typeof e=="number")return e;if(Rt(e))return O;if(Ne(e)){var i=typeof e.valueOf=="function"?e.valueOf():e;e=Ne(i)?i+"":i}if(typeof e!="string")return e===0?e:+e;e=cc(e);var o=Gg.test(e);return o||qg.test(e)?bp(e.slice(2),o?2:8):Bg.test(e)?O:+e}function zf(e){return vn(e,dt(e))}function cS(e){return e?Rr(re(e),-St,St):e===0?e:0}function Se(e){return e==null?"":Tt(e)}var fS=oi(function(e,i){if(rs(i)||ht(i)){vn(i,Be(i),e);return}for(var o in i)we.call(i,o)&&Ji(e,o,i[o])}),Kf=oi(function(e,i){vn(i,dt(i),e)}),jf=oi(function(e,i,o,c){vn(i,dt(i),e,c)}),fl=oi(function(e,i,o,c){vn(i,Be(i),e,c)}),hS=Nn(Lo);function dS(e,i){var o=ai(e);return i==null?o:Tc(o,i)}var gS=se(function(e,i){e=Ce(e);var o=-1,c=i.length,d=c>2?i[2]:n;for(d&&st(i[0],i[1],d)&&(c=1);++o<c;)for(var v=i[o],S=dt(v),y=-1,T=S.length;++y<T;){var x=S[y],L=e[x];(L===n||tn(L,ri[x])&&!we.call(e,x))&&(e[x]=v[x])}return e}),pS=se(function(e){return e.push(n,ff),Et(Yf,n,e)});function vS(e,i){return ac(e,z(i,3),pn)}function _S(e,i){return ac(e,z(i,3),Oo)}function mS(e,i){return e==null?e:No(e,z(i,3),dt)}function wS(e,i){return e==null?e:xc(e,z(i,3),dt)}function SS(e,i){return e&&pn(e,z(i,3))}function yS(e,i){return e&&Oo(e,z(i,3))}function ES(e){return e==null?[]:na(e,Be(e))}function CS(e){return e==null?[]:na(e,dt(e))}function hl(e,i,o){var c=e==null?n:Ar(e,i);return c===n?o:c}function bS(e,i){return e!=null&&gf(e,i,Kv)}function dl(e,i){return e!=null&&gf(e,i,jv)}var TS=af(function(e,i,o){i!=null&&typeof i.toString!="function"&&(i=Bs.call(i)),e[i]=o},pl(gt)),RS=af(function(e,i,o){i!=null&&typeof i.toString!="function"&&(i=Bs.call(i)),we.call(e,i)?e[i].push(o):e[i]=[o]},z),AS=se(Zi);function Be(e){return ht(e)?Cc(e):ko(e)}function dt(e){return ht(e)?Cc(e,!0):s_(e)}function PS(e,i){var o={};return i=z(i,3),pn(e,function(c,d,v){gn(o,i(c,d,v),c)}),o}function IS(e,i){var o={};return i=z(i,3),pn(e,function(c,d,v){gn(o,d,i(c,d,v))}),o}var xS=oi(function(e,i,o){ra(e,i,o)}),Yf=oi(function(e,i,o,c){ra(e,i,o,c)}),LS=Nn(function(e,i){var o={};if(e==null)return o;var c=!1;i=xe(i,function(v){return v=Jn(v,e),c||(c=v.length>1),v}),vn(e,Jo(e),o),c&&(o=Mt(o,m|E|b,R_));for(var d=i.length;d--;)Bo(o,i[d]);return o});function NS(e,i){return Jf(e,ma(z(i)))}var OS=Nn(function(e,i){return e==null?{}:o_(e,i)});function Jf(e,i){if(e==null)return{};var o=xe(Jo(e),function(c){return[c]});return i=z(i),Hc(e,o,function(c,d){return i(c,d[0])})}function US(e,i,o){i=Jn(i,e);var c=-1,d=i.length;for(d||(d=1,e=n);++c<d;){var v=e==null?n:e[en(i[c])];v===n&&(c=d,v=o),e=Un(v)?v.call(e):v}return e}function DS(e,i,o){return e==null?e:ts(e,i,o)}function MS(e,i,o,c){return c=typeof c=="function"?c:n,e==null?e:ts(e,i,o,c)}var Xf=uf(Be),Zf=uf(dt);function kS(e,i,o){var c=X(e),d=c||Zn(e)||ci(e);if(i=z(i,4),o==null){var v=e&&e.constructor;d?o=c?new v:[]:Ne(e)?o=Un(v)?ai(qs(e)):{}:o={}}return(d?Ct:pn)(e,function(S,y,T){return i(o,S,y,T)}),o}function $S(e,i){return e==null?!0:Bo(e,i)}function FS(e,i,o){return e==null?e:Qc(e,i,qo(o))}function HS(e,i,o,c){return c=typeof c=="function"?c:n,e==null?e:Qc(e,i,qo(o),c)}function fi(e){return e==null?[]:bo(e,Be(e))}function VS(e){return e==null?[]:bo(e,dt(e))}function WS(e,i,o){return o===n&&(o=i,i=n),o!==n&&(o=Ft(o),o=o===o?o:0),i!==n&&(i=Ft(i),i=i===i?i:0),Rr(Ft(e),i,o)}function BS(e,i,o){return i=Dn(i),o===n?(o=i,i=0):o=Dn(o),e=Ft(e),Yv(e,i,o)}function GS(e,i,o){if(o&&typeof o!="boolean"&&st(e,i,o)&&(i=o=n),o===n&&(typeof i=="boolean"?(o=i,i=n):typeof e=="boolean"&&(o=e,e=n)),e===n&&i===n?(e=0,i=1):(e=Dn(e),i===n?(i=e,e=0):i=Dn(i)),e>i){var c=e;e=i,i=c}if(o||e%1||i%1){var d=yc();return Ze(e+d*(i-e+Cp("1e-"+((d+"").length-1))),i)}return Ho(e,i)}var QS=li(function(e,i,o){return i=i.toLowerCase(),e+(o?eh(i):i)});function eh(e){return gl(Se(e).toLowerCase())}function th(e){return e=Se(e),e&&e.replace(Kg,Mp).replace(dp,"")}function qS(e,i,o){e=Se(e),i=Tt(i);var c=e.length;o=o===n?c:Rr(re(o),0,c);var d=o;return o-=i.length,o>=0&&e.slice(o,d)==i}function zS(e){return e=Se(e),e&&Ig.test(e)?e.replace(Iu,kp):e}function KS(e){return e=Se(e),e&&Dg.test(e)?e.replace(oo,"\\$&"):e}var jS=li(function(e,i,o){return e+(o?"-":"")+i.toLowerCase()}),YS=li(function(e,i,o){return e+(o?" ":"")+i.toLowerCase()}),JS=nf("toLowerCase");function XS(e,i,o){e=Se(e),i=re(i);var c=i?ti(e):0;if(!i||c>=i)return e;var d=(i-c)/2;return ua(Ys(d),o)+e+ua(js(d),o)}function ZS(e,i,o){e=Se(e),i=re(i);var c=i?ti(e):0;return i&&c<i?e+ua(i-c,o):e}function ey(e,i,o){e=Se(e),i=re(i);var c=i?ti(e):0;return i&&c<i?ua(i-c,o)+e:e}function ty(e,i,o){return o||i==null?i=0:i&&(i=+i),uv(Se(e).replace(lo,""),i||0)}function ny(e,i,o){return(o?st(e,i,o):i===n)?i=1:i=re(i),Vo(Se(e),i)}function ry(){var e=arguments,i=Se(e[0]);return e.length<3?i:i.replace(e[1],e[2])}var iy=li(function(e,i,o){return e+(o?"_":"")+i.toLowerCase()});function sy(e,i,o){return o&&typeof o!="number"&&st(e,i,o)&&(i=o=n),o=o===n?Ae:o>>>0,o?(e=Se(e),e&&(typeof i=="string"||i!=null&&!cl(i))&&(i=Tt(i),!i&&ei(e))?Xn(Xt(e),0,o):e.split(i,o)):[]}var ay=li(function(e,i,o){return e+(o?" ":"")+gl(i)});function oy(e,i,o){return e=Se(e),o=o==null?0:Rr(re(o),0,e.length),i=Tt(i),e.slice(o,o+i.length)==i}function ly(e,i,o){var c=p.templateSettings;o&&st(e,i,o)&&(i=n),e=Se(e),i=fl({},i,c,cf);var d=fl({},i.imports,c.imports,cf),v=Be(d),S=bo(d,v);Ct(v,function(Q){if(Lu.test(Q))throw new Y(h)});var y,T,x=0,L=i.interpolate||Us,U="__p += '",F=Ro((i.escape||Us).source+"|"+L.source+"|"+(L===xu?Wg:Us).source+"|"+(i.evaluate||Us).source+"|$","g"),B="//# sourceURL="+(we.call(i,"sourceURL")?(i.sourceURL+"").replace(/\s/g," "):"lodash.templateSources["+ ++mp+"]")+`
4
+ `;e.replace(F,function(Q,le,he,At,at,Pt){return he||(he=At),U+=e.slice(x,Pt).replace(jg,$p),le&&(y=!0,U+=`' +
5
+ __e(`+le+`) +
6
+ '`),at&&(T=!0,U+=`';
7
+ `+at+`;
8
+ __p += '`),he&&(U+=`' +
9
+ ((__t = (`+he+`)) == null ? '' : __t) +
10
+ '`),x=Pt+Q.length,Q}),U+=`';
11
+ `;var K=we.call(i,"variable")&&i.variable;if(!K)U=`with (obj) {
12
+ `+U+`
13
13
  }
14
- `;else if(uo.test(G))throw new Q(d);x=(S?x.replace(rh,""):x).replace(ih,"$1").replace(sh,"$1;"),x="function("+(G||"obj")+`) {
15
- `+(G?"":`obj || (obj = {});
16
- `)+"var __t, __p = ''"+(v?", __e = _.escape":"")+(S?`, __j = Array.prototype.join;
14
+ `;else if(Lu.test(K))throw new Y(f);U=(T?U.replace(Tg,""):U).replace(Rg,"$1").replace(Ag,"$1;"),U="function("+(K||"obj")+`) {
15
+ `+(K?"":`obj || (obj = {});
16
+ `)+"var __t, __p = ''"+(y?", __e = _.escape":"")+(T?`, __j = Array.prototype.join;
17
17
  function print() { __p += __j.call(arguments, '') }
18
18
  `:`;
19
- `)+x+`return __p
20
- }`;var Y=Ol(function(){return re(g,k+"return "+x).apply(r,m)});if(Y.source=x,Sa(Y))throw Y;return Y}function Vm(e){return ae(e).toLowerCase()}function Bm(e){return ae(e).toUpperCase()}function Gm(e,t,s){if(e=ae(e),e&&(s||t===r))return Vo(e);if(!e||!(t=nt(t)))return e;var o=Ct(e),h=Ct(t),g=Bo(o,h),m=Go(o,h)+1;return on(o,g,m).join("")}function Qm(e,t,s){if(e=ae(e),e&&(s||t===r))return e.slice(0,qo(e)+1);if(!e||!(t=nt(t)))return e;var o=Ct(e),h=Go(o,Ct(t))+1;return on(o,0,h).join("")}function qm(e,t,s){if(e=ae(e),e&&(s||t===r))return e.replace(Ss,"");if(!e||!(t=nt(t)))return e;var o=Ct(e),h=Bo(o,Ct(t));return on(o,h).join("")}function zm(e,t){var s=be,o=$;if(de(t)){var h="separator"in t?t.separator:h;s="length"in t?K(t.length):s,o="omission"in t?nt(t.omission):o}e=ae(e);var g=e.length;if(qn(e)){var m=Ct(e);g=m.length}if(s>=g)return e;var v=s-zn(o);if(v<1)return o;var S=m?on(m,0,v).join(""):e.slice(0,v);if(h===r)return S+o;if(m&&(v+=S.length-v),Ea(h)){if(e.slice(v).search(h)){var P,I=S;for(h.global||(h=Ms(h.source,ae(lo.exec(h))+"g")),h.lastIndex=0;P=h.exec(I);)var x=P.index;S=S.slice(0,x===r?v:x)}}else if(e.indexOf(nt(h),v)!=v){var D=S.lastIndexOf(h);D>-1&&(S=S.slice(0,D))}return S+o}function Km(e){return e=ae(e),e&&ah.test(e)?e.replace(so,yf):e}var Ym=er(function(e,t,s){return e+(s?" ":"")+t.toUpperCase()}),Ra=Ou("toUpperCase");function Ul(e,t,s){return e=ae(e),t=s?r:t,t===r?wf(e)?Af(e):cf(e):e.match(t)||[]}var Ol=X(function(e,t){try{return je(e,r,t)}catch(s){return Sa(s)?s:new Q(s)}}),Xm=Bt(function(e,t){return et(t,function(s){s=yt(s),Nt(e,s,va(e[s],e))}),e});function Zm(e){var t=e==null?0:e.length,s=B();return e=t?fe(e,function(o){if(typeof o[1]!="function")throw new lt(l);return[s(o[0]),o[1]]}):[],X(function(o){for(var h=-1;++h<t;){var g=e[h];if(je(g[0],this,o))return je(g[1],this,o)}})}function Jm(e){return yd(ht(e,E))}function ba(e){return function(){return e}}function jm(e,t){return e==null||e!==e?t:e}var ev=Du(),tv=Du(!0);function Ye(e){return e}function Aa(e){return fu(typeof e=="function"?e:ht(e,E))}function nv(e){return gu(ht(e,E))}function rv(e,t){return pu(e,ht(t,E))}var iv=X(function(e,t){return function(s){return Dr(s,e,t)}}),sv=X(function(e,t){return function(s){return Dr(e,s,t)}});function Pa(e,t,s){var o=Ae(t),h=Ii(t,o);s==null&&!(de(t)&&(h.length||!o.length))&&(s=t,t=e,e=this,h=Ii(t,Ae(t)));var g=!(de(s)&&"chain"in s)||!!s.chain,m=Qt(e);return et(h,function(v){var S=t[v];e[v]=S,m&&(e.prototype[v]=function(){var P=this.__chain__;if(g||P){var I=e(this.__wrapped__),x=I.__actions__=qe(this.__actions__);return x.push({func:S,args:arguments,thisArg:e}),I.__chain__=P,I}return S.apply(e,en([this.value()],arguments))})}),e}function av(){return Le._===this&&(Le._=Uf),this}function Ia(){}function ov(e){return e=K(e),X(function(t){return _u(t,e)})}var uv=sa(fe),lv=sa(Mo),cv=sa(xs);function $l(e){return fa(e)?Ls(yt(e)):Wd(e)}function hv(e){return function(t){return e==null?r:An(e,t)}}var fv=Fu(),dv=Fu(!0);function xa(){return[]}function La(){return!1}function gv(){return{}}function pv(){return""}function _v(){return!0}function mv(e,t){if(e=K(e),e<1||e>oe)return[];var s=Lt,o=De(e,Lt);t=B(t),e-=Lt;for(var h=Os(o,t);++s<e;)t(s);return h}function vv(e){return z(e)?fe(e,yt):rt(e)?[e]:qe(el(ae(e)))}function wv(e){var t=++Lf;return ae(e)+t}var Sv=$i(function(e,t){return e+t},0),Ev=aa("ceil"),Cv=$i(function(e,t){return e/t},1),Tv=aa("floor");function yv(e){return e&&e.length?Pi(e,Ye,Qs):r}function Rv(e,t){return e&&e.length?Pi(e,B(t,2),Qs):r}function bv(e){return Ho(e,Ye)}function Av(e,t){return Ho(e,B(t,2))}function Pv(e){return e&&e.length?Pi(e,Ye,Ys):r}function Iv(e,t){return e&&e.length?Pi(e,B(t,2),Ys):r}var xv=$i(function(e,t){return e*t},1),Lv=aa("round"),Nv=$i(function(e,t){return e-t},0);function Uv(e){return e&&e.length?Us(e,Ye):0}function Ov(e,t){return e&&e.length?Us(e,B(t,2)):0}return f.after=r_,f.ary=hl,f.assign=G_,f.assignIn=Rl,f.assignInWith=bl,f.assignWith=Ca,f.at=Q_,f.before=fl,f.bind=va,f.bindAll=Xm,f.bindKey=dl,f.castArray=p_,f.chain=ul,f.chunk=yg,f.compact=Rg,f.concat=bg,f.cond=Zm,f.conforms=Jm,f.constant=ba,f.countBy=Op,f.create=q_,f.curry=gl,f.curryRight=pl,f.debounce=_l,f.defaults=z_,f.defaultsDeep=K_,f.defer=i_,f.delay=s_,f.difference=Ag,f.differenceBy=Pg,f.differenceWith=Ig,f.drop=xg,f.dropRight=Lg,f.dropRightWhile=Ng,f.dropWhile=Ug,f.fill=Og,f.filter=Dp,f.flatMap=kp,f.flatMapDeep=Hp,f.flatMapDepth=Wp,f.flatten=il,f.flattenDeep=$g,f.flattenDepth=Dg,f.flip=a_,f.flow=ev,f.flowRight=tv,f.fromPairs=Mg,f.functions=tm,f.functionsIn=nm,f.groupBy=Vp,f.initial=kg,f.intersection=Hg,f.intersectionBy=Wg,f.intersectionWith=Vg,f.invert=im,f.invertBy=sm,f.invokeMap=Gp,f.iteratee=Aa,f.keyBy=Qp,f.keys=Ae,f.keysIn=Ke,f.map=Vi,f.mapKeys=om,f.mapValues=um,f.matches=nv,f.matchesProperty=rv,f.memoize=Gi,f.merge=lm,f.mergeWith=Al,f.method=iv,f.methodOf=sv,f.mixin=Pa,f.negate=Qi,f.nthArg=ov,f.omit=cm,f.omitBy=hm,f.once=o_,f.orderBy=qp,f.over=uv,f.overArgs=u_,f.overEvery=lv,f.overSome=cv,f.partial=wa,f.partialRight=ml,f.partition=zp,f.pick=fm,f.pickBy=Pl,f.property=$l,f.propertyOf=hv,f.pull=qg,f.pullAll=al,f.pullAllBy=zg,f.pullAllWith=Kg,f.pullAt=Yg,f.range=fv,f.rangeRight=dv,f.rearg=l_,f.reject=Xp,f.remove=Xg,f.rest=c_,f.reverse=_a,f.sampleSize=Jp,f.set=gm,f.setWith=pm,f.shuffle=jp,f.slice=Zg,f.sortBy=n_,f.sortedUniq=ip,f.sortedUniqBy=sp,f.split=Fm,f.spread=h_,f.tail=ap,f.take=op,f.takeRight=up,f.takeRightWhile=lp,f.takeWhile=cp,f.tap=Rp,f.throttle=f_,f.thru=Wi,f.toArray=Cl,f.toPairs=Il,f.toPairsIn=xl,f.toPath=vv,f.toPlainObject=yl,f.transform=_m,f.unary=d_,f.union=hp,f.unionBy=fp,f.unionWith=dp,f.uniq=gp,f.uniqBy=pp,f.uniqWith=_p,f.unset=mm,f.unzip=ma,f.unzipWith=ol,f.update=vm,f.updateWith=wm,f.values=rr,f.valuesIn=Sm,f.without=mp,f.words=Ul,f.wrap=g_,f.xor=vp,f.xorBy=wp,f.xorWith=Sp,f.zip=Ep,f.zipObject=Cp,f.zipObjectDeep=Tp,f.zipWith=yp,f.entries=Il,f.entriesIn=xl,f.extend=Rl,f.extendWith=bl,Pa(f,f),f.add=Sv,f.attempt=Ol,f.camelCase=ym,f.capitalize=Ll,f.ceil=Ev,f.clamp=Em,f.clone=__,f.cloneDeep=v_,f.cloneDeepWith=w_,f.cloneWith=m_,f.conformsTo=S_,f.deburr=Nl,f.defaultTo=jm,f.divide=Cv,f.endsWith=Rm,f.eq=Rt,f.escape=bm,f.escapeRegExp=Am,f.every=$p,f.find=Mp,f.findIndex=nl,f.findKey=Y_,f.findLast=Fp,f.findLastIndex=rl,f.findLastKey=X_,f.floor=Tv,f.forEach=ll,f.forEachRight=cl,f.forIn=Z_,f.forInRight=J_,f.forOwn=j_,f.forOwnRight=em,f.get=Ta,f.gt=E_,f.gte=C_,f.has=rm,f.hasIn=ya,f.head=sl,f.identity=Ye,f.includes=Bp,f.indexOf=Fg,f.inRange=Cm,f.invoke=am,f.isArguments=xn,f.isArray=z,f.isArrayBuffer=T_,f.isArrayLike=ze,f.isArrayLikeObject=_e,f.isBoolean=y_,f.isBuffer=un,f.isDate=R_,f.isElement=b_,f.isEmpty=A_,f.isEqual=P_,f.isEqualWith=I_,f.isError=Sa,f.isFinite=x_,f.isFunction=Qt,f.isInteger=vl,f.isLength=qi,f.isMap=wl,f.isMatch=L_,f.isMatchWith=N_,f.isNaN=U_,f.isNative=O_,f.isNil=D_,f.isNull=$_,f.isNumber=Sl,f.isObject=de,f.isObjectLike=ge,f.isPlainObject=Vr,f.isRegExp=Ea,f.isSafeInteger=M_,f.isSet=El,f.isString=zi,f.isSymbol=rt,f.isTypedArray=nr,f.isUndefined=F_,f.isWeakMap=k_,f.isWeakSet=H_,f.join=Bg,f.kebabCase=Pm,f.last=dt,f.lastIndexOf=Gg,f.lowerCase=Im,f.lowerFirst=xm,f.lt=W_,f.lte=V_,f.max=yv,f.maxBy=Rv,f.mean=bv,f.meanBy=Av,f.min=Pv,f.minBy=Iv,f.stubArray=xa,f.stubFalse=La,f.stubObject=gv,f.stubString=pv,f.stubTrue=_v,f.multiply=xv,f.nth=Qg,f.noConflict=av,f.noop=Ia,f.now=Bi,f.pad=Lm,f.padEnd=Nm,f.padStart=Um,f.parseInt=Om,f.random=Tm,f.reduce=Kp,f.reduceRight=Yp,f.repeat=$m,f.replace=Dm,f.result=dm,f.round=Lv,f.runInContext=w,f.sample=Zp,f.size=e_,f.snakeCase=Mm,f.some=t_,f.sortedIndex=Jg,f.sortedIndexBy=jg,f.sortedIndexOf=ep,f.sortedLastIndex=tp,f.sortedLastIndexBy=np,f.sortedLastIndexOf=rp,f.startCase=km,f.startsWith=Hm,f.subtract=Nv,f.sum=Uv,f.sumBy=Ov,f.template=Wm,f.times=mv,f.toFinite=qt,f.toInteger=K,f.toLength=Tl,f.toLower=Vm,f.toNumber=gt,f.toSafeInteger=B_,f.toString=ae,f.toUpper=Bm,f.trim=Gm,f.trimEnd=Qm,f.trimStart=qm,f.truncate=zm,f.unescape=Km,f.uniqueId=wv,f.upperCase=Ym,f.upperFirst=Ra,f.each=ll,f.eachRight=cl,f.first=sl,Pa(f,(function(){var e={};return Ut(f,function(t,s){se.call(f.prototype,s)||(e[s]=t)}),e})(),{chain:!1}),f.VERSION=a,et(["bind","bindKey","curry","curryRight","partial","partialRight"],function(e){f[e].placeholder=f}),et(["drop","take"],function(e,t){ee.prototype[e]=function(s){s=s===r?1:Se(K(s),0);var o=this.__filtered__&&!t?new ee(this):this.clone();return o.__filtered__?o.__takeCount__=De(s,o.__takeCount__):o.__views__.push({size:De(s,Lt),type:e+(o.__dir__<0?"Right":"")}),o},ee.prototype[e+"Right"]=function(s){return this.reverse()[e](s).reverse()}}),et(["filter","map","takeWhile"],function(e,t){var s=t+1,o=s==$e||s==L;ee.prototype[e]=function(h){var g=this.clone();return g.__iteratees__.push({iteratee:B(h,3),type:s}),g.__filtered__=g.__filtered__||o,g}}),et(["head","last"],function(e,t){var s="take"+(t?"Right":"");ee.prototype[e]=function(){return this[s](1).value()[0]}}),et(["initial","tail"],function(e,t){var s="drop"+(t?"":"Right");ee.prototype[e]=function(){return this.__filtered__?new ee(this):this[s](1)}}),ee.prototype.compact=function(){return this.filter(Ye)},ee.prototype.find=function(e){return this.filter(e).head()},ee.prototype.findLast=function(e){return this.reverse().find(e)},ee.prototype.invokeMap=X(function(e,t){return typeof e=="function"?new ee(this):this.map(function(s){return Dr(s,e,t)})}),ee.prototype.reject=function(e){return this.filter(Qi(B(e)))},ee.prototype.slice=function(e,t){e=K(e);var s=this;return s.__filtered__&&(e>0||t<0)?new ee(s):(e<0?s=s.takeRight(-e):e&&(s=s.drop(e)),t!==r&&(t=K(t),s=t<0?s.dropRight(-t):s.take(t-e)),s)},ee.prototype.takeRightWhile=function(e){return this.reverse().takeWhile(e).reverse()},ee.prototype.toArray=function(){return this.take(Lt)},Ut(ee.prototype,function(e,t){var s=/^(?:filter|find|map|reject)|While$/.test(t),o=/^(?:head|last)$/.test(t),h=f[o?"take"+(t=="last"?"Right":""):t],g=o||/^find/.test(t);h&&(f.prototype[t]=function(){var m=this.__wrapped__,v=o?[1]:arguments,S=m instanceof ee,P=v[0],I=S||z(m),x=function(J){var te=h.apply(f,en([J],v));return o&&D?te[0]:te};I&&s&&typeof P=="function"&&P.length!=1&&(S=I=!1);var D=this.__chain__,k=!!this.__actions__.length,G=g&&!D,Y=S&&!k;if(!g&&I){m=Y?m:new ee(this);var V=e.apply(m,v);return V.__actions__.push({func:Wi,args:[x],thisArg:r}),new ct(V,D)}return G&&Y?e.apply(this,v):(V=this.thru(x),G?o?V.value()[0]:V.value():V)})}),et(["pop","push","shift","sort","splice","unshift"],function(e){var t=di[e],s=/^(?:push|sort|unshift)$/.test(e)?"tap":"thru",o=/^(?:pop|shift)$/.test(e);f.prototype[e]=function(){var h=arguments;if(o&&!this.__chain__){var g=this.value();return t.apply(z(g)?g:[],h)}return this[s](function(m){return t.apply(z(m)?m:[],h)})}}),Ut(ee.prototype,function(e,t){var s=f[t];if(s){var o=s.name+"";se.call(Zn,o)||(Zn[o]=[]),Zn[o].push({name:t,func:s})}}),Zn[Oi(r,ie).name]=[{name:"wrapper",func:r}],ee.prototype.clone=Yf,ee.prototype.reverse=Xf,ee.prototype.value=Zf,f.prototype.at=bp,f.prototype.chain=Ap,f.prototype.commit=Pp,f.prototype.next=Ip,f.prototype.plant=Lp,f.prototype.reverse=Np,f.prototype.toJSON=f.prototype.valueOf=f.prototype.value=Up,f.prototype.first=f.prototype.head,Ir&&(f.prototype[Ir]=xp),f}),Kn=Pf();Cn?((Cn.exports=Kn)._=Kn,bs._=Kn):Le._=Kn}).call(Dv)})(Br,Br.exports)),Br.exports}var Fl=Mv();const M={getRandomId:()=>window.crypto.getRandomValues(new Uint32Array(1))[0],isPromise:i=>i&&M.isFunction(i.then),isFunction:i=>i&&{}.toString.call(i)==="[object Function]",isAsyncFunction:i=>i&&{}.toString.call(i)==="[object AsyncFunction]",isString:i=>typeof i=="string"||i instanceof String,isObject:i=>!!(i&&typeof i=="object"&&!Array.isArray(i)),hasHash:i=>!!(i&&i.search(/^[#\/].*$/)===0),getPathWithoutHash:i=>{for(;M.hasHash(i);)i=i.substring(1,i.length);return i},getTrimmedUrl:i=>{const n=i.length>0?M.getPathWithoutHash(i):i;return M.trimTrailingSlash(n.split("?")[0])},addLeadingSlash:i=>(i.startsWith("/")?"":"/")+i,trimLeadingSlash:i=>M.isString(i)?i.replace(/^\/+/g,""):"",trimTrailingSlash:i=>M.isString(i)?i.replace(/\/+$/,""):"",isElementVisible:i=>i?window.getComputedStyle(i).getPropertyValue("display")!=="none":!1,getNodeList:(i,n=!1)=>{const r=[];return i&&Array.from(document.querySelectorAll(i)).forEach(u=>{n?M.isElementVisible(u)&&r.push(u):r.push(u)}),r},prependOrigin:i=>{if(!i||i.startsWith("http"))return i;const n=i.startsWith("/");return i.length?window.location.origin+(n?"":"/")+i:window.location.origin},getConfigValueFromObject:(i,n)=>{let r=0,a=i;const u=n.split(".");for(;a&&r<u.length;)a=a[u[r++]];return a},getConfigBooleanValue:(i,n)=>{const r=M.getConfigValueFromObject(i,n);return r===!0||r==="true"},getUrlParameter:i=>new URLSearchParams(window.location.search).get(i),removeProperties(i,n){const r={};if(!(n instanceof Array)||!n.length)return console.error("[ERROR] removeProperties requires second parameter: array of keys to remove from object."),i;for(const a in i)if(i.hasOwnProperty(a)){const u=n.filter(l=>a.includes(l)).length===0,c=n.filter(l=>l.endsWith("*")).map(l=>l.slice(0,-1)).filter(l=>a.startsWith(l)).length===0;u&&c&&(r[a]=i[a])}return r},replaceVars(i,n,r,a=!0){let u=i;return n&&(a?u=Fl.replace(u,/{([\s\S]+?)}/g,c=>{let l=c.slice(1,-1).trim();return l.indexOf(r)===0&&(l=l.substring(r.length)),Fl.get(n,l,c)}):Object.entries(n).forEach(c=>{u=u.replace(new RegExp(this.escapeRegExp(r+c[0]),"g"),encodeURIComponent(c[1]))})),a&&(u=u.replace(new RegExp("\\{"+this.escapeRegExp(r)+"[^\\}]+\\}","g"),"")),u},escapeRegExp(i){return i.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")},hasHashOrSlash:i=>!!(i&&i.search(/^[#\/].*$/)===0),getPathWithoutHashOrSlash:i=>{for(;M.hasHashOrSlash(i);)i=i.substring(1,i.length);return i}},$n={wrapAsPromise:i=>new Promise(n=>{n(i)}),applyFunctionPromisified:(i,n)=>(i=i.apply(void 0,n),M.isPromise(i)?i:$n.wrapAsPromise(i)),getConfigValueFromObjectAsync:(i,n,...r)=>{const a=M.getConfigValueFromObject(i,n);return M.isFunction(a)?$n.applyFunctionPromisified(a,r):$n.wrapAsPromise(a)}};class Fv{setErrorMessage(n){this.getLuigi().getEngine()?._connector?.showFatalError(n)}getLuigi(){return window.Luigi}getConfigValue(n){return this.getLuigi().getConfigValue(n)}getConfigValueAsync(n){return this.getLuigi().getConfigValueAsync(n)}async executeConfigFnAsync(n,r=!1,...a){const u=this.getConfigValue(n);if(M.isFunction(u))try{return await $n.applyFunctionPromisified(u,a)}catch(c){if(r)return Promise.reject(c)}return Promise.resolve(void 0)}}const Xe=new Fv;class kv{constructor(){this._internalStorage={},this._defaultStorage="localStorage",this._authKey="luigi.auth",this._newlyAuthorizedKey="luigi.newlyAuthorized",this._invalidStorageMsg="Configuration Error: Invalid auth.storage value defined. Must be one of localStorage, sessionStorage or none."}reset(){this._storageType=void 0}getStorageKey(){return this._authKey}getStorageType(){return this._storageType||(this._storageType=Xe.getConfigValue("auth.storage")||this._defaultStorage),this._storageType}getAuthData(){return this._getStore(this.getStorageKey())}setAuthData(n){this._setStore(this.getStorageKey(),n)}removeAuthData(){this._setStore(this.getStorageKey(),void 0)}isNewlyAuthorized(){return!!this._getStore(this._newlyAuthorizedKey)}setNewlyAuthorized(){this._setStore(this._newlyAuthorizedKey,!0)}removeNewlyAuthorized(){this._setStore(this._newlyAuthorizedKey,void 0)}_getWebStorage(n){return window[n]}_setStore(n,r){switch(this.getStorageType()){case"localStorage":case"sessionStorage":r!==void 0?this._getWebStorage(this.getStorageType()).setItem(n,JSON.stringify(r)):this._getWebStorage(this.getStorageType()).removeItem(n);break;case"none":this._internalStorage[n]=r;break;default:console.error(this._invalidStorageMsg)}}_getStore(n){try{switch(this.getStorageType()){case"localStorage":case"sessionStorage":return JSON.parse(this._getWebStorage(this.getStorageType()).getItem(n));case"none":return this._internalStorage[n];default:console.error(this._invalidStorageMsg)}}catch{console.warn("Error parsing authorization data. Auto-logout might not work!")}}}const At=new kv;class Hv{isAuthorizationEnabled(){return!!Xe.getConfigValue("auth.use")}login(){this.isAuthorizationEnabled()&&fr.startAuthorization()}logout(){this.isAuthorizationEnabled()&&fr.logout()}async handleAuthEvent(n,r,a,u){const c=await Xe.executeConfigFnAsync("auth.events."+n,!1,r,a),l=c===void 0||!!c;if(l&&u){window.location.href=u;return}return l}get store(){return Xe.getLuigi()?.initialized||console.warn("Luigi Core is not initialized yet. Consider moving your code to the luigiAfterInit lifecycle hook. Documentation: https://docs.luigi-project.io/docs/lifecycle-hooks"),{getStorageKey:()=>At.getStorageKey(),getStorageType:()=>At.getStorageType(),getAuthData:()=>At.getAuthData(),setAuthData:n=>At.setAuthData(n),removeAuthData:()=>At.removeAuthData(),setNewlyAuthorized:()=>{At.setNewlyAuthorized(),fr.resetExpirationChecks()}}}}const or=new Hv;class Wv{getStoredAuthData(){return At.getAuthData()}isLoggedIn(){const n=this.getStoredAuthData();return!!(n&&n.accessTokenExpirationDate>Number(new Date))}parseUrlAuthErrors(){const n=M.getUrlParameter("error"),r=M.getUrlParameter("errorDescription");if(n)return{error:n,errorDescription:r}}async handleUrlAuthErrors(n,r,a){return r?await or.handleAuthEvent("onAuthError",n,{error:r,errorDescription:a},n.logoutUrl+"?post_logout_redirect_uri="+n.post_logout_redirect_uri+"&error="+encodeURIComponent(r)+"&errorDescription="+encodeURIComponent(a||"")):!0}}const Un=new Wv;class Vv{constructor(){this._userInfoStore=ns({}),this._loggedInStore=ns(!1)}setUserInfo(n){this._userInfoStore.set(n)}setLoggedIn(n){this._loggedInStore.set(n)}getUserInfoStore(){return this._userInfoStore}getLoggedInStore(){return this._loggedInStore}async init(){const n=Xe.getConfigValue("auth.use");if(!n)return Promise.resolve(!0);const r=Xe.getConfigValue(`auth.${n}`),a=Un.parseUrlAuthErrors()||{};if(await Un.handleUrlAuthErrors(r,a.error,a.errorDescription))return this.idpProviderInstance=this.getIdpProviderInstance(n,r),M.isPromise(this.idpProviderInstance)?this.idpProviderInstance.then(c=>(this.idpProviderInstance=c,this.checkAuth(r))).catch(c=>{const l=`Error: ${c.message||c}`;console.error(l,c.message&&c),Xe.setErrorMessage(l)}):this.checkAuth(r)}async checkAuth(n){const r=Un.getStoredAuthData();if(!r||!Un.isLoggedIn()){if(Xe.getConfigValue("auth.disableAutoLogin"))return;let u=!0;return r&&(u=await or.handleAuthEvent("onAuthExpired",n)),u?this.startAuthorization():void 0}this.idpProviderInstance.settings&&M.isFunction(this.idpProviderInstance.settings.userInfoFn)?this.idpProviderInstance.settings.userInfoFn(this.idpProviderInstance.settings,r).then(u=>{this.setUserInfo(u),this.setLoggedIn(!0)}):M.isFunction(this.idpProviderInstance.userInfo)?this.idpProviderInstance.userInfo(n).then(u=>{this.setUserInfo(u),this.setLoggedIn(!0)}):(this.setLoggedIn(!0),this.setUserInfo(ac(this._userInfoStore))),M.isFunction(Xe.getConfigValue("auth.events.onAuthSuccessful"))&&At.isNewlyAuthorized()&&await or.handleAuthEvent("onAuthSuccessful",n,r),At.removeNewlyAuthorized(),M.isFunction(this.idpProviderInstance.setTokenExpirationAction)&&this.idpProviderInstance.setTokenExpirationAction(),M.isFunction(this.idpProviderInstance.setTokenExpireSoonAction)&&this.idpProviderInstance.setTokenExpireSoonAction()}async startAuthorization(){if(this.idpProviderInstance)return this.idpProviderInstance.login().then(n=>{At.setNewlyAuthorized(),n&&console.error(n)})}logout(){const n=Un.getStoredAuthData(),r=async c=>{await or.handleAuthEvent("onLogout",this.idpProviderInstance.settings,void 0,c),At.removeAuthData()},a=Xe.getConfigValue(`auth.${Xe.getConfigValue("auth.use")}.logoutFn`),u=Xe.getConfigValueAsync("navigation.profile.logout.customLogoutFn");M.isFunction(a)?a(this.idpProviderInstance.settings,n,r):M.isFunction(this.idpProviderInstance.logout)?this.idpProviderInstance.logout(n,r):u&&M.isFunction(u)?u(n,r):r(this.idpProviderInstance.settings.logoutUrl)}createIdpProviderException(n){return{message:n,name:"IdpProviderException"}}async getIdpProviderInstance(n,r){const a=M.getConfigValueFromObject(r,"idpProvider");if(a){const c=await new a(r);return["login"].forEach(l=>{if(!M.isFunction(c[l]))throw this.createIdpProviderException(`${l} function does not exist in custom IDP Provider ${n}`)}),c}if(M.isFunction(Xe.getConfigValue("auth.events.onAuthConfigError")))await or.handleAuthEvent("onAuthConfigError",{idpProviderName:n,type:"IdpProviderException"});else throw this.createIdpProviderException(`IDP Provider ${n} does not exist.`)}unload(){this.idpProviderInstance&&M.isFunction(this.idpProviderInstance.unload)&&this.idpProviderInstance.unload()}resetExpirationChecks(){this.idpProviderInstance&&M.isFunction(this.idpProviderInstance.resetExpirationChecks)&&this.idpProviderInstance.resetExpirationChecks()}}const fr=new Vv,Bv={luigi:{button:{confirm:"Yes",dismiss:"No"},confirmationModal:{body:"Are you sure you want to do this?",header:"Confirmation"},navigation:{up:"Up"},notExactTargetNode:"Could not map the exact target node for the requested route {route}.",requestedRouteNotFound:"Could not find the requested route {route}.",unsavedChangesAlert:{body:"Unsaved changes will be lost. Do you want to continue?",header:"Unsaved changes detected"}}},Gv=Bv,rs={sanitizeHtml(i=""){return i.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/'/g,"&#39;").replace(/javascript:/gi,"").replace(/data:/gi,"").replace(/vbscript:/gi,"")},restoreSanitizedBrs(i=""){return i.replace(/&lt;br\/&gt;/g,"<br>").replace(/&lt;br \/&gt;/g,"<br>").replace(/&lt;br&gt;/g,"<br>").replace(/&lt;br &gt;/g,"<br>")},restoreSanitizedElements(i=""){let n=i;const r=["i","b","br","mark","strong","em","small","del","ins","sub","sup"];for(let a=0;a<r.length;a++){const u=new RegExp(`&lt;${r[a]}/&gt;`,"g"),c=new RegExp(`&lt;${r[a]} /&gt;`,"g"),l=new RegExp(`&lt;${r[a]}&gt;`,"g"),d=new RegExp(`&lt;${r[a]} &gt;`,"g"),p=new RegExp(`&lt;/${r[a]}[/]&gt;`,"g"),_=new RegExp(`&lt;/${r[a]} [/]&gt;`,"g"),R=new RegExp(`&lt;[/]${r[a]}&gt;`,"g"),T=new RegExp(`&lt;[/]${r[a]} &gt;`,"g");n=n.replace(u,`<${r[a]}>`).replace(c,`<${r[a]}>`).replace(l,`<${r[a]}>`).replace(d,`<${r[a]}>`).replace(p,`</${r[a]}>`).replace(_,`</${r[a]}>`).replace(R,`</${r[a]}>`).replace(T,`</${r[a]}>`)}return n},sanatizeHtmlExceptTextFormatting(i=""){return this.restoreSanitizedElements(this.sanitizeHtml(i))},sanitizeParam(i=""){return String(i).replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/'/g,"&#39;").replace(/\//g,"&sol;")},escapeKeyForRegexp(i=""){return i.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&")},processTextAndLinks(i="",n,r){const u={sanitizedText:this.restoreSanitizedBrs(this.sanitizeHtml(i)),links:[]};return n?Object.entries(n).reduce((c,[l,d])=>{const p=`_luigi_alert_${r}_link_${this.sanitizeParam(l)}`,_=this.restoreSanitizedBrs(this.sanitizeHtml(d.text)),R=`<a id="${p}">${_}</a>`,T=this.escapeKeyForRegexp(l),E=new RegExp(`({${T}})`,"g");return{sanitizedText:c.sanitizedText.replace(E,R),links:c.links.concat({elemId:p,url:d.url?encodeURI(this.sanitizeHtml(d.url)):void 0,dismissKey:d.dismissKey?encodeURI(this.sanitizeHtml(d.dismissKey)):void 0})}},u):u}};class Qv{constructor(n){this.luigi=n,this.currentLocaleStorageKey="luigi.currentLocale",this.defaultLocale="en",this.listeners={},this.translationTable=Gv}_init(){this._initCustomImplementation(),this.addCurrentLocaleChangeListener(n=>{this.broadcastLocaleToAllContainers(n)})}getCurrentLocale(){return sessionStorage.getItem(this.currentLocaleStorageKey)||this.defaultLocale}setCurrentLocale(n,r){if(!r?.clientPermissions?.changeCurrentLocale){console.error('Current locale change declined from client, as client permission "changeCurrentLocale" is not set for this view.');return}n&&(r&&(r.locale=n),sessionStorage.setItem(this.currentLocaleStorageKey,n),this._notifyLocaleChange(n)),this.luigi.getEngine()._connector?.setCurrentLocale(n)}addCurrentLocaleChangeListener(n){let r=null;return M.isFunction(n)?(r=M.getRandomId(),this.listeners[r]=n):console.error("Provided locale change listener is not a function."),r}removeCurrentLocaleChangeListener(n){n&&this.listeners[n]?delete this.listeners[n]:console.error("Unable to remove locale change listener - no listener registered for given ID.")}getTranslation(n,r=void 0,a=void 0){if(!n)return"";if(this.translationImpl){const c=this.translationImpl.getTranslation(n,r,a);if(c!==n)return c}const u=this.findTranslation(n,this.translationTable,r);return u||n}_notifyLocaleChange(n){Object.getOwnPropertyNames(this.listeners).forEach(r=>{this.listeners[Number(r)](n)}),this.luigi.configChanged()}_initCustomImplementation(){this.translationImpl=this.luigi.getConfigValue("settings.customTranslationImplementation"),M.isFunction(this.translationImpl)&&(this.translationImpl=this.translationImpl())}broadcastLocaleToAllContainers(n){const r=M.getNodeList("luigi-container[lui_container]");r?.length&&n&&r.forEach(a=>{a.locale=n,a.updateContext({locale:n})})}findTranslation(n,r,a){const u=n.split(".");for(let c=0;c<u.length;c++){const l=u[c];if(Object.prototype.hasOwnProperty.call(r,l)&&typeof r[l]=="object")r=r[l];else return a?this.findInterpolations(r[l],a):r[l]}}findInterpolations(n,r){return typeof n!="string"||!n.trim()||Object.keys(r).forEach(a=>{n=n.replace(new RegExp("{"+rs.escapeKeyForRegexp(a)+"}","gi"),r[a])}),n}}function fn(){}function oc(i){return i()}function kl(){return Object.create(null)}function is(i){i.forEach(oc)}function uc(i){return typeof i=="function"}function lc(i,n){return i!=i?n==n:i!==n||i&&typeof i=="object"||typeof i=="function"}let Yi,Yr;function Hl(i,n){return i===n||(Yi||(Yi=document.createElement("a")),Yi.href=n,i===Yi.href)}function qv(i,n,r){const a=(function(u){if(!u)return document;const c=u.getRootNode?u.getRootNode():u.ownerDocument;return c&&c.host?c:u.ownerDocument})(i);if(!a.getElementById(n)){const u=pr("style");u.id=n,u.textContent=r,(function(c,l){(function(d,p){d.appendChild(p)})(c.head||c,l),l.sheet})(a,u)}}function Dn(i,n,r){i.insertBefore(n,r||null)}function dn(i){i.parentNode&&i.parentNode.removeChild(i)}function pr(i){return document.createElement(i)}function cc(i){return document.createTextNode(i)}function _t(i,n,r){r==null?i.removeAttribute(n):i.getAttribute(n)!==r&&i.setAttribute(n,r)}function Qr(i){Yr=i}function hc(){if(!Yr)throw new Error("Function called outside component initialization");return Yr}function fc(i){hc().$$.on_mount.push(i)}const sr=[],Xr=[];let dr=[];const Wl=[],zv=Promise.resolve();let Ma=!1;function Fa(i){dr.push(i)}const Na=new Set;let ir=0;function q(){if(ir!==0)return;const i=Yr;do{try{for(;ir<sr.length;){const n=sr[ir];ir++,Qr(n),Kv(n.$$)}}catch(n){throw sr.length=0,ir=0,n}for(Qr(null),sr.length=0,ir=0;Xr.length;)Xr.pop()();for(let n=0;n<dr.length;n+=1){const r=dr[n];Na.has(r)||(Na.add(r),r())}dr.length=0}while(sr.length);for(;Wl.length;)Wl.pop()();Ma=!1,Na.clear(),Qr(i)}function Kv(i){if(i.fragment!==null){i.update(),is(i.before_update);const n=i.dirty;i.dirty=[-1],i.fragment&&i.fragment.p(i.ctx,n),i.after_update.forEach(Fa)}}const Yv=new Set;function Xv(i,n){const r=i.$$;r.fragment!==null&&((function(a){const u=[],c=[];dr.forEach((l=>a.indexOf(l)===-1?u.push(l):c.push(l))),c.forEach((l=>l())),dr=u})(r.after_update),is(r.on_destroy),r.fragment&&r.fragment.d(n),r.on_destroy=r.fragment=null,r.ctx=[])}function Zv(i,n){i.$$.dirty[0]===-1&&(sr.push(i),Ma||(Ma=!0,zv.then(q)),i.$$.dirty.fill(0)),i.$$.dirty[n/31|0]|=1<<n%31}function dc(i,n,r,a,u,c,l=null,d=[-1]){const p=Yr;Qr(i);const _=i.$$={fragment:null,ctx:[],props:c,update:fn,not_equal:u,bound:kl(),on_mount:[],on_destroy:[],on_disconnect:[],before_update:[],after_update:[],context:new Map(n.context||(p?p.$$.context:[])),callbacks:kl(),dirty:d,skip_bound:!1,root:n.target||p.$$.root};l&&l(_.root);let R=!1;if(_.ctx=r?r(i,n.props||{},((C,A,...N)=>{const H=N.length?N[0]:A;return _.ctx&&u(_.ctx[C],_.ctx[C]=H)&&(!_.skip_bound&&_.bound[C]&&_.bound[C](H),R&&Zv(i,C)),A})):[],_.update(),R=!0,is(_.before_update),_.fragment=!!a&&a(_.ctx),n.target){if(n.hydrate){const C=(function(A){return Array.from(A.childNodes)})(n.target);_.fragment&&_.fragment.l(C),C.forEach(dn)}else _.fragment&&_.fragment.c();n.intro&&(T=i.$$.fragment)&&T.i&&(Yv.delete(T),T.i(E)),(function(C,A,N){const{fragment:H,after_update:W}=C.$$;H&&H.m(A,N),Fa((()=>{const ie=C.$$.on_mount.map(oc).filter(uc);C.$$.on_destroy?C.$$.on_destroy.push(...ie):is(ie),C.$$.on_mount=[]})),W.forEach(Fa)})(i,n.target,n.anchor),q()}var T,E;Qr(p)}let gc;function Ji(i,n,r,a){const u=r[i]?.type;if(n=u==="Boolean"&&typeof n!="boolean"?n!=null:n,!a||!r[i])return n;if(a==="toAttribute")switch(u){case"Object":case"Array":return n==null?null:JSON.stringify(n);case"Boolean":return n?"":null;case"Number":return n??null;default:return n}else switch(u){case"Object":case"Array":return n&&JSON.parse(n);case"Boolean":default:return n;case"Number":return n!=null?+n:n}}function pc(i,n,r,a,u,c){let l=class extends gc{constructor(){super(i,r,u),this.$$p_d=n}static get observedAttributes(){return Object.keys(n).map((d=>(n[d].attribute||d).toLowerCase()))}};return Object.keys(n).forEach((d=>{Object.defineProperty(l.prototype,d,{get(){return this.$$c&&d in this.$$c?this.$$c[d]:this.$$d[d]},set(p){p=Ji(d,p,n),this.$$d[d]=p,this.$$c?.$set({[d]:p})}})})),a.forEach((d=>{Object.defineProperty(l.prototype,d,{get(){return this.$$c?.[d]}})})),c&&(l=c(l)),i.element=l,l}typeof HTMLElement=="function"&&(gc=class extends HTMLElement{$$ctor;$$s;$$c;$$cn=!1;$$d={};$$r=!1;$$p_d={};$$l={};$$l_u=new Map;constructor(i,n,r){super(),this.$$ctor=i,this.$$s=n,r&&this.attachShadow({mode:"open"})}addEventListener(i,n,r){if(this.$$l[i]=this.$$l[i]||[],this.$$l[i].push(n),this.$$c){const a=this.$$c.$on(i,n);this.$$l_u.set(n,a)}super.addEventListener(i,n,r)}removeEventListener(i,n,r){if(super.removeEventListener(i,n,r),this.$$c){const a=this.$$l_u.get(n);a&&(a(),this.$$l_u.delete(n))}}async connectedCallback(){if(this.$$cn=!0,!this.$$c){let n=function(c){return()=>{let l;return{c:function(){l=pr("slot"),c!=="default"&&_t(l,"name",c)},m:function(d,p){Dn(d,l,p)},d:function(d){d&&dn(l)}}}};var i=n;if(await Promise.resolve(),!this.$$cn||this.$$c)return;const r={},a=(function(c){const l={};return c.childNodes.forEach((d=>{l[d.slot||"default"]=!0})),l})(this);for(const c of this.$$s)c in a&&(r[c]=[n(c)]);for(const c of this.attributes){const l=this.$$g_p(c.name);l in this.$$d||(this.$$d[l]=Ji(l,c.value,this.$$p_d,"toProp"))}for(const c in this.$$p_d)c in this.$$d||this[c]===void 0||(this.$$d[c]=this[c],delete this[c]);this.$$c=new this.$$ctor({target:this.shadowRoot||this,props:{...this.$$d,$$slots:r,$$scope:{ctx:[]}}});const u=()=>{this.$$r=!0;for(const c in this.$$p_d)if(this.$$d[c]=this.$$c.$$.ctx[this.$$c.$$.props[c]],this.$$p_d[c].reflect){const l=Ji(c,this.$$d[c],this.$$p_d,"toAttribute");l==null?this.removeAttribute(this.$$p_d[c].attribute||c):this.setAttribute(this.$$p_d[c].attribute||c,l)}this.$$r=!1};this.$$c.$$.after_update.push(u),u();for(const c in this.$$l)for(const l of this.$$l[c]){const d=this.$$c.$on(c,l);this.$$l_u.set(l,d)}this.$$l={}}}attributeChangedCallback(i,n,r){this.$$r||(i=this.$$g_p(i),this.$$d[i]=Ji(i,r,this.$$p_d,"toProp"),this.$$c?.$set({[i]:this.$$d[i]}))}disconnectedCallback(){this.$$cn=!1,Promise.resolve().then((()=>{!this.$$cn&&this.$$c&&(this.$$c.$destroy(),this.$$c=void 0)}))}$$g_p(i){return Object.keys(this.$$p_d).find((n=>this.$$p_d[n].attribute===i||!this.$$p_d[n].attribute&&n.toLowerCase()===i))||i}});class _c{$$=void 0;$$set=void 0;$destroy(){Xv(this,1),this.$destroy=fn}$on(n,r){if(!uc(r))return fn;const a=this.$$.callbacks[n]||(this.$$.callbacks[n]=[]);return a.push(r),()=>{const u=a.indexOf(r);u!==-1&&a.splice(u,1)}}$set(n){var r;this.$$set&&(r=n,Object.keys(r).length!==0)&&(this.$$.skip_bound=!0,this.$$set(n),this.$$.skip_bound=!1)}}var j;typeof window<"u"&&(window.__svelte||(window.__svelte={v:new Set})).v.add("4"),(function(i){i.CUSTOM_MESSAGE="custom",i.GET_CONTEXT="luigi.get-context",i.SEND_CONTEXT_HANDSHAKE="luigi.init",i.CONTEXT_RECEIVED="luigi.init.ok",i.NAVIGATION_REQUEST="luigi.navigation.open",i.ALERT_REQUEST="luigi.ux.alert.show",i.ALERT_CLOSED="luigi.ux.alert.hide",i.INITIALIZED="luigi.init.ok",i.ADD_SEARCH_PARAMS_REQUEST="luigi.addSearchParams",i.ADD_NODE_PARAMS_REQUEST="luigi.addNodeParams",i.SHOW_CONFIRMATION_MODAL_REQUEST="luigi.ux.confirmationModal.show",i.CONFIRMATION_MODAL_CLOSED="luigi.ux.confirmationModal.hide",i.SHOW_LOADING_INDICATOR_REQUEST="luigi.show-loading-indicator",i.HIDE_LOADING_INDICATOR_REQUEST="luigi.hide-loading-indicator",i.SET_CURRENT_LOCALE_REQUEST="luigi.ux.set-current-locale",i.LOCAL_STORAGE_SET_REQUEST="storage",i.RUNTIME_ERROR_HANDLING_REQUEST="luigi-runtime-error-handling",i.SET_ANCHOR_LINK_REQUEST="luigi.setAnchor",i.SET_THIRD_PARTY_COOKIES_REQUEST="luigi.third-party-cookie",i.BACK_NAVIGATION_REQUEST="luigi.navigation.back",i.GET_CURRENT_ROUTE_REQUEST="luigi.navigation.currentRoute",i.SEND_CURRENT_ROUTE_ANSWER="luigi.navigation.currentRoute.answer",i.SEND_CONTEXT_OBJECT="luigi.navigate",i.NAVIGATION_COMPLETED_REPORT="luigi.navigate.ok",i.CLOSE_MODAL_ANSWER="luigi.navigation.modal.close",i.UPDATE_MODAL_PATH_DATA_REQUEST="luigi.navigation.updateModalDataPath",i.UPDATE_MODAL_SETTINGS="luigi.navigation.updateModalSettings",i.CHECK_PATH_EXISTS_REQUEST="luigi.navigation.pathExists",i.SEND_PATH_EXISTS_ANSWER="luigi.navigation.pathExists.answer",i.SET_DIRTY_STATUS_REQUEST="luigi.set-page-dirty",i.AUTH_SET_TOKEN="luigi.auth.tokenIssued",i.ADD_BACKDROP_REQUEST="luigi.add-backdrop",i.REMOVE_BACKDROP_REQUEST="luigi.remove-backdrop",i.SET_VIEW_GROUP_DATA_REQUEST="luigi.setVGData",i.CLOSE_CURRENT_MODAL_REQUEST="luigi.close-modal"})(j||(j={}));class Jv extends Event{constructor(n,r,a,u){super(n),this.detail=r,this.payload=a||r||{},this.callbackFn=u}callback(n){this.callbackFn&&this.callbackFn(n)}}const U={ADD_BACKDROP_REQUEST:"add-backdrop-request",ADD_NODE_PARAMS_REQUEST:"add-node-params-request",ADD_SEARCH_PARAMS_REQUEST:"add-search-params-request",ALERT_CLOSED:"close-alert-request",ALERT_REQUEST:"show-alert-request",BACK_NAVIGATION_REQUEST:"navigate-back-request",CHECK_PATH_EXISTS_REQUEST:"check-path-exists-request",CLOSE_CURRENT_MODAL_REQUEST:"close-current-modal-request",CLOSE_USER_SETTINGS_REQUEST:"close-user-settings-request",COLLAPSE_LEFT_NAV_REQUEST:"collapse-leftnav-request",CUSTOM_MESSAGE:"custom-message",GET_CONTEXT_REQUEST:"get-context-request",GET_CURRENT_ROUTE_REQUEST:"get-current-route-request",GO_BACK_REQUEST:"go-back-request",HAS_BACK_REQUEST:"has-back-request",HIDE_LOADING_INDICATOR_REQUEST:"hide-loading-indicator-request",INITIALIZED:"initialized",LOCAL_STORAGE_SET_REQUEST:"set-storage-request",NAVIGATION_COMPLETED_REPORT:"report-navigation-completed-request",NAVIGATION_REQUEST:"navigation-request",OPEN_USER_SETTINGS_REQUEST:"open-user-settings-request",PATH_EXISTS_REQUEST:"path-exists-request",REMOVE_BACKDROP_REQUEST:"remove-backdrop-request",RUNTIME_ERROR_HANDLING_REQUEST:"runtime-error-handling-request",SET_ANCHOR_LINK_REQUEST:"set-anchor-request",SET_CURRENT_LOCALE_REQUEST:"set-current-locale-request",SET_DIRTY_STATUS_REQUEST:"set-dirty-status-request",SET_DOCUMENT_TITLE_REQUEST:"set-document-title-request",SET_THIRD_PARTY_COOKIES_REQUEST:"set-third-party-cookies-request",SET_VIEW_GROUP_DATA_REQUEST:"set-viewgroup-data-request",SHOW_CONFIRMATION_MODAL_REQUEST:"show-confirmation-modal-request",SHOW_LOADING_INDICATOR_REQUEST:"show-loading-indicator-request",UPDATE_MODAL_PATH_DATA_REQUEST:"update-modal-path-data-request",UPDATE_MODAL_SETTINGS_REQUEST:"update-modal-settings-request",UPDATE_TOP_NAVIGATION_REQUEST:"update-top-navigation-request"};class qa{isVisible(n){return!!(n.offsetWidth||n.offsetHeight||n.getClientRects().length)}sendCustomMessageToIframe(n,r,a){const u=a||"custom";if(n?.iframe?.contentWindow){const c=new URL(n.iframe.src);u==="custom"?n.iframe.contentWindow.postMessage({msg:u,data:r},c.origin):n.iframe.contentWindow.postMessage({msg:u,...r},c.origin)}else console.error("Message target could not be resolved")}dispatchWithPayload(n,r,a,u,c){this.dispatch(n,r,a,c,u)}dispatch(n,r,a,u,c){const l=new Jv(n,a,c,u);r.dispatchEvent(l)}getTargetContainer(n){let r;return globalThis.__luigi_container_manager.container.forEach((a=>{a.iframeHandle?.iframe&&a.iframeHandle.iframe.contentWindow===n.source&&(r=a)})),r}getContainerManager(){return globalThis.__luigi_container_manager||(globalThis.__luigi_container_manager={container:[],messageListener:n=>{const r=this.getTargetContainer(n),a=r?.iframeHandle?.iframe?.contentWindow;if(a&&a===n.source)switch(n.data.msg){case j.CUSTOM_MESSAGE:{const u=n.data.data,c=u.id;delete u.id,this.dispatch(U.CUSTOM_MESSAGE,r,{id:c,_metaData:{},data:u})}break;case j.GET_CONTEXT:a.postMessage({msg:j.SEND_CONTEXT_HANDSHAKE,context:r.context||{},internal:{thirdPartyCookieCheck:{disabled:r.skipCookieCheck==="true"},currentTheme:r.theme,currentLocale:r.locale,activeFeatureToggleList:r.activeFeatureToggleList||[],cssVariables:r.cssVariables||{},anchor:r.anchor||"",userSettings:r.userSettings||null,drawer:r.drawer||!1,modal:r.modal||!1,viewStackSize:r.viewStackSize||0,isNavigateBack:r.isNavigateBack||!1},authData:r.authData||{},nodeParams:r.nodeParams||{},searchParams:r.searchParams||{},pathParams:r.pathParams||{}},n.origin);break;case j.NAVIGATION_REQUEST:this.dispatch(U.NAVIGATION_REQUEST,r,n.data.params,(u=>{a.postMessage({msg:j.CLOSE_MODAL_ANSWER,data:u},n.origin)}));break;case j.ALERT_REQUEST:this.dispatchWithPayload(U.ALERT_REQUEST,r,n,n.data?.data?.settings,(u=>{r.notifyAlertClosed(n.data?.data?.settings?.id,u)}));break;case j.INITIALIZED:this.dispatch(U.INITIALIZED,r,n.data?.params||{});break;case j.ADD_SEARCH_PARAMS_REQUEST:this.dispatch(U.ADD_SEARCH_PARAMS_REQUEST,r,{data:n.data.data,keepBrowserHistory:n.data.keepBrowserHistory});break;case j.ADD_NODE_PARAMS_REQUEST:this.dispatch(U.ADD_NODE_PARAMS_REQUEST,r,{data:n.data.data,keepBrowserHistory:n.data.keepBrowserHistory});break;case j.SHOW_CONFIRMATION_MODAL_REQUEST:this.dispatchWithPayload(U.SHOW_CONFIRMATION_MODAL_REQUEST,r,n.data.data,n.data.data?.settings,(u=>{r.notifyConfirmationModalClosed(u)}));break;case j.SHOW_LOADING_INDICATOR_REQUEST:this.dispatch(U.SHOW_LOADING_INDICATOR_REQUEST,r,n);break;case j.HIDE_LOADING_INDICATOR_REQUEST:this.dispatch(U.HIDE_LOADING_INDICATOR_REQUEST,r,n);break;case j.SET_CURRENT_LOCALE_REQUEST:this.dispatchWithPayload(U.SET_CURRENT_LOCALE_REQUEST,r,n,n.data.data);break;case j.LOCAL_STORAGE_SET_REQUEST:this.dispatchWithPayload(U.LOCAL_STORAGE_SET_REQUEST,r,n,n.data.data?.params);break;case j.RUNTIME_ERROR_HANDLING_REQUEST:this.dispatch(U.RUNTIME_ERROR_HANDLING_REQUEST,r,n);break;case j.SET_ANCHOR_LINK_REQUEST:this.dispatchWithPayload(U.SET_ANCHOR_LINK_REQUEST,r,n,n.data.anchor);break;case j.SET_THIRD_PARTY_COOKIES_REQUEST:this.dispatch(U.SET_THIRD_PARTY_COOKIES_REQUEST,r,n);break;case j.BACK_NAVIGATION_REQUEST:{let u=n.data?.goBackContext||{};if(typeof u=="string")try{u=JSON.parse(u)}catch(c){console.warn(c)}this.dispatch(U.GO_BACK_REQUEST,r,u),this.dispatch(U.BACK_NAVIGATION_REQUEST,r,n)}break;case j.GET_CURRENT_ROUTE_REQUEST:this.dispatchWithPayload(U.GET_CURRENT_ROUTE_REQUEST,r,n,n.data.data,(u=>{a.postMessage({msg:j.SEND_CURRENT_ROUTE_ANSWER,data:{correlationId:n.data?.data?.id,route:u}},n.origin)}));break;case j.NAVIGATION_COMPLETED_REPORT:this.dispatch(U.NAVIGATION_COMPLETED_REPORT,r,n);break;case j.UPDATE_MODAL_PATH_DATA_REQUEST:this.dispatchWithPayload(U.UPDATE_MODAL_PATH_DATA_REQUEST,r,n,n.data.params);break;case j.UPDATE_MODAL_SETTINGS:this.dispatchWithPayload(U.UPDATE_MODAL_SETTINGS_REQUEST,r,n,{addHistoryEntry:n.data.addHistoryEntry,updatedModalSettings:n.data.updatedModalSettings});break;case j.CHECK_PATH_EXISTS_REQUEST:this.dispatchWithPayload(U.CHECK_PATH_EXISTS_REQUEST,r,n,n.data.data,(u=>{a.postMessage({msg:j.SEND_PATH_EXISTS_ANSWER,data:{correlationId:n.data?.data?.id,pathExists:u}},n.origin)}));break;case j.SET_DIRTY_STATUS_REQUEST:this.dispatchWithPayload(U.SET_DIRTY_STATUS_REQUEST,r,n,{dirty:n.data.dirty});break;case j.SET_VIEW_GROUP_DATA_REQUEST:this.dispatch(U.SET_VIEW_GROUP_DATA_REQUEST,r,n.data.data);break;case j.ADD_BACKDROP_REQUEST:this.dispatch(U.ADD_BACKDROP_REQUEST,r,n);break;case j.REMOVE_BACKDROP_REQUEST:this.dispatch(U.REMOVE_BACKDROP_REQUEST,r,n);break;case j.CLOSE_CURRENT_MODAL_REQUEST:this.dispatch(U.CLOSE_CURRENT_MODAL_REQUEST,r,n)}}},window.addEventListener("message",globalThis.__luigi_container_manager.messageListener)),globalThis.__luigi_container_manager}registerContainer(n){this.getContainerManager().container.push(n)}}const hn=new qa,ar=new class{constructor(){this.updateContext=(i,n,r,a,u,c)=>{if(r){const l=n||{};hn.sendCustomMessageToIframe(r,{context:i,nodeParams:a||{},pathParams:u||{},searchParams:c||{},internal:l,withoutSync:!0},j.SEND_CONTEXT_OBJECT)}else console.warn("Attempting to update context on inexisting iframe")},this.updateViewUrl=(i,n,r,a)=>{if(a){const u=r||{};hn.sendCustomMessageToIframe(a,{context:n,internal:u,withoutSync:!1,viewUrl:i},j.SEND_CONTEXT_OBJECT)}else console.warn("Attempting to update route on inexisting iframe")},this.updateAuthData=(i,n)=>{i&&n?hn.sendCustomMessageToIframe(i,{authData:n},j.AUTH_SET_TOKEN):console.warn("Attempting to update auth data on inexisting iframe or authData")},this.sendCustomMessage=(i,n,r,a,u)=>{if(r&&n._luigi_mfe_webcomponent)hn.dispatch(i,n._luigi_mfe_webcomponent,u);else{const c={...u};c.id&&console.warn('Property "id" is reserved and can not be used in custom message data'),c.id=i,hn.sendCustomMessageToIframe(a,c)}},this.notifyConfirmationModalClosed=(i,n)=>{const r={data:{confirmed:i}};hn.sendCustomMessageToIframe(n,r,j.CONFIRMATION_MODAL_CLOSED)}}notifyAlertClosed(i,n,r){const a=n?{id:i,dismissKey:n}:{id:i};hn.sendCustomMessageToIframe(r,a,j.ALERT_CLOSED)}},Vl=i=>{if(!i)return;const n=i;return n.forEach(((r,a)=>{n[a]=r+(r.indexOf(";")!=-1?"":";"),n[a]=i[a].replaceAll('"',"'")})),n.join(" ")};class _r{constructor(n){n?(this.rendererObject=n,this.config=n.config||{}):this.config={}}createCompoundContainer(){return document.createElement("div")}createCompoundItemContainer(n){return document.createElement("div")}attachCompoundItem(n,r){n.appendChild(r)}}class jv extends _r{constructor(n){super(n||{use:{}}),n&&n.use&&n.use.extends&&(this.superRenderer=mc({use:n.use.extends,config:n.config}))}createCompoundContainer(){return this.rendererObject.use.createCompoundContainer?this.rendererObject.use.createCompoundContainer(this.config,this.superRenderer):this.superRenderer?this.superRenderer.createCompoundContainer():super.createCompoundContainer()}createCompoundItemContainer(n){return this.rendererObject.use.createCompoundItemContainer?this.rendererObject.use.createCompoundItemContainer(n,this.config,this.superRenderer):this.superRenderer?this.superRenderer.createCompoundItemContainer(n):super.createCompoundItemContainer(n)}attachCompoundItem(n,r){this.rendererObject.use.attachCompoundItem?this.rendererObject.use.attachCompoundItem(n,r,this.superRenderer):this.superRenderer?this.superRenderer.attachCompoundItem(n,r):super.attachCompoundItem(n,r)}}class ew extends _r{createCompoundContainer(){const n="__lui_compound_"+new Date().getTime(),r=document.createElement("div");r.classList.add(n);let a="";return this.config.layouts&&this.config.layouts.forEach((u=>{if(u.minWidth||u.maxWidth){let c="@media only screen ";u.minWidth!=null&&(c+=`and (min-width: ${u.minWidth}px) `),u.maxWidth!=null&&(c+=`and (max-width: ${u.maxWidth}px) `),c+=`{
21
- .${n} {
22
- grid-template-columns: ${u.columns||"auto"};
23
- grid-template-rows: ${u.rows||"auto"};
24
- grid-gap: ${u.gap||"0"};
19
+ `)+U+`return __p
20
+ }`;var ie=rh(function(){return ve(v,B+"return "+U).apply(n,S)});if(ie.source=U,ul(ie))throw ie;return ie}function uy(e){return Se(e).toLowerCase()}function cy(e){return Se(e).toUpperCase()}function fy(e,i,o){if(e=Se(e),e&&(o||i===n))return cc(e);if(!e||!(i=Tt(i)))return e;var c=Xt(e),d=Xt(i),v=fc(c,d),S=hc(c,d)+1;return Xn(c,v,S).join("")}function hy(e,i,o){if(e=Se(e),e&&(o||i===n))return e.slice(0,gc(e)+1);if(!e||!(i=Tt(i)))return e;var c=Xt(e),d=hc(c,Xt(i))+1;return Xn(c,0,d).join("")}function dy(e,i,o){if(e=Se(e),e&&(o||i===n))return e.replace(lo,"");if(!e||!(i=Tt(i)))return e;var c=Xt(e),d=fc(c,Xt(i));return Xn(c,d).join("")}function gy(e,i){var o=ut,c=ct;if(Ne(i)){var d="separator"in i?i.separator:d;o="length"in i?re(i.length):o,c="omission"in i?Tt(i.omission):c}e=Se(e);var v=e.length;if(ei(e)){var S=Xt(e);v=S.length}if(o>=v)return e;var y=o-ti(c);if(y<1)return c;var T=S?Xn(S,0,y).join(""):e.slice(0,y);if(d===n)return T+c;if(S&&(y+=T.length-y),cl(d)){if(e.slice(y).search(d)){var x,L=T;for(d.global||(d=Ro(d.source,Se(Nu.exec(d))+"g")),d.lastIndex=0;x=d.exec(L);)var U=x.index;T=T.slice(0,U===n?y:U)}}else if(e.indexOf(Tt(d),y)!=y){var F=T.lastIndexOf(d);F>-1&&(T=T.slice(0,F))}return T+c}function py(e){return e=Se(e),e&&Pg.test(e)?e.replace(Pu,Qp):e}var vy=li(function(e,i,o){return e+(o?" ":"")+i.toUpperCase()}),gl=nf("toUpperCase");function nh(e,i,o){return e=Se(e),i=o?n:i,i===n?Hp(e)?Kp(e):Lp(e):e.match(i)||[]}var rh=se(function(e,i){try{return Et(e,n,i)}catch(o){return ul(o)?o:new Y(o)}}),_y=Nn(function(e,i){return Ct(i,function(o){o=en(o),gn(e,o,ol(e[o],e))}),e});function my(e){var i=e==null?0:e.length,o=z();return e=i?xe(e,function(c){if(typeof c[1]!="function")throw new Ut(u);return[o(c[0]),c[1]]}):[],se(function(c){for(var d=-1;++d<i;){var v=e[d];if(Et(v[0],this,c))return Et(v[1],this,c)}})}function wy(e){return Qv(Mt(e,m))}function pl(e){return function(){return e}}function Sy(e,i){return e==null||e!==e?i:e}var yy=sf(),Ey=sf(!0);function gt(e){return e}function vl(e){return Uc(typeof e=="function"?e:Mt(e,m))}function Cy(e){return Mc(Mt(e,m))}function by(e,i){return kc(e,Mt(i,m))}var Ty=se(function(e,i){return function(o){return Zi(o,e,i)}}),Ry=se(function(e,i){return function(o){return Zi(e,o,i)}});function _l(e,i,o){var c=Be(i),d=na(i,c);o==null&&!(Ne(i)&&(d.length||!c.length))&&(o=i,i=e,e=this,d=na(i,Be(i)));var v=!(Ne(o)&&"chain"in o)||!!o.chain,S=Un(e);return Ct(d,function(y){var T=i[y];e[y]=T,S&&(e.prototype[y]=function(){var x=this.__chain__;if(v||x){var L=e(this.__wrapped__),U=L.__actions__=ft(this.__actions__);return U.push({func:T,args:arguments,thisArg:e}),L.__chain__=x,L}return T.apply(e,qn([this.value()],arguments))})}),e}function Ay(){return Ke._===this&&(Ke._=ev),this}function ml(){}function Py(e){return e=re(e),se(function(i){return $c(i,e)})}var Iy=Ko(xe),xy=Ko(sc),Ly=Ko(wo);function ih(e){return tl(e)?So(en(e)):l_(e)}function Ny(e){return function(i){return e==null?n:Ar(e,i)}}var Oy=of(),Uy=of(!0);function wl(){return[]}function Sl(){return!1}function Dy(){return{}}function My(){return""}function ky(){return!0}function $y(e,i){if(e=re(e),e<1||e>St)return[];var o=Ae,c=Ze(e,Ae);i=z(i),e-=Ae;for(var d=Co(c,i);++o<e;)i(o);return d}function Fy(e){return X(e)?xe(e,en):Rt(e)?[e]:ft(Cf(Se(e)))}function Hy(e){var i=++Xp;return Se(e)+i}var Vy=la(function(e,i){return e+i},0),Wy=jo("ceil"),By=la(function(e,i){return e/i},1),Gy=jo("floor");function Qy(e){return e&&e.length?ta(e,gt,Uo):n}function qy(e,i){return e&&e.length?ta(e,z(i,2),Uo):n}function zy(e){return lc(e,gt)}function Ky(e,i){return lc(e,z(i,2))}function jy(e){return e&&e.length?ta(e,gt,$o):n}function Yy(e,i){return e&&e.length?ta(e,z(i,2),$o):n}var Jy=la(function(e,i){return e*i},1),Xy=jo("round"),Zy=la(function(e,i){return e-i},0);function eE(e){return e&&e.length?Eo(e,gt):0}function tE(e,i){return e&&e.length?Eo(e,z(i,2)):0}return p.after=bw,p.ary=Uf,p.assign=fS,p.assignIn=Kf,p.assignInWith=jf,p.assignWith=fl,p.at=hS,p.before=Df,p.bind=ol,p.bindAll=_y,p.bindKey=Mf,p.castArray=Mw,p.chain=Lf,p.chunk=Q_,p.compact=q_,p.concat=z_,p.cond=my,p.conforms=wy,p.constant=pl,p.countBy=tw,p.create=dS,p.curry=kf,p.curryRight=$f,p.debounce=Ff,p.defaults=gS,p.defaultsDeep=pS,p.defer=Tw,p.delay=Rw,p.difference=K_,p.differenceBy=j_,p.differenceWith=Y_,p.drop=J_,p.dropRight=X_,p.dropRightWhile=Z_,p.dropWhile=em,p.fill=tm,p.filter=rw,p.flatMap=aw,p.flatMapDeep=ow,p.flatMapDepth=lw,p.flatten=Af,p.flattenDeep=nm,p.flattenDepth=rm,p.flip=Aw,p.flow=yy,p.flowRight=Ey,p.fromPairs=im,p.functions=ES,p.functionsIn=CS,p.groupBy=uw,p.initial=am,p.intersection=om,p.intersectionBy=lm,p.intersectionWith=um,p.invert=TS,p.invertBy=RS,p.invokeMap=fw,p.iteratee=vl,p.keyBy=hw,p.keys=Be,p.keysIn=dt,p.map=pa,p.mapKeys=PS,p.mapValues=IS,p.matches=Cy,p.matchesProperty=by,p.memoize=_a,p.merge=xS,p.mergeWith=Yf,p.method=Ty,p.methodOf=Ry,p.mixin=_l,p.negate=ma,p.nthArg=Py,p.omit=LS,p.omitBy=NS,p.once=Pw,p.orderBy=dw,p.over=Iy,p.overArgs=Iw,p.overEvery=xy,p.overSome=Ly,p.partial=ll,p.partialRight=Hf,p.partition=gw,p.pick=OS,p.pickBy=Jf,p.property=ih,p.propertyOf=Ny,p.pull=dm,p.pullAll=If,p.pullAllBy=gm,p.pullAllWith=pm,p.pullAt=vm,p.range=Oy,p.rangeRight=Uy,p.rearg=xw,p.reject=_w,p.remove=_m,p.rest=Lw,p.reverse=sl,p.sampleSize=ww,p.set=DS,p.setWith=MS,p.shuffle=Sw,p.slice=mm,p.sortBy=Cw,p.sortedUniq=Tm,p.sortedUniqBy=Rm,p.split=sy,p.spread=Nw,p.tail=Am,p.take=Pm,p.takeRight=Im,p.takeRightWhile=xm,p.takeWhile=Lm,p.tap=qm,p.throttle=Ow,p.thru=ga,p.toArray=Qf,p.toPairs=Xf,p.toPairsIn=Zf,p.toPath=Fy,p.toPlainObject=zf,p.transform=kS,p.unary=Uw,p.union=Nm,p.unionBy=Om,p.unionWith=Um,p.uniq=Dm,p.uniqBy=Mm,p.uniqWith=km,p.unset=$S,p.unzip=al,p.unzipWith=xf,p.update=FS,p.updateWith=HS,p.values=fi,p.valuesIn=VS,p.without=$m,p.words=nh,p.wrap=Dw,p.xor=Fm,p.xorBy=Hm,p.xorWith=Vm,p.zip=Wm,p.zipObject=Bm,p.zipObjectDeep=Gm,p.zipWith=Qm,p.entries=Xf,p.entriesIn=Zf,p.extend=Kf,p.extendWith=jf,_l(p,p),p.add=Vy,p.attempt=rh,p.camelCase=QS,p.capitalize=eh,p.ceil=Wy,p.clamp=WS,p.clone=kw,p.cloneDeep=Fw,p.cloneDeepWith=Hw,p.cloneWith=$w,p.conformsTo=Vw,p.deburr=th,p.defaultTo=Sy,p.divide=By,p.endsWith=qS,p.eq=tn,p.escape=zS,p.escapeRegExp=KS,p.every=nw,p.find=iw,p.findIndex=Tf,p.findKey=vS,p.findLast=sw,p.findLastIndex=Rf,p.findLastKey=_S,p.floor=Gy,p.forEach=Nf,p.forEachRight=Of,p.forIn=mS,p.forInRight=wS,p.forOwn=SS,p.forOwnRight=yS,p.get=hl,p.gt=Ww,p.gte=Bw,p.has=bS,p.hasIn=dl,p.head=Pf,p.identity=gt,p.includes=cw,p.indexOf=sm,p.inRange=BS,p.invoke=AS,p.isArguments=xr,p.isArray=X,p.isArrayBuffer=Gw,p.isArrayLike=ht,p.isArrayLikeObject=ke,p.isBoolean=Qw,p.isBuffer=Zn,p.isDate=qw,p.isElement=zw,p.isEmpty=Kw,p.isEqual=jw,p.isEqualWith=Yw,p.isError=ul,p.isFinite=Jw,p.isFunction=Un,p.isInteger=Vf,p.isLength=wa,p.isMap=Wf,p.isMatch=Xw,p.isMatchWith=Zw,p.isNaN=eS,p.isNative=tS,p.isNil=rS,p.isNull=nS,p.isNumber=Bf,p.isObject=Ne,p.isObjectLike=De,p.isPlainObject=ss,p.isRegExp=cl,p.isSafeInteger=iS,p.isSet=Gf,p.isString=Sa,p.isSymbol=Rt,p.isTypedArray=ci,p.isUndefined=sS,p.isWeakMap=aS,p.isWeakSet=oS,p.join=cm,p.kebabCase=jS,p.last=$t,p.lastIndexOf=fm,p.lowerCase=YS,p.lowerFirst=JS,p.lt=lS,p.lte=uS,p.max=Qy,p.maxBy=qy,p.mean=zy,p.meanBy=Ky,p.min=jy,p.minBy=Yy,p.stubArray=wl,p.stubFalse=Sl,p.stubObject=Dy,p.stubString=My,p.stubTrue=ky,p.multiply=Jy,p.nth=hm,p.noConflict=Ay,p.noop=ml,p.now=va,p.pad=XS,p.padEnd=ZS,p.padStart=ey,p.parseInt=ty,p.random=GS,p.reduce=pw,p.reduceRight=vw,p.repeat=ny,p.replace=ry,p.result=US,p.round=Xy,p.runInContext=C,p.sample=mw,p.size=yw,p.snakeCase=iy,p.some=Ew,p.sortedIndex=wm,p.sortedIndexBy=Sm,p.sortedIndexOf=ym,p.sortedLastIndex=Em,p.sortedLastIndexBy=Cm,p.sortedLastIndexOf=bm,p.startCase=ay,p.startsWith=oy,p.subtract=Zy,p.sum=eE,p.sumBy=tE,p.template=ly,p.times=$y,p.toFinite=Dn,p.toInteger=re,p.toLength=qf,p.toLower=uy,p.toNumber=Ft,p.toSafeInteger=cS,p.toString=Se,p.toUpper=cy,p.trim=fy,p.trimEnd=hy,p.trimStart=dy,p.truncate=gy,p.unescape=py,p.uniqueId=Hy,p.upperCase=vy,p.upperFirst=gl,p.each=Nf,p.eachRight=Of,p.first=Pf,_l(p,(function(){var e={};return pn(p,function(i,o){we.call(p.prototype,o)||(e[o]=i)}),e})(),{chain:!1}),p.VERSION=s,Ct(["bind","bindKey","curry","curryRight","partial","partialRight"],function(e){p[e].placeholder=p}),Ct(["drop","take"],function(e,i){ce.prototype[e]=function(o){o=o===n?1:We(re(o),0);var c=this.__filtered__&&!i?new ce(this):this.clone();return c.__filtered__?c.__takeCount__=Ze(o,c.__takeCount__):c.__views__.push({size:Ze(o,Ae),type:e+(c.__dir__<0?"Right":"")}),c},ce.prototype[e+"Right"]=function(o){return this.reverse()[e](o).reverse()}}),Ct(["filter","map","takeWhile"],function(e,i){var o=i+1,c=o==Gn||o==wt;ce.prototype[e]=function(d){var v=this.clone();return v.__iteratees__.push({iteratee:z(d,3),type:o}),v.__filtered__=v.__filtered__||c,v}}),Ct(["head","last"],function(e,i){var o="take"+(i?"Right":"");ce.prototype[e]=function(){return this[o](1).value()[0]}}),Ct(["initial","tail"],function(e,i){var o="drop"+(i?"":"Right");ce.prototype[e]=function(){return this.__filtered__?new ce(this):this[o](1)}}),ce.prototype.compact=function(){return this.filter(gt)},ce.prototype.find=function(e){return this.filter(e).head()},ce.prototype.findLast=function(e){return this.reverse().find(e)},ce.prototype.invokeMap=se(function(e,i){return typeof e=="function"?new ce(this):this.map(function(o){return Zi(o,e,i)})}),ce.prototype.reject=function(e){return this.filter(ma(z(e)))},ce.prototype.slice=function(e,i){e=re(e);var o=this;return o.__filtered__&&(e>0||i<0)?new ce(o):(e<0?o=o.takeRight(-e):e&&(o=o.drop(e)),i!==n&&(i=re(i),o=i<0?o.dropRight(-i):o.take(i-e)),o)},ce.prototype.takeRightWhile=function(e){return this.reverse().takeWhile(e).reverse()},ce.prototype.toArray=function(){return this.take(Ae)},pn(ce.prototype,function(e,i){var o=/^(?:filter|find|map|reject)|While$/.test(i),c=/^(?:head|last)$/.test(i),d=p[c?"take"+(i=="last"?"Right":""):i],v=c||/^find/.test(i);d&&(p.prototype[i]=function(){var S=this.__wrapped__,y=c?[1]:arguments,T=S instanceof ce,x=y[0],L=T||X(S),U=function(le){var he=d.apply(p,qn([le],y));return c&&F?he[0]:he};L&&o&&typeof x=="function"&&x.length!=1&&(T=L=!1);var F=this.__chain__,B=!!this.__actions__.length,K=v&&!F,ie=T&&!B;if(!v&&L){S=ie?S:new ce(this);var Q=e.apply(S,y);return Q.__actions__.push({func:ga,args:[U],thisArg:n}),new Dt(Q,F)}return K&&ie?e.apply(this,y):(Q=this.thru(U),K?c?Q.value()[0]:Q.value():Q)})}),Ct(["pop","push","shift","sort","splice","unshift"],function(e){var i=Hs[e],o=/^(?:push|sort|unshift)$/.test(e)?"tap":"thru",c=/^(?:pop|shift)$/.test(e);p.prototype[e]=function(){var d=arguments;if(c&&!this.__chain__){var v=this.value();return i.apply(X(v)?v:[],d)}return this[o](function(S){return i.apply(X(S)?S:[],d)})}}),pn(ce.prototype,function(e,i){var o=p[i];if(o){var c=o.name+"";we.call(si,c)||(si[c]=[]),si[c].push({name:i,func:o})}}),si[oa(n,$).name]=[{name:"wrapper",func:n}],ce.prototype.clone=vv,ce.prototype.reverse=_v,ce.prototype.value=mv,p.prototype.at=zm,p.prototype.chain=Km,p.prototype.commit=jm,p.prototype.next=Ym,p.prototype.plant=Xm,p.prototype.reverse=Zm,p.prototype.toJSON=p.prototype.valueOf=p.prototype.value=ew,p.prototype.first=p.prototype.head,qi&&(p.prototype[qi]=Jm),p}),ni=jp();Er?((Er.exports=ni)._=ni,po._=ni):Ke._=ni}).call(rE)})(as,as.exports)),as.exports}var Ul=iE();const M={getRandomId:()=>window.crypto.getRandomValues(new Uint32Array(1))[0],isPromise:r=>r&&M.isFunction(r.then),isFunction:r=>r&&{}.toString.call(r)==="[object Function]",isAsyncFunction:r=>r&&{}.toString.call(r)==="[object AsyncFunction]",isString:r=>typeof r=="string"||r instanceof String,isObject:r=>!!(r&&typeof r=="object"&&!Array.isArray(r)),hasHash:r=>!!(r&&r.search(/^[#\/].*$/)===0),getPathWithoutHash:r=>{for(;M.hasHash(r);)r=r.substring(1,r.length);return r},getTrimmedUrl:r=>{const t=r.length>0?M.getPathWithoutHash(r):r;return M.trimTrailingSlash(t.split("?")[0])},addLeadingSlash:r=>(r.startsWith("/")?"":"/")+r,trimLeadingSlash:r=>M.isString(r)?r.replace(/^\/+/g,""):"",addTrailingSlash:r=>M.isString(r)?r.replace(/\/?$/,"/"):"",trimTrailingSlash:r=>M.isString(r)?r.replace(/\/+$/,""):"",normalizePath:r=>typeof r!="string"?r:M.addLeadingSlash(M.addTrailingSlash(r)),isElementVisible:r=>r?window.getComputedStyle(r).getPropertyValue("display")!=="none":!1,getNodeList:(r,t=!1)=>{const n=[];return r&&Array.from(document.querySelectorAll(r)).forEach(a=>{t?M.isElementVisible(a)&&n.push(a):n.push(a)}),n},prependOrigin:r=>{if(!r||r.startsWith("http"))return r;const t=r.startsWith("/");return r.length?window.location.origin+(t?"":"/")+r:window.location.origin},getConfigValueFromObject:(r,t)=>{let n=0,s=r;const a=t.split(".");for(;s&&n<a.length;)s=s[a[n++]];return s},getConfigBooleanValue:(r,t)=>{const n=M.getConfigValueFromObject(r,t);return n===!0||n==="true"},getUrlParameter:r=>new URLSearchParams(window.location.search).get(r),removeProperties(r,t){const n={};if(!(t instanceof Array)||!t.length)return console.error("[ERROR] removeProperties requires second parameter: array of keys to remove from object."),r;for(const s in r)if(r.hasOwnProperty(s)){const a=t.filter(u=>s.includes(u)).length===0,l=t.filter(u=>u.endsWith("*")).map(u=>u.slice(0,-1)).filter(u=>s.startsWith(u)).length===0;a&&l&&(n[s]=r[s])}return n},replaceVars(r,t,n,s=!0,a=!1){let l=r;if(t)if(s)l=Ul.replace(l,/{([\s\S]+?)}/g,u=>{let f=u.slice(1,-1).trim();return f.indexOf(n)===0&&(f=f.substring(n.length)),Ul.get(t,f,u)});else{const u=a?" ":"";l=l.replace(/\//g,u+"/")+u,Array.from(Object.entries(t)).sort((f,h)=>h[0].length-f[0].length).forEach(f=>{l=l.replace(new RegExp(this.escapeRegExp(n+f[0]+u),"g"),encodeURIComponent(f[1]))}),l=l.replace(new RegExp(this.escapeRegExp(u),"g"),"")}return s&&(l=l.replace(new RegExp("\\{"+this.escapeRegExp(n)+"[^\\}]+\\}","g"),"")),l},escapeRegExp(r){return r.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")},hasHashOrSlash:r=>!!(r&&r.search(/^[#\/].*$/)===0),getPathWithoutHashOrSlash:r=>{for(;M.hasHashOrSlash(r);)r=r.substring(1,r.length);return r}},kr={wrapAsPromise:r=>new Promise(t=>{t(r)}),applyFunctionPromisified:(r,t)=>(r=r.apply(void 0,t),M.isPromise(r)?r:kr.wrapAsPromise(r)),getConfigValueFromObjectAsync:(r,t,...n)=>{const s=M.getConfigValueFromObject(r,t);return M.isFunction(s)?kr.applyFunctionPromisified(s,n):kr.wrapAsPromise(s)}};class sE{setErrorMessage(t){this.getLuigi().getEngine()?._connector?.showFatalError(t)}getLuigi(){return window.Luigi}getConfigValue(t){return this.getLuigi().getConfigValue(t)}getConfigValueAsync(t){return this.getLuigi().getConfigValueAsync(t)}async executeConfigFnAsync(t,n=!1,...s){const a=this.getConfigValue(t);if(M.isFunction(a))try{return await kr.applyFunctionPromisified(a,s)}catch(l){if(n)return Promise.reject(l)}return Promise.resolve(void 0)}}const ot=new sE;class aE{constructor(){this._internalStorage={},this._defaultStorage="localStorage",this._authKey="luigi.auth",this._newlyAuthorizedKey="luigi.newlyAuthorized",this._invalidStorageMsg="Configuration Error: Invalid auth.storage value defined. Must be one of localStorage, sessionStorage or none."}reset(){this._storageType=void 0}getStorageKey(){return this._authKey}getStorageType(){return this._storageType||(this._storageType=ot.getConfigValue("auth.storage")||this._defaultStorage),this._storageType}getAuthData(){return this._getStore(this.getStorageKey())}setAuthData(t){this._setStore(this.getStorageKey(),t)}removeAuthData(){this._setStore(this.getStorageKey(),void 0)}isNewlyAuthorized(){return!!this._getStore(this._newlyAuthorizedKey)}setNewlyAuthorized(){this._setStore(this._newlyAuthorizedKey,!0)}removeNewlyAuthorized(){this._setStore(this._newlyAuthorizedKey,void 0)}_getWebStorage(t){return window[t]}_setStore(t,n){switch(this.getStorageType()){case"localStorage":case"sessionStorage":n!==void 0?this._getWebStorage(this.getStorageType()).setItem(t,JSON.stringify(n)):this._getWebStorage(this.getStorageType()).removeItem(t);break;case"none":this._internalStorage[t]=n;break;default:console.error(this._invalidStorageMsg)}}_getStore(t){try{switch(this.getStorageType()){case"localStorage":case"sessionStorage":return JSON.parse(this._getWebStorage(this.getStorageType()).getItem(t));case"none":return this._internalStorage[t];default:console.error(this._invalidStorageMsg)}}catch{console.warn("Error parsing authorization data. Auto-logout might not work!")}}}const rn=new aE;class oE{isAuthorizationEnabled(){return!!ot.getConfigValue("auth.use")}login(){this.isAuthorizationEnabled()&&ar.startAuthorization()}logout(){this.isAuthorizationEnabled()&&ar.logout()}async handleAuthEvent(t,n,s,a){const l=await ot.executeConfigFnAsync("auth.events."+t,!1,n,s),u=l===void 0||!!l;if(u&&a){window.location.href=a;return}return u}get store(){return ot.getLuigi()?.initialized||console.warn("Luigi Core is not initialized yet. Consider moving your code to the luigiAfterInit lifecycle hook. Documentation: https://docs.luigi-project.io/docs/lifecycle-hooks"),{getStorageKey:()=>rn.getStorageKey(),getStorageType:()=>rn.getStorageType(),getAuthData:()=>rn.getAuthData(),setAuthData:t=>{rn.setAuthData(t),ar.broadcastAuthData(t)},removeAuthData:()=>rn.removeAuthData(),setNewlyAuthorized:()=>{rn.setNewlyAuthorized(),ar.resetExpirationChecks()}}}}const vi=new oE;class lE{getStoredAuthData(){return rn.getAuthData()}isLoggedIn(){const t=this.getStoredAuthData();return!!(t&&t.accessTokenExpirationDate>Number(new Date))}parseUrlAuthErrors(){const t=M.getUrlParameter("error"),n=M.getUrlParameter("errorDescription");if(t)return{error:t,errorDescription:n}}async handleUrlAuthErrors(t,n,s){return n?await vi.handleAuthEvent("onAuthError",t,{error:n,errorDescription:s},t.logoutUrl+"?post_logout_redirect_uri="+t.post_logout_redirect_uri+"&error="+encodeURIComponent(n)+"&errorDescription="+encodeURIComponent(s||"")):!0}}const ir=new lE;typeof window<"u"&&((window.__svelte??={}).v??=new Set).add("5");let $i=!1;$i=!0;const Pi={},Ge=Symbol(),uE=Symbol("filename"),Gh="http://www.w3.org/1999/xhtml",cE="production";var H=!cE.toLowerCase().startsWith("prod"),fE=Array.isArray,hE=Array.prototype.indexOf,Gr=Array.prototype.includes,dE=Array.from,$a=Object.keys,cn=Object.defineProperty,Hn=Object.getOwnPropertyDescriptor,Qh=Object.getOwnPropertyDescriptors,gE=Object.prototype,pE=Array.prototype,Zl=Object.getPrototypeOf,oh=Object.isExtensible;const vE=()=>{};function _E(r){return r()}function Dl(r){for(var t=0;t<r.length;t++)r[t]()}function qh(){var r,t;return{promise:new Promise((n,s)=>{r=n,t=s}),resolve:r,reject:t}}const Rs=16,As=32,eu=64,Gt=512,He=1024,lt=2048,Cn=4096,Qr=8192,Ii=16384,_r=32768,Ml=1<<25,_s=65536,tu=1<<17,zh=1<<19,Fa=65536,ms=1<<21,mE=1<<22,or=1<<23,wn=Symbol("$state"),Kh=Symbol("legacy props"),wE=Symbol(""),jh=Symbol("proxy path"),Yh=Symbol("attributes"),kl=Symbol("class"),SE=Symbol("style"),yE=Symbol("text"),EE=Symbol("hmr anchor"),Ka=new class extends Error{name="StaleReactionError";message="The reaction that called `getAbortSignal()` was re-run or destroyed"},CE=!!globalThis.document?.contentType&&globalThis.document.contentType.includes("xml");function Jh(r){if(H){const t=new Error(`lifecycle_outside_component
21
+ \`${r}(...)\` can only be used during component initialisation
22
+ https://svelte.dev/e/lifecycle_outside_component`);throw t.name="Svelte error",t}throw new Error("https://svelte.dev/e/lifecycle_outside_component")}var ur="font-weight: bold",cr="font-weight: normal";function ja(r){H?console.warn(`%c[svelte] hydration_mismatch
23
+ %cHydration failed because the initial UI does not match what was rendered on the server
24
+ https://svelte.dev/e/hydration_mismatch`,ur,cr):console.warn("https://svelte.dev/e/hydration_mismatch")}function yl(r){H?console.warn(`%c[svelte] state_proxy_equality_mismatch
25
+ %cReactive \`$state(...)\` proxies and the values they proxy have different identities. Because of this, comparisons with \`${r}\` will produce unexpected results
26
+ https://svelte.dev/e/state_proxy_equality_mismatch`,ur,cr):console.warn("https://svelte.dev/e/state_proxy_equality_mismatch")}let Ee,Ue=!1;function _i(r){Ue=r}function Sn(r){if(r===null)throw ja(),Pi;return Ee=r}function nu(){return Sn(Wn(Ee))}function Xh(r=!0){for(var t=0,n=Ee;;){if(n.nodeType===8){var s=n.data;if(s==="]"){if(t===0)return n;t-=1}else(s==="["||s==="[!"||s[0]==="["&&!isNaN(Number(s.slice(1))))&&(t+=1)}var a=Wn(n);r&&n.remove(),n=a}}function Zh(r){return r===this.v}function ed(r){return t=r,n=this.v,!(t!=t?n==n:t!==n||t!==null&&typeof t=="object"||typeof t=="function");var t,n}function _n(r,t){return r.label=t,td(r.v,t),r}function td(r,t){return r?.[jh]?.(t),r}function nd(r){const t=new Error,n=(function(){const s=Error.stackTraceLimit;Error.stackTraceLimit=1/0;const a=new Error().stack;if(Error.stackTraceLimit=s,!a)return[];const l=a.split(`
27
+ `),u=[];for(let f=0;f<l.length;f++){const h=l[f],g=h.replaceAll("\\","/");if(h.trim()!=="Error"){if(h.includes("validate_each_keys"))return[];g.includes("svelte/src/internal")||g.includes("node_modules/.vite")||u.push(h)}}return u})();return n.length===0?null:(n.unshift(`
28
+ `),cn(t,"stack",{value:n.join(`
29
+ `)}),cn(t,"name",{value:r}),t)}function bE(r,t){if(!H)throw new Error("invariant(...) was not guarded by if (DEV)");r||(function(n){if(H){const s=new Error(`invariant_violation
30
+ An invariant violation occurred, meaning Svelte's internal assumptions were flawed. This is a bug in Svelte, not your app — please open an issue at https://github.com/sveltejs/svelte, citing the following message: "${n}"
31
+ https://svelte.dev/e/invariant_violation`);throw s.name="Svelte error",s}throw new Error("https://svelte.dev/e/invariant_violation")})(t)}let be=null;function xi(r){be=r}let ws=null;function Ha(r){ws=r}let Ps=null;function lh(r){Ps=r}function ru(r,t=!1,n){be={p:be,i:!1,c:null,e:null,s:r,x:null,r:te,l:$i&&!t?{s:null,u:null,$:[]}:null},H&&(be.function=n,Ps=n)}function iu(r){var t=be,n=t.e;if(n!==null)for(var s of(t.e=null,n))Cd(s);return r!==void 0&&(t.x=r),t.i=!0,be=t.p,H&&(Ps=be?.function??null),r??{}}function Is(){return!$i||be!==null&&be.l===null}let Ur=[];function rd(){var r=Ur;Ur=[],Dl(r)}function mi(r){if(Ur.length===0&&!us){var t=Ur;queueMicrotask(()=>{t===Ur&&rd()})}Ur.push(r)}function TE(){for(;Ur.length>0;)rd()}const $l=new WeakMap;function id(r){var t=te;if(t===null)return ge.f|=or,r;if(H&&r instanceof Error&&!$l.has(r)&&$l.set(r,(function(n,s){const a=Hn(n,"message");if(!(a&&!a.configurable)){for(var l=fu?" ":" ",u=`
32
+ ${l}in ${s.fn?.name||"<unknown>"}`,f=s.ctx;f!==null;)u+=`
33
+ ${l}in ${f.function?.[uE].split("/").pop()}`,f=f.p;return{message:n.message+`
34
+ ${u}
35
+ `,stack:n.stack?.split(`
36
+ `).filter(h=>!h.includes("svelte/src/internal")).join(`
37
+ `)}}})(r,t)),(t.f&_r)===0&&!(4&t.f))throw H&&!t.parent&&r instanceof Error&&sd(r),r;sr(r,t)}function sr(r,t){for(;t!==null;){if(128&t.f){if((t.f&_r)===0)throw r;try{return void t.b.error(r)}catch(n){r=n}}t=t.parent}throw H&&r instanceof Error&&sd(r),r}function sd(r){const t=$l.get(r);t&&(cn(r,"message",{value:t.message}),cn(r,"stack",{value:t.stack}))}const RE=-7169;function Oe(r,t){r.f=r.f&RE|t}function su(r){(r.f&Gt)!==0||r.deps===null?Oe(r,He):Oe(r,Cn)}function ad(r){if(r!==null)for(const t of r)2&t.f&&(t.f&Fa)!==0&&(t.f^=Fa,ad(t.deps))}function od(r,t,n){(r.f&lt)!==0?t.add(r):(r.f&Cn)!==0&&n.add(r),ad(r.deps),Oe(r,He)}let Ea=!1,El=null,hi=null,fe=null,Fl=null,sn=null,Cl=null,us=!1,bl=!1,wi=null,La=null;var uh=0,Tl=new Set;let AE=1;class Vn{id=AE++;#e=!1;linked=!0;#n=null;#t=null;async_deriveds=new Map;current=new Map;previous=new Map;unblocked=new Set;#l=new Set;#i=new Set;#o=new Set;#s=0;#r=new Map;#h=null;#a=[];#g=[];#d=new Set;#c=new Set;#f=new Map;#u=new Set;is_fork=!1;#_=!1;#E(){if(this.is_fork)return!0;for(const s of this.#r.keys()){for(var t=s,n=!1;t.parent!==null;){if(this.#f.has(t)){n=!0;break}t=t.parent}if(!n)return!0}return!1}skip_effect(t){this.#f.has(t)||this.#f.set(t,{d:[],m:[]}),this.#u.delete(t)}unskip_effect(t,n=s=>this.schedule(s)){var s=this.#f.get(t);if(s){for(var a of(this.#f.delete(t),s.d))Oe(a,lt),n(a);for(a of s.m)Oe(a,Cn),n(a)}this.#u.add(t)}#v(){if(this.#e=!0,uh++>1e3&&(this.#S(),(function(){if(H){var h=new Map;for(const _ of fe.current.keys())for(const[w,m]of _.updated??[]){var g=h.get(w);g||(g={error:m.error,count:0},h.set(w,g)),g.count+=m.count}for(const _ of h.values())_.error&&console.error(_.error)}try{(function(){if(H){const _=new Error(`effect_update_depth_exceeded
38
+ Maximum update depth exceeded. This typically indicates that an effect reads and writes the same piece of state
39
+ https://svelte.dev/e/effect_update_depth_exceeded`);throw _.name="Svelte error",_}throw new Error("https://svelte.dev/e/effect_update_depth_exceeded")})()}catch(_){H&&cn(_,"stack",{value:""}),sr(_,Cl)}})()),H)for(const h of this.current.keys())Tl.add(h);if(!this.#E()){for(const h of this.#d)this.#c.delete(h),Oe(h,lt),this.schedule(h);for(const h of this.#c)Oe(h,Cn),this.schedule(h)}const t=this.#a;this.#a=[],this.apply();var n=wi=[],s=[],a=La=[];for(const h of t)try{this.#C(h,n,s)}catch(g){throw cd(h),g}if(fe=null,a.length>0){var l=Vn.ensure();for(const h of a)l.schedule(h)}if(wi=null,La=null,this.#E()){this.#p(s),this.#p(n);for(const[h,g]of this.#f)ud(h,g);return void(a.length>0&&fe.#v())}const u=this.#y();if(u)u.#m(this);else{this.#d.clear(),this.#c.clear();for(const h of this.#l)h(this);this.#l.clear(),Fl=this,ch(s),ch(n),Fl=null,this.#h?.resolve();var f=fe;if(this.linked&&this.#s===0&&this.#S(),this.#a.length>0){f===null&&(f=this,this.#w());const h=f;h.#a.push(...this.#a.filter(g=>!h.#a.includes(g)))}f!==null&&f.#v()}}#C(t,n,s){t.f^=He;for(var a=t.first;a!==null;){var l=a.f,u=!!(96&l);if(!(u&&(l&He)!==0||(l&Qr)!==0||this.#f.has(a))&&a.fn!==null){u?a.f^=He:4&l?n.push(a):Fi(a)&&((l&Rs)!==0&&this.#c.add(a),qr(a));var f=a.first;if(f!==null){a=f;continue}}for(;a!==null;){var h=a.next;if(h!==null){a=h;break}a=a.parent}}}#y(){for(var t=this.#n;t!==null;){if(!t.is_fork){for(const[n,[,s]]of this.current)if(t.current.has(n)&&!s)return t}t=t.#n}return null}#m(t){for(const[s,a]of t.current)!this.previous.has(s)&&t.previous.has(s)&&this.previous.set(s,t.previous.get(s)),this.current.set(s,a);for(const[s,a]of t.async_deriveds){const l=this.async_deriveds.get(s);l&&a.promise.then(l.resolve)}const n=s=>{var a=s.reactions;if(a!==null)for(const f of a){var l=f.f;if(2&l)n(f);else{var u=f;4194320&l&&!this.async_deriveds.has(u)&&(this.#c.delete(u),Oe(u,lt),this.schedule(u))}}};for(const s of this.current.keys())n(s);this.oncommit(()=>t.discard()),t.#S(),fe=this,this.#v()}#p(t){for(var n=0;n<t.length;n+=1)od(t[n],this.#d,this.#c)}capture(t,n,s=!1){t.v===Ge||this.previous.has(t)||this.previous.set(t,t.v),(t.f&or)===0&&(this.current.set(t,[n,s]),sn?.set(t,n)),this.is_fork||(t.v=n)}activate(){fe=this}deactivate(){fe=null,sn=null}flush(){try{H&&Tl.clear(),bl=!0,fe=this,this.#v()}finally{if(uh=0,Cl=null,wi=null,La=null,bl=!1,fe=null,sn=null,$r.clear(),H)for(const t of Tl)t.updated=null}}discard(){for(const t of this.#i)t(this);this.#i.clear(),this.#o.clear(),this.#S()}register_created_effect(t){this.#g.push(t)}#b(){this.#S();for(let _=El;_!==null;_=_.#t){var t=_.id<this.id,n=[];for(const[w,[m,E]]of this.current){if(_.current.has(w)){var s=_.current.get(w)[0];if(!t||m===s)continue;_.current.set(w,[m,E])}n.push(w)}if(t)for(const[w,m]of this.async_deriveds){const E=_.async_deriveds.get(w);E&&m.promise.then(E.resolve)}if(_.#e){var a=[..._.current.keys()].filter(w=>!this.current.has(w));if(a.length===0)t&&_.discard();else if(n.length>0){if(H&&bE(_.#a.length===0,"Batch has scheduled roots"),t)for(const w of this.#u)_.unskip_effect(w,m=>{4194320&m.f?_.schedule(m):_.#p([m])});_.activate();var l=new Set,u=new Map;for(var f of n)ld(f,a,l,u);u=new Map;var h=[..._.current.keys()].filter(w=>!this.current.has(w)||this.current.get(w)[0]!==w.v);if(h.length>0)for(const w of this.#g)155648&w.f||!au(w,h,u)||(4194320&w.f?(Oe(w,lt),_.schedule(w)):_.#d.add(w));if(_.#a.length>0){for(var g of(_.apply(),_.#a))_.#C(g,[],[]);_.#a=[]}_.deactivate()}}}}increment(t,n){if(this.#s+=1,t){let s=this.#r.get(n)??0;this.#r.set(n,s+1)}}decrement(t,n){if(this.#s-=1,t){let s=this.#r.get(n)??0;s===1?this.#r.delete(n):this.#r.set(n,s-1)}this.#_||(this.#_=!0,mi(()=>{this.#_=!1,this.linked&&this.flush()}))}transfer_effects(t,n){for(const s of t)this.#d.add(s);for(const s of n)this.#c.add(s);t.clear(),n.clear()}oncommit(t){this.#l.add(t)}ondiscard(t){this.#i.add(t)}on_fork_commit(t){this.#o.add(t)}run_fork_commit_callbacks(){for(const t of this.#o)t(this);this.#o.clear()}settled(){return(this.#h??=qh()).promise}static ensure(){if(fe===null){const t=fe=new Vn;t.#w(),bl||us||mi(()=>{t.#e||t.flush()})}return fe}apply(){sn=null}schedule(t){if(Cl=t,t.b?.is_pending&&16777228&t.f&&(t.f&_r)===0)t.b.defer_effect(t);else{for(var n=t;n.parent!==null;){var s=(n=n.parent).f;if(!(wi===null||n!==te||ge!==null&&2&ge.f))return;if(96&s){if((s&He)===0)return;n.f^=He}}this.#a.push(n)}}#w(){hi===null?El=hi=this:(hi.#t=this,this.#n=hi),hi=this}#S(){var t=this.#n,n=this.#t;t===null?El=n:t.#t=n,n===null?hi=t:n.#n=t,this.linked=!1}}function Z(r){var t=us;us=!0;try{var n;for(r&&(fe===null||fe.is_fork||fe.flush(),n=r());;){if(TE(),fe===null)return n;fe.flush()}}finally{us=t}}let kn=null;function ch(r){var t=r.length;if(t!==0){for(var n=0;n<t;){var s=r[n++];if(!(24576&s.f)&&Fi(s)&&(kn=new Set,qr(s),s.deps===null&&s.first===null&&s.nodes===null&&s.teardown===null&&s.ac===null&&Ad(s),kn?.size>0)){$r.clear();for(const a of kn){if(24576&a.f)continue;const l=[a];let u=a.parent;for(;u!==null;)kn.has(u)&&(kn.delete(u),l.push(u)),u=u.parent;for(let f=l.length-1;f>=0;f--){const h=l[f];24576&h.f||qr(h)}}kn.clear()}}kn=null}}function ld(r,t,n,s){if(!n.has(r)&&(n.add(r),r.reactions!==null))for(const a of r.reactions){const l=a.f;2&l?ld(a,t,n,s):4194320&l&&(l&lt)===0&&au(a,t,s)&&(Oe(a,lt),ou(a))}}function au(r,t,n){const s=n.get(r);if(s!==void 0)return s;if(r.deps!==null)for(const a of r.deps){if(Gr.call(t,a))return!0;if(2&a.f&&au(a,t,n))return n.set(a,!0),!0}return n.set(r,!1),!1}function ou(r){fe.schedule(r)}function ud(r,t){if((r.f&As)===0||(r.f&He)===0){(r.f&lt)!==0?t.d.push(r):(r.f&Cn)!==0&&t.m.push(r),Oe(r,He);for(var n=r.first;n!==null;)ud(n,t),n=n.next}}function cd(r){Oe(r,He);for(var t=r.first;t!==null;)cd(t),t=t.next}class PE{parent;is_pending=!1;transform_error;#e;#n=Ue?Ee:null;#t;#l;#i;#o=null;#s=null;#r=null;#h=null;#a=0;#g=0;#d=!1;#c=new Set;#f=new Set;#u=null;#_=(function(t){let n,s=0,a=Ss(0);return H&&_n(a,"createSubscriber version"),()=>{du()&&(q(a),ys(()=>(s===0&&(n=Fn(()=>t(()=>cs(a)))),s+=1,()=>{mi(()=>{s-=1,s===0&&(n?.(),n=void 0,cs(a))})})))}})(()=>(this.#u=Ss(this.#a),H&&_n(this.#u,"$effect.pending()"),()=>{this.#u=null}));constructor(t,n,s,a){this.#e=t,this.#t=n,this.#l=l=>{var u=te;u.b=this,u.f|=128,s(l)},this.parent=te.b,this.transform_error=a??this.parent?.transform_error??(l=>l),this.#i=Td(()=>{if(Ue){const l=this.#n;nu();const u=l.data==="[!";if(l.data.startsWith("[?")){const f=JSON.parse(l.data.slice(2));this.#v(f)}else u?this.#C():this.#E()}else this.#y()},589824),Ue&&(this.#e=Ee)}#E(){try{this.#o=nr(()=>this.#l(this.#e))}catch(t){this.error(t)}}#v(t){const n=this.#t.failed;n&&(this.#r=nr(()=>{n(this.#e,()=>t,()=>()=>{})}))}#C(){const t=this.#t.pending;t&&(this.is_pending=!0,this.#s=nr(()=>t(this.#e)),mi(()=>{var n=this.#h=document.createDocumentFragment(),s=Fr();n.append(s),this.#o=this.#p(()=>nr(()=>this.#l(s))),this.#g===0&&(this.#e.before(n),this.#h=null,fs(this.#s,()=>{this.#s=null}),this.#m(fe))}))}#y(){try{if(this.is_pending=this.has_pending_snippet(),this.#g=0,this.#a=0,this.#o=nr(()=>{this.#l(this.#e)}),this.#g>0){var t=this.#h=document.createDocumentFragment();xd(this.#o,t);const n=this.#t.pending;this.#s=nr(()=>n(this.#e))}else this.#m(fe)}catch(n){this.error(n)}}#m(t){this.is_pending=!1,t.transfer_effects(this.#c,this.#f)}defer_effect(t){od(t,this.#c,this.#f)}is_rendered(){return!this.is_pending&&(!this.parent||this.parent.is_rendered())}has_pending_snippet(){return!!this.#t.pending}#p(t){var n=te,s=ge,a=be;xt(this.#i),Kt(this.#i),xi(this.#i.ctx);try{return Vn.ensure(),t()}catch(l){return id(l),null}finally{xt(n),Kt(s),xi(a)}}#b(t,n){this.has_pending_snippet()?(this.#g+=t,this.#g===0&&(this.#m(n),this.#s&&fs(this.#s,()=>{this.#s=null}),this.#h&&(this.#e.before(this.#h),this.#h=null))):this.parent&&this.parent.#b(t,n)}update_pending_count(t,n){this.#b(t,n),this.#a+=t,this.#u&&!this.#d&&(this.#d=!0,mi(()=>{this.#d=!1,this.#u&&Va(this.#u,this.#a)}))}get_effect_pending(){return this.#_(),q(this.#u)}error(t){if(!this.#t.onerror&&!this.#t.failed)throw t;fe?.is_fork?(this.#o&&fe.skip_effect(this.#o),this.#s&&fe.skip_effect(this.#s),this.#r&&fe.skip_effect(this.#r),fe.on_fork_commit(()=>{this.#w(t)})):this.#w(t)}#w(t){this.#o&&(mt(this.#o),this.#o=null),this.#s&&(mt(this.#s),this.#s=null),this.#r&&(mt(this.#r),this.#r=null),Ue&&(Sn(this.#n),(function(h=1){if(Ue){for(var g=h,_=Ee;g--;)_=Wn(_);Ee=_}})(),Sn(Xh()));var n=this.#t.onerror;let s=this.#t.failed;var a=!1,l=!1;const u=()=>{a?H?console.warn("%c[svelte] svelte_boundary_reset_noop\n%cA `<svelte:boundary>` `reset` function only resets the boundary the first time it is called\nhttps://svelte.dev/e/svelte_boundary_reset_noop",ur,cr):console.warn("https://svelte.dev/e/svelte_boundary_reset_noop"):(a=!0,l&&(function(){if(H){const h=new Error("svelte_boundary_reset_onerror\nA `<svelte:boundary>` `reset` function cannot be called while an error is still being handled\nhttps://svelte.dev/e/svelte_boundary_reset_onerror");throw h.name="Svelte error",h}throw new Error("https://svelte.dev/e/svelte_boundary_reset_onerror")})(),this.#r!==null&&fs(this.#r,()=>{this.#r=null}),this.#p(()=>{this.#y()}))},f=h=>{try{l=!0,n?.(h,u),l=!1}catch(g){sr(g,this.#i&&this.#i.parent)}s&&(this.#r=this.#p(()=>{try{return nr(()=>{var g=te;g.b=this,g.f|=128,s(this.#e,()=>h,()=>u)})}catch(g){return sr(g,this.#i.parent),null}}))};mi(()=>{var h;try{h=this.transform_error(t)}catch(g){return void sr(g,this.#i&&this.#i.parent)}h!==null&&typeof h=="object"&&typeof h.then=="function"?h.then(f,g=>sr(g,this.#i&&this.#i.parent)):f(h)})}}function IE(r,t,n,s){const a=Is()?lu:hd;var l=r.filter(m=>!m.settled);if(n.length!==0||l.length!==0){var u=te,f=(function(){var m=te,E=ge,b=be,R=fe;if(H)var I=ws;return function(N=!0){xt(m),Kt(E),xi(b),N&&(m.f&Ii)===0&&(R?.activate(),R?.apply()),H&&(fd(null),Ha(I))}})(),h=l.length===1?l[0].promise:l.length>1?Promise.all(l.map(m=>m.promise)):null,g=fh();n.length!==0?h?h.then(()=>{f(),w(),Ca()}):w():h.then(()=>_(t.map(a))).finally(g)}else s(t.map(a));function _(m){if((u.f&Ii)===0){f();try{s(m)}catch(E){sr(E,u)}Ca()}}function w(){Promise.all(n.map(m=>(function(E,b,R){let I=te;I===null&&(function(){if(H){const _e=new Error("async_derived_orphan\nCannot create a `$derived(...)` with an `await` expression outside of an effect tree\nhttps://svelte.dev/e/async_derived_orphan");throw _e.name="Svelte error",_e}throw new Error("https://svelte.dev/e/async_derived_orphan")})();var N=void 0,$=Ss(Ge);H&&($.label=E.toString());var J=!ge,de=new Set;return(function(_e){hn(4718592,_e)})(()=>{var _e=te;H&&(Wt={effect:_e,effect_deps:new Set,warned:!1});var pe=qh();N=pe.promise;try{Promise.resolve(E()).then(pe.resolve,ae=>{ae!==Ka&&pe.reject(ae)}).finally(Ca)}catch(ae){pe.reject(ae),Ca()}if(H){if(Wt){if(_e.deps!==null)for(let ae=0;ae<pt;ae+=1)Wt.effect_deps.add(_e.deps[ae]);if(Ye!==null)for(let ae=0;ae<Ye.length;ae+=1)Wt.effect_deps.add(Ye[ae])}Wt=null}var oe=fe;if(J){if((_e.f&_r)!==0)var me=fh();if(I.b.is_rendered())oe.async_deriveds.get(_e)?.reject(ba);else for(const ae of de.values())ae.reject(ba);de.add(pe),oe.async_deriveds.set(_e,pe)}const Re=(ae,ut=void 0)=>{H&&(Wt=null),me?.(),de.delete(pe),ut!==ba&&(oe.activate(),ut?($.f|=or,Va($,ut)):(($.f&or)!==0&&($.f^=or),Va($,ae)),oe.deactivate())};pe.promise.then(Re,ae=>Re(null,ae||"unknown"))}),Ed(()=>{for(const _e of de)_e.reject(ba)}),H&&($.f|=mE),new Promise(_e=>{function pe(oe){function me(){oe===N?_e($):pe(N)}oe.then(me,me)}pe(N)})})(m))).then(m=>_([...t.map(a),...m])).catch(m=>sr(m,u)).finally(g)}}function Ca(r=!0){xt(null),Kt(null),xi(null),r&&fe?.deactivate(),H&&(fd(null),Ha(null))}function fh(){var r=te,t=r.b,n=fe,s=t.is_rendered();return t.update_pending_count(1,n),n.increment(s,r),()=>{t.update_pending_count(-1,n),n.decrement(s,r)}}let Wt=null;function fd(r){Wt=r}const xE=new Set;function lu(r){return te!==null&&(te.f|=zh),{ctx:be,deps:null,effects:null,equals:Zh,f:2050,fn:r,reactions:null,rv:0,v:Ge,wv:0,parent:te,ac:null}}const ba=Symbol("obsolete");function hd(r){const t=lu(r);return t.equals=ed,t}function hh(r){var t=r.effects;if(t!==null){r.effects=null;for(var n=0;n<t.length;n+=1)mt(t[n])}}let Rl=[];function uu(r){var t,n=te,s=r.parent;if(!Bn&&s!==null&&24576&s.f)return H?console.warn(`%c[svelte] derived_inert
40
+ %cReading a derived belonging to a now-destroyed effect may result in stale values
41
+ https://svelte.dev/e/derived_inert`,ur,cr):console.warn("https://svelte.dev/e/derived_inert"),r.v;if(xt(s),H){let a=Li;dh(new Set);try{Gr.call(Rl,r)&&(function(){if(H){const l=new Error(`derived_references_self
42
+ A derived value cannot reference itself recursively
43
+ https://svelte.dev/e/derived_references_self`);throw l.name="Svelte error",l}throw new Error("https://svelte.dev/e/derived_references_self")})(),Rl.push(r),r.f&=-65537,hh(r),t=Wl(r)}finally{xt(n),dh(a),Rl.pop()}}else try{r.f&=-65537,hh(r),t=Wl(r)}finally{xt(n)}return t}function dd(r){var t=uu(r);r.equals(t)||(r.wv=Nd(),fe?.is_fork&&r.deps!==null||(fe!==null?(fe.capture(r,t,!0),Fl?.capture(r,t,!0)):r.v=t,r.deps!==null))?Bn||(sn!==null?(du()||fe?.is_fork)&&sn.set(r,t):su(r)):Oe(r,He)}function gd(r){if(r.effects!==null)for(const t of r.effects)t.teardown&&qr(t)}let Li=new Set;const $r=new Map;function dh(r){Li=r}let cu=!1;function Ss(r,t){var n={f:0,v:r,reactions:null,equals:Zh,rv:0,wv:0};return n}function er(r,t){const n=Ss(r);var s;return s=n,ge!==null&&(Qt===null?Qt=[s]:Qt.push(s)),n}function Si(r,t=!1,n=!0){const s=Ss(r);return t||(s.equals=ed),$i&&n&&be!==null&&be.l!==null&&(be.l.s??=[]).push(s),s}function os(r,t){return _t(r,Fn(()=>q(r))),t}function _t(r,t,n=!1){ge===null||Bt&&(ge.f&tu)===0||!Is()||!(4325394&ge.f)||Qt!==null&&Gr.call(Qt,r)||(function(){if(H){const a=new Error("state_unsafe_mutation\nUpdating state inside `$derived(...)`, `$inspect(...)` or a template expression is forbidden. If the value should not be reactive, declare it without `$state`\nhttps://svelte.dev/e/state_unsafe_mutation");throw a.name="Svelte error",a}throw new Error("https://svelte.dev/e/state_unsafe_mutation")})();let s=n?yi(t):t;return H&&td(s,r.label),Va(r,s,La)}function Va(r,t,n=null){if(!r.equals(t)){$r.set(r,Bn?t:r.v);var s=Vn.ensure();if(s.capture(r,t),H){if(te!==null){r.updated??=new Map;const a=(r.updated.get("")?.count??0)+1;if(r.updated.set("",{error:null,count:a}),a>5){const l=nd("updated at");if(l!==null){let u=r.updated.get(l.stack);u||(u={error:l,count:0},r.updated.set(l.stack,u)),u.count++}}}te!==null&&(r.set_during_effect=!0)}if(2&r.f){const a=r;(r.f&lt)!==0&&uu(a),sn===null&&su(a)}r.wv=Nd(),vd(r,lt,n),!Is()||te===null||(te.f&He)===0||96&te.f||(Ht===null?(function(a){Ht=a})([r]):Ht.push(r)),!s.is_fork&&Li.size>0&&!cu&&pd()}return t}function pd(){cu=!1;for(const r of Li){let t;(r.f&He)!==0&&Oe(r,Cn);try{t=Fi(r)}catch{t=!0}t&&qr(r)}Li.clear()}function cs(r){_t(r,r.v+1)}function vd(r,t,n){var s=r.reactions;if(s!==null)for(var a=Is(),l=s.length,u=0;u<l;u++){var f=s[u],h=f.f;if(a||f!==te){var g=(h&lt)===0;if(g&&Oe(f,t),(h&tu)!==0)Li.add(f);else if(2&h){var _=f;sn?.delete(_),(h&Fa)===0&&(h&Gt&&(te===null||(te.f&ms)===0)&&(f.f|=Fa),vd(_,Cn,n))}else if(g){var w=f;(h&Rs)!==0&&kn!==null&&kn.add(w),n!==null?n.push(w):ou(w)}}}}const LE=/^[a-zA-Z_$][a-zA-Z_$0-9]*$/;function yi(r){if(typeof r!="object"||r===null||wn in r)return r;const t=Zl(r);if(t!==gE&&t!==pE)return r;var n=new Map,s=fE(r),a=er(0),l=Hr,u=_=>{if(Hr===l)return _();var w=ge,m=Hr;Kt(null),mh(l);var E=_();return Kt(w),mh(m),E};s&&(n.set("length",er(r.length)),H&&(r=new Proxy(r,{get(_,w,m){var E=Reflect.get(_,w,m);return NE.has(w)?function(...b){cu=!0;var R=E.apply(this,b);return pd(),R}:E}})));var f="";let h=!1;function g(_){if(!h){h=!0,_n(a,`${f=_} version`);for(const[w,m]of n)_n(m,Lr(f,w));h=!1}}return new Proxy(r,{defineProperty(_,w,m){"value"in m&&m.configurable!==!1&&m.enumerable!==!1&&m.writable!==!1||(function(){if(H){const b=new Error("state_descriptors_fixed\nProperty descriptors defined on `$state` objects must contain `value` and always be `enumerable`, `configurable` and `writable`.\nhttps://svelte.dev/e/state_descriptors_fixed");throw b.name="Svelte error",b}throw new Error("https://svelte.dev/e/state_descriptors_fixed")})();var E=n.get(w);return E===void 0?u(()=>{var b=er(m.value);return n.set(w,b),H&&typeof w=="string"&&_n(b,Lr(f,w)),b}):_t(E,m.value,!0),!0},deleteProperty(_,w){var m=n.get(w);if(m===void 0){if(w in _){const E=u(()=>er(Ge));n.set(w,E),cs(a),H&&_n(E,Lr(f,w))}}else _t(m,Ge),cs(a);return!0},get(_,w,m){if(w===wn)return r;if(H&&w===jh)return g;var E=n.get(w),b=w in _;if(E!==void 0||b&&!Hn(_,w)?.writable||(E=u(()=>{var I=er(yi(b?_[w]:Ge));return H&&_n(I,Lr(f,w)),I}),n.set(w,E)),E!==void 0){var R=q(E);return R===Ge?void 0:R}return Reflect.get(_,w,m)},getOwnPropertyDescriptor(_,w){var m=Reflect.getOwnPropertyDescriptor(_,w);if(m&&"value"in m){var E=n.get(w);E&&(m.value=q(E))}else if(m===void 0){var b=n.get(w),R=b?.v;if(b!==void 0&&R!==Ge)return{enumerable:!0,configurable:!0,value:R,writable:!0}}return m},has(_,w){if(w===wn)return!0;var m=n.get(w),E=m!==void 0&&m.v!==Ge||Reflect.has(_,w);return(m!==void 0||te!==null&&(!E||Hn(_,w)?.writable))&&(m===void 0&&(m=u(()=>{var b=er(E?yi(_[w]):Ge);return H&&_n(b,Lr(f,w)),b}),n.set(w,m)),q(m)===Ge)?!1:E},set(_,w,m,E){var b=n.get(w),R=w in _;if(s&&w==="length")for(var I=m;I<b.v;I+=1){var N=n.get(I+"");N!==void 0?_t(N,Ge):I in _&&(N=u(()=>er(Ge)),n.set(I+"",N),H&&_n(N,Lr(f,I)))}b===void 0?R&&!Hn(_,w)?.writable||(b=u(()=>er(void 0)),H&&_n(b,Lr(f,w)),_t(b,yi(m)),n.set(w,b)):(R=b.v!==Ge,_t(b,u(()=>yi(m))));var $=Reflect.getOwnPropertyDescriptor(_,w);if($?.set&&$.set.call(E,m),!R){if(s&&typeof w=="string"){var J=n.get("length"),de=Number(w);Number.isInteger(de)&&de>=J.v&&_t(J,de+1)}cs(a)}return!0},ownKeys(_){q(a);var w=Reflect.ownKeys(_).filter(b=>{var R=n.get(b);return R===void 0||R.v!==Ge});for(var[m,E]of n)E.v===Ge||m in _||w.push(m);return w},setPrototypeOf(){(function(){if(H){const _=new Error("state_prototype_fixed\nCannot set prototype of `$state` object\nhttps://svelte.dev/e/state_prototype_fixed");throw _.name="Svelte error",_}throw new Error("https://svelte.dev/e/state_prototype_fixed")})()}})}function Lr(r,t){return typeof t=="symbol"?`${r}[Symbol(${t.description??""})]`:LE.test(t)?`${r}.${t}`:/^\d+$/.test(t)?`${r}[${t}]`:`${r}['${t}']`}function Al(r){try{if(r!==null&&typeof r=="object"&&wn in r)return r[wn]}catch{}return r}const NE=new Set(["copyWithin","fill","pop","push","reverse","shift","sort","splice","unshift"]);var gh,fu,_d,md;function Hl(){if(gh===void 0){gh=window,fu=/Firefox/.test(navigator.userAgent);var r=Element.prototype,t=Node.prototype,n=Text.prototype;_d=Hn(t,"firstChild").get,md=Hn(t,"nextSibling").get,oh(r)&&(r[kl]=void 0,r[Yh]=null,r[SE]=void 0,r.__e=void 0),oh(n)&&(n[yE]=void 0),H&&(r.__svelte_meta=null,(function(){const s=Array.prototype,a=Array.__svelte_cleanup;a&&a();const{indexOf:l,lastIndexOf:u,includes:f}=s;s.indexOf=function(h,g){const _=l.call(this,h,g);if(_===-1){for(let w=g??0;w<this.length;w+=1)if(Al(this[w])===h){yl("array.indexOf(...)");break}}return _},s.lastIndexOf=function(h,g){const _=u.call(this,h,g??this.length-1);if(_===-1){for(let w=0;w<=(g??this.length-1);w+=1)if(Al(this[w])===h){yl("array.lastIndexOf(...)");break}}return _},s.includes=function(h,g){const _=f.call(this,h,g);if(!_){for(let w=0;w<this.length;w+=1)if(Al(this[w])===h){yl("array.includes(...)");break}}return _},Array.__svelte_cleanup=()=>{s.indexOf=l,s.lastIndexOf=u,s.includes=f}})())}}function Fr(r=""){return document.createTextNode(r)}function Ni(r){return _d.call(r)}function Wn(r){return md.call(r)}function ph(r,t=!1){if(!Ue){var n=Ni(r);return n instanceof Comment&&n.data===""?Wn(n):n}if(t){if(Ee?.nodeType!==3){var s=Fr();return Ee?.before(s),Sn(s),s}wd(Ee)}return Ee}function hu(r,t,n){return document.createElementNS(Gh,r,void 0)}function wd(r){if(r.nodeValue.length<65536)return;let t=r.nextSibling;for(;t!==null&&t.nodeType===3;)t.remove(),r.nodeValue+=t.nodeValue,t=r.nextSibling}function Sd(r){var t=ge,n=te;Kt(null),xt(null);try{return r()}finally{Kt(t),xt(n)}}function yd(r){te===null&&(ge===null&&(function(t){if(H){const n=new Error(`effect_orphan
44
+ \`${t}\` can only be used inside an effect (e.g. during component initialisation)
45
+ https://svelte.dev/e/effect_orphan`);throw n.name="Svelte error",n}throw new Error("https://svelte.dev/e/effect_orphan")})(r),(function(){if(H){const t=new Error("effect_in_unowned_derived\nEffect cannot be created inside a `$derived` value that was not itself created inside an effect\nhttps://svelte.dev/e/effect_in_unowned_derived");throw t.name="Svelte error",t}throw new Error("https://svelte.dev/e/effect_in_unowned_derived")})()),Bn&&(function(t){if(H){const n=new Error(`effect_in_teardown
46
+ \`${t}\` cannot be used inside an effect cleanup function
47
+ https://svelte.dev/e/effect_in_teardown`);throw n.name="Svelte error",n}throw new Error("https://svelte.dev/e/effect_in_teardown")})(r)}function hn(r,t){var n=te;if(H)for(;n!==null&&(n.f&tu)!==0;)n=n.parent;n!==null&&(n.f&Qr)!==0&&(r|=Qr);var s={ctx:be,deps:null,nodes:null,f:r|lt|Gt,first:null,fn:t,last:null,next:null,parent:n,b:n&&n.b,prev:null,teardown:null,wv:0,ac:null};H&&(s.component_function=Ps),fe?.register_created_effect(s);var a=s;if(4&r)wi!==null?wi.push(s):Vn.ensure().schedule(s);else if(t!==null){try{qr(s)}catch(u){throw mt(s),u}a.deps===null&&a.teardown===null&&a.nodes===null&&a.first===a.last&&(a.f&zh)===0&&(a=a.first,(r&Rs)!==0&&(r&_s)!==0&&a!==null&&(a.f|=_s))}if(a!==null&&(a.parent=n,n!==null&&(function(u,f){var h=f.last;h===null?f.last=f.first=u:(h.next=u,u.prev=h,f.last=u)})(a,n),ge!==null&&2&ge.f&&(r&eu)===0)){var l=ge;(l.effects??=[]).push(a)}return s}function du(){return ge!==null&&!Bt}function Ed(r){const t=hn(8,null);return Oe(t,He),t.teardown=r,t}function Vl(r){yd("$effect"),H&&cn(r,"name",{value:"$effect"});var t=te.f;if(!(!ge&&(t&As)!==0&&(t&_r)===0))return Cd(r);var n=be;(n.e??=[]).push(r)}function Cd(r){return hn(1048580,r)}function bd(r){return hn(4,r)}function ys(r,t=0){return hn(8|t,r)}function vh(r,t=[],n=[],s=[]){IE(s,t,n,a=>{hn(8,()=>r(...a.map(q)))})}function Td(r,t=0){var n=hn(Rs|t,r);return H&&(n.dev_stack=ws),n}function nr(r){return hn(524320,r)}function Rd(r){var t=r.teardown;if(t!==null){const n=Bn,s=ge;_h(!0),Kt(null);try{t.call(null)}finally{_h(n),Kt(s)}}}function gu(r,t=!1){var n=r.first;for(r.first=r.last=null;n!==null;){const a=n.ac;a!==null&&Sd(()=>{a.abort(Ka)});var s=n.next;(n.f&eu)!==0?n.parent=null:mt(n,t),n=s}}function mt(r,t=!0){var n=!1;(t||262144&r.f)&&r.nodes!==null&&r.nodes.end!==null&&((function(l,u){for(;l!==null;){var f=l===u?null:Wn(l);l.remove(),l=f}})(r.nodes.start,r.nodes.end),n=!0),Oe(r,Ml),gu(r,t&&!n),Es(r,0);var s=r.nodes&&r.nodes.t;if(s!==null)for(const l of s)l.stop();Rd(r),r.f^=Ml,r.f|=Ii;var a=r.parent;a!==null&&a.first!==null&&Ad(r),H&&(r.component_function=null),r.next=r.prev=r.teardown=r.ctx=r.deps=r.fn=r.nodes=r.ac=r.b=null}function Ad(r){var t=r.parent,n=r.prev,s=r.next;n!==null&&(n.next=s),s!==null&&(s.prev=n),t!==null&&(t.first===r&&(t.first=s),t.last===r&&(t.last=n))}function fs(r,t,n=!0){var s=[];Pd(r,s,!0);var a=()=>{n&&mt(r),t&&t()},l=s.length;if(l>0){var u=()=>--l||a();for(var f of s)f.out(u)}else a()}function Pd(r,t,n){if((r.f&Qr)===0){r.f^=Qr;var s=r.nodes&&r.nodes.t;if(s!==null)for(const u of s)(u.is_global||n)&&t.push(u);for(var a=r.first;a!==null;){var l=a.next;(a.f&eu)===0&&Pd(a,t,((a.f&_s)!==0||(a.f&As)!==0&&(r.f&Rs)!==0)&&n),a=l}}}function OE(r){Id(r,!0)}function Id(r,t){if((r.f&Qr)!==0){r.f^=Qr,(r.f&He)===0&&(Oe(r,lt),Vn.ensure().schedule(r));for(var n=r.first;n!==null;){var s=n.next;Id(n,((n.f&_s)!==0||(n.f&As)!==0)&&t),n=s}var a=r.nodes&&r.nodes.t;if(a!==null)for(const l of a)(l.is_global||t)&&l.in()}}function xd(r,t){if(r.nodes)for(var n=r.nodes.start,s=r.nodes.end;n!==null;){var a=n===s?null:Wn(n);t.append(n),n=a}}let Na=!1,Bn=!1;function _h(r){Bn=r}let ge=null,Bt=!1;function Kt(r){ge=r}let te=null;function xt(r){te=r}let Qt=null,Ye=null,pt=0,Ht=null,Ld=1,Dr=0,Hr=Dr;function mh(r){Hr=r}function Nd(){return++Ld}function Fi(r){var t=r.f;if((t&lt)!==0)return!0;if(2&t&&(r.f&=-65537),(t&Cn)!==0){for(var n=r.deps,s=n.length,a=0;a<s;a++){var l=n[a];if(Fi(l)&&dd(l),l.wv>r.wv)return!0}(t&Gt)!==0&&sn===null&&Oe(r,He)}return!1}function Od(r,t,n=!0){var s=r.reactions;if(s!==null&&(Qt===null||!Gr.call(Qt,r)))for(var a=0;a<s.length;a++){var l=s[a];2&l.f?Od(l,t,!1):t===l&&(n?Oe(l,lt):(l.f&He)!==0&&Oe(l,Cn),ou(l))}}function Wl(r){var t=Ye,n=pt,s=Ht,a=ge,l=Qt,u=be,f=Bt,h=Hr,g=r.f;Ye=null,pt=0,Ht=null,ge=96&g?null:r,Qt=null,xi(r.ctx),Bt=!1,Hr=++Dr,r.ac!==null&&(Sd(()=>{r.ac.abort(Ka)}),r.ac=null);try{r.f|=ms;var _=(0,r.fn)();r.f|=_r;var w=r.deps,m=fe?.is_fork;if(Ye!==null){var E;if(m||Es(r,pt),w!==null&&pt>0)for(w.length=pt+Ye.length,E=0;E<Ye.length;E++)w[pt+E]=Ye[E];else r.deps=w=Ye;if(du()&&(r.f&Gt)!==0)for(E=pt;E<w.length;E++)(w[E].reactions??=[]).push(r)}else!m&&w!==null&&pt<w.length&&(Es(r,pt),w.length=pt);if(Is()&&Ht!==null&&!Bt&&w!==null&&!(6146&r.f))for(E=0;E<Ht.length;E++)Od(Ht[E],r);if(a!==null&&a!==r){if(Dr++,a.deps!==null)for(let b=0;b<n;b+=1)a.deps[b].rv=Dr;if(t!==null)for(const b of t)b.rv=Dr;Ht!==null&&(s===null?s=Ht:s.push(...Ht))}return(r.f&or)!==0&&(r.f^=or),_}catch(b){return id(b)}finally{r.f^=ms,Ye=t,pt=n,Ht=s,ge=a,Qt=l,xi(u),Bt=f,Hr=h}}function UE(r,t){let n=t.reactions;if(n!==null){var s=hE.call(n,r);if(s!==-1){var a=n.length-1;a===0?n=t.reactions=null:(n[s]=n[a],n.pop())}}if(n===null&&2&t.f&&(Ye===null||!Gr.call(Ye,t))){var l=t;(l.f&Gt)!==0&&(l.f^=Gt,l.f&=-65537),l.v!==Ge&&su(l),(function(u){if(u.effects!==null)for(const f of u.effects)(f.teardown||f.ac)&&(f.teardown?.(),f.ac?.abort(Ka),f.teardown=vE,f.ac=null,Es(f,0),gu(f))})(l),Es(l,0)}}function Es(r,t){var n=r.deps;if(n!==null)for(var s=t;s<n.length;s++)UE(r,n[s])}function qr(r){var t=r.f;if((t&Ii)===0){Oe(r,He);var n=te,s=Na;if(te=r,Na=!0,H){var a=Ps;lh(r.component_function);var l=ws;Ha(r.dev_stack??ws)}try{16777232&t?(function(f){for(var h=f.first;h!==null;){var g=h.next;(h.f&As)===0&&mt(h),h=g}})(r):gu(r),Rd(r);var u=Wl(r);r.teardown=typeof u=="function"?u:null,r.wv=Ld}finally{Na=s,te=n,H&&(lh(a),Ha(l))}}}function q(r){var t,n=!!(2&r.f);if(ge!==null&&!Bt&&!(te!==null&&(te.f&Ii)!==0||Qt!==null&&Gr.call(Qt,r))){var s=ge.deps;if((ge.f&ms)!==0)r.rv<Dr&&(r.rv=Dr,Ye===null&&s!==null&&s[pt]===r?pt++:Ye===null?Ye=[r]:Ye.push(r));else{(ge.deps??=[]).push(r);var a=r.reactions;a===null?r.reactions=[ge]:Gr.call(a,ge)||a.push(ge)}}if(H){if(!Bt&&Wt&&!Wt.warned&&(Wt.effect.f&ms)===0&&!Wt.effect_deps.has(r)){Wt.warned=!0,t=r.label,H?console.warn(`%c[svelte] await_reactivity_loss
48
+ %cDetected reactivity loss when reading \`${t}\`. This happens when state is read in an async function after an earlier \`await\`
49
+ https://svelte.dev/e/await_reactivity_loss`,ur,cr):console.warn("https://svelte.dev/e/await_reactivity_loss");var l=nd("traced at");l&&console.warn(l)}xE.delete(r)}if(Bn&&$r.has(r))return $r.get(r);if(n){var u=r;if(Bn){var f=u.v;return((u.f&He)===0&&u.reactions!==null||Dd(u))&&(f=uu(u)),$r.set(u,f),f}var h=(u.f&Gt)===0&&!Bt&&ge!==null&&(Na||(ge.f&Gt)!==0),g=(u.f&_r)===0;Fi(u)&&(h&&(u.f|=Gt),dd(u)),h&&!g&&(gd(u),Ud(u))}if(sn?.has(r))return sn.get(r);if((r.f&or)!==0)throw r.v;return r.v}function Ud(r){if(r.f|=Gt,r.deps!==null)for(const t of r.deps)(t.reactions??=[]).push(r),2&t.f&&(t.f&Gt)===0&&(gd(t),Ud(t))}function Dd(r){if(r.v===Ge)return!0;if(r.deps===null)return!1;for(const t of r.deps)if($r.has(t)||2&t.f&&Dd(t))return!0;return!1}function Fn(r){var t=Bt;try{return Bt=!0,r()}finally{Bt=t}}function gi(r){if(typeof r=="object"&&r&&!(r instanceof EventTarget)){if(wn in r)Bl(r);else if(!Array.isArray(r))for(let t in r){const n=r[t];typeof n=="object"&&n&&wn in n&&Bl(n)}}}function Bl(r,t=new Set){if(!(typeof r!="object"||r===null||r instanceof EventTarget||t.has(r))){t.add(r),r instanceof Date&&r.getTime();for(let s in r)try{Bl(r[s],t)}catch{}const n=Zl(r);if(n!==Object.prototype&&n!==Array.prototype&&n!==Map.prototype&&n!==Set.prototype&&n!==Date.prototype){const s=Qh(n);for(let a in s){const l=s[a].get;if(l)try{l.call(r)}catch{}}}}}const Ta=Symbol("events"),DE=new Set,wh=new Set;let Sh=null;function yh(r){var t=this,n=t.ownerDocument,s=r.type,a=r.composedPath?.()||[],l=a[0]||r.target;Sh=r;var u=0,f=Sh===r&&r[Ta];if(f){var h=a.indexOf(f);if(h!==-1&&(t===document||t===window))return void(r[Ta]=t);var g=a.indexOf(t);if(g===-1)return;h<=g&&(u=h)}if((l=a[u]||r.target)!==t){cn(r,"currentTarget",{configurable:!0,get:()=>l||n});var _=ge,w=te;Kt(null),xt(null);try{for(var m,E=[];l!==null;){var b=l.assignedSlot||l.parentNode||l.host||null;try{var R=l[Ta]?.[s];R==null||l.disabled&&r.target!==l||R.call(l,r)}catch(I){m?E.push(I):m=I}if(r.cancelBubble||b===t||b===null)break;l=b}if(m){for(let I of E)queueMicrotask(()=>{throw I});throw m}}finally{r[Ta]=t,delete r.currentTarget,Kt(_),xt(w)}}}const ME=globalThis?.window?.trustedTypes&&globalThis.window.trustedTypes.createPolicy("svelte-trusted-html",{createHTML:r=>r});function kE(r){var t=hu("template");return t.innerHTML=(function(n){return ME?.createHTML(n)??n})(r.replaceAll("<!>","<!---->")),t.content}function Ri(r,t){var n=te;n.nodes===null&&(n.nodes={start:r,end:t,a:null,t:null})}function pu(r,t){var n,s=!!(1&t),a=!!(2&t),l=!r.startsWith("<!>");return()=>{if(Ue)return Ri(Ee,null),Ee;n===void 0&&(n=kE(l?r:"<!>"+r),s||(n=Ni(n)));var u=a||fu?document.importNode(n,!0):n.cloneNode(!0);return s?Ri(Ni(u),u.lastChild):Ri(u,u),u}}function hs(r,t){if(Ue){var n=te;return(n.f&_r)!==0&&n.nodes.end!==null||(n.nodes.end=Ee),void nu()}r!==null&&r.before(t)}const $E=["touchstart","touchmove"];function FE(r){return $E.includes(r)}function Md(r,t){return kd(r,t)}function HE(r,t){Hl(),t.intro=t.intro??!1;const n=t.target,s=Ue,a=Ee;try{for(var l=Ni(n);l&&(l.nodeType!==8||l.data!=="[");)l=Wn(l);if(!l)throw Pi;_i(!0),Sn(l);const u=kd(r,{...t,anchor:l});return _i(!1),u}catch(u){if(u instanceof Error&&u.message.split(`
50
+ `).some(f=>f.startsWith("https://svelte.dev/e/")))throw u;return u!==Pi&&console.warn("Failed to hydrate: ",u),t.recover===!1&&(function(){if(H){const f=new Error(`hydration_failed
51
+ Failed to hydrate the application
52
+ https://svelte.dev/e/hydration_failed`);throw f.name="Svelte error",f}throw new Error("https://svelte.dev/e/hydration_failed")})(),Hl(),n.textContent="",_i(!1),Md(r,t)}finally{_i(s),Sn(a)}}const Ra=new Map;function kd(r,{target:t,anchor:n,props:s={},events:a,context:l,intro:u=!0,transformError:f}){Hl();var h=void 0,g=(function(_){Vn.ensure();const w=hn(524352,_);return(m={})=>new Promise(E=>{m.outro?fs(w,()=>{mt(w),E(void 0)}):(mt(w),E(void 0))})})(()=>{var _=n??t.appendChild(Fr());(function(E,b,R,I){new PE(E,b,R,I)})(_,{pending:()=>{}},E=>{if(ru({}),l&&(be.c=l),a&&(s.$$events=a),Ue&&Ri(E,null),h=r(E,s)||{},Ue&&(te.nodes.end=Ee,Ee===null||Ee.nodeType!==8||Ee.data!=="]"))throw ja(),Pi;iu()},f);var w=new Set,m=E=>{for(var b=0;b<E.length;b++){var R=E[b];if(!w.has(R)){w.add(R);var I=FE(R);for(const J of[t,document]){var N=Ra.get(J);N===void 0&&(N=new Map,Ra.set(J,N));var $=N.get(R);$===void 0?(J.addEventListener(R,yh,{passive:I}),N.set(R,1)):N.set(R,$+1)}}}};return m(dE(DE)),wh.add(m),()=>{for(var E of w)for(const I of[t,document]){var b=Ra.get(I),R=b.get(E);--R==0?(I.removeEventListener(E,yh),b.delete(E),b.size===0&&Ra.delete(I)):b.set(E,R)}wh.delete(m),_!==n&&_.parentNode?.removeChild(_)}});return Gl.set(h,g),h}let Gl=new WeakMap;function VE(r,t){const n=Gl.get(r);return n?(Gl.delete(r),n(t)):(H&&(wn in r?H?console.warn(`%c[svelte] state_proxy_unmount
53
+ %cTried to unmount a state proxy, rather than a component
54
+ https://svelte.dev/e/state_proxy_unmount`,ur,cr):console.warn("https://svelte.dev/e/state_proxy_unmount"):H?console.warn(`%c[svelte] lifecycle_double_unmount
55
+ %cTried to unmount a component that was not mounted
56
+ https://svelte.dev/e/lifecycle_double_unmount`,ur,cr):console.warn("https://svelte.dev/e/lifecycle_double_unmount")),Promise.resolve())}class WE{anchor;#e=new Map;#n=new Map;#t=new Map;#l=new Set;#i=!0;constructor(t,n=!0){this.anchor=t,this.#i=n}#o=t=>{if(this.#e.has(t)){var n=this.#e.get(t),s=this.#n.get(n);if(s)OE(s),this.#l.delete(n);else{var a=this.#t.get(n);a&&(this.#n.set(n,a.effect),this.#t.delete(n),H&&(a.fragment.lastChild[EE]=this.anchor),a.fragment.lastChild.remove(),this.anchor.before(a.fragment),s=a.effect)}for(const[l,u]of this.#e){if(this.#e.delete(l),l===t)break;const f=this.#t.get(u);f&&(mt(f.effect),this.#t.delete(u))}for(const[l,u]of this.#n){if(l===n||this.#l.has(l))continue;const f=()=>{if(Array.from(this.#e.values()).includes(l)){var h=document.createDocumentFragment();xd(u,h),h.append(Fr()),this.#t.set(l,{effect:u,fragment:h})}else mt(u);this.#l.delete(l),this.#n.delete(l)};this.#i||!s?(this.#l.add(l),fs(u,f,!1)):f()}}};#s=t=>{this.#e.delete(t);const n=Array.from(this.#e.values());for(const[s,a]of this.#t)n.includes(s)||(mt(a.effect),this.#t.delete(s))};ensure(t,n){var s=fe;!n||this.#n.has(t)||this.#t.has(t)||this.#n.set(t,nr(()=>n(this.anchor))),this.#e.set(s,t),Ue&&(this.anchor=Ee),this.#o(s)}}if(H){let r=function(t){if(!(t in globalThis)){let n;Object.defineProperty(globalThis,t,{configurable:!0,get:()=>{if(n!==void 0)return n;(function(s){if(H){const a=new Error(`rune_outside_svelte
57
+ The \`${s}\` rune is only available inside \`.svelte\` and \`.svelte.js/ts\` files
58
+ https://svelte.dev/e/rune_outside_svelte`);throw a.name="Svelte error",a}throw new Error("https://svelte.dev/e/rune_outside_svelte")})(t)},set:s=>{n=s}})}};r("$state"),r("$effect"),r("$derived"),r("$inspect"),r("$props"),r("$bindable")}function Ql(r){var t,n;be===null&&Jh("onMount"),$i&&be.l!==null?(t=be,n=t.l,n.u??={a:[],b:[],m:[]}).m.push(r):Vl(()=>{const s=Fn(r);if(typeof s=="function")return s})}var Eh=new Map;function Ch(r,t,n=!1){var s;Ue&&(s=Ee,nu());var a=new WE(r);function l(u,f){if(Ue){var h=(function(_){if(!_||_.nodeType!==8)throw ja(),Pi;return _.data})(s);if(u!==parseInt(h.substring(1))){var g=Xh();return Sn(g),a.anchor=g,_i(!1),a.ensure(u,f),void _i(!0)}}a.ensure(u,f)}Td(()=>{var u=!1;t((f,h=0)=>{u=!0,l(h,f)}),u||l(-1,null)},n?_s:0)}function BE(r,t){bd(()=>{var n=r.getRootNode(),s=n.host?n:n.head??n.ownerDocument.head;if(!s.querySelector("#"+t.hash)){const a=hu("style");a.id=t.hash,a.textContent=t.code,s.appendChild(a),H&&(function(l,u){var f=Eh.get(l);f||(f=new Set,Eh.set(l,f)),f.add(u)})(t.hash,a)}})}function $d(r){var t,n,s="";if(typeof r=="string"||typeof r=="number")s+=r;else if(typeof r=="object")if(Array.isArray(r)){var a=r.length;for(t=0;t<a;t++)r[t]&&(n=$d(r[t]))&&(s&&(s+=" "),s+=n)}else for(n in r)r[n]&&(s&&(s+=" "),s+=n);return s}function GE(r){return typeof r=="object"?(function(){for(var t,n,s=0,a="",l=arguments.length;s<l;s++)(t=arguments[s])&&(n=$d(t))&&(a&&(a+=" "),a+=n);return a})(r):r??""}function QE(r,t,n,s,a,l){var u=r[kl];if(Ue||u!==n||u===void 0){var f=(function(h,g,_){var w=h==null?"":""+h;return w===""?null:w})(n);Ue&&f===r.getAttribute("class")||(f==null?r.removeAttribute("class"):r.className=f),r[kl]=n}return l}const qE=Symbol("is custom element"),zE=Symbol("is html"),KE=CE?"link":"LINK";function Aa(r,t,n,s){var a=(function(l){return l[Yh]??={[qE]:l.nodeName.includes("-"),[zE]:l.namespaceURI===Gh}})(r);Ue&&(a[t]=r.getAttribute(t),t==="src"||t==="srcset"||t==="href"&&r.nodeName===KE)?(function(l,u,f){H&&(u==="srcset"&&(function(h,g){var _=Th(h.srcset),w=Th(g);return w.length===_.length&&w.every(([m,E],b)=>E===_[b][1]&&(Pl(_[b][0],m)||Pl(m,_[b][0])))})(l,f)||Pl(l.getAttribute(u)??"",f)||(function(h,g,_){H?console.warn(`%c[svelte] hydration_attribute_changed
59
+ %cThe \`${h}\` attribute on \`${g}\` changed its value between server and client renders. The client value, \`${_}\`, will be ignored in favour of the server value
60
+ https://svelte.dev/e/hydration_attribute_changed`,ur,cr):console.warn("https://svelte.dev/e/hydration_attribute_changed")})(u,l.outerHTML.replace(l.innerHTML,l.innerHTML&&"..."),String(f)))})(r,t,n??""):a[t]!==(a[t]=n)&&(t==="loading"&&(r[wE]=n),n==null?r.removeAttribute(t):typeof n!="string"&&(function(l){var u,f=l.getAttribute("is")||l.nodeName,h=bh.get(f);if(h)return h;bh.set(f,h=[]);for(var g=l,_=Element.prototype;_!==g;){for(var w in u=Qh(g))u[w].set&&w!=="innerHTML"&&w!=="textContent"&&w!=="innerText"&&h.push(w);g=Zl(g)}return h})(r).includes(t)?r[t]=n:r.setAttribute(t,n))}var bh=new Map;function Pl(r,t){return r===t||new URL(r,document.baseURI).href===new URL(t,document.baseURI).href}function Th(r){return r.split(",").map(t=>t.trim().split(" ").filter(Boolean))}function Fd(r,t,n){var s=Hn(r,t);s&&s.set&&(r[t]=n,Ed(()=>{r[t]=null}))}function Il(r,t){return r===t||r?.[wn]===t}function ql(r={},t,n,s){var a=be.r,l=te;return bd(()=>{var u,f;return ys(()=>{u=f,f=[],Fn(()=>{Il(n(...f),r)||(t(r,...f),u&&Il(n(...u),r)&&t(null,...u))})}),()=>{let h=l;for(;h!==a&&h.parent!==null&&h.parent.f&Ml;)h=h.parent;const g=h.teardown;h.teardown=()=>{f&&Il(n(...f),r)&&t(null,...f),g?.()}}}),r}function Hd(r=!1){const t=be,n=t.l.u;if(!n)return;let s=()=>gi(t.s);if(r){let l=0,u={};const f=lu(()=>{let h=!1;const g=t.s;for(const _ in g)g[_]!==u[_]&&(u[_]=g[_],h=!0);return h&&l++,l});s=()=>q(f)}var a;n.b.length&&(a=()=>{Rh(t,s),Dl(n.b)},yd("$effect.pre"),H&&cn(a,"name",{value:"$effect.pre"}),hn(1048584,a)),Vl(()=>{const l=Fn(()=>n.m.map(_E));return()=>{for(const u of l)typeof u=="function"&&u()}}),n.a.length&&Vl(()=>{Rh(t,s),Dl(n.a)})}function Rh(r,t){if(r.l.s)for(const n of r.l.s)q(n);t()}function ee(r,t,n,s){var a=!$i||!1,l=!0,u=s,f=!0,h=()=>(f&&(f=!1,u=s),u);let g;{var _=wn in r||Kh in r;g=Hn(r,t)?.set??(_&&t in r?$=>r[t]=$:void 0)}var w,m,E=!1;if([w,E]=(function($){var J=Ea;try{return Ea=!1,[$(),Ea]}finally{Ea=J}})(()=>r[t]),m=a?()=>{var $=r[t];return $===void 0?h():(f=!0,$)}:()=>{var $=r[t];return $!==void 0&&(u=void 0),$===void 0?u:$},g){var b=r.$$legacy;return function($,J){return arguments.length>0?(a&&J&&!b&&!E||g(J?m():$),$):m()}}var R=!1,I=hd(()=>(R=!1,m()));H&&(I.label=t),q(I);var N=te;return function($,J){if(arguments.length>0){const de=J?q(I):a&&l?yi($):$;return _t(I,de),R=!0,u!==void 0&&(u=de),$}return Bn&&R||(N.f&Ii)!==0?I.v:q(I)}}class jE{#e;#n;constructor(t){var n=new Map,s=(l,u)=>{var f=Si(u,!1,!1);return n.set(l,f),f};const a=new Proxy({...t.props||{},$$events:{}},{get:(l,u)=>q(n.get(u)??s(u,Reflect.get(l,u))),has:(l,u)=>u===Kh||(q(n.get(u)??s(u,Reflect.get(l,u))),Reflect.has(l,u)),set:(l,u,f)=>(_t(n.get(u)??s(u,f),f),Reflect.set(l,u,f))});this.#n=(t.hydrate?HE:Md)(t.component,{target:t.target,anchor:t.anchor,props:a,context:t.context,intro:t.intro??!1,recover:t.recover,transformError:t.transformError}),t?.props?.$$host&&t.sync!==!1||Z(),this.#e=a.$$events;for(const l of Object.keys(this.#n))l!=="$set"&&l!=="$destroy"&&l!=="$on"&&cn(this,l,{get(){return this.#n[l]},set(u){this.#n[l]=u},enumerable:!0});this.#n.$set=l=>{Object.assign(a,l)},this.#n.$destroy=()=>{VE(this.#n)}}$set(t){this.#n.$set(t)}$on(t,n){this.#e[t]=this.#e[t]||[];const s=(...a)=>n.call(this,...a);return this.#e[t].push(s),()=>{this.#e[t]=this.#e[t].filter(a=>a!==s)}}$destroy(){this.#n.$destroy()}}let Vd;function Oa(r,t,n,s){const a=n[r]?.type;if(t=a==="Boolean"&&typeof t!="boolean"?t!=null:t,!s||!n[r])return t;if(s==="toAttribute")switch(a){case"Object":case"Array":return t==null?null:JSON.stringify(t);case"Boolean":return t?"":null;case"Number":return t??null;default:return t}else switch(a){case"Object":case"Array":return t&&JSON.parse(t);case"Boolean":default:return t;case"Number":return t!=null?+t:t}}function Wd(r,t,n,s,a,l){let u=class extends Vd{constructor(){super(r,n,a),this.$$p_d=t}static get observedAttributes(){return $a(t).map(f=>(t[f].attribute||f).toLowerCase())}};return $a(t).forEach(f=>{cn(u.prototype,f,{get(){return this.$$c&&f in this.$$c?this.$$c[f]:this.$$d[f]},set(h){h=Oa(f,h,t),this.$$d[f]=h;var g=this.$$c;if(g){var _=Hn(g,f)?.get;_?g[f]=h:g.$set({[f]:h})}}})}),s.forEach(f=>{cn(u.prototype,f,{get(){return this.$$c?.[f]}})}),l&&(u=l(u)),r.element=u,u}var ue;typeof HTMLElement=="function"&&(Vd=class extends HTMLElement{$$ctor;$$s;$$c;$$cn=!1;$$d={};$$r=!1;$$p_d={};$$l={};$$l_u=new Map;$$me;$$shadowRoot=null;constructor(r,t,n){super(),this.$$ctor=r,this.$$s=t,n&&(this.$$shadowRoot=this.attachShadow(n))}addEventListener(r,t,n){if(this.$$l[r]=this.$$l[r]||[],this.$$l[r].push(t),this.$$c){const s=this.$$c.$on(r,t);this.$$l_u.set(t,s)}super.addEventListener(r,t,n)}removeEventListener(r,t,n){if(super.removeEventListener(r,t,n),this.$$c){const s=this.$$l_u.get(t);s&&(s(),this.$$l_u.delete(t))}}async connectedCallback(){if(this.$$cn=!0,!this.$$c){let t=function(a){return l=>{const u=hu("slot");a!=="default"&&(u.name=a),hs(l,u)}};if(await Promise.resolve(),!this.$$cn||this.$$c)return;const n={},s=(function(a){const l={};return a.childNodes.forEach(u=>{l[u.slot||"default"]=!0}),l})(this);for(const a of this.$$s)a in s&&(a!=="default"||this.$$d.children?n[a]=t(a):(this.$$d.children=t(a),n.default=!0));for(const a of this.attributes){const l=this.$$g_p(a.name);l in this.$$d||(this.$$d[l]=Oa(l,a.value,this.$$p_d,"toProp"))}for(const a in this.$$p_d)a in this.$$d||this[a]===void 0||(this.$$d[a]=this[a],delete this[a]);this.$$c=(r={component:this.$$ctor,target:this.$$shadowRoot||this,props:{...this.$$d,$$slots:n,$$host:this}},new jE(r)),this.$$me=(function(a){Vn.ensure();const l=hn(524352,a);return()=>{mt(l)}})(()=>{ys(()=>{this.$$r=!0;for(const a of $a(this.$$c)){if(!this.$$p_d[a]?.reflect)continue;this.$$d[a]=this.$$c[a];const l=Oa(a,this.$$d[a],this.$$p_d,"toAttribute");l==null?this.removeAttribute(this.$$p_d[a].attribute||a):this.setAttribute(this.$$p_d[a].attribute||a,l)}this.$$r=!1})});for(const a in this.$$l)for(const l of this.$$l[a]){const u=this.$$c.$on(a,l);this.$$l_u.set(l,u)}this.$$l={}}var r}attributeChangedCallback(r,t,n){this.$$r||(r=this.$$g_p(r),this.$$d[r]=Oa(r,n,this.$$p_d,"toProp"),this.$$c?.$set({[r]:this.$$d[r]}))}disconnectedCallback(){this.$$cn=!1,Promise.resolve().then(()=>{!this.$$cn&&this.$$c&&(this.$$c.$destroy(),this.$$me(),this.$$c=void 0)})}$$g_p(r){return $a(this.$$p_d).find(t=>this.$$p_d[t].attribute===r||!this.$$p_d[t].attribute&&t.toLowerCase()===r)||r}}),(function(r){r.CUSTOM_MESSAGE="custom",r.GET_CONTEXT="luigi.get-context",r.SEND_CONTEXT_HANDSHAKE="luigi.init",r.CONTEXT_RECEIVED="luigi.init.ok",r.NAVIGATION_REQUEST="luigi.navigation.open",r.ALERT_REQUEST="luigi.ux.alert.show",r.ALERT_CLOSED="luigi.ux.alert.hide",r.INITIALIZED="luigi.init.ok",r.ADD_SEARCH_PARAMS_REQUEST="luigi.addSearchParams",r.ADD_NODE_PARAMS_REQUEST="luigi.addNodeParams",r.SHOW_CONFIRMATION_MODAL_REQUEST="luigi.ux.confirmationModal.show",r.CONFIRMATION_MODAL_CLOSED="luigi.ux.confirmationModal.hide",r.SHOW_LOADING_INDICATOR_REQUEST="luigi.show-loading-indicator",r.HIDE_LOADING_INDICATOR_REQUEST="luigi.hide-loading-indicator",r.SET_CURRENT_LOCALE_REQUEST="luigi.ux.set-current-locale",r.LOCAL_STORAGE_SET_REQUEST="storage",r.RUNTIME_ERROR_HANDLING_REQUEST="luigi-runtime-error-handling",r.SET_ANCHOR_LINK_REQUEST="luigi.setAnchor",r.SET_THIRD_PARTY_COOKIES_REQUEST="luigi.third-party-cookie",r.BACK_NAVIGATION_REQUEST="luigi.navigation.back",r.GET_CURRENT_ROUTE_REQUEST="luigi.navigation.currentRoute",r.SEND_CURRENT_ROUTE_ANSWER="luigi.navigation.currentRoute.answer",r.SEND_CONTEXT_OBJECT="luigi.navigate",r.NAVIGATION_COMPLETED_REPORT="luigi.navigate.ok",r.CLOSE_MODAL_ANSWER="luigi.navigation.modal.close",r.UPDATE_MODAL_PATH_DATA_REQUEST="luigi.navigation.updateModalDataPath",r.UPDATE_MODAL_SETTINGS="luigi.navigation.updateModalSettings",r.CHECK_PATH_EXISTS_REQUEST="luigi.navigation.pathExists",r.SEND_PATH_EXISTS_ANSWER="luigi.navigation.pathExists.answer",r.SET_DIRTY_STATUS_REQUEST="luigi.set-page-dirty",r.AUTH_SET_TOKEN="luigi.auth.tokenIssued",r.ADD_BACKDROP_REQUEST="luigi.add-backdrop",r.REMOVE_BACKDROP_REQUEST="luigi.remove-backdrop",r.SET_VIEW_GROUP_DATA_REQUEST="luigi.setVGData",r.CLOSE_CURRENT_MODAL_REQUEST="luigi.close-modal"})(ue||(ue={}));class YE extends Event{constructor(t,n,s,a){super(t),this.detail=n,this.payload=s||n||{},this.callbackFn=a}callback(t){this.callbackFn&&this.callbackFn(t)}}const k={ADD_BACKDROP_REQUEST:"add-backdrop-request",ADD_NODE_PARAMS_REQUEST:"add-node-params-request",ADD_SEARCH_PARAMS_REQUEST:"add-search-params-request",ALERT_CLOSED:"close-alert-request",ALERT_REQUEST:"show-alert-request",BACK_NAVIGATION_REQUEST:"navigate-back-request",CHECK_PATH_EXISTS_REQUEST:"check-path-exists-request",CLOSE_CURRENT_MODAL_REQUEST:"close-current-modal-request",CLOSE_USER_SETTINGS_REQUEST:"close-user-settings-request",COLLAPSE_LEFT_NAV_REQUEST:"collapse-leftnav-request",CUSTOM_MESSAGE:"custom-message",GET_CONTEXT_REQUEST:"get-context-request",GET_CURRENT_ROUTE_REQUEST:"get-current-route-request",GO_BACK_REQUEST:"go-back-request",HAS_BACK_REQUEST:"has-back-request",HIDE_LOADING_INDICATOR_REQUEST:"hide-loading-indicator-request",INITIALIZED:"initialized",LOCAL_STORAGE_SET_REQUEST:"set-storage-request",NAVIGATION_COMPLETED_REPORT:"report-navigation-completed-request",NAVIGATION_REQUEST:"navigation-request",OPEN_USER_SETTINGS_REQUEST:"open-user-settings-request",PATH_EXISTS_REQUEST:"path-exists-request",REMOVE_BACKDROP_REQUEST:"remove-backdrop-request",RUNTIME_ERROR_HANDLING_REQUEST:"runtime-error-handling-request",SET_ANCHOR_LINK_REQUEST:"set-anchor-request",SET_CURRENT_LOCALE_REQUEST:"set-current-locale-request",SET_DIRTY_STATUS_REQUEST:"set-dirty-status-request",SET_DOCUMENT_TITLE_REQUEST:"set-document-title-request",SET_THIRD_PARTY_COOKIES_REQUEST:"set-third-party-cookies-request",SET_VIEW_GROUP_DATA_REQUEST:"set-viewgroup-data-request",SHOW_CONFIRMATION_MODAL_REQUEST:"show-confirmation-modal-request",SHOW_LOADING_INDICATOR_REQUEST:"show-loading-indicator-request",UPDATE_MODAL_PATH_DATA_REQUEST:"update-modal-path-data-request",UPDATE_MODAL_SETTINGS_REQUEST:"update-modal-settings-request",UPDATE_TOP_NAVIGATION_REQUEST:"update-top-navigation-request"};class vu{isVisible(t){return getComputedStyle(t).display!=="none"&&!(!t.offsetWidth&&!t.offsetHeight)}sendCustomMessageToIframe(t,n,s){const a=s||"custom";if(t?.iframe?.contentWindow){const l=new URL(t.iframe.src);a==="custom"?t.iframe.contentWindow.postMessage({msg:a,data:n},l.origin):t.iframe.contentWindow.postMessage({msg:a,...n},l.origin)}else console.error("Message target could not be resolved")}dispatchWithPayload(t,n,s,a,l){this.dispatch(t,n,s,l,a)}dispatch(t,n,s,a,l){const u=new YE(t,s,l,a);n.dispatchEvent(u)}getTargetContainer(t){let n;return globalThis.__luigi_container_manager.container.forEach(s=>{s.iframeHandle?.iframe&&s.iframeHandle.iframe.contentWindow===t.source&&(n=s)}),n}getContainerManager(){return globalThis.__luigi_container_manager||(globalThis.__luigi_container_manager={container:[],messageListener:t=>{const n=this.getTargetContainer(t),s=n?.iframeHandle?.iframe?.contentWindow;if(s&&s===t.source)switch(t.data.msg){case ue.CUSTOM_MESSAGE:{const a=t.data.data,l=a.id;delete a.id,this.dispatch(k.CUSTOM_MESSAGE,n,{id:l,_metaData:{},data:a})}break;case ue.GET_CONTEXT:s.postMessage({msg:ue.SEND_CONTEXT_HANDSHAKE,context:n.context||{},internal:{thirdPartyCookieCheck:{disabled:n.skipCookieCheck==="true"},currentTheme:n.theme,currentLocale:n.locale,activeFeatureToggleList:n.activeFeatureToggleList||[],cssVariables:n.cssVariables||{},anchor:n.anchor||"",userSettings:n.userSettings||null,drawer:n.drawer||!1,modal:n.modal||!1,viewStackSize:n.viewStackSize||0,isNavigateBack:n.isNavigateBack||!1},authData:n.authData||{},nodeParams:n.nodeParams||{},searchParams:n.searchParams||{},pathParams:n.pathParams||{}},t.origin);break;case ue.NAVIGATION_REQUEST:this.dispatch(k.NAVIGATION_REQUEST,n,t.data.params,a=>{s.postMessage({msg:ue.CLOSE_MODAL_ANSWER,data:a},t.origin)});break;case ue.ALERT_REQUEST:this.dispatchWithPayload(k.ALERT_REQUEST,n,t,t.data?.data?.settings,a=>{n.notifyAlertClosed(t.data?.data?.settings?.id,a)});break;case ue.INITIALIZED:this.dispatch(k.INITIALIZED,n,t.data?.params||{});break;case ue.ADD_SEARCH_PARAMS_REQUEST:this.dispatch(k.ADD_SEARCH_PARAMS_REQUEST,n,{data:t.data.data,keepBrowserHistory:t.data.keepBrowserHistory});break;case ue.ADD_NODE_PARAMS_REQUEST:this.dispatch(k.ADD_NODE_PARAMS_REQUEST,n,{data:t.data.data,keepBrowserHistory:t.data.keepBrowserHistory});break;case ue.SHOW_CONFIRMATION_MODAL_REQUEST:this.dispatchWithPayload(k.SHOW_CONFIRMATION_MODAL_REQUEST,n,t.data.data,t.data.data?.settings,a=>{n.notifyConfirmationModalClosed(a)});break;case ue.SHOW_LOADING_INDICATOR_REQUEST:this.dispatch(k.SHOW_LOADING_INDICATOR_REQUEST,n,t);break;case ue.HIDE_LOADING_INDICATOR_REQUEST:this.dispatch(k.HIDE_LOADING_INDICATOR_REQUEST,n,t);break;case ue.SET_CURRENT_LOCALE_REQUEST:this.dispatchWithPayload(k.SET_CURRENT_LOCALE_REQUEST,n,t,t.data.data);break;case ue.LOCAL_STORAGE_SET_REQUEST:this.dispatchWithPayload(k.LOCAL_STORAGE_SET_REQUEST,n,t,t.data.data?.params);break;case ue.RUNTIME_ERROR_HANDLING_REQUEST:this.dispatch(k.RUNTIME_ERROR_HANDLING_REQUEST,n,t);break;case ue.SET_ANCHOR_LINK_REQUEST:this.dispatchWithPayload(k.SET_ANCHOR_LINK_REQUEST,n,t,t.data.anchor);break;case ue.SET_THIRD_PARTY_COOKIES_REQUEST:this.dispatch(k.SET_THIRD_PARTY_COOKIES_REQUEST,n,t);break;case ue.BACK_NAVIGATION_REQUEST:{let a=t.data?.goBackContext||{};if(typeof a=="string")try{a=JSON.parse(a)}catch(l){console.warn(l)}this.dispatch(k.GO_BACK_REQUEST,n,a),this.dispatch(k.BACK_NAVIGATION_REQUEST,n,t)}break;case ue.GET_CURRENT_ROUTE_REQUEST:this.dispatchWithPayload(k.GET_CURRENT_ROUTE_REQUEST,n,t,t.data.data,a=>{s.postMessage({msg:ue.SEND_CURRENT_ROUTE_ANSWER,data:{correlationId:t.data?.data?.id,route:a}},t.origin)});break;case ue.NAVIGATION_COMPLETED_REPORT:this.dispatch(k.NAVIGATION_COMPLETED_REPORT,n,t);break;case ue.UPDATE_MODAL_PATH_DATA_REQUEST:this.dispatchWithPayload(k.UPDATE_MODAL_PATH_DATA_REQUEST,n,t,t.data.params);break;case ue.UPDATE_MODAL_SETTINGS:this.dispatchWithPayload(k.UPDATE_MODAL_SETTINGS_REQUEST,n,t,{addHistoryEntry:t.data.addHistoryEntry,updatedModalSettings:t.data.updatedModalSettings});break;case ue.CHECK_PATH_EXISTS_REQUEST:this.dispatchWithPayload(k.CHECK_PATH_EXISTS_REQUEST,n,t,t.data.data,a=>{s.postMessage({msg:ue.SEND_PATH_EXISTS_ANSWER,data:{correlationId:t.data?.data?.id,pathExists:a}},t.origin)});break;case ue.SET_DIRTY_STATUS_REQUEST:this.dispatchWithPayload(k.SET_DIRTY_STATUS_REQUEST,n,t,{dirty:t.data.dirty});break;case ue.SET_VIEW_GROUP_DATA_REQUEST:this.dispatch(k.SET_VIEW_GROUP_DATA_REQUEST,n,t.data.data);break;case ue.ADD_BACKDROP_REQUEST:this.dispatch(k.ADD_BACKDROP_REQUEST,n,t);break;case ue.REMOVE_BACKDROP_REQUEST:this.dispatch(k.REMOVE_BACKDROP_REQUEST,n,t);break;case ue.CLOSE_CURRENT_MODAL_REQUEST:this.dispatch(k.CLOSE_CURRENT_MODAL_REQUEST,n,t)}}},window.addEventListener("message",globalThis.__luigi_container_manager.messageListener)),globalThis.__luigi_container_manager}registerContainer(t){this.getContainerManager().container.push(t)}}const rr=new vu,pi=new class{constructor(){this.updateContext=(r,t,n,s,a,l)=>{if(n){const u=t||{};rr.sendCustomMessageToIframe(n,{context:r,nodeParams:s||{},pathParams:a||{},searchParams:l||{},internal:u,withoutSync:u.withoutSync??!0},ue.SEND_CONTEXT_OBJECT)}else console.warn("Attempting to update context on inexisting iframe")},this.updateViewUrl=(r,t,n,s)=>{if(s){const a=n||{};rr.sendCustomMessageToIframe(s,{context:t,internal:a,withoutSync:!1,viewUrl:r},ue.SEND_CONTEXT_OBJECT)}else console.warn("Attempting to update route on inexisting iframe")},this.updateAuthData=(r,t)=>{r&&t?rr.sendCustomMessageToIframe(r,{authData:t},ue.AUTH_SET_TOKEN):console.warn("Attempting to update auth data on inexisting iframe or authData")},this.sendCustomMessage=(r,t,n,s,a)=>{if(n&&t._luigi_mfe_webcomponent)rr.dispatch(r,t._luigi_mfe_webcomponent,a);else{const l={...a};l.id&&console.warn('Property "id" is reserved and can not be used in custom message data'),l.id=r,rr.sendCustomMessageToIframe(s,l)}},this.notifyConfirmationModalClosed=(r,t)=>{const n={data:{confirmed:r}};rr.sendCustomMessageToIframe(t,n,ue.CONFIRMATION_MODAL_CLOSED)}}notifyAlertClosed(r,t,n){const s=t?{id:r,dismissKey:t}:{id:r};rr.sendCustomMessageToIframe(n,s,ue.ALERT_CLOSED)}},Ah=r=>{if(!r)return;const t=r;return t.forEach((n,s)=>{t[s]=n+(n.indexOf(";")!=-1?"":";"),t[s]=r[s].replaceAll('"',"'")}),t.join(" ")};class Oi{constructor(t){t?(this.rendererObject=t,this.config=t.config||{}):this.config={}}createCompoundContainer(){return document.createElement("div")}createCompoundItemContainer(t){return document.createElement("div")}attachCompoundItem(t,n){t.appendChild(n)}}class JE extends Oi{constructor(t){super(t||{use:{}}),t&&t.use&&t.use.extends&&(this.superRenderer=Bd({use:t.use.extends,config:t.config}))}createCompoundContainer(){return this.rendererObject.use.createCompoundContainer?this.rendererObject.use.createCompoundContainer(this.config,this.superRenderer):this.superRenderer?this.superRenderer.createCompoundContainer():super.createCompoundContainer()}createCompoundItemContainer(t){return this.rendererObject.use.createCompoundItemContainer?this.rendererObject.use.createCompoundItemContainer(t,this.config,this.superRenderer):this.superRenderer?this.superRenderer.createCompoundItemContainer(t):super.createCompoundItemContainer(t)}attachCompoundItem(t,n){this.rendererObject.use.attachCompoundItem?this.rendererObject.use.attachCompoundItem(t,n,this.superRenderer):this.superRenderer?this.superRenderer.attachCompoundItem(t,n):super.attachCompoundItem(t,n)}}class XE extends Oi{createCompoundContainer(){const t="__lui_compound_"+new Date().getTime(),n=document.createElement("div");n.classList.add(t);let s="";return this.config.layouts&&this.config.layouts.forEach(a=>{if(a.minWidth||a.maxWidth){let l="@media only screen ";a.minWidth!=null&&(l+=`and (min-width: ${a.minWidth}px) `),a.maxWidth!=null&&(l+=`and (max-width: ${a.maxWidth}px) `),l+=`{
61
+ .${t} {
62
+ grid-template-columns: ${a.columns||"auto"};
63
+ grid-template-rows: ${a.rows||"auto"};
64
+ grid-gap: ${a.gap||"0"};
25
65
  }
26
66
  }
27
- `,a+=c}})),r.innerHTML=`
67
+ `,s+=l}}),n.innerHTML=`
28
68
  <style scoped>
29
- .${n} {
69
+ .${t} {
30
70
  display: grid;
31
71
  grid-template-columns: ${this.config.columns||"auto"};
32
72
  grid-template-rows: ${this.config.rows||"auto"};
33
73
  grid-gap: ${this.config.gap||"0"};
34
74
  min-height: ${this.config.minHeight||"auto"};
35
75
  }
36
- ${a}
76
+ ${s}
37
77
  </style>
38
- `,r}createCompoundItemContainer(n){const r=n||{},a=document.createElement("div");return a.setAttribute("style",`grid-row: ${r.row||"auto"}; grid-column: ${r.column||"auto"}`),a.classList.add("lui-compoundItemCnt"),a}}const mc=i=>{const n=i.use;return n?n==="grid"?new ew(i):n.createCompoundContainer||n.createCompoundItemContainer||n.attachCompoundItem?new jv(i):new _r(i):new _r(i)},Bl=(i,n,r,a)=>{n?.eventListeners&&n.eventListeners.forEach((u=>{const c=u.source+"."+u.name,l=i[c],d={wcElementId:r,wcElement:a,action:u.action,converter:u.dataConverter};l?l.push(d):i[c]=[d]}))};function Gl(i){return String(i).replaceAll("&lt;","<").replaceAll("&gt;",">").replaceAll("&quot;",'"').replaceAll("&#39;","'").replaceAll("&sol;","/")}class vc{constructor(){this.alertResolvers={},this.alertIndex=0,this.containerService=new qa}dynamicImport(n){return Object.freeze(import(n))}processViewUrl(n,r){return n}attachWC(n,r,a,u,c,l,d){if(a&&a.contains(r)){const p=document.createElement(n);l&&p.setAttribute("nodeId",l),p.setAttribute("lui_web_component","true"),this.initWC(p,n,a,c,u,l,d),a.replaceChild(p,r),a._luigi_node&&(a._luigi_mfe_webcomponent=p),a.dispatchEvent(new Event("wc_ready"))}}dispatchLuigiEvent(n,r,a){this.containerService.dispatch(n,this.thisComponent,r,a)}createClientAPI(n,r,a,u,c){return{linkManager:()=>{let l=null,d=!1,p=!1,_=!1,R={};const T={navigate:(E,C={})=>{const A={fromContext:l,fromClosestContext:d,fromVirtualTreeRoot:p,fromParent:_,nodeParams:R,...C};this.dispatchLuigiEvent(U.NAVIGATION_REQUEST,{link:E,...A})},navigateToIntent:(E,C={})=>{let A="#?intent=";if(A+=E,C&&Object.keys(C)?.length){const N=Object.entries(C);if(N.length>0){A+="?";for(const[H,W]of N)A+=H+"="+W+"&";A=A.slice(0,-1)}}T.navigate(A)},fromClosestContext:()=>(d=!0,T),fromContext:E=>(l=E,T),fromVirtualTreeRoot:()=>(p=!0,T),fromParent:()=>(_=!0,T),getCurrentRoute:()=>{const E={fromContext:l,fromClosestContext:d,fromVirtualTreeRoot:p,fromParent:_,nodeParams:R};return new Promise(((C,A)=>{this.containerService.dispatch(U.GET_CURRENT_ROUTE_REQUEST,this.thisComponent,{...E},(N=>{N?C(N):A("No current route received.")}))}))},withParams:E=>(R=E,T),updateModalPathInternalNavigation:(E,C={},A=!1)=>{if(!E)return void console.warn("Updating path of the modal upon internal navigation prevented. No path specified.");const N={fromClosestContext:d,fromContext:l,fromParent:_,fromVirtualTreeRoot:p,nodeParams:R};this.dispatchLuigiEvent(U.UPDATE_MODAL_PATH_DATA_REQUEST,Object.assign(N,{history:A,link:E,modal:C}))},updateTopNavigation:()=>{this.dispatchLuigiEvent(U.UPDATE_TOP_NAVIGATION_REQUEST,{})},pathExists:E=>{const C={fromContext:l,fromClosestContext:d,fromVirtualTreeRoot:p,fromParent:_,nodeParams:R};return new Promise(((A,N)=>{this.containerService.dispatch(U.CHECK_PATH_EXISTS_REQUEST,this.thisComponent,{...C,link:E},(H=>{H?A(!0):N(!1)})),this.containerService.dispatch(U.PATH_EXISTS_REQUEST,this.thisComponent,{...C,link:E},(H=>{H?A(!0):N(!1)}))}))},openAsDrawer:(E,C={})=>{T.navigate(E,{drawer:C})},openAsModal:(E,C={})=>{T.navigate(E,{modal:C})},openAsSplitView:(E,C={})=>{T.navigate(E,{splitView:C})},goBack:E=>{this.dispatchLuigiEvent(U.GO_BACK_REQUEST,E)},hasBack:()=>!1,updateModalSettings:(E={},C=!1)=>{this.dispatchLuigiEvent(U.UPDATE_MODAL_SETTINGS_REQUEST,{updatedModalSettings:E,addHistoryEntry:C})}};return T},uxManager:()=>({showAlert:l=>(l.id=this.alertIndex++,new Promise((d=>{this.alertResolvers[l.id]=d,this.dispatchLuigiEvent(U.ALERT_REQUEST,l,(p=>{this.resolveAlert(l.id,p)}))}))),showConfirmationModal:l=>new Promise(((d,p)=>{this.modalResolver={resolve:d,reject:p},this.containerService.dispatch(U.SHOW_CONFIRMATION_MODAL_REQUEST,this.thisComponent,l,(_=>{_?d():p()}))})),getCurrentTheme:()=>this.thisComponent.theme,closeUserSettings:()=>{this.dispatchLuigiEvent(U.CLOSE_USER_SETTINGS_REQUEST,this.thisComponent.userSettings)},openUserSettings:()=>{this.dispatchLuigiEvent(U.OPEN_USER_SETTINGS_REQUEST,this.thisComponent.userSettings)},collapseLeftSideNav:()=>{this.dispatchLuigiEvent(U.COLLAPSE_LEFT_NAV_REQUEST,{})},getDirtyStatus:()=>this.thisComponent.dirtyStatus||!1,getDocumentTitle:()=>this.thisComponent.documentTitle,setDocumentTitle:l=>{this.dispatchLuigiEvent(U.SET_DOCUMENT_TITLE_REQUEST,l)},setDirtyStatus:l=>{this.dispatchLuigiEvent(U.SET_DIRTY_STATUS_REQUEST,{dirty:l})},setCurrentLocale:l=>{l&&this.dispatchLuigiEvent(U.SET_CURRENT_LOCALE_REQUEST,{currentLocale:l})},removeBackdrop:()=>{this.dispatchLuigiEvent(U.REMOVE_BACKDROP_REQUEST,{})},addBackdrop:()=>{this.dispatchLuigiEvent(U.ADD_BACKDROP_REQUEST,{})},showLoadingIndicator:()=>{this.dispatchLuigiEvent(U.SHOW_LOADING_INDICATOR_REQUEST,{})},hideLoadingIndicator:()=>{this.dispatchLuigiEvent(U.HIDE_LOADING_INDICATOR_REQUEST,{})},hideAppLoadingIndicator:()=>{this.dispatchLuigiEvent(U.HIDE_LOADING_INDICATOR_REQUEST,{})},closeCurrentModal:()=>{this.dispatchLuigiEvent(U.CLOSE_CURRENT_MODAL_REQUEST,{})}}),getCurrentLocale:()=>this.thisComponent.locale,getActiveFeatureToggles:()=>this.thisComponent.activeFeatureToggleList||[],publishEvent:l=>{n&&n.eventBus&&n.eventBus.onPublishEvent(l,r,a);const d={id:l.type,_metaData:{nodeId:r,wc_id:a,src:u},data:l.detail};this.dispatchLuigiEvent(U.CUSTOM_MESSAGE,d)},luigiClientInit:()=>{this.dispatchLuigiEvent(U.INITIALIZED,{})},addNodeParams:(l,d)=>{c||this.dispatchLuigiEvent(U.ADD_NODE_PARAMS_REQUEST,{params:l,data:l,keepBrowserHistory:d})},getNodeParams:l=>{return c?{}:l?(d=this.thisComponent.nodeParams,Object.entries(d).reduce(((p,_)=>(p[Gl(_[0])]=Gl(_[1]),p)),{})):this.thisComponent.nodeParams||{};var d},setAnchor:l=>{c||this.dispatchLuigiEvent(U.SET_ANCHOR_LINK_REQUEST,l)},getAnchor:()=>this.thisComponent.anchor||"",getCoreSearchParams:()=>this.thisComponent.searchParams||{},getPathParams:()=>this.thisComponent.pathParams||{},getClientPermissions:()=>this.thisComponent.clientPermissions||{},addCoreSearchParams:(l={},d=!0)=>{this.dispatchLuigiEvent(U.ADD_SEARCH_PARAMS_REQUEST,{data:l,keepBrowserHistory:d})},getUserSettings:()=>this.thisComponent.userSettings||{},setViewGroupData:l=>{this.dispatchLuigiEvent(U.SET_VIEW_GROUP_DATA_REQUEST,l)}}}initWC(n,r,a,u,c,l,d){const p=this.createClientAPI(a,l,r,n,d);if(n.__postProcess){const _=new URL(document.baseURI).origin===new URL(u,document.baseURI).origin?new URL("./",new URL(u,document.baseURI)):new URL("./",u);n.__postProcess(c,p,_.origin+_.pathname)}else n.context=c,n.LuigiClient=p}generateWCId(n){let r="";const a=new URL(n,encodeURI(location.href)).href;for(let u=0;u<a.length;u++)r+=a.charCodeAt(u).toString(16);return"luigi-wc-"+r}registerWCFromUrl(n,r){const a=this.processViewUrl(n);return new Promise(((u,c)=>{this.checkWCUrl(a)?this.dynamicImport(a).then((l=>{try{if(!window.customElements.get(r)){let d=l.default;if(!HTMLElement.isPrototypeOf(d)){const p=Object.keys(l);for(let _=0;_<p.length&&(d=l[p[_]],!HTMLElement.isPrototypeOf(d));_++);}window.customElements.define(r,d)}u(1)}catch(d){c(d)}})).catch((l=>{c(l)})):c(`Error: View URL '${a}' not allowed to be included`)}))}includeSelfRegisteredWCFromUrl(n,r,a){if(this.checkWCUrl(r)){this.containerService.getContainerManager()._registerWebcomponent||(this.containerService.getContainerManager()._registerWebcomponent=(c,l)=>{window.customElements.define(this.generateWCId(c),l)}),window.Luigi||(window.Luigi={},window.Luigi._registerWebcomponent||(window.Luigi._registerWebcomponent=(c,l)=>{this.containerService.getContainerManager()._registerWebcomponent(c,l)}));const u=document.createElement("script");u.setAttribute("src",r),n.webcomponent.type==="module"&&u.setAttribute("type","module"),u.setAttribute("defer","true"),u.addEventListener("load",(()=>{a()})),document.body.appendChild(u)}else console.warn(`View URL '${r}' not allowed to be included`)}checkWCUrl(n){return!0}renderWebComponent(n,r,a,u,c,l){const d=this.processViewUrl(n,{context:a}),p=u?.webcomponent?.tagName||this.generateWCId(d),_=document.createElement("div");r.appendChild(_),r._luigi_node=u,window.customElements.get(p)?this.attachWC(p,_,r,a,d,c,l):window.luigiWCFn?window.luigiWCFn(d,p,_,(()=>{this.attachWC(p,_,r,a,d,c,l)})):u?.webcomponent?.selfRegistered?this.includeSelfRegisteredWCFromUrl(u,d,(()=>{this.attachWC(p,_,r,a,d,c,l)})):this.registerWCFromUrl(d,p).then((()=>{this.attachWC(p,_,r,a,d,c,l)})).catch((R=>{console.warn("ERROR =>",R),this.containerService.dispatch(U.RUNTIME_ERROR_HANDLING_REQUEST,this.thisComponent,R)}))}createCompoundContainerAsync(n,r,a){return new Promise(((u,c)=>{if(n.viewUrl)try{const l=a?.webcomponent?.tagName||this.generateWCId(n.viewUrl);a?.webcomponent?.selfRegistered?this.includeSelfRegisteredWCFromUrl(a,n.viewUrl,(()=>{const d=document.createElement(l);d.setAttribute("lui_web_component","true"),this.initWC(d,l,d,n.viewUrl,r,"_root"),u(d)})):this.registerWCFromUrl(n.viewUrl,l).then((()=>{const d=document.createElement(l);d.setAttribute("lui_web_component","true"),this.initWC(d,l,d,n.viewUrl,r,"_root"),u(d)})).catch((d=>{console.warn("Error: ",d),this.containerService.dispatch(U.RUNTIME_ERROR_HANDLING_REQUEST,this.thisComponent,d)}))}catch(l){c(l)}else u(n.createCompoundContainer())}))}renderWebComponentCompound(n,r,a){let u;return n.webcomponent&&n.viewUrl?(u=new _r,u.viewUrl=this.processViewUrl(n.viewUrl,{context:a}),u.createCompoundItemContainer=c=>{const l=document.createElement("div");return c?.slot&&l.setAttribute("slot",c.slot),l}):n.compound?.renderer&&(u=mc(n.compound.renderer)),u=u||new _r,new Promise((c=>{this.createCompoundContainerAsync(u,a,n).then((l=>{r._luigi_mfe_webcomponent=l,r._luigi_node=n;const d={};l.eventBus={listeners:d,onPublishEvent:(p,_,R)=>{const T=d[_+"."+p.type]||[];T.push(...d["*."+p.type]||[]),T.forEach((E=>{const C=E.wcElement||l.querySelector("[nodeId="+E.wcElementId+"]");C?C.dispatchEvent(new CustomEvent(E.action,{detail:E.converter?E.converter(p.detail):p.detail})):console.debug("Could not find event target",E)}))}},n.compound?.children?.forEach(((p,_)=>{const R={...a,...p.context},T=u.createCompoundItemContainer(p.layoutConfig);T.eventBus=l.eventBus,u.attachCompoundItem(l,T);const E=p.id||"gen_"+_;this.renderWebComponent(p.viewUrl,T,R,p,E,!0),Bl(d,p,E)})),r.appendChild(l),Bl(d,n.compound,"_root",l),c(l)})).catch((l=>{console.warn("Error: ",l),this.containerService.dispatch(U.RUNTIME_ERROR_HANDLING_REQUEST,this.thisComponent,l)}))}))}resolveAlert(n,r){this.alertResolvers[n]?(this.alertResolvers[n](r===void 0||r),this.alertResolvers[n]=void 0):console.log("Promise is not in the list.")}notifyConfirmationModalClosed(n){this.modalResolver?(n?this.modalResolver.resolve():this.modalResolver.reject(),this.modalResolver=void 0):console.log("Modal promise is not listed.")}}const qr=new class{isFunction(i){return i&&{}.toString.call(i)==="[object Function]"}isObject(i){return!(!i||typeof i!="object"||Array.isArray(i))}checkWebcomponentValue(i){return typeof i=="string"?JSON.parse(i):typeof i=="boolean"||typeof i=="object"?i:void console.warn("Webcomponent value has a wrong type.")}resolveContext(i){return i?typeof i=="string"?JSON.parse(i):i:{}}};function Ql(i){let n,r=(!i[4]||i[4]==="false")&&ql(i);return{c(){r&&r.c(),n=cc("")},m(a,u){r&&r.m(a,u),Dn(a,n,u)},p(a,u){a[4]&&a[4]!=="false"?r&&(r.d(1),r=null):r?r.p(a,u):(r=ql(a),r.c(),r.m(n.parentNode,n))},d(a){a&&dn(n),r&&r.d(a)}}}function ql(i){let n,r,a,u,c,l;return{c(){n=pr("style"),n.textContent=`main.lui-isolated,
78
+ `,n}createCompoundItemContainer(t){const n=t||{},s=document.createElement("div");return s.setAttribute("style",`grid-row: ${n.row||"auto"}; grid-column: ${n.column||"auto"}`),s.classList.add("lui-compoundItemCnt"),s}}const Bd=r=>{const t=r.use;return t?t==="grid"?new XE(r):t.createCompoundContainer||t.createCompoundItemContainer||t.attachCompoundItem?new JE(r):new Oi(r):new Oi(r)},Ph=(r,t,n,s)=>{t?.eventListeners&&t.eventListeners.forEach(a=>{const l=a.source+"."+a.name,u=r[l],f={wcElementId:n,wcElement:s,action:a.action,converter:a.dataConverter};u?u.push(f):r[l]=[f]})};function Ih(r){return String(r).replaceAll("&lt;","<").replaceAll("&gt;",">").replaceAll("&quot;",'"').replaceAll("&#39;","'").replaceAll("&sol;","/")}class Gd{constructor(){this.alertResolvers={},this.alertIndex=0,this.containerService=new vu}dynamicImport(t){return Object.freeze(import(t))}processViewUrl(t,n){return t}attachWC(t,n,s,a,l,u,f){if(s&&s.contains(n)){const h=document.createElement(t);u&&h.setAttribute("nodeId",u),h.setAttribute("lui_web_component","true"),this.initWC(h,t,s,l,a,u,f),s.replaceChild(h,n),s._luigi_node&&(s._luigi_mfe_webcomponent=h),s.dispatchEvent(new Event("wc_ready"))}}dispatchLuigiEvent(t,n,s){this.containerService.dispatch(t,this.thisComponent,n,s)}createClientAPI(t,n,s,a,l){return{linkManager:()=>{let u=null,f=!1,h=!1,g=!1,_={};const w={navigate:(m,E={},b)=>{const R={fromContext:u,fromClosestContext:f,fromVirtualTreeRoot:h,fromParent:g,nodeParams:_,...E};this.dispatchLuigiEvent(k.NAVIGATION_REQUEST,{link:m,...R},b)},navigateToIntent:(m,E={})=>{let b="#?intent=";if(b+=m,E&&Object.keys(E)?.length){const R=Object.entries(E);if(R.length>0){b+="?";for(const[I,N]of R)b+=I+"="+N+"&";b=b.slice(0,-1)}}w.navigate(b)},fromClosestContext:()=>(f=!0,w),fromContext:m=>(u=m,w),fromVirtualTreeRoot:()=>(h=!0,w),fromParent:()=>(g=!0,w),getCurrentRoute:()=>{const m={fromContext:u,fromClosestContext:f,fromVirtualTreeRoot:h,fromParent:g,nodeParams:_};return new Promise((E,b)=>{this.containerService.dispatch(k.GET_CURRENT_ROUTE_REQUEST,this.thisComponent,{...m},R=>{R?E(R):b("No current route received.")})})},withParams:m=>(_=m,w),updateModalPathInternalNavigation:(m,E={},b=!1)=>{if(!m)return void console.warn("Updating path of the modal upon internal navigation prevented. No path specified.");const R={fromClosestContext:f,fromContext:u,fromParent:g,fromVirtualTreeRoot:h,nodeParams:_};this.dispatchLuigiEvent(k.UPDATE_MODAL_PATH_DATA_REQUEST,Object.assign(R,{history:b,link:m,modal:E}))},updateTopNavigation:()=>{this.dispatchLuigiEvent(k.UPDATE_TOP_NAVIGATION_REQUEST,{})},pathExists:m=>{const E={fromContext:u,fromClosestContext:f,fromVirtualTreeRoot:h,fromParent:g,nodeParams:_};return new Promise((b,R)=>{this.containerService.dispatch(k.CHECK_PATH_EXISTS_REQUEST,this.thisComponent,{...E,link:m},I=>{I?b(!0):R(!1)}),this.containerService.dispatch(k.PATH_EXISTS_REQUEST,this.thisComponent,{...E,link:m},I=>{I?b(!0):R(!1)})})},openAsDrawer:(m,E={})=>{w.navigate(m,{drawer:E})},openAsModal:(m,E={},b)=>new Promise(R=>{w.navigate(m,{modal:E},I=>{R({goBackValue:I}),b&&typeof b=="function"&&b(I)})}),openAsSplitView:(m,E={})=>{w.navigate(m,{splitView:E})},goBack:m=>{this.dispatchLuigiEvent(k.GO_BACK_REQUEST,m)},hasBack:()=>!1,updateModalSettings:(m={},E=!1)=>{this.dispatchLuigiEvent(k.UPDATE_MODAL_SETTINGS_REQUEST,{updatedModalSettings:m,addHistoryEntry:E})}};return w},uxManager:()=>({showAlert:u=>(u.id=this.alertIndex++,new Promise(f=>{this.alertResolvers[u.id]=f,this.dispatchLuigiEvent(k.ALERT_REQUEST,u,h=>{this.resolveAlert(u.id,h)})})),showConfirmationModal:u=>new Promise((f,h)=>{this.modalResolver={resolve:f,reject:h},this.containerService.dispatch(k.SHOW_CONFIRMATION_MODAL_REQUEST,this.thisComponent,u,g=>{g?f():h()})}),getCurrentTheme:()=>this.thisComponent.theme,closeUserSettings:()=>{this.dispatchLuigiEvent(k.CLOSE_USER_SETTINGS_REQUEST,this.thisComponent.userSettings)},openUserSettings:()=>{this.dispatchLuigiEvent(k.OPEN_USER_SETTINGS_REQUEST,this.thisComponent.userSettings)},collapseLeftSideNav:()=>{this.dispatchLuigiEvent(k.COLLAPSE_LEFT_NAV_REQUEST,{})},getDirtyStatus:()=>this.thisComponent.dirtyStatus||!1,getDocumentTitle:()=>this.thisComponent.documentTitle,setDocumentTitle:u=>{this.dispatchLuigiEvent(k.SET_DOCUMENT_TITLE_REQUEST,u)},setDirtyStatus:u=>{this.dispatchLuigiEvent(k.SET_DIRTY_STATUS_REQUEST,{dirty:u})},setCurrentLocale:u=>{u&&this.dispatchLuigiEvent(k.SET_CURRENT_LOCALE_REQUEST,{currentLocale:u})},removeBackdrop:()=>{this.dispatchLuigiEvent(k.REMOVE_BACKDROP_REQUEST,{})},addBackdrop:()=>{this.dispatchLuigiEvent(k.ADD_BACKDROP_REQUEST,{})},showLoadingIndicator:()=>{this.dispatchLuigiEvent(k.SHOW_LOADING_INDICATOR_REQUEST,{})},hideLoadingIndicator:()=>{this.dispatchLuigiEvent(k.HIDE_LOADING_INDICATOR_REQUEST,{})},hideAppLoadingIndicator:()=>{this.dispatchLuigiEvent(k.HIDE_LOADING_INDICATOR_REQUEST,{})},closeCurrentModal:()=>{this.dispatchLuigiEvent(k.CLOSE_CURRENT_MODAL_REQUEST,{})}}),getCurrentLocale:()=>this.thisComponent.locale,getActiveFeatureToggles:()=>this.thisComponent.activeFeatureToggleList||[],publishEvent:u=>{t&&t.eventBus&&t.eventBus.onPublishEvent(u,n,s);const f={id:u.type,_metaData:{nodeId:n,wc_id:s,src:a},data:u.detail};this.dispatchLuigiEvent(k.CUSTOM_MESSAGE,f)},luigiClientInit:()=>{this.dispatchLuigiEvent(k.INITIALIZED,{})},addNodeParams:(u,f)=>{l||this.dispatchLuigiEvent(k.ADD_NODE_PARAMS_REQUEST,{params:u,data:u,keepBrowserHistory:f})},getNodeParams:u=>{return l?{}:u?(f=this.thisComponent.nodeParams,Object.entries(f).reduce((h,g)=>(h[Ih(g[0])]=Ih(g[1]),h),{})):this.thisComponent.nodeParams||{};var f},setAnchor:u=>{l||this.dispatchLuigiEvent(k.SET_ANCHOR_LINK_REQUEST,u)},getAnchor:()=>this.thisComponent.anchor||"",getCoreSearchParams:()=>this.thisComponent.searchParams||{},getPathParams:()=>this.thisComponent.pathParams||{},getClientPermissions:()=>this.thisComponent.clientPermissions||{},addCoreSearchParams:(u={},f=!0)=>{this.dispatchLuigiEvent(k.ADD_SEARCH_PARAMS_REQUEST,{data:u,keepBrowserHistory:f})},getUserSettings:()=>this.thisComponent.userSettings||{},setViewGroupData:u=>{this.dispatchLuigiEvent(k.SET_VIEW_GROUP_DATA_REQUEST,u)}}}initWC(t,n,s,a,l,u,f){const h=this.createClientAPI(s,u,n,t,f);if(t.__postProcess){const g=new URL(document.baseURI).origin===new URL(a,document.baseURI).origin?new URL("./",new URL(a,document.baseURI)):new URL("./",a);t.__postProcess(l,h,g.origin+g.pathname)}else t.context=l,t.LuigiClient=h}generateWCId(t){let n="";const s=new URL(t,encodeURI(location.href)).href;for(let a=0;a<s.length;a++)n+=s.charCodeAt(a).toString(16);return"luigi-wc-"+n}registerWCFromUrl(t,n){const s=this.processViewUrl(t);return new Promise((a,l)=>{this.checkWCUrl(s)?this.dynamicImport(s).then(u=>{try{if(!window.customElements.get(n)){let f=u.default;if(!HTMLElement.isPrototypeOf(f)){const h=Object.keys(u);for(let g=0;g<h.length&&(f=u[h[g]],!HTMLElement.isPrototypeOf(f));g++);}window.customElements.define(n,f)}a(1)}catch(f){l(f)}}).catch(u=>{l(u)}):l(`Error: View URL '${s}' not allowed to be included`)})}includeSelfRegisteredWCFromUrl(t,n,s){if(this.checkWCUrl(n)){this.containerService.getContainerManager()._registerWebcomponent||(this.containerService.getContainerManager()._registerWebcomponent=(l,u)=>{window.customElements.define(this.generateWCId(l),u)}),window.Luigi||(window.Luigi={},window.Luigi._registerWebcomponent||(window.Luigi._registerWebcomponent=(l,u)=>{this.containerService.getContainerManager()._registerWebcomponent(l,u)}));const a=document.createElement("script");a.setAttribute("src",n),t.webcomponent.type==="module"&&a.setAttribute("type","module"),a.setAttribute("defer","true"),a.addEventListener("load",()=>{s()}),document.body.appendChild(a)}else console.warn(`View URL '${n}' not allowed to be included`)}checkWCUrl(t){return!0}renderWebComponent(t,n,s,a,l,u){const f=this.processViewUrl(t,{context:s}),h=a?.webcomponent?.tagName||this.generateWCId(f),g=document.createElement("div");n.appendChild(g),n._luigi_node=a,window.customElements.get(h)?this.attachWC(h,g,n,s,f,l,u):window.luigiWCFn?window.luigiWCFn(f,h,g,()=>{this.attachWC(h,g,n,s,f,l,u)}):a?.webcomponent?.selfRegistered?this.includeSelfRegisteredWCFromUrl(a,f,()=>{this.attachWC(h,g,n,s,f,l,u)}):this.registerWCFromUrl(f,h).then(()=>{this.attachWC(h,g,n,s,f,l,u)}).catch(_=>{console.warn("ERROR =>",_),this.containerService.dispatch(k.RUNTIME_ERROR_HANDLING_REQUEST,this.thisComponent,_)})}createCompoundContainerAsync(t,n,s){return new Promise((a,l)=>{if(t.viewUrl)try{const u=s?.webcomponent?.tagName||this.generateWCId(t.viewUrl);s?.webcomponent?.selfRegistered?this.includeSelfRegisteredWCFromUrl(s,t.viewUrl,()=>{const f=document.createElement(u);f.setAttribute("lui_web_component","true"),this.initWC(f,u,f,t.viewUrl,n,"_root"),a(f)}):this.registerWCFromUrl(t.viewUrl,u).then(()=>{const f=document.createElement(u);f.setAttribute("lui_web_component","true"),this.initWC(f,u,f,t.viewUrl,n,"_root"),a(f)}).catch(f=>{console.warn("Error: ",f),this.containerService.dispatch(k.RUNTIME_ERROR_HANDLING_REQUEST,this.thisComponent,f)})}catch(u){l(u)}else a(t.createCompoundContainer())})}renderWebComponentCompound(t,n,s){let a;return t.webcomponent&&t.viewUrl?(a=new Oi,a.viewUrl=this.processViewUrl(t.viewUrl,{context:s}),a.createCompoundItemContainer=l=>{const u=document.createElement("div");return l?.slot&&u.setAttribute("slot",l.slot),u}):t.compound?.renderer&&(a=Bd(t.compound.renderer)),a=a||new Oi,new Promise(l=>{this.createCompoundContainerAsync(a,s,t).then(u=>{n._luigi_mfe_webcomponent=u,n._luigi_node=t;const f={};u.eventBus={listeners:f,onPublishEvent:(h,g,_)=>{const w=f[g+"."+h.type]||[];w.push(...f["*."+h.type]||[]),w.forEach(m=>{const E=m.wcElement||u.querySelector("[nodeId="+m.wcElementId+"]");E?E.dispatchEvent(new CustomEvent(m.action,{detail:m.converter?m.converter(h.detail):h.detail})):console.debug("Could not find event target",m)})}},t.compound?.children?.forEach((h,g)=>{const _={...s,...h.context},w=a.createCompoundItemContainer(h.layoutConfig);w.eventBus=u.eventBus,a.attachCompoundItem(u,w);const m=h.id||"gen_"+g;this.renderWebComponent(h.viewUrl,w,_,h,m,!0),Ph(f,h,m)}),n.appendChild(u),Ph(f,t.compound,"_root",u),l(u)}).catch(u=>{console.warn("Error: ",u),this.containerService.dispatch(k.RUNTIME_ERROR_HANDLING_REQUEST,this.thisComponent,u)})})}resolveAlert(t,n){this.alertResolvers[t]?(this.alertResolvers[t](n===void 0||n),this.alertResolvers[t]=void 0):console.log("Promise is not in the list.")}notifyConfirmationModalClosed(t){this.modalResolver?(t?this.modalResolver.resolve():this.modalResolver.reject(),this.modalResolver=void 0):console.log("Modal promise is not listed.")}}const ds=new class{isFunction(r){return r&&{}.toString.call(r)==="[object Function]"}isObject(r){return!(!r||typeof r!="object"||Array.isArray(r))}checkWebcomponentValue(r){return typeof r=="string"?JSON.parse(r):typeof r=="boolean"||typeof r=="object"?r:void console.warn("Webcomponent value has a wrong type.")}resolveContext(r){return r?typeof r=="string"?JSON.parse(r):r:{}}};var ZE=pu(`<style>main.lui-isolated,
39
79
  .lui-isolated iframe {
40
80
  width: 100%;
41
81
  height: 100%;
@@ -44,12 +84,12 @@ function print() { __p += __j.call(arguments, '') }
44
84
 
45
85
  main.lui-isolated {
46
86
  line-height: 0;
47
- }`,r=cc(" "),a=pr("iframe"),Hl(a.src,u=i[3])||_t(a,"src",u),_t(a,"title",i[1]),_t(a,"allow",c=Vl(i[0])),_t(a,"sandbox",l=i[2]?i[2].join(" "):void 0)},m(d,p){Dn(d,n,p),Dn(d,r,p),Dn(d,a,p),i[28](a)},p(d,p){8&p[0]&&!Hl(a.src,u=d[3])&&_t(a,"src",u),2&p[0]&&_t(a,"title",d[1]),1&p[0]&&c!==(c=Vl(d[0]))&&_t(a,"allow",c),4&p[0]&&l!==(l=d[2]?d[2].join(" "):void 0)&&_t(a,"sandbox",l)},d(d){d&&(dn(n),dn(r),dn(a)),i[28](null)}}}function tw(i){let n,r,a=i[5]&&Ql(i);return{c(){n=pr("main"),a&&a.c(),_t(n,"class",r=i[4]?void 0:"lui-isolated")},m(u,c){Dn(u,n,c),a&&a.m(n,null),i[29](n)},p(u,c){u[5]?a?a.p(u,c):(a=Ql(u),a.c(),a.m(n,null)):a&&(a.d(1),a=null),16&c[0]&&r!==(r=u[4]?void 0:"lui-isolated")&&_t(n,"class",r)},i:fn,o:fn,d(u){u&&dn(n),a&&a.d(),i[29](null)}}}function nw(i,n,r){let{activeFeatureToggleList:a}=n,{allowRules:u}=n,{anchor:c}=n,{authData:l}=n,{clientPermissions:d}=n,{context:p}=n,{deferInit:_}=n,{dirtyStatus:R}=n,{documentTitle:T}=n,{hasBack:E}=n,{label:C}=n,{locale:A}=n,{noShadow:N}=n,{nodeParams:H}=n,{pathParams:W}=n,{sandboxRules:ie}=n,{searchParams:Oe}=n,{skipCookieCheck:Ie}=n,{skipInitCheck:Qe}=n,{theme:xe}=n,{userSettings:Je}=n,{viewurl:ye}=n,{webcomponent:Re}=n;const ve={};let be,$,Zt=!1;const wt=new vc,$e=L=>{if(!Zt){L.sendCustomMessage=(oe,ke)=>{ar.sendCustomMessage(oe,L.getNoShadow()?L:be,!!Re,ve,ke)},L.updateContext=(oe,ke)=>{if(r(8,p=oe),Re)(L.getNoShadow()?L:be)._luigi_mfe_webcomponent.context=oe;else{const Jt={...ke||{},activeFeatureToggleList:L.activeFeatureToggleList||[],currentLocale:L.locale,currentTheme:L.theme,userSettings:L.userSettings||null,cssVariables:L.cssVariables||{},anchor:L.anchor||"",drawer:L.drawer||!1,modal:L.modal||!1,viewStackSize:L.viewStackSize||0,isNavigateBack:L.isNavigateBack||!1};ar.updateContext(oe,Jt,ve,H,W,Oe)}},L.closeAlert=(oe,ke)=>{L.notifyAlertClosed(oe,ke)},L.notifyAlertClosed=(oe,ke)=>{L.isConnected&&(Re?wt.resolveAlert(oe,ke):ar.notifyAlertClosed(oe,ke,ve))},L.notifyConfirmationModalClosed=oe=>{L.isConnected&&(Re?wt.notifyConfirmationModalClosed(!!oe):ar.notifyConfirmationModalClosed(!!oe,ve))},hn.registerContainer(L),wt.thisComponent=L;const ot=qr.resolveContext(p);if(L.updateViewUrl=(oe,ke)=>{oe?.length&&ar.updateViewUrl(oe,qr.resolveContext(p),ke,ve)},Re&&Re!="false"){L.getNoShadow()?L.innerHTML="":(r(7,be.innerHTML="",be),L.attachShadow({mode:"open"}).append(be));const oe=qr.checkWebcomponentValue(Re);wt.renderWebComponent(ye,L.getNoShadow()?L:be,ot,typeof oe=="object"?{webcomponent:oe}:{})}else L.getNoShadow()||(L.innerHTML="",L.attachShadow({mode:"open"}).append(be));Qe?(L.initialized=!0,setTimeout((()=>{wt.dispatchLuigiEvent(U.INITIALIZED,{})}))):Re&&(L.getNoShadow()?L:be).addEventListener("wc_ready",(()=>{(L.getNoShadow()?L:be)._luigi_mfe_webcomponent?.deferLuigiClientWCInit||(L.initialized=!0,wt.dispatchLuigiEvent(U.INITIALIZED,{}))})),r(5,Zt=!0),L.containerInitialized=!0}};var En;return fc((async()=>{r(27,$=be.parentNode),r(27,$.iframeHandle=ve,$),r(27,$.init=()=>{$e($)},$),!_&&ye&&$e($)})),En=async()=>{},hc().$$.on_destroy.push(En),i.$$set=L=>{"activeFeatureToggleList"in L&&r(9,a=L.activeFeatureToggleList),"allowRules"in L&&r(0,u=L.allowRules),"anchor"in L&&r(10,c=L.anchor),"authData"in L&&r(11,l=L.authData),"clientPermissions"in L&&r(12,d=L.clientPermissions),"context"in L&&r(8,p=L.context),"deferInit"in L&&r(13,_=L.deferInit),"dirtyStatus"in L&&r(14,R=L.dirtyStatus),"documentTitle"in L&&r(15,T=L.documentTitle),"hasBack"in L&&r(16,E=L.hasBack),"label"in L&&r(1,C=L.label),"locale"in L&&r(17,A=L.locale),"noShadow"in L&&r(18,N=L.noShadow),"nodeParams"in L&&r(19,H=L.nodeParams),"pathParams"in L&&r(20,W=L.pathParams),"sandboxRules"in L&&r(2,ie=L.sandboxRules),"searchParams"in L&&r(21,Oe=L.searchParams),"skipCookieCheck"in L&&r(22,Ie=L.skipCookieCheck),"skipInitCheck"in L&&r(23,Qe=L.skipInitCheck),"theme"in L&&r(24,xe=L.theme),"userSettings"in L&&r(25,Je=L.userSettings),"viewurl"in L&&r(3,ye=L.viewurl),"webcomponent"in L&&r(4,Re=L.webcomponent)},i.$$.update=()=>{134225960&i.$$.dirty[0]&&!Zt&&ye&&!_&&$&&$e($)},[u,C,ie,ye,Re,Zt,ve,be,p,a,c,l,d,_,R,T,E,A,N,H,W,Oe,Ie,Qe,xe,Je,()=>a&&u&&c&&l&&d&&R&&T&&E&&A&&N&&H&&W&&ie&&Oe&&Ie&&Qe&&xe&&Je,$,function(L){Xr[L?"unshift":"push"]((()=>{ve.iframe=L,r(6,ve)}))},function(L){Xr[L?"unshift":"push"]((()=>{be=L,r(7,be)}))}]}class wc extends _c{constructor(n){super(),dc(this,n,nw,tw,lc,{activeFeatureToggleList:9,allowRules:0,anchor:10,authData:11,clientPermissions:12,context:8,deferInit:13,dirtyStatus:14,documentTitle:15,hasBack:16,label:1,locale:17,noShadow:18,nodeParams:19,pathParams:20,sandboxRules:2,searchParams:21,skipCookieCheck:22,skipInitCheck:23,theme:24,userSettings:25,viewurl:3,webcomponent:4,unwarn:26},null,[-1,-1])}get activeFeatureToggleList(){return this.$$.ctx[9]}set activeFeatureToggleList(n){this.$$set({activeFeatureToggleList:n}),q()}get allowRules(){return this.$$.ctx[0]}set allowRules(n){this.$$set({allowRules:n}),q()}get anchor(){return this.$$.ctx[10]}set anchor(n){this.$$set({anchor:n}),q()}get authData(){return this.$$.ctx[11]}set authData(n){this.$$set({authData:n}),q()}get clientPermissions(){return this.$$.ctx[12]}set clientPermissions(n){this.$$set({clientPermissions:n}),q()}get context(){return this.$$.ctx[8]}set context(n){this.$$set({context:n}),q()}get deferInit(){return this.$$.ctx[13]}set deferInit(n){this.$$set({deferInit:n}),q()}get dirtyStatus(){return this.$$.ctx[14]}set dirtyStatus(n){this.$$set({dirtyStatus:n}),q()}get documentTitle(){return this.$$.ctx[15]}set documentTitle(n){this.$$set({documentTitle:n}),q()}get hasBack(){return this.$$.ctx[16]}set hasBack(n){this.$$set({hasBack:n}),q()}get label(){return this.$$.ctx[1]}set label(n){this.$$set({label:n}),q()}get locale(){return this.$$.ctx[17]}set locale(n){this.$$set({locale:n}),q()}get noShadow(){return this.$$.ctx[18]}set noShadow(n){this.$$set({noShadow:n}),q()}get nodeParams(){return this.$$.ctx[19]}set nodeParams(n){this.$$set({nodeParams:n}),q()}get pathParams(){return this.$$.ctx[20]}set pathParams(n){this.$$set({pathParams:n}),q()}get sandboxRules(){return this.$$.ctx[2]}set sandboxRules(n){this.$$set({sandboxRules:n}),q()}get searchParams(){return this.$$.ctx[21]}set searchParams(n){this.$$set({searchParams:n}),q()}get skipCookieCheck(){return this.$$.ctx[22]}set skipCookieCheck(n){this.$$set({skipCookieCheck:n}),q()}get skipInitCheck(){return this.$$.ctx[23]}set skipInitCheck(n){this.$$set({skipInitCheck:n}),q()}get theme(){return this.$$.ctx[24]}set theme(n){this.$$set({theme:n}),q()}get userSettings(){return this.$$.ctx[25]}set userSettings(n){this.$$set({userSettings:n}),q()}get viewurl(){return this.$$.ctx[3]}set viewurl(n){this.$$set({viewurl:n}),q()}get webcomponent(){return this.$$.ctx[4]}set webcomponent(n){this.$$set({webcomponent:n}),q()}get unwarn(){return this.$$.ctx[26]}}function rw(i){qv(i,"svelte-1buc46y","main.svelte-1buc46y{width:100%;height:100%;border:none}")}function iw(i){let n;return{c(){n=pr("main"),_t(n,"class","svelte-1buc46y")},m(r,a){Dn(r,n,a),i[21](n)},p:fn,i:fn,o:fn,d(r){r&&dn(n),i[21](null)}}}function sw(i,n,r){let a,u,{activeFeatureToggleList:c}=n,{anchor:l}=n,{clientPermissions:d}=n,{compoundConfig:p}=n,{context:_}=n,{deferInit:R}=n,{dirtyStatus:T}=n,{documentTitle:E}=n,{hasBack:C}=n,{locale:A}=n,{noShadow:N}=n,{nodeParams:H}=n,{pathParams:W}=n,{searchParams:ie}=n,{skipInitCheck:Oe}=n,{theme:Ie}=n,{userSettings:Qe}=n,{viewurl:xe}=n,{webcomponent:Je}=n,ye=!1;const Re=new qa,ve=new vc,be=$=>{if(!p||ye)return;$.updateContext=($e,En)=>{const L=$.getNoShadow()?$:a;L._luigi_mfe_webcomponent.context=$e,r(1,_=$e);const ot=L._luigi_mfe_webcomponent;ot&&ot.querySelectorAll("[lui_web_component]")?.forEach((ke=>{const Jt=ke.context||{};ke.context=Object.assign(Jt,$e)}))};const Zt=qr.resolveContext(_);r(2,R=!1),$.notifyAlertClosed=($e,En)=>{$.isConnected&&ve.resolveAlert($e,En)},$.notifyConfirmationModalClosed=$e=>{$.isConnected&&ve.notifyConfirmationModalClosed(!!$e)};const wt={compound:p,viewUrl:xe,webcomponent:qr.checkWebcomponentValue(Je)||!0};$.getNoShadow()?$.innerHTML="":(r(0,a.innerHTML="",a),$.attachShadow({mode:"open"}).append(a)),ve.renderWebComponentCompound(wt,$.getNoShadow()?$:a,Zt).then(($e=>{u=$e,Oe||!wt.viewUrl?($.initialized=!0,setTimeout((()=>{ve.dispatchLuigiEvent(U.INITIALIZED,{})}))):u.LuigiClient&&!u.deferLuigiClientWCInit&&($.initialized=!0,ve.dispatchLuigiEvent(U.INITIALIZED,{}))})),ye=!0,$.containerInitialized=!0};return fc((async()=>{const $=a.getRootNode()===document?a.parentNode:a.getRootNode().host;$.init=()=>{be($)},R||be($),Re.registerContainer($),ve.thisComponent=$})),i.$$set=$=>{"activeFeatureToggleList"in $&&r(3,c=$.activeFeatureToggleList),"anchor"in $&&r(4,l=$.anchor),"clientPermissions"in $&&r(5,d=$.clientPermissions),"compoundConfig"in $&&r(6,p=$.compoundConfig),"context"in $&&r(1,_=$.context),"deferInit"in $&&r(2,R=$.deferInit),"dirtyStatus"in $&&r(7,T=$.dirtyStatus),"documentTitle"in $&&r(8,E=$.documentTitle),"hasBack"in $&&r(9,C=$.hasBack),"locale"in $&&r(10,A=$.locale),"noShadow"in $&&r(11,N=$.noShadow),"nodeParams"in $&&r(12,H=$.nodeParams),"pathParams"in $&&r(13,W=$.pathParams),"searchParams"in $&&r(14,ie=$.searchParams),"skipInitCheck"in $&&r(15,Oe=$.skipInitCheck),"theme"in $&&r(16,Ie=$.theme),"userSettings"in $&&r(17,Qe=$.userSettings),"viewurl"in $&&r(18,xe=$.viewurl),"webcomponent"in $&&r(19,Je=$.webcomponent)},[a,_,R,c,l,d,p,T,E,C,A,N,H,W,ie,Oe,Ie,Qe,xe,Je,()=>c&&l&&d&&T&&E&&C&&A&&N&&H&&W&&ie&&Oe&&Ie&&Qe,function($){Xr[$?"unshift":"push"]((()=>{a=$,r(0,a)}))}]}pc(wc,{activeFeatureToggleList:{type:"Array",reflect:!1,attribute:"active-feature-toggle-list"},allowRules:{type:"Array",reflect:!1,attribute:"allow-rules"},anchor:{type:"String",reflect:!1,attribute:"anchor"},authData:{type:"Object",reflect:!1,attribute:"auth-data"},clientPermissions:{type:"Object",reflect:!1,attribute:"client-permissions"},context:{type:"String",reflect:!1,attribute:"context"},deferInit:{type:"Boolean",attribute:"defer-init"},dirtyStatus:{type:"Boolean",reflect:!1,attribute:"dirty-status"},documentTitle:{type:"String",reflect:!1,attribute:"document-title"},hasBack:{type:"Boolean",reflect:!1,attribute:"has-back"},label:{type:"String",reflect:!1,attribute:"label"},locale:{type:"String",reflect:!1,attribute:"locale"},noShadow:{type:"Boolean",attribute:"no-shadow"},nodeParams:{type:"Object",reflect:!1,attribute:"node-params"},pathParams:{type:"Object",reflect:!1,attribute:"path-params"},sandboxRules:{type:"Array",reflect:!1,attribute:"sandbox-rules"},searchParams:{type:"Object",reflect:!1,attribute:"search-params"},skipCookieCheck:{type:"String",reflect:!1,attribute:"skip-cookie-check"},skipInitCheck:{type:"Boolean",reflect:!1,attribute:"skip-init-check"},theme:{type:"String",reflect:!1,attribute:"theme"},userSettings:{type:"Object",reflect:!1,attribute:"user-settings"},viewurl:{type:"String",reflect:!1,attribute:"viewurl"},webcomponent:{type:"String",reflect:!1,attribute:"webcomponent"}},[],["unwarn"],!1,(i=>{let n=r=>()=>console.warn(r+" can't be called on luigi-container before its micro frontend is attached to the DOM.");return class extends i{sendCustomMessage=n("sendCustomMessage");updateContext=n("updateContext");updateViewUrl=n("updateViewUrl");closeAlert=n("closeAlert");notifyAlertClosed=n("notifyAlertClosed");notifyConfirmationModalClosed=n("notifyConfirmationModalClosed");attributeChangedCallback(r,a,u){try{super.attributeChangedCallback(r,a,u)}catch(c){console.error("Error in super.attributeChangedCallback",c)}this.containerInitialized&&(r==="context"&&this.updateContext(JSON.parse(u)),r==="auth-data"&&ar.updateAuthData(this.iframeHandle,JSON.parse(u)))}getNoShadow(){return this.hasAttribute("no-shadow")||this.noShadow}}}));class zl extends _c{constructor(n){super(),dc(this,n,sw,iw,lc,{activeFeatureToggleList:3,anchor:4,clientPermissions:5,compoundConfig:6,context:1,deferInit:2,dirtyStatus:7,documentTitle:8,hasBack:9,locale:10,noShadow:11,nodeParams:12,pathParams:13,searchParams:14,skipInitCheck:15,theme:16,userSettings:17,viewurl:18,webcomponent:19,unwarn:20},rw)}get activeFeatureToggleList(){return this.$$.ctx[3]}set activeFeatureToggleList(n){this.$$set({activeFeatureToggleList:n}),q()}get anchor(){return this.$$.ctx[4]}set anchor(n){this.$$set({anchor:n}),q()}get clientPermissions(){return this.$$.ctx[5]}set clientPermissions(n){this.$$set({clientPermissions:n}),q()}get compoundConfig(){return this.$$.ctx[6]}set compoundConfig(n){this.$$set({compoundConfig:n}),q()}get context(){return this.$$.ctx[1]}set context(n){this.$$set({context:n}),q()}get deferInit(){return this.$$.ctx[2]}set deferInit(n){this.$$set({deferInit:n}),q()}get dirtyStatus(){return this.$$.ctx[7]}set dirtyStatus(n){this.$$set({dirtyStatus:n}),q()}get documentTitle(){return this.$$.ctx[8]}set documentTitle(n){this.$$set({documentTitle:n}),q()}get hasBack(){return this.$$.ctx[9]}set hasBack(n){this.$$set({hasBack:n}),q()}get locale(){return this.$$.ctx[10]}set locale(n){this.$$set({locale:n}),q()}get noShadow(){return this.$$.ctx[11]}set noShadow(n){this.$$set({noShadow:n}),q()}get nodeParams(){return this.$$.ctx[12]}set nodeParams(n){this.$$set({nodeParams:n}),q()}get pathParams(){return this.$$.ctx[13]}set pathParams(n){this.$$set({pathParams:n}),q()}get searchParams(){return this.$$.ctx[14]}set searchParams(n){this.$$set({searchParams:n}),q()}get skipInitCheck(){return this.$$.ctx[15]}set skipInitCheck(n){this.$$set({skipInitCheck:n}),q()}get theme(){return this.$$.ctx[16]}set theme(n){this.$$set({theme:n}),q()}get userSettings(){return this.$$.ctx[17]}set userSettings(n){this.$$set({userSettings:n}),q()}get viewurl(){return this.$$.ctx[18]}set viewurl(n){this.$$set({viewurl:n}),q()}get webcomponent(){return this.$$.ctx[19]}set webcomponent(n){this.$$set({webcomponent:n}),q()}get unwarn(){return this.$$.ctx[20]}}pc(zl,{activeFeatureToggleList:{type:"Array",reflect:!1,attribute:"active-feature-toggle-list"},anchor:{type:"String",reflect:!1,attribute:"anchor"},clientPermissions:{type:"Object",reflect:!1,attribute:"client-permissions"},compoundConfig:{type:"Object",reflect:!1,attribute:"compound-config"},context:{type:"String",reflect:!1,attribute:"context"},deferInit:{type:"Boolean",attribute:"defer-init"},dirtyStatus:{type:"Boolean",reflect:!1,attribute:"dirty-status"},documentTitle:{type:"String",reflect:!1,attribute:"document-title"},hasBack:{type:"Boolean",reflect:!1,attribute:"has-back"},locale:{type:"String",reflect:!1,attribute:"locale"},noShadow:{type:"Boolean",attribute:"no-shadow",reflect:!1},nodeParams:{type:"Object",reflect:!1,attribute:"node-params"},pathParams:{type:"Object",reflect:!1,attribute:"path-params"},searchParams:{type:"Object",reflect:!1,attribute:"search-params"},skipInitCheck:{type:"Boolean",reflect:!1,attribute:"skip-init-check"},theme:{type:"String",reflect:!1,attribute:"theme"},userSettings:{type:"Object",reflect:!1,attribute:"user-settings"},viewurl:{type:"String",reflect:!1,attribute:"viewurl"},webcomponent:{type:"String",reflect:!1,attribute:"webcomponent"}},[],["unwarn"],!1,(i=>{let n=r=>()=>console.warn(r+" can't be called on luigi-container before its micro frontend is attached to the DOM.");return class extends i{updateContext=n("updateContext");notifyAlertClosed=n("notifyAlertClosed");notifyConfirmationModalClosed=n("notifyConfirmationModalClosed");attributeChangedCallback(r,a,u){try{super.attributeChangedCallback(r,a,u)}catch(c){console.warn("Error in attributeChangedCallback",c)}this.containerInitialized&&r==="context"&&this.updateContext(JSON.parse(u))}getNoShadow(){return this.hasAttribute("no-shadow")||this.noShadow}}})),customElements.get("luigi-container")||customElements.define("luigi-container",wc.element),customElements.get("luigi-compound-container")||customElements.define("luigi-compound-container",zl.element);const O={defaultContentViewParamPrefix:"~",defaultQueryParamSeparator:"?",defaultModalViewParamName:"modal",addParamsOnHashRouting(i,n,r){let a=n;const[u,c]=a.split("?"),l=new URLSearchParams(c);return this.modifySearchParams(i,l,r),a=u,l.toString()!==""&&(a+=`?${l.toString()}`),a},modifySearchParams(i,n,r){for(const[a,u]of Object.entries(i)){const c=r?`${r}${a}`:a;n.set(c,u),u===void 0&&n.delete(c)}},filterNodeParams(i,n){const r=Object.create(null),a=this.getContentViewParamPrefix(n);return i&&Object.entries(i).forEach(u=>{if(u[0].startsWith(a)){const c=u[0].substr(a.length);r[c]=u[1]}}),this.sanitizeParamsMap(r)},mapPathToNode(i,n){if(!i||!n)return;const r=M.trimLeadingSlash(i).split("/"),a=O.buildRoute(n,`/${n.pathSegment}`),u=M.trimLeadingSlash(a).split("/");if(r.length<u.length)return;let c="";for(let l=0;l<u.length;l++){if(r[l]!==u[l]&&u[l].indexOf(":")!==0)return;c+="/"+r[l]}return c},async getNodeLabel(i,n){if(i.label&&!i._virtualTree)return n.i18n().getTranslation(i.label)||i.label;if(i.pathSegment&&i.pathSegment.indexOf(":")===0){const r=n.getConfig().routing?.useHashRouting,a=O.mapPathToNode(O.getCurrentPath(r)?.path,i)||"",u=await n.navigation().navService.extractDataFromPath(a);return O.getDynamicNodeValue(i,u.pathData.pathParams)||""}return i.pathSegment?i.pathSegment:""},getContentViewParamPrefix(i){let n=i?.getConfigValue("routing.nodeParamPrefix");return n===!1?n="":n||(n=this.defaultContentViewParamPrefix),n},sanitizeParamsMap(i){return Object.entries(i).reduce((n,r)=>(n[rs.sanitizeParam(r[0])]=rs.sanitizeParam(r[1]),n),{})},prepareSearchParamsForClient(i,n){const r={};return i&&i.clientPermissions&&i.clientPermissions.urlParameters&&Object.keys(i.clientPermissions.urlParameters).forEach(a=>{a in n.routing().getSearchParams()&&i.clientPermissions?.urlParameters&&i.clientPermissions.urlParameters[a]?.read===!0&&(r[a]=n.routing().getSearchParams()[a])}),r},getCurrentPath(i){if(i){const n=Ce.normalizePath(location.hash),[r,a]=n.split("?");return{path:r,query:a}}else return{path:Ce.normalizePath(location.pathname),query:location.search}},getModalPathFromPath(i){return this.getQueryParam(this.getModalViewParamName(i),i)},getQueryParam(i,n){return this.getQueryParams(n)[i]},getQueryParams(i){return i.getConfigValue("routing.useHashRouting")?this.getLocationHashQueryParams():this.getLocationSearchQueryParams()},getLocationSearchQueryParams(){return O.getLocation().search?O.parseParams(O.getLocation().search.slice(1)):{}},getLocation(){return location},getLocationHashQueryParams(){const i=O.getLocation().hash.indexOf(this.defaultQueryParamSeparator);return i!==-1?O.parseParams(O.getLocation().hash.slice(i+1)):{}},getModalViewParamName(i){let n=i.getConfigValue("routing.modalPathParam");return n||(n=this.defaultModalViewParamName),n},parseParams(i){const n=new URLSearchParams(i),r=new Map;for(const[a,u]of n.entries())r.set(a,u);return Object.fromEntries(r)},getModalParamsFromPath(i){const n=this.getQueryParam(`${this.getModalViewParamName(i)}Params`,i);return n&&JSON.parse(n)},getHashQueryParamSeparator(){return this.defaultQueryParamSeparator},getURLWithoutModalData(i,n){const r=new URLSearchParams(i);return r.delete(n),r.delete(`${n}Params`),r.toString()},handleHistoryState(i,n){return i&&i.modalHistoryLength?i.modalHistoryLength+=1:i={modalHistoryLength:1,historygap:history.length,pathBeforeHistory:n},i},encodeParams(i){const n=[];for(const r in i)n.push(encodeURIComponent(r)+"="+encodeURIComponent(i[r]));return n.join("&")},getLastNodeObject(i){return(i.nodesInPath?[...i.nodesInPath].pop():{})||{}},checkWCUrl(i,n){if(i.indexOf("://")>0||i.trim().indexOf("//")===0){if(new URL(i).host===window.location.host)return!0;const a=n.getConfigValue("navigation.validWebcomponentUrls");if(a?.length>0)for(const u of a)try{if(new RegExp(u).test(i))return!0}catch(c){console.error(c)}return!1}return!0},setFeatureToggles(i,n,r){const a=this.sanitizeParamsMap(this.parseParams(n.split("?")[1]));let u;if(a[i]&&(u=a[i]),!u)return;const c=u.split(",");c.length>0&&c[0]!==""&&c.forEach(l=>r?.setFeatureToggle(l,!0))},substituteDynamicParamsInObject(i,n,r=":",a=!1){return Object.entries(i).map(([u,c])=>{const l=a?Object.keys(n).find(d=>c&&c.indexOf(r+d)>=0):Object.keys(n).find(d=>c===r+d);return[u,l?a?c.replace(r+l,n[l]):n[l]:c]}).reduce((u,[c,l])=>Object.assign(u,{[c]:l}),{})},isDynamicNode(i){return typeof i.pathSegment=="string"&&i.pathSegment.length>0&&i.pathSegment[0]===":"},getDynamicNodeValue(i,n){return this.isDynamicNode(i)&&i.pathSegment?n[i.pathSegment.substring(1)]:void 0},isExistingRoute(i,n){const r=i?.split("/")||[],a=n?.nodesInPath||[],u=(l,d)=>{let p=null;if(l?.children?.length){const _=l.children.filter(R=>R.pathSegment===d);_?.length&&(p=_[0])}return p};let c=[];if(r.length>1&&a.length===1){let l;r.forEach((d,p)=>{const _=p===0?a[0]:l;l=u(_,d),l?.pathSegment&&c.push(l.pathSegment)})}else c=a.filter(l=>l.pathSegment).map(l=>l.pathSegment||"");return!i||r.length===c.length},async pathExists(i,n){const r=M.getTrimmedUrl(i),a=await n.navigation().navService.getPathData(i),u=O.isExistingRoute(r,a);return a?u:!1},showRouteNotFoundAlert(i,n=!1,r){const a={text:r.i18n().getTranslation(n?"luigi.notExactTargetNode":"luigi.requestedRouteNotFound",{route:i}),type:"error",ttl:1};r.ux().showAlert(a)},getPageNotFoundRedirectResult(i,n=!1,r){const a=r.getConfigValue("routing.pageNotFoundHandler");if(typeof a=="function"){const u=a(i,n);if(u&&(u.redirectTo||u.ignoreLuigiErrorHandling))return{path:u.redirectTo,keepURL:u.keepURL,ignoreLuigiErrorHandling:u.ignoreLuigiErrorHandling}}return{}},async handlePageNotFoundAndRetrieveRedirectPath(i,n,r){if(n)return i;const a=r.getConfigValue("routing.pageNotFoundHandler"),u=this.getPageNotFoundRedirectResult(i,a,r)?.path;if(u!==void 0)return u;this.showRouteNotFoundAlert(i,!1,r),console.warn(`Could not find the requested route: ${i}`)},async getDefaultChildNode(i,n){if(!i)return"";const r=i.nodesInPath&&i.nodesInPath[i.nodesInPath.length-1],a=i.context,u=n?await n(r,a):await $n.getConfigValueFromObjectAsync(r,"children",a),c=u.find(l=>l.pathSegment===r.defaultChildNode);if(r.defaultChildNode&&c)return r.defaultChildNode;if(u&&u.length){if(i?.nodesInPath?.length===1){const p=u.find(_=>_.pathSegment);return p&&p.pathSegment||console.error("At least one navigation node in the root hierarchy must have a pathSegment.")}const d=u.find(p=>p.pathSegment&&(p.viewUrl||p.compound||p.externalLink&&p.externalLink.url));if(d)return d.pathSegment}return""},getNodePath(i,n){return!i||n?i?this.buildRoute(i,i.pathSegment?"/"+i.pathSegment:"",n):"":`${i.parent?this.getNodePath(i.parent):""}/${i.pathSegment}`},buildRoute(i,n,r){return i.parent?this.buildRoute(i.parent,`/${i.parent.pathSegment}${n}`,r):n+(r?"?"+r:"")},substituteViewUrl(i,n,r){if(!i.viewUrl)return"";let a=i.viewUrl;return i.virtualTree&&(a=a.replace("{virtualTreePath}","")),a=M.replaceVars(a,n,":",!1),a},getSubPath(i,n){return M.replaceVars(O.getNodePath(i),n,":",!1)},concatenatePath(i,n){let r=M.getPathWithoutHashOrSlash(i);return r?(n&&(r.endsWith("/")&&(r=r.substring(0,r.length-1)),n.startsWith("/")||(r+="/"),r+=n),r):n}},Ce={normalizePath:i=>{if(!i||i.length<=0)return i;let n=i;return n.startsWith("#")&&(n=n.substring(1)),n.startsWith("/")&&(n=n.substring(1)),n},segmentMatches:(i,n,r)=>!!(i===n||n.startsWith(":")&&r&&r[n.substr(1)]===i),checkMatch:(i,n,r)=>{let a=!0;return M.trimTrailingSlash(M.trimLeadingSlash(i)).split("/").forEach((u,c)=>{a&&(c+1>=n.length||!n[c+1]?.pathSegment||!Ce.segmentMatches(u,n[c+1]?.pathSegment??"",r??{}))&&(a=!1)}),a},checkVisibleForFeatureToggles:(i,n)=>{if(i?.visibleForFeatureToggles){const r=n?.getActiveFeatureToggleList()||[];for(const a of i.visibleForFeatureToggles)if(a.startsWith("!")){if(r.includes(a.slice(1)))return!1}else if(!r.includes(a))return!1}return!0},generateTooltipText:(i,n,r)=>{let a=i?.tooltipText;switch(a===void 0&&(a=r.getConfigValue("navigation.defaults.tooltipText")),a){case void 0:return n;case!1:return"";default:return r.i18n().getTranslation(a)}},isNodeAccessPermitted:(i,n,r,a)=>{if(a.auth().isAuthorizationEnabled()){const l=Un.isLoggedIn(),d=i.anonymousAccess;if(l&&d==="exclusive"||!l&&d!=="exclusive"&&d!==!0)return!1}const u=a.featureToggles();if(!Ce.checkVisibleForFeatureToggles(i,u))return!1;const c=a.getConfigValue("navigation.nodeAccessibilityResolver");return typeof c!="function"?!0:c(i,n,r)},applyContext:(i,n,r)=>{if(n)for(let a in n)i[a]=n[a];return r&&i.parentNavigationContexts&&i.parentNavigationContexts.unshift(r),i},updateHeaderTitle:(i,n)=>{const r=i?.items;if(r&&n){let a="";return[...r].sort((u,c)=>(c.link||"").localeCompare(u.link||"")).some(u=>{let c=!1;if(c=Ce.checkMatch(u.link||"",n.nodesInPath??[]),!c&&u.selectionConditions&&u.selectionConditions.route&&(c=Ce.checkMatch(u.selectionConditions.route,n.nodesInPath??[]),c&&(u.selectionConditions.contextCriteria||[]).forEach(l=>{c=c&&n?.selectedNode?.context?.[l.key]===l.value})),c)return a=u.title||"",!0}),a}},buildPath(i,n){return i.map(a=>{const u=a.pathSegment;if(u?.startsWith(":")){const c=u.slice(1),l=n?.pathParams?.[c];if(l!=null)return encodeURIComponent(String(l))}return u}).join("/")},mergeContext(...i){return Object.assign({},...i)},prepareForTests(...i){let n="";return i.forEach(r=>{r&&(n+=(n?"_":"")+encodeURIComponent(r.toLowerCase().split(" ").join("")))}),n},findVirtualTreeRootNode(i){if(i.virtualTree)return i;if(i.parent)return Ce.findVirtualTreeRootNode(i.parent)},validatePathAndGetRedirect:async(i,n)=>{const r=await O.pathExists(i,n);return await O.handlePageNotFoundAndRetrieveRedirectPath(i,r,n)||void 0}};class _n{constructor(){this.dataManagement=new Map}setChildren(n,r){this.dataManagement.set(n,r),this.navPath=""}getChildren(n){return n?this.dataManagement.get(n):{}}hasChildren(n){const r=this.getChildren(n);return!!(r&&Object.prototype.hasOwnProperty.call(r,"children"))}setRootNode(n){this.dataManagement.set("_luigiRootNode",{node:n})}getRootNode(){return this.dataManagement.get("_luigiRootNode")}hasRootNode(){return!!this.getRootNode()}deleteCache(){this.dataManagement.clear()}deleteNodesRecursively(n){if(this.hasChildren(n)){const r=this.getChildren(n).children;for(let a=0;a<r.length;a++)this.deleteNodesRecursively(r[a])}this.dataManagement.delete(n)}}const Ua={logout:{label:"Sign Out",icon:"log"}};class aw{constructor(){this.services=new Map}register(n,r,a=!0){this.services.set(n,{factory:r,singleton:a})}get(n){const r=this.services.get(n);if(!r)throw new Error(`Service '${n}' is not registered.`);return r.singleton?(r.instance||(r.instance=r.factory()),r.instance):r.factory()}}const ne=new aw;class mn{constructor(n){this.luigi=n,this._modalStack=[],this.modalSettings={}}async closeModals(){if(this._modalStack.length===0)return;const n=[...this._modalStack];for(const{onInternalClose:r}of n)try{typeof r=="function"&&r()}catch(a){console.warn("onInternalClose threw an error",a)}this.clearModalStack()}registerModal(n){n&&this._modalStack.push(n)}getModalSettings(){return this._modalStack.length>0?this._modalStack[0].modalsettings||{}:{}}getModalStackLength(){return this._modalStack.length}updateFirstModalSettings(n){if(this._modalStack.length>0){const r=this._modalStack[0];r.modalsettings={...r.modalsettings,...n}}}clearModalStack(){this._modalStack=[]}removeLastModalFromStack(){Z.modalContainer.pop(),this._modalStack.pop()}}class vn{constructor(n){this.luigi=n,this.previousBreadcrumbs={}}getModalService(){return this.modalService||(this.modalService=ne.get(mn)),this.modalService}getNodeDataManagementService(){return this.nodeDataManagementService||(this.nodeDataManagementService=ne.get(_n)),this.nodeDataManagementService}async getPathData(n){const r=this.luigi.getConfig();let a=n.split("/");a?.length>0&&a[0]===""&&(a=a.slice(1));let c=r.navigation?.globalContext||{},l;if(this.getNodeDataManagementService().hasRootNode())l=this.getNodeDataManagementService().getRootNode().node;else{const T=await this.luigi.getConfigValueAsync("navigation.nodes");typeof T=="object"&&!Array.isArray(T)?(l=T,l.pathSegment&&(l.pathSegment="",console.warn("Root node must have an empty path segment. Provided path segment will be ignored."))):l={children:T},l.children=await this.getChildren(l,c),l.children=this.prepareRootNodes(l.children||[],c),this.getNodeDataManagementService().setRootNode(l)}const d={...c||{},...l.context||{}},p={},_={context:d,selectedNodeChildren:l.children,nodesInPath:[l],rootNodes:l.children,pathParams:p,matchedPath:""};if(l.viewUrl&&a.length===0)_.selectedNode=l;else for(const T of a)if(_.selectedNodeChildren){const E=this.findMatchingNode(T,_.selectedNodeChildren||[]);if(!E){console.warn("No matching node found for segment:",T);break}const C=E.context||{},A=Ce.mergeContext(c,C);let N=A;if(E.pathSegment?.startsWith(":")&&(p[E.pathSegment.replace(":","")]=rs.sanitizeParam(T),N=O.substituteDynamicParamsInObject(A,p)),c=N,E.context=N,_.selectedNode=E,_.selectedNode&&_.nodesInPath?.push(_.selectedNode),E.virtualTree||E._virtualTree){const H=this.buildVirtualTree(E,T,p);H&&H.length>0&&(E.children=H)}_.selectedNodeChildren=await this.getChildren(E,c)}const R=_.nodesInPath?.filter(T=>T.pathSegment).map(T=>T.pathSegment)||[];return _.matchedPath=a.filter((T,E)=>R[E]&&R[E].startsWith(":")||R[E]===T).join("/")||"",_}findMatchingNode(n,r){let a;const u=r.filter(l=>!!l.pathSegment).length,c=r.filter(l=>l.pathSegment&&l.pathSegment.startsWith(":")).length;if(u>1&&(c===1&&(console.warn(`Invalid node setup detected.
87
+ }</style> <iframe></iframe>`,1),eC=pu("<main><!></main>");function Qd(r,t){ru(t,!1);let n=ee(t,"activeFeatureToggleList"),s=ee(t,"allowRules"),a=ee(t,"anchor"),l=ee(t,"authData"),u=ee(t,"clientPermissions"),f=ee(t,"context"),h=ee(t,"deferInit"),g=ee(t,"dirtyStatus"),_=ee(t,"documentTitle"),w=ee(t,"hasBack"),m=ee(t,"label"),E=ee(t,"locale"),b=ee(t,"noShadow"),R=ee(t,"nodeParams"),I=ee(t,"pathParams"),N=ee(t,"sandboxRules"),$=ee(t,"searchParams"),J=ee(t,"skipCookieCheck"),de=ee(t,"skipInitCheck"),_e=ee(t,"theme"),pe=ee(t,"userSettings"),oe=ee(t,"viewurl"),me=ee(t,"webcomponent");const Re=Si({});let ae=Si(),ut=Si(!1),ct=Si();const jt=new Gd,W=()=>n()&&s()&&a()&&l()&&u()&&g()&&_()&&w()&&E()&&b()&&R()&&I()&&N()&&$()&&J()&&de()&&_e()&&pe(),Gn=O=>{if(!q(ut)){O.sendCustomMessage=(ne,ze)=>{pi.sendCustomMessage(ne,O.getNoShadow()?O:q(ae),!!me(),q(Re),ze)},O.updateContext=(ne,ze)=>{if(f(ne),me())(O.getNoShadow()?O:q(ae))._luigi_mfe_webcomponent.context=ne;else{const dn={...ze||{},activeFeatureToggleList:O.activeFeatureToggleList||[],currentLocale:O.locale,currentTheme:O.theme,userSettings:O.userSettings||null,cssVariables:O.cssVariables||{},anchor:O.anchor||"",drawer:O.drawer||!1,modal:O.modal||!1,viewStackSize:O.viewStackSize||0,isNavigateBack:O.isNavigateBack||!1};pi.updateContext(ne,dn,q(Re),R(),I(),$())}},O.closeAlert=(ne,ze)=>{O.notifyAlertClosed(ne,ze)},O.notifyAlertClosed=(ne,ze)=>{O.isConnected&&(me()?jt.resolveAlert(ne,ze):pi.notifyAlertClosed(ne,ze,q(Re)))},O.notifyConfirmationModalClosed=ne=>{O.isConnected&&(me()?jt.notifyConfirmationModalClosed(!!ne):pi.notifyConfirmationModalClosed(!!ne,q(Re)))},rr.registerContainer(O),jt.thisComponent=O;const Ae=ds.resolveContext(f());if(O.updateViewUrl=(ne,ze)=>{ne?.length&&pi.updateViewUrl(ne,ds.resolveContext(f()),ze,q(Re))},me()&&me()!="false"){O.getNoShadow()?O.innerHTML="":(os(ae,q(ae).innerHTML=""),O.attachShadow({mode:"open"}).append(q(ae)));const ne=ds.checkWebcomponentValue(me());jt.renderWebComponent(oe(),O.getNoShadow()?O:q(ae),Ae,typeof ne=="object"?{webcomponent:ne}:{})}else O.getNoShadow()||(O.innerHTML="",O.attachShadow({mode:"open"}).append(q(ae)));de()?(O.initialized=!0,setTimeout(()=>{jt.dispatchLuigiEvent(k.INITIALIZED,{})})):me()&&(O.getNoShadow()?O:q(ae)).addEventListener("wc_ready",()=>{(O.getNoShadow()?O:q(ae))._luigi_mfe_webcomponent?.deferLuigiClientWCInit||(O.initialized=!0,jt.dispatchLuigiEvent(k.INITIALIZED,{}))}),_t(ut,!0),O.containerInitialized=!0}};var mr;Ql(async()=>{_t(ct,q(ae).parentNode),os(ct,q(ct).iframeHandle=q(Re)),os(ct,q(ct).init=()=>{Gn(q(ct))}),!h()&&oe()&&Gn(q(ct))}),mr=async()=>{},be===null&&Jh("onDestroy"),Ql(()=>()=>Fn(mr)),(function(O,Ae){var ne={effect:null,ran:!1,deps:O};be.l.$.push(ne),ne.effect=ys(()=>{if(O(),!ne.ran){ne.ran=!0;var ze=te;try{xt(ze.parent),Fn(Ae)}finally{xt(ze)}}})})(()=>(q(ut),gi(oe()),gi(h()),q(ct)),()=>{!q(ut)&&oe()&&!h()&&q(ct)&&Gn(q(ct))}),(function(){var O=be;ys(()=>{for(var Ae of O.l.$){Ae.deps();var ne=Ae.effect;(ne.f&He)!==0&&ne.deps!==null&&Oe(ne,Cn),Fi(ne)&&qr(ne),Ae.ran=!1}})})();var wt={unwarn:W,get activeFeatureToggleList(){return n()},set activeFeatureToggleList(O){n(O),Z()},get allowRules(){return s()},set allowRules(O){s(O),Z()},get anchor(){return a()},set anchor(O){a(O),Z()},get authData(){return l()},set authData(O){l(O),Z()},get clientPermissions(){return u()},set clientPermissions(O){u(O),Z()},get context(){return f()},set context(O){f(O),Z()},get deferInit(){return h()},set deferInit(O){h(O),Z()},get dirtyStatus(){return g()},set dirtyStatus(O){g(O),Z()},get documentTitle(){return _()},set documentTitle(O){_(O),Z()},get hasBack(){return w()},set hasBack(O){w(O),Z()},get label(){return m()},set label(O){m(O),Z()},get locale(){return E()},set locale(O){E(O),Z()},get noShadow(){return b()},set noShadow(O){b(O),Z()},get nodeParams(){return R()},set nodeParams(O){R(O),Z()},get pathParams(){return I()},set pathParams(O){I(O),Z()},get sandboxRules(){return N()},set sandboxRules(O){N(O),Z()},get searchParams(){return $()},set searchParams(O){$(O),Z()},get skipCookieCheck(){return J()},set skipCookieCheck(O){J(O),Z()},get skipInitCheck(){return de()},set skipInitCheck(O){de(O),Z()},get theme(){return _e()},set theme(O){_e(O),Z()},get userSettings(){return pe()},set userSettings(O){pe(O),Z()},get viewurl(){return oe()},set viewurl(O){oe(O),Z()},get webcomponent(){return me()},set webcomponent(O){me(O),Z()}};Hd();var Xe=eC(),St=(function(O,Ae){if(!Ue)return Ni(O);var ne=Ni(Ee);return ne===null&&(ne=Ee.appendChild(Fr())),Sn(ne),ne})(Xe),Yr=O=>{var Ae=(function(){if(Ue)return Ri(Ee,null),Ee;var dn=document.createDocumentFragment(),Lt=document.createComment(""),yt=Fr();return dn.append(Lt,yt),Ri(Lt,yt),dn})(),ne=ph(Ae),ze=dn=>{var Lt=ZE(),yt=(function(wr,Rn=1,Sr=!1){let Nt=Ue?Ee:wr;for(var yr;Rn--;)yr=Nt,Nt=Wn(Nt);if(!Ue)return Nt;if(Sr){if(Nt?.nodeType!==3){var An=Fr();return Nt===null?yr?.after(An):Nt.before(An),Sn(An),An}wd(Nt)}return Sn(Nt),Nt})(ph(Lt),2);ql(yt,wr=>os(Re,q(Re).iframe=wr),()=>q(Re)?.iframe),vh((wr,Rn)=>{Aa(yt,"src",oe()),Aa(yt,"title",m()),Aa(yt,"allow",wr),Aa(yt,"sandbox",Rn)},[()=>(gi(Ah),gi(s()),Fn(()=>Ah(s()))),()=>(gi(N()),Fn(()=>N()?N().join(" "):void 0))]),hs(dn,Lt)};Ch(ne,dn=>{me()&&me()!=="false"||dn(ze)}),hs(O,Ae)};return Ch(St,O=>{q(ut)&&O(Yr)}),(function(O){if(Ue){if(Wn(Ee)!==null)throw ja(),Pi;Ee=O}})(Xe),ql(Xe,O=>_t(ae,O),()=>q(ae)),vh(()=>QE(Xe,1,GE(me()?void 0:"lui-isolated"))),hs(r,Xe),Fd(t,"unwarn",W),iu(wt)}Wd(Qd,{activeFeatureToggleList:{attribute:"active-feature-toggle-list",type:"Array"},allowRules:{attribute:"allow-rules",type:"Array"},anchor:{attribute:"anchor",type:"String"},authData:{attribute:"auth-data",type:"Object"},clientPermissions:{attribute:"client-permissions",type:"Object"},context:{attribute:"context",type:"String"},deferInit:{attribute:"defer-init",type:"Boolean"},dirtyStatus:{attribute:"dirty-status",type:"Boolean"},documentTitle:{attribute:"document-title",type:"String"},hasBack:{attribute:"has-back",type:"Boolean"},label:{attribute:"label",type:"String"},locale:{attribute:"locale",type:"String"},noShadow:{attribute:"no-shadow",type:"Boolean"},nodeParams:{attribute:"node-params",type:"Object"},pathParams:{attribute:"path-params",type:"Object"},sandboxRules:{attribute:"sandbox-rules",type:"Array"},searchParams:{attribute:"search-params",type:"Object"},skipCookieCheck:{attribute:"skip-cookie-check",type:"String"},skipInitCheck:{attribute:"skip-init-check",type:"Boolean"},theme:{attribute:"theme",type:"String"},userSettings:{attribute:"user-settings",type:"Object"},viewurl:{attribute:"viewurl",type:"String"},webcomponent:{attribute:"webcomponent",type:"String"}},[],["unwarn"],void 0,r=>{let t=n=>()=>console.warn(n+" can't be called on luigi-container before its micro frontend is attached to the DOM.");return class extends r{sendCustomMessage=t("sendCustomMessage");updateContext=t("updateContext");updateViewUrl=t("updateViewUrl");closeAlert=t("closeAlert");notifyAlertClosed=t("notifyAlertClosed");notifyConfirmationModalClosed=t("notifyConfirmationModalClosed");attributeChangedCallback(n,s,a){try{super.attributeChangedCallback(n,s,a)}catch(l){console.error("Error in super.attributeChangedCallback",l)}this.containerInitialized&&(n==="context"&&this.updateContext(JSON.parse(a)),n==="auth-data"&&pi.updateAuthData(this.iframeHandle,JSON.parse(a)))}getNoShadow(){return this.hasAttribute("no-shadow")||this.noShadow}}});var tC=pu('<main class="svelte-1yfh4yd"></main>');const nC={hash:"svelte-1yfh4yd",code:"main.svelte-1yfh4yd {width:100%;height:100%;border:none;}"};function xh(r,t){ru(t,!1),BE(r,nC);let n,s=ee(t,"activeFeatureToggleList"),a=ee(t,"anchor"),l=ee(t,"clientPermissions"),u=ee(t,"compoundConfig"),f=ee(t,"context"),h=ee(t,"deferInit"),g=ee(t,"dirtyStatus"),_=ee(t,"documentTitle"),w=ee(t,"hasBack"),m=ee(t,"locale"),E=ee(t,"noShadow"),b=ee(t,"nodeParams"),R=ee(t,"pathParams"),I=ee(t,"searchParams"),N=ee(t,"skipInitCheck"),$=ee(t,"theme"),J=ee(t,"userSettings"),de=ee(t,"viewurl"),_e=ee(t,"webcomponent"),pe=!1,oe=Si();const me=new vu,Re=new Gd,ae=()=>s()&&a()&&l()&&g()&&_()&&w()&&m()&&E()&&b()&&R()&&I()&&N()&&$()&&J(),ut=W=>{if(!u()||pe)return;W.updateContext=(wt,Xe)=>{const St=W.getNoShadow()?W:q(oe);St._luigi_mfe_webcomponent.context=wt,f(wt);const Yr=St._luigi_mfe_webcomponent;Yr&&Yr.querySelectorAll("[lui_web_component]")?.forEach(Ae=>{const ne=Ae.context||{};Ae.context=Object.assign(ne,wt)})};const Gn=ds.resolveContext(f());h(!1),W.notifyAlertClosed=(wt,Xe)=>{W.isConnected&&Re.resolveAlert(wt,Xe)},W.notifyConfirmationModalClosed=wt=>{W.isConnected&&Re.notifyConfirmationModalClosed(!!wt)};const mr={compound:u(),viewUrl:de(),webcomponent:ds.checkWebcomponentValue(_e())||!0};W.getNoShadow()?W.innerHTML="":(os(oe,q(oe).innerHTML=""),W.attachShadow({mode:"open"}).append(q(oe))),Re.renderWebComponentCompound(mr,W.getNoShadow()?W:q(oe),Gn).then(wt=>{n=wt,N()||!mr.viewUrl?(W.initialized=!0,setTimeout(()=>{Re.dispatchLuigiEvent(k.INITIALIZED,{})})):n.LuigiClient&&!n.deferLuigiClientWCInit&&(W.initialized=!0,Re.dispatchLuigiEvent(k.INITIALIZED,{}))}),pe=!0,W.containerInitialized=!0};Ql(async()=>{const W=q(oe).getRootNode()===document?q(oe).parentNode:q(oe).getRootNode().host;W.init=()=>{ut(W)},h()||ut(W),me.registerContainer(W),Re.thisComponent=W});var ct={unwarn:ae,get activeFeatureToggleList(){return s()},set activeFeatureToggleList(W){s(W),Z()},get anchor(){return a()},set anchor(W){a(W),Z()},get clientPermissions(){return l()},set clientPermissions(W){l(W),Z()},get compoundConfig(){return u()},set compoundConfig(W){u(W),Z()},get context(){return f()},set context(W){f(W),Z()},get deferInit(){return h()},set deferInit(W){h(W),Z()},get dirtyStatus(){return g()},set dirtyStatus(W){g(W),Z()},get documentTitle(){return _()},set documentTitle(W){_(W),Z()},get hasBack(){return w()},set hasBack(W){w(W),Z()},get locale(){return m()},set locale(W){m(W),Z()},get noShadow(){return E()},set noShadow(W){E(W),Z()},get nodeParams(){return b()},set nodeParams(W){b(W),Z()},get pathParams(){return R()},set pathParams(W){R(W),Z()},get searchParams(){return I()},set searchParams(W){I(W),Z()},get skipInitCheck(){return N()},set skipInitCheck(W){N(W),Z()},get theme(){return $()},set theme(W){$(W),Z()},get userSettings(){return J()},set userSettings(W){J(W),Z()},get viewurl(){return de()},set viewurl(W){de(W),Z()},get webcomponent(){return _e()},set webcomponent(W){_e(W),Z()}};Hd();var jt=tC();return ql(jt,W=>_t(oe,W),()=>q(oe)),hs(r,jt),Fd(t,"unwarn",ae),iu(ct)}Wd(xh,{activeFeatureToggleList:{attribute:"active-feature-toggle-list",type:"Array"},anchor:{attribute:"anchor",type:"String"},clientPermissions:{attribute:"client-permissions",type:"Object"},compoundConfig:{attribute:"compound-config",type:"Object"},context:{attribute:"context",type:"String"},deferInit:{attribute:"defer-init",type:"Boolean"},dirtyStatus:{attribute:"dirty-status",type:"Boolean"},documentTitle:{attribute:"document-title",type:"String"},hasBack:{attribute:"has-back",type:"Boolean"},locale:{attribute:"locale",type:"String"},noShadow:{attribute:"no-shadow",type:"Boolean"},nodeParams:{attribute:"node-params",type:"Object"},pathParams:{attribute:"path-params",type:"Object"},searchParams:{attribute:"search-params",type:"Object"},skipInitCheck:{attribute:"skip-init-check",type:"Boolean"},theme:{attribute:"theme",type:"String"},userSettings:{attribute:"user-settings",type:"Object"},viewurl:{attribute:"viewurl",type:"String"},webcomponent:{attribute:"webcomponent",type:"String"}},[],["unwarn"],void 0,r=>{let t=n=>()=>console.warn(n+" can't be called on luigi-container before its micro frontend is attached to the DOM.");return class extends r{updateContext=t("updateContext");notifyAlertClosed=t("notifyAlertClosed");notifyConfirmationModalClosed=t("notifyConfirmationModalClosed");attributeChangedCallback(n,s,a){try{super.attributeChangedCallback(n,s,a)}catch(l){console.warn("Error in attributeChangedCallback",l)}this.containerInitialized&&n==="context"&&this.updateContext(JSON.parse(a))}getNoShadow(){return this.hasAttribute("no-shadow")||this.noShadow}}}),customElements.get("luigi-container")||customElements.define("luigi-container",Qd.element),customElements.get("luigi-compound-container")||customElements.define("luigi-compound-container",xh.element);const Wa={sanitizeHtml(r=""){return r.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/'/g,"&#39;").replace(/javascript:/gi,"").replace(/data:/gi,"").replace(/vbscript:/gi,"")},restoreSanitizedBrs(r=""){return r.replace(/&lt;br\/&gt;/g,"<br>").replace(/&lt;br \/&gt;/g,"<br>").replace(/&lt;br&gt;/g,"<br>").replace(/&lt;br &gt;/g,"<br>")},restoreSanitizedElements(r=""){let t=r;const n=["i","b","br","mark","strong","em","small","del","ins","sub","sup"];for(let s=0;s<n.length;s++){const a=new RegExp(`&lt;${n[s]}/&gt;`,"g"),l=new RegExp(`&lt;${n[s]} /&gt;`,"g"),u=new RegExp(`&lt;${n[s]}&gt;`,"g"),f=new RegExp(`&lt;${n[s]} &gt;`,"g"),h=new RegExp(`&lt;/${n[s]}[/]&gt;`,"g"),g=new RegExp(`&lt;/${n[s]} [/]&gt;`,"g"),_=new RegExp(`&lt;[/]${n[s]}&gt;`,"g"),w=new RegExp(`&lt;[/]${n[s]} &gt;`,"g");t=t.replace(a,`<${n[s]}>`).replace(l,`<${n[s]}>`).replace(u,`<${n[s]}>`).replace(f,`<${n[s]}>`).replace(h,`</${n[s]}>`).replace(g,`</${n[s]}>`).replace(_,`</${n[s]}>`).replace(w,`</${n[s]}>`)}return t},sanatizeHtmlExceptTextFormatting(r=""){return this.restoreSanitizedElements(this.sanitizeHtml(r))},sanitizeParam(r=""){return String(r).replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/'/g,"&#39;").replace(/\//g,"&sol;")},escapeKeyForRegexp(r=""){return r.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&")},processTextAndLinks(r="",t,n){const a={sanitizedText:this.restoreSanitizedBrs(this.sanitizeHtml(r)),links:[]};return t?Object.entries(t).reduce((l,[u,f])=>{const h=`_luigi_alert_${n}_link_${this.sanitizeParam(u)}`,g=this.restoreSanitizedBrs(this.sanitizeHtml(f.text)),_=`<a id="${h}">${g}</a>`,w=this.escapeKeyForRegexp(u),m=new RegExp(`({${w}})`,"g");return{sanitizedText:l.sanitizedText.replace(m,_),links:l.links.concat({elemId:h,url:f.url?encodeURI(this.sanitizeHtml(f.url)):void 0,dismissKey:f.dismissKey?encodeURI(this.sanitizeHtml(f.dismissKey)):void 0})}},a):a}},Me={normalizePath:r=>{if(!r||r.length<=0)return r;let t=r;return t.startsWith("#")&&(t=t.substring(1)),t.startsWith("/")&&(t=t.substring(1)),t},segmentMatches:(r,t,n)=>!!(r===t||t.startsWith(":")&&n&&n[t.substr(1)]===r),checkMatch:(r,t,n)=>{let s=!0;return M.trimTrailingSlash(M.trimLeadingSlash(r)).split("/").forEach((a,l)=>{s&&(l+1>=t.length||!t[l+1]?.pathSegment||!Me.segmentMatches(a,t[l+1]?.pathSegment??"",n??{}))&&(s=!1)}),s},checkVisibleForFeatureToggles:(r,t)=>{if(r?.visibleForFeatureToggles){const n=t?.getActiveFeatureToggleList()||[];for(const s of r.visibleForFeatureToggles)if(s.startsWith("!")){if(n.includes(s.slice(1)))return!1}else if(!n.includes(s))return!1}return!0},generateTooltipText:(r,t,n)=>{let s=r?.tooltipText;switch(s===void 0&&(s=n.getConfigValue("navigation.defaults.tooltipText")),s){case void 0:return t;case!1:return"";default:return n.i18n().getTranslation(s)}},isNodeAccessPermitted:(r,t,n,s)=>{if(s.auth().isAuthorizationEnabled()){const u=ir.isLoggedIn(),f=r.anonymousAccess;if(u&&f==="exclusive"||!u&&f!=="exclusive"&&f!==!0)return!1}const a=s.featureToggles();if(!Me.checkVisibleForFeatureToggles(r,a))return!1;const l=s.getConfigValue("navigation.nodeAccessibilityResolver");return typeof l!="function"?!0:l(r,t,n)},updateHeaderTitle:(r,t)=>{const n=r?.items;if(n&&t){let s="";return[...n].sort((a,l)=>(l.link||"").localeCompare(a.link||"")).some(a=>{let l=!1;if(l=Me.checkMatch(a.link||"",t.nodesInPath??[]),!l&&a.selectionConditions&&a.selectionConditions.route&&(l=Me.checkMatch(a.selectionConditions.route,t.nodesInPath??[]),l&&(a.selectionConditions.contextCriteria||[]).forEach(u=>{l=l&&t?.selectedNode?.context?.[u.key]===u.value})),l)return s=a.title||"",!0}),s}},buildPath(r,t){return r.map(s=>{const a=s.pathSegment;if(a?.startsWith(":")){const l=a.slice(1),u=t?.pathParams?.[l];if(u!=null)return encodeURIComponent(String(u))}return a}).join("/")},mergeContext(r,t,n){const s=[...r.parentNavigationContexts||[]];return n&&s.unshift(n),{...r,...t||{},parentNavigationContexts:s}},prepareForTests(...r){let t="";return r.forEach(n=>{n&&(t+=(t?"_":"")+encodeURIComponent(n.toLowerCase().split(" ").join("")))}),t},findVirtualTreeRootNode(r){if(r.virtualTree)return r;if(r.parent)return Me.findVirtualTreeRootNode(r.parent)},validatePathAndGetRedirect:async(r,t)=>{const n=await D.pathExists(r,t);return await D.handlePageNotFoundAndRetrieveRedirectPath(r,n,t)||void 0},async fetchNodeTitleData(r,t){return new Promise((n,s)=>{if(!r.titleResolver){s(new Error("No title resolver defined at node"));return}const a={...r.titleResolver};delete a._cache;const l=this.substituteVars(a,t),u=JSON.stringify(l);if(r.titleResolver._cache&&r.titleResolver._cache.key===u){n(r.titleResolver._cache.value);return}const f=l.request;this._fetch(f.url,{method:f.method,headers:f.headers,body:JSON.stringify(f.body)}).then(h=>{h.json().then(g=>{try{const _=this.processTitleData(g,l);r.titleResolver._cache={key:u,value:_},n(_)}catch(_){s(_)}})}).catch(h=>{s(h)})})},getPropertyChainValue(r,t,n){return!t||!r?n:Ul.get(r,t,n)},substituteVars(r,t){const s=JSON.stringify(r).replace(/\$\{[a-zA-Z0-9$_.]+\}/g,a=>{const l=a.substr(2,a.length-3);return this.getPropertyChainValue(t,l)||a});return JSON.parse(s)},_fetch(r,t){return fetch(r,t)},processTitleData(r,t){let n=this.getPropertyChainValue(r,t.titlePropertyChain);return n&&(n=n.trim()),n&&t.titleDecorator&&(n=t.titleDecorator.replace("%s",n)),{label:n||t.fallbackTitle,icon:this.getPropertyChainValue(r,t.iconPropertyChain,t.fallbackIcon)}},openExternalLink(r,t){let n=r.url;if(t&&(n=M.replaceVars(n,t,":",!1)),r.sameWindow)window.location.href=n;else{const s=window.open(n,"_blank","noopener noreferrer");s&&(s.opener=null,s.focus())}}},D={defaultContentViewParamPrefix:"~",defaultQueryParamSeparator:"?",defaultModalViewParamName:"modal",addParamsOnHashRouting(r,t,n){let s=t;const[a,l]=s.split("?"),u=new URLSearchParams(l);return this.modifySearchParams(r,u,n),s=a,u.toString()!==""&&(s+=`?${u.toString()}`),s},modifySearchParams(r,t,n){for(const[s,a]of Object.entries(r)){const l=n?`${n}${s}`:s;t.set(l,a),a===void 0&&t.delete(l)}},filterNodeParams(r,t){const n=Object.create(null),s=this.getContentViewParamPrefix(t);return r&&Object.entries(r).forEach(a=>{if(a[0].startsWith(s)){const l=a[0].substr(s.length);n[l]=a[1]}}),this.sanitizeParamsMap(n)},mapPathToNode(r,t){if(!r||!t)return;const n=M.trimLeadingSlash(r).split("/"),s=D.buildRoute(t,`/${t.pathSegment}`),a=M.trimLeadingSlash(s).split("/");if(n.length<a.length)return;let l="";for(let u=0;u<a.length;u++){if(n[u]!==a[u]&&a[u].indexOf(":")!==0)return;l+="/"+n[u]}return l},async getNodeLabel(r,t){if(r.label&&!r._virtualTree)return t.i18n().getTranslation(r.label)||r.label;if(r.pathSegment&&r.pathSegment.indexOf(":")===0){const n=t.getConfig().routing?.useHashRouting,s=D.mapPathToNode(D.getCurrentPath(t,n)?.path,r)||"",a=await t.navigation().navService.extractDataFromPath(s);return D.getDynamicNodeValue(r,a.pathData.pathParams)||""}return r.pathSegment?r.pathSegment:""},getContentViewParamPrefix(r){let t=r?.getConfigValue("routing.nodeParamPrefix");return t===!1?t="":t||(t=this.defaultContentViewParamPrefix),t},sanitizeParamsMap(r){return Object.entries(r).reduce((t,n)=>(t[Wa.sanitizeParam(n[0])]=Wa.sanitizeParam(n[1]),t),{})},prepareSearchParamsForClient(r,t){const n={};return r&&r.clientPermissions&&r.clientPermissions.urlParameters&&Object.keys(r.clientPermissions.urlParameters).forEach(s=>{s in t.routing().getSearchParams()&&r.clientPermissions?.urlParameters&&r.clientPermissions.urlParameters[s]?.read===!0&&(n[s]=t.routing().getSearchParams()[s])}),n},hasIntent(r){return!!r&&r.toLowerCase().includes("#?intent=")},getIntentObject(r){const t=r.split("?intent=")[1];if(t){const n=t.split("?"),s=n[0].split("-"),a=Object.fromEntries(new URLSearchParams(n[1]).entries());return{semanticObject:s[0],action:s[1],params:a}}},getIntentPath(r,t){const n=t.getConfigValue("navigation.intentMapping");if(n&&n.length>0){const s=r.replace(/\?intent=/i,"?intent="),a=this.getIntentObject(s);if(a){let l=n.find(f=>f.semanticObject===a.semanticObject&&f.action===a.action);if(!l)return!1;if(l.externalLink)return{...l.externalLink,external:!0};l=l.pathSegment;const u=Object.entries(a.params);if(u&&u.length>0){l=this.resolveDynamicIntentPath(l,a.params);let f=t.getConfigValue("routing.nodeParamPrefix");f=f||"~",l=l.concat(`?${f}`),u.forEach(([h,g],_)=>{l+=`${_>0?"&"+f:""}${h}=${g}`})}return l}else console.warn("Could not parse given intent link.")}else console.warn("No intent mappings are defined in Luigi configuration.");return!1},resolveDynamicIntentPath(r,t){if(!t)return r;let n=r;for(const[s,a]of Object.entries(t)){const l=new RegExp("/:"+s+"(/|$)","g");n=n.replace(l,`/${a}/`)}return n=n.replace(/\/$/,""),n},getCurrentPath(r,t,n){if(n&&/\?intent=/i.test(location.hash)){const s=location.hash.replace("#/#","").replace("#",""),a=D.getIntentPath(s,r);if(a){if(typeof a=="string")return r?.getConfigValue("routing.replaceIntentRoute")&&history.replaceState(window.state,"",a),{path:a,query:location.search};if(M.isObject(a))return D.handleExternalIntentPath(a),{path:t?location.hash:location.pathname,query:""}}}if(t){const s=Me.normalizePath(location.hash),[a,l]=s.split("?");return{path:a.replace("#",""),query:l}}else return{path:Me.normalizePath(location.pathname),query:location.search}},handleExternalIntentPath(r){if(r.external&&r.url){const t=r.openInNewTab?"_blank":"_self";window.open(r.url,t,"noopener,noreferrer")?.focus()}},getModalPathFromPath(r){return this.getQueryParam(this.getModalViewParamName(r),r)},getQueryParam(r,t){return this.getQueryParams(t)[r]},getQueryParams(r){return r.getConfigValue("routing.useHashRouting")?this.getLocationHashQueryParams():this.getLocationSearchQueryParams()},getLocationSearchQueryParams(){return D.getLocation().search?D.parseParams(D.getLocation().search.slice(1)):{}},getLocation(){return location},getLocationHashQueryParams(){const r=D.getLocation().hash.indexOf(this.defaultQueryParamSeparator);return r!==-1?D.parseParams(D.getLocation().hash.slice(r+1)):{}},getModalViewParamName(r){let t=r.getConfigValue("routing.modalPathParam");return t||(t=this.defaultModalViewParamName),t},parseParams(r){const t=new URLSearchParams(r),n=new Map;for(const[s,a]of t.entries())n.set(s,a);return Object.fromEntries(n)},getModalParamsFromPath(r){const t=this.getQueryParam(`${this.getModalViewParamName(r)}Params`,r);return t&&JSON.parse(t)},getHashQueryParamSeparator(){return this.defaultQueryParamSeparator},getURLWithoutModalData(r,t){const n=new URLSearchParams(r);return n.delete(t),n.delete(`${t}Params`),n.toString()},handleHistoryState(r,t){return r&&r.modalHistoryLength?r.modalHistoryLength+=1:r={modalHistoryLength:1,historygap:history.length,pathBeforeHistory:t},r},encodeParams(r){const t=[];for(const n in r)t.push(encodeURIComponent(n)+"="+encodeURIComponent(r[n]));return t.join("&")},getLastNodeObject(r){return(r.nodesInPath?[...r.nodesInPath].pop():{})||{}},checkWCUrl(r,t){if(r.indexOf("://")>0||r.trim().indexOf("//")===0){if(new URL(r).host===window.location.host)return!0;const s=t.getConfigValue("navigation.validWebcomponentUrls");if(s?.length>0)for(const a of s)try{if(new RegExp(a).test(r))return!0}catch(l){console.error(l)}return!1}return!0},setFeatureToggles(r,t,n){const s=this.sanitizeParamsMap(this.parseParams(t.split("?")[1]));let a;if(s[r]&&(a=s[r]),!a)return;const l=a.split(",");l.length>0&&l[0]!==""&&l.forEach(u=>n?.setFeatureToggle(u,!0))},substituteDynamicParamsInObject(r,t,n=":",s=!1){return Object.entries(r).map(([a,l])=>{const u=s?Object.keys(t).find(f=>l&&l.indexOf(n+f)>=0):Object.keys(t).find(f=>l===n+f);return[a,u?s?l.replace(n+u,t[u]):t[u]:l]}).reduce((a,[l,u])=>Object.assign(a,{[l]:u}),{})},isDynamicNode(r){return typeof r.pathSegment=="string"&&r.pathSegment.length>0&&r.pathSegment[0]===":"},getDynamicNodeValue(r,t){return this.isDynamicNode(r)&&r.pathSegment?t[r.pathSegment.substring(1)]:void 0},isExistingRoute(r,t){const n=r?.split("/")||[],s=t?.nodesInPath||[],a=(u,f)=>{let h=null;if(u?.children?.length){const g=u.children.filter(_=>_.pathSegment===f);g?.length&&(h=g[0])}return h};let l=[];if(n.length>1&&s.length===1){let u;n.forEach((f,h)=>{const g=h===0?s[0]:u;u=a(g,f),u?.pathSegment&&l.push(u.pathSegment)})}else l=s.filter(u=>u.pathSegment).map(u=>u.pathSegment||"");return!r||n.length===l.length},async pathExists(r,t){const n=M.getTrimmedUrl(r),s=await t.navigation().navService.getPathData(r),a=D.isExistingRoute(n,s);return s?a:!1},showRouteNotFoundAlert(r,t=!1,n){const s={text:n.i18n().getTranslation(t?"luigi.notExactTargetNode":"luigi.requestedRouteNotFound",{route:r}),type:"error",ttl:1};n.ux().showAlert(s)},getPageNotFoundRedirectResult(r,t=!1,n){const s=n.getConfigValue("routing.pageNotFoundHandler");if(typeof s=="function"){const a=s(r,t);if(a&&(a.redirectTo||a.ignoreLuigiErrorHandling))return{path:a.redirectTo,keepURL:a.keepURL,ignoreLuigiErrorHandling:a.ignoreLuigiErrorHandling}}return{}},async handlePageNotFoundAndRetrieveRedirectPath(r,t,n){if(t)return r;const s=n.getConfigValue("routing.pageNotFoundHandler"),a=this.getPageNotFoundRedirectResult(r,s,n)?.path;if(a!==void 0)return a;this.showRouteNotFoundAlert(r,!1,n),console.warn(`Could not find the requested route: ${r}`)},async getDefaultChildNode(r,t){if(!r)return"";const n=r.nodesInPath&&r.nodesInPath[r.nodesInPath.length-1],s=r.context,a=t?await t(n,s):await kr.getConfigValueFromObjectAsync(n,"children",s),l=a.find(u=>u.pathSegment===n.defaultChildNode);if(n.defaultChildNode&&l)return n.defaultChildNode;if(a&&a.length){if(r?.nodesInPath?.length===1){const h=a.find(g=>g.pathSegment);return h&&h.pathSegment||console.error("At least one navigation node in the root hierarchy must have a pathSegment.")}const f=a.find(h=>h.pathSegment&&(h.viewUrl||h.compound||h.externalLink&&h.externalLink.url));if(f)return f.pathSegment}return""},getNodePath(r,t){return!r||t?r?this.buildRoute(r,r.pathSegment?"/"+r.pathSegment:"",t):"":`${r.parent?this.getNodePath(r.parent):""}/${r.pathSegment}`},buildRoute(r,t,n){return r.parent?this.buildRoute(r.parent,`/${r.parent.pathSegment}${t}`,n):t+(n?"?"+n:"")},substituteViewUrl(r,t,n,s){if(!r.viewUrl)return"";let a=r.viewUrl;const l="context.",u="nodeParams.",f="routing.queryParams";if(r.virtualTree&&(a=a.replace("{virtualTreePath}","")),a=M.replaceVars(a,t,":",!1),r.context&&(a=M.replaceVars(a,r.context,l)),a=M.replaceVars(a,n,u),a=this.getI18nViewUrl(a,s),a&&a.includes(f)){const h=a.split("?")[1];if(h){const g=h.split("=")[0],_=s.routing().getSearchParams();_[g]?a=a.replace(`{${f}.${g}}`,_[g]):a=a.replace(`?${g}={${f}.${g}}`,"")}}return a},getI18nViewUrl(r,t){const n="{i18n.currentLocale}",s=t.i18n().getCurrentLocale();return r&&r.includes(n)?r.replace(n,s):r},getSubPath(r,t){return M.replaceVars(D.getNodePath(r),t,":",!1)},concatenatePath(r,t){let n=M.getPathWithoutHashOrSlash(r);return n?(!t||typeof t!="string"||(n.endsWith("/")&&(n=n.substring(0,n.length-1)),t.startsWith("/")||(n+="/"),n+=t),n):t},getRouteLink(r,t,n){const s=n||"";if(r.externalLink&&r.externalLink.url)return r.externalLink.url;if(r.link)return s+r.link;const a=D.buildRoute(r,`/${r.pathSegment}`);return s+M.replaceVars(a,t,":",!1,!0)},calculateNodeHref(r,t,n){const a=n.getConfigValue("routing.useHashRouting")?"#":"",l=D.getRouteLink(r,t,a);return D.getI18nViewUrl(l,n)||l},getNodeHref(r,t,n){if(M.getConfigBooleanValue(n.getConfig(),"navigation.addNavHrefs"))return D.calculateNodeHref(r,t,n)}},Qe={_fallbackLabels:new Map,resetFallbackLabelCache(){Qe._fallbackLabels.clear()},getPreparedParentNodePath(r){return(!r.parentNodePath||!r.parentNodePath.startsWith("/"))&&console.error("Luigi Config Error: navigation.contextSwitcher.parentNodePath must be defined as an absolute path."),r.parentNodePath?M.addTrailingSlash(r.parentNodePath):r.parentNodePath},generateSwitcherNav(r,t){const n=Qe.getPreparedParentNodePath(r);return t.map(s=>({label:s.label,link:(n||"/")+s.pathValue,id:s.pathValue,testId:s.testId,customRendererCategory:s.customRendererCategory}))},getNodePathFromCurrentPath(r,t,n){const s=n.getConfig().routing?.useHashRouting,a=M.addLeadingSlash(D.getCurrentPath(n,s)?.path),l=M.addLeadingSlash(t.link);return a.startsWith(l)?r.link+M.addLeadingSlash(a.substring(l.length)):r.link},getOptionById(r,t){return r.find(n=>n.id===t)},getLabelFromOptions(r,t){const n=r.find(s=>s.id===t);return n&&n.label},isContextSwitcherDetailsView(r,t){const n=M.normalizePath(r),s=M.normalizePath(t);return!!(t&&n&&typeof n=="string"&&n.startsWith(s)&&n!==s)},async getFallbackLabel(r,t,n){if(!r)return t;const s=M.getConfigBooleanValue(n.getConfig(),"navigation.contextSwitcher.useFallbackLabelCache"),a=Qe._fallbackLabels;if(s&&a.has(t))return a.get(t);const l=await r(t);return s&&a.set(t,l),l},getSelectedId(r,t,n){if(r=M.normalizePath(r),n=M.normalizePath(n),!!Qe.isContextSwitcherDetailsView(r,n))return r.replace(n,"").split("/")[0].split("?")[0]},getSelectedOption(r,t,n){const s=Qe.getSelectedId(r,t,n);let a;return s&&t&&(a=Qe.getOptionById(t,s)),a},async getSelectedLabel(r,t,n,s,a){const l=Qe.getSelectedId(r,t,n);if(!l)return;const u=Qe.getSelectedOption(r,t,n);return(u?u.label:void 0)||await Qe.getFallbackLabel(s,l,a)},getSelectedNode(r,t,n){if(!Qe.getSelectedId(r,t,n))return;const a=Qe.getSelectedOption(r,t,n);return a?a.link:void 0},async fetchOptions(r,t=[]){const n=r.getConfigValue("navigation.contextSwitcher");if(!n.lazyloadOptions&&t.length)return t;const s=await r.getConfigValueAsync("navigation.contextSwitcher.options");return await Qe.generateSwitcherNav(n,s)}},Pa={logout:{label:"Sign Out",icon:"log"},userSettingsProfileMenuEntry:{label:"Settings",icon:"settings"}};class un{constructor(t){this.luigi=t,this.luigi=t,this.unsavedChanges={isDirty:!1,persistUrl:null}}updateDirtyStatus(t,n){if(!this.unsavedChanges.dirtySet||!(this.unsavedChanges.dirtySet instanceof Set)){const s=new Set;s.add(n),this.unsavedChanges={dirtySet:s}}this.unsavedChanges.persistUrl=window.location.href,t?this.unsavedChanges.dirtySet?.add(n):this.unsavedChanges.dirtySet?.delete(n)}clearDirtyState(t){this.unsavedChanges&&this.unsavedChanges.dirtySet&&(t?this.unsavedChanges.dirtySet.delete(t):this.unsavedChanges.dirtySet.clear())}readDirtyStatus(){return this.unsavedChanges.dirtySet?this.unsavedChanges.dirtySet.size>0:!!this.unsavedChanges.isDirty}getUnsavedChangesModalPromise(t){if(!this.shouldShowUnsavedChangesModal(t))return Promise.resolve();const n=this.luigi.getConfigValue("settings.unsavedChangesHandler");if(n)return n().then(()=>this.clearDirtyState(t));const s={header:this.luigi.i18n().getTranslation("luigi.unsavedChangesAlert.header"),body:this.luigi.i18n().getTranslation("luigi.unsavedChangesAlert.body"),buttonDismiss:this.luigi.i18n().getTranslation("luigi.button.dismiss"),buttonConfirm:this.luigi.i18n().getTranslation("luigi.button.confirm")};return new Promise((a,l)=>{this.luigi.getEngine()._connector?.renderConfirmationModal(s,{confirm:()=>{this.clearDirtyState(t),a()},dismiss:()=>{l()}})})}shouldShowUnsavedChangesModal(t){return t?this.unsavedChanges.dirtySet?.has(t)??!1:this.readDirtyStatus()}}class rC{constructor(){this.services=new Map}register(t,n,s=!0){this.services.set(t,{factory:n,singleton:s})}get(t){const n=this.services.get(t);if(!n)throw new Error(`Service '${t}' is not registered.`);return n.singleton?(n.instance||(n.instance=n.factory()),n.instance):n.factory()}}const j=new rC;class fr{constructor(t){this.luigi=t,this._modalStack=[],this.modalSettings={}}async closeModals(){if(this._modalStack.length===0)return;const t=[...this._modalStack];for(const{onInternalClose:n}of t)try{typeof n=="function"&&n()}catch(s){console.warn("onInternalClose threw an error",s)}this.clearModalStack()}registerModal(t){t&&this._modalStack.push(t)}getModalSettings(){return this._modalStack.length>0?this._modalStack[0].modalsettings||{}:{}}getModalStackLength(){return this._modalStack.length}updateFirstModalSettings(t){if(this._modalStack.length>0){const n=this._modalStack[0];n.modalsettings={...n.modalsettings,...t}}}clearModalStack(){this._modalStack=[]}removeLastModalFromStack(){G.modalContainer.pop(),this._modalStack.pop()}async closeModalsWithDirtyCheck(){const t=j.get(un);for(const n of G.modalContainer)if(t.shouldShowUnsavedChangesModal(n))try{await t.getUnsavedChangesModalPromise(n)}catch{return!1}return await this.closeModals(),!0}}class hr{constructor(){this.dataManagement=new Map}setChildren(t,n){this.dataManagement.set(t,n),this.navPath=""}getChildren(t){return t?this.dataManagement.get(t):{}}hasChildren(t){const n=this.getChildren(t);return!!(n&&Object.prototype.hasOwnProperty.call(n,"children"))}setRootNode(t){this.dataManagement.set("_luigiRootNode",{node:t})}getRootNode(){return this.dataManagement.get("_luigiRootNode")}hasRootNode(){return!!this.getRootNode()}deleteCache(){this.dataManagement.clear()}deleteNodesRecursively(t){if(this.hasChildren(t)){const n=this.getChildren(t).children;for(let s=0;s<n.length;s++)this.deleteNodesRecursively(n[s])}this.dataManagement.delete(t)}}class dr{constructor(t){this.luigi=t,this.previousBreadcrumbs={}}getModalService(){return this.modalService||(this.modalService=j.get(fr)),this.modalService}getNodeDataManagementService(){return this.nodeDataManagementService||(this.nodeDataManagementService=j.get(hr)),this.nodeDataManagementService}async getPathData(t){const n=this.luigi.getConfig();let s=t.split("/");s?.length>0&&s[0]===""&&(s=s.slice(1));let l=n.navigation?.globalContext||{},u;if(this.getNodeDataManagementService().hasRootNode())u=this.getNodeDataManagementService().getRootNode().node;else{const w=await this.luigi.getConfigValueAsync("navigation.nodes");typeof w=="object"&&!Array.isArray(w)?(u=w,u.pathSegment&&(u.pathSegment="",console.warn("Root node must have an empty path segment. Provided path segment will be ignored."))):u={children:w},u.children=await this.getChildren(u,l),u.children=this.prepareRootNodes(u.children||[],l),this.getNodeDataManagementService().setRootNode(u)}const f={parentNavigationContexts:[],...l||{},...u.context||{}},h={},g={context:f,selectedNodeChildren:u.children,nodesInPath:[u],rootNodes:u.children,pathParams:h,matchedPath:""};if(u.viewUrl&&s.length===0)g.selectedNode=u;else for(const w of s)if(g.selectedNodeChildren){const m=this.findMatchingNode(w,g.selectedNodeChildren||[]);if(!m){console.warn("No matching node found for segment:",w);break}"_rawContext"in m||(m._rawContext=m.context);const E=m._rawContext??{},b=Me.mergeContext(l,E,m.navigationContext);let R=b;if(m.pathSegment?.startsWith(":")&&(h[m.pathSegment.replace(":","")]=Wa.sanitizeParam(w),R=D.substituteDynamicParamsInObject(b,h)),l=R,m.context=R,g.selectedNode=m,g.selectedNode&&g.nodesInPath?.push(g.selectedNode),m.virtualTree||m._virtualTree){const I=this.buildVirtualTree(m,w,h);I&&I.length>0&&(m.children=I)}g.selectedNodeChildren=await this.getChildren(m,l)}const _=g.nodesInPath?.filter(w=>w.pathSegment).map(w=>w.pathSegment)||[];return g.matchedPath=s.filter((w,m)=>_[m]&&_[m].startsWith(":")||_[m]===w).join("/")||"",g}findMatchingNode(t,n){let s;const a=n.filter(u=>!!u.pathSegment).length,l=n.filter(u=>u.pathSegment&&u.pathSegment.startsWith(":")).length;if(a>1&&(l===1&&(console.warn(`Invalid node setup detected.
48
88
  Static and dynamic nodes cannot be used together on the same level. Static node gets cleaned up.
49
89
  Remove the static node from the configuration to resolve this warning.
50
- Affected pathSegment:`,n,"Children:",r),r=r.filter(l=>l.pathSegment&&l.pathSegment.startsWith(":"))),c>1)){console.error(`Invalid node setup detected.
90
+ Affected pathSegment:`,t,"Children:",n),n=n.filter(u=>u.pathSegment&&u.pathSegment.startsWith(":"))),l>1)){console.error(`Invalid node setup detected.
51
91
  Multiple dynamic nodes are not allowed on the same level. Stopped navigation.
52
- Invalid Children:`,r);return}return r.some(l=>{if(l.pathSegment===n||l.pathSegment&&l.pathSegment.startsWith(":"))return a=l,!0}),a}buildNavItems(n,r,a){const u={},c=[];return n?.forEach(l=>{if(Ce.isNodeAccessPermitted(l,this.getParentNode(a.selectedNode,a),a?.selectedNode?.context||{},this.luigi))if(l.category){const d=l.category.id||l.category.label||l.category,p=this.luigi.i18n().getTranslation(l.category.label||l.category.id||l.category);let _=u[d];_||(_={category:{altText:l.category.altText||"",icon:l.category.icon,id:d,label:p,nodes:[],tooltip:this.resolveTooltipText(l.category,p)}},u[d]=_,c.push(_)),_.category?.nodes?.push({node:l,selected:l===r,label:l.label?this.luigi.i18n().getTranslation(l.label):void 0,tooltip:l.label?this.resolveTooltipText(l,l.label):void 0,altText:l.altText,icon:l.icon})}else c.push({altText:l.altText,icon:l.icon,label:l.label?this.luigi.i18n().getTranslation(l.label):void 0,tooltip:l.label?this.resolveTooltipText(l,l.label):void 0,node:l,selected:l===r})}),c}async getCurrentNode(n){const r=await this.getPathData(n);let a=r.selectedNode;if(!a&&r.nodesInPath?.length===1&&(a=r.nodesInPath[0]),!(!a||!Ce.isNodeAccessPermitted(a,this.getParentNode(r.selectedNode,r),r?.selectedNode?.context||{},this.luigi)))return a}async getPathParams(n){return(await this.getPathData(n)).pathParams}getTruncatedChildren(n){let r=!1,a=!1,u=[];return n.slice().reverse().forEach(c=>{(!r||c.tabNav)&&(c.tabNav===!1&&(a=!0),c.keepSelectedForChildren===!1?r=!0:(c.keepSelectedForChildren||c.tabNav&&!a)&&(r=!0,u=[])),u.push(c)}),u.reverse()}applyNavGroups(n){const r={},a=[],c=[];return n.forEach(l=>{if(l.node)c.push(l);else if(l.category){const d=l.category.id;d&&d.indexOf("::")>0?a.push(l):(l.category.isGroup,r[d]=l,c.push(l))}}),a.forEach(l=>{const d=l.category?.id.split("::")[0]||"",p=r[d];p&&p.category&&(p.category.isGroup||(p.category.isGroup=!0),p.category.nodes||(p.category.nodes=[]),p.category.nodes.push(l))}),c.filter(l=>{if(l.category?.isGroup&&l.category?.nodes&&l.category?.nodes.length>0){for(let d=0;d<l.category?.nodes.length;d++){const p=l.category?.nodes[d];if(p.node&&!p.node.hideFromNav&&p.node.label||p.category?.nodes&&p.category.nodes.filter(_=>!_.node?.hideFromNav&&_.node?.label).length>0)return!0}return!1}return!0})}async getLeftNavData(n,r){const a=r??await this.getPathData(n);if(n===""&&a?.nodesInPath?.[0].viewUrl)return{items:[],basePath:"",selectedNode:{},navClick:void 0};let u=[];const c=[];let l="";a.nodesInPath?.forEach(C=>{C.children&&(C.tabNav||(l+="/"+(C.pathSegment||"")),c.push(C))});const d=this.getTruncatedChildren(a.nodesInPath??[]);let p=[...d].pop(),_=a.selectedNode;(p?.keepSelectedForChildren||p?.tabNav)&&(_=p,d.pop(),p=[...d].pop());let R,T=_;_?a.rootNodes.includes(_)?(R=_,T=void 0):_.tabNav||_.keepSelectedForChildren?R=p:R=[...c].pop():(R=[...c].pop(),T=void 0);let E=await this.getChildren(R,R?.context||{})||[];return u=this.buildNavItems(E,T,a),u=this.applyNavGroups(u),{selectedNode:_||{},items:u,basePath:l.replace(/\/\/+/g,"/"),sideNavFooterText:this.luigi.getConfig().settings?.sideNavFooterText,navClick:C=>C.node&&this.navItemClick(C.node,a)}}navItemClick(n,r){let a=O.getNodePath(n),u=r?.pathParams;if(a=M.replaceVars(a,u||{},":",!1),!a&&a!==""){console.error("Navigation error: could not build path for the node. Check if pathSegment is defined for all nodes in the path and if there are no duplicate pathSegments on the same level.");return}this.luigi.navigation().navigate(a)}async getTopNavData(n,r){const a=this.luigi.getConfig(),u=r??await this.getPathData(n),c=a.navigation?.profile?.items?.length?JSON.parse(JSON.stringify(a.navigation.profile.items)):[],l=a.navigation?.appSwitcher&&this.getAppSwitcherData(a.navigation?.appSwitcher,a.settings?.header),d=Ce.updateHeaderTitle(l,u);c?.length&&c.map(C=>({...C,label:this.luigi.i18n().getTranslation(C.label||"")}));const p=this.luigi.i18n().getTranslation(a.navigation?.profile?.logout?.label)||Ua.logout.label,_=C=>{if(C.openNodeInModal&&!C.externalLink?.url)this.luigi.navigation().openAsModal(C.link||"",C.openNodeInModal===!0?{}:C.openNodeInModal);else if(C.link)this.luigi.navigation().navigate(C.link);else if(C.externalLink?.url)if(C.externalLink.sameWindow)window.location.href=C.externalLink.url;else{const A=window.open(C.externalLink.url,"_blank","noopener noreferrer");A&&(A.opener=null,A.focus())}},R={authEnabled:this.luigi.auth().isAuthorizationEnabled(),signedIn:this.luigi.auth().isAuthorizationEnabled()&&Un.isLoggedIn(),items:c,itemClick:_,logout:{altText:this.luigi.i18n().getTranslation(a.navigation?.profile?.logout?.altText)||Ua.logout.label,label:p,icon:a.navigation?.profile?.logout?.icon||Ua.logout.icon,testId:a.navigation?.profile?.logout?.testId||Ce.prepareForTests(p),doLogout:()=>{fr.logout()}},onUserInfoUpdate:C=>{this.luigi.getConfigValueAsync("navigation.profile.staticUserInfoFn").then(A=>{A?C(A):fr.getUserInfoStore().subscribe(N=>{C(N)})})}},T=u.selectedNode,E=T&&u.rootNodes.includes(T)?T:void 0;return{appTitle:d||a.settings?.header?.title,logo:a.settings?.header?.logo,topNodes:this.buildNavItems(u.rootNodes,E,u),productSwitcher:a.navigation?.productSwitcher,profile:this.luigi.auth().isAuthorizationEnabled()||a.navigation?.profile?R:void 0,appSwitcher:a.navigation?.appSwitcher&&this.getAppSwitcherData(a.navigation?.appSwitcher,a.settings?.header),navClick:C=>C.node&&this.navItemClick(C.node,u)}}getParentNode(n,r){if(n&&n===r.nodesInPath?.[r.nodesInPath.length-1])return r.nodesInPath[r.nodesInPath.length-2]}getAppSwitcherData(n,r){const a=n,u=a?.showMainAppEntry;if(a&&a.items&&u){const c={title:this.luigi.i18n().getTranslation(r.title||""),subTitle:r.subTitle,link:"/"};if(a.items?.map(l=>({...l,title:this.luigi.i18n().getTranslation(l.title||"")})),a.items.some(l=>l.link===c.link))return a;a.items.unshift(c)}return a}async getTabNavData(n,r){const a=r??await this.getPathData(n);if(n===""&&a?.nodesInPath?.[0].viewUrl)return{};const u=a?.selectedNode;let c;if(!u)return{};if(!u.tabNav&&(c=this.getParentNode(u,a),c&&!c.tabNav))return{};let l="";a.nodesInPath?.forEach(_=>{_.children&&(l+="/"+(_.pathSegment||""))});const d=c?this.getTruncatedChildren(c.children??[]):this.getTruncatedChildren(u.children??[]),p=this.buildNavItems(d,u,a);return{selectedNode:u,items:p,basePath:l.replace(/\/\/+/g,"/"),navClick:_=>_.node&&this.navItemClick(_.node,a)}}async getBreadcrumbData(n,r){const a=this.luigi.getConfigValue("navigation.breadcrumbs"),u=r??await this.getPathData(n),c=u?.nodesInPath||[],l=[];let d,p="";if(!a||n===""&&c?.[0].viewUrl)return this.previousBreadcrumbs={},{};if(c.forEach(E=>{E.children&&(p+="/"+(E.pathSegment||"")),E.showBreadcrumbs===!1?d=!1:d=!0}),!d)return{clearBeforeRender:!0};const _=this.luigi.getConfigValue("routing.useHashRouting"),R=O.getCurrentPath(_),T=a.omitRoot?2:1;for(let E=T;E<c.length;E++){const C=c[E],A=O.mapPathToNode(R.path,C);if(A&&this.previousBreadcrumbs[A])l.push(this.previousBreadcrumbs[A]);else if(C.label||C.pathSegment){let N=await O.getNodeLabel(C,this.luigi);N||(N=a.pendingItemLabel||""),l.push({label:N,node:C,route:A})}}if(R.path===O.getCurrentPath(_).path){const E={};l.length>1?l[l.length-1].last=!0:a.autoHide&&(l.length=0),l.map(C=>{C.route&&(E[C.route]=C)}),this.previousBreadcrumbs=E}return{basePath:p.replace(/\/\/+/g,"/"),clearBeforeRender:a.clearBeforeRender,items:l,renderer:a.renderer,selectedNode:u?.selectedNode||{}}}onNodeChange(n,r){const a=this.luigi.getConfigValue("navigation.nodeChangeHook");M.isFunction(a)?a(n,r):a!==void 0&&console.warn("nodeChangeHook is not a function!")}async extractDataFromPath(n){const r=await this.getPathData(n);return{nodeObject:O.getLastNodeObject(r),pathData:r}}async shouldPreventNavigation(n){return!!(n?.onNodeActivation&&(M.isFunction(n.onNodeActivation)||M.isAsyncFunction(n.onNodeActivation))&&await n.onNodeActivation(n)===!1)}async shouldPreventNavigationForPath(n){const{nodeObject:r}=await this.extractDataFromPath(n);return!!await this.shouldPreventNavigation(r)}async openViewInNewTab(n){if(await this.shouldPreventNavigationForPath(n))return;this.luigi.getConfigValue("routing.useHashRouting")&&(n="#"+n);let a;try{if(a=new URL(n,window.location.origin),a.origin!==window.location.origin)return}catch{return}window.open(a.toString(),"_blank","noopener,noreferrer")}resolveTooltipText(n,r){return Ce.generateTooltipText(n,r,this.luigi)}prepareRootNodes(n,r){const a=n;return a.length&&a.forEach(u=>{u.isRootNode=!0}),a}getAccessibleNodes(n,r,a){return r?r.filter(u=>Ce.isNodeAccessPermitted(u,n,a,this.luigi)):[]}async handleNavigationRequest(n,r){const{path:a,preserveView:u,drawerSettings:c,modalSettings:l,newTab:d,withoutSync:p,preventContextUpdate:_,preventHistoryEntry:R,options:T}=n,C=(await this.buildPath(a,T||{})).replace(/\/\/+/g,"/"),A=R?"replaceState":"pushState";if(c||l)c?this.luigi.navigation().openAsDrawer(C,c,r):(l.keepPrevious||this.getModalService().closeModals(),this.luigi.navigation().openAsModal(C,l,r));else{const N={detail:{preventContextUpdate:!!_,preventHistoryEntry:!!R,withoutSync:!!p}};if(await ne.get(mn).closeModals(),d){await this.openViewInNewTab(C);return}const H=this.luigi.getConfigValue("routing.disableBrowserHistory")?"replaceState":A;if(this.luigi.getConfig().routing?.useHashRouting)if(!p&&H!=="replaceState")location.hash=C;else{const W=new CustomEvent("hashchange",N);window.history[H]({path:"/#"+C},"","/#"+C),window.dispatchEvent(W)}else{const W=new CustomEvent("popstate",N);window.history[H]({path:C},"",C),window.dispatchEvent(W)}}}async getChildren(n,r={}){const a=ne.get(_n);if(!n)return[];let u=[];if(a.hasChildren(n)){let l=a.getChildren(n);l&&(u=l.children)}else try{u=await $n.getConfigValueFromObjectAsync(n,"children",r||n.context),u==null&&(u=[]),u=u.map(l=>this.getExpandStructuralPathSegment(l)).map(l=>this.bindChildToParent(l,n))||[]}catch(l){console.error("Could not lazy-load children for node",l)}let c=this.getAccessibleNodes(n,u,r);return a.setChildren(n,{children:u,filteredChildren:c}),c}getExpandStructuralPathSegment(n){if(n&&n.pathSegment&&n.pathSegment.indexOf("/")!==-1){const r=n.pathSegment.split("/"),a={...n},u=(c,l)=>{const d=c.shift();let p={};return c.length?(p.pathSegment=d,l.hideFromNav&&(p.hideFromNav=l.hideFromNav),p.children=[u(c,l)]):(p=a,p.pathSegment=d),p};return u(r,n)}return n}bindChildToParent(n,r){return r&&r.pathSegment&&(n.parent=r),n}buildVirtualTree(n,r,a){const u=n.virtualTree,c=n._virtualTree,l=n._virtualViewUrl||n.viewUrl;if((u||c)&&r){let d=typeof n._virtualPathIndex=="number"?n._virtualPathIndex:void 0;u&&(d=void 0,n.keepSelectedForChildren=!0);const p=50;if(typeof d=="number"&&d>p)return;const _=(d??0)+1;if(_>p)return;const R=["_*","virtualTree","parent","children","keepSelectedForChildren","navigationContext"],T=M.removeProperties(n,R);Object.assign(T,{pathSegment:":virtualSegment_"+_,label:":virtualSegment_"+_,viewUrl:M.trimTrailingSlash(this.buildVirtualViewUrl(l||"",a,_)),_virtualTree:!0,_virtualPathIndex:_,_virtualViewUrl:l});const E=Array.isArray(n.children)&&n.children.length>0?n.children[0]._virtualTree:!1;return n.children&&!E&&console.warn(`Found both virtualTree and children nodes defined on a navigation node.
92
+ Invalid Children:`,n);return}return n.some(u=>{if(u.pathSegment===t||u.pathSegment&&u.pathSegment.startsWith(":"))return s=u,!0}),s}buildNavItems(t,n,s){const a={},l=[];return t?.forEach(u=>{if(Me.isNodeAccessPermitted(u,this.getParentNode(s.selectedNode,s),s?.selectedNode?.context||{},this.luigi))if(u.category){const f=u.category.id||u.category.label||u.category,h=this.luigi.i18n().getTranslation(u.category.label||u.category.id||u.category);let g=a[f];g||(g={category:{altText:u.category.altText||"",icon:u.category.icon,id:f,label:h,nodes:[],tooltip:this.resolveTooltipText(u.category,h)}},a[f]=g,l.push(g)),g.category?.nodes?.push({node:u,selected:u===n,label:u.label?this.luigi.i18n().getTranslation(u.label):void 0,tooltip:u.label?this.resolveTooltipText(u,u.label):void 0,altText:u.altText,icon:u.icon,externalLink:u.externalLink,href:u.externalLink?.url||D.getNodeHref(u,s.pathParams,this.luigi)})}else l.push({altText:u.altText,icon:u.icon,label:u.label?this.luigi.i18n().getTranslation(u.label):void 0,tooltip:u.label?this.resolveTooltipText(u,u.label):void 0,node:u,selected:u===n,externalLink:u.externalLink,href:u.externalLink?.url||D.getNodeHref(u,s.pathParams,this.luigi)})}),l}async getCurrentNode(t){const n=await this.getPathData(t);let s=n.selectedNode;if(!s&&n.nodesInPath?.length===1&&(s=n.nodesInPath[0]),!(!s||!Me.isNodeAccessPermitted(s,this.getParentNode(n.selectedNode,n),n?.selectedNode?.context||{},this.luigi)))return s}async getPathParams(t){return(await this.getPathData(t)).pathParams}getTruncatedChildren(t){let n=!1,s=!1,a=[];return t.slice().reverse().forEach(l=>{(!n||l.tabNav)&&(l.tabNav===!1&&(s=!0),l.keepSelectedForChildren===!1?n=!0:(l.keepSelectedForChildren||l.tabNav&&!s)&&(n=!0,a=[])),a.push(l)}),a.reverse()}applyNavGroups(t){const n={},s=[],l=[];return t.forEach(u=>{if(u.node)l.push(u);else if(u.category){const f=u.category.id;f&&f.indexOf("::")>0?s.push(u):(u.category.isGroup,n[f]=u,l.push(u))}}),s.forEach(u=>{const f=u.category?.id.split("::")[0]||"",h=n[f];h&&h.category&&(h.category.isGroup||(h.category.isGroup=!0),h.category.nodes||(h.category.nodes=[]),h.category.nodes.push(u))}),l.filter(u=>{if(u.category?.isGroup&&u.category?.nodes&&u.category?.nodes.length>0){for(let f=0;f<u.category?.nodes.length;f++){const h=u.category?.nodes[f];if(h.node&&!h.node.hideFromNav&&h.node.label||h.category?.nodes&&h.category.nodes.filter(g=>!g.node?.hideFromNav&&g.node?.label).length>0)return!0}return!1}return!0})}async getLeftNavData(t,n){const s=n??await this.getPathData(t);if(t===""&&s?.nodesInPath?.[0].viewUrl)return{items:[],basePath:"",selectedNode:{},navClick:void 0};let a=[];const l=[];let u="";s.nodesInPath?.forEach(E=>{E.children&&(E.tabNav||(u+="/"+(E.pathSegment||"")),l.push(E))});const f=this.getTruncatedChildren(s.nodesInPath??[]);let h=[...f].pop(),g=s.selectedNode;(h?.keepSelectedForChildren||h?.tabNav)&&(g=h,f.pop(),h=[...f].pop());let _,w=g;g?s.rootNodes.includes(g)?(_=g,w=void 0):g.tabNav||g.keepSelectedForChildren?_=h:_=[...l].pop():(_=[...l].pop(),w=void 0);let m=await this.getChildren(_,_?.context||{})||[];return a=this.buildNavItems(m,w,s),a=this.applyNavGroups(a),{selectedNode:g||{},items:a,basePath:u.replace(/\/\/+/g,"/"),sideNavFooterText:this.luigi.getConfig().settings?.sideNavFooterText,navClick:E=>E.node?this.navItemClick(E.node,s):Promise.resolve()}}async navItemClick(t,n){if(await j.get(un).getUnsavedChangesModalPromise(),t.externalLink?.url){Me.openExternalLink(t.externalLink,n?.pathParams);return}let a=D.getNodePath(t),l=n?.pathParams;if(a=M.replaceVars(a,l||{},":",!1),!a&&a!==""){console.error("Navigation error: could not build path for the node. Check if pathSegment is defined for all nodes in the path and if there are no duplicate pathSegments on the same level.");return}return this.luigi.navigation().navigate(a)}async getTopNavData(t,n){const s=this.luigi.getConfig(),a=n??await this.getPathData(t),l=s.navigation?.profile?.items?.length?JSON.parse(JSON.stringify(s.navigation.profile.items)):[],u=s.navigation?.appSwitcher&&this.getAppSwitcherData(s.navigation?.appSwitcher,s.settings?.header),f=Me.updateHeaderTitle(u,a);l?.length&&l.map(N=>({...N,label:this.luigi.i18n().getTranslation(N.label||"")}));const h=this.luigi.i18n().getTranslation(s.navigation?.profile?.logout?.label)||Pa.logout.label,g=N=>{if(N.openNodeInModal&&!N.externalLink?.url)this.luigi.navigation().openAsModal(N.link||"",N.openNodeInModal===!0?{}:N.openNodeInModal);else if(N.link)this.luigi.navigation().navigate(N.link);else if(N.externalLink?.url)if(N.externalLink.sameWindow)window.location.href=N.externalLink.url;else{const $=window.open(N.externalLink.url,"_blank","noopener noreferrer");$&&($.opener=null,$.focus())}},_=s.userSettings;let w={};_&&(w={...Pa.userSettingsProfileMenuEntry,...s.userSettings?.userSettingsProfileMenuEntry});const m={authEnabled:this.luigi.auth().isAuthorizationEnabled(),signedIn:this.luigi.auth().isAuthorizationEnabled()&&ir.isLoggedIn(),items:l,itemClick:g,logout:{altText:this.luigi.i18n().getTranslation(s.navigation?.profile?.logout?.altText)||Pa.logout.label,label:h,icon:s.navigation?.profile?.logout?.icon||Pa.logout.icon,testId:s.navigation?.profile?.logout?.testId||Me.prepareForTests(h),doLogout:()=>{ar.logout()}},settings:w,onUserInfoUpdate:N=>{this.luigi.getConfigValueAsync("navigation.profile.staticUserInfoFn").then($=>{$?N($):ar.getUserInfoStore().subscribe(J=>{N(J)})})}},E=a.selectedNode,b=E&&a.rootNodes.includes(E)?E:void 0,R=await this.buildContextSwitcher(),I={...s.navigation?.productSwitcher,productSwitcherItemClick:N=>{N.externalLink?.url?Me.openExternalLink(N.externalLink):N.link&&this.luigi.navigation().navigate(N.link)}};return{appTitle:f||s.settings?.header?.title,logo:s.settings?.header?.logo,topNodes:this.buildNavItems(a.rootNodes,b,a),contextSwitcher:R,productSwitcher:I,profile:this.luigi.auth().isAuthorizationEnabled()||s.navigation?.profile?m:void 0,appSwitcher:s.navigation?.appSwitcher&&this.getAppSwitcherData(s.navigation?.appSwitcher,s.settings?.header),navClick:N=>N.node?this.navItemClick(N.node,a):Promise.resolve()}}getParentNode(t,n){if(t&&t===n.nodesInPath?.[n.nodesInPath.length-1])return n.nodesInPath[n.nodesInPath.length-2]}getAppSwitcherData(t,n){const s=t,a=s?.showMainAppEntry;if(s&&s.items&&a){const l={title:this.luigi.i18n().getTranslation(n.title||""),subTitle:n.subTitle,link:"/"};if(s.items?.map(u=>({...u,title:this.luigi.i18n().getTranslation(u.title||"")})),s.items.some(u=>u.link===l.link))return s;s.items.unshift(l)}return s}async getTabNavData(t,n){const s=n??await this.getPathData(t);if(t===""&&s?.nodesInPath?.[0].viewUrl)return{};const a=s?.selectedNode;let l;if(!a)return{};if(!a.tabNav&&(l=this.getParentNode(a,s),l&&!l.tabNav))return{};let u="";s.nodesInPath?.forEach(g=>{g.children&&(u+="/"+(g.pathSegment||""))});const f=l?this.getTruncatedChildren(l.children??[]):this.getTruncatedChildren(a.children??[]),h=this.buildNavItems(f,a,s);return{selectedNode:a,items:h,basePath:u.replace(/\/\/+/g,"/"),navClick:g=>g.node?this.navItemClick(g.node,s):Promise.resolve()}}async getBreadcrumbData(t,n,s){const a=this.luigi.getConfigValue("navigation.breadcrumbs"),l=n??await this.getPathData(t),u=l?.nodesInPath||[],f=[];let h=!!a,g="";if(!a||t===""&&u?.[0].viewUrl)return this.previousBreadcrumbs={},{};if(u.forEach(R=>{R.children&&(g+="/"+(R.pathSegment||"")),R.showBreadcrumbs===!1?h=!1:R.showBreadcrumbs===!0&&(h=!0)}),!h)return{clearBeforeRender:!0};const _=this.luigi.getConfigValue("routing.useHashRouting"),w=D.getCurrentPath(this.luigi,_),m=a.omitRoot?2:1;for(let R=m;R<u.length;R++){const I=u[R],N=D.mapPathToNode(w.path,I);if(N&&this.previousBreadcrumbs[N])f.push(this.previousBreadcrumbs[N]);else if(I.label||I.pathSegment||I.titleResolver)if(I.titleResolver)f.push({label:I.titleResolver.prerenderFallback&&I.titleResolver.fallbackTitle?this.luigi.i18n().getTranslation(I.titleResolver.fallbackTitle):a.pendingItemLabel||"",node:I,route:N,pending:!0});else{const $=await D.getNodeLabel(I,this.luigi);$&&f.push({label:$,node:I,route:N})}}const E=f.some(R=>R.pending),b=R=>({basePath:g.replace(/\/\/+/g,"/"),clearBeforeRender:a.clearBeforeRender,items:R,renderer:a.renderer,selectedNode:l?.selectedNode||{}});if(E&&s)return this.resolveBreadcrumbTitles(u,m,w,_,a,b,s),b(f);if(w.path===D.getCurrentPath(this.luigi,_).path){const R={};f.length>1?f[f.length-1].last=!0:a.autoHide&&(f.length=0),f.map(I=>{I.route&&(R[I.route]=I)}),this.previousBreadcrumbs=R}return b(f)}async resolveBreadcrumbTitles(t,n,s,a,l,u,f){const h=[];for(let g=n;g<t.length;g++){const _=t[g],w=D.mapPathToNode(s.path,_);if(_.titleResolver)try{const E=await this.extractDataFromPath(w||""),b=D.substituteDynamicParamsInObject(Object.assign({},E.pathData.context,_.context),E.pathData.pathParams||{}),R=await Me.fetchNodeTitleData(_,b);h.push({label:R.label,node:_,route:w});continue}catch{}const m=await D.getNodeLabel(_,this.luigi);m&&h.push({label:m,node:_,route:w})}if(s.path===D.getCurrentPath(this.luigi,a).path){const g={};h.length>1?h[h.length-1].last=!0:l.autoHide&&(h.length=0),h.map(_=>{_.route&&(g[_.route]=_)}),this.previousBreadcrumbs=g}f(u(h))}onNodeChange(t,n){const s=this.luigi.getConfigValue("navigation.nodeChangeHook");M.isFunction(s)?s(t,n):s!==void 0&&console.warn("nodeChangeHook is not a function!")}async extractDataFromPath(t){const n=await this.getPathData(t);return{nodeObject:D.getLastNodeObject(n),pathData:n}}async shouldPreventNavigation(t){return!!(t?.onNodeActivation&&(M.isFunction(t.onNodeActivation)||M.isAsyncFunction(t.onNodeActivation))&&await t.onNodeActivation(t)===!1)}async shouldPreventNavigationForPath(t){const{nodeObject:n}=await this.extractDataFromPath(t);return!!await this.shouldPreventNavigation(n)}async openViewInNewTab(t){if(await this.shouldPreventNavigationForPath(t))return;this.luigi.getConfigValue("routing.useHashRouting")&&(t="#"+t);let s;try{if(s=new URL(t,window.location.origin),s.origin!==window.location.origin)return}catch{return}window.open(s.toString(),"_blank","noopener,noreferrer")}resolveTooltipText(t,n){return Me.generateTooltipText(t,n,this.luigi)}prepareRootNodes(t,n){const s=t;return s.length&&s.forEach(a=>{a.isRootNode=!0}),s}getAccessibleNodes(t,n,s){return n?n.filter(a=>Me.isNodeAccessPermitted(a,t,s,this.luigi)):[]}async handleNavigationRequest(t,n){const{path:s,intent:a,preserveView:l,drawerSettings:u,modalSettings:f,newTab:h,withoutSync:g,preventContextUpdate:_,preventHistoryEntry:w,options:m}=t,E=this.luigi.getConfig().routing?.useHashRouting,b=!!(u||f);let R=await this.buildPath(s,m||{});if(!b){const J=j.get(un);try{await J.getUnsavedChangesModalPromise()}catch{return}}if(a){const J=D.getIntentPath(s.replace("#",""),this.luigi);if(!J)return;if(typeof J=="string")R=J;else if(M.isObject(J)){D.handleExternalIntentPath(J);return}}const I=R.replace(/\/\/+/g,"/"),N=w?"replaceState":"pushState",$=D.getCurrentPath(this.luigi,E).path;if(M.trimLeadingSlash($)!==M.trimLeadingSlash(I))if(u||f)if(u)this.luigi.navigation().openAsDrawer(I,u,n);else{if(!f.keepPrevious&&!await this.getModalService().closeModalsWithDirtyCheck())return;this.luigi.navigation().openAsModal(I,f,n)}else{const J={detail:{preventContextUpdate:!!_,preventHistoryEntry:!!w,withoutSync:!!g}},de=j.get(un);if(G.drawerContainer&&de.shouldShowUnsavedChangesModal(G.drawerContainer))try{await de.getUnsavedChangesModalPromise(G.drawerContainer)}catch{return}if(!await j.get(fr).closeModalsWithDirtyCheck())return;if(h){await this.openViewInNewTab(I);return}const pe=this.luigi.getConfigValue("routing.disableBrowserHistory")?"replaceState":N;if(E)if(!g&&pe!=="replaceState")location.hash=I;else{const oe=new CustomEvent("hashchange",J);window.history[pe]({path:"/#"+I},"","/#"+I),window.dispatchEvent(oe)}else{const oe=new CustomEvent("popstate",J);window.history[pe]({path:I},"",I),window.dispatchEvent(oe)}}}async getChildren(t,n={}){const s=j.get(hr);if(!t)return[];let a=[];if(s.hasChildren(t)){let u=s.getChildren(t);u&&(a=u.children)}else try{a=await kr.getConfigValueFromObjectAsync(t,"children",n||t.context),a==null&&(a=[]),a=a.map(u=>this.getExpandStructuralPathSegment(u)).map(u=>this.bindChildToParent(u,t))||[]}catch(u){console.error("Could not lazy-load children for node",u)}let l=this.getAccessibleNodes(t,a,n);return s.setChildren(t,{children:a,filteredChildren:l}),l}getExpandStructuralPathSegment(t){if(t&&t.pathSegment&&t.pathSegment.indexOf("/")!==-1){const n=t.pathSegment.split("/"),s={...t},a=(l,u)=>{const f=l.shift();let h={};return l.length?(h.pathSegment=f,u.hideFromNav&&(h.hideFromNav=u.hideFromNav),h.children=[a(l,u)]):(h=s,h.pathSegment=f),h};return a(n,t)}return t}bindChildToParent(t,n){return n&&n.pathSegment&&(t.parent=n),t}buildVirtualTree(t,n,s){const a=t.virtualTree,l=t._virtualTree,u=t._virtualViewUrl||t.viewUrl;if((a||l)&&n){let f=typeof t._virtualPathIndex=="number"?t._virtualPathIndex:void 0;a&&(f=void 0,t.keepSelectedForChildren=!0);const h=50;if(typeof f=="number"&&f>h)return;const g=(f??0)+1;if(g>h)return;const _=["_*","virtualTree","parent","children","keepSelectedForChildren","navigationContext"],w=M.removeProperties(t,_);Object.assign(w,{pathSegment:":virtualSegment_"+g,label:":virtualSegment_"+g,viewUrl:M.trimTrailingSlash(this.buildVirtualViewUrl(u||"",s,g)),_virtualTree:!0,_virtualPathIndex:g,_virtualViewUrl:u});const m=Array.isArray(t.children)&&t.children.length>0?t.children[0]._virtualTree:!1;return t.children&&!m&&console.warn(`Found both virtualTree and children nodes defined on a navigation node.
53
93
  Children nodes are redundant and ignored when virtualTree is enabled.
54
- Please refer to documentation`),[T]}}buildVirtualViewUrl(n,r,a){let u="";for(const l in r)l.startsWith("virtualSegment")&&(u+=":"+l+"/");if(!a)return n;u+=":virtualSegment_"+a+"/";let c=n;n.includes("{virtualTreePath}")?c=n.replace("{virtualTreePath}",u):c=n+"/"+u;try{if(new URL(c,"http://dummy-base").origin===new URL(n,"http://dummy-base").origin)return c}catch(l){console.error("Error building virtual view URL -- make sure virtualTreePath is not part of origin.",l)}return n}async buildPath(n,r){const{fromVirtualTreeRoot:a,fromContext:u,fromClosestContext:c,fromParent:l,relative:d,nodeParams:p}=r,_=this.luigi.getConfigValue("routing.useHashRouting"),{path:R,query:T}=O.getCurrentPath(_),E=R+(T?"?"+T:""),C=await this.getPathData(E),A=C.nodesInPath;let N=n;if(A===void 0)return console.warn("No nodes in path found for current path:",E),N;if(a){N="";const H=[...A].map((W,ie)=>W.virtualTree?ie:-1).filter(W=>W!==-1).pop();A.forEach((W,ie)=>{W.pathSegment&&(H===void 0||ie<=H)&&(N+="/"+W.pathSegment)}),N+="/"+n}else if(u){const H=u,W=[...A].reverse().find(ie=>H===ie.navigationContext);N=O.concatenatePath(O.getSubPath(W,C.pathParams),n)}else if(c){const H=[...A].reverse().find(W=>W.navigationContext&&W.navigationContext.length>0);N=O.concatenatePath(O.getSubPath(H,C.pathParams),n)}else l?N=O.concatenatePath(O.getSubPath(C.selectedNode?.parent,C.pathParams),n):d&&(N=O.concatenatePath(O.getSubPath(C.selectedNode,C.pathParams),n));return p&&Object.keys(p).length>0&&(N+=N.includes("?")?"&":"?",Object.entries(p).forEach((H,W)=>{N+=encodeURIComponent(O.getContentViewParamPrefix(this.luigi)+H[0])+"="+encodeURIComponent(H[1])+(W<Object.keys(p).length-1?"&":"")})),N}}class Mn{constructor(n){this.luigi=n}getNavigationService(){return this.navigationService||(this.navigationService=ne.get(vn)),this.navigationService}shouldSkipRoutingForUrlPatterns(){const n=[/access_token=/,/id_token=/];return(this.luigi.getConfigValue("routing.skipRoutingForUrlPatterns")||n).filter(a=>location.href.match(a)).length!==0}enableRouting(){const n=this.luigi.getConfig();console.log("Init Routing...",n.routing),n.routing?.useHashRouting?(window.addEventListener("hashchange",r=>{const a=!!r?.detail?.preventContextUpdate,u=!!r?.detail?.withoutSync;this.handleRouteChange(O.getCurrentPath(!0),u,a)}),this.handleRouteChange(O.getCurrentPath(!0))):(window.addEventListener("popstate",r=>{const a=!!r?.detail?.preventContextUpdate,u=!!r?.detail?.withoutSync;this.handleRouteChange(O.getCurrentPath(),u,a)}),this.handleRouteChange(O.getCurrentPath()))}async handleRouteChange(n,r=!1,a=!1){const u=n.path,c=n.query,l=u+(c?"?"+c:""),d=new URLSearchParams(c),p=Object.create(null);if(this.shouldSkipRoutingForUrlPatterns())return;this.setFeatureToggle(l),await this.shouldShowModalPathInUrl(n),d.forEach((A,N)=>{p[N]=A}),this.checkInvalidateCache(this.previousPathData,u);const _=await this.getNavigationService().getPathData(u);this.previousPathData=_;const R=O.filterNodeParams(p,this.luigi),T=M.getPathWithoutHash(u);this.currentRoute={raw:window.location.href,path:u,nodeParams:R};const E=_?.selectedNode??await this.getNavigationService().getCurrentNode(u),C=E?.viewUrl||"";if(!await this.handlePageNotFound(E,C,_,u,T)&&(this.luigi.getEngine()._connector?.renderTopNav(await this.getNavigationService().getTopNavData(u,_)),this.luigi.getEngine()._connector?.renderLeftNav(await this.getNavigationService().getLeftNavData(u,_)),this.luigi.getEngine()._connector?.renderTabNav(await this.getNavigationService().getTabNavData(u,_)),this.luigi.getEngine()._connector?.renderBreadcrumbs(await this.getNavigationService().getBreadcrumbData(u,_)),E)){const A={nodeParams:R||{},pathParams:_?.pathParams||{},searchParams:O.prepareSearchParamsForClient(E,this.luigi)};this.currentRoute.node=E,this.getNavigationService().onNodeChange(this.previousNode,E),this.previousNode=E,Z.updateMainContent(E,this.luigi,A,r,a)}}getCurrentRoute(){return this.currentRoute}async shouldShowModalPathInUrl(n){this.luigi.getConfigValue("routing.showModalPathInUrl")&&await this.handleBookmarkableModalPath(n)}async handleBookmarkableModalPath(n){const r=ne.get(vn),a=ne.get(mn),u=new URLSearchParams(n?.query||""),c=O.getModalViewParamName(this.luigi),l=u.get(c);if(l){const d=u.get(`${c}Params`);try{const p=JSON.parse(d||"{}"),{nodeObject:_}=await r.extractDataFromPath(l);document.querySelector(".lui-modal luigi-container")?this.luigi.getEngine()._connector?.updateModalSettings(p):this.luigi.navigation().openAsModal(l,p||_.openNodeInModal)}catch(p){console.error("Error parsing modal settings from URL parameters",p)}}else{a.closeModals();return}}appendModalDataToUrl(n,r){const a=O.getHashQueryParamSeparator(),u=O.getQueryParams(this.luigi),c=O.getModalViewParamName(this.luigi),l=u[c],d=new URL(location.href),p=this.luigi.getConfigValue("routing.useHashRouting");let _=history.state,R,T;if(p){let[E,C]=d.hash.split("?");R=E,T=O.getURLWithoutModalData(C,c),T&&(R+="?"+T)}else R=d.pathname,T=O.getURLWithoutModalData(d.search,c),T&&(R+="?"+O.getURLWithoutModalData(d.search,c));if(_=O.handleHistoryState(_,R),l!==n){if(u[c]=n,r&&Object.keys(r).length&&(u[`${c}Params`]=JSON.stringify(r)),p){const E=location.hash.indexOf(a);E!==-1&&(d.hash=d.hash.slice(0,E)),d.hash=`${d.hash}${a}${O.encodeParams(u)}`}else d.search=`?${O.encodeParams(u)}`;history.pushState(_,"",d.href)}else{const E=new URL(d);if(p){let C=E.hash.split("?")[0];E.hash=C,T&&(E.hash+="?"+T)}else E.search=T;history.replaceState({},"",E.href),history.pushState(_,"",d.href)}}removeModalDataFromUrl(n){const r=O.getQueryParams(this.luigi),a=O.getModalViewParamName(this.luigi);let u=new URL(location.href);if(this.luigi.getConfigValue("routing.useHashRouting")){let l={};r[a]&&(l[a]=r[a]),r[`${a}Params`]&&(l[`${a}Params`]=r[`${a}Params`]);let d=O.encodeParams(l);u.hash.includes(`?${d}`)?u.hash=u.hash.replace(`?${d}`,""):u.hash.includes(`&${d}`)&&(u.hash=u.hash.replace(`&${d}`,""))}else{let l=new URLSearchParams(u.search.slice(1));l.delete(a),l.delete(`${a}Params`);let d="";Array.from(l.keys()).forEach(p=>{d+=(d===""?"?":"&")+p+"="+l.get(p)}),u.search=d}if(history.state&&history.state.modalHistoryLength>=0&&n){history.state.modalHistoryLength;const l=history.state.pathBeforeHistory;let d=!1;if(window.addEventListener("popstate",p=>{d?(history.replaceState({},"",l),history.pushState({},"",l),history.back()):(history.pushState({},"",l),history.back())},{once:!0}),history.state.historygap===history.length-history.state.modalHistoryLength)history.go(-history.state.modalHistoryLength);else if(history.state.modalHistoryLength>history.length){const p=history.length-1;d=!0,history.go(-p),window.Luigi.preventLoadingModalData=!0}else{const p=history.state.modalHistoryLength;history.go(-p)}}else history.pushState({},"",u.href)}setFeatureToggle(n){const r=this.luigi.getConfigValue("settings.featureToggles.queryStringParam"),a=this.luigi.featureToggles();r&&typeof n=="string"&&O.setFeatureToggles(r,n,a)}updateModalDataInUrl(n,r,a){let u=O.getHashQueryParamSeparator();const c=O.getQueryParams(this.luigi),l=O.getModalViewParamName(this.luigi);c[l]=n,r&&Object.keys(r).length&&(c[`${l}Params`]=JSON.stringify(r));const d=new URL(location.href);if(this.luigi.getConfigValue("routing.useHashRouting")){const _=location.hash.indexOf(u);_!==-1&&(d.hash=d.hash.slice(0,_)),d.hash=`${d.hash}${u}${O.encodeParams(c)}`}else d.search=`?${O.encodeParams(c)}`;a?history.pushState(window.state,"",d.href):history.replaceState(window.state,"",d.href)}checkInvalidateCache(n,r){if(!n)return;const a=ne.get(_n);let u=r.split("/");if(n.nodesInPath&&n.nodesInPath.length>0){let c=n.nodesInPath.slice(1),l=!0;for(let d=0;d<c.length;d++){let p=u.length>d?u[d]:void 0,_=c[d];if(p!==_.pathSegment||!l)if(O.isDynamicNode(_)){if(!l||p!==O.getDynamicNodeValue(_,n.pathParams)){a.deleteNodesRecursively(_);break}}else l=!1}}else a.deleteCache()}async handlePageNotFound(n,r,a,u,c){const l=M.getTrimmedUrl(u),d=O.isExistingRoute(l,a);if(!r&&!n?.compound||n?.tabNav?.showAsTabHeader){const p=await O.getDefaultChildNode(a,async(_,R)=>await this.getNavigationService().getChildren(_,R));if(d){const _=M.getTrimmedUrl(u);return this.getNavigationService().handleNavigationRequest({path:`${_?`/${_}`:""}/${p}`,preserveView:void 0,modalSettings:void 0,newTab:!1,withoutSync:!1,preventContextUpdate:!1,preventHistoryEntry:!0}),!1}else{if(p&&a?.nodesInPath&&a.nodesInPath.length>1)return this.showPageNotFoundError(M.trimTrailingSlash(l||"")+"/"+p,c,!0),!0;const _=await O.getDefaultChildNode(a);this.showPageNotFoundError(_,c,!1)}return!0}return d?!1:(this.showPageNotFoundError(a.matchedPath,c,!0),!0)}async showPageNotFoundError(n,r,a=!1){const u=O.getPageNotFoundRedirectResult(r,a,this.luigi);if(u.ignoreLuigiErrorHandling)return;const c=u.path;if(c){if(u.keepURL){const l=this.luigi.getConfig().routing?.useHashRouting,d=O.getCurrentPath(l);d.path=c,this.handleRouteChange(d)}else this.getNavigationService().handleNavigationRequest({path:c});return}O.showRouteNotFoundAlert(r,a,this.luigi),this.getNavigationService().handleNavigationRequest({path:M.addLeadingSlash(n)})}}class mr{constructor(){this.decorators=[]}hasDecorators(){return this.decorators.length>0}add(n){this.decorators=this.decorators.filter(r=>r.uid!==n.uid).concat(n)}applyDecorators(n,r){if(!n)return n;const a=new URL(M.prependOrigin(n)),u=this.decorators.filter(c=>c.type==="queryString");for(let c=0;c<u.length;c++){const l=u[c];a.searchParams.has(l.key)&&a.searchParams.delete(l.key);const d=l.valueFn();a.searchParams.append(l.key,d)}return r&&(a.search=decodeURIComponent(a.search)),a.href}}const Oa=async(i,n,r)=>{const a=await n.readUserSettings(),c=i.userSettingsGroup&&typeof a=="object"&&a!==null&&i.userSettingsGroup?a[i.userSettingsGroup]:null,l=r?.nodeParams||{},d=r?.pathParams||{},p=r?.searchParams||{};if(i.webcomponent&&i.viewUrl&&!O.checkWCUrl(i.viewUrl,n))return console.warn(`View URL '${i.viewUrl}' not allowed to be included`),document.createElement("div");if(i.compound){const _=document.createElement("luigi-compound-container");return _.setAttribute("lui_container","true"),_.viewurl=i.viewUrl?ne.get(mr).applyDecorators(O.substituteViewUrl(i,d,n),i.decodeViewUrl??!1):"",_.webcomponent=i.webcomponent??!1,_.compoundConfig=i.compound,_.context=i.context,_.clientPermissions=i.clientPermissions??{},_.nodeParams=l,_.pathParams=d,_.userSettingsGroup=i.userSettingsGroup,_.userSettings=c,_.searchParams=p,_.activeFeatureToggleList=n.featureToggles().getActiveFeatureToggleList(),_.locale=n.i18n().getCurrentLocale(),_.theme=n.theming().getCurrentTheme(),_.viewGroup=i.viewGroup,_.virtualTree=i.virtualTree||i._virtualTree,_.virtualTreeRootNode=Ce.findVirtualTreeRootNode(i),n.getEngine()._comm.addListeners(_,n),_}else{const _=document.createElement("luigi-container");return _.setAttribute("lui_container","true"),_.viewurl=i.viewUrl?ne.get(mr).applyDecorators(O.substituteViewUrl(i,d,n),i.decodeViewUrl??!1):"",_.webcomponent=i.webcomponent??!1,_.context=i.context,_.clientPermissions=i.clientPermissions??{},_.cssVariables=await n.theming().getCSSVariables(),_.nodeParams=l,_.pathParams=d,_.userSettingsGroup=i.userSettingsGroup,_.userSettings=c,_.searchParams=p,_.activeFeatureToggleList=n.featureToggles().getActiveFeatureToggleList(),_.locale=n.i18n().getCurrentLocale(),_.theme=n.theming().getCurrentTheme(),_.viewGroup=i.viewGroup,_.virtualTree=i.virtualTree||i._virtualTree,_.virtualTreeRootNode=Ce.findVirtualTreeRootNode(i),Sc(_,n),Ec(_,n),n.getEngine()._comm.addListeners(_,n),_.luigiMfId=M.getRandomId(),_}},Sc=(i,n)=>{const r=n.getConfigValue("settings.customSandboxRules");if(!r?.length)return;const a=["allow-forms","allow-modals","allow-popups","allow-popups-to-escape-sandbox","allow-same-origin","allow-scripts"],u=r?[...new Set([...a,...r])]:a;i.sandboxRules=u},Ec=(i,n)=>{const r=n.getConfigValue("settings.allowRules");r?.length&&(r.forEach((a,u)=>{r[u]=a+(a.indexOf(";")!=-1?"":";")}),i.allowRules=r)},Z={navService:void 0,routingService:void 0,luigi:void 0,modalContainer:[],drawerContainer:void 0,init:i=>{console.log("Init UI..."),Z.navService=ne.get(vn),Z.routingService=ne.get(Mn),Z.luigi=i,i.getEngine()._connector?.renderMainLayout()},update:async i=>{const n=Z.routingService.getCurrentRoute();if(!n)return;const r=!i||i.length===0;(r||i.includes("settings.header")||i.includes("settings")||i.includes("navigation")||i.includes("navigation.profile")||i.includes("navigation.contextSwitcher")||i.includes("navigation.productSwitcher"))&&Z.luigi.getEngine()._connector?.renderTopNav(await Z.navService.getTopNavData(n.path)),(r||i.includes("navigation")||i.includes("navigation.nodes")||i.includes("navigation.viewgroupdata")||i.includes("settings")||i.includes("settings.footer"))&&(ne.get(_n).deleteCache(),Z.luigi.getEngine()._connector?.renderLeftNav(await Z.navService.getLeftNavData(n.path)),Z.luigi.getEngine()._connector?.renderTabNav(await Z.navService.getTabNavData(n.path)),Z.luigi.getEngine()._connector?.renderBreadcrumbs(await Z.navService.getBreadcrumbData(n.path))),(r||i.includes("navigation")||i.includes("navigation.nodes")||i.includes("navigation.viewgroupdata")||i.includes("settings.theming"))&&(ne.get(_n).deleteCache(),n.node&&Z.updateMainContent(n.node,Z.luigi))},updateMainContent:async(i,n,r,a,u)=>{const c=await n.readUserSettings(),d=i.userSettingsGroup&&typeof c=="object"&&c!==null&&i.userSettingsGroup?c[i.userSettingsGroup]:null,p=n.getEngine()._connector?.getContainerWrapper();n.getEngine()._connector?.hideLoadingIndicator(p);const _=r?.nodeParams||{},R=r?.pathParams||{},T=r?.searchParams||{};if(i&&p){let E,C;if((i.virtualTree||i._virtualTree)&&(C=Ce.findVirtualTreeRootNode(i)),[...p.childNodes].forEach(A=>{A.tagName?.indexOf("LUIGI-")===0&&(A.viewGroup&&i.viewGroup!==A.viewGroup?A.style.display="none":A.viewGroup||A.virtualTree&&C===A.virtualTreeRootNode?E=A:A.remove())}),E)a||(E.style.display="block",E.viewurl=i.viewUrl?ne.get(mr).applyDecorators(O.substituteViewUrl(i,R,n),i.decodeViewUrl??!1):"",E.nodeParams=_,E.pathParams=R,E.clientPermissions=i.clientPermissions,E.searchParams=T,E.locale=n.i18n().getCurrentLocale(),E.theme=n.theming().getCurrentTheme(),E.activeFeatureToggleList=n.featureToggles().getActiveFeatureToggleList(),E.userSettingsGroup=i.userSettingsGroup,E.userSettings=d,Sc(E,n),Ec(E,n)),u||E.updateContext(i.context||{});else{const A=await Oa(i,n,r);p?.appendChild(A);const N=n.getEngine()._connector;i.loadingIndicator?.enabled!==!1&&N?.showLoadingIndicator(p)}}},openModal:async(i,n,r,a)=>{const u=await Oa(n,i);Z.modalContainer.push(u);const c=ne.get(Mn),l=ne.get(mn);let d=!1,p,_;const T=new Promise(A=>{p=()=>{d||(d=!0,A(),l.removeLastModalFromStack())},_=()=>{p&&p(),i.getConfigValue("routing.showModalPathInUrl")&&l.getModalStackLength()===0&&c.removeModalDataFromUrl(!0)},u.addEventListener(U.CLOSE_CURRENT_MODAL_REQUEST,_)}),E={closePromise:T,resolveFn:p,onCloseRequestHandler:_,onInternalClose:()=>{try{E.resolveFn&&E.resolveFn()}catch(A){console.warn("onInternalClose failed",A)}},modalsettings:r};l.registerModal(E),i.getEngine()._connector?.renderModal(u,r,()=>{a?.(),l.removeLastModalFromStack(),i.getConfigValue("routing.showModalPathInUrl")&&l.getModalStackLength()===0&&c.removeModalDataFromUrl(!0)},()=>T);const C=i.getEngine()._connector;n.loadingIndicator?.enabled!==!1&&C?.showLoadingIndicator(u.parentElement)},updateModalSettings:(i,n,r)=>{const a=ne.get(mn);if(a.getModalStackLength()===0)return;a.updateFirstModalSettings(i);const u=ne.get(Mn),c=O.getModalPathFromPath(r);c&&u.updateModalDataInUrl(c,a.getModalSettings(),n),r.getEngine()._connector?.updateModalSettings(a.getModalSettings())},openDrawer:async(i,n,r,a)=>{const u=await Oa(n,i);Z.drawerContainer=u,i.getEngine()._connector?.renderDrawer(u,r,a);const c=i.getEngine()._connector;n.loadingIndicator?.enabled!==!1&&c?.showLoadingIndicator(u.parentElement)}},ka={getMicrofrontendsInDom(i){return[...this.getMainMicrofrontends(i).map(n=>({container:n.iframe,active:n.active,type:"main",id:n.id})),...this.getModalMicrofrontends().map(n=>({container:n.iframe,active:n.active,type:"modal",id:n.id})),...(()=>{const n=this.getDrawerMicrofrontends();return n.iframe?[{container:n.iframe,active:n.active,type:"drawer",id:n.id}]:[]})()]},getMainMicrofrontends(i){const n=i.getEngine()._connector?.getContainerWrapper();if(!n)return[];const r=[];for(const a of n.childNodes)if(a.tagName?.startsWith("LUIGI-"))if(a.iframeHandle?.iframe)r.push({iframe:a.iframeHandle.iframe,id:a.luigiMfId,active:M.isElementVisible(a)});else{const u=a.shadowRoot?.firstElementChild?.firstElementChild??null;u&&r.push({iframe:u,id:a.luigiMfId,active:M.isElementVisible(a)})}return r},getModalMicrofrontends(){const i=[];for(const n of Z.modalContainer)if(n.iframeHandle?.iframe)i.push({iframe:n.iframeHandle.iframe,id:n.luigiMfId,active:M.isElementVisible(n)});else{const r=n.shadowRoot?.firstElementChild?.firstElementChild??null;r&&i.push({iframe:r,id:n.luigiMfId,active:M.isElementVisible(n)})}return i},getDrawerMicrofrontends(){if(!Z.drawerContainer)return{};if(Z.drawerContainer.iframeHandle?.iframe)return{iframe:Z.drawerContainer.iframeHandle.iframe,id:Z.drawerContainer.luigiMfId,active:M.isElementVisible(Z.drawerContainer)};{const i=Z.drawerContainer.shadowRoot?.firstElementChild?.firstElementChild??null;if(i)return{iframe:i,id:Z.drawerContainer.luigiMfId,active:M.isElementVisible(Z.drawerContainer)}}return{}},getAllLuigiContainerIframe(i){const n=i.getEngine()._connector?.getContainerWrapper();if(!n)return;const r=[...n.children].filter(a=>a.tagName?.indexOf("LUIGI-CONTAINER")===0&&a.iframeHandle?.iframe);for(const a of Z.modalContainer)a.iframeHandle?.iframe&&r.push(a);return Z.drawerContainer&&Z.drawerContainer.iframeHandle?.iframe&&r.push(Z.drawerContainer),r.length>0?r:void 0}};class ow{constructor(n){this.luigi=n}getShellbar(){return this.luigi.getEngine()._connector?.getCoreAPISupportedElements().getShellbarElement()||null}getShellbarActions(){return this.luigi.getEngine()._connector?.getCoreAPISupportedElements().getShellbarActions()||null}getLuigiContainer(){return this.luigi.getEngine()._connector?.getCoreAPISupportedElements().getLuigiContainer()||null}getNavFooterContainer(){return this.luigi.getEngine()._connector?.getCoreAPISupportedElements().getNavFooterContainer()||null}getMicrofrontends(){return ka.getMicrofrontendsInDom(this.luigi)}getMicrofrontendIframes(){const n=this.luigi.getEngine()._connector?.getContainerWrapper();let r=[];if(Z.modalContainer)for(const a of Array.from(Z.modalContainer))a.tagName?.startsWith("LUIGI-")&&a.iframeHandle?.iframe&&r.push(a.iframeHandle.iframe);if(Z.drawerContainer&&r.push(Z.drawerContainer.iframeHandle.iframe),!n)return null;for(const a of Array.from(n.childNodes))a.tagName?.startsWith("LUIGI-")&&a.iframeHandle?.iframe&&r.push(a.iframeHandle.iframe);return r}getCurrentMicrofrontendIframe(){const n=this.luigi.getEngine()._connector?.getContainerWrapper();if(!n)return null;const r=Z.modalContainer[0]?.iframeHandle?.iframe??null;let a=null,u=null;for(const c of Array.from(n.children))c.tagName?.startsWith("LUIGI-")&&M.isElementVisible(c)&&(c.iframeHandle?.iframe?a=c.iframeHandle.iframe:u=c.shadowRoot?.firstElementChild?.firstElementChild??null);return r||a||u}}const uw={luigiAfterInit:async i=>{M.getConfigBooleanValue(i.getConfig(),"settings.appLoadingIndicator.hideAutomatically")&&setTimeout(()=>{i.ux().hideAppLoadingIndicator()},0),await Xe.executeConfigFnAsync("lifecycleHooks.luigiAfterInit")}};class lw{constructor(){this.featureToggleList=new Set}setFeatureToggle(n,r=!1){this.isValid(n)&&(n.startsWith("!")&&!r||this.isDuplicatedOrDisabled(n)||this.featureToggleList.add(n))}unsetFeatureToggle(n){if(this.isValid(n)){if(!this.featureToggleList.has(n)){console.warn("Feature toggle name is not in the list.");return}this.featureToggleList.delete(n)}}getActiveFeatureToggleList(){return[...Array.from(this.featureToggleList)].filter(r=>!r.startsWith("!"))}isValid(n){return M.isString(n)?!0:(console.warn("Feature toggle name is not valid or not of type 'string'"),!1)}isDuplicatedOrDisabled(n){return this.featureToggleList.has(n)?(console.warn("Feature toggle name already exists"),!0):this.featureToggleList.has(`!${n}`)?(console.warn("Disabled feature toggle can not be activated"),!0):!1}}class cw{constructor(n){this.hashRouting=!1,this.options={fromContext:null,fromClosestContext:!1,fromVirtualTreeRoot:!1,fromParent:!1,nodeParams:{}},this.navigate=async(r,a,u,c,l)=>{const d=r[0]!=="/";this.options.relative=d;const p={modalSettings:u,newTab:!1,options:this.options,path:r,preserveView:a,preventContextUpdate:!1,preventHistoryEntry:!1,withoutSync:!1};this.navService.handleNavigationRequest(p,void 0)},this.openAsModal=async(r,a,u)=>{a?.keepPrevious||await this.modalService.closeModals();const c=r.replace(/\/\/+/g,"/");if(!await Ce.validatePathAndGetRedirect(c,this.luigi))return;const d=await this.navService.getCurrentNode(c),p=a||{};p.title||(p.title=d?.label),this.luigi.getConfigValue("routing.showModalPathInUrl")&&this.modalService.getModalStackLength()===0&&this.routingService.appendModalDataToUrl(c,p),this.luigi.getEngine()._ui.openModal(this.luigi,d,p,u)},this.openAsDrawer=async(r,a,u)=>{const c=r.replace(/\/\/+/g,"/");if(!await Ce.validatePathAndGetRedirect(c,this.luigi))return;const d=await this.navService.getCurrentNode(c),p=a||{};if(!p.header?.title){const R=await O.getNodeLabel(d,this.luigi)||"";p.header?p.header.title=R:p.header={title:R}}p.overlap===void 0&&(p.overlap=!0),this.luigi.getEngine()._ui.openDrawer(this.luigi,d,p,u)},this.runTimeErrorHandler=async r=>{const{path:a}=O.getCurrentPath(this.luigi.getConfig().routing?.useHashRouting),u=await this.navService.getCurrentNode(a),c=this.luigi.getConfigValue("navigation.defaults.runTimeErrorHandler");u?.runTimeErrorHandler?.errorFn&&M.isFunction(u?.runTimeErrorHandler?.errorFn)?u.runTimeErrorHandler.errorFn(r,u):c?.errorFn&&M.isFunction(c.errorFn)&&c.errorFn(r,u)},this.pathExists=async r=>await O.pathExists(r,this.luigi),this.luigi=n,this.hashRouting=n.getConfig().routing?.useHashRouting,this.navService=ne.get(vn),this.routingService=ne.get(Mn),this.modalService=ne.get(mn)}fromVirtualTreeRoot(){return this.options.fromContext=null,this.options.fromClosestContext=!1,this.options.fromVirtualTreeRoot=!0,this.options.fromParent=!1,this}fromContext(n){return this.options.fromContext=n,this}fromClosestContext(){return this.options.fromContext=null,this.options.fromClosestContext=!0,this.options.fromParent=!1,this}fromParent(){return this.options.fromContext=null,this.options.fromClosestContext=!1,this.options.fromVirtualTreeRoot=!1,this.options.fromParent=!0,this}withParams(n){return n&&Object.assign(this.options.nodeParams??{},n),this}}class hw{constructor(n){this.luigi=n}addSearchParams(n,r=!1){if(!M.isObject(n)){console.log("Params argument must be an object");return}const a=new URL(location.href);this.luigi.getConfigValue("routing.useHashRouting")?a.hash=O.addParamsOnHashRouting(n,a.hash):O.modifySearchParams(n,a.searchParams),this.handleBrowserHistory(r,a),this.luigi.configChanged()}getSearchParams(){const n={},r=["__proto__","constructor","prototype"],a=new URL(location.href);let u;if(this.luigi.getConfigValue("routing.useHashRouting")){const c=a.hash.split("?")[1];u=c?new URLSearchParams(c).entries():[]}else u=a.searchParams.entries();for(const[c,l]of u){if(r.some(d=>c===d)){console.warn(`Blocked because of potentially dangerous query param: ${c}`);continue}n[c]=l}return n}handleBrowserHistory(n,r){const a=this.sanitizeUrl(r.href);if(!a){console.warn("invalid url: "+a);return}n?window.history.pushState({},"",a):window.history.replaceState({},"",a)}sanitizeUrl(n){return new URL(location.href).origin===new URL(n).origin?n:void 0}addNodeParams(n,r){if(!M.isObject(n)){console.log("Params argument must be an object");return}const a=O.getContentViewParamPrefix(this.luigi),u=new URL(location.href);this.luigi.getConfigValue("routing.useHashRouting")?u.hash=O.addParamsOnHashRouting(n,u.hash,a):O.modifySearchParams(n,u.searchParams,a),this.handleBrowserHistory(r,u),this.luigi.getConfigValue("routing.useHashRouting")?window.dispatchEvent(new HashChangeEvent("hashchange")):this.luigi.configChanged()}}class fw{#e;#h="";constructor(n){this.#e=n}async getAvailableThemes(){return await this.#e.getConfigValueAsync("settings.theming.themes")}setCurrentTheme(n){this.#h=n,this.#e.__cssVars=void 0}async getThemeObject(n){return(await this.getAvailableThemes())?.find(a=>a.id===n)}getCurrentTheme(){if(!this.isThemingAvailable())return!1;if(this.#h)return this.#h;const n=this.#e.getConfigValue("settings.theming");return n.defaultTheme||console.error("[Theming] getCurrentTheme() error. No theme set and no defaultTheme found in configuration",n),n.defaultTheme}isThemingAvailable(){return!!this.#e.getConfigValue("settings.theming")}async getCSSVariables(){if(!window.Luigi.__cssVars){const n=this.#e.getConfigValue("settings.theming.variables.file");if(n)try{const r=await fetch(n);window.Luigi.__cssVars=(await r.json()).root,Object.keys(window.Luigi.__cssVars).forEach(a=>{const u=getComputedStyle(document.documentElement).getPropertyValue("--"+a);u&&(window.Luigi.__cssVars[a]=u)})}catch(r){M.isFunction(this.#e.getConfigValue("settings.theming.variables.errorHandling"))?this.#e.getConfigValue("settings.theming.variables.errorHandling")(r):console.error("CSS variables file error: ",r)}else this.#e.getConfigValue("settings.theming.variables")==="fiori"&&window.__luigiThemeVars?(window.Luigi.__cssVars={},window.__luigiThemeVars.forEach(r=>{window.Luigi.__cssVars[r]=getComputedStyle(document.documentElement).getPropertyValue("--"+r)})):window.Luigi.__cssVars={}}return window.Luigi.__cssVars}_init(){const n=ne.get(mr);(()=>{const a=this.#e.getConfigValue("settings.theming");a&&a.nodeViewURLDecorator&&a.nodeViewURLDecorator.queryStringParameter&&n.add({type:"queryString",uid:"theming",key:a.nodeViewURLDecorator.queryStringParameter.keyName,valueFn:()=>{const u=this.getCurrentTheme(),c=a.nodeViewURLDecorator.queryStringParameter.value;return c?c(u):u}}),a&&a.useFioriScrollbars===!0&&document.body.classList.add("fioriScrollbars")})()}}class ss{constructor(){this.unsavedChanges={isDirty:!1,persistUrl:null}}updateDirtyStatus(n,r){if(!this.unsavedChanges.dirtySet||!(this.unsavedChanges.dirtySet instanceof Set)){const a=new Set;a.add(r),this.unsavedChanges={dirtySet:a}}this.unsavedChanges.persistUrl=window.location.href,n?this.unsavedChanges.dirtySet?.add(r):this.unsavedChanges.dirtySet?.delete(r)}clearDirtyState(n){this.unsavedChanges&&this.unsavedChanges.dirtySet&&(n?this.unsavedChanges.dirtySet.delete(n):this.unsavedChanges.dirtySet.clear())}readDirtyStatus(){return this.unsavedChanges.dirtySet?this.unsavedChanges.dirtySet.size>0:!!this.unsavedChanges.isDirty}}let Kl;const Pe={luigi:void 0,documentTitle:void 0,init:i=>{console.log("ux init..."),Pe.luigi=i,Pe.documentTitle=ns(void 0),Kl=ne.get(ss)},processAlert:(i,n,r)=>{if(!Pe.luigi)throw new Error("Luigi is not initialized.");const a={openFromClient:n,close:()=>{i.id&&r.notifyAlertClosed(i.id)},link:u=>{if(i.links){const c=i.links[u];if(c&&(c.url&&Pe.luigi?.navigation().navigate(c.url),c.dismissKey&&i.id))return r.notifyAlertClosed(i.id,c.dismissKey),!0}return!1}};Pe.luigi.getEngine()._connector?.renderAlert(i,a)},handleConfirmationModalRequest:(i,n)=>{if(!Pe.luigi)throw new Error("Luigi is not initialized.");i&&(i={...i,header:Pe.luigi.i18n().getTranslation(i.header||"luigi.confirmationModal.header"),body:Pe.luigi.i18n().getTranslation(i.body||"luigi.confirmationModal.body"),buttonDismiss:Pe.luigi.i18n().getTranslation(i.buttonDismiss||"luigi.button.dismiss"),buttonConfirm:Pe.luigi.i18n().getTranslation(i.buttonConfirm||"luigi.button.confirm")}),Pe.luigi.getEngine()._connector?.renderConfirmationModal(i,{confirm(){n.notifyConfirmationModalClosed(!0)},dismiss(){n.notifyConfirmationModalClosed(!1)}})},handleDirtyStatusRequest:(i,n)=>{if(!Pe.luigi)throw new Error("Luigi is not initialized.");Kl.updateDirtyStatus(i,n)}};class dw{processUserSettingGroups(n,r){const a=[],u=n?.userSettingGroups,c=r?.userSettings?.userSettingGroups,l=u||c;if(M.isObject(l)){for(const d in l){const p={};p[d]=l[d],a.push(p)}return a}return a}getUserSettingsIframesInDom(){const n=document.querySelector(".iframeUserSettingsCtn");return n?[...n.children]:[]}hideUserSettingsIframe(){this.getUserSettingsIframesInDom().forEach(n=>{n.style.display="none"})}findActiveCustomUserSettingsIframe(n){const r=document.querySelectorAll("[userSettingsGroup]");for(let a=0;a<r.length;a++)if(r[a].contentWindow===n)return r[a];return null}}const gw=new dw;class pw{constructor(n){this.dirtyStatusService=ne.get(ss),this.appLoadingIndicatorSelector="[luigi-app-loading-indicator]",this.showAlert=r=>new Promise(a=>{r.id||(r.id=M.getRandomId().toString());const u={openFromClient:!1,close:()=>{a(!0)},link:c=>{if(r.links){const l=r.links[c];if(l&&(l.url&&this.luigi?.navigation().navigate(l.url),l.dismissKey))return a(l.dismissKey),!0}return!1}};this.luigi.getEngine()._connector?.renderAlert(r,u)}),this.showConfirmationModal=r=>(r&&(r={...r,header:this.luigi.i18n().getTranslation(r.header||"luigi.confirmationModal.header"),body:this.luigi.i18n().getTranslation(r.body||"luigi.confirmationModal.body"),buttonDismiss:this.luigi.i18n().getTranslation(r.buttonDismiss||"luigi.button.dismiss"),buttonConfirm:this.luigi.i18n().getTranslation(r.buttonConfirm||"luigi.button.confirm")}),new Promise((a,u)=>{this.luigi.getEngine()._connector?.renderConfirmationModal(r,{confirm(){a(!0)},dismiss(){u()}})})),this.processUserSettingGroups=()=>{const r=this.luigi.getConfigValue("userSettings"),a=this.luigi.getConfigValue("settings");return gw.processUserSettingGroups(r,a)},this.openUserSettings=r=>{this.luigi.getEngine()._connector?.openUserSettings(r)},this.closeUserSettings=()=>{this.luigi.getEngine()._connector?.closeUserSettings()},this.setDocumentTitle=r=>{this.luigi.getEngine()._ux?.documentTitle?.set(r),this.luigi.getEngine()._connector?.setDocumentTitle(r)},this.getDocumentTitle=()=>ac(this.luigi.getEngine()._ux?.documentTitle)||window.document.title||"",this.hideAppLoadingIndicator=()=>{const r=document.querySelector(this.appLoadingIndicatorSelector);r&&(r.classList.add("hidden"),setTimeout(()=>{r.parentNode?.removeChild(r)},500))},this.showLoadingIndicator=r=>this.luigi.getEngine()._connector?.showLoadingIndicator(r),this.hideLoadingIndicator=r=>this.luigi.getEngine()._connector?.hideLoadingIndicator(r),this.addBackdrop=()=>this.luigi.getEngine()._connector?.addBackdrop(),this.removeBackdrop=()=>this.luigi.getEngine()._connector?.removeBackdrop(),this.getDirtyStatus=()=>this.dirtyStatusService.readDirtyStatus(),this.luigi=n}}class _w{filterIdFromMessageObject(n){const{id:r,...a}=n;return{id:r,messageWithoutId:a}}}const Yl=new _w;class mw{constructor(n){this.luigi=n}sendToAll(n){const r=ka.getAllLuigiContainerIframe(this.luigi);if(!r){console.warn("No Luigi containers found to send the message to.");return}const{id:a,messageWithoutId:u}=Yl.filterIdFromMessageObject(n);if(!a){console.warn('Message object must contain an "id" property to specify the message type.');return}for(const c of r)c.sendCustomMessage?c.sendCustomMessage(a,u):console.warn("Container does not support sending custom messages:",c)}send(n,r){const a=ka.getAllLuigiContainerIframe(this.luigi);if(!a){console.warn("No Luigi containers found to send the message to.");return}const{id:u,messageWithoutId:c}=Yl.filterIdFromMessageObject(r);if(!u){console.warn('Message object must contain an "id" property to specify the message type.');return}for(const l of a)if(l.luigiMfId===n){l.sendCustomMessage?l.sendCustomMessage(u,c):console.warn("Container does not support sending custom messages:",l);return}console.warn(`No container found with microfrontend ID: ${n}`)}}class vw{constructor(n){this.engine=n,this.initialized=!1,this.configReadyCallback=function(){},this.USER_SETTINGS_KEY="luigi.preferences.userSettings",this.setConfig=r=>{this.config=r,this.setConfigCallback(this.getConfigReadyCallback()),fr.init().then(()=>{this.engine.init(),this.initialized||(this.initialized=!0,uw.luigiAfterInit(this))})},this.getConfig=()=>this.config,this.configChanged=(...r)=>{this.getEngine()._ui.update(r)},this.customMessages=()=>(this._customMessages||(this._customMessages=new mw(this)),this._customMessages),this.i18n=()=>(this._i18n||(this._i18n=new Qv(this)),this._i18n),this.elements=()=>(this._elements||(this._elements=new ow(this)),this._elements),this.navigation=()=>new cw(this),this.ux=()=>new pw(this),this.featureToggles=()=>(this._featureToggles||(this._featureToggles=new lw),this._featureToggles),this.routing=()=>(this._routing||(this._routing=new hw(this)),this._routing),this.theming=()=>(this._theming||(this._theming=new fw(this)),this._theming),this.auth=()=>or,this._store=this.createConfigStore()}getEngine(){return this.engine}getConfigValue(n){return M.getConfigValueFromObject(this.getConfig(),n)}getConfigValueAsync(n,...r){return $n.getConfigValueFromObjectAsync(this.getConfig(),n,r)}clearNavigationCache(){ne.get(_n).deleteCache()}async readUserSettings(){const n=await this.getConfigValueAsync("userSettings"),r=n||await this.getConfigValueAsync("settings.userSettings");if(r&&M.isFunction(r.readUserSettings))return r.readUserSettings();const a=localStorage.getItem(this.USER_SETTINGS_KEY);return a&&JSON.parse(a)}async storeUserSettings(n,r){const a=await this.getConfigValueAsync("userSettings"),u=a||await this.getConfigValueAsync("settings.userSettings");if(u&&M.isFunction(u.storeUserSettings))return u.storeUserSettings(n,r);localStorage.setItem(this.USER_SETTINGS_KEY,JSON.stringify(n)),this.configChanged()}createConfigStore(){const n=ns({}),r={};let a=[];return{subscribe:u=>{a.push(n.subscribe(u))},reset:u=>{n.update(u)},subscribeToScope:(u,c)=>{let l=r[c];l||(l=new Set,r[c]=l),l.add(u)},fire:(u,c)=>{const l=r[u];l&&[...l].forEach(d=>{d(c)})},clear:()=>{a.forEach(u=>{u()}),a=[]}}}getConfigReadyCallback(){return new Promise(n=>{this.i18n()._init(),n()})}setConfigCallback(n){this.configReadyCallback=n}}const ww=!1;var Sw=Array.isArray,Ew=Array.prototype.indexOf,vr=Array.prototype.includes,Cw=Array.from,Tw=Object.defineProperty,zr=Object.getOwnPropertyDescriptor,yw=Object.prototype,Rw=Array.prototype,bw=Object.getPrototypeOf,Xl=Object.isExtensible;const Aw=()=>{};function Pw(i){for(var n=0;n<i.length;n++)i[n]()}function Iw(){var i,n,r=new Promise((a,u)=>{i=a,n=u});return{promise:r,resolve:i,reject:n}}const Fe=2,Zr=4,Cc=8,Tc=1<<24,Xt=16,wn=32,kn=64,Ha=128,mt=512,Ue=1024,Ge=2048,Mt=4096,Yt=8192,gn=16384,ei=32768,Zl=1<<25,as=65536,Wa=1<<17,xw=1<<18,us=1<<19,Lw=1<<20,Hn=65536,Va=1<<21,za=1<<22,Jr=1<<23,$a=Symbol("$state"),Ka=new class extends Error{name="StaleReactionError";message="The reaction that called `getAbortSignal()` was re-run or destroyed"};function Nw(){throw new Error("https://svelte.dev/e/effect_update_depth_exceeded")}function Uw(){throw new Error("https://svelte.dev/e/state_descriptors_fixed")}function Ow(){throw new Error("https://svelte.dev/e/state_prototype_fixed")}function $w(){throw new Error("https://svelte.dev/e/state_unsafe_mutation")}function Dw(){throw new Error("https://svelte.dev/e/svelte_boundary_reset_onerror")}const Be=Symbol();function Mw(){console.warn("https://svelte.dev/e/svelte_boundary_reset_noop")}function Fw(i){return i===this.v}let Ya=!1,kw=!1;function Hw(){Ya=!0}let xt=null;function os(i){xt=i}function Ww(i,n=!1,r){xt={p:xt,i:!1,c:null,e:null,s:i,x:null,r:pe,l:Ya&&!n?{s:null,u:null,$:[]}:null}}function Vw(i){var n=xt,r=n.e;if(r!==null){n.e=null;for(var a of r)rS(a)}return n.i=!0,xt=n.p,{}}function ls(){return!Ya||xt!==null&&xt.l===null}let ur=[];function Bw(){var i=ur;ur=[],Pw(i)}function gr(i){if(ur.length===0){var n=ur;queueMicrotask(()=>{n===ur&&Bw()})}ur.push(i)}function yc(i){var n=pe;if(n===null)return ue.f|=Jr,i;if((n.f&ei)===0&&(n.f&Zr)===0)throw i;lr(i,n)}function lr(i,n){for(;n!==null;){if((n.f&Ha)!==0){if((n.f&ei)===0)throw i;try{n.b.error(i);return}catch(r){i=r}}n=n.parent}throw i}const Gw=-7169;function Te(i,n){i.f=i.f&Gw|n}function Xa(i){(i.f&mt)!==0||i.deps===null?Te(i,Ue):Te(i,Mt)}function Rc(i){if(i!==null)for(const n of i)(n.f&Fe)===0||(n.f&Hn)===0||(n.f^=Hn,Rc(n.deps))}function bc(i,n,r){(i.f&Ge)!==0?n.add(i):(i.f&Mt)!==0&&r.add(i),Rc(i.deps),Te(i,Ue)}const ln=new Set;let Ee=null,Pt=null,Ba=null,Da=!1,cr=null,ji=null;var Jl=0;let Qw=1;class Wn{id=Qw++;current=new Map;previous=new Map;#e=new Set;#h=new Set;#n=new Map;#o=new Map;#r=null;#t=[];#s=[];#i=new Set;#a=new Set;#u=new Map;is_fork=!1;#c=!1;#f=new Set;#d(){return this.is_fork||this.#o.size>0}#g(){for(const a of this.#f)for(const u of a.#o.keys()){for(var n=!1,r=u;r.parent!==null;){if(this.#u.has(r)){n=!0;break}r=r.parent}if(!n)return!0}return!1}skip_effect(n){this.#u.has(n)||this.#u.set(n,{d:[],m:[]})}unskip_effect(n){var r=this.#u.get(n);if(r){this.#u.delete(n);for(var a of r.d)Te(a,Ge),this.schedule(a);for(a of r.m)Te(a,Mt),this.schedule(a)}}#l(){if(Jl++>1e3&&(ln.delete(this),qw()),!this.#d()){for(const d of this.#i)this.#a.delete(d),Te(d,Ge),this.schedule(d);for(const d of this.#a)Te(d,Mt),this.schedule(d)}const n=this.#t;this.#t=[],this.apply();var r=cr=[],a=[],u=ji=[];for(const d of n)try{this.#p(d,r,a)}catch(p){throw Ic(d),p}if(Ee=null,u.length>0){var c=Wn.ensure();for(const d of u)c.schedule(d)}if(cr=null,ji=null,this.#d()||this.#g()){this.#_(a),this.#_(r);for(const[d,p]of this.#u)Pc(d,p)}else{this.#n.size===0&&ln.delete(this),this.#i.clear(),this.#a.clear();for(const d of this.#e)d(this);this.#e.clear(),jl(a),jl(r),this.#r?.resolve()}var l=Ee;if(this.#t.length>0){const d=l??=this;d.#t.push(...this.#t.filter(p=>!d.#t.includes(p)))}l!==null&&(ln.add(l),l.#l()),ln.has(this)||this.#w()}#p(n,r,a){n.f^=Ue;for(var u=n.first;u!==null;){var c=u.f,l=(c&(wn|kn))!==0,d=l&&(c&Ue)!==0,p=d||(c&Yt)!==0||this.#u.has(u);if(!p&&u.fn!==null){l?u.f^=Ue:(c&Zr)!==0?r.push(u):ni(u)&&((c&Xt)!==0&&this.#a.add(u),Sr(u));var _=u.first;if(_!==null){u=_;continue}}for(;u!==null;){var R=u.next;if(R!==null){u=R;break}u=u.parent}}}#_(n){for(var r=0;r<n.length;r+=1)bc(n[r],this.#i,this.#a)}capture(n,r,a=!1){r!==Be&&!this.previous.has(n)&&this.previous.set(n,r),(n.f&Jr)===0&&(this.current.set(n,[n.v,a]),Pt?.set(n,n.v))}activate(){Ee=this}deactivate(){Ee=null,Pt=null}flush(){try{Da=!0,Ee=this,this.#l()}finally{Jl=0,Ba=null,cr=null,ji=null,Da=!1,Ee=null,Pt=null,pn.clear()}}discard(){for(const n of this.#h)n(this);this.#h.clear(),ln.delete(this)}register_created_effect(n){this.#s.push(n)}#w(){for(const R of ln){var n=R.id<this.id,r=[];for(const[T,[E,C]]of this.current){if(R.current.has(T)){var a=R.current.get(T)[0];if(n&&E!==a)R.current.set(T,[E,C]);else continue}r.push(T)}var u=[...R.current.keys()].filter(T=>!this.current.has(T));if(u.length===0)n&&R.discard();else if(r.length>0){R.activate();var c=new Set,l=new Map;for(var d of r)Ac(d,u,c,l);l=new Map;var p=[...R.current.keys()].filter(T=>this.current.has(T)?this.current.get(T)[0]!==T:!0);for(const T of this.#s)(T.f&(gn|Yt|Wa))===0&&Za(T,p,l)&&((T.f&(za|Xt))!==0?(Te(T,Ge),R.schedule(T)):R.#i.add(T));if(R.#t.length>0){R.apply();for(var _ of R.#t)R.#p(_,[],[]);R.#t=[]}R.deactivate()}}for(const R of ln)R.#f.has(this)&&(R.#f.delete(this),R.#f.size===0&&!R.#d()&&(R.activate(),R.#l()))}increment(n,r){let a=this.#n.get(r)??0;if(this.#n.set(r,a+1),n){let u=this.#o.get(r)??0;this.#o.set(r,u+1)}}decrement(n,r,a){let u=this.#n.get(r)??0;if(u===1?this.#n.delete(r):this.#n.set(r,u-1),n){let c=this.#o.get(r)??0;c===1?this.#o.delete(r):this.#o.set(r,c-1)}this.#c||a||(this.#c=!0,gr(()=>{this.#c=!1,this.flush()}))}transfer_effects(n,r){for(const a of n)this.#i.add(a);for(const a of r)this.#a.add(a);n.clear(),r.clear()}oncommit(n){this.#e.add(n)}ondiscard(n){this.#h.add(n)}settled(){return(this.#r??=Iw()).promise}static ensure(){if(Ee===null){const n=Ee=new Wn;Da||(ln.add(Ee),gr(()=>{Ee===n&&n.flush()}))}return Ee}apply(){{Pt=null;return}}schedule(n){if(Ba=n,n.b?.is_pending&&(n.f&(Zr|Cc|Tc))!==0&&(n.f&ei)===0){n.b.defer_effect(n);return}for(var r=n;r.parent!==null;){r=r.parent;var a=r.f;if(cr!==null&&r===pe&&(ue===null||(ue.f&Fe)===0))return;if((a&(kn|wn))!==0){if((a&Ue)===0)return;r.f^=Ue}}this.#t.push(r)}}function qw(){try{Nw()}catch(i){lr(i,Ba)}}let Kt=null;function jl(i){var n=i.length;if(n!==0){for(var r=0;r<n;){var a=i[r++];if((a.f&(gn|Yt))===0&&ni(a)&&(Kt=new Set,Sr(a),a.deps===null&&a.first===null&&a.nodes===null&&a.teardown===null&&a.ac===null&&Hc(a),Kt?.size>0)){pn.clear();for(const u of Kt){if((u.f&(gn|Yt))!==0)continue;const c=[u];let l=u.parent;for(;l!==null;)Kt.has(l)&&(Kt.delete(l),c.push(l)),l=l.parent;for(let d=c.length-1;d>=0;d--){const p=c[d];(p.f&(gn|Yt))===0&&Sr(p)}}Kt.clear()}}Kt=null}}function Ac(i,n,r,a){if(!r.has(i)&&(r.add(i),i.reactions!==null))for(const u of i.reactions){const c=u.f;(c&Fe)!==0?Ac(u,n,r,a):(c&(za|Xt))!==0&&(c&Ge)===0&&Za(u,n,a)&&(Te(u,Ge),Ja(u))}}function Za(i,n,r){const a=r.get(i);if(a!==void 0)return a;if(i.deps!==null)for(const u of i.deps){if(vr.call(n,u))return!0;if((u.f&Fe)!==0&&Za(u,n,r))return r.set(u,!0),!0}return r.set(i,!1),!1}function Ja(i){Ee.schedule(i)}function Pc(i,n){if(!((i.f&wn)!==0&&(i.f&Ue)!==0)){(i.f&Ge)!==0?n.d.push(i):(i.f&Mt)!==0&&n.m.push(i),Te(i,Ue);for(var r=i.first;r!==null;)Pc(r,n),r=r.next}}function Ic(i){Te(i,Ue);for(var n=i.first;n!==null;)Ic(n),n=n.next}function zw(i){let n=0,r=eo(0),a;return()=>{to()&&(hr(r),sS(()=>(n===0&&(a=dS(()=>i(()=>Kr(r)))),n+=1,()=>{gr(()=>{n-=1,n===0&&(a?.(),a=void 0,Kr(r))})})))}}var Kw=as|us;function Yw(i,n,r,a){new Xw(i,n,r,a)}class Xw{parent;is_pending=!1;transform_error;#e;#h=null;#n;#o;#r;#t=null;#s=null;#i=null;#a=null;#u=0;#c=0;#f=!1;#d=new Set;#g=new Set;#l=null;#p=zw(()=>(this.#l=eo(this.#u),()=>{this.#l=null}));constructor(n,r,a,u){this.#e=n,this.#n=r,this.#o=c=>{var l=pe;l.b=this,l.f|=Ha,a(c)},this.parent=pe.b,this.transform_error=u??this.parent?.transform_error??(c=>c),this.#r=aS(()=>{this.#S()},Kw)}#_(){try{this.#t=Ln(()=>this.#o(this.#e))}catch(n){this.error(n)}}#w(n){const r=this.#n.failed;r&&(this.#i=Ln(()=>{r(this.#e,()=>n,()=>()=>{})}))}#C(){const n=this.#n.pending;n&&(this.is_pending=!0,this.#s=Ln(()=>n(this.#e)),gr(()=>{var r=this.#a=document.createDocumentFragment(),a=Dc();r.append(a),this.#t=this.#v(()=>Ln(()=>this.#o(a))),this.#c===0&&(this.#e.before(r),this.#a=null,es(this.#s,()=>{this.#s=null}),this.#m(Ee))}))}#S(){try{if(this.is_pending=this.has_pending_snippet(),this.#c=0,this.#u=0,this.#t=Ln(()=>{this.#o(this.#e)}),this.#c>0){var n=this.#a=document.createDocumentFragment();lS(this.#t,n);const r=this.#n.pending;this.#s=Ln(()=>r(this.#e))}else this.#m(Ee)}catch(r){this.error(r)}}#m(n){this.is_pending=!1,n.transfer_effects(this.#d,this.#g)}defer_effect(n){bc(n,this.#d,this.#g)}is_rendered(){return!this.is_pending&&(!this.parent||this.parent.is_rendered())}has_pending_snippet(){return!!this.#n.pending}#v(n){var r=pe,a=ue,u=xt;Sn(this.#r),Ft(this.#r),os(this.#r.ctx);try{return Wn.ensure(),n()}catch(c){return yc(c),null}finally{Sn(r),Ft(a),os(u)}}#E(n,r){if(!this.has_pending_snippet()){this.parent&&this.parent.#E(n,r);return}this.#c+=n,this.#c===0&&(this.#m(r),this.#s&&es(this.#s,()=>{this.#s=null}),this.#a&&(this.#e.before(this.#a),this.#a=null))}update_pending_count(n,r){this.#E(n,r),this.#u+=n,!(!this.#l||this.#f)&&(this.#f=!0,gr(()=>{this.#f=!1,this.#l&&Uc(this.#l,this.#u)}))}get_effect_pending(){return this.#p(),hr(this.#l)}error(n){var r=this.#n.onerror;let a=this.#n.failed;if(!r&&!a)throw n;this.#t&&(Dt(this.#t),this.#t=null),this.#s&&(Dt(this.#s),this.#s=null),this.#i&&(Dt(this.#i),this.#i=null);var u=!1,c=!1;const l=()=>{if(u){Mw();return}u=!0,c&&Dw(),this.#i!==null&&es(this.#i,()=>{this.#i=null}),this.#v(()=>{this.#S()})},d=p=>{try{c=!0,r?.(p,l),c=!1}catch(_){lr(_,this.#r&&this.#r.parent)}a&&(this.#i=this.#v(()=>{try{return Ln(()=>{var _=pe;_.b=this,_.f|=Ha,a(this.#e,()=>p,()=>l)})}catch(_){return lr(_,this.#r.parent),null}}))};gr(()=>{var p;try{p=this.transform_error(n)}catch(_){lr(_,this.#r&&this.#r.parent);return}p!==null&&typeof p=="object"&&typeof p.then=="function"?p.then(d,_=>lr(_,this.#r&&this.#r.parent)):d(p)})}}function Zw(i){var n=i.effects;if(n!==null){i.effects=null;for(var r=0;r<n.length;r+=1)Dt(n[r])}}function Jw(i){for(var n=i.parent;n!==null;){if((n.f&Fe)===0)return(n.f&gn)===0?n:null;n=n.parent}return null}function ja(i){var n,r=pe;Sn(Jw(i));try{i.f&=~Hn,Zw(i),n=Qc(i)}finally{Sn(r)}return n}function xc(i){var n=i.v,r=ja(i);if(!i.equals(r)&&(i.wv=Bc(),(!Ee?.is_fork||i.deps===null)&&(i.v=r,Ee?.capture(i,n,!0),i.deps===null))){Te(i,Ue);return}wr||(Pt!==null?(to()||Ee?.is_fork)&&Pt.set(i,r):Xa(i))}function jw(i){if(i.effects!==null)for(const n of i.effects)(n.teardown||n.ac)&&(n.teardown?.(),n.ac?.abort(Ka),n.teardown=Aw,n.ac=null,jr(n,0),no(n))}function Lc(i){if(i.effects!==null)for(const n of i.effects)n.teardown&&Sr(n)}let Ga=new Set;const pn=new Map;let Nc=!1;function eo(i,n){var r={f:0,v:i,reactions:null,equals:Fw,rv:0,wv:0};return r}function cn(i,n){const r=eo(i);return cS(r),r}function Nn(i,n,r=!1){ue!==null&&(!It||(ue.f&Wa)!==0)&&ls()&&(ue.f&(Fe|Xt|za|Wa))!==0&&(vt===null||!vr.call(vt,i))&&$w();let a=r?Gr(n):n;return Uc(i,a,ji)}function Uc(i,n,r=null){if(!i.equals(n)){var a=i.v;wr?pn.set(i,n):pn.set(i,a),i.v=n;var u=Wn.ensure();if(u.capture(i,a),(i.f&Fe)!==0){const c=i;(i.f&Ge)!==0&&ja(c),Pt===null&&Xa(c)}i.wv=Bc(),Oc(i,Ge,r),ls()&&pe!==null&&(pe.f&Ue)!==0&&(pe.f&(wn|kn))===0&&(pt===null?hS([i]):pt.push(i)),!u.is_fork&&Ga.size>0&&!Nc&&eS()}return n}function eS(){Nc=!1;for(const i of Ga)(i.f&Ue)!==0&&Te(i,Mt),ni(i)&&Sr(i);Ga.clear()}function Kr(i){Nn(i,i.v+1)}function Oc(i,n,r){var a=i.reactions;if(a!==null)for(var u=ls(),c=a.length,l=0;l<c;l++){var d=a[l],p=d.f;if(!(!u&&d===pe)){var _=(p&Ge)===0;if(_&&Te(d,n),(p&Fe)!==0){var R=d;Pt?.delete(R),(p&Hn)===0&&(p&mt&&(d.f|=Hn),Oc(R,Mt,r))}else if(_){var T=d;(p&Xt)!==0&&Kt!==null&&Kt.add(T),r!==null?r.push(T):Ja(T)}}}}function Gr(i){if(typeof i!="object"||i===null||$a in i)return i;const n=bw(i);if(n!==yw&&n!==Rw)return i;var r=new Map,a=Sw(i),u=cn(0),c=Fn,l=d=>{if(Fn===c)return d();var p=ue,_=Fn;Ft(null),nc(c);var R=d();return Ft(p),nc(_),R};return a&&r.set("length",cn(i.length)),new Proxy(i,{defineProperty(d,p,_){(!("value"in _)||_.configurable===!1||_.enumerable===!1||_.writable===!1)&&Uw();var R=r.get(p);return R===void 0?l(()=>{var T=cn(_.value);return r.set(p,T),T}):Nn(R,_.value,!0),!0},deleteProperty(d,p){var _=r.get(p);if(_===void 0){if(p in d){const R=l(()=>cn(Be));r.set(p,R),Kr(u)}}else Nn(_,Be),Kr(u);return!0},get(d,p,_){if(p===$a)return i;var R=r.get(p),T=p in d;if(R===void 0&&(!T||zr(d,p)?.writable)&&(R=l(()=>{var C=Gr(T?d[p]:Be),A=cn(C);return A}),r.set(p,R)),R!==void 0){var E=hr(R);return E===Be?void 0:E}return Reflect.get(d,p,_)},getOwnPropertyDescriptor(d,p){var _=Reflect.getOwnPropertyDescriptor(d,p);if(_&&"value"in _){var R=r.get(p);R&&(_.value=hr(R))}else if(_===void 0){var T=r.get(p),E=T?.v;if(T!==void 0&&E!==Be)return{enumerable:!0,configurable:!0,value:E,writable:!0}}return _},has(d,p){if(p===$a)return!0;var _=r.get(p),R=_!==void 0&&_.v!==Be||Reflect.has(d,p);if(_!==void 0||pe!==null&&(!R||zr(d,p)?.writable)){_===void 0&&(_=l(()=>{var E=R?Gr(d[p]):Be,C=cn(E);return C}),r.set(p,_));var T=hr(_);if(T===Be)return!1}return R},set(d,p,_,R){var T=r.get(p),E=p in d;if(a&&p==="length")for(var C=_;C<T.v;C+=1){var A=r.get(C+"");A!==void 0?Nn(A,Be):C in d&&(A=l(()=>cn(Be)),r.set(C+"",A))}if(T===void 0)(!E||zr(d,p)?.writable)&&(T=l(()=>cn(void 0)),Nn(T,Gr(_)),r.set(p,T));else{E=T.v!==Be;var N=l(()=>Gr(_));Nn(T,N)}var H=Reflect.getOwnPropertyDescriptor(d,p);if(H?.set&&H.set.call(R,_),!E){if(a&&typeof p=="string"){var W=r.get("length"),ie=Number(p);Number.isInteger(ie)&&ie>=W.v&&Nn(W,ie+1)}Kr(u)}return!0},ownKeys(d){hr(u);var p=Reflect.ownKeys(d).filter(T=>{var E=r.get(T);return E===void 0||E.v!==Be});for(var[_,R]of r)R.v!==Be&&!(_ in d)&&p.push(_);return p},setPrototypeOf(){Ow()}})}var ec,$c;function tS(){if(ec===void 0){ec=window;var i=Element.prototype,n=Node.prototype,r=Text.prototype;zr(n,"firstChild").get,$c=zr(n,"nextSibling").get,Xl(i)&&(i.__click=void 0,i.__className=void 0,i.__attributes=null,i.__style=void 0,i.__e=void 0),Xl(r)&&(r.__t=void 0)}}function Dc(i=""){return document.createTextNode(i)}function Mc(i){return $c.call(i)}function Fc(i){var n=ue,r=pe;Ft(null),Sn(null);try{return i()}finally{Ft(n),Sn(r)}}function nS(i,n){var r=n.last;r===null?n.last=n.first=i:(r.next=i,i.prev=r,n.last=i)}function ti(i,n){var r=pe;r!==null&&(r.f&Yt)!==0&&(i|=Yt);var a={ctx:xt,deps:null,nodes:null,f:i|Ge|mt,first:null,fn:n,last:null,next:null,parent:r,b:r&&r.b,prev:null,teardown:null,wv:0,ac:null};Ee?.register_created_effect(a);var u=a;if((i&Zr)!==0)cr!==null?cr.push(a):Wn.ensure().schedule(a);else if(n!==null){try{Sr(a)}catch(l){throw Dt(a),l}u.deps===null&&u.teardown===null&&u.nodes===null&&u.first===u.last&&(u.f&us)===0&&(u=u.first,(i&Xt)!==0&&(i&as)!==0&&u!==null&&(u.f|=as))}if(u!==null&&(u.parent=r,r!==null&&nS(u,r),ue!==null&&(ue.f&Fe)!==0&&(i&kn)===0)){var c=ue;(c.effects??=[]).push(u)}return a}function to(){return ue!==null&&!It}function rS(i){return ti(Zr|Lw,i)}function iS(i){Wn.ensure();const n=ti(kn|us,i);return(r={})=>new Promise(a=>{r.outro?es(n,()=>{Dt(n),a(void 0)}):(Dt(n),a(void 0))})}function sS(i,n=0){return ti(Cc|n,i)}function aS(i,n=0){var r=ti(Xt|n,i);return r}function Ln(i){return ti(wn|us,i)}function kc(i){var n=i.teardown;if(n!==null){const r=wr,a=ue;tc(!0),Ft(null);try{n.call(null)}finally{tc(r),Ft(a)}}}function no(i,n=!1){var r=i.first;for(i.first=i.last=null;r!==null;){const u=r.ac;u!==null&&Fc(()=>{u.abort(Ka)});var a=r.next;(r.f&kn)!==0?r.parent=null:Dt(r,n),r=a}}function oS(i){for(var n=i.first;n!==null;){var r=n.next;(n.f&wn)===0&&Dt(n),n=r}}function Dt(i,n=!0){var r=!1;(n||(i.f&xw)!==0)&&i.nodes!==null&&i.nodes.end!==null&&(uS(i.nodes.start,i.nodes.end),r=!0),Te(i,Zl),no(i,n&&!r),jr(i,0);var a=i.nodes&&i.nodes.t;if(a!==null)for(const c of a)c.stop();kc(i),i.f^=Zl,i.f|=gn;var u=i.parent;u!==null&&u.first!==null&&Hc(i),i.next=i.prev=i.teardown=i.ctx=i.deps=i.fn=i.nodes=i.ac=i.b=null}function uS(i,n){for(;i!==null;){var r=i===n?null:Mc(i);i.remove(),i=r}}function Hc(i){var n=i.parent,r=i.prev,a=i.next;r!==null&&(r.next=a),a!==null&&(a.prev=r),n!==null&&(n.first===i&&(n.first=a),n.last===i&&(n.last=r))}function es(i,n,r=!0){var a=[];Wc(i,a,!0);var u=()=>{r&&Dt(i),n&&n()},c=a.length;if(c>0){var l=()=>--c||u();for(var d of a)d.out(l)}else u()}function Wc(i,n,r){if((i.f&Yt)===0){i.f^=Yt;var a=i.nodes&&i.nodes.t;if(a!==null)for(const d of a)(d.is_global||r)&&n.push(d);for(var u=i.first;u!==null;){var c=u.next,l=(u.f&as)!==0||(u.f&wn)!==0&&(i.f&Xt)!==0;Wc(u,n,l?r:!1),u=c}}}function lS(i,n){if(i.nodes)for(var r=i.nodes.start,a=i.nodes.end;r!==null;){var u=r===a?null:Mc(r);n.append(r),r=u}}let ts=!1,wr=!1;function tc(i){wr=i}let ue=null,It=!1;function Ft(i){ue=i}let pe=null;function Sn(i){pe=i}let vt=null;function cS(i){ue!==null&&(vt===null?vt=[i]:vt.push(i))}let Ze=null,at=0,pt=null;function hS(i){pt=i}let Vc=1,On=0,Fn=On;function nc(i){Fn=i}function Bc(){return++Vc}function ni(i){var n=i.f;if((n&Ge)!==0)return!0;if(n&Fe&&(i.f&=~Hn),(n&Mt)!==0){for(var r=i.deps,a=r.length,u=0;u<a;u++){var c=r[u];if(ni(c)&&xc(c),c.wv>i.wv)return!0}(n&mt)!==0&&Pt===null&&Te(i,Ue)}return!1}function Gc(i,n,r=!0){var a=i.reactions;if(a!==null&&!(vt!==null&&vr.call(vt,i)))for(var u=0;u<a.length;u++){var c=a[u];(c.f&Fe)!==0?Gc(c,n,!1):n===c&&(r?Te(c,Ge):(c.f&Ue)!==0&&Te(c,Mt),Ja(c))}}function Qc(i){var n=Ze,r=at,a=pt,u=ue,c=vt,l=xt,d=It,p=Fn,_=i.f;Ze=null,at=0,pt=null,ue=(_&(wn|kn))===0?i:null,vt=null,os(i.ctx),It=!1,Fn=++On,i.ac!==null&&(Fc(()=>{i.ac.abort(Ka)}),i.ac=null);try{i.f|=Va;var R=i.fn,T=R();i.f|=ei;var E=i.deps,C=Ee?.is_fork;if(Ze!==null){var A;if(C||jr(i,at),E!==null&&at>0)for(E.length=at+Ze.length,A=0;A<Ze.length;A++)E[at+A]=Ze[A];else i.deps=E=Ze;if(to()&&(i.f&mt)!==0)for(A=at;A<E.length;A++)(E[A].reactions??=[]).push(i)}else!C&&E!==null&&at<E.length&&(jr(i,at),E.length=at);if(ls()&&pt!==null&&!It&&E!==null&&(i.f&(Fe|Mt|Ge))===0)for(A=0;A<pt.length;A++)Gc(pt[A],i);if(u!==null&&u!==i){if(On++,u.deps!==null)for(let N=0;N<r;N+=1)u.deps[N].rv=On;if(n!==null)for(const N of n)N.rv=On;pt!==null&&(a===null?a=pt:a.push(...pt))}return(i.f&Jr)!==0&&(i.f^=Jr),T}catch(N){return yc(N)}finally{i.f^=Va,Ze=n,at=r,pt=a,ue=u,vt=c,os(l),It=d,Fn=p}}function fS(i,n){let r=n.reactions;if(r!==null){var a=Ew.call(r,i);if(a!==-1){var u=r.length-1;u===0?r=n.reactions=null:(r[a]=r[u],r.pop())}}if(r===null&&(n.f&Fe)!==0&&(Ze===null||!vr.call(Ze,n))){var c=n;(c.f&mt)!==0&&(c.f^=mt,c.f&=~Hn),Xa(c),jw(c),jr(c,0)}}function jr(i,n){var r=i.deps;if(r!==null)for(var a=n;a<r.length;a++)fS(i,r[a])}function Sr(i){var n=i.f;if((n&gn)===0){Te(i,Ue);var r=pe,a=ts;pe=i,ts=!0;try{(n&(Xt|Tc))!==0?oS(i):no(i),kc(i);var u=Qc(i);i.teardown=typeof u=="function"?u:null,i.wv=Vc;var c;ww&&kw&&(i.f&Ge)!==0&&i.deps}finally{ts=a,pe=r}}}function hr(i){var n=i.f,r=(n&Fe)!==0;if(ue!==null&&!It){var a=pe!==null&&(pe.f&gn)!==0;if(!a&&(vt===null||!vr.call(vt,i))){var u=ue.deps;if((ue.f&Va)!==0)i.rv<On&&(i.rv=On,Ze===null&&u!==null&&u[at]===i?at++:Ze===null?Ze=[i]:Ze.push(i));else{(ue.deps??=[]).push(i);var c=i.reactions;c===null?i.reactions=[ue]:vr.call(c,ue)||c.push(ue)}}}if(wr&&pn.has(i))return pn.get(i);if(r){var l=i;if(wr){var d=l.v;return((l.f&Ue)===0&&l.reactions!==null||zc(l))&&(d=ja(l)),pn.set(l,d),d}var p=(l.f&mt)===0&&!It&&ue!==null&&(ts||(ue.f&mt)!==0),_=(l.f&ei)===0;ni(l)&&(p&&(l.f|=mt),xc(l)),p&&!_&&(Lc(l),qc(l))}if(Pt?.has(i))return Pt.get(i);if((i.f&Jr)!==0)throw i.v;return i.v}function qc(i){if(i.f|=mt,i.deps!==null)for(const n of i.deps)(n.reactions??=[]).push(i),(n.f&Fe)!==0&&(n.f&mt)===0&&(Lc(n),qc(n))}function zc(i){if(i.v===Be)return!0;if(i.deps===null)return!1;for(const n of i.deps)if(pn.has(n)||(n.f&Fe)!==0&&zc(n))return!0;return!1}function dS(i){var n=It;try{return It=!0,i()}finally{It=n}}const gS=["touchstart","touchmove"];function pS(i){return gS.includes(i)}const Xi=Symbol("events"),_S=new Set,rc=new Set;let ic=null;function sc(i){var n=this,r=n.ownerDocument,a=i.type,u=i.composedPath?.()||[],c=u[0]||i.target;ic=i;var l=0,d=ic===i&&i[Xi];if(d){var p=u.indexOf(d);if(p!==-1&&(n===document||n===window)){i[Xi]=n;return}var _=u.indexOf(n);if(_===-1)return;p<=_&&(l=p)}if(c=u[l]||i.target,c!==n){Tw(i,"currentTarget",{configurable:!0,get(){return c||r}});var R=ue,T=pe;Ft(null),Sn(null);try{for(var E,C=[];c!==null;){var A=c.assignedSlot||c.parentNode||c.host||null;try{var N=c[Xi]?.[a];N!=null&&(!c.disabled||i.target===c)&&N.call(c,i)}catch(H){E?C.push(H):E=H}if(i.cancelBubble||A===n||A===null)break;c=A}if(E){for(let H of C)queueMicrotask(()=>{throw H});throw E}}finally{i[Xi]=n,delete i.currentTarget,Ft(R),Sn(T)}}}function mS(i,n){return vS(i,n)}const Zi=new Map;function vS(i,{target:n,anchor:r,props:a={},events:u,context:c,intro:l=!0,transformError:d}){tS();var p=void 0,_=iS(()=>{var R=r??n.appendChild(Dc());Yw(R,{pending:()=>{}},C=>{Ww({});var A=xt;c&&(A.c=c),u&&(a.$$events=u),p=i(C,a)||{},Vw()},d);var T=new Set,E=C=>{for(var A=0;A<C.length;A++){var N=C[A];if(!T.has(N)){T.add(N);var H=pS(N);for(const Oe of[n,document]){var W=Zi.get(Oe);W===void 0&&(W=new Map,Zi.set(Oe,W));var ie=W.get(N);ie===void 0?(Oe.addEventListener(N,sc,{passive:H}),W.set(N,1)):W.set(N,ie+1)}}}};return E(Cw(_S)),rc.add(E),()=>{for(var C of T)for(const H of[n,document]){var A=Zi.get(H),N=A.get(C);--N==0?(H.removeEventListener(C,sc),A.delete(C),A.size===0&&Zi.delete(H)):A.set(C,N)}rc.delete(E),R!==r&&R.parentNode?.removeChild(R)}});return wS.set(p,_),p}let wS=new WeakMap;const SS="5";typeof window<"u"&&((window.__svelte??={}).v??=new Set).add(SS);Hw();function ES(i){}const Qa={init:i=>{ne.get(Mn).enableRouting()},handlePageErrorHandler:(i,n,r)=>{i&&i.timeout&&setTimeout(()=>{if(i.viewUrl)n.viewUrl=i.viewUrl,r.getEngine()._ui.updateMainContent(n,r);else if(i.errorFn)i.errorFn(n);else{console.warn("Something went wrong with a client! You will be redirected to another page.");const a=i.redirectPath||"/";r.navigation().navigate(a)}},i.timeout)},handleExternalLinkNavigation:i=>{if(i.url)if(i.sameWindow||!1)window.location.href=i.url;else{const r=window.open(i.url,"_blank","noopener noreferrer");r&&(r.opener=null,r.focus())}},async addSearchParamsFromClient(i,n,r){const a=ne.get(vn),u=O.getCurrentPath(r.getConfig().routing?.useHashRouting),l=(await a.getCurrentNode(u.path))?.clientPermissions?.urlParameters,d={...i};if(l){const p={};Object.keys(l).forEach(_=>{_ in d&&l[_]?.write===!0&&(p[_]=d[_],delete d[_])});for(const _ in d)console.warn(`No permission to add the search param "${_}" to the url`);Object.keys(p).length>0&&r.routing().addSearchParams(p,n)}}},$t={luigi:{},init:i=>{console.log("Init communication..."),$t.luigi=i},addListeners:(i,n)=>{i.addEventListener(U.INITIALIZED,r=>{Pe.luigi?.ux().hideLoadingIndicator(i.parentNode)}),i.addEventListener(U.NAVIGATION_REQUEST,r=>{const{drawer:a,link:u,preserveView:c,modal:l,newTab:d,withoutSync:p,preventContextUpdate:_,preventHistoryEntry:R,fromVirtualTreeRoot:T,fromContext:E,fromClosestContext:C,fromParent:A,relative:N,nodeParams:H}=r.detail,W={drawerSettings:a,modalSettings:l,newTab:d,path:u,preserveView:c,preventContextUpdate:_,options:{fromVirtualTreeRoot:T,fromContext:E,fromClosestContext:C,fromParent:A,relative:N,nodeParams:H},preventHistoryEntry:R,withoutSync:p};ne.get(vn).handleNavigationRequest(W,r.callbackFn)}),i.addEventListener(U.RUNTIME_ERROR_HANDLING_REQUEST,r=>{n.navigation().runTimeErrorHandler(r.payload?.data?.errorObj||{})}),i.addEventListener(U.ALERT_REQUEST,r=>{Pe.processAlert(r.payload,!0,i)}),i.addEventListener(U.SHOW_CONFIRMATION_MODAL_REQUEST,r=>{Pe.handleConfirmationModalRequest(r.payload,i)}),i.addEventListener(U.SET_DOCUMENT_TITLE_REQUEST,r=>{$t.luigi.getEngine()._connector?.setDocumentTitle(r.detail.title)}),i.addEventListener(U.SHOW_LOADING_INDICATOR_REQUEST,r=>{$t.luigi.getEngine()._connector?.showLoadingIndicator(i.parentNode)}),i.addEventListener(U.HIDE_LOADING_INDICATOR_REQUEST,r=>{$t.luigi.getEngine()._connector?.hideLoadingIndicator(i.parentNode)}),i.addEventListener(U.ADD_BACKDROP_REQUEST,r=>{$t.luigi.getEngine()._connector?.addBackdrop()}),i.addEventListener(U.REMOVE_BACKDROP_REQUEST,r=>{$t.luigi.getEngine()._connector?.removeBackdrop()}),i.addEventListener(U.SET_DIRTY_STATUS_REQUEST,r=>{Pe.handleDirtyStatusRequest(r.detail?.data?.dirty,r.detail?.source)}),i.addEventListener(U.ADD_NODE_PARAMS_REQUEST,r=>{n.routing().addNodeParams(r.payload.data,r.payload.keepBrowserHistory)}),i.addEventListener(U.OPEN_USER_SETTINGS_REQUEST,r=>{$t.luigi.getEngine()._connector?.openUserSettings(r.detail)}),i.addEventListener(U.CLOSE_USER_SETTINGS_REQUEST,r=>{$t.luigi.getEngine()._connector?.closeUserSettings()}),i.addEventListener(U.ADD_SEARCH_PARAMS_REQUEST,r=>{Qa.addSearchParamsFromClient(r.detail.data,r.detail.keepBrowserHistory,n)}),i.addEventListener(U.UPDATE_MODAL_SETTINGS_REQUEST,r=>{Z.updateModalSettings(r.payload.updatedModalSettings,r.payload.addHistoryEntry,n)}),i.addEventListener(U.SET_CURRENT_LOCALE_REQUEST,r=>{n.i18n().setCurrentLocale(r.detail?.data?.data?.currentLocale,i)})}};class CS{constructor(){this._ui=Z,this._comm=$t,this._ux=Pe,this._routing=Qa}bootstrap(n){this._app=mS(ES,{target:document.body}),this._connector=n}init(){const n=window.Luigi;ne.register(ss,()=>new ss),ne.register(vn,()=>new vn(n)),ne.register(_n,()=>new _n),ne.register(Mn,()=>new Mn(n)),ne.register(mr,()=>new mr),ne.register(mn,()=>new mn(n)),n.theming()._init(),Z.init(n),Qa.init(n),$t.init(n),Pe.init(n)}}window.Luigi=new vw(new CS);
94
+ Please refer to documentation`),[w]}}buildVirtualViewUrl(t,n,s){let a="";for(const u in n)u.startsWith("virtualSegment")&&(a+=":"+u+"/");if(!s)return t;a+=":virtualSegment_"+s+"/";let l=t;t.includes("{virtualTreePath}")?l=t.replace("{virtualTreePath}",a):l=t+"/"+a;try{if(new URL(l,"http://dummy-base").origin===new URL(t,"http://dummy-base").origin)return l}catch(u){console.error("Error building virtual view URL -- make sure virtualTreePath is not part of origin.",u)}return t}async buildPath(t,n){const{fromVirtualTreeRoot:s,fromContext:a,fromClosestContext:l,fromParent:u,relative:f,nodeParams:h}=n,g=this.luigi.getConfigValue("routing.useHashRouting"),{path:_,query:w}=D.getCurrentPath(this.luigi,g),m=_+(w?"?"+w:""),E=await this.getPathData(m),b=E.nodesInPath;let R=t;if(b===void 0)return console.warn("No nodes in path found for current path:",m),R;if(s){R="";const I=[...b].map((N,$)=>N.virtualTree?$:-1).filter(N=>N!==-1).pop();b.forEach((N,$)=>{N.pathSegment&&(I===void 0||$<=I)&&(R+="/"+N.pathSegment)}),R+="/"+t}else if(a){const I=a,N=[...b].reverse().find($=>I===$.navigationContext);R=D.concatenatePath(D.getSubPath(N,E.pathParams),t)}else if(l){const I=[...b].reverse().find(N=>N.navigationContext&&N.navigationContext.length>0);R=D.concatenatePath(D.getSubPath(I,E.pathParams),t)}else u?R=D.concatenatePath(D.getSubPath(E.selectedNode?.parent,E.pathParams),t):f&&(R=D.concatenatePath(D.getSubPath(E.selectedNode,E.pathParams),t));return h&&Object.keys(h).length>0&&(R+=R.includes("?")?"&":"?",Object.entries(h).forEach((I,N)=>{R+=encodeURIComponent(D.getContentViewParamPrefix(this.luigi)+I[0])+"="+encodeURIComponent(I[1])+(N<Object.keys(h).length-1?"&":"")})),R}async buildContextSwitcher(){const t=this.luigi.getConfigValue("navigation.contextSwitcher");if(!t)return;Qe.resetFallbackLabelCache();const n=await this.luigi.getConfigValueAsync("navigation.contextSwitcher.actions"),s=await Qe.fetchOptions(this.luigi),a=this.luigi.getConfig().routing?.useHashRouting,l=D.getCurrentPath(this.luigi,a),u=t.parentNodePath,f=t.fallbackLabelResolver;let h=await Qe.getSelectedLabel(l?.path,s,u,f,this.luigi),g=Qe.getSelectedNode(l?.path,s,u),_=Qe.getSelectedOption(l?.path,s,u);const w=(m,E)=>{if(!(!m||typeof m!="string"))if(E==="action"){const b=n.find(R=>R.link===m);if(b?.clickHandler&&!b.clickHandler(b))return;this.luigi.navigation().navigate(m)}else this.luigi.navigation().navigate(m)};if(t?.preserveSubPathOnSwitch&&s?.length&&_&&s.forEach(m=>{m.linkFromPath=Qe.getNodePathFromCurrentPath(m,_,this.luigi),m.link===_.link&&(_.linkFromPath=m.linkFromPath)}),!_&&n?.length){const m=n?.find(E=>E.link===`/${l?.path}`);m&&(h=m.label,g=m.link,_=m)}return{actions:n,config:t,options:s,selectedLabel:h,selectedNodePath:g,selectedOption:_,switcherChange:(m,E)=>w(m,E)}}}class Ui{constructor(t){this.luigi=t,this.preloadBatchSize=1,this.shouldPreload=!1}preloadViewGroups(t=3,n){const s=this.luigi.getConfigValue("navigation.preloadViewGroups"),a=this.luigi.getConfigValue("navigation.viewGroupSettings"),l=this.luigi.getEngine()._connector?.getContainerWrapper();if(s===!1||!a||!l)return;const u=Date.now();if(this.getPreloadingContainers(l).filter(_=>u-(_._luigiPreloadCreatedAt||0)<3e4).length>0){console.log("skipping view group preloading (busy)");return}const h=[...l.childNodes].filter(_=>_.tagName?.startsWith("LUIGI-")&&_.viewGroup).map(_=>_.viewGroup),g=Object.entries(a).filter(([_])=>!h.includes(_)).filter(([_,w])=>w&&w.preloadUrl);n?g.forEach(([_,w])=>{w.loadOnStartup&&this.preloadContainerOnBackground(w,_,l)}):g.filter((_,w)=>w<t).forEach(([_,w])=>{this.preloadContainerOnBackground(w,_,l)})}preloadContainerOnBackground(t,n,s){const a=document.createElement("luigi-container");a.setAttribute("lui_container","true"),a.viewurl=t.preloadUrl,a.viewGroup=n,a.style.display="none",a._luigiPreloading=!0,a._luigiPreloadCreatedAt=Date.now(),a.luigiMfId=M.getRandomId(),this.luigi.getEngine()._comm.addListeners(a,this.luigi),s.appendChild(a)}preload(t){this.shouldPreload&&setTimeout(()=>{this.preloadViewGroups(this.preloadBatchSize,!!t)},t?1:0),this.shouldPreload=!0}viewGroupLoaded(t){if(t._luigiPreloading){const n=Date.now()-(t._luigiPreloadCreatedAt||0);let s=1;n<500?s=3:n<1e3&&(s=2),this.preloadBatchSize=s,setTimeout(()=>{t._luigiPreloading=!1},this.preloadBatchSize>2?500:1e3)}}getPreloadingContainers(t){return[...t.childNodes].filter(n=>n.tagName?.startsWith("LUIGI-")&&n._luigiPreloading)}}const zl={listeners:[],hashChangeWithoutSync:!1,addEventListener(r,t){this.listeners.push({type:r,listenerFn:t}),window.addEventListener(r,t)},removeEventListener(r,t){this.listeners=this.listeners.filter(n=>!(n.type===r&&n.listenerFn===t)),window.removeEventListener(r,t)},removeAllEventListeners(){this.listeners.forEach(r=>{window.removeEventListener(r.type,r.listenerFn)}),this.listeners=[]}};class Vr{constructor(t){this.luigi=t}getNavigationService(){return this.navigationService||(this.navigationService=j.get(dr),this.dirtyStatusService=j.get(un)),this.navigationService}shouldSkipRoutingForUrlPatterns(){const t=[/access_token=/,/id_token=/];return(this.luigi.getConfigValue("routing.skipRoutingForUrlPatterns")||t).filter(s=>location.href.match(s)).length!==0}enableRouting(){this.luigi.getConfig().routing?.useHashRouting?(zl.addEventListener("hashchange",n=>{const s=!!n?.detail?.preventContextUpdate,a=!!n?.detail?.withoutSync;this.handleRouteChange(D.getCurrentPath(this.luigi,!0,!0),a,s)}),this.handleRouteChange(D.getCurrentPath(this.luigi,!0,!0))):(zl.addEventListener("popstate",n=>{const s=!!n?.detail?.preventContextUpdate,a=!!n?.detail?.withoutSync;this.handleRouteChange(D.getCurrentPath(this.luigi,!1,!0),a,s)}),this.handleRouteChange(D.getCurrentPath(this.luigi,!1,!0)))}async handleRouteChange(t,n=!1,s=!1){const a=t.path,l=t.query,u=a+(l?"?"+l:""),f=new URLSearchParams(l),h=Object.create(null);try{if(this.dirtyStatusService?.shouldShowUnsavedChangesModal()){const R=window.location.href,I=this.dirtyStatusService.unsavedChanges.persistUrl;I&&history.pushState(window.state,"",I)}}catch{return}if(this.shouldSkipRoutingForUrlPatterns())return;this.setFeatureToggle(u),await this.shouldShowModalPathInUrl(t),f.forEach((R,I)=>{h[I]=R}),this.checkInvalidateCache(this.previousPathData,a);const g=await this.getNavigationService().getPathData(a),_=D.filterNodeParams(h,this.luigi),w=M.getPathWithoutHash(a)||"";this.currentRoute={raw:window.location.href,path:a,nodeParams:_};const m=g?.selectedNode??await this.getNavigationService().getCurrentNode(a),E=m?.viewUrl||"";if(m&&this.previousPathData&&await this.handleViewUrlMisconfigured(m,E,this.previousPathData,w)||await this.handlePageNotFound(m,E,g,a,w))return;const b=this.luigi.getEngine()._connector;if(b?.renderTopNav(await this.getNavigationService().getTopNavData(a,g)),b?.renderLeftNav(await this.getNavigationService().getLeftNavData(a,g)),b?.renderTabNav(await this.getNavigationService().getTabNavData(a,g)),b?.renderBreadcrumbs(await this.getNavigationService().getBreadcrumbData(a,g,R=>{b?.renderBreadcrumbs(R)})),m){const R={nodeParams:_||{},pathParams:g?.pathParams||{},searchParams:D.prepareSearchParamsForClient(m,this.luigi)};this.currentRoute.node=m,this.getNavigationService().onNodeChange(this.previousNode,m),this.previousNode=m,await G.updateMainContent(m,this.luigi,R,n,s),this.previousPathData=g}}getCurrentRoute(){return this.currentRoute}async shouldShowModalPathInUrl(t){this.luigi.getConfigValue("routing.showModalPathInUrl")&&await this.handleBookmarkableModalPath(t)}async handleBookmarkableModalPath(t){const n=j.get(dr),s=j.get(fr),a=new URLSearchParams(t?.query||""),l=D.getModalViewParamName(this.luigi),u=a.get(l);if(u){const f=a.get(`${l}Params`);try{const h=JSON.parse(f||"{}"),{nodeObject:g}=await n.extractDataFromPath(u);document.querySelector(".lui-modal luigi-container")?this.luigi.getEngine()._connector?.updateModalSettings(h):this.luigi.navigation().openAsModal(u,h||g.openNodeInModal)}catch(h){console.error("Error parsing modal settings from URL parameters",h)}}else return await s.closeModalsWithDirtyCheck(),void 0}appendModalDataToUrl(t,n){const s=D.getHashQueryParamSeparator(),a=D.getQueryParams(this.luigi),l=D.getModalViewParamName(this.luigi),u=a[l],f=new URL(location.href),h=this.luigi.getConfigValue("routing.useHashRouting");let g=history.state,_,w;if(h){let[m,E]=f.hash.split("?");_=m,w=D.getURLWithoutModalData(E,l),w&&(_+="?"+w)}else _=f.pathname,w=D.getURLWithoutModalData(f.search,l),w&&(_+="?"+D.getURLWithoutModalData(f.search,l));if(g=D.handleHistoryState(g,_),u!==t){if(a[l]=t,n&&Object.keys(n).length&&(a[`${l}Params`]=JSON.stringify(n)),h){const m=location.hash.indexOf(s);m!==-1&&(f.hash=f.hash.slice(0,m)),f.hash=`${f.hash}${s}${D.encodeParams(a)}`}else f.search=`?${D.encodeParams(a)}`;history.pushState(g,"",f.href)}else{const m=new URL(f);if(h){let E=m.hash.split("?")[0];m.hash=E,w&&(m.hash+="?"+w)}else m.search=w;history.replaceState({},"",m.href),history.pushState(g,"",f.href)}}removeModalDataFromUrl(t){const n=D.getQueryParams(this.luigi),s=D.getModalViewParamName(this.luigi);let a=new URL(location.href);if(this.luigi.getConfigValue("routing.useHashRouting")){let u={};n[s]&&(u[s]=n[s]),n[`${s}Params`]&&(u[`${s}Params`]=n[`${s}Params`]);let f=D.encodeParams(u);a.hash.includes(`?${f}`)?a.hash=a.hash.replace(`?${f}`,""):a.hash.includes(`&${f}`)&&(a.hash=a.hash.replace(`&${f}`,""))}else{let u=new URLSearchParams(a.search.slice(1));u.delete(s),u.delete(`${s}Params`);let f="";Array.from(u.keys()).forEach(h=>{f+=(f===""?"?":"&")+h+"="+u.get(h)}),a.search=f}if(history.state&&history.state.modalHistoryLength>=0&&t){history.state.modalHistoryLength;const u=history.state.pathBeforeHistory;let f=!1;if(window.addEventListener("popstate",h=>{f?(history.replaceState({},"",u),history.pushState({},"",u),history.back()):(history.pushState({},"",u),history.back())},{once:!0}),history.state.historygap===history.length-history.state.modalHistoryLength)history.go(-history.state.modalHistoryLength);else if(history.state.modalHistoryLength>history.length){const h=history.length-1;f=!0,history.go(-h),window.Luigi.preventLoadingModalData=!0}else{const h=history.state.modalHistoryLength;history.go(-h)}}else history.pushState({},"",a.href)}setFeatureToggle(t){const n=this.luigi.getConfigValue("settings.featureToggles.queryStringParam"),s=this.luigi.featureToggles();n&&typeof t=="string"&&D.setFeatureToggles(n,t,s)}updateModalDataInUrl(t,n,s){let a=D.getHashQueryParamSeparator();const l=D.getQueryParams(this.luigi),u=D.getModalViewParamName(this.luigi);l[u]=t,n&&Object.keys(n).length&&(l[`${u}Params`]=JSON.stringify(n));const f=new URL(location.href);if(this.luigi.getConfigValue("routing.useHashRouting")){const g=location.hash.indexOf(a);g!==-1&&(f.hash=f.hash.slice(0,g)),f.hash=`${f.hash}${a}${D.encodeParams(l)}`}else f.search=`?${D.encodeParams(l)}`;s?history.pushState(window.state,"",f.href):history.replaceState(window.state,"",f.href)}checkInvalidateCache(t,n){if(!t)return;const s=j.get(hr);let a=n.split("/");if(t.nodesInPath&&t.nodesInPath.length>0){let l=t.nodesInPath.slice(1),u=!0;for(let f=0;f<l.length;f++){let h=a.length>f?a[f]:void 0,g=l[f];if(h!==g.pathSegment||!u)if(D.isDynamicNode(g)){if(!u||h!==D.getDynamicNodeValue(g,t.pathParams)){s.deleteNodesRecursively(g);break}}else u=!1}}else s.deleteCache()}async handlePageNotFound(t,n,s,a,l){const u=M.getTrimmedUrl(a),f=D.isExistingRoute(u,s);if(!n&&!t?.compound||t?.tabNav?.showAsTabHeader){const h=await D.getDefaultChildNode(s,async(g,_)=>await this.getNavigationService().getChildren(g,_));if(f){const g=M.getTrimmedUrl(a);return this.getNavigationService().handleNavigationRequest({path:`${g?`/${g}`:""}/${h}`,preserveView:void 0,modalSettings:void 0,newTab:!1,withoutSync:!1,preventContextUpdate:!1,preventHistoryEntry:!0}),!1}else{if(h&&s?.nodesInPath&&s.nodesInPath.length>1)return this.showPageNotFoundError(M.trimTrailingSlash(u||"")+"/"+h,l,!0),!0;const g=await D.getDefaultChildNode(s);this.showPageNotFoundError(g,l,!1)}return!0}return f?!1:(this.showPageNotFoundError(s.matchedPath,l,!0),!0)}async showPageNotFoundError(t,n,s=!1){const a=D.getPageNotFoundRedirectResult(n,s,this.luigi);if(a.ignoreLuigiErrorHandling)return;const l=a.path;if(l){if(a.keepURL){const u=this.luigi.getConfig().routing?.useHashRouting,f=D.getCurrentPath(this.luigi,u);f.path=l,this.handleRouteChange(f)}else this.getNavigationService().handleNavigationRequest({path:l});return}D.showRouteNotFoundAlert(n,s,this.luigi),this.getNavigationService().handleNavigationRequest({path:M.addLeadingSlash(t)})}async handleViewUrlMisconfigured(t,n,s,a){const{children:l,intendToHaveEmptyViewUrl:u,compound:f}=t,h=!!l?.length;if(!f&&n.trim()===""&&!h&&!u){if(console.warn("The intended target route can't be accessed since it has neither a viewUrl nor children. This is most likely a misconfiguration."),!(s&&(s.selectedNode?.viewUrl||s.selectedNode&&s.selectedNode.compound))){const g=await this.getNavigationService().getPathData("/"),_=await D.getDefaultChildNode(g);this.showPageNotFoundError(_,a,!1),this.getNavigationService().handleNavigationRequest({path:_})}return!0}return!1}}class Di{constructor(){this.decorators=[]}hasDecorators(){return this.decorators.length>0}add(t){this.decorators=this.decorators.filter(n=>n.uid!==t.uid).concat(t)}applyDecorators(t,n){if(!t)return t;const s=new URL(M.prependOrigin(t)),a=this.decorators.filter(l=>l.type==="queryString");for(let l=0;l<a.length;l++){const u=a[l];s.searchParams.has(u.key)&&s.searchParams.delete(u.key);const f=u.valueFn();s.searchParams.append(u.key,f)}return n&&(s.search=decodeURIComponent(s.search)),s.href}}const xl=async(r,t,n)=>{const s=await t.readUserSettings(),l=r.userSettingsGroup&&typeof s=="object"&&s!==null&&r.userSettingsGroup?s[r.userSettingsGroup]:null,u=n?.nodeParams||{},f=n?.pathParams||{},h=n?.searchParams||{};if(r.webcomponent&&r.viewUrl&&!D.checkWCUrl(r.viewUrl,t))return console.warn(`View URL '${r.viewUrl}' not allowed to be included`),document.createElement("div");if(r.compound){const g=document.createElement("luigi-compound-container");return g.setAttribute("lui_container","true"),g.viewurl=r.viewUrl?j.get(Di).applyDecorators(D.substituteViewUrl(r,f,u,t),r.decodeViewUrl??!1):"",g.webcomponent=r.webcomponent??!1,g.compoundConfig=r.compound,g.context=r.context,g.clientPermissions=r.clientPermissions??{},g.nodeParams=u,g.pathParams=f,g.userSettingsGroup=r.userSettingsGroup,g.userSettings=l,g.searchParams=h,g.activeFeatureToggleList=t.featureToggles().getActiveFeatureToggleList(),g.locale=t.i18n().getCurrentLocale(),g.theme=t.theming().getCurrentTheme(),g.viewGroup=r.viewGroup,g.virtualTree=r.virtualTree||r._virtualTree,g.virtualTreeRootNode=Me.findVirtualTreeRootNode(r),t.getEngine()._comm.addListeners(g,t),g}else{const g=document.createElement("luigi-container");return g.setAttribute("lui_container","true"),g.viewurl=r.viewUrl?j.get(Di).applyDecorators(D.substituteViewUrl(r,f,u,t),r.decodeViewUrl??!1):"",g.webcomponent=r.webcomponent??!1,g.context=r.context,g.authData=ir.getStoredAuthData(),g.clientPermissions=r.clientPermissions??{},g.cssVariables=await t.theming().getCSSVariables(),g.nodeParams=u,g.pathParams=f,g.userSettingsGroup=r.userSettingsGroup,g.userSettings=l,g.searchParams=h,g.activeFeatureToggleList=t.featureToggles().getActiveFeatureToggleList(),g.locale=t.i18n().getCurrentLocale(),g.theme=t.theming().getCurrentTheme(),g.viewGroup=r.viewGroup,g.virtualTree=r.virtualTree||r._virtualTree,g.virtualTreeRootNode=Me.findVirtualTreeRootNode(r),qd(g,t),zd(g,t),t.getEngine()._comm.addListeners(g,t),g.luigiMfId=M.getRandomId(),g}},qd=(r,t)=>{const n=t.getConfigValue("settings.customSandboxRules");if(!n?.length)return;const s=["allow-forms","allow-modals","allow-popups","allow-popups-to-escape-sandbox","allow-same-origin","allow-scripts"],a=n?[...new Set([...s,...n])]:s;r.sandboxRules=a},zd=(r,t)=>{const n=t.getConfigValue("settings.allowRules");n?.length&&(n.forEach((s,a)=>{n[a]=s+(s.indexOf(";")!=-1?"":";")}),r.allowRules=n)},G={navService:void 0,routingService:void 0,luigi:void 0,modalContainer:[],drawerContainer:void 0,init:r=>{G.navService=j.get(dr),G.routingService=j.get(Vr),G.luigi=r,r.getEngine()._connector?.renderMainLayout();const t=j.get(Ui);t.shouldPreload=!0,t.preload(!0),t.shouldPreload=!1},update:async r=>{const t=G.routingService.getCurrentRoute();if(!t)return;const n=!r||r.length===0;if((n||r.includes("settings.header")||r.includes("settings")||r.includes("navigation")||r.includes("navigation.profile")||r.includes("navigation.contextSwitcher")||r.includes("navigation.productSwitcher"))&&G.luigi.getEngine()._connector?.renderTopNav(await G.navService.getTopNavData(t.path)),n||r.includes("navigation")||r.includes("navigation.nodes")||r.includes("navigation.viewgroupdata")||r.includes("settings")||r.includes("settings.footer")){j.get(hr).deleteCache(),G.luigi.getEngine()._connector?.renderLeftNav(await G.navService.getLeftNavData(t.path)),G.luigi.getEngine()._connector?.renderTabNav(await G.navService.getTabNavData(t.path));const s=G.luigi.getEngine()._connector;s?.renderBreadcrumbs(await G.navService.getBreadcrumbData(t.path,void 0,a=>{s?.renderBreadcrumbs(a)}))}if(n||r.includes("navigation")||r.includes("navigation.nodes")||r.includes("navigation.viewgroupdata")){if(j.get(hr).deleteCache(),t.path){const a=(await G.navService.getPathData(t.path))?.selectedNode??t.node;a&&(t.node=a,G.updateMainContent(a,G.luigi))}}else r.includes("settings.theming")&&t.node&&G.updateMainContent(t.node,G.luigi)},updateMainContent:async(r,t,n,s,a)=>{const l=await t.readUserSettings(),f=r.userSettingsGroup&&typeof l=="object"&&l!==null&&r.userSettingsGroup?l[r.userSettingsGroup]:null,h=t.getEngine()._connector?.getContainerWrapper();t.getEngine()._connector?.hideLoadingIndicator(h);const g=n?.nodeParams||{},_=n?.pathParams||{},w=n?.searchParams||{};if(r&&h){let m,E;if((r.virtualTree||r._virtualTree)&&(E=Me.findVirtualTreeRootNode(r)),[...h.childNodes].forEach(b=>{if(b.tagName?.indexOf("LUIGI-")===0)if(b.viewGroup&&r.viewGroup!==b.viewGroup){b.style.display="none";const R=t.getConfigValue("navigation.viewGroupSettings")?.[b.viewGroup];R?.preloadUrl&&(b.viewurl=R.preloadUrl,b.context={},b.nodeParams={},b.pathParams={})}else b.viewGroup||b.virtualTree&&E===b.virtualTreeRootNode?m=b:b.remove()}),m&&m._luigiPreloading&&(m._luigiPreloading=!1,j.get(Ui).viewGroupLoaded(m)),m)s||(m.style.display="block",m.viewurl=r.viewUrl?j.get(Di).applyDecorators(D.substituteViewUrl(r,_,g,t),r.decodeViewUrl??!1):"",m.nodeParams=g,m.pathParams=_,m.clientPermissions=r.clientPermissions,m.searchParams=w,m.locale=t.i18n().getCurrentLocale(),m.theme=t.theming().getCurrentTheme(),m.activeFeatureToggleList=t.featureToggles().getActiveFeatureToggleList(),m.userSettingsGroup=r.userSettingsGroup,m.userSettings=f,qd(m,t),zd(m,t)),a||m.updateContext(r.context||{},{withoutSync:!1});else{const b=await xl(r,t,n);h?.appendChild(b);const R=t.getEngine()._connector;r.loadingIndicator?.enabled!==!1&&R?.showLoadingIndicator(h)}}},openModal:async(r,t,n,s)=>{const a=await xl(t,r);G.modalContainer.push(a);const l=j.get(Vr),u=j.get(fr),f=j.get(un);let h=!1,g,_;const m=new Promise(R=>{g=()=>{h||(h=!0,R(),u.removeLastModalFromStack())},_=async()=>{try{await f.getUnsavedChangesModalPromise(a)}catch{return}g&&g(),r.getConfigValue("routing.showModalPathInUrl")&&u.getModalStackLength()===0&&l.removeModalDataFromUrl(!0)},a.addEventListener(k.CLOSE_CURRENT_MODAL_REQUEST,_)}),E={closePromise:m,resolveFn:g,onCloseRequestHandler:_,onInternalClose:()=>{try{f.clearDirtyState(a),E.resolveFn&&E.resolveFn()}catch(R){console.warn("onInternalClose failed",R)}},modalsettings:n};u.registerModal(E),r.getEngine()._connector?.renderModal(a,n,async()=>{try{await f.getUnsavedChangesModalPromise(a)}catch{return}s?.(),g&&g(),r.getConfigValue("routing.showModalPathInUrl")&&u.getModalStackLength()===0&&l.removeModalDataFromUrl(!0)},()=>m);const b=r.getEngine()._connector;t.loadingIndicator?.enabled!==!1&&b?.showLoadingIndicator(a.parentElement)},updateModalSettings:(r,t,n)=>{const s=j.get(fr);if(s.getModalStackLength()===0)return;s.updateFirstModalSettings(r);const a=j.get(Vr),l=D.getModalPathFromPath(n);l&&a.updateModalDataInUrl(l,s.getModalSettings(),t),n.getEngine()._connector?.updateModalSettings(s.getModalSettings())},openDrawer:async(r,t,n,s)=>{const a=j.get(un);if(G.drawerContainer&&a.shouldShowUnsavedChangesModal(G.drawerContainer))try{await a.getUnsavedChangesModalPromise(G.drawerContainer)}catch{return}const l=await xl(t,r);G.drawerContainer=l;const u=new Promise(h=>{const g=async()=>{try{await a.getUnsavedChangesModalPromise(l)}catch{return}G.drawerContainer=void 0,a.clearDirtyState(l),h()};l.addEventListener(k.CLOSE_CURRENT_MODAL_REQUEST,g)});r.getEngine()._connector?.renderDrawer(l,n,async()=>{try{await a.getUnsavedChangesModalPromise(l)}catch{return}s?.(),G.drawerContainer=void 0,a.clearDirtyState(l)},()=>u);const f=r.getEngine()._connector;t.loadingIndicator?.enabled!==!1&&f?.showLoadingIndicator(l.parentElement)}};class iC{constructor(){this._userInfoStore=ka({}),this._loggedInStore=ka(!1)}setUserInfo(t){this._userInfoStore.set(t)}setLoggedIn(t){this._loggedInStore.set(t)}getUserInfoStore(){return this._userInfoStore}getLoggedInStore(){return this._loggedInStore}async init(){const t=ot.getConfigValue("auth.use");if(!t)return Promise.resolve(!0);const n=ot.getConfigValue(`auth.${t}`),s=ir.parseUrlAuthErrors()||{};if(await ir.handleUrlAuthErrors(n,s.error,s.errorDescription))return this.idpProviderInstance=this.getIdpProviderInstance(t,n),M.isPromise(this.idpProviderInstance)?this.idpProviderInstance.then(l=>(this.idpProviderInstance=l,this.checkAuth(n))).catch(l=>{const u=`Error: ${l.message||l}`;console.error(u,l.message&&l),ot.setErrorMessage(u)}):this.checkAuth(n)}async checkAuth(t){const n=ir.getStoredAuthData();if(!n||!ir.isLoggedIn()){if(ot.getConfigValue("auth.disableAutoLogin"))return;let a=!0;return n&&(a=await vi.handleAuthEvent("onAuthExpired",t)),a?this.startAuthorization():void 0}this.idpProviderInstance.settings&&M.isFunction(this.idpProviderInstance.settings.userInfoFn)?this.idpProviderInstance.settings.userInfoFn(this.idpProviderInstance.settings,n).then(a=>{this.setUserInfo(a),this.setLoggedIn(!0)}):M.isFunction(this.idpProviderInstance.userInfo)?this.idpProviderInstance.userInfo(t).then(a=>{this.setUserInfo(a),this.setLoggedIn(!0)}):(this.setLoggedIn(!0),this.setUserInfo(Bh(this._userInfoStore))),M.isFunction(ot.getConfigValue("auth.events.onAuthSuccessful"))&&rn.isNewlyAuthorized()&&await vi.handleAuthEvent("onAuthSuccessful",t,n),rn.removeNewlyAuthorized(),M.isFunction(this.idpProviderInstance.setTokenExpirationAction)&&this.idpProviderInstance.setTokenExpirationAction(),M.isFunction(this.idpProviderInstance.setTokenExpireSoonAction)&&this.idpProviderInstance.setTokenExpireSoonAction()}async startAuthorization(){if(this.idpProviderInstance)return this.idpProviderInstance.login().then(t=>{rn.setNewlyAuthorized(),t&&console.error(t)})}logout(){const t=ir.getStoredAuthData(),n=async l=>{await vi.handleAuthEvent("onLogout",this.idpProviderInstance.settings,void 0,l),rn.removeAuthData()},s=ot.getConfigValue(`auth.${ot.getConfigValue("auth.use")}.logoutFn`),a=ot.getConfigValueAsync("navigation.profile.logout.customLogoutFn");M.isFunction(s)?s(this.idpProviderInstance.settings,t,n):M.isFunction(this.idpProviderInstance.logout)?this.idpProviderInstance.logout(t,n):a&&M.isFunction(a)?a(t,n):n(this.idpProviderInstance.settings.logoutUrl)}createIdpProviderException(t){return{message:t,name:"IdpProviderException"}}async getIdpProviderInstance(t,n){const s=M.getConfigValueFromObject(n,"idpProvider");if(s){const l=await new s(n);return["login"].forEach(u=>{if(!M.isFunction(l[u]))throw this.createIdpProviderException(`${u} function does not exist in custom IDP Provider ${t}`)}),l}if(M.isFunction(ot.getConfigValue("auth.events.onAuthConfigError")))await vi.handleAuthEvent("onAuthConfigError",{idpProviderName:t,type:"IdpProviderException"});else throw this.createIdpProviderException(`IDP Provider ${t} does not exist.`)}unload(){this.idpProviderInstance&&M.isFunction(this.idpProviderInstance.unload)&&this.idpProviderInstance.unload()}resetExpirationChecks(){this.idpProviderInstance&&M.isFunction(this.idpProviderInstance.resetExpirationChecks)&&this.idpProviderInstance.resetExpirationChecks()}broadcastAuthData(t){const s=ot.getLuigi()?.getEngine()?._connector?.getContainerWrapper();if(s){for(const a of s.childNodes)a.tagName?.startsWith("LUIGI-")&&a.setAttribute("auth-data",JSON.stringify(t));G.modalContainer?.forEach(a=>a.setAttribute("auth-data",JSON.stringify(t))),G.drawerContainer&&G.drawerContainer.setAttribute("auth-data",JSON.stringify(t))}}}const ar=new iC,sC={luigi:{button:{confirm:"Yes",dismiss:"No"},confirmationModal:{body:"Are you sure you want to do this?",header:"Confirmation"},navigation:{up:"Up"},notExactTargetNode:"Could not map the exact target node for the requested route {route}.",requestedRouteNotFound:"Could not find the requested route {route}.",unsavedChangesAlert:{body:"Unsaved changes will be lost. Do you want to continue?",header:"Unsaved changes detected"}}},aC=sC;class oC{constructor(t){this.luigi=t,this.currentLocaleStorageKey="luigi.currentLocale",this.defaultLocale="en",this.listeners={},this.translationTable=aC}_init(){this._initCustomImplementation(),this.addCurrentLocaleChangeListener(t=>{this.broadcastLocaleToAllContainers(t)})}getCurrentLocale(){return sessionStorage.getItem(this.currentLocaleStorageKey)||this.defaultLocale}setCurrentLocale(t){t&&(sessionStorage.setItem(this.currentLocaleStorageKey,t),this._notifyLocaleChange(t)),this.luigi.getEngine()._connector?.setCurrentLocale(t)}addCurrentLocaleChangeListener(t){let n=null;return M.isFunction(t)?(n=M.getRandomId(),this.listeners[n]=t):console.error("Provided locale change listener is not a function."),n}removeCurrentLocaleChangeListener(t){t&&this.listeners[t]?delete this.listeners[t]:console.error("Unable to remove locale change listener - no listener registered for given ID.")}getTranslation(t,n=void 0,s=void 0){if(!t)return"";if(this.translationImpl){const l=this.translationImpl.getTranslation(t,n,s);if(l!==t)return l}const a=this.findTranslation(t,this.translationTable,n);return a||t}_notifyLocaleChange(t){Object.getOwnPropertyNames(this.listeners).forEach(n=>{this.listeners[Number(n)](t)}),this.luigi.configChanged()}_initCustomImplementation(){this.translationImpl=this.luigi.getConfigValue("settings.customTranslationImplementation"),M.isFunction(this.translationImpl)&&(this.translationImpl=this.translationImpl())}broadcastLocaleToAllContainers(t){const n=M.getNodeList("luigi-container[lui_container]");n?.length&&t&&n.forEach(s=>{s.locale=t,s.updateContext({locale:t})})}findTranslation(t,n,s){const a=t.split(".");for(let l=0;l<a.length;l++){const u=a[l];if(Object.prototype.hasOwnProperty.call(n,u)&&typeof n[u]=="object")n=n[u];else return s?this.findInterpolations(n[u],s):n[u]}}findInterpolations(t,n){return typeof t!="string"||!t.trim()||Object.keys(n).forEach(s=>{t=t.replace(new RegExp("{"+Wa.escapeKeyForRegexp(s)+"}","gi"),n[s])}),t}}const Kl={getMicrofrontendsInDom(r){return[...this.getMainMicrofrontends(r).map(t=>({container:t.iframe,active:t.active,type:"main",id:t.id})),...this.getModalMicrofrontends().map(t=>({container:t.iframe,active:t.active,type:"modal",id:t.id})),...(()=>{const t=this.getDrawerMicrofrontends();return t.iframe?[{container:t.iframe,active:t.active,type:"drawer",id:t.id}]:[]})()]},getMainMicrofrontends(r){const t=r.getEngine()._connector?.getContainerWrapper();if(!t)return[];const n=[];for(const s of t.childNodes)if(s.tagName?.startsWith("LUIGI-"))if(s.iframeHandle?.iframe)n.push({iframe:s.iframeHandle.iframe,id:s.luigiMfId,active:M.isElementVisible(s)});else{const a=s.shadowRoot?.firstElementChild?.firstElementChild??null;a&&n.push({iframe:a,id:s.luigiMfId,active:M.isElementVisible(s)})}return n},getModalMicrofrontends(){const r=[];for(const t of G.modalContainer)if(t.iframeHandle?.iframe)r.push({iframe:t.iframeHandle.iframe,id:t.luigiMfId,active:M.isElementVisible(t)});else{const n=t.shadowRoot?.firstElementChild?.firstElementChild??null;n&&r.push({iframe:n,id:t.luigiMfId,active:M.isElementVisible(t)})}return r},getDrawerMicrofrontends(){if(!G.drawerContainer)return{};if(G.drawerContainer.iframeHandle?.iframe)return{iframe:G.drawerContainer.iframeHandle.iframe,id:G.drawerContainer.luigiMfId,active:M.isElementVisible(G.drawerContainer)};{const r=G.drawerContainer.shadowRoot?.firstElementChild?.firstElementChild??null;if(r)return{iframe:r,id:G.drawerContainer.luigiMfId,active:M.isElementVisible(G.drawerContainer)}}return{}},getAllLuigiContainerIframe(r){const t=r.getEngine()._connector?.getContainerWrapper();if(!t)return;const n=[...t.children].filter(s=>s.tagName?.indexOf("LUIGI-CONTAINER")===0&&s.iframeHandle?.iframe);for(const s of G.modalContainer)s.iframeHandle?.iframe&&n.push(s);return G.drawerContainer&&G.drawerContainer.iframeHandle?.iframe&&n.push(G.drawerContainer),n.length>0?n:void 0}};class lC{constructor(t){this.luigi=t}getShellbar(){return this.luigi.getEngine()._connector?.getCoreAPISupportedElements().getShellbarElement()||null}getShellbarActions(){return this.luigi.getEngine()._connector?.getCoreAPISupportedElements().getShellbarActions()||null}getLuigiContainer(){return this.luigi.getEngine()._connector?.getCoreAPISupportedElements().getLuigiContainer()||null}getNavFooterContainer(){return this.luigi.getEngine()._connector?.getCoreAPISupportedElements().getNavFooterContainer()||null}getMicrofrontends(){return Kl.getMicrofrontendsInDom(this.luigi)}getMicrofrontendIframes(){const t=this.luigi.getEngine()._connector?.getContainerWrapper();let n=[];if(G.modalContainer)for(const s of Array.from(G.modalContainer))s.tagName?.startsWith("LUIGI-")&&s.iframeHandle?.iframe&&n.push(s.iframeHandle.iframe);if(G.drawerContainer&&n.push(G.drawerContainer.iframeHandle.iframe),!t)return null;for(const s of Array.from(t.childNodes))s.tagName?.startsWith("LUIGI-")&&s.iframeHandle?.iframe&&n.push(s.iframeHandle.iframe);return n}getCurrentMicrofrontendIframe(){const t=this.luigi.getEngine()._connector?.getContainerWrapper();if(!t)return null;const n=G.modalContainer[0]?.iframeHandle?.iframe??null;let s=null,a=null;for(const l of Array.from(t.children))l.tagName?.startsWith("LUIGI-")&&M.isElementVisible(l)&&(l.iframeHandle?.iframe?s=l.iframeHandle.iframe:a=l.shadowRoot?.firstElementChild?.firstElementChild??null);return n||s||a}}const uC={luigiAfterInit:async r=>{M.getConfigBooleanValue(r.getConfig(),"settings.appLoadingIndicator.hideAutomatically")&&setTimeout(()=>{r.ux().hideAppLoadingIndicator()},0),await ot.executeConfigFnAsync("lifecycleHooks.luigiAfterInit")}};class cC{constructor(){this.featureToggleList=new Set}setFeatureToggle(t,n=!1){this.isValid(t)&&(t.startsWith("!")&&!n||this.isDuplicatedOrDisabled(t)||this.featureToggleList.add(t))}unsetFeatureToggle(t){if(this.isValid(t)){if(!this.featureToggleList.has(t)){console.warn("Feature toggle name is not in the list.");return}this.featureToggleList.delete(t)}}getActiveFeatureToggleList(){return[...Array.from(this.featureToggleList)].filter(n=>!n.startsWith("!"))}isValid(t){return M.isString(t)?!0:(console.warn("Feature toggle name is not valid or not of type 'string'"),!1)}isDuplicatedOrDisabled(t){return this.featureToggleList.has(t)?(console.warn("Feature toggle name already exists"),!0):this.featureToggleList.has(`!${t}`)?(console.warn("Disabled feature toggle can not be activated"),!0):!1}}class fC{constructor(t){this.hashRouting=!1,this.options={fromContext:null,fromClosestContext:!1,fromVirtualTreeRoot:!1,fromParent:!1,nodeParams:{}},this.navigate=async(n,s,a,l,u)=>{const f=n[0]!=="/";this.options.relative=f;const h={modalSettings:a,newTab:!1,options:this.options,path:n,preserveView:s,preventContextUpdate:!1,preventHistoryEntry:!1,withoutSync:!1};return this.navService.handleNavigationRequest(h,void 0)},this.navigateToIntent=(n,s={})=>{let a="#?intent=";if(a+=n,s&&Object.keys(s)?.length){const l=Object.entries(s);if(l.length>0){a+="?";for(const[u,f]of l)a+=u+"="+f+"&";a=a.slice(0,-1)}}this.navigate(a)},this.openAsModal=async(n,s,a)=>{if(!s?.keepPrevious&&!await this.modalService.closeModalsWithDirtyCheck())return;const l=n.replace(/\/\/+/g,"/");if(!await Me.validatePathAndGetRedirect(l,this.luigi))return;const f=await this.navService.getCurrentNode(l),h=s||{};h.title||(h.title=f?.label),this.luigi.getConfigValue("routing.showModalPathInUrl")&&this.modalService.getModalStackLength()===0&&this.routingService.appendModalDataToUrl(l,h),this.luigi.getEngine()._ui.openModal(this.luigi,f,h,a)},this.openAsDrawer=async(n,s,a)=>{const l=n.replace(/\/\/+/g,"/");if(!await Me.validatePathAndGetRedirect(l,this.luigi))return;const f=await this.navService.getCurrentNode(l),h=s||{};if(!h.header?.title){const _=await D.getNodeLabel(f,this.luigi)||"";h.header?h.header.title=_:h.header={title:_}}h.overlap===void 0&&(h.overlap=!0),this.luigi.getEngine()._ui.openDrawer(this.luigi,f,h,a)},this.runTimeErrorHandler=async n=>{const{path:s}=D.getCurrentPath(this.luigi,this.luigi.getConfig().routing?.useHashRouting),a=await this.navService.getCurrentNode(s),l=this.luigi.getConfigValue("navigation.defaults.runTimeErrorHandler");a?.runTimeErrorHandler?.errorFn&&M.isFunction(a?.runTimeErrorHandler?.errorFn)?a.runTimeErrorHandler.errorFn(n,a):l?.errorFn&&M.isFunction(l.errorFn)&&l.errorFn(n,a)},this.pathExists=async n=>await D.pathExists(n,this.luigi),this.luigi=t,this.hashRouting=t.getConfig().routing?.useHashRouting,this.navService=j.get(dr),this.routingService=j.get(Vr),this.modalService=j.get(fr)}fromVirtualTreeRoot(){return this.options.fromContext=null,this.options.fromClosestContext=!1,this.options.fromVirtualTreeRoot=!0,this.options.fromParent=!1,this}fromContext(t){return this.options.fromContext=t,this}fromClosestContext(){return this.options.fromContext=null,this.options.fromClosestContext=!0,this.options.fromParent=!1,this}fromParent(){return this.options.fromContext=null,this.options.fromClosestContext=!1,this.options.fromVirtualTreeRoot=!1,this.options.fromParent=!0,this}withParams(t){return t&&Object.assign(this.options.nodeParams??{},t),this}}class hC{constructor(t){this.luigi=t}addSearchParams(t,n=!1){if(!M.isObject(t)){console.log("Params argument must be an object");return}const s=new URL(location.href);this.luigi.getConfigValue("routing.useHashRouting")?s.hash=D.addParamsOnHashRouting(t,s.hash):D.modifySearchParams(t,s.searchParams),this.handleBrowserHistory(n,s),this.luigi.configChanged()}getSearchParams(){const t={},n=["__proto__","constructor","prototype"],s=new URL(location.href);let a;if(this.luigi.getConfigValue("routing.useHashRouting")){const l=s.hash.split("?")[1];a=l?new URLSearchParams(l).entries():[]}else a=s.searchParams.entries();for(const[l,u]of a){if(n.some(f=>l===f)){console.warn(`Blocked because of potentially dangerous query param: ${l}`);continue}t[l]=u}return t}handleBrowserHistory(t,n){const s=this.sanitizeUrl(n.href);if(!s){console.warn("invalid url: "+s);return}t?window.history.pushState({},"",s):window.history.replaceState({},"",s)}sanitizeUrl(t){return new URL(location.href).origin===new URL(t).origin?t:void 0}addNodeParams(t,n){if(!M.isObject(t)){console.log("Params argument must be an object");return}const s=D.getContentViewParamPrefix(this.luigi),a=new URL(location.href);this.luigi.getConfigValue("routing.useHashRouting")?a.hash=D.addParamsOnHashRouting(t,a.hash,s):D.modifySearchParams(t,a.searchParams,s),this.handleBrowserHistory(n,a),this.luigi.getConfigValue("routing.useHashRouting")?window.dispatchEvent(new HashChangeEvent("hashchange")):this.luigi.configChanged()}}class dC{#e;#n="";constructor(t){this.#e=t}async getAvailableThemes(){return await this.#e.getConfigValueAsync("settings.theming.themes")}setCurrentTheme(t){this.#n=t,this.#e.__cssVars=void 0}async getThemeObject(t){return(await this.getAvailableThemes())?.find(s=>s.id===t)}getCurrentTheme(){if(!this.isThemingAvailable())return!1;if(this.#n)return this.#n;const t=this.#e.getConfigValue("settings.theming");return t.defaultTheme||console.error("[Theming] getCurrentTheme() error. No theme set and no defaultTheme found in configuration",t),t.defaultTheme}isThemingAvailable(){return!!this.#e.getConfigValue("settings.theming")}async getCSSVariables(){if(!window.Luigi.__cssVars){const t=this.#e.getConfigValue("settings.theming.variables.file");if(t)try{const n=await fetch(t);window.Luigi.__cssVars=(await n.json()).root,Object.keys(window.Luigi.__cssVars).forEach(s=>{const a=getComputedStyle(document.documentElement).getPropertyValue("--"+s);a&&(window.Luigi.__cssVars[s]=a)})}catch(n){M.isFunction(this.#e.getConfigValue("settings.theming.variables.errorHandling"))?this.#e.getConfigValue("settings.theming.variables.errorHandling")(n):console.error("CSS variables file error: ",n)}else this.#e.getConfigValue("settings.theming.variables")==="fiori"&&window.__luigiThemeVars?(window.Luigi.__cssVars={},window.__luigiThemeVars.forEach(n=>{window.Luigi.__cssVars[n]=getComputedStyle(document.documentElement).getPropertyValue("--"+n)})):window.Luigi.__cssVars={}}return window.Luigi.__cssVars}_init(){const t=j.get(Di);(()=>{const s=this.#e.getConfigValue("settings.theming");s&&s.nodeViewURLDecorator&&s.nodeViewURLDecorator.queryStringParameter&&t.add({type:"queryString",uid:"theming",key:s.nodeViewURLDecorator.queryStringParameter.keyName,valueFn:()=>{const a=this.getCurrentTheme(),l=s.nodeViewURLDecorator.queryStringParameter.value;return l?l(a):a}}),s&&s.useFioriScrollbars===!0&&document.body.classList.add("fioriScrollbars")})()}}let Lh;const qe={luigi:void 0,documentTitle:void 0,init:r=>{qe.luigi=r,qe.documentTitle=ka(void 0),Lh=j.get(un)},processAlert:(r,t,n)=>{if(!qe.luigi)throw new Error("Luigi is not initialized.");const s={openFromClient:t,close:()=>{r.id&&n.notifyAlertClosed(r.id)},link:a=>{if(r.links){const l=r.links[a];if(l&&(l.url&&qe.luigi?.navigation().navigate(l.url),l.dismissKey&&r.id))return n.notifyAlertClosed(r.id,l.dismissKey),!0}return!1}};qe.luigi.getEngine()._connector?.renderAlert(r,s)},handleConfirmationModalRequest:(r,t)=>{if(!qe.luigi)throw new Error("Luigi is not initialized.");r&&(r={...r,header:qe.luigi.i18n().getTranslation(r.header||"luigi.confirmationModal.header"),body:qe.luigi.i18n().getTranslation(r.body||"luigi.confirmationModal.body"),buttonDismiss:qe.luigi.i18n().getTranslation(r.buttonDismiss||"luigi.button.dismiss"),buttonConfirm:qe.luigi.i18n().getTranslation(r.buttonConfirm||"luigi.button.confirm")}),qe.luigi.getEngine()._connector?.renderConfirmationModal(r,{confirm(){t.notifyConfirmationModalClosed(!0)},dismiss(){t.notifyConfirmationModalClosed(!1)}})},handleDirtyStatusRequest:(r,t)=>{if(!qe.luigi)throw new Error("Luigi is not initialized.");Lh.updateDirtyStatus(r,t)}};class gC{processUserSettingGroups(t,n){const s=[],a=t?.userSettingGroups,l=n?.userSettings?.userSettingGroups,u=a||l;if(M.isObject(u)){for(const f in u){const h={};h[f]=u[f],s.push(h)}return s}return s}getUserSettingsIframesInDom(){const t=document.querySelector(".iframeUserSettingsCtn");return t?[...t.children]:[]}hideUserSettingsIframe(){this.getUserSettingsIframesInDom().forEach(t=>{t.style.display="none"})}findActiveCustomUserSettingsIframe(t){const n=document.querySelectorAll("[userSettingsGroup]");for(let s=0;s<n.length;s++)if(n[s].contentWindow===t)return n[s];return null}}const pC=new gC;class vC{constructor(t){this.dirtyStatusService=j.get(un),this.appLoadingIndicatorSelector="[luigi-app-loading-indicator]",this.showAlert=n=>new Promise(s=>{n.id||(n.id=M.getRandomId().toString());const a={openFromClient:!1,close:()=>{s(!0)},link:l=>{if(n.links){const u=n.links[l];if(u&&(u.url&&this.luigi?.navigation().navigate(u.url),u.dismissKey))return s(u.dismissKey),!0}return!1}};this.luigi.getEngine()._connector?.renderAlert(n,a)}),this.showConfirmationModal=n=>(n&&(n={...n,header:this.luigi.i18n().getTranslation(n.header||"luigi.confirmationModal.header"),body:this.luigi.i18n().getTranslation(n.body||"luigi.confirmationModal.body"),buttonDismiss:this.luigi.i18n().getTranslation(n.buttonDismiss||"luigi.button.dismiss"),buttonConfirm:this.luigi.i18n().getTranslation(n.buttonConfirm||"luigi.button.confirm")}),new Promise((s,a)=>{this.luigi.getEngine()._connector?.renderConfirmationModal(n,{confirm(){s(!0)},dismiss(){a()}})})),this.processUserSettingGroups=()=>{const n=this.luigi.getConfigValue("userSettings"),s=this.luigi.getConfigValue("settings");return pC.processUserSettingGroups(n,s)},this.openUserSettings=n=>{this.luigi.getEngine()._connector?.openUserSettings(n)},this.closeUserSettings=()=>{this.luigi.getEngine()._connector?.closeUserSettings()},this.setDocumentTitle=n=>{this.luigi.getEngine()._ux?.documentTitle?.set(n),this.luigi.getEngine()._connector?.setDocumentTitle(n)},this.getDocumentTitle=()=>Bh(this.luigi.getEngine()._ux?.documentTitle)||window.document.title||"",this.hideAppLoadingIndicator=()=>{const n=document.querySelector(this.appLoadingIndicatorSelector);n&&(n.classList.add("hidden"),setTimeout(()=>{n.parentNode?.removeChild(n)},500))},this.showLoadingIndicator=n=>this.luigi.getEngine()._connector?.showLoadingIndicator(n),this.hideLoadingIndicator=n=>this.luigi.getEngine()._connector?.hideLoadingIndicator(n),this.addBackdrop=()=>this.luigi.getEngine()._connector?.addBackdrop(),this.removeBackdrop=()=>this.luigi.getEngine()._connector?.removeBackdrop(),this.getDirtyStatus=()=>this.dirtyStatusService.readDirtyStatus(),this.luigi=t}}class _C{filterIdFromMessageObject(t){const{id:n,...s}=t;return{id:n,messageWithoutId:s}}}const Nh=new _C;class mC{constructor(t){this.luigi=t}sendToAll(t){const n=Kl.getAllLuigiContainerIframe(this.luigi);if(!n){console.warn("No Luigi containers found to send the message to.");return}const{id:s,messageWithoutId:a}=Nh.filterIdFromMessageObject(t);if(!s){console.warn('Message object must contain an "id" property to specify the message type.');return}for(const l of n)l.sendCustomMessage?l.sendCustomMessage(s,a):console.warn("Container does not support sending custom messages:",l)}send(t,n){const s=Kl.getAllLuigiContainerIframe(this.luigi);if(!s){console.warn("No Luigi containers found to send the message to.");return}const{id:a,messageWithoutId:l}=Nh.filterIdFromMessageObject(n);if(!a){console.warn('Message object must contain an "id" property to specify the message type.');return}for(const u of s)if(u.luigiMfId===t){u.sendCustomMessage?u.sendCustomMessage(a,l):console.warn("Container does not support sending custom messages:",u);return}console.warn(`No container found with microfrontend ID: ${t}`)}}class wC{constructor(t){this.engine=t,this.initialized=!1,this.configReadyCallback=function(){},this.USER_SETTINGS_KEY="luigi.preferences.userSettings",this.setConfig=n=>{this.config=n,this.setConfigCallback(this.getConfigReadyCallback()),ar.init().then(()=>{this.engine.init(),this.initialized||(this.initialized=!0,uC.luigiAfterInit(this))})},this.getConfig=()=>this.config,this.configChanged=(...n)=>{this.getEngine()._ui.update(n)},this.customMessages=()=>(this._customMessages||(this._customMessages=new mC(this)),this._customMessages),this.i18n=()=>(this._i18n||(this._i18n=new oC(this)),this._i18n),this.elements=()=>(this._elements||(this._elements=new lC(this)),this._elements),this.navigation=()=>new fC(this),this.ux=()=>new vC(this),this.featureToggles=()=>(this._featureToggles||(this._featureToggles=new cC),this._featureToggles),this.routing=()=>(this._routing||(this._routing=new hC(this)),this._routing),this.theming=()=>(this._theming||(this._theming=new dC(this)),this._theming),this.auth=()=>vi,this._store=this.createConfigStore()}getEngine(){return this.engine}getConfigValue(t){return M.getConfigValueFromObject(this.getConfig(),t)}getConfigValueAsync(t,...n){return kr.getConfigValueFromObjectAsync(this.getConfig(),t,n)}clearNavigationCache(){j.get(hr).deleteCache();const t=n=>{n&&n.forEach&&n.forEach(s=>{s.titleResolver&&s.titleResolver._cache&&(s.titleResolver._cache=void 0),s.children&&t(s.children)})};t(this.getConfig().navigation.nodes)}setGlobalContext(t,n){this.config&&this.config.navigation&&(this.config.navigation.globalContext=t,n||this.configChanged("navigation"))}getGlobalContext(){return this.config?.navigation?.globalContext||{}}updateContextValues(t){const n=M.getNodeList("luigi-container[lui_container]");n&&n.forEach(s=>{const l={...s.context||{},...t};s.context=l,s.updateContext&&s.updateContext(l,{withoutSync:!1})})}async readUserSettings(){const t=await this.getConfigValueAsync("userSettings"),n=t||await this.getConfigValueAsync("settings.userSettings");if(n&&M.isFunction(n.readUserSettings))return n.readUserSettings();const s=localStorage.getItem(this.USER_SETTINGS_KEY);return s&&JSON.parse(s)}async storeUserSettings(t,n){const s=await this.getConfigValueAsync("userSettings"),a=s||await this.getConfigValueAsync("settings.userSettings");if(a&&M.isFunction(a.storeUserSettings))return a.storeUserSettings(t,n);localStorage.setItem(this.USER_SETTINGS_KEY,JSON.stringify(t)),this.configChanged()}reset(){const t=this.getConfig();this.unload(),this.setConfig(t)}unload(){this.initialized=!1,window.Luigi._store.clear(),ar.unload(),zl.removeAllEventListeners(),this.getEngine()._connector?.unload(),this._i18n=void 0}createConfigStore(){const t=ka({}),n={};let s=[];return{subscribe:a=>{s.push(t.subscribe(a))},reset:a=>{t.update(a)},subscribeToScope:(a,l)=>{let u=n[l];u||(u=new Set,n[l]=u),u.add(a)},fire:(a,l)=>{const u=n[a];u&&[...u].forEach(f=>{f(l)})},clear:()=>{s.forEach(a=>{a()}),s=[]}}}getConfigReadyCallback(){return new Promise(t=>{this.i18n()._init(),t()})}setConfigCallback(t){this.configReadyCallback=t}}const Kd=!1;var SC=Array.isArray,yC=Array.prototype.indexOf,Mi=Array.prototype.includes,EC=Array.from,CC=Object.defineProperty,gs=Object.getOwnPropertyDescriptor,bC=Object.prototype,TC=Array.prototype,RC=Object.getPrototypeOf,Oh=Object.isExtensible;const AC=()=>{};function PC(r){for(var t=0;t<r.length;t++)r[t]()}function IC(){var r,t,n=new Promise((s,a)=>{r=s,t=a});return{promise:n,resolve:r,reject:t}}const rt=2,Cs=4,jd=8,Yd=1<<24,an=16,gr=32,pr=64,jl=128,qt=512,Je=1024,nt=2048,bn=4096,yn=8192,lr=16384,xs=32768,Uh=1<<25,Ba=65536,Ga=1<<17,xC=1<<18,Ya=1<<19,LC=1<<20,zr=65536,Qa=1<<21,ps=1<<22,bs=1<<23,Ll=Symbol("$state"),NC=Symbol("attributes"),OC=Symbol("class"),UC=Symbol("style"),DC=Symbol("text"),_u=new class extends Error{name="StaleReactionError";message="The reaction that called `getAbortSignal()` was re-run or destroyed"};function MC(){throw new Error("https://svelte.dev/e/effect_update_depth_exceeded")}function kC(){throw new Error("https://svelte.dev/e/state_descriptors_fixed")}function $C(){throw new Error("https://svelte.dev/e/state_prototype_fixed")}function FC(){throw new Error("https://svelte.dev/e/state_unsafe_mutation")}function HC(){throw new Error("https://svelte.dev/e/svelte_boundary_reset_onerror")}const tt=Symbol();function VC(){console.warn("https://svelte.dev/e/derived_inert")}function WC(){console.warn("https://svelte.dev/e/svelte_boundary_reset_noop")}function BC(r){return r===this.v}let mu=!1,GC=!1;function QC(){mu=!0}let fn=null;function qa(r){fn=r}function qC(r,t=!1,n){fn={p:fn,i:!1,c:null,e:null,s:r,x:null,r:Le,l:mu&&!t?{s:null,u:null,$:[]}:null}}function zC(r){var t=fn,n=t.e;if(n!==null){t.e=null;for(var s of n)o0(s)}return t.i=!0,fn=t.p,{}}function Ja(){return!mu||fn!==null&&fn.l===null}let Ei=[];function KC(){var r=Ei;Ei=[],PC(r)}function Ai(r){if(Ei.length===0){var t=Ei;queueMicrotask(()=>{t===Ei&&KC()})}Ei.push(r)}function Jd(r){var t=Le;if(t===null)return ye.f|=bs,r;if((t.f&xs)===0&&(t.f&Cs)===0)throw r;Ci(r,t)}function Ci(r,t){for(;t!==null;){if((t.f&jl)!==0){if((t.f&xs)===0)throw r;try{t.b.error(r);return}catch(n){r=n}}t=t.parent}throw r}const jC=-7169;function Fe(r,t){r.f=r.f&jC|t}function wu(r){(r.f&qt)!==0||r.deps===null?Fe(r,Je):Fe(r,bn)}function Xd(r){if(r!==null)for(const t of r)(t.f&rt)===0||(t.f&zr)===0||(t.f^=zr,Xd(t.deps))}function Zd(r,t,n){(r.f&nt)!==0?t.add(r):(r.f&bn)!==0&&n.add(r),Xd(r.deps),Fe(r,Je)}let Nl=null,di=null,Ie=null,Yl=null,on=null,Jl=null,Ol=!1,bi=null,Ua=null;var Dh=0;let YC=1;class Kr{id=YC++;#e=!1;linked=!0;#n=null;#t=null;async_deriveds=new Map;current=new Map;previous=new Map;unblocked=new Set;#l=new Set;#i=new Set;#o=new Set;#s=0;#r=new Map;#h=null;#a=[];#g=[];#d=new Set;#c=new Set;#f=new Map;#u=new Set;is_fork=!1;#_=!1;#E(){if(this.is_fork)return!0;for(const s of this.#r.keys()){for(var t=s,n=!1;t.parent!==null;){if(this.#f.has(t)){n=!0;break}t=t.parent}if(!n)return!0}return!1}skip_effect(t){this.#f.has(t)||this.#f.set(t,{d:[],m:[]}),this.#u.delete(t)}unskip_effect(t,n=s=>this.schedule(s)){var s=this.#f.get(t);if(s){this.#f.delete(t);for(var a of s.d)Fe(a,nt),n(a);for(a of s.m)Fe(a,bn),n(a)}this.#u.add(t)}#v(){if(this.#e=!0,Dh++>1e3&&(this.#S(),JC()),!this.#E()){for(const h of this.#d)this.#c.delete(h),Fe(h,nt),this.schedule(h);for(const h of this.#c)Fe(h,bn),this.schedule(h)}const t=this.#a;this.#a=[],this.apply();var n=bi=[],s=[],a=Ua=[];for(const h of t)try{this.#C(h,n,s)}catch(g){throw ng(h),g}if(Ie=null,a.length>0){var l=Kr.ensure();for(const h of a)l.schedule(h)}if(bi=null,Ua=null,this.#E()){this.#p(s),this.#p(n);for(const[h,g]of this.#f)tg(h,g);a.length>0&&Ie.#v();return}const u=this.#y();if(u){u.#m(this);return}this.#d.clear(),this.#c.clear();for(const h of this.#l)h(this);this.#l.clear(),Yl=this,Mh(s),Mh(n),Yl=null,this.#h?.resolve();var f=Ie;if(this.linked&&this.#s===0&&this.#S(),this.#a.length>0){f===null&&(f=this,this.#w());const h=f;h.#a.push(...this.#a.filter(g=>!h.#a.includes(g)))}f!==null&&f.#v()}#C(t,n,s){t.f^=Je;for(var a=t.first;a!==null;){var l=a.f,u=(l&(gr|pr))!==0,f=u&&(l&Je)!==0,h=f||(l&yn)!==0||this.#f.has(a);if(!h&&a.fn!==null){u?a.f^=Je:(l&Cs)!==0?n.push(a):Ns(a)&&((l&an)!==0&&this.#c.add(a),ki(a));var g=a.first;if(g!==null){a=g;continue}}for(;a!==null;){var _=a.next;if(_!==null){a=_;break}a=a.parent}}}#y(){for(var t=this.#n;t!==null;){if(!t.is_fork){for(const[n,[,s]]of this.current)if(t.current.has(n)&&!s)return t}t=t.#n}return null}#m(t){for(const[s,a]of t.current)!this.previous.has(s)&&t.previous.has(s)&&this.previous.set(s,t.previous.get(s)),this.current.set(s,a);for(const[s,a]of t.async_deriveds){const l=this.async_deriveds.get(s);l&&a.promise.then(l.resolve)}const n=s=>{var a=s.reactions;if(a!==null)for(const f of a){var l=f.f;if((l&rt)!==0)n(f);else{var u=f;l&(ps|an)&&!this.async_deriveds.has(u)&&(this.#c.delete(u),Fe(u,nt),this.schedule(u))}}};for(const s of this.current.keys())n(s);this.oncommit(()=>t.discard()),t.#S(),Ie=this,this.#v()}#p(t){for(var n=0;n<t.length;n+=1)Zd(t[n],this.#d,this.#c)}capture(t,n,s=!1){t.v!==tt&&!this.previous.has(t)&&this.previous.set(t,t.v),(t.f&bs)===0&&(this.current.set(t,[n,s]),on?.set(t,n)),this.is_fork||(t.v=n)}activate(){Ie=this}deactivate(){Ie=null,on=null}flush(){try{Ol=!0,Ie=this,this.#v()}finally{Dh=0,Jl=null,bi=null,Ua=null,Ol=!1,Ie=null,on=null,Wr.clear()}}discard(){for(const t of this.#i)t(this);this.#i.clear(),this.#o.clear(),this.#S()}register_created_effect(t){this.#g.push(t)}#b(){this.#S();for(let _=Nl;_!==null;_=_.#t){var t=_.id<this.id,n=[];for(const[w,[m,E]]of this.current){if(_.current.has(w)){var s=_.current.get(w)[0];if(t&&m!==s)_.current.set(w,[m,E]);else continue}n.push(w)}if(t)for(const[w,m]of this.async_deriveds){const E=_.async_deriveds.get(w);E&&m.promise.then(E.resolve)}if(_.#e){var a=[..._.current.keys()].filter(w=>!this.current.has(w));if(a.length===0)t&&_.discard();else if(n.length>0){if(t)for(const w of this.#u)_.unskip_effect(w,m=>{(m.f&(an|ps))!==0?_.schedule(m):_.#p([m])});_.activate();var l=new Set,u=new Map;for(var f of n)eg(f,a,l,u);u=new Map;var h=[..._.current.keys()].filter(w=>this.current.has(w)?this.current.get(w)[0]!==w.v:!0);if(h.length>0)for(const w of this.#g)(w.f&(lr|yn|Ga))===0&&Su(w,h,u)&&((w.f&(ps|an))!==0?(Fe(w,nt),_.schedule(w)):_.#d.add(w));if(_.#a.length>0){_.apply();for(var g of _.#a)_.#C(g,[],[]);_.#a=[]}_.deactivate()}}}}increment(t,n){if(this.#s+=1,t){let s=this.#r.get(n)??0;this.#r.set(n,s+1)}}decrement(t,n){if(this.#s-=1,t){let s=this.#r.get(n)??0;s===1?this.#r.delete(n):this.#r.set(n,s-1)}this.#_||(this.#_=!0,Ai(()=>{this.#_=!1,this.linked&&this.flush()}))}transfer_effects(t,n){for(const s of t)this.#d.add(s);for(const s of n)this.#c.add(s);t.clear(),n.clear()}oncommit(t){this.#l.add(t)}ondiscard(t){this.#i.add(t)}on_fork_commit(t){this.#o.add(t)}run_fork_commit_callbacks(){for(const t of this.#o)t(this);this.#o.clear()}settled(){return(this.#h??=IC()).promise}static ensure(){if(Ie===null){const t=Ie=new Kr;t.#w(),Ol||Ai(()=>{t.#e||t.flush()})}return Ie}apply(){{on=null;return}}schedule(t){if(Jl=t,t.b?.is_pending&&(t.f&(Cs|jd|Yd))!==0&&(t.f&xs)===0){t.b.defer_effect(t);return}for(var n=t;n.parent!==null;){n=n.parent;var s=n.f;if(bi!==null&&n===Le&&(ye===null||(ye.f&rt)===0))return;if((s&(pr|gr))!==0){if((s&Je)===0)return;n.f^=Je}}this.#a.push(n)}#w(){di===null?Nl=di=this:(di.#t=this,this.#n=di),di=this}#S(){var t=this.#n,n=this.#t;t===null?Nl=n:t.#t=n,n===null?di=t:n.#n=t,this.linked=!1}}function JC(){try{MC()}catch(r){Ci(r,Jl)}}let $n=null;function Mh(r){var t=r.length;if(t!==0){for(var n=0;n<t;){var s=r[n++];if((s.f&(lr|yn))===0&&Ns(s)&&($n=new Set,ki(s),s.deps===null&&s.first===null&&s.nodes===null&&s.teardown===null&&s.ac===null&&dg(s),$n?.size>0)){Wr.clear();for(const a of $n){if((a.f&(lr|yn))!==0)continue;const l=[a];let u=a.parent;for(;u!==null;)$n.has(u)&&($n.delete(u),l.push(u)),u=u.parent;for(let f=l.length-1;f>=0;f--){const h=l[f];(h.f&(lr|yn))===0&&ki(h)}}$n.clear()}}$n=null}}function eg(r,t,n,s){if(!n.has(r)&&(n.add(r),r.reactions!==null))for(const a of r.reactions){const l=a.f;(l&rt)!==0?eg(a,t,n,s):(l&(ps|an))!==0&&(l&nt)===0&&Su(a,t,s)&&(Fe(a,nt),yu(a))}}function Su(r,t,n){const s=n.get(r);if(s!==void 0)return s;if(r.deps!==null)for(const a of r.deps){if(Mi.call(t,a))return!0;if((a.f&rt)!==0&&Su(a,t,n))return n.set(a,!0),!0}return n.set(r,!1),!1}function yu(r){Ie.schedule(r)}function tg(r,t){if(!((r.f&gr)!==0&&(r.f&Je)!==0)){(r.f&nt)!==0?t.d.push(r):(r.f&bn)!==0&&t.m.push(r),Fe(r,Je);for(var n=r.first;n!==null;)tg(n,t),n=n.next}}function ng(r){Fe(r,Je);for(var t=r.first;t!==null;)ng(t),t=t.next}function XC(r){let t=0,n=Cu(0),s;return()=>{bu()&&(Ti(n),u0(()=>(t===0&&(s=_0(()=>r(()=>vs(n)))),t+=1,()=>{Ai(()=>{t-=1,t===0&&(s?.(),s=void 0,vs(n))})})))}}var ZC=Ba|Ya;function e0(r,t,n,s){new t0(r,t,n,s)}class t0{parent;is_pending=!1;transform_error;#e;#n=null;#t;#l;#i;#o=null;#s=null;#r=null;#h=null;#a=0;#g=0;#d=!1;#c=new Set;#f=new Set;#u=null;#_=XC(()=>(this.#u=Cu(this.#a),()=>{this.#u=null}));constructor(t,n,s,a){this.#e=t,this.#t=n,this.#l=l=>{var u=Le;u.b=this,u.f|=jl,s(l)},this.parent=Le.b,this.transform_error=a??this.parent?.transform_error??(l=>l),this.#i=c0(()=>{this.#y()},ZC)}#E(){try{this.#o=Nr(()=>this.#l(this.#e))}catch(t){this.error(t)}}#v(t){const n=this.#t.failed;n&&(this.#r=Nr(()=>{n(this.#e,()=>t,()=>()=>{})}))}#C(){const t=this.#t.pending;t&&(this.is_pending=!0,this.#s=Nr(()=>t(this.#e)),Ai(()=>{var n=this.#h=document.createDocumentFragment(),s=ug();n.append(s),this.#o=this.#p(()=>Nr(()=>this.#l(s))),this.#g===0&&(this.#e.before(n),this.#h=null,Da(this.#s,()=>{this.#s=null}),this.#m(Ie))}))}#y(){try{if(this.is_pending=this.has_pending_snippet(),this.#g=0,this.#a=0,this.#o=Nr(()=>{this.#l(this.#e)}),this.#g>0){var t=this.#h=document.createDocumentFragment();d0(this.#o,t);const n=this.#t.pending;this.#s=Nr(()=>n(this.#e))}else this.#m(Ie)}catch(n){this.error(n)}}#m(t){this.is_pending=!1,t.transfer_effects(this.#c,this.#f)}defer_effect(t){Zd(t,this.#c,this.#f)}is_rendered(){return!this.is_pending&&(!this.parent||this.parent.is_rendered())}has_pending_snippet(){return!!this.#t.pending}#p(t){var n=Le,s=ye,a=fn;vr(this.#i),Tn(this.#i),qa(this.#i.ctx);try{return Kr.ensure(),t()}catch(l){return Jd(l),null}finally{vr(n),Tn(s),qa(a)}}#b(t,n){if(!this.has_pending_snippet()){this.parent&&this.parent.#b(t,n);return}this.#g+=t,this.#g===0&&(this.#m(n),this.#s&&Da(this.#s,()=>{this.#s=null}),this.#h&&(this.#e.before(this.#h),this.#h=null))}update_pending_count(t,n){this.#b(t,n),this.#a+=t,!(!this.#u||this.#d)&&(this.#d=!0,Ai(()=>{this.#d=!1,this.#u&&ag(this.#u,this.#a)}))}get_effect_pending(){return this.#_(),Ti(this.#u)}error(t){if(!this.#t.onerror&&!this.#t.failed)throw t;Ie?.is_fork?(this.#o&&Ie.skip_effect(this.#o),this.#s&&Ie.skip_effect(this.#s),this.#r&&Ie.skip_effect(this.#r),Ie.on_fork_commit(()=>{this.#w(t)})):this.#w(t)}#w(t){this.#o&&(En(this.#o),this.#o=null),this.#s&&(En(this.#s),this.#s=null),this.#r&&(En(this.#r),this.#r=null);var n=this.#t.onerror;let s=this.#t.failed;var a=!1,l=!1;const u=()=>{if(a){WC();return}a=!0,l&&HC(),this.#r!==null&&Da(this.#r,()=>{this.#r=null}),this.#p(()=>{this.#y()})},f=h=>{try{l=!0,n?.(h,u),l=!1}catch(g){Ci(g,this.#i&&this.#i.parent)}s&&(this.#r=this.#p(()=>{try{return Nr(()=>{var g=Le;g.b=this,g.f|=jl,s(this.#e,()=>h,()=>u)})}catch(g){return Ci(g,this.#i.parent),null}}))};Ai(()=>{var h;try{h=this.transform_error(t)}catch(g){Ci(g,this.#i&&this.#i.parent);return}h!==null&&typeof h=="object"&&typeof h.then=="function"?h.then(f,g=>Ci(g,this.#i&&this.#i.parent)):f(h)})}}function n0(r){var t=r.effects;if(t!==null){r.effects=null;for(var n=0;n<t.length;n+=1)En(t[n])}}function Eu(r){var t,n=Le,s=r.parent;if(!jr&&s!==null&&(s.f&(lr|yn))!==0)return VC(),r.v;vr(s);try{r.f&=~zr,n0(r),t=mg(r)}finally{vr(n)}return t}function rg(r){var t=Eu(r);if(!r.equals(t)&&(r.wv=vg(),(!Ie?.is_fork||r.deps===null)&&(Ie!==null?(Ie.capture(r,t,!0),Yl?.capture(r,t,!0)):r.v=t,r.deps===null))){Fe(r,Je);return}jr||(on!==null?(bu()||Ie?.is_fork)&&on.set(r,t):wu(r))}function r0(r){if(r.effects!==null)for(const t of r.effects)(t.teardown||t.ac)&&(t.teardown?.(),t.ac?.abort(_u),t.teardown=AC,t.ac=null,Ts(t,0),Tu(t))}function ig(r){if(r.effects!==null)for(const t of r.effects)t.teardown&&ki(t)}let za=new Set;const Wr=new Map;let sg=!1;function Cu(r,t){var n={f:0,v:r,reactions:null,equals:BC,rv:0,wv:0};return n}function tr(r,t){const n=Cu(r);return g0(n),n}function Or(r,t,n=!1){ye!==null&&(!ln||(ye.f&Ga)!==0)&&Ja()&&(ye.f&(rt|an|ps|Ga))!==0&&(zt===null||!Mi.call(zt,r))&&FC();let s=n?ls(t):t;return ag(r,s,Ua)}function ag(r,t,n=null){if(!r.equals(t)){Wr.set(r,jr?t:r.v);var s=Kr.ensure();if(s.capture(r,t),(r.f&rt)!==0){const a=r;(r.f&nt)!==0&&Eu(a),on===null&&wu(a)}r.wv=vg(),og(r,nt,n),Ja()&&Le!==null&&(Le.f&Je)!==0&&(Le.f&(gr|pr))===0&&(Vt===null?p0([r]):Vt.push(r)),!s.is_fork&&za.size>0&&!sg&&i0()}return t}function i0(){sg=!1;for(const r of za){(r.f&Je)!==0&&Fe(r,bn);let t;try{t=Ns(r)}catch{t=!0}t&&ki(r)}za.clear()}function vs(r){Or(r,r.v+1)}function og(r,t,n){var s=r.reactions;if(s!==null)for(var a=Ja(),l=s.length,u=0;u<l;u++){var f=s[u],h=f.f;if(!(!a&&f===Le)){var g=(h&nt)===0;if(g&&Fe(f,t),(h&Ga)!==0)za.add(f);else if((h&rt)!==0){var _=f;on?.delete(_),(h&zr)===0&&(h&qt&&(Le===null||(Le.f&Qa)===0)&&(f.f|=zr),og(_,bn,n))}else if(g){var w=f;(h&an)!==0&&$n!==null&&$n.add(w),n!==null?n.push(w):yu(w)}}}}function ls(r){if(typeof r!="object"||r===null||Ll in r)return r;const t=RC(r);if(t!==bC&&t!==TC)return r;var n=new Map,s=SC(r),a=tr(0),l=Br,u=f=>{if(Br===l)return f();var h=ye,g=Br;Tn(null),Fh(l);var _=f();return Tn(h),Fh(g),_};return s&&n.set("length",tr(r.length)),new Proxy(r,{defineProperty(f,h,g){(!("value"in g)||g.configurable===!1||g.enumerable===!1||g.writable===!1)&&kC();var _=n.get(h);return _===void 0?u(()=>{var w=tr(g.value);return n.set(h,w),w}):Or(_,g.value,!0),!0},deleteProperty(f,h){var g=n.get(h);if(g===void 0){if(h in f){const _=u(()=>tr(tt));n.set(h,_),vs(a)}}else Or(g,tt),vs(a);return!0},get(f,h,g){if(h===Ll)return r;var _=n.get(h),w=h in f;if(_===void 0&&(!w||gs(f,h)?.writable)&&(_=u(()=>{var E=ls(w?f[h]:tt),b=tr(E);return b}),n.set(h,_)),_!==void 0){var m=Ti(_);return m===tt?void 0:m}return Reflect.get(f,h,g)},getOwnPropertyDescriptor(f,h){var g=Reflect.getOwnPropertyDescriptor(f,h);if(g&&"value"in g){var _=n.get(h);_&&(g.value=Ti(_))}else if(g===void 0){var w=n.get(h),m=w?.v;if(w!==void 0&&m!==tt)return{enumerable:!0,configurable:!0,value:m,writable:!0}}return g},has(f,h){if(h===Ll)return!0;var g=n.get(h),_=g!==void 0&&g.v!==tt||Reflect.has(f,h);if(g!==void 0||Le!==null&&(!_||gs(f,h)?.writable)){g===void 0&&(g=u(()=>{var m=_?ls(f[h]):tt,E=tr(m);return E}),n.set(h,g));var w=Ti(g);if(w===tt)return!1}return _},set(f,h,g,_){var w=n.get(h),m=h in f;if(s&&h==="length")for(var E=g;E<w.v;E+=1){var b=n.get(E+"");b!==void 0?Or(b,tt):E in f&&(b=u(()=>tr(tt)),n.set(E+"",b))}if(w===void 0)(!m||gs(f,h)?.writable)&&(w=u(()=>tr(void 0)),Or(w,ls(g)),n.set(h,w));else{m=w.v!==tt;var R=u(()=>ls(g));Or(w,R)}var I=Reflect.getOwnPropertyDescriptor(f,h);if(I?.set&&I.set.call(_,g),!m){if(s&&typeof h=="string"){var N=n.get("length"),$=Number(h);Number.isInteger($)&&$>=N.v&&Or(N,$+1)}vs(a)}return!0},ownKeys(f){Ti(a);var h=Reflect.ownKeys(f).filter(w=>{var m=n.get(w);return m===void 0||m.v!==tt});for(var[g,_]of n)_.v!==tt&&!(g in f)&&h.push(g);return h},setPrototypeOf(){$C()}})}var kh,lg;function s0(){if(kh===void 0){kh=window;var r=Element.prototype,t=Node.prototype,n=Text.prototype;gs(t,"firstChild").get,lg=gs(t,"nextSibling").get,Oh(r)&&(r[OC]=void 0,r[NC]=null,r[UC]=void 0,r.__e=void 0),Oh(n)&&(n[DC]=void 0)}}function ug(r=""){return document.createTextNode(r)}function cg(r){return lg.call(r)}function fg(r){var t=ye,n=Le;Tn(null),vr(null);try{return r()}finally{Tn(t),vr(n)}}function a0(r,t){var n=t.last;n===null?t.last=t.first=r:(n.next=r,r.prev=n,t.last=r)}function Ls(r,t){var n=Le;n!==null&&(n.f&yn)!==0&&(r|=yn);var s={ctx:fn,deps:null,nodes:null,f:r|nt|qt,first:null,fn:t,last:null,next:null,parent:n,b:n&&n.b,prev:null,teardown:null,wv:0,ac:null};Ie?.register_created_effect(s);var a=s;if((r&Cs)!==0)bi!==null?bi.push(s):Kr.ensure().schedule(s);else if(t!==null){try{ki(s)}catch(u){throw En(s),u}a.deps===null&&a.teardown===null&&a.nodes===null&&a.first===a.last&&(a.f&Ya)===0&&(a=a.first,(r&an)!==0&&(r&Ba)!==0&&a!==null&&(a.f|=Ba))}if(a!==null&&(a.parent=n,n!==null&&a0(a,n),ye!==null&&(ye.f&rt)!==0&&(r&pr)===0)){var l=ye;(l.effects??=[]).push(a)}return s}function bu(){return ye!==null&&!ln}function o0(r){return Ls(Cs|LC,r)}function l0(r){Kr.ensure();const t=Ls(pr|Ya,r);return(n={})=>new Promise(s=>{n.outro?Da(t,()=>{En(t),s(void 0)}):(En(t),s(void 0))})}function u0(r,t=0){return Ls(jd|t,r)}function c0(r,t=0){var n=Ls(an|t,r);return n}function Nr(r){return Ls(gr|Ya,r)}function hg(r){var t=r.teardown;if(t!==null){const n=jr,s=ye;$h(!0),Tn(null);try{t.call(null)}finally{$h(n),Tn(s)}}}function Tu(r,t=!1){var n=r.first;for(r.first=r.last=null;n!==null;){const a=n.ac;a!==null&&fg(()=>{a.abort(_u)});var s=n.next;(n.f&pr)!==0?n.parent=null:En(n,t),n=s}}function f0(r){for(var t=r.first;t!==null;){var n=t.next;(t.f&gr)===0&&En(t),t=n}}function En(r,t=!0){var n=!1;(t||(r.f&xC)!==0)&&r.nodes!==null&&r.nodes.end!==null&&(h0(r.nodes.start,r.nodes.end),n=!0),Fe(r,Uh),Tu(r,t&&!n),Ts(r,0);var s=r.nodes&&r.nodes.t;if(s!==null)for(const l of s)l.stop();hg(r),r.f^=Uh,r.f|=lr;var a=r.parent;a!==null&&a.first!==null&&dg(r),r.next=r.prev=r.teardown=r.ctx=r.deps=r.fn=r.nodes=r.ac=r.b=null}function h0(r,t){for(;r!==null;){var n=r===t?null:cg(r);r.remove(),r=n}}function dg(r){var t=r.parent,n=r.prev,s=r.next;n!==null&&(n.next=s),s!==null&&(s.prev=n),t!==null&&(t.first===r&&(t.first=s),t.last===r&&(t.last=n))}function Da(r,t,n=!0){var s=[];gg(r,s,!0);var a=()=>{n&&En(r),t&&t()},l=s.length;if(l>0){var u=()=>--l||a();for(var f of s)f.out(u)}else a()}function gg(r,t,n){if((r.f&yn)===0){r.f^=yn;var s=r.nodes&&r.nodes.t;if(s!==null)for(const f of s)(f.is_global||n)&&t.push(f);for(var a=r.first;a!==null;){var l=a.next;if((a.f&pr)===0){var u=(a.f&Ba)!==0||(a.f&gr)!==0&&(r.f&an)!==0;gg(a,t,u?n:!1)}a=l}}}function d0(r,t){if(r.nodes)for(var n=r.nodes.start,s=r.nodes.end;n!==null;){var a=n===s?null:cg(n);t.append(n),n=a}}let Ma=!1,jr=!1;function $h(r){jr=r}let ye=null,ln=!1;function Tn(r){ye=r}let Le=null;function vr(r){Le=r}let zt=null;function g0(r){ye!==null&&(zt===null?zt=[r]:zt.push(r))}let vt=null,It=0,Vt=null;function p0(r){Vt=r}let pg=1,Mr=0,Br=Mr;function Fh(r){Br=r}function vg(){return++pg}function Ns(r){var t=r.f;if((t&nt)!==0)return!0;if(t&rt&&(r.f&=~zr),(t&bn)!==0){for(var n=r.deps,s=n.length,a=0;a<s;a++){var l=n[a];if(Ns(l)&&rg(l),l.wv>r.wv)return!0}(t&qt)!==0&&on===null&&Fe(r,Je)}return!1}function _g(r,t,n=!0){var s=r.reactions;if(s!==null&&!(zt!==null&&Mi.call(zt,r)))for(var a=0;a<s.length;a++){var l=s[a];(l.f&rt)!==0?_g(l,t,!1):t===l&&(n?Fe(l,nt):(l.f&Je)!==0&&Fe(l,bn),yu(l))}}function mg(r){var t=vt,n=It,s=Vt,a=ye,l=zt,u=fn,f=ln,h=Br,g=r.f;vt=null,It=0,Vt=null,ye=(g&(gr|pr))===0?r:null,zt=null,qa(r.ctx),ln=!1,Br=++Mr,r.ac!==null&&(fg(()=>{r.ac.abort(_u)}),r.ac=null);try{r.f|=Qa;var _=r.fn,w=_();r.f|=xs;var m=r.deps,E=Ie?.is_fork;if(vt!==null){var b;if(E||Ts(r,It),m!==null&&It>0)for(m.length=It+vt.length,b=0;b<vt.length;b++)m[It+b]=vt[b];else r.deps=m=vt;if(bu()&&(r.f&qt)!==0)for(b=It;b<m.length;b++)(m[b].reactions??=[]).push(r)}else!E&&m!==null&&It<m.length&&(Ts(r,It),m.length=It);if(Ja()&&Vt!==null&&!ln&&m!==null&&(r.f&(rt|bn|nt))===0)for(b=0;b<Vt.length;b++)_g(Vt[b],r);if(a!==null&&a!==r){if(Mr++,a.deps!==null)for(let R=0;R<n;R+=1)a.deps[R].rv=Mr;if(t!==null)for(const R of t)R.rv=Mr;Vt!==null&&(s===null?s=Vt:s.push(...Vt))}return(r.f&bs)!==0&&(r.f^=bs),w}catch(R){return Jd(R)}finally{r.f^=Qa,vt=t,It=n,Vt=s,ye=a,zt=l,qa(u),ln=f,Br=h}}function v0(r,t){let n=t.reactions;if(n!==null){var s=yC.call(n,r);if(s!==-1){var a=n.length-1;a===0?n=t.reactions=null:(n[s]=n[a],n.pop())}}if(n===null&&(t.f&rt)!==0&&(vt===null||!Mi.call(vt,t))){var l=t;(l.f&qt)!==0&&(l.f^=qt,l.f&=~zr),l.v!==tt&&wu(l),r0(l),Ts(l,0)}}function Ts(r,t){var n=r.deps;if(n!==null)for(var s=t;s<n.length;s++)v0(r,n[s])}function ki(r){var t=r.f;if((t&lr)===0){Fe(r,Je);var n=Le,s=Ma;Le=r,Ma=!0;try{(t&(an|Yd))!==0?f0(r):Tu(r),hg(r);var a=mg(r);r.teardown=typeof a=="function"?a:null,r.wv=pg;var l;Kd&&GC&&(r.f&nt)!==0&&r.deps}finally{Ma=s,Le=n}}}function Ti(r){var t=r.f,n=(t&rt)!==0;if(ye!==null&&!ln){var s=Le!==null&&(Le.f&lr)!==0;if(!s&&(zt===null||!Mi.call(zt,r))){var a=ye.deps;if((ye.f&Qa)!==0)r.rv<Mr&&(r.rv=Mr,vt===null&&a!==null&&a[It]===r?It++:vt===null?vt=[r]:vt.push(r));else{(ye.deps??=[]).push(r);var l=r.reactions;l===null?r.reactions=[ye]:Mi.call(l,ye)||l.push(ye)}}}if(jr&&Wr.has(r))return Wr.get(r);if(n){var u=r;if(jr){var f=u.v;return((u.f&Je)===0&&u.reactions!==null||Sg(u))&&(f=Eu(u)),Wr.set(u,f),f}var h=(u.f&qt)===0&&!ln&&ye!==null&&(Ma||(ye.f&qt)!==0),g=(u.f&xs)===0;Ns(u)&&(h&&(u.f|=qt),rg(u)),h&&!g&&(ig(u),wg(u))}if(on?.has(r))return on.get(r);if((r.f&bs)!==0)throw r.v;return r.v}function wg(r){if(r.f|=qt,r.deps!==null)for(const t of r.deps)(t.reactions??=[]).push(r),(t.f&rt)!==0&&(t.f&qt)===0&&(ig(t),wg(t))}function Sg(r){if(r.v===tt)return!0;if(r.deps===null)return!1;for(const t of r.deps)if(Wr.has(t)||(t.f&rt)!==0&&Sg(t))return!0;return!1}function _0(r){var t=ln;try{return ln=!0,r()}finally{ln=t}}const m0=["touchstart","touchmove"];function w0(r){return m0.includes(r)}const Ia=Symbol("events"),S0=new Set,Hh=new Set;let Vh=null;function Wh(r){var t=this,n=t.ownerDocument,s=r.type,a=r.composedPath?.()||[],l=a[0]||r.target;Vh=r;var u=0,f=Vh===r&&r[Ia];if(f){var h=a.indexOf(f);if(h!==-1&&(t===document||t===window)){r[Ia]=t;return}var g=a.indexOf(t);if(g===-1)return;h<=g&&(u=h)}if(l=a[u]||r.target,l!==t){CC(r,"currentTarget",{configurable:!0,get(){return l||n}});var _=ye,w=Le;Tn(null),vr(null);try{for(var m,E=[];l!==null;){var b=l.assignedSlot||l.parentNode||l.host||null;try{var R=l[Ia]?.[s];R!=null&&(!l.disabled||r.target===l)&&R.call(l,r)}catch(I){m?E.push(I):m=I}if(r.cancelBubble||b===t||b===null)break;l=b}if(m){for(let I of E)queueMicrotask(()=>{throw I});throw m}}finally{r[Ia]=t,delete r.currentTarget,Tn(_),vr(w)}}}function y0(r,t){return E0(r,t)}const xa=new Map;function E0(r,{target:t,anchor:n,props:s={},events:a,context:l,intro:u=!0,transformError:f}){s0();var h=void 0,g=l0(()=>{var _=n??t.appendChild(ug());e0(_,{pending:()=>{}},E=>{qC({});var b=fn;l&&(b.c=l),a&&(s.$$events=a),h=r(E,s)||{},zC()},f);var w=new Set,m=E=>{for(var b=0;b<E.length;b++){var R=E[b];if(!w.has(R)){w.add(R);var I=w0(R);for(const J of[t,document]){var N=xa.get(J);N===void 0&&(N=new Map,xa.set(J,N));var $=N.get(R);$===void 0?(J.addEventListener(R,Wh,{passive:I}),N.set(R,1)):N.set(R,$+1)}}}};return m(EC(S0)),Hh.add(m),()=>{for(var E of w)for(const I of[t,document]){var b=xa.get(I),R=b.get(E);--R==0?(I.removeEventListener(E,Wh),b.delete(E),b.size===0&&xa.delete(I)):b.set(E,R)}Hh.delete(m),_!==n&&_.parentNode?.removeChild(_)}});return C0.set(h,g),h}let C0=new WeakMap;const b0="5";typeof window<"u"&&((window.__svelte??={}).v??=new Set).add(b0);QC();function T0(r){}const Xl={init:r=>{j.get(Vr).enableRouting()},handlePageErrorHandler:(r,t,n)=>{r&&r.timeout&&setTimeout(()=>{if(r.viewUrl)t.viewUrl=r.viewUrl,n.getEngine()._ui.updateMainContent(t,n);else if(r.errorFn)r.errorFn(t);else{console.warn("Something went wrong with a client! You will be redirected to another page.");const s=r.redirectPath||"/";n.navigation().navigate(s)}},r.timeout)},handleExternalLinkNavigation:r=>{if(r.url)if(r.sameWindow||!1)window.location.href=r.url;else{const n=window.open(r.url,"_blank","noopener noreferrer");n&&(n.opener=null,n.focus())}},async addSearchParamsFromClient(r,t,n){const s=j.get(dr),a=D.getCurrentPath(n,n.getConfig().routing?.useHashRouting),u=(await s.getCurrentNode(a.path))?.clientPermissions?.urlParameters,f={...r};if(u){const h={};Object.keys(u).forEach(g=>{g in f&&u[g]?.write===!0&&(h[g]=f[g],delete f[g])});for(const g in f)console.warn(`No permission to add the search param "${g}" to the url`);Object.keys(h).length>0&&n.routing().addSearchParams(h,t)}}};class R0{static hasLocaleChangePermission(t){return t?.clientPermissions?.changeCurrentLocale?!0:(console.error('Current locale change declined from client, as client permission "changeCurrentLocale" is not set for this view.'),!1)}}const mn={luigi:{},init:r=>{mn.luigi=r},addListeners:(r,t)=>{r.addEventListener(k.INITIALIZED,n=>{qe.luigi?.ux().hideLoadingIndicator(r.parentNode);const s=j.get(Ui);s.viewGroupLoaded(r),!r._luigiPreloading&&r.style.display!=="none"&&s.preload()}),r.addEventListener(k.NAVIGATION_COMPLETED_REPORT,()=>{j.get(Ui).preload()}),r.addEventListener(k.NAVIGATION_REQUEST,n=>{const{drawer:s,link:a,intent:l,preserveView:u,modal:f,newTab:h,withoutSync:g,preventContextUpdate:_,preventHistoryEntry:w,fromVirtualTreeRoot:m,fromContext:E,fromClosestContext:b,fromParent:R,relative:I,nodeParams:N}=n.detail,$={drawerSettings:s,intent:l,modalSettings:f,newTab:h,path:a,preserveView:u,preventContextUpdate:_,options:{fromVirtualTreeRoot:m,fromContext:E,fromClosestContext:b,fromParent:R,relative:I,nodeParams:N},preventHistoryEntry:w,withoutSync:g};j.get(dr).handleNavigationRequest($,n.callbackFn)}),r.addEventListener(k.RUNTIME_ERROR_HANDLING_REQUEST,n=>{t.navigation().runTimeErrorHandler(n.payload?.data?.errorObj||{})}),r.addEventListener(k.ALERT_REQUEST,n=>{qe.processAlert(n.payload,!0,r)}),r.addEventListener(k.SHOW_CONFIRMATION_MODAL_REQUEST,n=>{qe.handleConfirmationModalRequest(n.payload,r)}),r.addEventListener(k.SET_DOCUMENT_TITLE_REQUEST,n=>{mn.luigi.getEngine()._connector?.setDocumentTitle(n.detail.title)}),r.addEventListener(k.SHOW_LOADING_INDICATOR_REQUEST,n=>{mn.luigi.getEngine()._connector?.showLoadingIndicator(r.parentNode)}),r.addEventListener(k.HIDE_LOADING_INDICATOR_REQUEST,n=>{mn.luigi.getEngine()._connector?.hideLoadingIndicator(r.parentNode)}),r.addEventListener(k.ADD_BACKDROP_REQUEST,n=>{mn.luigi.getEngine()._connector?.addBackdrop()}),r.addEventListener(k.REMOVE_BACKDROP_REQUEST,n=>{mn.luigi.getEngine()._connector?.removeBackdrop()}),r.addEventListener(k.SET_DIRTY_STATUS_REQUEST,n=>{qe.handleDirtyStatusRequest(n.detail?.data?.dirty,r)}),r.addEventListener(k.ADD_NODE_PARAMS_REQUEST,n=>{t.routing().addNodeParams(n.payload.data,n.payload.keepBrowserHistory)}),r.addEventListener(k.OPEN_USER_SETTINGS_REQUEST,n=>{mn.luigi.getEngine()._connector?.openUserSettings(n.detail)}),r.addEventListener(k.CLOSE_USER_SETTINGS_REQUEST,n=>{mn.luigi.getEngine()._connector?.closeUserSettings()}),r.addEventListener(k.ADD_SEARCH_PARAMS_REQUEST,n=>{Xl.addSearchParamsFromClient(n.detail.data,n.detail.keepBrowserHistory,t)}),r.addEventListener(k.UPDATE_MODAL_SETTINGS_REQUEST,n=>{G.updateModalSettings(n.payload.updatedModalSettings,n.payload.addHistoryEntry,t)}),r.addEventListener(k.SET_CURRENT_LOCALE_REQUEST,n=>{R0.hasLocaleChangePermission(r)&&t.i18n().setCurrentLocale(n.detail?.data?.data?.currentLocale)})}};class A0{constructor(){this._ui=G,this._comm=mn,this._ux=qe,this._routing=Xl}bootstrap(t){this._app=y0(T0,{target:document.body}),this._connector=t}init(){const t=window.Luigi;j.register(un,()=>new un(t)),j.register(dr,()=>new dr(t)),j.register(hr,()=>new hr),j.register(Vr,()=>new Vr(t)),j.register(Di,()=>new Di),j.register(fr,()=>new fr(t)),j.register(Ui,()=>new Ui(t)),t.theming()._init(),G.init(t),Xl.init(t),mn.init(t),qe.init(t)}}window.Luigi=new wC(new A0);
55
95
  //# sourceMappingURL=luigi.js.map