@equinor/fusion-framework-cli 10.5.5 → 10.6.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -34,13 +34,13 @@ var iH=Object.defineProperty;var oH=(r,e,t)=>e in r?iH(r,e,{enumerable:!0,config
34
34
  `+P+s}var ye=!1;function Pe(s,l){if(!s||ye)return"";ye=!0;var f=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{if(l)if(l=function(){throw Error()},Object.defineProperty(l.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(l,[])}catch(ne){var m=ne}Reflect.construct(s,[],l)}else{try{l.call()}catch(ne){m=ne}s.call(l.prototype)}else{try{throw Error()}catch(ne){m=ne}s()}}catch(ne){if(ne&&m&&typeof ne.stack=="string"){for(var y=ne.stack.split(`
35
35
  `),w=m.stack.split(`
36
36
  `),E=y.length-1,L=w.length-1;1<=E&&0<=L&&y[E]!==w[L];)L--;for(;1<=E&&0<=L;E--,L--)if(y[E]!==w[L]){if(E!==1||L!==1)do if(E--,L--,0>L||y[E]!==w[L]){var V=`
37
- `+y[E].replace(" at new "," at ");return s.displayName&&V.includes("<anonymous>")&&(V=V.replace("<anonymous>",s.displayName)),V}while(1<=E&&0<=L);break}}}finally{ye=!1,Error.prepareStackTrace=f}return(s=s?s.displayName||s.name:"")?N(s):""}function Ie(s){switch(s.tag){case 5:return N(s.type);case 16:return N("Lazy");case 13:return N("Suspense");case 19:return N("SuspenseList");case 0:case 2:case 15:return s=Pe(s.type,!1),s;case 11:return s=Pe(s.type.render,!1),s;case 1:return s=Pe(s.type,!0),s;default:return""}}function Te(s){if(s==null)return null;if(typeof s=="function")return s.displayName||s.name||null;if(typeof s=="string")return s;switch(s){case I:return"Fragment";case U:return"Portal";case le:return"Profiler";case Y:return"StrictMode";case Ce:return"Suspense";case J:return"SuspenseList"}if(typeof s=="object")switch(s.$$typeof){case Ee:return(s.displayName||"Context")+".Consumer";case de:return(s._context.displayName||"Context")+".Provider";case we:var l=s.render;return s=s.displayName,s||(s=l.displayName||l.name||"",s=s!==""?"ForwardRef("+s+")":"ForwardRef"),s;case K:return l=s.displayName||null,l!==null?l:Te(s.type)||"Memo";case re:l=s._payload,s=s._init;try{return Te(s(l))}catch{}}return null}function Ke(s){var l=s.type;switch(s.tag){case 24:return"Cache";case 9:return(l.displayName||"Context")+".Consumer";case 10:return(l._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return s=l.render,s=s.displayName||s.name||"",l.displayName||(s!==""?"ForwardRef("+s+")":"ForwardRef");case 7:return"Fragment";case 5:return l;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return Te(l);case 8:return l===Y?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof l=="function")return l.displayName||l.name||null;if(typeof l=="string")return l}return null}function ot(s){switch(typeof s){case"boolean":case"number":case"string":case"undefined":return s;case"object":return s;default:return""}}function _t(s){var l=s.type;return(s=s.nodeName)&&s.toLowerCase()==="input"&&(l==="checkbox"||l==="radio")}function yr(s){var l=_t(s)?"checked":"value",f=Object.getOwnPropertyDescriptor(s.constructor.prototype,l),m=""+s[l];if(!s.hasOwnProperty(l)&&typeof f<"u"&&typeof f.get=="function"&&typeof f.set=="function"){var y=f.get,w=f.set;return Object.defineProperty(s,l,{configurable:!0,get:function(){return y.call(this)},set:function(E){m=""+E,w.call(this,E)}}),Object.defineProperty(s,l,{enumerable:f.enumerable}),{getValue:function(){return m},setValue:function(E){m=""+E},stopTracking:function(){s._valueTracker=null,delete s[l]}}}}function Wr(s){s._valueTracker||(s._valueTracker=yr(s))}function Rt(s){if(!s)return!1;var l=s._valueTracker;if(!l)return!0;var f=l.getValue(),m="";return s&&(m=_t(s)?s.checked?"true":"false":s.value),s=m,s!==f?(l.setValue(s),!0):!1}function Un(s){if(s=s||(typeof document<"u"?document:void 0),typeof s>"u")return null;try{return s.activeElement||s.body}catch{return s.body}}function co(s,l){var f=l.checked;return H({},l,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:f??s._wrapperState.initialChecked})}function ma(s,l){var f=l.defaultValue==null?"":l.defaultValue,m=l.checked!=null?l.checked:l.defaultChecked;f=ot(l.value!=null?l.value:f),s._wrapperState={initialChecked:m,initialValue:f,controlled:l.type==="checkbox"||l.type==="radio"?l.checked!=null:l.value!=null}}function qi(s,l){l=l.checked,l!=null&&A(s,"checked",l,!1)}function Sc(s,l){qi(s,l);var f=ot(l.value),m=l.type;if(f!=null)m==="number"?(f===0&&s.value===""||s.value!=f)&&(s.value=""+f):s.value!==""+f&&(s.value=""+f);else if(m==="submit"||m==="reset"){s.removeAttribute("value");return}l.hasOwnProperty("value")?Tc(s,l.type,f):l.hasOwnProperty("defaultValue")&&Tc(s,l.type,ot(l.defaultValue)),l.checked==null&&l.defaultChecked!=null&&(s.defaultChecked=!!l.defaultChecked)}function Uu(s,l,f){if(l.hasOwnProperty("value")||l.hasOwnProperty("defaultValue")){var m=l.type;if(!(m!=="submit"&&m!=="reset"||l.value!==void 0&&l.value!==null))return;l=""+s._wrapperState.initialValue,f||l===s.value||(s.value=l),s.defaultValue=l}f=s.name,f!==""&&(s.name=""),s.defaultChecked=!!s._wrapperState.initialChecked,f!==""&&(s.name=f)}function Tc(s,l,f){(l!=="number"||Un(s.ownerDocument)!==s)&&(f==null?s.defaultValue=""+s._wrapperState.initialValue:s.defaultValue!==""+f&&(s.defaultValue=""+f))}var Po=Array.isArray;function Mo(s,l,f,m){if(s=s.options,l){l={};for(var y=0;y<f.length;y++)l["$"+f[y]]=!0;for(f=0;f<s.length;f++)y=l.hasOwnProperty("$"+s[f].value),s[f].selected!==y&&(s[f].selected=y),y&&m&&(s[f].defaultSelected=!0)}else{for(f=""+ot(f),l=null,y=0;y<s.length;y++){if(s[y].value===f){s[y].selected=!0,m&&(s[y].defaultSelected=!0);return}l!==null||s[y].disabled||(l=s[y])}l!==null&&(l.selected=!0)}}function Ac(s,l){if(l.dangerouslySetInnerHTML!=null)throw Error(t(91));return H({},l,{value:void 0,defaultValue:void 0,children:""+s._wrapperState.initialValue})}function zl(s,l){var f=l.value;if(f==null){if(f=l.children,l=l.defaultValue,f!=null){if(l!=null)throw Error(t(92));if(Po(f)){if(1<f.length)throw Error(t(93));f=f[0]}l=f}l==null&&(l=""),f=l}s._wrapperState={initialValue:ot(f)}}function An(s,l){var f=ot(l.value),m=ot(l.defaultValue);f!=null&&(f=""+f,f!==s.value&&(s.value=f),l.defaultValue==null&&s.defaultValue!==f&&(s.defaultValue=f)),m!=null&&(s.defaultValue=""+m)}function lo(s){var l=s.textContent;l===s._wrapperState.initialValue&&l!==""&&l!==null&&(s.value=l)}function Bl(s){switch(s){case"svg":return"http://www.w3.org/2000/svg";case"math":return"http://www.w3.org/1998/Math/MathML";default:return"http://www.w3.org/1999/xhtml"}}function Ba(s,l){return s==null||s==="http://www.w3.org/1999/xhtml"?Bl(l):s==="http://www.w3.org/2000/svg"&&l==="foreignObject"?"http://www.w3.org/1999/xhtml":s}var ai,Ii=function(s){return typeof MSApp<"u"&&MSApp.execUnsafeLocalFunction?function(l,f,m,y){MSApp.execUnsafeLocalFunction(function(){return s(l,f,m,y)})}:s}(function(s,l){if(s.namespaceURI!=="http://www.w3.org/2000/svg"||"innerHTML"in s)s.innerHTML=l;else{for(ai=ai||document.createElement("div"),ai.innerHTML="<svg>"+l.valueOf().toString()+"</svg>",l=ai.firstChild;s.firstChild;)s.removeChild(s.firstChild);for(;l.firstChild;)s.appendChild(l.firstChild)}});function Ua(s,l){if(l){var f=s.firstChild;if(f&&f===s.lastChild&&f.nodeType===3){f.nodeValue=l;return}}s.textContent=l}var $o={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},e1=["Webkit","ms","Moz","O"];Object.keys($o).forEach(function(s){e1.forEach(function(l){l=l+s.charAt(0).toUpperCase()+s.substring(1),$o[l]=$o[s]})});function uo(s,l,f){return l==null||typeof l=="boolean"||l===""?"":f||typeof l!="number"||l===0||$o.hasOwnProperty(s)&&$o[s]?(""+l).trim():l+"px"}function Ic(s,l){s=s.style;for(var f in l)if(l.hasOwnProperty(f)){var m=f.indexOf("--")===0,y=uo(f,l[f],m);f==="float"&&(f="cssFloat"),m?s.setProperty(f,y):s[f]=y}}var qu=H({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function Rc(s,l){if(l){if(qu[s]&&(l.children!=null||l.dangerouslySetInnerHTML!=null))throw Error(t(137,s));if(l.dangerouslySetInnerHTML!=null){if(l.children!=null)throw Error(t(60));if(typeof l.dangerouslySetInnerHTML!="object"||!("__html"in l.dangerouslySetInnerHTML))throw Error(t(61))}if(l.style!=null&&typeof l.style!="object")throw Error(t(62))}}function Ps(s,l){if(s.indexOf("-")===-1)return typeof l.is=="string";switch(s){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var Oo=null;function Zo(s){return s=s.target||s.srcElement||window,s.correspondingUseElement&&(s=s.correspondingUseElement),s.nodeType===3?s.parentNode:s}var qa=null,Wi=null,si=null;function Wu(s){if(s=_1(s)){if(typeof qa!="function")throw Error(t(280));var l=s.stateNode;l&&(l=P2(l),qa(s.stateNode,s.type,l))}}function Ul(s){Wi?si?si.push(s):si=[s]:Wi=s}function Gu(){if(Wi){var s=Wi,l=si;if(si=Wi=null,Wu(s),l)for(s=0;s<l.length;s++)Wu(l[s])}}function ql(s,l){return s(l)}function Ms(){}var va=!1;function Wl(s,l,f){if(va)return s(l,f);va=!0;try{return ql(s,l,f)}finally{va=!1,(Wi!==null||si!==null)&&(Ms(),Gu())}}function Ri(s,l){var f=s.stateNode;if(f===null)return null;var m=P2(f);if(m===null)return null;f=m[l];e:switch(l){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(m=!m.disabled)||(s=s.type,m=!(s==="button"||s==="input"||s==="select"||s==="textarea")),s=!m;break e;default:s=!1}if(s)return null;if(f&&typeof f!="function")throw Error(t(231,l,typeof f));return f}var D=!1;if(c)try{var Q={};Object.defineProperty(Q,"passive",{get:function(){D=!0}}),window.addEventListener("test",Q,Q),window.removeEventListener("test",Q,Q)}catch{D=!1}function ie(s,l,f,m,y,w,E,L,V){var ne=Array.prototype.slice.call(arguments,3);try{l.apply(f,ne)}catch(ge){this.onError(ge)}}var he=!1,Oe=null,Ve=!1,mt=null,Ge={onError:function(s){he=!0,Oe=s}};function Ye(s,l,f,m,y,w,E,L,V){he=!1,Oe=null,ie.apply(Ge,arguments)}function je(s,l,f,m,y,w,E,L,V){if(Ye.apply(this,arguments),he){if(he){var ne=Oe;he=!1,Oe=null}else throw Error(t(198));Ve||(Ve=!0,mt=ne)}}function Je(s){var l=s,f=s;if(s.alternate)for(;l.return;)l=l.return;else{s=l;do l=s,l.flags&4098&&(f=l.return),s=l.return;while(s)}return l.tag===3?f:null}function wt(s){if(s.tag===13){var l=s.memoizedState;if(l===null&&(s=s.alternate,s!==null&&(l=s.memoizedState)),l!==null)return l.dehydrated}return null}function Ht(s){if(Je(s)!==s)throw Error(t(188))}function mn(s){var l=s.alternate;if(!l){if(l=Je(s),l===null)throw Error(t(188));return l!==s?null:s}for(var f=s,m=l;;){var y=f.return;if(y===null)break;var w=y.alternate;if(w===null){if(m=y.return,m!==null){f=m;continue}break}if(y.child===w.child){for(w=y.child;w;){if(w===f)return Ht(y),s;if(w===m)return Ht(y),l;w=w.sibling}throw Error(t(188))}if(f.return!==m.return)f=y,m=w;else{for(var E=!1,L=y.child;L;){if(L===f){E=!0,f=y,m=w;break}if(L===m){E=!0,m=y,f=w;break}L=L.sibling}if(!E){for(L=w.child;L;){if(L===f){E=!0,f=w,m=y;break}if(L===m){E=!0,m=w,f=y;break}L=L.sibling}if(!E)throw Error(t(189))}}if(f.alternate!==m)throw Error(t(190))}if(f.tag!==3)throw Error(t(188));return f.stateNode.current===f?s:l}function ar(s){return s=mn(s),s!==null?Ut(s):null}function Ut(s){if(s.tag===5||s.tag===6)return s;for(s=s.child;s!==null;){var l=Ut(s);if(l!==null)return l;s=s.sibling}return null}var Er=e.unstable_scheduleCallback,ci=e.unstable_cancelCallback,$s=e.unstable_shouldYield,ho=e.unstable_requestPaint,Kt=e.unstable_now,Gl=e.unstable_getCurrentPriorityLevel,ga=e.unstable_ImmediatePriority,Lo=e.unstable_UserBlockingPriority,Ho=e.unstable_NormalPriority,ya=e.unstable_LowPriority,jt=e.unstable_IdlePriority,sr=null,In=null;function Os(s){if(In&&typeof In.onCommitFiberRoot=="function")try{In.onCommitFiberRoot(sr,s,void 0,(s.current.flags&128)===128)}catch{}}var Yt=Math.clz32?Math.clz32:t1,Wa=Math.log,Ku=Math.LN2;function t1(s){return s>>>=0,s===0?32:31-(Wa(s)/Ku|0)|0}var Pc=64,Yu=4194304;function Kl(s){switch(s&-s){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return s&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return s&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return s}}function Qu(s,l){var f=s.pendingLanes;if(f===0)return 0;var m=0,y=s.suspendedLanes,w=s.pingedLanes,E=f&268435455;if(E!==0){var L=E&~y;L!==0?m=Kl(L):(w&=E,w!==0&&(m=Kl(w)))}else E=f&~y,E!==0?m=Kl(E):w!==0&&(m=Kl(w));if(m===0)return 0;if(l!==0&&l!==m&&!(l&y)&&(y=m&-m,w=l&-l,y>=w||y===16&&(w&4194240)!==0))return l;if(m&4&&(m|=f&16),l=s.entangledLanes,l!==0)for(s=s.entanglements,l&=m;0<l;)f=31-Yt(l),y=1<<f,m|=s[f],l&=~y;return m}function a5(s,l){switch(s){case 1:case 2:case 4:return l+250;case 8:case 16:case 32:case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return l+5e3;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return-1;case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function s5(s,l){for(var f=s.suspendedLanes,m=s.pingedLanes,y=s.expirationTimes,w=s.pendingLanes;0<w;){var E=31-Yt(w),L=1<<E,V=y[E];V===-1?(!(L&f)||L&m)&&(y[E]=a5(L,l)):V<=l&&(s.expiredLanes|=L),w&=~L}}function r1(s){return s=s.pendingLanes&-1073741825,s!==0?s:s&1073741824?1073741824:0}function p2(){var s=Pc;return Pc<<=1,!(Pc&4194240)&&(Pc=64),s}function Xu(s){for(var l=[],f=0;31>f;f++)l.push(s);return l}function Yl(s,l,f){s.pendingLanes|=l,l!==536870912&&(s.suspendedLanes=0,s.pingedLanes=0),s=s.eventTimes,l=31-Yt(l),s[l]=f}function c5(s,l){var f=s.pendingLanes&~l;s.pendingLanes=l,s.suspendedLanes=0,s.pingedLanes=0,s.expiredLanes&=l,s.mutableReadLanes&=l,s.entangledLanes&=l,l=s.entanglements;var m=s.eventTimes;for(s=s.expirationTimes;0<f;){var y=31-Yt(f),w=1<<y;l[y]=0,m[y]=-1,s[y]=-1,f&=~w}}function Mc(s,l){var f=s.entangledLanes|=l;for(s=s.entanglements;f;){var m=31-Yt(f),y=1<<m;y&l|s[m]&l&&(s[m]|=l),f&=~y}}var qt=0;function n1(s){return s&=-s,1<s?4<s?s&268435455?16:536870912:4:1}var Ga,i1,m2,v2,g2,o1=!1,Ju=[],_a=null,li=null,Ka=null,$c=new Map,Ql=new Map,No=[],y2="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset submit".split(" ");function _2(s,l){switch(s){case"focusin":case"focusout":_a=null;break;case"dragenter":case"dragleave":li=null;break;case"mouseover":case"mouseout":Ka=null;break;case"pointerover":case"pointerout":$c.delete(l.pointerId);break;case"gotpointercapture":case"lostpointercapture":Ql.delete(l.pointerId)}}function Xl(s,l,f,m,y,w){return s===null||s.nativeEvent!==w?(s={blockedOn:l,domEventName:f,eventSystemFlags:m,nativeEvent:w,targetContainers:[y]},l!==null&&(l=_1(l),l!==null&&i1(l)),s):(s.eventSystemFlags|=m,l=s.targetContainers,y!==null&&l.indexOf(y)===-1&&l.push(y),s)}function b2(s,l,f,m,y){switch(l){case"focusin":return _a=Xl(_a,s,l,f,m,y),!0;case"dragenter":return li=Xl(li,s,l,f,m,y),!0;case"mouseover":return Ka=Xl(Ka,s,l,f,m,y),!0;case"pointerover":var w=y.pointerId;return $c.set(w,Xl($c.get(w)||null,s,l,f,m,y)),!0;case"gotpointercapture":return w=y.pointerId,Ql.set(w,Xl(Ql.get(w)||null,s,l,f,m,y)),!0}return!1}function w2(s){var l=id(s.target);if(l!==null){var f=Je(l);if(f!==null){if(l=f.tag,l===13){if(l=wt(f),l!==null){s.blockedOn=l,g2(s.priority,function(){m2(f)});return}}else if(l===3&&f.stateNode.current.memoizedState.isDehydrated){s.blockedOn=f.tag===3?f.stateNode.containerInfo:null;return}}}s.blockedOn=null}function Zs(s){if(s.blockedOn!==null)return!1;for(var l=s.targetContainers;0<l.length;){var f=fo(s.domEventName,s.eventSystemFlags,l[0],s.nativeEvent);if(f===null){f=s.nativeEvent;var m=new f.constructor(f.type,f);Oo=m,f.target.dispatchEvent(m),Oo=null}else return l=_1(f),l!==null&&i1(l),s.blockedOn=f,!1;l.shift()}return!0}function x2(s,l,f){Zs(s)&&f.delete(l)}function a1(){o1=!1,_a!==null&&Zs(_a)&&(_a=null),li!==null&&Zs(li)&&(li=null),Ka!==null&&Zs(Ka)&&(Ka=null),$c.forEach(x2),Ql.forEach(x2)}function Jl(s,l){s.blockedOn===l&&(s.blockedOn=null,o1||(o1=!0,e.unstable_scheduleCallback(e.unstable_NormalPriority,a1)))}function ed(s){function l(y){return Jl(y,s)}if(0<Ju.length){Jl(Ju[0],s);for(var f=1;f<Ju.length;f++){var m=Ju[f];m.blockedOn===s&&(m.blockedOn=null)}}for(_a!==null&&Jl(_a,s),li!==null&&Jl(li,s),Ka!==null&&Jl(Ka,s),$c.forEach(l),Ql.forEach(l),f=0;f<No.length;f++)m=No[f],m.blockedOn===s&&(m.blockedOn=null);for(;0<No.length&&(f=No[0],f.blockedOn===null);)w2(f),f.blockedOn===null&&No.shift()}var M=Z.ReactCurrentBatchConfig,te=!0;function ue(s,l,f,m){var y=qt,w=M.transition;M.transition=null;try{qt=1,vn(s,l,f,m)}finally{qt=y,M.transition=w}}function at(s,l,f,m){var y=qt,w=M.transition;M.transition=null;try{qt=4,vn(s,l,f,m)}finally{qt=y,M.transition=w}}function vn(s,l,f,m){if(te){var y=fo(s,l,f,m);if(y===null)k5(s,l,m,Rn,f),_2(s,m);else if(b2(y,s,l,f,m))m.stopPropagation();else if(_2(s,m),l&4&&-1<y2.indexOf(s)){for(;y!==null;){var w=_1(y);if(w!==null&&Ga(w),w=fo(s,l,f,m),w===null&&k5(s,l,m,Rn,f),w===y)break;y=w}y!==null&&m.stopPropagation()}else k5(s,l,m,null,f)}}var Rn=null;function fo(s,l,f,m){if(Rn=null,s=Zo(m),s=id(s),s!==null)if(l=Je(s),l===null)s=null;else if(f=l.tag,f===13){if(s=wt(l),s!==null)return s;s=null}else if(f===3){if(l.stateNode.current.memoizedState.isDehydrated)return l.tag===3?l.stateNode.containerInfo:null;s=null}else l!==s&&(s=null);return Rn=s,null}function qn(s){switch(s){case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"resize":case"seeked":case"submit":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 1;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"toggle":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 4;case"message":switch(Gl()){case ga:return 1;case Lo:return 4;case Ho:case ya:return 16;case jt:return 536870912;default:return 16}default:return 16}}var ba=null,Ya=null,td=null;function s1(){if(td)return td;var s,l=Ya,f=l.length,m,y="value"in ba?ba.value:ba.textContent,w=y.length;for(s=0;s<f&&l[s]===y[s];s++);var E=f-s;for(m=1;m<=E&&l[f-m]===y[w-m];m++);return td=y.slice(s,1<m?1-m:void 0)}function rd(s){var l=s.keyCode;return"charCode"in s?(s=s.charCode,s===0&&l===13&&(s=13)):s=l,s===10&&(s=13),32<=s||s===13?s:0}function Oc(){return!0}function nd(){return!1}function po(s){function l(f,m,y,w,E){this._reactName=f,this._targetInst=y,this.type=m,this.nativeEvent=w,this.target=E,this.currentTarget=null;for(var L in s)s.hasOwnProperty(L)&&(f=s[L],this[L]=f?f(w):w[L]);return this.isDefaultPrevented=(w.defaultPrevented!=null?w.defaultPrevented:w.returnValue===!1)?Oc:nd,this.isPropagationStopped=nd,this}return H(l.prototype,{preventDefault:function(){this.defaultPrevented=!0;var f=this.nativeEvent;f&&(f.preventDefault?f.preventDefault():typeof f.returnValue!="unknown"&&(f.returnValue=!1),this.isDefaultPrevented=Oc)},stopPropagation:function(){var f=this.nativeEvent;f&&(f.stopPropagation?f.stopPropagation():typeof f.cancelBubble!="unknown"&&(f.cancelBubble=!0),this.isPropagationStopped=Oc)},persist:function(){},isPersistent:Oc}),l}var eh={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(s){return s.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},l5=po(eh),c1=H({},eh,{view:0,detail:0}),PZ=po(c1),d5,u5,l1,C2=H({},c1,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:f5,button:0,buttons:0,relatedTarget:function(s){return s.relatedTarget===void 0?s.fromElement===s.srcElement?s.toElement:s.fromElement:s.relatedTarget},movementX:function(s){return"movementX"in s?s.movementX:(s!==l1&&(l1&&s.type==="mousemove"?(d5=s.screenX-l1.screenX,u5=s.screenY-l1.screenY):u5=d5=0,l1=s),d5)},movementY:function(s){return"movementY"in s?s.movementY:u5}}),s9=po(C2),MZ=H({},C2,{dataTransfer:0}),$Z=po(MZ),OZ=H({},c1,{relatedTarget:0}),h5=po(OZ),ZZ=H({},eh,{animationName:0,elapsedTime:0,pseudoElement:0}),LZ=po(ZZ),HZ=H({},eh,{clipboardData:function(s){return"clipboardData"in s?s.clipboardData:window.clipboardData}}),NZ=po(HZ),DZ=H({},eh,{data:0}),c9=po(DZ),VZ={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},FZ={8:"Backspace",9:"Tab",12:"Clear",13:"Enter",16:"Shift",17:"Control",18:"Alt",19:"Pause",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",45:"Insert",46:"Delete",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"NumLock",145:"ScrollLock",224:"Meta"},jZ={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function zZ(s){var l=this.nativeEvent;return l.getModifierState?l.getModifierState(s):(s=jZ[s])?!!l[s]:!1}function f5(){return zZ}var BZ=H({},c1,{key:function(s){if(s.key){var l=VZ[s.key]||s.key;if(l!=="Unidentified")return l}return s.type==="keypress"?(s=rd(s),s===13?"Enter":String.fromCharCode(s)):s.type==="keydown"||s.type==="keyup"?FZ[s.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:f5,charCode:function(s){return s.type==="keypress"?rd(s):0},keyCode:function(s){return s.type==="keydown"||s.type==="keyup"?s.keyCode:0},which:function(s){return s.type==="keypress"?rd(s):s.type==="keydown"||s.type==="keyup"?s.keyCode:0}}),UZ=po(BZ),qZ=H({},C2,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),l9=po(qZ),WZ=H({},c1,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:f5}),GZ=po(WZ),KZ=H({},eh,{propertyName:0,elapsedTime:0,pseudoElement:0}),YZ=po(KZ),QZ=H({},C2,{deltaX:function(s){return"deltaX"in s?s.deltaX:"wheelDeltaX"in s?-s.wheelDeltaX:0},deltaY:function(s){return"deltaY"in s?s.deltaY:"wheelDeltaY"in s?-s.wheelDeltaY:"wheelDelta"in s?-s.wheelDelta:0},deltaZ:0,deltaMode:0}),XZ=po(QZ),JZ=[9,13,27,32],p5=c&&"CompositionEvent"in window,d1=null;c&&"documentMode"in document&&(d1=document.documentMode);var eL=c&&"TextEvent"in window&&!d1,d9=c&&(!p5||d1&&8<d1&&11>=d1),u9=" ",h9=!1;function f9(s,l){switch(s){case"keyup":return JZ.indexOf(l.keyCode)!==-1;case"keydown":return l.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function p9(s){return s=s.detail,typeof s=="object"&&"data"in s?s.data:null}var th=!1;function tL(s,l){switch(s){case"compositionend":return p9(l);case"keypress":return l.which!==32?null:(h9=!0,u9);case"textInput":return s=l.data,s===u9&&h9?null:s;default:return null}}function rL(s,l){if(th)return s==="compositionend"||!p5&&f9(s,l)?(s=s1(),td=Ya=ba=null,th=!1,s):null;switch(s){case"paste":return null;case"keypress":if(!(l.ctrlKey||l.altKey||l.metaKey)||l.ctrlKey&&l.altKey){if(l.char&&1<l.char.length)return l.char;if(l.which)return String.fromCharCode(l.which)}return null;case"compositionend":return d9&&l.locale!=="ko"?null:l.data;default:return null}}var nL={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};function m9(s){var l=s&&s.nodeName&&s.nodeName.toLowerCase();return l==="input"?!!nL[s.type]:l==="textarea"}function v9(s,l,f,m){Ul(m),l=A2(l,"onChange"),0<l.length&&(f=new l5("onChange","change",null,f,m),s.push({event:f,listeners:l}))}var u1=null,h1=null;function iL(s){O9(s,0)}function k2(s){var l=ah(s);if(Rt(l))return s}function oL(s,l){if(s==="change")return l}var g9=!1;if(c){var m5;if(c){var v5="oninput"in document;if(!v5){var y9=document.createElement("div");y9.setAttribute("oninput","return;"),v5=typeof y9.oninput=="function"}m5=v5}else m5=!1;g9=m5&&(!document.documentMode||9<document.documentMode)}function _9(){u1&&(u1.detachEvent("onpropertychange",b9),h1=u1=null)}function b9(s){if(s.propertyName==="value"&&k2(h1)){var l=[];v9(l,h1,s,Zo(s)),Wl(iL,l)}}function aL(s,l,f){s==="focusin"?(_9(),u1=l,h1=f,u1.attachEvent("onpropertychange",b9)):s==="focusout"&&_9()}function sL(s){if(s==="selectionchange"||s==="keyup"||s==="keydown")return k2(h1)}function cL(s,l){if(s==="click")return k2(l)}function lL(s,l){if(s==="input"||s==="change")return k2(l)}function dL(s,l){return s===l&&(s!==0||1/s===1/l)||s!==s&&l!==l}var wa=typeof Object.is=="function"?Object.is:dL;function f1(s,l){if(wa(s,l))return!0;if(typeof s!="object"||s===null||typeof l!="object"||l===null)return!1;var f=Object.keys(s),m=Object.keys(l);if(f.length!==m.length)return!1;for(m=0;m<f.length;m++){var y=f[m];if(!d.call(l,y)||!wa(s[y],l[y]))return!1}return!0}function w9(s){for(;s&&s.firstChild;)s=s.firstChild;return s}function x9(s,l){var f=w9(s);s=0;for(var m;f;){if(f.nodeType===3){if(m=s+f.textContent.length,s<=l&&m>=l)return{node:f,offset:l-s};s=m}e:{for(;f;){if(f.nextSibling){f=f.nextSibling;break e}f=f.parentNode}f=void 0}f=w9(f)}}function C9(s,l){return s&&l?s===l?!0:s&&s.nodeType===3?!1:l&&l.nodeType===3?C9(s,l.parentNode):"contains"in s?s.contains(l):s.compareDocumentPosition?!!(s.compareDocumentPosition(l)&16):!1:!1}function k9(){for(var s=window,l=Un();l instanceof s.HTMLIFrameElement;){try{var f=typeof l.contentWindow.location.href=="string"}catch{f=!1}if(f)s=l.contentWindow;else break;l=Un(s.document)}return l}function g5(s){var l=s&&s.nodeName&&s.nodeName.toLowerCase();return l&&(l==="input"&&(s.type==="text"||s.type==="search"||s.type==="tel"||s.type==="url"||s.type==="password")||l==="textarea"||s.contentEditable==="true")}function uL(s){var l=k9(),f=s.focusedElem,m=s.selectionRange;if(l!==f&&f&&f.ownerDocument&&C9(f.ownerDocument.documentElement,f)){if(m!==null&&g5(f)){if(l=m.start,s=m.end,s===void 0&&(s=l),"selectionStart"in f)f.selectionStart=l,f.selectionEnd=Math.min(s,f.value.length);else if(s=(l=f.ownerDocument||document)&&l.defaultView||window,s.getSelection){s=s.getSelection();var y=f.textContent.length,w=Math.min(m.start,y);m=m.end===void 0?w:Math.min(m.end,y),!s.extend&&w>m&&(y=m,m=w,w=y),y=x9(f,w);var E=x9(f,m);y&&E&&(s.rangeCount!==1||s.anchorNode!==y.node||s.anchorOffset!==y.offset||s.focusNode!==E.node||s.focusOffset!==E.offset)&&(l=l.createRange(),l.setStart(y.node,y.offset),s.removeAllRanges(),w>m?(s.addRange(l),s.extend(E.node,E.offset)):(l.setEnd(E.node,E.offset),s.addRange(l)))}}for(l=[],s=f;s=s.parentNode;)s.nodeType===1&&l.push({element:s,left:s.scrollLeft,top:s.scrollTop});for(typeof f.focus=="function"&&f.focus(),f=0;f<l.length;f++)s=l[f],s.element.scrollLeft=s.left,s.element.scrollTop=s.top}}var hL=c&&"documentMode"in document&&11>=document.documentMode,rh=null,y5=null,p1=null,_5=!1;function E9(s,l,f){var m=f.window===f?f.document:f.nodeType===9?f:f.ownerDocument;_5||rh==null||rh!==Un(m)||(m=rh,"selectionStart"in m&&g5(m)?m={start:m.selectionStart,end:m.selectionEnd}:(m=(m.ownerDocument&&m.ownerDocument.defaultView||window).getSelection(),m={anchorNode:m.anchorNode,anchorOffset:m.anchorOffset,focusNode:m.focusNode,focusOffset:m.focusOffset}),p1&&f1(p1,m)||(p1=m,m=A2(y5,"onSelect"),0<m.length&&(l=new l5("onSelect","select",null,l,f),s.push({event:l,listeners:m}),l.target=rh)))}function E2(s,l){var f={};return f[s.toLowerCase()]=l.toLowerCase(),f["Webkit"+s]="webkit"+l,f["Moz"+s]="moz"+l,f}var nh={animationend:E2("Animation","AnimationEnd"),animationiteration:E2("Animation","AnimationIteration"),animationstart:E2("Animation","AnimationStart"),transitionend:E2("Transition","TransitionEnd")},b5={},S9={};c&&(S9=document.createElement("div").style,"AnimationEvent"in window||(delete nh.animationend.animation,delete nh.animationiteration.animation,delete nh.animationstart.animation),"TransitionEvent"in window||delete nh.transitionend.transition);function S2(s){if(b5[s])return b5[s];if(!nh[s])return s;var l=nh[s],f;for(f in l)if(l.hasOwnProperty(f)&&f in S9)return b5[s]=l[f];return s}var T9=S2("animationend"),A9=S2("animationiteration"),I9=S2("animationstart"),R9=S2("transitionend"),P9=new Map,M9="abort auxClick cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel".split(" ");function Zc(s,l){P9.set(s,l),o(l,[s])}for(var w5=0;w5<M9.length;w5++){var x5=M9[w5],fL=x5.toLowerCase(),pL=x5[0].toUpperCase()+x5.slice(1);Zc(fL,"on"+pL)}Zc(T9,"onAnimationEnd"),Zc(A9,"onAnimationIteration"),Zc(I9,"onAnimationStart"),Zc("dblclick","onDoubleClick"),Zc("focusin","onFocus"),Zc("focusout","onBlur"),Zc(R9,"onTransitionEnd"),a("onMouseEnter",["mouseout","mouseover"]),a("onMouseLeave",["mouseout","mouseover"]),a("onPointerEnter",["pointerout","pointerover"]),a("onPointerLeave",["pointerout","pointerover"]),o("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),o("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),o("onBeforeInput",["compositionend","keypress","textInput","paste"]),o("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),o("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),o("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var m1="abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange resize seeked seeking stalled suspend timeupdate volumechange waiting".split(" "),mL=new Set("cancel close invalid load scroll toggle".split(" ").concat(m1));function $9(s,l,f){var m=s.type||"unknown-event";s.currentTarget=f,je(m,l,void 0,s),s.currentTarget=null}function O9(s,l){l=(l&4)!==0;for(var f=0;f<s.length;f++){var m=s[f],y=m.event;m=m.listeners;e:{var w=void 0;if(l)for(var E=m.length-1;0<=E;E--){var L=m[E],V=L.instance,ne=L.currentTarget;if(L=L.listener,V!==w&&y.isPropagationStopped())break e;$9(y,L,ne),w=V}else for(E=0;E<m.length;E++){if(L=m[E],V=L.instance,ne=L.currentTarget,L=L.listener,V!==w&&y.isPropagationStopped())break e;$9(y,L,ne),w=V}}}if(Ve)throw s=mt,Ve=!1,mt=null,s}function Zr(s,l){var f=l[R5];f===void 0&&(f=l[R5]=new Set);var m=s+"__bubble";f.has(m)||(Z9(l,s,2,!1),f.add(m))}function C5(s,l,f){var m=0;l&&(m|=4),Z9(f,s,m,l)}var T2="_reactListening"+Math.random().toString(36).slice(2);function v1(s){if(!s[T2]){s[T2]=!0,n.forEach(function(f){f!=="selectionchange"&&(mL.has(f)||C5(f,!1,s),C5(f,!0,s))});var l=s.nodeType===9?s:s.ownerDocument;l===null||l[T2]||(l[T2]=!0,C5("selectionchange",!1,l))}}function Z9(s,l,f,m){switch(qn(l)){case 1:var y=ue;break;case 4:y=at;break;default:y=vn}f=y.bind(null,l,f,s),y=void 0,!D||l!=="touchstart"&&l!=="touchmove"&&l!=="wheel"||(y=!0),m?y!==void 0?s.addEventListener(l,f,{capture:!0,passive:y}):s.addEventListener(l,f,!0):y!==void 0?s.addEventListener(l,f,{passive:y}):s.addEventListener(l,f,!1)}function k5(s,l,f,m,y){var w=m;if(!(l&1)&&!(l&2)&&m!==null)e:for(;;){if(m===null)return;var E=m.tag;if(E===3||E===4){var L=m.stateNode.containerInfo;if(L===y||L.nodeType===8&&L.parentNode===y)break;if(E===4)for(E=m.return;E!==null;){var V=E.tag;if((V===3||V===4)&&(V=E.stateNode.containerInfo,V===y||V.nodeType===8&&V.parentNode===y))return;E=E.return}for(;L!==null;){if(E=id(L),E===null)return;if(V=E.tag,V===5||V===6){m=w=E;continue e}L=L.parentNode}}m=m.return}Wl(function(){var ne=w,ge=Zo(f),_e=[];e:{var ve=P9.get(s);if(ve!==void 0){var Fe=l5,tt=s;switch(s){case"keypress":if(rd(f)===0)break e;case"keydown":case"keyup":Fe=UZ;break;case"focusin":tt="focus",Fe=h5;break;case"focusout":tt="blur",Fe=h5;break;case"beforeblur":case"afterblur":Fe=h5;break;case"click":if(f.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":Fe=s9;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":Fe=$Z;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":Fe=GZ;break;case T9:case A9:case I9:Fe=LZ;break;case R9:Fe=YZ;break;case"scroll":Fe=PZ;break;case"wheel":Fe=XZ;break;case"copy":case"cut":case"paste":Fe=NZ;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":Fe=l9}var nt=(l&4)!==0,gn=!nt&&s==="scroll",X=nt?ve!==null?ve+"Capture":null:ve;nt=[];for(var W=ne,ee;W!==null;){ee=W;var Se=ee.stateNode;if(ee.tag===5&&Se!==null&&(ee=Se,X!==null&&(Se=Ri(W,X),Se!=null&&nt.push(g1(W,Se,ee)))),gn)break;W=W.return}0<nt.length&&(ve=new Fe(ve,tt,null,f,ge),_e.push({event:ve,listeners:nt}))}}if(!(l&7)){e:{if(ve=s==="mouseover"||s==="pointerover",Fe=s==="mouseout"||s==="pointerout",ve&&f!==Oo&&(tt=f.relatedTarget||f.fromElement)&&(id(tt)||tt[Ls]))break e;if((Fe||ve)&&(ve=ge.window===ge?ge:(ve=ge.ownerDocument)?ve.defaultView||ve.parentWindow:window,Fe?(tt=f.relatedTarget||f.toElement,Fe=ne,tt=tt?id(tt):null,tt!==null&&(gn=Je(tt),tt!==gn||tt.tag!==5&&tt.tag!==6)&&(tt=null)):(Fe=null,tt=ne),Fe!==tt)){if(nt=s9,Se="onMouseLeave",X="onMouseEnter",W="mouse",(s==="pointerout"||s==="pointerover")&&(nt=l9,Se="onPointerLeave",X="onPointerEnter",W="pointer"),gn=Fe==null?ve:ah(Fe),ee=tt==null?ve:ah(tt),ve=new nt(Se,W+"leave",Fe,f,ge),ve.target=gn,ve.relatedTarget=ee,Se=null,id(ge)===ne&&(nt=new nt(X,W+"enter",tt,f,ge),nt.target=ee,nt.relatedTarget=gn,Se=nt),gn=Se,Fe&&tt)t:{for(nt=Fe,X=tt,W=0,ee=nt;ee;ee=ih(ee))W++;for(ee=0,Se=X;Se;Se=ih(Se))ee++;for(;0<W-ee;)nt=ih(nt),W--;for(;0<ee-W;)X=ih(X),ee--;for(;W--;){if(nt===X||X!==null&&nt===X.alternate)break t;nt=ih(nt),X=ih(X)}nt=null}else nt=null;Fe!==null&&L9(_e,ve,Fe,nt,!1),tt!==null&&gn!==null&&L9(_e,gn,tt,nt,!0)}}e:{if(ve=ne?ah(ne):window,Fe=ve.nodeName&&ve.nodeName.toLowerCase(),Fe==="select"||Fe==="input"&&ve.type==="file")var st=oL;else if(m9(ve))if(g9)st=lL;else{st=sL;var ht=aL}else(Fe=ve.nodeName)&&Fe.toLowerCase()==="input"&&(ve.type==="checkbox"||ve.type==="radio")&&(st=cL);if(st&&(st=st(s,ne))){v9(_e,st,f,ge);break e}ht&&ht(s,ve,ne),s==="focusout"&&(ht=ve._wrapperState)&&ht.controlled&&ve.type==="number"&&Tc(ve,"number",ve.value)}switch(ht=ne?ah(ne):window,s){case"focusin":(m9(ht)||ht.contentEditable==="true")&&(rh=ht,y5=ne,p1=null);break;case"focusout":p1=y5=rh=null;break;case"mousedown":_5=!0;break;case"contextmenu":case"mouseup":case"dragend":_5=!1,E9(_e,f,ge);break;case"selectionchange":if(hL)break;case"keydown":case"keyup":E9(_e,f,ge)}var ft;if(p5)e:{switch(s){case"compositionstart":var xt="onCompositionStart";break e;case"compositionend":xt="onCompositionEnd";break e;case"compositionupdate":xt="onCompositionUpdate";break e}xt=void 0}else th?f9(s,f)&&(xt="onCompositionEnd"):s==="keydown"&&f.keyCode===229&&(xt="onCompositionStart");xt&&(d9&&f.locale!=="ko"&&(th||xt!=="onCompositionStart"?xt==="onCompositionEnd"&&th&&(ft=s1()):(ba=ge,Ya="value"in ba?ba.value:ba.textContent,th=!0)),ht=A2(ne,xt),0<ht.length&&(xt=new c9(xt,s,null,f,ge),_e.push({event:xt,listeners:ht}),ft?xt.data=ft:(ft=p9(f),ft!==null&&(xt.data=ft)))),(ft=eL?tL(s,f):rL(s,f))&&(ne=A2(ne,"onBeforeInput"),0<ne.length&&(ge=new c9("onBeforeInput","beforeinput",null,f,ge),_e.push({event:ge,listeners:ne}),ge.data=ft))}O9(_e,l)})}function g1(s,l,f){return{instance:s,listener:l,currentTarget:f}}function A2(s,l){for(var f=l+"Capture",m=[];s!==null;){var y=s,w=y.stateNode;y.tag===5&&w!==null&&(y=w,w=Ri(s,f),w!=null&&m.unshift(g1(s,w,y)),w=Ri(s,l),w!=null&&m.push(g1(s,w,y))),s=s.return}return m}function ih(s){if(s===null)return null;do s=s.return;while(s&&s.tag!==5);return s||null}function L9(s,l,f,m,y){for(var w=l._reactName,E=[];f!==null&&f!==m;){var L=f,V=L.alternate,ne=L.stateNode;if(V!==null&&V===m)break;L.tag===5&&ne!==null&&(L=ne,y?(V=Ri(f,w),V!=null&&E.unshift(g1(f,V,L))):y||(V=Ri(f,w),V!=null&&E.push(g1(f,V,L)))),f=f.return}E.length!==0&&s.push({event:l,listeners:E})}var vL=/\r\n?/g,gL=/\u0000|\uFFFD/g;function H9(s){return(typeof s=="string"?s:""+s).replace(vL,`
38
- `).replace(gL,"")}function I2(s,l,f){if(l=H9(l),H9(s)!==l&&f)throw Error(t(425))}function R2(){}var E5=null,S5=null;function T5(s,l){return s==="textarea"||s==="noscript"||typeof l.children=="string"||typeof l.children=="number"||typeof l.dangerouslySetInnerHTML=="object"&&l.dangerouslySetInnerHTML!==null&&l.dangerouslySetInnerHTML.__html!=null}var A5=typeof setTimeout=="function"?setTimeout:void 0,yL=typeof clearTimeout=="function"?clearTimeout:void 0,N9=typeof Promise=="function"?Promise:void 0,_L=typeof queueMicrotask=="function"?queueMicrotask:typeof N9<"u"?function(s){return N9.resolve(null).then(s).catch(bL)}:A5;function bL(s){setTimeout(function(){throw s})}function I5(s,l){var f=l,m=0;do{var y=f.nextSibling;if(s.removeChild(f),y&&y.nodeType===8)if(f=y.data,f==="/$"){if(m===0){s.removeChild(y),ed(l);return}m--}else f!=="$"&&f!=="$?"&&f!=="$!"||m++;f=y}while(f);ed(l)}function Lc(s){for(;s!=null;s=s.nextSibling){var l=s.nodeType;if(l===1||l===3)break;if(l===8){if(l=s.data,l==="$"||l==="$!"||l==="$?")break;if(l==="/$")return null}}return s}function D9(s){s=s.previousSibling;for(var l=0;s;){if(s.nodeType===8){var f=s.data;if(f==="$"||f==="$!"||f==="$?"){if(l===0)return s;l--}else f==="/$"&&l++}s=s.previousSibling}return null}var oh=Math.random().toString(36).slice(2),Qa="__reactFiber$"+oh,y1="__reactProps$"+oh,Ls="__reactContainer$"+oh,R5="__reactEvents$"+oh,wL="__reactListeners$"+oh,xL="__reactHandles$"+oh;function id(s){var l=s[Qa];if(l)return l;for(var f=s.parentNode;f;){if(l=f[Ls]||f[Qa]){if(f=l.alternate,l.child!==null||f!==null&&f.child!==null)for(s=D9(s);s!==null;){if(f=s[Qa])return f;s=D9(s)}return l}s=f,f=s.parentNode}return null}function _1(s){return s=s[Qa]||s[Ls],!s||s.tag!==5&&s.tag!==6&&s.tag!==13&&s.tag!==3?null:s}function ah(s){if(s.tag===5||s.tag===6)return s.stateNode;throw Error(t(33))}function P2(s){return s[y1]||null}var P5=[],sh=-1;function Hc(s){return{current:s}}function Lr(s){0>sh||(s.current=P5[sh],P5[sh]=null,sh--)}function Ir(s,l){sh++,P5[sh]=s.current,s.current=l}var Nc={},di=Hc(Nc),Gi=Hc(!1),od=Nc;function ch(s,l){var f=s.type.contextTypes;if(!f)return Nc;var m=s.stateNode;if(m&&m.__reactInternalMemoizedUnmaskedChildContext===l)return m.__reactInternalMemoizedMaskedChildContext;var y={},w;for(w in f)y[w]=l[w];return m&&(s=s.stateNode,s.__reactInternalMemoizedUnmaskedChildContext=l,s.__reactInternalMemoizedMaskedChildContext=y),y}function Ki(s){return s=s.childContextTypes,s!=null}function M2(){Lr(Gi),Lr(di)}function V9(s,l,f){if(di.current!==Nc)throw Error(t(168));Ir(di,l),Ir(Gi,f)}function F9(s,l,f){var m=s.stateNode;if(l=l.childContextTypes,typeof m.getChildContext!="function")return f;m=m.getChildContext();for(var y in m)if(!(y in l))throw Error(t(108,Ke(s)||"Unknown",y));return H({},f,m)}function $2(s){return s=(s=s.stateNode)&&s.__reactInternalMemoizedMergedChildContext||Nc,od=di.current,Ir(di,s),Ir(Gi,Gi.current),!0}function j9(s,l,f){var m=s.stateNode;if(!m)throw Error(t(169));f?(s=F9(s,l,od),m.__reactInternalMemoizedMergedChildContext=s,Lr(Gi),Lr(di),Ir(di,s)):Lr(Gi),Ir(Gi,f)}var Hs=null,O2=!1,M5=!1;function z9(s){Hs===null?Hs=[s]:Hs.push(s)}function CL(s){O2=!0,z9(s)}function Dc(){if(!M5&&Hs!==null){M5=!0;var s=0,l=qt;try{var f=Hs;for(qt=1;s<f.length;s++){var m=f[s];do m=m(!0);while(m!==null)}Hs=null,O2=!1}catch(y){throw Hs!==null&&(Hs=Hs.slice(s+1)),Er(ga,Dc),y}finally{qt=l,M5=!1}}return null}var lh=[],dh=0,Z2=null,L2=0,Do=[],Vo=0,ad=null,Ns=1,Ds="";function sd(s,l){lh[dh++]=L2,lh[dh++]=Z2,Z2=s,L2=l}function B9(s,l,f){Do[Vo++]=Ns,Do[Vo++]=Ds,Do[Vo++]=ad,ad=s;var m=Ns;s=Ds;var y=32-Yt(m)-1;m&=~(1<<y),f+=1;var w=32-Yt(l)+y;if(30<w){var E=y-y%5;w=(m&(1<<E)-1).toString(32),m>>=E,y-=E,Ns=1<<32-Yt(l)+y|f<<y|m,Ds=w+s}else Ns=1<<w|f<<y|m,Ds=s}function $5(s){s.return!==null&&(sd(s,1),B9(s,1,0))}function O5(s){for(;s===Z2;)Z2=lh[--dh],lh[dh]=null,L2=lh[--dh],lh[dh]=null;for(;s===ad;)ad=Do[--Vo],Do[Vo]=null,Ds=Do[--Vo],Do[Vo]=null,Ns=Do[--Vo],Do[Vo]=null}var mo=null,vo=null,Vr=!1,xa=null;function U9(s,l){var f=Bo(5,null,null,0);f.elementType="DELETED",f.stateNode=l,f.return=s,l=s.deletions,l===null?(s.deletions=[f],s.flags|=16):l.push(f)}function q9(s,l){switch(s.tag){case 5:var f=s.type;return l=l.nodeType!==1||f.toLowerCase()!==l.nodeName.toLowerCase()?null:l,l!==null?(s.stateNode=l,mo=s,vo=Lc(l.firstChild),!0):!1;case 6:return l=s.pendingProps===""||l.nodeType!==3?null:l,l!==null?(s.stateNode=l,mo=s,vo=null,!0):!1;case 13:return l=l.nodeType!==8?null:l,l!==null?(f=ad!==null?{id:Ns,overflow:Ds}:null,s.memoizedState={dehydrated:l,treeContext:f,retryLane:1073741824},f=Bo(18,null,null,0),f.stateNode=l,f.return=s,s.child=f,mo=s,vo=null,!0):!1;default:return!1}}function Z5(s){return(s.mode&1)!==0&&(s.flags&128)===0}function L5(s){if(Vr){var l=vo;if(l){var f=l;if(!q9(s,l)){if(Z5(s))throw Error(t(418));l=Lc(f.nextSibling);var m=mo;l&&q9(s,l)?U9(m,f):(s.flags=s.flags&-4097|2,Vr=!1,mo=s)}}else{if(Z5(s))throw Error(t(418));s.flags=s.flags&-4097|2,Vr=!1,mo=s}}}function W9(s){for(s=s.return;s!==null&&s.tag!==5&&s.tag!==3&&s.tag!==13;)s=s.return;mo=s}function H2(s){if(s!==mo)return!1;if(!Vr)return W9(s),Vr=!0,!1;var l;if((l=s.tag!==3)&&!(l=s.tag!==5)&&(l=s.type,l=l!=="head"&&l!=="body"&&!T5(s.type,s.memoizedProps)),l&&(l=vo)){if(Z5(s))throw G9(),Error(t(418));for(;l;)U9(s,l),l=Lc(l.nextSibling)}if(W9(s),s.tag===13){if(s=s.memoizedState,s=s!==null?s.dehydrated:null,!s)throw Error(t(317));e:{for(s=s.nextSibling,l=0;s;){if(s.nodeType===8){var f=s.data;if(f==="/$"){if(l===0){vo=Lc(s.nextSibling);break e}l--}else f!=="$"&&f!=="$!"&&f!=="$?"||l++}s=s.nextSibling}vo=null}}else vo=mo?Lc(s.stateNode.nextSibling):null;return!0}function G9(){for(var s=vo;s;)s=Lc(s.nextSibling)}function uh(){vo=mo=null,Vr=!1}function H5(s){xa===null?xa=[s]:xa.push(s)}var kL=Z.ReactCurrentBatchConfig;function b1(s,l,f){if(s=f.ref,s!==null&&typeof s!="function"&&typeof s!="object"){if(f._owner){if(f=f._owner,f){if(f.tag!==1)throw Error(t(309));var m=f.stateNode}if(!m)throw Error(t(147,s));var y=m,w=""+s;return l!==null&&l.ref!==null&&typeof l.ref=="function"&&l.ref._stringRef===w?l.ref:(l=function(E){var L=y.refs;E===null?delete L[w]:L[w]=E},l._stringRef=w,l)}if(typeof s!="string")throw Error(t(284));if(!f._owner)throw Error(t(290,s))}return s}function N2(s,l){throw s=Object.prototype.toString.call(l),Error(t(31,s==="[object Object]"?"object with keys {"+Object.keys(l).join(", ")+"}":s))}function K9(s){var l=s._init;return l(s._payload)}function Y9(s){function l(X,W){if(s){var ee=X.deletions;ee===null?(X.deletions=[W],X.flags|=16):ee.push(W)}}function f(X,W){if(!s)return null;for(;W!==null;)l(X,W),W=W.sibling;return null}function m(X,W){for(X=new Map;W!==null;)W.key!==null?X.set(W.key,W):X.set(W.index,W),W=W.sibling;return X}function y(X,W){return X=Wc(X,W),X.index=0,X.sibling=null,X}function w(X,W,ee){return X.index=ee,s?(ee=X.alternate,ee!==null?(ee=ee.index,ee<W?(X.flags|=2,W):ee):(X.flags|=2,W)):(X.flags|=1048576,W)}function E(X){return s&&X.alternate===null&&(X.flags|=2),X}function L(X,W,ee,Se){return W===null||W.tag!==6?(W=Ay(ee,X.mode,Se),W.return=X,W):(W=y(W,ee),W.return=X,W)}function V(X,W,ee,Se){var st=ee.type;return st===I?ge(X,W,ee.props.children,Se,ee.key):W!==null&&(W.elementType===st||typeof st=="object"&&st!==null&&st.$$typeof===re&&K9(st)===W.type)?(Se=y(W,ee.props),Se.ref=b1(X,W,ee),Se.return=X,Se):(Se=c0(ee.type,ee.key,ee.props,null,X.mode,Se),Se.ref=b1(X,W,ee),Se.return=X,Se)}function ne(X,W,ee,Se){return W===null||W.tag!==4||W.stateNode.containerInfo!==ee.containerInfo||W.stateNode.implementation!==ee.implementation?(W=Iy(ee,X.mode,Se),W.return=X,W):(W=y(W,ee.children||[]),W.return=X,W)}function ge(X,W,ee,Se,st){return W===null||W.tag!==7?(W=md(ee,X.mode,Se,st),W.return=X,W):(W=y(W,ee),W.return=X,W)}function _e(X,W,ee){if(typeof W=="string"&&W!==""||typeof W=="number")return W=Ay(""+W,X.mode,ee),W.return=X,W;if(typeof W=="object"&&W!==null){switch(W.$$typeof){case B:return ee=c0(W.type,W.key,W.props,null,X.mode,ee),ee.ref=b1(X,null,W),ee.return=X,ee;case U:return W=Iy(W,X.mode,ee),W.return=X,W;case re:var Se=W._init;return _e(X,Se(W._payload),ee)}if(Po(W)||O(W))return W=md(W,X.mode,ee,null),W.return=X,W;N2(X,W)}return null}function ve(X,W,ee,Se){var st=W!==null?W.key:null;if(typeof ee=="string"&&ee!==""||typeof ee=="number")return st!==null?null:L(X,W,""+ee,Se);if(typeof ee=="object"&&ee!==null){switch(ee.$$typeof){case B:return ee.key===st?V(X,W,ee,Se):null;case U:return ee.key===st?ne(X,W,ee,Se):null;case re:return st=ee._init,ve(X,W,st(ee._payload),Se)}if(Po(ee)||O(ee))return st!==null?null:ge(X,W,ee,Se,null);N2(X,ee)}return null}function Fe(X,W,ee,Se,st){if(typeof Se=="string"&&Se!==""||typeof Se=="number")return X=X.get(ee)||null,L(W,X,""+Se,st);if(typeof Se=="object"&&Se!==null){switch(Se.$$typeof){case B:return X=X.get(Se.key===null?ee:Se.key)||null,V(W,X,Se,st);case U:return X=X.get(Se.key===null?ee:Se.key)||null,ne(W,X,Se,st);case re:var ht=Se._init;return Fe(X,W,ee,ht(Se._payload),st)}if(Po(Se)||O(Se))return X=X.get(ee)||null,ge(W,X,Se,st,null);N2(W,Se)}return null}function tt(X,W,ee,Se){for(var st=null,ht=null,ft=W,xt=W=0,Nn=null;ft!==null&&xt<ee.length;xt++){ft.index>xt?(Nn=ft,ft=null):Nn=ft.sibling;var tr=ve(X,ft,ee[xt],Se);if(tr===null){ft===null&&(ft=Nn);break}s&&ft&&tr.alternate===null&&l(X,ft),W=w(tr,W,xt),ht===null?st=tr:ht.sibling=tr,ht=tr,ft=Nn}if(xt===ee.length)return f(X,ft),Vr&&sd(X,xt),st;if(ft===null){for(;xt<ee.length;xt++)ft=_e(X,ee[xt],Se),ft!==null&&(W=w(ft,W,xt),ht===null?st=ft:ht.sibling=ft,ht=ft);return Vr&&sd(X,xt),st}for(ft=m(X,ft);xt<ee.length;xt++)Nn=Fe(ft,X,xt,ee[xt],Se),Nn!==null&&(s&&Nn.alternate!==null&&ft.delete(Nn.key===null?xt:Nn.key),W=w(Nn,W,xt),ht===null?st=Nn:ht.sibling=Nn,ht=Nn);return s&&ft.forEach(function(Gc){return l(X,Gc)}),Vr&&sd(X,xt),st}function nt(X,W,ee,Se){var st=O(ee);if(typeof st!="function")throw Error(t(150));if(ee=st.call(ee),ee==null)throw Error(t(151));for(var ht=st=null,ft=W,xt=W=0,Nn=null,tr=ee.next();ft!==null&&!tr.done;xt++,tr=ee.next()){ft.index>xt?(Nn=ft,ft=null):Nn=ft.sibling;var Gc=ve(X,ft,tr.value,Se);if(Gc===null){ft===null&&(ft=Nn);break}s&&ft&&Gc.alternate===null&&l(X,ft),W=w(Gc,W,xt),ht===null?st=Gc:ht.sibling=Gc,ht=Gc,ft=Nn}if(tr.done)return f(X,ft),Vr&&sd(X,xt),st;if(ft===null){for(;!tr.done;xt++,tr=ee.next())tr=_e(X,tr.value,Se),tr!==null&&(W=w(tr,W,xt),ht===null?st=tr:ht.sibling=tr,ht=tr);return Vr&&sd(X,xt),st}for(ft=m(X,ft);!tr.done;xt++,tr=ee.next())tr=Fe(ft,X,xt,tr.value,Se),tr!==null&&(s&&tr.alternate!==null&&ft.delete(tr.key===null?xt:tr.key),W=w(tr,W,xt),ht===null?st=tr:ht.sibling=tr,ht=tr);return s&&ft.forEach(function(nH){return l(X,nH)}),Vr&&sd(X,xt),st}function gn(X,W,ee,Se){if(typeof ee=="object"&&ee!==null&&ee.type===I&&ee.key===null&&(ee=ee.props.children),typeof ee=="object"&&ee!==null){switch(ee.$$typeof){case B:e:{for(var st=ee.key,ht=W;ht!==null;){if(ht.key===st){if(st=ee.type,st===I){if(ht.tag===7){f(X,ht.sibling),W=y(ht,ee.props.children),W.return=X,X=W;break e}}else if(ht.elementType===st||typeof st=="object"&&st!==null&&st.$$typeof===re&&K9(st)===ht.type){f(X,ht.sibling),W=y(ht,ee.props),W.ref=b1(X,ht,ee),W.return=X,X=W;break e}f(X,ht);break}else l(X,ht);ht=ht.sibling}ee.type===I?(W=md(ee.props.children,X.mode,Se,ee.key),W.return=X,X=W):(Se=c0(ee.type,ee.key,ee.props,null,X.mode,Se),Se.ref=b1(X,W,ee),Se.return=X,X=Se)}return E(X);case U:e:{for(ht=ee.key;W!==null;){if(W.key===ht)if(W.tag===4&&W.stateNode.containerInfo===ee.containerInfo&&W.stateNode.implementation===ee.implementation){f(X,W.sibling),W=y(W,ee.children||[]),W.return=X,X=W;break e}else{f(X,W);break}else l(X,W);W=W.sibling}W=Iy(ee,X.mode,Se),W.return=X,X=W}return E(X);case re:return ht=ee._init,gn(X,W,ht(ee._payload),Se)}if(Po(ee))return tt(X,W,ee,Se);if(O(ee))return nt(X,W,ee,Se);N2(X,ee)}return typeof ee=="string"&&ee!==""||typeof ee=="number"?(ee=""+ee,W!==null&&W.tag===6?(f(X,W.sibling),W=y(W,ee),W.return=X,X=W):(f(X,W),W=Ay(ee,X.mode,Se),W.return=X,X=W),E(X)):f(X,W)}return gn}var hh=Y9(!0),Q9=Y9(!1),D2=Hc(null),V2=null,fh=null,N5=null;function D5(){N5=fh=V2=null}function V5(s){var l=D2.current;Lr(D2),s._currentValue=l}function F5(s,l,f){for(;s!==null;){var m=s.alternate;if((s.childLanes&l)!==l?(s.childLanes|=l,m!==null&&(m.childLanes|=l)):m!==null&&(m.childLanes&l)!==l&&(m.childLanes|=l),s===f)break;s=s.return}}function ph(s,l){V2=s,N5=fh=null,s=s.dependencies,s!==null&&s.firstContext!==null&&(s.lanes&l&&(Yi=!0),s.firstContext=null)}function Fo(s){var l=s._currentValue;if(N5!==s)if(s={context:s,memoizedValue:l,next:null},fh===null){if(V2===null)throw Error(t(308));fh=s,V2.dependencies={lanes:0,firstContext:s}}else fh=fh.next=s;return l}var cd=null;function j5(s){cd===null?cd=[s]:cd.push(s)}function X9(s,l,f,m){var y=l.interleaved;return y===null?(f.next=f,j5(l)):(f.next=y.next,y.next=f),l.interleaved=f,Vs(s,m)}function Vs(s,l){s.lanes|=l;var f=s.alternate;for(f!==null&&(f.lanes|=l),f=s,s=s.return;s!==null;)s.childLanes|=l,f=s.alternate,f!==null&&(f.childLanes|=l),f=s,s=s.return;return f.tag===3?f.stateNode:null}var Vc=!1;function z5(s){s.updateQueue={baseState:s.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function J9(s,l){s=s.updateQueue,l.updateQueue===s&&(l.updateQueue={baseState:s.baseState,firstBaseUpdate:s.firstBaseUpdate,lastBaseUpdate:s.lastBaseUpdate,shared:s.shared,effects:s.effects})}function Fs(s,l){return{eventTime:s,lane:l,tag:0,payload:null,callback:null,next:null}}function Fc(s,l,f){var m=s.updateQueue;if(m===null)return null;if(m=m.shared,Xt&2){var y=m.pending;return y===null?l.next=l:(l.next=y.next,y.next=l),m.pending=l,Vs(s,f)}return y=m.interleaved,y===null?(l.next=l,j5(m)):(l.next=y.next,y.next=l),m.interleaved=l,Vs(s,f)}function F2(s,l,f){if(l=l.updateQueue,l!==null&&(l=l.shared,(f&4194240)!==0)){var m=l.lanes;m&=s.pendingLanes,f|=m,l.lanes=f,Mc(s,f)}}function e7(s,l){var f=s.updateQueue,m=s.alternate;if(m!==null&&(m=m.updateQueue,f===m)){var y=null,w=null;if(f=f.firstBaseUpdate,f!==null){do{var E={eventTime:f.eventTime,lane:f.lane,tag:f.tag,payload:f.payload,callback:f.callback,next:null};w===null?y=w=E:w=w.next=E,f=f.next}while(f!==null);w===null?y=w=l:w=w.next=l}else y=w=l;f={baseState:m.baseState,firstBaseUpdate:y,lastBaseUpdate:w,shared:m.shared,effects:m.effects},s.updateQueue=f;return}s=f.lastBaseUpdate,s===null?f.firstBaseUpdate=l:s.next=l,f.lastBaseUpdate=l}function j2(s,l,f,m){var y=s.updateQueue;Vc=!1;var w=y.firstBaseUpdate,E=y.lastBaseUpdate,L=y.shared.pending;if(L!==null){y.shared.pending=null;var V=L,ne=V.next;V.next=null,E===null?w=ne:E.next=ne,E=V;var ge=s.alternate;ge!==null&&(ge=ge.updateQueue,L=ge.lastBaseUpdate,L!==E&&(L===null?ge.firstBaseUpdate=ne:L.next=ne,ge.lastBaseUpdate=V))}if(w!==null){var _e=y.baseState;E=0,ge=ne=V=null,L=w;do{var ve=L.lane,Fe=L.eventTime;if((m&ve)===ve){ge!==null&&(ge=ge.next={eventTime:Fe,lane:0,tag:L.tag,payload:L.payload,callback:L.callback,next:null});e:{var tt=s,nt=L;switch(ve=l,Fe=f,nt.tag){case 1:if(tt=nt.payload,typeof tt=="function"){_e=tt.call(Fe,_e,ve);break e}_e=tt;break e;case 3:tt.flags=tt.flags&-65537|128;case 0:if(tt=nt.payload,ve=typeof tt=="function"?tt.call(Fe,_e,ve):tt,ve==null)break e;_e=H({},_e,ve);break e;case 2:Vc=!0}}L.callback!==null&&L.lane!==0&&(s.flags|=64,ve=y.effects,ve===null?y.effects=[L]:ve.push(L))}else Fe={eventTime:Fe,lane:ve,tag:L.tag,payload:L.payload,callback:L.callback,next:null},ge===null?(ne=ge=Fe,V=_e):ge=ge.next=Fe,E|=ve;if(L=L.next,L===null){if(L=y.shared.pending,L===null)break;ve=L,L=ve.next,ve.next=null,y.lastBaseUpdate=ve,y.shared.pending=null}}while(!0);if(ge===null&&(V=_e),y.baseState=V,y.firstBaseUpdate=ne,y.lastBaseUpdate=ge,l=y.shared.interleaved,l!==null){y=l;do E|=y.lane,y=y.next;while(y!==l)}else w===null&&(y.shared.lanes=0);ud|=E,s.lanes=E,s.memoizedState=_e}}function t7(s,l,f){if(s=l.effects,l.effects=null,s!==null)for(l=0;l<s.length;l++){var m=s[l],y=m.callback;if(y!==null){if(m.callback=null,m=f,typeof y!="function")throw Error(t(191,y));y.call(m)}}}var w1={},Xa=Hc(w1),x1=Hc(w1),C1=Hc(w1);function ld(s){if(s===w1)throw Error(t(174));return s}function B5(s,l){switch(Ir(C1,l),Ir(x1,s),Ir(Xa,w1),s=l.nodeType,s){case 9:case 11:l=(l=l.documentElement)?l.namespaceURI:Ba(null,"");break;default:s=s===8?l.parentNode:l,l=s.namespaceURI||null,s=s.tagName,l=Ba(l,s)}Lr(Xa),Ir(Xa,l)}function mh(){Lr(Xa),Lr(x1),Lr(C1)}function r7(s){ld(C1.current);var l=ld(Xa.current),f=Ba(l,s.type);l!==f&&(Ir(x1,s),Ir(Xa,f))}function U5(s){x1.current===s&&(Lr(Xa),Lr(x1))}var Gr=Hc(0);function z2(s){for(var l=s;l!==null;){if(l.tag===13){var f=l.memoizedState;if(f!==null&&(f=f.dehydrated,f===null||f.data==="$?"||f.data==="$!"))return l}else if(l.tag===19&&l.memoizedProps.revealOrder!==void 0){if(l.flags&128)return l}else if(l.child!==null){l.child.return=l,l=l.child;continue}if(l===s)break;for(;l.sibling===null;){if(l.return===null||l.return===s)return null;l=l.return}l.sibling.return=l.return,l=l.sibling}return null}var q5=[];function W5(){for(var s=0;s<q5.length;s++)q5[s]._workInProgressVersionPrimary=null;q5.length=0}var B2=Z.ReactCurrentDispatcher,G5=Z.ReactCurrentBatchConfig,dd=0,Kr=null,Pn=null,Ln=null,U2=!1,k1=!1,E1=0,EL=0;function ui(){throw Error(t(321))}function K5(s,l){if(l===null)return!1;for(var f=0;f<l.length&&f<s.length;f++)if(!wa(s[f],l[f]))return!1;return!0}function Y5(s,l,f,m,y,w){if(dd=w,Kr=l,l.memoizedState=null,l.updateQueue=null,l.lanes=0,B2.current=s===null||s.memoizedState===null?IL:RL,s=f(m,y),k1){w=0;do{if(k1=!1,E1=0,25<=w)throw Error(t(301));w+=1,Ln=Pn=null,l.updateQueue=null,B2.current=PL,s=f(m,y)}while(k1)}if(B2.current=G2,l=Pn!==null&&Pn.next!==null,dd=0,Ln=Pn=Kr=null,U2=!1,l)throw Error(t(300));return s}function Q5(){var s=E1!==0;return E1=0,s}function Ja(){var s={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return Ln===null?Kr.memoizedState=Ln=s:Ln=Ln.next=s,Ln}function jo(){if(Pn===null){var s=Kr.alternate;s=s!==null?s.memoizedState:null}else s=Pn.next;var l=Ln===null?Kr.memoizedState:Ln.next;if(l!==null)Ln=l,Pn=s;else{if(s===null)throw Error(t(310));Pn=s,s={memoizedState:Pn.memoizedState,baseState:Pn.baseState,baseQueue:Pn.baseQueue,queue:Pn.queue,next:null},Ln===null?Kr.memoizedState=Ln=s:Ln=Ln.next=s}return Ln}function S1(s,l){return typeof l=="function"?l(s):l}function X5(s){var l=jo(),f=l.queue;if(f===null)throw Error(t(311));f.lastRenderedReducer=s;var m=Pn,y=m.baseQueue,w=f.pending;if(w!==null){if(y!==null){var E=y.next;y.next=w.next,w.next=E}m.baseQueue=y=w,f.pending=null}if(y!==null){w=y.next,m=m.baseState;var L=E=null,V=null,ne=w;do{var ge=ne.lane;if((dd&ge)===ge)V!==null&&(V=V.next={lane:0,action:ne.action,hasEagerState:ne.hasEagerState,eagerState:ne.eagerState,next:null}),m=ne.hasEagerState?ne.eagerState:s(m,ne.action);else{var _e={lane:ge,action:ne.action,hasEagerState:ne.hasEagerState,eagerState:ne.eagerState,next:null};V===null?(L=V=_e,E=m):V=V.next=_e,Kr.lanes|=ge,ud|=ge}ne=ne.next}while(ne!==null&&ne!==w);V===null?E=m:V.next=L,wa(m,l.memoizedState)||(Yi=!0),l.memoizedState=m,l.baseState=E,l.baseQueue=V,f.lastRenderedState=m}if(s=f.interleaved,s!==null){y=s;do w=y.lane,Kr.lanes|=w,ud|=w,y=y.next;while(y!==s)}else y===null&&(f.lanes=0);return[l.memoizedState,f.dispatch]}function J5(s){var l=jo(),f=l.queue;if(f===null)throw Error(t(311));f.lastRenderedReducer=s;var m=f.dispatch,y=f.pending,w=l.memoizedState;if(y!==null){f.pending=null;var E=y=y.next;do w=s(w,E.action),E=E.next;while(E!==y);wa(w,l.memoizedState)||(Yi=!0),l.memoizedState=w,l.baseQueue===null&&(l.baseState=w),f.lastRenderedState=w}return[w,m]}function n7(){}function i7(s,l){var f=Kr,m=jo(),y=l(),w=!wa(m.memoizedState,y);if(w&&(m.memoizedState=y,Yi=!0),m=m.queue,ey(s7.bind(null,f,m,s),[s]),m.getSnapshot!==l||w||Ln!==null&&Ln.memoizedState.tag&1){if(f.flags|=2048,T1(9,a7.bind(null,f,m,y,l),void 0,null),Hn===null)throw Error(t(349));dd&30||o7(f,l,y)}return y}function o7(s,l,f){s.flags|=16384,s={getSnapshot:l,value:f},l=Kr.updateQueue,l===null?(l={lastEffect:null,stores:null},Kr.updateQueue=l,l.stores=[s]):(f=l.stores,f===null?l.stores=[s]:f.push(s))}function a7(s,l,f,m){l.value=f,l.getSnapshot=m,c7(l)&&l7(s)}function s7(s,l,f){return f(function(){c7(l)&&l7(s)})}function c7(s){var l=s.getSnapshot;s=s.value;try{var f=l();return!wa(s,f)}catch{return!0}}function l7(s){var l=Vs(s,1);l!==null&&Sa(l,s,1,-1)}function d7(s){var l=Ja();return typeof s=="function"&&(s=s()),l.memoizedState=l.baseState=s,s={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:S1,lastRenderedState:s},l.queue=s,s=s.dispatch=AL.bind(null,Kr,s),[l.memoizedState,s]}function T1(s,l,f,m){return s={tag:s,create:l,destroy:f,deps:m,next:null},l=Kr.updateQueue,l===null?(l={lastEffect:null,stores:null},Kr.updateQueue=l,l.lastEffect=s.next=s):(f=l.lastEffect,f===null?l.lastEffect=s.next=s:(m=f.next,f.next=s,s.next=m,l.lastEffect=s)),s}function u7(){return jo().memoizedState}function q2(s,l,f,m){var y=Ja();Kr.flags|=s,y.memoizedState=T1(1|l,f,void 0,m===void 0?null:m)}function W2(s,l,f,m){var y=jo();m=m===void 0?null:m;var w=void 0;if(Pn!==null){var E=Pn.memoizedState;if(w=E.destroy,m!==null&&K5(m,E.deps)){y.memoizedState=T1(l,f,w,m);return}}Kr.flags|=s,y.memoizedState=T1(1|l,f,w,m)}function h7(s,l){return q2(8390656,8,s,l)}function ey(s,l){return W2(2048,8,s,l)}function f7(s,l){return W2(4,2,s,l)}function p7(s,l){return W2(4,4,s,l)}function m7(s,l){if(typeof l=="function")return s=s(),l(s),function(){l(null)};if(l!=null)return s=s(),l.current=s,function(){l.current=null}}function v7(s,l,f){return f=f!=null?f.concat([s]):null,W2(4,4,m7.bind(null,l,s),f)}function ty(){}function g7(s,l){var f=jo();l=l===void 0?null:l;var m=f.memoizedState;return m!==null&&l!==null&&K5(l,m[1])?m[0]:(f.memoizedState=[s,l],s)}function y7(s,l){var f=jo();l=l===void 0?null:l;var m=f.memoizedState;return m!==null&&l!==null&&K5(l,m[1])?m[0]:(s=s(),f.memoizedState=[s,l],s)}function _7(s,l,f){return dd&21?(wa(f,l)||(f=p2(),Kr.lanes|=f,ud|=f,s.baseState=!0),l):(s.baseState&&(s.baseState=!1,Yi=!0),s.memoizedState=f)}function SL(s,l){var f=qt;qt=f!==0&&4>f?f:4,s(!0);var m=G5.transition;G5.transition={};try{s(!1),l()}finally{qt=f,G5.transition=m}}function b7(){return jo().memoizedState}function TL(s,l,f){var m=Uc(s);if(f={lane:m,action:f,hasEagerState:!1,eagerState:null,next:null},w7(s))x7(l,f);else if(f=X9(s,l,f,m),f!==null){var y=Mi();Sa(f,s,m,y),C7(f,l,m)}}function AL(s,l,f){var m=Uc(s),y={lane:m,action:f,hasEagerState:!1,eagerState:null,next:null};if(w7(s))x7(l,y);else{var w=s.alternate;if(s.lanes===0&&(w===null||w.lanes===0)&&(w=l.lastRenderedReducer,w!==null))try{var E=l.lastRenderedState,L=w(E,f);if(y.hasEagerState=!0,y.eagerState=L,wa(L,E)){var V=l.interleaved;V===null?(y.next=y,j5(l)):(y.next=V.next,V.next=y),l.interleaved=y;return}}catch{}finally{}f=X9(s,l,y,m),f!==null&&(y=Mi(),Sa(f,s,m,y),C7(f,l,m))}}function w7(s){var l=s.alternate;return s===Kr||l!==null&&l===Kr}function x7(s,l){k1=U2=!0;var f=s.pending;f===null?l.next=l:(l.next=f.next,f.next=l),s.pending=l}function C7(s,l,f){if(f&4194240){var m=l.lanes;m&=s.pendingLanes,f|=m,l.lanes=f,Mc(s,f)}}var G2={readContext:Fo,useCallback:ui,useContext:ui,useEffect:ui,useImperativeHandle:ui,useInsertionEffect:ui,useLayoutEffect:ui,useMemo:ui,useReducer:ui,useRef:ui,useState:ui,useDebugValue:ui,useDeferredValue:ui,useTransition:ui,useMutableSource:ui,useSyncExternalStore:ui,useId:ui,unstable_isNewReconciler:!1},IL={readContext:Fo,useCallback:function(s,l){return Ja().memoizedState=[s,l===void 0?null:l],s},useContext:Fo,useEffect:h7,useImperativeHandle:function(s,l,f){return f=f!=null?f.concat([s]):null,q2(4194308,4,m7.bind(null,l,s),f)},useLayoutEffect:function(s,l){return q2(4194308,4,s,l)},useInsertionEffect:function(s,l){return q2(4,2,s,l)},useMemo:function(s,l){var f=Ja();return l=l===void 0?null:l,s=s(),f.memoizedState=[s,l],s},useReducer:function(s,l,f){var m=Ja();return l=f!==void 0?f(l):l,m.memoizedState=m.baseState=l,s={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:s,lastRenderedState:l},m.queue=s,s=s.dispatch=TL.bind(null,Kr,s),[m.memoizedState,s]},useRef:function(s){var l=Ja();return s={current:s},l.memoizedState=s},useState:d7,useDebugValue:ty,useDeferredValue:function(s){return Ja().memoizedState=s},useTransition:function(){var s=d7(!1),l=s[0];return s=SL.bind(null,s[1]),Ja().memoizedState=s,[l,s]},useMutableSource:function(){},useSyncExternalStore:function(s,l,f){var m=Kr,y=Ja();if(Vr){if(f===void 0)throw Error(t(407));f=f()}else{if(f=l(),Hn===null)throw Error(t(349));dd&30||o7(m,l,f)}y.memoizedState=f;var w={value:f,getSnapshot:l};return y.queue=w,h7(s7.bind(null,m,w,s),[s]),m.flags|=2048,T1(9,a7.bind(null,m,w,f,l),void 0,null),f},useId:function(){var s=Ja(),l=Hn.identifierPrefix;if(Vr){var f=Ds,m=Ns;f=(m&~(1<<32-Yt(m)-1)).toString(32)+f,l=":"+l+"R"+f,f=E1++,0<f&&(l+="H"+f.toString(32)),l+=":"}else f=EL++,l=":"+l+"r"+f.toString(32)+":";return s.memoizedState=l},unstable_isNewReconciler:!1},RL={readContext:Fo,useCallback:g7,useContext:Fo,useEffect:ey,useImperativeHandle:v7,useInsertionEffect:f7,useLayoutEffect:p7,useMemo:y7,useReducer:X5,useRef:u7,useState:function(){return X5(S1)},useDebugValue:ty,useDeferredValue:function(s){var l=jo();return _7(l,Pn.memoizedState,s)},useTransition:function(){var s=X5(S1)[0],l=jo().memoizedState;return[s,l]},useMutableSource:n7,useSyncExternalStore:i7,useId:b7,unstable_isNewReconciler:!1},PL={readContext:Fo,useCallback:g7,useContext:Fo,useEffect:ey,useImperativeHandle:v7,useInsertionEffect:f7,useLayoutEffect:p7,useMemo:y7,useReducer:J5,useRef:u7,useState:function(){return J5(S1)},useDebugValue:ty,useDeferredValue:function(s){var l=jo();return Pn===null?l.memoizedState=s:_7(l,Pn.memoizedState,s)},useTransition:function(){var s=J5(S1)[0],l=jo().memoizedState;return[s,l]},useMutableSource:n7,useSyncExternalStore:i7,useId:b7,unstable_isNewReconciler:!1};function Ca(s,l){if(s&&s.defaultProps){l=H({},l),s=s.defaultProps;for(var f in s)l[f]===void 0&&(l[f]=s[f]);return l}return l}function ry(s,l,f,m){l=s.memoizedState,f=f(m,l),f=f==null?l:H({},l,f),s.memoizedState=f,s.lanes===0&&(s.updateQueue.baseState=f)}var K2={isMounted:function(s){return(s=s._reactInternals)?Je(s)===s:!1},enqueueSetState:function(s,l,f){s=s._reactInternals;var m=Mi(),y=Uc(s),w=Fs(m,y);w.payload=l,f!=null&&(w.callback=f),l=Fc(s,w,y),l!==null&&(Sa(l,s,y,m),F2(l,s,y))},enqueueReplaceState:function(s,l,f){s=s._reactInternals;var m=Mi(),y=Uc(s),w=Fs(m,y);w.tag=1,w.payload=l,f!=null&&(w.callback=f),l=Fc(s,w,y),l!==null&&(Sa(l,s,y,m),F2(l,s,y))},enqueueForceUpdate:function(s,l){s=s._reactInternals;var f=Mi(),m=Uc(s),y=Fs(f,m);y.tag=2,l!=null&&(y.callback=l),l=Fc(s,y,m),l!==null&&(Sa(l,s,m,f),F2(l,s,m))}};function k7(s,l,f,m,y,w,E){return s=s.stateNode,typeof s.shouldComponentUpdate=="function"?s.shouldComponentUpdate(m,w,E):l.prototype&&l.prototype.isPureReactComponent?!f1(f,m)||!f1(y,w):!0}function E7(s,l,f){var m=!1,y=Nc,w=l.contextType;return typeof w=="object"&&w!==null?w=Fo(w):(y=Ki(l)?od:di.current,m=l.contextTypes,w=(m=m!=null)?ch(s,y):Nc),l=new l(f,w),s.memoizedState=l.state!==null&&l.state!==void 0?l.state:null,l.updater=K2,s.stateNode=l,l._reactInternals=s,m&&(s=s.stateNode,s.__reactInternalMemoizedUnmaskedChildContext=y,s.__reactInternalMemoizedMaskedChildContext=w),l}function S7(s,l,f,m){s=l.state,typeof l.componentWillReceiveProps=="function"&&l.componentWillReceiveProps(f,m),typeof l.UNSAFE_componentWillReceiveProps=="function"&&l.UNSAFE_componentWillReceiveProps(f,m),l.state!==s&&K2.enqueueReplaceState(l,l.state,null)}function ny(s,l,f,m){var y=s.stateNode;y.props=f,y.state=s.memoizedState,y.refs={},z5(s);var w=l.contextType;typeof w=="object"&&w!==null?y.context=Fo(w):(w=Ki(l)?od:di.current,y.context=ch(s,w)),y.state=s.memoizedState,w=l.getDerivedStateFromProps,typeof w=="function"&&(ry(s,l,w,f),y.state=s.memoizedState),typeof l.getDerivedStateFromProps=="function"||typeof y.getSnapshotBeforeUpdate=="function"||typeof y.UNSAFE_componentWillMount!="function"&&typeof y.componentWillMount!="function"||(l=y.state,typeof y.componentWillMount=="function"&&y.componentWillMount(),typeof y.UNSAFE_componentWillMount=="function"&&y.UNSAFE_componentWillMount(),l!==y.state&&K2.enqueueReplaceState(y,y.state,null),j2(s,f,y,m),y.state=s.memoizedState),typeof y.componentDidMount=="function"&&(s.flags|=4194308)}function vh(s,l){try{var f="",m=l;do f+=Ie(m),m=m.return;while(m);var y=f}catch(w){y=`
37
+ `+y[E].replace(" at new "," at ");return s.displayName&&V.includes("<anonymous>")&&(V=V.replace("<anonymous>",s.displayName)),V}while(1<=E&&0<=L);break}}}finally{ye=!1,Error.prepareStackTrace=f}return(s=s?s.displayName||s.name:"")?N(s):""}function Ie(s){switch(s.tag){case 5:return N(s.type);case 16:return N("Lazy");case 13:return N("Suspense");case 19:return N("SuspenseList");case 0:case 2:case 15:return s=Pe(s.type,!1),s;case 11:return s=Pe(s.type.render,!1),s;case 1:return s=Pe(s.type,!0),s;default:return""}}function Te(s){if(s==null)return null;if(typeof s=="function")return s.displayName||s.name||null;if(typeof s=="string")return s;switch(s){case I:return"Fragment";case U:return"Portal";case le:return"Profiler";case Y:return"StrictMode";case Ce:return"Suspense";case J:return"SuspenseList"}if(typeof s=="object")switch(s.$$typeof){case Ee:return(s.displayName||"Context")+".Consumer";case de:return(s._context.displayName||"Context")+".Provider";case we:var l=s.render;return s=s.displayName,s||(s=l.displayName||l.name||"",s=s!==""?"ForwardRef("+s+")":"ForwardRef"),s;case K:return l=s.displayName||null,l!==null?l:Te(s.type)||"Memo";case re:l=s._payload,s=s._init;try{return Te(s(l))}catch{}}return null}function Ke(s){var l=s.type;switch(s.tag){case 24:return"Cache";case 9:return(l.displayName||"Context")+".Consumer";case 10:return(l._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return s=l.render,s=s.displayName||s.name||"",l.displayName||(s!==""?"ForwardRef("+s+")":"ForwardRef");case 7:return"Fragment";case 5:return l;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return Te(l);case 8:return l===Y?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof l=="function")return l.displayName||l.name||null;if(typeof l=="string")return l}return null}function ot(s){switch(typeof s){case"boolean":case"number":case"string":case"undefined":return s;case"object":return s;default:return""}}function _t(s){var l=s.type;return(s=s.nodeName)&&s.toLowerCase()==="input"&&(l==="checkbox"||l==="radio")}function yr(s){var l=_t(s)?"checked":"value",f=Object.getOwnPropertyDescriptor(s.constructor.prototype,l),m=""+s[l];if(!s.hasOwnProperty(l)&&typeof f<"u"&&typeof f.get=="function"&&typeof f.set=="function"){var y=f.get,w=f.set;return Object.defineProperty(s,l,{configurable:!0,get:function(){return y.call(this)},set:function(E){m=""+E,w.call(this,E)}}),Object.defineProperty(s,l,{enumerable:f.enumerable}),{getValue:function(){return m},setValue:function(E){m=""+E},stopTracking:function(){s._valueTracker=null,delete s[l]}}}}function Wr(s){s._valueTracker||(s._valueTracker=yr(s))}function Rt(s){if(!s)return!1;var l=s._valueTracker;if(!l)return!0;var f=l.getValue(),m="";return s&&(m=_t(s)?s.checked?"true":"false":s.value),s=m,s!==f?(l.setValue(s),!0):!1}function Un(s){if(s=s||(typeof document<"u"?document:void 0),typeof s>"u")return null;try{return s.activeElement||s.body}catch{return s.body}}function co(s,l){var f=l.checked;return H({},l,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:f??s._wrapperState.initialChecked})}function ma(s,l){var f=l.defaultValue==null?"":l.defaultValue,m=l.checked!=null?l.checked:l.defaultChecked;f=ot(l.value!=null?l.value:f),s._wrapperState={initialChecked:m,initialValue:f,controlled:l.type==="checkbox"||l.type==="radio"?l.checked!=null:l.value!=null}}function qi(s,l){l=l.checked,l!=null&&A(s,"checked",l,!1)}function Sc(s,l){qi(s,l);var f=ot(l.value),m=l.type;if(f!=null)m==="number"?(f===0&&s.value===""||s.value!=f)&&(s.value=""+f):s.value!==""+f&&(s.value=""+f);else if(m==="submit"||m==="reset"){s.removeAttribute("value");return}l.hasOwnProperty("value")?Tc(s,l.type,f):l.hasOwnProperty("defaultValue")&&Tc(s,l.type,ot(l.defaultValue)),l.checked==null&&l.defaultChecked!=null&&(s.defaultChecked=!!l.defaultChecked)}function Uu(s,l,f){if(l.hasOwnProperty("value")||l.hasOwnProperty("defaultValue")){var m=l.type;if(!(m!=="submit"&&m!=="reset"||l.value!==void 0&&l.value!==null))return;l=""+s._wrapperState.initialValue,f||l===s.value||(s.value=l),s.defaultValue=l}f=s.name,f!==""&&(s.name=""),s.defaultChecked=!!s._wrapperState.initialChecked,f!==""&&(s.name=f)}function Tc(s,l,f){(l!=="number"||Un(s.ownerDocument)!==s)&&(f==null?s.defaultValue=""+s._wrapperState.initialValue:s.defaultValue!==""+f&&(s.defaultValue=""+f))}var Po=Array.isArray;function Mo(s,l,f,m){if(s=s.options,l){l={};for(var y=0;y<f.length;y++)l["$"+f[y]]=!0;for(f=0;f<s.length;f++)y=l.hasOwnProperty("$"+s[f].value),s[f].selected!==y&&(s[f].selected=y),y&&m&&(s[f].defaultSelected=!0)}else{for(f=""+ot(f),l=null,y=0;y<s.length;y++){if(s[y].value===f){s[y].selected=!0,m&&(s[y].defaultSelected=!0);return}l!==null||s[y].disabled||(l=s[y])}l!==null&&(l.selected=!0)}}function Ac(s,l){if(l.dangerouslySetInnerHTML!=null)throw Error(t(91));return H({},l,{value:void 0,defaultValue:void 0,children:""+s._wrapperState.initialValue})}function zl(s,l){var f=l.value;if(f==null){if(f=l.children,l=l.defaultValue,f!=null){if(l!=null)throw Error(t(92));if(Po(f)){if(1<f.length)throw Error(t(93));f=f[0]}l=f}l==null&&(l=""),f=l}s._wrapperState={initialValue:ot(f)}}function An(s,l){var f=ot(l.value),m=ot(l.defaultValue);f!=null&&(f=""+f,f!==s.value&&(s.value=f),l.defaultValue==null&&s.defaultValue!==f&&(s.defaultValue=f)),m!=null&&(s.defaultValue=""+m)}function lo(s){var l=s.textContent;l===s._wrapperState.initialValue&&l!==""&&l!==null&&(s.value=l)}function Bl(s){switch(s){case"svg":return"http://www.w3.org/2000/svg";case"math":return"http://www.w3.org/1998/Math/MathML";default:return"http://www.w3.org/1999/xhtml"}}function Ba(s,l){return s==null||s==="http://www.w3.org/1999/xhtml"?Bl(l):s==="http://www.w3.org/2000/svg"&&l==="foreignObject"?"http://www.w3.org/1999/xhtml":s}var ai,Ii=function(s){return typeof MSApp<"u"&&MSApp.execUnsafeLocalFunction?function(l,f,m,y){MSApp.execUnsafeLocalFunction(function(){return s(l,f,m,y)})}:s}(function(s,l){if(s.namespaceURI!=="http://www.w3.org/2000/svg"||"innerHTML"in s)s.innerHTML=l;else{for(ai=ai||document.createElement("div"),ai.innerHTML="<svg>"+l.valueOf().toString()+"</svg>",l=ai.firstChild;s.firstChild;)s.removeChild(s.firstChild);for(;l.firstChild;)s.appendChild(l.firstChild)}});function Ua(s,l){if(l){var f=s.firstChild;if(f&&f===s.lastChild&&f.nodeType===3){f.nodeValue=l;return}}s.textContent=l}var $o={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},e1=["Webkit","ms","Moz","O"];Object.keys($o).forEach(function(s){e1.forEach(function(l){l=l+s.charAt(0).toUpperCase()+s.substring(1),$o[l]=$o[s]})});function uo(s,l,f){return l==null||typeof l=="boolean"||l===""?"":f||typeof l!="number"||l===0||$o.hasOwnProperty(s)&&$o[s]?(""+l).trim():l+"px"}function Ic(s,l){s=s.style;for(var f in l)if(l.hasOwnProperty(f)){var m=f.indexOf("--")===0,y=uo(f,l[f],m);f==="float"&&(f="cssFloat"),m?s.setProperty(f,y):s[f]=y}}var qu=H({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function Rc(s,l){if(l){if(qu[s]&&(l.children!=null||l.dangerouslySetInnerHTML!=null))throw Error(t(137,s));if(l.dangerouslySetInnerHTML!=null){if(l.children!=null)throw Error(t(60));if(typeof l.dangerouslySetInnerHTML!="object"||!("__html"in l.dangerouslySetInnerHTML))throw Error(t(61))}if(l.style!=null&&typeof l.style!="object")throw Error(t(62))}}function Ps(s,l){if(s.indexOf("-")===-1)return typeof l.is=="string";switch(s){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var Oo=null;function Zo(s){return s=s.target||s.srcElement||window,s.correspondingUseElement&&(s=s.correspondingUseElement),s.nodeType===3?s.parentNode:s}var qa=null,Wi=null,si=null;function Wu(s){if(s=_1(s)){if(typeof qa!="function")throw Error(t(280));var l=s.stateNode;l&&(l=P2(l),qa(s.stateNode,s.type,l))}}function Ul(s){Wi?si?si.push(s):si=[s]:Wi=s}function Gu(){if(Wi){var s=Wi,l=si;if(si=Wi=null,Wu(s),l)for(s=0;s<l.length;s++)Wu(l[s])}}function ql(s,l){return s(l)}function Ms(){}var va=!1;function Wl(s,l,f){if(va)return s(l,f);va=!0;try{return ql(s,l,f)}finally{va=!1,(Wi!==null||si!==null)&&(Ms(),Gu())}}function Ri(s,l){var f=s.stateNode;if(f===null)return null;var m=P2(f);if(m===null)return null;f=m[l];e:switch(l){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(m=!m.disabled)||(s=s.type,m=!(s==="button"||s==="input"||s==="select"||s==="textarea")),s=!m;break e;default:s=!1}if(s)return null;if(f&&typeof f!="function")throw Error(t(231,l,typeof f));return f}var D=!1;if(c)try{var Q={};Object.defineProperty(Q,"passive",{get:function(){D=!0}}),window.addEventListener("test",Q,Q),window.removeEventListener("test",Q,Q)}catch{D=!1}function ie(s,l,f,m,y,w,E,L,V){var ne=Array.prototype.slice.call(arguments,3);try{l.apply(f,ne)}catch(ge){this.onError(ge)}}var he=!1,Oe=null,Ve=!1,mt=null,Ge={onError:function(s){he=!0,Oe=s}};function Ye(s,l,f,m,y,w,E,L,V){he=!1,Oe=null,ie.apply(Ge,arguments)}function je(s,l,f,m,y,w,E,L,V){if(Ye.apply(this,arguments),he){if(he){var ne=Oe;he=!1,Oe=null}else throw Error(t(198));Ve||(Ve=!0,mt=ne)}}function Je(s){var l=s,f=s;if(s.alternate)for(;l.return;)l=l.return;else{s=l;do l=s,(l.flags&4098)!==0&&(f=l.return),s=l.return;while(s)}return l.tag===3?f:null}function wt(s){if(s.tag===13){var l=s.memoizedState;if(l===null&&(s=s.alternate,s!==null&&(l=s.memoizedState)),l!==null)return l.dehydrated}return null}function Ht(s){if(Je(s)!==s)throw Error(t(188))}function mn(s){var l=s.alternate;if(!l){if(l=Je(s),l===null)throw Error(t(188));return l!==s?null:s}for(var f=s,m=l;;){var y=f.return;if(y===null)break;var w=y.alternate;if(w===null){if(m=y.return,m!==null){f=m;continue}break}if(y.child===w.child){for(w=y.child;w;){if(w===f)return Ht(y),s;if(w===m)return Ht(y),l;w=w.sibling}throw Error(t(188))}if(f.return!==m.return)f=y,m=w;else{for(var E=!1,L=y.child;L;){if(L===f){E=!0,f=y,m=w;break}if(L===m){E=!0,m=y,f=w;break}L=L.sibling}if(!E){for(L=w.child;L;){if(L===f){E=!0,f=w,m=y;break}if(L===m){E=!0,m=w,f=y;break}L=L.sibling}if(!E)throw Error(t(189))}}if(f.alternate!==m)throw Error(t(190))}if(f.tag!==3)throw Error(t(188));return f.stateNode.current===f?s:l}function ar(s){return s=mn(s),s!==null?Ut(s):null}function Ut(s){if(s.tag===5||s.tag===6)return s;for(s=s.child;s!==null;){var l=Ut(s);if(l!==null)return l;s=s.sibling}return null}var Er=e.unstable_scheduleCallback,ci=e.unstable_cancelCallback,$s=e.unstable_shouldYield,ho=e.unstable_requestPaint,Kt=e.unstable_now,Gl=e.unstable_getCurrentPriorityLevel,ga=e.unstable_ImmediatePriority,Lo=e.unstable_UserBlockingPriority,Ho=e.unstable_NormalPriority,ya=e.unstable_LowPriority,jt=e.unstable_IdlePriority,sr=null,In=null;function Os(s){if(In&&typeof In.onCommitFiberRoot=="function")try{In.onCommitFiberRoot(sr,s,void 0,(s.current.flags&128)===128)}catch{}}var Yt=Math.clz32?Math.clz32:t1,Wa=Math.log,Ku=Math.LN2;function t1(s){return s>>>=0,s===0?32:31-(Wa(s)/Ku|0)|0}var Pc=64,Yu=4194304;function Kl(s){switch(s&-s){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return s&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return s&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return s}}function Qu(s,l){var f=s.pendingLanes;if(f===0)return 0;var m=0,y=s.suspendedLanes,w=s.pingedLanes,E=f&268435455;if(E!==0){var L=E&~y;L!==0?m=Kl(L):(w&=E,w!==0&&(m=Kl(w)))}else E=f&~y,E!==0?m=Kl(E):w!==0&&(m=Kl(w));if(m===0)return 0;if(l!==0&&l!==m&&(l&y)===0&&(y=m&-m,w=l&-l,y>=w||y===16&&(w&4194240)!==0))return l;if((m&4)!==0&&(m|=f&16),l=s.entangledLanes,l!==0)for(s=s.entanglements,l&=m;0<l;)f=31-Yt(l),y=1<<f,m|=s[f],l&=~y;return m}function a5(s,l){switch(s){case 1:case 2:case 4:return l+250;case 8:case 16:case 32:case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return l+5e3;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return-1;case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function s5(s,l){for(var f=s.suspendedLanes,m=s.pingedLanes,y=s.expirationTimes,w=s.pendingLanes;0<w;){var E=31-Yt(w),L=1<<E,V=y[E];V===-1?((L&f)===0||(L&m)!==0)&&(y[E]=a5(L,l)):V<=l&&(s.expiredLanes|=L),w&=~L}}function r1(s){return s=s.pendingLanes&-1073741825,s!==0?s:s&1073741824?1073741824:0}function p2(){var s=Pc;return Pc<<=1,(Pc&4194240)===0&&(Pc=64),s}function Xu(s){for(var l=[],f=0;31>f;f++)l.push(s);return l}function Yl(s,l,f){s.pendingLanes|=l,l!==536870912&&(s.suspendedLanes=0,s.pingedLanes=0),s=s.eventTimes,l=31-Yt(l),s[l]=f}function c5(s,l){var f=s.pendingLanes&~l;s.pendingLanes=l,s.suspendedLanes=0,s.pingedLanes=0,s.expiredLanes&=l,s.mutableReadLanes&=l,s.entangledLanes&=l,l=s.entanglements;var m=s.eventTimes;for(s=s.expirationTimes;0<f;){var y=31-Yt(f),w=1<<y;l[y]=0,m[y]=-1,s[y]=-1,f&=~w}}function Mc(s,l){var f=s.entangledLanes|=l;for(s=s.entanglements;f;){var m=31-Yt(f),y=1<<m;y&l|s[m]&l&&(s[m]|=l),f&=~y}}var qt=0;function n1(s){return s&=-s,1<s?4<s?(s&268435455)!==0?16:536870912:4:1}var Ga,i1,m2,v2,g2,o1=!1,Ju=[],_a=null,li=null,Ka=null,$c=new Map,Ql=new Map,No=[],y2="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset submit".split(" ");function _2(s,l){switch(s){case"focusin":case"focusout":_a=null;break;case"dragenter":case"dragleave":li=null;break;case"mouseover":case"mouseout":Ka=null;break;case"pointerover":case"pointerout":$c.delete(l.pointerId);break;case"gotpointercapture":case"lostpointercapture":Ql.delete(l.pointerId)}}function Xl(s,l,f,m,y,w){return s===null||s.nativeEvent!==w?(s={blockedOn:l,domEventName:f,eventSystemFlags:m,nativeEvent:w,targetContainers:[y]},l!==null&&(l=_1(l),l!==null&&i1(l)),s):(s.eventSystemFlags|=m,l=s.targetContainers,y!==null&&l.indexOf(y)===-1&&l.push(y),s)}function b2(s,l,f,m,y){switch(l){case"focusin":return _a=Xl(_a,s,l,f,m,y),!0;case"dragenter":return li=Xl(li,s,l,f,m,y),!0;case"mouseover":return Ka=Xl(Ka,s,l,f,m,y),!0;case"pointerover":var w=y.pointerId;return $c.set(w,Xl($c.get(w)||null,s,l,f,m,y)),!0;case"gotpointercapture":return w=y.pointerId,Ql.set(w,Xl(Ql.get(w)||null,s,l,f,m,y)),!0}return!1}function w2(s){var l=id(s.target);if(l!==null){var f=Je(l);if(f!==null){if(l=f.tag,l===13){if(l=wt(f),l!==null){s.blockedOn=l,g2(s.priority,function(){m2(f)});return}}else if(l===3&&f.stateNode.current.memoizedState.isDehydrated){s.blockedOn=f.tag===3?f.stateNode.containerInfo:null;return}}}s.blockedOn=null}function Zs(s){if(s.blockedOn!==null)return!1;for(var l=s.targetContainers;0<l.length;){var f=fo(s.domEventName,s.eventSystemFlags,l[0],s.nativeEvent);if(f===null){f=s.nativeEvent;var m=new f.constructor(f.type,f);Oo=m,f.target.dispatchEvent(m),Oo=null}else return l=_1(f),l!==null&&i1(l),s.blockedOn=f,!1;l.shift()}return!0}function x2(s,l,f){Zs(s)&&f.delete(l)}function a1(){o1=!1,_a!==null&&Zs(_a)&&(_a=null),li!==null&&Zs(li)&&(li=null),Ka!==null&&Zs(Ka)&&(Ka=null),$c.forEach(x2),Ql.forEach(x2)}function Jl(s,l){s.blockedOn===l&&(s.blockedOn=null,o1||(o1=!0,e.unstable_scheduleCallback(e.unstable_NormalPriority,a1)))}function ed(s){function l(y){return Jl(y,s)}if(0<Ju.length){Jl(Ju[0],s);for(var f=1;f<Ju.length;f++){var m=Ju[f];m.blockedOn===s&&(m.blockedOn=null)}}for(_a!==null&&Jl(_a,s),li!==null&&Jl(li,s),Ka!==null&&Jl(Ka,s),$c.forEach(l),Ql.forEach(l),f=0;f<No.length;f++)m=No[f],m.blockedOn===s&&(m.blockedOn=null);for(;0<No.length&&(f=No[0],f.blockedOn===null);)w2(f),f.blockedOn===null&&No.shift()}var M=Z.ReactCurrentBatchConfig,te=!0;function ue(s,l,f,m){var y=qt,w=M.transition;M.transition=null;try{qt=1,vn(s,l,f,m)}finally{qt=y,M.transition=w}}function at(s,l,f,m){var y=qt,w=M.transition;M.transition=null;try{qt=4,vn(s,l,f,m)}finally{qt=y,M.transition=w}}function vn(s,l,f,m){if(te){var y=fo(s,l,f,m);if(y===null)k5(s,l,m,Rn,f),_2(s,m);else if(b2(y,s,l,f,m))m.stopPropagation();else if(_2(s,m),l&4&&-1<y2.indexOf(s)){for(;y!==null;){var w=_1(y);if(w!==null&&Ga(w),w=fo(s,l,f,m),w===null&&k5(s,l,m,Rn,f),w===y)break;y=w}y!==null&&m.stopPropagation()}else k5(s,l,m,null,f)}}var Rn=null;function fo(s,l,f,m){if(Rn=null,s=Zo(m),s=id(s),s!==null)if(l=Je(s),l===null)s=null;else if(f=l.tag,f===13){if(s=wt(l),s!==null)return s;s=null}else if(f===3){if(l.stateNode.current.memoizedState.isDehydrated)return l.tag===3?l.stateNode.containerInfo:null;s=null}else l!==s&&(s=null);return Rn=s,null}function qn(s){switch(s){case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"resize":case"seeked":case"submit":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 1;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"toggle":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 4;case"message":switch(Gl()){case ga:return 1;case Lo:return 4;case Ho:case ya:return 16;case jt:return 536870912;default:return 16}default:return 16}}var ba=null,Ya=null,td=null;function s1(){if(td)return td;var s,l=Ya,f=l.length,m,y="value"in ba?ba.value:ba.textContent,w=y.length;for(s=0;s<f&&l[s]===y[s];s++);var E=f-s;for(m=1;m<=E&&l[f-m]===y[w-m];m++);return td=y.slice(s,1<m?1-m:void 0)}function rd(s){var l=s.keyCode;return"charCode"in s?(s=s.charCode,s===0&&l===13&&(s=13)):s=l,s===10&&(s=13),32<=s||s===13?s:0}function Oc(){return!0}function nd(){return!1}function po(s){function l(f,m,y,w,E){this._reactName=f,this._targetInst=y,this.type=m,this.nativeEvent=w,this.target=E,this.currentTarget=null;for(var L in s)s.hasOwnProperty(L)&&(f=s[L],this[L]=f?f(w):w[L]);return this.isDefaultPrevented=(w.defaultPrevented!=null?w.defaultPrevented:w.returnValue===!1)?Oc:nd,this.isPropagationStopped=nd,this}return H(l.prototype,{preventDefault:function(){this.defaultPrevented=!0;var f=this.nativeEvent;f&&(f.preventDefault?f.preventDefault():typeof f.returnValue!="unknown"&&(f.returnValue=!1),this.isDefaultPrevented=Oc)},stopPropagation:function(){var f=this.nativeEvent;f&&(f.stopPropagation?f.stopPropagation():typeof f.cancelBubble!="unknown"&&(f.cancelBubble=!0),this.isPropagationStopped=Oc)},persist:function(){},isPersistent:Oc}),l}var eh={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(s){return s.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},l5=po(eh),c1=H({},eh,{view:0,detail:0}),PZ=po(c1),d5,u5,l1,C2=H({},c1,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:f5,button:0,buttons:0,relatedTarget:function(s){return s.relatedTarget===void 0?s.fromElement===s.srcElement?s.toElement:s.fromElement:s.relatedTarget},movementX:function(s){return"movementX"in s?s.movementX:(s!==l1&&(l1&&s.type==="mousemove"?(d5=s.screenX-l1.screenX,u5=s.screenY-l1.screenY):u5=d5=0,l1=s),d5)},movementY:function(s){return"movementY"in s?s.movementY:u5}}),s9=po(C2),MZ=H({},C2,{dataTransfer:0}),$Z=po(MZ),OZ=H({},c1,{relatedTarget:0}),h5=po(OZ),ZZ=H({},eh,{animationName:0,elapsedTime:0,pseudoElement:0}),LZ=po(ZZ),HZ=H({},eh,{clipboardData:function(s){return"clipboardData"in s?s.clipboardData:window.clipboardData}}),NZ=po(HZ),DZ=H({},eh,{data:0}),c9=po(DZ),VZ={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},FZ={8:"Backspace",9:"Tab",12:"Clear",13:"Enter",16:"Shift",17:"Control",18:"Alt",19:"Pause",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",45:"Insert",46:"Delete",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"NumLock",145:"ScrollLock",224:"Meta"},jZ={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function zZ(s){var l=this.nativeEvent;return l.getModifierState?l.getModifierState(s):(s=jZ[s])?!!l[s]:!1}function f5(){return zZ}var BZ=H({},c1,{key:function(s){if(s.key){var l=VZ[s.key]||s.key;if(l!=="Unidentified")return l}return s.type==="keypress"?(s=rd(s),s===13?"Enter":String.fromCharCode(s)):s.type==="keydown"||s.type==="keyup"?FZ[s.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:f5,charCode:function(s){return s.type==="keypress"?rd(s):0},keyCode:function(s){return s.type==="keydown"||s.type==="keyup"?s.keyCode:0},which:function(s){return s.type==="keypress"?rd(s):s.type==="keydown"||s.type==="keyup"?s.keyCode:0}}),UZ=po(BZ),qZ=H({},C2,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),l9=po(qZ),WZ=H({},c1,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:f5}),GZ=po(WZ),KZ=H({},eh,{propertyName:0,elapsedTime:0,pseudoElement:0}),YZ=po(KZ),QZ=H({},C2,{deltaX:function(s){return"deltaX"in s?s.deltaX:"wheelDeltaX"in s?-s.wheelDeltaX:0},deltaY:function(s){return"deltaY"in s?s.deltaY:"wheelDeltaY"in s?-s.wheelDeltaY:"wheelDelta"in s?-s.wheelDelta:0},deltaZ:0,deltaMode:0}),XZ=po(QZ),JZ=[9,13,27,32],p5=c&&"CompositionEvent"in window,d1=null;c&&"documentMode"in document&&(d1=document.documentMode);var eL=c&&"TextEvent"in window&&!d1,d9=c&&(!p5||d1&&8<d1&&11>=d1),u9=" ",h9=!1;function f9(s,l){switch(s){case"keyup":return JZ.indexOf(l.keyCode)!==-1;case"keydown":return l.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function p9(s){return s=s.detail,typeof s=="object"&&"data"in s?s.data:null}var th=!1;function tL(s,l){switch(s){case"compositionend":return p9(l);case"keypress":return l.which!==32?null:(h9=!0,u9);case"textInput":return s=l.data,s===u9&&h9?null:s;default:return null}}function rL(s,l){if(th)return s==="compositionend"||!p5&&f9(s,l)?(s=s1(),td=Ya=ba=null,th=!1,s):null;switch(s){case"paste":return null;case"keypress":if(!(l.ctrlKey||l.altKey||l.metaKey)||l.ctrlKey&&l.altKey){if(l.char&&1<l.char.length)return l.char;if(l.which)return String.fromCharCode(l.which)}return null;case"compositionend":return d9&&l.locale!=="ko"?null:l.data;default:return null}}var nL={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};function m9(s){var l=s&&s.nodeName&&s.nodeName.toLowerCase();return l==="input"?!!nL[s.type]:l==="textarea"}function v9(s,l,f,m){Ul(m),l=A2(l,"onChange"),0<l.length&&(f=new l5("onChange","change",null,f,m),s.push({event:f,listeners:l}))}var u1=null,h1=null;function iL(s){O9(s,0)}function k2(s){var l=ah(s);if(Rt(l))return s}function oL(s,l){if(s==="change")return l}var g9=!1;if(c){var m5;if(c){var v5="oninput"in document;if(!v5){var y9=document.createElement("div");y9.setAttribute("oninput","return;"),v5=typeof y9.oninput=="function"}m5=v5}else m5=!1;g9=m5&&(!document.documentMode||9<document.documentMode)}function _9(){u1&&(u1.detachEvent("onpropertychange",b9),h1=u1=null)}function b9(s){if(s.propertyName==="value"&&k2(h1)){var l=[];v9(l,h1,s,Zo(s)),Wl(iL,l)}}function aL(s,l,f){s==="focusin"?(_9(),u1=l,h1=f,u1.attachEvent("onpropertychange",b9)):s==="focusout"&&_9()}function sL(s){if(s==="selectionchange"||s==="keyup"||s==="keydown")return k2(h1)}function cL(s,l){if(s==="click")return k2(l)}function lL(s,l){if(s==="input"||s==="change")return k2(l)}function dL(s,l){return s===l&&(s!==0||1/s===1/l)||s!==s&&l!==l}var wa=typeof Object.is=="function"?Object.is:dL;function f1(s,l){if(wa(s,l))return!0;if(typeof s!="object"||s===null||typeof l!="object"||l===null)return!1;var f=Object.keys(s),m=Object.keys(l);if(f.length!==m.length)return!1;for(m=0;m<f.length;m++){var y=f[m];if(!d.call(l,y)||!wa(s[y],l[y]))return!1}return!0}function w9(s){for(;s&&s.firstChild;)s=s.firstChild;return s}function x9(s,l){var f=w9(s);s=0;for(var m;f;){if(f.nodeType===3){if(m=s+f.textContent.length,s<=l&&m>=l)return{node:f,offset:l-s};s=m}e:{for(;f;){if(f.nextSibling){f=f.nextSibling;break e}f=f.parentNode}f=void 0}f=w9(f)}}function C9(s,l){return s&&l?s===l?!0:s&&s.nodeType===3?!1:l&&l.nodeType===3?C9(s,l.parentNode):"contains"in s?s.contains(l):s.compareDocumentPosition?!!(s.compareDocumentPosition(l)&16):!1:!1}function k9(){for(var s=window,l=Un();l instanceof s.HTMLIFrameElement;){try{var f=typeof l.contentWindow.location.href=="string"}catch{f=!1}if(f)s=l.contentWindow;else break;l=Un(s.document)}return l}function g5(s){var l=s&&s.nodeName&&s.nodeName.toLowerCase();return l&&(l==="input"&&(s.type==="text"||s.type==="search"||s.type==="tel"||s.type==="url"||s.type==="password")||l==="textarea"||s.contentEditable==="true")}function uL(s){var l=k9(),f=s.focusedElem,m=s.selectionRange;if(l!==f&&f&&f.ownerDocument&&C9(f.ownerDocument.documentElement,f)){if(m!==null&&g5(f)){if(l=m.start,s=m.end,s===void 0&&(s=l),"selectionStart"in f)f.selectionStart=l,f.selectionEnd=Math.min(s,f.value.length);else if(s=(l=f.ownerDocument||document)&&l.defaultView||window,s.getSelection){s=s.getSelection();var y=f.textContent.length,w=Math.min(m.start,y);m=m.end===void 0?w:Math.min(m.end,y),!s.extend&&w>m&&(y=m,m=w,w=y),y=x9(f,w);var E=x9(f,m);y&&E&&(s.rangeCount!==1||s.anchorNode!==y.node||s.anchorOffset!==y.offset||s.focusNode!==E.node||s.focusOffset!==E.offset)&&(l=l.createRange(),l.setStart(y.node,y.offset),s.removeAllRanges(),w>m?(s.addRange(l),s.extend(E.node,E.offset)):(l.setEnd(E.node,E.offset),s.addRange(l)))}}for(l=[],s=f;s=s.parentNode;)s.nodeType===1&&l.push({element:s,left:s.scrollLeft,top:s.scrollTop});for(typeof f.focus=="function"&&f.focus(),f=0;f<l.length;f++)s=l[f],s.element.scrollLeft=s.left,s.element.scrollTop=s.top}}var hL=c&&"documentMode"in document&&11>=document.documentMode,rh=null,y5=null,p1=null,_5=!1;function E9(s,l,f){var m=f.window===f?f.document:f.nodeType===9?f:f.ownerDocument;_5||rh==null||rh!==Un(m)||(m=rh,"selectionStart"in m&&g5(m)?m={start:m.selectionStart,end:m.selectionEnd}:(m=(m.ownerDocument&&m.ownerDocument.defaultView||window).getSelection(),m={anchorNode:m.anchorNode,anchorOffset:m.anchorOffset,focusNode:m.focusNode,focusOffset:m.focusOffset}),p1&&f1(p1,m)||(p1=m,m=A2(y5,"onSelect"),0<m.length&&(l=new l5("onSelect","select",null,l,f),s.push({event:l,listeners:m}),l.target=rh)))}function E2(s,l){var f={};return f[s.toLowerCase()]=l.toLowerCase(),f["Webkit"+s]="webkit"+l,f["Moz"+s]="moz"+l,f}var nh={animationend:E2("Animation","AnimationEnd"),animationiteration:E2("Animation","AnimationIteration"),animationstart:E2("Animation","AnimationStart"),transitionend:E2("Transition","TransitionEnd")},b5={},S9={};c&&(S9=document.createElement("div").style,"AnimationEvent"in window||(delete nh.animationend.animation,delete nh.animationiteration.animation,delete nh.animationstart.animation),"TransitionEvent"in window||delete nh.transitionend.transition);function S2(s){if(b5[s])return b5[s];if(!nh[s])return s;var l=nh[s],f;for(f in l)if(l.hasOwnProperty(f)&&f in S9)return b5[s]=l[f];return s}var T9=S2("animationend"),A9=S2("animationiteration"),I9=S2("animationstart"),R9=S2("transitionend"),P9=new Map,M9="abort auxClick cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel".split(" ");function Zc(s,l){P9.set(s,l),o(l,[s])}for(var w5=0;w5<M9.length;w5++){var x5=M9[w5],fL=x5.toLowerCase(),pL=x5[0].toUpperCase()+x5.slice(1);Zc(fL,"on"+pL)}Zc(T9,"onAnimationEnd"),Zc(A9,"onAnimationIteration"),Zc(I9,"onAnimationStart"),Zc("dblclick","onDoubleClick"),Zc("focusin","onFocus"),Zc("focusout","onBlur"),Zc(R9,"onTransitionEnd"),a("onMouseEnter",["mouseout","mouseover"]),a("onMouseLeave",["mouseout","mouseover"]),a("onPointerEnter",["pointerout","pointerover"]),a("onPointerLeave",["pointerout","pointerover"]),o("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),o("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),o("onBeforeInput",["compositionend","keypress","textInput","paste"]),o("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),o("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),o("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var m1="abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange resize seeked seeking stalled suspend timeupdate volumechange waiting".split(" "),mL=new Set("cancel close invalid load scroll toggle".split(" ").concat(m1));function $9(s,l,f){var m=s.type||"unknown-event";s.currentTarget=f,je(m,l,void 0,s),s.currentTarget=null}function O9(s,l){l=(l&4)!==0;for(var f=0;f<s.length;f++){var m=s[f],y=m.event;m=m.listeners;e:{var w=void 0;if(l)for(var E=m.length-1;0<=E;E--){var L=m[E],V=L.instance,ne=L.currentTarget;if(L=L.listener,V!==w&&y.isPropagationStopped())break e;$9(y,L,ne),w=V}else for(E=0;E<m.length;E++){if(L=m[E],V=L.instance,ne=L.currentTarget,L=L.listener,V!==w&&y.isPropagationStopped())break e;$9(y,L,ne),w=V}}}if(Ve)throw s=mt,Ve=!1,mt=null,s}function Zr(s,l){var f=l[R5];f===void 0&&(f=l[R5]=new Set);var m=s+"__bubble";f.has(m)||(Z9(l,s,2,!1),f.add(m))}function C5(s,l,f){var m=0;l&&(m|=4),Z9(f,s,m,l)}var T2="_reactListening"+Math.random().toString(36).slice(2);function v1(s){if(!s[T2]){s[T2]=!0,n.forEach(function(f){f!=="selectionchange"&&(mL.has(f)||C5(f,!1,s),C5(f,!0,s))});var l=s.nodeType===9?s:s.ownerDocument;l===null||l[T2]||(l[T2]=!0,C5("selectionchange",!1,l))}}function Z9(s,l,f,m){switch(qn(l)){case 1:var y=ue;break;case 4:y=at;break;default:y=vn}f=y.bind(null,l,f,s),y=void 0,!D||l!=="touchstart"&&l!=="touchmove"&&l!=="wheel"||(y=!0),m?y!==void 0?s.addEventListener(l,f,{capture:!0,passive:y}):s.addEventListener(l,f,!0):y!==void 0?s.addEventListener(l,f,{passive:y}):s.addEventListener(l,f,!1)}function k5(s,l,f,m,y){var w=m;if((l&1)===0&&(l&2)===0&&m!==null)e:for(;;){if(m===null)return;var E=m.tag;if(E===3||E===4){var L=m.stateNode.containerInfo;if(L===y||L.nodeType===8&&L.parentNode===y)break;if(E===4)for(E=m.return;E!==null;){var V=E.tag;if((V===3||V===4)&&(V=E.stateNode.containerInfo,V===y||V.nodeType===8&&V.parentNode===y))return;E=E.return}for(;L!==null;){if(E=id(L),E===null)return;if(V=E.tag,V===5||V===6){m=w=E;continue e}L=L.parentNode}}m=m.return}Wl(function(){var ne=w,ge=Zo(f),_e=[];e:{var ve=P9.get(s);if(ve!==void 0){var Fe=l5,tt=s;switch(s){case"keypress":if(rd(f)===0)break e;case"keydown":case"keyup":Fe=UZ;break;case"focusin":tt="focus",Fe=h5;break;case"focusout":tt="blur",Fe=h5;break;case"beforeblur":case"afterblur":Fe=h5;break;case"click":if(f.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":Fe=s9;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":Fe=$Z;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":Fe=GZ;break;case T9:case A9:case I9:Fe=LZ;break;case R9:Fe=YZ;break;case"scroll":Fe=PZ;break;case"wheel":Fe=XZ;break;case"copy":case"cut":case"paste":Fe=NZ;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":Fe=l9}var nt=(l&4)!==0,gn=!nt&&s==="scroll",X=nt?ve!==null?ve+"Capture":null:ve;nt=[];for(var W=ne,ee;W!==null;){ee=W;var Se=ee.stateNode;if(ee.tag===5&&Se!==null&&(ee=Se,X!==null&&(Se=Ri(W,X),Se!=null&&nt.push(g1(W,Se,ee)))),gn)break;W=W.return}0<nt.length&&(ve=new Fe(ve,tt,null,f,ge),_e.push({event:ve,listeners:nt}))}}if((l&7)===0){e:{if(ve=s==="mouseover"||s==="pointerover",Fe=s==="mouseout"||s==="pointerout",ve&&f!==Oo&&(tt=f.relatedTarget||f.fromElement)&&(id(tt)||tt[Ls]))break e;if((Fe||ve)&&(ve=ge.window===ge?ge:(ve=ge.ownerDocument)?ve.defaultView||ve.parentWindow:window,Fe?(tt=f.relatedTarget||f.toElement,Fe=ne,tt=tt?id(tt):null,tt!==null&&(gn=Je(tt),tt!==gn||tt.tag!==5&&tt.tag!==6)&&(tt=null)):(Fe=null,tt=ne),Fe!==tt)){if(nt=s9,Se="onMouseLeave",X="onMouseEnter",W="mouse",(s==="pointerout"||s==="pointerover")&&(nt=l9,Se="onPointerLeave",X="onPointerEnter",W="pointer"),gn=Fe==null?ve:ah(Fe),ee=tt==null?ve:ah(tt),ve=new nt(Se,W+"leave",Fe,f,ge),ve.target=gn,ve.relatedTarget=ee,Se=null,id(ge)===ne&&(nt=new nt(X,W+"enter",tt,f,ge),nt.target=ee,nt.relatedTarget=gn,Se=nt),gn=Se,Fe&&tt)t:{for(nt=Fe,X=tt,W=0,ee=nt;ee;ee=ih(ee))W++;for(ee=0,Se=X;Se;Se=ih(Se))ee++;for(;0<W-ee;)nt=ih(nt),W--;for(;0<ee-W;)X=ih(X),ee--;for(;W--;){if(nt===X||X!==null&&nt===X.alternate)break t;nt=ih(nt),X=ih(X)}nt=null}else nt=null;Fe!==null&&L9(_e,ve,Fe,nt,!1),tt!==null&&gn!==null&&L9(_e,gn,tt,nt,!0)}}e:{if(ve=ne?ah(ne):window,Fe=ve.nodeName&&ve.nodeName.toLowerCase(),Fe==="select"||Fe==="input"&&ve.type==="file")var st=oL;else if(m9(ve))if(g9)st=lL;else{st=sL;var ht=aL}else(Fe=ve.nodeName)&&Fe.toLowerCase()==="input"&&(ve.type==="checkbox"||ve.type==="radio")&&(st=cL);if(st&&(st=st(s,ne))){v9(_e,st,f,ge);break e}ht&&ht(s,ve,ne),s==="focusout"&&(ht=ve._wrapperState)&&ht.controlled&&ve.type==="number"&&Tc(ve,"number",ve.value)}switch(ht=ne?ah(ne):window,s){case"focusin":(m9(ht)||ht.contentEditable==="true")&&(rh=ht,y5=ne,p1=null);break;case"focusout":p1=y5=rh=null;break;case"mousedown":_5=!0;break;case"contextmenu":case"mouseup":case"dragend":_5=!1,E9(_e,f,ge);break;case"selectionchange":if(hL)break;case"keydown":case"keyup":E9(_e,f,ge)}var ft;if(p5)e:{switch(s){case"compositionstart":var xt="onCompositionStart";break e;case"compositionend":xt="onCompositionEnd";break e;case"compositionupdate":xt="onCompositionUpdate";break e}xt=void 0}else th?f9(s,f)&&(xt="onCompositionEnd"):s==="keydown"&&f.keyCode===229&&(xt="onCompositionStart");xt&&(d9&&f.locale!=="ko"&&(th||xt!=="onCompositionStart"?xt==="onCompositionEnd"&&th&&(ft=s1()):(ba=ge,Ya="value"in ba?ba.value:ba.textContent,th=!0)),ht=A2(ne,xt),0<ht.length&&(xt=new c9(xt,s,null,f,ge),_e.push({event:xt,listeners:ht}),ft?xt.data=ft:(ft=p9(f),ft!==null&&(xt.data=ft)))),(ft=eL?tL(s,f):rL(s,f))&&(ne=A2(ne,"onBeforeInput"),0<ne.length&&(ge=new c9("onBeforeInput","beforeinput",null,f,ge),_e.push({event:ge,listeners:ne}),ge.data=ft))}O9(_e,l)})}function g1(s,l,f){return{instance:s,listener:l,currentTarget:f}}function A2(s,l){for(var f=l+"Capture",m=[];s!==null;){var y=s,w=y.stateNode;y.tag===5&&w!==null&&(y=w,w=Ri(s,f),w!=null&&m.unshift(g1(s,w,y)),w=Ri(s,l),w!=null&&m.push(g1(s,w,y))),s=s.return}return m}function ih(s){if(s===null)return null;do s=s.return;while(s&&s.tag!==5);return s||null}function L9(s,l,f,m,y){for(var w=l._reactName,E=[];f!==null&&f!==m;){var L=f,V=L.alternate,ne=L.stateNode;if(V!==null&&V===m)break;L.tag===5&&ne!==null&&(L=ne,y?(V=Ri(f,w),V!=null&&E.unshift(g1(f,V,L))):y||(V=Ri(f,w),V!=null&&E.push(g1(f,V,L)))),f=f.return}E.length!==0&&s.push({event:l,listeners:E})}var vL=/\r\n?/g,gL=/\u0000|\uFFFD/g;function H9(s){return(typeof s=="string"?s:""+s).replace(vL,`
38
+ `).replace(gL,"")}function I2(s,l,f){if(l=H9(l),H9(s)!==l&&f)throw Error(t(425))}function R2(){}var E5=null,S5=null;function T5(s,l){return s==="textarea"||s==="noscript"||typeof l.children=="string"||typeof l.children=="number"||typeof l.dangerouslySetInnerHTML=="object"&&l.dangerouslySetInnerHTML!==null&&l.dangerouslySetInnerHTML.__html!=null}var A5=typeof setTimeout=="function"?setTimeout:void 0,yL=typeof clearTimeout=="function"?clearTimeout:void 0,N9=typeof Promise=="function"?Promise:void 0,_L=typeof queueMicrotask=="function"?queueMicrotask:typeof N9<"u"?function(s){return N9.resolve(null).then(s).catch(bL)}:A5;function bL(s){setTimeout(function(){throw s})}function I5(s,l){var f=l,m=0;do{var y=f.nextSibling;if(s.removeChild(f),y&&y.nodeType===8)if(f=y.data,f==="/$"){if(m===0){s.removeChild(y),ed(l);return}m--}else f!=="$"&&f!=="$?"&&f!=="$!"||m++;f=y}while(f);ed(l)}function Lc(s){for(;s!=null;s=s.nextSibling){var l=s.nodeType;if(l===1||l===3)break;if(l===8){if(l=s.data,l==="$"||l==="$!"||l==="$?")break;if(l==="/$")return null}}return s}function D9(s){s=s.previousSibling;for(var l=0;s;){if(s.nodeType===8){var f=s.data;if(f==="$"||f==="$!"||f==="$?"){if(l===0)return s;l--}else f==="/$"&&l++}s=s.previousSibling}return null}var oh=Math.random().toString(36).slice(2),Qa="__reactFiber$"+oh,y1="__reactProps$"+oh,Ls="__reactContainer$"+oh,R5="__reactEvents$"+oh,wL="__reactListeners$"+oh,xL="__reactHandles$"+oh;function id(s){var l=s[Qa];if(l)return l;for(var f=s.parentNode;f;){if(l=f[Ls]||f[Qa]){if(f=l.alternate,l.child!==null||f!==null&&f.child!==null)for(s=D9(s);s!==null;){if(f=s[Qa])return f;s=D9(s)}return l}s=f,f=s.parentNode}return null}function _1(s){return s=s[Qa]||s[Ls],!s||s.tag!==5&&s.tag!==6&&s.tag!==13&&s.tag!==3?null:s}function ah(s){if(s.tag===5||s.tag===6)return s.stateNode;throw Error(t(33))}function P2(s){return s[y1]||null}var P5=[],sh=-1;function Hc(s){return{current:s}}function Lr(s){0>sh||(s.current=P5[sh],P5[sh]=null,sh--)}function Ir(s,l){sh++,P5[sh]=s.current,s.current=l}var Nc={},di=Hc(Nc),Gi=Hc(!1),od=Nc;function ch(s,l){var f=s.type.contextTypes;if(!f)return Nc;var m=s.stateNode;if(m&&m.__reactInternalMemoizedUnmaskedChildContext===l)return m.__reactInternalMemoizedMaskedChildContext;var y={},w;for(w in f)y[w]=l[w];return m&&(s=s.stateNode,s.__reactInternalMemoizedUnmaskedChildContext=l,s.__reactInternalMemoizedMaskedChildContext=y),y}function Ki(s){return s=s.childContextTypes,s!=null}function M2(){Lr(Gi),Lr(di)}function V9(s,l,f){if(di.current!==Nc)throw Error(t(168));Ir(di,l),Ir(Gi,f)}function F9(s,l,f){var m=s.stateNode;if(l=l.childContextTypes,typeof m.getChildContext!="function")return f;m=m.getChildContext();for(var y in m)if(!(y in l))throw Error(t(108,Ke(s)||"Unknown",y));return H({},f,m)}function $2(s){return s=(s=s.stateNode)&&s.__reactInternalMemoizedMergedChildContext||Nc,od=di.current,Ir(di,s),Ir(Gi,Gi.current),!0}function j9(s,l,f){var m=s.stateNode;if(!m)throw Error(t(169));f?(s=F9(s,l,od),m.__reactInternalMemoizedMergedChildContext=s,Lr(Gi),Lr(di),Ir(di,s)):Lr(Gi),Ir(Gi,f)}var Hs=null,O2=!1,M5=!1;function z9(s){Hs===null?Hs=[s]:Hs.push(s)}function CL(s){O2=!0,z9(s)}function Dc(){if(!M5&&Hs!==null){M5=!0;var s=0,l=qt;try{var f=Hs;for(qt=1;s<f.length;s++){var m=f[s];do m=m(!0);while(m!==null)}Hs=null,O2=!1}catch(y){throw Hs!==null&&(Hs=Hs.slice(s+1)),Er(ga,Dc),y}finally{qt=l,M5=!1}}return null}var lh=[],dh=0,Z2=null,L2=0,Do=[],Vo=0,ad=null,Ns=1,Ds="";function sd(s,l){lh[dh++]=L2,lh[dh++]=Z2,Z2=s,L2=l}function B9(s,l,f){Do[Vo++]=Ns,Do[Vo++]=Ds,Do[Vo++]=ad,ad=s;var m=Ns;s=Ds;var y=32-Yt(m)-1;m&=~(1<<y),f+=1;var w=32-Yt(l)+y;if(30<w){var E=y-y%5;w=(m&(1<<E)-1).toString(32),m>>=E,y-=E,Ns=1<<32-Yt(l)+y|f<<y|m,Ds=w+s}else Ns=1<<w|f<<y|m,Ds=s}function $5(s){s.return!==null&&(sd(s,1),B9(s,1,0))}function O5(s){for(;s===Z2;)Z2=lh[--dh],lh[dh]=null,L2=lh[--dh],lh[dh]=null;for(;s===ad;)ad=Do[--Vo],Do[Vo]=null,Ds=Do[--Vo],Do[Vo]=null,Ns=Do[--Vo],Do[Vo]=null}var mo=null,vo=null,Vr=!1,xa=null;function U9(s,l){var f=Bo(5,null,null,0);f.elementType="DELETED",f.stateNode=l,f.return=s,l=s.deletions,l===null?(s.deletions=[f],s.flags|=16):l.push(f)}function q9(s,l){switch(s.tag){case 5:var f=s.type;return l=l.nodeType!==1||f.toLowerCase()!==l.nodeName.toLowerCase()?null:l,l!==null?(s.stateNode=l,mo=s,vo=Lc(l.firstChild),!0):!1;case 6:return l=s.pendingProps===""||l.nodeType!==3?null:l,l!==null?(s.stateNode=l,mo=s,vo=null,!0):!1;case 13:return l=l.nodeType!==8?null:l,l!==null?(f=ad!==null?{id:Ns,overflow:Ds}:null,s.memoizedState={dehydrated:l,treeContext:f,retryLane:1073741824},f=Bo(18,null,null,0),f.stateNode=l,f.return=s,s.child=f,mo=s,vo=null,!0):!1;default:return!1}}function Z5(s){return(s.mode&1)!==0&&(s.flags&128)===0}function L5(s){if(Vr){var l=vo;if(l){var f=l;if(!q9(s,l)){if(Z5(s))throw Error(t(418));l=Lc(f.nextSibling);var m=mo;l&&q9(s,l)?U9(m,f):(s.flags=s.flags&-4097|2,Vr=!1,mo=s)}}else{if(Z5(s))throw Error(t(418));s.flags=s.flags&-4097|2,Vr=!1,mo=s}}}function W9(s){for(s=s.return;s!==null&&s.tag!==5&&s.tag!==3&&s.tag!==13;)s=s.return;mo=s}function H2(s){if(s!==mo)return!1;if(!Vr)return W9(s),Vr=!0,!1;var l;if((l=s.tag!==3)&&!(l=s.tag!==5)&&(l=s.type,l=l!=="head"&&l!=="body"&&!T5(s.type,s.memoizedProps)),l&&(l=vo)){if(Z5(s))throw G9(),Error(t(418));for(;l;)U9(s,l),l=Lc(l.nextSibling)}if(W9(s),s.tag===13){if(s=s.memoizedState,s=s!==null?s.dehydrated:null,!s)throw Error(t(317));e:{for(s=s.nextSibling,l=0;s;){if(s.nodeType===8){var f=s.data;if(f==="/$"){if(l===0){vo=Lc(s.nextSibling);break e}l--}else f!=="$"&&f!=="$!"&&f!=="$?"||l++}s=s.nextSibling}vo=null}}else vo=mo?Lc(s.stateNode.nextSibling):null;return!0}function G9(){for(var s=vo;s;)s=Lc(s.nextSibling)}function uh(){vo=mo=null,Vr=!1}function H5(s){xa===null?xa=[s]:xa.push(s)}var kL=Z.ReactCurrentBatchConfig;function b1(s,l,f){if(s=f.ref,s!==null&&typeof s!="function"&&typeof s!="object"){if(f._owner){if(f=f._owner,f){if(f.tag!==1)throw Error(t(309));var m=f.stateNode}if(!m)throw Error(t(147,s));var y=m,w=""+s;return l!==null&&l.ref!==null&&typeof l.ref=="function"&&l.ref._stringRef===w?l.ref:(l=function(E){var L=y.refs;E===null?delete L[w]:L[w]=E},l._stringRef=w,l)}if(typeof s!="string")throw Error(t(284));if(!f._owner)throw Error(t(290,s))}return s}function N2(s,l){throw s=Object.prototype.toString.call(l),Error(t(31,s==="[object Object]"?"object with keys {"+Object.keys(l).join(", ")+"}":s))}function K9(s){var l=s._init;return l(s._payload)}function Y9(s){function l(X,W){if(s){var ee=X.deletions;ee===null?(X.deletions=[W],X.flags|=16):ee.push(W)}}function f(X,W){if(!s)return null;for(;W!==null;)l(X,W),W=W.sibling;return null}function m(X,W){for(X=new Map;W!==null;)W.key!==null?X.set(W.key,W):X.set(W.index,W),W=W.sibling;return X}function y(X,W){return X=Wc(X,W),X.index=0,X.sibling=null,X}function w(X,W,ee){return X.index=ee,s?(ee=X.alternate,ee!==null?(ee=ee.index,ee<W?(X.flags|=2,W):ee):(X.flags|=2,W)):(X.flags|=1048576,W)}function E(X){return s&&X.alternate===null&&(X.flags|=2),X}function L(X,W,ee,Se){return W===null||W.tag!==6?(W=Ay(ee,X.mode,Se),W.return=X,W):(W=y(W,ee),W.return=X,W)}function V(X,W,ee,Se){var st=ee.type;return st===I?ge(X,W,ee.props.children,Se,ee.key):W!==null&&(W.elementType===st||typeof st=="object"&&st!==null&&st.$$typeof===re&&K9(st)===W.type)?(Se=y(W,ee.props),Se.ref=b1(X,W,ee),Se.return=X,Se):(Se=c0(ee.type,ee.key,ee.props,null,X.mode,Se),Se.ref=b1(X,W,ee),Se.return=X,Se)}function ne(X,W,ee,Se){return W===null||W.tag!==4||W.stateNode.containerInfo!==ee.containerInfo||W.stateNode.implementation!==ee.implementation?(W=Iy(ee,X.mode,Se),W.return=X,W):(W=y(W,ee.children||[]),W.return=X,W)}function ge(X,W,ee,Se,st){return W===null||W.tag!==7?(W=md(ee,X.mode,Se,st),W.return=X,W):(W=y(W,ee),W.return=X,W)}function _e(X,W,ee){if(typeof W=="string"&&W!==""||typeof W=="number")return W=Ay(""+W,X.mode,ee),W.return=X,W;if(typeof W=="object"&&W!==null){switch(W.$$typeof){case B:return ee=c0(W.type,W.key,W.props,null,X.mode,ee),ee.ref=b1(X,null,W),ee.return=X,ee;case U:return W=Iy(W,X.mode,ee),W.return=X,W;case re:var Se=W._init;return _e(X,Se(W._payload),ee)}if(Po(W)||O(W))return W=md(W,X.mode,ee,null),W.return=X,W;N2(X,W)}return null}function ve(X,W,ee,Se){var st=W!==null?W.key:null;if(typeof ee=="string"&&ee!==""||typeof ee=="number")return st!==null?null:L(X,W,""+ee,Se);if(typeof ee=="object"&&ee!==null){switch(ee.$$typeof){case B:return ee.key===st?V(X,W,ee,Se):null;case U:return ee.key===st?ne(X,W,ee,Se):null;case re:return st=ee._init,ve(X,W,st(ee._payload),Se)}if(Po(ee)||O(ee))return st!==null?null:ge(X,W,ee,Se,null);N2(X,ee)}return null}function Fe(X,W,ee,Se,st){if(typeof Se=="string"&&Se!==""||typeof Se=="number")return X=X.get(ee)||null,L(W,X,""+Se,st);if(typeof Se=="object"&&Se!==null){switch(Se.$$typeof){case B:return X=X.get(Se.key===null?ee:Se.key)||null,V(W,X,Se,st);case U:return X=X.get(Se.key===null?ee:Se.key)||null,ne(W,X,Se,st);case re:var ht=Se._init;return Fe(X,W,ee,ht(Se._payload),st)}if(Po(Se)||O(Se))return X=X.get(ee)||null,ge(W,X,Se,st,null);N2(W,Se)}return null}function tt(X,W,ee,Se){for(var st=null,ht=null,ft=W,xt=W=0,Nn=null;ft!==null&&xt<ee.length;xt++){ft.index>xt?(Nn=ft,ft=null):Nn=ft.sibling;var tr=ve(X,ft,ee[xt],Se);if(tr===null){ft===null&&(ft=Nn);break}s&&ft&&tr.alternate===null&&l(X,ft),W=w(tr,W,xt),ht===null?st=tr:ht.sibling=tr,ht=tr,ft=Nn}if(xt===ee.length)return f(X,ft),Vr&&sd(X,xt),st;if(ft===null){for(;xt<ee.length;xt++)ft=_e(X,ee[xt],Se),ft!==null&&(W=w(ft,W,xt),ht===null?st=ft:ht.sibling=ft,ht=ft);return Vr&&sd(X,xt),st}for(ft=m(X,ft);xt<ee.length;xt++)Nn=Fe(ft,X,xt,ee[xt],Se),Nn!==null&&(s&&Nn.alternate!==null&&ft.delete(Nn.key===null?xt:Nn.key),W=w(Nn,W,xt),ht===null?st=Nn:ht.sibling=Nn,ht=Nn);return s&&ft.forEach(function(Gc){return l(X,Gc)}),Vr&&sd(X,xt),st}function nt(X,W,ee,Se){var st=O(ee);if(typeof st!="function")throw Error(t(150));if(ee=st.call(ee),ee==null)throw Error(t(151));for(var ht=st=null,ft=W,xt=W=0,Nn=null,tr=ee.next();ft!==null&&!tr.done;xt++,tr=ee.next()){ft.index>xt?(Nn=ft,ft=null):Nn=ft.sibling;var Gc=ve(X,ft,tr.value,Se);if(Gc===null){ft===null&&(ft=Nn);break}s&&ft&&Gc.alternate===null&&l(X,ft),W=w(Gc,W,xt),ht===null?st=Gc:ht.sibling=Gc,ht=Gc,ft=Nn}if(tr.done)return f(X,ft),Vr&&sd(X,xt),st;if(ft===null){for(;!tr.done;xt++,tr=ee.next())tr=_e(X,tr.value,Se),tr!==null&&(W=w(tr,W,xt),ht===null?st=tr:ht.sibling=tr,ht=tr);return Vr&&sd(X,xt),st}for(ft=m(X,ft);!tr.done;xt++,tr=ee.next())tr=Fe(ft,X,xt,tr.value,Se),tr!==null&&(s&&tr.alternate!==null&&ft.delete(tr.key===null?xt:tr.key),W=w(tr,W,xt),ht===null?st=tr:ht.sibling=tr,ht=tr);return s&&ft.forEach(function(nH){return l(X,nH)}),Vr&&sd(X,xt),st}function gn(X,W,ee,Se){if(typeof ee=="object"&&ee!==null&&ee.type===I&&ee.key===null&&(ee=ee.props.children),typeof ee=="object"&&ee!==null){switch(ee.$$typeof){case B:e:{for(var st=ee.key,ht=W;ht!==null;){if(ht.key===st){if(st=ee.type,st===I){if(ht.tag===7){f(X,ht.sibling),W=y(ht,ee.props.children),W.return=X,X=W;break e}}else if(ht.elementType===st||typeof st=="object"&&st!==null&&st.$$typeof===re&&K9(st)===ht.type){f(X,ht.sibling),W=y(ht,ee.props),W.ref=b1(X,ht,ee),W.return=X,X=W;break e}f(X,ht);break}else l(X,ht);ht=ht.sibling}ee.type===I?(W=md(ee.props.children,X.mode,Se,ee.key),W.return=X,X=W):(Se=c0(ee.type,ee.key,ee.props,null,X.mode,Se),Se.ref=b1(X,W,ee),Se.return=X,X=Se)}return E(X);case U:e:{for(ht=ee.key;W!==null;){if(W.key===ht)if(W.tag===4&&W.stateNode.containerInfo===ee.containerInfo&&W.stateNode.implementation===ee.implementation){f(X,W.sibling),W=y(W,ee.children||[]),W.return=X,X=W;break e}else{f(X,W);break}else l(X,W);W=W.sibling}W=Iy(ee,X.mode,Se),W.return=X,X=W}return E(X);case re:return ht=ee._init,gn(X,W,ht(ee._payload),Se)}if(Po(ee))return tt(X,W,ee,Se);if(O(ee))return nt(X,W,ee,Se);N2(X,ee)}return typeof ee=="string"&&ee!==""||typeof ee=="number"?(ee=""+ee,W!==null&&W.tag===6?(f(X,W.sibling),W=y(W,ee),W.return=X,X=W):(f(X,W),W=Ay(ee,X.mode,Se),W.return=X,X=W),E(X)):f(X,W)}return gn}var hh=Y9(!0),Q9=Y9(!1),D2=Hc(null),V2=null,fh=null,N5=null;function D5(){N5=fh=V2=null}function V5(s){var l=D2.current;Lr(D2),s._currentValue=l}function F5(s,l,f){for(;s!==null;){var m=s.alternate;if((s.childLanes&l)!==l?(s.childLanes|=l,m!==null&&(m.childLanes|=l)):m!==null&&(m.childLanes&l)!==l&&(m.childLanes|=l),s===f)break;s=s.return}}function ph(s,l){V2=s,N5=fh=null,s=s.dependencies,s!==null&&s.firstContext!==null&&((s.lanes&l)!==0&&(Yi=!0),s.firstContext=null)}function Fo(s){var l=s._currentValue;if(N5!==s)if(s={context:s,memoizedValue:l,next:null},fh===null){if(V2===null)throw Error(t(308));fh=s,V2.dependencies={lanes:0,firstContext:s}}else fh=fh.next=s;return l}var cd=null;function j5(s){cd===null?cd=[s]:cd.push(s)}function X9(s,l,f,m){var y=l.interleaved;return y===null?(f.next=f,j5(l)):(f.next=y.next,y.next=f),l.interleaved=f,Vs(s,m)}function Vs(s,l){s.lanes|=l;var f=s.alternate;for(f!==null&&(f.lanes|=l),f=s,s=s.return;s!==null;)s.childLanes|=l,f=s.alternate,f!==null&&(f.childLanes|=l),f=s,s=s.return;return f.tag===3?f.stateNode:null}var Vc=!1;function z5(s){s.updateQueue={baseState:s.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function J9(s,l){s=s.updateQueue,l.updateQueue===s&&(l.updateQueue={baseState:s.baseState,firstBaseUpdate:s.firstBaseUpdate,lastBaseUpdate:s.lastBaseUpdate,shared:s.shared,effects:s.effects})}function Fs(s,l){return{eventTime:s,lane:l,tag:0,payload:null,callback:null,next:null}}function Fc(s,l,f){var m=s.updateQueue;if(m===null)return null;if(m=m.shared,(Xt&2)!==0){var y=m.pending;return y===null?l.next=l:(l.next=y.next,y.next=l),m.pending=l,Vs(s,f)}return y=m.interleaved,y===null?(l.next=l,j5(m)):(l.next=y.next,y.next=l),m.interleaved=l,Vs(s,f)}function F2(s,l,f){if(l=l.updateQueue,l!==null&&(l=l.shared,(f&4194240)!==0)){var m=l.lanes;m&=s.pendingLanes,f|=m,l.lanes=f,Mc(s,f)}}function e7(s,l){var f=s.updateQueue,m=s.alternate;if(m!==null&&(m=m.updateQueue,f===m)){var y=null,w=null;if(f=f.firstBaseUpdate,f!==null){do{var E={eventTime:f.eventTime,lane:f.lane,tag:f.tag,payload:f.payload,callback:f.callback,next:null};w===null?y=w=E:w=w.next=E,f=f.next}while(f!==null);w===null?y=w=l:w=w.next=l}else y=w=l;f={baseState:m.baseState,firstBaseUpdate:y,lastBaseUpdate:w,shared:m.shared,effects:m.effects},s.updateQueue=f;return}s=f.lastBaseUpdate,s===null?f.firstBaseUpdate=l:s.next=l,f.lastBaseUpdate=l}function j2(s,l,f,m){var y=s.updateQueue;Vc=!1;var w=y.firstBaseUpdate,E=y.lastBaseUpdate,L=y.shared.pending;if(L!==null){y.shared.pending=null;var V=L,ne=V.next;V.next=null,E===null?w=ne:E.next=ne,E=V;var ge=s.alternate;ge!==null&&(ge=ge.updateQueue,L=ge.lastBaseUpdate,L!==E&&(L===null?ge.firstBaseUpdate=ne:L.next=ne,ge.lastBaseUpdate=V))}if(w!==null){var _e=y.baseState;E=0,ge=ne=V=null,L=w;do{var ve=L.lane,Fe=L.eventTime;if((m&ve)===ve){ge!==null&&(ge=ge.next={eventTime:Fe,lane:0,tag:L.tag,payload:L.payload,callback:L.callback,next:null});e:{var tt=s,nt=L;switch(ve=l,Fe=f,nt.tag){case 1:if(tt=nt.payload,typeof tt=="function"){_e=tt.call(Fe,_e,ve);break e}_e=tt;break e;case 3:tt.flags=tt.flags&-65537|128;case 0:if(tt=nt.payload,ve=typeof tt=="function"?tt.call(Fe,_e,ve):tt,ve==null)break e;_e=H({},_e,ve);break e;case 2:Vc=!0}}L.callback!==null&&L.lane!==0&&(s.flags|=64,ve=y.effects,ve===null?y.effects=[L]:ve.push(L))}else Fe={eventTime:Fe,lane:ve,tag:L.tag,payload:L.payload,callback:L.callback,next:null},ge===null?(ne=ge=Fe,V=_e):ge=ge.next=Fe,E|=ve;if(L=L.next,L===null){if(L=y.shared.pending,L===null)break;ve=L,L=ve.next,ve.next=null,y.lastBaseUpdate=ve,y.shared.pending=null}}while(!0);if(ge===null&&(V=_e),y.baseState=V,y.firstBaseUpdate=ne,y.lastBaseUpdate=ge,l=y.shared.interleaved,l!==null){y=l;do E|=y.lane,y=y.next;while(y!==l)}else w===null&&(y.shared.lanes=0);ud|=E,s.lanes=E,s.memoizedState=_e}}function t7(s,l,f){if(s=l.effects,l.effects=null,s!==null)for(l=0;l<s.length;l++){var m=s[l],y=m.callback;if(y!==null){if(m.callback=null,m=f,typeof y!="function")throw Error(t(191,y));y.call(m)}}}var w1={},Xa=Hc(w1),x1=Hc(w1),C1=Hc(w1);function ld(s){if(s===w1)throw Error(t(174));return s}function B5(s,l){switch(Ir(C1,l),Ir(x1,s),Ir(Xa,w1),s=l.nodeType,s){case 9:case 11:l=(l=l.documentElement)?l.namespaceURI:Ba(null,"");break;default:s=s===8?l.parentNode:l,l=s.namespaceURI||null,s=s.tagName,l=Ba(l,s)}Lr(Xa),Ir(Xa,l)}function mh(){Lr(Xa),Lr(x1),Lr(C1)}function r7(s){ld(C1.current);var l=ld(Xa.current),f=Ba(l,s.type);l!==f&&(Ir(x1,s),Ir(Xa,f))}function U5(s){x1.current===s&&(Lr(Xa),Lr(x1))}var Gr=Hc(0);function z2(s){for(var l=s;l!==null;){if(l.tag===13){var f=l.memoizedState;if(f!==null&&(f=f.dehydrated,f===null||f.data==="$?"||f.data==="$!"))return l}else if(l.tag===19&&l.memoizedProps.revealOrder!==void 0){if((l.flags&128)!==0)return l}else if(l.child!==null){l.child.return=l,l=l.child;continue}if(l===s)break;for(;l.sibling===null;){if(l.return===null||l.return===s)return null;l=l.return}l.sibling.return=l.return,l=l.sibling}return null}var q5=[];function W5(){for(var s=0;s<q5.length;s++)q5[s]._workInProgressVersionPrimary=null;q5.length=0}var B2=Z.ReactCurrentDispatcher,G5=Z.ReactCurrentBatchConfig,dd=0,Kr=null,Pn=null,Ln=null,U2=!1,k1=!1,E1=0,EL=0;function ui(){throw Error(t(321))}function K5(s,l){if(l===null)return!1;for(var f=0;f<l.length&&f<s.length;f++)if(!wa(s[f],l[f]))return!1;return!0}function Y5(s,l,f,m,y,w){if(dd=w,Kr=l,l.memoizedState=null,l.updateQueue=null,l.lanes=0,B2.current=s===null||s.memoizedState===null?IL:RL,s=f(m,y),k1){w=0;do{if(k1=!1,E1=0,25<=w)throw Error(t(301));w+=1,Ln=Pn=null,l.updateQueue=null,B2.current=PL,s=f(m,y)}while(k1)}if(B2.current=G2,l=Pn!==null&&Pn.next!==null,dd=0,Ln=Pn=Kr=null,U2=!1,l)throw Error(t(300));return s}function Q5(){var s=E1!==0;return E1=0,s}function Ja(){var s={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return Ln===null?Kr.memoizedState=Ln=s:Ln=Ln.next=s,Ln}function jo(){if(Pn===null){var s=Kr.alternate;s=s!==null?s.memoizedState:null}else s=Pn.next;var l=Ln===null?Kr.memoizedState:Ln.next;if(l!==null)Ln=l,Pn=s;else{if(s===null)throw Error(t(310));Pn=s,s={memoizedState:Pn.memoizedState,baseState:Pn.baseState,baseQueue:Pn.baseQueue,queue:Pn.queue,next:null},Ln===null?Kr.memoizedState=Ln=s:Ln=Ln.next=s}return Ln}function S1(s,l){return typeof l=="function"?l(s):l}function X5(s){var l=jo(),f=l.queue;if(f===null)throw Error(t(311));f.lastRenderedReducer=s;var m=Pn,y=m.baseQueue,w=f.pending;if(w!==null){if(y!==null){var E=y.next;y.next=w.next,w.next=E}m.baseQueue=y=w,f.pending=null}if(y!==null){w=y.next,m=m.baseState;var L=E=null,V=null,ne=w;do{var ge=ne.lane;if((dd&ge)===ge)V!==null&&(V=V.next={lane:0,action:ne.action,hasEagerState:ne.hasEagerState,eagerState:ne.eagerState,next:null}),m=ne.hasEagerState?ne.eagerState:s(m,ne.action);else{var _e={lane:ge,action:ne.action,hasEagerState:ne.hasEagerState,eagerState:ne.eagerState,next:null};V===null?(L=V=_e,E=m):V=V.next=_e,Kr.lanes|=ge,ud|=ge}ne=ne.next}while(ne!==null&&ne!==w);V===null?E=m:V.next=L,wa(m,l.memoizedState)||(Yi=!0),l.memoizedState=m,l.baseState=E,l.baseQueue=V,f.lastRenderedState=m}if(s=f.interleaved,s!==null){y=s;do w=y.lane,Kr.lanes|=w,ud|=w,y=y.next;while(y!==s)}else y===null&&(f.lanes=0);return[l.memoizedState,f.dispatch]}function J5(s){var l=jo(),f=l.queue;if(f===null)throw Error(t(311));f.lastRenderedReducer=s;var m=f.dispatch,y=f.pending,w=l.memoizedState;if(y!==null){f.pending=null;var E=y=y.next;do w=s(w,E.action),E=E.next;while(E!==y);wa(w,l.memoizedState)||(Yi=!0),l.memoizedState=w,l.baseQueue===null&&(l.baseState=w),f.lastRenderedState=w}return[w,m]}function n7(){}function i7(s,l){var f=Kr,m=jo(),y=l(),w=!wa(m.memoizedState,y);if(w&&(m.memoizedState=y,Yi=!0),m=m.queue,ey(s7.bind(null,f,m,s),[s]),m.getSnapshot!==l||w||Ln!==null&&Ln.memoizedState.tag&1){if(f.flags|=2048,T1(9,a7.bind(null,f,m,y,l),void 0,null),Hn===null)throw Error(t(349));(dd&30)!==0||o7(f,l,y)}return y}function o7(s,l,f){s.flags|=16384,s={getSnapshot:l,value:f},l=Kr.updateQueue,l===null?(l={lastEffect:null,stores:null},Kr.updateQueue=l,l.stores=[s]):(f=l.stores,f===null?l.stores=[s]:f.push(s))}function a7(s,l,f,m){l.value=f,l.getSnapshot=m,c7(l)&&l7(s)}function s7(s,l,f){return f(function(){c7(l)&&l7(s)})}function c7(s){var l=s.getSnapshot;s=s.value;try{var f=l();return!wa(s,f)}catch{return!0}}function l7(s){var l=Vs(s,1);l!==null&&Sa(l,s,1,-1)}function d7(s){var l=Ja();return typeof s=="function"&&(s=s()),l.memoizedState=l.baseState=s,s={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:S1,lastRenderedState:s},l.queue=s,s=s.dispatch=AL.bind(null,Kr,s),[l.memoizedState,s]}function T1(s,l,f,m){return s={tag:s,create:l,destroy:f,deps:m,next:null},l=Kr.updateQueue,l===null?(l={lastEffect:null,stores:null},Kr.updateQueue=l,l.lastEffect=s.next=s):(f=l.lastEffect,f===null?l.lastEffect=s.next=s:(m=f.next,f.next=s,s.next=m,l.lastEffect=s)),s}function u7(){return jo().memoizedState}function q2(s,l,f,m){var y=Ja();Kr.flags|=s,y.memoizedState=T1(1|l,f,void 0,m===void 0?null:m)}function W2(s,l,f,m){var y=jo();m=m===void 0?null:m;var w=void 0;if(Pn!==null){var E=Pn.memoizedState;if(w=E.destroy,m!==null&&K5(m,E.deps)){y.memoizedState=T1(l,f,w,m);return}}Kr.flags|=s,y.memoizedState=T1(1|l,f,w,m)}function h7(s,l){return q2(8390656,8,s,l)}function ey(s,l){return W2(2048,8,s,l)}function f7(s,l){return W2(4,2,s,l)}function p7(s,l){return W2(4,4,s,l)}function m7(s,l){if(typeof l=="function")return s=s(),l(s),function(){l(null)};if(l!=null)return s=s(),l.current=s,function(){l.current=null}}function v7(s,l,f){return f=f!=null?f.concat([s]):null,W2(4,4,m7.bind(null,l,s),f)}function ty(){}function g7(s,l){var f=jo();l=l===void 0?null:l;var m=f.memoizedState;return m!==null&&l!==null&&K5(l,m[1])?m[0]:(f.memoizedState=[s,l],s)}function y7(s,l){var f=jo();l=l===void 0?null:l;var m=f.memoizedState;return m!==null&&l!==null&&K5(l,m[1])?m[0]:(s=s(),f.memoizedState=[s,l],s)}function _7(s,l,f){return(dd&21)===0?(s.baseState&&(s.baseState=!1,Yi=!0),s.memoizedState=f):(wa(f,l)||(f=p2(),Kr.lanes|=f,ud|=f,s.baseState=!0),l)}function SL(s,l){var f=qt;qt=f!==0&&4>f?f:4,s(!0);var m=G5.transition;G5.transition={};try{s(!1),l()}finally{qt=f,G5.transition=m}}function b7(){return jo().memoizedState}function TL(s,l,f){var m=Uc(s);if(f={lane:m,action:f,hasEagerState:!1,eagerState:null,next:null},w7(s))x7(l,f);else if(f=X9(s,l,f,m),f!==null){var y=Mi();Sa(f,s,m,y),C7(f,l,m)}}function AL(s,l,f){var m=Uc(s),y={lane:m,action:f,hasEagerState:!1,eagerState:null,next:null};if(w7(s))x7(l,y);else{var w=s.alternate;if(s.lanes===0&&(w===null||w.lanes===0)&&(w=l.lastRenderedReducer,w!==null))try{var E=l.lastRenderedState,L=w(E,f);if(y.hasEagerState=!0,y.eagerState=L,wa(L,E)){var V=l.interleaved;V===null?(y.next=y,j5(l)):(y.next=V.next,V.next=y),l.interleaved=y;return}}catch{}finally{}f=X9(s,l,y,m),f!==null&&(y=Mi(),Sa(f,s,m,y),C7(f,l,m))}}function w7(s){var l=s.alternate;return s===Kr||l!==null&&l===Kr}function x7(s,l){k1=U2=!0;var f=s.pending;f===null?l.next=l:(l.next=f.next,f.next=l),s.pending=l}function C7(s,l,f){if((f&4194240)!==0){var m=l.lanes;m&=s.pendingLanes,f|=m,l.lanes=f,Mc(s,f)}}var G2={readContext:Fo,useCallback:ui,useContext:ui,useEffect:ui,useImperativeHandle:ui,useInsertionEffect:ui,useLayoutEffect:ui,useMemo:ui,useReducer:ui,useRef:ui,useState:ui,useDebugValue:ui,useDeferredValue:ui,useTransition:ui,useMutableSource:ui,useSyncExternalStore:ui,useId:ui,unstable_isNewReconciler:!1},IL={readContext:Fo,useCallback:function(s,l){return Ja().memoizedState=[s,l===void 0?null:l],s},useContext:Fo,useEffect:h7,useImperativeHandle:function(s,l,f){return f=f!=null?f.concat([s]):null,q2(4194308,4,m7.bind(null,l,s),f)},useLayoutEffect:function(s,l){return q2(4194308,4,s,l)},useInsertionEffect:function(s,l){return q2(4,2,s,l)},useMemo:function(s,l){var f=Ja();return l=l===void 0?null:l,s=s(),f.memoizedState=[s,l],s},useReducer:function(s,l,f){var m=Ja();return l=f!==void 0?f(l):l,m.memoizedState=m.baseState=l,s={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:s,lastRenderedState:l},m.queue=s,s=s.dispatch=TL.bind(null,Kr,s),[m.memoizedState,s]},useRef:function(s){var l=Ja();return s={current:s},l.memoizedState=s},useState:d7,useDebugValue:ty,useDeferredValue:function(s){return Ja().memoizedState=s},useTransition:function(){var s=d7(!1),l=s[0];return s=SL.bind(null,s[1]),Ja().memoizedState=s,[l,s]},useMutableSource:function(){},useSyncExternalStore:function(s,l,f){var m=Kr,y=Ja();if(Vr){if(f===void 0)throw Error(t(407));f=f()}else{if(f=l(),Hn===null)throw Error(t(349));(dd&30)!==0||o7(m,l,f)}y.memoizedState=f;var w={value:f,getSnapshot:l};return y.queue=w,h7(s7.bind(null,m,w,s),[s]),m.flags|=2048,T1(9,a7.bind(null,m,w,f,l),void 0,null),f},useId:function(){var s=Ja(),l=Hn.identifierPrefix;if(Vr){var f=Ds,m=Ns;f=(m&~(1<<32-Yt(m)-1)).toString(32)+f,l=":"+l+"R"+f,f=E1++,0<f&&(l+="H"+f.toString(32)),l+=":"}else f=EL++,l=":"+l+"r"+f.toString(32)+":";return s.memoizedState=l},unstable_isNewReconciler:!1},RL={readContext:Fo,useCallback:g7,useContext:Fo,useEffect:ey,useImperativeHandle:v7,useInsertionEffect:f7,useLayoutEffect:p7,useMemo:y7,useReducer:X5,useRef:u7,useState:function(){return X5(S1)},useDebugValue:ty,useDeferredValue:function(s){var l=jo();return _7(l,Pn.memoizedState,s)},useTransition:function(){var s=X5(S1)[0],l=jo().memoizedState;return[s,l]},useMutableSource:n7,useSyncExternalStore:i7,useId:b7,unstable_isNewReconciler:!1},PL={readContext:Fo,useCallback:g7,useContext:Fo,useEffect:ey,useImperativeHandle:v7,useInsertionEffect:f7,useLayoutEffect:p7,useMemo:y7,useReducer:J5,useRef:u7,useState:function(){return J5(S1)},useDebugValue:ty,useDeferredValue:function(s){var l=jo();return Pn===null?l.memoizedState=s:_7(l,Pn.memoizedState,s)},useTransition:function(){var s=J5(S1)[0],l=jo().memoizedState;return[s,l]},useMutableSource:n7,useSyncExternalStore:i7,useId:b7,unstable_isNewReconciler:!1};function Ca(s,l){if(s&&s.defaultProps){l=H({},l),s=s.defaultProps;for(var f in s)l[f]===void 0&&(l[f]=s[f]);return l}return l}function ry(s,l,f,m){l=s.memoizedState,f=f(m,l),f=f==null?l:H({},l,f),s.memoizedState=f,s.lanes===0&&(s.updateQueue.baseState=f)}var K2={isMounted:function(s){return(s=s._reactInternals)?Je(s)===s:!1},enqueueSetState:function(s,l,f){s=s._reactInternals;var m=Mi(),y=Uc(s),w=Fs(m,y);w.payload=l,f!=null&&(w.callback=f),l=Fc(s,w,y),l!==null&&(Sa(l,s,y,m),F2(l,s,y))},enqueueReplaceState:function(s,l,f){s=s._reactInternals;var m=Mi(),y=Uc(s),w=Fs(m,y);w.tag=1,w.payload=l,f!=null&&(w.callback=f),l=Fc(s,w,y),l!==null&&(Sa(l,s,y,m),F2(l,s,y))},enqueueForceUpdate:function(s,l){s=s._reactInternals;var f=Mi(),m=Uc(s),y=Fs(f,m);y.tag=2,l!=null&&(y.callback=l),l=Fc(s,y,m),l!==null&&(Sa(l,s,m,f),F2(l,s,m))}};function k7(s,l,f,m,y,w,E){return s=s.stateNode,typeof s.shouldComponentUpdate=="function"?s.shouldComponentUpdate(m,w,E):l.prototype&&l.prototype.isPureReactComponent?!f1(f,m)||!f1(y,w):!0}function E7(s,l,f){var m=!1,y=Nc,w=l.contextType;return typeof w=="object"&&w!==null?w=Fo(w):(y=Ki(l)?od:di.current,m=l.contextTypes,w=(m=m!=null)?ch(s,y):Nc),l=new l(f,w),s.memoizedState=l.state!==null&&l.state!==void 0?l.state:null,l.updater=K2,s.stateNode=l,l._reactInternals=s,m&&(s=s.stateNode,s.__reactInternalMemoizedUnmaskedChildContext=y,s.__reactInternalMemoizedMaskedChildContext=w),l}function S7(s,l,f,m){s=l.state,typeof l.componentWillReceiveProps=="function"&&l.componentWillReceiveProps(f,m),typeof l.UNSAFE_componentWillReceiveProps=="function"&&l.UNSAFE_componentWillReceiveProps(f,m),l.state!==s&&K2.enqueueReplaceState(l,l.state,null)}function ny(s,l,f,m){var y=s.stateNode;y.props=f,y.state=s.memoizedState,y.refs={},z5(s);var w=l.contextType;typeof w=="object"&&w!==null?y.context=Fo(w):(w=Ki(l)?od:di.current,y.context=ch(s,w)),y.state=s.memoizedState,w=l.getDerivedStateFromProps,typeof w=="function"&&(ry(s,l,w,f),y.state=s.memoizedState),typeof l.getDerivedStateFromProps=="function"||typeof y.getSnapshotBeforeUpdate=="function"||typeof y.UNSAFE_componentWillMount!="function"&&typeof y.componentWillMount!="function"||(l=y.state,typeof y.componentWillMount=="function"&&y.componentWillMount(),typeof y.UNSAFE_componentWillMount=="function"&&y.UNSAFE_componentWillMount(),l!==y.state&&K2.enqueueReplaceState(y,y.state,null),j2(s,f,y,m),y.state=s.memoizedState),typeof y.componentDidMount=="function"&&(s.flags|=4194308)}function vh(s,l){try{var f="",m=l;do f+=Ie(m),m=m.return;while(m);var y=f}catch(w){y=`
39
39
  Error generating stack: `+w.message+`
40
- `+w.stack}return{value:s,source:l,stack:y,digest:null}}function iy(s,l,f){return{value:s,source:null,stack:f??null,digest:l??null}}function oy(s,l){try{console.error(l.value)}catch(f){setTimeout(function(){throw f})}}var ML=typeof WeakMap=="function"?WeakMap:Map;function T7(s,l,f){f=Fs(-1,f),f.tag=3,f.payload={element:null};var m=l.value;return f.callback=function(){r0||(r0=!0,by=m),oy(s,l)},f}function A7(s,l,f){f=Fs(-1,f),f.tag=3;var m=s.type.getDerivedStateFromError;if(typeof m=="function"){var y=l.value;f.payload=function(){return m(y)},f.callback=function(){oy(s,l)}}var w=s.stateNode;return w!==null&&typeof w.componentDidCatch=="function"&&(f.callback=function(){oy(s,l),typeof m!="function"&&(zc===null?zc=new Set([this]):zc.add(this));var E=l.stack;this.componentDidCatch(l.value,{componentStack:E!==null?E:""})}),f}function I7(s,l,f){var m=s.pingCache;if(m===null){m=s.pingCache=new ML;var y=new Set;m.set(l,y)}else y=m.get(l),y===void 0&&(y=new Set,m.set(l,y));y.has(f)||(y.add(f),s=qL.bind(null,s,l,f),l.then(s,s))}function R7(s){do{var l;if((l=s.tag===13)&&(l=s.memoizedState,l=l!==null?l.dehydrated!==null:!0),l)return s;s=s.return}while(s!==null);return null}function P7(s,l,f,m,y){return s.mode&1?(s.flags|=65536,s.lanes=y,s):(s===l?s.flags|=65536:(s.flags|=128,f.flags|=131072,f.flags&=-52805,f.tag===1&&(f.alternate===null?f.tag=17:(l=Fs(-1,1),l.tag=2,Fc(f,l,1))),f.lanes|=1),s)}var $L=Z.ReactCurrentOwner,Yi=!1;function Pi(s,l,f,m){l.child=s===null?Q9(l,null,f,m):hh(l,s.child,f,m)}function M7(s,l,f,m,y){f=f.render;var w=l.ref;return ph(l,y),m=Y5(s,l,f,m,w,y),f=Q5(),s!==null&&!Yi?(l.updateQueue=s.updateQueue,l.flags&=-2053,s.lanes&=~y,js(s,l,y)):(Vr&&f&&$5(l),l.flags|=1,Pi(s,l,m,y),l.child)}function $7(s,l,f,m,y){if(s===null){var w=f.type;return typeof w=="function"&&!Ty(w)&&w.defaultProps===void 0&&f.compare===null&&f.defaultProps===void 0?(l.tag=15,l.type=w,O7(s,l,w,m,y)):(s=c0(f.type,null,m,l,l.mode,y),s.ref=l.ref,s.return=l,l.child=s)}if(w=s.child,!(s.lanes&y)){var E=w.memoizedProps;if(f=f.compare,f=f!==null?f:f1,f(E,m)&&s.ref===l.ref)return js(s,l,y)}return l.flags|=1,s=Wc(w,m),s.ref=l.ref,s.return=l,l.child=s}function O7(s,l,f,m,y){if(s!==null){var w=s.memoizedProps;if(f1(w,m)&&s.ref===l.ref)if(Yi=!1,l.pendingProps=m=w,(s.lanes&y)!==0)s.flags&131072&&(Yi=!0);else return l.lanes=s.lanes,js(s,l,y)}return ay(s,l,f,m,y)}function Z7(s,l,f){var m=l.pendingProps,y=m.children,w=s!==null?s.memoizedState:null;if(m.mode==="hidden")if(!(l.mode&1))l.memoizedState={baseLanes:0,cachePool:null,transitions:null},Ir(yh,go),go|=f;else{if(!(f&1073741824))return s=w!==null?w.baseLanes|f:f,l.lanes=l.childLanes=1073741824,l.memoizedState={baseLanes:s,cachePool:null,transitions:null},l.updateQueue=null,Ir(yh,go),go|=s,null;l.memoizedState={baseLanes:0,cachePool:null,transitions:null},m=w!==null?w.baseLanes:f,Ir(yh,go),go|=m}else w!==null?(m=w.baseLanes|f,l.memoizedState=null):m=f,Ir(yh,go),go|=m;return Pi(s,l,y,f),l.child}function L7(s,l){var f=l.ref;(s===null&&f!==null||s!==null&&s.ref!==f)&&(l.flags|=512,l.flags|=2097152)}function ay(s,l,f,m,y){var w=Ki(f)?od:di.current;return w=ch(l,w),ph(l,y),f=Y5(s,l,f,m,w,y),m=Q5(),s!==null&&!Yi?(l.updateQueue=s.updateQueue,l.flags&=-2053,s.lanes&=~y,js(s,l,y)):(Vr&&m&&$5(l),l.flags|=1,Pi(s,l,f,y),l.child)}function H7(s,l,f,m,y){if(Ki(f)){var w=!0;$2(l)}else w=!1;if(ph(l,y),l.stateNode===null)Q2(s,l),E7(l,f,m),ny(l,f,m,y),m=!0;else if(s===null){var E=l.stateNode,L=l.memoizedProps;E.props=L;var V=E.context,ne=f.contextType;typeof ne=="object"&&ne!==null?ne=Fo(ne):(ne=Ki(f)?od:di.current,ne=ch(l,ne));var ge=f.getDerivedStateFromProps,_e=typeof ge=="function"||typeof E.getSnapshotBeforeUpdate=="function";_e||typeof E.UNSAFE_componentWillReceiveProps!="function"&&typeof E.componentWillReceiveProps!="function"||(L!==m||V!==ne)&&S7(l,E,m,ne),Vc=!1;var ve=l.memoizedState;E.state=ve,j2(l,m,E,y),V=l.memoizedState,L!==m||ve!==V||Gi.current||Vc?(typeof ge=="function"&&(ry(l,f,ge,m),V=l.memoizedState),(L=Vc||k7(l,f,L,m,ve,V,ne))?(_e||typeof E.UNSAFE_componentWillMount!="function"&&typeof E.componentWillMount!="function"||(typeof E.componentWillMount=="function"&&E.componentWillMount(),typeof E.UNSAFE_componentWillMount=="function"&&E.UNSAFE_componentWillMount()),typeof E.componentDidMount=="function"&&(l.flags|=4194308)):(typeof E.componentDidMount=="function"&&(l.flags|=4194308),l.memoizedProps=m,l.memoizedState=V),E.props=m,E.state=V,E.context=ne,m=L):(typeof E.componentDidMount=="function"&&(l.flags|=4194308),m=!1)}else{E=l.stateNode,J9(s,l),L=l.memoizedProps,ne=l.type===l.elementType?L:Ca(l.type,L),E.props=ne,_e=l.pendingProps,ve=E.context,V=f.contextType,typeof V=="object"&&V!==null?V=Fo(V):(V=Ki(f)?od:di.current,V=ch(l,V));var Fe=f.getDerivedStateFromProps;(ge=typeof Fe=="function"||typeof E.getSnapshotBeforeUpdate=="function")||typeof E.UNSAFE_componentWillReceiveProps!="function"&&typeof E.componentWillReceiveProps!="function"||(L!==_e||ve!==V)&&S7(l,E,m,V),Vc=!1,ve=l.memoizedState,E.state=ve,j2(l,m,E,y);var tt=l.memoizedState;L!==_e||ve!==tt||Gi.current||Vc?(typeof Fe=="function"&&(ry(l,f,Fe,m),tt=l.memoizedState),(ne=Vc||k7(l,f,ne,m,ve,tt,V)||!1)?(ge||typeof E.UNSAFE_componentWillUpdate!="function"&&typeof E.componentWillUpdate!="function"||(typeof E.componentWillUpdate=="function"&&E.componentWillUpdate(m,tt,V),typeof E.UNSAFE_componentWillUpdate=="function"&&E.UNSAFE_componentWillUpdate(m,tt,V)),typeof E.componentDidUpdate=="function"&&(l.flags|=4),typeof E.getSnapshotBeforeUpdate=="function"&&(l.flags|=1024)):(typeof E.componentDidUpdate!="function"||L===s.memoizedProps&&ve===s.memoizedState||(l.flags|=4),typeof E.getSnapshotBeforeUpdate!="function"||L===s.memoizedProps&&ve===s.memoizedState||(l.flags|=1024),l.memoizedProps=m,l.memoizedState=tt),E.props=m,E.state=tt,E.context=V,m=ne):(typeof E.componentDidUpdate!="function"||L===s.memoizedProps&&ve===s.memoizedState||(l.flags|=4),typeof E.getSnapshotBeforeUpdate!="function"||L===s.memoizedProps&&ve===s.memoizedState||(l.flags|=1024),m=!1)}return sy(s,l,f,m,w,y)}function sy(s,l,f,m,y,w){L7(s,l);var E=(l.flags&128)!==0;if(!m&&!E)return y&&j9(l,f,!1),js(s,l,w);m=l.stateNode,$L.current=l;var L=E&&typeof f.getDerivedStateFromError!="function"?null:m.render();return l.flags|=1,s!==null&&E?(l.child=hh(l,s.child,null,w),l.child=hh(l,null,L,w)):Pi(s,l,L,w),l.memoizedState=m.state,y&&j9(l,f,!0),l.child}function N7(s){var l=s.stateNode;l.pendingContext?V9(s,l.pendingContext,l.pendingContext!==l.context):l.context&&V9(s,l.context,!1),B5(s,l.containerInfo)}function D7(s,l,f,m,y){return uh(),H5(y),l.flags|=256,Pi(s,l,f,m),l.child}var cy={dehydrated:null,treeContext:null,retryLane:0};function ly(s){return{baseLanes:s,cachePool:null,transitions:null}}function V7(s,l,f){var m=l.pendingProps,y=Gr.current,w=!1,E=(l.flags&128)!==0,L;if((L=E)||(L=s!==null&&s.memoizedState===null?!1:(y&2)!==0),L?(w=!0,l.flags&=-129):(s===null||s.memoizedState!==null)&&(y|=1),Ir(Gr,y&1),s===null)return L5(l),s=l.memoizedState,s!==null&&(s=s.dehydrated,s!==null)?(l.mode&1?s.data==="$!"?l.lanes=8:l.lanes=1073741824:l.lanes=1,null):(E=m.children,s=m.fallback,w?(m=l.mode,w=l.child,E={mode:"hidden",children:E},!(m&1)&&w!==null?(w.childLanes=0,w.pendingProps=E):w=l0(E,m,0,null),s=md(s,m,f,null),w.return=l,s.return=l,w.sibling=s,l.child=w,l.child.memoizedState=ly(f),l.memoizedState=cy,s):dy(l,E));if(y=s.memoizedState,y!==null&&(L=y.dehydrated,L!==null))return OL(s,l,E,m,L,y,f);if(w){w=m.fallback,E=l.mode,y=s.child,L=y.sibling;var V={mode:"hidden",children:m.children};return!(E&1)&&l.child!==y?(m=l.child,m.childLanes=0,m.pendingProps=V,l.deletions=null):(m=Wc(y,V),m.subtreeFlags=y.subtreeFlags&14680064),L!==null?w=Wc(L,w):(w=md(w,E,f,null),w.flags|=2),w.return=l,m.return=l,m.sibling=w,l.child=m,m=w,w=l.child,E=s.child.memoizedState,E=E===null?ly(f):{baseLanes:E.baseLanes|f,cachePool:null,transitions:E.transitions},w.memoizedState=E,w.childLanes=s.childLanes&~f,l.memoizedState=cy,m}return w=s.child,s=w.sibling,m=Wc(w,{mode:"visible",children:m.children}),!(l.mode&1)&&(m.lanes=f),m.return=l,m.sibling=null,s!==null&&(f=l.deletions,f===null?(l.deletions=[s],l.flags|=16):f.push(s)),l.child=m,l.memoizedState=null,m}function dy(s,l){return l=l0({mode:"visible",children:l},s.mode,0,null),l.return=s,s.child=l}function Y2(s,l,f,m){return m!==null&&H5(m),hh(l,s.child,null,f),s=dy(l,l.pendingProps.children),s.flags|=2,l.memoizedState=null,s}function OL(s,l,f,m,y,w,E){if(f)return l.flags&256?(l.flags&=-257,m=iy(Error(t(422))),Y2(s,l,E,m)):l.memoizedState!==null?(l.child=s.child,l.flags|=128,null):(w=m.fallback,y=l.mode,m=l0({mode:"visible",children:m.children},y,0,null),w=md(w,y,E,null),w.flags|=2,m.return=l,w.return=l,m.sibling=w,l.child=m,l.mode&1&&hh(l,s.child,null,E),l.child.memoizedState=ly(E),l.memoizedState=cy,w);if(!(l.mode&1))return Y2(s,l,E,null);if(y.data==="$!"){if(m=y.nextSibling&&y.nextSibling.dataset,m)var L=m.dgst;return m=L,w=Error(t(419)),m=iy(w,m,void 0),Y2(s,l,E,m)}if(L=(E&s.childLanes)!==0,Yi||L){if(m=Hn,m!==null){switch(E&-E){case 4:y=2;break;case 16:y=8;break;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:y=32;break;case 536870912:y=268435456;break;default:y=0}y=y&(m.suspendedLanes|E)?0:y,y!==0&&y!==w.retryLane&&(w.retryLane=y,Vs(s,y),Sa(m,s,y,-1))}return Sy(),m=iy(Error(t(421))),Y2(s,l,E,m)}return y.data==="$?"?(l.flags|=128,l.child=s.child,l=WL.bind(null,s),y._reactRetry=l,null):(s=w.treeContext,vo=Lc(y.nextSibling),mo=l,Vr=!0,xa=null,s!==null&&(Do[Vo++]=Ns,Do[Vo++]=Ds,Do[Vo++]=ad,Ns=s.id,Ds=s.overflow,ad=l),l=dy(l,m.children),l.flags|=4096,l)}function F7(s,l,f){s.lanes|=l;var m=s.alternate;m!==null&&(m.lanes|=l),F5(s.return,l,f)}function uy(s,l,f,m,y){var w=s.memoizedState;w===null?s.memoizedState={isBackwards:l,rendering:null,renderingStartTime:0,last:m,tail:f,tailMode:y}:(w.isBackwards=l,w.rendering=null,w.renderingStartTime=0,w.last=m,w.tail=f,w.tailMode=y)}function j7(s,l,f){var m=l.pendingProps,y=m.revealOrder,w=m.tail;if(Pi(s,l,m.children,f),m=Gr.current,m&2)m=m&1|2,l.flags|=128;else{if(s!==null&&s.flags&128)e:for(s=l.child;s!==null;){if(s.tag===13)s.memoizedState!==null&&F7(s,f,l);else if(s.tag===19)F7(s,f,l);else if(s.child!==null){s.child.return=s,s=s.child;continue}if(s===l)break e;for(;s.sibling===null;){if(s.return===null||s.return===l)break e;s=s.return}s.sibling.return=s.return,s=s.sibling}m&=1}if(Ir(Gr,m),!(l.mode&1))l.memoizedState=null;else switch(y){case"forwards":for(f=l.child,y=null;f!==null;)s=f.alternate,s!==null&&z2(s)===null&&(y=f),f=f.sibling;f=y,f===null?(y=l.child,l.child=null):(y=f.sibling,f.sibling=null),uy(l,!1,y,f,w);break;case"backwards":for(f=null,y=l.child,l.child=null;y!==null;){if(s=y.alternate,s!==null&&z2(s)===null){l.child=y;break}s=y.sibling,y.sibling=f,f=y,y=s}uy(l,!0,f,null,w);break;case"together":uy(l,!1,null,null,void 0);break;default:l.memoizedState=null}return l.child}function Q2(s,l){!(l.mode&1)&&s!==null&&(s.alternate=null,l.alternate=null,l.flags|=2)}function js(s,l,f){if(s!==null&&(l.dependencies=s.dependencies),ud|=l.lanes,!(f&l.childLanes))return null;if(s!==null&&l.child!==s.child)throw Error(t(153));if(l.child!==null){for(s=l.child,f=Wc(s,s.pendingProps),l.child=f,f.return=l;s.sibling!==null;)s=s.sibling,f=f.sibling=Wc(s,s.pendingProps),f.return=l;f.sibling=null}return l.child}function ZL(s,l,f){switch(l.tag){case 3:N7(l),uh();break;case 5:r7(l);break;case 1:Ki(l.type)&&$2(l);break;case 4:B5(l,l.stateNode.containerInfo);break;case 10:var m=l.type._context,y=l.memoizedProps.value;Ir(D2,m._currentValue),m._currentValue=y;break;case 13:if(m=l.memoizedState,m!==null)return m.dehydrated!==null?(Ir(Gr,Gr.current&1),l.flags|=128,null):f&l.child.childLanes?V7(s,l,f):(Ir(Gr,Gr.current&1),s=js(s,l,f),s!==null?s.sibling:null);Ir(Gr,Gr.current&1);break;case 19:if(m=(f&l.childLanes)!==0,s.flags&128){if(m)return j7(s,l,f);l.flags|=128}if(y=l.memoizedState,y!==null&&(y.rendering=null,y.tail=null,y.lastEffect=null),Ir(Gr,Gr.current),m)break;return null;case 22:case 23:return l.lanes=0,Z7(s,l,f)}return js(s,l,f)}var z7,hy,B7,U7;z7=function(s,l){for(var f=l.child;f!==null;){if(f.tag===5||f.tag===6)s.appendChild(f.stateNode);else if(f.tag!==4&&f.child!==null){f.child.return=f,f=f.child;continue}if(f===l)break;for(;f.sibling===null;){if(f.return===null||f.return===l)return;f=f.return}f.sibling.return=f.return,f=f.sibling}},hy=function(){},B7=function(s,l,f,m){var y=s.memoizedProps;if(y!==m){s=l.stateNode,ld(Xa.current);var w=null;switch(f){case"input":y=co(s,y),m=co(s,m),w=[];break;case"select":y=H({},y,{value:void 0}),m=H({},m,{value:void 0}),w=[];break;case"textarea":y=Ac(s,y),m=Ac(s,m),w=[];break;default:typeof y.onClick!="function"&&typeof m.onClick=="function"&&(s.onclick=R2)}Rc(f,m);var E;f=null;for(ne in y)if(!m.hasOwnProperty(ne)&&y.hasOwnProperty(ne)&&y[ne]!=null)if(ne==="style"){var L=y[ne];for(E in L)L.hasOwnProperty(E)&&(f||(f={}),f[E]="")}else ne!=="dangerouslySetInnerHTML"&&ne!=="children"&&ne!=="suppressContentEditableWarning"&&ne!=="suppressHydrationWarning"&&ne!=="autoFocus"&&(i.hasOwnProperty(ne)?w||(w=[]):(w=w||[]).push(ne,null));for(ne in m){var V=m[ne];if(L=y!=null?y[ne]:void 0,m.hasOwnProperty(ne)&&V!==L&&(V!=null||L!=null))if(ne==="style")if(L){for(E in L)!L.hasOwnProperty(E)||V&&V.hasOwnProperty(E)||(f||(f={}),f[E]="");for(E in V)V.hasOwnProperty(E)&&L[E]!==V[E]&&(f||(f={}),f[E]=V[E])}else f||(w||(w=[]),w.push(ne,f)),f=V;else ne==="dangerouslySetInnerHTML"?(V=V?V.__html:void 0,L=L?L.__html:void 0,V!=null&&L!==V&&(w=w||[]).push(ne,V)):ne==="children"?typeof V!="string"&&typeof V!="number"||(w=w||[]).push(ne,""+V):ne!=="suppressContentEditableWarning"&&ne!=="suppressHydrationWarning"&&(i.hasOwnProperty(ne)?(V!=null&&ne==="onScroll"&&Zr("scroll",s),w||L===V||(w=[])):(w=w||[]).push(ne,V))}f&&(w=w||[]).push("style",f);var ne=w;(l.updateQueue=ne)&&(l.flags|=4)}},U7=function(s,l,f,m){f!==m&&(l.flags|=4)};function A1(s,l){if(!Vr)switch(s.tailMode){case"hidden":l=s.tail;for(var f=null;l!==null;)l.alternate!==null&&(f=l),l=l.sibling;f===null?s.tail=null:f.sibling=null;break;case"collapsed":f=s.tail;for(var m=null;f!==null;)f.alternate!==null&&(m=f),f=f.sibling;m===null?l||s.tail===null?s.tail=null:s.tail.sibling=null:m.sibling=null}}function hi(s){var l=s.alternate!==null&&s.alternate.child===s.child,f=0,m=0;if(l)for(var y=s.child;y!==null;)f|=y.lanes|y.childLanes,m|=y.subtreeFlags&14680064,m|=y.flags&14680064,y.return=s,y=y.sibling;else for(y=s.child;y!==null;)f|=y.lanes|y.childLanes,m|=y.subtreeFlags,m|=y.flags,y.return=s,y=y.sibling;return s.subtreeFlags|=m,s.childLanes=f,l}function LL(s,l,f){var m=l.pendingProps;switch(O5(l),l.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return hi(l),null;case 1:return Ki(l.type)&&M2(),hi(l),null;case 3:return m=l.stateNode,mh(),Lr(Gi),Lr(di),W5(),m.pendingContext&&(m.context=m.pendingContext,m.pendingContext=null),(s===null||s.child===null)&&(H2(l)?l.flags|=4:s===null||s.memoizedState.isDehydrated&&!(l.flags&256)||(l.flags|=1024,xa!==null&&(Cy(xa),xa=null))),hy(s,l),hi(l),null;case 5:U5(l);var y=ld(C1.current);if(f=l.type,s!==null&&l.stateNode!=null)B7(s,l,f,m,y),s.ref!==l.ref&&(l.flags|=512,l.flags|=2097152);else{if(!m){if(l.stateNode===null)throw Error(t(166));return hi(l),null}if(s=ld(Xa.current),H2(l)){m=l.stateNode,f=l.type;var w=l.memoizedProps;switch(m[Qa]=l,m[y1]=w,s=(l.mode&1)!==0,f){case"dialog":Zr("cancel",m),Zr("close",m);break;case"iframe":case"object":case"embed":Zr("load",m);break;case"video":case"audio":for(y=0;y<m1.length;y++)Zr(m1[y],m);break;case"source":Zr("error",m);break;case"img":case"image":case"link":Zr("error",m),Zr("load",m);break;case"details":Zr("toggle",m);break;case"input":ma(m,w),Zr("invalid",m);break;case"select":m._wrapperState={wasMultiple:!!w.multiple},Zr("invalid",m);break;case"textarea":zl(m,w),Zr("invalid",m)}Rc(f,w),y=null;for(var E in w)if(w.hasOwnProperty(E)){var L=w[E];E==="children"?typeof L=="string"?m.textContent!==L&&(w.suppressHydrationWarning!==!0&&I2(m.textContent,L,s),y=["children",L]):typeof L=="number"&&m.textContent!==""+L&&(w.suppressHydrationWarning!==!0&&I2(m.textContent,L,s),y=["children",""+L]):i.hasOwnProperty(E)&&L!=null&&E==="onScroll"&&Zr("scroll",m)}switch(f){case"input":Wr(m),Uu(m,w,!0);break;case"textarea":Wr(m),lo(m);break;case"select":case"option":break;default:typeof w.onClick=="function"&&(m.onclick=R2)}m=y,l.updateQueue=m,m!==null&&(l.flags|=4)}else{E=y.nodeType===9?y:y.ownerDocument,s==="http://www.w3.org/1999/xhtml"&&(s=Bl(f)),s==="http://www.w3.org/1999/xhtml"?f==="script"?(s=E.createElement("div"),s.innerHTML="<script><\/script>",s=s.removeChild(s.firstChild)):typeof m.is=="string"?s=E.createElement(f,{is:m.is}):(s=E.createElement(f),f==="select"&&(E=s,m.multiple?E.multiple=!0:m.size&&(E.size=m.size))):s=E.createElementNS(s,f),s[Qa]=l,s[y1]=m,z7(s,l,!1,!1),l.stateNode=s;e:{switch(E=Ps(f,m),f){case"dialog":Zr("cancel",s),Zr("close",s),y=m;break;case"iframe":case"object":case"embed":Zr("load",s),y=m;break;case"video":case"audio":for(y=0;y<m1.length;y++)Zr(m1[y],s);y=m;break;case"source":Zr("error",s),y=m;break;case"img":case"image":case"link":Zr("error",s),Zr("load",s),y=m;break;case"details":Zr("toggle",s),y=m;break;case"input":ma(s,m),y=co(s,m),Zr("invalid",s);break;case"option":y=m;break;case"select":s._wrapperState={wasMultiple:!!m.multiple},y=H({},m,{value:void 0}),Zr("invalid",s);break;case"textarea":zl(s,m),y=Ac(s,m),Zr("invalid",s);break;default:y=m}Rc(f,y),L=y;for(w in L)if(L.hasOwnProperty(w)){var V=L[w];w==="style"?Ic(s,V):w==="dangerouslySetInnerHTML"?(V=V?V.__html:void 0,V!=null&&Ii(s,V)):w==="children"?typeof V=="string"?(f!=="textarea"||V!=="")&&Ua(s,V):typeof V=="number"&&Ua(s,""+V):w!=="suppressContentEditableWarning"&&w!=="suppressHydrationWarning"&&w!=="autoFocus"&&(i.hasOwnProperty(w)?V!=null&&w==="onScroll"&&Zr("scroll",s):V!=null&&A(s,w,V,E))}switch(f){case"input":Wr(s),Uu(s,m,!1);break;case"textarea":Wr(s),lo(s);break;case"option":m.value!=null&&s.setAttribute("value",""+ot(m.value));break;case"select":s.multiple=!!m.multiple,w=m.value,w!=null?Mo(s,!!m.multiple,w,!1):m.defaultValue!=null&&Mo(s,!!m.multiple,m.defaultValue,!0);break;default:typeof y.onClick=="function"&&(s.onclick=R2)}switch(f){case"button":case"input":case"select":case"textarea":m=!!m.autoFocus;break e;case"img":m=!0;break e;default:m=!1}}m&&(l.flags|=4)}l.ref!==null&&(l.flags|=512,l.flags|=2097152)}return hi(l),null;case 6:if(s&&l.stateNode!=null)U7(s,l,s.memoizedProps,m);else{if(typeof m!="string"&&l.stateNode===null)throw Error(t(166));if(f=ld(C1.current),ld(Xa.current),H2(l)){if(m=l.stateNode,f=l.memoizedProps,m[Qa]=l,(w=m.nodeValue!==f)&&(s=mo,s!==null))switch(s.tag){case 3:I2(m.nodeValue,f,(s.mode&1)!==0);break;case 5:s.memoizedProps.suppressHydrationWarning!==!0&&I2(m.nodeValue,f,(s.mode&1)!==0)}w&&(l.flags|=4)}else m=(f.nodeType===9?f:f.ownerDocument).createTextNode(m),m[Qa]=l,l.stateNode=m}return hi(l),null;case 13:if(Lr(Gr),m=l.memoizedState,s===null||s.memoizedState!==null&&s.memoizedState.dehydrated!==null){if(Vr&&vo!==null&&l.mode&1&&!(l.flags&128))G9(),uh(),l.flags|=98560,w=!1;else if(w=H2(l),m!==null&&m.dehydrated!==null){if(s===null){if(!w)throw Error(t(318));if(w=l.memoizedState,w=w!==null?w.dehydrated:null,!w)throw Error(t(317));w[Qa]=l}else uh(),!(l.flags&128)&&(l.memoizedState=null),l.flags|=4;hi(l),w=!1}else xa!==null&&(Cy(xa),xa=null),w=!0;if(!w)return l.flags&65536?l:null}return l.flags&128?(l.lanes=f,l):(m=m!==null,m!==(s!==null&&s.memoizedState!==null)&&m&&(l.child.flags|=8192,l.mode&1&&(s===null||Gr.current&1?Mn===0&&(Mn=3):Sy())),l.updateQueue!==null&&(l.flags|=4),hi(l),null);case 4:return mh(),hy(s,l),s===null&&v1(l.stateNode.containerInfo),hi(l),null;case 10:return V5(l.type._context),hi(l),null;case 17:return Ki(l.type)&&M2(),hi(l),null;case 19:if(Lr(Gr),w=l.memoizedState,w===null)return hi(l),null;if(m=(l.flags&128)!==0,E=w.rendering,E===null)if(m)A1(w,!1);else{if(Mn!==0||s!==null&&s.flags&128)for(s=l.child;s!==null;){if(E=z2(s),E!==null){for(l.flags|=128,A1(w,!1),m=E.updateQueue,m!==null&&(l.updateQueue=m,l.flags|=4),l.subtreeFlags=0,m=f,f=l.child;f!==null;)w=f,s=m,w.flags&=14680066,E=w.alternate,E===null?(w.childLanes=0,w.lanes=s,w.child=null,w.subtreeFlags=0,w.memoizedProps=null,w.memoizedState=null,w.updateQueue=null,w.dependencies=null,w.stateNode=null):(w.childLanes=E.childLanes,w.lanes=E.lanes,w.child=E.child,w.subtreeFlags=0,w.deletions=null,w.memoizedProps=E.memoizedProps,w.memoizedState=E.memoizedState,w.updateQueue=E.updateQueue,w.type=E.type,s=E.dependencies,w.dependencies=s===null?null:{lanes:s.lanes,firstContext:s.firstContext}),f=f.sibling;return Ir(Gr,Gr.current&1|2),l.child}s=s.sibling}w.tail!==null&&Kt()>_h&&(l.flags|=128,m=!0,A1(w,!1),l.lanes=4194304)}else{if(!m)if(s=z2(E),s!==null){if(l.flags|=128,m=!0,f=s.updateQueue,f!==null&&(l.updateQueue=f,l.flags|=4),A1(w,!0),w.tail===null&&w.tailMode==="hidden"&&!E.alternate&&!Vr)return hi(l),null}else 2*Kt()-w.renderingStartTime>_h&&f!==1073741824&&(l.flags|=128,m=!0,A1(w,!1),l.lanes=4194304);w.isBackwards?(E.sibling=l.child,l.child=E):(f=w.last,f!==null?f.sibling=E:l.child=E,w.last=E)}return w.tail!==null?(l=w.tail,w.rendering=l,w.tail=l.sibling,w.renderingStartTime=Kt(),l.sibling=null,f=Gr.current,Ir(Gr,m?f&1|2:f&1),l):(hi(l),null);case 22:case 23:return Ey(),m=l.memoizedState!==null,s!==null&&s.memoizedState!==null!==m&&(l.flags|=8192),m&&l.mode&1?go&1073741824&&(hi(l),l.subtreeFlags&6&&(l.flags|=8192)):hi(l),null;case 24:return null;case 25:return null}throw Error(t(156,l.tag))}function HL(s,l){switch(O5(l),l.tag){case 1:return Ki(l.type)&&M2(),s=l.flags,s&65536?(l.flags=s&-65537|128,l):null;case 3:return mh(),Lr(Gi),Lr(di),W5(),s=l.flags,s&65536&&!(s&128)?(l.flags=s&-65537|128,l):null;case 5:return U5(l),null;case 13:if(Lr(Gr),s=l.memoizedState,s!==null&&s.dehydrated!==null){if(l.alternate===null)throw Error(t(340));uh()}return s=l.flags,s&65536?(l.flags=s&-65537|128,l):null;case 19:return Lr(Gr),null;case 4:return mh(),null;case 10:return V5(l.type._context),null;case 22:case 23:return Ey(),null;case 24:return null;default:return null}}var X2=!1,fi=!1,NL=typeof WeakSet=="function"?WeakSet:Set,Qe=null;function gh(s,l){var f=s.ref;if(f!==null)if(typeof f=="function")try{f(null)}catch(m){cn(s,l,m)}else f.current=null}function fy(s,l,f){try{f()}catch(m){cn(s,l,m)}}var q7=!1;function DL(s,l){if(E5=te,s=k9(),g5(s)){if("selectionStart"in s)var f={start:s.selectionStart,end:s.selectionEnd};else e:{f=(f=s.ownerDocument)&&f.defaultView||window;var m=f.getSelection&&f.getSelection();if(m&&m.rangeCount!==0){f=m.anchorNode;var y=m.anchorOffset,w=m.focusNode;m=m.focusOffset;try{f.nodeType,w.nodeType}catch{f=null;break e}var E=0,L=-1,V=-1,ne=0,ge=0,_e=s,ve=null;t:for(;;){for(var Fe;_e!==f||y!==0&&_e.nodeType!==3||(L=E+y),_e!==w||m!==0&&_e.nodeType!==3||(V=E+m),_e.nodeType===3&&(E+=_e.nodeValue.length),(Fe=_e.firstChild)!==null;)ve=_e,_e=Fe;for(;;){if(_e===s)break t;if(ve===f&&++ne===y&&(L=E),ve===w&&++ge===m&&(V=E),(Fe=_e.nextSibling)!==null)break;_e=ve,ve=_e.parentNode}_e=Fe}f=L===-1||V===-1?null:{start:L,end:V}}else f=null}f=f||{start:0,end:0}}else f=null;for(S5={focusedElem:s,selectionRange:f},te=!1,Qe=l;Qe!==null;)if(l=Qe,s=l.child,(l.subtreeFlags&1028)!==0&&s!==null)s.return=l,Qe=s;else for(;Qe!==null;){l=Qe;try{var tt=l.alternate;if(l.flags&1024)switch(l.tag){case 0:case 11:case 15:break;case 1:if(tt!==null){var nt=tt.memoizedProps,gn=tt.memoizedState,X=l.stateNode,W=X.getSnapshotBeforeUpdate(l.elementType===l.type?nt:Ca(l.type,nt),gn);X.__reactInternalSnapshotBeforeUpdate=W}break;case 3:var ee=l.stateNode.containerInfo;ee.nodeType===1?ee.textContent="":ee.nodeType===9&&ee.documentElement&&ee.removeChild(ee.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(t(163))}}catch(Se){cn(l,l.return,Se)}if(s=l.sibling,s!==null){s.return=l.return,Qe=s;break}Qe=l.return}return tt=q7,q7=!1,tt}function I1(s,l,f){var m=l.updateQueue;if(m=m!==null?m.lastEffect:null,m!==null){var y=m=m.next;do{if((y.tag&s)===s){var w=y.destroy;y.destroy=void 0,w!==void 0&&fy(l,f,w)}y=y.next}while(y!==m)}}function J2(s,l){if(l=l.updateQueue,l=l!==null?l.lastEffect:null,l!==null){var f=l=l.next;do{if((f.tag&s)===s){var m=f.create;f.destroy=m()}f=f.next}while(f!==l)}}function py(s){var l=s.ref;if(l!==null){var f=s.stateNode;switch(s.tag){case 5:s=f;break;default:s=f}typeof l=="function"?l(s):l.current=s}}function W7(s){var l=s.alternate;l!==null&&(s.alternate=null,W7(l)),s.child=null,s.deletions=null,s.sibling=null,s.tag===5&&(l=s.stateNode,l!==null&&(delete l[Qa],delete l[y1],delete l[R5],delete l[wL],delete l[xL])),s.stateNode=null,s.return=null,s.dependencies=null,s.memoizedProps=null,s.memoizedState=null,s.pendingProps=null,s.stateNode=null,s.updateQueue=null}function G7(s){return s.tag===5||s.tag===3||s.tag===4}function K7(s){e:for(;;){for(;s.sibling===null;){if(s.return===null||G7(s.return))return null;s=s.return}for(s.sibling.return=s.return,s=s.sibling;s.tag!==5&&s.tag!==6&&s.tag!==18;){if(s.flags&2||s.child===null||s.tag===4)continue e;s.child.return=s,s=s.child}if(!(s.flags&2))return s.stateNode}}function my(s,l,f){var m=s.tag;if(m===5||m===6)s=s.stateNode,l?f.nodeType===8?f.parentNode.insertBefore(s,l):f.insertBefore(s,l):(f.nodeType===8?(l=f.parentNode,l.insertBefore(s,f)):(l=f,l.appendChild(s)),f=f._reactRootContainer,f!=null||l.onclick!==null||(l.onclick=R2));else if(m!==4&&(s=s.child,s!==null))for(my(s,l,f),s=s.sibling;s!==null;)my(s,l,f),s=s.sibling}function vy(s,l,f){var m=s.tag;if(m===5||m===6)s=s.stateNode,l?f.insertBefore(s,l):f.appendChild(s);else if(m!==4&&(s=s.child,s!==null))for(vy(s,l,f),s=s.sibling;s!==null;)vy(s,l,f),s=s.sibling}var Wn=null,ka=!1;function jc(s,l,f){for(f=f.child;f!==null;)Y7(s,l,f),f=f.sibling}function Y7(s,l,f){if(In&&typeof In.onCommitFiberUnmount=="function")try{In.onCommitFiberUnmount(sr,f)}catch{}switch(f.tag){case 5:fi||gh(f,l);case 6:var m=Wn,y=ka;Wn=null,jc(s,l,f),Wn=m,ka=y,Wn!==null&&(ka?(s=Wn,f=f.stateNode,s.nodeType===8?s.parentNode.removeChild(f):s.removeChild(f)):Wn.removeChild(f.stateNode));break;case 18:Wn!==null&&(ka?(s=Wn,f=f.stateNode,s.nodeType===8?I5(s.parentNode,f):s.nodeType===1&&I5(s,f),ed(s)):I5(Wn,f.stateNode));break;case 4:m=Wn,y=ka,Wn=f.stateNode.containerInfo,ka=!0,jc(s,l,f),Wn=m,ka=y;break;case 0:case 11:case 14:case 15:if(!fi&&(m=f.updateQueue,m!==null&&(m=m.lastEffect,m!==null))){y=m=m.next;do{var w=y,E=w.destroy;w=w.tag,E!==void 0&&(w&2||w&4)&&fy(f,l,E),y=y.next}while(y!==m)}jc(s,l,f);break;case 1:if(!fi&&(gh(f,l),m=f.stateNode,typeof m.componentWillUnmount=="function"))try{m.props=f.memoizedProps,m.state=f.memoizedState,m.componentWillUnmount()}catch(L){cn(f,l,L)}jc(s,l,f);break;case 21:jc(s,l,f);break;case 22:f.mode&1?(fi=(m=fi)||f.memoizedState!==null,jc(s,l,f),fi=m):jc(s,l,f);break;default:jc(s,l,f)}}function Q7(s){var l=s.updateQueue;if(l!==null){s.updateQueue=null;var f=s.stateNode;f===null&&(f=s.stateNode=new NL),l.forEach(function(m){var y=GL.bind(null,s,m);f.has(m)||(f.add(m),m.then(y,y))})}}function Ea(s,l){var f=l.deletions;if(f!==null)for(var m=0;m<f.length;m++){var y=f[m];try{var w=s,E=l,L=E;e:for(;L!==null;){switch(L.tag){case 5:Wn=L.stateNode,ka=!1;break e;case 3:Wn=L.stateNode.containerInfo,ka=!0;break e;case 4:Wn=L.stateNode.containerInfo,ka=!0;break e}L=L.return}if(Wn===null)throw Error(t(160));Y7(w,E,y),Wn=null,ka=!1;var V=y.alternate;V!==null&&(V.return=null),y.return=null}catch(ne){cn(y,l,ne)}}if(l.subtreeFlags&12854)for(l=l.child;l!==null;)X7(l,s),l=l.sibling}function X7(s,l){var f=s.alternate,m=s.flags;switch(s.tag){case 0:case 11:case 14:case 15:if(Ea(l,s),es(s),m&4){try{I1(3,s,s.return),J2(3,s)}catch(nt){cn(s,s.return,nt)}try{I1(5,s,s.return)}catch(nt){cn(s,s.return,nt)}}break;case 1:Ea(l,s),es(s),m&512&&f!==null&&gh(f,f.return);break;case 5:if(Ea(l,s),es(s),m&512&&f!==null&&gh(f,f.return),s.flags&32){var y=s.stateNode;try{Ua(y,"")}catch(nt){cn(s,s.return,nt)}}if(m&4&&(y=s.stateNode,y!=null)){var w=s.memoizedProps,E=f!==null?f.memoizedProps:w,L=s.type,V=s.updateQueue;if(s.updateQueue=null,V!==null)try{L==="input"&&w.type==="radio"&&w.name!=null&&qi(y,w),Ps(L,E);var ne=Ps(L,w);for(E=0;E<V.length;E+=2){var ge=V[E],_e=V[E+1];ge==="style"?Ic(y,_e):ge==="dangerouslySetInnerHTML"?Ii(y,_e):ge==="children"?Ua(y,_e):A(y,ge,_e,ne)}switch(L){case"input":Sc(y,w);break;case"textarea":An(y,w);break;case"select":var ve=y._wrapperState.wasMultiple;y._wrapperState.wasMultiple=!!w.multiple;var Fe=w.value;Fe!=null?Mo(y,!!w.multiple,Fe,!1):ve!==!!w.multiple&&(w.defaultValue!=null?Mo(y,!!w.multiple,w.defaultValue,!0):Mo(y,!!w.multiple,w.multiple?[]:"",!1))}y[y1]=w}catch(nt){cn(s,s.return,nt)}}break;case 6:if(Ea(l,s),es(s),m&4){if(s.stateNode===null)throw Error(t(162));y=s.stateNode,w=s.memoizedProps;try{y.nodeValue=w}catch(nt){cn(s,s.return,nt)}}break;case 3:if(Ea(l,s),es(s),m&4&&f!==null&&f.memoizedState.isDehydrated)try{ed(l.containerInfo)}catch(nt){cn(s,s.return,nt)}break;case 4:Ea(l,s),es(s);break;case 13:Ea(l,s),es(s),y=s.child,y.flags&8192&&(w=y.memoizedState!==null,y.stateNode.isHidden=w,!w||y.alternate!==null&&y.alternate.memoizedState!==null||(_y=Kt())),m&4&&Q7(s);break;case 22:if(ge=f!==null&&f.memoizedState!==null,s.mode&1?(fi=(ne=fi)||ge,Ea(l,s),fi=ne):Ea(l,s),es(s),m&8192){if(ne=s.memoizedState!==null,(s.stateNode.isHidden=ne)&&!ge&&s.mode&1)for(Qe=s,ge=s.child;ge!==null;){for(_e=Qe=ge;Qe!==null;){switch(ve=Qe,Fe=ve.child,ve.tag){case 0:case 11:case 14:case 15:I1(4,ve,ve.return);break;case 1:gh(ve,ve.return);var tt=ve.stateNode;if(typeof tt.componentWillUnmount=="function"){m=ve,f=ve.return;try{l=m,tt.props=l.memoizedProps,tt.state=l.memoizedState,tt.componentWillUnmount()}catch(nt){cn(m,f,nt)}}break;case 5:gh(ve,ve.return);break;case 22:if(ve.memoizedState!==null){tx(_e);continue}}Fe!==null?(Fe.return=ve,Qe=Fe):tx(_e)}ge=ge.sibling}e:for(ge=null,_e=s;;){if(_e.tag===5){if(ge===null){ge=_e;try{y=_e.stateNode,ne?(w=y.style,typeof w.setProperty=="function"?w.setProperty("display","none","important"):w.display="none"):(L=_e.stateNode,V=_e.memoizedProps.style,E=V!=null&&V.hasOwnProperty("display")?V.display:null,L.style.display=uo("display",E))}catch(nt){cn(s,s.return,nt)}}}else if(_e.tag===6){if(ge===null)try{_e.stateNode.nodeValue=ne?"":_e.memoizedProps}catch(nt){cn(s,s.return,nt)}}else if((_e.tag!==22&&_e.tag!==23||_e.memoizedState===null||_e===s)&&_e.child!==null){_e.child.return=_e,_e=_e.child;continue}if(_e===s)break e;for(;_e.sibling===null;){if(_e.return===null||_e.return===s)break e;ge===_e&&(ge=null),_e=_e.return}ge===_e&&(ge=null),_e.sibling.return=_e.return,_e=_e.sibling}}break;case 19:Ea(l,s),es(s),m&4&&Q7(s);break;case 21:break;default:Ea(l,s),es(s)}}function es(s){var l=s.flags;if(l&2){try{e:{for(var f=s.return;f!==null;){if(G7(f)){var m=f;break e}f=f.return}throw Error(t(160))}switch(m.tag){case 5:var y=m.stateNode;m.flags&32&&(Ua(y,""),m.flags&=-33);var w=K7(s);vy(s,w,y);break;case 3:case 4:var E=m.stateNode.containerInfo,L=K7(s);my(s,L,E);break;default:throw Error(t(161))}}catch(V){cn(s,s.return,V)}s.flags&=-3}l&4096&&(s.flags&=-4097)}function VL(s,l,f){Qe=s,J7(s)}function J7(s,l,f){for(var m=(s.mode&1)!==0;Qe!==null;){var y=Qe,w=y.child;if(y.tag===22&&m){var E=y.memoizedState!==null||X2;if(!E){var L=y.alternate,V=L!==null&&L.memoizedState!==null||fi;L=X2;var ne=fi;if(X2=E,(fi=V)&&!ne)for(Qe=y;Qe!==null;)E=Qe,V=E.child,E.tag===22&&E.memoizedState!==null?rx(y):V!==null?(V.return=E,Qe=V):rx(y);for(;w!==null;)Qe=w,J7(w),w=w.sibling;Qe=y,X2=L,fi=ne}ex(s)}else y.subtreeFlags&8772&&w!==null?(w.return=y,Qe=w):ex(s)}}function ex(s){for(;Qe!==null;){var l=Qe;if(l.flags&8772){var f=l.alternate;try{if(l.flags&8772)switch(l.tag){case 0:case 11:case 15:fi||J2(5,l);break;case 1:var m=l.stateNode;if(l.flags&4&&!fi)if(f===null)m.componentDidMount();else{var y=l.elementType===l.type?f.memoizedProps:Ca(l.type,f.memoizedProps);m.componentDidUpdate(y,f.memoizedState,m.__reactInternalSnapshotBeforeUpdate)}var w=l.updateQueue;w!==null&&t7(l,w,m);break;case 3:var E=l.updateQueue;if(E!==null){if(f=null,l.child!==null)switch(l.child.tag){case 5:f=l.child.stateNode;break;case 1:f=l.child.stateNode}t7(l,E,f)}break;case 5:var L=l.stateNode;if(f===null&&l.flags&4){f=L;var V=l.memoizedProps;switch(l.type){case"button":case"input":case"select":case"textarea":V.autoFocus&&f.focus();break;case"img":V.src&&(f.src=V.src)}}break;case 6:break;case 4:break;case 12:break;case 13:if(l.memoizedState===null){var ne=l.alternate;if(ne!==null){var ge=ne.memoizedState;if(ge!==null){var _e=ge.dehydrated;_e!==null&&ed(_e)}}}break;case 19:case 17:case 21:case 22:case 23:case 25:break;default:throw Error(t(163))}fi||l.flags&512&&py(l)}catch(ve){cn(l,l.return,ve)}}if(l===s){Qe=null;break}if(f=l.sibling,f!==null){f.return=l.return,Qe=f;break}Qe=l.return}}function tx(s){for(;Qe!==null;){var l=Qe;if(l===s){Qe=null;break}var f=l.sibling;if(f!==null){f.return=l.return,Qe=f;break}Qe=l.return}}function rx(s){for(;Qe!==null;){var l=Qe;try{switch(l.tag){case 0:case 11:case 15:var f=l.return;try{J2(4,l)}catch(V){cn(l,f,V)}break;case 1:var m=l.stateNode;if(typeof m.componentDidMount=="function"){var y=l.return;try{m.componentDidMount()}catch(V){cn(l,y,V)}}var w=l.return;try{py(l)}catch(V){cn(l,w,V)}break;case 5:var E=l.return;try{py(l)}catch(V){cn(l,E,V)}}}catch(V){cn(l,l.return,V)}if(l===s){Qe=null;break}var L=l.sibling;if(L!==null){L.return=l.return,Qe=L;break}Qe=l.return}}var FL=Math.ceil,e0=Z.ReactCurrentDispatcher,gy=Z.ReactCurrentOwner,zo=Z.ReactCurrentBatchConfig,Xt=0,Hn=null,wn=null,Gn=0,go=0,yh=Hc(0),Mn=0,R1=null,ud=0,t0=0,yy=0,P1=null,Qi=null,_y=0,_h=1/0,zs=null,r0=!1,by=null,zc=null,n0=!1,Bc=null,i0=0,M1=0,wy=null,o0=-1,a0=0;function Mi(){return Xt&6?Kt():o0!==-1?o0:o0=Kt()}function Uc(s){return s.mode&1?Xt&2&&Gn!==0?Gn&-Gn:kL.transition!==null?(a0===0&&(a0=p2()),a0):(s=qt,s!==0||(s=window.event,s=s===void 0?16:qn(s.type)),s):1}function Sa(s,l,f,m){if(50<M1)throw M1=0,wy=null,Error(t(185));Yl(s,f,m),(!(Xt&2)||s!==Hn)&&(s===Hn&&(!(Xt&2)&&(t0|=f),Mn===4&&qc(s,Gn)),Xi(s,m),f===1&&Xt===0&&!(l.mode&1)&&(_h=Kt()+500,O2&&Dc()))}function Xi(s,l){var f=s.callbackNode;s5(s,l);var m=Qu(s,s===Hn?Gn:0);if(m===0)f!==null&&ci(f),s.callbackNode=null,s.callbackPriority=0;else if(l=m&-m,s.callbackPriority!==l){if(f!=null&&ci(f),l===1)s.tag===0?CL(ix.bind(null,s)):z9(ix.bind(null,s)),_L(function(){!(Xt&6)&&Dc()}),f=null;else{switch(n1(m)){case 1:f=ga;break;case 4:f=Lo;break;case 16:f=Ho;break;case 536870912:f=jt;break;default:f=Ho}f=hx(f,nx.bind(null,s))}s.callbackPriority=l,s.callbackNode=f}}function nx(s,l){if(o0=-1,a0=0,Xt&6)throw Error(t(327));var f=s.callbackNode;if(bh()&&s.callbackNode!==f)return null;var m=Qu(s,s===Hn?Gn:0);if(m===0)return null;if(m&30||m&s.expiredLanes||l)l=s0(s,m);else{l=m;var y=Xt;Xt|=2;var w=ax();(Hn!==s||Gn!==l)&&(zs=null,_h=Kt()+500,fd(s,l));do try{BL();break}catch(L){ox(s,L)}while(!0);D5(),e0.current=w,Xt=y,wn!==null?l=0:(Hn=null,Gn=0,l=Mn)}if(l!==0){if(l===2&&(y=r1(s),y!==0&&(m=y,l=xy(s,y))),l===1)throw f=R1,fd(s,0),qc(s,m),Xi(s,Kt()),f;if(l===6)qc(s,m);else{if(y=s.current.alternate,!(m&30)&&!jL(y)&&(l=s0(s,m),l===2&&(w=r1(s),w!==0&&(m=w,l=xy(s,w))),l===1))throw f=R1,fd(s,0),qc(s,m),Xi(s,Kt()),f;switch(s.finishedWork=y,s.finishedLanes=m,l){case 0:case 1:throw Error(t(345));case 2:pd(s,Qi,zs);break;case 3:if(qc(s,m),(m&130023424)===m&&(l=_y+500-Kt(),10<l)){if(Qu(s,0)!==0)break;if(y=s.suspendedLanes,(y&m)!==m){Mi(),s.pingedLanes|=s.suspendedLanes&y;break}s.timeoutHandle=A5(pd.bind(null,s,Qi,zs),l);break}pd(s,Qi,zs);break;case 4:if(qc(s,m),(m&4194240)===m)break;for(l=s.eventTimes,y=-1;0<m;){var E=31-Yt(m);w=1<<E,E=l[E],E>y&&(y=E),m&=~w}if(m=y,m=Kt()-m,m=(120>m?120:480>m?480:1080>m?1080:1920>m?1920:3e3>m?3e3:4320>m?4320:1960*FL(m/1960))-m,10<m){s.timeoutHandle=A5(pd.bind(null,s,Qi,zs),m);break}pd(s,Qi,zs);break;case 5:pd(s,Qi,zs);break;default:throw Error(t(329))}}}return Xi(s,Kt()),s.callbackNode===f?nx.bind(null,s):null}function xy(s,l){var f=P1;return s.current.memoizedState.isDehydrated&&(fd(s,l).flags|=256),s=s0(s,l),s!==2&&(l=Qi,Qi=f,l!==null&&Cy(l)),s}function Cy(s){Qi===null?Qi=s:Qi.push.apply(Qi,s)}function jL(s){for(var l=s;;){if(l.flags&16384){var f=l.updateQueue;if(f!==null&&(f=f.stores,f!==null))for(var m=0;m<f.length;m++){var y=f[m],w=y.getSnapshot;y=y.value;try{if(!wa(w(),y))return!1}catch{return!1}}}if(f=l.child,l.subtreeFlags&16384&&f!==null)f.return=l,l=f;else{if(l===s)break;for(;l.sibling===null;){if(l.return===null||l.return===s)return!0;l=l.return}l.sibling.return=l.return,l=l.sibling}}return!0}function qc(s,l){for(l&=~yy,l&=~t0,s.suspendedLanes|=l,s.pingedLanes&=~l,s=s.expirationTimes;0<l;){var f=31-Yt(l),m=1<<f;s[f]=-1,l&=~m}}function ix(s){if(Xt&6)throw Error(t(327));bh();var l=Qu(s,0);if(!(l&1))return Xi(s,Kt()),null;var f=s0(s,l);if(s.tag!==0&&f===2){var m=r1(s);m!==0&&(l=m,f=xy(s,m))}if(f===1)throw f=R1,fd(s,0),qc(s,l),Xi(s,Kt()),f;if(f===6)throw Error(t(345));return s.finishedWork=s.current.alternate,s.finishedLanes=l,pd(s,Qi,zs),Xi(s,Kt()),null}function ky(s,l){var f=Xt;Xt|=1;try{return s(l)}finally{Xt=f,Xt===0&&(_h=Kt()+500,O2&&Dc())}}function hd(s){Bc!==null&&Bc.tag===0&&!(Xt&6)&&bh();var l=Xt;Xt|=1;var f=zo.transition,m=qt;try{if(zo.transition=null,qt=1,s)return s()}finally{qt=m,zo.transition=f,Xt=l,!(Xt&6)&&Dc()}}function Ey(){go=yh.current,Lr(yh)}function fd(s,l){s.finishedWork=null,s.finishedLanes=0;var f=s.timeoutHandle;if(f!==-1&&(s.timeoutHandle=-1,yL(f)),wn!==null)for(f=wn.return;f!==null;){var m=f;switch(O5(m),m.tag){case 1:m=m.type.childContextTypes,m!=null&&M2();break;case 3:mh(),Lr(Gi),Lr(di),W5();break;case 5:U5(m);break;case 4:mh();break;case 13:Lr(Gr);break;case 19:Lr(Gr);break;case 10:V5(m.type._context);break;case 22:case 23:Ey()}f=f.return}if(Hn=s,wn=s=Wc(s.current,null),Gn=go=l,Mn=0,R1=null,yy=t0=ud=0,Qi=P1=null,cd!==null){for(l=0;l<cd.length;l++)if(f=cd[l],m=f.interleaved,m!==null){f.interleaved=null;var y=m.next,w=f.pending;if(w!==null){var E=w.next;w.next=y,m.next=E}f.pending=m}cd=null}return s}function ox(s,l){do{var f=wn;try{if(D5(),B2.current=G2,U2){for(var m=Kr.memoizedState;m!==null;){var y=m.queue;y!==null&&(y.pending=null),m=m.next}U2=!1}if(dd=0,Ln=Pn=Kr=null,k1=!1,E1=0,gy.current=null,f===null||f.return===null){Mn=1,R1=l,wn=null;break}e:{var w=s,E=f.return,L=f,V=l;if(l=Gn,L.flags|=32768,V!==null&&typeof V=="object"&&typeof V.then=="function"){var ne=V,ge=L,_e=ge.tag;if(!(ge.mode&1)&&(_e===0||_e===11||_e===15)){var ve=ge.alternate;ve?(ge.updateQueue=ve.updateQueue,ge.memoizedState=ve.memoizedState,ge.lanes=ve.lanes):(ge.updateQueue=null,ge.memoizedState=null)}var Fe=R7(E);if(Fe!==null){Fe.flags&=-257,P7(Fe,E,L,w,l),Fe.mode&1&&I7(w,ne,l),l=Fe,V=ne;var tt=l.updateQueue;if(tt===null){var nt=new Set;nt.add(V),l.updateQueue=nt}else tt.add(V);break e}else{if(!(l&1)){I7(w,ne,l),Sy();break e}V=Error(t(426))}}else if(Vr&&L.mode&1){var gn=R7(E);if(gn!==null){!(gn.flags&65536)&&(gn.flags|=256),P7(gn,E,L,w,l),H5(vh(V,L));break e}}w=V=vh(V,L),Mn!==4&&(Mn=2),P1===null?P1=[w]:P1.push(w),w=E;do{switch(w.tag){case 3:w.flags|=65536,l&=-l,w.lanes|=l;var X=T7(w,V,l);e7(w,X);break e;case 1:L=V;var W=w.type,ee=w.stateNode;if(!(w.flags&128)&&(typeof W.getDerivedStateFromError=="function"||ee!==null&&typeof ee.componentDidCatch=="function"&&(zc===null||!zc.has(ee)))){w.flags|=65536,l&=-l,w.lanes|=l;var Se=A7(w,L,l);e7(w,Se);break e}}w=w.return}while(w!==null)}cx(f)}catch(st){l=st,wn===f&&f!==null&&(wn=f=f.return);continue}break}while(!0)}function ax(){var s=e0.current;return e0.current=G2,s===null?G2:s}function Sy(){(Mn===0||Mn===3||Mn===2)&&(Mn=4),Hn===null||!(ud&268435455)&&!(t0&268435455)||qc(Hn,Gn)}function s0(s,l){var f=Xt;Xt|=2;var m=ax();(Hn!==s||Gn!==l)&&(zs=null,fd(s,l));do try{zL();break}catch(y){ox(s,y)}while(!0);if(D5(),Xt=f,e0.current=m,wn!==null)throw Error(t(261));return Hn=null,Gn=0,Mn}function zL(){for(;wn!==null;)sx(wn)}function BL(){for(;wn!==null&&!$s();)sx(wn)}function sx(s){var l=ux(s.alternate,s,go);s.memoizedProps=s.pendingProps,l===null?cx(s):wn=l,gy.current=null}function cx(s){var l=s;do{var f=l.alternate;if(s=l.return,l.flags&32768){if(f=HL(f,l),f!==null){f.flags&=32767,wn=f;return}if(s!==null)s.flags|=32768,s.subtreeFlags=0,s.deletions=null;else{Mn=6,wn=null;return}}else if(f=LL(f,l,go),f!==null){wn=f;return}if(l=l.sibling,l!==null){wn=l;return}wn=l=s}while(l!==null);Mn===0&&(Mn=5)}function pd(s,l,f){var m=qt,y=zo.transition;try{zo.transition=null,qt=1,UL(s,l,f,m)}finally{zo.transition=y,qt=m}return null}function UL(s,l,f,m){do bh();while(Bc!==null);if(Xt&6)throw Error(t(327));f=s.finishedWork;var y=s.finishedLanes;if(f===null)return null;if(s.finishedWork=null,s.finishedLanes=0,f===s.current)throw Error(t(177));s.callbackNode=null,s.callbackPriority=0;var w=f.lanes|f.childLanes;if(c5(s,w),s===Hn&&(wn=Hn=null,Gn=0),!(f.subtreeFlags&2064)&&!(f.flags&2064)||n0||(n0=!0,hx(Ho,function(){return bh(),null})),w=(f.flags&15990)!==0,f.subtreeFlags&15990||w){w=zo.transition,zo.transition=null;var E=qt;qt=1;var L=Xt;Xt|=4,gy.current=null,DL(s,f),X7(f,s),uL(S5),te=!!E5,S5=E5=null,s.current=f,VL(f),ho(),Xt=L,qt=E,zo.transition=w}else s.current=f;if(n0&&(n0=!1,Bc=s,i0=y),w=s.pendingLanes,w===0&&(zc=null),Os(f.stateNode),Xi(s,Kt()),l!==null)for(m=s.onRecoverableError,f=0;f<l.length;f++)y=l[f],m(y.value,{componentStack:y.stack,digest:y.digest});if(r0)throw r0=!1,s=by,by=null,s;return i0&1&&s.tag!==0&&bh(),w=s.pendingLanes,w&1?s===wy?M1++:(M1=0,wy=s):M1=0,Dc(),null}function bh(){if(Bc!==null){var s=n1(i0),l=zo.transition,f=qt;try{if(zo.transition=null,qt=16>s?16:s,Bc===null)var m=!1;else{if(s=Bc,Bc=null,i0=0,Xt&6)throw Error(t(331));var y=Xt;for(Xt|=4,Qe=s.current;Qe!==null;){var w=Qe,E=w.child;if(Qe.flags&16){var L=w.deletions;if(L!==null){for(var V=0;V<L.length;V++){var ne=L[V];for(Qe=ne;Qe!==null;){var ge=Qe;switch(ge.tag){case 0:case 11:case 15:I1(8,ge,w)}var _e=ge.child;if(_e!==null)_e.return=ge,Qe=_e;else for(;Qe!==null;){ge=Qe;var ve=ge.sibling,Fe=ge.return;if(W7(ge),ge===ne){Qe=null;break}if(ve!==null){ve.return=Fe,Qe=ve;break}Qe=Fe}}}var tt=w.alternate;if(tt!==null){var nt=tt.child;if(nt!==null){tt.child=null;do{var gn=nt.sibling;nt.sibling=null,nt=gn}while(nt!==null)}}Qe=w}}if(w.subtreeFlags&2064&&E!==null)E.return=w,Qe=E;else e:for(;Qe!==null;){if(w=Qe,w.flags&2048)switch(w.tag){case 0:case 11:case 15:I1(9,w,w.return)}var X=w.sibling;if(X!==null){X.return=w.return,Qe=X;break e}Qe=w.return}}var W=s.current;for(Qe=W;Qe!==null;){E=Qe;var ee=E.child;if(E.subtreeFlags&2064&&ee!==null)ee.return=E,Qe=ee;else e:for(E=W;Qe!==null;){if(L=Qe,L.flags&2048)try{switch(L.tag){case 0:case 11:case 15:J2(9,L)}}catch(st){cn(L,L.return,st)}if(L===E){Qe=null;break e}var Se=L.sibling;if(Se!==null){Se.return=L.return,Qe=Se;break e}Qe=L.return}}if(Xt=y,Dc(),In&&typeof In.onPostCommitFiberRoot=="function")try{In.onPostCommitFiberRoot(sr,s)}catch{}m=!0}return m}finally{qt=f,zo.transition=l}}return!1}function lx(s,l,f){l=vh(f,l),l=T7(s,l,1),s=Fc(s,l,1),l=Mi(),s!==null&&(Yl(s,1,l),Xi(s,l))}function cn(s,l,f){if(s.tag===3)lx(s,s,f);else for(;l!==null;){if(l.tag===3){lx(l,s,f);break}else if(l.tag===1){var m=l.stateNode;if(typeof l.type.getDerivedStateFromError=="function"||typeof m.componentDidCatch=="function"&&(zc===null||!zc.has(m))){s=vh(f,s),s=A7(l,s,1),l=Fc(l,s,1),s=Mi(),l!==null&&(Yl(l,1,s),Xi(l,s));break}}l=l.return}}function qL(s,l,f){var m=s.pingCache;m!==null&&m.delete(l),l=Mi(),s.pingedLanes|=s.suspendedLanes&f,Hn===s&&(Gn&f)===f&&(Mn===4||Mn===3&&(Gn&130023424)===Gn&&500>Kt()-_y?fd(s,0):yy|=f),Xi(s,l)}function dx(s,l){l===0&&(s.mode&1?(l=Yu,Yu<<=1,!(Yu&130023424)&&(Yu=4194304)):l=1);var f=Mi();s=Vs(s,l),s!==null&&(Yl(s,l,f),Xi(s,f))}function WL(s){var l=s.memoizedState,f=0;l!==null&&(f=l.retryLane),dx(s,f)}function GL(s,l){var f=0;switch(s.tag){case 13:var m=s.stateNode,y=s.memoizedState;y!==null&&(f=y.retryLane);break;case 19:m=s.stateNode;break;default:throw Error(t(314))}m!==null&&m.delete(l),dx(s,f)}var ux;ux=function(s,l,f){if(s!==null)if(s.memoizedProps!==l.pendingProps||Gi.current)Yi=!0;else{if(!(s.lanes&f)&&!(l.flags&128))return Yi=!1,ZL(s,l,f);Yi=!!(s.flags&131072)}else Yi=!1,Vr&&l.flags&1048576&&B9(l,L2,l.index);switch(l.lanes=0,l.tag){case 2:var m=l.type;Q2(s,l),s=l.pendingProps;var y=ch(l,di.current);ph(l,f),y=Y5(null,l,m,s,y,f);var w=Q5();return l.flags|=1,typeof y=="object"&&y!==null&&typeof y.render=="function"&&y.$$typeof===void 0?(l.tag=1,l.memoizedState=null,l.updateQueue=null,Ki(m)?(w=!0,$2(l)):w=!1,l.memoizedState=y.state!==null&&y.state!==void 0?y.state:null,z5(l),y.updater=K2,l.stateNode=y,y._reactInternals=l,ny(l,m,s,f),l=sy(null,l,m,!0,w,f)):(l.tag=0,Vr&&w&&$5(l),Pi(null,l,y,f),l=l.child),l;case 16:m=l.elementType;e:{switch(Q2(s,l),s=l.pendingProps,y=m._init,m=y(m._payload),l.type=m,y=l.tag=YL(m),s=Ca(m,s),y){case 0:l=ay(null,l,m,s,f);break e;case 1:l=H7(null,l,m,s,f);break e;case 11:l=M7(null,l,m,s,f);break e;case 14:l=$7(null,l,m,Ca(m.type,s),f);break e}throw Error(t(306,m,""))}return l;case 0:return m=l.type,y=l.pendingProps,y=l.elementType===m?y:Ca(m,y),ay(s,l,m,y,f);case 1:return m=l.type,y=l.pendingProps,y=l.elementType===m?y:Ca(m,y),H7(s,l,m,y,f);case 3:e:{if(N7(l),s===null)throw Error(t(387));m=l.pendingProps,w=l.memoizedState,y=w.element,J9(s,l),j2(l,m,null,f);var E=l.memoizedState;if(m=E.element,w.isDehydrated)if(w={element:m,isDehydrated:!1,cache:E.cache,pendingSuspenseBoundaries:E.pendingSuspenseBoundaries,transitions:E.transitions},l.updateQueue.baseState=w,l.memoizedState=w,l.flags&256){y=vh(Error(t(423)),l),l=D7(s,l,m,f,y);break e}else if(m!==y){y=vh(Error(t(424)),l),l=D7(s,l,m,f,y);break e}else for(vo=Lc(l.stateNode.containerInfo.firstChild),mo=l,Vr=!0,xa=null,f=Q9(l,null,m,f),l.child=f;f;)f.flags=f.flags&-3|4096,f=f.sibling;else{if(uh(),m===y){l=js(s,l,f);break e}Pi(s,l,m,f)}l=l.child}return l;case 5:return r7(l),s===null&&L5(l),m=l.type,y=l.pendingProps,w=s!==null?s.memoizedProps:null,E=y.children,T5(m,y)?E=null:w!==null&&T5(m,w)&&(l.flags|=32),L7(s,l),Pi(s,l,E,f),l.child;case 6:return s===null&&L5(l),null;case 13:return V7(s,l,f);case 4:return B5(l,l.stateNode.containerInfo),m=l.pendingProps,s===null?l.child=hh(l,null,m,f):Pi(s,l,m,f),l.child;case 11:return m=l.type,y=l.pendingProps,y=l.elementType===m?y:Ca(m,y),M7(s,l,m,y,f);case 7:return Pi(s,l,l.pendingProps,f),l.child;case 8:return Pi(s,l,l.pendingProps.children,f),l.child;case 12:return Pi(s,l,l.pendingProps.children,f),l.child;case 10:e:{if(m=l.type._context,y=l.pendingProps,w=l.memoizedProps,E=y.value,Ir(D2,m._currentValue),m._currentValue=E,w!==null)if(wa(w.value,E)){if(w.children===y.children&&!Gi.current){l=js(s,l,f);break e}}else for(w=l.child,w!==null&&(w.return=l);w!==null;){var L=w.dependencies;if(L!==null){E=w.child;for(var V=L.firstContext;V!==null;){if(V.context===m){if(w.tag===1){V=Fs(-1,f&-f),V.tag=2;var ne=w.updateQueue;if(ne!==null){ne=ne.shared;var ge=ne.pending;ge===null?V.next=V:(V.next=ge.next,ge.next=V),ne.pending=V}}w.lanes|=f,V=w.alternate,V!==null&&(V.lanes|=f),F5(w.return,f,l),L.lanes|=f;break}V=V.next}}else if(w.tag===10)E=w.type===l.type?null:w.child;else if(w.tag===18){if(E=w.return,E===null)throw Error(t(341));E.lanes|=f,L=E.alternate,L!==null&&(L.lanes|=f),F5(E,f,l),E=w.sibling}else E=w.child;if(E!==null)E.return=w;else for(E=w;E!==null;){if(E===l){E=null;break}if(w=E.sibling,w!==null){w.return=E.return,E=w;break}E=E.return}w=E}Pi(s,l,y.children,f),l=l.child}return l;case 9:return y=l.type,m=l.pendingProps.children,ph(l,f),y=Fo(y),m=m(y),l.flags|=1,Pi(s,l,m,f),l.child;case 14:return m=l.type,y=Ca(m,l.pendingProps),y=Ca(m.type,y),$7(s,l,m,y,f);case 15:return O7(s,l,l.type,l.pendingProps,f);case 17:return m=l.type,y=l.pendingProps,y=l.elementType===m?y:Ca(m,y),Q2(s,l),l.tag=1,Ki(m)?(s=!0,$2(l)):s=!1,ph(l,f),E7(l,m,y),ny(l,m,y,f),sy(null,l,m,!0,s,f);case 19:return j7(s,l,f);case 22:return Z7(s,l,f)}throw Error(t(156,l.tag))};function hx(s,l){return Er(s,l)}function KL(s,l,f,m){this.tag=s,this.key=f,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=l,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=m,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Bo(s,l,f,m){return new KL(s,l,f,m)}function Ty(s){return s=s.prototype,!(!s||!s.isReactComponent)}function YL(s){if(typeof s=="function")return Ty(s)?1:0;if(s!=null){if(s=s.$$typeof,s===we)return 11;if(s===K)return 14}return 2}function Wc(s,l){var f=s.alternate;return f===null?(f=Bo(s.tag,l,s.key,s.mode),f.elementType=s.elementType,f.type=s.type,f.stateNode=s.stateNode,f.alternate=s,s.alternate=f):(f.pendingProps=l,f.type=s.type,f.flags=0,f.subtreeFlags=0,f.deletions=null),f.flags=s.flags&14680064,f.childLanes=s.childLanes,f.lanes=s.lanes,f.child=s.child,f.memoizedProps=s.memoizedProps,f.memoizedState=s.memoizedState,f.updateQueue=s.updateQueue,l=s.dependencies,f.dependencies=l===null?null:{lanes:l.lanes,firstContext:l.firstContext},f.sibling=s.sibling,f.index=s.index,f.ref=s.ref,f}function c0(s,l,f,m,y,w){var E=2;if(m=s,typeof s=="function")Ty(s)&&(E=1);else if(typeof s=="string")E=5;else e:switch(s){case I:return md(f.children,y,w,l);case Y:E=8,y|=8;break;case le:return s=Bo(12,f,l,y|2),s.elementType=le,s.lanes=w,s;case Ce:return s=Bo(13,f,l,y),s.elementType=Ce,s.lanes=w,s;case J:return s=Bo(19,f,l,y),s.elementType=J,s.lanes=w,s;case q:return l0(f,y,w,l);default:if(typeof s=="object"&&s!==null)switch(s.$$typeof){case de:E=10;break e;case Ee:E=9;break e;case we:E=11;break e;case K:E=14;break e;case re:E=16,m=null;break e}throw Error(t(130,s==null?s:typeof s,""))}return l=Bo(E,f,l,y),l.elementType=s,l.type=m,l.lanes=w,l}function md(s,l,f,m){return s=Bo(7,s,m,l),s.lanes=f,s}function l0(s,l,f,m){return s=Bo(22,s,m,l),s.elementType=q,s.lanes=f,s.stateNode={isHidden:!1},s}function Ay(s,l,f){return s=Bo(6,s,null,l),s.lanes=f,s}function Iy(s,l,f){return l=Bo(4,s.children!==null?s.children:[],s.key,l),l.lanes=f,l.stateNode={containerInfo:s.containerInfo,pendingChildren:null,implementation:s.implementation},l}function QL(s,l,f,m,y){this.tag=l,this.containerInfo=s,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=Xu(0),this.expirationTimes=Xu(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Xu(0),this.identifierPrefix=m,this.onRecoverableError=y,this.mutableSourceEagerHydrationData=null}function Ry(s,l,f,m,y,w,E,L,V){return s=new QL(s,l,f,L,V),l===1?(l=1,w===!0&&(l|=8)):l=0,w=Bo(3,null,null,l),s.current=w,w.stateNode=s,w.memoizedState={element:m,isDehydrated:f,cache:null,transitions:null,pendingSuspenseBoundaries:null},z5(w),s}function XL(s,l,f){var m=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:U,key:m==null?null:""+m,children:s,containerInfo:l,implementation:f}}function fx(s){if(!s)return Nc;s=s._reactInternals;e:{if(Je(s)!==s||s.tag!==1)throw Error(t(170));var l=s;do{switch(l.tag){case 3:l=l.stateNode.context;break e;case 1:if(Ki(l.type)){l=l.stateNode.__reactInternalMemoizedMergedChildContext;break e}}l=l.return}while(l!==null);throw Error(t(171))}if(s.tag===1){var f=s.type;if(Ki(f))return F9(s,f,l)}return l}function px(s,l,f,m,y,w,E,L,V){return s=Ry(f,m,!0,s,y,w,E,L,V),s.context=fx(null),f=s.current,m=Mi(),y=Uc(f),w=Fs(m,y),w.callback=l??null,Fc(f,w,y),s.current.lanes=y,Yl(s,y,m),Xi(s,m),s}function d0(s,l,f,m){var y=l.current,w=Mi(),E=Uc(y);return f=fx(f),l.context===null?l.context=f:l.pendingContext=f,l=Fs(w,E),l.payload={element:s},m=m===void 0?null:m,m!==null&&(l.callback=m),s=Fc(y,l,E),s!==null&&(Sa(s,y,E,w),F2(s,y,E)),E}function u0(s){if(s=s.current,!s.child)return null;switch(s.child.tag){case 5:return s.child.stateNode;default:return s.child.stateNode}}function mx(s,l){if(s=s.memoizedState,s!==null&&s.dehydrated!==null){var f=s.retryLane;s.retryLane=f!==0&&f<l?f:l}}function Py(s,l){mx(s,l),(s=s.alternate)&&mx(s,l)}function JL(){return null}var vx=typeof reportError=="function"?reportError:function(s){console.error(s)};function My(s){this._internalRoot=s}h0.prototype.render=My.prototype.render=function(s){var l=this._internalRoot;if(l===null)throw Error(t(409));d0(s,l,null,null)},h0.prototype.unmount=My.prototype.unmount=function(){var s=this._internalRoot;if(s!==null){this._internalRoot=null;var l=s.containerInfo;hd(function(){d0(null,s,null,null)}),l[Ls]=null}};function h0(s){this._internalRoot=s}h0.prototype.unstable_scheduleHydration=function(s){if(s){var l=v2();s={blockedOn:null,target:s,priority:l};for(var f=0;f<No.length&&l!==0&&l<No[f].priority;f++);No.splice(f,0,s),f===0&&w2(s)}};function $y(s){return!(!s||s.nodeType!==1&&s.nodeType!==9&&s.nodeType!==11)}function f0(s){return!(!s||s.nodeType!==1&&s.nodeType!==9&&s.nodeType!==11&&(s.nodeType!==8||s.nodeValue!==" react-mount-point-unstable "))}function gx(){}function eH(s,l,f,m,y){if(y){if(typeof m=="function"){var w=m;m=function(){var ne=u0(E);w.call(ne)}}var E=px(l,m,s,0,null,!1,!1,"",gx);return s._reactRootContainer=E,s[Ls]=E.current,v1(s.nodeType===8?s.parentNode:s),hd(),E}for(;y=s.lastChild;)s.removeChild(y);if(typeof m=="function"){var L=m;m=function(){var ne=u0(V);L.call(ne)}}var V=Ry(s,0,!1,null,null,!1,!1,"",gx);return s._reactRootContainer=V,s[Ls]=V.current,v1(s.nodeType===8?s.parentNode:s),hd(function(){d0(l,V,f,m)}),V}function p0(s,l,f,m,y){var w=f._reactRootContainer;if(w){var E=w;if(typeof y=="function"){var L=y;y=function(){var V=u0(E);L.call(V)}}d0(l,E,s,y)}else E=eH(f,l,s,y,m);return u0(E)}Ga=function(s){switch(s.tag){case 3:var l=s.stateNode;if(l.current.memoizedState.isDehydrated){var f=Kl(l.pendingLanes);f!==0&&(Mc(l,f|1),Xi(l,Kt()),!(Xt&6)&&(_h=Kt()+500,Dc()))}break;case 13:hd(function(){var m=Vs(s,1);if(m!==null){var y=Mi();Sa(m,s,1,y)}}),Py(s,1)}},i1=function(s){if(s.tag===13){var l=Vs(s,134217728);if(l!==null){var f=Mi();Sa(l,s,134217728,f)}Py(s,134217728)}},m2=function(s){if(s.tag===13){var l=Uc(s),f=Vs(s,l);if(f!==null){var m=Mi();Sa(f,s,l,m)}Py(s,l)}},v2=function(){return qt},g2=function(s,l){var f=qt;try{return qt=s,l()}finally{qt=f}},qa=function(s,l,f){switch(l){case"input":if(Sc(s,f),l=f.name,f.type==="radio"&&l!=null){for(f=s;f.parentNode;)f=f.parentNode;for(f=f.querySelectorAll("input[name="+JSON.stringify(""+l)+'][type="radio"]'),l=0;l<f.length;l++){var m=f[l];if(m!==s&&m.form===s.form){var y=P2(m);if(!y)throw Error(t(90));Rt(m),Sc(m,y)}}}break;case"textarea":An(s,f);break;case"select":l=f.value,l!=null&&Mo(s,!!f.multiple,l,!1)}},ql=ky,Ms=hd;var tH={usingClientEntryPoint:!1,Events:[_1,ah,P2,Ul,Gu,ky]},$1={findFiberByHostInstance:id,bundleType:0,version:"18.3.1",rendererPackageName:"react-dom"},rH={bundleType:$1.bundleType,version:$1.version,rendererPackageName:$1.rendererPackageName,rendererConfig:$1.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setErrorHandler:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:Z.ReactCurrentDispatcher,findHostInstanceByFiber:function(s){return s=ar(s),s===null?null:s.stateNode},findFiberByHostInstance:$1.findFiberByHostInstance||JL,findHostInstancesForRefresh:null,scheduleRefresh:null,scheduleRoot:null,setRefreshHandler:null,getCurrentFiber:null,reconcilerVersion:"18.3.1-next-f1338f8080-20240426"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var m0=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!m0.isDisabled&&m0.supportsFiber)try{sr=m0.inject(rH),In=m0}catch{}}return Ji.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=tH,Ji.createPortal=function(s,l){var f=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!$y(l))throw Error(t(200));return XL(s,l,null,f)},Ji.createRoot=function(s,l){if(!$y(s))throw Error(t(299));var f=!1,m="",y=vx;return l!=null&&(l.unstable_strictMode===!0&&(f=!0),l.identifierPrefix!==void 0&&(m=l.identifierPrefix),l.onRecoverableError!==void 0&&(y=l.onRecoverableError)),l=Ry(s,1,!1,null,null,f,!1,m,y),s[Ls]=l.current,v1(s.nodeType===8?s.parentNode:s),new My(l)},Ji.findDOMNode=function(s){if(s==null)return null;if(s.nodeType===1)return s;var l=s._reactInternals;if(l===void 0)throw typeof s.render=="function"?Error(t(188)):(s=Object.keys(s).join(","),Error(t(268,s)));return s=ar(l),s=s===null?null:s.stateNode,s},Ji.flushSync=function(s){return hd(s)},Ji.hydrate=function(s,l,f){if(!f0(l))throw Error(t(200));return p0(null,s,l,!0,f)},Ji.hydrateRoot=function(s,l,f){if(!$y(s))throw Error(t(405));var m=f!=null&&f.hydratedSources||null,y=!1,w="",E=vx;if(f!=null&&(f.unstable_strictMode===!0&&(y=!0),f.identifierPrefix!==void 0&&(w=f.identifierPrefix),f.onRecoverableError!==void 0&&(E=f.onRecoverableError)),l=px(l,null,s,1,f??null,y,!1,w,E),s[Ls]=l.current,v1(s),m)for(s=0;s<m.length;s++)f=m[s],y=f._getVersion,y=y(f._source),l.mutableSourceEagerHydrationData==null?l.mutableSourceEagerHydrationData=[f,y]:l.mutableSourceEagerHydrationData.push(f,y);return new h0(l)},Ji.render=function(s,l,f){if(!f0(l))throw Error(t(200));return p0(null,s,l,!1,f)},Ji.unmountComponentAtNode=function(s){if(!f0(s))throw Error(t(40));return s._reactRootContainer?(hd(function(){p0(null,null,s,!1,function(){s._reactRootContainer=null,s[Ls]=null})}),!0):!1},Ji.unstable_batchedUpdates=ky,Ji.unstable_renderSubtreeIntoContainer=function(s,l,f,m){if(!f0(f))throw Error(t(200));if(s==null||s._reactInternals===void 0)throw Error(t(38));return p0(s,l,f,!1,m)},Ji.version="18.3.1-next-f1338f8080-20240426",Ji}var Ex;function JI(){if(Ex)return Hy.exports;Ex=1;function r(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(r)}catch(e){console.error(e)}}return r(),Hy.exports=uH(),Hy.exports}var Sx;function hH(){if(Sx)return g0;Sx=1;var r=JI();return g0.createRoot=r.createRoot,g0.hydrateRoot=r.hydrateRoot,g0}var fH=hH();const pH=Hu(fH);var y0={exports:{}},Vy,Tx;function o4(){if(Tx)return Vy;Tx=1;const r="2.0.0",e=256,t=Number.MAX_SAFE_INTEGER||9007199254740991,n=16,i=e-6;return Vy={MAX_LENGTH:e,MAX_SAFE_COMPONENT_LENGTH:n,MAX_SAFE_BUILD_LENGTH:i,MAX_SAFE_INTEGER:t,RELEASE_TYPES:["major","premajor","minor","preminor","patch","prepatch","prerelease"],SEMVER_SPEC_VERSION:r,FLAG_INCLUDE_PRERELEASE:1,FLAG_LOOSE:2},Vy}var Fy,Ax;function a4(){if(Ax)return Fy;Ax=1;var r={};return Fy=typeof process=="object"&&r&&r.NODE_DEBUG&&/\bsemver\b/i.test(r.NODE_DEBUG)?(...t)=>console.error("SEMVER",...t):()=>{},Fy}var Ix;function Rm(){return Ix||(Ix=1,function(r,e){const{MAX_SAFE_COMPONENT_LENGTH:t,MAX_SAFE_BUILD_LENGTH:n,MAX_LENGTH:i}=o4(),o=a4();e=r.exports={};const a=e.re=[],c=e.safeRe=[],d=e.src=[],h=e.safeSrc=[],u=e.t={};let p=0;const v="[a-zA-Z0-9-]",g=[["\\s",1],["\\d",i],[v,n]],_=C=>{for(const[T,S]of g)C=C.split(`${T}*`).join(`${T}{0,${S}}`).split(`${T}+`).join(`${T}{1,${S}}`);return C},b=(C,T,S)=>{const A=_(T),Z=p++;o(C,Z,T),u[C]=Z,d[Z]=T,h[Z]=A,a[Z]=new RegExp(T,S?"g":void 0),c[Z]=new RegExp(A,S?"g":void 0)};b("NUMERICIDENTIFIER","0|[1-9]\\d*"),b("NUMERICIDENTIFIERLOOSE","\\d+"),b("NONNUMERICIDENTIFIER",`\\d*[a-zA-Z-]${v}*`),b("MAINVERSION",`(${d[u.NUMERICIDENTIFIER]})\\.(${d[u.NUMERICIDENTIFIER]})\\.(${d[u.NUMERICIDENTIFIER]})`),b("MAINVERSIONLOOSE",`(${d[u.NUMERICIDENTIFIERLOOSE]})\\.(${d[u.NUMERICIDENTIFIERLOOSE]})\\.(${d[u.NUMERICIDENTIFIERLOOSE]})`),b("PRERELEASEIDENTIFIER",`(?:${d[u.NUMERICIDENTIFIER]}|${d[u.NONNUMERICIDENTIFIER]})`),b("PRERELEASEIDENTIFIERLOOSE",`(?:${d[u.NUMERICIDENTIFIERLOOSE]}|${d[u.NONNUMERICIDENTIFIER]})`),b("PRERELEASE",`(?:-(${d[u.PRERELEASEIDENTIFIER]}(?:\\.${d[u.PRERELEASEIDENTIFIER]})*))`),b("PRERELEASELOOSE",`(?:-?(${d[u.PRERELEASEIDENTIFIERLOOSE]}(?:\\.${d[u.PRERELEASEIDENTIFIERLOOSE]})*))`),b("BUILDIDENTIFIER",`${v}+`),b("BUILD",`(?:\\+(${d[u.BUILDIDENTIFIER]}(?:\\.${d[u.BUILDIDENTIFIER]})*))`),b("FULLPLAIN",`v?${d[u.MAINVERSION]}${d[u.PRERELEASE]}?${d[u.BUILD]}?`),b("FULL",`^${d[u.FULLPLAIN]}$`),b("LOOSEPLAIN",`[v=\\s]*${d[u.MAINVERSIONLOOSE]}${d[u.PRERELEASELOOSE]}?${d[u.BUILD]}?`),b("LOOSE",`^${d[u.LOOSEPLAIN]}$`),b("GTLT","((?:<|>)?=?)"),b("XRANGEIDENTIFIERLOOSE",`${d[u.NUMERICIDENTIFIERLOOSE]}|x|X|\\*`),b("XRANGEIDENTIFIER",`${d[u.NUMERICIDENTIFIER]}|x|X|\\*`),b("XRANGEPLAIN",`[v=\\s]*(${d[u.XRANGEIDENTIFIER]})(?:\\.(${d[u.XRANGEIDENTIFIER]})(?:\\.(${d[u.XRANGEIDENTIFIER]})(?:${d[u.PRERELEASE]})?${d[u.BUILD]}?)?)?`),b("XRANGEPLAINLOOSE",`[v=\\s]*(${d[u.XRANGEIDENTIFIERLOOSE]})(?:\\.(${d[u.XRANGEIDENTIFIERLOOSE]})(?:\\.(${d[u.XRANGEIDENTIFIERLOOSE]})(?:${d[u.PRERELEASELOOSE]})?${d[u.BUILD]}?)?)?`),b("XRANGE",`^${d[u.GTLT]}\\s*${d[u.XRANGEPLAIN]}$`),b("XRANGELOOSE",`^${d[u.GTLT]}\\s*${d[u.XRANGEPLAINLOOSE]}$`),b("COERCEPLAIN",`(^|[^\\d])(\\d{1,${t}})(?:\\.(\\d{1,${t}}))?(?:\\.(\\d{1,${t}}))?`),b("COERCE",`${d[u.COERCEPLAIN]}(?:$|[^\\d])`),b("COERCEFULL",d[u.COERCEPLAIN]+`(?:${d[u.PRERELEASE]})?(?:${d[u.BUILD]})?(?:$|[^\\d])`),b("COERCERTL",d[u.COERCE],!0),b("COERCERTLFULL",d[u.COERCEFULL],!0),b("LONETILDE","(?:~>?)"),b("TILDETRIM",`(\\s*)${d[u.LONETILDE]}\\s+`,!0),e.tildeTrimReplace="$1~",b("TILDE",`^${d[u.LONETILDE]}${d[u.XRANGEPLAIN]}$`),b("TILDELOOSE",`^${d[u.LONETILDE]}${d[u.XRANGEPLAINLOOSE]}$`),b("LONECARET","(?:\\^)"),b("CARETTRIM",`(\\s*)${d[u.LONECARET]}\\s+`,!0),e.caretTrimReplace="$1^",b("CARET",`^${d[u.LONECARET]}${d[u.XRANGEPLAIN]}$`),b("CARETLOOSE",`^${d[u.LONECARET]}${d[u.XRANGEPLAINLOOSE]}$`),b("COMPARATORLOOSE",`^${d[u.GTLT]}\\s*(${d[u.LOOSEPLAIN]})$|^$`),b("COMPARATOR",`^${d[u.GTLT]}\\s*(${d[u.FULLPLAIN]})$|^$`),b("COMPARATORTRIM",`(\\s*)${d[u.GTLT]}\\s*(${d[u.LOOSEPLAIN]}|${d[u.XRANGEPLAIN]})`,!0),e.comparatorTrimReplace="$1$2$3",b("HYPHENRANGE",`^\\s*(${d[u.XRANGEPLAIN]})\\s+-\\s+(${d[u.XRANGEPLAIN]})\\s*$`),b("HYPHENRANGELOOSE",`^\\s*(${d[u.XRANGEPLAINLOOSE]})\\s+-\\s+(${d[u.XRANGEPLAINLOOSE]})\\s*$`),b("STAR","(<|>)?=?\\s*\\*"),b("GTE0","^\\s*>=\\s*0\\.0\\.0\\s*$"),b("GTE0PRE","^\\s*>=\\s*0\\.0\\.0-0\\s*$")}(y0,y0.exports)),y0.exports}var jy,Rx;function c6(){if(Rx)return jy;Rx=1;const r=Object.freeze({loose:!0}),e=Object.freeze({});return jy=n=>n?typeof n!="object"?r:n:e,jy}var zy,Px;function eR(){if(Px)return zy;Px=1;const r=/^[0-9]+$/,e=(n,i)=>{const o=r.test(n),a=r.test(i);return o&&a&&(n=+n,i=+i),n===i?0:o&&!a?-1:a&&!o?1:n<i?-1:1};return zy={compareIdentifiers:e,rcompareIdentifiers:(n,i)=>e(i,n)},zy}var By,Mx;function ji(){if(Mx)return By;Mx=1;const r=a4(),{MAX_LENGTH:e,MAX_SAFE_INTEGER:t}=o4(),{safeRe:n,safeSrc:i,t:o}=Rm(),a=c6(),{compareIdentifiers:c}=eR();class d{constructor(u,p){if(p=a(p),u instanceof d){if(u.loose===!!p.loose&&u.includePrerelease===!!p.includePrerelease)return u;u=u.version}else if(typeof u!="string")throw new TypeError(`Invalid version. Must be a string. Got type "${typeof u}".`);if(u.length>e)throw new TypeError(`version is longer than ${e} characters`);r("SemVer",u,p),this.options=p,this.loose=!!p.loose,this.includePrerelease=!!p.includePrerelease;const v=u.trim().match(p.loose?n[o.LOOSE]:n[o.FULL]);if(!v)throw new TypeError(`Invalid Version: ${u}`);if(this.raw=u,this.major=+v[1],this.minor=+v[2],this.patch=+v[3],this.major>t||this.major<0)throw new TypeError("Invalid major version");if(this.minor>t||this.minor<0)throw new TypeError("Invalid minor version");if(this.patch>t||this.patch<0)throw new TypeError("Invalid patch version");v[4]?this.prerelease=v[4].split(".").map(g=>{if(/^[0-9]+$/.test(g)){const _=+g;if(_>=0&&_<t)return _}return g}):this.prerelease=[],this.build=v[5]?v[5].split("."):[],this.format()}format(){return this.version=`${this.major}.${this.minor}.${this.patch}`,this.prerelease.length&&(this.version+=`-${this.prerelease.join(".")}`),this.version}toString(){return this.version}compare(u){if(r("SemVer.compare",this.version,this.options,u),!(u instanceof d)){if(typeof u=="string"&&u===this.version)return 0;u=new d(u,this.options)}return u.version===this.version?0:this.compareMain(u)||this.comparePre(u)}compareMain(u){return u instanceof d||(u=new d(u,this.options)),c(this.major,u.major)||c(this.minor,u.minor)||c(this.patch,u.patch)}comparePre(u){if(u instanceof d||(u=new d(u,this.options)),this.prerelease.length&&!u.prerelease.length)return-1;if(!this.prerelease.length&&u.prerelease.length)return 1;if(!this.prerelease.length&&!u.prerelease.length)return 0;let p=0;do{const v=this.prerelease[p],g=u.prerelease[p];if(r("prerelease compare",p,v,g),v===void 0&&g===void 0)return 0;if(g===void 0)return 1;if(v===void 0)return-1;if(v===g)continue;return c(v,g)}while(++p)}compareBuild(u){u instanceof d||(u=new d(u,this.options));let p=0;do{const v=this.build[p],g=u.build[p];if(r("build compare",p,v,g),v===void 0&&g===void 0)return 0;if(g===void 0)return 1;if(v===void 0)return-1;if(v===g)continue;return c(v,g)}while(++p)}inc(u,p,v){if(u.startsWith("pre")){if(!p&&v===!1)throw new Error("invalid increment argument: identifier is empty");if(p){const g=new RegExp(`^${this.options.loose?i[o.PRERELEASELOOSE]:i[o.PRERELEASE]}$`),_=`-${p}`.match(g);if(!_||_[1]!==p)throw new Error(`invalid identifier: ${p}`)}}switch(u){case"premajor":this.prerelease.length=0,this.patch=0,this.minor=0,this.major++,this.inc("pre",p,v);break;case"preminor":this.prerelease.length=0,this.patch=0,this.minor++,this.inc("pre",p,v);break;case"prepatch":this.prerelease.length=0,this.inc("patch",p,v),this.inc("pre",p,v);break;case"prerelease":this.prerelease.length===0&&this.inc("patch",p,v),this.inc("pre",p,v);break;case"release":if(this.prerelease.length===0)throw new Error(`version ${this.raw} is not a prerelease`);this.prerelease.length=0;break;case"major":(this.minor!==0||this.patch!==0||this.prerelease.length===0)&&this.major++,this.minor=0,this.patch=0,this.prerelease=[];break;case"minor":(this.patch!==0||this.prerelease.length===0)&&this.minor++,this.patch=0,this.prerelease=[];break;case"patch":this.prerelease.length===0&&this.patch++,this.prerelease=[];break;case"pre":{const g=Number(v)?1:0;if(this.prerelease.length===0)this.prerelease=[g];else{let _=this.prerelease.length;for(;--_>=0;)typeof this.prerelease[_]=="number"&&(this.prerelease[_]++,_=-2);if(_===-1){if(p===this.prerelease.join(".")&&v===!1)throw new Error("invalid increment argument: identifier already exists");this.prerelease.push(g)}}if(p){let _=[p,g];v===!1&&(_=[p]),c(this.prerelease[0],p)===0?isNaN(this.prerelease[1])&&(this.prerelease=_):this.prerelease=_}break}default:throw new Error(`invalid increment argument: ${u}`)}return this.raw=this.format(),this.build.length&&(this.raw+=`+${this.build.join(".")}`),this}}return By=d,By}var Uy,$x;function Nf(){if($x)return Uy;$x=1;const r=ji();return Uy=(t,n,i=!1)=>{if(t instanceof r)return t;try{return new r(t,n)}catch(o){if(!i)return null;throw o}},Uy}var qy,Ox;function mH(){if(Ox)return qy;Ox=1;const r=Nf();return qy=(t,n)=>{const i=r(t,n);return i?i.version:null},qy}var Wy,Zx;function vH(){if(Zx)return Wy;Zx=1;const r=Nf();return Wy=(t,n)=>{const i=r(t.trim().replace(/^[=v]+/,""),n);return i?i.version:null},Wy}var Gy,Lx;function gH(){if(Lx)return Gy;Lx=1;const r=ji();return Gy=(t,n,i,o,a)=>{typeof i=="string"&&(a=o,o=i,i=void 0);try{return new r(t instanceof r?t.version:t,i).inc(n,o,a).version}catch{return null}},Gy}var Ky,Hx;function yH(){if(Hx)return Ky;Hx=1;const r=Nf();return Ky=(t,n)=>{const i=r(t,null,!0),o=r(n,null,!0),a=i.compare(o);if(a===0)return null;const c=a>0,d=c?i:o,h=c?o:i,u=!!d.prerelease.length;if(!!h.prerelease.length&&!u){if(!h.patch&&!h.minor)return"major";if(h.compareMain(d)===0)return h.minor&&!h.patch?"minor":"patch"}const v=u?"pre":"";return i.major!==o.major?v+"major":i.minor!==o.minor?v+"minor":i.patch!==o.patch?v+"patch":"prerelease"},Ky}var Yy,Nx;function _H(){if(Nx)return Yy;Nx=1;const r=ji();return Yy=(t,n)=>new r(t,n).major,Yy}var Qy,Dx;function bH(){if(Dx)return Qy;Dx=1;const r=ji();return Qy=(t,n)=>new r(t,n).minor,Qy}var Xy,Vx;function wH(){if(Vx)return Xy;Vx=1;const r=ji();return Xy=(t,n)=>new r(t,n).patch,Xy}var Jy,Fx;function xH(){if(Fx)return Jy;Fx=1;const r=Nf();return Jy=(t,n)=>{const i=r(t,n);return i&&i.prerelease.length?i.prerelease:null},Jy}var e3,jx;function Fa(){if(jx)return e3;jx=1;const r=ji();return e3=(t,n,i)=>new r(t,i).compare(new r(n,i)),e3}var t3,zx;function CH(){if(zx)return t3;zx=1;const r=Fa();return t3=(t,n,i)=>r(n,t,i),t3}var r3,Bx;function kH(){if(Bx)return r3;Bx=1;const r=Fa();return r3=(t,n)=>r(t,n,!0),r3}var n3,Ux;function l6(){if(Ux)return n3;Ux=1;const r=ji();return n3=(t,n,i)=>{const o=new r(t,i),a=new r(n,i);return o.compare(a)||o.compareBuild(a)},n3}var i3,qx;function EH(){if(qx)return i3;qx=1;const r=l6();return i3=(t,n)=>t.sort((i,o)=>r(i,o,n)),i3}var o3,Wx;function SH(){if(Wx)return o3;Wx=1;const r=l6();return o3=(t,n)=>t.sort((i,o)=>r(o,i,n)),o3}var a3,Gx;function s4(){if(Gx)return a3;Gx=1;const r=Fa();return a3=(t,n,i)=>r(t,n,i)>0,a3}var s3,Kx;function d6(){if(Kx)return s3;Kx=1;const r=Fa();return s3=(t,n,i)=>r(t,n,i)<0,s3}var c3,Yx;function tR(){if(Yx)return c3;Yx=1;const r=Fa();return c3=(t,n,i)=>r(t,n,i)===0,c3}var l3,Qx;function rR(){if(Qx)return l3;Qx=1;const r=Fa();return l3=(t,n,i)=>r(t,n,i)!==0,l3}var d3,Xx;function u6(){if(Xx)return d3;Xx=1;const r=Fa();return d3=(t,n,i)=>r(t,n,i)>=0,d3}var u3,Jx;function h6(){if(Jx)return u3;Jx=1;const r=Fa();return u3=(t,n,i)=>r(t,n,i)<=0,u3}var h3,eC;function nR(){if(eC)return h3;eC=1;const r=tR(),e=rR(),t=s4(),n=u6(),i=d6(),o=h6();return h3=(c,d,h,u)=>{switch(d){case"===":return typeof c=="object"&&(c=c.version),typeof h=="object"&&(h=h.version),c===h;case"!==":return typeof c=="object"&&(c=c.version),typeof h=="object"&&(h=h.version),c!==h;case"":case"=":case"==":return r(c,h,u);case"!=":return e(c,h,u);case">":return t(c,h,u);case">=":return n(c,h,u);case"<":return i(c,h,u);case"<=":return o(c,h,u);default:throw new TypeError(`Invalid operator: ${d}`)}},h3}var f3,tC;function TH(){if(tC)return f3;tC=1;const r=ji(),e=Nf(),{safeRe:t,t:n}=Rm();return f3=(o,a)=>{if(o instanceof r)return o;if(typeof o=="number"&&(o=String(o)),typeof o!="string")return null;a=a||{};let c=null;if(!a.rtl)c=o.match(a.includePrerelease?t[n.COERCEFULL]:t[n.COERCE]);else{const g=a.includePrerelease?t[n.COERCERTLFULL]:t[n.COERCERTL];let _;for(;(_=g.exec(o))&&(!c||c.index+c[0].length!==o.length);)(!c||_.index+_[0].length!==c.index+c[0].length)&&(c=_),g.lastIndex=_.index+_[1].length+_[2].length;g.lastIndex=-1}if(c===null)return null;const d=c[2],h=c[3]||"0",u=c[4]||"0",p=a.includePrerelease&&c[5]?`-${c[5]}`:"",v=a.includePrerelease&&c[6]?`+${c[6]}`:"";return e(`${d}.${h}.${u}${p}${v}`,a)},f3}var p3,rC;function AH(){if(rC)return p3;rC=1;class r{constructor(){this.max=1e3,this.map=new Map}get(t){const n=this.map.get(t);if(n!==void 0)return this.map.delete(t),this.map.set(t,n),n}delete(t){return this.map.delete(t)}set(t,n){if(!this.delete(t)&&n!==void 0){if(this.map.size>=this.max){const o=this.map.keys().next().value;this.delete(o)}this.map.set(t,n)}return this}}return p3=r,p3}var m3,nC;function ja(){if(nC)return m3;nC=1;const r=/\s+/g;class e{constructor(K,re){if(re=i(re),K instanceof e)return K.loose===!!re.loose&&K.includePrerelease===!!re.includePrerelease?K:new e(K.raw,re);if(K instanceof o)return this.raw=K.value,this.set=[[K]],this.formatted=void 0,this;if(this.options=re,this.loose=!!re.loose,this.includePrerelease=!!re.includePrerelease,this.raw=K.trim().replace(r," "),this.set=this.raw.split("||").map(q=>this.parseRange(q.trim())).filter(q=>q.length),!this.set.length)throw new TypeError(`Invalid SemVer Range: ${this.raw}`);if(this.set.length>1){const q=this.set[0];if(this.set=this.set.filter($=>!b($[0])),this.set.length===0)this.set=[q];else if(this.set.length>1){for(const $ of this.set)if($.length===1&&C($[0])){this.set=[$];break}}}this.formatted=void 0}get range(){if(this.formatted===void 0){this.formatted="";for(let K=0;K<this.set.length;K++){K>0&&(this.formatted+="||");const re=this.set[K];for(let q=0;q<re.length;q++)q>0&&(this.formatted+=" "),this.formatted+=re[q].toString().trim()}}return this.formatted}format(){return this.range}toString(){return this.range}parseRange(K){const q=((this.options.includePrerelease&&g)|(this.options.loose&&_))+":"+K,$=n.get(q);if($)return $;const O=this.options.loose,H=O?d[h.HYPHENRANGELOOSE]:d[h.HYPHENRANGE];K=K.replace(H,we(this.options.includePrerelease)),a("hyphen replace",K),K=K.replace(d[h.COMPARATORTRIM],u),a("comparator trim",K),K=K.replace(d[h.TILDETRIM],p),a("tilde trim",K),K=K.replace(d[h.CARETTRIM],v),a("caret trim",K);let P=K.split(" ").map(Ie=>S(Ie,this.options)).join(" ").split(/\s+/).map(Ie=>Ee(Ie,this.options));O&&(P=P.filter(Ie=>(a("loose invalid filter",Ie,this.options),!!Ie.match(d[h.COMPARATORLOOSE])))),a("range list",P);const N=new Map,ye=P.map(Ie=>new o(Ie,this.options));for(const Ie of ye){if(b(Ie))return[Ie];N.set(Ie.value,Ie)}N.size>1&&N.has("")&&N.delete("");const Pe=[...N.values()];return n.set(q,Pe),Pe}intersects(K,re){if(!(K instanceof e))throw new TypeError("a Range is required");return this.set.some(q=>T(q,re)&&K.set.some($=>T($,re)&&q.every(O=>$.every(H=>O.intersects(H,re)))))}test(K){if(!K)return!1;if(typeof K=="string")try{K=new c(K,this.options)}catch{return!1}for(let re=0;re<this.set.length;re++)if(Ce(this.set[re],K,this.options))return!0;return!1}}m3=e;const t=AH(),n=new t,i=c6(),o=c4(),a=a4(),c=ji(),{safeRe:d,t:h,comparatorTrimReplace:u,tildeTrimReplace:p,caretTrimReplace:v}=Rm(),{FLAG_INCLUDE_PRERELEASE:g,FLAG_LOOSE:_}=o4(),b=J=>J.value==="<0.0.0-0",C=J=>J.value==="",T=(J,K)=>{let re=!0;const q=J.slice();let $=q.pop();for(;re&&q.length;)re=q.every(O=>$.intersects(O,K)),$=q.pop();return re},S=(J,K)=>(a("comp",J,K),J=U(J,K),a("caret",J),J=Z(J,K),a("tildes",J),J=Y(J,K),a("xrange",J),J=de(J,K),a("stars",J),J),A=J=>!J||J.toLowerCase()==="x"||J==="*",Z=(J,K)=>J.trim().split(/\s+/).map(re=>B(re,K)).join(" "),B=(J,K)=>{const re=K.loose?d[h.TILDELOOSE]:d[h.TILDE];return J.replace(re,(q,$,O,H,P)=>{a("tilde",J,q,$,O,H,P);let N;return A($)?N="":A(O)?N=`>=${$}.0.0 <${+$+1}.0.0-0`:A(H)?N=`>=${$}.${O}.0 <${$}.${+O+1}.0-0`:P?(a("replaceTilde pr",P),N=`>=${$}.${O}.${H}-${P} <${$}.${+O+1}.0-0`):N=`>=${$}.${O}.${H} <${$}.${+O+1}.0-0`,a("tilde return",N),N})},U=(J,K)=>J.trim().split(/\s+/).map(re=>I(re,K)).join(" "),I=(J,K)=>{a("caret",J,K);const re=K.loose?d[h.CARETLOOSE]:d[h.CARET],q=K.includePrerelease?"-0":"";return J.replace(re,($,O,H,P,N)=>{a("caret",J,$,O,H,P,N);let ye;return A(O)?ye="":A(H)?ye=`>=${O}.0.0${q} <${+O+1}.0.0-0`:A(P)?O==="0"?ye=`>=${O}.${H}.0${q} <${O}.${+H+1}.0-0`:ye=`>=${O}.${H}.0${q} <${+O+1}.0.0-0`:N?(a("replaceCaret pr",N),O==="0"?H==="0"?ye=`>=${O}.${H}.${P}-${N} <${O}.${H}.${+P+1}-0`:ye=`>=${O}.${H}.${P}-${N} <${O}.${+H+1}.0-0`:ye=`>=${O}.${H}.${P}-${N} <${+O+1}.0.0-0`):(a("no pr"),O==="0"?H==="0"?ye=`>=${O}.${H}.${P}${q} <${O}.${H}.${+P+1}-0`:ye=`>=${O}.${H}.${P}${q} <${O}.${+H+1}.0-0`:ye=`>=${O}.${H}.${P} <${+O+1}.0.0-0`),a("caret return",ye),ye})},Y=(J,K)=>(a("replaceXRanges",J,K),J.split(/\s+/).map(re=>le(re,K)).join(" ")),le=(J,K)=>{J=J.trim();const re=K.loose?d[h.XRANGELOOSE]:d[h.XRANGE];return J.replace(re,(q,$,O,H,P,N)=>{a("xRange",J,q,$,O,H,P,N);const ye=A(O),Pe=ye||A(H),Ie=Pe||A(P),Te=Ie;return $==="="&&Te&&($=""),N=K.includePrerelease?"-0":"",ye?$===">"||$==="<"?q="<0.0.0-0":q="*":$&&Te?(Pe&&(H=0),P=0,$===">"?($=">=",Pe?(O=+O+1,H=0,P=0):(H=+H+1,P=0)):$==="<="&&($="<",Pe?O=+O+1:H=+H+1),$==="<"&&(N="-0"),q=`${$+O}.${H}.${P}${N}`):Pe?q=`>=${O}.0.0${N} <${+O+1}.0.0-0`:Ie&&(q=`>=${O}.${H}.0${N} <${O}.${+H+1}.0-0`),a("xRange return",q),q})},de=(J,K)=>(a("replaceStars",J,K),J.trim().replace(d[h.STAR],"")),Ee=(J,K)=>(a("replaceGTE0",J,K),J.trim().replace(d[K.includePrerelease?h.GTE0PRE:h.GTE0],"")),we=J=>(K,re,q,$,O,H,P,N,ye,Pe,Ie,Te)=>(A(q)?re="":A($)?re=`>=${q}.0.0${J?"-0":""}`:A(O)?re=`>=${q}.${$}.0${J?"-0":""}`:H?re=`>=${re}`:re=`>=${re}${J?"-0":""}`,A(ye)?N="":A(Pe)?N=`<${+ye+1}.0.0-0`:A(Ie)?N=`<${ye}.${+Pe+1}.0-0`:Te?N=`<=${ye}.${Pe}.${Ie}-${Te}`:J?N=`<${ye}.${Pe}.${+Ie+1}-0`:N=`<=${N}`,`${re} ${N}`.trim()),Ce=(J,K,re)=>{for(let q=0;q<J.length;q++)if(!J[q].test(K))return!1;if(K.prerelease.length&&!re.includePrerelease){for(let q=0;q<J.length;q++)if(a(J[q].semver),J[q].semver!==o.ANY&&J[q].semver.prerelease.length>0){const $=J[q].semver;if($.major===K.major&&$.minor===K.minor&&$.patch===K.patch)return!0}return!1}return!0};return m3}var v3,iC;function c4(){if(iC)return v3;iC=1;const r=Symbol("SemVer ANY");class e{static get ANY(){return r}constructor(u,p){if(p=t(p),u instanceof e){if(u.loose===!!p.loose)return u;u=u.value}u=u.trim().split(/\s+/).join(" "),a("comparator",u,p),this.options=p,this.loose=!!p.loose,this.parse(u),this.semver===r?this.value="":this.value=this.operator+this.semver.version,a("comp",this)}parse(u){const p=this.options.loose?n[i.COMPARATORLOOSE]:n[i.COMPARATOR],v=u.match(p);if(!v)throw new TypeError(`Invalid comparator: ${u}`);this.operator=v[1]!==void 0?v[1]:"",this.operator==="="&&(this.operator=""),v[2]?this.semver=new c(v[2],this.options.loose):this.semver=r}toString(){return this.value}test(u){if(a("Comparator.test",u,this.options.loose),this.semver===r||u===r)return!0;if(typeof u=="string")try{u=new c(u,this.options)}catch{return!1}return o(u,this.operator,this.semver,this.options)}intersects(u,p){if(!(u instanceof e))throw new TypeError("a Comparator is required");return this.operator===""?this.value===""?!0:new d(u.value,p).test(this.value):u.operator===""?u.value===""?!0:new d(this.value,p).test(u.semver):(p=t(p),p.includePrerelease&&(this.value==="<0.0.0-0"||u.value==="<0.0.0-0")||!p.includePrerelease&&(this.value.startsWith("<0.0.0")||u.value.startsWith("<0.0.0"))?!1:!!(this.operator.startsWith(">")&&u.operator.startsWith(">")||this.operator.startsWith("<")&&u.operator.startsWith("<")||this.semver.version===u.semver.version&&this.operator.includes("=")&&u.operator.includes("=")||o(this.semver,"<",u.semver,p)&&this.operator.startsWith(">")&&u.operator.startsWith("<")||o(this.semver,">",u.semver,p)&&this.operator.startsWith("<")&&u.operator.startsWith(">")))}}v3=e;const t=c6(),{safeRe:n,t:i}=Rm(),o=nR(),a=a4(),c=ji(),d=ja();return v3}var g3,oC;function l4(){if(oC)return g3;oC=1;const r=ja();return g3=(t,n,i)=>{try{n=new r(n,i)}catch{return!1}return n.test(t)},g3}var y3,aC;function IH(){if(aC)return y3;aC=1;const r=ja();return y3=(t,n)=>new r(t,n).set.map(i=>i.map(o=>o.value).join(" ").trim().split(" ")),y3}var _3,sC;function RH(){if(sC)return _3;sC=1;const r=ji(),e=ja();return _3=(n,i,o)=>{let a=null,c=null,d=null;try{d=new e(i,o)}catch{return null}return n.forEach(h=>{d.test(h)&&(!a||c.compare(h)===-1)&&(a=h,c=new r(a,o))}),a},_3}var b3,cC;function PH(){if(cC)return b3;cC=1;const r=ji(),e=ja();return b3=(n,i,o)=>{let a=null,c=null,d=null;try{d=new e(i,o)}catch{return null}return n.forEach(h=>{d.test(h)&&(!a||c.compare(h)===1)&&(a=h,c=new r(a,o))}),a},b3}var w3,lC;function MH(){if(lC)return w3;lC=1;const r=ji(),e=ja(),t=s4();return w3=(i,o)=>{i=new e(i,o);let a=new r("0.0.0");if(i.test(a)||(a=new r("0.0.0-0"),i.test(a)))return a;a=null;for(let c=0;c<i.set.length;++c){const d=i.set[c];let h=null;d.forEach(u=>{const p=new r(u.semver.version);switch(u.operator){case">":p.prerelease.length===0?p.patch++:p.prerelease.push(0),p.raw=p.format();case"":case">=":(!h||t(p,h))&&(h=p);break;case"<":case"<=":break;default:throw new Error(`Unexpected operation: ${u.operator}`)}}),h&&(!a||t(a,h))&&(a=h)}return a&&i.test(a)?a:null},w3}var x3,dC;function $H(){if(dC)return x3;dC=1;const r=ja();return x3=(t,n)=>{try{return new r(t,n).range||"*"}catch{return null}},x3}var C3,uC;function f6(){if(uC)return C3;uC=1;const r=ji(),e=c4(),{ANY:t}=e,n=ja(),i=l4(),o=s4(),a=d6(),c=h6(),d=u6();return C3=(u,p,v,g)=>{u=new r(u,g),p=new n(p,g);let _,b,C,T,S;switch(v){case">":_=o,b=c,C=a,T=">",S=">=";break;case"<":_=a,b=d,C=o,T="<",S="<=";break;default:throw new TypeError('Must provide a hilo val of "<" or ">"')}if(i(u,p,g))return!1;for(let A=0;A<p.set.length;++A){const Z=p.set[A];let B=null,U=null;if(Z.forEach(I=>{I.semver===t&&(I=new e(">=0.0.0")),B=B||I,U=U||I,_(I.semver,B.semver,g)?B=I:C(I.semver,U.semver,g)&&(U=I)}),B.operator===T||B.operator===S||(!U.operator||U.operator===T)&&b(u,U.semver))return!1;if(U.operator===S&&C(u,U.semver))return!1}return!0},C3}var k3,hC;function OH(){if(hC)return k3;hC=1;const r=f6();return k3=(t,n,i)=>r(t,n,">",i),k3}var E3,fC;function ZH(){if(fC)return E3;fC=1;const r=f6();return E3=(t,n,i)=>r(t,n,"<",i),E3}var S3,pC;function LH(){if(pC)return S3;pC=1;const r=ja();return S3=(t,n,i)=>(t=new r(t,i),n=new r(n,i),t.intersects(n,i)),S3}var T3,mC;function HH(){if(mC)return T3;mC=1;const r=l4(),e=Fa();return T3=(t,n,i)=>{const o=[];let a=null,c=null;const d=t.sort((v,g)=>e(v,g,i));for(const v of d)r(v,n,i)?(c=v,a||(a=v)):(c&&o.push([a,c]),c=null,a=null);a&&o.push([a,null]);const h=[];for(const[v,g]of o)v===g?h.push(v):!g&&v===d[0]?h.push("*"):g?v===d[0]?h.push(`<=${g}`):h.push(`${v} - ${g}`):h.push(`>=${v}`);const u=h.join(" || "),p=typeof n.raw=="string"?n.raw:String(n);return u.length<p.length?u:n},T3}var A3,vC;function NH(){if(vC)return A3;vC=1;const r=ja(),e=c4(),{ANY:t}=e,n=l4(),i=Fa(),o=(p,v,g={})=>{if(p===v)return!0;p=new r(p,g),v=new r(v,g);let _=!1;e:for(const b of p.set){for(const C of v.set){const T=d(b,C,g);if(_=_||T!==null,T)continue e}if(_)return!1}return!0},a=[new e(">=0.0.0-0")],c=[new e(">=0.0.0")],d=(p,v,g)=>{if(p===v)return!0;if(p.length===1&&p[0].semver===t){if(v.length===1&&v[0].semver===t)return!0;g.includePrerelease?p=a:p=c}if(v.length===1&&v[0].semver===t){if(g.includePrerelease)return!0;v=c}const _=new Set;let b,C;for(const Y of p)Y.operator===">"||Y.operator===">="?b=h(b,Y,g):Y.operator==="<"||Y.operator==="<="?C=u(C,Y,g):_.add(Y.semver);if(_.size>1)return null;let T;if(b&&C){if(T=i(b.semver,C.semver,g),T>0)return null;if(T===0&&(b.operator!==">="||C.operator!=="<="))return null}for(const Y of _){if(b&&!n(Y,String(b),g)||C&&!n(Y,String(C),g))return null;for(const le of v)if(!n(Y,String(le),g))return!1;return!0}let S,A,Z,B,U=C&&!g.includePrerelease&&C.semver.prerelease.length?C.semver:!1,I=b&&!g.includePrerelease&&b.semver.prerelease.length?b.semver:!1;U&&U.prerelease.length===1&&C.operator==="<"&&U.prerelease[0]===0&&(U=!1);for(const Y of v){if(B=B||Y.operator===">"||Y.operator===">=",Z=Z||Y.operator==="<"||Y.operator==="<=",b){if(I&&Y.semver.prerelease&&Y.semver.prerelease.length&&Y.semver.major===I.major&&Y.semver.minor===I.minor&&Y.semver.patch===I.patch&&(I=!1),Y.operator===">"||Y.operator===">="){if(S=h(b,Y,g),S===Y&&S!==b)return!1}else if(b.operator===">="&&!n(b.semver,String(Y),g))return!1}if(C){if(U&&Y.semver.prerelease&&Y.semver.prerelease.length&&Y.semver.major===U.major&&Y.semver.minor===U.minor&&Y.semver.patch===U.patch&&(U=!1),Y.operator==="<"||Y.operator==="<="){if(A=u(C,Y,g),A===Y&&A!==C)return!1}else if(C.operator==="<="&&!n(C.semver,String(Y),g))return!1}if(!Y.operator&&(C||b)&&T!==0)return!1}return!(b&&Z&&!C&&T!==0||C&&B&&!b&&T!==0||I||U)},h=(p,v,g)=>{if(!p)return v;const _=i(p.semver,v.semver,g);return _>0?p:_<0||v.operator===">"&&p.operator===">="?v:p},u=(p,v,g)=>{if(!p)return v;const _=i(p.semver,v.semver,g);return _<0?p:_>0||v.operator==="<"&&p.operator==="<="?v:p};return A3=o,A3}var I3,gC;function DH(){if(gC)return I3;gC=1;const r=Rm(),e=o4(),t=ji(),n=eR(),i=Nf(),o=mH(),a=vH(),c=gH(),d=yH(),h=_H(),u=bH(),p=wH(),v=xH(),g=Fa(),_=CH(),b=kH(),C=l6(),T=EH(),S=SH(),A=s4(),Z=d6(),B=tR(),U=rR(),I=u6(),Y=h6(),le=nR(),de=TH(),Ee=c4(),we=ja(),Ce=l4(),J=IH(),K=RH(),re=PH(),q=MH(),$=$H(),O=f6(),H=OH(),P=ZH(),N=LH(),ye=HH(),Pe=NH();return I3={parse:i,valid:o,clean:a,inc:c,diff:d,major:h,minor:u,patch:p,prerelease:v,compare:g,rcompare:_,compareLoose:b,compareBuild:C,sort:T,rsort:S,gt:A,lt:Z,eq:B,neq:U,gte:I,lte:Y,cmp:le,coerce:de,Comparator:Ee,Range:we,satisfies:Ce,toComparators:J,maxSatisfying:K,minSatisfying:re,minVersion:q,validRange:$,outside:O,gtr:H,ltr:P,intersects:N,simplifyRange:ye,subset:Pe,SemVer:t,re:r.re,src:r.src,tokens:r.t,SEMVER_SPEC_VERSION:e.SEMVER_SPEC_VERSION,RELEASE_TYPES:e.RELEASE_TYPES,compareIdentifiers:n.compareIdentifiers,rcompareIdentifiers:n.rcompareIdentifiers},I3}var _b=DH();const ep=Hu(_b);class fs extends _b.SemVer{satisfies(e){return _b.satisfies(this,e)}}var VH={};let FH=class{constructor(e){this.domain=e,this.level=Number(VH.FUSION_LOG_LEVEL)||1}_createMessage(e){return[`%c FUSION FRAMEWORK %c ${this.domain} %c %s`,"background: rgb(179, 13, 47); color: white; padding: 1px;","background: rgb(244, 244, 244); color: rgb(36, 55, 70); padding: 1px;","background: none; color: inherit",...e.reduce((t,n)=>[...t,n,`
41
- `],[])]}debug(...e){this.level>3&&console.debug(...this._createMessage(e))}info(...e){this.level>2&&console.info(...this._createMessage(e))}warn(...e){this.level>1&&console.warn(...this._createMessage(e))}error(...e){this.level>0&&console.error(...this._createMessage(e))}};class iR extends FH{formatModuleName(e){return`📦\x1B[1;32m${(typeof e=="string"?e:e.name).replace(/([A-Z])/g," $1").toUpperCase()}\x1B[0m`}}var bb=function(r,e){return bb=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,n){t.__proto__=n}||function(t,n){for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(t[i]=n[i])},bb(r,e)};function Si(r,e){if(typeof e!="function"&&e!==null)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");bb(r,e);function t(){this.constructor=r}r.prototype=e===null?Object.create(e):(t.prototype=e.prototype,new t)}var Sn=function(){return Sn=Object.assign||function(e){for(var t,n=1,i=arguments.length;n<i;n++){t=arguments[n];for(var o in t)Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o])}return e},Sn.apply(this,arguments)};function oR(r,e){var t={};for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&e.indexOf(n)<0&&(t[n]=r[n]);if(r!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,n=Object.getOwnPropertySymbols(r);i<n.length;i++)e.indexOf(n[i])<0&&Object.prototype.propertyIsEnumerable.call(r,n[i])&&(t[n[i]]=r[n[i]]);return t}function R(r,e,t,n){var i=arguments.length,o=i<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,t):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(r,e,t,n);else for(var c=r.length-1;c>=0;c--)(a=r[c])&&(o=(i<3?a(o):i>3?a(e,t,o):a(e,t))||o);return i>3&&o&&Object.defineProperty(e,t,o),o}function uc(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})}function aR(r,e){var t={label:0,sent:function(){if(o[0]&1)throw o[1];return o[1]},trys:[],ops:[]},n,i,o,a=Object.create((typeof Iterator=="function"?Iterator:Object).prototype);return a.next=c(0),a.throw=c(1),a.return=c(2),typeof Symbol=="function"&&(a[Symbol.iterator]=function(){return this}),a;function c(h){return function(u){return d([h,u])}}function d(h){if(n)throw new TypeError("Generator is already executing.");for(;a&&(a=0,h[0]&&(t=0)),t;)try{if(n=1,i&&(o=h[0]&2?i.return:h[0]?i.throw||((o=i.return)&&o.call(i),0):i.next)&&!(o=o.call(i,h[1])).done)return o;switch(i=0,o&&(h=[h[0]&2,o.value]),h[0]){case 0:case 1:o=h;break;case 4:return t.label++,{value:h[1],done:!1};case 5:t.label++,i=h[1],h=[0];continue;case 7:h=t.ops.pop(),t.trys.pop();continue;default:if(o=t.trys,!(o=o.length>0&&o[o.length-1])&&(h[0]===6||h[0]===2)){t=0;continue}if(h[0]===3&&(!o||h[1]>o[0]&&h[1]<o[3])){t.label=h[1];break}if(h[0]===6&&t.label<o[1]){t.label=o[1],o=h;break}if(o&&t.label<o[2]){t.label=o[2],t.ops.push(h);break}o[2]&&t.ops.pop(),t.trys.pop();continue}h=e.call(r,t)}catch(u){h=[6,u],i=0}finally{n=o=0}if(h[0]&5)throw h[1];return{value:h[0]?h[1]:void 0,done:!0}}}function Di(r){var e=typeof Symbol=="function"&&Symbol.iterator,t=e&&r[e],n=0;if(t)return t.call(r);if(r&&typeof r.length=="number")return{next:function(){return r&&n>=r.length&&(r=void 0),{value:r&&r[n++],done:!r}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")}function ys(r,e){var t=typeof Symbol=="function"&&r[Symbol.iterator];if(!t)return r;var n=t.call(r),i,o=[],a;try{for(;(e===void 0||e-- >0)&&!(i=n.next()).done;)o.push(i.value)}catch(c){a={error:c}}finally{try{i&&!i.done&&(t=n.return)&&t.call(n)}finally{if(a)throw a.error}}return o}function vc(r,e,t){if(t||arguments.length===2)for(var n=0,i=e.length,o;n<i;n++)(o||!(n in e))&&(o||(o=Array.prototype.slice.call(e,0,n)),o[n]=e[n]);return r.concat(o||Array.prototype.slice.call(e))}function of(r){return this instanceof of?(this.v=r,this):new of(r)}function jH(r,e,t){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var n=t.apply(r,e||[]),i,o=[];return i=Object.create((typeof AsyncIterator=="function"?AsyncIterator:Object).prototype),c("next"),c("throw"),c("return",a),i[Symbol.asyncIterator]=function(){return this},i;function a(g){return function(_){return Promise.resolve(_).then(g,p)}}function c(g,_){n[g]&&(i[g]=function(b){return new Promise(function(C,T){o.push([g,b,C,T])>1||d(g,b)})},_&&(i[g]=_(i[g])))}function d(g,_){try{h(n[g](_))}catch(b){v(o[0][3],b)}}function h(g){g.value instanceof of?Promise.resolve(g.value.v).then(u,p):v(o[0][2],g)}function u(g){d("next",g)}function p(g){d("throw",g)}function v(g,_){g(_),o.shift(),o.length&&d(o[0][0],o[0][1])}}function zH(r){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var e=r[Symbol.asyncIterator],t;return e?e.call(r):(r=typeof Di=="function"?Di(r):r[Symbol.iterator](),t={},n("next"),n("throw"),n("return"),t[Symbol.asyncIterator]=function(){return this},t);function n(o){t[o]=r[o]&&function(a){return new Promise(function(c,d){a=r[o](a),i(c,d,a.done,a.value)})}}function i(o,a,c,d){Promise.resolve(d).then(function(h){o({value:h,done:c})},a)}}function Ae(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)}function ic(r,e,t,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?r!==e||!i:!e.has(r))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(r,t):i?i.value=t:e.set(r,t),t}function gr(r){return typeof r=="function"}function d4(r){var e=function(n){Error.call(n),n.stack=new Error().stack},t=r(e);return t.prototype=Object.create(Error.prototype),t.prototype.constructor=t,t}var R3=d4(function(r){return function(t){r(this),this.message=t?t.length+` errors occurred during unsubscription:
40
+ `+w.stack}return{value:s,source:l,stack:y,digest:null}}function iy(s,l,f){return{value:s,source:null,stack:f??null,digest:l??null}}function oy(s,l){try{console.error(l.value)}catch(f){setTimeout(function(){throw f})}}var ML=typeof WeakMap=="function"?WeakMap:Map;function T7(s,l,f){f=Fs(-1,f),f.tag=3,f.payload={element:null};var m=l.value;return f.callback=function(){r0||(r0=!0,by=m),oy(s,l)},f}function A7(s,l,f){f=Fs(-1,f),f.tag=3;var m=s.type.getDerivedStateFromError;if(typeof m=="function"){var y=l.value;f.payload=function(){return m(y)},f.callback=function(){oy(s,l)}}var w=s.stateNode;return w!==null&&typeof w.componentDidCatch=="function"&&(f.callback=function(){oy(s,l),typeof m!="function"&&(zc===null?zc=new Set([this]):zc.add(this));var E=l.stack;this.componentDidCatch(l.value,{componentStack:E!==null?E:""})}),f}function I7(s,l,f){var m=s.pingCache;if(m===null){m=s.pingCache=new ML;var y=new Set;m.set(l,y)}else y=m.get(l),y===void 0&&(y=new Set,m.set(l,y));y.has(f)||(y.add(f),s=qL.bind(null,s,l,f),l.then(s,s))}function R7(s){do{var l;if((l=s.tag===13)&&(l=s.memoizedState,l=l!==null?l.dehydrated!==null:!0),l)return s;s=s.return}while(s!==null);return null}function P7(s,l,f,m,y){return(s.mode&1)===0?(s===l?s.flags|=65536:(s.flags|=128,f.flags|=131072,f.flags&=-52805,f.tag===1&&(f.alternate===null?f.tag=17:(l=Fs(-1,1),l.tag=2,Fc(f,l,1))),f.lanes|=1),s):(s.flags|=65536,s.lanes=y,s)}var $L=Z.ReactCurrentOwner,Yi=!1;function Pi(s,l,f,m){l.child=s===null?Q9(l,null,f,m):hh(l,s.child,f,m)}function M7(s,l,f,m,y){f=f.render;var w=l.ref;return ph(l,y),m=Y5(s,l,f,m,w,y),f=Q5(),s!==null&&!Yi?(l.updateQueue=s.updateQueue,l.flags&=-2053,s.lanes&=~y,js(s,l,y)):(Vr&&f&&$5(l),l.flags|=1,Pi(s,l,m,y),l.child)}function $7(s,l,f,m,y){if(s===null){var w=f.type;return typeof w=="function"&&!Ty(w)&&w.defaultProps===void 0&&f.compare===null&&f.defaultProps===void 0?(l.tag=15,l.type=w,O7(s,l,w,m,y)):(s=c0(f.type,null,m,l,l.mode,y),s.ref=l.ref,s.return=l,l.child=s)}if(w=s.child,(s.lanes&y)===0){var E=w.memoizedProps;if(f=f.compare,f=f!==null?f:f1,f(E,m)&&s.ref===l.ref)return js(s,l,y)}return l.flags|=1,s=Wc(w,m),s.ref=l.ref,s.return=l,l.child=s}function O7(s,l,f,m,y){if(s!==null){var w=s.memoizedProps;if(f1(w,m)&&s.ref===l.ref)if(Yi=!1,l.pendingProps=m=w,(s.lanes&y)!==0)(s.flags&131072)!==0&&(Yi=!0);else return l.lanes=s.lanes,js(s,l,y)}return ay(s,l,f,m,y)}function Z7(s,l,f){var m=l.pendingProps,y=m.children,w=s!==null?s.memoizedState:null;if(m.mode==="hidden")if((l.mode&1)===0)l.memoizedState={baseLanes:0,cachePool:null,transitions:null},Ir(yh,go),go|=f;else{if((f&1073741824)===0)return s=w!==null?w.baseLanes|f:f,l.lanes=l.childLanes=1073741824,l.memoizedState={baseLanes:s,cachePool:null,transitions:null},l.updateQueue=null,Ir(yh,go),go|=s,null;l.memoizedState={baseLanes:0,cachePool:null,transitions:null},m=w!==null?w.baseLanes:f,Ir(yh,go),go|=m}else w!==null?(m=w.baseLanes|f,l.memoizedState=null):m=f,Ir(yh,go),go|=m;return Pi(s,l,y,f),l.child}function L7(s,l){var f=l.ref;(s===null&&f!==null||s!==null&&s.ref!==f)&&(l.flags|=512,l.flags|=2097152)}function ay(s,l,f,m,y){var w=Ki(f)?od:di.current;return w=ch(l,w),ph(l,y),f=Y5(s,l,f,m,w,y),m=Q5(),s!==null&&!Yi?(l.updateQueue=s.updateQueue,l.flags&=-2053,s.lanes&=~y,js(s,l,y)):(Vr&&m&&$5(l),l.flags|=1,Pi(s,l,f,y),l.child)}function H7(s,l,f,m,y){if(Ki(f)){var w=!0;$2(l)}else w=!1;if(ph(l,y),l.stateNode===null)Q2(s,l),E7(l,f,m),ny(l,f,m,y),m=!0;else if(s===null){var E=l.stateNode,L=l.memoizedProps;E.props=L;var V=E.context,ne=f.contextType;typeof ne=="object"&&ne!==null?ne=Fo(ne):(ne=Ki(f)?od:di.current,ne=ch(l,ne));var ge=f.getDerivedStateFromProps,_e=typeof ge=="function"||typeof E.getSnapshotBeforeUpdate=="function";_e||typeof E.UNSAFE_componentWillReceiveProps!="function"&&typeof E.componentWillReceiveProps!="function"||(L!==m||V!==ne)&&S7(l,E,m,ne),Vc=!1;var ve=l.memoizedState;E.state=ve,j2(l,m,E,y),V=l.memoizedState,L!==m||ve!==V||Gi.current||Vc?(typeof ge=="function"&&(ry(l,f,ge,m),V=l.memoizedState),(L=Vc||k7(l,f,L,m,ve,V,ne))?(_e||typeof E.UNSAFE_componentWillMount!="function"&&typeof E.componentWillMount!="function"||(typeof E.componentWillMount=="function"&&E.componentWillMount(),typeof E.UNSAFE_componentWillMount=="function"&&E.UNSAFE_componentWillMount()),typeof E.componentDidMount=="function"&&(l.flags|=4194308)):(typeof E.componentDidMount=="function"&&(l.flags|=4194308),l.memoizedProps=m,l.memoizedState=V),E.props=m,E.state=V,E.context=ne,m=L):(typeof E.componentDidMount=="function"&&(l.flags|=4194308),m=!1)}else{E=l.stateNode,J9(s,l),L=l.memoizedProps,ne=l.type===l.elementType?L:Ca(l.type,L),E.props=ne,_e=l.pendingProps,ve=E.context,V=f.contextType,typeof V=="object"&&V!==null?V=Fo(V):(V=Ki(f)?od:di.current,V=ch(l,V));var Fe=f.getDerivedStateFromProps;(ge=typeof Fe=="function"||typeof E.getSnapshotBeforeUpdate=="function")||typeof E.UNSAFE_componentWillReceiveProps!="function"&&typeof E.componentWillReceiveProps!="function"||(L!==_e||ve!==V)&&S7(l,E,m,V),Vc=!1,ve=l.memoizedState,E.state=ve,j2(l,m,E,y);var tt=l.memoizedState;L!==_e||ve!==tt||Gi.current||Vc?(typeof Fe=="function"&&(ry(l,f,Fe,m),tt=l.memoizedState),(ne=Vc||k7(l,f,ne,m,ve,tt,V)||!1)?(ge||typeof E.UNSAFE_componentWillUpdate!="function"&&typeof E.componentWillUpdate!="function"||(typeof E.componentWillUpdate=="function"&&E.componentWillUpdate(m,tt,V),typeof E.UNSAFE_componentWillUpdate=="function"&&E.UNSAFE_componentWillUpdate(m,tt,V)),typeof E.componentDidUpdate=="function"&&(l.flags|=4),typeof E.getSnapshotBeforeUpdate=="function"&&(l.flags|=1024)):(typeof E.componentDidUpdate!="function"||L===s.memoizedProps&&ve===s.memoizedState||(l.flags|=4),typeof E.getSnapshotBeforeUpdate!="function"||L===s.memoizedProps&&ve===s.memoizedState||(l.flags|=1024),l.memoizedProps=m,l.memoizedState=tt),E.props=m,E.state=tt,E.context=V,m=ne):(typeof E.componentDidUpdate!="function"||L===s.memoizedProps&&ve===s.memoizedState||(l.flags|=4),typeof E.getSnapshotBeforeUpdate!="function"||L===s.memoizedProps&&ve===s.memoizedState||(l.flags|=1024),m=!1)}return sy(s,l,f,m,w,y)}function sy(s,l,f,m,y,w){L7(s,l);var E=(l.flags&128)!==0;if(!m&&!E)return y&&j9(l,f,!1),js(s,l,w);m=l.stateNode,$L.current=l;var L=E&&typeof f.getDerivedStateFromError!="function"?null:m.render();return l.flags|=1,s!==null&&E?(l.child=hh(l,s.child,null,w),l.child=hh(l,null,L,w)):Pi(s,l,L,w),l.memoizedState=m.state,y&&j9(l,f,!0),l.child}function N7(s){var l=s.stateNode;l.pendingContext?V9(s,l.pendingContext,l.pendingContext!==l.context):l.context&&V9(s,l.context,!1),B5(s,l.containerInfo)}function D7(s,l,f,m,y){return uh(),H5(y),l.flags|=256,Pi(s,l,f,m),l.child}var cy={dehydrated:null,treeContext:null,retryLane:0};function ly(s){return{baseLanes:s,cachePool:null,transitions:null}}function V7(s,l,f){var m=l.pendingProps,y=Gr.current,w=!1,E=(l.flags&128)!==0,L;if((L=E)||(L=s!==null&&s.memoizedState===null?!1:(y&2)!==0),L?(w=!0,l.flags&=-129):(s===null||s.memoizedState!==null)&&(y|=1),Ir(Gr,y&1),s===null)return L5(l),s=l.memoizedState,s!==null&&(s=s.dehydrated,s!==null)?((l.mode&1)===0?l.lanes=1:s.data==="$!"?l.lanes=8:l.lanes=1073741824,null):(E=m.children,s=m.fallback,w?(m=l.mode,w=l.child,E={mode:"hidden",children:E},(m&1)===0&&w!==null?(w.childLanes=0,w.pendingProps=E):w=l0(E,m,0,null),s=md(s,m,f,null),w.return=l,s.return=l,w.sibling=s,l.child=w,l.child.memoizedState=ly(f),l.memoizedState=cy,s):dy(l,E));if(y=s.memoizedState,y!==null&&(L=y.dehydrated,L!==null))return OL(s,l,E,m,L,y,f);if(w){w=m.fallback,E=l.mode,y=s.child,L=y.sibling;var V={mode:"hidden",children:m.children};return(E&1)===0&&l.child!==y?(m=l.child,m.childLanes=0,m.pendingProps=V,l.deletions=null):(m=Wc(y,V),m.subtreeFlags=y.subtreeFlags&14680064),L!==null?w=Wc(L,w):(w=md(w,E,f,null),w.flags|=2),w.return=l,m.return=l,m.sibling=w,l.child=m,m=w,w=l.child,E=s.child.memoizedState,E=E===null?ly(f):{baseLanes:E.baseLanes|f,cachePool:null,transitions:E.transitions},w.memoizedState=E,w.childLanes=s.childLanes&~f,l.memoizedState=cy,m}return w=s.child,s=w.sibling,m=Wc(w,{mode:"visible",children:m.children}),(l.mode&1)===0&&(m.lanes=f),m.return=l,m.sibling=null,s!==null&&(f=l.deletions,f===null?(l.deletions=[s],l.flags|=16):f.push(s)),l.child=m,l.memoizedState=null,m}function dy(s,l){return l=l0({mode:"visible",children:l},s.mode,0,null),l.return=s,s.child=l}function Y2(s,l,f,m){return m!==null&&H5(m),hh(l,s.child,null,f),s=dy(l,l.pendingProps.children),s.flags|=2,l.memoizedState=null,s}function OL(s,l,f,m,y,w,E){if(f)return l.flags&256?(l.flags&=-257,m=iy(Error(t(422))),Y2(s,l,E,m)):l.memoizedState!==null?(l.child=s.child,l.flags|=128,null):(w=m.fallback,y=l.mode,m=l0({mode:"visible",children:m.children},y,0,null),w=md(w,y,E,null),w.flags|=2,m.return=l,w.return=l,m.sibling=w,l.child=m,(l.mode&1)!==0&&hh(l,s.child,null,E),l.child.memoizedState=ly(E),l.memoizedState=cy,w);if((l.mode&1)===0)return Y2(s,l,E,null);if(y.data==="$!"){if(m=y.nextSibling&&y.nextSibling.dataset,m)var L=m.dgst;return m=L,w=Error(t(419)),m=iy(w,m,void 0),Y2(s,l,E,m)}if(L=(E&s.childLanes)!==0,Yi||L){if(m=Hn,m!==null){switch(E&-E){case 4:y=2;break;case 16:y=8;break;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:y=32;break;case 536870912:y=268435456;break;default:y=0}y=(y&(m.suspendedLanes|E))!==0?0:y,y!==0&&y!==w.retryLane&&(w.retryLane=y,Vs(s,y),Sa(m,s,y,-1))}return Sy(),m=iy(Error(t(421))),Y2(s,l,E,m)}return y.data==="$?"?(l.flags|=128,l.child=s.child,l=WL.bind(null,s),y._reactRetry=l,null):(s=w.treeContext,vo=Lc(y.nextSibling),mo=l,Vr=!0,xa=null,s!==null&&(Do[Vo++]=Ns,Do[Vo++]=Ds,Do[Vo++]=ad,Ns=s.id,Ds=s.overflow,ad=l),l=dy(l,m.children),l.flags|=4096,l)}function F7(s,l,f){s.lanes|=l;var m=s.alternate;m!==null&&(m.lanes|=l),F5(s.return,l,f)}function uy(s,l,f,m,y){var w=s.memoizedState;w===null?s.memoizedState={isBackwards:l,rendering:null,renderingStartTime:0,last:m,tail:f,tailMode:y}:(w.isBackwards=l,w.rendering=null,w.renderingStartTime=0,w.last=m,w.tail=f,w.tailMode=y)}function j7(s,l,f){var m=l.pendingProps,y=m.revealOrder,w=m.tail;if(Pi(s,l,m.children,f),m=Gr.current,(m&2)!==0)m=m&1|2,l.flags|=128;else{if(s!==null&&(s.flags&128)!==0)e:for(s=l.child;s!==null;){if(s.tag===13)s.memoizedState!==null&&F7(s,f,l);else if(s.tag===19)F7(s,f,l);else if(s.child!==null){s.child.return=s,s=s.child;continue}if(s===l)break e;for(;s.sibling===null;){if(s.return===null||s.return===l)break e;s=s.return}s.sibling.return=s.return,s=s.sibling}m&=1}if(Ir(Gr,m),(l.mode&1)===0)l.memoizedState=null;else switch(y){case"forwards":for(f=l.child,y=null;f!==null;)s=f.alternate,s!==null&&z2(s)===null&&(y=f),f=f.sibling;f=y,f===null?(y=l.child,l.child=null):(y=f.sibling,f.sibling=null),uy(l,!1,y,f,w);break;case"backwards":for(f=null,y=l.child,l.child=null;y!==null;){if(s=y.alternate,s!==null&&z2(s)===null){l.child=y;break}s=y.sibling,y.sibling=f,f=y,y=s}uy(l,!0,f,null,w);break;case"together":uy(l,!1,null,null,void 0);break;default:l.memoizedState=null}return l.child}function Q2(s,l){(l.mode&1)===0&&s!==null&&(s.alternate=null,l.alternate=null,l.flags|=2)}function js(s,l,f){if(s!==null&&(l.dependencies=s.dependencies),ud|=l.lanes,(f&l.childLanes)===0)return null;if(s!==null&&l.child!==s.child)throw Error(t(153));if(l.child!==null){for(s=l.child,f=Wc(s,s.pendingProps),l.child=f,f.return=l;s.sibling!==null;)s=s.sibling,f=f.sibling=Wc(s,s.pendingProps),f.return=l;f.sibling=null}return l.child}function ZL(s,l,f){switch(l.tag){case 3:N7(l),uh();break;case 5:r7(l);break;case 1:Ki(l.type)&&$2(l);break;case 4:B5(l,l.stateNode.containerInfo);break;case 10:var m=l.type._context,y=l.memoizedProps.value;Ir(D2,m._currentValue),m._currentValue=y;break;case 13:if(m=l.memoizedState,m!==null)return m.dehydrated!==null?(Ir(Gr,Gr.current&1),l.flags|=128,null):(f&l.child.childLanes)!==0?V7(s,l,f):(Ir(Gr,Gr.current&1),s=js(s,l,f),s!==null?s.sibling:null);Ir(Gr,Gr.current&1);break;case 19:if(m=(f&l.childLanes)!==0,(s.flags&128)!==0){if(m)return j7(s,l,f);l.flags|=128}if(y=l.memoizedState,y!==null&&(y.rendering=null,y.tail=null,y.lastEffect=null),Ir(Gr,Gr.current),m)break;return null;case 22:case 23:return l.lanes=0,Z7(s,l,f)}return js(s,l,f)}var z7,hy,B7,U7;z7=function(s,l){for(var f=l.child;f!==null;){if(f.tag===5||f.tag===6)s.appendChild(f.stateNode);else if(f.tag!==4&&f.child!==null){f.child.return=f,f=f.child;continue}if(f===l)break;for(;f.sibling===null;){if(f.return===null||f.return===l)return;f=f.return}f.sibling.return=f.return,f=f.sibling}},hy=function(){},B7=function(s,l,f,m){var y=s.memoizedProps;if(y!==m){s=l.stateNode,ld(Xa.current);var w=null;switch(f){case"input":y=co(s,y),m=co(s,m),w=[];break;case"select":y=H({},y,{value:void 0}),m=H({},m,{value:void 0}),w=[];break;case"textarea":y=Ac(s,y),m=Ac(s,m),w=[];break;default:typeof y.onClick!="function"&&typeof m.onClick=="function"&&(s.onclick=R2)}Rc(f,m);var E;f=null;for(ne in y)if(!m.hasOwnProperty(ne)&&y.hasOwnProperty(ne)&&y[ne]!=null)if(ne==="style"){var L=y[ne];for(E in L)L.hasOwnProperty(E)&&(f||(f={}),f[E]="")}else ne!=="dangerouslySetInnerHTML"&&ne!=="children"&&ne!=="suppressContentEditableWarning"&&ne!=="suppressHydrationWarning"&&ne!=="autoFocus"&&(i.hasOwnProperty(ne)?w||(w=[]):(w=w||[]).push(ne,null));for(ne in m){var V=m[ne];if(L=y!=null?y[ne]:void 0,m.hasOwnProperty(ne)&&V!==L&&(V!=null||L!=null))if(ne==="style")if(L){for(E in L)!L.hasOwnProperty(E)||V&&V.hasOwnProperty(E)||(f||(f={}),f[E]="");for(E in V)V.hasOwnProperty(E)&&L[E]!==V[E]&&(f||(f={}),f[E]=V[E])}else f||(w||(w=[]),w.push(ne,f)),f=V;else ne==="dangerouslySetInnerHTML"?(V=V?V.__html:void 0,L=L?L.__html:void 0,V!=null&&L!==V&&(w=w||[]).push(ne,V)):ne==="children"?typeof V!="string"&&typeof V!="number"||(w=w||[]).push(ne,""+V):ne!=="suppressContentEditableWarning"&&ne!=="suppressHydrationWarning"&&(i.hasOwnProperty(ne)?(V!=null&&ne==="onScroll"&&Zr("scroll",s),w||L===V||(w=[])):(w=w||[]).push(ne,V))}f&&(w=w||[]).push("style",f);var ne=w;(l.updateQueue=ne)&&(l.flags|=4)}},U7=function(s,l,f,m){f!==m&&(l.flags|=4)};function A1(s,l){if(!Vr)switch(s.tailMode){case"hidden":l=s.tail;for(var f=null;l!==null;)l.alternate!==null&&(f=l),l=l.sibling;f===null?s.tail=null:f.sibling=null;break;case"collapsed":f=s.tail;for(var m=null;f!==null;)f.alternate!==null&&(m=f),f=f.sibling;m===null?l||s.tail===null?s.tail=null:s.tail.sibling=null:m.sibling=null}}function hi(s){var l=s.alternate!==null&&s.alternate.child===s.child,f=0,m=0;if(l)for(var y=s.child;y!==null;)f|=y.lanes|y.childLanes,m|=y.subtreeFlags&14680064,m|=y.flags&14680064,y.return=s,y=y.sibling;else for(y=s.child;y!==null;)f|=y.lanes|y.childLanes,m|=y.subtreeFlags,m|=y.flags,y.return=s,y=y.sibling;return s.subtreeFlags|=m,s.childLanes=f,l}function LL(s,l,f){var m=l.pendingProps;switch(O5(l),l.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return hi(l),null;case 1:return Ki(l.type)&&M2(),hi(l),null;case 3:return m=l.stateNode,mh(),Lr(Gi),Lr(di),W5(),m.pendingContext&&(m.context=m.pendingContext,m.pendingContext=null),(s===null||s.child===null)&&(H2(l)?l.flags|=4:s===null||s.memoizedState.isDehydrated&&(l.flags&256)===0||(l.flags|=1024,xa!==null&&(Cy(xa),xa=null))),hy(s,l),hi(l),null;case 5:U5(l);var y=ld(C1.current);if(f=l.type,s!==null&&l.stateNode!=null)B7(s,l,f,m,y),s.ref!==l.ref&&(l.flags|=512,l.flags|=2097152);else{if(!m){if(l.stateNode===null)throw Error(t(166));return hi(l),null}if(s=ld(Xa.current),H2(l)){m=l.stateNode,f=l.type;var w=l.memoizedProps;switch(m[Qa]=l,m[y1]=w,s=(l.mode&1)!==0,f){case"dialog":Zr("cancel",m),Zr("close",m);break;case"iframe":case"object":case"embed":Zr("load",m);break;case"video":case"audio":for(y=0;y<m1.length;y++)Zr(m1[y],m);break;case"source":Zr("error",m);break;case"img":case"image":case"link":Zr("error",m),Zr("load",m);break;case"details":Zr("toggle",m);break;case"input":ma(m,w),Zr("invalid",m);break;case"select":m._wrapperState={wasMultiple:!!w.multiple},Zr("invalid",m);break;case"textarea":zl(m,w),Zr("invalid",m)}Rc(f,w),y=null;for(var E in w)if(w.hasOwnProperty(E)){var L=w[E];E==="children"?typeof L=="string"?m.textContent!==L&&(w.suppressHydrationWarning!==!0&&I2(m.textContent,L,s),y=["children",L]):typeof L=="number"&&m.textContent!==""+L&&(w.suppressHydrationWarning!==!0&&I2(m.textContent,L,s),y=["children",""+L]):i.hasOwnProperty(E)&&L!=null&&E==="onScroll"&&Zr("scroll",m)}switch(f){case"input":Wr(m),Uu(m,w,!0);break;case"textarea":Wr(m),lo(m);break;case"select":case"option":break;default:typeof w.onClick=="function"&&(m.onclick=R2)}m=y,l.updateQueue=m,m!==null&&(l.flags|=4)}else{E=y.nodeType===9?y:y.ownerDocument,s==="http://www.w3.org/1999/xhtml"&&(s=Bl(f)),s==="http://www.w3.org/1999/xhtml"?f==="script"?(s=E.createElement("div"),s.innerHTML="<script><\/script>",s=s.removeChild(s.firstChild)):typeof m.is=="string"?s=E.createElement(f,{is:m.is}):(s=E.createElement(f),f==="select"&&(E=s,m.multiple?E.multiple=!0:m.size&&(E.size=m.size))):s=E.createElementNS(s,f),s[Qa]=l,s[y1]=m,z7(s,l,!1,!1),l.stateNode=s;e:{switch(E=Ps(f,m),f){case"dialog":Zr("cancel",s),Zr("close",s),y=m;break;case"iframe":case"object":case"embed":Zr("load",s),y=m;break;case"video":case"audio":for(y=0;y<m1.length;y++)Zr(m1[y],s);y=m;break;case"source":Zr("error",s),y=m;break;case"img":case"image":case"link":Zr("error",s),Zr("load",s),y=m;break;case"details":Zr("toggle",s),y=m;break;case"input":ma(s,m),y=co(s,m),Zr("invalid",s);break;case"option":y=m;break;case"select":s._wrapperState={wasMultiple:!!m.multiple},y=H({},m,{value:void 0}),Zr("invalid",s);break;case"textarea":zl(s,m),y=Ac(s,m),Zr("invalid",s);break;default:y=m}Rc(f,y),L=y;for(w in L)if(L.hasOwnProperty(w)){var V=L[w];w==="style"?Ic(s,V):w==="dangerouslySetInnerHTML"?(V=V?V.__html:void 0,V!=null&&Ii(s,V)):w==="children"?typeof V=="string"?(f!=="textarea"||V!=="")&&Ua(s,V):typeof V=="number"&&Ua(s,""+V):w!=="suppressContentEditableWarning"&&w!=="suppressHydrationWarning"&&w!=="autoFocus"&&(i.hasOwnProperty(w)?V!=null&&w==="onScroll"&&Zr("scroll",s):V!=null&&A(s,w,V,E))}switch(f){case"input":Wr(s),Uu(s,m,!1);break;case"textarea":Wr(s),lo(s);break;case"option":m.value!=null&&s.setAttribute("value",""+ot(m.value));break;case"select":s.multiple=!!m.multiple,w=m.value,w!=null?Mo(s,!!m.multiple,w,!1):m.defaultValue!=null&&Mo(s,!!m.multiple,m.defaultValue,!0);break;default:typeof y.onClick=="function"&&(s.onclick=R2)}switch(f){case"button":case"input":case"select":case"textarea":m=!!m.autoFocus;break e;case"img":m=!0;break e;default:m=!1}}m&&(l.flags|=4)}l.ref!==null&&(l.flags|=512,l.flags|=2097152)}return hi(l),null;case 6:if(s&&l.stateNode!=null)U7(s,l,s.memoizedProps,m);else{if(typeof m!="string"&&l.stateNode===null)throw Error(t(166));if(f=ld(C1.current),ld(Xa.current),H2(l)){if(m=l.stateNode,f=l.memoizedProps,m[Qa]=l,(w=m.nodeValue!==f)&&(s=mo,s!==null))switch(s.tag){case 3:I2(m.nodeValue,f,(s.mode&1)!==0);break;case 5:s.memoizedProps.suppressHydrationWarning!==!0&&I2(m.nodeValue,f,(s.mode&1)!==0)}w&&(l.flags|=4)}else m=(f.nodeType===9?f:f.ownerDocument).createTextNode(m),m[Qa]=l,l.stateNode=m}return hi(l),null;case 13:if(Lr(Gr),m=l.memoizedState,s===null||s.memoizedState!==null&&s.memoizedState.dehydrated!==null){if(Vr&&vo!==null&&(l.mode&1)!==0&&(l.flags&128)===0)G9(),uh(),l.flags|=98560,w=!1;else if(w=H2(l),m!==null&&m.dehydrated!==null){if(s===null){if(!w)throw Error(t(318));if(w=l.memoizedState,w=w!==null?w.dehydrated:null,!w)throw Error(t(317));w[Qa]=l}else uh(),(l.flags&128)===0&&(l.memoizedState=null),l.flags|=4;hi(l),w=!1}else xa!==null&&(Cy(xa),xa=null),w=!0;if(!w)return l.flags&65536?l:null}return(l.flags&128)!==0?(l.lanes=f,l):(m=m!==null,m!==(s!==null&&s.memoizedState!==null)&&m&&(l.child.flags|=8192,(l.mode&1)!==0&&(s===null||(Gr.current&1)!==0?Mn===0&&(Mn=3):Sy())),l.updateQueue!==null&&(l.flags|=4),hi(l),null);case 4:return mh(),hy(s,l),s===null&&v1(l.stateNode.containerInfo),hi(l),null;case 10:return V5(l.type._context),hi(l),null;case 17:return Ki(l.type)&&M2(),hi(l),null;case 19:if(Lr(Gr),w=l.memoizedState,w===null)return hi(l),null;if(m=(l.flags&128)!==0,E=w.rendering,E===null)if(m)A1(w,!1);else{if(Mn!==0||s!==null&&(s.flags&128)!==0)for(s=l.child;s!==null;){if(E=z2(s),E!==null){for(l.flags|=128,A1(w,!1),m=E.updateQueue,m!==null&&(l.updateQueue=m,l.flags|=4),l.subtreeFlags=0,m=f,f=l.child;f!==null;)w=f,s=m,w.flags&=14680066,E=w.alternate,E===null?(w.childLanes=0,w.lanes=s,w.child=null,w.subtreeFlags=0,w.memoizedProps=null,w.memoizedState=null,w.updateQueue=null,w.dependencies=null,w.stateNode=null):(w.childLanes=E.childLanes,w.lanes=E.lanes,w.child=E.child,w.subtreeFlags=0,w.deletions=null,w.memoizedProps=E.memoizedProps,w.memoizedState=E.memoizedState,w.updateQueue=E.updateQueue,w.type=E.type,s=E.dependencies,w.dependencies=s===null?null:{lanes:s.lanes,firstContext:s.firstContext}),f=f.sibling;return Ir(Gr,Gr.current&1|2),l.child}s=s.sibling}w.tail!==null&&Kt()>_h&&(l.flags|=128,m=!0,A1(w,!1),l.lanes=4194304)}else{if(!m)if(s=z2(E),s!==null){if(l.flags|=128,m=!0,f=s.updateQueue,f!==null&&(l.updateQueue=f,l.flags|=4),A1(w,!0),w.tail===null&&w.tailMode==="hidden"&&!E.alternate&&!Vr)return hi(l),null}else 2*Kt()-w.renderingStartTime>_h&&f!==1073741824&&(l.flags|=128,m=!0,A1(w,!1),l.lanes=4194304);w.isBackwards?(E.sibling=l.child,l.child=E):(f=w.last,f!==null?f.sibling=E:l.child=E,w.last=E)}return w.tail!==null?(l=w.tail,w.rendering=l,w.tail=l.sibling,w.renderingStartTime=Kt(),l.sibling=null,f=Gr.current,Ir(Gr,m?f&1|2:f&1),l):(hi(l),null);case 22:case 23:return Ey(),m=l.memoizedState!==null,s!==null&&s.memoizedState!==null!==m&&(l.flags|=8192),m&&(l.mode&1)!==0?(go&1073741824)!==0&&(hi(l),l.subtreeFlags&6&&(l.flags|=8192)):hi(l),null;case 24:return null;case 25:return null}throw Error(t(156,l.tag))}function HL(s,l){switch(O5(l),l.tag){case 1:return Ki(l.type)&&M2(),s=l.flags,s&65536?(l.flags=s&-65537|128,l):null;case 3:return mh(),Lr(Gi),Lr(di),W5(),s=l.flags,(s&65536)!==0&&(s&128)===0?(l.flags=s&-65537|128,l):null;case 5:return U5(l),null;case 13:if(Lr(Gr),s=l.memoizedState,s!==null&&s.dehydrated!==null){if(l.alternate===null)throw Error(t(340));uh()}return s=l.flags,s&65536?(l.flags=s&-65537|128,l):null;case 19:return Lr(Gr),null;case 4:return mh(),null;case 10:return V5(l.type._context),null;case 22:case 23:return Ey(),null;case 24:return null;default:return null}}var X2=!1,fi=!1,NL=typeof WeakSet=="function"?WeakSet:Set,Qe=null;function gh(s,l){var f=s.ref;if(f!==null)if(typeof f=="function")try{f(null)}catch(m){cn(s,l,m)}else f.current=null}function fy(s,l,f){try{f()}catch(m){cn(s,l,m)}}var q7=!1;function DL(s,l){if(E5=te,s=k9(),g5(s)){if("selectionStart"in s)var f={start:s.selectionStart,end:s.selectionEnd};else e:{f=(f=s.ownerDocument)&&f.defaultView||window;var m=f.getSelection&&f.getSelection();if(m&&m.rangeCount!==0){f=m.anchorNode;var y=m.anchorOffset,w=m.focusNode;m=m.focusOffset;try{f.nodeType,w.nodeType}catch{f=null;break e}var E=0,L=-1,V=-1,ne=0,ge=0,_e=s,ve=null;t:for(;;){for(var Fe;_e!==f||y!==0&&_e.nodeType!==3||(L=E+y),_e!==w||m!==0&&_e.nodeType!==3||(V=E+m),_e.nodeType===3&&(E+=_e.nodeValue.length),(Fe=_e.firstChild)!==null;)ve=_e,_e=Fe;for(;;){if(_e===s)break t;if(ve===f&&++ne===y&&(L=E),ve===w&&++ge===m&&(V=E),(Fe=_e.nextSibling)!==null)break;_e=ve,ve=_e.parentNode}_e=Fe}f=L===-1||V===-1?null:{start:L,end:V}}else f=null}f=f||{start:0,end:0}}else f=null;for(S5={focusedElem:s,selectionRange:f},te=!1,Qe=l;Qe!==null;)if(l=Qe,s=l.child,(l.subtreeFlags&1028)!==0&&s!==null)s.return=l,Qe=s;else for(;Qe!==null;){l=Qe;try{var tt=l.alternate;if((l.flags&1024)!==0)switch(l.tag){case 0:case 11:case 15:break;case 1:if(tt!==null){var nt=tt.memoizedProps,gn=tt.memoizedState,X=l.stateNode,W=X.getSnapshotBeforeUpdate(l.elementType===l.type?nt:Ca(l.type,nt),gn);X.__reactInternalSnapshotBeforeUpdate=W}break;case 3:var ee=l.stateNode.containerInfo;ee.nodeType===1?ee.textContent="":ee.nodeType===9&&ee.documentElement&&ee.removeChild(ee.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(t(163))}}catch(Se){cn(l,l.return,Se)}if(s=l.sibling,s!==null){s.return=l.return,Qe=s;break}Qe=l.return}return tt=q7,q7=!1,tt}function I1(s,l,f){var m=l.updateQueue;if(m=m!==null?m.lastEffect:null,m!==null){var y=m=m.next;do{if((y.tag&s)===s){var w=y.destroy;y.destroy=void 0,w!==void 0&&fy(l,f,w)}y=y.next}while(y!==m)}}function J2(s,l){if(l=l.updateQueue,l=l!==null?l.lastEffect:null,l!==null){var f=l=l.next;do{if((f.tag&s)===s){var m=f.create;f.destroy=m()}f=f.next}while(f!==l)}}function py(s){var l=s.ref;if(l!==null){var f=s.stateNode;switch(s.tag){case 5:s=f;break;default:s=f}typeof l=="function"?l(s):l.current=s}}function W7(s){var l=s.alternate;l!==null&&(s.alternate=null,W7(l)),s.child=null,s.deletions=null,s.sibling=null,s.tag===5&&(l=s.stateNode,l!==null&&(delete l[Qa],delete l[y1],delete l[R5],delete l[wL],delete l[xL])),s.stateNode=null,s.return=null,s.dependencies=null,s.memoizedProps=null,s.memoizedState=null,s.pendingProps=null,s.stateNode=null,s.updateQueue=null}function G7(s){return s.tag===5||s.tag===3||s.tag===4}function K7(s){e:for(;;){for(;s.sibling===null;){if(s.return===null||G7(s.return))return null;s=s.return}for(s.sibling.return=s.return,s=s.sibling;s.tag!==5&&s.tag!==6&&s.tag!==18;){if(s.flags&2||s.child===null||s.tag===4)continue e;s.child.return=s,s=s.child}if(!(s.flags&2))return s.stateNode}}function my(s,l,f){var m=s.tag;if(m===5||m===6)s=s.stateNode,l?f.nodeType===8?f.parentNode.insertBefore(s,l):f.insertBefore(s,l):(f.nodeType===8?(l=f.parentNode,l.insertBefore(s,f)):(l=f,l.appendChild(s)),f=f._reactRootContainer,f!=null||l.onclick!==null||(l.onclick=R2));else if(m!==4&&(s=s.child,s!==null))for(my(s,l,f),s=s.sibling;s!==null;)my(s,l,f),s=s.sibling}function vy(s,l,f){var m=s.tag;if(m===5||m===6)s=s.stateNode,l?f.insertBefore(s,l):f.appendChild(s);else if(m!==4&&(s=s.child,s!==null))for(vy(s,l,f),s=s.sibling;s!==null;)vy(s,l,f),s=s.sibling}var Wn=null,ka=!1;function jc(s,l,f){for(f=f.child;f!==null;)Y7(s,l,f),f=f.sibling}function Y7(s,l,f){if(In&&typeof In.onCommitFiberUnmount=="function")try{In.onCommitFiberUnmount(sr,f)}catch{}switch(f.tag){case 5:fi||gh(f,l);case 6:var m=Wn,y=ka;Wn=null,jc(s,l,f),Wn=m,ka=y,Wn!==null&&(ka?(s=Wn,f=f.stateNode,s.nodeType===8?s.parentNode.removeChild(f):s.removeChild(f)):Wn.removeChild(f.stateNode));break;case 18:Wn!==null&&(ka?(s=Wn,f=f.stateNode,s.nodeType===8?I5(s.parentNode,f):s.nodeType===1&&I5(s,f),ed(s)):I5(Wn,f.stateNode));break;case 4:m=Wn,y=ka,Wn=f.stateNode.containerInfo,ka=!0,jc(s,l,f),Wn=m,ka=y;break;case 0:case 11:case 14:case 15:if(!fi&&(m=f.updateQueue,m!==null&&(m=m.lastEffect,m!==null))){y=m=m.next;do{var w=y,E=w.destroy;w=w.tag,E!==void 0&&((w&2)!==0||(w&4)!==0)&&fy(f,l,E),y=y.next}while(y!==m)}jc(s,l,f);break;case 1:if(!fi&&(gh(f,l),m=f.stateNode,typeof m.componentWillUnmount=="function"))try{m.props=f.memoizedProps,m.state=f.memoizedState,m.componentWillUnmount()}catch(L){cn(f,l,L)}jc(s,l,f);break;case 21:jc(s,l,f);break;case 22:f.mode&1?(fi=(m=fi)||f.memoizedState!==null,jc(s,l,f),fi=m):jc(s,l,f);break;default:jc(s,l,f)}}function Q7(s){var l=s.updateQueue;if(l!==null){s.updateQueue=null;var f=s.stateNode;f===null&&(f=s.stateNode=new NL),l.forEach(function(m){var y=GL.bind(null,s,m);f.has(m)||(f.add(m),m.then(y,y))})}}function Ea(s,l){var f=l.deletions;if(f!==null)for(var m=0;m<f.length;m++){var y=f[m];try{var w=s,E=l,L=E;e:for(;L!==null;){switch(L.tag){case 5:Wn=L.stateNode,ka=!1;break e;case 3:Wn=L.stateNode.containerInfo,ka=!0;break e;case 4:Wn=L.stateNode.containerInfo,ka=!0;break e}L=L.return}if(Wn===null)throw Error(t(160));Y7(w,E,y),Wn=null,ka=!1;var V=y.alternate;V!==null&&(V.return=null),y.return=null}catch(ne){cn(y,l,ne)}}if(l.subtreeFlags&12854)for(l=l.child;l!==null;)X7(l,s),l=l.sibling}function X7(s,l){var f=s.alternate,m=s.flags;switch(s.tag){case 0:case 11:case 14:case 15:if(Ea(l,s),es(s),m&4){try{I1(3,s,s.return),J2(3,s)}catch(nt){cn(s,s.return,nt)}try{I1(5,s,s.return)}catch(nt){cn(s,s.return,nt)}}break;case 1:Ea(l,s),es(s),m&512&&f!==null&&gh(f,f.return);break;case 5:if(Ea(l,s),es(s),m&512&&f!==null&&gh(f,f.return),s.flags&32){var y=s.stateNode;try{Ua(y,"")}catch(nt){cn(s,s.return,nt)}}if(m&4&&(y=s.stateNode,y!=null)){var w=s.memoizedProps,E=f!==null?f.memoizedProps:w,L=s.type,V=s.updateQueue;if(s.updateQueue=null,V!==null)try{L==="input"&&w.type==="radio"&&w.name!=null&&qi(y,w),Ps(L,E);var ne=Ps(L,w);for(E=0;E<V.length;E+=2){var ge=V[E],_e=V[E+1];ge==="style"?Ic(y,_e):ge==="dangerouslySetInnerHTML"?Ii(y,_e):ge==="children"?Ua(y,_e):A(y,ge,_e,ne)}switch(L){case"input":Sc(y,w);break;case"textarea":An(y,w);break;case"select":var ve=y._wrapperState.wasMultiple;y._wrapperState.wasMultiple=!!w.multiple;var Fe=w.value;Fe!=null?Mo(y,!!w.multiple,Fe,!1):ve!==!!w.multiple&&(w.defaultValue!=null?Mo(y,!!w.multiple,w.defaultValue,!0):Mo(y,!!w.multiple,w.multiple?[]:"",!1))}y[y1]=w}catch(nt){cn(s,s.return,nt)}}break;case 6:if(Ea(l,s),es(s),m&4){if(s.stateNode===null)throw Error(t(162));y=s.stateNode,w=s.memoizedProps;try{y.nodeValue=w}catch(nt){cn(s,s.return,nt)}}break;case 3:if(Ea(l,s),es(s),m&4&&f!==null&&f.memoizedState.isDehydrated)try{ed(l.containerInfo)}catch(nt){cn(s,s.return,nt)}break;case 4:Ea(l,s),es(s);break;case 13:Ea(l,s),es(s),y=s.child,y.flags&8192&&(w=y.memoizedState!==null,y.stateNode.isHidden=w,!w||y.alternate!==null&&y.alternate.memoizedState!==null||(_y=Kt())),m&4&&Q7(s);break;case 22:if(ge=f!==null&&f.memoizedState!==null,s.mode&1?(fi=(ne=fi)||ge,Ea(l,s),fi=ne):Ea(l,s),es(s),m&8192){if(ne=s.memoizedState!==null,(s.stateNode.isHidden=ne)&&!ge&&(s.mode&1)!==0)for(Qe=s,ge=s.child;ge!==null;){for(_e=Qe=ge;Qe!==null;){switch(ve=Qe,Fe=ve.child,ve.tag){case 0:case 11:case 14:case 15:I1(4,ve,ve.return);break;case 1:gh(ve,ve.return);var tt=ve.stateNode;if(typeof tt.componentWillUnmount=="function"){m=ve,f=ve.return;try{l=m,tt.props=l.memoizedProps,tt.state=l.memoizedState,tt.componentWillUnmount()}catch(nt){cn(m,f,nt)}}break;case 5:gh(ve,ve.return);break;case 22:if(ve.memoizedState!==null){tx(_e);continue}}Fe!==null?(Fe.return=ve,Qe=Fe):tx(_e)}ge=ge.sibling}e:for(ge=null,_e=s;;){if(_e.tag===5){if(ge===null){ge=_e;try{y=_e.stateNode,ne?(w=y.style,typeof w.setProperty=="function"?w.setProperty("display","none","important"):w.display="none"):(L=_e.stateNode,V=_e.memoizedProps.style,E=V!=null&&V.hasOwnProperty("display")?V.display:null,L.style.display=uo("display",E))}catch(nt){cn(s,s.return,nt)}}}else if(_e.tag===6){if(ge===null)try{_e.stateNode.nodeValue=ne?"":_e.memoizedProps}catch(nt){cn(s,s.return,nt)}}else if((_e.tag!==22&&_e.tag!==23||_e.memoizedState===null||_e===s)&&_e.child!==null){_e.child.return=_e,_e=_e.child;continue}if(_e===s)break e;for(;_e.sibling===null;){if(_e.return===null||_e.return===s)break e;ge===_e&&(ge=null),_e=_e.return}ge===_e&&(ge=null),_e.sibling.return=_e.return,_e=_e.sibling}}break;case 19:Ea(l,s),es(s),m&4&&Q7(s);break;case 21:break;default:Ea(l,s),es(s)}}function es(s){var l=s.flags;if(l&2){try{e:{for(var f=s.return;f!==null;){if(G7(f)){var m=f;break e}f=f.return}throw Error(t(160))}switch(m.tag){case 5:var y=m.stateNode;m.flags&32&&(Ua(y,""),m.flags&=-33);var w=K7(s);vy(s,w,y);break;case 3:case 4:var E=m.stateNode.containerInfo,L=K7(s);my(s,L,E);break;default:throw Error(t(161))}}catch(V){cn(s,s.return,V)}s.flags&=-3}l&4096&&(s.flags&=-4097)}function VL(s,l,f){Qe=s,J7(s)}function J7(s,l,f){for(var m=(s.mode&1)!==0;Qe!==null;){var y=Qe,w=y.child;if(y.tag===22&&m){var E=y.memoizedState!==null||X2;if(!E){var L=y.alternate,V=L!==null&&L.memoizedState!==null||fi;L=X2;var ne=fi;if(X2=E,(fi=V)&&!ne)for(Qe=y;Qe!==null;)E=Qe,V=E.child,E.tag===22&&E.memoizedState!==null?rx(y):V!==null?(V.return=E,Qe=V):rx(y);for(;w!==null;)Qe=w,J7(w),w=w.sibling;Qe=y,X2=L,fi=ne}ex(s)}else(y.subtreeFlags&8772)!==0&&w!==null?(w.return=y,Qe=w):ex(s)}}function ex(s){for(;Qe!==null;){var l=Qe;if((l.flags&8772)!==0){var f=l.alternate;try{if((l.flags&8772)!==0)switch(l.tag){case 0:case 11:case 15:fi||J2(5,l);break;case 1:var m=l.stateNode;if(l.flags&4&&!fi)if(f===null)m.componentDidMount();else{var y=l.elementType===l.type?f.memoizedProps:Ca(l.type,f.memoizedProps);m.componentDidUpdate(y,f.memoizedState,m.__reactInternalSnapshotBeforeUpdate)}var w=l.updateQueue;w!==null&&t7(l,w,m);break;case 3:var E=l.updateQueue;if(E!==null){if(f=null,l.child!==null)switch(l.child.tag){case 5:f=l.child.stateNode;break;case 1:f=l.child.stateNode}t7(l,E,f)}break;case 5:var L=l.stateNode;if(f===null&&l.flags&4){f=L;var V=l.memoizedProps;switch(l.type){case"button":case"input":case"select":case"textarea":V.autoFocus&&f.focus();break;case"img":V.src&&(f.src=V.src)}}break;case 6:break;case 4:break;case 12:break;case 13:if(l.memoizedState===null){var ne=l.alternate;if(ne!==null){var ge=ne.memoizedState;if(ge!==null){var _e=ge.dehydrated;_e!==null&&ed(_e)}}}break;case 19:case 17:case 21:case 22:case 23:case 25:break;default:throw Error(t(163))}fi||l.flags&512&&py(l)}catch(ve){cn(l,l.return,ve)}}if(l===s){Qe=null;break}if(f=l.sibling,f!==null){f.return=l.return,Qe=f;break}Qe=l.return}}function tx(s){for(;Qe!==null;){var l=Qe;if(l===s){Qe=null;break}var f=l.sibling;if(f!==null){f.return=l.return,Qe=f;break}Qe=l.return}}function rx(s){for(;Qe!==null;){var l=Qe;try{switch(l.tag){case 0:case 11:case 15:var f=l.return;try{J2(4,l)}catch(V){cn(l,f,V)}break;case 1:var m=l.stateNode;if(typeof m.componentDidMount=="function"){var y=l.return;try{m.componentDidMount()}catch(V){cn(l,y,V)}}var w=l.return;try{py(l)}catch(V){cn(l,w,V)}break;case 5:var E=l.return;try{py(l)}catch(V){cn(l,E,V)}}}catch(V){cn(l,l.return,V)}if(l===s){Qe=null;break}var L=l.sibling;if(L!==null){L.return=l.return,Qe=L;break}Qe=l.return}}var FL=Math.ceil,e0=Z.ReactCurrentDispatcher,gy=Z.ReactCurrentOwner,zo=Z.ReactCurrentBatchConfig,Xt=0,Hn=null,wn=null,Gn=0,go=0,yh=Hc(0),Mn=0,R1=null,ud=0,t0=0,yy=0,P1=null,Qi=null,_y=0,_h=1/0,zs=null,r0=!1,by=null,zc=null,n0=!1,Bc=null,i0=0,M1=0,wy=null,o0=-1,a0=0;function Mi(){return(Xt&6)!==0?Kt():o0!==-1?o0:o0=Kt()}function Uc(s){return(s.mode&1)===0?1:(Xt&2)!==0&&Gn!==0?Gn&-Gn:kL.transition!==null?(a0===0&&(a0=p2()),a0):(s=qt,s!==0||(s=window.event,s=s===void 0?16:qn(s.type)),s)}function Sa(s,l,f,m){if(50<M1)throw M1=0,wy=null,Error(t(185));Yl(s,f,m),((Xt&2)===0||s!==Hn)&&(s===Hn&&((Xt&2)===0&&(t0|=f),Mn===4&&qc(s,Gn)),Xi(s,m),f===1&&Xt===0&&(l.mode&1)===0&&(_h=Kt()+500,O2&&Dc()))}function Xi(s,l){var f=s.callbackNode;s5(s,l);var m=Qu(s,s===Hn?Gn:0);if(m===0)f!==null&&ci(f),s.callbackNode=null,s.callbackPriority=0;else if(l=m&-m,s.callbackPriority!==l){if(f!=null&&ci(f),l===1)s.tag===0?CL(ix.bind(null,s)):z9(ix.bind(null,s)),_L(function(){(Xt&6)===0&&Dc()}),f=null;else{switch(n1(m)){case 1:f=ga;break;case 4:f=Lo;break;case 16:f=Ho;break;case 536870912:f=jt;break;default:f=Ho}f=hx(f,nx.bind(null,s))}s.callbackPriority=l,s.callbackNode=f}}function nx(s,l){if(o0=-1,a0=0,(Xt&6)!==0)throw Error(t(327));var f=s.callbackNode;if(bh()&&s.callbackNode!==f)return null;var m=Qu(s,s===Hn?Gn:0);if(m===0)return null;if((m&30)!==0||(m&s.expiredLanes)!==0||l)l=s0(s,m);else{l=m;var y=Xt;Xt|=2;var w=ax();(Hn!==s||Gn!==l)&&(zs=null,_h=Kt()+500,fd(s,l));do try{BL();break}catch(L){ox(s,L)}while(!0);D5(),e0.current=w,Xt=y,wn!==null?l=0:(Hn=null,Gn=0,l=Mn)}if(l!==0){if(l===2&&(y=r1(s),y!==0&&(m=y,l=xy(s,y))),l===1)throw f=R1,fd(s,0),qc(s,m),Xi(s,Kt()),f;if(l===6)qc(s,m);else{if(y=s.current.alternate,(m&30)===0&&!jL(y)&&(l=s0(s,m),l===2&&(w=r1(s),w!==0&&(m=w,l=xy(s,w))),l===1))throw f=R1,fd(s,0),qc(s,m),Xi(s,Kt()),f;switch(s.finishedWork=y,s.finishedLanes=m,l){case 0:case 1:throw Error(t(345));case 2:pd(s,Qi,zs);break;case 3:if(qc(s,m),(m&130023424)===m&&(l=_y+500-Kt(),10<l)){if(Qu(s,0)!==0)break;if(y=s.suspendedLanes,(y&m)!==m){Mi(),s.pingedLanes|=s.suspendedLanes&y;break}s.timeoutHandle=A5(pd.bind(null,s,Qi,zs),l);break}pd(s,Qi,zs);break;case 4:if(qc(s,m),(m&4194240)===m)break;for(l=s.eventTimes,y=-1;0<m;){var E=31-Yt(m);w=1<<E,E=l[E],E>y&&(y=E),m&=~w}if(m=y,m=Kt()-m,m=(120>m?120:480>m?480:1080>m?1080:1920>m?1920:3e3>m?3e3:4320>m?4320:1960*FL(m/1960))-m,10<m){s.timeoutHandle=A5(pd.bind(null,s,Qi,zs),m);break}pd(s,Qi,zs);break;case 5:pd(s,Qi,zs);break;default:throw Error(t(329))}}}return Xi(s,Kt()),s.callbackNode===f?nx.bind(null,s):null}function xy(s,l){var f=P1;return s.current.memoizedState.isDehydrated&&(fd(s,l).flags|=256),s=s0(s,l),s!==2&&(l=Qi,Qi=f,l!==null&&Cy(l)),s}function Cy(s){Qi===null?Qi=s:Qi.push.apply(Qi,s)}function jL(s){for(var l=s;;){if(l.flags&16384){var f=l.updateQueue;if(f!==null&&(f=f.stores,f!==null))for(var m=0;m<f.length;m++){var y=f[m],w=y.getSnapshot;y=y.value;try{if(!wa(w(),y))return!1}catch{return!1}}}if(f=l.child,l.subtreeFlags&16384&&f!==null)f.return=l,l=f;else{if(l===s)break;for(;l.sibling===null;){if(l.return===null||l.return===s)return!0;l=l.return}l.sibling.return=l.return,l=l.sibling}}return!0}function qc(s,l){for(l&=~yy,l&=~t0,s.suspendedLanes|=l,s.pingedLanes&=~l,s=s.expirationTimes;0<l;){var f=31-Yt(l),m=1<<f;s[f]=-1,l&=~m}}function ix(s){if((Xt&6)!==0)throw Error(t(327));bh();var l=Qu(s,0);if((l&1)===0)return Xi(s,Kt()),null;var f=s0(s,l);if(s.tag!==0&&f===2){var m=r1(s);m!==0&&(l=m,f=xy(s,m))}if(f===1)throw f=R1,fd(s,0),qc(s,l),Xi(s,Kt()),f;if(f===6)throw Error(t(345));return s.finishedWork=s.current.alternate,s.finishedLanes=l,pd(s,Qi,zs),Xi(s,Kt()),null}function ky(s,l){var f=Xt;Xt|=1;try{return s(l)}finally{Xt=f,Xt===0&&(_h=Kt()+500,O2&&Dc())}}function hd(s){Bc!==null&&Bc.tag===0&&(Xt&6)===0&&bh();var l=Xt;Xt|=1;var f=zo.transition,m=qt;try{if(zo.transition=null,qt=1,s)return s()}finally{qt=m,zo.transition=f,Xt=l,(Xt&6)===0&&Dc()}}function Ey(){go=yh.current,Lr(yh)}function fd(s,l){s.finishedWork=null,s.finishedLanes=0;var f=s.timeoutHandle;if(f!==-1&&(s.timeoutHandle=-1,yL(f)),wn!==null)for(f=wn.return;f!==null;){var m=f;switch(O5(m),m.tag){case 1:m=m.type.childContextTypes,m!=null&&M2();break;case 3:mh(),Lr(Gi),Lr(di),W5();break;case 5:U5(m);break;case 4:mh();break;case 13:Lr(Gr);break;case 19:Lr(Gr);break;case 10:V5(m.type._context);break;case 22:case 23:Ey()}f=f.return}if(Hn=s,wn=s=Wc(s.current,null),Gn=go=l,Mn=0,R1=null,yy=t0=ud=0,Qi=P1=null,cd!==null){for(l=0;l<cd.length;l++)if(f=cd[l],m=f.interleaved,m!==null){f.interleaved=null;var y=m.next,w=f.pending;if(w!==null){var E=w.next;w.next=y,m.next=E}f.pending=m}cd=null}return s}function ox(s,l){do{var f=wn;try{if(D5(),B2.current=G2,U2){for(var m=Kr.memoizedState;m!==null;){var y=m.queue;y!==null&&(y.pending=null),m=m.next}U2=!1}if(dd=0,Ln=Pn=Kr=null,k1=!1,E1=0,gy.current=null,f===null||f.return===null){Mn=1,R1=l,wn=null;break}e:{var w=s,E=f.return,L=f,V=l;if(l=Gn,L.flags|=32768,V!==null&&typeof V=="object"&&typeof V.then=="function"){var ne=V,ge=L,_e=ge.tag;if((ge.mode&1)===0&&(_e===0||_e===11||_e===15)){var ve=ge.alternate;ve?(ge.updateQueue=ve.updateQueue,ge.memoizedState=ve.memoizedState,ge.lanes=ve.lanes):(ge.updateQueue=null,ge.memoizedState=null)}var Fe=R7(E);if(Fe!==null){Fe.flags&=-257,P7(Fe,E,L,w,l),Fe.mode&1&&I7(w,ne,l),l=Fe,V=ne;var tt=l.updateQueue;if(tt===null){var nt=new Set;nt.add(V),l.updateQueue=nt}else tt.add(V);break e}else{if((l&1)===0){I7(w,ne,l),Sy();break e}V=Error(t(426))}}else if(Vr&&L.mode&1){var gn=R7(E);if(gn!==null){(gn.flags&65536)===0&&(gn.flags|=256),P7(gn,E,L,w,l),H5(vh(V,L));break e}}w=V=vh(V,L),Mn!==4&&(Mn=2),P1===null?P1=[w]:P1.push(w),w=E;do{switch(w.tag){case 3:w.flags|=65536,l&=-l,w.lanes|=l;var X=T7(w,V,l);e7(w,X);break e;case 1:L=V;var W=w.type,ee=w.stateNode;if((w.flags&128)===0&&(typeof W.getDerivedStateFromError=="function"||ee!==null&&typeof ee.componentDidCatch=="function"&&(zc===null||!zc.has(ee)))){w.flags|=65536,l&=-l,w.lanes|=l;var Se=A7(w,L,l);e7(w,Se);break e}}w=w.return}while(w!==null)}cx(f)}catch(st){l=st,wn===f&&f!==null&&(wn=f=f.return);continue}break}while(!0)}function ax(){var s=e0.current;return e0.current=G2,s===null?G2:s}function Sy(){(Mn===0||Mn===3||Mn===2)&&(Mn=4),Hn===null||(ud&268435455)===0&&(t0&268435455)===0||qc(Hn,Gn)}function s0(s,l){var f=Xt;Xt|=2;var m=ax();(Hn!==s||Gn!==l)&&(zs=null,fd(s,l));do try{zL();break}catch(y){ox(s,y)}while(!0);if(D5(),Xt=f,e0.current=m,wn!==null)throw Error(t(261));return Hn=null,Gn=0,Mn}function zL(){for(;wn!==null;)sx(wn)}function BL(){for(;wn!==null&&!$s();)sx(wn)}function sx(s){var l=ux(s.alternate,s,go);s.memoizedProps=s.pendingProps,l===null?cx(s):wn=l,gy.current=null}function cx(s){var l=s;do{var f=l.alternate;if(s=l.return,(l.flags&32768)===0){if(f=LL(f,l,go),f!==null){wn=f;return}}else{if(f=HL(f,l),f!==null){f.flags&=32767,wn=f;return}if(s!==null)s.flags|=32768,s.subtreeFlags=0,s.deletions=null;else{Mn=6,wn=null;return}}if(l=l.sibling,l!==null){wn=l;return}wn=l=s}while(l!==null);Mn===0&&(Mn=5)}function pd(s,l,f){var m=qt,y=zo.transition;try{zo.transition=null,qt=1,UL(s,l,f,m)}finally{zo.transition=y,qt=m}return null}function UL(s,l,f,m){do bh();while(Bc!==null);if((Xt&6)!==0)throw Error(t(327));f=s.finishedWork;var y=s.finishedLanes;if(f===null)return null;if(s.finishedWork=null,s.finishedLanes=0,f===s.current)throw Error(t(177));s.callbackNode=null,s.callbackPriority=0;var w=f.lanes|f.childLanes;if(c5(s,w),s===Hn&&(wn=Hn=null,Gn=0),(f.subtreeFlags&2064)===0&&(f.flags&2064)===0||n0||(n0=!0,hx(Ho,function(){return bh(),null})),w=(f.flags&15990)!==0,(f.subtreeFlags&15990)!==0||w){w=zo.transition,zo.transition=null;var E=qt;qt=1;var L=Xt;Xt|=4,gy.current=null,DL(s,f),X7(f,s),uL(S5),te=!!E5,S5=E5=null,s.current=f,VL(f),ho(),Xt=L,qt=E,zo.transition=w}else s.current=f;if(n0&&(n0=!1,Bc=s,i0=y),w=s.pendingLanes,w===0&&(zc=null),Os(f.stateNode),Xi(s,Kt()),l!==null)for(m=s.onRecoverableError,f=0;f<l.length;f++)y=l[f],m(y.value,{componentStack:y.stack,digest:y.digest});if(r0)throw r0=!1,s=by,by=null,s;return(i0&1)!==0&&s.tag!==0&&bh(),w=s.pendingLanes,(w&1)!==0?s===wy?M1++:(M1=0,wy=s):M1=0,Dc(),null}function bh(){if(Bc!==null){var s=n1(i0),l=zo.transition,f=qt;try{if(zo.transition=null,qt=16>s?16:s,Bc===null)var m=!1;else{if(s=Bc,Bc=null,i0=0,(Xt&6)!==0)throw Error(t(331));var y=Xt;for(Xt|=4,Qe=s.current;Qe!==null;){var w=Qe,E=w.child;if((Qe.flags&16)!==0){var L=w.deletions;if(L!==null){for(var V=0;V<L.length;V++){var ne=L[V];for(Qe=ne;Qe!==null;){var ge=Qe;switch(ge.tag){case 0:case 11:case 15:I1(8,ge,w)}var _e=ge.child;if(_e!==null)_e.return=ge,Qe=_e;else for(;Qe!==null;){ge=Qe;var ve=ge.sibling,Fe=ge.return;if(W7(ge),ge===ne){Qe=null;break}if(ve!==null){ve.return=Fe,Qe=ve;break}Qe=Fe}}}var tt=w.alternate;if(tt!==null){var nt=tt.child;if(nt!==null){tt.child=null;do{var gn=nt.sibling;nt.sibling=null,nt=gn}while(nt!==null)}}Qe=w}}if((w.subtreeFlags&2064)!==0&&E!==null)E.return=w,Qe=E;else e:for(;Qe!==null;){if(w=Qe,(w.flags&2048)!==0)switch(w.tag){case 0:case 11:case 15:I1(9,w,w.return)}var X=w.sibling;if(X!==null){X.return=w.return,Qe=X;break e}Qe=w.return}}var W=s.current;for(Qe=W;Qe!==null;){E=Qe;var ee=E.child;if((E.subtreeFlags&2064)!==0&&ee!==null)ee.return=E,Qe=ee;else e:for(E=W;Qe!==null;){if(L=Qe,(L.flags&2048)!==0)try{switch(L.tag){case 0:case 11:case 15:J2(9,L)}}catch(st){cn(L,L.return,st)}if(L===E){Qe=null;break e}var Se=L.sibling;if(Se!==null){Se.return=L.return,Qe=Se;break e}Qe=L.return}}if(Xt=y,Dc(),In&&typeof In.onPostCommitFiberRoot=="function")try{In.onPostCommitFiberRoot(sr,s)}catch{}m=!0}return m}finally{qt=f,zo.transition=l}}return!1}function lx(s,l,f){l=vh(f,l),l=T7(s,l,1),s=Fc(s,l,1),l=Mi(),s!==null&&(Yl(s,1,l),Xi(s,l))}function cn(s,l,f){if(s.tag===3)lx(s,s,f);else for(;l!==null;){if(l.tag===3){lx(l,s,f);break}else if(l.tag===1){var m=l.stateNode;if(typeof l.type.getDerivedStateFromError=="function"||typeof m.componentDidCatch=="function"&&(zc===null||!zc.has(m))){s=vh(f,s),s=A7(l,s,1),l=Fc(l,s,1),s=Mi(),l!==null&&(Yl(l,1,s),Xi(l,s));break}}l=l.return}}function qL(s,l,f){var m=s.pingCache;m!==null&&m.delete(l),l=Mi(),s.pingedLanes|=s.suspendedLanes&f,Hn===s&&(Gn&f)===f&&(Mn===4||Mn===3&&(Gn&130023424)===Gn&&500>Kt()-_y?fd(s,0):yy|=f),Xi(s,l)}function dx(s,l){l===0&&((s.mode&1)===0?l=1:(l=Yu,Yu<<=1,(Yu&130023424)===0&&(Yu=4194304)));var f=Mi();s=Vs(s,l),s!==null&&(Yl(s,l,f),Xi(s,f))}function WL(s){var l=s.memoizedState,f=0;l!==null&&(f=l.retryLane),dx(s,f)}function GL(s,l){var f=0;switch(s.tag){case 13:var m=s.stateNode,y=s.memoizedState;y!==null&&(f=y.retryLane);break;case 19:m=s.stateNode;break;default:throw Error(t(314))}m!==null&&m.delete(l),dx(s,f)}var ux;ux=function(s,l,f){if(s!==null)if(s.memoizedProps!==l.pendingProps||Gi.current)Yi=!0;else{if((s.lanes&f)===0&&(l.flags&128)===0)return Yi=!1,ZL(s,l,f);Yi=(s.flags&131072)!==0}else Yi=!1,Vr&&(l.flags&1048576)!==0&&B9(l,L2,l.index);switch(l.lanes=0,l.tag){case 2:var m=l.type;Q2(s,l),s=l.pendingProps;var y=ch(l,di.current);ph(l,f),y=Y5(null,l,m,s,y,f);var w=Q5();return l.flags|=1,typeof y=="object"&&y!==null&&typeof y.render=="function"&&y.$$typeof===void 0?(l.tag=1,l.memoizedState=null,l.updateQueue=null,Ki(m)?(w=!0,$2(l)):w=!1,l.memoizedState=y.state!==null&&y.state!==void 0?y.state:null,z5(l),y.updater=K2,l.stateNode=y,y._reactInternals=l,ny(l,m,s,f),l=sy(null,l,m,!0,w,f)):(l.tag=0,Vr&&w&&$5(l),Pi(null,l,y,f),l=l.child),l;case 16:m=l.elementType;e:{switch(Q2(s,l),s=l.pendingProps,y=m._init,m=y(m._payload),l.type=m,y=l.tag=YL(m),s=Ca(m,s),y){case 0:l=ay(null,l,m,s,f);break e;case 1:l=H7(null,l,m,s,f);break e;case 11:l=M7(null,l,m,s,f);break e;case 14:l=$7(null,l,m,Ca(m.type,s),f);break e}throw Error(t(306,m,""))}return l;case 0:return m=l.type,y=l.pendingProps,y=l.elementType===m?y:Ca(m,y),ay(s,l,m,y,f);case 1:return m=l.type,y=l.pendingProps,y=l.elementType===m?y:Ca(m,y),H7(s,l,m,y,f);case 3:e:{if(N7(l),s===null)throw Error(t(387));m=l.pendingProps,w=l.memoizedState,y=w.element,J9(s,l),j2(l,m,null,f);var E=l.memoizedState;if(m=E.element,w.isDehydrated)if(w={element:m,isDehydrated:!1,cache:E.cache,pendingSuspenseBoundaries:E.pendingSuspenseBoundaries,transitions:E.transitions},l.updateQueue.baseState=w,l.memoizedState=w,l.flags&256){y=vh(Error(t(423)),l),l=D7(s,l,m,f,y);break e}else if(m!==y){y=vh(Error(t(424)),l),l=D7(s,l,m,f,y);break e}else for(vo=Lc(l.stateNode.containerInfo.firstChild),mo=l,Vr=!0,xa=null,f=Q9(l,null,m,f),l.child=f;f;)f.flags=f.flags&-3|4096,f=f.sibling;else{if(uh(),m===y){l=js(s,l,f);break e}Pi(s,l,m,f)}l=l.child}return l;case 5:return r7(l),s===null&&L5(l),m=l.type,y=l.pendingProps,w=s!==null?s.memoizedProps:null,E=y.children,T5(m,y)?E=null:w!==null&&T5(m,w)&&(l.flags|=32),L7(s,l),Pi(s,l,E,f),l.child;case 6:return s===null&&L5(l),null;case 13:return V7(s,l,f);case 4:return B5(l,l.stateNode.containerInfo),m=l.pendingProps,s===null?l.child=hh(l,null,m,f):Pi(s,l,m,f),l.child;case 11:return m=l.type,y=l.pendingProps,y=l.elementType===m?y:Ca(m,y),M7(s,l,m,y,f);case 7:return Pi(s,l,l.pendingProps,f),l.child;case 8:return Pi(s,l,l.pendingProps.children,f),l.child;case 12:return Pi(s,l,l.pendingProps.children,f),l.child;case 10:e:{if(m=l.type._context,y=l.pendingProps,w=l.memoizedProps,E=y.value,Ir(D2,m._currentValue),m._currentValue=E,w!==null)if(wa(w.value,E)){if(w.children===y.children&&!Gi.current){l=js(s,l,f);break e}}else for(w=l.child,w!==null&&(w.return=l);w!==null;){var L=w.dependencies;if(L!==null){E=w.child;for(var V=L.firstContext;V!==null;){if(V.context===m){if(w.tag===1){V=Fs(-1,f&-f),V.tag=2;var ne=w.updateQueue;if(ne!==null){ne=ne.shared;var ge=ne.pending;ge===null?V.next=V:(V.next=ge.next,ge.next=V),ne.pending=V}}w.lanes|=f,V=w.alternate,V!==null&&(V.lanes|=f),F5(w.return,f,l),L.lanes|=f;break}V=V.next}}else if(w.tag===10)E=w.type===l.type?null:w.child;else if(w.tag===18){if(E=w.return,E===null)throw Error(t(341));E.lanes|=f,L=E.alternate,L!==null&&(L.lanes|=f),F5(E,f,l),E=w.sibling}else E=w.child;if(E!==null)E.return=w;else for(E=w;E!==null;){if(E===l){E=null;break}if(w=E.sibling,w!==null){w.return=E.return,E=w;break}E=E.return}w=E}Pi(s,l,y.children,f),l=l.child}return l;case 9:return y=l.type,m=l.pendingProps.children,ph(l,f),y=Fo(y),m=m(y),l.flags|=1,Pi(s,l,m,f),l.child;case 14:return m=l.type,y=Ca(m,l.pendingProps),y=Ca(m.type,y),$7(s,l,m,y,f);case 15:return O7(s,l,l.type,l.pendingProps,f);case 17:return m=l.type,y=l.pendingProps,y=l.elementType===m?y:Ca(m,y),Q2(s,l),l.tag=1,Ki(m)?(s=!0,$2(l)):s=!1,ph(l,f),E7(l,m,y),ny(l,m,y,f),sy(null,l,m,!0,s,f);case 19:return j7(s,l,f);case 22:return Z7(s,l,f)}throw Error(t(156,l.tag))};function hx(s,l){return Er(s,l)}function KL(s,l,f,m){this.tag=s,this.key=f,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=l,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=m,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Bo(s,l,f,m){return new KL(s,l,f,m)}function Ty(s){return s=s.prototype,!(!s||!s.isReactComponent)}function YL(s){if(typeof s=="function")return Ty(s)?1:0;if(s!=null){if(s=s.$$typeof,s===we)return 11;if(s===K)return 14}return 2}function Wc(s,l){var f=s.alternate;return f===null?(f=Bo(s.tag,l,s.key,s.mode),f.elementType=s.elementType,f.type=s.type,f.stateNode=s.stateNode,f.alternate=s,s.alternate=f):(f.pendingProps=l,f.type=s.type,f.flags=0,f.subtreeFlags=0,f.deletions=null),f.flags=s.flags&14680064,f.childLanes=s.childLanes,f.lanes=s.lanes,f.child=s.child,f.memoizedProps=s.memoizedProps,f.memoizedState=s.memoizedState,f.updateQueue=s.updateQueue,l=s.dependencies,f.dependencies=l===null?null:{lanes:l.lanes,firstContext:l.firstContext},f.sibling=s.sibling,f.index=s.index,f.ref=s.ref,f}function c0(s,l,f,m,y,w){var E=2;if(m=s,typeof s=="function")Ty(s)&&(E=1);else if(typeof s=="string")E=5;else e:switch(s){case I:return md(f.children,y,w,l);case Y:E=8,y|=8;break;case le:return s=Bo(12,f,l,y|2),s.elementType=le,s.lanes=w,s;case Ce:return s=Bo(13,f,l,y),s.elementType=Ce,s.lanes=w,s;case J:return s=Bo(19,f,l,y),s.elementType=J,s.lanes=w,s;case q:return l0(f,y,w,l);default:if(typeof s=="object"&&s!==null)switch(s.$$typeof){case de:E=10;break e;case Ee:E=9;break e;case we:E=11;break e;case K:E=14;break e;case re:E=16,m=null;break e}throw Error(t(130,s==null?s:typeof s,""))}return l=Bo(E,f,l,y),l.elementType=s,l.type=m,l.lanes=w,l}function md(s,l,f,m){return s=Bo(7,s,m,l),s.lanes=f,s}function l0(s,l,f,m){return s=Bo(22,s,m,l),s.elementType=q,s.lanes=f,s.stateNode={isHidden:!1},s}function Ay(s,l,f){return s=Bo(6,s,null,l),s.lanes=f,s}function Iy(s,l,f){return l=Bo(4,s.children!==null?s.children:[],s.key,l),l.lanes=f,l.stateNode={containerInfo:s.containerInfo,pendingChildren:null,implementation:s.implementation},l}function QL(s,l,f,m,y){this.tag=l,this.containerInfo=s,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=Xu(0),this.expirationTimes=Xu(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Xu(0),this.identifierPrefix=m,this.onRecoverableError=y,this.mutableSourceEagerHydrationData=null}function Ry(s,l,f,m,y,w,E,L,V){return s=new QL(s,l,f,L,V),l===1?(l=1,w===!0&&(l|=8)):l=0,w=Bo(3,null,null,l),s.current=w,w.stateNode=s,w.memoizedState={element:m,isDehydrated:f,cache:null,transitions:null,pendingSuspenseBoundaries:null},z5(w),s}function XL(s,l,f){var m=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:U,key:m==null?null:""+m,children:s,containerInfo:l,implementation:f}}function fx(s){if(!s)return Nc;s=s._reactInternals;e:{if(Je(s)!==s||s.tag!==1)throw Error(t(170));var l=s;do{switch(l.tag){case 3:l=l.stateNode.context;break e;case 1:if(Ki(l.type)){l=l.stateNode.__reactInternalMemoizedMergedChildContext;break e}}l=l.return}while(l!==null);throw Error(t(171))}if(s.tag===1){var f=s.type;if(Ki(f))return F9(s,f,l)}return l}function px(s,l,f,m,y,w,E,L,V){return s=Ry(f,m,!0,s,y,w,E,L,V),s.context=fx(null),f=s.current,m=Mi(),y=Uc(f),w=Fs(m,y),w.callback=l??null,Fc(f,w,y),s.current.lanes=y,Yl(s,y,m),Xi(s,m),s}function d0(s,l,f,m){var y=l.current,w=Mi(),E=Uc(y);return f=fx(f),l.context===null?l.context=f:l.pendingContext=f,l=Fs(w,E),l.payload={element:s},m=m===void 0?null:m,m!==null&&(l.callback=m),s=Fc(y,l,E),s!==null&&(Sa(s,y,E,w),F2(s,y,E)),E}function u0(s){if(s=s.current,!s.child)return null;switch(s.child.tag){case 5:return s.child.stateNode;default:return s.child.stateNode}}function mx(s,l){if(s=s.memoizedState,s!==null&&s.dehydrated!==null){var f=s.retryLane;s.retryLane=f!==0&&f<l?f:l}}function Py(s,l){mx(s,l),(s=s.alternate)&&mx(s,l)}function JL(){return null}var vx=typeof reportError=="function"?reportError:function(s){console.error(s)};function My(s){this._internalRoot=s}h0.prototype.render=My.prototype.render=function(s){var l=this._internalRoot;if(l===null)throw Error(t(409));d0(s,l,null,null)},h0.prototype.unmount=My.prototype.unmount=function(){var s=this._internalRoot;if(s!==null){this._internalRoot=null;var l=s.containerInfo;hd(function(){d0(null,s,null,null)}),l[Ls]=null}};function h0(s){this._internalRoot=s}h0.prototype.unstable_scheduleHydration=function(s){if(s){var l=v2();s={blockedOn:null,target:s,priority:l};for(var f=0;f<No.length&&l!==0&&l<No[f].priority;f++);No.splice(f,0,s),f===0&&w2(s)}};function $y(s){return!(!s||s.nodeType!==1&&s.nodeType!==9&&s.nodeType!==11)}function f0(s){return!(!s||s.nodeType!==1&&s.nodeType!==9&&s.nodeType!==11&&(s.nodeType!==8||s.nodeValue!==" react-mount-point-unstable "))}function gx(){}function eH(s,l,f,m,y){if(y){if(typeof m=="function"){var w=m;m=function(){var ne=u0(E);w.call(ne)}}var E=px(l,m,s,0,null,!1,!1,"",gx);return s._reactRootContainer=E,s[Ls]=E.current,v1(s.nodeType===8?s.parentNode:s),hd(),E}for(;y=s.lastChild;)s.removeChild(y);if(typeof m=="function"){var L=m;m=function(){var ne=u0(V);L.call(ne)}}var V=Ry(s,0,!1,null,null,!1,!1,"",gx);return s._reactRootContainer=V,s[Ls]=V.current,v1(s.nodeType===8?s.parentNode:s),hd(function(){d0(l,V,f,m)}),V}function p0(s,l,f,m,y){var w=f._reactRootContainer;if(w){var E=w;if(typeof y=="function"){var L=y;y=function(){var V=u0(E);L.call(V)}}d0(l,E,s,y)}else E=eH(f,l,s,y,m);return u0(E)}Ga=function(s){switch(s.tag){case 3:var l=s.stateNode;if(l.current.memoizedState.isDehydrated){var f=Kl(l.pendingLanes);f!==0&&(Mc(l,f|1),Xi(l,Kt()),(Xt&6)===0&&(_h=Kt()+500,Dc()))}break;case 13:hd(function(){var m=Vs(s,1);if(m!==null){var y=Mi();Sa(m,s,1,y)}}),Py(s,1)}},i1=function(s){if(s.tag===13){var l=Vs(s,134217728);if(l!==null){var f=Mi();Sa(l,s,134217728,f)}Py(s,134217728)}},m2=function(s){if(s.tag===13){var l=Uc(s),f=Vs(s,l);if(f!==null){var m=Mi();Sa(f,s,l,m)}Py(s,l)}},v2=function(){return qt},g2=function(s,l){var f=qt;try{return qt=s,l()}finally{qt=f}},qa=function(s,l,f){switch(l){case"input":if(Sc(s,f),l=f.name,f.type==="radio"&&l!=null){for(f=s;f.parentNode;)f=f.parentNode;for(f=f.querySelectorAll("input[name="+JSON.stringify(""+l)+'][type="radio"]'),l=0;l<f.length;l++){var m=f[l];if(m!==s&&m.form===s.form){var y=P2(m);if(!y)throw Error(t(90));Rt(m),Sc(m,y)}}}break;case"textarea":An(s,f);break;case"select":l=f.value,l!=null&&Mo(s,!!f.multiple,l,!1)}},ql=ky,Ms=hd;var tH={usingClientEntryPoint:!1,Events:[_1,ah,P2,Ul,Gu,ky]},$1={findFiberByHostInstance:id,bundleType:0,version:"18.3.1",rendererPackageName:"react-dom"},rH={bundleType:$1.bundleType,version:$1.version,rendererPackageName:$1.rendererPackageName,rendererConfig:$1.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setErrorHandler:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:Z.ReactCurrentDispatcher,findHostInstanceByFiber:function(s){return s=ar(s),s===null?null:s.stateNode},findFiberByHostInstance:$1.findFiberByHostInstance||JL,findHostInstancesForRefresh:null,scheduleRefresh:null,scheduleRoot:null,setRefreshHandler:null,getCurrentFiber:null,reconcilerVersion:"18.3.1-next-f1338f8080-20240426"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var m0=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!m0.isDisabled&&m0.supportsFiber)try{sr=m0.inject(rH),In=m0}catch{}}return Ji.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=tH,Ji.createPortal=function(s,l){var f=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!$y(l))throw Error(t(200));return XL(s,l,null,f)},Ji.createRoot=function(s,l){if(!$y(s))throw Error(t(299));var f=!1,m="",y=vx;return l!=null&&(l.unstable_strictMode===!0&&(f=!0),l.identifierPrefix!==void 0&&(m=l.identifierPrefix),l.onRecoverableError!==void 0&&(y=l.onRecoverableError)),l=Ry(s,1,!1,null,null,f,!1,m,y),s[Ls]=l.current,v1(s.nodeType===8?s.parentNode:s),new My(l)},Ji.findDOMNode=function(s){if(s==null)return null;if(s.nodeType===1)return s;var l=s._reactInternals;if(l===void 0)throw typeof s.render=="function"?Error(t(188)):(s=Object.keys(s).join(","),Error(t(268,s)));return s=ar(l),s=s===null?null:s.stateNode,s},Ji.flushSync=function(s){return hd(s)},Ji.hydrate=function(s,l,f){if(!f0(l))throw Error(t(200));return p0(null,s,l,!0,f)},Ji.hydrateRoot=function(s,l,f){if(!$y(s))throw Error(t(405));var m=f!=null&&f.hydratedSources||null,y=!1,w="",E=vx;if(f!=null&&(f.unstable_strictMode===!0&&(y=!0),f.identifierPrefix!==void 0&&(w=f.identifierPrefix),f.onRecoverableError!==void 0&&(E=f.onRecoverableError)),l=px(l,null,s,1,f??null,y,!1,w,E),s[Ls]=l.current,v1(s),m)for(s=0;s<m.length;s++)f=m[s],y=f._getVersion,y=y(f._source),l.mutableSourceEagerHydrationData==null?l.mutableSourceEagerHydrationData=[f,y]:l.mutableSourceEagerHydrationData.push(f,y);return new h0(l)},Ji.render=function(s,l,f){if(!f0(l))throw Error(t(200));return p0(null,s,l,!1,f)},Ji.unmountComponentAtNode=function(s){if(!f0(s))throw Error(t(40));return s._reactRootContainer?(hd(function(){p0(null,null,s,!1,function(){s._reactRootContainer=null,s[Ls]=null})}),!0):!1},Ji.unstable_batchedUpdates=ky,Ji.unstable_renderSubtreeIntoContainer=function(s,l,f,m){if(!f0(f))throw Error(t(200));if(s==null||s._reactInternals===void 0)throw Error(t(38));return p0(s,l,f,!1,m)},Ji.version="18.3.1-next-f1338f8080-20240426",Ji}var Ex;function JI(){if(Ex)return Hy.exports;Ex=1;function r(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(r)}catch(e){console.error(e)}}return r(),Hy.exports=uH(),Hy.exports}var Sx;function hH(){if(Sx)return g0;Sx=1;var r=JI();return g0.createRoot=r.createRoot,g0.hydrateRoot=r.hydrateRoot,g0}var fH=hH();const pH=Hu(fH);var y0={exports:{}},Vy,Tx;function o4(){if(Tx)return Vy;Tx=1;const r="2.0.0",e=256,t=Number.MAX_SAFE_INTEGER||9007199254740991,n=16,i=e-6;return Vy={MAX_LENGTH:e,MAX_SAFE_COMPONENT_LENGTH:n,MAX_SAFE_BUILD_LENGTH:i,MAX_SAFE_INTEGER:t,RELEASE_TYPES:["major","premajor","minor","preminor","patch","prepatch","prerelease"],SEMVER_SPEC_VERSION:r,FLAG_INCLUDE_PRERELEASE:1,FLAG_LOOSE:2},Vy}var Fy,Ax;function a4(){if(Ax)return Fy;Ax=1;var r={};return Fy=typeof process=="object"&&r&&r.NODE_DEBUG&&/\bsemver\b/i.test(r.NODE_DEBUG)?(...t)=>console.error("SEMVER",...t):()=>{},Fy}var Ix;function Rm(){return Ix||(Ix=1,function(r,e){const{MAX_SAFE_COMPONENT_LENGTH:t,MAX_SAFE_BUILD_LENGTH:n,MAX_LENGTH:i}=o4(),o=a4();e=r.exports={};const a=e.re=[],c=e.safeRe=[],d=e.src=[],h=e.safeSrc=[],u=e.t={};let p=0;const v="[a-zA-Z0-9-]",g=[["\\s",1],["\\d",i],[v,n]],_=C=>{for(const[T,S]of g)C=C.split(`${T}*`).join(`${T}{0,${S}}`).split(`${T}+`).join(`${T}{1,${S}}`);return C},b=(C,T,S)=>{const A=_(T),Z=p++;o(C,Z,T),u[C]=Z,d[Z]=T,h[Z]=A,a[Z]=new RegExp(T,S?"g":void 0),c[Z]=new RegExp(A,S?"g":void 0)};b("NUMERICIDENTIFIER","0|[1-9]\\d*"),b("NUMERICIDENTIFIERLOOSE","\\d+"),b("NONNUMERICIDENTIFIER",`\\d*[a-zA-Z-]${v}*`),b("MAINVERSION",`(${d[u.NUMERICIDENTIFIER]})\\.(${d[u.NUMERICIDENTIFIER]})\\.(${d[u.NUMERICIDENTIFIER]})`),b("MAINVERSIONLOOSE",`(${d[u.NUMERICIDENTIFIERLOOSE]})\\.(${d[u.NUMERICIDENTIFIERLOOSE]})\\.(${d[u.NUMERICIDENTIFIERLOOSE]})`),b("PRERELEASEIDENTIFIER",`(?:${d[u.NUMERICIDENTIFIER]}|${d[u.NONNUMERICIDENTIFIER]})`),b("PRERELEASEIDENTIFIERLOOSE",`(?:${d[u.NUMERICIDENTIFIERLOOSE]}|${d[u.NONNUMERICIDENTIFIER]})`),b("PRERELEASE",`(?:-(${d[u.PRERELEASEIDENTIFIER]}(?:\\.${d[u.PRERELEASEIDENTIFIER]})*))`),b("PRERELEASELOOSE",`(?:-?(${d[u.PRERELEASEIDENTIFIERLOOSE]}(?:\\.${d[u.PRERELEASEIDENTIFIERLOOSE]})*))`),b("BUILDIDENTIFIER",`${v}+`),b("BUILD",`(?:\\+(${d[u.BUILDIDENTIFIER]}(?:\\.${d[u.BUILDIDENTIFIER]})*))`),b("FULLPLAIN",`v?${d[u.MAINVERSION]}${d[u.PRERELEASE]}?${d[u.BUILD]}?`),b("FULL",`^${d[u.FULLPLAIN]}$`),b("LOOSEPLAIN",`[v=\\s]*${d[u.MAINVERSIONLOOSE]}${d[u.PRERELEASELOOSE]}?${d[u.BUILD]}?`),b("LOOSE",`^${d[u.LOOSEPLAIN]}$`),b("GTLT","((?:<|>)?=?)"),b("XRANGEIDENTIFIERLOOSE",`${d[u.NUMERICIDENTIFIERLOOSE]}|x|X|\\*`),b("XRANGEIDENTIFIER",`${d[u.NUMERICIDENTIFIER]}|x|X|\\*`),b("XRANGEPLAIN",`[v=\\s]*(${d[u.XRANGEIDENTIFIER]})(?:\\.(${d[u.XRANGEIDENTIFIER]})(?:\\.(${d[u.XRANGEIDENTIFIER]})(?:${d[u.PRERELEASE]})?${d[u.BUILD]}?)?)?`),b("XRANGEPLAINLOOSE",`[v=\\s]*(${d[u.XRANGEIDENTIFIERLOOSE]})(?:\\.(${d[u.XRANGEIDENTIFIERLOOSE]})(?:\\.(${d[u.XRANGEIDENTIFIERLOOSE]})(?:${d[u.PRERELEASELOOSE]})?${d[u.BUILD]}?)?)?`),b("XRANGE",`^${d[u.GTLT]}\\s*${d[u.XRANGEPLAIN]}$`),b("XRANGELOOSE",`^${d[u.GTLT]}\\s*${d[u.XRANGEPLAINLOOSE]}$`),b("COERCEPLAIN",`(^|[^\\d])(\\d{1,${t}})(?:\\.(\\d{1,${t}}))?(?:\\.(\\d{1,${t}}))?`),b("COERCE",`${d[u.COERCEPLAIN]}(?:$|[^\\d])`),b("COERCEFULL",d[u.COERCEPLAIN]+`(?:${d[u.PRERELEASE]})?(?:${d[u.BUILD]})?(?:$|[^\\d])`),b("COERCERTL",d[u.COERCE],!0),b("COERCERTLFULL",d[u.COERCEFULL],!0),b("LONETILDE","(?:~>?)"),b("TILDETRIM",`(\\s*)${d[u.LONETILDE]}\\s+`,!0),e.tildeTrimReplace="$1~",b("TILDE",`^${d[u.LONETILDE]}${d[u.XRANGEPLAIN]}$`),b("TILDELOOSE",`^${d[u.LONETILDE]}${d[u.XRANGEPLAINLOOSE]}$`),b("LONECARET","(?:\\^)"),b("CARETTRIM",`(\\s*)${d[u.LONECARET]}\\s+`,!0),e.caretTrimReplace="$1^",b("CARET",`^${d[u.LONECARET]}${d[u.XRANGEPLAIN]}$`),b("CARETLOOSE",`^${d[u.LONECARET]}${d[u.XRANGEPLAINLOOSE]}$`),b("COMPARATORLOOSE",`^${d[u.GTLT]}\\s*(${d[u.LOOSEPLAIN]})$|^$`),b("COMPARATOR",`^${d[u.GTLT]}\\s*(${d[u.FULLPLAIN]})$|^$`),b("COMPARATORTRIM",`(\\s*)${d[u.GTLT]}\\s*(${d[u.LOOSEPLAIN]}|${d[u.XRANGEPLAIN]})`,!0),e.comparatorTrimReplace="$1$2$3",b("HYPHENRANGE",`^\\s*(${d[u.XRANGEPLAIN]})\\s+-\\s+(${d[u.XRANGEPLAIN]})\\s*$`),b("HYPHENRANGELOOSE",`^\\s*(${d[u.XRANGEPLAINLOOSE]})\\s+-\\s+(${d[u.XRANGEPLAINLOOSE]})\\s*$`),b("STAR","(<|>)?=?\\s*\\*"),b("GTE0","^\\s*>=\\s*0\\.0\\.0\\s*$"),b("GTE0PRE","^\\s*>=\\s*0\\.0\\.0-0\\s*$")}(y0,y0.exports)),y0.exports}var jy,Rx;function c6(){if(Rx)return jy;Rx=1;const r=Object.freeze({loose:!0}),e=Object.freeze({});return jy=n=>n?typeof n!="object"?r:n:e,jy}var zy,Px;function eR(){if(Px)return zy;Px=1;const r=/^[0-9]+$/,e=(n,i)=>{const o=r.test(n),a=r.test(i);return o&&a&&(n=+n,i=+i),n===i?0:o&&!a?-1:a&&!o?1:n<i?-1:1};return zy={compareIdentifiers:e,rcompareIdentifiers:(n,i)=>e(i,n)},zy}var By,Mx;function ji(){if(Mx)return By;Mx=1;const r=a4(),{MAX_LENGTH:e,MAX_SAFE_INTEGER:t}=o4(),{safeRe:n,safeSrc:i,t:o}=Rm(),a=c6(),{compareIdentifiers:c}=eR();class d{constructor(u,p){if(p=a(p),u instanceof d){if(u.loose===!!p.loose&&u.includePrerelease===!!p.includePrerelease)return u;u=u.version}else if(typeof u!="string")throw new TypeError(`Invalid version. Must be a string. Got type "${typeof u}".`);if(u.length>e)throw new TypeError(`version is longer than ${e} characters`);r("SemVer",u,p),this.options=p,this.loose=!!p.loose,this.includePrerelease=!!p.includePrerelease;const v=u.trim().match(p.loose?n[o.LOOSE]:n[o.FULL]);if(!v)throw new TypeError(`Invalid Version: ${u}`);if(this.raw=u,this.major=+v[1],this.minor=+v[2],this.patch=+v[3],this.major>t||this.major<0)throw new TypeError("Invalid major version");if(this.minor>t||this.minor<0)throw new TypeError("Invalid minor version");if(this.patch>t||this.patch<0)throw new TypeError("Invalid patch version");v[4]?this.prerelease=v[4].split(".").map(g=>{if(/^[0-9]+$/.test(g)){const _=+g;if(_>=0&&_<t)return _}return g}):this.prerelease=[],this.build=v[5]?v[5].split("."):[],this.format()}format(){return this.version=`${this.major}.${this.minor}.${this.patch}`,this.prerelease.length&&(this.version+=`-${this.prerelease.join(".")}`),this.version}toString(){return this.version}compare(u){if(r("SemVer.compare",this.version,this.options,u),!(u instanceof d)){if(typeof u=="string"&&u===this.version)return 0;u=new d(u,this.options)}return u.version===this.version?0:this.compareMain(u)||this.comparePre(u)}compareMain(u){return u instanceof d||(u=new d(u,this.options)),c(this.major,u.major)||c(this.minor,u.minor)||c(this.patch,u.patch)}comparePre(u){if(u instanceof d||(u=new d(u,this.options)),this.prerelease.length&&!u.prerelease.length)return-1;if(!this.prerelease.length&&u.prerelease.length)return 1;if(!this.prerelease.length&&!u.prerelease.length)return 0;let p=0;do{const v=this.prerelease[p],g=u.prerelease[p];if(r("prerelease compare",p,v,g),v===void 0&&g===void 0)return 0;if(g===void 0)return 1;if(v===void 0)return-1;if(v===g)continue;return c(v,g)}while(++p)}compareBuild(u){u instanceof d||(u=new d(u,this.options));let p=0;do{const v=this.build[p],g=u.build[p];if(r("build compare",p,v,g),v===void 0&&g===void 0)return 0;if(g===void 0)return 1;if(v===void 0)return-1;if(v===g)continue;return c(v,g)}while(++p)}inc(u,p,v){if(u.startsWith("pre")){if(!p&&v===!1)throw new Error("invalid increment argument: identifier is empty");if(p){const g=new RegExp(`^${this.options.loose?i[o.PRERELEASELOOSE]:i[o.PRERELEASE]}$`),_=`-${p}`.match(g);if(!_||_[1]!==p)throw new Error(`invalid identifier: ${p}`)}}switch(u){case"premajor":this.prerelease.length=0,this.patch=0,this.minor=0,this.major++,this.inc("pre",p,v);break;case"preminor":this.prerelease.length=0,this.patch=0,this.minor++,this.inc("pre",p,v);break;case"prepatch":this.prerelease.length=0,this.inc("patch",p,v),this.inc("pre",p,v);break;case"prerelease":this.prerelease.length===0&&this.inc("patch",p,v),this.inc("pre",p,v);break;case"release":if(this.prerelease.length===0)throw new Error(`version ${this.raw} is not a prerelease`);this.prerelease.length=0;break;case"major":(this.minor!==0||this.patch!==0||this.prerelease.length===0)&&this.major++,this.minor=0,this.patch=0,this.prerelease=[];break;case"minor":(this.patch!==0||this.prerelease.length===0)&&this.minor++,this.patch=0,this.prerelease=[];break;case"patch":this.prerelease.length===0&&this.patch++,this.prerelease=[];break;case"pre":{const g=Number(v)?1:0;if(this.prerelease.length===0)this.prerelease=[g];else{let _=this.prerelease.length;for(;--_>=0;)typeof this.prerelease[_]=="number"&&(this.prerelease[_]++,_=-2);if(_===-1){if(p===this.prerelease.join(".")&&v===!1)throw new Error("invalid increment argument: identifier already exists");this.prerelease.push(g)}}if(p){let _=[p,g];v===!1&&(_=[p]),c(this.prerelease[0],p)===0?isNaN(this.prerelease[1])&&(this.prerelease=_):this.prerelease=_}break}default:throw new Error(`invalid increment argument: ${u}`)}return this.raw=this.format(),this.build.length&&(this.raw+=`+${this.build.join(".")}`),this}}return By=d,By}var Uy,$x;function Nf(){if($x)return Uy;$x=1;const r=ji();return Uy=(t,n,i=!1)=>{if(t instanceof r)return t;try{return new r(t,n)}catch(o){if(!i)return null;throw o}},Uy}var qy,Ox;function mH(){if(Ox)return qy;Ox=1;const r=Nf();return qy=(t,n)=>{const i=r(t,n);return i?i.version:null},qy}var Wy,Zx;function vH(){if(Zx)return Wy;Zx=1;const r=Nf();return Wy=(t,n)=>{const i=r(t.trim().replace(/^[=v]+/,""),n);return i?i.version:null},Wy}var Gy,Lx;function gH(){if(Lx)return Gy;Lx=1;const r=ji();return Gy=(t,n,i,o,a)=>{typeof i=="string"&&(a=o,o=i,i=void 0);try{return new r(t instanceof r?t.version:t,i).inc(n,o,a).version}catch{return null}},Gy}var Ky,Hx;function yH(){if(Hx)return Ky;Hx=1;const r=Nf();return Ky=(t,n)=>{const i=r(t,null,!0),o=r(n,null,!0),a=i.compare(o);if(a===0)return null;const c=a>0,d=c?i:o,h=c?o:i,u=!!d.prerelease.length;if(!!h.prerelease.length&&!u){if(!h.patch&&!h.minor)return"major";if(h.compareMain(d)===0)return h.minor&&!h.patch?"minor":"patch"}const v=u?"pre":"";return i.major!==o.major?v+"major":i.minor!==o.minor?v+"minor":i.patch!==o.patch?v+"patch":"prerelease"},Ky}var Yy,Nx;function _H(){if(Nx)return Yy;Nx=1;const r=ji();return Yy=(t,n)=>new r(t,n).major,Yy}var Qy,Dx;function bH(){if(Dx)return Qy;Dx=1;const r=ji();return Qy=(t,n)=>new r(t,n).minor,Qy}var Xy,Vx;function wH(){if(Vx)return Xy;Vx=1;const r=ji();return Xy=(t,n)=>new r(t,n).patch,Xy}var Jy,Fx;function xH(){if(Fx)return Jy;Fx=1;const r=Nf();return Jy=(t,n)=>{const i=r(t,n);return i&&i.prerelease.length?i.prerelease:null},Jy}var e3,jx;function Fa(){if(jx)return e3;jx=1;const r=ji();return e3=(t,n,i)=>new r(t,i).compare(new r(n,i)),e3}var t3,zx;function CH(){if(zx)return t3;zx=1;const r=Fa();return t3=(t,n,i)=>r(n,t,i),t3}var r3,Bx;function kH(){if(Bx)return r3;Bx=1;const r=Fa();return r3=(t,n)=>r(t,n,!0),r3}var n3,Ux;function l6(){if(Ux)return n3;Ux=1;const r=ji();return n3=(t,n,i)=>{const o=new r(t,i),a=new r(n,i);return o.compare(a)||o.compareBuild(a)},n3}var i3,qx;function EH(){if(qx)return i3;qx=1;const r=l6();return i3=(t,n)=>t.sort((i,o)=>r(i,o,n)),i3}var o3,Wx;function SH(){if(Wx)return o3;Wx=1;const r=l6();return o3=(t,n)=>t.sort((i,o)=>r(o,i,n)),o3}var a3,Gx;function s4(){if(Gx)return a3;Gx=1;const r=Fa();return a3=(t,n,i)=>r(t,n,i)>0,a3}var s3,Kx;function d6(){if(Kx)return s3;Kx=1;const r=Fa();return s3=(t,n,i)=>r(t,n,i)<0,s3}var c3,Yx;function tR(){if(Yx)return c3;Yx=1;const r=Fa();return c3=(t,n,i)=>r(t,n,i)===0,c3}var l3,Qx;function rR(){if(Qx)return l3;Qx=1;const r=Fa();return l3=(t,n,i)=>r(t,n,i)!==0,l3}var d3,Xx;function u6(){if(Xx)return d3;Xx=1;const r=Fa();return d3=(t,n,i)=>r(t,n,i)>=0,d3}var u3,Jx;function h6(){if(Jx)return u3;Jx=1;const r=Fa();return u3=(t,n,i)=>r(t,n,i)<=0,u3}var h3,eC;function nR(){if(eC)return h3;eC=1;const r=tR(),e=rR(),t=s4(),n=u6(),i=d6(),o=h6();return h3=(c,d,h,u)=>{switch(d){case"===":return typeof c=="object"&&(c=c.version),typeof h=="object"&&(h=h.version),c===h;case"!==":return typeof c=="object"&&(c=c.version),typeof h=="object"&&(h=h.version),c!==h;case"":case"=":case"==":return r(c,h,u);case"!=":return e(c,h,u);case">":return t(c,h,u);case">=":return n(c,h,u);case"<":return i(c,h,u);case"<=":return o(c,h,u);default:throw new TypeError(`Invalid operator: ${d}`)}},h3}var f3,tC;function TH(){if(tC)return f3;tC=1;const r=ji(),e=Nf(),{safeRe:t,t:n}=Rm();return f3=(o,a)=>{if(o instanceof r)return o;if(typeof o=="number"&&(o=String(o)),typeof o!="string")return null;a=a||{};let c=null;if(!a.rtl)c=o.match(a.includePrerelease?t[n.COERCEFULL]:t[n.COERCE]);else{const g=a.includePrerelease?t[n.COERCERTLFULL]:t[n.COERCERTL];let _;for(;(_=g.exec(o))&&(!c||c.index+c[0].length!==o.length);)(!c||_.index+_[0].length!==c.index+c[0].length)&&(c=_),g.lastIndex=_.index+_[1].length+_[2].length;g.lastIndex=-1}if(c===null)return null;const d=c[2],h=c[3]||"0",u=c[4]||"0",p=a.includePrerelease&&c[5]?`-${c[5]}`:"",v=a.includePrerelease&&c[6]?`+${c[6]}`:"";return e(`${d}.${h}.${u}${p}${v}`,a)},f3}var p3,rC;function AH(){if(rC)return p3;rC=1;class r{constructor(){this.max=1e3,this.map=new Map}get(t){const n=this.map.get(t);if(n!==void 0)return this.map.delete(t),this.map.set(t,n),n}delete(t){return this.map.delete(t)}set(t,n){if(!this.delete(t)&&n!==void 0){if(this.map.size>=this.max){const o=this.map.keys().next().value;this.delete(o)}this.map.set(t,n)}return this}}return p3=r,p3}var m3,nC;function ja(){if(nC)return m3;nC=1;const r=/\s+/g;class e{constructor(K,re){if(re=i(re),K instanceof e)return K.loose===!!re.loose&&K.includePrerelease===!!re.includePrerelease?K:new e(K.raw,re);if(K instanceof o)return this.raw=K.value,this.set=[[K]],this.formatted=void 0,this;if(this.options=re,this.loose=!!re.loose,this.includePrerelease=!!re.includePrerelease,this.raw=K.trim().replace(r," "),this.set=this.raw.split("||").map(q=>this.parseRange(q.trim())).filter(q=>q.length),!this.set.length)throw new TypeError(`Invalid SemVer Range: ${this.raw}`);if(this.set.length>1){const q=this.set[0];if(this.set=this.set.filter($=>!b($[0])),this.set.length===0)this.set=[q];else if(this.set.length>1){for(const $ of this.set)if($.length===1&&C($[0])){this.set=[$];break}}}this.formatted=void 0}get range(){if(this.formatted===void 0){this.formatted="";for(let K=0;K<this.set.length;K++){K>0&&(this.formatted+="||");const re=this.set[K];for(let q=0;q<re.length;q++)q>0&&(this.formatted+=" "),this.formatted+=re[q].toString().trim()}}return this.formatted}format(){return this.range}toString(){return this.range}parseRange(K){const q=((this.options.includePrerelease&&g)|(this.options.loose&&_))+":"+K,$=n.get(q);if($)return $;const O=this.options.loose,H=O?d[h.HYPHENRANGELOOSE]:d[h.HYPHENRANGE];K=K.replace(H,we(this.options.includePrerelease)),a("hyphen replace",K),K=K.replace(d[h.COMPARATORTRIM],u),a("comparator trim",K),K=K.replace(d[h.TILDETRIM],p),a("tilde trim",K),K=K.replace(d[h.CARETTRIM],v),a("caret trim",K);let P=K.split(" ").map(Ie=>S(Ie,this.options)).join(" ").split(/\s+/).map(Ie=>Ee(Ie,this.options));O&&(P=P.filter(Ie=>(a("loose invalid filter",Ie,this.options),!!Ie.match(d[h.COMPARATORLOOSE])))),a("range list",P);const N=new Map,ye=P.map(Ie=>new o(Ie,this.options));for(const Ie of ye){if(b(Ie))return[Ie];N.set(Ie.value,Ie)}N.size>1&&N.has("")&&N.delete("");const Pe=[...N.values()];return n.set(q,Pe),Pe}intersects(K,re){if(!(K instanceof e))throw new TypeError("a Range is required");return this.set.some(q=>T(q,re)&&K.set.some($=>T($,re)&&q.every(O=>$.every(H=>O.intersects(H,re)))))}test(K){if(!K)return!1;if(typeof K=="string")try{K=new c(K,this.options)}catch{return!1}for(let re=0;re<this.set.length;re++)if(Ce(this.set[re],K,this.options))return!0;return!1}}m3=e;const t=AH(),n=new t,i=c6(),o=c4(),a=a4(),c=ji(),{safeRe:d,t:h,comparatorTrimReplace:u,tildeTrimReplace:p,caretTrimReplace:v}=Rm(),{FLAG_INCLUDE_PRERELEASE:g,FLAG_LOOSE:_}=o4(),b=J=>J.value==="<0.0.0-0",C=J=>J.value==="",T=(J,K)=>{let re=!0;const q=J.slice();let $=q.pop();for(;re&&q.length;)re=q.every(O=>$.intersects(O,K)),$=q.pop();return re},S=(J,K)=>(a("comp",J,K),J=U(J,K),a("caret",J),J=Z(J,K),a("tildes",J),J=Y(J,K),a("xrange",J),J=de(J,K),a("stars",J),J),A=J=>!J||J.toLowerCase()==="x"||J==="*",Z=(J,K)=>J.trim().split(/\s+/).map(re=>B(re,K)).join(" "),B=(J,K)=>{const re=K.loose?d[h.TILDELOOSE]:d[h.TILDE];return J.replace(re,(q,$,O,H,P)=>{a("tilde",J,q,$,O,H,P);let N;return A($)?N="":A(O)?N=`>=${$}.0.0 <${+$+1}.0.0-0`:A(H)?N=`>=${$}.${O}.0 <${$}.${+O+1}.0-0`:P?(a("replaceTilde pr",P),N=`>=${$}.${O}.${H}-${P} <${$}.${+O+1}.0-0`):N=`>=${$}.${O}.${H} <${$}.${+O+1}.0-0`,a("tilde return",N),N})},U=(J,K)=>J.trim().split(/\s+/).map(re=>I(re,K)).join(" "),I=(J,K)=>{a("caret",J,K);const re=K.loose?d[h.CARETLOOSE]:d[h.CARET],q=K.includePrerelease?"-0":"";return J.replace(re,($,O,H,P,N)=>{a("caret",J,$,O,H,P,N);let ye;return A(O)?ye="":A(H)?ye=`>=${O}.0.0${q} <${+O+1}.0.0-0`:A(P)?O==="0"?ye=`>=${O}.${H}.0${q} <${O}.${+H+1}.0-0`:ye=`>=${O}.${H}.0${q} <${+O+1}.0.0-0`:N?(a("replaceCaret pr",N),O==="0"?H==="0"?ye=`>=${O}.${H}.${P}-${N} <${O}.${H}.${+P+1}-0`:ye=`>=${O}.${H}.${P}-${N} <${O}.${+H+1}.0-0`:ye=`>=${O}.${H}.${P}-${N} <${+O+1}.0.0-0`):(a("no pr"),O==="0"?H==="0"?ye=`>=${O}.${H}.${P}${q} <${O}.${H}.${+P+1}-0`:ye=`>=${O}.${H}.${P}${q} <${O}.${+H+1}.0-0`:ye=`>=${O}.${H}.${P} <${+O+1}.0.0-0`),a("caret return",ye),ye})},Y=(J,K)=>(a("replaceXRanges",J,K),J.split(/\s+/).map(re=>le(re,K)).join(" ")),le=(J,K)=>{J=J.trim();const re=K.loose?d[h.XRANGELOOSE]:d[h.XRANGE];return J.replace(re,(q,$,O,H,P,N)=>{a("xRange",J,q,$,O,H,P,N);const ye=A(O),Pe=ye||A(H),Ie=Pe||A(P),Te=Ie;return $==="="&&Te&&($=""),N=K.includePrerelease?"-0":"",ye?$===">"||$==="<"?q="<0.0.0-0":q="*":$&&Te?(Pe&&(H=0),P=0,$===">"?($=">=",Pe?(O=+O+1,H=0,P=0):(H=+H+1,P=0)):$==="<="&&($="<",Pe?O=+O+1:H=+H+1),$==="<"&&(N="-0"),q=`${$+O}.${H}.${P}${N}`):Pe?q=`>=${O}.0.0${N} <${+O+1}.0.0-0`:Ie&&(q=`>=${O}.${H}.0${N} <${O}.${+H+1}.0-0`),a("xRange return",q),q})},de=(J,K)=>(a("replaceStars",J,K),J.trim().replace(d[h.STAR],"")),Ee=(J,K)=>(a("replaceGTE0",J,K),J.trim().replace(d[K.includePrerelease?h.GTE0PRE:h.GTE0],"")),we=J=>(K,re,q,$,O,H,P,N,ye,Pe,Ie,Te)=>(A(q)?re="":A($)?re=`>=${q}.0.0${J?"-0":""}`:A(O)?re=`>=${q}.${$}.0${J?"-0":""}`:H?re=`>=${re}`:re=`>=${re}${J?"-0":""}`,A(ye)?N="":A(Pe)?N=`<${+ye+1}.0.0-0`:A(Ie)?N=`<${ye}.${+Pe+1}.0-0`:Te?N=`<=${ye}.${Pe}.${Ie}-${Te}`:J?N=`<${ye}.${Pe}.${+Ie+1}-0`:N=`<=${N}`,`${re} ${N}`.trim()),Ce=(J,K,re)=>{for(let q=0;q<J.length;q++)if(!J[q].test(K))return!1;if(K.prerelease.length&&!re.includePrerelease){for(let q=0;q<J.length;q++)if(a(J[q].semver),J[q].semver!==o.ANY&&J[q].semver.prerelease.length>0){const $=J[q].semver;if($.major===K.major&&$.minor===K.minor&&$.patch===K.patch)return!0}return!1}return!0};return m3}var v3,iC;function c4(){if(iC)return v3;iC=1;const r=Symbol("SemVer ANY");class e{static get ANY(){return r}constructor(u,p){if(p=t(p),u instanceof e){if(u.loose===!!p.loose)return u;u=u.value}u=u.trim().split(/\s+/).join(" "),a("comparator",u,p),this.options=p,this.loose=!!p.loose,this.parse(u),this.semver===r?this.value="":this.value=this.operator+this.semver.version,a("comp",this)}parse(u){const p=this.options.loose?n[i.COMPARATORLOOSE]:n[i.COMPARATOR],v=u.match(p);if(!v)throw new TypeError(`Invalid comparator: ${u}`);this.operator=v[1]!==void 0?v[1]:"",this.operator==="="&&(this.operator=""),v[2]?this.semver=new c(v[2],this.options.loose):this.semver=r}toString(){return this.value}test(u){if(a("Comparator.test",u,this.options.loose),this.semver===r||u===r)return!0;if(typeof u=="string")try{u=new c(u,this.options)}catch{return!1}return o(u,this.operator,this.semver,this.options)}intersects(u,p){if(!(u instanceof e))throw new TypeError("a Comparator is required");return this.operator===""?this.value===""?!0:new d(u.value,p).test(this.value):u.operator===""?u.value===""?!0:new d(this.value,p).test(u.semver):(p=t(p),p.includePrerelease&&(this.value==="<0.0.0-0"||u.value==="<0.0.0-0")||!p.includePrerelease&&(this.value.startsWith("<0.0.0")||u.value.startsWith("<0.0.0"))?!1:!!(this.operator.startsWith(">")&&u.operator.startsWith(">")||this.operator.startsWith("<")&&u.operator.startsWith("<")||this.semver.version===u.semver.version&&this.operator.includes("=")&&u.operator.includes("=")||o(this.semver,"<",u.semver,p)&&this.operator.startsWith(">")&&u.operator.startsWith("<")||o(this.semver,">",u.semver,p)&&this.operator.startsWith("<")&&u.operator.startsWith(">")))}}v3=e;const t=c6(),{safeRe:n,t:i}=Rm(),o=nR(),a=a4(),c=ji(),d=ja();return v3}var g3,oC;function l4(){if(oC)return g3;oC=1;const r=ja();return g3=(t,n,i)=>{try{n=new r(n,i)}catch{return!1}return n.test(t)},g3}var y3,aC;function IH(){if(aC)return y3;aC=1;const r=ja();return y3=(t,n)=>new r(t,n).set.map(i=>i.map(o=>o.value).join(" ").trim().split(" ")),y3}var _3,sC;function RH(){if(sC)return _3;sC=1;const r=ji(),e=ja();return _3=(n,i,o)=>{let a=null,c=null,d=null;try{d=new e(i,o)}catch{return null}return n.forEach(h=>{d.test(h)&&(!a||c.compare(h)===-1)&&(a=h,c=new r(a,o))}),a},_3}var b3,cC;function PH(){if(cC)return b3;cC=1;const r=ji(),e=ja();return b3=(n,i,o)=>{let a=null,c=null,d=null;try{d=new e(i,o)}catch{return null}return n.forEach(h=>{d.test(h)&&(!a||c.compare(h)===1)&&(a=h,c=new r(a,o))}),a},b3}var w3,lC;function MH(){if(lC)return w3;lC=1;const r=ji(),e=ja(),t=s4();return w3=(i,o)=>{i=new e(i,o);let a=new r("0.0.0");if(i.test(a)||(a=new r("0.0.0-0"),i.test(a)))return a;a=null;for(let c=0;c<i.set.length;++c){const d=i.set[c];let h=null;d.forEach(u=>{const p=new r(u.semver.version);switch(u.operator){case">":p.prerelease.length===0?p.patch++:p.prerelease.push(0),p.raw=p.format();case"":case">=":(!h||t(p,h))&&(h=p);break;case"<":case"<=":break;default:throw new Error(`Unexpected operation: ${u.operator}`)}}),h&&(!a||t(a,h))&&(a=h)}return a&&i.test(a)?a:null},w3}var x3,dC;function $H(){if(dC)return x3;dC=1;const r=ja();return x3=(t,n)=>{try{return new r(t,n).range||"*"}catch{return null}},x3}var C3,uC;function f6(){if(uC)return C3;uC=1;const r=ji(),e=c4(),{ANY:t}=e,n=ja(),i=l4(),o=s4(),a=d6(),c=h6(),d=u6();return C3=(u,p,v,g)=>{u=new r(u,g),p=new n(p,g);let _,b,C,T,S;switch(v){case">":_=o,b=c,C=a,T=">",S=">=";break;case"<":_=a,b=d,C=o,T="<",S="<=";break;default:throw new TypeError('Must provide a hilo val of "<" or ">"')}if(i(u,p,g))return!1;for(let A=0;A<p.set.length;++A){const Z=p.set[A];let B=null,U=null;if(Z.forEach(I=>{I.semver===t&&(I=new e(">=0.0.0")),B=B||I,U=U||I,_(I.semver,B.semver,g)?B=I:C(I.semver,U.semver,g)&&(U=I)}),B.operator===T||B.operator===S||(!U.operator||U.operator===T)&&b(u,U.semver))return!1;if(U.operator===S&&C(u,U.semver))return!1}return!0},C3}var k3,hC;function OH(){if(hC)return k3;hC=1;const r=f6();return k3=(t,n,i)=>r(t,n,">",i),k3}var E3,fC;function ZH(){if(fC)return E3;fC=1;const r=f6();return E3=(t,n,i)=>r(t,n,"<",i),E3}var S3,pC;function LH(){if(pC)return S3;pC=1;const r=ja();return S3=(t,n,i)=>(t=new r(t,i),n=new r(n,i),t.intersects(n,i)),S3}var T3,mC;function HH(){if(mC)return T3;mC=1;const r=l4(),e=Fa();return T3=(t,n,i)=>{const o=[];let a=null,c=null;const d=t.sort((v,g)=>e(v,g,i));for(const v of d)r(v,n,i)?(c=v,a||(a=v)):(c&&o.push([a,c]),c=null,a=null);a&&o.push([a,null]);const h=[];for(const[v,g]of o)v===g?h.push(v):!g&&v===d[0]?h.push("*"):g?v===d[0]?h.push(`<=${g}`):h.push(`${v} - ${g}`):h.push(`>=${v}`);const u=h.join(" || "),p=typeof n.raw=="string"?n.raw:String(n);return u.length<p.length?u:n},T3}var A3,vC;function NH(){if(vC)return A3;vC=1;const r=ja(),e=c4(),{ANY:t}=e,n=l4(),i=Fa(),o=(p,v,g={})=>{if(p===v)return!0;p=new r(p,g),v=new r(v,g);let _=!1;e:for(const b of p.set){for(const C of v.set){const T=d(b,C,g);if(_=_||T!==null,T)continue e}if(_)return!1}return!0},a=[new e(">=0.0.0-0")],c=[new e(">=0.0.0")],d=(p,v,g)=>{if(p===v)return!0;if(p.length===1&&p[0].semver===t){if(v.length===1&&v[0].semver===t)return!0;g.includePrerelease?p=a:p=c}if(v.length===1&&v[0].semver===t){if(g.includePrerelease)return!0;v=c}const _=new Set;let b,C;for(const Y of p)Y.operator===">"||Y.operator===">="?b=h(b,Y,g):Y.operator==="<"||Y.operator==="<="?C=u(C,Y,g):_.add(Y.semver);if(_.size>1)return null;let T;if(b&&C){if(T=i(b.semver,C.semver,g),T>0)return null;if(T===0&&(b.operator!==">="||C.operator!=="<="))return null}for(const Y of _){if(b&&!n(Y,String(b),g)||C&&!n(Y,String(C),g))return null;for(const le of v)if(!n(Y,String(le),g))return!1;return!0}let S,A,Z,B,U=C&&!g.includePrerelease&&C.semver.prerelease.length?C.semver:!1,I=b&&!g.includePrerelease&&b.semver.prerelease.length?b.semver:!1;U&&U.prerelease.length===1&&C.operator==="<"&&U.prerelease[0]===0&&(U=!1);for(const Y of v){if(B=B||Y.operator===">"||Y.operator===">=",Z=Z||Y.operator==="<"||Y.operator==="<=",b){if(I&&Y.semver.prerelease&&Y.semver.prerelease.length&&Y.semver.major===I.major&&Y.semver.minor===I.minor&&Y.semver.patch===I.patch&&(I=!1),Y.operator===">"||Y.operator===">="){if(S=h(b,Y,g),S===Y&&S!==b)return!1}else if(b.operator===">="&&!n(b.semver,String(Y),g))return!1}if(C){if(U&&Y.semver.prerelease&&Y.semver.prerelease.length&&Y.semver.major===U.major&&Y.semver.minor===U.minor&&Y.semver.patch===U.patch&&(U=!1),Y.operator==="<"||Y.operator==="<="){if(A=u(C,Y,g),A===Y&&A!==C)return!1}else if(C.operator==="<="&&!n(C.semver,String(Y),g))return!1}if(!Y.operator&&(C||b)&&T!==0)return!1}return!(b&&Z&&!C&&T!==0||C&&B&&!b&&T!==0||I||U)},h=(p,v,g)=>{if(!p)return v;const _=i(p.semver,v.semver,g);return _>0?p:_<0||v.operator===">"&&p.operator===">="?v:p},u=(p,v,g)=>{if(!p)return v;const _=i(p.semver,v.semver,g);return _<0?p:_>0||v.operator==="<"&&p.operator==="<="?v:p};return A3=o,A3}var I3,gC;function DH(){if(gC)return I3;gC=1;const r=Rm(),e=o4(),t=ji(),n=eR(),i=Nf(),o=mH(),a=vH(),c=gH(),d=yH(),h=_H(),u=bH(),p=wH(),v=xH(),g=Fa(),_=CH(),b=kH(),C=l6(),T=EH(),S=SH(),A=s4(),Z=d6(),B=tR(),U=rR(),I=u6(),Y=h6(),le=nR(),de=TH(),Ee=c4(),we=ja(),Ce=l4(),J=IH(),K=RH(),re=PH(),q=MH(),$=$H(),O=f6(),H=OH(),P=ZH(),N=LH(),ye=HH(),Pe=NH();return I3={parse:i,valid:o,clean:a,inc:c,diff:d,major:h,minor:u,patch:p,prerelease:v,compare:g,rcompare:_,compareLoose:b,compareBuild:C,sort:T,rsort:S,gt:A,lt:Z,eq:B,neq:U,gte:I,lte:Y,cmp:le,coerce:de,Comparator:Ee,Range:we,satisfies:Ce,toComparators:J,maxSatisfying:K,minSatisfying:re,minVersion:q,validRange:$,outside:O,gtr:H,ltr:P,intersects:N,simplifyRange:ye,subset:Pe,SemVer:t,re:r.re,src:r.src,tokens:r.t,SEMVER_SPEC_VERSION:e.SEMVER_SPEC_VERSION,RELEASE_TYPES:e.RELEASE_TYPES,compareIdentifiers:n.compareIdentifiers,rcompareIdentifiers:n.rcompareIdentifiers},I3}var _b=DH();const ep=Hu(_b);class fs extends _b.SemVer{satisfies(e){return _b.satisfies(this,e)}}var VH={};let FH=class{constructor(e){this.domain=e,this.level=Number(VH.FUSION_LOG_LEVEL)||1}_createMessage(e){return[`%c FUSION FRAMEWORK %c ${this.domain} %c %s`,"background: rgb(179, 13, 47); color: white; padding: 1px;","background: rgb(244, 244, 244); color: rgb(36, 55, 70); padding: 1px;","background: none; color: inherit",...e.reduce((t,n)=>t.concat(n,`
41
+ `),[])]}debug(...e){this.level>3&&console.debug(...this._createMessage(e))}info(...e){this.level>2&&console.info(...this._createMessage(e))}warn(...e){this.level>1&&console.warn(...this._createMessage(e))}error(...e){this.level>0&&console.error(...this._createMessage(e))}};class iR extends FH{formatModuleName(e){return`📦\x1B[1;32m${(typeof e=="string"?e:e.name).replace(/([A-Z])/g," $1").toUpperCase()}\x1B[0m`}}var bb=function(r,e){return bb=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,n){t.__proto__=n}||function(t,n){for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(t[i]=n[i])},bb(r,e)};function Si(r,e){if(typeof e!="function"&&e!==null)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");bb(r,e);function t(){this.constructor=r}r.prototype=e===null?Object.create(e):(t.prototype=e.prototype,new t)}var Sn=function(){return Sn=Object.assign||function(e){for(var t,n=1,i=arguments.length;n<i;n++){t=arguments[n];for(var o in t)Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o])}return e},Sn.apply(this,arguments)};function oR(r,e){var t={};for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&e.indexOf(n)<0&&(t[n]=r[n]);if(r!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,n=Object.getOwnPropertySymbols(r);i<n.length;i++)e.indexOf(n[i])<0&&Object.prototype.propertyIsEnumerable.call(r,n[i])&&(t[n[i]]=r[n[i]]);return t}function R(r,e,t,n){var i=arguments.length,o=i<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,t):n,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(r,e,t,n);else for(var c=r.length-1;c>=0;c--)(a=r[c])&&(o=(i<3?a(o):i>3?a(e,t,o):a(e,t))||o);return i>3&&o&&Object.defineProperty(e,t,o),o}function uc(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})}function aR(r,e){var t={label:0,sent:function(){if(o[0]&1)throw o[1];return o[1]},trys:[],ops:[]},n,i,o,a=Object.create((typeof Iterator=="function"?Iterator:Object).prototype);return a.next=c(0),a.throw=c(1),a.return=c(2),typeof Symbol=="function"&&(a[Symbol.iterator]=function(){return this}),a;function c(h){return function(u){return d([h,u])}}function d(h){if(n)throw new TypeError("Generator is already executing.");for(;a&&(a=0,h[0]&&(t=0)),t;)try{if(n=1,i&&(o=h[0]&2?i.return:h[0]?i.throw||((o=i.return)&&o.call(i),0):i.next)&&!(o=o.call(i,h[1])).done)return o;switch(i=0,o&&(h=[h[0]&2,o.value]),h[0]){case 0:case 1:o=h;break;case 4:return t.label++,{value:h[1],done:!1};case 5:t.label++,i=h[1],h=[0];continue;case 7:h=t.ops.pop(),t.trys.pop();continue;default:if(o=t.trys,!(o=o.length>0&&o[o.length-1])&&(h[0]===6||h[0]===2)){t=0;continue}if(h[0]===3&&(!o||h[1]>o[0]&&h[1]<o[3])){t.label=h[1];break}if(h[0]===6&&t.label<o[1]){t.label=o[1],o=h;break}if(o&&t.label<o[2]){t.label=o[2],t.ops.push(h);break}o[2]&&t.ops.pop(),t.trys.pop();continue}h=e.call(r,t)}catch(u){h=[6,u],i=0}finally{n=o=0}if(h[0]&5)throw h[1];return{value:h[0]?h[1]:void 0,done:!0}}}function Di(r){var e=typeof Symbol=="function"&&Symbol.iterator,t=e&&r[e],n=0;if(t)return t.call(r);if(r&&typeof r.length=="number")return{next:function(){return r&&n>=r.length&&(r=void 0),{value:r&&r[n++],done:!r}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")}function ys(r,e){var t=typeof Symbol=="function"&&r[Symbol.iterator];if(!t)return r;var n=t.call(r),i,o=[],a;try{for(;(e===void 0||e-- >0)&&!(i=n.next()).done;)o.push(i.value)}catch(c){a={error:c}}finally{try{i&&!i.done&&(t=n.return)&&t.call(n)}finally{if(a)throw a.error}}return o}function vc(r,e,t){if(t||arguments.length===2)for(var n=0,i=e.length,o;n<i;n++)(o||!(n in e))&&(o||(o=Array.prototype.slice.call(e,0,n)),o[n]=e[n]);return r.concat(o||Array.prototype.slice.call(e))}function of(r){return this instanceof of?(this.v=r,this):new of(r)}function jH(r,e,t){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var n=t.apply(r,e||[]),i,o=[];return i=Object.create((typeof AsyncIterator=="function"?AsyncIterator:Object).prototype),c("next"),c("throw"),c("return",a),i[Symbol.asyncIterator]=function(){return this},i;function a(g){return function(_){return Promise.resolve(_).then(g,p)}}function c(g,_){n[g]&&(i[g]=function(b){return new Promise(function(C,T){o.push([g,b,C,T])>1||d(g,b)})},_&&(i[g]=_(i[g])))}function d(g,_){try{h(n[g](_))}catch(b){v(o[0][3],b)}}function h(g){g.value instanceof of?Promise.resolve(g.value.v).then(u,p):v(o[0][2],g)}function u(g){d("next",g)}function p(g){d("throw",g)}function v(g,_){g(_),o.shift(),o.length&&d(o[0][0],o[0][1])}}function zH(r){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var e=r[Symbol.asyncIterator],t;return e?e.call(r):(r=typeof Di=="function"?Di(r):r[Symbol.iterator](),t={},n("next"),n("throw"),n("return"),t[Symbol.asyncIterator]=function(){return this},t);function n(o){t[o]=r[o]&&function(a){return new Promise(function(c,d){a=r[o](a),i(c,d,a.done,a.value)})}}function i(o,a,c,d){Promise.resolve(d).then(function(h){o({value:h,done:c})},a)}}function Ae(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)}function ic(r,e,t,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?r!==e||!i:!e.has(r))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(r,t):i?i.value=t:e.set(r,t),t}function gr(r){return typeof r=="function"}function d4(r){var e=function(n){Error.call(n),n.stack=new Error().stack},t=r(e);return t.prototype=Object.create(Error.prototype),t.prototype.constructor=t,t}var R3=d4(function(r){return function(t){r(this),this.message=t?t.length+` errors occurred during unsubscription:
42
42
  `+t.map(function(n,i){return i+1+") "+n.toString()}).join(`
43
- `):"",this.name="UnsubscriptionError",this.errors=t}});function Jv(r,e){if(r){var t=r.indexOf(e);0<=t&&r.splice(t,1)}}var ti=function(){function r(e){this.initialTeardown=e,this.closed=!1,this._parentage=null,this._finalizers=null}return r.prototype.unsubscribe=function(){var e,t,n,i,o;if(!this.closed){this.closed=!0;var a=this._parentage;if(a)if(this._parentage=null,Array.isArray(a))try{for(var c=Di(a),d=c.next();!d.done;d=c.next()){var h=d.value;h.remove(this)}}catch(b){e={error:b}}finally{try{d&&!d.done&&(t=c.return)&&t.call(c)}finally{if(e)throw e.error}}else a.remove(this);var u=this.initialTeardown;if(gr(u))try{u()}catch(b){o=b instanceof R3?b.errors:[b]}var p=this._finalizers;if(p){this._finalizers=null;try{for(var v=Di(p),g=v.next();!g.done;g=v.next()){var _=g.value;try{yC(_)}catch(b){o=o??[],b instanceof R3?o=vc(vc([],ys(o)),ys(b.errors)):o.push(b)}}}catch(b){n={error:b}}finally{try{g&&!g.done&&(i=v.return)&&i.call(v)}finally{if(n)throw n.error}}}if(o)throw new R3(o)}},r.prototype.add=function(e){var t;if(e&&e!==this)if(this.closed)yC(e);else{if(e instanceof r){if(e.closed||e._hasParent(this))return;e._addParent(this)}(this._finalizers=(t=this._finalizers)!==null&&t!==void 0?t:[]).push(e)}},r.prototype._hasParent=function(e){var t=this._parentage;return t===e||Array.isArray(t)&&t.includes(e)},r.prototype._addParent=function(e){var t=this._parentage;this._parentage=Array.isArray(t)?(t.push(e),t):t?[t,e]:e},r.prototype._removeParent=function(e){var t=this._parentage;t===e?this._parentage=null:Array.isArray(t)&&Jv(t,e)},r.prototype.remove=function(e){var t=this._finalizers;t&&Jv(t,e),e instanceof r&&e._removeParent(this)},r.EMPTY=function(){var e=new r;return e.closed=!0,e}(),r}(),sR=ti.EMPTY;function cR(r){return r instanceof ti||r&&"closed"in r&&gr(r.remove)&&gr(r.add)&&gr(r.unsubscribe)}function yC(r){gr(r)?r():r.unsubscribe()}var BH={Promise:void 0},UH={setTimeout:function(r,e){for(var t=[],n=2;n<arguments.length;n++)t[n-2]=arguments[n];return setTimeout.apply(void 0,vc([r,e],ys(t)))},clearTimeout:function(r){return clearTimeout(r)},delegate:void 0};function lR(r){UH.setTimeout(function(){throw r})}function eg(){}function fv(r){r()}var p6=function(r){Si(e,r);function e(t){var n=r.call(this)||this;return n.isStopped=!1,t?(n.destination=t,cR(t)&&t.add(n)):n.destination=GH,n}return e.create=function(t,n,i){return new hf(t,n,i)},e.prototype.next=function(t){this.isStopped||this._next(t)},e.prototype.error=function(t){this.isStopped||(this.isStopped=!0,this._error(t))},e.prototype.complete=function(){this.isStopped||(this.isStopped=!0,this._complete())},e.prototype.unsubscribe=function(){this.closed||(this.isStopped=!0,r.prototype.unsubscribe.call(this),this.destination=null)},e.prototype._next=function(t){this.destination.next(t)},e.prototype._error=function(t){try{this.destination.error(t)}finally{this.unsubscribe()}},e.prototype._complete=function(){try{this.destination.complete()}finally{this.unsubscribe()}},e}(ti),qH=function(){function r(e){this.partialObserver=e}return r.prototype.next=function(e){var t=this.partialObserver;if(t.next)try{t.next(e)}catch(n){_0(n)}},r.prototype.error=function(e){var t=this.partialObserver;if(t.error)try{t.error(e)}catch(n){_0(n)}else _0(e)},r.prototype.complete=function(){var e=this.partialObserver;if(e.complete)try{e.complete()}catch(t){_0(t)}},r}(),hf=function(r){Si(e,r);function e(t,n,i){var o=r.call(this)||this,a;return gr(t)||!t?a={next:t??void 0,error:n??void 0,complete:i??void 0}:a=t,o.destination=new qH(a),o}return e}(p6);function _0(r){lR(r)}function WH(r){throw r}var GH={closed:!0,next:eg,error:WH,complete:eg},m6=function(){return typeof Symbol=="function"&&Symbol.observable||"@@observable"}();function Ts(r){return r}function KH(r){return r.length===0?Ts:r.length===1?r[0]:function(t){return r.reduce(function(n,i){return i(n)},t)}}var Tt=function(){function r(e){e&&(this._subscribe=e)}return r.prototype.lift=function(e){var t=new r;return t.source=this,t.operator=e,t},r.prototype.subscribe=function(e,t,n){var i=this,o=QH(e)?e:new hf(e,t,n);return fv(function(){var a=i,c=a.operator,d=a.source;o.add(c?c.call(o,d):d?i._subscribe(o):i._trySubscribe(o))}),o},r.prototype._trySubscribe=function(e){try{return this._subscribe(e)}catch(t){e.error(t)}},r.prototype.forEach=function(e,t){var n=this;return t=_C(t),new t(function(i,o){var a=new hf({next:function(c){try{e(c)}catch(d){o(d),a.unsubscribe()}},error:o,complete:i});n.subscribe(a)})},r.prototype._subscribe=function(e){var t;return(t=this.source)===null||t===void 0?void 0:t.subscribe(e)},r.prototype[m6]=function(){return this},r.prototype.pipe=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return KH(e)(this)},r.prototype.toPromise=function(e){var t=this;return e=_C(e),new e(function(n,i){var o;t.subscribe(function(a){return o=a},function(a){return i(a)},function(){return n(o)})})},r.create=function(e){return new r(e)},r}();function _C(r){var e;return(e=r??BH.Promise)!==null&&e!==void 0?e:Promise}function YH(r){return r&&gr(r.next)&&gr(r.error)&&gr(r.complete)}function QH(r){return r&&r instanceof p6||YH(r)&&cR(r)}function XH(r){return gr(r==null?void 0:r.lift)}function Ar(r){return function(e){if(XH(e))return e.lift(function(t){try{return r(t,this)}catch(n){this.error(n)}});throw new TypeError("Unable to lift unknown Observable type")}}function xr(r,e,t,n,i){return new dR(r,e,t,n,i)}var dR=function(r){Si(e,r);function e(t,n,i,o,a,c){var d=r.call(this,t)||this;return d.onFinalize=a,d.shouldUnsubscribe=c,d._next=n?function(h){try{n(h)}catch(u){t.error(u)}}:r.prototype._next,d._error=o?function(h){try{o(h)}catch(u){t.error(u)}finally{this.unsubscribe()}}:r.prototype._error,d._complete=i?function(){try{i()}catch(h){t.error(h)}finally{this.unsubscribe()}}:r.prototype._complete,d}return e.prototype.unsubscribe=function(){var t;if(!this.shouldUnsubscribe||this.shouldUnsubscribe()){var n=this.closed;r.prototype.unsubscribe.call(this),!n&&((t=this.onFinalize)===null||t===void 0||t.call(this))}},e}(p6),JH=d4(function(r){return function(){r(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"}}),Bn=function(r){Si(e,r);function e(){var t=r.call(this)||this;return t.closed=!1,t.currentObservers=null,t.observers=[],t.isStopped=!1,t.hasError=!1,t.thrownError=null,t}return e.prototype.lift=function(t){var n=new bC(this,this);return n.operator=t,n},e.prototype._throwIfClosed=function(){if(this.closed)throw new JH},e.prototype.next=function(t){var n=this;fv(function(){var i,o;if(n._throwIfClosed(),!n.isStopped){n.currentObservers||(n.currentObservers=Array.from(n.observers));try{for(var a=Di(n.currentObservers),c=a.next();!c.done;c=a.next()){var d=c.value;d.next(t)}}catch(h){i={error:h}}finally{try{c&&!c.done&&(o=a.return)&&o.call(a)}finally{if(i)throw i.error}}}})},e.prototype.error=function(t){var n=this;fv(function(){if(n._throwIfClosed(),!n.isStopped){n.hasError=n.isStopped=!0,n.thrownError=t;for(var i=n.observers;i.length;)i.shift().error(t)}})},e.prototype.complete=function(){var t=this;fv(function(){if(t._throwIfClosed(),!t.isStopped){t.isStopped=!0;for(var n=t.observers;n.length;)n.shift().complete()}})},e.prototype.unsubscribe=function(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null},Object.defineProperty(e.prototype,"observed",{get:function(){var t;return((t=this.observers)===null||t===void 0?void 0:t.length)>0},enumerable:!1,configurable:!0}),e.prototype._trySubscribe=function(t){return this._throwIfClosed(),r.prototype._trySubscribe.call(this,t)},e.prototype._subscribe=function(t){return this._throwIfClosed(),this._checkFinalizedStatuses(t),this._innerSubscribe(t)},e.prototype._innerSubscribe=function(t){var n=this,i=this,o=i.hasError,a=i.isStopped,c=i.observers;return o||a?sR:(this.currentObservers=null,c.push(t),new ti(function(){n.currentObservers=null,Jv(c,t)}))},e.prototype._checkFinalizedStatuses=function(t){var n=this,i=n.hasError,o=n.thrownError,a=n.isStopped;i?t.error(o):a&&t.complete()},e.prototype.asObservable=function(){var t=new Tt;return t.source=this,t},e.create=function(t,n){return new bC(t,n)},e}(Tt),bC=function(r){Si(e,r);function e(t,n){var i=r.call(this)||this;return i.destination=t,i.source=n,i}return e.prototype.next=function(t){var n,i;(i=(n=this.destination)===null||n===void 0?void 0:n.next)===null||i===void 0||i.call(n,t)},e.prototype.error=function(t){var n,i;(i=(n=this.destination)===null||n===void 0?void 0:n.error)===null||i===void 0||i.call(n,t)},e.prototype.complete=function(){var t,n;(n=(t=this.destination)===null||t===void 0?void 0:t.complete)===null||n===void 0||n.call(t)},e.prototype._subscribe=function(t){var n,i;return(i=(n=this.source)===null||n===void 0?void 0:n.subscribe(t))!==null&&i!==void 0?i:sR},e}(Bn),Df=function(r){Si(e,r);function e(t){var n=r.call(this)||this;return n._value=t,n}return Object.defineProperty(e.prototype,"value",{get:function(){return this.getValue()},enumerable:!1,configurable:!0}),e.prototype._subscribe=function(t){var n=r.prototype._subscribe.call(this,t);return!n.closed&&t.next(this._value),n},e.prototype.getValue=function(){var t=this,n=t.hasError,i=t.thrownError,o=t._value;if(n)throw i;return this._throwIfClosed(),o},e.prototype.next=function(t){r.prototype.next.call(this,this._value=t)},e}(Bn),v6={now:function(){return(v6.delegate||Date).now()},delegate:void 0},uR=function(r){Si(e,r);function e(t,n,i){t===void 0&&(t=1/0),n===void 0&&(n=1/0),i===void 0&&(i=v6);var o=r.call(this)||this;return o._bufferSize=t,o._windowTime=n,o._timestampProvider=i,o._buffer=[],o._infiniteTimeWindow=!0,o._infiniteTimeWindow=n===1/0,o._bufferSize=Math.max(1,t),o._windowTime=Math.max(1,n),o}return e.prototype.next=function(t){var n=this,i=n.isStopped,o=n._buffer,a=n._infiniteTimeWindow,c=n._timestampProvider,d=n._windowTime;i||(o.push(t),!a&&o.push(c.now()+d)),this._trimBuffer(),r.prototype.next.call(this,t)},e.prototype._subscribe=function(t){this._throwIfClosed(),this._trimBuffer();for(var n=this._innerSubscribe(t),i=this,o=i._infiniteTimeWindow,a=i._buffer,c=a.slice(),d=0;d<c.length&&!t.closed;d+=o?1:2)t.next(c[d]);return this._checkFinalizedStatuses(t),n},e.prototype._trimBuffer=function(){var t=this,n=t._bufferSize,i=t._timestampProvider,o=t._buffer,a=t._infiniteTimeWindow,c=(a?1:2)*n;if(n<1/0&&c<o.length&&o.splice(0,o.length-c),!a){for(var d=i.now(),h=0,u=1;u<o.length&&o[u]<=d;u+=2)h=u;h&&o.splice(0,h+1)}},e}(Bn),eN=function(r){Si(e,r);function e(t,n){return r.call(this)||this}return e.prototype.schedule=function(t,n){return this},e}(ti),wC={setInterval:function(r,e){for(var t=[],n=2;n<arguments.length;n++)t[n-2]=arguments[n];return setInterval.apply(void 0,vc([r,e],ys(t)))},clearInterval:function(r){return clearInterval(r)},delegate:void 0},tN=function(r){Si(e,r);function e(t,n){var i=r.call(this,t,n)||this;return i.scheduler=t,i.work=n,i.pending=!1,i}return e.prototype.schedule=function(t,n){var i;if(n===void 0&&(n=0),this.closed)return this;this.state=t;var o=this.id,a=this.scheduler;return o!=null&&(this.id=this.recycleAsyncId(a,o,n)),this.pending=!0,this.delay=n,this.id=(i=this.id)!==null&&i!==void 0?i:this.requestAsyncId(a,this.id,n),this},e.prototype.requestAsyncId=function(t,n,i){return i===void 0&&(i=0),wC.setInterval(t.flush.bind(t,this),i)},e.prototype.recycleAsyncId=function(t,n,i){if(i===void 0&&(i=0),i!=null&&this.delay===i&&this.pending===!1)return n;n!=null&&wC.clearInterval(n)},e.prototype.execute=function(t,n){if(this.closed)return new Error("executing a cancelled action");this.pending=!1;var i=this._execute(t,n);if(i)return i;this.pending===!1&&this.id!=null&&(this.id=this.recycleAsyncId(this.scheduler,this.id,null))},e.prototype._execute=function(t,n){var i=!1,o;try{this.work(t)}catch(a){i=!0,o=a||new Error("Scheduled action threw falsy error")}if(i)return this.unsubscribe(),o},e.prototype.unsubscribe=function(){if(!this.closed){var t=this,n=t.id,i=t.scheduler,o=i.actions;this.work=this.state=this.scheduler=null,this.pending=!1,Jv(o,this),n!=null&&(this.id=this.recycleAsyncId(i,n,null)),this.delay=null,r.prototype.unsubscribe.call(this)}},e}(eN),xC=function(){function r(e,t){t===void 0&&(t=r.now),this.schedulerActionCtor=e,this.now=t}return r.prototype.schedule=function(e,t,n){return t===void 0&&(t=0),new this.schedulerActionCtor(this,e).schedule(n,t)},r.now=v6.now,r}(),rN=function(r){Si(e,r);function e(t,n){n===void 0&&(n=xC.now);var i=r.call(this,t,n)||this;return i.actions=[],i._active=!1,i}return e.prototype.flush=function(t){var n=this.actions;if(this._active){n.push(t);return}var i;this._active=!0;do if(i=t.execute(t.state,t.delay))break;while(t=n.shift());if(this._active=!1,i){for(;t=n.shift();)t.unsubscribe();throw i}},e}(xC),ff=new rN(tN),nN=ff,Tr=new Tt(function(r){return r.complete()});function hR(r){return r&&gr(r.schedule)}function g6(r){return r[r.length-1]}function y6(r){return gr(g6(r))?r.pop():void 0}function u4(r){return hR(g6(r))?r.pop():void 0}function iN(r,e){return typeof g6(r)=="number"?r.pop():e}var _6=function(r){return r&&typeof r.length=="number"&&typeof r!="function"};function fR(r){return gr(r==null?void 0:r.then)}function pR(r){return gr(r[m6])}function mR(r){return Symbol.asyncIterator&&gr(r==null?void 0:r[Symbol.asyncIterator])}function vR(r){return new TypeError("You provided "+(r!==null&&typeof r=="object"?"an invalid object":"'"+r+"'")+" where a stream was expected. You can provide an Observable, Promise, ReadableStream, Array, AsyncIterable, or Iterable.")}function oN(){return typeof Symbol!="function"||!Symbol.iterator?"@@iterator":Symbol.iterator}var gR=oN();function yR(r){return gr(r==null?void 0:r[gR])}function _R(r){return jH(this,arguments,function(){var t,n,i,o;return aR(this,function(a){switch(a.label){case 0:t=r.getReader(),a.label=1;case 1:a.trys.push([1,,9,10]),a.label=2;case 2:return[4,of(t.read())];case 3:return n=a.sent(),i=n.value,o=n.done,o?[4,of(void 0)]:[3,5];case 4:return[2,a.sent()];case 5:return[4,of(i)];case 6:return[4,a.sent()];case 7:return a.sent(),[3,2];case 8:return[3,10];case 9:return t.releaseLock(),[7];case 10:return[2]}})})}function bR(r){return gr(r==null?void 0:r.getReader)}function Zn(r){if(r instanceof Tt)return r;if(r!=null){if(pR(r))return aN(r);if(_6(r))return sN(r);if(fR(r))return cN(r);if(mR(r))return wR(r);if(yR(r))return lN(r);if(bR(r))return dN(r)}throw vR(r)}function aN(r){return new Tt(function(e){var t=r[m6]();if(gr(t.subscribe))return t.subscribe(e);throw new TypeError("Provided object does not correctly implement Symbol.observable")})}function sN(r){return new Tt(function(e){for(var t=0;t<r.length&&!e.closed;t++)e.next(r[t]);e.complete()})}function cN(r){return new Tt(function(e){r.then(function(t){e.closed||(e.next(t),e.complete())},function(t){return e.error(t)}).then(null,lR)})}function lN(r){return new Tt(function(e){var t,n;try{for(var i=Di(r),o=i.next();!o.done;o=i.next()){var a=o.value;if(e.next(a),e.closed)return}}catch(c){t={error:c}}finally{try{o&&!o.done&&(n=i.return)&&n.call(i)}finally{if(t)throw t.error}}e.complete()})}function wR(r){return new Tt(function(e){uN(r,e).catch(function(t){return e.error(t)})})}function dN(r){return wR(_R(r))}function uN(r,e){var t,n,i,o;return uc(this,void 0,void 0,function(){var a,c;return aR(this,function(d){switch(d.label){case 0:d.trys.push([0,5,6,11]),t=zH(r),d.label=1;case 1:return[4,t.next()];case 2:if(n=d.sent(),!!n.done)return[3,4];if(a=n.value,e.next(a),e.closed)return[2];d.label=3;case 3:return[3,1];case 4:return[3,11];case 5:return c=d.sent(),i={error:c},[3,11];case 6:return d.trys.push([6,,9,10]),n&&!n.done&&(o=t.return)?[4,o.call(t)]:[3,8];case 7:d.sent(),d.label=8;case 8:return[3,10];case 9:if(i)throw i.error;return[7];case 10:return[7];case 11:return e.complete(),[2]}})})}function hc(r,e,t,n,i){n===void 0&&(n=0),i===void 0&&(i=!1);var o=e.schedule(function(){t(),i?r.add(this.schedule(null,n)):this.unsubscribe()},n);if(r.add(o),!i)return o}function tg(r,e){return e===void 0&&(e=0),Ar(function(t,n){t.subscribe(xr(n,function(i){return hc(n,r,function(){return n.next(i)},e)},function(){return hc(n,r,function(){return n.complete()},e)},function(i){return hc(n,r,function(){return n.error(i)},e)}))})}function xR(r,e){return e===void 0&&(e=0),Ar(function(t,n){n.add(r.schedule(function(){return t.subscribe(n)},e))})}function hN(r,e){return Zn(r).pipe(xR(e),tg(e))}function fN(r,e){return Zn(r).pipe(xR(e),tg(e))}function pN(r,e){return new Tt(function(t){var n=0;return e.schedule(function(){n===r.length?t.complete():(t.next(r[n++]),t.closed||this.schedule())})})}function mN(r,e){return new Tt(function(t){var n;return hc(t,e,function(){n=r[gR](),hc(t,e,function(){var i,o,a;try{i=n.next(),o=i.value,a=i.done}catch(c){t.error(c);return}a?t.complete():t.next(o)},0,!0)}),function(){return gr(n==null?void 0:n.return)&&n.return()}})}function CR(r,e){if(!r)throw new Error("Iterable cannot be null");return new Tt(function(t){hc(t,e,function(){var n=r[Symbol.asyncIterator]();hc(t,e,function(){n.next().then(function(i){i.done?t.complete():t.next(i.value)})},0,!0)})})}function vN(r,e){return CR(_R(r),e)}function gN(r,e){if(r!=null){if(pR(r))return hN(r,e);if(_6(r))return pN(r,e);if(fR(r))return fN(r,e);if(mR(r))return CR(r,e);if(yR(r))return mN(r,e);if(bR(r))return vN(r,e)}throw vR(r)}function rt(r,e){return e?gN(r,e):Zn(r)}function It(){for(var r=[],e=0;e<arguments.length;e++)r[e]=arguments[e];var t=u4(r);return rt(r,t)}function kR(r,e){var t=gr(r)?r:function(){return r},n=function(i){return i.error(t())};return new Tt(n)}var Pm=d4(function(r){return function(){r(this),this.name="EmptyError",this.message="no elements in sequence"}});function lr(r,e){var t=typeof e=="object";return new Promise(function(n,i){var o=!1,a;r.subscribe({next:function(c){a=c,o=!0},error:i,complete:function(){o?n(a):t?n(e.defaultValue):i(new Pm)}})})}function zn(r,e){var t=typeof e=="object";return new Promise(function(n,i){var o=new hf({next:function(a){n(a),o.unsubscribe()},error:i,complete:function(){t?n(e.defaultValue):i(new Pm)}});r.subscribe(o)})}function ER(r){return r instanceof Date&&!isNaN(r)}var yN=d4(function(r){return function(t){t===void 0&&(t=null),r(this),this.message="Timeout has occurred",this.name="TimeoutError",this.info=t}});function Gs(r,e){var t=ER(r)?{first:r}:typeof r=="number"?{each:r}:r,n=t.first,i=t.each,o=t.with,a=o===void 0?_N:o,c=t.scheduler,d=c===void 0?ff:c,h=t.meta,u=h===void 0?null:h;if(n==null&&i==null)throw new TypeError("No timeout provided.");return Ar(function(p,v){var g,_,b=null,C=0,T=function(S){_=hc(v,d,function(){try{g.unsubscribe(),Zn(a({meta:u,lastValue:b,seen:C})).subscribe(v)}catch(A){v.error(A)}},S)};g=p.subscribe(xr(v,function(S){_==null||_.unsubscribe(),C++,v.next(b=S),i>0&&T(i)},void 0,void 0,function(){_!=null&&_.closed||_==null||_.unsubscribe(),b=null})),!C&&T(n!=null?typeof n=="number"?n:+n-d.now():i)})}function _N(r){throw new yN(r)}function me(r,e){return Ar(function(t,n){var i=0;t.subscribe(xr(n,function(o){n.next(r.call(e,o,i++))}))})}var bN=Array.isArray;function wN(r,e){return bN(e)?r.apply(void 0,vc([],ys(e))):r(e)}function b6(r){return me(function(e){return wN(r,e)})}var xN=Array.isArray,CN=Object.getPrototypeOf,kN=Object.prototype,EN=Object.keys;function SR(r){if(r.length===1){var e=r[0];if(xN(e))return{args:e,keys:null};if(SN(e)){var t=EN(e);return{args:t.map(function(n){return e[n]}),keys:t}}}return{args:r,keys:null}}function SN(r){return r&&typeof r=="object"&&CN(r)===kN}function TR(r,e){return r.reduce(function(t,n,i){return t[n]=e[i],t},{})}function TN(){for(var r=[],e=0;e<arguments.length;e++)r[e]=arguments[e];var t=u4(r),n=y6(r),i=SR(r),o=i.args,a=i.keys;if(o.length===0)return rt([],t);var c=new Tt(AN(o,t,a?function(d){return TR(a,d)}:Ts));return n?c.pipe(b6(n)):c}function AN(r,e,t){return t===void 0&&(t=Ts),function(n){CC(e,function(){for(var i=r.length,o=new Array(i),a=i,c=i,d=function(u){CC(e,function(){var p=rt(r[u],e),v=!1;p.subscribe(xr(n,function(g){o[u]=g,v||(v=!0,c--),c||n.next(t(o.slice()))},function(){--a||n.complete()}))},n)},h=0;h<i;h++)d(h)},n)}}function CC(r,e,t){r?hc(t,r,e):e()}function AR(r,e,t,n,i,o,a,c){var d=[],h=0,u=0,p=!1,v=function(){p&&!d.length&&!h&&e.complete()},g=function(b){return h<n?_(b):d.push(b)},_=function(b){o&&e.next(b),h++;var C=!1;Zn(t(b,u++)).subscribe(xr(e,function(T){i==null||i(T),o?g(T):e.next(T)},function(){C=!0},void 0,function(){if(C)try{h--;for(var T=function(){var S=d.shift();a||_(S)};d.length&&h<n;)T();v()}catch(S){e.error(S)}}))};return r.subscribe(xr(e,g,function(){p=!0,v()})),function(){c==null||c()}}function Jn(r,e,t){return t===void 0&&(t=1/0),gr(e)?Jn(function(n,i){return me(function(o,a){return e(n,o,i,a)})(Zn(r(n,i)))},t):(typeof e=="number"&&(t=e),Ar(function(n,i){return AR(n,i,r,t)}))}function IR(r){return r===void 0&&(r=1/0),Jn(Ts,r)}function IN(){return IR(1)}function xl(){for(var r=[],e=0;e<arguments.length;e++)r[e]=arguments[e];return IN()(rt(r,u4(r)))}function pv(){for(var r=[],e=0;e<arguments.length;e++)r[e]=arguments[e];var t=y6(r),n=SR(r),i=n.args,o=n.keys,a=new Tt(function(c){var d=i.length;if(!d){c.complete();return}for(var h=new Array(d),u=d,p=d,v=function(_){var b=!1;Zn(i[_]).subscribe(xr(c,function(C){b||(b=!0,p--),h[_]=C},function(){return u--},void 0,function(){(!u||!b)&&(p||c.next(o?TR(o,h):h),c.complete())}))},g=0;g<d;g++)v(g)});return t?a.pipe(b6(t)):a}var RN=["addListener","removeListener"],PN=["addEventListener","removeEventListener"],MN=["on","off"];function iu(r,e,t,n){if(gr(t)&&(n=t,t=void 0),n)return iu(r,e,t).pipe(b6(n));var i=ys(ZN(r)?PN.map(function(c){return function(d){return r[c](e,d,t)}}):$N(r)?RN.map(kC(r,e)):ON(r)?MN.map(kC(r,e)):[],2),o=i[0],a=i[1];if(!o&&_6(r))return Jn(function(c){return iu(c,e,t)})(Zn(r));if(!o)throw new TypeError("Invalid event target");return new Tt(function(c){var d=function(){for(var h=[],u=0;u<arguments.length;u++)h[u]=arguments[u];return c.next(1<h.length?h:h[0])};return o(d),function(){return a(d)}})}function kC(r,e){return function(t){return function(n){return r[t](e,n)}}}function $N(r){return gr(r.addListener)&&gr(r.removeListener)}function ON(r){return gr(r.on)&&gr(r.off)}function ZN(r){return gr(r.addEventListener)&&gr(r.removeEventListener)}function w6(r,e,t){r===void 0&&(r=0),t===void 0&&(t=nN);var n=-1;return e!=null&&(hR(e)?t=e:n=e),new Tt(function(i){var o=ER(r)?+r-t.now():r;o<0&&(o=0);var a=0;return t.schedule(function(){i.closed||(i.next(a++),0<=n?this.schedule(void 0,n):i.complete())},o)})}function LN(r,e){return e===void 0&&(e=ff),w6(r,r,e)}function P3(){for(var r=[],e=0;e<arguments.length;e++)r[e]=arguments[e];var t=u4(r),n=iN(r,1/0),i=r;return i.length?i.length===1?Zn(i[0]):IR(n)(rt(i,t)):Tr}function $e(r,e){return Ar(function(t,n){var i=0;t.subscribe(xr(n,function(o){return r.call(e,o,i++)&&n.next(o)}))})}function HN(r){return function(e){for(var t=[],n=function(o){t.push(Zn(r[o]).subscribe(xr(e,function(a){if(t){for(var c=0;c<t.length;c++)c!==o&&t[c].unsubscribe();t=null}e.next(a)})))},i=0;t&&!e.closed&&i<r.length;i++)n(i)}}function Vt(r){return Ar(function(e,t){var n=null,i=!1,o;n=e.subscribe(xr(t,void 0,void 0,function(a){o=Zn(r(a,Vt(r)(e))),n?(n.unsubscribe(),n=null,o.subscribe(t)):i=!0})),i&&(n.unsubscribe(),n=null,o.subscribe(t))})}function RR(r,e,t,n,i){return function(o,a){var c=t,d=e,h=0;o.subscribe(xr(a,function(u){var p=h++;d=c?r(d,u,p):(c=!0,u),n&&a.next(d)},i&&function(){c&&a.next(d),a.complete()}))}}function Bp(r,e){return Ar(RR(r,e,arguments.length>=2,!1,!0))}function _s(r,e){return gr(e)?Jn(r,e,1):Jn(r,1)}function x6(r){return Ar(function(e,t){var n=!1;e.subscribe(xr(t,function(i){n=!0,t.next(i)},function(){n||t.next(r),t.complete()}))})}function tp(r){return r<=0?function(){return Tr}:Ar(function(e,t){var n=0;e.subscribe(xr(t,function(i){++n<=r&&(t.next(i),r<=n&&t.complete())}))})}function rg(r,e){return e===void 0&&(e=Ts),r=r??NN,Ar(function(t,n){var i,o=!0;t.subscribe(xr(n,function(a){var c=e(a);(o||!r(i,c))&&(o=!1,i=c,n.next(a))}))})}function NN(r,e){return r===e}function C6(r){return r===void 0&&(r=DN),Ar(function(e,t){var n=!1;e.subscribe(xr(t,function(i){n=!0,t.next(i)},function(){return n?t.complete():t.error(r())}))})}function DN(){return new Pm}function ng(r){return Ar(function(e,t){try{e.subscribe(t)}finally{t.add(r)}})}function Z1(r,e){return Ar(VN(r,e,"value"))}function VN(r,e,t){return function(n,i){var o=0;n.subscribe(xr(i,function(a){var c=o++;r.call(e,a,c,n)&&(i.next(a),i.complete())},function(){i.next(void 0),i.complete()}))}}function Ks(r,e){var t=arguments.length>=2;return function(n){return n.pipe(Ts,tp(1),t?x6(e):C6(function(){return new Pm}))}}function k6(r,e,t,n){return Ar(function(i,o){var a;(!e||typeof e=="function")&&(a=e);var c=new Map,d=function(_){c.forEach(_),_(o)},h=function(_){return d(function(b){return b.error(_)})},u=0,p=!1,v=new dR(o,function(_){try{var b=r(_),C=c.get(b);if(!C){c.set(b,C=n?n():new Bn);var T=g(b,C);if(o.next(T),t){var S=xr(C,function(){C.complete(),S==null||S.unsubscribe()},void 0,void 0,function(){return c.delete(b)});v.add(Zn(t(T)).subscribe(S))}}C.next(a?a(_):_)}catch(A){h(A)}},function(){return d(function(_){return _.complete()})},h,function(){return c.clear()},function(){return p=!0,u===0});i.subscribe(v);function g(_,b){var C=new Tt(function(T){u++;var S=b.subscribe(T);return function(){S.unsubscribe(),--u===0&&p&&v.unsubscribe()}});return C.key=_,C}})}function FN(r){return r<=0?function(){return Tr}:Ar(function(e,t){var n=[];e.subscribe(xr(t,function(i){n.push(i),r<n.length&&n.shift()},function(){var i,o;try{for(var a=Di(n),c=a.next();!c.done;c=a.next()){var d=c.value;t.next(d)}}catch(h){i={error:h}}finally{try{c&&!c.done&&(o=a.return)&&o.call(a)}finally{if(i)throw i.error}}t.complete()},void 0,function(){n=null}))})}function Ti(r,e){var t=arguments.length>=2;return function(n){return n.pipe(Ts,FN(1),t?x6(e):C6(function(){return new Pm}))}}function PR(r,e,t){return Ar(function(n,i){var o=e;return AR(n,i,function(a,c){return r(o,a,c)},t,function(a){o=a},!1,void 0,function(){return o=null})})}function ig(){return Ar(function(r,e){var t,n=!1;r.subscribe(xr(e,function(i){var o=t;t=i,n&&e.next([o,i]),n=!0}))})}function Kc(){for(var r=[],e=0;e<arguments.length;e++)r[e]=arguments[e];return r.length?Ar(function(t,n){HN(vc([t],ys(r)))(n)}):Ts}function jN(r,e){return Ar(RR(r,e,arguments.length>=2,!0))}function Vf(r){r===void 0&&(r={});var e=r.connector,t=e===void 0?function(){return new Bn}:e,n=r.resetOnError,i=n===void 0?!0:n,o=r.resetOnComplete,a=o===void 0?!0:o,c=r.resetOnRefCountZero,d=c===void 0?!0:c;return function(h){var u,p,v,g=0,_=!1,b=!1,C=function(){p==null||p.unsubscribe(),p=void 0},T=function(){C(),u=v=void 0,_=b=!1},S=function(){var A=u;T(),A==null||A.unsubscribe()};return Ar(function(A,Z){g++,!b&&!_&&C();var B=v=v??t();Z.add(function(){g--,g===0&&!b&&!_&&(p=M3(S,d))}),B.subscribe(Z),!u&&g>0&&(u=new hf({next:function(U){return B.next(U)},error:function(U){b=!0,C(),p=M3(T,i,U),B.error(U)},complete:function(){_=!0,C(),p=M3(T,a),B.complete()}}),Zn(A).subscribe(u))})(h)}}function M3(r,e){for(var t=[],n=2;n<arguments.length;n++)t[n-2]=arguments[n];if(e===!0){r();return}if(e!==!1){var i=new hf({next:function(){i.unsubscribe(),r()}});return Zn(e.apply(void 0,vc([],ys(t)))).subscribe(i)}}function zN(r,e,t){var n,i=!1;return n=1/0,Vf({connector:function(){return new uR(n,e,t)},resetOnError:!0,resetOnComplete:!1,resetOnRefCountZero:i})}function Wt(r,e){return Ar(function(t,n){var i=null,o=0,a=!1,c=function(){return a&&!i&&n.complete()};t.subscribe(xr(n,function(d){i==null||i.unsubscribe();var h=0,u=o++;Zn(r(d,u)).subscribe(i=xr(n,function(p){return n.next(e?e(d,p,u,h++):p)},function(){i=null,c()}))},function(){a=!0,c()}))})}function ou(r){return Ar(function(e,t){Zn(r).subscribe(xr(t,function(){return t.complete()},eg)),!t.closed&&e.subscribe(t)})}function MR(r,e){return e===void 0&&(e=!1),Ar(function(t,n){var i=0;t.subscribe(xr(n,function(o){var a=r(o,i++);(a||e)&&n.next(o),!a&&n.complete()}))})}function Br(r,e,t){var n=gr(r)||e||t?{next:r,error:e,complete:t}:r;return n?Ar(function(i,o){var a;(a=n.subscribe)===null||a===void 0||a.call(n);var c=!0;i.subscribe(xr(o,function(d){var h;(h=n.next)===null||h===void 0||h.call(n,d),o.next(d)},function(){var d;c=!1,(d=n.complete)===null||d===void 0||d.call(n),o.complete()},function(d){var h;c=!1,(h=n.error)===null||h===void 0||h.call(n,d),o.error(d)},function(){var d,h;c&&((d=n.unsubscribe)===null||d===void 0||d.call(n)),(h=n.finalize)===null||h===void 0||h.call(n)}))}):Ts}function BN(r,e){return Ar(function(t,n){var i=e??{},o=i.leading,a=o===void 0?!0:o,c=i.trailing,d=c===void 0?!1:c,h=!1,u=null,p=null,v=!1,g=function(){p==null||p.unsubscribe(),p=null,d&&(C(),v&&n.complete())},_=function(){p=null,v&&n.complete()},b=function(T){return p=Zn(r(T)).subscribe(xr(n,g,_))},C=function(){if(h){h=!1;var T=u;u=null,n.next(T),!v&&b(T)}};t.subscribe(xr(n,function(T){h=!0,u=T,!(p&&!p.closed)&&(a?C():b(T))},function(){v=!0,!(d&&h&&p&&!p.closed)&&n.complete()}))})}function E6(r,e,t){e===void 0&&(e=ff);var n=w6(r,e);return BN(function(){return n},t)}function Up(){for(var r=[],e=0;e<arguments.length;e++)r[e]=arguments[e];var t=y6(r);return Ar(function(n,i){for(var o=r.length,a=new Array(o),c=r.map(function(){return!1}),d=!1,h=function(p){Zn(r[p]).subscribe(xr(i,function(v){a[p]=v,!d&&!c[p]&&(c[p]=!0,(d=c.every(Ts))&&(c=null))},eg))},u=0;u<o;u++)h(u);n.subscribe(xr(i,function(p){if(d){var v=vc([p],ys(a));i.next(t?t.apply(void 0,vc([],ys(v))):v)}}))})}var UN=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})},b0=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},Oh;const $R=(r,e,t)=>{var n;const i=typeof e=="string"?e.split("."):e,o=i.shift();return o&&((n=r[o])!==null&&n!==void 0||(r[o]={}),i.length?$R(r[o],i,t):Object.assign(r,{[o]:t})),r};class Mm{constructor(){Oh.set(this,{})}createConfig(e,t){return rt(this._createConfig(e,t))}createConfigAsync(e,t){return UN(this,void 0,void 0,function*(){return lr(this.createConfig(e,t))})}_set(e,t){b0(this,Oh,"f")[e]=t}_get(e){return b0(this,Oh,"f")[e]}_has(e){return e in b0(this,Oh,"f")}_createConfig(e,t){return rt(this._buildConfig(e,t)).pipe(Wt(n=>this._processConfig(n,e)))}_buildConfig(e,t){return rt(Object.entries(b0(this,Oh,"f"))).pipe(Jn(([n,i])=>rt(i(e)).pipe($e(o=>o!==void 0),me(o=>({target:n,value:o})),Vt(o=>(console.error(`Failed to execute config callback: ${i.name} for attribute: '${n}'`,o),Tr)))),Bp((n,{target:i,value:o})=>$R(n,i,o),t??{}))}_processConfig(e,t){return It(e)}}Oh=new WeakMap;var w0=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},EC=function(r,e,t,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?r!==e||!i:!e.has(r))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(r,t):i?i.value=t:e.set(r,t),t},mv,Zh;class OR{get version(){return w0(this,mv,"f")}constructor(e){mv.set(this,void 0),Zh.set(this,void 0);const{version:t}=e;EC(this,mv,new fs(t),"f"),EC(this,Zh,new ti,"f")}_addTeardown(e){return w0(this,Zh,"f").add(e),()=>w0(this,Zh,"f").remove(e)}dispose(){w0(this,Zh,"f").unsubscribe()}}mv=new WeakMap,Zh=new WeakMap;var Bs=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};class qN extends Error{constructor(){super("It was too slow"),this.name="RequiredModuleTimeoutError"}}class WN{constructor(e){this.logger=new iR("ModulesConfigurator"),this._configs=[],this._afterConfiguration=[],this._afterInit=[],this._modules=new Set(e)}get modules(){return[...this._modules]}configure(...e){for(const t of e)this.addConfig(t)}addConfig(e){const{module:t,afterConfig:n,afterInit:i,configure:o}=e;this._modules.add(t),o&&this._configs.push((a,c)=>o(a[t.name],c)),n&&this._afterConfiguration.push(a=>n(a[t.name])),i&&this._afterInit.push(a=>i(a[t.name]))}onConfigured(e){this._afterConfiguration.push(e)}onInitialized(e){this._afterInit.push(e)}initialize(e){return Bs(this,void 0,void 0,function*(){const t=yield this._configure(e),n=yield this._initialize(t,e);return yield this._postInitialize(n,e),Object.seal(Object.assign({},n,{dispose:()=>this.dispose(n)}))})}_configure(e){return Bs(this,void 0,void 0,function*(){const t=yield this._createConfig(e);return yield Promise.all(this._configs.map(n=>Promise.resolve(n(t,e)))),yield this._postConfigure(t),t})}_createConfig(e){const{modules:t,logger:n,_afterConfiguration:i,_afterInit:o}=this,a=rt(t).pipe(Jn(c=>Bs(this,void 0,void 0,function*(){var d;n.debug(`🛠 creating configurator ${n.formatModuleName(c)}`);try{const h=yield(d=c.configure)===null||d===void 0?void 0:d.call(c,e);return n.debug(`🛠 created configurator for ${n.formatModuleName(c)}`,h),{[c.name]:h}}catch(h){throw n.error(`🛠 Failed to created configurator for ${n.formatModuleName(c)}`,h),h}})),Bp((c,d)=>Object.assign(c,d),{onAfterConfiguration(c){i.push(c)},onAfterInit(c){o.push(c)}}));return lr(a)}_postConfigure(e){return Bs(this,void 0,void 0,function*(){const{modules:t,logger:n,_afterConfiguration:i}=this;if(yield Promise.allSettled(t.filter(o=>!!o.postConfigure).map(o=>Bs(this,void 0,void 0,function*(){var a;try{yield(a=o.postConfigure)===null||a===void 0?void 0:a.call(o,e),n.debug(`🏗📌 post configured ${n.formatModuleName(o)}`,o)}catch{n.warn(`🏗📌 post configure failed ${n.formatModuleName(o)}`)}}))),i.length)try{n.debug(`🏗📌 post configure hooks [${i.length}]`),yield Promise.allSettled(i.map(o=>Promise.resolve(o(e)))),n.debug("🏗📌 post configure hooks complete")}catch(o){n.warn("🏗📌 post configure hook failed",o)}})}_initialize(e,t){return Bs(this,void 0,void 0,function*(){const{modules:n,logger:i}=this,o=n.map(u=>u.name),a=new Df({}),c=u=>o.includes(u),d=(u,p=60)=>{if(!o.includes(u))throw i.error(`🚀⌛️ Cannot not require ${i.formatModuleName(String(u))} since module is not defined!`),Error(`cannot not require [${String(u)}] since module is not defined!`);return a.value[u]?(i.debug(`🚀⌛️ ${i.formatModuleName(String(u))} is initiated, skipping queue`),Promise.resolve(a.value[u])):(i.debug(`🚀⌛️ Awaiting init ${i.formatModuleName(String(u))}, timeout ${p}s`),zn(a.pipe($e(v=>!!v[u]),me(v=>v[u]),Gs({each:p*1e3,with:()=>kR(()=>new qN)}))))};rt(n).pipe(Jn(u=>{const p=u.name;return i.debug(`🚀 initializing ${i.formatModuleName(u)}`),rt(Promise.resolve(u.initialize({ref:t,config:e[p],requireInstance:d,hasModule:c}))).pipe(me(v=>{var g;if(!(v instanceof OR)&&!(v.version instanceof fs)){i.debug("🤷 module does not extends the [BaseModuleProvider] or exposes [SemanticVersion]");try{v.version=u.version instanceof fs?u.version:new fs((g=u.version)!==null&&g!==void 0?g:"0.0.0-unknown")}catch{i.error("🚨 failed to set module version")}}return i.debug(`🚀 initialized ${i.formatModuleName(u)}`),[p,v]}))})).subscribe({next:([u,p])=>{a.next(Object.assign(a.value,{[u]:p}))},complete:()=>a.complete()});const h=yield lr(a);return Object.seal(h),h})}_postInitialize(e,t){return Bs(this,void 0,void 0,function*(){const{modules:n,logger:i,_afterInit:o}=this,a=rt(n).pipe($e(c=>!!c.postInitialize),Br(c=>i.debug(`🚀📌 post initializing moule ${i.formatModuleName(c)}`)),Jn(c=>rt(c.postInitialize({ref:t,modules:e,instance:e[c.name]})).pipe(Br(()=>{i.debug(`🚀📌 post initialized moule ${i.formatModuleName(c)}`)}),Vt(d=>(i.warn(`🚀📌 post initialize failed moule ${i.formatModuleName(c)}`,d),Tr)))));if(yield new Promise((c,d)=>{a.subscribe({complete:()=>c(!0),error:d})}),o.length)try{i.debug(`🚀📌 post configure hooks [${o.length}]`),yield Promise.allSettled(o.map(c=>Promise.resolve(c(e)))),i.debug("🚀📌 post configure hooks complete")}catch(c){i.warn("🚀📌 post configure hook failed",c)}i.debug(`🎉 Modules initialized ${n.map(i.formatModuleName)}`,e),i.info("🟢 Modules initialized")})}dispose(e,t){return Bs(this,void 0,void 0,function*(){const{modules:n}=this;yield Promise.allSettled(n.filter(i=>!!i.dispose).map(i=>Bs(this,void 0,void 0,function*(){var o;yield(o=i.dispose)===null||o===void 0?void 0:o.call(i,{ref:t,modules:e,instance:e[i.name]})})))})}}var rp={exports:{}};rp.exports;var SC;function GN(){return SC||(SC=1,function(r,e){var t=200,n="__lodash_hash_undefined__",i=9007199254740991,o="[object Arguments]",a="[object Array]",c="[object Boolean]",d="[object Date]",h="[object Error]",u="[object Function]",p="[object GeneratorFunction]",v="[object Map]",g="[object Number]",_="[object Object]",b="[object Promise]",C="[object RegExp]",T="[object Set]",S="[object String]",A="[object Symbol]",Z="[object WeakMap]",B="[object ArrayBuffer]",U="[object DataView]",I="[object Float32Array]",Y="[object Float64Array]",le="[object Int8Array]",de="[object Int16Array]",Ee="[object Int32Array]",we="[object Uint8Array]",Ce="[object Uint8ClampedArray]",J="[object Uint16Array]",K="[object Uint32Array]",re=/[\\^$.*+?()[\]{}|]/g,q=/\w*$/,$=/^\[object .+?Constructor\]$/,O=/^(?:0|[1-9]\d*)$/,H={};H[o]=H[a]=H[B]=H[U]=H[c]=H[d]=H[I]=H[Y]=H[le]=H[de]=H[Ee]=H[v]=H[g]=H[_]=H[C]=H[T]=H[S]=H[A]=H[we]=H[Ce]=H[J]=H[K]=!0,H[h]=H[u]=H[Z]=!1;var P=typeof v0=="object"&&v0&&v0.Object===Object&&v0,N=typeof self=="object"&&self&&self.Object===Object&&self,ye=P||N||Function("return this")(),Pe=e&&!e.nodeType&&e,Ie=Pe&&!0&&r&&!r.nodeType&&r,Te=Ie&&Ie.exports===Pe;function Ke(M,te){return M.set(te[0],te[1]),M}function ot(M,te){return M.add(te),M}function _t(M,te){for(var ue=-1,at=M?M.length:0;++ue<at&&te(M[ue],ue,M)!==!1;);return M}function yr(M,te){for(var ue=-1,at=te.length,vn=M.length;++ue<at;)M[vn+ue]=te[ue];return M}function Wr(M,te,ue,at){for(var vn=-1,Rn=M?M.length:0;++vn<Rn;)ue=te(ue,M[vn],vn,M);return ue}function Rt(M,te){for(var ue=-1,at=Array(M);++ue<M;)at[ue]=te(ue);return at}function Un(M,te){return M==null?void 0:M[te]}function co(M){var te=!1;if(M!=null&&typeof M.toString!="function")try{te=!!(M+"")}catch{}return te}function ma(M){var te=-1,ue=Array(M.size);return M.forEach(function(at,vn){ue[++te]=[vn,at]}),ue}function qi(M,te){return function(ue){return M(te(ue))}}function Sc(M){var te=-1,ue=Array(M.size);return M.forEach(function(at){ue[++te]=at}),ue}var Uu=Array.prototype,Tc=Function.prototype,Po=Object.prototype,Mo=ye["__core-js_shared__"],Ac=function(){var M=/[^.]+$/.exec(Mo&&Mo.keys&&Mo.keys.IE_PROTO||"");return M?"Symbol(src)_1."+M:""}(),zl=Tc.toString,An=Po.hasOwnProperty,lo=Po.toString,Bl=RegExp("^"+zl.call(An).replace(re,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),Ba=Te?ye.Buffer:void 0,ai=ye.Symbol,Ii=ye.Uint8Array,Ua=qi(Object.getPrototypeOf,Object),$o=Object.create,e1=Po.propertyIsEnumerable,uo=Uu.splice,Ic=Object.getOwnPropertySymbols,qu=Ba?Ba.isBuffer:void 0,Rc=qi(Object.keys,Object),Ps=qt(ye,"DataView"),Oo=qt(ye,"Map"),Zo=qt(ye,"Promise"),qa=qt(ye,"Set"),Wi=qt(ye,"WeakMap"),si=qt(Object,"create"),Wu=li(Ps),Ul=li(Oo),Gu=li(Zo),ql=li(qa),Ms=li(Wi),va=ai?ai.prototype:void 0,Wl=va?va.valueOf:void 0;function Ri(M){var te=-1,ue=M?M.length:0;for(this.clear();++te<ue;){var at=M[te];this.set(at[0],at[1])}}function D(){this.__data__=si?si(null):{}}function Q(M){return this.has(M)&&delete this.__data__[M]}function ie(M){var te=this.__data__;if(si){var ue=te[M];return ue===n?void 0:ue}return An.call(te,M)?te[M]:void 0}function he(M){var te=this.__data__;return si?te[M]!==void 0:An.call(te,M)}function Oe(M,te){var ue=this.__data__;return ue[M]=si&&te===void 0?n:te,this}Ri.prototype.clear=D,Ri.prototype.delete=Q,Ri.prototype.get=ie,Ri.prototype.has=he,Ri.prototype.set=Oe;function Ve(M){var te=-1,ue=M?M.length:0;for(this.clear();++te<ue;){var at=M[te];this.set(at[0],at[1])}}function mt(){this.__data__=[]}function Ge(M){var te=this.__data__,ue=ya(te,M);if(ue<0)return!1;var at=te.length-1;return ue==at?te.pop():uo.call(te,ue,1),!0}function Ye(M){var te=this.__data__,ue=ya(te,M);return ue<0?void 0:te[ue][1]}function je(M){return ya(this.__data__,M)>-1}function Je(M,te){var ue=this.__data__,at=ya(ue,M);return at<0?ue.push([M,te]):ue[at][1]=te,this}Ve.prototype.clear=mt,Ve.prototype.delete=Ge,Ve.prototype.get=Ye,Ve.prototype.has=je,Ve.prototype.set=Je;function wt(M){var te=-1,ue=M?M.length:0;for(this.clear();++te<ue;){var at=M[te];this.set(at[0],at[1])}}function Ht(){this.__data__={hash:new Ri,map:new(Oo||Ve),string:new Ri}}function mn(M){return Mc(this,M).delete(M)}function ar(M){return Mc(this,M).get(M)}function Ut(M){return Mc(this,M).has(M)}function Er(M,te){return Mc(this,M).set(M,te),this}wt.prototype.clear=Ht,wt.prototype.delete=mn,wt.prototype.get=ar,wt.prototype.has=Ut,wt.prototype.set=Er;function ci(M){this.__data__=new Ve(M)}function $s(){this.__data__=new Ve}function ho(M){return this.__data__.delete(M)}function Kt(M){return this.__data__.get(M)}function Gl(M){return this.__data__.has(M)}function ga(M,te){var ue=this.__data__;if(ue instanceof Ve){var at=ue.__data__;if(!Oo||at.length<t-1)return at.push([M,te]),this;ue=this.__data__=new wt(at)}return ue.set(M,te),this}ci.prototype.clear=$s,ci.prototype.delete=ho,ci.prototype.get=Kt,ci.prototype.has=Gl,ci.prototype.set=ga;function Lo(M,te){var ue=No(M)||Ql(M)?Rt(M.length,String):[],at=ue.length,vn=!!at;for(var Rn in M)An.call(M,Rn)&&!(vn&&(Rn=="length"||g2(Rn,at)))&&ue.push(Rn);return ue}function Ho(M,te,ue){var at=M[te];(!(An.call(M,te)&&$c(at,ue))||ue===void 0&&!(te in M))&&(M[te]=ue)}function ya(M,te){for(var ue=M.length;ue--;)if($c(M[ue][0],te))return ue;return-1}function jt(M,te){return M&&Xu(te,a1(te),M)}function sr(M,te,ue,at,vn,Rn,fo){var qn;if(at&&(qn=Rn?at(M,vn,Rn,fo):at(M)),qn!==void 0)return qn;if(!Zs(M))return M;var ba=No(M);if(ba){if(qn=i1(M),!te)return p2(M,qn)}else{var Ya=Ga(M),td=Ya==u||Ya==p;if(Xl(M))return t1(M,te);if(Ya==_||Ya==o||td&&!Rn){if(co(M))return Rn?M:{};if(qn=m2(td?{}:M),!te)return Yl(M,jt(qn,M))}else{if(!H[Ya])return Rn?M:{};qn=v2(M,Ya,sr,te)}}fo||(fo=new ci);var s1=fo.get(M);if(s1)return s1;if(fo.set(M,qn),!ba)var rd=ue?c5(M):a1(M);return _t(rd||M,function(Oc,nd){rd&&(nd=Oc,Oc=M[nd]),Ho(qn,nd,sr(Oc,te,ue,at,nd,M,fo))}),qn}function In(M){return Zs(M)?$o(M):{}}function Os(M,te,ue){var at=te(M);return No(M)?at:yr(at,ue(M))}function Yt(M){return lo.call(M)}function Wa(M){if(!Zs(M)||Ju(M))return!1;var te=b2(M)||co(M)?Bl:$;return te.test(li(M))}function Ku(M){if(!_a(M))return Rc(M);var te=[];for(var ue in Object(M))An.call(M,ue)&&ue!="constructor"&&te.push(ue);return te}function t1(M,te){if(te)return M.slice();var ue=new M.constructor(M.length);return M.copy(ue),ue}function Pc(M){var te=new M.constructor(M.byteLength);return new Ii(te).set(new Ii(M)),te}function Yu(M,te){var ue=te?Pc(M.buffer):M.buffer;return new M.constructor(ue,M.byteOffset,M.byteLength)}function Kl(M,te,ue){var at=te?ue(ma(M),!0):ma(M);return Wr(at,Ke,new M.constructor)}function Qu(M){var te=new M.constructor(M.source,q.exec(M));return te.lastIndex=M.lastIndex,te}function a5(M,te,ue){var at=te?ue(Sc(M),!0):Sc(M);return Wr(at,ot,new M.constructor)}function s5(M){return Wl?Object(Wl.call(M)):{}}function r1(M,te){var ue=te?Pc(M.buffer):M.buffer;return new M.constructor(ue,M.byteOffset,M.length)}function p2(M,te){var ue=-1,at=M.length;for(te||(te=Array(at));++ue<at;)te[ue]=M[ue];return te}function Xu(M,te,ue,at){ue||(ue={});for(var vn=-1,Rn=te.length;++vn<Rn;){var fo=te[vn],qn=void 0;Ho(ue,fo,qn===void 0?M[fo]:qn)}return ue}function Yl(M,te){return Xu(M,n1(M),te)}function c5(M){return Os(M,a1,n1)}function Mc(M,te){var ue=M.__data__;return o1(te)?ue[typeof te=="string"?"string":"hash"]:ue.map}function qt(M,te){var ue=Un(M,te);return Wa(ue)?ue:void 0}var n1=Ic?qi(Ic,Object):Jl,Ga=Yt;(Ps&&Ga(new Ps(new ArrayBuffer(1)))!=U||Oo&&Ga(new Oo)!=v||Zo&&Ga(Zo.resolve())!=b||qa&&Ga(new qa)!=T||Wi&&Ga(new Wi)!=Z)&&(Ga=function(M){var te=lo.call(M),ue=te==_?M.constructor:void 0,at=ue?li(ue):void 0;if(at)switch(at){case Wu:return U;case Ul:return v;case Gu:return b;case ql:return T;case Ms:return Z}return te});function i1(M){var te=M.length,ue=M.constructor(te);return te&&typeof M[0]=="string"&&An.call(M,"index")&&(ue.index=M.index,ue.input=M.input),ue}function m2(M){return typeof M.constructor=="function"&&!_a(M)?In(Ua(M)):{}}function v2(M,te,ue,at){var vn=M.constructor;switch(te){case B:return Pc(M);case c:case d:return new vn(+M);case U:return Yu(M,at);case I:case Y:case le:case de:case Ee:case we:case Ce:case J:case K:return r1(M,at);case v:return Kl(M,at,ue);case g:case S:return new vn(M);case C:return Qu(M);case T:return a5(M,at,ue);case A:return s5(M)}}function g2(M,te){return te=te??i,!!te&&(typeof M=="number"||O.test(M))&&M>-1&&M%1==0&&M<te}function o1(M){var te=typeof M;return te=="string"||te=="number"||te=="symbol"||te=="boolean"?M!=="__proto__":M===null}function Ju(M){return!!Ac&&Ac in M}function _a(M){var te=M&&M.constructor,ue=typeof te=="function"&&te.prototype||Po;return M===ue}function li(M){if(M!=null){try{return zl.call(M)}catch{}try{return M+""}catch{}}return""}function Ka(M){return sr(M,!0,!0)}function $c(M,te){return M===te||M!==M&&te!==te}function Ql(M){return _2(M)&&An.call(M,"callee")&&(!e1.call(M,"callee")||lo.call(M)==o)}var No=Array.isArray;function y2(M){return M!=null&&w2(M.length)&&!b2(M)}function _2(M){return x2(M)&&y2(M)}var Xl=qu||ed;function b2(M){var te=Zs(M)?lo.call(M):"";return te==u||te==p}function w2(M){return typeof M=="number"&&M>-1&&M%1==0&&M<=i}function Zs(M){var te=typeof M;return!!M&&(te=="object"||te=="function")}function x2(M){return!!M&&typeof M=="object"}function a1(M){return y2(M)?Lo(M):Ku(M)}function Jl(){return[]}function ed(){return!1}r.exports=Ka}(rp,rp.exports)),rp.exports}var KN=GN();const YN=Hu(KN);var Us=function(r,e,t,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?r!==e||!i:!e.has(r))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(r,t):i?i.value=t:e.set(r,t),t},Uo=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},Rd,vv,gv,np,yv,ip,op,wb;class ZR{constructor(e,t){this.__type=e,Rd.set(this,void 0),vv.set(this,void 0),gv.set(this,void 0),np.set(this,!1),yv.set(this,void 0),ip.set(this,void 0),op.set(this,void 0),wb.set(this,Date.now()),Us(this,Rd,t.detail,"f"),Us(this,vv,YN(t.detail),"f"),Us(this,ip,!!t.mutableDetails,"f"),Us(this,gv,t.source,"f"),Us(this,yv,!!t.cancelable,"f"),Us(this,op,t.canBubble===void 0?!0:t.canBubble,"f")}get bubbles(){return Uo(this,op,"f")&&!Uo(this,np,"f")}get created(){return Uo(this,wb,"f")}get cancelable(){return Uo(this,yv,"f")}get canceled(){return Uo(this,np,"f")}get detail(){return Uo(this,Rd,"f")}get originalDetail(){return Uo(this,vv,"f")}get source(){return Uo(this,gv,"f")}get type(){return this.__type}get allowEventDetailsMutation(){return Uo(this,ip,"f")}preventDefault(){this.cancelable&&Us(this,np,!0,"f")}stopPropagation(){Us(this,op,!1,"f")}updateDetails(e){if(!Uo(this,ip,"f"))throw new Error("Event details are not mutable");const t=e(Uo(this,Rd,"f"));Us(this,Rd,t===void 0?Uo(this,Rd,"f"):t,"f")}}Rd=new WeakMap,vv=new WeakMap,gv=new WeakMap,np=new WeakMap,yv=new WeakMap,ip=new WeakMap,op=new WeakMap,wb=new WeakMap;var QN=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};class XN{constructor({onDispatch:e,onBubble:t}){this.__onDispatch=e,this.__onBubble=t}dispatch(e,t){return QN(this,void 0,void 0,function*(){var n,i;try{yield(n=this.__onDispatch)===null||n===void 0?void 0:n.call(this,e)}catch(a){throw a}const o=e;if(!o.dispatcher)o.dispatcher=this;else if(o.dispatcher===this)throw Error("loop detected");for(const a of t)e.cancelable?e.canceled||(yield Promise.resolve(a(e))):a(e);if(e.bubbles)try{yield(i=this.__onBubble)===null||i===void 0?void 0:i.call(this,e)}catch(a){throw a}})}}var TC=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};class JN extends Tt{get event$(){return this.__event$.asObservable()}get closed(){return this.__event$.closed}constructor(e){super(t=>{this.__event$.subscribe(t)}),this.__listeners=[],this.__event$=new Bn,this.__dispatcher=new XN({onDispatch:e.onDispatch,onBubble:e.onBubble})}addEventListener(e,t){if(this.closed)throw Error("Cannot listen to events when provider is closed!");const n={type:e,handler:t};return this.__listeners.push(n),()=>{const i=this.__listeners.indexOf(n);0<=i&&this.__listeners.splice(i,1)}}dispatchEvent(e,t){return TC(this,void 0,void 0,function*(){if(typeof e=="string"){if(!t)throw Error("invalid arguments, missing [FrameworkEventInit]");return this._dispatchEvent(new ZR(e,t))}else return this._dispatchEvent(e)})}_dispatchEvent(e){return TC(this,void 0,void 0,function*(){if(this.closed)throw Error("Cannot dispatch events when provider is closed!");this.__event$.next(e);try{const t=this.__listeners.filter(n=>n.type===e.type).map(({handler:n})=>n);yield this.__dispatcher.dispatch(e,t)}catch(t){throw t}return e})}dispose(){this.__listeners=[],this.__event$.complete()}}var AC=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};const eD="event",tD={name:eD,configure:r=>{const e={},t=r==null?void 0:r.event;return t&&(e.onBubble=n=>AC(void 0,void 0,void 0,function*(){yield t.dispatchEvent(n)})),e},initialize:({config:r})=>new JN(r),postInitialize:r=>AC(void 0,[r],void 0,function*({instance:e,modules:t}){e.dispatchEvent("onModulesLoaded",{detail:t,source:e})}),dispose({instance:r}){r.dispose()}};class LR{get operators(){return this._operators}constructor(e){e&&"operators"in e?this._operators=Object.assign({},e.operators):this._operators=e??{}}add(e,t){if(Object.keys(this._operators).includes(e))throw Error(`Operator [${e}] already defined`);return this.set(e,t)}set(e,t){return this._operators[e]=t,this}remove(e){return delete this._operators[e],this}get(e){return this._operators[e]}process(e){return Object.values(this._operators).length?rt(Object.values(this._operators)).pipe(PR((n,i)=>Promise.resolve(i(n)).then(o=>o??n),e,1),Ti()):It(e)}}const rD=(r,e)=>t=>{const n=new Headers(t.headers);return n.append(r,e),Object.assign(Object.assign({},t),{headers:n})};class HR extends LR{setHeader(e,t){const n=rD(e,t);return this.set("header-"+e,n)}}class nD extends LR{}var Qt;(function(r){r.assertEqual=i=>i;function e(i){}r.assertIs=e;function t(i){throw new Error}r.assertNever=t,r.arrayToEnum=i=>{const o={};for(const a of i)o[a]=a;return o},r.getValidEnumValues=i=>{const o=r.objectKeys(i).filter(c=>typeof i[i[c]]!="number"),a={};for(const c of o)a[c]=i[c];return r.objectValues(a)},r.objectValues=i=>r.objectKeys(i).map(function(o){return i[o]}),r.objectKeys=typeof Object.keys=="function"?i=>Object.keys(i):i=>{const o=[];for(const a in i)Object.prototype.hasOwnProperty.call(i,a)&&o.push(a);return o},r.find=(i,o)=>{for(const a of i)if(o(a))return a},r.isInteger=typeof Number.isInteger=="function"?i=>Number.isInteger(i):i=>typeof i=="number"&&isFinite(i)&&Math.floor(i)===i;function n(i,o=" | "){return i.map(a=>typeof a=="string"?`'${a}'`:a).join(o)}r.joinValues=n,r.jsonStringifyReplacer=(i,o)=>typeof o=="bigint"?o.toString():o})(Qt||(Qt={}));var xb;(function(r){r.mergeShapes=(e,t)=>({...e,...t})})(xb||(xb={}));const Ue=Qt.arrayToEnum(["string","nan","number","integer","float","boolean","date","bigint","symbol","function","undefined","null","array","object","unknown","promise","void","never","map","set"]),rc=r=>{switch(typeof r){case"undefined":return Ue.undefined;case"string":return Ue.string;case"number":return isNaN(r)?Ue.nan:Ue.number;case"boolean":return Ue.boolean;case"function":return Ue.function;case"bigint":return Ue.bigint;case"symbol":return Ue.symbol;case"object":return Array.isArray(r)?Ue.array:r===null?Ue.null:r.then&&typeof r.then=="function"&&r.catch&&typeof r.catch=="function"?Ue.promise:typeof Map<"u"&&r instanceof Map?Ue.map:typeof Set<"u"&&r instanceof Set?Ue.set:typeof Date<"u"&&r instanceof Date?Ue.date:Ue.object;default:return Ue.unknown}},be=Qt.arrayToEnum(["invalid_type","invalid_literal","custom","invalid_union","invalid_union_discriminator","invalid_enum_value","unrecognized_keys","invalid_arguments","invalid_return_type","invalid_date","invalid_string","too_small","too_big","invalid_intersection_types","not_multiple_of","not_finite"]),iD=r=>JSON.stringify(r,null,2).replace(/"([^"]+)":/g,"$1:");class ko extends Error{get errors(){return this.issues}constructor(e){super(),this.issues=[],this.addIssue=n=>{this.issues=[...this.issues,n]},this.addIssues=(n=[])=>{this.issues=[...this.issues,...n]};const t=new.target.prototype;Object.setPrototypeOf?Object.setPrototypeOf(this,t):this.__proto__=t,this.name="ZodError",this.issues=e}format(e){const t=e||function(o){return o.message},n={_errors:[]},i=o=>{for(const a of o.issues)if(a.code==="invalid_union")a.unionErrors.map(i);else if(a.code==="invalid_return_type")i(a.returnTypeError);else if(a.code==="invalid_arguments")i(a.argumentsError);else if(a.path.length===0)n._errors.push(t(a));else{let c=n,d=0;for(;d<a.path.length;){const h=a.path[d];d===a.path.length-1?(c[h]=c[h]||{_errors:[]},c[h]._errors.push(t(a))):c[h]=c[h]||{_errors:[]},c=c[h],d++}}};return i(this),n}static assert(e){if(!(e instanceof ko))throw new Error(`Not a ZodError: ${e}`)}toString(){return this.message}get message(){return JSON.stringify(this.issues,Qt.jsonStringifyReplacer,2)}get isEmpty(){return this.issues.length===0}flatten(e=t=>t.message){const t={},n=[];for(const i of this.issues)i.path.length>0?(t[i.path[0]]=t[i.path[0]]||[],t[i.path[0]].push(e(i))):n.push(e(i));return{formErrors:n,fieldErrors:t}}get formErrors(){return this.flatten()}}ko.create=r=>new ko(r);const pf=(r,e)=>{let t;switch(r.code){case be.invalid_type:r.received===Ue.undefined?t="Required":t=`Expected ${r.expected}, received ${r.received}`;break;case be.invalid_literal:t=`Invalid literal value, expected ${JSON.stringify(r.expected,Qt.jsonStringifyReplacer)}`;break;case be.unrecognized_keys:t=`Unrecognized key(s) in object: ${Qt.joinValues(r.keys,", ")}`;break;case be.invalid_union:t="Invalid input";break;case be.invalid_union_discriminator:t=`Invalid discriminator value. Expected ${Qt.joinValues(r.options)}`;break;case be.invalid_enum_value:t=`Invalid enum value. Expected ${Qt.joinValues(r.options)}, received '${r.received}'`;break;case be.invalid_arguments:t="Invalid function arguments";break;case be.invalid_return_type:t="Invalid function return type";break;case be.invalid_date:t="Invalid date";break;case be.invalid_string:typeof r.validation=="object"?"includes"in r.validation?(t=`Invalid input: must include "${r.validation.includes}"`,typeof r.validation.position=="number"&&(t=`${t} at one or more positions greater than or equal to ${r.validation.position}`)):"startsWith"in r.validation?t=`Invalid input: must start with "${r.validation.startsWith}"`:"endsWith"in r.validation?t=`Invalid input: must end with "${r.validation.endsWith}"`:Qt.assertNever(r.validation):r.validation!=="regex"?t=`Invalid ${r.validation}`:t="Invalid";break;case be.too_small:r.type==="array"?t=`Array must contain ${r.exact?"exactly":r.inclusive?"at least":"more than"} ${r.minimum} element(s)`:r.type==="string"?t=`String must contain ${r.exact?"exactly":r.inclusive?"at least":"over"} ${r.minimum} character(s)`:r.type==="number"?t=`Number must be ${r.exact?"exactly equal to ":r.inclusive?"greater than or equal to ":"greater than "}${r.minimum}`:r.type==="date"?t=`Date must be ${r.exact?"exactly equal to ":r.inclusive?"greater than or equal to ":"greater than "}${new Date(Number(r.minimum))}`:t="Invalid input";break;case be.too_big:r.type==="array"?t=`Array must contain ${r.exact?"exactly":r.inclusive?"at most":"less than"} ${r.maximum} element(s)`:r.type==="string"?t=`String must contain ${r.exact?"exactly":r.inclusive?"at most":"under"} ${r.maximum} character(s)`:r.type==="number"?t=`Number must be ${r.exact?"exactly":r.inclusive?"less than or equal to":"less than"} ${r.maximum}`:r.type==="bigint"?t=`BigInt must be ${r.exact?"exactly":r.inclusive?"less than or equal to":"less than"} ${r.maximum}`:r.type==="date"?t=`Date must be ${r.exact?"exactly":r.inclusive?"smaller than or equal to":"smaller than"} ${new Date(Number(r.maximum))}`:t="Invalid input";break;case be.custom:t="Invalid input";break;case be.invalid_intersection_types:t="Intersection results could not be merged";break;case be.not_multiple_of:t=`Number must be a multiple of ${r.multipleOf}`;break;case be.not_finite:t="Number must be finite";break;default:t=e.defaultError,Qt.assertNever(r)}return{message:t}};let NR=pf;function oD(r){NR=r}function og(){return NR}const ag=r=>{const{data:e,path:t,errorMaps:n,issueData:i}=r,o=[...t,...i.path||[]],a={...i,path:o};if(i.message!==void 0)return{...i,path:o,message:i.message};let c="";const d=n.filter(h=>!!h).slice().reverse();for(const h of d)c=h(a,{data:e,defaultError:c}).message;return{...i,path:o,message:c}},aD=[];function Le(r,e){const t=og(),n=ag({issueData:e,data:r.data,path:r.path,errorMaps:[r.common.contextualErrorMap,r.schemaErrorMap,t,t===pf?void 0:pf].filter(i=>!!i)});r.common.issues.push(n)}class ki{constructor(){this.value="valid"}dirty(){this.value==="valid"&&(this.value="dirty")}abort(){this.value!=="aborted"&&(this.value="aborted")}static mergeArray(e,t){const n=[];for(const i of t){if(i.status==="aborted")return bt;i.status==="dirty"&&e.dirty(),n.push(i.value)}return{status:e.value,value:n}}static async mergeObjectAsync(e,t){const n=[];for(const i of t){const o=await i.key,a=await i.value;n.push({key:o,value:a})}return ki.mergeObjectSync(e,n)}static mergeObjectSync(e,t){const n={};for(const i of t){const{key:o,value:a}=i;if(o.status==="aborted"||a.status==="aborted")return bt;o.status==="dirty"&&e.dirty(),a.status==="dirty"&&e.dirty(),o.value!=="__proto__"&&(typeof a.value<"u"||i.alwaysSet)&&(n[o.value]=a.value)}return{status:e.value,value:n}}}const bt=Object.freeze({status:"aborted"}),Wh=r=>({status:"dirty",value:r}),Fi=r=>({status:"valid",value:r}),Cb=r=>r.status==="aborted",kb=r=>r.status==="dirty",_u=r=>r.status==="valid",qp=r=>typeof Promise<"u"&&r instanceof Promise;function sg(r,e,t,n){if(typeof e=="function"?r!==e||!0:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return e.get(r)}function DR(r,e,t,n,i){if(typeof e=="function"?r!==e||!0:!e.has(r))throw new TypeError("Cannot write private member to an object whose class did not declare it");return e.set(r,t),t}var ct;(function(r){r.errToObj=e=>typeof e=="string"?{message:e}:e||{},r.toString=e=>typeof e=="string"?e:e==null?void 0:e.message})(ct||(ct={}));var ap,sp;class bs{constructor(e,t,n,i){this._cachedPath=[],this.parent=e,this.data=t,this._path=n,this._key=i}get path(){return this._cachedPath.length||(this._key instanceof Array?this._cachedPath.push(...this._path,...this._key):this._cachedPath.push(...this._path,this._key)),this._cachedPath}}const IC=(r,e)=>{if(_u(e))return{success:!0,data:e.value};if(!r.common.issues.length)throw new Error("Validation failed but no issues detected.");return{success:!1,get error(){if(this._error)return this._error;const t=new ko(r.common.issues);return this._error=t,this._error}}};function Pt(r){if(!r)return{};const{errorMap:e,invalid_type_error:t,required_error:n,description:i}=r;if(e&&(t||n))throw new Error(`Can't use "invalid_type_error" or "required_error" in conjunction with custom error map.`);return e?{errorMap:e,description:i}:{errorMap:(a,c)=>{var d,h;const{message:u}=r;return a.code==="invalid_enum_value"?{message:u??c.defaultError}:typeof c.data>"u"?{message:(d=u??n)!==null&&d!==void 0?d:c.defaultError}:a.code!=="invalid_type"?{message:c.defaultError}:{message:(h=u??t)!==null&&h!==void 0?h:c.defaultError}},description:i}}class Lt{get description(){return this._def.description}_getType(e){return rc(e.data)}_getOrReturnCtx(e,t){return t||{common:e.parent.common,data:e.data,parsedType:rc(e.data),schemaErrorMap:this._def.errorMap,path:e.path,parent:e.parent}}_processInputParams(e){return{status:new ki,ctx:{common:e.parent.common,data:e.data,parsedType:rc(e.data),schemaErrorMap:this._def.errorMap,path:e.path,parent:e.parent}}}_parseSync(e){const t=this._parse(e);if(qp(t))throw new Error("Synchronous parse encountered promise.");return t}_parseAsync(e){const t=this._parse(e);return Promise.resolve(t)}parse(e,t){const n=this.safeParse(e,t);if(n.success)return n.data;throw n.error}safeParse(e,t){var n;const i={common:{issues:[],async:(n=t==null?void 0:t.async)!==null&&n!==void 0?n:!1,contextualErrorMap:t==null?void 0:t.errorMap},path:(t==null?void 0:t.path)||[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:rc(e)},o=this._parseSync({data:e,path:i.path,parent:i});return IC(i,o)}"~validate"(e){var t,n;const i={common:{issues:[],async:!!this["~standard"].async},path:[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:rc(e)};if(!this["~standard"].async)try{const o=this._parseSync({data:e,path:[],parent:i});return _u(o)?{value:o.value}:{issues:i.common.issues}}catch(o){!((n=(t=o==null?void 0:o.message)===null||t===void 0?void 0:t.toLowerCase())===null||n===void 0)&&n.includes("encountered")&&(this["~standard"].async=!0),i.common={issues:[],async:!0}}return this._parseAsync({data:e,path:[],parent:i}).then(o=>_u(o)?{value:o.value}:{issues:i.common.issues})}async parseAsync(e,t){const n=await this.safeParseAsync(e,t);if(n.success)return n.data;throw n.error}async safeParseAsync(e,t){const n={common:{issues:[],contextualErrorMap:t==null?void 0:t.errorMap,async:!0},path:(t==null?void 0:t.path)||[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:rc(e)},i=this._parse({data:e,path:n.path,parent:n}),o=await(qp(i)?i:Promise.resolve(i));return IC(n,o)}refine(e,t){const n=i=>typeof t=="string"||typeof t>"u"?{message:t}:typeof t=="function"?t(i):t;return this._refinement((i,o)=>{const a=e(i),c=()=>o.addIssue({code:be.custom,...n(i)});return typeof Promise<"u"&&a instanceof Promise?a.then(d=>d?!0:(c(),!1)):a?!0:(c(),!1)})}refinement(e,t){return this._refinement((n,i)=>e(n)?!0:(i.addIssue(typeof t=="function"?t(n,i):t),!1))}_refinement(e){return new Na({schema:this,typeName:yt.ZodEffects,effect:{type:"refinement",refinement:e}})}superRefine(e){return this._refinement(e)}constructor(e){this.spa=this.safeParseAsync,this._def=e,this.parse=this.parse.bind(this),this.safeParse=this.safeParse.bind(this),this.parseAsync=this.parseAsync.bind(this),this.safeParseAsync=this.safeParseAsync.bind(this),this.spa=this.spa.bind(this),this.refine=this.refine.bind(this),this.refinement=this.refinement.bind(this),this.superRefine=this.superRefine.bind(this),this.optional=this.optional.bind(this),this.nullable=this.nullable.bind(this),this.nullish=this.nullish.bind(this),this.array=this.array.bind(this),this.promise=this.promise.bind(this),this.or=this.or.bind(this),this.and=this.and.bind(this),this.transform=this.transform.bind(this),this.brand=this.brand.bind(this),this.default=this.default.bind(this),this.catch=this.catch.bind(this),this.describe=this.describe.bind(this),this.pipe=this.pipe.bind(this),this.readonly=this.readonly.bind(this),this.isNullable=this.isNullable.bind(this),this.isOptional=this.isOptional.bind(this),this["~standard"]={version:1,vendor:"zod",validate:t=>this["~validate"](t)}}optional(){return ps.create(this,this._def)}nullable(){return Pl.create(this,this._def)}nullish(){return this.nullable().optional()}array(){return Oa.create(this)}promise(){return vf.create(this,this._def)}or(e){return Yp.create([this,e],this._def)}and(e){return Qp.create(this,e,this._def)}transform(e){return new Na({...Pt(this._def),schema:this,typeName:yt.ZodEffects,effect:{type:"transform",transform:e}})}default(e){const t=typeof e=="function"?e:()=>e;return new rm({...Pt(this._def),innerType:this,defaultValue:t,typeName:yt.ZodDefault})}brand(){return new S6({typeName:yt.ZodBranded,type:this,...Pt(this._def)})}catch(e){const t=typeof e=="function"?e:()=>e;return new nm({...Pt(this._def),innerType:this,catchValue:t,typeName:yt.ZodCatch})}describe(e){const t=this.constructor;return new t({...this._def,description:e})}pipe(e){return $m.create(this,e)}readonly(){return im.create(this)}isOptional(){return this.safeParse(void 0).success}isNullable(){return this.safeParse(null).success}}const sD=/^c[^\s-]{8,}$/i,cD=/^[0-9a-z]+$/,lD=/^[0-9A-HJKMNP-TV-Z]{26}$/i,dD=/^[0-9a-fA-F]{8}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{12}$/i,uD=/^[a-z0-9_-]{21}$/i,hD=/^[A-Za-z0-9-_]+\.[A-Za-z0-9-_]+\.[A-Za-z0-9-_]*$/,fD=/^[-+]?P(?!$)(?:(?:[-+]?\d+Y)|(?:[-+]?\d+[.,]\d+Y$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:(?:[-+]?\d+W)|(?:[-+]?\d+[.,]\d+W$))?(?:(?:[-+]?\d+D)|(?:[-+]?\d+[.,]\d+D$))?(?:T(?=[\d+-])(?:(?:[-+]?\d+H)|(?:[-+]?\d+[.,]\d+H$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:[-+]?\d+(?:[.,]\d+)?S)?)??$/,pD=/^(?!\.)(?!.*\.\.)([A-Z0-9_'+\-\.]*)[A-Z0-9_+-]@([A-Z0-9][A-Z0-9\-]*\.)+[A-Z]{2,}$/i,mD="^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$";let $3;const vD=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])$/,gD=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\/(3[0-2]|[12]?[0-9])$/,yD=/^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))$/,_D=/^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))\/(12[0-8]|1[01][0-9]|[1-9]?[0-9])$/,bD=/^([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))?$/,wD=/^([0-9a-zA-Z-_]{4})*(([0-9a-zA-Z-_]{2}(==)?)|([0-9a-zA-Z-_]{3}(=)?))?$/,VR="((\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-((0[13578]|1[02])-(0[1-9]|[12]\\d|3[01])|(0[469]|11)-(0[1-9]|[12]\\d|30)|(02)-(0[1-9]|1\\d|2[0-8])))",xD=new RegExp(`^${VR}$`);function FR(r){let e="([01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d";return r.precision?e=`${e}\\.\\d{${r.precision}}`:r.precision==null&&(e=`${e}(\\.\\d+)?`),e}function CD(r){return new RegExp(`^${FR(r)}$`)}function jR(r){let e=`${VR}T${FR(r)}`;const t=[];return t.push(r.local?"Z?":"Z"),r.offset&&t.push("([+-]\\d{2}:?\\d{2})"),e=`${e}(${t.join("|")})`,new RegExp(`^${e}$`)}function kD(r,e){return!!((e==="v4"||!e)&&vD.test(r)||(e==="v6"||!e)&&yD.test(r))}function ED(r,e){if(!hD.test(r))return!1;try{const[t]=r.split("."),n=t.replace(/-/g,"+").replace(/_/g,"/").padEnd(t.length+(4-t.length%4)%4,"="),i=JSON.parse(atob(n));return!(typeof i!="object"||i===null||!i.typ||!i.alg||e&&i.alg!==e)}catch{return!1}}function SD(r,e){return!!((e==="v4"||!e)&&gD.test(r)||(e==="v6"||!e)&&_D.test(r))}class Pa extends Lt{_parse(e){if(this._def.coerce&&(e.data=String(e.data)),this._getType(e)!==Ue.string){const o=this._getOrReturnCtx(e);return Le(o,{code:be.invalid_type,expected:Ue.string,received:o.parsedType}),bt}const n=new ki;let i;for(const o of this._def.checks)if(o.kind==="min")e.data.length<o.value&&(i=this._getOrReturnCtx(e,i),Le(i,{code:be.too_small,minimum:o.value,type:"string",inclusive:!0,exact:!1,message:o.message}),n.dirty());else if(o.kind==="max")e.data.length>o.value&&(i=this._getOrReturnCtx(e,i),Le(i,{code:be.too_big,maximum:o.value,type:"string",inclusive:!0,exact:!1,message:o.message}),n.dirty());else if(o.kind==="length"){const a=e.data.length>o.value,c=e.data.length<o.value;(a||c)&&(i=this._getOrReturnCtx(e,i),a?Le(i,{code:be.too_big,maximum:o.value,type:"string",inclusive:!0,exact:!0,message:o.message}):c&&Le(i,{code:be.too_small,minimum:o.value,type:"string",inclusive:!0,exact:!0,message:o.message}),n.dirty())}else if(o.kind==="email")pD.test(e.data)||(i=this._getOrReturnCtx(e,i),Le(i,{validation:"email",code:be.invalid_string,message:o.message}),n.dirty());else if(o.kind==="emoji")$3||($3=new RegExp(mD,"u")),$3.test(e.data)||(i=this._getOrReturnCtx(e,i),Le(i,{validation:"emoji",code:be.invalid_string,message:o.message}),n.dirty());else if(o.kind==="uuid")dD.test(e.data)||(i=this._getOrReturnCtx(e,i),Le(i,{validation:"uuid",code:be.invalid_string,message:o.message}),n.dirty());else if(o.kind==="nanoid")uD.test(e.data)||(i=this._getOrReturnCtx(e,i),Le(i,{validation:"nanoid",code:be.invalid_string,message:o.message}),n.dirty());else if(o.kind==="cuid")sD.test(e.data)||(i=this._getOrReturnCtx(e,i),Le(i,{validation:"cuid",code:be.invalid_string,message:o.message}),n.dirty());else if(o.kind==="cuid2")cD.test(e.data)||(i=this._getOrReturnCtx(e,i),Le(i,{validation:"cuid2",code:be.invalid_string,message:o.message}),n.dirty());else if(o.kind==="ulid")lD.test(e.data)||(i=this._getOrReturnCtx(e,i),Le(i,{validation:"ulid",code:be.invalid_string,message:o.message}),n.dirty());else if(o.kind==="url")try{new URL(e.data)}catch{i=this._getOrReturnCtx(e,i),Le(i,{validation:"url",code:be.invalid_string,message:o.message}),n.dirty()}else o.kind==="regex"?(o.regex.lastIndex=0,o.regex.test(e.data)||(i=this._getOrReturnCtx(e,i),Le(i,{validation:"regex",code:be.invalid_string,message:o.message}),n.dirty())):o.kind==="trim"?e.data=e.data.trim():o.kind==="includes"?e.data.includes(o.value,o.position)||(i=this._getOrReturnCtx(e,i),Le(i,{code:be.invalid_string,validation:{includes:o.value,position:o.position},message:o.message}),n.dirty()):o.kind==="toLowerCase"?e.data=e.data.toLowerCase():o.kind==="toUpperCase"?e.data=e.data.toUpperCase():o.kind==="startsWith"?e.data.startsWith(o.value)||(i=this._getOrReturnCtx(e,i),Le(i,{code:be.invalid_string,validation:{startsWith:o.value},message:o.message}),n.dirty()):o.kind==="endsWith"?e.data.endsWith(o.value)||(i=this._getOrReturnCtx(e,i),Le(i,{code:be.invalid_string,validation:{endsWith:o.value},message:o.message}),n.dirty()):o.kind==="datetime"?jR(o).test(e.data)||(i=this._getOrReturnCtx(e,i),Le(i,{code:be.invalid_string,validation:"datetime",message:o.message}),n.dirty()):o.kind==="date"?xD.test(e.data)||(i=this._getOrReturnCtx(e,i),Le(i,{code:be.invalid_string,validation:"date",message:o.message}),n.dirty()):o.kind==="time"?CD(o).test(e.data)||(i=this._getOrReturnCtx(e,i),Le(i,{code:be.invalid_string,validation:"time",message:o.message}),n.dirty()):o.kind==="duration"?fD.test(e.data)||(i=this._getOrReturnCtx(e,i),Le(i,{validation:"duration",code:be.invalid_string,message:o.message}),n.dirty()):o.kind==="ip"?kD(e.data,o.version)||(i=this._getOrReturnCtx(e,i),Le(i,{validation:"ip",code:be.invalid_string,message:o.message}),n.dirty()):o.kind==="jwt"?ED(e.data,o.alg)||(i=this._getOrReturnCtx(e,i),Le(i,{validation:"jwt",code:be.invalid_string,message:o.message}),n.dirty()):o.kind==="cidr"?SD(e.data,o.version)||(i=this._getOrReturnCtx(e,i),Le(i,{validation:"cidr",code:be.invalid_string,message:o.message}),n.dirty()):o.kind==="base64"?bD.test(e.data)||(i=this._getOrReturnCtx(e,i),Le(i,{validation:"base64",code:be.invalid_string,message:o.message}),n.dirty()):o.kind==="base64url"?wD.test(e.data)||(i=this._getOrReturnCtx(e,i),Le(i,{validation:"base64url",code:be.invalid_string,message:o.message}),n.dirty()):Qt.assertNever(o);return{status:n.value,value:e.data}}_regex(e,t,n){return this.refinement(i=>e.test(i),{validation:t,code:be.invalid_string,...ct.errToObj(n)})}_addCheck(e){return new Pa({...this._def,checks:[...this._def.checks,e]})}email(e){return this._addCheck({kind:"email",...ct.errToObj(e)})}url(e){return this._addCheck({kind:"url",...ct.errToObj(e)})}emoji(e){return this._addCheck({kind:"emoji",...ct.errToObj(e)})}uuid(e){return this._addCheck({kind:"uuid",...ct.errToObj(e)})}nanoid(e){return this._addCheck({kind:"nanoid",...ct.errToObj(e)})}cuid(e){return this._addCheck({kind:"cuid",...ct.errToObj(e)})}cuid2(e){return this._addCheck({kind:"cuid2",...ct.errToObj(e)})}ulid(e){return this._addCheck({kind:"ulid",...ct.errToObj(e)})}base64(e){return this._addCheck({kind:"base64",...ct.errToObj(e)})}base64url(e){return this._addCheck({kind:"base64url",...ct.errToObj(e)})}jwt(e){return this._addCheck({kind:"jwt",...ct.errToObj(e)})}ip(e){return this._addCheck({kind:"ip",...ct.errToObj(e)})}cidr(e){return this._addCheck({kind:"cidr",...ct.errToObj(e)})}datetime(e){var t,n;return typeof e=="string"?this._addCheck({kind:"datetime",precision:null,offset:!1,local:!1,message:e}):this._addCheck({kind:"datetime",precision:typeof(e==null?void 0:e.precision)>"u"?null:e==null?void 0:e.precision,offset:(t=e==null?void 0:e.offset)!==null&&t!==void 0?t:!1,local:(n=e==null?void 0:e.local)!==null&&n!==void 0?n:!1,...ct.errToObj(e==null?void 0:e.message)})}date(e){return this._addCheck({kind:"date",message:e})}time(e){return typeof e=="string"?this._addCheck({kind:"time",precision:null,message:e}):this._addCheck({kind:"time",precision:typeof(e==null?void 0:e.precision)>"u"?null:e==null?void 0:e.precision,...ct.errToObj(e==null?void 0:e.message)})}duration(e){return this._addCheck({kind:"duration",...ct.errToObj(e)})}regex(e,t){return this._addCheck({kind:"regex",regex:e,...ct.errToObj(t)})}includes(e,t){return this._addCheck({kind:"includes",value:e,position:t==null?void 0:t.position,...ct.errToObj(t==null?void 0:t.message)})}startsWith(e,t){return this._addCheck({kind:"startsWith",value:e,...ct.errToObj(t)})}endsWith(e,t){return this._addCheck({kind:"endsWith",value:e,...ct.errToObj(t)})}min(e,t){return this._addCheck({kind:"min",value:e,...ct.errToObj(t)})}max(e,t){return this._addCheck({kind:"max",value:e,...ct.errToObj(t)})}length(e,t){return this._addCheck({kind:"length",value:e,...ct.errToObj(t)})}nonempty(e){return this.min(1,ct.errToObj(e))}trim(){return new Pa({...this._def,checks:[...this._def.checks,{kind:"trim"}]})}toLowerCase(){return new Pa({...this._def,checks:[...this._def.checks,{kind:"toLowerCase"}]})}toUpperCase(){return new Pa({...this._def,checks:[...this._def.checks,{kind:"toUpperCase"}]})}get isDatetime(){return!!this._def.checks.find(e=>e.kind==="datetime")}get isDate(){return!!this._def.checks.find(e=>e.kind==="date")}get isTime(){return!!this._def.checks.find(e=>e.kind==="time")}get isDuration(){return!!this._def.checks.find(e=>e.kind==="duration")}get isEmail(){return!!this._def.checks.find(e=>e.kind==="email")}get isURL(){return!!this._def.checks.find(e=>e.kind==="url")}get isEmoji(){return!!this._def.checks.find(e=>e.kind==="emoji")}get isUUID(){return!!this._def.checks.find(e=>e.kind==="uuid")}get isNANOID(){return!!this._def.checks.find(e=>e.kind==="nanoid")}get isCUID(){return!!this._def.checks.find(e=>e.kind==="cuid")}get isCUID2(){return!!this._def.checks.find(e=>e.kind==="cuid2")}get isULID(){return!!this._def.checks.find(e=>e.kind==="ulid")}get isIP(){return!!this._def.checks.find(e=>e.kind==="ip")}get isCIDR(){return!!this._def.checks.find(e=>e.kind==="cidr")}get isBase64(){return!!this._def.checks.find(e=>e.kind==="base64")}get isBase64url(){return!!this._def.checks.find(e=>e.kind==="base64url")}get minLength(){let e=null;for(const t of this._def.checks)t.kind==="min"&&(e===null||t.value>e)&&(e=t.value);return e}get maxLength(){let e=null;for(const t of this._def.checks)t.kind==="max"&&(e===null||t.value<e)&&(e=t.value);return e}}Pa.create=r=>{var e;return new Pa({checks:[],typeName:yt.ZodString,coerce:(e=r==null?void 0:r.coerce)!==null&&e!==void 0?e:!1,...Pt(r)})};function TD(r,e){const t=(r.toString().split(".")[1]||"").length,n=(e.toString().split(".")[1]||"").length,i=t>n?t:n,o=parseInt(r.toFixed(i).replace(".","")),a=parseInt(e.toFixed(i).replace(".",""));return o%a/Math.pow(10,i)}class Al extends Lt{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte,this.step=this.multipleOf}_parse(e){if(this._def.coerce&&(e.data=Number(e.data)),this._getType(e)!==Ue.number){const o=this._getOrReturnCtx(e);return Le(o,{code:be.invalid_type,expected:Ue.number,received:o.parsedType}),bt}let n;const i=new ki;for(const o of this._def.checks)o.kind==="int"?Qt.isInteger(e.data)||(n=this._getOrReturnCtx(e,n),Le(n,{code:be.invalid_type,expected:"integer",received:"float",message:o.message}),i.dirty()):o.kind==="min"?(o.inclusive?e.data<o.value:e.data<=o.value)&&(n=this._getOrReturnCtx(e,n),Le(n,{code:be.too_small,minimum:o.value,type:"number",inclusive:o.inclusive,exact:!1,message:o.message}),i.dirty()):o.kind==="max"?(o.inclusive?e.data>o.value:e.data>=o.value)&&(n=this._getOrReturnCtx(e,n),Le(n,{code:be.too_big,maximum:o.value,type:"number",inclusive:o.inclusive,exact:!1,message:o.message}),i.dirty()):o.kind==="multipleOf"?TD(e.data,o.value)!==0&&(n=this._getOrReturnCtx(e,n),Le(n,{code:be.not_multiple_of,multipleOf:o.value,message:o.message}),i.dirty()):o.kind==="finite"?Number.isFinite(e.data)||(n=this._getOrReturnCtx(e,n),Le(n,{code:be.not_finite,message:o.message}),i.dirty()):Qt.assertNever(o);return{status:i.value,value:e.data}}gte(e,t){return this.setLimit("min",e,!0,ct.toString(t))}gt(e,t){return this.setLimit("min",e,!1,ct.toString(t))}lte(e,t){return this.setLimit("max",e,!0,ct.toString(t))}lt(e,t){return this.setLimit("max",e,!1,ct.toString(t))}setLimit(e,t,n,i){return new Al({...this._def,checks:[...this._def.checks,{kind:e,value:t,inclusive:n,message:ct.toString(i)}]})}_addCheck(e){return new Al({...this._def,checks:[...this._def.checks,e]})}int(e){return this._addCheck({kind:"int",message:ct.toString(e)})}positive(e){return this._addCheck({kind:"min",value:0,inclusive:!1,message:ct.toString(e)})}negative(e){return this._addCheck({kind:"max",value:0,inclusive:!1,message:ct.toString(e)})}nonpositive(e){return this._addCheck({kind:"max",value:0,inclusive:!0,message:ct.toString(e)})}nonnegative(e){return this._addCheck({kind:"min",value:0,inclusive:!0,message:ct.toString(e)})}multipleOf(e,t){return this._addCheck({kind:"multipleOf",value:e,message:ct.toString(t)})}finite(e){return this._addCheck({kind:"finite",message:ct.toString(e)})}safe(e){return this._addCheck({kind:"min",inclusive:!0,value:Number.MIN_SAFE_INTEGER,message:ct.toString(e)})._addCheck({kind:"max",inclusive:!0,value:Number.MAX_SAFE_INTEGER,message:ct.toString(e)})}get minValue(){let e=null;for(const t of this._def.checks)t.kind==="min"&&(e===null||t.value>e)&&(e=t.value);return e}get maxValue(){let e=null;for(const t of this._def.checks)t.kind==="max"&&(e===null||t.value<e)&&(e=t.value);return e}get isInt(){return!!this._def.checks.find(e=>e.kind==="int"||e.kind==="multipleOf"&&Qt.isInteger(e.value))}get isFinite(){let e=null,t=null;for(const n of this._def.checks){if(n.kind==="finite"||n.kind==="int"||n.kind==="multipleOf")return!0;n.kind==="min"?(t===null||n.value>t)&&(t=n.value):n.kind==="max"&&(e===null||n.value<e)&&(e=n.value)}return Number.isFinite(t)&&Number.isFinite(e)}}Al.create=r=>new Al({checks:[],typeName:yt.ZodNumber,coerce:(r==null?void 0:r.coerce)||!1,...Pt(r)});class Il extends Lt{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte}_parse(e){if(this._def.coerce)try{e.data=BigInt(e.data)}catch{return this._getInvalidInput(e)}if(this._getType(e)!==Ue.bigint)return this._getInvalidInput(e);let n;const i=new ki;for(const o of this._def.checks)o.kind==="min"?(o.inclusive?e.data<o.value:e.data<=o.value)&&(n=this._getOrReturnCtx(e,n),Le(n,{code:be.too_small,type:"bigint",minimum:o.value,inclusive:o.inclusive,message:o.message}),i.dirty()):o.kind==="max"?(o.inclusive?e.data>o.value:e.data>=o.value)&&(n=this._getOrReturnCtx(e,n),Le(n,{code:be.too_big,type:"bigint",maximum:o.value,inclusive:o.inclusive,message:o.message}),i.dirty()):o.kind==="multipleOf"?e.data%o.value!==BigInt(0)&&(n=this._getOrReturnCtx(e,n),Le(n,{code:be.not_multiple_of,multipleOf:o.value,message:o.message}),i.dirty()):Qt.assertNever(o);return{status:i.value,value:e.data}}_getInvalidInput(e){const t=this._getOrReturnCtx(e);return Le(t,{code:be.invalid_type,expected:Ue.bigint,received:t.parsedType}),bt}gte(e,t){return this.setLimit("min",e,!0,ct.toString(t))}gt(e,t){return this.setLimit("min",e,!1,ct.toString(t))}lte(e,t){return this.setLimit("max",e,!0,ct.toString(t))}lt(e,t){return this.setLimit("max",e,!1,ct.toString(t))}setLimit(e,t,n,i){return new Il({...this._def,checks:[...this._def.checks,{kind:e,value:t,inclusive:n,message:ct.toString(i)}]})}_addCheck(e){return new Il({...this._def,checks:[...this._def.checks,e]})}positive(e){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!1,message:ct.toString(e)})}negative(e){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!1,message:ct.toString(e)})}nonpositive(e){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!0,message:ct.toString(e)})}nonnegative(e){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!0,message:ct.toString(e)})}multipleOf(e,t){return this._addCheck({kind:"multipleOf",value:e,message:ct.toString(t)})}get minValue(){let e=null;for(const t of this._def.checks)t.kind==="min"&&(e===null||t.value>e)&&(e=t.value);return e}get maxValue(){let e=null;for(const t of this._def.checks)t.kind==="max"&&(e===null||t.value<e)&&(e=t.value);return e}}Il.create=r=>{var e;return new Il({checks:[],typeName:yt.ZodBigInt,coerce:(e=r==null?void 0:r.coerce)!==null&&e!==void 0?e:!1,...Pt(r)})};class Wp extends Lt{_parse(e){if(this._def.coerce&&(e.data=!!e.data),this._getType(e)!==Ue.boolean){const n=this._getOrReturnCtx(e);return Le(n,{code:be.invalid_type,expected:Ue.boolean,received:n.parsedType}),bt}return Fi(e.data)}}Wp.create=r=>new Wp({typeName:yt.ZodBoolean,coerce:(r==null?void 0:r.coerce)||!1,...Pt(r)});class bu extends Lt{_parse(e){if(this._def.coerce&&(e.data=new Date(e.data)),this._getType(e)!==Ue.date){const o=this._getOrReturnCtx(e);return Le(o,{code:be.invalid_type,expected:Ue.date,received:o.parsedType}),bt}if(isNaN(e.data.getTime())){const o=this._getOrReturnCtx(e);return Le(o,{code:be.invalid_date}),bt}const n=new ki;let i;for(const o of this._def.checks)o.kind==="min"?e.data.getTime()<o.value&&(i=this._getOrReturnCtx(e,i),Le(i,{code:be.too_small,message:o.message,inclusive:!0,exact:!1,minimum:o.value,type:"date"}),n.dirty()):o.kind==="max"?e.data.getTime()>o.value&&(i=this._getOrReturnCtx(e,i),Le(i,{code:be.too_big,message:o.message,inclusive:!0,exact:!1,maximum:o.value,type:"date"}),n.dirty()):Qt.assertNever(o);return{status:n.value,value:new Date(e.data.getTime())}}_addCheck(e){return new bu({...this._def,checks:[...this._def.checks,e]})}min(e,t){return this._addCheck({kind:"min",value:e.getTime(),message:ct.toString(t)})}max(e,t){return this._addCheck({kind:"max",value:e.getTime(),message:ct.toString(t)})}get minDate(){let e=null;for(const t of this._def.checks)t.kind==="min"&&(e===null||t.value>e)&&(e=t.value);return e!=null?new Date(e):null}get maxDate(){let e=null;for(const t of this._def.checks)t.kind==="max"&&(e===null||t.value<e)&&(e=t.value);return e!=null?new Date(e):null}}bu.create=r=>new bu({checks:[],coerce:(r==null?void 0:r.coerce)||!1,typeName:yt.ZodDate,...Pt(r)});class cg extends Lt{_parse(e){if(this._getType(e)!==Ue.symbol){const n=this._getOrReturnCtx(e);return Le(n,{code:be.invalid_type,expected:Ue.symbol,received:n.parsedType}),bt}return Fi(e.data)}}cg.create=r=>new cg({typeName:yt.ZodSymbol,...Pt(r)});class Gp extends Lt{_parse(e){if(this._getType(e)!==Ue.undefined){const n=this._getOrReturnCtx(e);return Le(n,{code:be.invalid_type,expected:Ue.undefined,received:n.parsedType}),bt}return Fi(e.data)}}Gp.create=r=>new Gp({typeName:yt.ZodUndefined,...Pt(r)});class Kp extends Lt{_parse(e){if(this._getType(e)!==Ue.null){const n=this._getOrReturnCtx(e);return Le(n,{code:be.invalid_type,expected:Ue.null,received:n.parsedType}),bt}return Fi(e.data)}}Kp.create=r=>new Kp({typeName:yt.ZodNull,...Pt(r)});class mf extends Lt{constructor(){super(...arguments),this._any=!0}_parse(e){return Fi(e.data)}}mf.create=r=>new mf({typeName:yt.ZodAny,...Pt(r)});class au extends Lt{constructor(){super(...arguments),this._unknown=!0}_parse(e){return Fi(e.data)}}au.create=r=>new au({typeName:yt.ZodUnknown,...Pt(r)});class gc extends Lt{_parse(e){const t=this._getOrReturnCtx(e);return Le(t,{code:be.invalid_type,expected:Ue.never,received:t.parsedType}),bt}}gc.create=r=>new gc({typeName:yt.ZodNever,...Pt(r)});class lg extends Lt{_parse(e){if(this._getType(e)!==Ue.undefined){const n=this._getOrReturnCtx(e);return Le(n,{code:be.invalid_type,expected:Ue.void,received:n.parsedType}),bt}return Fi(e.data)}}lg.create=r=>new lg({typeName:yt.ZodVoid,...Pt(r)});class Oa extends Lt{_parse(e){const{ctx:t,status:n}=this._processInputParams(e),i=this._def;if(t.parsedType!==Ue.array)return Le(t,{code:be.invalid_type,expected:Ue.array,received:t.parsedType}),bt;if(i.exactLength!==null){const a=t.data.length>i.exactLength.value,c=t.data.length<i.exactLength.value;(a||c)&&(Le(t,{code:a?be.too_big:be.too_small,minimum:c?i.exactLength.value:void 0,maximum:a?i.exactLength.value:void 0,type:"array",inclusive:!0,exact:!0,message:i.exactLength.message}),n.dirty())}if(i.minLength!==null&&t.data.length<i.minLength.value&&(Le(t,{code:be.too_small,minimum:i.minLength.value,type:"array",inclusive:!0,exact:!1,message:i.minLength.message}),n.dirty()),i.maxLength!==null&&t.data.length>i.maxLength.value&&(Le(t,{code:be.too_big,maximum:i.maxLength.value,type:"array",inclusive:!0,exact:!1,message:i.maxLength.message}),n.dirty()),t.common.async)return Promise.all([...t.data].map((a,c)=>i.type._parseAsync(new bs(t,a,t.path,c)))).then(a=>ki.mergeArray(n,a));const o=[...t.data].map((a,c)=>i.type._parseSync(new bs(t,a,t.path,c)));return ki.mergeArray(n,o)}get element(){return this._def.type}min(e,t){return new Oa({...this._def,minLength:{value:e,message:ct.toString(t)}})}max(e,t){return new Oa({...this._def,maxLength:{value:e,message:ct.toString(t)}})}length(e,t){return new Oa({...this._def,exactLength:{value:e,message:ct.toString(t)}})}nonempty(e){return this.min(1,e)}}Oa.create=(r,e)=>new Oa({type:r,minLength:null,maxLength:null,exactLength:null,typeName:yt.ZodArray,...Pt(e)});function Lh(r){if(r instanceof nn){const e={};for(const t in r.shape){const n=r.shape[t];e[t]=ps.create(Lh(n))}return new nn({...r._def,shape:()=>e})}else return r instanceof Oa?new Oa({...r._def,type:Lh(r.element)}):r instanceof ps?ps.create(Lh(r.unwrap())):r instanceof Pl?Pl.create(Lh(r.unwrap())):r instanceof ws?ws.create(r.items.map(e=>Lh(e))):r}class nn extends Lt{constructor(){super(...arguments),this._cached=null,this.nonstrict=this.passthrough,this.augment=this.extend}_getCached(){if(this._cached!==null)return this._cached;const e=this._def.shape(),t=Qt.objectKeys(e);return this._cached={shape:e,keys:t}}_parse(e){if(this._getType(e)!==Ue.object){const h=this._getOrReturnCtx(e);return Le(h,{code:be.invalid_type,expected:Ue.object,received:h.parsedType}),bt}const{status:n,ctx:i}=this._processInputParams(e),{shape:o,keys:a}=this._getCached(),c=[];if(!(this._def.catchall instanceof gc&&this._def.unknownKeys==="strip"))for(const h in i.data)a.includes(h)||c.push(h);const d=[];for(const h of a){const u=o[h],p=i.data[h];d.push({key:{status:"valid",value:h},value:u._parse(new bs(i,p,i.path,h)),alwaysSet:h in i.data})}if(this._def.catchall instanceof gc){const h=this._def.unknownKeys;if(h==="passthrough")for(const u of c)d.push({key:{status:"valid",value:u},value:{status:"valid",value:i.data[u]}});else if(h==="strict")c.length>0&&(Le(i,{code:be.unrecognized_keys,keys:c}),n.dirty());else if(h!=="strip")throw new Error("Internal ZodObject error: invalid unknownKeys value.")}else{const h=this._def.catchall;for(const u of c){const p=i.data[u];d.push({key:{status:"valid",value:u},value:h._parse(new bs(i,p,i.path,u)),alwaysSet:u in i.data})}}return i.common.async?Promise.resolve().then(async()=>{const h=[];for(const u of d){const p=await u.key,v=await u.value;h.push({key:p,value:v,alwaysSet:u.alwaysSet})}return h}).then(h=>ki.mergeObjectSync(n,h)):ki.mergeObjectSync(n,d)}get shape(){return this._def.shape()}strict(e){return ct.errToObj,new nn({...this._def,unknownKeys:"strict",...e!==void 0?{errorMap:(t,n)=>{var i,o,a,c;const d=(a=(o=(i=this._def).errorMap)===null||o===void 0?void 0:o.call(i,t,n).message)!==null&&a!==void 0?a:n.defaultError;return t.code==="unrecognized_keys"?{message:(c=ct.errToObj(e).message)!==null&&c!==void 0?c:d}:{message:d}}}:{}})}strip(){return new nn({...this._def,unknownKeys:"strip"})}passthrough(){return new nn({...this._def,unknownKeys:"passthrough"})}extend(e){return new nn({...this._def,shape:()=>({...this._def.shape(),...e})})}merge(e){return new nn({unknownKeys:e._def.unknownKeys,catchall:e._def.catchall,shape:()=>({...this._def.shape(),...e._def.shape()}),typeName:yt.ZodObject})}setKey(e,t){return this.augment({[e]:t})}catchall(e){return new nn({...this._def,catchall:e})}pick(e){const t={};return Qt.objectKeys(e).forEach(n=>{e[n]&&this.shape[n]&&(t[n]=this.shape[n])}),new nn({...this._def,shape:()=>t})}omit(e){const t={};return Qt.objectKeys(this.shape).forEach(n=>{e[n]||(t[n]=this.shape[n])}),new nn({...this._def,shape:()=>t})}deepPartial(){return Lh(this)}partial(e){const t={};return Qt.objectKeys(this.shape).forEach(n=>{const i=this.shape[n];e&&!e[n]?t[n]=i:t[n]=i.optional()}),new nn({...this._def,shape:()=>t})}required(e){const t={};return Qt.objectKeys(this.shape).forEach(n=>{if(e&&!e[n])t[n]=this.shape[n];else{let o=this.shape[n];for(;o instanceof ps;)o=o._def.innerType;t[n]=o}}),new nn({...this._def,shape:()=>t})}keyof(){return zR(Qt.objectKeys(this.shape))}}nn.create=(r,e)=>new nn({shape:()=>r,unknownKeys:"strip",catchall:gc.create(),typeName:yt.ZodObject,...Pt(e)});nn.strictCreate=(r,e)=>new nn({shape:()=>r,unknownKeys:"strict",catchall:gc.create(),typeName:yt.ZodObject,...Pt(e)});nn.lazycreate=(r,e)=>new nn({shape:r,unknownKeys:"strip",catchall:gc.create(),typeName:yt.ZodObject,...Pt(e)});class Yp extends Lt{_parse(e){const{ctx:t}=this._processInputParams(e),n=this._def.options;function i(o){for(const c of o)if(c.result.status==="valid")return c.result;for(const c of o)if(c.result.status==="dirty")return t.common.issues.push(...c.ctx.common.issues),c.result;const a=o.map(c=>new ko(c.ctx.common.issues));return Le(t,{code:be.invalid_union,unionErrors:a}),bt}if(t.common.async)return Promise.all(n.map(async o=>{const a={...t,common:{...t.common,issues:[]},parent:null};return{result:await o._parseAsync({data:t.data,path:t.path,parent:a}),ctx:a}})).then(i);{let o;const a=[];for(const d of n){const h={...t,common:{...t.common,issues:[]},parent:null},u=d._parseSync({data:t.data,path:t.path,parent:h});if(u.status==="valid")return u;u.status==="dirty"&&!o&&(o={result:u,ctx:h}),h.common.issues.length&&a.push(h.common.issues)}if(o)return t.common.issues.push(...o.ctx.common.issues),o.result;const c=a.map(d=>new ko(d));return Le(t,{code:be.invalid_union,unionErrors:c}),bt}}get options(){return this._def.options}}Yp.create=(r,e)=>new Yp({options:r,typeName:yt.ZodUnion,...Pt(e)});const Ys=r=>r instanceof Jp?Ys(r.schema):r instanceof Na?Ys(r.innerType()):r instanceof em?[r.value]:r instanceof Rl?r.options:r instanceof tm?Qt.objectValues(r.enum):r instanceof rm?Ys(r._def.innerType):r instanceof Gp?[void 0]:r instanceof Kp?[null]:r instanceof ps?[void 0,...Ys(r.unwrap())]:r instanceof Pl?[null,...Ys(r.unwrap())]:r instanceof S6||r instanceof im?Ys(r.unwrap()):r instanceof nm?Ys(r._def.innerType):[];class h4 extends Lt{_parse(e){const{ctx:t}=this._processInputParams(e);if(t.parsedType!==Ue.object)return Le(t,{code:be.invalid_type,expected:Ue.object,received:t.parsedType}),bt;const n=this.discriminator,i=t.data[n],o=this.optionsMap.get(i);return o?t.common.async?o._parseAsync({data:t.data,path:t.path,parent:t}):o._parseSync({data:t.data,path:t.path,parent:t}):(Le(t,{code:be.invalid_union_discriminator,options:Array.from(this.optionsMap.keys()),path:[n]}),bt)}get discriminator(){return this._def.discriminator}get options(){return this._def.options}get optionsMap(){return this._def.optionsMap}static create(e,t,n){const i=new Map;for(const o of t){const a=Ys(o.shape[e]);if(!a.length)throw new Error(`A discriminator value for key \`${e}\` could not be extracted from all schema options`);for(const c of a){if(i.has(c))throw new Error(`Discriminator property ${String(e)} has duplicate value ${String(c)}`);i.set(c,o)}}return new h4({typeName:yt.ZodDiscriminatedUnion,discriminator:e,options:t,optionsMap:i,...Pt(n)})}}function Eb(r,e){const t=rc(r),n=rc(e);if(r===e)return{valid:!0,data:r};if(t===Ue.object&&n===Ue.object){const i=Qt.objectKeys(e),o=Qt.objectKeys(r).filter(c=>i.indexOf(c)!==-1),a={...r,...e};for(const c of o){const d=Eb(r[c],e[c]);if(!d.valid)return{valid:!1};a[c]=d.data}return{valid:!0,data:a}}else if(t===Ue.array&&n===Ue.array){if(r.length!==e.length)return{valid:!1};const i=[];for(let o=0;o<r.length;o++){const a=r[o],c=e[o],d=Eb(a,c);if(!d.valid)return{valid:!1};i.push(d.data)}return{valid:!0,data:i}}else return t===Ue.date&&n===Ue.date&&+r==+e?{valid:!0,data:r}:{valid:!1}}class Qp extends Lt{_parse(e){const{status:t,ctx:n}=this._processInputParams(e),i=(o,a)=>{if(Cb(o)||Cb(a))return bt;const c=Eb(o.value,a.value);return c.valid?((kb(o)||kb(a))&&t.dirty(),{status:t.value,value:c.data}):(Le(n,{code:be.invalid_intersection_types}),bt)};return n.common.async?Promise.all([this._def.left._parseAsync({data:n.data,path:n.path,parent:n}),this._def.right._parseAsync({data:n.data,path:n.path,parent:n})]).then(([o,a])=>i(o,a)):i(this._def.left._parseSync({data:n.data,path:n.path,parent:n}),this._def.right._parseSync({data:n.data,path:n.path,parent:n}))}}Qp.create=(r,e,t)=>new Qp({left:r,right:e,typeName:yt.ZodIntersection,...Pt(t)});class ws extends Lt{_parse(e){const{status:t,ctx:n}=this._processInputParams(e);if(n.parsedType!==Ue.array)return Le(n,{code:be.invalid_type,expected:Ue.array,received:n.parsedType}),bt;if(n.data.length<this._def.items.length)return Le(n,{code:be.too_small,minimum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),bt;!this._def.rest&&n.data.length>this._def.items.length&&(Le(n,{code:be.too_big,maximum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),t.dirty());const o=[...n.data].map((a,c)=>{const d=this._def.items[c]||this._def.rest;return d?d._parse(new bs(n,a,n.path,c)):null}).filter(a=>!!a);return n.common.async?Promise.all(o).then(a=>ki.mergeArray(t,a)):ki.mergeArray(t,o)}get items(){return this._def.items}rest(e){return new ws({...this._def,rest:e})}}ws.create=(r,e)=>{if(!Array.isArray(r))throw new Error("You must pass an array of schemas to z.tuple([ ... ])");return new ws({items:r,typeName:yt.ZodTuple,rest:null,...Pt(e)})};class Xp extends Lt{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(e){const{status:t,ctx:n}=this._processInputParams(e);if(n.parsedType!==Ue.object)return Le(n,{code:be.invalid_type,expected:Ue.object,received:n.parsedType}),bt;const i=[],o=this._def.keyType,a=this._def.valueType;for(const c in n.data)i.push({key:o._parse(new bs(n,c,n.path,c)),value:a._parse(new bs(n,n.data[c],n.path,c)),alwaysSet:c in n.data});return n.common.async?ki.mergeObjectAsync(t,i):ki.mergeObjectSync(t,i)}get element(){return this._def.valueType}static create(e,t,n){return t instanceof Lt?new Xp({keyType:e,valueType:t,typeName:yt.ZodRecord,...Pt(n)}):new Xp({keyType:Pa.create(),valueType:e,typeName:yt.ZodRecord,...Pt(t)})}}class dg extends Lt{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(e){const{status:t,ctx:n}=this._processInputParams(e);if(n.parsedType!==Ue.map)return Le(n,{code:be.invalid_type,expected:Ue.map,received:n.parsedType}),bt;const i=this._def.keyType,o=this._def.valueType,a=[...n.data.entries()].map(([c,d],h)=>({key:i._parse(new bs(n,c,n.path,[h,"key"])),value:o._parse(new bs(n,d,n.path,[h,"value"]))}));if(n.common.async){const c=new Map;return Promise.resolve().then(async()=>{for(const d of a){const h=await d.key,u=await d.value;if(h.status==="aborted"||u.status==="aborted")return bt;(h.status==="dirty"||u.status==="dirty")&&t.dirty(),c.set(h.value,u.value)}return{status:t.value,value:c}})}else{const c=new Map;for(const d of a){const h=d.key,u=d.value;if(h.status==="aborted"||u.status==="aborted")return bt;(h.status==="dirty"||u.status==="dirty")&&t.dirty(),c.set(h.value,u.value)}return{status:t.value,value:c}}}}dg.create=(r,e,t)=>new dg({valueType:e,keyType:r,typeName:yt.ZodMap,...Pt(t)});class wu extends Lt{_parse(e){const{status:t,ctx:n}=this._processInputParams(e);if(n.parsedType!==Ue.set)return Le(n,{code:be.invalid_type,expected:Ue.set,received:n.parsedType}),bt;const i=this._def;i.minSize!==null&&n.data.size<i.minSize.value&&(Le(n,{code:be.too_small,minimum:i.minSize.value,type:"set",inclusive:!0,exact:!1,message:i.minSize.message}),t.dirty()),i.maxSize!==null&&n.data.size>i.maxSize.value&&(Le(n,{code:be.too_big,maximum:i.maxSize.value,type:"set",inclusive:!0,exact:!1,message:i.maxSize.message}),t.dirty());const o=this._def.valueType;function a(d){const h=new Set;for(const u of d){if(u.status==="aborted")return bt;u.status==="dirty"&&t.dirty(),h.add(u.value)}return{status:t.value,value:h}}const c=[...n.data.values()].map((d,h)=>o._parse(new bs(n,d,n.path,h)));return n.common.async?Promise.all(c).then(d=>a(d)):a(c)}min(e,t){return new wu({...this._def,minSize:{value:e,message:ct.toString(t)}})}max(e,t){return new wu({...this._def,maxSize:{value:e,message:ct.toString(t)}})}size(e,t){return this.min(e,t).max(e,t)}nonempty(e){return this.min(1,e)}}wu.create=(r,e)=>new wu({valueType:r,minSize:null,maxSize:null,typeName:yt.ZodSet,...Pt(e)});class af extends Lt{constructor(){super(...arguments),this.validate=this.implement}_parse(e){const{ctx:t}=this._processInputParams(e);if(t.parsedType!==Ue.function)return Le(t,{code:be.invalid_type,expected:Ue.function,received:t.parsedType}),bt;function n(c,d){return ag({data:c,path:t.path,errorMaps:[t.common.contextualErrorMap,t.schemaErrorMap,og(),pf].filter(h=>!!h),issueData:{code:be.invalid_arguments,argumentsError:d}})}function i(c,d){return ag({data:c,path:t.path,errorMaps:[t.common.contextualErrorMap,t.schemaErrorMap,og(),pf].filter(h=>!!h),issueData:{code:be.invalid_return_type,returnTypeError:d}})}const o={errorMap:t.common.contextualErrorMap},a=t.data;if(this._def.returns instanceof vf){const c=this;return Fi(async function(...d){const h=new ko([]),u=await c._def.args.parseAsync(d,o).catch(g=>{throw h.addIssue(n(d,g)),h}),p=await Reflect.apply(a,this,u);return await c._def.returns._def.type.parseAsync(p,o).catch(g=>{throw h.addIssue(i(p,g)),h})})}else{const c=this;return Fi(function(...d){const h=c._def.args.safeParse(d,o);if(!h.success)throw new ko([n(d,h.error)]);const u=Reflect.apply(a,this,h.data),p=c._def.returns.safeParse(u,o);if(!p.success)throw new ko([i(u,p.error)]);return p.data})}}parameters(){return this._def.args}returnType(){return this._def.returns}args(...e){return new af({...this._def,args:ws.create(e).rest(au.create())})}returns(e){return new af({...this._def,returns:e})}implement(e){return this.parse(e)}strictImplement(e){return this.parse(e)}static create(e,t,n){return new af({args:e||ws.create([]).rest(au.create()),returns:t||au.create(),typeName:yt.ZodFunction,...Pt(n)})}}class Jp extends Lt{get schema(){return this._def.getter()}_parse(e){const{ctx:t}=this._processInputParams(e);return this._def.getter()._parse({data:t.data,path:t.path,parent:t})}}Jp.create=(r,e)=>new Jp({getter:r,typeName:yt.ZodLazy,...Pt(e)});class em extends Lt{_parse(e){if(e.data!==this._def.value){const t=this._getOrReturnCtx(e);return Le(t,{received:t.data,code:be.invalid_literal,expected:this._def.value}),bt}return{status:"valid",value:e.data}}get value(){return this._def.value}}em.create=(r,e)=>new em({value:r,typeName:yt.ZodLiteral,...Pt(e)});function zR(r,e){return new Rl({values:r,typeName:yt.ZodEnum,...Pt(e)})}class Rl extends Lt{constructor(){super(...arguments),ap.set(this,void 0)}_parse(e){if(typeof e.data!="string"){const t=this._getOrReturnCtx(e),n=this._def.values;return Le(t,{expected:Qt.joinValues(n),received:t.parsedType,code:be.invalid_type}),bt}if(sg(this,ap)||DR(this,ap,new Set(this._def.values)),!sg(this,ap).has(e.data)){const t=this._getOrReturnCtx(e),n=this._def.values;return Le(t,{received:t.data,code:be.invalid_enum_value,options:n}),bt}return Fi(e.data)}get options(){return this._def.values}get enum(){const e={};for(const t of this._def.values)e[t]=t;return e}get Values(){const e={};for(const t of this._def.values)e[t]=t;return e}get Enum(){const e={};for(const t of this._def.values)e[t]=t;return e}extract(e,t=this._def){return Rl.create(e,{...this._def,...t})}exclude(e,t=this._def){return Rl.create(this.options.filter(n=>!e.includes(n)),{...this._def,...t})}}ap=new WeakMap;Rl.create=zR;class tm extends Lt{constructor(){super(...arguments),sp.set(this,void 0)}_parse(e){const t=Qt.getValidEnumValues(this._def.values),n=this._getOrReturnCtx(e);if(n.parsedType!==Ue.string&&n.parsedType!==Ue.number){const i=Qt.objectValues(t);return Le(n,{expected:Qt.joinValues(i),received:n.parsedType,code:be.invalid_type}),bt}if(sg(this,sp)||DR(this,sp,new Set(Qt.getValidEnumValues(this._def.values))),!sg(this,sp).has(e.data)){const i=Qt.objectValues(t);return Le(n,{received:n.data,code:be.invalid_enum_value,options:i}),bt}return Fi(e.data)}get enum(){return this._def.values}}sp=new WeakMap;tm.create=(r,e)=>new tm({values:r,typeName:yt.ZodNativeEnum,...Pt(e)});class vf extends Lt{unwrap(){return this._def.type}_parse(e){const{ctx:t}=this._processInputParams(e);if(t.parsedType!==Ue.promise&&t.common.async===!1)return Le(t,{code:be.invalid_type,expected:Ue.promise,received:t.parsedType}),bt;const n=t.parsedType===Ue.promise?t.data:Promise.resolve(t.data);return Fi(n.then(i=>this._def.type.parseAsync(i,{path:t.path,errorMap:t.common.contextualErrorMap})))}}vf.create=(r,e)=>new vf({type:r,typeName:yt.ZodPromise,...Pt(e)});class Na extends Lt{innerType(){return this._def.schema}sourceType(){return this._def.schema._def.typeName===yt.ZodEffects?this._def.schema.sourceType():this._def.schema}_parse(e){const{status:t,ctx:n}=this._processInputParams(e),i=this._def.effect||null,o={addIssue:a=>{Le(n,a),a.fatal?t.abort():t.dirty()},get path(){return n.path}};if(o.addIssue=o.addIssue.bind(o),i.type==="preprocess"){const a=i.transform(n.data,o);if(n.common.async)return Promise.resolve(a).then(async c=>{if(t.value==="aborted")return bt;const d=await this._def.schema._parseAsync({data:c,path:n.path,parent:n});return d.status==="aborted"?bt:d.status==="dirty"||t.value==="dirty"?Wh(d.value):d});{if(t.value==="aborted")return bt;const c=this._def.schema._parseSync({data:a,path:n.path,parent:n});return c.status==="aborted"?bt:c.status==="dirty"||t.value==="dirty"?Wh(c.value):c}}if(i.type==="refinement"){const a=c=>{const d=i.refinement(c,o);if(n.common.async)return Promise.resolve(d);if(d instanceof Promise)throw new Error("Async refinement encountered during synchronous parse operation. Use .parseAsync instead.");return c};if(n.common.async===!1){const c=this._def.schema._parseSync({data:n.data,path:n.path,parent:n});return c.status==="aborted"?bt:(c.status==="dirty"&&t.dirty(),a(c.value),{status:t.value,value:c.value})}else return this._def.schema._parseAsync({data:n.data,path:n.path,parent:n}).then(c=>c.status==="aborted"?bt:(c.status==="dirty"&&t.dirty(),a(c.value).then(()=>({status:t.value,value:c.value}))))}if(i.type==="transform")if(n.common.async===!1){const a=this._def.schema._parseSync({data:n.data,path:n.path,parent:n});if(!_u(a))return a;const c=i.transform(a.value,o);if(c instanceof Promise)throw new Error("Asynchronous transform encountered during synchronous parse operation. Use .parseAsync instead.");return{status:t.value,value:c}}else return this._def.schema._parseAsync({data:n.data,path:n.path,parent:n}).then(a=>_u(a)?Promise.resolve(i.transform(a.value,o)).then(c=>({status:t.value,value:c})):a);Qt.assertNever(i)}}Na.create=(r,e,t)=>new Na({schema:r,typeName:yt.ZodEffects,effect:e,...Pt(t)});Na.createWithPreprocess=(r,e,t)=>new Na({schema:e,effect:{type:"preprocess",transform:r},typeName:yt.ZodEffects,...Pt(t)});class ps extends Lt{_parse(e){return this._getType(e)===Ue.undefined?Fi(void 0):this._def.innerType._parse(e)}unwrap(){return this._def.innerType}}ps.create=(r,e)=>new ps({innerType:r,typeName:yt.ZodOptional,...Pt(e)});class Pl extends Lt{_parse(e){return this._getType(e)===Ue.null?Fi(null):this._def.innerType._parse(e)}unwrap(){return this._def.innerType}}Pl.create=(r,e)=>new Pl({innerType:r,typeName:yt.ZodNullable,...Pt(e)});class rm extends Lt{_parse(e){const{ctx:t}=this._processInputParams(e);let n=t.data;return t.parsedType===Ue.undefined&&(n=this._def.defaultValue()),this._def.innerType._parse({data:n,path:t.path,parent:t})}removeDefault(){return this._def.innerType}}rm.create=(r,e)=>new rm({innerType:r,typeName:yt.ZodDefault,defaultValue:typeof e.default=="function"?e.default:()=>e.default,...Pt(e)});class nm extends Lt{_parse(e){const{ctx:t}=this._processInputParams(e),n={...t,common:{...t.common,issues:[]}},i=this._def.innerType._parse({data:n.data,path:n.path,parent:{...n}});return qp(i)?i.then(o=>({status:"valid",value:o.status==="valid"?o.value:this._def.catchValue({get error(){return new ko(n.common.issues)},input:n.data})})):{status:"valid",value:i.status==="valid"?i.value:this._def.catchValue({get error(){return new ko(n.common.issues)},input:n.data})}}removeCatch(){return this._def.innerType}}nm.create=(r,e)=>new nm({innerType:r,typeName:yt.ZodCatch,catchValue:typeof e.catch=="function"?e.catch:()=>e.catch,...Pt(e)});class ug extends Lt{_parse(e){if(this._getType(e)!==Ue.nan){const n=this._getOrReturnCtx(e);return Le(n,{code:be.invalid_type,expected:Ue.nan,received:n.parsedType}),bt}return{status:"valid",value:e.data}}}ug.create=r=>new ug({typeName:yt.ZodNaN,...Pt(r)});const AD=Symbol("zod_brand");class S6 extends Lt{_parse(e){const{ctx:t}=this._processInputParams(e),n=t.data;return this._def.type._parse({data:n,path:t.path,parent:t})}unwrap(){return this._def.type}}class $m extends Lt{_parse(e){const{status:t,ctx:n}=this._processInputParams(e);if(n.common.async)return(async()=>{const o=await this._def.in._parseAsync({data:n.data,path:n.path,parent:n});return o.status==="aborted"?bt:o.status==="dirty"?(t.dirty(),Wh(o.value)):this._def.out._parseAsync({data:o.value,path:n.path,parent:n})})();{const i=this._def.in._parseSync({data:n.data,path:n.path,parent:n});return i.status==="aborted"?bt:i.status==="dirty"?(t.dirty(),{status:"dirty",value:i.value}):this._def.out._parseSync({data:i.value,path:n.path,parent:n})}}static create(e,t){return new $m({in:e,out:t,typeName:yt.ZodPipeline})}}class im extends Lt{_parse(e){const t=this._def.innerType._parse(e),n=i=>(_u(i)&&(i.value=Object.freeze(i.value)),i);return qp(t)?t.then(i=>n(i)):n(t)}unwrap(){return this._def.innerType}}im.create=(r,e)=>new im({innerType:r,typeName:yt.ZodReadonly,...Pt(e)});function RC(r,e){const t=typeof r=="function"?r(e):typeof r=="string"?{message:r}:r;return typeof t=="string"?{message:t}:t}function BR(r,e={},t){return r?mf.create().superRefine((n,i)=>{var o,a;const c=r(n);if(c instanceof Promise)return c.then(d=>{var h,u;if(!d){const p=RC(e,n),v=(u=(h=p.fatal)!==null&&h!==void 0?h:t)!==null&&u!==void 0?u:!0;i.addIssue({code:"custom",...p,fatal:v})}});if(!c){const d=RC(e,n),h=(a=(o=d.fatal)!==null&&o!==void 0?o:t)!==null&&a!==void 0?a:!0;i.addIssue({code:"custom",...d,fatal:h})}}):mf.create()}const ID={object:nn.lazycreate};var yt;(function(r){r.ZodString="ZodString",r.ZodNumber="ZodNumber",r.ZodNaN="ZodNaN",r.ZodBigInt="ZodBigInt",r.ZodBoolean="ZodBoolean",r.ZodDate="ZodDate",r.ZodSymbol="ZodSymbol",r.ZodUndefined="ZodUndefined",r.ZodNull="ZodNull",r.ZodAny="ZodAny",r.ZodUnknown="ZodUnknown",r.ZodNever="ZodNever",r.ZodVoid="ZodVoid",r.ZodArray="ZodArray",r.ZodObject="ZodObject",r.ZodUnion="ZodUnion",r.ZodDiscriminatedUnion="ZodDiscriminatedUnion",r.ZodIntersection="ZodIntersection",r.ZodTuple="ZodTuple",r.ZodRecord="ZodRecord",r.ZodMap="ZodMap",r.ZodSet="ZodSet",r.ZodFunction="ZodFunction",r.ZodLazy="ZodLazy",r.ZodLiteral="ZodLiteral",r.ZodEnum="ZodEnum",r.ZodEffects="ZodEffects",r.ZodNativeEnum="ZodNativeEnum",r.ZodOptional="ZodOptional",r.ZodNullable="ZodNullable",r.ZodDefault="ZodDefault",r.ZodCatch="ZodCatch",r.ZodPromise="ZodPromise",r.ZodBranded="ZodBranded",r.ZodPipeline="ZodPipeline",r.ZodReadonly="ZodReadonly"})(yt||(yt={}));const RD=(r,e={message:`Input not instance of ${r.name}`})=>BR(t=>t instanceof r,e),bi=Pa.create,UR=Al.create,PD=ug.create,MD=Il.create,T6=Wp.create,Sb=bu.create,$D=cg.create,OD=Gp.create,ZD=Kp.create,LD=mf.create,qR=au.create,HD=gc.create,ND=lg.create,WR=Oa.create,Om=nn.create,DD=nn.strictCreate,VD=Yp.create,FD=h4.create,jD=Qp.create,zD=ws.create,GR=Xp.create,BD=dg.create,UD=wu.create,qD=af.create,WD=Jp.create,GD=em.create,KD=Rl.create,YD=tm.create,QD=vf.create,PC=Na.create,XD=ps.create,JD=Pl.create,eV=Na.createWithPreprocess,tV=$m.create,rV=()=>bi().optional(),nV=()=>UR().optional(),iV=()=>T6().optional(),oV={string:r=>Pa.create({...r,coerce:!0}),number:r=>Al.create({...r,coerce:!0}),boolean:r=>Wp.create({...r,coerce:!0}),bigint:r=>Il.create({...r,coerce:!0}),date:r=>bu.create({...r,coerce:!0})},aV=bt;var F=Object.freeze({__proto__:null,defaultErrorMap:pf,setErrorMap:oD,getErrorMap:og,makeIssue:ag,EMPTY_PATH:aD,addIssueToContext:Le,ParseStatus:ki,INVALID:bt,DIRTY:Wh,OK:Fi,isAborted:Cb,isDirty:kb,isValid:_u,isAsync:qp,get util(){return Qt},get objectUtil(){return xb},ZodParsedType:Ue,getParsedType:rc,ZodType:Lt,datetimeRegex:jR,ZodString:Pa,ZodNumber:Al,ZodBigInt:Il,ZodBoolean:Wp,ZodDate:bu,ZodSymbol:cg,ZodUndefined:Gp,ZodNull:Kp,ZodAny:mf,ZodUnknown:au,ZodNever:gc,ZodVoid:lg,ZodArray:Oa,ZodObject:nn,ZodUnion:Yp,ZodDiscriminatedUnion:h4,ZodIntersection:Qp,ZodTuple:ws,ZodRecord:Xp,ZodMap:dg,ZodSet:wu,ZodFunction:af,ZodLazy:Jp,ZodLiteral:em,ZodEnum:Rl,ZodNativeEnum:tm,ZodPromise:vf,ZodEffects:Na,ZodTransformer:Na,ZodOptional:ps,ZodNullable:Pl,ZodDefault:rm,ZodCatch:nm,ZodNaN:ug,BRAND:AD,ZodBranded:S6,ZodPipeline:$m,ZodReadonly:im,custom:BR,Schema:Lt,ZodSchema:Lt,late:ID,get ZodFirstPartyTypeKind(){return yt},coerce:oV,any:LD,array:WR,bigint:MD,boolean:T6,date:Sb,discriminatedUnion:FD,effect:PC,enum:KD,function:qD,instanceof:RD,intersection:jD,lazy:WD,literal:GD,map:BD,nan:PD,nativeEnum:YD,never:HD,null:ZD,nullable:JD,number:UR,object:Om,oboolean:iV,onumber:nV,optional:XD,ostring:rV,pipeline:tV,preprocess:eV,promise:QD,record:GR,set:UD,strictObject:DD,string:bi,symbol:$D,transformer:PC,tuple:zD,undefined:OD,union:VD,unknown:qR,void:ND,NEVER:aV,ZodIssueCode:be,quotelessJson:iD,ZodError:ko});const KR=()=>F.custom(r=>r===(r==null?void 0:r.toUpperCase()),r=>({code:F.ZodIssueCode.custom,validation:"uppercase",path:["method"],message:[`Provided HTTP method '${r}' must be in uppercase.`,"See RFC 7231 Section 4.1 for more information","https://www.rfc-editor.org/rfc/rfc7231#section-4.1"].join(" ")})),sV=()=>F.enum(["GET","POST","PUT","DELETE","PATCH","OPTIONS","HEAD","CONNECT","TRACE"],{errorMap:r=>{const{received:e,options:t}=r;return{message:["Invalid request method.",`Expected '${t.join(" | ")}', but received '${e}'.`,"See RFC 2615 Section 9 for more information","https://www.w3.org/Protocols/rfc2616/rfc2616-sec9.html"].join(" ")}}}),cV=()=>KR().pipe(sV()),lV=F.object({attributionReporting:F.object({eventSourceEligible:F.boolean().optional(),triggerEligible:F.boolean().optional()}).optional(),body:F.union([F.string(),F.instanceof(Blob),F.instanceof(ArrayBuffer),F.instanceof(FormData),F.instanceof(URLSearchParams),F.instanceof(ReadableStream)]).optional(),browsingTopics:F.boolean().optional(),cache:F.enum(["default","no-store","reload","no-cache","force-cache","only-if-cached"]).optional(),credentials:F.enum(["omit","same-origin","include"]).optional(),headers:F.record(F.string(),F.string()).optional().or(F.instanceof(Headers)),integrity:F.string().optional(),keepalive:F.boolean().optional(),method:cV().optional(),mode:F.enum(["same-origin","cors","no-cors","navigate","websocket"]).optional(),priority:F.enum(["low","high","auto"]).optional(),redirect:F.enum(["follow","error","manual"]).optional(),referrer:F.string().optional(),referrerPolicy:F.enum(["no-referrer","no-referrer-when-downgrade","origin","origin-when-cross-origin","same-origin","strict-origin","strict-origin-when-cross-origin","unsafe-url"]).optional(),signal:F.instanceof(AbortSignal).optional()}),MC=lV.extend({uri:F.string(),path:F.string().optional()}),dV=r=>e=>{var t;const{error:n,success:i,data:o}=KR().safeParse(e.method);if(e.method=i?o:(t=e.method)===null||t===void 0?void 0:t.toUpperCase(),n)for(const a of n.errors)console.warn(a.message);return e},uV=r=>e=>{const{strict:t,parse:n}={},i=t?MC:MC.passthrough();try{const o=i.parse(e);return n?o:void 0}catch(o){if(n)throw o;console.error("Invalid request options",o.message)}};class hV{get clients(){return Object.assign({},this._clients)}constructor(e){this._clients={},this.defaultHttpRequestHandler=new HR({"capitalize-method":dV(),"request-validation":uV()}),this.defaultHttpClientCtor=e}hasClient(e){return Object.keys(this._clients).includes(e)}configureClient(e,t){const n=typeof t=="string"?{baseUri:t}:t,i=typeof n=="function"?{onCreate:n}:n;return this._clients[e]=Object.assign(Object.assign({},this._clients[e]),i),this}}class fV extends Error{}const pV=r=>new RegExp("^(https?:\\/\\/)?((([a-z\\d]([a-z\\d-]*[a-z\\d])*)\\.?)+[a-z]{2,}|((\\d{1,3}\\.){3}\\d{1,3}))(\\:\\d+)?(\\/[-a-z\\d%_.~+]*)*(\\?[;&a-z\\d%_.~+=-]*)?(\\#[-a-z\\d_]*)?$","i").test(r);class mV{get defaultHttpRequestHandler(){return this.config.defaultHttpRequestHandler}constructor(e){this.config=e}hasClient(e){return Object.keys(this.config.clients).includes(e)}createClient(e){const t=this._resolveConfig(e),{baseUri:n,defaultScopes:i=[],onCreate:o,ctor:a=this.config.defaultHttpClientCtor,requestHandler:c=this.defaultHttpRequestHandler}=t,d={requestHandler:c},h=new a(n||"",d);return Object.assign(h,{defaultScopes:i}),o&&o(h),h}createCustomClient(e){return this.createClient(e)}_resolveConfig(e){if(typeof e=="string"){const t=this.config.clients[e];if(!t&&pV(e))return{baseUri:e};if(!t)throw new fV(`No registered http client for key [${e}]`);return t}return e}}function vV(r,e){e===void 0&&(e={});var t=e.selector,n=oR(e,["selector"]);return new Tt(function(i){var o=new AbortController,a=o.signal,c=!0,d=n.signal;if(d)if(d.aborted)o.abort();else{var h=function(){a.aborted||o.abort()};d.addEventListener("abort",h),i.add(function(){return d.removeEventListener("abort",h)})}var u=Sn(Sn({},n),{signal:a}),p=function(v){c=!1,i.error(v)};return fetch(r,u).then(function(v){t?Zn(t(v)).subscribe(xr(i,void 0,function(){c=!1,i.complete()},p)):(c=!1,i.next(v),i.complete())}).catch(p),function(){c&&o.abort()}})}class su extends Error{constructor(e,t,n){super(e,n),this.response=t}}su.Name="HttpResponseError";class cu extends su{constructor(e,t,n){super(e,t,n),this.name=cu.Name,this.data=n==null?void 0:n.data}}cu.Name="HttpJsonResponseError";var gV=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};const gf=r=>gV(void 0,void 0,void 0,function*(){if(r.status===204)return Promise.resolve();try{const e=yield r.json();if(!r.ok)throw new cu("network response was not OK",r,{data:e});return e}catch(e){throw e instanceof cu?e:new cu("failed to parse response",r,{cause:e})}});var yV=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};const _V=r=>yV(void 0,void 0,void 0,function*(){var e,t,n;if(!r.ok)throw new Error("network response was not OK");if(r.status===204)throw new Error("no content");const i=(n=(t=(e=r.headers.get("content-disposition"))===null||e===void 0?void 0:e.split(";").find(o=>o.includes("filename=")))===null||t===void 0?void 0:t.replace("filename=",""))===null||n===void 0?void 0:n.trim();try{const o=yield r.blob();return{filename:i,blob:o}}catch{throw Error("failed to parse response")}});var $C=function(r,e){var t={};for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&e.indexOf(n)<0&&(t[n]=r[n]);if(r!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,n=Object.getOwnPropertySymbols(r);i<n.length;i++)e.indexOf(n[i])<0&&Object.prototype.propertyIsEnumerable.call(r,n[i])&&(t[n[i]]=r[n[i]]);return t};class bV{get request$(){return this._request$.asObservable()}get response$(){return this._response$.asObservable()}constructor(e,t){this.uri=e,this._request$=new Bn,this._response$=new Bn,this._abort$=new Bn,this.requestHandler=new HR(t==null?void 0:t.requestHandler),this.responseHandler=new nD(t==null?void 0:t.responseHandler),this._init()}_init(){}fetch$(e,t){return this._fetch$(e,t)}fetch(e,t){return zn(this.fetch$(e,t))}fetchAsync(e,t){return this.fetch(e,t)}json$(e,t){var n;const i=typeof(t==null?void 0:t.body)=="object"?JSON.stringify(t==null?void 0:t.body):t==null?void 0:t.body,o=(n=t==null?void 0:t.selector)!==null&&n!==void 0?n:gf,a=new Headers(t==null?void 0:t.headers);return a.append("Accept","application/json"),a.append("Content-Type","application/json"),this.fetch$(e,Object.assign(Object.assign({},t),{body:i,selector:o,headers:a}))}json(e,t){return zn(this.json$(e,t))}blob$(e,t){var n;const i=(n=t==null?void 0:t.selector)!==null&&n!==void 0?n:_V,o=Object.assign(Object.assign({},t),{selector:i});return this.fetch$(e,o)}blob(e,t){return zn(this.blob$(e,t))}jsonAsync(e,t){return this.json(e,t)}execute(e,t,n){return this[e](t,n)}abort(){this._abort$.next()}_fetch$(e,t){const n=t||{},{selector:i}=n,o=$C(n,["selector"]);return It(Object.assign(Object.assign({},o),{uri:this._resolveUrl(e)})).pipe(Wt(c=>this._prepareRequest(c)),Br(c=>this._request$.next(c)),Wt(c=>{var{uri:d,path:h}=c,u=$C(c,["uri","path"]);return vV(d,u)}),Wt(c=>this._prepareResponse(c)),Br(c=>this._response$.next(c)),Wt(c=>{if(i)try{return i(c)}catch(d){throw new su("failed to execute response selector",c,{cause:d})}return It(c)}),ou(this._abort$))}_prepareRequest(e){return this.requestHandler.process(e)}_prepareResponse(e){return this.responseHandler.process(e)}_resolveUrl(e){const{origin:t,pathname:n}=new URL(this.uri||window.location.origin),i=[n,e].join("/").replace(/\/{2,}/g,"/");return new URL(i,t).href}}class wV extends bV{constructor(){super(...arguments),this.defaultScopes=[]}fetch$(e,t){const n=Object.assign(t||{},{scopes:this.defaultScopes.concat((t==null?void 0:t.scopes)||[])});return super._fetch$(e,n)}}var OC=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};const A6={name:"http",configure:()=>new hV(wV),initialize:r=>OC(void 0,[r],void 0,function*({config:e,hasModule:t,requireInstance:n}){const i=new mV(e);if(t("auth")){const o=yield n("auth");i.defaultHttpRequestHandler.set("MSAL",a=>OC(void 0,void 0,void 0,function*(){const{scopes:c=[]}=a;if(c.length){const d=yield o.acquireToken({scopes:c});if(d){const h=new Headers(a.headers);return h.set("Authorization",`Bearer ${d.accessToken}`),Object.assign(Object.assign({},a),{headers:h})}}}))}return i})},xV=r=>({module:A6,configure:r}),YR=(r,e)=>({module:A6,configure:t=>{t.configureClient(r,e)}});var Ma;(function(r){r.V2="v2",r.Latest="4.0.1"})(Ma||(Ma={}));var wh=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};const CV=F.string().transform(r=>String(ep.coerce(r))),kV=F.object({clientId:F.string(),tenantId:F.string(),redirectUri:F.string().optional()}),EV=F.custom(),SV=F.object({client:kV.optional(),provider:EV.optional(),requiresAuth:F.boolean().optional(),version:CV});class TV extends Mm{constructor(){super(),this.version=Ma.Latest,this._set("version",()=>wh(this,void 0,void 0,function*(){return this.version}))}setClientConfig(e){this._set("client",()=>wh(this,void 0,void 0,function*(){return e}))}setRequiresAuth(e){this._set("requiresAuth",()=>wh(this,void 0,void 0,function*(){return e}))}setProvider(e){this._set("provider",()=>wh(this,void 0,void 0,function*(){return e}))}setVersion(e){this._set("version",()=>wh(this,void 0,void 0,function*(){return e}))}_processConfig(e){return wh(this,void 0,void 0,function*(){return SV.parseAsync(e)})}}/*! @azure/msal-browser v2.39.0 2024-06-06 *//*! *****************************************************************************
43
+ `):"",this.name="UnsubscriptionError",this.errors=t}});function Jv(r,e){if(r){var t=r.indexOf(e);0<=t&&r.splice(t,1)}}var ti=function(){function r(e){this.initialTeardown=e,this.closed=!1,this._parentage=null,this._finalizers=null}return r.prototype.unsubscribe=function(){var e,t,n,i,o;if(!this.closed){this.closed=!0;var a=this._parentage;if(a)if(this._parentage=null,Array.isArray(a))try{for(var c=Di(a),d=c.next();!d.done;d=c.next()){var h=d.value;h.remove(this)}}catch(b){e={error:b}}finally{try{d&&!d.done&&(t=c.return)&&t.call(c)}finally{if(e)throw e.error}}else a.remove(this);var u=this.initialTeardown;if(gr(u))try{u()}catch(b){o=b instanceof R3?b.errors:[b]}var p=this._finalizers;if(p){this._finalizers=null;try{for(var v=Di(p),g=v.next();!g.done;g=v.next()){var _=g.value;try{yC(_)}catch(b){o=o??[],b instanceof R3?o=vc(vc([],ys(o)),ys(b.errors)):o.push(b)}}}catch(b){n={error:b}}finally{try{g&&!g.done&&(i=v.return)&&i.call(v)}finally{if(n)throw n.error}}}if(o)throw new R3(o)}},r.prototype.add=function(e){var t;if(e&&e!==this)if(this.closed)yC(e);else{if(e instanceof r){if(e.closed||e._hasParent(this))return;e._addParent(this)}(this._finalizers=(t=this._finalizers)!==null&&t!==void 0?t:[]).push(e)}},r.prototype._hasParent=function(e){var t=this._parentage;return t===e||Array.isArray(t)&&t.includes(e)},r.prototype._addParent=function(e){var t=this._parentage;this._parentage=Array.isArray(t)?(t.push(e),t):t?[t,e]:e},r.prototype._removeParent=function(e){var t=this._parentage;t===e?this._parentage=null:Array.isArray(t)&&Jv(t,e)},r.prototype.remove=function(e){var t=this._finalizers;t&&Jv(t,e),e instanceof r&&e._removeParent(this)},r.EMPTY=function(){var e=new r;return e.closed=!0,e}(),r}(),sR=ti.EMPTY;function cR(r){return r instanceof ti||r&&"closed"in r&&gr(r.remove)&&gr(r.add)&&gr(r.unsubscribe)}function yC(r){gr(r)?r():r.unsubscribe()}var BH={Promise:void 0},UH={setTimeout:function(r,e){for(var t=[],n=2;n<arguments.length;n++)t[n-2]=arguments[n];return setTimeout.apply(void 0,vc([r,e],ys(t)))},clearTimeout:function(r){return clearTimeout(r)},delegate:void 0};function lR(r){UH.setTimeout(function(){throw r})}function eg(){}function fv(r){r()}var p6=function(r){Si(e,r);function e(t){var n=r.call(this)||this;return n.isStopped=!1,t?(n.destination=t,cR(t)&&t.add(n)):n.destination=GH,n}return e.create=function(t,n,i){return new hf(t,n,i)},e.prototype.next=function(t){this.isStopped||this._next(t)},e.prototype.error=function(t){this.isStopped||(this.isStopped=!0,this._error(t))},e.prototype.complete=function(){this.isStopped||(this.isStopped=!0,this._complete())},e.prototype.unsubscribe=function(){this.closed||(this.isStopped=!0,r.prototype.unsubscribe.call(this),this.destination=null)},e.prototype._next=function(t){this.destination.next(t)},e.prototype._error=function(t){try{this.destination.error(t)}finally{this.unsubscribe()}},e.prototype._complete=function(){try{this.destination.complete()}finally{this.unsubscribe()}},e}(ti),qH=function(){function r(e){this.partialObserver=e}return r.prototype.next=function(e){var t=this.partialObserver;if(t.next)try{t.next(e)}catch(n){_0(n)}},r.prototype.error=function(e){var t=this.partialObserver;if(t.error)try{t.error(e)}catch(n){_0(n)}else _0(e)},r.prototype.complete=function(){var e=this.partialObserver;if(e.complete)try{e.complete()}catch(t){_0(t)}},r}(),hf=function(r){Si(e,r);function e(t,n,i){var o=r.call(this)||this,a;return gr(t)||!t?a={next:t??void 0,error:n??void 0,complete:i??void 0}:a=t,o.destination=new qH(a),o}return e}(p6);function _0(r){lR(r)}function WH(r){throw r}var GH={closed:!0,next:eg,error:WH,complete:eg},m6=function(){return typeof Symbol=="function"&&Symbol.observable||"@@observable"}();function Ts(r){return r}function KH(r){return r.length===0?Ts:r.length===1?r[0]:function(t){return r.reduce(function(n,i){return i(n)},t)}}var Tt=function(){function r(e){e&&(this._subscribe=e)}return r.prototype.lift=function(e){var t=new r;return t.source=this,t.operator=e,t},r.prototype.subscribe=function(e,t,n){var i=this,o=QH(e)?e:new hf(e,t,n);return fv(function(){var a=i,c=a.operator,d=a.source;o.add(c?c.call(o,d):d?i._subscribe(o):i._trySubscribe(o))}),o},r.prototype._trySubscribe=function(e){try{return this._subscribe(e)}catch(t){e.error(t)}},r.prototype.forEach=function(e,t){var n=this;return t=_C(t),new t(function(i,o){var a=new hf({next:function(c){try{e(c)}catch(d){o(d),a.unsubscribe()}},error:o,complete:i});n.subscribe(a)})},r.prototype._subscribe=function(e){var t;return(t=this.source)===null||t===void 0?void 0:t.subscribe(e)},r.prototype[m6]=function(){return this},r.prototype.pipe=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return KH(e)(this)},r.prototype.toPromise=function(e){var t=this;return e=_C(e),new e(function(n,i){var o;t.subscribe(function(a){return o=a},function(a){return i(a)},function(){return n(o)})})},r.create=function(e){return new r(e)},r}();function _C(r){var e;return(e=r??BH.Promise)!==null&&e!==void 0?e:Promise}function YH(r){return r&&gr(r.next)&&gr(r.error)&&gr(r.complete)}function QH(r){return r&&r instanceof p6||YH(r)&&cR(r)}function XH(r){return gr(r==null?void 0:r.lift)}function Ar(r){return function(e){if(XH(e))return e.lift(function(t){try{return r(t,this)}catch(n){this.error(n)}});throw new TypeError("Unable to lift unknown Observable type")}}function xr(r,e,t,n,i){return new dR(r,e,t,n,i)}var dR=function(r){Si(e,r);function e(t,n,i,o,a,c){var d=r.call(this,t)||this;return d.onFinalize=a,d.shouldUnsubscribe=c,d._next=n?function(h){try{n(h)}catch(u){t.error(u)}}:r.prototype._next,d._error=o?function(h){try{o(h)}catch(u){t.error(u)}finally{this.unsubscribe()}}:r.prototype._error,d._complete=i?function(){try{i()}catch(h){t.error(h)}finally{this.unsubscribe()}}:r.prototype._complete,d}return e.prototype.unsubscribe=function(){var t;if(!this.shouldUnsubscribe||this.shouldUnsubscribe()){var n=this.closed;r.prototype.unsubscribe.call(this),!n&&((t=this.onFinalize)===null||t===void 0||t.call(this))}},e}(p6),JH=d4(function(r){return function(){r(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"}}),Bn=function(r){Si(e,r);function e(){var t=r.call(this)||this;return t.closed=!1,t.currentObservers=null,t.observers=[],t.isStopped=!1,t.hasError=!1,t.thrownError=null,t}return e.prototype.lift=function(t){var n=new bC(this,this);return n.operator=t,n},e.prototype._throwIfClosed=function(){if(this.closed)throw new JH},e.prototype.next=function(t){var n=this;fv(function(){var i,o;if(n._throwIfClosed(),!n.isStopped){n.currentObservers||(n.currentObservers=Array.from(n.observers));try{for(var a=Di(n.currentObservers),c=a.next();!c.done;c=a.next()){var d=c.value;d.next(t)}}catch(h){i={error:h}}finally{try{c&&!c.done&&(o=a.return)&&o.call(a)}finally{if(i)throw i.error}}}})},e.prototype.error=function(t){var n=this;fv(function(){if(n._throwIfClosed(),!n.isStopped){n.hasError=n.isStopped=!0,n.thrownError=t;for(var i=n.observers;i.length;)i.shift().error(t)}})},e.prototype.complete=function(){var t=this;fv(function(){if(t._throwIfClosed(),!t.isStopped){t.isStopped=!0;for(var n=t.observers;n.length;)n.shift().complete()}})},e.prototype.unsubscribe=function(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null},Object.defineProperty(e.prototype,"observed",{get:function(){var t;return((t=this.observers)===null||t===void 0?void 0:t.length)>0},enumerable:!1,configurable:!0}),e.prototype._trySubscribe=function(t){return this._throwIfClosed(),r.prototype._trySubscribe.call(this,t)},e.prototype._subscribe=function(t){return this._throwIfClosed(),this._checkFinalizedStatuses(t),this._innerSubscribe(t)},e.prototype._innerSubscribe=function(t){var n=this,i=this,o=i.hasError,a=i.isStopped,c=i.observers;return o||a?sR:(this.currentObservers=null,c.push(t),new ti(function(){n.currentObservers=null,Jv(c,t)}))},e.prototype._checkFinalizedStatuses=function(t){var n=this,i=n.hasError,o=n.thrownError,a=n.isStopped;i?t.error(o):a&&t.complete()},e.prototype.asObservable=function(){var t=new Tt;return t.source=this,t},e.create=function(t,n){return new bC(t,n)},e}(Tt),bC=function(r){Si(e,r);function e(t,n){var i=r.call(this)||this;return i.destination=t,i.source=n,i}return e.prototype.next=function(t){var n,i;(i=(n=this.destination)===null||n===void 0?void 0:n.next)===null||i===void 0||i.call(n,t)},e.prototype.error=function(t){var n,i;(i=(n=this.destination)===null||n===void 0?void 0:n.error)===null||i===void 0||i.call(n,t)},e.prototype.complete=function(){var t,n;(n=(t=this.destination)===null||t===void 0?void 0:t.complete)===null||n===void 0||n.call(t)},e.prototype._subscribe=function(t){var n,i;return(i=(n=this.source)===null||n===void 0?void 0:n.subscribe(t))!==null&&i!==void 0?i:sR},e}(Bn),Df=function(r){Si(e,r);function e(t){var n=r.call(this)||this;return n._value=t,n}return Object.defineProperty(e.prototype,"value",{get:function(){return this.getValue()},enumerable:!1,configurable:!0}),e.prototype._subscribe=function(t){var n=r.prototype._subscribe.call(this,t);return!n.closed&&t.next(this._value),n},e.prototype.getValue=function(){var t=this,n=t.hasError,i=t.thrownError,o=t._value;if(n)throw i;return this._throwIfClosed(),o},e.prototype.next=function(t){r.prototype.next.call(this,this._value=t)},e}(Bn),v6={now:function(){return(v6.delegate||Date).now()},delegate:void 0},uR=function(r){Si(e,r);function e(t,n,i){t===void 0&&(t=1/0),n===void 0&&(n=1/0),i===void 0&&(i=v6);var o=r.call(this)||this;return o._bufferSize=t,o._windowTime=n,o._timestampProvider=i,o._buffer=[],o._infiniteTimeWindow=!0,o._infiniteTimeWindow=n===1/0,o._bufferSize=Math.max(1,t),o._windowTime=Math.max(1,n),o}return e.prototype.next=function(t){var n=this,i=n.isStopped,o=n._buffer,a=n._infiniteTimeWindow,c=n._timestampProvider,d=n._windowTime;i||(o.push(t),!a&&o.push(c.now()+d)),this._trimBuffer(),r.prototype.next.call(this,t)},e.prototype._subscribe=function(t){this._throwIfClosed(),this._trimBuffer();for(var n=this._innerSubscribe(t),i=this,o=i._infiniteTimeWindow,a=i._buffer,c=a.slice(),d=0;d<c.length&&!t.closed;d+=o?1:2)t.next(c[d]);return this._checkFinalizedStatuses(t),n},e.prototype._trimBuffer=function(){var t=this,n=t._bufferSize,i=t._timestampProvider,o=t._buffer,a=t._infiniteTimeWindow,c=(a?1:2)*n;if(n<1/0&&c<o.length&&o.splice(0,o.length-c),!a){for(var d=i.now(),h=0,u=1;u<o.length&&o[u]<=d;u+=2)h=u;h&&o.splice(0,h+1)}},e}(Bn),eN=function(r){Si(e,r);function e(t,n){return r.call(this)||this}return e.prototype.schedule=function(t,n){return this},e}(ti),wC={setInterval:function(r,e){for(var t=[],n=2;n<arguments.length;n++)t[n-2]=arguments[n];return setInterval.apply(void 0,vc([r,e],ys(t)))},clearInterval:function(r){return clearInterval(r)},delegate:void 0},tN=function(r){Si(e,r);function e(t,n){var i=r.call(this,t,n)||this;return i.scheduler=t,i.work=n,i.pending=!1,i}return e.prototype.schedule=function(t,n){var i;if(n===void 0&&(n=0),this.closed)return this;this.state=t;var o=this.id,a=this.scheduler;return o!=null&&(this.id=this.recycleAsyncId(a,o,n)),this.pending=!0,this.delay=n,this.id=(i=this.id)!==null&&i!==void 0?i:this.requestAsyncId(a,this.id,n),this},e.prototype.requestAsyncId=function(t,n,i){return i===void 0&&(i=0),wC.setInterval(t.flush.bind(t,this),i)},e.prototype.recycleAsyncId=function(t,n,i){if(i===void 0&&(i=0),i!=null&&this.delay===i&&this.pending===!1)return n;n!=null&&wC.clearInterval(n)},e.prototype.execute=function(t,n){if(this.closed)return new Error("executing a cancelled action");this.pending=!1;var i=this._execute(t,n);if(i)return i;this.pending===!1&&this.id!=null&&(this.id=this.recycleAsyncId(this.scheduler,this.id,null))},e.prototype._execute=function(t,n){var i=!1,o;try{this.work(t)}catch(a){i=!0,o=a||new Error("Scheduled action threw falsy error")}if(i)return this.unsubscribe(),o},e.prototype.unsubscribe=function(){if(!this.closed){var t=this,n=t.id,i=t.scheduler,o=i.actions;this.work=this.state=this.scheduler=null,this.pending=!1,Jv(o,this),n!=null&&(this.id=this.recycleAsyncId(i,n,null)),this.delay=null,r.prototype.unsubscribe.call(this)}},e}(eN),xC=function(){function r(e,t){t===void 0&&(t=r.now),this.schedulerActionCtor=e,this.now=t}return r.prototype.schedule=function(e,t,n){return t===void 0&&(t=0),new this.schedulerActionCtor(this,e).schedule(n,t)},r.now=v6.now,r}(),rN=function(r){Si(e,r);function e(t,n){n===void 0&&(n=xC.now);var i=r.call(this,t,n)||this;return i.actions=[],i._active=!1,i}return e.prototype.flush=function(t){var n=this.actions;if(this._active){n.push(t);return}var i;this._active=!0;do if(i=t.execute(t.state,t.delay))break;while(t=n.shift());if(this._active=!1,i){for(;t=n.shift();)t.unsubscribe();throw i}},e}(xC),ff=new rN(tN),nN=ff,Tr=new Tt(function(r){return r.complete()});function hR(r){return r&&gr(r.schedule)}function g6(r){return r[r.length-1]}function y6(r){return gr(g6(r))?r.pop():void 0}function u4(r){return hR(g6(r))?r.pop():void 0}function iN(r,e){return typeof g6(r)=="number"?r.pop():e}var _6=function(r){return r&&typeof r.length=="number"&&typeof r!="function"};function fR(r){return gr(r==null?void 0:r.then)}function pR(r){return gr(r[m6])}function mR(r){return Symbol.asyncIterator&&gr(r==null?void 0:r[Symbol.asyncIterator])}function vR(r){return new TypeError("You provided "+(r!==null&&typeof r=="object"?"an invalid object":"'"+r+"'")+" where a stream was expected. You can provide an Observable, Promise, ReadableStream, Array, AsyncIterable, or Iterable.")}function oN(){return typeof Symbol!="function"||!Symbol.iterator?"@@iterator":Symbol.iterator}var gR=oN();function yR(r){return gr(r==null?void 0:r[gR])}function _R(r){return jH(this,arguments,function(){var t,n,i,o;return aR(this,function(a){switch(a.label){case 0:t=r.getReader(),a.label=1;case 1:a.trys.push([1,,9,10]),a.label=2;case 2:return[4,of(t.read())];case 3:return n=a.sent(),i=n.value,o=n.done,o?[4,of(void 0)]:[3,5];case 4:return[2,a.sent()];case 5:return[4,of(i)];case 6:return[4,a.sent()];case 7:return a.sent(),[3,2];case 8:return[3,10];case 9:return t.releaseLock(),[7];case 10:return[2]}})})}function bR(r){return gr(r==null?void 0:r.getReader)}function Zn(r){if(r instanceof Tt)return r;if(r!=null){if(pR(r))return aN(r);if(_6(r))return sN(r);if(fR(r))return cN(r);if(mR(r))return wR(r);if(yR(r))return lN(r);if(bR(r))return dN(r)}throw vR(r)}function aN(r){return new Tt(function(e){var t=r[m6]();if(gr(t.subscribe))return t.subscribe(e);throw new TypeError("Provided object does not correctly implement Symbol.observable")})}function sN(r){return new Tt(function(e){for(var t=0;t<r.length&&!e.closed;t++)e.next(r[t]);e.complete()})}function cN(r){return new Tt(function(e){r.then(function(t){e.closed||(e.next(t),e.complete())},function(t){return e.error(t)}).then(null,lR)})}function lN(r){return new Tt(function(e){var t,n;try{for(var i=Di(r),o=i.next();!o.done;o=i.next()){var a=o.value;if(e.next(a),e.closed)return}}catch(c){t={error:c}}finally{try{o&&!o.done&&(n=i.return)&&n.call(i)}finally{if(t)throw t.error}}e.complete()})}function wR(r){return new Tt(function(e){uN(r,e).catch(function(t){return e.error(t)})})}function dN(r){return wR(_R(r))}function uN(r,e){var t,n,i,o;return uc(this,void 0,void 0,function(){var a,c;return aR(this,function(d){switch(d.label){case 0:d.trys.push([0,5,6,11]),t=zH(r),d.label=1;case 1:return[4,t.next()];case 2:if(n=d.sent(),!!n.done)return[3,4];if(a=n.value,e.next(a),e.closed)return[2];d.label=3;case 3:return[3,1];case 4:return[3,11];case 5:return c=d.sent(),i={error:c},[3,11];case 6:return d.trys.push([6,,9,10]),n&&!n.done&&(o=t.return)?[4,o.call(t)]:[3,8];case 7:d.sent(),d.label=8;case 8:return[3,10];case 9:if(i)throw i.error;return[7];case 10:return[7];case 11:return e.complete(),[2]}})})}function hc(r,e,t,n,i){n===void 0&&(n=0),i===void 0&&(i=!1);var o=e.schedule(function(){t(),i?r.add(this.schedule(null,n)):this.unsubscribe()},n);if(r.add(o),!i)return o}function tg(r,e){return e===void 0&&(e=0),Ar(function(t,n){t.subscribe(xr(n,function(i){return hc(n,r,function(){return n.next(i)},e)},function(){return hc(n,r,function(){return n.complete()},e)},function(i){return hc(n,r,function(){return n.error(i)},e)}))})}function xR(r,e){return e===void 0&&(e=0),Ar(function(t,n){n.add(r.schedule(function(){return t.subscribe(n)},e))})}function hN(r,e){return Zn(r).pipe(xR(e),tg(e))}function fN(r,e){return Zn(r).pipe(xR(e),tg(e))}function pN(r,e){return new Tt(function(t){var n=0;return e.schedule(function(){n===r.length?t.complete():(t.next(r[n++]),t.closed||this.schedule())})})}function mN(r,e){return new Tt(function(t){var n;return hc(t,e,function(){n=r[gR](),hc(t,e,function(){var i,o,a;try{i=n.next(),o=i.value,a=i.done}catch(c){t.error(c);return}a?t.complete():t.next(o)},0,!0)}),function(){return gr(n==null?void 0:n.return)&&n.return()}})}function CR(r,e){if(!r)throw new Error("Iterable cannot be null");return new Tt(function(t){hc(t,e,function(){var n=r[Symbol.asyncIterator]();hc(t,e,function(){n.next().then(function(i){i.done?t.complete():t.next(i.value)})},0,!0)})})}function vN(r,e){return CR(_R(r),e)}function gN(r,e){if(r!=null){if(pR(r))return hN(r,e);if(_6(r))return pN(r,e);if(fR(r))return fN(r,e);if(mR(r))return CR(r,e);if(yR(r))return mN(r,e);if(bR(r))return vN(r,e)}throw vR(r)}function rt(r,e){return e?gN(r,e):Zn(r)}function It(){for(var r=[],e=0;e<arguments.length;e++)r[e]=arguments[e];var t=u4(r);return rt(r,t)}function kR(r,e){var t=gr(r)?r:function(){return r},n=function(i){return i.error(t())};return new Tt(n)}var Pm=d4(function(r){return function(){r(this),this.name="EmptyError",this.message="no elements in sequence"}});function lr(r,e){var t=typeof e=="object";return new Promise(function(n,i){var o=!1,a;r.subscribe({next:function(c){a=c,o=!0},error:i,complete:function(){o?n(a):t?n(e.defaultValue):i(new Pm)}})})}function zn(r,e){var t=typeof e=="object";return new Promise(function(n,i){var o=new hf({next:function(a){n(a),o.unsubscribe()},error:i,complete:function(){t?n(e.defaultValue):i(new Pm)}});r.subscribe(o)})}function ER(r){return r instanceof Date&&!isNaN(r)}var yN=d4(function(r){return function(t){t===void 0&&(t=null),r(this),this.message="Timeout has occurred",this.name="TimeoutError",this.info=t}});function Gs(r,e){var t=ER(r)?{first:r}:typeof r=="number"?{each:r}:r,n=t.first,i=t.each,o=t.with,a=o===void 0?_N:o,c=t.scheduler,d=c===void 0?ff:c,h=t.meta,u=h===void 0?null:h;if(n==null&&i==null)throw new TypeError("No timeout provided.");return Ar(function(p,v){var g,_,b=null,C=0,T=function(S){_=hc(v,d,function(){try{g.unsubscribe(),Zn(a({meta:u,lastValue:b,seen:C})).subscribe(v)}catch(A){v.error(A)}},S)};g=p.subscribe(xr(v,function(S){_==null||_.unsubscribe(),C++,v.next(b=S),i>0&&T(i)},void 0,void 0,function(){_!=null&&_.closed||_==null||_.unsubscribe(),b=null})),!C&&T(n!=null?typeof n=="number"?n:+n-d.now():i)})}function _N(r){throw new yN(r)}function me(r,e){return Ar(function(t,n){var i=0;t.subscribe(xr(n,function(o){n.next(r.call(e,o,i++))}))})}var bN=Array.isArray;function wN(r,e){return bN(e)?r.apply(void 0,vc([],ys(e))):r(e)}function b6(r){return me(function(e){return wN(r,e)})}var xN=Array.isArray,CN=Object.getPrototypeOf,kN=Object.prototype,EN=Object.keys;function SR(r){if(r.length===1){var e=r[0];if(xN(e))return{args:e,keys:null};if(SN(e)){var t=EN(e);return{args:t.map(function(n){return e[n]}),keys:t}}}return{args:r,keys:null}}function SN(r){return r&&typeof r=="object"&&CN(r)===kN}function TR(r,e){return r.reduce(function(t,n,i){return t[n]=e[i],t},{})}function TN(){for(var r=[],e=0;e<arguments.length;e++)r[e]=arguments[e];var t=u4(r),n=y6(r),i=SR(r),o=i.args,a=i.keys;if(o.length===0)return rt([],t);var c=new Tt(AN(o,t,a?function(d){return TR(a,d)}:Ts));return n?c.pipe(b6(n)):c}function AN(r,e,t){return t===void 0&&(t=Ts),function(n){CC(e,function(){for(var i=r.length,o=new Array(i),a=i,c=i,d=function(u){CC(e,function(){var p=rt(r[u],e),v=!1;p.subscribe(xr(n,function(g){o[u]=g,v||(v=!0,c--),c||n.next(t(o.slice()))},function(){--a||n.complete()}))},n)},h=0;h<i;h++)d(h)},n)}}function CC(r,e,t){r?hc(t,r,e):e()}function AR(r,e,t,n,i,o,a,c){var d=[],h=0,u=0,p=!1,v=function(){p&&!d.length&&!h&&e.complete()},g=function(b){return h<n?_(b):d.push(b)},_=function(b){o&&e.next(b),h++;var C=!1;Zn(t(b,u++)).subscribe(xr(e,function(T){i==null||i(T),o?g(T):e.next(T)},function(){C=!0},void 0,function(){if(C)try{h--;for(var T=function(){var S=d.shift();a||_(S)};d.length&&h<n;)T();v()}catch(S){e.error(S)}}))};return r.subscribe(xr(e,g,function(){p=!0,v()})),function(){c==null||c()}}function Jn(r,e,t){return t===void 0&&(t=1/0),gr(e)?Jn(function(n,i){return me(function(o,a){return e(n,o,i,a)})(Zn(r(n,i)))},t):(typeof e=="number"&&(t=e),Ar(function(n,i){return AR(n,i,r,t)}))}function IR(r){return r===void 0&&(r=1/0),Jn(Ts,r)}function IN(){return IR(1)}function xl(){for(var r=[],e=0;e<arguments.length;e++)r[e]=arguments[e];return IN()(rt(r,u4(r)))}function pv(){for(var r=[],e=0;e<arguments.length;e++)r[e]=arguments[e];var t=y6(r),n=SR(r),i=n.args,o=n.keys,a=new Tt(function(c){var d=i.length;if(!d){c.complete();return}for(var h=new Array(d),u=d,p=d,v=function(_){var b=!1;Zn(i[_]).subscribe(xr(c,function(C){b||(b=!0,p--),h[_]=C},function(){return u--},void 0,function(){(!u||!b)&&(p||c.next(o?TR(o,h):h),c.complete())}))},g=0;g<d;g++)v(g)});return t?a.pipe(b6(t)):a}var RN=["addListener","removeListener"],PN=["addEventListener","removeEventListener"],MN=["on","off"];function iu(r,e,t,n){if(gr(t)&&(n=t,t=void 0),n)return iu(r,e,t).pipe(b6(n));var i=ys(ZN(r)?PN.map(function(c){return function(d){return r[c](e,d,t)}}):$N(r)?RN.map(kC(r,e)):ON(r)?MN.map(kC(r,e)):[],2),o=i[0],a=i[1];if(!o&&_6(r))return Jn(function(c){return iu(c,e,t)})(Zn(r));if(!o)throw new TypeError("Invalid event target");return new Tt(function(c){var d=function(){for(var h=[],u=0;u<arguments.length;u++)h[u]=arguments[u];return c.next(1<h.length?h:h[0])};return o(d),function(){return a(d)}})}function kC(r,e){return function(t){return function(n){return r[t](e,n)}}}function $N(r){return gr(r.addListener)&&gr(r.removeListener)}function ON(r){return gr(r.on)&&gr(r.off)}function ZN(r){return gr(r.addEventListener)&&gr(r.removeEventListener)}function w6(r,e,t){r===void 0&&(r=0),t===void 0&&(t=nN);var n=-1;return e!=null&&(hR(e)?t=e:n=e),new Tt(function(i){var o=ER(r)?+r-t.now():r;o<0&&(o=0);var a=0;return t.schedule(function(){i.closed||(i.next(a++),0<=n?this.schedule(void 0,n):i.complete())},o)})}function LN(r,e){return e===void 0&&(e=ff),w6(r,r,e)}function P3(){for(var r=[],e=0;e<arguments.length;e++)r[e]=arguments[e];var t=u4(r),n=iN(r,1/0),i=r;return i.length?i.length===1?Zn(i[0]):IR(n)(rt(i,t)):Tr}function $e(r,e){return Ar(function(t,n){var i=0;t.subscribe(xr(n,function(o){return r.call(e,o,i++)&&n.next(o)}))})}function HN(r){return function(e){for(var t=[],n=function(o){t.push(Zn(r[o]).subscribe(xr(e,function(a){if(t){for(var c=0;c<t.length;c++)c!==o&&t[c].unsubscribe();t=null}e.next(a)})))},i=0;t&&!e.closed&&i<r.length;i++)n(i)}}function Vt(r){return Ar(function(e,t){var n=null,i=!1,o;n=e.subscribe(xr(t,void 0,void 0,function(a){o=Zn(r(a,Vt(r)(e))),n?(n.unsubscribe(),n=null,o.subscribe(t)):i=!0})),i&&(n.unsubscribe(),n=null,o.subscribe(t))})}function RR(r,e,t,n,i){return function(o,a){var c=t,d=e,h=0;o.subscribe(xr(a,function(u){var p=h++;d=c?r(d,u,p):(c=!0,u),n&&a.next(d)},i&&function(){c&&a.next(d),a.complete()}))}}function Bp(r,e){return Ar(RR(r,e,arguments.length>=2,!1,!0))}function _s(r,e){return gr(e)?Jn(r,e,1):Jn(r,1)}function x6(r){return Ar(function(e,t){var n=!1;e.subscribe(xr(t,function(i){n=!0,t.next(i)},function(){n||t.next(r),t.complete()}))})}function tp(r){return r<=0?function(){return Tr}:Ar(function(e,t){var n=0;e.subscribe(xr(t,function(i){++n<=r&&(t.next(i),r<=n&&t.complete())}))})}function rg(r,e){return e===void 0&&(e=Ts),r=r??NN,Ar(function(t,n){var i,o=!0;t.subscribe(xr(n,function(a){var c=e(a);(o||!r(i,c))&&(o=!1,i=c,n.next(a))}))})}function NN(r,e){return r===e}function C6(r){return r===void 0&&(r=DN),Ar(function(e,t){var n=!1;e.subscribe(xr(t,function(i){n=!0,t.next(i)},function(){return n?t.complete():t.error(r())}))})}function DN(){return new Pm}function ng(r){return Ar(function(e,t){try{e.subscribe(t)}finally{t.add(r)}})}function Z1(r,e){return Ar(VN(r,e,"value"))}function VN(r,e,t){return function(n,i){var o=0;n.subscribe(xr(i,function(a){var c=o++;r.call(e,a,c,n)&&(i.next(a),i.complete())},function(){i.next(void 0),i.complete()}))}}function Ks(r,e){var t=arguments.length>=2;return function(n){return n.pipe(Ts,tp(1),t?x6(e):C6(function(){return new Pm}))}}function k6(r,e,t,n){return Ar(function(i,o){var a;(!e||typeof e=="function")&&(a=e);var c=new Map,d=function(_){c.forEach(_),_(o)},h=function(_){return d(function(b){return b.error(_)})},u=0,p=!1,v=new dR(o,function(_){try{var b=r(_),C=c.get(b);if(!C){c.set(b,C=n?n():new Bn);var T=g(b,C);if(o.next(T),t){var S=xr(C,function(){C.complete(),S==null||S.unsubscribe()},void 0,void 0,function(){return c.delete(b)});v.add(Zn(t(T)).subscribe(S))}}C.next(a?a(_):_)}catch(A){h(A)}},function(){return d(function(_){return _.complete()})},h,function(){return c.clear()},function(){return p=!0,u===0});i.subscribe(v);function g(_,b){var C=new Tt(function(T){u++;var S=b.subscribe(T);return function(){S.unsubscribe(),--u===0&&p&&v.unsubscribe()}});return C.key=_,C}})}function FN(r){return r<=0?function(){return Tr}:Ar(function(e,t){var n=[];e.subscribe(xr(t,function(i){n.push(i),r<n.length&&n.shift()},function(){var i,o;try{for(var a=Di(n),c=a.next();!c.done;c=a.next()){var d=c.value;t.next(d)}}catch(h){i={error:h}}finally{try{c&&!c.done&&(o=a.return)&&o.call(a)}finally{if(i)throw i.error}}t.complete()},void 0,function(){n=null}))})}function Ti(r,e){var t=arguments.length>=2;return function(n){return n.pipe(Ts,FN(1),t?x6(e):C6(function(){return new Pm}))}}function PR(r,e,t){return Ar(function(n,i){var o=e;return AR(n,i,function(a,c){return r(o,a,c)},t,function(a){o=a},!1,void 0,function(){return o=null})})}function ig(){return Ar(function(r,e){var t,n=!1;r.subscribe(xr(e,function(i){var o=t;t=i,n&&e.next([o,i]),n=!0}))})}function Kc(){for(var r=[],e=0;e<arguments.length;e++)r[e]=arguments[e];return r.length?Ar(function(t,n){HN(vc([t],ys(r)))(n)}):Ts}function jN(r,e){return Ar(RR(r,e,arguments.length>=2,!0))}function Vf(r){r===void 0&&(r={});var e=r.connector,t=e===void 0?function(){return new Bn}:e,n=r.resetOnError,i=n===void 0?!0:n,o=r.resetOnComplete,a=o===void 0?!0:o,c=r.resetOnRefCountZero,d=c===void 0?!0:c;return function(h){var u,p,v,g=0,_=!1,b=!1,C=function(){p==null||p.unsubscribe(),p=void 0},T=function(){C(),u=v=void 0,_=b=!1},S=function(){var A=u;T(),A==null||A.unsubscribe()};return Ar(function(A,Z){g++,!b&&!_&&C();var B=v=v??t();Z.add(function(){g--,g===0&&!b&&!_&&(p=M3(S,d))}),B.subscribe(Z),!u&&g>0&&(u=new hf({next:function(U){return B.next(U)},error:function(U){b=!0,C(),p=M3(T,i,U),B.error(U)},complete:function(){_=!0,C(),p=M3(T,a),B.complete()}}),Zn(A).subscribe(u))})(h)}}function M3(r,e){for(var t=[],n=2;n<arguments.length;n++)t[n-2]=arguments[n];if(e===!0){r();return}if(e!==!1){var i=new hf({next:function(){i.unsubscribe(),r()}});return Zn(e.apply(void 0,vc([],ys(t)))).subscribe(i)}}function zN(r,e,t){var n,i=!1;return n=1/0,Vf({connector:function(){return new uR(n,e,t)},resetOnError:!0,resetOnComplete:!1,resetOnRefCountZero:i})}function Wt(r,e){return Ar(function(t,n){var i=null,o=0,a=!1,c=function(){return a&&!i&&n.complete()};t.subscribe(xr(n,function(d){i==null||i.unsubscribe();var h=0,u=o++;Zn(r(d,u)).subscribe(i=xr(n,function(p){return n.next(e?e(d,p,u,h++):p)},function(){i=null,c()}))},function(){a=!0,c()}))})}function ou(r){return Ar(function(e,t){Zn(r).subscribe(xr(t,function(){return t.complete()},eg)),!t.closed&&e.subscribe(t)})}function MR(r,e){return e===void 0&&(e=!1),Ar(function(t,n){var i=0;t.subscribe(xr(n,function(o){var a=r(o,i++);(a||e)&&n.next(o),!a&&n.complete()}))})}function Br(r,e,t){var n=gr(r)||e||t?{next:r,error:e,complete:t}:r;return n?Ar(function(i,o){var a;(a=n.subscribe)===null||a===void 0||a.call(n);var c=!0;i.subscribe(xr(o,function(d){var h;(h=n.next)===null||h===void 0||h.call(n,d),o.next(d)},function(){var d;c=!1,(d=n.complete)===null||d===void 0||d.call(n),o.complete()},function(d){var h;c=!1,(h=n.error)===null||h===void 0||h.call(n,d),o.error(d)},function(){var d,h;c&&((d=n.unsubscribe)===null||d===void 0||d.call(n)),(h=n.finalize)===null||h===void 0||h.call(n)}))}):Ts}function BN(r,e){return Ar(function(t,n){var i=e??{},o=i.leading,a=o===void 0?!0:o,c=i.trailing,d=c===void 0?!1:c,h=!1,u=null,p=null,v=!1,g=function(){p==null||p.unsubscribe(),p=null,d&&(C(),v&&n.complete())},_=function(){p=null,v&&n.complete()},b=function(T){return p=Zn(r(T)).subscribe(xr(n,g,_))},C=function(){if(h){h=!1;var T=u;u=null,n.next(T),!v&&b(T)}};t.subscribe(xr(n,function(T){h=!0,u=T,!(p&&!p.closed)&&(a?C():b(T))},function(){v=!0,!(d&&h&&p&&!p.closed)&&n.complete()}))})}function E6(r,e,t){e===void 0&&(e=ff);var n=w6(r,e);return BN(function(){return n},t)}function Up(){for(var r=[],e=0;e<arguments.length;e++)r[e]=arguments[e];var t=y6(r);return Ar(function(n,i){for(var o=r.length,a=new Array(o),c=r.map(function(){return!1}),d=!1,h=function(p){Zn(r[p]).subscribe(xr(i,function(v){a[p]=v,!d&&!c[p]&&(c[p]=!0,(d=c.every(Ts))&&(c=null))},eg))},u=0;u<o;u++)h(u);n.subscribe(xr(i,function(p){if(d){var v=vc([p],ys(a));i.next(t?t.apply(void 0,vc([],ys(v))):v)}}))})}var UN=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})},b0=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},Oh;const $R=(r,e,t)=>{var n;const i=typeof e=="string"?e.split("."):e,o=i.shift();return o&&((n=r[o])!==null&&n!==void 0||(r[o]={}),i.length?$R(r[o],i,t):Object.assign(r,{[o]:t})),r};class Mm{constructor(){Oh.set(this,{})}createConfig(e,t){return rt(this._createConfig(e,t))}createConfigAsync(e,t){return UN(this,void 0,void 0,function*(){return lr(this.createConfig(e,t))})}_set(e,t){b0(this,Oh,"f")[e]=t}_get(e){return b0(this,Oh,"f")[e]}_has(e){return e in b0(this,Oh,"f")}_createConfig(e,t){return rt(this._buildConfig(e,t)).pipe(Wt(n=>this._processConfig(n,e)))}_buildConfig(e,t){return rt(Object.entries(b0(this,Oh,"f"))).pipe(Jn(([n,i])=>rt(i(e)).pipe($e(o=>o!==void 0),me(o=>({target:n,value:o})),Vt(o=>(console.error(`Failed to execute config callback: ${i.name} for attribute: '${n}'`,o),Tr)))),Bp((n,{target:i,value:o})=>$R(n,i,o),t??{}))}_processConfig(e,t){return It(e)}}Oh=new WeakMap;var w0=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},EC=function(r,e,t,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?r!==e||!i:!e.has(r))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(r,t):i?i.value=t:e.set(r,t),t},mv,Zh;class OR{get version(){return w0(this,mv,"f")}constructor(e){mv.set(this,void 0),Zh.set(this,void 0);const{version:t}=e;EC(this,mv,new fs(t),"f"),EC(this,Zh,new ti,"f")}_addTeardown(e){return w0(this,Zh,"f").add(e),()=>w0(this,Zh,"f").remove(e)}dispose(){w0(this,Zh,"f").unsubscribe()}}mv=new WeakMap,Zh=new WeakMap;var Bs=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};class qN extends Error{constructor(){super("It was too slow"),this.name="RequiredModuleTimeoutError"}}class WN{constructor(e){this.logger=new iR("ModulesConfigurator"),this._configs=[],this._afterConfiguration=[],this._afterInit=[],this._modules=new Set(e)}get modules(){return[...this._modules]}configure(...e){for(const t of e)this.addConfig(t)}addConfig(e){const{module:t,afterConfig:n,afterInit:i,configure:o}=e;this._modules.add(t),o&&this._configs.push((a,c)=>o(a[t.name],c)),n&&this._afterConfiguration.push(a=>n(a[t.name])),i&&this._afterInit.push(a=>i(a[t.name]))}onConfigured(e){this._afterConfiguration.push(e)}onInitialized(e){this._afterInit.push(e)}initialize(e){return Bs(this,void 0,void 0,function*(){const t=yield this._configure(e),n=yield this._initialize(t,e);return yield this._postInitialize(n,e),Object.seal(Object.assign({},n,{dispose:()=>this.dispose(n)}))})}_configure(e){return Bs(this,void 0,void 0,function*(){const t=yield this._createConfig(e);return yield Promise.all(this._configs.map(n=>Promise.resolve(n(t,e)))),yield this._postConfigure(t),t})}_createConfig(e){const{modules:t,logger:n,_afterConfiguration:i,_afterInit:o}=this,a=rt(t).pipe(Jn(c=>Bs(this,void 0,void 0,function*(){var d;n.debug(`🛠 creating configurator ${n.formatModuleName(c)}`);try{const h=yield(d=c.configure)===null||d===void 0?void 0:d.call(c,e);return n.debug(`🛠 created configurator for ${n.formatModuleName(c)}`,h),{[c.name]:h}}catch(h){throw n.error(`🛠 Failed to created configurator for ${n.formatModuleName(c)}`,h),h}})),Bp((c,d)=>Object.assign(c,d),{onAfterConfiguration(c){i.push(c)},onAfterInit(c){o.push(c)}}));return lr(a)}_postConfigure(e){return Bs(this,void 0,void 0,function*(){const{modules:t,logger:n,_afterConfiguration:i}=this;if(yield Promise.allSettled(t.filter(o=>!!o.postConfigure).map(o=>Bs(this,void 0,void 0,function*(){var a;try{yield(a=o.postConfigure)===null||a===void 0?void 0:a.call(o,e),n.debug(`🏗📌 post configured ${n.formatModuleName(o)}`,o)}catch{n.warn(`🏗📌 post configure failed ${n.formatModuleName(o)}`)}}))),i.length)try{n.debug(`🏗📌 post configure hooks [${i.length}]`),yield Promise.allSettled(i.map(o=>Promise.resolve(o(e)))),n.debug("🏗📌 post configure hooks complete")}catch(o){n.warn("🏗📌 post configure hook failed",o)}})}_initialize(e,t){return Bs(this,void 0,void 0,function*(){const{modules:n,logger:i}=this,o=n.map(u=>u.name),a=new Df({}),c=u=>o.includes(u),d=(u,p=60)=>{if(!o.includes(u))throw i.error(`🚀⌛️ Cannot not require ${i.formatModuleName(String(u))} since module is not defined!`),Error(`cannot not require [${String(u)}] since module is not defined!`);return a.value[u]?(i.debug(`🚀⌛️ ${i.formatModuleName(String(u))} is initiated, skipping queue`),Promise.resolve(a.value[u])):(i.debug(`🚀⌛️ Awaiting init ${i.formatModuleName(String(u))}, timeout ${p}s`),zn(a.pipe($e(v=>!!v[u]),me(v=>v[u]),Gs({each:p*1e3,with:()=>kR(()=>new qN)}))))};rt(n).pipe(Jn(u=>{const p=u.name;return i.debug(`🚀 initializing ${i.formatModuleName(u)}`),rt(Promise.resolve(u.initialize({ref:t,config:e[p],requireInstance:d,hasModule:c}))).pipe(me(v=>{var g;if(!(v instanceof OR)&&!(v.version instanceof fs)){i.debug("🤷 module does not extends the [BaseModuleProvider] or exposes [SemanticVersion]");try{v.version=u.version instanceof fs?u.version:new fs((g=u.version)!==null&&g!==void 0?g:"0.0.0-unknown")}catch{i.error("🚨 failed to set module version")}}return i.debug(`🚀 initialized ${i.formatModuleName(u)}`),[p,v]}))})).subscribe({next:([u,p])=>{a.next(Object.assign(a.value,{[u]:p}))},complete:()=>a.complete()});const h=yield lr(a);return Object.seal(h),h})}_postInitialize(e,t){return Bs(this,void 0,void 0,function*(){const{modules:n,logger:i,_afterInit:o}=this,a=rt(n).pipe($e(c=>!!c.postInitialize),Br(c=>i.debug(`🚀📌 post initializing moule ${i.formatModuleName(c)}`)),Jn(c=>rt(c.postInitialize({ref:t,modules:e,instance:e[c.name]})).pipe(Br(()=>{i.debug(`🚀📌 post initialized moule ${i.formatModuleName(c)}`)}),Vt(d=>(i.warn(`🚀📌 post initialize failed moule ${i.formatModuleName(c)}`,d),Tr)))));if(yield new Promise((c,d)=>{a.subscribe({complete:()=>c(!0),error:d})}),o.length)try{i.debug(`🚀📌 post configure hooks [${o.length}]`),yield Promise.allSettled(o.map(c=>Promise.resolve(c(e)))),i.debug("🚀📌 post configure hooks complete")}catch(c){i.warn("🚀📌 post configure hook failed",c)}i.debug(`🎉 Modules initialized ${n.map(i.formatModuleName)}`,e),i.info("🟢 Modules initialized")})}dispose(e,t){return Bs(this,void 0,void 0,function*(){const{modules:n}=this;yield Promise.allSettled(n.filter(i=>!!i.dispose).map(i=>Bs(this,void 0,void 0,function*(){var o;yield(o=i.dispose)===null||o===void 0?void 0:o.call(i,{ref:t,modules:e,instance:e[i.name]})})))})}}var rp={exports:{}};rp.exports;var SC;function GN(){return SC||(SC=1,function(r,e){var t=200,n="__lodash_hash_undefined__",i=9007199254740991,o="[object Arguments]",a="[object Array]",c="[object Boolean]",d="[object Date]",h="[object Error]",u="[object Function]",p="[object GeneratorFunction]",v="[object Map]",g="[object Number]",_="[object Object]",b="[object Promise]",C="[object RegExp]",T="[object Set]",S="[object String]",A="[object Symbol]",Z="[object WeakMap]",B="[object ArrayBuffer]",U="[object DataView]",I="[object Float32Array]",Y="[object Float64Array]",le="[object Int8Array]",de="[object Int16Array]",Ee="[object Int32Array]",we="[object Uint8Array]",Ce="[object Uint8ClampedArray]",J="[object Uint16Array]",K="[object Uint32Array]",re=/[\\^$.*+?()[\]{}|]/g,q=/\w*$/,$=/^\[object .+?Constructor\]$/,O=/^(?:0|[1-9]\d*)$/,H={};H[o]=H[a]=H[B]=H[U]=H[c]=H[d]=H[I]=H[Y]=H[le]=H[de]=H[Ee]=H[v]=H[g]=H[_]=H[C]=H[T]=H[S]=H[A]=H[we]=H[Ce]=H[J]=H[K]=!0,H[h]=H[u]=H[Z]=!1;var P=typeof v0=="object"&&v0&&v0.Object===Object&&v0,N=typeof self=="object"&&self&&self.Object===Object&&self,ye=P||N||Function("return this")(),Pe=e&&!e.nodeType&&e,Ie=Pe&&!0&&r&&!r.nodeType&&r,Te=Ie&&Ie.exports===Pe;function Ke(M,te){return M.set(te[0],te[1]),M}function ot(M,te){return M.add(te),M}function _t(M,te){for(var ue=-1,at=M?M.length:0;++ue<at&&te(M[ue],ue,M)!==!1;);return M}function yr(M,te){for(var ue=-1,at=te.length,vn=M.length;++ue<at;)M[vn+ue]=te[ue];return M}function Wr(M,te,ue,at){for(var vn=-1,Rn=M?M.length:0;++vn<Rn;)ue=te(ue,M[vn],vn,M);return ue}function Rt(M,te){for(var ue=-1,at=Array(M);++ue<M;)at[ue]=te(ue);return at}function Un(M,te){return M==null?void 0:M[te]}function co(M){var te=!1;if(M!=null&&typeof M.toString!="function")try{te=!!(M+"")}catch{}return te}function ma(M){var te=-1,ue=Array(M.size);return M.forEach(function(at,vn){ue[++te]=[vn,at]}),ue}function qi(M,te){return function(ue){return M(te(ue))}}function Sc(M){var te=-1,ue=Array(M.size);return M.forEach(function(at){ue[++te]=at}),ue}var Uu=Array.prototype,Tc=Function.prototype,Po=Object.prototype,Mo=ye["__core-js_shared__"],Ac=function(){var M=/[^.]+$/.exec(Mo&&Mo.keys&&Mo.keys.IE_PROTO||"");return M?"Symbol(src)_1."+M:""}(),zl=Tc.toString,An=Po.hasOwnProperty,lo=Po.toString,Bl=RegExp("^"+zl.call(An).replace(re,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),Ba=Te?ye.Buffer:void 0,ai=ye.Symbol,Ii=ye.Uint8Array,Ua=qi(Object.getPrototypeOf,Object),$o=Object.create,e1=Po.propertyIsEnumerable,uo=Uu.splice,Ic=Object.getOwnPropertySymbols,qu=Ba?Ba.isBuffer:void 0,Rc=qi(Object.keys,Object),Ps=qt(ye,"DataView"),Oo=qt(ye,"Map"),Zo=qt(ye,"Promise"),qa=qt(ye,"Set"),Wi=qt(ye,"WeakMap"),si=qt(Object,"create"),Wu=li(Ps),Ul=li(Oo),Gu=li(Zo),ql=li(qa),Ms=li(Wi),va=ai?ai.prototype:void 0,Wl=va?va.valueOf:void 0;function Ri(M){var te=-1,ue=M?M.length:0;for(this.clear();++te<ue;){var at=M[te];this.set(at[0],at[1])}}function D(){this.__data__=si?si(null):{}}function Q(M){return this.has(M)&&delete this.__data__[M]}function ie(M){var te=this.__data__;if(si){var ue=te[M];return ue===n?void 0:ue}return An.call(te,M)?te[M]:void 0}function he(M){var te=this.__data__;return si?te[M]!==void 0:An.call(te,M)}function Oe(M,te){var ue=this.__data__;return ue[M]=si&&te===void 0?n:te,this}Ri.prototype.clear=D,Ri.prototype.delete=Q,Ri.prototype.get=ie,Ri.prototype.has=he,Ri.prototype.set=Oe;function Ve(M){var te=-1,ue=M?M.length:0;for(this.clear();++te<ue;){var at=M[te];this.set(at[0],at[1])}}function mt(){this.__data__=[]}function Ge(M){var te=this.__data__,ue=ya(te,M);if(ue<0)return!1;var at=te.length-1;return ue==at?te.pop():uo.call(te,ue,1),!0}function Ye(M){var te=this.__data__,ue=ya(te,M);return ue<0?void 0:te[ue][1]}function je(M){return ya(this.__data__,M)>-1}function Je(M,te){var ue=this.__data__,at=ya(ue,M);return at<0?ue.push([M,te]):ue[at][1]=te,this}Ve.prototype.clear=mt,Ve.prototype.delete=Ge,Ve.prototype.get=Ye,Ve.prototype.has=je,Ve.prototype.set=Je;function wt(M){var te=-1,ue=M?M.length:0;for(this.clear();++te<ue;){var at=M[te];this.set(at[0],at[1])}}function Ht(){this.__data__={hash:new Ri,map:new(Oo||Ve),string:new Ri}}function mn(M){return Mc(this,M).delete(M)}function ar(M){return Mc(this,M).get(M)}function Ut(M){return Mc(this,M).has(M)}function Er(M,te){return Mc(this,M).set(M,te),this}wt.prototype.clear=Ht,wt.prototype.delete=mn,wt.prototype.get=ar,wt.prototype.has=Ut,wt.prototype.set=Er;function ci(M){this.__data__=new Ve(M)}function $s(){this.__data__=new Ve}function ho(M){return this.__data__.delete(M)}function Kt(M){return this.__data__.get(M)}function Gl(M){return this.__data__.has(M)}function ga(M,te){var ue=this.__data__;if(ue instanceof Ve){var at=ue.__data__;if(!Oo||at.length<t-1)return at.push([M,te]),this;ue=this.__data__=new wt(at)}return ue.set(M,te),this}ci.prototype.clear=$s,ci.prototype.delete=ho,ci.prototype.get=Kt,ci.prototype.has=Gl,ci.prototype.set=ga;function Lo(M,te){var ue=No(M)||Ql(M)?Rt(M.length,String):[],at=ue.length,vn=!!at;for(var Rn in M)An.call(M,Rn)&&!(vn&&(Rn=="length"||g2(Rn,at)))&&ue.push(Rn);return ue}function Ho(M,te,ue){var at=M[te];(!(An.call(M,te)&&$c(at,ue))||ue===void 0&&!(te in M))&&(M[te]=ue)}function ya(M,te){for(var ue=M.length;ue--;)if($c(M[ue][0],te))return ue;return-1}function jt(M,te){return M&&Xu(te,a1(te),M)}function sr(M,te,ue,at,vn,Rn,fo){var qn;if(at&&(qn=Rn?at(M,vn,Rn,fo):at(M)),qn!==void 0)return qn;if(!Zs(M))return M;var ba=No(M);if(ba){if(qn=i1(M),!te)return p2(M,qn)}else{var Ya=Ga(M),td=Ya==u||Ya==p;if(Xl(M))return t1(M,te);if(Ya==_||Ya==o||td&&!Rn){if(co(M))return Rn?M:{};if(qn=m2(td?{}:M),!te)return Yl(M,jt(qn,M))}else{if(!H[Ya])return Rn?M:{};qn=v2(M,Ya,sr,te)}}fo||(fo=new ci);var s1=fo.get(M);if(s1)return s1;if(fo.set(M,qn),!ba)var rd=ue?c5(M):a1(M);return _t(rd||M,function(Oc,nd){rd&&(nd=Oc,Oc=M[nd]),Ho(qn,nd,sr(Oc,te,ue,at,nd,M,fo))}),qn}function In(M){return Zs(M)?$o(M):{}}function Os(M,te,ue){var at=te(M);return No(M)?at:yr(at,ue(M))}function Yt(M){return lo.call(M)}function Wa(M){if(!Zs(M)||Ju(M))return!1;var te=b2(M)||co(M)?Bl:$;return te.test(li(M))}function Ku(M){if(!_a(M))return Rc(M);var te=[];for(var ue in Object(M))An.call(M,ue)&&ue!="constructor"&&te.push(ue);return te}function t1(M,te){if(te)return M.slice();var ue=new M.constructor(M.length);return M.copy(ue),ue}function Pc(M){var te=new M.constructor(M.byteLength);return new Ii(te).set(new Ii(M)),te}function Yu(M,te){var ue=te?Pc(M.buffer):M.buffer;return new M.constructor(ue,M.byteOffset,M.byteLength)}function Kl(M,te,ue){var at=te?ue(ma(M),!0):ma(M);return Wr(at,Ke,new M.constructor)}function Qu(M){var te=new M.constructor(M.source,q.exec(M));return te.lastIndex=M.lastIndex,te}function a5(M,te,ue){var at=te?ue(Sc(M),!0):Sc(M);return Wr(at,ot,new M.constructor)}function s5(M){return Wl?Object(Wl.call(M)):{}}function r1(M,te){var ue=te?Pc(M.buffer):M.buffer;return new M.constructor(ue,M.byteOffset,M.length)}function p2(M,te){var ue=-1,at=M.length;for(te||(te=Array(at));++ue<at;)te[ue]=M[ue];return te}function Xu(M,te,ue,at){ue||(ue={});for(var vn=-1,Rn=te.length;++vn<Rn;){var fo=te[vn],qn=void 0;Ho(ue,fo,qn===void 0?M[fo]:qn)}return ue}function Yl(M,te){return Xu(M,n1(M),te)}function c5(M){return Os(M,a1,n1)}function Mc(M,te){var ue=M.__data__;return o1(te)?ue[typeof te=="string"?"string":"hash"]:ue.map}function qt(M,te){var ue=Un(M,te);return Wa(ue)?ue:void 0}var n1=Ic?qi(Ic,Object):Jl,Ga=Yt;(Ps&&Ga(new Ps(new ArrayBuffer(1)))!=U||Oo&&Ga(new Oo)!=v||Zo&&Ga(Zo.resolve())!=b||qa&&Ga(new qa)!=T||Wi&&Ga(new Wi)!=Z)&&(Ga=function(M){var te=lo.call(M),ue=te==_?M.constructor:void 0,at=ue?li(ue):void 0;if(at)switch(at){case Wu:return U;case Ul:return v;case Gu:return b;case ql:return T;case Ms:return Z}return te});function i1(M){var te=M.length,ue=M.constructor(te);return te&&typeof M[0]=="string"&&An.call(M,"index")&&(ue.index=M.index,ue.input=M.input),ue}function m2(M){return typeof M.constructor=="function"&&!_a(M)?In(Ua(M)):{}}function v2(M,te,ue,at){var vn=M.constructor;switch(te){case B:return Pc(M);case c:case d:return new vn(+M);case U:return Yu(M,at);case I:case Y:case le:case de:case Ee:case we:case Ce:case J:case K:return r1(M,at);case v:return Kl(M,at,ue);case g:case S:return new vn(M);case C:return Qu(M);case T:return a5(M,at,ue);case A:return s5(M)}}function g2(M,te){return te=te??i,!!te&&(typeof M=="number"||O.test(M))&&M>-1&&M%1==0&&M<te}function o1(M){var te=typeof M;return te=="string"||te=="number"||te=="symbol"||te=="boolean"?M!=="__proto__":M===null}function Ju(M){return!!Ac&&Ac in M}function _a(M){var te=M&&M.constructor,ue=typeof te=="function"&&te.prototype||Po;return M===ue}function li(M){if(M!=null){try{return zl.call(M)}catch{}try{return M+""}catch{}}return""}function Ka(M){return sr(M,!0,!0)}function $c(M,te){return M===te||M!==M&&te!==te}function Ql(M){return _2(M)&&An.call(M,"callee")&&(!e1.call(M,"callee")||lo.call(M)==o)}var No=Array.isArray;function y2(M){return M!=null&&w2(M.length)&&!b2(M)}function _2(M){return x2(M)&&y2(M)}var Xl=qu||ed;function b2(M){var te=Zs(M)?lo.call(M):"";return te==u||te==p}function w2(M){return typeof M=="number"&&M>-1&&M%1==0&&M<=i}function Zs(M){var te=typeof M;return!!M&&(te=="object"||te=="function")}function x2(M){return!!M&&typeof M=="object"}function a1(M){return y2(M)?Lo(M):Ku(M)}function Jl(){return[]}function ed(){return!1}r.exports=Ka}(rp,rp.exports)),rp.exports}var KN=GN();const YN=Hu(KN);var Us=function(r,e,t,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?r!==e||!i:!e.has(r))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(r,t):i?i.value=t:e.set(r,t),t},Uo=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},Rd,vv,gv,np,yv,ip,op,wb;class ZR{constructor(e,t){this.__type=e,Rd.set(this,void 0),vv.set(this,void 0),gv.set(this,void 0),np.set(this,!1),yv.set(this,void 0),ip.set(this,void 0),op.set(this,void 0),wb.set(this,Date.now()),Us(this,Rd,t.detail,"f"),Us(this,vv,YN(t.detail),"f"),Us(this,ip,!!t.mutableDetails,"f"),Us(this,gv,t.source,"f"),Us(this,yv,!!t.cancelable,"f"),Us(this,op,t.canBubble===void 0?!0:t.canBubble,"f")}get bubbles(){return Uo(this,op,"f")&&!Uo(this,np,"f")}get created(){return Uo(this,wb,"f")}get cancelable(){return Uo(this,yv,"f")}get canceled(){return Uo(this,np,"f")}get detail(){return Uo(this,Rd,"f")}get originalDetail(){return Uo(this,vv,"f")}get source(){return Uo(this,gv,"f")}get type(){return this.__type}get allowEventDetailsMutation(){return Uo(this,ip,"f")}preventDefault(){this.cancelable&&Us(this,np,!0,"f")}stopPropagation(){Us(this,op,!1,"f")}updateDetails(e){if(!Uo(this,ip,"f"))throw new Error("Event details are not mutable");const t=e(Uo(this,Rd,"f"));Us(this,Rd,t===void 0?Uo(this,Rd,"f"):t,"f")}}Rd=new WeakMap,vv=new WeakMap,gv=new WeakMap,np=new WeakMap,yv=new WeakMap,ip=new WeakMap,op=new WeakMap,wb=new WeakMap;var QN=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};class XN{constructor({onDispatch:e,onBubble:t}){this.__onDispatch=e,this.__onBubble=t}dispatch(e,t){return QN(this,void 0,void 0,function*(){var n,i;try{yield(n=this.__onDispatch)===null||n===void 0?void 0:n.call(this,e)}catch(a){throw a}const o=e;if(!o.dispatcher)o.dispatcher=this;else if(o.dispatcher===this)throw Error("loop detected");for(const a of t)e.cancelable?e.canceled||(yield Promise.resolve(a(e))):a(e);if(e.bubbles)try{yield(i=this.__onBubble)===null||i===void 0?void 0:i.call(this,e)}catch(a){throw a}})}}var TC=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};class JN extends Tt{get event$(){return this.__event$.asObservable()}get closed(){return this.__event$.closed}constructor(e){super(t=>{this.__event$.subscribe(t)}),this.__listeners=[],this.__event$=new Bn,this.__dispatcher=new XN({onDispatch:e.onDispatch,onBubble:e.onBubble})}addEventListener(e,t){if(this.closed)throw Error("Cannot listen to events when provider is closed!");const n={type:e,handler:t};return this.__listeners.push(n),()=>{const i=this.__listeners.indexOf(n);0<=i&&this.__listeners.splice(i,1)}}dispatchEvent(e,t){return TC(this,void 0,void 0,function*(){if(typeof e=="string"){if(!t)throw Error("invalid arguments, missing [FrameworkEventInit]");return this._dispatchEvent(new ZR(e,t))}else return this._dispatchEvent(e)})}_dispatchEvent(e){return TC(this,void 0,void 0,function*(){if(this.closed)throw Error("Cannot dispatch events when provider is closed!");this.__event$.next(e);try{const t=this.__listeners.filter(n=>n.type===e.type).map(({handler:n})=>n);yield this.__dispatcher.dispatch(e,t)}catch(t){throw t}return e})}dispose(){this.__listeners=[],this.__event$.complete()}}var AC=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};const eD="event",tD={name:eD,configure:r=>{const e={},t=r==null?void 0:r.event;return t&&(e.onBubble=n=>AC(void 0,void 0,void 0,function*(){yield t.dispatchEvent(n)})),e},initialize:({config:r})=>new JN(r),postInitialize:r=>AC(void 0,[r],void 0,function*({instance:e,modules:t}){e.dispatchEvent("onModulesLoaded",{detail:t,source:e})}),dispose({instance:r}){r.dispose()}};class LR{get operators(){return this._operators}constructor(e){e&&"operators"in e?this._operators=Object.assign({},e.operators):this._operators=e??{}}add(e,t){if(Object.keys(this._operators).includes(e))throw Error(`Operator [${e}] already defined`);return this.set(e,t)}set(e,t){return this._operators[e]=t,this}remove(e){return delete this._operators[e],this}get(e){return this._operators[e]}process(e){return Object.values(this._operators).length?rt(Object.values(this._operators)).pipe(PR((n,i)=>Promise.resolve(i(n)).then(o=>o??n),e,1),Ti()):It(e)}}const rD=(r,e)=>t=>{const n=new Headers(t.headers);return n.append(r,e),Object.assign(Object.assign({},t),{headers:n})};class HR extends LR{setHeader(e,t){const n=rD(e,t);return this.set("header-"+e,n)}}class nD extends LR{}var Qt;(function(r){r.assertEqual=i=>i;function e(i){}r.assertIs=e;function t(i){throw new Error}r.assertNever=t,r.arrayToEnum=i=>{const o={};for(const a of i)o[a]=a;return o},r.getValidEnumValues=i=>{const o=r.objectKeys(i).filter(c=>typeof i[i[c]]!="number"),a={};for(const c of o)a[c]=i[c];return r.objectValues(a)},r.objectValues=i=>r.objectKeys(i).map(function(o){return i[o]}),r.objectKeys=typeof Object.keys=="function"?i=>Object.keys(i):i=>{const o=[];for(const a in i)Object.prototype.hasOwnProperty.call(i,a)&&o.push(a);return o},r.find=(i,o)=>{for(const a of i)if(o(a))return a},r.isInteger=typeof Number.isInteger=="function"?i=>Number.isInteger(i):i=>typeof i=="number"&&isFinite(i)&&Math.floor(i)===i;function n(i,o=" | "){return i.map(a=>typeof a=="string"?`'${a}'`:a).join(o)}r.joinValues=n,r.jsonStringifyReplacer=(i,o)=>typeof o=="bigint"?o.toString():o})(Qt||(Qt={}));var xb;(function(r){r.mergeShapes=(e,t)=>({...e,...t})})(xb||(xb={}));const Ue=Qt.arrayToEnum(["string","nan","number","integer","float","boolean","date","bigint","symbol","function","undefined","null","array","object","unknown","promise","void","never","map","set"]),rc=r=>{switch(typeof r){case"undefined":return Ue.undefined;case"string":return Ue.string;case"number":return isNaN(r)?Ue.nan:Ue.number;case"boolean":return Ue.boolean;case"function":return Ue.function;case"bigint":return Ue.bigint;case"symbol":return Ue.symbol;case"object":return Array.isArray(r)?Ue.array:r===null?Ue.null:r.then&&typeof r.then=="function"&&r.catch&&typeof r.catch=="function"?Ue.promise:typeof Map<"u"&&r instanceof Map?Ue.map:typeof Set<"u"&&r instanceof Set?Ue.set:typeof Date<"u"&&r instanceof Date?Ue.date:Ue.object;default:return Ue.unknown}},be=Qt.arrayToEnum(["invalid_type","invalid_literal","custom","invalid_union","invalid_union_discriminator","invalid_enum_value","unrecognized_keys","invalid_arguments","invalid_return_type","invalid_date","invalid_string","too_small","too_big","invalid_intersection_types","not_multiple_of","not_finite"]),iD=r=>JSON.stringify(r,null,2).replace(/"([^"]+)":/g,"$1:");class ko extends Error{get errors(){return this.issues}constructor(e){super(),this.issues=[],this.addIssue=n=>{this.issues=[...this.issues,n]},this.addIssues=(n=[])=>{this.issues=[...this.issues,...n]};const t=new.target.prototype;Object.setPrototypeOf?Object.setPrototypeOf(this,t):this.__proto__=t,this.name="ZodError",this.issues=e}format(e){const t=e||function(o){return o.message},n={_errors:[]},i=o=>{for(const a of o.issues)if(a.code==="invalid_union")a.unionErrors.map(i);else if(a.code==="invalid_return_type")i(a.returnTypeError);else if(a.code==="invalid_arguments")i(a.argumentsError);else if(a.path.length===0)n._errors.push(t(a));else{let c=n,d=0;for(;d<a.path.length;){const h=a.path[d];d===a.path.length-1?(c[h]=c[h]||{_errors:[]},c[h]._errors.push(t(a))):c[h]=c[h]||{_errors:[]},c=c[h],d++}}};return i(this),n}static assert(e){if(!(e instanceof ko))throw new Error(`Not a ZodError: ${e}`)}toString(){return this.message}get message(){return JSON.stringify(this.issues,Qt.jsonStringifyReplacer,2)}get isEmpty(){return this.issues.length===0}flatten(e=t=>t.message){const t={},n=[];for(const i of this.issues)i.path.length>0?(t[i.path[0]]=t[i.path[0]]||[],t[i.path[0]].push(e(i))):n.push(e(i));return{formErrors:n,fieldErrors:t}}get formErrors(){return this.flatten()}}ko.create=r=>new ko(r);const pf=(r,e)=>{let t;switch(r.code){case be.invalid_type:r.received===Ue.undefined?t="Required":t=`Expected ${r.expected}, received ${r.received}`;break;case be.invalid_literal:t=`Invalid literal value, expected ${JSON.stringify(r.expected,Qt.jsonStringifyReplacer)}`;break;case be.unrecognized_keys:t=`Unrecognized key(s) in object: ${Qt.joinValues(r.keys,", ")}`;break;case be.invalid_union:t="Invalid input";break;case be.invalid_union_discriminator:t=`Invalid discriminator value. Expected ${Qt.joinValues(r.options)}`;break;case be.invalid_enum_value:t=`Invalid enum value. Expected ${Qt.joinValues(r.options)}, received '${r.received}'`;break;case be.invalid_arguments:t="Invalid function arguments";break;case be.invalid_return_type:t="Invalid function return type";break;case be.invalid_date:t="Invalid date";break;case be.invalid_string:typeof r.validation=="object"?"includes"in r.validation?(t=`Invalid input: must include "${r.validation.includes}"`,typeof r.validation.position=="number"&&(t=`${t} at one or more positions greater than or equal to ${r.validation.position}`)):"startsWith"in r.validation?t=`Invalid input: must start with "${r.validation.startsWith}"`:"endsWith"in r.validation?t=`Invalid input: must end with "${r.validation.endsWith}"`:Qt.assertNever(r.validation):r.validation!=="regex"?t=`Invalid ${r.validation}`:t="Invalid";break;case be.too_small:r.type==="array"?t=`Array must contain ${r.exact?"exactly":r.inclusive?"at least":"more than"} ${r.minimum} element(s)`:r.type==="string"?t=`String must contain ${r.exact?"exactly":r.inclusive?"at least":"over"} ${r.minimum} character(s)`:r.type==="number"?t=`Number must be ${r.exact?"exactly equal to ":r.inclusive?"greater than or equal to ":"greater than "}${r.minimum}`:r.type==="date"?t=`Date must be ${r.exact?"exactly equal to ":r.inclusive?"greater than or equal to ":"greater than "}${new Date(Number(r.minimum))}`:t="Invalid input";break;case be.too_big:r.type==="array"?t=`Array must contain ${r.exact?"exactly":r.inclusive?"at most":"less than"} ${r.maximum} element(s)`:r.type==="string"?t=`String must contain ${r.exact?"exactly":r.inclusive?"at most":"under"} ${r.maximum} character(s)`:r.type==="number"?t=`Number must be ${r.exact?"exactly":r.inclusive?"less than or equal to":"less than"} ${r.maximum}`:r.type==="bigint"?t=`BigInt must be ${r.exact?"exactly":r.inclusive?"less than or equal to":"less than"} ${r.maximum}`:r.type==="date"?t=`Date must be ${r.exact?"exactly":r.inclusive?"smaller than or equal to":"smaller than"} ${new Date(Number(r.maximum))}`:t="Invalid input";break;case be.custom:t="Invalid input";break;case be.invalid_intersection_types:t="Intersection results could not be merged";break;case be.not_multiple_of:t=`Number must be a multiple of ${r.multipleOf}`;break;case be.not_finite:t="Number must be finite";break;default:t=e.defaultError,Qt.assertNever(r)}return{message:t}};let NR=pf;function oD(r){NR=r}function og(){return NR}const ag=r=>{const{data:e,path:t,errorMaps:n,issueData:i}=r,o=[...t,...i.path||[]],a={...i,path:o};if(i.message!==void 0)return{...i,path:o,message:i.message};let c="";const d=n.filter(h=>!!h).slice().reverse();for(const h of d)c=h(a,{data:e,defaultError:c}).message;return{...i,path:o,message:c}},aD=[];function Le(r,e){const t=og(),n=ag({issueData:e,data:r.data,path:r.path,errorMaps:[r.common.contextualErrorMap,r.schemaErrorMap,t,t===pf?void 0:pf].filter(i=>!!i)});r.common.issues.push(n)}class ki{constructor(){this.value="valid"}dirty(){this.value==="valid"&&(this.value="dirty")}abort(){this.value!=="aborted"&&(this.value="aborted")}static mergeArray(e,t){const n=[];for(const i of t){if(i.status==="aborted")return bt;i.status==="dirty"&&e.dirty(),n.push(i.value)}return{status:e.value,value:n}}static async mergeObjectAsync(e,t){const n=[];for(const i of t){const o=await i.key,a=await i.value;n.push({key:o,value:a})}return ki.mergeObjectSync(e,n)}static mergeObjectSync(e,t){const n={};for(const i of t){const{key:o,value:a}=i;if(o.status==="aborted"||a.status==="aborted")return bt;o.status==="dirty"&&e.dirty(),a.status==="dirty"&&e.dirty(),o.value!=="__proto__"&&(typeof a.value<"u"||i.alwaysSet)&&(n[o.value]=a.value)}return{status:e.value,value:n}}}const bt=Object.freeze({status:"aborted"}),Wh=r=>({status:"dirty",value:r}),Fi=r=>({status:"valid",value:r}),Cb=r=>r.status==="aborted",kb=r=>r.status==="dirty",_u=r=>r.status==="valid",qp=r=>typeof Promise<"u"&&r instanceof Promise;function sg(r,e,t,n){if(typeof e=="function"?r!==e||!0:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return e.get(r)}function DR(r,e,t,n,i){if(typeof e=="function"?r!==e||!0:!e.has(r))throw new TypeError("Cannot write private member to an object whose class did not declare it");return e.set(r,t),t}var ct;(function(r){r.errToObj=e=>typeof e=="string"?{message:e}:e||{},r.toString=e=>typeof e=="string"?e:e==null?void 0:e.message})(ct||(ct={}));var ap,sp;class bs{constructor(e,t,n,i){this._cachedPath=[],this.parent=e,this.data=t,this._path=n,this._key=i}get path(){return this._cachedPath.length||(this._key instanceof Array?this._cachedPath.push(...this._path,...this._key):this._cachedPath.push(...this._path,this._key)),this._cachedPath}}const IC=(r,e)=>{if(_u(e))return{success:!0,data:e.value};if(!r.common.issues.length)throw new Error("Validation failed but no issues detected.");return{success:!1,get error(){if(this._error)return this._error;const t=new ko(r.common.issues);return this._error=t,this._error}}};function Pt(r){if(!r)return{};const{errorMap:e,invalid_type_error:t,required_error:n,description:i}=r;if(e&&(t||n))throw new Error(`Can't use "invalid_type_error" or "required_error" in conjunction with custom error map.`);return e?{errorMap:e,description:i}:{errorMap:(a,c)=>{var d,h;const{message:u}=r;return a.code==="invalid_enum_value"?{message:u??c.defaultError}:typeof c.data>"u"?{message:(d=u??n)!==null&&d!==void 0?d:c.defaultError}:a.code!=="invalid_type"?{message:c.defaultError}:{message:(h=u??t)!==null&&h!==void 0?h:c.defaultError}},description:i}}class Lt{get description(){return this._def.description}_getType(e){return rc(e.data)}_getOrReturnCtx(e,t){return t||{common:e.parent.common,data:e.data,parsedType:rc(e.data),schemaErrorMap:this._def.errorMap,path:e.path,parent:e.parent}}_processInputParams(e){return{status:new ki,ctx:{common:e.parent.common,data:e.data,parsedType:rc(e.data),schemaErrorMap:this._def.errorMap,path:e.path,parent:e.parent}}}_parseSync(e){const t=this._parse(e);if(qp(t))throw new Error("Synchronous parse encountered promise.");return t}_parseAsync(e){const t=this._parse(e);return Promise.resolve(t)}parse(e,t){const n=this.safeParse(e,t);if(n.success)return n.data;throw n.error}safeParse(e,t){var n;const i={common:{issues:[],async:(n=t==null?void 0:t.async)!==null&&n!==void 0?n:!1,contextualErrorMap:t==null?void 0:t.errorMap},path:(t==null?void 0:t.path)||[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:rc(e)},o=this._parseSync({data:e,path:i.path,parent:i});return IC(i,o)}"~validate"(e){var t,n;const i={common:{issues:[],async:!!this["~standard"].async},path:[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:rc(e)};if(!this["~standard"].async)try{const o=this._parseSync({data:e,path:[],parent:i});return _u(o)?{value:o.value}:{issues:i.common.issues}}catch(o){!((n=(t=o==null?void 0:o.message)===null||t===void 0?void 0:t.toLowerCase())===null||n===void 0)&&n.includes("encountered")&&(this["~standard"].async=!0),i.common={issues:[],async:!0}}return this._parseAsync({data:e,path:[],parent:i}).then(o=>_u(o)?{value:o.value}:{issues:i.common.issues})}async parseAsync(e,t){const n=await this.safeParseAsync(e,t);if(n.success)return n.data;throw n.error}async safeParseAsync(e,t){const n={common:{issues:[],contextualErrorMap:t==null?void 0:t.errorMap,async:!0},path:(t==null?void 0:t.path)||[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:rc(e)},i=this._parse({data:e,path:n.path,parent:n}),o=await(qp(i)?i:Promise.resolve(i));return IC(n,o)}refine(e,t){const n=i=>typeof t=="string"||typeof t>"u"?{message:t}:typeof t=="function"?t(i):t;return this._refinement((i,o)=>{const a=e(i),c=()=>o.addIssue({code:be.custom,...n(i)});return typeof Promise<"u"&&a instanceof Promise?a.then(d=>d?!0:(c(),!1)):a?!0:(c(),!1)})}refinement(e,t){return this._refinement((n,i)=>e(n)?!0:(i.addIssue(typeof t=="function"?t(n,i):t),!1))}_refinement(e){return new Na({schema:this,typeName:yt.ZodEffects,effect:{type:"refinement",refinement:e}})}superRefine(e){return this._refinement(e)}constructor(e){this.spa=this.safeParseAsync,this._def=e,this.parse=this.parse.bind(this),this.safeParse=this.safeParse.bind(this),this.parseAsync=this.parseAsync.bind(this),this.safeParseAsync=this.safeParseAsync.bind(this),this.spa=this.spa.bind(this),this.refine=this.refine.bind(this),this.refinement=this.refinement.bind(this),this.superRefine=this.superRefine.bind(this),this.optional=this.optional.bind(this),this.nullable=this.nullable.bind(this),this.nullish=this.nullish.bind(this),this.array=this.array.bind(this),this.promise=this.promise.bind(this),this.or=this.or.bind(this),this.and=this.and.bind(this),this.transform=this.transform.bind(this),this.brand=this.brand.bind(this),this.default=this.default.bind(this),this.catch=this.catch.bind(this),this.describe=this.describe.bind(this),this.pipe=this.pipe.bind(this),this.readonly=this.readonly.bind(this),this.isNullable=this.isNullable.bind(this),this.isOptional=this.isOptional.bind(this),this["~standard"]={version:1,vendor:"zod",validate:t=>this["~validate"](t)}}optional(){return ps.create(this,this._def)}nullable(){return Pl.create(this,this._def)}nullish(){return this.nullable().optional()}array(){return Oa.create(this)}promise(){return vf.create(this,this._def)}or(e){return Yp.create([this,e],this._def)}and(e){return Qp.create(this,e,this._def)}transform(e){return new Na({...Pt(this._def),schema:this,typeName:yt.ZodEffects,effect:{type:"transform",transform:e}})}default(e){const t=typeof e=="function"?e:()=>e;return new rm({...Pt(this._def),innerType:this,defaultValue:t,typeName:yt.ZodDefault})}brand(){return new S6({typeName:yt.ZodBranded,type:this,...Pt(this._def)})}catch(e){const t=typeof e=="function"?e:()=>e;return new nm({...Pt(this._def),innerType:this,catchValue:t,typeName:yt.ZodCatch})}describe(e){const t=this.constructor;return new t({...this._def,description:e})}pipe(e){return $m.create(this,e)}readonly(){return im.create(this)}isOptional(){return this.safeParse(void 0).success}isNullable(){return this.safeParse(null).success}}const sD=/^c[^\s-]{8,}$/i,cD=/^[0-9a-z]+$/,lD=/^[0-9A-HJKMNP-TV-Z]{26}$/i,dD=/^[0-9a-fA-F]{8}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{12}$/i,uD=/^[a-z0-9_-]{21}$/i,hD=/^[A-Za-z0-9-_]+\.[A-Za-z0-9-_]+\.[A-Za-z0-9-_]*$/,fD=/^[-+]?P(?!$)(?:(?:[-+]?\d+Y)|(?:[-+]?\d+[.,]\d+Y$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:(?:[-+]?\d+W)|(?:[-+]?\d+[.,]\d+W$))?(?:(?:[-+]?\d+D)|(?:[-+]?\d+[.,]\d+D$))?(?:T(?=[\d+-])(?:(?:[-+]?\d+H)|(?:[-+]?\d+[.,]\d+H$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:[-+]?\d+(?:[.,]\d+)?S)?)??$/,pD=/^(?!\.)(?!.*\.\.)([A-Z0-9_'+\-\.]*)[A-Z0-9_+-]@([A-Z0-9][A-Z0-9\-]*\.)+[A-Z]{2,}$/i,mD="^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$";let $3;const vD=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])$/,gD=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\/(3[0-2]|[12]?[0-9])$/,yD=/^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))$/,_D=/^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))\/(12[0-8]|1[01][0-9]|[1-9]?[0-9])$/,bD=/^([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))?$/,wD=/^([0-9a-zA-Z-_]{4})*(([0-9a-zA-Z-_]{2}(==)?)|([0-9a-zA-Z-_]{3}(=)?))?$/,VR="((\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-((0[13578]|1[02])-(0[1-9]|[12]\\d|3[01])|(0[469]|11)-(0[1-9]|[12]\\d|30)|(02)-(0[1-9]|1\\d|2[0-8])))",xD=new RegExp(`^${VR}$`);function FR(r){let e="([01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d";return r.precision?e=`${e}\\.\\d{${r.precision}}`:r.precision==null&&(e=`${e}(\\.\\d+)?`),e}function CD(r){return new RegExp(`^${FR(r)}$`)}function jR(r){let e=`${VR}T${FR(r)}`;const t=[];return t.push(r.local?"Z?":"Z"),r.offset&&t.push("([+-]\\d{2}:?\\d{2})"),e=`${e}(${t.join("|")})`,new RegExp(`^${e}$`)}function kD(r,e){return!!((e==="v4"||!e)&&vD.test(r)||(e==="v6"||!e)&&yD.test(r))}function ED(r,e){if(!hD.test(r))return!1;try{const[t]=r.split("."),n=t.replace(/-/g,"+").replace(/_/g,"/").padEnd(t.length+(4-t.length%4)%4,"="),i=JSON.parse(atob(n));return!(typeof i!="object"||i===null||!i.typ||!i.alg||e&&i.alg!==e)}catch{return!1}}function SD(r,e){return!!((e==="v4"||!e)&&gD.test(r)||(e==="v6"||!e)&&_D.test(r))}class Pa extends Lt{_parse(e){if(this._def.coerce&&(e.data=String(e.data)),this._getType(e)!==Ue.string){const o=this._getOrReturnCtx(e);return Le(o,{code:be.invalid_type,expected:Ue.string,received:o.parsedType}),bt}const n=new ki;let i;for(const o of this._def.checks)if(o.kind==="min")e.data.length<o.value&&(i=this._getOrReturnCtx(e,i),Le(i,{code:be.too_small,minimum:o.value,type:"string",inclusive:!0,exact:!1,message:o.message}),n.dirty());else if(o.kind==="max")e.data.length>o.value&&(i=this._getOrReturnCtx(e,i),Le(i,{code:be.too_big,maximum:o.value,type:"string",inclusive:!0,exact:!1,message:o.message}),n.dirty());else if(o.kind==="length"){const a=e.data.length>o.value,c=e.data.length<o.value;(a||c)&&(i=this._getOrReturnCtx(e,i),a?Le(i,{code:be.too_big,maximum:o.value,type:"string",inclusive:!0,exact:!0,message:o.message}):c&&Le(i,{code:be.too_small,minimum:o.value,type:"string",inclusive:!0,exact:!0,message:o.message}),n.dirty())}else if(o.kind==="email")pD.test(e.data)||(i=this._getOrReturnCtx(e,i),Le(i,{validation:"email",code:be.invalid_string,message:o.message}),n.dirty());else if(o.kind==="emoji")$3||($3=new RegExp(mD,"u")),$3.test(e.data)||(i=this._getOrReturnCtx(e,i),Le(i,{validation:"emoji",code:be.invalid_string,message:o.message}),n.dirty());else if(o.kind==="uuid")dD.test(e.data)||(i=this._getOrReturnCtx(e,i),Le(i,{validation:"uuid",code:be.invalid_string,message:o.message}),n.dirty());else if(o.kind==="nanoid")uD.test(e.data)||(i=this._getOrReturnCtx(e,i),Le(i,{validation:"nanoid",code:be.invalid_string,message:o.message}),n.dirty());else if(o.kind==="cuid")sD.test(e.data)||(i=this._getOrReturnCtx(e,i),Le(i,{validation:"cuid",code:be.invalid_string,message:o.message}),n.dirty());else if(o.kind==="cuid2")cD.test(e.data)||(i=this._getOrReturnCtx(e,i),Le(i,{validation:"cuid2",code:be.invalid_string,message:o.message}),n.dirty());else if(o.kind==="ulid")lD.test(e.data)||(i=this._getOrReturnCtx(e,i),Le(i,{validation:"ulid",code:be.invalid_string,message:o.message}),n.dirty());else if(o.kind==="url")try{new URL(e.data)}catch{i=this._getOrReturnCtx(e,i),Le(i,{validation:"url",code:be.invalid_string,message:o.message}),n.dirty()}else o.kind==="regex"?(o.regex.lastIndex=0,o.regex.test(e.data)||(i=this._getOrReturnCtx(e,i),Le(i,{validation:"regex",code:be.invalid_string,message:o.message}),n.dirty())):o.kind==="trim"?e.data=e.data.trim():o.kind==="includes"?e.data.includes(o.value,o.position)||(i=this._getOrReturnCtx(e,i),Le(i,{code:be.invalid_string,validation:{includes:o.value,position:o.position},message:o.message}),n.dirty()):o.kind==="toLowerCase"?e.data=e.data.toLowerCase():o.kind==="toUpperCase"?e.data=e.data.toUpperCase():o.kind==="startsWith"?e.data.startsWith(o.value)||(i=this._getOrReturnCtx(e,i),Le(i,{code:be.invalid_string,validation:{startsWith:o.value},message:o.message}),n.dirty()):o.kind==="endsWith"?e.data.endsWith(o.value)||(i=this._getOrReturnCtx(e,i),Le(i,{code:be.invalid_string,validation:{endsWith:o.value},message:o.message}),n.dirty()):o.kind==="datetime"?jR(o).test(e.data)||(i=this._getOrReturnCtx(e,i),Le(i,{code:be.invalid_string,validation:"datetime",message:o.message}),n.dirty()):o.kind==="date"?xD.test(e.data)||(i=this._getOrReturnCtx(e,i),Le(i,{code:be.invalid_string,validation:"date",message:o.message}),n.dirty()):o.kind==="time"?CD(o).test(e.data)||(i=this._getOrReturnCtx(e,i),Le(i,{code:be.invalid_string,validation:"time",message:o.message}),n.dirty()):o.kind==="duration"?fD.test(e.data)||(i=this._getOrReturnCtx(e,i),Le(i,{validation:"duration",code:be.invalid_string,message:o.message}),n.dirty()):o.kind==="ip"?kD(e.data,o.version)||(i=this._getOrReturnCtx(e,i),Le(i,{validation:"ip",code:be.invalid_string,message:o.message}),n.dirty()):o.kind==="jwt"?ED(e.data,o.alg)||(i=this._getOrReturnCtx(e,i),Le(i,{validation:"jwt",code:be.invalid_string,message:o.message}),n.dirty()):o.kind==="cidr"?SD(e.data,o.version)||(i=this._getOrReturnCtx(e,i),Le(i,{validation:"cidr",code:be.invalid_string,message:o.message}),n.dirty()):o.kind==="base64"?bD.test(e.data)||(i=this._getOrReturnCtx(e,i),Le(i,{validation:"base64",code:be.invalid_string,message:o.message}),n.dirty()):o.kind==="base64url"?wD.test(e.data)||(i=this._getOrReturnCtx(e,i),Le(i,{validation:"base64url",code:be.invalid_string,message:o.message}),n.dirty()):Qt.assertNever(o);return{status:n.value,value:e.data}}_regex(e,t,n){return this.refinement(i=>e.test(i),{validation:t,code:be.invalid_string,...ct.errToObj(n)})}_addCheck(e){return new Pa({...this._def,checks:[...this._def.checks,e]})}email(e){return this._addCheck({kind:"email",...ct.errToObj(e)})}url(e){return this._addCheck({kind:"url",...ct.errToObj(e)})}emoji(e){return this._addCheck({kind:"emoji",...ct.errToObj(e)})}uuid(e){return this._addCheck({kind:"uuid",...ct.errToObj(e)})}nanoid(e){return this._addCheck({kind:"nanoid",...ct.errToObj(e)})}cuid(e){return this._addCheck({kind:"cuid",...ct.errToObj(e)})}cuid2(e){return this._addCheck({kind:"cuid2",...ct.errToObj(e)})}ulid(e){return this._addCheck({kind:"ulid",...ct.errToObj(e)})}base64(e){return this._addCheck({kind:"base64",...ct.errToObj(e)})}base64url(e){return this._addCheck({kind:"base64url",...ct.errToObj(e)})}jwt(e){return this._addCheck({kind:"jwt",...ct.errToObj(e)})}ip(e){return this._addCheck({kind:"ip",...ct.errToObj(e)})}cidr(e){return this._addCheck({kind:"cidr",...ct.errToObj(e)})}datetime(e){var t,n;return typeof e=="string"?this._addCheck({kind:"datetime",precision:null,offset:!1,local:!1,message:e}):this._addCheck({kind:"datetime",precision:typeof(e==null?void 0:e.precision)>"u"?null:e==null?void 0:e.precision,offset:(t=e==null?void 0:e.offset)!==null&&t!==void 0?t:!1,local:(n=e==null?void 0:e.local)!==null&&n!==void 0?n:!1,...ct.errToObj(e==null?void 0:e.message)})}date(e){return this._addCheck({kind:"date",message:e})}time(e){return typeof e=="string"?this._addCheck({kind:"time",precision:null,message:e}):this._addCheck({kind:"time",precision:typeof(e==null?void 0:e.precision)>"u"?null:e==null?void 0:e.precision,...ct.errToObj(e==null?void 0:e.message)})}duration(e){return this._addCheck({kind:"duration",...ct.errToObj(e)})}regex(e,t){return this._addCheck({kind:"regex",regex:e,...ct.errToObj(t)})}includes(e,t){return this._addCheck({kind:"includes",value:e,position:t==null?void 0:t.position,...ct.errToObj(t==null?void 0:t.message)})}startsWith(e,t){return this._addCheck({kind:"startsWith",value:e,...ct.errToObj(t)})}endsWith(e,t){return this._addCheck({kind:"endsWith",value:e,...ct.errToObj(t)})}min(e,t){return this._addCheck({kind:"min",value:e,...ct.errToObj(t)})}max(e,t){return this._addCheck({kind:"max",value:e,...ct.errToObj(t)})}length(e,t){return this._addCheck({kind:"length",value:e,...ct.errToObj(t)})}nonempty(e){return this.min(1,ct.errToObj(e))}trim(){return new Pa({...this._def,checks:[...this._def.checks,{kind:"trim"}]})}toLowerCase(){return new Pa({...this._def,checks:[...this._def.checks,{kind:"toLowerCase"}]})}toUpperCase(){return new Pa({...this._def,checks:[...this._def.checks,{kind:"toUpperCase"}]})}get isDatetime(){return!!this._def.checks.find(e=>e.kind==="datetime")}get isDate(){return!!this._def.checks.find(e=>e.kind==="date")}get isTime(){return!!this._def.checks.find(e=>e.kind==="time")}get isDuration(){return!!this._def.checks.find(e=>e.kind==="duration")}get isEmail(){return!!this._def.checks.find(e=>e.kind==="email")}get isURL(){return!!this._def.checks.find(e=>e.kind==="url")}get isEmoji(){return!!this._def.checks.find(e=>e.kind==="emoji")}get isUUID(){return!!this._def.checks.find(e=>e.kind==="uuid")}get isNANOID(){return!!this._def.checks.find(e=>e.kind==="nanoid")}get isCUID(){return!!this._def.checks.find(e=>e.kind==="cuid")}get isCUID2(){return!!this._def.checks.find(e=>e.kind==="cuid2")}get isULID(){return!!this._def.checks.find(e=>e.kind==="ulid")}get isIP(){return!!this._def.checks.find(e=>e.kind==="ip")}get isCIDR(){return!!this._def.checks.find(e=>e.kind==="cidr")}get isBase64(){return!!this._def.checks.find(e=>e.kind==="base64")}get isBase64url(){return!!this._def.checks.find(e=>e.kind==="base64url")}get minLength(){let e=null;for(const t of this._def.checks)t.kind==="min"&&(e===null||t.value>e)&&(e=t.value);return e}get maxLength(){let e=null;for(const t of this._def.checks)t.kind==="max"&&(e===null||t.value<e)&&(e=t.value);return e}}Pa.create=r=>{var e;return new Pa({checks:[],typeName:yt.ZodString,coerce:(e=r==null?void 0:r.coerce)!==null&&e!==void 0?e:!1,...Pt(r)})};function TD(r,e){const t=(r.toString().split(".")[1]||"").length,n=(e.toString().split(".")[1]||"").length,i=t>n?t:n,o=parseInt(r.toFixed(i).replace(".","")),a=parseInt(e.toFixed(i).replace(".",""));return o%a/Math.pow(10,i)}class Al extends Lt{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte,this.step=this.multipleOf}_parse(e){if(this._def.coerce&&(e.data=Number(e.data)),this._getType(e)!==Ue.number){const o=this._getOrReturnCtx(e);return Le(o,{code:be.invalid_type,expected:Ue.number,received:o.parsedType}),bt}let n;const i=new ki;for(const o of this._def.checks)o.kind==="int"?Qt.isInteger(e.data)||(n=this._getOrReturnCtx(e,n),Le(n,{code:be.invalid_type,expected:"integer",received:"float",message:o.message}),i.dirty()):o.kind==="min"?(o.inclusive?e.data<o.value:e.data<=o.value)&&(n=this._getOrReturnCtx(e,n),Le(n,{code:be.too_small,minimum:o.value,type:"number",inclusive:o.inclusive,exact:!1,message:o.message}),i.dirty()):o.kind==="max"?(o.inclusive?e.data>o.value:e.data>=o.value)&&(n=this._getOrReturnCtx(e,n),Le(n,{code:be.too_big,maximum:o.value,type:"number",inclusive:o.inclusive,exact:!1,message:o.message}),i.dirty()):o.kind==="multipleOf"?TD(e.data,o.value)!==0&&(n=this._getOrReturnCtx(e,n),Le(n,{code:be.not_multiple_of,multipleOf:o.value,message:o.message}),i.dirty()):o.kind==="finite"?Number.isFinite(e.data)||(n=this._getOrReturnCtx(e,n),Le(n,{code:be.not_finite,message:o.message}),i.dirty()):Qt.assertNever(o);return{status:i.value,value:e.data}}gte(e,t){return this.setLimit("min",e,!0,ct.toString(t))}gt(e,t){return this.setLimit("min",e,!1,ct.toString(t))}lte(e,t){return this.setLimit("max",e,!0,ct.toString(t))}lt(e,t){return this.setLimit("max",e,!1,ct.toString(t))}setLimit(e,t,n,i){return new Al({...this._def,checks:[...this._def.checks,{kind:e,value:t,inclusive:n,message:ct.toString(i)}]})}_addCheck(e){return new Al({...this._def,checks:[...this._def.checks,e]})}int(e){return this._addCheck({kind:"int",message:ct.toString(e)})}positive(e){return this._addCheck({kind:"min",value:0,inclusive:!1,message:ct.toString(e)})}negative(e){return this._addCheck({kind:"max",value:0,inclusive:!1,message:ct.toString(e)})}nonpositive(e){return this._addCheck({kind:"max",value:0,inclusive:!0,message:ct.toString(e)})}nonnegative(e){return this._addCheck({kind:"min",value:0,inclusive:!0,message:ct.toString(e)})}multipleOf(e,t){return this._addCheck({kind:"multipleOf",value:e,message:ct.toString(t)})}finite(e){return this._addCheck({kind:"finite",message:ct.toString(e)})}safe(e){return this._addCheck({kind:"min",inclusive:!0,value:Number.MIN_SAFE_INTEGER,message:ct.toString(e)})._addCheck({kind:"max",inclusive:!0,value:Number.MAX_SAFE_INTEGER,message:ct.toString(e)})}get minValue(){let e=null;for(const t of this._def.checks)t.kind==="min"&&(e===null||t.value>e)&&(e=t.value);return e}get maxValue(){let e=null;for(const t of this._def.checks)t.kind==="max"&&(e===null||t.value<e)&&(e=t.value);return e}get isInt(){return!!this._def.checks.find(e=>e.kind==="int"||e.kind==="multipleOf"&&Qt.isInteger(e.value))}get isFinite(){let e=null,t=null;for(const n of this._def.checks){if(n.kind==="finite"||n.kind==="int"||n.kind==="multipleOf")return!0;n.kind==="min"?(t===null||n.value>t)&&(t=n.value):n.kind==="max"&&(e===null||n.value<e)&&(e=n.value)}return Number.isFinite(t)&&Number.isFinite(e)}}Al.create=r=>new Al({checks:[],typeName:yt.ZodNumber,coerce:(r==null?void 0:r.coerce)||!1,...Pt(r)});class Il extends Lt{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte}_parse(e){if(this._def.coerce)try{e.data=BigInt(e.data)}catch{return this._getInvalidInput(e)}if(this._getType(e)!==Ue.bigint)return this._getInvalidInput(e);let n;const i=new ki;for(const o of this._def.checks)o.kind==="min"?(o.inclusive?e.data<o.value:e.data<=o.value)&&(n=this._getOrReturnCtx(e,n),Le(n,{code:be.too_small,type:"bigint",minimum:o.value,inclusive:o.inclusive,message:o.message}),i.dirty()):o.kind==="max"?(o.inclusive?e.data>o.value:e.data>=o.value)&&(n=this._getOrReturnCtx(e,n),Le(n,{code:be.too_big,type:"bigint",maximum:o.value,inclusive:o.inclusive,message:o.message}),i.dirty()):o.kind==="multipleOf"?e.data%o.value!==BigInt(0)&&(n=this._getOrReturnCtx(e,n),Le(n,{code:be.not_multiple_of,multipleOf:o.value,message:o.message}),i.dirty()):Qt.assertNever(o);return{status:i.value,value:e.data}}_getInvalidInput(e){const t=this._getOrReturnCtx(e);return Le(t,{code:be.invalid_type,expected:Ue.bigint,received:t.parsedType}),bt}gte(e,t){return this.setLimit("min",e,!0,ct.toString(t))}gt(e,t){return this.setLimit("min",e,!1,ct.toString(t))}lte(e,t){return this.setLimit("max",e,!0,ct.toString(t))}lt(e,t){return this.setLimit("max",e,!1,ct.toString(t))}setLimit(e,t,n,i){return new Il({...this._def,checks:[...this._def.checks,{kind:e,value:t,inclusive:n,message:ct.toString(i)}]})}_addCheck(e){return new Il({...this._def,checks:[...this._def.checks,e]})}positive(e){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!1,message:ct.toString(e)})}negative(e){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!1,message:ct.toString(e)})}nonpositive(e){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!0,message:ct.toString(e)})}nonnegative(e){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!0,message:ct.toString(e)})}multipleOf(e,t){return this._addCheck({kind:"multipleOf",value:e,message:ct.toString(t)})}get minValue(){let e=null;for(const t of this._def.checks)t.kind==="min"&&(e===null||t.value>e)&&(e=t.value);return e}get maxValue(){let e=null;for(const t of this._def.checks)t.kind==="max"&&(e===null||t.value<e)&&(e=t.value);return e}}Il.create=r=>{var e;return new Il({checks:[],typeName:yt.ZodBigInt,coerce:(e=r==null?void 0:r.coerce)!==null&&e!==void 0?e:!1,...Pt(r)})};class Wp extends Lt{_parse(e){if(this._def.coerce&&(e.data=!!e.data),this._getType(e)!==Ue.boolean){const n=this._getOrReturnCtx(e);return Le(n,{code:be.invalid_type,expected:Ue.boolean,received:n.parsedType}),bt}return Fi(e.data)}}Wp.create=r=>new Wp({typeName:yt.ZodBoolean,coerce:(r==null?void 0:r.coerce)||!1,...Pt(r)});class bu extends Lt{_parse(e){if(this._def.coerce&&(e.data=new Date(e.data)),this._getType(e)!==Ue.date){const o=this._getOrReturnCtx(e);return Le(o,{code:be.invalid_type,expected:Ue.date,received:o.parsedType}),bt}if(isNaN(e.data.getTime())){const o=this._getOrReturnCtx(e);return Le(o,{code:be.invalid_date}),bt}const n=new ki;let i;for(const o of this._def.checks)o.kind==="min"?e.data.getTime()<o.value&&(i=this._getOrReturnCtx(e,i),Le(i,{code:be.too_small,message:o.message,inclusive:!0,exact:!1,minimum:o.value,type:"date"}),n.dirty()):o.kind==="max"?e.data.getTime()>o.value&&(i=this._getOrReturnCtx(e,i),Le(i,{code:be.too_big,message:o.message,inclusive:!0,exact:!1,maximum:o.value,type:"date"}),n.dirty()):Qt.assertNever(o);return{status:n.value,value:new Date(e.data.getTime())}}_addCheck(e){return new bu({...this._def,checks:[...this._def.checks,e]})}min(e,t){return this._addCheck({kind:"min",value:e.getTime(),message:ct.toString(t)})}max(e,t){return this._addCheck({kind:"max",value:e.getTime(),message:ct.toString(t)})}get minDate(){let e=null;for(const t of this._def.checks)t.kind==="min"&&(e===null||t.value>e)&&(e=t.value);return e!=null?new Date(e):null}get maxDate(){let e=null;for(const t of this._def.checks)t.kind==="max"&&(e===null||t.value<e)&&(e=t.value);return e!=null?new Date(e):null}}bu.create=r=>new bu({checks:[],coerce:(r==null?void 0:r.coerce)||!1,typeName:yt.ZodDate,...Pt(r)});class cg extends Lt{_parse(e){if(this._getType(e)!==Ue.symbol){const n=this._getOrReturnCtx(e);return Le(n,{code:be.invalid_type,expected:Ue.symbol,received:n.parsedType}),bt}return Fi(e.data)}}cg.create=r=>new cg({typeName:yt.ZodSymbol,...Pt(r)});class Gp extends Lt{_parse(e){if(this._getType(e)!==Ue.undefined){const n=this._getOrReturnCtx(e);return Le(n,{code:be.invalid_type,expected:Ue.undefined,received:n.parsedType}),bt}return Fi(e.data)}}Gp.create=r=>new Gp({typeName:yt.ZodUndefined,...Pt(r)});class Kp extends Lt{_parse(e){if(this._getType(e)!==Ue.null){const n=this._getOrReturnCtx(e);return Le(n,{code:be.invalid_type,expected:Ue.null,received:n.parsedType}),bt}return Fi(e.data)}}Kp.create=r=>new Kp({typeName:yt.ZodNull,...Pt(r)});class mf extends Lt{constructor(){super(...arguments),this._any=!0}_parse(e){return Fi(e.data)}}mf.create=r=>new mf({typeName:yt.ZodAny,...Pt(r)});class au extends Lt{constructor(){super(...arguments),this._unknown=!0}_parse(e){return Fi(e.data)}}au.create=r=>new au({typeName:yt.ZodUnknown,...Pt(r)});class gc extends Lt{_parse(e){const t=this._getOrReturnCtx(e);return Le(t,{code:be.invalid_type,expected:Ue.never,received:t.parsedType}),bt}}gc.create=r=>new gc({typeName:yt.ZodNever,...Pt(r)});class lg extends Lt{_parse(e){if(this._getType(e)!==Ue.undefined){const n=this._getOrReturnCtx(e);return Le(n,{code:be.invalid_type,expected:Ue.void,received:n.parsedType}),bt}return Fi(e.data)}}lg.create=r=>new lg({typeName:yt.ZodVoid,...Pt(r)});class Oa extends Lt{_parse(e){const{ctx:t,status:n}=this._processInputParams(e),i=this._def;if(t.parsedType!==Ue.array)return Le(t,{code:be.invalid_type,expected:Ue.array,received:t.parsedType}),bt;if(i.exactLength!==null){const a=t.data.length>i.exactLength.value,c=t.data.length<i.exactLength.value;(a||c)&&(Le(t,{code:a?be.too_big:be.too_small,minimum:c?i.exactLength.value:void 0,maximum:a?i.exactLength.value:void 0,type:"array",inclusive:!0,exact:!0,message:i.exactLength.message}),n.dirty())}if(i.minLength!==null&&t.data.length<i.minLength.value&&(Le(t,{code:be.too_small,minimum:i.minLength.value,type:"array",inclusive:!0,exact:!1,message:i.minLength.message}),n.dirty()),i.maxLength!==null&&t.data.length>i.maxLength.value&&(Le(t,{code:be.too_big,maximum:i.maxLength.value,type:"array",inclusive:!0,exact:!1,message:i.maxLength.message}),n.dirty()),t.common.async)return Promise.all([...t.data].map((a,c)=>i.type._parseAsync(new bs(t,a,t.path,c)))).then(a=>ki.mergeArray(n,a));const o=[...t.data].map((a,c)=>i.type._parseSync(new bs(t,a,t.path,c)));return ki.mergeArray(n,o)}get element(){return this._def.type}min(e,t){return new Oa({...this._def,minLength:{value:e,message:ct.toString(t)}})}max(e,t){return new Oa({...this._def,maxLength:{value:e,message:ct.toString(t)}})}length(e,t){return new Oa({...this._def,exactLength:{value:e,message:ct.toString(t)}})}nonempty(e){return this.min(1,e)}}Oa.create=(r,e)=>new Oa({type:r,minLength:null,maxLength:null,exactLength:null,typeName:yt.ZodArray,...Pt(e)});function Lh(r){if(r instanceof nn){const e={};for(const t in r.shape){const n=r.shape[t];e[t]=ps.create(Lh(n))}return new nn({...r._def,shape:()=>e})}else return r instanceof Oa?new Oa({...r._def,type:Lh(r.element)}):r instanceof ps?ps.create(Lh(r.unwrap())):r instanceof Pl?Pl.create(Lh(r.unwrap())):r instanceof ws?ws.create(r.items.map(e=>Lh(e))):r}class nn extends Lt{constructor(){super(...arguments),this._cached=null,this.nonstrict=this.passthrough,this.augment=this.extend}_getCached(){if(this._cached!==null)return this._cached;const e=this._def.shape(),t=Qt.objectKeys(e);return this._cached={shape:e,keys:t}}_parse(e){if(this._getType(e)!==Ue.object){const h=this._getOrReturnCtx(e);return Le(h,{code:be.invalid_type,expected:Ue.object,received:h.parsedType}),bt}const{status:n,ctx:i}=this._processInputParams(e),{shape:o,keys:a}=this._getCached(),c=[];if(!(this._def.catchall instanceof gc&&this._def.unknownKeys==="strip"))for(const h in i.data)a.includes(h)||c.push(h);const d=[];for(const h of a){const u=o[h],p=i.data[h];d.push({key:{status:"valid",value:h},value:u._parse(new bs(i,p,i.path,h)),alwaysSet:h in i.data})}if(this._def.catchall instanceof gc){const h=this._def.unknownKeys;if(h==="passthrough")for(const u of c)d.push({key:{status:"valid",value:u},value:{status:"valid",value:i.data[u]}});else if(h==="strict")c.length>0&&(Le(i,{code:be.unrecognized_keys,keys:c}),n.dirty());else if(h!=="strip")throw new Error("Internal ZodObject error: invalid unknownKeys value.")}else{const h=this._def.catchall;for(const u of c){const p=i.data[u];d.push({key:{status:"valid",value:u},value:h._parse(new bs(i,p,i.path,u)),alwaysSet:u in i.data})}}return i.common.async?Promise.resolve().then(async()=>{const h=[];for(const u of d){const p=await u.key,v=await u.value;h.push({key:p,value:v,alwaysSet:u.alwaysSet})}return h}).then(h=>ki.mergeObjectSync(n,h)):ki.mergeObjectSync(n,d)}get shape(){return this._def.shape()}strict(e){return ct.errToObj,new nn({...this._def,unknownKeys:"strict",...e!==void 0?{errorMap:(t,n)=>{var i,o,a,c;const d=(a=(o=(i=this._def).errorMap)===null||o===void 0?void 0:o.call(i,t,n).message)!==null&&a!==void 0?a:n.defaultError;return t.code==="unrecognized_keys"?{message:(c=ct.errToObj(e).message)!==null&&c!==void 0?c:d}:{message:d}}}:{}})}strip(){return new nn({...this._def,unknownKeys:"strip"})}passthrough(){return new nn({...this._def,unknownKeys:"passthrough"})}extend(e){return new nn({...this._def,shape:()=>({...this._def.shape(),...e})})}merge(e){return new nn({unknownKeys:e._def.unknownKeys,catchall:e._def.catchall,shape:()=>({...this._def.shape(),...e._def.shape()}),typeName:yt.ZodObject})}setKey(e,t){return this.augment({[e]:t})}catchall(e){return new nn({...this._def,catchall:e})}pick(e){const t={};return Qt.objectKeys(e).forEach(n=>{e[n]&&this.shape[n]&&(t[n]=this.shape[n])}),new nn({...this._def,shape:()=>t})}omit(e){const t={};return Qt.objectKeys(this.shape).forEach(n=>{e[n]||(t[n]=this.shape[n])}),new nn({...this._def,shape:()=>t})}deepPartial(){return Lh(this)}partial(e){const t={};return Qt.objectKeys(this.shape).forEach(n=>{const i=this.shape[n];e&&!e[n]?t[n]=i:t[n]=i.optional()}),new nn({...this._def,shape:()=>t})}required(e){const t={};return Qt.objectKeys(this.shape).forEach(n=>{if(e&&!e[n])t[n]=this.shape[n];else{let o=this.shape[n];for(;o instanceof ps;)o=o._def.innerType;t[n]=o}}),new nn({...this._def,shape:()=>t})}keyof(){return zR(Qt.objectKeys(this.shape))}}nn.create=(r,e)=>new nn({shape:()=>r,unknownKeys:"strip",catchall:gc.create(),typeName:yt.ZodObject,...Pt(e)});nn.strictCreate=(r,e)=>new nn({shape:()=>r,unknownKeys:"strict",catchall:gc.create(),typeName:yt.ZodObject,...Pt(e)});nn.lazycreate=(r,e)=>new nn({shape:r,unknownKeys:"strip",catchall:gc.create(),typeName:yt.ZodObject,...Pt(e)});class Yp extends Lt{_parse(e){const{ctx:t}=this._processInputParams(e),n=this._def.options;function i(o){for(const c of o)if(c.result.status==="valid")return c.result;for(const c of o)if(c.result.status==="dirty")return t.common.issues.push(...c.ctx.common.issues),c.result;const a=o.map(c=>new ko(c.ctx.common.issues));return Le(t,{code:be.invalid_union,unionErrors:a}),bt}if(t.common.async)return Promise.all(n.map(async o=>{const a={...t,common:{...t.common,issues:[]},parent:null};return{result:await o._parseAsync({data:t.data,path:t.path,parent:a}),ctx:a}})).then(i);{let o;const a=[];for(const d of n){const h={...t,common:{...t.common,issues:[]},parent:null},u=d._parseSync({data:t.data,path:t.path,parent:h});if(u.status==="valid")return u;u.status==="dirty"&&!o&&(o={result:u,ctx:h}),h.common.issues.length&&a.push(h.common.issues)}if(o)return t.common.issues.push(...o.ctx.common.issues),o.result;const c=a.map(d=>new ko(d));return Le(t,{code:be.invalid_union,unionErrors:c}),bt}}get options(){return this._def.options}}Yp.create=(r,e)=>new Yp({options:r,typeName:yt.ZodUnion,...Pt(e)});const Ys=r=>r instanceof Jp?Ys(r.schema):r instanceof Na?Ys(r.innerType()):r instanceof em?[r.value]:r instanceof Rl?r.options:r instanceof tm?Qt.objectValues(r.enum):r instanceof rm?Ys(r._def.innerType):r instanceof Gp?[void 0]:r instanceof Kp?[null]:r instanceof ps?[void 0,...Ys(r.unwrap())]:r instanceof Pl?[null,...Ys(r.unwrap())]:r instanceof S6||r instanceof im?Ys(r.unwrap()):r instanceof nm?Ys(r._def.innerType):[];class h4 extends Lt{_parse(e){const{ctx:t}=this._processInputParams(e);if(t.parsedType!==Ue.object)return Le(t,{code:be.invalid_type,expected:Ue.object,received:t.parsedType}),bt;const n=this.discriminator,i=t.data[n],o=this.optionsMap.get(i);return o?t.common.async?o._parseAsync({data:t.data,path:t.path,parent:t}):o._parseSync({data:t.data,path:t.path,parent:t}):(Le(t,{code:be.invalid_union_discriminator,options:Array.from(this.optionsMap.keys()),path:[n]}),bt)}get discriminator(){return this._def.discriminator}get options(){return this._def.options}get optionsMap(){return this._def.optionsMap}static create(e,t,n){const i=new Map;for(const o of t){const a=Ys(o.shape[e]);if(!a.length)throw new Error(`A discriminator value for key \`${e}\` could not be extracted from all schema options`);for(const c of a){if(i.has(c))throw new Error(`Discriminator property ${String(e)} has duplicate value ${String(c)}`);i.set(c,o)}}return new h4({typeName:yt.ZodDiscriminatedUnion,discriminator:e,options:t,optionsMap:i,...Pt(n)})}}function Eb(r,e){const t=rc(r),n=rc(e);if(r===e)return{valid:!0,data:r};if(t===Ue.object&&n===Ue.object){const i=Qt.objectKeys(e),o=Qt.objectKeys(r).filter(c=>i.indexOf(c)!==-1),a={...r,...e};for(const c of o){const d=Eb(r[c],e[c]);if(!d.valid)return{valid:!1};a[c]=d.data}return{valid:!0,data:a}}else if(t===Ue.array&&n===Ue.array){if(r.length!==e.length)return{valid:!1};const i=[];for(let o=0;o<r.length;o++){const a=r[o],c=e[o],d=Eb(a,c);if(!d.valid)return{valid:!1};i.push(d.data)}return{valid:!0,data:i}}else return t===Ue.date&&n===Ue.date&&+r==+e?{valid:!0,data:r}:{valid:!1}}class Qp extends Lt{_parse(e){const{status:t,ctx:n}=this._processInputParams(e),i=(o,a)=>{if(Cb(o)||Cb(a))return bt;const c=Eb(o.value,a.value);return c.valid?((kb(o)||kb(a))&&t.dirty(),{status:t.value,value:c.data}):(Le(n,{code:be.invalid_intersection_types}),bt)};return n.common.async?Promise.all([this._def.left._parseAsync({data:n.data,path:n.path,parent:n}),this._def.right._parseAsync({data:n.data,path:n.path,parent:n})]).then(([o,a])=>i(o,a)):i(this._def.left._parseSync({data:n.data,path:n.path,parent:n}),this._def.right._parseSync({data:n.data,path:n.path,parent:n}))}}Qp.create=(r,e,t)=>new Qp({left:r,right:e,typeName:yt.ZodIntersection,...Pt(t)});class ws extends Lt{_parse(e){const{status:t,ctx:n}=this._processInputParams(e);if(n.parsedType!==Ue.array)return Le(n,{code:be.invalid_type,expected:Ue.array,received:n.parsedType}),bt;if(n.data.length<this._def.items.length)return Le(n,{code:be.too_small,minimum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),bt;!this._def.rest&&n.data.length>this._def.items.length&&(Le(n,{code:be.too_big,maximum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),t.dirty());const o=[...n.data].map((a,c)=>{const d=this._def.items[c]||this._def.rest;return d?d._parse(new bs(n,a,n.path,c)):null}).filter(a=>!!a);return n.common.async?Promise.all(o).then(a=>ki.mergeArray(t,a)):ki.mergeArray(t,o)}get items(){return this._def.items}rest(e){return new ws({...this._def,rest:e})}}ws.create=(r,e)=>{if(!Array.isArray(r))throw new Error("You must pass an array of schemas to z.tuple([ ... ])");return new ws({items:r,typeName:yt.ZodTuple,rest:null,...Pt(e)})};class Xp extends Lt{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(e){const{status:t,ctx:n}=this._processInputParams(e);if(n.parsedType!==Ue.object)return Le(n,{code:be.invalid_type,expected:Ue.object,received:n.parsedType}),bt;const i=[],o=this._def.keyType,a=this._def.valueType;for(const c in n.data)i.push({key:o._parse(new bs(n,c,n.path,c)),value:a._parse(new bs(n,n.data[c],n.path,c)),alwaysSet:c in n.data});return n.common.async?ki.mergeObjectAsync(t,i):ki.mergeObjectSync(t,i)}get element(){return this._def.valueType}static create(e,t,n){return t instanceof Lt?new Xp({keyType:e,valueType:t,typeName:yt.ZodRecord,...Pt(n)}):new Xp({keyType:Pa.create(),valueType:e,typeName:yt.ZodRecord,...Pt(t)})}}class dg extends Lt{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(e){const{status:t,ctx:n}=this._processInputParams(e);if(n.parsedType!==Ue.map)return Le(n,{code:be.invalid_type,expected:Ue.map,received:n.parsedType}),bt;const i=this._def.keyType,o=this._def.valueType,a=[...n.data.entries()].map(([c,d],h)=>({key:i._parse(new bs(n,c,n.path,[h,"key"])),value:o._parse(new bs(n,d,n.path,[h,"value"]))}));if(n.common.async){const c=new Map;return Promise.resolve().then(async()=>{for(const d of a){const h=await d.key,u=await d.value;if(h.status==="aborted"||u.status==="aborted")return bt;(h.status==="dirty"||u.status==="dirty")&&t.dirty(),c.set(h.value,u.value)}return{status:t.value,value:c}})}else{const c=new Map;for(const d of a){const h=d.key,u=d.value;if(h.status==="aborted"||u.status==="aborted")return bt;(h.status==="dirty"||u.status==="dirty")&&t.dirty(),c.set(h.value,u.value)}return{status:t.value,value:c}}}}dg.create=(r,e,t)=>new dg({valueType:e,keyType:r,typeName:yt.ZodMap,...Pt(t)});class wu extends Lt{_parse(e){const{status:t,ctx:n}=this._processInputParams(e);if(n.parsedType!==Ue.set)return Le(n,{code:be.invalid_type,expected:Ue.set,received:n.parsedType}),bt;const i=this._def;i.minSize!==null&&n.data.size<i.minSize.value&&(Le(n,{code:be.too_small,minimum:i.minSize.value,type:"set",inclusive:!0,exact:!1,message:i.minSize.message}),t.dirty()),i.maxSize!==null&&n.data.size>i.maxSize.value&&(Le(n,{code:be.too_big,maximum:i.maxSize.value,type:"set",inclusive:!0,exact:!1,message:i.maxSize.message}),t.dirty());const o=this._def.valueType;function a(d){const h=new Set;for(const u of d){if(u.status==="aborted")return bt;u.status==="dirty"&&t.dirty(),h.add(u.value)}return{status:t.value,value:h}}const c=[...n.data.values()].map((d,h)=>o._parse(new bs(n,d,n.path,h)));return n.common.async?Promise.all(c).then(d=>a(d)):a(c)}min(e,t){return new wu({...this._def,minSize:{value:e,message:ct.toString(t)}})}max(e,t){return new wu({...this._def,maxSize:{value:e,message:ct.toString(t)}})}size(e,t){return this.min(e,t).max(e,t)}nonempty(e){return this.min(1,e)}}wu.create=(r,e)=>new wu({valueType:r,minSize:null,maxSize:null,typeName:yt.ZodSet,...Pt(e)});class af extends Lt{constructor(){super(...arguments),this.validate=this.implement}_parse(e){const{ctx:t}=this._processInputParams(e);if(t.parsedType!==Ue.function)return Le(t,{code:be.invalid_type,expected:Ue.function,received:t.parsedType}),bt;function n(c,d){return ag({data:c,path:t.path,errorMaps:[t.common.contextualErrorMap,t.schemaErrorMap,og(),pf].filter(h=>!!h),issueData:{code:be.invalid_arguments,argumentsError:d}})}function i(c,d){return ag({data:c,path:t.path,errorMaps:[t.common.contextualErrorMap,t.schemaErrorMap,og(),pf].filter(h=>!!h),issueData:{code:be.invalid_return_type,returnTypeError:d}})}const o={errorMap:t.common.contextualErrorMap},a=t.data;if(this._def.returns instanceof vf){const c=this;return Fi(async function(...d){const h=new ko([]),u=await c._def.args.parseAsync(d,o).catch(g=>{throw h.addIssue(n(d,g)),h}),p=await Reflect.apply(a,this,u);return await c._def.returns._def.type.parseAsync(p,o).catch(g=>{throw h.addIssue(i(p,g)),h})})}else{const c=this;return Fi(function(...d){const h=c._def.args.safeParse(d,o);if(!h.success)throw new ko([n(d,h.error)]);const u=Reflect.apply(a,this,h.data),p=c._def.returns.safeParse(u,o);if(!p.success)throw new ko([i(u,p.error)]);return p.data})}}parameters(){return this._def.args}returnType(){return this._def.returns}args(...e){return new af({...this._def,args:ws.create(e).rest(au.create())})}returns(e){return new af({...this._def,returns:e})}implement(e){return this.parse(e)}strictImplement(e){return this.parse(e)}static create(e,t,n){return new af({args:e||ws.create([]).rest(au.create()),returns:t||au.create(),typeName:yt.ZodFunction,...Pt(n)})}}class Jp extends Lt{get schema(){return this._def.getter()}_parse(e){const{ctx:t}=this._processInputParams(e);return this._def.getter()._parse({data:t.data,path:t.path,parent:t})}}Jp.create=(r,e)=>new Jp({getter:r,typeName:yt.ZodLazy,...Pt(e)});class em extends Lt{_parse(e){if(e.data!==this._def.value){const t=this._getOrReturnCtx(e);return Le(t,{received:t.data,code:be.invalid_literal,expected:this._def.value}),bt}return{status:"valid",value:e.data}}get value(){return this._def.value}}em.create=(r,e)=>new em({value:r,typeName:yt.ZodLiteral,...Pt(e)});function zR(r,e){return new Rl({values:r,typeName:yt.ZodEnum,...Pt(e)})}class Rl extends Lt{constructor(){super(...arguments),ap.set(this,void 0)}_parse(e){if(typeof e.data!="string"){const t=this._getOrReturnCtx(e),n=this._def.values;return Le(t,{expected:Qt.joinValues(n),received:t.parsedType,code:be.invalid_type}),bt}if(sg(this,ap)||DR(this,ap,new Set(this._def.values)),!sg(this,ap).has(e.data)){const t=this._getOrReturnCtx(e),n=this._def.values;return Le(t,{received:t.data,code:be.invalid_enum_value,options:n}),bt}return Fi(e.data)}get options(){return this._def.values}get enum(){const e={};for(const t of this._def.values)e[t]=t;return e}get Values(){const e={};for(const t of this._def.values)e[t]=t;return e}get Enum(){const e={};for(const t of this._def.values)e[t]=t;return e}extract(e,t=this._def){return Rl.create(e,{...this._def,...t})}exclude(e,t=this._def){return Rl.create(this.options.filter(n=>!e.includes(n)),{...this._def,...t})}}ap=new WeakMap;Rl.create=zR;class tm extends Lt{constructor(){super(...arguments),sp.set(this,void 0)}_parse(e){const t=Qt.getValidEnumValues(this._def.values),n=this._getOrReturnCtx(e);if(n.parsedType!==Ue.string&&n.parsedType!==Ue.number){const i=Qt.objectValues(t);return Le(n,{expected:Qt.joinValues(i),received:n.parsedType,code:be.invalid_type}),bt}if(sg(this,sp)||DR(this,sp,new Set(Qt.getValidEnumValues(this._def.values))),!sg(this,sp).has(e.data)){const i=Qt.objectValues(t);return Le(n,{received:n.data,code:be.invalid_enum_value,options:i}),bt}return Fi(e.data)}get enum(){return this._def.values}}sp=new WeakMap;tm.create=(r,e)=>new tm({values:r,typeName:yt.ZodNativeEnum,...Pt(e)});class vf extends Lt{unwrap(){return this._def.type}_parse(e){const{ctx:t}=this._processInputParams(e);if(t.parsedType!==Ue.promise&&t.common.async===!1)return Le(t,{code:be.invalid_type,expected:Ue.promise,received:t.parsedType}),bt;const n=t.parsedType===Ue.promise?t.data:Promise.resolve(t.data);return Fi(n.then(i=>this._def.type.parseAsync(i,{path:t.path,errorMap:t.common.contextualErrorMap})))}}vf.create=(r,e)=>new vf({type:r,typeName:yt.ZodPromise,...Pt(e)});class Na extends Lt{innerType(){return this._def.schema}sourceType(){return this._def.schema._def.typeName===yt.ZodEffects?this._def.schema.sourceType():this._def.schema}_parse(e){const{status:t,ctx:n}=this._processInputParams(e),i=this._def.effect||null,o={addIssue:a=>{Le(n,a),a.fatal?t.abort():t.dirty()},get path(){return n.path}};if(o.addIssue=o.addIssue.bind(o),i.type==="preprocess"){const a=i.transform(n.data,o);if(n.common.async)return Promise.resolve(a).then(async c=>{if(t.value==="aborted")return bt;const d=await this._def.schema._parseAsync({data:c,path:n.path,parent:n});return d.status==="aborted"?bt:d.status==="dirty"||t.value==="dirty"?Wh(d.value):d});{if(t.value==="aborted")return bt;const c=this._def.schema._parseSync({data:a,path:n.path,parent:n});return c.status==="aborted"?bt:c.status==="dirty"||t.value==="dirty"?Wh(c.value):c}}if(i.type==="refinement"){const a=c=>{const d=i.refinement(c,o);if(n.common.async)return Promise.resolve(d);if(d instanceof Promise)throw new Error("Async refinement encountered during synchronous parse operation. Use .parseAsync instead.");return c};if(n.common.async===!1){const c=this._def.schema._parseSync({data:n.data,path:n.path,parent:n});return c.status==="aborted"?bt:(c.status==="dirty"&&t.dirty(),a(c.value),{status:t.value,value:c.value})}else return this._def.schema._parseAsync({data:n.data,path:n.path,parent:n}).then(c=>c.status==="aborted"?bt:(c.status==="dirty"&&t.dirty(),a(c.value).then(()=>({status:t.value,value:c.value}))))}if(i.type==="transform")if(n.common.async===!1){const a=this._def.schema._parseSync({data:n.data,path:n.path,parent:n});if(!_u(a))return a;const c=i.transform(a.value,o);if(c instanceof Promise)throw new Error("Asynchronous transform encountered during synchronous parse operation. Use .parseAsync instead.");return{status:t.value,value:c}}else return this._def.schema._parseAsync({data:n.data,path:n.path,parent:n}).then(a=>_u(a)?Promise.resolve(i.transform(a.value,o)).then(c=>({status:t.value,value:c})):a);Qt.assertNever(i)}}Na.create=(r,e,t)=>new Na({schema:r,typeName:yt.ZodEffects,effect:e,...Pt(t)});Na.createWithPreprocess=(r,e,t)=>new Na({schema:e,effect:{type:"preprocess",transform:r},typeName:yt.ZodEffects,...Pt(t)});class ps extends Lt{_parse(e){return this._getType(e)===Ue.undefined?Fi(void 0):this._def.innerType._parse(e)}unwrap(){return this._def.innerType}}ps.create=(r,e)=>new ps({innerType:r,typeName:yt.ZodOptional,...Pt(e)});class Pl extends Lt{_parse(e){return this._getType(e)===Ue.null?Fi(null):this._def.innerType._parse(e)}unwrap(){return this._def.innerType}}Pl.create=(r,e)=>new Pl({innerType:r,typeName:yt.ZodNullable,...Pt(e)});class rm extends Lt{_parse(e){const{ctx:t}=this._processInputParams(e);let n=t.data;return t.parsedType===Ue.undefined&&(n=this._def.defaultValue()),this._def.innerType._parse({data:n,path:t.path,parent:t})}removeDefault(){return this._def.innerType}}rm.create=(r,e)=>new rm({innerType:r,typeName:yt.ZodDefault,defaultValue:typeof e.default=="function"?e.default:()=>e.default,...Pt(e)});class nm extends Lt{_parse(e){const{ctx:t}=this._processInputParams(e),n={...t,common:{...t.common,issues:[]}},i=this._def.innerType._parse({data:n.data,path:n.path,parent:{...n}});return qp(i)?i.then(o=>({status:"valid",value:o.status==="valid"?o.value:this._def.catchValue({get error(){return new ko(n.common.issues)},input:n.data})})):{status:"valid",value:i.status==="valid"?i.value:this._def.catchValue({get error(){return new ko(n.common.issues)},input:n.data})}}removeCatch(){return this._def.innerType}}nm.create=(r,e)=>new nm({innerType:r,typeName:yt.ZodCatch,catchValue:typeof e.catch=="function"?e.catch:()=>e.catch,...Pt(e)});class ug extends Lt{_parse(e){if(this._getType(e)!==Ue.nan){const n=this._getOrReturnCtx(e);return Le(n,{code:be.invalid_type,expected:Ue.nan,received:n.parsedType}),bt}return{status:"valid",value:e.data}}}ug.create=r=>new ug({typeName:yt.ZodNaN,...Pt(r)});const AD=Symbol("zod_brand");class S6 extends Lt{_parse(e){const{ctx:t}=this._processInputParams(e),n=t.data;return this._def.type._parse({data:n,path:t.path,parent:t})}unwrap(){return this._def.type}}class $m extends Lt{_parse(e){const{status:t,ctx:n}=this._processInputParams(e);if(n.common.async)return(async()=>{const o=await this._def.in._parseAsync({data:n.data,path:n.path,parent:n});return o.status==="aborted"?bt:o.status==="dirty"?(t.dirty(),Wh(o.value)):this._def.out._parseAsync({data:o.value,path:n.path,parent:n})})();{const i=this._def.in._parseSync({data:n.data,path:n.path,parent:n});return i.status==="aborted"?bt:i.status==="dirty"?(t.dirty(),{status:"dirty",value:i.value}):this._def.out._parseSync({data:i.value,path:n.path,parent:n})}}static create(e,t){return new $m({in:e,out:t,typeName:yt.ZodPipeline})}}class im extends Lt{_parse(e){const t=this._def.innerType._parse(e),n=i=>(_u(i)&&(i.value=Object.freeze(i.value)),i);return qp(t)?t.then(i=>n(i)):n(t)}unwrap(){return this._def.innerType}}im.create=(r,e)=>new im({innerType:r,typeName:yt.ZodReadonly,...Pt(e)});function RC(r,e){const t=typeof r=="function"?r(e):typeof r=="string"?{message:r}:r;return typeof t=="string"?{message:t}:t}function BR(r,e={},t){return r?mf.create().superRefine((n,i)=>{var o,a;const c=r(n);if(c instanceof Promise)return c.then(d=>{var h,u;if(!d){const p=RC(e,n),v=(u=(h=p.fatal)!==null&&h!==void 0?h:t)!==null&&u!==void 0?u:!0;i.addIssue({code:"custom",...p,fatal:v})}});if(!c){const d=RC(e,n),h=(a=(o=d.fatal)!==null&&o!==void 0?o:t)!==null&&a!==void 0?a:!0;i.addIssue({code:"custom",...d,fatal:h})}}):mf.create()}const ID={object:nn.lazycreate};var yt;(function(r){r.ZodString="ZodString",r.ZodNumber="ZodNumber",r.ZodNaN="ZodNaN",r.ZodBigInt="ZodBigInt",r.ZodBoolean="ZodBoolean",r.ZodDate="ZodDate",r.ZodSymbol="ZodSymbol",r.ZodUndefined="ZodUndefined",r.ZodNull="ZodNull",r.ZodAny="ZodAny",r.ZodUnknown="ZodUnknown",r.ZodNever="ZodNever",r.ZodVoid="ZodVoid",r.ZodArray="ZodArray",r.ZodObject="ZodObject",r.ZodUnion="ZodUnion",r.ZodDiscriminatedUnion="ZodDiscriminatedUnion",r.ZodIntersection="ZodIntersection",r.ZodTuple="ZodTuple",r.ZodRecord="ZodRecord",r.ZodMap="ZodMap",r.ZodSet="ZodSet",r.ZodFunction="ZodFunction",r.ZodLazy="ZodLazy",r.ZodLiteral="ZodLiteral",r.ZodEnum="ZodEnum",r.ZodEffects="ZodEffects",r.ZodNativeEnum="ZodNativeEnum",r.ZodOptional="ZodOptional",r.ZodNullable="ZodNullable",r.ZodDefault="ZodDefault",r.ZodCatch="ZodCatch",r.ZodPromise="ZodPromise",r.ZodBranded="ZodBranded",r.ZodPipeline="ZodPipeline",r.ZodReadonly="ZodReadonly"})(yt||(yt={}));const RD=(r,e={message:`Input not instance of ${r.name}`})=>BR(t=>t instanceof r,e),bi=Pa.create,UR=Al.create,PD=ug.create,MD=Il.create,T6=Wp.create,Sb=bu.create,$D=cg.create,OD=Gp.create,ZD=Kp.create,LD=mf.create,qR=au.create,HD=gc.create,ND=lg.create,WR=Oa.create,Om=nn.create,DD=nn.strictCreate,VD=Yp.create,FD=h4.create,jD=Qp.create,zD=ws.create,GR=Xp.create,BD=dg.create,UD=wu.create,qD=af.create,WD=Jp.create,GD=em.create,KD=Rl.create,YD=tm.create,QD=vf.create,PC=Na.create,XD=ps.create,JD=Pl.create,eV=Na.createWithPreprocess,tV=$m.create,rV=()=>bi().optional(),nV=()=>UR().optional(),iV=()=>T6().optional(),oV={string:r=>Pa.create({...r,coerce:!0}),number:r=>Al.create({...r,coerce:!0}),boolean:r=>Wp.create({...r,coerce:!0}),bigint:r=>Il.create({...r,coerce:!0}),date:r=>bu.create({...r,coerce:!0})},aV=bt;var F=Object.freeze({__proto__:null,defaultErrorMap:pf,setErrorMap:oD,getErrorMap:og,makeIssue:ag,EMPTY_PATH:aD,addIssueToContext:Le,ParseStatus:ki,INVALID:bt,DIRTY:Wh,OK:Fi,isAborted:Cb,isDirty:kb,isValid:_u,isAsync:qp,get util(){return Qt},get objectUtil(){return xb},ZodParsedType:Ue,getParsedType:rc,ZodType:Lt,datetimeRegex:jR,ZodString:Pa,ZodNumber:Al,ZodBigInt:Il,ZodBoolean:Wp,ZodDate:bu,ZodSymbol:cg,ZodUndefined:Gp,ZodNull:Kp,ZodAny:mf,ZodUnknown:au,ZodNever:gc,ZodVoid:lg,ZodArray:Oa,ZodObject:nn,ZodUnion:Yp,ZodDiscriminatedUnion:h4,ZodIntersection:Qp,ZodTuple:ws,ZodRecord:Xp,ZodMap:dg,ZodSet:wu,ZodFunction:af,ZodLazy:Jp,ZodLiteral:em,ZodEnum:Rl,ZodNativeEnum:tm,ZodPromise:vf,ZodEffects:Na,ZodTransformer:Na,ZodOptional:ps,ZodNullable:Pl,ZodDefault:rm,ZodCatch:nm,ZodNaN:ug,BRAND:AD,ZodBranded:S6,ZodPipeline:$m,ZodReadonly:im,custom:BR,Schema:Lt,ZodSchema:Lt,late:ID,get ZodFirstPartyTypeKind(){return yt},coerce:oV,any:LD,array:WR,bigint:MD,boolean:T6,date:Sb,discriminatedUnion:FD,effect:PC,enum:KD,function:qD,instanceof:RD,intersection:jD,lazy:WD,literal:GD,map:BD,nan:PD,nativeEnum:YD,never:HD,null:ZD,nullable:JD,number:UR,object:Om,oboolean:iV,onumber:nV,optional:XD,ostring:rV,pipeline:tV,preprocess:eV,promise:QD,record:GR,set:UD,strictObject:DD,string:bi,symbol:$D,transformer:PC,tuple:zD,undefined:OD,union:VD,unknown:qR,void:ND,NEVER:aV,ZodIssueCode:be,quotelessJson:iD,ZodError:ko});const KR=()=>F.custom(r=>r===(r==null?void 0:r.toUpperCase()),r=>({code:F.ZodIssueCode.custom,validation:"uppercase",path:["method"],message:[`Provided HTTP method '${r}' must be in uppercase.`,"See RFC 7231 Section 4.1 for more information","https://www.rfc-editor.org/rfc/rfc7231#section-4.1"].join(" ")})),sV=()=>F.enum(["GET","POST","PUT","DELETE","PATCH","OPTIONS","HEAD","CONNECT","TRACE"],{errorMap:r=>{const{received:e,options:t}=r;return{message:["Invalid request method.",`Expected '${t.join(" | ")}', but received '${e}'.`,"See RFC 2615 Section 9 for more information","https://www.w3.org/Protocols/rfc2616/rfc2616-sec9.html"].join(" ")}}}),cV=()=>KR().pipe(sV()),lV=F.object({attributionReporting:F.object({eventSourceEligible:F.boolean().optional(),triggerEligible:F.boolean().optional()}).optional(),body:F.union([F.string(),F.instanceof(Blob),F.instanceof(ArrayBuffer),F.instanceof(FormData),F.instanceof(URLSearchParams),F.instanceof(ReadableStream)]).optional(),browsingTopics:F.boolean().optional(),cache:F.enum(["default","no-store","reload","no-cache","force-cache","only-if-cached"]).optional(),credentials:F.enum(["omit","same-origin","include"]).optional(),headers:F.record(F.string(),F.string()).optional().or(F.instanceof(Headers)),integrity:F.string().optional(),keepalive:F.boolean().optional(),method:cV().optional(),mode:F.enum(["same-origin","cors","no-cors","navigate","websocket"]).optional(),priority:F.enum(["low","high","auto"]).optional(),redirect:F.enum(["follow","error","manual"]).optional(),referrer:F.string().optional(),referrerPolicy:F.enum(["no-referrer","no-referrer-when-downgrade","origin","origin-when-cross-origin","same-origin","strict-origin","strict-origin-when-cross-origin","unsafe-url"]).optional(),signal:F.instanceof(AbortSignal).optional()}),MC=lV.extend({uri:F.string(),path:F.string().optional()}),dV=r=>e=>{var t;const{error:n,success:i,data:o}=KR().safeParse(e.method);if(e.method=i?o:(t=e.method)===null||t===void 0?void 0:t.toUpperCase(),n)for(const a of n.errors)console.warn(a.message);return e},uV=r=>e=>{const{strict:t,parse:n}={},i=t?MC:MC.passthrough();try{const o=i.parse(e);return n?o:void 0}catch(o){if(n)throw o;console.error("Invalid request options",o.message)}};class hV{get clients(){return Object.assign({},this._clients)}constructor(e){this._clients={},this.defaultHttpRequestHandler=new HR({"capitalize-method":dV(),"request-validation":uV()}),this.defaultHttpClientCtor=e}hasClient(e){return Object.keys(this._clients).includes(e)}configureClient(e,t){const n=typeof t=="string"?{baseUri:t}:t,i=typeof n=="function"?{onCreate:n}:n;return this._clients[e]=Object.assign(Object.assign({},this._clients[e]),i),this}}class fV extends Error{}const pV=r=>new RegExp("^(https?:\\/\\/)?((([a-z\\d]([a-z\\d-]*[a-z\\d])*)\\.?)+[a-z]{2,}|((\\d{1,3}\\.){3}\\d{1,3}))(\\:\\d+)?(\\/[-a-z\\d%_.~+]*)*(\\?[;&a-z\\d%_.~+=-]*)?(\\#[-a-z\\d_]*)?$","i").test(r);class mV{get defaultHttpRequestHandler(){return this.config.defaultHttpRequestHandler}constructor(e){this.config=e}hasClient(e){return Object.keys(this.config.clients).includes(e)}createClient(e){const t=this._resolveConfig(e),{baseUri:n,defaultScopes:i=[],onCreate:o,ctor:a=this.config.defaultHttpClientCtor,requestHandler:c=this.defaultHttpRequestHandler}=t,d={requestHandler:c},h=new a(n||"",d);return Object.assign(h,{defaultScopes:i}),o==null||o(h),h}createCustomClient(e){return this.createClient(e)}_resolveConfig(e){if(typeof e=="string"){const t=this.config.clients[e];if(!t&&pV(e))return{baseUri:e};if(!t)throw new fV(`No registered http client for key [${e}]`);return t}return e}}function vV(r,e){e===void 0&&(e={});var t=e.selector,n=oR(e,["selector"]);return new Tt(function(i){var o=new AbortController,a=o.signal,c=!0,d=n.signal;if(d)if(d.aborted)o.abort();else{var h=function(){a.aborted||o.abort()};d.addEventListener("abort",h),i.add(function(){return d.removeEventListener("abort",h)})}var u=Sn(Sn({},n),{signal:a}),p=function(v){c=!1,i.error(v)};return fetch(r,u).then(function(v){t?Zn(t(v)).subscribe(xr(i,void 0,function(){c=!1,i.complete()},p)):(c=!1,i.next(v),i.complete())}).catch(p),function(){c&&o.abort()}})}class su extends Error{constructor(e,t,n){super(e,n),this.response=t}}su.Name="HttpResponseError";class cu extends su{constructor(e,t,n){super(e,t,n),this.name=cu.Name,this.data=n==null?void 0:n.data}}cu.Name="HttpJsonResponseError";var gV=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};const gf=r=>gV(void 0,void 0,void 0,function*(){if(r.status===204)return Promise.resolve();try{const e=yield r.json();if(!r.ok)throw new cu("network response was not OK",r,{data:e});return e}catch(e){throw e instanceof cu?e:new cu("failed to parse response",r,{cause:e})}});var yV=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};const _V=r=>yV(void 0,void 0,void 0,function*(){var e,t,n;if(!r.ok)throw new Error("network response was not OK");if(r.status===204)throw new Error("no content");const i=(n=(t=(e=r.headers.get("content-disposition"))===null||e===void 0?void 0:e.split(";").find(o=>o.includes("filename=")))===null||t===void 0?void 0:t.replace("filename=",""))===null||n===void 0?void 0:n.trim();try{const o=yield r.blob();return{filename:i,blob:o}}catch{throw Error("failed to parse response")}});var $C=function(r,e){var t={};for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&e.indexOf(n)<0&&(t[n]=r[n]);if(r!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,n=Object.getOwnPropertySymbols(r);i<n.length;i++)e.indexOf(n[i])<0&&Object.prototype.propertyIsEnumerable.call(r,n[i])&&(t[n[i]]=r[n[i]]);return t};class bV{get request$(){return this._request$.asObservable()}get response$(){return this._response$.asObservable()}constructor(e,t){this.uri=e,this._request$=new Bn,this._response$=new Bn,this._abort$=new Bn,this.requestHandler=new HR(t==null?void 0:t.requestHandler),this.responseHandler=new nD(t==null?void 0:t.responseHandler),this._init()}_init(){}fetch$(e,t){return this._fetch$(e,t)}fetch(e,t){return zn(this.fetch$(e,t))}fetchAsync(e,t){return this.fetch(e,t)}json$(e,t){var n;const i=typeof(t==null?void 0:t.body)=="object"?JSON.stringify(t==null?void 0:t.body):t==null?void 0:t.body,o=(n=t==null?void 0:t.selector)!==null&&n!==void 0?n:gf,a=new Headers(t==null?void 0:t.headers);return a.append("Accept","application/json"),a.append("Content-Type","application/json"),this.fetch$(e,Object.assign(Object.assign({},t),{body:i,selector:o,headers:a}))}json(e,t){return zn(this.json$(e,t))}blob$(e,t){var n;const i=(n=t==null?void 0:t.selector)!==null&&n!==void 0?n:_V,o=Object.assign(Object.assign({},t),{selector:i});return this.fetch$(e,o)}blob(e,t){return zn(this.blob$(e,t))}jsonAsync(e,t){return this.json(e,t)}execute(e,t,n){return this[e](t,n)}abort(){this._abort$.next()}_fetch$(e,t){const n=t||{},{selector:i}=n,o=$C(n,["selector"]);return It(Object.assign(Object.assign({},o),{uri:this._resolveUrl(e)})).pipe(Wt(c=>this._prepareRequest(c)),Br(c=>this._request$.next(c)),Wt(c=>{var{uri:d,path:h}=c,u=$C(c,["uri","path"]);return vV(d,u)}),Wt(c=>this._prepareResponse(c)),Br(c=>this._response$.next(c)),Wt(c=>{if(i)try{return i(c)}catch(d){throw new su("failed to execute response selector",c,{cause:d})}return It(c)}),ou(this._abort$))}_prepareRequest(e){return this.requestHandler.process(e)}_prepareResponse(e){return this.responseHandler.process(e)}_resolveUrl(e){const{origin:t,pathname:n}=new URL(this.uri||window.location.origin),i=[n,e].join("/").replace(/\/{2,}/g,"/");return new URL(i,t).href}}class wV extends bV{constructor(){super(...arguments),this.defaultScopes=[]}fetch$(e,t){const n=Object.assign(t||{},{scopes:this.defaultScopes.concat((t==null?void 0:t.scopes)||[])});return super._fetch$(e,n)}}var OC=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};const A6={name:"http",configure:()=>new hV(wV),initialize:r=>OC(void 0,[r],void 0,function*({config:e,hasModule:t,requireInstance:n}){const i=new mV(e);if(t("auth")){const o=yield n("auth");i.defaultHttpRequestHandler.set("MSAL",a=>OC(void 0,void 0,void 0,function*(){const{scopes:c=[]}=a;if(c.length){const d=yield o.acquireToken({scopes:c});if(d){const h=new Headers(a.headers);return h.set("Authorization",`Bearer ${d.accessToken}`),Object.assign(Object.assign({},a),{headers:h})}}}))}return i})},xV=r=>({module:A6,configure:r}),YR=(r,e)=>({module:A6,configure:t=>{t.configureClient(r,e)}});var Ma;(function(r){r.V2="v2",r.Latest="4.0.2"})(Ma||(Ma={}));var wh=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};const CV=F.string().transform(r=>String(ep.coerce(r))),kV=F.object({clientId:F.string(),tenantId:F.string(),redirectUri:F.string().optional()}),EV=F.custom(),SV=F.object({client:kV.optional(),provider:EV.optional(),requiresAuth:F.boolean().optional(),version:CV});class TV extends Mm{constructor(){super(),this.version=Ma.Latest,this._set("version",()=>wh(this,void 0,void 0,function*(){return this.version}))}setClientConfig(e){this._set("client",()=>wh(this,void 0,void 0,function*(){return e}))}setRequiresAuth(e){this._set("requiresAuth",()=>wh(this,void 0,void 0,function*(){return e}))}setProvider(e){this._set("provider",()=>wh(this,void 0,void 0,function*(){return e}))}setVersion(e){this._set("version",()=>wh(this,void 0,void 0,function*(){return e}))}_processConfig(e){return wh(this,void 0,void 0,function*(){return SV.parseAsync(e)})}}/*! @azure/msal-browser v2.39.0 2024-06-06 *//*! *****************************************************************************
44
44
  Copyright (c) Microsoft Corporation.
45
45
 
46
46
  Permission to use, copy, modify, and/or distribute this software for any
@@ -71,11 +71,11 @@ Error: `+d.errorCode+`
71
71
  Error Description: `+d.errorMessage):(h=d,this.logger.error(`A non-MSALJS error was thrown while attempting to get the cloud instance discovery metadata.
72
72
  Error: `+h.name+`
73
73
  Error Description: `+h.message)),[2,null];case 4:return i||(this.logger.warning("The developer's authority was not found within the CloudInstanceDiscoveryMetadata returned from the network request."),this.logger.verbose("Creating custom Authority for custom domain scenario."),i=r.createCloudDiscoveryMetadataFromHost(this.hostnameAndPort)),[2,i]}})})},r.prototype.getCloudDiscoveryMetadataFromHarcodedValues=function(){return this.canonicalAuthority in FC?FC[this.canonicalAuthority]:null},r.prototype.isInKnownAuthorities=function(){var e=this,t=this.authorityOptions.knownAuthorities.filter(function(n){return Gt.getDomainFromUrl(n).toLowerCase()===e.hostnameAndPort});return t.length>0},r.generateAuthority=function(e,t){var n;if(t&&t.azureCloudInstance!==om.None){var i=t.tenant?t.tenant:G.DEFAULT_COMMON_TENANT;n=t.azureCloudInstance+"/"+i+"/"}return n||e},r.createCloudDiscoveryMetadataFromHost=function(e){return{preferred_network:e,preferred_cache:e,aliases:[e]}},r.getCloudDiscoveryMetadataFromNetworkResponse=function(e,t){for(var n=0;n<e.length;n++){var i=e[n];if(i.aliases.indexOf(t)>-1)return i}return null},r.prototype.getPreferredCache=function(){if(this.discoveryComplete())return this.metadata.preferred_cache;throw We.createEndpointDiscoveryIncompleteError("Discovery incomplete.")},r.prototype.isAlias=function(e){return this.metadata.aliases.indexOf(e)>-1},r.isPublicCloudAuthority=function(e){return G.KNOWN_PUBLIC_CLOUDS.indexOf(e)>=0},r.buildRegionalAuthorityString=function(e,t,n){var i=new Gt(e);i.validateAsUri();var o=i.getUrlComponents(),a=t+"."+o.HostNameAndPort;this.isPublicCloudAuthority(o.HostNameAndPort)&&(a=t+"."+G.REGIONAL_AUTH_PUBLIC_CLOUD_SUFFIX);var c=Gt.constructAuthorityUriFromObject(dr(dr({},i.getUrlComponents()),{HostNameAndPort:a})).urlString;return n?c+"?"+n:c},r.replaceWithRegionalInformation=function(e,t){return e.authorization_endpoint=r.buildRegionalAuthorityString(e.authorization_endpoint,t),e.token_endpoint=r.buildRegionalAuthorityString(e.token_endpoint,t,G.REGIONAL_AUTH_NON_MSI_QUERY_STRING),e.end_session_endpoint&&(e.end_session_endpoint=r.buildRegionalAuthorityString(e.end_session_endpoint,t)),e},r.transformCIAMAuthority=function(e){var t=e.endsWith(G.FORWARD_SLASH)?e:""+e+G.FORWARD_SLASH,n=new Gt(e),i=n.getUrlComponents();if(i.PathSegments.length===0&&i.HostNameAndPort.endsWith(G.CIAM_AUTH_URL)){var o=i.HostNameAndPort.split(".")[0];t=""+t+o+G.AAD_TENANT_DOMAIN_SUFFIX}return t},r.reservedTenantDomains=new Set(["{tenant}","{tenantid}",lu.COMMON,lu.CONSUMERS,lu.ORGANIZATIONS]),r}();/*! @azure/msal-common v13.3.3 2024-06-06 */var bg=function(){function r(){}return r.createDiscoveredInstance=function(e,t,n,i,o,a,c){return Et(this,void 0,void 0,function(){var d,h,u;return St(this,function(p){switch(p.label){case 0:a==null||a.addQueueMeasurement(ae.AuthorityFactoryCreateDiscoveredInstance,c),d=am.transformCIAMAuthority(e),h=r.createInstance(d,t,n,i,o,a,c),p.label=1;case 1:return p.trys.push([1,3,,4]),a==null||a.setPreQueueTime(ae.AuthorityResolveEndpointsAsync,c),[4,h.resolveEndpointsAsync()];case 2:return p.sent(),[2,h];case 3:throw u=p.sent(),We.createEndpointDiscoveryIncompleteError(u);case 4:return[2]}})})},r.createInstance=function(e,t,n,i,o,a,c){if(Ne.isEmpty(e))throw Or.createUrlEmptyError();return new am(e,t,n,i,o,a,c)},r}();/*! @azure/msal-common v13.3.3 2024-06-06 */var wg=function(){function r(){this.failedRequests=[],this.errors=[],this.cacheHits=0}return r.isServerTelemetryEntity=function(e,t){var n=e.indexOf(Yn.CACHE_KEY)===0,i=!0;return t&&(i=t.hasOwnProperty("failedRequests")&&t.hasOwnProperty("errors")&&t.hasOwnProperty("cacheHits")),n&&i},r}();/*! @azure/msal-common v13.3.3 2024-06-06 */var jC=function(){function r(){}return r.isThrottlingEntity=function(e,t){var n=!1;e&&(n=e.indexOf(Mp.THROTTLING_PREFIX)===0);var i=!0;return t&&(i=t.hasOwnProperty("throttleTime")),n&&i},r}();/*! @azure/msal-common v13.3.3 2024-06-06 */var YV={sendGetRequestAsync:function(){var r="Network interface - sendGetRequestAsync() has not been implemented for the Network interface.";return Promise.reject(it.createUnexpectedError(r))},sendPostRequestAsync:function(){var r="Network interface - sendPostRequestAsync() has not been implemented for the Network interface.";return Promise.reject(it.createUnexpectedError(r))}};/*! @azure/msal-common v13.3.3 2024-06-06 */var C0={missingKidError:{code:"missing_kid_error",desc:"The JOSE Header for the requested JWT, JWS or JWK object requires a keyId to be configured as the 'kid' header claim. No 'kid' value was provided."},missingAlgError:{code:"missing_alg_error",desc:"The JOSE Header for the requested JWT, JWS or JWK object requires an algorithm to be specified as the 'alg' header claim. No 'alg' value was provided."}},zC=function(r){ao(e,r);function e(t,n){var i=r.call(this,t,n)||this;return i.name="JoseHeaderError",Object.setPrototypeOf(i,e.prototype),i}return e.createMissingKidError=function(){return new e(C0.missingKidError.code,C0.missingKidError.desc)},e.createMissingAlgError=function(){return new e(C0.missingAlgError.code,C0.missingAlgError.desc)},e}(it);/*! @azure/msal-common v13.3.3 2024-06-06 */var QV=function(){function r(e){this.typ=e.typ,this.alg=e.alg,this.kid=e.kid}return r.getShrHeaderString=function(e){if(!e.kid)throw zC.createMissingKidError();if(!e.alg)throw zC.createMissingAlgError();var t=new r({typ:e.typ||Rb.Pop,kid:e.kid,alg:e.alg});return JSON.stringify(t)},r}();/*! @azure/msal-common v13.3.3 2024-06-06 */var XV=function(){function r(e,t){this.cacheOutcome=vl.NO_CACHE_HIT,this.cacheManager=t,this.apiId=e.apiId,this.correlationId=e.correlationId,this.wrapperSKU=e.wrapperSKU||G.EMPTY_STRING,this.wrapperVer=e.wrapperVer||G.EMPTY_STRING,this.telemetryCacheKey=Yn.CACHE_KEY+On.CACHE_KEY_SEPARATOR+e.clientId}return r.prototype.generateCurrentRequestHeaderValue=function(){var e=""+this.apiId+Yn.VALUE_SEPARATOR+this.cacheOutcome,t=[this.wrapperSKU,this.wrapperVer].join(Yn.VALUE_SEPARATOR),n=this.getRegionDiscoveryFields(),i=[e,n].join(Yn.VALUE_SEPARATOR);return[Yn.SCHEMA_VERSION,i,t].join(Yn.CATEGORY_SEPARATOR)},r.prototype.generateLastRequestHeaderValue=function(){var e=this.getLastRequests(),t=r.maxErrorsToSend(e),n=e.failedRequests.slice(0,2*t).join(Yn.VALUE_SEPARATOR),i=e.errors.slice(0,t).join(Yn.VALUE_SEPARATOR),o=e.errors.length,a=t<o?Yn.OVERFLOW_TRUE:Yn.OVERFLOW_FALSE,c=[o,a].join(Yn.VALUE_SEPARATOR);return[Yn.SCHEMA_VERSION,e.cacheHits,n,i,c].join(Yn.CATEGORY_SEPARATOR)},r.prototype.cacheFailedRequest=function(e){var t=this.getLastRequests();t.errors.length>=Yn.MAX_CACHED_ERRORS&&(t.failedRequests.shift(),t.failedRequests.shift(),t.errors.shift()),t.failedRequests.push(this.apiId,this.correlationId),Ne.isEmpty(e.subError)?Ne.isEmpty(e.errorCode)?e&&e.toString()?t.errors.push(e.toString()):t.errors.push(Yn.UNKNOWN_ERROR):t.errors.push(e.errorCode):t.errors.push(e.subError),this.cacheManager.setServerTelemetry(this.telemetryCacheKey,t)},r.prototype.incrementCacheHits=function(){var e=this.getLastRequests();return e.cacheHits+=1,this.cacheManager.setServerTelemetry(this.telemetryCacheKey,e),e.cacheHits},r.prototype.getLastRequests=function(){var e=new wg,t=this.cacheManager.getServerTelemetry(this.telemetryCacheKey);return t||e},r.prototype.clearTelemetryCache=function(){var e=this.getLastRequests(),t=r.maxErrorsToSend(e),n=e.errors.length;if(t===n)this.cacheManager.removeItem(this.telemetryCacheKey);else{var i=new wg;i.failedRequests=e.failedRequests.slice(t*2),i.errors=e.errors.slice(t),this.cacheManager.setServerTelemetry(this.telemetryCacheKey,i)}},r.maxErrorsToSend=function(e){var t,n=0,i=0,o=e.errors.length;for(t=0;t<o;t++){var a=e.failedRequests[2*t]||G.EMPTY_STRING,c=e.failedRequests[2*t+1]||G.EMPTY_STRING,d=e.errors[t]||G.EMPTY_STRING;if(i+=a.toString().length+c.toString().length+d.length+3,i<Yn.MAX_LAST_HEADER_BYTES)n+=1;else break}return n},r.prototype.getRegionDiscoveryFields=function(){var e=[];return e.push(this.regionUsed||G.EMPTY_STRING),e.push(this.regionSource||G.EMPTY_STRING),e.push(this.regionOutcome||G.EMPTY_STRING),e.join(",")},r.prototype.updateRegionDiscoveryMetadata=function(e){this.regionUsed=e.region_used,this.regionSource=e.region_source,this.regionOutcome=e.region_outcome},r.prototype.setCacheOutcome=function(e){this.cacheOutcome=e},r}();/*! @azure/msal-common v13.3.3 2024-06-06 */var rP=function(){function r(e,t,n,i,o,a){this.authority=t,this.libraryName=i,this.libraryVersion=o,this.applicationTelemetry=a,this.clientId=e,this.logger=n,this.callbacks=new Map,this.eventsByCorrelationId=new Map,this.queueMeasurements=new Map,this.preQueueTimeByCorrelationId=new Map}return r.prototype.startPerformanceMeasurement=function(e,t){return{}},r.prototype.startPerformanceMeasuremeant=function(e,t){return{}},r.prototype.getIntFields=function(){return zV},r.prototype.getPreQueueTime=function(e,t){var n=this.preQueueTimeByCorrelationId.get(t);if(n){if(n.name!==e){this.logger.trace("PerformanceClient.getPreQueueTime: no pre-queue time found for "+e+", unable to add queue measurement");return}}else{this.logger.trace("PerformanceClient.getPreQueueTime: no pre-queue times found for correlationId: "+t+", unable to add queue measurement");return}return n.time},r.prototype.calculateQueuedTime=function(e,t){return e<1?(this.logger.trace("PerformanceClient: preQueueTime should be a positive integer and not "+e),0):t<1?(this.logger.trace("PerformanceClient: currentTime should be a positive integer and not "+t),0):t<e?(this.logger.trace("PerformanceClient: currentTime is less than preQueueTime, check how time is being retrieved"),0):t-e},r.prototype.addQueueMeasurement=function(e,t,n,i){if(!t){this.logger.trace("PerformanceClient.addQueueMeasurement: correlationId not provided for "+e+", cannot add queue measurement");return}if(n===0)this.logger.trace("PerformanceClient.addQueueMeasurement: queue time provided for "+e+" is "+n);else if(!n){this.logger.trace("PerformanceClient.addQueueMeasurement: no queue time provided for "+e);return}var o={eventName:e,queueTime:n,manuallyCompleted:i},a=this.queueMeasurements.get(t);if(a)a.push(o),this.queueMeasurements.set(t,a);else{this.logger.trace("PerformanceClient.addQueueMeasurement: adding correlationId "+t+" to queue measurements");var c=[o];this.queueMeasurements.set(t,c)}this.preQueueTimeByCorrelationId.delete(t)},r.prototype.startMeasurement=function(e,t){var n=this,i,o,a=t||this.generateId();t||this.logger.info("PerformanceClient: No correlation id provided for "+e+", generating",a),this.logger.trace("PerformanceClient: Performance measurement started for "+e,a);var c=this.startPerformanceMeasuremeant(e,a);c.startMeasurement();var d={eventId:this.generateId(),status:yg.InProgress,authority:this.authority,libraryName:this.libraryName,libraryVersion:this.libraryVersion,clientId:this.clientId,name:e,startTimeMs:Date.now(),correlationId:a,appName:(i=this.applicationTelemetry)===null||i===void 0?void 0:i.appName,appVersion:(o=this.applicationTelemetry)===null||o===void 0?void 0:o.appVersion};return this.cacheEventByCorrelationId(d),{endMeasurement:function(h){return n.endMeasurement(dr(dr({},d),h),c)},discardMeasurement:function(){return n.discardMeasurements(d.correlationId)},addStaticFields:function(h){return n.addStaticFields(h,d.correlationId)},increment:function(h){return n.increment(h,d.correlationId)},measurement:c,event:d}},r.prototype.endMeasurement=function(e,t){var n=this,i,o,a=this.eventsByCorrelationId.get(e.correlationId);if(!a)return this.logger.trace("PerformanceClient: Measurement not found for "+e.eventId,e.correlationId),null;var c=e.eventId===a.eventId,d={totalQueueTime:0,totalQueueCount:0,manuallyCompletedCount:0};c?(d=this.getQueueInfo(e.correlationId),this.discardCache(a.correlationId)):(i=a.incompleteSubMeasurements)===null||i===void 0||i.delete(e.eventId),t==null||t.endMeasurement();var h=t==null?void 0:t.flushMeasurement();if(!h)return this.logger.trace("PerformanceClient: Performance measurement not taken",a.correlationId),null;if(this.logger.trace("PerformanceClient: Performance measurement ended for "+e.name+": "+h+" ms",e.correlationId),!c)return a[e.name+"DurationMs"]=Math.floor(h),dr({},a);var u=dr(dr({},a),e),p=0;return(o=u.incompleteSubMeasurements)===null||o===void 0||o.forEach(function(v){n.logger.trace("PerformanceClient: Incomplete submeasurement "+v.name+" found for "+e.name,u.correlationId),p++}),u.incompleteSubMeasurements=void 0,u=dr(dr({},u),{durationMs:Math.round(h),queuedTimeMs:d.totalQueueTime,queuedCount:d.totalQueueCount,queuedManuallyCompletedCount:d.manuallyCompletedCount,status:yg.Completed,incompleteSubsCount:p}),this.truncateIntegralFields(u,this.getIntFields()),this.emitEvents([u],e.correlationId),u},r.prototype.addStaticFields=function(e,t){this.logger.trace("PerformanceClient: Updating static fields");var n=this.eventsByCorrelationId.get(t);n?this.eventsByCorrelationId.set(t,dr(dr({},n),e)):this.logger.trace("PerformanceClient: Event not found for",t)},r.prototype.increment=function(e,t){this.logger.trace("PerformanceClient: Updating counters");var n=this.eventsByCorrelationId.get(t);if(n)for(var i in e)n.hasOwnProperty(i)||(n[i]=0),n[i]+=e[i];else this.logger.trace("PerformanceClient: Event not found for",t)},r.prototype.cacheEventByCorrelationId=function(e){var t=this.eventsByCorrelationId.get(e.correlationId);t?(this.logger.trace("PerformanceClient: Performance measurement for "+e.name+" added/updated",e.correlationId),t.incompleteSubMeasurements=t.incompleteSubMeasurements||new Map,t.incompleteSubMeasurements.set(e.eventId,{name:e.name,startTimeMs:e.startTimeMs})):(this.logger.trace("PerformanceClient: Performance measurement for "+e.name+" started",e.correlationId),this.eventsByCorrelationId.set(e.correlationId,dr({},e)))},r.prototype.getQueueInfo=function(e){var t=this.queueMeasurements.get(e);t||this.logger.trace("PerformanceClient: no queue measurements found for for correlationId: "+e);var n=0,i=0,o=0;return t==null||t.forEach(function(a){n+=a.queueTime,i++,o+=a.manuallyCompleted?1:0}),{totalQueueTime:n,totalQueueCount:i,manuallyCompletedCount:o}},r.prototype.discardMeasurements=function(e){this.logger.trace("PerformanceClient: Performance measurements discarded",e),this.eventsByCorrelationId.delete(e)},r.prototype.discardCache=function(e){this.discardMeasurements(e),this.logger.trace("PerformanceClient: QueueMeasurements discarded",e),this.queueMeasurements.delete(e),this.logger.trace("PerformanceClient: Pre-queue times discarded",e),this.preQueueTimeByCorrelationId.delete(e)},r.prototype.addPerformanceCallback=function(e){var t=this.generateId();return this.callbacks.set(t,e),this.logger.verbose("PerformanceClient: Performance callback registered with id: "+t),t},r.prototype.removePerformanceCallback=function(e){var t=this.callbacks.delete(e);return t?this.logger.verbose("PerformanceClient: Performance callback "+e+" removed."):this.logger.verbose("PerformanceClient: Performance callback "+e+" not removed."),t},r.prototype.emitEvents=function(e,t){var n=this;this.logger.verbose("PerformanceClient: Emitting performance events",t),this.callbacks.forEach(function(i,o){n.logger.trace("PerformanceClient: Emitting event to callback "+o,t),i.apply(null,[e])})},r.prototype.truncateIntegralFields=function(e,t){t.forEach(function(n){n in e&&typeof e[n]=="number"&&(e[n]=Math.floor(e[n]))})},r}();/*! @azure/msal-common v13.3.3 2024-06-06 */var BC=function(){function r(){}return r.prototype.startMeasurement=function(){},r.prototype.endMeasurement=function(){},r.prototype.flushMeasurement=function(){return null},r}(),JV=function(r){ao(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.generateId=function(){return"callback-id"},e.prototype.startPerformanceMeasuremeant=function(){return new BC},e.prototype.startPerformanceMeasurement=function(){return new BC},e.prototype.calculateQueuedTime=function(t,n){return 0},e.prototype.addQueueMeasurement=function(t,n,i){},e.prototype.setPreQueueTime=function(t,n){},e}(rP);/*! @azure/msal-browser v2.39.0 2024-06-06 */var xe={pkceNotGenerated:{code:"pkce_not_created",desc:"The PKCE code challenge and verifier could not be generated."},cryptoDoesNotExist:{code:"crypto_nonexistent",desc:"The crypto object or function is not available."},httpMethodNotImplementedError:{code:"http_method_not_implemented",desc:"The HTTP method given has not been implemented in this library."},emptyNavigateUriError:{code:"empty_navigate_uri",desc:"Navigation URI is empty. Please check stack trace for more info."},hashEmptyError:{code:"hash_empty_error",desc:"Hash value cannot be processed because it is empty. Please verify that your redirectUri is not clearing the hash. For more visit: aka.ms/msaljs/browser-errors."},hashDoesNotContainStateError:{code:"no_state_in_hash",desc:"Hash does not contain state. Please verify that the request originated from msal."},hashDoesNotContainKnownPropertiesError:{code:"hash_does_not_contain_known_properties",desc:"Hash does not contain known properites. Please verify that your redirectUri is not changing the hash. For more visit: aka.ms/msaljs/browser-errors."},unableToParseStateError:{code:"unable_to_parse_state",desc:"Unable to parse state. Please verify that the request originated from msal."},stateInteractionTypeMismatchError:{code:"state_interaction_type_mismatch",desc:"Hash contains state but the interaction type does not match the caller."},interactionInProgress:{code:"interaction_in_progress",desc:"Interaction is currently in progress. Please ensure that this interaction has been completed before calling an interactive API. For more visit: aka.ms/msaljs/browser-errors."},popupWindowError:{code:"popup_window_error",desc:"Error opening popup window. This can happen if you are using IE or if popups are blocked in the browser."},emptyWindowError:{code:"empty_window_error",desc:"window.open returned null or undefined window object."},userCancelledError:{code:"user_cancelled",desc:"User cancelled the flow."},monitorPopupTimeoutError:{code:"monitor_window_timeout",desc:"Token acquisition in popup failed due to timeout. For more visit: aka.ms/msaljs/browser-errors."},monitorIframeTimeoutError:{code:"monitor_window_timeout",desc:"Token acquisition in iframe failed due to timeout. For more visit: aka.ms/msaljs/browser-errors."},redirectInIframeError:{code:"redirect_in_iframe",desc:"Redirects are not supported for iframed or brokered applications. Please ensure you are using MSAL.js in a top frame of the window if using the redirect APIs, or use the popup APIs."},blockTokenRequestsInHiddenIframeError:{code:"block_iframe_reload",desc:"Request was blocked inside an iframe because MSAL detected an authentication response. For more visit: aka.ms/msaljs/browser-errors"},blockAcquireTokenInPopupsError:{code:"block_nested_popups",desc:"Request was blocked inside a popup because MSAL detected it was running in a popup."},iframeClosedPrematurelyError:{code:"iframe_closed_prematurely",desc:"The iframe being monitored was closed prematurely."},silentLogoutUnsupportedError:{code:"silent_logout_unsupported",desc:"Silent logout not supported. Please call logoutRedirect or logoutPopup instead."},noAccountError:{code:"no_account_error",desc:"No account object provided to acquireTokenSilent and no active account has been set. Please call setActiveAccount or provide an account on the request."},silentPromptValueError:{code:"silent_prompt_value_error",desc:"The value given for the prompt value is not valid for silent requests - must be set to 'none' or 'no_session'."},noTokenRequestCacheError:{code:"no_token_request_cache_error",desc:"No token request found in cache."},unableToParseTokenRequestCacheError:{code:"unable_to_parse_token_request_cache_error",desc:"The cached token request could not be parsed."},noCachedAuthorityError:{code:"no_cached_authority_error",desc:"No cached authority found."},authRequestNotSet:{code:"auth_request_not_set_error",desc:"Auth Request not set. Please ensure initiateAuthRequest was called from the InteractionHandler"},invalidCacheType:{code:"invalid_cache_type",desc:"Invalid cache type"},notInBrowserEnvironment:{code:"non_browser_environment",desc:"Login and token requests are not supported in non-browser environments."},databaseNotOpen:{code:"database_not_open",desc:"Database is not open!"},noNetworkConnectivity:{code:"no_network_connectivity",desc:"No network connectivity. Check your internet connection."},postRequestFailed:{code:"post_request_failed",desc:"Network request failed: If the browser threw a CORS error, check that the redirectUri is registered in the Azure App Portal as type 'SPA'"},getRequestFailed:{code:"get_request_failed",desc:"Network request failed. Please check the network trace to determine root cause."},failedToParseNetworkResponse:{code:"failed_to_parse_response",desc:"Failed to parse network response. Check network trace."},unableToLoadTokenError:{code:"unable_to_load_token",desc:"Error loading token to cache."},signingKeyNotFoundInStorage:{code:"crypto_key_not_found",desc:"Cryptographic Key or Keypair not found in browser storage."},authCodeRequired:{code:"auth_code_required",desc:"An authorization code must be provided (as the `code` property on the request) to this flow."},authCodeOrNativeAccountRequired:{code:"auth_code_or_nativeAccountId_required",desc:"An authorization code or nativeAccountId must be provided to this flow."},spaCodeAndNativeAccountPresent:{code:"spa_code_and_nativeAccountId_present",desc:"Request cannot contain both spa code and native account id."},databaseUnavailable:{code:"database_unavailable",desc:"IndexedDB, which is required for persistent cryptographic key storage, is unavailable. This may be caused by browser privacy features which block persistent storage in third-party contexts."},unableToAcquireTokenFromNativePlatform:{code:"unable_to_acquire_token_from_native_platform",desc:"Unable to acquire token from native platform. For a list of possible reasons visit aka.ms/msaljs/browser-errors."},nativeHandshakeTimeout:{code:"native_handshake_timeout",desc:"Timed out while attempting to establish connection to browser extension"},nativeExtensionNotInstalled:{code:"native_extension_not_installed",desc:"Native extension is not installed. If you think this is a mistake call the initialize function."},nativeConnectionNotEstablished:{code:"native_connection_not_established",desc:"Connection to native platform has not been established. Please install a compatible browser extension and run initialize(). For more please visit aka.ms/msaljs/browser-errors."},nativeBrokerCalledBeforeInitialize:{code:"native_broker_called_before_initialize",desc:"You must call and await the initialize function before attempting to call any other MSAL API when native brokering is enabled. For more please visit aka.ms/msaljs/browser-errors."},nativePromptNotSupported:{code:"native_prompt_not_supported",desc:"The provided prompt is not supported by the native platform. This request should be routed to the web based flow."}},Me=function(r){ri(e,r);function e(t,n){var i=r.call(this,t,n)||this;return Object.setPrototypeOf(i,e.prototype),i.name="BrowserAuthError",i}return e.createPkceNotGeneratedError=function(t){return new e(xe.pkceNotGenerated.code,xe.pkceNotGenerated.desc+" Detail:"+t)},e.createCryptoNotAvailableError=function(t){return new e(xe.cryptoDoesNotExist.code,xe.cryptoDoesNotExist.desc+" Detail:"+t)},e.createHttpMethodNotImplementedError=function(t){return new e(xe.httpMethodNotImplementedError.code,xe.httpMethodNotImplementedError.desc+" Given Method: "+t)},e.createEmptyNavigationUriError=function(){return new e(xe.emptyNavigateUriError.code,xe.emptyNavigateUriError.desc)},e.createEmptyHashError=function(t){return new e(xe.hashEmptyError.code,xe.hashEmptyError.desc+" Given Url: "+t)},e.createHashDoesNotContainStateError=function(){return new e(xe.hashDoesNotContainStateError.code,xe.hashDoesNotContainStateError.desc)},e.createHashDoesNotContainKnownPropertiesError=function(){return new e(xe.hashDoesNotContainKnownPropertiesError.code,xe.hashDoesNotContainKnownPropertiesError.desc)},e.createUnableToParseStateError=function(){return new e(xe.unableToParseStateError.code,xe.unableToParseStateError.desc)},e.createStateInteractionTypeMismatchError=function(){return new e(xe.stateInteractionTypeMismatchError.code,xe.stateInteractionTypeMismatchError.desc)},e.createInteractionInProgressError=function(){return new e(xe.interactionInProgress.code,xe.interactionInProgress.desc)},e.createPopupWindowError=function(t){var n=xe.popupWindowError.desc;return n=Ne.isEmpty(t)?n:n+" Details: "+t,new e(xe.popupWindowError.code,n)},e.createEmptyWindowCreatedError=function(){return new e(xe.emptyWindowError.code,xe.emptyWindowError.desc)},e.createUserCancelledError=function(){return new e(xe.userCancelledError.code,xe.userCancelledError.desc)},e.createMonitorPopupTimeoutError=function(){return new e(xe.monitorPopupTimeoutError.code,xe.monitorPopupTimeoutError.desc)},e.createMonitorIframeTimeoutError=function(){return new e(xe.monitorIframeTimeoutError.code,xe.monitorIframeTimeoutError.desc)},e.createRedirectInIframeError=function(t){return new e(xe.redirectInIframeError.code,xe.redirectInIframeError.desc+" (window.parent !== window) => "+t)},e.createBlockReloadInHiddenIframeError=function(){return new e(xe.blockTokenRequestsInHiddenIframeError.code,xe.blockTokenRequestsInHiddenIframeError.desc)},e.createBlockAcquireTokenInPopupsError=function(){return new e(xe.blockAcquireTokenInPopupsError.code,xe.blockAcquireTokenInPopupsError.desc)},e.createIframeClosedPrematurelyError=function(){return new e(xe.iframeClosedPrematurelyError.code,xe.iframeClosedPrematurelyError.desc)},e.createSilentLogoutUnsupportedError=function(){return new e(xe.silentLogoutUnsupportedError.code,xe.silentLogoutUnsupportedError.desc)},e.createNoAccountError=function(){return new e(xe.noAccountError.code,xe.noAccountError.desc)},e.createSilentPromptValueError=function(t){return new e(xe.silentPromptValueError.code,xe.silentPromptValueError.desc+" Given value: "+t)},e.createUnableToParseTokenRequestCacheError=function(){return new e(xe.unableToParseTokenRequestCacheError.code,xe.unableToParseTokenRequestCacheError.desc)},e.createNoTokenRequestCacheError=function(){return new e(xe.noTokenRequestCacheError.code,xe.noTokenRequestCacheError.desc)},e.createAuthRequestNotSetError=function(){return new e(xe.authRequestNotSet.code,xe.authRequestNotSet.desc)},e.createNoCachedAuthorityError=function(){return new e(xe.noCachedAuthorityError.code,xe.noCachedAuthorityError.desc)},e.createInvalidCacheTypeError=function(){return new e(xe.invalidCacheType.code,""+xe.invalidCacheType.desc)},e.createNonBrowserEnvironmentError=function(){return new e(xe.notInBrowserEnvironment.code,xe.notInBrowserEnvironment.desc)},e.createDatabaseNotOpenError=function(){return new e(xe.databaseNotOpen.code,xe.databaseNotOpen.desc)},e.createNoNetworkConnectivityError=function(){return new e(xe.noNetworkConnectivity.code,xe.noNetworkConnectivity.desc)},e.createPostRequestFailedError=function(t,n){return new e(xe.postRequestFailed.code,xe.postRequestFailed.desc+" | Network client threw: "+t+" | Attempted to reach: "+n.split("?")[0])},e.createGetRequestFailedError=function(t,n){return new e(xe.getRequestFailed.code,xe.getRequestFailed.desc+" | Network client threw: "+t+" | Attempted to reach: "+n.split("?")[0])},e.createFailedToParseNetworkResponseError=function(t){return new e(xe.failedToParseNetworkResponse.code,xe.failedToParseNetworkResponse.desc+" | Attempted to reach: "+t.split("?")[0])},e.createUnableToLoadTokenError=function(t){return new e(xe.unableToLoadTokenError.code,xe.unableToLoadTokenError.desc+" | "+t)},e.createSigningKeyNotFoundInStorageError=function(t){return new e(xe.signingKeyNotFoundInStorage.code,xe.signingKeyNotFoundInStorage.desc+" | No match found for KeyId: "+t)},e.createAuthCodeRequiredError=function(){return new e(xe.authCodeRequired.code,xe.authCodeRequired.desc)},e.createAuthCodeOrNativeAccountIdRequiredError=function(){return new e(xe.authCodeOrNativeAccountRequired.code,xe.authCodeOrNativeAccountRequired.desc)},e.createSpaCodeAndNativeAccountIdPresentError=function(){return new e(xe.spaCodeAndNativeAccountPresent.code,xe.spaCodeAndNativeAccountPresent.desc)},e.createDatabaseUnavailableError=function(){return new e(xe.databaseUnavailable.code,xe.databaseUnavailable.desc)},e.createUnableToAcquireTokenFromNativePlatformError=function(){return new e(xe.unableToAcquireTokenFromNativePlatform.code,xe.unableToAcquireTokenFromNativePlatform.desc)},e.createNativeHandshakeTimeoutError=function(){return new e(xe.nativeHandshakeTimeout.code,xe.nativeHandshakeTimeout.desc)},e.createNativeExtensionNotInstalledError=function(){return new e(xe.nativeExtensionNotInstalled.code,xe.nativeExtensionNotInstalled.desc)},e.createNativeConnectionNotEstablishedError=function(){return new e(xe.nativeConnectionNotEstablished.code,xe.nativeConnectionNotEstablished.desc)},e.createNativeBrokerCalledBeforeInitialize=function(){return new e(xe.nativeBrokerCalledBeforeInitialize.code,xe.nativeBrokerCalledBeforeInitialize.desc)},e.createNativePromptParameterNotSupportedError=function(){return new e(xe.nativePromptNotSupported.code,xe.nativePromptNotSupported.desc)},e}(it);/*! @azure/msal-browser v2.39.0 2024-06-06 */var Ra={INVALID_GRANT_ERROR:"invalid_grant",POPUP_WIDTH:483,POPUP_HEIGHT:600,POPUP_NAME_PREFIX:"msal",DEFAULT_POLL_INTERVAL_MS:30,MSAL_SKU:"msal.js.browser"},cp={CHANNEL_ID:"53ee284d-920a-4b59-9d30-a60315b26836",PREFERRED_EXTENSION_ID:"ppnbnpeolgkicgegkbkbjmhlideopiji",MATS_TELEMETRY:"MATS"},sc;(function(r){r.HandshakeRequest="Handshake",r.HandshakeResponse="HandshakeResponse",r.GetToken="GetToken",r.Response="Response"})(sc||(sc={}));var Cn;(function(r){r.LocalStorage="localStorage",r.SessionStorage="sessionStorage",r.MemoryStorage="memoryStorage"})(Cn||(Cn={}));var ls;(function(r){r.GET="GET",r.POST="POST"})(ls||(ls={}));var er;(function(r){r.AUTHORITY="authority",r.ACQUIRE_TOKEN_ACCOUNT="acquireToken.account",r.SESSION_STATE="session.state",r.REQUEST_STATE="request.state",r.NONCE_IDTOKEN="nonce.id_token",r.ORIGIN_URI="request.origin",r.RENEW_STATUS="token.renew.status",r.URL_HASH="urlHash",r.REQUEST_PARAMS="request.params",r.SCOPES="scopes",r.INTERACTION_STATUS_KEY="interaction.status",r.CCS_CREDENTIAL="ccs.credential",r.CORRELATION_ID="request.correlationId",r.NATIVE_REQUEST="request.native",r.REDIRECT_CONTEXT="request.redirect.context"})(er||(er={}));var as;(function(r){r.ACCOUNT_KEYS="msal.account.keys",r.TOKEN_KEYS="msal.token.keys"})(as||(as={}));var Jh;(function(r){r.WRAPPER_SKU="wrapper.sku",r.WRAPPER_VER="wrapper.version"})(Jh||(Jh={}));var $r;(function(r){r[r.acquireTokenRedirect=861]="acquireTokenRedirect",r[r.acquireTokenPopup=862]="acquireTokenPopup",r[r.ssoSilent=863]="ssoSilent",r[r.acquireTokenSilent_authCode=864]="acquireTokenSilent_authCode",r[r.handleRedirectPromise=865]="handleRedirectPromise",r[r.acquireTokenByCode=866]="acquireTokenByCode",r[r.acquireTokenSilent_silentFlow=61]="acquireTokenSilent_silentFlow",r[r.logout=961]="logout",r[r.logoutPopup=962]="logoutPopup"})($r||($r={}));var et;(function(r){r.Redirect="redirect",r.Popup="popup",r.Silent="silent",r.None="none"})(et||(et={}));var UC;(function(r){r.Startup="startup",r.Login="login",r.Logout="logout",r.AcquireToken="acquireToken",r.SsoSilent="ssoSilent",r.HandleRedirect="handleRedirect",r.None="none"})(UC||(UC={}));var qC={scopes:Zm},bf="jwk",WC;(function(r){r.React="@azure/msal-react",r.Angular="@azure/msal-angular"})(WC||(WC={}));var Ob="msal.db",eF=1,tF=Ob+".keys",oo;(function(r){r[r.Default=0]="Default",r[r.AccessToken=1]="AccessToken",r[r.AccessTokenAndRefreshToken=2]="AccessTokenAndRefreshToken",r[r.RefreshToken=3]="RefreshToken",r[r.RefreshTokenAndNetwork=4]="RefreshTokenAndNetwork",r[r.Skip=5]="Skip"})(oo||(oo={}));/*! @azure/msal-browser v2.39.0 2024-06-06 */var eo={redirectUriNotSet:{code:"redirect_uri_empty",desc:"A redirect URI is required for all calls, and none has been set."},postLogoutUriNotSet:{code:"post_logout_uri_empty",desc:"A post logout redirect has not been set."},storageNotSupportedError:{code:"storage_not_supported",desc:"Given storage configuration option was not supported."},noRedirectCallbacksSet:{code:"no_redirect_callbacks",desc:"No redirect callbacks have been set. Please call setRedirectCallbacks() with the appropriate function arguments before continuing. More information is available here: https://github.com/AzureAD/microsoft-authentication-library-for-js/wiki/MSAL-basics."},stubPcaInstanceCalled:{code:"stubbed_public_client_application_called",desc:"Stub instance of Public Client Application was called. If using msal-react, please ensure context is not used without a provider. For more visit: aka.ms/msaljs/browser-errors"},inMemRedirectUnavailable:{code:"in_mem_redirect_unavailable",desc:"Redirect cannot be supported. In-memory storage was selected and storeAuthStateInCookie=false, which would cause the library to be unable to handle the incoming hash. If you would like to use the redirect API, please use session/localStorage or set storeAuthStateInCookie=true."},entropyNotProvided:{code:"entropy_not_provided",desc:"The available browser crypto interface requires entropy set via system.cryptoOptions.entropy configuration option."}},xg=function(r){ri(e,r);function e(t,n){var i=r.call(this,t,n)||this;return i.name="BrowserConfigurationAuthError",Object.setPrototypeOf(i,e.prototype),i}return e.createRedirectUriEmptyError=function(){return new e(eo.redirectUriNotSet.code,eo.redirectUriNotSet.desc)},e.createPostLogoutRedirectUriEmptyError=function(){return new e(eo.postLogoutUriNotSet.code,eo.postLogoutUriNotSet.desc)},e.createStorageNotSupportedError=function(t){return new e(eo.storageNotSupportedError.code,eo.storageNotSupportedError.desc+" Given Location: "+t)},e.createRedirectCallbacksNotSetError=function(){return new e(eo.noRedirectCallbacksSet.code,eo.noRedirectCallbacksSet.desc)},e.createStubPcaInstanceCalledError=function(){return new e(eo.stubPcaInstanceCalled.code,eo.stubPcaInstanceCalled.desc)},e.createInMemoryRedirectUnavailableError=function(){return new e(eo.inMemRedirectUnavailable.code,eo.inMemRedirectUnavailable.desc)},e.createEntropyNotProvided=function(){return new e(eo.entropyNotProvided.code,eo.entropyNotProvided.desc)},e}(it);/*! @azure/msal-browser v2.39.0 2024-06-06 */var GC=function(){function r(e){this.validateWindowStorage(e),this.windowStorage=window[e]}return r.prototype.validateWindowStorage=function(e){if(e!==Cn.LocalStorage&&e!==Cn.SessionStorage)throw xg.createStorageNotSupportedError(e);var t=!!window[e];if(!t)throw xg.createStorageNotSupportedError(e)},r.prototype.getItem=function(e){return this.windowStorage.getItem(e)},r.prototype.setItem=function(e,t){this.windowStorage.setItem(e,t)},r.prototype.removeItem=function(e){this.windowStorage.removeItem(e)},r.prototype.getKeys=function(){return Object.keys(this.windowStorage)},r.prototype.containsKey=function(e){return this.windowStorage.hasOwnProperty(e)},r}();/*! @azure/msal-browser v2.39.0 2024-06-06 */var Zb=function(){function r(){this.cache=new Map}return r.prototype.getItem=function(e){return this.cache.get(e)||null},r.prototype.setItem=function(e,t){this.cache.set(e,t)},r.prototype.removeItem=function(e){this.cache.delete(e)},r.prototype.getKeys=function(){var e=[];return this.cache.forEach(function(t,n){e.push(n)}),e},r.prototype.containsKey=function(e){return this.cache.has(e)},r.prototype.clear=function(){this.cache.clear()},r}();/*! @azure/msal-browser v2.39.0 2024-06-06 */var nP=function(){function r(){}return r.extractBrowserRequestState=function(e,t){if(Ne.isEmpty(t))return null;try{var n=fc.parseRequestState(e,t);return n.libraryState.meta}catch(i){throw We.createInvalidStateError(t,i)}},r.parseServerResponseFromHash=function(e){if(!e)return{};var t=new Gt(e);return Gt.getDeserializedHash(t.getHash())},r}();/*! @azure/msal-browser v2.39.0 2024-06-06 */var Lb=function(r){ri(e,r);function e(t,n,i,o){var a=r.call(this,t,i,o)||this;return a.COOKIE_LIFE_MULTIPLIER=24*60*60*1e3,a.cacheConfig=n,a.logger=o,a.internalStorage=new Zb,a.browserStorage=a.setupBrowserStorage(a.cacheConfig.cacheLocation),a.temporaryCacheStorage=a.setupTemporaryCacheStorage(a.cacheConfig.temporaryCacheLocation,a.cacheConfig.cacheLocation),n.cacheMigrationEnabled&&(a.migrateCacheEntries(),a.createKeyMaps()),a}return e.prototype.setupBrowserStorage=function(t){switch(t){case Cn.LocalStorage:case Cn.SessionStorage:try{return new GC(t)}catch(n){this.logger.verbose(n);break}}return this.cacheConfig.cacheLocation=Cn.MemoryStorage,new Zb},e.prototype.setupTemporaryCacheStorage=function(t,n){switch(n){case Cn.LocalStorage:case Cn.SessionStorage:try{return new GC(t||Cn.SessionStorage)}catch(i){return this.logger.verbose(i),this.internalStorage}case Cn.MemoryStorage:default:return this.internalStorage}},e.prototype.migrateCacheEntries=function(){var t=this,n=G.CACHE_PREFIX+"."+$n.ID_TOKEN,i=G.CACHE_PREFIX+"."+$n.CLIENT_INFO,o=G.CACHE_PREFIX+"."+$n.ERROR,a=G.CACHE_PREFIX+"."+$n.ERROR_DESC,c=this.browserStorage.getItem(n),d=this.browserStorage.getItem(i),h=this.browserStorage.getItem(o),u=this.browserStorage.getItem(a),p=[c,d,h,u],v=[$n.ID_TOKEN,$n.CLIENT_INFO,$n.ERROR,$n.ERROR_DESC];v.forEach(function(g,_){return t.migrateCacheEntry(g,p[_])})},e.prototype.migrateCacheEntry=function(t,n){n&&this.setTemporaryCache(t,n,!0)},e.prototype.createKeyMaps=function(){var t=this;this.logger.trace("BrowserCacheManager - createKeyMaps called.");var n=this.getItem(as.ACCOUNT_KEYS),i=this.getItem(as.TOKEN_KEYS+"."+this.clientId);if(n&&i){this.logger.verbose("BrowserCacheManager:createKeyMaps - account and token key maps already exist, skipping migration.");return}var o=this.browserStorage.getKeys();o.forEach(function(a){if(t.isCredentialKey(a)){var c=t.getItem(a);if(c){var d=t.validateAndParseJson(c);if(d&&d.hasOwnProperty("credentialType"))switch(d.credentialType){case dt.ID_TOKEN:if(gl.isIdTokenEntity(d)){t.logger.trace("BrowserCacheManager:createKeyMaps - idToken found, saving key to token key map"),t.logger.tracePii("BrowserCacheManager:createKeyMaps - idToken with key: "+a+" found, saving key to token key map");var h=ro.toObject(new gl,d),u=t.updateCredentialCacheKey(a,h);t.addTokenKey(u,dt.ID_TOKEN);return}else t.logger.trace("BrowserCacheManager:createKeyMaps - key found matching idToken schema with value containing idToken credentialType field but value failed IdTokenEntity validation, skipping."),t.logger.tracePii("BrowserCacheManager:createKeyMaps - failed idToken validation on key: "+a);break;case dt.ACCESS_TOKEN:case dt.ACCESS_TOKEN_WITH_AUTH_SCHEME:if(yl.isAccessTokenEntity(d)){t.logger.trace("BrowserCacheManager:createKeyMaps - accessToken found, saving key to token key map"),t.logger.tracePii("BrowserCacheManager:createKeyMaps - accessToken with key: "+a+" found, saving key to token key map");var p=ro.toObject(new yl,d),u=t.updateCredentialCacheKey(a,p);t.addTokenKey(u,dt.ACCESS_TOKEN);return}else t.logger.trace("BrowserCacheManager:createKeyMaps - key found matching accessToken schema with value containing accessToken credentialType field but value failed AccessTokenEntity validation, skipping."),t.logger.tracePii("BrowserCacheManager:createKeyMaps - failed accessToken validation on key: "+a);break;case dt.REFRESH_TOKEN:if(Qh.isRefreshTokenEntity(d)){t.logger.trace("BrowserCacheManager:createKeyMaps - refreshToken found, saving key to token key map"),t.logger.tracePii("BrowserCacheManager:createKeyMaps - refreshToken with key: "+a+" found, saving key to token key map");var v=ro.toObject(new Qh,d),u=t.updateCredentialCacheKey(a,v);t.addTokenKey(u,dt.REFRESH_TOKEN);return}else t.logger.trace("BrowserCacheManager:createKeyMaps - key found matching refreshToken schema with value containing refreshToken credentialType field but value failed RefreshTokenEntity validation, skipping."),t.logger.tracePii("BrowserCacheManager:createKeyMaps - failed refreshToken validation on key: "+a);break}}}if(t.isAccountKey(a)){var c=t.getItem(a);if(c){var g=t.validateAndParseJson(c);g&&Ci.isAccountEntity(g)&&(t.logger.trace("BrowserCacheManager:createKeyMaps - account found, saving key to account key map"),t.logger.tracePii("BrowserCacheManager:createKeyMaps - account with key: "+a+" found, saving key to account key map"),t.addAccountKeyToMap(a))}}})},e.prototype.validateAndParseJson=function(t){try{var n=JSON.parse(t);return n&&typeof n=="object"?n:null}catch{return null}},e.prototype.getItem=function(t){return this.browserStorage.getItem(t)},e.prototype.setItem=function(t,n){this.browserStorage.setItem(t,n)},e.prototype.getAccount=function(t){this.logger.trace("BrowserCacheManager.getAccount called");var n=this.getItem(t);if(!n)return this.removeAccountKeyFromMap(t),null;var i=this.validateAndParseJson(n);return!i||!Ci.isAccountEntity(i)?(this.removeAccountKeyFromMap(t),null):ro.toObject(new Ci,i)},e.prototype.setAccount=function(t){this.logger.trace("BrowserCacheManager.setAccount called");var n=t.generateAccountKey();this.setItem(n,JSON.stringify(t)),this.addAccountKeyToMap(n)},e.prototype.getAccountKeys=function(){this.logger.trace("BrowserCacheManager.getAccountKeys called");var t=this.getItem(as.ACCOUNT_KEYS);return t?JSON.parse(t):(this.logger.verbose("BrowserCacheManager.getAccountKeys - No account keys found"),[])},e.prototype.addAccountKeyToMap=function(t){this.logger.trace("BrowserCacheManager.addAccountKeyToMap called"),this.logger.tracePii("BrowserCacheManager.addAccountKeyToMap called with key: "+t);var n=this.getAccountKeys();n.indexOf(t)===-1?(n.push(t),this.setItem(as.ACCOUNT_KEYS,JSON.stringify(n)),this.logger.verbose("BrowserCacheManager.addAccountKeyToMap account key added")):this.logger.verbose("BrowserCacheManager.addAccountKeyToMap account key already exists in map")},e.prototype.removeAccountKeyFromMap=function(t){this.logger.trace("BrowserCacheManager.removeAccountKeyFromMap called"),this.logger.tracePii("BrowserCacheManager.removeAccountKeyFromMap called with key: "+t);var n=this.getAccountKeys(),i=n.indexOf(t);i>-1?(n.splice(i,1),this.setItem(as.ACCOUNT_KEYS,JSON.stringify(n)),this.logger.trace("BrowserCacheManager.removeAccountKeyFromMap account key removed")):this.logger.trace("BrowserCacheManager.removeAccountKeyFromMap key not found in existing map")},e.prototype.removeAccount=function(t){return fe(this,void 0,void 0,function(){return pe(this,function(n){return r.prototype.removeAccount.call(this,t),this.removeAccountKeyFromMap(t),[2]})})},e.prototype.removeIdToken=function(t){r.prototype.removeIdToken.call(this,t),this.removeTokenKey(t,dt.ID_TOKEN)},e.prototype.removeAccessToken=function(t){return fe(this,void 0,void 0,function(){return pe(this,function(n){return r.prototype.removeAccessToken.call(this,t),this.removeTokenKey(t,dt.ACCESS_TOKEN),[2]})})},e.prototype.removeRefreshToken=function(t){r.prototype.removeRefreshToken.call(this,t),this.removeTokenKey(t,dt.REFRESH_TOKEN)},e.prototype.getTokenKeys=function(){this.logger.trace("BrowserCacheManager.getTokenKeys called");var t=this.getItem(as.TOKEN_KEYS+"."+this.clientId);if(t){var n=this.validateAndParseJson(t);if(n&&n.hasOwnProperty("idToken")&&n.hasOwnProperty("accessToken")&&n.hasOwnProperty("refreshToken"))return n;this.logger.error("BrowserCacheManager.getTokenKeys - Token keys found but in an unknown format. Returning empty key map.")}else this.logger.verbose("BrowserCacheManager.getTokenKeys - No token keys found");return{idToken:[],accessToken:[],refreshToken:[]}},e.prototype.addTokenKey=function(t,n){this.logger.trace("BrowserCacheManager addTokenKey called");var i=this.getTokenKeys();switch(n){case dt.ID_TOKEN:i.idToken.indexOf(t)===-1&&(this.logger.info("BrowserCacheManager: addTokenKey - idToken added to map"),i.idToken.push(t));break;case dt.ACCESS_TOKEN:i.accessToken.indexOf(t)===-1&&(this.logger.info("BrowserCacheManager: addTokenKey - accessToken added to map"),i.accessToken.push(t));break;case dt.REFRESH_TOKEN:i.refreshToken.indexOf(t)===-1&&(this.logger.info("BrowserCacheManager: addTokenKey - refreshToken added to map"),i.refreshToken.push(t));break;default:this.logger.error("BrowserCacheManager:addTokenKey - CredentialType provided invalid. CredentialType: "+n),We.createUnexpectedCredentialTypeError()}this.setItem(as.TOKEN_KEYS+"."+this.clientId,JSON.stringify(i))},e.prototype.removeTokenKey=function(t,n){this.logger.trace("BrowserCacheManager removeTokenKey called");var i=this.getTokenKeys();switch(n){case dt.ID_TOKEN:this.logger.infoPii("BrowserCacheManager: removeTokenKey - attempting to remove idToken with key: "+t+" from map");var o=i.idToken.indexOf(t);o>-1?(this.logger.info("BrowserCacheManager: removeTokenKey - idToken removed from map"),i.idToken.splice(o,1)):this.logger.info("BrowserCacheManager: removeTokenKey - idToken does not exist in map. Either it was previously removed or it was never added.");break;case dt.ACCESS_TOKEN:this.logger.infoPii("BrowserCacheManager: removeTokenKey - attempting to remove accessToken with key: "+t+" from map");var a=i.accessToken.indexOf(t);a>-1?(this.logger.info("BrowserCacheManager: removeTokenKey - accessToken removed from map"),i.accessToken.splice(a,1)):this.logger.info("BrowserCacheManager: removeTokenKey - accessToken does not exist in map. Either it was previously removed or it was never added.");break;case dt.REFRESH_TOKEN:this.logger.infoPii("BrowserCacheManager: removeTokenKey - attempting to remove refreshToken with key: "+t+" from map");var c=i.refreshToken.indexOf(t);c>-1?(this.logger.info("BrowserCacheManager: removeTokenKey - refreshToken removed from map"),i.refreshToken.splice(c,1)):this.logger.info("BrowserCacheManager: removeTokenKey - refreshToken does not exist in map. Either it was previously removed or it was never added.");break;default:this.logger.error("BrowserCacheManager:removeTokenKey - CredentialType provided invalid. CredentialType: "+n),We.createUnexpectedCredentialTypeError()}this.setItem(as.TOKEN_KEYS+"."+this.clientId,JSON.stringify(i))},e.prototype.getIdTokenCredential=function(t){var n=this.getItem(t);if(!n)return this.logger.trace("BrowserCacheManager.getIdTokenCredential: called, no cache hit"),this.removeTokenKey(t,dt.ID_TOKEN),null;var i=this.validateAndParseJson(n);return!i||!gl.isIdTokenEntity(i)?(this.logger.trace("BrowserCacheManager.getIdTokenCredential: called, no cache hit"),this.removeTokenKey(t,dt.ID_TOKEN),null):(this.logger.trace("BrowserCacheManager.getIdTokenCredential: cache hit"),ro.toObject(new gl,i))},e.prototype.setIdTokenCredential=function(t){this.logger.trace("BrowserCacheManager.setIdTokenCredential called");var n=t.generateCredentialKey();this.setItem(n,JSON.stringify(t)),this.addTokenKey(n,dt.ID_TOKEN)},e.prototype.getAccessTokenCredential=function(t){var n=this.getItem(t);if(!n)return this.logger.trace("BrowserCacheManager.getAccessTokenCredential: called, no cache hit"),this.removeTokenKey(t,dt.ACCESS_TOKEN),null;var i=this.validateAndParseJson(n);return!i||!yl.isAccessTokenEntity(i)?(this.logger.trace("BrowserCacheManager.getAccessTokenCredential: called, no cache hit"),this.removeTokenKey(t,dt.ACCESS_TOKEN),null):(this.logger.trace("BrowserCacheManager.getAccessTokenCredential: cache hit"),ro.toObject(new yl,i))},e.prototype.setAccessTokenCredential=function(t){this.logger.trace("BrowserCacheManager.setAccessTokenCredential called");var n=t.generateCredentialKey();this.setItem(n,JSON.stringify(t)),this.addTokenKey(n,dt.ACCESS_TOKEN)},e.prototype.getRefreshTokenCredential=function(t){var n=this.getItem(t);if(!n)return this.logger.trace("BrowserCacheManager.getRefreshTokenCredential: called, no cache hit"),this.removeTokenKey(t,dt.REFRESH_TOKEN),null;var i=this.validateAndParseJson(n);return!i||!Qh.isRefreshTokenEntity(i)?(this.logger.trace("BrowserCacheManager.getRefreshTokenCredential: called, no cache hit"),this.removeTokenKey(t,dt.REFRESH_TOKEN),null):(this.logger.trace("BrowserCacheManager.getRefreshTokenCredential: cache hit"),ro.toObject(new Qh,i))},e.prototype.setRefreshTokenCredential=function(t){this.logger.trace("BrowserCacheManager.setRefreshTokenCredential called");var n=t.generateCredentialKey();this.setItem(n,JSON.stringify(t)),this.addTokenKey(n,dt.REFRESH_TOKEN)},e.prototype.getAppMetadata=function(t){var n=this.getItem(t);if(!n)return this.logger.trace("BrowserCacheManager.getAppMetadata: called, no cache hit"),null;var i=this.validateAndParseJson(n);return!i||!Mb.isAppMetadataEntity(t,i)?(this.logger.trace("BrowserCacheManager.getAppMetadata: called, no cache hit"),null):(this.logger.trace("BrowserCacheManager.getAppMetadata: cache hit"),ro.toObject(new Mb,i))},e.prototype.setAppMetadata=function(t){this.logger.trace("BrowserCacheManager.setAppMetadata called");var n=t.generateAppMetadataKey();this.setItem(n,JSON.stringify(t))},e.prototype.getServerTelemetry=function(t){var n=this.getItem(t);if(!n)return this.logger.trace("BrowserCacheManager.getServerTelemetry: called, no cache hit"),null;var i=this.validateAndParseJson(n);return!i||!wg.isServerTelemetryEntity(t,i)?(this.logger.trace("BrowserCacheManager.getServerTelemetry: called, no cache hit"),null):(this.logger.trace("BrowserCacheManager.getServerTelemetry: cache hit"),ro.toObject(new wg,i))},e.prototype.setServerTelemetry=function(t,n){this.logger.trace("BrowserCacheManager.setServerTelemetry called"),this.setItem(t,JSON.stringify(n))},e.prototype.getAuthorityMetadata=function(t){var n=this.internalStorage.getItem(t);if(!n)return this.logger.trace("BrowserCacheManager.getAuthorityMetadata: called, no cache hit"),null;var i=this.validateAndParseJson(n);return i&&$b.isAuthorityMetadataEntity(t,i)?(this.logger.trace("BrowserCacheManager.getAuthorityMetadata: cache hit"),ro.toObject(new $b,i)):null},e.prototype.getAuthorityMetadataKeys=function(){var t=this,n=this.internalStorage.getKeys();return n.filter(function(i){return t.isAuthorityMetadata(i)})},e.prototype.setWrapperMetadata=function(t,n){this.internalStorage.setItem(Jh.WRAPPER_SKU,t),this.internalStorage.setItem(Jh.WRAPPER_VER,n)},e.prototype.getWrapperMetadata=function(){var t=this.internalStorage.getItem(Jh.WRAPPER_SKU)||G.EMPTY_STRING,n=this.internalStorage.getItem(Jh.WRAPPER_VER)||G.EMPTY_STRING;return[t,n]},e.prototype.setAuthorityMetadata=function(t,n){this.logger.trace("BrowserCacheManager.setAuthorityMetadata called"),this.internalStorage.setItem(t,JSON.stringify(n))},e.prototype.getActiveAccount=function(){var t=this.generateCacheKey($n.ACTIVE_ACCOUNT_FILTERS),n=this.getItem(t);if(!n){this.logger.trace("BrowserCacheManager.getActiveAccount: No active account filters cache schema found, looking for legacy schema");var i=this.generateCacheKey($n.ACTIVE_ACCOUNT),o=this.getItem(i);if(!o)return this.logger.trace("BrowserCacheManager.getActiveAccount: No active account found"),null;var a=this.getAccountInfoByFilter({localAccountId:o})[0]||null;return a?(this.logger.trace("BrowserCacheManager.getActiveAccount: Legacy active account cache schema found"),this.logger.trace("BrowserCacheManager.getActiveAccount: Adding active account filters cache schema"),this.setActiveAccount(a),a):null}var c=this.validateAndParseJson(n);return c?(this.logger.trace("BrowserCacheManager.getActiveAccount: Active account filters schema found"),this.getAccountInfoByFilter({homeAccountId:c.homeAccountId,localAccountId:c.localAccountId})[0]||null):(this.logger.trace("BrowserCacheManager.getActiveAccount: No active account found"),null)},e.prototype.setActiveAccount=function(t){var n=this.generateCacheKey($n.ACTIVE_ACCOUNT_FILTERS),i=this.generateCacheKey($n.ACTIVE_ACCOUNT);if(t){this.logger.verbose("setActiveAccount: Active account set");var o={homeAccountId:t.homeAccountId,localAccountId:t.localAccountId};this.browserStorage.setItem(n,JSON.stringify(o)),this.browserStorage.setItem(i,t.localAccountId)}else this.logger.verbose("setActiveAccount: No account passed, active account not set"),this.browserStorage.removeItem(n),this.browserStorage.removeItem(i)},e.prototype.getAccountInfoByFilter=function(t){var n=this.getAllAccounts();return this.logger.trace("BrowserCacheManager.getAccountInfoByFilter: total "+n.length+" accounts found"),n.filter(function(i){return!(t.username&&t.username.toLowerCase()!==i.username.toLowerCase()||t.homeAccountId&&t.homeAccountId!==i.homeAccountId||t.localAccountId&&t.localAccountId!==i.localAccountId||t.tenantId&&t.tenantId!==i.tenantId||t.environment&&t.environment!==i.environment)})},e.prototype.getAccountInfoByHints=function(t,n){var i=this.getAllAccounts().filter(function(o){if(n){var a=o.idTokenClaims&&o.idTokenClaims.sid;return n===a}return t?t===o.username:!1});if(i.length===1)return i[0];if(i.length>1)throw We.createMultipleMatchingAccountsInCacheError();return null},e.prototype.getThrottlingCache=function(t){var n=this.getItem(t);if(!n)return this.logger.trace("BrowserCacheManager.getThrottlingCache: called, no cache hit"),null;var i=this.validateAndParseJson(n);return!i||!jC.isThrottlingEntity(t,i)?(this.logger.trace("BrowserCacheManager.getThrottlingCache: called, no cache hit"),null):(this.logger.trace("BrowserCacheManager.getThrottlingCache: cache hit"),ro.toObject(new jC,i))},e.prototype.setThrottlingCache=function(t,n){this.logger.trace("BrowserCacheManager.setThrottlingCache called"),this.setItem(t,JSON.stringify(n))},e.prototype.getTemporaryCache=function(t,n){var i=n?this.generateCacheKey(t):t;if(this.cacheConfig.storeAuthStateInCookie){var o=this.getItemCookie(i);if(o)return this.logger.trace("BrowserCacheManager.getTemporaryCache: storeAuthStateInCookies set to true, retrieving from cookies"),o}var a=this.temporaryCacheStorage.getItem(i);if(!a){if(this.cacheConfig.cacheLocation===Cn.LocalStorage){var c=this.browserStorage.getItem(i);if(c)return this.logger.trace("BrowserCacheManager.getTemporaryCache: Temporary cache item found in local storage"),c}return this.logger.trace("BrowserCacheManager.getTemporaryCache: No cache item found in local storage"),null}return this.logger.trace("BrowserCacheManager.getTemporaryCache: Temporary cache item returned"),a},e.prototype.setTemporaryCache=function(t,n,i){var o=i?this.generateCacheKey(t):t;this.temporaryCacheStorage.setItem(o,n),this.cacheConfig.storeAuthStateInCookie&&(this.logger.trace("BrowserCacheManager.setTemporaryCache: storeAuthStateInCookie set to true, setting item cookie"),this.setItemCookie(o,n))},e.prototype.removeItem=function(t){this.browserStorage.removeItem(t),this.temporaryCacheStorage.removeItem(t),this.cacheConfig.storeAuthStateInCookie&&(this.logger.trace("BrowserCacheManager.removeItem: storeAuthStateInCookie is true, clearing item cookie"),this.clearItemCookie(t))},e.prototype.containsKey=function(t){return this.browserStorage.containsKey(t)||this.temporaryCacheStorage.containsKey(t)},e.prototype.getKeys=function(){return I6(this.browserStorage.getKeys(),this.temporaryCacheStorage.getKeys())},e.prototype.clear=function(){return fe(this,void 0,void 0,function(){var t=this;return pe(this,function(n){switch(n.label){case 0:return[4,this.removeAllAccounts()];case 1:return n.sent(),this.removeAppMetadata(),this.getKeys().forEach(function(i){(t.browserStorage.containsKey(i)||t.temporaryCacheStorage.containsKey(i))&&(i.indexOf(G.CACHE_PREFIX)!==-1||i.indexOf(t.clientId)!==-1)&&t.removeItem(i)}),this.internalStorage.clear(),[2]}})})},e.prototype.clearTokensAndKeysWithClaims=function(){return fe(this,void 0,void 0,function(){var t,n,i=this;return pe(this,function(o){switch(o.label){case 0:return this.logger.trace("BrowserCacheManager.clearTokensAndKeysWithClaims called"),t=this.getTokenKeys(),n=[],t.accessToken.forEach(function(a){var c=i.getAccessTokenCredential(a);c!=null&&c.requestedClaimsHash&&a.includes(c.requestedClaimsHash.toLowerCase())&&n.push(i.removeAccessToken(a))}),[4,Promise.all(n)];case 1:return o.sent(),n.length>0&&this.logger.warning(n.length+" access tokens with claims in the cache keys have been removed from the cache."),[2]}})})},e.prototype.setItemCookie=function(t,n,i){var o=encodeURIComponent(t)+"="+encodeURIComponent(n)+";path=/;SameSite=Lax;";if(i){var a=this.getCookieExpirationTime(i);o+="expires="+a+";"}this.cacheConfig.secureCookies&&(o+="Secure;"),document.cookie=o},e.prototype.getItemCookie=function(t){for(var n=encodeURIComponent(t)+"=",i=document.cookie.split(";"),o=0;o<i.length;o++){for(var a=i[o];a.charAt(0)===" ";)a=a.substring(1);if(a.indexOf(n)===0)return decodeURIComponent(a.substring(n.length,a.length))}return G.EMPTY_STRING},e.prototype.clearMsalCookies=function(){var t=this,n=G.CACHE_PREFIX+"."+this.clientId,i=document.cookie.split(";");i.forEach(function(o){for(;o.charAt(0)===" ";)o=o.substring(1);if(o.indexOf(n)===0){var a=o.split("=")[0];t.clearItemCookie(a)}})},e.prototype.clearItemCookie=function(t){this.setItemCookie(t,G.EMPTY_STRING,-1)},e.prototype.getCookieExpirationTime=function(t){var n=new Date,i=new Date(n.getTime()+t*this.COOKIE_LIFE_MULTIPLIER);return i.toUTCString()},e.prototype.getCache=function(){return this.browserStorage},e.prototype.setCache=function(){},e.prototype.generateCacheKey=function(t){var n=this.validateAndParseJson(t);return n?JSON.stringify(t):Ne.startsWith(t,G.CACHE_PREFIX)||Ne.startsWith(t,$n.ADAL_ID_TOKEN)?t:G.CACHE_PREFIX+"."+this.clientId+"."+t},e.prototype.generateAuthorityKey=function(t){var n=fc.parseRequestState(this.cryptoImpl,t).libraryState.id;return this.generateCacheKey(er.AUTHORITY+"."+n)},e.prototype.generateNonceKey=function(t){var n=fc.parseRequestState(this.cryptoImpl,t).libraryState.id;return this.generateCacheKey(er.NONCE_IDTOKEN+"."+n)},e.prototype.generateStateKey=function(t){var n=fc.parseRequestState(this.cryptoImpl,t).libraryState.id;return this.generateCacheKey(er.REQUEST_STATE+"."+n)},e.prototype.getCachedAuthority=function(t){var n=this.generateStateKey(t),i=this.getTemporaryCache(n);if(!i)return null;var o=this.generateAuthorityKey(i);return this.getTemporaryCache(o)},e.prototype.updateCacheEntries=function(t,n,i,o,a){this.logger.trace("BrowserCacheManager.updateCacheEntries called");var c=this.generateStateKey(t);this.setTemporaryCache(c,t,!1);var d=this.generateNonceKey(t);this.setTemporaryCache(d,n,!1);var h=this.generateAuthorityKey(t);if(this.setTemporaryCache(h,i,!1),a){var u={credential:a.homeAccountId,type:Co.HOME_ACCOUNT_ID};this.setTemporaryCache(er.CCS_CREDENTIAL,JSON.stringify(u),!0)}else if(!Ne.isEmpty(o)){var u={credential:o,type:Co.UPN};this.setTemporaryCache(er.CCS_CREDENTIAL,JSON.stringify(u),!0)}},e.prototype.resetRequestCache=function(t){var n=this;this.logger.trace("BrowserCacheManager.resetRequestCache called"),Ne.isEmpty(t)||this.getKeys().forEach(function(i){i.indexOf(t)!==-1&&n.removeItem(i)}),t&&(this.removeItem(this.generateStateKey(t)),this.removeItem(this.generateNonceKey(t)),this.removeItem(this.generateAuthorityKey(t))),this.removeItem(this.generateCacheKey(er.REQUEST_PARAMS)),this.removeItem(this.generateCacheKey(er.ORIGIN_URI)),this.removeItem(this.generateCacheKey(er.URL_HASH)),this.removeItem(this.generateCacheKey(er.CORRELATION_ID)),this.removeItem(this.generateCacheKey(er.CCS_CREDENTIAL)),this.removeItem(this.generateCacheKey(er.NATIVE_REQUEST)),this.setInteractionInProgress(!1)},e.prototype.cleanRequestByState=function(t){if(this.logger.trace("BrowserCacheManager.cleanRequestByState called"),t){var n=this.generateStateKey(t),i=this.temporaryCacheStorage.getItem(n);this.logger.infoPii("BrowserCacheManager.cleanRequestByState: Removing temporary cache items for state: "+i),this.resetRequestCache(i||G.EMPTY_STRING)}this.clearMsalCookies()},e.prototype.cleanRequestByInteractionType=function(t){var n=this;this.logger.trace("BrowserCacheManager.cleanRequestByInteractionType called"),this.getKeys().forEach(function(i){if(i.indexOf(er.REQUEST_STATE)!==-1){var o=n.temporaryCacheStorage.getItem(i);if(o){var a=nP.extractBrowserRequestState(n.cryptoImpl,o);a&&a.interactionType===t&&(n.logger.infoPii("BrowserCacheManager.cleanRequestByInteractionType: Removing temporary cache items for state: "+o),n.resetRequestCache(o))}}}),this.clearMsalCookies(),this.setInteractionInProgress(!1)},e.prototype.cacheCodeRequest=function(t,n){this.logger.trace("BrowserCacheManager.cacheCodeRequest called");var i=n.base64Encode(JSON.stringify(t));this.setTemporaryCache(er.REQUEST_PARAMS,i,!0)},e.prototype.getCachedRequest=function(t,n){this.logger.trace("BrowserCacheManager.getCachedRequest called");var i=this.getTemporaryCache(er.REQUEST_PARAMS,!0);if(!i)throw Me.createNoTokenRequestCacheError();var o=this.validateAndParseJson(n.base64Decode(i));if(!o)throw Me.createUnableToParseTokenRequestCacheError();if(this.removeItem(this.generateCacheKey(er.REQUEST_PARAMS)),Ne.isEmpty(o.authority)){var a=this.generateAuthorityKey(t),c=this.getTemporaryCache(a);if(!c)throw Me.createNoCachedAuthorityError();o.authority=c}return o},e.prototype.getCachedNativeRequest=function(){this.logger.trace("BrowserCacheManager.getCachedNativeRequest called");var t=this.getTemporaryCache(er.NATIVE_REQUEST,!0);if(!t)return this.logger.trace("BrowserCacheManager.getCachedNativeRequest: No cached native request found"),null;var n=this.validateAndParseJson(t);return n||(this.logger.error("BrowserCacheManager.getCachedNativeRequest: Unable to parse native request"),null)},e.prototype.isInteractionInProgress=function(t){var n=this.getInteractionInProgress();return t?n===this.clientId:!!n},e.prototype.getInteractionInProgress=function(){var t=G.CACHE_PREFIX+"."+er.INTERACTION_STATUS_KEY;return this.getTemporaryCache(t,!1)},e.prototype.setInteractionInProgress=function(t){var n=G.CACHE_PREFIX+"."+er.INTERACTION_STATUS_KEY;if(t){if(this.getInteractionInProgress())throw Me.createInteractionInProgressError();this.setTemporaryCache(n,this.clientId,!1)}else!t&&this.getInteractionInProgress()===this.clientId&&this.removeItem(n)},e.prototype.getLegacyLoginHint=function(){var t=this.getTemporaryCache($n.ADAL_ID_TOKEN);t&&(this.browserStorage.removeItem($n.ADAL_ID_TOKEN),this.logger.verbose("Cached ADAL id token retrieved."));var n=this.getTemporaryCache($n.ID_TOKEN,!0);n&&(this.removeItem(this.generateCacheKey($n.ID_TOKEN)),this.logger.verbose("Cached MSAL.js v1 id token retrieved"));var i=n||t;if(i){var o=new xs(i,this.cryptoImpl);if(o.claims&&o.claims.preferred_username)return this.logger.verbose("No SSO params used and ADAL/MSAL v1 token retrieved, setting ADAL/MSAL v1 preferred_username as loginHint"),o.claims.preferred_username;if(o.claims&&o.claims.upn)return this.logger.verbose("No SSO params used and ADAL/MSAL v1 token retrieved, setting ADAL/MSAL v1 upn as loginHint"),o.claims.upn;this.logger.verbose("No SSO params used and ADAL/MSAL v1 token retrieved, however, no account hint claim found. Enable preferred_username or upn id token claim to get SSO.")}return null},e.prototype.updateCredentialCacheKey=function(t,n){var i=n.generateCredentialKey();if(t!==i){var o=this.getItem(t);if(o)return this.removeItem(t),this.setItem(i,o),this.logger.verbose("Updated an outdated "+n.credentialType+" cache key"),i;this.logger.error("Attempted to update an outdated "+n.credentialType+" cache key but no item matching the outdated key was found in storage")}return t},e.prototype.getRedirectRequestContext=function(){return this.getTemporaryCache(er.REDIRECT_CONTEXT,!0)},e.prototype.setRedirectRequestContext=function(t){this.setTemporaryCache(er.REDIRECT_CONTEXT,t,!0)},e.prototype.hydrateCache=function(t,n){var i,o,a,c,d,h;return fe(this,void 0,void 0,function(){var u,p,v,g;return pe(this,function(_){switch(_.label){case 0:return u=gl.createIdTokenEntity(((i=t.account)===null||i===void 0?void 0:i.homeAccountId)||"",((o=t.account)===null||o===void 0?void 0:o.environment)||"",t.idToken,this.clientId,t.tenantId),n.claims?[4,this.cryptoImpl.hashString(n.claims)]:[3,2];case 1:p=_.sent(),_.label=2;case 2:return v=yl.createAccessTokenEntity(((a=t.account)===null||a===void 0?void 0:a.homeAccountId)||"",((c=t.account)===null||c===void 0?void 0:c.environment)||"",t.accessToken,this.clientId,t.tenantId,t.scopes.join(" "),((d=t.expiresOn)===null||d===void 0?void 0:d.getTime())||0,((h=t.extExpiresOn)===null||h===void 0?void 0:h.getTime())||0,this.cryptoImpl,void 0,t.tokenType,void 0,n.sshKid,n.claims,p),g=new sf(void 0,u,v),[2,this.saveCacheRecord(g)]}})})},e}(ro),rF=function(r,e){var t={cacheLocation:Cn.MemoryStorage,temporaryCacheLocation:Cn.MemoryStorage,storeAuthStateInCookie:!1,secureCookies:!1,cacheMigrationEnabled:!1,claimsBasedCachingEnabled:!0};return new Lb(r,t,mg,e)};/*! @azure/msal-browser v2.39.0 2024-06-06 */var O3="@azure/msal-browser",Zp="2.39.0";/*! @azure/msal-browser v2.39.0 2024-06-06 */var nF=function(){function r(){}return r.prototype.sendGetRequestAsync=function(e,t){return fe(this,void 0,void 0,function(){var n,i,o;return pe(this,function(a){switch(a.label){case 0:return a.trys.push([0,2,,3]),[4,fetch(e,{method:ls.GET,headers:this.getFetchHeaders(t)})];case 1:return n=a.sent(),[3,3];case 2:throw i=a.sent(),window.navigator.onLine?Me.createGetRequestFailedError(i,e):Me.createNoNetworkConnectivityError();case 3:return a.trys.push([3,5,,6]),o={headers:this.getHeaderDict(n.headers)},[4,n.json()];case 4:return[2,(o.body=a.sent(),o.status=n.status,o)];case 5:throw a.sent(),Me.createFailedToParseNetworkResponseError(e);case 6:return[2]}})})},r.prototype.sendPostRequestAsync=function(e,t){return fe(this,void 0,void 0,function(){var n,i,o,a;return pe(this,function(c){switch(c.label){case 0:n=t&&t.body||G.EMPTY_STRING,c.label=1;case 1:return c.trys.push([1,3,,4]),[4,fetch(e,{method:ls.POST,headers:this.getFetchHeaders(t),body:n})];case 2:return i=c.sent(),[3,4];case 3:throw o=c.sent(),window.navigator.onLine?Me.createPostRequestFailedError(o,e):Me.createNoNetworkConnectivityError();case 4:return c.trys.push([4,6,,7]),a={headers:this.getHeaderDict(i.headers)},[4,i.json()];case 5:return[2,(a.body=c.sent(),a.status=i.status,a)];case 6:throw c.sent(),Me.createFailedToParseNetworkResponseError(e);case 7:return[2]}})})},r.prototype.getFetchHeaders=function(e){var t=new Headers;if(!(e&&e.headers))return t;var n=e.headers;return Object.keys(n).forEach(function(i){t.append(i,n[i])}),t},r.prototype.getHeaderDict=function(e){var t={};return e.forEach(function(n,i){t[i]=n}),t},r}();/*! @azure/msal-browser v2.39.0 2024-06-06 */var iF=function(){function r(){}return r.prototype.sendGetRequestAsync=function(e,t){return fe(this,void 0,void 0,function(){return pe(this,function(n){return[2,this.sendRequestAsync(e,ls.GET,t)]})})},r.prototype.sendPostRequestAsync=function(e,t){return fe(this,void 0,void 0,function(){return pe(this,function(n){return[2,this.sendRequestAsync(e,ls.POST,t)]})})},r.prototype.sendRequestAsync=function(e,t,n){var i=this;return new Promise(function(o,a){var c=new XMLHttpRequest;if(c.open(t,e,!0),i.setXhrHeaders(c,n),c.onload=function(){(c.status<200||c.status>=300)&&(t===ls.POST?a(Me.createPostRequestFailedError("Failed with status "+c.status,e)):a(Me.createGetRequestFailedError("Failed with status "+c.status,e)));try{var d=JSON.parse(c.responseText),h={headers:i.getHeaderDict(c),body:d,status:c.status};o(h)}catch{a(Me.createFailedToParseNetworkResponseError(e))}},c.onerror=function(){window.navigator.onLine?t===ls.POST?a(Me.createPostRequestFailedError("Failed with status "+c.status,e)):a(Me.createGetRequestFailedError("Failed with status "+c.status,e)):a(Me.createNoNetworkConnectivityError())},t===ls.POST&&n&&n.body)c.send(n.body);else if(t===ls.GET)c.send();else throw Me.createHttpMethodNotImplementedError(t)})},r.prototype.setXhrHeaders=function(e,t){if(t&&t.headers){var n=t.headers;Object.keys(n).forEach(function(i){e.setRequestHeader(i,n[i])})}},r.prototype.getHeaderDict=function(e){var t=e.getAllResponseHeaders(),n=t.trim().split(/[\r\n]+/),i={};return n.forEach(function(o){var a=o.split(": "),c=a.shift(),d=a.join(": ");c&&d&&(i[c]=d)}),i},r}();/*! @azure/msal-browser v2.39.0 2024-06-06 */var hn=function(){function r(){}return r.clearHash=function(e){e.location.hash=G.EMPTY_STRING,typeof e.history.replaceState=="function"&&e.history.replaceState(null,G.EMPTY_STRING,""+e.location.origin+e.location.pathname+e.location.search)},r.replaceHash=function(e){var t=e.split("#");t.shift(),window.location.hash=t.length>0?t.join("#"):G.EMPTY_STRING},r.isInIframe=function(){return window.parent!==window},r.isInPopup=function(){return typeof window<"u"&&!!window.opener&&window.opener!==window&&typeof window.name=="string"&&window.name.indexOf(Ra.POPUP_NAME_PREFIX+".")===0},r.getCurrentUri=function(){return window.location.href.split("?")[0].split("#")[0]},r.getHomepage=function(){var e=new Gt(window.location.href),t=e.getUrlComponents();return t.Protocol+"//"+t.HostNameAndPort+"/"},r.getBrowserNetworkClient=function(){return window.fetch&&window.Headers?new nF:new iF},r.blockReloadInHiddenIframes=function(){var e=Gt.hashContainsKnownProperties(window.location.hash);if(e&&r.isInIframe())throw Me.createBlockReloadInHiddenIframeError()},r.blockRedirectInIframe=function(e,t){var n=r.isInIframe();if(e===et.Redirect&&n&&!t)throw Me.createRedirectInIframeError(n)},r.blockAcquireTokenInPopups=function(){if(r.isInPopup())throw Me.createBlockAcquireTokenInPopupsError()},r.blockNonBrowserEnvironment=function(e){if(!e)throw Me.createNonBrowserEnvironmentError()},r.blockNativeBrokerCalledBeforeInitialized=function(e,t){if(e&&!t)throw Me.createNativeBrokerCalledBeforeInitialize()},r.detectIEOrEdge=function(){var e=window.navigator.userAgent,t=e.indexOf("MSIE "),n=e.indexOf("Trident/"),i=e.indexOf("Edge/"),o=t>0||n>0,a=i>0;return o||a},r}();/*! @azure/msal-browser v2.39.0 2024-06-06 */var iP=function(){function r(e,t,n,i,o,a,c,d,h){this.config=e,this.browserStorage=t,this.browserCrypto=n,this.networkClient=this.config.system.networkClient,this.eventHandler=o,this.navigationClient=a,this.nativeMessageHandler=d,this.correlationId=h||this.browserCrypto.createNewGuid(),this.logger=i.clone(Ra.MSAL_SKU,Zp,this.correlationId),this.performanceClient=c}return r.prototype.clearCacheOnLogout=function(e){return fe(this,void 0,void 0,function(){return pe(this,function(t){switch(t.label){case 0:if(!e)return[3,5];Ci.accountInfoIsEqual(e,this.browserStorage.getActiveAccount(),!1)&&(this.logger.verbose("Setting active account to null"),this.browserStorage.setActiveAccount(null)),t.label=1;case 1:return t.trys.push([1,3,,4]),[4,this.browserStorage.removeAccount(Ci.generateAccountCacheKey(e))];case 2:return t.sent(),this.logger.verbose("Cleared cache items belonging to the account provided in the logout request."),[3,4];case 3:return t.sent(),this.logger.error("Account provided in logout request was not found. Local cache unchanged."),[3,4];case 4:return[3,9];case 5:return t.trys.push([5,8,,9]),this.logger.verbose("No account provided in logout request, clearing all cache items.",this.correlationId),[4,this.browserStorage.clear()];case 6:return t.sent(),[4,this.browserCrypto.clearKeystore()];case 7:return t.sent(),[3,9];case 8:return t.sent(),this.logger.error("Attempted to clear all MSAL cache items and failed. Local cache unchanged."),[3,9];case 9:return[2]}})})},r.prototype.initializeBaseRequest=function(e,t){return fe(this,void 0,void 0,function(){var n,i,o,a;return pe(this,function(c){switch(c.label){case 0:return this.performanceClient.addQueueMeasurement(ae.InitializeBaseRequest,e.correlationId),this.logger.verbose("Initializing BaseAuthRequest"),n=e.authority||this.config.auth.authority,t?[4,this.validateRequestAuthority(n,t)]:[3,2];case 1:c.sent(),c.label=2;case 2:if(i=I6(e&&e.scopes||[]),o=qe(qe({},e),{correlationId:this.correlationId,authority:n,scopes:i}),!o.authenticationScheme)o.authenticationScheme=mr.BEARER,this.logger.verbose(`Authentication Scheme wasn't explicitly set in request, defaulting to "Bearer" request`);else{if(o.authenticationScheme===mr.SSH){if(!e.sshJwk)throw Or.createMissingSshJwkError();if(!e.sshKid)throw Or.createMissingSshKidError()}this.logger.verbose('Authentication Scheme set to "'+o.authenticationScheme+'" as configured in Auth request')}return this.config.cache.claimsBasedCachingEnabled&&e.claims&&!Ne.isEmptyObj(e.claims)?(a=o,[4,this.browserCrypto.hashString(e.claims)]):[3,4];case 3:a.requestedClaimsHash=c.sent(),c.label=4;case 4:return[2,o]}})})},r.prototype.getRedirectUri=function(e){this.logger.verbose("getRedirectUri called");var t=e||this.config.auth.redirectUri||hn.getCurrentUri();return Gt.getAbsoluteUrl(t,hn.getCurrentUri())},r.prototype.validateRequestAuthority=function(e,t){return fe(this,void 0,void 0,function(){var n;return pe(this,function(i){switch(i.label){case 0:return[4,this.getDiscoveredAuthority(e)];case 1:if(n=i.sent(),!n.isAlias(t.environment))throw Or.createAuthorityMismatchError();return[2]}})})},r.prototype.initializeServerTelemetryManager=function(e,t){this.logger.verbose("initializeServerTelemetryManager called");var n={clientId:this.config.auth.clientId,correlationId:this.correlationId,apiId:e,forceRefresh:t||!1,wrapperSKU:this.browserStorage.getWrapperMetadata()[0],wrapperVer:this.browserStorage.getWrapperMetadata()[1]};return new XV(n,this.browserStorage)},r.prototype.getDiscoveredAuthority=function(e){return fe(this,void 0,void 0,function(){var t;return pe(this,function(n){switch(n.label){case 0:return this.logger.verbose("getDiscoveredAuthority called"),t={protocolMode:this.config.auth.protocolMode,knownAuthorities:this.config.auth.knownAuthorities,cloudDiscoveryMetadata:this.config.auth.cloudDiscoveryMetadata,authorityMetadata:this.config.auth.authorityMetadata},e?(this.logger.verbose("Creating discovered authority with request authority"),[4,bg.createDiscoveredInstance(e,this.config.system.networkClient,this.browserStorage,t,this.logger)]):[3,2];case 1:return[2,n.sent()];case 2:return this.logger.verbose("Creating discovered authority with configured authority"),[4,bg.createDiscoveredInstance(this.config.auth.authority,this.config.system.networkClient,this.browserStorage,t,this.logger)];case 3:return[2,n.sent()]}})})},r}();/*! @azure/msal-browser v2.39.0 2024-06-06 */var Ff=function(r){ri(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.initializeAuthorizationCodeRequest=function(t){return fe(this,void 0,void 0,function(){var n,i;return pe(this,function(o){switch(o.label){case 0:return this.performanceClient.addQueueMeasurement(ae.StandardInteractionClientInitializeAuthorizationCodeRequest,t.correlationId),this.logger.verbose("initializeAuthorizationRequest called",t.correlationId),[4,this.browserCrypto.generatePkceCodes()];case 1:return n=o.sent(),i=qe(qe({},t),{redirectUri:t.redirectUri,code:G.EMPTY_STRING,codeVerifier:n.verifier}),t.codeChallenge=n.challenge,t.codeChallengeMethod=G.S256_CODE_CHALLENGE_METHOD,[2,i]}})})},e.prototype.initializeLogoutRequest=function(t){this.logger.verbose("initializeLogoutRequest called",t==null?void 0:t.correlationId);var n=qe({correlationId:this.correlationId||this.browserCrypto.createNewGuid()},t);if(t)if(t.logoutHint)this.logger.verbose("logoutHint has already been set in logoutRequest");else if(t.account){var i=this.getLogoutHintFromIdTokenClaims(t.account);i&&(this.logger.verbose("Setting logoutHint to login_hint ID Token Claim value for the account provided"),n.logoutHint=i)}else this.logger.verbose("logoutHint was not set and account was not passed into logout request, logoutHint will not be set");else this.logger.verbose("logoutHint will not be set since no logout request was configured");return!t||t.postLogoutRedirectUri!==null?t&&t.postLogoutRedirectUri?(this.logger.verbose("Setting postLogoutRedirectUri to uri set on logout request",n.correlationId),n.postLogoutRedirectUri=Gt.getAbsoluteUrl(t.postLogoutRedirectUri,hn.getCurrentUri())):this.config.auth.postLogoutRedirectUri===null?this.logger.verbose("postLogoutRedirectUri configured as null and no uri set on request, not passing post logout redirect",n.correlationId):this.config.auth.postLogoutRedirectUri?(this.logger.verbose("Setting postLogoutRedirectUri to configured uri",n.correlationId),n.postLogoutRedirectUri=Gt.getAbsoluteUrl(this.config.auth.postLogoutRedirectUri,hn.getCurrentUri())):(this.logger.verbose("Setting postLogoutRedirectUri to current page",n.correlationId),n.postLogoutRedirectUri=Gt.getAbsoluteUrl(hn.getCurrentUri(),hn.getCurrentUri())):this.logger.verbose("postLogoutRedirectUri passed as null, not setting post logout redirect uri",n.correlationId),n},e.prototype.getLogoutHintFromIdTokenClaims=function(t){var n=t.idTokenClaims;if(n){if(n.login_hint)return n.login_hint;this.logger.verbose("The ID Token Claims tied to the provided account do not contain a login_hint claim, logoutHint will not be added to logout request")}else this.logger.verbose("The provided account does not contain ID Token Claims, logoutHint will not be added to logout request");return null},e.prototype.createAuthCodeClient=function(t,n,i){return fe(this,void 0,void 0,function(){var o;return pe(this,function(a){switch(a.label){case 0:return this.performanceClient.addQueueMeasurement(ae.StandardInteractionClientCreateAuthCodeClient,this.correlationId),this.performanceClient.setPreQueueTime(ae.StandardInteractionClientGetClientConfiguration,this.correlationId),[4,this.getClientConfiguration(t,n,i)];case 1:return o=a.sent(),[2,new JR(o,this.performanceClient)]}})})},e.prototype.getClientConfiguration=function(t,n,i){return fe(this,void 0,void 0,function(){var o,a;return pe(this,function(c){switch(c.label){case 0:return this.performanceClient.addQueueMeasurement(ae.StandardInteractionClientGetClientConfiguration,this.correlationId),this.logger.verbose("getClientConfiguration called",this.correlationId),this.performanceClient.setPreQueueTime(ae.StandardInteractionClientGetDiscoveredAuthority,this.correlationId),[4,this.getDiscoveredAuthority(n,i)];case 1:return o=c.sent(),a=this.config.system.loggerOptions,[2,{authOptions:{clientId:this.config.auth.clientId,authority:o,clientCapabilities:this.config.auth.clientCapabilities},systemOptions:{tokenRenewalOffsetSeconds:this.config.system.tokenRenewalOffsetSeconds,preventCorsPreflight:!0},loggerOptions:{loggerCallback:a.loggerCallback,piiLoggingEnabled:a.piiLoggingEnabled,logLevel:a.logLevel,correlationId:this.correlationId},cacheOptions:{claimsBasedCachingEnabled:this.config.cache.claimsBasedCachingEnabled},cryptoInterface:this.browserCrypto,networkInterface:this.networkClient,storageInterface:this.browserStorage,serverTelemetryManager:t,libraryInfo:{sku:Ra.MSAL_SKU,version:Zp,cpu:G.EMPTY_STRING,os:G.EMPTY_STRING},telemetry:this.config.telemetry}]}})})},e.prototype.validateAndExtractStateFromHash=function(t,n,i){if(this.logger.verbose("validateAndExtractStateFromHash called",i),!t.state)throw Me.createHashDoesNotContainStateError();var o=nP.extractBrowserRequestState(this.browserCrypto,t.state);if(!o)throw Me.createUnableToParseStateError();if(o.interactionType!==n)throw Me.createStateInteractionTypeMismatchError();return this.logger.verbose("Returning state from hash",i),t.state},e.prototype.getDiscoveredAuthority=function(t,n){var i;return fe(this,void 0,void 0,function(){var o,a,c,d;return pe(this,function(h){switch(h.label){case 0:return this.performanceClient.addQueueMeasurement(ae.StandardInteractionClientGetDiscoveredAuthority,this.correlationId),this.logger.verbose("getDiscoveredAuthority called",this.correlationId),o=(i=this.performanceClient)===null||i===void 0?void 0:i.startMeasurement(ae.StandardInteractionClientGetDiscoveredAuthority,this.correlationId),a={protocolMode:this.config.auth.protocolMode,knownAuthorities:this.config.auth.knownAuthorities,cloudDiscoveryMetadata:this.config.auth.cloudDiscoveryMetadata,authorityMetadata:this.config.auth.authorityMetadata,skipAuthorityMetadataCache:this.config.auth.skipAuthorityMetadataCache},c=t||this.config.auth.authority,d=am.generateAuthority(c,n||this.config.auth.azureCloudOptions),this.logger.verbose("Creating discovered authority with configured authority",this.correlationId),this.performanceClient.setPreQueueTime(ae.AuthorityFactoryCreateDiscoveredInstance,this.correlationId),[4,bg.createDiscoveredInstance(d,this.config.system.networkClient,this.browserStorage,a,this.logger,this.performanceClient,this.correlationId).then(function(u){return o.endMeasurement({success:!0}),u}).catch(function(u){throw o.endMeasurement({errorCode:u.errorCode,subErrorCode:u.subError,success:!1}),u})];case 1:return[2,h.sent()]}})})},e.prototype.initializeAuthorizationRequest=function(t,n){return fe(this,void 0,void 0,function(){var i,o,a,c,d,h,u;return pe(this,function(p){switch(p.label){case 0:return this.performanceClient.addQueueMeasurement(ae.StandardInteractionClientInitializeAuthorizationRequest,this.correlationId),this.logger.verbose("initializeAuthorizationRequest called",this.correlationId),i=this.getRedirectUri(t.redirectUri),o={interactionType:n},a=fc.setRequestState(this.browserCrypto,t&&t.state||G.EMPTY_STRING,o),this.performanceClient.setPreQueueTime(ae.InitializeBaseRequest,this.correlationId),d=[{}],[4,this.initializeBaseRequest(t)];case 1:return c=qe.apply(void 0,[qe.apply(void 0,d.concat([p.sent()])),{redirectUri:i,state:a,nonce:t.nonce||this.browserCrypto.createNewGuid(),responseMode:hg.FRAGMENT}]),h=t.account||this.browserStorage.getActiveAccount(),h&&(this.logger.verbose("Setting validated request account",this.correlationId),this.logger.verbosePii("Setting validated request account: "+h.homeAccountId,this.correlationId),c.account=h),Ne.isEmpty(c.loginHint)&&!h&&(u=this.browserStorage.getLegacyLoginHint(),u&&(c.loginHint=u)),[2,c]}})})},e}(iP);/*! @azure/msal-browser v2.39.0 2024-06-06 */var $6=function(){function r(e,t,n,i,o){this.authModule=e,this.browserStorage=t,this.authCodeRequest=n,this.logger=i,this.performanceClient=o}return r.prototype.handleCodeResponseFromHash=function(e,t,n,i){return fe(this,void 0,void 0,function(){var o,a,c;return pe(this,function(d){if(this.performanceClient.addQueueMeasurement(ae.HandleCodeResponseFromHash,this.authCodeRequest.correlationId),this.logger.verbose("InteractionHandler.handleCodeResponse called"),Ne.isEmpty(e))throw Me.createEmptyHashError(e);if(o=this.browserStorage.generateStateKey(t),a=this.browserStorage.getTemporaryCache(o),!a)throw We.createStateNotFoundError("Cached State");try{c=this.authModule.handleFragmentResponse(e,a)}catch(h){throw h instanceof xu&&h.subError===xe.userCancelledError.code?Me.createUserCancelledError():h}return this.performanceClient.setPreQueueTime(ae.HandleCodeResponseFromServer,this.authCodeRequest.correlationId),[2,this.handleCodeResponseFromServer(c,t,n,i)]})})},r.prototype.handleCodeResponseFromServer=function(e,t,n,i,o){return o===void 0&&(o=!0),fe(this,void 0,void 0,function(){var a,c,d,h,u,p;return pe(this,function(v){switch(v.label){case 0:if(this.performanceClient.addQueueMeasurement(ae.HandleCodeResponseFromServer,this.authCodeRequest.correlationId),this.logger.trace("InteractionHandler.handleCodeResponseFromServer called"),a=this.browserStorage.generateStateKey(t),c=this.browserStorage.getTemporaryCache(a),!c)throw We.createStateNotFoundError("Cached State");return d=this.browserStorage.generateNonceKey(c),h=this.browserStorage.getTemporaryCache(d),this.authCodeRequest.code=e.code,e.cloud_instance_host_name?(this.performanceClient.setPreQueueTime(ae.UpdateTokenEndpointAuthority,this.authCodeRequest.correlationId),[4,this.updateTokenEndpointAuthority(e.cloud_instance_host_name,n,i)]):[3,2];case 1:v.sent(),v.label=2;case 2:return o&&(e.nonce=h||void 0),e.state=c,e.client_info?this.authCodeRequest.clientInfo=e.client_info:(u=this.checkCcsCredentials(),u&&(this.authCodeRequest.ccsCredential=u)),this.performanceClient.setPreQueueTime(ae.AuthClientAcquireToken,this.authCodeRequest.correlationId),[4,this.authModule.acquireToken(this.authCodeRequest,e)];case 3:return p=v.sent(),this.browserStorage.cleanRequestByState(t),[2,p]}})})},r.prototype.updateTokenEndpointAuthority=function(e,t,n){return fe(this,void 0,void 0,function(){var i,o;return pe(this,function(a){switch(a.label){case 0:return this.performanceClient.addQueueMeasurement(ae.UpdateTokenEndpointAuthority,this.authCodeRequest.correlationId),i="https://"+e+"/"+t.tenant+"/",[4,bg.createDiscoveredInstance(i,n,this.browserStorage,t.options,this.logger,this.performanceClient,this.authCodeRequest.correlationId)];case 1:return o=a.sent(),this.authModule.updateAuthority(o),[2]}})})},r.prototype.checkCcsCredentials=function(){var e=this.browserStorage.getTemporaryCache(er.CCS_CREDENTIAL,!0);if(e)try{return JSON.parse(e)}catch{this.authModule.logger.error("Cache credential could not be parsed"),this.authModule.logger.errorPii("Cache credential could not be parsed: "+e)}return null},r}();/*! @azure/msal-browser v2.39.0 2024-06-06 */var KC=function(r){ri(e,r);function e(t,n,i,o,a,c){var d=r.call(this,t,n,i,o,c)||this;return d.browserCrypto=a,d}return e.prototype.initiateAuthRequest=function(t,n){return fe(this,void 0,void 0,function(){var i,o;return pe(this,function(a){switch(a.label){case 0:return this.logger.verbose("RedirectHandler.initiateAuthRequest called"),Ne.isEmpty(t)?[3,7]:(n.redirectStartPage&&(this.logger.verbose("RedirectHandler.initiateAuthRequest: redirectStartPage set, caching start page"),this.browserStorage.setTemporaryCache(er.ORIGIN_URI,n.redirectStartPage,!0)),this.browserStorage.setTemporaryCache(er.CORRELATION_ID,this.authCodeRequest.correlationId,!0),this.browserStorage.cacheCodeRequest(this.authCodeRequest,this.browserCrypto),this.logger.infoPii("RedirectHandler.initiateAuthRequest: Navigate to: "+t),i={apiId:$r.acquireTokenRedirect,timeout:n.redirectTimeout,noHistory:!1},typeof n.onRedirectNavigate!="function"?[3,4]:(this.logger.verbose("RedirectHandler.initiateAuthRequest: Invoking onRedirectNavigate callback"),o=n.onRedirectNavigate(t),o===!1?[3,2]:(this.logger.verbose("RedirectHandler.initiateAuthRequest: onRedirectNavigate did not return false, navigating"),[4,n.navigationClient.navigateExternal(t,i)])));case 1:return a.sent(),[2];case 2:return this.logger.verbose("RedirectHandler.initiateAuthRequest: onRedirectNavigate returned false, stopping navigation"),[2];case 3:return[3,6];case 4:return this.logger.verbose("RedirectHandler.initiateAuthRequest: Navigating window to navigate url"),[4,n.navigationClient.navigateExternal(t,i)];case 5:return a.sent(),[2];case 6:return[3,8];case 7:throw this.logger.info("RedirectHandler.initiateAuthRequest: Navigate url is empty"),Me.createEmptyNavigationUriError();case 8:return[2]}})})},e.prototype.handleCodeResponseFromHash=function(t,n,i,o){return fe(this,void 0,void 0,function(){var a,c,d,h,u,p,v;return pe(this,function(g){switch(g.label){case 0:if(this.logger.verbose("RedirectHandler.handleCodeResponse called"),Ne.isEmpty(t))throw Me.createEmptyHashError(t);if(this.browserStorage.setInteractionInProgress(!1),a=this.browserStorage.generateStateKey(n),c=this.browserStorage.getTemporaryCache(a),!c)throw We.createStateNotFoundError("Cached State");try{d=this.authModule.handleFragmentResponse(t,c)}catch(_){throw _ instanceof xu&&_.subError===xe.userCancelledError.code?Me.createUserCancelledError():_}return h=this.browserStorage.generateNonceKey(c),u=this.browserStorage.getTemporaryCache(h),this.authCodeRequest.code=d.code,d.cloud_instance_host_name?[4,this.updateTokenEndpointAuthority(d.cloud_instance_host_name,i,o)]:[3,2];case 1:g.sent(),g.label=2;case 2:return d.nonce=u||void 0,d.state=c,d.client_info?this.authCodeRequest.clientInfo=d.client_info:(p=this.checkCcsCredentials(),p&&(this.authCodeRequest.ccsCredential=p)),[4,this.authModule.acquireToken(this.authCodeRequest,d)];case 3:return v=g.sent(),this.browserStorage.cleanRequestByState(n),[2,v]}})})},e}($6);/*! @azure/msal-browser v2.39.0 2024-06-06 */var Ct;(function(r){r.INITIALIZE_START="msal:initializeStart",r.INITIALIZE_END="msal:initializeEnd",r.ACCOUNT_ADDED="msal:accountAdded",r.ACCOUNT_REMOVED="msal:accountRemoved",r.LOGIN_START="msal:loginStart",r.LOGIN_SUCCESS="msal:loginSuccess",r.LOGIN_FAILURE="msal:loginFailure",r.ACQUIRE_TOKEN_START="msal:acquireTokenStart",r.ACQUIRE_TOKEN_SUCCESS="msal:acquireTokenSuccess",r.ACQUIRE_TOKEN_FAILURE="msal:acquireTokenFailure",r.ACQUIRE_TOKEN_NETWORK_START="msal:acquireTokenFromNetworkStart",r.SSO_SILENT_START="msal:ssoSilentStart",r.SSO_SILENT_SUCCESS="msal:ssoSilentSuccess",r.SSO_SILENT_FAILURE="msal:ssoSilentFailure",r.ACQUIRE_TOKEN_BY_CODE_START="msal:acquireTokenByCodeStart",r.ACQUIRE_TOKEN_BY_CODE_SUCCESS="msal:acquireTokenByCodeSuccess",r.ACQUIRE_TOKEN_BY_CODE_FAILURE="msal:acquireTokenByCodeFailure",r.HANDLE_REDIRECT_START="msal:handleRedirectStart",r.HANDLE_REDIRECT_END="msal:handleRedirectEnd",r.POPUP_OPENED="msal:popupOpened",r.LOGOUT_START="msal:logoutStart",r.LOGOUT_SUCCESS="msal:logoutSuccess",r.LOGOUT_FAILURE="msal:logoutFailure",r.LOGOUT_END="msal:logoutEnd",r.RESTORE_FROM_BFCACHE="msal:restoreFromBFCache"})(Ct||(Ct={}));/*! @azure/msal-browser v2.39.0 2024-06-06 */var ml;(function(r){r.USER_INTERACTION_REQUIRED="USER_INTERACTION_REQUIRED",r.USER_CANCEL="USER_CANCEL",r.NO_NETWORK="NO_NETWORK",r.TRANSIENT_ERROR="TRANSIENT_ERROR",r.PERSISTENT_ERROR="PERSISTENT_ERROR",r.DISABLED="DISABLED",r.ACCOUNT_UNAVAILABLE="ACCOUNT_UNAVAILABLE"})(ml||(ml={}));var L1={extensionError:{code:"ContentError"},userSwitch:{code:"user_switch",desc:"User attempted to switch accounts in the native broker, which is not allowed. All new accounts must sign-in through the standard web flow first, please try again."},tokensNotFoundInCache:{code:"tokens_not_found_in_internal_memory_cache",desc:"Tokens not cached in MSAL JS internal memory, please make the WAM request"}},us=function(r){ri(e,r);function e(t,n,i){var o=r.call(this,t,n)||this;return Object.setPrototypeOf(o,e.prototype),o.name="NativeAuthError",o.ext=i,o}return e.prototype.isFatal=function(){if(this.ext&&this.ext.status&&(this.ext.status===ml.PERSISTENT_ERROR||this.ext.status===ml.DISABLED))return!0;switch(this.errorCode){case L1.extensionError.code:return!0;default:return!1}},e.createError=function(t,n,i){if(i&&i.status)switch(i.status){case ml.ACCOUNT_UNAVAILABLE:return $a.createNativeAccountUnavailableError();case ml.USER_INTERACTION_REQUIRED:return new $a(t,n);case ml.USER_CANCEL:return Me.createUserCancelledError();case ml.NO_NETWORK:return Me.createNoNetworkConnectivityError()}return new e(t,n,i)},e.createUserSwitchError=function(){return new e(L1.userSwitch.code,L1.userSwitch.desc)},e.createTokensNotFoundInCacheError=function(){return new e(L1.tokensNotFoundInCache.code,L1.tokensNotFoundInCache.desc)},e}(it);/*! @azure/msal-browser v2.39.0 2024-06-06 */var oP=function(r){ri(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.acquireToken=function(t){return fe(this,void 0,void 0,function(){var n,i,o,a,c;return pe(this,function(d){switch(d.label){case 0:return n=this.performanceClient.startMeasurement(ae.SilentCacheClientAcquireToken,t.correlationId),i=this.initializeServerTelemetryManager($r.acquireTokenSilent_silentFlow),[4,this.createSilentFlowClient(i,t.authority,t.azureCloudOptions)];case 1:o=d.sent(),this.logger.verbose("Silent auth client created"),d.label=2;case 2:return d.trys.push([2,4,,5]),[4,o.acquireCachedToken(t)];case 3:return a=d.sent(),n.endMeasurement({success:!0,fromCache:!0}),[2,a];case 4:throw c=d.sent(),c instanceof Me&&c.errorCode===xe.signingKeyNotFoundInStorage.code&&this.logger.verbose("Signing keypair for bound access token not found. Refreshing bound access token and generating a new crypto keypair."),n.endMeasurement({errorCode:c instanceof it&&c.errorCode||void 0,subErrorCode:c instanceof it&&c.subError||void 0,success:!1}),c;case 5:return[2]}})})},e.prototype.logout=function(){return Promise.reject(Me.createSilentLogoutUnsupportedError())},e.prototype.createSilentFlowClient=function(t,n,i){return fe(this,void 0,void 0,function(){var o;return pe(this,function(a){switch(a.label){case 0:return this.performanceClient.setPreQueueTime(ae.StandardInteractionClientGetClientConfiguration,this.correlationId),[4,this.getClientConfiguration(t,n,i)];case 1:return o=a.sent(),[2,new UV(o,this.performanceClient)]}})})},e.prototype.initializeSilentRequest=function(t,n){return fe(this,void 0,void 0,function(){var i;return pe(this,function(o){switch(o.label){case 0:return this.performanceClient.addQueueMeasurement(ae.InitializeSilentRequest,this.correlationId),this.performanceClient.setPreQueueTime(ae.InitializeBaseRequest,this.correlationId),i=[qe({},t)],[4,this.initializeBaseRequest(t,n)];case 1:return[2,qe.apply(void 0,[qe.apply(void 0,i.concat([o.sent()])),{account:n,forceRefresh:t.forceRefresh||!1}])]}})})},e}(Ff);/*! @azure/msal-browser v2.39.0 2024-06-06 */var cf=function(r){ri(e,r);function e(t,n,i,o,a,c,d,h,u,p,v,g){var _=r.call(this,t,n,i,o,a,c,h,u,g)||this;return _.apiId=d,_.accountId=p,_.nativeMessageHandler=u,_.nativeStorageManager=v,_.silentCacheClient=new oP(t,_.nativeStorageManager,i,o,a,c,h,u,g),_}return e.prototype.acquireToken=function(t){return fe(this,void 0,void 0,function(){var n,i,o,a,c,d,h;return pe(this,function(u){switch(u.label){case 0:return this.logger.trace("NativeInteractionClient - acquireToken called."),n=this.performanceClient.startMeasurement(ae.NativeInteractionClientAcquireToken,t.correlationId),i=ra.nowSeconds(),[4,this.initializeNativeRequest(t)];case 1:o=u.sent(),u.label=2;case 2:return u.trys.push([2,4,,5]),[4,this.acquireTokensFromCache(this.accountId,o)];case 3:return a=u.sent(),n.endMeasurement({success:!0,isNativeBroker:!1,fromCache:!0}),[2,a];case 4:return u.sent(),this.logger.info("MSAL internal Cache does not contain tokens, proceed to make a native call"),[3,5];case 5:return c={method:sc.GetToken,request:o},[4,this.nativeMessageHandler.sendMessage(c)];case 6:return d=u.sent(),h=this.validateNativeResponse(d),[2,this.handleNativeResponse(h,o,i).then(function(p){return n.endMeasurement({success:!0,isNativeBroker:!0,requestId:p.requestId}),p}).catch(function(p){throw n.endMeasurement({success:!1,errorCode:p.errorCode,subErrorCode:p.subError,isNativeBroker:!0}),p})]}})})},e.prototype.createSilentCacheRequest=function(t,n){return{authority:t.authority,correlationId:this.correlationId,scopes:gi.fromString(t.scope).asArray(),account:n,forceRefresh:!1}},e.prototype.acquireTokensFromCache=function(t,n){return fe(this,void 0,void 0,function(){var i,o,a,c,d;return pe(this,function(h){switch(h.label){case 0:if(!t)throw this.logger.warning("NativeInteractionClient:acquireTokensFromCache - No nativeAccountId provided"),We.createNoAccountFoundError();if(i=this.browserStorage.getAccountInfoFilteredBy({nativeAccountId:t}),!i)throw We.createNoAccountFoundError();h.label=1;case 1:return h.trys.push([1,3,,4]),o=this.createSilentCacheRequest(n,i),[4,this.silentCacheClient.acquireToken(o)];case 2:return a=h.sent(),c=qe(qe({},i),{idTokenClaims:a.idTokenClaims}),[2,qe(qe({},a),{account:c})];case 3:throw d=h.sent(),d;case 4:return[2]}})})},e.prototype.acquireTokenRedirect=function(t){return fe(this,void 0,void 0,function(){var n,i,o,a,c,d;return pe(this,function(h){switch(h.label){case 0:return this.logger.trace("NativeInteractionClient - acquireTokenRedirect called."),[4,this.initializeNativeRequest(t)];case 1:n=h.sent(),i={method:sc.GetToken,request:n},h.label=2;case 2:return h.trys.push([2,4,,5]),[4,this.nativeMessageHandler.sendMessage(i)];case 3:return o=h.sent(),this.validateNativeResponse(o),[3,5];case 4:if(a=h.sent(),a instanceof us&&a.isFatal())throw a;return[3,5];case 5:return this.browserStorage.setTemporaryCache(er.NATIVE_REQUEST,JSON.stringify(n),!0),c={apiId:$r.acquireTokenRedirect,timeout:this.config.system.redirectNavigationTimeout,noHistory:!1},d=this.config.auth.navigateToLoginRequestUrl?window.location.href:this.getRedirectUri(t.redirectUri),[4,this.navigationClient.navigateExternal(d,c)];case 6:return h.sent(),[2]}})})},e.prototype.handleRedirectPromise=function(){return fe(this,void 0,void 0,function(){var t,n,i,o,a,c,d,h;return pe(this,function(u){switch(u.label){case 0:if(this.logger.trace("NativeInteractionClient - handleRedirectPromise called."),!this.browserStorage.isInteractionInProgress(!0))return this.logger.info("handleRedirectPromise called but there is no interaction in progress, returning null."),[2,null];if(t=this.browserStorage.getCachedNativeRequest(),!t)return this.logger.verbose("NativeInteractionClient - handleRedirectPromise called but there is no cached request, returning null."),[2,null];n=t.prompt,i=ZC(t,["prompt"]),n&&this.logger.verbose("NativeInteractionClient - handleRedirectPromise called and prompt was included in the original request, removing prompt from cached request to prevent second interaction with native broker window."),this.browserStorage.removeItem(this.browserStorage.generateCacheKey(er.NATIVE_REQUEST)),o={method:sc.GetToken,request:i},a=ra.nowSeconds(),u.label=1;case 1:return u.trys.push([1,3,,4]),this.logger.verbose("NativeInteractionClient - handleRedirectPromise sending message to native broker."),[4,this.nativeMessageHandler.sendMessage(o)];case 2:return c=u.sent(),this.validateNativeResponse(c),d=this.handleNativeResponse(c,i,a),this.browserStorage.setInteractionInProgress(!1),[2,d];case 3:throw h=u.sent(),this.browserStorage.setInteractionInProgress(!1),h;case 4:return[2]}})})},e.prototype.logout=function(){return this.logger.trace("NativeInteractionClient - logout called."),Promise.reject("Logout not implemented yet")},e.prototype.handleNativeResponse=function(t,n,i){return fe(this,void 0,void 0,function(){var o,a,c,d,h;return pe(this,function(u){switch(u.label){case 0:if(this.logger.trace("NativeInteractionClient - handleNativeResponse called."),t.account.id!==n.accountId)throw us.createUserSwitchError();return[4,this.getDiscoveredAuthority(n.authority)];case 1:return o=u.sent(),a=this.createIdTokenObj(t),c=this.createHomeAccountIdentifier(t,a),d=Ci.createAccount({homeAccountId:c,idTokenClaims:a.claims,clientInfo:t.client_info,nativeAccountId:t.account.id},o),[4,this.generateAuthenticationResult(t,n,a,d,o.canonicalAuthority,i)];case 2:return h=u.sent(),this.cacheAccount(d),this.cacheNativeTokens(t,n,c,a,h.accessToken,h.tenantId,i),[2,h]}})})},e.prototype.createIdTokenObj=function(t){return new xs(t.id_token||G.EMPTY_STRING,this.browserCrypto)},e.prototype.createHomeAccountIdentifier=function(t,n){var i=Ci.generateHomeAccountId(t.client_info||G.EMPTY_STRING,io.Default,this.logger,this.browserCrypto,n.claims);return i},e.prototype.generateScopes=function(t,n){return t.scope?gi.fromString(t.scope):gi.fromString(n.scope)},e.prototype.generatePopAccessToken=function(t,n){return fe(this,void 0,void 0,function(){var i,o;return pe(this,function(a){switch(a.label){case 0:if(n.tokenType!==mr.POP)return[3,2];if(t.shr)return this.logger.trace("handleNativeServerResponse: SHR is enabled in native layer"),[2,t.shr];if(i=new _f(this.browserCrypto),o={resourceRequestMethod:n.resourceRequestMethod,resourceRequestUri:n.resourceRequestUri,shrClaims:n.shrClaims,shrNonce:n.shrNonce},!n.keyId)throw We.createKeyIdMissingError();return[4,i.signPopToken(t.access_token,n.keyId,o)];case 1:return[2,a.sent()];case 2:return[2,t.access_token]}})})},e.prototype.generateAuthenticationResult=function(t,n,i,o,a,c){return fe(this,void 0,void 0,function(){var d,h,u,p,v,g,_,b;return pe(this,function(C){switch(C.label){case 0:return d=this.addTelemetryFromNativeResponse(t),h=t.scope?gi.fromString(t.scope):gi.fromString(n.scope),u=t.account.properties||{},p=u.UID||i.claims.oid||i.claims.sub||G.EMPTY_STRING,v=u.TenantId||i.claims.tid||G.EMPTY_STRING,[4,this.generatePopAccessToken(t,n)];case 1:return g=C.sent(),_=n.tokenType===mr.POP?mr.POP:mr.BEARER,b={authority:a,uniqueId:p,tenantId:v,scopes:h.asArray(),account:o.getAccountInfo(),idToken:t.id_token,idTokenClaims:i.claims,accessToken:g,fromCache:d?this.isResponseFromCache(d):!1,expiresOn:new Date(Number(c+t.expires_in)*1e3),tokenType:_,correlationId:this.correlationId,state:t.state,fromNativeBroker:!0},[2,b]}})})},e.prototype.cacheAccount=function(t){var n=this;this.browserStorage.setAccount(t),this.browserStorage.removeAccountContext(t).catch(function(i){n.logger.error("Error occurred while removing account context from browser storage. "+i)})},e.prototype.cacheNativeTokens=function(t,n,i,o,a,c,d){var h=gl.createIdTokenEntity(i,n.authority,t.id_token||G.EMPTY_STRING,n.clientId,o.claims.tid||G.EMPTY_STRING),u=n.tokenType===mr.POP?G.SHR_NONCE_VALIDITY:(typeof t.expires_in=="string"?parseInt(t.expires_in,10):t.expires_in)||0,p=d+u,v=this.generateScopes(t,n),g=yl.createAccessTokenEntity(i,n.authority,a,n.clientId,o?o.claims.tid||G.EMPTY_STRING:c,v.printScopes(),p,0,this.browserCrypto),_=new sf(void 0,h,g);this.nativeStorageManager.saveCacheRecord(_)},e.prototype.addTelemetryFromNativeResponse=function(t){var n=this.getMATSFromResponse(t);return n?(this.performanceClient.addStaticFields({extensionId:this.nativeMessageHandler.getExtensionId(),extensionVersion:this.nativeMessageHandler.getExtensionVersion(),matsBrokerVersion:n.broker_version,matsAccountJoinOnStart:n.account_join_on_start,matsAccountJoinOnEnd:n.account_join_on_end,matsDeviceJoin:n.device_join,matsPromptBehavior:n.prompt_behavior,matsApiErrorCode:n.api_error_code,matsUiVisible:n.ui_visible,matsSilentCode:n.silent_code,matsSilentBiSubCode:n.silent_bi_sub_code,matsSilentMessage:n.silent_message,matsSilentStatus:n.silent_status,matsHttpStatus:n.http_status,matsHttpEventCount:n.http_event_count},this.correlationId),n):null},e.prototype.validateNativeResponse=function(t){if(t.hasOwnProperty("access_token")&&t.hasOwnProperty("id_token")&&t.hasOwnProperty("client_info")&&t.hasOwnProperty("account")&&t.hasOwnProperty("scope")&&t.hasOwnProperty("expires_in"))return t;throw us.createUnexpectedError("Response missing expected properties.")},e.prototype.getMATSFromResponse=function(t){if(t.properties.MATS)try{return JSON.parse(t.properties.MATS)}catch{this.logger.error("NativeInteractionClient - Error parsing MATS telemetry, returning null instead")}return null},e.prototype.isResponseFromCache=function(t){return typeof t.is_cached>"u"?(this.logger.verbose("NativeInteractionClient - MATS telemetry does not contain field indicating if response was served from cache. Returning false."),!1):!!t.is_cached},e.prototype.initializeNativeRequest=function(t){return fe(this,void 0,void 0,function(){var n,i,o,a,c,d,h,u,p,v,g=this;return pe(this,function(_){switch(_.label){case 0:return this.logger.trace("NativeInteractionClient - initializeNativeRequest called"),n=t.authority||this.config.auth.authority,t.account?[4,this.validateRequestAuthority(n,t.account)]:[3,2];case 1:_.sent(),_.label=2;case 2:return i=new Gt(n),i.validateAsUri(),o=t.scopes,a=ZC(t,["scopes"]),c=new gi(o||[]),c.appendScopes(Zm),d=function(){switch(g.apiId){case $r.ssoSilent:case $r.acquireTokenSilent_silentFlow:return g.logger.trace("initializeNativeRequest: silent request sets prompt to none"),wi.NONE}if(!t.prompt){g.logger.trace("initializeNativeRequest: prompt was not provided");return}switch(t.prompt){case wi.NONE:case wi.CONSENT:case wi.LOGIN:return g.logger.trace("initializeNativeRequest: prompt is compatible with native flow"),t.prompt;default:throw g.logger.trace("initializeNativeRequest: prompt = "+t.prompt+" is not compatible with native flow"),Me.createNativePromptParameterNotSupportedError()}},h=qe(qe({},a),{accountId:this.accountId,clientId:this.config.auth.clientId,authority:i.urlString,scope:c.printScopes(),redirectUri:this.getRedirectUri(t.redirectUri),prompt:d(),correlationId:this.correlationId,tokenType:t.authenticationScheme,windowTitleSubstring:document.title,extraParameters:qe(qe(qe({},t.extraQueryParameters),t.tokenQueryParameters),{telemetry:cp.MATS_TELEMETRY}),extendedExpiryToken:!1}),t.authenticationScheme!==mr.POP?[3,4]:(u={resourceRequestUri:t.resourceRequestUri,resourceRequestMethod:t.resourceRequestMethod,shrClaims:t.shrClaims,shrNonce:t.shrNonce},p=new _f(this.browserCrypto),[4,p.generateCnf(u)]);case 3:v=_.sent(),h.reqCnf=v.reqCnfString,h.keyId=v.kid,_.label=4;case 4:return[2,h]}})})},e}(iP);/*! @azure/msal-browser v2.39.0 2024-06-06 */var du=function(){function r(e,t,n,i){this.logger=e,this.handshakeTimeoutMs=t,this.extensionId=i,this.resolvers=new Map,this.handshakeResolvers=new Map,this.responseId=0,this.messageChannel=new MessageChannel,this.windowListener=this.onWindowMessage.bind(this),this.performanceClient=n,this.handshakeEvent=n.startMeasurement(ae.NativeMessageHandlerHandshake)}return r.prototype.sendMessage=function(e){return fe(this,void 0,void 0,function(){var t,n=this;return pe(this,function(i){return this.logger.trace("NativeMessageHandler - sendMessage called."),t={channel:cp.CHANNEL_ID,extensionId:this.extensionId,responseId:this.responseId++,body:e},this.logger.trace("NativeMessageHandler - Sending request to browser extension"),this.logger.tracePii("NativeMessageHandler - Sending request to browser extension: "+JSON.stringify(t)),this.messageChannel.port1.postMessage(t),[2,new Promise(function(o,a){n.resolvers.set(t.responseId,{resolve:o,reject:a})})]})})},r.createProvider=function(e,t,n){return fe(this,void 0,void 0,function(){var i,o;return pe(this,function(a){switch(a.label){case 0:e.trace("NativeMessageHandler - createProvider called."),a.label=1;case 1:return a.trys.push([1,3,,5]),i=new r(e,t,n,cp.PREFERRED_EXTENSION_ID),[4,i.sendHandshakeRequest()];case 2:return a.sent(),[2,i];case 3:return a.sent(),o=new r(e,t,n),[4,o.sendHandshakeRequest()];case 4:return a.sent(),[2,o];case 5:return[2]}})})},r.prototype.sendHandshakeRequest=function(){return fe(this,void 0,void 0,function(){var e,t=this;return pe(this,function(n){return this.logger.trace("NativeMessageHandler - sendHandshakeRequest called."),window.addEventListener("message",this.windowListener,!1),e={channel:cp.CHANNEL_ID,extensionId:this.extensionId,responseId:this.responseId++,body:{method:sc.HandshakeRequest}},this.handshakeEvent.addStaticFields({extensionId:this.extensionId,extensionHandshakeTimeoutMs:this.handshakeTimeoutMs}),this.messageChannel.port1.onmessage=function(i){t.onChannelMessage(i)},window.postMessage(e,window.origin,[this.messageChannel.port2]),[2,new Promise(function(i,o){t.handshakeResolvers.set(e.responseId,{resolve:i,reject:o}),t.timeoutId=window.setTimeout(function(){window.removeEventListener("message",t.windowListener,!1),t.messageChannel.port1.close(),t.messageChannel.port2.close(),t.handshakeEvent.endMeasurement({extensionHandshakeTimedOut:!0,success:!1}),o(Me.createNativeHandshakeTimeoutError()),t.handshakeResolvers.delete(e.responseId)},t.handshakeTimeoutMs)})]})})},r.prototype.onWindowMessage=function(e){if(this.logger.trace("NativeMessageHandler - onWindowMessage called"),e.source===window){var t=e.data;if(!(!t.channel||t.channel!==cp.CHANNEL_ID)&&!(t.extensionId&&t.extensionId!==this.extensionId)&&t.body.method===sc.HandshakeRequest){this.logger.verbose(t.extensionId?"Extension with id: "+t.extensionId+" not installed":"No extension installed"),clearTimeout(this.timeoutId),this.messageChannel.port1.close(),this.messageChannel.port2.close(),window.removeEventListener("message",this.windowListener,!1);var n=this.handshakeResolvers.get(t.responseId);n&&(this.handshakeEvent.endMeasurement({success:!1,extensionInstalled:!1}),n.reject(Me.createNativeExtensionNotInstalledError()))}}},r.prototype.onChannelMessage=function(e){this.logger.trace("NativeMessageHandler - onChannelMessage called.");var t=e.data,n=this.resolvers.get(t.responseId),i=this.handshakeResolvers.get(t.responseId);try{var o=t.body.method;if(o===sc.Response){if(!n)return;var a=t.body.response;if(this.logger.trace("NativeMessageHandler - Received response from browser extension"),this.logger.tracePii("NativeMessageHandler - Received response from browser extension: "+JSON.stringify(a)),a.status!=="Success")n.reject(us.createError(a.code,a.description,a.ext));else if(a.result)a.result.code&&a.result.description?n.reject(us.createError(a.result.code,a.result.description,a.result.ext)):n.resolve(a.result);else throw it.createUnexpectedError("Event does not contain result.");this.resolvers.delete(t.responseId)}else if(o===sc.HandshakeResponse){if(!i)return;clearTimeout(this.timeoutId),window.removeEventListener("message",this.windowListener,!1),this.extensionId=t.extensionId,this.extensionVersion=t.body.version,this.logger.verbose("NativeMessageHandler - Received HandshakeResponse from extension: "+this.extensionId),this.handshakeEvent.endMeasurement({extensionInstalled:!0,success:!0}),i.resolve(),this.handshakeResolvers.delete(t.responseId)}}catch(c){this.logger.error("Error parsing response from WAM Extension"),this.logger.errorPii("Error parsing response from WAM Extension: "+c.toString()),this.logger.errorPii("Unable to parse "+e),n?n.reject(c):i&&i.reject(c)}},r.prototype.getExtensionId=function(){return this.extensionId},r.prototype.getExtensionVersion=function(){return this.extensionVersion},r.isNativeAvailable=function(e,t,n,i){if(t.trace("isNativeAvailable called"),!e.system.allowNativeBroker)return t.trace("isNativeAvailable: allowNativeBroker is not enabled, returning false"),!1;if(!n)return t.trace("isNativeAvailable: WAM extension provider is not initialized, returning false"),!1;if(i)switch(i){case mr.BEARER:case mr.POP:return t.trace("isNativeAvailable: authenticationScheme is supported, returning true"),!0;default:return t.trace("isNativeAvailable: authenticationScheme is not supported, returning false"),!1}return!0},r}();/*! @azure/msal-browser v2.39.0 2024-06-06 */var oF=function(r){ri(e,r);function e(t,n,i,o,a,c,d,h,u,p){var v=r.call(this,t,n,i,o,a,c,d,u,p)||this;return v.nativeStorage=h,v}return e.prototype.acquireToken=function(t){return fe(this,void 0,void 0,function(){var n,i,o,a,c,d,h,u,p,v=this;return pe(this,function(g){switch(g.label){case 0:return this.performanceClient.setPreQueueTime(ae.StandardInteractionClientInitializeAuthorizationRequest,t.correlationId),[4,this.initializeAuthorizationRequest(t,et.Redirect)];case 1:n=g.sent(),this.browserStorage.updateCacheEntries(n.state,n.nonce,n.authority,n.loginHint||G.EMPTY_STRING,n.account||null),i=this.initializeServerTelemetryManager($r.acquireTokenRedirect),o=function(_){_.persisted&&(v.logger.verbose("Page was restored from back/forward cache. Clearing temporary cache."),v.browserStorage.cleanRequestByState(n.state),v.eventHandler.emitEvent(Ct.RESTORE_FROM_BFCACHE,et.Redirect))},g.label=2;case 2:return g.trys.push([2,7,,8]),this.performanceClient.setPreQueueTime(ae.StandardInteractionClientInitializeAuthorizationCodeRequest,t.correlationId),[4,this.initializeAuthorizationCodeRequest(n)];case 3:return a=g.sent(),this.performanceClient.setPreQueueTime(ae.StandardInteractionClientCreateAuthCodeClient,t.correlationId),[4,this.createAuthCodeClient(i,n.authority,n.azureCloudOptions)];case 4:return c=g.sent(),this.logger.verbose("Auth code client created"),d=new KC(c,this.browserStorage,a,this.logger,this.browserCrypto,this.performanceClient),[4,c.getAuthCodeUrl(qe(qe({},n),{nativeBroker:du.isNativeAvailable(this.config,this.logger,this.nativeMessageHandler,t.authenticationScheme)}))];case 5:return h=g.sent(),u=this.getRedirectStartPage(t.redirectStartPage),this.logger.verbosePii("Redirect start page: "+u),window.addEventListener("pageshow",o),[4,d.initiateAuthRequest(h,{navigationClient:this.navigationClient,redirectTimeout:this.config.system.redirectNavigationTimeout,redirectStartPage:u,onRedirectNavigate:t.onRedirectNavigate})];case 6:return[2,g.sent()];case 7:throw p=g.sent(),p instanceof it&&p.setCorrelationId(this.correlationId),window.removeEventListener("pageshow",o),i.cacheFailedRequest(p),this.browserStorage.cleanRequestByState(n.state),p;case 8:return[2]}})})},e.prototype.handleRedirectPromise=function(t){return fe(this,void 0,void 0,function(){var n,i,o,a,c,d,h,u,p,v,g,_;return pe(this,function(b){switch(b.label){case 0:n=this.initializeServerTelemetryManager($r.handleRedirectPromise),b.label=1;case 1:if(b.trys.push([1,10,,11]),!this.browserStorage.isInteractionInProgress(!0))return this.logger.info("handleRedirectPromise called but there is no interaction in progress, returning null."),[2,null];if(i=this.getRedirectResponseHash(t||window.location.hash),!i)return this.logger.info("handleRedirectPromise did not detect a response hash as a result of a redirect. Cleaning temporary cache."),this.browserStorage.cleanRequestByInteractionType(et.Redirect),[2,null];o=void 0;try{a=Gt.getDeserializedHash(i),o=this.validateAndExtractStateFromHash(a,et.Redirect),this.logger.verbose("State extracted from hash")}catch(C){return this.logger.info("handleRedirectPromise was unable to extract state due to: "+C),this.browserStorage.cleanRequestByInteractionType(et.Redirect),[2,null]}return c=this.browserStorage.getTemporaryCache(er.ORIGIN_URI,!0)||G.EMPTY_STRING,d=Gt.removeHashFromUrl(c),h=Gt.removeHashFromUrl(window.location.href),d===h&&this.config.auth.navigateToLoginRequestUrl?(this.logger.verbose("Current page is loginRequestUrl, handling hash"),[4,this.handleHash(i,o,n)]):[3,3];case 2:return u=b.sent(),c.indexOf("#")>-1&&hn.replaceHash(c),[2,u];case 3:return this.config.auth.navigateToLoginRequestUrl?[3,4]:(this.logger.verbose("NavigateToLoginRequestUrl set to false, handling hash"),[2,this.handleHash(i,o,n)]);case 4:return!hn.isInIframe()||this.config.system.allowRedirectInIframe?(this.browserStorage.setTemporaryCache(er.URL_HASH,i,!0),p={apiId:$r.handleRedirectPromise,timeout:this.config.system.redirectNavigationTimeout,noHistory:!0},v=!0,!c||c==="null"?(g=hn.getHomepage(),this.browserStorage.setTemporaryCache(er.ORIGIN_URI,g,!0),this.logger.warning("Unable to get valid login request url from cache, redirecting to home page"),[4,this.navigationClient.navigateInternal(g,p)]):[3,6]):[3,9];case 5:return v=b.sent(),[3,8];case 6:return this.logger.verbose("Navigating to loginRequestUrl: "+c),[4,this.navigationClient.navigateInternal(c,p)];case 7:v=b.sent(),b.label=8;case 8:if(!v)return[2,this.handleHash(i,o,n)];b.label=9;case 9:return[2,null];case 10:throw _=b.sent(),_ instanceof it&&_.setCorrelationId(this.correlationId),n.cacheFailedRequest(_),this.browserStorage.cleanRequestByInteractionType(et.Redirect),_;case 11:return[2]}})})},e.prototype.getRedirectResponseHash=function(t){this.logger.verbose("getRedirectResponseHash called");var n=Gt.hashContainsKnownProperties(t);if(n)return hn.clearHash(window),this.logger.verbose("Hash contains known properties, returning response hash"),t;var i=this.browserStorage.getTemporaryCache(er.URL_HASH,!0);return this.browserStorage.removeItem(this.browserStorage.generateCacheKey(er.URL_HASH)),this.logger.verbose("Hash does not contain known properties, returning cached hash"),i},e.prototype.handleHash=function(t,n,i){return fe(this,void 0,void 0,function(){var o,a,c,d,h,u,p,v=this;return pe(this,function(g){switch(g.label){case 0:if(o=this.browserStorage.getCachedRequest(n,this.browserCrypto),this.logger.verbose("handleHash called, retrieved cached request"),a=Gt.getDeserializedHash(t),a.accountId){if(this.logger.verbose("Account id found in hash, calling WAM for token"),!this.nativeMessageHandler)throw Me.createNativeConnectionNotEstablishedError();return c=new cf(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,$r.acquireTokenPopup,this.performanceClient,this.nativeMessageHandler,a.accountId,this.nativeStorage,o.correlationId),d=fc.parseRequestState(this.browserCrypto,n).userRequestState,[2,c.acquireToken(qe(qe({},o),{state:d,prompt:void 0})).finally(function(){v.browserStorage.cleanRequestByState(n)})]}if(h=this.browserStorage.getCachedAuthority(n),!h)throw Me.createNoCachedAuthorityError();return this.performanceClient.setPreQueueTime(ae.StandardInteractionClientCreateAuthCodeClient,o.correlationId),[4,this.createAuthCodeClient(i,h)];case 1:return u=g.sent(),this.logger.verbose("Auth code client created"),gg.removeThrottle(this.browserStorage,this.config.auth.clientId,o),p=new KC(u,this.browserStorage,o,this.logger,this.browserCrypto,this.performanceClient),[4,p.handleCodeResponseFromHash(t,n,u.authority,this.networkClient)];case 2:return[2,g.sent()]}})})},e.prototype.logout=function(t){return fe(this,void 0,void 0,function(){var n,i,o,a,c,d,h;return pe(this,function(u){switch(u.label){case 0:this.logger.verbose("logoutRedirect called"),n=this.initializeLogoutRequest(t),i=this.initializeServerTelemetryManager($r.logout),u.label=1;case 1:return u.trys.push([1,10,,11]),this.eventHandler.emitEvent(Ct.LOGOUT_START,et.Redirect,t),[4,this.clearCacheOnLogout(n.account)];case 2:return u.sent(),o={apiId:$r.logout,timeout:this.config.system.redirectNavigationTimeout,noHistory:!1},this.performanceClient.setPreQueueTime(ae.StandardInteractionClientCreateAuthCodeClient,n.correlationId),[4,this.createAuthCodeClient(i,t&&t.authority)];case 3:return a=u.sent(),this.logger.verbose("Auth code client created"),c=a.getLogoutUri(n),this.eventHandler.emitEvent(Ct.LOGOUT_SUCCESS,et.Redirect,n),t&&typeof t.onRedirectNavigate=="function"?(d=t.onRedirectNavigate(c),d===!1?[3,5]:(this.logger.verbose("Logout onRedirectNavigate did not return false, navigating"),this.browserStorage.getInteractionInProgress()||this.browserStorage.setInteractionInProgress(!0),[4,this.navigationClient.navigateExternal(c,o)])):[3,7];case 4:return u.sent(),[2];case 5:this.browserStorage.setInteractionInProgress(!1),this.logger.verbose("Logout onRedirectNavigate returned false, stopping navigation"),u.label=6;case 6:return[3,9];case 7:return this.browserStorage.getInteractionInProgress()||this.browserStorage.setInteractionInProgress(!0),[4,this.navigationClient.navigateExternal(c,o)];case 8:return u.sent(),[2];case 9:return[3,11];case 10:throw h=u.sent(),h instanceof it&&h.setCorrelationId(this.correlationId),i.cacheFailedRequest(h),this.eventHandler.emitEvent(Ct.LOGOUT_FAILURE,et.Redirect,null,h),this.eventHandler.emitEvent(Ct.LOGOUT_END,et.Redirect),h;case 11:return this.eventHandler.emitEvent(Ct.LOGOUT_END,et.Redirect),[2]}})})},e.prototype.getRedirectStartPage=function(t){var n=t||window.location.href;return Gt.getAbsoluteUrl(n,hn.getCurrentUri())},e}(Ff);/*! @azure/msal-browser v2.39.0 2024-06-06 */var aF=function(r){ri(e,r);function e(t,n,i,o,a,c,d,h,u,p){var v=r.call(this,t,n,i,o,a,c,d,u,p)||this;return v.unloadWindow=v.unloadWindow.bind(v),v.nativeStorage=h,v}return e.prototype.acquireToken=function(t){try{var n=this.generatePopupName(t.scopes||Zm,t.authority||this.config.auth.authority),i=t.popupWindowAttributes||{};if(this.config.system.asyncPopups)return this.logger.verbose("asyncPopups set to true, acquiring token"),this.acquireTokenPopupAsync(t,n,i);this.logger.verbose("asyncPopup set to false, opening popup before acquiring token");var o=this.openSizedPopup("about:blank",n,i);return this.acquireTokenPopupAsync(t,n,i,o)}catch(a){return Promise.reject(a)}},e.prototype.logout=function(t){try{this.logger.verbose("logoutPopup called");var n=this.initializeLogoutRequest(t),i=this.generateLogoutPopupName(n),o=t&&t.authority,a=t&&t.mainWindowRedirectUri,c=(t==null?void 0:t.popupWindowAttributes)||{};if(this.config.system.asyncPopups)return this.logger.verbose("asyncPopups set to true"),this.logoutPopupAsync(n,i,c,o,void 0,a);this.logger.verbose("asyncPopup set to false, opening popup");var d=this.openSizedPopup("about:blank",i,c);return this.logoutPopupAsync(n,i,c,o,d,a)}catch(h){return Promise.reject(h)}},e.prototype.acquireTokenPopupAsync=function(t,n,i,o){return fe(this,void 0,void 0,function(){var a,c,d,h,u,p,v,g,_,b,C,T,S,A,Z,B,U,I=this;return pe(this,function(Y){switch(Y.label){case 0:return this.logger.verbose("acquireTokenPopupAsync called"),a=this.initializeServerTelemetryManager($r.acquireTokenPopup),this.performanceClient.setPreQueueTime(ae.StandardInteractionClientInitializeAuthorizationRequest,t.correlationId),[4,this.initializeAuthorizationRequest(t,et.Popup)];case 1:c=Y.sent(),this.browserStorage.updateCacheEntries(c.state,c.nonce,c.authority,c.loginHint||G.EMPTY_STRING,c.account||null),Y.label=2;case 2:return Y.trys.push([2,8,,9]),this.performanceClient.setPreQueueTime(ae.StandardInteractionClientInitializeAuthorizationCodeRequest,t.correlationId),[4,this.initializeAuthorizationCodeRequest(c)];case 3:return d=Y.sent(),this.performanceClient.setPreQueueTime(ae.StandardInteractionClientCreateAuthCodeClient,t.correlationId),[4,this.createAuthCodeClient(a,c.authority,c.azureCloudOptions)];case 4:return h=Y.sent(),this.logger.verbose("Auth code client created"),u=du.isNativeAvailable(this.config,this.logger,this.nativeMessageHandler,t.authenticationScheme),p=void 0,u&&(p=this.performanceClient.startMeasurement(ae.FetchAccountIdWithNativeBroker,t.correlationId)),[4,h.getAuthCodeUrl(qe(qe({},c),{nativeBroker:u}))];case 5:return v=Y.sent(),g=new $6(h,this.browserStorage,d,this.logger,this.performanceClient),_={popup:o,popupName:n,popupWindowAttributes:i},b=this.initiateAuthRequest(v,_),this.eventHandler.emitEvent(Ct.POPUP_OPENED,et.Popup,{popupWindow:b},null),[4,this.monitorPopupForHash(b)];case 6:if(C=Y.sent(),T=Gt.getDeserializedHash(C),S=this.validateAndExtractStateFromHash(T,et.Popup,c.correlationId),gg.removeThrottle(this.browserStorage,this.config.auth.clientId,d),T.accountId){if(this.logger.verbose("Account id found in hash, calling WAM for token"),p&&p.endMeasurement({success:!0,isNativeBroker:!0}),!this.nativeMessageHandler)throw Me.createNativeConnectionNotEstablishedError();return A=new cf(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,$r.acquireTokenPopup,this.performanceClient,this.nativeMessageHandler,T.accountId,this.nativeStorage,c.correlationId),Z=fc.parseRequestState(this.browserCrypto,S).userRequestState,[2,A.acquireToken(qe(qe({},c),{state:Z,prompt:void 0})).finally(function(){I.browserStorage.cleanRequestByState(S)})]}return[4,g.handleCodeResponseFromHash(C,S,h.authority,this.networkClient)];case 7:return B=Y.sent(),[2,B];case 8:throw U=Y.sent(),o&&o.close(),U instanceof it&&U.setCorrelationId(this.correlationId),a.cacheFailedRequest(U),this.browserStorage.cleanRequestByState(c.state),U;case 9:return[2]}})})},e.prototype.logoutPopupAsync=function(t,n,i,o,a,c){return fe(this,void 0,void 0,function(){var d,h,u,p,v,g,_;return pe(this,function(b){switch(b.label){case 0:this.logger.verbose("logoutPopupAsync called"),this.eventHandler.emitEvent(Ct.LOGOUT_START,et.Popup,t),d=this.initializeServerTelemetryManager($r.logoutPopup),b.label=1;case 1:return b.trys.push([1,5,,6]),[4,this.clearCacheOnLogout(t.account)];case 2:return b.sent(),this.performanceClient.setPreQueueTime(ae.StandardInteractionClientCreateAuthCodeClient,t.correlationId),[4,this.createAuthCodeClient(d,o)];case 3:return h=b.sent(),this.logger.verbose("Auth code client created"),u=h.getLogoutUri(t),this.eventHandler.emitEvent(Ct.LOGOUT_SUCCESS,et.Popup,t),p=this.openPopup(u,{popupName:n,popupWindowAttributes:i,popup:a}),this.eventHandler.emitEvent(Ct.POPUP_OPENED,et.Popup,{popupWindow:p},null),[4,this.waitForLogoutPopup(p)];case 4:return b.sent(),c?(v={apiId:$r.logoutPopup,timeout:this.config.system.redirectNavigationTimeout,noHistory:!1},g=Gt.getAbsoluteUrl(c,hn.getCurrentUri()),this.logger.verbose("Redirecting main window to url specified in the request"),this.logger.verbosePii("Redirecting main window to: "+g),this.navigationClient.navigateInternal(g,v)):this.logger.verbose("No main window navigation requested"),[3,6];case 5:throw _=b.sent(),a&&a.close(),_ instanceof it&&_.setCorrelationId(this.correlationId),this.browserStorage.setInteractionInProgress(!1),this.eventHandler.emitEvent(Ct.LOGOUT_FAILURE,et.Popup,null,_),this.eventHandler.emitEvent(Ct.LOGOUT_END,et.Popup),d.cacheFailedRequest(_),_;case 6:return this.eventHandler.emitEvent(Ct.LOGOUT_END,et.Popup),[2]}})})},e.prototype.initiateAuthRequest=function(t,n){if(Ne.isEmpty(t))throw this.logger.error("Navigate url is empty"),Me.createEmptyNavigationUriError();return this.logger.infoPii("Navigate to: "+t),this.openPopup(t,n)},e.prototype.monitorPopupForHash=function(t){var n=this;return new Promise(function(i,o){var a=n.config.system.windowHashTimeout/n.config.system.pollIntervalMilliseconds,c=0;n.logger.verbose("PopupHandler.monitorPopupForHash - polling started");var d=setInterval(function(){if(t.closed){n.logger.error("PopupHandler.monitorPopupForHash - window closed"),n.cleanPopup(),clearInterval(d),o(Me.createUserCancelledError());return}var h=G.EMPTY_STRING,u=G.EMPTY_STRING;try{h=t.location.href,u=t.location.hash}catch{}Ne.isEmpty(h)||h==="about:blank"||(n.logger.verbose("PopupHandler.monitorPopupForHash - popup window is on same origin as caller"),c++,u?(n.logger.verbose("PopupHandler.monitorPopupForHash - found hash in url"),clearInterval(d),n.cleanPopup(t),Gt.hashContainsKnownProperties(u)?(n.logger.verbose("PopupHandler.monitorPopupForHash - hash contains known properties, returning."),i(u)):(n.logger.error("PopupHandler.monitorPopupForHash - found hash in url but it does not contain known properties. Check that your router is not changing the hash prematurely."),n.logger.errorPii("PopupHandler.monitorPopupForHash - hash found: "+u),o(Me.createHashDoesNotContainKnownPropertiesError()))):c>a&&(n.logger.error("PopupHandler.monitorPopupForHash - unable to find hash in url, timing out"),clearInterval(d),o(Me.createMonitorPopupTimeoutError())))},n.config.system.pollIntervalMilliseconds)})},e.prototype.waitForLogoutPopup=function(t){var n=this;return new Promise(function(i){n.logger.verbose("PopupHandler.waitForLogoutPopup - polling started");var o=setInterval(function(){t.closed&&(n.logger.error("PopupHandler.waitForLogoutPopup - window closed"),n.cleanPopup(),clearInterval(o),i());var a=G.EMPTY_STRING;try{a=t.location.href}catch{}Ne.isEmpty(a)||a==="about:blank"||(n.logger.verbose("PopupHandler.waitForLogoutPopup - popup window is on same origin as caller, closing."),clearInterval(o),n.cleanPopup(t),i())},n.config.system.pollIntervalMilliseconds)})},e.prototype.openPopup=function(t,n){try{var i=void 0;if(n.popup?(i=n.popup,this.logger.verbosePii("Navigating popup window to: "+t),i.location.assign(t)):typeof n.popup>"u"&&(this.logger.verbosePii("Opening popup window to: "+t),i=this.openSizedPopup(t,n.popupName,n.popupWindowAttributes)),!i)throw Me.createEmptyWindowCreatedError();return i.focus&&i.focus(),this.currentWindow=i,window.addEventListener("beforeunload",this.unloadWindow),i}catch(o){throw this.logger.error("error opening popup "+o.message),this.browserStorage.setInteractionInProgress(!1),Me.createPopupWindowError(o.toString())}},e.prototype.openSizedPopup=function(t,n,i){var o,a,c,d,h=window.screenLeft?window.screenLeft:window.screenX,u=window.screenTop?window.screenTop:window.screenY,p=window.innerWidth||document.documentElement.clientWidth||document.body.clientWidth,v=window.innerHeight||document.documentElement.clientHeight||document.body.clientHeight,g=(o=i.popupSize)===null||o===void 0?void 0:o.width,_=(a=i.popupSize)===null||a===void 0?void 0:a.height,b=(c=i.popupPosition)===null||c===void 0?void 0:c.top,C=(d=i.popupPosition)===null||d===void 0?void 0:d.left;return(!g||g<0||g>p)&&(this.logger.verbose("Default popup window width used. Window width not configured or invalid."),g=Ra.POPUP_WIDTH),(!_||_<0||_>v)&&(this.logger.verbose("Default popup window height used. Window height not configured or invalid."),_=Ra.POPUP_HEIGHT),(!b||b<0||b>v)&&(this.logger.verbose("Default popup window top position used. Window top not configured or invalid."),b=Math.max(0,v/2-Ra.POPUP_HEIGHT/2+u)),(!C||C<0||C>p)&&(this.logger.verbose("Default popup window left position used. Window left not configured or invalid."),C=Math.max(0,p/2-Ra.POPUP_WIDTH/2+h)),window.open(t,n,"width="+g+", height="+_+", top="+b+", left="+C+", scrollbars=yes")},e.prototype.unloadWindow=function(t){this.browserStorage.cleanRequestByInteractionType(et.Popup),this.currentWindow&&this.currentWindow.close(),t.preventDefault()},e.prototype.cleanPopup=function(t){t&&t.close(),window.removeEventListener("beforeunload",this.unloadWindow),this.browserStorage.setInteractionInProgress(!1)},e.prototype.generatePopupName=function(t,n){return Ra.POPUP_NAME_PREFIX+"."+this.config.auth.clientId+"."+t.join("-")+"."+n+"."+this.correlationId},e.prototype.generateLogoutPopupName=function(t){var n=t.account&&t.account.homeAccountId;return Ra.POPUP_NAME_PREFIX+"."+this.config.auth.clientId+"."+n+"."+this.correlationId},e}(Ff);/*! @azure/msal-browser v2.39.0 2024-06-06 */var sF=function(){function r(){}return r.prototype.navigateInternal=function(e,t){return r.defaultNavigateWindow(e,t)},r.prototype.navigateExternal=function(e,t){return r.defaultNavigateWindow(e,t)},r.defaultNavigateWindow=function(e,t){return t.noHistory?window.location.replace(e):window.location.assign(e),new Promise(function(n){setTimeout(function(){n(!0)},t.timeout)})},r}();/*! @azure/msal-browser v2.39.0 2024-06-06 */var cF=6e4,Hb=6e3,lF=3e4,dF=2e3;function uF(r,e){var t=r.auth,n=r.cache,i=r.system,o=r.telemetry,a={clientId:G.EMPTY_STRING,authority:""+G.DEFAULT_AUTHORITY,knownAuthorities:[],cloudDiscoveryMetadata:G.EMPTY_STRING,authorityMetadata:G.EMPTY_STRING,redirectUri:G.EMPTY_STRING,postLogoutRedirectUri:G.EMPTY_STRING,navigateToLoginRequestUrl:!0,clientCapabilities:[],protocolMode:yf.AAD,azureCloudOptions:{azureCloudInstance:om.None,tenant:G.EMPTY_STRING},skipAuthorityMetadataCache:!1},c={cacheLocation:Cn.SessionStorage,temporaryCacheLocation:Cn.SessionStorage,storeAuthStateInCookie:!1,secureCookies:!1,cacheMigrationEnabled:!!(n&&n.cacheLocation===Cn.LocalStorage),claimsBasedCachingEnabled:!0},d={loggerCallback:function(){},logLevel:tn.Info,piiLoggingEnabled:!1},h=qe(qe({},XR),{loggerOptions:d,networkClient:e?hn.getBrowserNetworkClient():YV,navigationClient:new sF,loadFrameTimeout:0,windowHashTimeout:(i==null?void 0:i.loadFrameTimeout)||cF,iframeHashTimeout:(i==null?void 0:i.loadFrameTimeout)||Hb,navigateFrameWait:e&&hn.detectIEOrEdge()?500:0,redirectNavigationTimeout:lF,asyncPopups:!1,allowRedirectInIframe:!1,allowNativeBroker:!1,nativeBrokerHandshakeTimeout:(i==null?void 0:i.nativeBrokerHandshakeTimeout)||dF,pollIntervalMilliseconds:Ra.DEFAULT_POLL_INTERVAL_MS,cryptoOptions:{useMsrCrypto:!1,entropy:void 0}}),u=qe(qe({},i),{loggerOptions:(i==null?void 0:i.loggerOptions)||d}),p={application:{appName:G.EMPTY_STRING,appVersion:G.EMPTY_STRING}},v={auth:qe(qe({},a),t),cache:qe(qe({},c),n),system:qe(qe({},h),u),telemetry:qe(qe({},p),o)};return v}/*! @azure/msal-browser v2.39.0 2024-06-06 */var aP=function(r){ri(e,r);function e(t,n,i,o,a,c){var d=r.call(this,t,n,i,o,c)||this;return d.navigateFrameWait=a.navigateFrameWait,d.pollIntervalMilliseconds=a.pollIntervalMilliseconds,d}return e.prototype.initiateAuthRequest=function(t){return fe(this,void 0,void 0,function(){return pe(this,function(n){switch(n.label){case 0:if(this.performanceClient.addQueueMeasurement(ae.SilentHandlerInitiateAuthRequest,this.authCodeRequest.correlationId),Ne.isEmpty(t))throw this.logger.info("Navigate url is empty"),Me.createEmptyNavigationUriError();return this.navigateFrameWait?(this.performanceClient.setPreQueueTime(ae.SilentHandlerLoadFrame,this.authCodeRequest.correlationId),[4,this.loadFrame(t)]):[3,2];case 1:return[2,n.sent()];case 2:return[2,this.loadFrameSync(t)]}})})},e.prototype.monitorIframeForHash=function(t,n){var i=this;return this.performanceClient.addQueueMeasurement(ae.SilentHandlerMonitorIframeForHash,this.authCodeRequest.correlationId),new Promise(function(o,a){n<Hb&&i.logger.warning("system.loadFrameTimeout or system.iframeHashTimeout set to lower ("+n+"ms) than the default ("+Hb+"ms). This may result in timeouts.");var c=window.performance.now(),d=c+n,h=setInterval(function(){if(window.performance.now()>d){i.removeHiddenIframe(t),clearInterval(h),a(Me.createMonitorIframeTimeoutError());return}var u=G.EMPTY_STRING,p=t.contentWindow;try{u=p?p.location.href:G.EMPTY_STRING}catch{}if(!Ne.isEmpty(u)){var v=p?p.location.hash:G.EMPTY_STRING;if(Gt.hashContainsKnownProperties(v)){i.removeHiddenIframe(t),clearInterval(h),o(v);return}}},i.pollIntervalMilliseconds)})},e.prototype.loadFrame=function(t){var n=this;return this.performanceClient.addQueueMeasurement(ae.SilentHandlerLoadFrame,this.authCodeRequest.correlationId),new Promise(function(i,o){var a=n.createHiddenIframe();setTimeout(function(){if(!a){o("Unable to load iframe");return}a.src=t,i(a)},n.navigateFrameWait)})},e.prototype.loadFrameSync=function(t){var n=this.createHiddenIframe();return n.src=t,n},e.prototype.createHiddenIframe=function(){var t=document.createElement("iframe");return t.className="msalSilentIframe",t.style.visibility="hidden",t.style.position="absolute",t.style.width=t.style.height="0",t.style.border="0",t.setAttribute("sandbox","allow-scripts allow-same-origin allow-forms"),document.getElementsByTagName("body")[0].appendChild(t),t},e.prototype.removeHiddenIframe=function(t){document.body===t.parentNode&&document.body.removeChild(t)},e}($6);/*! @azure/msal-browser v2.39.0 2024-06-06 */var hF=function(r){ri(e,r);function e(t,n,i,o,a,c,d,h,u,p,v){var g=r.call(this,t,n,i,o,a,c,h,p,v)||this;return g.apiId=d,g.nativeStorage=u,g}return e.prototype.acquireToken=function(t){return fe(this,void 0,void 0,function(){var n,i,o,a,c;return pe(this,function(d){switch(d.label){case 0:if(this.performanceClient.addQueueMeasurement(ae.SilentIframeClientAcquireToken,t.correlationId),this.logger.verbose("acquireTokenByIframe called"),n=this.performanceClient.startMeasurement(ae.SilentIframeClientAcquireToken,t.correlationId),Ne.isEmpty(t.loginHint)&&Ne.isEmpty(t.sid)&&(!t.account||Ne.isEmpty(t.account.username))&&this.logger.warning("No user hint provided. The authorization server may need more information to complete this request."),t.prompt&&t.prompt!==wi.NONE&&t.prompt!==wi.NO_SESSION)throw n.endMeasurement({success:!1}),Me.createSilentPromptValueError(t.prompt);return this.performanceClient.setPreQueueTime(ae.StandardInteractionClientInitializeAuthorizationRequest,t.correlationId),[4,this.initializeAuthorizationRequest(qe(qe({},t),{prompt:t.prompt||wi.NONE}),et.Silent)];case 1:i=d.sent(),this.browserStorage.updateCacheEntries(i.state,i.nonce,i.authority,i.loginHint||G.EMPTY_STRING,i.account||null),o=this.initializeServerTelemetryManager(this.apiId),d.label=2;case 2:return d.trys.push([2,5,,6]),this.performanceClient.setPreQueueTime(ae.StandardInteractionClientCreateAuthCodeClient,t.correlationId),[4,this.createAuthCodeClient(o,i.authority,i.azureCloudOptions)];case 3:return a=d.sent(),this.logger.verbose("Auth code client created"),this.performanceClient.setPreQueueTime(ae.SilentIframeClientTokenHelper,t.correlationId),[4,this.silentTokenHelper(a,i).then(function(h){return n.endMeasurement({success:!0,fromCache:!1,requestId:h.requestId}),h})];case 4:return[2,d.sent()];case 5:throw c=d.sent(),c instanceof it&&c.setCorrelationId(this.correlationId),o.cacheFailedRequest(c),this.browserStorage.cleanRequestByState(i.state),n.endMeasurement({errorCode:c instanceof it&&c.errorCode||void 0,subErrorCode:c instanceof it&&c.subError||void 0,success:!1}),c;case 6:return[2]}})})},e.prototype.logout=function(){return Promise.reject(Me.createSilentLogoutUnsupportedError())},e.prototype.silentTokenHelper=function(t,n){return fe(this,void 0,void 0,function(){var i,o,a,c,d,h,u,p,v,g=this;return pe(this,function(_){switch(_.label){case 0:return this.performanceClient.addQueueMeasurement(ae.SilentIframeClientTokenHelper,n.correlationId),this.performanceClient.setPreQueueTime(ae.StandardInteractionClientInitializeAuthorizationCodeRequest,n.correlationId),[4,this.initializeAuthorizationCodeRequest(n)];case 1:return i=_.sent(),this.performanceClient.setPreQueueTime(ae.GetAuthCodeUrl,n.correlationId),[4,t.getAuthCodeUrl(qe(qe({},n),{nativeBroker:du.isNativeAvailable(this.config,this.logger,this.nativeMessageHandler,n.authenticationScheme)}))];case 2:return o=_.sent(),a=new aP(t,this.browserStorage,i,this.logger,this.config.system,this.performanceClient),this.performanceClient.setPreQueueTime(ae.SilentHandlerInitiateAuthRequest,n.correlationId),[4,a.initiateAuthRequest(o)];case 3:return c=_.sent(),this.performanceClient.setPreQueueTime(ae.SilentHandlerMonitorIframeForHash,n.correlationId),[4,a.monitorIframeForHash(c,this.config.system.iframeHashTimeout)];case 4:if(d=_.sent(),h=Gt.getDeserializedHash(d),u=this.validateAndExtractStateFromHash(h,et.Silent,i.correlationId),h.accountId){if(this.logger.verbose("Account id found in hash, calling WAM for token"),!this.nativeMessageHandler)throw Me.createNativeConnectionNotEstablishedError();return p=new cf(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,this.apiId,this.performanceClient,this.nativeMessageHandler,h.accountId,this.browserStorage,this.correlationId),v=fc.parseRequestState(this.browserCrypto,u).userRequestState,[2,p.acquireToken(qe(qe({},n),{state:v,prompt:n.prompt||wi.NONE})).finally(function(){g.browserStorage.cleanRequestByState(u)})]}return this.performanceClient.setPreQueueTime(ae.HandleCodeResponseFromHash,n.correlationId),[2,a.handleCodeResponseFromHash(d,u,t.authority,this.networkClient)]}})})},e}(Ff);/*! @azure/msal-browser v2.39.0 2024-06-06 */var fF=function(r){ri(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.acquireToken=function(t){return fe(this,void 0,void 0,function(){var n,i,o,a,c,d=this;return pe(this,function(h){switch(h.label){case 0:return this.performanceClient.addQueueMeasurement(ae.SilentRefreshClientAcquireToken,t.correlationId),this.performanceClient.setPreQueueTime(ae.InitializeBaseRequest,t.correlationId),i=[qe({},t)],[4,this.initializeBaseRequest(t,t.account)];case 1:return n=qe.apply(void 0,i.concat([h.sent()])),o=this.performanceClient.startMeasurement(ae.SilentRefreshClientAcquireToken,n.correlationId),a=this.initializeServerTelemetryManager($r.acquireTokenSilent_silentFlow),[4,this.createRefreshTokenClient(a,n.authority,n.azureCloudOptions)];case 2:return c=h.sent(),this.logger.verbose("Refresh token client created"),this.performanceClient.setPreQueueTime(ae.RefreshTokenClientAcquireTokenByRefreshToken,t.correlationId),[2,c.acquireTokenByRefreshToken(n).then(function(u){return o.endMeasurement({success:!0,fromCache:u.fromCache,requestId:u.requestId}),u}).catch(function(u){throw u instanceof it&&u.setCorrelationId(d.correlationId),a.cacheFailedRequest(u),o.endMeasurement({errorCode:u.errorCode,subErrorCode:u.subError,success:!1}),u})]}})})},e.prototype.logout=function(){return Promise.reject(Me.createSilentLogoutUnsupportedError())},e.prototype.createRefreshTokenClient=function(t,n,i){return fe(this,void 0,void 0,function(){var o;return pe(this,function(a){switch(a.label){case 0:return this.performanceClient.setPreQueueTime(ae.StandardInteractionClientGetClientConfiguration,this.correlationId),[4,this.getClientConfiguration(t,n,i)];case 1:return o=a.sent(),[2,new eP(o,this.performanceClient)]}})})},e}(Ff);/*! @azure/msal-browser v2.39.0 2024-06-06 */var pF=function(){function r(e,t){this.eventCallbacks=new Map,this.logger=e,this.browserCrypto=t,this.listeningToStorageEvents=!1,this.handleAccountCacheChange=this.handleAccountCacheChange.bind(this)}return r.prototype.addEventCallback=function(e){if(typeof window<"u"){var t=this.browserCrypto.createNewGuid();return this.eventCallbacks.set(t,e),this.logger.verbose("Event callback registered with id: "+t),t}return null},r.prototype.removeEventCallback=function(e){this.eventCallbacks.delete(e),this.logger.verbose("Event callback "+e+" removed.")},r.prototype.enableAccountStorageEvents=function(){typeof window>"u"||(this.listeningToStorageEvents?this.logger.verbose("Account storage listener already registered."):(this.logger.verbose("Adding account storage listener."),this.listeningToStorageEvents=!0,window.addEventListener("storage",this.handleAccountCacheChange)))},r.prototype.disableAccountStorageEvents=function(){typeof window>"u"||(this.listeningToStorageEvents?(this.logger.verbose("Removing account storage listener."),window.removeEventListener("storage",this.handleAccountCacheChange),this.listeningToStorageEvents=!1):this.logger.verbose("No account storage listener registered."))},r.prototype.emitEvent=function(e,t,n,i){var o=this;if(typeof window<"u"){var a={eventType:e,interactionType:t||null,payload:n||null,error:i||null,timestamp:Date.now()};this.logger.info("Emitting event: "+e),this.eventCallbacks.forEach(function(c,d){o.logger.verbose("Emitting event to callback "+d+": "+e),c.apply(null,[a])})}},r.prototype.handleAccountCacheChange=function(e){try{var t=e.newValue||e.oldValue;if(!t)return;var n=JSON.parse(t);if(typeof n!="object"||!Ci.isAccountEntity(n))return;var i=ro.toObject(new Ci,n),o=i.getAccountInfo();!e.oldValue&&e.newValue?(this.logger.info("Account was added to cache in a different window"),this.emitEvent(Ct.ACCOUNT_ADDED,void 0,o)):!e.newValue&&e.oldValue&&(this.logger.info("Account was removed from cache in a different window"),this.emitEvent(Ct.ACCOUNT_REMOVED,void 0,o))}catch{return}},r}();/*! @azure/msal-browser v2.39.0 2024-06-06 */var pi=function(){function r(){}return r.decimalToHex=function(e){for(var t=e.toString(16);t.length<2;)t="0"+t;return t},r}();/*! @azure/msal-browser v2.39.0 2024-06-06 */var sP=function(){function r(e){this.cryptoObj=e}return r.prototype.generateGuid=function(){try{var e=new Uint8Array(16);return this.cryptoObj.getRandomValues(e),e[6]|=64,e[6]&=79,e[8]|=128,e[8]&=191,pi.decimalToHex(e[0])+pi.decimalToHex(e[1])+pi.decimalToHex(e[2])+pi.decimalToHex(e[3])+"-"+pi.decimalToHex(e[4])+pi.decimalToHex(e[5])+"-"+pi.decimalToHex(e[6])+pi.decimalToHex(e[7])+"-"+pi.decimalToHex(e[8])+pi.decimalToHex(e[9])+"-"+pi.decimalToHex(e[10])+pi.decimalToHex(e[11])+pi.decimalToHex(e[12])+pi.decimalToHex(e[13])+pi.decimalToHex(e[14])+pi.decimalToHex(e[15])}catch{for(var t="xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx",n="0123456789abcdef",i=0,o=G.EMPTY_STRING,a=0;a<36;a++)t[a]!=="-"&&t[a]!=="4"&&(i=Math.random()*16|0),t[a]==="x"?o+=n[i]:t[a]==="y"?(i&=3,i|=8,o+=n[i]):o+=t[a];return o}},r.prototype.isGuid=function(e){var t=/^[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$/i;return t.test(e)},r}();/*! @azure/msal-browser v2.39.0 2024-06-06 */var pc=function(){function r(){}return r.stringToUtf8Arr=function(e){for(var t,n=0,i=e.length,o=0;o<i;o++)t=e.charCodeAt(o),n+=t<128?1:t<2048?2:t<65536?3:t<2097152?4:t<67108864?5:6;for(var a=new Uint8Array(n),c=0,d=0;c<n;d++)t=e.charCodeAt(d),t<128?a[c++]=t:t<2048?(a[c++]=192+(t>>>6),a[c++]=128+(t&63)):t<65536?(a[c++]=224+(t>>>12),a[c++]=128+(t>>>6&63),a[c++]=128+(t&63)):t<2097152?(a[c++]=240+(t>>>18),a[c++]=128+(t>>>12&63),a[c++]=128+(t>>>6&63),a[c++]=128+(t&63)):t<67108864?(a[c++]=248+(t>>>24),a[c++]=128+(t>>>18&63),a[c++]=128+(t>>>12&63),a[c++]=128+(t>>>6&63),a[c++]=128+(t&63)):(a[c++]=252+(t>>>30),a[c++]=128+(t>>>24&63),a[c++]=128+(t>>>18&63),a[c++]=128+(t>>>12&63),a[c++]=128+(t>>>6&63),a[c++]=128+(t&63));return a},r.stringToArrayBuffer=function(e){for(var t=new ArrayBuffer(e.length),n=new Uint8Array(t),i=0;i<e.length;i++)n[i]=e.charCodeAt(i);return t},r.utf8ArrToString=function(e){for(var t=G.EMPTY_STRING,n=void 0,i=e.length,o=0;o<i;o++)n=e[o],t+=String.fromCharCode(n>251&&n<254&&o+5<i?(n-252)*1073741824+(e[++o]-128<<24)+(e[++o]-128<<18)+(e[++o]-128<<12)+(e[++o]-128<<6)+e[++o]-128:n>247&&n<252&&o+4<i?(n-248<<24)+(e[++o]-128<<18)+(e[++o]-128<<12)+(e[++o]-128<<6)+e[++o]-128:n>239&&n<248&&o+3<i?(n-240<<18)+(e[++o]-128<<12)+(e[++o]-128<<6)+e[++o]-128:n>223&&n<240&&o+2<i?(n-224<<12)+(e[++o]-128<<6)+e[++o]-128:n>191&&n<224&&o+1<i?(n-192<<6)+e[++o]-128:n);return t},r.getSortedObjectString=function(e){return JSON.stringify(e,Object.keys(e).sort())},r}();/*! @azure/msal-browser v2.39.0 2024-06-06 */var cP=function(){function r(){}return r.prototype.urlEncode=function(e){return encodeURIComponent(this.encode(e).replace(/=/g,G.EMPTY_STRING).replace(/\+/g,"-").replace(/\//g,"_"))},r.prototype.urlEncodeArr=function(e){return this.base64EncArr(e).replace(/=/g,G.EMPTY_STRING).replace(/\+/g,"-").replace(/\//g,"_")},r.prototype.encode=function(e){var t=pc.stringToUtf8Arr(e);return this.base64EncArr(t)},r.prototype.base64EncArr=function(e){for(var t=(3-e.length%3)%3,n=G.EMPTY_STRING,i=void 0,o=e.length,a=0,c=0;c<o;c++)i=c%3,a|=e[c]<<(16>>>i&24),(i===2||e.length-c===1)&&(n+=String.fromCharCode(this.uint6ToB64(a>>>18&63),this.uint6ToB64(a>>>12&63),this.uint6ToB64(a>>>6&63),this.uint6ToB64(a&63)),a=0);return t===0?n:n.substring(0,n.length-t)+(t===1?"=":"==")},r.prototype.uint6ToB64=function(e){return e<26?e+65:e<52?e+71:e<62?e-4:e===62?43:e===63?47:65},r}();/*! @azure/msal-browser v2.39.0 2024-06-06 */var mF=function(){function r(){}return r.prototype.decode=function(e){var t=e.replace(/-/g,"+").replace(/_/g,"/");switch(t.length%4){case 0:break;case 2:t+="==";break;case 3:t+="=";break;default:throw new Error("Invalid base64 string")}var n=this.base64DecToArr(t);return pc.utf8ArrToString(n)},r.prototype.base64DecToArr=function(e,t){for(var n=e.replace(/[^A-Za-z0-9\+\/]/g,G.EMPTY_STRING),i=n.length,o=t?Math.ceil((i*3+1>>>2)/t)*t:i*3+1>>>2,a=new Uint8Array(o),c=void 0,d=void 0,h=0,u=0,p=0;p<i;p++)if(d=p&3,h|=this.b64ToUint6(n.charCodeAt(p))<<18-6*d,d===3||i-p===1){for(c=0;c<3&&u<o;c++,u++)a[u]=h>>>(16>>>c&24)&255;h=0}return a},r.prototype.b64ToUint6=function(e){return e>64&&e<91?e-65:e>96&&e<123?e-71:e>47&&e<58?e+4:e===43?62:e===47?63:0},r}();/*! @azure/msal-browser v2.39.0 2024-06-06 */var vF=32,gF=function(){function r(e){this.base64Encode=new cP,this.cryptoObj=e}return r.prototype.generateCodes=function(){return fe(this,void 0,void 0,function(){var e,t;return pe(this,function(n){switch(n.label){case 0:return e=this.generateCodeVerifier(),[4,this.generateCodeChallengeFromVerifier(e)];case 1:return t=n.sent(),[2,{verifier:e,challenge:t}]}})})},r.prototype.generateCodeVerifier=function(){try{var e=new Uint8Array(vF);this.cryptoObj.getRandomValues(e);var t=this.base64Encode.urlEncodeArr(e);return t}catch(n){throw Me.createPkceNotGeneratedError(n)}},r.prototype.generateCodeChallengeFromVerifier=function(e){return fe(this,void 0,void 0,function(){var t,n;return pe(this,function(i){switch(i.label){case 0:return i.trys.push([0,2,,3]),[4,this.cryptoObj.sha256Digest(e)];case 1:return t=i.sent(),[2,this.base64Encode.urlEncodeArr(new Uint8Array(t))];case 2:throw n=i.sent(),Me.createPkceNotGeneratedError(n);case 3:return[2]}})})},r}();/*! @azure/msal-browser v2.39.0 2024-06-06 */var yF=function(){function r(){}return r.prototype.getRandomValues=function(e){return window.crypto.getRandomValues(e)},r.prototype.generateKey=function(e,t,n){return fe(this,void 0,void 0,function(){return pe(this,function(i){return[2,window.crypto.subtle.generateKey(e,t,n)]})})},r.prototype.exportKey=function(e){return fe(this,void 0,void 0,function(){return pe(this,function(t){return[2,window.crypto.subtle.exportKey(bf,e)]})})},r.prototype.importKey=function(e,t,n,i){return fe(this,void 0,void 0,function(){return pe(this,function(o){return[2,window.crypto.subtle.importKey(bf,e,t,n,i)]})})},r.prototype.sign=function(e,t,n){return fe(this,void 0,void 0,function(){return pe(this,function(i){return[2,window.crypto.subtle.sign(e,t,n)]})})},r.prototype.digest=function(e,t){return fe(this,void 0,void 0,function(){return pe(this,function(n){return[2,window.crypto.subtle.digest(e,t)]})})},r}();/*! @azure/msal-browser v2.39.0 2024-06-06 */var _F=function(){function r(){}return r.prototype.initPrng=function(e){return window.msrCrypto.initPrng(I6(e))},r.prototype.getRandomValues=function(e){return window.msrCrypto.getRandomValues(e)},r.prototype.generateKey=function(e,t,n){return fe(this,void 0,void 0,function(){return pe(this,function(i){return[2,window.msrCrypto.subtle.generateKey(e,t,n)]})})},r.prototype.exportKey=function(e){return fe(this,void 0,void 0,function(){return pe(this,function(t){return[2,window.msrCrypto.subtle.exportKey(bf,e)]})})},r.prototype.importKey=function(e,t,n,i){return fe(this,void 0,void 0,function(){return pe(this,function(o){return[2,window.msrCrypto.subtle.importKey(bf,e,t,n,i)]})})},r.prototype.sign=function(e,t,n){return fe(this,void 0,void 0,function(){return pe(this,function(i){return[2,window.msrCrypto.subtle.sign(e,t,n)]})})},r.prototype.digest=function(e,t){return fe(this,void 0,void 0,function(){return pe(this,function(n){return[2,window.msrCrypto.subtle.digest(e,t)]})})},r}();/*! @azure/msal-browser v2.39.0 2024-06-06 */var bF=function(){function r(){}return r.prototype.getRandomValues=function(e){return window.msCrypto.getRandomValues(e)},r.prototype.generateKey=function(e,t,n){return fe(this,void 0,void 0,function(){return pe(this,function(i){return[2,new Promise(function(o,a){var c=window.msCrypto.subtle.generateKey(e,t,n);c.addEventListener("complete",function(d){o(d.target.result)}),c.addEventListener("error",function(d){a(d)})})]})})},r.prototype.exportKey=function(e){return fe(this,void 0,void 0,function(){return pe(this,function(t){return[2,new Promise(function(n,i){var o=window.msCrypto.subtle.exportKey(bf,e);o.addEventListener("complete",function(a){var c=a.target.result,d=pc.utf8ArrToString(new Uint8Array(c)).replace(/\r/g,G.EMPTY_STRING).replace(/\n/g,G.EMPTY_STRING).replace(/\t/g,G.EMPTY_STRING).split(" ").join(G.EMPTY_STRING).replace("\0",G.EMPTY_STRING);try{n(JSON.parse(d))}catch(h){i(h)}}),o.addEventListener("error",function(a){i(a)})})]})})},r.prototype.importKey=function(e,t,n,i){return fe(this,void 0,void 0,function(){var o,a;return pe(this,function(c){return o=pc.getSortedObjectString(e),a=pc.stringToArrayBuffer(o),[2,new Promise(function(d,h){var u=window.msCrypto.subtle.importKey(bf,a,t,n,i);u.addEventListener("complete",function(p){d(p.target.result)}),u.addEventListener("error",function(p){h(p)})})]})})},r.prototype.sign=function(e,t,n){return fe(this,void 0,void 0,function(){return pe(this,function(i){return[2,new Promise(function(o,a){var c=window.msCrypto.subtle.sign(e,t,n);c.addEventListener("complete",function(d){o(d.target.result)}),c.addEventListener("error",function(d){a(d)})})]})})},r.prototype.digest=function(e,t){return fe(this,void 0,void 0,function(){return pe(this,function(n){return[2,new Promise(function(i,o){var a=window.msCrypto.subtle.digest(e,t.buffer);a.addEventListener("complete",function(c){i(c.target.result)}),a.addEventListener("error",function(c){o(c)})})]})})},r}();/*! @azure/msal-browser v2.39.0 2024-06-06 */var wF="RSASSA-PKCS1-v1_5",YC="SHA-256",xF=2048,CF=new Uint8Array([1,0,1]),lP=function(){function r(e,t){var n,i;if(this.logger=e,this.cryptoOptions=t,this.hasBrowserCrypto())this.logger.verbose("BrowserCrypto: modern crypto interface available"),this.subtleCrypto=new yF;else if(this.hasIECrypto())this.logger.verbose("BrowserCrypto: MS crypto interface available"),this.subtleCrypto=new bF;else if(this.hasMsrCrypto()&&(!((n=this.cryptoOptions)===null||n===void 0)&&n.useMsrCrypto))this.logger.verbose("BrowserCrypto: MSR crypto interface available"),this.subtleCrypto=new _F;else throw this.hasMsrCrypto()&&this.logger.info("BrowserCrypto: MSR Crypto interface available but system.cryptoOptions.useMsrCrypto not enabled"),this.logger.error("BrowserCrypto: No crypto interfaces available."),Me.createCryptoNotAvailableError("Browser crypto, msCrypto, or msrCrypto interfaces not available.");if(this.subtleCrypto.initPrng){if(this.logger.verbose("BrowserCrypto: Interface requires entropy"),!(!((i=this.cryptoOptions)===null||i===void 0)&&i.entropy))throw this.logger.error("BrowserCrypto: Interface requires entropy but none provided."),xg.createEntropyNotProvided();this.logger.verbose("BrowserCrypto: Entropy provided"),this.subtleCrypto.initPrng(this.cryptoOptions.entropy)}this.keygenAlgorithmOptions={name:wF,hash:YC,modulusLength:xF,publicExponent:CF}}return r.prototype.hasIECrypto=function(){return"msCrypto"in window},r.prototype.hasBrowserCrypto=function(){return"crypto"in window},r.prototype.hasMsrCrypto=function(){return"msrCrypto"in window},r.prototype.sha256Digest=function(e){return fe(this,void 0,void 0,function(){var t;return pe(this,function(n){return t=pc.stringToUtf8Arr(e),[2,this.subtleCrypto.digest({name:YC},t)]})})},r.prototype.getRandomValues=function(e){return this.subtleCrypto.getRandomValues(e)},r.prototype.generateKeyPair=function(e,t){return fe(this,void 0,void 0,function(){return pe(this,function(n){return[2,this.subtleCrypto.generateKey(this.keygenAlgorithmOptions,e,t)]})})},r.prototype.exportJwk=function(e){return fe(this,void 0,void 0,function(){return pe(this,function(t){return[2,this.subtleCrypto.exportKey(e)]})})},r.prototype.importJwk=function(e,t,n){return fe(this,void 0,void 0,function(){return pe(this,function(i){return[2,this.subtleCrypto.importKey(e,this.keygenAlgorithmOptions,t,n)]})})},r.prototype.sign=function(e,t){return fe(this,void 0,void 0,function(){return pe(this,function(n){return[2,this.subtleCrypto.sign(this.keygenAlgorithmOptions,e,t)]})})},r}();/*! @azure/msal-browser v2.39.0 2024-06-06 */var kF=function(){function r(){this.dbName=Ob,this.version=eF,this.tableName=tF,this.dbOpen=!1}return r.prototype.open=function(){return fe(this,void 0,void 0,function(){var e=this;return pe(this,function(t){return[2,new Promise(function(n,i){var o=window.indexedDB.open(e.dbName,e.version);o.addEventListener("upgradeneeded",function(a){var c=a;c.target.result.createObjectStore(e.tableName)}),o.addEventListener("success",function(a){var c=a;e.db=c.target.result,e.dbOpen=!0,n()}),o.addEventListener("error",function(){return i(Me.createDatabaseUnavailableError())})})]})})},r.prototype.closeConnection=function(){var e=this.db;e&&this.dbOpen&&(e.close(),this.dbOpen=!1)},r.prototype.validateDbIsOpen=function(){return fe(this,void 0,void 0,function(){return pe(this,function(e){switch(e.label){case 0:return this.dbOpen?[3,2]:[4,this.open()];case 1:return[2,e.sent()];case 2:return[2]}})})},r.prototype.getItem=function(e){return fe(this,void 0,void 0,function(){var t=this;return pe(this,function(n){switch(n.label){case 0:return[4,this.validateDbIsOpen()];case 1:return n.sent(),[2,new Promise(function(i,o){if(!t.db)return o(Me.createDatabaseNotOpenError());var a=t.db.transaction([t.tableName],"readonly"),c=a.objectStore(t.tableName),d=c.get(e);d.addEventListener("success",function(h){var u=h;t.closeConnection(),i(u.target.result)}),d.addEventListener("error",function(h){t.closeConnection(),o(h)})})]}})})},r.prototype.setItem=function(e,t){return fe(this,void 0,void 0,function(){var n=this;return pe(this,function(i){switch(i.label){case 0:return[4,this.validateDbIsOpen()];case 1:return i.sent(),[2,new Promise(function(o,a){if(!n.db)return a(Me.createDatabaseNotOpenError());var c=n.db.transaction([n.tableName],"readwrite"),d=c.objectStore(n.tableName),h=d.put(t,e);h.addEventListener("success",function(){n.closeConnection(),o()}),h.addEventListener("error",function(u){n.closeConnection(),a(u)})})]}})})},r.prototype.removeItem=function(e){return fe(this,void 0,void 0,function(){var t=this;return pe(this,function(n){switch(n.label){case 0:return[4,this.validateDbIsOpen()];case 1:return n.sent(),[2,new Promise(function(i,o){if(!t.db)return o(Me.createDatabaseNotOpenError());var a=t.db.transaction([t.tableName],"readwrite"),c=a.objectStore(t.tableName),d=c.delete(e);d.addEventListener("success",function(){t.closeConnection(),i()}),d.addEventListener("error",function(h){t.closeConnection(),o(h)})})]}})})},r.prototype.getKeys=function(){return fe(this,void 0,void 0,function(){var e=this;return pe(this,function(t){switch(t.label){case 0:return[4,this.validateDbIsOpen()];case 1:return t.sent(),[2,new Promise(function(n,i){if(!e.db)return i(Me.createDatabaseNotOpenError());var o=e.db.transaction([e.tableName],"readonly"),a=o.objectStore(e.tableName),c=a.getAllKeys();c.addEventListener("success",function(d){var h=d;e.closeConnection(),n(h.target.result)}),c.addEventListener("error",function(d){e.closeConnection(),i(d)})})]}})})},r.prototype.containsKey=function(e){return fe(this,void 0,void 0,function(){var t=this;return pe(this,function(n){switch(n.label){case 0:return[4,this.validateDbIsOpen()];case 1:return n.sent(),[2,new Promise(function(i,o){if(!t.db)return o(Me.createDatabaseNotOpenError());var a=t.db.transaction([t.tableName],"readonly"),c=a.objectStore(t.tableName),d=c.count(e);d.addEventListener("success",function(h){var u=h;t.closeConnection(),i(u.target.result===1)}),d.addEventListener("error",function(h){t.closeConnection(),o(h)})})]}})})},r.prototype.deleteDatabase=function(){return fe(this,void 0,void 0,function(){return pe(this,function(e){return this.db&&this.dbOpen&&this.closeConnection(),[2,new Promise(function(t,n){var i=window.indexedDB.deleteDatabase(Ob);i.addEventListener("success",function(){return t(!0)}),i.addEventListener("blocked",function(){return t(!0)}),i.addEventListener("error",function(){return n(!1)})})]})})},r}();/*! @azure/msal-browser v2.39.0 2024-06-06 */var QC=function(){function r(e,t){this.inMemoryCache=new Zb,this.indexedDBCache=new kF,this.logger=e,this.storeName=t}return r.prototype.handleDatabaseAccessError=function(e){if(e instanceof Me&&e.errorCode===xe.databaseUnavailable.code)this.logger.error("Could not access persistent storage. This may be caused by browser privacy features which block persistent storage in third-party contexts.");else throw e},r.prototype.getItem=function(e){return fe(this,void 0,void 0,function(){var t,n;return pe(this,function(i){switch(i.label){case 0:if(t=this.inMemoryCache.getItem(e),t)return[3,4];i.label=1;case 1:return i.trys.push([1,3,,4]),this.logger.verbose("Queried item not found in in-memory cache, now querying persistent storage."),[4,this.indexedDBCache.getItem(e)];case 2:return[2,i.sent()];case 3:return n=i.sent(),this.handleDatabaseAccessError(n),[3,4];case 4:return[2,t]}})})},r.prototype.setItem=function(e,t){return fe(this,void 0,void 0,function(){var n;return pe(this,function(i){switch(i.label){case 0:this.inMemoryCache.setItem(e,t),i.label=1;case 1:return i.trys.push([1,3,,4]),[4,this.indexedDBCache.setItem(e,t)];case 2:return i.sent(),[3,4];case 3:return n=i.sent(),this.handleDatabaseAccessError(n),[3,4];case 4:return[2]}})})},r.prototype.removeItem=function(e){return fe(this,void 0,void 0,function(){var t;return pe(this,function(n){switch(n.label){case 0:this.inMemoryCache.removeItem(e),n.label=1;case 1:return n.trys.push([1,3,,4]),[4,this.indexedDBCache.removeItem(e)];case 2:return n.sent(),[3,4];case 3:return t=n.sent(),this.handleDatabaseAccessError(t),[3,4];case 4:return[2]}})})},r.prototype.getKeys=function(){return fe(this,void 0,void 0,function(){var e,t;return pe(this,function(n){switch(n.label){case 0:if(e=this.inMemoryCache.getKeys(),e.length!==0)return[3,4];n.label=1;case 1:return n.trys.push([1,3,,4]),this.logger.verbose("In-memory cache is empty, now querying persistent storage."),[4,this.indexedDBCache.getKeys()];case 2:return[2,n.sent()];case 3:return t=n.sent(),this.handleDatabaseAccessError(t),[3,4];case 4:return[2,e]}})})},r.prototype.containsKey=function(e){return fe(this,void 0,void 0,function(){var t,n;return pe(this,function(i){switch(i.label){case 0:if(t=this.inMemoryCache.containsKey(e),t)return[3,4];i.label=1;case 1:return i.trys.push([1,3,,4]),this.logger.verbose("Key not found in in-memory cache, now querying persistent storage."),[4,this.indexedDBCache.containsKey(e)];case 2:return[2,i.sent()];case 3:return n=i.sent(),this.handleDatabaseAccessError(n),[3,4];case 4:return[2,t]}})})},r.prototype.clearInMemory=function(){this.logger.verbose("Deleting in-memory keystore "+this.storeName),this.inMemoryCache.clear(),this.logger.verbose("In-memory keystore "+this.storeName+" deleted")},r.prototype.clearPersistent=function(){return fe(this,void 0,void 0,function(){var e,t;return pe(this,function(n){switch(n.label){case 0:return n.trys.push([0,2,,3]),this.logger.verbose("Deleting persistent keystore"),[4,this.indexedDBCache.deleteDatabase()];case 1:return e=n.sent(),e&&this.logger.verbose("Persistent keystore deleted"),[2,e];case 2:return t=n.sent(),this.handleDatabaseAccessError(t),[2,!1];case 3:return[2]}})})},r}();/*! @azure/msal-browser v2.39.0 2024-06-06 */var Cg;(function(r){r.asymmetricKeys="asymmetricKeys",r.symmetricKeys="symmetricKeys"})(Cg||(Cg={}));var EF=function(){function r(e){this.logger=e,this.asymmetricKeys=new QC(this.logger,Cg.asymmetricKeys),this.symmetricKeys=new QC(this.logger,Cg.symmetricKeys)}return r.prototype.clear=function(){return fe(this,void 0,void 0,function(){var e;return pe(this,function(t){switch(t.label){case 0:this.asymmetricKeys.clearInMemory(),this.symmetricKeys.clearInMemory(),t.label=1;case 1:return t.trys.push([1,3,,4]),[4,this.asymmetricKeys.clearPersistent()];case 2:return t.sent(),[2,!0];case 3:return e=t.sent(),e instanceof Error?this.logger.error("Clearing keystore failed with error: "+e.message):this.logger.error("Clearing keystore failed with unknown error"),[2,!1];case 4:return[2]}})})},r}();/*! @azure/msal-browser v2.39.0 2024-06-06 */var SF=function(){function r(e,t,n){this.logger=e,this.browserCrypto=new lP(this.logger,n),this.b64Encode=new cP,this.b64Decode=new mF,this.guidGenerator=new sP(this.browserCrypto),this.pkceGenerator=new gF(this.browserCrypto),this.cache=new EF(this.logger),this.performanceClient=t}return r.prototype.createNewGuid=function(){return this.guidGenerator.generateGuid()},r.prototype.base64Encode=function(e){return this.b64Encode.encode(e)},r.prototype.base64Decode=function(e){return this.b64Decode.decode(e)},r.prototype.generatePkceCodes=function(){return fe(this,void 0,void 0,function(){return pe(this,function(e){return[2,this.pkceGenerator.generateCodes()]})})},r.prototype.getPublicKeyThumbprint=function(e){var t;return fe(this,void 0,void 0,function(){var n,i,o,a,c,d,h,u;return pe(this,function(p){switch(p.label){case 0:return n=(t=this.performanceClient)===null||t===void 0?void 0:t.startMeasurement(ae.CryptoOptsGetPublicKeyThumbprint,e.correlationId),[4,this.browserCrypto.generateKeyPair(r.EXTRACTABLE,r.POP_KEY_USAGES)];case 1:return i=p.sent(),[4,this.browserCrypto.exportJwk(i.publicKey)];case 2:return o=p.sent(),a={e:o.e,kty:o.kty,n:o.n},c=pc.getSortedObjectString(a),[4,this.hashString(c)];case 3:return d=p.sent(),[4,this.browserCrypto.exportJwk(i.privateKey)];case 4:return h=p.sent(),[4,this.browserCrypto.importJwk(h,!1,["sign"])];case 5:return u=p.sent(),[4,this.cache.asymmetricKeys.setItem(d,{privateKey:u,publicKey:i.publicKey,requestMethod:e.resourceRequestMethod,requestUri:e.resourceRequestUri})];case 6:return p.sent(),n&&n.endMeasurement({success:!0}),[2,d]}})})},r.prototype.removeTokenBindingKey=function(e){return fe(this,void 0,void 0,function(){var t;return pe(this,function(n){switch(n.label){case 0:return[4,this.cache.asymmetricKeys.removeItem(e)];case 1:return n.sent(),[4,this.cache.asymmetricKeys.containsKey(e)];case 2:return t=n.sent(),[2,!t]}})})},r.prototype.clearKeystore=function(){return fe(this,void 0,void 0,function(){return pe(this,function(e){switch(e.label){case 0:return[4,this.cache.clear()];case 1:return[2,e.sent()]}})})},r.prototype.signJwt=function(e,t,n){var i;return fe(this,void 0,void 0,function(){var o,a,c,d,h,u,p,v,g,_,b,C,T;return pe(this,function(S){switch(S.label){case 0:return o=(i=this.performanceClient)===null||i===void 0?void 0:i.startMeasurement(ae.CryptoOptsSignJwt,n),[4,this.cache.asymmetricKeys.getItem(t)];case 1:if(a=S.sent(),!a)throw Me.createSigningKeyNotFoundInStorageError(t);return[4,this.browserCrypto.exportJwk(a.publicKey)];case 2:return c=S.sent(),d=pc.getSortedObjectString(c),h=this.b64Encode.urlEncode(JSON.stringify({kid:t})),u=QV.getShrHeaderString({kid:h,alg:c.alg}),p=this.b64Encode.urlEncode(u),e.cnf={jwk:JSON.parse(d)},v=this.b64Encode.urlEncode(JSON.stringify(e)),g=p+"."+v,_=pc.stringToArrayBuffer(g),[4,this.browserCrypto.sign(a.privateKey,_)];case 3:return b=S.sent(),C=this.b64Encode.urlEncodeArr(new Uint8Array(b)),T=g+"."+C,o&&o.endMeasurement({success:!0}),[2,T]}})})},r.prototype.hashString=function(e){return fe(this,void 0,void 0,function(){var t,n;return pe(this,function(i){switch(i.label){case 0:return[4,this.browserCrypto.sha256Digest(e)];case 1:return t=i.sent(),n=new Uint8Array(t),[2,this.b64Encode.urlEncodeArr(n)]}})})},r.POP_KEY_USAGES=["sign","verify"],r.EXTRACTABLE=!0,r}();/*! @azure/msal-browser v2.39.0 2024-06-06 */var XC=function(){function r(e,t){this.correlationId=t,this.measureName=r.makeMeasureName(e,t),this.startMark=r.makeStartMark(e,t),this.endMark=r.makeEndMark(e,t)}return r.makeMeasureName=function(e,t){return"msal.measure."+e+"."+t},r.makeStartMark=function(e,t){return"msal.start."+e+"."+t},r.makeEndMark=function(e,t){return"msal.end."+e+"."+t},r.supportsBrowserPerformance=function(){return typeof window<"u"&&typeof window.performance<"u"&&typeof window.performance.mark=="function"&&typeof window.performance.measure=="function"&&typeof window.performance.clearMarks=="function"&&typeof window.performance.clearMeasures=="function"&&typeof window.performance.getEntriesByName=="function"},r.flushMeasurements=function(e,t){if(r.supportsBrowserPerformance())try{t.forEach(function(n){var i=r.makeMeasureName(n.name,e),o=window.performance.getEntriesByName(i,"measure");o.length>0&&(window.performance.clearMeasures(i),window.performance.clearMarks(r.makeStartMark(i,e)),window.performance.clearMarks(r.makeEndMark(i,e)))})}catch{}},r.prototype.startMeasurement=function(){if(r.supportsBrowserPerformance())try{window.performance.mark(this.startMark)}catch{}},r.prototype.endMeasurement=function(){if(r.supportsBrowserPerformance())try{window.performance.mark(this.endMark),window.performance.measure(this.measureName,this.startMark,this.endMark)}catch{}},r.prototype.flushMeasurement=function(){if(r.supportsBrowserPerformance())try{var e=window.performance.getEntriesByName(this.measureName,"measure");if(e.length>0){var t=e[0].duration;return window.performance.clearMeasures(this.measureName),window.performance.clearMarks(this.startMark),window.performance.clearMarks(this.endMark),t}}catch{}return null},r}();/*! @azure/msal-browser v2.39.0 2024-06-06 */var TF=function(r){ri(e,r);function e(t,n,i,o,a,c,d){var h=r.call(this,t,n,i,o,a,c)||this;return h.browserCrypto=new lP(h.logger,d),h.guidGenerator=new sP(h.browserCrypto),h}return e.prototype.startPerformanceMeasuremeant=function(t,n){return new XC(t,n)},e.prototype.generateId=function(){return this.guidGenerator.generateGuid()},e.prototype.getPageVisibility=function(){var t;return((t=document.visibilityState)===null||t===void 0?void 0:t.toString())||null},e.prototype.deleteIncompleteSubMeasurements=function(t){var n=this.eventsByCorrelationId.get(t.event.correlationId),i=n&&n.eventId===t.event.eventId,o=[];i&&(n!=null&&n.incompleteSubMeasurements)&&n.incompleteSubMeasurements.forEach(function(a){o.push(qe({},a))}),o.length>0&&XC.flushMeasurements(t.event.correlationId,o)},e.prototype.supportsBrowserPerformanceNow=function(){return typeof window<"u"&&typeof window.performance<"u"&&typeof window.performance.now=="function"},e.prototype.startMeasurement=function(t,n){var i=this,o=this.getPageVisibility(),a=r.prototype.startMeasurement.call(this,t,n);return qe(qe({},a),{endMeasurement:function(c){var d=a.endMeasurement(qe({startPageVisibility:o,endPageVisibility:i.getPageVisibility()},c));return i.deleteIncompleteSubMeasurements(a),d},discardMeasurement:function(){a.discardMeasurement(),i.deleteIncompleteSubMeasurements(a),a.measurement.flushMeasurement()}})},e.prototype.setPreQueueTime=function(t,n){if(!this.supportsBrowserPerformanceNow()){this.logger.trace("BrowserPerformanceClient: window performance API not available, unable to set telemetry queue time for "+t);return}if(!n){this.logger.trace("BrowserPerformanceClient: correlationId for "+t+" not provided, unable to set telemetry queue time");return}var i=this.preQueueTimeByCorrelationId.get(n);i&&(this.logger.trace("BrowserPerformanceClient: Incomplete pre-queue "+i.name+" found",n),this.addQueueMeasurement(i.name,n,void 0,!0)),this.preQueueTimeByCorrelationId.set(n,{name:t,time:window.performance.now()})},e.prototype.addQueueMeasurement=function(t,n,i,o){if(!this.supportsBrowserPerformanceNow()){this.logger.trace("BrowserPerformanceClient: window performance API not available, unable to add queue measurement for "+t);return}if(!n){this.logger.trace("BrowserPerformanceClient: correlationId for "+t+" not provided, unable to add queue measurement");return}var a=r.prototype.getPreQueueTime.call(this,t,n);if(a){var c=window.performance.now(),d=i||r.prototype.calculateQueuedTime.call(this,a,c);return r.prototype.addQueueMeasurement.call(this,t,n,d,o)}},e}(rP);/*! @azure/msal-browser v2.39.0 2024-06-06 */var AF=function(){function r(e,t,n,i){this.isBrowserEnvironment=typeof window<"u",this.config=e,this.storage=t,this.logger=n,this.cryptoObj=i}return r.prototype.loadExternalTokens=function(e,t,n){if(this.logger.info("TokenCache - loadExternalTokens called"),!t.id_token)throw Me.createUnableToLoadTokenError("Please ensure server response includes id token.");var i=new xs(t.id_token,this.cryptoObj),o,a,c;if(e.account)c=Ci.createFromAccountInfo(e.account),o=new sf(c,this.loadIdToken(i,c.homeAccountId,e.account.environment,e.account.tenantId),this.loadAccessToken(e,t,c.homeAccountId,e.account.environment,e.account.tenantId,n),this.loadRefreshToken(e,t,c.homeAccountId,e.account.environment));else if(e.authority){var d=am.generateAuthority(e.authority,e.azureCloudOptions),h={protocolMode:this.config.auth.protocolMode,knownAuthorities:this.config.auth.knownAuthorities,cloudDiscoveryMetadata:this.config.auth.cloudDiscoveryMetadata,authorityMetadata:this.config.auth.authorityMetadata,skipAuthorityMetadataCache:this.config.auth.skipAuthorityMetadataCache};if(a=new am(d,this.config.system.networkClient,this.storage,h,this.logger),n.clientInfo)this.logger.trace("TokenCache - homeAccountId from options"),c=this.loadAccount(i,a,n.clientInfo),o=new sf(c,this.loadIdToken(i,c.homeAccountId,a.hostnameAndPort,a.tenant),this.loadAccessToken(e,t,c.homeAccountId,a.hostnameAndPort,a.tenant,n),this.loadRefreshToken(e,t,c.homeAccountId,a.hostnameAndPort));else if(t.client_info)this.logger.trace("TokenCache - homeAccountId from response"),c=this.loadAccount(i,a,t.client_info),o=new sf(c,this.loadIdToken(i,c.homeAccountId,a.hostnameAndPort,a.tenant),this.loadAccessToken(e,t,c.homeAccountId,a.hostnameAndPort,a.tenant,n),this.loadRefreshToken(e,t,c.homeAccountId,a.hostnameAndPort));else throw Me.createUnableToLoadTokenError("Please provide clientInfo in the response or options.")}else throw Me.createUnableToLoadTokenError("Please provide a request with an account or a request with authority.");return this.generateAuthenticationResult(e,i,o,c,a)},r.prototype.loadAccount=function(e,t,n,i){var o;if(i?o=i:t.authorityType!==void 0&&n&&(o=Ci.generateHomeAccountId(n,t.authorityType,this.logger,this.cryptoObj,e.claims)),!o)throw Me.createUnableToLoadTokenError("Unexpected missing homeAccountId");var a=Ci.createAccount({homeAccountId:o,idTokenClaims:e.claims,clientInfo:n,environment:t.hostnameAndPort},t);if(this.isBrowserEnvironment)return this.logger.verbose("TokenCache - loading account"),this.storage.setAccount(a),a;throw Me.createUnableToLoadTokenError("loadExternalTokens is designed to work in browser environments only.")},r.prototype.loadIdToken=function(e,t,n,i){var o=gl.createIdTokenEntity(t,n,e.rawToken,this.config.auth.clientId,i);if(this.isBrowserEnvironment)return this.logger.verbose("TokenCache - loading id token"),this.storage.setIdTokenCredential(o),o;throw Me.createUnableToLoadTokenError("loadExternalTokens is designed to work in browser environments only.")},r.prototype.loadAccessToken=function(e,t,n,i,o,a){if(!t.access_token)return this.logger.verbose("TokenCache - No access token provided for caching"),null;if(!t.expires_in)throw Me.createUnableToLoadTokenError("Please ensure server response includes expires_in value.");if(!a.extendedExpiresOn)throw Me.createUnableToLoadTokenError("Please provide an extendedExpiresOn value in the options.");var c=new gi(e.scopes).printScopes(),d=a.expiresOn||t.expires_in+new Date().getTime()/1e3,h=a.extendedExpiresOn,u=yl.createAccessTokenEntity(n,i,t.access_token,this.config.auth.clientId,o,c,d,h,this.cryptoObj);if(this.isBrowserEnvironment)return this.logger.verbose("TokenCache - loading access token"),this.storage.setAccessTokenCredential(u),u;throw Me.createUnableToLoadTokenError("loadExternalTokens is designed to work in browser environments only.")},r.prototype.loadRefreshToken=function(e,t,n,i){if(!t.refresh_token)return this.logger.verbose("TokenCache - No refresh token provided for caching"),null;var o=Qh.createRefreshTokenEntity(n,i,t.refresh_token,this.config.auth.clientId);if(this.isBrowserEnvironment)return this.logger.verbose("TokenCache - loading refresh token"),this.storage.setRefreshTokenCredential(o),o;throw Me.createUnableToLoadTokenError("loadExternalTokens is designed to work in browser environments only.")},r.prototype.generateAuthenticationResult=function(e,t,n,i,o){var a,c=G.EMPTY_STRING,d=[],h=null,u;n.accessToken&&(c=n.accessToken.secret,d=gi.fromString(n.accessToken.target).asArray(),h=new Date(Number(n.accessToken.expiresOn)*1e3),u=new Date(Number(n.accessToken.extendedExpiresOn)*1e3));var p=(t==null?void 0:t.claims.oid)||(t==null?void 0:t.claims.sub)||G.EMPTY_STRING,v=(t==null?void 0:t.claims.tid)||G.EMPTY_STRING;return{authority:o?o.canonicalAuthority:G.EMPTY_STRING,uniqueId:p,tenantId:v,scopes:d,account:i?i.getAccountInfo():null,idToken:t?t.rawToken:G.EMPTY_STRING,idTokenClaims:t?t.claims:{},accessToken:c,fromCache:!0,expiresOn:h,correlationId:e.correlationId||G.EMPTY_STRING,requestId:G.EMPTY_STRING,extExpiresOn:u,familyId:G.EMPTY_STRING,tokenType:((a=n==null?void 0:n.accessToken)===null||a===void 0?void 0:a.tokenType)||G.EMPTY_STRING,state:G.EMPTY_STRING,cloudGraphHostName:i.cloudGraphHostName||G.EMPTY_STRING,msGraphHost:i.msGraphHost||G.EMPTY_STRING,code:void 0,fromNativeBroker:!1}},r}();/*! @azure/msal-browser v2.39.0 2024-06-06 */var IF=function(r){ri(e,r);function e(t){var n=r.call(this,t)||this;return n.includeRedirectUri=!1,n}return e}(JR);/*! @azure/msal-browser v2.39.0 2024-06-06 */var RF=function(r){ri(e,r);function e(t,n,i,o,a,c,d,h,u,p){var v=r.call(this,t,n,i,o,a,c,h,u,p)||this;return v.apiId=d,v}return e.prototype.acquireToken=function(t){return fe(this,void 0,void 0,function(){var n,i,o,a,c,d,h;return pe(this,function(u){switch(u.label){case 0:if(this.logger.trace("SilentAuthCodeClient.acquireToken called"),!t.code)throw Me.createAuthCodeRequiredError();return this.performanceClient.setPreQueueTime(ae.StandardInteractionClientInitializeAuthorizationRequest,t.correlationId),[4,this.initializeAuthorizationRequest(t,et.Silent)];case 1:n=u.sent(),this.browserStorage.updateCacheEntries(n.state,n.nonce,n.authority,n.loginHint||G.EMPTY_STRING,n.account||null),i=this.initializeServerTelemetryManager(this.apiId),u.label=2;case 2:return u.trys.push([2,4,,5]),o=qe(qe({},n),{code:t.code}),this.performanceClient.setPreQueueTime(ae.StandardInteractionClientGetClientConfiguration,t.correlationId),[4,this.getClientConfiguration(i,n.authority)];case 3:return a=u.sent(),c=new IF(a),this.logger.verbose("Auth code client created"),d=new aP(c,this.browserStorage,o,this.logger,this.config.system,this.performanceClient),[2,d.handleCodeResponseFromServer({code:t.code,msgraph_host:t.msGraphHost,cloud_graph_host_name:t.cloudGraphHostName,cloud_instance_host_name:t.cloudInstanceHostName},n.state,c.authority,this.networkClient,!1)];case 4:throw h=u.sent(),h instanceof it&&h.setCorrelationId(this.correlationId),i.cacheFailedRequest(h),this.browserStorage.cleanRequestByState(n.state),h;case 5:return[2]}})})},e.prototype.logout=function(){return Promise.reject(Me.createSilentLogoutUnsupportedError())},e}(Ff);/*! @azure/msal-browser v2.39.0 2024-06-06 */var PF=function(){function r(e){this.isBrowserEnvironment=typeof window<"u",this.config=uF(e,this.isBrowserEnvironment),this.initialized=!1,this.logger=new p4(this.config.system.loggerOptions,O3,Zp),this.networkClient=this.config.system.networkClient,this.navigationClient=this.config.system.navigationClient,this.redirectResponse=new Map,this.hybridAuthCodeResponses=new Map,this.performanceClient=this.isBrowserEnvironment?new TF(this.config.auth.clientId,this.config.auth.authority,this.logger,O3,Zp,this.config.telemetry.application,this.config.system.cryptoOptions):new JV(this.config.auth.clientId,this.config.auth.authority,this.logger,O3,Zp,this.config.telemetry.application),this.browserCrypto=this.isBrowserEnvironment?new SF(this.logger,this.performanceClient,this.config.system.cryptoOptions):mg,this.eventHandler=new pF(this.logger,this.browserCrypto),this.browserStorage=this.isBrowserEnvironment?new Lb(this.config.auth.clientId,this.config.cache,this.browserCrypto,this.logger):rF(this.config.auth.clientId,this.logger);var t={cacheLocation:Cn.MemoryStorage,temporaryCacheLocation:Cn.MemoryStorage,storeAuthStateInCookie:!1,secureCookies:!1,cacheMigrationEnabled:!1,claimsBasedCachingEnabled:!0};this.nativeInternalStorage=new Lb(this.config.auth.clientId,t,this.browserCrypto,this.logger),this.tokenCache=new AF(this.config,this.browserStorage,this.logger,this.browserCrypto),this.trackPageVisibilityWithMeasurement=this.trackPageVisibilityWithMeasurement.bind(this)}return r.prototype.initialize=function(){return fe(this,void 0,void 0,function(){var e,t,n,i,o;return pe(this,function(a){switch(a.label){case 0:if(this.logger.trace("initialize called"),this.initialized)return this.logger.info("initialize has already been called, exiting early."),[2];if(e=this.config.system.allowNativeBroker,t=this.performanceClient.startMeasurement(ae.InitializeClientApplication),this.eventHandler.emitEvent(Ct.INITIALIZE_START),!e)return[3,4];a.label=1;case 1:return a.trys.push([1,3,,4]),n=this,[4,du.createProvider(this.logger,this.config.system.nativeBrokerHandshakeTimeout,this.performanceClient)];case 2:return n.nativeExtensionProvider=a.sent(),[3,4];case 3:return i=a.sent(),this.logger.verbose(i),[3,4];case 4:return this.config.cache.claimsBasedCachingEnabled?[3,6]:(this.logger.verbose("Claims-based caching is disabled. Clearing the previous cache with claims"),o=this.performanceClient.startMeasurement(ae.ClearTokensAndKeysWithClaims),[4,this.browserStorage.clearTokensAndKeysWithClaims()]);case 5:a.sent(),o.endMeasurement({success:!0}),a.label=6;case 6:return this.initialized=!0,this.eventHandler.emitEvent(Ct.INITIALIZE_END),t.endMeasurement({allowNativeBroker:e,success:!0}),[2]}})})},r.prototype.handleRedirectPromise=function(e){return fe(this,void 0,void 0,function(){var t,n,i,o,a,c,d,h,u=this;return pe(this,function(p){return this.logger.verbose("handleRedirectPromise called"),hn.blockNativeBrokerCalledBeforeInitialized(this.config.system.allowNativeBroker,this.initialized),t=this.getAllAccounts(),this.isBrowserEnvironment?(n=e||G.EMPTY_STRING,i=this.redirectResponse.get(n),typeof i>"u"?(this.eventHandler.emitEvent(Ct.HANDLE_REDIRECT_START,et.Redirect),this.logger.verbose("handleRedirectPromise has been called for the first time, storing the promise"),o=this.browserStorage.getCachedNativeRequest(),a=void 0,o&&du.isNativeAvailable(this.config,this.logger,this.nativeExtensionProvider)&&this.nativeExtensionProvider&&!e?(this.logger.trace("handleRedirectPromise - acquiring token from native platform"),c=new cf(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,$r.handleRedirectPromise,this.performanceClient,this.nativeExtensionProvider,o.accountId,this.nativeInternalStorage,o.correlationId),a=c.handleRedirectPromise()):(this.logger.trace("handleRedirectPromise - acquiring token from web flow"),d=this.browserStorage.getTemporaryCache(er.CORRELATION_ID,!0)||G.EMPTY_STRING,h=this.createRedirectClient(d),a=h.handleRedirectPromise(e)),i=a.then(function(v){if(v){var g=t.length<u.getAllAccounts().length;g?(u.eventHandler.emitEvent(Ct.LOGIN_SUCCESS,et.Redirect,v),u.logger.verbose("handleRedirectResponse returned result, login success")):(u.eventHandler.emitEvent(Ct.ACQUIRE_TOKEN_SUCCESS,et.Redirect,v),u.logger.verbose("handleRedirectResponse returned result, acquire token success"))}return u.eventHandler.emitEvent(Ct.HANDLE_REDIRECT_END,et.Redirect),v}).catch(function(v){throw t.length>0?u.eventHandler.emitEvent(Ct.ACQUIRE_TOKEN_FAILURE,et.Redirect,null,v):u.eventHandler.emitEvent(Ct.LOGIN_FAILURE,et.Redirect,null,v),u.eventHandler.emitEvent(Ct.HANDLE_REDIRECT_END,et.Redirect),v}),this.redirectResponse.set(n,i)):this.logger.verbose("handleRedirectPromise has been called previously, returning the result from the first call"),[2,i]):(this.logger.verbose("handleRedirectPromise returns null, not browser environment"),[2,null])})})},r.prototype.acquireTokenRedirect=function(e){return fe(this,void 0,void 0,function(){var t,n,i,o,a,c=this;return pe(this,function(d){return t=this.getRequestCorrelationId(e),this.logger.verbose("acquireTokenRedirect called",t),this.preflightBrowserEnvironmentCheck(et.Redirect),n=this.getAllAccounts().length>0,n?this.eventHandler.emitEvent(Ct.ACQUIRE_TOKEN_START,et.Redirect,e):this.eventHandler.emitEvent(Ct.LOGIN_START,et.Redirect,e),this.nativeExtensionProvider&&this.canUseNative(e)?(o=new cf(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,$r.acquireTokenRedirect,this.performanceClient,this.nativeExtensionProvider,this.getNativeAccountId(e),this.nativeInternalStorage,e.correlationId),i=o.acquireTokenRedirect(e).catch(function(h){if(h instanceof us&&h.isFatal()){c.nativeExtensionProvider=void 0;var u=c.createRedirectClient(e.correlationId);return u.acquireToken(e)}else if(h instanceof $a){c.logger.verbose("acquireTokenRedirect - Resolving interaction required error thrown by native broker by falling back to web flow");var u=c.createRedirectClient(e.correlationId);return u.acquireToken(e)}throw c.browserStorage.setInteractionInProgress(!1),h})):(a=this.createRedirectClient(e.correlationId),i=a.acquireToken(e)),[2,i.catch(function(h){throw n?c.eventHandler.emitEvent(Ct.ACQUIRE_TOKEN_FAILURE,et.Redirect,null,h):c.eventHandler.emitEvent(Ct.LOGIN_FAILURE,et.Redirect,null,h),h})]})})},r.prototype.acquireTokenPopup=function(e){var t=this,n=this.getRequestCorrelationId(e),i=this.performanceClient.startMeasurement(ae.AcquireTokenPopup,n);try{this.logger.verbose("acquireTokenPopup called",n),this.preflightBrowserEnvironmentCheck(et.Popup)}catch(d){return Promise.reject(d)}var o=this.getAllAccounts();o.length>0?this.eventHandler.emitEvent(Ct.ACQUIRE_TOKEN_START,et.Popup,e):this.eventHandler.emitEvent(Ct.LOGIN_START,et.Popup,e);var a;if(this.canUseNative(e))a=this.acquireTokenNative(e,$r.acquireTokenPopup).then(function(d){return t.browserStorage.setInteractionInProgress(!1),i.endMeasurement({success:!0,isNativeBroker:!0,requestId:d.requestId}),d}).catch(function(d){if(d instanceof us&&d.isFatal()){t.nativeExtensionProvider=void 0;var h=t.createPopupClient(e.correlationId);return h.acquireToken(e)}else if(d instanceof $a){t.logger.verbose("acquireTokenPopup - Resolving interaction required error thrown by native broker by falling back to web flow");var h=t.createPopupClient(e.correlationId);return h.acquireToken(e)}throw t.browserStorage.setInteractionInProgress(!1),d});else{var c=this.createPopupClient(e.correlationId);a=c.acquireToken(e)}return a.then(function(d){var h=o.length<t.getAllAccounts().length;return h?t.eventHandler.emitEvent(Ct.LOGIN_SUCCESS,et.Popup,d):t.eventHandler.emitEvent(Ct.ACQUIRE_TOKEN_SUCCESS,et.Popup,d),i.addStaticFields({accessTokenSize:d.accessToken.length,idTokenSize:d.idToken.length}),i.endMeasurement({success:!0,requestId:d.requestId}),d}).catch(function(d){return o.length>0?t.eventHandler.emitEvent(Ct.ACQUIRE_TOKEN_FAILURE,et.Popup,null,d):t.eventHandler.emitEvent(Ct.LOGIN_FAILURE,et.Popup,null,d),i.endMeasurement({errorCode:d.errorCode,subErrorCode:d.subError,success:!1}),Promise.reject(d)})},r.prototype.trackPageVisibilityWithMeasurement=function(){var e=this.ssoSilentMeasurement||this.acquireTokenByCodeAsyncMeasurement;e&&(this.logger.info("Perf: Visibility change detected in ",e.event.name),e.increment({visibilityChangeCount:1}))},r.prototype.ssoSilent=function(e){var t;return fe(this,void 0,void 0,function(){var n,i,o,a,c=this;return pe(this,function(d){return n=this.getRequestCorrelationId(e),i=qe(qe({},e),{prompt:e.prompt,correlationId:n}),this.preflightBrowserEnvironmentCheck(et.Silent),this.ssoSilentMeasurement=this.performanceClient.startMeasurement(ae.SsoSilent,n),(t=this.ssoSilentMeasurement)===null||t===void 0||t.increment({visibilityChangeCount:0}),document.addEventListener("visibilitychange",this.trackPageVisibilityWithMeasurement),this.logger.verbose("ssoSilent called",n),this.eventHandler.emitEvent(Ct.SSO_SILENT_START,et.Silent,i),this.canUseNative(i)?o=this.acquireTokenNative(i,$r.ssoSilent).catch(function(h){if(h instanceof us&&h.isFatal()){c.nativeExtensionProvider=void 0;var u=c.createSilentIframeClient(i.correlationId);return u.acquireToken(i)}throw h}):(a=this.createSilentIframeClient(i.correlationId),o=a.acquireToken(i)),[2,o.then(function(h){var u,p;return c.eventHandler.emitEvent(Ct.SSO_SILENT_SUCCESS,et.Silent,h),(u=c.ssoSilentMeasurement)===null||u===void 0||u.addStaticFields({accessTokenSize:h.accessToken.length,idTokenSize:h.idToken.length}),(p=c.ssoSilentMeasurement)===null||p===void 0||p.endMeasurement({success:!0,isNativeBroker:h.fromNativeBroker,requestId:h.requestId}),h}).catch(function(h){var u;throw c.eventHandler.emitEvent(Ct.SSO_SILENT_FAILURE,et.Silent,null,h),(u=c.ssoSilentMeasurement)===null||u===void 0||u.endMeasurement({errorCode:h.errorCode,subErrorCode:h.subError,success:!1}),h}).finally(function(){document.removeEventListener("visibilitychange",c.trackPageVisibilityWithMeasurement)})]})})},r.prototype.acquireTokenByCode=function(e){return fe(this,void 0,void 0,function(){var t,n,i,o,a=this;return pe(this,function(c){t=this.getRequestCorrelationId(e),this.preflightBrowserEnvironmentCheck(et.Silent),this.logger.trace("acquireTokenByCode called",t),this.eventHandler.emitEvent(Ct.ACQUIRE_TOKEN_BY_CODE_START,et.Silent,e),n=this.performanceClient.startMeasurement(ae.AcquireTokenByCode,e.correlationId);try{if(e.code&&e.nativeAccountId)throw Me.createSpaCodeAndNativeAccountIdPresentError();if(e.code)return i=e.code,o=this.hybridAuthCodeResponses.get(i),o?(this.logger.verbose("Existing acquireTokenByCode request found",e.correlationId),n.discardMeasurement()):(this.logger.verbose("Initiating new acquireTokenByCode request",t),o=this.acquireTokenByCodeAsync(qe(qe({},e),{correlationId:t})).then(function(d){return a.eventHandler.emitEvent(Ct.ACQUIRE_TOKEN_BY_CODE_SUCCESS,et.Silent,d),a.hybridAuthCodeResponses.delete(i),n.addStaticFields({accessTokenSize:d.accessToken.length,idTokenSize:d.idToken.length}),n.endMeasurement({success:!0,isNativeBroker:d.fromNativeBroker,requestId:d.requestId}),d}).catch(function(d){throw a.hybridAuthCodeResponses.delete(i),a.eventHandler.emitEvent(Ct.ACQUIRE_TOKEN_BY_CODE_FAILURE,et.Silent,null,d),n.endMeasurement({errorCode:d.errorCode,subErrorCode:d.subError,success:!1}),d}),this.hybridAuthCodeResponses.set(i,o)),[2,o];if(e.nativeAccountId){if(this.canUseNative(e,e.nativeAccountId))return[2,this.acquireTokenNative(e,$r.acquireTokenByCode,e.nativeAccountId).catch(function(d){throw d instanceof us&&d.isFatal()&&(a.nativeExtensionProvider=void 0),d})];throw Me.createUnableToAcquireTokenFromNativePlatformError()}else throw Me.createAuthCodeOrNativeAccountIdRequiredError()}catch(d){throw this.eventHandler.emitEvent(Ct.ACQUIRE_TOKEN_BY_CODE_FAILURE,et.Silent,null,d),n.endMeasurement({errorCode:d instanceof it&&d.errorCode||void 0,subErrorCode:d instanceof it&&d.subError||void 0,success:!1}),d}return[2]})})},r.prototype.acquireTokenByCodeAsync=function(e){var t;return fe(this,void 0,void 0,function(){var n,i,o=this;return pe(this,function(a){switch(a.label){case 0:return this.logger.trace("acquireTokenByCodeAsync called",e.correlationId),this.acquireTokenByCodeAsyncMeasurement=this.performanceClient.startMeasurement(ae.AcquireTokenByCodeAsync,e.correlationId),(t=this.acquireTokenByCodeAsyncMeasurement)===null||t===void 0||t.increment({visibilityChangeCount:0}),document.addEventListener("visibilitychange",this.trackPageVisibilityWithMeasurement),n=this.createSilentAuthCodeClient(e.correlationId),[4,n.acquireToken(e).then(function(c){var d;return(d=o.acquireTokenByCodeAsyncMeasurement)===null||d===void 0||d.endMeasurement({success:!0,fromCache:c.fromCache,isNativeBroker:c.fromNativeBroker,requestId:c.requestId}),c}).catch(function(c){var d;throw(d=o.acquireTokenByCodeAsyncMeasurement)===null||d===void 0||d.endMeasurement({errorCode:c.errorCode,subErrorCode:c.subError,success:!1}),c}).finally(function(){document.removeEventListener("visibilitychange",o.trackPageVisibilityWithMeasurement)})];case 1:return i=a.sent(),[2,i]}})})},r.prototype.acquireTokenFromCache=function(e,t,n){return fe(this,void 0,void 0,function(){return pe(this,function(i){switch(this.performanceClient.addQueueMeasurement(ae.AcquireTokenFromCache,t.correlationId),n.cacheLookupPolicy){case oo.Default:case oo.AccessToken:case oo.AccessTokenAndRefreshToken:return[2,e.acquireToken(t)];default:throw We.createRefreshRequiredError()}return[2]})})},r.prototype.acquireTokenByRefreshToken=function(e,t){return fe(this,void 0,void 0,function(){var n;return pe(this,function(i){switch(this.performanceClient.addQueueMeasurement(ae.AcquireTokenByRefreshToken,e.correlationId),t.cacheLookupPolicy){case oo.Default:case oo.AccessTokenAndRefreshToken:case oo.RefreshToken:case oo.RefreshTokenAndNetwork:return n=this.createSilentRefreshClient(e.correlationId),this.performanceClient.setPreQueueTime(ae.SilentRefreshClientAcquireToken,e.correlationId),[2,n.acquireToken(e)];default:throw We.createRefreshRequiredError()}return[2]})})},r.prototype.acquireTokenBySilentIframe=function(e){return fe(this,void 0,void 0,function(){var t;return pe(this,function(n){return this.performanceClient.addQueueMeasurement(ae.AcquireTokenBySilentIframe,e.correlationId),t=this.createSilentIframeClient(e.correlationId),this.performanceClient.setPreQueueTime(ae.SilentIframeClientAcquireToken,e.correlationId),[2,t.acquireToken(e)]})})},r.prototype.logout=function(e){return fe(this,void 0,void 0,function(){var t;return pe(this,function(n){return t=this.getRequestCorrelationId(e),this.logger.warning("logout API is deprecated and will be removed in msal-browser v3.0.0. Use logoutRedirect instead.",t),[2,this.logoutRedirect(qe({correlationId:t},e))]})})},r.prototype.logoutRedirect=function(e){return fe(this,void 0,void 0,function(){var t,n;return pe(this,function(i){return t=this.getRequestCorrelationId(e),this.preflightBrowserEnvironmentCheck(et.Redirect),n=this.createRedirectClient(t),[2,n.logout(e)]})})},r.prototype.logoutPopup=function(e){try{var t=this.getRequestCorrelationId(e);this.preflightBrowserEnvironmentCheck(et.Popup);var n=this.createPopupClient(t);return n.logout(e)}catch(i){return Promise.reject(i)}},r.prototype.getAllAccounts=function(){return this.logger.verbose("getAllAccounts called"),this.isBrowserEnvironment?this.browserStorage.getAllAccounts():[]},r.prototype.getAccountByUsername=function(e){if(this.logger.trace("getAccountByUsername called"),!e)return this.logger.warning("getAccountByUsername: No username provided"),null;var t=this.browserStorage.getAccountInfoFilteredBy({username:e});return t?(this.logger.verbose("getAccountByUsername: Account matching username found, returning"),this.logger.verbosePii("getAccountByUsername: Returning signed-in accounts matching username: "+e),t):(this.logger.verbose("getAccountByUsername: No matching account found, returning null"),null)},r.prototype.getAccountByHomeId=function(e){if(this.logger.trace("getAccountByHomeId called"),!e)return this.logger.warning("getAccountByHomeId: No homeAccountId provided"),null;var t=this.browserStorage.getAccountInfoFilteredBy({homeAccountId:e});return t?(this.logger.verbose("getAccountByHomeId: Account matching homeAccountId found, returning"),this.logger.verbosePii("getAccountByHomeId: Returning signed-in accounts matching homeAccountId: "+e),t):(this.logger.verbose("getAccountByHomeId: No matching account found, returning null"),null)},r.prototype.getAccountByLocalId=function(e){if(this.logger.trace("getAccountByLocalId called"),!e)return this.logger.warning("getAccountByLocalId: No localAccountId provided"),null;var t=this.browserStorage.getAccountInfoFilteredBy({localAccountId:e});return t?(this.logger.verbose("getAccountByLocalId: Account matching localAccountId found, returning"),this.logger.verbosePii("getAccountByLocalId: Returning signed-in accounts matching localAccountId: "+e),t):(this.logger.verbose("getAccountByLocalId: No matching account found, returning null"),null)},r.prototype.setActiveAccount=function(e){this.browserStorage.setActiveAccount(e)},r.prototype.getActiveAccount=function(){return this.browserStorage.getActiveAccount()},r.prototype.preflightBrowserEnvironmentCheck=function(e,t){if(t===void 0&&(t=!0),this.logger.verbose("preflightBrowserEnvironmentCheck started"),hn.blockNonBrowserEnvironment(this.isBrowserEnvironment),hn.blockRedirectInIframe(e,this.config.system.allowRedirectInIframe),hn.blockReloadInHiddenIframes(),hn.blockAcquireTokenInPopups(),hn.blockNativeBrokerCalledBeforeInitialized(this.config.system.allowNativeBroker,this.initialized),e===et.Redirect&&this.config.cache.cacheLocation===Cn.MemoryStorage&&!this.config.cache.storeAuthStateInCookie)throw xg.createInMemoryRedirectUnavailableError();(e===et.Redirect||e===et.Popup)&&this.preflightInteractiveRequest(t)},r.prototype.preflightInteractiveRequest=function(e){this.logger.verbose("preflightInteractiveRequest called, validating app environment"),hn.blockReloadInHiddenIframes(),e&&this.browserStorage.setInteractionInProgress(!0)},r.prototype.acquireTokenNative=function(e,t,n){return fe(this,void 0,void 0,function(){var i;return pe(this,function(o){if(this.logger.trace("acquireTokenNative called"),!this.nativeExtensionProvider)throw Me.createNativeConnectionNotEstablishedError();return i=new cf(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,t,this.performanceClient,this.nativeExtensionProvider,n||this.getNativeAccountId(e),this.nativeInternalStorage,e.correlationId),[2,i.acquireToken(e)]})})},r.prototype.canUseNative=function(e,t){if(this.logger.trace("canUseNative called"),!du.isNativeAvailable(this.config,this.logger,this.nativeExtensionProvider,e.authenticationScheme))return this.logger.trace("canUseNative: isNativeAvailable returned false, returning false"),!1;if(e.prompt)switch(e.prompt){case wi.NONE:case wi.CONSENT:case wi.LOGIN:this.logger.trace("canUseNative: prompt is compatible with native flow");break;default:return this.logger.trace("canUseNative: prompt = "+e.prompt+" is not compatible with native flow, returning false"),!1}return!t&&!this.getNativeAccountId(e)?(this.logger.trace("canUseNative: nativeAccountId is not available, returning false"),!1):!0},r.prototype.getNativeAccountId=function(e){var t=e.account||this.browserStorage.getAccountInfoByHints(e.loginHint,e.sid)||this.getActiveAccount();return t&&t.nativeAccountId||""},r.prototype.createPopupClient=function(e){return new aF(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,this.performanceClient,this.nativeInternalStorage,this.nativeExtensionProvider,e)},r.prototype.createRedirectClient=function(e){return new oF(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,this.performanceClient,this.nativeInternalStorage,this.nativeExtensionProvider,e)},r.prototype.createSilentIframeClient=function(e){return new hF(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,$r.ssoSilent,this.performanceClient,this.nativeInternalStorage,this.nativeExtensionProvider,e)},r.prototype.createSilentCacheClient=function(e){return new oP(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,this.performanceClient,this.nativeExtensionProvider,e)},r.prototype.createSilentRefreshClient=function(e){return new fF(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,this.performanceClient,this.nativeExtensionProvider,e)},r.prototype.createSilentAuthCodeClient=function(e){return new RF(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,$r.acquireTokenByCode,this.performanceClient,this.nativeExtensionProvider,e)},r.prototype.addEventCallback=function(e){return this.eventHandler.addEventCallback(e)},r.prototype.removeEventCallback=function(e){this.eventHandler.removeEventCallback(e)},r.prototype.addPerformanceCallback=function(e){return this.performanceClient.addPerformanceCallback(e)},r.prototype.removePerformanceCallback=function(e){return this.performanceClient.removePerformanceCallback(e)},r.prototype.enableAccountStorageEvents=function(){this.eventHandler.enableAccountStorageEvents()},r.prototype.disableAccountStorageEvents=function(){this.eventHandler.disableAccountStorageEvents()},r.prototype.getTokenCache=function(){return this.tokenCache},r.prototype.getLogger=function(){return this.logger},r.prototype.setLogger=function(e){this.logger=e},r.prototype.initializeWrapperLibrary=function(e,t){this.browserStorage.setWrapperMetadata(e,t)},r.prototype.setNavigationClient=function(e){this.navigationClient=e},r.prototype.getConfiguration=function(){return this.config},r.prototype.getRequestCorrelationId=function(e){return e!=null&&e.correlationId?e.correlationId:this.isBrowserEnvironment?this.browserCrypto.createNewGuid():G.EMPTY_STRING},r}();/*! @azure/msal-browser v2.39.0 2024-06-06 */var MF=function(r){ri(e,r);function e(t){var n=r.call(this,t)||this;return n.astsAsyncMeasurement=void 0,n.activeSilentTokenRequests=new Map,n.trackPageVisibility=n.trackPageVisibility.bind(n),n}return e.prototype.loginRedirect=function(t){return fe(this,void 0,void 0,function(){var n;return pe(this,function(i){return n=this.getRequestCorrelationId(t),this.logger.verbose("loginRedirect called",n),[2,this.acquireTokenRedirect(qe({correlationId:n},t||qC))]})})},e.prototype.loginPopup=function(t){var n=this.getRequestCorrelationId(t);return this.logger.verbose("loginPopup called",n),this.acquireTokenPopup(qe({correlationId:n},t||qC))},e.prototype.acquireTokenSilent=function(t){return fe(this,void 0,void 0,function(){var n,i,o,a,c,d,h,u=this;return pe(this,function(p){if(n=this.getRequestCorrelationId(t),i=this.performanceClient.startMeasurement(ae.AcquireTokenSilent,n),i.addStaticFields({cacheLookupPolicy:t.cacheLookupPolicy}),this.preflightBrowserEnvironmentCheck(et.Silent),this.logger.verbose("acquireTokenSilent called",n),o=t.account||this.getActiveAccount(),!o)throw Me.createNoAccountError();return a={clientId:this.config.auth.clientId,authority:t.authority||G.EMPTY_STRING,scopes:t.scopes,homeAccountIdentifier:o.homeAccountId,claims:t.claims,authenticationScheme:t.authenticationScheme,resourceRequestMethod:t.resourceRequestMethod,resourceRequestUri:t.resourceRequestUri,shrClaims:t.shrClaims,sshKid:t.sshKid},c=JSON.stringify(a),d=this.activeSilentTokenRequests.get(c),typeof d>"u"?(this.logger.verbose("acquireTokenSilent called for the first time, storing active request",n),this.performanceClient.setPreQueueTime(ae.AcquireTokenSilentAsync,n),h=this.acquireTokenSilentAsync(qe(qe({},t),{correlationId:n}),o).then(function(v){return u.activeSilentTokenRequests.delete(c),i.addStaticFields({accessTokenSize:v.accessToken.length,idTokenSize:v.idToken.length}),i.endMeasurement({success:!0,fromCache:v.fromCache,isNativeBroker:v.fromNativeBroker,cacheLookupPolicy:t.cacheLookupPolicy,requestId:v.requestId}),v}).catch(function(v){throw u.activeSilentTokenRequests.delete(c),i.endMeasurement({errorCode:v.errorCode,subErrorCode:v.subError,success:!1}),v}),this.activeSilentTokenRequests.set(c,h),[2,h]):(this.logger.verbose("acquireTokenSilent has been called previously, returning the result from the first call",n),i.discardMeasurement(),[2,d])})})},e.prototype.trackPageVisibility=function(){this.astsAsyncMeasurement&&(this.logger.info("Perf: Visibility change detected"),this.astsAsyncMeasurement.increment({visibilityChangeCount:1}))},e.prototype.acquireTokenSilentAsync=function(t,n){var i;return fe(this,void 0,void 0,function(){var o,a,c,d,h,u=this;return pe(this,function(p){switch(p.label){case 0:return this.performanceClient.addQueueMeasurement(ae.AcquireTokenSilentAsync,t.correlationId),this.eventHandler.emitEvent(Ct.ACQUIRE_TOKEN_START,et.Silent,t),this.astsAsyncMeasurement=this.performanceClient.startMeasurement(ae.AcquireTokenSilentAsync,t.correlationId),(i=this.astsAsyncMeasurement)===null||i===void 0||i.increment({visibilityChangeCount:0}),document.addEventListener("visibilitychange",this.trackPageVisibility),du.isNativeAvailable(this.config,this.logger,this.nativeExtensionProvider,t.authenticationScheme)&&n.nativeAccountId?(this.logger.verbose("acquireTokenSilent - attempting to acquire token from native platform"),a=qe(qe({},t),{account:n}),o=this.acquireTokenNative(a,$r.acquireTokenSilent_silentFlow).catch(function(v){return fe(u,void 0,void 0,function(){var g;return pe(this,function(_){if(v instanceof us&&v.isFatal())return this.logger.verbose("acquireTokenSilent - native platform unavailable, falling back to web flow"),this.nativeExtensionProvider=void 0,g=this.createSilentIframeClient(t.correlationId),[2,g.acquireToken(t)];throw v})})}),[3,3]):[3,1];case 1:return this.logger.verbose("acquireTokenSilent - attempting to acquire token from web flow"),c=this.createSilentCacheClient(t.correlationId),this.performanceClient.setPreQueueTime(ae.InitializeSilentRequest,t.correlationId),[4,c.initializeSilentRequest(t,n)];case 2:d=p.sent(),h=qe(qe({},t),{cacheLookupPolicy:t.cacheLookupPolicy||oo.Default}),this.performanceClient.setPreQueueTime(ae.AcquireTokenFromCache,d.correlationId),o=this.acquireTokenFromCache(c,d,h).catch(function(v){if(h.cacheLookupPolicy===oo.AccessToken)throw v;return hn.blockReloadInHiddenIframes(),u.eventHandler.emitEvent(Ct.ACQUIRE_TOKEN_NETWORK_START,et.Silent,d),u.performanceClient.setPreQueueTime(ae.AcquireTokenByRefreshToken,d.correlationId),u.acquireTokenByRefreshToken(d,h).catch(function(g){var _=g instanceof xu,b=g instanceof $a,C=g.errorCode===Xh.noTokensFoundError.code,T=g.errorCode===Ra.INVALID_GRANT_ERROR;if((!_||!T||b||h.cacheLookupPolicy===oo.AccessTokenAndRefreshToken||h.cacheLookupPolicy===oo.RefreshToken)&&h.cacheLookupPolicy!==oo.Skip&&!C)throw g;return u.logger.verbose("Refresh token expired/invalid or CacheLookupPolicy is set to Skip, attempting acquire token by iframe.",t.correlationId),u.performanceClient.setPreQueueTime(ae.AcquireTokenBySilentIframe,d.correlationId),u.acquireTokenBySilentIframe(d)})}),p.label=3;case 3:return[2,o.then(function(v){var g;return u.eventHandler.emitEvent(Ct.ACQUIRE_TOKEN_SUCCESS,et.Silent,v),(g=u.astsAsyncMeasurement)===null||g===void 0||g.endMeasurement({success:!0,fromCache:v.fromCache,isNativeBroker:v.fromNativeBroker,requestId:v.requestId}),v}).catch(function(v){var g;throw u.eventHandler.emitEvent(Ct.ACQUIRE_TOKEN_FAILURE,et.Silent,null,v),(g=u.astsAsyncMeasurement)===null||g===void 0||g.endMeasurement({errorCode:v.errorCode,subErrorCode:v.subError,success:!1}),v}).finally(function(){document.removeEventListener("visibilitychange",u.trackPageVisibility)})]}})})},e.prototype.hydrateCache=function(t,n){return fe(this,void 0,void 0,function(){var i;return pe(this,function(o){return this.logger.verbose("hydrateCache called"),t.account?(i=Ci.createFromAccountInfo(t.account,t.cloudGraphHostName,t.msGraphHost),this.browserStorage.setAccount(i),t.fromNativeBroker?(this.logger.verbose("Response was from native broker, storing in-memory"),[2,this.nativeInternalStorage.hydrateCache(t,n)]):[2,this.browserStorage.hydrateCache(t,n)]):[2]})})},e}(PF);const JC="redirect";var ek=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};class $F extends MF{get account(){return this.getAllAccounts().find(n=>{var i;return((i=n.idTokenClaims)===null||i===void 0?void 0:i.aud)===this.clientId})}get hasValidClaims(){var e;const t=(e=this.account)===null||e===void 0?void 0:e.idTokenClaims;if(t){const n=Math.ceil(Date.now()/1e3);return t.exp>n}return!1}get clientId(){var e;return(e=this.config.auth)===null||e===void 0?void 0:e.clientId}get requestOrigin(){return this.browserStorage.getTemporaryCache("request.origin",!0)}constructor(e,t){super(t),this.tenantId=e}login(e){return ek(this,arguments,void 0,function*(t,n=JC,i=!0){var o;const a=(t==null?void 0:t.loginHint)||((o=this.account)===null||o===void 0?void 0:o.username),c=(t==null?void 0:t.scopes)||[],d=Object.assign(Object.assign({},t),{loginHint:a,scopes:c});if(a&&i){this.logger.verbose("Attempting to login in silently");try{return yield this.ssoSilent(d)}catch{this.logger.verbose("Silent login attempt failed")}}switch(this.logger.verbose(`Attempting to login in by [${n}]`),n){case"popup":return this.loginPopup(d);case"redirect":return this.loginRedirect(d)}})}acquireToken(){return ek(this,arguments,void 0,function*(e={scopes:[]},t=JC,n=!0){const i=yield this.account;if(n&&i){this.logger.verbose("Attempting to acquire token in silently");try{return yield this.acquireTokenSilent(Object.assign({account:i},e))}catch{this.logger.info("Expected to navigate away from the current page but timeout occurred.")}}switch(this.logger.verbose(`Attempting to acquire token by [${t}]`),t){case"popup":return this.acquireTokenPopup(e);case"redirect":return this.acquireTokenRedirect(e)}})}}const OF=(r,e=window.location.origin)=>{r=r.match(/^http[s]?/)?r:e+r;const{origin:t,pathname:n}=new URL(r);return t+n.replace(/([^:]\/)\/+/g,"$1")},ZF=(r,e,t,n,i)=>{const o=Object.assign({clientId:e,redirectUri:OF(t||""),navigateToLoginRequestUrl:!1,authority:`https://login.microsoftonline.com/${r}`},void 0),a=Object.assign({cacheLocation:"localStorage"},void 0),c=void 0;return new $F(r,{auth:o,cache:a,system:c})};let LF=class extends p4{constructor(e){super({logLevel:e,loggerCallback:(...t)=>this.loggerCallback(...t)}),this.getLogType=t=>{switch(t){case tn.Error:return"error";case tn.Warning:return"warn";case tn.Info:return"info";case tn.Verbose:return"debug";default:return this.getLogType(tn.Verbose)}}}loggerCallback(e,t,n){console[this.getLogType(e)]("%c FUSION::MSAL %c %s","border: 1px solid;","border: none;",t)}};function HF(r){const e=ep.coerce(r||Ma.Latest),t=ep.coerce(Ma.Latest);if(!e)throw new Error(`Invalid version ${r} provided`);if(!t)throw new Error("Invalid latest version");if(ep.gt(e,t))throw new Error(`Requested version ${r} is greater than the latest version ${Ma.Latest}`);const n=Object.values(Ma).find(i=>{var o;return((o=ep.coerce(i))===null||o===void 0?void 0:o.major)===e.major});return{wantedVersion:e,latestVersion:t,enumVersion:n,isLatest:e.compare(t)===0,satisfiesLatest:e.major===t.major}}var k0=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})},NF=function(r,e,t,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?r!==e||!i:!e.has(r))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(r,t):i?i.value=t:e.set(r,t),t},DF=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},_v;class VF{get version(){return new fs(Ma.Latest)}get defaultClient(){return this.getClient()}get defaultAccount(){return this.defaultClient.account}get defaultConfig(){return this._config}constructor(e){this._config=e,_v.set(this,void 0),NF(this,_v,this.createClient(),"f")}getClient(){return DF(this,_v,"f")}createClient(){const e=ZF(this._config.tenantId,this._config.clientId,this._config.redirectUri);return e.setLogger(new LF(0)),e}handleRedirect(){return k0(this,void 0,void 0,function*(){const{redirectUri:e}=this.defaultConfig||{};if(window.location.pathname===e){const t=this.defaultClient,n=t.getLogger(),{requestOrigin:i}=t;yield t.handleRedirectPromise(),i===e?(n.warning(`detected callback loop from url ${e}, redirecting to root`),window.location.replace("/")):window.location.replace(i||"/")}return null})}acquireToken(e){return this.defaultClient.acquireToken(e)}acquireAccessToken(e){return k0(this,void 0,void 0,function*(){const t=yield this.acquireToken(e);return t?t.accessToken:void 0})}login(e){return k0(this,void 0,void 0,function*(){e!=null&&e.onlyIfRequired&&this.defaultClient.hasValidClaims||(yield this.defaultClient.login())})}logout(e){return k0(this,void 0,void 0,function*(){yield this.defaultClient.logoutRedirect({postLogoutRedirectUri:e==null?void 0:e.redirectUri,account:this.defaultAccount})})}createProxyProvider(e){const{enumVersion:t}=HF(e);switch(t){case Ma.V2:case Ma.Latest:return this._createProxyProvider_v2();default:throw new Error(`Version ${e} is not supported`)}}_createProxyProvider_v2(){return new Proxy(this,{get:(e,t)=>{switch(t){case"version":return e.version;case"defaultAccount":return e.defaultAccount;case"defaultConfig":return e.defaultConfig;case"acquireToken":return e.acquireToken.bind(e);case"acquireAccessToken":return e.acquireAccessToken.bind(e);case"login":return e.login.bind(e);case"handleRedirect":return e.handleRedirect.bind(e);case"createProxyProvider":return e.createProxyProvider.bind(e)}}})}}_v=new WeakMap;var FF=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};const tk={name:"auth",version:new fs(Ma.Latest),configure:()=>new TV,initialize:r=>FF(void 0,void 0,void 0,function*(){var e;const t=yield r.config.createConfigAsync(r);if(t.provider)return t.provider;const n=(e=r.ref)===null||e===void 0?void 0:e.auth;if(n)try{return n.createProxyProvider(t.version)}catch(o){return console.error("MsalModule::Failed to create proxy provider",o),n}if(!t.client)throw new Error("Client configuration is required when provider is not in the parent module nor defined");const i=new VF(t.client);return t.requiresAuth&&(yield i.handleRedirect(),yield i.login({onlyIfRequired:!0})),i})};var O6=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};const jF=r=>{var e;return{id:r.id,isChildType:r.isChildType,parentTypeIds:(e=r.parentTypeIds)!==null&&e!==void 0?e:[]}},Z6=r=>{var e,t,n,i;return{id:r.id,externalId:(e=r.externalId)!==null&&e!==void 0?e:void 0,isActive:r.isActive,isDeleted:r.isDeleted,created:new Date(r.created),source:(t=r.source)!==null&&t!==void 0?t:void 0,title:(n=r.title)!==null&&n!==void 0?n:void 0,type:jF(r.type),value:(i=r.value)!==null&&i!==void 0?i:{}}},zF=r=>O6(void 0,void 0,void 0,function*(){const e=yield r.json();return Z6(e)}),BF=r=>O6(void 0,void 0,void 0,function*(){return(yield r.json()).map(Z6)}),UF=r=>O6(void 0,void 0,void 0,function*(){return(yield r.json()).map(Z6)});var qF=function(r,e,t,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?r!==e||!i:!e.has(r))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(r,t):i?i.value=t:e.set(r,t),t},WF=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},bv;class GF{constructor(e,t={}){this.config=t,bv.set(this,void 0),qF(this,bv,e,"f")}requireInstance(e){return WF(this,bv,"f").requireInstance(e)}setContextType(e){this.config.contextType=e}setContextFilter(e){this.config.contextFilter=e}connectParentContext(e){this.config.connectParentContext=e}setContextParameterFn(e){this.config.contextParameterFn=e}setValidateContext(e){this.config.validateContext=e}setResolveContext(e){this.config.resolveContext=e}setResolveInitialContext(e){this.config.resolveInitialContext=e}setContextClient(e,t=1*60*1e3){this.config.client={get:typeof e.get=="function"?{key:({id:n})=>n,client:{fn:e.get},expire:t}:e.get,query:typeof e.query=="function"?{key:n=>JSON.stringify(n),client:{fn:e.query},expire:t}:e.query},e.related&&(this.config.client.related=typeof e.related=="function"?{key:n=>JSON.stringify(n),client:{fn:e.related},expire:t}:e.related)}}bv=new WeakMap;const dP=/^(?:(?:[0-9a-fA-F]){8}-(?:[0-9a-fA-F]){4}-(?:[0-9a-fA-F]){4}-(?:[0-9a-fA-F]){4}-(?:[0-9a-fA-F]){12})$/,uP=(r,e=dP)=>r.replace(/^\/+/,"").split("/").find(t=>t.match(e)),KF=r=>!!r.match(dP);function YF(r,e){return t=>{const{extract:n=uP,validate:i=KF}={},o=n(t);if(!o)return Tr;if(i(o))return r.contextClient.resolveContext(o);throw Error(`Failed to validate context [${o}] from path [${t}]`)}}const QF=({ref:r})=>{const e=r==null?void 0:r.context;if(!e)throw Error(["resolveContextFromNavigation","ref does not support context!"].join(`
74
- `));return e.currentContext?It(e.currentContext):Tr},XF=r=>({ref:e,modules:t})=>{var n,i;const{context:o,navigation:a}=t,c=YF(o),d=(n=a==null?void 0:a.path.pathname)!==null&&n!==void 0?n:(i=e.navigation)===null||i===void 0?void 0:i.path.pathname;return xl(d?c(d):Tr,QF({ref:e})).pipe(Ks())};var E0=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})},rk=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},wv;class JF{constructor(){this.defaultExpireTime=1*60*1e3,wv.set(this,[])}addConfigBuilder(e){rk(this,wv,"f").push(e)}_getServiceProvider(e){return E0(this,void 0,void 0,function*(){var t;if(e.hasModule("services"))return e.requireInstance("services");{const n=(t=e.ref)===null||t===void 0?void 0:t.services;if(n)return n;throw Error("no service services provider configures [ServicesModule]")}})}createConfig(e){return E0(this,void 0,void 0,function*(){var t,n;const i=yield rk(this,wv,"f").reduce((o,a)=>E0(this,void 0,void 0,function*(){const c=new GF(e,yield o);return yield Promise.resolve(a(c)),Object.assign(o,c.config)}),Promise.resolve({}));return(t=i.resolveInitialContext)!==null&&t!==void 0||(i.resolveInitialContext=XF()),(n=i.client)!==null&&n!==void 0||(i.client=yield E0(this,void 0,void 0,function*(){const a=yield(yield this._getServiceProvider(e)).createContextClient("json$");return{get:{client:{fn:c=>a.get("v1",c,{selector:zF})},key:({id:c})=>c,expire:this.defaultExpireTime},query:{client:{fn:c=>a.query("v1",{query:c},{selector:BF})},key:c=>JSON.stringify(c),expire:this.defaultExpireTime},related:{client:{fn:c=>a.related("v1",{id:c.item.id,query:{filter:c.filter}},{selector:UF})},key:c=>JSON.stringify(c),expire:this.defaultExpireTime}}})),i})}}wv=new WeakMap;var Z3,nk;function ej(){return nk||(nk=1,Z3=function r(e,t){if(e===t)return!0;if(e&&t&&typeof e=="object"&&typeof t=="object"){if(e.constructor!==t.constructor)return!1;var n,i,o;if(Array.isArray(e)){if(n=e.length,n!=t.length)return!1;for(i=n;i--!==0;)if(!r(e[i],t[i]))return!1;return!0}if(e.constructor===RegExp)return e.source===t.source&&e.flags===t.flags;if(e.valueOf!==Object.prototype.valueOf)return e.valueOf()===t.valueOf();if(e.toString!==Object.prototype.toString)return e.toString()===t.toString();if(o=Object.keys(e),n=o.length,n!==Object.keys(t).length)return!1;for(i=n;i--!==0;)if(!Object.prototype.hasOwnProperty.call(t,o[i]))return!1;for(i=n;i--!==0;){var a=o[i];if(!r(e[a],t[a]))return!1}return!0}return e!==e&&t!==t}),Z3}var tj=ej();const Nb=Hu(tj),rj=(...r)=>e=>e.pipe(_s(...r)),nj=(...r)=>e=>e.pipe(Jn(...r)),ij=(...r)=>e=>e.pipe(Wt(...r)),lf=r=>r.pipe(me(e=>e.value)),oj=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-8][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$/i;function aj(r){return typeof r=="string"&&oj.test(r)}function ik(r){if(!aj(r))throw TypeError("Invalid UUID");let e;return Uint8Array.of((e=parseInt(r.slice(0,8),16))>>>24,e>>>16&255,e>>>8&255,e&255,(e=parseInt(r.slice(9,13),16))>>>8,e&255,(e=parseInt(r.slice(14,18),16))>>>8,e&255,(e=parseInt(r.slice(19,23),16))>>>8,e&255,(e=parseInt(r.slice(24,36),16))/1099511627776&255,e/4294967296&255,e>>>24&255,e>>>16&255,e>>>8&255,e&255)}const Qn=[];for(let r=0;r<256;++r)Qn.push((r+256).toString(16).slice(1));function hP(r,e=0){return(Qn[r[e+0]]+Qn[r[e+1]]+Qn[r[e+2]]+Qn[r[e+3]]+"-"+Qn[r[e+4]]+Qn[r[e+5]]+"-"+Qn[r[e+6]]+Qn[r[e+7]]+"-"+Qn[r[e+8]]+Qn[r[e+9]]+"-"+Qn[r[e+10]]+Qn[r[e+11]]+Qn[r[e+12]]+Qn[r[e+13]]+Qn[r[e+14]]+Qn[r[e+15]]).toLowerCase()}let L3;const sj=new Uint8Array(16);function cj(){if(!L3){if(typeof crypto>"u"||!crypto.getRandomValues)throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");L3=crypto.getRandomValues.bind(crypto)}return L3(sj)}function lj(r){r=unescape(encodeURIComponent(r));const e=new Uint8Array(r.length);for(let t=0;t<r.length;++t)e[t]=r.charCodeAt(t);return e}const dj="6ba7b810-9dad-11d1-80b4-00c04fd430c8",uj="6ba7b811-9dad-11d1-80b4-00c04fd430c8";function hj(r,e,t,n,i,o){const a=typeof t=="string"?lj(t):t,c=typeof n=="string"?ik(n):n;if(typeof n=="string"&&(n=ik(n)),(n==null?void 0:n.length)!==16)throw TypeError("Namespace must be array-like (16 iterable integer values, 0-255)");let d=new Uint8Array(16+a.length);if(d.set(c),d.set(a,c.length),d=e(d),d[6]=d[6]&15|r,d[8]=d[8]&63|128,i){o=o||0;for(let h=0;h<16;++h)i[o+h]=d[h];return i}return hP(d)}const fj=typeof crypto<"u"&&crypto.randomUUID&&crypto.randomUUID.bind(crypto),ok={randomUUID:fj};function sm(r,e,t){var i;if(ok.randomUUID&&!r)return ok.randomUUID();r=r||{};const n=r.random??((i=r.rng)==null?void 0:i.call(r))??cj();if(n.length<16)throw new Error("Random bytes length must be >= 16");return n[6]=n[6]&15|64,n[8]=n[8]&63|128,hP(n)}function pj(r,e,t,n){switch(r){case 0:return e&t^~e&n;case 1:return e^t^n;case 2:return e&t^e&n^t&n;case 3:return e^t^n}}function H3(r,e){return r<<e|r>>>32-e}function mj(r){const e=[1518500249,1859775393,2400959708,3395469782],t=[1732584193,4023233417,2562383102,271733878,3285377520],n=new Uint8Array(r.length+1);n.set(r),n[r.length]=128,r=n;const i=r.length/4+2,o=Math.ceil(i/16),a=new Array(o);for(let c=0;c<o;++c){const d=new Uint32Array(16);for(let h=0;h<16;++h)d[h]=r[c*64+h*4]<<24|r[c*64+h*4+1]<<16|r[c*64+h*4+2]<<8|r[c*64+h*4+3];a[c]=d}a[o-1][14]=(r.length-1)*8/Math.pow(2,32),a[o-1][14]=Math.floor(a[o-1][14]),a[o-1][15]=(r.length-1)*8&4294967295;for(let c=0;c<o;++c){const d=new Uint32Array(80);for(let _=0;_<16;++_)d[_]=a[c][_];for(let _=16;_<80;++_)d[_]=H3(d[_-3]^d[_-8]^d[_-14]^d[_-16],1);let h=t[0],u=t[1],p=t[2],v=t[3],g=t[4];for(let _=0;_<80;++_){const b=Math.floor(_/20),C=H3(h,5)+pj(b,u,p,v)+g+e[b]+d[_]>>>0;g=v,v=p,p=H3(u,30)>>>0,u=h,h=C}t[0]=t[0]+h>>>0,t[1]=t[1]+u>>>0,t[2]=t[2]+p>>>0,t[3]=t[3]+v>>>0,t[4]=t[4]+g>>>0}return Uint8Array.of(t[0]>>24,t[0]>>16,t[0]>>8,t[0],t[1]>>24,t[1]>>16,t[1]>>8,t[1],t[2]>>24,t[2]>>16,t[2]>>8,t[2],t[3]>>24,t[3]>>16,t[3]>>8,t[3],t[4]>>24,t[4]>>16,t[4]>>8,t[4])}function L6(r,e,t,n){return hj(80,mj,r,e,t,n)}L6.DNS=dj;L6.URL=uj;class jd extends Error{constructor(e,t){super(t.message,{cause:t.cause}),this.type=e,this.name="QueryClientError",this.request=t.request}}function ea(r){for(var e=arguments.length,t=Array(e>1?e-1:0),n=1;n<e;n++)t[n-1]=arguments[n];throw Error("[Immer] minified error nr: "+r+(t.length?" "+t.map(function(i){return"'"+i+"'"}).join(","):"")+". Find the full error at: https://bit.ly/3cXEKWf")}function Cu(r){return!!r&&!!r[pr]}function Da(r){var e;return!!r&&(function(t){if(!t||typeof t!="object")return!1;var n=Object.getPrototypeOf(t);if(n===null)return!0;var i=Object.hasOwnProperty.call(n,"constructor")&&n.constructor;return i===Object||typeof i=="function"&&Function.toString.call(i)===Ej}(r)||Array.isArray(r)||!!r[hk]||!!(!((e=r.constructor)===null||e===void 0)&&e[hk])||H6(r)||N6(r))}function wf(r,e,t){t===void 0&&(t=!1),jf(r)===0?(t?Object.keys:z6)(r).forEach(function(n){t&&typeof n=="symbol"||e(n,r[n],r)}):r.forEach(function(n,i){return e(i,n,r)})}function jf(r){var e=r[pr];return e?e.i>3?e.i-4:e.i:Array.isArray(r)?1:H6(r)?2:N6(r)?3:0}function Db(r,e){return jf(r)===2?r.has(e):Object.prototype.hasOwnProperty.call(r,e)}function vj(r,e){return jf(r)===2?r.get(e):r[e]}function fP(r,e,t){var n=jf(r);n===2?r.set(e,t):n===3?r.add(t):r[e]=t}function gj(r,e){return r===e?r!==0||1/r==1/e:r!=r&&e!=e}function H6(r){return Cj&&r instanceof Map}function N6(r){return kj&&r instanceof Set}function Fn(r){return r.o||r.t}function D6(r){if(Array.isArray(r))return Array.prototype.slice.call(r);var e=Sj(r);delete e[pr];for(var t=z6(e),n=0;n<t.length;n++){var i=t[n],o=e[i];o.writable===!1&&(o.writable=!0,o.configurable=!0),(o.get||o.set)&&(e[i]={configurable:!0,writable:!0,enumerable:o.enumerable,value:r[i]})}return Object.create(Object.getPrototypeOf(r),e)}function V6(r,e){return e===void 0&&(e=!1),F6(r)||Cu(r)||!Da(r)||(jf(r)>1&&(r.set=r.add=r.clear=r.delete=yj),Object.freeze(r),e&&wf(r,function(t,n){return V6(n,!0)},!0)),r}function yj(){ea(2)}function F6(r){return r==null||typeof r!="object"||Object.isFrozen(r)}function ms(r){var e=Fb[r];return e||ea(18,r),e}function _j(r,e){Fb[r]||(Fb[r]=e)}function kg(){return lm}function N3(r,e){e&&(ms("Patches"),r.u=[],r.s=[],r.v=e)}function Eg(r){Vb(r),r.p.forEach(bj),r.p=null}function Vb(r){r===lm&&(lm=r.l)}function ak(r){return lm={p:[],l:lm,h:r,m:!0,_:0}}function bj(r){var e=r[pr];e.i===0||e.i===1?e.j():e.g=!0}function D3(r,e){e._=e.p.length;var t=e.p[0],n=r!==void 0&&r!==t;return e.h.O||ms("ES5").S(e,r,n),n?(t[pr].P&&(Eg(e),ea(4)),Da(r)&&(r=Sg(e,r),e.l||Tg(e,r)),e.u&&ms("Patches").M(t[pr].t,r,e.u,e.s)):r=Sg(e,t,[]),Eg(e),e.u&&e.v(e.u,e.s),r!==pP?r:void 0}function Sg(r,e,t){if(F6(e))return e;var n=e[pr];if(!n)return wf(e,function(c,d){return sk(r,n,e,c,d,t)},!0),e;if(n.A!==r)return e;if(!n.P)return Tg(r,n.t,!0),n.t;if(!n.I){n.I=!0,n.A._--;var i=n.i===4||n.i===5?n.o=D6(n.k):n.o,o=i,a=!1;n.i===3&&(o=new Set(i),i.clear(),a=!0),wf(o,function(c,d){return sk(r,n,i,c,d,t,a)}),Tg(r,i,!1),t&&r.u&&ms("Patches").N(n,t,r.u,r.s)}return n.o}function sk(r,e,t,n,i,o,a){if(Cu(i)){var c=Sg(r,i,o&&e&&e.i!==3&&!Db(e.R,n)?o.concat(n):void 0);if(fP(t,n,c),!Cu(c))return;r.m=!1}else a&&t.add(i);if(Da(i)&&!F6(i)){if(!r.h.D&&r._<1)return;Sg(r,i),e&&e.A.l||Tg(r,i)}}function Tg(r,e,t){t===void 0&&(t=!1),!r.l&&r.h.D&&r.m&&V6(e,t)}function V3(r,e){var t=r[pr];return(t?Fn(t):r)[e]}function ck(r,e){if(e in r)for(var t=Object.getPrototypeOf(r);t;){var n=Object.getOwnPropertyDescriptor(t,e);if(n)return n;t=Object.getPrototypeOf(t)}}function nc(r){r.P||(r.P=!0,r.l&&nc(r.l))}function F3(r){r.o||(r.o=D6(r.t))}function cm(r,e,t){var n=H6(e)?ms("MapSet").F(e,t):N6(e)?ms("MapSet").T(e,t):r.O?function(i,o){var a=Array.isArray(i),c={i:a?1:0,A:o?o.A:kg(),P:!1,I:!1,R:{},l:o,t:i,k:null,o:null,j:null,C:!1},d=c,h=jb;a&&(d=[c],h=lp);var u=Proxy.revocable(d,h),p=u.revoke,v=u.proxy;return c.k=v,c.j=p,v}(e,t):ms("ES5").J(e,t);return(t?t.A:kg()).p.push(n),n}function wj(r){return Cu(r)||ea(22,r),function e(t){if(!Da(t))return t;var n,i=t[pr],o=jf(t);if(i){if(!i.P&&(i.i<4||!ms("ES5").K(i)))return i.t;i.I=!0,n=lk(t,o),i.I=!1}else n=lk(t,o);return wf(n,function(a,c){i&&vj(i.t,a)===c||fP(n,a,e(c))}),o===3?new Set(n):n}(r)}function lk(r,e){switch(e){case 2:return new Map(r);case 3:return Array.from(r)}return D6(r)}function xj(){function r(c,d){function h(){this.constructor=c}i(c,d),c.prototype=(h.prototype=d.prototype,new h)}function e(c){c.o||(c.R=new Map,c.o=new Map(c.t))}function t(c){c.o||(c.o=new Set,c.t.forEach(function(d){if(Da(d)){var h=cm(c.A.h,d,c);c.p.set(d,h),c.o.add(h)}else c.o.add(d)}))}function n(c){c.g&&ea(3,JSON.stringify(Fn(c)))}var i=function(c,d){return(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(h,u){h.__proto__=u}||function(h,u){for(var p in u)u.hasOwnProperty(p)&&(h[p]=u[p])})(c,d)},o=function(){function c(h,u){return this[pr]={i:2,l:u,A:u?u.A:kg(),P:!1,I:!1,o:void 0,R:void 0,t:h,k:this,C:!1,g:!1},this}r(c,Map);var d=c.prototype;return Object.defineProperty(d,"size",{get:function(){return Fn(this[pr]).size}}),d.has=function(h){return Fn(this[pr]).has(h)},d.set=function(h,u){var p=this[pr];return n(p),Fn(p).has(h)&&Fn(p).get(h)===u||(e(p),nc(p),p.R.set(h,!0),p.o.set(h,u),p.R.set(h,!0)),this},d.delete=function(h){if(!this.has(h))return!1;var u=this[pr];return n(u),e(u),nc(u),u.t.has(h)?u.R.set(h,!1):u.R.delete(h),u.o.delete(h),!0},d.clear=function(){var h=this[pr];n(h),Fn(h).size&&(e(h),nc(h),h.R=new Map,wf(h.t,function(u){h.R.set(u,!1)}),h.o.clear())},d.forEach=function(h,u){var p=this;Fn(this[pr]).forEach(function(v,g){h.call(u,p.get(g),g,p)})},d.get=function(h){var u=this[pr];n(u);var p=Fn(u).get(h);if(u.I||!Da(p)||p!==u.t.get(h))return p;var v=cm(u.A.h,p,u);return e(u),u.o.set(h,v),v},d.keys=function(){return Fn(this[pr]).keys()},d.values=function(){var h,u=this,p=this.keys();return(h={})[S0]=function(){return u.values()},h.next=function(){var v=p.next();return v.done?v:{done:!1,value:u.get(v.value)}},h},d.entries=function(){var h,u=this,p=this.keys();return(h={})[S0]=function(){return u.entries()},h.next=function(){var v=p.next();if(v.done)return v;var g=u.get(v.value);return{done:!1,value:[v.value,g]}},h},d[S0]=function(){return this.entries()},c}(),a=function(){function c(h,u){return this[pr]={i:3,l:u,A:u?u.A:kg(),P:!1,I:!1,o:void 0,t:h,k:this,p:new Map,g:!1,C:!1},this}r(c,Set);var d=c.prototype;return Object.defineProperty(d,"size",{get:function(){return Fn(this[pr]).size}}),d.has=function(h){var u=this[pr];return n(u),u.o?!!u.o.has(h)||!(!u.p.has(h)||!u.o.has(u.p.get(h))):u.t.has(h)},d.add=function(h){var u=this[pr];return n(u),this.has(h)||(t(u),nc(u),u.o.add(h)),this},d.delete=function(h){if(!this.has(h))return!1;var u=this[pr];return n(u),t(u),nc(u),u.o.delete(h)||!!u.p.has(h)&&u.o.delete(u.p.get(h))},d.clear=function(){var h=this[pr];n(h),Fn(h).size&&(t(h),nc(h),h.o.clear())},d.values=function(){var h=this[pr];return n(h),t(h),h.o.values()},d.entries=function(){var h=this[pr];return n(h),t(h),h.o.entries()},d.keys=function(){return this.values()},d[S0]=function(){return this.values()},d.forEach=function(h,u){for(var p=this.values(),v=p.next();!v.done;)h.call(u,v.value,v.value,this),v=p.next()},c}();_j("MapSet",{F:function(c,d){return new o(c,d)},T:function(c,d){return new a(c,d)}})}var dk,lm,j6=typeof Symbol<"u"&&typeof Symbol("x")=="symbol",Cj=typeof Map<"u",kj=typeof Set<"u",uk=typeof Proxy<"u"&&Proxy.revocable!==void 0&&typeof Reflect<"u",pP=j6?Symbol.for("immer-nothing"):((dk={})["immer-nothing"]=!0,dk),hk=j6?Symbol.for("immer-draftable"):"__$immer_draftable",pr=j6?Symbol.for("immer-state"):"__$immer_state",S0=typeof Symbol<"u"&&Symbol.iterator||"@@iterator",Ej=""+Object.prototype.constructor,z6=typeof Reflect<"u"&&Reflect.ownKeys?Reflect.ownKeys:Object.getOwnPropertySymbols!==void 0?function(r){return Object.getOwnPropertyNames(r).concat(Object.getOwnPropertySymbols(r))}:Object.getOwnPropertyNames,Sj=Object.getOwnPropertyDescriptors||function(r){var e={};return z6(r).forEach(function(t){e[t]=Object.getOwnPropertyDescriptor(r,t)}),e},Fb={},jb={get:function(r,e){if(e===pr)return r;var t=Fn(r);if(!Db(t,e))return function(i,o,a){var c,d=ck(o,a);return d?"value"in d?d.value:(c=d.get)===null||c===void 0?void 0:c.call(i.k):void 0}(r,t,e);var n=t[e];return r.I||!Da(n)?n:n===V3(r.t,e)?(F3(r),r.o[e]=cm(r.A.h,n,r)):n},has:function(r,e){return e in Fn(r)},ownKeys:function(r){return Reflect.ownKeys(Fn(r))},set:function(r,e,t){var n=ck(Fn(r),e);if(n!=null&&n.set)return n.set.call(r.k,t),!0;if(!r.P){var i=V3(Fn(r),e),o=i==null?void 0:i[pr];if(o&&o.t===t)return r.o[e]=t,r.R[e]=!1,!0;if(gj(t,i)&&(t!==void 0||Db(r.t,e)))return!0;F3(r),nc(r)}return r.o[e]===t&&(t!==void 0||e in r.o)||Number.isNaN(t)&&Number.isNaN(r.o[e])||(r.o[e]=t,r.R[e]=!0),!0},deleteProperty:function(r,e){return V3(r.t,e)!==void 0||e in r.t?(r.R[e]=!1,F3(r),nc(r)):delete r.R[e],r.o&&delete r.o[e],!0},getOwnPropertyDescriptor:function(r,e){var t=Fn(r),n=Reflect.getOwnPropertyDescriptor(t,e);return n&&{writable:!0,configurable:r.i!==1||e!=="length",enumerable:n.enumerable,value:t[e]}},defineProperty:function(){ea(11)},getPrototypeOf:function(r){return Object.getPrototypeOf(r.t)},setPrototypeOf:function(){ea(12)}},lp={};wf(jb,function(r,e){lp[r]=function(){return arguments[0]=arguments[0][0],e.apply(this,arguments)}}),lp.deleteProperty=function(r,e){return lp.set.call(this,r,e,void 0)},lp.set=function(r,e,t){return jb.set.call(this,r[0],e,t,r[0])};var Tj=function(){function r(t){var n=this;this.O=uk,this.D=!0,this.produce=function(i,o,a){if(typeof i=="function"&&typeof o!="function"){var c=o;o=i;var d=n;return function(b){var C=this;b===void 0&&(b=c);for(var T=arguments.length,S=Array(T>1?T-1:0),A=1;A<T;A++)S[A-1]=arguments[A];return d.produce(b,function(Z){var B;return(B=o).call.apply(B,[C,Z].concat(S))})}}var h;if(typeof o!="function"&&ea(6),a!==void 0&&typeof a!="function"&&ea(7),Da(i)){var u=ak(n),p=cm(n,i,void 0),v=!0;try{h=o(p),v=!1}finally{v?Eg(u):Vb(u)}return typeof Promise<"u"&&h instanceof Promise?h.then(function(b){return N3(u,a),D3(b,u)},function(b){throw Eg(u),b}):(N3(u,a),D3(h,u))}if(!i||typeof i!="object"){if((h=o(i))===void 0&&(h=i),h===pP&&(h=void 0),n.D&&V6(h,!0),a){var g=[],_=[];ms("Patches").M(i,h,g,_),a(g,_)}return h}ea(21,i)},this.produceWithPatches=function(i,o){if(typeof i=="function")return function(h){for(var u=arguments.length,p=Array(u>1?u-1:0),v=1;v<u;v++)p[v-1]=arguments[v];return n.produceWithPatches(h,function(g){return i.apply(void 0,[g].concat(p))})};var a,c,d=n.produce(i,o,function(h,u){a=h,c=u});return typeof Promise<"u"&&d instanceof Promise?d.then(function(h){return[h,a,c]}):[d,a,c]},typeof(t==null?void 0:t.useProxies)=="boolean"&&this.setUseProxies(t.useProxies),typeof(t==null?void 0:t.autoFreeze)=="boolean"&&this.setAutoFreeze(t.autoFreeze)}var e=r.prototype;return e.createDraft=function(t){Da(t)||ea(8),Cu(t)&&(t=wj(t));var n=ak(this),i=cm(this,t,void 0);return i[pr].C=!0,Vb(n),i},e.finishDraft=function(t,n){var i=t&&t[pr],o=i.A;return N3(o,n),D3(void 0,o)},e.setAutoFreeze=function(t){this.D=t},e.setUseProxies=function(t){t&&!uk&&ea(20),this.O=t},e.applyPatches=function(t,n){var i;for(i=n.length-1;i>=0;i--){var o=n[i];if(o.path.length===0&&o.op==="replace"){t=o.value;break}}i>-1&&(n=n.slice(i+1));var a=ms("Patches").$;return Cu(t)?a(t,n):this.produce(t,function(c){return a(c,n)})},r}(),So=new Tj,B6=So.produce;So.produceWithPatches.bind(So);So.setAutoFreeze.bind(So);So.setUseProxies.bind(So);So.applyPatches.bind(So);So.createDraft.bind(So);So.finishDraft.bind(So);const dm=(...r)=>$e(e=>r.includes(e.type));var Kn=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},Aj=function(r,e,t,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?r!==e||!i:!e.has(r))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(r,t):i?i.value=t:e.set(r,t),t},ns,Ko;class Lm extends Tt{get action$(){return Kn(this,ns,"f").asObservable()}get value(){return Kn(this,Ko,"f").value}get closed(){return Kn(this,Ko,"f").closed||Kn(this,ns,"f").closed}constructor(e,t){super(i=>Kn(this,Ko,"f").subscribe(i)),ns.set(this,new Bn),Ko.set(this,void 0);const n="getInitialState"in e?e.getInitialState():t;Aj(this,Ko,new Df(n),"f"),Kn(this,ns,"f").pipe(jN(e,n),rg()).subscribe(Kn(this,Ko,"f")),this.reset=()=>Kn(this,Ko,"f").next(n)}next(e){Kn(this,ns,"f").next(e)}select(e,t){return Kn(this,Ko,"f").pipe(me(e),rg(t))}addEffect(e,t){const n=typeof e=="function"?this.action$:Array.isArray(e)?this.action$.pipe(dm(...e)):this.action$.pipe(dm(e)),i=t||e;return n.pipe(Jn(o=>rt(new Promise((a,c)=>{try{a(i(o,this.value))}catch(d){c(d)}})).pipe(Vt(a=>(console.warn("unhandled effect",a),Tr)))),$e(o=>!!o),tg(ff)).subscribe(Kn(this,ns,"f"))}addEpic(e){return this.addFlow(e)}addFlow(e){const t=e(this.action$,this);if(!t)throw new TypeError(`addEpic: one of the provided effects "${e.name||"<anonymous>"}" does not return a stream. Double check you're not missing a return statement!`);return t.pipe(Vt(n=>(console.trace("unhandled exception, epic closed!",n),Tr)),tg(ff)).subscribe(Kn(this,ns,"f"))}unsubscribe(){Kn(this,ns,"f").unsubscribe(),Kn(this,Ko,"f").unsubscribe()}complete(){Kn(this,ns,"f").complete(),Kn(this,Ko,"f").complete()}asObservable(){return Kn(this,Ko,"f").asObservable()}}ns=new WeakMap,Ko=new WeakMap;function on(r,e){function t(...n){if(e){const i=e(...n);if(!i)throw new Error("prepareAction did not return an object");return Object.assign(Object.assign({type:r,payload:i.payload},"meta"in i&&{meta:i.meta}),"error"in i&&{error:i.error})}return{type:r,payload:n[0]}}return t.toString=()=>`${r}`,t.type=r,t.match=n=>n.type===r,t}const xv="::",mP=r=>new RegExp(`${xv}${r}$`);function Ag(r){return r.replace(mP("\\w+$"),"")}function vi(r,e,t,n){const i=on([r,"request"].join(xv),e);return t&&Object.assign(i,{success:on([r,"success"].join(xv),t)}),n&&Object.assign(i,{failure:on([r,"failure"].join(xv),n)}),i}function U6(r,e){return!!r.type.match(mP(e))}const vP=r=>U6(r,"request"),gP=r=>U6(r,"success"),q6=r=>U6(r,"failure"),yP=r=>gP(r)||q6(r);function fk(r){return Da(r)?B6(r,()=>{}):r}function Ij(r){return typeof r=="function"}function Hm(r,e){const[t,n,i]=Rj(e);let o;if(Ij(r))o=()=>fk(r());else{const c=fk(r);o=()=>c}function a(c=o(),d){let h=[t[d.type],...n.filter(({matcher:u})=>u(d)).map(({reducer:u})=>u)];return h.filter(u=>!!u).length===0&&(h=[i]),h.reduce((u,p)=>{if(p)if(Cu(u)){const g=p(u,d);return g===void 0?u:g}else{if(Da(u))return B6(u,v=>p(v,d));{const v=p(u,d);if(v===void 0){if(u===null)return u;throw Error("A case reducer on a non-draftable value must not return undefined")}return v}}return u},c)}return a.getInitialState=o,a}function Rj(r){const e={},t=[];let n;const i={addCase(o,a){const c=typeof o=="string"?o:o.type;if(c in e)throw new Error("addCase cannot be called with two reducers for the same action type");return e[c]=a,i},addMatcher(o,a){return t.push({matcher:o,reducer:a}),i},addDefaultCase(o){return n=o,i}};return r(i),[e,t,n]}const Pj=()=>({request:on("client/request",(r,e)=>({payload:{args:r,options:e},meta:{transaction:sm(),created:Date.now()}})),execute:vi("client/execute",r=>({payload:r,meta:{transaction:r,created:Date.now()}}),r=>({payload:r,meta:{transaction:r.transaction,created:Date.now()}}),(r,e)=>({payload:r,meta:{transaction:e,created:Date.now()}})),cancel:on("client/cancel",(r,e)=>({payload:{transaction:r,reason:e},meta:{transaction:r,created:Date.now()}})),error:on("client/error",(r,e)=>({payload:{transaction:r,error:e},meta:{transaction:r,created:Date.now()}}))}),ir=Pj(),Mj=r=>r.pipe($e(ir.request.match),me(e=>ir.execute(e.meta.transaction))),$j=r=>(e,t)=>e.pipe($e(ir.execute.match),Up(t),Jn(([n,i])=>{const o=n.payload,a=i[o],c=new AbortController,d=e.pipe($e(ir.cancel.match),$e(h=>h.payload.transaction===o),Br(()=>{c.signal.aborted||c.abort()}));try{return rt(r(a.args,c.signal)).pipe(me(h=>ir.execute.success(Object.assign(Object.assign({},a),{status:"complete",completed:Date.now(),value:h}))),Vt(h=>It(ir.execute.failure(h,o))),ou(d))}catch(h){return It(ir.execute.failure(h,o))}})),Oj=r=>(e,t)=>e.pipe($e(ir.execute.failure.match),Up(t),Jn(([n,i])=>{var o,a,c;const{transaction:d}=n.meta,h=i[d];if(!h)return It(ir.error(d,new jd("error",{message:"request not found, cannot retry request, most likely removed while scheduled for retry!"})));const u=h.execution.length,p=Object.assign({},r,(o=h.options)===null||o===void 0?void 0:o.retry),v=(c=(a=h.errors)===null||a===void 0?void 0:a.slice(-1)[0])!==null&&c!==void 0?c:new jd("error",{message:"no errors registered for request!",request:h});if(u>p.count){const _=p.count===0?v:new jd("error",{message:"maximum retries executed!",cause:h.errors,request:h});return It(ir.error(d,_))}return(typeof p.delay=="function"?rt(p.delay(v)).pipe(Vt(_=>{var b;return It(ir.error(d,new jd("error",{message:"retry delay callback failed!",cause:[...(b=h.errors)!==null&&b!==void 0?b:[],_],request:h})))})):w6(p.delay)).pipe(Up(t),$e(([_,b])=>!!b[d]),Br(([,_])=>{if(!_[d])throw new jd("error",{message:"request not found, most likely removed while scheduled for retry",cause:h.errors,request:h})}),me(()=>ir.execute(d)))})),Zj=(r={})=>Hm(r,e=>{e.addCase(ir.request,(t,n)=>{t[n.meta.transaction]=Object.assign(Object.assign(Object.assign({},n.payload),n.meta),{execution:[],errors:[],status:"idle"})}),e.addCase(ir.execute,(t,n)=>{const i=t[n.payload];i&&(i.execution.push(Date.now()),i.status="active")}),e.addCase(ir.execute.success,(t,n)=>{delete t[n.payload.transaction]}),e.addCase(ir.execute.failure,(t,n)=>{const i=t[n.meta.transaction];i&&(i.errors.push(n.payload),i.status="failed")}),e.addCase(ir.error,(t,n)=>{delete t[n.meta.transaction]}),e.addCase(ir.cancel,(t,n)=>{delete t[n.meta.transaction]})}),j3=10,pk=(r=0)=>e=>`\x1B[${e+r}m`,mk=(r=0)=>e=>`\x1B[${38+r};5;${e}m`,vk=(r=0)=>(e,t,n)=>`\x1B[${38+r};2;${e};${t};${n}m`,jr={modifier:{reset:[0,0],bold:[1,22],dim:[2,22],italic:[3,23],underline:[4,24],overline:[53,55],inverse:[7,27],hidden:[8,28],strikethrough:[9,29]},color:{black:[30,39],red:[31,39],green:[32,39],yellow:[33,39],blue:[34,39],magenta:[35,39],cyan:[36,39],white:[37,39],blackBright:[90,39],gray:[90,39],grey:[90,39],redBright:[91,39],greenBright:[92,39],yellowBright:[93,39],blueBright:[94,39],magentaBright:[95,39],cyanBright:[96,39],whiteBright:[97,39]},bgColor:{bgBlack:[40,49],bgRed:[41,49],bgGreen:[42,49],bgYellow:[43,49],bgBlue:[44,49],bgMagenta:[45,49],bgCyan:[46,49],bgWhite:[47,49],bgBlackBright:[100,49],bgGray:[100,49],bgGrey:[100,49],bgRedBright:[101,49],bgGreenBright:[102,49],bgYellowBright:[103,49],bgBlueBright:[104,49],bgMagentaBright:[105,49],bgCyanBright:[106,49],bgWhiteBright:[107,49]}};Object.keys(jr.modifier);const Lj=Object.keys(jr.color),Hj=Object.keys(jr.bgColor);[...Lj,...Hj];function Nj(){const r=new Map;for(const[e,t]of Object.entries(jr)){for(const[n,i]of Object.entries(t))jr[n]={open:`\x1B[${i[0]}m`,close:`\x1B[${i[1]}m`},t[n]=jr[n],r.set(i[0],i[1]);Object.defineProperty(jr,e,{value:t,enumerable:!1})}return Object.defineProperty(jr,"codes",{value:r,enumerable:!1}),jr.color.close="\x1B[39m",jr.bgColor.close="\x1B[49m",jr.color.ansi=pk(),jr.color.ansi256=mk(),jr.color.ansi16m=vk(),jr.bgColor.ansi=pk(j3),jr.bgColor.ansi256=mk(j3),jr.bgColor.ansi16m=vk(j3),Object.defineProperties(jr,{rgbToAnsi256:{value(e,t,n){return e===t&&t===n?e<8?16:e>248?231:Math.round((e-8)/247*24)+232:16+36*Math.round(e/255*5)+6*Math.round(t/255*5)+Math.round(n/255*5)},enumerable:!1},hexToRgb:{value(e){const t=/[a-f\d]{6}|[a-f\d]{3}/i.exec(e.toString(16));if(!t)return[0,0,0];let[n]=t;n.length===3&&(n=[...n].map(o=>o+o).join(""));const i=Number.parseInt(n,16);return[i>>16&255,i>>8&255,i&255]},enumerable:!1},hexToAnsi256:{value:e=>jr.rgbToAnsi256(...jr.hexToRgb(e)),enumerable:!1},ansi256ToAnsi:{value(e){if(e<8)return 30+e;if(e<16)return 90+(e-8);let t,n,i;if(e>=232)t=((e-232)*10+8)/255,n=t,i=t;else{e-=16;const c=e%36;t=Math.floor(e/36)/5,n=Math.floor(c/6)/5,i=c%6/5}const o=Math.max(t,n,i)*2;if(o===0)return 30;let a=30+(Math.round(i)<<2|Math.round(n)<<1|Math.round(t));return o===2&&(a+=60),a},enumerable:!1},rgbToAnsi:{value:(e,t,n)=>jr.ansi256ToAnsi(jr.rgbToAnsi256(e,t,n)),enumerable:!1},hexToAnsi:{value:e=>jr.ansi256ToAnsi(jr.hexToAnsi256(e)),enumerable:!1}}),jr}const cs=Nj(),gk=(()=>{if(navigator.userAgentData){const r=navigator.userAgentData.brands.find(({brand:e})=>e==="Chromium");if(r&&r.version>93)return 3}return/\b(Chrome|Chromium)\//.test(navigator.userAgent)?1:0})(),yk=gk!==0&&{level:gk},Dj={stdout:yk,stderr:yk};function Vj(r,e,t){let n=r.indexOf(e);if(n===-1)return r;const i=e.length;let o=0,a="";do a+=r.slice(o,n)+e+t,o=n+i,n=r.indexOf(e,o);while(n!==-1);return a+=r.slice(o),a}function Fj(r,e,t,n){let i=0,o="";do{const a=r[n-1]==="\r";o+=r.slice(i,a?n-1:n)+e+(a?`\r
74
+ `));return e.currentContext?It(e.currentContext):Tr},XF=r=>({ref:e,modules:t})=>{var n,i;const{context:o,navigation:a}=t,c=YF(o),d=(n=a==null?void 0:a.path.pathname)!==null&&n!==void 0?n:(i=e.navigation)===null||i===void 0?void 0:i.path.pathname;return xl(d?c(d):Tr,QF({ref:e})).pipe(Ks())};var E0=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})},rk=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},wv;class JF{constructor(){this.defaultExpireTime=1*60*1e3,wv.set(this,[])}addConfigBuilder(e){rk(this,wv,"f").push(e)}_getServiceProvider(e){return E0(this,void 0,void 0,function*(){var t;if(e.hasModule("services"))return e.requireInstance("services");{const n=(t=e.ref)===null||t===void 0?void 0:t.services;if(n)return n;throw Error("no service services provider configures [ServicesModule]")}})}createConfig(e){return E0(this,void 0,void 0,function*(){var t,n;const i=yield rk(this,wv,"f").reduce((o,a)=>E0(this,void 0,void 0,function*(){const c=new GF(e,yield o);return yield Promise.resolve(a(c)),Object.assign(o,c.config)}),Promise.resolve({}));return(t=i.resolveInitialContext)!==null&&t!==void 0||(i.resolveInitialContext=XF()),(n=i.client)!==null&&n!==void 0||(i.client=yield E0(this,void 0,void 0,function*(){const a=yield(yield this._getServiceProvider(e)).createContextClient("json$");return{get:{client:{fn:c=>a.get("v1",c,{selector:zF})},key:({id:c})=>c,expire:this.defaultExpireTime},query:{client:{fn:c=>a.query("v1",{query:c},{selector:BF})},key:c=>JSON.stringify(c),expire:this.defaultExpireTime},related:{client:{fn:c=>a.related("v1",{id:c.item.id,query:{filter:c.filter}},{selector:UF})},key:c=>JSON.stringify(c),expire:this.defaultExpireTime}}})),i})}}wv=new WeakMap;var Z3,nk;function ej(){return nk||(nk=1,Z3=function r(e,t){if(e===t)return!0;if(e&&t&&typeof e=="object"&&typeof t=="object"){if(e.constructor!==t.constructor)return!1;var n,i,o;if(Array.isArray(e)){if(n=e.length,n!=t.length)return!1;for(i=n;i--!==0;)if(!r(e[i],t[i]))return!1;return!0}if(e.constructor===RegExp)return e.source===t.source&&e.flags===t.flags;if(e.valueOf!==Object.prototype.valueOf)return e.valueOf()===t.valueOf();if(e.toString!==Object.prototype.toString)return e.toString()===t.toString();if(o=Object.keys(e),n=o.length,n!==Object.keys(t).length)return!1;for(i=n;i--!==0;)if(!Object.prototype.hasOwnProperty.call(t,o[i]))return!1;for(i=n;i--!==0;){var a=o[i];if(!r(e[a],t[a]))return!1}return!0}return e!==e&&t!==t}),Z3}var tj=ej();const Nb=Hu(tj),rj=(...r)=>e=>e.pipe(_s(...r)),nj=(...r)=>e=>e.pipe(Jn(...r)),ij=(...r)=>e=>e.pipe(Wt(...r)),lf=r=>r.pipe(me(e=>e.value)),oj=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-8][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$/i;function aj(r){return typeof r=="string"&&oj.test(r)}function ik(r){if(!aj(r))throw TypeError("Invalid UUID");let e;return Uint8Array.of((e=parseInt(r.slice(0,8),16))>>>24,e>>>16&255,e>>>8&255,e&255,(e=parseInt(r.slice(9,13),16))>>>8,e&255,(e=parseInt(r.slice(14,18),16))>>>8,e&255,(e=parseInt(r.slice(19,23),16))>>>8,e&255,(e=parseInt(r.slice(24,36),16))/1099511627776&255,e/4294967296&255,e>>>24&255,e>>>16&255,e>>>8&255,e&255)}const Qn=[];for(let r=0;r<256;++r)Qn.push((r+256).toString(16).slice(1));function hP(r,e=0){return(Qn[r[e+0]]+Qn[r[e+1]]+Qn[r[e+2]]+Qn[r[e+3]]+"-"+Qn[r[e+4]]+Qn[r[e+5]]+"-"+Qn[r[e+6]]+Qn[r[e+7]]+"-"+Qn[r[e+8]]+Qn[r[e+9]]+"-"+Qn[r[e+10]]+Qn[r[e+11]]+Qn[r[e+12]]+Qn[r[e+13]]+Qn[r[e+14]]+Qn[r[e+15]]).toLowerCase()}let L3;const sj=new Uint8Array(16);function cj(){if(!L3){if(typeof crypto>"u"||!crypto.getRandomValues)throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");L3=crypto.getRandomValues.bind(crypto)}return L3(sj)}function lj(r){r=unescape(encodeURIComponent(r));const e=new Uint8Array(r.length);for(let t=0;t<r.length;++t)e[t]=r.charCodeAt(t);return e}const dj="6ba7b810-9dad-11d1-80b4-00c04fd430c8",uj="6ba7b811-9dad-11d1-80b4-00c04fd430c8";function hj(r,e,t,n,i,o){const a=typeof t=="string"?lj(t):t,c=typeof n=="string"?ik(n):n;if(typeof n=="string"&&(n=ik(n)),(n==null?void 0:n.length)!==16)throw TypeError("Namespace must be array-like (16 iterable integer values, 0-255)");let d=new Uint8Array(16+a.length);if(d.set(c),d.set(a,c.length),d=e(d),d[6]=d[6]&15|r,d[8]=d[8]&63|128,i){o=o||0;for(let h=0;h<16;++h)i[o+h]=d[h];return i}return hP(d)}const fj=typeof crypto<"u"&&crypto.randomUUID&&crypto.randomUUID.bind(crypto),ok={randomUUID:fj};function sm(r,e,t){var i;if(ok.randomUUID&&!r)return ok.randomUUID();r=r||{};const n=r.random??((i=r.rng)==null?void 0:i.call(r))??cj();if(n.length<16)throw new Error("Random bytes length must be >= 16");return n[6]=n[6]&15|64,n[8]=n[8]&63|128,hP(n)}function pj(r,e,t,n){switch(r){case 0:return e&t^~e&n;case 1:return e^t^n;case 2:return e&t^e&n^t&n;case 3:return e^t^n}}function H3(r,e){return r<<e|r>>>32-e}function mj(r){const e=[1518500249,1859775393,2400959708,3395469782],t=[1732584193,4023233417,2562383102,271733878,3285377520],n=new Uint8Array(r.length+1);n.set(r),n[r.length]=128,r=n;const i=r.length/4+2,o=Math.ceil(i/16),a=new Array(o);for(let c=0;c<o;++c){const d=new Uint32Array(16);for(let h=0;h<16;++h)d[h]=r[c*64+h*4]<<24|r[c*64+h*4+1]<<16|r[c*64+h*4+2]<<8|r[c*64+h*4+3];a[c]=d}a[o-1][14]=(r.length-1)*8/Math.pow(2,32),a[o-1][14]=Math.floor(a[o-1][14]),a[o-1][15]=(r.length-1)*8&4294967295;for(let c=0;c<o;++c){const d=new Uint32Array(80);for(let _=0;_<16;++_)d[_]=a[c][_];for(let _=16;_<80;++_)d[_]=H3(d[_-3]^d[_-8]^d[_-14]^d[_-16],1);let h=t[0],u=t[1],p=t[2],v=t[3],g=t[4];for(let _=0;_<80;++_){const b=Math.floor(_/20),C=H3(h,5)+pj(b,u,p,v)+g+e[b]+d[_]>>>0;g=v,v=p,p=H3(u,30)>>>0,u=h,h=C}t[0]=t[0]+h>>>0,t[1]=t[1]+u>>>0,t[2]=t[2]+p>>>0,t[3]=t[3]+v>>>0,t[4]=t[4]+g>>>0}return Uint8Array.of(t[0]>>24,t[0]>>16,t[0]>>8,t[0],t[1]>>24,t[1]>>16,t[1]>>8,t[1],t[2]>>24,t[2]>>16,t[2]>>8,t[2],t[3]>>24,t[3]>>16,t[3]>>8,t[3],t[4]>>24,t[4]>>16,t[4]>>8,t[4])}function L6(r,e,t,n){return hj(80,mj,r,e,t,n)}L6.DNS=dj;L6.URL=uj;class jd extends Error{constructor(e,t){super(t.message,{cause:t.cause}),this.type=e,this.name="QueryClientError",this.request=t.request}}function ea(r){for(var e=arguments.length,t=Array(e>1?e-1:0),n=1;n<e;n++)t[n-1]=arguments[n];throw Error("[Immer] minified error nr: "+r+(t.length?" "+t.map(function(i){return"'"+i+"'"}).join(","):"")+". Find the full error at: https://bit.ly/3cXEKWf")}function Cu(r){return!!r&&!!r[pr]}function Da(r){var e;return!!r&&(function(t){if(!t||typeof t!="object")return!1;var n=Object.getPrototypeOf(t);if(n===null)return!0;var i=Object.hasOwnProperty.call(n,"constructor")&&n.constructor;return i===Object||typeof i=="function"&&Function.toString.call(i)===Ej}(r)||Array.isArray(r)||!!r[hk]||!!(!((e=r.constructor)===null||e===void 0)&&e[hk])||H6(r)||N6(r))}function wf(r,e,t){t===void 0&&(t=!1),jf(r)===0?(t?Object.keys:z6)(r).forEach(function(n){t&&typeof n=="symbol"||e(n,r[n],r)}):r.forEach(function(n,i){return e(i,n,r)})}function jf(r){var e=r[pr];return e?e.i>3?e.i-4:e.i:Array.isArray(r)?1:H6(r)?2:N6(r)?3:0}function Db(r,e){return jf(r)===2?r.has(e):Object.prototype.hasOwnProperty.call(r,e)}function vj(r,e){return jf(r)===2?r.get(e):r[e]}function fP(r,e,t){var n=jf(r);n===2?r.set(e,t):n===3?r.add(t):r[e]=t}function gj(r,e){return r===e?r!==0||1/r==1/e:r!=r&&e!=e}function H6(r){return Cj&&r instanceof Map}function N6(r){return kj&&r instanceof Set}function Fn(r){return r.o||r.t}function D6(r){if(Array.isArray(r))return Array.prototype.slice.call(r);var e=Sj(r);delete e[pr];for(var t=z6(e),n=0;n<t.length;n++){var i=t[n],o=e[i];o.writable===!1&&(o.writable=!0,o.configurable=!0),(o.get||o.set)&&(e[i]={configurable:!0,writable:!0,enumerable:o.enumerable,value:r[i]})}return Object.create(Object.getPrototypeOf(r),e)}function V6(r,e){return e===void 0&&(e=!1),F6(r)||Cu(r)||!Da(r)||(jf(r)>1&&(r.set=r.add=r.clear=r.delete=yj),Object.freeze(r),e&&wf(r,function(t,n){return V6(n,!0)},!0)),r}function yj(){ea(2)}function F6(r){return r==null||typeof r!="object"||Object.isFrozen(r)}function ms(r){var e=Fb[r];return e||ea(18,r),e}function _j(r,e){Fb[r]||(Fb[r]=e)}function kg(){return lm}function N3(r,e){e&&(ms("Patches"),r.u=[],r.s=[],r.v=e)}function Eg(r){Vb(r),r.p.forEach(bj),r.p=null}function Vb(r){r===lm&&(lm=r.l)}function ak(r){return lm={p:[],l:lm,h:r,m:!0,_:0}}function bj(r){var e=r[pr];e.i===0||e.i===1?e.j():e.g=!0}function D3(r,e){e._=e.p.length;var t=e.p[0],n=r!==void 0&&r!==t;return e.h.O||ms("ES5").S(e,r,n),n?(t[pr].P&&(Eg(e),ea(4)),Da(r)&&(r=Sg(e,r),e.l||Tg(e,r)),e.u&&ms("Patches").M(t[pr].t,r,e.u,e.s)):r=Sg(e,t,[]),Eg(e),e.u&&e.v(e.u,e.s),r!==pP?r:void 0}function Sg(r,e,t){if(F6(e))return e;var n=e[pr];if(!n)return wf(e,function(c,d){return sk(r,n,e,c,d,t)},!0),e;if(n.A!==r)return e;if(!n.P)return Tg(r,n.t,!0),n.t;if(!n.I){n.I=!0,n.A._--;var i=n.i===4||n.i===5?n.o=D6(n.k):n.o,o=i,a=!1;n.i===3&&(o=new Set(i),i.clear(),a=!0),wf(o,function(c,d){return sk(r,n,i,c,d,t,a)}),Tg(r,i,!1),t&&r.u&&ms("Patches").N(n,t,r.u,r.s)}return n.o}function sk(r,e,t,n,i,o,a){if(Cu(i)){var c=Sg(r,i,o&&e&&e.i!==3&&!Db(e.R,n)?o.concat(n):void 0);if(fP(t,n,c),!Cu(c))return;r.m=!1}else a&&t.add(i);if(Da(i)&&!F6(i)){if(!r.h.D&&r._<1)return;Sg(r,i),e&&e.A.l||Tg(r,i)}}function Tg(r,e,t){t===void 0&&(t=!1),!r.l&&r.h.D&&r.m&&V6(e,t)}function V3(r,e){var t=r[pr];return(t?Fn(t):r)[e]}function ck(r,e){if(e in r)for(var t=Object.getPrototypeOf(r);t;){var n=Object.getOwnPropertyDescriptor(t,e);if(n)return n;t=Object.getPrototypeOf(t)}}function nc(r){r.P||(r.P=!0,r.l&&nc(r.l))}function F3(r){r.o||(r.o=D6(r.t))}function cm(r,e,t){var n=H6(e)?ms("MapSet").F(e,t):N6(e)?ms("MapSet").T(e,t):r.O?function(i,o){var a=Array.isArray(i),c={i:a?1:0,A:o?o.A:kg(),P:!1,I:!1,R:{},l:o,t:i,k:null,o:null,j:null,C:!1},d=c,h=jb;a&&(d=[c],h=lp);var u=Proxy.revocable(d,h),p=u.revoke,v=u.proxy;return c.k=v,c.j=p,v}(e,t):ms("ES5").J(e,t);return(t?t.A:kg()).p.push(n),n}function wj(r){return Cu(r)||ea(22,r),function e(t){if(!Da(t))return t;var n,i=t[pr],o=jf(t);if(i){if(!i.P&&(i.i<4||!ms("ES5").K(i)))return i.t;i.I=!0,n=lk(t,o),i.I=!1}else n=lk(t,o);return wf(n,function(a,c){i&&vj(i.t,a)===c||fP(n,a,e(c))}),o===3?new Set(n):n}(r)}function lk(r,e){switch(e){case 2:return new Map(r);case 3:return Array.from(r)}return D6(r)}function xj(){function r(c,d){function h(){this.constructor=c}i(c,d),c.prototype=(h.prototype=d.prototype,new h)}function e(c){c.o||(c.R=new Map,c.o=new Map(c.t))}function t(c){c.o||(c.o=new Set,c.t.forEach(function(d){if(Da(d)){var h=cm(c.A.h,d,c);c.p.set(d,h),c.o.add(h)}else c.o.add(d)}))}function n(c){c.g&&ea(3,JSON.stringify(Fn(c)))}var i=function(c,d){return(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(h,u){h.__proto__=u}||function(h,u){for(var p in u)u.hasOwnProperty(p)&&(h[p]=u[p])})(c,d)},o=function(){function c(h,u){return this[pr]={i:2,l:u,A:u?u.A:kg(),P:!1,I:!1,o:void 0,R:void 0,t:h,k:this,C:!1,g:!1},this}r(c,Map);var d=c.prototype;return Object.defineProperty(d,"size",{get:function(){return Fn(this[pr]).size}}),d.has=function(h){return Fn(this[pr]).has(h)},d.set=function(h,u){var p=this[pr];return n(p),Fn(p).has(h)&&Fn(p).get(h)===u||(e(p),nc(p),p.R.set(h,!0),p.o.set(h,u),p.R.set(h,!0)),this},d.delete=function(h){if(!this.has(h))return!1;var u=this[pr];return n(u),e(u),nc(u),u.t.has(h)?u.R.set(h,!1):u.R.delete(h),u.o.delete(h),!0},d.clear=function(){var h=this[pr];n(h),Fn(h).size&&(e(h),nc(h),h.R=new Map,wf(h.t,function(u){h.R.set(u,!1)}),h.o.clear())},d.forEach=function(h,u){var p=this;Fn(this[pr]).forEach(function(v,g){h.call(u,p.get(g),g,p)})},d.get=function(h){var u=this[pr];n(u);var p=Fn(u).get(h);if(u.I||!Da(p)||p!==u.t.get(h))return p;var v=cm(u.A.h,p,u);return e(u),u.o.set(h,v),v},d.keys=function(){return Fn(this[pr]).keys()},d.values=function(){var h,u=this,p=this.keys();return(h={})[S0]=function(){return u.values()},h.next=function(){var v=p.next();return v.done?v:{done:!1,value:u.get(v.value)}},h},d.entries=function(){var h,u=this,p=this.keys();return(h={})[S0]=function(){return u.entries()},h.next=function(){var v=p.next();if(v.done)return v;var g=u.get(v.value);return{done:!1,value:[v.value,g]}},h},d[S0]=function(){return this.entries()},c}(),a=function(){function c(h,u){return this[pr]={i:3,l:u,A:u?u.A:kg(),P:!1,I:!1,o:void 0,t:h,k:this,p:new Map,g:!1,C:!1},this}r(c,Set);var d=c.prototype;return Object.defineProperty(d,"size",{get:function(){return Fn(this[pr]).size}}),d.has=function(h){var u=this[pr];return n(u),u.o?!!u.o.has(h)||!(!u.p.has(h)||!u.o.has(u.p.get(h))):u.t.has(h)},d.add=function(h){var u=this[pr];return n(u),this.has(h)||(t(u),nc(u),u.o.add(h)),this},d.delete=function(h){if(!this.has(h))return!1;var u=this[pr];return n(u),t(u),nc(u),u.o.delete(h)||!!u.p.has(h)&&u.o.delete(u.p.get(h))},d.clear=function(){var h=this[pr];n(h),Fn(h).size&&(t(h),nc(h),h.o.clear())},d.values=function(){var h=this[pr];return n(h),t(h),h.o.values()},d.entries=function(){var h=this[pr];return n(h),t(h),h.o.entries()},d.keys=function(){return this.values()},d[S0]=function(){return this.values()},d.forEach=function(h,u){for(var p=this.values(),v=p.next();!v.done;)h.call(u,v.value,v.value,this),v=p.next()},c}();_j("MapSet",{F:function(c,d){return new o(c,d)},T:function(c,d){return new a(c,d)}})}var dk,lm,j6=typeof Symbol<"u"&&typeof Symbol("x")=="symbol",Cj=typeof Map<"u",kj=typeof Set<"u",uk=typeof Proxy<"u"&&Proxy.revocable!==void 0&&typeof Reflect<"u",pP=j6?Symbol.for("immer-nothing"):((dk={})["immer-nothing"]=!0,dk),hk=j6?Symbol.for("immer-draftable"):"__$immer_draftable",pr=j6?Symbol.for("immer-state"):"__$immer_state",S0=typeof Symbol<"u"&&Symbol.iterator||"@@iterator",Ej=""+Object.prototype.constructor,z6=typeof Reflect<"u"&&Reflect.ownKeys?Reflect.ownKeys:Object.getOwnPropertySymbols!==void 0?function(r){return Object.getOwnPropertyNames(r).concat(Object.getOwnPropertySymbols(r))}:Object.getOwnPropertyNames,Sj=Object.getOwnPropertyDescriptors||function(r){var e={};return z6(r).forEach(function(t){e[t]=Object.getOwnPropertyDescriptor(r,t)}),e},Fb={},jb={get:function(r,e){if(e===pr)return r;var t=Fn(r);if(!Db(t,e))return function(i,o,a){var c,d=ck(o,a);return d?"value"in d?d.value:(c=d.get)===null||c===void 0?void 0:c.call(i.k):void 0}(r,t,e);var n=t[e];return r.I||!Da(n)?n:n===V3(r.t,e)?(F3(r),r.o[e]=cm(r.A.h,n,r)):n},has:function(r,e){return e in Fn(r)},ownKeys:function(r){return Reflect.ownKeys(Fn(r))},set:function(r,e,t){var n=ck(Fn(r),e);if(n!=null&&n.set)return n.set.call(r.k,t),!0;if(!r.P){var i=V3(Fn(r),e),o=i==null?void 0:i[pr];if(o&&o.t===t)return r.o[e]=t,r.R[e]=!1,!0;if(gj(t,i)&&(t!==void 0||Db(r.t,e)))return!0;F3(r),nc(r)}return r.o[e]===t&&(t!==void 0||e in r.o)||Number.isNaN(t)&&Number.isNaN(r.o[e])||(r.o[e]=t,r.R[e]=!0),!0},deleteProperty:function(r,e){return V3(r.t,e)!==void 0||e in r.t?(r.R[e]=!1,F3(r),nc(r)):delete r.R[e],r.o&&delete r.o[e],!0},getOwnPropertyDescriptor:function(r,e){var t=Fn(r),n=Reflect.getOwnPropertyDescriptor(t,e);return n&&{writable:!0,configurable:r.i!==1||e!=="length",enumerable:n.enumerable,value:t[e]}},defineProperty:function(){ea(11)},getPrototypeOf:function(r){return Object.getPrototypeOf(r.t)},setPrototypeOf:function(){ea(12)}},lp={};wf(jb,function(r,e){lp[r]=function(){return arguments[0]=arguments[0][0],e.apply(this,arguments)}}),lp.deleteProperty=function(r,e){return lp.set.call(this,r,e,void 0)},lp.set=function(r,e,t){return jb.set.call(this,r[0],e,t,r[0])};var Tj=function(){function r(t){var n=this;this.O=uk,this.D=!0,this.produce=function(i,o,a){if(typeof i=="function"&&typeof o!="function"){var c=o;o=i;var d=n;return function(b){var C=this;b===void 0&&(b=c);for(var T=arguments.length,S=Array(T>1?T-1:0),A=1;A<T;A++)S[A-1]=arguments[A];return d.produce(b,function(Z){var B;return(B=o).call.apply(B,[C,Z].concat(S))})}}var h;if(typeof o!="function"&&ea(6),a!==void 0&&typeof a!="function"&&ea(7),Da(i)){var u=ak(n),p=cm(n,i,void 0),v=!0;try{h=o(p),v=!1}finally{v?Eg(u):Vb(u)}return typeof Promise<"u"&&h instanceof Promise?h.then(function(b){return N3(u,a),D3(b,u)},function(b){throw Eg(u),b}):(N3(u,a),D3(h,u))}if(!i||typeof i!="object"){if((h=o(i))===void 0&&(h=i),h===pP&&(h=void 0),n.D&&V6(h,!0),a){var g=[],_=[];ms("Patches").M(i,h,g,_),a(g,_)}return h}ea(21,i)},this.produceWithPatches=function(i,o){if(typeof i=="function")return function(h){for(var u=arguments.length,p=Array(u>1?u-1:0),v=1;v<u;v++)p[v-1]=arguments[v];return n.produceWithPatches(h,function(g){return i.apply(void 0,[g].concat(p))})};var a,c,d=n.produce(i,o,function(h,u){a=h,c=u});return typeof Promise<"u"&&d instanceof Promise?d.then(function(h){return[h,a,c]}):[d,a,c]},typeof(t==null?void 0:t.useProxies)=="boolean"&&this.setUseProxies(t.useProxies),typeof(t==null?void 0:t.autoFreeze)=="boolean"&&this.setAutoFreeze(t.autoFreeze)}var e=r.prototype;return e.createDraft=function(t){Da(t)||ea(8),Cu(t)&&(t=wj(t));var n=ak(this),i=cm(this,t,void 0);return i[pr].C=!0,Vb(n),i},e.finishDraft=function(t,n){var i=t&&t[pr],o=i.A;return N3(o,n),D3(void 0,o)},e.setAutoFreeze=function(t){this.D=t},e.setUseProxies=function(t){t&&!uk&&ea(20),this.O=t},e.applyPatches=function(t,n){var i;for(i=n.length-1;i>=0;i--){var o=n[i];if(o.path.length===0&&o.op==="replace"){t=o.value;break}}i>-1&&(n=n.slice(i+1));var a=ms("Patches").$;return Cu(t)?a(t,n):this.produce(t,function(c){return a(c,n)})},r}(),So=new Tj,B6=So.produce;So.produceWithPatches.bind(So);So.setAutoFreeze.bind(So);So.setUseProxies.bind(So);So.applyPatches.bind(So);So.createDraft.bind(So);So.finishDraft.bind(So);const dm=(...r)=>$e(e=>r.includes(e.type));var Kn=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},Aj=function(r,e,t,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?r!==e||!i:!e.has(r))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(r,t):i?i.value=t:e.set(r,t),t},ns,Ko;class Lm extends Tt{get action$(){return Kn(this,ns,"f").asObservable()}get value(){return Kn(this,Ko,"f").value}get closed(){return Kn(this,Ko,"f").closed||Kn(this,ns,"f").closed}constructor(e,t){super(i=>Kn(this,Ko,"f").subscribe(i)),ns.set(this,new Bn),Ko.set(this,void 0);const n="getInitialState"in e?e.getInitialState():t;Aj(this,Ko,new Df(n),"f"),Kn(this,ns,"f").pipe(jN(e,n),rg()).subscribe(Kn(this,Ko,"f")),this.reset=()=>Kn(this,Ko,"f").next(n)}next(e){Kn(this,ns,"f").next(e)}select(e,t){return Kn(this,Ko,"f").pipe(me(e),rg(t))}addEffect(e,t){const n=typeof e=="function"?this.action$:Array.isArray(e)?this.action$.pipe(dm(...e)):this.action$.pipe(dm(e)),i=t||e;return n.pipe(Jn(o=>rt(new Promise((a,c)=>{try{a(i(o,this.value))}catch(d){c(d)}})).pipe(Vt(a=>(console.warn("unhandled effect",a),Tr)))),$e(o=>!!o),tg(ff)).subscribe(Kn(this,ns,"f"))}addEpic(e){return this.addFlow(e)}addFlow(e){const t=e(this.action$,this);if(!t)throw new TypeError(`addEpic: one of the provided effects "${e.name||"<anonymous>"}" does not return a stream. Double check you're not missing a return statement!`);return t.pipe(Vt(n=>(console.trace("unhandled exception, epic closed!",n),Tr)),tg(ff)).subscribe(Kn(this,ns,"f"))}unsubscribe(){Kn(this,ns,"f").unsubscribe(),Kn(this,Ko,"f").unsubscribe()}complete(){Kn(this,ns,"f").complete(),Kn(this,Ko,"f").complete()}asObservable(){return Kn(this,Ko,"f").asObservable()}}ns=new WeakMap,Ko=new WeakMap;function on(r,e){function t(...n){if(e){const i=e(...n);if(!i)throw new Error("prepareAction did not return an object");return Object.assign(Object.assign({type:r,payload:i.payload},"meta"in i&&{meta:i.meta}),"error"in i&&{error:i.error})}return{type:r,payload:n[0]}}return t.toString=()=>`${r}`,t.type=r,t.match=n=>n.type===r,t}const xv="::",mP=r=>new RegExp(`${xv}${r}$`);function Ag(r){return r.replace(mP("\\w+$"),"")}function vi(r,e,t,n){const i=on([r,"request"].join(xv),e);return t&&Object.assign(i,{success:on([r,"success"].join(xv),t)}),n&&Object.assign(i,{failure:on([r,"failure"].join(xv),n)}),i}function U6(r,e){return!!r.type.match(mP(e))}const vP=r=>U6(r,"request"),gP=r=>U6(r,"success"),q6=r=>U6(r,"failure"),yP=r=>gP(r)||q6(r);function fk(r){return Da(r)?B6(r,()=>{}):r}function Ij(r){return typeof r=="function"}function Hm(r,e){const[t,n,i]=Rj(e);let o;if(Ij(r))o=()=>fk(r());else{const c=fk(r);o=()=>c}function a(c,d){let h=[t[d.type],...n.filter(({matcher:u})=>u(d)).map(({reducer:u})=>u)];return i&&h.filter(u=>!!u).length===0&&(h=[i]),h.reduce((u,p)=>{if(p)if(Cu(u)){const g=p(u,d);return g===void 0?u:g}else{if(Da(u))return B6(u,v=>p(v,d));{const v=p(u,d);if(v===void 0){if(u===null)return u;throw Error("A case reducer on a non-draftable value must not return undefined")}return v}}return u},c??o())}return a.getInitialState=o,a}function Rj(r){const e={},t=[];let n;const i={addCase(o,a){const c=typeof o=="string"?o:o.type;if(c in e)throw new Error("addCase cannot be called with two reducers for the same action type");return e[c]=a,i},addMatcher(o,a){return t.push({matcher:o,reducer:a}),i},addDefaultCase(o){return n=o,i}};return r(i),[e,t,n]}const Pj=()=>({request:on("client/request",(r,e)=>({payload:{args:r,options:e},meta:{transaction:sm(),created:Date.now()}})),execute:vi("client/execute",r=>({payload:r,meta:{transaction:r,created:Date.now()}}),r=>({payload:r,meta:{transaction:r.transaction,created:Date.now()}}),(r,e)=>({payload:r,meta:{transaction:e,created:Date.now()}})),cancel:on("client/cancel",(r,e)=>({payload:{transaction:r,reason:e},meta:{transaction:r,created:Date.now()}})),error:on("client/error",(r,e)=>({payload:{transaction:r,error:e},meta:{transaction:r,created:Date.now()}}))}),ir=Pj(),Mj=r=>r.pipe($e(ir.request.match),me(e=>ir.execute(e.meta.transaction))),$j=r=>(e,t)=>e.pipe($e(ir.execute.match),Up(t),Jn(([n,i])=>{const o=n.payload,a=i[o],c=new AbortController,d=e.pipe($e(ir.cancel.match),$e(h=>h.payload.transaction===o),Br(()=>{c.signal.aborted||c.abort()}));try{return rt(r(a.args,c.signal)).pipe(me(h=>ir.execute.success(Object.assign(Object.assign({},a),{status:"complete",completed:Date.now(),value:h}))),Vt(h=>It(ir.execute.failure(h,o))),ou(d))}catch(h){return It(ir.execute.failure(h,o))}})),Oj=r=>(e,t)=>e.pipe($e(ir.execute.failure.match),Up(t),Jn(([n,i])=>{var o,a,c;const{transaction:d}=n.meta,h=i[d];if(!h)return It(ir.error(d,new jd("error",{message:"request not found, cannot retry request, most likely removed while scheduled for retry!"})));const u=h.execution.length,p=Object.assign({},r,(o=h.options)===null||o===void 0?void 0:o.retry),v=(c=(a=h.errors)===null||a===void 0?void 0:a.slice(-1)[0])!==null&&c!==void 0?c:new jd("error",{message:"no errors registered for request!",request:h});if(u>p.count){const _=p.count===0?v:new jd("error",{message:"maximum retries executed!",cause:h.errors,request:h});return It(ir.error(d,_))}return(typeof p.delay=="function"?rt(p.delay(v)).pipe(Vt(_=>{var b;return It(ir.error(d,new jd("error",{message:"retry delay callback failed!",cause:[...(b=h.errors)!==null&&b!==void 0?b:[],_],request:h})))})):w6(p.delay)).pipe(Up(t),$e(([_,b])=>!!b[d]),Br(([,_])=>{if(!_[d])throw new jd("error",{message:"request not found, most likely removed while scheduled for retry",cause:h.errors,request:h})}),me(()=>ir.execute(d)))})),Zj=(r={})=>Hm(r,e=>{e.addCase(ir.request,(t,n)=>{t[n.meta.transaction]=Object.assign(Object.assign(Object.assign({},n.payload),n.meta),{execution:[],errors:[],status:"idle"})}),e.addCase(ir.execute,(t,n)=>{const i=t[n.payload];i&&(i.execution.push(Date.now()),i.status="active")}),e.addCase(ir.execute.success,(t,n)=>{delete t[n.payload.transaction]}),e.addCase(ir.execute.failure,(t,n)=>{const i=t[n.meta.transaction];i&&(i.errors.push(n.payload),i.status="failed")}),e.addCase(ir.error,(t,n)=>{delete t[n.meta.transaction]}),e.addCase(ir.cancel,(t,n)=>{delete t[n.meta.transaction]})}),j3=10,pk=(r=0)=>e=>`\x1B[${e+r}m`,mk=(r=0)=>e=>`\x1B[${38+r};5;${e}m`,vk=(r=0)=>(e,t,n)=>`\x1B[${38+r};2;${e};${t};${n}m`,jr={modifier:{reset:[0,0],bold:[1,22],dim:[2,22],italic:[3,23],underline:[4,24],overline:[53,55],inverse:[7,27],hidden:[8,28],strikethrough:[9,29]},color:{black:[30,39],red:[31,39],green:[32,39],yellow:[33,39],blue:[34,39],magenta:[35,39],cyan:[36,39],white:[37,39],blackBright:[90,39],gray:[90,39],grey:[90,39],redBright:[91,39],greenBright:[92,39],yellowBright:[93,39],blueBright:[94,39],magentaBright:[95,39],cyanBright:[96,39],whiteBright:[97,39]},bgColor:{bgBlack:[40,49],bgRed:[41,49],bgGreen:[42,49],bgYellow:[43,49],bgBlue:[44,49],bgMagenta:[45,49],bgCyan:[46,49],bgWhite:[47,49],bgBlackBright:[100,49],bgGray:[100,49],bgGrey:[100,49],bgRedBright:[101,49],bgGreenBright:[102,49],bgYellowBright:[103,49],bgBlueBright:[104,49],bgMagentaBright:[105,49],bgCyanBright:[106,49],bgWhiteBright:[107,49]}};Object.keys(jr.modifier);const Lj=Object.keys(jr.color),Hj=Object.keys(jr.bgColor);[...Lj,...Hj];function Nj(){const r=new Map;for(const[e,t]of Object.entries(jr)){for(const[n,i]of Object.entries(t))jr[n]={open:`\x1B[${i[0]}m`,close:`\x1B[${i[1]}m`},t[n]=jr[n],r.set(i[0],i[1]);Object.defineProperty(jr,e,{value:t,enumerable:!1})}return Object.defineProperty(jr,"codes",{value:r,enumerable:!1}),jr.color.close="\x1B[39m",jr.bgColor.close="\x1B[49m",jr.color.ansi=pk(),jr.color.ansi256=mk(),jr.color.ansi16m=vk(),jr.bgColor.ansi=pk(j3),jr.bgColor.ansi256=mk(j3),jr.bgColor.ansi16m=vk(j3),Object.defineProperties(jr,{rgbToAnsi256:{value(e,t,n){return e===t&&t===n?e<8?16:e>248?231:Math.round((e-8)/247*24)+232:16+36*Math.round(e/255*5)+6*Math.round(t/255*5)+Math.round(n/255*5)},enumerable:!1},hexToRgb:{value(e){const t=/[a-f\d]{6}|[a-f\d]{3}/i.exec(e.toString(16));if(!t)return[0,0,0];let[n]=t;n.length===3&&(n=[...n].map(o=>o+o).join(""));const i=Number.parseInt(n,16);return[i>>16&255,i>>8&255,i&255]},enumerable:!1},hexToAnsi256:{value:e=>jr.rgbToAnsi256(...jr.hexToRgb(e)),enumerable:!1},ansi256ToAnsi:{value(e){if(e<8)return 30+e;if(e<16)return 90+(e-8);let t,n,i;if(e>=232)t=((e-232)*10+8)/255,n=t,i=t;else{e-=16;const c=e%36;t=Math.floor(e/36)/5,n=Math.floor(c/6)/5,i=c%6/5}const o=Math.max(t,n,i)*2;if(o===0)return 30;let a=30+(Math.round(i)<<2|Math.round(n)<<1|Math.round(t));return o===2&&(a+=60),a},enumerable:!1},rgbToAnsi:{value:(e,t,n)=>jr.ansi256ToAnsi(jr.rgbToAnsi256(e,t,n)),enumerable:!1},hexToAnsi:{value:e=>jr.ansi256ToAnsi(jr.hexToAnsi256(e)),enumerable:!1}}),jr}const cs=Nj(),gk=(()=>{if(navigator.userAgentData){const r=navigator.userAgentData.brands.find(({brand:e})=>e==="Chromium");if(r&&r.version>93)return 3}return/\b(Chrome|Chromium)\//.test(navigator.userAgent)?1:0})(),yk=gk!==0&&{level:gk},Dj={stdout:yk,stderr:yk};function Vj(r,e,t){let n=r.indexOf(e);if(n===-1)return r;const i=e.length;let o=0,a="";do a+=r.slice(o,n)+e+t,o=n+i,n=r.indexOf(e,o);while(n!==-1);return a+=r.slice(o),a}function Fj(r,e,t,n){let i=0,o="";do{const a=r[n-1]==="\r";o+=r.slice(i,a?n-1:n)+e+(a?`\r
75
75
  `:`
76
76
  `)+t,i=n+1,n=r.indexOf(`
77
77
  `,i)}while(n!==-1);return o+=r.slice(i),o}const{stdout:_k,stderr:bk}=Dj,zb=Symbol("GENERATOR"),xf=Symbol("STYLER"),um=Symbol("IS_EMPTY"),wk=["ansi","ansi","ansi256","ansi16m"],Cf=Object.create(null),jj=(r,e={})=>{if(e.level&&!(Number.isInteger(e.level)&&e.level>=0&&e.level<=3))throw new Error("The `level` option should be an integer from 0 to 3");const t=_k?_k.level:0;r.level=e.level===void 0?t:e.level},zj=r=>{const e=(...t)=>t.join(" ");return jj(e,r),Object.setPrototypeOf(e,Nm.prototype),e};function Nm(r){return zj(r)}Object.setPrototypeOf(Nm.prototype,Function.prototype);for(const[r,e]of Object.entries(cs))Cf[r]={get(){const t=Ig(this,Ub(e.open,e.close,this[xf]),this[um]);return Object.defineProperty(this,r,{value:t}),t}};Cf.visible={get(){const r=Ig(this,this[xf],!0);return Object.defineProperty(this,"visible",{value:r}),r}};const Bb=(r,e,t,...n)=>r==="rgb"?e==="ansi16m"?cs[t].ansi16m(...n):e==="ansi256"?cs[t].ansi256(cs.rgbToAnsi256(...n)):cs[t].ansi(cs.rgbToAnsi(...n)):r==="hex"?Bb("rgb",e,t,...cs.hexToRgb(...n)):cs[t][r](...n),Bj=["rgb","hex","ansi256"];for(const r of Bj){Cf[r]={get(){const{level:t}=this;return function(...n){const i=Ub(Bb(r,wk[t],"color",...n),cs.color.close,this[xf]);return Ig(this,i,this[um])}}};const e="bg"+r[0].toUpperCase()+r.slice(1);Cf[e]={get(){const{level:t}=this;return function(...n){const i=Ub(Bb(r,wk[t],"bgColor",...n),cs.bgColor.close,this[xf]);return Ig(this,i,this[um])}}}}const Uj=Object.defineProperties(()=>{},{...Cf,level:{enumerable:!0,get(){return this[zb].level},set(r){this[zb].level=r}}}),Ub=(r,e,t)=>{let n,i;return t===void 0?(n=r,i=e):(n=t.openAll+r,i=e+t.closeAll),{open:r,close:e,openAll:n,closeAll:i,parent:t}},Ig=(r,e,t)=>{const n=(...i)=>qj(n,i.length===1?""+i[0]:i.join(" "));return Object.setPrototypeOf(n,Uj),n[zb]=r,n[xf]=e,n[um]=t,n},qj=(r,e)=>{if(r.level<=0||!e)return r[um]?"":e;let t=r[xf];if(t===void 0)return e;const{openAll:n,closeAll:i}=t;if(e.includes("\x1B"))for(;t!==void 0;)e=Vj(e,t.close,t.open),t=t.parent;const o=e.indexOf(`
78
- `);return o!==-1&&(e=Fj(e,i,n,o)),n+e+i};Object.defineProperties(Nm.prototype,Cf);const xk=Nm();Nm({level:bk?bk.level:0});const Wj=r=>{if(typeof r!="string")throw new Error("Expected LogLevel key to be a string.");const e=r.toLowerCase(),t=Object.keys(un).find(n=>n.toLowerCase()===e);if(!t)throw new Error(`Failed to parse LogLevel from string: ${r}.`);return un[t]},Gj=r=>{const e=Number(r);if(Object.values(un).includes(e))return e;if(isNaN(e))return Wj(r);throw Error(`Invalid log level: ${r}`)};var Kj={},un;(function(r){r[r.None=0]="None",r[r.Error=1]="Error",r[r.Warning=2]="Warning",r[r.Info=3]="Info",r[r.Debug=4]="Debug"})(un||(un={}));const Yj=()=>{const r=Kj.FUSION_LOG_LEVEL;if(r)try{return Gj(r)}catch{return un.Error}return un.Error},Qj=Yj(),Xj="1.1.1";class Jj{constructor(){this.level=Qj,this.version=Xj,this._log$=new Bn}get log(){return this._log$.pipe($e(e=>this.level>=e.lvl))}debug(...e){this._log$.next({lvl:un.Debug,msg:this._createMessage(un.Debug,...e)})}info(...e){this._log$.next({lvl:un.Info,msg:this._createMessage(un.Info,...e)})}warn(...e){this._log$.next({lvl:un.Warning,msg:this._createMessage(un.Warning,...e)})}error(...e){this._log$.next({lvl:un.Error,msg:this._createMessage(un.Error,...e)})}}class Dm extends Jj{constructor(e,t){super(),this.title=e,this.subtitle=t,this.log.subscribe(({lvl:n,msg:i})=>{switch(n){case un.Debug:console.debug(...i);break;case un.Info:console.info(...i);break;case un.Warning:console.warn(...i);break;case un.Error:console.error(...i);break}})}_createMessage(e,...t){return[this._formatTitle(e),...t]}_formatTitle(e){const t=xk.magenta([this.title,this.subtitle].filter(n=>!!n).join(" - "));switch(e){case un.Warning:case un.Error:return xk.bold(t)}return t}createSubLogger(e,t,n){const i=new Dm(`${this.title}::${e}`,t??this.subtitle);return i.level=n===void 0?this.level:n,i}}var ts=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},Ck=function(r,e,t,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?r!==e||!i:!e.has(r))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(r,t):i?i.value=t:e.set(r,t),t},Yc,xh,T0;class ez extends Tt{get status(){return ts(this,Yc,"f").value}get status$(){return ts(this,Yc,"f").asObservable()}get transaction(){return ts(this,T0,"f")}get closed(){return this.status==="complete"||this.status==="error"||this.status==="canceled"}constructor(e,t,n){super(o=>{const{transaction:a}=this,c=e.action$.pipe($e(d=>d.meta.transaction===a));o.add(e.state$.pipe($e(d=>!!d[a]),me(d=>d[a])).subscribe(d=>{ts(this,Yc,"f").next(d.status)})),o.add(c.pipe($e(ir.execute.success.match),me(({payload:d})=>d)).subscribe(d=>{ts(this,Yc,"f").next("complete"),o.next(d),o.complete()})),o.add(c.pipe($e(ir.error.match),me(({payload:d})=>d)).subscribe(d=>{ts(this,Yc,"f").next("error"),o.error(d.error)})),o.add(c.pipe($e(ir.cancel.match)).subscribe(d=>{ts(this,Yc,"f").next("canceled"),o.error(new jd("abort",{message:d.payload.reason||`job: ${a} was canceled`,request:ts(this,xh,"f").getRequest(d.meta.transaction)}))})),n!=null&&n.signal&&o.add(iu(n==null?void 0:n.signal,"abort").pipe(me(()=>ir.cancel(a,`job: ${a} was aborted on signal from caller: ${n==null?void 0:n.ref}`))).subscribe(d=>e.next(d))),o.add(()=>{this.complete()})}),Yc.set(this,new Df("idle")),xh.set(this,void 0),T0.set(this,void 0),this.created=Date.now(),Ck(this,xh,e,"f");const i=ir.request(t,{ref:n==null?void 0:n.ref,retry:n==null?void 0:n.retry});Ck(this,T0,i.meta.transaction,"f"),ts(this,xh,"f").next(i)}complete(e){this.closed||this.cancel(e??`job: ${this.transaction} was completed`)}cancel(e){const t=this.transaction;ts(this,xh,"f").cancel(t,e??`job: ${t} was canceled`)}[(Yc=new WeakMap,xh=new WeakMap,T0=new WeakMap,Symbol.dispose)](){this.complete()}}var tz=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})},Jt=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},z3=function(r,e,t,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?r!==e||!i:!e.has(r))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(r,t):i?i.value=t:e.set(r,t),t},Hr,Md,is;class kk extends Tt{get closed(){return Jt(this,Hr,"f").closed}get state$(){return Jt(this,Hr,"f").asObservable()}get action$(){return Jt(this,Hr,"f").action$}get success$(){return this.action$.pipe($e(ir.execute.success.match),me(({payload:e})=>e))}get error$(){return this.action$.pipe(dm("client/error"),Up(Jt(this,Hr,"f")),me(([e,t])=>{const{payload:n,meta:{transaction:i}}=e,o=t[i];return new jd("error",{request:o,message:`job: ${i} failed`,cause:n})}))}constructor(e,t){var n;super(i=>Jt(this,Hr,"f").subscribe(i)),Hr.set(this,void 0),Md.set(this,void 0),is.set(this,void 0),z3(this,Hr,new Lm(Zj({})),"f"),z3(this,Md,new ti(()=>Jt(this,Hr,"f").complete()),"f"),Jt(this,Md,"f").add(Jt(this,Hr,"f").addFlow(Mj)),Jt(this,Md,"f").add(Jt(this,Hr,"f").addFlow($j(e))),Jt(this,Md,"f").add(Jt(this,Hr,"f").addFlow(Oj(Object.assign({count:0,delay:0},t==null?void 0:t.retry)))),z3(this,is,(n=t==null?void 0:t.logger)!==null&&n!==void 0?n:new Dm("QueryClient"),"f"),Jt(this,Hr,"f").addEffect(ir.request.type,({payload:i,meta:{transaction:o}})=>{Jt(this,is,"f").debug("Job requested",{transaction:o,payload:i})}),Jt(this,Hr,"f").addEffect(ir.execute.type,({payload:i,meta:{transaction:o}})=>{Jt(this,is,"f").debug("Job executing",{transaction:o,payload:i})}),Jt(this,Hr,"f").addEffect(ir.execute.success.type,({payload:i})=>{Jt(this,is,"f").info("Job complete",Object.assign({},i))}),Jt(this,Hr,"f").addEffect(ir.execute.failure.type,({payload:i,meta:{transaction:o}})=>{Jt(this,is,"f").debug("Job failed",{transaction:o,payload:i})}),Jt(this,Hr,"f").addEffect(ir.cancel.type,({payload:{reason:i},meta:{transaction:o}})=>{Jt(this,is,"f").debug("Job canceled",{transaction:o,reason:i})}),Jt(this,Hr,"f").addEffect(ir.error.type,({payload:{transaction:i,error:o}})=>{Jt(this,is,"f").error("Job error",{transaction:i,error:o})})}next(e){Jt(this,Hr,"f").next(e)}query(e,t){const n=new ez(this,e,t),i=n.pipe(Vf({connector:()=>new uR,resetOnRefCountZero:!1}));return Object.defineProperties(i,{transaction:{get:()=>n.transaction},created:{get:()=>n.created},status:{get:()=>n.status},closed:{get:()=>n.closed},cancel:{value:o=>n.cancel(o)},complete:{value:()=>n.complete()}}),i}nextAsync(e,t){return tz(this,void 0,void 0,function*(){return zn(this.query(e,t))})}getRequest(e){return Jt(this,Hr,"f").value[e]}getRequestByRef(e){return Object.values(Jt(this,Hr,"f").value).find(t=>t.ref===e)}cancelTaskByRef(e,t){const n=this.getRequestByRef(e);n!=null&&n.ref&&this.cancel(n.transaction,t)}cancel(e,t){if(e)Jt(this,Hr,"f").value[e]?(t??(t=`cancelation requested for job: ${e}`),Jt(this,Hr,"f").next(ir.cancel(e,t))):Jt(this,is,"f").warn("Task not registered, nothing to cancel",{transaction:e,reason:t});else for(const n of Object.keys(Jt(this,Hr,"f").value))this.cancel(n,"all transactions requested canceled")}on(e,t){return Jt(this,Hr,"f").addEffect(ir[e].type,n=>{t(n,this)})}complete(){Jt(this,Md,"f").unsubscribe()}}Hr=new WeakMap,Md=new WeakMap,is=new WeakMap;function rz(){return{set:on("cache/set",(r,e)=>({payload:{key:r,record:e}})),insert:on("cache/insert",(r,e)=>({payload:{key:r,entry:e}})),remove:on("cache/remove",r=>({payload:r})),invalidate:on("cache/invalidate",(r,e)=>({payload:r,meta:{item:e}})),mutate:on("cache/mutate",(r,e,t)=>({payload:Object.assign(Object.assign({},e),{key:r}),meta:{item:t}})),trim:on("cache/trim",r=>({payload:r}))}}const Qc=rz(),nz=(r,e)=>{var t,n;return((t=e.updated)!==null&&t!==void 0?t:0)-((n=r.updated)!==null&&n!==void 0?n:0)};function iz(r,e={}){return Hm(e,t=>t.addCase(r.set,(n,i)=>{const{key:o,record:a}=i.payload;n[o]=a}).addCase(r.insert,(n,i)=>{var o;const{key:a,entry:c}=i.payload,d=n[a];if(d)d.updated=Date.now(),(o=d.updates)!==null&&o!==void 0||(d.updates=0),d.updates++,d.value=c.value,d.transaction=c.transaction,d.mutated=void 0;else{const h=Date.now();n[a]=Object.assign(Object.assign({},c),{created:h,updated:h})}}).addCase(r.remove,(n,i)=>{delete n[i.payload]}).addCase(r.invalidate,(n,i)=>{const o=i.payload?[i.payload]:Object.keys(n);for(const a of o){const c=n[a];c&&(c.updated=void 0)}}).addCase(r.mutate,(n,i)=>{var o;const{key:a,value:c,updated:d}=i.payload,h=n[a];h&&(h.value=c,h.updated=d,h.mutated=Date.now(),(o=h.updates)!==null&&o!==void 0||(h.updates=0),h.updates++)}).addCase(r.trim,(n,i)=>{var o,a;const{payload:c}=i,d=(o=c.sort)!==null&&o!==void 0?o:nz,h=Object.keys(n),u=Object.entries(n).filter(([p,v])=>!c.validate||c.validate(v)).sort((p,v)=>d(p[1],v[1])).slice(0,(a=c.size)!==null&&a!==void 0?a:Number.MAX_SAFE_INTEGER).map(([p])=>p);if(h.length!==u.length)for(const p of h){const v=u.indexOf(p);v!==-1?u.splice(v,1):delete n[p]}}))}var Dn=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},oz=function(r,e,t,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?r!==e||!i:!e.has(r))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(r,t):i?i.value=t:e.set(r,t),t},yn;class Ek{get state(){return Dn(this,yn,"f").value}get state$(){return Dn(this,yn,"f").asObservable()}get action$(){return Dn(this,yn,"f").action$}constructor(e){yn.set(this,void 0);const{trimming:t,initial:n}=e??{};oz(this,yn,new Lm(iz(Qc,n)),"f"),t&&Dn(this,yn,"f").addEffect("cache/set",()=>Dn(this,yn,"f").next(Qc.trim(t)))}has(e){return e in Dn(this,yn,"f").value}setItem(e,t){const{args:n,transaction:i,value:o}=t;Dn(this,yn,"f").next(Qc.insert(e,{args:n,transaction:i,value:o}))}getItem(e){return Dn(this,yn,"f").value[e]}removeItem(e){Dn(this,yn,"f").next(Qc.remove(e))}invalidate(e){const t=e?Dn(this,yn,"f").value[e]:void 0;Dn(this,yn,"f").next(Qc.invalidate(e,t))}mutate(e,t){const n=e in Dn(this,yn,"f").value?Dn(this,yn,"f").value[e]:void 0;if(!n)throw new Error(`Cannot mutate cache item with key ${e}: item not found`);const i=typeof t=="function"?t(n==null?void 0:n.value):t;return Dn(this,yn,"f").next(Qc.mutate(e,i,n)),()=>Dn(this,yn,"f").next(Qc.set(e,n))}trim(e){Dn(this,yn,"f").next(Qc.trim(e))}reset(){Dn(this,yn,"f").reset()}complete(){Dn(this,yn,"f").complete()}}yn=new WeakMap;var Sk=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},qb,Wb;class az extends Bn{get created(){return Sk(this,qb,"f")}get uuid(){return Sk(this,Wb,"f")}constructor(e,t,n){super(),this.key=e,this.args=t,this.options=n,qb.set(this,Date.now()),Wb.set(this,sm())}processJob(e,t){return e.pipe(me(n=>{const{key:i,uuid:o,created:a}=this;return{key:i,uuid:o,created:a,status:"complete",transaction:e.transaction,complete:n.completed,value:n.value}}),ng(()=>{t==null||t.debug("QueryTask complete",{uuid:this.uuid,key:this.key,job:{status:e.status,transaction:e.transaction}}),e.complete()})).subscribe(this)}}qb=new WeakMap,Wb=new WeakMap;var pt=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},vd=function(r,e,t,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?r!==e||!i:!e.has(r))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(r,t):i?i.value=t:e.set(r,t),t},sz=function(r,e){var t={};for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&e.indexOf(n)<0&&(t[n]=r[n]);if(r!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,n=Object.getOwnPropertySymbols(r);i<n.length;i++)e.indexOf(n[i])<0&&Object.prototype.propertyIsEnumerable.call(r,n[i])&&(t[n[i]]=r[n[i]]);return t},$d,il,Yo,dp,Qs,ol,up,Cv,Vn;const cz=(r=0)=>e=>{var t;return((t=e.updated)!==null&&t!==void 0?t:0)+r>Date.now()},lz=(r="switch")=>typeof r=="function"?r:(()=>{switch(r){case"concat":return rj;case"merge":return nj;case"switch":return ij;default:throw new Error(`Invalid queue operator: ${r}`)}})();class xi{get client(){return pt(this,il,"f")}get cache(){return pt(this,Yo,"f")}constructor(e){var t,n;$d.set(this,new ti),il.set(this,void 0),Yo.set(this,void 0),dp.set(this,new Bn),Qs.set(this,{}),ol.set(this,void 0),up.set(this,void 0),Cv.set(this,sm()),Vn.set(this,void 0),vd(this,Vn,(t=e.logger)!==null&&t!==void 0?t:new Dm("Query",pt(this,Cv,"f")),"f"),vd(this,ol,o=>L6(e.key(o),pt(this,Cv,"f")),"f"),vd(this,up,(n=e==null?void 0:e.validate)!==null&&n!==void 0?n:cz(e==null?void 0:e.expire),"f"),e.client instanceof kk?vd(this,il,e.client,"f"):(vd(this,il,new kk(e.client.fn,Object.assign({logger:pt(this,Vn,"f").createSubLogger("Client")},e.client.options)),"f"),pt(this,$d,"f").add(()=>pt(this,il,"f").complete())),e.cache instanceof Ek?vd(this,Yo,e.cache,"f"):(vd(this,Yo,new Ek(e.cache||{}),"f"),pt(this,$d,"f").add(()=>pt(this,Yo,"f").complete()));const i=lz(e.queueOperator);pt(this,$d,"f").add(()=>pt(this,dp,"f").complete()),pt(this,$d,"f").add(pt(this,dp,"f").pipe(Br(o=>pt(this,Vn,"f").debug("Task added to queue",{key:o})),$e(o=>o in pt(this,Qs,"f")),i(o=>{const a=pt(this,Qs,"f")[o],{args:c,options:d,uuid:h}=a;if(pt(this,Vn,"f").debug("Task selected from queue",{key:o,task:a.uuid,args:c,options:d}),!(a!=null&&a.observed))return pt(this,Vn,"f").debug("Task skipped",{task:h}),delete pt(this,Qs,"f")[o],Tr;const u=pt(this,il,"f").query(c,Object.assign(Object.assign({},d),{ref:a.uuid}));return new Tt(p=>{const{transaction:v}=u;pt(this,Vn,"f").info("Task stated",{task:h,transaction:v}),p.add(()=>{pt(this,Vn,"f").debug("Task closed",{task:h,transaction:v,jobStatus:u.status}),u.complete("task closed"),delete pt(this,Qs,"f")[o]}),p.add(LN(10).pipe($e(()=>!a.observed)).subscribe(()=>{u.cancel(`task: ${a.uuid} is not observed`),p.complete()})),p.add(a.processJob(u,pt(this,Vn,"f"))),u.pipe(me(g=>({result:g,task:a})),Vt(()=>Tr)).subscribe(p)})}),MR(()=>!pt(this,il,"f").closed)).subscribe(o=>{const{value:a,transaction:c}=o.result,{args:d,key:h,uuid:u}=o.task;pt(this,Vn,"f").debug("Task output added to cache",{uuid:u,args:d,key:h,transaction:c,value:a}),pt(this,Yo,"f").setItem(h,{value:a,args:d,transaction:c})}))}query(e,t){return this._query(e,t)}queryAsync(e,t){const n=t||{},{skipResolve:i}=n,o=sz(n,["skipResolve"]),a=i?zn:lr;return new Promise((c,d)=>{t!=null&&t.signal&&t.signal.addEventListener("abort",()=>d(new Error("Query aborted"))),a(this._query(e,o).pipe(C6())).then(c,d)})}persistentQuery(e,t){const n=pt(this,ol,"f").call(this,e),i=this._query(e,t);return new Tt(o=>{var a;o.add(i.subscribe({next:o.next.bind(o),error:o.error.bind(o)}));const c=((a=t==null?void 0:t.cache)===null||a===void 0?void 0:a.validate)||pt(this,up,"f");o.add(this.cache.state$.pipe($e(d=>n in d),me(d=>Object.assign(Object.assign({},d[n]),{key:n,status:"cache",hasValidCache:c(d[n],e)}))).subscribe(o))}).pipe(rg((o,a)=>o.transaction===a.transaction&&o.mutated===a.mutated))}generateCacheKey(e){return pt(this,ol,"f").call(this,e)}mutate(e,t,n){const i=pt(this,ol,"f").call(this,e);if(!(i in this.cache.state)){if((n==null?void 0:n.allowCreation)===void 0)throw new Error(`Cannot mutate cache item with key ${i}: item not found and option "allowCreation" is false`);if(n.allowCreation===!1)return()=>{};const{value:o}=typeof t=="function"?t():t;this.cache.setItem(i,{args:e,transaction:sm(),value:o})}return pt(this,Yo,"f").mutate(i,t)}invalidate(e){pt(this,Yo,"f").invalidate(e&&pt(this,ol,"f").call(this,e))}complete(){pt(this,$d,"f").unsubscribe()}onInvalidate(e){const t=pt(this,Yo,"f").action$.pipe(dm("cache/invalidate")).subscribe(n=>e({detail:{item:n.meta.item}}));return()=>t.unsubscribe()}onMutate(e){const t=pt(this,Yo,"f").action$.pipe(dm("cache/mutate")).subscribe(n=>e({detail:{changes:n.payload,current:n.meta.item}}));return()=>t.unsubscribe()}_query(e,t){const n=pt(this,ol,"f").call(this,e),i=this._createTask(n,e,t);return pt(this,Vn,"f").debug("New query created",{key:n,args:e,options:t}),i}_createTask(e,t,n){return new Tt(i=>{var o,a,c,d,h;if(n!=null&&n.signal){if(n!=null&&n.signal.aborted)return pt(this,Vn,"f").debug("Abort signal already triggered by caller",{key:e}),i.complete();i.add(iu(n==null?void 0:n.signal,"abort").subscribe(()=>{pt(this,Vn,"f").debug("Abort signal triggered by caller",{key:e}),i.complete()}))}const u=pt(this,Yo,"f").getItem(e);if(u){pt(this,Vn,"f").debug("Query has cache",{key:e,cacheEntry:u});const g=(a=(o=n==null?void 0:n.cache)===null||o===void 0?void 0:o.suppressInvalid)!==null&&a!==void 0?a:!1,b=(((c=n==null?void 0:n.cache)===null||c===void 0?void 0:c.validate)||pt(this,up,"f"))(u,t),C=Object.assign(Object.assign({},u),{key:e,status:"cache",hasValidCache:b});if(pt(this,Vn,"f").info("Query cache valid, completing",{hasValidCache:b,suppressInvalid:g,record:C}),i.next(C),b||g)return i.complete();pt(this,Vn,"f").debug("Query cache entry is invalid, proceeding to fetch new data",{key:e})}const p=e in pt(this,Qs,"f");(d=(h=pt(this,Qs,"f"))[e])!==null&&d!==void 0||(h[e]=new az(e,t,n));const v=pt(this,Qs,"f")[e];i.add(v.subscribe(i)),pt(this,Vn,"f").info(p?"Query connected to existing task":"Query started new task",{key:e}),p||pt(this,dp,"f").next(e)})}}$d=new WeakMap,il=new WeakMap,Yo=new WeakMap,dp=new WeakMap,Qs=new WeakMap,ol=new WeakMap,up=new WeakMap,Cv=new WeakMap,Vn=new WeakMap;xi.extractQueryValue=lf;var Xc=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},Tk=function(r,e,t,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?r!==e||!i:!e.has(r))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(r,t):i?i.value=t:e.set(r,t),t},hp,Xs;class dz extends Tt{get currentContext(){return Xc(this,Xs,"f").value}get currentContext$(){return Xc(this,Xs,"f").asObservable()}get client(){return Xc(this,hp,"f")}constructor(e){super(t=>Xc(this,Xs,"f").subscribe(t)),hp.set(this,void 0),Xs.set(this,void 0),Tk(this,hp,new xi(e),"f"),Tk(this,Xs,new Df(void 0),"f")}setCurrentContext(e){typeof e=="string"?this.resolveContext(e).pipe(Vt(()=>Tr)).subscribe(t=>this.setCurrentContext(t)):Nb(e,Xc(this,Xs,"f").value)||Xc(this,Xs,"f").next(e)}resolveContext(e){return Xc(this,hp,"f").query({id:e}).pipe(me(t=>t.value),Vt(t=>{throw t.cause?t.cause:t}))}resolveContextAsync(e,t){return(t!=null&&t.awaitResolve?lr:zn)(this.resolveContext(e))}dispose(){Xc(this,Xs,"f").complete()}}hp=new WeakMap,Xs=new WeakMap;var H1=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})},cr=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},gd=function(r,e,t,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?r!==e||!i:!e.has(r))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(r,t):i?i.value=t:e.set(r,t),t},Js,kv,fp,Ta,Od,Zd,pp,Ev,Sv;let uz=class{get contextClient(){return cr(this,Js,"f")}get queryClient(){return cr(this,kv,"f")}get currentContext$(){return cr(this,Js,"f").currentContext$}get currentContext(){return cr(this,Js,"f").currentContext}set currentContext(e){if(console.warn("@deprecated","ContextProvider.currentContext","use setCurrentContextById|setCurrentContext|clearCurrentContext"),e===void 0)throw Error("not allowed to set current context as undefined undefined!");this.setCurrentContextAsync(e)}constructor(e){var t,n,i;Js.set(this,void 0),kv.set(this,void 0),fp.set(this,void 0),Ta.set(this,void 0),Od.set(this,new ti),Zd.set(this,void 0),pp.set(this,void 0),Ev.set(this,void 0),Sv.set(this,new Bn);const{config:o,event:a}=e;e.parentContext&&console.warn("@deprecated","parentContext as arg is deprecated, use ContextProvider.connectParentContext"),gd(this,Ta,a,"f"),o.resolveContext&&(this.resolveContext=(t=o.resolveContext)===null||t===void 0?void 0:t.bind(this)),o.validateContext&&(this.validateContext=(n=o.validateContext)===null||n===void 0?void 0:n.bind(this)),gd(this,Zd,o.contextType,"f"),gd(this,pp,o.contextFilter,"f"),gd(this,Js,new dz(o.client.get),"f"),gd(this,kv,new xi(o.client.query),"f"),o.client.related&&gd(this,fp,new xi(o.client.related),"f"),gd(this,Ev,(i=o.contextParameterFn)!==null&&i!==void 0?i:c=>({search:c.search,filter:{type:c.type}}),"f"),cr(this,Ta,"f")&&(cr(this,Od,"f").add(this.currentContext$.pipe(ig()).subscribe(([c,d])=>{var h;(h=cr(this,Ta,"f"))===null||h===void 0||h.dispatchEvent("onCurrentContextChanged",{source:this,canBubble:!0,detail:{previous:c,next:d}})})),cr(this,Od,"f").add(cr(this,Ta,"f").addEventListener("onCurrentContextChanged",c=>{c.source!==this&&c.detail.next!==void 0&&this.setCurrentContext(c.detail.next)}))),cr(this,Od,"f").add(cr(this,Sv,"f").pipe(Wt(c=>c),Br(c=>console.debug("ContextProvider::#contextQueue",c))).subscribe(c=>{cr(this,Js,"f").setCurrentContext(c??null)}))}connectParentContext(e,t){const i=e.currentContext$.pipe($e(o=>o!==void 0),$e((o,a)=>{var c;return t!=null&&t.skipFirst&&a<=1?(console.debug("ContextProvider::connectParentContext","skipping first item",o),!1):((c=this.currentContext)===null||c===void 0?void 0:c.id)!==(o==null?void 0:o.id)}),Wt(o=>H1(this,void 0,void 0,function*(){var a;if(!o)return{next:o};const c=yield(a=cr(this,Ta,"f"))===null||a===void 0?void 0:a.dispatchEvent("onParentContextChanged",{source:this,detail:o,cancelable:!0});return{next:o,canceled:c==null?void 0:c.canceled}})),$e(o=>!o.canceled),Wt(({next:o})=>this.setCurrentContext(o,{validate:!0,resolve:!0}).pipe(Vt(a=>(console.warn("ContextProvider::onParentContextChanged","setCurrentContext",a),Tr)))),Vt(o=>(console.warn("ContextProvider::onParentContextChanged","unhandled exception",o),Tr))).subscribe();return cr(this,Od,"f").add(i),i}setCurrentContextById(e){return new Tt(t=>{try{cr(this,Js,"f").resolveContext(e).pipe($e(n=>!!n),Wt(n=>this.setCurrentContext(n))).subscribe(t)}catch(n){t.error(n)}})}setCurrentContextByIdAsync(e){return lr(this.setCurrentContextById(e))}setCurrentContext(e,t){const n=new Bn,i=new Bn,o=this._setCurrentContext(e,t).pipe(Br(a=>i.next(a)),ou(n),ng(()=>i.complete()),Vt(a=>(i.error(a),Tr)));return cr(this,Sv,"f").next(o),i.pipe(ng(()=>n.next(!0)))}_setCurrentContext(e,t){return new Tt(n=>{var i;if(e===this.currentContext)return n.next(e),n.complete();if(e&&(t!=null&&t.validate)&&!this.validateContext(e)){if(!t.resolve)return(i=cr(this,Ta,"f"))===null||i===void 0||i.dispatchEvent("onSetContextValidationFailed",{source:this,detail:{context:e}}),n.error(Error("failed to validate provided context"));if(t.resolve)return It(e).pipe(Wt(o=>H1(this,void 0,void 0,function*(){var a;const c=yield(a=cr(this,Ta,"f"))===null||a===void 0?void 0:a.dispatchEvent("onSetContextResolve",{source:this,cancelable:!0,detail:{context:o}});if(c!=null&&c.canceled)throw Error("resolving of context was canceled");return o})),Wt(o=>this.resolveContext(o).pipe(me(a=>({context:o,resolved:a})))),Wt(o=>H1(this,[o],void 0,function*({context:a,resolved:c}){var d;const h=yield(d=cr(this,Ta,"f"))===null||d===void 0?void 0:d.dispatchEvent("onSetContextResolved",{source:this,cancelable:!0,detail:{context:a,resolved:c}});if(h!=null&&h.canceled)throw Error("resolving of context was canceled");return c})),Wt(o=>this._setCurrentContext(o))).subscribe(n)}return It(e).pipe(Wt(o=>H1(this,void 0,void 0,function*(){var a;const c=yield(a=cr(this,Ta,"f"))===null||a===void 0?void 0:a.dispatchEvent("onCurrentContextChange",{source:this,canBubble:!0,cancelable:!0,detail:{context:o}});if(c!=null&&c.canceled)throw Error("change of context was aborted");return o}))).subscribe(o=>{n.next(o),n.complete()})})}setCurrentContextAsync(e,t){return H1(this,void 0,void 0,function*(){return lr(this.setCurrentContext(e,t))})}queryContext(e){const t=this.queryClient.query(cr(this,Ev,"f").call(this,{search:e,type:cr(this,Zd,"f")})).pipe(Vt(n=>{throw n.name==="QueryClientError"?n.cause:n}),me(n=>n.value));return cr(this,pp,"f")?t.pipe(me(cr(this,pp,"f"))):t}queryContextAsync(e){return lr(this.queryContext(e))}validateContext(e){return cr(this,Zd,"f")?cr(this,Zd,"f").map(t=>t.toLowerCase()).includes(e.type.id.toLowerCase()):!0}resolveContext(e){return this.relatedContexts({item:e,filter:{type:cr(this,Zd,"f")}}).pipe(me(t=>t.filter(n=>this.validateContext(n))),me(t=>{const n=t.shift();if(!n)throw Error("failed to resolve context");return t.length&&console.warn("ContextProvider::relatedContext","multiple items found 🤣",t),n}))}resolveContextAsync(e){return lr(this.resolveContext(e))}relatedContexts(e){return cr(this,fp,"f")?cr(this,fp,"f").query(e).pipe(me(({value:t})=>t),Vt(t=>{throw t.cause?t.cause:t})):kR(()=>Error("ContextProvider::relatedContexts - no client defined for resolving related context"))}relatedContextsAsync(e){return lr(this.relatedContexts(e))}clearCurrentContext(){this.setCurrentContext(null)}dispose(){cr(this,Od,"f").unsubscribe(),cr(this,Js,"f").dispose()}};Js=new WeakMap,kv=new WeakMap,fp=new WeakMap,Ta=new WeakMap,Od=new WeakMap,Zd=new WeakMap,pp=new WeakMap,Ev=new WeakMap,Sv=new WeakMap;var hz=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};const fz="context",pz={name:fz,configure:()=>new JF,initialize:function(r){return hz(this,void 0,void 0,function*(){var e;const t=yield r.config.createConfig(r),n=r.hasModule("event")?yield r.requireInstance("event"):void 0,i=(e=r.ref)===null||e===void 0?void 0:e.context,o=new uz({config:t,event:n,parentContext:i}),a=new ti(()=>o.dispose());return this.postInitialize=c=>new Tt(d=>{const h=t.resolveInitialContext?rt(t.resolveInitialContext(c)).pipe($e(u=>!!u),Wt(u=>c.modules.context.setCurrentContext(u,{validate:!0,resolve:!0}))):Tr;d.add(h.pipe(Vt(u=>(console.warn("ContextModule.postInitialize","failed to resolve initial context",u),Tr))).subscribe({next:u=>{console.debug("ContextModule.postInitialize",`initial context was resolved to [${u?u.id:"none"}]`,u)},complete:()=>{t.connectParentContext!==!1&&i&&o.connectParentContext(i),d.complete()}}))}),this.dispose=()=>a.unsubscribe(),o})}},mz=F.object({key:F.string().describe("The key used to identify the service"),uri:F.string().describe("The URI of the service"),id:F.string().optional().describe("The ID of the service"),environment:F.string().optional().describe("The environment of the service"),name:F.string().optional().describe("The name of the service"),scopes:F.array(F.string()).optional().default([]).describe("Endpoint authentication scopes"),tags:F.array(F.string()).optional().describe("Tags for the service")}).describe("A service from the service discovery API").transform(r=>Object.assign(Object.assign({},r),{get defaultScopes(){var e;return console.warn("The `defaultScopes` property is deprecated. Use `scopes` instead."),(e=r.scopes)!==null&&e!==void 0?e:[]}})),vz=F.array(mz).describe("A list of services from the service discovery API");var gz=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})},yz=function(r,e,t,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?r!==e||!i:!e.has(r))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(r,t):i?i.value=t:e.set(r,t),t},_z=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},Tv;const bz="services",wz=r=>rt(gf(r)).pipe(me(e=>vz.default([]).parse(e)));class xz{constructor({http:e,endpoint:t}){Tv.set(this,void 0),this.http=e,this.endpoint=t,yz(this,Tv,new xi({client:{fn:()=>e.fetch$(t??"",{selector:wz})},key:()=>bz,expire:5*60*1e3}),"f")}resolveServices(e){return(e?zn:lr)(xi.extractQueryValue(_z(this,Tv,"f").query()))}resolveService(e,t){return gz(this,void 0,void 0,function*(){const i=(yield this.resolveServices(t)).find(o=>o.key===e);if(!i)throw Error(`Failed to resolve service, invalid key [${e}]`);return i})}}Tv=new WeakMap;var A0=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};class Cz extends Mm{_createConfig(e,t){const n=Object.create(null,{_createConfig:{get:()=>super._createConfig}});return A0(this,void 0,void 0,function*(){if(!e.hasModule("http"))throw new Error("http module is required");return this._has("discoveryClient")||(yield e.requireInstance("http")).hasClient("service_discovery")&&this.configureServiceDiscoveryClientByClientKey("service_discovery"),lr(rt(n._createConfig.call(this,e,t)))})}_processConfig(e,t){if(!e.discoveryClient)throw new Error("discoveryClient is required, please configure it");return super._processConfig(e,t)}setServiceDiscoveryClient(e){this._set("discoveryClient",typeof e=="function"?e:()=>A0(this,void 0,void 0,function*(){return e}))}configureServiceDiscoveryClient(e){this.setServiceDiscoveryClient(t=>A0(this,void 0,void 0,function*(){var n;const{httpClient:i,endpoint:o}=(n=yield lr(rt(e(t))))!==null&&n!==void 0?n:{};if(i)return new xz({http:i,endpoint:o});throw Error("httpClient is required")}))}configureServiceDiscoveryClientByClientKey(e,t){this.configureServiceDiscoveryClient(n=>A0(this,[n],void 0,function*({requireInstance:i}){return{httpClient:(yield i("http")).createClient(e),endpoint:t}}))}}var B3=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};class kz{constructor(e,t){this.config=e,this._http=t}resolveServices(){return this.config.discoveryClient.resolveServices()}resolveService(e){return B3(this,void 0,void 0,function*(){return this.config.discoveryClient.resolveService(e)})}createClient(e,t){return B3(this,void 0,void 0,function*(){const n=yield this.resolveService(e);if(!n)throw Error(`Could not load configuration of service [${e}]`);return this._http.createClient(Object.assign(Object.assign({},t),{baseUri:n.uri,defaultScopes:n.scopes}))})}configureClient(e,t){return B3(this,void 0,void 0,function*(){const{key:n,alias:i}=typeof e=="string"?{key:e,alias:e}:e,{uri:o,scopes:a}=yield this.resolveService(n);t.addConfig(YR(i,{baseUri:o,defaultScopes:a}))})}}var Ez=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};const Sz="serviceDiscovery",Tz={name:Sz,configure:()=>new Cz,initialize:r=>Ez(void 0,void 0,void 0,function*(){var e;const{requireInstance:t,ref:n}=r,i=yield r.config.createConfigAsync(r,Object.assign({},(e=n==null?void 0:n.serviceDiscovery)===null||e===void 0?void 0:e.config)),o=yield t("http");return new kz(i,o)})};class Az{}var yc;(function(r){r.v1="1.0",r.v2="2.0"})(yc||(yc={}));class Io extends Error{constructor(e,t){super(`unsupported version ${e}`,{cause:t}),this.version=e}}const Iz=(r,e)=>{var t;const n=(t=yc[r])!==null&&t!==void 0?t:r;switch(n){case yc.v2:throw new Io(r);default:{const{id:i}=e,o=new URLSearchParams;return o.append("api-version",n),`/contexts/${i}/?${String(o)}`}}},Rz=(r,e,t)=>[Iz(r,e),t],Pz=(r,e,t="json")=>(n,i)=>r[t](...Rz(e,n,i));var Mz=["eq","ne","gt","ge","lt","le"],I0=["and","or","not"],$z=["any","all"],Oz=["startswith","endswith","contains","matchespattern"],Zz=["expand","levels","select","skip","top","count","orderby","filter"],Ak=/\((.*)\)/,Ik=/(?!indexof)\((\w+)\)/,Rk;(function(r){r.sum="sum",r.min="min",r.max="max",r.average="average",r.countdistinct="countdistinct"})(Rk||(Rk={}));var qs="";function _P(r){var e=r===void 0?{}:r,t=e.select,n=e.search,i=e.skiptoken,o=e.format,a=e.top,c=e.skip,d=e.filter,h=e.transform,u=e.orderBy,p=e.key,v=e.count,g=e.expand,_=e.action,b=e.func,C="",T=[],S={};if(p!=null&&(C+="(".concat(hs(p,T),")")),(d||typeof v=="object")&&(S.$filter=hm(typeof v=="object"?v:d,T)),h&&(S.$apply=bP(h)),g&&(S.$expand=Av(g)),u&&(S.$orderby=W6(u)),v&&(typeof v=="boolean"?S.$count=!0:C+="/$count"),typeof a=="number"&&(S.$top=a),typeof c=="number"&&(S.$skip=c),_&&(C+="/".concat(_)),b){if(typeof b=="string")C+="/".concat(b);else if(typeof b=="object"){var A=Object.keys(b)[0],Z=hs(b[A],T);C+="/".concat(A),Z!==""&&(C+="(".concat(Z,")"))}}return T.length>0&&Object.assign(S,T.reduce(function(B,U){var I;return Object.assign(B,(I={},I["@".concat(U.name)]=hs(U.value),I))},{})),Vz(C,Sn({$select:t,$search:n,$skiptoken:i,$format:o},S))}function U3(r,e,t){return t===void 0&&(t=[]),"".concat(r," eq ").concat(hs(e,t))}function hm(r,e,t){return r===void 0&&(r={}),e===void 0&&(e=[]),t===void 0&&(t=""),(Array.isArray(r)?r:[r]).reduce(function(o,a){if(a){var c=n(a,e,t);c&&o.push(c)}return o},[]).join(" and ");function n(o,a,c){o===void 0&&(o={}),a===void 0&&(a=[]),c===void 0&&(c="");var d="";if(typeof o=="string")d=o;else if(o&&typeof o=="object"){var h=Object.keys(o).reduce(function(u,p){var v=o[p];if(v===void 0)return u;var g="";if(c?p===qs?g=c:Ik.test(p)?g=p.replace(Ik,function(S,A){return A.trim()===qs?"(".concat(c,")"):"(".concat(c,"/").concat(A.trim(),")")}):Ak.test(p)?g=p.replace(Ak,function(S,A){return A.trim()===qs?"(".concat(c,")"):"(".concat(c,"/").concat(A.trim(),")")}):g="".concat(c,"/").concat(p):g=p,p===qs&&Array.isArray(v))return u.concat(v.map(function(S){return U3(g,S)}));if(["number","string","boolean"].indexOf(typeof v)!==-1||v instanceof Date||v===null)u.push(U3(g,v,a));else if(Array.isArray(v)){var _=p,b=v.map(function(S){return hm(S,a,c)}).filter(function(S){return S}).map(function(S){return I0.indexOf(_)!==-1?"(".concat(S,")"):S});b.length&&(I0.indexOf(_)!==-1?b.length&&(_==="not"?u.push(Pk(b)):u.push("(".concat(b.join(" ".concat(_," ")),")"))):u.push(b.join(" ".concat(_," "))))}else if(I0.indexOf(g)!==-1){var C=g,b=Object.keys(v).map(function(A){var Z;return n((Z={},Z[A]=v[A],Z))});b.length&&(C==="not"?u.push(Pk(b)):u.push("(".concat(b.join(" ".concat(C," ")),")")))}else if(typeof v=="object")if("type"in v)u.push(U3(g,v,a));else{var T=Object.keys(v);T.forEach(function(S){var A;if(v[S]!==void 0)if(Mz.indexOf(S)!==-1)u.push("".concat(g," ").concat(S," ").concat(hs(v[S],a)));else if(I0.indexOf(S)!==-1)Array.isArray(v[S])?u.push(v[S].map(function(I){return"("+n(I,a,g)+")"}).join(" ".concat(S," "))):u.push("("+n(v[S],a,g)+")");else if($z.indexOf(S)!==-1){var Z=i(p.toLowerCase(),v[S],S,g);Z&&u.push(Z)}else if(S==="has")u.push("".concat(g," ").concat(S," ").concat(hs(v[S],a)));else if(S==="in"){var B=Array.isArray(v[S])?v[S]:v[S].value.map(function(I){return{type:v[S].type,value:I}});u.push(g+" in ("+B.map(function(I){return hs(I,a)}).join(",")+")")}else if(Oz.indexOf(S)!==-1)u.push("".concat(S,"(").concat(g,",").concat(hs(v[S],a),")"));else{var U=n((A={},A[S]=v[S],A),a,g);U&&u.push(U)}})}else throw new Error("Unexpected value type: ".concat(v));return u},[]);d=h.join(" and ")}return d}function i(o,a,c,d){var h="";if(typeof a=="string"||a instanceof String)h=Lz(o,a,c,d);else if(a){var u=Array.isArray(a)?a.reduce(function(v,g){return g.hasOwnProperty(qs)?(v.hasOwnProperty(qs)||(v[qs]=[]),v[qs].push(g[qs]),v):Sn(Sn({},v),g)},{}):a,p=n(u,e,o);h="".concat(d,"/").concat(c,"(").concat(p?"".concat(o,":").concat(p):"",")")}return h}}function Lz(r,e,t,n){var i="",o=t=="all"?"ne":"eq";return i="".concat(n,"/").concat(t,"(").concat(r,": ").concat(r," ").concat(o," '").concat(e,"')"),i}function Hz(r){return r=r.replace(/%/g,"%25"),r=r.replace(/\+/g,"%2B"),r=r.replace(/\//g,"%2F"),r=r.replace(/\?/g,"%3F"),r=r.replace(/#/g,"%23"),r=r.replace(/&/g,"%26"),r=r.replace(/'/g,"''"),r}function hs(r,e){if(typeof r=="string")return"'".concat(Hz(r),"'");if(r instanceof Date)return r.toISOString();if(typeof r=="number")return r;if(Array.isArray(r))return"[".concat(r.map(function(t){return hs(t)}).join(","),"]");if(r===null)return r;if(typeof r=="object")switch(r.type){case"raw":case"guid":return r.value;case"duration":return"duration'".concat(r.value,"'");case"binary":return"binary'".concat(r.value,"'");case"alias":return Array.isArray(e)&&e.push(r),"@".concat(r.name);case"json":return escape(JSON.stringify(r.value));case"decimal":return"".concat(r.value,"M");default:return Object.entries(r).filter(function(t){var n=t[1];return n!==void 0}).map(function(t){var n=t[0],i=t[1];return"".concat(n,"=").concat(hs(i,e))}).join(",")}return r}function Av(r){if(typeof r=="number")return r;if(typeof r=="string")return r.indexOf("/")===-1?r:r.split("/").reverse().reduce(function(t,n,i,o){return i===0?"$expand=".concat(n):i===o.length-1?"".concat(n,"(").concat(t,")"):"$expand=".concat(n,"(").concat(t,")")},"");if(Array.isArray(r))return"".concat(r.map(function(t){return Av(t)}).join(","));if(typeof r=="object"){var e=Object.keys(r);return e.some(function(t){return Zz.indexOf(t.toLowerCase())!==-1})?e.map(function(t){var n;switch(t){case"filter":n=hm(r[t]);break;case"orderBy":n=W6(r[t]);break;case"levels":case"count":case"skip":case"top":n="".concat(r[t]);break;default:n=Av(r[t])}return"$".concat(t.toLowerCase(),"=").concat(n)}).join(";"):e.map(function(t){var n=Av(r[t]);return n?"".concat(t,"(").concat(n,")"):t}).join(",")}return""}function bP(r){var e=Array.isArray(r)?r:[r],t=e.reduce(function(n,i){var o=i.aggregate,a=i.filter,c=i.groupBy,d=oR(i,["aggregate","filter","groupBy"]),h=Object.keys(d);if(h.length)throw new Error("Unsupported transform(s): ".concat(h));if(o&&n.push("aggregate(".concat(Nz(o),")")),a){var u=hm(a);u&&n.push("filter(".concat(hm(u),")"))}return c&&n.push("groupby(".concat(Dz(c),")")),n},[]);return t.join("/")||void 0}function Nz(r){var e=Array.isArray(r)?r:[r];return e.map(function(t){return typeof t=="string"?t:Object.keys(t).map(function(n){var i=t[n];if(!i.with&&i.as)return"".concat(n," as ").concat(i.as);if(!i.with)throw new Error("'with' property required for '".concat(n,"'"));if(!i.as)throw new Error("'as' property required for '".concat(n,"'"));return"".concat(n," with ").concat(i.with," as ").concat(i.as)})}).join(",")}function Dz(r){if(!r.properties)throw new Error("'properties' property required for groupBy");var e="(".concat(r.properties.join(","),")");return r.transform&&(e+=",".concat(bP(r.transform))),e}function W6(r,e){return e===void 0&&(e=""),Array.isArray(r)?r.map(function(t){return Array.isArray(t)&&t.length===2&&["asc","desc"].indexOf(t[1])!==-1?t.join(" "):t}).map(function(t){return"".concat(e).concat(String(t))}).join(","):typeof r=="object"?Object.entries(r).map(function(t){var n=t[0],i=t[1];return W6(i,"".concat(n,"/"))}).map(function(t){return"".concat(e).concat(t)}).join(","):"".concat(e).concat(String(r))}function Vz(r,e){var t=Object.getOwnPropertyNames(e).filter(function(n){return e[n]!==void 0&&e[n]!==""}).map(function(n){return"".concat(n,"=").concat(e[n])});return t.length?"".concat(r,"?").concat(t.join("&")):r}function Pk(r){return"not (".concat(r.join(" and "),")")}const Fz=r=>Object.keys(r).reduce((e,t)=>{var n;switch(t){case"type":return!((n=r[t])===null||n===void 0)&&n.length?Object.assign(Object.assign({},e),{[t]:{in:r[t]}}):e;default:return Object.assign(Object.assign({},e),{[t]:r[t]})}},{}),jz=r=>Object.entries(r).filter(([e,t])=>!!t).reduce((e,[t,n])=>{switch(t){case"filter":return Object.assign(Object.assign({},e),{[t]:Fz(n)});default:return Object.assign(Object.assign({},e),{[t]:r[t]})}},{}),zz=r=>typeof r=="string"?r:_P(jz(r)),Bz=(r,e)=>{var t;const n=(t=yc[r])!==null&&t!==void 0?t:r;switch(n){case yc.v2:throw new Io(r);default:{const{query:i,includeDeleted:o}=e,a=new URLSearchParams(zz(i));return a.append("api-version",n),o&&a.append("includeDeleted","true"),`/contexts/?${String(a)}`}}},Uz=(r,e,t)=>[Bz(r,e),t],qz=(r,e,t="json")=>(n,i)=>r[t](...Uz(e,n,i)),Wz=r=>Object.keys(r).reduce((e,t)=>{var n;switch(t){case"type":return!((n=r[t])===null||n===void 0)&&n.length?Object.assign(Object.assign({},e),{[t]:{in:r[t]}}):e;default:return Object.assign(Object.assign({},e),{[t]:r[t]})}},{}),Gz=r=>Object.entries(r).filter(([e,t])=>!!t).reduce((e,[t,n])=>{switch(t){case"filter":return Object.assign(Object.assign({},e),{[t]:Wz(n)});default:return Object.assign(Object.assign({},e),{[t]:r[t]})}},{}),Kz=r=>typeof r=="string"?r:_P(Gz(r)),Yz=(r,e)=>{var t;const n=(t=yc[r])!==null&&t!==void 0?t:r;switch(n){case yc.v2:throw new Io(r);default:{const{id:i,query:o}=e,a=new URLSearchParams(Kz(o||""));return a.append("api-version",n),`/contexts/${i}/relations?${String(a)}`}}},Qz=(r,e,t)=>[Yz(r,e),t],Xz=(r,e,t="json")=>(n,i)=>r[t](...Qz(e,n,i));class Jz{get Version(){return yc}constructor(e,t){this._client=e,this._method=t}get(e,...t){return Pz(this._client,e,this._method)(...t)}query(e,...t){return qz(this._client,e,this._method)(...t)}related(e,...t){return Xz(this._client,e,this._method)(...t)}}var eB=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};const xc=(r,e)=>{if(e in r)return r[e];const t=Object.values(r).find(n=>n===e);if(!t)throw new Error(`Version ${e} is not supported`);return t},Vm=r=>e=>eB(void 0,void 0,void 0,function*(){return r.parse(yield gf(e))});var Ze;(function(r){r.v1="1.0",r.v2="2.0"})(Ze||(Ze={}));const Mk=F.string().datetime({offset:!0}).transform(r=>new Date(r)),Gb={[Ze.v1]:F.object({azureUniqueId:F.string(),name:F.string(),mail:F.string().optional(),phoneNumber:F.string().optional(),jobTitle:F.string().optional(),accountType:F.enum(["Employee","Consultant","External","Application","Local"]).optional(),accountClassification:F.enum(["Unclassified","Internal","External"]).nullish()})},m4={[Ze.v1]:F.object({identifier:F.string(),name:F.string().nullish(),subSystem:F.string().nullish()})},tB={[Ze.v1]:F.object({id:F.string(),name:F.string().nullish(),type:F.string().nullish()})},kf={get[Ze.v1](){return F.object({id:F.string(),name:F.string(),appKey:F.string(),description:F.string().optional(),isShared:F.boolean().optional(),context:tB[Ze.v1].optional(),createdBy:Gb[Ze.v1],updatedBy:Gb[Ze.v1].optional(),created:Mk,updated:Mk.optional(),sourceSystem:m4[Ze.v1].nullish()})},get[Ze.v2](){return this[Ze.v1]}},G6={get[Ze.v1](){return F.record(F.unknown()).or(F.string()).optional().default("").transform(r=>{try{return typeof r=="string"?JSON.parse(r):r}catch{return r}})}},wP=r=>Object.entries(r).map(([e,t])=>{if(t===null)return`${e} eq null`;if(typeof t=="string")return`${e} eq '${t}'`;if(typeof t=="boolean")return`${e} eq ${t}`;if(typeof t=="object")return Object.entries(t).map(([n,i])=>`${e}.${n} eq '${i}'`).join(" and ")}).filter(e=>!!e).join(" and "),rB=F.object({appKey:F.string().optional(),contextId:F.string().optional(),sourceSystem:m4[Ze.v1].partial().optional()}).transform(wP),nB=F.object({appKey:F.string().optional(),contextId:F.string().optional(),sourceSystem:m4[Ze.v1].partial().optional(),isFavourite:F.boolean().optional()}).transform(wP),iB={[Ze.v1]:F.object({filter:F.string().or(rB).optional()}).optional(),[Ze.v2]:F.object({filter:F.string().or(nB).optional()}).optional()},oB={[Ze.v1]:F.array(kf[Ze.v1]),[Ze.v2]:F.array(kf[Ze.v2])},aB=(r,e,t)=>{switch(r){case Ze.v1:case Ze.v2:{const n={selector:Vm(oB[r])};return Object.assign({},n,t)}}throw Error(`Unknown API version: ${r}`)},sB=(r,e)=>{switch(r){case Ze.v1:case Ze.v2:{const t=new URLSearchParams;return t.append("api-version",r),e!=null&&e.filter&&t.append("$filter",e.filter),`/persons/me/bookmarks/?${String(t)}`}}throw Error(`Unknown API version: ${r}`)},cB=(r,e,t="json")=>{const n=xc(Ze,r);return(i,o)=>{const a=iB[n].parse(i),c=sB(n,a),d=aB(n,a,o);return e[t](c,d)}},lB={[Ze.v1]:F.object({bookmarkId:F.string()}),[Ze.v2]:F.object({bookmarkId:F.string()})},dB={[Ze.v1]:kf[Ze.v1],[Ze.v2]:kf[Ze.v2]},uB=(r,e,t)=>{switch(r){case Ze.v1:case Ze.v2:{const n={selector:Vm(dB[r])};return Object.assign({},n,t)}}throw Error(`Unknown API version: ${r}`)},hB=(r,e)=>{switch(r){case Ze.v1:case Ze.v2:{const t=new URLSearchParams;return t.append("api-version",r),`/bookmarks/${e.bookmarkId}?${String(t)}`}}throw Error(`Unknown API version: ${r}`)},fB=(r,e,t="json")=>{const n=xc(Ze,r);return(i,o)=>{const a=lB[n].parse(i);return e[t](hB(n,a),uB(n,a,o))}},pB={[Ze.v1]:F.object({name:F.string(),appKey:F.string(),payload:F.record(F.unknown()).or(F.string()).optional(),description:F.string().nullish(),isShared:F.boolean().nullish(),contextId:F.string().nullish(),sourceSystem:m4[Ze.v1].nullish()})},mB={[Ze.v1]:kf[Ze.v1].and(F.object({payload:G6[Ze.v1].optional()}))},vB=(r,e,t)=>{switch(r){case Ze.v1:{const n={method:"POST",selector:Vm(mB[r]),body:e};return Object.assign({},n,t)}}throw Error(`Unknown API version: ${r}`)},gB=(r,e)=>{switch(r){case Ze.v1:{const t=new URLSearchParams;return t.append("api-version",r),`/bookmarks?${String(t)}`}}throw Error(`Unknown API version: ${r}`)},yB=(r,e,t="json")=>{const n=xc(Ze,r);return(i,o)=>{const a=pB[n].parse(i);return e[t](gB(n),vB(n,a,o))}},_B={[Ze.v1]:F.object({bookmarkId:F.string(),updates:F.object({name:F.string().nullish(),description:F.string().nullish(),isShared:F.boolean().nullish(),payload:F.record(F.unknown()).or(F.string()).nullish().transform(r=>typeof r=="object"?JSON.stringify(r):r),sourceSystem:F.object({identifier:F.string().nullish(),name:F.string().nullish(),subSystem:F.string().nullish()}).nullish()})})},bB={[Ze.v1]:kf[Ze.v1].and(F.object({payload:G6[Ze.v1].optional()}))},wB=(r,e,t)=>{switch(r){case Ze.v1:{const n={method:"PATCH",selector:Vm(bB[r]),body:e.updates};return Object.assign({},n,t)}}throw Error(`Unknown API version: ${r}`)},xB=(r,e)=>{switch(r){case Ze.v1:{const t=new URLSearchParams;return t.append("api-version",r),`/bookmarks/${e.bookmarkId}?${String(t)}`}}throw Error(`Unknown API version: ${r}`)},CB=(r,e,t="json")=>{const n=xc(Ze,r);return(i,o)=>{const a=_B[n].parse(i);return e[t](xB(n,a),wB(n,a,o))}},kB={[Ze.v1]:F.object({bookmarkId:F.string()})},EB={[Ze.v1]:F.object({id:F.string(),payload:G6[Ze.v1]})},SB=(r,e,t)=>{switch(r){case Ze.v1:{const n={method:"GET",selector:Vm(EB[r])};return Object.assign({},n,t)}}throw Error(`Unknown API version: ${r}`)},TB=(r,e)=>{switch(r){case Ze.v1:{const t=new URLSearchParams;return t.append("api-version",r),`/bookmarks/${e.bookmarkId}/apply?${String(t)}`}}throw Error(`Unknown API version: ${r}`)},AB=(r,e,t="json")=>{const n=xc(Ze,r);return(i,o)=>{const a=kB[n].parse(i);return e[t](TB(n,a),SB(n,a,o))}};var xP=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};const K6=r=>xP(void 0,void 0,void 0,function*(){if(r.ok)return!0;const e=`Failed to execute request. Status code: ${r.status}`;let t,n;switch(r.status){case 403:case 404:try{n=yield r.json()}catch(i){t=i}}throw new cu(e,r,{cause:t,data:n})}),IB=r=>xP(void 0,void 0,void 0,function*(){if(r.ok)return!0;if(r.status===404)return!1;throw new su(`Failed to execute request. Status code: ${r.status}`,r)}),RB={[Ze.v1]:F.object({bookmarkId:F.string()})};Ze.v1+"",F.boolean();const PB=(r,e,t)=>{switch(r){case Ze.v1:return Object.assign({},{method:"POST",selector:K6,body:e},t)}throw Error(`Unknown API version: ${r}`)},MB=(r,e)=>{switch(r){case Ze.v1:{const t=new URLSearchParams;return t.append("api-version",r),`/persons/me/bookmarks/favourites?${String(t)}`}}throw Error(`Unknown API version: ${r}`)},$B=(r,e,t="json")=>{const n=xc(Ze,r);return(i,o)=>{const a=RB[n].parse(i);return e[t](MB(n),PB(n,a,o))}},OB={[Ze.v1]:F.object({bookmarkId:F.string()})};Ze.v1+"",F.boolean();const ZB=(r,e,t)=>{switch(r){case Ze.v1:return Object.assign({},{method:"DELETE",selector:K6},t)}throw Error(`Unknown API version: ${r}`)},LB=(r,e)=>{switch(r){case Ze.v1:{const t=new URLSearchParams;return t.append("api-version",r),`/bookmarks/${e.bookmarkId}?${String(t)}`}}throw Error(`Unknown API version: ${r}`)},HB=(r,e,t="json")=>{const n=xc(Ze,r);return(i,o)=>{const a=OB[n].parse(i);return e[t](LB(n,a),ZB(n,a,o))}},NB={[Ze.v1]:F.object({bookmarkId:F.string()})};Ze.v1+"",F.boolean();const DB=(r,e,t)=>{switch(r){case Ze.v1:return Object.assign({},{method:"HEAD",selector:IB},t)}throw Error(`Unknown API version: ${r}`)},VB=(r,e)=>{switch(r){case Ze.v1:{const t=new URLSearchParams;return t.append("api-version",r),`/persons/me/bookmarks/favourites/${e.bookmarkId}?${String(t)}`}}throw Error(`Unknown API version: ${r}`)},FB=(r,e,t="json")=>{const n=xc(Ze,r);return(i,o)=>{const a=NB[n].parse(i);return e[t](VB(n,a),DB(n,a,o))}},jB={[Ze.v1]:F.object({bookmarkId:F.string()})};Ze.v1+"",F.boolean();const zB=(r,e,t)=>{switch(r){case Ze.v1:return Object.assign({},{method:"DELETE",selector:K6},t)}throw Error(`Unknown API version: ${r}`)},BB=(r,e)=>{switch(r){case Ze.v1:{const t=new URLSearchParams;return t.append("api-version",r),`/persons/me/bookmarks/favourites/${e.bookmarkId}?${String(t)}`}}throw Error(`Unknown API version: ${r}`)},UB=(r,e,t="json")=>{const n=xc(Ze,r);return(i,o)=>{const a=jB[n].parse(i);return e[t](BB(n,a),zB(n,a,o))}};class qB{constructor(e,t){this._client=e,this._method=t}get(e,t,n){return fB(e,this._client,this._method)(t,n)}getPayload(e,t,n){return AB(e,this._client,this._method)(t,n)}query(e,t,n){return cB(e,this._client,this._method)(t,n)}patch(e,t,n){return CB(e,this._client,this._method)(t,n)}create(e,t,n){return yB(e,this._client,this._method)(t,n)}delete(e,t,n){return HB(e,this._client,this._method)(t,n)}isFavorite(e,t,n){return FB(e,this._client,this._method)(t,n)}addFavourite(e,t,n){return $B(e,this._client,this._method)(t,n)}removeFavourite(e,t,n){return UB(e,this._client,this._method)(t,n)}}const WB=(r,e)=>{var t;const n=(t=ei[r])!==null&&t!==void 0?t:r;switch(n){case ei.v2:throw new Io(r);default:{const{id:i}=e,o=new URLSearchParams;return o.append("api-version",n),`/notification/${i}/?${String(o)}`}}},GB=(r,e,t)=>[WB(r,e),t],KB=(r,e,t="json")=>(n,i)=>r[t](...GB(e,n,i)),YB=(r,e)=>{var t;const n=(t=ei[r])!==null&&t!==void 0?t:r;switch(n){case ei.v2:throw new Io(r);default:{const{userId:i}=e,o=new URLSearchParams;return o.append("api-version",n),`/person/${i}/notifications/?${String(o)}`}}},QB=(r,e,t)=>{const n=YB(r,e),i=new Headers;i.append("content-type","application/json");const o=Object.assign({},{method:"POST",body:JSON.stringify(e),headers:i},t);return[n,o]},XB=(r,e,t="json")=>(n,i)=>r[t](...QB(e,n,i)),JB=(r,e)=>{var t;const n=(t=ei[r])!==null&&t!==void 0?t:r;switch(n){case ei.v2:throw new Io(r);default:{const{id:i}=e,o=new URLSearchParams;return o.append("api-version",n),`/notification/${i}/?${String(o)}`}}},eU=(r,e,t)=>{const n=JB(r,e),i=new Headers;i.append("content-type","application/json");const o=Object.assign({},{method:"PATCH",body:JSON.stringify(e),headers:i},t);return[n,o]},tU=(r,e,t="json")=>(n,i)=>r[t](...eU(e,n,i)),rU=(r,e)=>{var t;const n=(t=ei[r])!==null&&t!==void 0?t:r;switch(n){case ei.v2:throw new Io(r);default:{const{userId:i}=e,o=new URLSearchParams;return o.append("api-version",n),`/person/${i}/notifications/?${String(o)}`}}},nU=(r,e,t)=>[rU(r,e),t],iU=(r,e,t="json")=>(n,i)=>r[t](...nU(e,n,i)),oU=(r,e)=>{var t;const n=(t=ei[r])!==null&&t!==void 0?t:r;switch(n){case ei.v2:throw new Io(r);default:{const{id:i}=e,o=new URLSearchParams;return o.append("api-version",n),`/notification/${i}/?${String(o)}`}}},aU=(r,e,t)=>{const n=oU(r,e),i=new Headers;i.append("content-type","application/json");const o=Object.assign({},{method:"DELETE",headers:i},t);return[n,o]},sU=(r,e,t="json")=>(n,i)=>r[t](...aU(e,n,i));var ei;(function(r){r.v1="1.0",r.v2="2.0"})(ei||(ei={}));const cU=(r,e)=>{var t;const n=(t=ei[r])!==null&&t!==void 0?t:r;switch(n){case ei.v2:throw new Io(r);default:{const{userId:i}=e,o=new URLSearchParams;return o.append("api-version",n),`/person/${i}/notifications/settings/?${String(o)}`}}},lU=(r,e,t)=>{const n=cU(r,e),i=new Headers;i.append("content-type","application/json");const o=Object.assign({},{method:"PUT",body:JSON.stringify(e),headers:i},t);return[n,o]},dU=(r,e,t="json")=>(n,i)=>r[t](...lU(e,n,i)),uU=(r,e)=>{var t;const n=(t=ei[r])!==null&&t!==void 0?t:r;switch(n){case ei.v2:throw new Io(r);default:{const{userId:i}=e,o=new URLSearchParams;return o.append("api-version",n),`/person/${i}/notifications/settings/?${String(o)}`}}},hU=(r,e,t)=>[uU(r,e),t],fU=(r,e,t="json")=>(n,i)=>r[t](...hU(e,n,i));class pU{get Version(){return ei}constructor(e,t){this._client=e,this._method=t}getAll(e,...t){return iU(this._client,e,this._method)(...t)}getById(e,...t){return KB(this._client,e,this._method)(...t)}setSeenByUser(e,...t){return tU(this._client,e,this._method)(...t)}create(e,...t){return XB(this._client,e,this._method)(...t)}delete(e,...t){return sU(this._client,e,this._method)(...t)}getSettings(e,...t){return fU(this._client,e,this._method)(...t)}updateSettings(e,...t){return dU(this._client,e,this._method)(...t)}}var oa;(function(r){r.v2="2.0",r.v4="4.0"})(oa||(oa={}));const mU=(r,e)=>{var t;const n=(t=oa[r])!==null&&t!==void 0?t:r;switch(n){case oa.v4:{const{azureId:i,expand:o}=e,a=new URLSearchParams;return a.append("api-version",n),o&&a.append("$expand",o.join(",")),`/persons/${i}?${String(a)}`}default:throw new Io(r)}},vU=(r,e,t)=>[mU(r,e),t],gU=(r,e,t="json")=>(n,i)=>r[t](...vU(e,n,i)),yU=(r,e)=>{var t;const n=(t=oa[r])!==null&&t!==void 0?t:r;switch(n){case oa.v2:{const{search:i}=e,o=new URLSearchParams;return o.append("api-version",n),o.append("$search",i),`/persons?${String(o)}`}default:throw new Io(r)}},_U=(r,e,t)=>[yU(r,e),t],bU=(r,e,t="json")=>(n,i)=>r[t](..._U(e,n,i)),wU=(r,e)=>{var t;const n=(t=oa[r])!==null&&t!==void 0?t:r;switch(n){case oa.v2:{const{azureId:i}=e,o=new URLSearchParams;return o.append("api-version",n),`/persons/${i}/photo?${String(o)}`}default:throw new Io(r)}},xU=(r,e,t)=>[wU(r,e),t],CU=(r,e,t="blob")=>(n,i)=>r[t](...xU(e,n,i));class kU{get Version(){return oa}constructor(e){this._client=e}get(e,t,n,i){return gU(this._client,e,t)(n,i)}query(e,t,n,i){return bU(this._client,e,t)(n,i)}photo(e,t,n,i){return CU(this._client,e,t)(n,i)}}var mp=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};class EU extends Error{constructor(e,t,n){super(e,n),this.response=t,this.name="ApiProviderError"}}const q3=r=>mp(void 0,void 0,void 0,function*(){var e;if(!r.ok){const{headers:t,status:n,statusText:i,type:o,url:a,bodyUsed:c}=r,d=(e=t.get("content-type"))===null||e===void 0?void 0:e.match(/application\/(\w*)?[+]?json/),h=!c&&(yield d?r.json():r.text());throw new EU("failed to execute request, response was not ok",{headers:t,status:n,statusText:i,type:o,url:a,data:h})}});class SU{constructor({createClient:e}){this._createClientFn=e}createNotificationClient(e){return mp(this,void 0,void 0,function*(){const t=yield this._createClientFn("notification");return t.responseHandler.add("validate_api_request",q3),new pU(t,e)})}createBookmarksClient(e){return mp(this,void 0,void 0,function*(){const t=yield this._createClientFn("bookmarks");return new qB(t,e)})}createContextClient(e){return mp(this,void 0,void 0,function*(){const t=yield this._createClientFn("context");return t.responseHandler.add("validate_api_request",q3),new Jz(t,e)})}createPeopleClient(){return mp(this,void 0,void 0,function*(){const e=yield this._createClientFn("people");return e.responseHandler.add("validate_api_request",q3),new kU(e)})}}var CP=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};const TU="services",AU=(r,e)=>t=>CP(void 0,void 0,void 0,function*(){if(r.hasClient(t))return r.createClient(t);if(e)return e.createClient(t);throw Error(`failed to create http client for service ${t}`)}),kP={name:TU,configure:()=>new Az,initialize:r=>CP(void 0,[r],void 0,function*({ref:e,config:t,requireInstance:n,hasModule:i}){if(!t.createClient){const o=yield n("http"),a=i("serviceDiscovery")?yield n("serviceDiscovery"):e==null?void 0:e.serviceDiscovery;t.createClient=AU(o,a)}if(!t.createClient)throw Error("missing configuration for creating API client");return new SU(t)})},IU=r=>{r.addConfig({module:kP})};class RU extends WN{constructor(){super([tD,tk,A6,Tz,kP,pz]),this.logger=new iR("FrameworkConfigurator")}configureHttp(...e){this.addConfig(xV(...e))}configureHttpClient(...e){this.addConfig(YR(...e))}configureMsal(e,t=!0){this.addConfig({module:tk,configure:n=>{t!==void 0&&n.setRequiresAuth(!!t),typeof e=="function"&&e(n),typeof e=="object"&&n.setClientConfig(e)}})}configureServiceDiscovery(e){this.configureHttpClient("service_discovery",e.client)}}var PU=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};const MU=(r,e)=>PU(void 0,void 0,void 0,function*(){const t=yield r.initialize(e),n={modules:t};return window.Fusion=n,t.event.dispatchEvent("onFrameworkLoaded",{detail:n}),n});var x=s6();const or=Hu(x),Y6=XI({__proto__:null,default:or},[x]),EP=x.createContext(null),$U=EP.Provider,SP=x.createContext({}),OU=SP.Provider,TP=()=>x.useContext(SP),ZU=r=>TP()[r];var LU=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};const HU=(r,e)=>x.lazy(()=>LU(void 0,void 0,void 0,function*(){const t=new RU;yield r(t,e);const n=yield MU(t,e);return{default:({children:i})=>k.jsx($U,{value:n,children:k.jsx(OU,{value:n.modules,children:i})})}})),Ll=()=>{let r=x.useContext(EP);return r||console.warn("could not locate fusion in context!"),r??(r=window.Fusion),r||console.error("Could not load framework, might not be initiated?"),r},Q6=r=>{const t=Ll().modules[r];return t||console.warn(`the requested module [${t}] is not included in the framework instance`),t},NU=r=>{const{configure:e,fallback:t,children:n}=r,i=TP(),o=x.useMemo(()=>HU(e,i),[e,i]);return k.jsx(x.Suspense,{fallback:t,children:k.jsx(o,{children:n})})};function br(){return br=Object.assign?Object.assign.bind():function(r){for(var e=1;e<arguments.length;e++){var t=arguments[e];for(var n in t)({}).hasOwnProperty.call(t,n)&&(r[n]=t[n])}return r},br.apply(null,arguments)}function Ef(r){"@babel/helpers - typeof";return Ef=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Ef(r)}function W3(r){return r&&Ef(r)==="object"&&r.constructor===Object}function AP(r,e){var t=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{clone:!0},n=t.clone?br({},r):r;return W3(r)&&W3(e)&&Object.keys(e).forEach(function(i){i!=="__proto__"&&(W3(e[i])&&i in r?n[i]=AP(r[i],e[i],t):n[i]=e[i])}),n}function DU(r,e){if(Ef(r)!="object"||!r)return r;var t=r[Symbol.toPrimitive];if(t!==void 0){var n=t.call(r,e);if(Ef(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(r)}function VU(r){var e=DU(r,"string");return Ef(e)=="symbol"?e:e+""}var FU=typeof Symbol=="function"&&Symbol.for;const IP=FU?Symbol.for("mui.nested"):"__THEME_NESTED__";var jU=["checked","disabled","error","focused","focusVisible","required","expanded","selected"];function zU(){var r=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},e=r.disableGlobal,t=e===void 0?!1:e,n=r.productionPrefix,i=n===void 0?"jss":n,o=r.seed,a=o===void 0?"":o,c=a===""?"":"".concat(a,"-"),d=0,h=function(){return d+=1,d};return function(u,p){var v=p.options.name;if(v&&v.indexOf("Mui")===0&&!p.options.link&&!t){if(jU.indexOf(u.key)!==-1)return"Mui-".concat(u.key);var g="".concat(c).concat(v,"-").concat(u.key);return!p.options.theme[IP]||a!==""?g:"".concat(g,"-").concat(h())}return"".concat(c).concat(i).concat(h())}}var $k=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(r){return typeof r}:function(r){return r&&typeof Symbol=="function"&&r.constructor===Symbol&&r!==Symbol.prototype?"symbol":typeof r},Fm=(typeof window>"u"?"undefined":$k(window))==="object"&&(typeof document>"u"?"undefined":$k(document))==="object"&&document.nodeType===9;function BU(r,e){for(var t=0;t<e.length;t++){var n=e[t];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(r,VU(n.key),n)}}function RP(r,e,t){return e&&BU(r.prototype,e),Object.defineProperty(r,"prototype",{writable:!1}),r}function Kb(r,e){return Kb=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,n){return t.__proto__=n,t},Kb(r,e)}function PP(r,e){r.prototype=Object.create(e.prototype),r.prototype.constructor=r,Kb(r,e)}function Ok(r){if(r===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return r}function MP(r,e){if(r==null)return{};var t={};for(var n in r)if({}.hasOwnProperty.call(r,n)){if(e.indexOf(n)!==-1)continue;t[n]=r[n]}return t}var UU={}.constructor;function Yb(r){if(r==null||typeof r!="object")return r;if(Array.isArray(r))return r.map(Yb);if(r.constructor!==UU)return r;var e={};for(var t in r)e[t]=Yb(r[t]);return e}function X6(r,e,t){r===void 0&&(r="unnamed");var n=t.jss,i=Yb(e),o=n.plugins.onCreateRule(r,i,t);return o||(r[0],null)}var Zk=function(e,t){for(var n="",i=0;i<e.length&&e[i]!=="!important";i++)n&&(n+=t),n+=e[i];return n},uu=function(e){if(!Array.isArray(e))return e;var t="";if(Array.isArray(e[0]))for(var n=0;n<e.length&&e[n]!=="!important";n++)t&&(t+=", "),t+=Zk(e[n]," ");else t=Zk(e,", ");return e[e.length-1]==="!important"&&(t+=" !important"),t};function zf(r){return r&&r.format===!1?{linebreak:"",space:""}:{linebreak:`
78
+ `);return o!==-1&&(e=Fj(e,i,n,o)),n+e+i};Object.defineProperties(Nm.prototype,Cf);const xk=Nm();Nm({level:bk?bk.level:0});const Wj=r=>{if(typeof r!="string")throw new Error("Expected LogLevel key to be a string.");const e=r.toLowerCase(),t=Object.keys(un).find(n=>n.toLowerCase()===e);if(!t)throw new Error(`Failed to parse LogLevel from string: ${r}.`);return un[t]},Gj=r=>{const e=Number(r);if(Object.values(un).includes(e))return e;if(isNaN(e))return Wj(r);throw Error(`Invalid log level: ${r}`)};var Kj={},un;(function(r){r[r.None=0]="None",r[r.Error=1]="Error",r[r.Warning=2]="Warning",r[r.Info=3]="Info",r[r.Debug=4]="Debug"})(un||(un={}));const Yj=()=>{const r=Kj.FUSION_LOG_LEVEL;if(r)try{return Gj(r)}catch{return un.Error}return un.Error},Qj=Yj(),Xj="1.1.2";class Jj{constructor(){this.level=Qj,this.version=Xj,this._log$=new Bn}get log(){return this._log$.pipe($e(e=>this.level>=e.lvl))}debug(...e){this._log$.next({lvl:un.Debug,msg:this._createMessage(un.Debug,...e)})}info(...e){this._log$.next({lvl:un.Info,msg:this._createMessage(un.Info,...e)})}warn(...e){this._log$.next({lvl:un.Warning,msg:this._createMessage(un.Warning,...e)})}error(...e){this._log$.next({lvl:un.Error,msg:this._createMessage(un.Error,...e)})}}class Dm extends Jj{constructor(e,t){super(),this.title=e,this.subtitle=t,this.log.subscribe(({lvl:n,msg:i})=>{switch(n){case un.Debug:console.debug(...i);break;case un.Info:console.info(...i);break;case un.Warning:console.warn(...i);break;case un.Error:console.error(...i);break}})}_createMessage(e,...t){return[this._formatTitle(e),...t]}_formatTitle(e){const t=xk.magenta([this.title,this.subtitle].filter(n=>!!n).join(" - "));switch(e){case un.Warning:case un.Error:return xk.bold(t)}return t}createSubLogger(e,t,n){const i=new Dm(`${this.title}::${e}`,t??this.subtitle);return i.level=n===void 0?this.level:n,i}}var ts=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},Ck=function(r,e,t,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?r!==e||!i:!e.has(r))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(r,t):i?i.value=t:e.set(r,t),t},Yc,xh,T0;class ez extends Tt{get status(){return ts(this,Yc,"f").value}get status$(){return ts(this,Yc,"f").asObservable()}get transaction(){return ts(this,T0,"f")}get closed(){return this.status==="complete"||this.status==="error"||this.status==="canceled"}constructor(e,t,n){super(o=>{const{transaction:a}=this,c=e.action$.pipe($e(d=>d.meta.transaction===a));o.add(e.state$.pipe($e(d=>!!d[a]),me(d=>d[a])).subscribe(d=>{ts(this,Yc,"f").next(d.status)})),o.add(c.pipe($e(ir.execute.success.match),me(({payload:d})=>d)).subscribe(d=>{ts(this,Yc,"f").next("complete"),o.next(d),o.complete()})),o.add(c.pipe($e(ir.error.match),me(({payload:d})=>d)).subscribe(d=>{ts(this,Yc,"f").next("error"),o.error(d.error)})),o.add(c.pipe($e(ir.cancel.match)).subscribe(d=>{ts(this,Yc,"f").next("canceled"),o.error(new jd("abort",{message:d.payload.reason||`job: ${a} was canceled`,request:ts(this,xh,"f").getRequest(d.meta.transaction)}))})),n!=null&&n.signal&&o.add(iu(n==null?void 0:n.signal,"abort").pipe(me(()=>ir.cancel(a,`job: ${a} was aborted on signal from caller: ${n==null?void 0:n.ref}`))).subscribe(d=>e.next(d))),o.add(()=>{this.complete()})}),Yc.set(this,new Df("idle")),xh.set(this,void 0),T0.set(this,void 0),this.created=Date.now(),Ck(this,xh,e,"f");const i=ir.request(t,{ref:n==null?void 0:n.ref,retry:n==null?void 0:n.retry});Ck(this,T0,i.meta.transaction,"f"),ts(this,xh,"f").next(i)}complete(e){this.closed||this.cancel(e??`job: ${this.transaction} was completed`)}cancel(e){const t=this.transaction;ts(this,xh,"f").cancel(t,e??`job: ${t} was canceled`)}[(Yc=new WeakMap,xh=new WeakMap,T0=new WeakMap,Symbol.dispose)](){this.complete()}}var tz=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})},Jt=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},z3=function(r,e,t,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?r!==e||!i:!e.has(r))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(r,t):i?i.value=t:e.set(r,t),t},Hr,Md,is;class kk extends Tt{get closed(){return Jt(this,Hr,"f").closed}get state$(){return Jt(this,Hr,"f").asObservable()}get action$(){return Jt(this,Hr,"f").action$}get success$(){return this.action$.pipe($e(ir.execute.success.match),me(({payload:e})=>e))}get error$(){return this.action$.pipe(dm("client/error"),Up(Jt(this,Hr,"f")),me(([e,t])=>{const{payload:n,meta:{transaction:i}}=e,o=t[i];return new jd("error",{request:o,message:`job: ${i} failed`,cause:n})}))}constructor(e,t){var n;super(i=>Jt(this,Hr,"f").subscribe(i)),Hr.set(this,void 0),Md.set(this,void 0),is.set(this,void 0),z3(this,Hr,new Lm(Zj({})),"f"),z3(this,Md,new ti(()=>Jt(this,Hr,"f").complete()),"f"),Jt(this,Md,"f").add(Jt(this,Hr,"f").addFlow(Mj)),Jt(this,Md,"f").add(Jt(this,Hr,"f").addFlow($j(e))),Jt(this,Md,"f").add(Jt(this,Hr,"f").addFlow(Oj(Object.assign({count:0,delay:0},t==null?void 0:t.retry)))),z3(this,is,(n=t==null?void 0:t.logger)!==null&&n!==void 0?n:new Dm("QueryClient"),"f"),Jt(this,Hr,"f").addEffect(ir.request.type,({payload:i,meta:{transaction:o}})=>{Jt(this,is,"f").debug("Job requested",{transaction:o,payload:i})}),Jt(this,Hr,"f").addEffect(ir.execute.type,({payload:i,meta:{transaction:o}})=>{Jt(this,is,"f").debug("Job executing",{transaction:o,payload:i})}),Jt(this,Hr,"f").addEffect(ir.execute.success.type,({payload:i})=>{Jt(this,is,"f").info("Job complete",Object.assign({},i))}),Jt(this,Hr,"f").addEffect(ir.execute.failure.type,({payload:i,meta:{transaction:o}})=>{Jt(this,is,"f").debug("Job failed",{transaction:o,payload:i})}),Jt(this,Hr,"f").addEffect(ir.cancel.type,({payload:{reason:i},meta:{transaction:o}})=>{Jt(this,is,"f").debug("Job canceled",{transaction:o,reason:i})}),Jt(this,Hr,"f").addEffect(ir.error.type,({payload:{transaction:i,error:o}})=>{Jt(this,is,"f").error("Job error",{transaction:i,error:o})})}next(e){Jt(this,Hr,"f").next(e)}query(e,t){const n=new ez(this,e,t),i=n.pipe(Vf({connector:()=>new uR,resetOnRefCountZero:!1}));return Object.defineProperties(i,{transaction:{get:()=>n.transaction},created:{get:()=>n.created},status:{get:()=>n.status},closed:{get:()=>n.closed},cancel:{value:o=>n.cancel(o)},complete:{value:()=>n.complete()}}),i}nextAsync(e,t){return tz(this,void 0,void 0,function*(){return zn(this.query(e,t))})}getRequest(e){return Jt(this,Hr,"f").value[e]}getRequestByRef(e){return Object.values(Jt(this,Hr,"f").value).find(t=>t.ref===e)}cancelTaskByRef(e,t){const n=this.getRequestByRef(e);n!=null&&n.ref&&this.cancel(n.transaction,t)}cancel(e,t){if(e)Jt(this,Hr,"f").value[e]?(t??(t=`cancelation requested for job: ${e}`),Jt(this,Hr,"f").next(ir.cancel(e,t))):Jt(this,is,"f").warn("Task not registered, nothing to cancel",{transaction:e,reason:t});else for(const n of Object.keys(Jt(this,Hr,"f").value))this.cancel(n,"all transactions requested canceled")}on(e,t){return Jt(this,Hr,"f").addEffect(ir[e].type,n=>{t(n,this)})}complete(){Jt(this,Md,"f").unsubscribe()}}Hr=new WeakMap,Md=new WeakMap,is=new WeakMap;function rz(){return{set:on("cache/set",(r,e)=>({payload:{key:r,record:e}})),insert:on("cache/insert",(r,e)=>({payload:{key:r,entry:e}})),remove:on("cache/remove",r=>({payload:r})),invalidate:on("cache/invalidate",(r,e)=>({payload:r,meta:{item:e}})),mutate:on("cache/mutate",(r,e,t)=>({payload:Object.assign(Object.assign({},e),{key:r}),meta:{item:t}})),trim:on("cache/trim",r=>({payload:r}))}}const Qc=rz(),nz=(r,e)=>{var t,n;return((t=e.updated)!==null&&t!==void 0?t:0)-((n=r.updated)!==null&&n!==void 0?n:0)};function iz(r,e={}){return Hm(e,t=>t.addCase(r.set,(n,i)=>{const{key:o,record:a}=i.payload;n[o]=a}).addCase(r.insert,(n,i)=>{var o;const{key:a,entry:c}=i.payload,d=n[a];if(d)d.updated=Date.now(),(o=d.updates)!==null&&o!==void 0||(d.updates=0),d.updates++,d.value=c.value,d.transaction=c.transaction,d.mutated=void 0;else{const h=Date.now();n[a]=Object.assign(Object.assign({},c),{created:h,updated:h})}}).addCase(r.remove,(n,i)=>{delete n[i.payload]}).addCase(r.invalidate,(n,i)=>{const o=i.payload?[i.payload]:Object.keys(n);for(const a of o){const c=n[a];c&&(c.updated=void 0)}}).addCase(r.mutate,(n,i)=>{var o;const{key:a,value:c,updated:d}=i.payload,h=n[a];h&&(h.value=c,h.updated=d,h.mutated=Date.now(),(o=h.updates)!==null&&o!==void 0||(h.updates=0),h.updates++)}).addCase(r.trim,(n,i)=>{var o,a;const{payload:c}=i,d=(o=c.sort)!==null&&o!==void 0?o:nz,h=Object.keys(n),u=Object.entries(n).filter(([p,v])=>!c.validate||c.validate(v)).sort((p,v)=>d(p[1],v[1])).slice(0,(a=c.size)!==null&&a!==void 0?a:Number.MAX_SAFE_INTEGER).map(([p])=>p);if(h.length!==u.length)for(const p of h){const v=u.indexOf(p);v!==-1?u.splice(v,1):delete n[p]}}))}var Dn=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},oz=function(r,e,t,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?r!==e||!i:!e.has(r))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(r,t):i?i.value=t:e.set(r,t),t},yn;class Ek{get state(){return Dn(this,yn,"f").value}get state$(){return Dn(this,yn,"f").asObservable()}get action$(){return Dn(this,yn,"f").action$}constructor(e){yn.set(this,void 0);const{trimming:t,initial:n}=e??{};oz(this,yn,new Lm(iz(Qc,n)),"f"),t&&Dn(this,yn,"f").addEffect("cache/set",()=>Dn(this,yn,"f").next(Qc.trim(t)))}has(e){return e in Dn(this,yn,"f").value}setItem(e,t){const{args:n,transaction:i,value:o}=t;Dn(this,yn,"f").next(Qc.insert(e,{args:n,transaction:i,value:o}))}getItem(e){return Dn(this,yn,"f").value[e]}removeItem(e){Dn(this,yn,"f").next(Qc.remove(e))}invalidate(e){const t=e?Dn(this,yn,"f").value[e]:void 0;Dn(this,yn,"f").next(Qc.invalidate(e,t))}mutate(e,t){const n=e in Dn(this,yn,"f").value?Dn(this,yn,"f").value[e]:void 0;if(!n)throw new Error(`Cannot mutate cache item with key ${e}: item not found`);const i=typeof t=="function"?t(n==null?void 0:n.value):t;return Dn(this,yn,"f").next(Qc.mutate(e,i,n)),()=>Dn(this,yn,"f").next(Qc.set(e,n))}trim(e){Dn(this,yn,"f").next(Qc.trim(e))}reset(){Dn(this,yn,"f").reset()}complete(){Dn(this,yn,"f").complete()}}yn=new WeakMap;var Sk=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},qb,Wb;class az extends Bn{get created(){return Sk(this,qb,"f")}get uuid(){return Sk(this,Wb,"f")}constructor(e,t,n){super(),this.key=e,this.args=t,this.options=n,qb.set(this,Date.now()),Wb.set(this,sm())}processJob(e,t){return e.pipe(me(n=>{const{key:i,uuid:o,created:a}=this;return{key:i,uuid:o,created:a,status:"complete",transaction:e.transaction,complete:n.completed,value:n.value}}),ng(()=>{t==null||t.debug("QueryTask complete",{uuid:this.uuid,key:this.key,job:{status:e.status,transaction:e.transaction}}),e.complete()})).subscribe(this)}}qb=new WeakMap,Wb=new WeakMap;var pt=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},vd=function(r,e,t,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?r!==e||!i:!e.has(r))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(r,t):i?i.value=t:e.set(r,t),t},sz=function(r,e){var t={};for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&e.indexOf(n)<0&&(t[n]=r[n]);if(r!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,n=Object.getOwnPropertySymbols(r);i<n.length;i++)e.indexOf(n[i])<0&&Object.prototype.propertyIsEnumerable.call(r,n[i])&&(t[n[i]]=r[n[i]]);return t},$d,il,Yo,dp,Qs,ol,up,Cv,Vn;const cz=(r=0)=>e=>{var t;return((t=e.updated)!==null&&t!==void 0?t:0)+r>Date.now()},lz=(r="switch")=>typeof r=="function"?r:(()=>{switch(r){case"concat":return rj;case"merge":return nj;case"switch":return ij;default:throw new Error(`Invalid queue operator: ${r}`)}})();class xi{get client(){return pt(this,il,"f")}get cache(){return pt(this,Yo,"f")}constructor(e){var t,n;$d.set(this,new ti),il.set(this,void 0),Yo.set(this,void 0),dp.set(this,new Bn),Qs.set(this,{}),ol.set(this,void 0),up.set(this,void 0),Cv.set(this,sm()),Vn.set(this,void 0),vd(this,Vn,(t=e.logger)!==null&&t!==void 0?t:new Dm("Query",pt(this,Cv,"f")),"f"),vd(this,ol,o=>L6(e.key(o),pt(this,Cv,"f")),"f"),vd(this,up,(n=e==null?void 0:e.validate)!==null&&n!==void 0?n:cz(e==null?void 0:e.expire),"f"),e.client instanceof kk?vd(this,il,e.client,"f"):(vd(this,il,new kk(e.client.fn,Object.assign({logger:pt(this,Vn,"f").createSubLogger("Client")},e.client.options)),"f"),pt(this,$d,"f").add(()=>pt(this,il,"f").complete())),e.cache instanceof Ek?vd(this,Yo,e.cache,"f"):(vd(this,Yo,new Ek(e.cache||{}),"f"),pt(this,$d,"f").add(()=>pt(this,Yo,"f").complete()));const i=lz(e.queueOperator);pt(this,$d,"f").add(()=>pt(this,dp,"f").complete()),pt(this,$d,"f").add(pt(this,dp,"f").pipe(Br(o=>pt(this,Vn,"f").debug("Task added to queue",{key:o})),$e(o=>o in pt(this,Qs,"f")),i(o=>{const a=pt(this,Qs,"f")[o],{args:c,options:d,uuid:h}=a;if(pt(this,Vn,"f").debug("Task selected from queue",{key:o,task:a.uuid,args:c,options:d}),!(a!=null&&a.observed))return pt(this,Vn,"f").debug("Task skipped",{task:h}),delete pt(this,Qs,"f")[o],Tr;const u=pt(this,il,"f").query(c,Object.assign(Object.assign({},d),{ref:a.uuid}));return new Tt(p=>{const{transaction:v}=u;pt(this,Vn,"f").info("Task stated",{task:h,transaction:v}),p.add(()=>{pt(this,Vn,"f").debug("Task closed",{task:h,transaction:v,jobStatus:u.status}),u.complete("task closed"),delete pt(this,Qs,"f")[o]}),p.add(LN(10).pipe($e(()=>!a.observed)).subscribe(()=>{u.cancel(`task: ${a.uuid} is not observed`),p.complete()})),p.add(a.processJob(u,pt(this,Vn,"f"))),u.pipe(me(g=>({result:g,task:a})),Vt(()=>Tr)).subscribe(p)})}),MR(()=>!pt(this,il,"f").closed)).subscribe(o=>{const{value:a,transaction:c}=o.result,{args:d,key:h,uuid:u}=o.task;pt(this,Vn,"f").debug("Task output added to cache",{uuid:u,args:d,key:h,transaction:c,value:a}),pt(this,Yo,"f").setItem(h,{value:a,args:d,transaction:c})}))}query(e,t){return this._query(e,t)}queryAsync(e,t){const n=t||{},{skipResolve:i}=n,o=sz(n,["skipResolve"]),a=i?zn:lr;return new Promise((c,d)=>{t!=null&&t.signal&&t.signal.addEventListener("abort",()=>d(new Error("Query aborted"))),a(this._query(e,o).pipe(C6())).then(c,d)})}persistentQuery(e,t){const n=pt(this,ol,"f").call(this,e),i=this._query(e,t);return new Tt(o=>{var a;o.add(i.subscribe({next:o.next.bind(o),error:o.error.bind(o)}));const c=((a=t==null?void 0:t.cache)===null||a===void 0?void 0:a.validate)||pt(this,up,"f");o.add(this.cache.state$.pipe($e(d=>n in d),me(d=>Object.assign(Object.assign({},d[n]),{key:n,status:"cache",hasValidCache:c(d[n],e)}))).subscribe(o))}).pipe(rg((o,a)=>o.transaction===a.transaction&&o.mutated===a.mutated))}generateCacheKey(e){return pt(this,ol,"f").call(this,e)}mutate(e,t,n){const i=pt(this,ol,"f").call(this,e);if(!(i in this.cache.state)){if((n==null?void 0:n.allowCreation)===void 0)throw new Error(`Cannot mutate cache item with key ${i}: item not found and option "allowCreation" is false`);if(n.allowCreation===!1)return()=>{};const{value:o}=typeof t=="function"?t():t;this.cache.setItem(i,{args:e,transaction:sm(),value:o})}return pt(this,Yo,"f").mutate(i,t)}invalidate(e){pt(this,Yo,"f").invalidate(e&&pt(this,ol,"f").call(this,e))}complete(){pt(this,$d,"f").unsubscribe()}onInvalidate(e){const t=pt(this,Yo,"f").action$.pipe(dm("cache/invalidate")).subscribe(n=>e({detail:{item:n.meta.item}}));return()=>t.unsubscribe()}onMutate(e){const t=pt(this,Yo,"f").action$.pipe(dm("cache/mutate")).subscribe(n=>e({detail:{changes:n.payload,current:n.meta.item}}));return()=>t.unsubscribe()}_query(e,t){const n=pt(this,ol,"f").call(this,e),i=this._createTask(n,e,t);return pt(this,Vn,"f").debug("New query created",{key:n,args:e,options:t}),i}_createTask(e,t,n){return new Tt(i=>{var o,a,c,d,h;if(n!=null&&n.signal){if(n!=null&&n.signal.aborted)return pt(this,Vn,"f").debug("Abort signal already triggered by caller",{key:e}),i.complete();i.add(iu(n==null?void 0:n.signal,"abort").subscribe(()=>{pt(this,Vn,"f").debug("Abort signal triggered by caller",{key:e}),i.complete()}))}const u=pt(this,Yo,"f").getItem(e);if(u){pt(this,Vn,"f").debug("Query has cache",{key:e,cacheEntry:u});const g=(a=(o=n==null?void 0:n.cache)===null||o===void 0?void 0:o.suppressInvalid)!==null&&a!==void 0?a:!1,b=(((c=n==null?void 0:n.cache)===null||c===void 0?void 0:c.validate)||pt(this,up,"f"))(u,t),C=Object.assign(Object.assign({},u),{key:e,status:"cache",hasValidCache:b});if(pt(this,Vn,"f").info("Query cache valid, completing",{hasValidCache:b,suppressInvalid:g,record:C}),i.next(C),b||g)return i.complete();pt(this,Vn,"f").debug("Query cache entry is invalid, proceeding to fetch new data",{key:e})}const p=e in pt(this,Qs,"f");(d=(h=pt(this,Qs,"f"))[e])!==null&&d!==void 0||(h[e]=new az(e,t,n));const v=pt(this,Qs,"f")[e];i.add(v.subscribe(i)),pt(this,Vn,"f").info(p?"Query connected to existing task":"Query started new task",{key:e}),p||pt(this,dp,"f").next(e)})}}$d=new WeakMap,il=new WeakMap,Yo=new WeakMap,dp=new WeakMap,Qs=new WeakMap,ol=new WeakMap,up=new WeakMap,Cv=new WeakMap,Vn=new WeakMap;xi.extractQueryValue=lf;var Xc=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},Tk=function(r,e,t,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?r!==e||!i:!e.has(r))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(r,t):i?i.value=t:e.set(r,t),t},hp,Xs;class dz extends Tt{get currentContext(){return Xc(this,Xs,"f").value}get currentContext$(){return Xc(this,Xs,"f").asObservable()}get client(){return Xc(this,hp,"f")}constructor(e){super(t=>Xc(this,Xs,"f").subscribe(t)),hp.set(this,void 0),Xs.set(this,void 0),Tk(this,hp,new xi(e),"f"),Tk(this,Xs,new Df(void 0),"f")}setCurrentContext(e){typeof e=="string"?this.resolveContext(e).pipe(Vt(()=>Tr)).subscribe(t=>this.setCurrentContext(t)):Nb(e,Xc(this,Xs,"f").value)||Xc(this,Xs,"f").next(e)}resolveContext(e){return Xc(this,hp,"f").query({id:e}).pipe(me(t=>t.value),Vt(t=>{throw t.cause?t.cause:t}))}resolveContextAsync(e,t){return(t!=null&&t.awaitResolve?lr:zn)(this.resolveContext(e))}dispose(){Xc(this,Xs,"f").complete()}}hp=new WeakMap,Xs=new WeakMap;var H1=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})},cr=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},gd=function(r,e,t,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?r!==e||!i:!e.has(r))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(r,t):i?i.value=t:e.set(r,t),t},Js,kv,fp,Ta,Od,Zd,pp,Ev,Sv;let uz=class{get contextClient(){return cr(this,Js,"f")}get queryClient(){return cr(this,kv,"f")}get currentContext$(){return cr(this,Js,"f").currentContext$}get currentContext(){return cr(this,Js,"f").currentContext}set currentContext(e){if(console.warn("@deprecated","ContextProvider.currentContext","use setCurrentContextById|setCurrentContext|clearCurrentContext"),e===void 0)throw Error("not allowed to set current context as undefined undefined!");this.setCurrentContextAsync(e)}constructor(e){var t,n,i;Js.set(this,void 0),kv.set(this,void 0),fp.set(this,void 0),Ta.set(this,void 0),Od.set(this,new ti),Zd.set(this,void 0),pp.set(this,void 0),Ev.set(this,void 0),Sv.set(this,new Bn);const{config:o,event:a}=e;e.parentContext&&console.warn("@deprecated","parentContext as arg is deprecated, use ContextProvider.connectParentContext"),gd(this,Ta,a,"f"),o.resolveContext&&(this.resolveContext=(t=o.resolveContext)===null||t===void 0?void 0:t.bind(this)),o.validateContext&&(this.validateContext=(n=o.validateContext)===null||n===void 0?void 0:n.bind(this)),gd(this,Zd,o.contextType,"f"),gd(this,pp,o.contextFilter,"f"),gd(this,Js,new dz(o.client.get),"f"),gd(this,kv,new xi(o.client.query),"f"),o.client.related&&gd(this,fp,new xi(o.client.related),"f"),gd(this,Ev,(i=o.contextParameterFn)!==null&&i!==void 0?i:c=>({search:c.search,filter:{type:c.type}}),"f"),cr(this,Ta,"f")&&(cr(this,Od,"f").add(this.currentContext$.pipe(ig()).subscribe(([c,d])=>{var h;(h=cr(this,Ta,"f"))===null||h===void 0||h.dispatchEvent("onCurrentContextChanged",{source:this,canBubble:!0,detail:{previous:c,next:d}})})),cr(this,Od,"f").add(cr(this,Ta,"f").addEventListener("onCurrentContextChanged",c=>{c.source!==this&&c.detail.next!==void 0&&this.setCurrentContext(c.detail.next)}))),cr(this,Od,"f").add(cr(this,Sv,"f").pipe(Wt(c=>c),Br(c=>console.debug("ContextProvider::#contextQueue",c))).subscribe(c=>{cr(this,Js,"f").setCurrentContext(c??null)}))}connectParentContext(e,t){const i=e.currentContext$.pipe($e(o=>o!==void 0),$e((o,a)=>{var c;return t!=null&&t.skipFirst&&a<=1?(console.debug("ContextProvider::connectParentContext","skipping first item",o),!1):((c=this.currentContext)===null||c===void 0?void 0:c.id)!==(o==null?void 0:o.id)}),Wt(o=>H1(this,void 0,void 0,function*(){var a;if(!o)return{next:o};const c=yield(a=cr(this,Ta,"f"))===null||a===void 0?void 0:a.dispatchEvent("onParentContextChanged",{source:this,detail:o,cancelable:!0});return{next:o,canceled:c==null?void 0:c.canceled}})),$e(o=>!o.canceled),Wt(({next:o})=>this.setCurrentContext(o,{validate:!0,resolve:!0}).pipe(Vt(a=>(console.warn("ContextProvider::onParentContextChanged","setCurrentContext",a),Tr)))),Vt(o=>(console.warn("ContextProvider::onParentContextChanged","unhandled exception",o),Tr))).subscribe();return cr(this,Od,"f").add(i),i}setCurrentContextById(e){return new Tt(t=>{try{cr(this,Js,"f").resolveContext(e).pipe($e(n=>!!n),Wt(n=>this.setCurrentContext(n))).subscribe(t)}catch(n){t.error(n)}})}setCurrentContextByIdAsync(e){return lr(this.setCurrentContextById(e))}setCurrentContext(e,t){const n=new Bn,i=new Bn,o=this._setCurrentContext(e,t).pipe(Br(a=>i.next(a)),ou(n),ng(()=>i.complete()),Vt(a=>(i.error(a),Tr)));return cr(this,Sv,"f").next(o),i.pipe(ng(()=>n.next(!0)))}_setCurrentContext(e,t){return new Tt(n=>{var i;if(e===this.currentContext)return n.next(e),n.complete();if(e&&(t!=null&&t.validate)&&!this.validateContext(e)){if(!t.resolve)return(i=cr(this,Ta,"f"))===null||i===void 0||i.dispatchEvent("onSetContextValidationFailed",{source:this,detail:{context:e}}),n.error(Error("failed to validate provided context"));if(t.resolve)return It(e).pipe(Wt(o=>H1(this,void 0,void 0,function*(){var a;const c=yield(a=cr(this,Ta,"f"))===null||a===void 0?void 0:a.dispatchEvent("onSetContextResolve",{source:this,cancelable:!0,detail:{context:o}});if(c!=null&&c.canceled)throw Error("resolving of context was canceled");return o})),Wt(o=>this.resolveContext(o).pipe(me(a=>({context:o,resolved:a})))),Wt(o=>H1(this,[o],void 0,function*({context:a,resolved:c}){var d;const h=yield(d=cr(this,Ta,"f"))===null||d===void 0?void 0:d.dispatchEvent("onSetContextResolved",{source:this,cancelable:!0,detail:{context:a,resolved:c}});if(h!=null&&h.canceled)throw Error("resolving of context was canceled");return c})),Wt(o=>this._setCurrentContext(o))).subscribe(n)}return It(e).pipe(Wt(o=>H1(this,void 0,void 0,function*(){var a;const c=yield(a=cr(this,Ta,"f"))===null||a===void 0?void 0:a.dispatchEvent("onCurrentContextChange",{source:this,canBubble:!0,cancelable:!0,detail:{context:o}});if(c!=null&&c.canceled)throw Error("change of context was aborted");return o}))).subscribe(o=>{n.next(o),n.complete()})})}setCurrentContextAsync(e,t){return H1(this,void 0,void 0,function*(){return lr(this.setCurrentContext(e,t))})}queryContext(e){const t=this.queryClient.query(cr(this,Ev,"f").call(this,{search:e,type:cr(this,Zd,"f")})).pipe(Vt(n=>{throw n.name==="QueryClientError"?n.cause:n}),me(n=>n.value));return cr(this,pp,"f")?t.pipe(me(cr(this,pp,"f"))):t}queryContextAsync(e){return lr(this.queryContext(e))}validateContext(e){return cr(this,Zd,"f")?cr(this,Zd,"f").map(t=>t.toLowerCase()).includes(e.type.id.toLowerCase()):!0}resolveContext(e){return this.relatedContexts({item:e,filter:{type:cr(this,Zd,"f")}}).pipe(me(t=>t.filter(n=>this.validateContext(n))),me(t=>{const n=t.shift();if(!n)throw Error("failed to resolve context");return t.length&&console.warn("ContextProvider::relatedContext","multiple items found 🤣",t),n}))}resolveContextAsync(e){return lr(this.resolveContext(e))}relatedContexts(e){return cr(this,fp,"f")?cr(this,fp,"f").query(e).pipe(me(({value:t})=>t),Vt(t=>{throw t.cause?t.cause:t})):kR(()=>Error("ContextProvider::relatedContexts - no client defined for resolving related context"))}relatedContextsAsync(e){return lr(this.relatedContexts(e))}clearCurrentContext(){this.setCurrentContext(null)}dispose(){cr(this,Od,"f").unsubscribe(),cr(this,Js,"f").dispose()}};Js=new WeakMap,kv=new WeakMap,fp=new WeakMap,Ta=new WeakMap,Od=new WeakMap,Zd=new WeakMap,pp=new WeakMap,Ev=new WeakMap,Sv=new WeakMap;var hz=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};const fz="context",pz={name:fz,configure:()=>new JF,initialize:function(r){return hz(this,void 0,void 0,function*(){var e;const t=yield r.config.createConfig(r),n=r.hasModule("event")?yield r.requireInstance("event"):void 0,i=(e=r.ref)===null||e===void 0?void 0:e.context,o=new uz({config:t,event:n,parentContext:i}),a=new ti(()=>o.dispose());return this.postInitialize=c=>new Tt(d=>{const h=t.resolveInitialContext?rt(t.resolveInitialContext(c)).pipe($e(u=>!!u),Wt(u=>c.modules.context.setCurrentContext(u,{validate:!0,resolve:!0}))):Tr;d.add(h.pipe(Vt(u=>(console.warn("ContextModule.postInitialize","failed to resolve initial context",u),Tr))).subscribe({next:u=>{console.debug("ContextModule.postInitialize",`initial context was resolved to [${u?u.id:"none"}]`,u)},complete:()=>{t.connectParentContext!==!1&&i&&o.connectParentContext(i),d.complete()}}))}),this.dispose=()=>a.unsubscribe(),o})}},mz=F.object({key:F.string().describe("The key used to identify the service"),uri:F.string().describe("The URI of the service"),id:F.string().optional().describe("The ID of the service"),environment:F.string().optional().describe("The environment of the service"),name:F.string().optional().describe("The name of the service"),scopes:F.array(F.string()).optional().default([]).describe("Endpoint authentication scopes"),tags:F.array(F.string()).optional().describe("Tags for the service")}).describe("A service from the service discovery API").transform(r=>Object.assign(Object.assign({},r),{get defaultScopes(){var e;return console.warn("The `defaultScopes` property is deprecated. Use `scopes` instead."),(e=r.scopes)!==null&&e!==void 0?e:[]}})),vz=F.array(mz).describe("A list of services from the service discovery API");var gz=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})},yz=function(r,e,t,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?r!==e||!i:!e.has(r))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(r,t):i?i.value=t:e.set(r,t),t},_z=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},Tv;const bz="services",wz=r=>rt(gf(r)).pipe(me(e=>vz.default([]).parse(e)));class xz{constructor({http:e,endpoint:t}){Tv.set(this,void 0),this.http=e,this.endpoint=t,yz(this,Tv,new xi({client:{fn:()=>e.fetch$(t??"",{selector:wz})},key:()=>bz,expire:5*60*1e3}),"f")}resolveServices(e){return(e?zn:lr)(xi.extractQueryValue(_z(this,Tv,"f").query()))}resolveService(e,t){return gz(this,void 0,void 0,function*(){const i=(yield this.resolveServices(t)).find(o=>o.key===e);if(!i)throw Error(`Failed to resolve service, invalid key [${e}]`);return i})}}Tv=new WeakMap;var A0=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};class Cz extends Mm{_createConfig(e,t){const n=Object.create(null,{_createConfig:{get:()=>super._createConfig}});return A0(this,void 0,void 0,function*(){if(!e.hasModule("http"))throw new Error("http module is required");return this._has("discoveryClient")||(yield e.requireInstance("http")).hasClient("service_discovery")&&this.configureServiceDiscoveryClientByClientKey("service_discovery"),lr(rt(n._createConfig.call(this,e,t)))})}_processConfig(e,t){if(!e.discoveryClient)throw new Error("discoveryClient is required, please configure it");return super._processConfig(e,t)}setServiceDiscoveryClient(e){this._set("discoveryClient",typeof e=="function"?e:()=>A0(this,void 0,void 0,function*(){return e}))}configureServiceDiscoveryClient(e){this.setServiceDiscoveryClient(t=>A0(this,void 0,void 0,function*(){var n;const{httpClient:i,endpoint:o}=(n=yield lr(rt(e(t))))!==null&&n!==void 0?n:{};if(i)return new xz({http:i,endpoint:o});throw Error("httpClient is required")}))}configureServiceDiscoveryClientByClientKey(e,t){this.configureServiceDiscoveryClient(n=>A0(this,[n],void 0,function*({requireInstance:i}){return{httpClient:(yield i("http")).createClient(e),endpoint:t}}))}}var B3=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};class kz{constructor(e,t){this.config=e,this._http=t}resolveServices(){return this.config.discoveryClient.resolveServices()}resolveService(e){return B3(this,void 0,void 0,function*(){return this.config.discoveryClient.resolveService(e)})}createClient(e,t){return B3(this,void 0,void 0,function*(){const n=yield this.resolveService(e);if(!n)throw Error(`Could not load configuration of service [${e}]`);return this._http.createClient(Object.assign(Object.assign({},t),{baseUri:n.uri,defaultScopes:n.scopes}))})}configureClient(e,t){return B3(this,void 0,void 0,function*(){const{key:n,alias:i}=typeof e=="string"?{key:e,alias:e}:e,{uri:o,scopes:a}=yield this.resolveService(n);t.addConfig(YR(i,{baseUri:o,defaultScopes:a}))})}}var Ez=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};const Sz="serviceDiscovery",Tz={name:Sz,configure:()=>new Cz,initialize:r=>Ez(void 0,void 0,void 0,function*(){var e;const{requireInstance:t,ref:n}=r,i=yield r.config.createConfigAsync(r,Object.assign({},(e=n==null?void 0:n.serviceDiscovery)===null||e===void 0?void 0:e.config)),o=yield t("http");return new kz(i,o)})};class Az{}var yc;(function(r){r.v1="1.0",r.v2="2.0"})(yc||(yc={}));class Io extends Error{constructor(e,t){super(`unsupported version ${e}`,{cause:t}),this.version=e}}const Iz=(r,e)=>{var t;const n=(t=yc[r])!==null&&t!==void 0?t:r;switch(n){case yc.v2:throw new Io(r);default:{const{id:i}=e,o=new URLSearchParams;return o.append("api-version",n),`/contexts/${i}/?${String(o)}`}}},Rz=(r,e,t)=>[Iz(r,e),t],Pz=(r,e,t="json")=>(n,i)=>r[t](...Rz(e,n,i));var Mz=["eq","ne","gt","ge","lt","le"],I0=["and","or","not"],$z=["any","all"],Oz=["startswith","endswith","contains","matchespattern"],Zz=["expand","levels","select","skip","top","count","orderby","filter"],Ak=/\((.*)\)/,Ik=/(?!indexof)\((\w+)\)/,Rk;(function(r){r.sum="sum",r.min="min",r.max="max",r.average="average",r.countdistinct="countdistinct"})(Rk||(Rk={}));var qs="";function _P(r){var e=r===void 0?{}:r,t=e.select,n=e.search,i=e.skiptoken,o=e.format,a=e.top,c=e.skip,d=e.filter,h=e.transform,u=e.orderBy,p=e.key,v=e.count,g=e.expand,_=e.action,b=e.func,C="",T=[],S={};if(p!=null&&(C+="(".concat(hs(p,T),")")),(d||typeof v=="object")&&(S.$filter=hm(typeof v=="object"?v:d,T)),h&&(S.$apply=bP(h)),g&&(S.$expand=Av(g)),u&&(S.$orderby=W6(u)),v&&(typeof v=="boolean"?S.$count=!0:C+="/$count"),typeof a=="number"&&(S.$top=a),typeof c=="number"&&(S.$skip=c),_&&(C+="/".concat(_)),b){if(typeof b=="string")C+="/".concat(b);else if(typeof b=="object"){var A=Object.keys(b)[0],Z=hs(b[A],T);C+="/".concat(A),Z!==""&&(C+="(".concat(Z,")"))}}return T.length>0&&Object.assign(S,T.reduce(function(B,U){var I;return Object.assign(B,(I={},I["@".concat(U.name)]=hs(U.value),I))},{})),Vz(C,Sn({$select:t,$search:n,$skiptoken:i,$format:o},S))}function U3(r,e,t){return t===void 0&&(t=[]),"".concat(r," eq ").concat(hs(e,t))}function hm(r,e,t){return r===void 0&&(r={}),e===void 0&&(e=[]),t===void 0&&(t=""),(Array.isArray(r)?r:[r]).reduce(function(o,a){if(a){var c=n(a,e,t);c&&o.push(c)}return o},[]).join(" and ");function n(o,a,c){o===void 0&&(o={}),a===void 0&&(a=[]),c===void 0&&(c="");var d="";if(typeof o=="string")d=o;else if(o&&typeof o=="object"){var h=Object.keys(o).reduce(function(u,p){var v=o[p];if(v===void 0)return u;var g="";if(c?p===qs?g=c:Ik.test(p)?g=p.replace(Ik,function(S,A){return A.trim()===qs?"(".concat(c,")"):"(".concat(c,"/").concat(A.trim(),")")}):Ak.test(p)?g=p.replace(Ak,function(S,A){return A.trim()===qs?"(".concat(c,")"):"(".concat(c,"/").concat(A.trim(),")")}):g="".concat(c,"/").concat(p):g=p,p===qs&&Array.isArray(v))return u.concat(v.map(function(S){return U3(g,S)}));if(["number","string","boolean"].indexOf(typeof v)!==-1||v instanceof Date||v===null)u.push(U3(g,v,a));else if(Array.isArray(v)){var _=p,b=v.map(function(S){return hm(S,a,c)}).filter(function(S){return S}).map(function(S){return I0.indexOf(_)!==-1?"(".concat(S,")"):S});b.length&&(I0.indexOf(_)!==-1?b.length&&(_==="not"?u.push(Pk(b)):u.push("(".concat(b.join(" ".concat(_," ")),")"))):u.push(b.join(" ".concat(_," "))))}else if(I0.indexOf(g)!==-1){var C=g,b=Object.keys(v).map(function(A){var Z;return n((Z={},Z[A]=v[A],Z))});b.length&&(C==="not"?u.push(Pk(b)):u.push("(".concat(b.join(" ".concat(C," ")),")")))}else if(typeof v=="object")if("type"in v)u.push(U3(g,v,a));else{var T=Object.keys(v);T.forEach(function(S){var A;if(v[S]!==void 0)if(Mz.indexOf(S)!==-1)u.push("".concat(g," ").concat(S," ").concat(hs(v[S],a)));else if(I0.indexOf(S)!==-1)Array.isArray(v[S])?u.push(v[S].map(function(I){return"("+n(I,a,g)+")"}).join(" ".concat(S," "))):u.push("("+n(v[S],a,g)+")");else if($z.indexOf(S)!==-1){var Z=i(p.toLowerCase(),v[S],S,g);Z&&u.push(Z)}else if(S==="has")u.push("".concat(g," ").concat(S," ").concat(hs(v[S],a)));else if(S==="in"){var B=Array.isArray(v[S])?v[S]:v[S].value.map(function(I){return{type:v[S].type,value:I}});u.push(g+" in ("+B.map(function(I){return hs(I,a)}).join(",")+")")}else if(Oz.indexOf(S)!==-1)u.push("".concat(S,"(").concat(g,",").concat(hs(v[S],a),")"));else{var U=n((A={},A[S]=v[S],A),a,g);U&&u.push(U)}})}else throw new Error("Unexpected value type: ".concat(v));return u},[]);d=h.join(" and ")}return d}function i(o,a,c,d){var h="";if(typeof a=="string"||a instanceof String)h=Lz(o,a,c,d);else if(a){var u=Array.isArray(a)?a.reduce(function(v,g){return g.hasOwnProperty(qs)?(v.hasOwnProperty(qs)||(v[qs]=[]),v[qs].push(g[qs]),v):Sn(Sn({},v),g)},{}):a,p=n(u,e,o);h="".concat(d,"/").concat(c,"(").concat(p?"".concat(o,":").concat(p):"",")")}return h}}function Lz(r,e,t,n){var i="",o=t=="all"?"ne":"eq";return i="".concat(n,"/").concat(t,"(").concat(r,": ").concat(r," ").concat(o," '").concat(e,"')"),i}function Hz(r){return r=r.replace(/%/g,"%25"),r=r.replace(/\+/g,"%2B"),r=r.replace(/\//g,"%2F"),r=r.replace(/\?/g,"%3F"),r=r.replace(/#/g,"%23"),r=r.replace(/&/g,"%26"),r=r.replace(/'/g,"''"),r}function hs(r,e){if(typeof r=="string")return"'".concat(Hz(r),"'");if(r instanceof Date)return r.toISOString();if(typeof r=="number")return r;if(Array.isArray(r))return"[".concat(r.map(function(t){return hs(t)}).join(","),"]");if(r===null)return r;if(typeof r=="object")switch(r.type){case"raw":case"guid":return r.value;case"duration":return"duration'".concat(r.value,"'");case"binary":return"binary'".concat(r.value,"'");case"alias":return Array.isArray(e)&&e.push(r),"@".concat(r.name);case"json":return escape(JSON.stringify(r.value));case"decimal":return"".concat(r.value,"M");default:return Object.entries(r).filter(function(t){var n=t[1];return n!==void 0}).map(function(t){var n=t[0],i=t[1];return"".concat(n,"=").concat(hs(i,e))}).join(",")}return r}function Av(r){if(typeof r=="number")return r;if(typeof r=="string")return r.indexOf("/")===-1?r:r.split("/").reverse().reduce(function(t,n,i,o){return i===0?"$expand=".concat(n):i===o.length-1?"".concat(n,"(").concat(t,")"):"$expand=".concat(n,"(").concat(t,")")},"");if(Array.isArray(r))return"".concat(r.map(function(t){return Av(t)}).join(","));if(typeof r=="object"){var e=Object.keys(r);return e.some(function(t){return Zz.indexOf(t.toLowerCase())!==-1})?e.map(function(t){var n;switch(t){case"filter":n=hm(r[t]);break;case"orderBy":n=W6(r[t]);break;case"levels":case"count":case"skip":case"top":n="".concat(r[t]);break;default:n=Av(r[t])}return"$".concat(t.toLowerCase(),"=").concat(n)}).join(";"):e.map(function(t){var n=Av(r[t]);return n?"".concat(t,"(").concat(n,")"):t}).join(",")}return""}function bP(r){var e=Array.isArray(r)?r:[r],t=e.reduce(function(n,i){var o=i.aggregate,a=i.filter,c=i.groupBy,d=oR(i,["aggregate","filter","groupBy"]),h=Object.keys(d);if(h.length)throw new Error("Unsupported transform(s): ".concat(h));if(o&&n.push("aggregate(".concat(Nz(o),")")),a){var u=hm(a);u&&n.push("filter(".concat(hm(u),")"))}return c&&n.push("groupby(".concat(Dz(c),")")),n},[]);return t.join("/")||void 0}function Nz(r){var e=Array.isArray(r)?r:[r];return e.map(function(t){return typeof t=="string"?t:Object.keys(t).map(function(n){var i=t[n];if(!i.with&&i.as)return"".concat(n," as ").concat(i.as);if(!i.with)throw new Error("'with' property required for '".concat(n,"'"));if(!i.as)throw new Error("'as' property required for '".concat(n,"'"));return"".concat(n," with ").concat(i.with," as ").concat(i.as)})}).join(",")}function Dz(r){if(!r.properties)throw new Error("'properties' property required for groupBy");var e="(".concat(r.properties.join(","),")");return r.transform&&(e+=",".concat(bP(r.transform))),e}function W6(r,e){return e===void 0&&(e=""),Array.isArray(r)?r.map(function(t){return Array.isArray(t)&&t.length===2&&["asc","desc"].indexOf(t[1])!==-1?t.join(" "):t}).map(function(t){return"".concat(e).concat(String(t))}).join(","):typeof r=="object"?Object.entries(r).map(function(t){var n=t[0],i=t[1];return W6(i,"".concat(n,"/"))}).map(function(t){return"".concat(e).concat(t)}).join(","):"".concat(e).concat(String(r))}function Vz(r,e){var t=Object.getOwnPropertyNames(e).filter(function(n){return e[n]!==void 0&&e[n]!==""}).map(function(n){return"".concat(n,"=").concat(e[n])});return t.length?"".concat(r,"?").concat(t.join("&")):r}function Pk(r){return"not (".concat(r.join(" and "),")")}function Fz(r){return Object.keys(r).reduce((e,t)=>{var n;switch(t){case"type":!((n=r[t])===null||n===void 0)&&n.length&&(e[t]={in:r[t]});break;default:e[t]=r[t];break}return e},{})}function jz(r){return Object.entries(r).filter(([e,t])=>!!t).reduce((e,[t,n])=>{switch(t){case"filter":e[t]=Fz(n);break;default:e[t]=r[t];break}return e},{})}function zz(r){return typeof r=="string"?r:_P(jz(r))}const Bz=(r,e)=>{var t;const n=(t=yc[r])!==null&&t!==void 0?t:r;switch(n){case yc.v2:throw new Io(r);default:{const{query:i,includeDeleted:o}=e,a=new URLSearchParams(zz(i));return a.append("api-version",n),o&&a.append("includeDeleted","true"),`/contexts/?${String(a)}`}}},Uz=(r,e,t)=>[Bz(r,e),t],qz=(r,e,t="json")=>(n,i)=>r[t](...Uz(e,n,i));function Wz(r){return Object.keys(r).reduce((e,t)=>{var n;switch(t){case"type":!((n=r[t])===null||n===void 0)&&n.length&&(e[t]={in:r[t]});break;default:e[t]=r[t];break}return e},{})}function Gz(r){return Object.entries(r).filter(([e,t])=>!!t).reduce((e,[t,n])=>{switch(t){case"filter":e[t]=Wz(n);break;default:e[t]=r[t];break}return e},{})}function Kz(r){return typeof r=="string"?r:_P(Gz(r))}const Yz=(r,e)=>{var t;const n=(t=yc[r])!==null&&t!==void 0?t:r;switch(n){case yc.v2:throw new Io(r);default:{const{id:i,query:o}=e,a=new URLSearchParams(Kz(o||""));return a.append("api-version",n),`/contexts/${i}/relations?${String(a)}`}}},Qz=(r,e,t)=>[Yz(r,e),t],Xz=(r,e,t="json")=>(n,i)=>r[t](...Qz(e,n,i));class Jz{get Version(){return yc}constructor(e,t){this._client=e,this._method=t}get(e,...t){return Pz(this._client,e,this._method)(...t)}query(e,...t){return qz(this._client,e,this._method)(...t)}related(e,...t){return Xz(this._client,e,this._method)(...t)}}var eB=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};const xc=(r,e)=>{if(e in r)return r[e];const t=Object.values(r).find(n=>n===e);if(!t)throw new Error(`Version ${e} is not supported`);return t},Vm=r=>e=>eB(void 0,void 0,void 0,function*(){return r.parse(yield gf(e))});var Ze;(function(r){r.v1="1.0",r.v2="2.0"})(Ze||(Ze={}));const Mk=F.string().datetime({offset:!0}).transform(r=>new Date(r)),Gb={[Ze.v1]:F.object({azureUniqueId:F.string(),name:F.string(),mail:F.string().optional(),phoneNumber:F.string().optional(),jobTitle:F.string().optional(),accountType:F.enum(["Employee","Consultant","External","Application","Local"]).optional(),accountClassification:F.enum(["Unclassified","Internal","External"]).nullish()})},m4={[Ze.v1]:F.object({identifier:F.string(),name:F.string().nullish(),subSystem:F.string().nullish()})},tB={[Ze.v1]:F.object({id:F.string(),name:F.string().nullish(),type:F.string().nullish()})},kf={get[Ze.v1](){return F.object({id:F.string(),name:F.string(),appKey:F.string(),description:F.string().optional(),isShared:F.boolean().optional(),context:tB[Ze.v1].optional(),createdBy:Gb[Ze.v1],updatedBy:Gb[Ze.v1].optional(),created:Mk,updated:Mk.optional(),sourceSystem:m4[Ze.v1].nullish()})},get[Ze.v2](){return this[Ze.v1]}},G6={get[Ze.v1](){return F.record(F.unknown()).or(F.string()).optional().default("").transform(r=>{try{return typeof r=="string"?JSON.parse(r):r}catch{return r}})}},wP=r=>Object.entries(r).map(([e,t])=>{if(t===null)return`${e} eq null`;if(typeof t=="string")return`${e} eq '${t}'`;if(typeof t=="boolean")return`${e} eq ${t}`;if(typeof t=="object")return Object.entries(t).map(([n,i])=>`${e}.${n} eq '${i}'`).join(" and ")}).filter(e=>!!e).join(" and "),rB=F.object({appKey:F.string().optional(),contextId:F.string().optional(),sourceSystem:m4[Ze.v1].partial().optional()}).transform(wP),nB=F.object({appKey:F.string().optional(),contextId:F.string().optional(),sourceSystem:m4[Ze.v1].partial().optional(),isFavourite:F.boolean().optional()}).transform(wP),iB={[Ze.v1]:F.object({filter:F.string().or(rB).optional()}).optional(),[Ze.v2]:F.object({filter:F.string().or(nB).optional()}).optional()},oB={[Ze.v1]:F.array(kf[Ze.v1]),[Ze.v2]:F.array(kf[Ze.v2])},aB=(r,e,t)=>{switch(r){case Ze.v1:case Ze.v2:{const n={selector:Vm(oB[r])};return Object.assign({},n,t)}}throw Error(`Unknown API version: ${r}`)},sB=(r,e)=>{switch(r){case Ze.v1:case Ze.v2:{const t=new URLSearchParams;return t.append("api-version",r),e!=null&&e.filter&&t.append("$filter",e.filter),`/persons/me/bookmarks/?${String(t)}`}}throw Error(`Unknown API version: ${r}`)},cB=(r,e,t="json")=>{const n=xc(Ze,r);return(i,o)=>{const a=iB[n].parse(i),c=sB(n,a),d=aB(n,a,o);return e[t](c,d)}},lB={[Ze.v1]:F.object({bookmarkId:F.string()}),[Ze.v2]:F.object({bookmarkId:F.string()})},dB={[Ze.v1]:kf[Ze.v1],[Ze.v2]:kf[Ze.v2]},uB=(r,e,t)=>{switch(r){case Ze.v1:case Ze.v2:{const n={selector:Vm(dB[r])};return Object.assign({},n,t)}}throw Error(`Unknown API version: ${r}`)},hB=(r,e)=>{switch(r){case Ze.v1:case Ze.v2:{const t=new URLSearchParams;return t.append("api-version",r),`/bookmarks/${e.bookmarkId}?${String(t)}`}}throw Error(`Unknown API version: ${r}`)},fB=(r,e,t="json")=>{const n=xc(Ze,r);return(i,o)=>{const a=lB[n].parse(i);return e[t](hB(n,a),uB(n,a,o))}},pB={[Ze.v1]:F.object({name:F.string(),appKey:F.string(),payload:F.record(F.unknown()).or(F.string()).optional(),description:F.string().nullish(),isShared:F.boolean().nullish(),contextId:F.string().nullish(),sourceSystem:m4[Ze.v1].nullish()})},mB={[Ze.v1]:kf[Ze.v1].and(F.object({payload:G6[Ze.v1].optional()}))},vB=(r,e,t)=>{switch(r){case Ze.v1:{const n={method:"POST",selector:Vm(mB[r]),body:e};return Object.assign({},n,t)}}throw Error(`Unknown API version: ${r}`)},gB=(r,e)=>{switch(r){case Ze.v1:{const t=new URLSearchParams;return t.append("api-version",r),`/bookmarks?${String(t)}`}}throw Error(`Unknown API version: ${r}`)},yB=(r,e,t="json")=>{const n=xc(Ze,r);return(i,o)=>{const a=pB[n].parse(i);return e[t](gB(n),vB(n,a,o))}},_B={[Ze.v1]:F.object({bookmarkId:F.string(),updates:F.object({name:F.string().nullish(),description:F.string().nullish(),isShared:F.boolean().nullish(),payload:F.record(F.unknown()).or(F.string()).nullish().transform(r=>typeof r=="object"?JSON.stringify(r):r),sourceSystem:F.object({identifier:F.string().nullish(),name:F.string().nullish(),subSystem:F.string().nullish()}).nullish()})})},bB={[Ze.v1]:kf[Ze.v1].and(F.object({payload:G6[Ze.v1].optional()}))},wB=(r,e,t)=>{switch(r){case Ze.v1:{const n={method:"PATCH",selector:Vm(bB[r]),body:e.updates};return Object.assign({},n,t)}}throw Error(`Unknown API version: ${r}`)},xB=(r,e)=>{switch(r){case Ze.v1:{const t=new URLSearchParams;return t.append("api-version",r),`/bookmarks/${e.bookmarkId}?${String(t)}`}}throw Error(`Unknown API version: ${r}`)},CB=(r,e,t="json")=>{const n=xc(Ze,r);return(i,o)=>{const a=_B[n].parse(i);return e[t](xB(n,a),wB(n,a,o))}},kB={[Ze.v1]:F.object({bookmarkId:F.string()})},EB={[Ze.v1]:F.object({id:F.string(),payload:G6[Ze.v1]})},SB=(r,e,t)=>{switch(r){case Ze.v1:{const n={method:"GET",selector:Vm(EB[r])};return Object.assign({},n,t)}}throw Error(`Unknown API version: ${r}`)},TB=(r,e)=>{switch(r){case Ze.v1:{const t=new URLSearchParams;return t.append("api-version",r),`/bookmarks/${e.bookmarkId}/apply?${String(t)}`}}throw Error(`Unknown API version: ${r}`)},AB=(r,e,t="json")=>{const n=xc(Ze,r);return(i,o)=>{const a=kB[n].parse(i);return e[t](TB(n,a),SB(n,a,o))}};var xP=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};const K6=r=>xP(void 0,void 0,void 0,function*(){if(r.ok)return!0;const e=`Failed to execute request. Status code: ${r.status}`;let t,n;switch(r.status){case 403:case 404:try{n=yield r.json()}catch(i){t=i}}throw new cu(e,r,{cause:t,data:n})}),IB=r=>xP(void 0,void 0,void 0,function*(){if(r.ok)return!0;if(r.status===404)return!1;throw new su(`Failed to execute request. Status code: ${r.status}`,r)}),RB={[Ze.v1]:F.object({bookmarkId:F.string()})};Ze.v1+"",F.boolean();const PB=(r,e,t)=>{switch(r){case Ze.v1:return Object.assign({},{method:"POST",selector:K6,body:e},t)}throw Error(`Unknown API version: ${r}`)},MB=(r,e)=>{switch(r){case Ze.v1:{const t=new URLSearchParams;return t.append("api-version",r),`/persons/me/bookmarks/favourites?${String(t)}`}}throw Error(`Unknown API version: ${r}`)},$B=(r,e,t="json")=>{const n=xc(Ze,r);return(i,o)=>{const a=RB[n].parse(i);return e[t](MB(n),PB(n,a,o))}},OB={[Ze.v1]:F.object({bookmarkId:F.string()})};Ze.v1+"",F.boolean();const ZB=(r,e,t)=>{switch(r){case Ze.v1:return Object.assign({},{method:"DELETE",selector:K6},t)}throw Error(`Unknown API version: ${r}`)},LB=(r,e)=>{switch(r){case Ze.v1:{const t=new URLSearchParams;return t.append("api-version",r),`/bookmarks/${e.bookmarkId}?${String(t)}`}}throw Error(`Unknown API version: ${r}`)},HB=(r,e,t="json")=>{const n=xc(Ze,r);return(i,o)=>{const a=OB[n].parse(i);return e[t](LB(n,a),ZB(n,a,o))}},NB={[Ze.v1]:F.object({bookmarkId:F.string()})};Ze.v1+"",F.boolean();const DB=(r,e,t)=>{switch(r){case Ze.v1:return Object.assign({},{method:"HEAD",selector:IB},t)}throw Error(`Unknown API version: ${r}`)},VB=(r,e)=>{switch(r){case Ze.v1:{const t=new URLSearchParams;return t.append("api-version",r),`/persons/me/bookmarks/favourites/${e.bookmarkId}?${String(t)}`}}throw Error(`Unknown API version: ${r}`)},FB=(r,e,t="json")=>{const n=xc(Ze,r);return(i,o)=>{const a=NB[n].parse(i);return e[t](VB(n,a),DB(n,a,o))}},jB={[Ze.v1]:F.object({bookmarkId:F.string()})};Ze.v1+"",F.boolean();const zB=(r,e,t)=>{switch(r){case Ze.v1:return Object.assign({},{method:"DELETE",selector:K6},t)}throw Error(`Unknown API version: ${r}`)},BB=(r,e)=>{switch(r){case Ze.v1:{const t=new URLSearchParams;return t.append("api-version",r),`/persons/me/bookmarks/favourites/${e.bookmarkId}?${String(t)}`}}throw Error(`Unknown API version: ${r}`)},UB=(r,e,t="json")=>{const n=xc(Ze,r);return(i,o)=>{const a=jB[n].parse(i);return e[t](BB(n,a),zB(n,a,o))}};class qB{constructor(e,t){this._client=e,this._method=t}get(e,t,n){return fB(e,this._client,this._method)(t,n)}getPayload(e,t,n){return AB(e,this._client,this._method)(t,n)}query(e,t,n){return cB(e,this._client,this._method)(t,n)}patch(e,t,n){return CB(e,this._client,this._method)(t,n)}create(e,t,n){return yB(e,this._client,this._method)(t,n)}delete(e,t,n){return HB(e,this._client,this._method)(t,n)}isFavorite(e,t,n){return FB(e,this._client,this._method)(t,n)}addFavourite(e,t,n){return $B(e,this._client,this._method)(t,n)}removeFavourite(e,t,n){return UB(e,this._client,this._method)(t,n)}}const WB=(r,e)=>{var t;const n=(t=ei[r])!==null&&t!==void 0?t:r;switch(n){case ei.v2:throw new Io(r);default:{const{id:i}=e,o=new URLSearchParams;return o.append("api-version",n),`/notification/${i}/?${String(o)}`}}},GB=(r,e,t)=>[WB(r,e),t],KB=(r,e,t="json")=>(n,i)=>r[t](...GB(e,n,i)),YB=(r,e)=>{var t;const n=(t=ei[r])!==null&&t!==void 0?t:r;switch(n){case ei.v2:throw new Io(r);default:{const{userId:i}=e,o=new URLSearchParams;return o.append("api-version",n),`/person/${i}/notifications/?${String(o)}`}}},QB=(r,e,t)=>{const n=YB(r,e),i=new Headers;i.append("content-type","application/json");const o=Object.assign({},{method:"POST",body:JSON.stringify(e),headers:i},t);return[n,o]},XB=(r,e,t="json")=>(n,i)=>r[t](...QB(e,n,i)),JB=(r,e)=>{var t;const n=(t=ei[r])!==null&&t!==void 0?t:r;switch(n){case ei.v2:throw new Io(r);default:{const{id:i}=e,o=new URLSearchParams;return o.append("api-version",n),`/notification/${i}/?${String(o)}`}}},eU=(r,e,t)=>{const n=JB(r,e),i=new Headers;i.append("content-type","application/json");const o=Object.assign({},{method:"PATCH",body:JSON.stringify(e),headers:i},t);return[n,o]},tU=(r,e,t="json")=>(n,i)=>r[t](...eU(e,n,i)),rU=(r,e)=>{var t;const n=(t=ei[r])!==null&&t!==void 0?t:r;switch(n){case ei.v2:throw new Io(r);default:{const{userId:i}=e,o=new URLSearchParams;return o.append("api-version",n),`/person/${i}/notifications/?${String(o)}`}}},nU=(r,e,t)=>[rU(r,e),t],iU=(r,e,t="json")=>(n,i)=>r[t](...nU(e,n,i)),oU=(r,e)=>{var t;const n=(t=ei[r])!==null&&t!==void 0?t:r;switch(n){case ei.v2:throw new Io(r);default:{const{id:i}=e,o=new URLSearchParams;return o.append("api-version",n),`/notification/${i}/?${String(o)}`}}},aU=(r,e,t)=>{const n=oU(r,e),i=new Headers;i.append("content-type","application/json");const o=Object.assign({},{method:"DELETE",headers:i},t);return[n,o]},sU=(r,e,t="json")=>(n,i)=>r[t](...aU(e,n,i));var ei;(function(r){r.v1="1.0",r.v2="2.0"})(ei||(ei={}));const cU=(r,e)=>{var t;const n=(t=ei[r])!==null&&t!==void 0?t:r;switch(n){case ei.v2:throw new Io(r);default:{const{userId:i}=e,o=new URLSearchParams;return o.append("api-version",n),`/person/${i}/notifications/settings/?${String(o)}`}}},lU=(r,e,t)=>{const n=cU(r,e),i=new Headers;i.append("content-type","application/json");const o=Object.assign({},{method:"PUT",body:JSON.stringify(e),headers:i},t);return[n,o]},dU=(r,e,t="json")=>(n,i)=>r[t](...lU(e,n,i)),uU=(r,e)=>{var t;const n=(t=ei[r])!==null&&t!==void 0?t:r;switch(n){case ei.v2:throw new Io(r);default:{const{userId:i}=e,o=new URLSearchParams;return o.append("api-version",n),`/person/${i}/notifications/settings/?${String(o)}`}}},hU=(r,e,t)=>[uU(r,e),t],fU=(r,e,t="json")=>(n,i)=>r[t](...hU(e,n,i));class pU{get Version(){return ei}constructor(e,t){this._client=e,this._method=t}getAll(e,...t){return iU(this._client,e,this._method)(...t)}getById(e,...t){return KB(this._client,e,this._method)(...t)}setSeenByUser(e,...t){return tU(this._client,e,this._method)(...t)}create(e,...t){return XB(this._client,e,this._method)(...t)}delete(e,...t){return sU(this._client,e,this._method)(...t)}getSettings(e,...t){return fU(this._client,e,this._method)(...t)}updateSettings(e,...t){return dU(this._client,e,this._method)(...t)}}var oa;(function(r){r.v2="2.0",r.v4="4.0"})(oa||(oa={}));const mU=(r,e)=>{var t;const n=(t=oa[r])!==null&&t!==void 0?t:r;switch(n){case oa.v4:{const{azureId:i,expand:o}=e,a=new URLSearchParams;return a.append("api-version",n),o&&a.append("$expand",o.join(",")),`/persons/${i}?${String(a)}`}default:throw new Io(r)}},vU=(r,e,t)=>[mU(r,e),t],gU=(r,e,t="json")=>(n,i)=>r[t](...vU(e,n,i)),yU=(r,e)=>{var t;const n=(t=oa[r])!==null&&t!==void 0?t:r;switch(n){case oa.v2:{const{search:i}=e,o=new URLSearchParams;return o.append("api-version",n),o.append("$search",i),`/persons?${String(o)}`}default:throw new Io(r)}},_U=(r,e,t)=>[yU(r,e),t],bU=(r,e,t="json")=>(n,i)=>r[t](..._U(e,n,i)),wU=(r,e)=>{var t;const n=(t=oa[r])!==null&&t!==void 0?t:r;switch(n){case oa.v2:{const{azureId:i}=e,o=new URLSearchParams;return o.append("api-version",n),`/persons/${i}/photo?${String(o)}`}default:throw new Io(r)}},xU=(r,e,t)=>[wU(r,e),t],CU=(r,e,t="blob")=>(n,i)=>r[t](...xU(e,n,i));class kU{get Version(){return oa}constructor(e){this._client=e}get(e,t,n,i){return gU(this._client,e,t)(n,i)}query(e,t,n,i){return bU(this._client,e,t)(n,i)}photo(e,t,n,i){return CU(this._client,e,t)(n,i)}}var mp=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};class EU extends Error{constructor(e,t,n){super(e,n),this.response=t,this.name="ApiProviderError"}}const q3=r=>mp(void 0,void 0,void 0,function*(){var e;if(!r.ok){const{headers:t,status:n,statusText:i,type:o,url:a,bodyUsed:c}=r,d=(e=t.get("content-type"))===null||e===void 0?void 0:e.match(/application\/(\w*)?[+]?json/),h=!c&&(yield d?r.json():r.text());throw new EU("failed to execute request, response was not ok",{headers:t,status:n,statusText:i,type:o,url:a,data:h})}});class SU{constructor({createClient:e}){this._createClientFn=e}createNotificationClient(e){return mp(this,void 0,void 0,function*(){const t=yield this._createClientFn("notification");return t.responseHandler.add("validate_api_request",q3),new pU(t,e)})}createBookmarksClient(e){return mp(this,void 0,void 0,function*(){const t=yield this._createClientFn("bookmarks");return new qB(t,e)})}createContextClient(e){return mp(this,void 0,void 0,function*(){const t=yield this._createClientFn("context");return t.responseHandler.add("validate_api_request",q3),new Jz(t,e)})}createPeopleClient(){return mp(this,void 0,void 0,function*(){const e=yield this._createClientFn("people");return e.responseHandler.add("validate_api_request",q3),new kU(e)})}}var CP=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};const TU="services",AU=(r,e)=>t=>CP(void 0,void 0,void 0,function*(){if(r.hasClient(t))return r.createClient(t);if(e)return e.createClient(t);throw Error(`failed to create http client for service ${t}`)}),kP={name:TU,configure:()=>new Az,initialize:r=>CP(void 0,[r],void 0,function*({ref:e,config:t,requireInstance:n,hasModule:i}){if(!t.createClient){const o=yield n("http"),a=i("serviceDiscovery")?yield n("serviceDiscovery"):e==null?void 0:e.serviceDiscovery;t.createClient=AU(o,a)}if(!t.createClient)throw Error("missing configuration for creating API client");return new SU(t)})},IU=r=>{r.addConfig({module:kP})};class RU extends WN{constructor(){super([tD,tk,A6,Tz,kP,pz]),this.logger=new iR("FrameworkConfigurator")}configureHttp(...e){this.addConfig(xV(...e))}configureHttpClient(...e){this.addConfig(YR(...e))}configureMsal(e,t=!0){this.addConfig({module:tk,configure:n=>{t!==void 0&&n.setRequiresAuth(!!t),typeof e=="function"&&e(n),typeof e=="object"&&n.setClientConfig(e)}})}configureServiceDiscovery(e){this.configureHttpClient("service_discovery",e.client)}}var PU=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};const MU=(r,e)=>PU(void 0,void 0,void 0,function*(){const t=yield r.initialize(e),n={modules:t};return window.Fusion=n,t.event.dispatchEvent("onFrameworkLoaded",{detail:n}),n});var x=s6();const or=Hu(x),Y6=XI({__proto__:null,default:or},[x]),EP=x.createContext(null),$U=EP.Provider,SP=x.createContext({}),OU=SP.Provider,TP=()=>x.useContext(SP),ZU=r=>TP()[r];var LU=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};const HU=(r,e)=>x.lazy(()=>LU(void 0,void 0,void 0,function*(){const t=new RU;yield r(t,e);const n=yield MU(t,e);return{default:({children:i})=>k.jsx($U,{value:n,children:k.jsx(OU,{value:n.modules,children:i})})}})),Ll=()=>{let r=x.useContext(EP);return r||console.warn("could not locate fusion in context!"),r??(r=window.Fusion),r||console.error("Could not load framework, might not be initiated?"),r},Q6=r=>{const t=Ll().modules[r];return t||console.warn(`the requested module [${t}] is not included in the framework instance`),t},NU=r=>{const{configure:e,fallback:t,children:n}=r,i=TP(),o=x.useMemo(()=>HU(e,i),[e,i]);return k.jsx(x.Suspense,{fallback:t,children:k.jsx(o,{children:n})})};function br(){return br=Object.assign?Object.assign.bind():function(r){for(var e=1;e<arguments.length;e++){var t=arguments[e];for(var n in t)({}).hasOwnProperty.call(t,n)&&(r[n]=t[n])}return r},br.apply(null,arguments)}function Ef(r){"@babel/helpers - typeof";return Ef=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Ef(r)}function W3(r){return r&&Ef(r)==="object"&&r.constructor===Object}function AP(r,e){var t=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{clone:!0},n=t.clone?br({},r):r;return W3(r)&&W3(e)&&Object.keys(e).forEach(function(i){i!=="__proto__"&&(W3(e[i])&&i in r?n[i]=AP(r[i],e[i],t):n[i]=e[i])}),n}function DU(r,e){if(Ef(r)!="object"||!r)return r;var t=r[Symbol.toPrimitive];if(t!==void 0){var n=t.call(r,e);if(Ef(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(r)}function VU(r){var e=DU(r,"string");return Ef(e)=="symbol"?e:e+""}var FU=typeof Symbol=="function"&&Symbol.for;const IP=FU?Symbol.for("mui.nested"):"__THEME_NESTED__";var jU=["checked","disabled","error","focused","focusVisible","required","expanded","selected"];function zU(){var r=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},e=r.disableGlobal,t=e===void 0?!1:e,n=r.productionPrefix,i=n===void 0?"jss":n,o=r.seed,a=o===void 0?"":o,c=a===""?"":"".concat(a,"-"),d=0,h=function(){return d+=1,d};return function(u,p){var v=p.options.name;if(v&&v.indexOf("Mui")===0&&!p.options.link&&!t){if(jU.indexOf(u.key)!==-1)return"Mui-".concat(u.key);var g="".concat(c).concat(v,"-").concat(u.key);return!p.options.theme[IP]||a!==""?g:"".concat(g,"-").concat(h())}return"".concat(c).concat(i).concat(h())}}var $k=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(r){return typeof r}:function(r){return r&&typeof Symbol=="function"&&r.constructor===Symbol&&r!==Symbol.prototype?"symbol":typeof r},Fm=(typeof window>"u"?"undefined":$k(window))==="object"&&(typeof document>"u"?"undefined":$k(document))==="object"&&document.nodeType===9;function BU(r,e){for(var t=0;t<e.length;t++){var n=e[t];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(r,VU(n.key),n)}}function RP(r,e,t){return e&&BU(r.prototype,e),Object.defineProperty(r,"prototype",{writable:!1}),r}function Kb(r,e){return Kb=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,n){return t.__proto__=n,t},Kb(r,e)}function PP(r,e){r.prototype=Object.create(e.prototype),r.prototype.constructor=r,Kb(r,e)}function Ok(r){if(r===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return r}function MP(r,e){if(r==null)return{};var t={};for(var n in r)if({}.hasOwnProperty.call(r,n)){if(e.indexOf(n)!==-1)continue;t[n]=r[n]}return t}var UU={}.constructor;function Yb(r){if(r==null||typeof r!="object")return r;if(Array.isArray(r))return r.map(Yb);if(r.constructor!==UU)return r;var e={};for(var t in r)e[t]=Yb(r[t]);return e}function X6(r,e,t){r===void 0&&(r="unnamed");var n=t.jss,i=Yb(e),o=n.plugins.onCreateRule(r,i,t);return o||(r[0],null)}var Zk=function(e,t){for(var n="",i=0;i<e.length&&e[i]!=="!important";i++)n&&(n+=t),n+=e[i];return n},uu=function(e){if(!Array.isArray(e))return e;var t="";if(Array.isArray(e[0]))for(var n=0;n<e.length&&e[n]!=="!important";n++)t&&(t+=", "),t+=Zk(e[n]," ");else t=Zk(e,", ");return e[e.length-1]==="!important"&&(t+=" !important"),t};function zf(r){return r&&r.format===!1?{linebreak:"",space:""}:{linebreak:`
79
79
  `,space:" "}}function N1(r,e){for(var t="",n=0;n<e;n++)t+=" ";return t+r}function fm(r,e,t){t===void 0&&(t={});var n="";if(!e)return n;var i=t,o=i.indent,a=o===void 0?0:o,c=e.fallbacks;t.format===!1&&(a=-1/0);var d=zf(t),h=d.linebreak,u=d.space;if(r&&a++,c)if(Array.isArray(c))for(var p=0;p<c.length;p++){var v=c[p];for(var g in v){var _=v[g];_!=null&&(n&&(n+=h),n+=N1(g+":"+u+uu(_)+";",a))}}else for(var b in c){var C=c[b];C!=null&&(n&&(n+=h),n+=N1(b+":"+u+uu(C)+";",a))}for(var T in e){var S=e[T];S!=null&&T!=="fallbacks"&&(n&&(n+=h),n+=N1(T+":"+u+uu(S)+";",a))}return!n&&!t.allowEmpty||!r?n:(a--,n&&(n=""+h+n+h),N1(""+r+u+"{"+n,a)+N1("}",a))}var qU=/([[\].#*$><+~=|^:(),"'`\s])/g,Lk=typeof CSS<"u"&&CSS.escape,J6=function(r){return Lk?Lk(r):r.replace(qU,"\\$1")},$P=function(){function r(t,n,i){this.type="style",this.isProcessed=!1;var o=i.sheet,a=i.Renderer;this.key=t,this.options=i,this.style=n,o?this.renderer=o.renderer:a&&(this.renderer=new a)}var e=r.prototype;return e.prop=function(n,i,o){if(i===void 0)return this.style[n];var a=o?o.force:!1;if(!a&&this.style[n]===i)return this;var c=i;(!o||o.process!==!1)&&(c=this.options.jss.plugins.onChangeValue(i,n,this));var d=c==null||c===!1,h=n in this.style;if(d&&!h&&!a)return this;var u=d&&h;if(u?delete this.style[n]:this.style[n]=c,this.renderable&&this.renderer)return u?this.renderer.removeProperty(this.renderable,n):this.renderer.setProperty(this.renderable,n,c),this;var p=this.options.sheet;return p&&p.attached,this},r}(),Qb=function(r){PP(e,r);function e(n,i,o){var a;a=r.call(this,n,i,o)||this;var c=o.selector,d=o.scoped,h=o.sheet,u=o.generateId;return c?a.selectorText=c:d!==!1&&(a.id=u(Ok(Ok(a)),h),a.selectorText="."+J6(a.id)),a}var t=e.prototype;return t.applyTo=function(i){var o=this.renderer;if(o){var a=this.toJSON();for(var c in a)o.setProperty(i,c,a[c])}return this},t.toJSON=function(){var i={};for(var o in this.style){var a=this.style[o];typeof a!="object"?i[o]=a:Array.isArray(a)&&(i[o]=uu(a))}return i},t.toString=function(i){var o=this.options.sheet,a=o?o.options.link:!1,c=a?br({},i,{allowEmpty:!0}):i;return fm(this.selectorText,this.style,c)},RP(e,[{key:"selector",set:function(i){if(i!==this.selectorText){this.selectorText=i;var o=this.renderer,a=this.renderable;if(!(!a||!o)){var c=o.setSelector(a,i);c||o.replaceRule(a,this)}}},get:function(){return this.selectorText}}]),e}($P),WU={onCreateRule:function(e,t,n){return e[0]==="@"||n.parent&&n.parent.type==="keyframes"?null:new Qb(e,t,n)}},G3={indent:1,children:!0},GU=/@([\w-]+)/,KU=function(){function r(t,n,i){this.type="conditional",this.isProcessed=!1,this.key=t;var o=t.match(GU);this.at=o?o[1]:"unknown",this.query=i.name||"@"+this.at,this.options=i,this.rules=new v4(br({},i,{parent:this}));for(var a in n)this.rules.add(a,n[a]);this.rules.process()}var e=r.prototype;return e.getRule=function(n){return this.rules.get(n)},e.indexOf=function(n){return this.rules.indexOf(n)},e.addRule=function(n,i,o){var a=this.rules.add(n,i,o);return a?(this.options.jss.plugins.onProcessRule(a),a):null},e.replaceRule=function(n,i,o){var a=this.rules.replace(n,i,o);return a&&this.options.jss.plugins.onProcessRule(a),a},e.toString=function(n){n===void 0&&(n=G3);var i=zf(n),o=i.linebreak;if(n.indent==null&&(n.indent=G3.indent),n.children==null&&(n.children=G3.children),n.children===!1)return this.query+" {}";var a=this.rules.toString(n);return a?this.query+" {"+o+a+o+"}":""},r}(),YU=/@container|@media|@supports\s+/,QU={onCreateRule:function(e,t,n){return YU.test(e)?new KU(e,t,n):null}},K3={indent:1,children:!0},XU=/@keyframes\s+([\w-]+)/,Xb=function(){function r(t,n,i){this.type="keyframes",this.at="@keyframes",this.isProcessed=!1;var o=t.match(XU);o&&o[1]?this.name=o[1]:this.name="noname",this.key=this.type+"-"+this.name,this.options=i;var a=i.scoped,c=i.sheet,d=i.generateId;this.id=a===!1?this.name:J6(d(this,c)),this.rules=new v4(br({},i,{parent:this}));for(var h in n)this.rules.add(h,n[h],br({},i,{parent:this}));this.rules.process()}var e=r.prototype;return e.toString=function(n){n===void 0&&(n=K3);var i=zf(n),o=i.linebreak;if(n.indent==null&&(n.indent=K3.indent),n.children==null&&(n.children=K3.children),n.children===!1)return this.at+" "+this.id+" {}";var a=this.rules.toString(n);return a&&(a=""+o+a+o),this.at+" "+this.id+" {"+a+"}"},r}(),JU=/@keyframes\s+/,eq=/\$([\w-]+)/g,Jb=function(e,t){return typeof e=="string"?e.replace(eq,function(n,i){return i in t?t[i]:n}):e},Hk=function(e,t,n){var i=e[t],o=Jb(i,n);o!==i&&(e[t]=o)},tq={onCreateRule:function(e,t,n){return typeof e=="string"&&JU.test(e)?new Xb(e,t,n):null},onProcessStyle:function(e,t,n){return t.type!=="style"||!n||("animation-name"in e&&Hk(e,"animation-name",n.keyframes),"animation"in e&&Hk(e,"animation",n.keyframes)),e},onChangeValue:function(e,t,n){var i=n.options.sheet;if(!i)return e;switch(t){case"animation":return Jb(e,i.keyframes);case"animation-name":return Jb(e,i.keyframes);default:return e}}},rq=function(r){PP(e,r);function e(){return r.apply(this,arguments)||this}var t=e.prototype;return t.toString=function(i){var o=this.options.sheet,a=o?o.options.link:!1,c=a?br({},i,{allowEmpty:!0}):i;return fm(this.key,this.style,c)},e}($P),nq={onCreateRule:function(e,t,n){return n.parent&&n.parent.type==="keyframes"?new rq(e,t,n):null}},iq=function(){function r(t,n,i){this.type="font-face",this.at="@font-face",this.isProcessed=!1,this.key=t,this.style=n,this.options=i}var e=r.prototype;return e.toString=function(n){var i=zf(n),o=i.linebreak;if(Array.isArray(this.style)){for(var a="",c=0;c<this.style.length;c++)a+=fm(this.at,this.style[c]),this.style[c+1]&&(a+=o);return a}return fm(this.at,this.style,n)},r}(),oq=/@font-face/,aq={onCreateRule:function(e,t,n){return oq.test(e)?new iq(e,t,n):null}},sq=function(){function r(t,n,i){this.type="viewport",this.at="@viewport",this.isProcessed=!1,this.key=t,this.style=n,this.options=i}var e=r.prototype;return e.toString=function(n){return fm(this.key,this.style,n)},r}(),cq={onCreateRule:function(e,t,n){return e==="@viewport"||e==="@-ms-viewport"?new sq(e,t,n):null}},lq=function(){function r(t,n,i){this.type="simple",this.isProcessed=!1,this.key=t,this.value=n,this.options=i}var e=r.prototype;return e.toString=function(n){if(Array.isArray(this.value)){for(var i="",o=0;o<this.value.length;o++)i+=this.key+" "+this.value[o]+";",this.value[o+1]&&(i+=`
80
80
  `);return i}return this.key+" "+this.value+";"},r}(),dq={"@charset":!0,"@import":!0,"@namespace":!0},uq={onCreateRule:function(e,t,n){return e in dq?new lq(e,t,n):null}},Nk=[WU,QU,tq,nq,aq,cq,uq],hq={process:!0},Dk={force:!0,process:!0},v4=function(){function r(t){this.map={},this.raw={},this.index=[],this.counter=0,this.options=t,this.classes=t.classes,this.keyframes=t.keyframes}var e=r.prototype;return e.add=function(n,i,o){var a=this.options,c=a.parent,d=a.sheet,h=a.jss,u=a.Renderer,p=a.generateId,v=a.scoped,g=br({classes:this.classes,parent:c,sheet:d,jss:h,Renderer:u,generateId:p,scoped:v,name:n,keyframes:this.keyframes,selector:void 0},o),_=n;n in this.raw&&(_=n+"-d"+this.counter++),this.raw[_]=i,_ in this.classes&&(g.selector="."+J6(this.classes[_]));var b=X6(_,i,g);if(!b)return null;this.register(b);var C=g.index===void 0?this.index.length:g.index;return this.index.splice(C,0,b),b},e.replace=function(n,i,o){var a=this.get(n),c=this.index.indexOf(a);a&&this.remove(a);var d=o;return c!==-1&&(d=br({},o,{index:c})),this.add(n,i,d)},e.get=function(n){return this.map[n]},e.remove=function(n){this.unregister(n),delete this.raw[n.key],this.index.splice(this.index.indexOf(n),1)},e.indexOf=function(n){return this.index.indexOf(n)},e.process=function(){var n=this.options.jss.plugins;this.index.slice(0).forEach(n.onProcessRule,n)},e.register=function(n){this.map[n.key]=n,n instanceof Qb?(this.map[n.selector]=n,n.id&&(this.classes[n.key]=n.id)):n instanceof Xb&&this.keyframes&&(this.keyframes[n.name]=n.id)},e.unregister=function(n){delete this.map[n.key],n instanceof Qb?(delete this.map[n.selector],delete this.classes[n.key]):n instanceof Xb&&delete this.keyframes[n.name]},e.update=function(){var n,i,o;if(typeof(arguments.length<=0?void 0:arguments[0])=="string"?(n=arguments.length<=0?void 0:arguments[0],i=arguments.length<=1?void 0:arguments[1],o=arguments.length<=2?void 0:arguments[2]):(i=arguments.length<=0?void 0:arguments[0],o=arguments.length<=1?void 0:arguments[1],n=null),n)this.updateOne(this.get(n),i,o);else for(var a=0;a<this.index.length;a++)this.updateOne(this.index[a],i,o)},e.updateOne=function(n,i,o){o===void 0&&(o=hq);var a=this.options,c=a.jss.plugins,d=a.sheet;if(n.rules instanceof r){n.rules.update(i,o);return}var h=n.style;if(c.onUpdate(i,n,d,o),o.process&&h&&h!==n.style){c.onProcessStyle(n.style,n,d);for(var u in n.style){var p=n.style[u],v=h[u];p!==v&&n.prop(u,p,Dk)}for(var g in h){var _=n.style[g],b=h[g];_==null&&_!==b&&n.prop(g,null,Dk)}}},e.toString=function(n){for(var i="",o=this.options.sheet,a=o?o.options.link:!1,c=zf(n),d=c.linebreak,h=0;h<this.index.length;h++){var u=this.index[h],p=u.toString(n);!p&&!a||(i&&(i+=d),i+=p)}return i},r}(),OP=function(){function r(t,n){this.attached=!1,this.deployed=!1,this.classes={},this.keyframes={},this.options=br({},n,{sheet:this,parent:this,classes:this.classes,keyframes:this.keyframes}),n.Renderer&&(this.renderer=new n.Renderer(this)),this.rules=new v4(this.options);for(var i in t)this.rules.add(i,t[i]);this.rules.process()}var e=r.prototype;return e.attach=function(){return this.attached?this:(this.renderer&&this.renderer.attach(),this.attached=!0,this.deployed||this.deploy(),this)},e.detach=function(){return this.attached?(this.renderer&&this.renderer.detach(),this.attached=!1,this):this},e.addRule=function(n,i,o){var a=this.queue;this.attached&&!a&&(this.queue=[]);var c=this.rules.add(n,i,o);return c?(this.options.jss.plugins.onProcessRule(c),this.attached?(this.deployed&&(a?a.push(c):(this.insertRule(c),this.queue&&(this.queue.forEach(this.insertRule,this),this.queue=void 0))),c):(this.deployed=!1,c)):null},e.replaceRule=function(n,i,o){var a=this.rules.get(n);if(!a)return this.addRule(n,i,o);var c=this.rules.replace(n,i,o);return c&&this.options.jss.plugins.onProcessRule(c),this.attached?(this.deployed&&this.renderer&&(c?a.renderable&&this.renderer.replaceRule(a.renderable,c):this.renderer.deleteRule(a)),c):(this.deployed=!1,c)},e.insertRule=function(n){this.renderer&&this.renderer.insertRule(n)},e.addRules=function(n,i){var o=[];for(var a in n){var c=this.addRule(a,n[a],i);c&&o.push(c)}return o},e.getRule=function(n){return this.rules.get(n)},e.deleteRule=function(n){var i=typeof n=="object"?n:this.rules.get(n);return!i||this.attached&&!i.renderable?!1:(this.rules.remove(i),this.attached&&i.renderable&&this.renderer?this.renderer.deleteRule(i.renderable):!0)},e.indexOf=function(n){return this.rules.indexOf(n)},e.deploy=function(){return this.renderer&&this.renderer.deploy(),this.deployed=!0,this},e.update=function(){var n;return(n=this.rules).update.apply(n,arguments),this},e.updateOne=function(n,i,o){return this.rules.updateOne(n,i,o),this},e.toString=function(n){return this.rules.toString(n)},r}(),fq=function(){function r(){this.plugins={internal:[],external:[]},this.registry={}}var e=r.prototype;return e.onCreateRule=function(n,i,o){for(var a=0;a<this.registry.onCreateRule.length;a++){var c=this.registry.onCreateRule[a](n,i,o);if(c)return c}return null},e.onProcessRule=function(n){if(!n.isProcessed){for(var i=n.options.sheet,o=0;o<this.registry.onProcessRule.length;o++)this.registry.onProcessRule[o](n,i);n.style&&this.onProcessStyle(n.style,n,i),n.isProcessed=!0}},e.onProcessStyle=function(n,i,o){for(var a=0;a<this.registry.onProcessStyle.length;a++)i.style=this.registry.onProcessStyle[a](i.style,i,o)},e.onProcessSheet=function(n){for(var i=0;i<this.registry.onProcessSheet.length;i++)this.registry.onProcessSheet[i](n)},e.onUpdate=function(n,i,o,a){for(var c=0;c<this.registry.onUpdate.length;c++)this.registry.onUpdate[c](n,i,o,a)},e.onChangeValue=function(n,i,o){for(var a=n,c=0;c<this.registry.onChangeValue.length;c++)a=this.registry.onChangeValue[c](a,i,o);return a},e.use=function(n,i){i===void 0&&(i={queue:"external"});var o=this.plugins[i.queue];o.indexOf(n)===-1&&(o.push(n),this.registry=[].concat(this.plugins.external,this.plugins.internal).reduce(function(a,c){for(var d in c)d in a&&a[d].push(c[d]);return a},{onCreateRule:[],onProcessRule:[],onProcessStyle:[],onProcessSheet:[],onChangeValue:[],onUpdate:[]}))},r}(),pq=function(){function r(){this.registry=[]}var e=r.prototype;return e.add=function(n){var i=this.registry,o=n.options.index;if(i.indexOf(n)===-1){if(i.length===0||o>=this.index){i.push(n);return}for(var a=0;a<i.length;a++)if(i[a].options.index>o){i.splice(a,0,n);return}}},e.reset=function(){this.registry=[]},e.remove=function(n){var i=this.registry.indexOf(n);this.registry.splice(i,1)},e.toString=function(n){for(var i=n===void 0?{}:n,o=i.attached,a=MP(i,["attached"]),c=zf(a),d=c.linebreak,h="",u=0;u<this.registry.length;u++){var p=this.registry[u];o!=null&&p.attached!==o||(h&&(h+=d),h+=p.toString(a))}return h},RP(r,[{key:"index",get:function(){return this.registry.length===0?0:this.registry[this.registry.length-1].options.index}}]),r}(),Lp=new pq,ew=typeof globalThis<"u"?globalThis:typeof window<"u"&&window.Math===Math?window:typeof self<"u"&&self.Math===Math?self:Function("return this")(),tw="2f1acc6c3a606b082e5eef5e54414ffb";ew[tw]==null&&(ew[tw]=0);var Vk=ew[tw]++,Fk=function(e){e===void 0&&(e={});var t=0,n=function(o,a){t+=1;var c="",d="";return a&&(a.options.classNamePrefix&&(d=a.options.classNamePrefix),a.options.jss.id!=null&&(c=String(a.options.jss.id))),e.minify?""+(d||"c")+Vk+c+t:d+o.key+"-"+Vk+(c?"-"+c:"")+"-"+t};return n},ZP=function(e){var t;return function(){return t||(t=e()),t}},mq=function(e,t){try{return e.attributeStyleMap?e.attributeStyleMap.get(t):e.style.getPropertyValue(t)}catch{return""}},vq=function(e,t,n){try{var i=n;if(Array.isArray(n)&&(i=uu(n)),e.attributeStyleMap)e.attributeStyleMap.set(t,i);else{var o=i?i.indexOf("!important"):-1,a=o>-1?i.substr(0,o-1):i;e.style.setProperty(t,a,o>-1?"important":"")}}catch{return!1}return!0},gq=function(e,t){try{e.attributeStyleMap?e.attributeStyleMap.delete(t):e.style.removeProperty(t)}catch{}},yq=function(e,t){return e.selectorText=t,e.selectorText===t},LP=ZP(function(){return document.querySelector("head")});function _q(r,e){for(var t=0;t<r.length;t++){var n=r[t];if(n.attached&&n.options.index>e.index&&n.options.insertionPoint===e.insertionPoint)return n}return null}function bq(r,e){for(var t=r.length-1;t>=0;t--){var n=r[t];if(n.attached&&n.options.insertionPoint===e.insertionPoint)return n}return null}function wq(r){for(var e=LP(),t=0;t<e.childNodes.length;t++){var n=e.childNodes[t];if(n.nodeType===8&&n.nodeValue.trim()===r)return n}return null}function xq(r){var e=Lp.registry;if(e.length>0){var t=_q(e,r);if(t&&t.renderer)return{parent:t.renderer.element.parentNode,node:t.renderer.element};if(t=bq(e,r),t&&t.renderer)return{parent:t.renderer.element.parentNode,node:t.renderer.element.nextSibling}}var n=r.insertionPoint;if(n&&typeof n=="string"){var i=wq(n);if(i)return{parent:i.parentNode,node:i.nextSibling}}return!1}function Cq(r,e){var t=e.insertionPoint,n=xq(e);if(n!==!1&&n.parent){n.parent.insertBefore(r,n.node);return}if(t&&typeof t.nodeType=="number"){var i=t,o=i.parentNode;o&&o.insertBefore(r,i.nextSibling);return}LP().appendChild(r)}var kq=ZP(function(){var r=document.querySelector('meta[property="csp-nonce"]');return r?r.getAttribute("content"):null}),jk=function(e,t,n){try{"insertRule"in e?e.insertRule(t,n):"appendRule"in e&&e.appendRule(t)}catch{return!1}return e.cssRules[n]},zk=function(e,t){var n=e.cssRules.length;return t===void 0||t>n?n:t},Eq=function(){var e=document.createElement("style");return e.textContent=`
81
81
  `,e},Sq=function(){function r(t){this.getPropertyValue=mq,this.setProperty=vq,this.removeProperty=gq,this.setSelector=yq,this.hasInsertedRules=!1,this.cssRules=[],t&&Lp.add(t),this.sheet=t;var n=this.sheet?this.sheet.options:{},i=n.media,o=n.meta,a=n.element;this.element=a||Eq(),this.element.setAttribute("data-jss",""),i&&this.element.setAttribute("media",i),o&&this.element.setAttribute("data-meta",o);var c=kq();c&&this.element.setAttribute("nonce",c)}var e=r.prototype;return e.attach=function(){if(!(this.element.parentNode||!this.sheet)){Cq(this.element,this.sheet.options);var n=!!(this.sheet&&this.sheet.deployed);this.hasInsertedRules&&n&&(this.hasInsertedRules=!1,this.deploy())}},e.detach=function(){if(this.sheet){var n=this.element.parentNode;n&&n.removeChild(this.element),this.sheet.options.link&&(this.cssRules=[],this.element.textContent=`
@@ -406,7 +406,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
406
406
  class="progress">
407
407
  </circle>
408
408
  </svg>
409
- `}}R([se({type:String,reflect:!0})],Wm.prototype,"size",void 0);R([se({type:String,reflect:!0})],Wm.prototype,"color",void 0);Wm.styles=rK;const vM="fwc-circular-progress";let uE=class extends Wm{};uE=R([Cr(vM)],uE);const nK=zm(Um,pM);zm(Wm,vM);zm(qm,mM);const gM=({children:r,text:e})=>k.jsx("div",{style:{display:"flex",justifyContent:"center",alignItems:"center",width:"100vw",height:"100vh",overflow:"hidden"},children:k.jsx(nK,{text:e,children:r})}),iK=()=>({setManifest:on("set_manifest",(r,e)=>({payload:r,meta:{created:Date.now(),update:e}})),fetchManifest:vi("fetch_manifest",(r,e)=>({payload:r,meta:{update:e}}),r=>({payload:r}),r=>({payload:r})),setConfig:on("set_config",r=>({payload:r})),fetchConfig:vi("fetch_config",r=>({payload:r}),r=>({payload:r}),r=>({payload:r})),setSettings:on("set_settings",r=>({payload:r})),fetchSettings:vi("fetch_settings",r=>({payload:{appKey:r}}),r=>({payload:r}),r=>({payload:r})),updateSettings:vi("update_settings",(r,e)=>({payload:{appKey:r,settings:e}}),r=>({payload:r}),r=>({payload:r})),updateSettingsAbort:on("update_settings::abort",r=>({payload:r})),setModule:on("set_module",r=>({payload:r})),importApp:vi("import_app",r=>({payload:r}),r=>({payload:r}),r=>({payload:r})),setInstance:on("set_instance",r=>({payload:r})),initialize:vi("initialize_app",()=>({payload:null}),()=>({payload:null}),r=>({payload:r}))}),lt=iK();xj();const oK=r=>Hm(Object.assign(Object.assign({},r),{status:new Set}),e=>e.addCase(lt.setManifest,(t,n)=>{var i;n.meta.update?t.manifest=Object.assign((i=t.manifest)!==null&&i!==void 0?i:{},n.payload):t.manifest=n.payload}).addCase(lt.setConfig,(t,n)=>{t.config=n.payload}).addCase(lt.setSettings,(t,n)=>{t.settings=n.payload}).addCase(lt.setModule,(t,n)=>{t.modules=n.payload}).addCase(lt.setInstance,(t,n)=>{t.instance=n.payload}).addMatcher(vP,(t,n)=>{t.status.add(Ag(n.type))}).addMatcher(yP,(t,n)=>{t.status.delete(Ag(n.type))})),aK=r=>e=>e.pipe($e(lt.fetchManifest.match),Wt(t=>{const{payload:n,meta:{update:i}}=t,o=rt(r.getAppManifest(n)).pipe($e(a=>!!a),Vf());return xl(o.pipe(me(a=>lt.setManifest(a,i))),o.pipe(Ti(),me(a=>lt.fetchManifest.success(a)))).pipe(Vt(a=>It(lt.fetchManifest.failure(a))))})),sK=r=>e=>e.pipe($e(lt.fetchConfig.match),Wt(({payload:t})=>{var n;const i=rt(r.getAppConfig(t.appKey,(n=t.build)===null||n===void 0?void 0:n.version)).pipe($e(o=>!!o),Vf());return xl(i.pipe(me(o=>lt.setConfig(o))),i.pipe(Ti(),me(o=>lt.fetchConfig.success(o)))).pipe(Vt(o=>It(lt.fetchConfig.failure(o))))})),cK=r=>e=>e.pipe($e(lt.fetchSettings.match),Wt(({payload:t})=>{const{appKey:n}=t,i=rt(r.getAppSettings(n)).pipe($e(o=>!!o),Vf());return xl(i.pipe(me(o=>lt.setSettings(o))),i.pipe(Ti(),me(o=>lt.fetchSettings.success(o)))).pipe(Vt(o=>It(lt.fetchSettings.failure(o))))})),lK=r=>e=>e.pipe($e(lt.updateSettings.match)).pipe(Wt(({payload:t})=>{const{appKey:n,settings:i}=t;return r.updateAppSettings(n,i).pipe(Ti(),_s(o=>rt([lt.setSettings(o),lt.updateSettings.success(o)])),Vt(o=>It(lt.updateSettings.failure(o))))})),dK=r=>e=>e.pipe($e(lt.importApp.match),Wt(({payload:t})=>{const n=[r.assetUri,t].join("/").replace(/\/{2,}/g,"/");return rt(import(n)).pipe(me(lt.importApp.success),Vt(i=>It(lt.importApp.failure(i))))})),uK=(r,e)=>{const t=oK(r),n=new Lm(t);return n.addFlow(aK(e)),n.addFlow(sK(e)),n.addFlow(cK(e)),n.addFlow(lK(e)),n.addFlow(dK(e)),n};var hK=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})},ze=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},fK=function(r,e,t,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?r!==e||!i:!e.has(r))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(r,t):i?i.value=t:e.set(r,t),t},sw,De,yM;function Nh(){return $e(r=>r!=null)}const pK={};class mK{get manifest$(){return ze(this,De,"f").select(e=>e.manifest).pipe(Nh())}get config$(){return ze(this,De,"f").select(e=>e.config,Nb).pipe(Nh())}get modules$(){return ze(this,De,"f").select(e=>e.modules).pipe(Nh())}get instance$(){return ze(this,De,"f").select(e=>e.instance).pipe(Nh())}get settings$(){return new Tt(e=>{ze(this,De,"f").next(lt.fetchSettings(this.appKey)),e.add(ze(this,De,"f").select(t=>t.settings,Nb).pipe(Nh(),x6(pK)).subscribe(e))})}get status$(){return ze(this,De,"f").select(e=>e.status)}get state(){return Object.freeze(ze(this,De,"f").value)}get appKey(){return ze(this,De,"f").value.appKey}get manifest(){return this.state.manifest}get manifestAsync(){return zn(this.manifest$)}get config(){return this.state.config}get configAsync(){return zn(this.config$)}get instance(){return ze(this,De,"f").value.instance}constructor(e,t){sw.add(this),De.set(this,void 0),fK(this,De,uK(e,t.provider),"f");const{appKey:n}=e,{event:i}=t;i&&ze(this,sw,"m",yM).call(this,i);const o=new ti;i&&(o.add(()=>{i.dispatchEvent("onAppDispose",{detail:{appKey:n}})}),o.add(i.addEventListener("onAppModulesLoaded",a=>{a.detail.appKey===n&&ze(this,De,"f").next(lt.setInstance(a.detail.modules))}))),this.dispose=()=>{o==null||o.unsubscribe(),ze(this,De,"f").value.instance&&ze(this,De,"f").value.instance.dispose(),ze(this,De,"f").complete()}}initialize(){return new Tt(e=>{ze(this,De,"f").next(lt.initialize()),e.add(TN([this.getManifest(),this.getAppModule(),this.getConfig()]).subscribe({next:([t,n,i])=>e.next({manifest:t,script:n,config:i}),error:t=>{e.error(t),ze(this,De,"f").next(lt.initialize.failure(t))},complete:()=>{ze(this,De,"f").next(lt.initialize.success()),e.complete()}}))})}loadConfig(){(this.manifest?It(this.manifest):this.getManifest()).subscribe({next:e=>{ze(this,De,"f").next(lt.fetchConfig(e))}})}loadManifest(e){ze(this,De,"f").next(lt.fetchManifest(this.appKey,e))}updateManifest(e,t){ze(this,De,"f").next(lt.setManifest(e,!t))}loadAppModule(){return hK(this,arguments,void 0,function*(e=!0){var t;const n=yield this.getManifestAsync(e);!((t=n.build)===null||t===void 0)&&t.entryPoint?ze(this,De,"f").next(lt.importApp(n.build.entryPoint)):console.warn(`The ${n.appKey} is missing entryPoint, please upload a build for the app before continuing`)})}getConfig(e=!1){return new Tt(t=>{if(ze(this,De,"f").value.config&&(t.next(ze(this,De,"f").value.config),!e))return t.complete();t.add(ze(this,De,"f").addEffect("set_config",({payload:n})=>{t.next(n)})),t.add(ze(this,De,"f").addEffect("fetch_config::success",({payload:n})=>{t.next(n),t.complete()})),t.add(ze(this,De,"f").addEffect("fetch_config::failure",({payload:n})=>{t.error(Error("failed to load application config",{cause:n}))})),this.loadConfig()})}getConfigAsync(e=!0){return(e?zn:lr)(this.getConfig(!e))}getSettings(e=!1){return new Tt(t=>{if(ze(this,De,"f").value.settings&&(t.next(ze(this,De,"f").value.settings),!e))return t.complete();t.add(ze(this,De,"f").addEffect("set_settings",({payload:n})=>{t.next(n)})),t.add(ze(this,De,"f").addEffect("fetch_settings::success",({payload:n})=>{t.next(n),t.complete()})),t.add(ze(this,De,"f").addEffect("fetch_settings::failure",({payload:n})=>{t.error(Error("failed to load application settings",{cause:n}))})),ze(this,De,"f").next(lt.fetchSettings(this.appKey))})}getSettingsAsync(e=!0){return(e?zn:lr)(this.getSettings(!e))}updateSettings(e){return new Tt(t=>{t.add(ze(this,De,"f").addEffect("update_settings::failure",({payload:n})=>{ze(this,De,"f").next(lt.fetchSettings(this.appKey)),t.error(Error("failed to update application settings",{cause:n}))})),t.add(ze(this,De,"f").addEffect("update_settings::success",({payload:n})=>{t.next(n),t.complete()})),ze(this,De,"f").next(lt.setSettings(e)),ze(this,De,"f").next(lt.updateSettings(this.appKey,e))})}updateSettingsAsync(e){return lr(this.updateSettings(e))}updateSetting(e,t){return(ze(this,De,"f").value.settings===void 0?this.getSettings().pipe(Ti()):It(ze(this,De,"f").value.settings)).pipe(me(i=>Object.assign(Object.assign({},i),{[e]:t})),Wt(i=>this.updateSettings(i)),me(i=>i[e]))}updateSettingAsync(e,t){return lr(this.updateSetting(e,t))}getManifest(e=!1){return new Tt(t=>{if(ze(this,De,"f").value.manifest&&(t.next(ze(this,De,"f").value.manifest),!e))return t.complete();t.add(ze(this,De,"f").addEffect("set_manifest",({payload:n})=>{t.next(n)})),t.add(ze(this,De,"f").addEffect("fetch_manifest::success",({payload:n})=>{t.next(n),t.complete()})),t.add(ze(this,De,"f").addEffect("fetch_manifest::failure",({payload:n})=>{t.error(Error("failed to load application manifest",{cause:n}))})),this.loadManifest()})}getManifestAsync(e=!0){return(e?zn:lr)(this.getManifest(!e))}getAppModule(e=!1){return new Tt(t=>{if(ze(this,De,"f").value.modules&&(t.next(ze(this,De,"f").value.modules),!e))return t.complete();t.add(ze(this,De,"f").addEffect("set_module",({payload:n})=>{t.next(n)})),t.add(ze(this,De,"f").addEffect("import_app::success",({payload:n})=>{t.next(n),t.complete()})),t.add(ze(this,De,"f").addEffect("import_app::failure",({payload:n})=>{t.error(Error("failed to load application modules from script",{cause:n}))})),t.add(this.getManifest().subscribe(n=>{var i,o;if(!((i=n.build)===null||i===void 0)&&i.entryPoint){const a=(o=n.build.assetPath)!==null&&o!==void 0?o:[n.appKey,n.build.version].join("@");ze(this,De,"f").next(lt.importApp([a,n.build.entryPoint].join("/")))}else console.error(`The ${n.appKey} app is missing a entry in the manifest, upload a build for your app before continuing`)}))})}getAppModuleAsync(e=!0){return(e?zn:lr)(this.getAppModule(!e))}}De=new WeakMap,sw=new WeakSet,yM=function(e){const{appKey:t}=this;ze(this,De,"f").addEffect(lt.fetchManifest.type,()=>{e.dispatchEvent("onAppManifestLoad",{detail:{appKey:t},source:this})}),ze(this,De,"f").addEffect(lt.fetchManifest.success.type,n=>{e.dispatchEvent("onAppManifestLoaded",{detail:{appKey:t,manifest:n.payload},source:this})}),ze(this,De,"f").addEffect(lt.fetchManifest.failure.type,n=>{e.dispatchEvent("onAppManifestFailure",{detail:{appKey:t,error:n.payload},source:this})}),ze(this,De,"f").addEffect(lt.fetchConfig.type,()=>{e.dispatchEvent("onAppConfigLoad",{detail:{appKey:t},source:this})}),ze(this,De,"f").addEffect(lt.fetchConfig.success.type,n=>{e.dispatchEvent("onAppConfigLoaded",{detail:{appKey:t,config:n.payload},source:this})}),ze(this,De,"f").addEffect(lt.fetchConfig.failure.type,n=>{e.dispatchEvent("onAppConfigFailure",{detail:{appKey:t,error:n.payload},source:this})}),ze(this,De,"f").addEffect(lt.fetchSettings.type,()=>{e.dispatchEvent("onAppSettingsLoad",{detail:{appKey:t},source:this})}),ze(this,De,"f").addEffect(lt.fetchSettings.success.type,n=>{e.dispatchEvent("onAppSettingsLoaded",{detail:{appKey:t,settings:n.payload},source:this})}),ze(this,De,"f").addEffect(lt.fetchSettings.failure.type,n=>{e.dispatchEvent("onAppSettingsFailure",{detail:{appKey:t,error:n.payload},source:this})}),ze(this,De,"f").addEffect(lt.updateSettings.type,n=>{e.dispatchEvent("onAppSettingsUpdate",{detail:{appKey:t,settings:n.payload.settings},source:this})}),ze(this,De,"f").addEffect(lt.updateSettings.success.type,n=>{e.dispatchEvent("onAppSettingsUpdated",{detail:{appKey:t,settings:n.payload.settings},source:this})}),ze(this,De,"f").addEffect(lt.updateSettings.failure.type,n=>{e.dispatchEvent("onAppSettingsUpdateFailure",{detail:{appKey:t,settings:n.payload},source:this})}),ze(this,De,"f").addEffect(lt.importApp.type,()=>{e.dispatchEvent("onAppScriptLoad",{detail:{appKey:t},source:this})}),ze(this,De,"f").addEffect(lt.importApp.success.type,n=>{e.dispatchEvent("onAppScriptLoaded",{detail:{appKey:t,script:n.payload},source:this})}),ze(this,De,"f").addEffect(lt.importApp.failure.type,n=>{e.dispatchEvent("onAppScriptFailure",{detail:{appKey:t,error:n.payload},source:this})}),ze(this,De,"f").addEffect(lt.initialize.type,()=>{e.dispatchEvent("onAppInitialize",{detail:{appKey:t},source:this})}),ze(this,De,"f").addEffect(lt.initialize.success.type,()=>{e.dispatchEvent("onAppInitialized",{detail:{appKey:t},source:this})}),ze(this,De,"f").addEffect(lt.initialize.failure.type,({payload:n})=>{e.dispatchEvent("onAppInitializeFailure",{detail:{appKey:t,error:n},source:this})})};const vK="6.1.5";var $i=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},P0=function(r,e,t,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?r!==e||!i:!e.has(r))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(r,t):i?i.value=t:e.set(r,t),t},sl,Rv,cl,yp,Pv;class gK{static compareAppManifest(e,t){return JSON.stringify(e)===JSON.stringify(t)}get version(){return new fs(vK)}get current(){return $i(this,cl,"f").value}get current$(){return $i(this,cl,"f").pipe(rg((e,t)=>e&&t?e.appKey===t.appKey:e===t))}constructor(e){var t;sl.set(this,void 0),Rv.set(this,void 0),cl.set(this,void 0),yp.set(this,new ti),Pv.set(this,void 0);const{event:n,config:i}=e;P0(this,sl,i.client,"f"),P0(this,Pv,n,"f"),P0(this,cl,new Df(void 0),"f"),P0(this,Rv,(t=i.assetUri)!==null&&t!==void 0?t:"","f"),$i(this,yp,"f").add(this.current$.pipe(ig(),MR(()=>!!n)).subscribe(([o,a])=>{n==null||n.dispatchEvent("onCurrentAppChanged",{source:this,detail:{previous:o,next:a}})})),$i(this,yp,"f").add($i(this,cl,"f").pipe(ig(),me(([o])=>o),Nh()).subscribe(o=>o.dispose()))}getAppManifest(e){return rt($i(this,sl,"f").getAppManifest({appKey:e}))}getAppManifests(e){return rt($i(this,sl,"f").getAppManifests(e))}getAllAppManifests(){return this.getAppManifests()}getAppConfig(e,t){return rt($i(this,sl,"f").getAppConfig({appKey:e,tag:t}))}getAppSettings(e){return rt($i(this,sl,"f").getAppSettings({appKey:e}))}updateAppSettings(e,t){return rt($i(this,sl,"f").updateAppSettings({appKey:e,settings:t}))}setCurrentApp(e){const t=typeof e=="string"?this.createApp({appKey:e}):e;$i(this,cl,"f").next(t)}clearCurrentApp(){$i(this,cl,"f").next(null)}get assetUri(){return $i(this,Rv,"f")}createApp(e){return console.warn(),new mK(e,{provider:this,event:$i(this,Pv,"f")})}dispose(){$i(this,yp,"f").unsubscribe()}}sl=new WeakMap,Rv=new WeakMap,cl=new WeakMap,yp=new WeakMap,Pv=new WeakMap;var yK=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};const cw="app",_K={name:cw,configure:()=>new IK,initialize:r=>yK(void 0,void 0,void 0,function*(){const e=yield r.config.createConfigAsync(r),t=yield r.requireInstance("event").catch(()=>{});return new gK({config:e,event:t})}),dispose:r=>{r.instance.dispose()}},bK=F.object({environment:F.record(F.any()).optional().default({}),endpoints:F.record(F.object({url:F.string(),scopes:F.array(F.string()).optional().default([])})).optional()}),lw=F.object({azureUniqueId:F.string({description:"The unique identifier for the person in Azure."}),displayName:F.string({description:"The display name of the person."}),mail:F.string({description:"The email address of the person, which can be null or undefined."}).nullish(),upn:F.string({description:"The User Principal Name (UPN) of the person, which can be null or undefined."}).nullish(),accountType:F.string({description:"The type of account the person has."}),accountClassification:F.string({description:"The classification of the account, which can be null or undefined."}).nullish(),isExpired:F.boolean({description:"Indicates whether the account is expired, which can be null or undefined."}).nullish()}),wK=F.object({version:F.string(),entryPoint:F.string(),tags:F.array(F.string()).nullish(),tag:F.enum(["latest","preview"]).nullish(),assetPath:F.string().nullish(),configUrl:F.string().nullish(),timestamp:F.string().nullish(),commitSha:F.string().nullish(),githubRepo:F.string().nullish(),projectPage:F.string().nullish(),allowedExtensions:F.array(F.string()).nullish(),uploadedBy:lw.nullish()}),xK=F.object({appKey:F.string(),displayName:F.string(),description:F.string(),type:F.string(),isPinned:F.boolean().nullish(),templateSource:F.string().nullish(),category:F.object({id:F.string(),name:F.string(),displayName:F.string(),color:F.string(),defaultIcon:F.string(),sortOrder:F.number()}).nullish(),visualization:F.object({color:F.string().nullish(),icon:F.string().nullish(),sortOrder:F.number()}).nullish(),keywords:F.array(F.string()).nullish(),admins:F.array(lw).nullish(),owners:F.array(lw).nullish(),build:wK.nullish()});class El extends Error{static fromHttpResponse(e,t){switch(e.status){case 401:return new El("unauthorized","failed to load application manifest, request not authorized",t);case 404:return new El("not_found","application manifest not found",t)}return new El("unknown",`failed to load application manifest, status code ${e.status}`,t)}constructor(e,t,n){super(t,n),this.type=e}}class hu extends Error{static fromHttpResponse(e,t){switch(e.status){case 401:return new hu("unauthorized","failed to load application config, request not authorized",t);case 404:return new hu("not_found","application config not found",t)}return new hu("unknown",`failed to load application config, status code ${e.status}`,t)}constructor(e,t,n){super(t,n),this.type=e}}class fu extends Error{static fromHttpResponse(e,t){switch(e.status){case 401:return new fu("unauthorized","failed to load application settings, request not authorized",t);case 404:return new fu("not_found","application not found",t)}return new fu("unknown",`failed to load application settings, status code ${e.status}`,t)}constructor(e,t,n){super(t,n),this.type=e}}var hE=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},CK=function(r,e,t,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?r!==e||!i:!e.has(r))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(r,t):i?i.value=t:e.set(r,t),t},_p;const _M=r=>{for(const e of Object.keys(r))typeof r[e]=="object"&&r[e]!==null&&!Object.isFrozen(r[e])&&_M(r[e]);return Object.freeze(r)};class kK{get endpoints(){return console.warn("endpoints is deprecated, use getEndpoint instead"),new Proxy(hE(this,_p,"f"),{get(e,t){var n;return(n=e[t])===null||n===void 0?void 0:n.url}})}constructor(e){var t,n;_p.set(this,void 0),this.environment=_M((t=e.environment)!==null&&t!==void 0?t:{}),CK(this,_p,(n=e.endpoints)!==null&&n!==void 0?n:{},"f")}getEndpoint(e){return hE(this,_p,"f")[e]}}_p=new WeakMap;var EK=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};const SK=r=>EK(void 0,void 0,void 0,function*(){const e=yield gf(r),t=bK.parse(e);return new kK(t)});var fE=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})},F1=function(r,e,t,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?r!==e||!i:!e.has(r))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(r,t):i?i.value=t:e.set(r,t),t},rs=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},TK=function(r,e){var t={};for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&e.indexOf(n)<0&&(t[n]=r[n]);if(r!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,n=Object.getOwnPropertySymbols(r);i<n.length;i++)e.indexOf(n[i])<0&&Object.prototype.propertyIsEnumerable.call(r,n[i])&&(t[n[i]]=r[n[i]]);return t},j1,z1,B1,Sh,M0;const pE=xK.transform(r=>{const{category:e}=r,t=TK(r,["category"]);return Object.assign(Object.assign({},t),{get key(){return t.appKey},get name(){return t.displayName},categoryId:e==null?void 0:e.id,category:e})});class AK{constructor(e){j1.set(this,void 0),z1.set(this,void 0),B1.set(this,void 0),Sh.set(this,void 0),M0.set(this,void 0),F1(this,M0,e,"f");const t=1*60*1e3;F1(this,j1,new xi({client:{fn:({appKey:n})=>e.json(`/persons/me/apps/${n}`,{headers:{"Api-Version":"1.0"},selector:i=>fE(this,void 0,void 0,function*(){return pE.parse(yield gf(i))})})},key:({appKey:n})=>n,expire:t}),"f"),F1(this,z1,new xi({client:{fn:n=>{const i=n!=null&&n.filterByCurrentUser?"/persons/me/apps":"/apps?=$expand=category,admins,owners,keywords";return e.json(i,{headers:{"Api-Version":"1.0"},selector:o=>fE(this,void 0,void 0,function*(){const a=yield gf(o);return pE.array().parse(a.value)})})}},key:n=>n!=null&&n.filterByCurrentUser?"currentUser":"all",expire:t}),"f"),F1(this,B1,new xi({client:{fn:({appKey:n,tag:i="latest"})=>e.json(`/apps/${n}/builds/${i}/config`,{selector:SK,headers:{"Api-Version":"1.0"}})},key:n=>JSON.stringify(n),expire:t}),"f"),F1(this,Sh,new xi({client:{fn:({appKey:n})=>e.json(`/persons/me/apps/${n}/settings`,{headers:{"Api-Version":"1.0"}})},key:n=>n.appKey,expire:t}),"f")}getAppManifest(e){return rs(this,j1,"f").query(e).pipe(lf,Vt(t=>{const{cause:n}=t;throw n instanceof El?n:n instanceof su?El.fromHttpResponse(n.response,{cause:n}):new El("unknown","failed to load manifest",{cause:n})}))}getAppManifests(e){return rs(this,z1,"f").query(e).pipe(lf)}getAppConfig(e){return rs(this,B1,"f").query(e).pipe(me(t=>t.value),Vt(t=>{const{cause:n}=t;throw n instanceof hu?n:n instanceof su?hu.fromHttpResponse(n.response,{cause:n}):new hu("unknown","failed to load config",{cause:n})}))}getAppSettings(e){return rs(this,Sh,"f").query(e).pipe(lf,Vt(t=>{const{cause:n}=t;throw n instanceof fu?n:n instanceof su?fu.fromHttpResponse(n.response,{cause:n}):new fu("unknown","failed to load settings",{cause:n})}))}updateAppSettings(e){const{appKey:t,settings:n}=e;return rs(this,M0,"f").json$(`/persons/me/apps/${t}/settings`,{method:"PUT",body:n,headers:{"Api-Version":"1.0"}}).pipe(Br(i=>{rs(this,Sh,"f").mutate({appKey:t},{value:i,updated:Date.now()})}))}[(j1=new WeakMap,z1=new WeakMap,B1=new WeakMap,Sh=new WeakMap,M0=new WeakMap,Symbol.dispose)](){console.warn("AppClient disposed"),rs(this,j1,"f").complete(),rs(this,z1,"f").complete(),rs(this,B1,"f").complete(),rs(this,Sh,"f").complete()}}var l_=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};class IK extends Mm{constructor(){super(...arguments),this.defaultExpireTime=1*60*1e3}_createHttpClient(e){return l_(this,void 0,void 0,function*(){const t=yield e.requireInstance("http");return t.hasClient(cw)?t.createClient(cw):yield(yield e.requireInstance("serviceDiscovery")).createClient("apps")})}setClient(e){const t=typeof e=="object"?()=>e:e;this._set("client",t)}setAssetUri(e){const t=typeof e=="string"?()=>l_(this,void 0,void 0,function*(){return e}):e;this._set("assetUri",t)}_createConfig(e,t){return this._has("client")||this.setClient(()=>l_(this,void 0,void 0,function*(){const n=yield this._createHttpClient(e);return new AK(n)})),this._has("assetUri")||this.setAssetUri("/apps-proxy"),super._createConfig(e,t)}}var RK=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};const PK=(r,e)=>{r.addConfig({module:_K,configure:t=>RK(void 0,void 0,void 0,function*(){})})},bM=(r,e,t)=>{x.useEffect(()=>{const n=r.subscribe(e);return n.add(t),()=>n.unsubscribe()},[r,e])},MK=(r,e,t)=>{x.useLayoutEffect(()=>{const n=r.subscribe(e);return n.add(t),()=>n.unsubscribe()},[r,e])};function ks(r,e){const t=x.useCallback(()=>{var p,v;return(v=(p=e==null?void 0:e.initial)!==null&&p!==void 0?p:r.value)!==null&&v!==void 0?v:void 0},[r,e==null?void 0:e.initial]),n=x.useRef(t()),[i,o]=x.useState(n.current),[a,c]=x.useState(null),[d,h]=x.useState(!1);x.useLayoutEffect(()=>{n.current=t()},[t]),x.useLayoutEffect(()=>{c(null),h(!1),o(n.current)},[r]);const u=x.useMemo(()=>({next:o,error:c,complete:()=>h(!0)}),[]);return MK(r,u,e==null?void 0:e.teardown),{value:i,error:a,complete:d}}const mE=Om({id:bi(),name:bi(),mail:bi().optional()}),wM=Om({identifier:bi(),name:bi().nullish(),subSystem:bi().nullish()},{message:"invalid source system"}),$K=Om({id:bi(),name:bi().optional(),type:bi().optional()}),xM=Om({id:bi(),name:bi(),appKey:bi(),description:bi().optional(),isShared:T6().optional(),created:Sb(),createdBy:mE,updated:Sb().optional(),updatedBy:mE.optional(),context:$K.optional(),sourceSystem:wM.nullish()});WR(xM);const OK=(r=GR(qR()).or(bi()).optional())=>xM.extend({payload:r});var $0=function(r,e,t,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?r!==e||!i:!e.has(r))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(r,t):i?i.value=t:e.set(r,t),t},Fr=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},$g=function(r,e){var t={};for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&e.indexOf(n)<0&&(t[n]=r[n]);if(r!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,n=Object.getOwnPropertySymbols(r);i<n.length;i++)e.indexOf(n[i])<0&&Object.prototype.propertyIsEnumerable.call(r,n[i])&&(t[n[i]]=r[n[i]]);return t},yo,Dh,ll,ec;const vE=Gb["1.0"].transform(r=>({azureUniqueId:r.azureUniqueId,id:r.azureUniqueId,name:r.name,email:r.mail})),dw=r=>{const e=r,{createdBy:t,updatedBy:n}=e,i=$g(e,["createdBy","updatedBy"]);return OK().parse(Object.assign(Object.assign({},i),{createdBy:vE.parse(t),updatedBy:n?vE.parse(n):void 0}))},gE=r=>{const e=dw(r),{payload:t}=e;return $g(e,["payload"])};class ZK{constructor(e,t){yo.set(this,void 0),Dh.set(this,void 0),ll.set(this,void 0),ec.set(this,void 0),$0(this,yo,e,"f");const{expire:n=5*60*1e3}=t??{};$0(this,Dh,new xi({client:{fn:i=>Fr(this,yo,"f").get("v2",i).pipe(me(gE))},key:i=>i.bookmarkId,expire:n}),"f"),$0(this,ll,new xi({client:{fn:i=>Fr(this,yo,"f").query("v2",{filter:i}).pipe(me(o=>o.map(gE)))},key:i=>JSON.stringify(i??""),expire:n}),"f"),$0(this,ec,new xi({client:{fn:i=>Fr(this,yo,"f").getPayload("v1",i).pipe(me(o=>o.payload))},key:i=>i.bookmarkId,expire:n,cache:{trimming:{size:3}}}),"f")}getAllBookmarks(e){return Fr(this,ll,"f").query(e).pipe(me(t=>t.value))}getBookmarkById(e){return Fr(this,Dh,"f").query({bookmarkId:e}).pipe(me(t=>t.value))}getBookmarkData(e){return Fr(this,ec,"f").query({bookmarkId:e}).pipe(me(t=>t.value))}setBookmarkData(e,t){return Fr(this,yo,"f").patch("v1",{bookmarkId:e,updates:{payload:t}}).pipe(me(n=>n.payload),Br(n=>{n&&Fr(this,ec,"f").mutate({bookmarkId:e},{value:n,updated:Date.now()},{allowCreation:!0})}))}createBookmark(e){return Fr(this,yo,"f").create("v1",e).pipe(me(t=>dw(t)),Br(t=>{console.log("createdBookmark",t);const{payload:n}=t,i=$g(t,["payload"]);Fr(this,Dh,"f").mutate({bookmarkId:i.id},{value:i,updated:Date.now()},{allowCreation:!0}),n&&Fr(this,ec,"f").mutate({bookmarkId:i.id},{value:n,updated:Date.now()},{allowCreation:!0}),Fr(this,ll,"f").invalidate()}))}updateBookmark(e,t){const n=Fr(this,yo,"f").patch("v1",{bookmarkId:e,updates:t}).pipe(me(i=>dw(i)),zN());return new Tt(i=>{i.add(n.subscribe(o=>{const{payload:a}=o,c=$g(o,["payload"]);Fr(this,Dh,"f").mutate({bookmarkId:e},{value:c,updated:Date.now()},{allowCreation:!1})})),i.add(n.subscribe(o=>{const{payload:a}=o;if(a)Fr(this,ec,"f").mutate({bookmarkId:o.id},{value:a,updated:Date.now()},{allowCreation:!0});else{const c=Fr(this,ec,"f").generateCacheKey({bookmarkId:o.id});Fr(this,ec,"f").cache.removeItem(c)}})),i.add(n.subscribe(()=>{Fr(this,ll,"f").invalidate()})),n.subscribe(i)})}deleteBookmark(e){return Fr(this,yo,"f").delete("v1",{bookmarkId:e})}addBookmarkToFavorites(e){return Fr(this,yo,"f").addFavourite("v1",{bookmarkId:e}).pipe(Br(()=>Fr(this,ll,"f").invalidate()))}removeBookmarkFromFavorites(e){return Fr(this,yo,"f").removeFavourite("v1",{bookmarkId:e}).pipe(Br(()=>Fr(this,ll,"f").invalidate()))}isBookmarkFavorite(e){return Fr(this,yo,"f").isFavorite("v1",{bookmarkId:e})}}yo=new WeakMap,Dh=new WeakMap,ll=new WeakMap,ec=new WeakMap;const CM=F.object({log:F.custom().optional(),logLevel:F.nativeEnum(un).optional(),eventProvider:F.custom().optional(),sourceSystem:wM.optional().describe("The source system for the bookmarks"),parent:F.custom().describe("Parent Bookmark provider").optional().nullable(),client:F.custom().describe("API client for interacting with bookmarks"),resolve:F.object({context:F.function().returns(F.promise(F.object({id:F.string()}).optional())),application:F.function().returns(F.promise(F.object({appKey:F.string(),name:F.string().optional()}).optional()))}).describe("Functions for resolving context and application"),filters:F.object({context:F.boolean().optional().default(!1),application:F.boolean().optional().default(!1)}).describe("Flags for enabling resolving when fetching bookmarks").optional().default({context:!1,application:!1})});var mi=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})},LK=function(r,e,t,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?r!==e||!i:!e.has(r))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(r,t):i?i.value=t:e.set(r,t),t},Yr=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},Rr;const HK=CM.pick({filters:!0,sourceSystem:!0,resolve:!0}).partial().optional();class NK extends Mm{constructor(e){super(),Rr.set(this,void 0),this.defaultExpireTime=1*60*1e3;const{log:t}=e??{};LK(this,Rr,t,"f"),this._set("log",()=>mi(this,void 0,void 0,function*(){return t}))}setLogLevel(e){this._set("logLevel",()=>mi(this,void 0,void 0,function*(){return e})),Yr(this,Rr,"f")&&(Yr(this,Rr,"f").level=e)}setClient(e){typeof e=="function"?this._set("client",t=>e(t)):this._set("client",()=>mi(this,void 0,void 0,function*(){return e}))}setParent(e){typeof e=="function"?this._set("parent",t=>e(t)):this._set("parent",()=>mi(this,void 0,void 0,function*(){return e}))}setSourceSystem(e){typeof e=="function"?this._set("sourceSystem",e):this._set("sourceSystem",()=>mi(this,void 0,void 0,function*(){return e}))}setContextResolver(e){this._set("resolve.context",e)}setApplicationResolver(e){this._set("resolve.application",e)}setFilter(e,t){this._set(`filters.${e}`,()=>mi(this,void 0,void 0,function*(){return t}))}_createConfig(e,t){var n,i,o,a,c,d,h;if(!this._has("parent")){(n=Yr(this,Rr,"f"))===null||n===void 0||n.debug("No parent provided, using default parent");const u=e.ref;if(u&&"bookmark"in u){const p=u.bookmark;"version"in p&&p.version.satisfies(">=2.0.0")?this._set("parent",()=>mi(this,void 0,void 0,function*(){return p})):(i=Yr(this,Rr,"f"))===null||i===void 0||i.warn("invalid version of parent BookmarkProvider provided")}else(o=Yr(this,Rr,"f"))===null||o===void 0||o.info("No parent BookmarkProvider found")}return this._has("client")||((a=Yr(this,Rr,"f"))===null||a===void 0||a.debug("No client provided, using default client"),this._set("client",this._createDefaultClient.bind(this))),this._has("resolve.context")||((c=Yr(this,Rr,"f"))===null||c===void 0||c.debug("No context resolver provided, using default context resolver"),this._set("resolve.context",this._createDefaultContextResolver.bind(this))),this._has("resolve.application")||((d=Yr(this,Rr,"f"))===null||d===void 0||d.debug("No application resolver provided, using default application resolver"),this._set("resolve.application",this._createDefaultApplicationResolver.bind(this))),this._has("eventProvider")||((h=Yr(this,Rr,"f"))===null||h===void 0||h.debug("No event provider provided, using default event provider"),this._set("eventProvider",this._resolveEventProvider.bind(this))),super._createConfig(e,HK.parse(t))}_createDefaultContextResolver(e){return mi(this,void 0,void 0,function*(){var t,n;if(e.hasModule("context")){(t=Yr(this,Rr,"f"))===null||t===void 0||t.debug("Context module available, awaiting instance");const i=yield e.requireInstance("context");return(n=Yr(this,Rr,"f"))===null||n===void 0||n.debug("Context provider available, creating context resolver"),()=>mi(this,void 0,void 0,function*(){var o,a;(o=Yr(this,Rr,"f"))===null||o===void 0||o.debug("Resolving context for bookmarks");const c=(a=i.currentContext)===null||a===void 0?void 0:a.id;return c?{id:c}:void 0})}})}_createDefaultApplicationResolver(e){return mi(this,void 0,void 0,function*(){var t,n;if(e.hasModule("app")){(t=Yr(this,Rr,"f"))===null||t===void 0||t.debug("App module available, awaiting instance");const i=yield e.requireInstance("app");return(n=Yr(this,Rr,"f"))===null||n===void 0||n.debug("App provider available, creating application resolver"),()=>mi(this,void 0,void 0,function*(){var o,a;const c=i.current;if(c)return{appKey:c.appKey,name:(o=c.manifest)===null||o===void 0?void 0:o.name};(a=Yr(this,Rr,"f"))===null||a===void 0||a.warn("No current application found")})}})}_resolveAppProvider(e){return mi(this,void 0,void 0,function*(){var t,n;if(e.hasModule("app"))return(t=Yr(this,Rr,"f"))===null||t===void 0||t.debug("App module available, awaiting instance"),e.requireInstance("app");(n=Yr(this,Rr,"f"))===null||n===void 0||n.debug("No app module available, will use ref to app module if available")})}_resolveEventProvider(e){return mi(this,void 0,void 0,function*(){var t;if(e.hasModule("event"))return(t=Yr(this,Rr,"f"))===null||t===void 0||t.debug("Event module available, awaiting instance"),e.requireInstance("event")})}_createDefaultClient(e){return mi(this,void 0,void 0,function*(){var t;try{const i=yield(yield this._getServiceProvider(e)).createBookmarksClient("json$");return new ZK(i)}catch{(t=Yr(this,Rr,"f"))===null||t===void 0||t.warn("Failed to create bookmark api client")}})}_getServiceProvider(e){return mi(this,void 0,void 0,function*(){var t,n,i,o;if(e.hasModule("services"))return(t=Yr(this,Rr,"f"))===null||t===void 0||t.debug("Services module available, awaiting instance"),e.requireInstance("services");(n=Yr(this,Rr,"f"))===null||n===void 0||n.debug("No services module available, will use ref services module if available");const a=(i=e.ref)===null||i===void 0?void 0:i.services;if(a)return a;throw(o=Yr(this,Rr,"f"))===null||o===void 0||o.error("No service provider available, cannot create bookmarks client"),Error("[BookmarkConfigurator] No service provider configures [ServicesModule] ")})}_processConfig(e,t){return mi(this,void 0,void 0,function*(){var n,i;try{return CM.parse(e)}catch(o){throw(n=Yr(this,Rr,"f"))===null||n===void 0||n.error("Failed to parse config",e,(i=o.issues)!==null&&i!==void 0?i:o),o}})}}Rr=new WeakMap;var d_,yE;function DK(){return yE||(yE=1,d_=function r(e,t){if(e===t)return!0;if(e&&t&&typeof e=="object"&&typeof t=="object"){if(e.constructor!==t.constructor)return!1;var n,i,o;if(Array.isArray(e)){if(n=e.length,n!=t.length)return!1;for(i=n;i--!==0;)if(!r(e[i],t[i]))return!1;return!0}if(e instanceof Map&&t instanceof Map){if(e.size!==t.size)return!1;for(i of e.entries())if(!t.has(i[0]))return!1;for(i of e.entries())if(!r(i[1],t.get(i[0])))return!1;return!0}if(e instanceof Set&&t instanceof Set){if(e.size!==t.size)return!1;for(i of e.entries())if(!t.has(i[0]))return!1;return!0}if(ArrayBuffer.isView(e)&&ArrayBuffer.isView(t)){if(n=e.length,n!=t.length)return!1;for(i=n;i--!==0;)if(e[i]!==t[i])return!1;return!0}if(e.constructor===RegExp)return e.source===t.source&&e.flags===t.flags;if(e.valueOf!==Object.prototype.valueOf)return e.valueOf()===t.valueOf();if(e.toString!==Object.prototype.toString)return e.toString()===t.toString();if(o=Object.keys(e),n=o.length,n!==Object.keys(t).length)return!1;for(i=n;i--!==0;)if(!Object.prototype.hasOwnProperty.call(t,o[i]))return!1;for(i=n;i--!==0;){var a=o[i];if(!r(e[a],t[a]))return!1}return!0}return e!==e&&t!==t}),d_}var VK=DK();const u_=Hu(VK),Be={aborted:on("action_aborted",r=>({payload:r})),setBookmark:on("set_bookmark",r=>({payload:r})),setCurrentBookmark:on("set_current_bookmark",r=>({payload:r})),fetchBookmark:vi("fetch_bookmark",(r,e)=>({payload:r,meta:e}),(r,e)=>({payload:r,meta:e}),(r,e)=>({payload:r,meta:e})),fetchBookmarkData:vi("fetch_bookmark_payload",(r,e)=>({payload:r,meta:e}),(r,e,t)=>({payload:{bookmarkId:r,data:e},meta:t}),(r,e)=>({payload:r,meta:e})),fetchBookmarks:vi("fetch_bookmarks",(r,e)=>({payload:r,meta:e}),(r,e)=>({payload:r,meta:e}),(r,e)=>({payload:r,meta:e})),updateBookmark:vi("set_bookmark",(r,e)=>({payload:r,meta:e}),(r,e)=>({payload:r,meta:e}),(r,e)=>({payload:r,meta:e})),createBookmark:vi("create_bookmark",(r,e)=>({payload:r,meta:e}),(r,e)=>({payload:r,meta:e}),(r,e)=>({payload:r,meta:e})),deleteBookmark:vi("delete_bookmark",(r,e)=>({payload:r,meta:Object.assign({ref:r},e)}),(r,e)=>({payload:r,meta:Object.assign({ref:r},e)}),(r,e)=>({payload:r,meta:e})),removeBookmark:vi("remove_bookmark",(r,e)=>({payload:r,meta:Object.assign({ref:r},e)}),(r,e)=>({payload:r,meta:e}),(r,e)=>({payload:r,meta:e})),addBookmarkAsFavourite:vi("add_favourite_bookmark",(r,e)=>({payload:r,meta:Object.assign({ref:r},e)}),(r,e)=>({payload:r,meta:Object.assign({ref:r},e)}),(r,e)=>({payload:r,meta:e})),removeBookmarkAsFavourite:vi("remove_favourite_bookmark",(r,e)=>({payload:r,meta:Object.assign({ref:r},e)}),(r,e)=>({payload:r,meta:Object.assign({ref:r},e)}),(r,e)=>({payload:r,meta:e}))};var FK=function(r,e){var t={};for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&e.indexOf(n)<0&&(t[n]=r[n]);if(r!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,n=Object.getOwnPropertySymbols(r);i<n.length;i++)e.indexOf(n[i])<0&&Object.prototype.propertyIsEnumerable.call(r,n[i])&&(t[n[i]]=r[n[i]]);return t};const O0=r=>Ag(r.type),jK={status:new Set,errors:{},bookmarks:{}},zK=r=>Hm(Object.assign(Object.assign({},jK),r),e=>{e.addCase(Be.fetchBookmark.success,(t,n)=>{n.payload.id in t.bookmarks&&(t.bookmarks[n.payload.id]=n.payload)}).addCase(Be.fetchBookmarkData.success,(t,n)=>{var i;const{bookmarkId:o,data:a}=n.payload;((i=t.currentBookmark)===null||i===void 0?void 0:i.id)===o&&(t.currentBookmark.payload=a)}).addCase(Be.fetchBookmarks.success,(t,n)=>{t.bookmarks=n.payload.reduce((i,o)=>(i[o.id]=o,i),{})}).addCase(Be.setBookmark,(t,n)=>{var i;const o=n.payload.id;o in t.bookmarks&&(t.bookmarks[o]=n.payload),((i=t.currentBookmark)===null||i===void 0?void 0:i.id)===o&&(t.currentBookmark=n.payload)}).addCase(Be.setCurrentBookmark,(t,n)=>{t.currentBookmark=n.payload}).addCase(Be.createBookmark.success,(t,n)=>{const i=n.payload,{payload:o}=i,a=FK(i,["payload"]);t.bookmarks[a.id]=a}).addCase(Be.updateBookmark.success,(t,n)=>{var i;const o=n.payload.id,a=o in t.bookmarks,c=((i=t.currentBookmark)===null||i===void 0?void 0:i.id)===o,d=a?t.bookmarks[o]:c?t.currentBookmark:null,h=Object.assign(Object.assign({},d),n.payload);a&&(t.bookmarks[o]=h),c&&(t.currentBookmark=h)}).addCase(Be.deleteBookmark.success,(t,n)=>{delete t.bookmarks[n.payload]}).addCase(Be.removeBookmarkAsFavourite.success,(t,n)=>{delete t.bookmarks[n.payload]}).addMatcher(vP,(t,n)=>{const i=O0(n);t.status.add(i)}).addMatcher(gP,(t,n)=>{const i=O0(n);delete t.errors[i]}).addMatcher(q6,(t,n)=>{const i=O0(n);t.errors[i]=n.payload}).addMatcher(yP,(t,n)=>{const i=O0(n);t.status.delete(i)})});class Hl extends Error{constructor(e,t,n){super(e,n),this.action=t,this.name="BookmarkProcessError"}}class kr extends Error{constructor(e,t){super(e,t),this.name="BookmarkProviderError"}}const a8=200,BK=r=>e=>e.pipe($e(Be.fetchBookmark.match),k6(n=>n.payload),Jn(n=>n.pipe(E6(a8))),Wt(n=>rt(r.getBookmarkById(n.payload)).pipe(Ti(),me(i=>Be.fetchBookmark.success(i,n.meta)),Vt(i=>It(Be.fetchBookmark.failure(new Hl("Failed to fetch bookmark",n,{cause:i}),n.meta)))))),UK=r=>e=>e.pipe($e(Be.fetchBookmarkData.match),k6(n=>JSON.stringify(n.payload)),Jn(n=>n.pipe(E6(a8))),Wt(n=>rt(r.getBookmarkData(n.payload)).pipe(Ti(),me(i=>Be.fetchBookmarkData.success(n.payload,i,n.meta)),Vt(i=>It(Be.fetchBookmarkData.failure(new Hl("Failed to fetch bookmark payload",n,{cause:i}),n.meta)))))),qK=r=>e=>e.pipe($e(Be.fetchBookmarks.match),k6(n=>JSON.stringify(n.payload)),Wt(n=>n.pipe(E6(a8))),Wt(n=>rt(r.getAllBookmarks(n.payload)).pipe(Ti(),me(i=>Be.fetchBookmarks.success(i,n.meta)),Vt(i=>It(Be.fetchBookmarks.failure(new Hl("Failed to fetch all bookmarks",n,{cause:i}),n.meta)))))),WK=r=>e=>e.pipe($e(Be.createBookmark.match),_s(n=>rt(r.createBookmark(n.payload)).pipe(Ti(),me(i=>Be.createBookmark.success(i,n.meta)),Vt(i=>It(Be.createBookmark.failure(new Hl("Failed to create new bookmark",n,{cause:i}),n.meta)))))),GK=r=>e=>e.pipe($e(Be.updateBookmark.match),_s(n=>{const{bookmarkId:i,updates:o}=n.payload;return rt(r.updateBookmark(i,o)).pipe(Ti(),me(a=>Be.updateBookmark.success(a,n.meta)),Vt(a=>It(Be.updateBookmark.failure(new Hl("Failed to update bookmark",n,{cause:a}),n.meta))))})),KK=r=>e=>e.pipe($e(Be.deleteBookmark.match),_s(n=>rt(r.deleteBookmark(n.payload)).pipe(Ti(),me(()=>Be.deleteBookmark.success(n.payload,n.meta)),Vt(i=>It(Be.deleteBookmark.failure(new Hl("Failed to delete bookmark",n,{cause:i}),n.meta)))))),YK=r=>e=>e.pipe($e(Be.removeBookmarkAsFavourite.match),_s(n=>rt(r.removeBookmarkFromFavorites(n.payload)).pipe(Ti(),me(()=>Be.removeBookmarkAsFavourite.success(n.payload,n.meta)),Vt(i=>It(Be.removeBookmarkAsFavourite.failure(new Hl("Failed to remove bookmark as favorite",n,{cause:i}),n.meta)))))),QK=r=>e=>e.pipe($e(Be.addBookmarkAsFavourite.match),_s(n=>rt(r.addBookmarkToFavorites(n.payload)).pipe(Ti(),me(()=>Be.addBookmarkAsFavourite.success(n.payload,n.meta)),Vt(i=>It(Be.addBookmarkAsFavourite.failure(new Hl("Failed to add bookmark as favorite",n,{cause:i}),n.meta)))))),XK=r=>e=>{const t=e.pipe($e(Be.removeBookmark.match),_s(({payload:a})=>rt(r.isBookmarkFavorite(a)).pipe(me(c=>(c?Be.removeBookmarkAsFavourite:Be.deleteBookmark)(a))))),n=P3(e.pipe($e(Be.deleteBookmark.failure.match)),e.pipe($e(Be.removeBookmarkAsFavourite.failure.match))).pipe(me(a=>Be.removeBookmark.failure(a.payload,a.meta))),i=P3(e.pipe($e(Be.deleteBookmark.success.match)),e.pipe($e(Be.removeBookmarkAsFavourite.success.match))).pipe(me(a=>Be.removeBookmark.success({type:Ag(a.type),bookmarkId:a.payload},a.meta)));return xl(t,P3(n,i))},JK=r=>(e,t)=>It(BK,UK,qK,WK,GK,KK,XK,YK,QK).pipe(Jn(n=>n(r)(e,t))),eY=r=>{const e=new Lm(zK(r.initial));return e.addFlow(JK(r.client)),e},_E=r=>Object.values(r.bookmarks),Z0=(r,e)=>r.bookmarks[e],h_=r=>r.currentBookmark,tY=r=>Object.values(r.errors),kM="2.1.2";var _d=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})},vt=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},f_=function(r,e,t,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?r!==e||!i:!e.has(r))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(r,t):i?i.value=t:e.set(r,t),t},rY=function(r,e){var t={};for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&e.indexOf(n)<0&&(t[n]=r[n]);if(r!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,n=Object.getOwnPropertySymbols(r);i<n.length;i++)e.indexOf(n[i])<0&&Object.prototype.propertyIsEnumerable.call(r,n[i])&&(t[n[i]]=r[n[i]]);return t},Oi,rr,bd,wd;const xd=2*60*1e3;let nY=class{get config(){return{getCurrentAppIdentification(){return window.Fusion.modules.app.current.appKey}}}addStateCreator(e){console.warn("addStateCreator is deprecated, use addPayloadGenerator instead"),this.addPayloadGenerator(e)}deleteBookmarkByIdAsync(e){return console.warn("deleteBookmarkByIdAsync is deprecated, use deleteBookmarkAsync instead"),this.deleteBookmarkAsync(e)}addBookmarkFavoriteAsync(e){return console.warn("addBookmarkFavoriteAsync is deprecated, use addBookmarkToFavoritesAsync instead"),this.addBookmarkToFavoritesAsync(e)}removeBookmarkFavoriteAsync(e){return console.warn("removeBookmarkFavoriteAsync is deprecated, use removeBookmarkAsFavoriteAsync instead"),this.removeBookmarkAsFavoriteAsync(e)}getBookmarkById(e){return console.warn("getBookmarkById is deprecated, use getBookmarkAsync instead"),this.getBookmarkAsync(e)}get version(){return new fs(kM)}get filters(){return vt(this,Oi,"f").filters}get client(){return vt(this,Oi,"f").client}get currentBookmark$(){return vt(this,rr,"f").select(h_,u_)}get bookmarks$(){return this.getAllBookmarksAsync(),vt(this,rr,"f").select(_E,u_)}get bookmarks(){return _E(vt(this,rr,"f").value)}get currentBookmark(){return h_(vt(this,rr,"f").value)}get status$(){return vt(this,rr,"f").select(e=>e.status)}get errors$(){return vt(this,rr,"f").select(tY,u_)}get canCreateBookmarks(){return vt(this,bd,"f").length>0}get sourceSystem(){return vt(this,Oi,"f").sourceSystem}get resolvedApplication(){return vt(this,Oi,"f").resolve.application}get resolvedContext(){return vt(this,Oi,"f").resolve.context}get _apiClient(){return vt(this,Oi,"f").client}get _log(){return vt(this,Oi,"f").log}get _resolve(){return vt(this,Oi,"f").resolve}get _event(){return vt(this,Oi,"f").eventProvider}get _parent(){return vt(this,Oi,"f").parent}constructor(e){var t,n,i;if(Oi.set(this,void 0),rr.set(this,void 0),bd.set(this,[]),wd.set(this,new ti),f_(this,Oi,e,"f"),f_(this,rr,eY({client:e.client,initial:{currentBookmark:(n=(t=this._parent)===null||t===void 0?void 0:t.currentBookmark)!==null&&n!==void 0?n:null}}),"f"),vt(this,wd,"f").add(()=>vt(this,rr,"f").complete()),vt(this,wd,"f").add(vt(this,rr,"f").action$.subscribe(o=>{var a,c;q6(o)?(a=this._log)===null||a===void 0||a.error(`Action: ${o.type}`,o):(c=this._log)===null||c===void 0||c.debug(`Action: ${o.type}`,o)})),vt(this,wd,"f").add(vt(this,rr,"f").select(h_).subscribe(o=>{o!==void 0&&this._dispatchEvent("onCurrentBookmarkChanged",{detail:o})})),this._event&&this._event.addEventListener("onCurrentBookmarkChanged",o=>{const{source:a,detail:c}=o;c!==void 0&&a!==this&&c!==this.currentBookmark&&vt(this,rr,"f").next(Be.setCurrentBookmark(c))}),this._parent)try{vt(this,wd,"f").add(this._parent.currentBookmark$.pipe($e(o=>o!==void 0),$e(o=>o!==this.currentBookmark)).subscribe(o=>{vt(this,rr,"f").next(Be.setCurrentBookmark(o))}))}catch(o){(i=this._log)===null||i===void 0||i.error("Failed to subscribe to parent bookmark provider",o)}}on(e,t){var n,i;return this._event?(i=this._event)===null||i===void 0?void 0:i.addEventListener(e,o=>{o.source===this&&t(o)}):((n=this._log)===null||n===void 0||n.warn("Failed to register event listener, event provider not configured"),()=>{})}addPayloadGenerator(e){var t;return(t=this._log)===null||t===void 0||t.debug(`adding bookmark payload generator: ${e.name}`),vt(this,bd,"f").push(e),this._dispatchEvent("onBookmarkPayloadCreatorAdded",{detail:e}),()=>{var n;(n=this._log)===null||n===void 0||n.debug(`removing bookmark payload generator: ${e.name}`),f_(this,bd,vt(this,bd,"f").filter(i=>i!==e),"f")}}generatePayload(e){var t;return(t=this._log)===null||t===void 0||t.debug("generating payload",e),rt(vt(this,bd,"f")).pipe(PR((i,o)=>this._producePayload(i,o),e??{},1),Br(i=>{var o;return(o=this._log)===null||o===void 0?void 0:o.debug("generated payload",{initial:e,payload:i})}))}_producePayload(e,t,n){return B6(e,i=>_d(this,void 0,void 0,function*(){var o,a,c;try{const d=yield Promise.resolve(t(i,n));if(d)return(o=this._log)===null||o===void 0||o.warn(`bookmark data generator ${t.name} returned a value, but it should not do this, since the data is an immer draft object`),JSON.parse(JSON.stringify(d));if(d===null){(a=this._log)===null||a===void 0||a.info(`bookmark data generator ${t.name} wish to clear the bookmark data`);return}}catch(d){(c=this._log)===null||c===void 0||c.error(`Failed to produce payload using generator ${t.name}`,d)}}))}getBookmark(e,t){var n;return(n=this._log)===null||n===void 0||n.debug(`fetching bookmark: ${e}`,t),pv({bookmark:this._getBookmarkInfo(e),payload:t!=null&&t.excludePayload?It({}):this._getBookmarkData(e)}).pipe(Vt(i=>{var o;throw(o=this._log)===null||o===void 0||o.error(`Failed to fetch bookmark: ${e}`,i),i}),me(({bookmark:i,payload:o})=>Object.assign({},i,{payload:o})),Br(i=>{var o;(o=this._log)===null||o===void 0||o.debug(`Bookmark fetched: ${i.id}`,i)}))}getBookmarkAsync(e,t){return lr(this.getBookmark(e,t))}getAllBookmarks(){return new Tt(e=>{var t,n,i;(t=this._log)===null||t===void 0||t.debug("fetching all bookmarks");const o=pv({sourceSystem:It(this.sourceSystem),appKey:!((n=vt(this,Oi,"f").filters)===null||n===void 0)&&n.application?rt(this._resolve.application()).pipe(me(d=>d==null?void 0:d.appKey)):It(void 0),contextId:!((i=vt(this,Oi,"f").filters)===null||i===void 0)&&i.context?rt(this._resolve.context()).pipe(me(d=>d==null?void 0:d.id)):It(void 0)}).pipe(Vt(d=>{var h;const u=new kr("Could not fetch bookmarks, failed to resolve filter parameters",d);throw(h=this._log)===null||h===void 0||h.error(u.message,u),u}));e.add(o.subscribe(d=>{vt(this,rr,"f").next(Be.fetchBookmarks(d))}));const a=vt(this,rr,"f").action$.pipe($e(Be.fetchBookmarks.failure.match),me(d=>{var h;throw(h=this._log)===null||h===void 0||h.error("Failed to fetch bookmarks",d.payload),new kr("Failed to fetch bookmarks",d.payload)}),Gs({each:xd,with:()=>{throw new kr("Timeout while fetching bookmarks")}}));vt(this,rr,"f").action$.pipe($e(Be.fetchBookmarks.success.match),me(d=>d.payload),Br(d=>{var h;(h=this._log)===null||h===void 0||h.debug("fetched all bookmarks",d)}),Kc(a),Ks()).subscribe(e)})}getAllBookmarksAsync(){return _d(this,void 0,void 0,function*(){return lr(this.getAllBookmarks())})}setCurrentBookmark(e){var t;return e==this.currentBookmark?It(e):((t=this._log)===null||t===void 0||t.debug("setting current bookmark",e),(typeof e=="string"?this.getBookmark(e):It(e??null)).pipe(Wt(i=>_d(this,void 0,void 0,function*(){var o,a,c;const d=this.currentBookmark,{type:h,canceled:u}=yield this._dispatchEvent("onCurrentBookmarkChange",{detail:{current:d,next:i}});if(u){const p=new kr(`event: ${h} was canceled by listener for change to ${(o=i==null?void 0:i.id)!==null&&o!==void 0?o:"none"}, from ${(a=d==null?void 0:d.id)!==null&&a!==void 0?a:"none"}`);throw(c=this._log)===null||c===void 0||c.info(p.message),p}return i})),Br(i=>{vt(this,rr,"f").next(Be.setCurrentBookmark(i))}),Vt(i=>{var o;const a=new kr("Could not set current bookmark, resolve of bookmark failed",i);throw(o=this._log)===null||o===void 0||o.error(a.message,a),a})))}setCurrentBookmarkAsync(e){return lr(this.setCurrentBookmark(e))}createBookmark(e){return new Tt(t=>{var n;const{ref:i,action$:o}=this._useScopedActions();(n=this._log)===null||n===void 0||n.debug(`creating new bookmark, ref: ${i}`,e);const c=pv({appKey:e.appKey?It(e.appKey):rt(this._resolve.application()).pipe(me(u=>{if(!(u!=null&&u.appKey))throw new kr("Failed to resolve application key");return u.appKey})),contextId:this._resolve.context().then(u=>u==null?void 0:u.id),payload:this.generatePayload(e.payload),sourceSystem:It(this.sourceSystem)}).pipe(Vt(u=>{var p;const v=new kr("Could not create new bookmark, failed to resolve bookmark data",u);throw(p=this._log)===null||p===void 0||p.error(v.message,v),v}),me(u=>Object.assign(Object.assign({},e),u))).pipe(Wt(u=>_d(this,void 0,void 0,function*(){var p;const{canceled:v,type:g}=yield this._dispatchEvent("onBookmarkCreate",{detail:u,cancelable:!0});if(v){const _=new kr(`event: ${g} was canceled by listener for creating bookmark: ${i}`);throw(p=this._log)===null||p===void 0||p.info(_.message),_}return u})));t.add(c.subscribe({error:u=>t.error(u),next:u=>{vt(this,rr,"f").next(Be.createBookmark(u,{ref:i}))}}));const d=o.pipe($e(Be.createBookmark.failure.match),me(({payload:u})=>{var p;const v=new kr(`Failed to create bookmark: ${i}`,{cause:u});throw(p=this._log)===null||p===void 0||p.warn(v.message),v}),Gs({each:xd,with:()=>{throw new kr(`Timeout while creating bookmark: ${i}`)}}));o.pipe($e(Be.createBookmark.success.match),me(({payload:u})=>u),Br(u=>{var p;(p=this._log)===null||p===void 0||p.info(`Bookmark created: ${u.id}, ref: ${i}`),this._dispatchEvent("onBookmarkCreated",{detail:u})}),Kc(d),Ks()).subscribe(t)})}createBookmarkAsync(e){return lr(this.createBookmark(e))}updateBookmark(e,t,n){if(!t&&(n!=null&&n.excludePayloadGeneration))throw new kr("Cannot update bookmark without updates and excludePayloadGeneration option");return new Tt(i=>{var o;const{ref:a,action$:c}=this._useScopedActions();(o=this._log)===null||o===void 0||o.debug(`Updating bookmark: ${e}, ref: ${a}`);const h=(n!=null&&n.excludePayloadGeneration?It(t):this.generatePayload(t==null?void 0:t.payload).pipe(me(v=>Object.assign(Object.assign({},t),{payload:v})))).pipe(Wt(v=>_d(this,void 0,void 0,function*(){var g;const{canceled:_,type:b}=yield this._dispatchEvent("onBookmarkUpdate",{detail:{current:Z0(vt(this,rr,"f").value,e),updates:v},cancelable:!0});if(_){const C=new kr(`event: ${b} was canceled by listener for updating bookmark: ${e}, ref: ${a}`);throw(g=this._log)===null||g===void 0||g.warn(C.message,v),C}return v})));i.add(h.subscribe({error:v=>i.error(v),next:v=>{vt(this,rr,"f").next(Be.updateBookmark({bookmarkId:e,updates:v},{ref:a}))}}));const u=c.pipe($e(Be.updateBookmark.failure.match),me(({payload:v})=>{var g;const _=new kr(`Failed to update bookmark: ${e}`,{cause:v});throw(g=this._log)===null||g===void 0||g.info(_.message),_}),Gs({each:xd,with:()=>{throw new kr(`Timeout while updating bookmark: ${e}`)}}));c.pipe($e(Be.updateBookmark.success.match),me(({payload:v})=>Object.assign(Object.assign({},Z0(vt(this,rr,"f").value,v.id)),{payload:v.payload})),Br(v=>{var g;(g=this._log)===null||g===void 0||g.info(`Bookmark updated: ${v.id}, ref: ${a}`),this._dispatchEvent("onBookmarkUpdated",{detail:v})}),Kc(u),Ks()).subscribe(i)})}updateBookmarkAsync(e,t,n){if(typeof e=="object"){console.warn("updateBookmarkAsync(bookmark, updates, options) is deprecated, use updateBookmarkAsync(id, updates, options) instead");const i=e,{id:o}=i,a=rY(i,["id"]);return lr(this.updateBookmark(o,a,{excludePayloadGeneration:!t.updatePayload}).pipe(me(c=>c.payload)))}return lr(this.updateBookmark(e,t,n))}deleteBookmark(e){return new Tt(t=>{var n,i;const{ref:o,action$:a}=this._useScopedActions();(n=this._log)===null||n===void 0||n.debug(`Removing bookmark: ${e}, ref: ${o}`);const c=(i=Z0(vt(this,rr,"f").value,e))!==null&&i!==void 0?i:{id:e},d=rt(this._dispatchEvent("onBookmarkDelete",{detail:c,cancelable:!0})).pipe(me(({canceled:p,type:v,detail:g})=>{var _;if(p){const b=new kr(`event: ${v} was canceled by listener for removing bookmark: ${e}, ref: ${o}`);throw(_=this._log)===null||_===void 0||_.warn(b.message),b}return g}));t.add(d.subscribe({error:p=>t.error(p),next:p=>{vt(this,rr,"f").next(Be.deleteBookmark(p.id,{ref:o}))}}));const h=a.pipe($e(Be.deleteBookmark.failure.match),me(({payload:p})=>{var v;const g=new kr(`Failed to update bookmark: ${e}`,{cause:p});throw(v=this._log)===null||v===void 0||v.warn(g.message),g}),Gs({each:xd,with:()=>{throw new kr(`Timeout while updating bookmark: ${e}`)}}));a.pipe($e(Be.deleteBookmark.success.match),me(()=>{}),Br(()=>{var p;(p=this._log)===null||p===void 0||p.info(`Removed bookmark: ${c.id}, ref: ${o}`),this._dispatchEvent("onBookmarkDeleted",{detail:c})}),Kc(h),Ks()).subscribe(t)})}deleteBookmarkAsync(e){return _d(this,void 0,void 0,function*(){return lr(this.deleteBookmark(e))})}addBookmarkToFavorites(e){return new Tt(n=>{var i;const{ref:o,action$:a}=this._useScopedActions();(i=this._log)===null||i===void 0||i.debug(`Adding bookmark: ${e} to favourites, ref: ${o}`);const c=rt(this._dispatchEvent("onBookmarkFavouriteAdd",{detail:{id:e},cancelable:!0})).pipe(me(({canceled:u,type:p})=>{var v;if(u){const g=new kr(`event: ${p} was canceled by listener for adding favourite bookmark: ${e}, ref: ${o}`);throw(v=this._log)===null||v===void 0||v.info(g.message),g}}));n.add(c.subscribe({error:u=>n.error(u),next:()=>{vt(this,rr,"f").next(Be.addBookmarkAsFavourite(e,{ref:o}))}}));const d=a.pipe($e(Be.addBookmarkAsFavourite.failure.match),me(({payload:u})=>{var p;const v=new kr(`Failed to add bookmark to favorites: ${e}`,{cause:u});throw(p=this._log)===null||p===void 0||p.warn(v.message),v}),Gs({each:xd,with:()=>{throw new kr(`Timeout while adding bookmark to favorites: ${e}`)}}));return a.pipe($e(Be.addBookmarkAsFavourite.success.match),Wt(({payload:u})=>this.getBookmark(u,{excludePayload:!0})),Br(u=>{var p;(p=this._log)===null||p===void 0||p.info(`Added bookmark: ${e} to favourites, ref: ${o}`),this._dispatchEvent("onBookmarkFavouriteAdded",{detail:u})}),Kc(d),Ks()).subscribe(n)})}addBookmarkToFavoritesAsync(e){return lr(this.addBookmarkToFavorites(e))}removeBookmarkAsFavorite(e){return new Tt(n=>{var i,o;const{ref:a,action$:c}=this._useScopedActions();(i=this._log)===null||i===void 0||i.debug(`Removing bookmark: ${e} from favourites, ref: ${a}`);const d=(o=Z0(vt(this,rr,"f").value,e))!==null&&o!==void 0?o:{id:e},h=rt(this._dispatchEvent("onBookmarkFavouriteRemove",{detail:d,cancelable:!0})).pipe(me(({canceled:v,type:g,detail:_})=>{var b;if(v){const C=new kr(`event: ${g} was canceled by listener for removing favourite bookmark: ${e}, ref: ${a}`);throw(b=this._log)===null||b===void 0||b.warn(C.message),C}return _}));n.add(h.subscribe({error:v=>n.error(v),next:v=>{vt(this,rr,"f").next(Be.removeBookmarkAsFavourite(v.id,{ref:a}))}}));const u=c.pipe($e(Be.removeBookmarkAsFavourite.failure.match),me(({payload:v})=>{var g;const _=new kr(`Failed to remove bookmark: ${e} from favourites`,{cause:v});throw(g=this._log)===null||g===void 0||g.warn(_.message),_}),Gs({each:xd,with:()=>{throw new kr(`Timeout while removing bookmark: ${e} from favourites`)}}));c.pipe($e(Be.removeBookmarkAsFavourite.success.match),Br(()=>{var v;(v=this._log)===null||v===void 0||v.info(`Removed bookmark: ${e} from favourites, ref: ${a}`),this._dispatchEvent("onBookmarkFavouriteRemoved",{detail:d})}),me(()=>{}),Kc(u),Ks()).subscribe(n)})}removeBookmarkAsFavoriteAsync(e){return lr(this.removeBookmarkAsFavorite(e))}isBookmarkInFavorites(e){var t;return(t=this._log)===null||t===void 0||t.debug(`Checking if bookmark: ${e} is in favourites`),rt(this._apiClient.isBookmarkFavorite(e)).pipe(Vt(n=>{var i;const o=new kr(`Failed to check if bookmark: ${e} is in favourites`,n);throw(i=this._log)===null||i===void 0||i.error(o.message,o),o}),Br(n=>{var i;(i=this._log)===null||i===void 0||i.debug(`Bookmark: ${e} is ${n?"in":"not in"} favourites`)}))}isBookmarkInFavoritesAsync(e){return lr(this.isBookmarkInFavorites(e))}_getBookmarkInfo(e,t){var n;const{action$:i}=this._useScopedActions(e),o=i.pipe($e(Be.fetchBookmark.success.match),me(c=>c.payload),Ks()),a=vt(this,rr,"f").action$.pipe($e(Be.fetchBookmark.failure.match),me(c=>{throw new kr(`Failed to fetch bookmark data: ${e}`,c.payload)}),Gs({each:(n=t==null?void 0:t.timeout)!==null&&n!==void 0?n:2*60*1e3,with:()=>{throw new kr(`Timeout while fetching bookmark data: ${e}`)}}));return vt(this,rr,"f").next(Be.fetchBookmark(e,{ref:e})),o.pipe(Kc(a))}_getBookmarkData(e,t){var n;const{action$:i}=this._useScopedActions(e),o=i.pipe($e(Be.fetchBookmarkData.success.match),me(c=>c.payload.data),Ks()),a=vt(this,rr,"f").action$.pipe($e(Be.fetchBookmarkData.failure.match),me(c=>{throw new kr(`Failed to fetch bookmark data: ${e}`,c.payload)}),Gs({each:(n=t==null?void 0:t.timeout)!==null&&n!==void 0?n:xd,with:()=>{throw new kr(`Timeout while fetching bookmark data: ${e}`)}}));return vt(this,rr,"f").next(Be.fetchBookmarkData(e,{ref:e})),o.pipe(Kc(a))}_dispatchEvent(e,t){return _d(this,void 0,void 0,function*(){var n,i;const o=new ZR(e,Object.assign({source:this,canBubble:!0},t));if(this._event){(n=this._log)===null||n===void 0||n.debug(`dispatching event ${e}`,t);const{canceled:a}=yield this._event.dispatchEvent(o);a&&((i=this._log)===null||i===void 0||i.debug(`event ${e} was canceled`,t))}return o})}_useScopedActions(e){e??(e=sm());const t=vt(this,rr,"f").action$.pipe($e(n=>{var i;return"meta"in n&&((i=n.meta)===null||i===void 0?void 0:i.ref)===e}));return{ref:e,action$:t}}dispose(){var e;(e=this._log)===null||e===void 0||e.debug("disposing BookmarkProvider"),vt(this,wd,"f").unsubscribe()}[(Oi=new WeakMap,rr=new WeakMap,bd=new WeakMap,wd=new WeakMap,Symbol.dispose)](){this.dispose()}};var iY=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};const oY="bookmark",aY=new Dm("BookmarkModule"),sY={name:oY,version:new fs(kM),configure:r=>{var e;const t=((e=r==null?void 0:r.log)===null||e===void 0?void 0:e.createSubLogger("BookmarkModule"))||aY,n=r==null?void 0:r.ref;return new NK({log:t,ref:n})},initialize:r=>iY(void 0,void 0,void 0,function*(){var e;const t=(e=r.ref)===null||e===void 0?void 0:e.bookmark,n=yield lr(r.config.createConfig(r,{filters:t==null?void 0:t.filters,sourceSystem:t==null?void 0:t.sourceSystem,resolve:t?{application:t.resolvedApplication.bind(t),context:t.resolvedContext.bind(t)}:void 0}));return new nY(n)}),dispose:r=>{r.instance.dispose()}};var cY=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};const lY=(r,e)=>{r.addConfig({module:sY,configure:t=>cY(void 0,void 0,void 0,function*(){e&&Promise.resolve(e(t))})})};class dY{}/**
409
+ `}}R([se({type:String,reflect:!0})],Wm.prototype,"size",void 0);R([se({type:String,reflect:!0})],Wm.prototype,"color",void 0);Wm.styles=rK;const vM="fwc-circular-progress";let uE=class extends Wm{};uE=R([Cr(vM)],uE);const nK=zm(Um,pM);zm(Wm,vM);zm(qm,mM);const gM=({children:r,text:e})=>k.jsx("div",{style:{display:"flex",justifyContent:"center",alignItems:"center",width:"100vw",height:"100vh",overflow:"hidden"},children:k.jsx(nK,{text:e,children:r})}),iK=()=>({setManifest:on("set_manifest",(r,e)=>({payload:r,meta:{created:Date.now(),update:e}})),fetchManifest:vi("fetch_manifest",(r,e)=>({payload:r,meta:{update:e}}),r=>({payload:r}),r=>({payload:r})),setConfig:on("set_config",r=>({payload:r})),fetchConfig:vi("fetch_config",r=>({payload:r}),r=>({payload:r}),r=>({payload:r})),setSettings:on("set_settings",r=>({payload:r})),fetchSettings:vi("fetch_settings",r=>({payload:{appKey:r}}),r=>({payload:r}),r=>({payload:r})),updateSettings:vi("update_settings",(r,e)=>({payload:{appKey:r,settings:e}}),r=>({payload:r}),r=>({payload:r})),updateSettingsAbort:on("update_settings::abort",r=>({payload:r})),setModule:on("set_module",r=>({payload:r})),importApp:vi("import_app",r=>({payload:r}),r=>({payload:r}),r=>({payload:r})),setInstance:on("set_instance",r=>({payload:r})),initialize:vi("initialize_app",()=>({payload:null}),()=>({payload:null}),r=>({payload:r}))}),lt=iK();xj();const oK=r=>Hm(Object.assign(Object.assign({},r),{status:new Set}),e=>e.addCase(lt.setManifest,(t,n)=>{var i;n.meta.update?t.manifest=Object.assign((i=t.manifest)!==null&&i!==void 0?i:{},n.payload):t.manifest=n.payload}).addCase(lt.setConfig,(t,n)=>{t.config=n.payload}).addCase(lt.setSettings,(t,n)=>{t.settings=n.payload}).addCase(lt.setModule,(t,n)=>{t.modules=n.payload}).addCase(lt.setInstance,(t,n)=>{t.instance=n.payload}).addMatcher(vP,(t,n)=>{t.status.add(Ag(n.type))}).addMatcher(yP,(t,n)=>{t.status.delete(Ag(n.type))})),aK=r=>e=>e.pipe($e(lt.fetchManifest.match),Wt(t=>{const{payload:n,meta:{update:i}}=t,o=rt(r.getAppManifest(n)).pipe($e(a=>!!a),Vf());return xl(o.pipe(me(a=>lt.setManifest(a,i))),o.pipe(Ti(),me(a=>lt.fetchManifest.success(a)))).pipe(Vt(a=>It(lt.fetchManifest.failure(a))))})),sK=r=>e=>e.pipe($e(lt.fetchConfig.match),Wt(({payload:t})=>{var n;const i=rt(r.getAppConfig(t.appKey,(n=t.build)===null||n===void 0?void 0:n.version)).pipe($e(o=>!!o),Vf());return xl(i.pipe(me(o=>lt.setConfig(o))),i.pipe(Ti(),me(o=>lt.fetchConfig.success(o)))).pipe(Vt(o=>It(lt.fetchConfig.failure(o))))})),cK=r=>e=>e.pipe($e(lt.fetchSettings.match),Wt(({payload:t})=>{const{appKey:n}=t,i=rt(r.getAppSettings(n)).pipe($e(o=>!!o),Vf());return xl(i.pipe(me(o=>lt.setSettings(o))),i.pipe(Ti(),me(o=>lt.fetchSettings.success(o)))).pipe(Vt(o=>It(lt.fetchSettings.failure(o))))})),lK=r=>e=>e.pipe($e(lt.updateSettings.match)).pipe(Wt(({payload:t})=>{const{appKey:n,settings:i}=t;return r.updateAppSettings(n,i).pipe(Ti(),_s(o=>rt([lt.setSettings(o),lt.updateSettings.success(o)])),Vt(o=>It(lt.updateSettings.failure(o))))})),dK=r=>e=>e.pipe($e(lt.importApp.match),Wt(({payload:t})=>{const n=[r.assetUri,t].join("/").replace(/\/{2,}/g,"/");return rt(import(n)).pipe(me(lt.importApp.success),Vt(i=>It(lt.importApp.failure(i))))})),uK=(r,e)=>{const t=oK(r),n=new Lm(t);return n.addFlow(aK(e)),n.addFlow(sK(e)),n.addFlow(cK(e)),n.addFlow(lK(e)),n.addFlow(dK(e)),n};var hK=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})},ze=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},fK=function(r,e,t,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?r!==e||!i:!e.has(r))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(r,t):i?i.value=t:e.set(r,t),t},sw,De,yM;function Nh(){return $e(r=>r!=null)}const pK={};class mK{get manifest$(){return ze(this,De,"f").select(e=>e.manifest).pipe(Nh())}get config$(){return ze(this,De,"f").select(e=>e.config,Nb).pipe(Nh())}get modules$(){return ze(this,De,"f").select(e=>e.modules).pipe(Nh())}get instance$(){return ze(this,De,"f").select(e=>e.instance).pipe(Nh())}get settings$(){return new Tt(e=>{ze(this,De,"f").next(lt.fetchSettings(this.appKey)),e.add(ze(this,De,"f").select(t=>t.settings,Nb).pipe(Nh(),x6(pK)).subscribe(e))})}get status$(){return ze(this,De,"f").select(e=>e.status)}get state(){return Object.freeze(ze(this,De,"f").value)}get appKey(){return ze(this,De,"f").value.appKey}get manifest(){return this.state.manifest}get manifestAsync(){return zn(this.manifest$)}get config(){return this.state.config}get configAsync(){return zn(this.config$)}get instance(){return ze(this,De,"f").value.instance}constructor(e,t){sw.add(this),De.set(this,void 0),fK(this,De,uK(e,t.provider),"f");const{appKey:n}=e,{event:i}=t;i&&ze(this,sw,"m",yM).call(this,i);const o=new ti;i&&(o.add(()=>{i.dispatchEvent("onAppDispose",{detail:{appKey:n}})}),o.add(i.addEventListener("onAppModulesLoaded",a=>{a.detail.appKey===n&&ze(this,De,"f").next(lt.setInstance(a.detail.modules))}))),this.dispose=()=>{o==null||o.unsubscribe(),ze(this,De,"f").value.instance&&ze(this,De,"f").value.instance.dispose(),ze(this,De,"f").complete()}}initialize(){return new Tt(e=>{ze(this,De,"f").next(lt.initialize()),e.add(TN([this.getManifest(),this.getAppModule(),this.getConfig()]).subscribe({next:([t,n,i])=>e.next({manifest:t,script:n,config:i}),error:t=>{e.error(t),ze(this,De,"f").next(lt.initialize.failure(t))},complete:()=>{ze(this,De,"f").next(lt.initialize.success()),e.complete()}}))})}loadConfig(){(this.manifest?It(this.manifest):this.getManifest()).subscribe({next:e=>{ze(this,De,"f").next(lt.fetchConfig(e))}})}loadManifest(e){ze(this,De,"f").next(lt.fetchManifest(this.appKey,e))}updateManifest(e,t){ze(this,De,"f").next(lt.setManifest(e,!t))}loadAppModule(){return hK(this,arguments,void 0,function*(e=!0){var t;const n=yield this.getManifestAsync(e);!((t=n.build)===null||t===void 0)&&t.entryPoint?ze(this,De,"f").next(lt.importApp(n.build.entryPoint)):console.warn(`The ${n.appKey} is missing entryPoint, please upload a build for the app before continuing`)})}getConfig(e=!1){return new Tt(t=>{if(ze(this,De,"f").value.config&&(t.next(ze(this,De,"f").value.config),!e))return t.complete();t.add(ze(this,De,"f").addEffect("set_config",({payload:n})=>{t.next(n)})),t.add(ze(this,De,"f").addEffect("fetch_config::success",({payload:n})=>{t.next(n),t.complete()})),t.add(ze(this,De,"f").addEffect("fetch_config::failure",({payload:n})=>{t.error(Error("failed to load application config",{cause:n}))})),this.loadConfig()})}getConfigAsync(e=!0){return(e?zn:lr)(this.getConfig(!e))}getSettings(e=!1){return new Tt(t=>{if(ze(this,De,"f").value.settings&&(t.next(ze(this,De,"f").value.settings),!e))return t.complete();t.add(ze(this,De,"f").addEffect("set_settings",({payload:n})=>{t.next(n)})),t.add(ze(this,De,"f").addEffect("fetch_settings::success",({payload:n})=>{t.next(n),t.complete()})),t.add(ze(this,De,"f").addEffect("fetch_settings::failure",({payload:n})=>{t.error(Error("failed to load application settings",{cause:n}))})),ze(this,De,"f").next(lt.fetchSettings(this.appKey))})}getSettingsAsync(e=!0){return(e?zn:lr)(this.getSettings(!e))}updateSettings(e){return new Tt(t=>{t.add(ze(this,De,"f").addEffect("update_settings::failure",({payload:n})=>{ze(this,De,"f").next(lt.fetchSettings(this.appKey)),t.error(Error("failed to update application settings",{cause:n}))})),t.add(ze(this,De,"f").addEffect("update_settings::success",({payload:n})=>{t.next(n),t.complete()})),ze(this,De,"f").next(lt.setSettings(e)),ze(this,De,"f").next(lt.updateSettings(this.appKey,e))})}updateSettingsAsync(e){return lr(this.updateSettings(e))}updateSetting(e,t){return(ze(this,De,"f").value.settings===void 0?this.getSettings().pipe(Ti()):It(ze(this,De,"f").value.settings)).pipe(me(i=>Object.assign(Object.assign({},i),{[e]:t})),Wt(i=>this.updateSettings(i)),me(i=>i[e]))}updateSettingAsync(e,t){return lr(this.updateSetting(e,t))}getManifest(e=!1){return new Tt(t=>{if(ze(this,De,"f").value.manifest&&(t.next(ze(this,De,"f").value.manifest),!e))return t.complete();t.add(ze(this,De,"f").addEffect("set_manifest",({payload:n})=>{t.next(n)})),t.add(ze(this,De,"f").addEffect("fetch_manifest::success",({payload:n})=>{t.next(n),t.complete()})),t.add(ze(this,De,"f").addEffect("fetch_manifest::failure",({payload:n})=>{t.error(Error("failed to load application manifest",{cause:n}))})),this.loadManifest()})}getManifestAsync(e=!0){return(e?zn:lr)(this.getManifest(!e))}getAppModule(e=!1){return new Tt(t=>{if(ze(this,De,"f").value.modules&&(t.next(ze(this,De,"f").value.modules),!e))return t.complete();t.add(ze(this,De,"f").addEffect("set_module",({payload:n})=>{t.next(n)})),t.add(ze(this,De,"f").addEffect("import_app::success",({payload:n})=>{t.next(n),t.complete()})),t.add(ze(this,De,"f").addEffect("import_app::failure",({payload:n})=>{t.error(Error("failed to load application modules from script",{cause:n}))})),t.add(this.getManifest().subscribe(n=>{var i,o;if(!((i=n.build)===null||i===void 0)&&i.entryPoint){const a=(o=n.build.assetPath)!==null&&o!==void 0?o:[n.appKey,n.build.version].join("@");ze(this,De,"f").next(lt.importApp([a,n.build.entryPoint].join("/")))}else console.error(`The ${n.appKey} app is missing a entry in the manifest, upload a build for your app before continuing`)}))})}getAppModuleAsync(e=!0){return(e?zn:lr)(this.getAppModule(!e))}}De=new WeakMap,sw=new WeakSet,yM=function(e){const{appKey:t}=this;ze(this,De,"f").addEffect(lt.fetchManifest.type,()=>{e.dispatchEvent("onAppManifestLoad",{detail:{appKey:t},source:this})}),ze(this,De,"f").addEffect(lt.fetchManifest.success.type,n=>{e.dispatchEvent("onAppManifestLoaded",{detail:{appKey:t,manifest:n.payload},source:this})}),ze(this,De,"f").addEffect(lt.fetchManifest.failure.type,n=>{e.dispatchEvent("onAppManifestFailure",{detail:{appKey:t,error:n.payload},source:this})}),ze(this,De,"f").addEffect(lt.fetchConfig.type,()=>{e.dispatchEvent("onAppConfigLoad",{detail:{appKey:t},source:this})}),ze(this,De,"f").addEffect(lt.fetchConfig.success.type,n=>{e.dispatchEvent("onAppConfigLoaded",{detail:{appKey:t,config:n.payload},source:this})}),ze(this,De,"f").addEffect(lt.fetchConfig.failure.type,n=>{e.dispatchEvent("onAppConfigFailure",{detail:{appKey:t,error:n.payload},source:this})}),ze(this,De,"f").addEffect(lt.fetchSettings.type,()=>{e.dispatchEvent("onAppSettingsLoad",{detail:{appKey:t},source:this})}),ze(this,De,"f").addEffect(lt.fetchSettings.success.type,n=>{e.dispatchEvent("onAppSettingsLoaded",{detail:{appKey:t,settings:n.payload},source:this})}),ze(this,De,"f").addEffect(lt.fetchSettings.failure.type,n=>{e.dispatchEvent("onAppSettingsFailure",{detail:{appKey:t,error:n.payload},source:this})}),ze(this,De,"f").addEffect(lt.updateSettings.type,n=>{e.dispatchEvent("onAppSettingsUpdate",{detail:{appKey:t,settings:n.payload.settings},source:this})}),ze(this,De,"f").addEffect(lt.updateSettings.success.type,n=>{e.dispatchEvent("onAppSettingsUpdated",{detail:{appKey:t,settings:n.payload.settings},source:this})}),ze(this,De,"f").addEffect(lt.updateSettings.failure.type,n=>{e.dispatchEvent("onAppSettingsUpdateFailure",{detail:{appKey:t,settings:n.payload},source:this})}),ze(this,De,"f").addEffect(lt.importApp.type,()=>{e.dispatchEvent("onAppScriptLoad",{detail:{appKey:t},source:this})}),ze(this,De,"f").addEffect(lt.importApp.success.type,n=>{e.dispatchEvent("onAppScriptLoaded",{detail:{appKey:t,script:n.payload},source:this})}),ze(this,De,"f").addEffect(lt.importApp.failure.type,n=>{e.dispatchEvent("onAppScriptFailure",{detail:{appKey:t,error:n.payload},source:this})}),ze(this,De,"f").addEffect(lt.initialize.type,()=>{e.dispatchEvent("onAppInitialize",{detail:{appKey:t},source:this})}),ze(this,De,"f").addEffect(lt.initialize.success.type,()=>{e.dispatchEvent("onAppInitialized",{detail:{appKey:t},source:this})}),ze(this,De,"f").addEffect(lt.initialize.failure.type,({payload:n})=>{e.dispatchEvent("onAppInitializeFailure",{detail:{appKey:t,error:n},source:this})})};const vK="6.1.8";var $i=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},P0=function(r,e,t,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?r!==e||!i:!e.has(r))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(r,t):i?i.value=t:e.set(r,t),t},sl,Rv,cl,yp,Pv;class gK{static compareAppManifest(e,t){return JSON.stringify(e)===JSON.stringify(t)}get version(){return new fs(vK)}get current(){return $i(this,cl,"f").value}get current$(){return $i(this,cl,"f").pipe(rg((e,t)=>e&&t?e.appKey===t.appKey:e===t))}constructor(e){var t;sl.set(this,void 0),Rv.set(this,void 0),cl.set(this,void 0),yp.set(this,new ti),Pv.set(this,void 0);const{event:n,config:i}=e;P0(this,sl,i.client,"f"),P0(this,Pv,n,"f"),P0(this,cl,new Df(void 0),"f"),P0(this,Rv,(t=i.assetUri)!==null&&t!==void 0?t:"","f"),$i(this,yp,"f").add(this.current$.pipe(ig(),MR(()=>!!n)).subscribe(([o,a])=>{n==null||n.dispatchEvent("onCurrentAppChanged",{source:this,detail:{previous:o,next:a}})})),$i(this,yp,"f").add($i(this,cl,"f").pipe(ig(),me(([o])=>o),Nh()).subscribe(o=>o.dispose()))}getAppManifest(e){return rt($i(this,sl,"f").getAppManifest({appKey:e}))}getAppManifests(e){return rt($i(this,sl,"f").getAppManifests(e))}getAllAppManifests(){return this.getAppManifests()}getAppConfig(e,t){return rt($i(this,sl,"f").getAppConfig({appKey:e,tag:t}))}getAppSettings(e){return rt($i(this,sl,"f").getAppSettings({appKey:e}))}updateAppSettings(e,t){return rt($i(this,sl,"f").updateAppSettings({appKey:e,settings:t}))}setCurrentApp(e){const t=typeof e=="string"?this.createApp({appKey:e}):e;$i(this,cl,"f").next(t)}clearCurrentApp(){$i(this,cl,"f").next(null)}get assetUri(){return $i(this,Rv,"f")}createApp(e){return console.warn(),new mK(e,{provider:this,event:$i(this,Pv,"f")})}dispose(){$i(this,yp,"f").unsubscribe()}}sl=new WeakMap,Rv=new WeakMap,cl=new WeakMap,yp=new WeakMap,Pv=new WeakMap;var yK=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};const cw="app",_K={name:cw,configure:()=>new IK,initialize:r=>yK(void 0,void 0,void 0,function*(){const e=yield r.config.createConfigAsync(r),t=yield r.requireInstance("event").catch(()=>{});return new gK({config:e,event:t})}),dispose:r=>{r.instance.dispose()}},bK=F.object({environment:F.record(F.any()).optional().default({}),endpoints:F.record(F.object({url:F.string(),scopes:F.array(F.string()).optional().default([])})).optional()}),lw=F.object({azureUniqueId:F.string({description:"The unique identifier for the person in Azure."}),displayName:F.string({description:"The display name of the person."}),mail:F.string({description:"The email address of the person, which can be null or undefined."}).nullish(),upn:F.string({description:"The User Principal Name (UPN) of the person, which can be null or undefined."}).nullish(),accountType:F.string({description:"The type of account the person has."}),accountClassification:F.string({description:"The classification of the account, which can be null or undefined."}).nullish(),isExpired:F.boolean({description:"Indicates whether the account is expired, which can be null or undefined."}).nullish()}),wK=F.object({version:F.string(),entryPoint:F.string(),tags:F.array(F.string()).nullish(),tag:F.enum(["latest","preview"]).nullish(),assetPath:F.string().nullish(),configUrl:F.string().nullish(),timestamp:F.string().nullish(),commitSha:F.string().nullish(),githubRepo:F.string().nullish(),projectPage:F.string().nullish(),allowedExtensions:F.array(F.string()).nullish(),uploadedBy:lw.nullish()}),xK=F.object({appKey:F.string(),displayName:F.string(),description:F.string(),type:F.string(),isPinned:F.boolean().nullish(),templateSource:F.string().nullish(),category:F.object({id:F.string(),name:F.string(),displayName:F.string(),color:F.string(),defaultIcon:F.string(),sortOrder:F.number()}).nullish(),visualization:F.object({color:F.string().nullish(),icon:F.string().nullish(),sortOrder:F.number()}).nullish(),keywords:F.array(F.string()).nullish(),admins:F.array(lw).nullish(),owners:F.array(lw).nullish(),build:wK.nullish()});class El extends Error{static fromHttpResponse(e,t){switch(e.status){case 401:return new El("unauthorized","failed to load application manifest, request not authorized",t);case 404:return new El("not_found","application manifest not found",t)}return new El("unknown",`failed to load application manifest, status code ${e.status}`,t)}constructor(e,t,n){super(t,n),this.type=e}}class hu extends Error{static fromHttpResponse(e,t){switch(e.status){case 401:return new hu("unauthorized","failed to load application config, request not authorized",t);case 404:return new hu("not_found","application config not found",t)}return new hu("unknown",`failed to load application config, status code ${e.status}`,t)}constructor(e,t,n){super(t,n),this.type=e}}class fu extends Error{static fromHttpResponse(e,t){switch(e.status){case 401:return new fu("unauthorized","failed to load application settings, request not authorized",t);case 404:return new fu("not_found","application not found",t)}return new fu("unknown",`failed to load application settings, status code ${e.status}`,t)}constructor(e,t,n){super(t,n),this.type=e}}var hE=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},CK=function(r,e,t,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?r!==e||!i:!e.has(r))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(r,t):i?i.value=t:e.set(r,t),t},_p;const _M=r=>{for(const e of Object.keys(r))typeof r[e]=="object"&&r[e]!==null&&!Object.isFrozen(r[e])&&_M(r[e]);return Object.freeze(r)};class kK{get endpoints(){return console.warn("endpoints is deprecated, use getEndpoint instead"),new Proxy(hE(this,_p,"f"),{get(e,t){var n;return(n=e[t])===null||n===void 0?void 0:n.url}})}constructor(e){var t,n;_p.set(this,void 0),this.environment=_M((t=e.environment)!==null&&t!==void 0?t:{}),CK(this,_p,(n=e.endpoints)!==null&&n!==void 0?n:{},"f")}getEndpoint(e){return hE(this,_p,"f")[e]}}_p=new WeakMap;var EK=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};const SK=r=>EK(void 0,void 0,void 0,function*(){const e=yield gf(r),t=bK.parse(e);return new kK(t)});var fE=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})},F1=function(r,e,t,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?r!==e||!i:!e.has(r))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(r,t):i?i.value=t:e.set(r,t),t},rs=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},TK=function(r,e){var t={};for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&e.indexOf(n)<0&&(t[n]=r[n]);if(r!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,n=Object.getOwnPropertySymbols(r);i<n.length;i++)e.indexOf(n[i])<0&&Object.prototype.propertyIsEnumerable.call(r,n[i])&&(t[n[i]]=r[n[i]]);return t},j1,z1,B1,Sh,M0;const pE=xK.transform(r=>{const{category:e}=r,t=TK(r,["category"]);return Object.assign(Object.assign({},t),{get key(){return t.appKey},get name(){return t.displayName},categoryId:e==null?void 0:e.id,category:e})});class AK{constructor(e){j1.set(this,void 0),z1.set(this,void 0),B1.set(this,void 0),Sh.set(this,void 0),M0.set(this,void 0),F1(this,M0,e,"f");const t=1*60*1e3;F1(this,j1,new xi({client:{fn:({appKey:n})=>e.json(`/persons/me/apps/${n}`,{headers:{"Api-Version":"1.0"},selector:i=>fE(this,void 0,void 0,function*(){return pE.parse(yield gf(i))})})},queueOperator:"merge",key:({appKey:n})=>n,expire:t}),"f"),F1(this,z1,new xi({client:{fn:n=>{const i=n!=null&&n.filterByCurrentUser?"/persons/me/apps":"/apps?=$expand=category,admins,owners,keywords";return e.json(i,{headers:{"Api-Version":"1.0"},selector:o=>fE(this,void 0,void 0,function*(){const a=yield gf(o);return pE.array().parse(a.value)})})}},key:n=>n!=null&&n.filterByCurrentUser?"currentUser":"all",expire:t}),"f"),F1(this,B1,new xi({client:{fn:({appKey:n,tag:i="latest"})=>e.json(`/apps/${n}/builds/${i}/config`,{selector:SK,headers:{"Api-Version":"1.0"}})},queueOperator:"merge",key:n=>JSON.stringify(n),expire:t}),"f"),F1(this,Sh,new xi({client:{fn:({appKey:n})=>e.json(`/persons/me/apps/${n}/settings`,{headers:{"Api-Version":"1.0"}})},key:n=>n.appKey,expire:t}),"f")}getAppManifest(e){return rs(this,j1,"f").query(e).pipe(lf,Vt(t=>{const{cause:n}=t;throw n instanceof El?n:n instanceof su?El.fromHttpResponse(n.response,{cause:n}):new El("unknown","failed to load manifest",{cause:n})}))}getAppManifests(e){return rs(this,z1,"f").query(e).pipe(lf)}getAppConfig(e){return rs(this,B1,"f").query(e).pipe(me(t=>t.value),Vt(t=>{const{cause:n}=t;throw n instanceof hu?n:n instanceof su?hu.fromHttpResponse(n.response,{cause:n}):new hu("unknown","failed to load config",{cause:n})}))}getAppSettings(e){return rs(this,Sh,"f").query(e).pipe(lf,Vt(t=>{const{cause:n}=t;throw n instanceof fu?n:n instanceof su?fu.fromHttpResponse(n.response,{cause:n}):new fu("unknown","failed to load settings",{cause:n})}))}updateAppSettings(e){const{appKey:t,settings:n}=e;return rs(this,M0,"f").json$(`/persons/me/apps/${t}/settings`,{method:"PUT",body:n,headers:{"Api-Version":"1.0"}}).pipe(Br(i=>{rs(this,Sh,"f").mutate({appKey:t},{value:i,updated:Date.now()})}))}[(j1=new WeakMap,z1=new WeakMap,B1=new WeakMap,Sh=new WeakMap,M0=new WeakMap,Symbol.dispose)](){console.warn("AppClient disposed"),rs(this,j1,"f").complete(),rs(this,z1,"f").complete(),rs(this,B1,"f").complete(),rs(this,Sh,"f").complete()}}var l_=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};class IK extends Mm{constructor(){super(...arguments),this.defaultExpireTime=1*60*1e3}_createHttpClient(e){return l_(this,void 0,void 0,function*(){const t=yield e.requireInstance("http");return t.hasClient(cw)?t.createClient(cw):yield(yield e.requireInstance("serviceDiscovery")).createClient("apps")})}setClient(e){const t=typeof e=="object"?()=>e:e;this._set("client",t)}setAssetUri(e){const t=typeof e=="string"?()=>l_(this,void 0,void 0,function*(){return e}):e;this._set("assetUri",t)}_createConfig(e,t){return this._has("client")||this.setClient(()=>l_(this,void 0,void 0,function*(){const n=yield this._createHttpClient(e);return new AK(n)})),this._has("assetUri")||this.setAssetUri("/apps-proxy"),super._createConfig(e,t)}}var RK=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};const PK=(r,e)=>{r.addConfig({module:_K,configure:t=>RK(void 0,void 0,void 0,function*(){})})},bM=(r,e,t)=>{x.useEffect(()=>{const n=r.subscribe(e);return n.add(t),()=>n.unsubscribe()},[r,e])},MK=(r,e,t)=>{x.useLayoutEffect(()=>{const n=r.subscribe(e);return n.add(t),()=>n.unsubscribe()},[r,e])};function ks(r,e){const t=x.useCallback(()=>{var p,v;return(v=(p=e==null?void 0:e.initial)!==null&&p!==void 0?p:r.value)!==null&&v!==void 0?v:void 0},[r,e==null?void 0:e.initial]),n=x.useRef(t()),[i,o]=x.useState(n.current),[a,c]=x.useState(null),[d,h]=x.useState(!1);x.useLayoutEffect(()=>{n.current=t()},[t]),x.useLayoutEffect(()=>{c(null),h(!1),o(n.current)},[r]);const u=x.useMemo(()=>({next:o,error:c,complete:()=>h(!0)}),[]);return MK(r,u,e==null?void 0:e.teardown),{value:i,error:a,complete:d}}const mE=Om({id:bi(),name:bi(),mail:bi().optional()}),wM=Om({identifier:bi(),name:bi().nullish(),subSystem:bi().nullish()},{message:"invalid source system"}),$K=Om({id:bi(),name:bi().optional(),type:bi().optional()}),xM=Om({id:bi(),name:bi(),appKey:bi(),description:bi().optional(),isShared:T6().optional(),created:Sb(),createdBy:mE,updated:Sb().optional(),updatedBy:mE.optional(),context:$K.optional(),sourceSystem:wM.nullish()});WR(xM);const OK=(r=GR(qR()).or(bi()).optional())=>xM.extend({payload:r});var $0=function(r,e,t,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?r!==e||!i:!e.has(r))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(r,t):i?i.value=t:e.set(r,t),t},Fr=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},$g=function(r,e){var t={};for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&e.indexOf(n)<0&&(t[n]=r[n]);if(r!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,n=Object.getOwnPropertySymbols(r);i<n.length;i++)e.indexOf(n[i])<0&&Object.prototype.propertyIsEnumerable.call(r,n[i])&&(t[n[i]]=r[n[i]]);return t},yo,Dh,ll,ec;const vE=Gb["1.0"].transform(r=>({azureUniqueId:r.azureUniqueId,id:r.azureUniqueId,name:r.name,email:r.mail})),dw=r=>{const e=r,{createdBy:t,updatedBy:n}=e,i=$g(e,["createdBy","updatedBy"]);return OK().parse(Object.assign(Object.assign({},i),{createdBy:vE.parse(t),updatedBy:n?vE.parse(n):void 0}))},gE=r=>{const e=dw(r),{payload:t}=e;return $g(e,["payload"])};class ZK{constructor(e,t){yo.set(this,void 0),Dh.set(this,void 0),ll.set(this,void 0),ec.set(this,void 0),$0(this,yo,e,"f");const{expire:n=5*60*1e3}=t??{};$0(this,Dh,new xi({client:{fn:i=>Fr(this,yo,"f").get("v2",i).pipe(me(gE))},key:i=>i.bookmarkId,expire:n}),"f"),$0(this,ll,new xi({client:{fn:i=>Fr(this,yo,"f").query("v2",{filter:i}).pipe(me(o=>o.map(gE)))},key:i=>JSON.stringify(i??""),expire:n}),"f"),$0(this,ec,new xi({client:{fn:i=>Fr(this,yo,"f").getPayload("v1",i).pipe(me(o=>o.payload))},key:i=>i.bookmarkId,expire:n,cache:{trimming:{size:3}}}),"f")}getAllBookmarks(e){return Fr(this,ll,"f").query(e).pipe(me(t=>t.value))}getBookmarkById(e){return Fr(this,Dh,"f").query({bookmarkId:e}).pipe(me(t=>t.value))}getBookmarkData(e){return Fr(this,ec,"f").query({bookmarkId:e}).pipe(me(t=>t.value))}setBookmarkData(e,t){return Fr(this,yo,"f").patch("v1",{bookmarkId:e,updates:{payload:t}}).pipe(me(n=>n.payload),Br(n=>{n&&Fr(this,ec,"f").mutate({bookmarkId:e},{value:n,updated:Date.now()},{allowCreation:!0})}))}createBookmark(e){return Fr(this,yo,"f").create("v1",e).pipe(me(t=>dw(t)),Br(t=>{console.log("createdBookmark",t);const{payload:n}=t,i=$g(t,["payload"]);Fr(this,Dh,"f").mutate({bookmarkId:i.id},{value:i,updated:Date.now()},{allowCreation:!0}),n&&Fr(this,ec,"f").mutate({bookmarkId:i.id},{value:n,updated:Date.now()},{allowCreation:!0}),Fr(this,ll,"f").invalidate()}))}updateBookmark(e,t){const n=Fr(this,yo,"f").patch("v1",{bookmarkId:e,updates:t}).pipe(me(i=>dw(i)),zN());return new Tt(i=>{i.add(n.subscribe(o=>{const{payload:a}=o,c=$g(o,["payload"]);Fr(this,Dh,"f").mutate({bookmarkId:e},{value:c,updated:Date.now()},{allowCreation:!1})})),i.add(n.subscribe(o=>{const{payload:a}=o;if(a)Fr(this,ec,"f").mutate({bookmarkId:o.id},{value:a,updated:Date.now()},{allowCreation:!0});else{const c=Fr(this,ec,"f").generateCacheKey({bookmarkId:o.id});Fr(this,ec,"f").cache.removeItem(c)}})),i.add(n.subscribe(()=>{Fr(this,ll,"f").invalidate()})),n.subscribe(i)})}deleteBookmark(e){return Fr(this,yo,"f").delete("v1",{bookmarkId:e})}addBookmarkToFavorites(e){return Fr(this,yo,"f").addFavourite("v1",{bookmarkId:e}).pipe(Br(()=>Fr(this,ll,"f").invalidate()))}removeBookmarkFromFavorites(e){return Fr(this,yo,"f").removeFavourite("v1",{bookmarkId:e}).pipe(Br(()=>Fr(this,ll,"f").invalidate()))}isBookmarkFavorite(e){return Fr(this,yo,"f").isFavorite("v1",{bookmarkId:e})}}yo=new WeakMap,Dh=new WeakMap,ll=new WeakMap,ec=new WeakMap;const CM=F.object({log:F.custom().optional(),logLevel:F.nativeEnum(un).optional(),eventProvider:F.custom().optional(),sourceSystem:wM.optional().describe("The source system for the bookmarks"),parent:F.custom().describe("Parent Bookmark provider").optional().nullable(),client:F.custom().describe("API client for interacting with bookmarks"),resolve:F.object({context:F.function().returns(F.promise(F.object({id:F.string()}).optional())),application:F.function().returns(F.promise(F.object({appKey:F.string(),name:F.string().optional()}).optional()))}).describe("Functions for resolving context and application"),filters:F.object({context:F.boolean().optional().default(!1),application:F.boolean().optional().default(!1)}).describe("Flags for enabling resolving when fetching bookmarks").optional().default({context:!1,application:!1})});var mi=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})},LK=function(r,e,t,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?r!==e||!i:!e.has(r))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(r,t):i?i.value=t:e.set(r,t),t},Yr=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},Rr;const HK=CM.pick({filters:!0,sourceSystem:!0,resolve:!0}).partial().optional();class NK extends Mm{constructor(e){super(),Rr.set(this,void 0),this.defaultExpireTime=1*60*1e3;const{log:t}=e??{};LK(this,Rr,t,"f"),this._set("log",()=>mi(this,void 0,void 0,function*(){return t}))}setLogLevel(e){this._set("logLevel",()=>mi(this,void 0,void 0,function*(){return e})),Yr(this,Rr,"f")&&(Yr(this,Rr,"f").level=e)}setClient(e){typeof e=="function"?this._set("client",t=>e(t)):this._set("client",()=>mi(this,void 0,void 0,function*(){return e}))}setParent(e){typeof e=="function"?this._set("parent",t=>e(t)):this._set("parent",()=>mi(this,void 0,void 0,function*(){return e}))}setSourceSystem(e){typeof e=="function"?this._set("sourceSystem",e):this._set("sourceSystem",()=>mi(this,void 0,void 0,function*(){return e}))}setContextResolver(e){this._set("resolve.context",e)}setApplicationResolver(e){this._set("resolve.application",e)}setFilter(e,t){this._set(`filters.${e}`,()=>mi(this,void 0,void 0,function*(){return t}))}_createConfig(e,t){var n,i,o,a,c,d,h;if(!this._has("parent")){(n=Yr(this,Rr,"f"))===null||n===void 0||n.debug("No parent provided, using default parent");const u=e.ref;if(u&&"bookmark"in u){const p=u.bookmark;"version"in p&&p.version.satisfies(">=2.0.0")?this._set("parent",()=>mi(this,void 0,void 0,function*(){return p})):(i=Yr(this,Rr,"f"))===null||i===void 0||i.warn("invalid version of parent BookmarkProvider provided")}else(o=Yr(this,Rr,"f"))===null||o===void 0||o.info("No parent BookmarkProvider found")}return this._has("client")||((a=Yr(this,Rr,"f"))===null||a===void 0||a.debug("No client provided, using default client"),this._set("client",this._createDefaultClient.bind(this))),this._has("resolve.context")||((c=Yr(this,Rr,"f"))===null||c===void 0||c.debug("No context resolver provided, using default context resolver"),this._set("resolve.context",this._createDefaultContextResolver.bind(this))),this._has("resolve.application")||((d=Yr(this,Rr,"f"))===null||d===void 0||d.debug("No application resolver provided, using default application resolver"),this._set("resolve.application",this._createDefaultApplicationResolver.bind(this))),this._has("eventProvider")||((h=Yr(this,Rr,"f"))===null||h===void 0||h.debug("No event provider provided, using default event provider"),this._set("eventProvider",this._resolveEventProvider.bind(this))),super._createConfig(e,HK.parse(t))}_createDefaultContextResolver(e){return mi(this,void 0,void 0,function*(){var t,n;if(e.hasModule("context")){(t=Yr(this,Rr,"f"))===null||t===void 0||t.debug("Context module available, awaiting instance");const i=yield e.requireInstance("context");return(n=Yr(this,Rr,"f"))===null||n===void 0||n.debug("Context provider available, creating context resolver"),()=>mi(this,void 0,void 0,function*(){var o,a;(o=Yr(this,Rr,"f"))===null||o===void 0||o.debug("Resolving context for bookmarks");const c=(a=i.currentContext)===null||a===void 0?void 0:a.id;return c?{id:c}:void 0})}})}_createDefaultApplicationResolver(e){return mi(this,void 0,void 0,function*(){var t,n;if(e.hasModule("app")){(t=Yr(this,Rr,"f"))===null||t===void 0||t.debug("App module available, awaiting instance");const i=yield e.requireInstance("app");return(n=Yr(this,Rr,"f"))===null||n===void 0||n.debug("App provider available, creating application resolver"),()=>mi(this,void 0,void 0,function*(){var o,a;const c=i.current;if(c)return{appKey:c.appKey,name:(o=c.manifest)===null||o===void 0?void 0:o.name};(a=Yr(this,Rr,"f"))===null||a===void 0||a.warn("No current application found")})}})}_resolveAppProvider(e){return mi(this,void 0,void 0,function*(){var t,n;if(e.hasModule("app"))return(t=Yr(this,Rr,"f"))===null||t===void 0||t.debug("App module available, awaiting instance"),e.requireInstance("app");(n=Yr(this,Rr,"f"))===null||n===void 0||n.debug("No app module available, will use ref to app module if available")})}_resolveEventProvider(e){return mi(this,void 0,void 0,function*(){var t;if(e.hasModule("event"))return(t=Yr(this,Rr,"f"))===null||t===void 0||t.debug("Event module available, awaiting instance"),e.requireInstance("event")})}_createDefaultClient(e){return mi(this,void 0,void 0,function*(){var t;try{const i=yield(yield this._getServiceProvider(e)).createBookmarksClient("json$");return new ZK(i)}catch{(t=Yr(this,Rr,"f"))===null||t===void 0||t.warn("Failed to create bookmark api client")}})}_getServiceProvider(e){return mi(this,void 0,void 0,function*(){var t,n,i,o;if(e.hasModule("services"))return(t=Yr(this,Rr,"f"))===null||t===void 0||t.debug("Services module available, awaiting instance"),e.requireInstance("services");(n=Yr(this,Rr,"f"))===null||n===void 0||n.debug("No services module available, will use ref services module if available");const a=(i=e.ref)===null||i===void 0?void 0:i.services;if(a)return a;throw(o=Yr(this,Rr,"f"))===null||o===void 0||o.error("No service provider available, cannot create bookmarks client"),Error("[BookmarkConfigurator] No service provider configures [ServicesModule] ")})}_processConfig(e,t){return mi(this,void 0,void 0,function*(){var n,i;try{return CM.parse(e)}catch(o){throw(n=Yr(this,Rr,"f"))===null||n===void 0||n.error("Failed to parse config",e,(i=o.issues)!==null&&i!==void 0?i:o),o}})}}Rr=new WeakMap;var d_,yE;function DK(){return yE||(yE=1,d_=function r(e,t){if(e===t)return!0;if(e&&t&&typeof e=="object"&&typeof t=="object"){if(e.constructor!==t.constructor)return!1;var n,i,o;if(Array.isArray(e)){if(n=e.length,n!=t.length)return!1;for(i=n;i--!==0;)if(!r(e[i],t[i]))return!1;return!0}if(e instanceof Map&&t instanceof Map){if(e.size!==t.size)return!1;for(i of e.entries())if(!t.has(i[0]))return!1;for(i of e.entries())if(!r(i[1],t.get(i[0])))return!1;return!0}if(e instanceof Set&&t instanceof Set){if(e.size!==t.size)return!1;for(i of e.entries())if(!t.has(i[0]))return!1;return!0}if(ArrayBuffer.isView(e)&&ArrayBuffer.isView(t)){if(n=e.length,n!=t.length)return!1;for(i=n;i--!==0;)if(e[i]!==t[i])return!1;return!0}if(e.constructor===RegExp)return e.source===t.source&&e.flags===t.flags;if(e.valueOf!==Object.prototype.valueOf)return e.valueOf()===t.valueOf();if(e.toString!==Object.prototype.toString)return e.toString()===t.toString();if(o=Object.keys(e),n=o.length,n!==Object.keys(t).length)return!1;for(i=n;i--!==0;)if(!Object.prototype.hasOwnProperty.call(t,o[i]))return!1;for(i=n;i--!==0;){var a=o[i];if(!r(e[a],t[a]))return!1}return!0}return e!==e&&t!==t}),d_}var VK=DK();const u_=Hu(VK),Be={aborted:on("action_aborted",r=>({payload:r})),setBookmark:on("set_bookmark",r=>({payload:r})),setCurrentBookmark:on("set_current_bookmark",r=>({payload:r})),fetchBookmark:vi("fetch_bookmark",(r,e)=>({payload:r,meta:e}),(r,e)=>({payload:r,meta:e}),(r,e)=>({payload:r,meta:e})),fetchBookmarkData:vi("fetch_bookmark_payload",(r,e)=>({payload:r,meta:e}),(r,e,t)=>({payload:{bookmarkId:r,data:e},meta:t}),(r,e)=>({payload:r,meta:e})),fetchBookmarks:vi("fetch_bookmarks",(r,e)=>({payload:r,meta:e}),(r,e)=>({payload:r,meta:e}),(r,e)=>({payload:r,meta:e})),updateBookmark:vi("set_bookmark",(r,e)=>({payload:r,meta:e}),(r,e)=>({payload:r,meta:e}),(r,e)=>({payload:r,meta:e})),createBookmark:vi("create_bookmark",(r,e)=>({payload:r,meta:e}),(r,e)=>({payload:r,meta:e}),(r,e)=>({payload:r,meta:e})),deleteBookmark:vi("delete_bookmark",(r,e)=>({payload:r,meta:Object.assign({ref:r},e)}),(r,e)=>({payload:r,meta:Object.assign({ref:r},e)}),(r,e)=>({payload:r,meta:e})),removeBookmark:vi("remove_bookmark",(r,e)=>({payload:r,meta:Object.assign({ref:r},e)}),(r,e)=>({payload:r,meta:e}),(r,e)=>({payload:r,meta:e})),addBookmarkAsFavourite:vi("add_favourite_bookmark",(r,e)=>({payload:r,meta:Object.assign({ref:r},e)}),(r,e)=>({payload:r,meta:Object.assign({ref:r},e)}),(r,e)=>({payload:r,meta:e})),removeBookmarkAsFavourite:vi("remove_favourite_bookmark",(r,e)=>({payload:r,meta:Object.assign({ref:r},e)}),(r,e)=>({payload:r,meta:Object.assign({ref:r},e)}),(r,e)=>({payload:r,meta:e}))};var FK=function(r,e){var t={};for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&e.indexOf(n)<0&&(t[n]=r[n]);if(r!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,n=Object.getOwnPropertySymbols(r);i<n.length;i++)e.indexOf(n[i])<0&&Object.prototype.propertyIsEnumerable.call(r,n[i])&&(t[n[i]]=r[n[i]]);return t};const O0=r=>Ag(r.type),jK={status:new Set,errors:{},bookmarks:{}},zK=r=>Hm(Object.assign(Object.assign({},jK),r),e=>{e.addCase(Be.fetchBookmark.success,(t,n)=>{n.payload.id in t.bookmarks&&(t.bookmarks[n.payload.id]=n.payload)}).addCase(Be.fetchBookmarkData.success,(t,n)=>{var i;const{bookmarkId:o,data:a}=n.payload;((i=t.currentBookmark)===null||i===void 0?void 0:i.id)===o&&(t.currentBookmark.payload=a)}).addCase(Be.fetchBookmarks.success,(t,n)=>{t.bookmarks=n.payload.reduce((i,o)=>(i[o.id]=o,i),{})}).addCase(Be.setBookmark,(t,n)=>{var i;const o=n.payload.id;o in t.bookmarks&&(t.bookmarks[o]=n.payload),((i=t.currentBookmark)===null||i===void 0?void 0:i.id)===o&&(t.currentBookmark=n.payload)}).addCase(Be.setCurrentBookmark,(t,n)=>{t.currentBookmark=n.payload}).addCase(Be.createBookmark.success,(t,n)=>{const i=n.payload,{payload:o}=i,a=FK(i,["payload"]);t.bookmarks[a.id]=a}).addCase(Be.updateBookmark.success,(t,n)=>{var i;const o=n.payload.id,a=o in t.bookmarks,c=((i=t.currentBookmark)===null||i===void 0?void 0:i.id)===o,d=a?t.bookmarks[o]:c?t.currentBookmark:null,h=Object.assign(Object.assign({},d),n.payload);a&&(t.bookmarks[o]=h),c&&(t.currentBookmark=h)}).addCase(Be.deleteBookmark.success,(t,n)=>{delete t.bookmarks[n.payload]}).addCase(Be.removeBookmarkAsFavourite.success,(t,n)=>{delete t.bookmarks[n.payload]}).addMatcher(vP,(t,n)=>{const i=O0(n);t.status.add(i)}).addMatcher(gP,(t,n)=>{const i=O0(n);delete t.errors[i]}).addMatcher(q6,(t,n)=>{const i=O0(n);t.errors[i]=n.payload}).addMatcher(yP,(t,n)=>{const i=O0(n);t.status.delete(i)})});class Hl extends Error{constructor(e,t,n){super(e,n),this.action=t,this.name="BookmarkProcessError"}}class kr extends Error{constructor(e,t){super(e,t),this.name="BookmarkProviderError"}}const a8=200,BK=r=>e=>e.pipe($e(Be.fetchBookmark.match),k6(n=>n.payload),Jn(n=>n.pipe(E6(a8))),Wt(n=>rt(r.getBookmarkById(n.payload)).pipe(Ti(),me(i=>Be.fetchBookmark.success(i,n.meta)),Vt(i=>It(Be.fetchBookmark.failure(new Hl("Failed to fetch bookmark",n,{cause:i}),n.meta)))))),UK=r=>e=>e.pipe($e(Be.fetchBookmarkData.match),k6(n=>JSON.stringify(n.payload)),Jn(n=>n.pipe(E6(a8))),Wt(n=>rt(r.getBookmarkData(n.payload)).pipe(Ti(),me(i=>Be.fetchBookmarkData.success(n.payload,i,n.meta)),Vt(i=>It(Be.fetchBookmarkData.failure(new Hl("Failed to fetch bookmark payload",n,{cause:i}),n.meta)))))),qK=r=>e=>e.pipe($e(Be.fetchBookmarks.match),k6(n=>JSON.stringify(n.payload)),Wt(n=>n.pipe(E6(a8))),Wt(n=>rt(r.getAllBookmarks(n.payload)).pipe(Ti(),me(i=>Be.fetchBookmarks.success(i,n.meta)),Vt(i=>It(Be.fetchBookmarks.failure(new Hl("Failed to fetch all bookmarks",n,{cause:i}),n.meta)))))),WK=r=>e=>e.pipe($e(Be.createBookmark.match),_s(n=>rt(r.createBookmark(n.payload)).pipe(Ti(),me(i=>Be.createBookmark.success(i,n.meta)),Vt(i=>It(Be.createBookmark.failure(new Hl("Failed to create new bookmark",n,{cause:i}),n.meta)))))),GK=r=>e=>e.pipe($e(Be.updateBookmark.match),_s(n=>{const{bookmarkId:i,updates:o}=n.payload;return rt(r.updateBookmark(i,o)).pipe(Ti(),me(a=>Be.updateBookmark.success(a,n.meta)),Vt(a=>It(Be.updateBookmark.failure(new Hl("Failed to update bookmark",n,{cause:a}),n.meta))))})),KK=r=>e=>e.pipe($e(Be.deleteBookmark.match),_s(n=>rt(r.deleteBookmark(n.payload)).pipe(Ti(),me(()=>Be.deleteBookmark.success(n.payload,n.meta)),Vt(i=>It(Be.deleteBookmark.failure(new Hl("Failed to delete bookmark",n,{cause:i}),n.meta)))))),YK=r=>e=>e.pipe($e(Be.removeBookmarkAsFavourite.match),_s(n=>rt(r.removeBookmarkFromFavorites(n.payload)).pipe(Ti(),me(()=>Be.removeBookmarkAsFavourite.success(n.payload,n.meta)),Vt(i=>It(Be.removeBookmarkAsFavourite.failure(new Hl("Failed to remove bookmark as favorite",n,{cause:i}),n.meta)))))),QK=r=>e=>e.pipe($e(Be.addBookmarkAsFavourite.match),_s(n=>rt(r.addBookmarkToFavorites(n.payload)).pipe(Ti(),me(()=>Be.addBookmarkAsFavourite.success(n.payload,n.meta)),Vt(i=>It(Be.addBookmarkAsFavourite.failure(new Hl("Failed to add bookmark as favorite",n,{cause:i}),n.meta)))))),XK=r=>e=>{const t=e.pipe($e(Be.removeBookmark.match),_s(({payload:a})=>rt(r.isBookmarkFavorite(a)).pipe(me(c=>(c?Be.removeBookmarkAsFavourite:Be.deleteBookmark)(a))))),n=P3(e.pipe($e(Be.deleteBookmark.failure.match)),e.pipe($e(Be.removeBookmarkAsFavourite.failure.match))).pipe(me(a=>Be.removeBookmark.failure(a.payload,a.meta))),i=P3(e.pipe($e(Be.deleteBookmark.success.match)),e.pipe($e(Be.removeBookmarkAsFavourite.success.match))).pipe(me(a=>Be.removeBookmark.success({type:Ag(a.type),bookmarkId:a.payload},a.meta)));return xl(t,P3(n,i))},JK=r=>(e,t)=>It(BK,UK,qK,WK,GK,KK,XK,YK,QK).pipe(Jn(n=>n(r)(e,t))),eY=r=>{const e=new Lm(zK(r.initial));return e.addFlow(JK(r.client)),e},_E=r=>Object.values(r.bookmarks),Z0=(r,e)=>r.bookmarks[e],h_=r=>r.currentBookmark,tY=r=>Object.values(r.errors),kM="2.1.3";var _d=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})},vt=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},f_=function(r,e,t,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?r!==e||!i:!e.has(r))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(r,t):i?i.value=t:e.set(r,t),t},rY=function(r,e){var t={};for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&e.indexOf(n)<0&&(t[n]=r[n]);if(r!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,n=Object.getOwnPropertySymbols(r);i<n.length;i++)e.indexOf(n[i])<0&&Object.prototype.propertyIsEnumerable.call(r,n[i])&&(t[n[i]]=r[n[i]]);return t},Oi,rr,bd,wd;const xd=2*60*1e3;let nY=class{get config(){return{getCurrentAppIdentification(){return window.Fusion.modules.app.current.appKey}}}addStateCreator(e){console.warn("addStateCreator is deprecated, use addPayloadGenerator instead"),this.addPayloadGenerator(e)}deleteBookmarkByIdAsync(e){return console.warn("deleteBookmarkByIdAsync is deprecated, use deleteBookmarkAsync instead"),this.deleteBookmarkAsync(e)}addBookmarkFavoriteAsync(e){return console.warn("addBookmarkFavoriteAsync is deprecated, use addBookmarkToFavoritesAsync instead"),this.addBookmarkToFavoritesAsync(e)}removeBookmarkFavoriteAsync(e){return console.warn("removeBookmarkFavoriteAsync is deprecated, use removeBookmarkAsFavoriteAsync instead"),this.removeBookmarkAsFavoriteAsync(e)}getBookmarkById(e){return console.warn("getBookmarkById is deprecated, use getBookmarkAsync instead"),this.getBookmarkAsync(e)}get version(){return new fs(kM)}get filters(){return vt(this,Oi,"f").filters}get client(){return vt(this,Oi,"f").client}get currentBookmark$(){return vt(this,rr,"f").select(h_,u_)}get bookmarks$(){return this.getAllBookmarksAsync(),vt(this,rr,"f").select(_E,u_)}get bookmarks(){return _E(vt(this,rr,"f").value)}get currentBookmark(){return h_(vt(this,rr,"f").value)}get status$(){return vt(this,rr,"f").select(e=>e.status)}get errors$(){return vt(this,rr,"f").select(tY,u_)}get canCreateBookmarks(){return vt(this,bd,"f").length>0}get sourceSystem(){return vt(this,Oi,"f").sourceSystem}get resolvedApplication(){return vt(this,Oi,"f").resolve.application}get resolvedContext(){return vt(this,Oi,"f").resolve.context}get _apiClient(){return vt(this,Oi,"f").client}get _log(){return vt(this,Oi,"f").log}get _resolve(){return vt(this,Oi,"f").resolve}get _event(){return vt(this,Oi,"f").eventProvider}get _parent(){return vt(this,Oi,"f").parent}constructor(e){var t,n,i;if(Oi.set(this,void 0),rr.set(this,void 0),bd.set(this,[]),wd.set(this,new ti),f_(this,Oi,e,"f"),f_(this,rr,eY({client:e.client,initial:{currentBookmark:(n=(t=this._parent)===null||t===void 0?void 0:t.currentBookmark)!==null&&n!==void 0?n:null}}),"f"),vt(this,wd,"f").add(()=>vt(this,rr,"f").complete()),vt(this,wd,"f").add(vt(this,rr,"f").action$.subscribe(o=>{var a,c;q6(o)?(a=this._log)===null||a===void 0||a.error(`Action: ${o.type}`,o):(c=this._log)===null||c===void 0||c.debug(`Action: ${o.type}`,o)})),vt(this,wd,"f").add(vt(this,rr,"f").select(h_).subscribe(o=>{o!==void 0&&this._dispatchEvent("onCurrentBookmarkChanged",{detail:o})})),this._event&&this._event.addEventListener("onCurrentBookmarkChanged",o=>{const{source:a,detail:c}=o;c!==void 0&&a!==this&&c!==this.currentBookmark&&vt(this,rr,"f").next(Be.setCurrentBookmark(c))}),this._parent)try{vt(this,wd,"f").add(this._parent.currentBookmark$.pipe($e(o=>o!==void 0),$e(o=>o!==this.currentBookmark)).subscribe(o=>{vt(this,rr,"f").next(Be.setCurrentBookmark(o))}))}catch(o){(i=this._log)===null||i===void 0||i.error("Failed to subscribe to parent bookmark provider",o)}}on(e,t){var n,i;return this._event?(i=this._event)===null||i===void 0?void 0:i.addEventListener(e,o=>{o.source===this&&t(o)}):((n=this._log)===null||n===void 0||n.warn("Failed to register event listener, event provider not configured"),()=>{})}addPayloadGenerator(e){var t;return(t=this._log)===null||t===void 0||t.debug(`adding bookmark payload generator: ${e.name}`),vt(this,bd,"f").push(e),this._dispatchEvent("onBookmarkPayloadCreatorAdded",{detail:e}),()=>{var n;(n=this._log)===null||n===void 0||n.debug(`removing bookmark payload generator: ${e.name}`),f_(this,bd,vt(this,bd,"f").filter(i=>i!==e),"f")}}generatePayload(e){var t;return(t=this._log)===null||t===void 0||t.debug("generating payload",e),rt(vt(this,bd,"f")).pipe(PR((i,o)=>this._producePayload(i,o),e??{},1),Br(i=>{var o;return(o=this._log)===null||o===void 0?void 0:o.debug("generated payload",{initial:e,payload:i})}))}_producePayload(e,t,n){return B6(e,i=>_d(this,void 0,void 0,function*(){var o,a,c;try{const d=yield Promise.resolve(t(i,n));if(d)return(o=this._log)===null||o===void 0||o.warn(`bookmark data generator ${t.name} returned a value, but it should not do this, since the data is an immer draft object`),JSON.parse(JSON.stringify(d));if(d===null){(a=this._log)===null||a===void 0||a.info(`bookmark data generator ${t.name} wish to clear the bookmark data`);return}}catch(d){(c=this._log)===null||c===void 0||c.error(`Failed to produce payload using generator ${t.name}`,d)}}))}getBookmark(e,t){var n;return(n=this._log)===null||n===void 0||n.debug(`fetching bookmark: ${e}`,t),pv({bookmark:this._getBookmarkInfo(e),payload:t!=null&&t.excludePayload?It({}):this._getBookmarkData(e)}).pipe(Vt(i=>{var o;throw(o=this._log)===null||o===void 0||o.error(`Failed to fetch bookmark: ${e}`,i),i}),me(({bookmark:i,payload:o})=>Object.assign({},i,{payload:o})),Br(i=>{var o;(o=this._log)===null||o===void 0||o.debug(`Bookmark fetched: ${i.id}`,i)}))}getBookmarkAsync(e,t){return lr(this.getBookmark(e,t))}getAllBookmarks(){return new Tt(e=>{var t,n,i;(t=this._log)===null||t===void 0||t.debug("fetching all bookmarks");const o=pv({sourceSystem:It(this.sourceSystem),appKey:!((n=vt(this,Oi,"f").filters)===null||n===void 0)&&n.application?rt(this._resolve.application()).pipe(me(d=>d==null?void 0:d.appKey)):It(void 0),contextId:!((i=vt(this,Oi,"f").filters)===null||i===void 0)&&i.context?rt(this._resolve.context()).pipe(me(d=>d==null?void 0:d.id)):It(void 0)}).pipe(Vt(d=>{var h;const u=new kr("Could not fetch bookmarks, failed to resolve filter parameters",d);throw(h=this._log)===null||h===void 0||h.error(u.message,u),u}));e.add(o.subscribe(d=>{vt(this,rr,"f").next(Be.fetchBookmarks(d))}));const a=vt(this,rr,"f").action$.pipe($e(Be.fetchBookmarks.failure.match),me(d=>{var h;throw(h=this._log)===null||h===void 0||h.error("Failed to fetch bookmarks",d.payload),new kr("Failed to fetch bookmarks",d.payload)}),Gs({each:xd,with:()=>{throw new kr("Timeout while fetching bookmarks")}}));vt(this,rr,"f").action$.pipe($e(Be.fetchBookmarks.success.match),me(d=>d.payload),Br(d=>{var h;(h=this._log)===null||h===void 0||h.debug("fetched all bookmarks",d)}),Kc(a),Ks()).subscribe(e)})}getAllBookmarksAsync(){return _d(this,void 0,void 0,function*(){return lr(this.getAllBookmarks())})}setCurrentBookmark(e){var t;return e==this.currentBookmark?It(e):((t=this._log)===null||t===void 0||t.debug("setting current bookmark",e),(typeof e=="string"?this.getBookmark(e):It(e??null)).pipe(Wt(i=>_d(this,void 0,void 0,function*(){var o,a,c;const d=this.currentBookmark,{type:h,canceled:u}=yield this._dispatchEvent("onCurrentBookmarkChange",{detail:{current:d,next:i}});if(u){const p=new kr(`event: ${h} was canceled by listener for change to ${(o=i==null?void 0:i.id)!==null&&o!==void 0?o:"none"}, from ${(a=d==null?void 0:d.id)!==null&&a!==void 0?a:"none"}`);throw(c=this._log)===null||c===void 0||c.info(p.message),p}return i})),Br(i=>{vt(this,rr,"f").next(Be.setCurrentBookmark(i))}),Vt(i=>{var o;const a=new kr("Could not set current bookmark, resolve of bookmark failed",i);throw(o=this._log)===null||o===void 0||o.error(a.message,a),a})))}setCurrentBookmarkAsync(e){return lr(this.setCurrentBookmark(e))}createBookmark(e){return new Tt(t=>{var n;const{ref:i,action$:o}=this._useScopedActions();(n=this._log)===null||n===void 0||n.debug(`creating new bookmark, ref: ${i}`,e);const c=pv({appKey:e.appKey?It(e.appKey):rt(this._resolve.application()).pipe(me(u=>{if(!(u!=null&&u.appKey))throw new kr("Failed to resolve application key");return u.appKey})),contextId:this._resolve.context().then(u=>u==null?void 0:u.id),payload:this.generatePayload(e.payload),sourceSystem:It(this.sourceSystem)}).pipe(Vt(u=>{var p;const v=new kr("Could not create new bookmark, failed to resolve bookmark data",u);throw(p=this._log)===null||p===void 0||p.error(v.message,v),v}),me(u=>Object.assign(Object.assign({},e),u))).pipe(Wt(u=>_d(this,void 0,void 0,function*(){var p;const{canceled:v,type:g}=yield this._dispatchEvent("onBookmarkCreate",{detail:u,cancelable:!0});if(v){const _=new kr(`event: ${g} was canceled by listener for creating bookmark: ${i}`);throw(p=this._log)===null||p===void 0||p.info(_.message),_}return u})));t.add(c.subscribe({error:u=>t.error(u),next:u=>{vt(this,rr,"f").next(Be.createBookmark(u,{ref:i}))}}));const d=o.pipe($e(Be.createBookmark.failure.match),me(({payload:u})=>{var p;const v=new kr(`Failed to create bookmark: ${i}`,{cause:u});throw(p=this._log)===null||p===void 0||p.warn(v.message),v}),Gs({each:xd,with:()=>{throw new kr(`Timeout while creating bookmark: ${i}`)}}));o.pipe($e(Be.createBookmark.success.match),me(({payload:u})=>u),Br(u=>{var p;(p=this._log)===null||p===void 0||p.info(`Bookmark created: ${u.id}, ref: ${i}`),this._dispatchEvent("onBookmarkCreated",{detail:u})}),Kc(d),Ks()).subscribe(t)})}createBookmarkAsync(e){return lr(this.createBookmark(e))}updateBookmark(e,t,n){if(!t&&(n!=null&&n.excludePayloadGeneration))throw new kr("Cannot update bookmark without updates and excludePayloadGeneration option");return new Tt(i=>{var o;const{ref:a,action$:c}=this._useScopedActions();(o=this._log)===null||o===void 0||o.debug(`Updating bookmark: ${e}, ref: ${a}`);const h=(n!=null&&n.excludePayloadGeneration?It(t):this.generatePayload(t==null?void 0:t.payload).pipe(me(v=>Object.assign(Object.assign({},t),{payload:v})))).pipe(Wt(v=>_d(this,void 0,void 0,function*(){var g;const{canceled:_,type:b}=yield this._dispatchEvent("onBookmarkUpdate",{detail:{current:Z0(vt(this,rr,"f").value,e),updates:v},cancelable:!0});if(_){const C=new kr(`event: ${b} was canceled by listener for updating bookmark: ${e}, ref: ${a}`);throw(g=this._log)===null||g===void 0||g.warn(C.message,v),C}return v})));i.add(h.subscribe({error:v=>i.error(v),next:v=>{vt(this,rr,"f").next(Be.updateBookmark({bookmarkId:e,updates:v},{ref:a}))}}));const u=c.pipe($e(Be.updateBookmark.failure.match),me(({payload:v})=>{var g;const _=new kr(`Failed to update bookmark: ${e}`,{cause:v});throw(g=this._log)===null||g===void 0||g.info(_.message),_}),Gs({each:xd,with:()=>{throw new kr(`Timeout while updating bookmark: ${e}`)}}));c.pipe($e(Be.updateBookmark.success.match),me(({payload:v})=>Object.assign(Object.assign({},Z0(vt(this,rr,"f").value,v.id)),{payload:v.payload})),Br(v=>{var g;(g=this._log)===null||g===void 0||g.info(`Bookmark updated: ${v.id}, ref: ${a}`),this._dispatchEvent("onBookmarkUpdated",{detail:v})}),Kc(u),Ks()).subscribe(i)})}updateBookmarkAsync(e,t,n){if(typeof e=="object"){console.warn("updateBookmarkAsync(bookmark, updates, options) is deprecated, use updateBookmarkAsync(id, updates, options) instead");const i=e,{id:o}=i,a=rY(i,["id"]);return lr(this.updateBookmark(o,a,{excludePayloadGeneration:!t.updatePayload}).pipe(me(c=>c.payload)))}return lr(this.updateBookmark(e,t,n))}deleteBookmark(e){return new Tt(t=>{var n,i;const{ref:o,action$:a}=this._useScopedActions();(n=this._log)===null||n===void 0||n.debug(`Removing bookmark: ${e}, ref: ${o}`);const c=(i=Z0(vt(this,rr,"f").value,e))!==null&&i!==void 0?i:{id:e},d=rt(this._dispatchEvent("onBookmarkDelete",{detail:c,cancelable:!0})).pipe(me(({canceled:p,type:v,detail:g})=>{var _;if(p){const b=new kr(`event: ${v} was canceled by listener for removing bookmark: ${e}, ref: ${o}`);throw(_=this._log)===null||_===void 0||_.warn(b.message),b}return g}));t.add(d.subscribe({error:p=>t.error(p),next:p=>{vt(this,rr,"f").next(Be.deleteBookmark(p.id,{ref:o}))}}));const h=a.pipe($e(Be.deleteBookmark.failure.match),me(({payload:p})=>{var v;const g=new kr(`Failed to update bookmark: ${e}`,{cause:p});throw(v=this._log)===null||v===void 0||v.warn(g.message),g}),Gs({each:xd,with:()=>{throw new kr(`Timeout while updating bookmark: ${e}`)}}));a.pipe($e(Be.deleteBookmark.success.match),me(()=>{}),Br(()=>{var p;(p=this._log)===null||p===void 0||p.info(`Removed bookmark: ${c.id}, ref: ${o}`),this._dispatchEvent("onBookmarkDeleted",{detail:c})}),Kc(h),Ks()).subscribe(t)})}deleteBookmarkAsync(e){return _d(this,void 0,void 0,function*(){return lr(this.deleteBookmark(e))})}addBookmarkToFavorites(e){return new Tt(n=>{var i;const{ref:o,action$:a}=this._useScopedActions();(i=this._log)===null||i===void 0||i.debug(`Adding bookmark: ${e} to favourites, ref: ${o}`);const c=rt(this._dispatchEvent("onBookmarkFavouriteAdd",{detail:{id:e},cancelable:!0})).pipe(me(({canceled:u,type:p})=>{var v;if(u){const g=new kr(`event: ${p} was canceled by listener for adding favourite bookmark: ${e}, ref: ${o}`);throw(v=this._log)===null||v===void 0||v.info(g.message),g}}));n.add(c.subscribe({error:u=>n.error(u),next:()=>{vt(this,rr,"f").next(Be.addBookmarkAsFavourite(e,{ref:o}))}}));const d=a.pipe($e(Be.addBookmarkAsFavourite.failure.match),me(({payload:u})=>{var p;const v=new kr(`Failed to add bookmark to favorites: ${e}`,{cause:u});throw(p=this._log)===null||p===void 0||p.warn(v.message),v}),Gs({each:xd,with:()=>{throw new kr(`Timeout while adding bookmark to favorites: ${e}`)}}));return a.pipe($e(Be.addBookmarkAsFavourite.success.match),Wt(({payload:u})=>this.getBookmark(u,{excludePayload:!0})),Br(u=>{var p;(p=this._log)===null||p===void 0||p.info(`Added bookmark: ${e} to favourites, ref: ${o}`),this._dispatchEvent("onBookmarkFavouriteAdded",{detail:u})}),Kc(d),Ks()).subscribe(n)})}addBookmarkToFavoritesAsync(e){return lr(this.addBookmarkToFavorites(e))}removeBookmarkAsFavorite(e){return new Tt(n=>{var i,o;const{ref:a,action$:c}=this._useScopedActions();(i=this._log)===null||i===void 0||i.debug(`Removing bookmark: ${e} from favourites, ref: ${a}`);const d=(o=Z0(vt(this,rr,"f").value,e))!==null&&o!==void 0?o:{id:e},h=rt(this._dispatchEvent("onBookmarkFavouriteRemove",{detail:d,cancelable:!0})).pipe(me(({canceled:v,type:g,detail:_})=>{var b;if(v){const C=new kr(`event: ${g} was canceled by listener for removing favourite bookmark: ${e}, ref: ${a}`);throw(b=this._log)===null||b===void 0||b.warn(C.message),C}return _}));n.add(h.subscribe({error:v=>n.error(v),next:v=>{vt(this,rr,"f").next(Be.removeBookmarkAsFavourite(v.id,{ref:a}))}}));const u=c.pipe($e(Be.removeBookmarkAsFavourite.failure.match),me(({payload:v})=>{var g;const _=new kr(`Failed to remove bookmark: ${e} from favourites`,{cause:v});throw(g=this._log)===null||g===void 0||g.warn(_.message),_}),Gs({each:xd,with:()=>{throw new kr(`Timeout while removing bookmark: ${e} from favourites`)}}));c.pipe($e(Be.removeBookmarkAsFavourite.success.match),Br(()=>{var v;(v=this._log)===null||v===void 0||v.info(`Removed bookmark: ${e} from favourites, ref: ${a}`),this._dispatchEvent("onBookmarkFavouriteRemoved",{detail:d})}),me(()=>{}),Kc(u),Ks()).subscribe(n)})}removeBookmarkAsFavoriteAsync(e){return lr(this.removeBookmarkAsFavorite(e))}isBookmarkInFavorites(e){var t;return(t=this._log)===null||t===void 0||t.debug(`Checking if bookmark: ${e} is in favourites`),rt(this._apiClient.isBookmarkFavorite(e)).pipe(Vt(n=>{var i;const o=new kr(`Failed to check if bookmark: ${e} is in favourites`,n);throw(i=this._log)===null||i===void 0||i.error(o.message,o),o}),Br(n=>{var i;(i=this._log)===null||i===void 0||i.debug(`Bookmark: ${e} is ${n?"in":"not in"} favourites`)}))}isBookmarkInFavoritesAsync(e){return lr(this.isBookmarkInFavorites(e))}_getBookmarkInfo(e,t){var n;const{action$:i}=this._useScopedActions(e),o=i.pipe($e(Be.fetchBookmark.success.match),me(c=>c.payload),Ks()),a=vt(this,rr,"f").action$.pipe($e(Be.fetchBookmark.failure.match),me(c=>{throw new kr(`Failed to fetch bookmark data: ${e}`,c.payload)}),Gs({each:(n=t==null?void 0:t.timeout)!==null&&n!==void 0?n:2*60*1e3,with:()=>{throw new kr(`Timeout while fetching bookmark data: ${e}`)}}));return vt(this,rr,"f").next(Be.fetchBookmark(e,{ref:e})),o.pipe(Kc(a))}_getBookmarkData(e,t){var n;const{action$:i}=this._useScopedActions(e),o=i.pipe($e(Be.fetchBookmarkData.success.match),me(c=>c.payload.data),Ks()),a=vt(this,rr,"f").action$.pipe($e(Be.fetchBookmarkData.failure.match),me(c=>{throw new kr(`Failed to fetch bookmark data: ${e}`,c.payload)}),Gs({each:(n=t==null?void 0:t.timeout)!==null&&n!==void 0?n:xd,with:()=>{throw new kr(`Timeout while fetching bookmark data: ${e}`)}}));return vt(this,rr,"f").next(Be.fetchBookmarkData(e,{ref:e})),o.pipe(Kc(a))}_dispatchEvent(e,t){return _d(this,void 0,void 0,function*(){var n,i;const o=new ZR(e,Object.assign({source:this,canBubble:!0},t));if(this._event){(n=this._log)===null||n===void 0||n.debug(`dispatching event ${e}`,t);const{canceled:a}=yield this._event.dispatchEvent(o);a&&((i=this._log)===null||i===void 0||i.debug(`event ${e} was canceled`,t))}return o})}_useScopedActions(e){e??(e=sm());const t=vt(this,rr,"f").action$.pipe($e(n=>{var i;return"meta"in n&&((i=n.meta)===null||i===void 0?void 0:i.ref)===e}));return{ref:e,action$:t}}dispose(){var e;(e=this._log)===null||e===void 0||e.debug("disposing BookmarkProvider"),vt(this,wd,"f").unsubscribe()}[(Oi=new WeakMap,rr=new WeakMap,bd=new WeakMap,wd=new WeakMap,Symbol.dispose)](){this.dispose()}};var iY=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};const oY="bookmark",aY=new Dm("BookmarkModule"),sY={name:oY,version:new fs(kM),configure:r=>{var e;const t=((e=r==null?void 0:r.log)===null||e===void 0?void 0:e.createSubLogger("BookmarkModule"))||aY,n=r==null?void 0:r.ref;return new NK({log:t,ref:n})},initialize:r=>iY(void 0,void 0,void 0,function*(){var e;const t=(e=r.ref)===null||e===void 0?void 0:e.bookmark,n=yield lr(r.config.createConfig(r,{filters:t==null?void 0:t.filters,sourceSystem:t==null?void 0:t.sourceSystem,resolve:t?{application:t.resolvedApplication.bind(t),context:t.resolvedContext.bind(t)}:void 0}));return new nY(n)}),dispose:r=>{r.instance.dispose()}};var cY=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};const lY=(r,e)=>{r.addConfig({module:sY,configure:t=>cY(void 0,void 0,void 0,function*(){e&&Promise.resolve(e(t))})})};class dY{}/**
410
410
  * @remix-run/router v1.22.0
411
411
  *
412
412
  * Copyright (c) Remix Software Inc.
@@ -416,7 +416,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
416
416
  *
417
417
  * @license MIT
418
418
  */function Ur(){return Ur=Object.assign?Object.assign.bind():function(r){for(var e=1;e<arguments.length;e++){var t=arguments[e];for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(r[n]=t[n])}return r},Ur.apply(this,arguments)}var rn;(function(r){r.Pop="POP",r.Push="PUSH",r.Replace="REPLACE"})(rn||(rn={}));const bE="popstate";function uY(r){r===void 0&&(r={});let{initialEntries:e=["/"],initialIndex:t,v5Compat:n=!1}=r,i;i=e.map((g,_)=>u(g,typeof g=="string"?null:g.state,_===0?"default":void 0));let o=d(t??i.length-1),a=rn.Pop,c=null;function d(g){return Math.min(Math.max(g,0),i.length-1)}function h(){return i[o]}function u(g,_,b){_===void 0&&(_=null);let C=Eu(i?h().pathname:"/",g,_,b);return $l(C.pathname.charAt(0)==="/","relative pathnames are not supported in memory history: "+JSON.stringify(g)),C}function p(g){return typeof g=="string"?g:Nu(g)}return{get index(){return o},get action(){return a},get location(){return h()},createHref:p,createURL(g){return new URL(p(g),"http://localhost")},encodeLocation(g){let _=typeof g=="string"?Cc(g):g;return{pathname:_.pathname||"",search:_.search||"",hash:_.hash||""}},push(g,_){a=rn.Push;let b=u(g,_);o+=1,i.splice(o,i.length,b),n&&c&&c({action:a,location:b,delta:1})},replace(g,_){a=rn.Replace;let b=u(g,_);i[o]=b,n&&c&&c({action:a,location:b,delta:0})},go(g){a=rn.Pop;let _=d(o+g),b=i[_];o=_,c&&c({action:a,location:b,delta:g})},listen(g){return c=g,()=>{c=null}}}}function hY(r){r===void 0&&(r={});function e(n,i){let{pathname:o,search:a,hash:c}=n.location;return Eu("",{pathname:o,search:a,hash:c},i.state&&i.state.usr||null,i.state&&i.state.key||"default")}function t(n,i){return typeof i=="string"?i:Nu(i)}return EM(e,t,null,r)}function fY(r){r===void 0&&(r={});function e(i,o){let{pathname:a="/",search:c="",hash:d=""}=Cc(i.location.hash.substr(1));return!a.startsWith("/")&&!a.startsWith(".")&&(a="/"+a),Eu("",{pathname:a,search:c,hash:d},o.state&&o.state.usr||null,o.state&&o.state.key||"default")}function t(i,o){let a=i.document.querySelector("base"),c="";if(a&&a.getAttribute("href")){let d=i.location.href,h=d.indexOf("#");c=h===-1?d:d.slice(0,h)}return c+"#"+(typeof o=="string"?o:Nu(o))}function n(i,o){$l(i.pathname.charAt(0)==="/","relative pathnames are not supported in hash history.push("+JSON.stringify(o)+")")}return EM(e,t,n,r)}function Pr(r,e){if(r===!1||r===null||typeof r>"u")throw new Error(e)}function $l(r,e){if(!r){typeof console<"u"&&console.warn(e);try{throw new Error(e)}catch{}}}function pY(){return Math.random().toString(36).substr(2,8)}function wE(r,e){return{usr:r.state,key:r.key,idx:e}}function Eu(r,e,t,n){return t===void 0&&(t=null),Ur({pathname:typeof r=="string"?r:r.pathname,search:"",hash:""},typeof e=="string"?Cc(e):e,{state:t,key:e&&e.key||n||pY()})}function Nu(r){let{pathname:e="/",search:t="",hash:n=""}=r;return t&&t!=="?"&&(e+=t.charAt(0)==="?"?t:"?"+t),n&&n!=="#"&&(e+=n.charAt(0)==="#"?n:"#"+n),e}function Cc(r){let e={};if(r){let t=r.indexOf("#");t>=0&&(e.hash=r.substr(t),r=r.substr(0,t));let n=r.indexOf("?");n>=0&&(e.search=r.substr(n),r=r.substr(0,n)),r&&(e.pathname=r)}return e}function EM(r,e,t,n){n===void 0&&(n={});let{window:i=document.defaultView,v5Compat:o=!1}=n,a=i.history,c=rn.Pop,d=null,h=u();h==null&&(h=0,a.replaceState(Ur({},a.state,{idx:h}),""));function u(){return(a.state||{idx:null}).idx}function p(){c=rn.Pop;let C=u(),T=C==null?null:C-h;h=C,d&&d({action:c,location:b.location,delta:T})}function v(C,T){c=rn.Push;let S=Eu(b.location,C,T);t&&t(S,C),h=u()+1;let A=wE(S,h),Z=b.createHref(S);try{a.pushState(A,"",Z)}catch(B){if(B instanceof DOMException&&B.name==="DataCloneError")throw B;i.location.assign(Z)}o&&d&&d({action:c,location:b.location,delta:1})}function g(C,T){c=rn.Replace;let S=Eu(b.location,C,T);t&&t(S,C),h=u();let A=wE(S,h),Z=b.createHref(S);a.replaceState(A,"",Z),o&&d&&d({action:c,location:b.location,delta:0})}function _(C){let T=i.location.origin!=="null"?i.location.origin:i.location.href,S=typeof C=="string"?C:Nu(C);return S=S.replace(/ $/,"%20"),Pr(T,"No window.location.(origin|href) available to create URL for href: "+S),new URL(S,T)}let b={get action(){return c},get location(){return r(i,a)},listen(C){if(d)throw new Error("A history only accepts one active listener");return i.addEventListener(bE,p),d=C,()=>{i.removeEventListener(bE,p),d=null}},createHref(C){return e(i,C)},createURL:_,encodeLocation(C){let T=_(C);return{pathname:T.pathname,search:T.search,hash:T.hash}},push:v,replace:g,go(C){return a.go(C)}};return b}var _r;(function(r){r.data="data",r.deferred="deferred",r.redirect="redirect",r.error="error"})(_r||(_r={}));const mY=new Set(["lazy","caseSensitive","path","id","index","children"]);function vY(r){return r.index===!0}function Og(r,e,t,n){return t===void 0&&(t=[]),n===void 0&&(n={}),r.map((i,o)=>{let a=[...t,String(o)],c=typeof i.id=="string"?i.id:a.join("-");if(Pr(i.index!==!0||!i.children,"Cannot specify children on an index route"),Pr(!n[c],'Found a route id collision on id "'+c+`". Route id's must be globally unique within Data Router usages`),vY(i)){let d=Ur({},i,e(i),{id:c});return n[c]=d,d}else{let d=Ur({},i,e(i),{id:c,children:void 0});return n[c]=d,i.children&&(d.children=Og(i.children,e,a,n)),d}})}function Vh(r,e,t){return t===void 0&&(t="/"),Mv(r,e,t,!1)}function Mv(r,e,t,n){let i=typeof e=="string"?Cc(e):e,o=C4(i.pathname||"/",t);if(o==null)return null;let a=SM(r);yY(a);let c=null;for(let d=0;c==null&&d<a.length;++d){let h=IY(o);c=TY(a[d],h,n)}return c}function gY(r,e){let{route:t,pathname:n,params:i}=r;return{id:t.id,pathname:n,params:i,data:e[t.id],handle:t.handle}}function SM(r,e,t,n){e===void 0&&(e=[]),t===void 0&&(t=[]),n===void 0&&(n="");let i=(o,a,c)=>{let d={relativePath:c===void 0?o.path||"":c,caseSensitive:o.caseSensitive===!0,childrenIndex:a,route:o};d.relativePath.startsWith("/")&&(Pr(d.relativePath.startsWith(n),'Absolute route path "'+d.relativePath+'" nested under path '+('"'+n+'" is not valid. An absolute child route path ')+"must start with the combined path of all its parent routes."),d.relativePath=d.relativePath.slice(n.length));let h=Vp([n,d.relativePath]),u=t.concat(d);o.children&&o.children.length>0&&(Pr(o.index!==!0,"Index routes must not have child routes. Please remove "+('all child routes from route path "'+h+'".')),SM(o.children,e,u,h)),!(o.path==null&&!o.index)&&e.push({path:h,score:EY(h,o.index),routesMeta:u})};return r.forEach((o,a)=>{var c;if(o.path===""||!((c=o.path)!=null&&c.includes("?")))i(o,a);else for(let d of TM(o.path))i(o,a,d)}),e}function TM(r){let e=r.split("/");if(e.length===0)return[];let[t,...n]=e,i=t.endsWith("?"),o=t.replace(/\?$/,"");if(n.length===0)return i?[o,""]:[o];let a=TM(n.join("/")),c=[];return c.push(...a.map(d=>d===""?o:[o,d].join("/"))),i&&c.push(...a),c.map(d=>r.startsWith("/")&&d===""?"/":d)}function yY(r){r.sort((e,t)=>e.score!==t.score?t.score-e.score:SY(e.routesMeta.map(n=>n.childrenIndex),t.routesMeta.map(n=>n.childrenIndex)))}const _Y=/^:[\w-]+$/,bY=3,wY=2,xY=1,CY=10,kY=-2,xE=r=>r==="*";function EY(r,e){let t=r.split("/"),n=t.length;return t.some(xE)&&(n+=kY),e&&(n+=wY),t.filter(i=>!xE(i)).reduce((i,o)=>i+(_Y.test(o)?bY:o===""?xY:CY),n)}function SY(r,e){return r.length===e.length&&r.slice(0,-1).every((n,i)=>n===e[i])?r[r.length-1]-e[e.length-1]:0}function TY(r,e,t){t===void 0&&(t=!1);let{routesMeta:n}=r,i={},o="/",a=[];for(let c=0;c<n.length;++c){let d=n[c],h=c===n.length-1,u=o==="/"?e:e.slice(o.length)||"/",p=CE({path:d.relativePath,caseSensitive:d.caseSensitive,end:h},u),v=d.route;if(!p&&h&&t&&!n[n.length-1].route.index&&(p=CE({path:d.relativePath,caseSensitive:d.caseSensitive,end:!1},u)),!p)return null;Object.assign(i,p.params),a.push({params:i,pathname:Vp([o,p.pathname]),pathnameBase:OY(Vp([o,p.pathnameBase])),route:v}),p.pathnameBase!=="/"&&(o=Vp([o,p.pathnameBase]))}return a}function CE(r,e){typeof r=="string"&&(r={path:r,caseSensitive:!1,end:!0});let[t,n]=AY(r.path,r.caseSensitive,r.end),i=e.match(t);if(!i)return null;let o=i[0],a=o.replace(/(.)\/+$/,"$1"),c=i.slice(1);return{params:n.reduce((h,u,p)=>{let{paramName:v,isOptional:g}=u;if(v==="*"){let b=c[p]||"";a=o.slice(0,o.length-b.length).replace(/(.)\/+$/,"$1")}const _=c[p];return g&&!_?h[v]=void 0:h[v]=(_||"").replace(/%2F/g,"/"),h},{}),pathname:o,pathnameBase:a,pattern:r}}function AY(r,e,t){e===void 0&&(e=!1),t===void 0&&(t=!0),$l(r==="*"||!r.endsWith("*")||r.endsWith("/*"),'Route path "'+r+'" will be treated as if it were '+('"'+r.replace(/\*$/,"/*")+'" because the `*` character must ')+"always follow a `/` in the pattern. To get rid of this warning, "+('please change the route path to "'+r.replace(/\*$/,"/*")+'".'));let n=[],i="^"+r.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(a,c,d)=>(n.push({paramName:c,isOptional:d!=null}),d?"/?([^\\/]+)?":"/([^\\/]+)"));return r.endsWith("*")?(n.push({paramName:"*"}),i+=r==="*"||r==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):t?i+="\\/*$":r!==""&&r!=="/"&&(i+="(?:(?=\\/|$))"),[new RegExp(i,e?void 0:"i"),n]}function IY(r){try{return r.split("/").map(e=>decodeURIComponent(e).replace(/\//g,"%2F")).join("/")}catch(e){return $l(!1,'The URL path "'+r+'" could not be decoded because it is is a malformed URL segment. This is probably due to a bad percent '+("encoding ("+e+").")),r}}function C4(r,e){if(e==="/")return r;if(!r.toLowerCase().startsWith(e.toLowerCase()))return null;let t=e.endsWith("/")?e.length-1:e.length,n=r.charAt(t);return n&&n!=="/"?null:r.slice(t)||"/"}function RY(r,e){e===void 0&&(e="/");let{pathname:t,search:n="",hash:i=""}=typeof r=="string"?Cc(r):r;return{pathname:t?t.startsWith("/")?t:PY(t,e):e,search:ZY(n),hash:LY(i)}}function PY(r,e){let t=e.replace(/\/+$/,"").split("/");return r.split("/").forEach(i=>{i===".."?t.length>1&&t.pop():i!=="."&&t.push(i)}),t.length>1?t.join("/"):"/"}function p_(r,e,t,n){return"Cannot include a '"+r+"' character in a manually specified "+("`to."+e+"` field ["+JSON.stringify(n)+"]. Please separate it out to the ")+("`to."+t+"` field. Alternatively you may provide the full path as ")+'a string in <Link to="..."> and the router will parse it for you.'}function AM(r){return r.filter((e,t)=>t===0||e.route.path&&e.route.path.length>0)}function MY(r,e){let t=AM(r);return e?t.map((n,i)=>i===t.length-1?n.pathname:n.pathnameBase):t.map(n=>n.pathnameBase)}function $Y(r,e,t,n){n===void 0&&(n=!1);let i;typeof r=="string"?i=Cc(r):(i=Ur({},r),Pr(!i.pathname||!i.pathname.includes("?"),p_("?","pathname","search",i)),Pr(!i.pathname||!i.pathname.includes("#"),p_("#","pathname","hash",i)),Pr(!i.search||!i.search.includes("#"),p_("#","search","hash",i)));let o=r===""||i.pathname==="",a=o?"/":i.pathname,c;if(a==null)c=t;else{let p=e.length-1;if(!n&&a.startsWith("..")){let v=a.split("/");for(;v[0]==="..";)v.shift(),p-=1;i.pathname=v.join("/")}c=p>=0?e[p]:"/"}let d=RY(i,c),h=a&&a!=="/"&&a.endsWith("/"),u=(o||a===".")&&t.endsWith("/");return!d.pathname.endsWith("/")&&(h||u)&&(d.pathname+="/"),d}const Vp=r=>r.join("/").replace(/\/\/+/g,"/"),OY=r=>r.replace(/\/+$/,"").replace(/^\/*/,"/"),ZY=r=>!r||r==="?"?"":r.startsWith("?")?r:"?"+r,LY=r=>!r||r==="#"?"":r.startsWith("#")?r:"#"+r;class uw{constructor(e,t,n,i){i===void 0&&(i=!1),this.status=e,this.statusText=t||"",this.internal=i,n instanceof Error?(this.data=n.toString(),this.error=n):this.data=n}}function Zg(r){return r!=null&&typeof r.status=="number"&&typeof r.statusText=="string"&&typeof r.internal=="boolean"&&"data"in r}const IM=["post","put","patch","delete"],HY=new Set(IM),NY=["get",...IM],DY=new Set(NY),VY=new Set([301,302,303,307,308]),FY=new Set([307,308]),m_={state:"idle",location:void 0,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0},jY={state:"idle",data:void 0,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0},U1={state:"unblocked",proceed:void 0,reset:void 0,location:void 0},s8=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,zY=r=>({hasErrorBoundary:!!r.hasErrorBoundary}),RM="remix-router-transitions";function BY(r){const e=r.window?r.window:typeof window<"u"?window:void 0,t=typeof e<"u"&&typeof e.document<"u"&&typeof e.document.createElement<"u",n=!t;Pr(r.routes.length>0,"You must provide a non-empty routes array to createRouter");let i;if(r.mapRouteProperties)i=r.mapRouteProperties;else if(r.detectErrorBoundary){let D=r.detectErrorBoundary;i=Q=>({hasErrorBoundary:D(Q)})}else i=zY;let o={},a=Og(r.routes,i,void 0,o),c,d=r.basename||"/",h=r.dataStrategy||GY,u=r.patchRoutesOnNavigation,p=Ur({v7_fetcherPersist:!1,v7_normalizeFormMethod:!1,v7_partialHydration:!1,v7_prependBasename:!1,v7_relativeSplatPath:!1,v7_skipActionErrorRevalidation:!1},r.future),v=null,g=new Set,_=null,b=null,C=null,T=r.hydrationData!=null,S=Vh(a,r.history.location,d),A=!1,Z=null;if(S==null&&!u){let D=no(404,{pathname:r.history.location.pathname}),{matches:Q,route:ie}=OE(a);S=Q,Z={[ie.id]:D}}S&&!r.hydrationData&&Ms(S,a,r.history.location.pathname).active&&(S=null);let B;if(S)if(S.some(D=>D.route.lazy))B=!1;else if(!S.some(D=>D.route.loader))B=!0;else if(p.v7_partialHydration){let D=r.hydrationData?r.hydrationData.loaderData:null,Q=r.hydrationData?r.hydrationData.errors:null;if(Q){let ie=S.findIndex(he=>Q[he.route.id]!==void 0);B=S.slice(0,ie+1).every(he=>!fw(he.route,D,Q))}else B=S.every(ie=>!fw(ie.route,D,Q))}else B=r.hydrationData!=null;else if(B=!1,S=[],p.v7_partialHydration){let D=Ms(null,a,r.history.location.pathname);D.active&&D.matches&&(A=!0,S=D.matches)}let U,I={historyAction:r.history.action,location:r.history.location,matches:S,initialized:B,navigation:m_,restoreScrollPosition:r.hydrationData!=null?!1:null,preventScrollReset:!1,revalidation:"idle",loaderData:r.hydrationData&&r.hydrationData.loaderData||{},actionData:r.hydrationData&&r.hydrationData.actionData||null,errors:r.hydrationData&&r.hydrationData.errors||Z,fetchers:new Map,blockers:new Map},Y=rn.Pop,le=!1,de,Ee=!1,we=new Map,Ce=null,J=!1,K=!1,re=[],q=new Set,$=new Map,O=0,H=-1,P=new Map,N=new Set,ye=new Map,Pe=new Map,Ie=new Set,Te=new Map,Ke=new Map,ot;function _t(){if(v=r.history.listen(D=>{let{action:Q,location:ie,delta:he}=D;if(ot){ot(),ot=void 0;return}$l(Ke.size===0||he!=null,"You are trying to use a blocker on a POP navigation to a location that was not created by @remix-run/router. This will fail silently in production. This can happen if you are navigating outside the router via `window.history.pushState`/`window.location.hash` instead of using router navigation APIs. This can also happen if you are using createHashRouter and the user manually changes the URL.");let Oe=qa({currentLocation:I.location,nextLocation:ie,historyAction:Q});if(Oe&&he!=null){let Ve=new Promise(mt=>{ot=mt});r.history.go(he*-1),Zo(Oe,{state:"blocked",location:ie,proceed(){Zo(Oe,{state:"proceeding",proceed:void 0,reset:void 0,location:ie}),Ve.then(()=>r.history.go(he))},reset(){let mt=new Map(I.blockers);mt.set(Oe,U1),Rt({blockers:mt})}});return}return qi(Q,ie)}),t){cQ(e,we);let D=()=>lQ(e,we);e.addEventListener("pagehide",D),Ce=()=>e.removeEventListener("pagehide",D)}return I.initialized||qi(rn.Pop,I.location,{initialHydration:!0}),U}function yr(){v&&v(),Ce&&Ce(),g.clear(),de&&de.abort(),I.fetchers.forEach((D,Q)=>$o(Q)),I.blockers.forEach((D,Q)=>Oo(Q))}function Wr(D){return g.add(D),()=>g.delete(D)}function Rt(D,Q){Q===void 0&&(Q={}),I=Ur({},I,D);let ie=[],he=[];p.v7_fetcherPersist&&I.fetchers.forEach((Oe,Ve)=>{Oe.state==="idle"&&(Ie.has(Ve)?he.push(Ve):ie.push(Ve))}),Ie.forEach(Oe=>{!I.fetchers.has(Oe)&&!$.has(Oe)&&he.push(Oe)}),[...g].forEach(Oe=>Oe(I,{deletedFetchers:he,viewTransitionOpts:Q.viewTransitionOpts,flushSync:Q.flushSync===!0})),p.v7_fetcherPersist?(ie.forEach(Oe=>I.fetchers.delete(Oe)),he.forEach(Oe=>$o(Oe))):he.forEach(Oe=>Ie.delete(Oe))}function Un(D,Q,ie){var he,Oe;let{flushSync:Ve}=ie===void 0?{}:ie,mt=I.actionData!=null&&I.navigation.formMethod!=null&&Ia(I.navigation.formMethod)&&I.navigation.state==="loading"&&((he=D.state)==null?void 0:he._isRedirect)!==!0,Ge;Q.actionData?Object.keys(Q.actionData).length>0?Ge=Q.actionData:Ge=null:mt?Ge=I.actionData:Ge=null;let Ye=Q.loaderData?ME(I.loaderData,Q.loaderData,Q.matches||[],Q.errors):I.loaderData,je=I.blockers;je.size>0&&(je=new Map(je),je.forEach((Ht,mn)=>je.set(mn,U1)));let Je=le===!0||I.navigation.formMethod!=null&&Ia(I.navigation.formMethod)&&((Oe=D.state)==null?void 0:Oe._isRedirect)!==!0;c&&(a=c,c=void 0),J||Y===rn.Pop||(Y===rn.Push?r.history.push(D,D.state):Y===rn.Replace&&r.history.replace(D,D.state));let wt;if(Y===rn.Pop){let Ht=we.get(I.location.pathname);Ht&&Ht.has(D.pathname)?wt={currentLocation:I.location,nextLocation:D}:we.has(D.pathname)&&(wt={currentLocation:D,nextLocation:I.location})}else if(Ee){let Ht=we.get(I.location.pathname);Ht?Ht.add(D.pathname):(Ht=new Set([D.pathname]),we.set(I.location.pathname,Ht)),wt={currentLocation:I.location,nextLocation:D}}Rt(Ur({},Q,{actionData:Ge,loaderData:Ye,historyAction:Y,location:D,initialized:!0,navigation:m_,revalidation:"idle",restoreScrollPosition:ql(D,Q.matches||I.matches),preventScrollReset:Je,blockers:je}),{viewTransitionOpts:wt,flushSync:Ve===!0}),Y=rn.Pop,le=!1,Ee=!1,J=!1,K=!1,re=[]}async function co(D,Q){if(typeof D=="number"){r.history.go(D);return}let ie=hw(I.location,I.matches,d,p.v7_prependBasename,D,p.v7_relativeSplatPath,Q==null?void 0:Q.fromRouteId,Q==null?void 0:Q.relative),{path:he,submission:Oe,error:Ve}=kE(p.v7_normalizeFormMethod,!1,ie,Q),mt=I.location,Ge=Eu(I.location,he,Q&&Q.state);Ge=Ur({},Ge,r.history.encodeLocation(Ge));let Ye=Q&&Q.replace!=null?Q.replace:void 0,je=rn.Push;Ye===!0?je=rn.Replace:Ye===!1||Oe!=null&&Ia(Oe.formMethod)&&Oe.formAction===I.location.pathname+I.location.search&&(je=rn.Replace);let Je=Q&&"preventScrollReset"in Q?Q.preventScrollReset===!0:void 0,wt=(Q&&Q.flushSync)===!0,Ht=qa({currentLocation:mt,nextLocation:Ge,historyAction:je});if(Ht){Zo(Ht,{state:"blocked",location:Ge,proceed(){Zo(Ht,{state:"proceeding",proceed:void 0,reset:void 0,location:Ge}),co(D,Q)},reset(){let mn=new Map(I.blockers);mn.set(Ht,U1),Rt({blockers:mn})}});return}return await qi(je,Ge,{submission:Oe,pendingError:Ve,preventScrollReset:Je,replace:Q&&Q.replace,enableViewTransition:Q&&Q.viewTransition,flushSync:wt})}function ma(){if(Ba(),Rt({revalidation:"loading"}),I.navigation.state!=="submitting"){if(I.navigation.state==="idle"){qi(I.historyAction,I.location,{startUninterruptedRevalidation:!0});return}qi(Y||I.historyAction,I.navigation.location,{overrideNavigation:I.navigation,enableViewTransition:Ee===!0})}}async function qi(D,Q,ie){de&&de.abort(),de=null,Y=D,J=(ie&&ie.startUninterruptedRevalidation)===!0,Gu(I.location,I.matches),le=(ie&&ie.preventScrollReset)===!0,Ee=(ie&&ie.enableViewTransition)===!0;let he=c||a,Oe=ie&&ie.overrideNavigation,Ve=ie!=null&&ie.initialHydration&&I.matches&&I.matches.length>0&&!A?I.matches:Vh(he,Q,d),mt=(ie&&ie.flushSync)===!0,Ge=Ms(Ve,he,Q.pathname);if(Ge.active&&Ge.matches&&(Ve=Ge.matches),!Ve){let{error:ar,notFoundMatches:Ut,route:Er}=Wi(Q.pathname);Un(Q,{matches:Ut,loaderData:{},errors:{[Er.id]:ar}},{flushSync:mt});return}if(I.initialized&&!K&&eQ(I.location,Q)&&!(ie&&ie.submission&&Ia(ie.submission.formMethod))){Un(Q,{matches:Ve},{flushSync:mt});return}de=new AbortController;let Ye=Th(r.history,Q,de.signal,ie&&ie.submission),je;if(ie&&ie.pendingError)je=[Bd(Ve).route.id,{type:_r.error,error:ie.pendingError}];else if(ie&&ie.submission&&Ia(ie.submission.formMethod)){let ar=await Sc(Ye,Q,ie.submission,Ve,Ge.active,{replace:ie.replace,flushSync:mt});if(ar.shortCircuited)return;if(ar.pendingActionResult){let[Ut,Er]=ar.pendingActionResult;if(wo(Er)&&Zg(Er.error)&&Er.error.status===404){de=null,Un(Q,{matches:ar.matches,loaderData:{},errors:{[Ut]:Er.error}});return}}Ve=ar.matches||Ve,je=ar.pendingActionResult,Oe=v_(Q,ie.submission),mt=!1,Ge.active=!1,Ye=Th(r.history,Ye.url,Ye.signal)}let{shortCircuited:Je,matches:wt,loaderData:Ht,errors:mn}=await Uu(Ye,Q,Ve,Ge.active,Oe,ie&&ie.submission,ie&&ie.fetcherSubmission,ie&&ie.replace,ie&&ie.initialHydration===!0,mt,je);Je||(de=null,Un(Q,Ur({matches:wt||Ve},$E(je),{loaderData:Ht,errors:mn})))}async function Sc(D,Q,ie,he,Oe,Ve){Ve===void 0&&(Ve={}),Ba();let mt=aQ(Q,ie);if(Rt({navigation:mt},{flushSync:Ve.flushSync===!0}),Oe){let je=await va(he,Q.pathname,D.signal);if(je.type==="aborted")return{shortCircuited:!0};if(je.type==="error"){let Je=Bd(je.partialMatches).route.id;return{matches:je.partialMatches,pendingActionResult:[Je,{type:_r.error,error:je.error}]}}else if(je.matches)he=je.matches;else{let{notFoundMatches:Je,error:wt,route:Ht}=Wi(Q.pathname);return{matches:Je,pendingActionResult:[Ht.id,{type:_r.error,error:wt}]}}}let Ge,Ye=bp(he,Q);if(!Ye.route.action&&!Ye.route.lazy)Ge={type:_r.error,error:no(405,{method:D.method,pathname:Q.pathname,routeId:Ye.route.id})};else if(Ge=(await lo("action",I,D,[Ye],he,null))[Ye.route.id],D.signal.aborted)return{shortCircuited:!0};if(Wd(Ge)){let je;return Ve&&Ve.replace!=null?je=Ve.replace:je=IE(Ge.response.headers.get("Location"),new URL(D.url),d)===I.location.pathname+I.location.search,await An(D,Ge,!0,{submission:ie,replace:je}),{shortCircuited:!0}}if(wl(Ge))throw no(400,{type:"defer-action"});if(wo(Ge)){let je=Bd(he,Ye.route.id);return(Ve&&Ve.replace)!==!0&&(Y=rn.Push),{matches:he,pendingActionResult:[je.route.id,Ge]}}return{matches:he,pendingActionResult:[Ye.route.id,Ge]}}async function Uu(D,Q,ie,he,Oe,Ve,mt,Ge,Ye,je,Je){let wt=Oe||v_(Q,Ve),Ht=Ve||mt||LE(wt),mn=!J&&(!p.v7_partialHydration||!Ye);if(he){if(mn){let sr=Tc(Je);Rt(Ur({navigation:wt},sr!==void 0?{actionData:sr}:{}),{flushSync:je})}let jt=await va(ie,Q.pathname,D.signal);if(jt.type==="aborted")return{shortCircuited:!0};if(jt.type==="error"){let sr=Bd(jt.partialMatches).route.id;return{matches:jt.partialMatches,loaderData:{},errors:{[sr]:jt.error}}}else if(jt.matches)ie=jt.matches;else{let{error:sr,notFoundMatches:In,route:Os}=Wi(Q.pathname);return{matches:In,loaderData:{},errors:{[Os.id]:sr}}}}let ar=c||a,[Ut,Er]=SE(r.history,I,ie,Ht,Q,p.v7_partialHydration&&Ye===!0,p.v7_skipActionErrorRevalidation,K,re,q,Ie,ye,N,ar,d,Je);if(si(jt=>!(ie&&ie.some(sr=>sr.route.id===jt))||Ut&&Ut.some(sr=>sr.route.id===jt)),H=++O,Ut.length===0&&Er.length===0){let jt=qu();return Un(Q,Ur({matches:ie,loaderData:{},errors:Je&&wo(Je[1])?{[Je[0]]:Je[1].error}:null},$E(Je),jt?{fetchers:new Map(I.fetchers)}:{}),{flushSync:je}),{shortCircuited:!0}}if(mn){let jt={};if(!he){jt.navigation=wt;let sr=Tc(Je);sr!==void 0&&(jt.actionData=sr)}Er.length>0&&(jt.fetchers=Po(Er)),Rt(jt,{flushSync:je})}Er.forEach(jt=>{uo(jt.key),jt.controller&&$.set(jt.key,jt.controller)});let ci=()=>Er.forEach(jt=>uo(jt.key));de&&de.signal.addEventListener("abort",ci);let{loaderResults:$s,fetcherResults:ho}=await Bl(I,ie,Ut,Er,D);if(D.signal.aborted)return{shortCircuited:!0};de&&de.signal.removeEventListener("abort",ci),Er.forEach(jt=>$.delete(jt.key));let Kt=L0($s);if(Kt)return await An(D,Kt.result,!0,{replace:Ge}),{shortCircuited:!0};if(Kt=L0(ho),Kt)return N.add(Kt.key),await An(D,Kt.result,!0,{replace:Ge}),{shortCircuited:!0};let{loaderData:Gl,errors:ga}=PE(I,ie,$s,Je,Er,ho,Te);Te.forEach((jt,sr)=>{jt.subscribe(In=>{(In||jt.done)&&Te.delete(sr)})}),p.v7_partialHydration&&Ye&&I.errors&&(ga=Ur({},I.errors,ga));let Lo=qu(),Ho=Rc(H),ya=Lo||Ho||Er.length>0;return Ur({matches:ie,loaderData:Gl,errors:ga},ya?{fetchers:new Map(I.fetchers)}:{})}function Tc(D){if(D&&!wo(D[1]))return{[D[0]]:D[1].data};if(I.actionData)return Object.keys(I.actionData).length===0?null:I.actionData}function Po(D){return D.forEach(Q=>{let ie=I.fetchers.get(Q.key),he=q1(void 0,ie?ie.data:void 0);I.fetchers.set(Q.key,he)}),new Map(I.fetchers)}function Mo(D,Q,ie,he){if(n)throw new Error("router.fetch() was called during the server render, but it shouldn't be. You are likely calling a useFetcher() method in the body of your component. Try moving it to a useEffect or a callback.");uo(D);let Oe=(he&&he.flushSync)===!0,Ve=c||a,mt=hw(I.location,I.matches,d,p.v7_prependBasename,ie,p.v7_relativeSplatPath,Q,he==null?void 0:he.relative),Ge=Vh(Ve,mt,d),Ye=Ms(Ge,Ve,mt);if(Ye.active&&Ye.matches&&(Ge=Ye.matches),!Ge){Ii(D,Q,no(404,{pathname:mt}),{flushSync:Oe});return}let{path:je,submission:Je,error:wt}=kE(p.v7_normalizeFormMethod,!0,mt,he);if(wt){Ii(D,Q,wt,{flushSync:Oe});return}let Ht=bp(Ge,je),mn=(he&&he.preventScrollReset)===!0;if(Je&&Ia(Je.formMethod)){Ac(D,Q,je,Ht,Ge,Ye.active,Oe,mn,Je);return}ye.set(D,{routeId:Q,path:je}),zl(D,Q,je,Ht,Ge,Ye.active,Oe,mn,Je)}async function Ac(D,Q,ie,he,Oe,Ve,mt,Ge,Ye){Ba(),ye.delete(D);function je(Yt){if(!Yt.route.action&&!Yt.route.lazy){let Wa=no(405,{method:Ye.formMethod,pathname:ie,routeId:Q});return Ii(D,Q,Wa,{flushSync:mt}),!0}return!1}if(!Ve&&je(he))return;let Je=I.fetchers.get(D);ai(D,sQ(Ye,Je),{flushSync:mt});let wt=new AbortController,Ht=Th(r.history,ie,wt.signal,Ye);if(Ve){let Yt=await va(Oe,new URL(Ht.url).pathname,Ht.signal);if(Yt.type==="aborted")return;if(Yt.type==="error"){Ii(D,Q,Yt.error,{flushSync:mt});return}else if(Yt.matches){if(Oe=Yt.matches,he=bp(Oe,ie),je(he))return}else{Ii(D,Q,no(404,{pathname:ie}),{flushSync:mt});return}}$.set(D,wt);let mn=O,Ut=(await lo("action",I,Ht,[he],Oe,D))[he.route.id];if(Ht.signal.aborted){$.get(D)===wt&&$.delete(D);return}if(p.v7_fetcherPersist&&Ie.has(D)){if(Wd(Ut)||wo(Ut)){ai(D,dl(void 0));return}}else{if(Wd(Ut))if($.delete(D),H>mn){ai(D,dl(void 0));return}else return N.add(D),ai(D,q1(Ye)),An(Ht,Ut,!1,{fetcherSubmission:Ye,preventScrollReset:Ge});if(wo(Ut)){Ii(D,Q,Ut.error);return}}if(wl(Ut))throw no(400,{type:"defer-action"});let Er=I.navigation.location||I.location,ci=Th(r.history,Er,wt.signal),$s=c||a,ho=I.navigation.state!=="idle"?Vh($s,I.navigation.location,d):I.matches;Pr(ho,"Didn't find any matches after fetcher action");let Kt=++O;P.set(D,Kt);let Gl=q1(Ye,Ut.data);I.fetchers.set(D,Gl);let[ga,Lo]=SE(r.history,I,ho,Ye,Er,!1,p.v7_skipActionErrorRevalidation,K,re,q,Ie,ye,N,$s,d,[he.route.id,Ut]);Lo.filter(Yt=>Yt.key!==D).forEach(Yt=>{let Wa=Yt.key,Ku=I.fetchers.get(Wa),t1=q1(void 0,Ku?Ku.data:void 0);I.fetchers.set(Wa,t1),uo(Wa),Yt.controller&&$.set(Wa,Yt.controller)}),Rt({fetchers:new Map(I.fetchers)});let Ho=()=>Lo.forEach(Yt=>uo(Yt.key));wt.signal.addEventListener("abort",Ho);let{loaderResults:ya,fetcherResults:jt}=await Bl(I,ho,ga,Lo,ci);if(wt.signal.aborted)return;wt.signal.removeEventListener("abort",Ho),P.delete(D),$.delete(D),Lo.forEach(Yt=>$.delete(Yt.key));let sr=L0(ya);if(sr)return An(ci,sr.result,!1,{preventScrollReset:Ge});if(sr=L0(jt),sr)return N.add(sr.key),An(ci,sr.result,!1,{preventScrollReset:Ge});let{loaderData:In,errors:Os}=PE(I,ho,ya,void 0,Lo,jt,Te);if(I.fetchers.has(D)){let Yt=dl(Ut.data);I.fetchers.set(D,Yt)}Rc(Kt),I.navigation.state==="loading"&&Kt>H?(Pr(Y,"Expected pending action"),de&&de.abort(),Un(I.navigation.location,{matches:ho,loaderData:In,errors:Os,fetchers:new Map(I.fetchers)})):(Rt({errors:Os,loaderData:ME(I.loaderData,In,ho,Os),fetchers:new Map(I.fetchers)}),K=!1)}async function zl(D,Q,ie,he,Oe,Ve,mt,Ge,Ye){let je=I.fetchers.get(D);ai(D,q1(Ye,je?je.data:void 0),{flushSync:mt});let Je=new AbortController,wt=Th(r.history,ie,Je.signal);if(Ve){let Ut=await va(Oe,new URL(wt.url).pathname,wt.signal);if(Ut.type==="aborted")return;if(Ut.type==="error"){Ii(D,Q,Ut.error,{flushSync:mt});return}else if(Ut.matches)Oe=Ut.matches,he=bp(Oe,ie);else{Ii(D,Q,no(404,{pathname:ie}),{flushSync:mt});return}}$.set(D,Je);let Ht=O,ar=(await lo("loader",I,wt,[he],Oe,D))[he.route.id];if(wl(ar)&&(ar=await c8(ar,wt.signal,!0)||ar),$.get(D)===Je&&$.delete(D),!wt.signal.aborted){if(Ie.has(D)){ai(D,dl(void 0));return}if(Wd(ar))if(H>Ht){ai(D,dl(void 0));return}else{N.add(D),await An(wt,ar,!1,{preventScrollReset:Ge});return}if(wo(ar)){Ii(D,Q,ar.error);return}Pr(!wl(ar),"Unhandled fetcher deferred data"),ai(D,dl(ar.data))}}async function An(D,Q,ie,he){let{submission:Oe,fetcherSubmission:Ve,preventScrollReset:mt,replace:Ge}=he===void 0?{}:he;Q.response.headers.has("X-Remix-Revalidate")&&(K=!0);let Ye=Q.response.headers.get("Location");Pr(Ye,"Expected a Location header on the redirect Response"),Ye=IE(Ye,new URL(D.url),d);let je=Eu(I.location,Ye,{_isRedirect:!0});if(t){let Ut=!1;if(Q.response.headers.has("X-Remix-Reload-Document"))Ut=!0;else if(s8.test(Ye)){const Er=r.history.createURL(Ye);Ut=Er.origin!==e.location.origin||C4(Er.pathname,d)==null}if(Ut){Ge?e.location.replace(Ye):e.location.assign(Ye);return}}de=null;let Je=Ge===!0||Q.response.headers.has("X-Remix-Replace")?rn.Replace:rn.Push,{formMethod:wt,formAction:Ht,formEncType:mn}=I.navigation;!Oe&&!Ve&&wt&&Ht&&mn&&(Oe=LE(I.navigation));let ar=Oe||Ve;if(FY.has(Q.response.status)&&ar&&Ia(ar.formMethod))await qi(Je,je,{submission:Ur({},ar,{formAction:Ye}),preventScrollReset:mt||le,enableViewTransition:ie?Ee:void 0});else{let Ut=v_(je,Oe);await qi(Je,je,{overrideNavigation:Ut,fetcherSubmission:Ve,preventScrollReset:mt||le,enableViewTransition:ie?Ee:void 0})}}async function lo(D,Q,ie,he,Oe,Ve){let mt,Ge={};try{mt=await KY(h,D,Q,ie,he,Oe,Ve,o,i)}catch(Ye){return he.forEach(je=>{Ge[je.route.id]={type:_r.error,error:Ye}}),Ge}for(let[Ye,je]of Object.entries(mt))if(tQ(je)){let Je=je.result;Ge[Ye]={type:_r.redirect,response:XY(Je,ie,Ye,Oe,d,p.v7_relativeSplatPath)}}else Ge[Ye]=await QY(je);return Ge}async function Bl(D,Q,ie,he,Oe){let Ve=D.matches,mt=lo("loader",D,Oe,ie,Q,null),Ge=Promise.all(he.map(async Je=>{if(Je.matches&&Je.match&&Je.controller){let Ht=(await lo("loader",D,Th(r.history,Je.path,Je.controller.signal),[Je.match],Je.matches,Je.key))[Je.match.route.id];return{[Je.key]:Ht}}else return Promise.resolve({[Je.key]:{type:_r.error,error:no(404,{pathname:Je.path})}})})),Ye=await mt,je=(await Ge).reduce((Je,wt)=>Object.assign(Je,wt),{});return await Promise.all([iQ(Q,Ye,Oe.signal,Ve,D.loaderData),oQ(Q,je,he)]),{loaderResults:Ye,fetcherResults:je}}function Ba(){K=!0,re.push(...si()),ye.forEach((D,Q)=>{$.has(Q)&&q.add(Q),uo(Q)})}function ai(D,Q,ie){ie===void 0&&(ie={}),I.fetchers.set(D,Q),Rt({fetchers:new Map(I.fetchers)},{flushSync:(ie&&ie.flushSync)===!0})}function Ii(D,Q,ie,he){he===void 0&&(he={});let Oe=Bd(I.matches,Q);$o(D),Rt({errors:{[Oe.route.id]:ie},fetchers:new Map(I.fetchers)},{flushSync:(he&&he.flushSync)===!0})}function Ua(D){return Pe.set(D,(Pe.get(D)||0)+1),Ie.has(D)&&Ie.delete(D),I.fetchers.get(D)||jY}function $o(D){let Q=I.fetchers.get(D);$.has(D)&&!(Q&&Q.state==="loading"&&P.has(D))&&uo(D),ye.delete(D),P.delete(D),N.delete(D),p.v7_fetcherPersist&&Ie.delete(D),q.delete(D),I.fetchers.delete(D)}function e1(D){let Q=(Pe.get(D)||0)-1;Q<=0?(Pe.delete(D),Ie.add(D),p.v7_fetcherPersist||$o(D)):Pe.set(D,Q),Rt({fetchers:new Map(I.fetchers)})}function uo(D){let Q=$.get(D);Q&&(Q.abort(),$.delete(D))}function Ic(D){for(let Q of D){let ie=Ua(Q),he=dl(ie.data);I.fetchers.set(Q,he)}}function qu(){let D=[],Q=!1;for(let ie of N){let he=I.fetchers.get(ie);Pr(he,"Expected fetcher: "+ie),he.state==="loading"&&(N.delete(ie),D.push(ie),Q=!0)}return Ic(D),Q}function Rc(D){let Q=[];for(let[ie,he]of P)if(he<D){let Oe=I.fetchers.get(ie);Pr(Oe,"Expected fetcher: "+ie),Oe.state==="loading"&&(uo(ie),P.delete(ie),Q.push(ie))}return Ic(Q),Q.length>0}function Ps(D,Q){let ie=I.blockers.get(D)||U1;return Ke.get(D)!==Q&&Ke.set(D,Q),ie}function Oo(D){I.blockers.delete(D),Ke.delete(D)}function Zo(D,Q){let ie=I.blockers.get(D)||U1;Pr(ie.state==="unblocked"&&Q.state==="blocked"||ie.state==="blocked"&&Q.state==="blocked"||ie.state==="blocked"&&Q.state==="proceeding"||ie.state==="blocked"&&Q.state==="unblocked"||ie.state==="proceeding"&&Q.state==="unblocked","Invalid blocker state transition: "+ie.state+" -> "+Q.state);let he=new Map(I.blockers);he.set(D,Q),Rt({blockers:he})}function qa(D){let{currentLocation:Q,nextLocation:ie,historyAction:he}=D;if(Ke.size===0)return;Ke.size>1&&$l(!1,"A router only supports one blocker at a time");let Oe=Array.from(Ke.entries()),[Ve,mt]=Oe[Oe.length-1],Ge=I.blockers.get(Ve);if(!(Ge&&Ge.state==="proceeding")&&mt({currentLocation:Q,nextLocation:ie,historyAction:he}))return Ve}function Wi(D){let Q=no(404,{pathname:D}),ie=c||a,{matches:he,route:Oe}=OE(ie);return si(),{notFoundMatches:he,route:Oe,error:Q}}function si(D){let Q=[];return Te.forEach((ie,he)=>{(!D||D(he))&&(ie.cancel(),Q.push(he),Te.delete(he))}),Q}function Wu(D,Q,ie){if(_=D,C=Q,b=ie||null,!T&&I.navigation===m_){T=!0;let he=ql(I.location,I.matches);he!=null&&Rt({restoreScrollPosition:he})}return()=>{_=null,C=null,b=null}}function Ul(D,Q){return b&&b(D,Q.map(he=>gY(he,I.loaderData)))||D.key}function Gu(D,Q){if(_&&C){let ie=Ul(D,Q);_[ie]=C()}}function ql(D,Q){if(_){let ie=Ul(D,Q),he=_[ie];if(typeof he=="number")return he}return null}function Ms(D,Q,ie){if(u)if(D){if(Object.keys(D[0].params).length>0)return{active:!0,matches:Mv(Q,ie,d,!0)}}else return{active:!0,matches:Mv(Q,ie,d,!0)||[]};return{active:!1,matches:null}}async function va(D,Q,ie){if(!u)return{type:"success",matches:D};let he=D;for(;;){let Oe=c==null,Ve=c||a,mt=o;try{await u({signal:ie,path:Q,matches:he,patch:(je,Je)=>{ie.aborted||AE(je,Je,Ve,mt,i)}})}catch(je){return{type:"error",error:je,partialMatches:he}}finally{Oe&&!ie.aborted&&(a=[...a])}if(ie.aborted)return{type:"aborted"};let Ge=Vh(Ve,Q,d);if(Ge)return{type:"success",matches:Ge};let Ye=Mv(Ve,Q,d,!0);if(!Ye||he.length===Ye.length&&he.every((je,Je)=>je.route.id===Ye[Je].route.id))return{type:"success",matches:null};he=Ye}}function Wl(D){o={},c=Og(D,i,void 0,o)}function Ri(D,Q){let ie=c==null;AE(D,Q,c||a,o,i),ie&&(a=[...a],Rt({}))}return U={get basename(){return d},get future(){return p},get state(){return I},get routes(){return a},get window(){return e},initialize:_t,subscribe:Wr,enableScrollRestoration:Wu,navigate:co,fetch:Mo,revalidate:ma,createHref:D=>r.history.createHref(D),encodeLocation:D=>r.history.encodeLocation(D),getFetcher:Ua,deleteFetcher:e1,dispose:yr,getBlocker:Ps,deleteBlocker:Oo,patchRoutes:Ri,_internalFetchControllers:$,_internalActiveDeferreds:Te,_internalSetRoutes:Wl},U}function UY(r){return r!=null&&("formData"in r&&r.formData!=null||"body"in r&&r.body!==void 0)}function hw(r,e,t,n,i,o,a,c){let d,h;if(a){d=[];for(let p of e)if(d.push(p),p.route.id===a){h=p;break}}else d=e,h=e[e.length-1];let u=$Y(i||".",MY(d,o),C4(r.pathname,t)||r.pathname,c==="path");if(i==null&&(u.search=r.search,u.hash=r.hash),(i==null||i===""||i===".")&&h){let p=l8(u.search);if(h.route.index&&!p)u.search=u.search?u.search.replace(/^\?/,"?index&"):"?index";else if(!h.route.index&&p){let v=new URLSearchParams(u.search),g=v.getAll("index");v.delete("index"),g.filter(b=>b).forEach(b=>v.append("index",b));let _=v.toString();u.search=_?"?"+_:""}}return n&&t!=="/"&&(u.pathname=u.pathname==="/"?t:Vp([t,u.pathname])),Nu(u)}function kE(r,e,t,n){if(!n||!UY(n))return{path:t};if(n.formMethod&&!nQ(n.formMethod))return{path:t,error:no(405,{method:n.formMethod})};let i=()=>({path:t,error:no(400,{type:"invalid-body"})}),o=n.formMethod||"get",a=r?o.toUpperCase():o.toLowerCase(),c=$M(t);if(n.body!==void 0){if(n.formEncType==="text/plain"){if(!Ia(a))return i();let v=typeof n.body=="string"?n.body:n.body instanceof FormData||n.body instanceof URLSearchParams?Array.from(n.body.entries()).reduce((g,_)=>{let[b,C]=_;return""+g+b+"="+C+`
419
- `},""):String(n.body);return{path:t,submission:{formMethod:a,formAction:c,formEncType:n.formEncType,formData:void 0,json:void 0,text:v}}}else if(n.formEncType==="application/json"){if(!Ia(a))return i();try{let v=typeof n.body=="string"?JSON.parse(n.body):n.body;return{path:t,submission:{formMethod:a,formAction:c,formEncType:n.formEncType,formData:void 0,json:v,text:void 0}}}catch{return i()}}}Pr(typeof FormData=="function","FormData is not available in this environment");let d,h;if(n.formData)d=pw(n.formData),h=n.formData;else if(n.body instanceof FormData)d=pw(n.body),h=n.body;else if(n.body instanceof URLSearchParams)d=n.body,h=RE(d);else if(n.body==null)d=new URLSearchParams,h=new FormData;else try{d=new URLSearchParams(n.body),h=RE(d)}catch{return i()}let u={formMethod:a,formAction:c,formEncType:n&&n.formEncType||"application/x-www-form-urlencoded",formData:h,json:void 0,text:void 0};if(Ia(u.formMethod))return{path:t,submission:u};let p=Cc(t);return e&&p.search&&l8(p.search)&&d.append("index",""),p.search="?"+d,{path:Nu(p),submission:u}}function EE(r,e,t){t===void 0&&(t=!1);let n=r.findIndex(i=>i.route.id===e);return n>=0?r.slice(0,t?n+1:n):r}function SE(r,e,t,n,i,o,a,c,d,h,u,p,v,g,_,b){let C=b?wo(b[1])?b[1].error:b[1].data:void 0,T=r.createURL(e.location),S=r.createURL(i),A=t;o&&e.errors?A=EE(t,Object.keys(e.errors)[0],!0):b&&wo(b[1])&&(A=EE(t,b[0]));let Z=b?b[1].statusCode:void 0,B=a&&Z&&Z>=400,U=A.filter((Y,le)=>{let{route:de}=Y;if(de.lazy)return!0;if(de.loader==null)return!1;if(o)return fw(de,e.loaderData,e.errors);if(qY(e.loaderData,e.matches[le],Y)||d.some(Ce=>Ce===Y.route.id))return!0;let Ee=e.matches[le],we=Y;return TE(Y,Ur({currentUrl:T,currentParams:Ee.params,nextUrl:S,nextParams:we.params},n,{actionResult:C,actionStatus:Z,defaultShouldRevalidate:B?!1:c||T.pathname+T.search===S.pathname+S.search||T.search!==S.search||PM(Ee,we)}))}),I=[];return p.forEach((Y,le)=>{if(o||!t.some(J=>J.route.id===Y.routeId)||u.has(le))return;let de=Vh(g,Y.path,_);if(!de){I.push({key:le,routeId:Y.routeId,path:Y.path,matches:null,match:null,controller:null});return}let Ee=e.fetchers.get(le),we=bp(de,Y.path),Ce=!1;v.has(le)?Ce=!1:h.has(le)?(h.delete(le),Ce=!0):Ee&&Ee.state!=="idle"&&Ee.data===void 0?Ce=c:Ce=TE(we,Ur({currentUrl:T,currentParams:e.matches[e.matches.length-1].params,nextUrl:S,nextParams:t[t.length-1].params},n,{actionResult:C,actionStatus:Z,defaultShouldRevalidate:B?!1:c})),Ce&&I.push({key:le,routeId:Y.routeId,path:Y.path,matches:de,match:we,controller:new AbortController})}),[U,I]}function fw(r,e,t){if(r.lazy)return!0;if(!r.loader)return!1;let n=e!=null&&e[r.id]!==void 0,i=t!=null&&t[r.id]!==void 0;return!n&&i?!1:typeof r.loader=="function"&&r.loader.hydrate===!0?!0:!n&&!i}function qY(r,e,t){let n=!e||t.route.id!==e.route.id,i=r[t.route.id]===void 0;return n||i}function PM(r,e){let t=r.route.path;return r.pathname!==e.pathname||t!=null&&t.endsWith("*")&&r.params["*"]!==e.params["*"]}function TE(r,e){if(r.route.shouldRevalidate){let t=r.route.shouldRevalidate(e);if(typeof t=="boolean")return t}return e.defaultShouldRevalidate}function AE(r,e,t,n,i){var o;let a;if(r){let h=n[r];Pr(h,"No route found to patch children into: routeId = "+r),h.children||(h.children=[]),a=h.children}else a=t;let c=e.filter(h=>!a.some(u=>MM(h,u))),d=Og(c,i,[r||"_","patch",String(((o=a)==null?void 0:o.length)||"0")],n);a.push(...d)}function MM(r,e){return"id"in r&&"id"in e&&r.id===e.id?!0:r.index===e.index&&r.path===e.path&&r.caseSensitive===e.caseSensitive?(!r.children||r.children.length===0)&&(!e.children||e.children.length===0)?!0:r.children.every((t,n)=>{var i;return(i=e.children)==null?void 0:i.some(o=>MM(t,o))}):!1}async function WY(r,e,t){if(!r.lazy)return;let n=await r.lazy();if(!r.lazy)return;let i=t[r.id];Pr(i,"No route found in manifest");let o={};for(let a in n){let d=i[a]!==void 0&&a!=="hasErrorBoundary";$l(!d,'Route "'+i.id+'" has a static property "'+a+'" defined but its lazy function is also returning a value for this property. '+('The lazy route property "'+a+'" will be ignored.')),!d&&!mY.has(a)&&(o[a]=n[a])}Object.assign(i,o),Object.assign(i,Ur({},e(i),{lazy:void 0}))}async function GY(r){let{matches:e}=r,t=e.filter(i=>i.shouldLoad);return(await Promise.all(t.map(i=>i.resolve()))).reduce((i,o,a)=>Object.assign(i,{[t[a].route.id]:o}),{})}async function KY(r,e,t,n,i,o,a,c,d,h){let u=o.map(g=>g.route.lazy?WY(g.route,d,c):void 0),p=o.map((g,_)=>{let b=u[_],C=i.some(S=>S.route.id===g.route.id);return Ur({},g,{shouldLoad:C,resolve:async S=>(S&&n.method==="GET"&&(g.route.lazy||g.route.loader)&&(C=!0),C?YY(e,n,g,b,S,h):Promise.resolve({type:_r.data,result:void 0}))})}),v=await r({matches:p,request:n,params:o[0].params,fetcherKey:a,context:h});try{await Promise.all(u)}catch{}return v}async function YY(r,e,t,n,i,o){let a,c,d=h=>{let u,p=new Promise((_,b)=>u=b);c=()=>u(),e.signal.addEventListener("abort",c);let v=_=>typeof h!="function"?Promise.reject(new Error("You cannot call the handler for a route which defines a boolean "+('"'+r+'" [routeId: '+t.route.id+"]"))):h({request:e,params:t.params,context:o},..._!==void 0?[_]:[]),g=(async()=>{try{return{type:"data",result:await(i?i(b=>v(b)):v())}}catch(_){return{type:"error",result:_}}})();return Promise.race([g,p])};try{let h=t.route[r];if(n)if(h){let u,[p]=await Promise.all([d(h).catch(v=>{u=v}),n]);if(u!==void 0)throw u;a=p}else if(await n,h=t.route[r],h)a=await d(h);else if(r==="action"){let u=new URL(e.url),p=u.pathname+u.search;throw no(405,{method:e.method,pathname:p,routeId:t.route.id})}else return{type:_r.data,result:void 0};else if(h)a=await d(h);else{let u=new URL(e.url),p=u.pathname+u.search;throw no(404,{pathname:p})}Pr(a.result!==void 0,"You defined "+(r==="action"?"an action":"a loader")+" for route "+('"'+t.route.id+"\" but didn't return anything from your `"+r+"` ")+"function. Please return a value or `null`.")}catch(h){return{type:_r.error,result:h}}finally{c&&e.signal.removeEventListener("abort",c)}return a}async function QY(r){let{result:e,type:t}=r;if(OM(e)){let p;try{let v=e.headers.get("Content-Type");v&&/\bapplication\/json\b/.test(v)?e.body==null?p=null:p=await e.json():p=await e.text()}catch(v){return{type:_r.error,error:v}}return t===_r.error?{type:_r.error,error:new uw(e.status,e.statusText,p),statusCode:e.status,headers:e.headers}:{type:_r.data,data:p,statusCode:e.status,headers:e.headers}}if(t===_r.error){if(ZE(e)){var n,i;if(e.data instanceof Error){var o,a;return{type:_r.error,error:e.data,statusCode:(o=e.init)==null?void 0:o.status,headers:(a=e.init)!=null&&a.headers?new Headers(e.init.headers):void 0}}return{type:_r.error,error:new uw(((n=e.init)==null?void 0:n.status)||500,void 0,e.data),statusCode:Zg(e)?e.status:void 0,headers:(i=e.init)!=null&&i.headers?new Headers(e.init.headers):void 0}}return{type:_r.error,error:e,statusCode:Zg(e)?e.status:void 0}}if(rQ(e)){var c,d;return{type:_r.deferred,deferredData:e,statusCode:(c=e.init)==null?void 0:c.status,headers:((d=e.init)==null?void 0:d.headers)&&new Headers(e.init.headers)}}if(ZE(e)){var h,u;return{type:_r.data,data:e.data,statusCode:(h=e.init)==null?void 0:h.status,headers:(u=e.init)!=null&&u.headers?new Headers(e.init.headers):void 0}}return{type:_r.data,data:e}}function XY(r,e,t,n,i,o){let a=r.headers.get("Location");if(Pr(a,"Redirects returned/thrown from loaders/actions must have a Location header"),!s8.test(a)){let c=n.slice(0,n.findIndex(d=>d.route.id===t)+1);a=hw(new URL(e.url),c,i,!0,a,o),r.headers.set("Location",a)}return r}function IE(r,e,t){if(s8.test(r)){let n=r,i=n.startsWith("//")?new URL(e.protocol+n):new URL(n),o=C4(i.pathname,t)!=null;if(i.origin===e.origin&&o)return i.pathname+i.search+i.hash}return r}function Th(r,e,t,n){let i=r.createURL($M(e)).toString(),o={signal:t};if(n&&Ia(n.formMethod)){let{formMethod:a,formEncType:c}=n;o.method=a.toUpperCase(),c==="application/json"?(o.headers=new Headers({"Content-Type":c}),o.body=JSON.stringify(n.json)):c==="text/plain"?o.body=n.text:c==="application/x-www-form-urlencoded"&&n.formData?o.body=pw(n.formData):o.body=n.formData}return new Request(i,o)}function pw(r){let e=new URLSearchParams;for(let[t,n]of r.entries())e.append(t,typeof n=="string"?n:n.name);return e}function RE(r){let e=new FormData;for(let[t,n]of r.entries())e.append(t,n);return e}function JY(r,e,t,n,i){let o={},a=null,c,d=!1,h={},u=t&&wo(t[1])?t[1].error:void 0;return r.forEach(p=>{if(!(p.route.id in e))return;let v=p.route.id,g=e[v];if(Pr(!Wd(g),"Cannot handle redirect results in processLoaderData"),wo(g)){let _=g.error;u!==void 0&&(_=u,u=void 0),a=a||{};{let b=Bd(r,v);a[b.route.id]==null&&(a[b.route.id]=_)}o[v]=void 0,d||(d=!0,c=Zg(g.error)?g.error.status:500),g.headers&&(h[v]=g.headers)}else wl(g)?(n.set(v,g.deferredData),o[v]=g.deferredData.data,g.statusCode!=null&&g.statusCode!==200&&!d&&(c=g.statusCode),g.headers&&(h[v]=g.headers)):(o[v]=g.data,g.statusCode&&g.statusCode!==200&&!d&&(c=g.statusCode),g.headers&&(h[v]=g.headers))}),u!==void 0&&t&&(a={[t[0]]:u},o[t[0]]=void 0),{loaderData:o,errors:a,statusCode:c||200,loaderHeaders:h}}function PE(r,e,t,n,i,o,a){let{loaderData:c,errors:d}=JY(e,t,n,a);return i.forEach(h=>{let{key:u,match:p,controller:v}=h,g=o[u];if(Pr(g,"Did not find corresponding fetcher result"),!(v&&v.signal.aborted))if(wo(g)){let _=Bd(r.matches,p==null?void 0:p.route.id);d&&d[_.route.id]||(d=Ur({},d,{[_.route.id]:g.error})),r.fetchers.delete(u)}else if(Wd(g))Pr(!1,"Unhandled fetcher revalidation redirect");else if(wl(g))Pr(!1,"Unhandled fetcher deferred data");else{let _=dl(g.data);r.fetchers.set(u,_)}}),{loaderData:c,errors:d}}function ME(r,e,t,n){let i=Ur({},e);for(let o of t){let a=o.route.id;if(e.hasOwnProperty(a)?e[a]!==void 0&&(i[a]=e[a]):r[a]!==void 0&&o.route.loader&&(i[a]=r[a]),n&&n.hasOwnProperty(a))break}return i}function $E(r){return r?wo(r[1])?{actionData:{}}:{actionData:{[r[0]]:r[1].data}}:{}}function Bd(r,e){return(e?r.slice(0,r.findIndex(n=>n.route.id===e)+1):[...r]).reverse().find(n=>n.route.hasErrorBoundary===!0)||r[0]}function OE(r){let e=r.length===1?r[0]:r.find(t=>t.index||!t.path||t.path==="/")||{id:"__shim-error-route__"};return{matches:[{params:{},pathname:"",pathnameBase:"",route:e}],route:e}}function no(r,e){let{pathname:t,routeId:n,method:i,type:o,message:a}=e===void 0?{}:e,c="Unknown Server Error",d="Unknown @remix-run/router error";return r===400?(c="Bad Request",i&&t&&n?d="You made a "+i+' request to "'+t+'" but '+('did not provide a `loader` for route "'+n+'", ')+"so there is no way to handle the request.":o==="defer-action"?d="defer() is not supported in actions":o==="invalid-body"&&(d="Unable to encode submission body")):r===403?(c="Forbidden",d='Route "'+n+'" does not match URL "'+t+'"'):r===404?(c="Not Found",d='No route matches URL "'+t+'"'):r===405&&(c="Method Not Allowed",i&&t&&n?d="You made a "+i.toUpperCase()+' request to "'+t+'" but '+('did not provide an `action` for route "'+n+'", ')+"so there is no way to handle the request.":i&&(d='Invalid request method "'+i.toUpperCase()+'"')),new uw(r||500,c,new Error(d),!0)}function L0(r){let e=Object.entries(r);for(let t=e.length-1;t>=0;t--){let[n,i]=e[t];if(Wd(i))return{key:n,result:i}}}function $M(r){let e=typeof r=="string"?Cc(r):r;return Nu(Ur({},e,{hash:""}))}function eQ(r,e){return r.pathname!==e.pathname||r.search!==e.search?!1:r.hash===""?e.hash!=="":r.hash===e.hash?!0:e.hash!==""}function tQ(r){return OM(r.result)&&VY.has(r.result.status)}function wl(r){return r.type===_r.deferred}function wo(r){return r.type===_r.error}function Wd(r){return(r&&r.type)===_r.redirect}function ZE(r){return typeof r=="object"&&r!=null&&"type"in r&&"data"in r&&"init"in r&&r.type==="DataWithResponseInit"}function rQ(r){let e=r;return e&&typeof e=="object"&&typeof e.data=="object"&&typeof e.subscribe=="function"&&typeof e.cancel=="function"&&typeof e.resolveData=="function"}function OM(r){return r!=null&&typeof r.status=="number"&&typeof r.statusText=="string"&&typeof r.headers=="object"&&typeof r.body<"u"}function nQ(r){return DY.has(r.toLowerCase())}function Ia(r){return HY.has(r.toLowerCase())}async function iQ(r,e,t,n,i){let o=Object.entries(e);for(let a=0;a<o.length;a++){let[c,d]=o[a],h=r.find(v=>(v==null?void 0:v.route.id)===c);if(!h)continue;let u=n.find(v=>v.route.id===h.route.id),p=u!=null&&!PM(u,h)&&(i&&i[h.route.id])!==void 0;wl(d)&&p&&await c8(d,t,!1).then(v=>{v&&(e[c]=v)})}}async function oQ(r,e,t){for(let n=0;n<t.length;n++){let{key:i,routeId:o,controller:a}=t[n],c=e[i];r.find(h=>(h==null?void 0:h.route.id)===o)&&wl(c)&&(Pr(a,"Expected an AbortController for revalidating fetcher deferred result"),await c8(c,a.signal,!0).then(h=>{h&&(e[i]=h)}))}}async function c8(r,e,t){if(t===void 0&&(t=!1),!await r.deferredData.resolveData(e)){if(t)try{return{type:_r.data,data:r.deferredData.unwrappedData}}catch(i){return{type:_r.error,error:i}}return{type:_r.data,data:r.deferredData.data}}}function l8(r){return new URLSearchParams(r).getAll("index").some(e=>e==="")}function bp(r,e){let t=typeof e=="string"?Cc(e).search:e.search;if(r[r.length-1].route.index&&l8(t||""))return r[r.length-1];let n=AM(r);return n[n.length-1]}function LE(r){let{formMethod:e,formAction:t,formEncType:n,text:i,formData:o,json:a}=r;if(!(!e||!t||!n)){if(i!=null)return{formMethod:e,formAction:t,formEncType:n,formData:void 0,json:void 0,text:i};if(o!=null)return{formMethod:e,formAction:t,formEncType:n,formData:o,json:void 0,text:void 0};if(a!==void 0)return{formMethod:e,formAction:t,formEncType:n,formData:void 0,json:a,text:void 0}}}function v_(r,e){return e?{state:"loading",location:r,formMethod:e.formMethod,formAction:e.formAction,formEncType:e.formEncType,formData:e.formData,json:e.json,text:e.text}:{state:"loading",location:r,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0}}function aQ(r,e){return{state:"submitting",location:r,formMethod:e.formMethod,formAction:e.formAction,formEncType:e.formEncType,formData:e.formData,json:e.json,text:e.text}}function q1(r,e){return r?{state:"loading",formMethod:r.formMethod,formAction:r.formAction,formEncType:r.formEncType,formData:r.formData,json:r.json,text:r.text,data:e}:{state:"loading",formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0,data:e}}function sQ(r,e){return{state:"submitting",formMethod:r.formMethod,formAction:r.formAction,formEncType:r.formEncType,formData:r.formData,json:r.json,text:r.text,data:e?e.data:void 0}}function dl(r){return{state:"idle",formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0,data:r}}function cQ(r,e){try{let t=r.sessionStorage.getItem(RM);if(t){let n=JSON.parse(t);for(let[i,o]of Object.entries(n||{}))o&&Array.isArray(o)&&e.set(i,new Set(o||[]))}}catch{}}function lQ(r,e){if(e.size>0){let t={};for(let[n,i]of e)t[n]=[...i];try{r.sessionStorage.setItem(RM,JSON.stringify(t))}catch(n){$l(!1,"Failed to save applied view transitions in sessionStorage ("+n+").")}}}const ZM=r=>{switch(r){case"hash":return fY({v5Compat:!0});case"memory":return uY({v5Compat:!0});case"browser":return hY({v5Compat:!0});default:return console.warn(`Unknown history type: ${r}. Using browser history as default.`),ZM("browser")}};var ln=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},H0=function(r,e,t,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?r!==e||!i:!e.has(r))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(r,t):i?i.value=t:e.set(r,t),t},Qo,$v,mw,Ov,os,wp;const HE=r=>typeof r=="object"&&"key"in r;class dQ extends Tt{get basename(){return ln(this,$v,"f")}get origin(){return ln(this,mw,"f")}get state(){return ln(this,os,"f").asObservable()}get value(){return ln(this,os,"f").value}get location(){return this.value.location}get action(){return this.value.action}constructor(e){super(i=>ln(this,os,"f").subscribe(i)),Qo.set(this,void 0),$v.set(this,void 0),mw.set(this,window.location.origin),Ov.set(this,new ti),os.set(this,void 0),wp.set(this,void 0);const{basename:t,history:n}=e;H0(this,wp,e.logger||console,"f"),H0(this,$v,t,"f"),H0(this,Qo,n,"f"),H0(this,os,new Df({action:ln(this,Qo,"f").action,location:ln(this,Qo,"f").location,delta:null}),"f"),ln(this,Ov,"f").add(ln(this,Qo,"f").listen(i=>{i.location.key!==ln(this,os,"f").value.location.key&&ln(this,os,"f").next(i)}))}encodeLocation(e){return ln(this,Qo,"f").encodeLocation(e)}listen(e){const t=ln(this,os,"f").subscribe(e);return ln(this,wp,"f").debug("Navigator::listen",e),()=>(ln(this,wp,"f").debug("Navigator::listen[unsubscribe]",e),t.unsubscribe())}createHref(e){return ln(this,Qo,"f").createHref(e)}go(e){ln(this,Qo,"f").go(e)}push(e,t){HE(e)&&this._isDuplicateLocation(e)||ln(this,Qo,"f").push(e,t)}replace(e,t){HE(e)&&this._isDuplicateLocation(e)||ln(this,Qo,"f").replace(e,t)}createURL(e){return ln(this,Qo,"f").createURL(e)}_isDuplicateLocation(e){return e.key===ln(this,os,"f").value.location.key}dispose(){ln(this,Ov,"f").unsubscribe()}}Qo=new WeakMap,$v=new WeakMap,mw=new WeakMap,Ov=new WeakMap,os=new WeakMap,wp=new WeakMap;var qo=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},NE=function(r,e,t,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?r!==e||!i:!e.has(r))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(r,t):i?i.value=t:e.set(r,t),t},Aa,Ld;const DE=r=>r.replace(/\/+/g,"/");class uQ extends OR{get state$(){return qo(this,Aa,"f").pipe($e(e=>qo(this,Ld,"f")?e.location.pathname.startsWith(qo(this,Ld,"f")):!0),me(({action:e,location:t})=>({action:e,location:this._localizePath(t)})))}get navigator(){return qo(this,Aa,"f")}get path(){return this._localizePath(this.navigator.location)}constructor(e){super(e),Aa.set(this,void 0),Ld.set(this,void 0);const{basename:t,history:n}=e.config;if(NE(this,Ld,t,"f"),!n)throw Error("no history provided!");NE(this,Aa,new dQ({basename:t,history:n}),"f"),this._addTeardown(()=>qo(this,Aa,"f").dispose())}createRouter(e){const t=qo(this,Aa,"f");console.debug("NavigationProvider::createRouter",e);const n=BY({basename:t.basename,history:t,routes:e,future:{v7_prependBasename:!0}});return n.initialize(),n}createHref(e){return qo(this,Aa,"f").createHref(this._createToPath(e??this.path))}createURL(e){return qo(this,Aa,"f").createURL(this._createToPath(e??this.path))}push(e,t){qo(this,Aa,"f").push(this._createToPath(e),t)}replace(e,t){qo(this,Aa,"f").replace(this._createToPath(e),t)}_localizePath(e){var t;const{pathname:n,search:i,hash:o}=e;return{pathname:DE(n.replace((t=qo(this,Ld,"f"))!==null&&t!==void 0?t:"","")),search:i,hash:o}}_createToPath(e){const{pathname:t,search:n,hash:i}=typeof e=="string"?{pathname:e,search:void 0,hash:void 0}:e;return{pathname:DE([qo(this,Ld,"f"),t==="/"?void 0:t].filter(o=>!!o).join("/")),search:n,hash:i}}}Aa=new WeakMap,Ld=new WeakMap;const VE="4.0.8",hQ="navigation",fQ={version:new fs(VE),name:hQ,configure:r=>{const e=new dY;return r!=null&&r.navigation&&(e.history=r.navigation.navigator),e},initialize:({config:r})=>{var e;return(e=r.history)!==null&&e!==void 0||(r.history=ZM()),new uQ({version:VE,config:r})},dispose({instance:r}){r.dispose()}},pQ=(r,e)=>{const t=e;r.addConfig(Object.assign({module:fQ},t))};var mQ=function(r,e,t,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?r!==e||!i:!e.has(r))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(r,t):i?i.value=t:e.set(r,t),t},W1=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},Jc;const LM="::",vQ=r=>{const[e,t]=r.split(LM);return{namespace:e,id:t}};class HM{constructor(e,t){this.namespace=e,Jc.set(this,void 0),mQ(this,Jc,t,"f")}*[(Jc=new WeakMap,Symbol.iterator)](){for(const e of Object.values(this.getItems()))yield e}generateId(e){return[this.namespace,e].join(LM)}setItem(e,t){W1(this,Jc,"f").setItem(this.generateId(e),JSON.stringify(t))}removeItem(e){W1(this,Jc,"f").removeItem(this.generateId(e))}getItem(e){const t=W1(this,Jc,"f").getItem(this.generateId(e));return t?JSON.parse(t):void 0}getItems(){return this._getItems().reduce((e,{id:t,value:n})=>Object.assign(e,{[t]:n}),{})}clear(){for(const e of this._getItems())W1(this,Jc,"f").removeItem(e.key)}_getItems(){const{namespace:e}=this;return Object.entries(W1(this,Jc,"f")).map(([t,n])=>Object.assign(Object.assign({},vQ(t)),{key:t,value:n})).filter(t=>t.namespace===e).map(t=>Object.assign(t,{value:JSON.parse(t.value)}))}}class gQ extends HM{constructor(e){super(e,window.localStorage)}}class yQ extends HM{constructor(e){super(e,window.sessionStorage)}}const _Q=(r,e)=>{switch(e){case"local":return new gQ(r);case"session":return new yQ(r)}throw Error("invalid type provided")};var FE=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};const NM=(r,e)=>()=>FE(void 0,void 0,void 0,function*(){const{name:t,type:n="local"}=e??{},i=["FEATURES",t].filter(a=>!!a).join("_"),o=_Q(i,n);return{connect:({provider:a})=>a.onFeatureToggle(({features:c})=>{c.map(d=>o.setItem(d.key,d))}),initial:()=>FE(void 0,void 0,void 0,function*(){const a=yield o.getItems();return r.map(c=>{const d=a[c.key];return Object.assign(Object.assign({},c),{enabled:d?d.enabled:c.enabled})})})}}),bQ=r=>!(r.value==="0"||r.value==="false");var jE=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};const DM=(r,e)=>{if(!r.length)return()=>Promise.resolve({});const t=r.map(n=>typeof n=="string"?n:n.key);return n=>jE(void 0,void 0,void 0,function*(){if(!n.hasModule("navigation"))throw Error("missing navigation module");const i=yield n.requireInstance("navigation"),{isFeatureEnabled:o=bQ}=e??{};return{order:-1,initial:()=>jE(void 0,void 0,void 0,function*(){return r.filter(a=>typeof a!="string")}),connect(a){const{provider:c}=a,d=new ti,h=new Bn,u=new Bn,p=c.features$.pipe(me(g=>Object.values(g)),me(g=>g.filter(_=>t.includes(_.key)))),v=u.pipe(Up(p),me(([g,_])=>{const b=new URLSearchParams(g.search);return _.reduce((C,T)=>{const{key:S}=T;if(b.has(S)){const A=b.get(S),Z=o({feature:T,value:A,path:g});C.push({key:S,enabled:Z})}return C},[])}),ou(h));return d.add(v.subscribe(g=>c.toggleFeatures(g))),d.add(()=>u.complete()),d.add(i.navigator.listen(g=>{u.next(g.location)})),u.next(i.path),d}}})};var zE=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},Zv,VM;class wQ extends Mm{constructor(){super(...arguments),Zv.set(this,[]),VM.set(this,[])}addPlugin(e){return zE(this,Zv,"f").push(e),this}enableLocalFeatures(...e){return this.addPlugin(NM(...e))}enableUrlToggle(...e){return this.addPlugin(DM(...e))}_processConfig(e,t){const n=rt(zE(this,Zv,"f")).pipe(Jn(a=>a(t)),$e(a=>Object.keys(a).length>0),Bp((a,c)=>(a.push(c),a),[]),Ti(),Vf()),i=n.pipe(_s(a=>rt(a.sort((c,d)=>{var h,u;return((h=c.order)!==null&&h!==void 0?h:0)-((u=d.order)!==null&&u!==void 0?u:0)})).pipe($e(c=>!!c.initial),_s(c=>c.initial()),Bp((c,d)=>{for(const h in d)h in c&&console.warn("FeatureFlagConfigurator",`duplicate entry of ${h}`);return c.push(...d),c},[]))));return pv({initial:i,plugins:n}).pipe(me(a=>Object.assign(Object.assign({},e),a)))}}Zv=new WeakMap,VM=new WeakMap;const Lg={setFeatures:on("set_features_enabled",r=>({payload:r})),toggleFeatures:on("toggle_features_enabled",r=>({payload:r}))},xQ=r=>Hm(r,e=>{e.addCase(Lg.setFeatures,(t,n)=>{for(const i of n.payload)t.features[i.key]=i}),e.addCase(Lg.toggleFeatures,(t,n)=>{const i=n.payload.filter(o=>o.key in t.features);for(const o of i){const{key:a}=o;t.features[a].enabled=!!o.enabled}})}),CQ={features:{}},kQ=r=>new Lm(xQ(r??CQ)),EQ=r=>r.reduce((e,t)=>Object.assign(e,{[t.key]:t}),{});var g_=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})},Wo=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},BE=function(r,e,t,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?r!==e||!i:!e.has(r))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(r,t):i?i.value=t:e.set(r,t),t},ul,hl,Lv;class SQ{get features(){return Wo(this,hl,"f").value.features}get features$(){return Wo(this,hl,"f").pipe(me(e=>e.features))}constructor(e){ul.set(this,new ti),hl.set(this,void 0),Lv.set(this,void 0);const{config:t,event:n}=e;BE(this,Lv,n,"f"),BE(this,hl,kQ({features:EQ(t.initial)}),"f");for(const i of Object.values(t.plugins))i.connect&&Wo(this,ul,"f").add(i.connect({provider:this}));n&&this.onFeatureToggle(({features:i})=>n.dispatchEvent("onFeatureFlagsToggled",{detail:{features:i}}))}hasFeature(e){return e in this.features}setFeatures(e){Wo(this,hl,"f").next(Lg.setFeatures(e))}onFeatureToggle(e){const t=this.features$.pipe(ig(),me(([n,i])=>Object.values(i).filter(o=>{var a;return o.enabled!==((a=n[o.key])===null||a===void 0?void 0:a.enabled)})),me(n=>({features:n}))).subscribe(e);return Wo(this,ul,"f").add(t),()=>Wo(this,ul,"f").remove(t)}toggleFeature(e){return g_(this,void 0,void 0,function*(){return this.toggleFeatures([e])})}toggleFeatures(e){return g_(this,void 0,void 0,function*(){const{features:t}=Wo(this,hl,"f").value,n=rt(e).pipe(Wt(i=>g_(this,void 0,void 0,function*(){var o;const a=t[i.key];if(a){if(a.readonly){console.warn(`skipped toggling flag [${a.key}], since readonly!`);return}}else{console.warn(`toggling flag [${i.key}] which is not registered`);return}const c=yield(o=Wo(this,Lv,"f"))===null||o===void 0?void 0:o.dispatchEvent("onFeatureFlagToggle",{source:this,detail:{feature:a,enable:i.enabled},cancelable:!0});if(c!=null&&c.canceled)console.debug(`skipped toggling flag [${a.key}], since aborted!`);else return i})),$e(i=>!!i),Bp((i,o)=>i.concat([o]),[]),ng(()=>{Wo(this,ul,"f").remove(n)})).subscribe(i=>{Wo(this,hl,"f").next(Lg.toggleFeatures(i))});Wo(this,ul,"f").add(n)})}getFeature(e){return this.features[e]}getFeatures(e){return Object.values(this.features).filter(e)}dispose(){Wo(this,ul,"f").unsubscribe()}}ul=new WeakMap,hl=new WeakMap,Lv=new WeakMap;var FM=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};const TQ="featureFlag",AQ={name:TQ,configure:()=>new wQ,initialize:r=>FM(void 0,void 0,void 0,function*(){const e=yield r.config.createConfigAsync(r),t=r.hasModule("event")?yield r.requireInstance("event"):void 0;return new SQ({config:e,event:t})})},IQ=(r,e)=>{r.addConfig({module:AQ,configure:t=>FM(void 0,void 0,void 0,function*(){if(e)return Promise.resolve(e(t))})})},RQ=async r=>{r.configureServiceDiscovery({client:{baseUri:"https://discovery.fusion.equinor.com/service-registry/environments/ci/services",defaultScopes:["5a842df8-3238-415d-b168-9f16a6a6031b/.default"]}}),r.configureHttpClient("app",{baseUri:new URL("/apps-proxy/",window.location.href).href,defaultScopes:["5a842df8-3238-415d-b168-9f16a6a6031b/.default"]}),r.configureMsal(e=>{e.setClientConfig({clientId:"9b707e3a-3e90-41ed-a47e-652a1e3b53d0",tenantId:"3aa4a235-b6e2-48d5-9195-7fcf05b459b0",redirectUri:"/authentication/login-callback"}),e.setRequiresAuth(!0)}),PK(r),pQ(r),IU(r),lY(r,e=>{e.setSourceSystem({subSystem:"CLI",identifier:"fusion-cli",name:"Fusion CLI"})}),IQ(r,e=>{e.addPlugin(NM([{key:"fusionDebug",title:"Fusion debug log",description:"Show Fusion debug log in console"},{key:"pinkBg",title:"Use pink bg?",description:"When enabled the background should be pink"}])),e.addPlugin(DM(["fusionDebug"]))}),r.onConfigured(()=>{console.log("framework config done")}),r.onInitialized(async()=>{console.debug("📒 subscribing to all events")})},PQ="bookmarkId",MQ=r=>{const{event:e,context:t,navigation:{navigator:n}}=Ll().modules;x.useLayoutEffect(()=>e.addEventListener("onBookmarkChanged",o=>{var a;const{appKey:c,context:d}=o.detail,h=r.resolveAppPath(c);if(n.location.pathname!==h){const{hash:u,search:p}=n.location,v={pathname:h,search:$Q(p),hash:u};n.push(v)}d&&((a=t.currentContext)===null||a===void 0?void 0:a.id)!==d.id&&t.setCurrentContextByIdAsync(d.id)}),[r,t,e,n])};function $Q(r){const e=new URLSearchParams(r);return e.delete(PQ),`?${e.toString()}`}var Du=JI();const OQ=Hu(Du),ZQ=XI({__proto__:null,default:OQ},[Du]);/**
419
+ `},""):String(n.body);return{path:t,submission:{formMethod:a,formAction:c,formEncType:n.formEncType,formData:void 0,json:void 0,text:v}}}else if(n.formEncType==="application/json"){if(!Ia(a))return i();try{let v=typeof n.body=="string"?JSON.parse(n.body):n.body;return{path:t,submission:{formMethod:a,formAction:c,formEncType:n.formEncType,formData:void 0,json:v,text:void 0}}}catch{return i()}}}Pr(typeof FormData=="function","FormData is not available in this environment");let d,h;if(n.formData)d=pw(n.formData),h=n.formData;else if(n.body instanceof FormData)d=pw(n.body),h=n.body;else if(n.body instanceof URLSearchParams)d=n.body,h=RE(d);else if(n.body==null)d=new URLSearchParams,h=new FormData;else try{d=new URLSearchParams(n.body),h=RE(d)}catch{return i()}let u={formMethod:a,formAction:c,formEncType:n&&n.formEncType||"application/x-www-form-urlencoded",formData:h,json:void 0,text:void 0};if(Ia(u.formMethod))return{path:t,submission:u};let p=Cc(t);return e&&p.search&&l8(p.search)&&d.append("index",""),p.search="?"+d,{path:Nu(p),submission:u}}function EE(r,e,t){t===void 0&&(t=!1);let n=r.findIndex(i=>i.route.id===e);return n>=0?r.slice(0,t?n+1:n):r}function SE(r,e,t,n,i,o,a,c,d,h,u,p,v,g,_,b){let C=b?wo(b[1])?b[1].error:b[1].data:void 0,T=r.createURL(e.location),S=r.createURL(i),A=t;o&&e.errors?A=EE(t,Object.keys(e.errors)[0],!0):b&&wo(b[1])&&(A=EE(t,b[0]));let Z=b?b[1].statusCode:void 0,B=a&&Z&&Z>=400,U=A.filter((Y,le)=>{let{route:de}=Y;if(de.lazy)return!0;if(de.loader==null)return!1;if(o)return fw(de,e.loaderData,e.errors);if(qY(e.loaderData,e.matches[le],Y)||d.some(Ce=>Ce===Y.route.id))return!0;let Ee=e.matches[le],we=Y;return TE(Y,Ur({currentUrl:T,currentParams:Ee.params,nextUrl:S,nextParams:we.params},n,{actionResult:C,actionStatus:Z,defaultShouldRevalidate:B?!1:c||T.pathname+T.search===S.pathname+S.search||T.search!==S.search||PM(Ee,we)}))}),I=[];return p.forEach((Y,le)=>{if(o||!t.some(J=>J.route.id===Y.routeId)||u.has(le))return;let de=Vh(g,Y.path,_);if(!de){I.push({key:le,routeId:Y.routeId,path:Y.path,matches:null,match:null,controller:null});return}let Ee=e.fetchers.get(le),we=bp(de,Y.path),Ce=!1;v.has(le)?Ce=!1:h.has(le)?(h.delete(le),Ce=!0):Ee&&Ee.state!=="idle"&&Ee.data===void 0?Ce=c:Ce=TE(we,Ur({currentUrl:T,currentParams:e.matches[e.matches.length-1].params,nextUrl:S,nextParams:t[t.length-1].params},n,{actionResult:C,actionStatus:Z,defaultShouldRevalidate:B?!1:c})),Ce&&I.push({key:le,routeId:Y.routeId,path:Y.path,matches:de,match:we,controller:new AbortController})}),[U,I]}function fw(r,e,t){if(r.lazy)return!0;if(!r.loader)return!1;let n=e!=null&&e[r.id]!==void 0,i=t!=null&&t[r.id]!==void 0;return!n&&i?!1:typeof r.loader=="function"&&r.loader.hydrate===!0?!0:!n&&!i}function qY(r,e,t){let n=!e||t.route.id!==e.route.id,i=r[t.route.id]===void 0;return n||i}function PM(r,e){let t=r.route.path;return r.pathname!==e.pathname||t!=null&&t.endsWith("*")&&r.params["*"]!==e.params["*"]}function TE(r,e){if(r.route.shouldRevalidate){let t=r.route.shouldRevalidate(e);if(typeof t=="boolean")return t}return e.defaultShouldRevalidate}function AE(r,e,t,n,i){var o;let a;if(r){let h=n[r];Pr(h,"No route found to patch children into: routeId = "+r),h.children||(h.children=[]),a=h.children}else a=t;let c=e.filter(h=>!a.some(u=>MM(h,u))),d=Og(c,i,[r||"_","patch",String(((o=a)==null?void 0:o.length)||"0")],n);a.push(...d)}function MM(r,e){return"id"in r&&"id"in e&&r.id===e.id?!0:r.index===e.index&&r.path===e.path&&r.caseSensitive===e.caseSensitive?(!r.children||r.children.length===0)&&(!e.children||e.children.length===0)?!0:r.children.every((t,n)=>{var i;return(i=e.children)==null?void 0:i.some(o=>MM(t,o))}):!1}async function WY(r,e,t){if(!r.lazy)return;let n=await r.lazy();if(!r.lazy)return;let i=t[r.id];Pr(i,"No route found in manifest");let o={};for(let a in n){let d=i[a]!==void 0&&a!=="hasErrorBoundary";$l(!d,'Route "'+i.id+'" has a static property "'+a+'" defined but its lazy function is also returning a value for this property. '+('The lazy route property "'+a+'" will be ignored.')),!d&&!mY.has(a)&&(o[a]=n[a])}Object.assign(i,o),Object.assign(i,Ur({},e(i),{lazy:void 0}))}async function GY(r){let{matches:e}=r,t=e.filter(i=>i.shouldLoad);return(await Promise.all(t.map(i=>i.resolve()))).reduce((i,o,a)=>Object.assign(i,{[t[a].route.id]:o}),{})}async function KY(r,e,t,n,i,o,a,c,d,h){let u=o.map(g=>g.route.lazy?WY(g.route,d,c):void 0),p=o.map((g,_)=>{let b=u[_],C=i.some(S=>S.route.id===g.route.id);return Ur({},g,{shouldLoad:C,resolve:async S=>(S&&n.method==="GET"&&(g.route.lazy||g.route.loader)&&(C=!0),C?YY(e,n,g,b,S,h):Promise.resolve({type:_r.data,result:void 0}))})}),v=await r({matches:p,request:n,params:o[0].params,fetcherKey:a,context:h});try{await Promise.all(u)}catch{}return v}async function YY(r,e,t,n,i,o){let a,c,d=h=>{let u,p=new Promise((_,b)=>u=b);c=()=>u(),e.signal.addEventListener("abort",c);let v=_=>typeof h!="function"?Promise.reject(new Error("You cannot call the handler for a route which defines a boolean "+('"'+r+'" [routeId: '+t.route.id+"]"))):h({request:e,params:t.params,context:o},..._!==void 0?[_]:[]),g=(async()=>{try{return{type:"data",result:await(i?i(b=>v(b)):v())}}catch(_){return{type:"error",result:_}}})();return Promise.race([g,p])};try{let h=t.route[r];if(n)if(h){let u,[p]=await Promise.all([d(h).catch(v=>{u=v}),n]);if(u!==void 0)throw u;a=p}else if(await n,h=t.route[r],h)a=await d(h);else if(r==="action"){let u=new URL(e.url),p=u.pathname+u.search;throw no(405,{method:e.method,pathname:p,routeId:t.route.id})}else return{type:_r.data,result:void 0};else if(h)a=await d(h);else{let u=new URL(e.url),p=u.pathname+u.search;throw no(404,{pathname:p})}Pr(a.result!==void 0,"You defined "+(r==="action"?"an action":"a loader")+" for route "+('"'+t.route.id+"\" but didn't return anything from your `"+r+"` ")+"function. Please return a value or `null`.")}catch(h){return{type:_r.error,result:h}}finally{c&&e.signal.removeEventListener("abort",c)}return a}async function QY(r){let{result:e,type:t}=r;if(OM(e)){let p;try{let v=e.headers.get("Content-Type");v&&/\bapplication\/json\b/.test(v)?e.body==null?p=null:p=await e.json():p=await e.text()}catch(v){return{type:_r.error,error:v}}return t===_r.error?{type:_r.error,error:new uw(e.status,e.statusText,p),statusCode:e.status,headers:e.headers}:{type:_r.data,data:p,statusCode:e.status,headers:e.headers}}if(t===_r.error){if(ZE(e)){var n,i;if(e.data instanceof Error){var o,a;return{type:_r.error,error:e.data,statusCode:(o=e.init)==null?void 0:o.status,headers:(a=e.init)!=null&&a.headers?new Headers(e.init.headers):void 0}}return{type:_r.error,error:new uw(((n=e.init)==null?void 0:n.status)||500,void 0,e.data),statusCode:Zg(e)?e.status:void 0,headers:(i=e.init)!=null&&i.headers?new Headers(e.init.headers):void 0}}return{type:_r.error,error:e,statusCode:Zg(e)?e.status:void 0}}if(rQ(e)){var c,d;return{type:_r.deferred,deferredData:e,statusCode:(c=e.init)==null?void 0:c.status,headers:((d=e.init)==null?void 0:d.headers)&&new Headers(e.init.headers)}}if(ZE(e)){var h,u;return{type:_r.data,data:e.data,statusCode:(h=e.init)==null?void 0:h.status,headers:(u=e.init)!=null&&u.headers?new Headers(e.init.headers):void 0}}return{type:_r.data,data:e}}function XY(r,e,t,n,i,o){let a=r.headers.get("Location");if(Pr(a,"Redirects returned/thrown from loaders/actions must have a Location header"),!s8.test(a)){let c=n.slice(0,n.findIndex(d=>d.route.id===t)+1);a=hw(new URL(e.url),c,i,!0,a,o),r.headers.set("Location",a)}return r}function IE(r,e,t){if(s8.test(r)){let n=r,i=n.startsWith("//")?new URL(e.protocol+n):new URL(n),o=C4(i.pathname,t)!=null;if(i.origin===e.origin&&o)return i.pathname+i.search+i.hash}return r}function Th(r,e,t,n){let i=r.createURL($M(e)).toString(),o={signal:t};if(n&&Ia(n.formMethod)){let{formMethod:a,formEncType:c}=n;o.method=a.toUpperCase(),c==="application/json"?(o.headers=new Headers({"Content-Type":c}),o.body=JSON.stringify(n.json)):c==="text/plain"?o.body=n.text:c==="application/x-www-form-urlencoded"&&n.formData?o.body=pw(n.formData):o.body=n.formData}return new Request(i,o)}function pw(r){let e=new URLSearchParams;for(let[t,n]of r.entries())e.append(t,typeof n=="string"?n:n.name);return e}function RE(r){let e=new FormData;for(let[t,n]of r.entries())e.append(t,n);return e}function JY(r,e,t,n,i){let o={},a=null,c,d=!1,h={},u=t&&wo(t[1])?t[1].error:void 0;return r.forEach(p=>{if(!(p.route.id in e))return;let v=p.route.id,g=e[v];if(Pr(!Wd(g),"Cannot handle redirect results in processLoaderData"),wo(g)){let _=g.error;u!==void 0&&(_=u,u=void 0),a=a||{};{let b=Bd(r,v);a[b.route.id]==null&&(a[b.route.id]=_)}o[v]=void 0,d||(d=!0,c=Zg(g.error)?g.error.status:500),g.headers&&(h[v]=g.headers)}else wl(g)?(n.set(v,g.deferredData),o[v]=g.deferredData.data,g.statusCode!=null&&g.statusCode!==200&&!d&&(c=g.statusCode),g.headers&&(h[v]=g.headers)):(o[v]=g.data,g.statusCode&&g.statusCode!==200&&!d&&(c=g.statusCode),g.headers&&(h[v]=g.headers))}),u!==void 0&&t&&(a={[t[0]]:u},o[t[0]]=void 0),{loaderData:o,errors:a,statusCode:c||200,loaderHeaders:h}}function PE(r,e,t,n,i,o,a){let{loaderData:c,errors:d}=JY(e,t,n,a);return i.forEach(h=>{let{key:u,match:p,controller:v}=h,g=o[u];if(Pr(g,"Did not find corresponding fetcher result"),!(v&&v.signal.aborted))if(wo(g)){let _=Bd(r.matches,p==null?void 0:p.route.id);d&&d[_.route.id]||(d=Ur({},d,{[_.route.id]:g.error})),r.fetchers.delete(u)}else if(Wd(g))Pr(!1,"Unhandled fetcher revalidation redirect");else if(wl(g))Pr(!1,"Unhandled fetcher deferred data");else{let _=dl(g.data);r.fetchers.set(u,_)}}),{loaderData:c,errors:d}}function ME(r,e,t,n){let i=Ur({},e);for(let o of t){let a=o.route.id;if(e.hasOwnProperty(a)?e[a]!==void 0&&(i[a]=e[a]):r[a]!==void 0&&o.route.loader&&(i[a]=r[a]),n&&n.hasOwnProperty(a))break}return i}function $E(r){return r?wo(r[1])?{actionData:{}}:{actionData:{[r[0]]:r[1].data}}:{}}function Bd(r,e){return(e?r.slice(0,r.findIndex(n=>n.route.id===e)+1):[...r]).reverse().find(n=>n.route.hasErrorBoundary===!0)||r[0]}function OE(r){let e=r.length===1?r[0]:r.find(t=>t.index||!t.path||t.path==="/")||{id:"__shim-error-route__"};return{matches:[{params:{},pathname:"",pathnameBase:"",route:e}],route:e}}function no(r,e){let{pathname:t,routeId:n,method:i,type:o,message:a}=e===void 0?{}:e,c="Unknown Server Error",d="Unknown @remix-run/router error";return r===400?(c="Bad Request",i&&t&&n?d="You made a "+i+' request to "'+t+'" but '+('did not provide a `loader` for route "'+n+'", ')+"so there is no way to handle the request.":o==="defer-action"?d="defer() is not supported in actions":o==="invalid-body"&&(d="Unable to encode submission body")):r===403?(c="Forbidden",d='Route "'+n+'" does not match URL "'+t+'"'):r===404?(c="Not Found",d='No route matches URL "'+t+'"'):r===405&&(c="Method Not Allowed",i&&t&&n?d="You made a "+i.toUpperCase()+' request to "'+t+'" but '+('did not provide an `action` for route "'+n+'", ')+"so there is no way to handle the request.":i&&(d='Invalid request method "'+i.toUpperCase()+'"')),new uw(r||500,c,new Error(d),!0)}function L0(r){let e=Object.entries(r);for(let t=e.length-1;t>=0;t--){let[n,i]=e[t];if(Wd(i))return{key:n,result:i}}}function $M(r){let e=typeof r=="string"?Cc(r):r;return Nu(Ur({},e,{hash:""}))}function eQ(r,e){return r.pathname!==e.pathname||r.search!==e.search?!1:r.hash===""?e.hash!=="":r.hash===e.hash?!0:e.hash!==""}function tQ(r){return OM(r.result)&&VY.has(r.result.status)}function wl(r){return r.type===_r.deferred}function wo(r){return r.type===_r.error}function Wd(r){return(r&&r.type)===_r.redirect}function ZE(r){return typeof r=="object"&&r!=null&&"type"in r&&"data"in r&&"init"in r&&r.type==="DataWithResponseInit"}function rQ(r){let e=r;return e&&typeof e=="object"&&typeof e.data=="object"&&typeof e.subscribe=="function"&&typeof e.cancel=="function"&&typeof e.resolveData=="function"}function OM(r){return r!=null&&typeof r.status=="number"&&typeof r.statusText=="string"&&typeof r.headers=="object"&&typeof r.body<"u"}function nQ(r){return DY.has(r.toLowerCase())}function Ia(r){return HY.has(r.toLowerCase())}async function iQ(r,e,t,n,i){let o=Object.entries(e);for(let a=0;a<o.length;a++){let[c,d]=o[a],h=r.find(v=>(v==null?void 0:v.route.id)===c);if(!h)continue;let u=n.find(v=>v.route.id===h.route.id),p=u!=null&&!PM(u,h)&&(i&&i[h.route.id])!==void 0;wl(d)&&p&&await c8(d,t,!1).then(v=>{v&&(e[c]=v)})}}async function oQ(r,e,t){for(let n=0;n<t.length;n++){let{key:i,routeId:o,controller:a}=t[n],c=e[i];r.find(h=>(h==null?void 0:h.route.id)===o)&&wl(c)&&(Pr(a,"Expected an AbortController for revalidating fetcher deferred result"),await c8(c,a.signal,!0).then(h=>{h&&(e[i]=h)}))}}async function c8(r,e,t){if(t===void 0&&(t=!1),!await r.deferredData.resolveData(e)){if(t)try{return{type:_r.data,data:r.deferredData.unwrappedData}}catch(i){return{type:_r.error,error:i}}return{type:_r.data,data:r.deferredData.data}}}function l8(r){return new URLSearchParams(r).getAll("index").some(e=>e==="")}function bp(r,e){let t=typeof e=="string"?Cc(e).search:e.search;if(r[r.length-1].route.index&&l8(t||""))return r[r.length-1];let n=AM(r);return n[n.length-1]}function LE(r){let{formMethod:e,formAction:t,formEncType:n,text:i,formData:o,json:a}=r;if(!(!e||!t||!n)){if(i!=null)return{formMethod:e,formAction:t,formEncType:n,formData:void 0,json:void 0,text:i};if(o!=null)return{formMethod:e,formAction:t,formEncType:n,formData:o,json:void 0,text:void 0};if(a!==void 0)return{formMethod:e,formAction:t,formEncType:n,formData:void 0,json:a,text:void 0}}}function v_(r,e){return e?{state:"loading",location:r,formMethod:e.formMethod,formAction:e.formAction,formEncType:e.formEncType,formData:e.formData,json:e.json,text:e.text}:{state:"loading",location:r,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0}}function aQ(r,e){return{state:"submitting",location:r,formMethod:e.formMethod,formAction:e.formAction,formEncType:e.formEncType,formData:e.formData,json:e.json,text:e.text}}function q1(r,e){return r?{state:"loading",formMethod:r.formMethod,formAction:r.formAction,formEncType:r.formEncType,formData:r.formData,json:r.json,text:r.text,data:e}:{state:"loading",formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0,data:e}}function sQ(r,e){return{state:"submitting",formMethod:r.formMethod,formAction:r.formAction,formEncType:r.formEncType,formData:r.formData,json:r.json,text:r.text,data:e?e.data:void 0}}function dl(r){return{state:"idle",formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0,data:r}}function cQ(r,e){try{let t=r.sessionStorage.getItem(RM);if(t){let n=JSON.parse(t);for(let[i,o]of Object.entries(n||{}))o&&Array.isArray(o)&&e.set(i,new Set(o||[]))}}catch{}}function lQ(r,e){if(e.size>0){let t={};for(let[n,i]of e)t[n]=[...i];try{r.sessionStorage.setItem(RM,JSON.stringify(t))}catch(n){$l(!1,"Failed to save applied view transitions in sessionStorage ("+n+").")}}}const ZM=r=>{switch(r){case"hash":return fY({v5Compat:!0});case"memory":return uY({v5Compat:!0});case"browser":return hY({v5Compat:!0});default:return console.warn(`Unknown history type: ${r}. Using browser history as default.`),ZM("browser")}};var ln=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},H0=function(r,e,t,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?r!==e||!i:!e.has(r))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(r,t):i?i.value=t:e.set(r,t),t},Qo,$v,mw,Ov,os,wp;const HE=r=>typeof r=="object"&&"key"in r;class dQ extends Tt{get basename(){return ln(this,$v,"f")}get origin(){return ln(this,mw,"f")}get state(){return ln(this,os,"f").asObservable()}get value(){return ln(this,os,"f").value}get location(){return this.value.location}get action(){return this.value.action}constructor(e){super(i=>ln(this,os,"f").subscribe(i)),Qo.set(this,void 0),$v.set(this,void 0),mw.set(this,window.location.origin),Ov.set(this,new ti),os.set(this,void 0),wp.set(this,void 0);const{basename:t,history:n}=e;H0(this,wp,e.logger||console,"f"),H0(this,$v,t,"f"),H0(this,Qo,n,"f"),H0(this,os,new Df({action:ln(this,Qo,"f").action,location:ln(this,Qo,"f").location,delta:null}),"f"),ln(this,Ov,"f").add(ln(this,Qo,"f").listen(i=>{i.location.key!==ln(this,os,"f").value.location.key&&ln(this,os,"f").next(i)}))}encodeLocation(e){return ln(this,Qo,"f").encodeLocation(e)}listen(e){const t=ln(this,os,"f").subscribe(e);return ln(this,wp,"f").debug("Navigator::listen",e),()=>(ln(this,wp,"f").debug("Navigator::listen[unsubscribe]",e),t.unsubscribe())}createHref(e){return ln(this,Qo,"f").createHref(e)}go(e){ln(this,Qo,"f").go(e)}push(e,t){HE(e)&&this._isDuplicateLocation(e)||ln(this,Qo,"f").push(e,t)}replace(e,t){HE(e)&&this._isDuplicateLocation(e)||ln(this,Qo,"f").replace(e,t)}createURL(e){return ln(this,Qo,"f").createURL(e)}_isDuplicateLocation(e){return e.key===ln(this,os,"f").value.location.key}dispose(){ln(this,Ov,"f").unsubscribe()}}Qo=new WeakMap,$v=new WeakMap,mw=new WeakMap,Ov=new WeakMap,os=new WeakMap,wp=new WeakMap;var qo=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},NE=function(r,e,t,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?r!==e||!i:!e.has(r))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(r,t):i?i.value=t:e.set(r,t),t},Aa,Ld;const DE=r=>r.replace(/\/+/g,"/");class uQ extends OR{get state$(){return qo(this,Aa,"f").pipe($e(e=>qo(this,Ld,"f")?e.location.pathname.startsWith(qo(this,Ld,"f")):!0),me(({action:e,location:t})=>({action:e,location:this._localizePath(t)})))}get navigator(){return qo(this,Aa,"f")}get path(){return this._localizePath(this.navigator.location)}constructor(e){super(e),Aa.set(this,void 0),Ld.set(this,void 0);const{basename:t,history:n}=e.config;if(NE(this,Ld,t,"f"),!n)throw Error("no history provided!");NE(this,Aa,new dQ({basename:t,history:n}),"f"),this._addTeardown(()=>qo(this,Aa,"f").dispose())}createRouter(e){const t=qo(this,Aa,"f");console.debug("NavigationProvider::createRouter",e);const n=BY({basename:t.basename,history:t,routes:e,future:{v7_prependBasename:!0}});return n.initialize(),n}createHref(e){return qo(this,Aa,"f").createHref(this._createToPath(e??this.path))}createURL(e){return qo(this,Aa,"f").createURL(this._createToPath(e??this.path))}push(e,t){qo(this,Aa,"f").push(this._createToPath(e),t)}replace(e,t){qo(this,Aa,"f").replace(this._createToPath(e),t)}_localizePath(e){var t;const{pathname:n,search:i,hash:o}=e;return{pathname:DE(n.replace((t=qo(this,Ld,"f"))!==null&&t!==void 0?t:"","")),search:i,hash:o}}_createToPath(e){const{pathname:t,search:n,hash:i}=typeof e=="string"?{pathname:e,search:void 0,hash:void 0}:e;return{pathname:DE([qo(this,Ld,"f"),t==="/"?void 0:t].filter(o=>!!o).join("/")),search:n,hash:i}}}Aa=new WeakMap,Ld=new WeakMap;const VE="4.0.9",hQ="navigation",fQ={version:new fs(VE),name:hQ,configure:r=>{const e=new dY;return r!=null&&r.navigation&&(e.history=r.navigation.navigator),e},initialize:({config:r})=>{var e;return(e=r.history)!==null&&e!==void 0||(r.history=ZM()),new uQ({version:VE,config:r})},dispose({instance:r}){r.dispose()}},pQ=(r,e)=>{const t=e;r.addConfig(Object.assign({module:fQ},t))};var mQ=function(r,e,t,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?r!==e||!i:!e.has(r))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(r,t):i?i.value=t:e.set(r,t),t},W1=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},Jc;const LM="::",vQ=r=>{const[e,t]=r.split(LM);return{namespace:e,id:t}};class HM{constructor(e,t){this.namespace=e,Jc.set(this,void 0),mQ(this,Jc,t,"f")}*[(Jc=new WeakMap,Symbol.iterator)](){for(const e of Object.values(this.getItems()))yield e}generateId(e){return[this.namespace,e].join(LM)}setItem(e,t){W1(this,Jc,"f").setItem(this.generateId(e),JSON.stringify(t))}removeItem(e){W1(this,Jc,"f").removeItem(this.generateId(e))}getItem(e){const t=W1(this,Jc,"f").getItem(this.generateId(e));return t?JSON.parse(t):void 0}getItems(){return this._getItems().reduce((e,{id:t,value:n})=>Object.assign(e,{[t]:n}),{})}clear(){for(const e of this._getItems())W1(this,Jc,"f").removeItem(e.key)}_getItems(){const{namespace:e}=this;return Object.entries(W1(this,Jc,"f")).map(([t,n])=>Object.assign(Object.assign({},vQ(t)),{key:t,value:n})).filter(t=>t.namespace===e).map(t=>Object.assign(t,{value:JSON.parse(t.value)}))}}class gQ extends HM{constructor(e){super(e,window.localStorage)}}class yQ extends HM{constructor(e){super(e,window.sessionStorage)}}const _Q=(r,e)=>{switch(e){case"local":return new gQ(r);case"session":return new yQ(r)}throw Error("invalid type provided")};var FE=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};const NM=(r,e)=>()=>FE(void 0,void 0,void 0,function*(){const{name:t,type:n="local"}=e??{},i=["FEATURES",t].filter(a=>!!a).join("_"),o=_Q(i,n);return{connect:({provider:a})=>a.onFeatureToggle(({features:c})=>{c.map(d=>o.setItem(d.key,d))}),initial:()=>FE(void 0,void 0,void 0,function*(){const a=yield o.getItems();return r.map(c=>{const d=a[c.key];return Object.assign(Object.assign({},c),{enabled:d?d.enabled:c.enabled})})})}}),bQ=r=>!(r.value==="0"||r.value==="false");var jE=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};const DM=(r,e)=>{if(!r.length)return()=>Promise.resolve({});const t=r.map(n=>typeof n=="string"?n:n.key);return n=>jE(void 0,void 0,void 0,function*(){if(!n.hasModule("navigation"))throw Error("missing navigation module");const i=yield n.requireInstance("navigation"),{isFeatureEnabled:o=bQ}=e??{};return{order:-1,initial:()=>jE(void 0,void 0,void 0,function*(){return r.filter(a=>typeof a!="string")}),connect(a){const{provider:c}=a,d=new ti,h=new Bn,u=new Bn,p=c.features$.pipe(me(g=>Object.values(g)),me(g=>g.filter(_=>t.includes(_.key)))),v=u.pipe(Up(p),me(([g,_])=>{const b=new URLSearchParams(g.search);return _.reduce((C,T)=>{const{key:S}=T;if(b.has(S)){const A=b.get(S),Z=o({feature:T,value:A,path:g});C.push({key:S,enabled:Z})}return C},[])}),ou(h));return d.add(v.subscribe(g=>c.toggleFeatures(g))),d.add(()=>u.complete()),d.add(i.navigator.listen(g=>{u.next(g.location)})),u.next(i.path),d}}})};var zE=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},Zv,VM;class wQ extends Mm{constructor(){super(...arguments),Zv.set(this,[]),VM.set(this,[])}addPlugin(e){return zE(this,Zv,"f").push(e),this}enableLocalFeatures(...e){return this.addPlugin(NM(...e))}enableUrlToggle(...e){return this.addPlugin(DM(...e))}_processConfig(e,t){const n=rt(zE(this,Zv,"f")).pipe(Jn(a=>a(t)),$e(a=>Object.keys(a).length>0),Bp((a,c)=>(a.push(c),a),[]),Ti(),Vf()),i=n.pipe(_s(a=>rt(a.sort((c,d)=>{var h,u;return((h=c.order)!==null&&h!==void 0?h:0)-((u=d.order)!==null&&u!==void 0?u:0)})).pipe($e(c=>!!c.initial),_s(c=>c.initial()),Bp((c,d)=>{for(const h in d)h in c&&console.warn("FeatureFlagConfigurator",`duplicate entry of ${h}`);return c.push(...d),c},[]))));return pv({initial:i,plugins:n}).pipe(me(a=>Object.assign(Object.assign({},e),a)))}}Zv=new WeakMap,VM=new WeakMap;const Lg={setFeatures:on("set_features_enabled",r=>({payload:r})),toggleFeatures:on("toggle_features_enabled",r=>({payload:r}))},xQ=r=>Hm(r,e=>{e.addCase(Lg.setFeatures,(t,n)=>{for(const i of n.payload)t.features[i.key]=i}),e.addCase(Lg.toggleFeatures,(t,n)=>{const i=n.payload.filter(o=>o.key in t.features);for(const o of i){const{key:a}=o;t.features[a].enabled=!!o.enabled}})}),CQ={features:{}},kQ=r=>new Lm(xQ(r??CQ)),EQ=r=>r.reduce((e,t)=>Object.assign(e,{[t.key]:t}),{});var g_=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})},Wo=function(r,e,t,n){if(t==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?r!==e||!n:!e.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?n:t==="a"?n.call(r):n?n.value:e.get(r)},BE=function(r,e,t,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?r!==e||!i:!e.has(r))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(r,t):i?i.value=t:e.set(r,t),t},ul,hl,Lv;class SQ{get features(){return Wo(this,hl,"f").value.features}get features$(){return Wo(this,hl,"f").pipe(me(e=>e.features))}constructor(e){ul.set(this,new ti),hl.set(this,void 0),Lv.set(this,void 0);const{config:t,event:n}=e;BE(this,Lv,n,"f"),BE(this,hl,kQ({features:EQ(t.initial)}),"f");for(const i of Object.values(t.plugins))i.connect&&Wo(this,ul,"f").add(i.connect({provider:this}));n&&this.onFeatureToggle(({features:i})=>n.dispatchEvent("onFeatureFlagsToggled",{detail:{features:i}}))}hasFeature(e){return e in this.features}setFeatures(e){Wo(this,hl,"f").next(Lg.setFeatures(e))}onFeatureToggle(e){const t=this.features$.pipe(ig(),me(([n,i])=>Object.values(i).filter(o=>{var a;return o.enabled!==((a=n[o.key])===null||a===void 0?void 0:a.enabled)})),me(n=>({features:n}))).subscribe(e);return Wo(this,ul,"f").add(t),()=>Wo(this,ul,"f").remove(t)}toggleFeature(e){return g_(this,void 0,void 0,function*(){return this.toggleFeatures([e])})}toggleFeatures(e){return g_(this,void 0,void 0,function*(){const{features:t}=Wo(this,hl,"f").value,n=rt(e).pipe(Wt(i=>g_(this,void 0,void 0,function*(){var o;const a=t[i.key];if(a){if(a.readonly){console.warn(`skipped toggling flag [${a.key}], since readonly!`);return}}else{console.warn(`toggling flag [${i.key}] which is not registered`);return}const c=yield(o=Wo(this,Lv,"f"))===null||o===void 0?void 0:o.dispatchEvent("onFeatureFlagToggle",{source:this,detail:{feature:a,enable:i.enabled},cancelable:!0});if(c!=null&&c.canceled)console.debug(`skipped toggling flag [${a.key}], since aborted!`);else return i})),$e(i=>!!i),Bp((i,o)=>i.concat([o]),[]),ng(()=>{Wo(this,ul,"f").remove(n)})).subscribe(i=>{Wo(this,hl,"f").next(Lg.toggleFeatures(i))});Wo(this,ul,"f").add(n)})}getFeature(e){return this.features[e]}getFeatures(e){return Object.values(this.features).filter(e)}dispose(){Wo(this,ul,"f").unsubscribe()}}ul=new WeakMap,hl=new WeakMap,Lv=new WeakMap;var FM=function(r,e,t,n){function i(o){return o instanceof t?o:new t(function(a){a(o)})}return new(t||(t=Promise))(function(o,a){function c(u){try{h(n.next(u))}catch(p){a(p)}}function d(u){try{h(n.throw(u))}catch(p){a(p)}}function h(u){u.done?o(u.value):i(u.value).then(c,d)}h((n=n.apply(r,e||[])).next())})};const TQ="featureFlag",AQ={name:TQ,configure:()=>new wQ,initialize:r=>FM(void 0,void 0,void 0,function*(){const e=yield r.config.createConfigAsync(r),t=r.hasModule("event")?yield r.requireInstance("event"):void 0;return new SQ({config:e,event:t})})},IQ=(r,e)=>{r.addConfig({module:AQ,configure:t=>FM(void 0,void 0,void 0,function*(){if(e)return Promise.resolve(e(t))})})},RQ=async r=>{r.configureServiceDiscovery({client:{baseUri:"https://discovery.fusion.equinor.com/service-registry/environments/ci/services",defaultScopes:["5a842df8-3238-415d-b168-9f16a6a6031b/.default"]}}),r.configureHttpClient("app",{baseUri:new URL("/apps-proxy/",window.location.href).href,defaultScopes:["5a842df8-3238-415d-b168-9f16a6a6031b/.default"]}),r.configureMsal(e=>{e.setClientConfig({clientId:"9b707e3a-3e90-41ed-a47e-652a1e3b53d0",tenantId:"3aa4a235-b6e2-48d5-9195-7fcf05b459b0",redirectUri:"/authentication/login-callback"}),e.setRequiresAuth(!0)}),PK(r),pQ(r),IU(r),lY(r,e=>{e.setSourceSystem({subSystem:"CLI",identifier:"fusion-cli",name:"Fusion CLI"})}),IQ(r,e=>{e.addPlugin(NM([{key:"fusionDebug",title:"Fusion debug log",description:"Show Fusion debug log in console"},{key:"pinkBg",title:"Use pink bg?",description:"When enabled the background should be pink"}])),e.addPlugin(DM(["fusionDebug"]))}),r.onConfigured(()=>{console.log("framework config done")}),r.onInitialized(async e=>{console.debug("📒 subscribing to all events");try{await e.http.createClient({defaultScopes:["5a842df8-3238-415d-b168-9f16a6a6031b/.default"]}).fetch("/help-proxy",{method:"OPTIONS"})}catch(t){console.error("Could not call help-proxy OPTIONS call to aquire an access token",t.message)}})},PQ="bookmarkId",MQ=r=>{const{event:e,context:t,navigation:{navigator:n}}=Ll().modules;x.useLayoutEffect(()=>e.addEventListener("onBookmarkChanged",o=>{var a;const{appKey:c,context:d}=o.detail,h=r.resolveAppPath(c);if(n.location.pathname!==h){const{hash:u,search:p}=n.location,v={pathname:h,search:$Q(p),hash:u};n.push(v)}d&&((a=t.currentContext)===null||a===void 0?void 0:a.id)!==d.id&&t.setCurrentContextByIdAsync(d.id)}),[r,t,e,n])};function $Q(r){const e=new URLSearchParams(r);return e.delete(PQ),`?${e.toString()}`}var Du=JI();const OQ=Hu(Du),ZQ=XI({__proto__:null,default:OQ},[Du]);/**
420
420
  * @remix-run/router v1.18.0
421
421
  *
422
422
  * Copyright (c) Remix Software Inc.
@@ -443,7 +443,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
443
443
  * LICENSE.md file in the root directory of this source tree.
444
444
  *
445
445
  * @license MIT
446
- */const gX="6";try{window.__reactRouterVersion=gX}catch{}const yX=x.createContext({isTransitioning:!1}),_X=x.createContext(new Map),bX="startTransition",GE=Y6[bX],wX="flushSync",KE=ZQ[wX];function xX(r){GE?GE(r):r()}function G1(r){KE?KE(r):r()}class CX{constructor(){this.status="pending",this.promise=new Promise((e,t)=>{this.resolve=n=>{this.status==="pending"&&(this.status="resolved",e(n))},this.reject=n=>{this.status==="pending"&&(this.status="rejected",t(n))}})}}function kX(r){let{fallbackElement:e,router:t,future:n}=r,[i,o]=x.useState(t.state),[a,c]=x.useState(),[d,h]=x.useState({isTransitioning:!1}),[u,p]=x.useState(),[v,g]=x.useState(),[_,b]=x.useState(),C=x.useRef(new Map),{v7_startTransition:T}=n||{},S=x.useCallback(Y=>{T?xX(Y):Y()},[T]),A=x.useCallback((Y,le)=>{let{deletedFetchers:de,unstable_flushSync:Ee,unstable_viewTransitionOpts:we}=le;de.forEach(J=>C.current.delete(J)),Y.fetchers.forEach((J,K)=>{J.data!==void 0&&C.current.set(K,J.data)});let Ce=t.window==null||t.window.document==null||typeof t.window.document.startViewTransition!="function";if(!we||Ce){Ee?G1(()=>o(Y)):S(()=>o(Y));return}if(Ee){G1(()=>{v&&(u&&u.resolve(),v.skipTransition()),h({isTransitioning:!0,flushSync:!0,currentLocation:we.currentLocation,nextLocation:we.nextLocation})});let J=t.window.document.startViewTransition(()=>{G1(()=>o(Y))});J.finished.finally(()=>{G1(()=>{p(void 0),g(void 0),c(void 0),h({isTransitioning:!1})})}),G1(()=>g(J));return}v?(u&&u.resolve(),v.skipTransition(),b({state:Y,currentLocation:we.currentLocation,nextLocation:we.nextLocation})):(c(Y),h({isTransitioning:!0,flushSync:!1,currentLocation:we.currentLocation,nextLocation:we.nextLocation}))},[t.window,v,u,C,S]);x.useLayoutEffect(()=>t.subscribe(A),[t,A]),x.useEffect(()=>{d.isTransitioning&&!d.flushSync&&p(new CX)},[d]),x.useEffect(()=>{if(u&&a&&t.window){let Y=a,le=u.promise,de=t.window.document.startViewTransition(async()=>{S(()=>o(Y)),await le});de.finished.finally(()=>{p(void 0),g(void 0),c(void 0),h({isTransitioning:!1})}),g(de)}},[S,a,u,t.window]),x.useEffect(()=>{u&&a&&i.location.key===a.location.key&&u.resolve()},[u,v,i.location,a]),x.useEffect(()=>{!d.isTransitioning&&_&&(c(_.state),h({isTransitioning:!0,flushSync:!1,currentLocation:_.currentLocation,nextLocation:_.nextLocation}),b(void 0))},[d.isTransitioning,_]),x.useEffect(()=>{},[]);let Z=x.useMemo(()=>({createHref:t.createHref,encodeLocation:t.encodeLocation,go:Y=>t.navigate(Y),push:(Y,le,de)=>t.navigate(Y,{state:le,preventScrollReset:de==null?void 0:de.preventScrollReset}),replace:(Y,le,de)=>t.navigate(Y,{replace:!0,state:le,preventScrollReset:de==null?void 0:de.preventScrollReset})}),[t]),B=t.basename||"/",U=x.useMemo(()=>({router:t,navigator:Z,static:!1,basename:B}),[t,Z,B]),I=x.useMemo(()=>({v7_relativeSplatPath:t.future.v7_relativeSplatPath}),[t.future.v7_relativeSplatPath]);return x.createElement(x.Fragment,null,x.createElement(GM.Provider,{value:U},x.createElement(KM.Provider,{value:i},x.createElement(_X.Provider,{value:C.current},x.createElement(yX.Provider,{value:d},x.createElement(vX,{basename:B,location:i.location,navigationType:i.historyAction,navigator:Z,future:I},i.initialized||t.future.v7_partialHydration?x.createElement(EX,{routes:t.routes,future:t.future,state:i}):e))))),null)}const EX=x.memo(SX);function SX(r){let{routes:e,future:t,state:n}=r;return iX(e,void 0,n,t)}var YE;(function(r){r.UseScrollRestoration="useScrollRestoration",r.UseSubmit="useSubmit",r.UseSubmitFetcher="useSubmitFetcher",r.UseFetcher="useFetcher",r.useViewTransitionState="useViewTransitionState"})(YE||(YE={}));var QE;(function(r){r.UseFetcher="useFetcher",r.UseFetchers="useFetchers",r.UseScrollRestoration="useScrollRestoration"})(QE||(QE={}));var vr=function(){return vr=Object.assign||function(e){for(var t,n=1,i=arguments.length;n<i;n++){t=arguments[n];for(var o in t)Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o])}return e},vr.apply(this,arguments)};function bc(r,e,t){if(t||arguments.length===2)for(var n=0,i=e.length,o;n<i;n++)(o||!(n in e))&&(o||(o=Array.prototype.slice.call(e,0,n)),o[n]=e[n]);return r.concat(o||Array.prototype.slice.call(e))}var Nr="-ms-",Fp="-moz-",fr="-webkit-",JM="comm",Gm="rule",h8="decl",TX="@import",e$="@keyframes",AX="@layer",t$=Math.abs,f8=String.fromCharCode,yw=Object.assign;function IX(r,e){return jn(r,0)^45?(((e<<2^jn(r,0))<<2^jn(r,1))<<2^jn(r,2))<<2^jn(r,3):0}function r$(r){return r.trim()}function tc(r,e){return(r=e.exec(r))?r[0]:r}function Ot(r,e,t){return r.replace(e,t)}function Hv(r,e,t){return r.indexOf(e,t)}function jn(r,e){return r.charCodeAt(e)|0}function Tf(r,e,t){return r.slice(e,t)}function ds(r){return r.length}function n$(r){return r.length}function xp(r,e){return e.push(r),r}function RX(r,e){return r.map(e).join("")}function XE(r,e){return r.filter(function(t){return!tc(t,e)})}var k4=1,Af=1,i$=0,aa=0,kn=0,Uf="";function E4(r,e,t,n,i,o,a,c){return{value:r,root:e,parent:t,type:n,props:i,children:o,line:k4,column:Af,length:a,return:"",siblings:c}}function fl(r,e){return yw(E4("",null,null,"",null,null,0,r.siblings),r,{length:-r.length},e)}function Ah(r){for(;r.root;)r=fl(r.root,{children:[r]});xp(r,r.siblings)}function PX(){return kn}function MX(){return kn=aa>0?jn(Uf,--aa):0,Af--,kn===10&&(Af=1,k4--),kn}function Za(){return kn=aa<i$?jn(Uf,aa++):0,Af++,kn===10&&(Af=1,k4++),kn}function pu(){return jn(Uf,aa)}function Nv(){return aa}function S4(r,e){return Tf(Uf,r,e)}function _w(r){switch(r){case 0:case 9:case 10:case 13:case 32:return 5;case 33:case 43:case 44:case 47:case 62:case 64:case 126:case 59:case 123:case 125:return 4;case 58:return 3;case 34:case 39:case 40:case 91:return 2;case 41:case 93:return 1}return 0}function $X(r){return k4=Af=1,i$=ds(Uf=r),aa=0,[]}function OX(r){return Uf="",r}function y_(r){return r$(S4(aa-1,bw(r===91?r+2:r===40?r+1:r)))}function ZX(r){for(;(kn=pu())&&kn<33;)Za();return _w(r)>2||_w(kn)>3?"":" "}function LX(r,e){for(;--e&&Za()&&!(kn<48||kn>102||kn>57&&kn<65||kn>70&&kn<97););return S4(r,Nv()+(e<6&&pu()==32&&Za()==32))}function bw(r){for(;Za();)switch(kn){case r:return aa;case 34:case 39:r!==34&&r!==39&&bw(kn);break;case 40:r===41&&bw(r);break;case 92:Za();break}return aa}function HX(r,e){for(;Za()&&r+kn!==57;)if(r+kn===84&&pu()===47)break;return"/*"+S4(e,aa-1)+"*"+f8(r===47?r:Za())}function NX(r){for(;!_w(pu());)Za();return S4(r,aa)}function o$(r){return OX(Dv("",null,null,null,[""],r=$X(r),0,[0],r))}function Dv(r,e,t,n,i,o,a,c,d){for(var h=0,u=0,p=a,v=0,g=0,_=0,b=1,C=1,T=1,S=0,A="",Z=i,B=o,U=n,I=A;C;)switch(_=S,S=Za()){case 40:if(_!=108&&jn(I,p-1)==58){Hv(I+=Ot(y_(S),"&","&\f"),"&\f",t$(h?c[h-1]:0))!=-1&&(T=-1);break}case 34:case 39:case 91:I+=y_(S);break;case 9:case 10:case 13:case 32:I+=ZX(_);break;case 92:I+=LX(Nv()-1,7);continue;case 47:switch(pu()){case 42:case 47:xp(DX(HX(Za(),Nv()),e,t,d),d);break;default:I+="/"}break;case 123*b:c[h++]=ds(I)*T;case 125*b:case 59:case 0:switch(S){case 0:case 125:C=0;case 59+u:T==-1&&(I=Ot(I,/\f/g,"")),g>0&&ds(I)-p&&xp(g>32?eS(I+";",n,t,p-1,d):eS(Ot(I," ","")+";",n,t,p-2,d),d);break;case 59:I+=";";default:if(xp(U=JE(I,e,t,h,u,i,c,A,Z=[],B=[],p,o),o),S===123)if(u===0)Dv(I,e,U,U,Z,o,p,c,B);else switch(v===99&&jn(I,3)===110?100:v){case 100:case 108:case 109:case 115:Dv(r,U,U,n&&xp(JE(r,U,U,0,0,i,c,A,i,Z=[],p,B),B),i,B,p,c,n?Z:B);break;default:Dv(I,U,U,U,[""],B,0,c,B)}}h=u=g=0,b=T=1,A=I="",p=a;break;case 58:p=1+ds(I),g=_;default:if(b<1){if(S==123)--b;else if(S==125&&b++==0&&MX()==125)continue}switch(I+=f8(S),S*b){case 38:T=u>0?1:(I+="\f",-1);break;case 44:c[h++]=(ds(I)-1)*T,T=1;break;case 64:pu()===45&&(I+=y_(Za())),v=pu(),u=p=ds(A=I+=NX(Nv())),S++;break;case 45:_===45&&ds(I)==2&&(b=0)}}return o}function JE(r,e,t,n,i,o,a,c,d,h,u,p){for(var v=i-1,g=i===0?o:[""],_=n$(g),b=0,C=0,T=0;b<n;++b)for(var S=0,A=Tf(r,v+1,v=t$(C=a[b])),Z=r;S<_;++S)(Z=r$(C>0?g[S]+" "+A:Ot(A,/&\f/g,g[S])))&&(d[T++]=Z);return E4(r,e,t,i===0?Gm:c,d,h,u,p)}function DX(r,e,t,n){return E4(r,e,t,JM,f8(PX()),Tf(r,2,-2),0,n)}function eS(r,e,t,n,i){return E4(r,e,t,h8,Tf(r,0,n),Tf(r,n+1,-1),n,i)}function a$(r,e,t){switch(IX(r,e)){case 5103:return fr+"print-"+r+r;case 5737:case 4201:case 3177:case 3433:case 1641:case 4457:case 2921:case 5572:case 6356:case 5844:case 3191:case 6645:case 3005:case 6391:case 5879:case 5623:case 6135:case 4599:case 4855:case 4215:case 6389:case 5109:case 5365:case 5621:case 3829:return fr+r+r;case 4789:return Fp+r+r;case 5349:case 4246:case 4810:case 6968:case 2756:return fr+r+Fp+r+Nr+r+r;case 5936:switch(jn(r,e+11)){case 114:return fr+r+Nr+Ot(r,/[svh]\w+-[tblr]{2}/,"tb")+r;case 108:return fr+r+Nr+Ot(r,/[svh]\w+-[tblr]{2}/,"tb-rl")+r;case 45:return fr+r+Nr+Ot(r,/[svh]\w+-[tblr]{2}/,"lr")+r}case 6828:case 4268:case 2903:return fr+r+Nr+r+r;case 6165:return fr+r+Nr+"flex-"+r+r;case 5187:return fr+r+Ot(r,/(\w+).+(:[^]+)/,fr+"box-$1$2"+Nr+"flex-$1$2")+r;case 5443:return fr+r+Nr+"flex-item-"+Ot(r,/flex-|-self/g,"")+(tc(r,/flex-|baseline/)?"":Nr+"grid-row-"+Ot(r,/flex-|-self/g,""))+r;case 4675:return fr+r+Nr+"flex-line-pack"+Ot(r,/align-content|flex-|-self/g,"")+r;case 5548:return fr+r+Nr+Ot(r,"shrink","negative")+r;case 5292:return fr+r+Nr+Ot(r,"basis","preferred-size")+r;case 6060:return fr+"box-"+Ot(r,"-grow","")+fr+r+Nr+Ot(r,"grow","positive")+r;case 4554:return fr+Ot(r,/([^-])(transform)/g,"$1"+fr+"$2")+r;case 6187:return Ot(Ot(Ot(r,/(zoom-|grab)/,fr+"$1"),/(image-set)/,fr+"$1"),r,"")+r;case 5495:case 3959:return Ot(r,/(image-set\([^]*)/,fr+"$1$`$1");case 4968:return Ot(Ot(r,/(.+:)(flex-)?(.*)/,fr+"box-pack:$3"+Nr+"flex-pack:$3"),/s.+-b[^;]+/,"justify")+fr+r+r;case 4200:if(!tc(r,/flex-|baseline/))return Nr+"grid-column-align"+Tf(r,e)+r;break;case 2592:case 3360:return Nr+Ot(r,"template-","")+r;case 4384:case 3616:return t&&t.some(function(n,i){return e=i,tc(n.props,/grid-\w+-end/)})?~Hv(r+(t=t[e].value),"span",0)?r:Nr+Ot(r,"-start","")+r+Nr+"grid-row-span:"+(~Hv(t,"span",0)?tc(t,/\d+/):+tc(t,/\d+/)-+tc(r,/\d+/))+";":Nr+Ot(r,"-start","")+r;case 4896:case 4128:return t&&t.some(function(n){return tc(n.props,/grid-\w+-start/)})?r:Nr+Ot(Ot(r,"-end","-span"),"span ","")+r;case 4095:case 3583:case 4068:case 2532:return Ot(r,/(.+)-inline(.+)/,fr+"$1$2")+r;case 8116:case 7059:case 5753:case 5535:case 5445:case 5701:case 4933:case 4677:case 5533:case 5789:case 5021:case 4765:if(ds(r)-1-e>6)switch(jn(r,e+1)){case 109:if(jn(r,e+4)!==45)break;case 102:return Ot(r,/(.+:)(.+)-([^]+)/,"$1"+fr+"$2-$3$1"+Fp+(jn(r,e+3)==108?"$3":"$2-$3"))+r;case 115:return~Hv(r,"stretch",0)?a$(Ot(r,"stretch","fill-available"),e,t)+r:r}break;case 5152:case 5920:return Ot(r,/(.+?):(\d+)(\s*\/\s*(span)?\s*(\d+))?(.*)/,function(n,i,o,a,c,d,h){return Nr+i+":"+o+h+(a?Nr+i+"-span:"+(c?d:+d-+o)+h:"")+r});case 4949:if(jn(r,e+6)===121)return Ot(r,":",":"+fr)+r;break;case 6444:switch(jn(r,jn(r,14)===45?18:11)){case 120:return Ot(r,/(.+:)([^;\s!]+)(;|(\s+)?!.+)?/,"$1"+fr+(jn(r,14)===45?"inline-":"")+"box$3$1"+fr+"$2$3$1"+Nr+"$2box$3")+r;case 100:return Ot(r,":",":"+Nr)+r}break;case 5719:case 2647:case 2135:case 3927:case 2391:return Ot(r,"scroll-","scroll-snap-")+r}return r}function vm(r,e){for(var t="",n=0;n<r.length;n++)t+=e(r[n],n,r,e)||"";return t}function s$(r,e,t,n){switch(r.type){case AX:if(r.children.length)break;case TX:case h8:return r.return=r.return||r.value;case JM:return"";case e$:return r.return=r.value+"{"+vm(r.children,n)+"}";case Gm:if(!ds(r.value=r.props.join(",")))return""}return ds(t=vm(r.children,n))?r.return=r.value+"{"+t+"}":""}function c$(r){var e=n$(r);return function(t,n,i,o){for(var a="",c=0;c<e;c++)a+=r[c](t,n,i,o)||"";return a}}function l$(r){return function(e){e.root||(e=e.return)&&r(e)}}function d$(r,e,t,n){if(r.length>-1&&!r.return)switch(r.type){case h8:r.return=a$(r.value,r.length,t);return;case e$:return vm([fl(r,{value:Ot(r.value,"@","@"+fr)})],n);case Gm:if(r.length)return RX(t=r.props,function(i){switch(tc(i,n=/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":Ah(fl(r,{props:[Ot(i,/:(read-\w+)/,":"+Fp+"$1")]})),Ah(fl(r,{props:[i]})),yw(r,{props:XE(t,n)});break;case"::placeholder":Ah(fl(r,{props:[Ot(i,/:(plac\w+)/,":"+fr+"input-$1")]})),Ah(fl(r,{props:[Ot(i,/:(plac\w+)/,":"+Fp+"$1")]})),Ah(fl(r,{props:[Ot(i,/:(plac\w+)/,Nr+"input-$1")]})),Ah(fl(r,{props:[i]})),yw(r,{props:XE(t,n)});break}return""})}}var u$={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1},_o={},If=typeof process<"u"&&_o!==void 0&&(_o.REACT_APP_SC_ATTR||_o.SC_ATTR)||"data-styled",h$="active",f$="data-styled-version",T4="6.1.15",p8=`/*!sc*/
446
+ */const gX="6";try{window.__reactRouterVersion=gX}catch{}const yX=x.createContext({isTransitioning:!1}),_X=x.createContext(new Map),bX="startTransition",GE=Y6[bX],wX="flushSync",KE=ZQ[wX];function xX(r){GE?GE(r):r()}function G1(r){KE?KE(r):r()}class CX{constructor(){this.status="pending",this.promise=new Promise((e,t)=>{this.resolve=n=>{this.status==="pending"&&(this.status="resolved",e(n))},this.reject=n=>{this.status==="pending"&&(this.status="rejected",t(n))}})}}function kX(r){let{fallbackElement:e,router:t,future:n}=r,[i,o]=x.useState(t.state),[a,c]=x.useState(),[d,h]=x.useState({isTransitioning:!1}),[u,p]=x.useState(),[v,g]=x.useState(),[_,b]=x.useState(),C=x.useRef(new Map),{v7_startTransition:T}=n||{},S=x.useCallback(Y=>{T?xX(Y):Y()},[T]),A=x.useCallback((Y,le)=>{let{deletedFetchers:de,unstable_flushSync:Ee,unstable_viewTransitionOpts:we}=le;de.forEach(J=>C.current.delete(J)),Y.fetchers.forEach((J,K)=>{J.data!==void 0&&C.current.set(K,J.data)});let Ce=t.window==null||t.window.document==null||typeof t.window.document.startViewTransition!="function";if(!we||Ce){Ee?G1(()=>o(Y)):S(()=>o(Y));return}if(Ee){G1(()=>{v&&(u&&u.resolve(),v.skipTransition()),h({isTransitioning:!0,flushSync:!0,currentLocation:we.currentLocation,nextLocation:we.nextLocation})});let J=t.window.document.startViewTransition(()=>{G1(()=>o(Y))});J.finished.finally(()=>{G1(()=>{p(void 0),g(void 0),c(void 0),h({isTransitioning:!1})})}),G1(()=>g(J));return}v?(u&&u.resolve(),v.skipTransition(),b({state:Y,currentLocation:we.currentLocation,nextLocation:we.nextLocation})):(c(Y),h({isTransitioning:!0,flushSync:!1,currentLocation:we.currentLocation,nextLocation:we.nextLocation}))},[t.window,v,u,C,S]);x.useLayoutEffect(()=>t.subscribe(A),[t,A]),x.useEffect(()=>{d.isTransitioning&&!d.flushSync&&p(new CX)},[d]),x.useEffect(()=>{if(u&&a&&t.window){let Y=a,le=u.promise,de=t.window.document.startViewTransition(async()=>{S(()=>o(Y)),await le});de.finished.finally(()=>{p(void 0),g(void 0),c(void 0),h({isTransitioning:!1})}),g(de)}},[S,a,u,t.window]),x.useEffect(()=>{u&&a&&i.location.key===a.location.key&&u.resolve()},[u,v,i.location,a]),x.useEffect(()=>{!d.isTransitioning&&_&&(c(_.state),h({isTransitioning:!0,flushSync:!1,currentLocation:_.currentLocation,nextLocation:_.nextLocation}),b(void 0))},[d.isTransitioning,_]),x.useEffect(()=>{},[]);let Z=x.useMemo(()=>({createHref:t.createHref,encodeLocation:t.encodeLocation,go:Y=>t.navigate(Y),push:(Y,le,de)=>t.navigate(Y,{state:le,preventScrollReset:de==null?void 0:de.preventScrollReset}),replace:(Y,le,de)=>t.navigate(Y,{replace:!0,state:le,preventScrollReset:de==null?void 0:de.preventScrollReset})}),[t]),B=t.basename||"/",U=x.useMemo(()=>({router:t,navigator:Z,static:!1,basename:B}),[t,Z,B]),I=x.useMemo(()=>({v7_relativeSplatPath:t.future.v7_relativeSplatPath}),[t.future.v7_relativeSplatPath]);return x.createElement(x.Fragment,null,x.createElement(GM.Provider,{value:U},x.createElement(KM.Provider,{value:i},x.createElement(_X.Provider,{value:C.current},x.createElement(yX.Provider,{value:d},x.createElement(vX,{basename:B,location:i.location,navigationType:i.historyAction,navigator:Z,future:I},i.initialized||t.future.v7_partialHydration?x.createElement(EX,{routes:t.routes,future:t.future,state:i}):e))))),null)}const EX=x.memo(SX);function SX(r){let{routes:e,future:t,state:n}=r;return iX(e,void 0,n,t)}var YE;(function(r){r.UseScrollRestoration="useScrollRestoration",r.UseSubmit="useSubmit",r.UseSubmitFetcher="useSubmitFetcher",r.UseFetcher="useFetcher",r.useViewTransitionState="useViewTransitionState"})(YE||(YE={}));var QE;(function(r){r.UseFetcher="useFetcher",r.UseFetchers="useFetchers",r.UseScrollRestoration="useScrollRestoration"})(QE||(QE={}));var vr=function(){return vr=Object.assign||function(e){for(var t,n=1,i=arguments.length;n<i;n++){t=arguments[n];for(var o in t)Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o])}return e},vr.apply(this,arguments)};function bc(r,e,t){if(t||arguments.length===2)for(var n=0,i=e.length,o;n<i;n++)(o||!(n in e))&&(o||(o=Array.prototype.slice.call(e,0,n)),o[n]=e[n]);return r.concat(o||Array.prototype.slice.call(e))}var Nr="-ms-",Fp="-moz-",fr="-webkit-",JM="comm",Gm="rule",h8="decl",TX="@import",e$="@keyframes",AX="@layer",t$=Math.abs,f8=String.fromCharCode,yw=Object.assign;function IX(r,e){return jn(r,0)^45?(((e<<2^jn(r,0))<<2^jn(r,1))<<2^jn(r,2))<<2^jn(r,3):0}function r$(r){return r.trim()}function tc(r,e){return(r=e.exec(r))?r[0]:r}function Ot(r,e,t){return r.replace(e,t)}function Hv(r,e,t){return r.indexOf(e,t)}function jn(r,e){return r.charCodeAt(e)|0}function Tf(r,e,t){return r.slice(e,t)}function ds(r){return r.length}function n$(r){return r.length}function xp(r,e){return e.push(r),r}function RX(r,e){return r.map(e).join("")}function XE(r,e){return r.filter(function(t){return!tc(t,e)})}var k4=1,Af=1,i$=0,aa=0,kn=0,Uf="";function E4(r,e,t,n,i,o,a,c){return{value:r,root:e,parent:t,type:n,props:i,children:o,line:k4,column:Af,length:a,return:"",siblings:c}}function fl(r,e){return yw(E4("",null,null,"",null,null,0,r.siblings),r,{length:-r.length},e)}function Ah(r){for(;r.root;)r=fl(r.root,{children:[r]});xp(r,r.siblings)}function PX(){return kn}function MX(){return kn=aa>0?jn(Uf,--aa):0,Af--,kn===10&&(Af=1,k4--),kn}function Za(){return kn=aa<i$?jn(Uf,aa++):0,Af++,kn===10&&(Af=1,k4++),kn}function pu(){return jn(Uf,aa)}function Nv(){return aa}function S4(r,e){return Tf(Uf,r,e)}function _w(r){switch(r){case 0:case 9:case 10:case 13:case 32:return 5;case 33:case 43:case 44:case 47:case 62:case 64:case 126:case 59:case 123:case 125:return 4;case 58:return 3;case 34:case 39:case 40:case 91:return 2;case 41:case 93:return 1}return 0}function $X(r){return k4=Af=1,i$=ds(Uf=r),aa=0,[]}function OX(r){return Uf="",r}function y_(r){return r$(S4(aa-1,bw(r===91?r+2:r===40?r+1:r)))}function ZX(r){for(;(kn=pu())&&kn<33;)Za();return _w(r)>2||_w(kn)>3?"":" "}function LX(r,e){for(;--e&&Za()&&!(kn<48||kn>102||kn>57&&kn<65||kn>70&&kn<97););return S4(r,Nv()+(e<6&&pu()==32&&Za()==32))}function bw(r){for(;Za();)switch(kn){case r:return aa;case 34:case 39:r!==34&&r!==39&&bw(kn);break;case 40:r===41&&bw(r);break;case 92:Za();break}return aa}function HX(r,e){for(;Za()&&r+kn!==57;)if(r+kn===84&&pu()===47)break;return"/*"+S4(e,aa-1)+"*"+f8(r===47?r:Za())}function NX(r){for(;!_w(pu());)Za();return S4(r,aa)}function o$(r){return OX(Dv("",null,null,null,[""],r=$X(r),0,[0],r))}function Dv(r,e,t,n,i,o,a,c,d){for(var h=0,u=0,p=a,v=0,g=0,_=0,b=1,C=1,T=1,S=0,A="",Z=i,B=o,U=n,I=A;C;)switch(_=S,S=Za()){case 40:if(_!=108&&jn(I,p-1)==58){Hv(I+=Ot(y_(S),"&","&\f"),"&\f",t$(h?c[h-1]:0))!=-1&&(T=-1);break}case 34:case 39:case 91:I+=y_(S);break;case 9:case 10:case 13:case 32:I+=ZX(_);break;case 92:I+=LX(Nv()-1,7);continue;case 47:switch(pu()){case 42:case 47:xp(DX(HX(Za(),Nv()),e,t,d),d);break;default:I+="/"}break;case 123*b:c[h++]=ds(I)*T;case 125*b:case 59:case 0:switch(S){case 0:case 125:C=0;case 59+u:T==-1&&(I=Ot(I,/\f/g,"")),g>0&&ds(I)-p&&xp(g>32?eS(I+";",n,t,p-1,d):eS(Ot(I," ","")+";",n,t,p-2,d),d);break;case 59:I+=";";default:if(xp(U=JE(I,e,t,h,u,i,c,A,Z=[],B=[],p,o),o),S===123)if(u===0)Dv(I,e,U,U,Z,o,p,c,B);else switch(v===99&&jn(I,3)===110?100:v){case 100:case 108:case 109:case 115:Dv(r,U,U,n&&xp(JE(r,U,U,0,0,i,c,A,i,Z=[],p,B),B),i,B,p,c,n?Z:B);break;default:Dv(I,U,U,U,[""],B,0,c,B)}}h=u=g=0,b=T=1,A=I="",p=a;break;case 58:p=1+ds(I),g=_;default:if(b<1){if(S==123)--b;else if(S==125&&b++==0&&MX()==125)continue}switch(I+=f8(S),S*b){case 38:T=u>0?1:(I+="\f",-1);break;case 44:c[h++]=(ds(I)-1)*T,T=1;break;case 64:pu()===45&&(I+=y_(Za())),v=pu(),u=p=ds(A=I+=NX(Nv())),S++;break;case 45:_===45&&ds(I)==2&&(b=0)}}return o}function JE(r,e,t,n,i,o,a,c,d,h,u,p){for(var v=i-1,g=i===0?o:[""],_=n$(g),b=0,C=0,T=0;b<n;++b)for(var S=0,A=Tf(r,v+1,v=t$(C=a[b])),Z=r;S<_;++S)(Z=r$(C>0?g[S]+" "+A:Ot(A,/&\f/g,g[S])))&&(d[T++]=Z);return E4(r,e,t,i===0?Gm:c,d,h,u,p)}function DX(r,e,t,n){return E4(r,e,t,JM,f8(PX()),Tf(r,2,-2),0,n)}function eS(r,e,t,n,i){return E4(r,e,t,h8,Tf(r,0,n),Tf(r,n+1,-1),n,i)}function a$(r,e,t){switch(IX(r,e)){case 5103:return fr+"print-"+r+r;case 5737:case 4201:case 3177:case 3433:case 1641:case 4457:case 2921:case 5572:case 6356:case 5844:case 3191:case 6645:case 3005:case 6391:case 5879:case 5623:case 6135:case 4599:case 4855:case 4215:case 6389:case 5109:case 5365:case 5621:case 3829:return fr+r+r;case 4789:return Fp+r+r;case 5349:case 4246:case 4810:case 6968:case 2756:return fr+r+Fp+r+Nr+r+r;case 5936:switch(jn(r,e+11)){case 114:return fr+r+Nr+Ot(r,/[svh]\w+-[tblr]{2}/,"tb")+r;case 108:return fr+r+Nr+Ot(r,/[svh]\w+-[tblr]{2}/,"tb-rl")+r;case 45:return fr+r+Nr+Ot(r,/[svh]\w+-[tblr]{2}/,"lr")+r}case 6828:case 4268:case 2903:return fr+r+Nr+r+r;case 6165:return fr+r+Nr+"flex-"+r+r;case 5187:return fr+r+Ot(r,/(\w+).+(:[^]+)/,fr+"box-$1$2"+Nr+"flex-$1$2")+r;case 5443:return fr+r+Nr+"flex-item-"+Ot(r,/flex-|-self/g,"")+(tc(r,/flex-|baseline/)?"":Nr+"grid-row-"+Ot(r,/flex-|-self/g,""))+r;case 4675:return fr+r+Nr+"flex-line-pack"+Ot(r,/align-content|flex-|-self/g,"")+r;case 5548:return fr+r+Nr+Ot(r,"shrink","negative")+r;case 5292:return fr+r+Nr+Ot(r,"basis","preferred-size")+r;case 6060:return fr+"box-"+Ot(r,"-grow","")+fr+r+Nr+Ot(r,"grow","positive")+r;case 4554:return fr+Ot(r,/([^-])(transform)/g,"$1"+fr+"$2")+r;case 6187:return Ot(Ot(Ot(r,/(zoom-|grab)/,fr+"$1"),/(image-set)/,fr+"$1"),r,"")+r;case 5495:case 3959:return Ot(r,/(image-set\([^]*)/,fr+"$1$`$1");case 4968:return Ot(Ot(r,/(.+:)(flex-)?(.*)/,fr+"box-pack:$3"+Nr+"flex-pack:$3"),/s.+-b[^;]+/,"justify")+fr+r+r;case 4200:if(!tc(r,/flex-|baseline/))return Nr+"grid-column-align"+Tf(r,e)+r;break;case 2592:case 3360:return Nr+Ot(r,"template-","")+r;case 4384:case 3616:return t&&t.some(function(n,i){return e=i,tc(n.props,/grid-\w+-end/)})?~Hv(r+(t=t[e].value),"span",0)?r:Nr+Ot(r,"-start","")+r+Nr+"grid-row-span:"+(~Hv(t,"span",0)?tc(t,/\d+/):+tc(t,/\d+/)-+tc(r,/\d+/))+";":Nr+Ot(r,"-start","")+r;case 4896:case 4128:return t&&t.some(function(n){return tc(n.props,/grid-\w+-start/)})?r:Nr+Ot(Ot(r,"-end","-span"),"span ","")+r;case 4095:case 3583:case 4068:case 2532:return Ot(r,/(.+)-inline(.+)/,fr+"$1$2")+r;case 8116:case 7059:case 5753:case 5535:case 5445:case 5701:case 4933:case 4677:case 5533:case 5789:case 5021:case 4765:if(ds(r)-1-e>6)switch(jn(r,e+1)){case 109:if(jn(r,e+4)!==45)break;case 102:return Ot(r,/(.+:)(.+)-([^]+)/,"$1"+fr+"$2-$3$1"+Fp+(jn(r,e+3)==108?"$3":"$2-$3"))+r;case 115:return~Hv(r,"stretch",0)?a$(Ot(r,"stretch","fill-available"),e,t)+r:r}break;case 5152:case 5920:return Ot(r,/(.+?):(\d+)(\s*\/\s*(span)?\s*(\d+))?(.*)/,function(n,i,o,a,c,d,h){return Nr+i+":"+o+h+(a?Nr+i+"-span:"+(c?d:+d-+o)+h:"")+r});case 4949:if(jn(r,e+6)===121)return Ot(r,":",":"+fr)+r;break;case 6444:switch(jn(r,jn(r,14)===45?18:11)){case 120:return Ot(r,/(.+:)([^;\s!]+)(;|(\s+)?!.+)?/,"$1"+fr+(jn(r,14)===45?"inline-":"")+"box$3$1"+fr+"$2$3$1"+Nr+"$2box$3")+r;case 100:return Ot(r,":",":"+Nr)+r}break;case 5719:case 2647:case 2135:case 3927:case 2391:return Ot(r,"scroll-","scroll-snap-")+r}return r}function vm(r,e){for(var t="",n=0;n<r.length;n++)t+=e(r[n],n,r,e)||"";return t}function s$(r,e,t,n){switch(r.type){case AX:if(r.children.length)break;case TX:case h8:return r.return=r.return||r.value;case JM:return"";case e$:return r.return=r.value+"{"+vm(r.children,n)+"}";case Gm:if(!ds(r.value=r.props.join(",")))return""}return ds(t=vm(r.children,n))?r.return=r.value+"{"+t+"}":""}function c$(r){var e=n$(r);return function(t,n,i,o){for(var a="",c=0;c<e;c++)a+=r[c](t,n,i,o)||"";return a}}function l$(r){return function(e){e.root||(e=e.return)&&r(e)}}function d$(r,e,t,n){if(r.length>-1&&!r.return)switch(r.type){case h8:r.return=a$(r.value,r.length,t);return;case e$:return vm([fl(r,{value:Ot(r.value,"@","@"+fr)})],n);case Gm:if(r.length)return RX(t=r.props,function(i){switch(tc(i,n=/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":Ah(fl(r,{props:[Ot(i,/:(read-\w+)/,":"+Fp+"$1")]})),Ah(fl(r,{props:[i]})),yw(r,{props:XE(t,n)});break;case"::placeholder":Ah(fl(r,{props:[Ot(i,/:(plac\w+)/,":"+fr+"input-$1")]})),Ah(fl(r,{props:[Ot(i,/:(plac\w+)/,":"+Fp+"$1")]})),Ah(fl(r,{props:[Ot(i,/:(plac\w+)/,Nr+"input-$1")]})),Ah(fl(r,{props:[i]})),yw(r,{props:XE(t,n)});break}return""})}}var u$={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1},_o={},If=typeof process<"u"&&_o!==void 0&&(_o.REACT_APP_SC_ATTR||_o.SC_ATTR)||"data-styled",h$="active",f$="data-styled-version",T4="6.1.16",p8=`/*!sc*/
447
447
  `,Hg=typeof window<"u"&&"HTMLElement"in window,VX=!!(typeof SC_DISABLE_SPEEDY=="boolean"?SC_DISABLE_SPEEDY:typeof process<"u"&&_o!==void 0&&_o.REACT_APP_SC_DISABLE_SPEEDY!==void 0&&_o.REACT_APP_SC_DISABLE_SPEEDY!==""?_o.REACT_APP_SC_DISABLE_SPEEDY!=="false"&&_o.REACT_APP_SC_DISABLE_SPEEDY:typeof process<"u"&&_o!==void 0&&_o.SC_DISABLE_SPEEDY!==void 0&&_o.SC_DISABLE_SPEEDY!==""&&_o.SC_DISABLE_SPEEDY!=="false"&&_o.SC_DISABLE_SPEEDY),A4=Object.freeze([]),Rf=Object.freeze({});function FX(r,e,t){return t===void 0&&(t=Rf),r.theme!==t.theme&&r.theme||e||t.theme}var p$=new Set(["a","abbr","address","area","article","aside","audio","b","base","bdi","bdo","big","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","data","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","header","hgroup","hr","html","i","iframe","img","input","ins","kbd","keygen","label","legend","li","link","main","map","mark","menu","menuitem","meta","meter","nav","noscript","object","ol","optgroup","option","output","p","param","picture","pre","progress","q","rp","rt","ruby","s","samp","script","section","select","small","source","span","strong","style","sub","summary","sup","table","tbody","td","textarea","tfoot","th","thead","time","tr","track","u","ul","use","var","video","wbr","circle","clipPath","defs","ellipse","foreignObject","g","image","line","linearGradient","marker","mask","path","pattern","polygon","polyline","radialGradient","rect","stop","svg","text","tspan"]),jX=/[!"#$%&'()*+,./:;<=>?@[\\\]^`{|}~-]+/g,zX=/(^-|-$)/g;function tS(r){return r.replace(jX,"-").replace(zX,"")}var BX=/(a)(d)/gi,N0=52,rS=function(r){return String.fromCharCode(r+(r>25?39:97))};function ww(r){var e,t="";for(e=Math.abs(r);e>N0;e=e/N0|0)t=rS(e%N0)+t;return(rS(e%N0)+t).replace(BX,"$1-$2")}var __,m$=5381,tf=function(r,e){for(var t=e.length;t;)r=33*r^e.charCodeAt(--t);return r},v$=function(r){return tf(m$,r)};function UX(r){return ww(v$(r)>>>0)}function qX(r){return r.displayName||r.name||"Component"}function b_(r){return typeof r=="string"&&!0}var g$=typeof Symbol=="function"&&Symbol.for,y$=g$?Symbol.for("react.memo"):60115,WX=g$?Symbol.for("react.forward_ref"):60112,GX={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},KX={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},_$={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},YX=((__={})[WX]={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},__[y$]=_$,__);function nS(r){return("type"in(e=r)&&e.type.$$typeof)===y$?_$:"$$typeof"in r?YX[r.$$typeof]:GX;var e}var QX=Object.defineProperty,XX=Object.getOwnPropertyNames,iS=Object.getOwnPropertySymbols,JX=Object.getOwnPropertyDescriptor,eJ=Object.getPrototypeOf,oS=Object.prototype;function b$(r,e,t){if(typeof e!="string"){if(oS){var n=eJ(e);n&&n!==oS&&b$(r,n,t)}var i=XX(e);iS&&(i=i.concat(iS(e)));for(var o=nS(r),a=nS(e),c=0;c<i.length;++c){var d=i[c];if(!(d in KX||t&&t[d]||a&&d in a||o&&d in o)){var h=JX(e,d);try{QX(r,d,h)}catch{}}}}return r}function Su(r){return typeof r=="function"}function m8(r){return typeof r=="object"&&"styledComponentId"in r}function Gd(r,e){return r&&e?"".concat(r," ").concat(e):r||e||""}function aS(r,e){if(r.length===0)return"";for(var t=r[0],n=1;n<r.length;n++)t+=r[n];return t}function gm(r){return r!==null&&typeof r=="object"&&r.constructor.name===Object.name&&!("props"in r&&r.$$typeof)}function xw(r,e,t){if(t===void 0&&(t=!1),!t&&!gm(r)&&!Array.isArray(r))return e;if(Array.isArray(e))for(var n=0;n<e.length;n++)r[n]=xw(r[n],e[n]);else if(gm(e))for(var n in e)r[n]=xw(r[n],e[n]);return r}function v8(r,e){Object.defineProperty(r,"toString",{value:e})}function Tu(r){for(var e=[],t=1;t<arguments.length;t++)e[t-1]=arguments[t];return new Error("An error occurred. See https://github.com/styled-components/styled-components/blob/main/packages/styled-components/src/utils/errors.md#".concat(r," for more information.").concat(e.length>0?" Args: ".concat(e.join(", ")):""))}var tJ=function(){function r(e){this.groupSizes=new Uint32Array(512),this.length=512,this.tag=e}return r.prototype.indexOfGroup=function(e){for(var t=0,n=0;n<e;n++)t+=this.groupSizes[n];return t},r.prototype.insertRules=function(e,t){if(e>=this.groupSizes.length){for(var n=this.groupSizes,i=n.length,o=i;e>=o;)if((o<<=1)<0)throw Tu(16,"".concat(e));this.groupSizes=new Uint32Array(o),this.groupSizes.set(n),this.length=o;for(var a=i;a<o;a++)this.groupSizes[a]=0}for(var c=this.indexOfGroup(e+1),d=(a=0,t.length);a<d;a++)this.tag.insertRule(c,t[a])&&(this.groupSizes[e]++,c++)},r.prototype.clearGroup=function(e){if(e<this.length){var t=this.groupSizes[e],n=this.indexOfGroup(e),i=n+t;this.groupSizes[e]=0;for(var o=n;o<i;o++)this.tag.deleteRule(n)}},r.prototype.getGroup=function(e){var t="";if(e>=this.length||this.groupSizes[e]===0)return t;for(var n=this.groupSizes[e],i=this.indexOfGroup(e),o=i+n,a=i;a<o;a++)t+="".concat(this.tag.getRule(a)).concat(p8);return t},r}(),Vv=new Map,Ng=new Map,Fv=1,D0=function(r){if(Vv.has(r))return Vv.get(r);for(;Ng.has(Fv);)Fv++;var e=Fv++;return Vv.set(r,e),Ng.set(e,r),e},rJ=function(r,e){Fv=e+1,Vv.set(r,e),Ng.set(e,r)},nJ="style[".concat(If,"][").concat(f$,'="').concat(T4,'"]'),iJ=new RegExp("^".concat(If,'\\.g(\\d+)\\[id="([\\w\\d-]+)"\\].*?"([^"]*)')),oJ=function(r,e,t){for(var n,i=t.split(","),o=0,a=i.length;o<a;o++)(n=i[o])&&r.registerName(e,n)},aJ=function(r,e){for(var t,n=((t=e.textContent)!==null&&t!==void 0?t:"").split(p8),i=[],o=0,a=n.length;o<a;o++){var c=n[o].trim();if(c){var d=c.match(iJ);if(d){var h=0|parseInt(d[1],10),u=d[2];h!==0&&(rJ(u,h),oJ(r,u,d[3]),r.getTag().insertRules(h,i)),i.length=0}else i.push(c)}}},sS=function(r){for(var e=document.querySelectorAll(nJ),t=0,n=e.length;t<n;t++){var i=e[t];i&&i.getAttribute(If)!==h$&&(aJ(r,i),i.parentNode&&i.parentNode.removeChild(i))}};function sJ(){return typeof __webpack_nonce__<"u"?__webpack_nonce__:null}var w$=function(r){var e=document.head,t=r||e,n=document.createElement("style"),i=function(c){var d=Array.from(c.querySelectorAll("style[".concat(If,"]")));return d[d.length-1]}(t),o=i!==void 0?i.nextSibling:null;n.setAttribute(If,h$),n.setAttribute(f$,T4);var a=sJ();return a&&n.setAttribute("nonce",a),t.insertBefore(n,o),n},cJ=function(){function r(e){this.element=w$(e),this.element.appendChild(document.createTextNode("")),this.sheet=function(t){if(t.sheet)return t.sheet;for(var n=document.styleSheets,i=0,o=n.length;i<o;i++){var a=n[i];if(a.ownerNode===t)return a}throw Tu(17)}(this.element),this.length=0}return r.prototype.insertRule=function(e,t){try{return this.sheet.insertRule(t,e),this.length++,!0}catch{return!1}},r.prototype.deleteRule=function(e){this.sheet.deleteRule(e),this.length--},r.prototype.getRule=function(e){var t=this.sheet.cssRules[e];return t&&t.cssText?t.cssText:""},r}(),lJ=function(){function r(e){this.element=w$(e),this.nodes=this.element.childNodes,this.length=0}return r.prototype.insertRule=function(e,t){if(e<=this.length&&e>=0){var n=document.createTextNode(t);return this.element.insertBefore(n,this.nodes[e]||null),this.length++,!0}return!1},r.prototype.deleteRule=function(e){this.element.removeChild(this.nodes[e]),this.length--},r.prototype.getRule=function(e){return e<this.length?this.nodes[e].textContent:""},r}(),dJ=function(){function r(e){this.rules=[],this.length=0}return r.prototype.insertRule=function(e,t){return e<=this.length&&(this.rules.splice(e,0,t),this.length++,!0)},r.prototype.deleteRule=function(e){this.rules.splice(e,1),this.length--},r.prototype.getRule=function(e){return e<this.length?this.rules[e]:""},r}(),cS=Hg,uJ={isServer:!Hg,useCSSOMInjection:!VX},x$=function(){function r(e,t,n){e===void 0&&(e=Rf),t===void 0&&(t={});var i=this;this.options=vr(vr({},uJ),e),this.gs=t,this.names=new Map(n),this.server=!!e.isServer,!this.server&&Hg&&cS&&(cS=!1,sS(this)),v8(this,function(){return function(o){for(var a=o.getTag(),c=a.length,d="",h=function(p){var v=function(T){return Ng.get(T)}(p);if(v===void 0)return"continue";var g=o.names.get(v),_=a.getGroup(p);if(g===void 0||!g.size||_.length===0)return"continue";var b="".concat(If,".g").concat(p,'[id="').concat(v,'"]'),C="";g!==void 0&&g.forEach(function(T){T.length>0&&(C+="".concat(T,","))}),d+="".concat(_).concat(b,'{content:"').concat(C,'"}').concat(p8)},u=0;u<c;u++)h(u);return d}(i)})}return r.registerId=function(e){return D0(e)},r.prototype.rehydrate=function(){!this.server&&Hg&&sS(this)},r.prototype.reconstructWithOptions=function(e,t){return t===void 0&&(t=!0),new r(vr(vr({},this.options),e),this.gs,t&&this.names||void 0)},r.prototype.allocateGSInstance=function(e){return this.gs[e]=(this.gs[e]||0)+1},r.prototype.getTag=function(){return this.tag||(this.tag=(e=function(t){var n=t.useCSSOMInjection,i=t.target;return t.isServer?new dJ(i):n?new cJ(i):new lJ(i)}(this.options),new tJ(e)));var e},r.prototype.hasNameForId=function(e,t){return this.names.has(e)&&this.names.get(e).has(t)},r.prototype.registerName=function(e,t){if(D0(e),this.names.has(e))this.names.get(e).add(t);else{var n=new Set;n.add(t),this.names.set(e,n)}},r.prototype.insertRules=function(e,t,n){this.registerName(e,t),this.getTag().insertRules(D0(e),n)},r.prototype.clearNames=function(e){this.names.has(e)&&this.names.get(e).clear()},r.prototype.clearRules=function(e){this.getTag().clearGroup(D0(e)),this.clearNames(e)},r.prototype.clearTag=function(){this.tag=void 0},r}(),hJ=/&/g,fJ=/^\s*\/\/.*$/gm;function C$(r,e){return r.map(function(t){return t.type==="rule"&&(t.value="".concat(e," ").concat(t.value),t.value=t.value.replaceAll(",",",".concat(e," ")),t.props=t.props.map(function(n){return"".concat(e," ").concat(n)})),Array.isArray(t.children)&&t.type!=="@keyframes"&&(t.children=C$(t.children,e)),t})}function pJ(r){var e,t,n,i=Rf,o=i.options,a=o===void 0?Rf:o,c=i.plugins,d=c===void 0?A4:c,h=function(v,g,_){return _.startsWith(t)&&_.endsWith(t)&&_.replaceAll(t,"").length>0?".".concat(e):v},u=d.slice();u.push(function(v){v.type===Gm&&v.value.includes("&")&&(v.props[0]=v.props[0].replace(hJ,t).replace(n,h))}),a.prefix&&u.push(d$),u.push(s$);var p=function(v,g,_,b){g===void 0&&(g=""),_===void 0&&(_=""),b===void 0&&(b="&"),e=b,t=g,n=new RegExp("\\".concat(t,"\\b"),"g");var C=v.replace(fJ,""),T=o$(_||g?"".concat(_," ").concat(g," { ").concat(C," }"):C);a.namespace&&(T=C$(T,a.namespace));var S=[];return vm(T,c$(u.concat(l$(function(A){return S.push(A)})))),S};return p.hash=d.length?d.reduce(function(v,g){return g.name||Tu(15),tf(v,g.name)},m$).toString():"",p}var mJ=new x$,Cw=pJ(),k$=or.createContext({shouldForwardProp:void 0,styleSheet:mJ,stylis:Cw});k$.Consumer;or.createContext(void 0);function lS(){return x.useContext(k$)}var vJ=function(){function r(e,t){var n=this;this.inject=function(i,o){o===void 0&&(o=Cw);var a=n.name+o.hash;i.hasNameForId(n.id,a)||i.insertRules(n.id,a,o(n.rules,a,"@keyframes"))},this.name=e,this.id="sc-keyframes-".concat(e),this.rules=t,v8(this,function(){throw Tu(12,String(n.name))})}return r.prototype.getName=function(e){return e===void 0&&(e=Cw),this.name+e.hash},r}(),gJ=function(r){return r>="A"&&r<="Z"};function dS(r){for(var e="",t=0;t<r.length;t++){var n=r[t];if(t===1&&n==="-"&&r[0]==="-")return r;gJ(n)?e+="-"+n.toLowerCase():e+=n}return e.startsWith("ms-")?"-"+e:e}var E$=function(r){return r==null||r===!1||r===""},S$=function(r){var e,t,n=[];for(var i in r){var o=r[i];r.hasOwnProperty(i)&&!E$(o)&&(Array.isArray(o)&&o.isCss||Su(o)?n.push("".concat(dS(i),":"),o,";"):gm(o)?n.push.apply(n,bc(bc(["".concat(i," {")],S$(o),!1),["}"],!1)):n.push("".concat(dS(i),": ").concat((e=i,(t=o)==null||typeof t=="boolean"||t===""?"":typeof t!="number"||t===0||e in u$||e.startsWith("--")?String(t).trim():"".concat(t,"px")),";")))}return n};function mu(r,e,t,n){if(E$(r))return[];if(m8(r))return[".".concat(r.styledComponentId)];if(Su(r)){if(!Su(o=r)||o.prototype&&o.prototype.isReactComponent||!e)return[r];var i=r(e);return mu(i,e,t,n)}var o;return r instanceof vJ?t?(r.inject(t,n),[r.getName(n)]):[r]:gm(r)?S$(r):Array.isArray(r)?Array.prototype.concat.apply(A4,r.map(function(a){return mu(a,e,t,n)})):[r.toString()]}function yJ(r){for(var e=0;e<r.length;e+=1){var t=r[e];if(Su(t)&&!m8(t))return!1}return!0}var _J=v$(T4),bJ=function(){function r(e,t,n){this.rules=e,this.staticRulesId="",this.isStatic=(n===void 0||n.isStatic)&&yJ(e),this.componentId=t,this.baseHash=tf(_J,t),this.baseStyle=n,x$.registerId(t)}return r.prototype.generateAndInjectStyles=function(e,t,n){var i=this.baseStyle?this.baseStyle.generateAndInjectStyles(e,t,n):"";if(this.isStatic&&!n.hash)if(this.staticRulesId&&t.hasNameForId(this.componentId,this.staticRulesId))i=Gd(i,this.staticRulesId);else{var o=aS(mu(this.rules,e,t,n)),a=ww(tf(this.baseHash,o)>>>0);if(!t.hasNameForId(this.componentId,a)){var c=n(o,".".concat(a),void 0,this.componentId);t.insertRules(this.componentId,a,c)}i=Gd(i,a),this.staticRulesId=a}else{for(var d=tf(this.baseHash,n.hash),h="",u=0;u<this.rules.length;u++){var p=this.rules[u];if(typeof p=="string")h+=p;else if(p){var v=aS(mu(p,e,t,n));d=tf(d,v+u),h+=v}}if(h){var g=ww(d>>>0);t.hasNameForId(this.componentId,g)||t.insertRules(this.componentId,g,n(h,".".concat(g),void 0,this.componentId)),i=Gd(i,g)}}return i},r}(),Dg=or.createContext(void 0);Dg.Consumer;function I4(r){var e=or.useContext(Dg),t=x.useMemo(function(){return function(n,i){if(!n)throw Tu(14);if(Su(n)){var o=n(i);return o}if(Array.isArray(n)||typeof n!="object")throw Tu(8);return i?vr(vr({},i),n):n}(r.theme,e)},[r.theme,e]);return r.children?or.createElement(Dg.Provider,{value:t},r.children):null}var w_={};function wJ(r,e,t){var n=m8(r),i=r,o=!b_(r),a=e.attrs,c=a===void 0?A4:a,d=e.componentId,h=d===void 0?function(Z,B){var U=typeof Z!="string"?"sc":tS(Z);w_[U]=(w_[U]||0)+1;var I="".concat(U,"-").concat(UX(T4+U+w_[U]));return B?"".concat(B,"-").concat(I):I}(e.displayName,e.parentComponentId):d,u=e.displayName,p=u===void 0?function(Z){return b_(Z)?"styled.".concat(Z):"Styled(".concat(qX(Z),")")}(r):u,v=e.displayName&&e.componentId?"".concat(tS(e.displayName),"-").concat(e.componentId):e.componentId||h,g=n&&i.attrs?i.attrs.concat(c).filter(Boolean):c,_=e.shouldForwardProp;if(n&&i.shouldForwardProp){var b=i.shouldForwardProp;if(e.shouldForwardProp){var C=e.shouldForwardProp;_=function(Z,B){return b(Z,B)&&C(Z,B)}}else _=b}var T=new bJ(t,v,n?i.componentStyle:void 0);function S(Z,B){return function(U,I,Y){var le=U.attrs,de=U.componentStyle,Ee=U.defaultProps,we=U.foldedComponentIds,Ce=U.styledComponentId,J=U.target,K=or.useContext(Dg),re=lS(),q=U.shouldForwardProp||re.shouldForwardProp,$=FX(I,K,Ee)||Rf,O=function(Ie,Te,Ke){for(var ot,_t=vr(vr({},Te),{className:void 0,theme:Ke}),yr=0;yr<Ie.length;yr+=1){var Wr=Su(ot=Ie[yr])?ot(_t):ot;for(var Rt in Wr)_t[Rt]=Rt==="className"?Gd(_t[Rt],Wr[Rt]):Rt==="style"?vr(vr({},_t[Rt]),Wr[Rt]):Wr[Rt]}return Te.className&&(_t.className=Gd(_t.className,Te.className)),_t}(le,I,$),H=O.as||J,P={};for(var N in O)O[N]===void 0||N[0]==="$"||N==="as"||N==="theme"&&O.theme===$||(N==="forwardedAs"?P.as=O.forwardedAs:q&&!q(N,H)||(P[N]=O[N]));var ye=function(Ie,Te){var Ke=lS(),ot=Ie.generateAndInjectStyles(Te,Ke.styleSheet,Ke.stylis);return ot}(de,O),Pe=Gd(we,Ce);return ye&&(Pe+=" "+ye),O.className&&(Pe+=" "+O.className),P[b_(H)&&!p$.has(H)?"class":"className"]=Pe,Y&&(P.ref=Y),x.createElement(H,P)}(A,Z,B)}S.displayName=p;var A=or.forwardRef(S);return A.attrs=g,A.componentStyle=T,A.displayName=p,A.shouldForwardProp=_,A.foldedComponentIds=n?Gd(i.foldedComponentIds,i.styledComponentId):"",A.styledComponentId=v,A.target=n?i.target:r,Object.defineProperty(A,"defaultProps",{get:function(){return this._foldedDefaultProps},set:function(Z){this._foldedDefaultProps=n?function(B){for(var U=[],I=1;I<arguments.length;I++)U[I-1]=arguments[I];for(var Y=0,le=U;Y<le.length;Y++)xw(B,le[Y],!0);return B}({},i.defaultProps,Z):Z}}),v8(A,function(){return".".concat(A.styledComponentId)}),o&&b$(A,r,{attrs:!0,componentStyle:!0,displayName:!0,foldedComponentIds:!0,shouldForwardProp:!0,styledComponentId:!0,target:!0}),A}function uS(r,e){for(var t=[r[0]],n=0,i=e.length;n<i;n+=1)t.push(e[n],r[n+1]);return t}var hS=function(r){return Object.assign(r,{isCss:!0})};function wr(r){for(var e=[],t=1;t<arguments.length;t++)e[t-1]=arguments[t];if(Su(r)||gm(r))return hS(mu(uS(A4,bc([r],e,!0))));var n=r;return e.length===0&&n.length===1&&typeof n[0]=="string"?mu(n):hS(mu(uS(n,e)))}function kw(r,e,t){if(t===void 0&&(t=Rf),!e)throw Tu(1,e);var n=function(i){for(var o=[],a=1;a<arguments.length;a++)o[a-1]=arguments[a];return r(e,t,wr.apply(void 0,bc([i],o,!1)))};return n.attrs=function(i){return kw(r,e,vr(vr({},t),{attrs:Array.prototype.concat(t.attrs,i).filter(Boolean)}))},n.withConfig=function(i){return kw(r,e,vr(vr({},t),i))},n}var T$=function(r){return kw(wJ,r)},ut=T$;p$.forEach(function(r){ut[r]=T$(r)});const{typography:{navigation:{button:x_}},colors:{interactive:{disabled__text:{rgba:xJ},disabled__border:{rgba:CJ},disabled__fill:{rgba:kJ}}},spacings:{comfortable:{medium:fS}},shape:{button:{minHeight:pS,borderRadius:mS},_modes:{compact:{button:{minHeight:vS}}}},interactions:{focused:gS},clickbounds:{default__base:yS,compact__standard:_S}}=Xe,R4={background:"transparent",height:`var(--eds_button__height, ${pS})`,typography:{...x_,textAlign:"center",fontSize:`var(--eds_button__font_size, ${x_.fontSize})`},border:{type:"border",width:"var(--eds_button__border_width, 1px)",color:"transparent",radius:`var(--eds_button__radius, ${mS})`,style:"solid"},spacings:{top:"var(--eds_button__padding_y, 0)",bottom:"var(--eds_button__padding_y, 0)",left:`var(--eds_button__padding_x, ${fS})`,right:`var(--eds_button__padding_x, ${fS})`},clickbound:{height:yS,width:"100%",offset:{top:`${(parseInt(yS)-parseInt(pS))/2+1}px`,left:"0"}},entities:{icon:{height:"var(--eds_button__icon__size, 24px)",width:"var(--eds_button__icon__size, 24px)"}},states:{hover:{border:{type:"border",width:"1px",color:"transparent",radius:`var(--eds_button__radius, ${mS})`,style:"solid"}},focus:{outline:{type:"outline",offset:"3px",style:"dashed",color:gS.color,width:gS.width}},disabled:{background:kJ,border:{type:"border",width:"1px",color:CJ,style:"solid"},typography:{...x_,color:xJ,textAlign:"center"}}},modes:{compact:{height:`var(--eds_button__height_compact, ${vS})`,spacings:{top:"var(--eds_button__padding_y_compact, 0)",bottom:"var(--eds_button__padding_y_compact, 0)"},clickbound:{height:_S,width:"100%",offset:{top:`${(parseInt(_S)-parseInt(vS))/2+1}px`,left:"0"}}}}};function Qr(r){return r!=null&&typeof r=="object"&&r["@@functional/placeholder"]===!0}function Kd(r){return function e(t){return arguments.length===0||Qr(t)?e:r.apply(this,arguments)}}function Hd(r){return function e(t,n){switch(arguments.length){case 0:return e;case 1:return Qr(t)?e:Kd(function(i){return r(t,i)});default:return Qr(t)&&Qr(n)?e:Qr(t)?Kd(function(i){return r(i,n)}):Qr(n)?Kd(function(i){return r(t,i)}):r(t,n)}}}function A$(r){return function e(t,n,i){switch(arguments.length){case 0:return e;case 1:return Qr(t)?e:Hd(function(o,a){return r(t,o,a)});case 2:return Qr(t)&&Qr(n)?e:Qr(t)?Hd(function(o,a){return r(o,n,a)}):Qr(n)?Hd(function(o,a){return r(t,o,a)}):Kd(function(o){return r(t,n,o)});default:return Qr(t)&&Qr(n)&&Qr(i)?e:Qr(t)&&Qr(n)?Hd(function(o,a){return r(o,a,i)}):Qr(t)&&Qr(i)?Hd(function(o,a){return r(o,n,a)}):Qr(n)&&Qr(i)?Hd(function(o,a){return r(t,o,a)}):Qr(t)?Kd(function(o){return r(o,n,i)}):Qr(n)?Kd(function(o){return r(t,o,i)}):Qr(i)?Kd(function(o){return r(t,n,o)}):r(t,n,i)}}}function bS(r){return Object.prototype.toString.call(r)==="[object Object]"}function V0(r,e){return Object.prototype.hasOwnProperty.call(e,r)}var EJ=A$(function(e,t,n){var i={},o;t=t||{},n=n||{};for(o in t)V0(o,t)&&(i[o]=V0(o,n)?e(o,t[o],n[o]):t[o]);for(o in n)V0(o,n)&&!V0(o,i)&&(i[o]=n[o]);return i}),SJ=A$(function r(e,t,n){return EJ(function(i,o,a){return bS(o)&&bS(a)?r(e,o,a):e(i,o,a)},t,n)}),zi=Hd(function(e,t){return SJ(function(n,i,o){return o},e,t)});const{colors:{text:{static_icons__primary_white:{rgba:TJ}},interactive:{primary__resting:{rgba:wS},primary__hover:{rgba:AJ},secondary__resting:{rgba:xS},secondary__link_hover:{rgba:CS},danger__resting:{rgba:kS},danger__hover:{rgba:ES}}},shape:{button:{borderRadius:IJ}}}=Xe,P4=zi(R4,{background:wS,typography:{color:TJ},border:{type:"border",style:"solid",width:"1px",color:wS,radius:`var(--eds_button__radius, ${IJ})`},states:{hover:{background:AJ}}}),I$=zi(P4,{background:xS,border:{color:xS},states:{hover:{background:CS,border:{color:CS}}}}),R$=zi(P4,{background:kS,border:{color:kS},states:{hover:{background:ES,border:{color:ES}}}}),{colors:{interactive:{primary__resting:{rgba:SS},primary__hover:{rgba:TS},primary__hover_alt:{rgba:RJ},secondary__resting:{rgba:AS},secondary__link_hover:{rgba:IS},secondary__highlight:{rgba:PJ},danger__resting:{rgba:RS},danger__hover:{rgba:PS},danger__highlight:{rgba:MJ}}},shape:{button:{borderRadius:$J}}}=Xe,g8=zi(R4,{typography:{color:SS},border:{type:"border",style:"solid",width:"1px",color:SS,radius:`var(--eds_button__radius, ${$J})`},states:{hover:{typography:{color:TS},background:RJ,border:{style:"solid",type:"border",width:"1px",color:TS}},disabled:{background:"transparent"}}}),OJ=zi(g8,{typography:{color:AS},border:{color:AS},states:{hover:{background:PJ,typography:{color:IS},border:{color:IS}}}}),ZJ=zi(g8,{typography:{color:RS},border:{color:RS},states:{hover:{background:MJ,typography:{color:PS},border:{color:PS}}}}),{colors:{interactive:{primary__resting:{rgba:LJ},primary__hover:{rgba:HJ},primary__hover_alt:{rgba:NJ},secondary__resting:{rgba:DJ},secondary__link_hover:{rgba:VJ},secondary__highlight:{rgba:FJ},danger__resting:{rgba:jJ},danger__hover:{rgba:zJ},danger__highlight:{rgba:BJ}}}}=Xe,y8=zi(R4,{typography:{color:LJ},states:{hover:{background:NJ,typography:{color:HJ}},disabled:{background:"transparent",border:{color:"transparent"}}}}),UJ=zi(y8,{typography:{color:DJ},states:{hover:{background:FJ,typography:{color:VJ}}}}),qJ=zi(y8,{typography:{color:jJ},states:{hover:{background:BJ,typography:{color:zJ}}}}),{colors:{interactive:{primary__resting:{rgba:WJ},primary__hover_alt:{rgba:GJ},secondary__resting:{rgba:KJ},secondary__link_hover:{rgba:YJ},secondary__highlight:{rgba:QJ},danger__resting:{rgba:XJ},danger__hover:{rgba:JJ},danger__highlight:{rgba:eee}}},clickbounds:{default__base:C_,compact__standard:MS},shape:Cd,interactions:{focused:{width:tee}}}=Xe,_8=zi(R4,{height:Cd.icon_button.minHeight,width:Cd.icon_button.minWidth,typography:{color:WJ},border:{width:"0px",radius:"50%"},background:"transparent",spacings:{left:"0",right:"0"},clickbound:{width:C_,offset:{top:`${(parseInt(C_)-parseInt(Cd.icon_button.minWidth))/2}px`,left:`${(parseInt(C_)-parseInt(Cd.icon_button.minWidth))/2}px`}},states:{hover:{background:GJ,border:{width:"0px",radius:"50%"}},disabled:{background:"transparent",border:{color:"transparent"}},focus:{outline:{offset:`-${parseInt(tee)}px`}}},modes:{compact:{height:Cd._modes.compact.icon_button.minHeight,width:Cd._modes.compact.icon_button.minWidth,clickbound:{width:MS,offset:{top:"0",left:`${(parseInt(MS)-parseInt(Cd._modes.compact.icon_button.minWidth))/2}px`}}}}}),ree=zi(_8,{typography:{color:KJ},states:{hover:{background:QJ,typography:{color:YJ}}}}),nee=zi(_8,{typography:{color:XJ},states:{hover:{background:eee,typography:{color:JJ}}}}),{clickbounds:{default__base:k_,compact__standard:$S},shape:kd}=Xe,b8={height:kd.icon_button.minHeight,width:kd.icon_button.minWidth,border:{width:"0px",radius:"50%"},spacings:{left:"0",right:"0"},clickbound:{width:k_,offset:{top:`${(parseInt(k_)-parseInt(kd.icon_button.minWidth))/2}px`,left:`${(parseInt(k_)-parseInt(kd.icon_button.minWidth))/2}px`}},states:{hover:{border:{width:"0px",radius:"50%"}}},modes:{compact:{height:kd._modes.compact.icon_button.minHeight,width:kd._modes.compact.icon_button.minWidth,clickbound:{width:$S,offset:{top:"0",left:`${(parseInt($S)-parseInt(kd._modes.compact.icon_button.minWidth))/2}px`}}}}},iee=zi(P4,b8),oee=zi(I$,b8),aee=zi(R$,b8),E_={primary:{contained:P4,outlined:g8,ghost:y8,ghost_icon:_8,contained_icon:iee},secondary:{contained:I$,outlined:OJ,ghost:UJ,ghost_icon:ree,contained_icon:oee},danger:{contained:R$,outlined:ZJ,ghost:qJ,ghost_icon:nee,contained_icon:aee}},see=(r,e)=>{x.useEffect(()=>{const t=n=>{const{key:i}=n;switch(i){case r:e(n);break}};return document.addEventListener("keydown",t,!0),()=>{document.removeEventListener("keydown",t,!0)}},[r,e])};let cee=0;const P$=(r,e)=>{const[t,n]=x.useState(r),i=r||t;return x.useEffect(()=>{t==null&&n(`eds-${e?e+"-":""}${cee++}`)},[t,e]),i},lee=r=>{const e=x.useRef();x.useEffect(()=>{if(typeof document>"u")return;const t=document.documentElement,{body:n}=document;if(r){const o=window.innerWidth-t.clientWidth,a=parseInt(window.getComputedStyle(n).getPropertyValue("padding-right"))||0,c={overflow:n.style.overflow,paddingRight:n.style.paddingRight};e.current=c,n.style.overflow="hidden",n.style.paddingRight=`${a+o}px`}else e.current&&(n.style.overflow=e.current.overflow,n.style.paddingRight=e.current.paddingRight);const i=e.current;return()=>{n.style.overflow=i==null?void 0:i.overflow,n.style.paddingRight=i==null?void 0:i.paddingRight}},[r])};function Xr(r){return r!=null&&typeof r=="object"&&r["@@functional/placeholder"]===!0}function Yd(r){return function e(t){return arguments.length===0||Xr(t)?e:r.apply(this,arguments)}}function Nd(r){return function e(t,n){switch(arguments.length){case 0:return e;case 1:return Xr(t)?e:Yd(function(i){return r(t,i)});default:return Xr(t)&&Xr(n)?e:Xr(t)?Yd(function(i){return r(i,n)}):Xr(n)?Yd(function(i){return r(t,i)}):r(t,n)}}}function M$(r){return function e(t,n,i){switch(arguments.length){case 0:return e;case 1:return Xr(t)?e:Nd(function(o,a){return r(t,o,a)});case 2:return Xr(t)&&Xr(n)?e:Xr(t)?Nd(function(o,a){return r(o,n,a)}):Xr(n)?Nd(function(o,a){return r(t,o,a)}):Yd(function(o){return r(t,n,o)});default:return Xr(t)&&Xr(n)&&Xr(i)?e:Xr(t)&&Xr(n)?Nd(function(o,a){return r(o,a,i)}):Xr(t)&&Xr(i)?Nd(function(o,a){return r(o,n,a)}):Xr(n)&&Xr(i)?Nd(function(o,a){return r(t,o,a)}):Xr(t)?Yd(function(o){return r(o,n,i)}):Xr(n)?Yd(function(o){return r(t,o,i)}):Xr(i)?Yd(function(o){return r(t,n,o)}):r(t,n,i)}}}function OS(r){return Object.prototype.toString.call(r)==="[object Object]"}function F0(r,e){return Object.prototype.hasOwnProperty.call(e,r)}var dee=M$(function(e,t,n){var i={},o;t=t||{},n=n||{};for(o in t)F0(o,t)&&(i[o]=F0(o,n)?e(o,t[o],n[o]):t[o]);for(o in n)F0(o,n)&&!F0(o,i)&&(i[o]=n[o]);return i}),uee=M$(function r(e,t,n){return dee(function(i,o,a){return OS(o)&&OS(a)?r(e,o,a):e(i,o,a)},t,n)}),hee=Nd(function(e,t){return uee(function(n,i,o){return o},e,t)});const M4=(r,e)=>x.useCallback(()=>{const{density:t}=r;return t==="compact"?hee(e,e.modes.compact):e},[r,e]),ym=(...r)=>e=>r.forEach(t=>{typeof t=="function"?t(e):t&&typeof t=="object"&&(t.current=e)}),Fh=r=>{if(!r)return;const{width:e="",style:t="",color:n=""}=r;return e?`${e} ${t} ${n}`:null},mc=r=>{var e,t,n,i;if(!r)return wr({});switch(r.type){case"border":return wr({border:Fh(r),borderRadius:r.radius});case"bordergroup":return wr({borderBottom:Fh(r.bottom),borderTop:Fh(r.top),borderLeft:Fh(r.left),borderRight:Fh(r.right),borderBottomLeftRadius:(e=r==null?void 0:r.left)==null?void 0:e.radius,borderTopLeftRadius:(t=r==null?void 0:r.left)==null?void 0:t.radius,borderBottomRightRadius:(n=r==null?void 0:r.right)==null?void 0:n.radius,borderTopRightRadius:(i=r==null?void 0:r.right)==null?void 0:i.radius});default:return wr({})}},{colors:{interactive:{focus:{rgba:fee}}}}=Xe,sa=r=>{const{color:e=fee,style:t="dashed",width:n="2px",offset:i="0px",type:o}=r,a={color:e,style:t,width:n,offset:i};return wr({outline:Fh(a),outlineOffset:a.offset})},Ol=(r,e)=>{if(!r)return"";let t=`
448
448
  margin: 0;
449
449
  color: ${r.color};
@@ -1941,7 +1941,7 @@ cursor: pointer;`),t},Km=({left:r,right:e,top:t,bottom:n})=>wr({paddingLeft:r,pa
1941
1941
  <div id="graphic">${this.renderGraphic()}</div>
1942
1942
  <div id="content">${this.renderContent()}</div>
1943
1943
  <div id="remove" @click=${this.handleRemoveOnClick}>${this.renderRemoveIcon()}</div>
1944
- </div>`}handleOnClick(e){this.clickable&&this.dispatchEvent(new PointerEvent("click",e))}handleRemoveOnClick(e){e.stopPropagation(),this.removable&&this.dispatchEvent(new PointerEvent("remove",e))}}R([se({type:String,reflect:!0})],ha.prototype,"size",void 0);R([se({type:String,reflect:!0})],ha.prototype,"variant",void 0);R([se({type:String,reflect:!0})],ha.prototype,"color",void 0);R([se({type:String})],ha.prototype,"value",void 0);R([se({type:String,reflect:!0})],ha.prototype,"icon",void 0);R([se({type:String})],ha.prototype,"tooltip",void 0);R([se({type:Boolean,reflect:!0})],ha.prototype,"active",void 0);R([se({type:Boolean,reflect:!0})],ha.prototype,"clickable",void 0);R([se({type:Boolean,reflect:!0})],ha.prototype,"removable",void 0);R([se({type:Boolean,reflect:!0})],ha.prototype,"disabled",void 0);ha.styles=Q0e;const X0e="fwc-chip";let WT=class extends ha{};WT=R([Cr(X0e)],WT);function J0e(r){return r.charAt(0).toUpperCase()+r.slice(1).toLowerCase()}const GT=r=>r.map(e=>{const t={id:e.id,title:e.title,subTitle:e.subTitle??e.type.id,graphic:e.graphic,meta:e.meta};switch(e.type.id){case"EquinorTask":return{...t,meta:e.value.taskState&&e.value.taskState!=="Active"?`<fwc-chip disabled variant="outlined" value="${e.value.taskState}" />`:""};case"OrgChart":return{...t,graphic:"list",meta:e.value.state&&e.value.state.toLowerCase()!=="active"?`<fwc-chip disabled variant="outlined" value="${J0e(e.value.state)}" />`:""};default:return t}}),Q0=r=>Object.assign({id:"no-such-item",title:"Change me"},r),eve=()=>{const r=Ll(),{currentApp:e}=U8(),t=x.useMemo(()=>(e==null?void 0:e.instance$)||Tr,[e]),[n,i]=x.useState(null),{value:o}=ks(x.useMemo(()=>(n==null?void 0:n.currentContext$)||Tr,[n])),a=x.useMemo(()=>o?GT([o]):[],[o]),c=x.useCallback(v=>{const g=v.context;i(g||null)},[]),d=x.useCallback(()=>{i(null)},[]);bM(t,c,d),x.useEffect(()=>r.modules.event.addEventListener("onReactAppLoaded",v=>(console.debug("useContextResolver::onReactAppLoaded","using legacy register hack method"),c(v.detail.modules))),[r,c]);const h=x.useCallback(v=>{if(v.name==="QueryClientError")return h(v.cause);if(v.name==="FusionContextSearchError"){const g=v;return[Q0({id:g.name,title:g.title,subTitle:g.description,graphic:"error_outlined",isDisabled:!0})]}return[Q0({title:"Unexpected error occurred",subTitle:"Please try again or report the issue in Services@Equinor",graphic:"error_outlined",isDisabled:!0})]},[]),u=2;return{resolver:x.useMemo(()=>n&&{searchQuery:async v=>{if(v.length<u)return[Q0({id:"min-length",title:`Type ${u-v.length} more chars to search`,isDisabled:!0})];try{return lr(n.queryContext(v).pipe(me(GT),me(g=>g.length?g:[Q0({id:"no-results",title:"No results found",graphic:"info_circle",isDisabled:!0})]),Vt(g=>(console.error("PORTAL::ContextResolver",`failed to resolve context for query ${v}`,g,g.cause),It(h(g))))))}catch(g){const _=g;return console.error("PORTAL::ContextResolver",`unhandled error for [${v}]`,g),h(_)}},initialResult:a},[n,a,h]),provider:n,currentContext:a}},tve=r=>{const{resolver:e,provider:t,currentContext:[n]}=eve(),i=x.useCallback(a=>{if(t)if(a.type==="select"){const c=a;c.nativeEvent.detail.selected.length&&t.contextClient.setCurrentContext(c.nativeEvent.detail.selected[0].id)}else t.clearCurrentContext()},[t]),o=x.useMemo(()=>new G4({date:Date.now()}),[]);return x.useEffect(()=>{n||document.dispatchEvent(o)},[o,n]),e?k.jsx("div",{style:{flex:1,maxWidth:"480px"},children:k.jsx(B0e,{resolver:e,children:k.jsx(W0e,{id:"context-selector-cli-header",placeholder:r.placeholder??"Search for context",initialText:r.initialText??"Start typing to search",dropdownHeight:r.dropdownHeight??"300px",variant:r.variant??"header",onSelect:a=>i(a),selectTextOnFocus:!0,previewItem:n,onClearContext:i})})}):null},rve=({scale:r=1,style:e})=>k.jsxs("svg",{viewBox:"0 0 50 35",style:{height:"1em",...e,transform:`scale(${r})`},children:[k.jsx("title",{children:"Fusion Logo"}),k.jsx("path",{d:"M0 2V23.1776L7.05405 16.1235V7.05405H16.1235L23.1776 0H2C0.895431 0 0 0.89543 0 2Z",transform:"translate(50 17.5) scale(0.92727 1.06779) rotate(135)",fill:"url(#paint0_linear)"}),k.jsx("path",{d:"M0 2V23.1776L7.05405 16.1235V7.05405H16.1235L23.1776 0H2C0.895431 0 0 0.89543 0 2Z",transform:"translate(0 17.5) scale(0.92727 1.06779) rotate(-45)",fill:"url(#paint1_linear)"}),k.jsx("path",{d:"M9.61965 36.6972L2.60087 29.6784L1.96135 22.3809L8.42623 22.9069L9.61965 36.6972Z",transform:"translate(33.8887 34.9863) scale(0.92727 -1.06779) rotate(45)",fill:"#990025"}),k.jsx("path",{d:"M7.05434 7.05434L0 0L1.21096 13.8183L7.68846 14.3818L7.05434 7.05434Z",transform:"translate(33.8887 34.9863) scale(0.92727 -1.06779) rotate(45)",fill:"#990025"}),k.jsx("path",{d:"M0 0L2.49398 29.5715L9.61965 36.6972L7.01878 7.01878L0 0Z",transform:"translate(33.8887 0.015625) scale(0.92727 1.06779) rotate(45)",fill:"#FF1243"}),k.jsxs("defs",{children:[k.jsxs("linearGradient",{id:"paint0_linear",x2:"1",gradientUnits:"userSpaceOnUse",gradientTransform:"matrix(-13.5478 9.01983 -12.9578 -13.5478 18.0677 6.77391)",children:[k.jsx("stop",{offset:"0.508287",stopColor:"#DC002E"}),k.jsx("stop",{offset:"0.508387",stopColor:"#FF1243"})]}),k.jsxs("linearGradient",{id:"paint1_linear",x2:"1",gradientUnits:"userSpaceOnUse",gradientTransform:"matrix(-13.5478 9.01983 -12.9578 -13.5478 18.0677 6.77391)",children:[k.jsx("stop",{offset:"0.508287",stopColor:"#DC002E"}),k.jsx("stop",{offset:"0.508387",stopColor:"#FF1243"})]})]})]}),kO=()=>Ll().modules.auth.defaultAccount,KT={"Group by app":r=>r.appKey,"Created by":r=>r.createdBy.name,"Group by Context":r=>{var e,t;return(t=(e=r==null?void 0:r.context)===null||e===void 0?void 0:e.name)!==null&&t!==void 0?t:"Unknown"}},nve=r=>{const[e,t]=x.useState(null),[n,i]=x.useState("Group by app"),o=ive(r||[],KT[n],e,"name");return{setGroupBy:i,setSearchText:t,searchText:e,bookmarkGroups:o,groupingModes:KT,groupByKey:n}},ive=(r,e,t,n)=>{var i;return(i=r==null?void 0:r.map(e).filter((o,a,c)=>c.indexOf(o)===a).map(o=>({groupingProperty:o,values:r.filter(a=>e(a)===o).filter(a=>{const c=a[n];return typeof c=="string"&&t?c.includes(t):!0})})))!==null&&i!==void 0?i:[]};var bo={},Of=typeof process<"u"&&bo!==void 0&&(bo.REACT_APP_SC_ATTR||bo.SC_ATTR)||"data-styled",EO="active",SO="data-styled-version",K4="6.1.15",q8=`/*!sc*/
1944
+ </div>`}handleOnClick(e){this.clickable&&this.dispatchEvent(new PointerEvent("click",e))}handleRemoveOnClick(e){e.stopPropagation(),this.removable&&this.dispatchEvent(new PointerEvent("remove",e))}}R([se({type:String,reflect:!0})],ha.prototype,"size",void 0);R([se({type:String,reflect:!0})],ha.prototype,"variant",void 0);R([se({type:String,reflect:!0})],ha.prototype,"color",void 0);R([se({type:String})],ha.prototype,"value",void 0);R([se({type:String,reflect:!0})],ha.prototype,"icon",void 0);R([se({type:String})],ha.prototype,"tooltip",void 0);R([se({type:Boolean,reflect:!0})],ha.prototype,"active",void 0);R([se({type:Boolean,reflect:!0})],ha.prototype,"clickable",void 0);R([se({type:Boolean,reflect:!0})],ha.prototype,"removable",void 0);R([se({type:Boolean,reflect:!0})],ha.prototype,"disabled",void 0);ha.styles=Q0e;const X0e="fwc-chip";let WT=class extends ha{};WT=R([Cr(X0e)],WT);function J0e(r){return r.charAt(0).toUpperCase()+r.slice(1).toLowerCase()}const GT=r=>r.map(e=>{const t={id:e.id,title:e.title,subTitle:e.subTitle??e.type.id,graphic:e.graphic,meta:e.meta};switch(e.type.id){case"EquinorTask":return{...t,meta:e.value.taskState&&e.value.taskState!=="Active"?`<fwc-chip disabled variant="outlined" value="${e.value.taskState}" />`:""};case"OrgChart":return{...t,graphic:"list",meta:e.value.state&&e.value.state.toLowerCase()!=="active"?`<fwc-chip disabled variant="outlined" value="${J0e(e.value.state)}" />`:""};default:return t}}),Q0=r=>Object.assign({id:"no-such-item",title:"Change me"},r),eve=()=>{const r=Ll(),{currentApp:e}=U8(),t=x.useMemo(()=>(e==null?void 0:e.instance$)||Tr,[e]),[n,i]=x.useState(null),{value:o}=ks(x.useMemo(()=>(n==null?void 0:n.currentContext$)||Tr,[n])),a=x.useMemo(()=>o?GT([o]):[],[o]),c=x.useCallback(v=>{const g=v.context;i(g||null)},[]),d=x.useCallback(()=>{i(null)},[]);bM(t,c,d),x.useEffect(()=>r.modules.event.addEventListener("onReactAppLoaded",v=>(console.debug("useContextResolver::onReactAppLoaded","using legacy register hack method"),c(v.detail.modules))),[r,c]);const h=x.useCallback(v=>{if(v.name==="QueryClientError")return h(v.cause);if(v.name==="FusionContextSearchError"){const g=v;return[Q0({id:g.name,title:g.title,subTitle:g.description,graphic:"error_outlined",isDisabled:!0})]}return[Q0({title:"Unexpected error occurred",subTitle:"Please try again or report the issue in Services@Equinor",graphic:"error_outlined",isDisabled:!0})]},[]),u=2;return{resolver:x.useMemo(()=>n&&{searchQuery:async v=>{if(v.length<u)return[Q0({id:"min-length",title:`Type ${u-v.length} more chars to search`,isDisabled:!0})];try{return lr(n.queryContext(v).pipe(me(GT),me(g=>g.length?g:[Q0({id:"no-results",title:"No results found",graphic:"info_circle",isDisabled:!0})]),Vt(g=>(console.error("PORTAL::ContextResolver",`failed to resolve context for query ${v}`,g,g.cause),It(h(g))))))}catch(g){const _=g;return console.error("PORTAL::ContextResolver",`unhandled error for [${v}]`,g),h(_)}},initialResult:a},[n,a,h]),provider:n,currentContext:a}},tve=r=>{const{resolver:e,provider:t,currentContext:[n]}=eve(),i=x.useCallback(a=>{if(t)if(a.type==="select"){const c=a;c.nativeEvent.detail.selected.length&&t.contextClient.setCurrentContext(c.nativeEvent.detail.selected[0].id)}else t.clearCurrentContext()},[t]),o=x.useMemo(()=>new G4({date:Date.now()}),[]);return x.useEffect(()=>{n||document.dispatchEvent(o)},[o,n]),e?k.jsx("div",{style:{flex:1,maxWidth:"480px"},children:k.jsx(B0e,{resolver:e,children:k.jsx(W0e,{id:"context-selector-cli-header",placeholder:r.placeholder??"Search for context",initialText:r.initialText??"Start typing to search",dropdownHeight:r.dropdownHeight??"300px",variant:r.variant??"header",onSelect:a=>i(a),selectTextOnFocus:!0,previewItem:n,onClearContext:i})})}):null},rve=({scale:r=1,style:e})=>k.jsxs("svg",{viewBox:"0 0 50 35",style:{height:"1em",...e,transform:`scale(${r})`},children:[k.jsx("title",{children:"Fusion Logo"}),k.jsx("path",{d:"M0 2V23.1776L7.05405 16.1235V7.05405H16.1235L23.1776 0H2C0.895431 0 0 0.89543 0 2Z",transform:"translate(50 17.5) scale(0.92727 1.06779) rotate(135)",fill:"url(#paint0_linear)"}),k.jsx("path",{d:"M0 2V23.1776L7.05405 16.1235V7.05405H16.1235L23.1776 0H2C0.895431 0 0 0.89543 0 2Z",transform:"translate(0 17.5) scale(0.92727 1.06779) rotate(-45)",fill:"url(#paint1_linear)"}),k.jsx("path",{d:"M9.61965 36.6972L2.60087 29.6784L1.96135 22.3809L8.42623 22.9069L9.61965 36.6972Z",transform:"translate(33.8887 34.9863) scale(0.92727 -1.06779) rotate(45)",fill:"#990025"}),k.jsx("path",{d:"M7.05434 7.05434L0 0L1.21096 13.8183L7.68846 14.3818L7.05434 7.05434Z",transform:"translate(33.8887 34.9863) scale(0.92727 -1.06779) rotate(45)",fill:"#990025"}),k.jsx("path",{d:"M0 0L2.49398 29.5715L9.61965 36.6972L7.01878 7.01878L0 0Z",transform:"translate(33.8887 0.015625) scale(0.92727 1.06779) rotate(45)",fill:"#FF1243"}),k.jsxs("defs",{children:[k.jsxs("linearGradient",{id:"paint0_linear",x2:"1",gradientUnits:"userSpaceOnUse",gradientTransform:"matrix(-13.5478 9.01983 -12.9578 -13.5478 18.0677 6.77391)",children:[k.jsx("stop",{offset:"0.508287",stopColor:"#DC002E"}),k.jsx("stop",{offset:"0.508387",stopColor:"#FF1243"})]}),k.jsxs("linearGradient",{id:"paint1_linear",x2:"1",gradientUnits:"userSpaceOnUse",gradientTransform:"matrix(-13.5478 9.01983 -12.9578 -13.5478 18.0677 6.77391)",children:[k.jsx("stop",{offset:"0.508287",stopColor:"#DC002E"}),k.jsx("stop",{offset:"0.508387",stopColor:"#FF1243"})]})]})]}),kO=()=>Ll().modules.auth.defaultAccount,KT={"Group by app":r=>r.appKey,"Created by":r=>r.createdBy.name,"Group by Context":r=>{var e,t;return(t=(e=r==null?void 0:r.context)===null||e===void 0?void 0:e.name)!==null&&t!==void 0?t:"Unknown"}},nve=r=>{const[e,t]=x.useState(null),[n,i]=x.useState("Group by app"),o=ive(r||[],KT[n],e,"name");return{setGroupBy:i,setSearchText:t,searchText:e,bookmarkGroups:o,groupingModes:KT,groupByKey:n}},ive=(r,e,t,n)=>{var i;return(i=r==null?void 0:r.map(e).filter((o,a,c)=>c.indexOf(o)===a).map(o=>({groupingProperty:o,values:r.filter(a=>e(a)===o).filter(a=>{const c=a[n];return typeof c=="string"&&t?c.includes(t):!0})})))!==null&&i!==void 0?i:[]};var bo={},Of=typeof process<"u"&&bo!==void 0&&(bo.REACT_APP_SC_ATTR||bo.SC_ATTR)||"data-styled",EO="active",SO="data-styled-version",K4="6.1.16",q8=`/*!sc*/
1945
1945
  `,Xg=typeof window<"u"&&"HTMLElement"in window,ove=!!(typeof SC_DISABLE_SPEEDY=="boolean"?SC_DISABLE_SPEEDY:typeof process<"u"&&bo!==void 0&&bo.REACT_APP_SC_DISABLE_SPEEDY!==void 0&&bo.REACT_APP_SC_DISABLE_SPEEDY!==""?bo.REACT_APP_SC_DISABLE_SPEEDY!=="false"&&bo.REACT_APP_SC_DISABLE_SPEEDY:typeof process<"u"&&bo!==void 0&&bo.SC_DISABLE_SPEEDY!==void 0&&bo.SC_DISABLE_SPEEDY!==""&&bo.SC_DISABLE_SPEEDY!=="false"&&bo.SC_DISABLE_SPEEDY),Y4=Object.freeze([]),Zf=Object.freeze({});function ave(r,e,t){return t===void 0&&(t=Zf),r.theme!==t.theme&&r.theme||e||t.theme}var TO=new Set(["a","abbr","address","area","article","aside","audio","b","base","bdi","bdo","big","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","data","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","header","hgroup","hr","html","i","iframe","img","input","ins","kbd","keygen","label","legend","li","link","main","map","mark","menu","menuitem","meta","meter","nav","noscript","object","ol","optgroup","option","output","p","param","picture","pre","progress","q","rp","rt","ruby","s","samp","script","section","select","small","source","span","strong","style","sub","summary","sup","table","tbody","td","textarea","tfoot","th","thead","time","tr","track","u","ul","use","var","video","wbr","circle","clipPath","defs","ellipse","foreignObject","g","image","line","linearGradient","marker","mask","path","pattern","polygon","polyline","radialGradient","rect","stop","svg","text","tspan"]),sve=/[!"#$%&'()*+,./:;<=>?@[\\\]^`{|}~-]+/g,cve=/(^-|-$)/g;function YT(r){return r.replace(sve,"-").replace(cve,"")}var lve=/(a)(d)/gi,X0=52,QT=function(r){return String.fromCharCode(r+(r>25?39:97))};function Gw(r){var e,t="";for(e=Math.abs(r);e>X0;e=e/X0|0)t=QT(e%X0)+t;return(QT(e%X0)+t).replace(lve,"$1-$2")}var G_,AO=5381,rf=function(r,e){for(var t=e.length;t;)r=33*r^e.charCodeAt(--t);return r},IO=function(r){return rf(AO,r)};function RO(r){return Gw(IO(r)>>>0)}function dve(r){return r.displayName||r.name||"Component"}function K_(r){return typeof r=="string"&&!0}var PO=typeof Symbol=="function"&&Symbol.for,MO=PO?Symbol.for("react.memo"):60115,uve=PO?Symbol.for("react.forward_ref"):60112,hve={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},fve={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},$O={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},pve=((G_={})[uve]={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},G_[MO]=$O,G_);function XT(r){return("type"in(e=r)&&e.type.$$typeof)===MO?$O:"$$typeof"in r?pve[r.$$typeof]:hve;var e}var mve=Object.defineProperty,vve=Object.getOwnPropertyNames,JT=Object.getOwnPropertySymbols,gve=Object.getOwnPropertyDescriptor,yve=Object.getPrototypeOf,eA=Object.prototype;function OO(r,e,t){if(typeof e!="string"){if(eA){var n=yve(e);n&&n!==eA&&OO(r,n,t)}var i=vve(e);JT&&(i=i.concat(JT(e)));for(var o=XT(r),a=XT(e),c=0;c<i.length;++c){var d=i[c];if(!(d in fve||t&&t[d]||a&&d in a||o&&d in o)){var h=gve(e,d);try{mve(r,d,h)}catch{}}}}return r}function $u(r){return typeof r=="function"}function W8(r){return typeof r=="object"&&"styledComponentId"in r}function Jd(r,e){return r&&e?"".concat(r," ").concat(e):r||e||""}function Kw(r,e){if(r.length===0)return"";for(var t=r[0],n=1;n<r.length;n++)t+=r[n];return t}function Cm(r){return r!==null&&typeof r=="object"&&r.constructor.name===Object.name&&!("props"in r&&r.$$typeof)}function Yw(r,e,t){if(t===void 0&&(t=!1),!t&&!Cm(r)&&!Array.isArray(r))return e;if(Array.isArray(e))for(var n=0;n<e.length;n++)r[n]=Yw(r[n],e[n]);else if(Cm(e))for(var n in e)r[n]=Yw(r[n],e[n]);return r}function G8(r,e){Object.defineProperty(r,"toString",{value:e})}function Ou(r){for(var e=[],t=1;t<arguments.length;t++)e[t-1]=arguments[t];return new Error("An error occurred. See https://github.com/styled-components/styled-components/blob/main/packages/styled-components/src/utils/errors.md#".concat(r," for more information.").concat(e.length>0?" Args: ".concat(e.join(", ")):""))}var _ve=function(){function r(e){this.groupSizes=new Uint32Array(512),this.length=512,this.tag=e}return r.prototype.indexOfGroup=function(e){for(var t=0,n=0;n<e;n++)t+=this.groupSizes[n];return t},r.prototype.insertRules=function(e,t){if(e>=this.groupSizes.length){for(var n=this.groupSizes,i=n.length,o=i;e>=o;)if((o<<=1)<0)throw Ou(16,"".concat(e));this.groupSizes=new Uint32Array(o),this.groupSizes.set(n),this.length=o;for(var a=i;a<o;a++)this.groupSizes[a]=0}for(var c=this.indexOfGroup(e+1),d=(a=0,t.length);a<d;a++)this.tag.insertRule(c,t[a])&&(this.groupSizes[e]++,c++)},r.prototype.clearGroup=function(e){if(e<this.length){var t=this.groupSizes[e],n=this.indexOfGroup(e),i=n+t;this.groupSizes[e]=0;for(var o=n;o<i;o++)this.tag.deleteRule(n)}},r.prototype.getGroup=function(e){var t="";if(e>=this.length||this.groupSizes[e]===0)return t;for(var n=this.groupSizes[e],i=this.indexOfGroup(e),o=i+n,a=i;a<o;a++)t+="".concat(this.tag.getRule(a)).concat(q8);return t},r}(),Uv=new Map,Jg=new Map,qv=1,J0=function(r){if(Uv.has(r))return Uv.get(r);for(;Jg.has(qv);)qv++;var e=qv++;return Uv.set(r,e),Jg.set(e,r),e},bve=function(r,e){qv=e+1,Uv.set(r,e),Jg.set(e,r)},wve="style[".concat(Of,"][").concat(SO,'="').concat(K4,'"]'),xve=new RegExp("^".concat(Of,'\\.g(\\d+)\\[id="([\\w\\d-]+)"\\].*?"([^"]*)')),Cve=function(r,e,t){for(var n,i=t.split(","),o=0,a=i.length;o<a;o++)(n=i[o])&&r.registerName(e,n)},kve=function(r,e){for(var t,n=((t=e.textContent)!==null&&t!==void 0?t:"").split(q8),i=[],o=0,a=n.length;o<a;o++){var c=n[o].trim();if(c){var d=c.match(xve);if(d){var h=0|parseInt(d[1],10),u=d[2];h!==0&&(bve(u,h),Cve(r,u,d[3]),r.getTag().insertRules(h,i)),i.length=0}else i.push(c)}}},tA=function(r){for(var e=document.querySelectorAll(wve),t=0,n=e.length;t<n;t++){var i=e[t];i&&i.getAttribute(Of)!==EO&&(kve(r,i),i.parentNode&&i.parentNode.removeChild(i))}};function Eve(){return typeof __webpack_nonce__<"u"?__webpack_nonce__:null}var ZO=function(r){var e=document.head,t=r||e,n=document.createElement("style"),i=function(c){var d=Array.from(c.querySelectorAll("style[".concat(Of,"]")));return d[d.length-1]}(t),o=i!==void 0?i.nextSibling:null;n.setAttribute(Of,EO),n.setAttribute(SO,K4);var a=Eve();return a&&n.setAttribute("nonce",a),t.insertBefore(n,o),n},Sve=function(){function r(e){this.element=ZO(e),this.element.appendChild(document.createTextNode("")),this.sheet=function(t){if(t.sheet)return t.sheet;for(var n=document.styleSheets,i=0,o=n.length;i<o;i++){var a=n[i];if(a.ownerNode===t)return a}throw Ou(17)}(this.element),this.length=0}return r.prototype.insertRule=function(e,t){try{return this.sheet.insertRule(t,e),this.length++,!0}catch{return!1}},r.prototype.deleteRule=function(e){this.sheet.deleteRule(e),this.length--},r.prototype.getRule=function(e){var t=this.sheet.cssRules[e];return t&&t.cssText?t.cssText:""},r}(),Tve=function(){function r(e){this.element=ZO(e),this.nodes=this.element.childNodes,this.length=0}return r.prototype.insertRule=function(e,t){if(e<=this.length&&e>=0){var n=document.createTextNode(t);return this.element.insertBefore(n,this.nodes[e]||null),this.length++,!0}return!1},r.prototype.deleteRule=function(e){this.element.removeChild(this.nodes[e]),this.length--},r.prototype.getRule=function(e){return e<this.length?this.nodes[e].textContent:""},r}(),Ave=function(){function r(e){this.rules=[],this.length=0}return r.prototype.insertRule=function(e,t){return e<=this.length&&(this.rules.splice(e,0,t),this.length++,!0)},r.prototype.deleteRule=function(e){this.rules.splice(e,1),this.length--},r.prototype.getRule=function(e){return e<this.length?this.rules[e]:""},r}(),rA=Xg,Ive={isServer:!Xg,useCSSOMInjection:!ove},LO=function(){function r(e,t,n){e===void 0&&(e=Zf),t===void 0&&(t={});var i=this;this.options=vr(vr({},Ive),e),this.gs=t,this.names=new Map(n),this.server=!!e.isServer,!this.server&&Xg&&rA&&(rA=!1,tA(this)),G8(this,function(){return function(o){for(var a=o.getTag(),c=a.length,d="",h=function(p){var v=function(T){return Jg.get(T)}(p);if(v===void 0)return"continue";var g=o.names.get(v),_=a.getGroup(p);if(g===void 0||!g.size||_.length===0)return"continue";var b="".concat(Of,".g").concat(p,'[id="').concat(v,'"]'),C="";g!==void 0&&g.forEach(function(T){T.length>0&&(C+="".concat(T,","))}),d+="".concat(_).concat(b,'{content:"').concat(C,'"}').concat(q8)},u=0;u<c;u++)h(u);return d}(i)})}return r.registerId=function(e){return J0(e)},r.prototype.rehydrate=function(){!this.server&&Xg&&tA(this)},r.prototype.reconstructWithOptions=function(e,t){return t===void 0&&(t=!0),new r(vr(vr({},this.options),e),this.gs,t&&this.names||void 0)},r.prototype.allocateGSInstance=function(e){return this.gs[e]=(this.gs[e]||0)+1},r.prototype.getTag=function(){return this.tag||(this.tag=(e=function(t){var n=t.useCSSOMInjection,i=t.target;return t.isServer?new Ave(i):n?new Sve(i):new Tve(i)}(this.options),new _ve(e)));var e},r.prototype.hasNameForId=function(e,t){return this.names.has(e)&&this.names.get(e).has(t)},r.prototype.registerName=function(e,t){if(J0(e),this.names.has(e))this.names.get(e).add(t);else{var n=new Set;n.add(t),this.names.set(e,n)}},r.prototype.insertRules=function(e,t,n){this.registerName(e,t),this.getTag().insertRules(J0(e),n)},r.prototype.clearNames=function(e){this.names.has(e)&&this.names.get(e).clear()},r.prototype.clearRules=function(e){this.getTag().clearGroup(J0(e)),this.clearNames(e)},r.prototype.clearTag=function(){this.tag=void 0},r}(),Rve=/&/g,Pve=/^\s*\/\/.*$/gm;function HO(r,e){return r.map(function(t){return t.type==="rule"&&(t.value="".concat(e," ").concat(t.value),t.value=t.value.replaceAll(",",",".concat(e," ")),t.props=t.props.map(function(n){return"".concat(e," ").concat(n)})),Array.isArray(t.children)&&t.type!=="@keyframes"&&(t.children=HO(t.children,e)),t})}function Mve(r){var e,t,n,i=Zf,o=i.options,a=o===void 0?Zf:o,c=i.plugins,d=c===void 0?Y4:c,h=function(v,g,_){return _.startsWith(t)&&_.endsWith(t)&&_.replaceAll(t,"").length>0?".".concat(e):v},u=d.slice();u.push(function(v){v.type===Gm&&v.value.includes("&")&&(v.props[0]=v.props[0].replace(Rve,t).replace(n,h))}),a.prefix&&u.push(d$),u.push(s$);var p=function(v,g,_,b){g===void 0&&(g=""),_===void 0&&(_=""),b===void 0&&(b="&"),e=b,t=g,n=new RegExp("\\".concat(t,"\\b"),"g");var C=v.replace(Pve,""),T=o$(_||g?"".concat(_," ").concat(g," { ").concat(C," }"):C);a.namespace&&(T=HO(T,a.namespace));var S=[];return vm(T,c$(u.concat(l$(function(A){return S.push(A)})))),S};return p.hash=d.length?d.reduce(function(v,g){return g.name||Ou(15),rf(v,g.name)},AO).toString():"",p}var $ve=new LO,Qw=Mve(),NO=or.createContext({shouldForwardProp:void 0,styleSheet:$ve,stylis:Qw});NO.Consumer;or.createContext(void 0);function nA(){return x.useContext(NO)}var DO=function(){function r(e,t){var n=this;this.inject=function(i,o){o===void 0&&(o=Qw);var a=n.name+o.hash;i.hasNameForId(n.id,a)||i.insertRules(n.id,a,o(n.rules,a,"@keyframes"))},this.name=e,this.id="sc-keyframes-".concat(e),this.rules=t,G8(this,function(){throw Ou(12,String(n.name))})}return r.prototype.getName=function(e){return e===void 0&&(e=Qw),this.name+e.hash},r}(),Ove=function(r){return r>="A"&&r<="Z"};function iA(r){for(var e="",t=0;t<r.length;t++){var n=r[t];if(t===1&&n==="-"&&r[0]==="-")return r;Ove(n)?e+="-"+n.toLowerCase():e+=n}return e.startsWith("ms-")?"-"+e:e}var VO=function(r){return r==null||r===!1||r===""},FO=function(r){var e,t,n=[];for(var i in r){var o=r[i];r.hasOwnProperty(i)&&!VO(o)&&(Array.isArray(o)&&o.isCss||$u(o)?n.push("".concat(iA(i),":"),o,";"):Cm(o)?n.push.apply(n,bc(bc(["".concat(i," {")],FO(o),!1),["}"],!1)):n.push("".concat(iA(i),": ").concat((e=i,(t=o)==null||typeof t=="boolean"||t===""?"":typeof t!="number"||t===0||e in u$||e.startsWith("--")?String(t).trim():"".concat(t,"px")),";")))}return n};function yu(r,e,t,n){if(VO(r))return[];if(W8(r))return[".".concat(r.styledComponentId)];if($u(r)){if(!$u(o=r)||o.prototype&&o.prototype.isReactComponent||!e)return[r];var i=r(e);return yu(i,e,t,n)}var o;return r instanceof DO?t?(r.inject(t,n),[r.getName(n)]):[r]:Cm(r)?FO(r):Array.isArray(r)?Array.prototype.concat.apply(Y4,r.map(function(a){return yu(a,e,t,n)})):[r.toString()]}function Zve(r){for(var e=0;e<r.length;e+=1){var t=r[e];if($u(t)&&!W8(t))return!1}return!0}var Lve=IO(K4),Hve=function(){function r(e,t,n){this.rules=e,this.staticRulesId="",this.isStatic=(n===void 0||n.isStatic)&&Zve(e),this.componentId=t,this.baseHash=rf(Lve,t),this.baseStyle=n,LO.registerId(t)}return r.prototype.generateAndInjectStyles=function(e,t,n){var i=this.baseStyle?this.baseStyle.generateAndInjectStyles(e,t,n):"";if(this.isStatic&&!n.hash)if(this.staticRulesId&&t.hasNameForId(this.componentId,this.staticRulesId))i=Jd(i,this.staticRulesId);else{var o=Kw(yu(this.rules,e,t,n)),a=Gw(rf(this.baseHash,o)>>>0);if(!t.hasNameForId(this.componentId,a)){var c=n(o,".".concat(a),void 0,this.componentId);t.insertRules(this.componentId,a,c)}i=Jd(i,a),this.staticRulesId=a}else{for(var d=rf(this.baseHash,n.hash),h="",u=0;u<this.rules.length;u++){var p=this.rules[u];if(typeof p=="string")h+=p;else if(p){var v=Kw(yu(p,e,t,n));d=rf(d,v+u),h+=v}}if(h){var g=Gw(d>>>0);t.hasNameForId(this.componentId,g)||t.insertRules(this.componentId,g,n(h,".".concat(g),void 0,this.componentId)),i=Jd(i,g)}}return i},r}(),e4=or.createContext(void 0);e4.Consumer;function Qf(r){var e=or.useContext(e4),t=x.useMemo(function(){return function(n,i){if(!n)throw Ou(14);if($u(n)){var o=n(i);return o}if(Array.isArray(n)||typeof n!="object")throw Ou(8);return i?vr(vr({},i),n):n}(r.theme,e)},[r.theme,e]);return r.children?or.createElement(e4.Provider,{value:t},r.children):null}var Y_={};function Nve(r,e,t){var n=W8(r),i=r,o=!K_(r),a=e.attrs,c=a===void 0?Y4:a,d=e.componentId,h=d===void 0?function(Z,B){var U=typeof Z!="string"?"sc":YT(Z);Y_[U]=(Y_[U]||0)+1;var I="".concat(U,"-").concat(RO(K4+U+Y_[U]));return B?"".concat(B,"-").concat(I):I}(e.displayName,e.parentComponentId):d,u=e.displayName,p=u===void 0?function(Z){return K_(Z)?"styled.".concat(Z):"Styled(".concat(dve(Z),")")}(r):u,v=e.displayName&&e.componentId?"".concat(YT(e.displayName),"-").concat(e.componentId):e.componentId||h,g=n&&i.attrs?i.attrs.concat(c).filter(Boolean):c,_=e.shouldForwardProp;if(n&&i.shouldForwardProp){var b=i.shouldForwardProp;if(e.shouldForwardProp){var C=e.shouldForwardProp;_=function(Z,B){return b(Z,B)&&C(Z,B)}}else _=b}var T=new Hve(t,v,n?i.componentStyle:void 0);function S(Z,B){return function(U,I,Y){var le=U.attrs,de=U.componentStyle,Ee=U.defaultProps,we=U.foldedComponentIds,Ce=U.styledComponentId,J=U.target,K=or.useContext(e4),re=nA(),q=U.shouldForwardProp||re.shouldForwardProp,$=ave(I,K,Ee)||Zf,O=function(Ie,Te,Ke){for(var ot,_t=vr(vr({},Te),{className:void 0,theme:Ke}),yr=0;yr<Ie.length;yr+=1){var Wr=$u(ot=Ie[yr])?ot(_t):ot;for(var Rt in Wr)_t[Rt]=Rt==="className"?Jd(_t[Rt],Wr[Rt]):Rt==="style"?vr(vr({},_t[Rt]),Wr[Rt]):Wr[Rt]}return Te.className&&(_t.className=Jd(_t.className,Te.className)),_t}(le,I,$),H=O.as||J,P={};for(var N in O)O[N]===void 0||N[0]==="$"||N==="as"||N==="theme"&&O.theme===$||(N==="forwardedAs"?P.as=O.forwardedAs:q&&!q(N,H)||(P[N]=O[N]));var ye=function(Ie,Te){var Ke=nA(),ot=Ie.generateAndInjectStyles(Te,Ke.styleSheet,Ke.stylis);return ot}(de,O),Pe=Jd(we,Ce);return ye&&(Pe+=" "+ye),O.className&&(Pe+=" "+O.className),P[K_(H)&&!TO.has(H)?"class":"className"]=Pe,Y&&(P.ref=Y),x.createElement(H,P)}(A,Z,B)}S.displayName=p;var A=or.forwardRef(S);return A.attrs=g,A.componentStyle=T,A.displayName=p,A.shouldForwardProp=_,A.foldedComponentIds=n?Jd(i.foldedComponentIds,i.styledComponentId):"",A.styledComponentId=v,A.target=n?i.target:r,Object.defineProperty(A,"defaultProps",{get:function(){return this._foldedDefaultProps},set:function(Z){this._foldedDefaultProps=n?function(B){for(var U=[],I=1;I<arguments.length;I++)U[I-1]=arguments[I];for(var Y=0,le=U;Y<le.length;Y++)Yw(B,le[Y],!0);return B}({},i.defaultProps,Z):Z}}),G8(A,function(){return".".concat(A.styledComponentId)}),o&&OO(A,r,{attrs:!0,componentStyle:!0,displayName:!0,foldedComponentIds:!0,shouldForwardProp:!0,styledComponentId:!0,target:!0}),A}function oA(r,e){for(var t=[r[0]],n=0,i=e.length;n<i;n+=1)t.push(e[n],r[n+1]);return t}var aA=function(r){return Object.assign(r,{isCss:!0})};function Zt(r){for(var e=[],t=1;t<arguments.length;t++)e[t-1]=arguments[t];if($u(r)||Cm(r))return aA(yu(oA(Y4,bc([r],e,!0))));var n=r;return e.length===0&&n.length===1&&typeof n[0]=="string"?yu(n):aA(yu(oA(n,e)))}function Xw(r,e,t){if(t===void 0&&(t=Zf),!e)throw Ou(1,e);var n=function(i){for(var o=[],a=1;a<arguments.length;a++)o[a-1]=arguments[a];return r(e,t,Zt.apply(void 0,bc([i],o,!1)))};return n.attrs=function(i){return Xw(r,e,vr(vr({},t),{attrs:Array.prototype.concat(t.attrs,i).filter(Boolean)}))},n.withConfig=function(i){return Xw(r,e,vr(vr({},t),i))},n}var jO=function(r){return Xw(Nve,r)},He=jO;TO.forEach(function(r){He[r]=jO(r)});function Dve(r){for(var e=[],t=1;t<arguments.length;t++)e[t-1]=arguments[t];var n=Kw(Zt.apply(void 0,bc([r],e,!1))),i=RO(n);return new DO(i,n)}const{typography:{navigation:{button:Q_}},colors:{interactive:{disabled__text:{rgba:Vve},disabled__border:{rgba:Fve},disabled__fill:{rgba:jve}}},spacings:{comfortable:{medium:sA}},shape:{button:{minHeight:cA,borderRadius:lA},_modes:{compact:{button:{minHeight:dA}}}},interactions:{focused:uA},clickbounds:{default__base:hA,compact__standard:fA}}=Xe,Q4={background:"transparent",height:`var(--eds_button__height, ${cA})`,typography:{...Q_,textAlign:"center",fontSize:`var(--eds_button__font_size, ${Q_.fontSize})`},border:{type:"border",width:"var(--eds_button__border_width, 1px)",color:"transparent",radius:`var(--eds_button__radius, ${lA})`,style:"solid"},spacings:{top:"var(--eds_button__padding_y, 0)",bottom:"var(--eds_button__padding_y, 0)",left:`var(--eds_button__padding_x, ${sA})`,right:`var(--eds_button__padding_x, ${sA})`},clickbound:{height:hA,width:"100%",offset:{top:`${(parseInt(hA)-parseInt(cA))/2+1}px`,left:"0"}},entities:{icon:{height:"var(--eds_button__icon__size, 24px)",width:"var(--eds_button__icon__size, 24px)"}},states:{hover:{border:{type:"border",width:"1px",color:"transparent",radius:`var(--eds_button__radius, ${lA})`,style:"solid"}},focus:{outline:{type:"outline",offset:"3px",style:"dashed",color:uA.color,width:uA.width}},disabled:{background:jve,border:{type:"border",width:"1px",color:Fve,style:"solid"},typography:{...Q_,color:Vve,textAlign:"center"}}},modes:{compact:{height:`var(--eds_button__height_compact, ${dA})`,spacings:{top:"var(--eds_button__padding_y_compact, 0)",bottom:"var(--eds_button__padding_y_compact, 0)"},clickbound:{height:fA,width:"100%",offset:{top:`${(parseInt(fA)-parseInt(dA))/2+1}px`,left:"0"}}}}};function Jr(r){return r!=null&&typeof r=="object"&&r["@@functional/placeholder"]===!0}function eu(r){return function e(t){return arguments.length===0||Jr(t)?e:r.apply(this,arguments)}}function Dd(r){return function e(t,n){switch(arguments.length){case 0:return e;case 1:return Jr(t)?e:eu(function(i){return r(t,i)});default:return Jr(t)&&Jr(n)?e:Jr(t)?eu(function(i){return r(i,n)}):Jr(n)?eu(function(i){return r(t,i)}):r(t,n)}}}function zO(r){return function e(t,n,i){switch(arguments.length){case 0:return e;case 1:return Jr(t)?e:Dd(function(o,a){return r(t,o,a)});case 2:return Jr(t)&&Jr(n)?e:Jr(t)?Dd(function(o,a){return r(o,n,a)}):Jr(n)?Dd(function(o,a){return r(t,o,a)}):eu(function(o){return r(t,n,o)});default:return Jr(t)&&Jr(n)&&Jr(i)?e:Jr(t)&&Jr(n)?Dd(function(o,a){return r(o,a,i)}):Jr(t)&&Jr(i)?Dd(function(o,a){return r(o,n,a)}):Jr(n)&&Jr(i)?Dd(function(o,a){return r(t,o,a)}):Jr(t)?eu(function(o){return r(o,n,i)}):Jr(n)?eu(function(o){return r(t,o,i)}):Jr(i)?eu(function(o){return r(t,n,o)}):r(t,n,i)}}}function pA(r){return Object.prototype.toString.call(r)==="[object Object]"}function ev(r,e){return Object.prototype.hasOwnProperty.call(e,r)}var zve=zO(function(e,t,n){var i={},o;t=t||{},n=n||{};for(o in t)ev(o,t)&&(i[o]=ev(o,n)?e(o,t[o],n[o]):t[o]);for(o in n)ev(o,n)&&!ev(o,i)&&(i[o]=n[o]);return i}),Bve=zO(function r(e,t,n){return zve(function(i,o,a){return pA(o)&&pA(a)?r(e,o,a):e(i,o,a)},t,n)}),bn=Dd(function(e,t){return Bve(function(n,i,o){return o},e,t)});const{colors:{text:{static_icons__primary_white:{rgba:Uve}},interactive:{primary__resting:{rgba:mA},primary__hover:{rgba:qve},secondary__resting:{rgba:vA},secondary__link_hover:{rgba:gA},danger__resting:{rgba:yA},danger__hover:{rgba:_A}}},shape:{button:{borderRadius:Wve}}}=Xe,X4=bn(Q4,{background:mA,typography:{color:Uve},border:{type:"border",style:"solid",width:"1px",color:mA,radius:`var(--eds_button__radius, ${Wve})`},states:{hover:{background:qve}}}),BO=bn(X4,{background:vA,border:{color:vA},states:{hover:{background:gA,border:{color:gA}}}}),UO=bn(X4,{background:yA,border:{color:yA},states:{hover:{background:_A,border:{color:_A}}}}),{colors:{interactive:{primary__resting:{rgba:bA},primary__hover:{rgba:wA},primary__hover_alt:{rgba:Gve},secondary__resting:{rgba:xA},secondary__link_hover:{rgba:CA},secondary__highlight:{rgba:Kve},danger__resting:{rgba:kA},danger__hover:{rgba:EA},danger__highlight:{rgba:Yve}}},shape:{button:{borderRadius:Qve}}}=Xe,K8=bn(Q4,{typography:{color:bA},border:{type:"border",style:"solid",width:"1px",color:bA,radius:`var(--eds_button__radius, ${Qve})`},states:{hover:{typography:{color:wA},background:Gve,border:{style:"solid",type:"border",width:"1px",color:wA}},disabled:{background:"transparent"}}}),Xve=bn(K8,{typography:{color:xA},border:{color:xA},states:{hover:{background:Kve,typography:{color:CA},border:{color:CA}}}}),Jve=bn(K8,{typography:{color:kA},border:{color:kA},states:{hover:{background:Yve,typography:{color:EA},border:{color:EA}}}}),{colors:{interactive:{primary__resting:{rgba:ege},primary__hover:{rgba:tge},primary__hover_alt:{rgba:rge},secondary__resting:{rgba:nge},secondary__link_hover:{rgba:ige},secondary__highlight:{rgba:oge},danger__resting:{rgba:age},danger__hover:{rgba:sge},danger__highlight:{rgba:cge}}}}=Xe,Y8=bn(Q4,{typography:{color:ege},states:{hover:{background:rge,typography:{color:tge}},disabled:{background:"transparent",border:{color:"transparent"}}}}),lge=bn(Y8,{typography:{color:nge},states:{hover:{background:oge,typography:{color:ige}}}}),dge=bn(Y8,{typography:{color:age},states:{hover:{background:cge,typography:{color:sge}}}}),{colors:{interactive:{primary__resting:{rgba:uge},primary__hover_alt:{rgba:hge},secondary__resting:{rgba:fge},secondary__link_hover:{rgba:pge},secondary__highlight:{rgba:mge},danger__resting:{rgba:vge},danger__hover:{rgba:gge},danger__highlight:{rgba:yge}}},clickbounds:{default__base:X_,compact__standard:SA},shape:Td,interactions:{focused:{width:_ge}}}=Xe,Q8=bn(Q4,{height:Td.icon_button.minHeight,width:Td.icon_button.minWidth,typography:{color:uge},border:{width:"0px",radius:"50%"},background:"transparent",spacings:{left:"0",right:"0"},clickbound:{width:X_,offset:{top:`${(parseInt(X_)-parseInt(Td.icon_button.minWidth))/2}px`,left:`${(parseInt(X_)-parseInt(Td.icon_button.minWidth))/2}px`}},states:{hover:{background:hge,border:{width:"0px",radius:"50%"}},disabled:{background:"transparent",border:{color:"transparent"}},focus:{outline:{offset:`-${parseInt(_ge)}px`}}},modes:{compact:{height:Td._modes.compact.icon_button.minHeight,width:Td._modes.compact.icon_button.minWidth,clickbound:{width:SA,offset:{top:"0",left:`${(parseInt(SA)-parseInt(Td._modes.compact.icon_button.minWidth))/2}px`}}}}}),bge=bn(Q8,{typography:{color:fge},states:{hover:{background:mge,typography:{color:pge}}}}),wge=bn(Q8,{typography:{color:vge},states:{hover:{background:yge,typography:{color:gge}}}}),{clickbounds:{default__base:J_,compact__standard:TA},shape:Ad}=Xe,X8={height:Ad.icon_button.minHeight,width:Ad.icon_button.minWidth,border:{width:"0px",radius:"50%"},spacings:{left:"0",right:"0"},clickbound:{width:J_,offset:{top:`${(parseInt(J_)-parseInt(Ad.icon_button.minWidth))/2}px`,left:`${(parseInt(J_)-parseInt(Ad.icon_button.minWidth))/2}px`}},states:{hover:{border:{width:"0px",radius:"50%"}}},modes:{compact:{height:Ad._modes.compact.icon_button.minHeight,width:Ad._modes.compact.icon_button.minWidth,clickbound:{width:TA,offset:{top:"0",left:`${(parseInt(TA)-parseInt(Ad._modes.compact.icon_button.minWidth))/2}px`}}}}},xge=bn(X4,X8),Cge=bn(BO,X8),kge=bn(UO,X8),eb={primary:{contained:X4,outlined:K8,ghost:Y8,ghost_icon:Q8,contained_icon:xge},secondary:{contained:BO,outlined:Xve,ghost:lge,ghost_icon:bge,contained_icon:Cge},danger:{contained:UO,outlined:Jve,ghost:dge,ghost_icon:wge,contained_icon:kge}},Ege=(r,e)=>{x.useEffect(()=>{const t=n=>{r&&!r.contains(n.target)&&e(n)};return document.addEventListener("click",t),()=>{document.removeEventListener("click",t)}},[r,e])},Jw=(r,e)=>{x.useEffect(()=>{const t=n=>{const{key:i}=n;switch(i){case r:e(n);break}};return document.addEventListener("keydown",t,!0),()=>{document.removeEventListener("keydown",t,!0)}},[r,e])};let Sge=0;const qO=(r,e)=>{const[t,n]=x.useState(r),i=t;return x.useEffect(()=>{t==null&&n(`eds-${e?e+"-":""}${Sge++}`)},[t,e]),i},Tge=(r,e)=>{x.useEffect(()=>{const t=()=>{r.style.height="auto";const{scrollHeight:n,clientHeight:i}=r;let o=i;e>o&&(o=Math.min(e,Math.max(n,o)),n>e?r.style.overflow="auto":r.style.overflow="hidden",o>i&&(r.style.height=`${o}px`))};return r&&e&&(t(),r.addEventListener("keyup",t,!0)),()=>{r==null||r.removeEventListener("keyup",t,!0)}},[r,e])},Age=r=>{const e=x.useRef();x.useEffect(()=>{if(typeof document>"u")return;const t=document.documentElement,{body:n}=document;if(r){const o=window.innerWidth-t.clientWidth,a=parseInt(window.getComputedStyle(n).getPropertyValue("padding-right"))||0,c={overflow:n.style.overflow,paddingRight:n.style.paddingRight};e.current=c,n.style.overflow="hidden",n.style.paddingRight=`${a+o}px`}else e.current&&(n.style.overflow=e.current.overflow,n.style.paddingRight=e.current.paddingRight);const i=e.current;return()=>{n.style.overflow=i==null?void 0:i.overflow,n.style.paddingRight=i==null?void 0:i.paddingRight}},[r])},AA=typeof window<"u"?x.useLayoutEffect:x.useEffect;function en(r){return r!=null&&typeof r=="object"&&r["@@functional/placeholder"]===!0}function tu(r){return function e(t){return arguments.length===0||en(t)?e:r.apply(this,arguments)}}function Vd(r){return function e(t,n){switch(arguments.length){case 0:return e;case 1:return en(t)?e:tu(function(i){return r(t,i)});default:return en(t)&&en(n)?e:en(t)?tu(function(i){return r(i,n)}):en(n)?tu(function(i){return r(t,i)}):r(t,n)}}}function WO(r){return function e(t,n,i){switch(arguments.length){case 0:return e;case 1:return en(t)?e:Vd(function(o,a){return r(t,o,a)});case 2:return en(t)&&en(n)?e:en(t)?Vd(function(o,a){return r(o,n,a)}):en(n)?Vd(function(o,a){return r(t,o,a)}):tu(function(o){return r(t,n,o)});default:return en(t)&&en(n)&&en(i)?e:en(t)&&en(n)?Vd(function(o,a){return r(o,a,i)}):en(t)&&en(i)?Vd(function(o,a){return r(o,n,a)}):en(n)&&en(i)?Vd(function(o,a){return r(t,o,a)}):en(t)?tu(function(o){return r(o,n,i)}):en(n)?tu(function(o){return r(t,o,i)}):en(i)?tu(function(o){return r(t,n,o)}):r(t,n,i)}}}function IA(r){return Object.prototype.toString.call(r)==="[object Object]"}function tv(r,e){return Object.prototype.hasOwnProperty.call(e,r)}var Ige=WO(function(e,t,n){var i={},o;t=t||{},n=n||{};for(o in t)tv(o,t)&&(i[o]=tv(o,n)?e(o,t[o],n[o]):t[o]);for(o in n)tv(o,n)&&!tv(o,i)&&(i[o]=n[o]);return i}),Rge=WO(function r(e,t,n){return Ige(function(i,o,a){return IA(o)&&IA(a)?r(e,o,a):e(i,o,a)},t,n)}),Pge=Vd(function(e,t){return Rge(function(n,i,o){return o},e,t)});const zu=(r,e)=>x.useCallback(()=>{const{density:t}=r;return t==="compact"?Pge(e,e.modes.compact):e},[r,e]),Zu=(...r)=>e=>r.forEach(t=>{typeof t=="function"?t(e):t&&typeof t=="object"&&(t.current=e)}),Mge=(r,e)=>{const t=r.value;r.value=e;const n=r._valueTracker;typeof n<"u"&&n.setValue(t),r.dispatchEvent(new Event("change",{bubbles:!0}))},Bh=r=>{if(!r)return;const{width:e="",style:t="",color:n=""}=r;return e?`${e} ${t} ${n}`:null},Tl=r=>{var e,t,n,i;if(!r)return Zt({});switch(r.type){case"border":return Zt({border:Bh(r),borderRadius:r.radius});case"bordergroup":return Zt({borderBottom:Bh(r.bottom),borderTop:Bh(r.top),borderLeft:Bh(r.left),borderRight:Bh(r.right),borderBottomLeftRadius:(e=r==null?void 0:r.left)==null?void 0:e.radius,borderTopLeftRadius:(t=r==null?void 0:r.left)==null?void 0:t.radius,borderBottomRightRadius:(n=r==null?void 0:r.right)==null?void 0:n.radius,borderTopRightRadius:(i=r==null?void 0:r.right)==null?void 0:i.radius});default:return Zt({})}},{colors:{interactive:{focus:{rgba:$ge}}}}=Xe,wc=r=>{const{color:e=$ge,style:t="dashed",width:n="2px",offset:i="0px",type:o}=r,a={color:e,style:t,width:n,offset:i};return Zt({outline:Bh(a),outlineOffset:a.offset})},Va=(r,e)=>{if(!r)return"";let t=`
1946
1946
  margin: 0;
1947
1947
  color: ${r.color};
@@ -3189,9 +3189,9 @@ cursor: pointer;`),t},Vl=({left:r,right:e,top:t,bottom:n})=>Zt({paddingLeft:r,pa
3189
3189
  background: ${Xe.colors.ui.background__default.hex};
3190
3190
  height: 100%;
3191
3191
  `,B_e=ut(n4)`
3192
- height: 3rem;
3192
+ height: var(--side-sheet-header-height, 3rem);
3193
3193
  justify-content: space-between;
3194
- padding: 1rem;
3194
+ padding: var(--side-sheet-header-padding, 1rem);
3195
3195
  `;Ao.add({close:$8});const yi=r=>{const{onClose:e,children:t,enableFullscreen:n}=r,i=x.useRef(null),o=x.useCallback(()=>{var c;document.fullscreenElement?document.exitFullscreen().catch(d=>console.error(d)):(c=i.current)==null||c.requestFullscreen()},[i]),a=TZ(t).reduce((c,d)=>{if(!or.isValidElement(d))return c;if(d.type===kZ)c.indicator=d;else if(d.type===SZ)c.title=d;else if(d.type===EZ)c.subTitle=d;else if(d.type===CZ)c.content=d;else if(d.type===xZ)c.actions=or.cloneElement(d);else throw Error(`unsupported child ${d.type} in SideSheet component`);return c},{});if(!a.title)throw Error("Title Component is required child");if(!a.subTitle)throw Error("SubTitle Component is required child");if(!a.content)throw Error("Content Component is required child");return k.jsx(D_e,{...r,children:k.jsxs(z_e,{ref:i,children:[k.jsxs(B_e,{children:[k.jsxs(n4,{children:[a.indicator,k.jsxs(AZ,{children:[a.title,a.subTitle]})]}),k.jsxs(n4,{children:[a.actions,n&&k.jsx(Aw,{title:"Full screen",enterDelay:500,children:k.jsx(ca,{variant:"ghost_icon",onClick:o,children:k.jsx(E_e,{})})}),k.jsx(Aw,{title:"Close",enterDelay:500,children:k.jsx(ca,{variant:"ghost_icon",onClick:e,children:k.jsx(Ao,{name:"close"})})})]})]}),a.content]})})};yi.Title=SZ;yi.SubTitle=EZ;yi.Indicator=kZ;yi.Content=CZ;yi.Actions=xZ;const U_e=gt`
3196
3196
  :host {
3197
3197
  --fwc-avatar-size: 2.5rem;