lensmcp 1.11.0 → 1.13.0

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.
@@ -1,18 +1,18 @@
1
- "use strict";(()=>{var o_=Object.create;var Vh=Object.defineProperty;var a_=Object.getOwnPropertyDescriptor;var l_=Object.getOwnPropertyNames;var i_=Object.getPrototypeOf,r_=Object.prototype.hasOwnProperty;var re=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports);var u_=(t,e,n,o)=>{if(e&&typeof e=="object"||typeof e=="function")for(let a of l_(e))!r_.call(t,a)&&a!==n&&Vh(t,a,{get:()=>e[a],enumerable:!(o=a_(e,a))||o.enumerable});return t};var We=(t,e,n)=>(n=t!=null?o_(i_(t)):{},u_(e||!t||!t.__esModule?Vh(n,"default",{value:t,enumerable:!0}):n,t));var Wh=re(P=>{"use strict";var Yc=Symbol.for("react.transitional.element"),c_=Symbol.for("react.portal"),s_=Symbol.for("react.fragment"),f_=Symbol.for("react.strict_mode"),d_=Symbol.for("react.profiler"),h_=Symbol.for("react.consumer"),p_=Symbol.for("react.context"),g_=Symbol.for("react.forward_ref"),m_=Symbol.for("react.suspense"),y_=Symbol.for("react.memo"),Qh=Symbol.for("react.lazy"),v_=Symbol.for("react.activity"),qh=Symbol.iterator;function b_(t){return t===null||typeof t!="object"?null:(t=qh&&t[qh]||t["@@iterator"],typeof t=="function"?t:null)}var jh={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},Kh=Object.assign,$h={};function ma(t,e,n){this.props=t,this.context=e,this.refs=$h,this.updater=n||jh}ma.prototype.isReactComponent={};ma.prototype.setState=function(t,e){if(typeof t!="object"&&typeof t!="function"&&t!=null)throw Error("takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,t,e,"setState")};ma.prototype.forceUpdate=function(t){this.updater.enqueueForceUpdate(this,t,"forceUpdate")};function Jh(){}Jh.prototype=ma.prototype;function Vc(t,e,n){this.props=t,this.context=e,this.refs=$h,this.updater=n||jh}var qc=Vc.prototype=new Jh;qc.constructor=Vc;Kh(qc,ma.prototype);qc.isPureReactComponent=!0;var Xh=Array.isArray;function Uc(){}var xt={H:null,A:null,T:null,S:null},Ih=Object.prototype.hasOwnProperty;function Xc(t,e,n){var o=n.ref;return{$$typeof:Yc,type:t,key:e,ref:o!==void 0?o:null,props:n}}function x_(t,e){return Xc(t.type,e,t.props)}function Zc(t){return typeof t=="object"&&t!==null&&t.$$typeof===Yc}function S_(t){var e={"=":"=0",":":"=2"};return"$"+t.replace(/[=:]/g,function(n){return e[n]})}var Zh=/\/+/g;function Lc(t,e){return typeof t=="object"&&t!==null&&t.key!=null?S_(""+t.key):e.toString(36)}function __(t){switch(t.status){case"fulfilled":return t.value;case"rejected":throw t.reason;default:switch(typeof t.status=="string"?t.then(Uc,Uc):(t.status="pending",t.then(function(e){t.status==="pending"&&(t.status="fulfilled",t.value=e)},function(e){t.status==="pending"&&(t.status="rejected",t.reason=e)})),t.status){case"fulfilled":return t.value;case"rejected":throw t.reason}}throw t}function ga(t,e,n,o,a){var l=typeof t;(l==="undefined"||l==="boolean")&&(t=null);var i=!1;if(t===null)i=!0;else switch(l){case"bigint":case"string":case"number":i=!0;break;case"object":switch(t.$$typeof){case Yc:case c_:i=!0;break;case Qh:return i=t._init,ga(i(t._payload),e,n,o,a)}}if(i)return a=a(t),i=o===""?"."+Lc(t,0):o,Xh(a)?(n="",i!=null&&(n=i.replace(Zh,"$&/")+"/"),ga(a,e,n,"",function(s){return s})):a!=null&&(Zc(a)&&(a=x_(a,n+(a.key==null||t&&t.key===a.key?"":(""+a.key).replace(Zh,"$&/")+"/")+i)),e.push(a)),1;i=0;var r=o===""?".":o+":";if(Xh(t))for(var u=0;u<t.length;u++)o=t[u],l=r+Lc(o,u),i+=ga(o,e,n,l,a);else if(u=b_(t),typeof u=="function")for(t=u.call(t),u=0;!(o=t.next()).done;)o=o.value,l=r+Lc(o,u++),i+=ga(o,e,n,l,a);else if(l==="object"){if(typeof t.then=="function")return ga(__(t),e,n,o,a);throw e=String(t),Error("Objects are not valid as a React child (found: "+(e==="[object Object]"?"object with keys {"+Object.keys(t).join(", ")+"}":e)+"). If you meant to render a collection of children, use an array instead.")}return i}function tr(t,e,n){if(t==null)return t;var o=[],a=0;return ga(t,o,"","",function(l){return e.call(n,l,a++)}),o}function w_(t){if(t._status===-1){var e=t._result;e=e(),e.then(function(n){(t._status===0||t._status===-1)&&(t._status=1,t._result=n)},function(n){(t._status===0||t._status===-1)&&(t._status=2,t._result=n)}),t._status===-1&&(t._status=0,t._result=e)}if(t._status===1)return t._result.default;throw t._result}var Gh=typeof reportError=="function"?reportError:function(t){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var e=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof t=="object"&&t!==null&&typeof t.message=="string"?String(t.message):String(t),error:t});if(!window.dispatchEvent(e))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",t);return}console.error(t)},E_={map:tr,forEach:function(t,e,n){tr(t,function(){e.apply(this,arguments)},n)},count:function(t){var e=0;return tr(t,function(){e++}),e},toArray:function(t){return tr(t,function(e){return e})||[]},only:function(t){if(!Zc(t))throw Error("React.Children.only expected to receive a single React element child.");return t}};P.Activity=v_;P.Children=E_;P.Component=ma;P.Fragment=s_;P.Profiler=d_;P.PureComponent=Vc;P.StrictMode=f_;P.Suspense=m_;P.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=xt;P.__COMPILER_RUNTIME={__proto__:null,c:function(t){return xt.H.useMemoCache(t)}};P.cache=function(t){return function(){return t.apply(null,arguments)}};P.cacheSignal=function(){return null};P.cloneElement=function(t,e,n){if(t==null)throw Error("The argument must be a React element, but you passed "+t+".");var o=Kh({},t.props),a=t.key;if(e!=null)for(l in e.key!==void 0&&(a=""+e.key),e)!Ih.call(e,l)||l==="key"||l==="__self"||l==="__source"||l==="ref"&&e.ref===void 0||(o[l]=e[l]);var l=arguments.length-2;if(l===1)o.children=n;else if(1<l){for(var i=Array(l),r=0;r<l;r++)i[r]=arguments[r+2];o.children=i}return Xc(t.type,a,o)};P.createContext=function(t){return t={$$typeof:p_,_currentValue:t,_currentValue2:t,_threadCount:0,Provider:null,Consumer:null},t.Provider=t,t.Consumer={$$typeof:h_,_context:t},t};P.createElement=function(t,e,n){var o,a={},l=null;if(e!=null)for(o in e.key!==void 0&&(l=""+e.key),e)Ih.call(e,o)&&o!=="key"&&o!=="__self"&&o!=="__source"&&(a[o]=e[o]);var i=arguments.length-2;if(i===1)a.children=n;else if(1<i){for(var r=Array(i),u=0;u<i;u++)r[u]=arguments[u+2];a.children=r}if(t&&t.defaultProps)for(o in i=t.defaultProps,i)a[o]===void 0&&(a[o]=i[o]);return Xc(t,l,a)};P.createRef=function(){return{current:null}};P.forwardRef=function(t){return{$$typeof:g_,render:t}};P.isValidElement=Zc;P.lazy=function(t){return{$$typeof:Qh,_payload:{_status:-1,_result:t},_init:w_}};P.memo=function(t,e){return{$$typeof:y_,type:t,compare:e===void 0?null:e}};P.startTransition=function(t){var e=xt.T,n={};xt.T=n;try{var o=t(),a=xt.S;a!==null&&a(n,o),typeof o=="object"&&o!==null&&typeof o.then=="function"&&o.then(Uc,Gh)}catch(l){Gh(l)}finally{e!==null&&n.types!==null&&(e.types=n.types),xt.T=e}};P.unstable_useCacheRefresh=function(){return xt.H.useCacheRefresh()};P.use=function(t){return xt.H.use(t)};P.useActionState=function(t,e,n){return xt.H.useActionState(t,e,n)};P.useCallback=function(t,e){return xt.H.useCallback(t,e)};P.useContext=function(t){return xt.H.useContext(t)};P.useDebugValue=function(){};P.useDeferredValue=function(t,e){return xt.H.useDeferredValue(t,e)};P.useEffect=function(t,e){return xt.H.useEffect(t,e)};P.useEffectEvent=function(t){return xt.H.useEffectEvent(t)};P.useId=function(){return xt.H.useId()};P.useImperativeHandle=function(t,e,n){return xt.H.useImperativeHandle(t,e,n)};P.useInsertionEffect=function(t,e){return xt.H.useInsertionEffect(t,e)};P.useLayoutEffect=function(t,e){return xt.H.useLayoutEffect(t,e)};P.useMemo=function(t,e){return xt.H.useMemo(t,e)};P.useOptimistic=function(t,e){return xt.H.useOptimistic(t,e)};P.useReducer=function(t,e,n){return xt.H.useReducer(t,e,n)};P.useRef=function(t){return xt.H.useRef(t)};P.useState=function(t){return xt.H.useState(t)};P.useSyncExternalStore=function(t,e,n){return xt.H.useSyncExternalStore(t,e,n)};P.useTransition=function(){return xt.H.useTransition()};P.version="19.2.7"});var hn=re((sC,Fh)=>{"use strict";Fh.exports=Wh()});var up=re(Nt=>{"use strict";function Kc(t,e){var n=t.length;t.push(e);t:for(;0<n;){var o=n-1>>>1,a=t[o];if(0<er(a,e))t[o]=e,t[n]=a,n=o;else break t}}function Fe(t){return t.length===0?null:t[0]}function or(t){if(t.length===0)return null;var e=t[0],n=t.pop();if(n!==e){t[0]=n;t:for(var o=0,a=t.length,l=a>>>1;o<l;){var i=2*(o+1)-1,r=t[i],u=i+1,s=t[u];if(0>er(r,n))u<a&&0>er(s,r)?(t[o]=s,t[u]=n,o=u):(t[o]=r,t[i]=n,o=i);else if(u<a&&0>er(s,n))t[o]=s,t[u]=n,o=u;else break t}}return e}function er(t,e){var n=t.sortIndex-e.sortIndex;return n!==0?n:t.id-e.id}Nt.unstable_now=void 0;typeof performance=="object"&&typeof performance.now=="function"?(Ph=performance,Nt.unstable_now=function(){return Ph.now()}):(Gc=Date,tp=Gc.now(),Nt.unstable_now=function(){return Gc.now()-tp});var Ph,Gc,tp,pn=[],Vn=[],N_=1,ze=null,Ft=3,$c=!1,Nl=!1,Ml=!1,Jc=!1,op=typeof setTimeout=="function"?setTimeout:null,ap=typeof clearTimeout=="function"?clearTimeout:null,ep=typeof setImmediate<"u"?setImmediate:null;function nr(t){for(var e=Fe(Vn);e!==null;){if(e.callback===null)or(Vn);else if(e.startTime<=t)or(Vn),e.sortIndex=e.expirationTime,Kc(pn,e);else break;e=Fe(Vn)}}function Ic(t){if(Ml=!1,nr(t),!Nl)if(Fe(pn)!==null)Nl=!0,va||(va=!0,ya());else{var e=Fe(Vn);e!==null&&Wc(Ic,e.startTime-t)}}var va=!1,zl=-1,lp=5,ip=-1;function rp(){return Jc?!0:!(Nt.unstable_now()-ip<lp)}function Qc(){if(Jc=!1,va){var t=Nt.unstable_now();ip=t;var e=!0;try{t:{Nl=!1,Ml&&(Ml=!1,ap(zl),zl=-1),$c=!0;var n=Ft;try{e:{for(nr(t),ze=Fe(pn);ze!==null&&!(ze.expirationTime>t&&rp());){var o=ze.callback;if(typeof o=="function"){ze.callback=null,Ft=ze.priorityLevel;var a=o(ze.expirationTime<=t);if(t=Nt.unstable_now(),typeof a=="function"){ze.callback=a,nr(t),e=!0;break e}ze===Fe(pn)&&or(pn),nr(t)}else or(pn);ze=Fe(pn)}if(ze!==null)e=!0;else{var l=Fe(Vn);l!==null&&Wc(Ic,l.startTime-t),e=!1}}break t}finally{ze=null,Ft=n,$c=!1}e=void 0}}finally{e?ya():va=!1}}}var ya;typeof ep=="function"?ya=function(){ep(Qc)}:typeof MessageChannel<"u"?(jc=new MessageChannel,np=jc.port2,jc.port1.onmessage=Qc,ya=function(){np.postMessage(null)}):ya=function(){op(Qc,0)};var jc,np;function Wc(t,e){zl=op(function(){t(Nt.unstable_now())},e)}Nt.unstable_IdlePriority=5;Nt.unstable_ImmediatePriority=1;Nt.unstable_LowPriority=4;Nt.unstable_NormalPriority=3;Nt.unstable_Profiling=null;Nt.unstable_UserBlockingPriority=2;Nt.unstable_cancelCallback=function(t){t.callback=null};Nt.unstable_forceFrameRate=function(t){0>t||125<t?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):lp=0<t?Math.floor(1e3/t):5};Nt.unstable_getCurrentPriorityLevel=function(){return Ft};Nt.unstable_next=function(t){switch(Ft){case 1:case 2:case 3:var e=3;break;default:e=Ft}var n=Ft;Ft=e;try{return t()}finally{Ft=n}};Nt.unstable_requestPaint=function(){Jc=!0};Nt.unstable_runWithPriority=function(t,e){switch(t){case 1:case 2:case 3:case 4:case 5:break;default:t=3}var n=Ft;Ft=t;try{return e()}finally{Ft=n}};Nt.unstable_scheduleCallback=function(t,e,n){var o=Nt.unstable_now();switch(typeof n=="object"&&n!==null?(n=n.delay,n=typeof n=="number"&&0<n?o+n:o):n=o,t){case 1:var a=-1;break;case 2:a=250;break;case 5:a=1073741823;break;case 4:a=1e4;break;default:a=5e3}return a=n+a,t={id:N_++,callback:e,priorityLevel:t,startTime:n,expirationTime:a,sortIndex:-1},n>o?(t.sortIndex=n,Kc(Vn,t),Fe(pn)===null&&t===Fe(Vn)&&(Ml?(ap(zl),zl=-1):Ml=!0,Wc(Ic,n-o))):(t.sortIndex=a,Kc(pn,t),Nl||$c||(Nl=!0,va||(va=!0,ya()))),t};Nt.unstable_shouldYield=rp;Nt.unstable_wrapCallback=function(t){var e=Ft;return function(){var n=Ft;Ft=e;try{return t.apply(this,arguments)}finally{Ft=n}}}});var sp=re((dC,cp)=>{"use strict";cp.exports=up()});var dp=re(ee=>{"use strict";var M_=hn();function fp(t){var e="https://react.dev/errors/"+t;if(1<arguments.length){e+="?args[]="+encodeURIComponent(arguments[1]);for(var n=2;n<arguments.length;n++)e+="&args[]="+encodeURIComponent(arguments[n])}return"Minified React error #"+t+"; visit "+e+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function qn(){}var te={d:{f:qn,r:function(){throw Error(fp(522))},D:qn,C:qn,L:qn,m:qn,X:qn,S:qn,M:qn},p:0,findDOMNode:null},z_=Symbol.for("react.portal");function A_(t,e,n){var o=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:z_,key:o==null?null:""+o,children:t,containerInfo:e,implementation:n}}var Al=M_.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function ar(t,e){if(t==="font")return"";if(typeof e=="string")return e==="use-credentials"?e:""}ee.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=te;ee.createPortal=function(t,e){var n=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)throw Error(fp(299));return A_(t,e,null,n)};ee.flushSync=function(t){var e=Al.T,n=te.p;try{if(Al.T=null,te.p=2,t)return t()}finally{Al.T=e,te.p=n,te.d.f()}};ee.preconnect=function(t,e){typeof t=="string"&&(e?(e=e.crossOrigin,e=typeof e=="string"?e==="use-credentials"?e:"":void 0):e=null,te.d.C(t,e))};ee.prefetchDNS=function(t){typeof t=="string"&&te.d.D(t)};ee.preinit=function(t,e){if(typeof t=="string"&&e&&typeof e.as=="string"){var n=e.as,o=ar(n,e.crossOrigin),a=typeof e.integrity=="string"?e.integrity:void 0,l=typeof e.fetchPriority=="string"?e.fetchPriority:void 0;n==="style"?te.d.S(t,typeof e.precedence=="string"?e.precedence:void 0,{crossOrigin:o,integrity:a,fetchPriority:l}):n==="script"&&te.d.X(t,{crossOrigin:o,integrity:a,fetchPriority:l,nonce:typeof e.nonce=="string"?e.nonce:void 0})}};ee.preinitModule=function(t,e){if(typeof t=="string")if(typeof e=="object"&&e!==null){if(e.as==null||e.as==="script"){var n=ar(e.as,e.crossOrigin);te.d.M(t,{crossOrigin:n,integrity:typeof e.integrity=="string"?e.integrity:void 0,nonce:typeof e.nonce=="string"?e.nonce:void 0})}}else e==null&&te.d.M(t)};ee.preload=function(t,e){if(typeof t=="string"&&typeof e=="object"&&e!==null&&typeof e.as=="string"){var n=e.as,o=ar(n,e.crossOrigin);te.d.L(t,n,{crossOrigin:o,integrity:typeof e.integrity=="string"?e.integrity:void 0,nonce:typeof e.nonce=="string"?e.nonce:void 0,type:typeof e.type=="string"?e.type:void 0,fetchPriority:typeof e.fetchPriority=="string"?e.fetchPriority:void 0,referrerPolicy:typeof e.referrerPolicy=="string"?e.referrerPolicy:void 0,imageSrcSet:typeof e.imageSrcSet=="string"?e.imageSrcSet:void 0,imageSizes:typeof e.imageSizes=="string"?e.imageSizes:void 0,media:typeof e.media=="string"?e.media:void 0})}};ee.preloadModule=function(t,e){if(typeof t=="string")if(e){var n=ar(e.as,e.crossOrigin);te.d.m(t,{as:typeof e.as=="string"&&e.as!=="script"?e.as:void 0,crossOrigin:n,integrity:typeof e.integrity=="string"?e.integrity:void 0})}else te.d.m(t)};ee.requestFormReset=function(t){te.d.r(t)};ee.unstable_batchedUpdates=function(t,e){return t(e)};ee.useFormState=function(t,e,n){return Al.H.useFormState(t,e,n)};ee.useFormStatus=function(){return Al.H.useHostTransitionStatus()};ee.version="19.2.7"});var Fc=re((pC,pp)=>{"use strict";function hp(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(hp)}catch(t){console.error(t)}}hp(),pp.exports=dp()});var My=re(Cu=>{"use strict";var Vt=sp(),Vg=hn(),C_=Fc();function L(t){var e="https://react.dev/errors/"+t;if(1<arguments.length){e+="?args[]="+encodeURIComponent(arguments[1]);for(var n=2;n<arguments.length;n++)e+="&args[]="+encodeURIComponent(arguments[n])}return"Minified React error #"+t+"; visit "+e+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function qg(t){return!(!t||t.nodeType!==1&&t.nodeType!==9&&t.nodeType!==11)}function pi(t){var e=t,n=t;if(t.alternate)for(;e.return;)e=e.return;else{t=e;do e=t,(e.flags&4098)!==0&&(n=e.return),t=e.return;while(t)}return e.tag===3?n:null}function Xg(t){if(t.tag===13){var e=t.memoizedState;if(e===null&&(t=t.alternate,t!==null&&(e=t.memoizedState)),e!==null)return e.dehydrated}return null}function Zg(t){if(t.tag===31){var e=t.memoizedState;if(e===null&&(t=t.alternate,t!==null&&(e=t.memoizedState)),e!==null)return e.dehydrated}return null}function gp(t){if(pi(t)!==t)throw Error(L(188))}function T_(t){var e=t.alternate;if(!e){if(e=pi(t),e===null)throw Error(L(188));return e!==t?null:t}for(var n=t,o=e;;){var a=n.return;if(a===null)break;var l=a.alternate;if(l===null){if(o=a.return,o!==null){n=o;continue}break}if(a.child===l.child){for(l=a.child;l;){if(l===n)return gp(a),t;if(l===o)return gp(a),e;l=l.sibling}throw Error(L(188))}if(n.return!==o.return)n=a,o=l;else{for(var i=!1,r=a.child;r;){if(r===n){i=!0,n=a,o=l;break}if(r===o){i=!0,o=a,n=l;break}r=r.sibling}if(!i){for(r=l.child;r;){if(r===n){i=!0,n=l,o=a;break}if(r===o){i=!0,o=l,n=a;break}r=r.sibling}if(!i)throw Error(L(189))}}if(n.alternate!==o)throw Error(L(190))}if(n.tag!==3)throw Error(L(188));return n.stateNode.current===n?t:e}function Gg(t){var e=t.tag;if(e===5||e===26||e===27||e===6)return t;for(t=t.child;t!==null;){if(e=Gg(t),e!==null)return e;t=t.sibling}return null}var wt=Object.assign,O_=Symbol.for("react.element"),lr=Symbol.for("react.transitional.element"),kl=Symbol.for("react.portal"),Ea=Symbol.for("react.fragment"),Qg=Symbol.for("react.strict_mode"),Ds=Symbol.for("react.profiler"),jg=Symbol.for("react.consumer"),_n=Symbol.for("react.context"),Af=Symbol.for("react.forward_ref"),Hs=Symbol.for("react.suspense"),Rs=Symbol.for("react.suspense_list"),Cf=Symbol.for("react.memo"),Xn=Symbol.for("react.lazy"),Bs=Symbol.for("react.activity"),D_=Symbol.for("react.memo_cache_sentinel"),mp=Symbol.iterator;function Cl(t){return t===null||typeof t!="object"?null:(t=mp&&t[mp]||t["@@iterator"],typeof t=="function"?t:null)}var H_=Symbol.for("react.client.reference");function ks(t){if(t==null)return null;if(typeof t=="function")return t.$$typeof===H_?null:t.displayName||t.name||null;if(typeof t=="string")return t;switch(t){case Ea:return"Fragment";case Ds:return"Profiler";case Qg:return"StrictMode";case Hs:return"Suspense";case Rs:return"SuspenseList";case Bs:return"Activity"}if(typeof t=="object")switch(t.$$typeof){case kl:return"Portal";case _n:return t.displayName||"Context";case jg:return(t._context.displayName||"Context")+".Consumer";case Af:var e=t.render;return t=t.displayName,t||(t=e.displayName||e.name||"",t=t!==""?"ForwardRef("+t+")":"ForwardRef"),t;case Cf:return e=t.displayName||null,e!==null?e:ks(t.type)||"Memo";case Xn:e=t._payload,t=t._init;try{return ks(t(e))}catch{}}return null}var Ll=Array.isArray,F=Vg.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,ft=C_.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,Ro={pending:!1,data:null,method:null,action:null},Ls=[],Na=-1;function on(t){return{current:t}}function Gt(t){0>Na||(t.current=Ls[Na],Ls[Na]=null,Na--)}function bt(t,e){Na++,Ls[Na]=t.current,t.current=e}var nn=on(null),ti=on(null),Pn=on(null),Ur=on(null);function Yr(t,e){switch(bt(Pn,e),bt(ti,t),bt(nn,null),e.nodeType){case 9:case 11:t=(t=e.documentElement)&&(t=t.namespaceURI)?wg(t):0;break;default:if(t=e.tagName,e=e.namespaceURI)e=wg(e),t=dy(e,t);else switch(t){case"svg":t=1;break;case"math":t=2;break;default:t=0}}Gt(nn),bt(nn,t)}function Za(){Gt(nn),Gt(ti),Gt(Pn)}function Us(t){t.memoizedState!==null&&bt(Ur,t);var e=nn.current,n=dy(e,t.type);e!==n&&(bt(ti,t),bt(nn,n))}function Vr(t){ti.current===t&&(Gt(nn),Gt(ti)),Ur.current===t&&(Gt(Ur),fi._currentValue=Ro)}var Pc,yp;function To(t){if(Pc===void 0)try{throw Error()}catch(n){var e=n.stack.trim().match(/\n( *(at )?)/);Pc=e&&e[1]||"",yp=-1<n.stack.indexOf(`
1
+ "use strict";(()=>{var o_=Object.create;var qh=Object.defineProperty;var a_=Object.getOwnPropertyDescriptor;var l_=Object.getOwnPropertyNames;var i_=Object.getPrototypeOf,r_=Object.prototype.hasOwnProperty;var re=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports);var u_=(t,e,n,o)=>{if(e&&typeof e=="object"||typeof e=="function")for(let a of l_(e))!r_.call(t,a)&&a!==n&&qh(t,a,{get:()=>e[a],enumerable:!(o=a_(e,a))||o.enumerable});return t};var We=(t,e,n)=>(n=t!=null?o_(i_(t)):{},u_(e||!t||!t.__esModule?qh(n,"default",{value:t,enumerable:!0}):n,t));var Fh=re(P=>{"use strict";var Vc=Symbol.for("react.transitional.element"),c_=Symbol.for("react.portal"),s_=Symbol.for("react.fragment"),f_=Symbol.for("react.strict_mode"),d_=Symbol.for("react.profiler"),h_=Symbol.for("react.consumer"),p_=Symbol.for("react.context"),g_=Symbol.for("react.forward_ref"),m_=Symbol.for("react.suspense"),y_=Symbol.for("react.memo"),jh=Symbol.for("react.lazy"),v_=Symbol.for("react.activity"),Xh=Symbol.iterator;function b_(t){return t===null||typeof t!="object"?null:(t=Xh&&t[Xh]||t["@@iterator"],typeof t=="function"?t:null)}var Kh={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},$h=Object.assign,Jh={};function ma(t,e,n){this.props=t,this.context=e,this.refs=Jh,this.updater=n||Kh}ma.prototype.isReactComponent={};ma.prototype.setState=function(t,e){if(typeof t!="object"&&typeof t!="function"&&t!=null)throw Error("takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,t,e,"setState")};ma.prototype.forceUpdate=function(t){this.updater.enqueueForceUpdate(this,t,"forceUpdate")};function Ih(){}Ih.prototype=ma.prototype;function qc(t,e,n){this.props=t,this.context=e,this.refs=Jh,this.updater=n||Kh}var Xc=qc.prototype=new Ih;Xc.constructor=qc;$h(Xc,ma.prototype);Xc.isPureReactComponent=!0;var Zh=Array.isArray;function Yc(){}var xt={H:null,A:null,T:null,S:null},Wh=Object.prototype.hasOwnProperty;function Zc(t,e,n){var o=n.ref;return{$$typeof:Vc,type:t,key:e,ref:o!==void 0?o:null,props:n}}function x_(t,e){return Zc(t.type,e,t.props)}function Gc(t){return typeof t=="object"&&t!==null&&t.$$typeof===Vc}function S_(t){var e={"=":"=0",":":"=2"};return"$"+t.replace(/[=:]/g,function(n){return e[n]})}var Gh=/\/+/g;function Uc(t,e){return typeof t=="object"&&t!==null&&t.key!=null?S_(""+t.key):e.toString(36)}function __(t){switch(t.status){case"fulfilled":return t.value;case"rejected":throw t.reason;default:switch(typeof t.status=="string"?t.then(Yc,Yc):(t.status="pending",t.then(function(e){t.status==="pending"&&(t.status="fulfilled",t.value=e)},function(e){t.status==="pending"&&(t.status="rejected",t.reason=e)})),t.status){case"fulfilled":return t.value;case"rejected":throw t.reason}}throw t}function ga(t,e,n,o,a){var l=typeof t;(l==="undefined"||l==="boolean")&&(t=null);var i=!1;if(t===null)i=!0;else switch(l){case"bigint":case"string":case"number":i=!0;break;case"object":switch(t.$$typeof){case Vc:case c_:i=!0;break;case jh:return i=t._init,ga(i(t._payload),e,n,o,a)}}if(i)return a=a(t),i=o===""?"."+Uc(t,0):o,Zh(a)?(n="",i!=null&&(n=i.replace(Gh,"$&/")+"/"),ga(a,e,n,"",function(s){return s})):a!=null&&(Gc(a)&&(a=x_(a,n+(a.key==null||t&&t.key===a.key?"":(""+a.key).replace(Gh,"$&/")+"/")+i)),e.push(a)),1;i=0;var r=o===""?".":o+":";if(Zh(t))for(var u=0;u<t.length;u++)o=t[u],l=r+Uc(o,u),i+=ga(o,e,n,l,a);else if(u=b_(t),typeof u=="function")for(t=u.call(t),u=0;!(o=t.next()).done;)o=o.value,l=r+Uc(o,u++),i+=ga(o,e,n,l,a);else if(l==="object"){if(typeof t.then=="function")return ga(__(t),e,n,o,a);throw e=String(t),Error("Objects are not valid as a React child (found: "+(e==="[object Object]"?"object with keys {"+Object.keys(t).join(", ")+"}":e)+"). If you meant to render a collection of children, use an array instead.")}return i}function tr(t,e,n){if(t==null)return t;var o=[],a=0;return ga(t,o,"","",function(l){return e.call(n,l,a++)}),o}function w_(t){if(t._status===-1){var e=t._result;e=e(),e.then(function(n){(t._status===0||t._status===-1)&&(t._status=1,t._result=n)},function(n){(t._status===0||t._status===-1)&&(t._status=2,t._result=n)}),t._status===-1&&(t._status=0,t._result=e)}if(t._status===1)return t._result.default;throw t._result}var Qh=typeof reportError=="function"?reportError:function(t){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var e=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof t=="object"&&t!==null&&typeof t.message=="string"?String(t.message):String(t),error:t});if(!window.dispatchEvent(e))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",t);return}console.error(t)},E_={map:tr,forEach:function(t,e,n){tr(t,function(){e.apply(this,arguments)},n)},count:function(t){var e=0;return tr(t,function(){e++}),e},toArray:function(t){return tr(t,function(e){return e})||[]},only:function(t){if(!Gc(t))throw Error("React.Children.only expected to receive a single React element child.");return t}};P.Activity=v_;P.Children=E_;P.Component=ma;P.Fragment=s_;P.Profiler=d_;P.PureComponent=qc;P.StrictMode=f_;P.Suspense=m_;P.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=xt;P.__COMPILER_RUNTIME={__proto__:null,c:function(t){return xt.H.useMemoCache(t)}};P.cache=function(t){return function(){return t.apply(null,arguments)}};P.cacheSignal=function(){return null};P.cloneElement=function(t,e,n){if(t==null)throw Error("The argument must be a React element, but you passed "+t+".");var o=$h({},t.props),a=t.key;if(e!=null)for(l in e.key!==void 0&&(a=""+e.key),e)!Wh.call(e,l)||l==="key"||l==="__self"||l==="__source"||l==="ref"&&e.ref===void 0||(o[l]=e[l]);var l=arguments.length-2;if(l===1)o.children=n;else if(1<l){for(var i=Array(l),r=0;r<l;r++)i[r]=arguments[r+2];o.children=i}return Zc(t.type,a,o)};P.createContext=function(t){return t={$$typeof:p_,_currentValue:t,_currentValue2:t,_threadCount:0,Provider:null,Consumer:null},t.Provider=t,t.Consumer={$$typeof:h_,_context:t},t};P.createElement=function(t,e,n){var o,a={},l=null;if(e!=null)for(o in e.key!==void 0&&(l=""+e.key),e)Wh.call(e,o)&&o!=="key"&&o!=="__self"&&o!=="__source"&&(a[o]=e[o]);var i=arguments.length-2;if(i===1)a.children=n;else if(1<i){for(var r=Array(i),u=0;u<i;u++)r[u]=arguments[u+2];a.children=r}if(t&&t.defaultProps)for(o in i=t.defaultProps,i)a[o]===void 0&&(a[o]=i[o]);return Zc(t,l,a)};P.createRef=function(){return{current:null}};P.forwardRef=function(t){return{$$typeof:g_,render:t}};P.isValidElement=Gc;P.lazy=function(t){return{$$typeof:jh,_payload:{_status:-1,_result:t},_init:w_}};P.memo=function(t,e){return{$$typeof:y_,type:t,compare:e===void 0?null:e}};P.startTransition=function(t){var e=xt.T,n={};xt.T=n;try{var o=t(),a=xt.S;a!==null&&a(n,o),typeof o=="object"&&o!==null&&typeof o.then=="function"&&o.then(Yc,Qh)}catch(l){Qh(l)}finally{e!==null&&n.types!==null&&(e.types=n.types),xt.T=e}};P.unstable_useCacheRefresh=function(){return xt.H.useCacheRefresh()};P.use=function(t){return xt.H.use(t)};P.useActionState=function(t,e,n){return xt.H.useActionState(t,e,n)};P.useCallback=function(t,e){return xt.H.useCallback(t,e)};P.useContext=function(t){return xt.H.useContext(t)};P.useDebugValue=function(){};P.useDeferredValue=function(t,e){return xt.H.useDeferredValue(t,e)};P.useEffect=function(t,e){return xt.H.useEffect(t,e)};P.useEffectEvent=function(t){return xt.H.useEffectEvent(t)};P.useId=function(){return xt.H.useId()};P.useImperativeHandle=function(t,e,n){return xt.H.useImperativeHandle(t,e,n)};P.useInsertionEffect=function(t,e){return xt.H.useInsertionEffect(t,e)};P.useLayoutEffect=function(t,e){return xt.H.useLayoutEffect(t,e)};P.useMemo=function(t,e){return xt.H.useMemo(t,e)};P.useOptimistic=function(t,e){return xt.H.useOptimistic(t,e)};P.useReducer=function(t,e,n){return xt.H.useReducer(t,e,n)};P.useRef=function(t){return xt.H.useRef(t)};P.useState=function(t){return xt.H.useState(t)};P.useSyncExternalStore=function(t,e,n){return xt.H.useSyncExternalStore(t,e,n)};P.useTransition=function(){return xt.H.useTransition()};P.version="19.2.7"});var hn=re((sC,Ph)=>{"use strict";Ph.exports=Fh()});var cp=re(Nt=>{"use strict";function $c(t,e){var n=t.length;t.push(e);t:for(;0<n;){var o=n-1>>>1,a=t[o];if(0<er(a,e))t[o]=e,t[n]=a,n=o;else break t}}function Fe(t){return t.length===0?null:t[0]}function or(t){if(t.length===0)return null;var e=t[0],n=t.pop();if(n!==e){t[0]=n;t:for(var o=0,a=t.length,l=a>>>1;o<l;){var i=2*(o+1)-1,r=t[i],u=i+1,s=t[u];if(0>er(r,n))u<a&&0>er(s,r)?(t[o]=s,t[u]=n,o=u):(t[o]=r,t[i]=n,o=i);else if(u<a&&0>er(s,n))t[o]=s,t[u]=n,o=u;else break t}}return e}function er(t,e){var n=t.sortIndex-e.sortIndex;return n!==0?n:t.id-e.id}Nt.unstable_now=void 0;typeof performance=="object"&&typeof performance.now=="function"?(tp=performance,Nt.unstable_now=function(){return tp.now()}):(Qc=Date,ep=Qc.now(),Nt.unstable_now=function(){return Qc.now()-ep});var tp,Qc,ep,pn=[],Vn=[],N_=1,ze=null,Ft=3,Jc=!1,Nl=!1,Ml=!1,Ic=!1,ap=typeof setTimeout=="function"?setTimeout:null,lp=typeof clearTimeout=="function"?clearTimeout:null,np=typeof setImmediate<"u"?setImmediate:null;function nr(t){for(var e=Fe(Vn);e!==null;){if(e.callback===null)or(Vn);else if(e.startTime<=t)or(Vn),e.sortIndex=e.expirationTime,$c(pn,e);else break;e=Fe(Vn)}}function Wc(t){if(Ml=!1,nr(t),!Nl)if(Fe(pn)!==null)Nl=!0,va||(va=!0,ya());else{var e=Fe(Vn);e!==null&&Fc(Wc,e.startTime-t)}}var va=!1,zl=-1,ip=5,rp=-1;function up(){return Ic?!0:!(Nt.unstable_now()-rp<ip)}function jc(){if(Ic=!1,va){var t=Nt.unstable_now();rp=t;var e=!0;try{t:{Nl=!1,Ml&&(Ml=!1,lp(zl),zl=-1),Jc=!0;var n=Ft;try{e:{for(nr(t),ze=Fe(pn);ze!==null&&!(ze.expirationTime>t&&up());){var o=ze.callback;if(typeof o=="function"){ze.callback=null,Ft=ze.priorityLevel;var a=o(ze.expirationTime<=t);if(t=Nt.unstable_now(),typeof a=="function"){ze.callback=a,nr(t),e=!0;break e}ze===Fe(pn)&&or(pn),nr(t)}else or(pn);ze=Fe(pn)}if(ze!==null)e=!0;else{var l=Fe(Vn);l!==null&&Fc(Wc,l.startTime-t),e=!1}}break t}finally{ze=null,Ft=n,Jc=!1}e=void 0}}finally{e?ya():va=!1}}}var ya;typeof np=="function"?ya=function(){np(jc)}:typeof MessageChannel<"u"?(Kc=new MessageChannel,op=Kc.port2,Kc.port1.onmessage=jc,ya=function(){op.postMessage(null)}):ya=function(){ap(jc,0)};var Kc,op;function Fc(t,e){zl=ap(function(){t(Nt.unstable_now())},e)}Nt.unstable_IdlePriority=5;Nt.unstable_ImmediatePriority=1;Nt.unstable_LowPriority=4;Nt.unstable_NormalPriority=3;Nt.unstable_Profiling=null;Nt.unstable_UserBlockingPriority=2;Nt.unstable_cancelCallback=function(t){t.callback=null};Nt.unstable_forceFrameRate=function(t){0>t||125<t?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):ip=0<t?Math.floor(1e3/t):5};Nt.unstable_getCurrentPriorityLevel=function(){return Ft};Nt.unstable_next=function(t){switch(Ft){case 1:case 2:case 3:var e=3;break;default:e=Ft}var n=Ft;Ft=e;try{return t()}finally{Ft=n}};Nt.unstable_requestPaint=function(){Ic=!0};Nt.unstable_runWithPriority=function(t,e){switch(t){case 1:case 2:case 3:case 4:case 5:break;default:t=3}var n=Ft;Ft=t;try{return e()}finally{Ft=n}};Nt.unstable_scheduleCallback=function(t,e,n){var o=Nt.unstable_now();switch(typeof n=="object"&&n!==null?(n=n.delay,n=typeof n=="number"&&0<n?o+n:o):n=o,t){case 1:var a=-1;break;case 2:a=250;break;case 5:a=1073741823;break;case 4:a=1e4;break;default:a=5e3}return a=n+a,t={id:N_++,callback:e,priorityLevel:t,startTime:n,expirationTime:a,sortIndex:-1},n>o?(t.sortIndex=n,$c(Vn,t),Fe(pn)===null&&t===Fe(Vn)&&(Ml?(lp(zl),zl=-1):Ml=!0,Fc(Wc,n-o))):(t.sortIndex=a,$c(pn,t),Nl||Jc||(Nl=!0,va||(va=!0,ya()))),t};Nt.unstable_shouldYield=up;Nt.unstable_wrapCallback=function(t){var e=Ft;return function(){var n=Ft;Ft=e;try{return t.apply(this,arguments)}finally{Ft=n}}}});var fp=re((dC,sp)=>{"use strict";sp.exports=cp()});var hp=re(ee=>{"use strict";var M_=hn();function dp(t){var e="https://react.dev/errors/"+t;if(1<arguments.length){e+="?args[]="+encodeURIComponent(arguments[1]);for(var n=2;n<arguments.length;n++)e+="&args[]="+encodeURIComponent(arguments[n])}return"Minified React error #"+t+"; visit "+e+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function qn(){}var te={d:{f:qn,r:function(){throw Error(dp(522))},D:qn,C:qn,L:qn,m:qn,X:qn,S:qn,M:qn},p:0,findDOMNode:null},z_=Symbol.for("react.portal");function A_(t,e,n){var o=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:z_,key:o==null?null:""+o,children:t,containerInfo:e,implementation:n}}var Al=M_.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function ar(t,e){if(t==="font")return"";if(typeof e=="string")return e==="use-credentials"?e:""}ee.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=te;ee.createPortal=function(t,e){var n=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)throw Error(dp(299));return A_(t,e,null,n)};ee.flushSync=function(t){var e=Al.T,n=te.p;try{if(Al.T=null,te.p=2,t)return t()}finally{Al.T=e,te.p=n,te.d.f()}};ee.preconnect=function(t,e){typeof t=="string"&&(e?(e=e.crossOrigin,e=typeof e=="string"?e==="use-credentials"?e:"":void 0):e=null,te.d.C(t,e))};ee.prefetchDNS=function(t){typeof t=="string"&&te.d.D(t)};ee.preinit=function(t,e){if(typeof t=="string"&&e&&typeof e.as=="string"){var n=e.as,o=ar(n,e.crossOrigin),a=typeof e.integrity=="string"?e.integrity:void 0,l=typeof e.fetchPriority=="string"?e.fetchPriority:void 0;n==="style"?te.d.S(t,typeof e.precedence=="string"?e.precedence:void 0,{crossOrigin:o,integrity:a,fetchPriority:l}):n==="script"&&te.d.X(t,{crossOrigin:o,integrity:a,fetchPriority:l,nonce:typeof e.nonce=="string"?e.nonce:void 0})}};ee.preinitModule=function(t,e){if(typeof t=="string")if(typeof e=="object"&&e!==null){if(e.as==null||e.as==="script"){var n=ar(e.as,e.crossOrigin);te.d.M(t,{crossOrigin:n,integrity:typeof e.integrity=="string"?e.integrity:void 0,nonce:typeof e.nonce=="string"?e.nonce:void 0})}}else e==null&&te.d.M(t)};ee.preload=function(t,e){if(typeof t=="string"&&typeof e=="object"&&e!==null&&typeof e.as=="string"){var n=e.as,o=ar(n,e.crossOrigin);te.d.L(t,n,{crossOrigin:o,integrity:typeof e.integrity=="string"?e.integrity:void 0,nonce:typeof e.nonce=="string"?e.nonce:void 0,type:typeof e.type=="string"?e.type:void 0,fetchPriority:typeof e.fetchPriority=="string"?e.fetchPriority:void 0,referrerPolicy:typeof e.referrerPolicy=="string"?e.referrerPolicy:void 0,imageSrcSet:typeof e.imageSrcSet=="string"?e.imageSrcSet:void 0,imageSizes:typeof e.imageSizes=="string"?e.imageSizes:void 0,media:typeof e.media=="string"?e.media:void 0})}};ee.preloadModule=function(t,e){if(typeof t=="string")if(e){var n=ar(e.as,e.crossOrigin);te.d.m(t,{as:typeof e.as=="string"&&e.as!=="script"?e.as:void 0,crossOrigin:n,integrity:typeof e.integrity=="string"?e.integrity:void 0})}else te.d.m(t)};ee.requestFormReset=function(t){te.d.r(t)};ee.unstable_batchedUpdates=function(t,e){return t(e)};ee.useFormState=function(t,e,n){return Al.H.useFormState(t,e,n)};ee.useFormStatus=function(){return Al.H.useHostTransitionStatus()};ee.version="19.2.7"});var Pc=re((pC,gp)=>{"use strict";function pp(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(pp)}catch(t){console.error(t)}}pp(),gp.exports=hp()});var zy=re(Cu=>{"use strict";var Vt=fp(),qg=hn(),C_=Pc();function L(t){var e="https://react.dev/errors/"+t;if(1<arguments.length){e+="?args[]="+encodeURIComponent(arguments[1]);for(var n=2;n<arguments.length;n++)e+="&args[]="+encodeURIComponent(arguments[n])}return"Minified React error #"+t+"; visit "+e+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function Xg(t){return!(!t||t.nodeType!==1&&t.nodeType!==9&&t.nodeType!==11)}function pi(t){var e=t,n=t;if(t.alternate)for(;e.return;)e=e.return;else{t=e;do e=t,(e.flags&4098)!==0&&(n=e.return),t=e.return;while(t)}return e.tag===3?n:null}function Zg(t){if(t.tag===13){var e=t.memoizedState;if(e===null&&(t=t.alternate,t!==null&&(e=t.memoizedState)),e!==null)return e.dehydrated}return null}function Gg(t){if(t.tag===31){var e=t.memoizedState;if(e===null&&(t=t.alternate,t!==null&&(e=t.memoizedState)),e!==null)return e.dehydrated}return null}function mp(t){if(pi(t)!==t)throw Error(L(188))}function T_(t){var e=t.alternate;if(!e){if(e=pi(t),e===null)throw Error(L(188));return e!==t?null:t}for(var n=t,o=e;;){var a=n.return;if(a===null)break;var l=a.alternate;if(l===null){if(o=a.return,o!==null){n=o;continue}break}if(a.child===l.child){for(l=a.child;l;){if(l===n)return mp(a),t;if(l===o)return mp(a),e;l=l.sibling}throw Error(L(188))}if(n.return!==o.return)n=a,o=l;else{for(var i=!1,r=a.child;r;){if(r===n){i=!0,n=a,o=l;break}if(r===o){i=!0,o=a,n=l;break}r=r.sibling}if(!i){for(r=l.child;r;){if(r===n){i=!0,n=l,o=a;break}if(r===o){i=!0,o=l,n=a;break}r=r.sibling}if(!i)throw Error(L(189))}}if(n.alternate!==o)throw Error(L(190))}if(n.tag!==3)throw Error(L(188));return n.stateNode.current===n?t:e}function Qg(t){var e=t.tag;if(e===5||e===26||e===27||e===6)return t;for(t=t.child;t!==null;){if(e=Qg(t),e!==null)return e;t=t.sibling}return null}var wt=Object.assign,O_=Symbol.for("react.element"),lr=Symbol.for("react.transitional.element"),kl=Symbol.for("react.portal"),Ea=Symbol.for("react.fragment"),jg=Symbol.for("react.strict_mode"),Hs=Symbol.for("react.profiler"),Kg=Symbol.for("react.consumer"),_n=Symbol.for("react.context"),Cf=Symbol.for("react.forward_ref"),Rs=Symbol.for("react.suspense"),Bs=Symbol.for("react.suspense_list"),Tf=Symbol.for("react.memo"),Xn=Symbol.for("react.lazy"),ks=Symbol.for("react.activity"),D_=Symbol.for("react.memo_cache_sentinel"),yp=Symbol.iterator;function Cl(t){return t===null||typeof t!="object"?null:(t=yp&&t[yp]||t["@@iterator"],typeof t=="function"?t:null)}var H_=Symbol.for("react.client.reference");function Ls(t){if(t==null)return null;if(typeof t=="function")return t.$$typeof===H_?null:t.displayName||t.name||null;if(typeof t=="string")return t;switch(t){case Ea:return"Fragment";case Hs:return"Profiler";case jg:return"StrictMode";case Rs:return"Suspense";case Bs:return"SuspenseList";case ks:return"Activity"}if(typeof t=="object")switch(t.$$typeof){case kl:return"Portal";case _n:return t.displayName||"Context";case Kg:return(t._context.displayName||"Context")+".Consumer";case Cf:var e=t.render;return t=t.displayName,t||(t=e.displayName||e.name||"",t=t!==""?"ForwardRef("+t+")":"ForwardRef"),t;case Tf:return e=t.displayName||null,e!==null?e:Ls(t.type)||"Memo";case Xn:e=t._payload,t=t._init;try{return Ls(t(e))}catch{}}return null}var Ll=Array.isArray,F=qg.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,ft=C_.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,Ro={pending:!1,data:null,method:null,action:null},Us=[],Na=-1;function on(t){return{current:t}}function Gt(t){0>Na||(t.current=Us[Na],Us[Na]=null,Na--)}function bt(t,e){Na++,Us[Na]=t.current,t.current=e}var nn=on(null),ti=on(null),Pn=on(null),Ur=on(null);function Yr(t,e){switch(bt(Pn,e),bt(ti,t),bt(nn,null),e.nodeType){case 9:case 11:t=(t=e.documentElement)&&(t=t.namespaceURI)?Eg(t):0;break;default:if(t=e.tagName,e=e.namespaceURI)e=Eg(e),t=hy(e,t);else switch(t){case"svg":t=1;break;case"math":t=2;break;default:t=0}}Gt(nn),bt(nn,t)}function Za(){Gt(nn),Gt(ti),Gt(Pn)}function Ys(t){t.memoizedState!==null&&bt(Ur,t);var e=nn.current,n=hy(e,t.type);e!==n&&(bt(ti,t),bt(nn,n))}function Vr(t){ti.current===t&&(Gt(nn),Gt(ti)),Ur.current===t&&(Gt(Ur),fi._currentValue=Ro)}var ts,vp;function To(t){if(ts===void 0)try{throw Error()}catch(n){var e=n.stack.trim().match(/\n( *(at )?)/);ts=e&&e[1]||"",vp=-1<n.stack.indexOf(`
2
2
  at`)?" (<anonymous>)":-1<n.stack.indexOf("@")?"@unknown:0:0":""}return`
3
- `+Pc+t+yp}var ts=!1;function es(t,e){if(!t||ts)return"";ts=!0;var n=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var o={DetermineComponentFrameRoot:function(){try{if(e){var d=function(){throw Error()};if(Object.defineProperty(d.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(d,[])}catch(p){var f=p}Reflect.construct(t,[],d)}else{try{d.call()}catch(p){f=p}t.call(d.prototype)}}else{try{throw Error()}catch(p){f=p}(d=t())&&typeof d.catch=="function"&&d.catch(function(){})}}catch(p){if(p&&f&&typeof p.stack=="string")return[p.stack,f.stack]}return[null,null]}};o.DetermineComponentFrameRoot.displayName="DetermineComponentFrameRoot";var a=Object.getOwnPropertyDescriptor(o.DetermineComponentFrameRoot,"name");a&&a.configurable&&Object.defineProperty(o.DetermineComponentFrameRoot,"name",{value:"DetermineComponentFrameRoot"});var l=o.DetermineComponentFrameRoot(),i=l[0],r=l[1];if(i&&r){var u=i.split(`
3
+ `+ts+t+vp}var es=!1;function ns(t,e){if(!t||es)return"";es=!0;var n=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var o={DetermineComponentFrameRoot:function(){try{if(e){var d=function(){throw Error()};if(Object.defineProperty(d.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(d,[])}catch(p){var f=p}Reflect.construct(t,[],d)}else{try{d.call()}catch(p){f=p}t.call(d.prototype)}}else{try{throw Error()}catch(p){f=p}(d=t())&&typeof d.catch=="function"&&d.catch(function(){})}}catch(p){if(p&&f&&typeof p.stack=="string")return[p.stack,f.stack]}return[null,null]}};o.DetermineComponentFrameRoot.displayName="DetermineComponentFrameRoot";var a=Object.getOwnPropertyDescriptor(o.DetermineComponentFrameRoot,"name");a&&a.configurable&&Object.defineProperty(o.DetermineComponentFrameRoot,"name",{value:"DetermineComponentFrameRoot"});var l=o.DetermineComponentFrameRoot(),i=l[0],r=l[1];if(i&&r){var u=i.split(`
4
4
  `),s=r.split(`
5
5
  `);for(a=o=0;o<u.length&&!u[o].includes("DetermineComponentFrameRoot");)o++;for(;a<s.length&&!s[a].includes("DetermineComponentFrameRoot");)a++;if(o===u.length||a===s.length)for(o=u.length-1,a=s.length-1;1<=o&&0<=a&&u[o]!==s[a];)a--;for(;1<=o&&0<=a;o--,a--)if(u[o]!==s[a]){if(o!==1||a!==1)do if(o--,a--,0>a||u[o]!==s[a]){var c=`
6
- `+u[o].replace(" at new "," at ");return t.displayName&&c.includes("<anonymous>")&&(c=c.replace("<anonymous>",t.displayName)),c}while(1<=o&&0<=a);break}}}finally{ts=!1,Error.prepareStackTrace=n}return(n=t?t.displayName||t.name:"")?To(n):""}function R_(t,e){switch(t.tag){case 26:case 27:case 5:return To(t.type);case 16:return To("Lazy");case 13:return t.child!==e&&e!==null?To("Suspense Fallback"):To("Suspense");case 19:return To("SuspenseList");case 0:case 15:return es(t.type,!1);case 11:return es(t.type.render,!1);case 1:return es(t.type,!0);case 31:return To("Activity");default:return""}}function vp(t){try{var e="",n=null;do e+=R_(t,n),n=t,t=t.return;while(t);return e}catch(o){return`
6
+ `+u[o].replace(" at new "," at ");return t.displayName&&c.includes("<anonymous>")&&(c=c.replace("<anonymous>",t.displayName)),c}while(1<=o&&0<=a);break}}}finally{es=!1,Error.prepareStackTrace=n}return(n=t?t.displayName||t.name:"")?To(n):""}function R_(t,e){switch(t.tag){case 26:case 27:case 5:return To(t.type);case 16:return To("Lazy");case 13:return t.child!==e&&e!==null?To("Suspense Fallback"):To("Suspense");case 19:return To("SuspenseList");case 0:case 15:return ns(t.type,!1);case 11:return ns(t.type.render,!1);case 1:return ns(t.type,!0);case 31:return To("Activity");default:return""}}function bp(t){try{var e="",n=null;do e+=R_(t,n),n=t,t=t.return;while(t);return e}catch(o){return`
7
7
  Error generating stack: `+o.message+`
8
- `+o.stack}}var Ys=Object.prototype.hasOwnProperty,Tf=Vt.unstable_scheduleCallback,ns=Vt.unstable_cancelCallback,B_=Vt.unstable_shouldYield,k_=Vt.unstable_requestPaint,xe=Vt.unstable_now,L_=Vt.unstable_getCurrentPriorityLevel,Kg=Vt.unstable_ImmediatePriority,$g=Vt.unstable_UserBlockingPriority,qr=Vt.unstable_NormalPriority,U_=Vt.unstable_LowPriority,Jg=Vt.unstable_IdlePriority,Y_=Vt.log,V_=Vt.unstable_setDisableYieldValue,gi=null,Se=null;function $n(t){if(typeof Y_=="function"&&V_(t),Se&&typeof Se.setStrictMode=="function")try{Se.setStrictMode(gi,t)}catch{}}var _e=Math.clz32?Math.clz32:Z_,q_=Math.log,X_=Math.LN2;function Z_(t){return t>>>=0,t===0?32:31-(q_(t)/X_|0)|0}var ir=256,rr=262144,ur=4194304;function Oo(t){var e=t&42;if(e!==0)return e;switch(t&-t){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:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:return t&261888;case 262144:case 524288:case 1048576:case 2097152:return t&3932160;case 4194304:case 8388608:case 16777216:case 33554432:return t&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return t}}function hu(t,e,n){var o=t.pendingLanes;if(o===0)return 0;var a=0,l=t.suspendedLanes,i=t.pingedLanes;t=t.warmLanes;var r=o&134217727;return r!==0?(o=r&~l,o!==0?a=Oo(o):(i&=r,i!==0?a=Oo(i):n||(n=r&~t,n!==0&&(a=Oo(n))))):(r=o&~l,r!==0?a=Oo(r):i!==0?a=Oo(i):n||(n=o&~t,n!==0&&(a=Oo(n)))),a===0?0:e!==0&&e!==a&&(e&l)===0&&(l=a&-a,n=e&-e,l>=n||l===32&&(n&4194048)!==0)?e:a}function mi(t,e){return(t.pendingLanes&~(t.suspendedLanes&~t.pingedLanes)&e)===0}function G_(t,e){switch(t){case 1:case 2:case 4:case 8:case 64:return e+250;case 16:case 32: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 e+5e3;case 4194304:case 8388608:case 16777216:case 33554432:return-1;case 67108864:case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function Ig(){var t=ur;return ur<<=1,(ur&62914560)===0&&(ur=4194304),t}function os(t){for(var e=[],n=0;31>n;n++)e.push(t);return e}function yi(t,e){t.pendingLanes|=e,e!==268435456&&(t.suspendedLanes=0,t.pingedLanes=0,t.warmLanes=0)}function Q_(t,e,n,o,a,l){var i=t.pendingLanes;t.pendingLanes=n,t.suspendedLanes=0,t.pingedLanes=0,t.warmLanes=0,t.expiredLanes&=n,t.entangledLanes&=n,t.errorRecoveryDisabledLanes&=n,t.shellSuspendCounter=0;var r=t.entanglements,u=t.expirationTimes,s=t.hiddenUpdates;for(n=i&~n;0<n;){var c=31-_e(n),d=1<<c;r[c]=0,u[c]=-1;var f=s[c];if(f!==null)for(s[c]=null,c=0;c<f.length;c++){var p=f[c];p!==null&&(p.lane&=-536870913)}n&=~d}o!==0&&Wg(t,o,0),l!==0&&a===0&&t.tag!==0&&(t.suspendedLanes|=l&~(i&~e))}function Wg(t,e,n){t.pendingLanes|=e,t.suspendedLanes&=~e;var o=31-_e(e);t.entangledLanes|=e,t.entanglements[o]=t.entanglements[o]|1073741824|n&261930}function Fg(t,e){var n=t.entangledLanes|=e;for(t=t.entanglements;n;){var o=31-_e(n),a=1<<o;a&e|t[o]&e&&(t[o]|=e),n&=~a}}function Pg(t,e){var n=e&-e;return n=(n&42)!==0?1:Of(n),(n&(t.suspendedLanes|e))!==0?0:n}function Of(t){switch(t){case 2:t=1;break;case 8:t=4;break;case 32:t=16;break;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:t=128;break;case 268435456:t=134217728;break;default:t=0}return t}function Df(t){return t&=-t,2<t?8<t?(t&134217727)!==0?32:268435456:8:2}function tm(){var t=ft.p;return t!==0?t:(t=window.event,t===void 0?32:wy(t.type))}function bp(t,e){var n=ft.p;try{return ft.p=t,e()}finally{ft.p=n}}var ho=Math.random().toString(36).slice(2),Kt="__reactFiber$"+ho,he="__reactProps$"+ho,tl="__reactContainer$"+ho,Vs="__reactEvents$"+ho,j_="__reactListeners$"+ho,K_="__reactHandles$"+ho,xp="__reactResources$"+ho,vi="__reactMarker$"+ho;function Hf(t){delete t[Kt],delete t[he],delete t[Vs],delete t[j_],delete t[K_]}function Ma(t){var e=t[Kt];if(e)return e;for(var n=t.parentNode;n;){if(e=n[tl]||n[Kt]){if(n=e.alternate,e.child!==null||n!==null&&n.child!==null)for(t=Ag(t);t!==null;){if(n=t[Kt])return n;t=Ag(t)}return e}t=n,n=t.parentNode}return null}function el(t){if(t=t[Kt]||t[tl]){var e=t.tag;if(e===5||e===6||e===13||e===31||e===26||e===27||e===3)return t}return null}function Ul(t){var e=t.tag;if(e===5||e===26||e===27||e===6)return t.stateNode;throw Error(L(33))}function ka(t){var e=t[xp];return e||(e=t[xp]={hoistableStyles:new Map,hoistableScripts:new Map}),e}function Zt(t){t[vi]=!0}var em=new Set,nm={};function Go(t,e){Ga(t,e),Ga(t+"Capture",e)}function Ga(t,e){for(nm[t]=e,t=0;t<e.length;t++)em.add(e[t])}var $_=RegExp("^[:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD][:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$"),Sp={},_p={};function J_(t){return Ys.call(_p,t)?!0:Ys.call(Sp,t)?!1:$_.test(t)?_p[t]=!0:(Sp[t]=!0,!1)}function wr(t,e,n){if(J_(e))if(n===null)t.removeAttribute(e);else{switch(typeof n){case"undefined":case"function":case"symbol":t.removeAttribute(e);return;case"boolean":var o=e.toLowerCase().slice(0,5);if(o!=="data-"&&o!=="aria-"){t.removeAttribute(e);return}}t.setAttribute(e,""+n)}}function cr(t,e,n){if(n===null)t.removeAttribute(e);else{switch(typeof n){case"undefined":case"function":case"symbol":case"boolean":t.removeAttribute(e);return}t.setAttribute(e,""+n)}}function gn(t,e,n,o){if(o===null)t.removeAttribute(n);else{switch(typeof o){case"undefined":case"function":case"symbol":case"boolean":t.removeAttribute(n);return}t.setAttributeNS(e,n,""+o)}}function Ce(t){switch(typeof t){case"bigint":case"boolean":case"number":case"string":case"undefined":return t;case"object":return t;default:return""}}function om(t){var e=t.type;return(t=t.nodeName)&&t.toLowerCase()==="input"&&(e==="checkbox"||e==="radio")}function I_(t,e,n){var o=Object.getOwnPropertyDescriptor(t.constructor.prototype,e);if(!t.hasOwnProperty(e)&&typeof o<"u"&&typeof o.get=="function"&&typeof o.set=="function"){var a=o.get,l=o.set;return Object.defineProperty(t,e,{configurable:!0,get:function(){return a.call(this)},set:function(i){n=""+i,l.call(this,i)}}),Object.defineProperty(t,e,{enumerable:o.enumerable}),{getValue:function(){return n},setValue:function(i){n=""+i},stopTracking:function(){t._valueTracker=null,delete t[e]}}}}function qs(t){if(!t._valueTracker){var e=om(t)?"checked":"value";t._valueTracker=I_(t,e,""+t[e])}}function am(t){if(!t)return!1;var e=t._valueTracker;if(!e)return!0;var n=e.getValue(),o="";return t&&(o=om(t)?t.checked?"true":"false":t.value),t=o,t!==n?(e.setValue(t),!0):!1}function Xr(t){if(t=t||(typeof document<"u"?document:void 0),typeof t>"u")return null;try{return t.activeElement||t.body}catch{return t.body}}var W_=/[\n"\\]/g;function De(t){return t.replace(W_,function(e){return"\\"+e.charCodeAt(0).toString(16)+" "})}function Xs(t,e,n,o,a,l,i,r){t.name="",i!=null&&typeof i!="function"&&typeof i!="symbol"&&typeof i!="boolean"?t.type=i:t.removeAttribute("type"),e!=null?i==="number"?(e===0&&t.value===""||t.value!=e)&&(t.value=""+Ce(e)):t.value!==""+Ce(e)&&(t.value=""+Ce(e)):i!=="submit"&&i!=="reset"||t.removeAttribute("value"),e!=null?Zs(t,i,Ce(e)):n!=null?Zs(t,i,Ce(n)):o!=null&&t.removeAttribute("value"),a==null&&l!=null&&(t.defaultChecked=!!l),a!=null&&(t.checked=a&&typeof a!="function"&&typeof a!="symbol"),r!=null&&typeof r!="function"&&typeof r!="symbol"&&typeof r!="boolean"?t.name=""+Ce(r):t.removeAttribute("name")}function lm(t,e,n,o,a,l,i,r){if(l!=null&&typeof l!="function"&&typeof l!="symbol"&&typeof l!="boolean"&&(t.type=l),e!=null||n!=null){if(!(l!=="submit"&&l!=="reset"||e!=null)){qs(t);return}n=n!=null?""+Ce(n):"",e=e!=null?""+Ce(e):n,r||e===t.value||(t.value=e),t.defaultValue=e}o=o??a,o=typeof o!="function"&&typeof o!="symbol"&&!!o,t.checked=r?t.checked:!!o,t.defaultChecked=!!o,i!=null&&typeof i!="function"&&typeof i!="symbol"&&typeof i!="boolean"&&(t.name=i),qs(t)}function Zs(t,e,n){e==="number"&&Xr(t.ownerDocument)===t||t.defaultValue===""+n||(t.defaultValue=""+n)}function La(t,e,n,o){if(t=t.options,e){e={};for(var a=0;a<n.length;a++)e["$"+n[a]]=!0;for(n=0;n<t.length;n++)a=e.hasOwnProperty("$"+t[n].value),t[n].selected!==a&&(t[n].selected=a),a&&o&&(t[n].defaultSelected=!0)}else{for(n=""+Ce(n),e=null,a=0;a<t.length;a++){if(t[a].value===n){t[a].selected=!0,o&&(t[a].defaultSelected=!0);return}e!==null||t[a].disabled||(e=t[a])}e!==null&&(e.selected=!0)}}function im(t,e,n){if(e!=null&&(e=""+Ce(e),e!==t.value&&(t.value=e),n==null)){t.defaultValue!==e&&(t.defaultValue=e);return}t.defaultValue=n!=null?""+Ce(n):""}function rm(t,e,n,o){if(e==null){if(o!=null){if(n!=null)throw Error(L(92));if(Ll(o)){if(1<o.length)throw Error(L(93));o=o[0]}n=o}n==null&&(n=""),e=n}n=Ce(e),t.defaultValue=n,o=t.textContent,o===n&&o!==""&&o!==null&&(t.value=o),qs(t)}function Qa(t,e){if(e){var n=t.firstChild;if(n&&n===t.lastChild&&n.nodeType===3){n.nodeValue=e;return}}t.textContent=e}var F_=new Set("animationIterationCount aspectRatio borderImageOutset borderImageSlice borderImageWidth boxFlex boxFlexGroup boxOrdinalGroup columnCount columns flex flexGrow flexPositive flexShrink flexNegative flexOrder gridArea gridRow gridRowEnd gridRowSpan gridRowStart gridColumn gridColumnEnd gridColumnSpan gridColumnStart fontWeight lineClamp lineHeight opacity order orphans scale tabSize widows zIndex zoom fillOpacity floodOpacity stopOpacity strokeDasharray strokeDashoffset strokeMiterlimit strokeOpacity strokeWidth MozAnimationIterationCount MozBoxFlex MozBoxFlexGroup MozLineClamp msAnimationIterationCount msFlex msZoom msFlexGrow msFlexNegative msFlexOrder msFlexPositive msFlexShrink msGridColumn msGridColumnSpan msGridRow msGridRowSpan WebkitAnimationIterationCount WebkitBoxFlex WebKitBoxFlexGroup WebkitBoxOrdinalGroup WebkitColumnCount WebkitColumns WebkitFlex WebkitFlexGrow WebkitFlexPositive WebkitFlexShrink WebkitLineClamp".split(" "));function wp(t,e,n){var o=e.indexOf("--")===0;n==null||typeof n=="boolean"||n===""?o?t.setProperty(e,""):e==="float"?t.cssFloat="":t[e]="":o?t.setProperty(e,n):typeof n!="number"||n===0||F_.has(e)?e==="float"?t.cssFloat=n:t[e]=(""+n).trim():t[e]=n+"px"}function um(t,e,n){if(e!=null&&typeof e!="object")throw Error(L(62));if(t=t.style,n!=null){for(var o in n)!n.hasOwnProperty(o)||e!=null&&e.hasOwnProperty(o)||(o.indexOf("--")===0?t.setProperty(o,""):o==="float"?t.cssFloat="":t[o]="");for(var a in e)o=e[a],e.hasOwnProperty(a)&&n[a]!==o&&wp(t,a,o)}else for(var l in e)e.hasOwnProperty(l)&&wp(t,l,e[l])}function Rf(t){if(t.indexOf("-")===-1)return!1;switch(t){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 P_=new Map([["acceptCharset","accept-charset"],["htmlFor","for"],["httpEquiv","http-equiv"],["crossOrigin","crossorigin"],["accentHeight","accent-height"],["alignmentBaseline","alignment-baseline"],["arabicForm","arabic-form"],["baselineShift","baseline-shift"],["capHeight","cap-height"],["clipPath","clip-path"],["clipRule","clip-rule"],["colorInterpolation","color-interpolation"],["colorInterpolationFilters","color-interpolation-filters"],["colorProfile","color-profile"],["colorRendering","color-rendering"],["dominantBaseline","dominant-baseline"],["enableBackground","enable-background"],["fillOpacity","fill-opacity"],["fillRule","fill-rule"],["floodColor","flood-color"],["floodOpacity","flood-opacity"],["fontFamily","font-family"],["fontSize","font-size"],["fontSizeAdjust","font-size-adjust"],["fontStretch","font-stretch"],["fontStyle","font-style"],["fontVariant","font-variant"],["fontWeight","font-weight"],["glyphName","glyph-name"],["glyphOrientationHorizontal","glyph-orientation-horizontal"],["glyphOrientationVertical","glyph-orientation-vertical"],["horizAdvX","horiz-adv-x"],["horizOriginX","horiz-origin-x"],["imageRendering","image-rendering"],["letterSpacing","letter-spacing"],["lightingColor","lighting-color"],["markerEnd","marker-end"],["markerMid","marker-mid"],["markerStart","marker-start"],["overlinePosition","overline-position"],["overlineThickness","overline-thickness"],["paintOrder","paint-order"],["panose-1","panose-1"],["pointerEvents","pointer-events"],["renderingIntent","rendering-intent"],["shapeRendering","shape-rendering"],["stopColor","stop-color"],["stopOpacity","stop-opacity"],["strikethroughPosition","strikethrough-position"],["strikethroughThickness","strikethrough-thickness"],["strokeDasharray","stroke-dasharray"],["strokeDashoffset","stroke-dashoffset"],["strokeLinecap","stroke-linecap"],["strokeLinejoin","stroke-linejoin"],["strokeMiterlimit","stroke-miterlimit"],["strokeOpacity","stroke-opacity"],["strokeWidth","stroke-width"],["textAnchor","text-anchor"],["textDecoration","text-decoration"],["textRendering","text-rendering"],["transformOrigin","transform-origin"],["underlinePosition","underline-position"],["underlineThickness","underline-thickness"],["unicodeBidi","unicode-bidi"],["unicodeRange","unicode-range"],["unitsPerEm","units-per-em"],["vAlphabetic","v-alphabetic"],["vHanging","v-hanging"],["vIdeographic","v-ideographic"],["vMathematical","v-mathematical"],["vectorEffect","vector-effect"],["vertAdvY","vert-adv-y"],["vertOriginX","vert-origin-x"],["vertOriginY","vert-origin-y"],["wordSpacing","word-spacing"],["writingMode","writing-mode"],["xmlnsXlink","xmlns:xlink"],["xHeight","x-height"]]),tw=/^[\u0000-\u001F ]*j[\r\n\t]*a[\r\n\t]*v[\r\n\t]*a[\r\n\t]*s[\r\n\t]*c[\r\n\t]*r[\r\n\t]*i[\r\n\t]*p[\r\n\t]*t[\r\n\t]*:/i;function Er(t){return tw.test(""+t)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":t}function wn(){}var Gs=null;function Bf(t){return t=t.target||t.srcElement||window,t.correspondingUseElement&&(t=t.correspondingUseElement),t.nodeType===3?t.parentNode:t}var za=null,Ua=null;function Ep(t){var e=el(t);if(e&&(t=e.stateNode)){var n=t[he]||null;t:switch(t=e.stateNode,e.type){case"input":if(Xs(t,n.value,n.defaultValue,n.defaultValue,n.checked,n.defaultChecked,n.type,n.name),e=n.name,n.type==="radio"&&e!=null){for(n=t;n.parentNode;)n=n.parentNode;for(n=n.querySelectorAll('input[name="'+De(""+e)+'"][type="radio"]'),e=0;e<n.length;e++){var o=n[e];if(o!==t&&o.form===t.form){var a=o[he]||null;if(!a)throw Error(L(90));Xs(o,a.value,a.defaultValue,a.defaultValue,a.checked,a.defaultChecked,a.type,a.name)}}for(e=0;e<n.length;e++)o=n[e],o.form===t.form&&am(o)}break t;case"textarea":im(t,n.value,n.defaultValue);break t;case"select":e=n.value,e!=null&&La(t,!!n.multiple,e,!1)}}}var as=!1;function cm(t,e,n){if(as)return t(e,n);as=!0;try{var o=t(e);return o}finally{if(as=!1,(za!==null||Ua!==null)&&(Nu(),za&&(e=za,t=Ua,Ua=za=null,Ep(e),t)))for(e=0;e<t.length;e++)Ep(t[e])}}function ei(t,e){var n=t.stateNode;if(n===null)return null;var o=n[he]||null;if(o===null)return null;n=o[e];t:switch(e){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(o=!o.disabled)||(t=t.type,o=!(t==="button"||t==="input"||t==="select"||t==="textarea")),t=!o;break t;default:t=!1}if(t)return null;if(n&&typeof n!="function")throw Error(L(231,e,typeof n));return n}var An=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),Qs=!1;if(An)try{ba={},Object.defineProperty(ba,"passive",{get:function(){Qs=!0}}),window.addEventListener("test",ba,ba),window.removeEventListener("test",ba,ba)}catch{Qs=!1}var ba,Jn=null,kf=null,Nr=null;function sm(){if(Nr)return Nr;var t,e=kf,n=e.length,o,a="value"in Jn?Jn.value:Jn.textContent,l=a.length;for(t=0;t<n&&e[t]===a[t];t++);var i=n-t;for(o=1;o<=i&&e[n-o]===a[l-o];o++);return Nr=a.slice(t,1<o?1-o:void 0)}function Mr(t){var e=t.keyCode;return"charCode"in t?(t=t.charCode,t===0&&e===13&&(t=13)):t=e,t===10&&(t=13),32<=t||t===13?t:0}function sr(){return!0}function Np(){return!1}function pe(t){function e(n,o,a,l,i){this._reactName=n,this._targetInst=a,this.type=o,this.nativeEvent=l,this.target=i,this.currentTarget=null;for(var r in t)t.hasOwnProperty(r)&&(n=t[r],this[r]=n?n(l):l[r]);return this.isDefaultPrevented=(l.defaultPrevented!=null?l.defaultPrevented:l.returnValue===!1)?sr:Np,this.isPropagationStopped=Np,this}return wt(e.prototype,{preventDefault:function(){this.defaultPrevented=!0;var n=this.nativeEvent;n&&(n.preventDefault?n.preventDefault():typeof n.returnValue!="unknown"&&(n.returnValue=!1),this.isDefaultPrevented=sr)},stopPropagation:function(){var n=this.nativeEvent;n&&(n.stopPropagation?n.stopPropagation():typeof n.cancelBubble!="unknown"&&(n.cancelBubble=!0),this.isPropagationStopped=sr)},persist:function(){},isPersistent:sr}),e}var Qo={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(t){return t.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},pu=pe(Qo),bi=wt({},Qo,{view:0,detail:0}),ew=pe(bi),ls,is,Tl,gu=wt({},bi,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:Lf,button:0,buttons:0,relatedTarget:function(t){return t.relatedTarget===void 0?t.fromElement===t.srcElement?t.toElement:t.fromElement:t.relatedTarget},movementX:function(t){return"movementX"in t?t.movementX:(t!==Tl&&(Tl&&t.type==="mousemove"?(ls=t.screenX-Tl.screenX,is=t.screenY-Tl.screenY):is=ls=0,Tl=t),ls)},movementY:function(t){return"movementY"in t?t.movementY:is}}),Mp=pe(gu),nw=wt({},gu,{dataTransfer:0}),ow=pe(nw),aw=wt({},bi,{relatedTarget:0}),rs=pe(aw),lw=wt({},Qo,{animationName:0,elapsedTime:0,pseudoElement:0}),iw=pe(lw),rw=wt({},Qo,{clipboardData:function(t){return"clipboardData"in t?t.clipboardData:window.clipboardData}}),uw=pe(rw),cw=wt({},Qo,{data:0}),zp=pe(cw),sw={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},fw={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"},dw={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function hw(t){var e=this.nativeEvent;return e.getModifierState?e.getModifierState(t):(t=dw[t])?!!e[t]:!1}function Lf(){return hw}var pw=wt({},bi,{key:function(t){if(t.key){var e=sw[t.key]||t.key;if(e!=="Unidentified")return e}return t.type==="keypress"?(t=Mr(t),t===13?"Enter":String.fromCharCode(t)):t.type==="keydown"||t.type==="keyup"?fw[t.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:Lf,charCode:function(t){return t.type==="keypress"?Mr(t):0},keyCode:function(t){return t.type==="keydown"||t.type==="keyup"?t.keyCode:0},which:function(t){return t.type==="keypress"?Mr(t):t.type==="keydown"||t.type==="keyup"?t.keyCode:0}}),gw=pe(pw),mw=wt({},gu,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),Ap=pe(mw),yw=wt({},bi,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:Lf}),vw=pe(yw),bw=wt({},Qo,{propertyName:0,elapsedTime:0,pseudoElement:0}),xw=pe(bw),Sw=wt({},gu,{deltaX:function(t){return"deltaX"in t?t.deltaX:"wheelDeltaX"in t?-t.wheelDeltaX:0},deltaY:function(t){return"deltaY"in t?t.deltaY:"wheelDeltaY"in t?-t.wheelDeltaY:"wheelDelta"in t?-t.wheelDelta:0},deltaZ:0,deltaMode:0}),_w=pe(Sw),ww=wt({},Qo,{newState:0,oldState:0}),Ew=pe(ww),Nw=[9,13,27,32],Uf=An&&"CompositionEvent"in window,ql=null;An&&"documentMode"in document&&(ql=document.documentMode);var Mw=An&&"TextEvent"in window&&!ql,fm=An&&(!Uf||ql&&8<ql&&11>=ql),Cp=" ",Tp=!1;function dm(t,e){switch(t){case"keyup":return Nw.indexOf(e.keyCode)!==-1;case"keydown":return e.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function hm(t){return t=t.detail,typeof t=="object"&&"data"in t?t.data:null}var Aa=!1;function zw(t,e){switch(t){case"compositionend":return hm(e);case"keypress":return e.which!==32?null:(Tp=!0,Cp);case"textInput":return t=e.data,t===Cp&&Tp?null:t;default:return null}}function Aw(t,e){if(Aa)return t==="compositionend"||!Uf&&dm(t,e)?(t=sm(),Nr=kf=Jn=null,Aa=!1,t):null;switch(t){case"paste":return null;case"keypress":if(!(e.ctrlKey||e.altKey||e.metaKey)||e.ctrlKey&&e.altKey){if(e.char&&1<e.char.length)return e.char;if(e.which)return String.fromCharCode(e.which)}return null;case"compositionend":return fm&&e.locale!=="ko"?null:e.data;default:return null}}var Cw={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 Op(t){var e=t&&t.nodeName&&t.nodeName.toLowerCase();return e==="input"?!!Cw[t.type]:e==="textarea"}function pm(t,e,n,o){za?Ua?Ua.push(o):Ua=[o]:za=o,e=iu(e,"onChange"),0<e.length&&(n=new pu("onChange","change",null,n,o),t.push({event:n,listeners:e}))}var Xl=null,ni=null;function Tw(t){cy(t,0)}function mu(t){var e=Ul(t);if(am(e))return t}function Dp(t,e){if(t==="change")return e}var gm=!1;An&&(An?(dr="oninput"in document,dr||(us=document.createElement("div"),us.setAttribute("oninput","return;"),dr=typeof us.oninput=="function"),fr=dr):fr=!1,gm=fr&&(!document.documentMode||9<document.documentMode));var fr,dr,us;function Hp(){Xl&&(Xl.detachEvent("onpropertychange",mm),ni=Xl=null)}function mm(t){if(t.propertyName==="value"&&mu(ni)){var e=[];pm(e,ni,t,Bf(t)),cm(Tw,e)}}function Ow(t,e,n){t==="focusin"?(Hp(),Xl=e,ni=n,Xl.attachEvent("onpropertychange",mm)):t==="focusout"&&Hp()}function Dw(t){if(t==="selectionchange"||t==="keyup"||t==="keydown")return mu(ni)}function Hw(t,e){if(t==="click")return mu(e)}function Rw(t,e){if(t==="input"||t==="change")return mu(e)}function Bw(t,e){return t===e&&(t!==0||1/t===1/e)||t!==t&&e!==e}var Ee=typeof Object.is=="function"?Object.is:Bw;function oi(t,e){if(Ee(t,e))return!0;if(typeof t!="object"||t===null||typeof e!="object"||e===null)return!1;var n=Object.keys(t),o=Object.keys(e);if(n.length!==o.length)return!1;for(o=0;o<n.length;o++){var a=n[o];if(!Ys.call(e,a)||!Ee(t[a],e[a]))return!1}return!0}function Rp(t){for(;t&&t.firstChild;)t=t.firstChild;return t}function Bp(t,e){var n=Rp(t);t=0;for(var o;n;){if(n.nodeType===3){if(o=t+n.textContent.length,t<=e&&o>=e)return{node:n,offset:e-t};t=o}t:{for(;n;){if(n.nextSibling){n=n.nextSibling;break t}n=n.parentNode}n=void 0}n=Rp(n)}}function ym(t,e){return t&&e?t===e?!0:t&&t.nodeType===3?!1:e&&e.nodeType===3?ym(t,e.parentNode):"contains"in t?t.contains(e):t.compareDocumentPosition?!!(t.compareDocumentPosition(e)&16):!1:!1}function vm(t){t=t!=null&&t.ownerDocument!=null&&t.ownerDocument.defaultView!=null?t.ownerDocument.defaultView:window;for(var e=Xr(t.document);e instanceof t.HTMLIFrameElement;){try{var n=typeof e.contentWindow.location.href=="string"}catch{n=!1}if(n)t=e.contentWindow;else break;e=Xr(t.document)}return e}function Yf(t){var e=t&&t.nodeName&&t.nodeName.toLowerCase();return e&&(e==="input"&&(t.type==="text"||t.type==="search"||t.type==="tel"||t.type==="url"||t.type==="password")||e==="textarea"||t.contentEditable==="true")}var kw=An&&"documentMode"in document&&11>=document.documentMode,Ca=null,js=null,Zl=null,Ks=!1;function kp(t,e,n){var o=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;Ks||Ca==null||Ca!==Xr(o)||(o=Ca,"selectionStart"in o&&Yf(o)?o={start:o.selectionStart,end:o.selectionEnd}:(o=(o.ownerDocument&&o.ownerDocument.defaultView||window).getSelection(),o={anchorNode:o.anchorNode,anchorOffset:o.anchorOffset,focusNode:o.focusNode,focusOffset:o.focusOffset}),Zl&&oi(Zl,o)||(Zl=o,o=iu(js,"onSelect"),0<o.length&&(e=new pu("onSelect","select",null,e,n),t.push({event:e,listeners:o}),e.target=Ca)))}function Co(t,e){var n={};return n[t.toLowerCase()]=e.toLowerCase(),n["Webkit"+t]="webkit"+e,n["Moz"+t]="moz"+e,n}var Ta={animationend:Co("Animation","AnimationEnd"),animationiteration:Co("Animation","AnimationIteration"),animationstart:Co("Animation","AnimationStart"),transitionrun:Co("Transition","TransitionRun"),transitionstart:Co("Transition","TransitionStart"),transitioncancel:Co("Transition","TransitionCancel"),transitionend:Co("Transition","TransitionEnd")},cs={},bm={};An&&(bm=document.createElement("div").style,"AnimationEvent"in window||(delete Ta.animationend.animation,delete Ta.animationiteration.animation,delete Ta.animationstart.animation),"TransitionEvent"in window||delete Ta.transitionend.transition);function jo(t){if(cs[t])return cs[t];if(!Ta[t])return t;var e=Ta[t],n;for(n in e)if(e.hasOwnProperty(n)&&n in bm)return cs[t]=e[n];return t}var xm=jo("animationend"),Sm=jo("animationiteration"),_m=jo("animationstart"),Lw=jo("transitionrun"),Uw=jo("transitionstart"),Yw=jo("transitioncancel"),wm=jo("transitionend"),Em=new Map,$s="abort auxClick beforeToggle 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(" ");$s.push("scrollEnd");function Ge(t,e){Em.set(t,e),Go(e,[t])}var Zr=typeof reportError=="function"?reportError:function(t){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var e=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof t=="object"&&t!==null&&typeof t.message=="string"?String(t.message):String(t),error:t});if(!window.dispatchEvent(e))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",t);return}console.error(t)},Ae=[],Oa=0,Vf=0;function yu(){for(var t=Oa,e=Vf=Oa=0;e<t;){var n=Ae[e];Ae[e++]=null;var o=Ae[e];Ae[e++]=null;var a=Ae[e];Ae[e++]=null;var l=Ae[e];if(Ae[e++]=null,o!==null&&a!==null){var i=o.pending;i===null?a.next=a:(a.next=i.next,i.next=a),o.pending=a}l!==0&&Nm(n,a,l)}}function vu(t,e,n,o){Ae[Oa++]=t,Ae[Oa++]=e,Ae[Oa++]=n,Ae[Oa++]=o,Vf|=o,t.lanes|=o,t=t.alternate,t!==null&&(t.lanes|=o)}function qf(t,e,n,o){return vu(t,e,n,o),Gr(t)}function Ko(t,e){return vu(t,null,null,e),Gr(t)}function Nm(t,e,n){t.lanes|=n;var o=t.alternate;o!==null&&(o.lanes|=n);for(var a=!1,l=t.return;l!==null;)l.childLanes|=n,o=l.alternate,o!==null&&(o.childLanes|=n),l.tag===22&&(t=l.stateNode,t===null||t._visibility&1||(a=!0)),t=l,l=l.return;return t.tag===3?(l=t.stateNode,a&&e!==null&&(a=31-_e(n),t=l.hiddenUpdates,o=t[a],o===null?t[a]=[e]:o.push(e),e.lane=n|536870912),l):null}function Gr(t){if(50<Fl)throw Fl=0,mf=null,Error(L(185));for(var e=t.return;e!==null;)t=e,e=t.return;return t.tag===3?t.stateNode:null}var Da={};function Vw(t,e,n,o){this.tag=t,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=e,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=o,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function ve(t,e,n,o){return new Vw(t,e,n,o)}function Xf(t){return t=t.prototype,!(!t||!t.isReactComponent)}function Nn(t,e){var n=t.alternate;return n===null?(n=ve(t.tag,e,t.key,t.mode),n.elementType=t.elementType,n.type=t.type,n.stateNode=t.stateNode,n.alternate=t,t.alternate=n):(n.pendingProps=e,n.type=t.type,n.flags=0,n.subtreeFlags=0,n.deletions=null),n.flags=t.flags&65011712,n.childLanes=t.childLanes,n.lanes=t.lanes,n.child=t.child,n.memoizedProps=t.memoizedProps,n.memoizedState=t.memoizedState,n.updateQueue=t.updateQueue,e=t.dependencies,n.dependencies=e===null?null:{lanes:e.lanes,firstContext:e.firstContext},n.sibling=t.sibling,n.index=t.index,n.ref=t.ref,n.refCleanup=t.refCleanup,n}function Mm(t,e){t.flags&=65011714;var n=t.alternate;return n===null?(t.childLanes=0,t.lanes=e,t.child=null,t.subtreeFlags=0,t.memoizedProps=null,t.memoizedState=null,t.updateQueue=null,t.dependencies=null,t.stateNode=null):(t.childLanes=n.childLanes,t.lanes=n.lanes,t.child=n.child,t.subtreeFlags=0,t.deletions=null,t.memoizedProps=n.memoizedProps,t.memoizedState=n.memoizedState,t.updateQueue=n.updateQueue,t.type=n.type,e=n.dependencies,t.dependencies=e===null?null:{lanes:e.lanes,firstContext:e.firstContext}),t}function zr(t,e,n,o,a,l){var i=0;if(o=t,typeof t=="function")Xf(t)&&(i=1);else if(typeof t=="string")i=ZE(t,n,nn.current)?26:t==="html"||t==="head"||t==="body"?27:5;else t:switch(t){case Bs:return t=ve(31,n,e,a),t.elementType=Bs,t.lanes=l,t;case Ea:return Bo(n.children,a,l,e);case Qg:i=8,a|=24;break;case Ds:return t=ve(12,n,e,a|2),t.elementType=Ds,t.lanes=l,t;case Hs:return t=ve(13,n,e,a),t.elementType=Hs,t.lanes=l,t;case Rs:return t=ve(19,n,e,a),t.elementType=Rs,t.lanes=l,t;default:if(typeof t=="object"&&t!==null)switch(t.$$typeof){case _n:i=10;break t;case jg:i=9;break t;case Af:i=11;break t;case Cf:i=14;break t;case Xn:i=16,o=null;break t}i=29,n=Error(L(130,t===null?"null":typeof t,"")),o=null}return e=ve(i,n,e,a),e.elementType=t,e.type=o,e.lanes=l,e}function Bo(t,e,n,o){return t=ve(7,t,o,e),t.lanes=n,t}function ss(t,e,n){return t=ve(6,t,null,e),t.lanes=n,t}function zm(t){var e=ve(18,null,null,0);return e.stateNode=t,e}function fs(t,e,n){return e=ve(4,t.children!==null?t.children:[],t.key,e),e.lanes=n,e.stateNode={containerInfo:t.containerInfo,pendingChildren:null,implementation:t.implementation},e}var Lp=new WeakMap;function He(t,e){if(typeof t=="object"&&t!==null){var n=Lp.get(t);return n!==void 0?n:(e={value:t,source:e,stack:vp(e)},Lp.set(t,e),e)}return{value:t,source:e,stack:vp(e)}}var Ha=[],Ra=0,Qr=null,ai=0,Te=[],Oe=0,uo=null,Pe=1,tn="";function xn(t,e){Ha[Ra++]=ai,Ha[Ra++]=Qr,Qr=t,ai=e}function Am(t,e,n){Te[Oe++]=Pe,Te[Oe++]=tn,Te[Oe++]=uo,uo=t;var o=Pe;t=tn;var a=32-_e(o)-1;o&=~(1<<a),n+=1;var l=32-_e(e)+a;if(30<l){var i=a-a%5;l=(o&(1<<i)-1).toString(32),o>>=i,a-=i,Pe=1<<32-_e(e)+a|n<<a|o,tn=l+t}else Pe=1<<l|n<<a|o,tn=t}function Zf(t){t.return!==null&&(xn(t,1),Am(t,1,0))}function Gf(t){for(;t===Qr;)Qr=Ha[--Ra],Ha[Ra]=null,ai=Ha[--Ra],Ha[Ra]=null;for(;t===uo;)uo=Te[--Oe],Te[Oe]=null,tn=Te[--Oe],Te[Oe]=null,Pe=Te[--Oe],Te[Oe]=null}function Cm(t,e){Te[Oe++]=Pe,Te[Oe++]=tn,Te[Oe++]=uo,Pe=e.id,tn=e.overflow,uo=t}var $t=null,_t=null,rt=!1,to=null,Re=!1,Js=Error(L(519));function co(t){var e=Error(L(418,1<arguments.length&&arguments[1]!==void 0&&arguments[1]?"text":"HTML",""));throw li(He(e,t)),Js}function Up(t){var e=t.stateNode,n=t.type,o=t.memoizedProps;switch(e[Kt]=t,e[he]=o,n){case"dialog":at("cancel",e),at("close",e);break;case"iframe":case"object":case"embed":at("load",e);break;case"video":case"audio":for(n=0;n<ci.length;n++)at(ci[n],e);break;case"source":at("error",e);break;case"img":case"image":case"link":at("error",e),at("load",e);break;case"details":at("toggle",e);break;case"input":at("invalid",e),lm(e,o.value,o.defaultValue,o.checked,o.defaultChecked,o.type,o.name,!0);break;case"select":at("invalid",e);break;case"textarea":at("invalid",e),rm(e,o.value,o.defaultValue,o.children)}n=o.children,typeof n!="string"&&typeof n!="number"&&typeof n!="bigint"||e.textContent===""+n||o.suppressHydrationWarning===!0||fy(e.textContent,n)?(o.popover!=null&&(at("beforetoggle",e),at("toggle",e)),o.onScroll!=null&&at("scroll",e),o.onScrollEnd!=null&&at("scrollend",e),o.onClick!=null&&(e.onclick=wn),e=!0):e=!1,e||co(t,!0)}function Yp(t){for($t=t.return;$t;)switch($t.tag){case 5:case 31:case 13:Re=!1;return;case 27:case 3:Re=!0;return;default:$t=$t.return}}function xa(t){if(t!==$t)return!1;if(!rt)return Yp(t),rt=!0,!1;var e=t.tag,n;if((n=e!==3&&e!==27)&&((n=e===5)&&(n=t.type,n=!(n!=="form"&&n!=="button")||Sf(t.type,t.memoizedProps)),n=!n),n&&_t&&co(t),Yp(t),e===13){if(t=t.memoizedState,t=t!==null?t.dehydrated:null,!t)throw Error(L(317));_t=zg(t)}else if(e===31){if(t=t.memoizedState,t=t!==null?t.dehydrated:null,!t)throw Error(L(317));_t=zg(t)}else e===27?(e=_t,po(t.type)?(t=Nf,Nf=null,_t=t):_t=e):_t=$t?ke(t.stateNode.nextSibling):null;return!0}function Yo(){_t=$t=null,rt=!1}function ds(){var t=to;return t!==null&&(fe===null?fe=t:fe.push.apply(fe,t),to=null),t}function li(t){to===null?to=[t]:to.push(t)}var Is=on(null),$o=null,En=null;function Gn(t,e,n){bt(Is,e._currentValue),e._currentValue=n}function Mn(t){t._currentValue=Is.current,Gt(Is)}function Ws(t,e,n){for(;t!==null;){var o=t.alternate;if((t.childLanes&e)!==e?(t.childLanes|=e,o!==null&&(o.childLanes|=e)):o!==null&&(o.childLanes&e)!==e&&(o.childLanes|=e),t===n)break;t=t.return}}function Fs(t,e,n,o){var a=t.child;for(a!==null&&(a.return=t);a!==null;){var l=a.dependencies;if(l!==null){var i=a.child;l=l.firstContext;t:for(;l!==null;){var r=l;l=a;for(var u=0;u<e.length;u++)if(r.context===e[u]){l.lanes|=n,r=l.alternate,r!==null&&(r.lanes|=n),Ws(l.return,n,t),o||(i=null);break t}l=r.next}}else if(a.tag===18){if(i=a.return,i===null)throw Error(L(341));i.lanes|=n,l=i.alternate,l!==null&&(l.lanes|=n),Ws(i,n,t),i=null}else i=a.child;if(i!==null)i.return=a;else for(i=a;i!==null;){if(i===t){i=null;break}if(a=i.sibling,a!==null){a.return=i.return,i=a;break}i=i.return}a=i}}function nl(t,e,n,o){t=null;for(var a=e,l=!1;a!==null;){if(!l){if((a.flags&524288)!==0)l=!0;else if((a.flags&262144)!==0)break}if(a.tag===10){var i=a.alternate;if(i===null)throw Error(L(387));if(i=i.memoizedProps,i!==null){var r=a.type;Ee(a.pendingProps.value,i.value)||(t!==null?t.push(r):t=[r])}}else if(a===Ur.current){if(i=a.alternate,i===null)throw Error(L(387));i.memoizedState.memoizedState!==a.memoizedState.memoizedState&&(t!==null?t.push(fi):t=[fi])}a=a.return}t!==null&&Fs(e,t,n,o),e.flags|=262144}function jr(t){for(t=t.firstContext;t!==null;){if(!Ee(t.context._currentValue,t.memoizedValue))return!0;t=t.next}return!1}function Vo(t){$o=t,En=null,t=t.dependencies,t!==null&&(t.firstContext=null)}function Jt(t){return Tm($o,t)}function hr(t,e){return $o===null&&Vo(t),Tm(t,e)}function Tm(t,e){var n=e._currentValue;if(e={context:e,memoizedValue:n,next:null},En===null){if(t===null)throw Error(L(308));En=e,t.dependencies={lanes:0,firstContext:e},t.flags|=524288}else En=En.next=e;return n}var qw=typeof AbortController<"u"?AbortController:function(){var t=[],e=this.signal={aborted:!1,addEventListener:function(n,o){t.push(o)}};this.abort=function(){e.aborted=!0,t.forEach(function(n){return n()})}},Xw=Vt.unstable_scheduleCallback,Zw=Vt.unstable_NormalPriority,Lt={$$typeof:_n,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function Qf(){return{controller:new qw,data:new Map,refCount:0}}function xi(t){t.refCount--,t.refCount===0&&Xw(Zw,function(){t.controller.abort()})}var Gl=null,Ps=0,ja=0,Ya=null;function Gw(t,e){if(Gl===null){var n=Gl=[];Ps=0,ja=md(),Ya={status:"pending",value:void 0,then:function(o){n.push(o)}}}return Ps++,e.then(Vp,Vp),e}function Vp(){if(--Ps===0&&Gl!==null){Ya!==null&&(Ya.status="fulfilled");var t=Gl;Gl=null,ja=0,Ya=null;for(var e=0;e<t.length;e++)(0,t[e])()}}function Qw(t,e){var n=[],o={status:"pending",value:null,reason:null,then:function(a){n.push(a)}};return t.then(function(){o.status="fulfilled",o.value=e;for(var a=0;a<n.length;a++)(0,n[a])(e)},function(a){for(o.status="rejected",o.reason=a,a=0;a<n.length;a++)(0,n[a])(void 0)}),o}var qp=F.S;F.S=function(t,e){G0=xe(),typeof e=="object"&&e!==null&&typeof e.then=="function"&&Gw(t,e),qp!==null&&qp(t,e)};var ko=on(null);function jf(){var t=ko.current;return t!==null?t:vt.pooledCache}function Ar(t,e){e===null?bt(ko,ko.current):bt(ko,e.pool)}function Om(){var t=jf();return t===null?null:{parent:Lt._currentValue,pool:t}}var ol=Error(L(460)),Kf=Error(L(474)),bu=Error(L(542)),Kr={then:function(){}};function Xp(t){return t=t.status,t==="fulfilled"||t==="rejected"}function Dm(t,e,n){switch(n=t[n],n===void 0?t.push(e):n!==e&&(e.then(wn,wn),e=n),e.status){case"fulfilled":return e.value;case"rejected":throw t=e.reason,Gp(t),t;default:if(typeof e.status=="string")e.then(wn,wn);else{if(t=vt,t!==null&&100<t.shellSuspendCounter)throw Error(L(482));t=e,t.status="pending",t.then(function(o){if(e.status==="pending"){var a=e;a.status="fulfilled",a.value=o}},function(o){if(e.status==="pending"){var a=e;a.status="rejected",a.reason=o}})}switch(e.status){case"fulfilled":return e.value;case"rejected":throw t=e.reason,Gp(t),t}throw Lo=e,ol}}function Do(t){try{var e=t._init;return e(t._payload)}catch(n){throw n!==null&&typeof n=="object"&&typeof n.then=="function"?(Lo=n,ol):n}}var Lo=null;function Zp(){if(Lo===null)throw Error(L(459));var t=Lo;return Lo=null,t}function Gp(t){if(t===ol||t===bu)throw Error(L(483))}var Va=null,ii=0;function pr(t){var e=ii;return ii+=1,Va===null&&(Va=[]),Dm(Va,t,e)}function Ol(t,e){e=e.props.ref,t.ref=e!==void 0?e:null}function gr(t,e){throw e.$$typeof===O_?Error(L(525)):(t=Object.prototype.toString.call(e),Error(L(31,t==="[object Object]"?"object with keys {"+Object.keys(e).join(", ")+"}":t)))}function Hm(t){function e(g,m){if(t){var h=g.deletions;h===null?(g.deletions=[m],g.flags|=16):h.push(m)}}function n(g,m){if(!t)return null;for(;m!==null;)e(g,m),m=m.sibling;return null}function o(g){for(var m=new Map;g!==null;)g.key!==null?m.set(g.key,g):m.set(g.index,g),g=g.sibling;return m}function a(g,m){return g=Nn(g,m),g.index=0,g.sibling=null,g}function l(g,m,h){return g.index=h,t?(h=g.alternate,h!==null?(h=h.index,h<m?(g.flags|=67108866,m):h):(g.flags|=67108866,m)):(g.flags|=1048576,m)}function i(g){return t&&g.alternate===null&&(g.flags|=67108866),g}function r(g,m,h,v){return m===null||m.tag!==6?(m=ss(h,g.mode,v),m.return=g,m):(m=a(m,h),m.return=g,m)}function u(g,m,h,v){var _=h.type;return _===Ea?c(g,m,h.props.children,v,h.key):m!==null&&(m.elementType===_||typeof _=="object"&&_!==null&&_.$$typeof===Xn&&Do(_)===m.type)?(m=a(m,h.props),Ol(m,h),m.return=g,m):(m=zr(h.type,h.key,h.props,null,g.mode,v),Ol(m,h),m.return=g,m)}function s(g,m,h,v){return m===null||m.tag!==4||m.stateNode.containerInfo!==h.containerInfo||m.stateNode.implementation!==h.implementation?(m=fs(h,g.mode,v),m.return=g,m):(m=a(m,h.children||[]),m.return=g,m)}function c(g,m,h,v,_){return m===null||m.tag!==7?(m=Bo(h,g.mode,v,_),m.return=g,m):(m=a(m,h),m.return=g,m)}function d(g,m,h){if(typeof m=="string"&&m!==""||typeof m=="number"||typeof m=="bigint")return m=ss(""+m,g.mode,h),m.return=g,m;if(typeof m=="object"&&m!==null){switch(m.$$typeof){case lr:return h=zr(m.type,m.key,m.props,null,g.mode,h),Ol(h,m),h.return=g,h;case kl:return m=fs(m,g.mode,h),m.return=g,m;case Xn:return m=Do(m),d(g,m,h)}if(Ll(m)||Cl(m))return m=Bo(m,g.mode,h,null),m.return=g,m;if(typeof m.then=="function")return d(g,pr(m),h);if(m.$$typeof===_n)return d(g,hr(g,m),h);gr(g,m)}return null}function f(g,m,h,v){var _=m!==null?m.key:null;if(typeof h=="string"&&h!==""||typeof h=="number"||typeof h=="bigint")return _!==null?null:r(g,m,""+h,v);if(typeof h=="object"&&h!==null){switch(h.$$typeof){case lr:return h.key===_?u(g,m,h,v):null;case kl:return h.key===_?s(g,m,h,v):null;case Xn:return h=Do(h),f(g,m,h,v)}if(Ll(h)||Cl(h))return _!==null?null:c(g,m,h,v,null);if(typeof h.then=="function")return f(g,m,pr(h),v);if(h.$$typeof===_n)return f(g,m,hr(g,h),v);gr(g,h)}return null}function p(g,m,h,v,_){if(typeof v=="string"&&v!==""||typeof v=="number"||typeof v=="bigint")return g=g.get(h)||null,r(m,g,""+v,_);if(typeof v=="object"&&v!==null){switch(v.$$typeof){case lr:return g=g.get(v.key===null?h:v.key)||null,u(m,g,v,_);case kl:return g=g.get(v.key===null?h:v.key)||null,s(m,g,v,_);case Xn:return v=Do(v),p(g,m,h,v,_)}if(Ll(v)||Cl(v))return g=g.get(h)||null,c(m,g,v,_,null);if(typeof v.then=="function")return p(g,m,h,pr(v),_);if(v.$$typeof===_n)return p(g,m,h,hr(m,v),_);gr(m,v)}return null}function y(g,m,h,v){for(var _=null,E=null,w=m,N=m=0,M=null;w!==null&&N<h.length;N++){w.index>N?(M=w,w=null):M=w.sibling;var R=f(g,w,h[N],v);if(R===null){w===null&&(w=M);break}t&&w&&R.alternate===null&&e(g,w),m=l(R,m,N),E===null?_=R:E.sibling=R,E=R,w=M}if(N===h.length)return n(g,w),rt&&xn(g,N),_;if(w===null){for(;N<h.length;N++)w=d(g,h[N],v),w!==null&&(m=l(w,m,N),E===null?_=w:E.sibling=w,E=w);return rt&&xn(g,N),_}for(w=o(w);N<h.length;N++)M=p(w,g,N,h[N],v),M!==null&&(t&&M.alternate!==null&&w.delete(M.key===null?N:M.key),m=l(M,m,N),E===null?_=M:E.sibling=M,E=M);return t&&w.forEach(function(C){return e(g,C)}),rt&&xn(g,N),_}function b(g,m,h,v){if(h==null)throw Error(L(151));for(var _=null,E=null,w=m,N=m=0,M=null,R=h.next();w!==null&&!R.done;N++,R=h.next()){w.index>N?(M=w,w=null):M=w.sibling;var C=f(g,w,R.value,v);if(C===null){w===null&&(w=M);break}t&&w&&C.alternate===null&&e(g,w),m=l(C,m,N),E===null?_=C:E.sibling=C,E=C,w=M}if(R.done)return n(g,w),rt&&xn(g,N),_;if(w===null){for(;!R.done;N++,R=h.next())R=d(g,R.value,v),R!==null&&(m=l(R,m,N),E===null?_=R:E.sibling=R,E=R);return rt&&xn(g,N),_}for(w=o(w);!R.done;N++,R=h.next())R=p(w,g,N,R.value,v),R!==null&&(t&&R.alternate!==null&&w.delete(R.key===null?N:R.key),m=l(R,m,N),E===null?_=R:E.sibling=R,E=R);return t&&w.forEach(function(k){return e(g,k)}),rt&&xn(g,N),_}function x(g,m,h,v){if(typeof h=="object"&&h!==null&&h.type===Ea&&h.key===null&&(h=h.props.children),typeof h=="object"&&h!==null){switch(h.$$typeof){case lr:t:{for(var _=h.key;m!==null;){if(m.key===_){if(_=h.type,_===Ea){if(m.tag===7){n(g,m.sibling),v=a(m,h.props.children),v.return=g,g=v;break t}}else if(m.elementType===_||typeof _=="object"&&_!==null&&_.$$typeof===Xn&&Do(_)===m.type){n(g,m.sibling),v=a(m,h.props),Ol(v,h),v.return=g,g=v;break t}n(g,m);break}else e(g,m);m=m.sibling}h.type===Ea?(v=Bo(h.props.children,g.mode,v,h.key),v.return=g,g=v):(v=zr(h.type,h.key,h.props,null,g.mode,v),Ol(v,h),v.return=g,g=v)}return i(g);case kl:t:{for(_=h.key;m!==null;){if(m.key===_)if(m.tag===4&&m.stateNode.containerInfo===h.containerInfo&&m.stateNode.implementation===h.implementation){n(g,m.sibling),v=a(m,h.children||[]),v.return=g,g=v;break t}else{n(g,m);break}else e(g,m);m=m.sibling}v=fs(h,g.mode,v),v.return=g,g=v}return i(g);case Xn:return h=Do(h),x(g,m,h,v)}if(Ll(h))return y(g,m,h,v);if(Cl(h)){if(_=Cl(h),typeof _!="function")throw Error(L(150));return h=_.call(h),b(g,m,h,v)}if(typeof h.then=="function")return x(g,m,pr(h),v);if(h.$$typeof===_n)return x(g,m,hr(g,h),v);gr(g,h)}return typeof h=="string"&&h!==""||typeof h=="number"||typeof h=="bigint"?(h=""+h,m!==null&&m.tag===6?(n(g,m.sibling),v=a(m,h),v.return=g,g=v):(n(g,m),v=ss(h,g.mode,v),v.return=g,g=v),i(g)):n(g,m)}return function(g,m,h,v){try{ii=0;var _=x(g,m,h,v);return Va=null,_}catch(w){if(w===ol||w===bu)throw w;var E=ve(29,w,null,g.mode);return E.lanes=v,E.return=g,E}}}var qo=Hm(!0),Rm=Hm(!1),Zn=!1;function $f(t){t.updateQueue={baseState:t.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function tf(t,e){t=t.updateQueue,e.updateQueue===t&&(e.updateQueue={baseState:t.baseState,firstBaseUpdate:t.firstBaseUpdate,lastBaseUpdate:t.lastBaseUpdate,shared:t.shared,callbacks:null})}function eo(t){return{lane:t,tag:0,payload:null,callback:null,next:null}}function no(t,e,n){var o=t.updateQueue;if(o===null)return null;if(o=o.shared,(st&2)!==0){var a=o.pending;return a===null?e.next=e:(e.next=a.next,a.next=e),o.pending=e,e=Gr(t),Nm(t,null,n),e}return vu(t,o,e,n),Gr(t)}function Ql(t,e,n){if(e=e.updateQueue,e!==null&&(e=e.shared,(n&4194048)!==0)){var o=e.lanes;o&=t.pendingLanes,n|=o,e.lanes=n,Fg(t,n)}}function hs(t,e){var n=t.updateQueue,o=t.alternate;if(o!==null&&(o=o.updateQueue,n===o)){var a=null,l=null;if(n=n.firstBaseUpdate,n!==null){do{var i={lane:n.lane,tag:n.tag,payload:n.payload,callback:null,next:null};l===null?a=l=i:l=l.next=i,n=n.next}while(n!==null);l===null?a=l=e:l=l.next=e}else a=l=e;n={baseState:o.baseState,firstBaseUpdate:a,lastBaseUpdate:l,shared:o.shared,callbacks:o.callbacks},t.updateQueue=n;return}t=n.lastBaseUpdate,t===null?n.firstBaseUpdate=e:t.next=e,n.lastBaseUpdate=e}var ef=!1;function jl(){if(ef){var t=Ya;if(t!==null)throw t}}function Kl(t,e,n,o){ef=!1;var a=t.updateQueue;Zn=!1;var l=a.firstBaseUpdate,i=a.lastBaseUpdate,r=a.shared.pending;if(r!==null){a.shared.pending=null;var u=r,s=u.next;u.next=null,i===null?l=s:i.next=s,i=u;var c=t.alternate;c!==null&&(c=c.updateQueue,r=c.lastBaseUpdate,r!==i&&(r===null?c.firstBaseUpdate=s:r.next=s,c.lastBaseUpdate=u))}if(l!==null){var d=a.baseState;i=0,c=s=u=null,r=l;do{var f=r.lane&-536870913,p=f!==r.lane;if(p?(it&f)===f:(o&f)===f){f!==0&&f===ja&&(ef=!0),c!==null&&(c=c.next={lane:0,tag:r.tag,payload:r.payload,callback:null,next:null});t:{var y=t,b=r;f=e;var x=n;switch(b.tag){case 1:if(y=b.payload,typeof y=="function"){d=y.call(x,d,f);break t}d=y;break t;case 3:y.flags=y.flags&-65537|128;case 0:if(y=b.payload,f=typeof y=="function"?y.call(x,d,f):y,f==null)break t;d=wt({},d,f);break t;case 2:Zn=!0}}f=r.callback,f!==null&&(t.flags|=64,p&&(t.flags|=8192),p=a.callbacks,p===null?a.callbacks=[f]:p.push(f))}else p={lane:f,tag:r.tag,payload:r.payload,callback:r.callback,next:null},c===null?(s=c=p,u=d):c=c.next=p,i|=f;if(r=r.next,r===null){if(r=a.shared.pending,r===null)break;p=r,r=p.next,p.next=null,a.lastBaseUpdate=p,a.shared.pending=null}}while(!0);c===null&&(u=d),a.baseState=u,a.firstBaseUpdate=s,a.lastBaseUpdate=c,l===null&&(a.shared.lanes=0),fo|=i,t.lanes=i,t.memoizedState=d}}function Bm(t,e){if(typeof t!="function")throw Error(L(191,t));t.call(e)}function km(t,e){var n=t.callbacks;if(n!==null)for(t.callbacks=null,t=0;t<n.length;t++)Bm(n[t],e)}var Ka=on(null),$r=on(0);function Qp(t,e){t=Dn,bt($r,t),bt(Ka,e),Dn=t|e.baseLanes}function nf(){bt($r,Dn),bt(Ka,Ka.current)}function Jf(){Dn=$r.current,Gt(Ka),Gt($r)}var Ne=on(null),Be=null;function Qn(t){var e=t.alternate;bt(Ht,Ht.current&1),bt(Ne,t),Be===null&&(e===null||Ka.current!==null||e.memoizedState!==null)&&(Be=t)}function of(t){bt(Ht,Ht.current),bt(Ne,t),Be===null&&(Be=t)}function Lm(t){t.tag===22?(bt(Ht,Ht.current),bt(Ne,t),Be===null&&(Be=t)):jn(t)}function jn(){bt(Ht,Ht.current),bt(Ne,Ne.current)}function ye(t){Gt(Ne),Be===t&&(Be=null),Gt(Ht)}var Ht=on(0);function Jr(t){for(var e=t;e!==null;){if(e.tag===13){var n=e.memoizedState;if(n!==null&&(n=n.dehydrated,n===null||wf(n)||Ef(n)))return e}else if(e.tag===19&&(e.memoizedProps.revealOrder==="forwards"||e.memoizedProps.revealOrder==="backwards"||e.memoizedProps.revealOrder==="unstable_legacy-backwards"||e.memoizedProps.revealOrder==="together")){if((e.flags&128)!==0)return e}else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break;for(;e.sibling===null;){if(e.return===null||e.return===t)return null;e=e.return}e.sibling.return=e.return,e=e.sibling}return null}var Cn=0,et=null,yt=null,Bt=null,Ir=!1,qa=!1,Xo=!1,Wr=0,ri=0,Xa=null,jw=0;function At(){throw Error(L(321))}function If(t,e){if(e===null)return!1;for(var n=0;n<e.length&&n<t.length;n++)if(!Ee(t[n],e[n]))return!1;return!0}function Wf(t,e,n,o,a,l){return Cn=l,et=e,e.memoizedState=null,e.updateQueue=null,e.lanes=0,F.H=t===null||t.memoizedState===null?p0:ud,Xo=!1,l=n(o,a),Xo=!1,qa&&(l=Ym(e,n,o,a)),Um(t),l}function Um(t){F.H=ui;var e=yt!==null&&yt.next!==null;if(Cn=0,Bt=yt=et=null,Ir=!1,ri=0,Xa=null,e)throw Error(L(300));t===null||Ut||(t=t.dependencies,t!==null&&jr(t)&&(Ut=!0))}function Ym(t,e,n,o){et=t;var a=0;do{if(qa&&(Xa=null),ri=0,qa=!1,25<=a)throw Error(L(301));if(a+=1,Bt=yt=null,t.updateQueue!=null){var l=t.updateQueue;l.lastEffect=null,l.events=null,l.stores=null,l.memoCache!=null&&(l.memoCache.index=0)}F.H=g0,l=e(n,o)}while(qa);return l}function Kw(){var t=F.H,e=t.useState()[0];return e=typeof e.then=="function"?Si(e):e,t=t.useState()[0],(yt!==null?yt.memoizedState:null)!==t&&(et.flags|=1024),e}function Ff(){var t=Wr!==0;return Wr=0,t}function Pf(t,e,n){e.updateQueue=t.updateQueue,e.flags&=-2053,t.lanes&=~n}function td(t){if(Ir){for(t=t.memoizedState;t!==null;){var e=t.queue;e!==null&&(e.pending=null),t=t.next}Ir=!1}Cn=0,Bt=yt=et=null,qa=!1,ri=Wr=0,Xa=null}function ne(){var t={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return Bt===null?et.memoizedState=Bt=t:Bt=Bt.next=t,Bt}function Rt(){if(yt===null){var t=et.alternate;t=t!==null?t.memoizedState:null}else t=yt.next;var e=Bt===null?et.memoizedState:Bt.next;if(e!==null)Bt=e,yt=t;else{if(t===null)throw et.alternate===null?Error(L(467)):Error(L(310));yt=t,t={memoizedState:yt.memoizedState,baseState:yt.baseState,baseQueue:yt.baseQueue,queue:yt.queue,next:null},Bt===null?et.memoizedState=Bt=t:Bt=Bt.next=t}return Bt}function xu(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function Si(t){var e=ri;return ri+=1,Xa===null&&(Xa=[]),t=Dm(Xa,t,e),e=et,(Bt===null?e.memoizedState:Bt.next)===null&&(e=e.alternate,F.H=e===null||e.memoizedState===null?p0:ud),t}function Su(t){if(t!==null&&typeof t=="object"){if(typeof t.then=="function")return Si(t);if(t.$$typeof===_n)return Jt(t)}throw Error(L(438,String(t)))}function ed(t){var e=null,n=et.updateQueue;if(n!==null&&(e=n.memoCache),e==null){var o=et.alternate;o!==null&&(o=o.updateQueue,o!==null&&(o=o.memoCache,o!=null&&(e={data:o.data.map(function(a){return a.slice()}),index:0})))}if(e==null&&(e={data:[],index:0}),n===null&&(n=xu(),et.updateQueue=n),n.memoCache=e,n=e.data[e.index],n===void 0)for(n=e.data[e.index]=Array(t),o=0;o<t;o++)n[o]=D_;return e.index++,n}function Tn(t,e){return typeof e=="function"?e(t):e}function Cr(t){var e=Rt();return nd(e,yt,t)}function nd(t,e,n){var o=t.queue;if(o===null)throw Error(L(311));o.lastRenderedReducer=n;var a=t.baseQueue,l=o.pending;if(l!==null){if(a!==null){var i=a.next;a.next=l.next,l.next=i}e.baseQueue=a=l,o.pending=null}if(l=t.baseState,a===null)t.memoizedState=l;else{e=a.next;var r=i=null,u=null,s=e,c=!1;do{var d=s.lane&-536870913;if(d!==s.lane?(it&d)===d:(Cn&d)===d){var f=s.revertLane;if(f===0)u!==null&&(u=u.next={lane:0,revertLane:0,gesture:null,action:s.action,hasEagerState:s.hasEagerState,eagerState:s.eagerState,next:null}),d===ja&&(c=!0);else if((Cn&f)===f){s=s.next,f===ja&&(c=!0);continue}else d={lane:0,revertLane:s.revertLane,gesture:null,action:s.action,hasEagerState:s.hasEagerState,eagerState:s.eagerState,next:null},u===null?(r=u=d,i=l):u=u.next=d,et.lanes|=f,fo|=f;d=s.action,Xo&&n(l,d),l=s.hasEagerState?s.eagerState:n(l,d)}else f={lane:d,revertLane:s.revertLane,gesture:s.gesture,action:s.action,hasEagerState:s.hasEagerState,eagerState:s.eagerState,next:null},u===null?(r=u=f,i=l):u=u.next=f,et.lanes|=d,fo|=d;s=s.next}while(s!==null&&s!==e);if(u===null?i=l:u.next=r,!Ee(l,t.memoizedState)&&(Ut=!0,c&&(n=Ya,n!==null)))throw n;t.memoizedState=l,t.baseState=i,t.baseQueue=u,o.lastRenderedState=l}return a===null&&(o.lanes=0),[t.memoizedState,o.dispatch]}function ps(t){var e=Rt(),n=e.queue;if(n===null)throw Error(L(311));n.lastRenderedReducer=t;var o=n.dispatch,a=n.pending,l=e.memoizedState;if(a!==null){n.pending=null;var i=a=a.next;do l=t(l,i.action),i=i.next;while(i!==a);Ee(l,e.memoizedState)||(Ut=!0),e.memoizedState=l,e.baseQueue===null&&(e.baseState=l),n.lastRenderedState=l}return[l,o]}function Vm(t,e,n){var o=et,a=Rt(),l=rt;if(l){if(n===void 0)throw Error(L(407));n=n()}else n=e();var i=!Ee((yt||a).memoizedState,n);if(i&&(a.memoizedState=n,Ut=!0),a=a.queue,od(Zm.bind(null,o,a,t),[t]),a.getSnapshot!==e||i||Bt!==null&&Bt.memoizedState.tag&1){if(o.flags|=2048,$a(9,{destroy:void 0},Xm.bind(null,o,a,n,e),null),vt===null)throw Error(L(349));l||(Cn&127)!==0||qm(o,e,n)}return n}function qm(t,e,n){t.flags|=16384,t={getSnapshot:e,value:n},e=et.updateQueue,e===null?(e=xu(),et.updateQueue=e,e.stores=[t]):(n=e.stores,n===null?e.stores=[t]:n.push(t))}function Xm(t,e,n,o){e.value=n,e.getSnapshot=o,Gm(e)&&Qm(t)}function Zm(t,e,n){return n(function(){Gm(e)&&Qm(t)})}function Gm(t){var e=t.getSnapshot;t=t.value;try{var n=e();return!Ee(t,n)}catch{return!0}}function Qm(t){var e=Ko(t,2);e!==null&&de(e,t,2)}function af(t){var e=ne();if(typeof t=="function"){var n=t;if(t=n(),Xo){$n(!0);try{n()}finally{$n(!1)}}}return e.memoizedState=e.baseState=t,e.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Tn,lastRenderedState:t},e}function jm(t,e,n,o){return t.baseState=n,nd(t,yt,typeof o=="function"?o:Tn)}function $w(t,e,n,o,a){if(wu(t))throw Error(L(485));if(t=e.action,t!==null){var l={payload:a,action:t,next:null,isTransition:!0,status:"pending",value:null,reason:null,listeners:[],then:function(i){l.listeners.push(i)}};F.T!==null?n(!0):l.isTransition=!1,o(l),n=e.pending,n===null?(l.next=e.pending=l,Km(e,l)):(l.next=n.next,e.pending=n.next=l)}}function Km(t,e){var n=e.action,o=e.payload,a=t.state;if(e.isTransition){var l=F.T,i={};F.T=i;try{var r=n(a,o),u=F.S;u!==null&&u(i,r),jp(t,e,r)}catch(s){lf(t,e,s)}finally{l!==null&&i.types!==null&&(l.types=i.types),F.T=l}}else try{l=n(a,o),jp(t,e,l)}catch(s){lf(t,e,s)}}function jp(t,e,n){n!==null&&typeof n=="object"&&typeof n.then=="function"?n.then(function(o){Kp(t,e,o)},function(o){return lf(t,e,o)}):Kp(t,e,n)}function Kp(t,e,n){e.status="fulfilled",e.value=n,$m(e),t.state=n,e=t.pending,e!==null&&(n=e.next,n===e?t.pending=null:(n=n.next,e.next=n,Km(t,n)))}function lf(t,e,n){var o=t.pending;if(t.pending=null,o!==null){o=o.next;do e.status="rejected",e.reason=n,$m(e),e=e.next;while(e!==o)}t.action=null}function $m(t){t=t.listeners;for(var e=0;e<t.length;e++)(0,t[e])()}function Jm(t,e){return e}function $p(t,e){if(rt){var n=vt.formState;if(n!==null){t:{var o=et;if(rt){if(_t){e:{for(var a=_t,l=Re;a.nodeType!==8;){if(!l){a=null;break e}if(a=ke(a.nextSibling),a===null){a=null;break e}}l=a.data,a=l==="F!"||l==="F"?a:null}if(a){_t=ke(a.nextSibling),o=a.data==="F!";break t}}co(o)}o=!1}o&&(e=n[0])}}return n=ne(),n.memoizedState=n.baseState=e,o={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Jm,lastRenderedState:e},n.queue=o,n=f0.bind(null,et,o),o.dispatch=n,o=af(!1),l=rd.bind(null,et,!1,o.queue),o=ne(),a={state:e,dispatch:null,action:t,pending:null},o.queue=a,n=$w.bind(null,et,a,l,n),a.dispatch=n,o.memoizedState=t,[e,n,!1]}function Jp(t){var e=Rt();return Im(e,yt,t)}function Im(t,e,n){if(e=nd(t,e,Jm)[0],t=Cr(Tn)[0],typeof e=="object"&&e!==null&&typeof e.then=="function")try{var o=Si(e)}catch(i){throw i===ol?bu:i}else o=e;e=Rt();var a=e.queue,l=a.dispatch;return n!==e.memoizedState&&(et.flags|=2048,$a(9,{destroy:void 0},Jw.bind(null,a,n),null)),[o,l,t]}function Jw(t,e){t.action=e}function Ip(t){var e=Rt(),n=yt;if(n!==null)return Im(e,n,t);Rt(),e=e.memoizedState,n=Rt();var o=n.queue.dispatch;return n.memoizedState=t,[e,o,!1]}function $a(t,e,n,o){return t={tag:t,create:n,deps:o,inst:e,next:null},e=et.updateQueue,e===null&&(e=xu(),et.updateQueue=e),n=e.lastEffect,n===null?e.lastEffect=t.next=t:(o=n.next,n.next=t,t.next=o,e.lastEffect=t),t}function Wm(){return Rt().memoizedState}function Tr(t,e,n,o){var a=ne();et.flags|=t,a.memoizedState=$a(1|e,{destroy:void 0},n,o===void 0?null:o)}function _u(t,e,n,o){var a=Rt();o=o===void 0?null:o;var l=a.memoizedState.inst;yt!==null&&o!==null&&If(o,yt.memoizedState.deps)?a.memoizedState=$a(e,l,n,o):(et.flags|=t,a.memoizedState=$a(1|e,l,n,o))}function Wp(t,e){Tr(8390656,8,t,e)}function od(t,e){_u(2048,8,t,e)}function Iw(t){et.flags|=4;var e=et.updateQueue;if(e===null)e=xu(),et.updateQueue=e,e.events=[t];else{var n=e.events;n===null?e.events=[t]:n.push(t)}}function Fm(t){var e=Rt().memoizedState;return Iw({ref:e,nextImpl:t}),function(){if((st&2)!==0)throw Error(L(440));return e.impl.apply(void 0,arguments)}}function Pm(t,e){return _u(4,2,t,e)}function t0(t,e){return _u(4,4,t,e)}function e0(t,e){if(typeof e=="function"){t=t();var n=e(t);return function(){typeof n=="function"?n():e(null)}}if(e!=null)return t=t(),e.current=t,function(){e.current=null}}function n0(t,e,n){n=n!=null?n.concat([t]):null,_u(4,4,e0.bind(null,e,t),n)}function ad(){}function o0(t,e){var n=Rt();e=e===void 0?null:e;var o=n.memoizedState;return e!==null&&If(e,o[1])?o[0]:(n.memoizedState=[t,e],t)}function a0(t,e){var n=Rt();e=e===void 0?null:e;var o=n.memoizedState;if(e!==null&&If(e,o[1]))return o[0];if(o=t(),Xo){$n(!0);try{t()}finally{$n(!1)}}return n.memoizedState=[o,e],o}function ld(t,e,n){return n===void 0||(Cn&1073741824)!==0&&(it&261930)===0?t.memoizedState=e:(t.memoizedState=n,t=j0(),et.lanes|=t,fo|=t,n)}function l0(t,e,n,o){return Ee(n,e)?n:Ka.current!==null?(t=ld(t,n,o),Ee(t,e)||(Ut=!0),t):(Cn&42)===0||(Cn&1073741824)!==0&&(it&261930)===0?(Ut=!0,t.memoizedState=n):(t=j0(),et.lanes|=t,fo|=t,e)}function i0(t,e,n,o,a){var l=ft.p;ft.p=l!==0&&8>l?l:8;var i=F.T,r={};F.T=r,rd(t,!1,e,n);try{var u=a(),s=F.S;if(s!==null&&s(r,u),u!==null&&typeof u=="object"&&typeof u.then=="function"){var c=Qw(u,o);$l(t,e,c,we(t))}else $l(t,e,o,we(t))}catch(d){$l(t,e,{then:function(){},status:"rejected",reason:d},we())}finally{ft.p=l,i!==null&&r.types!==null&&(i.types=r.types),F.T=i}}function Ww(){}function rf(t,e,n,o){if(t.tag!==5)throw Error(L(476));var a=r0(t).queue;i0(t,a,e,Ro,n===null?Ww:function(){return u0(t),n(o)})}function r0(t){var e=t.memoizedState;if(e!==null)return e;e={memoizedState:Ro,baseState:Ro,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Tn,lastRenderedState:Ro},next:null};var n={};return e.next={memoizedState:n,baseState:n,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Tn,lastRenderedState:n},next:null},t.memoizedState=e,t=t.alternate,t!==null&&(t.memoizedState=e),e}function u0(t){var e=r0(t);e.next===null&&(e=t.alternate.memoizedState),$l(t,e.next.queue,{},we())}function id(){return Jt(fi)}function c0(){return Rt().memoizedState}function s0(){return Rt().memoizedState}function Fw(t){for(var e=t.return;e!==null;){switch(e.tag){case 24:case 3:var n=we();t=eo(n);var o=no(e,t,n);o!==null&&(de(o,e,n),Ql(o,e,n)),e={cache:Qf()},t.payload=e;return}e=e.return}}function Pw(t,e,n){var o=we();n={lane:o,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null},wu(t)?d0(e,n):(n=qf(t,e,n,o),n!==null&&(de(n,t,o),h0(n,e,o)))}function f0(t,e,n){var o=we();$l(t,e,n,o)}function $l(t,e,n,o){var a={lane:o,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null};if(wu(t))d0(e,a);else{var l=t.alternate;if(t.lanes===0&&(l===null||l.lanes===0)&&(l=e.lastRenderedReducer,l!==null))try{var i=e.lastRenderedState,r=l(i,n);if(a.hasEagerState=!0,a.eagerState=r,Ee(r,i))return vu(t,e,a,0),vt===null&&yu(),!1}catch{}if(n=qf(t,e,a,o),n!==null)return de(n,t,o),h0(n,e,o),!0}return!1}function rd(t,e,n,o){if(o={lane:2,revertLane:md(),gesture:null,action:o,hasEagerState:!1,eagerState:null,next:null},wu(t)){if(e)throw Error(L(479))}else e=qf(t,n,o,2),e!==null&&de(e,t,2)}function wu(t){var e=t.alternate;return t===et||e!==null&&e===et}function d0(t,e){qa=Ir=!0;var n=t.pending;n===null?e.next=e:(e.next=n.next,n.next=e),t.pending=e}function h0(t,e,n){if((n&4194048)!==0){var o=e.lanes;o&=t.pendingLanes,n|=o,e.lanes=n,Fg(t,n)}}var ui={readContext:Jt,use:Su,useCallback:At,useContext:At,useEffect:At,useImperativeHandle:At,useLayoutEffect:At,useInsertionEffect:At,useMemo:At,useReducer:At,useRef:At,useState:At,useDebugValue:At,useDeferredValue:At,useTransition:At,useSyncExternalStore:At,useId:At,useHostTransitionStatus:At,useFormState:At,useActionState:At,useOptimistic:At,useMemoCache:At,useCacheRefresh:At};ui.useEffectEvent=At;var p0={readContext:Jt,use:Su,useCallback:function(t,e){return ne().memoizedState=[t,e===void 0?null:e],t},useContext:Jt,useEffect:Wp,useImperativeHandle:function(t,e,n){n=n!=null?n.concat([t]):null,Tr(4194308,4,e0.bind(null,e,t),n)},useLayoutEffect:function(t,e){return Tr(4194308,4,t,e)},useInsertionEffect:function(t,e){Tr(4,2,t,e)},useMemo:function(t,e){var n=ne();e=e===void 0?null:e;var o=t();if(Xo){$n(!0);try{t()}finally{$n(!1)}}return n.memoizedState=[o,e],o},useReducer:function(t,e,n){var o=ne();if(n!==void 0){var a=n(e);if(Xo){$n(!0);try{n(e)}finally{$n(!1)}}}else a=e;return o.memoizedState=o.baseState=a,t={pending:null,lanes:0,dispatch:null,lastRenderedReducer:t,lastRenderedState:a},o.queue=t,t=t.dispatch=Pw.bind(null,et,t),[o.memoizedState,t]},useRef:function(t){var e=ne();return t={current:t},e.memoizedState=t},useState:function(t){t=af(t);var e=t.queue,n=f0.bind(null,et,e);return e.dispatch=n,[t.memoizedState,n]},useDebugValue:ad,useDeferredValue:function(t,e){var n=ne();return ld(n,t,e)},useTransition:function(){var t=af(!1);return t=i0.bind(null,et,t.queue,!0,!1),ne().memoizedState=t,[!1,t]},useSyncExternalStore:function(t,e,n){var o=et,a=ne();if(rt){if(n===void 0)throw Error(L(407));n=n()}else{if(n=e(),vt===null)throw Error(L(349));(it&127)!==0||qm(o,e,n)}a.memoizedState=n;var l={value:n,getSnapshot:e};return a.queue=l,Wp(Zm.bind(null,o,l,t),[t]),o.flags|=2048,$a(9,{destroy:void 0},Xm.bind(null,o,l,n,e),null),n},useId:function(){var t=ne(),e=vt.identifierPrefix;if(rt){var n=tn,o=Pe;n=(o&~(1<<32-_e(o)-1)).toString(32)+n,e="_"+e+"R_"+n,n=Wr++,0<n&&(e+="H"+n.toString(32)),e+="_"}else n=jw++,e="_"+e+"r_"+n.toString(32)+"_";return t.memoizedState=e},useHostTransitionStatus:id,useFormState:$p,useActionState:$p,useOptimistic:function(t){var e=ne();e.memoizedState=e.baseState=t;var n={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return e.queue=n,e=rd.bind(null,et,!0,n),n.dispatch=e,[t,e]},useMemoCache:ed,useCacheRefresh:function(){return ne().memoizedState=Fw.bind(null,et)},useEffectEvent:function(t){var e=ne(),n={impl:t};return e.memoizedState=n,function(){if((st&2)!==0)throw Error(L(440));return n.impl.apply(void 0,arguments)}}},ud={readContext:Jt,use:Su,useCallback:o0,useContext:Jt,useEffect:od,useImperativeHandle:n0,useInsertionEffect:Pm,useLayoutEffect:t0,useMemo:a0,useReducer:Cr,useRef:Wm,useState:function(){return Cr(Tn)},useDebugValue:ad,useDeferredValue:function(t,e){var n=Rt();return l0(n,yt.memoizedState,t,e)},useTransition:function(){var t=Cr(Tn)[0],e=Rt().memoizedState;return[typeof t=="boolean"?t:Si(t),e]},useSyncExternalStore:Vm,useId:c0,useHostTransitionStatus:id,useFormState:Jp,useActionState:Jp,useOptimistic:function(t,e){var n=Rt();return jm(n,yt,t,e)},useMemoCache:ed,useCacheRefresh:s0};ud.useEffectEvent=Fm;var g0={readContext:Jt,use:Su,useCallback:o0,useContext:Jt,useEffect:od,useImperativeHandle:n0,useInsertionEffect:Pm,useLayoutEffect:t0,useMemo:a0,useReducer:ps,useRef:Wm,useState:function(){return ps(Tn)},useDebugValue:ad,useDeferredValue:function(t,e){var n=Rt();return yt===null?ld(n,t,e):l0(n,yt.memoizedState,t,e)},useTransition:function(){var t=ps(Tn)[0],e=Rt().memoizedState;return[typeof t=="boolean"?t:Si(t),e]},useSyncExternalStore:Vm,useId:c0,useHostTransitionStatus:id,useFormState:Ip,useActionState:Ip,useOptimistic:function(t,e){var n=Rt();return yt!==null?jm(n,yt,t,e):(n.baseState=t,[t,n.queue.dispatch])},useMemoCache:ed,useCacheRefresh:s0};g0.useEffectEvent=Fm;function gs(t,e,n,o){e=t.memoizedState,n=n(o,e),n=n==null?e:wt({},e,n),t.memoizedState=n,t.lanes===0&&(t.updateQueue.baseState=n)}var uf={enqueueSetState:function(t,e,n){t=t._reactInternals;var o=we(),a=eo(o);a.payload=e,n!=null&&(a.callback=n),e=no(t,a,o),e!==null&&(de(e,t,o),Ql(e,t,o))},enqueueReplaceState:function(t,e,n){t=t._reactInternals;var o=we(),a=eo(o);a.tag=1,a.payload=e,n!=null&&(a.callback=n),e=no(t,a,o),e!==null&&(de(e,t,o),Ql(e,t,o))},enqueueForceUpdate:function(t,e){t=t._reactInternals;var n=we(),o=eo(n);o.tag=2,e!=null&&(o.callback=e),e=no(t,o,n),e!==null&&(de(e,t,n),Ql(e,t,n))}};function Fp(t,e,n,o,a,l,i){return t=t.stateNode,typeof t.shouldComponentUpdate=="function"?t.shouldComponentUpdate(o,l,i):e.prototype&&e.prototype.isPureReactComponent?!oi(n,o)||!oi(a,l):!0}function Pp(t,e,n,o){t=e.state,typeof e.componentWillReceiveProps=="function"&&e.componentWillReceiveProps(n,o),typeof e.UNSAFE_componentWillReceiveProps=="function"&&e.UNSAFE_componentWillReceiveProps(n,o),e.state!==t&&uf.enqueueReplaceState(e,e.state,null)}function Zo(t,e){var n=e;if("ref"in e){n={};for(var o in e)o!=="ref"&&(n[o]=e[o])}if(t=t.defaultProps){n===e&&(n=wt({},n));for(var a in t)n[a]===void 0&&(n[a]=t[a])}return n}function m0(t){Zr(t)}function y0(t){console.error(t)}function v0(t){Zr(t)}function Fr(t,e){try{var n=t.onUncaughtError;n(e.value,{componentStack:e.stack})}catch(o){setTimeout(function(){throw o})}}function tg(t,e,n){try{var o=t.onCaughtError;o(n.value,{componentStack:n.stack,errorBoundary:e.tag===1?e.stateNode:null})}catch(a){setTimeout(function(){throw a})}}function cf(t,e,n){return n=eo(n),n.tag=3,n.payload={element:null},n.callback=function(){Fr(t,e)},n}function b0(t){return t=eo(t),t.tag=3,t}function x0(t,e,n,o){var a=n.type.getDerivedStateFromError;if(typeof a=="function"){var l=o.value;t.payload=function(){return a(l)},t.callback=function(){tg(e,n,o)}}var i=n.stateNode;i!==null&&typeof i.componentDidCatch=="function"&&(t.callback=function(){tg(e,n,o),typeof a!="function"&&(oo===null?oo=new Set([this]):oo.add(this));var r=o.stack;this.componentDidCatch(o.value,{componentStack:r!==null?r:""})})}function tE(t,e,n,o,a){if(n.flags|=32768,o!==null&&typeof o=="object"&&typeof o.then=="function"){if(e=n.alternate,e!==null&&nl(e,n,a,!0),n=Ne.current,n!==null){switch(n.tag){case 31:case 13:return Be===null?ou():n.alternate===null&&Ct===0&&(Ct=3),n.flags&=-257,n.flags|=65536,n.lanes=a,o===Kr?n.flags|=16384:(e=n.updateQueue,e===null?n.updateQueue=new Set([o]):e.add(o),Ms(t,o,a)),!1;case 22:return n.flags|=65536,o===Kr?n.flags|=16384:(e=n.updateQueue,e===null?(e={transitions:null,markerInstances:null,retryQueue:new Set([o])},n.updateQueue=e):(n=e.retryQueue,n===null?e.retryQueue=new Set([o]):n.add(o)),Ms(t,o,a)),!1}throw Error(L(435,n.tag))}return Ms(t,o,a),ou(),!1}if(rt)return e=Ne.current,e!==null?((e.flags&65536)===0&&(e.flags|=256),e.flags|=65536,e.lanes=a,o!==Js&&(t=Error(L(422),{cause:o}),li(He(t,n)))):(o!==Js&&(e=Error(L(423),{cause:o}),li(He(e,n))),t=t.current.alternate,t.flags|=65536,a&=-a,t.lanes|=a,o=He(o,n),a=cf(t.stateNode,o,a),hs(t,a),Ct!==4&&(Ct=2)),!1;var l=Error(L(520),{cause:o});if(l=He(l,n),Wl===null?Wl=[l]:Wl.push(l),Ct!==4&&(Ct=2),e===null)return!0;o=He(o,n),n=e;do{switch(n.tag){case 3:return n.flags|=65536,t=a&-a,n.lanes|=t,t=cf(n.stateNode,o,t),hs(n,t),!1;case 1:if(e=n.type,l=n.stateNode,(n.flags&128)===0&&(typeof e.getDerivedStateFromError=="function"||l!==null&&typeof l.componentDidCatch=="function"&&(oo===null||!oo.has(l))))return n.flags|=65536,a&=-a,n.lanes|=a,a=b0(a),x0(a,t,n,o),hs(n,a),!1}n=n.return}while(n!==null);return!1}var cd=Error(L(461)),Ut=!1;function jt(t,e,n,o){e.child=t===null?Rm(e,null,n,o):qo(e,t.child,n,o)}function eg(t,e,n,o,a){n=n.render;var l=e.ref;if("ref"in o){var i={};for(var r in o)r!=="ref"&&(i[r]=o[r])}else i=o;return Vo(e),o=Wf(t,e,n,i,l,a),r=Ff(),t!==null&&!Ut?(Pf(t,e,a),On(t,e,a)):(rt&&r&&Zf(e),e.flags|=1,jt(t,e,o,a),e.child)}function ng(t,e,n,o,a){if(t===null){var l=n.type;return typeof l=="function"&&!Xf(l)&&l.defaultProps===void 0&&n.compare===null?(e.tag=15,e.type=l,S0(t,e,l,o,a)):(t=zr(n.type,null,o,e,e.mode,a),t.ref=e.ref,t.return=e,e.child=t)}if(l=t.child,!sd(t,a)){var i=l.memoizedProps;if(n=n.compare,n=n!==null?n:oi,n(i,o)&&t.ref===e.ref)return On(t,e,a)}return e.flags|=1,t=Nn(l,o),t.ref=e.ref,t.return=e,e.child=t}function S0(t,e,n,o,a){if(t!==null){var l=t.memoizedProps;if(oi(l,o)&&t.ref===e.ref)if(Ut=!1,e.pendingProps=o=l,sd(t,a))(t.flags&131072)!==0&&(Ut=!0);else return e.lanes=t.lanes,On(t,e,a)}return sf(t,e,n,o,a)}function _0(t,e,n,o){var a=o.children,l=t!==null?t.memoizedState:null;if(t===null&&e.stateNode===null&&(e.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),o.mode==="hidden"){if((e.flags&128)!==0){if(l=l!==null?l.baseLanes|n:n,t!==null){for(o=e.child=t.child,a=0;o!==null;)a=a|o.lanes|o.childLanes,o=o.sibling;o=a&~l}else o=0,e.child=null;return og(t,e,l,n,o)}if((n&536870912)!==0)e.memoizedState={baseLanes:0,cachePool:null},t!==null&&Ar(e,l!==null?l.cachePool:null),l!==null?Qp(e,l):nf(),Lm(e);else return o=e.lanes=536870912,og(t,e,l!==null?l.baseLanes|n:n,n,o)}else l!==null?(Ar(e,l.cachePool),Qp(e,l),jn(e),e.memoizedState=null):(t!==null&&Ar(e,null),nf(),jn(e));return jt(t,e,a,n),e.child}function Yl(t,e){return t!==null&&t.tag===22||e.stateNode!==null||(e.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),e.sibling}function og(t,e,n,o,a){var l=jf();return l=l===null?null:{parent:Lt._currentValue,pool:l},e.memoizedState={baseLanes:n,cachePool:l},t!==null&&Ar(e,null),nf(),Lm(e),t!==null&&nl(t,e,o,!0),e.childLanes=a,null}function Or(t,e){return e=Pr({mode:e.mode,children:e.children},t.mode),e.ref=t.ref,t.child=e,e.return=t,e}function ag(t,e,n){return qo(e,t.child,null,n),t=Or(e,e.pendingProps),t.flags|=2,ye(e),e.memoizedState=null,t}function eE(t,e,n){var o=e.pendingProps,a=(e.flags&128)!==0;if(e.flags&=-129,t===null){if(rt){if(o.mode==="hidden")return t=Or(e,o),e.lanes=536870912,Yl(null,t);if(of(e),(t=_t)?(t=py(t,Re),t=t!==null&&t.data==="&"?t:null,t!==null&&(e.memoizedState={dehydrated:t,treeContext:uo!==null?{id:Pe,overflow:tn}:null,retryLane:536870912,hydrationErrors:null},n=zm(t),n.return=e,e.child=n,$t=e,_t=null)):t=null,t===null)throw co(e);return e.lanes=536870912,null}return Or(e,o)}var l=t.memoizedState;if(l!==null){var i=l.dehydrated;if(of(e),a)if(e.flags&256)e.flags&=-257,e=ag(t,e,n);else if(e.memoizedState!==null)e.child=t.child,e.flags|=128,e=null;else throw Error(L(558));else if(Ut||nl(t,e,n,!1),a=(n&t.childLanes)!==0,Ut||a){if(o=vt,o!==null&&(i=Pg(o,n),i!==0&&i!==l.retryLane))throw l.retryLane=i,Ko(t,i),de(o,t,i),cd;ou(),e=ag(t,e,n)}else t=l.treeContext,_t=ke(i.nextSibling),$t=e,rt=!0,to=null,Re=!1,t!==null&&Cm(e,t),e=Or(e,o),e.flags|=4096;return e}return t=Nn(t.child,{mode:o.mode,children:o.children}),t.ref=e.ref,e.child=t,t.return=e,t}function Dr(t,e){var n=e.ref;if(n===null)t!==null&&t.ref!==null&&(e.flags|=4194816);else{if(typeof n!="function"&&typeof n!="object")throw Error(L(284));(t===null||t.ref!==n)&&(e.flags|=4194816)}}function sf(t,e,n,o,a){return Vo(e),n=Wf(t,e,n,o,void 0,a),o=Ff(),t!==null&&!Ut?(Pf(t,e,a),On(t,e,a)):(rt&&o&&Zf(e),e.flags|=1,jt(t,e,n,a),e.child)}function lg(t,e,n,o,a,l){return Vo(e),e.updateQueue=null,n=Ym(e,o,n,a),Um(t),o=Ff(),t!==null&&!Ut?(Pf(t,e,l),On(t,e,l)):(rt&&o&&Zf(e),e.flags|=1,jt(t,e,n,l),e.child)}function ig(t,e,n,o,a){if(Vo(e),e.stateNode===null){var l=Da,i=n.contextType;typeof i=="object"&&i!==null&&(l=Jt(i)),l=new n(o,l),e.memoizedState=l.state!==null&&l.state!==void 0?l.state:null,l.updater=uf,e.stateNode=l,l._reactInternals=e,l=e.stateNode,l.props=o,l.state=e.memoizedState,l.refs={},$f(e),i=n.contextType,l.context=typeof i=="object"&&i!==null?Jt(i):Da,l.state=e.memoizedState,i=n.getDerivedStateFromProps,typeof i=="function"&&(gs(e,n,i,o),l.state=e.memoizedState),typeof n.getDerivedStateFromProps=="function"||typeof l.getSnapshotBeforeUpdate=="function"||typeof l.UNSAFE_componentWillMount!="function"&&typeof l.componentWillMount!="function"||(i=l.state,typeof l.componentWillMount=="function"&&l.componentWillMount(),typeof l.UNSAFE_componentWillMount=="function"&&l.UNSAFE_componentWillMount(),i!==l.state&&uf.enqueueReplaceState(l,l.state,null),Kl(e,o,l,a),jl(),l.state=e.memoizedState),typeof l.componentDidMount=="function"&&(e.flags|=4194308),o=!0}else if(t===null){l=e.stateNode;var r=e.memoizedProps,u=Zo(n,r);l.props=u;var s=l.context,c=n.contextType;i=Da,typeof c=="object"&&c!==null&&(i=Jt(c));var d=n.getDerivedStateFromProps;c=typeof d=="function"||typeof l.getSnapshotBeforeUpdate=="function",r=e.pendingProps!==r,c||typeof l.UNSAFE_componentWillReceiveProps!="function"&&typeof l.componentWillReceiveProps!="function"||(r||s!==i)&&Pp(e,l,o,i),Zn=!1;var f=e.memoizedState;l.state=f,Kl(e,o,l,a),jl(),s=e.memoizedState,r||f!==s||Zn?(typeof d=="function"&&(gs(e,n,d,o),s=e.memoizedState),(u=Zn||Fp(e,n,u,o,f,s,i))?(c||typeof l.UNSAFE_componentWillMount!="function"&&typeof l.componentWillMount!="function"||(typeof l.componentWillMount=="function"&&l.componentWillMount(),typeof l.UNSAFE_componentWillMount=="function"&&l.UNSAFE_componentWillMount()),typeof l.componentDidMount=="function"&&(e.flags|=4194308)):(typeof l.componentDidMount=="function"&&(e.flags|=4194308),e.memoizedProps=o,e.memoizedState=s),l.props=o,l.state=s,l.context=i,o=u):(typeof l.componentDidMount=="function"&&(e.flags|=4194308),o=!1)}else{l=e.stateNode,tf(t,e),i=e.memoizedProps,c=Zo(n,i),l.props=c,d=e.pendingProps,f=l.context,s=n.contextType,u=Da,typeof s=="object"&&s!==null&&(u=Jt(s)),r=n.getDerivedStateFromProps,(s=typeof r=="function"||typeof l.getSnapshotBeforeUpdate=="function")||typeof l.UNSAFE_componentWillReceiveProps!="function"&&typeof l.componentWillReceiveProps!="function"||(i!==d||f!==u)&&Pp(e,l,o,u),Zn=!1,f=e.memoizedState,l.state=f,Kl(e,o,l,a),jl();var p=e.memoizedState;i!==d||f!==p||Zn||t!==null&&t.dependencies!==null&&jr(t.dependencies)?(typeof r=="function"&&(gs(e,n,r,o),p=e.memoizedState),(c=Zn||Fp(e,n,c,o,f,p,u)||t!==null&&t.dependencies!==null&&jr(t.dependencies))?(s||typeof l.UNSAFE_componentWillUpdate!="function"&&typeof l.componentWillUpdate!="function"||(typeof l.componentWillUpdate=="function"&&l.componentWillUpdate(o,p,u),typeof l.UNSAFE_componentWillUpdate=="function"&&l.UNSAFE_componentWillUpdate(o,p,u)),typeof l.componentDidUpdate=="function"&&(e.flags|=4),typeof l.getSnapshotBeforeUpdate=="function"&&(e.flags|=1024)):(typeof l.componentDidUpdate!="function"||i===t.memoizedProps&&f===t.memoizedState||(e.flags|=4),typeof l.getSnapshotBeforeUpdate!="function"||i===t.memoizedProps&&f===t.memoizedState||(e.flags|=1024),e.memoizedProps=o,e.memoizedState=p),l.props=o,l.state=p,l.context=u,o=c):(typeof l.componentDidUpdate!="function"||i===t.memoizedProps&&f===t.memoizedState||(e.flags|=4),typeof l.getSnapshotBeforeUpdate!="function"||i===t.memoizedProps&&f===t.memoizedState||(e.flags|=1024),o=!1)}return l=o,Dr(t,e),o=(e.flags&128)!==0,l||o?(l=e.stateNode,n=o&&typeof n.getDerivedStateFromError!="function"?null:l.render(),e.flags|=1,t!==null&&o?(e.child=qo(e,t.child,null,a),e.child=qo(e,null,n,a)):jt(t,e,n,a),e.memoizedState=l.state,t=e.child):t=On(t,e,a),t}function rg(t,e,n,o){return Yo(),e.flags|=256,jt(t,e,n,o),e.child}var ms={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function ys(t){return{baseLanes:t,cachePool:Om()}}function vs(t,e,n){return t=t!==null?t.childLanes&~n:0,e&&(t|=be),t}function w0(t,e,n){var o=e.pendingProps,a=!1,l=(e.flags&128)!==0,i;if((i=l)||(i=t!==null&&t.memoizedState===null?!1:(Ht.current&2)!==0),i&&(a=!0,e.flags&=-129),i=(e.flags&32)!==0,e.flags&=-33,t===null){if(rt){if(a?Qn(e):jn(e),(t=_t)?(t=py(t,Re),t=t!==null&&t.data!=="&"?t:null,t!==null&&(e.memoizedState={dehydrated:t,treeContext:uo!==null?{id:Pe,overflow:tn}:null,retryLane:536870912,hydrationErrors:null},n=zm(t),n.return=e,e.child=n,$t=e,_t=null)):t=null,t===null)throw co(e);return Ef(t)?e.lanes=32:e.lanes=536870912,null}var r=o.children;return o=o.fallback,a?(jn(e),a=e.mode,r=Pr({mode:"hidden",children:r},a),o=Bo(o,a,n,null),r.return=e,o.return=e,r.sibling=o,e.child=r,o=e.child,o.memoizedState=ys(n),o.childLanes=vs(t,i,n),e.memoizedState=ms,Yl(null,o)):(Qn(e),ff(e,r))}var u=t.memoizedState;if(u!==null&&(r=u.dehydrated,r!==null)){if(l)e.flags&256?(Qn(e),e.flags&=-257,e=bs(t,e,n)):e.memoizedState!==null?(jn(e),e.child=t.child,e.flags|=128,e=null):(jn(e),r=o.fallback,a=e.mode,o=Pr({mode:"visible",children:o.children},a),r=Bo(r,a,n,null),r.flags|=2,o.return=e,r.return=e,o.sibling=r,e.child=o,qo(e,t.child,null,n),o=e.child,o.memoizedState=ys(n),o.childLanes=vs(t,i,n),e.memoizedState=ms,e=Yl(null,o));else if(Qn(e),Ef(r)){if(i=r.nextSibling&&r.nextSibling.dataset,i)var s=i.dgst;i=s,o=Error(L(419)),o.stack="",o.digest=i,li({value:o,source:null,stack:null}),e=bs(t,e,n)}else if(Ut||nl(t,e,n,!1),i=(n&t.childLanes)!==0,Ut||i){if(i=vt,i!==null&&(o=Pg(i,n),o!==0&&o!==u.retryLane))throw u.retryLane=o,Ko(t,o),de(i,t,o),cd;wf(r)||ou(),e=bs(t,e,n)}else wf(r)?(e.flags|=192,e.child=t.child,e=null):(t=u.treeContext,_t=ke(r.nextSibling),$t=e,rt=!0,to=null,Re=!1,t!==null&&Cm(e,t),e=ff(e,o.children),e.flags|=4096);return e}return a?(jn(e),r=o.fallback,a=e.mode,u=t.child,s=u.sibling,o=Nn(u,{mode:"hidden",children:o.children}),o.subtreeFlags=u.subtreeFlags&65011712,s!==null?r=Nn(s,r):(r=Bo(r,a,n,null),r.flags|=2),r.return=e,o.return=e,o.sibling=r,e.child=o,Yl(null,o),o=e.child,r=t.child.memoizedState,r===null?r=ys(n):(a=r.cachePool,a!==null?(u=Lt._currentValue,a=a.parent!==u?{parent:u,pool:u}:a):a=Om(),r={baseLanes:r.baseLanes|n,cachePool:a}),o.memoizedState=r,o.childLanes=vs(t,i,n),e.memoizedState=ms,Yl(t.child,o)):(Qn(e),n=t.child,t=n.sibling,n=Nn(n,{mode:"visible",children:o.children}),n.return=e,n.sibling=null,t!==null&&(i=e.deletions,i===null?(e.deletions=[t],e.flags|=16):i.push(t)),e.child=n,e.memoizedState=null,n)}function ff(t,e){return e=Pr({mode:"visible",children:e},t.mode),e.return=t,t.child=e}function Pr(t,e){return t=ve(22,t,null,e),t.lanes=0,t}function bs(t,e,n){return qo(e,t.child,null,n),t=ff(e,e.pendingProps.children),t.flags|=2,e.memoizedState=null,t}function ug(t,e,n){t.lanes|=e;var o=t.alternate;o!==null&&(o.lanes|=e),Ws(t.return,e,n)}function xs(t,e,n,o,a,l){var i=t.memoizedState;i===null?t.memoizedState={isBackwards:e,rendering:null,renderingStartTime:0,last:o,tail:n,tailMode:a,treeForkCount:l}:(i.isBackwards=e,i.rendering=null,i.renderingStartTime=0,i.last=o,i.tail=n,i.tailMode=a,i.treeForkCount=l)}function E0(t,e,n){var o=e.pendingProps,a=o.revealOrder,l=o.tail;o=o.children;var i=Ht.current,r=(i&2)!==0;if(r?(i=i&1|2,e.flags|=128):i&=1,bt(Ht,i),jt(t,e,o,n),o=rt?ai:0,!r&&t!==null&&(t.flags&128)!==0)t:for(t=e.child;t!==null;){if(t.tag===13)t.memoizedState!==null&&ug(t,n,e);else if(t.tag===19)ug(t,n,e);else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break t;for(;t.sibling===null;){if(t.return===null||t.return===e)break t;t=t.return}t.sibling.return=t.return,t=t.sibling}switch(a){case"forwards":for(n=e.child,a=null;n!==null;)t=n.alternate,t!==null&&Jr(t)===null&&(a=n),n=n.sibling;n=a,n===null?(a=e.child,e.child=null):(a=n.sibling,n.sibling=null),xs(e,!1,a,n,l,o);break;case"backwards":case"unstable_legacy-backwards":for(n=null,a=e.child,e.child=null;a!==null;){if(t=a.alternate,t!==null&&Jr(t)===null){e.child=a;break}t=a.sibling,a.sibling=n,n=a,a=t}xs(e,!0,n,null,l,o);break;case"together":xs(e,!1,null,null,void 0,o);break;default:e.memoizedState=null}return e.child}function On(t,e,n){if(t!==null&&(e.dependencies=t.dependencies),fo|=e.lanes,(n&e.childLanes)===0)if(t!==null){if(nl(t,e,n,!1),(n&e.childLanes)===0)return null}else return null;if(t!==null&&e.child!==t.child)throw Error(L(153));if(e.child!==null){for(t=e.child,n=Nn(t,t.pendingProps),e.child=n,n.return=e;t.sibling!==null;)t=t.sibling,n=n.sibling=Nn(t,t.pendingProps),n.return=e;n.sibling=null}return e.child}function sd(t,e){return(t.lanes&e)!==0?!0:(t=t.dependencies,!!(t!==null&&jr(t)))}function nE(t,e,n){switch(e.tag){case 3:Yr(e,e.stateNode.containerInfo),Gn(e,Lt,t.memoizedState.cache),Yo();break;case 27:case 5:Us(e);break;case 4:Yr(e,e.stateNode.containerInfo);break;case 10:Gn(e,e.type,e.memoizedProps.value);break;case 31:if(e.memoizedState!==null)return e.flags|=128,of(e),null;break;case 13:var o=e.memoizedState;if(o!==null)return o.dehydrated!==null?(Qn(e),e.flags|=128,null):(n&e.child.childLanes)!==0?w0(t,e,n):(Qn(e),t=On(t,e,n),t!==null?t.sibling:null);Qn(e);break;case 19:var a=(t.flags&128)!==0;if(o=(n&e.childLanes)!==0,o||(nl(t,e,n,!1),o=(n&e.childLanes)!==0),a){if(o)return E0(t,e,n);e.flags|=128}if(a=e.memoizedState,a!==null&&(a.rendering=null,a.tail=null,a.lastEffect=null),bt(Ht,Ht.current),o)break;return null;case 22:return e.lanes=0,_0(t,e,n,e.pendingProps);case 24:Gn(e,Lt,t.memoizedState.cache)}return On(t,e,n)}function N0(t,e,n){if(t!==null)if(t.memoizedProps!==e.pendingProps)Ut=!0;else{if(!sd(t,n)&&(e.flags&128)===0)return Ut=!1,nE(t,e,n);Ut=(t.flags&131072)!==0}else Ut=!1,rt&&(e.flags&1048576)!==0&&Am(e,ai,e.index);switch(e.lanes=0,e.tag){case 16:t:{var o=e.pendingProps;if(t=Do(e.elementType),e.type=t,typeof t=="function")Xf(t)?(o=Zo(t,o),e.tag=1,e=ig(null,e,t,o,n)):(e.tag=0,e=sf(null,e,t,o,n));else{if(t!=null){var a=t.$$typeof;if(a===Af){e.tag=11,e=eg(null,e,t,o,n);break t}else if(a===Cf){e.tag=14,e=ng(null,e,t,o,n);break t}}throw e=ks(t)||t,Error(L(306,e,""))}}return e;case 0:return sf(t,e,e.type,e.pendingProps,n);case 1:return o=e.type,a=Zo(o,e.pendingProps),ig(t,e,o,a,n);case 3:t:{if(Yr(e,e.stateNode.containerInfo),t===null)throw Error(L(387));o=e.pendingProps;var l=e.memoizedState;a=l.element,tf(t,e),Kl(e,o,null,n);var i=e.memoizedState;if(o=i.cache,Gn(e,Lt,o),o!==l.cache&&Fs(e,[Lt],n,!0),jl(),o=i.element,l.isDehydrated)if(l={element:o,isDehydrated:!1,cache:i.cache},e.updateQueue.baseState=l,e.memoizedState=l,e.flags&256){e=rg(t,e,o,n);break t}else if(o!==a){a=He(Error(L(424)),e),li(a),e=rg(t,e,o,n);break t}else for(t=e.stateNode.containerInfo,t.nodeType===9?t=t.body:t=t.nodeName==="HTML"?t.ownerDocument.body:t,_t=ke(t.firstChild),$t=e,rt=!0,to=null,Re=!0,n=Rm(e,null,o,n),e.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if(Yo(),o===a){e=On(t,e,n);break t}jt(t,e,o,n)}e=e.child}return e;case 26:return Dr(t,e),t===null?(n=Tg(e.type,null,e.pendingProps,null))?e.memoizedState=n:rt||(n=e.type,t=e.pendingProps,o=ru(Pn.current).createElement(n),o[Kt]=e,o[he]=t,It(o,n,t),Zt(o),e.stateNode=o):e.memoizedState=Tg(e.type,t.memoizedProps,e.pendingProps,t.memoizedState),null;case 27:return Us(e),t===null&&rt&&(o=e.stateNode=gy(e.type,e.pendingProps,Pn.current),$t=e,Re=!0,a=_t,po(e.type)?(Nf=a,_t=ke(o.firstChild)):_t=a),jt(t,e,e.pendingProps.children,n),Dr(t,e),t===null&&(e.flags|=4194304),e.child;case 5:return t===null&&rt&&((a=o=_t)&&(o=TE(o,e.type,e.pendingProps,Re),o!==null?(e.stateNode=o,$t=e,_t=ke(o.firstChild),Re=!1,a=!0):a=!1),a||co(e)),Us(e),a=e.type,l=e.pendingProps,i=t!==null?t.memoizedProps:null,o=l.children,Sf(a,l)?o=null:i!==null&&Sf(a,i)&&(e.flags|=32),e.memoizedState!==null&&(a=Wf(t,e,Kw,null,null,n),fi._currentValue=a),Dr(t,e),jt(t,e,o,n),e.child;case 6:return t===null&&rt&&((t=n=_t)&&(n=OE(n,e.pendingProps,Re),n!==null?(e.stateNode=n,$t=e,_t=null,t=!0):t=!1),t||co(e)),null;case 13:return w0(t,e,n);case 4:return Yr(e,e.stateNode.containerInfo),o=e.pendingProps,t===null?e.child=qo(e,null,o,n):jt(t,e,o,n),e.child;case 11:return eg(t,e,e.type,e.pendingProps,n);case 7:return jt(t,e,e.pendingProps,n),e.child;case 8:return jt(t,e,e.pendingProps.children,n),e.child;case 12:return jt(t,e,e.pendingProps.children,n),e.child;case 10:return o=e.pendingProps,Gn(e,e.type,o.value),jt(t,e,o.children,n),e.child;case 9:return a=e.type._context,o=e.pendingProps.children,Vo(e),a=Jt(a),o=o(a),e.flags|=1,jt(t,e,o,n),e.child;case 14:return ng(t,e,e.type,e.pendingProps,n);case 15:return S0(t,e,e.type,e.pendingProps,n);case 19:return E0(t,e,n);case 31:return eE(t,e,n);case 22:return _0(t,e,n,e.pendingProps);case 24:return Vo(e),o=Jt(Lt),t===null?(a=jf(),a===null&&(a=vt,l=Qf(),a.pooledCache=l,l.refCount++,l!==null&&(a.pooledCacheLanes|=n),a=l),e.memoizedState={parent:o,cache:a},$f(e),Gn(e,Lt,a)):((t.lanes&n)!==0&&(tf(t,e),Kl(e,null,null,n),jl()),a=t.memoizedState,l=e.memoizedState,a.parent!==o?(a={parent:o,cache:o},e.memoizedState=a,e.lanes===0&&(e.memoizedState=e.updateQueue.baseState=a),Gn(e,Lt,o)):(o=l.cache,Gn(e,Lt,o),o!==a.cache&&Fs(e,[Lt],n,!0))),jt(t,e,e.pendingProps.children,n),e.child;case 29:throw e.pendingProps}throw Error(L(156,e.tag))}function mn(t){t.flags|=4}function Ss(t,e,n,o,a){if((e=(t.mode&32)!==0)&&(e=!1),e){if(t.flags|=16777216,(a&335544128)===a)if(t.stateNode.complete)t.flags|=8192;else if(J0())t.flags|=8192;else throw Lo=Kr,Kf}else t.flags&=-16777217}function cg(t,e){if(e.type!=="stylesheet"||(e.state.loading&4)!==0)t.flags&=-16777217;else if(t.flags|=16777216,!vy(e))if(J0())t.flags|=8192;else throw Lo=Kr,Kf}function mr(t,e){e!==null&&(t.flags|=4),t.flags&16384&&(e=t.tag!==22?Ig():536870912,t.lanes|=e,Ja|=e)}function Dl(t,e){if(!rt)switch(t.tailMode){case"hidden":e=t.tail;for(var n=null;e!==null;)e.alternate!==null&&(n=e),e=e.sibling;n===null?t.tail=null:n.sibling=null;break;case"collapsed":n=t.tail;for(var o=null;n!==null;)n.alternate!==null&&(o=n),n=n.sibling;o===null?e||t.tail===null?t.tail=null:t.tail.sibling=null:o.sibling=null}}function St(t){var e=t.alternate!==null&&t.alternate.child===t.child,n=0,o=0;if(e)for(var a=t.child;a!==null;)n|=a.lanes|a.childLanes,o|=a.subtreeFlags&65011712,o|=a.flags&65011712,a.return=t,a=a.sibling;else for(a=t.child;a!==null;)n|=a.lanes|a.childLanes,o|=a.subtreeFlags,o|=a.flags,a.return=t,a=a.sibling;return t.subtreeFlags|=o,t.childLanes=n,e}function oE(t,e,n){var o=e.pendingProps;switch(Gf(e),e.tag){case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return St(e),null;case 1:return St(e),null;case 3:return n=e.stateNode,o=null,t!==null&&(o=t.memoizedState.cache),e.memoizedState.cache!==o&&(e.flags|=2048),Mn(Lt),Za(),n.pendingContext&&(n.context=n.pendingContext,n.pendingContext=null),(t===null||t.child===null)&&(xa(e)?mn(e):t===null||t.memoizedState.isDehydrated&&(e.flags&256)===0||(e.flags|=1024,ds())),St(e),null;case 26:var a=e.type,l=e.memoizedState;return t===null?(mn(e),l!==null?(St(e),cg(e,l)):(St(e),Ss(e,a,null,o,n))):l?l!==t.memoizedState?(mn(e),St(e),cg(e,l)):(St(e),e.flags&=-16777217):(t=t.memoizedProps,t!==o&&mn(e),St(e),Ss(e,a,t,o,n)),null;case 27:if(Vr(e),n=Pn.current,a=e.type,t!==null&&e.stateNode!=null)t.memoizedProps!==o&&mn(e);else{if(!o){if(e.stateNode===null)throw Error(L(166));return St(e),null}t=nn.current,xa(e)?Up(e,t):(t=gy(a,o,n),e.stateNode=t,mn(e))}return St(e),null;case 5:if(Vr(e),a=e.type,t!==null&&e.stateNode!=null)t.memoizedProps!==o&&mn(e);else{if(!o){if(e.stateNode===null)throw Error(L(166));return St(e),null}if(l=nn.current,xa(e))Up(e,l);else{var i=ru(Pn.current);switch(l){case 1:l=i.createElementNS("http://www.w3.org/2000/svg",a);break;case 2:l=i.createElementNS("http://www.w3.org/1998/Math/MathML",a);break;default:switch(a){case"svg":l=i.createElementNS("http://www.w3.org/2000/svg",a);break;case"math":l=i.createElementNS("http://www.w3.org/1998/Math/MathML",a);break;case"script":l=i.createElement("div"),l.innerHTML="<script><\/script>",l=l.removeChild(l.firstChild);break;case"select":l=typeof o.is=="string"?i.createElement("select",{is:o.is}):i.createElement("select"),o.multiple?l.multiple=!0:o.size&&(l.size=o.size);break;default:l=typeof o.is=="string"?i.createElement(a,{is:o.is}):i.createElement(a)}}l[Kt]=e,l[he]=o;t:for(i=e.child;i!==null;){if(i.tag===5||i.tag===6)l.appendChild(i.stateNode);else if(i.tag!==4&&i.tag!==27&&i.child!==null){i.child.return=i,i=i.child;continue}if(i===e)break t;for(;i.sibling===null;){if(i.return===null||i.return===e)break t;i=i.return}i.sibling.return=i.return,i=i.sibling}e.stateNode=l;t:switch(It(l,a,o),a){case"button":case"input":case"select":case"textarea":o=!!o.autoFocus;break t;case"img":o=!0;break t;default:o=!1}o&&mn(e)}}return St(e),Ss(e,e.type,t===null?null:t.memoizedProps,e.pendingProps,n),null;case 6:if(t&&e.stateNode!=null)t.memoizedProps!==o&&mn(e);else{if(typeof o!="string"&&e.stateNode===null)throw Error(L(166));if(t=Pn.current,xa(e)){if(t=e.stateNode,n=e.memoizedProps,o=null,a=$t,a!==null)switch(a.tag){case 27:case 5:o=a.memoizedProps}t[Kt]=e,t=!!(t.nodeValue===n||o!==null&&o.suppressHydrationWarning===!0||fy(t.nodeValue,n)),t||co(e,!0)}else t=ru(t).createTextNode(o),t[Kt]=e,e.stateNode=t}return St(e),null;case 31:if(n=e.memoizedState,t===null||t.memoizedState!==null){if(o=xa(e),n!==null){if(t===null){if(!o)throw Error(L(318));if(t=e.memoizedState,t=t!==null?t.dehydrated:null,!t)throw Error(L(557));t[Kt]=e}else Yo(),(e.flags&128)===0&&(e.memoizedState=null),e.flags|=4;St(e),t=!1}else n=ds(),t!==null&&t.memoizedState!==null&&(t.memoizedState.hydrationErrors=n),t=!0;if(!t)return e.flags&256?(ye(e),e):(ye(e),null);if((e.flags&128)!==0)throw Error(L(558))}return St(e),null;case 13:if(o=e.memoizedState,t===null||t.memoizedState!==null&&t.memoizedState.dehydrated!==null){if(a=xa(e),o!==null&&o.dehydrated!==null){if(t===null){if(!a)throw Error(L(318));if(a=e.memoizedState,a=a!==null?a.dehydrated:null,!a)throw Error(L(317));a[Kt]=e}else Yo(),(e.flags&128)===0&&(e.memoizedState=null),e.flags|=4;St(e),a=!1}else a=ds(),t!==null&&t.memoizedState!==null&&(t.memoizedState.hydrationErrors=a),a=!0;if(!a)return e.flags&256?(ye(e),e):(ye(e),null)}return ye(e),(e.flags&128)!==0?(e.lanes=n,e):(n=o!==null,t=t!==null&&t.memoizedState!==null,n&&(o=e.child,a=null,o.alternate!==null&&o.alternate.memoizedState!==null&&o.alternate.memoizedState.cachePool!==null&&(a=o.alternate.memoizedState.cachePool.pool),l=null,o.memoizedState!==null&&o.memoizedState.cachePool!==null&&(l=o.memoizedState.cachePool.pool),l!==a&&(o.flags|=2048)),n!==t&&n&&(e.child.flags|=8192),mr(e,e.updateQueue),St(e),null);case 4:return Za(),t===null&&yd(e.stateNode.containerInfo),St(e),null;case 10:return Mn(e.type),St(e),null;case 19:if(Gt(Ht),o=e.memoizedState,o===null)return St(e),null;if(a=(e.flags&128)!==0,l=o.rendering,l===null)if(a)Dl(o,!1);else{if(Ct!==0||t!==null&&(t.flags&128)!==0)for(t=e.child;t!==null;){if(l=Jr(t),l!==null){for(e.flags|=128,Dl(o,!1),t=l.updateQueue,e.updateQueue=t,mr(e,t),e.subtreeFlags=0,t=n,n=e.child;n!==null;)Mm(n,t),n=n.sibling;return bt(Ht,Ht.current&1|2),rt&&xn(e,o.treeForkCount),e.child}t=t.sibling}o.tail!==null&&xe()>eu&&(e.flags|=128,a=!0,Dl(o,!1),e.lanes=4194304)}else{if(!a)if(t=Jr(l),t!==null){if(e.flags|=128,a=!0,t=t.updateQueue,e.updateQueue=t,mr(e,t),Dl(o,!0),o.tail===null&&o.tailMode==="hidden"&&!l.alternate&&!rt)return St(e),null}else 2*xe()-o.renderingStartTime>eu&&n!==536870912&&(e.flags|=128,a=!0,Dl(o,!1),e.lanes=4194304);o.isBackwards?(l.sibling=e.child,e.child=l):(t=o.last,t!==null?t.sibling=l:e.child=l,o.last=l)}return o.tail!==null?(t=o.tail,o.rendering=t,o.tail=t.sibling,o.renderingStartTime=xe(),t.sibling=null,n=Ht.current,bt(Ht,a?n&1|2:n&1),rt&&xn(e,o.treeForkCount),t):(St(e),null);case 22:case 23:return ye(e),Jf(),o=e.memoizedState!==null,t!==null?t.memoizedState!==null!==o&&(e.flags|=8192):o&&(e.flags|=8192),o?(n&536870912)!==0&&(e.flags&128)===0&&(St(e),e.subtreeFlags&6&&(e.flags|=8192)):St(e),n=e.updateQueue,n!==null&&mr(e,n.retryQueue),n=null,t!==null&&t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(n=t.memoizedState.cachePool.pool),o=null,e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(o=e.memoizedState.cachePool.pool),o!==n&&(e.flags|=2048),t!==null&&Gt(ko),null;case 24:return n=null,t!==null&&(n=t.memoizedState.cache),e.memoizedState.cache!==n&&(e.flags|=2048),Mn(Lt),St(e),null;case 25:return null;case 30:return null}throw Error(L(156,e.tag))}function aE(t,e){switch(Gf(e),e.tag){case 1:return t=e.flags,t&65536?(e.flags=t&-65537|128,e):null;case 3:return Mn(Lt),Za(),t=e.flags,(t&65536)!==0&&(t&128)===0?(e.flags=t&-65537|128,e):null;case 26:case 27:case 5:return Vr(e),null;case 31:if(e.memoizedState!==null){if(ye(e),e.alternate===null)throw Error(L(340));Yo()}return t=e.flags,t&65536?(e.flags=t&-65537|128,e):null;case 13:if(ye(e),t=e.memoizedState,t!==null&&t.dehydrated!==null){if(e.alternate===null)throw Error(L(340));Yo()}return t=e.flags,t&65536?(e.flags=t&-65537|128,e):null;case 19:return Gt(Ht),null;case 4:return Za(),null;case 10:return Mn(e.type),null;case 22:case 23:return ye(e),Jf(),t!==null&&Gt(ko),t=e.flags,t&65536?(e.flags=t&-65537|128,e):null;case 24:return Mn(Lt),null;case 25:return null;default:return null}}function M0(t,e){switch(Gf(e),e.tag){case 3:Mn(Lt),Za();break;case 26:case 27:case 5:Vr(e);break;case 4:Za();break;case 31:e.memoizedState!==null&&ye(e);break;case 13:ye(e);break;case 19:Gt(Ht);break;case 10:Mn(e.type);break;case 22:case 23:ye(e),Jf(),t!==null&&Gt(ko);break;case 24:Mn(Lt)}}function _i(t,e){try{var n=e.updateQueue,o=n!==null?n.lastEffect:null;if(o!==null){var a=o.next;n=a;do{if((n.tag&t)===t){o=void 0;var l=n.create,i=n.inst;o=l(),i.destroy=o}n=n.next}while(n!==a)}}catch(r){pt(e,e.return,r)}}function so(t,e,n){try{var o=e.updateQueue,a=o!==null?o.lastEffect:null;if(a!==null){var l=a.next;o=l;do{if((o.tag&t)===t){var i=o.inst,r=i.destroy;if(r!==void 0){i.destroy=void 0,a=e;var u=n,s=r;try{s()}catch(c){pt(a,u,c)}}}o=o.next}while(o!==l)}}catch(c){pt(e,e.return,c)}}function z0(t){var e=t.updateQueue;if(e!==null){var n=t.stateNode;try{km(e,n)}catch(o){pt(t,t.return,o)}}}function A0(t,e,n){n.props=Zo(t.type,t.memoizedProps),n.state=t.memoizedState;try{n.componentWillUnmount()}catch(o){pt(t,e,o)}}function Jl(t,e){try{var n=t.ref;if(n!==null){switch(t.tag){case 26:case 27:case 5:var o=t.stateNode;break;case 30:o=t.stateNode;break;default:o=t.stateNode}typeof n=="function"?t.refCleanup=n(o):n.current=o}}catch(a){pt(t,e,a)}}function en(t,e){var n=t.ref,o=t.refCleanup;if(n!==null)if(typeof o=="function")try{o()}catch(a){pt(t,e,a)}finally{t.refCleanup=null,t=t.alternate,t!=null&&(t.refCleanup=null)}else if(typeof n=="function")try{n(null)}catch(a){pt(t,e,a)}else n.current=null}function C0(t){var e=t.type,n=t.memoizedProps,o=t.stateNode;try{t:switch(e){case"button":case"input":case"select":case"textarea":n.autoFocus&&o.focus();break t;case"img":n.src?o.src=n.src:n.srcSet&&(o.srcset=n.srcSet)}}catch(a){pt(t,t.return,a)}}function _s(t,e,n){try{var o=t.stateNode;EE(o,t.type,n,e),o[he]=e}catch(a){pt(t,t.return,a)}}function T0(t){return t.tag===5||t.tag===3||t.tag===26||t.tag===27&&po(t.type)||t.tag===4}function ws(t){t:for(;;){for(;t.sibling===null;){if(t.return===null||T0(t.return))return null;t=t.return}for(t.sibling.return=t.return,t=t.sibling;t.tag!==5&&t.tag!==6&&t.tag!==18;){if(t.tag===27&&po(t.type)||t.flags&2||t.child===null||t.tag===4)continue t;t.child.return=t,t=t.child}if(!(t.flags&2))return t.stateNode}}function df(t,e,n){var o=t.tag;if(o===5||o===6)t=t.stateNode,e?(n.nodeType===9?n.body:n.nodeName==="HTML"?n.ownerDocument.body:n).insertBefore(t,e):(e=n.nodeType===9?n.body:n.nodeName==="HTML"?n.ownerDocument.body:n,e.appendChild(t),n=n._reactRootContainer,n!=null||e.onclick!==null||(e.onclick=wn));else if(o!==4&&(o===27&&po(t.type)&&(n=t.stateNode,e=null),t=t.child,t!==null))for(df(t,e,n),t=t.sibling;t!==null;)df(t,e,n),t=t.sibling}function tu(t,e,n){var o=t.tag;if(o===5||o===6)t=t.stateNode,e?n.insertBefore(t,e):n.appendChild(t);else if(o!==4&&(o===27&&po(t.type)&&(n=t.stateNode),t=t.child,t!==null))for(tu(t,e,n),t=t.sibling;t!==null;)tu(t,e,n),t=t.sibling}function O0(t){var e=t.stateNode,n=t.memoizedProps;try{for(var o=t.type,a=e.attributes;a.length;)e.removeAttributeNode(a[0]);It(e,o,n),e[Kt]=t,e[he]=n}catch(l){pt(t,t.return,l)}}var Sn=!1,kt=!1,Es=!1,sg=typeof WeakSet=="function"?WeakSet:Set,Xt=null;function lE(t,e){if(t=t.containerInfo,bf=fu,t=vm(t),Yf(t)){if("selectionStart"in t)var n={start:t.selectionStart,end:t.selectionEnd};else t:{n=(n=t.ownerDocument)&&n.defaultView||window;var o=n.getSelection&&n.getSelection();if(o&&o.rangeCount!==0){n=o.anchorNode;var a=o.anchorOffset,l=o.focusNode;o=o.focusOffset;try{n.nodeType,l.nodeType}catch{n=null;break t}var i=0,r=-1,u=-1,s=0,c=0,d=t,f=null;e:for(;;){for(var p;d!==n||a!==0&&d.nodeType!==3||(r=i+a),d!==l||o!==0&&d.nodeType!==3||(u=i+o),d.nodeType===3&&(i+=d.nodeValue.length),(p=d.firstChild)!==null;)f=d,d=p;for(;;){if(d===t)break e;if(f===n&&++s===a&&(r=i),f===l&&++c===o&&(u=i),(p=d.nextSibling)!==null)break;d=f,f=d.parentNode}d=p}n=r===-1||u===-1?null:{start:r,end:u}}else n=null}n=n||{start:0,end:0}}else n=null;for(xf={focusedElem:t,selectionRange:n},fu=!1,Xt=e;Xt!==null;)if(e=Xt,t=e.child,(e.subtreeFlags&1028)!==0&&t!==null)t.return=e,Xt=t;else for(;Xt!==null;){switch(e=Xt,l=e.alternate,t=e.flags,e.tag){case 0:if((t&4)!==0&&(t=e.updateQueue,t=t!==null?t.events:null,t!==null))for(n=0;n<t.length;n++)a=t[n],a.ref.impl=a.nextImpl;break;case 11:case 15:break;case 1:if((t&1024)!==0&&l!==null){t=void 0,n=e,a=l.memoizedProps,l=l.memoizedState,o=n.stateNode;try{var y=Zo(n.type,a);t=o.getSnapshotBeforeUpdate(y,l),o.__reactInternalSnapshotBeforeUpdate=t}catch(b){pt(n,n.return,b)}}break;case 3:if((t&1024)!==0){if(t=e.stateNode.containerInfo,n=t.nodeType,n===9)_f(t);else if(n===1)switch(t.nodeName){case"HEAD":case"HTML":case"BODY":_f(t);break;default:t.textContent=""}}break;case 5:case 26:case 27:case 6:case 4:case 17:break;default:if((t&1024)!==0)throw Error(L(163))}if(t=e.sibling,t!==null){t.return=e.return,Xt=t;break}Xt=e.return}}function D0(t,e,n){var o=n.flags;switch(n.tag){case 0:case 11:case 15:vn(t,n),o&4&&_i(5,n);break;case 1:if(vn(t,n),o&4)if(t=n.stateNode,e===null)try{t.componentDidMount()}catch(i){pt(n,n.return,i)}else{var a=Zo(n.type,e.memoizedProps);e=e.memoizedState;try{t.componentDidUpdate(a,e,t.__reactInternalSnapshotBeforeUpdate)}catch(i){pt(n,n.return,i)}}o&64&&z0(n),o&512&&Jl(n,n.return);break;case 3:if(vn(t,n),o&64&&(t=n.updateQueue,t!==null)){if(e=null,n.child!==null)switch(n.child.tag){case 27:case 5:e=n.child.stateNode;break;case 1:e=n.child.stateNode}try{km(t,e)}catch(i){pt(n,n.return,i)}}break;case 27:e===null&&o&4&&O0(n);case 26:case 5:vn(t,n),e===null&&o&4&&C0(n),o&512&&Jl(n,n.return);break;case 12:vn(t,n);break;case 31:vn(t,n),o&4&&B0(t,n);break;case 13:vn(t,n),o&4&&k0(t,n),o&64&&(t=n.memoizedState,t!==null&&(t=t.dehydrated,t!==null&&(n=pE.bind(null,n),DE(t,n))));break;case 22:if(o=n.memoizedState!==null||Sn,!o){e=e!==null&&e.memoizedState!==null||kt,a=Sn;var l=kt;Sn=o,(kt=e)&&!l?bn(t,n,(n.subtreeFlags&8772)!==0):vn(t,n),Sn=a,kt=l}break;case 30:break;default:vn(t,n)}}function H0(t){var e=t.alternate;e!==null&&(t.alternate=null,H0(e)),t.child=null,t.deletions=null,t.sibling=null,t.tag===5&&(e=t.stateNode,e!==null&&Hf(e)),t.stateNode=null,t.return=null,t.dependencies=null,t.memoizedProps=null,t.memoizedState=null,t.pendingProps=null,t.stateNode=null,t.updateQueue=null}var Mt=null,se=!1;function yn(t,e,n){for(n=n.child;n!==null;)R0(t,e,n),n=n.sibling}function R0(t,e,n){if(Se&&typeof Se.onCommitFiberUnmount=="function")try{Se.onCommitFiberUnmount(gi,n)}catch{}switch(n.tag){case 26:kt||en(n,e),yn(t,e,n),n.memoizedState?n.memoizedState.count--:n.stateNode&&(n=n.stateNode,n.parentNode.removeChild(n));break;case 27:kt||en(n,e);var o=Mt,a=se;po(n.type)&&(Mt=n.stateNode,se=!1),yn(t,e,n),Pl(n.stateNode),Mt=o,se=a;break;case 5:kt||en(n,e);case 6:if(o=Mt,a=se,Mt=null,yn(t,e,n),Mt=o,se=a,Mt!==null)if(se)try{(Mt.nodeType===9?Mt.body:Mt.nodeName==="HTML"?Mt.ownerDocument.body:Mt).removeChild(n.stateNode)}catch(l){pt(n,e,l)}else try{Mt.removeChild(n.stateNode)}catch(l){pt(n,e,l)}break;case 18:Mt!==null&&(se?(t=Mt,Ng(t.nodeType===9?t.body:t.nodeName==="HTML"?t.ownerDocument.body:t,n.stateNode),Pa(t)):Ng(Mt,n.stateNode));break;case 4:o=Mt,a=se,Mt=n.stateNode.containerInfo,se=!0,yn(t,e,n),Mt=o,se=a;break;case 0:case 11:case 14:case 15:so(2,n,e),kt||so(4,n,e),yn(t,e,n);break;case 1:kt||(en(n,e),o=n.stateNode,typeof o.componentWillUnmount=="function"&&A0(n,e,o)),yn(t,e,n);break;case 21:yn(t,e,n);break;case 22:kt=(o=kt)||n.memoizedState!==null,yn(t,e,n),kt=o;break;default:yn(t,e,n)}}function B0(t,e){if(e.memoizedState===null&&(t=e.alternate,t!==null&&(t=t.memoizedState,t!==null))){t=t.dehydrated;try{Pa(t)}catch(n){pt(e,e.return,n)}}}function k0(t,e){if(e.memoizedState===null&&(t=e.alternate,t!==null&&(t=t.memoizedState,t!==null&&(t=t.dehydrated,t!==null))))try{Pa(t)}catch(n){pt(e,e.return,n)}}function iE(t){switch(t.tag){case 31:case 13:case 19:var e=t.stateNode;return e===null&&(e=t.stateNode=new sg),e;case 22:return t=t.stateNode,e=t._retryCache,e===null&&(e=t._retryCache=new sg),e;default:throw Error(L(435,t.tag))}}function yr(t,e){var n=iE(t);e.forEach(function(o){if(!n.has(o)){n.add(o);var a=gE.bind(null,t,o);o.then(a,a)}})}function ue(t,e){var n=e.deletions;if(n!==null)for(var o=0;o<n.length;o++){var a=n[o],l=t,i=e,r=i;t:for(;r!==null;){switch(r.tag){case 27:if(po(r.type)){Mt=r.stateNode,se=!1;break t}break;case 5:Mt=r.stateNode,se=!1;break t;case 3:case 4:Mt=r.stateNode.containerInfo,se=!0;break t}r=r.return}if(Mt===null)throw Error(L(160));R0(l,i,a),Mt=null,se=!1,l=a.alternate,l!==null&&(l.return=null),a.return=null}if(e.subtreeFlags&13886)for(e=e.child;e!==null;)L0(e,t),e=e.sibling}var Ze=null;function L0(t,e){var n=t.alternate,o=t.flags;switch(t.tag){case 0:case 11:case 14:case 15:ue(e,t),ce(t),o&4&&(so(3,t,t.return),_i(3,t),so(5,t,t.return));break;case 1:ue(e,t),ce(t),o&512&&(kt||n===null||en(n,n.return)),o&64&&Sn&&(t=t.updateQueue,t!==null&&(o=t.callbacks,o!==null&&(n=t.shared.hiddenCallbacks,t.shared.hiddenCallbacks=n===null?o:n.concat(o))));break;case 26:var a=Ze;if(ue(e,t),ce(t),o&512&&(kt||n===null||en(n,n.return)),o&4){var l=n!==null?n.memoizedState:null;if(o=t.memoizedState,n===null)if(o===null)if(t.stateNode===null){t:{o=t.type,n=t.memoizedProps,a=a.ownerDocument||a;e:switch(o){case"title":l=a.getElementsByTagName("title")[0],(!l||l[vi]||l[Kt]||l.namespaceURI==="http://www.w3.org/2000/svg"||l.hasAttribute("itemprop"))&&(l=a.createElement(o),a.head.insertBefore(l,a.querySelector("head > title"))),It(l,o,n),l[Kt]=t,Zt(l),o=l;break t;case"link":var i=Dg("link","href",a).get(o+(n.href||""));if(i){for(var r=0;r<i.length;r++)if(l=i[r],l.getAttribute("href")===(n.href==null||n.href===""?null:n.href)&&l.getAttribute("rel")===(n.rel==null?null:n.rel)&&l.getAttribute("title")===(n.title==null?null:n.title)&&l.getAttribute("crossorigin")===(n.crossOrigin==null?null:n.crossOrigin)){i.splice(r,1);break e}}l=a.createElement(o),It(l,o,n),a.head.appendChild(l);break;case"meta":if(i=Dg("meta","content",a).get(o+(n.content||""))){for(r=0;r<i.length;r++)if(l=i[r],l.getAttribute("content")===(n.content==null?null:""+n.content)&&l.getAttribute("name")===(n.name==null?null:n.name)&&l.getAttribute("property")===(n.property==null?null:n.property)&&l.getAttribute("http-equiv")===(n.httpEquiv==null?null:n.httpEquiv)&&l.getAttribute("charset")===(n.charSet==null?null:n.charSet)){i.splice(r,1);break e}}l=a.createElement(o),It(l,o,n),a.head.appendChild(l);break;default:throw Error(L(468,o))}l[Kt]=t,Zt(l),o=l}t.stateNode=o}else Hg(a,t.type,t.stateNode);else t.stateNode=Og(a,o,t.memoizedProps);else l!==o?(l===null?n.stateNode!==null&&(n=n.stateNode,n.parentNode.removeChild(n)):l.count--,o===null?Hg(a,t.type,t.stateNode):Og(a,o,t.memoizedProps)):o===null&&t.stateNode!==null&&_s(t,t.memoizedProps,n.memoizedProps)}break;case 27:ue(e,t),ce(t),o&512&&(kt||n===null||en(n,n.return)),n!==null&&o&4&&_s(t,t.memoizedProps,n.memoizedProps);break;case 5:if(ue(e,t),ce(t),o&512&&(kt||n===null||en(n,n.return)),t.flags&32){a=t.stateNode;try{Qa(a,"")}catch(y){pt(t,t.return,y)}}o&4&&t.stateNode!=null&&(a=t.memoizedProps,_s(t,a,n!==null?n.memoizedProps:a)),o&1024&&(Es=!0);break;case 6:if(ue(e,t),ce(t),o&4){if(t.stateNode===null)throw Error(L(162));o=t.memoizedProps,n=t.stateNode;try{n.nodeValue=o}catch(y){pt(t,t.return,y)}}break;case 3:if(Br=null,a=Ze,Ze=uu(e.containerInfo),ue(e,t),Ze=a,ce(t),o&4&&n!==null&&n.memoizedState.isDehydrated)try{Pa(e.containerInfo)}catch(y){pt(t,t.return,y)}Es&&(Es=!1,U0(t));break;case 4:o=Ze,Ze=uu(t.stateNode.containerInfo),ue(e,t),ce(t),Ze=o;break;case 12:ue(e,t),ce(t);break;case 31:ue(e,t),ce(t),o&4&&(o=t.updateQueue,o!==null&&(t.updateQueue=null,yr(t,o)));break;case 13:ue(e,t),ce(t),t.child.flags&8192&&t.memoizedState!==null!=(n!==null&&n.memoizedState!==null)&&(Eu=xe()),o&4&&(o=t.updateQueue,o!==null&&(t.updateQueue=null,yr(t,o)));break;case 22:a=t.memoizedState!==null;var u=n!==null&&n.memoizedState!==null,s=Sn,c=kt;if(Sn=s||a,kt=c||u,ue(e,t),kt=c,Sn=s,ce(t),o&8192)t:for(e=t.stateNode,e._visibility=a?e._visibility&-2:e._visibility|1,a&&(n===null||u||Sn||kt||Ho(t)),n=null,e=t;;){if(e.tag===5||e.tag===26){if(n===null){u=n=e;try{if(l=u.stateNode,a)i=l.style,typeof i.setProperty=="function"?i.setProperty("display","none","important"):i.display="none";else{r=u.stateNode;var d=u.memoizedProps.style,f=d!=null&&d.hasOwnProperty("display")?d.display:null;r.style.display=f==null||typeof f=="boolean"?"":(""+f).trim()}}catch(y){pt(u,u.return,y)}}}else if(e.tag===6){if(n===null){u=e;try{u.stateNode.nodeValue=a?"":u.memoizedProps}catch(y){pt(u,u.return,y)}}}else if(e.tag===18){if(n===null){u=e;try{var p=u.stateNode;a?Mg(p,!0):Mg(u.stateNode,!1)}catch(y){pt(u,u.return,y)}}}else if((e.tag!==22&&e.tag!==23||e.memoizedState===null||e===t)&&e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break t;for(;e.sibling===null;){if(e.return===null||e.return===t)break t;n===e&&(n=null),e=e.return}n===e&&(n=null),e.sibling.return=e.return,e=e.sibling}o&4&&(o=t.updateQueue,o!==null&&(n=o.retryQueue,n!==null&&(o.retryQueue=null,yr(t,n))));break;case 19:ue(e,t),ce(t),o&4&&(o=t.updateQueue,o!==null&&(t.updateQueue=null,yr(t,o)));break;case 30:break;case 21:break;default:ue(e,t),ce(t)}}function ce(t){var e=t.flags;if(e&2){try{for(var n,o=t.return;o!==null;){if(T0(o)){n=o;break}o=o.return}if(n==null)throw Error(L(160));switch(n.tag){case 27:var a=n.stateNode,l=ws(t);tu(t,l,a);break;case 5:var i=n.stateNode;n.flags&32&&(Qa(i,""),n.flags&=-33);var r=ws(t);tu(t,r,i);break;case 3:case 4:var u=n.stateNode.containerInfo,s=ws(t);df(t,s,u);break;default:throw Error(L(161))}}catch(c){pt(t,t.return,c)}t.flags&=-3}e&4096&&(t.flags&=-4097)}function U0(t){if(t.subtreeFlags&1024)for(t=t.child;t!==null;){var e=t;U0(e),e.tag===5&&e.flags&1024&&e.stateNode.reset(),t=t.sibling}}function vn(t,e){if(e.subtreeFlags&8772)for(e=e.child;e!==null;)D0(t,e.alternate,e),e=e.sibling}function Ho(t){for(t=t.child;t!==null;){var e=t;switch(e.tag){case 0:case 11:case 14:case 15:so(4,e,e.return),Ho(e);break;case 1:en(e,e.return);var n=e.stateNode;typeof n.componentWillUnmount=="function"&&A0(e,e.return,n),Ho(e);break;case 27:Pl(e.stateNode);case 26:case 5:en(e,e.return),Ho(e);break;case 22:e.memoizedState===null&&Ho(e);break;case 30:Ho(e);break;default:Ho(e)}t=t.sibling}}function bn(t,e,n){for(n=n&&(e.subtreeFlags&8772)!==0,e=e.child;e!==null;){var o=e.alternate,a=t,l=e,i=l.flags;switch(l.tag){case 0:case 11:case 15:bn(a,l,n),_i(4,l);break;case 1:if(bn(a,l,n),o=l,a=o.stateNode,typeof a.componentDidMount=="function")try{a.componentDidMount()}catch(s){pt(o,o.return,s)}if(o=l,a=o.updateQueue,a!==null){var r=o.stateNode;try{var u=a.shared.hiddenCallbacks;if(u!==null)for(a.shared.hiddenCallbacks=null,a=0;a<u.length;a++)Bm(u[a],r)}catch(s){pt(o,o.return,s)}}n&&i&64&&z0(l),Jl(l,l.return);break;case 27:O0(l);case 26:case 5:bn(a,l,n),n&&o===null&&i&4&&C0(l),Jl(l,l.return);break;case 12:bn(a,l,n);break;case 31:bn(a,l,n),n&&i&4&&B0(a,l);break;case 13:bn(a,l,n),n&&i&4&&k0(a,l);break;case 22:l.memoizedState===null&&bn(a,l,n),Jl(l,l.return);break;case 30:break;default:bn(a,l,n)}e=e.sibling}}function fd(t,e){var n=null;t!==null&&t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(n=t.memoizedState.cachePool.pool),t=null,e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(t=e.memoizedState.cachePool.pool),t!==n&&(t!=null&&t.refCount++,n!=null&&xi(n))}function dd(t,e){t=null,e.alternate!==null&&(t=e.alternate.memoizedState.cache),e=e.memoizedState.cache,e!==t&&(e.refCount++,t!=null&&xi(t))}function Xe(t,e,n,o){if(e.subtreeFlags&10256)for(e=e.child;e!==null;)Y0(t,e,n,o),e=e.sibling}function Y0(t,e,n,o){var a=e.flags;switch(e.tag){case 0:case 11:case 15:Xe(t,e,n,o),a&2048&&_i(9,e);break;case 1:Xe(t,e,n,o);break;case 3:Xe(t,e,n,o),a&2048&&(t=null,e.alternate!==null&&(t=e.alternate.memoizedState.cache),e=e.memoizedState.cache,e!==t&&(e.refCount++,t!=null&&xi(t)));break;case 12:if(a&2048){Xe(t,e,n,o),t=e.stateNode;try{var l=e.memoizedProps,i=l.id,r=l.onPostCommit;typeof r=="function"&&r(i,e.alternate===null?"mount":"update",t.passiveEffectDuration,-0)}catch(u){pt(e,e.return,u)}}else Xe(t,e,n,o);break;case 31:Xe(t,e,n,o);break;case 13:Xe(t,e,n,o);break;case 23:break;case 22:l=e.stateNode,i=e.alternate,e.memoizedState!==null?l._visibility&2?Xe(t,e,n,o):Il(t,e):l._visibility&2?Xe(t,e,n,o):(l._visibility|=2,_a(t,e,n,o,(e.subtreeFlags&10256)!==0||!1)),a&2048&&fd(i,e);break;case 24:Xe(t,e,n,o),a&2048&&dd(e.alternate,e);break;default:Xe(t,e,n,o)}}function _a(t,e,n,o,a){for(a=a&&((e.subtreeFlags&10256)!==0||!1),e=e.child;e!==null;){var l=t,i=e,r=n,u=o,s=i.flags;switch(i.tag){case 0:case 11:case 15:_a(l,i,r,u,a),_i(8,i);break;case 23:break;case 22:var c=i.stateNode;i.memoizedState!==null?c._visibility&2?_a(l,i,r,u,a):Il(l,i):(c._visibility|=2,_a(l,i,r,u,a)),a&&s&2048&&fd(i.alternate,i);break;case 24:_a(l,i,r,u,a),a&&s&2048&&dd(i.alternate,i);break;default:_a(l,i,r,u,a)}e=e.sibling}}function Il(t,e){if(e.subtreeFlags&10256)for(e=e.child;e!==null;){var n=t,o=e,a=o.flags;switch(o.tag){case 22:Il(n,o),a&2048&&fd(o.alternate,o);break;case 24:Il(n,o),a&2048&&dd(o.alternate,o);break;default:Il(n,o)}e=e.sibling}}var Vl=8192;function Sa(t,e,n){if(t.subtreeFlags&Vl)for(t=t.child;t!==null;)V0(t,e,n),t=t.sibling}function V0(t,e,n){switch(t.tag){case 26:Sa(t,e,n),t.flags&Vl&&t.memoizedState!==null&&GE(n,Ze,t.memoizedState,t.memoizedProps);break;case 5:Sa(t,e,n);break;case 3:case 4:var o=Ze;Ze=uu(t.stateNode.containerInfo),Sa(t,e,n),Ze=o;break;case 22:t.memoizedState===null&&(o=t.alternate,o!==null&&o.memoizedState!==null?(o=Vl,Vl=16777216,Sa(t,e,n),Vl=o):Sa(t,e,n));break;default:Sa(t,e,n)}}function q0(t){var e=t.alternate;if(e!==null&&(t=e.child,t!==null)){e.child=null;do e=t.sibling,t.sibling=null,t=e;while(t!==null)}}function Hl(t){var e=t.deletions;if((t.flags&16)!==0){if(e!==null)for(var n=0;n<e.length;n++){var o=e[n];Xt=o,Z0(o,t)}q0(t)}if(t.subtreeFlags&10256)for(t=t.child;t!==null;)X0(t),t=t.sibling}function X0(t){switch(t.tag){case 0:case 11:case 15:Hl(t),t.flags&2048&&so(9,t,t.return);break;case 3:Hl(t);break;case 12:Hl(t);break;case 22:var e=t.stateNode;t.memoizedState!==null&&e._visibility&2&&(t.return===null||t.return.tag!==13)?(e._visibility&=-3,Hr(t)):Hl(t);break;default:Hl(t)}}function Hr(t){var e=t.deletions;if((t.flags&16)!==0){if(e!==null)for(var n=0;n<e.length;n++){var o=e[n];Xt=o,Z0(o,t)}q0(t)}for(t=t.child;t!==null;){switch(e=t,e.tag){case 0:case 11:case 15:so(8,e,e.return),Hr(e);break;case 22:n=e.stateNode,n._visibility&2&&(n._visibility&=-3,Hr(e));break;default:Hr(e)}t=t.sibling}}function Z0(t,e){for(;Xt!==null;){var n=Xt;switch(n.tag){case 0:case 11:case 15:so(8,n,e);break;case 23:case 22:if(n.memoizedState!==null&&n.memoizedState.cachePool!==null){var o=n.memoizedState.cachePool.pool;o!=null&&o.refCount++}break;case 24:xi(n.memoizedState.cache)}if(o=n.child,o!==null)o.return=n,Xt=o;else t:for(n=t;Xt!==null;){o=Xt;var a=o.sibling,l=o.return;if(H0(o),o===n){Xt=null;break t}if(a!==null){a.return=l,Xt=a;break t}Xt=l}}}var rE={getCacheForType:function(t){var e=Jt(Lt),n=e.data.get(t);return n===void 0&&(n=t(),e.data.set(t,n)),n},cacheSignal:function(){return Jt(Lt).controller.signal}},uE=typeof WeakMap=="function"?WeakMap:Map,st=0,vt=null,lt=null,it=0,ht=0,me=null,In=!1,al=!1,hd=!1,Dn=0,Ct=0,fo=0,Uo=0,pd=0,be=0,Ja=0,Wl=null,fe=null,hf=!1,Eu=0,G0=0,eu=1/0,nu=null,oo=null,Yt=0,ao=null,Ia=null,zn=0,pf=0,gf=null,Q0=null,Fl=0,mf=null;function we(){return(st&2)!==0&&it!==0?it&-it:F.T!==null?md():tm()}function j0(){if(be===0)if((it&536870912)===0||rt){var t=rr;rr<<=1,(rr&3932160)===0&&(rr=262144),be=t}else be=536870912;return t=Ne.current,t!==null&&(t.flags|=32),be}function de(t,e,n){(t===vt&&(ht===2||ht===9)||t.cancelPendingCommit!==null)&&(Wa(t,0),Wn(t,it,be,!1)),yi(t,n),((st&2)===0||t!==vt)&&(t===vt&&((st&2)===0&&(Uo|=n),Ct===4&&Wn(t,it,be,!1)),an(t))}function K0(t,e,n){if((st&6)!==0)throw Error(L(327));var o=!n&&(e&127)===0&&(e&t.expiredLanes)===0||mi(t,e),a=o?fE(t,e):Ns(t,e,!0),l=o;do{if(a===0){al&&!o&&Wn(t,e,0,!1);break}else{if(n=t.current.alternate,l&&!cE(n)){a=Ns(t,e,!1),l=!1;continue}if(a===2){if(l=e,t.errorRecoveryDisabledLanes&l)var i=0;else i=t.pendingLanes&-536870913,i=i!==0?i:i&536870912?536870912:0;if(i!==0){e=i;t:{var r=t;a=Wl;var u=r.current.memoizedState.isDehydrated;if(u&&(Wa(r,i).flags|=256),i=Ns(r,i,!1),i!==2){if(hd&&!u){r.errorRecoveryDisabledLanes|=l,Uo|=l,a=4;break t}l=fe,fe=a,l!==null&&(fe===null?fe=l:fe.push.apply(fe,l))}a=i}if(l=!1,a!==2)continue}}if(a===1){Wa(t,0),Wn(t,e,0,!0);break}t:{switch(o=t,l=a,l){case 0:case 1:throw Error(L(345));case 4:if((e&4194048)!==e)break;case 6:Wn(o,e,be,!In);break t;case 2:fe=null;break;case 3:case 5:break;default:throw Error(L(329))}if((e&62914560)===e&&(a=Eu+300-xe(),10<a)){if(Wn(o,e,be,!In),hu(o,0,!0)!==0)break t;zn=e,o.timeoutHandle=hy(fg.bind(null,o,n,fe,nu,hf,e,be,Uo,Ja,In,l,"Throttled",-0,0),a);break t}fg(o,n,fe,nu,hf,e,be,Uo,Ja,In,l,null,-0,0)}}break}while(!0);an(t)}function fg(t,e,n,o,a,l,i,r,u,s,c,d,f,p){if(t.timeoutHandle=-1,d=e.subtreeFlags,d&8192||(d&16785408)===16785408){d={stylesheets:null,count:0,imgCount:0,imgBytes:0,suspenseyImages:[],waitingForImages:!0,waitingForViewTransition:!1,unsuspend:wn},V0(e,l,d);var y=(l&62914560)===l?Eu-xe():(l&4194048)===l?G0-xe():0;if(y=QE(d,y),y!==null){zn=l,t.cancelPendingCommit=y(hg.bind(null,t,e,l,n,o,a,i,r,u,c,d,null,f,p)),Wn(t,l,i,!s);return}}hg(t,e,l,n,o,a,i,r,u)}function cE(t){for(var e=t;;){var n=e.tag;if((n===0||n===11||n===15)&&e.flags&16384&&(n=e.updateQueue,n!==null&&(n=n.stores,n!==null)))for(var o=0;o<n.length;o++){var a=n[o],l=a.getSnapshot;a=a.value;try{if(!Ee(l(),a))return!1}catch{return!1}}if(n=e.child,e.subtreeFlags&16384&&n!==null)n.return=e,e=n;else{if(e===t)break;for(;e.sibling===null;){if(e.return===null||e.return===t)return!0;e=e.return}e.sibling.return=e.return,e=e.sibling}}return!0}function Wn(t,e,n,o){e&=~pd,e&=~Uo,t.suspendedLanes|=e,t.pingedLanes&=~e,o&&(t.warmLanes|=e),o=t.expirationTimes;for(var a=e;0<a;){var l=31-_e(a),i=1<<l;o[l]=-1,a&=~i}n!==0&&Wg(t,n,e)}function Nu(){return(st&6)===0?(wi(0,!1),!1):!0}function gd(){if(lt!==null){if(ht===0)var t=lt.return;else t=lt,En=$o=null,td(t),Va=null,ii=0,t=lt;for(;t!==null;)M0(t.alternate,t),t=t.return;lt=null}}function Wa(t,e){var n=t.timeoutHandle;n!==-1&&(t.timeoutHandle=-1,zE(n)),n=t.cancelPendingCommit,n!==null&&(t.cancelPendingCommit=null,n()),zn=0,gd(),vt=t,lt=n=Nn(t.current,null),it=e,ht=0,me=null,In=!1,al=mi(t,e),hd=!1,Ja=be=pd=Uo=fo=Ct=0,fe=Wl=null,hf=!1,(e&8)!==0&&(e|=e&32);var o=t.entangledLanes;if(o!==0)for(t=t.entanglements,o&=e;0<o;){var a=31-_e(o),l=1<<a;e|=t[a],o&=~l}return Dn=e,yu(),n}function $0(t,e){et=null,F.H=ui,e===ol||e===bu?(e=Zp(),ht=3):e===Kf?(e=Zp(),ht=4):ht=e===cd?8:e!==null&&typeof e=="object"&&typeof e.then=="function"?6:1,me=e,lt===null&&(Ct=1,Fr(t,He(e,t.current)))}function J0(){var t=Ne.current;return t===null?!0:(it&4194048)===it?Be===null:(it&62914560)===it||(it&536870912)!==0?t===Be:!1}function I0(){var t=F.H;return F.H=ui,t===null?ui:t}function W0(){var t=F.A;return F.A=rE,t}function ou(){Ct=4,In||(it&4194048)!==it&&Ne.current!==null||(al=!0),(fo&134217727)===0&&(Uo&134217727)===0||vt===null||Wn(vt,it,be,!1)}function Ns(t,e,n){var o=st;st|=2;var a=I0(),l=W0();(vt!==t||it!==e)&&(nu=null,Wa(t,e)),e=!1;var i=Ct;t:do try{if(ht!==0&&lt!==null){var r=lt,u=me;switch(ht){case 8:gd(),i=6;break t;case 3:case 2:case 9:case 6:Ne.current===null&&(e=!0);var s=ht;if(ht=0,me=null,Ba(t,r,u,s),n&&al){i=0;break t}break;default:s=ht,ht=0,me=null,Ba(t,r,u,s)}}sE(),i=Ct;break}catch(c){$0(t,c)}while(!0);return e&&t.shellSuspendCounter++,En=$o=null,st=o,F.H=a,F.A=l,lt===null&&(vt=null,it=0,yu()),i}function sE(){for(;lt!==null;)F0(lt)}function fE(t,e){var n=st;st|=2;var o=I0(),a=W0();vt!==t||it!==e?(nu=null,eu=xe()+500,Wa(t,e)):al=mi(t,e);t:do try{if(ht!==0&&lt!==null){e=lt;var l=me;e:switch(ht){case 1:ht=0,me=null,Ba(t,e,l,1);break;case 2:case 9:if(Xp(l)){ht=0,me=null,dg(e);break}e=function(){ht!==2&&ht!==9||vt!==t||(ht=7),an(t)},l.then(e,e);break t;case 3:ht=7;break t;case 4:ht=5;break t;case 7:Xp(l)?(ht=0,me=null,dg(e)):(ht=0,me=null,Ba(t,e,l,7));break;case 5:var i=null;switch(lt.tag){case 26:i=lt.memoizedState;case 5:case 27:var r=lt;if(i?vy(i):r.stateNode.complete){ht=0,me=null;var u=r.sibling;if(u!==null)lt=u;else{var s=r.return;s!==null?(lt=s,Mu(s)):lt=null}break e}}ht=0,me=null,Ba(t,e,l,5);break;case 6:ht=0,me=null,Ba(t,e,l,6);break;case 8:gd(),Ct=6;break t;default:throw Error(L(462))}}dE();break}catch(c){$0(t,c)}while(!0);return En=$o=null,F.H=o,F.A=a,st=n,lt!==null?0:(vt=null,it=0,yu(),Ct)}function dE(){for(;lt!==null&&!B_();)F0(lt)}function F0(t){var e=N0(t.alternate,t,Dn);t.memoizedProps=t.pendingProps,e===null?Mu(t):lt=e}function dg(t){var e=t,n=e.alternate;switch(e.tag){case 15:case 0:e=lg(n,e,e.pendingProps,e.type,void 0,it);break;case 11:e=lg(n,e,e.pendingProps,e.type.render,e.ref,it);break;case 5:td(e);default:M0(n,e),e=lt=Mm(e,Dn),e=N0(n,e,Dn)}t.memoizedProps=t.pendingProps,e===null?Mu(t):lt=e}function Ba(t,e,n,o){En=$o=null,td(e),Va=null,ii=0;var a=e.return;try{if(tE(t,a,e,n,it)){Ct=1,Fr(t,He(n,t.current)),lt=null;return}}catch(l){if(a!==null)throw lt=a,l;Ct=1,Fr(t,He(n,t.current)),lt=null;return}e.flags&32768?(rt||o===1?t=!0:al||(it&536870912)!==0?t=!1:(In=t=!0,(o===2||o===9||o===3||o===6)&&(o=Ne.current,o!==null&&o.tag===13&&(o.flags|=16384))),P0(e,t)):Mu(e)}function Mu(t){var e=t;do{if((e.flags&32768)!==0){P0(e,In);return}t=e.return;var n=oE(e.alternate,e,Dn);if(n!==null){lt=n;return}if(e=e.sibling,e!==null){lt=e;return}lt=e=t}while(e!==null);Ct===0&&(Ct=5)}function P0(t,e){do{var n=aE(t.alternate,t);if(n!==null){n.flags&=32767,lt=n;return}if(n=t.return,n!==null&&(n.flags|=32768,n.subtreeFlags=0,n.deletions=null),!e&&(t=t.sibling,t!==null)){lt=t;return}lt=t=n}while(t!==null);Ct=6,lt=null}function hg(t,e,n,o,a,l,i,r,u){t.cancelPendingCommit=null;do zu();while(Yt!==0);if((st&6)!==0)throw Error(L(327));if(e!==null){if(e===t.current)throw Error(L(177));if(l=e.lanes|e.childLanes,l|=Vf,Q_(t,n,l,i,r,u),t===vt&&(lt=vt=null,it=0),Ia=e,ao=t,zn=n,pf=l,gf=a,Q0=o,(e.subtreeFlags&10256)!==0||(e.flags&10256)!==0?(t.callbackNode=null,t.callbackPriority=0,mE(qr,function(){return ay(),null})):(t.callbackNode=null,t.callbackPriority=0),o=(e.flags&13878)!==0,(e.subtreeFlags&13878)!==0||o){o=F.T,F.T=null,a=ft.p,ft.p=2,i=st,st|=4;try{lE(t,e,n)}finally{st=i,ft.p=a,F.T=o}}Yt=1,ty(),ey(),ny()}}function ty(){if(Yt===1){Yt=0;var t=ao,e=Ia,n=(e.flags&13878)!==0;if((e.subtreeFlags&13878)!==0||n){n=F.T,F.T=null;var o=ft.p;ft.p=2;var a=st;st|=4;try{L0(e,t);var l=xf,i=vm(t.containerInfo),r=l.focusedElem,u=l.selectionRange;if(i!==r&&r&&r.ownerDocument&&ym(r.ownerDocument.documentElement,r)){if(u!==null&&Yf(r)){var s=u.start,c=u.end;if(c===void 0&&(c=s),"selectionStart"in r)r.selectionStart=s,r.selectionEnd=Math.min(c,r.value.length);else{var d=r.ownerDocument||document,f=d&&d.defaultView||window;if(f.getSelection){var p=f.getSelection(),y=r.textContent.length,b=Math.min(u.start,y),x=u.end===void 0?b:Math.min(u.end,y);!p.extend&&b>x&&(i=x,x=b,b=i);var g=Bp(r,b),m=Bp(r,x);if(g&&m&&(p.rangeCount!==1||p.anchorNode!==g.node||p.anchorOffset!==g.offset||p.focusNode!==m.node||p.focusOffset!==m.offset)){var h=d.createRange();h.setStart(g.node,g.offset),p.removeAllRanges(),b>x?(p.addRange(h),p.extend(m.node,m.offset)):(h.setEnd(m.node,m.offset),p.addRange(h))}}}}for(d=[],p=r;p=p.parentNode;)p.nodeType===1&&d.push({element:p,left:p.scrollLeft,top:p.scrollTop});for(typeof r.focus=="function"&&r.focus(),r=0;r<d.length;r++){var v=d[r];v.element.scrollLeft=v.left,v.element.scrollTop=v.top}}fu=!!bf,xf=bf=null}finally{st=a,ft.p=o,F.T=n}}t.current=e,Yt=2}}function ey(){if(Yt===2){Yt=0;var t=ao,e=Ia,n=(e.flags&8772)!==0;if((e.subtreeFlags&8772)!==0||n){n=F.T,F.T=null;var o=ft.p;ft.p=2;var a=st;st|=4;try{D0(t,e.alternate,e)}finally{st=a,ft.p=o,F.T=n}}Yt=3}}function ny(){if(Yt===4||Yt===3){Yt=0,k_();var t=ao,e=Ia,n=zn,o=Q0;(e.subtreeFlags&10256)!==0||(e.flags&10256)!==0?Yt=5:(Yt=0,Ia=ao=null,oy(t,t.pendingLanes));var a=t.pendingLanes;if(a===0&&(oo=null),Df(n),e=e.stateNode,Se&&typeof Se.onCommitFiberRoot=="function")try{Se.onCommitFiberRoot(gi,e,void 0,(e.current.flags&128)===128)}catch{}if(o!==null){e=F.T,a=ft.p,ft.p=2,F.T=null;try{for(var l=t.onRecoverableError,i=0;i<o.length;i++){var r=o[i];l(r.value,{componentStack:r.stack})}}finally{F.T=e,ft.p=a}}(zn&3)!==0&&zu(),an(t),a=t.pendingLanes,(n&261930)!==0&&(a&42)!==0?t===mf?Fl++:(Fl=0,mf=t):Fl=0,wi(0,!1)}}function oy(t,e){(t.pooledCacheLanes&=e)===0&&(e=t.pooledCache,e!=null&&(t.pooledCache=null,xi(e)))}function zu(){return ty(),ey(),ny(),ay()}function ay(){if(Yt!==5)return!1;var t=ao,e=pf;pf=0;var n=Df(zn),o=F.T,a=ft.p;try{ft.p=32>n?32:n,F.T=null,n=gf,gf=null;var l=ao,i=zn;if(Yt=0,Ia=ao=null,zn=0,(st&6)!==0)throw Error(L(331));var r=st;if(st|=4,X0(l.current),Y0(l,l.current,i,n),st=r,wi(0,!1),Se&&typeof Se.onPostCommitFiberRoot=="function")try{Se.onPostCommitFiberRoot(gi,l)}catch{}return!0}finally{ft.p=a,F.T=o,oy(t,e)}}function pg(t,e,n){e=He(n,e),e=cf(t.stateNode,e,2),t=no(t,e,2),t!==null&&(yi(t,2),an(t))}function pt(t,e,n){if(t.tag===3)pg(t,t,n);else for(;e!==null;){if(e.tag===3){pg(e,t,n);break}else if(e.tag===1){var o=e.stateNode;if(typeof e.type.getDerivedStateFromError=="function"||typeof o.componentDidCatch=="function"&&(oo===null||!oo.has(o))){t=He(n,t),n=b0(2),o=no(e,n,2),o!==null&&(x0(n,o,e,t),yi(o,2),an(o));break}}e=e.return}}function Ms(t,e,n){var o=t.pingCache;if(o===null){o=t.pingCache=new uE;var a=new Set;o.set(e,a)}else a=o.get(e),a===void 0&&(a=new Set,o.set(e,a));a.has(n)||(hd=!0,a.add(n),t=hE.bind(null,t,e,n),e.then(t,t))}function hE(t,e,n){var o=t.pingCache;o!==null&&o.delete(e),t.pingedLanes|=t.suspendedLanes&n,t.warmLanes&=~n,vt===t&&(it&n)===n&&(Ct===4||Ct===3&&(it&62914560)===it&&300>xe()-Eu?(st&2)===0&&Wa(t,0):pd|=n,Ja===it&&(Ja=0)),an(t)}function ly(t,e){e===0&&(e=Ig()),t=Ko(t,e),t!==null&&(yi(t,e),an(t))}function pE(t){var e=t.memoizedState,n=0;e!==null&&(n=e.retryLane),ly(t,n)}function gE(t,e){var n=0;switch(t.tag){case 31:case 13:var o=t.stateNode,a=t.memoizedState;a!==null&&(n=a.retryLane);break;case 19:o=t.stateNode;break;case 22:o=t.stateNode._retryCache;break;default:throw Error(L(314))}o!==null&&o.delete(e),ly(t,n)}function mE(t,e){return Tf(t,e)}var au=null,wa=null,yf=!1,lu=!1,zs=!1,Fn=0;function an(t){t!==wa&&t.next===null&&(wa===null?au=wa=t:wa=wa.next=t),lu=!0,yf||(yf=!0,vE())}function wi(t,e){if(!zs&&lu){zs=!0;do for(var n=!1,o=au;o!==null;){if(!e)if(t!==0){var a=o.pendingLanes;if(a===0)var l=0;else{var i=o.suspendedLanes,r=o.pingedLanes;l=(1<<31-_e(42|t)+1)-1,l&=a&~(i&~r),l=l&201326741?l&201326741|1:l?l|2:0}l!==0&&(n=!0,gg(o,l))}else l=it,l=hu(o,o===vt?l:0,o.cancelPendingCommit!==null||o.timeoutHandle!==-1),(l&3)===0||mi(o,l)||(n=!0,gg(o,l));o=o.next}while(n);zs=!1}}function yE(){iy()}function iy(){lu=yf=!1;var t=0;Fn!==0&&ME()&&(t=Fn);for(var e=xe(),n=null,o=au;o!==null;){var a=o.next,l=ry(o,e);l===0?(o.next=null,n===null?au=a:n.next=a,a===null&&(wa=n)):(n=o,(t!==0||(l&3)!==0)&&(lu=!0)),o=a}Yt!==0&&Yt!==5||wi(t,!1),Fn!==0&&(Fn=0)}function ry(t,e){for(var n=t.suspendedLanes,o=t.pingedLanes,a=t.expirationTimes,l=t.pendingLanes&-62914561;0<l;){var i=31-_e(l),r=1<<i,u=a[i];u===-1?((r&n)===0||(r&o)!==0)&&(a[i]=G_(r,e)):u<=e&&(t.expiredLanes|=r),l&=~r}if(e=vt,n=it,n=hu(t,t===e?n:0,t.cancelPendingCommit!==null||t.timeoutHandle!==-1),o=t.callbackNode,n===0||t===e&&(ht===2||ht===9)||t.cancelPendingCommit!==null)return o!==null&&o!==null&&ns(o),t.callbackNode=null,t.callbackPriority=0;if((n&3)===0||mi(t,n)){if(e=n&-n,e===t.callbackPriority)return e;switch(o!==null&&ns(o),Df(n)){case 2:case 8:n=$g;break;case 32:n=qr;break;case 268435456:n=Jg;break;default:n=qr}return o=uy.bind(null,t),n=Tf(n,o),t.callbackPriority=e,t.callbackNode=n,e}return o!==null&&o!==null&&ns(o),t.callbackPriority=2,t.callbackNode=null,2}function uy(t,e){if(Yt!==0&&Yt!==5)return t.callbackNode=null,t.callbackPriority=0,null;var n=t.callbackNode;if(zu()&&t.callbackNode!==n)return null;var o=it;return o=hu(t,t===vt?o:0,t.cancelPendingCommit!==null||t.timeoutHandle!==-1),o===0?null:(K0(t,o,e),ry(t,xe()),t.callbackNode!=null&&t.callbackNode===n?uy.bind(null,t):null)}function gg(t,e){if(zu())return null;K0(t,e,!0)}function vE(){AE(function(){(st&6)!==0?Tf(Kg,yE):iy()})}function md(){if(Fn===0){var t=ja;t===0&&(t=ir,ir<<=1,(ir&261888)===0&&(ir=256)),Fn=t}return Fn}function mg(t){return t==null||typeof t=="symbol"||typeof t=="boolean"?null:typeof t=="function"?t:Er(""+t)}function yg(t,e){var n=e.ownerDocument.createElement("input");return n.name=e.name,n.value=e.value,t.id&&n.setAttribute("form",t.id),e.parentNode.insertBefore(n,e),t=new FormData(t),n.parentNode.removeChild(n),t}function bE(t,e,n,o,a){if(e==="submit"&&n&&n.stateNode===a){var l=mg((a[he]||null).action),i=o.submitter;i&&(e=(e=i[he]||null)?mg(e.formAction):i.getAttribute("formAction"),e!==null&&(l=e,i=null));var r=new pu("action","action",null,o,a);t.push({event:r,listeners:[{instance:null,listener:function(){if(o.defaultPrevented){if(Fn!==0){var u=i?yg(a,i):new FormData(a);rf(n,{pending:!0,data:u,method:a.method,action:l},null,u)}}else typeof l=="function"&&(r.preventDefault(),u=i?yg(a,i):new FormData(a),rf(n,{pending:!0,data:u,method:a.method,action:l},l,u))},currentTarget:a}]})}}for(vr=0;vr<$s.length;vr++)br=$s[vr],vg=br.toLowerCase(),bg=br[0].toUpperCase()+br.slice(1),Ge(vg,"on"+bg);var br,vg,bg,vr;Ge(xm,"onAnimationEnd");Ge(Sm,"onAnimationIteration");Ge(_m,"onAnimationStart");Ge("dblclick","onDoubleClick");Ge("focusin","onFocus");Ge("focusout","onBlur");Ge(Lw,"onTransitionRun");Ge(Uw,"onTransitionStart");Ge(Yw,"onTransitionCancel");Ge(wm,"onTransitionEnd");Ga("onMouseEnter",["mouseout","mouseover"]);Ga("onMouseLeave",["mouseout","mouseover"]);Ga("onPointerEnter",["pointerout","pointerover"]);Ga("onPointerLeave",["pointerout","pointerover"]);Go("onChange","change click focusin focusout input keydown keyup selectionchange".split(" "));Go("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" "));Go("onBeforeInput",["compositionend","keypress","textInput","paste"]);Go("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" "));Go("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" "));Go("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var ci="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(" "),xE=new Set("beforetoggle cancel close invalid load scroll scrollend toggle".split(" ").concat(ci));function cy(t,e){e=(e&4)!==0;for(var n=0;n<t.length;n++){var o=t[n],a=o.event;o=o.listeners;t:{var l=void 0;if(e)for(var i=o.length-1;0<=i;i--){var r=o[i],u=r.instance,s=r.currentTarget;if(r=r.listener,u!==l&&a.isPropagationStopped())break t;l=r,a.currentTarget=s;try{l(a)}catch(c){Zr(c)}a.currentTarget=null,l=u}else for(i=0;i<o.length;i++){if(r=o[i],u=r.instance,s=r.currentTarget,r=r.listener,u!==l&&a.isPropagationStopped())break t;l=r,a.currentTarget=s;try{l(a)}catch(c){Zr(c)}a.currentTarget=null,l=u}}}}function at(t,e){var n=e[Vs];n===void 0&&(n=e[Vs]=new Set);var o=t+"__bubble";n.has(o)||(sy(e,t,2,!1),n.add(o))}function As(t,e,n){var o=0;e&&(o|=4),sy(n,t,o,e)}var xr="_reactListening"+Math.random().toString(36).slice(2);function yd(t){if(!t[xr]){t[xr]=!0,em.forEach(function(n){n!=="selectionchange"&&(xE.has(n)||As(n,!1,t),As(n,!0,t))});var e=t.nodeType===9?t:t.ownerDocument;e===null||e[xr]||(e[xr]=!0,As("selectionchange",!1,e))}}function sy(t,e,n,o){switch(wy(e)){case 2:var a=$E;break;case 8:a=JE;break;default:a=Sd}n=a.bind(null,e,n,t),a=void 0,!Qs||e!=="touchstart"&&e!=="touchmove"&&e!=="wheel"||(a=!0),o?a!==void 0?t.addEventListener(e,n,{capture:!0,passive:a}):t.addEventListener(e,n,!0):a!==void 0?t.addEventListener(e,n,{passive:a}):t.addEventListener(e,n,!1)}function Cs(t,e,n,o,a){var l=o;if((e&1)===0&&(e&2)===0&&o!==null)t:for(;;){if(o===null)return;var i=o.tag;if(i===3||i===4){var r=o.stateNode.containerInfo;if(r===a)break;if(i===4)for(i=o.return;i!==null;){var u=i.tag;if((u===3||u===4)&&i.stateNode.containerInfo===a)return;i=i.return}for(;r!==null;){if(i=Ma(r),i===null)return;if(u=i.tag,u===5||u===6||u===26||u===27){o=l=i;continue t}r=r.parentNode}}o=o.return}cm(function(){var s=l,c=Bf(n),d=[];t:{var f=Em.get(t);if(f!==void 0){var p=pu,y=t;switch(t){case"keypress":if(Mr(n)===0)break t;case"keydown":case"keyup":p=gw;break;case"focusin":y="focus",p=rs;break;case"focusout":y="blur",p=rs;break;case"beforeblur":case"afterblur":p=rs;break;case"click":if(n.button===2)break t;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":p=Mp;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":p=ow;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":p=vw;break;case xm:case Sm:case _m:p=iw;break;case wm:p=xw;break;case"scroll":case"scrollend":p=ew;break;case"wheel":p=_w;break;case"copy":case"cut":case"paste":p=uw;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":p=Ap;break;case"toggle":case"beforetoggle":p=Ew}var b=(e&4)!==0,x=!b&&(t==="scroll"||t==="scrollend"),g=b?f!==null?f+"Capture":null:f;b=[];for(var m=s,h;m!==null;){var v=m;if(h=v.stateNode,v=v.tag,v!==5&&v!==26&&v!==27||h===null||g===null||(v=ei(m,g),v!=null&&b.push(si(m,v,h))),x)break;m=m.return}0<b.length&&(f=new p(f,y,null,n,c),d.push({event:f,listeners:b}))}}if((e&7)===0){t:{if(f=t==="mouseover"||t==="pointerover",p=t==="mouseout"||t==="pointerout",f&&n!==Gs&&(y=n.relatedTarget||n.fromElement)&&(Ma(y)||y[tl]))break t;if((p||f)&&(f=c.window===c?c:(f=c.ownerDocument)?f.defaultView||f.parentWindow:window,p?(y=n.relatedTarget||n.toElement,p=s,y=y?Ma(y):null,y!==null&&(x=pi(y),b=y.tag,y!==x||b!==5&&b!==27&&b!==6)&&(y=null)):(p=null,y=s),p!==y)){if(b=Mp,v="onMouseLeave",g="onMouseEnter",m="mouse",(t==="pointerout"||t==="pointerover")&&(b=Ap,v="onPointerLeave",g="onPointerEnter",m="pointer"),x=p==null?f:Ul(p),h=y==null?f:Ul(y),f=new b(v,m+"leave",p,n,c),f.target=x,f.relatedTarget=h,v=null,Ma(c)===s&&(b=new b(g,m+"enter",y,n,c),b.target=h,b.relatedTarget=x,v=b),x=v,p&&y)e:{for(b=SE,g=p,m=y,h=0,v=g;v;v=b(v))h++;v=0;for(var _=m;_;_=b(_))v++;for(;0<h-v;)g=b(g),h--;for(;0<v-h;)m=b(m),v--;for(;h--;){if(g===m||m!==null&&g===m.alternate){b=g;break e}g=b(g),m=b(m)}b=null}else b=null;p!==null&&xg(d,f,p,b,!1),y!==null&&x!==null&&xg(d,x,y,b,!0)}}t:{if(f=s?Ul(s):window,p=f.nodeName&&f.nodeName.toLowerCase(),p==="select"||p==="input"&&f.type==="file")var E=Dp;else if(Op(f))if(gm)E=Rw;else{E=Dw;var w=Ow}else p=f.nodeName,!p||p.toLowerCase()!=="input"||f.type!=="checkbox"&&f.type!=="radio"?s&&Rf(s.elementType)&&(E=Dp):E=Hw;if(E&&(E=E(t,s))){pm(d,E,n,c);break t}w&&w(t,f,s),t==="focusout"&&s&&f.type==="number"&&s.memoizedProps.value!=null&&Zs(f,"number",f.value)}switch(w=s?Ul(s):window,t){case"focusin":(Op(w)||w.contentEditable==="true")&&(Ca=w,js=s,Zl=null);break;case"focusout":Zl=js=Ca=null;break;case"mousedown":Ks=!0;break;case"contextmenu":case"mouseup":case"dragend":Ks=!1,kp(d,n,c);break;case"selectionchange":if(kw)break;case"keydown":case"keyup":kp(d,n,c)}var N;if(Uf)t:{switch(t){case"compositionstart":var M="onCompositionStart";break t;case"compositionend":M="onCompositionEnd";break t;case"compositionupdate":M="onCompositionUpdate";break t}M=void 0}else Aa?dm(t,n)&&(M="onCompositionEnd"):t==="keydown"&&n.keyCode===229&&(M="onCompositionStart");M&&(fm&&n.locale!=="ko"&&(Aa||M!=="onCompositionStart"?M==="onCompositionEnd"&&Aa&&(N=sm()):(Jn=c,kf="value"in Jn?Jn.value:Jn.textContent,Aa=!0)),w=iu(s,M),0<w.length&&(M=new zp(M,t,null,n,c),d.push({event:M,listeners:w}),N?M.data=N:(N=hm(n),N!==null&&(M.data=N)))),(N=Mw?zw(t,n):Aw(t,n))&&(M=iu(s,"onBeforeInput"),0<M.length&&(w=new zp("onBeforeInput","beforeinput",null,n,c),d.push({event:w,listeners:M}),w.data=N)),bE(d,t,s,n,c)}cy(d,e)})}function si(t,e,n){return{instance:t,listener:e,currentTarget:n}}function iu(t,e){for(var n=e+"Capture",o=[];t!==null;){var a=t,l=a.stateNode;if(a=a.tag,a!==5&&a!==26&&a!==27||l===null||(a=ei(t,n),a!=null&&o.unshift(si(t,a,l)),a=ei(t,e),a!=null&&o.push(si(t,a,l))),t.tag===3)return o;t=t.return}return[]}function SE(t){if(t===null)return null;do t=t.return;while(t&&t.tag!==5&&t.tag!==27);return t||null}function xg(t,e,n,o,a){for(var l=e._reactName,i=[];n!==null&&n!==o;){var r=n,u=r.alternate,s=r.stateNode;if(r=r.tag,u!==null&&u===o)break;r!==5&&r!==26&&r!==27||s===null||(u=s,a?(s=ei(n,l),s!=null&&i.unshift(si(n,s,u))):a||(s=ei(n,l),s!=null&&i.push(si(n,s,u)))),n=n.return}i.length!==0&&t.push({event:e,listeners:i})}var _E=/\r\n?/g,wE=/\u0000|\uFFFD/g;function Sg(t){return(typeof t=="string"?t:""+t).replace(_E,`
9
- `).replace(wE,"")}function fy(t,e){return e=Sg(e),Sg(t)===e}function mt(t,e,n,o,a,l){switch(n){case"children":typeof o=="string"?e==="body"||e==="textarea"&&o===""||Qa(t,o):(typeof o=="number"||typeof o=="bigint")&&e!=="body"&&Qa(t,""+o);break;case"className":cr(t,"class",o);break;case"tabIndex":cr(t,"tabindex",o);break;case"dir":case"role":case"viewBox":case"width":case"height":cr(t,n,o);break;case"style":um(t,o,l);break;case"data":if(e!=="object"){cr(t,"data",o);break}case"src":case"href":if(o===""&&(e!=="a"||n!=="href")){t.removeAttribute(n);break}if(o==null||typeof o=="function"||typeof o=="symbol"||typeof o=="boolean"){t.removeAttribute(n);break}o=Er(""+o),t.setAttribute(n,o);break;case"action":case"formAction":if(typeof o=="function"){t.setAttribute(n,"javascript:throw new Error('A React form was unexpectedly submitted. If you called form.submit() manually, consider using form.requestSubmit() instead. If you\\'re trying to use event.stopPropagation() in a submit event handler, consider also calling event.preventDefault().')");break}else typeof l=="function"&&(n==="formAction"?(e!=="input"&&mt(t,e,"name",a.name,a,null),mt(t,e,"formEncType",a.formEncType,a,null),mt(t,e,"formMethod",a.formMethod,a,null),mt(t,e,"formTarget",a.formTarget,a,null)):(mt(t,e,"encType",a.encType,a,null),mt(t,e,"method",a.method,a,null),mt(t,e,"target",a.target,a,null)));if(o==null||typeof o=="symbol"||typeof o=="boolean"){t.removeAttribute(n);break}o=Er(""+o),t.setAttribute(n,o);break;case"onClick":o!=null&&(t.onclick=wn);break;case"onScroll":o!=null&&at("scroll",t);break;case"onScrollEnd":o!=null&&at("scrollend",t);break;case"dangerouslySetInnerHTML":if(o!=null){if(typeof o!="object"||!("__html"in o))throw Error(L(61));if(n=o.__html,n!=null){if(a.children!=null)throw Error(L(60));t.innerHTML=n}}break;case"multiple":t.multiple=o&&typeof o!="function"&&typeof o!="symbol";break;case"muted":t.muted=o&&typeof o!="function"&&typeof o!="symbol";break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":break;case"autoFocus":break;case"xlinkHref":if(o==null||typeof o=="function"||typeof o=="boolean"||typeof o=="symbol"){t.removeAttribute("xlink:href");break}n=Er(""+o),t.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",n);break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":o!=null&&typeof o!="function"&&typeof o!="symbol"?t.setAttribute(n,""+o):t.removeAttribute(n);break;case"inert":case"allowFullScreen":case"async":case"autoPlay":case"controls":case"default":case"defer":case"disabled":case"disablePictureInPicture":case"disableRemotePlayback":case"formNoValidate":case"hidden":case"loop":case"noModule":case"noValidate":case"open":case"playsInline":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"itemScope":o&&typeof o!="function"&&typeof o!="symbol"?t.setAttribute(n,""):t.removeAttribute(n);break;case"capture":case"download":o===!0?t.setAttribute(n,""):o!==!1&&o!=null&&typeof o!="function"&&typeof o!="symbol"?t.setAttribute(n,o):t.removeAttribute(n);break;case"cols":case"rows":case"size":case"span":o!=null&&typeof o!="function"&&typeof o!="symbol"&&!isNaN(o)&&1<=o?t.setAttribute(n,o):t.removeAttribute(n);break;case"rowSpan":case"start":o==null||typeof o=="function"||typeof o=="symbol"||isNaN(o)?t.removeAttribute(n):t.setAttribute(n,o);break;case"popover":at("beforetoggle",t),at("toggle",t),wr(t,"popover",o);break;case"xlinkActuate":gn(t,"http://www.w3.org/1999/xlink","xlink:actuate",o);break;case"xlinkArcrole":gn(t,"http://www.w3.org/1999/xlink","xlink:arcrole",o);break;case"xlinkRole":gn(t,"http://www.w3.org/1999/xlink","xlink:role",o);break;case"xlinkShow":gn(t,"http://www.w3.org/1999/xlink","xlink:show",o);break;case"xlinkTitle":gn(t,"http://www.w3.org/1999/xlink","xlink:title",o);break;case"xlinkType":gn(t,"http://www.w3.org/1999/xlink","xlink:type",o);break;case"xmlBase":gn(t,"http://www.w3.org/XML/1998/namespace","xml:base",o);break;case"xmlLang":gn(t,"http://www.w3.org/XML/1998/namespace","xml:lang",o);break;case"xmlSpace":gn(t,"http://www.w3.org/XML/1998/namespace","xml:space",o);break;case"is":wr(t,"is",o);break;case"innerText":case"textContent":break;default:(!(2<n.length)||n[0]!=="o"&&n[0]!=="O"||n[1]!=="n"&&n[1]!=="N")&&(n=P_.get(n)||n,wr(t,n,o))}}function vf(t,e,n,o,a,l){switch(n){case"style":um(t,o,l);break;case"dangerouslySetInnerHTML":if(o!=null){if(typeof o!="object"||!("__html"in o))throw Error(L(61));if(n=o.__html,n!=null){if(a.children!=null)throw Error(L(60));t.innerHTML=n}}break;case"children":typeof o=="string"?Qa(t,o):(typeof o=="number"||typeof o=="bigint")&&Qa(t,""+o);break;case"onScroll":o!=null&&at("scroll",t);break;case"onScrollEnd":o!=null&&at("scrollend",t);break;case"onClick":o!=null&&(t.onclick=wn);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"innerHTML":case"ref":break;case"innerText":case"textContent":break;default:if(!nm.hasOwnProperty(n))t:{if(n[0]==="o"&&n[1]==="n"&&(a=n.endsWith("Capture"),e=n.slice(2,a?n.length-7:void 0),l=t[he]||null,l=l!=null?l[n]:null,typeof l=="function"&&t.removeEventListener(e,l,a),typeof o=="function")){typeof l!="function"&&l!==null&&(n in t?t[n]=null:t.hasAttribute(n)&&t.removeAttribute(n)),t.addEventListener(e,o,a);break t}n in t?t[n]=o:o===!0?t.setAttribute(n,""):wr(t,n,o)}}}function It(t,e,n){switch(e){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"img":at("error",t),at("load",t);var o=!1,a=!1,l;for(l in n)if(n.hasOwnProperty(l)){var i=n[l];if(i!=null)switch(l){case"src":o=!0;break;case"srcSet":a=!0;break;case"children":case"dangerouslySetInnerHTML":throw Error(L(137,e));default:mt(t,e,l,i,n,null)}}a&&mt(t,e,"srcSet",n.srcSet,n,null),o&&mt(t,e,"src",n.src,n,null);return;case"input":at("invalid",t);var r=l=i=a=null,u=null,s=null;for(o in n)if(n.hasOwnProperty(o)){var c=n[o];if(c!=null)switch(o){case"name":a=c;break;case"type":i=c;break;case"checked":u=c;break;case"defaultChecked":s=c;break;case"value":l=c;break;case"defaultValue":r=c;break;case"children":case"dangerouslySetInnerHTML":if(c!=null)throw Error(L(137,e));break;default:mt(t,e,o,c,n,null)}}lm(t,l,r,u,s,i,a,!1);return;case"select":at("invalid",t),o=i=l=null;for(a in n)if(n.hasOwnProperty(a)&&(r=n[a],r!=null))switch(a){case"value":l=r;break;case"defaultValue":i=r;break;case"multiple":o=r;default:mt(t,e,a,r,n,null)}e=l,n=i,t.multiple=!!o,e!=null?La(t,!!o,e,!1):n!=null&&La(t,!!o,n,!0);return;case"textarea":at("invalid",t),l=a=o=null;for(i in n)if(n.hasOwnProperty(i)&&(r=n[i],r!=null))switch(i){case"value":o=r;break;case"defaultValue":a=r;break;case"children":l=r;break;case"dangerouslySetInnerHTML":if(r!=null)throw Error(L(91));break;default:mt(t,e,i,r,n,null)}rm(t,o,a,l);return;case"option":for(u in n)n.hasOwnProperty(u)&&(o=n[u],o!=null)&&(u==="selected"?t.selected=o&&typeof o!="function"&&typeof o!="symbol":mt(t,e,u,o,n,null));return;case"dialog":at("beforetoggle",t),at("toggle",t),at("cancel",t),at("close",t);break;case"iframe":case"object":at("load",t);break;case"video":case"audio":for(o=0;o<ci.length;o++)at(ci[o],t);break;case"image":at("error",t),at("load",t);break;case"details":at("toggle",t);break;case"embed":case"source":case"link":at("error",t),at("load",t);case"area":case"base":case"br":case"col":case"hr":case"keygen":case"meta":case"param":case"track":case"wbr":case"menuitem":for(s in n)if(n.hasOwnProperty(s)&&(o=n[s],o!=null))switch(s){case"children":case"dangerouslySetInnerHTML":throw Error(L(137,e));default:mt(t,e,s,o,n,null)}return;default:if(Rf(e)){for(c in n)n.hasOwnProperty(c)&&(o=n[c],o!==void 0&&vf(t,e,c,o,n,void 0));return}}for(r in n)n.hasOwnProperty(r)&&(o=n[r],o!=null&&mt(t,e,r,o,n,null))}function EE(t,e,n,o){switch(e){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"input":var a=null,l=null,i=null,r=null,u=null,s=null,c=null;for(p in n){var d=n[p];if(n.hasOwnProperty(p)&&d!=null)switch(p){case"checked":break;case"value":break;case"defaultValue":u=d;default:o.hasOwnProperty(p)||mt(t,e,p,null,o,d)}}for(var f in o){var p=o[f];if(d=n[f],o.hasOwnProperty(f)&&(p!=null||d!=null))switch(f){case"type":l=p;break;case"name":a=p;break;case"checked":s=p;break;case"defaultChecked":c=p;break;case"value":i=p;break;case"defaultValue":r=p;break;case"children":case"dangerouslySetInnerHTML":if(p!=null)throw Error(L(137,e));break;default:p!==d&&mt(t,e,f,p,o,d)}}Xs(t,i,r,u,s,c,l,a);return;case"select":p=i=r=f=null;for(l in n)if(u=n[l],n.hasOwnProperty(l)&&u!=null)switch(l){case"value":break;case"multiple":p=u;default:o.hasOwnProperty(l)||mt(t,e,l,null,o,u)}for(a in o)if(l=o[a],u=n[a],o.hasOwnProperty(a)&&(l!=null||u!=null))switch(a){case"value":f=l;break;case"defaultValue":r=l;break;case"multiple":i=l;default:l!==u&&mt(t,e,a,l,o,u)}e=r,n=i,o=p,f!=null?La(t,!!n,f,!1):!!o!=!!n&&(e!=null?La(t,!!n,e,!0):La(t,!!n,n?[]:"",!1));return;case"textarea":p=f=null;for(r in n)if(a=n[r],n.hasOwnProperty(r)&&a!=null&&!o.hasOwnProperty(r))switch(r){case"value":break;case"children":break;default:mt(t,e,r,null,o,a)}for(i in o)if(a=o[i],l=n[i],o.hasOwnProperty(i)&&(a!=null||l!=null))switch(i){case"value":f=a;break;case"defaultValue":p=a;break;case"children":break;case"dangerouslySetInnerHTML":if(a!=null)throw Error(L(91));break;default:a!==l&&mt(t,e,i,a,o,l)}im(t,f,p);return;case"option":for(var y in n)f=n[y],n.hasOwnProperty(y)&&f!=null&&!o.hasOwnProperty(y)&&(y==="selected"?t.selected=!1:mt(t,e,y,null,o,f));for(u in o)f=o[u],p=n[u],o.hasOwnProperty(u)&&f!==p&&(f!=null||p!=null)&&(u==="selected"?t.selected=f&&typeof f!="function"&&typeof f!="symbol":mt(t,e,u,f,o,p));return;case"img":case"link":case"area":case"base":case"br":case"col":case"embed":case"hr":case"keygen":case"meta":case"param":case"source":case"track":case"wbr":case"menuitem":for(var b in n)f=n[b],n.hasOwnProperty(b)&&f!=null&&!o.hasOwnProperty(b)&&mt(t,e,b,null,o,f);for(s in o)if(f=o[s],p=n[s],o.hasOwnProperty(s)&&f!==p&&(f!=null||p!=null))switch(s){case"children":case"dangerouslySetInnerHTML":if(f!=null)throw Error(L(137,e));break;default:mt(t,e,s,f,o,p)}return;default:if(Rf(e)){for(var x in n)f=n[x],n.hasOwnProperty(x)&&f!==void 0&&!o.hasOwnProperty(x)&&vf(t,e,x,void 0,o,f);for(c in o)f=o[c],p=n[c],!o.hasOwnProperty(c)||f===p||f===void 0&&p===void 0||vf(t,e,c,f,o,p);return}}for(var g in n)f=n[g],n.hasOwnProperty(g)&&f!=null&&!o.hasOwnProperty(g)&&mt(t,e,g,null,o,f);for(d in o)f=o[d],p=n[d],!o.hasOwnProperty(d)||f===p||f==null&&p==null||mt(t,e,d,f,o,p)}function _g(t){switch(t){case"css":case"script":case"font":case"img":case"image":case"input":case"link":return!0;default:return!1}}function NE(){if(typeof performance.getEntriesByType=="function"){for(var t=0,e=0,n=performance.getEntriesByType("resource"),o=0;o<n.length;o++){var a=n[o],l=a.transferSize,i=a.initiatorType,r=a.duration;if(l&&r&&_g(i)){for(i=0,r=a.responseEnd,o+=1;o<n.length;o++){var u=n[o],s=u.startTime;if(s>r)break;var c=u.transferSize,d=u.initiatorType;c&&_g(d)&&(u=u.responseEnd,i+=c*(u<r?1:(r-s)/(u-s)))}if(--o,e+=8*(l+i)/(a.duration/1e3),t++,10<t)break}}if(0<t)return e/t/1e6}return navigator.connection&&(t=navigator.connection.downlink,typeof t=="number")?t:5}var bf=null,xf=null;function ru(t){return t.nodeType===9?t:t.ownerDocument}function wg(t){switch(t){case"http://www.w3.org/2000/svg":return 1;case"http://www.w3.org/1998/Math/MathML":return 2;default:return 0}}function dy(t,e){if(t===0)switch(e){case"svg":return 1;case"math":return 2;default:return 0}return t===1&&e==="foreignObject"?0:t}function Sf(t,e){return t==="textarea"||t==="noscript"||typeof e.children=="string"||typeof e.children=="number"||typeof e.children=="bigint"||typeof e.dangerouslySetInnerHTML=="object"&&e.dangerouslySetInnerHTML!==null&&e.dangerouslySetInnerHTML.__html!=null}var Ts=null;function ME(){var t=window.event;return t&&t.type==="popstate"?t===Ts?!1:(Ts=t,!0):(Ts=null,!1)}var hy=typeof setTimeout=="function"?setTimeout:void 0,zE=typeof clearTimeout=="function"?clearTimeout:void 0,Eg=typeof Promise=="function"?Promise:void 0,AE=typeof queueMicrotask=="function"?queueMicrotask:typeof Eg<"u"?function(t){return Eg.resolve(null).then(t).catch(CE)}:hy;function CE(t){setTimeout(function(){throw t})}function po(t){return t==="head"}function Ng(t,e){var n=e,o=0;do{var a=n.nextSibling;if(t.removeChild(n),a&&a.nodeType===8)if(n=a.data,n==="/$"||n==="/&"){if(o===0){t.removeChild(a),Pa(e);return}o--}else if(n==="$"||n==="$?"||n==="$~"||n==="$!"||n==="&")o++;else if(n==="html")Pl(t.ownerDocument.documentElement);else if(n==="head"){n=t.ownerDocument.head,Pl(n);for(var l=n.firstChild;l;){var i=l.nextSibling,r=l.nodeName;l[vi]||r==="SCRIPT"||r==="STYLE"||r==="LINK"&&l.rel.toLowerCase()==="stylesheet"||n.removeChild(l),l=i}}else n==="body"&&Pl(t.ownerDocument.body);n=a}while(n);Pa(e)}function Mg(t,e){var n=t;t=0;do{var o=n.nextSibling;if(n.nodeType===1?e?(n._stashedDisplay=n.style.display,n.style.display="none"):(n.style.display=n._stashedDisplay||"",n.getAttribute("style")===""&&n.removeAttribute("style")):n.nodeType===3&&(e?(n._stashedText=n.nodeValue,n.nodeValue=""):n.nodeValue=n._stashedText||""),o&&o.nodeType===8)if(n=o.data,n==="/$"){if(t===0)break;t--}else n!=="$"&&n!=="$?"&&n!=="$~"&&n!=="$!"||t++;n=o}while(n)}function _f(t){var e=t.firstChild;for(e&&e.nodeType===10&&(e=e.nextSibling);e;){var n=e;switch(e=e.nextSibling,n.nodeName){case"HTML":case"HEAD":case"BODY":_f(n),Hf(n);continue;case"SCRIPT":case"STYLE":continue;case"LINK":if(n.rel.toLowerCase()==="stylesheet")continue}t.removeChild(n)}}function TE(t,e,n,o){for(;t.nodeType===1;){var a=n;if(t.nodeName.toLowerCase()!==e.toLowerCase()){if(!o&&(t.nodeName!=="INPUT"||t.type!=="hidden"))break}else if(o){if(!t[vi])switch(e){case"meta":if(!t.hasAttribute("itemprop"))break;return t;case"link":if(l=t.getAttribute("rel"),l==="stylesheet"&&t.hasAttribute("data-precedence"))break;if(l!==a.rel||t.getAttribute("href")!==(a.href==null||a.href===""?null:a.href)||t.getAttribute("crossorigin")!==(a.crossOrigin==null?null:a.crossOrigin)||t.getAttribute("title")!==(a.title==null?null:a.title))break;return t;case"style":if(t.hasAttribute("data-precedence"))break;return t;case"script":if(l=t.getAttribute("src"),(l!==(a.src==null?null:a.src)||t.getAttribute("type")!==(a.type==null?null:a.type)||t.getAttribute("crossorigin")!==(a.crossOrigin==null?null:a.crossOrigin))&&l&&t.hasAttribute("async")&&!t.hasAttribute("itemprop"))break;return t;default:return t}}else if(e==="input"&&t.type==="hidden"){var l=a.name==null?null:""+a.name;if(a.type==="hidden"&&t.getAttribute("name")===l)return t}else return t;if(t=ke(t.nextSibling),t===null)break}return null}function OE(t,e,n){if(e==="")return null;for(;t.nodeType!==3;)if((t.nodeType!==1||t.nodeName!=="INPUT"||t.type!=="hidden")&&!n||(t=ke(t.nextSibling),t===null))return null;return t}function py(t,e){for(;t.nodeType!==8;)if((t.nodeType!==1||t.nodeName!=="INPUT"||t.type!=="hidden")&&!e||(t=ke(t.nextSibling),t===null))return null;return t}function wf(t){return t.data==="$?"||t.data==="$~"}function Ef(t){return t.data==="$!"||t.data==="$?"&&t.ownerDocument.readyState!=="loading"}function DE(t,e){var n=t.ownerDocument;if(t.data==="$~")t._reactRetry=e;else if(t.data!=="$?"||n.readyState!=="loading")e();else{var o=function(){e(),n.removeEventListener("DOMContentLoaded",o)};n.addEventListener("DOMContentLoaded",o),t._reactRetry=o}}function ke(t){for(;t!=null;t=t.nextSibling){var e=t.nodeType;if(e===1||e===3)break;if(e===8){if(e=t.data,e==="$"||e==="$!"||e==="$?"||e==="$~"||e==="&"||e==="F!"||e==="F")break;if(e==="/$"||e==="/&")return null}}return t}var Nf=null;function zg(t){t=t.nextSibling;for(var e=0;t;){if(t.nodeType===8){var n=t.data;if(n==="/$"||n==="/&"){if(e===0)return ke(t.nextSibling);e--}else n!=="$"&&n!=="$!"&&n!=="$?"&&n!=="$~"&&n!=="&"||e++}t=t.nextSibling}return null}function Ag(t){t=t.previousSibling;for(var e=0;t;){if(t.nodeType===8){var n=t.data;if(n==="$"||n==="$!"||n==="$?"||n==="$~"||n==="&"){if(e===0)return t;e--}else n!=="/$"&&n!=="/&"||e++}t=t.previousSibling}return null}function gy(t,e,n){switch(e=ru(n),t){case"html":if(t=e.documentElement,!t)throw Error(L(452));return t;case"head":if(t=e.head,!t)throw Error(L(453));return t;case"body":if(t=e.body,!t)throw Error(L(454));return t;default:throw Error(L(451))}}function Pl(t){for(var e=t.attributes;e.length;)t.removeAttributeNode(e[0]);Hf(t)}var Le=new Map,Cg=new Set;function uu(t){return typeof t.getRootNode=="function"?t.getRootNode():t.nodeType===9?t:t.ownerDocument}var Hn=ft.d;ft.d={f:HE,r:RE,D:BE,C:kE,L:LE,m:UE,X:VE,S:YE,M:qE};function HE(){var t=Hn.f(),e=Nu();return t||e}function RE(t){var e=el(t);e!==null&&e.tag===5&&e.type==="form"?u0(e):Hn.r(t)}var ll=typeof document>"u"?null:document;function my(t,e,n){var o=ll;if(o&&typeof e=="string"&&e){var a=De(e);a='link[rel="'+t+'"][href="'+a+'"]',typeof n=="string"&&(a+='[crossorigin="'+n+'"]'),Cg.has(a)||(Cg.add(a),t={rel:t,crossOrigin:n,href:e},o.querySelector(a)===null&&(e=o.createElement("link"),It(e,"link",t),Zt(e),o.head.appendChild(e)))}}function BE(t){Hn.D(t),my("dns-prefetch",t,null)}function kE(t,e){Hn.C(t,e),my("preconnect",t,e)}function LE(t,e,n){Hn.L(t,e,n);var o=ll;if(o&&t&&e){var a='link[rel="preload"][as="'+De(e)+'"]';e==="image"&&n&&n.imageSrcSet?(a+='[imagesrcset="'+De(n.imageSrcSet)+'"]',typeof n.imageSizes=="string"&&(a+='[imagesizes="'+De(n.imageSizes)+'"]')):a+='[href="'+De(t)+'"]';var l=a;switch(e){case"style":l=Fa(t);break;case"script":l=il(t)}Le.has(l)||(t=wt({rel:"preload",href:e==="image"&&n&&n.imageSrcSet?void 0:t,as:e},n),Le.set(l,t),o.querySelector(a)!==null||e==="style"&&o.querySelector(Ei(l))||e==="script"&&o.querySelector(Ni(l))||(e=o.createElement("link"),It(e,"link",t),Zt(e),o.head.appendChild(e)))}}function UE(t,e){Hn.m(t,e);var n=ll;if(n&&t){var o=e&&typeof e.as=="string"?e.as:"script",a='link[rel="modulepreload"][as="'+De(o)+'"][href="'+De(t)+'"]',l=a;switch(o){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":l=il(t)}if(!Le.has(l)&&(t=wt({rel:"modulepreload",href:t},e),Le.set(l,t),n.querySelector(a)===null)){switch(o){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(n.querySelector(Ni(l)))return}o=n.createElement("link"),It(o,"link",t),Zt(o),n.head.appendChild(o)}}}function YE(t,e,n){Hn.S(t,e,n);var o=ll;if(o&&t){var a=ka(o).hoistableStyles,l=Fa(t);e=e||"default";var i=a.get(l);if(!i){var r={loading:0,preload:null};if(i=o.querySelector(Ei(l)))r.loading=5;else{t=wt({rel:"stylesheet",href:t,"data-precedence":e},n),(n=Le.get(l))&&vd(t,n);var u=i=o.createElement("link");Zt(u),It(u,"link",t),u._p=new Promise(function(s,c){u.onload=s,u.onerror=c}),u.addEventListener("load",function(){r.loading|=1}),u.addEventListener("error",function(){r.loading|=2}),r.loading|=4,Rr(i,e,o)}i={type:"stylesheet",instance:i,count:1,state:r},a.set(l,i)}}}function VE(t,e){Hn.X(t,e);var n=ll;if(n&&t){var o=ka(n).hoistableScripts,a=il(t),l=o.get(a);l||(l=n.querySelector(Ni(a)),l||(t=wt({src:t,async:!0},e),(e=Le.get(a))&&bd(t,e),l=n.createElement("script"),Zt(l),It(l,"link",t),n.head.appendChild(l)),l={type:"script",instance:l,count:1,state:null},o.set(a,l))}}function qE(t,e){Hn.M(t,e);var n=ll;if(n&&t){var o=ka(n).hoistableScripts,a=il(t),l=o.get(a);l||(l=n.querySelector(Ni(a)),l||(t=wt({src:t,async:!0,type:"module"},e),(e=Le.get(a))&&bd(t,e),l=n.createElement("script"),Zt(l),It(l,"link",t),n.head.appendChild(l)),l={type:"script",instance:l,count:1,state:null},o.set(a,l))}}function Tg(t,e,n,o){var a=(a=Pn.current)?uu(a):null;if(!a)throw Error(L(446));switch(t){case"meta":case"title":return null;case"style":return typeof n.precedence=="string"&&typeof n.href=="string"?(e=Fa(n.href),n=ka(a).hoistableStyles,o=n.get(e),o||(o={type:"style",instance:null,count:0,state:null},n.set(e,o)),o):{type:"void",instance:null,count:0,state:null};case"link":if(n.rel==="stylesheet"&&typeof n.href=="string"&&typeof n.precedence=="string"){t=Fa(n.href);var l=ka(a).hoistableStyles,i=l.get(t);if(i||(a=a.ownerDocument||a,i={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},l.set(t,i),(l=a.querySelector(Ei(t)))&&!l._p&&(i.instance=l,i.state.loading=5),Le.has(t)||(n={rel:"preload",as:"style",href:n.href,crossOrigin:n.crossOrigin,integrity:n.integrity,media:n.media,hrefLang:n.hrefLang,referrerPolicy:n.referrerPolicy},Le.set(t,n),l||XE(a,t,n,i.state))),e&&o===null)throw Error(L(528,""));return i}if(e&&o!==null)throw Error(L(529,""));return null;case"script":return e=n.async,n=n.src,typeof n=="string"&&e&&typeof e!="function"&&typeof e!="symbol"?(e=il(n),n=ka(a).hoistableScripts,o=n.get(e),o||(o={type:"script",instance:null,count:0,state:null},n.set(e,o)),o):{type:"void",instance:null,count:0,state:null};default:throw Error(L(444,t))}}function Fa(t){return'href="'+De(t)+'"'}function Ei(t){return'link[rel="stylesheet"]['+t+"]"}function yy(t){return wt({},t,{"data-precedence":t.precedence,precedence:null})}function XE(t,e,n,o){t.querySelector('link[rel="preload"][as="style"]['+e+"]")?o.loading=1:(e=t.createElement("link"),o.preload=e,e.addEventListener("load",function(){return o.loading|=1}),e.addEventListener("error",function(){return o.loading|=2}),It(e,"link",n),Zt(e),t.head.appendChild(e))}function il(t){return'[src="'+De(t)+'"]'}function Ni(t){return"script[async]"+t}function Og(t,e,n){if(e.count++,e.instance===null)switch(e.type){case"style":var o=t.querySelector('style[data-href~="'+De(n.href)+'"]');if(o)return e.instance=o,Zt(o),o;var a=wt({},n,{"data-href":n.href,"data-precedence":n.precedence,href:null,precedence:null});return o=(t.ownerDocument||t).createElement("style"),Zt(o),It(o,"style",a),Rr(o,n.precedence,t),e.instance=o;case"stylesheet":a=Fa(n.href);var l=t.querySelector(Ei(a));if(l)return e.state.loading|=4,e.instance=l,Zt(l),l;o=yy(n),(a=Le.get(a))&&vd(o,a),l=(t.ownerDocument||t).createElement("link"),Zt(l);var i=l;return i._p=new Promise(function(r,u){i.onload=r,i.onerror=u}),It(l,"link",o),e.state.loading|=4,Rr(l,n.precedence,t),e.instance=l;case"script":return l=il(n.src),(a=t.querySelector(Ni(l)))?(e.instance=a,Zt(a),a):(o=n,(a=Le.get(l))&&(o=wt({},n),bd(o,a)),t=t.ownerDocument||t,a=t.createElement("script"),Zt(a),It(a,"link",o),t.head.appendChild(a),e.instance=a);case"void":return null;default:throw Error(L(443,e.type))}else e.type==="stylesheet"&&(e.state.loading&4)===0&&(o=e.instance,e.state.loading|=4,Rr(o,n.precedence,t));return e.instance}function Rr(t,e,n){for(var o=n.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),a=o.length?o[o.length-1]:null,l=a,i=0;i<o.length;i++){var r=o[i];if(r.dataset.precedence===e)l=r;else if(l!==a)break}l?l.parentNode.insertBefore(t,l.nextSibling):(e=n.nodeType===9?n.head:n,e.insertBefore(t,e.firstChild))}function vd(t,e){t.crossOrigin==null&&(t.crossOrigin=e.crossOrigin),t.referrerPolicy==null&&(t.referrerPolicy=e.referrerPolicy),t.title==null&&(t.title=e.title)}function bd(t,e){t.crossOrigin==null&&(t.crossOrigin=e.crossOrigin),t.referrerPolicy==null&&(t.referrerPolicy=e.referrerPolicy),t.integrity==null&&(t.integrity=e.integrity)}var Br=null;function Dg(t,e,n){if(Br===null){var o=new Map,a=Br=new Map;a.set(n,o)}else a=Br,o=a.get(n),o||(o=new Map,a.set(n,o));if(o.has(t))return o;for(o.set(t,null),n=n.getElementsByTagName(t),a=0;a<n.length;a++){var l=n[a];if(!(l[vi]||l[Kt]||t==="link"&&l.getAttribute("rel")==="stylesheet")&&l.namespaceURI!=="http://www.w3.org/2000/svg"){var i=l.getAttribute(e)||"";i=t+i;var r=o.get(i);r?r.push(l):o.set(i,[l])}}return o}function Hg(t,e,n){t=t.ownerDocument||t,t.head.insertBefore(n,e==="title"?t.querySelector("head > title"):null)}function ZE(t,e,n){if(n===1||e.itemProp!=null)return!1;switch(t){case"meta":case"title":return!0;case"style":if(typeof e.precedence!="string"||typeof e.href!="string"||e.href==="")break;return!0;case"link":if(typeof e.rel!="string"||typeof e.href!="string"||e.href===""||e.onLoad||e.onError)break;return e.rel==="stylesheet"?(t=e.disabled,typeof e.precedence=="string"&&t==null):!0;case"script":if(e.async&&typeof e.async!="function"&&typeof e.async!="symbol"&&!e.onLoad&&!e.onError&&e.src&&typeof e.src=="string")return!0}return!1}function vy(t){return!(t.type==="stylesheet"&&(t.state.loading&3)===0)}function GE(t,e,n,o){if(n.type==="stylesheet"&&(typeof o.media!="string"||matchMedia(o.media).matches!==!1)&&(n.state.loading&4)===0){if(n.instance===null){var a=Fa(o.href),l=e.querySelector(Ei(a));if(l){e=l._p,e!==null&&typeof e=="object"&&typeof e.then=="function"&&(t.count++,t=cu.bind(t),e.then(t,t)),n.state.loading|=4,n.instance=l,Zt(l);return}l=e.ownerDocument||e,o=yy(o),(a=Le.get(a))&&vd(o,a),l=l.createElement("link"),Zt(l);var i=l;i._p=new Promise(function(r,u){i.onload=r,i.onerror=u}),It(l,"link",o),n.instance=l}t.stylesheets===null&&(t.stylesheets=new Map),t.stylesheets.set(n,e),(e=n.state.preload)&&(n.state.loading&3)===0&&(t.count++,n=cu.bind(t),e.addEventListener("load",n),e.addEventListener("error",n))}}var Os=0;function QE(t,e){return t.stylesheets&&t.count===0&&kr(t,t.stylesheets),0<t.count||0<t.imgCount?function(n){var o=setTimeout(function(){if(t.stylesheets&&kr(t,t.stylesheets),t.unsuspend){var l=t.unsuspend;t.unsuspend=null,l()}},6e4+e);0<t.imgBytes&&Os===0&&(Os=62500*NE());var a=setTimeout(function(){if(t.waitingForImages=!1,t.count===0&&(t.stylesheets&&kr(t,t.stylesheets),t.unsuspend)){var l=t.unsuspend;t.unsuspend=null,l()}},(t.imgBytes>Os?50:800)+e);return t.unsuspend=n,function(){t.unsuspend=null,clearTimeout(o),clearTimeout(a)}}:null}function cu(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)kr(this,this.stylesheets);else if(this.unsuspend){var t=this.unsuspend;this.unsuspend=null,t()}}}var su=null;function kr(t,e){t.stylesheets=null,t.unsuspend!==null&&(t.count++,su=new Map,e.forEach(jE,t),su=null,cu.call(t))}function jE(t,e){if(!(e.state.loading&4)){var n=su.get(t);if(n)var o=n.get(null);else{n=new Map,su.set(t,n);for(var a=t.querySelectorAll("link[data-precedence],style[data-precedence]"),l=0;l<a.length;l++){var i=a[l];(i.nodeName==="LINK"||i.getAttribute("media")!=="not all")&&(n.set(i.dataset.precedence,i),o=i)}o&&n.set(null,o)}a=e.instance,i=a.getAttribute("data-precedence"),l=n.get(i)||o,l===o&&n.set(null,a),n.set(i,a),this.count++,o=cu.bind(this),a.addEventListener("load",o),a.addEventListener("error",o),l?l.parentNode.insertBefore(a,l.nextSibling):(t=t.nodeType===9?t.head:t,t.insertBefore(a,t.firstChild)),e.state.loading|=4}}var fi={$$typeof:_n,Provider:null,Consumer:null,_currentValue:Ro,_currentValue2:Ro,_threadCount:0};function KE(t,e,n,o,a,l,i,r,u){this.tag=1,this.containerInfo=t,this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.next=this.pendingContext=this.context=this.cancelPendingCommit=null,this.callbackPriority=0,this.expirationTimes=os(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=os(0),this.hiddenUpdates=os(null),this.identifierPrefix=o,this.onUncaughtError=a,this.onCaughtError=l,this.onRecoverableError=i,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=u,this.incompleteTransitions=new Map}function by(t,e,n,o,a,l,i,r,u,s,c,d){return t=new KE(t,e,n,i,u,s,c,d,r),e=1,l===!0&&(e|=24),l=ve(3,null,null,e),t.current=l,l.stateNode=t,e=Qf(),e.refCount++,t.pooledCache=e,e.refCount++,l.memoizedState={element:o,isDehydrated:n,cache:e},$f(l),t}function xy(t){return t?(t=Da,t):Da}function Sy(t,e,n,o,a,l){a=xy(a),o.context===null?o.context=a:o.pendingContext=a,o=eo(e),o.payload={element:n},l=l===void 0?null:l,l!==null&&(o.callback=l),n=no(t,o,e),n!==null&&(de(n,t,e),Ql(n,t,e))}function Rg(t,e){if(t=t.memoizedState,t!==null&&t.dehydrated!==null){var n=t.retryLane;t.retryLane=n!==0&&n<e?n:e}}function xd(t,e){Rg(t,e),(t=t.alternate)&&Rg(t,e)}function _y(t){if(t.tag===13||t.tag===31){var e=Ko(t,67108864);e!==null&&de(e,t,67108864),xd(t,67108864)}}function Bg(t){if(t.tag===13||t.tag===31){var e=we();e=Of(e);var n=Ko(t,e);n!==null&&de(n,t,e),xd(t,e)}}var fu=!0;function $E(t,e,n,o){var a=F.T;F.T=null;var l=ft.p;try{ft.p=2,Sd(t,e,n,o)}finally{ft.p=l,F.T=a}}function JE(t,e,n,o){var a=F.T;F.T=null;var l=ft.p;try{ft.p=8,Sd(t,e,n,o)}finally{ft.p=l,F.T=a}}function Sd(t,e,n,o){if(fu){var a=Mf(o);if(a===null)Cs(t,e,o,du,n),kg(t,o);else if(WE(a,t,e,n,o))o.stopPropagation();else if(kg(t,o),e&4&&-1<IE.indexOf(t)){for(;a!==null;){var l=el(a);if(l!==null)switch(l.tag){case 3:if(l=l.stateNode,l.current.memoizedState.isDehydrated){var i=Oo(l.pendingLanes);if(i!==0){var r=l;for(r.pendingLanes|=2,r.entangledLanes|=2;i;){var u=1<<31-_e(i);r.entanglements[1]|=u,i&=~u}an(l),(st&6)===0&&(eu=xe()+500,wi(0,!1))}}break;case 31:case 13:r=Ko(l,2),r!==null&&de(r,l,2),Nu(),xd(l,2)}if(l=Mf(o),l===null&&Cs(t,e,o,du,n),l===a)break;a=l}a!==null&&o.stopPropagation()}else Cs(t,e,o,null,n)}}function Mf(t){return t=Bf(t),_d(t)}var du=null;function _d(t){if(du=null,t=Ma(t),t!==null){var e=pi(t);if(e===null)t=null;else{var n=e.tag;if(n===13){if(t=Xg(e),t!==null)return t;t=null}else if(n===31){if(t=Zg(e),t!==null)return t;t=null}else if(n===3){if(e.stateNode.current.memoizedState.isDehydrated)return e.tag===3?e.stateNode.containerInfo:null;t=null}else e!==t&&(t=null)}}return du=t,null}function wy(t){switch(t){case"beforetoggle":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"toggle":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 2;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"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 8;case"message":switch(L_()){case Kg:return 2;case $g:return 8;case qr:case U_:return 32;case Jg:return 268435456;default:return 32}default:return 32}}var zf=!1,lo=null,io=null,ro=null,di=new Map,hi=new Map,Kn=[],IE="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".split(" ");function kg(t,e){switch(t){case"focusin":case"focusout":lo=null;break;case"dragenter":case"dragleave":io=null;break;case"mouseover":case"mouseout":ro=null;break;case"pointerover":case"pointerout":di.delete(e.pointerId);break;case"gotpointercapture":case"lostpointercapture":hi.delete(e.pointerId)}}function Rl(t,e,n,o,a,l){return t===null||t.nativeEvent!==l?(t={blockedOn:e,domEventName:n,eventSystemFlags:o,nativeEvent:l,targetContainers:[a]},e!==null&&(e=el(e),e!==null&&_y(e)),t):(t.eventSystemFlags|=o,e=t.targetContainers,a!==null&&e.indexOf(a)===-1&&e.push(a),t)}function WE(t,e,n,o,a){switch(e){case"focusin":return lo=Rl(lo,t,e,n,o,a),!0;case"dragenter":return io=Rl(io,t,e,n,o,a),!0;case"mouseover":return ro=Rl(ro,t,e,n,o,a),!0;case"pointerover":var l=a.pointerId;return di.set(l,Rl(di.get(l)||null,t,e,n,o,a)),!0;case"gotpointercapture":return l=a.pointerId,hi.set(l,Rl(hi.get(l)||null,t,e,n,o,a)),!0}return!1}function Ey(t){var e=Ma(t.target);if(e!==null){var n=pi(e);if(n!==null){if(e=n.tag,e===13){if(e=Xg(n),e!==null){t.blockedOn=e,bp(t.priority,function(){Bg(n)});return}}else if(e===31){if(e=Zg(n),e!==null){t.blockedOn=e,bp(t.priority,function(){Bg(n)});return}}else if(e===3&&n.stateNode.current.memoizedState.isDehydrated){t.blockedOn=n.tag===3?n.stateNode.containerInfo:null;return}}}t.blockedOn=null}function Lr(t){if(t.blockedOn!==null)return!1;for(var e=t.targetContainers;0<e.length;){var n=Mf(t.nativeEvent);if(n===null){n=t.nativeEvent;var o=new n.constructor(n.type,n);Gs=o,n.target.dispatchEvent(o),Gs=null}else return e=el(n),e!==null&&_y(e),t.blockedOn=n,!1;e.shift()}return!0}function Lg(t,e,n){Lr(t)&&n.delete(e)}function FE(){zf=!1,lo!==null&&Lr(lo)&&(lo=null),io!==null&&Lr(io)&&(io=null),ro!==null&&Lr(ro)&&(ro=null),di.forEach(Lg),hi.forEach(Lg)}function Sr(t,e){t.blockedOn===e&&(t.blockedOn=null,zf||(zf=!0,Vt.unstable_scheduleCallback(Vt.unstable_NormalPriority,FE)))}var _r=null;function Ug(t){_r!==t&&(_r=t,Vt.unstable_scheduleCallback(Vt.unstable_NormalPriority,function(){_r===t&&(_r=null);for(var e=0;e<t.length;e+=3){var n=t[e],o=t[e+1],a=t[e+2];if(typeof o!="function"){if(_d(o||n)===null)continue;break}var l=el(n);l!==null&&(t.splice(e,3),e-=3,rf(l,{pending:!0,data:a,method:n.method,action:o},o,a))}}))}function Pa(t){function e(u){return Sr(u,t)}lo!==null&&Sr(lo,t),io!==null&&Sr(io,t),ro!==null&&Sr(ro,t),di.forEach(e),hi.forEach(e);for(var n=0;n<Kn.length;n++){var o=Kn[n];o.blockedOn===t&&(o.blockedOn=null)}for(;0<Kn.length&&(n=Kn[0],n.blockedOn===null);)Ey(n),n.blockedOn===null&&Kn.shift();if(n=(t.ownerDocument||t).$$reactFormReplay,n!=null)for(o=0;o<n.length;o+=3){var a=n[o],l=n[o+1],i=a[he]||null;if(typeof l=="function")i||Ug(n);else if(i){var r=null;if(l&&l.hasAttribute("formAction")){if(a=l,i=l[he]||null)r=i.formAction;else if(_d(a)!==null)continue}else r=i.action;typeof r=="function"?n[o+1]=r:(n.splice(o,3),o-=3),Ug(n)}}}function Ny(){function t(l){l.canIntercept&&l.info==="react-transition"&&l.intercept({handler:function(){return new Promise(function(i){return a=i})},focusReset:"manual",scroll:"manual"})}function e(){a!==null&&(a(),a=null),o||setTimeout(n,20)}function n(){if(!o&&!navigation.transition){var l=navigation.currentEntry;l&&l.url!=null&&navigation.navigate(l.url,{state:l.getState(),info:"react-transition",history:"replace"})}}if(typeof navigation=="object"){var o=!1,a=null;return navigation.addEventListener("navigate",t),navigation.addEventListener("navigatesuccess",e),navigation.addEventListener("navigateerror",e),setTimeout(n,100),function(){o=!0,navigation.removeEventListener("navigate",t),navigation.removeEventListener("navigatesuccess",e),navigation.removeEventListener("navigateerror",e),a!==null&&(a(),a=null)}}}function wd(t){this._internalRoot=t}Au.prototype.render=wd.prototype.render=function(t){var e=this._internalRoot;if(e===null)throw Error(L(409));var n=e.current,o=we();Sy(n,o,t,e,null,null)};Au.prototype.unmount=wd.prototype.unmount=function(){var t=this._internalRoot;if(t!==null){this._internalRoot=null;var e=t.containerInfo;Sy(t.current,2,null,t,null,null),Nu(),e[tl]=null}};function Au(t){this._internalRoot=t}Au.prototype.unstable_scheduleHydration=function(t){if(t){var e=tm();t={blockedOn:null,target:t,priority:e};for(var n=0;n<Kn.length&&e!==0&&e<Kn[n].priority;n++);Kn.splice(n,0,t),n===0&&Ey(t)}};var Yg=Vg.version;if(Yg!=="19.2.7")throw Error(L(527,Yg,"19.2.7"));ft.findDOMNode=function(t){var e=t._reactInternals;if(e===void 0)throw typeof t.render=="function"?Error(L(188)):(t=Object.keys(t).join(","),Error(L(268,t)));return t=T_(e),t=t!==null?Gg(t):null,t=t===null?null:t.stateNode,t};var PE={bundleType:0,version:"19.2.7",rendererPackageName:"react-dom",currentDispatcherRef:F,reconcilerVersion:"19.2.7"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&(Bl=__REACT_DEVTOOLS_GLOBAL_HOOK__,!Bl.isDisabled&&Bl.supportsFiber))try{gi=Bl.inject(PE),Se=Bl}catch{}var Bl;Cu.createRoot=function(t,e){if(!qg(t))throw Error(L(299));var n=!1,o="",a=m0,l=y0,i=v0;return e!=null&&(e.unstable_strictMode===!0&&(n=!0),e.identifierPrefix!==void 0&&(o=e.identifierPrefix),e.onUncaughtError!==void 0&&(a=e.onUncaughtError),e.onCaughtError!==void 0&&(l=e.onCaughtError),e.onRecoverableError!==void 0&&(i=e.onRecoverableError)),e=by(t,1,!1,null,null,n,o,null,a,l,i,Ny),t[tl]=e.current,yd(t),new wd(e)};Cu.hydrateRoot=function(t,e,n){if(!qg(t))throw Error(L(299));var o=!1,a="",l=m0,i=y0,r=v0,u=null;return n!=null&&(n.unstable_strictMode===!0&&(o=!0),n.identifierPrefix!==void 0&&(a=n.identifierPrefix),n.onUncaughtError!==void 0&&(l=n.onUncaughtError),n.onCaughtError!==void 0&&(i=n.onCaughtError),n.onRecoverableError!==void 0&&(r=n.onRecoverableError),n.formState!==void 0&&(u=n.formState)),e=by(t,1,!0,e,n??null,o,a,u,l,i,r,Ny),e.context=xy(null),n=e.current,o=we(),o=Of(o),a=eo(o),a.callback=null,no(n,a,o),n=o,e.current.lanes=n,yi(e,n),an(e),t[tl]=e.current,yd(t),new Au(e)};Cu.version="19.2.7"});var Cy=re((mC,Ay)=>{"use strict";function zy(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(zy)}catch(t){console.error(t)}}zy(),Ay.exports=My()});var Zy=re(Ru=>{"use strict";var g2=Symbol.for("react.transitional.element"),m2=Symbol.for("react.fragment");function Xy(t,e,n){var o=null;if(n!==void 0&&(o=""+n),e.key!==void 0&&(o=""+e.key),"key"in e){n={};for(var a in e)a!=="key"&&(n[a]=e[a])}else n=e;return e=n.ref,{$$typeof:g2,type:t,key:o,ref:e!==void 0?e:null,props:n}}Ru.Fragment=m2;Ru.jsx=Xy;Ru.jsxs=Xy});var Bu=re((EC,Gy)=>{"use strict";Gy.exports=Zy()});var zb=re(Mb=>{"use strict";var Sl=hn();function sz(t,e){return t===e&&(t!==0||1/t===1/e)||t!==t&&e!==e}var fz=typeof Object.is=="function"?Object.is:sz,dz=Sl.useState,hz=Sl.useEffect,pz=Sl.useLayoutEffect,gz=Sl.useDebugValue;function mz(t,e){var n=e(),o=dz({inst:{value:n,getSnapshot:e}}),a=o[0].inst,l=o[1];return pz(function(){a.value=n,a.getSnapshot=e,Nh(a)&&l({inst:a})},[t,n,e]),hz(function(){return Nh(a)&&l({inst:a}),t(function(){Nh(a)&&l({inst:a})})},[t]),gz(n),n}function Nh(t){var e=t.getSnapshot;t=t.value;try{var n=e();return!fz(t,n)}catch{return!0}}function yz(t,e){return e()}var vz=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?yz:mz;Mb.useSyncExternalStore=Sl.useSyncExternalStore!==void 0?Sl.useSyncExternalStore:vz});var Cb=re((y6,Ab)=>{"use strict";Ab.exports=zb()});var Ob=re(Tb=>{"use strict";var zc=hn(),bz=Cb();function xz(t,e){return t===e&&(t!==0||1/t===1/e)||t!==t&&e!==e}var Sz=typeof Object.is=="function"?Object.is:xz,_z=bz.useSyncExternalStore,wz=zc.useRef,Ez=zc.useEffect,Nz=zc.useMemo,Mz=zc.useDebugValue;Tb.useSyncExternalStoreWithSelector=function(t,e,n,o,a){var l=wz(null);if(l.current===null){var i={hasValue:!1,value:null};l.current=i}else i=l.current;l=Nz(function(){function u(p){if(!s){if(s=!0,c=p,p=o(p),a!==void 0&&i.hasValue){var y=i.value;if(a(y,p))return d=y}return d=p}if(y=d,Sz(c,p))return y;var b=o(p);return a!==void 0&&a(y,b)?(c=p,y):(c=p,d=b)}var s=!1,c,d,f=n===void 0?null:n;return[function(){return u(e())},f===null?void 0:function(){return u(f())}]},[e,n,o,a]);var r=_z(t,l[0],l[1]);return Ez(function(){i.hasValue=!0,i.value=r},[r]),Mz(r),r}});var Hb=re((b6,Db)=>{"use strict";Db.exports=Ob()});var pa=We(hn(),1),Fx=We(Cy(),1);var t2=Symbol(),Md=Symbol(),Mi="a",Oy="f",Ty="p",Dy="c",Hy="t",zd="h",zi="w",Ad="o",Cd="k",e2=(t,e)=>new Proxy(t,e),Ed=Object.getPrototypeOf,Nd=new WeakMap,Ry=t=>t&&(Nd.has(t)?Nd.get(t):Ed(t)===Object.prototype||Ed(t)===Array.prototype),Tu=t=>typeof t=="object"&&t!==null,n2=t=>Object.values(Object.getOwnPropertyDescriptors(t)).some(e=>!e.configurable&&!e.writable),o2=t=>{if(Array.isArray(t))return Array.from(t);let e=Object.getOwnPropertyDescriptors(t);return Object.values(e).forEach(n=>{n.configurable=!0}),Object.create(Ed(t),e)},a2=(t,e)=>{let n={[Oy]:e},o=!1,a=(r,u)=>{if(!o){let s=n[Mi].get(t);if(s||(s={},n[Mi].set(t,s)),r===zi)s[zi]=!0;else{let c=s[r];c||(c=new Set,s[r]=c),c.add(u)}}},l=()=>{o=!0,n[Mi].delete(t)},i={get(r,u){return u===Md?t:(a(Cd,u),Od(Reflect.get(r,u),n[Mi],n[Dy],n[Hy]))},has(r,u){return u===t2?(l(),!0):(a(zd,u),Reflect.has(r,u))},getOwnPropertyDescriptor(r,u){return a(Ad,u),Reflect.getOwnPropertyDescriptor(r,u)},ownKeys(r){return a(zi),Reflect.ownKeys(r)}};return e&&(i.set=i.deleteProperty=()=>!1),[i,n]},Td=t=>t[Md]||t,Od=(t,e,n,o)=>{if(!Ry(t))return t;let a=o&&o.get(t);if(!a){let u=Td(t);n2(u)?a=[u,o2(u)]:a=[u],o?.set(t,a)}let[l,i]=a,r=n&&n.get(l);return(!r||r[1][Oy]!==!!i)&&(r=a2(l,!!i),r[1][Ty]=e2(i||l,r[0]),n&&n.set(l,r)),r[1][Mi]=e,r[1][Dy]=n,r[1][Hy]=o,r[1][Ty]},l2=(t,e)=>{let n=Reflect.ownKeys(t),o=Reflect.ownKeys(e);return n.length!==o.length||n.some((a,l)=>a!==o[l])},Dd=(t,e,n,o,a=Object.is)=>{if(a(t,e))return!1;if(!Tu(t)||!Tu(e))return!0;let l=n.get(Td(t));if(!l)return!0;if(o){if(o.get(t)===e)return!1;o.set(t,e)}let i=null;for(let r of l[zd]||[])if(i=Reflect.has(t,r)!==Reflect.has(e,r),i)return i;if(l[zi]===!0){if(i=l2(t,e),i)return i}else for(let r of l[Ad]||[]){let u=!!Reflect.getOwnPropertyDescriptor(t,r),s=!!Reflect.getOwnPropertyDescriptor(e,r);if(i=u!==s,i)return i}for(let r of l[Cd]||[])if(i=Dd(t[r],e[r],n,o,a),i)return i;if(i===null)throw new Error("invalid used");return i};var By=t=>Ry(t)&&t[Md]||null,Hd=(t,e=!0)=>{Nd.set(t,e)},ky=(t,e,n)=>{let o=[],a=new WeakSet,l=(i,r)=>{var u,s,c;if(a.has(i))return;Tu(i)&&a.add(i);let d=Tu(i)&&e.get(Td(i));if(d){if((u=d[zd])===null||u===void 0||u.forEach(f=>{let p=`:has(${String(f)})`;o.push(r?[...r,p]:[p])}),d[zi]===!0){let f=":ownKeys";o.push(r?[...r,f]:[f])}else(s=d[Ad])===null||s===void 0||s.forEach(f=>{let p=`:hasOwn(${String(f)})`;o.push(r?[...r,p]:[p])});(c=d[Cd])===null||c===void 0||c.forEach(f=>{(!n||"value"in(Object.getOwnPropertyDescriptor(i,f)||{}))&&l(i[f],r?[...r,f]:[f])})}else r&&o.push(r)};return l(t),o};var go={},Bd=t=>typeof t=="object"&&t!==null,i2=t=>Bd(t)&&!kd.has(t)&&(Array.isArray(t)||!(Symbol.iterator in t))&&!(t instanceof WeakMap)&&!(t instanceof WeakSet)&&!(t instanceof Error)&&!(t instanceof Number)&&!(t instanceof Date)&&!(t instanceof String)&&!(t instanceof RegExp)&&!(t instanceof ArrayBuffer)&&!(t instanceof Promise),Yy=(t,e)=>{let n=Ly.get(t);if(n?.[0]===e)return n[1];let o=Array.isArray(t)?[]:Object.create(Object.getPrototypeOf(t));return Hd(o,!0),Ly.set(t,[e,o]),Reflect.ownKeys(t).forEach(a=>{if(Object.getOwnPropertyDescriptor(o,a))return;let l=Reflect.get(t,a),{enumerable:i}=Reflect.getOwnPropertyDescriptor(t,a),r={value:l,enumerable:i,configurable:!0};if(kd.has(l))Hd(l,!1);else if(Jo.has(l)){let[u,s]=Jo.get(l);r.value=Yy(u,s())}Object.defineProperty(o,a,r)}),o},r2=(t,e,n,o)=>({deleteProperty(a,l){let i=Reflect.get(a,l);n(l);let r=Reflect.deleteProperty(a,l);return r&&o(Ou?.("delete",l,i)),r},set(a,l,i,r){let u=!t()&&Reflect.has(a,l),s=Reflect.get(a,l,r);if(u&&(Uy(s,i)||Du.has(i)&&Uy(s,Du.get(i))))return!0;n(l),Bd(i)&&(i=By(i)||i);let c=!Jo.has(i)&&c2(i)?Hu(i):i;return e(l,c),Reflect.set(a,l,c,r),o(Ou?.("set",l,i,s)),!0}});var Jo=new WeakMap,kd=new WeakSet,Ly=new WeakMap,Rd=[1],Du=new WeakMap,Uy=Object.is,u2=(t,e)=>new Proxy(t,e),c2=i2,s2=Yy,f2=r2,Ou;function Hu(t={}){if(!Bd(t))throw new Error("object required");let e=Du.get(t);if(e)return e;let n=Rd[0],o=new Set,a=(x,g=++Rd[0])=>{n!==g&&(l=n=g,o.forEach(m=>m(x,g)))},l=n,i=(x=Rd[0])=>(l!==x&&(l=x,u.forEach(([g])=>{let m=g[1](x);m>n&&(n=m)})),n),r=x=>(g,m)=>{let h;g&&(h=[...g],h[1]=[x,...h[1]]),a(h,m)},u=new Map,s=(x,g)=>{let m=!kd.has(g)&&Jo.get(g);if(m){if((go.env?go.env.MODE:void 0)!=="production"&&u.has(x))throw new Error("prop listener already exists");if(o.size){let h=m[2](r(x));u.set(x,[m,h])}else u.set(x,[m])}},c=x=>{var g;let m=u.get(x);m&&(u.delete(x),(g=m[1])==null||g.call(m))},d=x=>(o.add(x),o.size===1&&u.forEach(([m,h],v)=>{if((go.env?go.env.MODE:void 0)!=="production"&&h)throw new Error("remove already exists");let _=m[2](r(v));u.set(v,[m,_])}),()=>{o.delete(x),o.size===0&&u.forEach(([m,h],v)=>{h&&(h(),u.set(v,[m]))})}),f=!0,p=f2(()=>f,s,c,a),y=u2(t,p);Du.set(t,y);let b=[t,i,d];return Jo.set(y,b),Reflect.ownKeys(t).forEach(x=>{let g=Object.getOwnPropertyDescriptor(t,x);"value"in g&&g.writable&&(y[x]=t[x])}),f=!1,y}function Vy(t,e,n){let o=Jo.get(t);(go.env?go.env.MODE:void 0)!=="production"&&!o&&console.warn("Please use proxy object");let a,l=[],i=o[2],r=!1,s=i(c=>{if(c&&l.push(c),n){e(l.splice(0));return}a||(a=Promise.resolve().then(()=>{a=void 0,r&&e(l.splice(0))}))});return r=!0,()=>{r=!1,s()}}function Ld(t){let e=Jo.get(t);(go.env?go.env.MODE:void 0)!=="production"&&!e&&console.warn("Please use proxy object");let[n,o]=e;return s2(n,o())}var Pt=We(hn(),1);var qy={},d2=(t,e)=>{let n=(0,Pt.useRef)(void 0);(0,Pt.useEffect)(()=>{n.current=ky(t,e,!0)}),(0,Pt.useDebugValue)(n.current)},h2=d2,p2=new WeakMap;function Ue(t,e){let n=e?.sync,o=(0,Pt.useMemo)(()=>t&&new WeakMap,[t]),a=(0,Pt.useRef)(void 0),l=!0,i=(0,Pt.useSyncExternalStore)((0,Pt.useCallback)(u=>{let s=Vy(t,u,n);return u(),s},[t,n]),()=>{let u=Ld(t);try{if(!l&&a.current&&!Dd(a.current,u,o,new WeakMap))return a.current}catch{}return u},()=>Ld(t));l=!1,(0,Pt.useLayoutEffect)(()=>{a.current=i}),(qy.env?qy.env.MODE:void 0)!=="production"&&h2(i,o);let r=(0,Pt.useMemo)(()=>new WeakMap,[]);return Od(i,o,r,p2)}var O=We(Bu()),D=We(hn());function Tt(t){if(typeof t=="string"||typeof t=="number")return""+t;let e="";if(Array.isArray(t))for(let n=0,o;n<t.length;n++)(o=Tt(t[n]))!==""&&(e+=(e&&" ")+o);else for(let n in t)t[n]&&(e+=(e&&" ")+n);return e}var y2={value:()=>{}};function jy(){for(var t=0,e=arguments.length,n={},o;t<e;++t){if(!(o=arguments[t]+"")||o in n||/[\s.]/.test(o))throw new Error("illegal type: "+o);n[o]=[]}return new ku(n)}function ku(t){this._=t}function v2(t,e){return t.trim().split(/^|\s+/).map(function(n){var o="",a=n.indexOf(".");if(a>=0&&(o=n.slice(a+1),n=n.slice(0,a)),n&&!e.hasOwnProperty(n))throw new Error("unknown type: "+n);return{type:n,name:o}})}ku.prototype=jy.prototype={constructor:ku,on:function(t,e){var n=this._,o=v2(t+"",n),a,l=-1,i=o.length;if(arguments.length<2){for(;++l<i;)if((a=(t=o[l]).type)&&(a=b2(n[a],t.name)))return a;return}if(e!=null&&typeof e!="function")throw new Error("invalid callback: "+e);for(;++l<i;)if(a=(t=o[l]).type)n[a]=Qy(n[a],t.name,e);else if(e==null)for(a in n)n[a]=Qy(n[a],t.name,null);return this},copy:function(){var t={},e=this._;for(var n in e)t[n]=e[n].slice();return new ku(t)},call:function(t,e){if((a=arguments.length-2)>0)for(var n=new Array(a),o=0,a,l;o<a;++o)n[o]=arguments[o+2];if(!this._.hasOwnProperty(t))throw new Error("unknown type: "+t);for(l=this._[t],o=0,a=l.length;o<a;++o)l[o].value.apply(e,n)},apply:function(t,e,n){if(!this._.hasOwnProperty(t))throw new Error("unknown type: "+t);for(var o=this._[t],a=0,l=o.length;a<l;++a)o[a].value.apply(e,n)}};function b2(t,e){for(var n=0,o=t.length,a;n<o;++n)if((a=t[n]).name===e)return a.value}function Qy(t,e,n){for(var o=0,a=t.length;o<a;++o)if(t[o].name===e){t[o]=y2,t=t.slice(0,o).concat(t.slice(o+1));break}return n!=null&&t.push({name:e,value:n}),t}var Io=jy;var Lu="http://www.w3.org/1999/xhtml",Ud={svg:"http://www.w3.org/2000/svg",xhtml:Lu,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};function Rn(t){var e=t+="",n=e.indexOf(":");return n>=0&&(e=t.slice(0,n))!=="xmlns"&&(t=t.slice(n+1)),Ud.hasOwnProperty(e)?{space:Ud[e],local:t}:t}function x2(t){return function(){var e=this.ownerDocument,n=this.namespaceURI;return n===Lu&&e.documentElement.namespaceURI===Lu?e.createElement(t):e.createElementNS(n,t)}}function S2(t){return function(){return this.ownerDocument.createElementNS(t.space,t.local)}}function Uu(t){var e=Rn(t);return(e.local?S2:x2)(e)}function _2(){}function Wo(t){return t==null?_2:function(){return this.querySelector(t)}}function Ky(t){typeof t!="function"&&(t=Wo(t));for(var e=this._groups,n=e.length,o=new Array(n),a=0;a<n;++a)for(var l=e[a],i=l.length,r=o[a]=new Array(i),u,s,c=0;c<i;++c)(u=l[c])&&(s=t.call(u,u.__data__,c,l))&&("__data__"in u&&(s.__data__=u.__data__),r[c]=s);return new Ot(o,this._parents)}function Yd(t){return t==null?[]:Array.isArray(t)?t:Array.from(t)}function w2(){return[]}function Ai(t){return t==null?w2:function(){return this.querySelectorAll(t)}}function E2(t){return function(){return Yd(t.apply(this,arguments))}}function $y(t){typeof t=="function"?t=E2(t):t=Ai(t);for(var e=this._groups,n=e.length,o=[],a=[],l=0;l<n;++l)for(var i=e[l],r=i.length,u,s=0;s<r;++s)(u=i[s])&&(o.push(t.call(u,u.__data__,s,i)),a.push(u));return new Ot(o,a)}function Ci(t){return function(){return this.matches(t)}}function Yu(t){return function(e){return e.matches(t)}}var N2=Array.prototype.find;function M2(t){return function(){return N2.call(this.children,t)}}function z2(){return this.firstElementChild}function Jy(t){return this.select(t==null?z2:M2(typeof t=="function"?t:Yu(t)))}var A2=Array.prototype.filter;function C2(){return Array.from(this.children)}function T2(t){return function(){return A2.call(this.children,t)}}function Iy(t){return this.selectAll(t==null?C2:T2(typeof t=="function"?t:Yu(t)))}function Wy(t){typeof t!="function"&&(t=Ci(t));for(var e=this._groups,n=e.length,o=new Array(n),a=0;a<n;++a)for(var l=e[a],i=l.length,r=o[a]=[],u,s=0;s<i;++s)(u=l[s])&&t.call(u,u.__data__,s,l)&&r.push(u);return new Ot(o,this._parents)}function Vu(t){return new Array(t.length)}function Fy(){return new Ot(this._enter||this._groups.map(Vu),this._parents)}function Ti(t,e){this.ownerDocument=t.ownerDocument,this.namespaceURI=t.namespaceURI,this._next=null,this._parent=t,this.__data__=e}Ti.prototype={constructor:Ti,appendChild:function(t){return this._parent.insertBefore(t,this._next)},insertBefore:function(t,e){return this._parent.insertBefore(t,e)},querySelector:function(t){return this._parent.querySelector(t)},querySelectorAll:function(t){return this._parent.querySelectorAll(t)}};function Py(t){return function(){return t}}function O2(t,e,n,o,a,l){for(var i=0,r,u=e.length,s=l.length;i<s;++i)(r=e[i])?(r.__data__=l[i],o[i]=r):n[i]=new Ti(t,l[i]);for(;i<u;++i)(r=e[i])&&(a[i]=r)}function D2(t,e,n,o,a,l,i){var r,u,s=new Map,c=e.length,d=l.length,f=new Array(c),p;for(r=0;r<c;++r)(u=e[r])&&(f[r]=p=i.call(u,u.__data__,r,e)+"",s.has(p)?a[r]=u:s.set(p,u));for(r=0;r<d;++r)p=i.call(t,l[r],r,l)+"",(u=s.get(p))?(o[r]=u,u.__data__=l[r],s.delete(p)):n[r]=new Ti(t,l[r]);for(r=0;r<c;++r)(u=e[r])&&s.get(f[r])===u&&(a[r]=u)}function H2(t){return t.__data__}function tv(t,e){if(!arguments.length)return Array.from(this,H2);var n=e?D2:O2,o=this._parents,a=this._groups;typeof t!="function"&&(t=Py(t));for(var l=a.length,i=new Array(l),r=new Array(l),u=new Array(l),s=0;s<l;++s){var c=o[s],d=a[s],f=d.length,p=R2(t.call(c,c&&c.__data__,s,o)),y=p.length,b=r[s]=new Array(y),x=i[s]=new Array(y),g=u[s]=new Array(f);n(c,d,b,x,g,p,e);for(var m=0,h=0,v,_;m<y;++m)if(v=b[m]){for(m>=h&&(h=m+1);!(_=x[h])&&++h<y;);v._next=_||null}}return i=new Ot(i,o),i._enter=r,i._exit=u,i}function R2(t){return typeof t=="object"&&"length"in t?t:Array.from(t)}function ev(){return new Ot(this._exit||this._groups.map(Vu),this._parents)}function nv(t,e,n){var o=this.enter(),a=this,l=this.exit();return typeof t=="function"?(o=t(o),o&&(o=o.selection())):o=o.append(t+""),e!=null&&(a=e(a),a&&(a=a.selection())),n==null?l.remove():n(l),o&&a?o.merge(a).order():a}function ov(t){for(var e=t.selection?t.selection():t,n=this._groups,o=e._groups,a=n.length,l=o.length,i=Math.min(a,l),r=new Array(a),u=0;u<i;++u)for(var s=n[u],c=o[u],d=s.length,f=r[u]=new Array(d),p,y=0;y<d;++y)(p=s[y]||c[y])&&(f[y]=p);for(;u<a;++u)r[u]=n[u];return new Ot(r,this._parents)}function av(){for(var t=this._groups,e=-1,n=t.length;++e<n;)for(var o=t[e],a=o.length-1,l=o[a],i;--a>=0;)(i=o[a])&&(l&&i.compareDocumentPosition(l)^4&&l.parentNode.insertBefore(i,l),l=i);return this}function lv(t){t||(t=B2);function e(d,f){return d&&f?t(d.__data__,f.__data__):!d-!f}for(var n=this._groups,o=n.length,a=new Array(o),l=0;l<o;++l){for(var i=n[l],r=i.length,u=a[l]=new Array(r),s,c=0;c<r;++c)(s=i[c])&&(u[c]=s);u.sort(e)}return new Ot(a,this._parents).order()}function B2(t,e){return t<e?-1:t>e?1:t>=e?0:NaN}function iv(){var t=arguments[0];return arguments[0]=this,t.apply(null,arguments),this}function rv(){return Array.from(this)}function uv(){for(var t=this._groups,e=0,n=t.length;e<n;++e)for(var o=t[e],a=0,l=o.length;a<l;++a){var i=o[a];if(i)return i}return null}function cv(){let t=0;for(let e of this)++t;return t}function sv(){return!this.node()}function fv(t){for(var e=this._groups,n=0,o=e.length;n<o;++n)for(var a=e[n],l=0,i=a.length,r;l<i;++l)(r=a[l])&&t.call(r,r.__data__,l,a);return this}function k2(t){return function(){this.removeAttribute(t)}}function L2(t){return function(){this.removeAttributeNS(t.space,t.local)}}function U2(t,e){return function(){this.setAttribute(t,e)}}function Y2(t,e){return function(){this.setAttributeNS(t.space,t.local,e)}}function V2(t,e){return function(){var n=e.apply(this,arguments);n==null?this.removeAttribute(t):this.setAttribute(t,n)}}function q2(t,e){return function(){var n=e.apply(this,arguments);n==null?this.removeAttributeNS(t.space,t.local):this.setAttributeNS(t.space,t.local,n)}}function dv(t,e){var n=Rn(t);if(arguments.length<2){var o=this.node();return n.local?o.getAttributeNS(n.space,n.local):o.getAttribute(n)}return this.each((e==null?n.local?L2:k2:typeof e=="function"?n.local?q2:V2:n.local?Y2:U2)(n,e))}function qu(t){return t.ownerDocument&&t.ownerDocument.defaultView||t.document&&t||t.defaultView}function X2(t){return function(){this.style.removeProperty(t)}}function Z2(t,e,n){return function(){this.style.setProperty(t,e,n)}}function G2(t,e,n){return function(){var o=e.apply(this,arguments);o==null?this.style.removeProperty(t):this.style.setProperty(t,o,n)}}function hv(t,e,n){return arguments.length>1?this.each((e==null?X2:typeof e=="function"?G2:Z2)(t,e,n??"")):mo(this.node(),t)}function mo(t,e){return t.style.getPropertyValue(e)||qu(t).getComputedStyle(t,null).getPropertyValue(e)}function Q2(t){return function(){delete this[t]}}function j2(t,e){return function(){this[t]=e}}function K2(t,e){return function(){var n=e.apply(this,arguments);n==null?delete this[t]:this[t]=n}}function pv(t,e){return arguments.length>1?this.each((e==null?Q2:typeof e=="function"?K2:j2)(t,e)):this.node()[t]}function gv(t){return t.trim().split(/^|\s+/)}function Vd(t){return t.classList||new mv(t)}function mv(t){this._node=t,this._names=gv(t.getAttribute("class")||"")}mv.prototype={add:function(t){var e=this._names.indexOf(t);e<0&&(this._names.push(t),this._node.setAttribute("class",this._names.join(" ")))},remove:function(t){var e=this._names.indexOf(t);e>=0&&(this._names.splice(e,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(t){return this._names.indexOf(t)>=0}};function yv(t,e){for(var n=Vd(t),o=-1,a=e.length;++o<a;)n.add(e[o])}function vv(t,e){for(var n=Vd(t),o=-1,a=e.length;++o<a;)n.remove(e[o])}function $2(t){return function(){yv(this,t)}}function J2(t){return function(){vv(this,t)}}function I2(t,e){return function(){(e.apply(this,arguments)?yv:vv)(this,t)}}function bv(t,e){var n=gv(t+"");if(arguments.length<2){for(var o=Vd(this.node()),a=-1,l=n.length;++a<l;)if(!o.contains(n[a]))return!1;return!0}return this.each((typeof e=="function"?I2:e?$2:J2)(n,e))}function W2(){this.textContent=""}function F2(t){return function(){this.textContent=t}}function P2(t){return function(){var e=t.apply(this,arguments);this.textContent=e??""}}function xv(t){return arguments.length?this.each(t==null?W2:(typeof t=="function"?P2:F2)(t)):this.node().textContent}function tN(){this.innerHTML=""}function eN(t){return function(){this.innerHTML=t}}function nN(t){return function(){var e=t.apply(this,arguments);this.innerHTML=e??""}}function Sv(t){return arguments.length?this.each(t==null?tN:(typeof t=="function"?nN:eN)(t)):this.node().innerHTML}function oN(){this.nextSibling&&this.parentNode.appendChild(this)}function _v(){return this.each(oN)}function aN(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}function wv(){return this.each(aN)}function Ev(t){var e=typeof t=="function"?t:Uu(t);return this.select(function(){return this.appendChild(e.apply(this,arguments))})}function lN(){return null}function Nv(t,e){var n=typeof t=="function"?t:Uu(t),o=e==null?lN:typeof e=="function"?e:Wo(e);return this.select(function(){return this.insertBefore(n.apply(this,arguments),o.apply(this,arguments)||null)})}function iN(){var t=this.parentNode;t&&t.removeChild(this)}function Mv(){return this.each(iN)}function rN(){var t=this.cloneNode(!1),e=this.parentNode;return e?e.insertBefore(t,this.nextSibling):t}function uN(){var t=this.cloneNode(!0),e=this.parentNode;return e?e.insertBefore(t,this.nextSibling):t}function zv(t){return this.select(t?uN:rN)}function Av(t){return arguments.length?this.property("__data__",t):this.node().__data__}function cN(t){return function(e){t.call(this,e,this.__data__)}}function sN(t){return t.trim().split(/^|\s+/).map(function(e){var n="",o=e.indexOf(".");return o>=0&&(n=e.slice(o+1),e=e.slice(0,o)),{type:e,name:n}})}function fN(t){return function(){var e=this.__on;if(e){for(var n=0,o=-1,a=e.length,l;n<a;++n)l=e[n],(!t.type||l.type===t.type)&&l.name===t.name?this.removeEventListener(l.type,l.listener,l.options):e[++o]=l;++o?e.length=o:delete this.__on}}}function dN(t,e,n){return function(){var o=this.__on,a,l=cN(e);if(o){for(var i=0,r=o.length;i<r;++i)if((a=o[i]).type===t.type&&a.name===t.name){this.removeEventListener(a.type,a.listener,a.options),this.addEventListener(a.type,a.listener=l,a.options=n),a.value=e;return}}this.addEventListener(t.type,l,n),a={type:t.type,name:t.name,value:e,listener:l,options:n},o?o.push(a):this.__on=[a]}}function Cv(t,e,n){var o=sN(t+""),a,l=o.length,i;if(arguments.length<2){var r=this.node().__on;if(r){for(var u=0,s=r.length,c;u<s;++u)for(a=0,c=r[u];a<l;++a)if((i=o[a]).type===c.type&&i.name===c.name)return c.value}return}for(r=e?dN:fN,a=0;a<l;++a)this.each(r(o[a],e,n));return this}function Tv(t,e,n){var o=qu(t),a=o.CustomEvent;typeof a=="function"?a=new a(e,n):(a=o.document.createEvent("Event"),n?(a.initEvent(e,n.bubbles,n.cancelable),a.detail=n.detail):a.initEvent(e,!1,!1)),t.dispatchEvent(a)}function hN(t,e){return function(){return Tv(this,t,e)}}function pN(t,e){return function(){return Tv(this,t,e.apply(this,arguments))}}function Ov(t,e){return this.each((typeof e=="function"?pN:hN)(t,e))}function*Dv(){for(var t=this._groups,e=0,n=t.length;e<n;++e)for(var o=t[e],a=0,l=o.length,i;a<l;++a)(i=o[a])&&(yield i)}var qd=[null];function Ot(t,e){this._groups=t,this._parents=e}function Hv(){return new Ot([[document.documentElement]],qd)}function gN(){return this}Ot.prototype=Hv.prototype={constructor:Ot,select:Ky,selectAll:$y,selectChild:Jy,selectChildren:Iy,filter:Wy,data:tv,enter:Fy,exit:ev,join:nv,merge:ov,selection:gN,order:av,sort:lv,call:iv,nodes:rv,node:uv,size:cv,empty:sv,each:fv,attr:dv,style:hv,property:pv,classed:bv,text:xv,html:Sv,raise:_v,lower:wv,append:Ev,insert:Nv,remove:Mv,clone:zv,datum:Av,on:Cv,dispatch:Ov,[Symbol.iterator]:Dv};var Bn=Hv;function Qt(t){return typeof t=="string"?new Ot([[document.querySelector(t)]],[document.documentElement]):new Ot([[t]],qd)}function Rv(t){let e;for(;e=t.sourceEvent;)t=e;return t}function oe(t,e){if(t=Rv(t),e===void 0&&(e=t.currentTarget),e){var n=e.ownerSVGElement||e;if(n.createSVGPoint){var o=n.createSVGPoint();return o.x=t.clientX,o.y=t.clientY,o=o.matrixTransform(e.getScreenCTM().inverse()),[o.x,o.y]}if(e.getBoundingClientRect){var a=e.getBoundingClientRect();return[t.clientX-a.left-e.clientLeft,t.clientY-a.top-e.clientTop]}}return[t.pageX,t.pageY]}var Bv={passive:!1},Fo={capture:!0,passive:!1};function Xu(t){t.stopImmediatePropagation()}function yo(t){t.preventDefault(),t.stopImmediatePropagation()}function Oi(t){var e=t.document.documentElement,n=Qt(t).on("dragstart.drag",yo,Fo);"onselectstart"in e?n.on("selectstart.drag",yo,Fo):(e.__noselect=e.style.MozUserSelect,e.style.MozUserSelect="none")}function Di(t,e){var n=t.document.documentElement,o=Qt(t).on("dragstart.drag",null);e&&(o.on("click.drag",yo,Fo),setTimeout(function(){o.on("click.drag",null)},0)),"onselectstart"in n?o.on("selectstart.drag",null):(n.style.MozUserSelect=n.__noselect,delete n.__noselect)}var Hi=t=>()=>t;function Ri(t,{sourceEvent:e,subject:n,target:o,identifier:a,active:l,x:i,y:r,dx:u,dy:s,dispatch:c}){Object.defineProperties(this,{type:{value:t,enumerable:!0,configurable:!0},sourceEvent:{value:e,enumerable:!0,configurable:!0},subject:{value:n,enumerable:!0,configurable:!0},target:{value:o,enumerable:!0,configurable:!0},identifier:{value:a,enumerable:!0,configurable:!0},active:{value:l,enumerable:!0,configurable:!0},x:{value:i,enumerable:!0,configurable:!0},y:{value:r,enumerable:!0,configurable:!0},dx:{value:u,enumerable:!0,configurable:!0},dy:{value:s,enumerable:!0,configurable:!0},_:{value:c}})}Ri.prototype.on=function(){var t=this._.on.apply(this._,arguments);return t===this._?this:t};function mN(t){return!t.ctrlKey&&!t.button}function yN(){return this.parentNode}function vN(t,e){return e??{x:t.x,y:t.y}}function bN(){return navigator.maxTouchPoints||"ontouchstart"in this}function Zu(){var t=mN,e=yN,n=vN,o=bN,a={},l=Io("start","drag","end"),i=0,r,u,s,c,d=0;function f(v){v.on("mousedown.drag",p).filter(o).on("touchstart.drag",x).on("touchmove.drag",g,Bv).on("touchend.drag touchcancel.drag",m).style("touch-action","none").style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}function p(v,_){if(!(c||!t.call(this,v,_))){var E=h(this,e.call(this,v,_),v,_,"mouse");E&&(Qt(v.view).on("mousemove.drag",y,Fo).on("mouseup.drag",b,Fo),Oi(v.view),Xu(v),s=!1,r=v.clientX,u=v.clientY,E("start",v))}}function y(v){if(yo(v),!s){var _=v.clientX-r,E=v.clientY-u;s=_*_+E*E>d}a.mouse("drag",v)}function b(v){Qt(v.view).on("mousemove.drag mouseup.drag",null),Di(v.view,s),yo(v),a.mouse("end",v)}function x(v,_){if(t.call(this,v,_)){var E=v.changedTouches,w=e.call(this,v,_),N=E.length,M,R;for(M=0;M<N;++M)(R=h(this,w,v,_,E[M].identifier,E[M]))&&(Xu(v),R("start",v,E[M]))}}function g(v){var _=v.changedTouches,E=_.length,w,N;for(w=0;w<E;++w)(N=a[_[w].identifier])&&(yo(v),N("drag",v,_[w]))}function m(v){var _=v.changedTouches,E=_.length,w,N;for(c&&clearTimeout(c),c=setTimeout(function(){c=null},500),w=0;w<E;++w)(N=a[_[w].identifier])&&(Xu(v),N("end",v,_[w]))}function h(v,_,E,w,N,M){var R=l.copy(),C=oe(M||E,_),k,V,S;if((S=n.call(v,new Ri("beforestart",{sourceEvent:E,target:f,identifier:N,active:i,x:C[0],y:C[1],dx:0,dy:0,dispatch:R}),w))!=null)return k=S.x-C[0]||0,V=S.y-C[1]||0,function A(z,T,B){var H=C,X;switch(z){case"start":a[N]=A,X=i++;break;case"end":delete a[N],--i;case"drag":C=oe(B||T,_),X=i;break}R.call(z,v,new Ri(z,{sourceEvent:T,subject:S,target:f,identifier:N,active:X,x:C[0]+k,y:C[1]+V,dx:C[0]-H[0],dy:C[1]-H[1],dispatch:R}),w)}}return f.filter=function(v){return arguments.length?(t=typeof v=="function"?v:Hi(!!v),f):t},f.container=function(v){return arguments.length?(e=typeof v=="function"?v:Hi(v),f):e},f.subject=function(v){return arguments.length?(n=typeof v=="function"?v:Hi(v),f):n},f.touchable=function(v){return arguments.length?(o=typeof v=="function"?v:Hi(!!v),f):o},f.on=function(){var v=l.on.apply(l,arguments);return v===l?f:v},f.clickDistance=function(v){return arguments.length?(d=(v=+v)*v,f):Math.sqrt(d)},f}function Gu(t,e,n){t.prototype=e.prototype=n,n.constructor=t}function Xd(t,e){var n=Object.create(t.prototype);for(var o in e)n[o]=e[o];return n}function Li(){}var Bi=.7,Ku=1/Bi,rl="\\s*([+-]?\\d+)\\s*",ki="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",ln="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",xN=/^#([0-9a-f]{3,8})$/,SN=new RegExp(`^rgb\\(${rl},${rl},${rl}\\)$`),_N=new RegExp(`^rgb\\(${ln},${ln},${ln}\\)$`),wN=new RegExp(`^rgba\\(${rl},${rl},${rl},${ki}\\)$`),EN=new RegExp(`^rgba\\(${ln},${ln},${ln},${ki}\\)$`),NN=new RegExp(`^hsl\\(${ki},${ln},${ln}\\)$`),MN=new RegExp(`^hsla\\(${ki},${ln},${ln},${ki}\\)$`),kv={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};Gu(Li,je,{copy(t){return Object.assign(new this.constructor,this,t)},displayable(){return this.rgb().displayable()},hex:Lv,formatHex:Lv,formatHex8:zN,formatHsl:AN,formatRgb:Uv,toString:Uv});function Lv(){return this.rgb().formatHex()}function zN(){return this.rgb().formatHex8()}function AN(){return Gv(this).formatHsl()}function Uv(){return this.rgb().formatRgb()}function je(t){var e,n;return t=(t+"").trim().toLowerCase(),(e=xN.exec(t))?(n=e[1].length,e=parseInt(e[1],16),n===6?Yv(e):n===3?new ge(e>>8&15|e>>4&240,e>>4&15|e&240,(e&15)<<4|e&15,1):n===8?Qu(e>>24&255,e>>16&255,e>>8&255,(e&255)/255):n===4?Qu(e>>12&15|e>>8&240,e>>8&15|e>>4&240,e>>4&15|e&240,((e&15)<<4|e&15)/255):null):(e=SN.exec(t))?new ge(e[1],e[2],e[3],1):(e=_N.exec(t))?new ge(e[1]*255/100,e[2]*255/100,e[3]*255/100,1):(e=wN.exec(t))?Qu(e[1],e[2],e[3],e[4]):(e=EN.exec(t))?Qu(e[1]*255/100,e[2]*255/100,e[3]*255/100,e[4]):(e=NN.exec(t))?Xv(e[1],e[2]/100,e[3]/100,1):(e=MN.exec(t))?Xv(e[1],e[2]/100,e[3]/100,e[4]):kv.hasOwnProperty(t)?Yv(kv[t]):t==="transparent"?new ge(NaN,NaN,NaN,0):null}function Yv(t){return new ge(t>>16&255,t>>8&255,t&255,1)}function Qu(t,e,n,o){return o<=0&&(t=e=n=NaN),new ge(t,e,n,o)}function CN(t){return t instanceof Li||(t=je(t)),t?(t=t.rgb(),new ge(t.r,t.g,t.b,t.opacity)):new ge}function ul(t,e,n,o){return arguments.length===1?CN(t):new ge(t,e,n,o??1)}function ge(t,e,n,o){this.r=+t,this.g=+e,this.b=+n,this.opacity=+o}Gu(ge,ul,Xd(Li,{brighter(t){return t=t==null?Ku:Math.pow(Ku,t),new ge(this.r*t,this.g*t,this.b*t,this.opacity)},darker(t){return t=t==null?Bi:Math.pow(Bi,t),new ge(this.r*t,this.g*t,this.b*t,this.opacity)},rgb(){return this},clamp(){return new ge(ta(this.r),ta(this.g),ta(this.b),$u(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:Vv,formatHex:Vv,formatHex8:TN,formatRgb:qv,toString:qv}));function Vv(){return`#${Po(this.r)}${Po(this.g)}${Po(this.b)}`}function TN(){return`#${Po(this.r)}${Po(this.g)}${Po(this.b)}${Po((isNaN(this.opacity)?1:this.opacity)*255)}`}function qv(){let t=$u(this.opacity);return`${t===1?"rgb(":"rgba("}${ta(this.r)}, ${ta(this.g)}, ${ta(this.b)}${t===1?")":`, ${t})`}`}function $u(t){return isNaN(t)?1:Math.max(0,Math.min(1,t))}function ta(t){return Math.max(0,Math.min(255,Math.round(t)||0))}function Po(t){return t=ta(t),(t<16?"0":"")+t.toString(16)}function Xv(t,e,n,o){return o<=0?t=e=n=NaN:n<=0||n>=1?t=e=NaN:e<=0&&(t=NaN),new Qe(t,e,n,o)}function Gv(t){if(t instanceof Qe)return new Qe(t.h,t.s,t.l,t.opacity);if(t instanceof Li||(t=je(t)),!t)return new Qe;if(t instanceof Qe)return t;t=t.rgb();var e=t.r/255,n=t.g/255,o=t.b/255,a=Math.min(e,n,o),l=Math.max(e,n,o),i=NaN,r=l-a,u=(l+a)/2;return r?(e===l?i=(n-o)/r+(n<o)*6:n===l?i=(o-e)/r+2:i=(e-n)/r+4,r/=u<.5?l+a:2-l-a,i*=60):r=u>0&&u<1?0:i,new Qe(i,r,u,t.opacity)}function Qv(t,e,n,o){return arguments.length===1?Gv(t):new Qe(t,e,n,o??1)}function Qe(t,e,n,o){this.h=+t,this.s=+e,this.l=+n,this.opacity=+o}Gu(Qe,Qv,Xd(Li,{brighter(t){return t=t==null?Ku:Math.pow(Ku,t),new Qe(this.h,this.s,this.l*t,this.opacity)},darker(t){return t=t==null?Bi:Math.pow(Bi,t),new Qe(this.h,this.s,this.l*t,this.opacity)},rgb(){var t=this.h%360+(this.h<0)*360,e=isNaN(t)||isNaN(this.s)?0:this.s,n=this.l,o=n+(n<.5?n:1-n)*e,a=2*n-o;return new ge(Zd(t>=240?t-240:t+120,a,o),Zd(t,a,o),Zd(t<120?t+240:t-120,a,o),this.opacity)},clamp(){return new Qe(Zv(this.h),ju(this.s),ju(this.l),$u(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){let t=$u(this.opacity);return`${t===1?"hsl(":"hsla("}${Zv(this.h)}, ${ju(this.s)*100}%, ${ju(this.l)*100}%${t===1?")":`, ${t})`}`}}));function Zv(t){return t=(t||0)%360,t<0?t+360:t}function ju(t){return Math.max(0,Math.min(1,t||0))}function Zd(t,e,n){return(t<60?e+(n-e)*t/60:t<180?n:t<240?e+(n-e)*(240-t)/60:e)*255}function Gd(t,e,n,o,a){var l=t*t,i=l*t;return((1-3*t+3*l-i)*e+(4-6*l+3*i)*n+(1+3*t+3*l-3*i)*o+i*a)/6}function jv(t){var e=t.length-1;return function(n){var o=n<=0?n=0:n>=1?(n=1,e-1):Math.floor(n*e),a=t[o],l=t[o+1],i=o>0?t[o-1]:2*a-l,r=o<e-1?t[o+2]:2*l-a;return Gd((n-o/e)*e,i,a,l,r)}}function Kv(t){var e=t.length;return function(n){var o=Math.floor(((n%=1)<0?++n:n)*e),a=t[(o+e-1)%e],l=t[o%e],i=t[(o+1)%e],r=t[(o+2)%e];return Gd((n-o/e)*e,a,l,i,r)}}var Ui=t=>()=>t;function ON(t,e){return function(n){return t+n*e}}function DN(t,e,n){return t=Math.pow(t,n),e=Math.pow(e,n)-t,n=1/n,function(o){return Math.pow(t+o*e,n)}}function $v(t){return(t=+t)==1?Ju:function(e,n){return n-e?DN(e,n,t):Ui(isNaN(e)?n:e)}}function Ju(t,e){var n=e-t;return n?ON(t,n):Ui(isNaN(t)?e:t)}var ea=(function t(e){var n=$v(e);function o(a,l){var i=n((a=ul(a)).r,(l=ul(l)).r),r=n(a.g,l.g),u=n(a.b,l.b),s=Ju(a.opacity,l.opacity);return function(c){return a.r=i(c),a.g=r(c),a.b=u(c),a.opacity=s(c),a+""}}return o.gamma=t,o})(1);function Jv(t){return function(e){var n=e.length,o=new Array(n),a=new Array(n),l=new Array(n),i,r;for(i=0;i<n;++i)r=ul(e[i]),o[i]=r.r||0,a[i]=r.g||0,l[i]=r.b||0;return o=t(o),a=t(a),l=t(l),r.opacity=1,function(u){return r.r=o(u),r.g=a(u),r.b=l(u),r+""}}}var HN=Jv(jv),RN=Jv(Kv);function Iv(t,e){e||(e=[]);var n=t?Math.min(e.length,t.length):0,o=e.slice(),a;return function(l){for(a=0;a<n;++a)o[a]=t[a]*(1-l)+e[a]*l;return o}}function Wv(t){return ArrayBuffer.isView(t)&&!(t instanceof DataView)}function Fv(t,e){var n=e?e.length:0,o=t?Math.min(n,t.length):0,a=new Array(o),l=new Array(n),i;for(i=0;i<o;++i)a[i]=kn(t[i],e[i]);for(;i<n;++i)l[i]=e[i];return function(r){for(i=0;i<o;++i)l[i]=a[i](r);return l}}function Pv(t,e){var n=new Date;return t=+t,e=+e,function(o){return n.setTime(t*(1-o)+e*o),n}}function ae(t,e){return t=+t,e=+e,function(n){return t*(1-n)+e*n}}function t1(t,e){var n={},o={},a;(t===null||typeof t!="object")&&(t={}),(e===null||typeof e!="object")&&(e={});for(a in e)a in t?n[a]=kn(t[a],e[a]):o[a]=e[a];return function(l){for(a in n)o[a]=n[a](l);return o}}var jd=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,Qd=new RegExp(jd.source,"g");function BN(t){return function(){return t}}function kN(t){return function(e){return t(e)+""}}function Yi(t,e){var n=jd.lastIndex=Qd.lastIndex=0,o,a,l,i=-1,r=[],u=[];for(t=t+"",e=e+"";(o=jd.exec(t))&&(a=Qd.exec(e));)(l=a.index)>n&&(l=e.slice(n,l),r[i]?r[i]+=l:r[++i]=l),(o=o[0])===(a=a[0])?r[i]?r[i]+=a:r[++i]=a:(r[++i]=null,u.push({i,x:ae(o,a)})),n=Qd.lastIndex;return n<e.length&&(l=e.slice(n),r[i]?r[i]+=l:r[++i]=l),r.length<2?u[0]?kN(u[0].x):BN(e):(e=u.length,function(s){for(var c=0,d;c<e;++c)r[(d=u[c]).i]=d.x(s);return r.join("")})}function kn(t,e){var n=typeof e,o;return e==null||n==="boolean"?Ui(e):(n==="number"?ae:n==="string"?(o=je(e))?(e=o,ea):Yi:e instanceof je?ea:e instanceof Date?Pv:Wv(e)?Iv:Array.isArray(e)?Fv:typeof e.valueOf!="function"&&typeof e.toString!="function"||isNaN(e)?t1:ae)(t,e)}var e1=180/Math.PI,Iu={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1};function Kd(t,e,n,o,a,l){var i,r,u;return(i=Math.sqrt(t*t+e*e))&&(t/=i,e/=i),(u=t*n+e*o)&&(n-=t*u,o-=e*u),(r=Math.sqrt(n*n+o*o))&&(n/=r,o/=r,u/=r),t*o<e*n&&(t=-t,e=-e,u=-u,i=-i),{translateX:a,translateY:l,rotate:Math.atan2(e,t)*e1,skewX:Math.atan(u)*e1,scaleX:i,scaleY:r}}var Wu;function n1(t){let e=new(typeof DOMMatrix=="function"?DOMMatrix:WebKitCSSMatrix)(t+"");return e.isIdentity?Iu:Kd(e.a,e.b,e.c,e.d,e.e,e.f)}function o1(t){return t==null?Iu:(Wu||(Wu=document.createElementNS("http://www.w3.org/2000/svg","g")),Wu.setAttribute("transform",t),(t=Wu.transform.baseVal.consolidate())?(t=t.matrix,Kd(t.a,t.b,t.c,t.d,t.e,t.f)):Iu)}function a1(t,e,n,o){function a(s){return s.length?s.pop()+" ":""}function l(s,c,d,f,p,y){if(s!==d||c!==f){var b=p.push("translate(",null,e,null,n);y.push({i:b-4,x:ae(s,d)},{i:b-2,x:ae(c,f)})}else(d||f)&&p.push("translate("+d+e+f+n)}function i(s,c,d,f){s!==c?(s-c>180?c+=360:c-s>180&&(s+=360),f.push({i:d.push(a(d)+"rotate(",null,o)-2,x:ae(s,c)})):c&&d.push(a(d)+"rotate("+c+o)}function r(s,c,d,f){s!==c?f.push({i:d.push(a(d)+"skewX(",null,o)-2,x:ae(s,c)}):c&&d.push(a(d)+"skewX("+c+o)}function u(s,c,d,f,p,y){if(s!==d||c!==f){var b=p.push(a(p)+"scale(",null,",",null,")");y.push({i:b-4,x:ae(s,d)},{i:b-2,x:ae(c,f)})}else(d!==1||f!==1)&&p.push(a(p)+"scale("+d+","+f+")")}return function(s,c){var d=[],f=[];return s=t(s),c=t(c),l(s.translateX,s.translateY,c.translateX,c.translateY,d,f),i(s.rotate,c.rotate,d,f),r(s.skewX,c.skewX,d,f),u(s.scaleX,s.scaleY,c.scaleX,c.scaleY,d,f),s=c=null,function(p){for(var y=-1,b=f.length,x;++y<b;)d[(x=f[y]).i]=x.x(p);return d.join("")}}}var $d=a1(n1,"px, ","px)","deg)"),Jd=a1(o1,", ",")",")");var LN=1e-12;function l1(t){return((t=Math.exp(t))+1/t)/2}function UN(t){return((t=Math.exp(t))-1/t)/2}function YN(t){return((t=Math.exp(2*t))-1)/(t+1)}var na=(function t(e,n,o){function a(l,i){var r=l[0],u=l[1],s=l[2],c=i[0],d=i[1],f=i[2],p=c-r,y=d-u,b=p*p+y*y,x,g;if(b<LN)g=Math.log(f/s)/e,x=function(w){return[r+w*p,u+w*y,s*Math.exp(e*w*g)]};else{var m=Math.sqrt(b),h=(f*f-s*s+o*b)/(2*s*n*m),v=(f*f-s*s-o*b)/(2*f*n*m),_=Math.log(Math.sqrt(h*h+1)-h),E=Math.log(Math.sqrt(v*v+1)-v);g=(E-_)/e,x=function(w){var N=w*g,M=l1(_),R=s/(n*m)*(M*YN(e*N+_)-UN(_));return[r+R*p,u+R*y,s*M/l1(e*N+_)]}}return x.duration=g*1e3*e/Math.SQRT2,x}return a.rho=function(l){var i=Math.max(.001,+l),r=i*i,u=r*r;return t(i,r,u)},a})(Math.SQRT2,2,4);var cl=0,qi=0,Vi=0,r1=1e3,Fu,Xi,Pu=0,oa=0,tc=0,Zi=typeof performance=="object"&&performance.now?performance:Date,u1=typeof window=="object"&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(t){setTimeout(t,17)};function Qi(){return oa||(u1(VN),oa=Zi.now()+tc)}function VN(){oa=0}function Gi(){this._call=this._time=this._next=null}Gi.prototype=ec.prototype={constructor:Gi,restart:function(t,e,n){if(typeof t!="function")throw new TypeError("callback is not a function");n=(n==null?Qi():+n)+(e==null?0:+e),!this._next&&Xi!==this&&(Xi?Xi._next=this:Fu=this,Xi=this),this._call=t,this._time=n,Id()},stop:function(){this._call&&(this._call=null,this._time=1/0,Id())}};function ec(t,e,n){var o=new Gi;return o.restart(t,e,n),o}function c1(){Qi(),++cl;for(var t=Fu,e;t;)(e=oa-t._time)>=0&&t._call.call(void 0,e),t=t._next;--cl}function i1(){oa=(Pu=Zi.now())+tc,cl=qi=0;try{c1()}finally{cl=0,XN(),oa=0}}function qN(){var t=Zi.now(),e=t-Pu;e>r1&&(tc-=e,Pu=t)}function XN(){for(var t,e=Fu,n,o=1/0;e;)e._call?(o>e._time&&(o=e._time),t=e,e=e._next):(n=e._next,e._next=null,e=t?t._next=n:Fu=n);Xi=t,Id(o)}function Id(t){if(!cl){qi&&(qi=clearTimeout(qi));var e=t-oa;e>24?(t<1/0&&(qi=setTimeout(i1,t-Zi.now()-tc)),Vi&&(Vi=clearInterval(Vi))):(Vi||(Pu=Zi.now(),Vi=setInterval(qN,r1)),cl=1,u1(i1))}}function nc(t,e,n){var o=new Gi;return e=e==null?0:+e,o.restart(a=>{o.stop(),t(a+e)},e,n),o}var ZN=Io("start","end","cancel","interrupt"),GN=[],d1=0,s1=1,ac=2,oc=3,f1=4,lc=5,ji=6;function vo(t,e,n,o,a,l){var i=t.__transition;if(!i)t.__transition={};else if(n in i)return;QN(t,n,{name:e,index:o,group:a,on:ZN,tween:GN,time:l.time,delay:l.delay,duration:l.duration,ease:l.ease,timer:null,state:d1})}function Ki(t,e){var n=qt(t,e);if(n.state>d1)throw new Error("too late; already scheduled");return n}function Wt(t,e){var n=qt(t,e);if(n.state>oc)throw new Error("too late; already running");return n}function qt(t,e){var n=t.__transition;if(!n||!(n=n[e]))throw new Error("transition not found");return n}function QN(t,e,n){var o=t.__transition,a;o[e]=n,n.timer=ec(l,0,n.time);function l(s){n.state=s1,n.timer.restart(i,n.delay,n.time),n.delay<=s&&i(s-n.delay)}function i(s){var c,d,f,p;if(n.state!==s1)return u();for(c in o)if(p=o[c],p.name===n.name){if(p.state===oc)return nc(i);p.state===f1?(p.state=ji,p.timer.stop(),p.on.call("interrupt",t,t.__data__,p.index,p.group),delete o[c]):+c<e&&(p.state=ji,p.timer.stop(),p.on.call("cancel",t,t.__data__,p.index,p.group),delete o[c])}if(nc(function(){n.state===oc&&(n.state=f1,n.timer.restart(r,n.delay,n.time),r(s))}),n.state=ac,n.on.call("start",t,t.__data__,n.index,n.group),n.state===ac){for(n.state=oc,a=new Array(f=n.tween.length),c=0,d=-1;c<f;++c)(p=n.tween[c].value.call(t,t.__data__,n.index,n.group))&&(a[++d]=p);a.length=d+1}}function r(s){for(var c=s<n.duration?n.ease.call(null,s/n.duration):(n.timer.restart(u),n.state=lc,1),d=-1,f=a.length;++d<f;)a[d].call(t,c);n.state===lc&&(n.on.call("end",t,t.__data__,n.index,n.group),u())}function u(){n.state=ji,n.timer.stop(),delete o[e];for(var s in o)return;delete t.__transition}}function aa(t,e){var n=t.__transition,o,a,l=!0,i;if(n){e=e==null?null:e+"";for(i in n){if((o=n[i]).name!==e){l=!1;continue}a=o.state>ac&&o.state<lc,o.state=ji,o.timer.stop(),o.on.call(a?"interrupt":"cancel",t,t.__data__,o.index,o.group),delete n[i]}l&&delete t.__transition}}function h1(t){return this.each(function(){aa(this,t)})}function jN(t,e){var n,o;return function(){var a=Wt(this,t),l=a.tween;if(l!==n){o=n=l;for(var i=0,r=o.length;i<r;++i)if(o[i].name===e){o=o.slice(),o.splice(i,1);break}}a.tween=o}}function KN(t,e,n){var o,a;if(typeof n!="function")throw new Error;return function(){var l=Wt(this,t),i=l.tween;if(i!==o){a=(o=i).slice();for(var r={name:e,value:n},u=0,s=a.length;u<s;++u)if(a[u].name===e){a[u]=r;break}u===s&&a.push(r)}l.tween=a}}function p1(t,e){var n=this._id;if(t+="",arguments.length<2){for(var o=qt(this.node(),n).tween,a=0,l=o.length,i;a<l;++a)if((i=o[a]).name===t)return i.value;return null}return this.each((e==null?jN:KN)(n,t,e))}function sl(t,e,n){var o=t._id;return t.each(function(){var a=Wt(this,o);(a.value||(a.value={}))[e]=n.apply(this,arguments)}),function(a){return qt(a,o).value[e]}}function ic(t,e){var n;return(typeof e=="number"?ae:e instanceof je?ea:(n=je(e))?(e=n,ea):Yi)(t,e)}function $N(t){return function(){this.removeAttribute(t)}}function JN(t){return function(){this.removeAttributeNS(t.space,t.local)}}function IN(t,e,n){var o,a=n+"",l;return function(){var i=this.getAttribute(t);return i===a?null:i===o?l:l=e(o=i,n)}}function WN(t,e,n){var o,a=n+"",l;return function(){var i=this.getAttributeNS(t.space,t.local);return i===a?null:i===o?l:l=e(o=i,n)}}function FN(t,e,n){var o,a,l;return function(){var i,r=n(this),u;return r==null?void this.removeAttribute(t):(i=this.getAttribute(t),u=r+"",i===u?null:i===o&&u===a?l:(a=u,l=e(o=i,r)))}}function PN(t,e,n){var o,a,l;return function(){var i,r=n(this),u;return r==null?void this.removeAttributeNS(t.space,t.local):(i=this.getAttributeNS(t.space,t.local),u=r+"",i===u?null:i===o&&u===a?l:(a=u,l=e(o=i,r)))}}function g1(t,e){var n=Rn(t),o=n==="transform"?Jd:ic;return this.attrTween(t,typeof e=="function"?(n.local?PN:FN)(n,o,sl(this,"attr."+t,e)):e==null?(n.local?JN:$N)(n):(n.local?WN:IN)(n,o,e))}function tM(t,e){return function(n){this.setAttribute(t,e.call(this,n))}}function eM(t,e){return function(n){this.setAttributeNS(t.space,t.local,e.call(this,n))}}function nM(t,e){var n,o;function a(){var l=e.apply(this,arguments);return l!==o&&(n=(o=l)&&eM(t,l)),n}return a._value=e,a}function oM(t,e){var n,o;function a(){var l=e.apply(this,arguments);return l!==o&&(n=(o=l)&&tM(t,l)),n}return a._value=e,a}function m1(t,e){var n="attr."+t;if(arguments.length<2)return(n=this.tween(n))&&n._value;if(e==null)return this.tween(n,null);if(typeof e!="function")throw new Error;var o=Rn(t);return this.tween(n,(o.local?nM:oM)(o,e))}function aM(t,e){return function(){Ki(this,t).delay=+e.apply(this,arguments)}}function lM(t,e){return e=+e,function(){Ki(this,t).delay=e}}function y1(t){var e=this._id;return arguments.length?this.each((typeof t=="function"?aM:lM)(e,t)):qt(this.node(),e).delay}function iM(t,e){return function(){Wt(this,t).duration=+e.apply(this,arguments)}}function rM(t,e){return e=+e,function(){Wt(this,t).duration=e}}function v1(t){var e=this._id;return arguments.length?this.each((typeof t=="function"?iM:rM)(e,t)):qt(this.node(),e).duration}function uM(t,e){if(typeof e!="function")throw new Error;return function(){Wt(this,t).ease=e}}function b1(t){var e=this._id;return arguments.length?this.each(uM(e,t)):qt(this.node(),e).ease}function cM(t,e){return function(){var n=e.apply(this,arguments);if(typeof n!="function")throw new Error;Wt(this,t).ease=n}}function x1(t){if(typeof t!="function")throw new Error;return this.each(cM(this._id,t))}function S1(t){typeof t!="function"&&(t=Ci(t));for(var e=this._groups,n=e.length,o=new Array(n),a=0;a<n;++a)for(var l=e[a],i=l.length,r=o[a]=[],u,s=0;s<i;++s)(u=l[s])&&t.call(u,u.__data__,s,l)&&r.push(u);return new le(o,this._parents,this._name,this._id)}function _1(t){if(t._id!==this._id)throw new Error;for(var e=this._groups,n=t._groups,o=e.length,a=n.length,l=Math.min(o,a),i=new Array(o),r=0;r<l;++r)for(var u=e[r],s=n[r],c=u.length,d=i[r]=new Array(c),f,p=0;p<c;++p)(f=u[p]||s[p])&&(d[p]=f);for(;r<o;++r)i[r]=e[r];return new le(i,this._parents,this._name,this._id)}function sM(t){return(t+"").trim().split(/^|\s+/).every(function(e){var n=e.indexOf(".");return n>=0&&(e=e.slice(0,n)),!e||e==="start"})}function fM(t,e,n){var o,a,l=sM(e)?Ki:Wt;return function(){var i=l(this,t),r=i.on;r!==o&&(a=(o=r).copy()).on(e,n),i.on=a}}function w1(t,e){var n=this._id;return arguments.length<2?qt(this.node(),n).on.on(t):this.each(fM(n,t,e))}function dM(t){return function(){var e=this.parentNode;for(var n in this.__transition)if(+n!==t)return;e&&e.removeChild(this)}}function E1(){return this.on("end.remove",dM(this._id))}function N1(t){var e=this._name,n=this._id;typeof t!="function"&&(t=Wo(t));for(var o=this._groups,a=o.length,l=new Array(a),i=0;i<a;++i)for(var r=o[i],u=r.length,s=l[i]=new Array(u),c,d,f=0;f<u;++f)(c=r[f])&&(d=t.call(c,c.__data__,f,r))&&("__data__"in c&&(d.__data__=c.__data__),s[f]=d,vo(s[f],e,n,f,s,qt(c,n)));return new le(l,this._parents,e,n)}function M1(t){var e=this._name,n=this._id;typeof t!="function"&&(t=Ai(t));for(var o=this._groups,a=o.length,l=[],i=[],r=0;r<a;++r)for(var u=o[r],s=u.length,c,d=0;d<s;++d)if(c=u[d]){for(var f=t.call(c,c.__data__,d,u),p,y=qt(c,n),b=0,x=f.length;b<x;++b)(p=f[b])&&vo(p,e,n,b,f,y);l.push(f),i.push(c)}return new le(l,i,e,n)}var hM=Bn.prototype.constructor;function z1(){return new hM(this._groups,this._parents)}function pM(t,e){var n,o,a;return function(){var l=mo(this,t),i=(this.style.removeProperty(t),mo(this,t));return l===i?null:l===n&&i===o?a:a=e(n=l,o=i)}}function A1(t){return function(){this.style.removeProperty(t)}}function gM(t,e,n){var o,a=n+"",l;return function(){var i=mo(this,t);return i===a?null:i===o?l:l=e(o=i,n)}}function mM(t,e,n){var o,a,l;return function(){var i=mo(this,t),r=n(this),u=r+"";return r==null&&(u=r=(this.style.removeProperty(t),mo(this,t))),i===u?null:i===o&&u===a?l:(a=u,l=e(o=i,r))}}function yM(t,e){var n,o,a,l="style."+e,i="end."+l,r;return function(){var u=Wt(this,t),s=u.on,c=u.value[l]==null?r||(r=A1(e)):void 0;(s!==n||a!==c)&&(o=(n=s).copy()).on(i,a=c),u.on=o}}function C1(t,e,n){var o=(t+="")=="transform"?$d:ic;return e==null?this.styleTween(t,pM(t,o)).on("end.style."+t,A1(t)):typeof e=="function"?this.styleTween(t,mM(t,o,sl(this,"style."+t,e))).each(yM(this._id,t)):this.styleTween(t,gM(t,o,e),n).on("end.style."+t,null)}function vM(t,e,n){return function(o){this.style.setProperty(t,e.call(this,o),n)}}function bM(t,e,n){var o,a;function l(){var i=e.apply(this,arguments);return i!==a&&(o=(a=i)&&vM(t,i,n)),o}return l._value=e,l}function T1(t,e,n){var o="style."+(t+="");if(arguments.length<2)return(o=this.tween(o))&&o._value;if(e==null)return this.tween(o,null);if(typeof e!="function")throw new Error;return this.tween(o,bM(t,e,n??""))}function xM(t){return function(){this.textContent=t}}function SM(t){return function(){var e=t(this);this.textContent=e??""}}function O1(t){return this.tween("text",typeof t=="function"?SM(sl(this,"text",t)):xM(t==null?"":t+""))}function _M(t){return function(e){this.textContent=t.call(this,e)}}function wM(t){var e,n;function o(){var a=t.apply(this,arguments);return a!==n&&(e=(n=a)&&_M(a)),e}return o._value=t,o}function D1(t){var e="text";if(arguments.length<1)return(e=this.tween(e))&&e._value;if(t==null)return this.tween(e,null);if(typeof t!="function")throw new Error;return this.tween(e,wM(t))}function H1(){for(var t=this._name,e=this._id,n=rc(),o=this._groups,a=o.length,l=0;l<a;++l)for(var i=o[l],r=i.length,u,s=0;s<r;++s)if(u=i[s]){var c=qt(u,e);vo(u,t,n,s,i,{time:c.time+c.delay+c.duration,delay:0,duration:c.duration,ease:c.ease})}return new le(o,this._parents,t,n)}function R1(){var t,e,n=this,o=n._id,a=n.size();return new Promise(function(l,i){var r={value:i},u={value:function(){--a===0&&l()}};n.each(function(){var s=Wt(this,o),c=s.on;c!==t&&(e=(t=c).copy(),e._.cancel.push(r),e._.interrupt.push(r),e._.end.push(u)),s.on=e}),a===0&&l()})}var EM=0;function le(t,e,n,o){this._groups=t,this._parents=e,this._name=n,this._id=o}function B1(t){return Bn().transition(t)}function rc(){return++EM}var Ln=Bn.prototype;le.prototype=B1.prototype={constructor:le,select:N1,selectAll:M1,selectChild:Ln.selectChild,selectChildren:Ln.selectChildren,filter:S1,merge:_1,selection:z1,transition:H1,call:Ln.call,nodes:Ln.nodes,node:Ln.node,size:Ln.size,empty:Ln.empty,each:Ln.each,on:w1,attr:g1,attrTween:m1,style:C1,styleTween:T1,text:O1,textTween:D1,remove:E1,tween:p1,delay:y1,duration:v1,ease:b1,easeVarying:x1,end:R1,[Symbol.iterator]:Ln[Symbol.iterator]};function uc(t){return((t*=2)<=1?t*t*t:(t-=2)*t*t+2)/2}var NM={time:null,delay:0,duration:250,ease:uc};function MM(t,e){for(var n;!(n=t.__transition)||!(n=n[e]);)if(!(t=t.parentNode))throw new Error(`transition ${e} not found`);return n}function k1(t){var e,n;t instanceof le?(e=t._id,t=t._name):(e=rc(),(n=NM).time=Qi(),t=t==null?null:t+"");for(var o=this._groups,a=o.length,l=0;l<a;++l)for(var i=o[l],r=i.length,u,s=0;s<r;++s)(u=i[s])&&vo(u,t,e,s,i,n||MM(u,e));return new le(o,this._parents,t,e)}Bn.prototype.interrupt=h1;Bn.prototype.transition=k1;var $i=t=>()=>t;function Wd(t,{sourceEvent:e,target:n,transform:o,dispatch:a}){Object.defineProperties(this,{type:{value:t,enumerable:!0,configurable:!0},sourceEvent:{value:e,enumerable:!0,configurable:!0},target:{value:n,enumerable:!0,configurable:!0},transform:{value:o,enumerable:!0,configurable:!0},_:{value:a}})}function Ke(t,e,n){this.k=t,this.x=e,this.y=n}Ke.prototype={constructor:Ke,scale:function(t){return t===1?this:new Ke(this.k*t,this.x,this.y)},translate:function(t,e){return t===0&e===0?this:new Ke(this.k,this.x+this.k*t,this.y+this.k*e)},apply:function(t){return[t[0]*this.k+this.x,t[1]*this.k+this.y]},applyX:function(t){return t*this.k+this.x},applyY:function(t){return t*this.k+this.y},invert:function(t){return[(t[0]-this.x)/this.k,(t[1]-this.y)/this.k]},invertX:function(t){return(t-this.x)/this.k},invertY:function(t){return(t-this.y)/this.k},rescaleX:function(t){return t.copy().domain(t.range().map(this.invertX,this).map(t.invert,t))},rescaleY:function(t){return t.copy().domain(t.range().map(this.invertY,this).map(t.invert,t))},toString:function(){return"translate("+this.x+","+this.y+") scale("+this.k+")"}};var la=new Ke(1,0,0);Ji.prototype=Ke.prototype;function Ji(t){for(;!t.__zoom;)if(!(t=t.parentNode))return la;return t.__zoom}function cc(t){t.stopImmediatePropagation()}function fl(t){t.preventDefault(),t.stopImmediatePropagation()}function zM(t){return(!t.ctrlKey||t.type==="wheel")&&!t.button}function AM(){var t=this;return t instanceof SVGElement?(t=t.ownerSVGElement||t,t.hasAttribute("viewBox")?(t=t.viewBox.baseVal,[[t.x,t.y],[t.x+t.width,t.y+t.height]]):[[0,0],[t.width.baseVal.value,t.height.baseVal.value]]):[[0,0],[t.clientWidth,t.clientHeight]]}function L1(){return this.__zoom||la}function CM(t){return-t.deltaY*(t.deltaMode===1?.05:t.deltaMode?1:.002)*(t.ctrlKey?10:1)}function TM(){return navigator.maxTouchPoints||"ontouchstart"in this}function OM(t,e,n){var o=t.invertX(e[0][0])-n[0][0],a=t.invertX(e[1][0])-n[1][0],l=t.invertY(e[0][1])-n[0][1],i=t.invertY(e[1][1])-n[1][1];return t.translate(a>o?(o+a)/2:Math.min(0,o)||Math.max(0,a),i>l?(l+i)/2:Math.min(0,l)||Math.max(0,i))}function sc(){var t=zM,e=AM,n=OM,o=CM,a=TM,l=[0,1/0],i=[[-1/0,-1/0],[1/0,1/0]],r=250,u=na,s=Io("start","zoom","end"),c,d,f,p=500,y=150,b=0,x=10;function g(S){S.property("__zoom",L1).on("wheel.zoom",N,{passive:!1}).on("mousedown.zoom",M).on("dblclick.zoom",R).filter(a).on("touchstart.zoom",C).on("touchmove.zoom",k).on("touchend.zoom touchcancel.zoom",V).style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}g.transform=function(S,A,z,T){var B=S.selection?S.selection():S;B.property("__zoom",L1),S!==B?_(S,A,z,T):B.interrupt().each(function(){E(this,arguments).event(T).start().zoom(null,typeof A=="function"?A.apply(this,arguments):A).end()})},g.scaleBy=function(S,A,z,T){g.scaleTo(S,function(){var B=this.__zoom.k,H=typeof A=="function"?A.apply(this,arguments):A;return B*H},z,T)},g.scaleTo=function(S,A,z,T){g.transform(S,function(){var B=e.apply(this,arguments),H=this.__zoom,X=z==null?v(B):typeof z=="function"?z.apply(this,arguments):z,Z=H.invert(X),q=typeof A=="function"?A.apply(this,arguments):A;return n(h(m(H,q),X,Z),B,i)},z,T)},g.translateBy=function(S,A,z,T){g.transform(S,function(){return n(this.__zoom.translate(typeof A=="function"?A.apply(this,arguments):A,typeof z=="function"?z.apply(this,arguments):z),e.apply(this,arguments),i)},null,T)},g.translateTo=function(S,A,z,T,B){g.transform(S,function(){var H=e.apply(this,arguments),X=this.__zoom,Z=T==null?v(H):typeof T=="function"?T.apply(this,arguments):T;return n(la.translate(Z[0],Z[1]).scale(X.k).translate(typeof A=="function"?-A.apply(this,arguments):-A,typeof z=="function"?-z.apply(this,arguments):-z),H,i)},T,B)};function m(S,A){return A=Math.max(l[0],Math.min(l[1],A)),A===S.k?S:new Ke(A,S.x,S.y)}function h(S,A,z){var T=A[0]-z[0]*S.k,B=A[1]-z[1]*S.k;return T===S.x&&B===S.y?S:new Ke(S.k,T,B)}function v(S){return[(+S[0][0]+ +S[1][0])/2,(+S[0][1]+ +S[1][1])/2]}function _(S,A,z,T){S.on("start.zoom",function(){E(this,arguments).event(T).start()}).on("interrupt.zoom end.zoom",function(){E(this,arguments).event(T).end()}).tween("zoom",function(){var B=this,H=arguments,X=E(B,H).event(T),Z=e.apply(B,H),q=z==null?v(Z):typeof z=="function"?z.apply(B,H):z,K=Math.max(Z[1][0]-Z[0][0],Z[1][1]-Z[0][1]),j=B.__zoom,I=typeof A=="function"?A.apply(B,H):A,ot=u(j.invert(q).concat(K/j.k),I.invert(q).concat(K/I.k));return function(J){if(J===1)J=I;else{var U=ot(J),Q=K/U[2];J=new Ke(Q,q[0]-U[0]*Q,q[1]-U[1]*Q)}X.zoom(null,J)}})}function E(S,A,z){return!z&&S.__zooming||new w(S,A)}function w(S,A){this.that=S,this.args=A,this.active=0,this.sourceEvent=null,this.extent=e.apply(S,A),this.taps=0}w.prototype={event:function(S){return S&&(this.sourceEvent=S),this},start:function(){return++this.active===1&&(this.that.__zooming=this,this.emit("start")),this},zoom:function(S,A){return this.mouse&&S!=="mouse"&&(this.mouse[1]=A.invert(this.mouse[0])),this.touch0&&S!=="touch"&&(this.touch0[1]=A.invert(this.touch0[0])),this.touch1&&S!=="touch"&&(this.touch1[1]=A.invert(this.touch1[0])),this.that.__zoom=A,this.emit("zoom"),this},end:function(){return--this.active===0&&(delete this.that.__zooming,this.emit("end")),this},emit:function(S){var A=Qt(this.that).datum();s.call(S,this.that,new Wd(S,{sourceEvent:this.sourceEvent,target:g,type:S,transform:this.that.__zoom,dispatch:s}),A)}};function N(S,...A){if(!t.apply(this,arguments))return;var z=E(this,A).event(S),T=this.__zoom,B=Math.max(l[0],Math.min(l[1],T.k*Math.pow(2,o.apply(this,arguments)))),H=oe(S);if(z.wheel)(z.mouse[0][0]!==H[0]||z.mouse[0][1]!==H[1])&&(z.mouse[1]=T.invert(z.mouse[0]=H)),clearTimeout(z.wheel);else{if(T.k===B)return;z.mouse=[H,T.invert(H)],aa(this),z.start()}fl(S),z.wheel=setTimeout(X,y),z.zoom("mouse",n(h(m(T,B),z.mouse[0],z.mouse[1]),z.extent,i));function X(){z.wheel=null,z.end()}}function M(S,...A){if(f||!t.apply(this,arguments))return;var z=S.currentTarget,T=E(this,A,!0).event(S),B=Qt(S.view).on("mousemove.zoom",q,!0).on("mouseup.zoom",K,!0),H=oe(S,z),X=S.clientX,Z=S.clientY;Oi(S.view),cc(S),T.mouse=[H,this.__zoom.invert(H)],aa(this),T.start();function q(j){if(fl(j),!T.moved){var I=j.clientX-X,ot=j.clientY-Z;T.moved=I*I+ot*ot>b}T.event(j).zoom("mouse",n(h(T.that.__zoom,T.mouse[0]=oe(j,z),T.mouse[1]),T.extent,i))}function K(j){B.on("mousemove.zoom mouseup.zoom",null),Di(j.view,T.moved),fl(j),T.event(j).end()}}function R(S,...A){if(t.apply(this,arguments)){var z=this.__zoom,T=oe(S.changedTouches?S.changedTouches[0]:S,this),B=z.invert(T),H=z.k*(S.shiftKey?.5:2),X=n(h(m(z,H),T,B),e.apply(this,A),i);fl(S),r>0?Qt(this).transition().duration(r).call(_,X,T,S):Qt(this).call(g.transform,X,T,S)}}function C(S,...A){if(t.apply(this,arguments)){var z=S.touches,T=z.length,B=E(this,A,S.changedTouches.length===T).event(S),H,X,Z,q;for(cc(S),X=0;X<T;++X)Z=z[X],q=oe(Z,this),q=[q,this.__zoom.invert(q),Z.identifier],B.touch0?!B.touch1&&B.touch0[2]!==q[2]&&(B.touch1=q,B.taps=0):(B.touch0=q,H=!0,B.taps=1+!!c);c&&(c=clearTimeout(c)),H&&(B.taps<2&&(d=q[0],c=setTimeout(function(){c=null},p)),aa(this),B.start())}}function k(S,...A){if(this.__zooming){var z=E(this,A).event(S),T=S.changedTouches,B=T.length,H,X,Z,q;for(fl(S),H=0;H<B;++H)X=T[H],Z=oe(X,this),z.touch0&&z.touch0[2]===X.identifier?z.touch0[0]=Z:z.touch1&&z.touch1[2]===X.identifier&&(z.touch1[0]=Z);if(X=z.that.__zoom,z.touch1){var K=z.touch0[0],j=z.touch0[1],I=z.touch1[0],ot=z.touch1[1],J=(J=I[0]-K[0])*J+(J=I[1]-K[1])*J,U=(U=ot[0]-j[0])*U+(U=ot[1]-j[1])*U;X=m(X,Math.sqrt(J/U)),Z=[(K[0]+I[0])/2,(K[1]+I[1])/2],q=[(j[0]+ot[0])/2,(j[1]+ot[1])/2]}else if(z.touch0)Z=z.touch0[0],q=z.touch0[1];else return;z.zoom("touch",n(h(X,Z,q),z.extent,i))}}function V(S,...A){if(this.__zooming){var z=E(this,A).event(S),T=S.changedTouches,B=T.length,H,X;for(cc(S),f&&clearTimeout(f),f=setTimeout(function(){f=null},p),H=0;H<B;++H)X=T[H],z.touch0&&z.touch0[2]===X.identifier?delete z.touch0:z.touch1&&z.touch1[2]===X.identifier&&delete z.touch1;if(z.touch1&&!z.touch0&&(z.touch0=z.touch1,delete z.touch1),z.touch0)z.touch0[1]=this.__zoom.invert(z.touch0[0]);else if(z.end(),z.taps===2&&(X=oe(X,this),Math.hypot(d[0]-X[0],d[1]-X[1])<x)){var Z=Qt(this).on("dblclick.zoom");Z&&Z.apply(this,arguments)}}}return g.wheelDelta=function(S){return arguments.length?(o=typeof S=="function"?S:$i(+S),g):o},g.filter=function(S){return arguments.length?(t=typeof S=="function"?S:$i(!!S),g):t},g.touchable=function(S){return arguments.length?(a=typeof S=="function"?S:$i(!!S),g):a},g.extent=function(S){return arguments.length?(e=typeof S=="function"?S:$i([[+S[0][0],+S[0][1]],[+S[1][0],+S[1][1]]]),g):e},g.scaleExtent=function(S){return arguments.length?(l[0]=+S[0],l[1]=+S[1],g):[l[0],l[1]]},g.translateExtent=function(S){return arguments.length?(i[0][0]=+S[0][0],i[1][0]=+S[1][0],i[0][1]=+S[0][1],i[1][1]=+S[1][1],g):[[i[0][0],i[0][1]],[i[1][0],i[1][1]]]},g.constrain=function(S){return arguments.length?(n=S,g):n},g.duration=function(S){return arguments.length?(r=+S,g):r},g.interpolate=function(S){return arguments.length?(u=S,g):u},g.on=function(){var S=s.on.apply(s,arguments);return S===s?g:S},g.clickDistance=function(S){return arguments.length?(b=(S=+S)*S,g):Math.sqrt(b)},g.tapDistance=function(S){return arguments.length?(x=+S,g):x},g}var Me={error001:(t="react")=>`Seems like you have not used zustand provider as an ancestor. Help: https://${t}flow.dev/error#001`,error002:()=>"It looks like you've created a new nodeTypes or edgeTypes object. If this wasn't on purpose please define the nodeTypes/edgeTypes outside of the component or memoize them.",error003:t=>`Node type "${t}" not found. Using fallback type "default".`,error004:()=>"The parent container needs a width and a height to render the graph.",error005:()=>"Only child nodes can use a parent extent.",error006:()=>"Can't create edge. An edge needs a source and a target.",error007:t=>`The old edge with id=${t} does not exist.`,error009:t=>`Marker type "${t}" doesn't exist.`,error008:(t,{id:e,sourceHandle:n,targetHandle:o})=>`Couldn't create edge for ${t} handle id: "${t==="source"?n:o}", edge id: ${e}.`,error010:()=>"Handle: No node id found. Make sure to only use a Handle inside a custom Node.",error011:t=>`Edge type "${t}" not found. Using fallback type "default".`,error012:t=>`Node with id "${t}" does not exist, it may have been removed. This can happen when a node is deleted before the "onNodeClick" handler is called.`,error013:(t="react")=>`It seems that you haven't loaded the styles. Please import '@xyflow/${t}/dist/style.css' or base.css to make sure everything is working properly.`,error014:()=>"useNodeConnections: No node ID found. Call useNodeConnections inside a custom Node or provide a node ID.",error015:()=>"It seems that you are trying to drag a node that is not initialized. Please use onNodesChange as explained in the docs.",error016:t=>`Edge with id "${t}" does not exist, it may have been removed. This can happen when an edge is deleted before the "onEdgeClick" handler is called.`},ml=[[Number.NEGATIVE_INFINITY,Number.NEGATIVE_INFINITY],[Number.POSITIVE_INFINITY,Number.POSITIVE_INFINITY]],nh=["Enter"," ","Escape"],oh={"node.a11yDescription.default":"Press enter or space to select a node. Press delete to remove it and escape to cancel.","node.a11yDescription.keyboardDisabled":"Press enter or space to select a node. You can then use the arrow keys to move the node around. Press delete to remove it and escape to cancel.","node.a11yDescription.ariaLiveMessage":({direction:t,x:e,y:n})=>`Moved selected node ${t}. New position, x: ${e}, y: ${n}`,"edge.a11yDescription.default":"Press enter or space to select an edge. You can then press delete to remove it or escape to cancel.","controls.ariaLabel":"Control Panel","controls.zoomIn.ariaLabel":"Zoom In","controls.zoomOut.ariaLabel":"Zoom Out","controls.fitView.ariaLabel":"Fit View","controls.interactive.ariaLabel":"Toggle Interactivity","minimap.ariaLabel":"Mini Map","handle.ariaLabel":"Handle"},So;(function(t){t.Strict="strict",t.Loose="loose"})(So||(So={}));var Un;(function(t){t.Free="free",t.Vertical="vertical",t.Horizontal="horizontal"})(Un||(Un={}));var ia;(function(t){t.Partial="partial",t.Full="full"})(ia||(ia={}));var ah={inProgress:!1,isValid:null,from:null,fromHandle:null,fromPosition:null,fromNode:null,to:null,toHandle:null,toPosition:null,toNode:null,pointer:null},rn;(function(t){t.Bezier="default",t.Straight="straight",t.Step="step",t.SmoothStep="smoothstep",t.SimpleBezier="simplebezier"})(rn||(rn={}));var pl;(function(t){t.Arrow="arrow",t.ArrowClosed="arrowclosed"})(pl||(pl={}));var G;(function(t){t.Left="left",t.Top="top",t.Right="right",t.Bottom="bottom"})(G||(G={}));var U1={[G.Left]:G.Right,[G.Right]:G.Left,[G.Top]:G.Bottom,[G.Bottom]:G.Top};function lh(t){return t===null?null:t?"valid":"invalid"}var ih=t=>"id"in t&&"source"in t&&"target"in t,W1=t=>"id"in t&&"position"in t&&!("source"in t)&&!("target"in t),rh=t=>"id"in t&&"internals"in t&&!("source"in t)&&!("target"in t);var Wi=(t,e=[0,0])=>{let{width:n,height:o}=un(t),a=t.origin??e,l=n*a[0],i=o*a[1];return{x:t.position.x-l,y:t.position.y-i}},uh=(t,e={nodeOrigin:[0,0]})=>{if(t.length===0)return{x:0,y:0,width:0,height:0};let n=t.reduce((o,a)=>{let l=typeof a=="string",i=!e.nodeLookup&&!l?a:void 0;e.nodeLookup&&(i=l?e.nodeLookup.get(a):rh(a)?a:e.nodeLookup.get(a.id));let r=i?hc(i,e.nodeOrigin):{x:0,y:0,x2:0,y2:0};return mc(o,r)},{x:1/0,y:1/0,x2:-1/0,y2:-1/0});return yc(n)},yl=(t,e={})=>{let n={x:1/0,y:1/0,x2:-1/0,y2:-1/0},o=!1;return t.forEach(a=>{(e.filter===void 0||e.filter(a))&&(n=mc(n,hc(a)),o=!0)}),o?yc(n):{x:0,y:0,width:0,height:0}},pc=(t,e,[n,o,a]=[0,0,1],l=!1,i=!1)=>{let r={...fa(e,[n,o,a]),width:e.width/a,height:e.height/a},u=[];for(let s of t.values()){let{measured:c,selectable:d=!0,hidden:f=!1}=s;if(i&&!d||f)continue;let p=c.width??s.width??s.initialWidth??null,y=c.height??s.height??s.initialHeight??null,b=vl(r,sa(s)),x=(p??0)*(y??0),g=l&&b>0;(!s.internals.handleBounds||g||b>=x||s.dragging)&&u.push(s)}return u},F1=(t,e)=>{let n=new Set;return t.forEach(o=>{n.add(o.id)}),e.filter(o=>n.has(o.source)||n.has(o.target))};function DM(t,e){let n=new Map,o=e?.nodes?new Set(e.nodes.map(a=>a.id)):null;return t.forEach(a=>{a.measured.width&&a.measured.height&&(e?.includeHiddenNodes||!a.hidden)&&(!o||o.has(a.id))&&n.set(a.id,a)}),n}async function P1({nodes:t,width:e,height:n,panZoom:o,minZoom:a,maxZoom:l},i){if(t.size===0)return!0;let r=DM(t,i),u=yl(r),s=Fi(u,e,n,i?.minZoom??a,i?.maxZoom??l,i?.padding??.1);return await o.setViewport(s,{duration:i?.duration,ease:i?.ease,interpolate:i?.interpolate}),!0}function ch({nodeId:t,nextPosition:e,nodeLookup:n,nodeOrigin:o=[0,0],nodeExtent:a,onError:l}){let i=n.get(t),r=i.parentId?n.get(i.parentId):void 0,{x:u,y:s}=r?r.internals.positionAbsolute:{x:0,y:0},c=i.origin??o,d=i.extent||a;if(i.extent==="parent"&&!i.expandParent)if(!r)l?.("005",Me.error005());else{let p=r.measured.width,y=r.measured.height;p&&y&&(d=[[u,s],[u+p,s+y]])}else r&&ca(i.extent)&&(d=[[i.extent[0][0]+u,i.extent[0][1]+s],[i.extent[1][0]+u,i.extent[1][1]+s]]);let f=ca(d)?ra(e,d,i.measured):e;return(i.measured.width===void 0||i.measured.height===void 0)&&l?.("015",Me.error015()),{position:{x:f.x-u+(i.measured.width??0)*c[0],y:f.y-s+(i.measured.height??0)*c[1]},positionAbsolute:f}}async function tb({nodesToRemove:t=[],edgesToRemove:e=[],nodes:n,edges:o,onBeforeDelete:a}){let l=new Set(t.map(f=>f.id)),i=[];for(let f of n){if(f.deletable===!1)continue;let p=l.has(f.id),y=!p&&f.parentId&&i.find(b=>b.id===f.parentId);(p||y)&&i.push(f)}let r=new Set(e.map(f=>f.id)),u=o.filter(f=>f.deletable!==!1),c=F1(i,u);for(let f of u)r.has(f.id)&&!c.find(y=>y.id===f.id)&&c.push(f);if(!a)return{edges:c,nodes:i};let d=await a({nodes:i,edges:c});return typeof d=="boolean"?d?{edges:c,nodes:i}:{edges:[],nodes:[]}:d}var gl=(t,e=0,n=1)=>Math.min(Math.max(t,e),n),ra=(t={x:0,y:0},e,n)=>({x:gl(t.x,e[0][0],e[1][0]-(n?.width??0)),y:gl(t.y,e[0][1],e[1][1]-(n?.height??0))});function eb(t,e,n){let{width:o,height:a}=un(n),{x:l,y:i}=n.internals.positionAbsolute;return ra(t,[[l,i],[l+o,i+a]],e)}var Y1=(t,e,n)=>t<e?gl(Math.abs(t-e),1,e)/e:t>n?-gl(Math.abs(t-n),1,e)/e:0,gc=(t,e,n=15,o=40)=>{let a=Y1(t.x,o,e.width-o)*n,l=Y1(t.y,o,e.height-o)*n;return[a,l]},mc=(t,e)=>({x:Math.min(t.x,e.x),y:Math.min(t.y,e.y),x2:Math.max(t.x2,e.x2),y2:Math.max(t.y2,e.y2)}),eh=({x:t,y:e,width:n,height:o})=>({x:t,y:e,x2:t+n,y2:e+o}),yc=({x:t,y:e,x2:n,y2:o})=>({x:t,y:e,width:n-t,height:o-e}),sa=(t,e=[0,0])=>{let{x:n,y:o}=rh(t)?t.internals.positionAbsolute:Wi(t,e);return{x:n,y:o,width:t.measured?.width??t.width??t.initialWidth??0,height:t.measured?.height??t.height??t.initialHeight??0}},hc=(t,e=[0,0])=>{let{x:n,y:o}=rh(t)?t.internals.positionAbsolute:Wi(t,e);return{x:n,y:o,x2:n+(t.measured?.width??t.width??t.initialWidth??0),y2:o+(t.measured?.height??t.height??t.initialHeight??0)}},sh=(t,e)=>yc(mc(eh(t),eh(e))),vl=(t,e)=>{let n=Math.max(0,Math.min(t.x+t.width,e.x+e.width)-Math.max(t.x,e.x)),o=Math.max(0,Math.min(t.y+t.height,e.y+e.height)-Math.max(t.y,e.y));return Math.ceil(n*o)},fh=t=>Ye(t.width)&&Ye(t.height)&&Ye(t.x)&&Ye(t.y),Ye=t=>!isNaN(t)&&isFinite(t),dh=(t,e)=>(n,o)=>{},bl=(t,e=[1,1])=>({x:e[0]*Math.round(t.x/e[0]),y:e[1]*Math.round(t.y/e[1])}),fa=({x:t,y:e},[n,o,a],l=!1,i=[1,1])=>{let r={x:(t-n)/a,y:(e-o)/a};return l?bl(r,i):r},ua=({x:t,y:e},[n,o,a])=>({x:t*a+n,y:e*a+o});function dl(t,e){if(typeof t=="number")return Math.floor((e-e/(1+t))*.5);if(typeof t=="string"&&t.endsWith("px")){let n=parseFloat(t);if(!Number.isNaN(n))return Math.floor(n)}if(typeof t=="string"&&t.endsWith("%")){let n=parseFloat(t);if(!Number.isNaN(n))return Math.floor(e*n*.01)}return console.error(`The padding value "${t}" is invalid. Please provide a number or a string with a valid unit (px or %).`),0}function HM(t,e,n){if(typeof t=="string"||typeof t=="number"){let o=dl(t,n),a=dl(t,e);return{top:o,right:a,bottom:o,left:a,x:a*2,y:o*2}}if(typeof t=="object"){let o=dl(t.top??t.y??0,n),a=dl(t.bottom??t.y??0,n),l=dl(t.left??t.x??0,e),i=dl(t.right??t.x??0,e);return{top:o,right:i,bottom:a,left:l,x:l+i,y:o+a}}return{top:0,right:0,bottom:0,left:0,x:0,y:0}}function RM(t,e,n,o,a,l){let{x:i,y:r}=ua(t,[e,n,o]),{x:u,y:s}=ua({x:t.x+t.width,y:t.y+t.height},[e,n,o]),c=a-u,d=l-s;return{left:Math.floor(i),top:Math.floor(r),right:Math.floor(c),bottom:Math.floor(d)}}var Fi=(t,e,n,o,a,l)=>{let i=HM(l,e,n),r=(e-i.x)/t.width,u=(n-i.y)/t.height,s=Math.min(r,u),c=gl(s,o,a),d=t.x+t.width/2,f=t.y+t.height/2,p=e/2-d*c,y=n/2-f*c,b=RM(t,p,y,c,e,n),x={left:Math.min(b.left-i.left,0),top:Math.min(b.top-i.top,0),right:Math.min(b.right-i.right,0),bottom:Math.min(b.bottom-i.bottom,0)};return{x:p-x.left+x.right,y:y-x.top+x.bottom,zoom:c}},xl=()=>typeof navigator<"u"&&navigator?.userAgent?.indexOf("Mac")>=0;function ca(t){return t!=null&&t!=="parent"}function un(t){return{width:t.measured?.width??t.width??t.initialWidth??0,height:t.measured?.height??t.height??t.initialHeight??0}}function hh(t){return(t.measured?.width??t.width??t.initialWidth)!==void 0&&(t.measured?.height??t.height??t.initialHeight)!==void 0}function ph(t,e={width:0,height:0},n,o,a){let l={...t},i=o.get(n);if(i){let r=i.origin||a;l.x+=i.internals.positionAbsolute.x-(e.width??0)*r[0],l.y+=i.internals.positionAbsolute.y-(e.height??0)*r[1]}return l}function gh(t,e){if(t.size!==e.size)return!1;for(let n of t)if(!e.has(n))return!1;return!0}function nb(){let t,e;return{promise:new Promise((o,a)=>{t=o,e=a}),resolve:t,reject:e}}function ob(t){return{...oh,...t||{}}}function Ii(t,{snapGrid:e=[0,0],snapToGrid:n=!1,transform:o,containerBounds:a}){let{x:l,y:i}=Ve(t),r=fa({x:l-(a?.left??0),y:i-(a?.top??0)},o),{x:u,y:s}=n?bl(r,e):r;return{xSnapped:u,ySnapped:s,...r}}var vc=t=>({width:t.offsetWidth,height:t.offsetHeight}),mh=t=>t?.getRootNode?.()||window?.document,BM=["INPUT","SELECT","TEXTAREA"];function yh(t){let e=t.composedPath?.()?.[0]||t.target;return e?.nodeType!==1?!1:BM.includes(e.nodeName)||e.hasAttribute("contenteditable")||!!e.closest(".nokey")}var vh=t=>"clientX"in t,Ve=(t,e)=>{let n=vh(t),o=n?t.clientX:t.touches?.[0].clientX,a=n?t.clientY:t.touches?.[0].clientY;return{x:o-(e?.left??0),y:a-(e?.top??0)}},V1=(t,e,n,o,a)=>{let l=e.querySelectorAll(`.${t}`);return!l||!l.length?null:Array.from(l).map(i=>{let r=i.getBoundingClientRect();return{id:i.getAttribute("data-handleid"),type:t,nodeId:a,position:i.getAttribute("data-handlepos"),x:(r.left-n.left)/o,y:(r.top-n.top)/o,...vc(i)}})};function bc({sourceX:t,sourceY:e,targetX:n,targetY:o,sourceControlX:a,sourceControlY:l,targetControlX:i,targetControlY:r}){let u=t*.125+a*.375+i*.375+n*.125,s=e*.125+l*.375+r*.375+o*.125,c=Math.abs(u-t),d=Math.abs(s-e);return[u,s,c,d]}function fc(t,e){return t>=0?.5*t:e*25*Math.sqrt(-t)}function q1({pos:t,x1:e,y1:n,x2:o,y2:a,c:l}){switch(t){case G.Left:return[e-fc(e-o,l),n];case G.Right:return[e+fc(o-e,l),n];case G.Top:return[e,n-fc(n-a,l)];case G.Bottom:return[e,n+fc(a-n,l)]}}function xc({sourceX:t,sourceY:e,sourcePosition:n=G.Bottom,targetX:o,targetY:a,targetPosition:l=G.Top,curvature:i=.25}){let[r,u]=q1({pos:n,x1:t,y1:e,x2:o,y2:a,c:i}),[s,c]=q1({pos:l,x1:o,y1:a,x2:t,y2:e,c:i}),[d,f,p,y]=bc({sourceX:t,sourceY:e,targetX:o,targetY:a,sourceControlX:r,sourceControlY:u,targetControlX:s,targetControlY:c});return[`M${t},${e} C${r},${u} ${s},${c} ${o},${a}`,d,f,p,y]}function bh({sourceX:t,sourceY:e,targetX:n,targetY:o}){let a=Math.abs(n-t)/2,l=n<t?n+a:n-a,i=Math.abs(o-e)/2,r=o<e?o+i:o-i;return[l,r,a,i]}function ab({sourceNode:t,targetNode:e,selected:n=!1,zIndex:o=0,elevateOnSelect:a=!1,zIndexMode:l="basic"}){if(l==="manual")return o;let i=a&&n?o+1e3:o,r=Math.max(t.parentId||a&&t.selected?t.internals.z:0,e.parentId||a&&e.selected?e.internals.z:0);return i+r}function lb({sourceNode:t,targetNode:e,width:n,height:o,transform:a}){let l=mc(hc(t),hc(e));l.x===l.x2&&(l.x2+=1),l.y===l.y2&&(l.y2+=1);let i={x:-a[0]/a[2],y:-a[1]/a[2],width:n/a[2],height:o/a[2]};return vl(i,yc(l))>0}var kM=({source:t,sourceHandle:e,target:n,targetHandle:o})=>`xy-edge__${t}${e||""}-${n}${o||""}`,LM=(t,e)=>e.some(n=>n.source===t.source&&n.target===t.target&&(n.sourceHandle===t.sourceHandle||!n.sourceHandle&&!t.sourceHandle)&&(n.targetHandle===t.targetHandle||!n.targetHandle&&!t.targetHandle)),ib=(t,e,n={})=>{if(!t.source||!t.target)return n.onError?.("006",Me.error006()),e;let o=n.getEdgeId||kM,a;return ih(t)?a={...t}:a={...t,id:o(t)},LM(a,e)?e:(a.sourceHandle===null&&delete a.sourceHandle,a.targetHandle===null&&delete a.targetHandle,e.concat(a))};function Sc({sourceX:t,sourceY:e,targetX:n,targetY:o}){let[a,l,i,r]=bh({sourceX:t,sourceY:e,targetX:n,targetY:o});return[`M ${t},${e}L ${n},${o}`,a,l,i,r]}var X1={[G.Left]:{x:-1,y:0},[G.Right]:{x:1,y:0},[G.Top]:{x:0,y:-1},[G.Bottom]:{x:0,y:1}},UM=({source:t,sourcePosition:e=G.Bottom,target:n})=>e===G.Left||e===G.Right?t.x<n.x?{x:1,y:0}:{x:-1,y:0}:t.y<n.y?{x:0,y:1}:{x:0,y:-1},Z1=(t,e)=>Math.sqrt(Math.pow(e.x-t.x,2)+Math.pow(e.y-t.y,2));function YM({source:t,sourcePosition:e=G.Bottom,target:n,targetPosition:o=G.Top,center:a,offset:l,stepPosition:i}){let r=X1[e],u=X1[o],s={x:t.x+r.x*l,y:t.y+r.y*l},c={x:n.x+u.x*l,y:n.y+u.y*l},d=UM({source:s,sourcePosition:e,target:c}),f=d.x!==0?"x":"y",p=d[f],y=[],b,x,g={x:0,y:0},m={x:0,y:0},[,,h,v]=bh({sourceX:t.x,sourceY:t.y,targetX:n.x,targetY:n.y});if(r[f]*u[f]===-1){f==="x"?(b=a.x??s.x+(c.x-s.x)*i,x=a.y??(s.y+c.y)/2):(b=a.x??(s.x+c.x)/2,x=a.y??s.y+(c.y-s.y)*i);let N=[{x:b,y:s.y},{x:b,y:c.y}],M=[{x:s.x,y:x},{x:c.x,y:x}];r[f]===p?y=f==="x"?N:M:y=f==="x"?M:N}else{let N=[{x:s.x,y:c.y}],M=[{x:c.x,y:s.y}];if(f==="x"?y=r.x===p?M:N:y=r.y===p?N:M,e===o){let S=Math.abs(t[f]-n[f]);if(S<=l){let A=Math.min(l-1,l-S);r[f]===p?g[f]=(s[f]>t[f]?-1:1)*A:m[f]=(c[f]>n[f]?-1:1)*A}}if(e!==o){let S=f==="x"?"y":"x",A=r[f]===u[S],z=s[S]>c[S],T=s[S]<c[S];(r[f]===1&&(!A&&z||A&&T)||r[f]!==1&&(!A&&T||A&&z))&&(y=f==="x"?N:M)}let R={x:s.x+g.x,y:s.y+g.y},C={x:c.x+m.x,y:c.y+m.y},k=Math.max(Math.abs(R.x-y[0].x),Math.abs(C.x-y[0].x)),V=Math.max(Math.abs(R.y-y[0].y),Math.abs(C.y-y[0].y));k>=V?(b=(R.x+C.x)/2,x=y[0].y):(b=y[0].x,x=(R.y+C.y)/2)}let _={x:s.x+g.x,y:s.y+g.y},E={x:c.x+m.x,y:c.y+m.y};return[[t,..._.x!==y[0].x||_.y!==y[0].y?[_]:[],...y,...E.x!==y[y.length-1].x||E.y!==y[y.length-1].y?[E]:[],n],b,x,h,v]}function VM(t,e,n,o){let a=Math.min(Z1(t,e)/2,Z1(e,n)/2,o),{x:l,y:i}=e;if(t.x===l&&l===n.x||t.y===i&&i===n.y)return`L${l} ${i}`;if(t.y===i){let s=t.x<n.x?-1:1,c=t.y<n.y?1:-1;return`L ${l+a*s},${i}Q ${l},${i} ${l},${i+a*c}`}let r=t.x<n.x?1:-1,u=t.y<n.y?-1:1;return`L ${l},${i+a*u}Q ${l},${i} ${l+a*r},${i}`}function da({sourceX:t,sourceY:e,sourcePosition:n=G.Bottom,targetX:o,targetY:a,targetPosition:l=G.Top,borderRadius:i=5,centerX:r,centerY:u,offset:s=20,stepPosition:c=.5}){let[d,f,p,y,b]=YM({source:{x:t,y:e},sourcePosition:n,target:{x:o,y:a},targetPosition:l,center:{x:r,y:u},offset:s,stepPosition:c}),x=`M${d[0].x} ${d[0].y}`;for(let g=1;g<d.length-1;g++)x+=VM(d[g-1],d[g],d[g+1],i);return x+=`L${d[d.length-1].x} ${d[d.length-1].y}`,[x,f,p,y,b]}function G1(t){return t&&!!(t.internals.handleBounds||t.handles?.length)&&!!(t.measured.width||t.width||t.initialWidth)}function rb(t){let{sourceNode:e,targetNode:n}=t;if(!G1(e)||!G1(n))return null;let o=e.internals.handleBounds||Q1(e.handles),a=n.internals.handleBounds||Q1(n.handles),l=j1(o?.source??[],t.sourceHandle),i=j1(t.connectionMode===So.Strict?a?.target??[]:(a?.target??[]).concat(a?.source??[]),t.targetHandle);if(!l||!i)return t.onError?.("008",Me.error008(l?"target":"source",{id:t.id,sourceHandle:t.sourceHandle,targetHandle:t.targetHandle})),null;let r=l?.position||G.Bottom,u=i?.position||G.Top,s=_o(e,l,r),c=_o(n,i,u);return{sourceX:s.x,sourceY:s.y,targetX:c.x,targetY:c.y,sourcePosition:r,targetPosition:u}}function Q1(t){if(!t)return null;let e=[],n=[];for(let o of t)o.width=o.width??1,o.height=o.height??1,o.type==="source"?e.push(o):o.type==="target"&&n.push(o);return{source:e,target:n}}function _o(t,e,n=G.Left,o=!1){let a=(e?.x??0)+t.internals.positionAbsolute.x,l=(e?.y??0)+t.internals.positionAbsolute.y,{width:i,height:r}=e??un(t);if(o)return{x:a+i/2,y:l+r/2};switch(e?.position??n){case G.Top:return{x:a+i/2,y:l};case G.Right:return{x:a+i,y:l+r/2};case G.Bottom:return{x:a+i/2,y:l+r};case G.Left:return{x:a,y:l+r/2}}}function j1(t,e){return t&&(e?t.find(n=>n.id===e):t[0])||null}function _c(t,e){return t?typeof t=="string"?t:`${e?`${e}__`:""}${Object.keys(t).sort().map(o=>`${o}=${t[o]}`).join("&")}`:""}function ub(t,{id:e,defaultColor:n,defaultMarkerStart:o,defaultMarkerEnd:a}){let l=new Set;return t.reduce((i,r)=>([r.markerStart||o,r.markerEnd||a].forEach(u=>{if(u&&typeof u=="object"){let s=_c(u,e);l.has(s)||(i.push({id:s,color:u.color||n,...u}),l.add(s))}}),i),[]).sort((i,r)=>i.id.localeCompare(r.id))}var cb=1e3,qM=10,xh={nodeOrigin:[0,0],nodeExtent:ml,elevateNodesOnSelect:!0,zIndexMode:"basic",defaults:{}},XM={...xh,checkEquality:!0};function Sh(t,e){let n={...t};for(let o in e)e[o]!==void 0&&(n[o]=e[o]);return n}function sb(t,e,n){let o=Sh(xh,n);for(let a of t.values())if(a.parentId)wh(a,t,e,o);else{let l=Wi(a,o.nodeOrigin),i=ca(a.extent)?a.extent:o.nodeExtent,r=ra(l,i,un(a));a.internals.positionAbsolute=r}}function ZM(t,e){if(!t.handles)return t.measured?e?.internals.handleBounds:void 0;let n=[],o=[];for(let a of t.handles){let l={id:a.id,width:a.width??1,height:a.height??1,nodeId:t.id,x:a.x,y:a.y,position:a.position,type:a.type};a.type==="source"?n.push(l):a.type==="target"&&o.push(l)}return{source:n,target:o}}function _h(t){return t==="manual"}function wc(t,e,n,o={}){let a=Sh(XM,o),l={i:0},i=new Map(e),r=a?.elevateNodesOnSelect&&!_h(a.zIndexMode)?cb:0,u=t.length>0,s=!1;e.clear(),n.clear();for(let c of t){let d=i.get(c.id);if(a.checkEquality&&c===d?.internals.userNode)e.set(c.id,d);else{let f=Wi(c,a.nodeOrigin),p=ca(c.extent)?c.extent:a.nodeExtent,y=ra(f,p,un(c));d={...a.defaults,...c,measured:{width:c.measured?.width,height:c.measured?.height},internals:{positionAbsolute:y,handleBounds:ZM(c,d),z:fb(c,r,a.zIndexMode),userNode:c}},e.set(c.id,d)}(d.measured===void 0||d.measured.width===void 0||d.measured.height===void 0)&&!d.hidden&&(u=!1),c.parentId&&wh(d,e,n,o,l),s||(s=c.selected??!1)}return{nodesInitialized:u,hasSelectedNodes:s}}function GM(t,e){if(!t.parentId)return;let n=e.get(t.parentId);n?n.set(t.id,t):e.set(t.parentId,new Map([[t.id,t]]))}function wh(t,e,n,o,a){let{elevateNodesOnSelect:l,nodeOrigin:i,nodeExtent:r,zIndexMode:u}=Sh(xh,o),s=t.parentId,c=e.get(s);if(!c){console.warn(`Parent node ${s} not found. Please make sure that parent nodes are in front of their child nodes in the nodes array.`);return}GM(t,n),a&&!c.parentId&&c.internals.rootParentIndex===void 0&&u==="auto"&&(c.internals.rootParentIndex=++a.i,c.internals.z=c.internals.z+a.i*qM),a&&c.internals.rootParentIndex!==void 0&&(a.i=c.internals.rootParentIndex);let d=l&&!_h(u)?cb:0,{x:f,y:p,z:y}=QM(t,c,i,r,d,u),{positionAbsolute:b}=t.internals,x=f!==b.x||p!==b.y;(x||y!==t.internals.z)&&e.set(t.id,{...t,internals:{...t.internals,positionAbsolute:x?{x:f,y:p}:b,z:y}})}function fb(t,e,n){let o=Ye(t.zIndex)?t.zIndex:0;return _h(n)?o:o+(t.selected?e:0)}function QM(t,e,n,o,a,l){let{x:i,y:r}=e.internals.positionAbsolute,u=un(t),s=Wi(t,n),c=ca(t.extent)?ra(s,t.extent,u):s,d=ra({x:i+c.x,y:r+c.y},o,u);t.extent==="parent"&&(d=eb(d,u,e));let f=fb(t,a,l),p=e.internals.z??0;return{x:d.x,y:d.y,z:p>=f?p+1:f}}function Ec(t,e,n,o=[0,0]){let a=[],l=new Map;for(let i of t){let r=e.get(i.parentId);if(!r)continue;let u=l.get(i.parentId)?.expandedRect??sa(r),s=sh(u,i.rect);l.set(i.parentId,{expandedRect:s,parent:r})}return l.size>0&&l.forEach(({expandedRect:i,parent:r},u)=>{let s=r.internals.positionAbsolute,c=un(r),d=r.origin??o,f=i.x<s.x?Math.round(Math.abs(s.x-i.x)):0,p=i.y<s.y?Math.round(Math.abs(s.y-i.y)):0,y=Math.max(c.width,Math.round(i.width)),b=Math.max(c.height,Math.round(i.height)),x=(y-c.width)*d[0],g=(b-c.height)*d[1];(f>0||p>0||x||g)&&(a.push({id:u,type:"position",position:{x:r.position.x-f+x,y:r.position.y-p+g}}),n.get(u)?.forEach(m=>{t.some(h=>h.id===m.id)||a.push({id:m.id,type:"position",position:{x:m.position.x+f,y:m.position.y+p}})})),(c.width<i.width||c.height<i.height||f||p)&&a.push({id:u,type:"dimensions",setAttributes:!0,dimensions:{width:y+(f?d[0]*f-x:0),height:b+(p?d[1]*p-g:0)}})}),a}function db(t,e,n,o,a,l,i){let r=o?.querySelector(".xyflow__viewport"),u=!1;if(!r)return{changes:[],updatedInternals:u};let s=[],c=window.getComputedStyle(r),{m22:d}=new window.DOMMatrixReadOnly(c.transform),f=[];for(let p of t.values()){let y=e.get(p.id);if(!y)continue;if(y.hidden){e.set(y.id,{...y,internals:{...y.internals,handleBounds:void 0}}),u=!0;continue}let b=vc(p.nodeElement),x=y.measured.width!==b.width||y.measured.height!==b.height;if(!!(b.width&&b.height&&(x||!y.internals.handleBounds||p.force))){let m=p.nodeElement.getBoundingClientRect(),h=ca(y.extent)?y.extent:l,{positionAbsolute:v}=y.internals;y.parentId&&y.extent==="parent"?v=eb(v,b,e.get(y.parentId)):h&&(v=ra(v,h,b));let _={...y,measured:b,internals:{...y.internals,positionAbsolute:v,handleBounds:{source:V1("source",p.nodeElement,m,d,y.id),target:V1("target",p.nodeElement,m,d,y.id)}}};e.set(y.id,_),y.parentId&&wh(_,e,n,{nodeOrigin:a,zIndexMode:i}),u=!0,x&&(s.push({id:y.id,type:"dimensions",dimensions:b}),y.expandParent&&y.parentId&&f.push({id:y.id,parentId:y.parentId,rect:sa(_,a)}))}}if(f.length>0){let p=Ec(f,e,n,a);s.push(...p)}return{changes:s,updatedInternals:u}}async function hb({delta:t,panZoom:e,transform:n,translateExtent:o,width:a,height:l}){if(!e||!t.x&&!t.y)return!1;let i=await e.setViewportConstrained({x:n[0]+t.x,y:n[1]+t.y,zoom:n[2]},[[0,0],[a,l]],o);return!!i&&(i.x!==n[0]||i.y!==n[1]||i.k!==n[2])}function K1(t,e,n,o,a,l){let i=a,r=o.get(i)||new Map;o.set(i,r.set(n,e)),i=`${a}-${t}`;let u=o.get(i)||new Map;if(o.set(i,u.set(n,e)),l){i=`${a}-${t}-${l}`;let s=o.get(i)||new Map;o.set(i,s.set(n,e))}}function Eh(t,e,n){t.clear(),e.clear();for(let o of n){let{source:a,target:l,sourceHandle:i=null,targetHandle:r=null}=o,u={edgeId:o.id,source:a,target:l,sourceHandle:i,targetHandle:r},s=`${a}-${i}--${l}-${r}`,c=`${l}-${r}--${a}-${i}`;K1("source",u,c,t,a,i),K1("target",u,s,t,l,r),e.set(o.id,o)}}function pb(t,e){if(!t.parentId)return!1;let n=e.get(t.parentId);return n?n.selected?!0:pb(n,e):!1}function $1(t,e,n){let o=t;do{if(o?.matches?.(e))return!0;if(o===n)return!1;o=o?.parentElement}while(o);return!1}function jM(t,e,n,o){let a=new Map;for(let[l,i]of t)if((i.selected||i.id===o)&&(!i.parentId||!pb(i,t))&&(i.draggable||e&&typeof i.draggable>"u")){let r=t.get(l);r&&a.set(l,{id:l,position:r.position||{x:0,y:0},distance:{x:n.x-r.internals.positionAbsolute.x,y:n.y-r.internals.positionAbsolute.y},extent:r.extent,parentId:r.parentId,origin:r.origin,expandParent:r.expandParent,internals:{positionAbsolute:r.internals.positionAbsolute||{x:0,y:0}},measured:{width:r.measured.width??0,height:r.measured.height??0}})}return a}function Fd({nodeId:t,dragItems:e,nodeLookup:n,dragging:o=!0}){let a=[];for(let[i,r]of e){let u=n.get(i)?.internals.userNode;u&&a.push({...u,position:r.position,dragging:o})}if(!t)return[a[0],a];let l=n.get(t)?.internals.userNode;return[l?{...l,position:e.get(t)?.position||l.position,dragging:o}:a[0],a]}function KM({dragItems:t,snapGrid:e,x:n,y:o}){let a=t.values().next().value;if(!a)return null;let l={x:n-a.distance.x,y:o-a.distance.y},i=bl(l,e);return{x:i.x-l.x,y:i.y-l.y}}function gb({onNodeMouseDown:t,getStoreItems:e,onDragStart:n,onDrag:o,onDragStop:a}){let l={x:null,y:null},i=0,r=new Map,u=!1,s={x:0,y:0},c=null,d=!1,f=null,p=!1,y=!1,b=null;function x({noDragClassName:m,handleSelector:h,domNode:v,isSelectable:_,nodeId:E,nodeClickDistance:w=0}){f=Qt(v);function N({x:k,y:V}){let{nodeLookup:S,nodeExtent:A,snapGrid:z,snapToGrid:T,nodeOrigin:B,onNodeDrag:H,onSelectionDrag:X,onError:Z,updateNodePositions:q}=e();l={x:k,y:V};let K=!1,j=r.size>1,I=j&&A?eh(yl(r)):null,ot=j&&T?KM({dragItems:r,snapGrid:z,x:k,y:V}):null;for(let[J,U]of r){if(!S.has(J))continue;let Q={x:k-U.distance.x,y:V-U.distance.y};T&&(Q=ot?{x:Math.round(Q.x+ot.x),y:Math.round(Q.y+ot.y)}:bl(Q,z));let nt=null;if(j&&A&&!U.extent&&I){let{positionAbsolute:W}=U.internals,ct=W.x-I.x+A[0][0],dt=W.x+U.measured.width-I.x2+A[1][0],Dt=W.y-I.y+A[0][1],ie=W.y+U.measured.height-I.y2+A[1][1];nt=[[ct,Dt],[dt,ie]]}let{position:tt,positionAbsolute:$}=ch({nodeId:J,nextPosition:Q,nodeLookup:S,nodeExtent:nt||A,nodeOrigin:B,onError:Z});K=K||U.position.x!==tt.x||U.position.y!==tt.y,U.position=tt,U.internals.positionAbsolute=$}if(y=y||K,!!K&&(q(r,!0),b&&(o||H||!E&&X))){let[J,U]=Fd({nodeId:E,dragItems:r,nodeLookup:S});o?.(b,r,J,U),H?.(b,J,U),E||X?.(b,U)}}async function M(){if(!c)return;let{transform:k,panBy:V,autoPanSpeed:S,autoPanOnNodeDrag:A}=e();if(!A){u=!1,cancelAnimationFrame(i);return}let[z,T]=gc(s,c,S);(z!==0||T!==0)&&(l.x=(l.x??0)-z/k[2],l.y=(l.y??0)-T/k[2],await V({x:z,y:T})&&N(l)),i=requestAnimationFrame(M)}function R(k){let{nodeLookup:V,multiSelectionActive:S,nodesDraggable:A,transform:z,snapGrid:T,snapToGrid:B,selectNodesOnDrag:H,onNodeDragStart:X,onSelectionDragStart:Z,unselectNodesAndEdges:q}=e();d=!0,(!H||!_)&&!S&&E&&(V.get(E)?.selected||q()),_&&H&&E&&t?.(E);let K=Ii(k.sourceEvent,{transform:z,snapGrid:T,snapToGrid:B,containerBounds:c});if(l=K,r=jM(V,A,K,E),r.size>0&&(n||X||!E&&Z)){let[j,I]=Fd({nodeId:E,dragItems:r,nodeLookup:V});n?.(k.sourceEvent,r,j,I),X?.(k.sourceEvent,j,I),E||Z?.(k.sourceEvent,I)}}let C=Zu().clickDistance(w).on("start",k=>{let{domNode:V,nodeDragThreshold:S,transform:A,snapGrid:z,snapToGrid:T}=e();c=V?.getBoundingClientRect()||null,p=!1,y=!1,b=k.sourceEvent,S===0&&R(k),l=Ii(k.sourceEvent,{transform:A,snapGrid:z,snapToGrid:T,containerBounds:c}),s=Ve(k.sourceEvent,c)}).on("drag",k=>{let{autoPanOnNodeDrag:V,transform:S,snapGrid:A,snapToGrid:z,nodeDragThreshold:T,nodeLookup:B}=e(),H=Ii(k.sourceEvent,{transform:S,snapGrid:A,snapToGrid:z,containerBounds:c});if(b=k.sourceEvent,(k.sourceEvent.type==="touchmove"&&k.sourceEvent.touches.length>1||E&&!B.has(E))&&(p=!0),!p){if(!u&&V&&d&&(u=!0,M()),!d){let X=Ve(k.sourceEvent,c),Z=X.x-s.x,q=X.y-s.y;Math.sqrt(Z*Z+q*q)>T&&R(k)}(l.x!==H.xSnapped||l.y!==H.ySnapped)&&r&&d&&(s=Ve(k.sourceEvent,c),N(H))}}).on("end",k=>{if(!d||p){p&&r.size>0&&e().updateNodePositions(r,!1);return}if(u=!1,d=!1,cancelAnimationFrame(i),r.size>0){let{nodeLookup:V,updateNodePositions:S,onNodeDragStop:A,onSelectionDragStop:z}=e();if(y&&(S(r,!1),y=!1),a||A||!E&&z){let[T,B]=Fd({nodeId:E,dragItems:r,nodeLookup:V,dragging:!1});a?.(k.sourceEvent,r,T,B),A?.(k.sourceEvent,T,B),E||z?.(k.sourceEvent,B)}}}).filter(k=>{let V=k.target;return!k.button&&(!m||!$1(V,`.${m}`,v))&&(!h||$1(V,h,v))});f.call(C)}function g(){f?.on(".drag",null)}return{update:x,destroy:g}}function $M(t,e,n){let o=[],a={x:t.x-n,y:t.y-n,width:n*2,height:n*2};for(let l of e.values())vl(a,sa(l))>0&&o.push(l);return o}var JM=250;function IM(t,e,n,o){let a=[],l=1/0,i=$M(t,n,e+JM);for(let r of i){let u=[...r.internals.handleBounds?.source??[],...r.internals.handleBounds?.target??[]];for(let s of u){if(o.nodeId===s.nodeId&&o.type===s.type&&o.id===s.id)continue;let{x:c,y:d}=_o(r,s,s.position,!0),f=Math.sqrt(Math.pow(c-t.x,2)+Math.pow(d-t.y,2));f>e||(f<l?(a=[{...s,x:c,y:d}],l=f):f===l&&a.push({...s,x:c,y:d}))}}if(!a.length)return null;if(a.length>1){let r=o.type==="source"?"target":"source";return a.find(u=>u.type===r)??a[0]}return a[0]}function mb(t,e,n,o,a,l=!1){let i=o.get(t);if(!i)return null;let r=a==="strict"?i.internals.handleBounds?.[e]:[...i.internals.handleBounds?.source??[],...i.internals.handleBounds?.target??[]],u=(n?r?.find(s=>s.id===n):r?.[0])??null;return u&&l?{...u,..._o(i,u,u.position,!0)}:u}function yb(t,e){return t||(e?.classList.contains("target")?"target":e?.classList.contains("source")?"source":null)}function WM(t,e){let n=null;return e?n=!0:t&&!e&&(n=!1),n}var vb=()=>!0;function FM(t,{connectionMode:e,connectionRadius:n,handleId:o,nodeId:a,edgeUpdaterType:l,isTarget:i,domNode:r,nodeLookup:u,lib:s,autoPanOnConnect:c,flowId:d,panBy:f,cancelConnection:p,onConnectStart:y,onConnect:b,onConnectEnd:x,isValidConnection:g=vb,onReconnectEnd:m,updateConnection:h,getTransform:v,getFromHandle:_,autoPanSpeed:E,dragThreshold:w=1,handleDomNode:N}){let M=mh(t.target),R=0,C,{x:k,y:V}=Ve(t),S=yb(l,N),A=r?.getBoundingClientRect(),z=!1;if(!A||!S)return;let T=mb(a,S,o,u,e);if(!T)return;let B=Ve(t,A),H=!1,X=null,Z=!1,q=null;function K(){if(!c||!A)return;let[tt,$]=gc(B,A,E);f({x:tt,y:$}),R=requestAnimationFrame(K)}let j={...T,nodeId:a,type:S,position:T.position},I=u.get(a),J={inProgress:!0,isValid:null,from:_o(I,j,G.Left,!0),fromHandle:j,fromPosition:j.position,fromNode:I,to:B,toHandle:null,toPosition:U1[j.position],toNode:null,pointer:B};function U(){z=!0,h(J),y?.(t,{nodeId:a,handleId:o,handleType:S})}w===0&&U();function Q(tt){if(!z){let{x:ie,y:cn}=Ve(tt),Je=ie-k,Ie=cn-V;if(!(Je*Je+Ie*Ie>w*w))return;U()}if(!_()||!j){nt(tt);return}let $=v();B=Ve(tt,A),C=IM(fa(B,$,!1,[1,1]),n,u,j),H||(K(),H=!0);let W=bb(tt,{handle:C,connectionMode:e,fromNodeId:a,fromHandleId:o,fromType:i?"target":"source",isValidConnection:g,doc:M,lib:s,flowId:d,nodeLookup:u});q=W.handleDomNode,X=W.connection,Z=WM(!!C,W.isValid);let ct=u.get(a),dt=ct?_o(ct,j,G.Left,!0):J.from,Dt={...J,from:dt,isValid:Z,to:W.toHandle&&Z?ua({x:W.toHandle.x,y:W.toHandle.y},$):B,toHandle:W.toHandle,toPosition:Z&&W.toHandle?W.toHandle.position:U1[j.position],toNode:W.toHandle?u.get(W.toHandle.nodeId):null,pointer:B};h(Dt),J=Dt}function nt(tt){if(!("touches"in tt&&tt.touches.length>0)){if(z){(C||q)&&X&&Z&&b?.(X);let{inProgress:$,...W}=J,ct={...W,toPosition:J.toHandle?J.toPosition:null};x?.(tt,ct),l&&m?.(tt,ct)}p(),cancelAnimationFrame(R),H=!1,Z=!1,X=null,q=null,M.removeEventListener("mousemove",Q),M.removeEventListener("mouseup",nt),M.removeEventListener("touchmove",Q),M.removeEventListener("touchend",nt)}}M.addEventListener("mousemove",Q),M.addEventListener("mouseup",nt),M.addEventListener("touchmove",Q),M.addEventListener("touchend",nt)}function bb(t,{handle:e,connectionMode:n,fromNodeId:o,fromHandleId:a,fromType:l,doc:i,lib:r,flowId:u,isValidConnection:s=vb,nodeLookup:c}){let d=l==="target",f=e?i.querySelector(`.${r}-flow__handle[data-id="${u}-${e?.nodeId}-${e?.id}-${e?.type}"]`):null,{x:p,y}=Ve(t),b=i.elementFromPoint(p,y),x=b?.classList.contains(`${r}-flow__handle`)?b:f,g={handleDomNode:x,isValid:!1,connection:null,toHandle:null};if(x){let m=yb(void 0,x),h=x.getAttribute("data-nodeid"),v=x.getAttribute("data-handleid"),_=x.classList.contains("connectable"),E=x.classList.contains("connectableend");if(!h||!m)return g;let w={source:d?h:o,sourceHandle:d?v:a,target:d?o:h,targetHandle:d?a:v};g.connection=w;let M=_&&E&&(n===So.Strict?d&&m==="source"||!d&&m==="target":h!==o||v!==a);g.isValid=M&&s(w),g.toHandle=mb(h,m,v,c,n,!0)}return g}var Nc={onPointerDown:FM,isValid:bb};function xb({domNode:t,panZoom:e,getTransform:n,getViewScale:o}){let a=Qt(t);function l({translateExtent:r,width:u,height:s,zoomStep:c=1,pannable:d=!0,zoomable:f=!0,inversePan:p=!1}){let y=h=>{if(h.sourceEvent.type!=="wheel"||!e)return;let v=n(),_=h.sourceEvent.ctrlKey&&xl()?10:1,E=-h.sourceEvent.deltaY*(h.sourceEvent.deltaMode===1?.05:h.sourceEvent.deltaMode?1:.002)*c,w=v[2]*Math.pow(2,E*_);e.scaleTo(w)},b=[0,0],x=h=>{(h.sourceEvent.type==="mousedown"||h.sourceEvent.type==="touchstart")&&(b=[h.sourceEvent.clientX??h.sourceEvent.touches[0].clientX,h.sourceEvent.clientY??h.sourceEvent.touches[0].clientY])},g=h=>{let v=n();if(h.sourceEvent.type!=="mousemove"&&h.sourceEvent.type!=="touchmove"||!e)return;let _=[h.sourceEvent.clientX??h.sourceEvent.touches[0].clientX,h.sourceEvent.clientY??h.sourceEvent.touches[0].clientY],E=[_[0]-b[0],_[1]-b[1]];b=_;let w=o()*Math.max(v[2],Math.log(v[2]))*(p?-1:1),N={x:v[0]-E[0]*w,y:v[1]-E[1]*w},M=[[0,0],[u,s]];e.setViewportConstrained({x:N.x,y:N.y,zoom:v[2]},M,r)},m=sc().on("start",x).on("zoom",d?g:null).on("zoom.wheel",f?y:null);a.call(m,{})}function i(){a.on("zoom",null)}return{update:l,destroy:i,pointer:oe}}var Mc=t=>({x:t.x,y:t.y,zoom:t.k}),Pd=({x:t,y:e,zoom:n})=>la.translate(t,e).scale(n),hl=(t,e)=>t.target.closest(`.${e}`),Sb=(t,e)=>e===2&&Array.isArray(t)&&t.includes(2),PM=t=>((t*=2)<=1?t*t*t:(t-=2)*t*t+2)/2,th=(t,e=0,n=PM,o=()=>{})=>{let a=typeof e=="number"&&e>0;return a||o(),a?t.transition().duration(e).ease(n).on("end",o):t},_b=t=>{let e=t.ctrlKey&&xl()?10:1;return-t.deltaY*(t.deltaMode===1?.05:t.deltaMode?1:.002)*e};function tz({zoomPanValues:t,noWheelClassName:e,d3Selection:n,d3Zoom:o,panOnScrollMode:a,panOnScrollSpeed:l,zoomOnPinch:i,onPanZoomStart:r,onPanZoom:u,onPanZoomEnd:s}){return c=>{if(hl(c,e))return c.ctrlKey&&c.preventDefault(),!1;c.preventDefault(),c.stopImmediatePropagation();let d=n.property("__zoom").k||1;if(c.ctrlKey&&i){let x=oe(c),g=_b(c),m=d*Math.pow(2,g);o.scaleTo(n,m,x,c);return}let f=c.deltaMode===1?20:1,p=a===Un.Vertical?0:c.deltaX*f,y=a===Un.Horizontal?0:c.deltaY*f;!xl()&&c.shiftKey&&a!==Un.Vertical&&(p=c.deltaY*f,y=0),o.translateBy(n,-(p/d)*l,-(y/d)*l,{internal:!0});let b=Mc(n.property("__zoom"));clearTimeout(t.panScrollTimeout),t.isPanScrolling?(u?.(c,b),t.panScrollTimeout=setTimeout(()=>{s?.(c,b),t.isPanScrolling=!1},150)):(t.isPanScrolling=!0,r?.(c,b))}}function ez({noWheelClassName:t,preventScrolling:e,d3ZoomHandler:n}){return function(o,a){let l=o.type==="wheel",i=!e&&l&&!o.ctrlKey,r=hl(o,t);if(o.ctrlKey&&l&&r&&o.preventDefault(),i||r)return null;o.preventDefault(),n.call(this,o,a)}}function nz({zoomPanValues:t,onDraggingChange:e,onPanZoomStart:n}){return o=>{if(o.sourceEvent?.internal)return;let a=Mc(o.transform);t.mouseButton=o.sourceEvent?.button||0,t.isZoomingOrPanning=!0,t.prevViewport=a,o.sourceEvent?.type==="mousedown"&&e(!0),n&&n?.(o.sourceEvent,a)}}function oz({zoomPanValues:t,panOnDrag:e,onPaneContextMenu:n,onTransformChange:o,onPanZoom:a}){return l=>{t.usedRightMouseButton=!!(n&&Sb(e,t.mouseButton??0)),l.sourceEvent?.sync||o([l.transform.x,l.transform.y,l.transform.k]),a&&!l.sourceEvent?.internal&&a?.(l.sourceEvent,Mc(l.transform))}}function az({zoomPanValues:t,panOnDrag:e,panOnScroll:n,onDraggingChange:o,onPanZoomEnd:a,onPaneContextMenu:l}){return i=>{if(!i.sourceEvent?.internal&&(t.isZoomingOrPanning=!1,l&&Sb(e,t.mouseButton??0)&&!t.usedRightMouseButton&&i.sourceEvent&&l(i.sourceEvent),t.usedRightMouseButton=!1,o(!1),a)){let r=Mc(i.transform);t.prevViewport=r,clearTimeout(t.timerId),t.timerId=setTimeout(()=>{a?.(i.sourceEvent,r)},n?150:0)}}}function lz({zoomActivationKeyPressed:t,zoomOnScroll:e,zoomOnPinch:n,panOnDrag:o,panOnScroll:a,zoomOnDoubleClick:l,userSelectionActive:i,noWheelClassName:r,noPanClassName:u,lib:s,connectionInProgress:c}){return d=>{let f=t||e,p=n&&d.ctrlKey,y=d.type==="wheel";if(d.button===1&&d.type==="mousedown"&&(hl(d,`${s}-flow__node`)||hl(d,`${s}-flow__edge`)))return!0;if(!o&&!f&&!a&&!l&&!n||i||c&&!y||hl(d,r)&&y||hl(d,u)&&(!y||a&&y&&!t)||!n&&d.ctrlKey&&y)return!1;if(!n&&d.type==="touchstart"&&d.touches?.length>1)return d.preventDefault(),!1;if(!f&&!a&&!p&&y||!o&&(d.type==="mousedown"||d.type==="touchstart")||Array.isArray(o)&&!o.includes(d.button)&&d.type==="mousedown")return!1;let b=Array.isArray(o)&&o.includes(d.button)||!d.button||d.button<=1;return(!d.ctrlKey||y)&&b}}function wb({domNode:t,minZoom:e,maxZoom:n,translateExtent:o,viewport:a,onPanZoom:l,onPanZoomStart:i,onPanZoomEnd:r,onDraggingChange:u}){let s={isZoomingOrPanning:!1,usedRightMouseButton:!1,prevViewport:{},mouseButton:0,timerId:void 0,panScrollTimeout:void 0,isPanScrolling:!1},c=t.getBoundingClientRect(),d=sc().scaleExtent([e,n]).translateExtent(o),f=Qt(t).call(d);m({x:a.x,y:a.y,zoom:gl(a.zoom,e,n)},[[0,0],[c.width,c.height]],o);let p=f.on("wheel.zoom"),y=f.on("dblclick.zoom");d.wheelDelta(_b);async function b(C,k){return f?new Promise(V=>{d?.interpolate(k?.interpolate==="linear"?kn:na).transform(th(f,k?.duration,k?.ease,()=>V(!0)),C)}):!1}function x({noWheelClassName:C,noPanClassName:k,onPaneContextMenu:V,userSelectionActive:S,panOnScroll:A,panOnDrag:z,panOnScrollMode:T,panOnScrollSpeed:B,preventScrolling:H,zoomOnPinch:X,zoomOnScroll:Z,zoomOnDoubleClick:q,zoomActivationKeyPressed:K,lib:j,onTransformChange:I,connectionInProgress:ot,paneClickDistance:J,selectionOnDrag:U}){S&&!s.isZoomingOrPanning&&g();let Q=A&&!K&&!S;d.clickDistance(U?1/0:!Ye(J)||J<0?0:J);let nt=Q?tz({zoomPanValues:s,noWheelClassName:C,d3Selection:f,d3Zoom:d,panOnScrollMode:T,panOnScrollSpeed:B,zoomOnPinch:X,onPanZoomStart:i,onPanZoom:l,onPanZoomEnd:r}):ez({noWheelClassName:C,preventScrolling:H,d3ZoomHandler:p});f.on("wheel.zoom",nt,{passive:!1});let tt=nz({zoomPanValues:s,onDraggingChange:u,onPanZoomStart:i});d.on("start",tt);let $=oz({zoomPanValues:s,panOnDrag:z,onPaneContextMenu:!!V,onPanZoom:l,onTransformChange:I});d.on("zoom",$);let W=az({zoomPanValues:s,panOnDrag:z,panOnScroll:A,onPaneContextMenu:V,onPanZoomEnd:r,onDraggingChange:u});d.on("end",W);let ct=lz({zoomActivationKeyPressed:K,panOnDrag:z,zoomOnScroll:Z,panOnScroll:A,zoomOnDoubleClick:q,zoomOnPinch:X,userSelectionActive:S,noPanClassName:k,noWheelClassName:C,lib:j,connectionInProgress:ot});d.filter(ct),q?f.on("dblclick.zoom",y):f.on("dblclick.zoom",null)}function g(){d.on("zoom",null)}async function m(C,k,V){let S=Pd(C),A=d?.constrain()(S,k,V);return A&&await b(A),A}async function h(C,k){let V=Pd(C);return await b(V,k),V}function v(C){if(f){let k=Pd(C),V=f.property("__zoom");(V.k!==C.zoom||V.x!==C.x||V.y!==C.y)&&d?.transform(f,k,null,{sync:!0})}}function _(){let C=f?Ji(f.node()):{x:0,y:0,k:1};return{x:C.x,y:C.y,zoom:C.k}}async function E(C,k){return f?new Promise(V=>{d?.interpolate(k?.interpolate==="linear"?kn:na).scaleTo(th(f,k?.duration,k?.ease,()=>V(!0)),C)}):!1}async function w(C,k){return f?new Promise(V=>{d?.interpolate(k?.interpolate==="linear"?kn:na).scaleBy(th(f,k?.duration,k?.ease,()=>V(!0)),C)}):!1}function N(C){d?.scaleExtent(C)}function M(C){d?.translateExtent(C)}function R(C){let k=!Ye(C)||C<0?0:C;d?.clickDistance(k)}return{update:x,destroy:g,setViewport:h,setViewportConstrained:m,getViewport:_,scaleTo:E,scaleBy:w,setScaleExtent:N,setTranslateExtent:M,syncViewport:v,setClickDistance:R}}var wo;(function(t){t.Line="line",t.Handle="handle"})(wo||(wo={}));function iz({width:t,prevWidth:e,height:n,prevHeight:o,affectsX:a,affectsY:l}){let i=t-e,r=n-o,u=[i>0?1:i<0?-1:0,r>0?1:r<0?-1:0];return i&&a&&(u[0]=u[0]*-1),r&&l&&(u[1]=u[1]*-1),u}function J1(t){let e=t.includes("right")||t.includes("left"),n=t.includes("bottom")||t.includes("top"),o=t.includes("left"),a=t.includes("top");return{isHorizontal:e,isVertical:n,affectsX:o,affectsY:a}}function bo(t,e){return Math.max(0,e-t)}function xo(t,e){return Math.max(0,t-e)}function dc(t,e,n){return Math.max(0,e-t,t-n)}function I1(t,e){return t?!e:e}function rz(t,e,n,o,a,l,i,r){let{affectsX:u,affectsY:s}=e,{isHorizontal:c,isVertical:d}=e,f=c&&d,{xSnapped:p,ySnapped:y}=n,{minWidth:b,maxWidth:x,minHeight:g,maxHeight:m}=o,{x:h,y:v,width:_,height:E,aspectRatio:w}=t,N=Math.floor(c?p-t.pointerX:0),M=Math.floor(d?y-t.pointerY:0),R=_+(u?-N:N),C=E+(s?-M:M),k=-l[0]*_,V=-l[1]*E,S=dc(R,b,x),A=dc(C,g,m);if(i){let B=0,H=0;u&&N<0?B=bo(h+N+k,i[0][0]):!u&&N>0&&(B=xo(h+R+k,i[1][0])),s&&M<0?H=bo(v+M+V,i[0][1]):!s&&M>0&&(H=xo(v+C+V,i[1][1])),S=Math.max(S,B),A=Math.max(A,H)}if(r){let B=0,H=0;u&&N>0?B=xo(h+N,r[0][0]):!u&&N<0&&(B=bo(h+R,r[1][0])),s&&M>0?H=xo(v+M,r[0][1]):!s&&M<0&&(H=bo(v+C,r[1][1])),S=Math.max(S,B),A=Math.max(A,H)}if(a){if(c){let B=dc(R/w,g,m)*w;if(S=Math.max(S,B),i){let H=0;!u&&!s||u&&!s&&f?H=xo(v+V+R/w,i[1][1])*w:H=bo(v+V+(u?N:-N)/w,i[0][1])*w,S=Math.max(S,H)}if(r){let H=0;!u&&!s||u&&!s&&f?H=bo(v+R/w,r[1][1])*w:H=xo(v+(u?N:-N)/w,r[0][1])*w,S=Math.max(S,H)}}if(d){let B=dc(C*w,b,x)/w;if(A=Math.max(A,B),i){let H=0;!u&&!s||s&&!u&&f?H=xo(h+C*w+k,i[1][0])/w:H=bo(h+(s?M:-M)*w+k,i[0][0])/w,A=Math.max(A,H)}if(r){let H=0;!u&&!s||s&&!u&&f?H=bo(h+C*w,r[1][0])/w:H=xo(h+(s?M:-M)*w,r[0][0])/w,A=Math.max(A,H)}}}M=M+(M<0?A:-A),N=N+(N<0?S:-S),a&&(f?R>C*w?M=(I1(u,s)?-N:N)/w:N=(I1(u,s)?-M:M)*w:c?(M=N/w,s=u):(N=M*w,u=s));let z=u?h+N:h,T=s?v+M:v;return{width:_+(u?-N:N),height:E+(s?-M:M),x:l[0]*N*(u?-1:1)+z,y:l[1]*M*(s?-1:1)+T}}var Eb={width:0,height:0,x:0,y:0},uz={...Eb,pointerX:0,pointerY:0,aspectRatio:1};function cz(t,e,n){let o=e.position.x+t.position.x,a=e.position.y+t.position.y,l=t.measured.width??0,i=t.measured.height??0,r=n[0]*l,u=n[1]*i;return[[o-r,a-u],[o+l-r,a+i-u]]}function Nb({domNode:t,nodeId:e,getStoreItems:n,onChange:o,onEnd:a}){let l=Qt(t),i={controlDirection:J1("bottom-right"),boundaries:{minWidth:0,minHeight:0,maxWidth:Number.MAX_VALUE,maxHeight:Number.MAX_VALUE},resizeDirection:void 0,keepAspectRatio:!1};function r({controlPosition:s,boundaries:c,keepAspectRatio:d,resizeDirection:f,onResizeStart:p,onResize:y,onResizeEnd:b,shouldResize:x}){let g={...Eb},m={...uz};i={boundaries:c,resizeDirection:f,keepAspectRatio:d,controlDirection:J1(s)};let h,v=null,_=[],E,w,N,M=!1,R=Zu().on("start",C=>{let{nodeLookup:k,transform:V,snapGrid:S,snapToGrid:A,nodeOrigin:z,paneDomNode:T}=n();if(h=k.get(e),!h)return;v=T?.getBoundingClientRect()??null;let{xSnapped:B,ySnapped:H}=Ii(C.sourceEvent,{transform:V,snapGrid:S,snapToGrid:A,containerBounds:v});g={width:h.measured.width??0,height:h.measured.height??0,x:h.position.x??0,y:h.position.y??0},m={...g,pointerX:B,pointerY:H,aspectRatio:g.width/g.height},E=void 0,w=ca(h.extent)?h.extent:void 0,h.parentId&&(h.extent==="parent"||h.expandParent)&&(E=k.get(h.parentId)),E&&h.extent==="parent"&&(w=[[0,0],[E.measured.width,E.measured.height]]),_=[],N=void 0;for(let[X,Z]of k)if(Z.parentId===e&&(_.push({id:X,position:{...Z.position},extent:Z.extent}),Z.extent==="parent"||Z.expandParent)){let q=cz(Z,h,Z.origin??z);N?N=[[Math.min(q[0][0],N[0][0]),Math.min(q[0][1],N[0][1])],[Math.max(q[1][0],N[1][0]),Math.max(q[1][1],N[1][1])]]:N=q}p?.(C,{...g})}).on("drag",C=>{let{transform:k,snapGrid:V,snapToGrid:S,nodeOrigin:A}=n(),z=Ii(C.sourceEvent,{transform:k,snapGrid:V,snapToGrid:S,containerBounds:v}),T=[];if(!h)return;let{x:B,y:H,width:X,height:Z}=g,q={},K=h.origin??A,{width:j,height:I,x:ot,y:J}=rz(m,i.controlDirection,z,i.boundaries,i.keepAspectRatio,K,w,N),U=j!==X,Q=I!==Z,nt=ot!==B&&U,tt=J!==H&&Q;if(!nt&&!tt&&!U&&!Q)return;if((nt||tt||K[0]===1||K[1]===1)&&(q.x=nt?ot:g.x,q.y=tt?J:g.y,g.x=q.x,g.y=q.y,_.length>0)){let dt=ot-B,Dt=J-H;for(let ie of _)ie.position={x:ie.position.x-dt+K[0]*(j-X),y:ie.position.y-Dt+K[1]*(I-Z)},T.push(ie)}if((U||Q)&&(q.width=U&&(!i.resizeDirection||i.resizeDirection==="horizontal")?j:g.width,q.height=Q&&(!i.resizeDirection||i.resizeDirection==="vertical")?I:g.height,g.width=q.width,g.height=q.height),E&&h.expandParent){let dt=K[0]*(q.width??0);q.x&&q.x<dt&&(g.x=dt,m.x=m.x-(q.x-dt));let Dt=K[1]*(q.height??0);q.y&&q.y<Dt&&(g.y=Dt,m.y=m.y-(q.y-Dt))}let $=iz({width:g.width,prevWidth:X,height:g.height,prevHeight:Z,affectsX:i.controlDirection.affectsX,affectsY:i.controlDirection.affectsY}),W={...g,direction:$};x?.(C,W)!==!1&&(M=!0,y?.(C,W),o(q,T))}).on("end",C=>{M&&(b?.(C,{...g}),a?.({...g}),M=!1)});l.call(R)}function u(){l.on(".drag",null)}return{update:r,destroy:u}}var Ub=We(hn(),1),Yb=We(Hb(),1);var Bb={},Rb=t=>{let e,n=new Set,o=(c,d)=>{let f=typeof c=="function"?c(e):c;if(!Object.is(f,e)){let p=e;e=d??(typeof f!="object"||f===null)?f:Object.assign({},e,f),n.forEach(y=>y(e,p))}},a=()=>e,u={setState:o,getState:a,getInitialState:()=>s,subscribe:c=>(n.add(c),()=>n.delete(c)),destroy:()=>{(Bb.env?Bb.env.MODE:void 0)!=="production"&&console.warn("[DEPRECATED] The `destroy` method will be unsupported in a future version. Instead use unsubscribe function returned by subscribe. Everything will be garbage-collected if store is garbage-collected."),n.clear()}},s=e=t(o,a,u);return u},kb=t=>t?Rb(t):Rb;var{useDebugValue:zz}=Ub.default,{useSyncExternalStoreWithSelector:Az}=Yb.default,Cz=t=>t;function Mh(t,e=Cz,n){let o=Az(t.subscribe,t.getState,t.getServerState||t.getInitialState,e,n);return zz(o),o}var Lb=(t,e)=>{let n=kb(t),o=(a,l=e)=>Mh(n,a,l);return Object.assign(o,n),o},Vb=(t,e)=>t?Lb(t,e):Lb;function Et(t,e){if(Object.is(t,e))return!0;if(typeof t!="object"||t===null||typeof e!="object"||e===null)return!1;if(t instanceof Map&&e instanceof Map){if(t.size!==e.size)return!1;for(let[o,a]of t)if(!Object.is(a,e.get(o)))return!1;return!0}if(t instanceof Set&&e instanceof Set){if(t.size!==e.size)return!1;for(let o of t)if(!e.has(o))return!1;return!0}let n=Object.keys(t);if(n.length!==Object.keys(e).length)return!1;for(let o of n)if(!Object.prototype.hasOwnProperty.call(e,o)||!Object.is(t[o],e[o]))return!1;return!0}var sx=We(Fc()),Oc=(0,D.createContext)(null),Tz=Oc.Provider,fx=Me.error001("react");function ut(t,e){let n=(0,D.useContext)(Oc);if(n===null)throw new Error(fx);return Mh(n,t,e)}function zt(){let t=(0,D.useContext)(Oc);if(t===null)throw new Error(fx);return(0,D.useMemo)(()=>({getState:t.getState,setState:t.setState,subscribe:t.subscribe}),[t])}var qb={display:"none"},Oz={position:"absolute",width:1,height:1,margin:-1,border:0,padding:0,overflow:"hidden",clip:"rect(0px, 0px, 0px, 0px)",clipPath:"inset(100%)"},dx="react-flow__node-desc",hx="react-flow__edge-desc",Dz="react-flow__aria-live",Hz=t=>t.ariaLiveMessage,Rz=t=>t.ariaLabelConfig;function Bz({rfId:t}){let e=ut(Hz);return(0,O.jsx)("div",{id:`${Dz}-${t}`,"aria-live":"assertive","aria-atomic":"true",style:Oz,children:e})}function kz({rfId:t,disableKeyboardA11y:e}){let n=ut(Rz);return(0,O.jsxs)(O.Fragment,{children:[(0,O.jsx)("div",{id:`${dx}-${t}`,style:qb,children:e?n["node.a11yDescription.default"]:n["node.a11yDescription.keyboardDisabled"]}),(0,O.jsx)("div",{id:`${hx}-${t}`,style:qb,children:n["edge.a11yDescription.default"]}),!e&&(0,O.jsx)(Bz,{rfId:t})]})}var Dc=(0,D.forwardRef)(({position:t="top-left",children:e,className:n,style:o,...a},l)=>{let i=`${t}`.split("-");return(0,O.jsx)("div",{className:Tt(["react-flow__panel",n,...i]),style:o,ref:l,...a,children:e})});Dc.displayName="Panel";function Lz({proOptions:t,position:e="bottom-right"}){return t?.hideAttribution?null:(0,O.jsx)(Dc,{position:e,className:"react-flow__attribution","data-message":"Please only hide this attribution when you are subscribed to React Flow Pro: https://pro.reactflow.dev",children:(0,O.jsx)("a",{href:"https://reactflow.dev",target:"_blank",rel:"noopener noreferrer","aria-label":"React Flow attribution",children:"React Flow"})})}var Uz=t=>{let e=[],n=[];for(let[,o]of t.nodeLookup)o.selected&&e.push(o.internals.userNode);for(let[,o]of t.edgeLookup)o.selected&&n.push(o);return{selectedNodes:e,selectedEdges:n}},Ac=t=>t.id;function Yz(t,e){return Et(t.selectedNodes.map(Ac),e.selectedNodes.map(Ac))&&Et(t.selectedEdges.map(Ac),e.selectedEdges.map(Ac))}function Vz({onSelectionChange:t}){let e=zt(),{selectedNodes:n,selectedEdges:o}=ut(Uz,Yz);return(0,D.useEffect)(()=>{let a={nodes:n,edges:o};t?.(a),e.getState().onSelectionChangeHandlers.forEach(l=>l(a))},[n,o,t]),null}var qz=t=>!!t.onSelectionChangeHandlers;function Xz({onSelectionChange:t}){let e=ut(qz);return t||e?(0,O.jsx)(Vz,{onSelectionChange:t}):null}var px=[0,0],Zz={x:0,y:0,zoom:1},Gz=["nodes","edges","defaultNodes","defaultEdges","onConnect","onConnectStart","onConnectEnd","onClickConnectStart","onClickConnectEnd","nodesDraggable","autoPanOnNodeFocus","nodesConnectable","nodesFocusable","edgesFocusable","edgesReconnectable","elevateNodesOnSelect","elevateEdgesOnSelect","minZoom","maxZoom","nodeExtent","onNodesChange","onEdgesChange","elementsSelectable","connectionMode","snapGrid","snapToGrid","translateExtent","connectOnClick","defaultEdgeOptions","fitView","fitViewOptions","onNodesDelete","onEdgesDelete","onDelete","onNodeDrag","onNodeDragStart","onNodeDragStop","onSelectionDrag","onSelectionDragStart","onSelectionDragStop","onMoveStart","onMove","onMoveEnd","noPanClassName","nodeOrigin","autoPanOnConnect","autoPanOnNodeDrag","onError","connectionRadius","isValidConnection","selectNodesOnDrag","nodeDragThreshold","connectionDragThreshold","onBeforeDelete","debug","autoPanSpeed","ariaLabelConfig","zIndexMode"],Xb=[...Gz,"rfId"],Qz=t=>({setNodes:t.setNodes,setEdges:t.setEdges,setMinZoom:t.setMinZoom,setMaxZoom:t.setMaxZoom,setTranslateExtent:t.setTranslateExtent,setNodeExtent:t.setNodeExtent,reset:t.reset,setDefaultNodesAndEdges:t.setDefaultNodesAndEdges}),Zb={translateExtent:ml,nodeOrigin:px,minZoom:.5,maxZoom:2,elementsSelectable:!0,noPanClassName:"nopan",rfId:"1"};function jz(t){let{setNodes:e,setEdges:n,setMinZoom:o,setMaxZoom:a,setTranslateExtent:l,setNodeExtent:i,reset:r,setDefaultNodesAndEdges:u}=ut(Qz,Et),s=zt();(0,D.useEffect)(()=>(u(t.defaultNodes,t.defaultEdges),()=>{c.current=Zb,r()}),[]);let c=(0,D.useRef)(Zb);return(0,D.useEffect)(()=>{for(let d of Xb){let f=t[d],p=c.current[d];f!==p&&(typeof t[d]>"u"||(d==="nodes"?e(f):d==="edges"?n(f):d==="minZoom"?o(f):d==="maxZoom"?a(f):d==="translateExtent"?l(f):d==="nodeExtent"?i(f):d==="ariaLabelConfig"?s.setState({ariaLabelConfig:ob(f)}):d==="fitView"?s.setState({fitViewQueued:f}):d==="fitViewOptions"?s.setState({fitViewOptions:f}):s.setState({[d]:f})))}c.current=t},Xb.map(d=>t[d])),null}function Gb(){return typeof window>"u"||!window.matchMedia?null:window.matchMedia("(prefers-color-scheme: dark)")}function Kz(t){let[e,n]=(0,D.useState)(t==="system"?null:t);return(0,D.useEffect)(()=>{if(t!=="system"){n(t);return}let o=Gb(),a=()=>n(o?.matches?"dark":"light");return a(),o?.addEventListener("change",a),()=>{o?.removeEventListener("change",a)}},[t]),e!==null?e:Gb()?.matches?"dark":"light"}var Qb=typeof document<"u"?document:null;function Pi(t=null,e={target:Qb,actInsideInputWithModifier:!0}){let[n,o]=(0,D.useState)(!1),a=(0,D.useRef)(!1),l=(0,D.useRef)(new Set([])),[i,r]=(0,D.useMemo)(()=>{if(t!==null){let s=(Array.isArray(t)?t:[t]).filter(d=>typeof d=="string").map(d=>d.replace("+",`
8
+ `+o.stack}}var Vs=Object.prototype.hasOwnProperty,Of=Vt.unstable_scheduleCallback,os=Vt.unstable_cancelCallback,B_=Vt.unstable_shouldYield,k_=Vt.unstable_requestPaint,xe=Vt.unstable_now,L_=Vt.unstable_getCurrentPriorityLevel,$g=Vt.unstable_ImmediatePriority,Jg=Vt.unstable_UserBlockingPriority,qr=Vt.unstable_NormalPriority,U_=Vt.unstable_LowPriority,Ig=Vt.unstable_IdlePriority,Y_=Vt.log,V_=Vt.unstable_setDisableYieldValue,gi=null,Se=null;function $n(t){if(typeof Y_=="function"&&V_(t),Se&&typeof Se.setStrictMode=="function")try{Se.setStrictMode(gi,t)}catch{}}var _e=Math.clz32?Math.clz32:Z_,q_=Math.log,X_=Math.LN2;function Z_(t){return t>>>=0,t===0?32:31-(q_(t)/X_|0)|0}var ir=256,rr=262144,ur=4194304;function Oo(t){var e=t&42;if(e!==0)return e;switch(t&-t){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:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:return t&261888;case 262144:case 524288:case 1048576:case 2097152:return t&3932160;case 4194304:case 8388608:case 16777216:case 33554432:return t&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return t}}function hu(t,e,n){var o=t.pendingLanes;if(o===0)return 0;var a=0,l=t.suspendedLanes,i=t.pingedLanes;t=t.warmLanes;var r=o&134217727;return r!==0?(o=r&~l,o!==0?a=Oo(o):(i&=r,i!==0?a=Oo(i):n||(n=r&~t,n!==0&&(a=Oo(n))))):(r=o&~l,r!==0?a=Oo(r):i!==0?a=Oo(i):n||(n=o&~t,n!==0&&(a=Oo(n)))),a===0?0:e!==0&&e!==a&&(e&l)===0&&(l=a&-a,n=e&-e,l>=n||l===32&&(n&4194048)!==0)?e:a}function mi(t,e){return(t.pendingLanes&~(t.suspendedLanes&~t.pingedLanes)&e)===0}function G_(t,e){switch(t){case 1:case 2:case 4:case 8:case 64:return e+250;case 16:case 32: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 e+5e3;case 4194304:case 8388608:case 16777216:case 33554432:return-1;case 67108864:case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function Wg(){var t=ur;return ur<<=1,(ur&62914560)===0&&(ur=4194304),t}function as(t){for(var e=[],n=0;31>n;n++)e.push(t);return e}function yi(t,e){t.pendingLanes|=e,e!==268435456&&(t.suspendedLanes=0,t.pingedLanes=0,t.warmLanes=0)}function Q_(t,e,n,o,a,l){var i=t.pendingLanes;t.pendingLanes=n,t.suspendedLanes=0,t.pingedLanes=0,t.warmLanes=0,t.expiredLanes&=n,t.entangledLanes&=n,t.errorRecoveryDisabledLanes&=n,t.shellSuspendCounter=0;var r=t.entanglements,u=t.expirationTimes,s=t.hiddenUpdates;for(n=i&~n;0<n;){var c=31-_e(n),d=1<<c;r[c]=0,u[c]=-1;var f=s[c];if(f!==null)for(s[c]=null,c=0;c<f.length;c++){var p=f[c];p!==null&&(p.lane&=-536870913)}n&=~d}o!==0&&Fg(t,o,0),l!==0&&a===0&&t.tag!==0&&(t.suspendedLanes|=l&~(i&~e))}function Fg(t,e,n){t.pendingLanes|=e,t.suspendedLanes&=~e;var o=31-_e(e);t.entangledLanes|=e,t.entanglements[o]=t.entanglements[o]|1073741824|n&261930}function Pg(t,e){var n=t.entangledLanes|=e;for(t=t.entanglements;n;){var o=31-_e(n),a=1<<o;a&e|t[o]&e&&(t[o]|=e),n&=~a}}function tm(t,e){var n=e&-e;return n=(n&42)!==0?1:Df(n),(n&(t.suspendedLanes|e))!==0?0:n}function Df(t){switch(t){case 2:t=1;break;case 8:t=4;break;case 32:t=16;break;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:t=128;break;case 268435456:t=134217728;break;default:t=0}return t}function Hf(t){return t&=-t,2<t?8<t?(t&134217727)!==0?32:268435456:8:2}function em(){var t=ft.p;return t!==0?t:(t=window.event,t===void 0?32:Ey(t.type))}function xp(t,e){var n=ft.p;try{return ft.p=t,e()}finally{ft.p=n}}var ho=Math.random().toString(36).slice(2),Kt="__reactFiber$"+ho,he="__reactProps$"+ho,tl="__reactContainer$"+ho,qs="__reactEvents$"+ho,j_="__reactListeners$"+ho,K_="__reactHandles$"+ho,Sp="__reactResources$"+ho,vi="__reactMarker$"+ho;function Rf(t){delete t[Kt],delete t[he],delete t[qs],delete t[j_],delete t[K_]}function Ma(t){var e=t[Kt];if(e)return e;for(var n=t.parentNode;n;){if(e=n[tl]||n[Kt]){if(n=e.alternate,e.child!==null||n!==null&&n.child!==null)for(t=Cg(t);t!==null;){if(n=t[Kt])return n;t=Cg(t)}return e}t=n,n=t.parentNode}return null}function el(t){if(t=t[Kt]||t[tl]){var e=t.tag;if(e===5||e===6||e===13||e===31||e===26||e===27||e===3)return t}return null}function Ul(t){var e=t.tag;if(e===5||e===26||e===27||e===6)return t.stateNode;throw Error(L(33))}function ka(t){var e=t[Sp];return e||(e=t[Sp]={hoistableStyles:new Map,hoistableScripts:new Map}),e}function Zt(t){t[vi]=!0}var nm=new Set,om={};function Go(t,e){Ga(t,e),Ga(t+"Capture",e)}function Ga(t,e){for(om[t]=e,t=0;t<e.length;t++)nm.add(e[t])}var $_=RegExp("^[:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD][:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$"),_p={},wp={};function J_(t){return Vs.call(wp,t)?!0:Vs.call(_p,t)?!1:$_.test(t)?wp[t]=!0:(_p[t]=!0,!1)}function wr(t,e,n){if(J_(e))if(n===null)t.removeAttribute(e);else{switch(typeof n){case"undefined":case"function":case"symbol":t.removeAttribute(e);return;case"boolean":var o=e.toLowerCase().slice(0,5);if(o!=="data-"&&o!=="aria-"){t.removeAttribute(e);return}}t.setAttribute(e,""+n)}}function cr(t,e,n){if(n===null)t.removeAttribute(e);else{switch(typeof n){case"undefined":case"function":case"symbol":case"boolean":t.removeAttribute(e);return}t.setAttribute(e,""+n)}}function gn(t,e,n,o){if(o===null)t.removeAttribute(n);else{switch(typeof o){case"undefined":case"function":case"symbol":case"boolean":t.removeAttribute(n);return}t.setAttributeNS(e,n,""+o)}}function Ce(t){switch(typeof t){case"bigint":case"boolean":case"number":case"string":case"undefined":return t;case"object":return t;default:return""}}function am(t){var e=t.type;return(t=t.nodeName)&&t.toLowerCase()==="input"&&(e==="checkbox"||e==="radio")}function I_(t,e,n){var o=Object.getOwnPropertyDescriptor(t.constructor.prototype,e);if(!t.hasOwnProperty(e)&&typeof o<"u"&&typeof o.get=="function"&&typeof o.set=="function"){var a=o.get,l=o.set;return Object.defineProperty(t,e,{configurable:!0,get:function(){return a.call(this)},set:function(i){n=""+i,l.call(this,i)}}),Object.defineProperty(t,e,{enumerable:o.enumerable}),{getValue:function(){return n},setValue:function(i){n=""+i},stopTracking:function(){t._valueTracker=null,delete t[e]}}}}function Xs(t){if(!t._valueTracker){var e=am(t)?"checked":"value";t._valueTracker=I_(t,e,""+t[e])}}function lm(t){if(!t)return!1;var e=t._valueTracker;if(!e)return!0;var n=e.getValue(),o="";return t&&(o=am(t)?t.checked?"true":"false":t.value),t=o,t!==n?(e.setValue(t),!0):!1}function Xr(t){if(t=t||(typeof document<"u"?document:void 0),typeof t>"u")return null;try{return t.activeElement||t.body}catch{return t.body}}var W_=/[\n"\\]/g;function De(t){return t.replace(W_,function(e){return"\\"+e.charCodeAt(0).toString(16)+" "})}function Zs(t,e,n,o,a,l,i,r){t.name="",i!=null&&typeof i!="function"&&typeof i!="symbol"&&typeof i!="boolean"?t.type=i:t.removeAttribute("type"),e!=null?i==="number"?(e===0&&t.value===""||t.value!=e)&&(t.value=""+Ce(e)):t.value!==""+Ce(e)&&(t.value=""+Ce(e)):i!=="submit"&&i!=="reset"||t.removeAttribute("value"),e!=null?Gs(t,i,Ce(e)):n!=null?Gs(t,i,Ce(n)):o!=null&&t.removeAttribute("value"),a==null&&l!=null&&(t.defaultChecked=!!l),a!=null&&(t.checked=a&&typeof a!="function"&&typeof a!="symbol"),r!=null&&typeof r!="function"&&typeof r!="symbol"&&typeof r!="boolean"?t.name=""+Ce(r):t.removeAttribute("name")}function im(t,e,n,o,a,l,i,r){if(l!=null&&typeof l!="function"&&typeof l!="symbol"&&typeof l!="boolean"&&(t.type=l),e!=null||n!=null){if(!(l!=="submit"&&l!=="reset"||e!=null)){Xs(t);return}n=n!=null?""+Ce(n):"",e=e!=null?""+Ce(e):n,r||e===t.value||(t.value=e),t.defaultValue=e}o=o??a,o=typeof o!="function"&&typeof o!="symbol"&&!!o,t.checked=r?t.checked:!!o,t.defaultChecked=!!o,i!=null&&typeof i!="function"&&typeof i!="symbol"&&typeof i!="boolean"&&(t.name=i),Xs(t)}function Gs(t,e,n){e==="number"&&Xr(t.ownerDocument)===t||t.defaultValue===""+n||(t.defaultValue=""+n)}function La(t,e,n,o){if(t=t.options,e){e={};for(var a=0;a<n.length;a++)e["$"+n[a]]=!0;for(n=0;n<t.length;n++)a=e.hasOwnProperty("$"+t[n].value),t[n].selected!==a&&(t[n].selected=a),a&&o&&(t[n].defaultSelected=!0)}else{for(n=""+Ce(n),e=null,a=0;a<t.length;a++){if(t[a].value===n){t[a].selected=!0,o&&(t[a].defaultSelected=!0);return}e!==null||t[a].disabled||(e=t[a])}e!==null&&(e.selected=!0)}}function rm(t,e,n){if(e!=null&&(e=""+Ce(e),e!==t.value&&(t.value=e),n==null)){t.defaultValue!==e&&(t.defaultValue=e);return}t.defaultValue=n!=null?""+Ce(n):""}function um(t,e,n,o){if(e==null){if(o!=null){if(n!=null)throw Error(L(92));if(Ll(o)){if(1<o.length)throw Error(L(93));o=o[0]}n=o}n==null&&(n=""),e=n}n=Ce(e),t.defaultValue=n,o=t.textContent,o===n&&o!==""&&o!==null&&(t.value=o),Xs(t)}function Qa(t,e){if(e){var n=t.firstChild;if(n&&n===t.lastChild&&n.nodeType===3){n.nodeValue=e;return}}t.textContent=e}var F_=new Set("animationIterationCount aspectRatio borderImageOutset borderImageSlice borderImageWidth boxFlex boxFlexGroup boxOrdinalGroup columnCount columns flex flexGrow flexPositive flexShrink flexNegative flexOrder gridArea gridRow gridRowEnd gridRowSpan gridRowStart gridColumn gridColumnEnd gridColumnSpan gridColumnStart fontWeight lineClamp lineHeight opacity order orphans scale tabSize widows zIndex zoom fillOpacity floodOpacity stopOpacity strokeDasharray strokeDashoffset strokeMiterlimit strokeOpacity strokeWidth MozAnimationIterationCount MozBoxFlex MozBoxFlexGroup MozLineClamp msAnimationIterationCount msFlex msZoom msFlexGrow msFlexNegative msFlexOrder msFlexPositive msFlexShrink msGridColumn msGridColumnSpan msGridRow msGridRowSpan WebkitAnimationIterationCount WebkitBoxFlex WebKitBoxFlexGroup WebkitBoxOrdinalGroup WebkitColumnCount WebkitColumns WebkitFlex WebkitFlexGrow WebkitFlexPositive WebkitFlexShrink WebkitLineClamp".split(" "));function Ep(t,e,n){var o=e.indexOf("--")===0;n==null||typeof n=="boolean"||n===""?o?t.setProperty(e,""):e==="float"?t.cssFloat="":t[e]="":o?t.setProperty(e,n):typeof n!="number"||n===0||F_.has(e)?e==="float"?t.cssFloat=n:t[e]=(""+n).trim():t[e]=n+"px"}function cm(t,e,n){if(e!=null&&typeof e!="object")throw Error(L(62));if(t=t.style,n!=null){for(var o in n)!n.hasOwnProperty(o)||e!=null&&e.hasOwnProperty(o)||(o.indexOf("--")===0?t.setProperty(o,""):o==="float"?t.cssFloat="":t[o]="");for(var a in e)o=e[a],e.hasOwnProperty(a)&&n[a]!==o&&Ep(t,a,o)}else for(var l in e)e.hasOwnProperty(l)&&Ep(t,l,e[l])}function Bf(t){if(t.indexOf("-")===-1)return!1;switch(t){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 P_=new Map([["acceptCharset","accept-charset"],["htmlFor","for"],["httpEquiv","http-equiv"],["crossOrigin","crossorigin"],["accentHeight","accent-height"],["alignmentBaseline","alignment-baseline"],["arabicForm","arabic-form"],["baselineShift","baseline-shift"],["capHeight","cap-height"],["clipPath","clip-path"],["clipRule","clip-rule"],["colorInterpolation","color-interpolation"],["colorInterpolationFilters","color-interpolation-filters"],["colorProfile","color-profile"],["colorRendering","color-rendering"],["dominantBaseline","dominant-baseline"],["enableBackground","enable-background"],["fillOpacity","fill-opacity"],["fillRule","fill-rule"],["floodColor","flood-color"],["floodOpacity","flood-opacity"],["fontFamily","font-family"],["fontSize","font-size"],["fontSizeAdjust","font-size-adjust"],["fontStretch","font-stretch"],["fontStyle","font-style"],["fontVariant","font-variant"],["fontWeight","font-weight"],["glyphName","glyph-name"],["glyphOrientationHorizontal","glyph-orientation-horizontal"],["glyphOrientationVertical","glyph-orientation-vertical"],["horizAdvX","horiz-adv-x"],["horizOriginX","horiz-origin-x"],["imageRendering","image-rendering"],["letterSpacing","letter-spacing"],["lightingColor","lighting-color"],["markerEnd","marker-end"],["markerMid","marker-mid"],["markerStart","marker-start"],["overlinePosition","overline-position"],["overlineThickness","overline-thickness"],["paintOrder","paint-order"],["panose-1","panose-1"],["pointerEvents","pointer-events"],["renderingIntent","rendering-intent"],["shapeRendering","shape-rendering"],["stopColor","stop-color"],["stopOpacity","stop-opacity"],["strikethroughPosition","strikethrough-position"],["strikethroughThickness","strikethrough-thickness"],["strokeDasharray","stroke-dasharray"],["strokeDashoffset","stroke-dashoffset"],["strokeLinecap","stroke-linecap"],["strokeLinejoin","stroke-linejoin"],["strokeMiterlimit","stroke-miterlimit"],["strokeOpacity","stroke-opacity"],["strokeWidth","stroke-width"],["textAnchor","text-anchor"],["textDecoration","text-decoration"],["textRendering","text-rendering"],["transformOrigin","transform-origin"],["underlinePosition","underline-position"],["underlineThickness","underline-thickness"],["unicodeBidi","unicode-bidi"],["unicodeRange","unicode-range"],["unitsPerEm","units-per-em"],["vAlphabetic","v-alphabetic"],["vHanging","v-hanging"],["vIdeographic","v-ideographic"],["vMathematical","v-mathematical"],["vectorEffect","vector-effect"],["vertAdvY","vert-adv-y"],["vertOriginX","vert-origin-x"],["vertOriginY","vert-origin-y"],["wordSpacing","word-spacing"],["writingMode","writing-mode"],["xmlnsXlink","xmlns:xlink"],["xHeight","x-height"]]),tw=/^[\u0000-\u001F ]*j[\r\n\t]*a[\r\n\t]*v[\r\n\t]*a[\r\n\t]*s[\r\n\t]*c[\r\n\t]*r[\r\n\t]*i[\r\n\t]*p[\r\n\t]*t[\r\n\t]*:/i;function Er(t){return tw.test(""+t)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":t}function wn(){}var Qs=null;function kf(t){return t=t.target||t.srcElement||window,t.correspondingUseElement&&(t=t.correspondingUseElement),t.nodeType===3?t.parentNode:t}var za=null,Ua=null;function Np(t){var e=el(t);if(e&&(t=e.stateNode)){var n=t[he]||null;t:switch(t=e.stateNode,e.type){case"input":if(Zs(t,n.value,n.defaultValue,n.defaultValue,n.checked,n.defaultChecked,n.type,n.name),e=n.name,n.type==="radio"&&e!=null){for(n=t;n.parentNode;)n=n.parentNode;for(n=n.querySelectorAll('input[name="'+De(""+e)+'"][type="radio"]'),e=0;e<n.length;e++){var o=n[e];if(o!==t&&o.form===t.form){var a=o[he]||null;if(!a)throw Error(L(90));Zs(o,a.value,a.defaultValue,a.defaultValue,a.checked,a.defaultChecked,a.type,a.name)}}for(e=0;e<n.length;e++)o=n[e],o.form===t.form&&lm(o)}break t;case"textarea":rm(t,n.value,n.defaultValue);break t;case"select":e=n.value,e!=null&&La(t,!!n.multiple,e,!1)}}}var ls=!1;function sm(t,e,n){if(ls)return t(e,n);ls=!0;try{var o=t(e);return o}finally{if(ls=!1,(za!==null||Ua!==null)&&(Nu(),za&&(e=za,t=Ua,Ua=za=null,Np(e),t)))for(e=0;e<t.length;e++)Np(t[e])}}function ei(t,e){var n=t.stateNode;if(n===null)return null;var o=n[he]||null;if(o===null)return null;n=o[e];t:switch(e){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(o=!o.disabled)||(t=t.type,o=!(t==="button"||t==="input"||t==="select"||t==="textarea")),t=!o;break t;default:t=!1}if(t)return null;if(n&&typeof n!="function")throw Error(L(231,e,typeof n));return n}var An=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),js=!1;if(An)try{ba={},Object.defineProperty(ba,"passive",{get:function(){js=!0}}),window.addEventListener("test",ba,ba),window.removeEventListener("test",ba,ba)}catch{js=!1}var ba,Jn=null,Lf=null,Nr=null;function fm(){if(Nr)return Nr;var t,e=Lf,n=e.length,o,a="value"in Jn?Jn.value:Jn.textContent,l=a.length;for(t=0;t<n&&e[t]===a[t];t++);var i=n-t;for(o=1;o<=i&&e[n-o]===a[l-o];o++);return Nr=a.slice(t,1<o?1-o:void 0)}function Mr(t){var e=t.keyCode;return"charCode"in t?(t=t.charCode,t===0&&e===13&&(t=13)):t=e,t===10&&(t=13),32<=t||t===13?t:0}function sr(){return!0}function Mp(){return!1}function pe(t){function e(n,o,a,l,i){this._reactName=n,this._targetInst=a,this.type=o,this.nativeEvent=l,this.target=i,this.currentTarget=null;for(var r in t)t.hasOwnProperty(r)&&(n=t[r],this[r]=n?n(l):l[r]);return this.isDefaultPrevented=(l.defaultPrevented!=null?l.defaultPrevented:l.returnValue===!1)?sr:Mp,this.isPropagationStopped=Mp,this}return wt(e.prototype,{preventDefault:function(){this.defaultPrevented=!0;var n=this.nativeEvent;n&&(n.preventDefault?n.preventDefault():typeof n.returnValue!="unknown"&&(n.returnValue=!1),this.isDefaultPrevented=sr)},stopPropagation:function(){var n=this.nativeEvent;n&&(n.stopPropagation?n.stopPropagation():typeof n.cancelBubble!="unknown"&&(n.cancelBubble=!0),this.isPropagationStopped=sr)},persist:function(){},isPersistent:sr}),e}var Qo={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(t){return t.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},pu=pe(Qo),bi=wt({},Qo,{view:0,detail:0}),ew=pe(bi),is,rs,Tl,gu=wt({},bi,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:Uf,button:0,buttons:0,relatedTarget:function(t){return t.relatedTarget===void 0?t.fromElement===t.srcElement?t.toElement:t.fromElement:t.relatedTarget},movementX:function(t){return"movementX"in t?t.movementX:(t!==Tl&&(Tl&&t.type==="mousemove"?(is=t.screenX-Tl.screenX,rs=t.screenY-Tl.screenY):rs=is=0,Tl=t),is)},movementY:function(t){return"movementY"in t?t.movementY:rs}}),zp=pe(gu),nw=wt({},gu,{dataTransfer:0}),ow=pe(nw),aw=wt({},bi,{relatedTarget:0}),us=pe(aw),lw=wt({},Qo,{animationName:0,elapsedTime:0,pseudoElement:0}),iw=pe(lw),rw=wt({},Qo,{clipboardData:function(t){return"clipboardData"in t?t.clipboardData:window.clipboardData}}),uw=pe(rw),cw=wt({},Qo,{data:0}),Ap=pe(cw),sw={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},fw={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"},dw={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function hw(t){var e=this.nativeEvent;return e.getModifierState?e.getModifierState(t):(t=dw[t])?!!e[t]:!1}function Uf(){return hw}var pw=wt({},bi,{key:function(t){if(t.key){var e=sw[t.key]||t.key;if(e!=="Unidentified")return e}return t.type==="keypress"?(t=Mr(t),t===13?"Enter":String.fromCharCode(t)):t.type==="keydown"||t.type==="keyup"?fw[t.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:Uf,charCode:function(t){return t.type==="keypress"?Mr(t):0},keyCode:function(t){return t.type==="keydown"||t.type==="keyup"?t.keyCode:0},which:function(t){return t.type==="keypress"?Mr(t):t.type==="keydown"||t.type==="keyup"?t.keyCode:0}}),gw=pe(pw),mw=wt({},gu,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),Cp=pe(mw),yw=wt({},bi,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:Uf}),vw=pe(yw),bw=wt({},Qo,{propertyName:0,elapsedTime:0,pseudoElement:0}),xw=pe(bw),Sw=wt({},gu,{deltaX:function(t){return"deltaX"in t?t.deltaX:"wheelDeltaX"in t?-t.wheelDeltaX:0},deltaY:function(t){return"deltaY"in t?t.deltaY:"wheelDeltaY"in t?-t.wheelDeltaY:"wheelDelta"in t?-t.wheelDelta:0},deltaZ:0,deltaMode:0}),_w=pe(Sw),ww=wt({},Qo,{newState:0,oldState:0}),Ew=pe(ww),Nw=[9,13,27,32],Yf=An&&"CompositionEvent"in window,ql=null;An&&"documentMode"in document&&(ql=document.documentMode);var Mw=An&&"TextEvent"in window&&!ql,dm=An&&(!Yf||ql&&8<ql&&11>=ql),Tp=" ",Op=!1;function hm(t,e){switch(t){case"keyup":return Nw.indexOf(e.keyCode)!==-1;case"keydown":return e.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function pm(t){return t=t.detail,typeof t=="object"&&"data"in t?t.data:null}var Aa=!1;function zw(t,e){switch(t){case"compositionend":return pm(e);case"keypress":return e.which!==32?null:(Op=!0,Tp);case"textInput":return t=e.data,t===Tp&&Op?null:t;default:return null}}function Aw(t,e){if(Aa)return t==="compositionend"||!Yf&&hm(t,e)?(t=fm(),Nr=Lf=Jn=null,Aa=!1,t):null;switch(t){case"paste":return null;case"keypress":if(!(e.ctrlKey||e.altKey||e.metaKey)||e.ctrlKey&&e.altKey){if(e.char&&1<e.char.length)return e.char;if(e.which)return String.fromCharCode(e.which)}return null;case"compositionend":return dm&&e.locale!=="ko"?null:e.data;default:return null}}var Cw={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 Dp(t){var e=t&&t.nodeName&&t.nodeName.toLowerCase();return e==="input"?!!Cw[t.type]:e==="textarea"}function gm(t,e,n,o){za?Ua?Ua.push(o):Ua=[o]:za=o,e=iu(e,"onChange"),0<e.length&&(n=new pu("onChange","change",null,n,o),t.push({event:n,listeners:e}))}var Xl=null,ni=null;function Tw(t){sy(t,0)}function mu(t){var e=Ul(t);if(lm(e))return t}function Hp(t,e){if(t==="change")return e}var mm=!1;An&&(An?(dr="oninput"in document,dr||(cs=document.createElement("div"),cs.setAttribute("oninput","return;"),dr=typeof cs.oninput=="function"),fr=dr):fr=!1,mm=fr&&(!document.documentMode||9<document.documentMode));var fr,dr,cs;function Rp(){Xl&&(Xl.detachEvent("onpropertychange",ym),ni=Xl=null)}function ym(t){if(t.propertyName==="value"&&mu(ni)){var e=[];gm(e,ni,t,kf(t)),sm(Tw,e)}}function Ow(t,e,n){t==="focusin"?(Rp(),Xl=e,ni=n,Xl.attachEvent("onpropertychange",ym)):t==="focusout"&&Rp()}function Dw(t){if(t==="selectionchange"||t==="keyup"||t==="keydown")return mu(ni)}function Hw(t,e){if(t==="click")return mu(e)}function Rw(t,e){if(t==="input"||t==="change")return mu(e)}function Bw(t,e){return t===e&&(t!==0||1/t===1/e)||t!==t&&e!==e}var Ee=typeof Object.is=="function"?Object.is:Bw;function oi(t,e){if(Ee(t,e))return!0;if(typeof t!="object"||t===null||typeof e!="object"||e===null)return!1;var n=Object.keys(t),o=Object.keys(e);if(n.length!==o.length)return!1;for(o=0;o<n.length;o++){var a=n[o];if(!Vs.call(e,a)||!Ee(t[a],e[a]))return!1}return!0}function Bp(t){for(;t&&t.firstChild;)t=t.firstChild;return t}function kp(t,e){var n=Bp(t);t=0;for(var o;n;){if(n.nodeType===3){if(o=t+n.textContent.length,t<=e&&o>=e)return{node:n,offset:e-t};t=o}t:{for(;n;){if(n.nextSibling){n=n.nextSibling;break t}n=n.parentNode}n=void 0}n=Bp(n)}}function vm(t,e){return t&&e?t===e?!0:t&&t.nodeType===3?!1:e&&e.nodeType===3?vm(t,e.parentNode):"contains"in t?t.contains(e):t.compareDocumentPosition?!!(t.compareDocumentPosition(e)&16):!1:!1}function bm(t){t=t!=null&&t.ownerDocument!=null&&t.ownerDocument.defaultView!=null?t.ownerDocument.defaultView:window;for(var e=Xr(t.document);e instanceof t.HTMLIFrameElement;){try{var n=typeof e.contentWindow.location.href=="string"}catch{n=!1}if(n)t=e.contentWindow;else break;e=Xr(t.document)}return e}function Vf(t){var e=t&&t.nodeName&&t.nodeName.toLowerCase();return e&&(e==="input"&&(t.type==="text"||t.type==="search"||t.type==="tel"||t.type==="url"||t.type==="password")||e==="textarea"||t.contentEditable==="true")}var kw=An&&"documentMode"in document&&11>=document.documentMode,Ca=null,Ks=null,Zl=null,$s=!1;function Lp(t,e,n){var o=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;$s||Ca==null||Ca!==Xr(o)||(o=Ca,"selectionStart"in o&&Vf(o)?o={start:o.selectionStart,end:o.selectionEnd}:(o=(o.ownerDocument&&o.ownerDocument.defaultView||window).getSelection(),o={anchorNode:o.anchorNode,anchorOffset:o.anchorOffset,focusNode:o.focusNode,focusOffset:o.focusOffset}),Zl&&oi(Zl,o)||(Zl=o,o=iu(Ks,"onSelect"),0<o.length&&(e=new pu("onSelect","select",null,e,n),t.push({event:e,listeners:o}),e.target=Ca)))}function Co(t,e){var n={};return n[t.toLowerCase()]=e.toLowerCase(),n["Webkit"+t]="webkit"+e,n["Moz"+t]="moz"+e,n}var Ta={animationend:Co("Animation","AnimationEnd"),animationiteration:Co("Animation","AnimationIteration"),animationstart:Co("Animation","AnimationStart"),transitionrun:Co("Transition","TransitionRun"),transitionstart:Co("Transition","TransitionStart"),transitioncancel:Co("Transition","TransitionCancel"),transitionend:Co("Transition","TransitionEnd")},ss={},xm={};An&&(xm=document.createElement("div").style,"AnimationEvent"in window||(delete Ta.animationend.animation,delete Ta.animationiteration.animation,delete Ta.animationstart.animation),"TransitionEvent"in window||delete Ta.transitionend.transition);function jo(t){if(ss[t])return ss[t];if(!Ta[t])return t;var e=Ta[t],n;for(n in e)if(e.hasOwnProperty(n)&&n in xm)return ss[t]=e[n];return t}var Sm=jo("animationend"),_m=jo("animationiteration"),wm=jo("animationstart"),Lw=jo("transitionrun"),Uw=jo("transitionstart"),Yw=jo("transitioncancel"),Em=jo("transitionend"),Nm=new Map,Js="abort auxClick beforeToggle 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(" ");Js.push("scrollEnd");function Ge(t,e){Nm.set(t,e),Go(e,[t])}var Zr=typeof reportError=="function"?reportError:function(t){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var e=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof t=="object"&&t!==null&&typeof t.message=="string"?String(t.message):String(t),error:t});if(!window.dispatchEvent(e))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",t);return}console.error(t)},Ae=[],Oa=0,qf=0;function yu(){for(var t=Oa,e=qf=Oa=0;e<t;){var n=Ae[e];Ae[e++]=null;var o=Ae[e];Ae[e++]=null;var a=Ae[e];Ae[e++]=null;var l=Ae[e];if(Ae[e++]=null,o!==null&&a!==null){var i=o.pending;i===null?a.next=a:(a.next=i.next,i.next=a),o.pending=a}l!==0&&Mm(n,a,l)}}function vu(t,e,n,o){Ae[Oa++]=t,Ae[Oa++]=e,Ae[Oa++]=n,Ae[Oa++]=o,qf|=o,t.lanes|=o,t=t.alternate,t!==null&&(t.lanes|=o)}function Xf(t,e,n,o){return vu(t,e,n,o),Gr(t)}function Ko(t,e){return vu(t,null,null,e),Gr(t)}function Mm(t,e,n){t.lanes|=n;var o=t.alternate;o!==null&&(o.lanes|=n);for(var a=!1,l=t.return;l!==null;)l.childLanes|=n,o=l.alternate,o!==null&&(o.childLanes|=n),l.tag===22&&(t=l.stateNode,t===null||t._visibility&1||(a=!0)),t=l,l=l.return;return t.tag===3?(l=t.stateNode,a&&e!==null&&(a=31-_e(n),t=l.hiddenUpdates,o=t[a],o===null?t[a]=[e]:o.push(e),e.lane=n|536870912),l):null}function Gr(t){if(50<Fl)throw Fl=0,yf=null,Error(L(185));for(var e=t.return;e!==null;)t=e,e=t.return;return t.tag===3?t.stateNode:null}var Da={};function Vw(t,e,n,o){this.tag=t,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=e,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=o,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function ve(t,e,n,o){return new Vw(t,e,n,o)}function Zf(t){return t=t.prototype,!(!t||!t.isReactComponent)}function Nn(t,e){var n=t.alternate;return n===null?(n=ve(t.tag,e,t.key,t.mode),n.elementType=t.elementType,n.type=t.type,n.stateNode=t.stateNode,n.alternate=t,t.alternate=n):(n.pendingProps=e,n.type=t.type,n.flags=0,n.subtreeFlags=0,n.deletions=null),n.flags=t.flags&65011712,n.childLanes=t.childLanes,n.lanes=t.lanes,n.child=t.child,n.memoizedProps=t.memoizedProps,n.memoizedState=t.memoizedState,n.updateQueue=t.updateQueue,e=t.dependencies,n.dependencies=e===null?null:{lanes:e.lanes,firstContext:e.firstContext},n.sibling=t.sibling,n.index=t.index,n.ref=t.ref,n.refCleanup=t.refCleanup,n}function zm(t,e){t.flags&=65011714;var n=t.alternate;return n===null?(t.childLanes=0,t.lanes=e,t.child=null,t.subtreeFlags=0,t.memoizedProps=null,t.memoizedState=null,t.updateQueue=null,t.dependencies=null,t.stateNode=null):(t.childLanes=n.childLanes,t.lanes=n.lanes,t.child=n.child,t.subtreeFlags=0,t.deletions=null,t.memoizedProps=n.memoizedProps,t.memoizedState=n.memoizedState,t.updateQueue=n.updateQueue,t.type=n.type,e=n.dependencies,t.dependencies=e===null?null:{lanes:e.lanes,firstContext:e.firstContext}),t}function zr(t,e,n,o,a,l){var i=0;if(o=t,typeof t=="function")Zf(t)&&(i=1);else if(typeof t=="string")i=ZE(t,n,nn.current)?26:t==="html"||t==="head"||t==="body"?27:5;else t:switch(t){case ks:return t=ve(31,n,e,a),t.elementType=ks,t.lanes=l,t;case Ea:return Bo(n.children,a,l,e);case jg:i=8,a|=24;break;case Hs:return t=ve(12,n,e,a|2),t.elementType=Hs,t.lanes=l,t;case Rs:return t=ve(13,n,e,a),t.elementType=Rs,t.lanes=l,t;case Bs:return t=ve(19,n,e,a),t.elementType=Bs,t.lanes=l,t;default:if(typeof t=="object"&&t!==null)switch(t.$$typeof){case _n:i=10;break t;case Kg:i=9;break t;case Cf:i=11;break t;case Tf:i=14;break t;case Xn:i=16,o=null;break t}i=29,n=Error(L(130,t===null?"null":typeof t,"")),o=null}return e=ve(i,n,e,a),e.elementType=t,e.type=o,e.lanes=l,e}function Bo(t,e,n,o){return t=ve(7,t,o,e),t.lanes=n,t}function fs(t,e,n){return t=ve(6,t,null,e),t.lanes=n,t}function Am(t){var e=ve(18,null,null,0);return e.stateNode=t,e}function ds(t,e,n){return e=ve(4,t.children!==null?t.children:[],t.key,e),e.lanes=n,e.stateNode={containerInfo:t.containerInfo,pendingChildren:null,implementation:t.implementation},e}var Up=new WeakMap;function He(t,e){if(typeof t=="object"&&t!==null){var n=Up.get(t);return n!==void 0?n:(e={value:t,source:e,stack:bp(e)},Up.set(t,e),e)}return{value:t,source:e,stack:bp(e)}}var Ha=[],Ra=0,Qr=null,ai=0,Te=[],Oe=0,uo=null,Pe=1,tn="";function xn(t,e){Ha[Ra++]=ai,Ha[Ra++]=Qr,Qr=t,ai=e}function Cm(t,e,n){Te[Oe++]=Pe,Te[Oe++]=tn,Te[Oe++]=uo,uo=t;var o=Pe;t=tn;var a=32-_e(o)-1;o&=~(1<<a),n+=1;var l=32-_e(e)+a;if(30<l){var i=a-a%5;l=(o&(1<<i)-1).toString(32),o>>=i,a-=i,Pe=1<<32-_e(e)+a|n<<a|o,tn=l+t}else Pe=1<<l|n<<a|o,tn=t}function Gf(t){t.return!==null&&(xn(t,1),Cm(t,1,0))}function Qf(t){for(;t===Qr;)Qr=Ha[--Ra],Ha[Ra]=null,ai=Ha[--Ra],Ha[Ra]=null;for(;t===uo;)uo=Te[--Oe],Te[Oe]=null,tn=Te[--Oe],Te[Oe]=null,Pe=Te[--Oe],Te[Oe]=null}function Tm(t,e){Te[Oe++]=Pe,Te[Oe++]=tn,Te[Oe++]=uo,Pe=e.id,tn=e.overflow,uo=t}var $t=null,_t=null,rt=!1,to=null,Re=!1,Is=Error(L(519));function co(t){var e=Error(L(418,1<arguments.length&&arguments[1]!==void 0&&arguments[1]?"text":"HTML",""));throw li(He(e,t)),Is}function Yp(t){var e=t.stateNode,n=t.type,o=t.memoizedProps;switch(e[Kt]=t,e[he]=o,n){case"dialog":at("cancel",e),at("close",e);break;case"iframe":case"object":case"embed":at("load",e);break;case"video":case"audio":for(n=0;n<ci.length;n++)at(ci[n],e);break;case"source":at("error",e);break;case"img":case"image":case"link":at("error",e),at("load",e);break;case"details":at("toggle",e);break;case"input":at("invalid",e),im(e,o.value,o.defaultValue,o.checked,o.defaultChecked,o.type,o.name,!0);break;case"select":at("invalid",e);break;case"textarea":at("invalid",e),um(e,o.value,o.defaultValue,o.children)}n=o.children,typeof n!="string"&&typeof n!="number"&&typeof n!="bigint"||e.textContent===""+n||o.suppressHydrationWarning===!0||dy(e.textContent,n)?(o.popover!=null&&(at("beforetoggle",e),at("toggle",e)),o.onScroll!=null&&at("scroll",e),o.onScrollEnd!=null&&at("scrollend",e),o.onClick!=null&&(e.onclick=wn),e=!0):e=!1,e||co(t,!0)}function Vp(t){for($t=t.return;$t;)switch($t.tag){case 5:case 31:case 13:Re=!1;return;case 27:case 3:Re=!0;return;default:$t=$t.return}}function xa(t){if(t!==$t)return!1;if(!rt)return Vp(t),rt=!0,!1;var e=t.tag,n;if((n=e!==3&&e!==27)&&((n=e===5)&&(n=t.type,n=!(n!=="form"&&n!=="button")||_f(t.type,t.memoizedProps)),n=!n),n&&_t&&co(t),Vp(t),e===13){if(t=t.memoizedState,t=t!==null?t.dehydrated:null,!t)throw Error(L(317));_t=Ag(t)}else if(e===31){if(t=t.memoizedState,t=t!==null?t.dehydrated:null,!t)throw Error(L(317));_t=Ag(t)}else e===27?(e=_t,po(t.type)?(t=Mf,Mf=null,_t=t):_t=e):_t=$t?ke(t.stateNode.nextSibling):null;return!0}function Yo(){_t=$t=null,rt=!1}function hs(){var t=to;return t!==null&&(fe===null?fe=t:fe.push.apply(fe,t),to=null),t}function li(t){to===null?to=[t]:to.push(t)}var Ws=on(null),$o=null,En=null;function Gn(t,e,n){bt(Ws,e._currentValue),e._currentValue=n}function Mn(t){t._currentValue=Ws.current,Gt(Ws)}function Fs(t,e,n){for(;t!==null;){var o=t.alternate;if((t.childLanes&e)!==e?(t.childLanes|=e,o!==null&&(o.childLanes|=e)):o!==null&&(o.childLanes&e)!==e&&(o.childLanes|=e),t===n)break;t=t.return}}function Ps(t,e,n,o){var a=t.child;for(a!==null&&(a.return=t);a!==null;){var l=a.dependencies;if(l!==null){var i=a.child;l=l.firstContext;t:for(;l!==null;){var r=l;l=a;for(var u=0;u<e.length;u++)if(r.context===e[u]){l.lanes|=n,r=l.alternate,r!==null&&(r.lanes|=n),Fs(l.return,n,t),o||(i=null);break t}l=r.next}}else if(a.tag===18){if(i=a.return,i===null)throw Error(L(341));i.lanes|=n,l=i.alternate,l!==null&&(l.lanes|=n),Fs(i,n,t),i=null}else i=a.child;if(i!==null)i.return=a;else for(i=a;i!==null;){if(i===t){i=null;break}if(a=i.sibling,a!==null){a.return=i.return,i=a;break}i=i.return}a=i}}function nl(t,e,n,o){t=null;for(var a=e,l=!1;a!==null;){if(!l){if((a.flags&524288)!==0)l=!0;else if((a.flags&262144)!==0)break}if(a.tag===10){var i=a.alternate;if(i===null)throw Error(L(387));if(i=i.memoizedProps,i!==null){var r=a.type;Ee(a.pendingProps.value,i.value)||(t!==null?t.push(r):t=[r])}}else if(a===Ur.current){if(i=a.alternate,i===null)throw Error(L(387));i.memoizedState.memoizedState!==a.memoizedState.memoizedState&&(t!==null?t.push(fi):t=[fi])}a=a.return}t!==null&&Ps(e,t,n,o),e.flags|=262144}function jr(t){for(t=t.firstContext;t!==null;){if(!Ee(t.context._currentValue,t.memoizedValue))return!0;t=t.next}return!1}function Vo(t){$o=t,En=null,t=t.dependencies,t!==null&&(t.firstContext=null)}function Jt(t){return Om($o,t)}function hr(t,e){return $o===null&&Vo(t),Om(t,e)}function Om(t,e){var n=e._currentValue;if(e={context:e,memoizedValue:n,next:null},En===null){if(t===null)throw Error(L(308));En=e,t.dependencies={lanes:0,firstContext:e},t.flags|=524288}else En=En.next=e;return n}var qw=typeof AbortController<"u"?AbortController:function(){var t=[],e=this.signal={aborted:!1,addEventListener:function(n,o){t.push(o)}};this.abort=function(){e.aborted=!0,t.forEach(function(n){return n()})}},Xw=Vt.unstable_scheduleCallback,Zw=Vt.unstable_NormalPriority,Lt={$$typeof:_n,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function jf(){return{controller:new qw,data:new Map,refCount:0}}function xi(t){t.refCount--,t.refCount===0&&Xw(Zw,function(){t.controller.abort()})}var Gl=null,tf=0,ja=0,Ya=null;function Gw(t,e){if(Gl===null){var n=Gl=[];tf=0,ja=yd(),Ya={status:"pending",value:void 0,then:function(o){n.push(o)}}}return tf++,e.then(qp,qp),e}function qp(){if(--tf===0&&Gl!==null){Ya!==null&&(Ya.status="fulfilled");var t=Gl;Gl=null,ja=0,Ya=null;for(var e=0;e<t.length;e++)(0,t[e])()}}function Qw(t,e){var n=[],o={status:"pending",value:null,reason:null,then:function(a){n.push(a)}};return t.then(function(){o.status="fulfilled",o.value=e;for(var a=0;a<n.length;a++)(0,n[a])(e)},function(a){for(o.status="rejected",o.reason=a,a=0;a<n.length;a++)(0,n[a])(void 0)}),o}var Xp=F.S;F.S=function(t,e){Q0=xe(),typeof e=="object"&&e!==null&&typeof e.then=="function"&&Gw(t,e),Xp!==null&&Xp(t,e)};var ko=on(null);function Kf(){var t=ko.current;return t!==null?t:vt.pooledCache}function Ar(t,e){e===null?bt(ko,ko.current):bt(ko,e.pool)}function Dm(){var t=Kf();return t===null?null:{parent:Lt._currentValue,pool:t}}var ol=Error(L(460)),$f=Error(L(474)),bu=Error(L(542)),Kr={then:function(){}};function Zp(t){return t=t.status,t==="fulfilled"||t==="rejected"}function Hm(t,e,n){switch(n=t[n],n===void 0?t.push(e):n!==e&&(e.then(wn,wn),e=n),e.status){case"fulfilled":return e.value;case"rejected":throw t=e.reason,Qp(t),t;default:if(typeof e.status=="string")e.then(wn,wn);else{if(t=vt,t!==null&&100<t.shellSuspendCounter)throw Error(L(482));t=e,t.status="pending",t.then(function(o){if(e.status==="pending"){var a=e;a.status="fulfilled",a.value=o}},function(o){if(e.status==="pending"){var a=e;a.status="rejected",a.reason=o}})}switch(e.status){case"fulfilled":return e.value;case"rejected":throw t=e.reason,Qp(t),t}throw Lo=e,ol}}function Do(t){try{var e=t._init;return e(t._payload)}catch(n){throw n!==null&&typeof n=="object"&&typeof n.then=="function"?(Lo=n,ol):n}}var Lo=null;function Gp(){if(Lo===null)throw Error(L(459));var t=Lo;return Lo=null,t}function Qp(t){if(t===ol||t===bu)throw Error(L(483))}var Va=null,ii=0;function pr(t){var e=ii;return ii+=1,Va===null&&(Va=[]),Hm(Va,t,e)}function Ol(t,e){e=e.props.ref,t.ref=e!==void 0?e:null}function gr(t,e){throw e.$$typeof===O_?Error(L(525)):(t=Object.prototype.toString.call(e),Error(L(31,t==="[object Object]"?"object with keys {"+Object.keys(e).join(", ")+"}":t)))}function Rm(t){function e(g,m){if(t){var h=g.deletions;h===null?(g.deletions=[m],g.flags|=16):h.push(m)}}function n(g,m){if(!t)return null;for(;m!==null;)e(g,m),m=m.sibling;return null}function o(g){for(var m=new Map;g!==null;)g.key!==null?m.set(g.key,g):m.set(g.index,g),g=g.sibling;return m}function a(g,m){return g=Nn(g,m),g.index=0,g.sibling=null,g}function l(g,m,h){return g.index=h,t?(h=g.alternate,h!==null?(h=h.index,h<m?(g.flags|=67108866,m):h):(g.flags|=67108866,m)):(g.flags|=1048576,m)}function i(g){return t&&g.alternate===null&&(g.flags|=67108866),g}function r(g,m,h,v){return m===null||m.tag!==6?(m=fs(h,g.mode,v),m.return=g,m):(m=a(m,h),m.return=g,m)}function u(g,m,h,v){var _=h.type;return _===Ea?c(g,m,h.props.children,v,h.key):m!==null&&(m.elementType===_||typeof _=="object"&&_!==null&&_.$$typeof===Xn&&Do(_)===m.type)?(m=a(m,h.props),Ol(m,h),m.return=g,m):(m=zr(h.type,h.key,h.props,null,g.mode,v),Ol(m,h),m.return=g,m)}function s(g,m,h,v){return m===null||m.tag!==4||m.stateNode.containerInfo!==h.containerInfo||m.stateNode.implementation!==h.implementation?(m=ds(h,g.mode,v),m.return=g,m):(m=a(m,h.children||[]),m.return=g,m)}function c(g,m,h,v,_){return m===null||m.tag!==7?(m=Bo(h,g.mode,v,_),m.return=g,m):(m=a(m,h),m.return=g,m)}function d(g,m,h){if(typeof m=="string"&&m!==""||typeof m=="number"||typeof m=="bigint")return m=fs(""+m,g.mode,h),m.return=g,m;if(typeof m=="object"&&m!==null){switch(m.$$typeof){case lr:return h=zr(m.type,m.key,m.props,null,g.mode,h),Ol(h,m),h.return=g,h;case kl:return m=ds(m,g.mode,h),m.return=g,m;case Xn:return m=Do(m),d(g,m,h)}if(Ll(m)||Cl(m))return m=Bo(m,g.mode,h,null),m.return=g,m;if(typeof m.then=="function")return d(g,pr(m),h);if(m.$$typeof===_n)return d(g,hr(g,m),h);gr(g,m)}return null}function f(g,m,h,v){var _=m!==null?m.key:null;if(typeof h=="string"&&h!==""||typeof h=="number"||typeof h=="bigint")return _!==null?null:r(g,m,""+h,v);if(typeof h=="object"&&h!==null){switch(h.$$typeof){case lr:return h.key===_?u(g,m,h,v):null;case kl:return h.key===_?s(g,m,h,v):null;case Xn:return h=Do(h),f(g,m,h,v)}if(Ll(h)||Cl(h))return _!==null?null:c(g,m,h,v,null);if(typeof h.then=="function")return f(g,m,pr(h),v);if(h.$$typeof===_n)return f(g,m,hr(g,h),v);gr(g,h)}return null}function p(g,m,h,v,_){if(typeof v=="string"&&v!==""||typeof v=="number"||typeof v=="bigint")return g=g.get(h)||null,r(m,g,""+v,_);if(typeof v=="object"&&v!==null){switch(v.$$typeof){case lr:return g=g.get(v.key===null?h:v.key)||null,u(m,g,v,_);case kl:return g=g.get(v.key===null?h:v.key)||null,s(m,g,v,_);case Xn:return v=Do(v),p(g,m,h,v,_)}if(Ll(v)||Cl(v))return g=g.get(h)||null,c(m,g,v,_,null);if(typeof v.then=="function")return p(g,m,h,pr(v),_);if(v.$$typeof===_n)return p(g,m,h,hr(m,v),_);gr(m,v)}return null}function y(g,m,h,v){for(var _=null,E=null,w=m,N=m=0,M=null;w!==null&&N<h.length;N++){w.index>N?(M=w,w=null):M=w.sibling;var R=f(g,w,h[N],v);if(R===null){w===null&&(w=M);break}t&&w&&R.alternate===null&&e(g,w),m=l(R,m,N),E===null?_=R:E.sibling=R,E=R,w=M}if(N===h.length)return n(g,w),rt&&xn(g,N),_;if(w===null){for(;N<h.length;N++)w=d(g,h[N],v),w!==null&&(m=l(w,m,N),E===null?_=w:E.sibling=w,E=w);return rt&&xn(g,N),_}for(w=o(w);N<h.length;N++)M=p(w,g,N,h[N],v),M!==null&&(t&&M.alternate!==null&&w.delete(M.key===null?N:M.key),m=l(M,m,N),E===null?_=M:E.sibling=M,E=M);return t&&w.forEach(function(C){return e(g,C)}),rt&&xn(g,N),_}function b(g,m,h,v){if(h==null)throw Error(L(151));for(var _=null,E=null,w=m,N=m=0,M=null,R=h.next();w!==null&&!R.done;N++,R=h.next()){w.index>N?(M=w,w=null):M=w.sibling;var C=f(g,w,R.value,v);if(C===null){w===null&&(w=M);break}t&&w&&C.alternate===null&&e(g,w),m=l(C,m,N),E===null?_=C:E.sibling=C,E=C,w=M}if(R.done)return n(g,w),rt&&xn(g,N),_;if(w===null){for(;!R.done;N++,R=h.next())R=d(g,R.value,v),R!==null&&(m=l(R,m,N),E===null?_=R:E.sibling=R,E=R);return rt&&xn(g,N),_}for(w=o(w);!R.done;N++,R=h.next())R=p(w,g,N,R.value,v),R!==null&&(t&&R.alternate!==null&&w.delete(R.key===null?N:R.key),m=l(R,m,N),E===null?_=R:E.sibling=R,E=R);return t&&w.forEach(function(k){return e(g,k)}),rt&&xn(g,N),_}function x(g,m,h,v){if(typeof h=="object"&&h!==null&&h.type===Ea&&h.key===null&&(h=h.props.children),typeof h=="object"&&h!==null){switch(h.$$typeof){case lr:t:{for(var _=h.key;m!==null;){if(m.key===_){if(_=h.type,_===Ea){if(m.tag===7){n(g,m.sibling),v=a(m,h.props.children),v.return=g,g=v;break t}}else if(m.elementType===_||typeof _=="object"&&_!==null&&_.$$typeof===Xn&&Do(_)===m.type){n(g,m.sibling),v=a(m,h.props),Ol(v,h),v.return=g,g=v;break t}n(g,m);break}else e(g,m);m=m.sibling}h.type===Ea?(v=Bo(h.props.children,g.mode,v,h.key),v.return=g,g=v):(v=zr(h.type,h.key,h.props,null,g.mode,v),Ol(v,h),v.return=g,g=v)}return i(g);case kl:t:{for(_=h.key;m!==null;){if(m.key===_)if(m.tag===4&&m.stateNode.containerInfo===h.containerInfo&&m.stateNode.implementation===h.implementation){n(g,m.sibling),v=a(m,h.children||[]),v.return=g,g=v;break t}else{n(g,m);break}else e(g,m);m=m.sibling}v=ds(h,g.mode,v),v.return=g,g=v}return i(g);case Xn:return h=Do(h),x(g,m,h,v)}if(Ll(h))return y(g,m,h,v);if(Cl(h)){if(_=Cl(h),typeof _!="function")throw Error(L(150));return h=_.call(h),b(g,m,h,v)}if(typeof h.then=="function")return x(g,m,pr(h),v);if(h.$$typeof===_n)return x(g,m,hr(g,h),v);gr(g,h)}return typeof h=="string"&&h!==""||typeof h=="number"||typeof h=="bigint"?(h=""+h,m!==null&&m.tag===6?(n(g,m.sibling),v=a(m,h),v.return=g,g=v):(n(g,m),v=fs(h,g.mode,v),v.return=g,g=v),i(g)):n(g,m)}return function(g,m,h,v){try{ii=0;var _=x(g,m,h,v);return Va=null,_}catch(w){if(w===ol||w===bu)throw w;var E=ve(29,w,null,g.mode);return E.lanes=v,E.return=g,E}}}var qo=Rm(!0),Bm=Rm(!1),Zn=!1;function Jf(t){t.updateQueue={baseState:t.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function ef(t,e){t=t.updateQueue,e.updateQueue===t&&(e.updateQueue={baseState:t.baseState,firstBaseUpdate:t.firstBaseUpdate,lastBaseUpdate:t.lastBaseUpdate,shared:t.shared,callbacks:null})}function eo(t){return{lane:t,tag:0,payload:null,callback:null,next:null}}function no(t,e,n){var o=t.updateQueue;if(o===null)return null;if(o=o.shared,(st&2)!==0){var a=o.pending;return a===null?e.next=e:(e.next=a.next,a.next=e),o.pending=e,e=Gr(t),Mm(t,null,n),e}return vu(t,o,e,n),Gr(t)}function Ql(t,e,n){if(e=e.updateQueue,e!==null&&(e=e.shared,(n&4194048)!==0)){var o=e.lanes;o&=t.pendingLanes,n|=o,e.lanes=n,Pg(t,n)}}function ps(t,e){var n=t.updateQueue,o=t.alternate;if(o!==null&&(o=o.updateQueue,n===o)){var a=null,l=null;if(n=n.firstBaseUpdate,n!==null){do{var i={lane:n.lane,tag:n.tag,payload:n.payload,callback:null,next:null};l===null?a=l=i:l=l.next=i,n=n.next}while(n!==null);l===null?a=l=e:l=l.next=e}else a=l=e;n={baseState:o.baseState,firstBaseUpdate:a,lastBaseUpdate:l,shared:o.shared,callbacks:o.callbacks},t.updateQueue=n;return}t=n.lastBaseUpdate,t===null?n.firstBaseUpdate=e:t.next=e,n.lastBaseUpdate=e}var nf=!1;function jl(){if(nf){var t=Ya;if(t!==null)throw t}}function Kl(t,e,n,o){nf=!1;var a=t.updateQueue;Zn=!1;var l=a.firstBaseUpdate,i=a.lastBaseUpdate,r=a.shared.pending;if(r!==null){a.shared.pending=null;var u=r,s=u.next;u.next=null,i===null?l=s:i.next=s,i=u;var c=t.alternate;c!==null&&(c=c.updateQueue,r=c.lastBaseUpdate,r!==i&&(r===null?c.firstBaseUpdate=s:r.next=s,c.lastBaseUpdate=u))}if(l!==null){var d=a.baseState;i=0,c=s=u=null,r=l;do{var f=r.lane&-536870913,p=f!==r.lane;if(p?(it&f)===f:(o&f)===f){f!==0&&f===ja&&(nf=!0),c!==null&&(c=c.next={lane:0,tag:r.tag,payload:r.payload,callback:null,next:null});t:{var y=t,b=r;f=e;var x=n;switch(b.tag){case 1:if(y=b.payload,typeof y=="function"){d=y.call(x,d,f);break t}d=y;break t;case 3:y.flags=y.flags&-65537|128;case 0:if(y=b.payload,f=typeof y=="function"?y.call(x,d,f):y,f==null)break t;d=wt({},d,f);break t;case 2:Zn=!0}}f=r.callback,f!==null&&(t.flags|=64,p&&(t.flags|=8192),p=a.callbacks,p===null?a.callbacks=[f]:p.push(f))}else p={lane:f,tag:r.tag,payload:r.payload,callback:r.callback,next:null},c===null?(s=c=p,u=d):c=c.next=p,i|=f;if(r=r.next,r===null){if(r=a.shared.pending,r===null)break;p=r,r=p.next,p.next=null,a.lastBaseUpdate=p,a.shared.pending=null}}while(!0);c===null&&(u=d),a.baseState=u,a.firstBaseUpdate=s,a.lastBaseUpdate=c,l===null&&(a.shared.lanes=0),fo|=i,t.lanes=i,t.memoizedState=d}}function km(t,e){if(typeof t!="function")throw Error(L(191,t));t.call(e)}function Lm(t,e){var n=t.callbacks;if(n!==null)for(t.callbacks=null,t=0;t<n.length;t++)km(n[t],e)}var Ka=on(null),$r=on(0);function jp(t,e){t=Dn,bt($r,t),bt(Ka,e),Dn=t|e.baseLanes}function of(){bt($r,Dn),bt(Ka,Ka.current)}function If(){Dn=$r.current,Gt(Ka),Gt($r)}var Ne=on(null),Be=null;function Qn(t){var e=t.alternate;bt(Ht,Ht.current&1),bt(Ne,t),Be===null&&(e===null||Ka.current!==null||e.memoizedState!==null)&&(Be=t)}function af(t){bt(Ht,Ht.current),bt(Ne,t),Be===null&&(Be=t)}function Um(t){t.tag===22?(bt(Ht,Ht.current),bt(Ne,t),Be===null&&(Be=t)):jn(t)}function jn(){bt(Ht,Ht.current),bt(Ne,Ne.current)}function ye(t){Gt(Ne),Be===t&&(Be=null),Gt(Ht)}var Ht=on(0);function Jr(t){for(var e=t;e!==null;){if(e.tag===13){var n=e.memoizedState;if(n!==null&&(n=n.dehydrated,n===null||Ef(n)||Nf(n)))return e}else if(e.tag===19&&(e.memoizedProps.revealOrder==="forwards"||e.memoizedProps.revealOrder==="backwards"||e.memoizedProps.revealOrder==="unstable_legacy-backwards"||e.memoizedProps.revealOrder==="together")){if((e.flags&128)!==0)return e}else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break;for(;e.sibling===null;){if(e.return===null||e.return===t)return null;e=e.return}e.sibling.return=e.return,e=e.sibling}return null}var Cn=0,et=null,yt=null,Bt=null,Ir=!1,qa=!1,Xo=!1,Wr=0,ri=0,Xa=null,jw=0;function At(){throw Error(L(321))}function Wf(t,e){if(e===null)return!1;for(var n=0;n<e.length&&n<t.length;n++)if(!Ee(t[n],e[n]))return!1;return!0}function Ff(t,e,n,o,a,l){return Cn=l,et=e,e.memoizedState=null,e.updateQueue=null,e.lanes=0,F.H=t===null||t.memoizedState===null?g0:cd,Xo=!1,l=n(o,a),Xo=!1,qa&&(l=Vm(e,n,o,a)),Ym(t),l}function Ym(t){F.H=ui;var e=yt!==null&&yt.next!==null;if(Cn=0,Bt=yt=et=null,Ir=!1,ri=0,Xa=null,e)throw Error(L(300));t===null||Ut||(t=t.dependencies,t!==null&&jr(t)&&(Ut=!0))}function Vm(t,e,n,o){et=t;var a=0;do{if(qa&&(Xa=null),ri=0,qa=!1,25<=a)throw Error(L(301));if(a+=1,Bt=yt=null,t.updateQueue!=null){var l=t.updateQueue;l.lastEffect=null,l.events=null,l.stores=null,l.memoCache!=null&&(l.memoCache.index=0)}F.H=m0,l=e(n,o)}while(qa);return l}function Kw(){var t=F.H,e=t.useState()[0];return e=typeof e.then=="function"?Si(e):e,t=t.useState()[0],(yt!==null?yt.memoizedState:null)!==t&&(et.flags|=1024),e}function Pf(){var t=Wr!==0;return Wr=0,t}function td(t,e,n){e.updateQueue=t.updateQueue,e.flags&=-2053,t.lanes&=~n}function ed(t){if(Ir){for(t=t.memoizedState;t!==null;){var e=t.queue;e!==null&&(e.pending=null),t=t.next}Ir=!1}Cn=0,Bt=yt=et=null,qa=!1,ri=Wr=0,Xa=null}function ne(){var t={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return Bt===null?et.memoizedState=Bt=t:Bt=Bt.next=t,Bt}function Rt(){if(yt===null){var t=et.alternate;t=t!==null?t.memoizedState:null}else t=yt.next;var e=Bt===null?et.memoizedState:Bt.next;if(e!==null)Bt=e,yt=t;else{if(t===null)throw et.alternate===null?Error(L(467)):Error(L(310));yt=t,t={memoizedState:yt.memoizedState,baseState:yt.baseState,baseQueue:yt.baseQueue,queue:yt.queue,next:null},Bt===null?et.memoizedState=Bt=t:Bt=Bt.next=t}return Bt}function xu(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function Si(t){var e=ri;return ri+=1,Xa===null&&(Xa=[]),t=Hm(Xa,t,e),e=et,(Bt===null?e.memoizedState:Bt.next)===null&&(e=e.alternate,F.H=e===null||e.memoizedState===null?g0:cd),t}function Su(t){if(t!==null&&typeof t=="object"){if(typeof t.then=="function")return Si(t);if(t.$$typeof===_n)return Jt(t)}throw Error(L(438,String(t)))}function nd(t){var e=null,n=et.updateQueue;if(n!==null&&(e=n.memoCache),e==null){var o=et.alternate;o!==null&&(o=o.updateQueue,o!==null&&(o=o.memoCache,o!=null&&(e={data:o.data.map(function(a){return a.slice()}),index:0})))}if(e==null&&(e={data:[],index:0}),n===null&&(n=xu(),et.updateQueue=n),n.memoCache=e,n=e.data[e.index],n===void 0)for(n=e.data[e.index]=Array(t),o=0;o<t;o++)n[o]=D_;return e.index++,n}function Tn(t,e){return typeof e=="function"?e(t):e}function Cr(t){var e=Rt();return od(e,yt,t)}function od(t,e,n){var o=t.queue;if(o===null)throw Error(L(311));o.lastRenderedReducer=n;var a=t.baseQueue,l=o.pending;if(l!==null){if(a!==null){var i=a.next;a.next=l.next,l.next=i}e.baseQueue=a=l,o.pending=null}if(l=t.baseState,a===null)t.memoizedState=l;else{e=a.next;var r=i=null,u=null,s=e,c=!1;do{var d=s.lane&-536870913;if(d!==s.lane?(it&d)===d:(Cn&d)===d){var f=s.revertLane;if(f===0)u!==null&&(u=u.next={lane:0,revertLane:0,gesture:null,action:s.action,hasEagerState:s.hasEagerState,eagerState:s.eagerState,next:null}),d===ja&&(c=!0);else if((Cn&f)===f){s=s.next,f===ja&&(c=!0);continue}else d={lane:0,revertLane:s.revertLane,gesture:null,action:s.action,hasEagerState:s.hasEagerState,eagerState:s.eagerState,next:null},u===null?(r=u=d,i=l):u=u.next=d,et.lanes|=f,fo|=f;d=s.action,Xo&&n(l,d),l=s.hasEagerState?s.eagerState:n(l,d)}else f={lane:d,revertLane:s.revertLane,gesture:s.gesture,action:s.action,hasEagerState:s.hasEagerState,eagerState:s.eagerState,next:null},u===null?(r=u=f,i=l):u=u.next=f,et.lanes|=d,fo|=d;s=s.next}while(s!==null&&s!==e);if(u===null?i=l:u.next=r,!Ee(l,t.memoizedState)&&(Ut=!0,c&&(n=Ya,n!==null)))throw n;t.memoizedState=l,t.baseState=i,t.baseQueue=u,o.lastRenderedState=l}return a===null&&(o.lanes=0),[t.memoizedState,o.dispatch]}function gs(t){var e=Rt(),n=e.queue;if(n===null)throw Error(L(311));n.lastRenderedReducer=t;var o=n.dispatch,a=n.pending,l=e.memoizedState;if(a!==null){n.pending=null;var i=a=a.next;do l=t(l,i.action),i=i.next;while(i!==a);Ee(l,e.memoizedState)||(Ut=!0),e.memoizedState=l,e.baseQueue===null&&(e.baseState=l),n.lastRenderedState=l}return[l,o]}function qm(t,e,n){var o=et,a=Rt(),l=rt;if(l){if(n===void 0)throw Error(L(407));n=n()}else n=e();var i=!Ee((yt||a).memoizedState,n);if(i&&(a.memoizedState=n,Ut=!0),a=a.queue,ad(Gm.bind(null,o,a,t),[t]),a.getSnapshot!==e||i||Bt!==null&&Bt.memoizedState.tag&1){if(o.flags|=2048,$a(9,{destroy:void 0},Zm.bind(null,o,a,n,e),null),vt===null)throw Error(L(349));l||(Cn&127)!==0||Xm(o,e,n)}return n}function Xm(t,e,n){t.flags|=16384,t={getSnapshot:e,value:n},e=et.updateQueue,e===null?(e=xu(),et.updateQueue=e,e.stores=[t]):(n=e.stores,n===null?e.stores=[t]:n.push(t))}function Zm(t,e,n,o){e.value=n,e.getSnapshot=o,Qm(e)&&jm(t)}function Gm(t,e,n){return n(function(){Qm(e)&&jm(t)})}function Qm(t){var e=t.getSnapshot;t=t.value;try{var n=e();return!Ee(t,n)}catch{return!0}}function jm(t){var e=Ko(t,2);e!==null&&de(e,t,2)}function lf(t){var e=ne();if(typeof t=="function"){var n=t;if(t=n(),Xo){$n(!0);try{n()}finally{$n(!1)}}}return e.memoizedState=e.baseState=t,e.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Tn,lastRenderedState:t},e}function Km(t,e,n,o){return t.baseState=n,od(t,yt,typeof o=="function"?o:Tn)}function $w(t,e,n,o,a){if(wu(t))throw Error(L(485));if(t=e.action,t!==null){var l={payload:a,action:t,next:null,isTransition:!0,status:"pending",value:null,reason:null,listeners:[],then:function(i){l.listeners.push(i)}};F.T!==null?n(!0):l.isTransition=!1,o(l),n=e.pending,n===null?(l.next=e.pending=l,$m(e,l)):(l.next=n.next,e.pending=n.next=l)}}function $m(t,e){var n=e.action,o=e.payload,a=t.state;if(e.isTransition){var l=F.T,i={};F.T=i;try{var r=n(a,o),u=F.S;u!==null&&u(i,r),Kp(t,e,r)}catch(s){rf(t,e,s)}finally{l!==null&&i.types!==null&&(l.types=i.types),F.T=l}}else try{l=n(a,o),Kp(t,e,l)}catch(s){rf(t,e,s)}}function Kp(t,e,n){n!==null&&typeof n=="object"&&typeof n.then=="function"?n.then(function(o){$p(t,e,o)},function(o){return rf(t,e,o)}):$p(t,e,n)}function $p(t,e,n){e.status="fulfilled",e.value=n,Jm(e),t.state=n,e=t.pending,e!==null&&(n=e.next,n===e?t.pending=null:(n=n.next,e.next=n,$m(t,n)))}function rf(t,e,n){var o=t.pending;if(t.pending=null,o!==null){o=o.next;do e.status="rejected",e.reason=n,Jm(e),e=e.next;while(e!==o)}t.action=null}function Jm(t){t=t.listeners;for(var e=0;e<t.length;e++)(0,t[e])()}function Im(t,e){return e}function Jp(t,e){if(rt){var n=vt.formState;if(n!==null){t:{var o=et;if(rt){if(_t){e:{for(var a=_t,l=Re;a.nodeType!==8;){if(!l){a=null;break e}if(a=ke(a.nextSibling),a===null){a=null;break e}}l=a.data,a=l==="F!"||l==="F"?a:null}if(a){_t=ke(a.nextSibling),o=a.data==="F!";break t}}co(o)}o=!1}o&&(e=n[0])}}return n=ne(),n.memoizedState=n.baseState=e,o={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Im,lastRenderedState:e},n.queue=o,n=d0.bind(null,et,o),o.dispatch=n,o=lf(!1),l=ud.bind(null,et,!1,o.queue),o=ne(),a={state:e,dispatch:null,action:t,pending:null},o.queue=a,n=$w.bind(null,et,a,l,n),a.dispatch=n,o.memoizedState=t,[e,n,!1]}function Ip(t){var e=Rt();return Wm(e,yt,t)}function Wm(t,e,n){if(e=od(t,e,Im)[0],t=Cr(Tn)[0],typeof e=="object"&&e!==null&&typeof e.then=="function")try{var o=Si(e)}catch(i){throw i===ol?bu:i}else o=e;e=Rt();var a=e.queue,l=a.dispatch;return n!==e.memoizedState&&(et.flags|=2048,$a(9,{destroy:void 0},Jw.bind(null,a,n),null)),[o,l,t]}function Jw(t,e){t.action=e}function Wp(t){var e=Rt(),n=yt;if(n!==null)return Wm(e,n,t);Rt(),e=e.memoizedState,n=Rt();var o=n.queue.dispatch;return n.memoizedState=t,[e,o,!1]}function $a(t,e,n,o){return t={tag:t,create:n,deps:o,inst:e,next:null},e=et.updateQueue,e===null&&(e=xu(),et.updateQueue=e),n=e.lastEffect,n===null?e.lastEffect=t.next=t:(o=n.next,n.next=t,t.next=o,e.lastEffect=t),t}function Fm(){return Rt().memoizedState}function Tr(t,e,n,o){var a=ne();et.flags|=t,a.memoizedState=$a(1|e,{destroy:void 0},n,o===void 0?null:o)}function _u(t,e,n,o){var a=Rt();o=o===void 0?null:o;var l=a.memoizedState.inst;yt!==null&&o!==null&&Wf(o,yt.memoizedState.deps)?a.memoizedState=$a(e,l,n,o):(et.flags|=t,a.memoizedState=$a(1|e,l,n,o))}function Fp(t,e){Tr(8390656,8,t,e)}function ad(t,e){_u(2048,8,t,e)}function Iw(t){et.flags|=4;var e=et.updateQueue;if(e===null)e=xu(),et.updateQueue=e,e.events=[t];else{var n=e.events;n===null?e.events=[t]:n.push(t)}}function Pm(t){var e=Rt().memoizedState;return Iw({ref:e,nextImpl:t}),function(){if((st&2)!==0)throw Error(L(440));return e.impl.apply(void 0,arguments)}}function t0(t,e){return _u(4,2,t,e)}function e0(t,e){return _u(4,4,t,e)}function n0(t,e){if(typeof e=="function"){t=t();var n=e(t);return function(){typeof n=="function"?n():e(null)}}if(e!=null)return t=t(),e.current=t,function(){e.current=null}}function o0(t,e,n){n=n!=null?n.concat([t]):null,_u(4,4,n0.bind(null,e,t),n)}function ld(){}function a0(t,e){var n=Rt();e=e===void 0?null:e;var o=n.memoizedState;return e!==null&&Wf(e,o[1])?o[0]:(n.memoizedState=[t,e],t)}function l0(t,e){var n=Rt();e=e===void 0?null:e;var o=n.memoizedState;if(e!==null&&Wf(e,o[1]))return o[0];if(o=t(),Xo){$n(!0);try{t()}finally{$n(!1)}}return n.memoizedState=[o,e],o}function id(t,e,n){return n===void 0||(Cn&1073741824)!==0&&(it&261930)===0?t.memoizedState=e:(t.memoizedState=n,t=K0(),et.lanes|=t,fo|=t,n)}function i0(t,e,n,o){return Ee(n,e)?n:Ka.current!==null?(t=id(t,n,o),Ee(t,e)||(Ut=!0),t):(Cn&42)===0||(Cn&1073741824)!==0&&(it&261930)===0?(Ut=!0,t.memoizedState=n):(t=K0(),et.lanes|=t,fo|=t,e)}function r0(t,e,n,o,a){var l=ft.p;ft.p=l!==0&&8>l?l:8;var i=F.T,r={};F.T=r,ud(t,!1,e,n);try{var u=a(),s=F.S;if(s!==null&&s(r,u),u!==null&&typeof u=="object"&&typeof u.then=="function"){var c=Qw(u,o);$l(t,e,c,we(t))}else $l(t,e,o,we(t))}catch(d){$l(t,e,{then:function(){},status:"rejected",reason:d},we())}finally{ft.p=l,i!==null&&r.types!==null&&(i.types=r.types),F.T=i}}function Ww(){}function uf(t,e,n,o){if(t.tag!==5)throw Error(L(476));var a=u0(t).queue;r0(t,a,e,Ro,n===null?Ww:function(){return c0(t),n(o)})}function u0(t){var e=t.memoizedState;if(e!==null)return e;e={memoizedState:Ro,baseState:Ro,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Tn,lastRenderedState:Ro},next:null};var n={};return e.next={memoizedState:n,baseState:n,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Tn,lastRenderedState:n},next:null},t.memoizedState=e,t=t.alternate,t!==null&&(t.memoizedState=e),e}function c0(t){var e=u0(t);e.next===null&&(e=t.alternate.memoizedState),$l(t,e.next.queue,{},we())}function rd(){return Jt(fi)}function s0(){return Rt().memoizedState}function f0(){return Rt().memoizedState}function Fw(t){for(var e=t.return;e!==null;){switch(e.tag){case 24:case 3:var n=we();t=eo(n);var o=no(e,t,n);o!==null&&(de(o,e,n),Ql(o,e,n)),e={cache:jf()},t.payload=e;return}e=e.return}}function Pw(t,e,n){var o=we();n={lane:o,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null},wu(t)?h0(e,n):(n=Xf(t,e,n,o),n!==null&&(de(n,t,o),p0(n,e,o)))}function d0(t,e,n){var o=we();$l(t,e,n,o)}function $l(t,e,n,o){var a={lane:o,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null};if(wu(t))h0(e,a);else{var l=t.alternate;if(t.lanes===0&&(l===null||l.lanes===0)&&(l=e.lastRenderedReducer,l!==null))try{var i=e.lastRenderedState,r=l(i,n);if(a.hasEagerState=!0,a.eagerState=r,Ee(r,i))return vu(t,e,a,0),vt===null&&yu(),!1}catch{}if(n=Xf(t,e,a,o),n!==null)return de(n,t,o),p0(n,e,o),!0}return!1}function ud(t,e,n,o){if(o={lane:2,revertLane:yd(),gesture:null,action:o,hasEagerState:!1,eagerState:null,next:null},wu(t)){if(e)throw Error(L(479))}else e=Xf(t,n,o,2),e!==null&&de(e,t,2)}function wu(t){var e=t.alternate;return t===et||e!==null&&e===et}function h0(t,e){qa=Ir=!0;var n=t.pending;n===null?e.next=e:(e.next=n.next,n.next=e),t.pending=e}function p0(t,e,n){if((n&4194048)!==0){var o=e.lanes;o&=t.pendingLanes,n|=o,e.lanes=n,Pg(t,n)}}var ui={readContext:Jt,use:Su,useCallback:At,useContext:At,useEffect:At,useImperativeHandle:At,useLayoutEffect:At,useInsertionEffect:At,useMemo:At,useReducer:At,useRef:At,useState:At,useDebugValue:At,useDeferredValue:At,useTransition:At,useSyncExternalStore:At,useId:At,useHostTransitionStatus:At,useFormState:At,useActionState:At,useOptimistic:At,useMemoCache:At,useCacheRefresh:At};ui.useEffectEvent=At;var g0={readContext:Jt,use:Su,useCallback:function(t,e){return ne().memoizedState=[t,e===void 0?null:e],t},useContext:Jt,useEffect:Fp,useImperativeHandle:function(t,e,n){n=n!=null?n.concat([t]):null,Tr(4194308,4,n0.bind(null,e,t),n)},useLayoutEffect:function(t,e){return Tr(4194308,4,t,e)},useInsertionEffect:function(t,e){Tr(4,2,t,e)},useMemo:function(t,e){var n=ne();e=e===void 0?null:e;var o=t();if(Xo){$n(!0);try{t()}finally{$n(!1)}}return n.memoizedState=[o,e],o},useReducer:function(t,e,n){var o=ne();if(n!==void 0){var a=n(e);if(Xo){$n(!0);try{n(e)}finally{$n(!1)}}}else a=e;return o.memoizedState=o.baseState=a,t={pending:null,lanes:0,dispatch:null,lastRenderedReducer:t,lastRenderedState:a},o.queue=t,t=t.dispatch=Pw.bind(null,et,t),[o.memoizedState,t]},useRef:function(t){var e=ne();return t={current:t},e.memoizedState=t},useState:function(t){t=lf(t);var e=t.queue,n=d0.bind(null,et,e);return e.dispatch=n,[t.memoizedState,n]},useDebugValue:ld,useDeferredValue:function(t,e){var n=ne();return id(n,t,e)},useTransition:function(){var t=lf(!1);return t=r0.bind(null,et,t.queue,!0,!1),ne().memoizedState=t,[!1,t]},useSyncExternalStore:function(t,e,n){var o=et,a=ne();if(rt){if(n===void 0)throw Error(L(407));n=n()}else{if(n=e(),vt===null)throw Error(L(349));(it&127)!==0||Xm(o,e,n)}a.memoizedState=n;var l={value:n,getSnapshot:e};return a.queue=l,Fp(Gm.bind(null,o,l,t),[t]),o.flags|=2048,$a(9,{destroy:void 0},Zm.bind(null,o,l,n,e),null),n},useId:function(){var t=ne(),e=vt.identifierPrefix;if(rt){var n=tn,o=Pe;n=(o&~(1<<32-_e(o)-1)).toString(32)+n,e="_"+e+"R_"+n,n=Wr++,0<n&&(e+="H"+n.toString(32)),e+="_"}else n=jw++,e="_"+e+"r_"+n.toString(32)+"_";return t.memoizedState=e},useHostTransitionStatus:rd,useFormState:Jp,useActionState:Jp,useOptimistic:function(t){var e=ne();e.memoizedState=e.baseState=t;var n={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return e.queue=n,e=ud.bind(null,et,!0,n),n.dispatch=e,[t,e]},useMemoCache:nd,useCacheRefresh:function(){return ne().memoizedState=Fw.bind(null,et)},useEffectEvent:function(t){var e=ne(),n={impl:t};return e.memoizedState=n,function(){if((st&2)!==0)throw Error(L(440));return n.impl.apply(void 0,arguments)}}},cd={readContext:Jt,use:Su,useCallback:a0,useContext:Jt,useEffect:ad,useImperativeHandle:o0,useInsertionEffect:t0,useLayoutEffect:e0,useMemo:l0,useReducer:Cr,useRef:Fm,useState:function(){return Cr(Tn)},useDebugValue:ld,useDeferredValue:function(t,e){var n=Rt();return i0(n,yt.memoizedState,t,e)},useTransition:function(){var t=Cr(Tn)[0],e=Rt().memoizedState;return[typeof t=="boolean"?t:Si(t),e]},useSyncExternalStore:qm,useId:s0,useHostTransitionStatus:rd,useFormState:Ip,useActionState:Ip,useOptimistic:function(t,e){var n=Rt();return Km(n,yt,t,e)},useMemoCache:nd,useCacheRefresh:f0};cd.useEffectEvent=Pm;var m0={readContext:Jt,use:Su,useCallback:a0,useContext:Jt,useEffect:ad,useImperativeHandle:o0,useInsertionEffect:t0,useLayoutEffect:e0,useMemo:l0,useReducer:gs,useRef:Fm,useState:function(){return gs(Tn)},useDebugValue:ld,useDeferredValue:function(t,e){var n=Rt();return yt===null?id(n,t,e):i0(n,yt.memoizedState,t,e)},useTransition:function(){var t=gs(Tn)[0],e=Rt().memoizedState;return[typeof t=="boolean"?t:Si(t),e]},useSyncExternalStore:qm,useId:s0,useHostTransitionStatus:rd,useFormState:Wp,useActionState:Wp,useOptimistic:function(t,e){var n=Rt();return yt!==null?Km(n,yt,t,e):(n.baseState=t,[t,n.queue.dispatch])},useMemoCache:nd,useCacheRefresh:f0};m0.useEffectEvent=Pm;function ms(t,e,n,o){e=t.memoizedState,n=n(o,e),n=n==null?e:wt({},e,n),t.memoizedState=n,t.lanes===0&&(t.updateQueue.baseState=n)}var cf={enqueueSetState:function(t,e,n){t=t._reactInternals;var o=we(),a=eo(o);a.payload=e,n!=null&&(a.callback=n),e=no(t,a,o),e!==null&&(de(e,t,o),Ql(e,t,o))},enqueueReplaceState:function(t,e,n){t=t._reactInternals;var o=we(),a=eo(o);a.tag=1,a.payload=e,n!=null&&(a.callback=n),e=no(t,a,o),e!==null&&(de(e,t,o),Ql(e,t,o))},enqueueForceUpdate:function(t,e){t=t._reactInternals;var n=we(),o=eo(n);o.tag=2,e!=null&&(o.callback=e),e=no(t,o,n),e!==null&&(de(e,t,n),Ql(e,t,n))}};function Pp(t,e,n,o,a,l,i){return t=t.stateNode,typeof t.shouldComponentUpdate=="function"?t.shouldComponentUpdate(o,l,i):e.prototype&&e.prototype.isPureReactComponent?!oi(n,o)||!oi(a,l):!0}function tg(t,e,n,o){t=e.state,typeof e.componentWillReceiveProps=="function"&&e.componentWillReceiveProps(n,o),typeof e.UNSAFE_componentWillReceiveProps=="function"&&e.UNSAFE_componentWillReceiveProps(n,o),e.state!==t&&cf.enqueueReplaceState(e,e.state,null)}function Zo(t,e){var n=e;if("ref"in e){n={};for(var o in e)o!=="ref"&&(n[o]=e[o])}if(t=t.defaultProps){n===e&&(n=wt({},n));for(var a in t)n[a]===void 0&&(n[a]=t[a])}return n}function y0(t){Zr(t)}function v0(t){console.error(t)}function b0(t){Zr(t)}function Fr(t,e){try{var n=t.onUncaughtError;n(e.value,{componentStack:e.stack})}catch(o){setTimeout(function(){throw o})}}function eg(t,e,n){try{var o=t.onCaughtError;o(n.value,{componentStack:n.stack,errorBoundary:e.tag===1?e.stateNode:null})}catch(a){setTimeout(function(){throw a})}}function sf(t,e,n){return n=eo(n),n.tag=3,n.payload={element:null},n.callback=function(){Fr(t,e)},n}function x0(t){return t=eo(t),t.tag=3,t}function S0(t,e,n,o){var a=n.type.getDerivedStateFromError;if(typeof a=="function"){var l=o.value;t.payload=function(){return a(l)},t.callback=function(){eg(e,n,o)}}var i=n.stateNode;i!==null&&typeof i.componentDidCatch=="function"&&(t.callback=function(){eg(e,n,o),typeof a!="function"&&(oo===null?oo=new Set([this]):oo.add(this));var r=o.stack;this.componentDidCatch(o.value,{componentStack:r!==null?r:""})})}function tE(t,e,n,o,a){if(n.flags|=32768,o!==null&&typeof o=="object"&&typeof o.then=="function"){if(e=n.alternate,e!==null&&nl(e,n,a,!0),n=Ne.current,n!==null){switch(n.tag){case 31:case 13:return Be===null?ou():n.alternate===null&&Ct===0&&(Ct=3),n.flags&=-257,n.flags|=65536,n.lanes=a,o===Kr?n.flags|=16384:(e=n.updateQueue,e===null?n.updateQueue=new Set([o]):e.add(o),zs(t,o,a)),!1;case 22:return n.flags|=65536,o===Kr?n.flags|=16384:(e=n.updateQueue,e===null?(e={transitions:null,markerInstances:null,retryQueue:new Set([o])},n.updateQueue=e):(n=e.retryQueue,n===null?e.retryQueue=new Set([o]):n.add(o)),zs(t,o,a)),!1}throw Error(L(435,n.tag))}return zs(t,o,a),ou(),!1}if(rt)return e=Ne.current,e!==null?((e.flags&65536)===0&&(e.flags|=256),e.flags|=65536,e.lanes=a,o!==Is&&(t=Error(L(422),{cause:o}),li(He(t,n)))):(o!==Is&&(e=Error(L(423),{cause:o}),li(He(e,n))),t=t.current.alternate,t.flags|=65536,a&=-a,t.lanes|=a,o=He(o,n),a=sf(t.stateNode,o,a),ps(t,a),Ct!==4&&(Ct=2)),!1;var l=Error(L(520),{cause:o});if(l=He(l,n),Wl===null?Wl=[l]:Wl.push(l),Ct!==4&&(Ct=2),e===null)return!0;o=He(o,n),n=e;do{switch(n.tag){case 3:return n.flags|=65536,t=a&-a,n.lanes|=t,t=sf(n.stateNode,o,t),ps(n,t),!1;case 1:if(e=n.type,l=n.stateNode,(n.flags&128)===0&&(typeof e.getDerivedStateFromError=="function"||l!==null&&typeof l.componentDidCatch=="function"&&(oo===null||!oo.has(l))))return n.flags|=65536,a&=-a,n.lanes|=a,a=x0(a),S0(a,t,n,o),ps(n,a),!1}n=n.return}while(n!==null);return!1}var sd=Error(L(461)),Ut=!1;function jt(t,e,n,o){e.child=t===null?Bm(e,null,n,o):qo(e,t.child,n,o)}function ng(t,e,n,o,a){n=n.render;var l=e.ref;if("ref"in o){var i={};for(var r in o)r!=="ref"&&(i[r]=o[r])}else i=o;return Vo(e),o=Ff(t,e,n,i,l,a),r=Pf(),t!==null&&!Ut?(td(t,e,a),On(t,e,a)):(rt&&r&&Gf(e),e.flags|=1,jt(t,e,o,a),e.child)}function og(t,e,n,o,a){if(t===null){var l=n.type;return typeof l=="function"&&!Zf(l)&&l.defaultProps===void 0&&n.compare===null?(e.tag=15,e.type=l,_0(t,e,l,o,a)):(t=zr(n.type,null,o,e,e.mode,a),t.ref=e.ref,t.return=e,e.child=t)}if(l=t.child,!fd(t,a)){var i=l.memoizedProps;if(n=n.compare,n=n!==null?n:oi,n(i,o)&&t.ref===e.ref)return On(t,e,a)}return e.flags|=1,t=Nn(l,o),t.ref=e.ref,t.return=e,e.child=t}function _0(t,e,n,o,a){if(t!==null){var l=t.memoizedProps;if(oi(l,o)&&t.ref===e.ref)if(Ut=!1,e.pendingProps=o=l,fd(t,a))(t.flags&131072)!==0&&(Ut=!0);else return e.lanes=t.lanes,On(t,e,a)}return ff(t,e,n,o,a)}function w0(t,e,n,o){var a=o.children,l=t!==null?t.memoizedState:null;if(t===null&&e.stateNode===null&&(e.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),o.mode==="hidden"){if((e.flags&128)!==0){if(l=l!==null?l.baseLanes|n:n,t!==null){for(o=e.child=t.child,a=0;o!==null;)a=a|o.lanes|o.childLanes,o=o.sibling;o=a&~l}else o=0,e.child=null;return ag(t,e,l,n,o)}if((n&536870912)!==0)e.memoizedState={baseLanes:0,cachePool:null},t!==null&&Ar(e,l!==null?l.cachePool:null),l!==null?jp(e,l):of(),Um(e);else return o=e.lanes=536870912,ag(t,e,l!==null?l.baseLanes|n:n,n,o)}else l!==null?(Ar(e,l.cachePool),jp(e,l),jn(e),e.memoizedState=null):(t!==null&&Ar(e,null),of(),jn(e));return jt(t,e,a,n),e.child}function Yl(t,e){return t!==null&&t.tag===22||e.stateNode!==null||(e.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),e.sibling}function ag(t,e,n,o,a){var l=Kf();return l=l===null?null:{parent:Lt._currentValue,pool:l},e.memoizedState={baseLanes:n,cachePool:l},t!==null&&Ar(e,null),of(),Um(e),t!==null&&nl(t,e,o,!0),e.childLanes=a,null}function Or(t,e){return e=Pr({mode:e.mode,children:e.children},t.mode),e.ref=t.ref,t.child=e,e.return=t,e}function lg(t,e,n){return qo(e,t.child,null,n),t=Or(e,e.pendingProps),t.flags|=2,ye(e),e.memoizedState=null,t}function eE(t,e,n){var o=e.pendingProps,a=(e.flags&128)!==0;if(e.flags&=-129,t===null){if(rt){if(o.mode==="hidden")return t=Or(e,o),e.lanes=536870912,Yl(null,t);if(af(e),(t=_t)?(t=gy(t,Re),t=t!==null&&t.data==="&"?t:null,t!==null&&(e.memoizedState={dehydrated:t,treeContext:uo!==null?{id:Pe,overflow:tn}:null,retryLane:536870912,hydrationErrors:null},n=Am(t),n.return=e,e.child=n,$t=e,_t=null)):t=null,t===null)throw co(e);return e.lanes=536870912,null}return Or(e,o)}var l=t.memoizedState;if(l!==null){var i=l.dehydrated;if(af(e),a)if(e.flags&256)e.flags&=-257,e=lg(t,e,n);else if(e.memoizedState!==null)e.child=t.child,e.flags|=128,e=null;else throw Error(L(558));else if(Ut||nl(t,e,n,!1),a=(n&t.childLanes)!==0,Ut||a){if(o=vt,o!==null&&(i=tm(o,n),i!==0&&i!==l.retryLane))throw l.retryLane=i,Ko(t,i),de(o,t,i),sd;ou(),e=lg(t,e,n)}else t=l.treeContext,_t=ke(i.nextSibling),$t=e,rt=!0,to=null,Re=!1,t!==null&&Tm(e,t),e=Or(e,o),e.flags|=4096;return e}return t=Nn(t.child,{mode:o.mode,children:o.children}),t.ref=e.ref,e.child=t,t.return=e,t}function Dr(t,e){var n=e.ref;if(n===null)t!==null&&t.ref!==null&&(e.flags|=4194816);else{if(typeof n!="function"&&typeof n!="object")throw Error(L(284));(t===null||t.ref!==n)&&(e.flags|=4194816)}}function ff(t,e,n,o,a){return Vo(e),n=Ff(t,e,n,o,void 0,a),o=Pf(),t!==null&&!Ut?(td(t,e,a),On(t,e,a)):(rt&&o&&Gf(e),e.flags|=1,jt(t,e,n,a),e.child)}function ig(t,e,n,o,a,l){return Vo(e),e.updateQueue=null,n=Vm(e,o,n,a),Ym(t),o=Pf(),t!==null&&!Ut?(td(t,e,l),On(t,e,l)):(rt&&o&&Gf(e),e.flags|=1,jt(t,e,n,l),e.child)}function rg(t,e,n,o,a){if(Vo(e),e.stateNode===null){var l=Da,i=n.contextType;typeof i=="object"&&i!==null&&(l=Jt(i)),l=new n(o,l),e.memoizedState=l.state!==null&&l.state!==void 0?l.state:null,l.updater=cf,e.stateNode=l,l._reactInternals=e,l=e.stateNode,l.props=o,l.state=e.memoizedState,l.refs={},Jf(e),i=n.contextType,l.context=typeof i=="object"&&i!==null?Jt(i):Da,l.state=e.memoizedState,i=n.getDerivedStateFromProps,typeof i=="function"&&(ms(e,n,i,o),l.state=e.memoizedState),typeof n.getDerivedStateFromProps=="function"||typeof l.getSnapshotBeforeUpdate=="function"||typeof l.UNSAFE_componentWillMount!="function"&&typeof l.componentWillMount!="function"||(i=l.state,typeof l.componentWillMount=="function"&&l.componentWillMount(),typeof l.UNSAFE_componentWillMount=="function"&&l.UNSAFE_componentWillMount(),i!==l.state&&cf.enqueueReplaceState(l,l.state,null),Kl(e,o,l,a),jl(),l.state=e.memoizedState),typeof l.componentDidMount=="function"&&(e.flags|=4194308),o=!0}else if(t===null){l=e.stateNode;var r=e.memoizedProps,u=Zo(n,r);l.props=u;var s=l.context,c=n.contextType;i=Da,typeof c=="object"&&c!==null&&(i=Jt(c));var d=n.getDerivedStateFromProps;c=typeof d=="function"||typeof l.getSnapshotBeforeUpdate=="function",r=e.pendingProps!==r,c||typeof l.UNSAFE_componentWillReceiveProps!="function"&&typeof l.componentWillReceiveProps!="function"||(r||s!==i)&&tg(e,l,o,i),Zn=!1;var f=e.memoizedState;l.state=f,Kl(e,o,l,a),jl(),s=e.memoizedState,r||f!==s||Zn?(typeof d=="function"&&(ms(e,n,d,o),s=e.memoizedState),(u=Zn||Pp(e,n,u,o,f,s,i))?(c||typeof l.UNSAFE_componentWillMount!="function"&&typeof l.componentWillMount!="function"||(typeof l.componentWillMount=="function"&&l.componentWillMount(),typeof l.UNSAFE_componentWillMount=="function"&&l.UNSAFE_componentWillMount()),typeof l.componentDidMount=="function"&&(e.flags|=4194308)):(typeof l.componentDidMount=="function"&&(e.flags|=4194308),e.memoizedProps=o,e.memoizedState=s),l.props=o,l.state=s,l.context=i,o=u):(typeof l.componentDidMount=="function"&&(e.flags|=4194308),o=!1)}else{l=e.stateNode,ef(t,e),i=e.memoizedProps,c=Zo(n,i),l.props=c,d=e.pendingProps,f=l.context,s=n.contextType,u=Da,typeof s=="object"&&s!==null&&(u=Jt(s)),r=n.getDerivedStateFromProps,(s=typeof r=="function"||typeof l.getSnapshotBeforeUpdate=="function")||typeof l.UNSAFE_componentWillReceiveProps!="function"&&typeof l.componentWillReceiveProps!="function"||(i!==d||f!==u)&&tg(e,l,o,u),Zn=!1,f=e.memoizedState,l.state=f,Kl(e,o,l,a),jl();var p=e.memoizedState;i!==d||f!==p||Zn||t!==null&&t.dependencies!==null&&jr(t.dependencies)?(typeof r=="function"&&(ms(e,n,r,o),p=e.memoizedState),(c=Zn||Pp(e,n,c,o,f,p,u)||t!==null&&t.dependencies!==null&&jr(t.dependencies))?(s||typeof l.UNSAFE_componentWillUpdate!="function"&&typeof l.componentWillUpdate!="function"||(typeof l.componentWillUpdate=="function"&&l.componentWillUpdate(o,p,u),typeof l.UNSAFE_componentWillUpdate=="function"&&l.UNSAFE_componentWillUpdate(o,p,u)),typeof l.componentDidUpdate=="function"&&(e.flags|=4),typeof l.getSnapshotBeforeUpdate=="function"&&(e.flags|=1024)):(typeof l.componentDidUpdate!="function"||i===t.memoizedProps&&f===t.memoizedState||(e.flags|=4),typeof l.getSnapshotBeforeUpdate!="function"||i===t.memoizedProps&&f===t.memoizedState||(e.flags|=1024),e.memoizedProps=o,e.memoizedState=p),l.props=o,l.state=p,l.context=u,o=c):(typeof l.componentDidUpdate!="function"||i===t.memoizedProps&&f===t.memoizedState||(e.flags|=4),typeof l.getSnapshotBeforeUpdate!="function"||i===t.memoizedProps&&f===t.memoizedState||(e.flags|=1024),o=!1)}return l=o,Dr(t,e),o=(e.flags&128)!==0,l||o?(l=e.stateNode,n=o&&typeof n.getDerivedStateFromError!="function"?null:l.render(),e.flags|=1,t!==null&&o?(e.child=qo(e,t.child,null,a),e.child=qo(e,null,n,a)):jt(t,e,n,a),e.memoizedState=l.state,t=e.child):t=On(t,e,a),t}function ug(t,e,n,o){return Yo(),e.flags|=256,jt(t,e,n,o),e.child}var ys={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function vs(t){return{baseLanes:t,cachePool:Dm()}}function bs(t,e,n){return t=t!==null?t.childLanes&~n:0,e&&(t|=be),t}function E0(t,e,n){var o=e.pendingProps,a=!1,l=(e.flags&128)!==0,i;if((i=l)||(i=t!==null&&t.memoizedState===null?!1:(Ht.current&2)!==0),i&&(a=!0,e.flags&=-129),i=(e.flags&32)!==0,e.flags&=-33,t===null){if(rt){if(a?Qn(e):jn(e),(t=_t)?(t=gy(t,Re),t=t!==null&&t.data!=="&"?t:null,t!==null&&(e.memoizedState={dehydrated:t,treeContext:uo!==null?{id:Pe,overflow:tn}:null,retryLane:536870912,hydrationErrors:null},n=Am(t),n.return=e,e.child=n,$t=e,_t=null)):t=null,t===null)throw co(e);return Nf(t)?e.lanes=32:e.lanes=536870912,null}var r=o.children;return o=o.fallback,a?(jn(e),a=e.mode,r=Pr({mode:"hidden",children:r},a),o=Bo(o,a,n,null),r.return=e,o.return=e,r.sibling=o,e.child=r,o=e.child,o.memoizedState=vs(n),o.childLanes=bs(t,i,n),e.memoizedState=ys,Yl(null,o)):(Qn(e),df(e,r))}var u=t.memoizedState;if(u!==null&&(r=u.dehydrated,r!==null)){if(l)e.flags&256?(Qn(e),e.flags&=-257,e=xs(t,e,n)):e.memoizedState!==null?(jn(e),e.child=t.child,e.flags|=128,e=null):(jn(e),r=o.fallback,a=e.mode,o=Pr({mode:"visible",children:o.children},a),r=Bo(r,a,n,null),r.flags|=2,o.return=e,r.return=e,o.sibling=r,e.child=o,qo(e,t.child,null,n),o=e.child,o.memoizedState=vs(n),o.childLanes=bs(t,i,n),e.memoizedState=ys,e=Yl(null,o));else if(Qn(e),Nf(r)){if(i=r.nextSibling&&r.nextSibling.dataset,i)var s=i.dgst;i=s,o=Error(L(419)),o.stack="",o.digest=i,li({value:o,source:null,stack:null}),e=xs(t,e,n)}else if(Ut||nl(t,e,n,!1),i=(n&t.childLanes)!==0,Ut||i){if(i=vt,i!==null&&(o=tm(i,n),o!==0&&o!==u.retryLane))throw u.retryLane=o,Ko(t,o),de(i,t,o),sd;Ef(r)||ou(),e=xs(t,e,n)}else Ef(r)?(e.flags|=192,e.child=t.child,e=null):(t=u.treeContext,_t=ke(r.nextSibling),$t=e,rt=!0,to=null,Re=!1,t!==null&&Tm(e,t),e=df(e,o.children),e.flags|=4096);return e}return a?(jn(e),r=o.fallback,a=e.mode,u=t.child,s=u.sibling,o=Nn(u,{mode:"hidden",children:o.children}),o.subtreeFlags=u.subtreeFlags&65011712,s!==null?r=Nn(s,r):(r=Bo(r,a,n,null),r.flags|=2),r.return=e,o.return=e,o.sibling=r,e.child=o,Yl(null,o),o=e.child,r=t.child.memoizedState,r===null?r=vs(n):(a=r.cachePool,a!==null?(u=Lt._currentValue,a=a.parent!==u?{parent:u,pool:u}:a):a=Dm(),r={baseLanes:r.baseLanes|n,cachePool:a}),o.memoizedState=r,o.childLanes=bs(t,i,n),e.memoizedState=ys,Yl(t.child,o)):(Qn(e),n=t.child,t=n.sibling,n=Nn(n,{mode:"visible",children:o.children}),n.return=e,n.sibling=null,t!==null&&(i=e.deletions,i===null?(e.deletions=[t],e.flags|=16):i.push(t)),e.child=n,e.memoizedState=null,n)}function df(t,e){return e=Pr({mode:"visible",children:e},t.mode),e.return=t,t.child=e}function Pr(t,e){return t=ve(22,t,null,e),t.lanes=0,t}function xs(t,e,n){return qo(e,t.child,null,n),t=df(e,e.pendingProps.children),t.flags|=2,e.memoizedState=null,t}function cg(t,e,n){t.lanes|=e;var o=t.alternate;o!==null&&(o.lanes|=e),Fs(t.return,e,n)}function Ss(t,e,n,o,a,l){var i=t.memoizedState;i===null?t.memoizedState={isBackwards:e,rendering:null,renderingStartTime:0,last:o,tail:n,tailMode:a,treeForkCount:l}:(i.isBackwards=e,i.rendering=null,i.renderingStartTime=0,i.last=o,i.tail=n,i.tailMode=a,i.treeForkCount=l)}function N0(t,e,n){var o=e.pendingProps,a=o.revealOrder,l=o.tail;o=o.children;var i=Ht.current,r=(i&2)!==0;if(r?(i=i&1|2,e.flags|=128):i&=1,bt(Ht,i),jt(t,e,o,n),o=rt?ai:0,!r&&t!==null&&(t.flags&128)!==0)t:for(t=e.child;t!==null;){if(t.tag===13)t.memoizedState!==null&&cg(t,n,e);else if(t.tag===19)cg(t,n,e);else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break t;for(;t.sibling===null;){if(t.return===null||t.return===e)break t;t=t.return}t.sibling.return=t.return,t=t.sibling}switch(a){case"forwards":for(n=e.child,a=null;n!==null;)t=n.alternate,t!==null&&Jr(t)===null&&(a=n),n=n.sibling;n=a,n===null?(a=e.child,e.child=null):(a=n.sibling,n.sibling=null),Ss(e,!1,a,n,l,o);break;case"backwards":case"unstable_legacy-backwards":for(n=null,a=e.child,e.child=null;a!==null;){if(t=a.alternate,t!==null&&Jr(t)===null){e.child=a;break}t=a.sibling,a.sibling=n,n=a,a=t}Ss(e,!0,n,null,l,o);break;case"together":Ss(e,!1,null,null,void 0,o);break;default:e.memoizedState=null}return e.child}function On(t,e,n){if(t!==null&&(e.dependencies=t.dependencies),fo|=e.lanes,(n&e.childLanes)===0)if(t!==null){if(nl(t,e,n,!1),(n&e.childLanes)===0)return null}else return null;if(t!==null&&e.child!==t.child)throw Error(L(153));if(e.child!==null){for(t=e.child,n=Nn(t,t.pendingProps),e.child=n,n.return=e;t.sibling!==null;)t=t.sibling,n=n.sibling=Nn(t,t.pendingProps),n.return=e;n.sibling=null}return e.child}function fd(t,e){return(t.lanes&e)!==0?!0:(t=t.dependencies,!!(t!==null&&jr(t)))}function nE(t,e,n){switch(e.tag){case 3:Yr(e,e.stateNode.containerInfo),Gn(e,Lt,t.memoizedState.cache),Yo();break;case 27:case 5:Ys(e);break;case 4:Yr(e,e.stateNode.containerInfo);break;case 10:Gn(e,e.type,e.memoizedProps.value);break;case 31:if(e.memoizedState!==null)return e.flags|=128,af(e),null;break;case 13:var o=e.memoizedState;if(o!==null)return o.dehydrated!==null?(Qn(e),e.flags|=128,null):(n&e.child.childLanes)!==0?E0(t,e,n):(Qn(e),t=On(t,e,n),t!==null?t.sibling:null);Qn(e);break;case 19:var a=(t.flags&128)!==0;if(o=(n&e.childLanes)!==0,o||(nl(t,e,n,!1),o=(n&e.childLanes)!==0),a){if(o)return N0(t,e,n);e.flags|=128}if(a=e.memoizedState,a!==null&&(a.rendering=null,a.tail=null,a.lastEffect=null),bt(Ht,Ht.current),o)break;return null;case 22:return e.lanes=0,w0(t,e,n,e.pendingProps);case 24:Gn(e,Lt,t.memoizedState.cache)}return On(t,e,n)}function M0(t,e,n){if(t!==null)if(t.memoizedProps!==e.pendingProps)Ut=!0;else{if(!fd(t,n)&&(e.flags&128)===0)return Ut=!1,nE(t,e,n);Ut=(t.flags&131072)!==0}else Ut=!1,rt&&(e.flags&1048576)!==0&&Cm(e,ai,e.index);switch(e.lanes=0,e.tag){case 16:t:{var o=e.pendingProps;if(t=Do(e.elementType),e.type=t,typeof t=="function")Zf(t)?(o=Zo(t,o),e.tag=1,e=rg(null,e,t,o,n)):(e.tag=0,e=ff(null,e,t,o,n));else{if(t!=null){var a=t.$$typeof;if(a===Cf){e.tag=11,e=ng(null,e,t,o,n);break t}else if(a===Tf){e.tag=14,e=og(null,e,t,o,n);break t}}throw e=Ls(t)||t,Error(L(306,e,""))}}return e;case 0:return ff(t,e,e.type,e.pendingProps,n);case 1:return o=e.type,a=Zo(o,e.pendingProps),rg(t,e,o,a,n);case 3:t:{if(Yr(e,e.stateNode.containerInfo),t===null)throw Error(L(387));o=e.pendingProps;var l=e.memoizedState;a=l.element,ef(t,e),Kl(e,o,null,n);var i=e.memoizedState;if(o=i.cache,Gn(e,Lt,o),o!==l.cache&&Ps(e,[Lt],n,!0),jl(),o=i.element,l.isDehydrated)if(l={element:o,isDehydrated:!1,cache:i.cache},e.updateQueue.baseState=l,e.memoizedState=l,e.flags&256){e=ug(t,e,o,n);break t}else if(o!==a){a=He(Error(L(424)),e),li(a),e=ug(t,e,o,n);break t}else for(t=e.stateNode.containerInfo,t.nodeType===9?t=t.body:t=t.nodeName==="HTML"?t.ownerDocument.body:t,_t=ke(t.firstChild),$t=e,rt=!0,to=null,Re=!0,n=Bm(e,null,o,n),e.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if(Yo(),o===a){e=On(t,e,n);break t}jt(t,e,o,n)}e=e.child}return e;case 26:return Dr(t,e),t===null?(n=Og(e.type,null,e.pendingProps,null))?e.memoizedState=n:rt||(n=e.type,t=e.pendingProps,o=ru(Pn.current).createElement(n),o[Kt]=e,o[he]=t,It(o,n,t),Zt(o),e.stateNode=o):e.memoizedState=Og(e.type,t.memoizedProps,e.pendingProps,t.memoizedState),null;case 27:return Ys(e),t===null&&rt&&(o=e.stateNode=my(e.type,e.pendingProps,Pn.current),$t=e,Re=!0,a=_t,po(e.type)?(Mf=a,_t=ke(o.firstChild)):_t=a),jt(t,e,e.pendingProps.children,n),Dr(t,e),t===null&&(e.flags|=4194304),e.child;case 5:return t===null&&rt&&((a=o=_t)&&(o=TE(o,e.type,e.pendingProps,Re),o!==null?(e.stateNode=o,$t=e,_t=ke(o.firstChild),Re=!1,a=!0):a=!1),a||co(e)),Ys(e),a=e.type,l=e.pendingProps,i=t!==null?t.memoizedProps:null,o=l.children,_f(a,l)?o=null:i!==null&&_f(a,i)&&(e.flags|=32),e.memoizedState!==null&&(a=Ff(t,e,Kw,null,null,n),fi._currentValue=a),Dr(t,e),jt(t,e,o,n),e.child;case 6:return t===null&&rt&&((t=n=_t)&&(n=OE(n,e.pendingProps,Re),n!==null?(e.stateNode=n,$t=e,_t=null,t=!0):t=!1),t||co(e)),null;case 13:return E0(t,e,n);case 4:return Yr(e,e.stateNode.containerInfo),o=e.pendingProps,t===null?e.child=qo(e,null,o,n):jt(t,e,o,n),e.child;case 11:return ng(t,e,e.type,e.pendingProps,n);case 7:return jt(t,e,e.pendingProps,n),e.child;case 8:return jt(t,e,e.pendingProps.children,n),e.child;case 12:return jt(t,e,e.pendingProps.children,n),e.child;case 10:return o=e.pendingProps,Gn(e,e.type,o.value),jt(t,e,o.children,n),e.child;case 9:return a=e.type._context,o=e.pendingProps.children,Vo(e),a=Jt(a),o=o(a),e.flags|=1,jt(t,e,o,n),e.child;case 14:return og(t,e,e.type,e.pendingProps,n);case 15:return _0(t,e,e.type,e.pendingProps,n);case 19:return N0(t,e,n);case 31:return eE(t,e,n);case 22:return w0(t,e,n,e.pendingProps);case 24:return Vo(e),o=Jt(Lt),t===null?(a=Kf(),a===null&&(a=vt,l=jf(),a.pooledCache=l,l.refCount++,l!==null&&(a.pooledCacheLanes|=n),a=l),e.memoizedState={parent:o,cache:a},Jf(e),Gn(e,Lt,a)):((t.lanes&n)!==0&&(ef(t,e),Kl(e,null,null,n),jl()),a=t.memoizedState,l=e.memoizedState,a.parent!==o?(a={parent:o,cache:o},e.memoizedState=a,e.lanes===0&&(e.memoizedState=e.updateQueue.baseState=a),Gn(e,Lt,o)):(o=l.cache,Gn(e,Lt,o),o!==a.cache&&Ps(e,[Lt],n,!0))),jt(t,e,e.pendingProps.children,n),e.child;case 29:throw e.pendingProps}throw Error(L(156,e.tag))}function mn(t){t.flags|=4}function _s(t,e,n,o,a){if((e=(t.mode&32)!==0)&&(e=!1),e){if(t.flags|=16777216,(a&335544128)===a)if(t.stateNode.complete)t.flags|=8192;else if(I0())t.flags|=8192;else throw Lo=Kr,$f}else t.flags&=-16777217}function sg(t,e){if(e.type!=="stylesheet"||(e.state.loading&4)!==0)t.flags&=-16777217;else if(t.flags|=16777216,!by(e))if(I0())t.flags|=8192;else throw Lo=Kr,$f}function mr(t,e){e!==null&&(t.flags|=4),t.flags&16384&&(e=t.tag!==22?Wg():536870912,t.lanes|=e,Ja|=e)}function Dl(t,e){if(!rt)switch(t.tailMode){case"hidden":e=t.tail;for(var n=null;e!==null;)e.alternate!==null&&(n=e),e=e.sibling;n===null?t.tail=null:n.sibling=null;break;case"collapsed":n=t.tail;for(var o=null;n!==null;)n.alternate!==null&&(o=n),n=n.sibling;o===null?e||t.tail===null?t.tail=null:t.tail.sibling=null:o.sibling=null}}function St(t){var e=t.alternate!==null&&t.alternate.child===t.child,n=0,o=0;if(e)for(var a=t.child;a!==null;)n|=a.lanes|a.childLanes,o|=a.subtreeFlags&65011712,o|=a.flags&65011712,a.return=t,a=a.sibling;else for(a=t.child;a!==null;)n|=a.lanes|a.childLanes,o|=a.subtreeFlags,o|=a.flags,a.return=t,a=a.sibling;return t.subtreeFlags|=o,t.childLanes=n,e}function oE(t,e,n){var o=e.pendingProps;switch(Qf(e),e.tag){case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return St(e),null;case 1:return St(e),null;case 3:return n=e.stateNode,o=null,t!==null&&(o=t.memoizedState.cache),e.memoizedState.cache!==o&&(e.flags|=2048),Mn(Lt),Za(),n.pendingContext&&(n.context=n.pendingContext,n.pendingContext=null),(t===null||t.child===null)&&(xa(e)?mn(e):t===null||t.memoizedState.isDehydrated&&(e.flags&256)===0||(e.flags|=1024,hs())),St(e),null;case 26:var a=e.type,l=e.memoizedState;return t===null?(mn(e),l!==null?(St(e),sg(e,l)):(St(e),_s(e,a,null,o,n))):l?l!==t.memoizedState?(mn(e),St(e),sg(e,l)):(St(e),e.flags&=-16777217):(t=t.memoizedProps,t!==o&&mn(e),St(e),_s(e,a,t,o,n)),null;case 27:if(Vr(e),n=Pn.current,a=e.type,t!==null&&e.stateNode!=null)t.memoizedProps!==o&&mn(e);else{if(!o){if(e.stateNode===null)throw Error(L(166));return St(e),null}t=nn.current,xa(e)?Yp(e,t):(t=my(a,o,n),e.stateNode=t,mn(e))}return St(e),null;case 5:if(Vr(e),a=e.type,t!==null&&e.stateNode!=null)t.memoizedProps!==o&&mn(e);else{if(!o){if(e.stateNode===null)throw Error(L(166));return St(e),null}if(l=nn.current,xa(e))Yp(e,l);else{var i=ru(Pn.current);switch(l){case 1:l=i.createElementNS("http://www.w3.org/2000/svg",a);break;case 2:l=i.createElementNS("http://www.w3.org/1998/Math/MathML",a);break;default:switch(a){case"svg":l=i.createElementNS("http://www.w3.org/2000/svg",a);break;case"math":l=i.createElementNS("http://www.w3.org/1998/Math/MathML",a);break;case"script":l=i.createElement("div"),l.innerHTML="<script><\/script>",l=l.removeChild(l.firstChild);break;case"select":l=typeof o.is=="string"?i.createElement("select",{is:o.is}):i.createElement("select"),o.multiple?l.multiple=!0:o.size&&(l.size=o.size);break;default:l=typeof o.is=="string"?i.createElement(a,{is:o.is}):i.createElement(a)}}l[Kt]=e,l[he]=o;t:for(i=e.child;i!==null;){if(i.tag===5||i.tag===6)l.appendChild(i.stateNode);else if(i.tag!==4&&i.tag!==27&&i.child!==null){i.child.return=i,i=i.child;continue}if(i===e)break t;for(;i.sibling===null;){if(i.return===null||i.return===e)break t;i=i.return}i.sibling.return=i.return,i=i.sibling}e.stateNode=l;t:switch(It(l,a,o),a){case"button":case"input":case"select":case"textarea":o=!!o.autoFocus;break t;case"img":o=!0;break t;default:o=!1}o&&mn(e)}}return St(e),_s(e,e.type,t===null?null:t.memoizedProps,e.pendingProps,n),null;case 6:if(t&&e.stateNode!=null)t.memoizedProps!==o&&mn(e);else{if(typeof o!="string"&&e.stateNode===null)throw Error(L(166));if(t=Pn.current,xa(e)){if(t=e.stateNode,n=e.memoizedProps,o=null,a=$t,a!==null)switch(a.tag){case 27:case 5:o=a.memoizedProps}t[Kt]=e,t=!!(t.nodeValue===n||o!==null&&o.suppressHydrationWarning===!0||dy(t.nodeValue,n)),t||co(e,!0)}else t=ru(t).createTextNode(o),t[Kt]=e,e.stateNode=t}return St(e),null;case 31:if(n=e.memoizedState,t===null||t.memoizedState!==null){if(o=xa(e),n!==null){if(t===null){if(!o)throw Error(L(318));if(t=e.memoizedState,t=t!==null?t.dehydrated:null,!t)throw Error(L(557));t[Kt]=e}else Yo(),(e.flags&128)===0&&(e.memoizedState=null),e.flags|=4;St(e),t=!1}else n=hs(),t!==null&&t.memoizedState!==null&&(t.memoizedState.hydrationErrors=n),t=!0;if(!t)return e.flags&256?(ye(e),e):(ye(e),null);if((e.flags&128)!==0)throw Error(L(558))}return St(e),null;case 13:if(o=e.memoizedState,t===null||t.memoizedState!==null&&t.memoizedState.dehydrated!==null){if(a=xa(e),o!==null&&o.dehydrated!==null){if(t===null){if(!a)throw Error(L(318));if(a=e.memoizedState,a=a!==null?a.dehydrated:null,!a)throw Error(L(317));a[Kt]=e}else Yo(),(e.flags&128)===0&&(e.memoizedState=null),e.flags|=4;St(e),a=!1}else a=hs(),t!==null&&t.memoizedState!==null&&(t.memoizedState.hydrationErrors=a),a=!0;if(!a)return e.flags&256?(ye(e),e):(ye(e),null)}return ye(e),(e.flags&128)!==0?(e.lanes=n,e):(n=o!==null,t=t!==null&&t.memoizedState!==null,n&&(o=e.child,a=null,o.alternate!==null&&o.alternate.memoizedState!==null&&o.alternate.memoizedState.cachePool!==null&&(a=o.alternate.memoizedState.cachePool.pool),l=null,o.memoizedState!==null&&o.memoizedState.cachePool!==null&&(l=o.memoizedState.cachePool.pool),l!==a&&(o.flags|=2048)),n!==t&&n&&(e.child.flags|=8192),mr(e,e.updateQueue),St(e),null);case 4:return Za(),t===null&&vd(e.stateNode.containerInfo),St(e),null;case 10:return Mn(e.type),St(e),null;case 19:if(Gt(Ht),o=e.memoizedState,o===null)return St(e),null;if(a=(e.flags&128)!==0,l=o.rendering,l===null)if(a)Dl(o,!1);else{if(Ct!==0||t!==null&&(t.flags&128)!==0)for(t=e.child;t!==null;){if(l=Jr(t),l!==null){for(e.flags|=128,Dl(o,!1),t=l.updateQueue,e.updateQueue=t,mr(e,t),e.subtreeFlags=0,t=n,n=e.child;n!==null;)zm(n,t),n=n.sibling;return bt(Ht,Ht.current&1|2),rt&&xn(e,o.treeForkCount),e.child}t=t.sibling}o.tail!==null&&xe()>eu&&(e.flags|=128,a=!0,Dl(o,!1),e.lanes=4194304)}else{if(!a)if(t=Jr(l),t!==null){if(e.flags|=128,a=!0,t=t.updateQueue,e.updateQueue=t,mr(e,t),Dl(o,!0),o.tail===null&&o.tailMode==="hidden"&&!l.alternate&&!rt)return St(e),null}else 2*xe()-o.renderingStartTime>eu&&n!==536870912&&(e.flags|=128,a=!0,Dl(o,!1),e.lanes=4194304);o.isBackwards?(l.sibling=e.child,e.child=l):(t=o.last,t!==null?t.sibling=l:e.child=l,o.last=l)}return o.tail!==null?(t=o.tail,o.rendering=t,o.tail=t.sibling,o.renderingStartTime=xe(),t.sibling=null,n=Ht.current,bt(Ht,a?n&1|2:n&1),rt&&xn(e,o.treeForkCount),t):(St(e),null);case 22:case 23:return ye(e),If(),o=e.memoizedState!==null,t!==null?t.memoizedState!==null!==o&&(e.flags|=8192):o&&(e.flags|=8192),o?(n&536870912)!==0&&(e.flags&128)===0&&(St(e),e.subtreeFlags&6&&(e.flags|=8192)):St(e),n=e.updateQueue,n!==null&&mr(e,n.retryQueue),n=null,t!==null&&t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(n=t.memoizedState.cachePool.pool),o=null,e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(o=e.memoizedState.cachePool.pool),o!==n&&(e.flags|=2048),t!==null&&Gt(ko),null;case 24:return n=null,t!==null&&(n=t.memoizedState.cache),e.memoizedState.cache!==n&&(e.flags|=2048),Mn(Lt),St(e),null;case 25:return null;case 30:return null}throw Error(L(156,e.tag))}function aE(t,e){switch(Qf(e),e.tag){case 1:return t=e.flags,t&65536?(e.flags=t&-65537|128,e):null;case 3:return Mn(Lt),Za(),t=e.flags,(t&65536)!==0&&(t&128)===0?(e.flags=t&-65537|128,e):null;case 26:case 27:case 5:return Vr(e),null;case 31:if(e.memoizedState!==null){if(ye(e),e.alternate===null)throw Error(L(340));Yo()}return t=e.flags,t&65536?(e.flags=t&-65537|128,e):null;case 13:if(ye(e),t=e.memoizedState,t!==null&&t.dehydrated!==null){if(e.alternate===null)throw Error(L(340));Yo()}return t=e.flags,t&65536?(e.flags=t&-65537|128,e):null;case 19:return Gt(Ht),null;case 4:return Za(),null;case 10:return Mn(e.type),null;case 22:case 23:return ye(e),If(),t!==null&&Gt(ko),t=e.flags,t&65536?(e.flags=t&-65537|128,e):null;case 24:return Mn(Lt),null;case 25:return null;default:return null}}function z0(t,e){switch(Qf(e),e.tag){case 3:Mn(Lt),Za();break;case 26:case 27:case 5:Vr(e);break;case 4:Za();break;case 31:e.memoizedState!==null&&ye(e);break;case 13:ye(e);break;case 19:Gt(Ht);break;case 10:Mn(e.type);break;case 22:case 23:ye(e),If(),t!==null&&Gt(ko);break;case 24:Mn(Lt)}}function _i(t,e){try{var n=e.updateQueue,o=n!==null?n.lastEffect:null;if(o!==null){var a=o.next;n=a;do{if((n.tag&t)===t){o=void 0;var l=n.create,i=n.inst;o=l(),i.destroy=o}n=n.next}while(n!==a)}}catch(r){pt(e,e.return,r)}}function so(t,e,n){try{var o=e.updateQueue,a=o!==null?o.lastEffect:null;if(a!==null){var l=a.next;o=l;do{if((o.tag&t)===t){var i=o.inst,r=i.destroy;if(r!==void 0){i.destroy=void 0,a=e;var u=n,s=r;try{s()}catch(c){pt(a,u,c)}}}o=o.next}while(o!==l)}}catch(c){pt(e,e.return,c)}}function A0(t){var e=t.updateQueue;if(e!==null){var n=t.stateNode;try{Lm(e,n)}catch(o){pt(t,t.return,o)}}}function C0(t,e,n){n.props=Zo(t.type,t.memoizedProps),n.state=t.memoizedState;try{n.componentWillUnmount()}catch(o){pt(t,e,o)}}function Jl(t,e){try{var n=t.ref;if(n!==null){switch(t.tag){case 26:case 27:case 5:var o=t.stateNode;break;case 30:o=t.stateNode;break;default:o=t.stateNode}typeof n=="function"?t.refCleanup=n(o):n.current=o}}catch(a){pt(t,e,a)}}function en(t,e){var n=t.ref,o=t.refCleanup;if(n!==null)if(typeof o=="function")try{o()}catch(a){pt(t,e,a)}finally{t.refCleanup=null,t=t.alternate,t!=null&&(t.refCleanup=null)}else if(typeof n=="function")try{n(null)}catch(a){pt(t,e,a)}else n.current=null}function T0(t){var e=t.type,n=t.memoizedProps,o=t.stateNode;try{t:switch(e){case"button":case"input":case"select":case"textarea":n.autoFocus&&o.focus();break t;case"img":n.src?o.src=n.src:n.srcSet&&(o.srcset=n.srcSet)}}catch(a){pt(t,t.return,a)}}function ws(t,e,n){try{var o=t.stateNode;EE(o,t.type,n,e),o[he]=e}catch(a){pt(t,t.return,a)}}function O0(t){return t.tag===5||t.tag===3||t.tag===26||t.tag===27&&po(t.type)||t.tag===4}function Es(t){t:for(;;){for(;t.sibling===null;){if(t.return===null||O0(t.return))return null;t=t.return}for(t.sibling.return=t.return,t=t.sibling;t.tag!==5&&t.tag!==6&&t.tag!==18;){if(t.tag===27&&po(t.type)||t.flags&2||t.child===null||t.tag===4)continue t;t.child.return=t,t=t.child}if(!(t.flags&2))return t.stateNode}}function hf(t,e,n){var o=t.tag;if(o===5||o===6)t=t.stateNode,e?(n.nodeType===9?n.body:n.nodeName==="HTML"?n.ownerDocument.body:n).insertBefore(t,e):(e=n.nodeType===9?n.body:n.nodeName==="HTML"?n.ownerDocument.body:n,e.appendChild(t),n=n._reactRootContainer,n!=null||e.onclick!==null||(e.onclick=wn));else if(o!==4&&(o===27&&po(t.type)&&(n=t.stateNode,e=null),t=t.child,t!==null))for(hf(t,e,n),t=t.sibling;t!==null;)hf(t,e,n),t=t.sibling}function tu(t,e,n){var o=t.tag;if(o===5||o===6)t=t.stateNode,e?n.insertBefore(t,e):n.appendChild(t);else if(o!==4&&(o===27&&po(t.type)&&(n=t.stateNode),t=t.child,t!==null))for(tu(t,e,n),t=t.sibling;t!==null;)tu(t,e,n),t=t.sibling}function D0(t){var e=t.stateNode,n=t.memoizedProps;try{for(var o=t.type,a=e.attributes;a.length;)e.removeAttributeNode(a[0]);It(e,o,n),e[Kt]=t,e[he]=n}catch(l){pt(t,t.return,l)}}var Sn=!1,kt=!1,Ns=!1,fg=typeof WeakSet=="function"?WeakSet:Set,Xt=null;function lE(t,e){if(t=t.containerInfo,xf=fu,t=bm(t),Vf(t)){if("selectionStart"in t)var n={start:t.selectionStart,end:t.selectionEnd};else t:{n=(n=t.ownerDocument)&&n.defaultView||window;var o=n.getSelection&&n.getSelection();if(o&&o.rangeCount!==0){n=o.anchorNode;var a=o.anchorOffset,l=o.focusNode;o=o.focusOffset;try{n.nodeType,l.nodeType}catch{n=null;break t}var i=0,r=-1,u=-1,s=0,c=0,d=t,f=null;e:for(;;){for(var p;d!==n||a!==0&&d.nodeType!==3||(r=i+a),d!==l||o!==0&&d.nodeType!==3||(u=i+o),d.nodeType===3&&(i+=d.nodeValue.length),(p=d.firstChild)!==null;)f=d,d=p;for(;;){if(d===t)break e;if(f===n&&++s===a&&(r=i),f===l&&++c===o&&(u=i),(p=d.nextSibling)!==null)break;d=f,f=d.parentNode}d=p}n=r===-1||u===-1?null:{start:r,end:u}}else n=null}n=n||{start:0,end:0}}else n=null;for(Sf={focusedElem:t,selectionRange:n},fu=!1,Xt=e;Xt!==null;)if(e=Xt,t=e.child,(e.subtreeFlags&1028)!==0&&t!==null)t.return=e,Xt=t;else for(;Xt!==null;){switch(e=Xt,l=e.alternate,t=e.flags,e.tag){case 0:if((t&4)!==0&&(t=e.updateQueue,t=t!==null?t.events:null,t!==null))for(n=0;n<t.length;n++)a=t[n],a.ref.impl=a.nextImpl;break;case 11:case 15:break;case 1:if((t&1024)!==0&&l!==null){t=void 0,n=e,a=l.memoizedProps,l=l.memoizedState,o=n.stateNode;try{var y=Zo(n.type,a);t=o.getSnapshotBeforeUpdate(y,l),o.__reactInternalSnapshotBeforeUpdate=t}catch(b){pt(n,n.return,b)}}break;case 3:if((t&1024)!==0){if(t=e.stateNode.containerInfo,n=t.nodeType,n===9)wf(t);else if(n===1)switch(t.nodeName){case"HEAD":case"HTML":case"BODY":wf(t);break;default:t.textContent=""}}break;case 5:case 26:case 27:case 6:case 4:case 17:break;default:if((t&1024)!==0)throw Error(L(163))}if(t=e.sibling,t!==null){t.return=e.return,Xt=t;break}Xt=e.return}}function H0(t,e,n){var o=n.flags;switch(n.tag){case 0:case 11:case 15:vn(t,n),o&4&&_i(5,n);break;case 1:if(vn(t,n),o&4)if(t=n.stateNode,e===null)try{t.componentDidMount()}catch(i){pt(n,n.return,i)}else{var a=Zo(n.type,e.memoizedProps);e=e.memoizedState;try{t.componentDidUpdate(a,e,t.__reactInternalSnapshotBeforeUpdate)}catch(i){pt(n,n.return,i)}}o&64&&A0(n),o&512&&Jl(n,n.return);break;case 3:if(vn(t,n),o&64&&(t=n.updateQueue,t!==null)){if(e=null,n.child!==null)switch(n.child.tag){case 27:case 5:e=n.child.stateNode;break;case 1:e=n.child.stateNode}try{Lm(t,e)}catch(i){pt(n,n.return,i)}}break;case 27:e===null&&o&4&&D0(n);case 26:case 5:vn(t,n),e===null&&o&4&&T0(n),o&512&&Jl(n,n.return);break;case 12:vn(t,n);break;case 31:vn(t,n),o&4&&k0(t,n);break;case 13:vn(t,n),o&4&&L0(t,n),o&64&&(t=n.memoizedState,t!==null&&(t=t.dehydrated,t!==null&&(n=pE.bind(null,n),DE(t,n))));break;case 22:if(o=n.memoizedState!==null||Sn,!o){e=e!==null&&e.memoizedState!==null||kt,a=Sn;var l=kt;Sn=o,(kt=e)&&!l?bn(t,n,(n.subtreeFlags&8772)!==0):vn(t,n),Sn=a,kt=l}break;case 30:break;default:vn(t,n)}}function R0(t){var e=t.alternate;e!==null&&(t.alternate=null,R0(e)),t.child=null,t.deletions=null,t.sibling=null,t.tag===5&&(e=t.stateNode,e!==null&&Rf(e)),t.stateNode=null,t.return=null,t.dependencies=null,t.memoizedProps=null,t.memoizedState=null,t.pendingProps=null,t.stateNode=null,t.updateQueue=null}var Mt=null,se=!1;function yn(t,e,n){for(n=n.child;n!==null;)B0(t,e,n),n=n.sibling}function B0(t,e,n){if(Se&&typeof Se.onCommitFiberUnmount=="function")try{Se.onCommitFiberUnmount(gi,n)}catch{}switch(n.tag){case 26:kt||en(n,e),yn(t,e,n),n.memoizedState?n.memoizedState.count--:n.stateNode&&(n=n.stateNode,n.parentNode.removeChild(n));break;case 27:kt||en(n,e);var o=Mt,a=se;po(n.type)&&(Mt=n.stateNode,se=!1),yn(t,e,n),Pl(n.stateNode),Mt=o,se=a;break;case 5:kt||en(n,e);case 6:if(o=Mt,a=se,Mt=null,yn(t,e,n),Mt=o,se=a,Mt!==null)if(se)try{(Mt.nodeType===9?Mt.body:Mt.nodeName==="HTML"?Mt.ownerDocument.body:Mt).removeChild(n.stateNode)}catch(l){pt(n,e,l)}else try{Mt.removeChild(n.stateNode)}catch(l){pt(n,e,l)}break;case 18:Mt!==null&&(se?(t=Mt,Mg(t.nodeType===9?t.body:t.nodeName==="HTML"?t.ownerDocument.body:t,n.stateNode),Pa(t)):Mg(Mt,n.stateNode));break;case 4:o=Mt,a=se,Mt=n.stateNode.containerInfo,se=!0,yn(t,e,n),Mt=o,se=a;break;case 0:case 11:case 14:case 15:so(2,n,e),kt||so(4,n,e),yn(t,e,n);break;case 1:kt||(en(n,e),o=n.stateNode,typeof o.componentWillUnmount=="function"&&C0(n,e,o)),yn(t,e,n);break;case 21:yn(t,e,n);break;case 22:kt=(o=kt)||n.memoizedState!==null,yn(t,e,n),kt=o;break;default:yn(t,e,n)}}function k0(t,e){if(e.memoizedState===null&&(t=e.alternate,t!==null&&(t=t.memoizedState,t!==null))){t=t.dehydrated;try{Pa(t)}catch(n){pt(e,e.return,n)}}}function L0(t,e){if(e.memoizedState===null&&(t=e.alternate,t!==null&&(t=t.memoizedState,t!==null&&(t=t.dehydrated,t!==null))))try{Pa(t)}catch(n){pt(e,e.return,n)}}function iE(t){switch(t.tag){case 31:case 13:case 19:var e=t.stateNode;return e===null&&(e=t.stateNode=new fg),e;case 22:return t=t.stateNode,e=t._retryCache,e===null&&(e=t._retryCache=new fg),e;default:throw Error(L(435,t.tag))}}function yr(t,e){var n=iE(t);e.forEach(function(o){if(!n.has(o)){n.add(o);var a=gE.bind(null,t,o);o.then(a,a)}})}function ue(t,e){var n=e.deletions;if(n!==null)for(var o=0;o<n.length;o++){var a=n[o],l=t,i=e,r=i;t:for(;r!==null;){switch(r.tag){case 27:if(po(r.type)){Mt=r.stateNode,se=!1;break t}break;case 5:Mt=r.stateNode,se=!1;break t;case 3:case 4:Mt=r.stateNode.containerInfo,se=!0;break t}r=r.return}if(Mt===null)throw Error(L(160));B0(l,i,a),Mt=null,se=!1,l=a.alternate,l!==null&&(l.return=null),a.return=null}if(e.subtreeFlags&13886)for(e=e.child;e!==null;)U0(e,t),e=e.sibling}var Ze=null;function U0(t,e){var n=t.alternate,o=t.flags;switch(t.tag){case 0:case 11:case 14:case 15:ue(e,t),ce(t),o&4&&(so(3,t,t.return),_i(3,t),so(5,t,t.return));break;case 1:ue(e,t),ce(t),o&512&&(kt||n===null||en(n,n.return)),o&64&&Sn&&(t=t.updateQueue,t!==null&&(o=t.callbacks,o!==null&&(n=t.shared.hiddenCallbacks,t.shared.hiddenCallbacks=n===null?o:n.concat(o))));break;case 26:var a=Ze;if(ue(e,t),ce(t),o&512&&(kt||n===null||en(n,n.return)),o&4){var l=n!==null?n.memoizedState:null;if(o=t.memoizedState,n===null)if(o===null)if(t.stateNode===null){t:{o=t.type,n=t.memoizedProps,a=a.ownerDocument||a;e:switch(o){case"title":l=a.getElementsByTagName("title")[0],(!l||l[vi]||l[Kt]||l.namespaceURI==="http://www.w3.org/2000/svg"||l.hasAttribute("itemprop"))&&(l=a.createElement(o),a.head.insertBefore(l,a.querySelector("head > title"))),It(l,o,n),l[Kt]=t,Zt(l),o=l;break t;case"link":var i=Hg("link","href",a).get(o+(n.href||""));if(i){for(var r=0;r<i.length;r++)if(l=i[r],l.getAttribute("href")===(n.href==null||n.href===""?null:n.href)&&l.getAttribute("rel")===(n.rel==null?null:n.rel)&&l.getAttribute("title")===(n.title==null?null:n.title)&&l.getAttribute("crossorigin")===(n.crossOrigin==null?null:n.crossOrigin)){i.splice(r,1);break e}}l=a.createElement(o),It(l,o,n),a.head.appendChild(l);break;case"meta":if(i=Hg("meta","content",a).get(o+(n.content||""))){for(r=0;r<i.length;r++)if(l=i[r],l.getAttribute("content")===(n.content==null?null:""+n.content)&&l.getAttribute("name")===(n.name==null?null:n.name)&&l.getAttribute("property")===(n.property==null?null:n.property)&&l.getAttribute("http-equiv")===(n.httpEquiv==null?null:n.httpEquiv)&&l.getAttribute("charset")===(n.charSet==null?null:n.charSet)){i.splice(r,1);break e}}l=a.createElement(o),It(l,o,n),a.head.appendChild(l);break;default:throw Error(L(468,o))}l[Kt]=t,Zt(l),o=l}t.stateNode=o}else Rg(a,t.type,t.stateNode);else t.stateNode=Dg(a,o,t.memoizedProps);else l!==o?(l===null?n.stateNode!==null&&(n=n.stateNode,n.parentNode.removeChild(n)):l.count--,o===null?Rg(a,t.type,t.stateNode):Dg(a,o,t.memoizedProps)):o===null&&t.stateNode!==null&&ws(t,t.memoizedProps,n.memoizedProps)}break;case 27:ue(e,t),ce(t),o&512&&(kt||n===null||en(n,n.return)),n!==null&&o&4&&ws(t,t.memoizedProps,n.memoizedProps);break;case 5:if(ue(e,t),ce(t),o&512&&(kt||n===null||en(n,n.return)),t.flags&32){a=t.stateNode;try{Qa(a,"")}catch(y){pt(t,t.return,y)}}o&4&&t.stateNode!=null&&(a=t.memoizedProps,ws(t,a,n!==null?n.memoizedProps:a)),o&1024&&(Ns=!0);break;case 6:if(ue(e,t),ce(t),o&4){if(t.stateNode===null)throw Error(L(162));o=t.memoizedProps,n=t.stateNode;try{n.nodeValue=o}catch(y){pt(t,t.return,y)}}break;case 3:if(Br=null,a=Ze,Ze=uu(e.containerInfo),ue(e,t),Ze=a,ce(t),o&4&&n!==null&&n.memoizedState.isDehydrated)try{Pa(e.containerInfo)}catch(y){pt(t,t.return,y)}Ns&&(Ns=!1,Y0(t));break;case 4:o=Ze,Ze=uu(t.stateNode.containerInfo),ue(e,t),ce(t),Ze=o;break;case 12:ue(e,t),ce(t);break;case 31:ue(e,t),ce(t),o&4&&(o=t.updateQueue,o!==null&&(t.updateQueue=null,yr(t,o)));break;case 13:ue(e,t),ce(t),t.child.flags&8192&&t.memoizedState!==null!=(n!==null&&n.memoizedState!==null)&&(Eu=xe()),o&4&&(o=t.updateQueue,o!==null&&(t.updateQueue=null,yr(t,o)));break;case 22:a=t.memoizedState!==null;var u=n!==null&&n.memoizedState!==null,s=Sn,c=kt;if(Sn=s||a,kt=c||u,ue(e,t),kt=c,Sn=s,ce(t),o&8192)t:for(e=t.stateNode,e._visibility=a?e._visibility&-2:e._visibility|1,a&&(n===null||u||Sn||kt||Ho(t)),n=null,e=t;;){if(e.tag===5||e.tag===26){if(n===null){u=n=e;try{if(l=u.stateNode,a)i=l.style,typeof i.setProperty=="function"?i.setProperty("display","none","important"):i.display="none";else{r=u.stateNode;var d=u.memoizedProps.style,f=d!=null&&d.hasOwnProperty("display")?d.display:null;r.style.display=f==null||typeof f=="boolean"?"":(""+f).trim()}}catch(y){pt(u,u.return,y)}}}else if(e.tag===6){if(n===null){u=e;try{u.stateNode.nodeValue=a?"":u.memoizedProps}catch(y){pt(u,u.return,y)}}}else if(e.tag===18){if(n===null){u=e;try{var p=u.stateNode;a?zg(p,!0):zg(u.stateNode,!1)}catch(y){pt(u,u.return,y)}}}else if((e.tag!==22&&e.tag!==23||e.memoizedState===null||e===t)&&e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break t;for(;e.sibling===null;){if(e.return===null||e.return===t)break t;n===e&&(n=null),e=e.return}n===e&&(n=null),e.sibling.return=e.return,e=e.sibling}o&4&&(o=t.updateQueue,o!==null&&(n=o.retryQueue,n!==null&&(o.retryQueue=null,yr(t,n))));break;case 19:ue(e,t),ce(t),o&4&&(o=t.updateQueue,o!==null&&(t.updateQueue=null,yr(t,o)));break;case 30:break;case 21:break;default:ue(e,t),ce(t)}}function ce(t){var e=t.flags;if(e&2){try{for(var n,o=t.return;o!==null;){if(O0(o)){n=o;break}o=o.return}if(n==null)throw Error(L(160));switch(n.tag){case 27:var a=n.stateNode,l=Es(t);tu(t,l,a);break;case 5:var i=n.stateNode;n.flags&32&&(Qa(i,""),n.flags&=-33);var r=Es(t);tu(t,r,i);break;case 3:case 4:var u=n.stateNode.containerInfo,s=Es(t);hf(t,s,u);break;default:throw Error(L(161))}}catch(c){pt(t,t.return,c)}t.flags&=-3}e&4096&&(t.flags&=-4097)}function Y0(t){if(t.subtreeFlags&1024)for(t=t.child;t!==null;){var e=t;Y0(e),e.tag===5&&e.flags&1024&&e.stateNode.reset(),t=t.sibling}}function vn(t,e){if(e.subtreeFlags&8772)for(e=e.child;e!==null;)H0(t,e.alternate,e),e=e.sibling}function Ho(t){for(t=t.child;t!==null;){var e=t;switch(e.tag){case 0:case 11:case 14:case 15:so(4,e,e.return),Ho(e);break;case 1:en(e,e.return);var n=e.stateNode;typeof n.componentWillUnmount=="function"&&C0(e,e.return,n),Ho(e);break;case 27:Pl(e.stateNode);case 26:case 5:en(e,e.return),Ho(e);break;case 22:e.memoizedState===null&&Ho(e);break;case 30:Ho(e);break;default:Ho(e)}t=t.sibling}}function bn(t,e,n){for(n=n&&(e.subtreeFlags&8772)!==0,e=e.child;e!==null;){var o=e.alternate,a=t,l=e,i=l.flags;switch(l.tag){case 0:case 11:case 15:bn(a,l,n),_i(4,l);break;case 1:if(bn(a,l,n),o=l,a=o.stateNode,typeof a.componentDidMount=="function")try{a.componentDidMount()}catch(s){pt(o,o.return,s)}if(o=l,a=o.updateQueue,a!==null){var r=o.stateNode;try{var u=a.shared.hiddenCallbacks;if(u!==null)for(a.shared.hiddenCallbacks=null,a=0;a<u.length;a++)km(u[a],r)}catch(s){pt(o,o.return,s)}}n&&i&64&&A0(l),Jl(l,l.return);break;case 27:D0(l);case 26:case 5:bn(a,l,n),n&&o===null&&i&4&&T0(l),Jl(l,l.return);break;case 12:bn(a,l,n);break;case 31:bn(a,l,n),n&&i&4&&k0(a,l);break;case 13:bn(a,l,n),n&&i&4&&L0(a,l);break;case 22:l.memoizedState===null&&bn(a,l,n),Jl(l,l.return);break;case 30:break;default:bn(a,l,n)}e=e.sibling}}function dd(t,e){var n=null;t!==null&&t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(n=t.memoizedState.cachePool.pool),t=null,e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(t=e.memoizedState.cachePool.pool),t!==n&&(t!=null&&t.refCount++,n!=null&&xi(n))}function hd(t,e){t=null,e.alternate!==null&&(t=e.alternate.memoizedState.cache),e=e.memoizedState.cache,e!==t&&(e.refCount++,t!=null&&xi(t))}function Xe(t,e,n,o){if(e.subtreeFlags&10256)for(e=e.child;e!==null;)V0(t,e,n,o),e=e.sibling}function V0(t,e,n,o){var a=e.flags;switch(e.tag){case 0:case 11:case 15:Xe(t,e,n,o),a&2048&&_i(9,e);break;case 1:Xe(t,e,n,o);break;case 3:Xe(t,e,n,o),a&2048&&(t=null,e.alternate!==null&&(t=e.alternate.memoizedState.cache),e=e.memoizedState.cache,e!==t&&(e.refCount++,t!=null&&xi(t)));break;case 12:if(a&2048){Xe(t,e,n,o),t=e.stateNode;try{var l=e.memoizedProps,i=l.id,r=l.onPostCommit;typeof r=="function"&&r(i,e.alternate===null?"mount":"update",t.passiveEffectDuration,-0)}catch(u){pt(e,e.return,u)}}else Xe(t,e,n,o);break;case 31:Xe(t,e,n,o);break;case 13:Xe(t,e,n,o);break;case 23:break;case 22:l=e.stateNode,i=e.alternate,e.memoizedState!==null?l._visibility&2?Xe(t,e,n,o):Il(t,e):l._visibility&2?Xe(t,e,n,o):(l._visibility|=2,_a(t,e,n,o,(e.subtreeFlags&10256)!==0||!1)),a&2048&&dd(i,e);break;case 24:Xe(t,e,n,o),a&2048&&hd(e.alternate,e);break;default:Xe(t,e,n,o)}}function _a(t,e,n,o,a){for(a=a&&((e.subtreeFlags&10256)!==0||!1),e=e.child;e!==null;){var l=t,i=e,r=n,u=o,s=i.flags;switch(i.tag){case 0:case 11:case 15:_a(l,i,r,u,a),_i(8,i);break;case 23:break;case 22:var c=i.stateNode;i.memoizedState!==null?c._visibility&2?_a(l,i,r,u,a):Il(l,i):(c._visibility|=2,_a(l,i,r,u,a)),a&&s&2048&&dd(i.alternate,i);break;case 24:_a(l,i,r,u,a),a&&s&2048&&hd(i.alternate,i);break;default:_a(l,i,r,u,a)}e=e.sibling}}function Il(t,e){if(e.subtreeFlags&10256)for(e=e.child;e!==null;){var n=t,o=e,a=o.flags;switch(o.tag){case 22:Il(n,o),a&2048&&dd(o.alternate,o);break;case 24:Il(n,o),a&2048&&hd(o.alternate,o);break;default:Il(n,o)}e=e.sibling}}var Vl=8192;function Sa(t,e,n){if(t.subtreeFlags&Vl)for(t=t.child;t!==null;)q0(t,e,n),t=t.sibling}function q0(t,e,n){switch(t.tag){case 26:Sa(t,e,n),t.flags&Vl&&t.memoizedState!==null&&GE(n,Ze,t.memoizedState,t.memoizedProps);break;case 5:Sa(t,e,n);break;case 3:case 4:var o=Ze;Ze=uu(t.stateNode.containerInfo),Sa(t,e,n),Ze=o;break;case 22:t.memoizedState===null&&(o=t.alternate,o!==null&&o.memoizedState!==null?(o=Vl,Vl=16777216,Sa(t,e,n),Vl=o):Sa(t,e,n));break;default:Sa(t,e,n)}}function X0(t){var e=t.alternate;if(e!==null&&(t=e.child,t!==null)){e.child=null;do e=t.sibling,t.sibling=null,t=e;while(t!==null)}}function Hl(t){var e=t.deletions;if((t.flags&16)!==0){if(e!==null)for(var n=0;n<e.length;n++){var o=e[n];Xt=o,G0(o,t)}X0(t)}if(t.subtreeFlags&10256)for(t=t.child;t!==null;)Z0(t),t=t.sibling}function Z0(t){switch(t.tag){case 0:case 11:case 15:Hl(t),t.flags&2048&&so(9,t,t.return);break;case 3:Hl(t);break;case 12:Hl(t);break;case 22:var e=t.stateNode;t.memoizedState!==null&&e._visibility&2&&(t.return===null||t.return.tag!==13)?(e._visibility&=-3,Hr(t)):Hl(t);break;default:Hl(t)}}function Hr(t){var e=t.deletions;if((t.flags&16)!==0){if(e!==null)for(var n=0;n<e.length;n++){var o=e[n];Xt=o,G0(o,t)}X0(t)}for(t=t.child;t!==null;){switch(e=t,e.tag){case 0:case 11:case 15:so(8,e,e.return),Hr(e);break;case 22:n=e.stateNode,n._visibility&2&&(n._visibility&=-3,Hr(e));break;default:Hr(e)}t=t.sibling}}function G0(t,e){for(;Xt!==null;){var n=Xt;switch(n.tag){case 0:case 11:case 15:so(8,n,e);break;case 23:case 22:if(n.memoizedState!==null&&n.memoizedState.cachePool!==null){var o=n.memoizedState.cachePool.pool;o!=null&&o.refCount++}break;case 24:xi(n.memoizedState.cache)}if(o=n.child,o!==null)o.return=n,Xt=o;else t:for(n=t;Xt!==null;){o=Xt;var a=o.sibling,l=o.return;if(R0(o),o===n){Xt=null;break t}if(a!==null){a.return=l,Xt=a;break t}Xt=l}}}var rE={getCacheForType:function(t){var e=Jt(Lt),n=e.data.get(t);return n===void 0&&(n=t(),e.data.set(t,n)),n},cacheSignal:function(){return Jt(Lt).controller.signal}},uE=typeof WeakMap=="function"?WeakMap:Map,st=0,vt=null,lt=null,it=0,ht=0,me=null,In=!1,al=!1,pd=!1,Dn=0,Ct=0,fo=0,Uo=0,gd=0,be=0,Ja=0,Wl=null,fe=null,pf=!1,Eu=0,Q0=0,eu=1/0,nu=null,oo=null,Yt=0,ao=null,Ia=null,zn=0,gf=0,mf=null,j0=null,Fl=0,yf=null;function we(){return(st&2)!==0&&it!==0?it&-it:F.T!==null?yd():em()}function K0(){if(be===0)if((it&536870912)===0||rt){var t=rr;rr<<=1,(rr&3932160)===0&&(rr=262144),be=t}else be=536870912;return t=Ne.current,t!==null&&(t.flags|=32),be}function de(t,e,n){(t===vt&&(ht===2||ht===9)||t.cancelPendingCommit!==null)&&(Wa(t,0),Wn(t,it,be,!1)),yi(t,n),((st&2)===0||t!==vt)&&(t===vt&&((st&2)===0&&(Uo|=n),Ct===4&&Wn(t,it,be,!1)),an(t))}function $0(t,e,n){if((st&6)!==0)throw Error(L(327));var o=!n&&(e&127)===0&&(e&t.expiredLanes)===0||mi(t,e),a=o?fE(t,e):Ms(t,e,!0),l=o;do{if(a===0){al&&!o&&Wn(t,e,0,!1);break}else{if(n=t.current.alternate,l&&!cE(n)){a=Ms(t,e,!1),l=!1;continue}if(a===2){if(l=e,t.errorRecoveryDisabledLanes&l)var i=0;else i=t.pendingLanes&-536870913,i=i!==0?i:i&536870912?536870912:0;if(i!==0){e=i;t:{var r=t;a=Wl;var u=r.current.memoizedState.isDehydrated;if(u&&(Wa(r,i).flags|=256),i=Ms(r,i,!1),i!==2){if(pd&&!u){r.errorRecoveryDisabledLanes|=l,Uo|=l,a=4;break t}l=fe,fe=a,l!==null&&(fe===null?fe=l:fe.push.apply(fe,l))}a=i}if(l=!1,a!==2)continue}}if(a===1){Wa(t,0),Wn(t,e,0,!0);break}t:{switch(o=t,l=a,l){case 0:case 1:throw Error(L(345));case 4:if((e&4194048)!==e)break;case 6:Wn(o,e,be,!In);break t;case 2:fe=null;break;case 3:case 5:break;default:throw Error(L(329))}if((e&62914560)===e&&(a=Eu+300-xe(),10<a)){if(Wn(o,e,be,!In),hu(o,0,!0)!==0)break t;zn=e,o.timeoutHandle=py(dg.bind(null,o,n,fe,nu,pf,e,be,Uo,Ja,In,l,"Throttled",-0,0),a);break t}dg(o,n,fe,nu,pf,e,be,Uo,Ja,In,l,null,-0,0)}}break}while(!0);an(t)}function dg(t,e,n,o,a,l,i,r,u,s,c,d,f,p){if(t.timeoutHandle=-1,d=e.subtreeFlags,d&8192||(d&16785408)===16785408){d={stylesheets:null,count:0,imgCount:0,imgBytes:0,suspenseyImages:[],waitingForImages:!0,waitingForViewTransition:!1,unsuspend:wn},q0(e,l,d);var y=(l&62914560)===l?Eu-xe():(l&4194048)===l?Q0-xe():0;if(y=QE(d,y),y!==null){zn=l,t.cancelPendingCommit=y(pg.bind(null,t,e,l,n,o,a,i,r,u,c,d,null,f,p)),Wn(t,l,i,!s);return}}pg(t,e,l,n,o,a,i,r,u)}function cE(t){for(var e=t;;){var n=e.tag;if((n===0||n===11||n===15)&&e.flags&16384&&(n=e.updateQueue,n!==null&&(n=n.stores,n!==null)))for(var o=0;o<n.length;o++){var a=n[o],l=a.getSnapshot;a=a.value;try{if(!Ee(l(),a))return!1}catch{return!1}}if(n=e.child,e.subtreeFlags&16384&&n!==null)n.return=e,e=n;else{if(e===t)break;for(;e.sibling===null;){if(e.return===null||e.return===t)return!0;e=e.return}e.sibling.return=e.return,e=e.sibling}}return!0}function Wn(t,e,n,o){e&=~gd,e&=~Uo,t.suspendedLanes|=e,t.pingedLanes&=~e,o&&(t.warmLanes|=e),o=t.expirationTimes;for(var a=e;0<a;){var l=31-_e(a),i=1<<l;o[l]=-1,a&=~i}n!==0&&Fg(t,n,e)}function Nu(){return(st&6)===0?(wi(0,!1),!1):!0}function md(){if(lt!==null){if(ht===0)var t=lt.return;else t=lt,En=$o=null,ed(t),Va=null,ii=0,t=lt;for(;t!==null;)z0(t.alternate,t),t=t.return;lt=null}}function Wa(t,e){var n=t.timeoutHandle;n!==-1&&(t.timeoutHandle=-1,zE(n)),n=t.cancelPendingCommit,n!==null&&(t.cancelPendingCommit=null,n()),zn=0,md(),vt=t,lt=n=Nn(t.current,null),it=e,ht=0,me=null,In=!1,al=mi(t,e),pd=!1,Ja=be=gd=Uo=fo=Ct=0,fe=Wl=null,pf=!1,(e&8)!==0&&(e|=e&32);var o=t.entangledLanes;if(o!==0)for(t=t.entanglements,o&=e;0<o;){var a=31-_e(o),l=1<<a;e|=t[a],o&=~l}return Dn=e,yu(),n}function J0(t,e){et=null,F.H=ui,e===ol||e===bu?(e=Gp(),ht=3):e===$f?(e=Gp(),ht=4):ht=e===sd?8:e!==null&&typeof e=="object"&&typeof e.then=="function"?6:1,me=e,lt===null&&(Ct=1,Fr(t,He(e,t.current)))}function I0(){var t=Ne.current;return t===null?!0:(it&4194048)===it?Be===null:(it&62914560)===it||(it&536870912)!==0?t===Be:!1}function W0(){var t=F.H;return F.H=ui,t===null?ui:t}function F0(){var t=F.A;return F.A=rE,t}function ou(){Ct=4,In||(it&4194048)!==it&&Ne.current!==null||(al=!0),(fo&134217727)===0&&(Uo&134217727)===0||vt===null||Wn(vt,it,be,!1)}function Ms(t,e,n){var o=st;st|=2;var a=W0(),l=F0();(vt!==t||it!==e)&&(nu=null,Wa(t,e)),e=!1;var i=Ct;t:do try{if(ht!==0&&lt!==null){var r=lt,u=me;switch(ht){case 8:md(),i=6;break t;case 3:case 2:case 9:case 6:Ne.current===null&&(e=!0);var s=ht;if(ht=0,me=null,Ba(t,r,u,s),n&&al){i=0;break t}break;default:s=ht,ht=0,me=null,Ba(t,r,u,s)}}sE(),i=Ct;break}catch(c){J0(t,c)}while(!0);return e&&t.shellSuspendCounter++,En=$o=null,st=o,F.H=a,F.A=l,lt===null&&(vt=null,it=0,yu()),i}function sE(){for(;lt!==null;)P0(lt)}function fE(t,e){var n=st;st|=2;var o=W0(),a=F0();vt!==t||it!==e?(nu=null,eu=xe()+500,Wa(t,e)):al=mi(t,e);t:do try{if(ht!==0&&lt!==null){e=lt;var l=me;e:switch(ht){case 1:ht=0,me=null,Ba(t,e,l,1);break;case 2:case 9:if(Zp(l)){ht=0,me=null,hg(e);break}e=function(){ht!==2&&ht!==9||vt!==t||(ht=7),an(t)},l.then(e,e);break t;case 3:ht=7;break t;case 4:ht=5;break t;case 7:Zp(l)?(ht=0,me=null,hg(e)):(ht=0,me=null,Ba(t,e,l,7));break;case 5:var i=null;switch(lt.tag){case 26:i=lt.memoizedState;case 5:case 27:var r=lt;if(i?by(i):r.stateNode.complete){ht=0,me=null;var u=r.sibling;if(u!==null)lt=u;else{var s=r.return;s!==null?(lt=s,Mu(s)):lt=null}break e}}ht=0,me=null,Ba(t,e,l,5);break;case 6:ht=0,me=null,Ba(t,e,l,6);break;case 8:md(),Ct=6;break t;default:throw Error(L(462))}}dE();break}catch(c){J0(t,c)}while(!0);return En=$o=null,F.H=o,F.A=a,st=n,lt!==null?0:(vt=null,it=0,yu(),Ct)}function dE(){for(;lt!==null&&!B_();)P0(lt)}function P0(t){var e=M0(t.alternate,t,Dn);t.memoizedProps=t.pendingProps,e===null?Mu(t):lt=e}function hg(t){var e=t,n=e.alternate;switch(e.tag){case 15:case 0:e=ig(n,e,e.pendingProps,e.type,void 0,it);break;case 11:e=ig(n,e,e.pendingProps,e.type.render,e.ref,it);break;case 5:ed(e);default:z0(n,e),e=lt=zm(e,Dn),e=M0(n,e,Dn)}t.memoizedProps=t.pendingProps,e===null?Mu(t):lt=e}function Ba(t,e,n,o){En=$o=null,ed(e),Va=null,ii=0;var a=e.return;try{if(tE(t,a,e,n,it)){Ct=1,Fr(t,He(n,t.current)),lt=null;return}}catch(l){if(a!==null)throw lt=a,l;Ct=1,Fr(t,He(n,t.current)),lt=null;return}e.flags&32768?(rt||o===1?t=!0:al||(it&536870912)!==0?t=!1:(In=t=!0,(o===2||o===9||o===3||o===6)&&(o=Ne.current,o!==null&&o.tag===13&&(o.flags|=16384))),ty(e,t)):Mu(e)}function Mu(t){var e=t;do{if((e.flags&32768)!==0){ty(e,In);return}t=e.return;var n=oE(e.alternate,e,Dn);if(n!==null){lt=n;return}if(e=e.sibling,e!==null){lt=e;return}lt=e=t}while(e!==null);Ct===0&&(Ct=5)}function ty(t,e){do{var n=aE(t.alternate,t);if(n!==null){n.flags&=32767,lt=n;return}if(n=t.return,n!==null&&(n.flags|=32768,n.subtreeFlags=0,n.deletions=null),!e&&(t=t.sibling,t!==null)){lt=t;return}lt=t=n}while(t!==null);Ct=6,lt=null}function pg(t,e,n,o,a,l,i,r,u){t.cancelPendingCommit=null;do zu();while(Yt!==0);if((st&6)!==0)throw Error(L(327));if(e!==null){if(e===t.current)throw Error(L(177));if(l=e.lanes|e.childLanes,l|=qf,Q_(t,n,l,i,r,u),t===vt&&(lt=vt=null,it=0),Ia=e,ao=t,zn=n,gf=l,mf=a,j0=o,(e.subtreeFlags&10256)!==0||(e.flags&10256)!==0?(t.callbackNode=null,t.callbackPriority=0,mE(qr,function(){return ly(),null})):(t.callbackNode=null,t.callbackPriority=0),o=(e.flags&13878)!==0,(e.subtreeFlags&13878)!==0||o){o=F.T,F.T=null,a=ft.p,ft.p=2,i=st,st|=4;try{lE(t,e,n)}finally{st=i,ft.p=a,F.T=o}}Yt=1,ey(),ny(),oy()}}function ey(){if(Yt===1){Yt=0;var t=ao,e=Ia,n=(e.flags&13878)!==0;if((e.subtreeFlags&13878)!==0||n){n=F.T,F.T=null;var o=ft.p;ft.p=2;var a=st;st|=4;try{U0(e,t);var l=Sf,i=bm(t.containerInfo),r=l.focusedElem,u=l.selectionRange;if(i!==r&&r&&r.ownerDocument&&vm(r.ownerDocument.documentElement,r)){if(u!==null&&Vf(r)){var s=u.start,c=u.end;if(c===void 0&&(c=s),"selectionStart"in r)r.selectionStart=s,r.selectionEnd=Math.min(c,r.value.length);else{var d=r.ownerDocument||document,f=d&&d.defaultView||window;if(f.getSelection){var p=f.getSelection(),y=r.textContent.length,b=Math.min(u.start,y),x=u.end===void 0?b:Math.min(u.end,y);!p.extend&&b>x&&(i=x,x=b,b=i);var g=kp(r,b),m=kp(r,x);if(g&&m&&(p.rangeCount!==1||p.anchorNode!==g.node||p.anchorOffset!==g.offset||p.focusNode!==m.node||p.focusOffset!==m.offset)){var h=d.createRange();h.setStart(g.node,g.offset),p.removeAllRanges(),b>x?(p.addRange(h),p.extend(m.node,m.offset)):(h.setEnd(m.node,m.offset),p.addRange(h))}}}}for(d=[],p=r;p=p.parentNode;)p.nodeType===1&&d.push({element:p,left:p.scrollLeft,top:p.scrollTop});for(typeof r.focus=="function"&&r.focus(),r=0;r<d.length;r++){var v=d[r];v.element.scrollLeft=v.left,v.element.scrollTop=v.top}}fu=!!xf,Sf=xf=null}finally{st=a,ft.p=o,F.T=n}}t.current=e,Yt=2}}function ny(){if(Yt===2){Yt=0;var t=ao,e=Ia,n=(e.flags&8772)!==0;if((e.subtreeFlags&8772)!==0||n){n=F.T,F.T=null;var o=ft.p;ft.p=2;var a=st;st|=4;try{H0(t,e.alternate,e)}finally{st=a,ft.p=o,F.T=n}}Yt=3}}function oy(){if(Yt===4||Yt===3){Yt=0,k_();var t=ao,e=Ia,n=zn,o=j0;(e.subtreeFlags&10256)!==0||(e.flags&10256)!==0?Yt=5:(Yt=0,Ia=ao=null,ay(t,t.pendingLanes));var a=t.pendingLanes;if(a===0&&(oo=null),Hf(n),e=e.stateNode,Se&&typeof Se.onCommitFiberRoot=="function")try{Se.onCommitFiberRoot(gi,e,void 0,(e.current.flags&128)===128)}catch{}if(o!==null){e=F.T,a=ft.p,ft.p=2,F.T=null;try{for(var l=t.onRecoverableError,i=0;i<o.length;i++){var r=o[i];l(r.value,{componentStack:r.stack})}}finally{F.T=e,ft.p=a}}(zn&3)!==0&&zu(),an(t),a=t.pendingLanes,(n&261930)!==0&&(a&42)!==0?t===yf?Fl++:(Fl=0,yf=t):Fl=0,wi(0,!1)}}function ay(t,e){(t.pooledCacheLanes&=e)===0&&(e=t.pooledCache,e!=null&&(t.pooledCache=null,xi(e)))}function zu(){return ey(),ny(),oy(),ly()}function ly(){if(Yt!==5)return!1;var t=ao,e=gf;gf=0;var n=Hf(zn),o=F.T,a=ft.p;try{ft.p=32>n?32:n,F.T=null,n=mf,mf=null;var l=ao,i=zn;if(Yt=0,Ia=ao=null,zn=0,(st&6)!==0)throw Error(L(331));var r=st;if(st|=4,Z0(l.current),V0(l,l.current,i,n),st=r,wi(0,!1),Se&&typeof Se.onPostCommitFiberRoot=="function")try{Se.onPostCommitFiberRoot(gi,l)}catch{}return!0}finally{ft.p=a,F.T=o,ay(t,e)}}function gg(t,e,n){e=He(n,e),e=sf(t.stateNode,e,2),t=no(t,e,2),t!==null&&(yi(t,2),an(t))}function pt(t,e,n){if(t.tag===3)gg(t,t,n);else for(;e!==null;){if(e.tag===3){gg(e,t,n);break}else if(e.tag===1){var o=e.stateNode;if(typeof e.type.getDerivedStateFromError=="function"||typeof o.componentDidCatch=="function"&&(oo===null||!oo.has(o))){t=He(n,t),n=x0(2),o=no(e,n,2),o!==null&&(S0(n,o,e,t),yi(o,2),an(o));break}}e=e.return}}function zs(t,e,n){var o=t.pingCache;if(o===null){o=t.pingCache=new uE;var a=new Set;o.set(e,a)}else a=o.get(e),a===void 0&&(a=new Set,o.set(e,a));a.has(n)||(pd=!0,a.add(n),t=hE.bind(null,t,e,n),e.then(t,t))}function hE(t,e,n){var o=t.pingCache;o!==null&&o.delete(e),t.pingedLanes|=t.suspendedLanes&n,t.warmLanes&=~n,vt===t&&(it&n)===n&&(Ct===4||Ct===3&&(it&62914560)===it&&300>xe()-Eu?(st&2)===0&&Wa(t,0):gd|=n,Ja===it&&(Ja=0)),an(t)}function iy(t,e){e===0&&(e=Wg()),t=Ko(t,e),t!==null&&(yi(t,e),an(t))}function pE(t){var e=t.memoizedState,n=0;e!==null&&(n=e.retryLane),iy(t,n)}function gE(t,e){var n=0;switch(t.tag){case 31:case 13:var o=t.stateNode,a=t.memoizedState;a!==null&&(n=a.retryLane);break;case 19:o=t.stateNode;break;case 22:o=t.stateNode._retryCache;break;default:throw Error(L(314))}o!==null&&o.delete(e),iy(t,n)}function mE(t,e){return Of(t,e)}var au=null,wa=null,vf=!1,lu=!1,As=!1,Fn=0;function an(t){t!==wa&&t.next===null&&(wa===null?au=wa=t:wa=wa.next=t),lu=!0,vf||(vf=!0,vE())}function wi(t,e){if(!As&&lu){As=!0;do for(var n=!1,o=au;o!==null;){if(!e)if(t!==0){var a=o.pendingLanes;if(a===0)var l=0;else{var i=o.suspendedLanes,r=o.pingedLanes;l=(1<<31-_e(42|t)+1)-1,l&=a&~(i&~r),l=l&201326741?l&201326741|1:l?l|2:0}l!==0&&(n=!0,mg(o,l))}else l=it,l=hu(o,o===vt?l:0,o.cancelPendingCommit!==null||o.timeoutHandle!==-1),(l&3)===0||mi(o,l)||(n=!0,mg(o,l));o=o.next}while(n);As=!1}}function yE(){ry()}function ry(){lu=vf=!1;var t=0;Fn!==0&&ME()&&(t=Fn);for(var e=xe(),n=null,o=au;o!==null;){var a=o.next,l=uy(o,e);l===0?(o.next=null,n===null?au=a:n.next=a,a===null&&(wa=n)):(n=o,(t!==0||(l&3)!==0)&&(lu=!0)),o=a}Yt!==0&&Yt!==5||wi(t,!1),Fn!==0&&(Fn=0)}function uy(t,e){for(var n=t.suspendedLanes,o=t.pingedLanes,a=t.expirationTimes,l=t.pendingLanes&-62914561;0<l;){var i=31-_e(l),r=1<<i,u=a[i];u===-1?((r&n)===0||(r&o)!==0)&&(a[i]=G_(r,e)):u<=e&&(t.expiredLanes|=r),l&=~r}if(e=vt,n=it,n=hu(t,t===e?n:0,t.cancelPendingCommit!==null||t.timeoutHandle!==-1),o=t.callbackNode,n===0||t===e&&(ht===2||ht===9)||t.cancelPendingCommit!==null)return o!==null&&o!==null&&os(o),t.callbackNode=null,t.callbackPriority=0;if((n&3)===0||mi(t,n)){if(e=n&-n,e===t.callbackPriority)return e;switch(o!==null&&os(o),Hf(n)){case 2:case 8:n=Jg;break;case 32:n=qr;break;case 268435456:n=Ig;break;default:n=qr}return o=cy.bind(null,t),n=Of(n,o),t.callbackPriority=e,t.callbackNode=n,e}return o!==null&&o!==null&&os(o),t.callbackPriority=2,t.callbackNode=null,2}function cy(t,e){if(Yt!==0&&Yt!==5)return t.callbackNode=null,t.callbackPriority=0,null;var n=t.callbackNode;if(zu()&&t.callbackNode!==n)return null;var o=it;return o=hu(t,t===vt?o:0,t.cancelPendingCommit!==null||t.timeoutHandle!==-1),o===0?null:($0(t,o,e),uy(t,xe()),t.callbackNode!=null&&t.callbackNode===n?cy.bind(null,t):null)}function mg(t,e){if(zu())return null;$0(t,e,!0)}function vE(){AE(function(){(st&6)!==0?Of($g,yE):ry()})}function yd(){if(Fn===0){var t=ja;t===0&&(t=ir,ir<<=1,(ir&261888)===0&&(ir=256)),Fn=t}return Fn}function yg(t){return t==null||typeof t=="symbol"||typeof t=="boolean"?null:typeof t=="function"?t:Er(""+t)}function vg(t,e){var n=e.ownerDocument.createElement("input");return n.name=e.name,n.value=e.value,t.id&&n.setAttribute("form",t.id),e.parentNode.insertBefore(n,e),t=new FormData(t),n.parentNode.removeChild(n),t}function bE(t,e,n,o,a){if(e==="submit"&&n&&n.stateNode===a){var l=yg((a[he]||null).action),i=o.submitter;i&&(e=(e=i[he]||null)?yg(e.formAction):i.getAttribute("formAction"),e!==null&&(l=e,i=null));var r=new pu("action","action",null,o,a);t.push({event:r,listeners:[{instance:null,listener:function(){if(o.defaultPrevented){if(Fn!==0){var u=i?vg(a,i):new FormData(a);uf(n,{pending:!0,data:u,method:a.method,action:l},null,u)}}else typeof l=="function"&&(r.preventDefault(),u=i?vg(a,i):new FormData(a),uf(n,{pending:!0,data:u,method:a.method,action:l},l,u))},currentTarget:a}]})}}for(vr=0;vr<Js.length;vr++)br=Js[vr],bg=br.toLowerCase(),xg=br[0].toUpperCase()+br.slice(1),Ge(bg,"on"+xg);var br,bg,xg,vr;Ge(Sm,"onAnimationEnd");Ge(_m,"onAnimationIteration");Ge(wm,"onAnimationStart");Ge("dblclick","onDoubleClick");Ge("focusin","onFocus");Ge("focusout","onBlur");Ge(Lw,"onTransitionRun");Ge(Uw,"onTransitionStart");Ge(Yw,"onTransitionCancel");Ge(Em,"onTransitionEnd");Ga("onMouseEnter",["mouseout","mouseover"]);Ga("onMouseLeave",["mouseout","mouseover"]);Ga("onPointerEnter",["pointerout","pointerover"]);Ga("onPointerLeave",["pointerout","pointerover"]);Go("onChange","change click focusin focusout input keydown keyup selectionchange".split(" "));Go("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" "));Go("onBeforeInput",["compositionend","keypress","textInput","paste"]);Go("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" "));Go("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" "));Go("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var ci="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(" "),xE=new Set("beforetoggle cancel close invalid load scroll scrollend toggle".split(" ").concat(ci));function sy(t,e){e=(e&4)!==0;for(var n=0;n<t.length;n++){var o=t[n],a=o.event;o=o.listeners;t:{var l=void 0;if(e)for(var i=o.length-1;0<=i;i--){var r=o[i],u=r.instance,s=r.currentTarget;if(r=r.listener,u!==l&&a.isPropagationStopped())break t;l=r,a.currentTarget=s;try{l(a)}catch(c){Zr(c)}a.currentTarget=null,l=u}else for(i=0;i<o.length;i++){if(r=o[i],u=r.instance,s=r.currentTarget,r=r.listener,u!==l&&a.isPropagationStopped())break t;l=r,a.currentTarget=s;try{l(a)}catch(c){Zr(c)}a.currentTarget=null,l=u}}}}function at(t,e){var n=e[qs];n===void 0&&(n=e[qs]=new Set);var o=t+"__bubble";n.has(o)||(fy(e,t,2,!1),n.add(o))}function Cs(t,e,n){var o=0;e&&(o|=4),fy(n,t,o,e)}var xr="_reactListening"+Math.random().toString(36).slice(2);function vd(t){if(!t[xr]){t[xr]=!0,nm.forEach(function(n){n!=="selectionchange"&&(xE.has(n)||Cs(n,!1,t),Cs(n,!0,t))});var e=t.nodeType===9?t:t.ownerDocument;e===null||e[xr]||(e[xr]=!0,Cs("selectionchange",!1,e))}}function fy(t,e,n,o){switch(Ey(e)){case 2:var a=$E;break;case 8:a=JE;break;default:a=_d}n=a.bind(null,e,n,t),a=void 0,!js||e!=="touchstart"&&e!=="touchmove"&&e!=="wheel"||(a=!0),o?a!==void 0?t.addEventListener(e,n,{capture:!0,passive:a}):t.addEventListener(e,n,!0):a!==void 0?t.addEventListener(e,n,{passive:a}):t.addEventListener(e,n,!1)}function Ts(t,e,n,o,a){var l=o;if((e&1)===0&&(e&2)===0&&o!==null)t:for(;;){if(o===null)return;var i=o.tag;if(i===3||i===4){var r=o.stateNode.containerInfo;if(r===a)break;if(i===4)for(i=o.return;i!==null;){var u=i.tag;if((u===3||u===4)&&i.stateNode.containerInfo===a)return;i=i.return}for(;r!==null;){if(i=Ma(r),i===null)return;if(u=i.tag,u===5||u===6||u===26||u===27){o=l=i;continue t}r=r.parentNode}}o=o.return}sm(function(){var s=l,c=kf(n),d=[];t:{var f=Nm.get(t);if(f!==void 0){var p=pu,y=t;switch(t){case"keypress":if(Mr(n)===0)break t;case"keydown":case"keyup":p=gw;break;case"focusin":y="focus",p=us;break;case"focusout":y="blur",p=us;break;case"beforeblur":case"afterblur":p=us;break;case"click":if(n.button===2)break t;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":p=zp;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":p=ow;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":p=vw;break;case Sm:case _m:case wm:p=iw;break;case Em:p=xw;break;case"scroll":case"scrollend":p=ew;break;case"wheel":p=_w;break;case"copy":case"cut":case"paste":p=uw;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":p=Cp;break;case"toggle":case"beforetoggle":p=Ew}var b=(e&4)!==0,x=!b&&(t==="scroll"||t==="scrollend"),g=b?f!==null?f+"Capture":null:f;b=[];for(var m=s,h;m!==null;){var v=m;if(h=v.stateNode,v=v.tag,v!==5&&v!==26&&v!==27||h===null||g===null||(v=ei(m,g),v!=null&&b.push(si(m,v,h))),x)break;m=m.return}0<b.length&&(f=new p(f,y,null,n,c),d.push({event:f,listeners:b}))}}if((e&7)===0){t:{if(f=t==="mouseover"||t==="pointerover",p=t==="mouseout"||t==="pointerout",f&&n!==Qs&&(y=n.relatedTarget||n.fromElement)&&(Ma(y)||y[tl]))break t;if((p||f)&&(f=c.window===c?c:(f=c.ownerDocument)?f.defaultView||f.parentWindow:window,p?(y=n.relatedTarget||n.toElement,p=s,y=y?Ma(y):null,y!==null&&(x=pi(y),b=y.tag,y!==x||b!==5&&b!==27&&b!==6)&&(y=null)):(p=null,y=s),p!==y)){if(b=zp,v="onMouseLeave",g="onMouseEnter",m="mouse",(t==="pointerout"||t==="pointerover")&&(b=Cp,v="onPointerLeave",g="onPointerEnter",m="pointer"),x=p==null?f:Ul(p),h=y==null?f:Ul(y),f=new b(v,m+"leave",p,n,c),f.target=x,f.relatedTarget=h,v=null,Ma(c)===s&&(b=new b(g,m+"enter",y,n,c),b.target=h,b.relatedTarget=x,v=b),x=v,p&&y)e:{for(b=SE,g=p,m=y,h=0,v=g;v;v=b(v))h++;v=0;for(var _=m;_;_=b(_))v++;for(;0<h-v;)g=b(g),h--;for(;0<v-h;)m=b(m),v--;for(;h--;){if(g===m||m!==null&&g===m.alternate){b=g;break e}g=b(g),m=b(m)}b=null}else b=null;p!==null&&Sg(d,f,p,b,!1),y!==null&&x!==null&&Sg(d,x,y,b,!0)}}t:{if(f=s?Ul(s):window,p=f.nodeName&&f.nodeName.toLowerCase(),p==="select"||p==="input"&&f.type==="file")var E=Hp;else if(Dp(f))if(mm)E=Rw;else{E=Dw;var w=Ow}else p=f.nodeName,!p||p.toLowerCase()!=="input"||f.type!=="checkbox"&&f.type!=="radio"?s&&Bf(s.elementType)&&(E=Hp):E=Hw;if(E&&(E=E(t,s))){gm(d,E,n,c);break t}w&&w(t,f,s),t==="focusout"&&s&&f.type==="number"&&s.memoizedProps.value!=null&&Gs(f,"number",f.value)}switch(w=s?Ul(s):window,t){case"focusin":(Dp(w)||w.contentEditable==="true")&&(Ca=w,Ks=s,Zl=null);break;case"focusout":Zl=Ks=Ca=null;break;case"mousedown":$s=!0;break;case"contextmenu":case"mouseup":case"dragend":$s=!1,Lp(d,n,c);break;case"selectionchange":if(kw)break;case"keydown":case"keyup":Lp(d,n,c)}var N;if(Yf)t:{switch(t){case"compositionstart":var M="onCompositionStart";break t;case"compositionend":M="onCompositionEnd";break t;case"compositionupdate":M="onCompositionUpdate";break t}M=void 0}else Aa?hm(t,n)&&(M="onCompositionEnd"):t==="keydown"&&n.keyCode===229&&(M="onCompositionStart");M&&(dm&&n.locale!=="ko"&&(Aa||M!=="onCompositionStart"?M==="onCompositionEnd"&&Aa&&(N=fm()):(Jn=c,Lf="value"in Jn?Jn.value:Jn.textContent,Aa=!0)),w=iu(s,M),0<w.length&&(M=new Ap(M,t,null,n,c),d.push({event:M,listeners:w}),N?M.data=N:(N=pm(n),N!==null&&(M.data=N)))),(N=Mw?zw(t,n):Aw(t,n))&&(M=iu(s,"onBeforeInput"),0<M.length&&(w=new Ap("onBeforeInput","beforeinput",null,n,c),d.push({event:w,listeners:M}),w.data=N)),bE(d,t,s,n,c)}sy(d,e)})}function si(t,e,n){return{instance:t,listener:e,currentTarget:n}}function iu(t,e){for(var n=e+"Capture",o=[];t!==null;){var a=t,l=a.stateNode;if(a=a.tag,a!==5&&a!==26&&a!==27||l===null||(a=ei(t,n),a!=null&&o.unshift(si(t,a,l)),a=ei(t,e),a!=null&&o.push(si(t,a,l))),t.tag===3)return o;t=t.return}return[]}function SE(t){if(t===null)return null;do t=t.return;while(t&&t.tag!==5&&t.tag!==27);return t||null}function Sg(t,e,n,o,a){for(var l=e._reactName,i=[];n!==null&&n!==o;){var r=n,u=r.alternate,s=r.stateNode;if(r=r.tag,u!==null&&u===o)break;r!==5&&r!==26&&r!==27||s===null||(u=s,a?(s=ei(n,l),s!=null&&i.unshift(si(n,s,u))):a||(s=ei(n,l),s!=null&&i.push(si(n,s,u)))),n=n.return}i.length!==0&&t.push({event:e,listeners:i})}var _E=/\r\n?/g,wE=/\u0000|\uFFFD/g;function _g(t){return(typeof t=="string"?t:""+t).replace(_E,`
9
+ `).replace(wE,"")}function dy(t,e){return e=_g(e),_g(t)===e}function mt(t,e,n,o,a,l){switch(n){case"children":typeof o=="string"?e==="body"||e==="textarea"&&o===""||Qa(t,o):(typeof o=="number"||typeof o=="bigint")&&e!=="body"&&Qa(t,""+o);break;case"className":cr(t,"class",o);break;case"tabIndex":cr(t,"tabindex",o);break;case"dir":case"role":case"viewBox":case"width":case"height":cr(t,n,o);break;case"style":cm(t,o,l);break;case"data":if(e!=="object"){cr(t,"data",o);break}case"src":case"href":if(o===""&&(e!=="a"||n!=="href")){t.removeAttribute(n);break}if(o==null||typeof o=="function"||typeof o=="symbol"||typeof o=="boolean"){t.removeAttribute(n);break}o=Er(""+o),t.setAttribute(n,o);break;case"action":case"formAction":if(typeof o=="function"){t.setAttribute(n,"javascript:throw new Error('A React form was unexpectedly submitted. If you called form.submit() manually, consider using form.requestSubmit() instead. If you\\'re trying to use event.stopPropagation() in a submit event handler, consider also calling event.preventDefault().')");break}else typeof l=="function"&&(n==="formAction"?(e!=="input"&&mt(t,e,"name",a.name,a,null),mt(t,e,"formEncType",a.formEncType,a,null),mt(t,e,"formMethod",a.formMethod,a,null),mt(t,e,"formTarget",a.formTarget,a,null)):(mt(t,e,"encType",a.encType,a,null),mt(t,e,"method",a.method,a,null),mt(t,e,"target",a.target,a,null)));if(o==null||typeof o=="symbol"||typeof o=="boolean"){t.removeAttribute(n);break}o=Er(""+o),t.setAttribute(n,o);break;case"onClick":o!=null&&(t.onclick=wn);break;case"onScroll":o!=null&&at("scroll",t);break;case"onScrollEnd":o!=null&&at("scrollend",t);break;case"dangerouslySetInnerHTML":if(o!=null){if(typeof o!="object"||!("__html"in o))throw Error(L(61));if(n=o.__html,n!=null){if(a.children!=null)throw Error(L(60));t.innerHTML=n}}break;case"multiple":t.multiple=o&&typeof o!="function"&&typeof o!="symbol";break;case"muted":t.muted=o&&typeof o!="function"&&typeof o!="symbol";break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":break;case"autoFocus":break;case"xlinkHref":if(o==null||typeof o=="function"||typeof o=="boolean"||typeof o=="symbol"){t.removeAttribute("xlink:href");break}n=Er(""+o),t.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",n);break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":o!=null&&typeof o!="function"&&typeof o!="symbol"?t.setAttribute(n,""+o):t.removeAttribute(n);break;case"inert":case"allowFullScreen":case"async":case"autoPlay":case"controls":case"default":case"defer":case"disabled":case"disablePictureInPicture":case"disableRemotePlayback":case"formNoValidate":case"hidden":case"loop":case"noModule":case"noValidate":case"open":case"playsInline":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"itemScope":o&&typeof o!="function"&&typeof o!="symbol"?t.setAttribute(n,""):t.removeAttribute(n);break;case"capture":case"download":o===!0?t.setAttribute(n,""):o!==!1&&o!=null&&typeof o!="function"&&typeof o!="symbol"?t.setAttribute(n,o):t.removeAttribute(n);break;case"cols":case"rows":case"size":case"span":o!=null&&typeof o!="function"&&typeof o!="symbol"&&!isNaN(o)&&1<=o?t.setAttribute(n,o):t.removeAttribute(n);break;case"rowSpan":case"start":o==null||typeof o=="function"||typeof o=="symbol"||isNaN(o)?t.removeAttribute(n):t.setAttribute(n,o);break;case"popover":at("beforetoggle",t),at("toggle",t),wr(t,"popover",o);break;case"xlinkActuate":gn(t,"http://www.w3.org/1999/xlink","xlink:actuate",o);break;case"xlinkArcrole":gn(t,"http://www.w3.org/1999/xlink","xlink:arcrole",o);break;case"xlinkRole":gn(t,"http://www.w3.org/1999/xlink","xlink:role",o);break;case"xlinkShow":gn(t,"http://www.w3.org/1999/xlink","xlink:show",o);break;case"xlinkTitle":gn(t,"http://www.w3.org/1999/xlink","xlink:title",o);break;case"xlinkType":gn(t,"http://www.w3.org/1999/xlink","xlink:type",o);break;case"xmlBase":gn(t,"http://www.w3.org/XML/1998/namespace","xml:base",o);break;case"xmlLang":gn(t,"http://www.w3.org/XML/1998/namespace","xml:lang",o);break;case"xmlSpace":gn(t,"http://www.w3.org/XML/1998/namespace","xml:space",o);break;case"is":wr(t,"is",o);break;case"innerText":case"textContent":break;default:(!(2<n.length)||n[0]!=="o"&&n[0]!=="O"||n[1]!=="n"&&n[1]!=="N")&&(n=P_.get(n)||n,wr(t,n,o))}}function bf(t,e,n,o,a,l){switch(n){case"style":cm(t,o,l);break;case"dangerouslySetInnerHTML":if(o!=null){if(typeof o!="object"||!("__html"in o))throw Error(L(61));if(n=o.__html,n!=null){if(a.children!=null)throw Error(L(60));t.innerHTML=n}}break;case"children":typeof o=="string"?Qa(t,o):(typeof o=="number"||typeof o=="bigint")&&Qa(t,""+o);break;case"onScroll":o!=null&&at("scroll",t);break;case"onScrollEnd":o!=null&&at("scrollend",t);break;case"onClick":o!=null&&(t.onclick=wn);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"innerHTML":case"ref":break;case"innerText":case"textContent":break;default:if(!om.hasOwnProperty(n))t:{if(n[0]==="o"&&n[1]==="n"&&(a=n.endsWith("Capture"),e=n.slice(2,a?n.length-7:void 0),l=t[he]||null,l=l!=null?l[n]:null,typeof l=="function"&&t.removeEventListener(e,l,a),typeof o=="function")){typeof l!="function"&&l!==null&&(n in t?t[n]=null:t.hasAttribute(n)&&t.removeAttribute(n)),t.addEventListener(e,o,a);break t}n in t?t[n]=o:o===!0?t.setAttribute(n,""):wr(t,n,o)}}}function It(t,e,n){switch(e){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"img":at("error",t),at("load",t);var o=!1,a=!1,l;for(l in n)if(n.hasOwnProperty(l)){var i=n[l];if(i!=null)switch(l){case"src":o=!0;break;case"srcSet":a=!0;break;case"children":case"dangerouslySetInnerHTML":throw Error(L(137,e));default:mt(t,e,l,i,n,null)}}a&&mt(t,e,"srcSet",n.srcSet,n,null),o&&mt(t,e,"src",n.src,n,null);return;case"input":at("invalid",t);var r=l=i=a=null,u=null,s=null;for(o in n)if(n.hasOwnProperty(o)){var c=n[o];if(c!=null)switch(o){case"name":a=c;break;case"type":i=c;break;case"checked":u=c;break;case"defaultChecked":s=c;break;case"value":l=c;break;case"defaultValue":r=c;break;case"children":case"dangerouslySetInnerHTML":if(c!=null)throw Error(L(137,e));break;default:mt(t,e,o,c,n,null)}}im(t,l,r,u,s,i,a,!1);return;case"select":at("invalid",t),o=i=l=null;for(a in n)if(n.hasOwnProperty(a)&&(r=n[a],r!=null))switch(a){case"value":l=r;break;case"defaultValue":i=r;break;case"multiple":o=r;default:mt(t,e,a,r,n,null)}e=l,n=i,t.multiple=!!o,e!=null?La(t,!!o,e,!1):n!=null&&La(t,!!o,n,!0);return;case"textarea":at("invalid",t),l=a=o=null;for(i in n)if(n.hasOwnProperty(i)&&(r=n[i],r!=null))switch(i){case"value":o=r;break;case"defaultValue":a=r;break;case"children":l=r;break;case"dangerouslySetInnerHTML":if(r!=null)throw Error(L(91));break;default:mt(t,e,i,r,n,null)}um(t,o,a,l);return;case"option":for(u in n)n.hasOwnProperty(u)&&(o=n[u],o!=null)&&(u==="selected"?t.selected=o&&typeof o!="function"&&typeof o!="symbol":mt(t,e,u,o,n,null));return;case"dialog":at("beforetoggle",t),at("toggle",t),at("cancel",t),at("close",t);break;case"iframe":case"object":at("load",t);break;case"video":case"audio":for(o=0;o<ci.length;o++)at(ci[o],t);break;case"image":at("error",t),at("load",t);break;case"details":at("toggle",t);break;case"embed":case"source":case"link":at("error",t),at("load",t);case"area":case"base":case"br":case"col":case"hr":case"keygen":case"meta":case"param":case"track":case"wbr":case"menuitem":for(s in n)if(n.hasOwnProperty(s)&&(o=n[s],o!=null))switch(s){case"children":case"dangerouslySetInnerHTML":throw Error(L(137,e));default:mt(t,e,s,o,n,null)}return;default:if(Bf(e)){for(c in n)n.hasOwnProperty(c)&&(o=n[c],o!==void 0&&bf(t,e,c,o,n,void 0));return}}for(r in n)n.hasOwnProperty(r)&&(o=n[r],o!=null&&mt(t,e,r,o,n,null))}function EE(t,e,n,o){switch(e){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"input":var a=null,l=null,i=null,r=null,u=null,s=null,c=null;for(p in n){var d=n[p];if(n.hasOwnProperty(p)&&d!=null)switch(p){case"checked":break;case"value":break;case"defaultValue":u=d;default:o.hasOwnProperty(p)||mt(t,e,p,null,o,d)}}for(var f in o){var p=o[f];if(d=n[f],o.hasOwnProperty(f)&&(p!=null||d!=null))switch(f){case"type":l=p;break;case"name":a=p;break;case"checked":s=p;break;case"defaultChecked":c=p;break;case"value":i=p;break;case"defaultValue":r=p;break;case"children":case"dangerouslySetInnerHTML":if(p!=null)throw Error(L(137,e));break;default:p!==d&&mt(t,e,f,p,o,d)}}Zs(t,i,r,u,s,c,l,a);return;case"select":p=i=r=f=null;for(l in n)if(u=n[l],n.hasOwnProperty(l)&&u!=null)switch(l){case"value":break;case"multiple":p=u;default:o.hasOwnProperty(l)||mt(t,e,l,null,o,u)}for(a in o)if(l=o[a],u=n[a],o.hasOwnProperty(a)&&(l!=null||u!=null))switch(a){case"value":f=l;break;case"defaultValue":r=l;break;case"multiple":i=l;default:l!==u&&mt(t,e,a,l,o,u)}e=r,n=i,o=p,f!=null?La(t,!!n,f,!1):!!o!=!!n&&(e!=null?La(t,!!n,e,!0):La(t,!!n,n?[]:"",!1));return;case"textarea":p=f=null;for(r in n)if(a=n[r],n.hasOwnProperty(r)&&a!=null&&!o.hasOwnProperty(r))switch(r){case"value":break;case"children":break;default:mt(t,e,r,null,o,a)}for(i in o)if(a=o[i],l=n[i],o.hasOwnProperty(i)&&(a!=null||l!=null))switch(i){case"value":f=a;break;case"defaultValue":p=a;break;case"children":break;case"dangerouslySetInnerHTML":if(a!=null)throw Error(L(91));break;default:a!==l&&mt(t,e,i,a,o,l)}rm(t,f,p);return;case"option":for(var y in n)f=n[y],n.hasOwnProperty(y)&&f!=null&&!o.hasOwnProperty(y)&&(y==="selected"?t.selected=!1:mt(t,e,y,null,o,f));for(u in o)f=o[u],p=n[u],o.hasOwnProperty(u)&&f!==p&&(f!=null||p!=null)&&(u==="selected"?t.selected=f&&typeof f!="function"&&typeof f!="symbol":mt(t,e,u,f,o,p));return;case"img":case"link":case"area":case"base":case"br":case"col":case"embed":case"hr":case"keygen":case"meta":case"param":case"source":case"track":case"wbr":case"menuitem":for(var b in n)f=n[b],n.hasOwnProperty(b)&&f!=null&&!o.hasOwnProperty(b)&&mt(t,e,b,null,o,f);for(s in o)if(f=o[s],p=n[s],o.hasOwnProperty(s)&&f!==p&&(f!=null||p!=null))switch(s){case"children":case"dangerouslySetInnerHTML":if(f!=null)throw Error(L(137,e));break;default:mt(t,e,s,f,o,p)}return;default:if(Bf(e)){for(var x in n)f=n[x],n.hasOwnProperty(x)&&f!==void 0&&!o.hasOwnProperty(x)&&bf(t,e,x,void 0,o,f);for(c in o)f=o[c],p=n[c],!o.hasOwnProperty(c)||f===p||f===void 0&&p===void 0||bf(t,e,c,f,o,p);return}}for(var g in n)f=n[g],n.hasOwnProperty(g)&&f!=null&&!o.hasOwnProperty(g)&&mt(t,e,g,null,o,f);for(d in o)f=o[d],p=n[d],!o.hasOwnProperty(d)||f===p||f==null&&p==null||mt(t,e,d,f,o,p)}function wg(t){switch(t){case"css":case"script":case"font":case"img":case"image":case"input":case"link":return!0;default:return!1}}function NE(){if(typeof performance.getEntriesByType=="function"){for(var t=0,e=0,n=performance.getEntriesByType("resource"),o=0;o<n.length;o++){var a=n[o],l=a.transferSize,i=a.initiatorType,r=a.duration;if(l&&r&&wg(i)){for(i=0,r=a.responseEnd,o+=1;o<n.length;o++){var u=n[o],s=u.startTime;if(s>r)break;var c=u.transferSize,d=u.initiatorType;c&&wg(d)&&(u=u.responseEnd,i+=c*(u<r?1:(r-s)/(u-s)))}if(--o,e+=8*(l+i)/(a.duration/1e3),t++,10<t)break}}if(0<t)return e/t/1e6}return navigator.connection&&(t=navigator.connection.downlink,typeof t=="number")?t:5}var xf=null,Sf=null;function ru(t){return t.nodeType===9?t:t.ownerDocument}function Eg(t){switch(t){case"http://www.w3.org/2000/svg":return 1;case"http://www.w3.org/1998/Math/MathML":return 2;default:return 0}}function hy(t,e){if(t===0)switch(e){case"svg":return 1;case"math":return 2;default:return 0}return t===1&&e==="foreignObject"?0:t}function _f(t,e){return t==="textarea"||t==="noscript"||typeof e.children=="string"||typeof e.children=="number"||typeof e.children=="bigint"||typeof e.dangerouslySetInnerHTML=="object"&&e.dangerouslySetInnerHTML!==null&&e.dangerouslySetInnerHTML.__html!=null}var Os=null;function ME(){var t=window.event;return t&&t.type==="popstate"?t===Os?!1:(Os=t,!0):(Os=null,!1)}var py=typeof setTimeout=="function"?setTimeout:void 0,zE=typeof clearTimeout=="function"?clearTimeout:void 0,Ng=typeof Promise=="function"?Promise:void 0,AE=typeof queueMicrotask=="function"?queueMicrotask:typeof Ng<"u"?function(t){return Ng.resolve(null).then(t).catch(CE)}:py;function CE(t){setTimeout(function(){throw t})}function po(t){return t==="head"}function Mg(t,e){var n=e,o=0;do{var a=n.nextSibling;if(t.removeChild(n),a&&a.nodeType===8)if(n=a.data,n==="/$"||n==="/&"){if(o===0){t.removeChild(a),Pa(e);return}o--}else if(n==="$"||n==="$?"||n==="$~"||n==="$!"||n==="&")o++;else if(n==="html")Pl(t.ownerDocument.documentElement);else if(n==="head"){n=t.ownerDocument.head,Pl(n);for(var l=n.firstChild;l;){var i=l.nextSibling,r=l.nodeName;l[vi]||r==="SCRIPT"||r==="STYLE"||r==="LINK"&&l.rel.toLowerCase()==="stylesheet"||n.removeChild(l),l=i}}else n==="body"&&Pl(t.ownerDocument.body);n=a}while(n);Pa(e)}function zg(t,e){var n=t;t=0;do{var o=n.nextSibling;if(n.nodeType===1?e?(n._stashedDisplay=n.style.display,n.style.display="none"):(n.style.display=n._stashedDisplay||"",n.getAttribute("style")===""&&n.removeAttribute("style")):n.nodeType===3&&(e?(n._stashedText=n.nodeValue,n.nodeValue=""):n.nodeValue=n._stashedText||""),o&&o.nodeType===8)if(n=o.data,n==="/$"){if(t===0)break;t--}else n!=="$"&&n!=="$?"&&n!=="$~"&&n!=="$!"||t++;n=o}while(n)}function wf(t){var e=t.firstChild;for(e&&e.nodeType===10&&(e=e.nextSibling);e;){var n=e;switch(e=e.nextSibling,n.nodeName){case"HTML":case"HEAD":case"BODY":wf(n),Rf(n);continue;case"SCRIPT":case"STYLE":continue;case"LINK":if(n.rel.toLowerCase()==="stylesheet")continue}t.removeChild(n)}}function TE(t,e,n,o){for(;t.nodeType===1;){var a=n;if(t.nodeName.toLowerCase()!==e.toLowerCase()){if(!o&&(t.nodeName!=="INPUT"||t.type!=="hidden"))break}else if(o){if(!t[vi])switch(e){case"meta":if(!t.hasAttribute("itemprop"))break;return t;case"link":if(l=t.getAttribute("rel"),l==="stylesheet"&&t.hasAttribute("data-precedence"))break;if(l!==a.rel||t.getAttribute("href")!==(a.href==null||a.href===""?null:a.href)||t.getAttribute("crossorigin")!==(a.crossOrigin==null?null:a.crossOrigin)||t.getAttribute("title")!==(a.title==null?null:a.title))break;return t;case"style":if(t.hasAttribute("data-precedence"))break;return t;case"script":if(l=t.getAttribute("src"),(l!==(a.src==null?null:a.src)||t.getAttribute("type")!==(a.type==null?null:a.type)||t.getAttribute("crossorigin")!==(a.crossOrigin==null?null:a.crossOrigin))&&l&&t.hasAttribute("async")&&!t.hasAttribute("itemprop"))break;return t;default:return t}}else if(e==="input"&&t.type==="hidden"){var l=a.name==null?null:""+a.name;if(a.type==="hidden"&&t.getAttribute("name")===l)return t}else return t;if(t=ke(t.nextSibling),t===null)break}return null}function OE(t,e,n){if(e==="")return null;for(;t.nodeType!==3;)if((t.nodeType!==1||t.nodeName!=="INPUT"||t.type!=="hidden")&&!n||(t=ke(t.nextSibling),t===null))return null;return t}function gy(t,e){for(;t.nodeType!==8;)if((t.nodeType!==1||t.nodeName!=="INPUT"||t.type!=="hidden")&&!e||(t=ke(t.nextSibling),t===null))return null;return t}function Ef(t){return t.data==="$?"||t.data==="$~"}function Nf(t){return t.data==="$!"||t.data==="$?"&&t.ownerDocument.readyState!=="loading"}function DE(t,e){var n=t.ownerDocument;if(t.data==="$~")t._reactRetry=e;else if(t.data!=="$?"||n.readyState!=="loading")e();else{var o=function(){e(),n.removeEventListener("DOMContentLoaded",o)};n.addEventListener("DOMContentLoaded",o),t._reactRetry=o}}function ke(t){for(;t!=null;t=t.nextSibling){var e=t.nodeType;if(e===1||e===3)break;if(e===8){if(e=t.data,e==="$"||e==="$!"||e==="$?"||e==="$~"||e==="&"||e==="F!"||e==="F")break;if(e==="/$"||e==="/&")return null}}return t}var Mf=null;function Ag(t){t=t.nextSibling;for(var e=0;t;){if(t.nodeType===8){var n=t.data;if(n==="/$"||n==="/&"){if(e===0)return ke(t.nextSibling);e--}else n!=="$"&&n!=="$!"&&n!=="$?"&&n!=="$~"&&n!=="&"||e++}t=t.nextSibling}return null}function Cg(t){t=t.previousSibling;for(var e=0;t;){if(t.nodeType===8){var n=t.data;if(n==="$"||n==="$!"||n==="$?"||n==="$~"||n==="&"){if(e===0)return t;e--}else n!=="/$"&&n!=="/&"||e++}t=t.previousSibling}return null}function my(t,e,n){switch(e=ru(n),t){case"html":if(t=e.documentElement,!t)throw Error(L(452));return t;case"head":if(t=e.head,!t)throw Error(L(453));return t;case"body":if(t=e.body,!t)throw Error(L(454));return t;default:throw Error(L(451))}}function Pl(t){for(var e=t.attributes;e.length;)t.removeAttributeNode(e[0]);Rf(t)}var Le=new Map,Tg=new Set;function uu(t){return typeof t.getRootNode=="function"?t.getRootNode():t.nodeType===9?t:t.ownerDocument}var Hn=ft.d;ft.d={f:HE,r:RE,D:BE,C:kE,L:LE,m:UE,X:VE,S:YE,M:qE};function HE(){var t=Hn.f(),e=Nu();return t||e}function RE(t){var e=el(t);e!==null&&e.tag===5&&e.type==="form"?c0(e):Hn.r(t)}var ll=typeof document>"u"?null:document;function yy(t,e,n){var o=ll;if(o&&typeof e=="string"&&e){var a=De(e);a='link[rel="'+t+'"][href="'+a+'"]',typeof n=="string"&&(a+='[crossorigin="'+n+'"]'),Tg.has(a)||(Tg.add(a),t={rel:t,crossOrigin:n,href:e},o.querySelector(a)===null&&(e=o.createElement("link"),It(e,"link",t),Zt(e),o.head.appendChild(e)))}}function BE(t){Hn.D(t),yy("dns-prefetch",t,null)}function kE(t,e){Hn.C(t,e),yy("preconnect",t,e)}function LE(t,e,n){Hn.L(t,e,n);var o=ll;if(o&&t&&e){var a='link[rel="preload"][as="'+De(e)+'"]';e==="image"&&n&&n.imageSrcSet?(a+='[imagesrcset="'+De(n.imageSrcSet)+'"]',typeof n.imageSizes=="string"&&(a+='[imagesizes="'+De(n.imageSizes)+'"]')):a+='[href="'+De(t)+'"]';var l=a;switch(e){case"style":l=Fa(t);break;case"script":l=il(t)}Le.has(l)||(t=wt({rel:"preload",href:e==="image"&&n&&n.imageSrcSet?void 0:t,as:e},n),Le.set(l,t),o.querySelector(a)!==null||e==="style"&&o.querySelector(Ei(l))||e==="script"&&o.querySelector(Ni(l))||(e=o.createElement("link"),It(e,"link",t),Zt(e),o.head.appendChild(e)))}}function UE(t,e){Hn.m(t,e);var n=ll;if(n&&t){var o=e&&typeof e.as=="string"?e.as:"script",a='link[rel="modulepreload"][as="'+De(o)+'"][href="'+De(t)+'"]',l=a;switch(o){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":l=il(t)}if(!Le.has(l)&&(t=wt({rel:"modulepreload",href:t},e),Le.set(l,t),n.querySelector(a)===null)){switch(o){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(n.querySelector(Ni(l)))return}o=n.createElement("link"),It(o,"link",t),Zt(o),n.head.appendChild(o)}}}function YE(t,e,n){Hn.S(t,e,n);var o=ll;if(o&&t){var a=ka(o).hoistableStyles,l=Fa(t);e=e||"default";var i=a.get(l);if(!i){var r={loading:0,preload:null};if(i=o.querySelector(Ei(l)))r.loading=5;else{t=wt({rel:"stylesheet",href:t,"data-precedence":e},n),(n=Le.get(l))&&bd(t,n);var u=i=o.createElement("link");Zt(u),It(u,"link",t),u._p=new Promise(function(s,c){u.onload=s,u.onerror=c}),u.addEventListener("load",function(){r.loading|=1}),u.addEventListener("error",function(){r.loading|=2}),r.loading|=4,Rr(i,e,o)}i={type:"stylesheet",instance:i,count:1,state:r},a.set(l,i)}}}function VE(t,e){Hn.X(t,e);var n=ll;if(n&&t){var o=ka(n).hoistableScripts,a=il(t),l=o.get(a);l||(l=n.querySelector(Ni(a)),l||(t=wt({src:t,async:!0},e),(e=Le.get(a))&&xd(t,e),l=n.createElement("script"),Zt(l),It(l,"link",t),n.head.appendChild(l)),l={type:"script",instance:l,count:1,state:null},o.set(a,l))}}function qE(t,e){Hn.M(t,e);var n=ll;if(n&&t){var o=ka(n).hoistableScripts,a=il(t),l=o.get(a);l||(l=n.querySelector(Ni(a)),l||(t=wt({src:t,async:!0,type:"module"},e),(e=Le.get(a))&&xd(t,e),l=n.createElement("script"),Zt(l),It(l,"link",t),n.head.appendChild(l)),l={type:"script",instance:l,count:1,state:null},o.set(a,l))}}function Og(t,e,n,o){var a=(a=Pn.current)?uu(a):null;if(!a)throw Error(L(446));switch(t){case"meta":case"title":return null;case"style":return typeof n.precedence=="string"&&typeof n.href=="string"?(e=Fa(n.href),n=ka(a).hoistableStyles,o=n.get(e),o||(o={type:"style",instance:null,count:0,state:null},n.set(e,o)),o):{type:"void",instance:null,count:0,state:null};case"link":if(n.rel==="stylesheet"&&typeof n.href=="string"&&typeof n.precedence=="string"){t=Fa(n.href);var l=ka(a).hoistableStyles,i=l.get(t);if(i||(a=a.ownerDocument||a,i={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},l.set(t,i),(l=a.querySelector(Ei(t)))&&!l._p&&(i.instance=l,i.state.loading=5),Le.has(t)||(n={rel:"preload",as:"style",href:n.href,crossOrigin:n.crossOrigin,integrity:n.integrity,media:n.media,hrefLang:n.hrefLang,referrerPolicy:n.referrerPolicy},Le.set(t,n),l||XE(a,t,n,i.state))),e&&o===null)throw Error(L(528,""));return i}if(e&&o!==null)throw Error(L(529,""));return null;case"script":return e=n.async,n=n.src,typeof n=="string"&&e&&typeof e!="function"&&typeof e!="symbol"?(e=il(n),n=ka(a).hoistableScripts,o=n.get(e),o||(o={type:"script",instance:null,count:0,state:null},n.set(e,o)),o):{type:"void",instance:null,count:0,state:null};default:throw Error(L(444,t))}}function Fa(t){return'href="'+De(t)+'"'}function Ei(t){return'link[rel="stylesheet"]['+t+"]"}function vy(t){return wt({},t,{"data-precedence":t.precedence,precedence:null})}function XE(t,e,n,o){t.querySelector('link[rel="preload"][as="style"]['+e+"]")?o.loading=1:(e=t.createElement("link"),o.preload=e,e.addEventListener("load",function(){return o.loading|=1}),e.addEventListener("error",function(){return o.loading|=2}),It(e,"link",n),Zt(e),t.head.appendChild(e))}function il(t){return'[src="'+De(t)+'"]'}function Ni(t){return"script[async]"+t}function Dg(t,e,n){if(e.count++,e.instance===null)switch(e.type){case"style":var o=t.querySelector('style[data-href~="'+De(n.href)+'"]');if(o)return e.instance=o,Zt(o),o;var a=wt({},n,{"data-href":n.href,"data-precedence":n.precedence,href:null,precedence:null});return o=(t.ownerDocument||t).createElement("style"),Zt(o),It(o,"style",a),Rr(o,n.precedence,t),e.instance=o;case"stylesheet":a=Fa(n.href);var l=t.querySelector(Ei(a));if(l)return e.state.loading|=4,e.instance=l,Zt(l),l;o=vy(n),(a=Le.get(a))&&bd(o,a),l=(t.ownerDocument||t).createElement("link"),Zt(l);var i=l;return i._p=new Promise(function(r,u){i.onload=r,i.onerror=u}),It(l,"link",o),e.state.loading|=4,Rr(l,n.precedence,t),e.instance=l;case"script":return l=il(n.src),(a=t.querySelector(Ni(l)))?(e.instance=a,Zt(a),a):(o=n,(a=Le.get(l))&&(o=wt({},n),xd(o,a)),t=t.ownerDocument||t,a=t.createElement("script"),Zt(a),It(a,"link",o),t.head.appendChild(a),e.instance=a);case"void":return null;default:throw Error(L(443,e.type))}else e.type==="stylesheet"&&(e.state.loading&4)===0&&(o=e.instance,e.state.loading|=4,Rr(o,n.precedence,t));return e.instance}function Rr(t,e,n){for(var o=n.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),a=o.length?o[o.length-1]:null,l=a,i=0;i<o.length;i++){var r=o[i];if(r.dataset.precedence===e)l=r;else if(l!==a)break}l?l.parentNode.insertBefore(t,l.nextSibling):(e=n.nodeType===9?n.head:n,e.insertBefore(t,e.firstChild))}function bd(t,e){t.crossOrigin==null&&(t.crossOrigin=e.crossOrigin),t.referrerPolicy==null&&(t.referrerPolicy=e.referrerPolicy),t.title==null&&(t.title=e.title)}function xd(t,e){t.crossOrigin==null&&(t.crossOrigin=e.crossOrigin),t.referrerPolicy==null&&(t.referrerPolicy=e.referrerPolicy),t.integrity==null&&(t.integrity=e.integrity)}var Br=null;function Hg(t,e,n){if(Br===null){var o=new Map,a=Br=new Map;a.set(n,o)}else a=Br,o=a.get(n),o||(o=new Map,a.set(n,o));if(o.has(t))return o;for(o.set(t,null),n=n.getElementsByTagName(t),a=0;a<n.length;a++){var l=n[a];if(!(l[vi]||l[Kt]||t==="link"&&l.getAttribute("rel")==="stylesheet")&&l.namespaceURI!=="http://www.w3.org/2000/svg"){var i=l.getAttribute(e)||"";i=t+i;var r=o.get(i);r?r.push(l):o.set(i,[l])}}return o}function Rg(t,e,n){t=t.ownerDocument||t,t.head.insertBefore(n,e==="title"?t.querySelector("head > title"):null)}function ZE(t,e,n){if(n===1||e.itemProp!=null)return!1;switch(t){case"meta":case"title":return!0;case"style":if(typeof e.precedence!="string"||typeof e.href!="string"||e.href==="")break;return!0;case"link":if(typeof e.rel!="string"||typeof e.href!="string"||e.href===""||e.onLoad||e.onError)break;return e.rel==="stylesheet"?(t=e.disabled,typeof e.precedence=="string"&&t==null):!0;case"script":if(e.async&&typeof e.async!="function"&&typeof e.async!="symbol"&&!e.onLoad&&!e.onError&&e.src&&typeof e.src=="string")return!0}return!1}function by(t){return!(t.type==="stylesheet"&&(t.state.loading&3)===0)}function GE(t,e,n,o){if(n.type==="stylesheet"&&(typeof o.media!="string"||matchMedia(o.media).matches!==!1)&&(n.state.loading&4)===0){if(n.instance===null){var a=Fa(o.href),l=e.querySelector(Ei(a));if(l){e=l._p,e!==null&&typeof e=="object"&&typeof e.then=="function"&&(t.count++,t=cu.bind(t),e.then(t,t)),n.state.loading|=4,n.instance=l,Zt(l);return}l=e.ownerDocument||e,o=vy(o),(a=Le.get(a))&&bd(o,a),l=l.createElement("link"),Zt(l);var i=l;i._p=new Promise(function(r,u){i.onload=r,i.onerror=u}),It(l,"link",o),n.instance=l}t.stylesheets===null&&(t.stylesheets=new Map),t.stylesheets.set(n,e),(e=n.state.preload)&&(n.state.loading&3)===0&&(t.count++,n=cu.bind(t),e.addEventListener("load",n),e.addEventListener("error",n))}}var Ds=0;function QE(t,e){return t.stylesheets&&t.count===0&&kr(t,t.stylesheets),0<t.count||0<t.imgCount?function(n){var o=setTimeout(function(){if(t.stylesheets&&kr(t,t.stylesheets),t.unsuspend){var l=t.unsuspend;t.unsuspend=null,l()}},6e4+e);0<t.imgBytes&&Ds===0&&(Ds=62500*NE());var a=setTimeout(function(){if(t.waitingForImages=!1,t.count===0&&(t.stylesheets&&kr(t,t.stylesheets),t.unsuspend)){var l=t.unsuspend;t.unsuspend=null,l()}},(t.imgBytes>Ds?50:800)+e);return t.unsuspend=n,function(){t.unsuspend=null,clearTimeout(o),clearTimeout(a)}}:null}function cu(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)kr(this,this.stylesheets);else if(this.unsuspend){var t=this.unsuspend;this.unsuspend=null,t()}}}var su=null;function kr(t,e){t.stylesheets=null,t.unsuspend!==null&&(t.count++,su=new Map,e.forEach(jE,t),su=null,cu.call(t))}function jE(t,e){if(!(e.state.loading&4)){var n=su.get(t);if(n)var o=n.get(null);else{n=new Map,su.set(t,n);for(var a=t.querySelectorAll("link[data-precedence],style[data-precedence]"),l=0;l<a.length;l++){var i=a[l];(i.nodeName==="LINK"||i.getAttribute("media")!=="not all")&&(n.set(i.dataset.precedence,i),o=i)}o&&n.set(null,o)}a=e.instance,i=a.getAttribute("data-precedence"),l=n.get(i)||o,l===o&&n.set(null,a),n.set(i,a),this.count++,o=cu.bind(this),a.addEventListener("load",o),a.addEventListener("error",o),l?l.parentNode.insertBefore(a,l.nextSibling):(t=t.nodeType===9?t.head:t,t.insertBefore(a,t.firstChild)),e.state.loading|=4}}var fi={$$typeof:_n,Provider:null,Consumer:null,_currentValue:Ro,_currentValue2:Ro,_threadCount:0};function KE(t,e,n,o,a,l,i,r,u){this.tag=1,this.containerInfo=t,this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.next=this.pendingContext=this.context=this.cancelPendingCommit=null,this.callbackPriority=0,this.expirationTimes=as(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=as(0),this.hiddenUpdates=as(null),this.identifierPrefix=o,this.onUncaughtError=a,this.onCaughtError=l,this.onRecoverableError=i,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=u,this.incompleteTransitions=new Map}function xy(t,e,n,o,a,l,i,r,u,s,c,d){return t=new KE(t,e,n,i,u,s,c,d,r),e=1,l===!0&&(e|=24),l=ve(3,null,null,e),t.current=l,l.stateNode=t,e=jf(),e.refCount++,t.pooledCache=e,e.refCount++,l.memoizedState={element:o,isDehydrated:n,cache:e},Jf(l),t}function Sy(t){return t?(t=Da,t):Da}function _y(t,e,n,o,a,l){a=Sy(a),o.context===null?o.context=a:o.pendingContext=a,o=eo(e),o.payload={element:n},l=l===void 0?null:l,l!==null&&(o.callback=l),n=no(t,o,e),n!==null&&(de(n,t,e),Ql(n,t,e))}function Bg(t,e){if(t=t.memoizedState,t!==null&&t.dehydrated!==null){var n=t.retryLane;t.retryLane=n!==0&&n<e?n:e}}function Sd(t,e){Bg(t,e),(t=t.alternate)&&Bg(t,e)}function wy(t){if(t.tag===13||t.tag===31){var e=Ko(t,67108864);e!==null&&de(e,t,67108864),Sd(t,67108864)}}function kg(t){if(t.tag===13||t.tag===31){var e=we();e=Df(e);var n=Ko(t,e);n!==null&&de(n,t,e),Sd(t,e)}}var fu=!0;function $E(t,e,n,o){var a=F.T;F.T=null;var l=ft.p;try{ft.p=2,_d(t,e,n,o)}finally{ft.p=l,F.T=a}}function JE(t,e,n,o){var a=F.T;F.T=null;var l=ft.p;try{ft.p=8,_d(t,e,n,o)}finally{ft.p=l,F.T=a}}function _d(t,e,n,o){if(fu){var a=zf(o);if(a===null)Ts(t,e,o,du,n),Lg(t,o);else if(WE(a,t,e,n,o))o.stopPropagation();else if(Lg(t,o),e&4&&-1<IE.indexOf(t)){for(;a!==null;){var l=el(a);if(l!==null)switch(l.tag){case 3:if(l=l.stateNode,l.current.memoizedState.isDehydrated){var i=Oo(l.pendingLanes);if(i!==0){var r=l;for(r.pendingLanes|=2,r.entangledLanes|=2;i;){var u=1<<31-_e(i);r.entanglements[1]|=u,i&=~u}an(l),(st&6)===0&&(eu=xe()+500,wi(0,!1))}}break;case 31:case 13:r=Ko(l,2),r!==null&&de(r,l,2),Nu(),Sd(l,2)}if(l=zf(o),l===null&&Ts(t,e,o,du,n),l===a)break;a=l}a!==null&&o.stopPropagation()}else Ts(t,e,o,null,n)}}function zf(t){return t=kf(t),wd(t)}var du=null;function wd(t){if(du=null,t=Ma(t),t!==null){var e=pi(t);if(e===null)t=null;else{var n=e.tag;if(n===13){if(t=Zg(e),t!==null)return t;t=null}else if(n===31){if(t=Gg(e),t!==null)return t;t=null}else if(n===3){if(e.stateNode.current.memoizedState.isDehydrated)return e.tag===3?e.stateNode.containerInfo:null;t=null}else e!==t&&(t=null)}}return du=t,null}function Ey(t){switch(t){case"beforetoggle":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"toggle":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 2;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"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 8;case"message":switch(L_()){case $g:return 2;case Jg:return 8;case qr:case U_:return 32;case Ig:return 268435456;default:return 32}default:return 32}}var Af=!1,lo=null,io=null,ro=null,di=new Map,hi=new Map,Kn=[],IE="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".split(" ");function Lg(t,e){switch(t){case"focusin":case"focusout":lo=null;break;case"dragenter":case"dragleave":io=null;break;case"mouseover":case"mouseout":ro=null;break;case"pointerover":case"pointerout":di.delete(e.pointerId);break;case"gotpointercapture":case"lostpointercapture":hi.delete(e.pointerId)}}function Rl(t,e,n,o,a,l){return t===null||t.nativeEvent!==l?(t={blockedOn:e,domEventName:n,eventSystemFlags:o,nativeEvent:l,targetContainers:[a]},e!==null&&(e=el(e),e!==null&&wy(e)),t):(t.eventSystemFlags|=o,e=t.targetContainers,a!==null&&e.indexOf(a)===-1&&e.push(a),t)}function WE(t,e,n,o,a){switch(e){case"focusin":return lo=Rl(lo,t,e,n,o,a),!0;case"dragenter":return io=Rl(io,t,e,n,o,a),!0;case"mouseover":return ro=Rl(ro,t,e,n,o,a),!0;case"pointerover":var l=a.pointerId;return di.set(l,Rl(di.get(l)||null,t,e,n,o,a)),!0;case"gotpointercapture":return l=a.pointerId,hi.set(l,Rl(hi.get(l)||null,t,e,n,o,a)),!0}return!1}function Ny(t){var e=Ma(t.target);if(e!==null){var n=pi(e);if(n!==null){if(e=n.tag,e===13){if(e=Zg(n),e!==null){t.blockedOn=e,xp(t.priority,function(){kg(n)});return}}else if(e===31){if(e=Gg(n),e!==null){t.blockedOn=e,xp(t.priority,function(){kg(n)});return}}else if(e===3&&n.stateNode.current.memoizedState.isDehydrated){t.blockedOn=n.tag===3?n.stateNode.containerInfo:null;return}}}t.blockedOn=null}function Lr(t){if(t.blockedOn!==null)return!1;for(var e=t.targetContainers;0<e.length;){var n=zf(t.nativeEvent);if(n===null){n=t.nativeEvent;var o=new n.constructor(n.type,n);Qs=o,n.target.dispatchEvent(o),Qs=null}else return e=el(n),e!==null&&wy(e),t.blockedOn=n,!1;e.shift()}return!0}function Ug(t,e,n){Lr(t)&&n.delete(e)}function FE(){Af=!1,lo!==null&&Lr(lo)&&(lo=null),io!==null&&Lr(io)&&(io=null),ro!==null&&Lr(ro)&&(ro=null),di.forEach(Ug),hi.forEach(Ug)}function Sr(t,e){t.blockedOn===e&&(t.blockedOn=null,Af||(Af=!0,Vt.unstable_scheduleCallback(Vt.unstable_NormalPriority,FE)))}var _r=null;function Yg(t){_r!==t&&(_r=t,Vt.unstable_scheduleCallback(Vt.unstable_NormalPriority,function(){_r===t&&(_r=null);for(var e=0;e<t.length;e+=3){var n=t[e],o=t[e+1],a=t[e+2];if(typeof o!="function"){if(wd(o||n)===null)continue;break}var l=el(n);l!==null&&(t.splice(e,3),e-=3,uf(l,{pending:!0,data:a,method:n.method,action:o},o,a))}}))}function Pa(t){function e(u){return Sr(u,t)}lo!==null&&Sr(lo,t),io!==null&&Sr(io,t),ro!==null&&Sr(ro,t),di.forEach(e),hi.forEach(e);for(var n=0;n<Kn.length;n++){var o=Kn[n];o.blockedOn===t&&(o.blockedOn=null)}for(;0<Kn.length&&(n=Kn[0],n.blockedOn===null);)Ny(n),n.blockedOn===null&&Kn.shift();if(n=(t.ownerDocument||t).$$reactFormReplay,n!=null)for(o=0;o<n.length;o+=3){var a=n[o],l=n[o+1],i=a[he]||null;if(typeof l=="function")i||Yg(n);else if(i){var r=null;if(l&&l.hasAttribute("formAction")){if(a=l,i=l[he]||null)r=i.formAction;else if(wd(a)!==null)continue}else r=i.action;typeof r=="function"?n[o+1]=r:(n.splice(o,3),o-=3),Yg(n)}}}function My(){function t(l){l.canIntercept&&l.info==="react-transition"&&l.intercept({handler:function(){return new Promise(function(i){return a=i})},focusReset:"manual",scroll:"manual"})}function e(){a!==null&&(a(),a=null),o||setTimeout(n,20)}function n(){if(!o&&!navigation.transition){var l=navigation.currentEntry;l&&l.url!=null&&navigation.navigate(l.url,{state:l.getState(),info:"react-transition",history:"replace"})}}if(typeof navigation=="object"){var o=!1,a=null;return navigation.addEventListener("navigate",t),navigation.addEventListener("navigatesuccess",e),navigation.addEventListener("navigateerror",e),setTimeout(n,100),function(){o=!0,navigation.removeEventListener("navigate",t),navigation.removeEventListener("navigatesuccess",e),navigation.removeEventListener("navigateerror",e),a!==null&&(a(),a=null)}}}function Ed(t){this._internalRoot=t}Au.prototype.render=Ed.prototype.render=function(t){var e=this._internalRoot;if(e===null)throw Error(L(409));var n=e.current,o=we();_y(n,o,t,e,null,null)};Au.prototype.unmount=Ed.prototype.unmount=function(){var t=this._internalRoot;if(t!==null){this._internalRoot=null;var e=t.containerInfo;_y(t.current,2,null,t,null,null),Nu(),e[tl]=null}};function Au(t){this._internalRoot=t}Au.prototype.unstable_scheduleHydration=function(t){if(t){var e=em();t={blockedOn:null,target:t,priority:e};for(var n=0;n<Kn.length&&e!==0&&e<Kn[n].priority;n++);Kn.splice(n,0,t),n===0&&Ny(t)}};var Vg=qg.version;if(Vg!=="19.2.7")throw Error(L(527,Vg,"19.2.7"));ft.findDOMNode=function(t){var e=t._reactInternals;if(e===void 0)throw typeof t.render=="function"?Error(L(188)):(t=Object.keys(t).join(","),Error(L(268,t)));return t=T_(e),t=t!==null?Qg(t):null,t=t===null?null:t.stateNode,t};var PE={bundleType:0,version:"19.2.7",rendererPackageName:"react-dom",currentDispatcherRef:F,reconcilerVersion:"19.2.7"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&(Bl=__REACT_DEVTOOLS_GLOBAL_HOOK__,!Bl.isDisabled&&Bl.supportsFiber))try{gi=Bl.inject(PE),Se=Bl}catch{}var Bl;Cu.createRoot=function(t,e){if(!Xg(t))throw Error(L(299));var n=!1,o="",a=y0,l=v0,i=b0;return e!=null&&(e.unstable_strictMode===!0&&(n=!0),e.identifierPrefix!==void 0&&(o=e.identifierPrefix),e.onUncaughtError!==void 0&&(a=e.onUncaughtError),e.onCaughtError!==void 0&&(l=e.onCaughtError),e.onRecoverableError!==void 0&&(i=e.onRecoverableError)),e=xy(t,1,!1,null,null,n,o,null,a,l,i,My),t[tl]=e.current,vd(t),new Ed(e)};Cu.hydrateRoot=function(t,e,n){if(!Xg(t))throw Error(L(299));var o=!1,a="",l=y0,i=v0,r=b0,u=null;return n!=null&&(n.unstable_strictMode===!0&&(o=!0),n.identifierPrefix!==void 0&&(a=n.identifierPrefix),n.onUncaughtError!==void 0&&(l=n.onUncaughtError),n.onCaughtError!==void 0&&(i=n.onCaughtError),n.onRecoverableError!==void 0&&(r=n.onRecoverableError),n.formState!==void 0&&(u=n.formState)),e=xy(t,1,!0,e,n??null,o,a,u,l,i,r,My),e.context=Sy(null),n=e.current,o=we(),o=Df(o),a=eo(o),a.callback=null,no(n,a,o),n=o,e.current.lanes=n,yi(e,n),an(e),t[tl]=e.current,vd(t),new Au(e)};Cu.version="19.2.7"});var Ty=re((mC,Cy)=>{"use strict";function Ay(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(Ay)}catch(t){console.error(t)}}Ay(),Cy.exports=zy()});var Gy=re(Ru=>{"use strict";var g2=Symbol.for("react.transitional.element"),m2=Symbol.for("react.fragment");function Zy(t,e,n){var o=null;if(n!==void 0&&(o=""+n),e.key!==void 0&&(o=""+e.key),"key"in e){n={};for(var a in e)a!=="key"&&(n[a]=e[a])}else n=e;return e=n.ref,{$$typeof:g2,type:t,key:o,ref:e!==void 0?e:null,props:n}}Ru.Fragment=m2;Ru.jsx=Zy;Ru.jsxs=Zy});var Bu=re((EC,Qy)=>{"use strict";Qy.exports=Gy()});var Ab=re(zb=>{"use strict";var Sl=hn();function sz(t,e){return t===e&&(t!==0||1/t===1/e)||t!==t&&e!==e}var fz=typeof Object.is=="function"?Object.is:sz,dz=Sl.useState,hz=Sl.useEffect,pz=Sl.useLayoutEffect,gz=Sl.useDebugValue;function mz(t,e){var n=e(),o=dz({inst:{value:n,getSnapshot:e}}),a=o[0].inst,l=o[1];return pz(function(){a.value=n,a.getSnapshot=e,Mh(a)&&l({inst:a})},[t,n,e]),hz(function(){return Mh(a)&&l({inst:a}),t(function(){Mh(a)&&l({inst:a})})},[t]),gz(n),n}function Mh(t){var e=t.getSnapshot;t=t.value;try{var n=e();return!fz(t,n)}catch{return!0}}function yz(t,e){return e()}var vz=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?yz:mz;zb.useSyncExternalStore=Sl.useSyncExternalStore!==void 0?Sl.useSyncExternalStore:vz});var Tb=re((y6,Cb)=>{"use strict";Cb.exports=Ab()});var Db=re(Ob=>{"use strict";var zc=hn(),bz=Tb();function xz(t,e){return t===e&&(t!==0||1/t===1/e)||t!==t&&e!==e}var Sz=typeof Object.is=="function"?Object.is:xz,_z=bz.useSyncExternalStore,wz=zc.useRef,Ez=zc.useEffect,Nz=zc.useMemo,Mz=zc.useDebugValue;Ob.useSyncExternalStoreWithSelector=function(t,e,n,o,a){var l=wz(null);if(l.current===null){var i={hasValue:!1,value:null};l.current=i}else i=l.current;l=Nz(function(){function u(p){if(!s){if(s=!0,c=p,p=o(p),a!==void 0&&i.hasValue){var y=i.value;if(a(y,p))return d=y}return d=p}if(y=d,Sz(c,p))return y;var b=o(p);return a!==void 0&&a(y,b)?(c=p,y):(c=p,d=b)}var s=!1,c,d,f=n===void 0?null:n;return[function(){return u(e())},f===null?void 0:function(){return u(f())}]},[e,n,o,a]);var r=_z(t,l[0],l[1]);return Ez(function(){i.hasValue=!0,i.value=r},[r]),Mz(r),r}});var Rb=re((b6,Hb)=>{"use strict";Hb.exports=Db()});var pa=We(hn(),1),Fx=We(Ty(),1);var t2=Symbol(),zd=Symbol(),Mi="a",Dy="f",Oy="p",Hy="c",Ry="t",Ad="h",zi="w",Cd="o",Td="k",e2=(t,e)=>new Proxy(t,e),Nd=Object.getPrototypeOf,Md=new WeakMap,By=t=>t&&(Md.has(t)?Md.get(t):Nd(t)===Object.prototype||Nd(t)===Array.prototype),Tu=t=>typeof t=="object"&&t!==null,n2=t=>Object.values(Object.getOwnPropertyDescriptors(t)).some(e=>!e.configurable&&!e.writable),o2=t=>{if(Array.isArray(t))return Array.from(t);let e=Object.getOwnPropertyDescriptors(t);return Object.values(e).forEach(n=>{n.configurable=!0}),Object.create(Nd(t),e)},a2=(t,e)=>{let n={[Dy]:e},o=!1,a=(r,u)=>{if(!o){let s=n[Mi].get(t);if(s||(s={},n[Mi].set(t,s)),r===zi)s[zi]=!0;else{let c=s[r];c||(c=new Set,s[r]=c),c.add(u)}}},l=()=>{o=!0,n[Mi].delete(t)},i={get(r,u){return u===zd?t:(a(Td,u),Dd(Reflect.get(r,u),n[Mi],n[Hy],n[Ry]))},has(r,u){return u===t2?(l(),!0):(a(Ad,u),Reflect.has(r,u))},getOwnPropertyDescriptor(r,u){return a(Cd,u),Reflect.getOwnPropertyDescriptor(r,u)},ownKeys(r){return a(zi),Reflect.ownKeys(r)}};return e&&(i.set=i.deleteProperty=()=>!1),[i,n]},Od=t=>t[zd]||t,Dd=(t,e,n,o)=>{if(!By(t))return t;let a=o&&o.get(t);if(!a){let u=Od(t);n2(u)?a=[u,o2(u)]:a=[u],o?.set(t,a)}let[l,i]=a,r=n&&n.get(l);return(!r||r[1][Dy]!==!!i)&&(r=a2(l,!!i),r[1][Oy]=e2(i||l,r[0]),n&&n.set(l,r)),r[1][Mi]=e,r[1][Hy]=n,r[1][Ry]=o,r[1][Oy]},l2=(t,e)=>{let n=Reflect.ownKeys(t),o=Reflect.ownKeys(e);return n.length!==o.length||n.some((a,l)=>a!==o[l])},Hd=(t,e,n,o,a=Object.is)=>{if(a(t,e))return!1;if(!Tu(t)||!Tu(e))return!0;let l=n.get(Od(t));if(!l)return!0;if(o){if(o.get(t)===e)return!1;o.set(t,e)}let i=null;for(let r of l[Ad]||[])if(i=Reflect.has(t,r)!==Reflect.has(e,r),i)return i;if(l[zi]===!0){if(i=l2(t,e),i)return i}else for(let r of l[Cd]||[]){let u=!!Reflect.getOwnPropertyDescriptor(t,r),s=!!Reflect.getOwnPropertyDescriptor(e,r);if(i=u!==s,i)return i}for(let r of l[Td]||[])if(i=Hd(t[r],e[r],n,o,a),i)return i;if(i===null)throw new Error("invalid used");return i};var ky=t=>By(t)&&t[zd]||null,Rd=(t,e=!0)=>{Md.set(t,e)},Ly=(t,e,n)=>{let o=[],a=new WeakSet,l=(i,r)=>{var u,s,c;if(a.has(i))return;Tu(i)&&a.add(i);let d=Tu(i)&&e.get(Od(i));if(d){if((u=d[Ad])===null||u===void 0||u.forEach(f=>{let p=`:has(${String(f)})`;o.push(r?[...r,p]:[p])}),d[zi]===!0){let f=":ownKeys";o.push(r?[...r,f]:[f])}else(s=d[Cd])===null||s===void 0||s.forEach(f=>{let p=`:hasOwn(${String(f)})`;o.push(r?[...r,p]:[p])});(c=d[Td])===null||c===void 0||c.forEach(f=>{(!n||"value"in(Object.getOwnPropertyDescriptor(i,f)||{}))&&l(i[f],r?[...r,f]:[f])})}else r&&o.push(r)};return l(t),o};var go={},kd=t=>typeof t=="object"&&t!==null,i2=t=>kd(t)&&!Ld.has(t)&&(Array.isArray(t)||!(Symbol.iterator in t))&&!(t instanceof WeakMap)&&!(t instanceof WeakSet)&&!(t instanceof Error)&&!(t instanceof Number)&&!(t instanceof Date)&&!(t instanceof String)&&!(t instanceof RegExp)&&!(t instanceof ArrayBuffer)&&!(t instanceof Promise),Vy=(t,e)=>{let n=Uy.get(t);if(n?.[0]===e)return n[1];let o=Array.isArray(t)?[]:Object.create(Object.getPrototypeOf(t));return Rd(o,!0),Uy.set(t,[e,o]),Reflect.ownKeys(t).forEach(a=>{if(Object.getOwnPropertyDescriptor(o,a))return;let l=Reflect.get(t,a),{enumerable:i}=Reflect.getOwnPropertyDescriptor(t,a),r={value:l,enumerable:i,configurable:!0};if(Ld.has(l))Rd(l,!1);else if(Jo.has(l)){let[u,s]=Jo.get(l);r.value=Vy(u,s())}Object.defineProperty(o,a,r)}),o},r2=(t,e,n,o)=>({deleteProperty(a,l){let i=Reflect.get(a,l);n(l);let r=Reflect.deleteProperty(a,l);return r&&o(Ou?.("delete",l,i)),r},set(a,l,i,r){let u=!t()&&Reflect.has(a,l),s=Reflect.get(a,l,r);if(u&&(Yy(s,i)||Du.has(i)&&Yy(s,Du.get(i))))return!0;n(l),kd(i)&&(i=ky(i)||i);let c=!Jo.has(i)&&c2(i)?Hu(i):i;return e(l,c),Reflect.set(a,l,c,r),o(Ou?.("set",l,i,s)),!0}});var Jo=new WeakMap,Ld=new WeakSet,Uy=new WeakMap,Bd=[1],Du=new WeakMap,Yy=Object.is,u2=(t,e)=>new Proxy(t,e),c2=i2,s2=Vy,f2=r2,Ou;function Hu(t={}){if(!kd(t))throw new Error("object required");let e=Du.get(t);if(e)return e;let n=Bd[0],o=new Set,a=(x,g=++Bd[0])=>{n!==g&&(l=n=g,o.forEach(m=>m(x,g)))},l=n,i=(x=Bd[0])=>(l!==x&&(l=x,u.forEach(([g])=>{let m=g[1](x);m>n&&(n=m)})),n),r=x=>(g,m)=>{let h;g&&(h=[...g],h[1]=[x,...h[1]]),a(h,m)},u=new Map,s=(x,g)=>{let m=!Ld.has(g)&&Jo.get(g);if(m){if((go.env?go.env.MODE:void 0)!=="production"&&u.has(x))throw new Error("prop listener already exists");if(o.size){let h=m[2](r(x));u.set(x,[m,h])}else u.set(x,[m])}},c=x=>{var g;let m=u.get(x);m&&(u.delete(x),(g=m[1])==null||g.call(m))},d=x=>(o.add(x),o.size===1&&u.forEach(([m,h],v)=>{if((go.env?go.env.MODE:void 0)!=="production"&&h)throw new Error("remove already exists");let _=m[2](r(v));u.set(v,[m,_])}),()=>{o.delete(x),o.size===0&&u.forEach(([m,h],v)=>{h&&(h(),u.set(v,[m]))})}),f=!0,p=f2(()=>f,s,c,a),y=u2(t,p);Du.set(t,y);let b=[t,i,d];return Jo.set(y,b),Reflect.ownKeys(t).forEach(x=>{let g=Object.getOwnPropertyDescriptor(t,x);"value"in g&&g.writable&&(y[x]=t[x])}),f=!1,y}function qy(t,e,n){let o=Jo.get(t);(go.env?go.env.MODE:void 0)!=="production"&&!o&&console.warn("Please use proxy object");let a,l=[],i=o[2],r=!1,s=i(c=>{if(c&&l.push(c),n){e(l.splice(0));return}a||(a=Promise.resolve().then(()=>{a=void 0,r&&e(l.splice(0))}))});return r=!0,()=>{r=!1,s()}}function Ud(t){let e=Jo.get(t);(go.env?go.env.MODE:void 0)!=="production"&&!e&&console.warn("Please use proxy object");let[n,o]=e;return s2(n,o())}var Pt=We(hn(),1);var Xy={},d2=(t,e)=>{let n=(0,Pt.useRef)(void 0);(0,Pt.useEffect)(()=>{n.current=Ly(t,e,!0)}),(0,Pt.useDebugValue)(n.current)},h2=d2,p2=new WeakMap;function Ue(t,e){let n=e?.sync,o=(0,Pt.useMemo)(()=>t&&new WeakMap,[t]),a=(0,Pt.useRef)(void 0),l=!0,i=(0,Pt.useSyncExternalStore)((0,Pt.useCallback)(u=>{let s=qy(t,u,n);return u(),s},[t,n]),()=>{let u=Ud(t);try{if(!l&&a.current&&!Hd(a.current,u,o,new WeakMap))return a.current}catch{}return u},()=>Ud(t));l=!1,(0,Pt.useLayoutEffect)(()=>{a.current=i}),(Xy.env?Xy.env.MODE:void 0)!=="production"&&h2(i,o);let r=(0,Pt.useMemo)(()=>new WeakMap,[]);return Dd(i,o,r,p2)}var O=We(Bu()),D=We(hn());function Tt(t){if(typeof t=="string"||typeof t=="number")return""+t;let e="";if(Array.isArray(t))for(let n=0,o;n<t.length;n++)(o=Tt(t[n]))!==""&&(e+=(e&&" ")+o);else for(let n in t)t[n]&&(e+=(e&&" ")+n);return e}var y2={value:()=>{}};function Ky(){for(var t=0,e=arguments.length,n={},o;t<e;++t){if(!(o=arguments[t]+"")||o in n||/[\s.]/.test(o))throw new Error("illegal type: "+o);n[o]=[]}return new ku(n)}function ku(t){this._=t}function v2(t,e){return t.trim().split(/^|\s+/).map(function(n){var o="",a=n.indexOf(".");if(a>=0&&(o=n.slice(a+1),n=n.slice(0,a)),n&&!e.hasOwnProperty(n))throw new Error("unknown type: "+n);return{type:n,name:o}})}ku.prototype=Ky.prototype={constructor:ku,on:function(t,e){var n=this._,o=v2(t+"",n),a,l=-1,i=o.length;if(arguments.length<2){for(;++l<i;)if((a=(t=o[l]).type)&&(a=b2(n[a],t.name)))return a;return}if(e!=null&&typeof e!="function")throw new Error("invalid callback: "+e);for(;++l<i;)if(a=(t=o[l]).type)n[a]=jy(n[a],t.name,e);else if(e==null)for(a in n)n[a]=jy(n[a],t.name,null);return this},copy:function(){var t={},e=this._;for(var n in e)t[n]=e[n].slice();return new ku(t)},call:function(t,e){if((a=arguments.length-2)>0)for(var n=new Array(a),o=0,a,l;o<a;++o)n[o]=arguments[o+2];if(!this._.hasOwnProperty(t))throw new Error("unknown type: "+t);for(l=this._[t],o=0,a=l.length;o<a;++o)l[o].value.apply(e,n)},apply:function(t,e,n){if(!this._.hasOwnProperty(t))throw new Error("unknown type: "+t);for(var o=this._[t],a=0,l=o.length;a<l;++a)o[a].value.apply(e,n)}};function b2(t,e){for(var n=0,o=t.length,a;n<o;++n)if((a=t[n]).name===e)return a.value}function jy(t,e,n){for(var o=0,a=t.length;o<a;++o)if(t[o].name===e){t[o]=y2,t=t.slice(0,o).concat(t.slice(o+1));break}return n!=null&&t.push({name:e,value:n}),t}var Io=Ky;var Lu="http://www.w3.org/1999/xhtml",Yd={svg:"http://www.w3.org/2000/svg",xhtml:Lu,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};function Rn(t){var e=t+="",n=e.indexOf(":");return n>=0&&(e=t.slice(0,n))!=="xmlns"&&(t=t.slice(n+1)),Yd.hasOwnProperty(e)?{space:Yd[e],local:t}:t}function x2(t){return function(){var e=this.ownerDocument,n=this.namespaceURI;return n===Lu&&e.documentElement.namespaceURI===Lu?e.createElement(t):e.createElementNS(n,t)}}function S2(t){return function(){return this.ownerDocument.createElementNS(t.space,t.local)}}function Uu(t){var e=Rn(t);return(e.local?S2:x2)(e)}function _2(){}function Wo(t){return t==null?_2:function(){return this.querySelector(t)}}function $y(t){typeof t!="function"&&(t=Wo(t));for(var e=this._groups,n=e.length,o=new Array(n),a=0;a<n;++a)for(var l=e[a],i=l.length,r=o[a]=new Array(i),u,s,c=0;c<i;++c)(u=l[c])&&(s=t.call(u,u.__data__,c,l))&&("__data__"in u&&(s.__data__=u.__data__),r[c]=s);return new Ot(o,this._parents)}function Vd(t){return t==null?[]:Array.isArray(t)?t:Array.from(t)}function w2(){return[]}function Ai(t){return t==null?w2:function(){return this.querySelectorAll(t)}}function E2(t){return function(){return Vd(t.apply(this,arguments))}}function Jy(t){typeof t=="function"?t=E2(t):t=Ai(t);for(var e=this._groups,n=e.length,o=[],a=[],l=0;l<n;++l)for(var i=e[l],r=i.length,u,s=0;s<r;++s)(u=i[s])&&(o.push(t.call(u,u.__data__,s,i)),a.push(u));return new Ot(o,a)}function Ci(t){return function(){return this.matches(t)}}function Yu(t){return function(e){return e.matches(t)}}var N2=Array.prototype.find;function M2(t){return function(){return N2.call(this.children,t)}}function z2(){return this.firstElementChild}function Iy(t){return this.select(t==null?z2:M2(typeof t=="function"?t:Yu(t)))}var A2=Array.prototype.filter;function C2(){return Array.from(this.children)}function T2(t){return function(){return A2.call(this.children,t)}}function Wy(t){return this.selectAll(t==null?C2:T2(typeof t=="function"?t:Yu(t)))}function Fy(t){typeof t!="function"&&(t=Ci(t));for(var e=this._groups,n=e.length,o=new Array(n),a=0;a<n;++a)for(var l=e[a],i=l.length,r=o[a]=[],u,s=0;s<i;++s)(u=l[s])&&t.call(u,u.__data__,s,l)&&r.push(u);return new Ot(o,this._parents)}function Vu(t){return new Array(t.length)}function Py(){return new Ot(this._enter||this._groups.map(Vu),this._parents)}function Ti(t,e){this.ownerDocument=t.ownerDocument,this.namespaceURI=t.namespaceURI,this._next=null,this._parent=t,this.__data__=e}Ti.prototype={constructor:Ti,appendChild:function(t){return this._parent.insertBefore(t,this._next)},insertBefore:function(t,e){return this._parent.insertBefore(t,e)},querySelector:function(t){return this._parent.querySelector(t)},querySelectorAll:function(t){return this._parent.querySelectorAll(t)}};function tv(t){return function(){return t}}function O2(t,e,n,o,a,l){for(var i=0,r,u=e.length,s=l.length;i<s;++i)(r=e[i])?(r.__data__=l[i],o[i]=r):n[i]=new Ti(t,l[i]);for(;i<u;++i)(r=e[i])&&(a[i]=r)}function D2(t,e,n,o,a,l,i){var r,u,s=new Map,c=e.length,d=l.length,f=new Array(c),p;for(r=0;r<c;++r)(u=e[r])&&(f[r]=p=i.call(u,u.__data__,r,e)+"",s.has(p)?a[r]=u:s.set(p,u));for(r=0;r<d;++r)p=i.call(t,l[r],r,l)+"",(u=s.get(p))?(o[r]=u,u.__data__=l[r],s.delete(p)):n[r]=new Ti(t,l[r]);for(r=0;r<c;++r)(u=e[r])&&s.get(f[r])===u&&(a[r]=u)}function H2(t){return t.__data__}function ev(t,e){if(!arguments.length)return Array.from(this,H2);var n=e?D2:O2,o=this._parents,a=this._groups;typeof t!="function"&&(t=tv(t));for(var l=a.length,i=new Array(l),r=new Array(l),u=new Array(l),s=0;s<l;++s){var c=o[s],d=a[s],f=d.length,p=R2(t.call(c,c&&c.__data__,s,o)),y=p.length,b=r[s]=new Array(y),x=i[s]=new Array(y),g=u[s]=new Array(f);n(c,d,b,x,g,p,e);for(var m=0,h=0,v,_;m<y;++m)if(v=b[m]){for(m>=h&&(h=m+1);!(_=x[h])&&++h<y;);v._next=_||null}}return i=new Ot(i,o),i._enter=r,i._exit=u,i}function R2(t){return typeof t=="object"&&"length"in t?t:Array.from(t)}function nv(){return new Ot(this._exit||this._groups.map(Vu),this._parents)}function ov(t,e,n){var o=this.enter(),a=this,l=this.exit();return typeof t=="function"?(o=t(o),o&&(o=o.selection())):o=o.append(t+""),e!=null&&(a=e(a),a&&(a=a.selection())),n==null?l.remove():n(l),o&&a?o.merge(a).order():a}function av(t){for(var e=t.selection?t.selection():t,n=this._groups,o=e._groups,a=n.length,l=o.length,i=Math.min(a,l),r=new Array(a),u=0;u<i;++u)for(var s=n[u],c=o[u],d=s.length,f=r[u]=new Array(d),p,y=0;y<d;++y)(p=s[y]||c[y])&&(f[y]=p);for(;u<a;++u)r[u]=n[u];return new Ot(r,this._parents)}function lv(){for(var t=this._groups,e=-1,n=t.length;++e<n;)for(var o=t[e],a=o.length-1,l=o[a],i;--a>=0;)(i=o[a])&&(l&&i.compareDocumentPosition(l)^4&&l.parentNode.insertBefore(i,l),l=i);return this}function iv(t){t||(t=B2);function e(d,f){return d&&f?t(d.__data__,f.__data__):!d-!f}for(var n=this._groups,o=n.length,a=new Array(o),l=0;l<o;++l){for(var i=n[l],r=i.length,u=a[l]=new Array(r),s,c=0;c<r;++c)(s=i[c])&&(u[c]=s);u.sort(e)}return new Ot(a,this._parents).order()}function B2(t,e){return t<e?-1:t>e?1:t>=e?0:NaN}function rv(){var t=arguments[0];return arguments[0]=this,t.apply(null,arguments),this}function uv(){return Array.from(this)}function cv(){for(var t=this._groups,e=0,n=t.length;e<n;++e)for(var o=t[e],a=0,l=o.length;a<l;++a){var i=o[a];if(i)return i}return null}function sv(){let t=0;for(let e of this)++t;return t}function fv(){return!this.node()}function dv(t){for(var e=this._groups,n=0,o=e.length;n<o;++n)for(var a=e[n],l=0,i=a.length,r;l<i;++l)(r=a[l])&&t.call(r,r.__data__,l,a);return this}function k2(t){return function(){this.removeAttribute(t)}}function L2(t){return function(){this.removeAttributeNS(t.space,t.local)}}function U2(t,e){return function(){this.setAttribute(t,e)}}function Y2(t,e){return function(){this.setAttributeNS(t.space,t.local,e)}}function V2(t,e){return function(){var n=e.apply(this,arguments);n==null?this.removeAttribute(t):this.setAttribute(t,n)}}function q2(t,e){return function(){var n=e.apply(this,arguments);n==null?this.removeAttributeNS(t.space,t.local):this.setAttributeNS(t.space,t.local,n)}}function hv(t,e){var n=Rn(t);if(arguments.length<2){var o=this.node();return n.local?o.getAttributeNS(n.space,n.local):o.getAttribute(n)}return this.each((e==null?n.local?L2:k2:typeof e=="function"?n.local?q2:V2:n.local?Y2:U2)(n,e))}function qu(t){return t.ownerDocument&&t.ownerDocument.defaultView||t.document&&t||t.defaultView}function X2(t){return function(){this.style.removeProperty(t)}}function Z2(t,e,n){return function(){this.style.setProperty(t,e,n)}}function G2(t,e,n){return function(){var o=e.apply(this,arguments);o==null?this.style.removeProperty(t):this.style.setProperty(t,o,n)}}function pv(t,e,n){return arguments.length>1?this.each((e==null?X2:typeof e=="function"?G2:Z2)(t,e,n??"")):mo(this.node(),t)}function mo(t,e){return t.style.getPropertyValue(e)||qu(t).getComputedStyle(t,null).getPropertyValue(e)}function Q2(t){return function(){delete this[t]}}function j2(t,e){return function(){this[t]=e}}function K2(t,e){return function(){var n=e.apply(this,arguments);n==null?delete this[t]:this[t]=n}}function gv(t,e){return arguments.length>1?this.each((e==null?Q2:typeof e=="function"?K2:j2)(t,e)):this.node()[t]}function mv(t){return t.trim().split(/^|\s+/)}function qd(t){return t.classList||new yv(t)}function yv(t){this._node=t,this._names=mv(t.getAttribute("class")||"")}yv.prototype={add:function(t){var e=this._names.indexOf(t);e<0&&(this._names.push(t),this._node.setAttribute("class",this._names.join(" ")))},remove:function(t){var e=this._names.indexOf(t);e>=0&&(this._names.splice(e,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(t){return this._names.indexOf(t)>=0}};function vv(t,e){for(var n=qd(t),o=-1,a=e.length;++o<a;)n.add(e[o])}function bv(t,e){for(var n=qd(t),o=-1,a=e.length;++o<a;)n.remove(e[o])}function $2(t){return function(){vv(this,t)}}function J2(t){return function(){bv(this,t)}}function I2(t,e){return function(){(e.apply(this,arguments)?vv:bv)(this,t)}}function xv(t,e){var n=mv(t+"");if(arguments.length<2){for(var o=qd(this.node()),a=-1,l=n.length;++a<l;)if(!o.contains(n[a]))return!1;return!0}return this.each((typeof e=="function"?I2:e?$2:J2)(n,e))}function W2(){this.textContent=""}function F2(t){return function(){this.textContent=t}}function P2(t){return function(){var e=t.apply(this,arguments);this.textContent=e??""}}function Sv(t){return arguments.length?this.each(t==null?W2:(typeof t=="function"?P2:F2)(t)):this.node().textContent}function tN(){this.innerHTML=""}function eN(t){return function(){this.innerHTML=t}}function nN(t){return function(){var e=t.apply(this,arguments);this.innerHTML=e??""}}function _v(t){return arguments.length?this.each(t==null?tN:(typeof t=="function"?nN:eN)(t)):this.node().innerHTML}function oN(){this.nextSibling&&this.parentNode.appendChild(this)}function wv(){return this.each(oN)}function aN(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}function Ev(){return this.each(aN)}function Nv(t){var e=typeof t=="function"?t:Uu(t);return this.select(function(){return this.appendChild(e.apply(this,arguments))})}function lN(){return null}function Mv(t,e){var n=typeof t=="function"?t:Uu(t),o=e==null?lN:typeof e=="function"?e:Wo(e);return this.select(function(){return this.insertBefore(n.apply(this,arguments),o.apply(this,arguments)||null)})}function iN(){var t=this.parentNode;t&&t.removeChild(this)}function zv(){return this.each(iN)}function rN(){var t=this.cloneNode(!1),e=this.parentNode;return e?e.insertBefore(t,this.nextSibling):t}function uN(){var t=this.cloneNode(!0),e=this.parentNode;return e?e.insertBefore(t,this.nextSibling):t}function Av(t){return this.select(t?uN:rN)}function Cv(t){return arguments.length?this.property("__data__",t):this.node().__data__}function cN(t){return function(e){t.call(this,e,this.__data__)}}function sN(t){return t.trim().split(/^|\s+/).map(function(e){var n="",o=e.indexOf(".");return o>=0&&(n=e.slice(o+1),e=e.slice(0,o)),{type:e,name:n}})}function fN(t){return function(){var e=this.__on;if(e){for(var n=0,o=-1,a=e.length,l;n<a;++n)l=e[n],(!t.type||l.type===t.type)&&l.name===t.name?this.removeEventListener(l.type,l.listener,l.options):e[++o]=l;++o?e.length=o:delete this.__on}}}function dN(t,e,n){return function(){var o=this.__on,a,l=cN(e);if(o){for(var i=0,r=o.length;i<r;++i)if((a=o[i]).type===t.type&&a.name===t.name){this.removeEventListener(a.type,a.listener,a.options),this.addEventListener(a.type,a.listener=l,a.options=n),a.value=e;return}}this.addEventListener(t.type,l,n),a={type:t.type,name:t.name,value:e,listener:l,options:n},o?o.push(a):this.__on=[a]}}function Tv(t,e,n){var o=sN(t+""),a,l=o.length,i;if(arguments.length<2){var r=this.node().__on;if(r){for(var u=0,s=r.length,c;u<s;++u)for(a=0,c=r[u];a<l;++a)if((i=o[a]).type===c.type&&i.name===c.name)return c.value}return}for(r=e?dN:fN,a=0;a<l;++a)this.each(r(o[a],e,n));return this}function Ov(t,e,n){var o=qu(t),a=o.CustomEvent;typeof a=="function"?a=new a(e,n):(a=o.document.createEvent("Event"),n?(a.initEvent(e,n.bubbles,n.cancelable),a.detail=n.detail):a.initEvent(e,!1,!1)),t.dispatchEvent(a)}function hN(t,e){return function(){return Ov(this,t,e)}}function pN(t,e){return function(){return Ov(this,t,e.apply(this,arguments))}}function Dv(t,e){return this.each((typeof e=="function"?pN:hN)(t,e))}function*Hv(){for(var t=this._groups,e=0,n=t.length;e<n;++e)for(var o=t[e],a=0,l=o.length,i;a<l;++a)(i=o[a])&&(yield i)}var Xd=[null];function Ot(t,e){this._groups=t,this._parents=e}function Rv(){return new Ot([[document.documentElement]],Xd)}function gN(){return this}Ot.prototype=Rv.prototype={constructor:Ot,select:$y,selectAll:Jy,selectChild:Iy,selectChildren:Wy,filter:Fy,data:ev,enter:Py,exit:nv,join:ov,merge:av,selection:gN,order:lv,sort:iv,call:rv,nodes:uv,node:cv,size:sv,empty:fv,each:dv,attr:hv,style:pv,property:gv,classed:xv,text:Sv,html:_v,raise:wv,lower:Ev,append:Nv,insert:Mv,remove:zv,clone:Av,datum:Cv,on:Tv,dispatch:Dv,[Symbol.iterator]:Hv};var Bn=Rv;function Qt(t){return typeof t=="string"?new Ot([[document.querySelector(t)]],[document.documentElement]):new Ot([[t]],Xd)}function Bv(t){let e;for(;e=t.sourceEvent;)t=e;return t}function oe(t,e){if(t=Bv(t),e===void 0&&(e=t.currentTarget),e){var n=e.ownerSVGElement||e;if(n.createSVGPoint){var o=n.createSVGPoint();return o.x=t.clientX,o.y=t.clientY,o=o.matrixTransform(e.getScreenCTM().inverse()),[o.x,o.y]}if(e.getBoundingClientRect){var a=e.getBoundingClientRect();return[t.clientX-a.left-e.clientLeft,t.clientY-a.top-e.clientTop]}}return[t.pageX,t.pageY]}var kv={passive:!1},Fo={capture:!0,passive:!1};function Xu(t){t.stopImmediatePropagation()}function yo(t){t.preventDefault(),t.stopImmediatePropagation()}function Oi(t){var e=t.document.documentElement,n=Qt(t).on("dragstart.drag",yo,Fo);"onselectstart"in e?n.on("selectstart.drag",yo,Fo):(e.__noselect=e.style.MozUserSelect,e.style.MozUserSelect="none")}function Di(t,e){var n=t.document.documentElement,o=Qt(t).on("dragstart.drag",null);e&&(o.on("click.drag",yo,Fo),setTimeout(function(){o.on("click.drag",null)},0)),"onselectstart"in n?o.on("selectstart.drag",null):(n.style.MozUserSelect=n.__noselect,delete n.__noselect)}var Hi=t=>()=>t;function Ri(t,{sourceEvent:e,subject:n,target:o,identifier:a,active:l,x:i,y:r,dx:u,dy:s,dispatch:c}){Object.defineProperties(this,{type:{value:t,enumerable:!0,configurable:!0},sourceEvent:{value:e,enumerable:!0,configurable:!0},subject:{value:n,enumerable:!0,configurable:!0},target:{value:o,enumerable:!0,configurable:!0},identifier:{value:a,enumerable:!0,configurable:!0},active:{value:l,enumerable:!0,configurable:!0},x:{value:i,enumerable:!0,configurable:!0},y:{value:r,enumerable:!0,configurable:!0},dx:{value:u,enumerable:!0,configurable:!0},dy:{value:s,enumerable:!0,configurable:!0},_:{value:c}})}Ri.prototype.on=function(){var t=this._.on.apply(this._,arguments);return t===this._?this:t};function mN(t){return!t.ctrlKey&&!t.button}function yN(){return this.parentNode}function vN(t,e){return e??{x:t.x,y:t.y}}function bN(){return navigator.maxTouchPoints||"ontouchstart"in this}function Zu(){var t=mN,e=yN,n=vN,o=bN,a={},l=Io("start","drag","end"),i=0,r,u,s,c,d=0;function f(v){v.on("mousedown.drag",p).filter(o).on("touchstart.drag",x).on("touchmove.drag",g,kv).on("touchend.drag touchcancel.drag",m).style("touch-action","none").style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}function p(v,_){if(!(c||!t.call(this,v,_))){var E=h(this,e.call(this,v,_),v,_,"mouse");E&&(Qt(v.view).on("mousemove.drag",y,Fo).on("mouseup.drag",b,Fo),Oi(v.view),Xu(v),s=!1,r=v.clientX,u=v.clientY,E("start",v))}}function y(v){if(yo(v),!s){var _=v.clientX-r,E=v.clientY-u;s=_*_+E*E>d}a.mouse("drag",v)}function b(v){Qt(v.view).on("mousemove.drag mouseup.drag",null),Di(v.view,s),yo(v),a.mouse("end",v)}function x(v,_){if(t.call(this,v,_)){var E=v.changedTouches,w=e.call(this,v,_),N=E.length,M,R;for(M=0;M<N;++M)(R=h(this,w,v,_,E[M].identifier,E[M]))&&(Xu(v),R("start",v,E[M]))}}function g(v){var _=v.changedTouches,E=_.length,w,N;for(w=0;w<E;++w)(N=a[_[w].identifier])&&(yo(v),N("drag",v,_[w]))}function m(v){var _=v.changedTouches,E=_.length,w,N;for(c&&clearTimeout(c),c=setTimeout(function(){c=null},500),w=0;w<E;++w)(N=a[_[w].identifier])&&(Xu(v),N("end",v,_[w]))}function h(v,_,E,w,N,M){var R=l.copy(),C=oe(M||E,_),k,V,S;if((S=n.call(v,new Ri("beforestart",{sourceEvent:E,target:f,identifier:N,active:i,x:C[0],y:C[1],dx:0,dy:0,dispatch:R}),w))!=null)return k=S.x-C[0]||0,V=S.y-C[1]||0,function A(z,T,B){var H=C,X;switch(z){case"start":a[N]=A,X=i++;break;case"end":delete a[N],--i;case"drag":C=oe(B||T,_),X=i;break}R.call(z,v,new Ri(z,{sourceEvent:T,subject:S,target:f,identifier:N,active:X,x:C[0]+k,y:C[1]+V,dx:C[0]-H[0],dy:C[1]-H[1],dispatch:R}),w)}}return f.filter=function(v){return arguments.length?(t=typeof v=="function"?v:Hi(!!v),f):t},f.container=function(v){return arguments.length?(e=typeof v=="function"?v:Hi(v),f):e},f.subject=function(v){return arguments.length?(n=typeof v=="function"?v:Hi(v),f):n},f.touchable=function(v){return arguments.length?(o=typeof v=="function"?v:Hi(!!v),f):o},f.on=function(){var v=l.on.apply(l,arguments);return v===l?f:v},f.clickDistance=function(v){return arguments.length?(d=(v=+v)*v,f):Math.sqrt(d)},f}function Gu(t,e,n){t.prototype=e.prototype=n,n.constructor=t}function Zd(t,e){var n=Object.create(t.prototype);for(var o in e)n[o]=e[o];return n}function Li(){}var Bi=.7,Ku=1/Bi,rl="\\s*([+-]?\\d+)\\s*",ki="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",ln="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",xN=/^#([0-9a-f]{3,8})$/,SN=new RegExp(`^rgb\\(${rl},${rl},${rl}\\)$`),_N=new RegExp(`^rgb\\(${ln},${ln},${ln}\\)$`),wN=new RegExp(`^rgba\\(${rl},${rl},${rl},${ki}\\)$`),EN=new RegExp(`^rgba\\(${ln},${ln},${ln},${ki}\\)$`),NN=new RegExp(`^hsl\\(${ki},${ln},${ln}\\)$`),MN=new RegExp(`^hsla\\(${ki},${ln},${ln},${ki}\\)$`),Lv={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};Gu(Li,je,{copy(t){return Object.assign(new this.constructor,this,t)},displayable(){return this.rgb().displayable()},hex:Uv,formatHex:Uv,formatHex8:zN,formatHsl:AN,formatRgb:Yv,toString:Yv});function Uv(){return this.rgb().formatHex()}function zN(){return this.rgb().formatHex8()}function AN(){return Qv(this).formatHsl()}function Yv(){return this.rgb().formatRgb()}function je(t){var e,n;return t=(t+"").trim().toLowerCase(),(e=xN.exec(t))?(n=e[1].length,e=parseInt(e[1],16),n===6?Vv(e):n===3?new ge(e>>8&15|e>>4&240,e>>4&15|e&240,(e&15)<<4|e&15,1):n===8?Qu(e>>24&255,e>>16&255,e>>8&255,(e&255)/255):n===4?Qu(e>>12&15|e>>8&240,e>>8&15|e>>4&240,e>>4&15|e&240,((e&15)<<4|e&15)/255):null):(e=SN.exec(t))?new ge(e[1],e[2],e[3],1):(e=_N.exec(t))?new ge(e[1]*255/100,e[2]*255/100,e[3]*255/100,1):(e=wN.exec(t))?Qu(e[1],e[2],e[3],e[4]):(e=EN.exec(t))?Qu(e[1]*255/100,e[2]*255/100,e[3]*255/100,e[4]):(e=NN.exec(t))?Zv(e[1],e[2]/100,e[3]/100,1):(e=MN.exec(t))?Zv(e[1],e[2]/100,e[3]/100,e[4]):Lv.hasOwnProperty(t)?Vv(Lv[t]):t==="transparent"?new ge(NaN,NaN,NaN,0):null}function Vv(t){return new ge(t>>16&255,t>>8&255,t&255,1)}function Qu(t,e,n,o){return o<=0&&(t=e=n=NaN),new ge(t,e,n,o)}function CN(t){return t instanceof Li||(t=je(t)),t?(t=t.rgb(),new ge(t.r,t.g,t.b,t.opacity)):new ge}function ul(t,e,n,o){return arguments.length===1?CN(t):new ge(t,e,n,o??1)}function ge(t,e,n,o){this.r=+t,this.g=+e,this.b=+n,this.opacity=+o}Gu(ge,ul,Zd(Li,{brighter(t){return t=t==null?Ku:Math.pow(Ku,t),new ge(this.r*t,this.g*t,this.b*t,this.opacity)},darker(t){return t=t==null?Bi:Math.pow(Bi,t),new ge(this.r*t,this.g*t,this.b*t,this.opacity)},rgb(){return this},clamp(){return new ge(ta(this.r),ta(this.g),ta(this.b),$u(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:qv,formatHex:qv,formatHex8:TN,formatRgb:Xv,toString:Xv}));function qv(){return`#${Po(this.r)}${Po(this.g)}${Po(this.b)}`}function TN(){return`#${Po(this.r)}${Po(this.g)}${Po(this.b)}${Po((isNaN(this.opacity)?1:this.opacity)*255)}`}function Xv(){let t=$u(this.opacity);return`${t===1?"rgb(":"rgba("}${ta(this.r)}, ${ta(this.g)}, ${ta(this.b)}${t===1?")":`, ${t})`}`}function $u(t){return isNaN(t)?1:Math.max(0,Math.min(1,t))}function ta(t){return Math.max(0,Math.min(255,Math.round(t)||0))}function Po(t){return t=ta(t),(t<16?"0":"")+t.toString(16)}function Zv(t,e,n,o){return o<=0?t=e=n=NaN:n<=0||n>=1?t=e=NaN:e<=0&&(t=NaN),new Qe(t,e,n,o)}function Qv(t){if(t instanceof Qe)return new Qe(t.h,t.s,t.l,t.opacity);if(t instanceof Li||(t=je(t)),!t)return new Qe;if(t instanceof Qe)return t;t=t.rgb();var e=t.r/255,n=t.g/255,o=t.b/255,a=Math.min(e,n,o),l=Math.max(e,n,o),i=NaN,r=l-a,u=(l+a)/2;return r?(e===l?i=(n-o)/r+(n<o)*6:n===l?i=(o-e)/r+2:i=(e-n)/r+4,r/=u<.5?l+a:2-l-a,i*=60):r=u>0&&u<1?0:i,new Qe(i,r,u,t.opacity)}function jv(t,e,n,o){return arguments.length===1?Qv(t):new Qe(t,e,n,o??1)}function Qe(t,e,n,o){this.h=+t,this.s=+e,this.l=+n,this.opacity=+o}Gu(Qe,jv,Zd(Li,{brighter(t){return t=t==null?Ku:Math.pow(Ku,t),new Qe(this.h,this.s,this.l*t,this.opacity)},darker(t){return t=t==null?Bi:Math.pow(Bi,t),new Qe(this.h,this.s,this.l*t,this.opacity)},rgb(){var t=this.h%360+(this.h<0)*360,e=isNaN(t)||isNaN(this.s)?0:this.s,n=this.l,o=n+(n<.5?n:1-n)*e,a=2*n-o;return new ge(Gd(t>=240?t-240:t+120,a,o),Gd(t,a,o),Gd(t<120?t+240:t-120,a,o),this.opacity)},clamp(){return new Qe(Gv(this.h),ju(this.s),ju(this.l),$u(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){let t=$u(this.opacity);return`${t===1?"hsl(":"hsla("}${Gv(this.h)}, ${ju(this.s)*100}%, ${ju(this.l)*100}%${t===1?")":`, ${t})`}`}}));function Gv(t){return t=(t||0)%360,t<0?t+360:t}function ju(t){return Math.max(0,Math.min(1,t||0))}function Gd(t,e,n){return(t<60?e+(n-e)*t/60:t<180?n:t<240?e+(n-e)*(240-t)/60:e)*255}function Qd(t,e,n,o,a){var l=t*t,i=l*t;return((1-3*t+3*l-i)*e+(4-6*l+3*i)*n+(1+3*t+3*l-3*i)*o+i*a)/6}function Kv(t){var e=t.length-1;return function(n){var o=n<=0?n=0:n>=1?(n=1,e-1):Math.floor(n*e),a=t[o],l=t[o+1],i=o>0?t[o-1]:2*a-l,r=o<e-1?t[o+2]:2*l-a;return Qd((n-o/e)*e,i,a,l,r)}}function $v(t){var e=t.length;return function(n){var o=Math.floor(((n%=1)<0?++n:n)*e),a=t[(o+e-1)%e],l=t[o%e],i=t[(o+1)%e],r=t[(o+2)%e];return Qd((n-o/e)*e,a,l,i,r)}}var Ui=t=>()=>t;function ON(t,e){return function(n){return t+n*e}}function DN(t,e,n){return t=Math.pow(t,n),e=Math.pow(e,n)-t,n=1/n,function(o){return Math.pow(t+o*e,n)}}function Jv(t){return(t=+t)==1?Ju:function(e,n){return n-e?DN(e,n,t):Ui(isNaN(e)?n:e)}}function Ju(t,e){var n=e-t;return n?ON(t,n):Ui(isNaN(t)?e:t)}var ea=(function t(e){var n=Jv(e);function o(a,l){var i=n((a=ul(a)).r,(l=ul(l)).r),r=n(a.g,l.g),u=n(a.b,l.b),s=Ju(a.opacity,l.opacity);return function(c){return a.r=i(c),a.g=r(c),a.b=u(c),a.opacity=s(c),a+""}}return o.gamma=t,o})(1);function Iv(t){return function(e){var n=e.length,o=new Array(n),a=new Array(n),l=new Array(n),i,r;for(i=0;i<n;++i)r=ul(e[i]),o[i]=r.r||0,a[i]=r.g||0,l[i]=r.b||0;return o=t(o),a=t(a),l=t(l),r.opacity=1,function(u){return r.r=o(u),r.g=a(u),r.b=l(u),r+""}}}var HN=Iv(Kv),RN=Iv($v);function Wv(t,e){e||(e=[]);var n=t?Math.min(e.length,t.length):0,o=e.slice(),a;return function(l){for(a=0;a<n;++a)o[a]=t[a]*(1-l)+e[a]*l;return o}}function Fv(t){return ArrayBuffer.isView(t)&&!(t instanceof DataView)}function Pv(t,e){var n=e?e.length:0,o=t?Math.min(n,t.length):0,a=new Array(o),l=new Array(n),i;for(i=0;i<o;++i)a[i]=kn(t[i],e[i]);for(;i<n;++i)l[i]=e[i];return function(r){for(i=0;i<o;++i)l[i]=a[i](r);return l}}function t1(t,e){var n=new Date;return t=+t,e=+e,function(o){return n.setTime(t*(1-o)+e*o),n}}function ae(t,e){return t=+t,e=+e,function(n){return t*(1-n)+e*n}}function e1(t,e){var n={},o={},a;(t===null||typeof t!="object")&&(t={}),(e===null||typeof e!="object")&&(e={});for(a in e)a in t?n[a]=kn(t[a],e[a]):o[a]=e[a];return function(l){for(a in n)o[a]=n[a](l);return o}}var Kd=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,jd=new RegExp(Kd.source,"g");function BN(t){return function(){return t}}function kN(t){return function(e){return t(e)+""}}function Yi(t,e){var n=Kd.lastIndex=jd.lastIndex=0,o,a,l,i=-1,r=[],u=[];for(t=t+"",e=e+"";(o=Kd.exec(t))&&(a=jd.exec(e));)(l=a.index)>n&&(l=e.slice(n,l),r[i]?r[i]+=l:r[++i]=l),(o=o[0])===(a=a[0])?r[i]?r[i]+=a:r[++i]=a:(r[++i]=null,u.push({i,x:ae(o,a)})),n=jd.lastIndex;return n<e.length&&(l=e.slice(n),r[i]?r[i]+=l:r[++i]=l),r.length<2?u[0]?kN(u[0].x):BN(e):(e=u.length,function(s){for(var c=0,d;c<e;++c)r[(d=u[c]).i]=d.x(s);return r.join("")})}function kn(t,e){var n=typeof e,o;return e==null||n==="boolean"?Ui(e):(n==="number"?ae:n==="string"?(o=je(e))?(e=o,ea):Yi:e instanceof je?ea:e instanceof Date?t1:Fv(e)?Wv:Array.isArray(e)?Pv:typeof e.valueOf!="function"&&typeof e.toString!="function"||isNaN(e)?e1:ae)(t,e)}var n1=180/Math.PI,Iu={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1};function $d(t,e,n,o,a,l){var i,r,u;return(i=Math.sqrt(t*t+e*e))&&(t/=i,e/=i),(u=t*n+e*o)&&(n-=t*u,o-=e*u),(r=Math.sqrt(n*n+o*o))&&(n/=r,o/=r,u/=r),t*o<e*n&&(t=-t,e=-e,u=-u,i=-i),{translateX:a,translateY:l,rotate:Math.atan2(e,t)*n1,skewX:Math.atan(u)*n1,scaleX:i,scaleY:r}}var Wu;function o1(t){let e=new(typeof DOMMatrix=="function"?DOMMatrix:WebKitCSSMatrix)(t+"");return e.isIdentity?Iu:$d(e.a,e.b,e.c,e.d,e.e,e.f)}function a1(t){return t==null?Iu:(Wu||(Wu=document.createElementNS("http://www.w3.org/2000/svg","g")),Wu.setAttribute("transform",t),(t=Wu.transform.baseVal.consolidate())?(t=t.matrix,$d(t.a,t.b,t.c,t.d,t.e,t.f)):Iu)}function l1(t,e,n,o){function a(s){return s.length?s.pop()+" ":""}function l(s,c,d,f,p,y){if(s!==d||c!==f){var b=p.push("translate(",null,e,null,n);y.push({i:b-4,x:ae(s,d)},{i:b-2,x:ae(c,f)})}else(d||f)&&p.push("translate("+d+e+f+n)}function i(s,c,d,f){s!==c?(s-c>180?c+=360:c-s>180&&(s+=360),f.push({i:d.push(a(d)+"rotate(",null,o)-2,x:ae(s,c)})):c&&d.push(a(d)+"rotate("+c+o)}function r(s,c,d,f){s!==c?f.push({i:d.push(a(d)+"skewX(",null,o)-2,x:ae(s,c)}):c&&d.push(a(d)+"skewX("+c+o)}function u(s,c,d,f,p,y){if(s!==d||c!==f){var b=p.push(a(p)+"scale(",null,",",null,")");y.push({i:b-4,x:ae(s,d)},{i:b-2,x:ae(c,f)})}else(d!==1||f!==1)&&p.push(a(p)+"scale("+d+","+f+")")}return function(s,c){var d=[],f=[];return s=t(s),c=t(c),l(s.translateX,s.translateY,c.translateX,c.translateY,d,f),i(s.rotate,c.rotate,d,f),r(s.skewX,c.skewX,d,f),u(s.scaleX,s.scaleY,c.scaleX,c.scaleY,d,f),s=c=null,function(p){for(var y=-1,b=f.length,x;++y<b;)d[(x=f[y]).i]=x.x(p);return d.join("")}}}var Jd=l1(o1,"px, ","px)","deg)"),Id=l1(a1,", ",")",")");var LN=1e-12;function i1(t){return((t=Math.exp(t))+1/t)/2}function UN(t){return((t=Math.exp(t))-1/t)/2}function YN(t){return((t=Math.exp(2*t))-1)/(t+1)}var na=(function t(e,n,o){function a(l,i){var r=l[0],u=l[1],s=l[2],c=i[0],d=i[1],f=i[2],p=c-r,y=d-u,b=p*p+y*y,x,g;if(b<LN)g=Math.log(f/s)/e,x=function(w){return[r+w*p,u+w*y,s*Math.exp(e*w*g)]};else{var m=Math.sqrt(b),h=(f*f-s*s+o*b)/(2*s*n*m),v=(f*f-s*s-o*b)/(2*f*n*m),_=Math.log(Math.sqrt(h*h+1)-h),E=Math.log(Math.sqrt(v*v+1)-v);g=(E-_)/e,x=function(w){var N=w*g,M=i1(_),R=s/(n*m)*(M*YN(e*N+_)-UN(_));return[r+R*p,u+R*y,s*M/i1(e*N+_)]}}return x.duration=g*1e3*e/Math.SQRT2,x}return a.rho=function(l){var i=Math.max(.001,+l),r=i*i,u=r*r;return t(i,r,u)},a})(Math.SQRT2,2,4);var cl=0,qi=0,Vi=0,u1=1e3,Fu,Xi,Pu=0,oa=0,tc=0,Zi=typeof performance=="object"&&performance.now?performance:Date,c1=typeof window=="object"&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(t){setTimeout(t,17)};function Qi(){return oa||(c1(VN),oa=Zi.now()+tc)}function VN(){oa=0}function Gi(){this._call=this._time=this._next=null}Gi.prototype=ec.prototype={constructor:Gi,restart:function(t,e,n){if(typeof t!="function")throw new TypeError("callback is not a function");n=(n==null?Qi():+n)+(e==null?0:+e),!this._next&&Xi!==this&&(Xi?Xi._next=this:Fu=this,Xi=this),this._call=t,this._time=n,Wd()},stop:function(){this._call&&(this._call=null,this._time=1/0,Wd())}};function ec(t,e,n){var o=new Gi;return o.restart(t,e,n),o}function s1(){Qi(),++cl;for(var t=Fu,e;t;)(e=oa-t._time)>=0&&t._call.call(void 0,e),t=t._next;--cl}function r1(){oa=(Pu=Zi.now())+tc,cl=qi=0;try{s1()}finally{cl=0,XN(),oa=0}}function qN(){var t=Zi.now(),e=t-Pu;e>u1&&(tc-=e,Pu=t)}function XN(){for(var t,e=Fu,n,o=1/0;e;)e._call?(o>e._time&&(o=e._time),t=e,e=e._next):(n=e._next,e._next=null,e=t?t._next=n:Fu=n);Xi=t,Wd(o)}function Wd(t){if(!cl){qi&&(qi=clearTimeout(qi));var e=t-oa;e>24?(t<1/0&&(qi=setTimeout(r1,t-Zi.now()-tc)),Vi&&(Vi=clearInterval(Vi))):(Vi||(Pu=Zi.now(),Vi=setInterval(qN,u1)),cl=1,c1(r1))}}function nc(t,e,n){var o=new Gi;return e=e==null?0:+e,o.restart(a=>{o.stop(),t(a+e)},e,n),o}var ZN=Io("start","end","cancel","interrupt"),GN=[],h1=0,f1=1,ac=2,oc=3,d1=4,lc=5,ji=6;function vo(t,e,n,o,a,l){var i=t.__transition;if(!i)t.__transition={};else if(n in i)return;QN(t,n,{name:e,index:o,group:a,on:ZN,tween:GN,time:l.time,delay:l.delay,duration:l.duration,ease:l.ease,timer:null,state:h1})}function Ki(t,e){var n=qt(t,e);if(n.state>h1)throw new Error("too late; already scheduled");return n}function Wt(t,e){var n=qt(t,e);if(n.state>oc)throw new Error("too late; already running");return n}function qt(t,e){var n=t.__transition;if(!n||!(n=n[e]))throw new Error("transition not found");return n}function QN(t,e,n){var o=t.__transition,a;o[e]=n,n.timer=ec(l,0,n.time);function l(s){n.state=f1,n.timer.restart(i,n.delay,n.time),n.delay<=s&&i(s-n.delay)}function i(s){var c,d,f,p;if(n.state!==f1)return u();for(c in o)if(p=o[c],p.name===n.name){if(p.state===oc)return nc(i);p.state===d1?(p.state=ji,p.timer.stop(),p.on.call("interrupt",t,t.__data__,p.index,p.group),delete o[c]):+c<e&&(p.state=ji,p.timer.stop(),p.on.call("cancel",t,t.__data__,p.index,p.group),delete o[c])}if(nc(function(){n.state===oc&&(n.state=d1,n.timer.restart(r,n.delay,n.time),r(s))}),n.state=ac,n.on.call("start",t,t.__data__,n.index,n.group),n.state===ac){for(n.state=oc,a=new Array(f=n.tween.length),c=0,d=-1;c<f;++c)(p=n.tween[c].value.call(t,t.__data__,n.index,n.group))&&(a[++d]=p);a.length=d+1}}function r(s){for(var c=s<n.duration?n.ease.call(null,s/n.duration):(n.timer.restart(u),n.state=lc,1),d=-1,f=a.length;++d<f;)a[d].call(t,c);n.state===lc&&(n.on.call("end",t,t.__data__,n.index,n.group),u())}function u(){n.state=ji,n.timer.stop(),delete o[e];for(var s in o)return;delete t.__transition}}function aa(t,e){var n=t.__transition,o,a,l=!0,i;if(n){e=e==null?null:e+"";for(i in n){if((o=n[i]).name!==e){l=!1;continue}a=o.state>ac&&o.state<lc,o.state=ji,o.timer.stop(),o.on.call(a?"interrupt":"cancel",t,t.__data__,o.index,o.group),delete n[i]}l&&delete t.__transition}}function p1(t){return this.each(function(){aa(this,t)})}function jN(t,e){var n,o;return function(){var a=Wt(this,t),l=a.tween;if(l!==n){o=n=l;for(var i=0,r=o.length;i<r;++i)if(o[i].name===e){o=o.slice(),o.splice(i,1);break}}a.tween=o}}function KN(t,e,n){var o,a;if(typeof n!="function")throw new Error;return function(){var l=Wt(this,t),i=l.tween;if(i!==o){a=(o=i).slice();for(var r={name:e,value:n},u=0,s=a.length;u<s;++u)if(a[u].name===e){a[u]=r;break}u===s&&a.push(r)}l.tween=a}}function g1(t,e){var n=this._id;if(t+="",arguments.length<2){for(var o=qt(this.node(),n).tween,a=0,l=o.length,i;a<l;++a)if((i=o[a]).name===t)return i.value;return null}return this.each((e==null?jN:KN)(n,t,e))}function sl(t,e,n){var o=t._id;return t.each(function(){var a=Wt(this,o);(a.value||(a.value={}))[e]=n.apply(this,arguments)}),function(a){return qt(a,o).value[e]}}function ic(t,e){var n;return(typeof e=="number"?ae:e instanceof je?ea:(n=je(e))?(e=n,ea):Yi)(t,e)}function $N(t){return function(){this.removeAttribute(t)}}function JN(t){return function(){this.removeAttributeNS(t.space,t.local)}}function IN(t,e,n){var o,a=n+"",l;return function(){var i=this.getAttribute(t);return i===a?null:i===o?l:l=e(o=i,n)}}function WN(t,e,n){var o,a=n+"",l;return function(){var i=this.getAttributeNS(t.space,t.local);return i===a?null:i===o?l:l=e(o=i,n)}}function FN(t,e,n){var o,a,l;return function(){var i,r=n(this),u;return r==null?void this.removeAttribute(t):(i=this.getAttribute(t),u=r+"",i===u?null:i===o&&u===a?l:(a=u,l=e(o=i,r)))}}function PN(t,e,n){var o,a,l;return function(){var i,r=n(this),u;return r==null?void this.removeAttributeNS(t.space,t.local):(i=this.getAttributeNS(t.space,t.local),u=r+"",i===u?null:i===o&&u===a?l:(a=u,l=e(o=i,r)))}}function m1(t,e){var n=Rn(t),o=n==="transform"?Id:ic;return this.attrTween(t,typeof e=="function"?(n.local?PN:FN)(n,o,sl(this,"attr."+t,e)):e==null?(n.local?JN:$N)(n):(n.local?WN:IN)(n,o,e))}function tM(t,e){return function(n){this.setAttribute(t,e.call(this,n))}}function eM(t,e){return function(n){this.setAttributeNS(t.space,t.local,e.call(this,n))}}function nM(t,e){var n,o;function a(){var l=e.apply(this,arguments);return l!==o&&(n=(o=l)&&eM(t,l)),n}return a._value=e,a}function oM(t,e){var n,o;function a(){var l=e.apply(this,arguments);return l!==o&&(n=(o=l)&&tM(t,l)),n}return a._value=e,a}function y1(t,e){var n="attr."+t;if(arguments.length<2)return(n=this.tween(n))&&n._value;if(e==null)return this.tween(n,null);if(typeof e!="function")throw new Error;var o=Rn(t);return this.tween(n,(o.local?nM:oM)(o,e))}function aM(t,e){return function(){Ki(this,t).delay=+e.apply(this,arguments)}}function lM(t,e){return e=+e,function(){Ki(this,t).delay=e}}function v1(t){var e=this._id;return arguments.length?this.each((typeof t=="function"?aM:lM)(e,t)):qt(this.node(),e).delay}function iM(t,e){return function(){Wt(this,t).duration=+e.apply(this,arguments)}}function rM(t,e){return e=+e,function(){Wt(this,t).duration=e}}function b1(t){var e=this._id;return arguments.length?this.each((typeof t=="function"?iM:rM)(e,t)):qt(this.node(),e).duration}function uM(t,e){if(typeof e!="function")throw new Error;return function(){Wt(this,t).ease=e}}function x1(t){var e=this._id;return arguments.length?this.each(uM(e,t)):qt(this.node(),e).ease}function cM(t,e){return function(){var n=e.apply(this,arguments);if(typeof n!="function")throw new Error;Wt(this,t).ease=n}}function S1(t){if(typeof t!="function")throw new Error;return this.each(cM(this._id,t))}function _1(t){typeof t!="function"&&(t=Ci(t));for(var e=this._groups,n=e.length,o=new Array(n),a=0;a<n;++a)for(var l=e[a],i=l.length,r=o[a]=[],u,s=0;s<i;++s)(u=l[s])&&t.call(u,u.__data__,s,l)&&r.push(u);return new le(o,this._parents,this._name,this._id)}function w1(t){if(t._id!==this._id)throw new Error;for(var e=this._groups,n=t._groups,o=e.length,a=n.length,l=Math.min(o,a),i=new Array(o),r=0;r<l;++r)for(var u=e[r],s=n[r],c=u.length,d=i[r]=new Array(c),f,p=0;p<c;++p)(f=u[p]||s[p])&&(d[p]=f);for(;r<o;++r)i[r]=e[r];return new le(i,this._parents,this._name,this._id)}function sM(t){return(t+"").trim().split(/^|\s+/).every(function(e){var n=e.indexOf(".");return n>=0&&(e=e.slice(0,n)),!e||e==="start"})}function fM(t,e,n){var o,a,l=sM(e)?Ki:Wt;return function(){var i=l(this,t),r=i.on;r!==o&&(a=(o=r).copy()).on(e,n),i.on=a}}function E1(t,e){var n=this._id;return arguments.length<2?qt(this.node(),n).on.on(t):this.each(fM(n,t,e))}function dM(t){return function(){var e=this.parentNode;for(var n in this.__transition)if(+n!==t)return;e&&e.removeChild(this)}}function N1(){return this.on("end.remove",dM(this._id))}function M1(t){var e=this._name,n=this._id;typeof t!="function"&&(t=Wo(t));for(var o=this._groups,a=o.length,l=new Array(a),i=0;i<a;++i)for(var r=o[i],u=r.length,s=l[i]=new Array(u),c,d,f=0;f<u;++f)(c=r[f])&&(d=t.call(c,c.__data__,f,r))&&("__data__"in c&&(d.__data__=c.__data__),s[f]=d,vo(s[f],e,n,f,s,qt(c,n)));return new le(l,this._parents,e,n)}function z1(t){var e=this._name,n=this._id;typeof t!="function"&&(t=Ai(t));for(var o=this._groups,a=o.length,l=[],i=[],r=0;r<a;++r)for(var u=o[r],s=u.length,c,d=0;d<s;++d)if(c=u[d]){for(var f=t.call(c,c.__data__,d,u),p,y=qt(c,n),b=0,x=f.length;b<x;++b)(p=f[b])&&vo(p,e,n,b,f,y);l.push(f),i.push(c)}return new le(l,i,e,n)}var hM=Bn.prototype.constructor;function A1(){return new hM(this._groups,this._parents)}function pM(t,e){var n,o,a;return function(){var l=mo(this,t),i=(this.style.removeProperty(t),mo(this,t));return l===i?null:l===n&&i===o?a:a=e(n=l,o=i)}}function C1(t){return function(){this.style.removeProperty(t)}}function gM(t,e,n){var o,a=n+"",l;return function(){var i=mo(this,t);return i===a?null:i===o?l:l=e(o=i,n)}}function mM(t,e,n){var o,a,l;return function(){var i=mo(this,t),r=n(this),u=r+"";return r==null&&(u=r=(this.style.removeProperty(t),mo(this,t))),i===u?null:i===o&&u===a?l:(a=u,l=e(o=i,r))}}function yM(t,e){var n,o,a,l="style."+e,i="end."+l,r;return function(){var u=Wt(this,t),s=u.on,c=u.value[l]==null?r||(r=C1(e)):void 0;(s!==n||a!==c)&&(o=(n=s).copy()).on(i,a=c),u.on=o}}function T1(t,e,n){var o=(t+="")=="transform"?Jd:ic;return e==null?this.styleTween(t,pM(t,o)).on("end.style."+t,C1(t)):typeof e=="function"?this.styleTween(t,mM(t,o,sl(this,"style."+t,e))).each(yM(this._id,t)):this.styleTween(t,gM(t,o,e),n).on("end.style."+t,null)}function vM(t,e,n){return function(o){this.style.setProperty(t,e.call(this,o),n)}}function bM(t,e,n){var o,a;function l(){var i=e.apply(this,arguments);return i!==a&&(o=(a=i)&&vM(t,i,n)),o}return l._value=e,l}function O1(t,e,n){var o="style."+(t+="");if(arguments.length<2)return(o=this.tween(o))&&o._value;if(e==null)return this.tween(o,null);if(typeof e!="function")throw new Error;return this.tween(o,bM(t,e,n??""))}function xM(t){return function(){this.textContent=t}}function SM(t){return function(){var e=t(this);this.textContent=e??""}}function D1(t){return this.tween("text",typeof t=="function"?SM(sl(this,"text",t)):xM(t==null?"":t+""))}function _M(t){return function(e){this.textContent=t.call(this,e)}}function wM(t){var e,n;function o(){var a=t.apply(this,arguments);return a!==n&&(e=(n=a)&&_M(a)),e}return o._value=t,o}function H1(t){var e="text";if(arguments.length<1)return(e=this.tween(e))&&e._value;if(t==null)return this.tween(e,null);if(typeof t!="function")throw new Error;return this.tween(e,wM(t))}function R1(){for(var t=this._name,e=this._id,n=rc(),o=this._groups,a=o.length,l=0;l<a;++l)for(var i=o[l],r=i.length,u,s=0;s<r;++s)if(u=i[s]){var c=qt(u,e);vo(u,t,n,s,i,{time:c.time+c.delay+c.duration,delay:0,duration:c.duration,ease:c.ease})}return new le(o,this._parents,t,n)}function B1(){var t,e,n=this,o=n._id,a=n.size();return new Promise(function(l,i){var r={value:i},u={value:function(){--a===0&&l()}};n.each(function(){var s=Wt(this,o),c=s.on;c!==t&&(e=(t=c).copy(),e._.cancel.push(r),e._.interrupt.push(r),e._.end.push(u)),s.on=e}),a===0&&l()})}var EM=0;function le(t,e,n,o){this._groups=t,this._parents=e,this._name=n,this._id=o}function k1(t){return Bn().transition(t)}function rc(){return++EM}var Ln=Bn.prototype;le.prototype=k1.prototype={constructor:le,select:M1,selectAll:z1,selectChild:Ln.selectChild,selectChildren:Ln.selectChildren,filter:_1,merge:w1,selection:A1,transition:R1,call:Ln.call,nodes:Ln.nodes,node:Ln.node,size:Ln.size,empty:Ln.empty,each:Ln.each,on:E1,attr:m1,attrTween:y1,style:T1,styleTween:O1,text:D1,textTween:H1,remove:N1,tween:g1,delay:v1,duration:b1,ease:x1,easeVarying:S1,end:B1,[Symbol.iterator]:Ln[Symbol.iterator]};function uc(t){return((t*=2)<=1?t*t*t:(t-=2)*t*t+2)/2}var NM={time:null,delay:0,duration:250,ease:uc};function MM(t,e){for(var n;!(n=t.__transition)||!(n=n[e]);)if(!(t=t.parentNode))throw new Error(`transition ${e} not found`);return n}function L1(t){var e,n;t instanceof le?(e=t._id,t=t._name):(e=rc(),(n=NM).time=Qi(),t=t==null?null:t+"");for(var o=this._groups,a=o.length,l=0;l<a;++l)for(var i=o[l],r=i.length,u,s=0;s<r;++s)(u=i[s])&&vo(u,t,e,s,i,n||MM(u,e));return new le(o,this._parents,t,e)}Bn.prototype.interrupt=p1;Bn.prototype.transition=L1;var $i=t=>()=>t;function Fd(t,{sourceEvent:e,target:n,transform:o,dispatch:a}){Object.defineProperties(this,{type:{value:t,enumerable:!0,configurable:!0},sourceEvent:{value:e,enumerable:!0,configurable:!0},target:{value:n,enumerable:!0,configurable:!0},transform:{value:o,enumerable:!0,configurable:!0},_:{value:a}})}function Ke(t,e,n){this.k=t,this.x=e,this.y=n}Ke.prototype={constructor:Ke,scale:function(t){return t===1?this:new Ke(this.k*t,this.x,this.y)},translate:function(t,e){return t===0&e===0?this:new Ke(this.k,this.x+this.k*t,this.y+this.k*e)},apply:function(t){return[t[0]*this.k+this.x,t[1]*this.k+this.y]},applyX:function(t){return t*this.k+this.x},applyY:function(t){return t*this.k+this.y},invert:function(t){return[(t[0]-this.x)/this.k,(t[1]-this.y)/this.k]},invertX:function(t){return(t-this.x)/this.k},invertY:function(t){return(t-this.y)/this.k},rescaleX:function(t){return t.copy().domain(t.range().map(this.invertX,this).map(t.invert,t))},rescaleY:function(t){return t.copy().domain(t.range().map(this.invertY,this).map(t.invert,t))},toString:function(){return"translate("+this.x+","+this.y+") scale("+this.k+")"}};var la=new Ke(1,0,0);Ji.prototype=Ke.prototype;function Ji(t){for(;!t.__zoom;)if(!(t=t.parentNode))return la;return t.__zoom}function cc(t){t.stopImmediatePropagation()}function fl(t){t.preventDefault(),t.stopImmediatePropagation()}function zM(t){return(!t.ctrlKey||t.type==="wheel")&&!t.button}function AM(){var t=this;return t instanceof SVGElement?(t=t.ownerSVGElement||t,t.hasAttribute("viewBox")?(t=t.viewBox.baseVal,[[t.x,t.y],[t.x+t.width,t.y+t.height]]):[[0,0],[t.width.baseVal.value,t.height.baseVal.value]]):[[0,0],[t.clientWidth,t.clientHeight]]}function U1(){return this.__zoom||la}function CM(t){return-t.deltaY*(t.deltaMode===1?.05:t.deltaMode?1:.002)*(t.ctrlKey?10:1)}function TM(){return navigator.maxTouchPoints||"ontouchstart"in this}function OM(t,e,n){var o=t.invertX(e[0][0])-n[0][0],a=t.invertX(e[1][0])-n[1][0],l=t.invertY(e[0][1])-n[0][1],i=t.invertY(e[1][1])-n[1][1];return t.translate(a>o?(o+a)/2:Math.min(0,o)||Math.max(0,a),i>l?(l+i)/2:Math.min(0,l)||Math.max(0,i))}function sc(){var t=zM,e=AM,n=OM,o=CM,a=TM,l=[0,1/0],i=[[-1/0,-1/0],[1/0,1/0]],r=250,u=na,s=Io("start","zoom","end"),c,d,f,p=500,y=150,b=0,x=10;function g(S){S.property("__zoom",U1).on("wheel.zoom",N,{passive:!1}).on("mousedown.zoom",M).on("dblclick.zoom",R).filter(a).on("touchstart.zoom",C).on("touchmove.zoom",k).on("touchend.zoom touchcancel.zoom",V).style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}g.transform=function(S,A,z,T){var B=S.selection?S.selection():S;B.property("__zoom",U1),S!==B?_(S,A,z,T):B.interrupt().each(function(){E(this,arguments).event(T).start().zoom(null,typeof A=="function"?A.apply(this,arguments):A).end()})},g.scaleBy=function(S,A,z,T){g.scaleTo(S,function(){var B=this.__zoom.k,H=typeof A=="function"?A.apply(this,arguments):A;return B*H},z,T)},g.scaleTo=function(S,A,z,T){g.transform(S,function(){var B=e.apply(this,arguments),H=this.__zoom,X=z==null?v(B):typeof z=="function"?z.apply(this,arguments):z,Z=H.invert(X),q=typeof A=="function"?A.apply(this,arguments):A;return n(h(m(H,q),X,Z),B,i)},z,T)},g.translateBy=function(S,A,z,T){g.transform(S,function(){return n(this.__zoom.translate(typeof A=="function"?A.apply(this,arguments):A,typeof z=="function"?z.apply(this,arguments):z),e.apply(this,arguments),i)},null,T)},g.translateTo=function(S,A,z,T,B){g.transform(S,function(){var H=e.apply(this,arguments),X=this.__zoom,Z=T==null?v(H):typeof T=="function"?T.apply(this,arguments):T;return n(la.translate(Z[0],Z[1]).scale(X.k).translate(typeof A=="function"?-A.apply(this,arguments):-A,typeof z=="function"?-z.apply(this,arguments):-z),H,i)},T,B)};function m(S,A){return A=Math.max(l[0],Math.min(l[1],A)),A===S.k?S:new Ke(A,S.x,S.y)}function h(S,A,z){var T=A[0]-z[0]*S.k,B=A[1]-z[1]*S.k;return T===S.x&&B===S.y?S:new Ke(S.k,T,B)}function v(S){return[(+S[0][0]+ +S[1][0])/2,(+S[0][1]+ +S[1][1])/2]}function _(S,A,z,T){S.on("start.zoom",function(){E(this,arguments).event(T).start()}).on("interrupt.zoom end.zoom",function(){E(this,arguments).event(T).end()}).tween("zoom",function(){var B=this,H=arguments,X=E(B,H).event(T),Z=e.apply(B,H),q=z==null?v(Z):typeof z=="function"?z.apply(B,H):z,K=Math.max(Z[1][0]-Z[0][0],Z[1][1]-Z[0][1]),j=B.__zoom,I=typeof A=="function"?A.apply(B,H):A,ot=u(j.invert(q).concat(K/j.k),I.invert(q).concat(K/I.k));return function(J){if(J===1)J=I;else{var U=ot(J),Q=K/U[2];J=new Ke(Q,q[0]-U[0]*Q,q[1]-U[1]*Q)}X.zoom(null,J)}})}function E(S,A,z){return!z&&S.__zooming||new w(S,A)}function w(S,A){this.that=S,this.args=A,this.active=0,this.sourceEvent=null,this.extent=e.apply(S,A),this.taps=0}w.prototype={event:function(S){return S&&(this.sourceEvent=S),this},start:function(){return++this.active===1&&(this.that.__zooming=this,this.emit("start")),this},zoom:function(S,A){return this.mouse&&S!=="mouse"&&(this.mouse[1]=A.invert(this.mouse[0])),this.touch0&&S!=="touch"&&(this.touch0[1]=A.invert(this.touch0[0])),this.touch1&&S!=="touch"&&(this.touch1[1]=A.invert(this.touch1[0])),this.that.__zoom=A,this.emit("zoom"),this},end:function(){return--this.active===0&&(delete this.that.__zooming,this.emit("end")),this},emit:function(S){var A=Qt(this.that).datum();s.call(S,this.that,new Fd(S,{sourceEvent:this.sourceEvent,target:g,type:S,transform:this.that.__zoom,dispatch:s}),A)}};function N(S,...A){if(!t.apply(this,arguments))return;var z=E(this,A).event(S),T=this.__zoom,B=Math.max(l[0],Math.min(l[1],T.k*Math.pow(2,o.apply(this,arguments)))),H=oe(S);if(z.wheel)(z.mouse[0][0]!==H[0]||z.mouse[0][1]!==H[1])&&(z.mouse[1]=T.invert(z.mouse[0]=H)),clearTimeout(z.wheel);else{if(T.k===B)return;z.mouse=[H,T.invert(H)],aa(this),z.start()}fl(S),z.wheel=setTimeout(X,y),z.zoom("mouse",n(h(m(T,B),z.mouse[0],z.mouse[1]),z.extent,i));function X(){z.wheel=null,z.end()}}function M(S,...A){if(f||!t.apply(this,arguments))return;var z=S.currentTarget,T=E(this,A,!0).event(S),B=Qt(S.view).on("mousemove.zoom",q,!0).on("mouseup.zoom",K,!0),H=oe(S,z),X=S.clientX,Z=S.clientY;Oi(S.view),cc(S),T.mouse=[H,this.__zoom.invert(H)],aa(this),T.start();function q(j){if(fl(j),!T.moved){var I=j.clientX-X,ot=j.clientY-Z;T.moved=I*I+ot*ot>b}T.event(j).zoom("mouse",n(h(T.that.__zoom,T.mouse[0]=oe(j,z),T.mouse[1]),T.extent,i))}function K(j){B.on("mousemove.zoom mouseup.zoom",null),Di(j.view,T.moved),fl(j),T.event(j).end()}}function R(S,...A){if(t.apply(this,arguments)){var z=this.__zoom,T=oe(S.changedTouches?S.changedTouches[0]:S,this),B=z.invert(T),H=z.k*(S.shiftKey?.5:2),X=n(h(m(z,H),T,B),e.apply(this,A),i);fl(S),r>0?Qt(this).transition().duration(r).call(_,X,T,S):Qt(this).call(g.transform,X,T,S)}}function C(S,...A){if(t.apply(this,arguments)){var z=S.touches,T=z.length,B=E(this,A,S.changedTouches.length===T).event(S),H,X,Z,q;for(cc(S),X=0;X<T;++X)Z=z[X],q=oe(Z,this),q=[q,this.__zoom.invert(q),Z.identifier],B.touch0?!B.touch1&&B.touch0[2]!==q[2]&&(B.touch1=q,B.taps=0):(B.touch0=q,H=!0,B.taps=1+!!c);c&&(c=clearTimeout(c)),H&&(B.taps<2&&(d=q[0],c=setTimeout(function(){c=null},p)),aa(this),B.start())}}function k(S,...A){if(this.__zooming){var z=E(this,A).event(S),T=S.changedTouches,B=T.length,H,X,Z,q;for(fl(S),H=0;H<B;++H)X=T[H],Z=oe(X,this),z.touch0&&z.touch0[2]===X.identifier?z.touch0[0]=Z:z.touch1&&z.touch1[2]===X.identifier&&(z.touch1[0]=Z);if(X=z.that.__zoom,z.touch1){var K=z.touch0[0],j=z.touch0[1],I=z.touch1[0],ot=z.touch1[1],J=(J=I[0]-K[0])*J+(J=I[1]-K[1])*J,U=(U=ot[0]-j[0])*U+(U=ot[1]-j[1])*U;X=m(X,Math.sqrt(J/U)),Z=[(K[0]+I[0])/2,(K[1]+I[1])/2],q=[(j[0]+ot[0])/2,(j[1]+ot[1])/2]}else if(z.touch0)Z=z.touch0[0],q=z.touch0[1];else return;z.zoom("touch",n(h(X,Z,q),z.extent,i))}}function V(S,...A){if(this.__zooming){var z=E(this,A).event(S),T=S.changedTouches,B=T.length,H,X;for(cc(S),f&&clearTimeout(f),f=setTimeout(function(){f=null},p),H=0;H<B;++H)X=T[H],z.touch0&&z.touch0[2]===X.identifier?delete z.touch0:z.touch1&&z.touch1[2]===X.identifier&&delete z.touch1;if(z.touch1&&!z.touch0&&(z.touch0=z.touch1,delete z.touch1),z.touch0)z.touch0[1]=this.__zoom.invert(z.touch0[0]);else if(z.end(),z.taps===2&&(X=oe(X,this),Math.hypot(d[0]-X[0],d[1]-X[1])<x)){var Z=Qt(this).on("dblclick.zoom");Z&&Z.apply(this,arguments)}}}return g.wheelDelta=function(S){return arguments.length?(o=typeof S=="function"?S:$i(+S),g):o},g.filter=function(S){return arguments.length?(t=typeof S=="function"?S:$i(!!S),g):t},g.touchable=function(S){return arguments.length?(a=typeof S=="function"?S:$i(!!S),g):a},g.extent=function(S){return arguments.length?(e=typeof S=="function"?S:$i([[+S[0][0],+S[0][1]],[+S[1][0],+S[1][1]]]),g):e},g.scaleExtent=function(S){return arguments.length?(l[0]=+S[0],l[1]=+S[1],g):[l[0],l[1]]},g.translateExtent=function(S){return arguments.length?(i[0][0]=+S[0][0],i[1][0]=+S[1][0],i[0][1]=+S[0][1],i[1][1]=+S[1][1],g):[[i[0][0],i[0][1]],[i[1][0],i[1][1]]]},g.constrain=function(S){return arguments.length?(n=S,g):n},g.duration=function(S){return arguments.length?(r=+S,g):r},g.interpolate=function(S){return arguments.length?(u=S,g):u},g.on=function(){var S=s.on.apply(s,arguments);return S===s?g:S},g.clickDistance=function(S){return arguments.length?(b=(S=+S)*S,g):Math.sqrt(b)},g.tapDistance=function(S){return arguments.length?(x=+S,g):x},g}var Me={error001:(t="react")=>`Seems like you have not used zustand provider as an ancestor. Help: https://${t}flow.dev/error#001`,error002:()=>"It looks like you've created a new nodeTypes or edgeTypes object. If this wasn't on purpose please define the nodeTypes/edgeTypes outside of the component or memoize them.",error003:t=>`Node type "${t}" not found. Using fallback type "default".`,error004:()=>"The parent container needs a width and a height to render the graph.",error005:()=>"Only child nodes can use a parent extent.",error006:()=>"Can't create edge. An edge needs a source and a target.",error007:t=>`The old edge with id=${t} does not exist.`,error009:t=>`Marker type "${t}" doesn't exist.`,error008:(t,{id:e,sourceHandle:n,targetHandle:o})=>`Couldn't create edge for ${t} handle id: "${t==="source"?n:o}", edge id: ${e}.`,error010:()=>"Handle: No node id found. Make sure to only use a Handle inside a custom Node.",error011:t=>`Edge type "${t}" not found. Using fallback type "default".`,error012:t=>`Node with id "${t}" does not exist, it may have been removed. This can happen when a node is deleted before the "onNodeClick" handler is called.`,error013:(t="react")=>`It seems that you haven't loaded the styles. Please import '@xyflow/${t}/dist/style.css' or base.css to make sure everything is working properly.`,error014:()=>"useNodeConnections: No node ID found. Call useNodeConnections inside a custom Node or provide a node ID.",error015:()=>"It seems that you are trying to drag a node that is not initialized. Please use onNodesChange as explained in the docs.",error016:t=>`Edge with id "${t}" does not exist, it may have been removed. This can happen when an edge is deleted before the "onEdgeClick" handler is called.`},ml=[[Number.NEGATIVE_INFINITY,Number.NEGATIVE_INFINITY],[Number.POSITIVE_INFINITY,Number.POSITIVE_INFINITY]],oh=["Enter"," ","Escape"],ah={"node.a11yDescription.default":"Press enter or space to select a node. Press delete to remove it and escape to cancel.","node.a11yDescription.keyboardDisabled":"Press enter or space to select a node. You can then use the arrow keys to move the node around. Press delete to remove it and escape to cancel.","node.a11yDescription.ariaLiveMessage":({direction:t,x:e,y:n})=>`Moved selected node ${t}. New position, x: ${e}, y: ${n}`,"edge.a11yDescription.default":"Press enter or space to select an edge. You can then press delete to remove it or escape to cancel.","controls.ariaLabel":"Control Panel","controls.zoomIn.ariaLabel":"Zoom In","controls.zoomOut.ariaLabel":"Zoom Out","controls.fitView.ariaLabel":"Fit View","controls.interactive.ariaLabel":"Toggle Interactivity","minimap.ariaLabel":"Mini Map","handle.ariaLabel":"Handle"},So;(function(t){t.Strict="strict",t.Loose="loose"})(So||(So={}));var Un;(function(t){t.Free="free",t.Vertical="vertical",t.Horizontal="horizontal"})(Un||(Un={}));var ia;(function(t){t.Partial="partial",t.Full="full"})(ia||(ia={}));var lh={inProgress:!1,isValid:null,from:null,fromHandle:null,fromPosition:null,fromNode:null,to:null,toHandle:null,toPosition:null,toNode:null,pointer:null},rn;(function(t){t.Bezier="default",t.Straight="straight",t.Step="step",t.SmoothStep="smoothstep",t.SimpleBezier="simplebezier"})(rn||(rn={}));var pl;(function(t){t.Arrow="arrow",t.ArrowClosed="arrowclosed"})(pl||(pl={}));var G;(function(t){t.Left="left",t.Top="top",t.Right="right",t.Bottom="bottom"})(G||(G={}));var Y1={[G.Left]:G.Right,[G.Right]:G.Left,[G.Top]:G.Bottom,[G.Bottom]:G.Top};function ih(t){return t===null?null:t?"valid":"invalid"}var rh=t=>"id"in t&&"source"in t&&"target"in t,F1=t=>"id"in t&&"position"in t&&!("source"in t)&&!("target"in t),uh=t=>"id"in t&&"internals"in t&&!("source"in t)&&!("target"in t);var Wi=(t,e=[0,0])=>{let{width:n,height:o}=un(t),a=t.origin??e,l=n*a[0],i=o*a[1];return{x:t.position.x-l,y:t.position.y-i}},ch=(t,e={nodeOrigin:[0,0]})=>{if(t.length===0)return{x:0,y:0,width:0,height:0};let n=t.reduce((o,a)=>{let l=typeof a=="string",i=!e.nodeLookup&&!l?a:void 0;e.nodeLookup&&(i=l?e.nodeLookup.get(a):uh(a)?a:e.nodeLookup.get(a.id));let r=i?hc(i,e.nodeOrigin):{x:0,y:0,x2:0,y2:0};return mc(o,r)},{x:1/0,y:1/0,x2:-1/0,y2:-1/0});return yc(n)},yl=(t,e={})=>{let n={x:1/0,y:1/0,x2:-1/0,y2:-1/0},o=!1;return t.forEach(a=>{(e.filter===void 0||e.filter(a))&&(n=mc(n,hc(a)),o=!0)}),o?yc(n):{x:0,y:0,width:0,height:0}},pc=(t,e,[n,o,a]=[0,0,1],l=!1,i=!1)=>{let r={...fa(e,[n,o,a]),width:e.width/a,height:e.height/a},u=[];for(let s of t.values()){let{measured:c,selectable:d=!0,hidden:f=!1}=s;if(i&&!d||f)continue;let p=c.width??s.width??s.initialWidth??null,y=c.height??s.height??s.initialHeight??null,b=vl(r,sa(s)),x=(p??0)*(y??0),g=l&&b>0;(!s.internals.handleBounds||g||b>=x||s.dragging)&&u.push(s)}return u},P1=(t,e)=>{let n=new Set;return t.forEach(o=>{n.add(o.id)}),e.filter(o=>n.has(o.source)||n.has(o.target))};function DM(t,e){let n=new Map,o=e?.nodes?new Set(e.nodes.map(a=>a.id)):null;return t.forEach(a=>{a.measured.width&&a.measured.height&&(e?.includeHiddenNodes||!a.hidden)&&(!o||o.has(a.id))&&n.set(a.id,a)}),n}async function tb({nodes:t,width:e,height:n,panZoom:o,minZoom:a,maxZoom:l},i){if(t.size===0)return!0;let r=DM(t,i),u=yl(r),s=Fi(u,e,n,i?.minZoom??a,i?.maxZoom??l,i?.padding??.1);return await o.setViewport(s,{duration:i?.duration,ease:i?.ease,interpolate:i?.interpolate}),!0}function sh({nodeId:t,nextPosition:e,nodeLookup:n,nodeOrigin:o=[0,0],nodeExtent:a,onError:l}){let i=n.get(t),r=i.parentId?n.get(i.parentId):void 0,{x:u,y:s}=r?r.internals.positionAbsolute:{x:0,y:0},c=i.origin??o,d=i.extent||a;if(i.extent==="parent"&&!i.expandParent)if(!r)l?.("005",Me.error005());else{let p=r.measured.width,y=r.measured.height;p&&y&&(d=[[u,s],[u+p,s+y]])}else r&&ca(i.extent)&&(d=[[i.extent[0][0]+u,i.extent[0][1]+s],[i.extent[1][0]+u,i.extent[1][1]+s]]);let f=ca(d)?ra(e,d,i.measured):e;return(i.measured.width===void 0||i.measured.height===void 0)&&l?.("015",Me.error015()),{position:{x:f.x-u+(i.measured.width??0)*c[0],y:f.y-s+(i.measured.height??0)*c[1]},positionAbsolute:f}}async function eb({nodesToRemove:t=[],edgesToRemove:e=[],nodes:n,edges:o,onBeforeDelete:a}){let l=new Set(t.map(f=>f.id)),i=[];for(let f of n){if(f.deletable===!1)continue;let p=l.has(f.id),y=!p&&f.parentId&&i.find(b=>b.id===f.parentId);(p||y)&&i.push(f)}let r=new Set(e.map(f=>f.id)),u=o.filter(f=>f.deletable!==!1),c=P1(i,u);for(let f of u)r.has(f.id)&&!c.find(y=>y.id===f.id)&&c.push(f);if(!a)return{edges:c,nodes:i};let d=await a({nodes:i,edges:c});return typeof d=="boolean"?d?{edges:c,nodes:i}:{edges:[],nodes:[]}:d}var gl=(t,e=0,n=1)=>Math.min(Math.max(t,e),n),ra=(t={x:0,y:0},e,n)=>({x:gl(t.x,e[0][0],e[1][0]-(n?.width??0)),y:gl(t.y,e[0][1],e[1][1]-(n?.height??0))});function nb(t,e,n){let{width:o,height:a}=un(n),{x:l,y:i}=n.internals.positionAbsolute;return ra(t,[[l,i],[l+o,i+a]],e)}var V1=(t,e,n)=>t<e?gl(Math.abs(t-e),1,e)/e:t>n?-gl(Math.abs(t-n),1,e)/e:0,gc=(t,e,n=15,o=40)=>{let a=V1(t.x,o,e.width-o)*n,l=V1(t.y,o,e.height-o)*n;return[a,l]},mc=(t,e)=>({x:Math.min(t.x,e.x),y:Math.min(t.y,e.y),x2:Math.max(t.x2,e.x2),y2:Math.max(t.y2,e.y2)}),nh=({x:t,y:e,width:n,height:o})=>({x:t,y:e,x2:t+n,y2:e+o}),yc=({x:t,y:e,x2:n,y2:o})=>({x:t,y:e,width:n-t,height:o-e}),sa=(t,e=[0,0])=>{let{x:n,y:o}=uh(t)?t.internals.positionAbsolute:Wi(t,e);return{x:n,y:o,width:t.measured?.width??t.width??t.initialWidth??0,height:t.measured?.height??t.height??t.initialHeight??0}},hc=(t,e=[0,0])=>{let{x:n,y:o}=uh(t)?t.internals.positionAbsolute:Wi(t,e);return{x:n,y:o,x2:n+(t.measured?.width??t.width??t.initialWidth??0),y2:o+(t.measured?.height??t.height??t.initialHeight??0)}},fh=(t,e)=>yc(mc(nh(t),nh(e))),vl=(t,e)=>{let n=Math.max(0,Math.min(t.x+t.width,e.x+e.width)-Math.max(t.x,e.x)),o=Math.max(0,Math.min(t.y+t.height,e.y+e.height)-Math.max(t.y,e.y));return Math.ceil(n*o)},dh=t=>Ye(t.width)&&Ye(t.height)&&Ye(t.x)&&Ye(t.y),Ye=t=>!isNaN(t)&&isFinite(t),hh=(t,e)=>(n,o)=>{},bl=(t,e=[1,1])=>({x:e[0]*Math.round(t.x/e[0]),y:e[1]*Math.round(t.y/e[1])}),fa=({x:t,y:e},[n,o,a],l=!1,i=[1,1])=>{let r={x:(t-n)/a,y:(e-o)/a};return l?bl(r,i):r},ua=({x:t,y:e},[n,o,a])=>({x:t*a+n,y:e*a+o});function dl(t,e){if(typeof t=="number")return Math.floor((e-e/(1+t))*.5);if(typeof t=="string"&&t.endsWith("px")){let n=parseFloat(t);if(!Number.isNaN(n))return Math.floor(n)}if(typeof t=="string"&&t.endsWith("%")){let n=parseFloat(t);if(!Number.isNaN(n))return Math.floor(e*n*.01)}return console.error(`The padding value "${t}" is invalid. Please provide a number or a string with a valid unit (px or %).`),0}function HM(t,e,n){if(typeof t=="string"||typeof t=="number"){let o=dl(t,n),a=dl(t,e);return{top:o,right:a,bottom:o,left:a,x:a*2,y:o*2}}if(typeof t=="object"){let o=dl(t.top??t.y??0,n),a=dl(t.bottom??t.y??0,n),l=dl(t.left??t.x??0,e),i=dl(t.right??t.x??0,e);return{top:o,right:i,bottom:a,left:l,x:l+i,y:o+a}}return{top:0,right:0,bottom:0,left:0,x:0,y:0}}function RM(t,e,n,o,a,l){let{x:i,y:r}=ua(t,[e,n,o]),{x:u,y:s}=ua({x:t.x+t.width,y:t.y+t.height},[e,n,o]),c=a-u,d=l-s;return{left:Math.floor(i),top:Math.floor(r),right:Math.floor(c),bottom:Math.floor(d)}}var Fi=(t,e,n,o,a,l)=>{let i=HM(l,e,n),r=(e-i.x)/t.width,u=(n-i.y)/t.height,s=Math.min(r,u),c=gl(s,o,a),d=t.x+t.width/2,f=t.y+t.height/2,p=e/2-d*c,y=n/2-f*c,b=RM(t,p,y,c,e,n),x={left:Math.min(b.left-i.left,0),top:Math.min(b.top-i.top,0),right:Math.min(b.right-i.right,0),bottom:Math.min(b.bottom-i.bottom,0)};return{x:p-x.left+x.right,y:y-x.top+x.bottom,zoom:c}},xl=()=>typeof navigator<"u"&&navigator?.userAgent?.indexOf("Mac")>=0;function ca(t){return t!=null&&t!=="parent"}function un(t){return{width:t.measured?.width??t.width??t.initialWidth??0,height:t.measured?.height??t.height??t.initialHeight??0}}function ph(t){return(t.measured?.width??t.width??t.initialWidth)!==void 0&&(t.measured?.height??t.height??t.initialHeight)!==void 0}function gh(t,e={width:0,height:0},n,o,a){let l={...t},i=o.get(n);if(i){let r=i.origin||a;l.x+=i.internals.positionAbsolute.x-(e.width??0)*r[0],l.y+=i.internals.positionAbsolute.y-(e.height??0)*r[1]}return l}function mh(t,e){if(t.size!==e.size)return!1;for(let n of t)if(!e.has(n))return!1;return!0}function ob(){let t,e;return{promise:new Promise((o,a)=>{t=o,e=a}),resolve:t,reject:e}}function ab(t){return{...ah,...t||{}}}function Ii(t,{snapGrid:e=[0,0],snapToGrid:n=!1,transform:o,containerBounds:a}){let{x:l,y:i}=Ve(t),r=fa({x:l-(a?.left??0),y:i-(a?.top??0)},o),{x:u,y:s}=n?bl(r,e):r;return{xSnapped:u,ySnapped:s,...r}}var vc=t=>({width:t.offsetWidth,height:t.offsetHeight}),yh=t=>t?.getRootNode?.()||window?.document,BM=["INPUT","SELECT","TEXTAREA"];function vh(t){let e=t.composedPath?.()?.[0]||t.target;return e?.nodeType!==1?!1:BM.includes(e.nodeName)||e.hasAttribute("contenteditable")||!!e.closest(".nokey")}var bh=t=>"clientX"in t,Ve=(t,e)=>{let n=bh(t),o=n?t.clientX:t.touches?.[0].clientX,a=n?t.clientY:t.touches?.[0].clientY;return{x:o-(e?.left??0),y:a-(e?.top??0)}},q1=(t,e,n,o,a)=>{let l=e.querySelectorAll(`.${t}`);return!l||!l.length?null:Array.from(l).map(i=>{let r=i.getBoundingClientRect();return{id:i.getAttribute("data-handleid"),type:t,nodeId:a,position:i.getAttribute("data-handlepos"),x:(r.left-n.left)/o,y:(r.top-n.top)/o,...vc(i)}})};function bc({sourceX:t,sourceY:e,targetX:n,targetY:o,sourceControlX:a,sourceControlY:l,targetControlX:i,targetControlY:r}){let u=t*.125+a*.375+i*.375+n*.125,s=e*.125+l*.375+r*.375+o*.125,c=Math.abs(u-t),d=Math.abs(s-e);return[u,s,c,d]}function fc(t,e){return t>=0?.5*t:e*25*Math.sqrt(-t)}function X1({pos:t,x1:e,y1:n,x2:o,y2:a,c:l}){switch(t){case G.Left:return[e-fc(e-o,l),n];case G.Right:return[e+fc(o-e,l),n];case G.Top:return[e,n-fc(n-a,l)];case G.Bottom:return[e,n+fc(a-n,l)]}}function xc({sourceX:t,sourceY:e,sourcePosition:n=G.Bottom,targetX:o,targetY:a,targetPosition:l=G.Top,curvature:i=.25}){let[r,u]=X1({pos:n,x1:t,y1:e,x2:o,y2:a,c:i}),[s,c]=X1({pos:l,x1:o,y1:a,x2:t,y2:e,c:i}),[d,f,p,y]=bc({sourceX:t,sourceY:e,targetX:o,targetY:a,sourceControlX:r,sourceControlY:u,targetControlX:s,targetControlY:c});return[`M${t},${e} C${r},${u} ${s},${c} ${o},${a}`,d,f,p,y]}function xh({sourceX:t,sourceY:e,targetX:n,targetY:o}){let a=Math.abs(n-t)/2,l=n<t?n+a:n-a,i=Math.abs(o-e)/2,r=o<e?o+i:o-i;return[l,r,a,i]}function lb({sourceNode:t,targetNode:e,selected:n=!1,zIndex:o=0,elevateOnSelect:a=!1,zIndexMode:l="basic"}){if(l==="manual")return o;let i=a&&n?o+1e3:o,r=Math.max(t.parentId||a&&t.selected?t.internals.z:0,e.parentId||a&&e.selected?e.internals.z:0);return i+r}function ib({sourceNode:t,targetNode:e,width:n,height:o,transform:a}){let l=mc(hc(t),hc(e));l.x===l.x2&&(l.x2+=1),l.y===l.y2&&(l.y2+=1);let i={x:-a[0]/a[2],y:-a[1]/a[2],width:n/a[2],height:o/a[2]};return vl(i,yc(l))>0}var kM=({source:t,sourceHandle:e,target:n,targetHandle:o})=>`xy-edge__${t}${e||""}-${n}${o||""}`,LM=(t,e)=>e.some(n=>n.source===t.source&&n.target===t.target&&(n.sourceHandle===t.sourceHandle||!n.sourceHandle&&!t.sourceHandle)&&(n.targetHandle===t.targetHandle||!n.targetHandle&&!t.targetHandle)),rb=(t,e,n={})=>{if(!t.source||!t.target)return n.onError?.("006",Me.error006()),e;let o=n.getEdgeId||kM,a;return rh(t)?a={...t}:a={...t,id:o(t)},LM(a,e)?e:(a.sourceHandle===null&&delete a.sourceHandle,a.targetHandle===null&&delete a.targetHandle,e.concat(a))};function Sc({sourceX:t,sourceY:e,targetX:n,targetY:o}){let[a,l,i,r]=xh({sourceX:t,sourceY:e,targetX:n,targetY:o});return[`M ${t},${e}L ${n},${o}`,a,l,i,r]}var Z1={[G.Left]:{x:-1,y:0},[G.Right]:{x:1,y:0},[G.Top]:{x:0,y:-1},[G.Bottom]:{x:0,y:1}},UM=({source:t,sourcePosition:e=G.Bottom,target:n})=>e===G.Left||e===G.Right?t.x<n.x?{x:1,y:0}:{x:-1,y:0}:t.y<n.y?{x:0,y:1}:{x:0,y:-1},G1=(t,e)=>Math.sqrt(Math.pow(e.x-t.x,2)+Math.pow(e.y-t.y,2));function YM({source:t,sourcePosition:e=G.Bottom,target:n,targetPosition:o=G.Top,center:a,offset:l,stepPosition:i}){let r=Z1[e],u=Z1[o],s={x:t.x+r.x*l,y:t.y+r.y*l},c={x:n.x+u.x*l,y:n.y+u.y*l},d=UM({source:s,sourcePosition:e,target:c}),f=d.x!==0?"x":"y",p=d[f],y=[],b,x,g={x:0,y:0},m={x:0,y:0},[,,h,v]=xh({sourceX:t.x,sourceY:t.y,targetX:n.x,targetY:n.y});if(r[f]*u[f]===-1){f==="x"?(b=a.x??s.x+(c.x-s.x)*i,x=a.y??(s.y+c.y)/2):(b=a.x??(s.x+c.x)/2,x=a.y??s.y+(c.y-s.y)*i);let N=[{x:b,y:s.y},{x:b,y:c.y}],M=[{x:s.x,y:x},{x:c.x,y:x}];r[f]===p?y=f==="x"?N:M:y=f==="x"?M:N}else{let N=[{x:s.x,y:c.y}],M=[{x:c.x,y:s.y}];if(f==="x"?y=r.x===p?M:N:y=r.y===p?N:M,e===o){let S=Math.abs(t[f]-n[f]);if(S<=l){let A=Math.min(l-1,l-S);r[f]===p?g[f]=(s[f]>t[f]?-1:1)*A:m[f]=(c[f]>n[f]?-1:1)*A}}if(e!==o){let S=f==="x"?"y":"x",A=r[f]===u[S],z=s[S]>c[S],T=s[S]<c[S];(r[f]===1&&(!A&&z||A&&T)||r[f]!==1&&(!A&&T||A&&z))&&(y=f==="x"?N:M)}let R={x:s.x+g.x,y:s.y+g.y},C={x:c.x+m.x,y:c.y+m.y},k=Math.max(Math.abs(R.x-y[0].x),Math.abs(C.x-y[0].x)),V=Math.max(Math.abs(R.y-y[0].y),Math.abs(C.y-y[0].y));k>=V?(b=(R.x+C.x)/2,x=y[0].y):(b=y[0].x,x=(R.y+C.y)/2)}let _={x:s.x+g.x,y:s.y+g.y},E={x:c.x+m.x,y:c.y+m.y};return[[t,..._.x!==y[0].x||_.y!==y[0].y?[_]:[],...y,...E.x!==y[y.length-1].x||E.y!==y[y.length-1].y?[E]:[],n],b,x,h,v]}function VM(t,e,n,o){let a=Math.min(G1(t,e)/2,G1(e,n)/2,o),{x:l,y:i}=e;if(t.x===l&&l===n.x||t.y===i&&i===n.y)return`L${l} ${i}`;if(t.y===i){let s=t.x<n.x?-1:1,c=t.y<n.y?1:-1;return`L ${l+a*s},${i}Q ${l},${i} ${l},${i+a*c}`}let r=t.x<n.x?1:-1,u=t.y<n.y?-1:1;return`L ${l},${i+a*u}Q ${l},${i} ${l+a*r},${i}`}function da({sourceX:t,sourceY:e,sourcePosition:n=G.Bottom,targetX:o,targetY:a,targetPosition:l=G.Top,borderRadius:i=5,centerX:r,centerY:u,offset:s=20,stepPosition:c=.5}){let[d,f,p,y,b]=YM({source:{x:t,y:e},sourcePosition:n,target:{x:o,y:a},targetPosition:l,center:{x:r,y:u},offset:s,stepPosition:c}),x=`M${d[0].x} ${d[0].y}`;for(let g=1;g<d.length-1;g++)x+=VM(d[g-1],d[g],d[g+1],i);return x+=`L${d[d.length-1].x} ${d[d.length-1].y}`,[x,f,p,y,b]}function Q1(t){return t&&!!(t.internals.handleBounds||t.handles?.length)&&!!(t.measured.width||t.width||t.initialWidth)}function ub(t){let{sourceNode:e,targetNode:n}=t;if(!Q1(e)||!Q1(n))return null;let o=e.internals.handleBounds||j1(e.handles),a=n.internals.handleBounds||j1(n.handles),l=K1(o?.source??[],t.sourceHandle),i=K1(t.connectionMode===So.Strict?a?.target??[]:(a?.target??[]).concat(a?.source??[]),t.targetHandle);if(!l||!i)return t.onError?.("008",Me.error008(l?"target":"source",{id:t.id,sourceHandle:t.sourceHandle,targetHandle:t.targetHandle})),null;let r=l?.position||G.Bottom,u=i?.position||G.Top,s=_o(e,l,r),c=_o(n,i,u);return{sourceX:s.x,sourceY:s.y,targetX:c.x,targetY:c.y,sourcePosition:r,targetPosition:u}}function j1(t){if(!t)return null;let e=[],n=[];for(let o of t)o.width=o.width??1,o.height=o.height??1,o.type==="source"?e.push(o):o.type==="target"&&n.push(o);return{source:e,target:n}}function _o(t,e,n=G.Left,o=!1){let a=(e?.x??0)+t.internals.positionAbsolute.x,l=(e?.y??0)+t.internals.positionAbsolute.y,{width:i,height:r}=e??un(t);if(o)return{x:a+i/2,y:l+r/2};switch(e?.position??n){case G.Top:return{x:a+i/2,y:l};case G.Right:return{x:a+i,y:l+r/2};case G.Bottom:return{x:a+i/2,y:l+r};case G.Left:return{x:a,y:l+r/2}}}function K1(t,e){return t&&(e?t.find(n=>n.id===e):t[0])||null}function _c(t,e){return t?typeof t=="string"?t:`${e?`${e}__`:""}${Object.keys(t).sort().map(o=>`${o}=${t[o]}`).join("&")}`:""}function cb(t,{id:e,defaultColor:n,defaultMarkerStart:o,defaultMarkerEnd:a}){let l=new Set;return t.reduce((i,r)=>([r.markerStart||o,r.markerEnd||a].forEach(u=>{if(u&&typeof u=="object"){let s=_c(u,e);l.has(s)||(i.push({id:s,color:u.color||n,...u}),l.add(s))}}),i),[]).sort((i,r)=>i.id.localeCompare(r.id))}var sb=1e3,qM=10,Sh={nodeOrigin:[0,0],nodeExtent:ml,elevateNodesOnSelect:!0,zIndexMode:"basic",defaults:{}},XM={...Sh,checkEquality:!0};function _h(t,e){let n={...t};for(let o in e)e[o]!==void 0&&(n[o]=e[o]);return n}function fb(t,e,n){let o=_h(Sh,n);for(let a of t.values())if(a.parentId)Eh(a,t,e,o);else{let l=Wi(a,o.nodeOrigin),i=ca(a.extent)?a.extent:o.nodeExtent,r=ra(l,i,un(a));a.internals.positionAbsolute=r}}function ZM(t,e){if(!t.handles)return t.measured?e?.internals.handleBounds:void 0;let n=[],o=[];for(let a of t.handles){let l={id:a.id,width:a.width??1,height:a.height??1,nodeId:t.id,x:a.x,y:a.y,position:a.position,type:a.type};a.type==="source"?n.push(l):a.type==="target"&&o.push(l)}return{source:n,target:o}}function wh(t){return t==="manual"}function wc(t,e,n,o={}){let a=_h(XM,o),l={i:0},i=new Map(e),r=a?.elevateNodesOnSelect&&!wh(a.zIndexMode)?sb:0,u=t.length>0,s=!1;e.clear(),n.clear();for(let c of t){let d=i.get(c.id);if(a.checkEquality&&c===d?.internals.userNode)e.set(c.id,d);else{let f=Wi(c,a.nodeOrigin),p=ca(c.extent)?c.extent:a.nodeExtent,y=ra(f,p,un(c));d={...a.defaults,...c,measured:{width:c.measured?.width,height:c.measured?.height},internals:{positionAbsolute:y,handleBounds:ZM(c,d),z:db(c,r,a.zIndexMode),userNode:c}},e.set(c.id,d)}(d.measured===void 0||d.measured.width===void 0||d.measured.height===void 0)&&!d.hidden&&(u=!1),c.parentId&&Eh(d,e,n,o,l),s||(s=c.selected??!1)}return{nodesInitialized:u,hasSelectedNodes:s}}function GM(t,e){if(!t.parentId)return;let n=e.get(t.parentId);n?n.set(t.id,t):e.set(t.parentId,new Map([[t.id,t]]))}function Eh(t,e,n,o,a){let{elevateNodesOnSelect:l,nodeOrigin:i,nodeExtent:r,zIndexMode:u}=_h(Sh,o),s=t.parentId,c=e.get(s);if(!c){console.warn(`Parent node ${s} not found. Please make sure that parent nodes are in front of their child nodes in the nodes array.`);return}GM(t,n),a&&!c.parentId&&c.internals.rootParentIndex===void 0&&u==="auto"&&(c.internals.rootParentIndex=++a.i,c.internals.z=c.internals.z+a.i*qM),a&&c.internals.rootParentIndex!==void 0&&(a.i=c.internals.rootParentIndex);let d=l&&!wh(u)?sb:0,{x:f,y:p,z:y}=QM(t,c,i,r,d,u),{positionAbsolute:b}=t.internals,x=f!==b.x||p!==b.y;(x||y!==t.internals.z)&&e.set(t.id,{...t,internals:{...t.internals,positionAbsolute:x?{x:f,y:p}:b,z:y}})}function db(t,e,n){let o=Ye(t.zIndex)?t.zIndex:0;return wh(n)?o:o+(t.selected?e:0)}function QM(t,e,n,o,a,l){let{x:i,y:r}=e.internals.positionAbsolute,u=un(t),s=Wi(t,n),c=ca(t.extent)?ra(s,t.extent,u):s,d=ra({x:i+c.x,y:r+c.y},o,u);t.extent==="parent"&&(d=nb(d,u,e));let f=db(t,a,l),p=e.internals.z??0;return{x:d.x,y:d.y,z:p>=f?p+1:f}}function Ec(t,e,n,o=[0,0]){let a=[],l=new Map;for(let i of t){let r=e.get(i.parentId);if(!r)continue;let u=l.get(i.parentId)?.expandedRect??sa(r),s=fh(u,i.rect);l.set(i.parentId,{expandedRect:s,parent:r})}return l.size>0&&l.forEach(({expandedRect:i,parent:r},u)=>{let s=r.internals.positionAbsolute,c=un(r),d=r.origin??o,f=i.x<s.x?Math.round(Math.abs(s.x-i.x)):0,p=i.y<s.y?Math.round(Math.abs(s.y-i.y)):0,y=Math.max(c.width,Math.round(i.width)),b=Math.max(c.height,Math.round(i.height)),x=(y-c.width)*d[0],g=(b-c.height)*d[1];(f>0||p>0||x||g)&&(a.push({id:u,type:"position",position:{x:r.position.x-f+x,y:r.position.y-p+g}}),n.get(u)?.forEach(m=>{t.some(h=>h.id===m.id)||a.push({id:m.id,type:"position",position:{x:m.position.x+f,y:m.position.y+p}})})),(c.width<i.width||c.height<i.height||f||p)&&a.push({id:u,type:"dimensions",setAttributes:!0,dimensions:{width:y+(f?d[0]*f-x:0),height:b+(p?d[1]*p-g:0)}})}),a}function hb(t,e,n,o,a,l,i){let r=o?.querySelector(".xyflow__viewport"),u=!1;if(!r)return{changes:[],updatedInternals:u};let s=[],c=window.getComputedStyle(r),{m22:d}=new window.DOMMatrixReadOnly(c.transform),f=[];for(let p of t.values()){let y=e.get(p.id);if(!y)continue;if(y.hidden){e.set(y.id,{...y,internals:{...y.internals,handleBounds:void 0}}),u=!0;continue}let b=vc(p.nodeElement),x=y.measured.width!==b.width||y.measured.height!==b.height;if(!!(b.width&&b.height&&(x||!y.internals.handleBounds||p.force))){let m=p.nodeElement.getBoundingClientRect(),h=ca(y.extent)?y.extent:l,{positionAbsolute:v}=y.internals;y.parentId&&y.extent==="parent"?v=nb(v,b,e.get(y.parentId)):h&&(v=ra(v,h,b));let _={...y,measured:b,internals:{...y.internals,positionAbsolute:v,handleBounds:{source:q1("source",p.nodeElement,m,d,y.id),target:q1("target",p.nodeElement,m,d,y.id)}}};e.set(y.id,_),y.parentId&&Eh(_,e,n,{nodeOrigin:a,zIndexMode:i}),u=!0,x&&(s.push({id:y.id,type:"dimensions",dimensions:b}),y.expandParent&&y.parentId&&f.push({id:y.id,parentId:y.parentId,rect:sa(_,a)}))}}if(f.length>0){let p=Ec(f,e,n,a);s.push(...p)}return{changes:s,updatedInternals:u}}async function pb({delta:t,panZoom:e,transform:n,translateExtent:o,width:a,height:l}){if(!e||!t.x&&!t.y)return!1;let i=await e.setViewportConstrained({x:n[0]+t.x,y:n[1]+t.y,zoom:n[2]},[[0,0],[a,l]],o);return!!i&&(i.x!==n[0]||i.y!==n[1]||i.k!==n[2])}function $1(t,e,n,o,a,l){let i=a,r=o.get(i)||new Map;o.set(i,r.set(n,e)),i=`${a}-${t}`;let u=o.get(i)||new Map;if(o.set(i,u.set(n,e)),l){i=`${a}-${t}-${l}`;let s=o.get(i)||new Map;o.set(i,s.set(n,e))}}function Nh(t,e,n){t.clear(),e.clear();for(let o of n){let{source:a,target:l,sourceHandle:i=null,targetHandle:r=null}=o,u={edgeId:o.id,source:a,target:l,sourceHandle:i,targetHandle:r},s=`${a}-${i}--${l}-${r}`,c=`${l}-${r}--${a}-${i}`;$1("source",u,c,t,a,i),$1("target",u,s,t,l,r),e.set(o.id,o)}}function gb(t,e){if(!t.parentId)return!1;let n=e.get(t.parentId);return n?n.selected?!0:gb(n,e):!1}function J1(t,e,n){let o=t;do{if(o?.matches?.(e))return!0;if(o===n)return!1;o=o?.parentElement}while(o);return!1}function jM(t,e,n,o){let a=new Map;for(let[l,i]of t)if((i.selected||i.id===o)&&(!i.parentId||!gb(i,t))&&(i.draggable||e&&typeof i.draggable>"u")){let r=t.get(l);r&&a.set(l,{id:l,position:r.position||{x:0,y:0},distance:{x:n.x-r.internals.positionAbsolute.x,y:n.y-r.internals.positionAbsolute.y},extent:r.extent,parentId:r.parentId,origin:r.origin,expandParent:r.expandParent,internals:{positionAbsolute:r.internals.positionAbsolute||{x:0,y:0}},measured:{width:r.measured.width??0,height:r.measured.height??0}})}return a}function Pd({nodeId:t,dragItems:e,nodeLookup:n,dragging:o=!0}){let a=[];for(let[i,r]of e){let u=n.get(i)?.internals.userNode;u&&a.push({...u,position:r.position,dragging:o})}if(!t)return[a[0],a];let l=n.get(t)?.internals.userNode;return[l?{...l,position:e.get(t)?.position||l.position,dragging:o}:a[0],a]}function KM({dragItems:t,snapGrid:e,x:n,y:o}){let a=t.values().next().value;if(!a)return null;let l={x:n-a.distance.x,y:o-a.distance.y},i=bl(l,e);return{x:i.x-l.x,y:i.y-l.y}}function mb({onNodeMouseDown:t,getStoreItems:e,onDragStart:n,onDrag:o,onDragStop:a}){let l={x:null,y:null},i=0,r=new Map,u=!1,s={x:0,y:0},c=null,d=!1,f=null,p=!1,y=!1,b=null;function x({noDragClassName:m,handleSelector:h,domNode:v,isSelectable:_,nodeId:E,nodeClickDistance:w=0}){f=Qt(v);function N({x:k,y:V}){let{nodeLookup:S,nodeExtent:A,snapGrid:z,snapToGrid:T,nodeOrigin:B,onNodeDrag:H,onSelectionDrag:X,onError:Z,updateNodePositions:q}=e();l={x:k,y:V};let K=!1,j=r.size>1,I=j&&A?nh(yl(r)):null,ot=j&&T?KM({dragItems:r,snapGrid:z,x:k,y:V}):null;for(let[J,U]of r){if(!S.has(J))continue;let Q={x:k-U.distance.x,y:V-U.distance.y};T&&(Q=ot?{x:Math.round(Q.x+ot.x),y:Math.round(Q.y+ot.y)}:bl(Q,z));let nt=null;if(j&&A&&!U.extent&&I){let{positionAbsolute:W}=U.internals,ct=W.x-I.x+A[0][0],dt=W.x+U.measured.width-I.x2+A[1][0],Dt=W.y-I.y+A[0][1],ie=W.y+U.measured.height-I.y2+A[1][1];nt=[[ct,Dt],[dt,ie]]}let{position:tt,positionAbsolute:$}=sh({nodeId:J,nextPosition:Q,nodeLookup:S,nodeExtent:nt||A,nodeOrigin:B,onError:Z});K=K||U.position.x!==tt.x||U.position.y!==tt.y,U.position=tt,U.internals.positionAbsolute=$}if(y=y||K,!!K&&(q(r,!0),b&&(o||H||!E&&X))){let[J,U]=Pd({nodeId:E,dragItems:r,nodeLookup:S});o?.(b,r,J,U),H?.(b,J,U),E||X?.(b,U)}}async function M(){if(!c)return;let{transform:k,panBy:V,autoPanSpeed:S,autoPanOnNodeDrag:A}=e();if(!A){u=!1,cancelAnimationFrame(i);return}let[z,T]=gc(s,c,S);(z!==0||T!==0)&&(l.x=(l.x??0)-z/k[2],l.y=(l.y??0)-T/k[2],await V({x:z,y:T})&&N(l)),i=requestAnimationFrame(M)}function R(k){let{nodeLookup:V,multiSelectionActive:S,nodesDraggable:A,transform:z,snapGrid:T,snapToGrid:B,selectNodesOnDrag:H,onNodeDragStart:X,onSelectionDragStart:Z,unselectNodesAndEdges:q}=e();d=!0,(!H||!_)&&!S&&E&&(V.get(E)?.selected||q()),_&&H&&E&&t?.(E);let K=Ii(k.sourceEvent,{transform:z,snapGrid:T,snapToGrid:B,containerBounds:c});if(l=K,r=jM(V,A,K,E),r.size>0&&(n||X||!E&&Z)){let[j,I]=Pd({nodeId:E,dragItems:r,nodeLookup:V});n?.(k.sourceEvent,r,j,I),X?.(k.sourceEvent,j,I),E||Z?.(k.sourceEvent,I)}}let C=Zu().clickDistance(w).on("start",k=>{let{domNode:V,nodeDragThreshold:S,transform:A,snapGrid:z,snapToGrid:T}=e();c=V?.getBoundingClientRect()||null,p=!1,y=!1,b=k.sourceEvent,S===0&&R(k),l=Ii(k.sourceEvent,{transform:A,snapGrid:z,snapToGrid:T,containerBounds:c}),s=Ve(k.sourceEvent,c)}).on("drag",k=>{let{autoPanOnNodeDrag:V,transform:S,snapGrid:A,snapToGrid:z,nodeDragThreshold:T,nodeLookup:B}=e(),H=Ii(k.sourceEvent,{transform:S,snapGrid:A,snapToGrid:z,containerBounds:c});if(b=k.sourceEvent,(k.sourceEvent.type==="touchmove"&&k.sourceEvent.touches.length>1||E&&!B.has(E))&&(p=!0),!p){if(!u&&V&&d&&(u=!0,M()),!d){let X=Ve(k.sourceEvent,c),Z=X.x-s.x,q=X.y-s.y;Math.sqrt(Z*Z+q*q)>T&&R(k)}(l.x!==H.xSnapped||l.y!==H.ySnapped)&&r&&d&&(s=Ve(k.sourceEvent,c),N(H))}}).on("end",k=>{if(!d||p){p&&r.size>0&&e().updateNodePositions(r,!1);return}if(u=!1,d=!1,cancelAnimationFrame(i),r.size>0){let{nodeLookup:V,updateNodePositions:S,onNodeDragStop:A,onSelectionDragStop:z}=e();if(y&&(S(r,!1),y=!1),a||A||!E&&z){let[T,B]=Pd({nodeId:E,dragItems:r,nodeLookup:V,dragging:!1});a?.(k.sourceEvent,r,T,B),A?.(k.sourceEvent,T,B),E||z?.(k.sourceEvent,B)}}}).filter(k=>{let V=k.target;return!k.button&&(!m||!J1(V,`.${m}`,v))&&(!h||J1(V,h,v))});f.call(C)}function g(){f?.on(".drag",null)}return{update:x,destroy:g}}function $M(t,e,n){let o=[],a={x:t.x-n,y:t.y-n,width:n*2,height:n*2};for(let l of e.values())vl(a,sa(l))>0&&o.push(l);return o}var JM=250;function IM(t,e,n,o){let a=[],l=1/0,i=$M(t,n,e+JM);for(let r of i){let u=[...r.internals.handleBounds?.source??[],...r.internals.handleBounds?.target??[]];for(let s of u){if(o.nodeId===s.nodeId&&o.type===s.type&&o.id===s.id)continue;let{x:c,y:d}=_o(r,s,s.position,!0),f=Math.sqrt(Math.pow(c-t.x,2)+Math.pow(d-t.y,2));f>e||(f<l?(a=[{...s,x:c,y:d}],l=f):f===l&&a.push({...s,x:c,y:d}))}}if(!a.length)return null;if(a.length>1){let r=o.type==="source"?"target":"source";return a.find(u=>u.type===r)??a[0]}return a[0]}function yb(t,e,n,o,a,l=!1){let i=o.get(t);if(!i)return null;let r=a==="strict"?i.internals.handleBounds?.[e]:[...i.internals.handleBounds?.source??[],...i.internals.handleBounds?.target??[]],u=(n?r?.find(s=>s.id===n):r?.[0])??null;return u&&l?{...u,..._o(i,u,u.position,!0)}:u}function vb(t,e){return t||(e?.classList.contains("target")?"target":e?.classList.contains("source")?"source":null)}function WM(t,e){let n=null;return e?n=!0:t&&!e&&(n=!1),n}var bb=()=>!0;function FM(t,{connectionMode:e,connectionRadius:n,handleId:o,nodeId:a,edgeUpdaterType:l,isTarget:i,domNode:r,nodeLookup:u,lib:s,autoPanOnConnect:c,flowId:d,panBy:f,cancelConnection:p,onConnectStart:y,onConnect:b,onConnectEnd:x,isValidConnection:g=bb,onReconnectEnd:m,updateConnection:h,getTransform:v,getFromHandle:_,autoPanSpeed:E,dragThreshold:w=1,handleDomNode:N}){let M=yh(t.target),R=0,C,{x:k,y:V}=Ve(t),S=vb(l,N),A=r?.getBoundingClientRect(),z=!1;if(!A||!S)return;let T=yb(a,S,o,u,e);if(!T)return;let B=Ve(t,A),H=!1,X=null,Z=!1,q=null;function K(){if(!c||!A)return;let[tt,$]=gc(B,A,E);f({x:tt,y:$}),R=requestAnimationFrame(K)}let j={...T,nodeId:a,type:S,position:T.position},I=u.get(a),J={inProgress:!0,isValid:null,from:_o(I,j,G.Left,!0),fromHandle:j,fromPosition:j.position,fromNode:I,to:B,toHandle:null,toPosition:Y1[j.position],toNode:null,pointer:B};function U(){z=!0,h(J),y?.(t,{nodeId:a,handleId:o,handleType:S})}w===0&&U();function Q(tt){if(!z){let{x:ie,y:cn}=Ve(tt),Je=ie-k,Ie=cn-V;if(!(Je*Je+Ie*Ie>w*w))return;U()}if(!_()||!j){nt(tt);return}let $=v();B=Ve(tt,A),C=IM(fa(B,$,!1,[1,1]),n,u,j),H||(K(),H=!0);let W=xb(tt,{handle:C,connectionMode:e,fromNodeId:a,fromHandleId:o,fromType:i?"target":"source",isValidConnection:g,doc:M,lib:s,flowId:d,nodeLookup:u});q=W.handleDomNode,X=W.connection,Z=WM(!!C,W.isValid);let ct=u.get(a),dt=ct?_o(ct,j,G.Left,!0):J.from,Dt={...J,from:dt,isValid:Z,to:W.toHandle&&Z?ua({x:W.toHandle.x,y:W.toHandle.y},$):B,toHandle:W.toHandle,toPosition:Z&&W.toHandle?W.toHandle.position:Y1[j.position],toNode:W.toHandle?u.get(W.toHandle.nodeId):null,pointer:B};h(Dt),J=Dt}function nt(tt){if(!("touches"in tt&&tt.touches.length>0)){if(z){(C||q)&&X&&Z&&b?.(X);let{inProgress:$,...W}=J,ct={...W,toPosition:J.toHandle?J.toPosition:null};x?.(tt,ct),l&&m?.(tt,ct)}p(),cancelAnimationFrame(R),H=!1,Z=!1,X=null,q=null,M.removeEventListener("mousemove",Q),M.removeEventListener("mouseup",nt),M.removeEventListener("touchmove",Q),M.removeEventListener("touchend",nt)}}M.addEventListener("mousemove",Q),M.addEventListener("mouseup",nt),M.addEventListener("touchmove",Q),M.addEventListener("touchend",nt)}function xb(t,{handle:e,connectionMode:n,fromNodeId:o,fromHandleId:a,fromType:l,doc:i,lib:r,flowId:u,isValidConnection:s=bb,nodeLookup:c}){let d=l==="target",f=e?i.querySelector(`.${r}-flow__handle[data-id="${u}-${e?.nodeId}-${e?.id}-${e?.type}"]`):null,{x:p,y}=Ve(t),b=i.elementFromPoint(p,y),x=b?.classList.contains(`${r}-flow__handle`)?b:f,g={handleDomNode:x,isValid:!1,connection:null,toHandle:null};if(x){let m=vb(void 0,x),h=x.getAttribute("data-nodeid"),v=x.getAttribute("data-handleid"),_=x.classList.contains("connectable"),E=x.classList.contains("connectableend");if(!h||!m)return g;let w={source:d?h:o,sourceHandle:d?v:a,target:d?o:h,targetHandle:d?a:v};g.connection=w;let M=_&&E&&(n===So.Strict?d&&m==="source"||!d&&m==="target":h!==o||v!==a);g.isValid=M&&s(w),g.toHandle=yb(h,m,v,c,n,!0)}return g}var Nc={onPointerDown:FM,isValid:xb};function Sb({domNode:t,panZoom:e,getTransform:n,getViewScale:o}){let a=Qt(t);function l({translateExtent:r,width:u,height:s,zoomStep:c=1,pannable:d=!0,zoomable:f=!0,inversePan:p=!1}){let y=h=>{if(h.sourceEvent.type!=="wheel"||!e)return;let v=n(),_=h.sourceEvent.ctrlKey&&xl()?10:1,E=-h.sourceEvent.deltaY*(h.sourceEvent.deltaMode===1?.05:h.sourceEvent.deltaMode?1:.002)*c,w=v[2]*Math.pow(2,E*_);e.scaleTo(w)},b=[0,0],x=h=>{(h.sourceEvent.type==="mousedown"||h.sourceEvent.type==="touchstart")&&(b=[h.sourceEvent.clientX??h.sourceEvent.touches[0].clientX,h.sourceEvent.clientY??h.sourceEvent.touches[0].clientY])},g=h=>{let v=n();if(h.sourceEvent.type!=="mousemove"&&h.sourceEvent.type!=="touchmove"||!e)return;let _=[h.sourceEvent.clientX??h.sourceEvent.touches[0].clientX,h.sourceEvent.clientY??h.sourceEvent.touches[0].clientY],E=[_[0]-b[0],_[1]-b[1]];b=_;let w=o()*Math.max(v[2],Math.log(v[2]))*(p?-1:1),N={x:v[0]-E[0]*w,y:v[1]-E[1]*w},M=[[0,0],[u,s]];e.setViewportConstrained({x:N.x,y:N.y,zoom:v[2]},M,r)},m=sc().on("start",x).on("zoom",d?g:null).on("zoom.wheel",f?y:null);a.call(m,{})}function i(){a.on("zoom",null)}return{update:l,destroy:i,pointer:oe}}var Mc=t=>({x:t.x,y:t.y,zoom:t.k}),th=({x:t,y:e,zoom:n})=>la.translate(t,e).scale(n),hl=(t,e)=>t.target.closest(`.${e}`),_b=(t,e)=>e===2&&Array.isArray(t)&&t.includes(2),PM=t=>((t*=2)<=1?t*t*t:(t-=2)*t*t+2)/2,eh=(t,e=0,n=PM,o=()=>{})=>{let a=typeof e=="number"&&e>0;return a||o(),a?t.transition().duration(e).ease(n).on("end",o):t},wb=t=>{let e=t.ctrlKey&&xl()?10:1;return-t.deltaY*(t.deltaMode===1?.05:t.deltaMode?1:.002)*e};function tz({zoomPanValues:t,noWheelClassName:e,d3Selection:n,d3Zoom:o,panOnScrollMode:a,panOnScrollSpeed:l,zoomOnPinch:i,onPanZoomStart:r,onPanZoom:u,onPanZoomEnd:s}){return c=>{if(hl(c,e))return c.ctrlKey&&c.preventDefault(),!1;c.preventDefault(),c.stopImmediatePropagation();let d=n.property("__zoom").k||1;if(c.ctrlKey&&i){let x=oe(c),g=wb(c),m=d*Math.pow(2,g);o.scaleTo(n,m,x,c);return}let f=c.deltaMode===1?20:1,p=a===Un.Vertical?0:c.deltaX*f,y=a===Un.Horizontal?0:c.deltaY*f;!xl()&&c.shiftKey&&a!==Un.Vertical&&(p=c.deltaY*f,y=0),o.translateBy(n,-(p/d)*l,-(y/d)*l,{internal:!0});let b=Mc(n.property("__zoom"));clearTimeout(t.panScrollTimeout),t.isPanScrolling?(u?.(c,b),t.panScrollTimeout=setTimeout(()=>{s?.(c,b),t.isPanScrolling=!1},150)):(t.isPanScrolling=!0,r?.(c,b))}}function ez({noWheelClassName:t,preventScrolling:e,d3ZoomHandler:n}){return function(o,a){let l=o.type==="wheel",i=!e&&l&&!o.ctrlKey,r=hl(o,t);if(o.ctrlKey&&l&&r&&o.preventDefault(),i||r)return null;o.preventDefault(),n.call(this,o,a)}}function nz({zoomPanValues:t,onDraggingChange:e,onPanZoomStart:n}){return o=>{if(o.sourceEvent?.internal)return;let a=Mc(o.transform);t.mouseButton=o.sourceEvent?.button||0,t.isZoomingOrPanning=!0,t.prevViewport=a,o.sourceEvent?.type==="mousedown"&&e(!0),n&&n?.(o.sourceEvent,a)}}function oz({zoomPanValues:t,panOnDrag:e,onPaneContextMenu:n,onTransformChange:o,onPanZoom:a}){return l=>{t.usedRightMouseButton=!!(n&&_b(e,t.mouseButton??0)),l.sourceEvent?.sync||o([l.transform.x,l.transform.y,l.transform.k]),a&&!l.sourceEvent?.internal&&a?.(l.sourceEvent,Mc(l.transform))}}function az({zoomPanValues:t,panOnDrag:e,panOnScroll:n,onDraggingChange:o,onPanZoomEnd:a,onPaneContextMenu:l}){return i=>{if(!i.sourceEvent?.internal&&(t.isZoomingOrPanning=!1,l&&_b(e,t.mouseButton??0)&&!t.usedRightMouseButton&&i.sourceEvent&&l(i.sourceEvent),t.usedRightMouseButton=!1,o(!1),a)){let r=Mc(i.transform);t.prevViewport=r,clearTimeout(t.timerId),t.timerId=setTimeout(()=>{a?.(i.sourceEvent,r)},n?150:0)}}}function lz({zoomActivationKeyPressed:t,zoomOnScroll:e,zoomOnPinch:n,panOnDrag:o,panOnScroll:a,zoomOnDoubleClick:l,userSelectionActive:i,noWheelClassName:r,noPanClassName:u,lib:s,connectionInProgress:c}){return d=>{let f=t||e,p=n&&d.ctrlKey,y=d.type==="wheel";if(d.button===1&&d.type==="mousedown"&&(hl(d,`${s}-flow__node`)||hl(d,`${s}-flow__edge`)))return!0;if(!o&&!f&&!a&&!l&&!n||i||c&&!y||hl(d,r)&&y||hl(d,u)&&(!y||a&&y&&!t)||!n&&d.ctrlKey&&y)return!1;if(!n&&d.type==="touchstart"&&d.touches?.length>1)return d.preventDefault(),!1;if(!f&&!a&&!p&&y||!o&&(d.type==="mousedown"||d.type==="touchstart")||Array.isArray(o)&&!o.includes(d.button)&&d.type==="mousedown")return!1;let b=Array.isArray(o)&&o.includes(d.button)||!d.button||d.button<=1;return(!d.ctrlKey||y)&&b}}function Eb({domNode:t,minZoom:e,maxZoom:n,translateExtent:o,viewport:a,onPanZoom:l,onPanZoomStart:i,onPanZoomEnd:r,onDraggingChange:u}){let s={isZoomingOrPanning:!1,usedRightMouseButton:!1,prevViewport:{},mouseButton:0,timerId:void 0,panScrollTimeout:void 0,isPanScrolling:!1},c=t.getBoundingClientRect(),d=sc().scaleExtent([e,n]).translateExtent(o),f=Qt(t).call(d);m({x:a.x,y:a.y,zoom:gl(a.zoom,e,n)},[[0,0],[c.width,c.height]],o);let p=f.on("wheel.zoom"),y=f.on("dblclick.zoom");d.wheelDelta(wb);async function b(C,k){return f?new Promise(V=>{d?.interpolate(k?.interpolate==="linear"?kn:na).transform(eh(f,k?.duration,k?.ease,()=>V(!0)),C)}):!1}function x({noWheelClassName:C,noPanClassName:k,onPaneContextMenu:V,userSelectionActive:S,panOnScroll:A,panOnDrag:z,panOnScrollMode:T,panOnScrollSpeed:B,preventScrolling:H,zoomOnPinch:X,zoomOnScroll:Z,zoomOnDoubleClick:q,zoomActivationKeyPressed:K,lib:j,onTransformChange:I,connectionInProgress:ot,paneClickDistance:J,selectionOnDrag:U}){S&&!s.isZoomingOrPanning&&g();let Q=A&&!K&&!S;d.clickDistance(U?1/0:!Ye(J)||J<0?0:J);let nt=Q?tz({zoomPanValues:s,noWheelClassName:C,d3Selection:f,d3Zoom:d,panOnScrollMode:T,panOnScrollSpeed:B,zoomOnPinch:X,onPanZoomStart:i,onPanZoom:l,onPanZoomEnd:r}):ez({noWheelClassName:C,preventScrolling:H,d3ZoomHandler:p});f.on("wheel.zoom",nt,{passive:!1});let tt=nz({zoomPanValues:s,onDraggingChange:u,onPanZoomStart:i});d.on("start",tt);let $=oz({zoomPanValues:s,panOnDrag:z,onPaneContextMenu:!!V,onPanZoom:l,onTransformChange:I});d.on("zoom",$);let W=az({zoomPanValues:s,panOnDrag:z,panOnScroll:A,onPaneContextMenu:V,onPanZoomEnd:r,onDraggingChange:u});d.on("end",W);let ct=lz({zoomActivationKeyPressed:K,panOnDrag:z,zoomOnScroll:Z,panOnScroll:A,zoomOnDoubleClick:q,zoomOnPinch:X,userSelectionActive:S,noPanClassName:k,noWheelClassName:C,lib:j,connectionInProgress:ot});d.filter(ct),q?f.on("dblclick.zoom",y):f.on("dblclick.zoom",null)}function g(){d.on("zoom",null)}async function m(C,k,V){let S=th(C),A=d?.constrain()(S,k,V);return A&&await b(A),A}async function h(C,k){let V=th(C);return await b(V,k),V}function v(C){if(f){let k=th(C),V=f.property("__zoom");(V.k!==C.zoom||V.x!==C.x||V.y!==C.y)&&d?.transform(f,k,null,{sync:!0})}}function _(){let C=f?Ji(f.node()):{x:0,y:0,k:1};return{x:C.x,y:C.y,zoom:C.k}}async function E(C,k){return f?new Promise(V=>{d?.interpolate(k?.interpolate==="linear"?kn:na).scaleTo(eh(f,k?.duration,k?.ease,()=>V(!0)),C)}):!1}async function w(C,k){return f?new Promise(V=>{d?.interpolate(k?.interpolate==="linear"?kn:na).scaleBy(eh(f,k?.duration,k?.ease,()=>V(!0)),C)}):!1}function N(C){d?.scaleExtent(C)}function M(C){d?.translateExtent(C)}function R(C){let k=!Ye(C)||C<0?0:C;d?.clickDistance(k)}return{update:x,destroy:g,setViewport:h,setViewportConstrained:m,getViewport:_,scaleTo:E,scaleBy:w,setScaleExtent:N,setTranslateExtent:M,syncViewport:v,setClickDistance:R}}var wo;(function(t){t.Line="line",t.Handle="handle"})(wo||(wo={}));function iz({width:t,prevWidth:e,height:n,prevHeight:o,affectsX:a,affectsY:l}){let i=t-e,r=n-o,u=[i>0?1:i<0?-1:0,r>0?1:r<0?-1:0];return i&&a&&(u[0]=u[0]*-1),r&&l&&(u[1]=u[1]*-1),u}function I1(t){let e=t.includes("right")||t.includes("left"),n=t.includes("bottom")||t.includes("top"),o=t.includes("left"),a=t.includes("top");return{isHorizontal:e,isVertical:n,affectsX:o,affectsY:a}}function bo(t,e){return Math.max(0,e-t)}function xo(t,e){return Math.max(0,t-e)}function dc(t,e,n){return Math.max(0,e-t,t-n)}function W1(t,e){return t?!e:e}function rz(t,e,n,o,a,l,i,r){let{affectsX:u,affectsY:s}=e,{isHorizontal:c,isVertical:d}=e,f=c&&d,{xSnapped:p,ySnapped:y}=n,{minWidth:b,maxWidth:x,minHeight:g,maxHeight:m}=o,{x:h,y:v,width:_,height:E,aspectRatio:w}=t,N=Math.floor(c?p-t.pointerX:0),M=Math.floor(d?y-t.pointerY:0),R=_+(u?-N:N),C=E+(s?-M:M),k=-l[0]*_,V=-l[1]*E,S=dc(R,b,x),A=dc(C,g,m);if(i){let B=0,H=0;u&&N<0?B=bo(h+N+k,i[0][0]):!u&&N>0&&(B=xo(h+R+k,i[1][0])),s&&M<0?H=bo(v+M+V,i[0][1]):!s&&M>0&&(H=xo(v+C+V,i[1][1])),S=Math.max(S,B),A=Math.max(A,H)}if(r){let B=0,H=0;u&&N>0?B=xo(h+N,r[0][0]):!u&&N<0&&(B=bo(h+R,r[1][0])),s&&M>0?H=xo(v+M,r[0][1]):!s&&M<0&&(H=bo(v+C,r[1][1])),S=Math.max(S,B),A=Math.max(A,H)}if(a){if(c){let B=dc(R/w,g,m)*w;if(S=Math.max(S,B),i){let H=0;!u&&!s||u&&!s&&f?H=xo(v+V+R/w,i[1][1])*w:H=bo(v+V+(u?N:-N)/w,i[0][1])*w,S=Math.max(S,H)}if(r){let H=0;!u&&!s||u&&!s&&f?H=bo(v+R/w,r[1][1])*w:H=xo(v+(u?N:-N)/w,r[0][1])*w,S=Math.max(S,H)}}if(d){let B=dc(C*w,b,x)/w;if(A=Math.max(A,B),i){let H=0;!u&&!s||s&&!u&&f?H=xo(h+C*w+k,i[1][0])/w:H=bo(h+(s?M:-M)*w+k,i[0][0])/w,A=Math.max(A,H)}if(r){let H=0;!u&&!s||s&&!u&&f?H=bo(h+C*w,r[1][0])/w:H=xo(h+(s?M:-M)*w,r[0][0])/w,A=Math.max(A,H)}}}M=M+(M<0?A:-A),N=N+(N<0?S:-S),a&&(f?R>C*w?M=(W1(u,s)?-N:N)/w:N=(W1(u,s)?-M:M)*w:c?(M=N/w,s=u):(N=M*w,u=s));let z=u?h+N:h,T=s?v+M:v;return{width:_+(u?-N:N),height:E+(s?-M:M),x:l[0]*N*(u?-1:1)+z,y:l[1]*M*(s?-1:1)+T}}var Nb={width:0,height:0,x:0,y:0},uz={...Nb,pointerX:0,pointerY:0,aspectRatio:1};function cz(t,e,n){let o=e.position.x+t.position.x,a=e.position.y+t.position.y,l=t.measured.width??0,i=t.measured.height??0,r=n[0]*l,u=n[1]*i;return[[o-r,a-u],[o+l-r,a+i-u]]}function Mb({domNode:t,nodeId:e,getStoreItems:n,onChange:o,onEnd:a}){let l=Qt(t),i={controlDirection:I1("bottom-right"),boundaries:{minWidth:0,minHeight:0,maxWidth:Number.MAX_VALUE,maxHeight:Number.MAX_VALUE},resizeDirection:void 0,keepAspectRatio:!1};function r({controlPosition:s,boundaries:c,keepAspectRatio:d,resizeDirection:f,onResizeStart:p,onResize:y,onResizeEnd:b,shouldResize:x}){let g={...Nb},m={...uz};i={boundaries:c,resizeDirection:f,keepAspectRatio:d,controlDirection:I1(s)};let h,v=null,_=[],E,w,N,M=!1,R=Zu().on("start",C=>{let{nodeLookup:k,transform:V,snapGrid:S,snapToGrid:A,nodeOrigin:z,paneDomNode:T}=n();if(h=k.get(e),!h)return;v=T?.getBoundingClientRect()??null;let{xSnapped:B,ySnapped:H}=Ii(C.sourceEvent,{transform:V,snapGrid:S,snapToGrid:A,containerBounds:v});g={width:h.measured.width??0,height:h.measured.height??0,x:h.position.x??0,y:h.position.y??0},m={...g,pointerX:B,pointerY:H,aspectRatio:g.width/g.height},E=void 0,w=ca(h.extent)?h.extent:void 0,h.parentId&&(h.extent==="parent"||h.expandParent)&&(E=k.get(h.parentId)),E&&h.extent==="parent"&&(w=[[0,0],[E.measured.width,E.measured.height]]),_=[],N=void 0;for(let[X,Z]of k)if(Z.parentId===e&&(_.push({id:X,position:{...Z.position},extent:Z.extent}),Z.extent==="parent"||Z.expandParent)){let q=cz(Z,h,Z.origin??z);N?N=[[Math.min(q[0][0],N[0][0]),Math.min(q[0][1],N[0][1])],[Math.max(q[1][0],N[1][0]),Math.max(q[1][1],N[1][1])]]:N=q}p?.(C,{...g})}).on("drag",C=>{let{transform:k,snapGrid:V,snapToGrid:S,nodeOrigin:A}=n(),z=Ii(C.sourceEvent,{transform:k,snapGrid:V,snapToGrid:S,containerBounds:v}),T=[];if(!h)return;let{x:B,y:H,width:X,height:Z}=g,q={},K=h.origin??A,{width:j,height:I,x:ot,y:J}=rz(m,i.controlDirection,z,i.boundaries,i.keepAspectRatio,K,w,N),U=j!==X,Q=I!==Z,nt=ot!==B&&U,tt=J!==H&&Q;if(!nt&&!tt&&!U&&!Q)return;if((nt||tt||K[0]===1||K[1]===1)&&(q.x=nt?ot:g.x,q.y=tt?J:g.y,g.x=q.x,g.y=q.y,_.length>0)){let dt=ot-B,Dt=J-H;for(let ie of _)ie.position={x:ie.position.x-dt+K[0]*(j-X),y:ie.position.y-Dt+K[1]*(I-Z)},T.push(ie)}if((U||Q)&&(q.width=U&&(!i.resizeDirection||i.resizeDirection==="horizontal")?j:g.width,q.height=Q&&(!i.resizeDirection||i.resizeDirection==="vertical")?I:g.height,g.width=q.width,g.height=q.height),E&&h.expandParent){let dt=K[0]*(q.width??0);q.x&&q.x<dt&&(g.x=dt,m.x=m.x-(q.x-dt));let Dt=K[1]*(q.height??0);q.y&&q.y<Dt&&(g.y=Dt,m.y=m.y-(q.y-Dt))}let $=iz({width:g.width,prevWidth:X,height:g.height,prevHeight:Z,affectsX:i.controlDirection.affectsX,affectsY:i.controlDirection.affectsY}),W={...g,direction:$};x?.(C,W)!==!1&&(M=!0,y?.(C,W),o(q,T))}).on("end",C=>{M&&(b?.(C,{...g}),a?.({...g}),M=!1)});l.call(R)}function u(){l.on(".drag",null)}return{update:r,destroy:u}}var Yb=We(hn(),1),Vb=We(Rb(),1);var kb={},Bb=t=>{let e,n=new Set,o=(c,d)=>{let f=typeof c=="function"?c(e):c;if(!Object.is(f,e)){let p=e;e=d??(typeof f!="object"||f===null)?f:Object.assign({},e,f),n.forEach(y=>y(e,p))}},a=()=>e,u={setState:o,getState:a,getInitialState:()=>s,subscribe:c=>(n.add(c),()=>n.delete(c)),destroy:()=>{(kb.env?kb.env.MODE:void 0)!=="production"&&console.warn("[DEPRECATED] The `destroy` method will be unsupported in a future version. Instead use unsubscribe function returned by subscribe. Everything will be garbage-collected if store is garbage-collected."),n.clear()}},s=e=t(o,a,u);return u},Lb=t=>t?Bb(t):Bb;var{useDebugValue:zz}=Yb.default,{useSyncExternalStoreWithSelector:Az}=Vb.default,Cz=t=>t;function zh(t,e=Cz,n){let o=Az(t.subscribe,t.getState,t.getServerState||t.getInitialState,e,n);return zz(o),o}var Ub=(t,e)=>{let n=Lb(t),o=(a,l=e)=>zh(n,a,l);return Object.assign(o,n),o},qb=(t,e)=>t?Ub(t,e):Ub;function Et(t,e){if(Object.is(t,e))return!0;if(typeof t!="object"||t===null||typeof e!="object"||e===null)return!1;if(t instanceof Map&&e instanceof Map){if(t.size!==e.size)return!1;for(let[o,a]of t)if(!Object.is(a,e.get(o)))return!1;return!0}if(t instanceof Set&&e instanceof Set){if(t.size!==e.size)return!1;for(let o of t)if(!e.has(o))return!1;return!0}let n=Object.keys(t);if(n.length!==Object.keys(e).length)return!1;for(let o of n)if(!Object.prototype.hasOwnProperty.call(e,o)||!Object.is(t[o],e[o]))return!1;return!0}var fx=We(Pc()),Oc=(0,D.createContext)(null),Tz=Oc.Provider,dx=Me.error001("react");function ut(t,e){let n=(0,D.useContext)(Oc);if(n===null)throw new Error(dx);return zh(n,t,e)}function zt(){let t=(0,D.useContext)(Oc);if(t===null)throw new Error(dx);return(0,D.useMemo)(()=>({getState:t.getState,setState:t.setState,subscribe:t.subscribe}),[t])}var Xb={display:"none"},Oz={position:"absolute",width:1,height:1,margin:-1,border:0,padding:0,overflow:"hidden",clip:"rect(0px, 0px, 0px, 0px)",clipPath:"inset(100%)"},hx="react-flow__node-desc",px="react-flow__edge-desc",Dz="react-flow__aria-live",Hz=t=>t.ariaLiveMessage,Rz=t=>t.ariaLabelConfig;function Bz({rfId:t}){let e=ut(Hz);return(0,O.jsx)("div",{id:`${Dz}-${t}`,"aria-live":"assertive","aria-atomic":"true",style:Oz,children:e})}function kz({rfId:t,disableKeyboardA11y:e}){let n=ut(Rz);return(0,O.jsxs)(O.Fragment,{children:[(0,O.jsx)("div",{id:`${hx}-${t}`,style:Xb,children:e?n["node.a11yDescription.default"]:n["node.a11yDescription.keyboardDisabled"]}),(0,O.jsx)("div",{id:`${px}-${t}`,style:Xb,children:n["edge.a11yDescription.default"]}),!e&&(0,O.jsx)(Bz,{rfId:t})]})}var Dc=(0,D.forwardRef)(({position:t="top-left",children:e,className:n,style:o,...a},l)=>{let i=`${t}`.split("-");return(0,O.jsx)("div",{className:Tt(["react-flow__panel",n,...i]),style:o,ref:l,...a,children:e})});Dc.displayName="Panel";function Lz({proOptions:t,position:e="bottom-right"}){return t?.hideAttribution?null:(0,O.jsx)(Dc,{position:e,className:"react-flow__attribution","data-message":"Please only hide this attribution when you are subscribed to React Flow Pro: https://pro.reactflow.dev",children:(0,O.jsx)("a",{href:"https://reactflow.dev",target:"_blank",rel:"noopener noreferrer","aria-label":"React Flow attribution",children:"React Flow"})})}var Uz=t=>{let e=[],n=[];for(let[,o]of t.nodeLookup)o.selected&&e.push(o.internals.userNode);for(let[,o]of t.edgeLookup)o.selected&&n.push(o);return{selectedNodes:e,selectedEdges:n}},Ac=t=>t.id;function Yz(t,e){return Et(t.selectedNodes.map(Ac),e.selectedNodes.map(Ac))&&Et(t.selectedEdges.map(Ac),e.selectedEdges.map(Ac))}function Vz({onSelectionChange:t}){let e=zt(),{selectedNodes:n,selectedEdges:o}=ut(Uz,Yz);return(0,D.useEffect)(()=>{let a={nodes:n,edges:o};t?.(a),e.getState().onSelectionChangeHandlers.forEach(l=>l(a))},[n,o,t]),null}var qz=t=>!!t.onSelectionChangeHandlers;function Xz({onSelectionChange:t}){let e=ut(qz);return t||e?(0,O.jsx)(Vz,{onSelectionChange:t}):null}var gx=[0,0],Zz={x:0,y:0,zoom:1},Gz=["nodes","edges","defaultNodes","defaultEdges","onConnect","onConnectStart","onConnectEnd","onClickConnectStart","onClickConnectEnd","nodesDraggable","autoPanOnNodeFocus","nodesConnectable","nodesFocusable","edgesFocusable","edgesReconnectable","elevateNodesOnSelect","elevateEdgesOnSelect","minZoom","maxZoom","nodeExtent","onNodesChange","onEdgesChange","elementsSelectable","connectionMode","snapGrid","snapToGrid","translateExtent","connectOnClick","defaultEdgeOptions","fitView","fitViewOptions","onNodesDelete","onEdgesDelete","onDelete","onNodeDrag","onNodeDragStart","onNodeDragStop","onSelectionDrag","onSelectionDragStart","onSelectionDragStop","onMoveStart","onMove","onMoveEnd","noPanClassName","nodeOrigin","autoPanOnConnect","autoPanOnNodeDrag","onError","connectionRadius","isValidConnection","selectNodesOnDrag","nodeDragThreshold","connectionDragThreshold","onBeforeDelete","debug","autoPanSpeed","ariaLabelConfig","zIndexMode"],Zb=[...Gz,"rfId"],Qz=t=>({setNodes:t.setNodes,setEdges:t.setEdges,setMinZoom:t.setMinZoom,setMaxZoom:t.setMaxZoom,setTranslateExtent:t.setTranslateExtent,setNodeExtent:t.setNodeExtent,reset:t.reset,setDefaultNodesAndEdges:t.setDefaultNodesAndEdges}),Gb={translateExtent:ml,nodeOrigin:gx,minZoom:.5,maxZoom:2,elementsSelectable:!0,noPanClassName:"nopan",rfId:"1"};function jz(t){let{setNodes:e,setEdges:n,setMinZoom:o,setMaxZoom:a,setTranslateExtent:l,setNodeExtent:i,reset:r,setDefaultNodesAndEdges:u}=ut(Qz,Et),s=zt();(0,D.useEffect)(()=>(u(t.defaultNodes,t.defaultEdges),()=>{c.current=Gb,r()}),[]);let c=(0,D.useRef)(Gb);return(0,D.useEffect)(()=>{for(let d of Zb){let f=t[d],p=c.current[d];f!==p&&(typeof t[d]>"u"||(d==="nodes"?e(f):d==="edges"?n(f):d==="minZoom"?o(f):d==="maxZoom"?a(f):d==="translateExtent"?l(f):d==="nodeExtent"?i(f):d==="ariaLabelConfig"?s.setState({ariaLabelConfig:ab(f)}):d==="fitView"?s.setState({fitViewQueued:f}):d==="fitViewOptions"?s.setState({fitViewOptions:f}):s.setState({[d]:f})))}c.current=t},Zb.map(d=>t[d])),null}function Qb(){return typeof window>"u"||!window.matchMedia?null:window.matchMedia("(prefers-color-scheme: dark)")}function Kz(t){let[e,n]=(0,D.useState)(t==="system"?null:t);return(0,D.useEffect)(()=>{if(t!=="system"){n(t);return}let o=Qb(),a=()=>n(o?.matches?"dark":"light");return a(),o?.addEventListener("change",a),()=>{o?.removeEventListener("change",a)}},[t]),e!==null?e:Qb()?.matches?"dark":"light"}var jb=typeof document<"u"?document:null;function Pi(t=null,e={target:jb,actInsideInputWithModifier:!0}){let[n,o]=(0,D.useState)(!1),a=(0,D.useRef)(!1),l=(0,D.useRef)(new Set([])),[i,r]=(0,D.useMemo)(()=>{if(t!==null){let s=(Array.isArray(t)?t:[t]).filter(d=>typeof d=="string").map(d=>d.replace("+",`
10
10
  `).replace(`
11
11
 
12
12
  `,`
13
13
  +`).split(`
14
- `)),c=s.reduce((d,f)=>d.concat(...f),[]);return[s,c]}return[[],[]]},[t]);return(0,D.useEffect)(()=>{let u=e?.target??Qb,s=e?.actInsideInputWithModifier??!0;if(t!==null){let c=p=>{if(a.current=p.ctrlKey||p.metaKey||p.shiftKey||p.altKey,(!a.current||a.current&&!s)&&yh(p))return!1;let b=Kb(p.code,r);if(l.current.add(p[b]),jb(i,l.current,!1)){let x=p.composedPath?.()?.[0]||p.target,g=x?.nodeName==="BUTTON"||x?.nodeName==="A";e.preventDefault!==!1&&(a.current||!g)&&p.preventDefault(),o(!0)}},d=p=>{let y=Kb(p.code,r);jb(i,l.current,!0)?(o(!1),l.current.clear()):l.current.delete(p[y]),p.key==="Meta"&&l.current.clear(),a.current=!1},f=()=>{l.current.clear(),o(!1)};return u?.addEventListener("keydown",c),u?.addEventListener("keyup",d),window.addEventListener("blur",f),window.addEventListener("contextmenu",f),()=>{u?.removeEventListener("keydown",c),u?.removeEventListener("keyup",d),window.removeEventListener("blur",f),window.removeEventListener("contextmenu",f)}}},[t,o]),n}function jb(t,e,n){return t.filter(o=>n||o.length===e.size).some(o=>o.every(a=>e.has(a)))}function Kb(t,e){return e.includes(t)?"code":"key"}var $z=()=>{let t=zt();return(0,D.useMemo)(()=>({zoomIn:async e=>{let{panZoom:n}=t.getState();return n?n.scaleBy(1.2,e):!1},zoomOut:async e=>{let{panZoom:n}=t.getState();return n?n.scaleBy(1/1.2,e):!1},zoomTo:async(e,n)=>{let{panZoom:o}=t.getState();return o?o.scaleTo(e,n):!1},getZoom:()=>t.getState().transform[2],setViewport:async(e,n)=>{let{transform:[o,a,l],panZoom:i}=t.getState();return i?(await i.setViewport({x:e.x??o,y:e.y??a,zoom:e.zoom??l},n),!0):!1},getViewport:()=>{let[e,n,o]=t.getState().transform;return{x:e,y:n,zoom:o}},setCenter:async(e,n,o)=>t.getState().setCenter(e,n,o),fitBounds:async(e,n)=>{let{width:o,height:a,minZoom:l,maxZoom:i,panZoom:r}=t.getState(),u=Fi(e,o,a,l,i,n?.padding??.1);return r?(await r.setViewport(u,{duration:n?.duration,ease:n?.ease,interpolate:n?.interpolate}),!0):!1},screenToFlowPosition:(e,n={})=>{let{transform:o,snapGrid:a,snapToGrid:l,domNode:i}=t.getState();if(!i)return e;let{x:r,y:u}=i.getBoundingClientRect(),s={x:e.x-r,y:e.y-u},c=n.snapGrid??a,d=n.snapToGrid??l;return fa(s,o,d,c)},flowToScreenPosition:e=>{let{transform:n,domNode:o}=t.getState();if(!o)return e;let{x:a,y:l}=o.getBoundingClientRect(),i=ua(e,n);return{x:i.x+a,y:i.y+l}}}),[])};function gx(t,e){let n=[],o=new Map,a=[];for(let l of t)if(l.type==="add"){a.push(l);continue}else if(l.type==="remove"||l.type==="replace")o.set(l.id,[l]);else{let i=o.get(l.id);i?i.push(l):o.set(l.id,[l])}for(let l of e){let i=o.get(l.id);if(!i){n.push(l);continue}if(i[0].type==="remove")continue;if(i[0].type==="replace"){n.push({...i[0].item});continue}let r={...l};for(let u of i)Jz(u,r);n.push(r)}return a.length&&a.forEach(l=>{l.index!==void 0?n.splice(l.index,0,{...l.item}):n.push({...l.item})}),n}function Jz(t,e){switch(t.type){case"select":{e.selected=t.selected;break}case"position":{typeof t.position<"u"&&(e.position=t.position),typeof t.dragging<"u"&&(e.dragging=t.dragging);break}case"dimensions":{typeof t.dimensions<"u"&&(e.measured={...t.dimensions},t.setAttributes&&((t.setAttributes===!0||t.setAttributes==="width")&&(e.width=t.dimensions.width),(t.setAttributes===!0||t.setAttributes==="height")&&(e.height=t.dimensions.height))),typeof t.resizing=="boolean"&&(e.resizing=t.resizing);break}}}function Iz(t,e){return gx(t,e)}function Wz(t,e){return gx(t,e)}function ha(t,e){return{id:t,type:"select",selected:e}}function _l(t,e=new Set,n=!1){let o=[];for(let[a,l]of t){let i=e.has(a);!(l.selected===void 0&&!i)&&l.selected!==i&&(n&&(l.selected=i),o.push(ha(l.id,i)))}return o}function $b({items:t=[],lookup:e}){let n=[],o=new Map(t.map(a=>[a.id,a]));for(let[a,l]of t.entries()){let i=e.get(l.id),r=i?.internals?.userNode??i;r!==void 0&&r!==l&&n.push({id:l.id,item:l,type:"replace"}),r===void 0&&n.push({item:l,type:"add",index:a})}for(let[a]of e)o.get(a)===void 0&&n.push({id:a,type:"remove"});return n}function Jb(t){return{id:t.id,type:"remove"}}var Fz=dh("React Flow","https://reactflow.dev/");function Pz(t,e,n={}){return ib(t,e,{...n,onError:n.onError??Fz})}var Ib=t=>W1(t),t3=t=>ih(t);function mx(t){return(0,D.forwardRef)(t)}var e3=typeof window<"u"?D.useLayoutEffect:D.useEffect;function Wb(t){let[e,n]=(0,D.useState)(BigInt(0)),[o]=(0,D.useState)(()=>n3(()=>n(a=>a+BigInt(1))));return e3(()=>{let a=o.get();a.length&&(t(a),o.reset())},[e]),o}function n3(t){let e=[];return{get:()=>e,reset:()=>{e=[]},push:n=>{e.push(n),t()}}}var yx=(0,D.createContext)(null);function o3({children:t}){let e=zt(),n=(0,D.useCallback)(r=>{let{nodes:u=[],setNodes:s,hasDefaultNodes:c,onNodesChange:d,nodeLookup:f,fitViewQueued:p,onNodesChangeMiddlewareMap:y}=e.getState(),b=u;for(let g of r)b=typeof g=="function"?g(b):g;let x=$b({items:b,lookup:f});for(let g of y.values())x=g(x);c&&s(b),x.length>0?d?.(x):p&&window.requestAnimationFrame(()=>{let{fitViewQueued:g,nodes:m,setNodes:h}=e.getState();g&&h(m)})},[]),o=Wb(n),a=(0,D.useCallback)(r=>{let{edges:u=[],setEdges:s,hasDefaultEdges:c,onEdgesChange:d,edgeLookup:f}=e.getState(),p=u;for(let y of r)p=typeof y=="function"?y(p):y;c?s(p):d&&d($b({items:p,lookup:f}))},[]),l=Wb(a),i=(0,D.useMemo)(()=>({nodeQueue:o,edgeQueue:l}),[]);return(0,O.jsx)(yx.Provider,{value:i,children:t})}function a3(){let t=(0,D.useContext)(yx);if(!t)throw new Error("useBatchContext must be used within a BatchProvider");return t}var l3=t=>!!t.panZoom;function Th(){let t=$z(),e=zt(),n=a3(),o=ut(l3),a=(0,D.useMemo)(()=>{let l=d=>e.getState().nodeLookup.get(d),i=d=>{n.nodeQueue.push(d)},r=d=>{n.edgeQueue.push(d)},u=d=>{let{nodeLookup:f,nodeOrigin:p}=e.getState(),y=Ib(d)?d:f.get(d.id),b=y.parentId?ph(y.position,y.measured,y.parentId,f,p):y.position,x={...y,position:b,width:y.measured?.width??y.width,height:y.measured?.height??y.height};return sa(x)},s=(d,f,p={replace:!1})=>{i(y=>y.map(b=>{if(b.id===d){let x=typeof f=="function"?f(b):f;return p.replace&&Ib(x)?x:{...b,...x}}return b}))},c=(d,f,p={replace:!1})=>{r(y=>y.map(b=>{if(b.id===d){let x=typeof f=="function"?f(b):f;return p.replace&&t3(x)?x:{...b,...x}}return b}))};return{getNodes:()=>e.getState().nodes.map(d=>({...d})),getNode:d=>l(d)?.internals.userNode,getInternalNode:l,getEdges:()=>{let{edges:d=[]}=e.getState();return d.map(f=>({...f}))},getEdge:d=>e.getState().edgeLookup.get(d),setNodes:i,setEdges:r,addNodes:d=>{let f=Array.isArray(d)?d:[d];n.nodeQueue.push(p=>[...p,...f])},addEdges:d=>{let f=Array.isArray(d)?d:[d];n.edgeQueue.push(p=>[...p,...f])},toObject:()=>{let{nodes:d=[],edges:f=[],transform:p}=e.getState(),[y,b,x]=p;return{nodes:d.map(g=>({...g})),edges:f.map(g=>({...g})),viewport:{x:y,y:b,zoom:x}}},deleteElements:async({nodes:d=[],edges:f=[]})=>{let{nodes:p,edges:y,onNodesDelete:b,onEdgesDelete:x,triggerNodeChanges:g,triggerEdgeChanges:m,onDelete:h,onBeforeDelete:v}=e.getState(),{nodes:_,edges:E}=await tb({nodesToRemove:d,edgesToRemove:f,nodes:p,edges:y,onBeforeDelete:v}),w=E.length>0,N=_.length>0;if(w){let M=E.map(Jb);x?.(E),m(M)}if(N){let M=_.map(Jb);b?.(_),g(M)}return(N||w)&&h?.({nodes:_,edges:E}),{deletedNodes:_,deletedEdges:E}},getIntersectingNodes:(d,f=!0,p)=>{let y=fh(d),b=y?d:u(d),x=p!==void 0;return b?(p||e.getState().nodes).filter(g=>{let m=e.getState().nodeLookup.get(g.id);if(m&&!y&&(g.id===d.id||!m.internals.positionAbsolute))return!1;let h=sa(x?g:m),v=vl(h,b);return f&&v>0||v>=h.width*h.height||v>=b.width*b.height}):[]},isNodeIntersecting:(d,f,p=!0)=>{let b=fh(d)?d:u(d);if(!b)return!1;let x=vl(b,f);return p&&x>0||x>=f.width*f.height||x>=b.width*b.height},updateNode:s,updateNodeData:(d,f,p={replace:!1})=>{s(d,y=>{let b=typeof f=="function"?f(y):f;return p.replace?{...y,data:b}:{...y,data:{...y.data,...b}}},p)},updateEdge:c,updateEdgeData:(d,f,p={replace:!1})=>{c(d,y=>{let b=typeof f=="function"?f(y):f;return p.replace?{...y,data:b}:{...y,data:{...y.data,...b}}},p)},getNodesBounds:d=>{let{nodeLookup:f,nodeOrigin:p}=e.getState();return uh(d,{nodeLookup:f,nodeOrigin:p})},getHandleConnections:({type:d,id:f,nodeId:p})=>Array.from(e.getState().connectionLookup.get(`${p}-${d}${f?`-${f}`:""}`)?.values()??[]),getNodeConnections:({type:d,handleId:f,nodeId:p})=>Array.from(e.getState().connectionLookup.get(`${p}${d?f?`-${d}-${f}`:`-${d}`:""}`)?.values()??[]),fitView:async d=>{let f=e.getState().fitViewResolver??nb();return e.setState({fitViewQueued:!0,fitViewOptions:d,fitViewResolver:f}),n.nodeQueue.push(p=>[...p]),f.promise}}},[]);return(0,D.useMemo)(()=>({...a,...t,viewportInitialized:o}),[o])}var Fb=t=>t.selected,i3=typeof window<"u"?window:void 0;function r3({deleteKeyCode:t,multiSelectionKeyCode:e}){let n=zt(),{deleteElements:o}=Th(),a=Pi(t,{actInsideInputWithModifier:!1}),l=Pi(e,{target:i3});(0,D.useEffect)(()=>{if(a){let{edges:i,nodes:r}=n.getState();o({nodes:r.filter(Fb),edges:i.filter(Fb)}),n.setState({nodesSelectionActive:!1})}},[a]),(0,D.useEffect)(()=>{n.setState({multiSelectionActive:l})},[l])}function u3(t){let e=zt();(0,D.useEffect)(()=>{let n=()=>{if(!t.current||!(t.current.checkVisibility?.()??!0))return!1;let o=vc(t.current);(o.height===0||o.width===0)&&e.getState().onError?.("004",Me.error004()),e.setState({width:o.width||500,height:o.height||500})};if(t.current){n(),window.addEventListener("resize",n);let o=new ResizeObserver(()=>n());return o.observe(t.current),()=>{window.removeEventListener("resize",n),o&&t.current&&o.unobserve(t.current)}}},[])}var Hc={position:"absolute",width:"100%",height:"100%",top:0,left:0},c3=t=>({userSelectionActive:t.userSelectionActive,lib:t.lib,connectionInProgress:t.connection.inProgress});function s3({onPaneContextMenu:t,zoomOnScroll:e=!0,zoomOnPinch:n=!0,panOnScroll:o=!1,panOnScrollSpeed:a=.5,panOnScrollMode:l=Un.Free,zoomOnDoubleClick:i=!0,panOnDrag:r=!0,defaultViewport:u,translateExtent:s,minZoom:c,maxZoom:d,zoomActivationKeyCode:f,preventScrolling:p=!0,children:y,noWheelClassName:b,noPanClassName:x,onViewportChange:g,isControlledViewport:m,paneClickDistance:h,selectionOnDrag:v}){let _=zt(),E=(0,D.useRef)(null),{userSelectionActive:w,lib:N,connectionInProgress:M}=ut(c3,Et),R=Pi(f),C=(0,D.useRef)();u3(E);let k=(0,D.useCallback)(V=>{g?.({x:V[0],y:V[1],zoom:V[2]}),m||_.setState({transform:V})},[g,m]);return(0,D.useEffect)(()=>{if(E.current){C.current=wb({domNode:E.current,minZoom:c,maxZoom:d,translateExtent:s,viewport:u,onDraggingChange:z=>_.setState(T=>T.paneDragging===z?T:{paneDragging:z}),onPanZoomStart:(z,T)=>{let{onViewportChangeStart:B,onMoveStart:H}=_.getState();H?.(z,T),B?.(T)},onPanZoom:(z,T)=>{let{onViewportChange:B,onMove:H}=_.getState();H?.(z,T),B?.(T)},onPanZoomEnd:(z,T)=>{let{onViewportChangeEnd:B,onMoveEnd:H}=_.getState();H?.(z,T),B?.(T)}});let{x:V,y:S,zoom:A}=C.current.getViewport();return _.setState({panZoom:C.current,transform:[V,S,A],domNode:E.current.closest(".react-flow")}),()=>{C.current?.destroy()}}},[]),(0,D.useEffect)(()=>{C.current?.update({onPaneContextMenu:t,zoomOnScroll:e,zoomOnPinch:n,panOnScroll:o,panOnScrollSpeed:a,panOnScrollMode:l,zoomOnDoubleClick:i,panOnDrag:r,zoomActivationKeyPressed:R,preventScrolling:p,noPanClassName:x,userSelectionActive:w,noWheelClassName:b,lib:N,onTransformChange:k,connectionInProgress:M,selectionOnDrag:v,paneClickDistance:h})},[t,e,n,o,a,l,i,r,R,p,x,w,b,N,k,M,v,h]),(0,O.jsx)("div",{className:"react-flow__renderer",ref:E,style:Hc,children:y})}var f3=t=>({userSelectionActive:t.userSelectionActive,userSelectionRect:t.userSelectionRect});function d3(){let{userSelectionActive:t,userSelectionRect:e}=ut(f3,Et);return t&&e?(0,O.jsx)("div",{className:"react-flow__selection react-flow__container",style:{width:e.width,height:e.height,transform:`translate(${e.x}px, ${e.y}px)`}}):null}var zh=(t,e)=>n=>{n.target===e.current&&t?.(n)},h3=t=>({userSelectionActive:t.userSelectionActive,elementsSelectable:t.elementsSelectable,connectionInProgress:t.connection.inProgress,dragging:t.paneDragging,panBy:t.panBy,autoPanSpeed:t.autoPanSpeed});function p3({isSelecting:t,selectionKeyPressed:e,selectionMode:n=ia.Full,panOnDrag:o,autoPanOnSelection:a,paneClickDistance:l,selectionOnDrag:i,onSelectionStart:r,onSelectionEnd:u,onPaneClick:s,onPaneContextMenu:c,onPaneScroll:d,onPaneMouseEnter:f,onPaneMouseMove:p,onPaneMouseLeave:y,children:b}){let x=(0,D.useRef)(0),g=zt(),{userSelectionActive:m,elementsSelectable:h,dragging:v,connectionInProgress:_,panBy:E,autoPanSpeed:w}=ut(h3,Et),N=h&&(t||m),M=(0,D.useRef)(null),R=(0,D.useRef)(),C=(0,D.useRef)(new Set),k=(0,D.useRef)(new Set),V=(0,D.useRef)(!1),S=(0,D.useRef)({x:0,y:0}),A=(0,D.useRef)(!1),z=U=>{if(V.current||_){V.current=!1;return}s?.(U),g.getState().resetSelectedElements(),g.setState({nodesSelectionActive:!1})},T=U=>{if(Array.isArray(o)&&o?.includes(2)){U.preventDefault();return}c?.(U)},B=d?U=>d(U):void 0,H=U=>{V.current&&(U.stopPropagation(),V.current=!1)},X=U=>{let{domNode:Q,transform:nt}=g.getState();if(R.current=Q?.getBoundingClientRect(),!R.current)return;let tt=U.target===M.current;if(!tt&&!!U.target.closest(".nokey")||!t||!(i&&tt||e)||U.button!==0||!U.isPrimary)return;U.target?.setPointerCapture?.(U.pointerId),V.current=!1;let{x:ct,y:dt}=Ve(U.nativeEvent,R.current),Dt=fa({x:ct,y:dt},nt);g.setState({userSelectionRect:{width:0,height:0,startX:Dt.x,startY:Dt.y,x:ct,y:dt}}),tt||(U.stopPropagation(),U.preventDefault())};function Z(U,Q){let{userSelectionRect:nt}=g.getState();if(!nt)return;let{transform:tt,nodeLookup:$,edgeLookup:W,connectionLookup:ct,triggerNodeChanges:dt,triggerEdgeChanges:Dt,defaultEdgeOptions:ie}=g.getState(),cn={x:nt.startX,y:nt.startY},{x:Je,y:Ie}=ua(cn,tt),sn={startX:cn.x,startY:cn.y,x:U<Je?U:Je,y:Q<Ie?Q:Ie,width:Math.abs(U-Je),height:Math.abs(Q-Ie)},El=C.current,Mo=k.current;C.current=new Set(pc($,sn,tt,n===ia.Partial,!0).map(qe=>qe.id)),k.current=new Set;let zo=ie?.selectable??!0;for(let qe of C.current){let fn=ct.get(qe);if(fn)for(let{edgeId:dn}of fn.values()){let Ao=W.get(dn);Ao&&(Ao.selectable??zo)&&k.current.add(dn)}}if(!gh(El,C.current)){let qe=_l($,C.current,!0);dt(qe)}if(!gh(Mo,k.current)){let qe=_l(W,k.current);Dt(qe)}g.setState({userSelectionRect:sn,userSelectionActive:!0,nodesSelectionActive:!1})}function q(){if(!a||!R.current)return;let[U,Q]=gc(S.current,R.current,w);E({x:U,y:Q}).then(nt=>{if(!V.current||!nt){x.current=requestAnimationFrame(q);return}let{x:tt,y:$}=S.current;Z(tt,$),x.current=requestAnimationFrame(q)})}let K=()=>{cancelAnimationFrame(x.current),x.current=0,A.current=!1};(0,D.useEffect)(()=>()=>K(),[]);let j=U=>{let{userSelectionRect:Q,transform:nt,resetSelectedElements:tt}=g.getState();if(!R.current||!Q)return;let{x:$,y:W}=Ve(U.nativeEvent,R.current);S.current={x:$,y:W};let ct=ua({x:Q.startX,y:Q.startY},nt);if(!V.current){let dt=e?0:l;if(Math.hypot($-ct.x,W-ct.y)<=dt)return;tt(),r?.(U)}V.current=!0,A.current||(q(),A.current=!0),Z($,W)},I=U=>{U.button===0&&(U.target?.releasePointerCapture?.(U.pointerId),!m&&U.target===M.current&&g.getState().userSelectionRect&&z?.(U),g.setState({userSelectionActive:!1,userSelectionRect:null}),V.current&&(u?.(U),g.setState({nodesSelectionActive:C.current.size>0})),K())},ot=U=>{U.target?.releasePointerCapture?.(U.pointerId),K()},J=o===!0||Array.isArray(o)&&o.includes(0);return(0,O.jsxs)("div",{className:Tt(["react-flow__pane",{draggable:J,dragging:v,selection:t}]),onClick:N?void 0:zh(z,M),onContextMenu:zh(T,M),onWheel:zh(B,M),onPointerEnter:N?void 0:f,onPointerMove:N?j:p,onPointerUp:N?I:void 0,onPointerCancel:N?ot:void 0,onPointerDownCapture:N?X:void 0,onClickCapture:N?H:void 0,onPointerLeave:y,ref:M,style:Hc,children:[b,(0,O.jsx)(d3,{})]})}function Ch({id:t,store:e,unselect:n=!1,nodeRef:o}){let{addSelectedNodes:a,unselectNodesAndEdges:l,multiSelectionActive:i,nodeLookup:r,onError:u}=e.getState(),s=r.get(t);if(!s){u?.("012",Me.error012(t));return}e.setState({nodesSelectionActive:!1}),s.selected?(n||s.selected&&i)&&(l({nodes:[s],edges:[]}),requestAnimationFrame(()=>o?.current?.blur())):a([t])}function vx({nodeRef:t,disabled:e=!1,noDragClassName:n,handleSelector:o,nodeId:a,isSelectable:l,nodeClickDistance:i}){let r=zt(),[u,s]=(0,D.useState)(!1),c=(0,D.useRef)();return(0,D.useEffect)(()=>{c.current=gb({getStoreItems:()=>r.getState(),onNodeMouseDown:d=>{Ch({id:d,store:r,nodeRef:t})},onDragStart:()=>{s(!0)},onDragStop:()=>{s(!1)}})},[]),(0,D.useEffect)(()=>{if(!(e||!t.current||!c.current))return c.current.update({noDragClassName:n,handleSelector:o,domNode:t.current,isSelectable:l,nodeId:a,nodeClickDistance:i}),()=>{c.current?.destroy()}},[n,o,e,l,t,a,i]),u}var g3=t=>e=>e.selected&&(e.draggable||t&&typeof e.draggable>"u");function bx(){let t=zt();return(0,D.useCallback)(n=>{let{nodeExtent:o,snapToGrid:a,snapGrid:l,nodesDraggable:i,onError:r,updateNodePositions:u,nodeLookup:s,nodeOrigin:c}=t.getState(),d=new Map,f=g3(i),p=a?l[0]:5,y=a?l[1]:5,b=n.direction.x*p*n.factor,x=n.direction.y*y*n.factor;for(let[,g]of s){if(!f(g))continue;let m={x:g.internals.positionAbsolute.x+b,y:g.internals.positionAbsolute.y+x};a&&(m=bl(m,l));let{position:h,positionAbsolute:v}=ch({nodeId:g.id,nextPosition:m,nodeLookup:s,nodeExtent:o,nodeOrigin:c,onError:r});g.position=h,g.internals.positionAbsolute=v,d.set(g.id,g)}u(d)},[])}var Oh=(0,D.createContext)(null),m3=Oh.Provider;Oh.Consumer;var xx=()=>(0,D.useContext)(Oh),y3=t=>({connectOnClick:t.connectOnClick,noPanClassName:t.noPanClassName,rfId:t.rfId}),v3=(t,e,n)=>o=>{let{connectionClickStartHandle:a,connectionMode:l,connection:i}=o,{fromHandle:r,toHandle:u,isValid:s}=i,c=u?.nodeId===t&&u?.id===e&&u?.type===n;return{connectingFrom:r?.nodeId===t&&r?.id===e&&r?.type===n,connectingTo:c,clickConnecting:a?.nodeId===t&&a?.id===e&&a?.type===n,isPossibleEndHandle:l===So.Strict?r?.type!==n:t!==r?.nodeId||e!==r?.id,connectionInProcess:!!r,clickConnectionInProcess:!!a,valid:c&&s}};function b3({type:t="source",position:e=G.Top,isValidConnection:n,isConnectable:o=!0,isConnectableStart:a=!0,isConnectableEnd:l=!0,id:i,onConnect:r,children:u,className:s,onMouseDown:c,onTouchStart:d,...f},p){let y=i||null,b=t==="target",x=zt(),g=xx(),{connectOnClick:m,noPanClassName:h,rfId:v}=ut(y3,Et),{connectingFrom:_,connectingTo:E,clickConnecting:w,isPossibleEndHandle:N,connectionInProcess:M,clickConnectionInProcess:R,valid:C}=ut(v3(g,y,t),Et);g||x.getState().onError?.("010",Me.error010());let k=A=>{let{defaultEdgeOptions:z,onConnect:T,hasDefaultEdges:B}=x.getState(),H={...z,...A};if(B){let{edges:X,setEdges:Z,onError:q}=x.getState();Z(Pz(H,X,{onError:q}))}T?.(H),r?.(H)},V=A=>{if(!g)return;let z=vh(A.nativeEvent);if(a&&(z&&A.button===0||!z)){let T=x.getState();Nc.onPointerDown(A.nativeEvent,{handleDomNode:A.currentTarget,autoPanOnConnect:T.autoPanOnConnect,connectionMode:T.connectionMode,connectionRadius:T.connectionRadius,domNode:T.domNode,nodeLookup:T.nodeLookup,lib:T.lib,isTarget:b,handleId:y,nodeId:g,flowId:T.rfId,panBy:T.panBy,cancelConnection:T.cancelConnection,onConnectStart:T.onConnectStart,onConnectEnd:(...B)=>x.getState().onConnectEnd?.(...B),updateConnection:T.updateConnection,onConnect:k,isValidConnection:n||((...B)=>x.getState().isValidConnection?.(...B)??!0),getTransform:()=>x.getState().transform,getFromHandle:()=>x.getState().connection.fromHandle,autoPanSpeed:T.autoPanSpeed,dragThreshold:T.connectionDragThreshold})}z?c?.(A):d?.(A)},S=A=>{let{onClickConnectStart:z,onClickConnectEnd:T,connectionClickStartHandle:B,connectionMode:H,isValidConnection:X,lib:Z,rfId:q,nodeLookup:K,connection:j}=x.getState();if(!g||!B&&!a)return;if(!B){z?.(A.nativeEvent,{nodeId:g,handleId:y,handleType:t}),x.setState({connectionClickStartHandle:{nodeId:g,type:t,id:y}});return}let I=mh(A.target),ot=n||X,{connection:J,isValid:U}=Nc.isValid(A.nativeEvent,{handle:{nodeId:g,id:y,type:t},connectionMode:H,fromNodeId:B.nodeId,fromHandleId:B.id||null,fromType:B.type,isValidConnection:ot,flowId:q,doc:I,lib:Z,nodeLookup:K});U&&J&&k(J);let Q=structuredClone(j);delete Q.inProgress,Q.toPosition=Q.toHandle?Q.toHandle.position:null,T?.(A,Q),x.setState({connectionClickStartHandle:null})};return(0,O.jsx)("div",{"data-handleid":y,"data-nodeid":g,"data-handlepos":e,"data-id":`${v}-${g}-${y}-${t}`,className:Tt(["react-flow__handle",`react-flow__handle-${e}`,"nodrag",h,s,{source:!b,target:b,connectable:o,connectablestart:a,connectableend:l,clickconnecting:w,connectingfrom:_,connectingto:E,valid:C,connectionindicator:o&&(!M||N)&&(M||R?l:a)}]),onMouseDown:V,onTouchStart:V,onClick:m?S:void 0,ref:p,...f,children:u})}var $e=(0,D.memo)(mx(b3));function x3({data:t,isConnectable:e,sourcePosition:n=G.Bottom}){return(0,O.jsxs)(O.Fragment,{children:[t?.label,(0,O.jsx)($e,{type:"source",position:n,isConnectable:e})]})}function S3({data:t,isConnectable:e,targetPosition:n=G.Top,sourcePosition:o=G.Bottom}){return(0,O.jsxs)(O.Fragment,{children:[(0,O.jsx)($e,{type:"target",position:n,isConnectable:e}),t?.label,(0,O.jsx)($e,{type:"source",position:o,isConnectable:e})]})}function _3(){return null}function w3({data:t,isConnectable:e,targetPosition:n=G.Top}){return(0,O.jsxs)(O.Fragment,{children:[(0,O.jsx)($e,{type:"target",position:n,isConnectable:e}),t?.label]})}var Tc={ArrowUp:{x:0,y:-1},ArrowDown:{x:0,y:1},ArrowLeft:{x:-1,y:0},ArrowRight:{x:1,y:0}},Pb={input:x3,default:S3,output:w3,group:_3};function E3(t){return t.internals.handleBounds===void 0?{width:t.width??t.initialWidth??t.style?.width,height:t.height??t.initialHeight??t.style?.height}:{width:t.width??t.style?.width,height:t.height??t.style?.height}}var N3=t=>{let{width:e,height:n,x:o,y:a}=yl(t.nodeLookup,{filter:l=>!!l.selected});return{width:Ye(e)?e:null,height:Ye(n)?n:null,userSelectionActive:t.userSelectionActive,transformString:`translate(${t.transform[0]}px,${t.transform[1]}px) scale(${t.transform[2]}) translate(${o}px,${a}px)`}};function M3({onSelectionContextMenu:t,noPanClassName:e,disableKeyboardA11y:n}){let o=zt(),{width:a,height:l,transformString:i,userSelectionActive:r}=ut(N3,Et),u=bx(),s=(0,D.useRef)(null);(0,D.useEffect)(()=>{n||s.current?.focus({preventScroll:!0})},[n]);let c=!r&&a!==null&&l!==null;if(vx({nodeRef:s,disabled:!c}),!c)return null;let d=t?p=>{let y=o.getState().nodes.filter(b=>b.selected);t(p,y)}:void 0,f=p=>{Object.prototype.hasOwnProperty.call(Tc,p.key)&&(p.preventDefault(),u({direction:Tc[p.key],factor:p.shiftKey?4:1}))};return(0,O.jsx)("div",{className:Tt(["react-flow__nodesselection","react-flow__container",e]),style:{transform:i},children:(0,O.jsx)("div",{ref:s,className:"react-flow__nodesselection-rect",onContextMenu:d,tabIndex:n?void 0:-1,onKeyDown:n?void 0:f,style:{width:a,height:l}})})}var tx=typeof window<"u"?window:void 0,z3=t=>({nodesSelectionActive:t.nodesSelectionActive,userSelectionActive:t.userSelectionActive});function Sx({children:t,onPaneClick:e,onPaneMouseEnter:n,onPaneMouseMove:o,onPaneMouseLeave:a,onPaneContextMenu:l,onPaneScroll:i,paneClickDistance:r,deleteKeyCode:u,selectionKeyCode:s,selectionOnDrag:c,selectionMode:d,onSelectionStart:f,onSelectionEnd:p,multiSelectionKeyCode:y,panActivationKeyCode:b,zoomActivationKeyCode:x,elementsSelectable:g,zoomOnScroll:m,zoomOnPinch:h,panOnScroll:v,panOnScrollSpeed:_,panOnScrollMode:E,zoomOnDoubleClick:w,panOnDrag:N,autoPanOnSelection:M,defaultViewport:R,translateExtent:C,minZoom:k,maxZoom:V,preventScrolling:S,onSelectionContextMenu:A,noWheelClassName:z,noPanClassName:T,disableKeyboardA11y:B,onViewportChange:H,isControlledViewport:X}){let{nodesSelectionActive:Z,userSelectionActive:q}=ut(z3,Et),K=Pi(s,{target:tx}),j=Pi(b,{target:tx}),I=j||N,ot=j||v,J=c&&I!==!0,U=K||q||J;return r3({deleteKeyCode:u,multiSelectionKeyCode:y}),(0,O.jsx)(s3,{onPaneContextMenu:l,elementsSelectable:g,zoomOnScroll:m,zoomOnPinch:h,panOnScroll:ot,panOnScrollSpeed:_,panOnScrollMode:E,zoomOnDoubleClick:w,panOnDrag:!K&&I,defaultViewport:R,translateExtent:C,minZoom:k,maxZoom:V,zoomActivationKeyCode:x,preventScrolling:S,noWheelClassName:z,noPanClassName:T,onViewportChange:H,isControlledViewport:X,paneClickDistance:r,selectionOnDrag:J,children:(0,O.jsxs)(p3,{onSelectionStart:f,onSelectionEnd:p,onPaneClick:e,onPaneMouseEnter:n,onPaneMouseMove:o,onPaneMouseLeave:a,onPaneContextMenu:l,onPaneScroll:i,panOnDrag:I,autoPanOnSelection:M,isSelecting:!!U,selectionMode:d,selectionKeyPressed:K,paneClickDistance:r,selectionOnDrag:J,children:[t,Z&&(0,O.jsx)(M3,{onSelectionContextMenu:A,noPanClassName:T,disableKeyboardA11y:B})]})})}Sx.displayName="FlowRenderer";var A3=(0,D.memo)(Sx),C3=t=>e=>t?pc(e.nodeLookup,{x:0,y:0,width:e.width,height:e.height},e.transform,!0).map(n=>n.id):Array.from(e.nodeLookup.keys());function T3(t){return ut((0,D.useCallback)(C3(t),[t]),Et)}var O3=t=>t.updateNodeInternals;function D3(){let t=ut(O3),[e]=(0,D.useState)(()=>typeof ResizeObserver>"u"?null:new ResizeObserver(n=>{let o=new Map;n.forEach(a=>{let l=a.target.getAttribute("data-id");o.set(l,{id:l,nodeElement:a.target,force:!0})}),t(o)}));return(0,D.useEffect)(()=>()=>{e?.disconnect()},[e]),e}function H3({node:t,nodeType:e,hasDimensions:n,resizeObserver:o}){let a=zt(),l=(0,D.useRef)(null),i=(0,D.useRef)(null),r=(0,D.useRef)(t.sourcePosition),u=(0,D.useRef)(t.targetPosition),s=(0,D.useRef)(e),c=n&&!!t.internals.handleBounds;return(0,D.useEffect)(()=>{l.current&&!t.hidden&&(!c||i.current!==l.current)&&(i.current&&o?.unobserve(i.current),o?.observe(l.current),i.current=l.current)},[c,t.hidden]),(0,D.useEffect)(()=>()=>{i.current&&(o?.unobserve(i.current),i.current=null)},[]),(0,D.useEffect)(()=>{if(l.current){let d=s.current!==e,f=r.current!==t.sourcePosition,p=u.current!==t.targetPosition;(d||f||p)&&(s.current=e,r.current=t.sourcePosition,u.current=t.targetPosition,a.getState().updateNodeInternals(new Map([[t.id,{id:t.id,nodeElement:l.current,force:!0}]])))}},[t.id,e,t.sourcePosition,t.targetPosition]),l}function R3({id:t,onClick:e,onMouseEnter:n,onMouseMove:o,onMouseLeave:a,onContextMenu:l,onDoubleClick:i,nodesDraggable:r,elementsSelectable:u,nodesConnectable:s,nodesFocusable:c,resizeObserver:d,noDragClassName:f,noPanClassName:p,disableKeyboardA11y:y,rfId:b,nodeTypes:x,nodeClickDistance:g,onError:m}){let{node:h,internals:v,isParent:_}=ut(U=>{let Q=U.nodeLookup.get(t),nt=U.parentLookup.has(t);return{node:Q,internals:Q.internals,isParent:nt}},Et),E=h.type||"default",w=x?.[E]||Pb[E];w===void 0&&(m?.("003",Me.error003(E)),E="default",w=x?.default||Pb.default);let N=!!(h.draggable||r&&typeof h.draggable>"u"),M=!!(h.selectable||u&&typeof h.selectable>"u"),R=!!(h.connectable||s&&typeof h.connectable>"u"),C=!!(h.focusable||c&&typeof h.focusable>"u"),k=zt(),V=hh(h),S=H3({node:h,nodeType:E,hasDimensions:V,resizeObserver:d}),A=vx({nodeRef:S,disabled:h.hidden||!N,noDragClassName:f,handleSelector:h.dragHandle,nodeId:t,isSelectable:M,nodeClickDistance:g}),z=bx();if(h.hidden)return null;let T=un(h),B=E3(h),H=M||N||e||n||o||a,X=n?U=>n(U,{...v.userNode}):void 0,Z=o?U=>o(U,{...v.userNode}):void 0,q=a?U=>a(U,{...v.userNode}):void 0,K=l?U=>l(U,{...v.userNode}):void 0,j=i?U=>i(U,{...v.userNode}):void 0,I=U=>{let{selectNodesOnDrag:Q,nodeDragThreshold:nt}=k.getState();M&&(!Q||!N||nt>0)&&Ch({id:t,store:k,nodeRef:S}),e&&e(U,{...v.userNode})},ot=U=>{if(!(yh(U.nativeEvent)||y)){if(nh.includes(U.key)&&M){let Q=U.key==="Escape";Ch({id:t,store:k,unselect:Q,nodeRef:S})}else if(N&&h.selected&&Object.prototype.hasOwnProperty.call(Tc,U.key)){U.preventDefault();let{ariaLabelConfig:Q}=k.getState();k.setState({ariaLiveMessage:Q["node.a11yDescription.ariaLiveMessage"]({direction:U.key.replace("Arrow","").toLowerCase(),x:~~v.positionAbsolute.x,y:~~v.positionAbsolute.y})}),z({direction:Tc[U.key],factor:U.shiftKey?4:1})}}},J=()=>{if(y||!S.current?.matches(":focus-visible"))return;let{transform:U,width:Q,height:nt,autoPanOnNodeFocus:tt,setCenter:$}=k.getState();if(!tt)return;pc(new Map([[t,h]]),{x:0,y:0,width:Q,height:nt},U,!0).length>0||$(h.position.x+T.width/2,h.position.y+T.height/2,{zoom:U[2]})};return(0,O.jsx)("div",{className:Tt(["react-flow__node",`react-flow__node-${E}`,{[p]:N},h.className,{selected:h.selected,selectable:M,parent:_,draggable:N,dragging:A}]),ref:S,style:{zIndex:v.z,transform:`translate(${v.positionAbsolute.x}px,${v.positionAbsolute.y}px)`,pointerEvents:H?"all":"none",visibility:V?"visible":"hidden",...h.style,...B},"data-id":t,"data-testid":`rf__node-${t}`,onMouseEnter:X,onMouseMove:Z,onMouseLeave:q,onContextMenu:K,onClick:I,onDoubleClick:j,onKeyDown:C?ot:void 0,tabIndex:C?0:void 0,onFocus:C?J:void 0,role:h.ariaRole??(C?"group":void 0),"aria-roledescription":"node","aria-describedby":y?void 0:`${dx}-${b}`,"aria-label":h.ariaLabel,...h.domAttributes,children:(0,O.jsx)(m3,{value:t,children:(0,O.jsx)(w,{id:t,data:h.data,type:E,positionAbsoluteX:v.positionAbsolute.x,positionAbsoluteY:v.positionAbsolute.y,selected:h.selected??!1,selectable:M,draggable:N,deletable:h.deletable??!0,isConnectable:R,sourcePosition:h.sourcePosition,targetPosition:h.targetPosition,dragging:A,dragHandle:h.dragHandle,zIndex:v.z,parentId:h.parentId,...T})})})}var B3=(0,D.memo)(R3),k3=t=>({nodesDraggable:t.nodesDraggable,nodesConnectable:t.nodesConnectable,nodesFocusable:t.nodesFocusable,elementsSelectable:t.elementsSelectable,onError:t.onError});function _x(t){let{nodesDraggable:e,nodesConnectable:n,nodesFocusable:o,elementsSelectable:a,onError:l}=ut(k3,Et),i=T3(t.onlyRenderVisibleElements),r=D3();return(0,O.jsx)("div",{className:"react-flow__nodes",style:Hc,children:i.map(u=>(0,O.jsx)(B3,{id:u,nodeTypes:t.nodeTypes,nodeExtent:t.nodeExtent,onClick:t.onNodeClick,onMouseEnter:t.onNodeMouseEnter,onMouseMove:t.onNodeMouseMove,onMouseLeave:t.onNodeMouseLeave,onContextMenu:t.onNodeContextMenu,onDoubleClick:t.onNodeDoubleClick,noDragClassName:t.noDragClassName,noPanClassName:t.noPanClassName,rfId:t.rfId,disableKeyboardA11y:t.disableKeyboardA11y,resizeObserver:r,nodesDraggable:e,nodesConnectable:n,nodesFocusable:o,elementsSelectable:a,nodeClickDistance:t.nodeClickDistance,onError:l},u))})}_x.displayName="NodeRenderer";var L3=(0,D.memo)(_x);function U3(t){return ut((0,D.useCallback)(n=>{if(!t)return n.edges.map(a=>a.id);let o=[];if(n.width&&n.height)for(let a of n.edges){let l=n.nodeLookup.get(a.source),i=n.nodeLookup.get(a.target);l&&i&&lb({sourceNode:l,targetNode:i,width:n.width,height:n.height,transform:n.transform})&&o.push(a.id)}return o},[t]),Et)}var Y3=({color:t="none",strokeWidth:e=1})=>{let n={strokeWidth:e,...t&&{stroke:t}};return(0,O.jsx)("polyline",{className:"arrow",style:n,strokeLinecap:"round",fill:"none",strokeLinejoin:"round",points:"-5,-4 0,0 -5,4"})},V3=({color:t="none",strokeWidth:e=1})=>{let n={strokeWidth:e,...t&&{stroke:t,fill:t}};return(0,O.jsx)("polyline",{className:"arrowclosed",style:n,strokeLinecap:"round",strokeLinejoin:"round",points:"-5,-4 0,0 -5,4 -5,-4"})},ex={[pl.Arrow]:Y3,[pl.ArrowClosed]:V3};function q3(t){let e=zt();return(0,D.useMemo)(()=>Object.prototype.hasOwnProperty.call(ex,t)?ex[t]:(e.getState().onError?.("009",Me.error009(t)),null),[t])}var X3=({id:t,type:e,color:n,width:o=12.5,height:a=12.5,markerUnits:l="strokeWidth",strokeWidth:i,orient:r="auto-start-reverse"})=>{let u=q3(e);return u?(0,O.jsx)("marker",{className:"react-flow__arrowhead",id:t,markerWidth:`${o}`,markerHeight:`${a}`,viewBox:"-10 -10 20 20",markerUnits:l,orient:r,refX:"0",refY:"0",children:(0,O.jsx)(u,{color:n,strokeWidth:i})}):null},wx=({defaultColor:t,rfId:e})=>{let n=ut(l=>l.edges),o=ut(l=>l.defaultEdgeOptions),a=(0,D.useMemo)(()=>ub(n,{id:e,defaultColor:t,defaultMarkerStart:o?.markerStart,defaultMarkerEnd:o?.markerEnd}),[n,o,e,t]);return a.length?(0,O.jsx)("svg",{className:"react-flow__marker","aria-hidden":"true",children:(0,O.jsx)("defs",{children:a.map(l=>(0,O.jsx)(X3,{id:l.id,type:l.type,color:l.color,width:l.width,height:l.height,markerUnits:l.markerUnits,strokeWidth:l.strokeWidth,orient:l.orient},l.id))})}):null};wx.displayName="MarkerDefinitions";var Z3=(0,D.memo)(wx);function Ex({x:t,y:e,label:n,labelStyle:o,labelShowBg:a=!0,labelBgStyle:l,labelBgPadding:i=[2,4],labelBgBorderRadius:r=2,children:u,className:s,...c}){let[d,f]=(0,D.useState)({x:1,y:0,width:0,height:0}),p=Tt(["react-flow__edge-textwrapper",s]),y=(0,D.useRef)(null);return(0,D.useEffect)(()=>{if(y.current){let b=y.current.getBBox();f({x:b.x,y:b.y,width:b.width,height:b.height})}},[n]),n?(0,O.jsxs)("g",{transform:`translate(${t-d.width/2} ${e-d.height/2})`,className:p,visibility:d.width?"visible":"hidden",...c,children:[a&&(0,O.jsx)("rect",{width:d.width+2*i[0],x:-i[0],y:-i[1],height:d.height+2*i[1],className:"react-flow__edge-textbg",style:l,rx:r,ry:r}),(0,O.jsx)("text",{className:"react-flow__edge-text",y:d.height/2,dy:"0.3em",ref:y,style:o,children:n}),u]}):null}Ex.displayName="EdgeText";var G3=(0,D.memo)(Ex);function wl({path:t,labelX:e,labelY:n,label:o,labelStyle:a,labelShowBg:l,labelBgStyle:i,labelBgPadding:r,labelBgBorderRadius:u,interactionWidth:s=20,...c}){return(0,O.jsxs)(O.Fragment,{children:[(0,O.jsx)("path",{...c,d:t,fill:"none",className:Tt(["react-flow__edge-path",c.className])}),s?(0,O.jsx)("path",{d:t,fill:"none",strokeOpacity:0,strokeWidth:s,className:"react-flow__edge-interaction"}):null,o&&Ye(e)&&Ye(n)?(0,O.jsx)(G3,{x:e,y:n,label:o,labelStyle:a,labelShowBg:l,labelBgStyle:i,labelBgPadding:r,labelBgBorderRadius:u}):null]})}function nx({pos:t,x1:e,y1:n,x2:o,y2:a}){return t===G.Left||t===G.Right?[.5*(e+o),n]:[e,.5*(n+a)]}function Nx({sourceX:t,sourceY:e,sourcePosition:n=G.Bottom,targetX:o,targetY:a,targetPosition:l=G.Top}){let[i,r]=nx({pos:n,x1:t,y1:e,x2:o,y2:a}),[u,s]=nx({pos:l,x1:o,y1:a,x2:t,y2:e}),[c,d,f,p]=bc({sourceX:t,sourceY:e,targetX:o,targetY:a,sourceControlX:i,sourceControlY:r,targetControlX:u,targetControlY:s});return[`M${t},${e} C${i},${r} ${u},${s} ${o},${a}`,c,d,f,p]}function Mx(t){return(0,D.memo)(({id:e,sourceX:n,sourceY:o,targetX:a,targetY:l,sourcePosition:i,targetPosition:r,label:u,labelStyle:s,labelShowBg:c,labelBgStyle:d,labelBgPadding:f,labelBgBorderRadius:p,style:y,markerEnd:b,markerStart:x,interactionWidth:g})=>{let[m,h,v]=Nx({sourceX:n,sourceY:o,sourcePosition:i,targetX:a,targetY:l,targetPosition:r}),_=t.isInternal?void 0:e;return(0,O.jsx)(wl,{id:_,path:m,labelX:h,labelY:v,label:u,labelStyle:s,labelShowBg:c,labelBgStyle:d,labelBgPadding:f,labelBgBorderRadius:p,style:y,markerEnd:b,markerStart:x,interactionWidth:g})})}var Q3=Mx({isInternal:!1}),zx=Mx({isInternal:!0});Q3.displayName="SimpleBezierEdge";zx.displayName="SimpleBezierEdgeInternal";function Ax(t){return(0,D.memo)(({id:e,sourceX:n,sourceY:o,targetX:a,targetY:l,label:i,labelStyle:r,labelShowBg:u,labelBgStyle:s,labelBgPadding:c,labelBgBorderRadius:d,style:f,sourcePosition:p=G.Bottom,targetPosition:y=G.Top,markerEnd:b,markerStart:x,pathOptions:g,interactionWidth:m})=>{let[h,v,_]=da({sourceX:n,sourceY:o,sourcePosition:p,targetX:a,targetY:l,targetPosition:y,borderRadius:g?.borderRadius,offset:g?.offset,stepPosition:g?.stepPosition}),E=t.isInternal?void 0:e;return(0,O.jsx)(wl,{id:E,path:h,labelX:v,labelY:_,label:i,labelStyle:r,labelShowBg:u,labelBgStyle:s,labelBgPadding:c,labelBgBorderRadius:d,style:f,markerEnd:b,markerStart:x,interactionWidth:m})})}var Cx=Ax({isInternal:!1}),Tx=Ax({isInternal:!0});Cx.displayName="SmoothStepEdge";Tx.displayName="SmoothStepEdgeInternal";function Ox(t){return(0,D.memo)(({id:e,...n})=>{let o=t.isInternal?void 0:e;return(0,O.jsx)(Cx,{...n,id:o,pathOptions:(0,D.useMemo)(()=>({borderRadius:0,offset:n.pathOptions?.offset}),[n.pathOptions?.offset])})})}var j3=Ox({isInternal:!1}),Dx=Ox({isInternal:!0});j3.displayName="StepEdge";Dx.displayName="StepEdgeInternal";function Hx(t){return(0,D.memo)(({id:e,sourceX:n,sourceY:o,targetX:a,targetY:l,label:i,labelStyle:r,labelShowBg:u,labelBgStyle:s,labelBgPadding:c,labelBgBorderRadius:d,style:f,markerEnd:p,markerStart:y,interactionWidth:b})=>{let[x,g,m]=Sc({sourceX:n,sourceY:o,targetX:a,targetY:l}),h=t.isInternal?void 0:e;return(0,O.jsx)(wl,{id:h,path:x,labelX:g,labelY:m,label:i,labelStyle:r,labelShowBg:u,labelBgStyle:s,labelBgPadding:c,labelBgBorderRadius:d,style:f,markerEnd:p,markerStart:y,interactionWidth:b})})}var K3=Hx({isInternal:!1}),Rx=Hx({isInternal:!0});K3.displayName="StraightEdge";Rx.displayName="StraightEdgeInternal";function Bx(t){return(0,D.memo)(({id:e,sourceX:n,sourceY:o,targetX:a,targetY:l,sourcePosition:i=G.Bottom,targetPosition:r=G.Top,label:u,labelStyle:s,labelShowBg:c,labelBgStyle:d,labelBgPadding:f,labelBgBorderRadius:p,style:y,markerEnd:b,markerStart:x,pathOptions:g,interactionWidth:m})=>{let[h,v,_]=xc({sourceX:n,sourceY:o,sourcePosition:i,targetX:a,targetY:l,targetPosition:r,curvature:g?.curvature}),E=t.isInternal?void 0:e;return(0,O.jsx)(wl,{id:E,path:h,labelX:v,labelY:_,label:u,labelStyle:s,labelShowBg:c,labelBgStyle:d,labelBgPadding:f,labelBgBorderRadius:p,style:y,markerEnd:b,markerStart:x,interactionWidth:m})})}var $3=Bx({isInternal:!1}),kx=Bx({isInternal:!0});$3.displayName="BezierEdge";kx.displayName="BezierEdgeInternal";var ox={default:kx,straight:Rx,step:Dx,smoothstep:Tx,simplebezier:zx},ax={sourceX:null,sourceY:null,targetX:null,targetY:null,sourcePosition:null,targetPosition:null},J3=(t,e,n)=>n===G.Left?t-e:n===G.Right?t+e:t,I3=(t,e,n)=>n===G.Top?t-e:n===G.Bottom?t+e:t,lx="react-flow__edgeupdater";function ix({position:t,centerX:e,centerY:n,radius:o=10,onMouseDown:a,onMouseEnter:l,onMouseOut:i,type:r}){return(0,O.jsx)("circle",{onMouseDown:a,onMouseEnter:l,onMouseOut:i,className:Tt([lx,`${lx}-${r}`]),cx:J3(e,o,t),cy:I3(n,o,t),r:o,stroke:"transparent",fill:"transparent"})}function W3({isReconnectable:t,reconnectRadius:e,edge:n,sourceX:o,sourceY:a,targetX:l,targetY:i,sourcePosition:r,targetPosition:u,onReconnect:s,onReconnectStart:c,onReconnectEnd:d,setReconnecting:f,setUpdateHover:p}){let y=zt(),b=(v,_)=>{if(v.button!==0)return;let{autoPanOnConnect:E,domNode:w,connectionMode:N,connectionRadius:M,lib:R,onConnectStart:C,cancelConnection:k,nodeLookup:V,rfId:S,panBy:A,updateConnection:z}=y.getState(),T=_.type==="target",B=(Z,q)=>{f(!1),d?.(Z,n,_.type,q)},H=Z=>s?.(n,Z),X=(Z,q)=>{f(!0),c?.(v,n,_.type),C?.(Z,q)};Nc.onPointerDown(v.nativeEvent,{autoPanOnConnect:E,connectionMode:N,connectionRadius:M,domNode:w,handleId:_.id,nodeId:_.nodeId,nodeLookup:V,isTarget:T,edgeUpdaterType:_.type,lib:R,flowId:S,cancelConnection:k,panBy:A,isValidConnection:(...Z)=>y.getState().isValidConnection?.(...Z)??!0,onConnect:H,onConnectStart:X,onConnectEnd:(...Z)=>y.getState().onConnectEnd?.(...Z),onReconnectEnd:B,updateConnection:z,getTransform:()=>y.getState().transform,getFromHandle:()=>y.getState().connection.fromHandle,dragThreshold:y.getState().connectionDragThreshold,handleDomNode:v.currentTarget})},x=v=>b(v,{nodeId:n.target,id:n.targetHandle??null,type:"target"}),g=v=>b(v,{nodeId:n.source,id:n.sourceHandle??null,type:"source"}),m=()=>p(!0),h=()=>p(!1);return(0,O.jsxs)(O.Fragment,{children:[(t===!0||t==="source")&&(0,O.jsx)(ix,{position:r,centerX:o,centerY:a,radius:e,onMouseDown:x,onMouseEnter:m,onMouseOut:h,type:"source"}),(t===!0||t==="target")&&(0,O.jsx)(ix,{position:u,centerX:l,centerY:i,radius:e,onMouseDown:g,onMouseEnter:m,onMouseOut:h,type:"target"})]})}function F3({id:t,edgesFocusable:e,edgesReconnectable:n,elementsSelectable:o,onClick:a,onDoubleClick:l,onContextMenu:i,onMouseEnter:r,onMouseMove:u,onMouseLeave:s,reconnectRadius:c,onReconnect:d,onReconnectStart:f,onReconnectEnd:p,rfId:y,edgeTypes:b,noPanClassName:x,onError:g,disableKeyboardA11y:m}){let h=ut($=>$.edgeLookup.get(t)),v=ut($=>$.defaultEdgeOptions);h=v?{...v,...h}:h;let _=h.type||"default",E=b?.[_]||ox[_];E===void 0&&(g?.("011",Me.error011(_)),_="default",E=b?.default||ox.default);let w=!!(h.focusable||e&&typeof h.focusable>"u"),N=typeof d<"u"&&(h.reconnectable||n&&typeof h.reconnectable>"u"),M=!!(h.selectable||o&&typeof h.selectable>"u"),R=(0,D.useRef)(null),[C,k]=(0,D.useState)(!1),[V,S]=(0,D.useState)(!1),A=zt(),{zIndex:z,sourceX:T,sourceY:B,targetX:H,targetY:X,sourcePosition:Z,targetPosition:q}=ut((0,D.useCallback)($=>{let W=$.nodeLookup.get(h.source),ct=$.nodeLookup.get(h.target);if(!W||!ct)return{zIndex:h.zIndex,...ax};let dt=rb({id:t,sourceNode:W,targetNode:ct,sourceHandle:h.sourceHandle||null,targetHandle:h.targetHandle||null,connectionMode:$.connectionMode,onError:g});return{zIndex:ab({selected:h.selected,zIndex:h.zIndex,sourceNode:W,targetNode:ct,elevateOnSelect:$.elevateEdgesOnSelect,zIndexMode:$.zIndexMode}),...dt||ax}},[h.source,h.target,h.sourceHandle,h.targetHandle,h.selected,h.zIndex]),Et),K=(0,D.useMemo)(()=>h.markerStart?`url('#${_c(h.markerStart,y)}')`:void 0,[h.markerStart,y]),j=(0,D.useMemo)(()=>h.markerEnd?`url('#${_c(h.markerEnd,y)}')`:void 0,[h.markerEnd,y]);if(h.hidden||T===null||B===null||H===null||X===null)return null;let I=$=>{let{addSelectedEdges:W,unselectNodesAndEdges:ct,multiSelectionActive:dt}=A.getState();M&&(A.setState({nodesSelectionActive:!1}),h.selected&&dt?(ct({nodes:[],edges:[h]}),R.current?.blur()):W([t])),a&&a($,h)},ot=l?$=>{l($,{...h})}:void 0,J=i?$=>{i($,{...h})}:void 0,U=r?$=>{r($,{...h})}:void 0,Q=u?$=>{u($,{...h})}:void 0,nt=s?$=>{s($,{...h})}:void 0,tt=$=>{if(!m&&nh.includes($.key)&&M){let{unselectNodesAndEdges:W,addSelectedEdges:ct}=A.getState();$.key==="Escape"?(R.current?.blur(),W({edges:[h]})):ct([t])}};return(0,O.jsx)("svg",{style:{zIndex:z},children:(0,O.jsxs)("g",{className:Tt(["react-flow__edge",`react-flow__edge-${_}`,h.className,x,{selected:h.selected,animated:h.animated,inactive:!M&&!a,updating:C,selectable:M}]),onClick:I,onDoubleClick:ot,onContextMenu:J,onMouseEnter:U,onMouseMove:Q,onMouseLeave:nt,onKeyDown:w?tt:void 0,tabIndex:w?0:void 0,role:h.ariaRole??(w?"group":"img"),"aria-roledescription":"edge","data-id":t,"data-testid":`rf__edge-${t}`,"aria-label":h.ariaLabel===null?void 0:h.ariaLabel||`Edge from ${h.source} to ${h.target}`,"aria-describedby":w?`${hx}-${y}`:void 0,ref:R,...h.domAttributes,children:[!V&&(0,O.jsx)(E,{id:t,source:h.source,target:h.target,type:h.type,selected:h.selected,animated:h.animated,selectable:M,deletable:h.deletable??!0,label:h.label,labelStyle:h.labelStyle,labelShowBg:h.labelShowBg,labelBgStyle:h.labelBgStyle,labelBgPadding:h.labelBgPadding,labelBgBorderRadius:h.labelBgBorderRadius,sourceX:T,sourceY:B,targetX:H,targetY:X,sourcePosition:Z,targetPosition:q,data:h.data,style:h.style,sourceHandleId:h.sourceHandle,targetHandleId:h.targetHandle,markerStart:K,markerEnd:j,pathOptions:"pathOptions"in h?h.pathOptions:void 0,interactionWidth:h.interactionWidth}),N&&(0,O.jsx)(W3,{edge:h,isReconnectable:N,reconnectRadius:c,onReconnect:d,onReconnectStart:f,onReconnectEnd:p,sourceX:T,sourceY:B,targetX:H,targetY:X,sourcePosition:Z,targetPosition:q,setUpdateHover:k,setReconnecting:S})]})})}var P3=(0,D.memo)(F3),tA=t=>({edgesFocusable:t.edgesFocusable,edgesReconnectable:t.edgesReconnectable,elementsSelectable:t.elementsSelectable,connectionMode:t.connectionMode,onError:t.onError});function Lx({defaultMarkerColor:t,onlyRenderVisibleElements:e,rfId:n,edgeTypes:o,noPanClassName:a,onReconnect:l,onEdgeContextMenu:i,onEdgeMouseEnter:r,onEdgeMouseMove:u,onEdgeMouseLeave:s,onEdgeClick:c,reconnectRadius:d,onEdgeDoubleClick:f,onReconnectStart:p,onReconnectEnd:y,disableKeyboardA11y:b}){let{edgesFocusable:x,edgesReconnectable:g,elementsSelectable:m,onError:h}=ut(tA,Et),v=U3(e);return(0,O.jsxs)("div",{className:"react-flow__edges",children:[(0,O.jsx)(Z3,{defaultColor:t,rfId:n}),v.map(_=>(0,O.jsx)(P3,{id:_,edgesFocusable:x,edgesReconnectable:g,elementsSelectable:m,noPanClassName:a,onReconnect:l,onContextMenu:i,onMouseEnter:r,onMouseMove:u,onMouseLeave:s,onClick:c,reconnectRadius:d,onDoubleClick:f,onReconnectStart:p,onReconnectEnd:y,rfId:n,onError:h,edgeTypes:o,disableKeyboardA11y:b},_))]})}Lx.displayName="EdgeRenderer";var eA=(0,D.memo)(Lx),nA=t=>`translate(${t.transform[0]}px,${t.transform[1]}px) scale(${t.transform[2]})`;function oA({children:t}){let e=ut(nA);return(0,O.jsx)("div",{className:"react-flow__viewport xyflow__viewport react-flow__container",style:{transform:e},children:t})}function aA(t){let e=Th(),n=(0,D.useRef)(!1);(0,D.useEffect)(()=>{!n.current&&e.viewportInitialized&&t&&(setTimeout(()=>t(e),1),n.current=!0)},[t,e.viewportInitialized])}var lA=t=>t.panZoom?.syncViewport;function iA(t){let e=ut(lA),n=zt();return(0,D.useEffect)(()=>{t&&(e?.(t),n.setState({transform:[t.x,t.y,t.zoom]}))},[t,e]),null}function rx(t){return t.connection.inProgress?{...t.connection,to:fa(t.connection.to,t.transform)}:{...t.connection}}function rA(t){return t?n=>{let o=rx(n);return t(o)}:rx}function uA(t){let e=rA(t);return ut(e,Et)}var cA=t=>({nodesConnectable:t.nodesConnectable,isValid:t.connection.isValid,inProgress:t.connection.inProgress,width:t.width,height:t.height});function sA({containerStyle:t,style:e,type:n,component:o}){let{nodesConnectable:a,width:l,height:i,isValid:r,inProgress:u}=ut(cA,Et);return!(l&&a&&u)?null:(0,O.jsx)("svg",{style:t,width:l,height:i,className:"react-flow__connectionline react-flow__container",children:(0,O.jsx)("g",{className:Tt(["react-flow__connection",lh(r)]),children:(0,O.jsx)(Ux,{style:e,type:n,CustomComponent:o,isValid:r})})})}var Ux=({style:t,type:e=rn.Bezier,CustomComponent:n,isValid:o})=>{let{inProgress:a,from:l,fromNode:i,fromHandle:r,fromPosition:u,to:s,toNode:c,toHandle:d,toPosition:f,pointer:p}=uA();if(!a)return;if(n)return(0,O.jsx)(n,{connectionLineType:e,connectionLineStyle:t,fromNode:i,fromHandle:r,fromX:l.x,fromY:l.y,toX:s.x,toY:s.y,fromPosition:u,toPosition:f,connectionStatus:lh(o),toNode:c,toHandle:d,pointer:p});let y="",b={sourceX:l.x,sourceY:l.y,sourcePosition:u,targetX:s.x,targetY:s.y,targetPosition:f};switch(e){case rn.Bezier:[y]=xc(b);break;case rn.SimpleBezier:[y]=Nx(b);break;case rn.Step:[y]=da({...b,borderRadius:0});break;case rn.SmoothStep:[y]=da(b);break;default:[y]=Sc(b)}return(0,O.jsx)("path",{d:y,fill:"none",className:"react-flow__connection-path",style:t})};Ux.displayName="ConnectionLine";var fA={};function ux(t=fA){let e=(0,D.useRef)(t),n=zt();(0,D.useEffect)(()=>{},[t])}function dA(){let t=zt(),e=(0,D.useRef)(!1);(0,D.useEffect)(()=>{},[])}function Yx({nodeTypes:t,edgeTypes:e,onInit:n,onNodeClick:o,onEdgeClick:a,onNodeDoubleClick:l,onEdgeDoubleClick:i,onNodeMouseEnter:r,onNodeMouseMove:u,onNodeMouseLeave:s,onNodeContextMenu:c,onSelectionContextMenu:d,onSelectionStart:f,onSelectionEnd:p,connectionLineType:y,connectionLineStyle:b,connectionLineComponent:x,connectionLineContainerStyle:g,selectionKeyCode:m,selectionOnDrag:h,selectionMode:v,multiSelectionKeyCode:_,panActivationKeyCode:E,zoomActivationKeyCode:w,deleteKeyCode:N,onlyRenderVisibleElements:M,elementsSelectable:R,defaultViewport:C,translateExtent:k,minZoom:V,maxZoom:S,preventScrolling:A,defaultMarkerColor:z,zoomOnScroll:T,zoomOnPinch:B,panOnScroll:H,panOnScrollSpeed:X,panOnScrollMode:Z,zoomOnDoubleClick:q,panOnDrag:K,autoPanOnSelection:j,onPaneClick:I,onPaneMouseEnter:ot,onPaneMouseMove:J,onPaneMouseLeave:U,onPaneScroll:Q,onPaneContextMenu:nt,paneClickDistance:tt,nodeClickDistance:$,onEdgeContextMenu:W,onEdgeMouseEnter:ct,onEdgeMouseMove:dt,onEdgeMouseLeave:Dt,reconnectRadius:ie,onReconnect:cn,onReconnectStart:Je,onReconnectEnd:Ie,noDragClassName:sn,noWheelClassName:El,noPanClassName:Mo,disableKeyboardA11y:zo,nodeExtent:qe,rfId:fn,viewport:dn,onViewportChange:Ao}){return ux(t),ux(e),dA(),aA(n),iA(dn),(0,O.jsx)(A3,{onPaneClick:I,onPaneMouseEnter:ot,onPaneMouseMove:J,onPaneMouseLeave:U,onPaneContextMenu:nt,onPaneScroll:Q,paneClickDistance:tt,deleteKeyCode:N,selectionKeyCode:m,selectionOnDrag:h,selectionMode:v,onSelectionStart:f,onSelectionEnd:p,multiSelectionKeyCode:_,panActivationKeyCode:E,zoomActivationKeyCode:w,elementsSelectable:R,zoomOnScroll:T,zoomOnPinch:B,zoomOnDoubleClick:q,panOnScroll:H,panOnScrollSpeed:X,panOnScrollMode:Z,panOnDrag:K,autoPanOnSelection:j,defaultViewport:C,translateExtent:k,minZoom:V,maxZoom:S,onSelectionContextMenu:d,preventScrolling:A,noDragClassName:sn,noWheelClassName:El,noPanClassName:Mo,disableKeyboardA11y:zo,onViewportChange:Ao,isControlledViewport:!!dn,children:(0,O.jsxs)(oA,{children:[(0,O.jsx)(eA,{edgeTypes:e,onEdgeClick:a,onEdgeDoubleClick:i,onReconnect:cn,onReconnectStart:Je,onReconnectEnd:Ie,onlyRenderVisibleElements:M,onEdgeContextMenu:W,onEdgeMouseEnter:ct,onEdgeMouseMove:dt,onEdgeMouseLeave:Dt,reconnectRadius:ie,defaultMarkerColor:z,noPanClassName:Mo,disableKeyboardA11y:zo,rfId:fn}),(0,O.jsx)(sA,{style:b,type:y,component:x,containerStyle:g}),(0,O.jsx)("div",{className:"react-flow__edgelabel-renderer"}),(0,O.jsx)(L3,{nodeTypes:t,onNodeClick:o,onNodeDoubleClick:l,onNodeMouseEnter:r,onNodeMouseMove:u,onNodeMouseLeave:s,onNodeContextMenu:c,nodeClickDistance:$,onlyRenderVisibleElements:M,noPanClassName:Mo,noDragClassName:sn,disableKeyboardA11y:zo,nodeExtent:qe,rfId:fn}),(0,O.jsx)("div",{className:"react-flow__viewport-portal"})]})})}Yx.displayName="GraphView";var hA=(0,D.memo)(Yx),pA=dh("React Flow","https://reactflow.dev/"),cx=({nodes:t,edges:e,defaultNodes:n,defaultEdges:o,width:a,height:l,fitView:i,fitViewOptions:r,minZoom:u=.5,maxZoom:s=2,nodeOrigin:c,nodeExtent:d,zIndexMode:f="basic"}={})=>{let p=new Map,y=new Map,b=new Map,x=new Map,g=o??e??[],m=n??t??[],h=c??[0,0],v=d??ml;Eh(b,x,g);let{nodesInitialized:_}=wc(m,p,y,{nodeOrigin:h,nodeExtent:v,zIndexMode:f}),E=[0,0,1];if(i&&a&&l){let w=yl(p,{filter:C=>!!((C.width||C.initialWidth)&&(C.height||C.initialHeight))}),{x:N,y:M,zoom:R}=Fi(w,a,l,u,s,r?.padding??.1);E=[N,M,R]}return{rfId:"1",width:a??0,height:l??0,transform:E,nodes:m,nodesInitialized:_,nodeLookup:p,parentLookup:y,edges:g,edgeLookup:x,connectionLookup:b,onNodesChange:null,onEdgesChange:null,hasDefaultNodes:n!==void 0,hasDefaultEdges:o!==void 0,panZoom:null,minZoom:u,maxZoom:s,translateExtent:ml,nodeExtent:v,nodesSelectionActive:!1,userSelectionActive:!1,userSelectionRect:null,connectionMode:So.Strict,domNode:null,paneDragging:!1,noPanClassName:"nopan",nodeOrigin:h,nodeDragThreshold:1,connectionDragThreshold:1,snapGrid:[15,15],snapToGrid:!1,nodesDraggable:!0,nodesConnectable:!0,nodesFocusable:!0,edgesFocusable:!0,edgesReconnectable:!0,elementsSelectable:!0,elevateNodesOnSelect:!0,elevateEdgesOnSelect:!0,selectNodesOnDrag:!0,multiSelectionActive:!1,fitViewQueued:i??!1,fitViewOptions:r,fitViewResolver:null,connection:{...ah},connectionClickStartHandle:null,connectOnClick:!0,ariaLiveMessage:"",autoPanOnConnect:!0,autoPanOnNodeDrag:!0,autoPanOnNodeFocus:!0,autoPanSpeed:15,connectionRadius:20,onError:pA,isValidConnection:void 0,onSelectionChangeHandlers:[],lib:"react",debug:!1,ariaLabelConfig:oh,zIndexMode:f,onNodesChangeMiddlewareMap:new Map,onEdgesChangeMiddlewareMap:new Map}},gA=({nodes:t,edges:e,defaultNodes:n,defaultEdges:o,width:a,height:l,fitView:i,fitViewOptions:r,minZoom:u,maxZoom:s,nodeOrigin:c,nodeExtent:d,zIndexMode:f})=>Vb((p,y)=>{async function b(){let{nodeLookup:x,panZoom:g,fitViewOptions:m,fitViewResolver:h,width:v,height:_,minZoom:E,maxZoom:w}=y();g&&(await P1({nodes:x,width:v,height:_,panZoom:g,minZoom:E,maxZoom:w},m),h?.resolve(!0),p({fitViewResolver:null}))}return{...cx({nodes:t,edges:e,width:a,height:l,fitView:i,fitViewOptions:r,minZoom:u,maxZoom:s,nodeOrigin:c,nodeExtent:d,defaultNodes:n,defaultEdges:o,zIndexMode:f}),setNodes:x=>{let{nodeLookup:g,parentLookup:m,nodeOrigin:h,elevateNodesOnSelect:v,fitViewQueued:_,zIndexMode:E,nodesSelectionActive:w}=y(),{nodesInitialized:N,hasSelectedNodes:M}=wc(x,g,m,{nodeOrigin:h,nodeExtent:d,elevateNodesOnSelect:v,checkEquality:!0,zIndexMode:E}),R=w&&M;_&&N?(b(),p({nodes:x,nodesInitialized:N,fitViewQueued:!1,fitViewOptions:void 0,nodesSelectionActive:R})):p({nodes:x,nodesInitialized:N,nodesSelectionActive:R})},setEdges:x=>{let{connectionLookup:g,edgeLookup:m}=y();Eh(g,m,x),p({edges:x})},setDefaultNodesAndEdges:(x,g)=>{if(x){let{setNodes:m}=y();m(x),p({hasDefaultNodes:!0})}if(g){let{setEdges:m}=y();m(g),p({hasDefaultEdges:!0})}},updateNodeInternals:x=>{let{triggerNodeChanges:g,nodeLookup:m,parentLookup:h,domNode:v,nodeOrigin:_,nodeExtent:E,debug:w,fitViewQueued:N,zIndexMode:M}=y(),{changes:R,updatedInternals:C}=db(x,m,h,v,_,E,M);C&&(sb(m,h,{nodeOrigin:_,nodeExtent:E,zIndexMode:M}),N?(b(),p({fitViewQueued:!1,fitViewOptions:void 0})):p({}),R?.length>0&&(w&&console.log("React Flow: trigger node changes",R),g?.(R)))},updateNodePositions:(x,g=!1)=>{let m=[],h=[],{nodeLookup:v,triggerNodeChanges:_,connection:E,updateConnection:w,onNodesChangeMiddlewareMap:N}=y();for(let[M,R]of x){let C=v.get(M),k=!!(C?.expandParent&&C?.parentId&&R?.position),V={id:M,type:"position",position:k?{x:Math.max(0,R.position.x),y:Math.max(0,R.position.y)}:R.position,dragging:g};if(C&&E.inProgress&&E.fromNode.id===C.id){let S=_o(C,E.fromHandle,G.Left,!0);w({...E,from:S})}k&&C.parentId&&m.push({id:M,parentId:C.parentId,rect:{...R.internals.positionAbsolute,width:R.measured.width??0,height:R.measured.height??0}}),h.push(V)}if(m.length>0){let{parentLookup:M,nodeOrigin:R}=y(),C=Ec(m,v,M,R);h.push(...C)}for(let M of N.values())h=M(h);_(h)},triggerNodeChanges:x=>{let{onNodesChange:g,setNodes:m,nodes:h,hasDefaultNodes:v,debug:_}=y();if(x?.length){if(v){let E=Iz(x,h);m(E)}_&&console.log("React Flow: trigger node changes",x),g?.(x)}},triggerEdgeChanges:x=>{let{onEdgesChange:g,setEdges:m,edges:h,hasDefaultEdges:v,debug:_}=y();if(x?.length){if(v){let E=Wz(x,h);m(E)}_&&console.log("React Flow: trigger edge changes",x),g?.(x)}},addSelectedNodes:x=>{let{multiSelectionActive:g,edgeLookup:m,nodeLookup:h,triggerNodeChanges:v,triggerEdgeChanges:_}=y();if(g){let E=x.map(w=>ha(w,!0));v(E);return}v(_l(h,new Set([...x]),!0)),_(_l(m))},addSelectedEdges:x=>{let{multiSelectionActive:g,edgeLookup:m,nodeLookup:h,triggerNodeChanges:v,triggerEdgeChanges:_}=y();if(g){let E=x.map(w=>ha(w,!0));_(E);return}_(_l(m,new Set([...x]))),v(_l(h,new Set,!0))},unselectNodesAndEdges:({nodes:x,edges:g}={})=>{let{edges:m,nodes:h,nodeLookup:v,triggerNodeChanges:_,triggerEdgeChanges:E}=y(),w=x||h,N=g||m,M=[];for(let C of w){if(!C.selected)continue;let k=v.get(C.id);k&&(k.selected=!1),M.push(ha(C.id,!1))}let R=[];for(let C of N)C.selected&&R.push(ha(C.id,!1));_(M),E(R)},setMinZoom:x=>{let{panZoom:g,maxZoom:m}=y();g?.setScaleExtent([x,m]),p({minZoom:x})},setMaxZoom:x=>{let{panZoom:g,minZoom:m}=y();g?.setScaleExtent([m,x]),p({maxZoom:x})},setTranslateExtent:x=>{y().panZoom?.setTranslateExtent(x),p({translateExtent:x})},resetSelectedElements:()=>{let{edges:x,nodes:g,triggerNodeChanges:m,triggerEdgeChanges:h,elementsSelectable:v}=y();if(!v)return;let _=g.reduce((w,N)=>N.selected?[...w,ha(N.id,!1)]:w,[]),E=x.reduce((w,N)=>N.selected?[...w,ha(N.id,!1)]:w,[]);m(_),h(E)},setNodeExtent:x=>{let{nodes:g,nodeLookup:m,parentLookup:h,nodeOrigin:v,elevateNodesOnSelect:_,nodeExtent:E,zIndexMode:w}=y();x[0][0]===E[0][0]&&x[0][1]===E[0][1]&&x[1][0]===E[1][0]&&x[1][1]===E[1][1]||(wc(g,m,h,{nodeOrigin:v,nodeExtent:x,elevateNodesOnSelect:_,checkEquality:!1,zIndexMode:w}),p({nodeExtent:x}))},panBy:x=>{let{transform:g,width:m,height:h,panZoom:v,translateExtent:_}=y();return hb({delta:x,panZoom:v,transform:g,translateExtent:_,width:m,height:h})},setCenter:async(x,g,m)=>{let{width:h,height:v,maxZoom:_,panZoom:E}=y();if(!E)return!1;let w=typeof m?.zoom<"u"?m.zoom:_;return await E.setViewport({x:h/2-x*w,y:v/2-g*w,zoom:w},{duration:m?.duration,ease:m?.ease,interpolate:m?.interpolate}),!0},cancelConnection:()=>{p({connection:{...ah}})},updateConnection:x=>{p({connection:x})},reset:()=>p({...cx()})}},Object.is);function mA({initialNodes:t,initialEdges:e,defaultNodes:n,defaultEdges:o,initialWidth:a,initialHeight:l,initialMinZoom:i,initialMaxZoom:r,initialFitViewOptions:u,fitView:s,nodeOrigin:c,nodeExtent:d,zIndexMode:f,children:p}){let[y]=(0,D.useState)(()=>gA({nodes:t,edges:e,defaultNodes:n,defaultEdges:o,width:a,height:l,fitView:s,minZoom:i,maxZoom:r,fitViewOptions:u,nodeOrigin:c,nodeExtent:d,zIndexMode:f}));return(0,O.jsx)(Tz,{value:y,children:(0,O.jsx)(o3,{children:p})})}function yA({children:t,nodes:e,edges:n,defaultNodes:o,defaultEdges:a,width:l,height:i,fitView:r,fitViewOptions:u,minZoom:s,maxZoom:c,nodeOrigin:d,nodeExtent:f,zIndexMode:p}){return(0,D.useContext)(Oc)?(0,O.jsx)(O.Fragment,{children:t}):(0,O.jsx)(mA,{initialNodes:e,initialEdges:n,defaultNodes:o,defaultEdges:a,initialWidth:l,initialHeight:i,fitView:r,initialFitViewOptions:u,initialMinZoom:s,initialMaxZoom:c,nodeOrigin:d,nodeExtent:f,zIndexMode:p,children:t})}var vA={width:"100%",height:"100%",overflow:"hidden",position:"relative",zIndex:0};function bA({nodes:t,edges:e,defaultNodes:n,defaultEdges:o,className:a,nodeTypes:l,edgeTypes:i,onNodeClick:r,onEdgeClick:u,onInit:s,onMove:c,onMoveStart:d,onMoveEnd:f,onConnect:p,onConnectStart:y,onConnectEnd:b,onClickConnectStart:x,onClickConnectEnd:g,onNodeMouseEnter:m,onNodeMouseMove:h,onNodeMouseLeave:v,onNodeContextMenu:_,onNodeDoubleClick:E,onNodeDragStart:w,onNodeDrag:N,onNodeDragStop:M,onNodesDelete:R,onEdgesDelete:C,onDelete:k,onSelectionChange:V,onSelectionDragStart:S,onSelectionDrag:A,onSelectionDragStop:z,onSelectionContextMenu:T,onSelectionStart:B,onSelectionEnd:H,onBeforeDelete:X,connectionMode:Z,connectionLineType:q=rn.Bezier,connectionLineStyle:K,connectionLineComponent:j,connectionLineContainerStyle:I,deleteKeyCode:ot="Backspace",selectionKeyCode:J="Shift",selectionOnDrag:U=!1,selectionMode:Q=ia.Full,panActivationKeyCode:nt="Space",multiSelectionKeyCode:tt=xl()?"Meta":"Control",zoomActivationKeyCode:$=xl()?"Meta":"Control",snapToGrid:W,snapGrid:ct,onlyRenderVisibleElements:dt=!1,selectNodesOnDrag:Dt,nodesDraggable:ie,autoPanOnNodeFocus:cn,nodesConnectable:Je,nodesFocusable:Ie,nodeOrigin:sn=px,edgesFocusable:El,edgesReconnectable:Mo,elementsSelectable:zo=!0,defaultViewport:qe=Zz,minZoom:fn=.5,maxZoom:dn=2,translateExtent:Ao=ml,preventScrolling:Px=!0,nodeExtent:Bc,defaultMarkerColor:tS="#b1b1b7",zoomOnScroll:eS=!0,zoomOnPinch:nS=!0,panOnScroll:oS=!1,panOnScrollSpeed:aS=.5,panOnScrollMode:lS=Un.Free,zoomOnDoubleClick:iS=!0,panOnDrag:rS=!0,onPaneClick:uS,onPaneMouseEnter:cS,onPaneMouseMove:sS,onPaneMouseLeave:fS,onPaneScroll:dS,onPaneContextMenu:hS,paneClickDistance:pS=1,nodeClickDistance:gS=0,children:mS,onReconnect:yS,onReconnectStart:vS,onReconnectEnd:bS,onEdgeContextMenu:xS,onEdgeDoubleClick:SS,onEdgeMouseEnter:_S,onEdgeMouseMove:wS,onEdgeMouseLeave:ES,reconnectRadius:NS=10,onNodesChange:MS,onEdgesChange:zS,noDragClassName:AS="nodrag",noWheelClassName:CS="nowheel",noPanClassName:Dh="nopan",fitView:Hh,fitViewOptions:Rh,connectOnClick:TS,attributionPosition:OS,proOptions:DS,defaultEdgeOptions:HS,elevateNodesOnSelect:RS=!0,elevateEdgesOnSelect:BS=!1,disableKeyboardA11y:Bh=!1,autoPanOnConnect:kS,autoPanOnNodeDrag:LS,autoPanOnSelection:US=!0,autoPanSpeed:YS,connectionRadius:VS,isValidConnection:qS,onError:XS,style:ZS,id:kh,nodeDragThreshold:GS,connectionDragThreshold:QS,viewport:jS,onViewportChange:KS,width:$S,height:JS,colorMode:IS="light",debug:WS,onScroll:Lh,ariaLabelConfig:FS,zIndexMode:Uh="basic",...PS},t_){let kc=kh||"1",e_=Kz(IS),n_=(0,D.useCallback)(Yh=>{Yh.currentTarget.scrollTo({top:0,left:0,behavior:"instant"}),Lh?.(Yh)},[Lh]);return(0,O.jsx)("div",{"data-testid":"rf__wrapper",...PS,onScroll:n_,style:{...ZS,...vA},ref:t_,className:Tt(["react-flow",a,e_]),id:kh,role:"application",children:(0,O.jsxs)(yA,{nodes:t,edges:e,width:$S,height:JS,fitView:Hh,fitViewOptions:Rh,minZoom:fn,maxZoom:dn,nodeOrigin:sn,nodeExtent:Bc,zIndexMode:Uh,children:[(0,O.jsx)(jz,{nodes:t,edges:e,defaultNodes:n,defaultEdges:o,onConnect:p,onConnectStart:y,onConnectEnd:b,onClickConnectStart:x,onClickConnectEnd:g,nodesDraggable:ie,autoPanOnNodeFocus:cn,nodesConnectable:Je,nodesFocusable:Ie,edgesFocusable:El,edgesReconnectable:Mo,elementsSelectable:zo,elevateNodesOnSelect:RS,elevateEdgesOnSelect:BS,minZoom:fn,maxZoom:dn,nodeExtent:Bc,onNodesChange:MS,onEdgesChange:zS,snapToGrid:W,snapGrid:ct,connectionMode:Z,translateExtent:Ao,connectOnClick:TS,defaultEdgeOptions:HS,fitView:Hh,fitViewOptions:Rh,onNodesDelete:R,onEdgesDelete:C,onDelete:k,onNodeDragStart:w,onNodeDrag:N,onNodeDragStop:M,onSelectionDrag:A,onSelectionDragStart:S,onSelectionDragStop:z,onMove:c,onMoveStart:d,onMoveEnd:f,noPanClassName:Dh,nodeOrigin:sn,rfId:kc,autoPanOnConnect:kS,autoPanOnNodeDrag:LS,autoPanSpeed:YS,onError:XS,connectionRadius:VS,isValidConnection:qS,selectNodesOnDrag:Dt,nodeDragThreshold:GS,connectionDragThreshold:QS,onBeforeDelete:X,debug:WS,ariaLabelConfig:FS,zIndexMode:Uh}),(0,O.jsx)(hA,{onInit:s,onNodeClick:r,onEdgeClick:u,onNodeMouseEnter:m,onNodeMouseMove:h,onNodeMouseLeave:v,onNodeContextMenu:_,onNodeDoubleClick:E,nodeTypes:l,edgeTypes:i,connectionLineType:q,connectionLineStyle:K,connectionLineComponent:j,connectionLineContainerStyle:I,selectionKeyCode:J,selectionOnDrag:U,selectionMode:Q,deleteKeyCode:ot,multiSelectionKeyCode:tt,panActivationKeyCode:nt,zoomActivationKeyCode:$,onlyRenderVisibleElements:dt,defaultViewport:qe,translateExtent:Ao,minZoom:fn,maxZoom:dn,preventScrolling:Px,zoomOnScroll:eS,zoomOnPinch:nS,zoomOnDoubleClick:iS,panOnScroll:oS,panOnScrollSpeed:aS,panOnScrollMode:lS,panOnDrag:rS,autoPanOnSelection:US,onPaneClick:uS,onPaneMouseEnter:cS,onPaneMouseMove:sS,onPaneMouseLeave:fS,onPaneScroll:dS,onPaneContextMenu:hS,paneClickDistance:pS,nodeClickDistance:gS,onSelectionContextMenu:T,onSelectionStart:B,onSelectionEnd:H,onReconnect:yS,onReconnectStart:vS,onReconnectEnd:bS,onEdgeContextMenu:xS,onEdgeDoubleClick:SS,onEdgeMouseEnter:_S,onEdgeMouseMove:wS,onEdgeMouseLeave:ES,reconnectRadius:NS,defaultMarkerColor:tS,noDragClassName:AS,noWheelClassName:CS,noPanClassName:Dh,rfId:kc,disableKeyboardA11y:Bh,nodeExtent:Bc,viewport:jS,onViewportChange:KS}),(0,O.jsx)(Xz,{onSelectionChange:V}),mS,(0,O.jsx)(Lz,{proOptions:DS,position:OS}),(0,O.jsx)(kz,{rfId:kc,disableKeyboardA11y:Bh})]})})}var Vx=mx(bA),xA=t=>t.domNode?.querySelector(".react-flow__edgelabel-renderer");function qx({children:t}){let e=ut(xA);return e?(0,sx.createPortal)(t,e):null}var U6=Me.error014();function SA({dimensions:t,lineWidth:e,variant:n,className:o}){return(0,O.jsx)("path",{strokeWidth:e,d:`M${t[0]/2} 0 V${t[1]} M0 ${t[1]/2} H${t[0]}`,className:Tt(["react-flow__background-pattern",n,o])})}function _A({radius:t,className:e}){return(0,O.jsx)("circle",{cx:t,cy:t,r:t,className:Tt(["react-flow__background-pattern","dots",e])})}var Eo;(function(t){t.Lines="lines",t.Dots="dots",t.Cross="cross"})(Eo||(Eo={}));var wA={[Eo.Dots]:1,[Eo.Lines]:1,[Eo.Cross]:6},EA=t=>({transform:t.transform,patternId:`pattern-${t.rfId}`});function Xx({id:t,variant:e=Eo.Dots,gap:n=20,size:o,lineWidth:a=1,offset:l=0,color:i,bgColor:r,style:u,className:s,patternClassName:c}){let d=(0,D.useRef)(null),{transform:f,patternId:p}=ut(EA,Et),y=o||wA[e],b=e===Eo.Dots,x=e===Eo.Cross,g=Array.isArray(n)?n:[n,n],m=[g[0]*f[2]||1,g[1]*f[2]||1],h=y*f[2],v=Array.isArray(l)?l:[l,l],_=x?[h,h]:m,E=[v[0]*f[2]||1+_[0]/2,v[1]*f[2]||1+_[1]/2],w=`${p}${t||""}`;return(0,O.jsxs)("svg",{className:Tt(["react-flow__background",s]),style:{...u,...Hc,"--xy-background-color-props":r,"--xy-background-pattern-color-props":i},ref:d,"data-testid":"rf__background",children:[(0,O.jsx)("pattern",{id:w,x:f[0]%m[0],y:f[1]%m[1],width:m[0],height:m[1],patternUnits:"userSpaceOnUse",patternTransform:`translate(-${E[0]},-${E[1]})`,children:b?(0,O.jsx)(_A,{radius:h/2,className:c}):(0,O.jsx)(SA,{dimensions:_,lineWidth:a,variant:e,className:c})}),(0,O.jsx)("rect",{x:"0",y:"0",width:"100%",height:"100%",fill:`url(#${w})`})]})}Xx.displayName="Background";var Zx=(0,D.memo)(Xx);function NA(){return(0,O.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",children:(0,O.jsx)("path",{d:"M32 18.133H18.133V32h-4.266V18.133H0v-4.266h13.867V0h4.266v13.867H32z"})})}function MA(){return(0,O.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 5",children:(0,O.jsx)("path",{d:"M0 0h32v4.2H0z"})})}function zA(){return(0,O.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 30",children:(0,O.jsx)("path",{d:"M3.692 4.63c0-.53.4-.938.939-.938h5.215V0H4.708C2.13 0 0 2.054 0 4.63v5.216h3.692V4.631zM27.354 0h-5.2v3.692h5.17c.53 0 .984.4.984.939v5.215H32V4.631A4.624 4.624 0 0027.354 0zm.954 24.83c0 .532-.4.94-.939.94h-5.215v3.768h5.215c2.577 0 4.631-2.13 4.631-4.707v-5.139h-3.692v5.139zm-23.677.94c-.531 0-.939-.4-.939-.94v-5.138H0v5.139c0 2.577 2.13 4.707 4.708 4.707h5.138V25.77H4.631z"})})}function AA(){return(0,O.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 25 32",children:(0,O.jsx)("path",{d:"M21.333 10.667H19.81V7.619C19.81 3.429 16.38 0 12.19 0 8 0 4.571 3.429 4.571 7.619v3.048H3.048A3.056 3.056 0 000 13.714v15.238A3.056 3.056 0 003.048 32h18.285a3.056 3.056 0 003.048-3.048V13.714a3.056 3.056 0 00-3.048-3.047zM12.19 24.533a3.056 3.056 0 01-3.047-3.047 3.056 3.056 0 013.047-3.048 3.056 3.056 0 013.048 3.048 3.056 3.056 0 01-3.048 3.047zm4.724-13.866H7.467V7.619c0-2.59 2.133-4.724 4.723-4.724 2.591 0 4.724 2.133 4.724 4.724v3.048z"})})}function CA(){return(0,O.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 25 32",children:(0,O.jsx)("path",{d:"M21.333 10.667H19.81V7.619C19.81 3.429 16.38 0 12.19 0c-4.114 1.828-1.37 2.133.305 2.438 1.676.305 4.42 2.59 4.42 5.181v3.048H3.047A3.056 3.056 0 000 13.714v15.238A3.056 3.056 0 003.048 32h18.285a3.056 3.056 0 003.048-3.048V13.714a3.056 3.056 0 00-3.048-3.047zM12.19 24.533a3.056 3.056 0 01-3.047-3.047 3.056 3.056 0 013.047-3.048 3.056 3.056 0 013.048 3.048 3.056 3.056 0 01-3.048 3.047z"})})}function Cc({children:t,className:e,...n}){return(0,O.jsx)("button",{type:"button",className:Tt(["react-flow__controls-button",e]),...n,children:t})}var TA=t=>({isInteractive:t.nodesDraggable||t.nodesConnectable||t.elementsSelectable,minZoomReached:t.transform[2]<=t.minZoom,maxZoomReached:t.transform[2]>=t.maxZoom,ariaLabelConfig:t.ariaLabelConfig});function Gx({style:t,showZoom:e=!0,showFitView:n=!0,showInteractive:o=!0,fitViewOptions:a,onZoomIn:l,onZoomOut:i,onFitView:r,onInteractiveChange:u,className:s,children:c,position:d="bottom-left",orientation:f="vertical","aria-label":p}){let y=zt(),{isInteractive:b,minZoomReached:x,maxZoomReached:g,ariaLabelConfig:m}=ut(TA,Et),{zoomIn:h,zoomOut:v,fitView:_}=Th(),E=()=>{h(),l?.()},w=()=>{v(),i?.()},N=()=>{_(a),r?.()},M=()=>{y.setState({nodesDraggable:!b,nodesConnectable:!b,elementsSelectable:!b}),u?.(!b)};return(0,O.jsxs)(Dc,{className:Tt(["react-flow__controls",f==="horizontal"?"horizontal":"vertical",s]),position:d,style:t,"data-testid":"rf__controls","aria-label":p??m["controls.ariaLabel"],children:[e&&(0,O.jsxs)(O.Fragment,{children:[(0,O.jsx)(Cc,{onClick:E,className:"react-flow__controls-zoomin",title:m["controls.zoomIn.ariaLabel"],"aria-label":m["controls.zoomIn.ariaLabel"],disabled:g,children:(0,O.jsx)(NA,{})}),(0,O.jsx)(Cc,{onClick:w,className:"react-flow__controls-zoomout",title:m["controls.zoomOut.ariaLabel"],"aria-label":m["controls.zoomOut.ariaLabel"],disabled:x,children:(0,O.jsx)(MA,{})})]}),n&&(0,O.jsx)(Cc,{className:"react-flow__controls-fitview",onClick:N,title:m["controls.fitView.ariaLabel"],"aria-label":m["controls.fitView.ariaLabel"],children:(0,O.jsx)(zA,{})}),o&&(0,O.jsx)(Cc,{className:"react-flow__controls-interactive",onClick:M,title:m["controls.interactive.ariaLabel"],"aria-label":m["controls.interactive.ariaLabel"],children:b?(0,O.jsx)(CA,{}):(0,O.jsx)(AA,{})}),c]})}Gx.displayName="Controls";var Qx=(0,D.memo)(Gx);function OA({id:t,x:e,y:n,width:o,height:a,style:l,color:i,strokeColor:r,strokeWidth:u,className:s,borderRadius:c,shapeRendering:d,selected:f,onClick:p}){let{background:y,backgroundColor:b}=l||{},x=i||y||b;return(0,O.jsx)("rect",{className:Tt(["react-flow__minimap-node",{selected:f},s]),x:e,y:n,rx:c,ry:c,width:o,height:a,style:{fill:x,stroke:r,strokeWidth:u},shapeRendering:d,onClick:p?g=>p(g,t):void 0})}var DA=(0,D.memo)(OA),HA=t=>t.nodes.map(e=>e.id),Ah=t=>t instanceof Function?t:()=>t;function RA({nodeStrokeColor:t,nodeColor:e,nodeClassName:n="",nodeBorderRadius:o=5,nodeStrokeWidth:a,nodeComponent:l=DA,onClick:i}){let r=ut(HA,Et),u=Ah(e),s=Ah(t),c=Ah(n),d=typeof window>"u"||window.chrome?"crispEdges":"geometricPrecision";return(0,O.jsx)(O.Fragment,{children:r.map(f=>(0,O.jsx)(kA,{id:f,nodeColorFunc:u,nodeStrokeColorFunc:s,nodeClassNameFunc:c,nodeBorderRadius:o,nodeStrokeWidth:a,NodeComponent:l,onClick:i,shapeRendering:d},f))})}function BA({id:t,nodeColorFunc:e,nodeStrokeColorFunc:n,nodeClassNameFunc:o,nodeBorderRadius:a,nodeStrokeWidth:l,shapeRendering:i,NodeComponent:r,onClick:u}){let{node:s,x:c,y:d,width:f,height:p}=ut(y=>{let b=y.nodeLookup.get(t);if(!b)return{node:void 0,x:0,y:0,width:0,height:0};let x=b.internals.userNode,{x:g,y:m}=b.internals.positionAbsolute,{width:h,height:v}=un(x);return{node:x,x:g,y:m,width:h,height:v}},Et);return!s||s.hidden||!hh(s)?null:(0,O.jsx)(r,{x:c,y:d,width:f,height:p,style:s.style,selected:!!s.selected,className:o(s),color:e(s),borderRadius:a,strokeColor:n(s),strokeWidth:l,shapeRendering:i,onClick:u,id:s.id})}var kA=(0,D.memo)(BA),LA=(0,D.memo)(RA),UA=200,YA=150,VA=t=>!t.hidden,qA=t=>{let e={x:-t.transform[0]/t.transform[2],y:-t.transform[1]/t.transform[2],width:t.width/t.transform[2],height:t.height/t.transform[2]};return{viewBB:e,boundingRect:t.nodeLookup.size>0?sh(yl(t.nodeLookup,{filter:VA}),e):e,rfId:t.rfId,panZoom:t.panZoom,translateExtent:t.translateExtent,flowWidth:t.width,flowHeight:t.height,ariaLabelConfig:t.ariaLabelConfig}},XA="react-flow__minimap-desc";function jx({style:t,className:e,nodeStrokeColor:n,nodeColor:o,nodeClassName:a="",nodeBorderRadius:l=5,nodeStrokeWidth:i,nodeComponent:r,bgColor:u,maskColor:s,maskStrokeColor:c,maskStrokeWidth:d,position:f="bottom-right",onClick:p,onNodeClick:y,pannable:b=!1,zoomable:x=!1,ariaLabel:g,inversePan:m,zoomStep:h=1,offsetScale:v=5}){let _=zt(),E=(0,D.useRef)(null),{boundingRect:w,viewBB:N,rfId:M,panZoom:R,translateExtent:C,flowWidth:k,flowHeight:V,ariaLabelConfig:S}=ut(qA,Et),A=t?.width??UA,z=t?.height??YA,T=w.width/A,B=w.height/z,H=Math.max(T,B),X=H*A,Z=H*z,q=v*H,K=w.x-(X-w.width)/2-q,j=w.y-(Z-w.height)/2-q,I=X+q*2,ot=Z+q*2,J=`${XA}-${M}`,U=(0,D.useRef)(0),Q=(0,D.useRef)();U.current=H,(0,D.useEffect)(()=>{if(E.current&&R)return Q.current=xb({domNode:E.current,panZoom:R,getTransform:()=>_.getState().transform,getViewScale:()=>U.current}),()=>{Q.current?.destroy()}},[R]),(0,D.useEffect)(()=>{Q.current?.update({translateExtent:C,width:k,height:V,inversePan:m,pannable:b,zoomStep:h,zoomable:x})},[b,x,m,h,C,k,V]);let nt=p?W=>{let[ct,dt]=Q.current?.pointer(W)||[0,0];p(W,{x:ct,y:dt})}:void 0,tt=y?(0,D.useCallback)((W,ct)=>{let dt=_.getState().nodeLookup.get(ct).internals.userNode;y(W,dt)},[]):void 0,$=g??S["minimap.ariaLabel"];return(0,O.jsx)(Dc,{position:f,style:{...t,"--xy-minimap-background-color-props":typeof u=="string"?u:void 0,"--xy-minimap-mask-background-color-props":typeof s=="string"?s:void 0,"--xy-minimap-mask-stroke-color-props":typeof c=="string"?c:void 0,"--xy-minimap-mask-stroke-width-props":typeof d=="number"?d*H:void 0,"--xy-minimap-node-background-color-props":typeof o=="string"?o:void 0,"--xy-minimap-node-stroke-color-props":typeof n=="string"?n:void 0,"--xy-minimap-node-stroke-width-props":typeof i=="number"?i:void 0},className:Tt(["react-flow__minimap",e]),"data-testid":"rf__minimap",children:(0,O.jsxs)("svg",{width:A,height:z,viewBox:`${K} ${j} ${I} ${ot}`,className:"react-flow__minimap-svg",role:"img","aria-labelledby":J,ref:E,onClick:nt,children:[$&&(0,O.jsx)("title",{id:J,children:$}),(0,O.jsx)(LA,{onClick:tt,nodeColor:o,nodeStrokeColor:n,nodeBorderRadius:l,nodeClassName:a,nodeStrokeWidth:i,nodeComponent:r}),(0,O.jsx)("path",{className:"react-flow__minimap-mask",d:`M${K-q},${j-q}h${I+q*2}v${ot+q*2}h${-I-q*2}z
15
- M${N.x},${N.y}h${N.width}v${N.height}h${-N.width}z`,fillRule:"evenodd",pointerEvents:"none"})]})})}jx.displayName="MiniMap";var Y6=(0,D.memo)(jx),ZA=t=>e=>t?`${Math.max(1/e.transform[2],1)}`:void 0,GA={[wo.Line]:"right",[wo.Handle]:"bottom-right"};function QA({nodeId:t,position:e,variant:n=wo.Handle,className:o,style:a=void 0,children:l,color:i,minWidth:r=10,minHeight:u=10,maxWidth:s=Number.MAX_VALUE,maxHeight:c=Number.MAX_VALUE,keepAspectRatio:d=!1,resizeDirection:f,autoScale:p=!0,shouldResize:y,onResizeStart:b,onResize:x,onResizeEnd:g}){let m=xx(),h=typeof t=="string"?t:m,v=zt(),_=(0,D.useRef)(null),E=n===wo.Handle,w=ut((0,D.useCallback)(ZA(E&&p),[E,p]),Et),N=(0,D.useRef)(null),M=e??GA[n];(0,D.useEffect)(()=>{if(!(!_.current||!h))return N.current||(N.current=Nb({domNode:_.current,nodeId:h,getStoreItems:()=>{let{nodeLookup:C,transform:k,snapGrid:V,snapToGrid:S,nodeOrigin:A,domNode:z}=v.getState();return{nodeLookup:C,transform:k,snapGrid:V,snapToGrid:S,nodeOrigin:A,paneDomNode:z}},onChange:(C,k)=>{let{triggerNodeChanges:V,nodeLookup:S,parentLookup:A,nodeOrigin:z}=v.getState(),T=[],B={x:C.x,y:C.y},H=S.get(h);if(H&&H.expandParent&&H.parentId){let X=H.origin??z,Z=C.width??H.measured.width??0,q=C.height??H.measured.height??0,K={id:H.id,parentId:H.parentId,rect:{width:Z,height:q,...ph({x:C.x??H.position.x,y:C.y??H.position.y},{width:Z,height:q},H.parentId,S,X)}},j=Ec([K],S,A,z);T.push(...j),B.x=C.x?Math.max(X[0]*Z,C.x):void 0,B.y=C.y?Math.max(X[1]*q,C.y):void 0}if(B.x!==void 0&&B.y!==void 0){let X={id:h,type:"position",position:{...B}};T.push(X)}if(C.width!==void 0&&C.height!==void 0){let Z={id:h,type:"dimensions",resizing:!0,setAttributes:f?f==="horizontal"?"width":"height":!0,dimensions:{width:C.width,height:C.height}};T.push(Z)}for(let X of k){let Z={...X,type:"position"};T.push(Z)}V(T)},onEnd:({width:C,height:k})=>{let V={id:h,type:"dimensions",resizing:!1,dimensions:{width:C,height:k}};v.getState().triggerNodeChanges([V])}})),N.current.update({controlPosition:M,boundaries:{minWidth:r,minHeight:u,maxWidth:s,maxHeight:c},keepAspectRatio:d,resizeDirection:f,onResizeStart:b,onResize:x,onResizeEnd:g,shouldResize:y}),()=>{N.current?.destroy()}},[M,r,u,s,c,d,b,x,g,y]);let R=M.split("-");return(0,O.jsx)("div",{className:Tt(["react-flow__resize-control","nodrag",...R,n,o]),ref:_,style:{...a,scale:w,...i&&{[E?"backgroundColor":"borderColor"]:i}},children:l})}var V6=(0,D.memo)(QA);var Y=We(Bu(),1);function Kx(t){return(globalThis.__LENS_BASE__??"")+t}var Yn=Hu({sig:"",domains:[],groups:[],dataIds:[],s2s:[]}),gt=Hu({gateway:{up:!1,portsLabel:"down"},services:{},edgeLabels:{},bursts:{},keys:{},hosts:[],trustCommand:"",recent:[],tick:0,queues:{}}),Rc=t=>{navigator.clipboard?.writeText(t)},$x={},Jx="";function jA(t){let e=t.decls.filter(c=>c.host||c.default).map(c=>({project:c.project,mode:c.service?"pods":"tcp",service:c.service,host:c.host?c.host+(c.path??""):void 0,internalHost:c.service&&c.internalHost!==!1&&c.host?(typeof c.internalHost=="string"?c.internalHost:"internal."+c.host)+(c.path??""):void 0,direct:c.internalPort?`http://localhost:${c.internalPort}${c.prependPrefix??""}/`:c.port?`http://localhost:${c.port}${c.prependPrefix??""}/`:void 0,upstream:c.upstream??(c.port?"http://localhost:"+c.port:void 0),prependPrefix:c.prependPrefix,isDefault:c.default,pods:c.podNames,workers:c.workers??[]})),n=t.edges.filter(c=>c.caller).map(c=>({key:"s2s:"+c.caller+">"+c.project,caller:c.caller,project:c.project})),o=t.dataNodes.map(c=>({id:c.id,kind:c.kind,name:c.name,viaProject:c.viaProject})),a=JSON.stringify([e.map(c=>[c.project,c.host,c.pods,c.workers]),o.map(c=>c.id),n.map(c=>c.key)]);if(a!==Yn.sig){let c=new Map;for(let d of t.decls.filter(f=>f.host))c.set(d.host,[...c.get(d.host)??[],d.project]);Yn.domains=[...c.entries()].map(([d,f])=>({host:d,project:f.length===1?f[0]:f.length+" services"})),Yn.groups=e,Yn.dataIds=o,Yn.s2s=[...new Map(n.map(d=>[d.key,d])).values()],Yn.sig=a}let l=!!t.gateway&&(t.gateway.ports.length>0||(t.gateway.aliveAt??0)>Date.now()-3e4),i=t.gateway&&t.gateway.ports.length>0?t.gateway.ports.map(c=>":"+c).join(" "):l?"live":"down";gt.gateway.up!==l&&(gt.gateway.up=l),gt.gateway.portsLabel!==i&&(gt.gateway.portsLabel=i);for(let c of e){let d=t.services.find(x=>x.project===c.project),f=c.mode==="tcp"?"up":d?.state??"unknown",p=c.mode==="tcp"?"":`${c.pods.length} pod${c.pods.length===1?"":"s"}`,y=c.mode==="pods"?`service "${c.service}" \xB7 ${f}${d?.lastColdStartMs?` \xB7 cold ${d.lastColdStartMs}ms`:""}`:c.upstream??"",b=gt.services[c.project];(!b||b.state!==f||b.podsLabel!==p||b.meta!==y)&&(gt.services[c.project]={state:f,podsLabel:p,meta:y})}let r={},u=(c,d)=>{gt.edgeLabels[c]!==d&&(gt.edgeLabels[c]=d)},s=(c,d)=>{r[c]=d;let f=d-($x[c]??d);f>0&&(gt.bursts[c]={n:Math.min(5,f),seq:(gt.bursts[c]?.seq??0)+1,until:Date.now()+3200})};for(let c of t.decls.filter(d=>d.host)){let d=t.edges.filter(y=>y.host===c.host&&!y.caller),f=d.reduce((y,b)=>y+b.count,0),p=d[0];u("e:"+c.host,p?`${f} req \xB7 ${p.avgMs}ms${p.errors?" \xB7 "+p.errors+" err":""}`:""),s("e:"+c.host,f)}for(let c of e){let d=t.edges.filter(f=>f.project===c.project&&!f.caller).reduce((f,p)=>f+p.count,0);s("e:gw>"+c.project,d),u("e:gw>"+c.project,c.isDefault&&!c.host?"(default)":"")}for(let c of t.edges.filter(d=>d.caller)){let d="s2s:"+c.caller+">"+c.project;u(d,`${c.caller} \u2192 ${c.project} \xB7 ${c.count} req \xB7 ${c.avgMs}ms`),s(d,c.count)}for(let c of t.dataNodes)if(u("e:data:"+c.id,c.count+" ops"),s("e:data:"+c.id,c.count),c.counts){let d=["active","waiting","completed","failed","delayed"].map(b=>[b,c.counts[b]??0]).filter(([,b])=>b>0||!0),f=(c.recent??[]).slice(0,5),p=gt.queues[c.id],y=JSON.stringify([d,f.map(b=>b.id+b.state)]);(!p||JSON.stringify([p.chips,p.recent.map(b=>b.id+b.state)])!==y)&&(gt.queues[c.id]={chips:d,recent:f})}Object.assign($x,r),gt.keys=t.serviceKeys,gt.hosts=t.hostsSetup,gt.trustCommand=t.trustCommand,gt.recent=t.recent.slice(0,10)}function Ix(t){let e=t.replace(/"at":\d+,/,"");e!==Jx&&(Jx=e,jA(JSON.parse(t)))}function KA(){setInterval(()=>{let n=Date.now();gt.tick=n;for(let o of Object.keys(gt.bursts))gt.bursts[o].until<n&&delete gt.bursts[o]},1e3);let t,e=()=>{t||(t=setInterval(()=>{fetch("/api/cluster").then(n=>n.text()).then(Ix).catch(()=>{})},2e3))};try{let n=new EventSource("/api/cluster/stream"),o=a=>Ix(String(a.data));n.addEventListener("snapshot",o),n.addEventListener("update",o),n.onerror=()=>e(),n.onopen=()=>{t&&(clearInterval(t),t=void 0)}}catch{e()}}function $A({data:t}){let e=t;return(0,Y.jsxs)("div",{className:"node domain",children:[(0,Y.jsx)("a",{className:"n-title link",href:"https://"+e.host,target:"_blank",rel:"noreferrer",children:e.host}),(0,Y.jsx)("div",{className:"n-sub",children:"public"}),(0,Y.jsx)($e,{type:"source",position:G.Bottom})]})}function JA(){let t=Ue(gt.gateway);return(0,Y.jsxs)("div",{className:"node gw "+(t.up?"up":"down"),children:[(0,Y.jsx)("div",{className:"n-title",children:"gateway"}),(0,Y.jsxs)("div",{className:"n-sub",children:[t.portsLabel," \xB7 https \xB7 round-robin"]}),(0,Y.jsx)($e,{type:"target",position:G.Top}),(0,Y.jsx)($e,{type:"source",position:G.Bottom})]})}function IA({data:t}){let e=t,n=Ue(gt.services),o=Ue(gt.keys);if(e.net)return(0,Y.jsx)("div",{className:"grp-inner",children:(0,Y.jsxs)("div",{className:"grp-head",children:[(0,Y.jsx)("span",{className:"n-title",children:"network"}),(0,Y.jsx)("span",{className:"n-sub",children:" public domains \u2192 gateway"})]})});let a=n[e.project]??{state:"unknown",podsLabel:"",meta:""};return(0,Y.jsxs)("div",{className:"grp-inner "+a.state,children:[(0,Y.jsxs)("div",{className:"grp-head",children:[(0,Y.jsx)("span",{className:"n-title",children:e.project}),(0,Y.jsxs)("span",{className:"n-sub",children:[" ",a.meta,a.podsLabel?" \xB7 "+a.podsLabel:""]}),e.host?(0,Y.jsxs)("div",{className:"grp-urls",children:[(0,Y.jsxs)("span",{className:"url",title:"click to copy",onClick:()=>Rc("https://"+e.host),children:["https://",e.host," \u29C9"]}),e.internalHost?(0,Y.jsxs)("span",{className:"url int",title:"copy internal curl (x-api-key via gateway)",onClick:()=>Rc(`curl -k -H "x-api-key: ${o[e.project]??"<key>"}" https://${e.internalHost}/`),children:[e.internalHost," \u{1F511}\u29C9"]}):null]}):null]}),(0,Y.jsx)($e,{type:"target",position:G.Top}),(0,Y.jsx)($e,{type:"source",position:G.Bottom})]})}function WA({data:t}){let e=t;return e.empty?(0,Y.jsxs)("div",{className:"node pod empty",children:[(0,Y.jsx)("div",{className:"n-title muted",children:"0 pods"}),(0,Y.jsx)("div",{className:"n-sub",children:"first request cold-starts"})]}):(0,Y.jsxs)("div",{className:"node pod",children:[(0,Y.jsxs)("div",{className:"n-title",children:[e.service," \xB7 ",e.pod]}),(0,Y.jsxs)("div",{className:"n-links",children:[e.host?(0,Y.jsx)("a",{className:"link",href:"https://"+e.host,target:"_blank",rel:"noreferrer",children:"gateway \u2197"}):null,e.direct?(0,Y.jsx)("a",{className:"link",href:e.direct,target:"_blank",rel:"noreferrer",children:"direct \u2197"}):null]}),(0,Y.jsx)("div",{className:"n-sub",children:e.direct?e.direct.replace("http://",""):"unix sock"})]})}function FA({data:t}){return(0,Y.jsxs)("div",{className:"node worker",children:[(0,Y.jsxs)("div",{className:"n-title",children:["\u2699 ",t.name]}),(0,Y.jsx)("div",{className:"n-sub",children:"worker"})]})}function PA({data:t}){let e=t,n=Ue(gt.edgeLabels)["e:data:"+e.id]??"",o=Ue(gt.queues)[e.id],a=e.kind==="queue"?"\u2630 ":e.kind==="redis"?"\u26A1 ":e.kind==="db"?"\u{1F6E2} ":e.kind==="external"?"\u{1F310} ":e.kind==="fs"?"\u{1F4C1} ":e.kind==="exec"?"\u2699\uFE0F ":"\u25C7 ";return(0,Y.jsxs)("div",{className:"node data "+e.kind,children:[(0,Y.jsxs)("div",{className:"n-title",children:[a,e.name]}),(0,Y.jsxs)("div",{className:"n-sub",children:[e.kind," \xB7 ",n," \xB7 via ",e.viaProject]}),o?(0,Y.jsxs)(Y.Fragment,{children:[(0,Y.jsx)("div",{className:"q-chips",children:o.chips.map(([l,i])=>(0,Y.jsxs)("span",{className:"q-chip "+l+(i>0?" nonzero":""),children:[i," ",l]},l))}),(0,Y.jsx)("div",{className:"q-jobs",children:o.recent.length===0?(0,Y.jsx)("div",{className:"n-sub",children:"(no jobs yet)"}):o.recent.map(l=>(0,Y.jsxs)("div",{className:"q-job "+l.state,children:[(0,Y.jsxs)("span",{className:"q-id",children:["#",l.id]})," ",l.name,l.to?" \u2192 "+l.to:""," ",(0,Y.jsx)("span",{className:"q-state "+l.state,children:l.state})]},l.id))})]}):null,(0,Y.jsx)($e,{type:"target",position:G.Top})]})}var tC={domain:$A,gw:JA,grp:IA,pod:WA,worker:FA,dataNode:PA};function eC(t){let{id:e,sourceX:n,sourceY:o,targetX:a,targetY:l,sourcePosition:i,targetPosition:r,data:u}=t,[s,c,d]=da({sourceX:n,sourceY:o,targetX:a,targetY:l,sourcePosition:i,targetPosition:r,borderRadius:14}),f=!!u?.internal,p=Number(u?.hop??0),y=Ue(gt.edgeLabels)[e]??"",b=Ue(gt.bursts)[e],x=Ue(gt).tick,g=b&&b.until>x?b:void 0;return(0,Y.jsxs)(Y.Fragment,{children:[(0,Y.jsx)(wl,{id:e,path:s,className:f?"edge-internal":void 0}),g&&g.n>0?Array.from({length:g.n}).map((m,h)=>{let _=p*1.25+h*.22;return(0,Y.jsxs)("circle",{r:"2.8",opacity:"0",className:"traffic-dot"+(f?" internal":""),children:[(0,Y.jsx)("animateMotion",{dur:1.25+"s",begin:_+"s",repeatCount:"1",fill:"freeze",path:s}),(0,Y.jsx)("animate",{attributeName:"opacity",values:"0;1;1;0",keyTimes:"0;0.05;0.85;1",dur:1.25+"s",begin:_+"s",repeatCount:"1",fill:"freeze"})]},g.seq+"-"+h)}):null,y?(0,Y.jsx)(qx,{children:(0,Y.jsx)("div",{className:"edge-pill",style:{transform:`translate(-50%, -50%) translate(${c}px,${d+(e.split("").reduce((m,h)=>m+h.charCodeAt(0),0)%3-1)*16}px)`},children:y})}):null]})}var nC={traffic:eC},oC={type:"traffic"},No=168;function aC(t){let e=[],n=[];e.push({id:"net",type:"grp",position:{x:-20,y:-34},draggable:!1,selectable:!1,data:{net:!0},className:"node grp net",style:{width:Math.max(1,t.domains.length)*248+26,height:150}}),t.domains.forEach((u,s)=>{e.push({id:"host:"+u.host,type:"domain",parentId:"net",extent:"parent",position:{x:14+s*248,y:58},data:{host:u.host},style:{width:230}}),n.push({id:"e:"+u.host,source:"host:"+u.host,target:"gateway",data:{hop:0}})});let a=Math.max(1,t.domains.length)*248/2-110;e.push({id:"gateway",type:"gw",position:{x:a,y:170},data:{},style:{width:220}});let l=0,i=120;for(let u of t.groups){let s=Math.max(1,u.pods.length)+u.workers.length,c=Math.max(430,24+s*(No+14)),d=196;i=Math.max(i,d);let f="svc:"+u.project;e.push({id:f,type:"grp",position:{x:l,y:332},data:{project:u.project,host:u.host,internalHost:u.internalHost},className:"node grp",style:{width:c,height:d}}),n.push({id:"e:gw>"+u.project,source:"gateway",target:f,data:{hop:1}});let p=12;if(u.mode==="pods"){u.pods.length===0&&(e.push({id:`pod:${u.service}:none`,type:"pod",parentId:f,extent:"parent",position:{x:p,y:96},data:{empty:!0},style:{width:No}}),p+=No+14);for(let y of u.pods)e.push({id:`pod:${u.service}:${y}`,type:"pod",parentId:f,extent:"parent",position:{x:p,y:96},data:{service:u.service,pod:y,host:u.host,direct:u.direct},style:{width:No}}),p+=No+14;for(let y of u.workers)e.push({id:`wrk:${u.service}:${y}`,type:"worker",parentId:f,extent:"parent",position:{x:p,y:96},data:{name:y},style:{width:No}}),p+=No+14}else e.push({id:"tcp:"+u.project,type:"pod",parentId:f,extent:"parent",position:{x:p,y:96},data:{service:u.project,pod:"dev server",host:u.host,direct:u.upstream},style:{width:No+30}});l+=c+36}for(let u of t.s2s)n.push({id:u.key,source:"svc:"+u.caller,target:"svc:"+u.project,data:{internal:!0,hop:1}});let r=332+i+110;return t.dataIds.forEach((u,s)=>{e.push({id:"data:"+u.id,type:"dataNode",position:{x:s*280,y:r},data:{...u},style:{width:u.kind==="queue"?260:200}}),n.push({id:"e:data:"+u.id,source:"svc:"+u.viaProject,target:"data:"+u.id,data:{hop:2}})}),{nodes:e,edges:n}}function lC(){let t=Ue(Yn),e=Ue(gt),n=e.hosts.filter(o=>!o.v4||!o.v6);return(0,Y.jsxs)("aside",{className:"panel",children:[(0,Y.jsx)("h3",{children:"Quick links"}),(0,Y.jsxs)("ul",{children:[t.domains.map(o=>(0,Y.jsxs)("li",{children:[(0,Y.jsxs)("a",{href:"https://"+o.host,target:"_blank",rel:"noreferrer",children:["https://",o.host]}),(0,Y.jsxs)("span",{className:"muted",children:[" \u2192 ",o.project]})]},o.host)),(0,Y.jsx)("li",{children:(0,Y.jsx)("a",{href:Kx("/flows"),children:"lens \xB7 flows"})}),(0,Y.jsx)("li",{children:(0,Y.jsx)("a",{href:Kx("/resources"),children:"lens \xB7 resources"})})]}),(0,Y.jsx)("h3",{children:"Hostnames setup"}),(0,Y.jsxs)("table",{children:[(0,Y.jsx)("thead",{children:(0,Y.jsxs)("tr",{children:[(0,Y.jsx)("th",{children:"host"}),(0,Y.jsx)("th",{children:"v4"}),(0,Y.jsx)("th",{children:"v6"})]})}),(0,Y.jsx)("tbody",{children:e.hosts.map(o=>(0,Y.jsxs)("tr",{children:[(0,Y.jsx)("td",{children:o.host}),(0,Y.jsx)("td",{className:o.v4?"ok":"bad",children:o.v4?"\u2713":"\u2717"}),(0,Y.jsx)("td",{className:o.v6?"ok":"bad",children:o.v6?"\u2713":"\u2717"})]},o.host))})]}),n.length>0?(0,Y.jsxs)("div",{className:"setup",children:[(0,Y.jsxs)("p",{children:[n.length," host entr",n.length===1?"y":"ies"," missing \u2014 run in your terminal:"]}),(0,Y.jsx)("code",{onClick:()=>Rc(e.trustCommand),title:"click to copy",children:e.trustCommand})]}):(0,Y.jsx)("p",{className:"muted",children:"all hostnames resolve locally \u2713"}),(0,Y.jsx)("h3",{children:"Service keys"}),(0,Y.jsx)("ul",{children:Object.entries(e.keys).map(([o,a])=>(0,Y.jsxs)("li",{children:[(0,Y.jsx)("span",{children:o})," ",(0,Y.jsxs)("code",{className:"key",title:"click to copy",onClick:()=>Rc(a),children:[a.slice(0,10),"\u2026 \u29C9"]})]},o))}),(0,Y.jsx)("p",{className:"muted",children:"public \u2192 gateway injects x-internal-token \xB7 internal.* requires x-api-key"}),(0,Y.jsx)("h3",{children:"Recent"}),(0,Y.jsx)("ul",{className:"recent",children:e.recent.map((o,a)=>(0,Y.jsxs)("li",{children:[(0,Y.jsx)("span",{className:"muted",children:new Date(o.at).toLocaleTimeString()})," ",o.title]},a))})]})}function iC(){let t=Ue(Yn).sig,e=(0,pa.useRef)(null),n=(0,pa.useMemo)(()=>aC(Yn),[t]);return(0,pa.useEffect)(()=>{requestAnimationFrame(()=>e.current?.fitView({padding:.16,duration:300}))},[t]),(0,Y.jsx)("div",{className:"canvas",children:(0,Y.jsxs)(Vx,{nodes:n.nodes,edges:n.edges,nodeTypes:tC,edgeTypes:nC,defaultEdgeOptions:oC,onInit:o=>{e.current=o,o.fitView({padding:.16})},proOptions:{hideAttribution:!0},colorMode:"dark",minZoom:.3,children:[(0,Y.jsx)(Zx,{gap:24}),(0,Y.jsx)(Qx,{showInteractive:!1})]})})}function rC(){return(0,pa.useEffect)(()=>{KA()},[]),(0,Y.jsxs)("div",{className:"cluster-layout",children:[(0,Y.jsx)(lC,{}),(0,Y.jsx)(iC,{})]})}var Wx=document.getElementById("cluster-root");Wx&&(0,Fx.createRoot)(Wx).render((0,Y.jsx)(rC,{}));})();
14
+ `)),c=s.reduce((d,f)=>d.concat(...f),[]);return[s,c]}return[[],[]]},[t]);return(0,D.useEffect)(()=>{let u=e?.target??jb,s=e?.actInsideInputWithModifier??!0;if(t!==null){let c=p=>{if(a.current=p.ctrlKey||p.metaKey||p.shiftKey||p.altKey,(!a.current||a.current&&!s)&&vh(p))return!1;let b=$b(p.code,r);if(l.current.add(p[b]),Kb(i,l.current,!1)){let x=p.composedPath?.()?.[0]||p.target,g=x?.nodeName==="BUTTON"||x?.nodeName==="A";e.preventDefault!==!1&&(a.current||!g)&&p.preventDefault(),o(!0)}},d=p=>{let y=$b(p.code,r);Kb(i,l.current,!0)?(o(!1),l.current.clear()):l.current.delete(p[y]),p.key==="Meta"&&l.current.clear(),a.current=!1},f=()=>{l.current.clear(),o(!1)};return u?.addEventListener("keydown",c),u?.addEventListener("keyup",d),window.addEventListener("blur",f),window.addEventListener("contextmenu",f),()=>{u?.removeEventListener("keydown",c),u?.removeEventListener("keyup",d),window.removeEventListener("blur",f),window.removeEventListener("contextmenu",f)}}},[t,o]),n}function Kb(t,e,n){return t.filter(o=>n||o.length===e.size).some(o=>o.every(a=>e.has(a)))}function $b(t,e){return e.includes(t)?"code":"key"}var $z=()=>{let t=zt();return(0,D.useMemo)(()=>({zoomIn:async e=>{let{panZoom:n}=t.getState();return n?n.scaleBy(1.2,e):!1},zoomOut:async e=>{let{panZoom:n}=t.getState();return n?n.scaleBy(1/1.2,e):!1},zoomTo:async(e,n)=>{let{panZoom:o}=t.getState();return o?o.scaleTo(e,n):!1},getZoom:()=>t.getState().transform[2],setViewport:async(e,n)=>{let{transform:[o,a,l],panZoom:i}=t.getState();return i?(await i.setViewport({x:e.x??o,y:e.y??a,zoom:e.zoom??l},n),!0):!1},getViewport:()=>{let[e,n,o]=t.getState().transform;return{x:e,y:n,zoom:o}},setCenter:async(e,n,o)=>t.getState().setCenter(e,n,o),fitBounds:async(e,n)=>{let{width:o,height:a,minZoom:l,maxZoom:i,panZoom:r}=t.getState(),u=Fi(e,o,a,l,i,n?.padding??.1);return r?(await r.setViewport(u,{duration:n?.duration,ease:n?.ease,interpolate:n?.interpolate}),!0):!1},screenToFlowPosition:(e,n={})=>{let{transform:o,snapGrid:a,snapToGrid:l,domNode:i}=t.getState();if(!i)return e;let{x:r,y:u}=i.getBoundingClientRect(),s={x:e.x-r,y:e.y-u},c=n.snapGrid??a,d=n.snapToGrid??l;return fa(s,o,d,c)},flowToScreenPosition:e=>{let{transform:n,domNode:o}=t.getState();if(!o)return e;let{x:a,y:l}=o.getBoundingClientRect(),i=ua(e,n);return{x:i.x+a,y:i.y+l}}}),[])};function mx(t,e){let n=[],o=new Map,a=[];for(let l of t)if(l.type==="add"){a.push(l);continue}else if(l.type==="remove"||l.type==="replace")o.set(l.id,[l]);else{let i=o.get(l.id);i?i.push(l):o.set(l.id,[l])}for(let l of e){let i=o.get(l.id);if(!i){n.push(l);continue}if(i[0].type==="remove")continue;if(i[0].type==="replace"){n.push({...i[0].item});continue}let r={...l};for(let u of i)Jz(u,r);n.push(r)}return a.length&&a.forEach(l=>{l.index!==void 0?n.splice(l.index,0,{...l.item}):n.push({...l.item})}),n}function Jz(t,e){switch(t.type){case"select":{e.selected=t.selected;break}case"position":{typeof t.position<"u"&&(e.position=t.position),typeof t.dragging<"u"&&(e.dragging=t.dragging);break}case"dimensions":{typeof t.dimensions<"u"&&(e.measured={...t.dimensions},t.setAttributes&&((t.setAttributes===!0||t.setAttributes==="width")&&(e.width=t.dimensions.width),(t.setAttributes===!0||t.setAttributes==="height")&&(e.height=t.dimensions.height))),typeof t.resizing=="boolean"&&(e.resizing=t.resizing);break}}}function Iz(t,e){return mx(t,e)}function Wz(t,e){return mx(t,e)}function ha(t,e){return{id:t,type:"select",selected:e}}function _l(t,e=new Set,n=!1){let o=[];for(let[a,l]of t){let i=e.has(a);!(l.selected===void 0&&!i)&&l.selected!==i&&(n&&(l.selected=i),o.push(ha(l.id,i)))}return o}function Jb({items:t=[],lookup:e}){let n=[],o=new Map(t.map(a=>[a.id,a]));for(let[a,l]of t.entries()){let i=e.get(l.id),r=i?.internals?.userNode??i;r!==void 0&&r!==l&&n.push({id:l.id,item:l,type:"replace"}),r===void 0&&n.push({item:l,type:"add",index:a})}for(let[a]of e)o.get(a)===void 0&&n.push({id:a,type:"remove"});return n}function Ib(t){return{id:t.id,type:"remove"}}var Fz=hh("React Flow","https://reactflow.dev/");function Pz(t,e,n={}){return rb(t,e,{...n,onError:n.onError??Fz})}var Wb=t=>F1(t),t3=t=>rh(t);function yx(t){return(0,D.forwardRef)(t)}var e3=typeof window<"u"?D.useLayoutEffect:D.useEffect;function Fb(t){let[e,n]=(0,D.useState)(BigInt(0)),[o]=(0,D.useState)(()=>n3(()=>n(a=>a+BigInt(1))));return e3(()=>{let a=o.get();a.length&&(t(a),o.reset())},[e]),o}function n3(t){let e=[];return{get:()=>e,reset:()=>{e=[]},push:n=>{e.push(n),t()}}}var vx=(0,D.createContext)(null);function o3({children:t}){let e=zt(),n=(0,D.useCallback)(r=>{let{nodes:u=[],setNodes:s,hasDefaultNodes:c,onNodesChange:d,nodeLookup:f,fitViewQueued:p,onNodesChangeMiddlewareMap:y}=e.getState(),b=u;for(let g of r)b=typeof g=="function"?g(b):g;let x=Jb({items:b,lookup:f});for(let g of y.values())x=g(x);c&&s(b),x.length>0?d?.(x):p&&window.requestAnimationFrame(()=>{let{fitViewQueued:g,nodes:m,setNodes:h}=e.getState();g&&h(m)})},[]),o=Fb(n),a=(0,D.useCallback)(r=>{let{edges:u=[],setEdges:s,hasDefaultEdges:c,onEdgesChange:d,edgeLookup:f}=e.getState(),p=u;for(let y of r)p=typeof y=="function"?y(p):y;c?s(p):d&&d(Jb({items:p,lookup:f}))},[]),l=Fb(a),i=(0,D.useMemo)(()=>({nodeQueue:o,edgeQueue:l}),[]);return(0,O.jsx)(vx.Provider,{value:i,children:t})}function a3(){let t=(0,D.useContext)(vx);if(!t)throw new Error("useBatchContext must be used within a BatchProvider");return t}var l3=t=>!!t.panZoom;function Oh(){let t=$z(),e=zt(),n=a3(),o=ut(l3),a=(0,D.useMemo)(()=>{let l=d=>e.getState().nodeLookup.get(d),i=d=>{n.nodeQueue.push(d)},r=d=>{n.edgeQueue.push(d)},u=d=>{let{nodeLookup:f,nodeOrigin:p}=e.getState(),y=Wb(d)?d:f.get(d.id),b=y.parentId?gh(y.position,y.measured,y.parentId,f,p):y.position,x={...y,position:b,width:y.measured?.width??y.width,height:y.measured?.height??y.height};return sa(x)},s=(d,f,p={replace:!1})=>{i(y=>y.map(b=>{if(b.id===d){let x=typeof f=="function"?f(b):f;return p.replace&&Wb(x)?x:{...b,...x}}return b}))},c=(d,f,p={replace:!1})=>{r(y=>y.map(b=>{if(b.id===d){let x=typeof f=="function"?f(b):f;return p.replace&&t3(x)?x:{...b,...x}}return b}))};return{getNodes:()=>e.getState().nodes.map(d=>({...d})),getNode:d=>l(d)?.internals.userNode,getInternalNode:l,getEdges:()=>{let{edges:d=[]}=e.getState();return d.map(f=>({...f}))},getEdge:d=>e.getState().edgeLookup.get(d),setNodes:i,setEdges:r,addNodes:d=>{let f=Array.isArray(d)?d:[d];n.nodeQueue.push(p=>[...p,...f])},addEdges:d=>{let f=Array.isArray(d)?d:[d];n.edgeQueue.push(p=>[...p,...f])},toObject:()=>{let{nodes:d=[],edges:f=[],transform:p}=e.getState(),[y,b,x]=p;return{nodes:d.map(g=>({...g})),edges:f.map(g=>({...g})),viewport:{x:y,y:b,zoom:x}}},deleteElements:async({nodes:d=[],edges:f=[]})=>{let{nodes:p,edges:y,onNodesDelete:b,onEdgesDelete:x,triggerNodeChanges:g,triggerEdgeChanges:m,onDelete:h,onBeforeDelete:v}=e.getState(),{nodes:_,edges:E}=await eb({nodesToRemove:d,edgesToRemove:f,nodes:p,edges:y,onBeforeDelete:v}),w=E.length>0,N=_.length>0;if(w){let M=E.map(Ib);x?.(E),m(M)}if(N){let M=_.map(Ib);b?.(_),g(M)}return(N||w)&&h?.({nodes:_,edges:E}),{deletedNodes:_,deletedEdges:E}},getIntersectingNodes:(d,f=!0,p)=>{let y=dh(d),b=y?d:u(d),x=p!==void 0;return b?(p||e.getState().nodes).filter(g=>{let m=e.getState().nodeLookup.get(g.id);if(m&&!y&&(g.id===d.id||!m.internals.positionAbsolute))return!1;let h=sa(x?g:m),v=vl(h,b);return f&&v>0||v>=h.width*h.height||v>=b.width*b.height}):[]},isNodeIntersecting:(d,f,p=!0)=>{let b=dh(d)?d:u(d);if(!b)return!1;let x=vl(b,f);return p&&x>0||x>=f.width*f.height||x>=b.width*b.height},updateNode:s,updateNodeData:(d,f,p={replace:!1})=>{s(d,y=>{let b=typeof f=="function"?f(y):f;return p.replace?{...y,data:b}:{...y,data:{...y.data,...b}}},p)},updateEdge:c,updateEdgeData:(d,f,p={replace:!1})=>{c(d,y=>{let b=typeof f=="function"?f(y):f;return p.replace?{...y,data:b}:{...y,data:{...y.data,...b}}},p)},getNodesBounds:d=>{let{nodeLookup:f,nodeOrigin:p}=e.getState();return ch(d,{nodeLookup:f,nodeOrigin:p})},getHandleConnections:({type:d,id:f,nodeId:p})=>Array.from(e.getState().connectionLookup.get(`${p}-${d}${f?`-${f}`:""}`)?.values()??[]),getNodeConnections:({type:d,handleId:f,nodeId:p})=>Array.from(e.getState().connectionLookup.get(`${p}${d?f?`-${d}-${f}`:`-${d}`:""}`)?.values()??[]),fitView:async d=>{let f=e.getState().fitViewResolver??ob();return e.setState({fitViewQueued:!0,fitViewOptions:d,fitViewResolver:f}),n.nodeQueue.push(p=>[...p]),f.promise}}},[]);return(0,D.useMemo)(()=>({...a,...t,viewportInitialized:o}),[o])}var Pb=t=>t.selected,i3=typeof window<"u"?window:void 0;function r3({deleteKeyCode:t,multiSelectionKeyCode:e}){let n=zt(),{deleteElements:o}=Oh(),a=Pi(t,{actInsideInputWithModifier:!1}),l=Pi(e,{target:i3});(0,D.useEffect)(()=>{if(a){let{edges:i,nodes:r}=n.getState();o({nodes:r.filter(Pb),edges:i.filter(Pb)}),n.setState({nodesSelectionActive:!1})}},[a]),(0,D.useEffect)(()=>{n.setState({multiSelectionActive:l})},[l])}function u3(t){let e=zt();(0,D.useEffect)(()=>{let n=()=>{if(!t.current||!(t.current.checkVisibility?.()??!0))return!1;let o=vc(t.current);(o.height===0||o.width===0)&&e.getState().onError?.("004",Me.error004()),e.setState({width:o.width||500,height:o.height||500})};if(t.current){n(),window.addEventListener("resize",n);let o=new ResizeObserver(()=>n());return o.observe(t.current),()=>{window.removeEventListener("resize",n),o&&t.current&&o.unobserve(t.current)}}},[])}var Hc={position:"absolute",width:"100%",height:"100%",top:0,left:0},c3=t=>({userSelectionActive:t.userSelectionActive,lib:t.lib,connectionInProgress:t.connection.inProgress});function s3({onPaneContextMenu:t,zoomOnScroll:e=!0,zoomOnPinch:n=!0,panOnScroll:o=!1,panOnScrollSpeed:a=.5,panOnScrollMode:l=Un.Free,zoomOnDoubleClick:i=!0,panOnDrag:r=!0,defaultViewport:u,translateExtent:s,minZoom:c,maxZoom:d,zoomActivationKeyCode:f,preventScrolling:p=!0,children:y,noWheelClassName:b,noPanClassName:x,onViewportChange:g,isControlledViewport:m,paneClickDistance:h,selectionOnDrag:v}){let _=zt(),E=(0,D.useRef)(null),{userSelectionActive:w,lib:N,connectionInProgress:M}=ut(c3,Et),R=Pi(f),C=(0,D.useRef)();u3(E);let k=(0,D.useCallback)(V=>{g?.({x:V[0],y:V[1],zoom:V[2]}),m||_.setState({transform:V})},[g,m]);return(0,D.useEffect)(()=>{if(E.current){C.current=Eb({domNode:E.current,minZoom:c,maxZoom:d,translateExtent:s,viewport:u,onDraggingChange:z=>_.setState(T=>T.paneDragging===z?T:{paneDragging:z}),onPanZoomStart:(z,T)=>{let{onViewportChangeStart:B,onMoveStart:H}=_.getState();H?.(z,T),B?.(T)},onPanZoom:(z,T)=>{let{onViewportChange:B,onMove:H}=_.getState();H?.(z,T),B?.(T)},onPanZoomEnd:(z,T)=>{let{onViewportChangeEnd:B,onMoveEnd:H}=_.getState();H?.(z,T),B?.(T)}});let{x:V,y:S,zoom:A}=C.current.getViewport();return _.setState({panZoom:C.current,transform:[V,S,A],domNode:E.current.closest(".react-flow")}),()=>{C.current?.destroy()}}},[]),(0,D.useEffect)(()=>{C.current?.update({onPaneContextMenu:t,zoomOnScroll:e,zoomOnPinch:n,panOnScroll:o,panOnScrollSpeed:a,panOnScrollMode:l,zoomOnDoubleClick:i,panOnDrag:r,zoomActivationKeyPressed:R,preventScrolling:p,noPanClassName:x,userSelectionActive:w,noWheelClassName:b,lib:N,onTransformChange:k,connectionInProgress:M,selectionOnDrag:v,paneClickDistance:h})},[t,e,n,o,a,l,i,r,R,p,x,w,b,N,k,M,v,h]),(0,O.jsx)("div",{className:"react-flow__renderer",ref:E,style:Hc,children:y})}var f3=t=>({userSelectionActive:t.userSelectionActive,userSelectionRect:t.userSelectionRect});function d3(){let{userSelectionActive:t,userSelectionRect:e}=ut(f3,Et);return t&&e?(0,O.jsx)("div",{className:"react-flow__selection react-flow__container",style:{width:e.width,height:e.height,transform:`translate(${e.x}px, ${e.y}px)`}}):null}var Ah=(t,e)=>n=>{n.target===e.current&&t?.(n)},h3=t=>({userSelectionActive:t.userSelectionActive,elementsSelectable:t.elementsSelectable,connectionInProgress:t.connection.inProgress,dragging:t.paneDragging,panBy:t.panBy,autoPanSpeed:t.autoPanSpeed});function p3({isSelecting:t,selectionKeyPressed:e,selectionMode:n=ia.Full,panOnDrag:o,autoPanOnSelection:a,paneClickDistance:l,selectionOnDrag:i,onSelectionStart:r,onSelectionEnd:u,onPaneClick:s,onPaneContextMenu:c,onPaneScroll:d,onPaneMouseEnter:f,onPaneMouseMove:p,onPaneMouseLeave:y,children:b}){let x=(0,D.useRef)(0),g=zt(),{userSelectionActive:m,elementsSelectable:h,dragging:v,connectionInProgress:_,panBy:E,autoPanSpeed:w}=ut(h3,Et),N=h&&(t||m),M=(0,D.useRef)(null),R=(0,D.useRef)(),C=(0,D.useRef)(new Set),k=(0,D.useRef)(new Set),V=(0,D.useRef)(!1),S=(0,D.useRef)({x:0,y:0}),A=(0,D.useRef)(!1),z=U=>{if(V.current||_){V.current=!1;return}s?.(U),g.getState().resetSelectedElements(),g.setState({nodesSelectionActive:!1})},T=U=>{if(Array.isArray(o)&&o?.includes(2)){U.preventDefault();return}c?.(U)},B=d?U=>d(U):void 0,H=U=>{V.current&&(U.stopPropagation(),V.current=!1)},X=U=>{let{domNode:Q,transform:nt}=g.getState();if(R.current=Q?.getBoundingClientRect(),!R.current)return;let tt=U.target===M.current;if(!tt&&!!U.target.closest(".nokey")||!t||!(i&&tt||e)||U.button!==0||!U.isPrimary)return;U.target?.setPointerCapture?.(U.pointerId),V.current=!1;let{x:ct,y:dt}=Ve(U.nativeEvent,R.current),Dt=fa({x:ct,y:dt},nt);g.setState({userSelectionRect:{width:0,height:0,startX:Dt.x,startY:Dt.y,x:ct,y:dt}}),tt||(U.stopPropagation(),U.preventDefault())};function Z(U,Q){let{userSelectionRect:nt}=g.getState();if(!nt)return;let{transform:tt,nodeLookup:$,edgeLookup:W,connectionLookup:ct,triggerNodeChanges:dt,triggerEdgeChanges:Dt,defaultEdgeOptions:ie}=g.getState(),cn={x:nt.startX,y:nt.startY},{x:Je,y:Ie}=ua(cn,tt),sn={startX:cn.x,startY:cn.y,x:U<Je?U:Je,y:Q<Ie?Q:Ie,width:Math.abs(U-Je),height:Math.abs(Q-Ie)},El=C.current,Mo=k.current;C.current=new Set(pc($,sn,tt,n===ia.Partial,!0).map(qe=>qe.id)),k.current=new Set;let zo=ie?.selectable??!0;for(let qe of C.current){let fn=ct.get(qe);if(fn)for(let{edgeId:dn}of fn.values()){let Ao=W.get(dn);Ao&&(Ao.selectable??zo)&&k.current.add(dn)}}if(!mh(El,C.current)){let qe=_l($,C.current,!0);dt(qe)}if(!mh(Mo,k.current)){let qe=_l(W,k.current);Dt(qe)}g.setState({userSelectionRect:sn,userSelectionActive:!0,nodesSelectionActive:!1})}function q(){if(!a||!R.current)return;let[U,Q]=gc(S.current,R.current,w);E({x:U,y:Q}).then(nt=>{if(!V.current||!nt){x.current=requestAnimationFrame(q);return}let{x:tt,y:$}=S.current;Z(tt,$),x.current=requestAnimationFrame(q)})}let K=()=>{cancelAnimationFrame(x.current),x.current=0,A.current=!1};(0,D.useEffect)(()=>()=>K(),[]);let j=U=>{let{userSelectionRect:Q,transform:nt,resetSelectedElements:tt}=g.getState();if(!R.current||!Q)return;let{x:$,y:W}=Ve(U.nativeEvent,R.current);S.current={x:$,y:W};let ct=ua({x:Q.startX,y:Q.startY},nt);if(!V.current){let dt=e?0:l;if(Math.hypot($-ct.x,W-ct.y)<=dt)return;tt(),r?.(U)}V.current=!0,A.current||(q(),A.current=!0),Z($,W)},I=U=>{U.button===0&&(U.target?.releasePointerCapture?.(U.pointerId),!m&&U.target===M.current&&g.getState().userSelectionRect&&z?.(U),g.setState({userSelectionActive:!1,userSelectionRect:null}),V.current&&(u?.(U),g.setState({nodesSelectionActive:C.current.size>0})),K())},ot=U=>{U.target?.releasePointerCapture?.(U.pointerId),K()},J=o===!0||Array.isArray(o)&&o.includes(0);return(0,O.jsxs)("div",{className:Tt(["react-flow__pane",{draggable:J,dragging:v,selection:t}]),onClick:N?void 0:Ah(z,M),onContextMenu:Ah(T,M),onWheel:Ah(B,M),onPointerEnter:N?void 0:f,onPointerMove:N?j:p,onPointerUp:N?I:void 0,onPointerCancel:N?ot:void 0,onPointerDownCapture:N?X:void 0,onClickCapture:N?H:void 0,onPointerLeave:y,ref:M,style:Hc,children:[b,(0,O.jsx)(d3,{})]})}function Th({id:t,store:e,unselect:n=!1,nodeRef:o}){let{addSelectedNodes:a,unselectNodesAndEdges:l,multiSelectionActive:i,nodeLookup:r,onError:u}=e.getState(),s=r.get(t);if(!s){u?.("012",Me.error012(t));return}e.setState({nodesSelectionActive:!1}),s.selected?(n||s.selected&&i)&&(l({nodes:[s],edges:[]}),requestAnimationFrame(()=>o?.current?.blur())):a([t])}function bx({nodeRef:t,disabled:e=!1,noDragClassName:n,handleSelector:o,nodeId:a,isSelectable:l,nodeClickDistance:i}){let r=zt(),[u,s]=(0,D.useState)(!1),c=(0,D.useRef)();return(0,D.useEffect)(()=>{c.current=mb({getStoreItems:()=>r.getState(),onNodeMouseDown:d=>{Th({id:d,store:r,nodeRef:t})},onDragStart:()=>{s(!0)},onDragStop:()=>{s(!1)}})},[]),(0,D.useEffect)(()=>{if(!(e||!t.current||!c.current))return c.current.update({noDragClassName:n,handleSelector:o,domNode:t.current,isSelectable:l,nodeId:a,nodeClickDistance:i}),()=>{c.current?.destroy()}},[n,o,e,l,t,a,i]),u}var g3=t=>e=>e.selected&&(e.draggable||t&&typeof e.draggable>"u");function xx(){let t=zt();return(0,D.useCallback)(n=>{let{nodeExtent:o,snapToGrid:a,snapGrid:l,nodesDraggable:i,onError:r,updateNodePositions:u,nodeLookup:s,nodeOrigin:c}=t.getState(),d=new Map,f=g3(i),p=a?l[0]:5,y=a?l[1]:5,b=n.direction.x*p*n.factor,x=n.direction.y*y*n.factor;for(let[,g]of s){if(!f(g))continue;let m={x:g.internals.positionAbsolute.x+b,y:g.internals.positionAbsolute.y+x};a&&(m=bl(m,l));let{position:h,positionAbsolute:v}=sh({nodeId:g.id,nextPosition:m,nodeLookup:s,nodeExtent:o,nodeOrigin:c,onError:r});g.position=h,g.internals.positionAbsolute=v,d.set(g.id,g)}u(d)},[])}var Dh=(0,D.createContext)(null),m3=Dh.Provider;Dh.Consumer;var Sx=()=>(0,D.useContext)(Dh),y3=t=>({connectOnClick:t.connectOnClick,noPanClassName:t.noPanClassName,rfId:t.rfId}),v3=(t,e,n)=>o=>{let{connectionClickStartHandle:a,connectionMode:l,connection:i}=o,{fromHandle:r,toHandle:u,isValid:s}=i,c=u?.nodeId===t&&u?.id===e&&u?.type===n;return{connectingFrom:r?.nodeId===t&&r?.id===e&&r?.type===n,connectingTo:c,clickConnecting:a?.nodeId===t&&a?.id===e&&a?.type===n,isPossibleEndHandle:l===So.Strict?r?.type!==n:t!==r?.nodeId||e!==r?.id,connectionInProcess:!!r,clickConnectionInProcess:!!a,valid:c&&s}};function b3({type:t="source",position:e=G.Top,isValidConnection:n,isConnectable:o=!0,isConnectableStart:a=!0,isConnectableEnd:l=!0,id:i,onConnect:r,children:u,className:s,onMouseDown:c,onTouchStart:d,...f},p){let y=i||null,b=t==="target",x=zt(),g=Sx(),{connectOnClick:m,noPanClassName:h,rfId:v}=ut(y3,Et),{connectingFrom:_,connectingTo:E,clickConnecting:w,isPossibleEndHandle:N,connectionInProcess:M,clickConnectionInProcess:R,valid:C}=ut(v3(g,y,t),Et);g||x.getState().onError?.("010",Me.error010());let k=A=>{let{defaultEdgeOptions:z,onConnect:T,hasDefaultEdges:B}=x.getState(),H={...z,...A};if(B){let{edges:X,setEdges:Z,onError:q}=x.getState();Z(Pz(H,X,{onError:q}))}T?.(H),r?.(H)},V=A=>{if(!g)return;let z=bh(A.nativeEvent);if(a&&(z&&A.button===0||!z)){let T=x.getState();Nc.onPointerDown(A.nativeEvent,{handleDomNode:A.currentTarget,autoPanOnConnect:T.autoPanOnConnect,connectionMode:T.connectionMode,connectionRadius:T.connectionRadius,domNode:T.domNode,nodeLookup:T.nodeLookup,lib:T.lib,isTarget:b,handleId:y,nodeId:g,flowId:T.rfId,panBy:T.panBy,cancelConnection:T.cancelConnection,onConnectStart:T.onConnectStart,onConnectEnd:(...B)=>x.getState().onConnectEnd?.(...B),updateConnection:T.updateConnection,onConnect:k,isValidConnection:n||((...B)=>x.getState().isValidConnection?.(...B)??!0),getTransform:()=>x.getState().transform,getFromHandle:()=>x.getState().connection.fromHandle,autoPanSpeed:T.autoPanSpeed,dragThreshold:T.connectionDragThreshold})}z?c?.(A):d?.(A)},S=A=>{let{onClickConnectStart:z,onClickConnectEnd:T,connectionClickStartHandle:B,connectionMode:H,isValidConnection:X,lib:Z,rfId:q,nodeLookup:K,connection:j}=x.getState();if(!g||!B&&!a)return;if(!B){z?.(A.nativeEvent,{nodeId:g,handleId:y,handleType:t}),x.setState({connectionClickStartHandle:{nodeId:g,type:t,id:y}});return}let I=yh(A.target),ot=n||X,{connection:J,isValid:U}=Nc.isValid(A.nativeEvent,{handle:{nodeId:g,id:y,type:t},connectionMode:H,fromNodeId:B.nodeId,fromHandleId:B.id||null,fromType:B.type,isValidConnection:ot,flowId:q,doc:I,lib:Z,nodeLookup:K});U&&J&&k(J);let Q=structuredClone(j);delete Q.inProgress,Q.toPosition=Q.toHandle?Q.toHandle.position:null,T?.(A,Q),x.setState({connectionClickStartHandle:null})};return(0,O.jsx)("div",{"data-handleid":y,"data-nodeid":g,"data-handlepos":e,"data-id":`${v}-${g}-${y}-${t}`,className:Tt(["react-flow__handle",`react-flow__handle-${e}`,"nodrag",h,s,{source:!b,target:b,connectable:o,connectablestart:a,connectableend:l,clickconnecting:w,connectingfrom:_,connectingto:E,valid:C,connectionindicator:o&&(!M||N)&&(M||R?l:a)}]),onMouseDown:V,onTouchStart:V,onClick:m?S:void 0,ref:p,...f,children:u})}var $e=(0,D.memo)(yx(b3));function x3({data:t,isConnectable:e,sourcePosition:n=G.Bottom}){return(0,O.jsxs)(O.Fragment,{children:[t?.label,(0,O.jsx)($e,{type:"source",position:n,isConnectable:e})]})}function S3({data:t,isConnectable:e,targetPosition:n=G.Top,sourcePosition:o=G.Bottom}){return(0,O.jsxs)(O.Fragment,{children:[(0,O.jsx)($e,{type:"target",position:n,isConnectable:e}),t?.label,(0,O.jsx)($e,{type:"source",position:o,isConnectable:e})]})}function _3(){return null}function w3({data:t,isConnectable:e,targetPosition:n=G.Top}){return(0,O.jsxs)(O.Fragment,{children:[(0,O.jsx)($e,{type:"target",position:n,isConnectable:e}),t?.label]})}var Tc={ArrowUp:{x:0,y:-1},ArrowDown:{x:0,y:1},ArrowLeft:{x:-1,y:0},ArrowRight:{x:1,y:0}},tx={input:x3,default:S3,output:w3,group:_3};function E3(t){return t.internals.handleBounds===void 0?{width:t.width??t.initialWidth??t.style?.width,height:t.height??t.initialHeight??t.style?.height}:{width:t.width??t.style?.width,height:t.height??t.style?.height}}var N3=t=>{let{width:e,height:n,x:o,y:a}=yl(t.nodeLookup,{filter:l=>!!l.selected});return{width:Ye(e)?e:null,height:Ye(n)?n:null,userSelectionActive:t.userSelectionActive,transformString:`translate(${t.transform[0]}px,${t.transform[1]}px) scale(${t.transform[2]}) translate(${o}px,${a}px)`}};function M3({onSelectionContextMenu:t,noPanClassName:e,disableKeyboardA11y:n}){let o=zt(),{width:a,height:l,transformString:i,userSelectionActive:r}=ut(N3,Et),u=xx(),s=(0,D.useRef)(null);(0,D.useEffect)(()=>{n||s.current?.focus({preventScroll:!0})},[n]);let c=!r&&a!==null&&l!==null;if(bx({nodeRef:s,disabled:!c}),!c)return null;let d=t?p=>{let y=o.getState().nodes.filter(b=>b.selected);t(p,y)}:void 0,f=p=>{Object.prototype.hasOwnProperty.call(Tc,p.key)&&(p.preventDefault(),u({direction:Tc[p.key],factor:p.shiftKey?4:1}))};return(0,O.jsx)("div",{className:Tt(["react-flow__nodesselection","react-flow__container",e]),style:{transform:i},children:(0,O.jsx)("div",{ref:s,className:"react-flow__nodesselection-rect",onContextMenu:d,tabIndex:n?void 0:-1,onKeyDown:n?void 0:f,style:{width:a,height:l}})})}var ex=typeof window<"u"?window:void 0,z3=t=>({nodesSelectionActive:t.nodesSelectionActive,userSelectionActive:t.userSelectionActive});function _x({children:t,onPaneClick:e,onPaneMouseEnter:n,onPaneMouseMove:o,onPaneMouseLeave:a,onPaneContextMenu:l,onPaneScroll:i,paneClickDistance:r,deleteKeyCode:u,selectionKeyCode:s,selectionOnDrag:c,selectionMode:d,onSelectionStart:f,onSelectionEnd:p,multiSelectionKeyCode:y,panActivationKeyCode:b,zoomActivationKeyCode:x,elementsSelectable:g,zoomOnScroll:m,zoomOnPinch:h,panOnScroll:v,panOnScrollSpeed:_,panOnScrollMode:E,zoomOnDoubleClick:w,panOnDrag:N,autoPanOnSelection:M,defaultViewport:R,translateExtent:C,minZoom:k,maxZoom:V,preventScrolling:S,onSelectionContextMenu:A,noWheelClassName:z,noPanClassName:T,disableKeyboardA11y:B,onViewportChange:H,isControlledViewport:X}){let{nodesSelectionActive:Z,userSelectionActive:q}=ut(z3,Et),K=Pi(s,{target:ex}),j=Pi(b,{target:ex}),I=j||N,ot=j||v,J=c&&I!==!0,U=K||q||J;return r3({deleteKeyCode:u,multiSelectionKeyCode:y}),(0,O.jsx)(s3,{onPaneContextMenu:l,elementsSelectable:g,zoomOnScroll:m,zoomOnPinch:h,panOnScroll:ot,panOnScrollSpeed:_,panOnScrollMode:E,zoomOnDoubleClick:w,panOnDrag:!K&&I,defaultViewport:R,translateExtent:C,minZoom:k,maxZoom:V,zoomActivationKeyCode:x,preventScrolling:S,noWheelClassName:z,noPanClassName:T,onViewportChange:H,isControlledViewport:X,paneClickDistance:r,selectionOnDrag:J,children:(0,O.jsxs)(p3,{onSelectionStart:f,onSelectionEnd:p,onPaneClick:e,onPaneMouseEnter:n,onPaneMouseMove:o,onPaneMouseLeave:a,onPaneContextMenu:l,onPaneScroll:i,panOnDrag:I,autoPanOnSelection:M,isSelecting:!!U,selectionMode:d,selectionKeyPressed:K,paneClickDistance:r,selectionOnDrag:J,children:[t,Z&&(0,O.jsx)(M3,{onSelectionContextMenu:A,noPanClassName:T,disableKeyboardA11y:B})]})})}_x.displayName="FlowRenderer";var A3=(0,D.memo)(_x),C3=t=>e=>t?pc(e.nodeLookup,{x:0,y:0,width:e.width,height:e.height},e.transform,!0).map(n=>n.id):Array.from(e.nodeLookup.keys());function T3(t){return ut((0,D.useCallback)(C3(t),[t]),Et)}var O3=t=>t.updateNodeInternals;function D3(){let t=ut(O3),[e]=(0,D.useState)(()=>typeof ResizeObserver>"u"?null:new ResizeObserver(n=>{let o=new Map;n.forEach(a=>{let l=a.target.getAttribute("data-id");o.set(l,{id:l,nodeElement:a.target,force:!0})}),t(o)}));return(0,D.useEffect)(()=>()=>{e?.disconnect()},[e]),e}function H3({node:t,nodeType:e,hasDimensions:n,resizeObserver:o}){let a=zt(),l=(0,D.useRef)(null),i=(0,D.useRef)(null),r=(0,D.useRef)(t.sourcePosition),u=(0,D.useRef)(t.targetPosition),s=(0,D.useRef)(e),c=n&&!!t.internals.handleBounds;return(0,D.useEffect)(()=>{l.current&&!t.hidden&&(!c||i.current!==l.current)&&(i.current&&o?.unobserve(i.current),o?.observe(l.current),i.current=l.current)},[c,t.hidden]),(0,D.useEffect)(()=>()=>{i.current&&(o?.unobserve(i.current),i.current=null)},[]),(0,D.useEffect)(()=>{if(l.current){let d=s.current!==e,f=r.current!==t.sourcePosition,p=u.current!==t.targetPosition;(d||f||p)&&(s.current=e,r.current=t.sourcePosition,u.current=t.targetPosition,a.getState().updateNodeInternals(new Map([[t.id,{id:t.id,nodeElement:l.current,force:!0}]])))}},[t.id,e,t.sourcePosition,t.targetPosition]),l}function R3({id:t,onClick:e,onMouseEnter:n,onMouseMove:o,onMouseLeave:a,onContextMenu:l,onDoubleClick:i,nodesDraggable:r,elementsSelectable:u,nodesConnectable:s,nodesFocusable:c,resizeObserver:d,noDragClassName:f,noPanClassName:p,disableKeyboardA11y:y,rfId:b,nodeTypes:x,nodeClickDistance:g,onError:m}){let{node:h,internals:v,isParent:_}=ut(U=>{let Q=U.nodeLookup.get(t),nt=U.parentLookup.has(t);return{node:Q,internals:Q.internals,isParent:nt}},Et),E=h.type||"default",w=x?.[E]||tx[E];w===void 0&&(m?.("003",Me.error003(E)),E="default",w=x?.default||tx.default);let N=!!(h.draggable||r&&typeof h.draggable>"u"),M=!!(h.selectable||u&&typeof h.selectable>"u"),R=!!(h.connectable||s&&typeof h.connectable>"u"),C=!!(h.focusable||c&&typeof h.focusable>"u"),k=zt(),V=ph(h),S=H3({node:h,nodeType:E,hasDimensions:V,resizeObserver:d}),A=bx({nodeRef:S,disabled:h.hidden||!N,noDragClassName:f,handleSelector:h.dragHandle,nodeId:t,isSelectable:M,nodeClickDistance:g}),z=xx();if(h.hidden)return null;let T=un(h),B=E3(h),H=M||N||e||n||o||a,X=n?U=>n(U,{...v.userNode}):void 0,Z=o?U=>o(U,{...v.userNode}):void 0,q=a?U=>a(U,{...v.userNode}):void 0,K=l?U=>l(U,{...v.userNode}):void 0,j=i?U=>i(U,{...v.userNode}):void 0,I=U=>{let{selectNodesOnDrag:Q,nodeDragThreshold:nt}=k.getState();M&&(!Q||!N||nt>0)&&Th({id:t,store:k,nodeRef:S}),e&&e(U,{...v.userNode})},ot=U=>{if(!(vh(U.nativeEvent)||y)){if(oh.includes(U.key)&&M){let Q=U.key==="Escape";Th({id:t,store:k,unselect:Q,nodeRef:S})}else if(N&&h.selected&&Object.prototype.hasOwnProperty.call(Tc,U.key)){U.preventDefault();let{ariaLabelConfig:Q}=k.getState();k.setState({ariaLiveMessage:Q["node.a11yDescription.ariaLiveMessage"]({direction:U.key.replace("Arrow","").toLowerCase(),x:~~v.positionAbsolute.x,y:~~v.positionAbsolute.y})}),z({direction:Tc[U.key],factor:U.shiftKey?4:1})}}},J=()=>{if(y||!S.current?.matches(":focus-visible"))return;let{transform:U,width:Q,height:nt,autoPanOnNodeFocus:tt,setCenter:$}=k.getState();if(!tt)return;pc(new Map([[t,h]]),{x:0,y:0,width:Q,height:nt},U,!0).length>0||$(h.position.x+T.width/2,h.position.y+T.height/2,{zoom:U[2]})};return(0,O.jsx)("div",{className:Tt(["react-flow__node",`react-flow__node-${E}`,{[p]:N},h.className,{selected:h.selected,selectable:M,parent:_,draggable:N,dragging:A}]),ref:S,style:{zIndex:v.z,transform:`translate(${v.positionAbsolute.x}px,${v.positionAbsolute.y}px)`,pointerEvents:H?"all":"none",visibility:V?"visible":"hidden",...h.style,...B},"data-id":t,"data-testid":`rf__node-${t}`,onMouseEnter:X,onMouseMove:Z,onMouseLeave:q,onContextMenu:K,onClick:I,onDoubleClick:j,onKeyDown:C?ot:void 0,tabIndex:C?0:void 0,onFocus:C?J:void 0,role:h.ariaRole??(C?"group":void 0),"aria-roledescription":"node","aria-describedby":y?void 0:`${hx}-${b}`,"aria-label":h.ariaLabel,...h.domAttributes,children:(0,O.jsx)(m3,{value:t,children:(0,O.jsx)(w,{id:t,data:h.data,type:E,positionAbsoluteX:v.positionAbsolute.x,positionAbsoluteY:v.positionAbsolute.y,selected:h.selected??!1,selectable:M,draggable:N,deletable:h.deletable??!0,isConnectable:R,sourcePosition:h.sourcePosition,targetPosition:h.targetPosition,dragging:A,dragHandle:h.dragHandle,zIndex:v.z,parentId:h.parentId,...T})})})}var B3=(0,D.memo)(R3),k3=t=>({nodesDraggable:t.nodesDraggable,nodesConnectable:t.nodesConnectable,nodesFocusable:t.nodesFocusable,elementsSelectable:t.elementsSelectable,onError:t.onError});function wx(t){let{nodesDraggable:e,nodesConnectable:n,nodesFocusable:o,elementsSelectable:a,onError:l}=ut(k3,Et),i=T3(t.onlyRenderVisibleElements),r=D3();return(0,O.jsx)("div",{className:"react-flow__nodes",style:Hc,children:i.map(u=>(0,O.jsx)(B3,{id:u,nodeTypes:t.nodeTypes,nodeExtent:t.nodeExtent,onClick:t.onNodeClick,onMouseEnter:t.onNodeMouseEnter,onMouseMove:t.onNodeMouseMove,onMouseLeave:t.onNodeMouseLeave,onContextMenu:t.onNodeContextMenu,onDoubleClick:t.onNodeDoubleClick,noDragClassName:t.noDragClassName,noPanClassName:t.noPanClassName,rfId:t.rfId,disableKeyboardA11y:t.disableKeyboardA11y,resizeObserver:r,nodesDraggable:e,nodesConnectable:n,nodesFocusable:o,elementsSelectable:a,nodeClickDistance:t.nodeClickDistance,onError:l},u))})}wx.displayName="NodeRenderer";var L3=(0,D.memo)(wx);function U3(t){return ut((0,D.useCallback)(n=>{if(!t)return n.edges.map(a=>a.id);let o=[];if(n.width&&n.height)for(let a of n.edges){let l=n.nodeLookup.get(a.source),i=n.nodeLookup.get(a.target);l&&i&&ib({sourceNode:l,targetNode:i,width:n.width,height:n.height,transform:n.transform})&&o.push(a.id)}return o},[t]),Et)}var Y3=({color:t="none",strokeWidth:e=1})=>{let n={strokeWidth:e,...t&&{stroke:t}};return(0,O.jsx)("polyline",{className:"arrow",style:n,strokeLinecap:"round",fill:"none",strokeLinejoin:"round",points:"-5,-4 0,0 -5,4"})},V3=({color:t="none",strokeWidth:e=1})=>{let n={strokeWidth:e,...t&&{stroke:t,fill:t}};return(0,O.jsx)("polyline",{className:"arrowclosed",style:n,strokeLinecap:"round",strokeLinejoin:"round",points:"-5,-4 0,0 -5,4 -5,-4"})},nx={[pl.Arrow]:Y3,[pl.ArrowClosed]:V3};function q3(t){let e=zt();return(0,D.useMemo)(()=>Object.prototype.hasOwnProperty.call(nx,t)?nx[t]:(e.getState().onError?.("009",Me.error009(t)),null),[t])}var X3=({id:t,type:e,color:n,width:o=12.5,height:a=12.5,markerUnits:l="strokeWidth",strokeWidth:i,orient:r="auto-start-reverse"})=>{let u=q3(e);return u?(0,O.jsx)("marker",{className:"react-flow__arrowhead",id:t,markerWidth:`${o}`,markerHeight:`${a}`,viewBox:"-10 -10 20 20",markerUnits:l,orient:r,refX:"0",refY:"0",children:(0,O.jsx)(u,{color:n,strokeWidth:i})}):null},Ex=({defaultColor:t,rfId:e})=>{let n=ut(l=>l.edges),o=ut(l=>l.defaultEdgeOptions),a=(0,D.useMemo)(()=>cb(n,{id:e,defaultColor:t,defaultMarkerStart:o?.markerStart,defaultMarkerEnd:o?.markerEnd}),[n,o,e,t]);return a.length?(0,O.jsx)("svg",{className:"react-flow__marker","aria-hidden":"true",children:(0,O.jsx)("defs",{children:a.map(l=>(0,O.jsx)(X3,{id:l.id,type:l.type,color:l.color,width:l.width,height:l.height,markerUnits:l.markerUnits,strokeWidth:l.strokeWidth,orient:l.orient},l.id))})}):null};Ex.displayName="MarkerDefinitions";var Z3=(0,D.memo)(Ex);function Nx({x:t,y:e,label:n,labelStyle:o,labelShowBg:a=!0,labelBgStyle:l,labelBgPadding:i=[2,4],labelBgBorderRadius:r=2,children:u,className:s,...c}){let[d,f]=(0,D.useState)({x:1,y:0,width:0,height:0}),p=Tt(["react-flow__edge-textwrapper",s]),y=(0,D.useRef)(null);return(0,D.useEffect)(()=>{if(y.current){let b=y.current.getBBox();f({x:b.x,y:b.y,width:b.width,height:b.height})}},[n]),n?(0,O.jsxs)("g",{transform:`translate(${t-d.width/2} ${e-d.height/2})`,className:p,visibility:d.width?"visible":"hidden",...c,children:[a&&(0,O.jsx)("rect",{width:d.width+2*i[0],x:-i[0],y:-i[1],height:d.height+2*i[1],className:"react-flow__edge-textbg",style:l,rx:r,ry:r}),(0,O.jsx)("text",{className:"react-flow__edge-text",y:d.height/2,dy:"0.3em",ref:y,style:o,children:n}),u]}):null}Nx.displayName="EdgeText";var G3=(0,D.memo)(Nx);function wl({path:t,labelX:e,labelY:n,label:o,labelStyle:a,labelShowBg:l,labelBgStyle:i,labelBgPadding:r,labelBgBorderRadius:u,interactionWidth:s=20,...c}){return(0,O.jsxs)(O.Fragment,{children:[(0,O.jsx)("path",{...c,d:t,fill:"none",className:Tt(["react-flow__edge-path",c.className])}),s?(0,O.jsx)("path",{d:t,fill:"none",strokeOpacity:0,strokeWidth:s,className:"react-flow__edge-interaction"}):null,o&&Ye(e)&&Ye(n)?(0,O.jsx)(G3,{x:e,y:n,label:o,labelStyle:a,labelShowBg:l,labelBgStyle:i,labelBgPadding:r,labelBgBorderRadius:u}):null]})}function ox({pos:t,x1:e,y1:n,x2:o,y2:a}){return t===G.Left||t===G.Right?[.5*(e+o),n]:[e,.5*(n+a)]}function Mx({sourceX:t,sourceY:e,sourcePosition:n=G.Bottom,targetX:o,targetY:a,targetPosition:l=G.Top}){let[i,r]=ox({pos:n,x1:t,y1:e,x2:o,y2:a}),[u,s]=ox({pos:l,x1:o,y1:a,x2:t,y2:e}),[c,d,f,p]=bc({sourceX:t,sourceY:e,targetX:o,targetY:a,sourceControlX:i,sourceControlY:r,targetControlX:u,targetControlY:s});return[`M${t},${e} C${i},${r} ${u},${s} ${o},${a}`,c,d,f,p]}function zx(t){return(0,D.memo)(({id:e,sourceX:n,sourceY:o,targetX:a,targetY:l,sourcePosition:i,targetPosition:r,label:u,labelStyle:s,labelShowBg:c,labelBgStyle:d,labelBgPadding:f,labelBgBorderRadius:p,style:y,markerEnd:b,markerStart:x,interactionWidth:g})=>{let[m,h,v]=Mx({sourceX:n,sourceY:o,sourcePosition:i,targetX:a,targetY:l,targetPosition:r}),_=t.isInternal?void 0:e;return(0,O.jsx)(wl,{id:_,path:m,labelX:h,labelY:v,label:u,labelStyle:s,labelShowBg:c,labelBgStyle:d,labelBgPadding:f,labelBgBorderRadius:p,style:y,markerEnd:b,markerStart:x,interactionWidth:g})})}var Q3=zx({isInternal:!1}),Ax=zx({isInternal:!0});Q3.displayName="SimpleBezierEdge";Ax.displayName="SimpleBezierEdgeInternal";function Cx(t){return(0,D.memo)(({id:e,sourceX:n,sourceY:o,targetX:a,targetY:l,label:i,labelStyle:r,labelShowBg:u,labelBgStyle:s,labelBgPadding:c,labelBgBorderRadius:d,style:f,sourcePosition:p=G.Bottom,targetPosition:y=G.Top,markerEnd:b,markerStart:x,pathOptions:g,interactionWidth:m})=>{let[h,v,_]=da({sourceX:n,sourceY:o,sourcePosition:p,targetX:a,targetY:l,targetPosition:y,borderRadius:g?.borderRadius,offset:g?.offset,stepPosition:g?.stepPosition}),E=t.isInternal?void 0:e;return(0,O.jsx)(wl,{id:E,path:h,labelX:v,labelY:_,label:i,labelStyle:r,labelShowBg:u,labelBgStyle:s,labelBgPadding:c,labelBgBorderRadius:d,style:f,markerEnd:b,markerStart:x,interactionWidth:m})})}var Tx=Cx({isInternal:!1}),Ox=Cx({isInternal:!0});Tx.displayName="SmoothStepEdge";Ox.displayName="SmoothStepEdgeInternal";function Dx(t){return(0,D.memo)(({id:e,...n})=>{let o=t.isInternal?void 0:e;return(0,O.jsx)(Tx,{...n,id:o,pathOptions:(0,D.useMemo)(()=>({borderRadius:0,offset:n.pathOptions?.offset}),[n.pathOptions?.offset])})})}var j3=Dx({isInternal:!1}),Hx=Dx({isInternal:!0});j3.displayName="StepEdge";Hx.displayName="StepEdgeInternal";function Rx(t){return(0,D.memo)(({id:e,sourceX:n,sourceY:o,targetX:a,targetY:l,label:i,labelStyle:r,labelShowBg:u,labelBgStyle:s,labelBgPadding:c,labelBgBorderRadius:d,style:f,markerEnd:p,markerStart:y,interactionWidth:b})=>{let[x,g,m]=Sc({sourceX:n,sourceY:o,targetX:a,targetY:l}),h=t.isInternal?void 0:e;return(0,O.jsx)(wl,{id:h,path:x,labelX:g,labelY:m,label:i,labelStyle:r,labelShowBg:u,labelBgStyle:s,labelBgPadding:c,labelBgBorderRadius:d,style:f,markerEnd:p,markerStart:y,interactionWidth:b})})}var K3=Rx({isInternal:!1}),Bx=Rx({isInternal:!0});K3.displayName="StraightEdge";Bx.displayName="StraightEdgeInternal";function kx(t){return(0,D.memo)(({id:e,sourceX:n,sourceY:o,targetX:a,targetY:l,sourcePosition:i=G.Bottom,targetPosition:r=G.Top,label:u,labelStyle:s,labelShowBg:c,labelBgStyle:d,labelBgPadding:f,labelBgBorderRadius:p,style:y,markerEnd:b,markerStart:x,pathOptions:g,interactionWidth:m})=>{let[h,v,_]=xc({sourceX:n,sourceY:o,sourcePosition:i,targetX:a,targetY:l,targetPosition:r,curvature:g?.curvature}),E=t.isInternal?void 0:e;return(0,O.jsx)(wl,{id:E,path:h,labelX:v,labelY:_,label:u,labelStyle:s,labelShowBg:c,labelBgStyle:d,labelBgPadding:f,labelBgBorderRadius:p,style:y,markerEnd:b,markerStart:x,interactionWidth:m})})}var $3=kx({isInternal:!1}),Lx=kx({isInternal:!0});$3.displayName="BezierEdge";Lx.displayName="BezierEdgeInternal";var ax={default:Lx,straight:Bx,step:Hx,smoothstep:Ox,simplebezier:Ax},lx={sourceX:null,sourceY:null,targetX:null,targetY:null,sourcePosition:null,targetPosition:null},J3=(t,e,n)=>n===G.Left?t-e:n===G.Right?t+e:t,I3=(t,e,n)=>n===G.Top?t-e:n===G.Bottom?t+e:t,ix="react-flow__edgeupdater";function rx({position:t,centerX:e,centerY:n,radius:o=10,onMouseDown:a,onMouseEnter:l,onMouseOut:i,type:r}){return(0,O.jsx)("circle",{onMouseDown:a,onMouseEnter:l,onMouseOut:i,className:Tt([ix,`${ix}-${r}`]),cx:J3(e,o,t),cy:I3(n,o,t),r:o,stroke:"transparent",fill:"transparent"})}function W3({isReconnectable:t,reconnectRadius:e,edge:n,sourceX:o,sourceY:a,targetX:l,targetY:i,sourcePosition:r,targetPosition:u,onReconnect:s,onReconnectStart:c,onReconnectEnd:d,setReconnecting:f,setUpdateHover:p}){let y=zt(),b=(v,_)=>{if(v.button!==0)return;let{autoPanOnConnect:E,domNode:w,connectionMode:N,connectionRadius:M,lib:R,onConnectStart:C,cancelConnection:k,nodeLookup:V,rfId:S,panBy:A,updateConnection:z}=y.getState(),T=_.type==="target",B=(Z,q)=>{f(!1),d?.(Z,n,_.type,q)},H=Z=>s?.(n,Z),X=(Z,q)=>{f(!0),c?.(v,n,_.type),C?.(Z,q)};Nc.onPointerDown(v.nativeEvent,{autoPanOnConnect:E,connectionMode:N,connectionRadius:M,domNode:w,handleId:_.id,nodeId:_.nodeId,nodeLookup:V,isTarget:T,edgeUpdaterType:_.type,lib:R,flowId:S,cancelConnection:k,panBy:A,isValidConnection:(...Z)=>y.getState().isValidConnection?.(...Z)??!0,onConnect:H,onConnectStart:X,onConnectEnd:(...Z)=>y.getState().onConnectEnd?.(...Z),onReconnectEnd:B,updateConnection:z,getTransform:()=>y.getState().transform,getFromHandle:()=>y.getState().connection.fromHandle,dragThreshold:y.getState().connectionDragThreshold,handleDomNode:v.currentTarget})},x=v=>b(v,{nodeId:n.target,id:n.targetHandle??null,type:"target"}),g=v=>b(v,{nodeId:n.source,id:n.sourceHandle??null,type:"source"}),m=()=>p(!0),h=()=>p(!1);return(0,O.jsxs)(O.Fragment,{children:[(t===!0||t==="source")&&(0,O.jsx)(rx,{position:r,centerX:o,centerY:a,radius:e,onMouseDown:x,onMouseEnter:m,onMouseOut:h,type:"source"}),(t===!0||t==="target")&&(0,O.jsx)(rx,{position:u,centerX:l,centerY:i,radius:e,onMouseDown:g,onMouseEnter:m,onMouseOut:h,type:"target"})]})}function F3({id:t,edgesFocusable:e,edgesReconnectable:n,elementsSelectable:o,onClick:a,onDoubleClick:l,onContextMenu:i,onMouseEnter:r,onMouseMove:u,onMouseLeave:s,reconnectRadius:c,onReconnect:d,onReconnectStart:f,onReconnectEnd:p,rfId:y,edgeTypes:b,noPanClassName:x,onError:g,disableKeyboardA11y:m}){let h=ut($=>$.edgeLookup.get(t)),v=ut($=>$.defaultEdgeOptions);h=v?{...v,...h}:h;let _=h.type||"default",E=b?.[_]||ax[_];E===void 0&&(g?.("011",Me.error011(_)),_="default",E=b?.default||ax.default);let w=!!(h.focusable||e&&typeof h.focusable>"u"),N=typeof d<"u"&&(h.reconnectable||n&&typeof h.reconnectable>"u"),M=!!(h.selectable||o&&typeof h.selectable>"u"),R=(0,D.useRef)(null),[C,k]=(0,D.useState)(!1),[V,S]=(0,D.useState)(!1),A=zt(),{zIndex:z,sourceX:T,sourceY:B,targetX:H,targetY:X,sourcePosition:Z,targetPosition:q}=ut((0,D.useCallback)($=>{let W=$.nodeLookup.get(h.source),ct=$.nodeLookup.get(h.target);if(!W||!ct)return{zIndex:h.zIndex,...lx};let dt=ub({id:t,sourceNode:W,targetNode:ct,sourceHandle:h.sourceHandle||null,targetHandle:h.targetHandle||null,connectionMode:$.connectionMode,onError:g});return{zIndex:lb({selected:h.selected,zIndex:h.zIndex,sourceNode:W,targetNode:ct,elevateOnSelect:$.elevateEdgesOnSelect,zIndexMode:$.zIndexMode}),...dt||lx}},[h.source,h.target,h.sourceHandle,h.targetHandle,h.selected,h.zIndex]),Et),K=(0,D.useMemo)(()=>h.markerStart?`url('#${_c(h.markerStart,y)}')`:void 0,[h.markerStart,y]),j=(0,D.useMemo)(()=>h.markerEnd?`url('#${_c(h.markerEnd,y)}')`:void 0,[h.markerEnd,y]);if(h.hidden||T===null||B===null||H===null||X===null)return null;let I=$=>{let{addSelectedEdges:W,unselectNodesAndEdges:ct,multiSelectionActive:dt}=A.getState();M&&(A.setState({nodesSelectionActive:!1}),h.selected&&dt?(ct({nodes:[],edges:[h]}),R.current?.blur()):W([t])),a&&a($,h)},ot=l?$=>{l($,{...h})}:void 0,J=i?$=>{i($,{...h})}:void 0,U=r?$=>{r($,{...h})}:void 0,Q=u?$=>{u($,{...h})}:void 0,nt=s?$=>{s($,{...h})}:void 0,tt=$=>{if(!m&&oh.includes($.key)&&M){let{unselectNodesAndEdges:W,addSelectedEdges:ct}=A.getState();$.key==="Escape"?(R.current?.blur(),W({edges:[h]})):ct([t])}};return(0,O.jsx)("svg",{style:{zIndex:z},children:(0,O.jsxs)("g",{className:Tt(["react-flow__edge",`react-flow__edge-${_}`,h.className,x,{selected:h.selected,animated:h.animated,inactive:!M&&!a,updating:C,selectable:M}]),onClick:I,onDoubleClick:ot,onContextMenu:J,onMouseEnter:U,onMouseMove:Q,onMouseLeave:nt,onKeyDown:w?tt:void 0,tabIndex:w?0:void 0,role:h.ariaRole??(w?"group":"img"),"aria-roledescription":"edge","data-id":t,"data-testid":`rf__edge-${t}`,"aria-label":h.ariaLabel===null?void 0:h.ariaLabel||`Edge from ${h.source} to ${h.target}`,"aria-describedby":w?`${px}-${y}`:void 0,ref:R,...h.domAttributes,children:[!V&&(0,O.jsx)(E,{id:t,source:h.source,target:h.target,type:h.type,selected:h.selected,animated:h.animated,selectable:M,deletable:h.deletable??!0,label:h.label,labelStyle:h.labelStyle,labelShowBg:h.labelShowBg,labelBgStyle:h.labelBgStyle,labelBgPadding:h.labelBgPadding,labelBgBorderRadius:h.labelBgBorderRadius,sourceX:T,sourceY:B,targetX:H,targetY:X,sourcePosition:Z,targetPosition:q,data:h.data,style:h.style,sourceHandleId:h.sourceHandle,targetHandleId:h.targetHandle,markerStart:K,markerEnd:j,pathOptions:"pathOptions"in h?h.pathOptions:void 0,interactionWidth:h.interactionWidth}),N&&(0,O.jsx)(W3,{edge:h,isReconnectable:N,reconnectRadius:c,onReconnect:d,onReconnectStart:f,onReconnectEnd:p,sourceX:T,sourceY:B,targetX:H,targetY:X,sourcePosition:Z,targetPosition:q,setUpdateHover:k,setReconnecting:S})]})})}var P3=(0,D.memo)(F3),tA=t=>({edgesFocusable:t.edgesFocusable,edgesReconnectable:t.edgesReconnectable,elementsSelectable:t.elementsSelectable,connectionMode:t.connectionMode,onError:t.onError});function Ux({defaultMarkerColor:t,onlyRenderVisibleElements:e,rfId:n,edgeTypes:o,noPanClassName:a,onReconnect:l,onEdgeContextMenu:i,onEdgeMouseEnter:r,onEdgeMouseMove:u,onEdgeMouseLeave:s,onEdgeClick:c,reconnectRadius:d,onEdgeDoubleClick:f,onReconnectStart:p,onReconnectEnd:y,disableKeyboardA11y:b}){let{edgesFocusable:x,edgesReconnectable:g,elementsSelectable:m,onError:h}=ut(tA,Et),v=U3(e);return(0,O.jsxs)("div",{className:"react-flow__edges",children:[(0,O.jsx)(Z3,{defaultColor:t,rfId:n}),v.map(_=>(0,O.jsx)(P3,{id:_,edgesFocusable:x,edgesReconnectable:g,elementsSelectable:m,noPanClassName:a,onReconnect:l,onContextMenu:i,onMouseEnter:r,onMouseMove:u,onMouseLeave:s,onClick:c,reconnectRadius:d,onDoubleClick:f,onReconnectStart:p,onReconnectEnd:y,rfId:n,onError:h,edgeTypes:o,disableKeyboardA11y:b},_))]})}Ux.displayName="EdgeRenderer";var eA=(0,D.memo)(Ux),nA=t=>`translate(${t.transform[0]}px,${t.transform[1]}px) scale(${t.transform[2]})`;function oA({children:t}){let e=ut(nA);return(0,O.jsx)("div",{className:"react-flow__viewport xyflow__viewport react-flow__container",style:{transform:e},children:t})}function aA(t){let e=Oh(),n=(0,D.useRef)(!1);(0,D.useEffect)(()=>{!n.current&&e.viewportInitialized&&t&&(setTimeout(()=>t(e),1),n.current=!0)},[t,e.viewportInitialized])}var lA=t=>t.panZoom?.syncViewport;function iA(t){let e=ut(lA),n=zt();return(0,D.useEffect)(()=>{t&&(e?.(t),n.setState({transform:[t.x,t.y,t.zoom]}))},[t,e]),null}function ux(t){return t.connection.inProgress?{...t.connection,to:fa(t.connection.to,t.transform)}:{...t.connection}}function rA(t){return t?n=>{let o=ux(n);return t(o)}:ux}function uA(t){let e=rA(t);return ut(e,Et)}var cA=t=>({nodesConnectable:t.nodesConnectable,isValid:t.connection.isValid,inProgress:t.connection.inProgress,width:t.width,height:t.height});function sA({containerStyle:t,style:e,type:n,component:o}){let{nodesConnectable:a,width:l,height:i,isValid:r,inProgress:u}=ut(cA,Et);return!(l&&a&&u)?null:(0,O.jsx)("svg",{style:t,width:l,height:i,className:"react-flow__connectionline react-flow__container",children:(0,O.jsx)("g",{className:Tt(["react-flow__connection",ih(r)]),children:(0,O.jsx)(Yx,{style:e,type:n,CustomComponent:o,isValid:r})})})}var Yx=({style:t,type:e=rn.Bezier,CustomComponent:n,isValid:o})=>{let{inProgress:a,from:l,fromNode:i,fromHandle:r,fromPosition:u,to:s,toNode:c,toHandle:d,toPosition:f,pointer:p}=uA();if(!a)return;if(n)return(0,O.jsx)(n,{connectionLineType:e,connectionLineStyle:t,fromNode:i,fromHandle:r,fromX:l.x,fromY:l.y,toX:s.x,toY:s.y,fromPosition:u,toPosition:f,connectionStatus:ih(o),toNode:c,toHandle:d,pointer:p});let y="",b={sourceX:l.x,sourceY:l.y,sourcePosition:u,targetX:s.x,targetY:s.y,targetPosition:f};switch(e){case rn.Bezier:[y]=xc(b);break;case rn.SimpleBezier:[y]=Mx(b);break;case rn.Step:[y]=da({...b,borderRadius:0});break;case rn.SmoothStep:[y]=da(b);break;default:[y]=Sc(b)}return(0,O.jsx)("path",{d:y,fill:"none",className:"react-flow__connection-path",style:t})};Yx.displayName="ConnectionLine";var fA={};function cx(t=fA){let e=(0,D.useRef)(t),n=zt();(0,D.useEffect)(()=>{},[t])}function dA(){let t=zt(),e=(0,D.useRef)(!1);(0,D.useEffect)(()=>{},[])}function Vx({nodeTypes:t,edgeTypes:e,onInit:n,onNodeClick:o,onEdgeClick:a,onNodeDoubleClick:l,onEdgeDoubleClick:i,onNodeMouseEnter:r,onNodeMouseMove:u,onNodeMouseLeave:s,onNodeContextMenu:c,onSelectionContextMenu:d,onSelectionStart:f,onSelectionEnd:p,connectionLineType:y,connectionLineStyle:b,connectionLineComponent:x,connectionLineContainerStyle:g,selectionKeyCode:m,selectionOnDrag:h,selectionMode:v,multiSelectionKeyCode:_,panActivationKeyCode:E,zoomActivationKeyCode:w,deleteKeyCode:N,onlyRenderVisibleElements:M,elementsSelectable:R,defaultViewport:C,translateExtent:k,minZoom:V,maxZoom:S,preventScrolling:A,defaultMarkerColor:z,zoomOnScroll:T,zoomOnPinch:B,panOnScroll:H,panOnScrollSpeed:X,panOnScrollMode:Z,zoomOnDoubleClick:q,panOnDrag:K,autoPanOnSelection:j,onPaneClick:I,onPaneMouseEnter:ot,onPaneMouseMove:J,onPaneMouseLeave:U,onPaneScroll:Q,onPaneContextMenu:nt,paneClickDistance:tt,nodeClickDistance:$,onEdgeContextMenu:W,onEdgeMouseEnter:ct,onEdgeMouseMove:dt,onEdgeMouseLeave:Dt,reconnectRadius:ie,onReconnect:cn,onReconnectStart:Je,onReconnectEnd:Ie,noDragClassName:sn,noWheelClassName:El,noPanClassName:Mo,disableKeyboardA11y:zo,nodeExtent:qe,rfId:fn,viewport:dn,onViewportChange:Ao}){return cx(t),cx(e),dA(),aA(n),iA(dn),(0,O.jsx)(A3,{onPaneClick:I,onPaneMouseEnter:ot,onPaneMouseMove:J,onPaneMouseLeave:U,onPaneContextMenu:nt,onPaneScroll:Q,paneClickDistance:tt,deleteKeyCode:N,selectionKeyCode:m,selectionOnDrag:h,selectionMode:v,onSelectionStart:f,onSelectionEnd:p,multiSelectionKeyCode:_,panActivationKeyCode:E,zoomActivationKeyCode:w,elementsSelectable:R,zoomOnScroll:T,zoomOnPinch:B,zoomOnDoubleClick:q,panOnScroll:H,panOnScrollSpeed:X,panOnScrollMode:Z,panOnDrag:K,autoPanOnSelection:j,defaultViewport:C,translateExtent:k,minZoom:V,maxZoom:S,onSelectionContextMenu:d,preventScrolling:A,noDragClassName:sn,noWheelClassName:El,noPanClassName:Mo,disableKeyboardA11y:zo,onViewportChange:Ao,isControlledViewport:!!dn,children:(0,O.jsxs)(oA,{children:[(0,O.jsx)(eA,{edgeTypes:e,onEdgeClick:a,onEdgeDoubleClick:i,onReconnect:cn,onReconnectStart:Je,onReconnectEnd:Ie,onlyRenderVisibleElements:M,onEdgeContextMenu:W,onEdgeMouseEnter:ct,onEdgeMouseMove:dt,onEdgeMouseLeave:Dt,reconnectRadius:ie,defaultMarkerColor:z,noPanClassName:Mo,disableKeyboardA11y:zo,rfId:fn}),(0,O.jsx)(sA,{style:b,type:y,component:x,containerStyle:g}),(0,O.jsx)("div",{className:"react-flow__edgelabel-renderer"}),(0,O.jsx)(L3,{nodeTypes:t,onNodeClick:o,onNodeDoubleClick:l,onNodeMouseEnter:r,onNodeMouseMove:u,onNodeMouseLeave:s,onNodeContextMenu:c,nodeClickDistance:$,onlyRenderVisibleElements:M,noPanClassName:Mo,noDragClassName:sn,disableKeyboardA11y:zo,nodeExtent:qe,rfId:fn}),(0,O.jsx)("div",{className:"react-flow__viewport-portal"})]})})}Vx.displayName="GraphView";var hA=(0,D.memo)(Vx),pA=hh("React Flow","https://reactflow.dev/"),sx=({nodes:t,edges:e,defaultNodes:n,defaultEdges:o,width:a,height:l,fitView:i,fitViewOptions:r,minZoom:u=.5,maxZoom:s=2,nodeOrigin:c,nodeExtent:d,zIndexMode:f="basic"}={})=>{let p=new Map,y=new Map,b=new Map,x=new Map,g=o??e??[],m=n??t??[],h=c??[0,0],v=d??ml;Nh(b,x,g);let{nodesInitialized:_}=wc(m,p,y,{nodeOrigin:h,nodeExtent:v,zIndexMode:f}),E=[0,0,1];if(i&&a&&l){let w=yl(p,{filter:C=>!!((C.width||C.initialWidth)&&(C.height||C.initialHeight))}),{x:N,y:M,zoom:R}=Fi(w,a,l,u,s,r?.padding??.1);E=[N,M,R]}return{rfId:"1",width:a??0,height:l??0,transform:E,nodes:m,nodesInitialized:_,nodeLookup:p,parentLookup:y,edges:g,edgeLookup:x,connectionLookup:b,onNodesChange:null,onEdgesChange:null,hasDefaultNodes:n!==void 0,hasDefaultEdges:o!==void 0,panZoom:null,minZoom:u,maxZoom:s,translateExtent:ml,nodeExtent:v,nodesSelectionActive:!1,userSelectionActive:!1,userSelectionRect:null,connectionMode:So.Strict,domNode:null,paneDragging:!1,noPanClassName:"nopan",nodeOrigin:h,nodeDragThreshold:1,connectionDragThreshold:1,snapGrid:[15,15],snapToGrid:!1,nodesDraggable:!0,nodesConnectable:!0,nodesFocusable:!0,edgesFocusable:!0,edgesReconnectable:!0,elementsSelectable:!0,elevateNodesOnSelect:!0,elevateEdgesOnSelect:!0,selectNodesOnDrag:!0,multiSelectionActive:!1,fitViewQueued:i??!1,fitViewOptions:r,fitViewResolver:null,connection:{...lh},connectionClickStartHandle:null,connectOnClick:!0,ariaLiveMessage:"",autoPanOnConnect:!0,autoPanOnNodeDrag:!0,autoPanOnNodeFocus:!0,autoPanSpeed:15,connectionRadius:20,onError:pA,isValidConnection:void 0,onSelectionChangeHandlers:[],lib:"react",debug:!1,ariaLabelConfig:ah,zIndexMode:f,onNodesChangeMiddlewareMap:new Map,onEdgesChangeMiddlewareMap:new Map}},gA=({nodes:t,edges:e,defaultNodes:n,defaultEdges:o,width:a,height:l,fitView:i,fitViewOptions:r,minZoom:u,maxZoom:s,nodeOrigin:c,nodeExtent:d,zIndexMode:f})=>qb((p,y)=>{async function b(){let{nodeLookup:x,panZoom:g,fitViewOptions:m,fitViewResolver:h,width:v,height:_,minZoom:E,maxZoom:w}=y();g&&(await tb({nodes:x,width:v,height:_,panZoom:g,minZoom:E,maxZoom:w},m),h?.resolve(!0),p({fitViewResolver:null}))}return{...sx({nodes:t,edges:e,width:a,height:l,fitView:i,fitViewOptions:r,minZoom:u,maxZoom:s,nodeOrigin:c,nodeExtent:d,defaultNodes:n,defaultEdges:o,zIndexMode:f}),setNodes:x=>{let{nodeLookup:g,parentLookup:m,nodeOrigin:h,elevateNodesOnSelect:v,fitViewQueued:_,zIndexMode:E,nodesSelectionActive:w}=y(),{nodesInitialized:N,hasSelectedNodes:M}=wc(x,g,m,{nodeOrigin:h,nodeExtent:d,elevateNodesOnSelect:v,checkEquality:!0,zIndexMode:E}),R=w&&M;_&&N?(b(),p({nodes:x,nodesInitialized:N,fitViewQueued:!1,fitViewOptions:void 0,nodesSelectionActive:R})):p({nodes:x,nodesInitialized:N,nodesSelectionActive:R})},setEdges:x=>{let{connectionLookup:g,edgeLookup:m}=y();Nh(g,m,x),p({edges:x})},setDefaultNodesAndEdges:(x,g)=>{if(x){let{setNodes:m}=y();m(x),p({hasDefaultNodes:!0})}if(g){let{setEdges:m}=y();m(g),p({hasDefaultEdges:!0})}},updateNodeInternals:x=>{let{triggerNodeChanges:g,nodeLookup:m,parentLookup:h,domNode:v,nodeOrigin:_,nodeExtent:E,debug:w,fitViewQueued:N,zIndexMode:M}=y(),{changes:R,updatedInternals:C}=hb(x,m,h,v,_,E,M);C&&(fb(m,h,{nodeOrigin:_,nodeExtent:E,zIndexMode:M}),N?(b(),p({fitViewQueued:!1,fitViewOptions:void 0})):p({}),R?.length>0&&(w&&console.log("React Flow: trigger node changes",R),g?.(R)))},updateNodePositions:(x,g=!1)=>{let m=[],h=[],{nodeLookup:v,triggerNodeChanges:_,connection:E,updateConnection:w,onNodesChangeMiddlewareMap:N}=y();for(let[M,R]of x){let C=v.get(M),k=!!(C?.expandParent&&C?.parentId&&R?.position),V={id:M,type:"position",position:k?{x:Math.max(0,R.position.x),y:Math.max(0,R.position.y)}:R.position,dragging:g};if(C&&E.inProgress&&E.fromNode.id===C.id){let S=_o(C,E.fromHandle,G.Left,!0);w({...E,from:S})}k&&C.parentId&&m.push({id:M,parentId:C.parentId,rect:{...R.internals.positionAbsolute,width:R.measured.width??0,height:R.measured.height??0}}),h.push(V)}if(m.length>0){let{parentLookup:M,nodeOrigin:R}=y(),C=Ec(m,v,M,R);h.push(...C)}for(let M of N.values())h=M(h);_(h)},triggerNodeChanges:x=>{let{onNodesChange:g,setNodes:m,nodes:h,hasDefaultNodes:v,debug:_}=y();if(x?.length){if(v){let E=Iz(x,h);m(E)}_&&console.log("React Flow: trigger node changes",x),g?.(x)}},triggerEdgeChanges:x=>{let{onEdgesChange:g,setEdges:m,edges:h,hasDefaultEdges:v,debug:_}=y();if(x?.length){if(v){let E=Wz(x,h);m(E)}_&&console.log("React Flow: trigger edge changes",x),g?.(x)}},addSelectedNodes:x=>{let{multiSelectionActive:g,edgeLookup:m,nodeLookup:h,triggerNodeChanges:v,triggerEdgeChanges:_}=y();if(g){let E=x.map(w=>ha(w,!0));v(E);return}v(_l(h,new Set([...x]),!0)),_(_l(m))},addSelectedEdges:x=>{let{multiSelectionActive:g,edgeLookup:m,nodeLookup:h,triggerNodeChanges:v,triggerEdgeChanges:_}=y();if(g){let E=x.map(w=>ha(w,!0));_(E);return}_(_l(m,new Set([...x]))),v(_l(h,new Set,!0))},unselectNodesAndEdges:({nodes:x,edges:g}={})=>{let{edges:m,nodes:h,nodeLookup:v,triggerNodeChanges:_,triggerEdgeChanges:E}=y(),w=x||h,N=g||m,M=[];for(let C of w){if(!C.selected)continue;let k=v.get(C.id);k&&(k.selected=!1),M.push(ha(C.id,!1))}let R=[];for(let C of N)C.selected&&R.push(ha(C.id,!1));_(M),E(R)},setMinZoom:x=>{let{panZoom:g,maxZoom:m}=y();g?.setScaleExtent([x,m]),p({minZoom:x})},setMaxZoom:x=>{let{panZoom:g,minZoom:m}=y();g?.setScaleExtent([m,x]),p({maxZoom:x})},setTranslateExtent:x=>{y().panZoom?.setTranslateExtent(x),p({translateExtent:x})},resetSelectedElements:()=>{let{edges:x,nodes:g,triggerNodeChanges:m,triggerEdgeChanges:h,elementsSelectable:v}=y();if(!v)return;let _=g.reduce((w,N)=>N.selected?[...w,ha(N.id,!1)]:w,[]),E=x.reduce((w,N)=>N.selected?[...w,ha(N.id,!1)]:w,[]);m(_),h(E)},setNodeExtent:x=>{let{nodes:g,nodeLookup:m,parentLookup:h,nodeOrigin:v,elevateNodesOnSelect:_,nodeExtent:E,zIndexMode:w}=y();x[0][0]===E[0][0]&&x[0][1]===E[0][1]&&x[1][0]===E[1][0]&&x[1][1]===E[1][1]||(wc(g,m,h,{nodeOrigin:v,nodeExtent:x,elevateNodesOnSelect:_,checkEquality:!1,zIndexMode:w}),p({nodeExtent:x}))},panBy:x=>{let{transform:g,width:m,height:h,panZoom:v,translateExtent:_}=y();return pb({delta:x,panZoom:v,transform:g,translateExtent:_,width:m,height:h})},setCenter:async(x,g,m)=>{let{width:h,height:v,maxZoom:_,panZoom:E}=y();if(!E)return!1;let w=typeof m?.zoom<"u"?m.zoom:_;return await E.setViewport({x:h/2-x*w,y:v/2-g*w,zoom:w},{duration:m?.duration,ease:m?.ease,interpolate:m?.interpolate}),!0},cancelConnection:()=>{p({connection:{...lh}})},updateConnection:x=>{p({connection:x})},reset:()=>p({...sx()})}},Object.is);function mA({initialNodes:t,initialEdges:e,defaultNodes:n,defaultEdges:o,initialWidth:a,initialHeight:l,initialMinZoom:i,initialMaxZoom:r,initialFitViewOptions:u,fitView:s,nodeOrigin:c,nodeExtent:d,zIndexMode:f,children:p}){let[y]=(0,D.useState)(()=>gA({nodes:t,edges:e,defaultNodes:n,defaultEdges:o,width:a,height:l,fitView:s,minZoom:i,maxZoom:r,fitViewOptions:u,nodeOrigin:c,nodeExtent:d,zIndexMode:f}));return(0,O.jsx)(Tz,{value:y,children:(0,O.jsx)(o3,{children:p})})}function yA({children:t,nodes:e,edges:n,defaultNodes:o,defaultEdges:a,width:l,height:i,fitView:r,fitViewOptions:u,minZoom:s,maxZoom:c,nodeOrigin:d,nodeExtent:f,zIndexMode:p}){return(0,D.useContext)(Oc)?(0,O.jsx)(O.Fragment,{children:t}):(0,O.jsx)(mA,{initialNodes:e,initialEdges:n,defaultNodes:o,defaultEdges:a,initialWidth:l,initialHeight:i,fitView:r,initialFitViewOptions:u,initialMinZoom:s,initialMaxZoom:c,nodeOrigin:d,nodeExtent:f,zIndexMode:p,children:t})}var vA={width:"100%",height:"100%",overflow:"hidden",position:"relative",zIndex:0};function bA({nodes:t,edges:e,defaultNodes:n,defaultEdges:o,className:a,nodeTypes:l,edgeTypes:i,onNodeClick:r,onEdgeClick:u,onInit:s,onMove:c,onMoveStart:d,onMoveEnd:f,onConnect:p,onConnectStart:y,onConnectEnd:b,onClickConnectStart:x,onClickConnectEnd:g,onNodeMouseEnter:m,onNodeMouseMove:h,onNodeMouseLeave:v,onNodeContextMenu:_,onNodeDoubleClick:E,onNodeDragStart:w,onNodeDrag:N,onNodeDragStop:M,onNodesDelete:R,onEdgesDelete:C,onDelete:k,onSelectionChange:V,onSelectionDragStart:S,onSelectionDrag:A,onSelectionDragStop:z,onSelectionContextMenu:T,onSelectionStart:B,onSelectionEnd:H,onBeforeDelete:X,connectionMode:Z,connectionLineType:q=rn.Bezier,connectionLineStyle:K,connectionLineComponent:j,connectionLineContainerStyle:I,deleteKeyCode:ot="Backspace",selectionKeyCode:J="Shift",selectionOnDrag:U=!1,selectionMode:Q=ia.Full,panActivationKeyCode:nt="Space",multiSelectionKeyCode:tt=xl()?"Meta":"Control",zoomActivationKeyCode:$=xl()?"Meta":"Control",snapToGrid:W,snapGrid:ct,onlyRenderVisibleElements:dt=!1,selectNodesOnDrag:Dt,nodesDraggable:ie,autoPanOnNodeFocus:cn,nodesConnectable:Je,nodesFocusable:Ie,nodeOrigin:sn=gx,edgesFocusable:El,edgesReconnectable:Mo,elementsSelectable:zo=!0,defaultViewport:qe=Zz,minZoom:fn=.5,maxZoom:dn=2,translateExtent:Ao=ml,preventScrolling:Px=!0,nodeExtent:kc,defaultMarkerColor:tS="#b1b1b7",zoomOnScroll:eS=!0,zoomOnPinch:nS=!0,panOnScroll:oS=!1,panOnScrollSpeed:aS=.5,panOnScrollMode:lS=Un.Free,zoomOnDoubleClick:iS=!0,panOnDrag:rS=!0,onPaneClick:uS,onPaneMouseEnter:cS,onPaneMouseMove:sS,onPaneMouseLeave:fS,onPaneScroll:dS,onPaneContextMenu:hS,paneClickDistance:pS=1,nodeClickDistance:gS=0,children:mS,onReconnect:yS,onReconnectStart:vS,onReconnectEnd:bS,onEdgeContextMenu:xS,onEdgeDoubleClick:SS,onEdgeMouseEnter:_S,onEdgeMouseMove:wS,onEdgeMouseLeave:ES,reconnectRadius:NS=10,onNodesChange:MS,onEdgesChange:zS,noDragClassName:AS="nodrag",noWheelClassName:CS="nowheel",noPanClassName:Hh="nopan",fitView:Rh,fitViewOptions:Bh,connectOnClick:TS,attributionPosition:OS,proOptions:DS,defaultEdgeOptions:HS,elevateNodesOnSelect:RS=!0,elevateEdgesOnSelect:BS=!1,disableKeyboardA11y:kh=!1,autoPanOnConnect:kS,autoPanOnNodeDrag:LS,autoPanOnSelection:US=!0,autoPanSpeed:YS,connectionRadius:VS,isValidConnection:qS,onError:XS,style:ZS,id:Lh,nodeDragThreshold:GS,connectionDragThreshold:QS,viewport:jS,onViewportChange:KS,width:$S,height:JS,colorMode:IS="light",debug:WS,onScroll:Uh,ariaLabelConfig:FS,zIndexMode:Yh="basic",...PS},t_){let Lc=Lh||"1",e_=Kz(IS),n_=(0,D.useCallback)(Vh=>{Vh.currentTarget.scrollTo({top:0,left:0,behavior:"instant"}),Uh?.(Vh)},[Uh]);return(0,O.jsx)("div",{"data-testid":"rf__wrapper",...PS,onScroll:n_,style:{...ZS,...vA},ref:t_,className:Tt(["react-flow",a,e_]),id:Lh,role:"application",children:(0,O.jsxs)(yA,{nodes:t,edges:e,width:$S,height:JS,fitView:Rh,fitViewOptions:Bh,minZoom:fn,maxZoom:dn,nodeOrigin:sn,nodeExtent:kc,zIndexMode:Yh,children:[(0,O.jsx)(jz,{nodes:t,edges:e,defaultNodes:n,defaultEdges:o,onConnect:p,onConnectStart:y,onConnectEnd:b,onClickConnectStart:x,onClickConnectEnd:g,nodesDraggable:ie,autoPanOnNodeFocus:cn,nodesConnectable:Je,nodesFocusable:Ie,edgesFocusable:El,edgesReconnectable:Mo,elementsSelectable:zo,elevateNodesOnSelect:RS,elevateEdgesOnSelect:BS,minZoom:fn,maxZoom:dn,nodeExtent:kc,onNodesChange:MS,onEdgesChange:zS,snapToGrid:W,snapGrid:ct,connectionMode:Z,translateExtent:Ao,connectOnClick:TS,defaultEdgeOptions:HS,fitView:Rh,fitViewOptions:Bh,onNodesDelete:R,onEdgesDelete:C,onDelete:k,onNodeDragStart:w,onNodeDrag:N,onNodeDragStop:M,onSelectionDrag:A,onSelectionDragStart:S,onSelectionDragStop:z,onMove:c,onMoveStart:d,onMoveEnd:f,noPanClassName:Hh,nodeOrigin:sn,rfId:Lc,autoPanOnConnect:kS,autoPanOnNodeDrag:LS,autoPanSpeed:YS,onError:XS,connectionRadius:VS,isValidConnection:qS,selectNodesOnDrag:Dt,nodeDragThreshold:GS,connectionDragThreshold:QS,onBeforeDelete:X,debug:WS,ariaLabelConfig:FS,zIndexMode:Yh}),(0,O.jsx)(hA,{onInit:s,onNodeClick:r,onEdgeClick:u,onNodeMouseEnter:m,onNodeMouseMove:h,onNodeMouseLeave:v,onNodeContextMenu:_,onNodeDoubleClick:E,nodeTypes:l,edgeTypes:i,connectionLineType:q,connectionLineStyle:K,connectionLineComponent:j,connectionLineContainerStyle:I,selectionKeyCode:J,selectionOnDrag:U,selectionMode:Q,deleteKeyCode:ot,multiSelectionKeyCode:tt,panActivationKeyCode:nt,zoomActivationKeyCode:$,onlyRenderVisibleElements:dt,defaultViewport:qe,translateExtent:Ao,minZoom:fn,maxZoom:dn,preventScrolling:Px,zoomOnScroll:eS,zoomOnPinch:nS,zoomOnDoubleClick:iS,panOnScroll:oS,panOnScrollSpeed:aS,panOnScrollMode:lS,panOnDrag:rS,autoPanOnSelection:US,onPaneClick:uS,onPaneMouseEnter:cS,onPaneMouseMove:sS,onPaneMouseLeave:fS,onPaneScroll:dS,onPaneContextMenu:hS,paneClickDistance:pS,nodeClickDistance:gS,onSelectionContextMenu:T,onSelectionStart:B,onSelectionEnd:H,onReconnect:yS,onReconnectStart:vS,onReconnectEnd:bS,onEdgeContextMenu:xS,onEdgeDoubleClick:SS,onEdgeMouseEnter:_S,onEdgeMouseMove:wS,onEdgeMouseLeave:ES,reconnectRadius:NS,defaultMarkerColor:tS,noDragClassName:AS,noWheelClassName:CS,noPanClassName:Hh,rfId:Lc,disableKeyboardA11y:kh,nodeExtent:kc,viewport:jS,onViewportChange:KS}),(0,O.jsx)(Xz,{onSelectionChange:V}),mS,(0,O.jsx)(Lz,{proOptions:DS,position:OS}),(0,O.jsx)(kz,{rfId:Lc,disableKeyboardA11y:kh})]})})}var qx=yx(bA),xA=t=>t.domNode?.querySelector(".react-flow__edgelabel-renderer");function Xx({children:t}){let e=ut(xA);return e?(0,fx.createPortal)(t,e):null}var U6=Me.error014();function SA({dimensions:t,lineWidth:e,variant:n,className:o}){return(0,O.jsx)("path",{strokeWidth:e,d:`M${t[0]/2} 0 V${t[1]} M0 ${t[1]/2} H${t[0]}`,className:Tt(["react-flow__background-pattern",n,o])})}function _A({radius:t,className:e}){return(0,O.jsx)("circle",{cx:t,cy:t,r:t,className:Tt(["react-flow__background-pattern","dots",e])})}var Eo;(function(t){t.Lines="lines",t.Dots="dots",t.Cross="cross"})(Eo||(Eo={}));var wA={[Eo.Dots]:1,[Eo.Lines]:1,[Eo.Cross]:6},EA=t=>({transform:t.transform,patternId:`pattern-${t.rfId}`});function Zx({id:t,variant:e=Eo.Dots,gap:n=20,size:o,lineWidth:a=1,offset:l=0,color:i,bgColor:r,style:u,className:s,patternClassName:c}){let d=(0,D.useRef)(null),{transform:f,patternId:p}=ut(EA,Et),y=o||wA[e],b=e===Eo.Dots,x=e===Eo.Cross,g=Array.isArray(n)?n:[n,n],m=[g[0]*f[2]||1,g[1]*f[2]||1],h=y*f[2],v=Array.isArray(l)?l:[l,l],_=x?[h,h]:m,E=[v[0]*f[2]||1+_[0]/2,v[1]*f[2]||1+_[1]/2],w=`${p}${t||""}`;return(0,O.jsxs)("svg",{className:Tt(["react-flow__background",s]),style:{...u,...Hc,"--xy-background-color-props":r,"--xy-background-pattern-color-props":i},ref:d,"data-testid":"rf__background",children:[(0,O.jsx)("pattern",{id:w,x:f[0]%m[0],y:f[1]%m[1],width:m[0],height:m[1],patternUnits:"userSpaceOnUse",patternTransform:`translate(-${E[0]},-${E[1]})`,children:b?(0,O.jsx)(_A,{radius:h/2,className:c}):(0,O.jsx)(SA,{dimensions:_,lineWidth:a,variant:e,className:c})}),(0,O.jsx)("rect",{x:"0",y:"0",width:"100%",height:"100%",fill:`url(#${w})`})]})}Zx.displayName="Background";var Gx=(0,D.memo)(Zx);function NA(){return(0,O.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",children:(0,O.jsx)("path",{d:"M32 18.133H18.133V32h-4.266V18.133H0v-4.266h13.867V0h4.266v13.867H32z"})})}function MA(){return(0,O.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 5",children:(0,O.jsx)("path",{d:"M0 0h32v4.2H0z"})})}function zA(){return(0,O.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 30",children:(0,O.jsx)("path",{d:"M3.692 4.63c0-.53.4-.938.939-.938h5.215V0H4.708C2.13 0 0 2.054 0 4.63v5.216h3.692V4.631zM27.354 0h-5.2v3.692h5.17c.53 0 .984.4.984.939v5.215H32V4.631A4.624 4.624 0 0027.354 0zm.954 24.83c0 .532-.4.94-.939.94h-5.215v3.768h5.215c2.577 0 4.631-2.13 4.631-4.707v-5.139h-3.692v5.139zm-23.677.94c-.531 0-.939-.4-.939-.94v-5.138H0v5.139c0 2.577 2.13 4.707 4.708 4.707h5.138V25.77H4.631z"})})}function AA(){return(0,O.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 25 32",children:(0,O.jsx)("path",{d:"M21.333 10.667H19.81V7.619C19.81 3.429 16.38 0 12.19 0 8 0 4.571 3.429 4.571 7.619v3.048H3.048A3.056 3.056 0 000 13.714v15.238A3.056 3.056 0 003.048 32h18.285a3.056 3.056 0 003.048-3.048V13.714a3.056 3.056 0 00-3.048-3.047zM12.19 24.533a3.056 3.056 0 01-3.047-3.047 3.056 3.056 0 013.047-3.048 3.056 3.056 0 013.048 3.048 3.056 3.056 0 01-3.048 3.047zm4.724-13.866H7.467V7.619c0-2.59 2.133-4.724 4.723-4.724 2.591 0 4.724 2.133 4.724 4.724v3.048z"})})}function CA(){return(0,O.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 25 32",children:(0,O.jsx)("path",{d:"M21.333 10.667H19.81V7.619C19.81 3.429 16.38 0 12.19 0c-4.114 1.828-1.37 2.133.305 2.438 1.676.305 4.42 2.59 4.42 5.181v3.048H3.047A3.056 3.056 0 000 13.714v15.238A3.056 3.056 0 003.048 32h18.285a3.056 3.056 0 003.048-3.048V13.714a3.056 3.056 0 00-3.048-3.047zM12.19 24.533a3.056 3.056 0 01-3.047-3.047 3.056 3.056 0 013.047-3.048 3.056 3.056 0 013.048 3.048 3.056 3.056 0 01-3.048 3.047z"})})}function Cc({children:t,className:e,...n}){return(0,O.jsx)("button",{type:"button",className:Tt(["react-flow__controls-button",e]),...n,children:t})}var TA=t=>({isInteractive:t.nodesDraggable||t.nodesConnectable||t.elementsSelectable,minZoomReached:t.transform[2]<=t.minZoom,maxZoomReached:t.transform[2]>=t.maxZoom,ariaLabelConfig:t.ariaLabelConfig});function Qx({style:t,showZoom:e=!0,showFitView:n=!0,showInteractive:o=!0,fitViewOptions:a,onZoomIn:l,onZoomOut:i,onFitView:r,onInteractiveChange:u,className:s,children:c,position:d="bottom-left",orientation:f="vertical","aria-label":p}){let y=zt(),{isInteractive:b,minZoomReached:x,maxZoomReached:g,ariaLabelConfig:m}=ut(TA,Et),{zoomIn:h,zoomOut:v,fitView:_}=Oh(),E=()=>{h(),l?.()},w=()=>{v(),i?.()},N=()=>{_(a),r?.()},M=()=>{y.setState({nodesDraggable:!b,nodesConnectable:!b,elementsSelectable:!b}),u?.(!b)};return(0,O.jsxs)(Dc,{className:Tt(["react-flow__controls",f==="horizontal"?"horizontal":"vertical",s]),position:d,style:t,"data-testid":"rf__controls","aria-label":p??m["controls.ariaLabel"],children:[e&&(0,O.jsxs)(O.Fragment,{children:[(0,O.jsx)(Cc,{onClick:E,className:"react-flow__controls-zoomin",title:m["controls.zoomIn.ariaLabel"],"aria-label":m["controls.zoomIn.ariaLabel"],disabled:g,children:(0,O.jsx)(NA,{})}),(0,O.jsx)(Cc,{onClick:w,className:"react-flow__controls-zoomout",title:m["controls.zoomOut.ariaLabel"],"aria-label":m["controls.zoomOut.ariaLabel"],disabled:x,children:(0,O.jsx)(MA,{})})]}),n&&(0,O.jsx)(Cc,{className:"react-flow__controls-fitview",onClick:N,title:m["controls.fitView.ariaLabel"],"aria-label":m["controls.fitView.ariaLabel"],children:(0,O.jsx)(zA,{})}),o&&(0,O.jsx)(Cc,{className:"react-flow__controls-interactive",onClick:M,title:m["controls.interactive.ariaLabel"],"aria-label":m["controls.interactive.ariaLabel"],children:b?(0,O.jsx)(CA,{}):(0,O.jsx)(AA,{})}),c]})}Qx.displayName="Controls";var jx=(0,D.memo)(Qx);function OA({id:t,x:e,y:n,width:o,height:a,style:l,color:i,strokeColor:r,strokeWidth:u,className:s,borderRadius:c,shapeRendering:d,selected:f,onClick:p}){let{background:y,backgroundColor:b}=l||{},x=i||y||b;return(0,O.jsx)("rect",{className:Tt(["react-flow__minimap-node",{selected:f},s]),x:e,y:n,rx:c,ry:c,width:o,height:a,style:{fill:x,stroke:r,strokeWidth:u},shapeRendering:d,onClick:p?g=>p(g,t):void 0})}var DA=(0,D.memo)(OA),HA=t=>t.nodes.map(e=>e.id),Ch=t=>t instanceof Function?t:()=>t;function RA({nodeStrokeColor:t,nodeColor:e,nodeClassName:n="",nodeBorderRadius:o=5,nodeStrokeWidth:a,nodeComponent:l=DA,onClick:i}){let r=ut(HA,Et),u=Ch(e),s=Ch(t),c=Ch(n),d=typeof window>"u"||window.chrome?"crispEdges":"geometricPrecision";return(0,O.jsx)(O.Fragment,{children:r.map(f=>(0,O.jsx)(kA,{id:f,nodeColorFunc:u,nodeStrokeColorFunc:s,nodeClassNameFunc:c,nodeBorderRadius:o,nodeStrokeWidth:a,NodeComponent:l,onClick:i,shapeRendering:d},f))})}function BA({id:t,nodeColorFunc:e,nodeStrokeColorFunc:n,nodeClassNameFunc:o,nodeBorderRadius:a,nodeStrokeWidth:l,shapeRendering:i,NodeComponent:r,onClick:u}){let{node:s,x:c,y:d,width:f,height:p}=ut(y=>{let b=y.nodeLookup.get(t);if(!b)return{node:void 0,x:0,y:0,width:0,height:0};let x=b.internals.userNode,{x:g,y:m}=b.internals.positionAbsolute,{width:h,height:v}=un(x);return{node:x,x:g,y:m,width:h,height:v}},Et);return!s||s.hidden||!ph(s)?null:(0,O.jsx)(r,{x:c,y:d,width:f,height:p,style:s.style,selected:!!s.selected,className:o(s),color:e(s),borderRadius:a,strokeColor:n(s),strokeWidth:l,shapeRendering:i,onClick:u,id:s.id})}var kA=(0,D.memo)(BA),LA=(0,D.memo)(RA),UA=200,YA=150,VA=t=>!t.hidden,qA=t=>{let e={x:-t.transform[0]/t.transform[2],y:-t.transform[1]/t.transform[2],width:t.width/t.transform[2],height:t.height/t.transform[2]};return{viewBB:e,boundingRect:t.nodeLookup.size>0?fh(yl(t.nodeLookup,{filter:VA}),e):e,rfId:t.rfId,panZoom:t.panZoom,translateExtent:t.translateExtent,flowWidth:t.width,flowHeight:t.height,ariaLabelConfig:t.ariaLabelConfig}},XA="react-flow__minimap-desc";function Kx({style:t,className:e,nodeStrokeColor:n,nodeColor:o,nodeClassName:a="",nodeBorderRadius:l=5,nodeStrokeWidth:i,nodeComponent:r,bgColor:u,maskColor:s,maskStrokeColor:c,maskStrokeWidth:d,position:f="bottom-right",onClick:p,onNodeClick:y,pannable:b=!1,zoomable:x=!1,ariaLabel:g,inversePan:m,zoomStep:h=1,offsetScale:v=5}){let _=zt(),E=(0,D.useRef)(null),{boundingRect:w,viewBB:N,rfId:M,panZoom:R,translateExtent:C,flowWidth:k,flowHeight:V,ariaLabelConfig:S}=ut(qA,Et),A=t?.width??UA,z=t?.height??YA,T=w.width/A,B=w.height/z,H=Math.max(T,B),X=H*A,Z=H*z,q=v*H,K=w.x-(X-w.width)/2-q,j=w.y-(Z-w.height)/2-q,I=X+q*2,ot=Z+q*2,J=`${XA}-${M}`,U=(0,D.useRef)(0),Q=(0,D.useRef)();U.current=H,(0,D.useEffect)(()=>{if(E.current&&R)return Q.current=Sb({domNode:E.current,panZoom:R,getTransform:()=>_.getState().transform,getViewScale:()=>U.current}),()=>{Q.current?.destroy()}},[R]),(0,D.useEffect)(()=>{Q.current?.update({translateExtent:C,width:k,height:V,inversePan:m,pannable:b,zoomStep:h,zoomable:x})},[b,x,m,h,C,k,V]);let nt=p?W=>{let[ct,dt]=Q.current?.pointer(W)||[0,0];p(W,{x:ct,y:dt})}:void 0,tt=y?(0,D.useCallback)((W,ct)=>{let dt=_.getState().nodeLookup.get(ct).internals.userNode;y(W,dt)},[]):void 0,$=g??S["minimap.ariaLabel"];return(0,O.jsx)(Dc,{position:f,style:{...t,"--xy-minimap-background-color-props":typeof u=="string"?u:void 0,"--xy-minimap-mask-background-color-props":typeof s=="string"?s:void 0,"--xy-minimap-mask-stroke-color-props":typeof c=="string"?c:void 0,"--xy-minimap-mask-stroke-width-props":typeof d=="number"?d*H:void 0,"--xy-minimap-node-background-color-props":typeof o=="string"?o:void 0,"--xy-minimap-node-stroke-color-props":typeof n=="string"?n:void 0,"--xy-minimap-node-stroke-width-props":typeof i=="number"?i:void 0},className:Tt(["react-flow__minimap",e]),"data-testid":"rf__minimap",children:(0,O.jsxs)("svg",{width:A,height:z,viewBox:`${K} ${j} ${I} ${ot}`,className:"react-flow__minimap-svg",role:"img","aria-labelledby":J,ref:E,onClick:nt,children:[$&&(0,O.jsx)("title",{id:J,children:$}),(0,O.jsx)(LA,{onClick:tt,nodeColor:o,nodeStrokeColor:n,nodeBorderRadius:l,nodeClassName:a,nodeStrokeWidth:i,nodeComponent:r}),(0,O.jsx)("path",{className:"react-flow__minimap-mask",d:`M${K-q},${j-q}h${I+q*2}v${ot+q*2}h${-I-q*2}z
15
+ M${N.x},${N.y}h${N.width}v${N.height}h${-N.width}z`,fillRule:"evenodd",pointerEvents:"none"})]})})}Kx.displayName="MiniMap";var Y6=(0,D.memo)(Kx),ZA=t=>e=>t?`${Math.max(1/e.transform[2],1)}`:void 0,GA={[wo.Line]:"right",[wo.Handle]:"bottom-right"};function QA({nodeId:t,position:e,variant:n=wo.Handle,className:o,style:a=void 0,children:l,color:i,minWidth:r=10,minHeight:u=10,maxWidth:s=Number.MAX_VALUE,maxHeight:c=Number.MAX_VALUE,keepAspectRatio:d=!1,resizeDirection:f,autoScale:p=!0,shouldResize:y,onResizeStart:b,onResize:x,onResizeEnd:g}){let m=Sx(),h=typeof t=="string"?t:m,v=zt(),_=(0,D.useRef)(null),E=n===wo.Handle,w=ut((0,D.useCallback)(ZA(E&&p),[E,p]),Et),N=(0,D.useRef)(null),M=e??GA[n];(0,D.useEffect)(()=>{if(!(!_.current||!h))return N.current||(N.current=Mb({domNode:_.current,nodeId:h,getStoreItems:()=>{let{nodeLookup:C,transform:k,snapGrid:V,snapToGrid:S,nodeOrigin:A,domNode:z}=v.getState();return{nodeLookup:C,transform:k,snapGrid:V,snapToGrid:S,nodeOrigin:A,paneDomNode:z}},onChange:(C,k)=>{let{triggerNodeChanges:V,nodeLookup:S,parentLookup:A,nodeOrigin:z}=v.getState(),T=[],B={x:C.x,y:C.y},H=S.get(h);if(H&&H.expandParent&&H.parentId){let X=H.origin??z,Z=C.width??H.measured.width??0,q=C.height??H.measured.height??0,K={id:H.id,parentId:H.parentId,rect:{width:Z,height:q,...gh({x:C.x??H.position.x,y:C.y??H.position.y},{width:Z,height:q},H.parentId,S,X)}},j=Ec([K],S,A,z);T.push(...j),B.x=C.x?Math.max(X[0]*Z,C.x):void 0,B.y=C.y?Math.max(X[1]*q,C.y):void 0}if(B.x!==void 0&&B.y!==void 0){let X={id:h,type:"position",position:{...B}};T.push(X)}if(C.width!==void 0&&C.height!==void 0){let Z={id:h,type:"dimensions",resizing:!0,setAttributes:f?f==="horizontal"?"width":"height":!0,dimensions:{width:C.width,height:C.height}};T.push(Z)}for(let X of k){let Z={...X,type:"position"};T.push(Z)}V(T)},onEnd:({width:C,height:k})=>{let V={id:h,type:"dimensions",resizing:!1,dimensions:{width:C,height:k}};v.getState().triggerNodeChanges([V])}})),N.current.update({controlPosition:M,boundaries:{minWidth:r,minHeight:u,maxWidth:s,maxHeight:c},keepAspectRatio:d,resizeDirection:f,onResizeStart:b,onResize:x,onResizeEnd:g,shouldResize:y}),()=>{N.current?.destroy()}},[M,r,u,s,c,d,b,x,g,y]);let R=M.split("-");return(0,O.jsx)("div",{className:Tt(["react-flow__resize-control","nodrag",...R,n,o]),ref:_,style:{...a,scale:w,...i&&{[E?"backgroundColor":"borderColor"]:i}},children:l})}var V6=(0,D.memo)(QA);var Y=We(Bu(),1);function Rc(t){return(globalThis.__LENS_BASE__??"")+t}var Yn=Hu({sig:"",domains:[],groups:[],dataIds:[],s2s:[]}),gt=Hu({gateway:{up:!1,portsLabel:"down"},services:{},edgeLabels:{},bursts:{},keys:{},hosts:[],trustCommand:"",recent:[],tick:0,queues:{}}),Bc=t=>{navigator.clipboard?.writeText(t)},$x={},Jx="";function jA(t){let e=t.decls.filter(c=>c.host||c.default).map(c=>({project:c.project,mode:c.service?"pods":"tcp",service:c.service,host:c.host?c.host+(c.path??""):void 0,internalHost:c.service&&c.internalHost!==!1&&c.host?(typeof c.internalHost=="string"?c.internalHost:"internal."+c.host)+(c.path??""):void 0,direct:c.internalPort?`http://localhost:${c.internalPort}${c.prependPrefix??""}/`:c.port?`http://localhost:${c.port}${c.prependPrefix??""}/`:void 0,upstream:c.upstream??(c.port?"http://localhost:"+c.port:void 0),prependPrefix:c.prependPrefix,isDefault:c.default,pods:c.podNames,workers:c.workers??[]})),n=t.edges.filter(c=>c.caller).map(c=>({key:"s2s:"+c.caller+">"+c.project,caller:c.caller,project:c.project})),o=t.dataNodes.map(c=>({id:c.id,kind:c.kind,name:c.name,viaProject:c.viaProject})),a=JSON.stringify([e.map(c=>[c.project,c.host,c.pods,c.workers]),o.map(c=>c.id),n.map(c=>c.key)]);if(a!==Yn.sig){let c=new Map;for(let d of t.decls.filter(f=>f.host))c.set(d.host,[...c.get(d.host)??[],d.project]);Yn.domains=[...c.entries()].map(([d,f])=>({host:d,project:f.length===1?f[0]:f.length+" services"})),Yn.groups=e,Yn.dataIds=o,Yn.s2s=[...new Map(n.map(d=>[d.key,d])).values()],Yn.sig=a}let l=!!t.gateway&&(t.gateway.ports.length>0||(t.gateway.aliveAt??0)>Date.now()-3e4),i=t.gateway&&t.gateway.ports.length>0?t.gateway.ports.map(c=>":"+c).join(" "):l?"live":"down";gt.gateway.up!==l&&(gt.gateway.up=l),gt.gateway.portsLabel!==i&&(gt.gateway.portsLabel=i);for(let c of e){let d=t.services.find(x=>x.project===c.project),f=c.mode==="tcp"?"up":d?.state??"unknown",p=c.mode==="tcp"?"":`${c.pods.length} pod${c.pods.length===1?"":"s"}`,y=c.mode==="pods"?`service "${c.service}" \xB7 ${f}${d?.lastColdStartMs?` \xB7 cold ${d.lastColdStartMs}ms`:""}`:c.upstream??"",b=gt.services[c.project];(!b||b.state!==f||b.podsLabel!==p||b.meta!==y)&&(gt.services[c.project]={state:f,podsLabel:p,meta:y})}let r={},u=(c,d)=>{gt.edgeLabels[c]!==d&&(gt.edgeLabels[c]=d)},s=(c,d)=>{r[c]=d;let f=d-($x[c]??d);f>0&&(gt.bursts[c]={n:Math.min(5,f),seq:(gt.bursts[c]?.seq??0)+1,until:Date.now()+3200})};for(let c of t.decls.filter(d=>d.host)){let d=t.edges.filter(y=>y.host===c.host&&!y.caller),f=d.reduce((y,b)=>y+b.count,0),p=d[0];u("e:"+c.host,p?`${f} req \xB7 ${p.avgMs}ms${p.errors?" \xB7 "+p.errors+" err":""}`:""),s("e:"+c.host,f)}for(let c of e){let d=t.edges.filter(f=>f.project===c.project&&!f.caller).reduce((f,p)=>f+p.count,0);s("e:gw>"+c.project,d),u("e:gw>"+c.project,c.isDefault&&!c.host?"(default)":"")}for(let c of t.edges.filter(d=>d.caller)){let d="s2s:"+c.caller+">"+c.project;u(d,`${c.caller} \u2192 ${c.project} \xB7 ${c.count} req \xB7 ${c.avgMs}ms`),s(d,c.count)}for(let c of t.dataNodes)if(u("e:data:"+c.id,c.count+" ops"),s("e:data:"+c.id,c.count),c.counts){let d=["active","waiting","completed","failed","delayed"].map(b=>[b,c.counts[b]??0]).filter(([,b])=>b>0||!0),f=(c.recent??[]).slice(0,5),p=gt.queues[c.id],y=JSON.stringify([d,f.map(b=>b.id+b.state)]);(!p||JSON.stringify([p.chips,p.recent.map(b=>b.id+b.state)])!==y)&&(gt.queues[c.id]={chips:d,recent:f})}Object.assign($x,r),gt.keys=t.serviceKeys,gt.hosts=t.hostsSetup,gt.trustCommand=t.trustCommand,gt.recent=t.recent.slice(0,10)}function Ix(t){let e=t.replace(/"at":\d+,/,"");e!==Jx&&(Jx=e,jA(JSON.parse(t)))}function KA(){setInterval(()=>{let n=Date.now();gt.tick=n;for(let o of Object.keys(gt.bursts))gt.bursts[o].until<n&&delete gt.bursts[o]},1e3);let t,e=()=>{t||(t=setInterval(()=>{fetch(Rc("/api/cluster")).then(n=>n.text()).then(Ix).catch(()=>{})},2e3))};try{let n=new EventSource(Rc("/api/cluster/stream")),o=a=>Ix(String(a.data));n.addEventListener("snapshot",o),n.addEventListener("update",o),n.onerror=()=>e(),n.onopen=()=>{t&&(clearInterval(t),t=void 0)}}catch{e()}}function $A({data:t}){let e=t;return(0,Y.jsxs)("div",{className:"node domain",children:[(0,Y.jsx)("a",{className:"n-title link",href:"https://"+e.host,target:"_blank",rel:"noreferrer",children:e.host}),(0,Y.jsx)("div",{className:"n-sub",children:"public"}),(0,Y.jsx)($e,{type:"source",position:G.Bottom})]})}function JA(){let t=Ue(gt.gateway);return(0,Y.jsxs)("div",{className:"node gw "+(t.up?"up":"down"),children:[(0,Y.jsx)("div",{className:"n-title",children:"gateway"}),(0,Y.jsxs)("div",{className:"n-sub",children:[t.portsLabel," \xB7 https \xB7 round-robin"]}),(0,Y.jsx)($e,{type:"target",position:G.Top}),(0,Y.jsx)($e,{type:"source",position:G.Bottom})]})}function IA({data:t}){let e=t,n=Ue(gt.services),o=Ue(gt.keys);if(e.net)return(0,Y.jsx)("div",{className:"grp-inner",children:(0,Y.jsxs)("div",{className:"grp-head",children:[(0,Y.jsx)("span",{className:"n-title",children:"network"}),(0,Y.jsx)("span",{className:"n-sub",children:" public domains \u2192 gateway"})]})});let a=n[e.project]??{state:"unknown",podsLabel:"",meta:""};return(0,Y.jsxs)("div",{className:"grp-inner "+a.state,children:[(0,Y.jsxs)("div",{className:"grp-head",children:[(0,Y.jsx)("span",{className:"n-title",children:e.project}),(0,Y.jsxs)("span",{className:"n-sub",children:[" ",a.meta,a.podsLabel?" \xB7 "+a.podsLabel:""]}),e.host?(0,Y.jsxs)("div",{className:"grp-urls",children:[(0,Y.jsxs)("span",{className:"url",title:"click to copy",onClick:()=>Bc("https://"+e.host),children:["https://",e.host," \u29C9"]}),e.internalHost?(0,Y.jsxs)("span",{className:"url int",title:"copy internal curl (x-api-key via gateway)",onClick:()=>Bc(`curl -k -H "x-api-key: ${o[e.project]??"<key>"}" https://${e.internalHost}/`),children:[e.internalHost," \u{1F511}\u29C9"]}):null]}):null]}),(0,Y.jsx)($e,{type:"target",position:G.Top}),(0,Y.jsx)($e,{type:"source",position:G.Bottom})]})}function WA({data:t}){let e=t;return e.empty?(0,Y.jsxs)("div",{className:"node pod empty",children:[(0,Y.jsx)("div",{className:"n-title muted",children:"0 pods"}),(0,Y.jsx)("div",{className:"n-sub",children:"first request cold-starts"})]}):(0,Y.jsxs)("div",{className:"node pod",children:[(0,Y.jsxs)("div",{className:"n-title",children:[e.service," \xB7 ",e.pod]}),(0,Y.jsxs)("div",{className:"n-links",children:[e.host?(0,Y.jsx)("a",{className:"link",href:"https://"+e.host,target:"_blank",rel:"noreferrer",children:"gateway \u2197"}):null,e.direct?(0,Y.jsx)("a",{className:"link",href:e.direct,target:"_blank",rel:"noreferrer",children:"direct \u2197"}):null]}),(0,Y.jsx)("div",{className:"n-sub",children:e.direct?e.direct.replace("http://",""):"unix sock"})]})}function FA({data:t}){return(0,Y.jsxs)("div",{className:"node worker",children:[(0,Y.jsxs)("div",{className:"n-title",children:["\u2699 ",t.name]}),(0,Y.jsx)("div",{className:"n-sub",children:"worker"})]})}function PA({data:t}){let e=t,n=Ue(gt.edgeLabels)["e:data:"+e.id]??"",o=Ue(gt.queues)[e.id],a=e.kind==="queue"?"\u2630 ":e.kind==="redis"?"\u26A1 ":e.kind==="db"?"\u{1F6E2} ":e.kind==="external"?"\u{1F310} ":e.kind==="fs"?"\u{1F4C1} ":e.kind==="exec"?"\u2699\uFE0F ":"\u25C7 ";return(0,Y.jsxs)("div",{className:"node data "+e.kind,children:[(0,Y.jsxs)("div",{className:"n-title",children:[a,e.name]}),(0,Y.jsxs)("div",{className:"n-sub",children:[e.kind," \xB7 ",n," \xB7 via ",e.viaProject]}),o?(0,Y.jsxs)(Y.Fragment,{children:[(0,Y.jsx)("div",{className:"q-chips",children:o.chips.map(([l,i])=>(0,Y.jsxs)("span",{className:"q-chip "+l+(i>0?" nonzero":""),children:[i," ",l]},l))}),(0,Y.jsx)("div",{className:"q-jobs",children:o.recent.length===0?(0,Y.jsx)("div",{className:"n-sub",children:"(no jobs yet)"}):o.recent.map(l=>(0,Y.jsxs)("div",{className:"q-job "+l.state,children:[(0,Y.jsxs)("span",{className:"q-id",children:["#",l.id]})," ",l.name,l.to?" \u2192 "+l.to:""," ",(0,Y.jsx)("span",{className:"q-state "+l.state,children:l.state})]},l.id))})]}):null,(0,Y.jsx)($e,{type:"target",position:G.Top})]})}var tC={domain:$A,gw:JA,grp:IA,pod:WA,worker:FA,dataNode:PA};function eC(t){let{id:e,sourceX:n,sourceY:o,targetX:a,targetY:l,sourcePosition:i,targetPosition:r,data:u}=t,[s,c,d]=da({sourceX:n,sourceY:o,targetX:a,targetY:l,sourcePosition:i,targetPosition:r,borderRadius:14}),f=!!u?.internal,p=Number(u?.hop??0),y=Ue(gt.edgeLabels)[e]??"",b=Ue(gt.bursts)[e],x=Ue(gt).tick,g=b&&b.until>x?b:void 0;return(0,Y.jsxs)(Y.Fragment,{children:[(0,Y.jsx)(wl,{id:e,path:s,className:f?"edge-internal":void 0}),g&&g.n>0?Array.from({length:g.n}).map((m,h)=>{let _=p*1.25+h*.22;return(0,Y.jsxs)("circle",{r:"2.8",opacity:"0",className:"traffic-dot"+(f?" internal":""),children:[(0,Y.jsx)("animateMotion",{dur:1.25+"s",begin:_+"s",repeatCount:"1",fill:"freeze",path:s}),(0,Y.jsx)("animate",{attributeName:"opacity",values:"0;1;1;0",keyTimes:"0;0.05;0.85;1",dur:1.25+"s",begin:_+"s",repeatCount:"1",fill:"freeze"})]},g.seq+"-"+h)}):null,y?(0,Y.jsx)(Xx,{children:(0,Y.jsx)("div",{className:"edge-pill",style:{transform:`translate(-50%, -50%) translate(${c}px,${d+(e.split("").reduce((m,h)=>m+h.charCodeAt(0),0)%3-1)*16}px)`},children:y})}):null]})}var nC={traffic:eC},oC={type:"traffic"},No=168;function aC(t){let e=[],n=[];e.push({id:"net",type:"grp",position:{x:-20,y:-34},draggable:!1,selectable:!1,data:{net:!0},className:"node grp net",style:{width:Math.max(1,t.domains.length)*248+26,height:150}}),t.domains.forEach((u,s)=>{e.push({id:"host:"+u.host,type:"domain",parentId:"net",extent:"parent",position:{x:14+s*248,y:58},data:{host:u.host},style:{width:230}}),n.push({id:"e:"+u.host,source:"host:"+u.host,target:"gateway",data:{hop:0}})});let a=Math.max(1,t.domains.length)*248/2-110;e.push({id:"gateway",type:"gw",position:{x:a,y:170},data:{},style:{width:220}});let l=0,i=120;for(let u of t.groups){let s=Math.max(1,u.pods.length)+u.workers.length,c=Math.max(430,24+s*(No+14)),d=196;i=Math.max(i,d);let f="svc:"+u.project;e.push({id:f,type:"grp",position:{x:l,y:332},data:{project:u.project,host:u.host,internalHost:u.internalHost},className:"node grp",style:{width:c,height:d}}),n.push({id:"e:gw>"+u.project,source:"gateway",target:f,data:{hop:1}});let p=12;if(u.mode==="pods"){u.pods.length===0&&(e.push({id:`pod:${u.service}:none`,type:"pod",parentId:f,extent:"parent",position:{x:p,y:96},data:{empty:!0},style:{width:No}}),p+=No+14);for(let y of u.pods)e.push({id:`pod:${u.service}:${y}`,type:"pod",parentId:f,extent:"parent",position:{x:p,y:96},data:{service:u.service,pod:y,host:u.host,direct:u.direct},style:{width:No}}),p+=No+14;for(let y of u.workers)e.push({id:`wrk:${u.service}:${y}`,type:"worker",parentId:f,extent:"parent",position:{x:p,y:96},data:{name:y},style:{width:No}}),p+=No+14}else e.push({id:"tcp:"+u.project,type:"pod",parentId:f,extent:"parent",position:{x:p,y:96},data:{service:u.project,pod:"dev server",host:u.host,direct:u.upstream},style:{width:No+30}});l+=c+36}for(let u of t.s2s)n.push({id:u.key,source:"svc:"+u.caller,target:"svc:"+u.project,data:{internal:!0,hop:1}});let r=332+i+110;return t.dataIds.forEach((u,s)=>{e.push({id:"data:"+u.id,type:"dataNode",position:{x:s*280,y:r},data:{...u},style:{width:u.kind==="queue"?260:200}}),n.push({id:"e:data:"+u.id,source:"svc:"+u.viaProject,target:"data:"+u.id,data:{hop:2}})}),{nodes:e,edges:n}}function lC(){let t=Ue(Yn),e=Ue(gt),n=e.hosts.filter(o=>!o.v4||!o.v6);return(0,Y.jsxs)("aside",{className:"panel",children:[(0,Y.jsx)("h3",{children:"Quick links"}),(0,Y.jsxs)("ul",{children:[t.domains.map(o=>(0,Y.jsxs)("li",{children:[(0,Y.jsxs)("a",{href:"https://"+o.host,target:"_blank",rel:"noreferrer",children:["https://",o.host]}),(0,Y.jsxs)("span",{className:"muted",children:[" \u2192 ",o.project]})]},o.host)),(0,Y.jsx)("li",{children:(0,Y.jsx)("a",{href:Rc("/flows"),children:"lens \xB7 flows"})}),(0,Y.jsx)("li",{children:(0,Y.jsx)("a",{href:Rc("/resources"),children:"lens \xB7 resources"})})]}),(0,Y.jsx)("h3",{children:"Hostnames setup"}),(0,Y.jsxs)("table",{children:[(0,Y.jsx)("thead",{children:(0,Y.jsxs)("tr",{children:[(0,Y.jsx)("th",{children:"host"}),(0,Y.jsx)("th",{children:"v4"}),(0,Y.jsx)("th",{children:"v6"})]})}),(0,Y.jsx)("tbody",{children:e.hosts.map(o=>(0,Y.jsxs)("tr",{children:[(0,Y.jsx)("td",{children:o.host}),(0,Y.jsx)("td",{className:o.v4?"ok":"bad",children:o.v4?"\u2713":"\u2717"}),(0,Y.jsx)("td",{className:o.v6?"ok":"bad",children:o.v6?"\u2713":"\u2717"})]},o.host))})]}),n.length>0?(0,Y.jsxs)("div",{className:"setup",children:[(0,Y.jsxs)("p",{children:[n.length," host entr",n.length===1?"y":"ies"," missing \u2014 run in your terminal:"]}),(0,Y.jsx)("code",{onClick:()=>Bc(e.trustCommand),title:"click to copy",children:e.trustCommand})]}):(0,Y.jsx)("p",{className:"muted",children:"all hostnames resolve locally \u2713"}),(0,Y.jsx)("h3",{children:"Service keys"}),(0,Y.jsx)("ul",{children:Object.entries(e.keys).map(([o,a])=>(0,Y.jsxs)("li",{children:[(0,Y.jsx)("span",{children:o})," ",(0,Y.jsxs)("code",{className:"key",title:"click to copy",onClick:()=>Bc(a),children:[a.slice(0,10),"\u2026 \u29C9"]})]},o))}),(0,Y.jsx)("p",{className:"muted",children:"public \u2192 gateway injects x-internal-token \xB7 internal.* requires x-api-key"}),(0,Y.jsx)("h3",{children:"Recent"}),(0,Y.jsx)("ul",{className:"recent",children:e.recent.map((o,a)=>(0,Y.jsxs)("li",{children:[(0,Y.jsx)("span",{className:"muted",children:new Date(o.at).toLocaleTimeString()})," ",o.title]},a))})]})}function iC(){let t=Ue(Yn).sig,e=(0,pa.useRef)(null),n=(0,pa.useMemo)(()=>aC(Yn),[t]);return(0,pa.useEffect)(()=>{requestAnimationFrame(()=>e.current?.fitView({padding:.16,duration:300}))},[t]),(0,Y.jsx)("div",{className:"canvas",children:(0,Y.jsxs)(qx,{nodes:n.nodes,edges:n.edges,nodeTypes:tC,edgeTypes:nC,defaultEdgeOptions:oC,onInit:o=>{e.current=o,o.fitView({padding:.16})},proOptions:{hideAttribution:!0},colorMode:"dark",minZoom:.3,children:[(0,Y.jsx)(Gx,{gap:24}),(0,Y.jsx)(jx,{showInteractive:!1})]})})}function rC(){return(0,pa.useEffect)(()=>{KA()},[]),(0,Y.jsxs)("div",{className:"cluster-layout",children:[(0,Y.jsx)(lC,{}),(0,Y.jsx)(iC,{})]})}var Wx=document.getElementById("cluster-root");Wx&&(0,Fx.createRoot)(Wx).render((0,Y.jsx)(rC,{}));})();
16
16
  /*! Bundled license information:
17
17
 
18
18
  react/cjs/react.production.js: