@task-shepherd/agent 1.0.45 → 1.0.49

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.
@@ -0,0 +1,69 @@
1
+ function fh(e,t){for(var n=0;n<t.length;n++){const r=t[n];if(typeof r!="string"&&!Array.isArray(r)){for(const s in r)if(s!=="default"&&!(s in e)){const i=Object.getOwnPropertyDescriptor(r,s);i&&Object.defineProperty(e,s,i.get?i:{enumerable:!0,get:()=>r[s]})}}}return Object.freeze(Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}))}(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const s of document.querySelectorAll('link[rel="modulepreload"]'))r(s);new MutationObserver(s=>{for(const i of s)if(i.type==="childList")for(const o of i.addedNodes)o.tagName==="LINK"&&o.rel==="modulepreload"&&r(o)}).observe(document,{childList:!0,subtree:!0});function n(s){const i={};return s.integrity&&(i.integrity=s.integrity),s.referrerPolicy&&(i.referrerPolicy=s.referrerPolicy),s.crossOrigin==="use-credentials"?i.credentials="include":s.crossOrigin==="anonymous"?i.credentials="omit":i.credentials="same-origin",i}function r(s){if(s.ep)return;s.ep=!0;const i=n(s);fetch(s.href,i)}})();function br(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Kc={exports:{}},Vi={},Gc={exports:{}},te={};/**
2
+ * @license React
3
+ * react.production.min.js
4
+ *
5
+ * Copyright (c) Facebook, Inc. and its affiliates.
6
+ *
7
+ * This source code is licensed under the MIT license found in the
8
+ * LICENSE file in the root directory of this source tree.
9
+ */var ks=Symbol.for("react.element"),ph=Symbol.for("react.portal"),hh=Symbol.for("react.fragment"),mh=Symbol.for("react.strict_mode"),gh=Symbol.for("react.profiler"),yh=Symbol.for("react.provider"),vh=Symbol.for("react.context"),xh=Symbol.for("react.forward_ref"),wh=Symbol.for("react.suspense"),jh=Symbol.for("react.memo"),bh=Symbol.for("react.lazy"),du=Symbol.iterator;function Nh(e){return e===null||typeof e!="object"?null:(e=du&&e[du]||e["@@iterator"],typeof e=="function"?e:null)}var Yc={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},Jc=Object.assign,Xc={};function Nr(e,t,n){this.props=e,this.context=t,this.refs=Xc,this.updater=n||Yc}Nr.prototype.isReactComponent={};Nr.prototype.setState=function(e,t){if(typeof e!="object"&&typeof e!="function"&&e!=null)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,e,t,"setState")};Nr.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function Zc(){}Zc.prototype=Nr.prototype;function ol(e,t,n){this.props=e,this.context=t,this.refs=Xc,this.updater=n||Yc}var ll=ol.prototype=new Zc;ll.constructor=ol;Jc(ll,Nr.prototype);ll.isPureReactComponent=!0;var fu=Array.isArray,ed=Object.prototype.hasOwnProperty,ul={current:null},td={key:!0,ref:!0,__self:!0,__source:!0};function nd(e,t,n){var r,s={},i=null,o=null;if(t!=null)for(r in t.ref!==void 0&&(o=t.ref),t.key!==void 0&&(i=""+t.key),t)ed.call(t,r)&&!td.hasOwnProperty(r)&&(s[r]=t[r]);var l=arguments.length-2;if(l===1)s.children=n;else if(1<l){for(var u=Array(l),c=0;c<l;c++)u[c]=arguments[c+2];s.children=u}if(e&&e.defaultProps)for(r in l=e.defaultProps,l)s[r]===void 0&&(s[r]=l[r]);return{$$typeof:ks,type:e,key:i,ref:o,props:s,_owner:ul.current}}function kh(e,t){return{$$typeof:ks,type:e.type,key:t,ref:e.ref,props:e.props,_owner:e._owner}}function cl(e){return typeof e=="object"&&e!==null&&e.$$typeof===ks}function Sh(e){var t={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,function(n){return t[n]})}var pu=/\/+/g;function ba(e,t){return typeof e=="object"&&e!==null&&e.key!=null?Sh(""+e.key):t.toString(36)}function ti(e,t,n,r,s){var i=typeof e;(i==="undefined"||i==="boolean")&&(e=null);var o=!1;if(e===null)o=!0;else switch(i){case"string":case"number":o=!0;break;case"object":switch(e.$$typeof){case ks:case ph:o=!0}}if(o)return o=e,s=s(o),e=r===""?"."+ba(o,0):r,fu(s)?(n="",e!=null&&(n=e.replace(pu,"$&/")+"/"),ti(s,t,n,"",function(c){return c})):s!=null&&(cl(s)&&(s=kh(s,n+(!s.key||o&&o.key===s.key?"":(""+s.key).replace(pu,"$&/")+"/")+e)),t.push(s)),1;if(o=0,r=r===""?".":r+":",fu(e))for(var l=0;l<e.length;l++){i=e[l];var u=r+ba(i,l);o+=ti(i,t,n,u,s)}else if(u=Nh(e),typeof u=="function")for(e=u.call(e),l=0;!(i=e.next()).done;)i=i.value,u=r+ba(i,l++),o+=ti(i,t,n,u,s);else if(i==="object")throw t=String(e),Error("Objects are not valid as a React child (found: "+(t==="[object Object]"?"object with keys {"+Object.keys(e).join(", ")+"}":t)+"). If you meant to render a collection of children, use an array instead.");return o}function Ms(e,t,n){if(e==null)return e;var r=[],s=0;return ti(e,r,"","",function(i){return t.call(n,i,s++)}),r}function Ch(e){if(e._status===-1){var t=e._result;t=t(),t.then(function(n){(e._status===0||e._status===-1)&&(e._status=1,e._result=n)},function(n){(e._status===0||e._status===-1)&&(e._status=2,e._result=n)}),e._status===-1&&(e._status=0,e._result=t)}if(e._status===1)return e._result.default;throw e._result}var Ve={current:null},ni={transition:null},Eh={ReactCurrentDispatcher:Ve,ReactCurrentBatchConfig:ni,ReactCurrentOwner:ul};function rd(){throw Error("act(...) is not supported in production builds of React.")}te.Children={map:Ms,forEach:function(e,t,n){Ms(e,function(){t.apply(this,arguments)},n)},count:function(e){var t=0;return Ms(e,function(){t++}),t},toArray:function(e){return Ms(e,function(t){return t})||[]},only:function(e){if(!cl(e))throw Error("React.Children.only expected to receive a single React element child.");return e}};te.Component=Nr;te.Fragment=hh;te.Profiler=gh;te.PureComponent=ol;te.StrictMode=mh;te.Suspense=wh;te.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=Eh;te.act=rd;te.cloneElement=function(e,t,n){if(e==null)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+e+".");var r=Jc({},e.props),s=e.key,i=e.ref,o=e._owner;if(t!=null){if(t.ref!==void 0&&(i=t.ref,o=ul.current),t.key!==void 0&&(s=""+t.key),e.type&&e.type.defaultProps)var l=e.type.defaultProps;for(u in t)ed.call(t,u)&&!td.hasOwnProperty(u)&&(r[u]=t[u]===void 0&&l!==void 0?l[u]:t[u])}var u=arguments.length-2;if(u===1)r.children=n;else if(1<u){l=Array(u);for(var c=0;c<u;c++)l[c]=arguments[c+2];r.children=l}return{$$typeof:ks,type:e.type,key:s,ref:i,props:r,_owner:o}};te.createContext=function(e){return e={$$typeof:vh,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null},e.Provider={$$typeof:yh,_context:e},e.Consumer=e};te.createElement=nd;te.createFactory=function(e){var t=nd.bind(null,e);return t.type=e,t};te.createRef=function(){return{current:null}};te.forwardRef=function(e){return{$$typeof:xh,render:e}};te.isValidElement=cl;te.lazy=function(e){return{$$typeof:bh,_payload:{_status:-1,_result:e},_init:Ch}};te.memo=function(e,t){return{$$typeof:jh,type:e,compare:t===void 0?null:t}};te.startTransition=function(e){var t=ni.transition;ni.transition={};try{e()}finally{ni.transition=t}};te.unstable_act=rd;te.useCallback=function(e,t){return Ve.current.useCallback(e,t)};te.useContext=function(e){return Ve.current.useContext(e)};te.useDebugValue=function(){};te.useDeferredValue=function(e){return Ve.current.useDeferredValue(e)};te.useEffect=function(e,t){return Ve.current.useEffect(e,t)};te.useId=function(){return Ve.current.useId()};te.useImperativeHandle=function(e,t,n){return Ve.current.useImperativeHandle(e,t,n)};te.useInsertionEffect=function(e,t){return Ve.current.useInsertionEffect(e,t)};te.useLayoutEffect=function(e,t){return Ve.current.useLayoutEffect(e,t)};te.useMemo=function(e,t){return Ve.current.useMemo(e,t)};te.useReducer=function(e,t,n){return Ve.current.useReducer(e,t,n)};te.useRef=function(e){return Ve.current.useRef(e)};te.useState=function(e){return Ve.current.useState(e)};te.useSyncExternalStore=function(e,t,n){return Ve.current.useSyncExternalStore(e,t,n)};te.useTransition=function(){return Ve.current.useTransition()};te.version="18.3.1";Gc.exports=te;var N=Gc.exports;const _=br(N),Ph=fh({__proto__:null,default:_},[N]);/**
10
+ * @license React
11
+ * react-jsx-runtime.production.min.js
12
+ *
13
+ * Copyright (c) Facebook, Inc. and its affiliates.
14
+ *
15
+ * This source code is licensed under the MIT license found in the
16
+ * LICENSE file in the root directory of this source tree.
17
+ */var Th=N,Oh=Symbol.for("react.element"),zh=Symbol.for("react.fragment"),Ah=Object.prototype.hasOwnProperty,Mh=Th.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,Rh={key:!0,ref:!0,__self:!0,__source:!0};function sd(e,t,n){var r,s={},i=null,o=null;n!==void 0&&(i=""+n),t.key!==void 0&&(i=""+t.key),t.ref!==void 0&&(o=t.ref);for(r in t)Ah.call(t,r)&&!Rh.hasOwnProperty(r)&&(s[r]=t[r]);if(e&&e.defaultProps)for(r in t=e.defaultProps,t)s[r]===void 0&&(s[r]=t[r]);return{$$typeof:Oh,type:e,key:i,ref:o,props:s,_owner:Mh.current}}Vi.Fragment=zh;Vi.jsx=sd;Vi.jsxs=sd;Kc.exports=Vi;var a=Kc.exports,to={},id={exports:{}},it={},ad={exports:{}},od={};/**
18
+ * @license React
19
+ * scheduler.production.min.js
20
+ *
21
+ * Copyright (c) Facebook, Inc. and its affiliates.
22
+ *
23
+ * This source code is licensed under the MIT license found in the
24
+ * LICENSE file in the root directory of this source tree.
25
+ */(function(e){function t(A,F){var U=A.length;A.push(F);e:for(;0<U;){var ee=U-1>>>1,Q=A[ee];if(0<s(Q,F))A[ee]=F,A[U]=Q,U=ee;else break e}}function n(A){return A.length===0?null:A[0]}function r(A){if(A.length===0)return null;var F=A[0],U=A.pop();if(U!==F){A[0]=U;e:for(var ee=0,Q=A.length,X=Q>>>1;ee<X;){var ue=2*(ee+1)-1,Ae=A[ue],ve=ue+1,Ge=A[ve];if(0>s(Ae,U))ve<Q&&0>s(Ge,Ae)?(A[ee]=Ge,A[ve]=U,ee=ve):(A[ee]=Ae,A[ue]=U,ee=ue);else if(ve<Q&&0>s(Ge,U))A[ee]=Ge,A[ve]=U,ee=ve;else break e}}return F}function s(A,F){var U=A.sortIndex-F.sortIndex;return U!==0?U:A.id-F.id}if(typeof performance=="object"&&typeof performance.now=="function"){var i=performance;e.unstable_now=function(){return i.now()}}else{var o=Date,l=o.now();e.unstable_now=function(){return o.now()-l}}var u=[],c=[],d=1,p=null,h=3,v=!1,x=!1,w=!1,k=typeof setTimeout=="function"?setTimeout:null,m=typeof clearTimeout=="function"?clearTimeout:null,f=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function g(A){for(var F=n(c);F!==null;){if(F.callback===null)r(c);else if(F.startTime<=A)r(c),F.sortIndex=F.expirationTime,t(u,F);else break;F=n(c)}}function b(A){if(w=!1,g(A),!x)if(n(u)!==null)x=!0,Y(E);else{var F=n(c);F!==null&&ae(b,F.startTime-A)}}function E(A,F){x=!1,w&&(w=!1,m(j),j=-1),v=!0;var U=h;try{for(g(F),p=n(u);p!==null&&(!(p.expirationTime>F)||A&&!K());){var ee=p.callback;if(typeof ee=="function"){p.callback=null,h=p.priorityLevel;var Q=ee(p.expirationTime<=F);F=e.unstable_now(),typeof Q=="function"?p.callback=Q:p===n(u)&&r(u),g(F)}else r(u);p=n(u)}if(p!==null)var X=!0;else{var ue=n(c);ue!==null&&ae(b,ue.startTime-F),X=!1}return X}finally{p=null,h=U,v=!1}}var T=!1,C=null,j=-1,R=5,M=-1;function K(){return!(e.unstable_now()-M<R)}function G(){if(C!==null){var A=e.unstable_now();M=A;var F=!0;try{F=C(!0,A)}finally{F?Ce():(T=!1,C=null)}}else T=!1}var Ce;if(typeof f=="function")Ce=function(){f(G)};else if(typeof MessageChannel<"u"){var P=new MessageChannel,q=P.port2;P.port1.onmessage=G,Ce=function(){q.postMessage(null)}}else Ce=function(){k(G,0)};function Y(A){C=A,T||(T=!0,Ce())}function ae(A,F){j=k(function(){A(e.unstable_now())},F)}e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(A){A.callback=null},e.unstable_continueExecution=function(){x||v||(x=!0,Y(E))},e.unstable_forceFrameRate=function(A){0>A||125<A?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):R=0<A?Math.floor(1e3/A):5},e.unstable_getCurrentPriorityLevel=function(){return h},e.unstable_getFirstCallbackNode=function(){return n(u)},e.unstable_next=function(A){switch(h){case 1:case 2:case 3:var F=3;break;default:F=h}var U=h;h=F;try{return A()}finally{h=U}},e.unstable_pauseExecution=function(){},e.unstable_requestPaint=function(){},e.unstable_runWithPriority=function(A,F){switch(A){case 1:case 2:case 3:case 4:case 5:break;default:A=3}var U=h;h=A;try{return F()}finally{h=U}},e.unstable_scheduleCallback=function(A,F,U){var ee=e.unstable_now();switch(typeof U=="object"&&U!==null?(U=U.delay,U=typeof U=="number"&&0<U?ee+U:ee):U=ee,A){case 1:var Q=-1;break;case 2:Q=250;break;case 5:Q=1073741823;break;case 4:Q=1e4;break;default:Q=5e3}return Q=U+Q,A={id:d++,callback:F,priorityLevel:A,startTime:U,expirationTime:Q,sortIndex:-1},U>ee?(A.sortIndex=U,t(c,A),n(u)===null&&A===n(c)&&(w?(m(j),j=-1):w=!0,ae(b,U-ee))):(A.sortIndex=Q,t(u,A),x||v||(x=!0,Y(E))),A},e.unstable_shouldYield=K,e.unstable_wrapCallback=function(A){var F=h;return function(){var U=h;h=F;try{return A.apply(this,arguments)}finally{h=U}}}})(od);ad.exports=od;var Ih=ad.exports;/**
26
+ * @license React
27
+ * react-dom.production.min.js
28
+ *
29
+ * Copyright (c) Facebook, Inc. and its affiliates.
30
+ *
31
+ * This source code is licensed under the MIT license found in the
32
+ * LICENSE file in the root directory of this source tree.
33
+ */var _h=N,st=Ih;function O(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,n=1;n<arguments.length;n++)t+="&args[]="+encodeURIComponent(arguments[n]);return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var ld=new Set,is={};function Ln(e,t){hr(e,t),hr(e+"Capture",t)}function hr(e,t){for(is[e]=t,e=0;e<t.length;e++)ld.add(t[e])}var Lt=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),no=Object.prototype.hasOwnProperty,Lh=/^[: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]*$/,hu={},mu={};function Fh(e){return no.call(mu,e)?!0:no.call(hu,e)?!1:Lh.test(e)?mu[e]=!0:(hu[e]=!0,!1)}function Dh(e,t,n,r){if(n!==null&&n.type===0)return!1;switch(typeof t){case"function":case"symbol":return!0;case"boolean":return r?!1:n!==null?!n.acceptsBooleans:(e=e.toLowerCase().slice(0,5),e!=="data-"&&e!=="aria-");default:return!1}}function $h(e,t,n,r){if(t===null||typeof t>"u"||Dh(e,t,n,r))return!0;if(r)return!1;if(n!==null)switch(n.type){case 3:return!t;case 4:return t===!1;case 5:return isNaN(t);case 6:return isNaN(t)||1>t}return!1}function Ke(e,t,n,r,s,i,o){this.acceptsBooleans=t===2||t===3||t===4,this.attributeName=r,this.attributeNamespace=s,this.mustUseProperty=n,this.propertyName=e,this.type=t,this.sanitizeURL=i,this.removeEmptyString=o}var Le={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){Le[e]=new Ke(e,0,!1,e,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];Le[t]=new Ke(t,1,!1,e[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(e){Le[e]=new Ke(e,2,!1,e.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){Le[e]=new Ke(e,2,!1,e,null,!1,!1)});"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(e){Le[e]=new Ke(e,3,!1,e.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(e){Le[e]=new Ke(e,3,!0,e,null,!1,!1)});["capture","download"].forEach(function(e){Le[e]=new Ke(e,4,!1,e,null,!1,!1)});["cols","rows","size","span"].forEach(function(e){Le[e]=new Ke(e,6,!1,e,null,!1,!1)});["rowSpan","start"].forEach(function(e){Le[e]=new Ke(e,5,!1,e.toLowerCase(),null,!1,!1)});var dl=/[\-:]([a-z])/g;function fl(e){return e[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(e){var t=e.replace(dl,fl);Le[t]=new Ke(t,1,!1,e,null,!1,!1)});"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(e){var t=e.replace(dl,fl);Le[t]=new Ke(t,1,!1,e,"http://www.w3.org/1999/xlink",!1,!1)});["xml:base","xml:lang","xml:space"].forEach(function(e){var t=e.replace(dl,fl);Le[t]=new Ke(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(e){Le[e]=new Ke(e,1,!1,e.toLowerCase(),null,!1,!1)});Le.xlinkHref=new Ke("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(e){Le[e]=new Ke(e,1,!1,e.toLowerCase(),null,!0,!0)});function pl(e,t,n,r){var s=Le.hasOwnProperty(t)?Le[t]:null;(s!==null?s.type!==0:r||!(2<t.length)||t[0]!=="o"&&t[0]!=="O"||t[1]!=="n"&&t[1]!=="N")&&($h(t,n,s,r)&&(n=null),r||s===null?Fh(t)&&(n===null?e.removeAttribute(t):e.setAttribute(t,""+n)):s.mustUseProperty?e[s.propertyName]=n===null?s.type===3?!1:"":n:(t=s.attributeName,r=s.attributeNamespace,n===null?e.removeAttribute(t):(s=s.type,n=s===3||s===4&&n===!0?"":""+n,r?e.setAttributeNS(r,t,n):e.setAttribute(t,n))))}var Ut=_h.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,Rs=Symbol.for("react.element"),Qn=Symbol.for("react.portal"),Vn=Symbol.for("react.fragment"),hl=Symbol.for("react.strict_mode"),ro=Symbol.for("react.profiler"),ud=Symbol.for("react.provider"),cd=Symbol.for("react.context"),ml=Symbol.for("react.forward_ref"),so=Symbol.for("react.suspense"),io=Symbol.for("react.suspense_list"),gl=Symbol.for("react.memo"),Vt=Symbol.for("react.lazy"),dd=Symbol.for("react.offscreen"),gu=Symbol.iterator;function Pr(e){return e===null||typeof e!="object"?null:(e=gu&&e[gu]||e["@@iterator"],typeof e=="function"?e:null)}var je=Object.assign,Na;function Wr(e){if(Na===void 0)try{throw Error()}catch(n){var t=n.stack.trim().match(/\n( *(at )?)/);Na=t&&t[1]||""}return`
34
+ `+Na+e}var ka=!1;function Sa(e,t){if(!e||ka)return"";ka=!0;var n=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{if(t)if(t=function(){throw Error()},Object.defineProperty(t.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(t,[])}catch(c){var r=c}Reflect.construct(e,[],t)}else{try{t.call()}catch(c){r=c}e.call(t.prototype)}else{try{throw Error()}catch(c){r=c}e()}}catch(c){if(c&&r&&typeof c.stack=="string"){for(var s=c.stack.split(`
35
+ `),i=r.stack.split(`
36
+ `),o=s.length-1,l=i.length-1;1<=o&&0<=l&&s[o]!==i[l];)l--;for(;1<=o&&0<=l;o--,l--)if(s[o]!==i[l]){if(o!==1||l!==1)do if(o--,l--,0>l||s[o]!==i[l]){var u=`
37
+ `+s[o].replace(" at new "," at ");return e.displayName&&u.includes("<anonymous>")&&(u=u.replace("<anonymous>",e.displayName)),u}while(1<=o&&0<=l);break}}}finally{ka=!1,Error.prepareStackTrace=n}return(e=e?e.displayName||e.name:"")?Wr(e):""}function Uh(e){switch(e.tag){case 5:return Wr(e.type);case 16:return Wr("Lazy");case 13:return Wr("Suspense");case 19:return Wr("SuspenseList");case 0:case 2:case 15:return e=Sa(e.type,!1),e;case 11:return e=Sa(e.type.render,!1),e;case 1:return e=Sa(e.type,!0),e;default:return""}}function ao(e){if(e==null)return null;if(typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case Vn:return"Fragment";case Qn:return"Portal";case ro:return"Profiler";case hl:return"StrictMode";case so:return"Suspense";case io:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case cd:return(e.displayName||"Context")+".Consumer";case ud:return(e._context.displayName||"Context")+".Provider";case ml:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case gl:return t=e.displayName||null,t!==null?t:ao(e.type)||"Memo";case Vt:t=e._payload,e=e._init;try{return ao(e(t))}catch{}}return null}function Wh(e){var t=e.type;switch(e.tag){case 24:return"Cache";case 9:return(t.displayName||"Context")+".Consumer";case 10:return(t._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return e=t.render,e=e.displayName||e.name||"",t.displayName||(e!==""?"ForwardRef("+e+")":"ForwardRef");case 7:return"Fragment";case 5:return t;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return ao(t);case 8:return t===hl?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof t=="function")return t.displayName||t.name||null;if(typeof t=="string")return t}return null}function mn(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function fd(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function Bh(e){var t=fd(e)?"checked":"value",n=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),r=""+e[t];if(!e.hasOwnProperty(t)&&typeof n<"u"&&typeof n.get=="function"&&typeof n.set=="function"){var s=n.get,i=n.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return s.call(this)},set:function(o){r=""+o,i.call(this,o)}}),Object.defineProperty(e,t,{enumerable:n.enumerable}),{getValue:function(){return r},setValue:function(o){r=""+o},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function Is(e){e._valueTracker||(e._valueTracker=Bh(e))}function pd(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r="";return e&&(r=fd(e)?e.checked?"true":"false":e.value),e=r,e!==n?(t.setValue(e),!0):!1}function yi(e){if(e=e||(typeof document<"u"?document:void 0),typeof e>"u")return null;try{return e.activeElement||e.body}catch{return e.body}}function oo(e,t){var n=t.checked;return je({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:n??e._wrapperState.initialChecked})}function yu(e,t){var n=t.defaultValue==null?"":t.defaultValue,r=t.checked!=null?t.checked:t.defaultChecked;n=mn(t.value!=null?t.value:n),e._wrapperState={initialChecked:r,initialValue:n,controlled:t.type==="checkbox"||t.type==="radio"?t.checked!=null:t.value!=null}}function hd(e,t){t=t.checked,t!=null&&pl(e,"checked",t,!1)}function lo(e,t){hd(e,t);var n=mn(t.value),r=t.type;if(n!=null)r==="number"?(n===0&&e.value===""||e.value!=n)&&(e.value=""+n):e.value!==""+n&&(e.value=""+n);else if(r==="submit"||r==="reset"){e.removeAttribute("value");return}t.hasOwnProperty("value")?uo(e,t.type,n):t.hasOwnProperty("defaultValue")&&uo(e,t.type,mn(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function vu(e,t,n){if(t.hasOwnProperty("value")||t.hasOwnProperty("defaultValue")){var r=t.type;if(!(r!=="submit"&&r!=="reset"||t.value!==void 0&&t.value!==null))return;t=""+e._wrapperState.initialValue,n||t===e.value||(e.value=t),e.defaultValue=t}n=e.name,n!==""&&(e.name=""),e.defaultChecked=!!e._wrapperState.initialChecked,n!==""&&(e.name=n)}function uo(e,t,n){(t!=="number"||yi(e.ownerDocument)!==e)&&(n==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+n&&(e.defaultValue=""+n))}var Br=Array.isArray;function ar(e,t,n,r){if(e=e.options,t){t={};for(var s=0;s<n.length;s++)t["$"+n[s]]=!0;for(n=0;n<e.length;n++)s=t.hasOwnProperty("$"+e[n].value),e[n].selected!==s&&(e[n].selected=s),s&&r&&(e[n].defaultSelected=!0)}else{for(n=""+mn(n),t=null,s=0;s<e.length;s++){if(e[s].value===n){e[s].selected=!0,r&&(e[s].defaultSelected=!0);return}t!==null||e[s].disabled||(t=e[s])}t!==null&&(t.selected=!0)}}function co(e,t){if(t.dangerouslySetInnerHTML!=null)throw Error(O(91));return je({},t,{value:void 0,defaultValue:void 0,children:""+e._wrapperState.initialValue})}function xu(e,t){var n=t.value;if(n==null){if(n=t.children,t=t.defaultValue,n!=null){if(t!=null)throw Error(O(92));if(Br(n)){if(1<n.length)throw Error(O(93));n=n[0]}t=n}t==null&&(t=""),n=t}e._wrapperState={initialValue:mn(n)}}function md(e,t){var n=mn(t.value),r=mn(t.defaultValue);n!=null&&(n=""+n,n!==e.value&&(e.value=n),t.defaultValue==null&&e.defaultValue!==n&&(e.defaultValue=n)),r!=null&&(e.defaultValue=""+r)}function wu(e){var t=e.textContent;t===e._wrapperState.initialValue&&t!==""&&t!==null&&(e.value=t)}function gd(e){switch(e){case"svg":return"http://www.w3.org/2000/svg";case"math":return"http://www.w3.org/1998/Math/MathML";default:return"http://www.w3.org/1999/xhtml"}}function fo(e,t){return e==null||e==="http://www.w3.org/1999/xhtml"?gd(t):e==="http://www.w3.org/2000/svg"&&t==="foreignObject"?"http://www.w3.org/1999/xhtml":e}var _s,yd=function(e){return typeof MSApp<"u"&&MSApp.execUnsafeLocalFunction?function(t,n,r,s){MSApp.execUnsafeLocalFunction(function(){return e(t,n,r,s)})}:e}(function(e,t){if(e.namespaceURI!=="http://www.w3.org/2000/svg"||"innerHTML"in e)e.innerHTML=t;else{for(_s=_s||document.createElement("div"),_s.innerHTML="<svg>"+t.valueOf().toString()+"</svg>",t=_s.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function as(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var Kr={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},Hh=["Webkit","ms","Moz","O"];Object.keys(Kr).forEach(function(e){Hh.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),Kr[t]=Kr[e]})});function vd(e,t,n){return t==null||typeof t=="boolean"||t===""?"":n||typeof t!="number"||t===0||Kr.hasOwnProperty(e)&&Kr[e]?(""+t).trim():t+"px"}function xd(e,t){e=e.style;for(var n in t)if(t.hasOwnProperty(n)){var r=n.indexOf("--")===0,s=vd(n,t[n],r);n==="float"&&(n="cssFloat"),r?e.setProperty(n,s):e[n]=s}}var qh=je({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function po(e,t){if(t){if(qh[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(O(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(O(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(O(61))}if(t.style!=null&&typeof t.style!="object")throw Error(O(62))}}function ho(e,t){if(e.indexOf("-")===-1)return typeof t.is=="string";switch(e){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 mo=null;function yl(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var go=null,or=null,lr=null;function ju(e){if(e=Es(e)){if(typeof go!="function")throw Error(O(280));var t=e.stateNode;t&&(t=Xi(t),go(e.stateNode,e.type,t))}}function wd(e){or?lr?lr.push(e):lr=[e]:or=e}function jd(){if(or){var e=or,t=lr;if(lr=or=null,ju(e),t)for(e=0;e<t.length;e++)ju(t[e])}}function bd(e,t){return e(t)}function Nd(){}var Ca=!1;function kd(e,t,n){if(Ca)return e(t,n);Ca=!0;try{return bd(e,t,n)}finally{Ca=!1,(or!==null||lr!==null)&&(Nd(),jd())}}function os(e,t){var n=e.stateNode;if(n===null)return null;var r=Xi(n);if(r===null)return null;n=r[t];e:switch(t){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(r=!r.disabled)||(e=e.type,r=!(e==="button"||e==="input"||e==="select"||e==="textarea")),e=!r;break e;default:e=!1}if(e)return null;if(n&&typeof n!="function")throw Error(O(231,t,typeof n));return n}var yo=!1;if(Lt)try{var Tr={};Object.defineProperty(Tr,"passive",{get:function(){yo=!0}}),window.addEventListener("test",Tr,Tr),window.removeEventListener("test",Tr,Tr)}catch{yo=!1}function Qh(e,t,n,r,s,i,o,l,u){var c=Array.prototype.slice.call(arguments,3);try{t.apply(n,c)}catch(d){this.onError(d)}}var Gr=!1,vi=null,xi=!1,vo=null,Vh={onError:function(e){Gr=!0,vi=e}};function Kh(e,t,n,r,s,i,o,l,u){Gr=!1,vi=null,Qh.apply(Vh,arguments)}function Gh(e,t,n,r,s,i,o,l,u){if(Kh.apply(this,arguments),Gr){if(Gr){var c=vi;Gr=!1,vi=null}else throw Error(O(198));xi||(xi=!0,vo=c)}}function Fn(e){var t=e,n=e;if(e.alternate)for(;t.return;)t=t.return;else{e=t;do t=e,t.flags&4098&&(n=t.return),e=t.return;while(e)}return t.tag===3?n:null}function Sd(e){if(e.tag===13){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function bu(e){if(Fn(e)!==e)throw Error(O(188))}function Yh(e){var t=e.alternate;if(!t){if(t=Fn(e),t===null)throw Error(O(188));return t!==e?null:e}for(var n=e,r=t;;){var s=n.return;if(s===null)break;var i=s.alternate;if(i===null){if(r=s.return,r!==null){n=r;continue}break}if(s.child===i.child){for(i=s.child;i;){if(i===n)return bu(s),e;if(i===r)return bu(s),t;i=i.sibling}throw Error(O(188))}if(n.return!==r.return)n=s,r=i;else{for(var o=!1,l=s.child;l;){if(l===n){o=!0,n=s,r=i;break}if(l===r){o=!0,r=s,n=i;break}l=l.sibling}if(!o){for(l=i.child;l;){if(l===n){o=!0,n=i,r=s;break}if(l===r){o=!0,r=i,n=s;break}l=l.sibling}if(!o)throw Error(O(189))}}if(n.alternate!==r)throw Error(O(190))}if(n.tag!==3)throw Error(O(188));return n.stateNode.current===n?e:t}function Cd(e){return e=Yh(e),e!==null?Ed(e):null}function Ed(e){if(e.tag===5||e.tag===6)return e;for(e=e.child;e!==null;){var t=Ed(e);if(t!==null)return t;e=e.sibling}return null}var Pd=st.unstable_scheduleCallback,Nu=st.unstable_cancelCallback,Jh=st.unstable_shouldYield,Xh=st.unstable_requestPaint,Se=st.unstable_now,Zh=st.unstable_getCurrentPriorityLevel,vl=st.unstable_ImmediatePriority,Td=st.unstable_UserBlockingPriority,wi=st.unstable_NormalPriority,em=st.unstable_LowPriority,Od=st.unstable_IdlePriority,Ki=null,Tt=null;function tm(e){if(Tt&&typeof Tt.onCommitFiberRoot=="function")try{Tt.onCommitFiberRoot(Ki,e,void 0,(e.current.flags&128)===128)}catch{}}var jt=Math.clz32?Math.clz32:sm,nm=Math.log,rm=Math.LN2;function sm(e){return e>>>=0,e===0?32:31-(nm(e)/rm|0)|0}var Ls=64,Fs=4194304;function Hr(e){switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return e&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return e&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return e}}function ji(e,t){var n=e.pendingLanes;if(n===0)return 0;var r=0,s=e.suspendedLanes,i=e.pingedLanes,o=n&268435455;if(o!==0){var l=o&~s;l!==0?r=Hr(l):(i&=o,i!==0&&(r=Hr(i)))}else o=n&~s,o!==0?r=Hr(o):i!==0&&(r=Hr(i));if(r===0)return 0;if(t!==0&&t!==r&&!(t&s)&&(s=r&-r,i=t&-t,s>=i||s===16&&(i&4194240)!==0))return t;if(r&4&&(r|=n&16),t=e.entangledLanes,t!==0)for(e=e.entanglements,t&=r;0<t;)n=31-jt(t),s=1<<n,r|=e[n],t&=~s;return r}function im(e,t){switch(e){case 1:case 2:case 4:return t+250;case 8:case 16:case 32:case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t+5e3;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return-1;case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function am(e,t){for(var n=e.suspendedLanes,r=e.pingedLanes,s=e.expirationTimes,i=e.pendingLanes;0<i;){var o=31-jt(i),l=1<<o,u=s[o];u===-1?(!(l&n)||l&r)&&(s[o]=im(l,t)):u<=t&&(e.expiredLanes|=l),i&=~l}}function xo(e){return e=e.pendingLanes&-1073741825,e!==0?e:e&1073741824?1073741824:0}function zd(){var e=Ls;return Ls<<=1,!(Ls&4194240)&&(Ls=64),e}function Ea(e){for(var t=[],n=0;31>n;n++)t.push(e);return t}function Ss(e,t,n){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-jt(t),e[t]=n}function om(e,t){var n=e.pendingLanes&~t;e.pendingLanes=t,e.suspendedLanes=0,e.pingedLanes=0,e.expiredLanes&=t,e.mutableReadLanes&=t,e.entangledLanes&=t,t=e.entanglements;var r=e.eventTimes;for(e=e.expirationTimes;0<n;){var s=31-jt(n),i=1<<s;t[s]=0,r[s]=-1,e[s]=-1,n&=~i}}function xl(e,t){var n=e.entangledLanes|=t;for(e=e.entanglements;n;){var r=31-jt(n),s=1<<r;s&t|e[r]&t&&(e[r]|=t),n&=~s}}var le=0;function Ad(e){return e&=-e,1<e?4<e?e&268435455?16:536870912:4:1}var Md,wl,Rd,Id,_d,wo=!1,Ds=[],sn=null,an=null,on=null,ls=new Map,us=new Map,Xt=[],lm="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset submit".split(" ");function ku(e,t){switch(e){case"focusin":case"focusout":sn=null;break;case"dragenter":case"dragleave":an=null;break;case"mouseover":case"mouseout":on=null;break;case"pointerover":case"pointerout":ls.delete(t.pointerId);break;case"gotpointercapture":case"lostpointercapture":us.delete(t.pointerId)}}function Or(e,t,n,r,s,i){return e===null||e.nativeEvent!==i?(e={blockedOn:t,domEventName:n,eventSystemFlags:r,nativeEvent:i,targetContainers:[s]},t!==null&&(t=Es(t),t!==null&&wl(t)),e):(e.eventSystemFlags|=r,t=e.targetContainers,s!==null&&t.indexOf(s)===-1&&t.push(s),e)}function um(e,t,n,r,s){switch(t){case"focusin":return sn=Or(sn,e,t,n,r,s),!0;case"dragenter":return an=Or(an,e,t,n,r,s),!0;case"mouseover":return on=Or(on,e,t,n,r,s),!0;case"pointerover":var i=s.pointerId;return ls.set(i,Or(ls.get(i)||null,e,t,n,r,s)),!0;case"gotpointercapture":return i=s.pointerId,us.set(i,Or(us.get(i)||null,e,t,n,r,s)),!0}return!1}function Ld(e){var t=kn(e.target);if(t!==null){var n=Fn(t);if(n!==null){if(t=n.tag,t===13){if(t=Sd(n),t!==null){e.blockedOn=t,_d(e.priority,function(){Rd(n)});return}}else if(t===3&&n.stateNode.current.memoizedState.isDehydrated){e.blockedOn=n.tag===3?n.stateNode.containerInfo:null;return}}}e.blockedOn=null}function ri(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var n=jo(e.domEventName,e.eventSystemFlags,t[0],e.nativeEvent);if(n===null){n=e.nativeEvent;var r=new n.constructor(n.type,n);mo=r,n.target.dispatchEvent(r),mo=null}else return t=Es(n),t!==null&&wl(t),e.blockedOn=n,!1;t.shift()}return!0}function Su(e,t,n){ri(e)&&n.delete(t)}function cm(){wo=!1,sn!==null&&ri(sn)&&(sn=null),an!==null&&ri(an)&&(an=null),on!==null&&ri(on)&&(on=null),ls.forEach(Su),us.forEach(Su)}function zr(e,t){e.blockedOn===t&&(e.blockedOn=null,wo||(wo=!0,st.unstable_scheduleCallback(st.unstable_NormalPriority,cm)))}function cs(e){function t(s){return zr(s,e)}if(0<Ds.length){zr(Ds[0],e);for(var n=1;n<Ds.length;n++){var r=Ds[n];r.blockedOn===e&&(r.blockedOn=null)}}for(sn!==null&&zr(sn,e),an!==null&&zr(an,e),on!==null&&zr(on,e),ls.forEach(t),us.forEach(t),n=0;n<Xt.length;n++)r=Xt[n],r.blockedOn===e&&(r.blockedOn=null);for(;0<Xt.length&&(n=Xt[0],n.blockedOn===null);)Ld(n),n.blockedOn===null&&Xt.shift()}var ur=Ut.ReactCurrentBatchConfig,bi=!0;function dm(e,t,n,r){var s=le,i=ur.transition;ur.transition=null;try{le=1,jl(e,t,n,r)}finally{le=s,ur.transition=i}}function fm(e,t,n,r){var s=le,i=ur.transition;ur.transition=null;try{le=4,jl(e,t,n,r)}finally{le=s,ur.transition=i}}function jl(e,t,n,r){if(bi){var s=jo(e,t,n,r);if(s===null)La(e,t,r,Ni,n),ku(e,r);else if(um(s,e,t,n,r))r.stopPropagation();else if(ku(e,r),t&4&&-1<lm.indexOf(e)){for(;s!==null;){var i=Es(s);if(i!==null&&Md(i),i=jo(e,t,n,r),i===null&&La(e,t,r,Ni,n),i===s)break;s=i}s!==null&&r.stopPropagation()}else La(e,t,r,null,n)}}var Ni=null;function jo(e,t,n,r){if(Ni=null,e=yl(r),e=kn(e),e!==null)if(t=Fn(e),t===null)e=null;else if(n=t.tag,n===13){if(e=Sd(t),e!==null)return e;e=null}else if(n===3){if(t.stateNode.current.memoizedState.isDehydrated)return t.tag===3?t.stateNode.containerInfo:null;e=null}else t!==e&&(e=null);return Ni=e,null}function Fd(e){switch(e){case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"resize":case"seeked":case"submit":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 1;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"toggle":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 4;case"message":switch(Zh()){case vl:return 1;case Td:return 4;case wi:case em:return 16;case Od:return 536870912;default:return 16}default:return 16}}var tn=null,bl=null,si=null;function Dd(){if(si)return si;var e,t=bl,n=t.length,r,s="value"in tn?tn.value:tn.textContent,i=s.length;for(e=0;e<n&&t[e]===s[e];e++);var o=n-e;for(r=1;r<=o&&t[n-r]===s[i-r];r++);return si=s.slice(e,1<r?1-r:void 0)}function ii(e){var t=e.keyCode;return"charCode"in e?(e=e.charCode,e===0&&t===13&&(e=13)):e=t,e===10&&(e=13),32<=e||e===13?e:0}function $s(){return!0}function Cu(){return!1}function at(e){function t(n,r,s,i,o){this._reactName=n,this._targetInst=s,this.type=r,this.nativeEvent=i,this.target=o,this.currentTarget=null;for(var l in e)e.hasOwnProperty(l)&&(n=e[l],this[l]=n?n(i):i[l]);return this.isDefaultPrevented=(i.defaultPrevented!=null?i.defaultPrevented:i.returnValue===!1)?$s:Cu,this.isPropagationStopped=Cu,this}return je(t.prototype,{preventDefault:function(){this.defaultPrevented=!0;var n=this.nativeEvent;n&&(n.preventDefault?n.preventDefault():typeof n.returnValue!="unknown"&&(n.returnValue=!1),this.isDefaultPrevented=$s)},stopPropagation:function(){var n=this.nativeEvent;n&&(n.stopPropagation?n.stopPropagation():typeof n.cancelBubble!="unknown"&&(n.cancelBubble=!0),this.isPropagationStopped=$s)},persist:function(){},isPersistent:$s}),t}var kr={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},Nl=at(kr),Cs=je({},kr,{view:0,detail:0}),pm=at(Cs),Pa,Ta,Ar,Gi=je({},Cs,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:kl,button:0,buttons:0,relatedTarget:function(e){return e.relatedTarget===void 0?e.fromElement===e.srcElement?e.toElement:e.fromElement:e.relatedTarget},movementX:function(e){return"movementX"in e?e.movementX:(e!==Ar&&(Ar&&e.type==="mousemove"?(Pa=e.screenX-Ar.screenX,Ta=e.screenY-Ar.screenY):Ta=Pa=0,Ar=e),Pa)},movementY:function(e){return"movementY"in e?e.movementY:Ta}}),Eu=at(Gi),hm=je({},Gi,{dataTransfer:0}),mm=at(hm),gm=je({},Cs,{relatedTarget:0}),Oa=at(gm),ym=je({},kr,{animationName:0,elapsedTime:0,pseudoElement:0}),vm=at(ym),xm=je({},kr,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),wm=at(xm),jm=je({},kr,{data:0}),Pu=at(jm),bm={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},Nm={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"},km={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function Sm(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=km[e])?!!t[e]:!1}function kl(){return Sm}var Cm=je({},Cs,{key:function(e){if(e.key){var t=bm[e.key]||e.key;if(t!=="Unidentified")return t}return e.type==="keypress"?(e=ii(e),e===13?"Enter":String.fromCharCode(e)):e.type==="keydown"||e.type==="keyup"?Nm[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:kl,charCode:function(e){return e.type==="keypress"?ii(e):0},keyCode:function(e){return e.type==="keydown"||e.type==="keyup"?e.keyCode:0},which:function(e){return e.type==="keypress"?ii(e):e.type==="keydown"||e.type==="keyup"?e.keyCode:0}}),Em=at(Cm),Pm=je({},Gi,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),Tu=at(Pm),Tm=je({},Cs,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:kl}),Om=at(Tm),zm=je({},kr,{propertyName:0,elapsedTime:0,pseudoElement:0}),Am=at(zm),Mm=je({},Gi,{deltaX:function(e){return"deltaX"in e?e.deltaX:"wheelDeltaX"in e?-e.wheelDeltaX:0},deltaY:function(e){return"deltaY"in e?e.deltaY:"wheelDeltaY"in e?-e.wheelDeltaY:"wheelDelta"in e?-e.wheelDelta:0},deltaZ:0,deltaMode:0}),Rm=at(Mm),Im=[9,13,27,32],Sl=Lt&&"CompositionEvent"in window,Yr=null;Lt&&"documentMode"in document&&(Yr=document.documentMode);var _m=Lt&&"TextEvent"in window&&!Yr,$d=Lt&&(!Sl||Yr&&8<Yr&&11>=Yr),Ou=String.fromCharCode(32),zu=!1;function Ud(e,t){switch(e){case"keyup":return Im.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function Wd(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var Kn=!1;function Lm(e,t){switch(e){case"compositionend":return Wd(t);case"keypress":return t.which!==32?null:(zu=!0,Ou);case"textInput":return e=t.data,e===Ou&&zu?null:e;default:return null}}function Fm(e,t){if(Kn)return e==="compositionend"||!Sl&&Ud(e,t)?(e=Dd(),si=bl=tn=null,Kn=!1,e):null;switch(e){case"paste":return null;case"keypress":if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1<t.char.length)return t.char;if(t.which)return String.fromCharCode(t.which)}return null;case"compositionend":return $d&&t.locale!=="ko"?null:t.data;default:return null}}var Dm={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 Au(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t==="input"?!!Dm[e.type]:t==="textarea"}function Bd(e,t,n,r){wd(r),t=ki(t,"onChange"),0<t.length&&(n=new Nl("onChange","change",null,n,r),e.push({event:n,listeners:t}))}var Jr=null,ds=null;function $m(e){ef(e,0)}function Yi(e){var t=Jn(e);if(pd(t))return e}function Um(e,t){if(e==="change")return t}var Hd=!1;if(Lt){var za;if(Lt){var Aa="oninput"in document;if(!Aa){var Mu=document.createElement("div");Mu.setAttribute("oninput","return;"),Aa=typeof Mu.oninput=="function"}za=Aa}else za=!1;Hd=za&&(!document.documentMode||9<document.documentMode)}function Ru(){Jr&&(Jr.detachEvent("onpropertychange",qd),ds=Jr=null)}function qd(e){if(e.propertyName==="value"&&Yi(ds)){var t=[];Bd(t,ds,e,yl(e)),kd($m,t)}}function Wm(e,t,n){e==="focusin"?(Ru(),Jr=t,ds=n,Jr.attachEvent("onpropertychange",qd)):e==="focusout"&&Ru()}function Bm(e){if(e==="selectionchange"||e==="keyup"||e==="keydown")return Yi(ds)}function Hm(e,t){if(e==="click")return Yi(t)}function qm(e,t){if(e==="input"||e==="change")return Yi(t)}function Qm(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var Nt=typeof Object.is=="function"?Object.is:Qm;function fs(e,t){if(Nt(e,t))return!0;if(typeof e!="object"||e===null||typeof t!="object"||t===null)return!1;var n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(r=0;r<n.length;r++){var s=n[r];if(!no.call(t,s)||!Nt(e[s],t[s]))return!1}return!0}function Iu(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function _u(e,t){var n=Iu(e);e=0;for(var r;n;){if(n.nodeType===3){if(r=e+n.textContent.length,e<=t&&r>=t)return{node:n,offset:t-e};e=r}e:{for(;n;){if(n.nextSibling){n=n.nextSibling;break e}n=n.parentNode}n=void 0}n=Iu(n)}}function Qd(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?Qd(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function Vd(){for(var e=window,t=yi();t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href=="string"}catch{n=!1}if(n)e=t.contentWindow;else break;t=yi(e.document)}return t}function Cl(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t==="input"&&(e.type==="text"||e.type==="search"||e.type==="tel"||e.type==="url"||e.type==="password")||t==="textarea"||e.contentEditable==="true")}function Vm(e){var t=Vd(),n=e.focusedElem,r=e.selectionRange;if(t!==n&&n&&n.ownerDocument&&Qd(n.ownerDocument.documentElement,n)){if(r!==null&&Cl(n)){if(t=r.start,e=r.end,e===void 0&&(e=t),"selectionStart"in n)n.selectionStart=t,n.selectionEnd=Math.min(e,n.value.length);else if(e=(t=n.ownerDocument||document)&&t.defaultView||window,e.getSelection){e=e.getSelection();var s=n.textContent.length,i=Math.min(r.start,s);r=r.end===void 0?i:Math.min(r.end,s),!e.extend&&i>r&&(s=r,r=i,i=s),s=_u(n,i);var o=_u(n,r);s&&o&&(e.rangeCount!==1||e.anchorNode!==s.node||e.anchorOffset!==s.offset||e.focusNode!==o.node||e.focusOffset!==o.offset)&&(t=t.createRange(),t.setStart(s.node,s.offset),e.removeAllRanges(),i>r?(e.addRange(t),e.extend(o.node,o.offset)):(t.setEnd(o.node,o.offset),e.addRange(t)))}}for(t=[],e=n;e=e.parentNode;)e.nodeType===1&&t.push({element:e,left:e.scrollLeft,top:e.scrollTop});for(typeof n.focus=="function"&&n.focus(),n=0;n<t.length;n++)e=t[n],e.element.scrollLeft=e.left,e.element.scrollTop=e.top}}var Km=Lt&&"documentMode"in document&&11>=document.documentMode,Gn=null,bo=null,Xr=null,No=!1;function Lu(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;No||Gn==null||Gn!==yi(r)||(r=Gn,"selectionStart"in r&&Cl(r)?r={start:r.selectionStart,end:r.selectionEnd}:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection(),r={anchorNode:r.anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset}),Xr&&fs(Xr,r)||(Xr=r,r=ki(bo,"onSelect"),0<r.length&&(t=new Nl("onSelect","select",null,t,n),e.push({event:t,listeners:r}),t.target=Gn)))}function Us(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n["Webkit"+e]="webkit"+t,n["Moz"+e]="moz"+t,n}var Yn={animationend:Us("Animation","AnimationEnd"),animationiteration:Us("Animation","AnimationIteration"),animationstart:Us("Animation","AnimationStart"),transitionend:Us("Transition","TransitionEnd")},Ma={},Kd={};Lt&&(Kd=document.createElement("div").style,"AnimationEvent"in window||(delete Yn.animationend.animation,delete Yn.animationiteration.animation,delete Yn.animationstart.animation),"TransitionEvent"in window||delete Yn.transitionend.transition);function Ji(e){if(Ma[e])return Ma[e];if(!Yn[e])return e;var t=Yn[e],n;for(n in t)if(t.hasOwnProperty(n)&&n in Kd)return Ma[e]=t[n];return e}var Gd=Ji("animationend"),Yd=Ji("animationiteration"),Jd=Ji("animationstart"),Xd=Ji("transitionend"),Zd=new Map,Fu="abort auxClick cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel".split(" ");function yn(e,t){Zd.set(e,t),Ln(t,[e])}for(var Ra=0;Ra<Fu.length;Ra++){var Ia=Fu[Ra],Gm=Ia.toLowerCase(),Ym=Ia[0].toUpperCase()+Ia.slice(1);yn(Gm,"on"+Ym)}yn(Gd,"onAnimationEnd");yn(Yd,"onAnimationIteration");yn(Jd,"onAnimationStart");yn("dblclick","onDoubleClick");yn("focusin","onFocus");yn("focusout","onBlur");yn(Xd,"onTransitionEnd");hr("onMouseEnter",["mouseout","mouseover"]);hr("onMouseLeave",["mouseout","mouseover"]);hr("onPointerEnter",["pointerout","pointerover"]);hr("onPointerLeave",["pointerout","pointerover"]);Ln("onChange","change click focusin focusout input keydown keyup selectionchange".split(" "));Ln("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" "));Ln("onBeforeInput",["compositionend","keypress","textInput","paste"]);Ln("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" "));Ln("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" "));Ln("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var qr="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(" "),Jm=new Set("cancel close invalid load scroll toggle".split(" ").concat(qr));function Du(e,t,n){var r=e.type||"unknown-event";e.currentTarget=n,Gh(r,t,void 0,e),e.currentTarget=null}function ef(e,t){t=(t&4)!==0;for(var n=0;n<e.length;n++){var r=e[n],s=r.event;r=r.listeners;e:{var i=void 0;if(t)for(var o=r.length-1;0<=o;o--){var l=r[o],u=l.instance,c=l.currentTarget;if(l=l.listener,u!==i&&s.isPropagationStopped())break e;Du(s,l,c),i=u}else for(o=0;o<r.length;o++){if(l=r[o],u=l.instance,c=l.currentTarget,l=l.listener,u!==i&&s.isPropagationStopped())break e;Du(s,l,c),i=u}}}if(xi)throw e=vo,xi=!1,vo=null,e}function me(e,t){var n=t[Po];n===void 0&&(n=t[Po]=new Set);var r=e+"__bubble";n.has(r)||(tf(t,e,2,!1),n.add(r))}function _a(e,t,n){var r=0;t&&(r|=4),tf(n,e,r,t)}var Ws="_reactListening"+Math.random().toString(36).slice(2);function ps(e){if(!e[Ws]){e[Ws]=!0,ld.forEach(function(n){n!=="selectionchange"&&(Jm.has(n)||_a(n,!1,e),_a(n,!0,e))});var t=e.nodeType===9?e:e.ownerDocument;t===null||t[Ws]||(t[Ws]=!0,_a("selectionchange",!1,t))}}function tf(e,t,n,r){switch(Fd(t)){case 1:var s=dm;break;case 4:s=fm;break;default:s=jl}n=s.bind(null,t,n,e),s=void 0,!yo||t!=="touchstart"&&t!=="touchmove"&&t!=="wheel"||(s=!0),r?s!==void 0?e.addEventListener(t,n,{capture:!0,passive:s}):e.addEventListener(t,n,!0):s!==void 0?e.addEventListener(t,n,{passive:s}):e.addEventListener(t,n,!1)}function La(e,t,n,r,s){var i=r;if(!(t&1)&&!(t&2)&&r!==null)e:for(;;){if(r===null)return;var o=r.tag;if(o===3||o===4){var l=r.stateNode.containerInfo;if(l===s||l.nodeType===8&&l.parentNode===s)break;if(o===4)for(o=r.return;o!==null;){var u=o.tag;if((u===3||u===4)&&(u=o.stateNode.containerInfo,u===s||u.nodeType===8&&u.parentNode===s))return;o=o.return}for(;l!==null;){if(o=kn(l),o===null)return;if(u=o.tag,u===5||u===6){r=i=o;continue e}l=l.parentNode}}r=r.return}kd(function(){var c=i,d=yl(n),p=[];e:{var h=Zd.get(e);if(h!==void 0){var v=Nl,x=e;switch(e){case"keypress":if(ii(n)===0)break e;case"keydown":case"keyup":v=Em;break;case"focusin":x="focus",v=Oa;break;case"focusout":x="blur",v=Oa;break;case"beforeblur":case"afterblur":v=Oa;break;case"click":if(n.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":v=Eu;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":v=mm;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":v=Om;break;case Gd:case Yd:case Jd:v=vm;break;case Xd:v=Am;break;case"scroll":v=pm;break;case"wheel":v=Rm;break;case"copy":case"cut":case"paste":v=wm;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":v=Tu}var w=(t&4)!==0,k=!w&&e==="scroll",m=w?h!==null?h+"Capture":null:h;w=[];for(var f=c,g;f!==null;){g=f;var b=g.stateNode;if(g.tag===5&&b!==null&&(g=b,m!==null&&(b=os(f,m),b!=null&&w.push(hs(f,b,g)))),k)break;f=f.return}0<w.length&&(h=new v(h,x,null,n,d),p.push({event:h,listeners:w}))}}if(!(t&7)){e:{if(h=e==="mouseover"||e==="pointerover",v=e==="mouseout"||e==="pointerout",h&&n!==mo&&(x=n.relatedTarget||n.fromElement)&&(kn(x)||x[Ft]))break e;if((v||h)&&(h=d.window===d?d:(h=d.ownerDocument)?h.defaultView||h.parentWindow:window,v?(x=n.relatedTarget||n.toElement,v=c,x=x?kn(x):null,x!==null&&(k=Fn(x),x!==k||x.tag!==5&&x.tag!==6)&&(x=null)):(v=null,x=c),v!==x)){if(w=Eu,b="onMouseLeave",m="onMouseEnter",f="mouse",(e==="pointerout"||e==="pointerover")&&(w=Tu,b="onPointerLeave",m="onPointerEnter",f="pointer"),k=v==null?h:Jn(v),g=x==null?h:Jn(x),h=new w(b,f+"leave",v,n,d),h.target=k,h.relatedTarget=g,b=null,kn(d)===c&&(w=new w(m,f+"enter",x,n,d),w.target=g,w.relatedTarget=k,b=w),k=b,v&&x)t:{for(w=v,m=x,f=0,g=w;g;g=Hn(g))f++;for(g=0,b=m;b;b=Hn(b))g++;for(;0<f-g;)w=Hn(w),f--;for(;0<g-f;)m=Hn(m),g--;for(;f--;){if(w===m||m!==null&&w===m.alternate)break t;w=Hn(w),m=Hn(m)}w=null}else w=null;v!==null&&$u(p,h,v,w,!1),x!==null&&k!==null&&$u(p,k,x,w,!0)}}e:{if(h=c?Jn(c):window,v=h.nodeName&&h.nodeName.toLowerCase(),v==="select"||v==="input"&&h.type==="file")var E=Um;else if(Au(h))if(Hd)E=qm;else{E=Bm;var T=Wm}else(v=h.nodeName)&&v.toLowerCase()==="input"&&(h.type==="checkbox"||h.type==="radio")&&(E=Hm);if(E&&(E=E(e,c))){Bd(p,E,n,d);break e}T&&T(e,h,c),e==="focusout"&&(T=h._wrapperState)&&T.controlled&&h.type==="number"&&uo(h,"number",h.value)}switch(T=c?Jn(c):window,e){case"focusin":(Au(T)||T.contentEditable==="true")&&(Gn=T,bo=c,Xr=null);break;case"focusout":Xr=bo=Gn=null;break;case"mousedown":No=!0;break;case"contextmenu":case"mouseup":case"dragend":No=!1,Lu(p,n,d);break;case"selectionchange":if(Km)break;case"keydown":case"keyup":Lu(p,n,d)}var C;if(Sl)e:{switch(e){case"compositionstart":var j="onCompositionStart";break e;case"compositionend":j="onCompositionEnd";break e;case"compositionupdate":j="onCompositionUpdate";break e}j=void 0}else Kn?Ud(e,n)&&(j="onCompositionEnd"):e==="keydown"&&n.keyCode===229&&(j="onCompositionStart");j&&($d&&n.locale!=="ko"&&(Kn||j!=="onCompositionStart"?j==="onCompositionEnd"&&Kn&&(C=Dd()):(tn=d,bl="value"in tn?tn.value:tn.textContent,Kn=!0)),T=ki(c,j),0<T.length&&(j=new Pu(j,e,null,n,d),p.push({event:j,listeners:T}),C?j.data=C:(C=Wd(n),C!==null&&(j.data=C)))),(C=_m?Lm(e,n):Fm(e,n))&&(c=ki(c,"onBeforeInput"),0<c.length&&(d=new Pu("onBeforeInput","beforeinput",null,n,d),p.push({event:d,listeners:c}),d.data=C))}ef(p,t)})}function hs(e,t,n){return{instance:e,listener:t,currentTarget:n}}function ki(e,t){for(var n=t+"Capture",r=[];e!==null;){var s=e,i=s.stateNode;s.tag===5&&i!==null&&(s=i,i=os(e,n),i!=null&&r.unshift(hs(e,i,s)),i=os(e,t),i!=null&&r.push(hs(e,i,s))),e=e.return}return r}function Hn(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5);return e||null}function $u(e,t,n,r,s){for(var i=t._reactName,o=[];n!==null&&n!==r;){var l=n,u=l.alternate,c=l.stateNode;if(u!==null&&u===r)break;l.tag===5&&c!==null&&(l=c,s?(u=os(n,i),u!=null&&o.unshift(hs(n,u,l))):s||(u=os(n,i),u!=null&&o.push(hs(n,u,l)))),n=n.return}o.length!==0&&e.push({event:t,listeners:o})}var Xm=/\r\n?/g,Zm=/\u0000|\uFFFD/g;function Uu(e){return(typeof e=="string"?e:""+e).replace(Xm,`
38
+ `).replace(Zm,"")}function Bs(e,t,n){if(t=Uu(t),Uu(e)!==t&&n)throw Error(O(425))}function Si(){}var ko=null,So=null;function Co(e,t){return e==="textarea"||e==="noscript"||typeof t.children=="string"||typeof t.children=="number"||typeof t.dangerouslySetInnerHTML=="object"&&t.dangerouslySetInnerHTML!==null&&t.dangerouslySetInnerHTML.__html!=null}var Eo=typeof setTimeout=="function"?setTimeout:void 0,eg=typeof clearTimeout=="function"?clearTimeout:void 0,Wu=typeof Promise=="function"?Promise:void 0,tg=typeof queueMicrotask=="function"?queueMicrotask:typeof Wu<"u"?function(e){return Wu.resolve(null).then(e).catch(ng)}:Eo;function ng(e){setTimeout(function(){throw e})}function Fa(e,t){var n=t,r=0;do{var s=n.nextSibling;if(e.removeChild(n),s&&s.nodeType===8)if(n=s.data,n==="/$"){if(r===0){e.removeChild(s),cs(t);return}r--}else n!=="$"&&n!=="$?"&&n!=="$!"||r++;n=s}while(n);cs(t)}function ln(e){for(;e!=null;e=e.nextSibling){var t=e.nodeType;if(t===1||t===3)break;if(t===8){if(t=e.data,t==="$"||t==="$!"||t==="$?")break;if(t==="/$")return null}}return e}function Bu(e){e=e.previousSibling;for(var t=0;e;){if(e.nodeType===8){var n=e.data;if(n==="$"||n==="$!"||n==="$?"){if(t===0)return e;t--}else n==="/$"&&t++}e=e.previousSibling}return null}var Sr=Math.random().toString(36).slice(2),Pt="__reactFiber$"+Sr,ms="__reactProps$"+Sr,Ft="__reactContainer$"+Sr,Po="__reactEvents$"+Sr,rg="__reactListeners$"+Sr,sg="__reactHandles$"+Sr;function kn(e){var t=e[Pt];if(t)return t;for(var n=e.parentNode;n;){if(t=n[Ft]||n[Pt]){if(n=t.alternate,t.child!==null||n!==null&&n.child!==null)for(e=Bu(e);e!==null;){if(n=e[Pt])return n;e=Bu(e)}return t}e=n,n=e.parentNode}return null}function Es(e){return e=e[Pt]||e[Ft],!e||e.tag!==5&&e.tag!==6&&e.tag!==13&&e.tag!==3?null:e}function Jn(e){if(e.tag===5||e.tag===6)return e.stateNode;throw Error(O(33))}function Xi(e){return e[ms]||null}var To=[],Xn=-1;function vn(e){return{current:e}}function ge(e){0>Xn||(e.current=To[Xn],To[Xn]=null,Xn--)}function pe(e,t){Xn++,To[Xn]=e.current,e.current=t}var gn={},We=vn(gn),Xe=vn(!1),An=gn;function mr(e,t){var n=e.type.contextTypes;if(!n)return gn;var r=e.stateNode;if(r&&r.__reactInternalMemoizedUnmaskedChildContext===t)return r.__reactInternalMemoizedMaskedChildContext;var s={},i;for(i in n)s[i]=t[i];return r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=s),s}function Ze(e){return e=e.childContextTypes,e!=null}function Ci(){ge(Xe),ge(We)}function Hu(e,t,n){if(We.current!==gn)throw Error(O(168));pe(We,t),pe(Xe,n)}function nf(e,t,n){var r=e.stateNode;if(t=t.childContextTypes,typeof r.getChildContext!="function")return n;r=r.getChildContext();for(var s in r)if(!(s in t))throw Error(O(108,Wh(e)||"Unknown",s));return je({},n,r)}function Ei(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||gn,An=We.current,pe(We,e),pe(Xe,Xe.current),!0}function qu(e,t,n){var r=e.stateNode;if(!r)throw Error(O(169));n?(e=nf(e,t,An),r.__reactInternalMemoizedMergedChildContext=e,ge(Xe),ge(We),pe(We,e)):ge(Xe),pe(Xe,n)}var At=null,Zi=!1,Da=!1;function rf(e){At===null?At=[e]:At.push(e)}function ig(e){Zi=!0,rf(e)}function xn(){if(!Da&&At!==null){Da=!0;var e=0,t=le;try{var n=At;for(le=1;e<n.length;e++){var r=n[e];do r=r(!0);while(r!==null)}At=null,Zi=!1}catch(s){throw At!==null&&(At=At.slice(e+1)),Pd(vl,xn),s}finally{le=t,Da=!1}}return null}var Zn=[],er=0,Pi=null,Ti=0,lt=[],ut=0,Mn=null,Rt=1,It="";function bn(e,t){Zn[er++]=Ti,Zn[er++]=Pi,Pi=e,Ti=t}function sf(e,t,n){lt[ut++]=Rt,lt[ut++]=It,lt[ut++]=Mn,Mn=e;var r=Rt;e=It;var s=32-jt(r)-1;r&=~(1<<s),n+=1;var i=32-jt(t)+s;if(30<i){var o=s-s%5;i=(r&(1<<o)-1).toString(32),r>>=o,s-=o,Rt=1<<32-jt(t)+s|n<<s|r,It=i+e}else Rt=1<<i|n<<s|r,It=e}function El(e){e.return!==null&&(bn(e,1),sf(e,1,0))}function Pl(e){for(;e===Pi;)Pi=Zn[--er],Zn[er]=null,Ti=Zn[--er],Zn[er]=null;for(;e===Mn;)Mn=lt[--ut],lt[ut]=null,It=lt[--ut],lt[ut]=null,Rt=lt[--ut],lt[ut]=null}var rt=null,nt=null,ye=!1,wt=null;function af(e,t){var n=ct(5,null,null,0);n.elementType="DELETED",n.stateNode=t,n.return=e,t=e.deletions,t===null?(e.deletions=[n],e.flags|=16):t.push(n)}function Qu(e,t){switch(e.tag){case 5:var n=e.type;return t=t.nodeType!==1||n.toLowerCase()!==t.nodeName.toLowerCase()?null:t,t!==null?(e.stateNode=t,rt=e,nt=ln(t.firstChild),!0):!1;case 6:return t=e.pendingProps===""||t.nodeType!==3?null:t,t!==null?(e.stateNode=t,rt=e,nt=null,!0):!1;case 13:return t=t.nodeType!==8?null:t,t!==null?(n=Mn!==null?{id:Rt,overflow:It}:null,e.memoizedState={dehydrated:t,treeContext:n,retryLane:1073741824},n=ct(18,null,null,0),n.stateNode=t,n.return=e,e.child=n,rt=e,nt=null,!0):!1;default:return!1}}function Oo(e){return(e.mode&1)!==0&&(e.flags&128)===0}function zo(e){if(ye){var t=nt;if(t){var n=t;if(!Qu(e,t)){if(Oo(e))throw Error(O(418));t=ln(n.nextSibling);var r=rt;t&&Qu(e,t)?af(r,n):(e.flags=e.flags&-4097|2,ye=!1,rt=e)}}else{if(Oo(e))throw Error(O(418));e.flags=e.flags&-4097|2,ye=!1,rt=e}}}function Vu(e){for(e=e.return;e!==null&&e.tag!==5&&e.tag!==3&&e.tag!==13;)e=e.return;rt=e}function Hs(e){if(e!==rt)return!1;if(!ye)return Vu(e),ye=!0,!1;var t;if((t=e.tag!==3)&&!(t=e.tag!==5)&&(t=e.type,t=t!=="head"&&t!=="body"&&!Co(e.type,e.memoizedProps)),t&&(t=nt)){if(Oo(e))throw of(),Error(O(418));for(;t;)af(e,t),t=ln(t.nextSibling)}if(Vu(e),e.tag===13){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(O(317));e:{for(e=e.nextSibling,t=0;e;){if(e.nodeType===8){var n=e.data;if(n==="/$"){if(t===0){nt=ln(e.nextSibling);break e}t--}else n!=="$"&&n!=="$!"&&n!=="$?"||t++}e=e.nextSibling}nt=null}}else nt=rt?ln(e.stateNode.nextSibling):null;return!0}function of(){for(var e=nt;e;)e=ln(e.nextSibling)}function gr(){nt=rt=null,ye=!1}function Tl(e){wt===null?wt=[e]:wt.push(e)}var ag=Ut.ReactCurrentBatchConfig;function Mr(e,t,n){if(e=n.ref,e!==null&&typeof e!="function"&&typeof e!="object"){if(n._owner){if(n=n._owner,n){if(n.tag!==1)throw Error(O(309));var r=n.stateNode}if(!r)throw Error(O(147,e));var s=r,i=""+e;return t!==null&&t.ref!==null&&typeof t.ref=="function"&&t.ref._stringRef===i?t.ref:(t=function(o){var l=s.refs;o===null?delete l[i]:l[i]=o},t._stringRef=i,t)}if(typeof e!="string")throw Error(O(284));if(!n._owner)throw Error(O(290,e))}return e}function qs(e,t){throw e=Object.prototype.toString.call(t),Error(O(31,e==="[object Object]"?"object with keys {"+Object.keys(t).join(", ")+"}":e))}function Ku(e){var t=e._init;return t(e._payload)}function lf(e){function t(m,f){if(e){var g=m.deletions;g===null?(m.deletions=[f],m.flags|=16):g.push(f)}}function n(m,f){if(!e)return null;for(;f!==null;)t(m,f),f=f.sibling;return null}function r(m,f){for(m=new Map;f!==null;)f.key!==null?m.set(f.key,f):m.set(f.index,f),f=f.sibling;return m}function s(m,f){return m=fn(m,f),m.index=0,m.sibling=null,m}function i(m,f,g){return m.index=g,e?(g=m.alternate,g!==null?(g=g.index,g<f?(m.flags|=2,f):g):(m.flags|=2,f)):(m.flags|=1048576,f)}function o(m){return e&&m.alternate===null&&(m.flags|=2),m}function l(m,f,g,b){return f===null||f.tag!==6?(f=Qa(g,m.mode,b),f.return=m,f):(f=s(f,g),f.return=m,f)}function u(m,f,g,b){var E=g.type;return E===Vn?d(m,f,g.props.children,b,g.key):f!==null&&(f.elementType===E||typeof E=="object"&&E!==null&&E.$$typeof===Vt&&Ku(E)===f.type)?(b=s(f,g.props),b.ref=Mr(m,f,g),b.return=m,b):(b=fi(g.type,g.key,g.props,null,m.mode,b),b.ref=Mr(m,f,g),b.return=m,b)}function c(m,f,g,b){return f===null||f.tag!==4||f.stateNode.containerInfo!==g.containerInfo||f.stateNode.implementation!==g.implementation?(f=Va(g,m.mode,b),f.return=m,f):(f=s(f,g.children||[]),f.return=m,f)}function d(m,f,g,b,E){return f===null||f.tag!==7?(f=zn(g,m.mode,b,E),f.return=m,f):(f=s(f,g),f.return=m,f)}function p(m,f,g){if(typeof f=="string"&&f!==""||typeof f=="number")return f=Qa(""+f,m.mode,g),f.return=m,f;if(typeof f=="object"&&f!==null){switch(f.$$typeof){case Rs:return g=fi(f.type,f.key,f.props,null,m.mode,g),g.ref=Mr(m,null,f),g.return=m,g;case Qn:return f=Va(f,m.mode,g),f.return=m,f;case Vt:var b=f._init;return p(m,b(f._payload),g)}if(Br(f)||Pr(f))return f=zn(f,m.mode,g,null),f.return=m,f;qs(m,f)}return null}function h(m,f,g,b){var E=f!==null?f.key:null;if(typeof g=="string"&&g!==""||typeof g=="number")return E!==null?null:l(m,f,""+g,b);if(typeof g=="object"&&g!==null){switch(g.$$typeof){case Rs:return g.key===E?u(m,f,g,b):null;case Qn:return g.key===E?c(m,f,g,b):null;case Vt:return E=g._init,h(m,f,E(g._payload),b)}if(Br(g)||Pr(g))return E!==null?null:d(m,f,g,b,null);qs(m,g)}return null}function v(m,f,g,b,E){if(typeof b=="string"&&b!==""||typeof b=="number")return m=m.get(g)||null,l(f,m,""+b,E);if(typeof b=="object"&&b!==null){switch(b.$$typeof){case Rs:return m=m.get(b.key===null?g:b.key)||null,u(f,m,b,E);case Qn:return m=m.get(b.key===null?g:b.key)||null,c(f,m,b,E);case Vt:var T=b._init;return v(m,f,g,T(b._payload),E)}if(Br(b)||Pr(b))return m=m.get(g)||null,d(f,m,b,E,null);qs(f,b)}return null}function x(m,f,g,b){for(var E=null,T=null,C=f,j=f=0,R=null;C!==null&&j<g.length;j++){C.index>j?(R=C,C=null):R=C.sibling;var M=h(m,C,g[j],b);if(M===null){C===null&&(C=R);break}e&&C&&M.alternate===null&&t(m,C),f=i(M,f,j),T===null?E=M:T.sibling=M,T=M,C=R}if(j===g.length)return n(m,C),ye&&bn(m,j),E;if(C===null){for(;j<g.length;j++)C=p(m,g[j],b),C!==null&&(f=i(C,f,j),T===null?E=C:T.sibling=C,T=C);return ye&&bn(m,j),E}for(C=r(m,C);j<g.length;j++)R=v(C,m,j,g[j],b),R!==null&&(e&&R.alternate!==null&&C.delete(R.key===null?j:R.key),f=i(R,f,j),T===null?E=R:T.sibling=R,T=R);return e&&C.forEach(function(K){return t(m,K)}),ye&&bn(m,j),E}function w(m,f,g,b){var E=Pr(g);if(typeof E!="function")throw Error(O(150));if(g=E.call(g),g==null)throw Error(O(151));for(var T=E=null,C=f,j=f=0,R=null,M=g.next();C!==null&&!M.done;j++,M=g.next()){C.index>j?(R=C,C=null):R=C.sibling;var K=h(m,C,M.value,b);if(K===null){C===null&&(C=R);break}e&&C&&K.alternate===null&&t(m,C),f=i(K,f,j),T===null?E=K:T.sibling=K,T=K,C=R}if(M.done)return n(m,C),ye&&bn(m,j),E;if(C===null){for(;!M.done;j++,M=g.next())M=p(m,M.value,b),M!==null&&(f=i(M,f,j),T===null?E=M:T.sibling=M,T=M);return ye&&bn(m,j),E}for(C=r(m,C);!M.done;j++,M=g.next())M=v(C,m,j,M.value,b),M!==null&&(e&&M.alternate!==null&&C.delete(M.key===null?j:M.key),f=i(M,f,j),T===null?E=M:T.sibling=M,T=M);return e&&C.forEach(function(G){return t(m,G)}),ye&&bn(m,j),E}function k(m,f,g,b){if(typeof g=="object"&&g!==null&&g.type===Vn&&g.key===null&&(g=g.props.children),typeof g=="object"&&g!==null){switch(g.$$typeof){case Rs:e:{for(var E=g.key,T=f;T!==null;){if(T.key===E){if(E=g.type,E===Vn){if(T.tag===7){n(m,T.sibling),f=s(T,g.props.children),f.return=m,m=f;break e}}else if(T.elementType===E||typeof E=="object"&&E!==null&&E.$$typeof===Vt&&Ku(E)===T.type){n(m,T.sibling),f=s(T,g.props),f.ref=Mr(m,T,g),f.return=m,m=f;break e}n(m,T);break}else t(m,T);T=T.sibling}g.type===Vn?(f=zn(g.props.children,m.mode,b,g.key),f.return=m,m=f):(b=fi(g.type,g.key,g.props,null,m.mode,b),b.ref=Mr(m,f,g),b.return=m,m=b)}return o(m);case Qn:e:{for(T=g.key;f!==null;){if(f.key===T)if(f.tag===4&&f.stateNode.containerInfo===g.containerInfo&&f.stateNode.implementation===g.implementation){n(m,f.sibling),f=s(f,g.children||[]),f.return=m,m=f;break e}else{n(m,f);break}else t(m,f);f=f.sibling}f=Va(g,m.mode,b),f.return=m,m=f}return o(m);case Vt:return T=g._init,k(m,f,T(g._payload),b)}if(Br(g))return x(m,f,g,b);if(Pr(g))return w(m,f,g,b);qs(m,g)}return typeof g=="string"&&g!==""||typeof g=="number"?(g=""+g,f!==null&&f.tag===6?(n(m,f.sibling),f=s(f,g),f.return=m,m=f):(n(m,f),f=Qa(g,m.mode,b),f.return=m,m=f),o(m)):n(m,f)}return k}var yr=lf(!0),uf=lf(!1),Oi=vn(null),zi=null,tr=null,Ol=null;function zl(){Ol=tr=zi=null}function Al(e){var t=Oi.current;ge(Oi),e._currentValue=t}function Ao(e,t,n){for(;e!==null;){var r=e.alternate;if((e.childLanes&t)!==t?(e.childLanes|=t,r!==null&&(r.childLanes|=t)):r!==null&&(r.childLanes&t)!==t&&(r.childLanes|=t),e===n)break;e=e.return}}function cr(e,t){zi=e,Ol=tr=null,e=e.dependencies,e!==null&&e.firstContext!==null&&(e.lanes&t&&(Je=!0),e.firstContext=null)}function ft(e){var t=e._currentValue;if(Ol!==e)if(e={context:e,memoizedValue:t,next:null},tr===null){if(zi===null)throw Error(O(308));tr=e,zi.dependencies={lanes:0,firstContext:e}}else tr=tr.next=e;return t}var Sn=null;function Ml(e){Sn===null?Sn=[e]:Sn.push(e)}function cf(e,t,n,r){var s=t.interleaved;return s===null?(n.next=n,Ml(t)):(n.next=s.next,s.next=n),t.interleaved=n,Dt(e,r)}function Dt(e,t){e.lanes|=t;var n=e.alternate;for(n!==null&&(n.lanes|=t),n=e,e=e.return;e!==null;)e.childLanes|=t,n=e.alternate,n!==null&&(n.childLanes|=t),n=e,e=e.return;return n.tag===3?n.stateNode:null}var Kt=!1;function Rl(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function df(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,effects:e.effects})}function _t(e,t){return{eventTime:e,lane:t,tag:0,payload:null,callback:null,next:null}}function un(e,t,n){var r=e.updateQueue;if(r===null)return null;if(r=r.shared,ie&2){var s=r.pending;return s===null?t.next=t:(t.next=s.next,s.next=t),r.pending=t,Dt(e,n)}return s=r.interleaved,s===null?(t.next=t,Ml(r)):(t.next=s.next,s.next=t),r.interleaved=t,Dt(e,n)}function ai(e,t,n){if(t=t.updateQueue,t!==null&&(t=t.shared,(n&4194240)!==0)){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,xl(e,n)}}function Gu(e,t){var n=e.updateQueue,r=e.alternate;if(r!==null&&(r=r.updateQueue,n===r)){var s=null,i=null;if(n=n.firstBaseUpdate,n!==null){do{var o={eventTime:n.eventTime,lane:n.lane,tag:n.tag,payload:n.payload,callback:n.callback,next:null};i===null?s=i=o:i=i.next=o,n=n.next}while(n!==null);i===null?s=i=t:i=i.next=t}else s=i=t;n={baseState:r.baseState,firstBaseUpdate:s,lastBaseUpdate:i,shared:r.shared,effects:r.effects},e.updateQueue=n;return}e=n.lastBaseUpdate,e===null?n.firstBaseUpdate=t:e.next=t,n.lastBaseUpdate=t}function Ai(e,t,n,r){var s=e.updateQueue;Kt=!1;var i=s.firstBaseUpdate,o=s.lastBaseUpdate,l=s.shared.pending;if(l!==null){s.shared.pending=null;var u=l,c=u.next;u.next=null,o===null?i=c:o.next=c,o=u;var d=e.alternate;d!==null&&(d=d.updateQueue,l=d.lastBaseUpdate,l!==o&&(l===null?d.firstBaseUpdate=c:l.next=c,d.lastBaseUpdate=u))}if(i!==null){var p=s.baseState;o=0,d=c=u=null,l=i;do{var h=l.lane,v=l.eventTime;if((r&h)===h){d!==null&&(d=d.next={eventTime:v,lane:0,tag:l.tag,payload:l.payload,callback:l.callback,next:null});e:{var x=e,w=l;switch(h=t,v=n,w.tag){case 1:if(x=w.payload,typeof x=="function"){p=x.call(v,p,h);break e}p=x;break e;case 3:x.flags=x.flags&-65537|128;case 0:if(x=w.payload,h=typeof x=="function"?x.call(v,p,h):x,h==null)break e;p=je({},p,h);break e;case 2:Kt=!0}}l.callback!==null&&l.lane!==0&&(e.flags|=64,h=s.effects,h===null?s.effects=[l]:h.push(l))}else v={eventTime:v,lane:h,tag:l.tag,payload:l.payload,callback:l.callback,next:null},d===null?(c=d=v,u=p):d=d.next=v,o|=h;if(l=l.next,l===null){if(l=s.shared.pending,l===null)break;h=l,l=h.next,h.next=null,s.lastBaseUpdate=h,s.shared.pending=null}}while(1);if(d===null&&(u=p),s.baseState=u,s.firstBaseUpdate=c,s.lastBaseUpdate=d,t=s.shared.interleaved,t!==null){s=t;do o|=s.lane,s=s.next;while(s!==t)}else i===null&&(s.shared.lanes=0);In|=o,e.lanes=o,e.memoizedState=p}}function Yu(e,t,n){if(e=t.effects,t.effects=null,e!==null)for(t=0;t<e.length;t++){var r=e[t],s=r.callback;if(s!==null){if(r.callback=null,r=n,typeof s!="function")throw Error(O(191,s));s.call(r)}}}var Ps={},Ot=vn(Ps),gs=vn(Ps),ys=vn(Ps);function Cn(e){if(e===Ps)throw Error(O(174));return e}function Il(e,t){switch(pe(ys,t),pe(gs,e),pe(Ot,Ps),e=t.nodeType,e){case 9:case 11:t=(t=t.documentElement)?t.namespaceURI:fo(null,"");break;default:e=e===8?t.parentNode:t,t=e.namespaceURI||null,e=e.tagName,t=fo(t,e)}ge(Ot),pe(Ot,t)}function vr(){ge(Ot),ge(gs),ge(ys)}function ff(e){Cn(ys.current);var t=Cn(Ot.current),n=fo(t,e.type);t!==n&&(pe(gs,e),pe(Ot,n))}function _l(e){gs.current===e&&(ge(Ot),ge(gs))}var xe=vn(0);function Mi(e){for(var t=e;t!==null;){if(t.tag===13){var n=t.memoizedState;if(n!==null&&(n=n.dehydrated,n===null||n.data==="$?"||n.data==="$!"))return t}else if(t.tag===19&&t.memoizedProps.revealOrder!==void 0){if(t.flags&128)return t}else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}var $a=[];function Ll(){for(var e=0;e<$a.length;e++)$a[e]._workInProgressVersionPrimary=null;$a.length=0}var oi=Ut.ReactCurrentDispatcher,Ua=Ut.ReactCurrentBatchConfig,Rn=0,we=null,Oe=null,Me=null,Ri=!1,Zr=!1,vs=0,og=0;function De(){throw Error(O(321))}function Fl(e,t){if(t===null)return!1;for(var n=0;n<t.length&&n<e.length;n++)if(!Nt(e[n],t[n]))return!1;return!0}function Dl(e,t,n,r,s,i){if(Rn=i,we=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,oi.current=e===null||e.memoizedState===null?dg:fg,e=n(r,s),Zr){i=0;do{if(Zr=!1,vs=0,25<=i)throw Error(O(301));i+=1,Me=Oe=null,t.updateQueue=null,oi.current=pg,e=n(r,s)}while(Zr)}if(oi.current=Ii,t=Oe!==null&&Oe.next!==null,Rn=0,Me=Oe=we=null,Ri=!1,t)throw Error(O(300));return e}function $l(){var e=vs!==0;return vs=0,e}function Et(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return Me===null?we.memoizedState=Me=e:Me=Me.next=e,Me}function pt(){if(Oe===null){var e=we.alternate;e=e!==null?e.memoizedState:null}else e=Oe.next;var t=Me===null?we.memoizedState:Me.next;if(t!==null)Me=t,Oe=e;else{if(e===null)throw Error(O(310));Oe=e,e={memoizedState:Oe.memoizedState,baseState:Oe.baseState,baseQueue:Oe.baseQueue,queue:Oe.queue,next:null},Me===null?we.memoizedState=Me=e:Me=Me.next=e}return Me}function xs(e,t){return typeof t=="function"?t(e):t}function Wa(e){var t=pt(),n=t.queue;if(n===null)throw Error(O(311));n.lastRenderedReducer=e;var r=Oe,s=r.baseQueue,i=n.pending;if(i!==null){if(s!==null){var o=s.next;s.next=i.next,i.next=o}r.baseQueue=s=i,n.pending=null}if(s!==null){i=s.next,r=r.baseState;var l=o=null,u=null,c=i;do{var d=c.lane;if((Rn&d)===d)u!==null&&(u=u.next={lane:0,action:c.action,hasEagerState:c.hasEagerState,eagerState:c.eagerState,next:null}),r=c.hasEagerState?c.eagerState:e(r,c.action);else{var p={lane:d,action:c.action,hasEagerState:c.hasEagerState,eagerState:c.eagerState,next:null};u===null?(l=u=p,o=r):u=u.next=p,we.lanes|=d,In|=d}c=c.next}while(c!==null&&c!==i);u===null?o=r:u.next=l,Nt(r,t.memoizedState)||(Je=!0),t.memoizedState=r,t.baseState=o,t.baseQueue=u,n.lastRenderedState=r}if(e=n.interleaved,e!==null){s=e;do i=s.lane,we.lanes|=i,In|=i,s=s.next;while(s!==e)}else s===null&&(n.lanes=0);return[t.memoizedState,n.dispatch]}function Ba(e){var t=pt(),n=t.queue;if(n===null)throw Error(O(311));n.lastRenderedReducer=e;var r=n.dispatch,s=n.pending,i=t.memoizedState;if(s!==null){n.pending=null;var o=s=s.next;do i=e(i,o.action),o=o.next;while(o!==s);Nt(i,t.memoizedState)||(Je=!0),t.memoizedState=i,t.baseQueue===null&&(t.baseState=i),n.lastRenderedState=i}return[i,r]}function pf(){}function hf(e,t){var n=we,r=pt(),s=t(),i=!Nt(r.memoizedState,s);if(i&&(r.memoizedState=s,Je=!0),r=r.queue,Ul(yf.bind(null,n,r,e),[e]),r.getSnapshot!==t||i||Me!==null&&Me.memoizedState.tag&1){if(n.flags|=2048,ws(9,gf.bind(null,n,r,s,t),void 0,null),Re===null)throw Error(O(349));Rn&30||mf(n,t,s)}return s}function mf(e,t,n){e.flags|=16384,e={getSnapshot:t,value:n},t=we.updateQueue,t===null?(t={lastEffect:null,stores:null},we.updateQueue=t,t.stores=[e]):(n=t.stores,n===null?t.stores=[e]:n.push(e))}function gf(e,t,n,r){t.value=n,t.getSnapshot=r,vf(t)&&xf(e)}function yf(e,t,n){return n(function(){vf(t)&&xf(e)})}function vf(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!Nt(e,n)}catch{return!0}}function xf(e){var t=Dt(e,1);t!==null&&bt(t,e,1,-1)}function Ju(e){var t=Et();return typeof e=="function"&&(e=e()),t.memoizedState=t.baseState=e,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:xs,lastRenderedState:e},t.queue=e,e=e.dispatch=cg.bind(null,we,e),[t.memoizedState,e]}function ws(e,t,n,r){return e={tag:e,create:t,destroy:n,deps:r,next:null},t=we.updateQueue,t===null?(t={lastEffect:null,stores:null},we.updateQueue=t,t.lastEffect=e.next=e):(n=t.lastEffect,n===null?t.lastEffect=e.next=e:(r=n.next,n.next=e,e.next=r,t.lastEffect=e)),e}function wf(){return pt().memoizedState}function li(e,t,n,r){var s=Et();we.flags|=e,s.memoizedState=ws(1|t,n,void 0,r===void 0?null:r)}function ea(e,t,n,r){var s=pt();r=r===void 0?null:r;var i=void 0;if(Oe!==null){var o=Oe.memoizedState;if(i=o.destroy,r!==null&&Fl(r,o.deps)){s.memoizedState=ws(t,n,i,r);return}}we.flags|=e,s.memoizedState=ws(1|t,n,i,r)}function Xu(e,t){return li(8390656,8,e,t)}function Ul(e,t){return ea(2048,8,e,t)}function jf(e,t){return ea(4,2,e,t)}function bf(e,t){return ea(4,4,e,t)}function Nf(e,t){if(typeof t=="function")return e=e(),t(e),function(){t(null)};if(t!=null)return e=e(),t.current=e,function(){t.current=null}}function kf(e,t,n){return n=n!=null?n.concat([e]):null,ea(4,4,Nf.bind(null,t,e),n)}function Wl(){}function Sf(e,t){var n=pt();t=t===void 0?null:t;var r=n.memoizedState;return r!==null&&t!==null&&Fl(t,r[1])?r[0]:(n.memoizedState=[e,t],e)}function Cf(e,t){var n=pt();t=t===void 0?null:t;var r=n.memoizedState;return r!==null&&t!==null&&Fl(t,r[1])?r[0]:(e=e(),n.memoizedState=[e,t],e)}function Ef(e,t,n){return Rn&21?(Nt(n,t)||(n=zd(),we.lanes|=n,In|=n,e.baseState=!0),t):(e.baseState&&(e.baseState=!1,Je=!0),e.memoizedState=n)}function lg(e,t){var n=le;le=n!==0&&4>n?n:4,e(!0);var r=Ua.transition;Ua.transition={};try{e(!1),t()}finally{le=n,Ua.transition=r}}function Pf(){return pt().memoizedState}function ug(e,t,n){var r=dn(e);if(n={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null},Tf(e))Of(t,n);else if(n=cf(e,t,n,r),n!==null){var s=Qe();bt(n,e,r,s),zf(n,t,r)}}function cg(e,t,n){var r=dn(e),s={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null};if(Tf(e))Of(t,s);else{var i=e.alternate;if(e.lanes===0&&(i===null||i.lanes===0)&&(i=t.lastRenderedReducer,i!==null))try{var o=t.lastRenderedState,l=i(o,n);if(s.hasEagerState=!0,s.eagerState=l,Nt(l,o)){var u=t.interleaved;u===null?(s.next=s,Ml(t)):(s.next=u.next,u.next=s),t.interleaved=s;return}}catch{}finally{}n=cf(e,t,s,r),n!==null&&(s=Qe(),bt(n,e,r,s),zf(n,t,r))}}function Tf(e){var t=e.alternate;return e===we||t!==null&&t===we}function Of(e,t){Zr=Ri=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function zf(e,t,n){if(n&4194240){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,xl(e,n)}}var Ii={readContext:ft,useCallback:De,useContext:De,useEffect:De,useImperativeHandle:De,useInsertionEffect:De,useLayoutEffect:De,useMemo:De,useReducer:De,useRef:De,useState:De,useDebugValue:De,useDeferredValue:De,useTransition:De,useMutableSource:De,useSyncExternalStore:De,useId:De,unstable_isNewReconciler:!1},dg={readContext:ft,useCallback:function(e,t){return Et().memoizedState=[e,t===void 0?null:t],e},useContext:ft,useEffect:Xu,useImperativeHandle:function(e,t,n){return n=n!=null?n.concat([e]):null,li(4194308,4,Nf.bind(null,t,e),n)},useLayoutEffect:function(e,t){return li(4194308,4,e,t)},useInsertionEffect:function(e,t){return li(4,2,e,t)},useMemo:function(e,t){var n=Et();return t=t===void 0?null:t,e=e(),n.memoizedState=[e,t],e},useReducer:function(e,t,n){var r=Et();return t=n!==void 0?n(t):t,r.memoizedState=r.baseState=t,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:t},r.queue=e,e=e.dispatch=ug.bind(null,we,e),[r.memoizedState,e]},useRef:function(e){var t=Et();return e={current:e},t.memoizedState=e},useState:Ju,useDebugValue:Wl,useDeferredValue:function(e){return Et().memoizedState=e},useTransition:function(){var e=Ju(!1),t=e[0];return e=lg.bind(null,e[1]),Et().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,n){var r=we,s=Et();if(ye){if(n===void 0)throw Error(O(407));n=n()}else{if(n=t(),Re===null)throw Error(O(349));Rn&30||mf(r,t,n)}s.memoizedState=n;var i={value:n,getSnapshot:t};return s.queue=i,Xu(yf.bind(null,r,i,e),[e]),r.flags|=2048,ws(9,gf.bind(null,r,i,n,t),void 0,null),n},useId:function(){var e=Et(),t=Re.identifierPrefix;if(ye){var n=It,r=Rt;n=(r&~(1<<32-jt(r)-1)).toString(32)+n,t=":"+t+"R"+n,n=vs++,0<n&&(t+="H"+n.toString(32)),t+=":"}else n=og++,t=":"+t+"r"+n.toString(32)+":";return e.memoizedState=t},unstable_isNewReconciler:!1},fg={readContext:ft,useCallback:Sf,useContext:ft,useEffect:Ul,useImperativeHandle:kf,useInsertionEffect:jf,useLayoutEffect:bf,useMemo:Cf,useReducer:Wa,useRef:wf,useState:function(){return Wa(xs)},useDebugValue:Wl,useDeferredValue:function(e){var t=pt();return Ef(t,Oe.memoizedState,e)},useTransition:function(){var e=Wa(xs)[0],t=pt().memoizedState;return[e,t]},useMutableSource:pf,useSyncExternalStore:hf,useId:Pf,unstable_isNewReconciler:!1},pg={readContext:ft,useCallback:Sf,useContext:ft,useEffect:Ul,useImperativeHandle:kf,useInsertionEffect:jf,useLayoutEffect:bf,useMemo:Cf,useReducer:Ba,useRef:wf,useState:function(){return Ba(xs)},useDebugValue:Wl,useDeferredValue:function(e){var t=pt();return Oe===null?t.memoizedState=e:Ef(t,Oe.memoizedState,e)},useTransition:function(){var e=Ba(xs)[0],t=pt().memoizedState;return[e,t]},useMutableSource:pf,useSyncExternalStore:hf,useId:Pf,unstable_isNewReconciler:!1};function yt(e,t){if(e&&e.defaultProps){t=je({},t),e=e.defaultProps;for(var n in e)t[n]===void 0&&(t[n]=e[n]);return t}return t}function Mo(e,t,n,r){t=e.memoizedState,n=n(r,t),n=n==null?t:je({},t,n),e.memoizedState=n,e.lanes===0&&(e.updateQueue.baseState=n)}var ta={isMounted:function(e){return(e=e._reactInternals)?Fn(e)===e:!1},enqueueSetState:function(e,t,n){e=e._reactInternals;var r=Qe(),s=dn(e),i=_t(r,s);i.payload=t,n!=null&&(i.callback=n),t=un(e,i,s),t!==null&&(bt(t,e,s,r),ai(t,e,s))},enqueueReplaceState:function(e,t,n){e=e._reactInternals;var r=Qe(),s=dn(e),i=_t(r,s);i.tag=1,i.payload=t,n!=null&&(i.callback=n),t=un(e,i,s),t!==null&&(bt(t,e,s,r),ai(t,e,s))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var n=Qe(),r=dn(e),s=_t(n,r);s.tag=2,t!=null&&(s.callback=t),t=un(e,s,r),t!==null&&(bt(t,e,r,n),ai(t,e,r))}};function Zu(e,t,n,r,s,i,o){return e=e.stateNode,typeof e.shouldComponentUpdate=="function"?e.shouldComponentUpdate(r,i,o):t.prototype&&t.prototype.isPureReactComponent?!fs(n,r)||!fs(s,i):!0}function Af(e,t,n){var r=!1,s=gn,i=t.contextType;return typeof i=="object"&&i!==null?i=ft(i):(s=Ze(t)?An:We.current,r=t.contextTypes,i=(r=r!=null)?mr(e,s):gn),t=new t(n,i),e.memoizedState=t.state!==null&&t.state!==void 0?t.state:null,t.updater=ta,e.stateNode=t,t._reactInternals=e,r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=s,e.__reactInternalMemoizedMaskedChildContext=i),t}function ec(e,t,n,r){e=t.state,typeof t.componentWillReceiveProps=="function"&&t.componentWillReceiveProps(n,r),typeof t.UNSAFE_componentWillReceiveProps=="function"&&t.UNSAFE_componentWillReceiveProps(n,r),t.state!==e&&ta.enqueueReplaceState(t,t.state,null)}function Ro(e,t,n,r){var s=e.stateNode;s.props=n,s.state=e.memoizedState,s.refs={},Rl(e);var i=t.contextType;typeof i=="object"&&i!==null?s.context=ft(i):(i=Ze(t)?An:We.current,s.context=mr(e,i)),s.state=e.memoizedState,i=t.getDerivedStateFromProps,typeof i=="function"&&(Mo(e,t,i,n),s.state=e.memoizedState),typeof t.getDerivedStateFromProps=="function"||typeof s.getSnapshotBeforeUpdate=="function"||typeof s.UNSAFE_componentWillMount!="function"&&typeof s.componentWillMount!="function"||(t=s.state,typeof s.componentWillMount=="function"&&s.componentWillMount(),typeof s.UNSAFE_componentWillMount=="function"&&s.UNSAFE_componentWillMount(),t!==s.state&&ta.enqueueReplaceState(s,s.state,null),Ai(e,n,s,r),s.state=e.memoizedState),typeof s.componentDidMount=="function"&&(e.flags|=4194308)}function xr(e,t){try{var n="",r=t;do n+=Uh(r),r=r.return;while(r);var s=n}catch(i){s=`
39
+ Error generating stack: `+i.message+`
40
+ `+i.stack}return{value:e,source:t,stack:s,digest:null}}function Ha(e,t,n){return{value:e,source:null,stack:n??null,digest:t??null}}function Io(e,t){try{console.error(t.value)}catch(n){setTimeout(function(){throw n})}}var hg=typeof WeakMap=="function"?WeakMap:Map;function Mf(e,t,n){n=_t(-1,n),n.tag=3,n.payload={element:null};var r=t.value;return n.callback=function(){Li||(Li=!0,qo=r),Io(e,t)},n}function Rf(e,t,n){n=_t(-1,n),n.tag=3;var r=e.type.getDerivedStateFromError;if(typeof r=="function"){var s=t.value;n.payload=function(){return r(s)},n.callback=function(){Io(e,t)}}var i=e.stateNode;return i!==null&&typeof i.componentDidCatch=="function"&&(n.callback=function(){Io(e,t),typeof r!="function"&&(cn===null?cn=new Set([this]):cn.add(this));var o=t.stack;this.componentDidCatch(t.value,{componentStack:o!==null?o:""})}),n}function tc(e,t,n){var r=e.pingCache;if(r===null){r=e.pingCache=new hg;var s=new Set;r.set(t,s)}else s=r.get(t),s===void 0&&(s=new Set,r.set(t,s));s.has(n)||(s.add(n),e=Pg.bind(null,e,t,n),t.then(e,e))}function nc(e){do{var t;if((t=e.tag===13)&&(t=e.memoizedState,t=t!==null?t.dehydrated!==null:!0),t)return e;e=e.return}while(e!==null);return null}function rc(e,t,n,r,s){return e.mode&1?(e.flags|=65536,e.lanes=s,e):(e===t?e.flags|=65536:(e.flags|=128,n.flags|=131072,n.flags&=-52805,n.tag===1&&(n.alternate===null?n.tag=17:(t=_t(-1,1),t.tag=2,un(n,t,1))),n.lanes|=1),e)}var mg=Ut.ReactCurrentOwner,Je=!1;function He(e,t,n,r){t.child=e===null?uf(t,null,n,r):yr(t,e.child,n,r)}function sc(e,t,n,r,s){n=n.render;var i=t.ref;return cr(t,s),r=Dl(e,t,n,r,i,s),n=$l(),e!==null&&!Je?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~s,$t(e,t,s)):(ye&&n&&El(t),t.flags|=1,He(e,t,r,s),t.child)}function ic(e,t,n,r,s){if(e===null){var i=n.type;return typeof i=="function"&&!Yl(i)&&i.defaultProps===void 0&&n.compare===null&&n.defaultProps===void 0?(t.tag=15,t.type=i,If(e,t,i,r,s)):(e=fi(n.type,null,r,t,t.mode,s),e.ref=t.ref,e.return=t,t.child=e)}if(i=e.child,!(e.lanes&s)){var o=i.memoizedProps;if(n=n.compare,n=n!==null?n:fs,n(o,r)&&e.ref===t.ref)return $t(e,t,s)}return t.flags|=1,e=fn(i,r),e.ref=t.ref,e.return=t,t.child=e}function If(e,t,n,r,s){if(e!==null){var i=e.memoizedProps;if(fs(i,r)&&e.ref===t.ref)if(Je=!1,t.pendingProps=r=i,(e.lanes&s)!==0)e.flags&131072&&(Je=!0);else return t.lanes=e.lanes,$t(e,t,s)}return _o(e,t,n,r,s)}function _f(e,t,n){var r=t.pendingProps,s=r.children,i=e!==null?e.memoizedState:null;if(r.mode==="hidden")if(!(t.mode&1))t.memoizedState={baseLanes:0,cachePool:null,transitions:null},pe(rr,tt),tt|=n;else{if(!(n&1073741824))return e=i!==null?i.baseLanes|n:n,t.lanes=t.childLanes=1073741824,t.memoizedState={baseLanes:e,cachePool:null,transitions:null},t.updateQueue=null,pe(rr,tt),tt|=e,null;t.memoizedState={baseLanes:0,cachePool:null,transitions:null},r=i!==null?i.baseLanes:n,pe(rr,tt),tt|=r}else i!==null?(r=i.baseLanes|n,t.memoizedState=null):r=n,pe(rr,tt),tt|=r;return He(e,t,s,n),t.child}function Lf(e,t){var n=t.ref;(e===null&&n!==null||e!==null&&e.ref!==n)&&(t.flags|=512,t.flags|=2097152)}function _o(e,t,n,r,s){var i=Ze(n)?An:We.current;return i=mr(t,i),cr(t,s),n=Dl(e,t,n,r,i,s),r=$l(),e!==null&&!Je?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~s,$t(e,t,s)):(ye&&r&&El(t),t.flags|=1,He(e,t,n,s),t.child)}function ac(e,t,n,r,s){if(Ze(n)){var i=!0;Ei(t)}else i=!1;if(cr(t,s),t.stateNode===null)ui(e,t),Af(t,n,r),Ro(t,n,r,s),r=!0;else if(e===null){var o=t.stateNode,l=t.memoizedProps;o.props=l;var u=o.context,c=n.contextType;typeof c=="object"&&c!==null?c=ft(c):(c=Ze(n)?An:We.current,c=mr(t,c));var d=n.getDerivedStateFromProps,p=typeof d=="function"||typeof o.getSnapshotBeforeUpdate=="function";p||typeof o.UNSAFE_componentWillReceiveProps!="function"&&typeof o.componentWillReceiveProps!="function"||(l!==r||u!==c)&&ec(t,o,r,c),Kt=!1;var h=t.memoizedState;o.state=h,Ai(t,r,o,s),u=t.memoizedState,l!==r||h!==u||Xe.current||Kt?(typeof d=="function"&&(Mo(t,n,d,r),u=t.memoizedState),(l=Kt||Zu(t,n,l,r,h,u,c))?(p||typeof o.UNSAFE_componentWillMount!="function"&&typeof o.componentWillMount!="function"||(typeof o.componentWillMount=="function"&&o.componentWillMount(),typeof o.UNSAFE_componentWillMount=="function"&&o.UNSAFE_componentWillMount()),typeof o.componentDidMount=="function"&&(t.flags|=4194308)):(typeof o.componentDidMount=="function"&&(t.flags|=4194308),t.memoizedProps=r,t.memoizedState=u),o.props=r,o.state=u,o.context=c,r=l):(typeof o.componentDidMount=="function"&&(t.flags|=4194308),r=!1)}else{o=t.stateNode,df(e,t),l=t.memoizedProps,c=t.type===t.elementType?l:yt(t.type,l),o.props=c,p=t.pendingProps,h=o.context,u=n.contextType,typeof u=="object"&&u!==null?u=ft(u):(u=Ze(n)?An:We.current,u=mr(t,u));var v=n.getDerivedStateFromProps;(d=typeof v=="function"||typeof o.getSnapshotBeforeUpdate=="function")||typeof o.UNSAFE_componentWillReceiveProps!="function"&&typeof o.componentWillReceiveProps!="function"||(l!==p||h!==u)&&ec(t,o,r,u),Kt=!1,h=t.memoizedState,o.state=h,Ai(t,r,o,s);var x=t.memoizedState;l!==p||h!==x||Xe.current||Kt?(typeof v=="function"&&(Mo(t,n,v,r),x=t.memoizedState),(c=Kt||Zu(t,n,c,r,h,x,u)||!1)?(d||typeof o.UNSAFE_componentWillUpdate!="function"&&typeof o.componentWillUpdate!="function"||(typeof o.componentWillUpdate=="function"&&o.componentWillUpdate(r,x,u),typeof o.UNSAFE_componentWillUpdate=="function"&&o.UNSAFE_componentWillUpdate(r,x,u)),typeof o.componentDidUpdate=="function"&&(t.flags|=4),typeof o.getSnapshotBeforeUpdate=="function"&&(t.flags|=1024)):(typeof o.componentDidUpdate!="function"||l===e.memoizedProps&&h===e.memoizedState||(t.flags|=4),typeof o.getSnapshotBeforeUpdate!="function"||l===e.memoizedProps&&h===e.memoizedState||(t.flags|=1024),t.memoizedProps=r,t.memoizedState=x),o.props=r,o.state=x,o.context=u,r=c):(typeof o.componentDidUpdate!="function"||l===e.memoizedProps&&h===e.memoizedState||(t.flags|=4),typeof o.getSnapshotBeforeUpdate!="function"||l===e.memoizedProps&&h===e.memoizedState||(t.flags|=1024),r=!1)}return Lo(e,t,n,r,i,s)}function Lo(e,t,n,r,s,i){Lf(e,t);var o=(t.flags&128)!==0;if(!r&&!o)return s&&qu(t,n,!1),$t(e,t,i);r=t.stateNode,mg.current=t;var l=o&&typeof n.getDerivedStateFromError!="function"?null:r.render();return t.flags|=1,e!==null&&o?(t.child=yr(t,e.child,null,i),t.child=yr(t,null,l,i)):He(e,t,l,i),t.memoizedState=r.state,s&&qu(t,n,!0),t.child}function Ff(e){var t=e.stateNode;t.pendingContext?Hu(e,t.pendingContext,t.pendingContext!==t.context):t.context&&Hu(e,t.context,!1),Il(e,t.containerInfo)}function oc(e,t,n,r,s){return gr(),Tl(s),t.flags|=256,He(e,t,n,r),t.child}var Fo={dehydrated:null,treeContext:null,retryLane:0};function Do(e){return{baseLanes:e,cachePool:null,transitions:null}}function Df(e,t,n){var r=t.pendingProps,s=xe.current,i=!1,o=(t.flags&128)!==0,l;if((l=o)||(l=e!==null&&e.memoizedState===null?!1:(s&2)!==0),l?(i=!0,t.flags&=-129):(e===null||e.memoizedState!==null)&&(s|=1),pe(xe,s&1),e===null)return zo(t),e=t.memoizedState,e!==null&&(e=e.dehydrated,e!==null)?(t.mode&1?e.data==="$!"?t.lanes=8:t.lanes=1073741824:t.lanes=1,null):(o=r.children,e=r.fallback,i?(r=t.mode,i=t.child,o={mode:"hidden",children:o},!(r&1)&&i!==null?(i.childLanes=0,i.pendingProps=o):i=sa(o,r,0,null),e=zn(e,r,n,null),i.return=t,e.return=t,i.sibling=e,t.child=i,t.child.memoizedState=Do(n),t.memoizedState=Fo,e):Bl(t,o));if(s=e.memoizedState,s!==null&&(l=s.dehydrated,l!==null))return gg(e,t,o,r,l,s,n);if(i){i=r.fallback,o=t.mode,s=e.child,l=s.sibling;var u={mode:"hidden",children:r.children};return!(o&1)&&t.child!==s?(r=t.child,r.childLanes=0,r.pendingProps=u,t.deletions=null):(r=fn(s,u),r.subtreeFlags=s.subtreeFlags&14680064),l!==null?i=fn(l,i):(i=zn(i,o,n,null),i.flags|=2),i.return=t,r.return=t,r.sibling=i,t.child=r,r=i,i=t.child,o=e.child.memoizedState,o=o===null?Do(n):{baseLanes:o.baseLanes|n,cachePool:null,transitions:o.transitions},i.memoizedState=o,i.childLanes=e.childLanes&~n,t.memoizedState=Fo,r}return i=e.child,e=i.sibling,r=fn(i,{mode:"visible",children:r.children}),!(t.mode&1)&&(r.lanes=n),r.return=t,r.sibling=null,e!==null&&(n=t.deletions,n===null?(t.deletions=[e],t.flags|=16):n.push(e)),t.child=r,t.memoizedState=null,r}function Bl(e,t){return t=sa({mode:"visible",children:t},e.mode,0,null),t.return=e,e.child=t}function Qs(e,t,n,r){return r!==null&&Tl(r),yr(t,e.child,null,n),e=Bl(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function gg(e,t,n,r,s,i,o){if(n)return t.flags&256?(t.flags&=-257,r=Ha(Error(O(422))),Qs(e,t,o,r)):t.memoizedState!==null?(t.child=e.child,t.flags|=128,null):(i=r.fallback,s=t.mode,r=sa({mode:"visible",children:r.children},s,0,null),i=zn(i,s,o,null),i.flags|=2,r.return=t,i.return=t,r.sibling=i,t.child=r,t.mode&1&&yr(t,e.child,null,o),t.child.memoizedState=Do(o),t.memoizedState=Fo,i);if(!(t.mode&1))return Qs(e,t,o,null);if(s.data==="$!"){if(r=s.nextSibling&&s.nextSibling.dataset,r)var l=r.dgst;return r=l,i=Error(O(419)),r=Ha(i,r,void 0),Qs(e,t,o,r)}if(l=(o&e.childLanes)!==0,Je||l){if(r=Re,r!==null){switch(o&-o){case 4:s=2;break;case 16:s=8;break;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:s=32;break;case 536870912:s=268435456;break;default:s=0}s=s&(r.suspendedLanes|o)?0:s,s!==0&&s!==i.retryLane&&(i.retryLane=s,Dt(e,s),bt(r,e,s,-1))}return Gl(),r=Ha(Error(O(421))),Qs(e,t,o,r)}return s.data==="$?"?(t.flags|=128,t.child=e.child,t=Tg.bind(null,e),s._reactRetry=t,null):(e=i.treeContext,nt=ln(s.nextSibling),rt=t,ye=!0,wt=null,e!==null&&(lt[ut++]=Rt,lt[ut++]=It,lt[ut++]=Mn,Rt=e.id,It=e.overflow,Mn=t),t=Bl(t,r.children),t.flags|=4096,t)}function lc(e,t,n){e.lanes|=t;var r=e.alternate;r!==null&&(r.lanes|=t),Ao(e.return,t,n)}function qa(e,t,n,r,s){var i=e.memoizedState;i===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:r,tail:n,tailMode:s}:(i.isBackwards=t,i.rendering=null,i.renderingStartTime=0,i.last=r,i.tail=n,i.tailMode=s)}function $f(e,t,n){var r=t.pendingProps,s=r.revealOrder,i=r.tail;if(He(e,t,r.children,n),r=xe.current,r&2)r=r&1|2,t.flags|=128;else{if(e!==null&&e.flags&128)e:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&lc(e,n,t);else if(e.tag===19)lc(e,n,t);else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break e;for(;e.sibling===null;){if(e.return===null||e.return===t)break e;e=e.return}e.sibling.return=e.return,e=e.sibling}r&=1}if(pe(xe,r),!(t.mode&1))t.memoizedState=null;else switch(s){case"forwards":for(n=t.child,s=null;n!==null;)e=n.alternate,e!==null&&Mi(e)===null&&(s=n),n=n.sibling;n=s,n===null?(s=t.child,t.child=null):(s=n.sibling,n.sibling=null),qa(t,!1,s,n,i);break;case"backwards":for(n=null,s=t.child,t.child=null;s!==null;){if(e=s.alternate,e!==null&&Mi(e)===null){t.child=s;break}e=s.sibling,s.sibling=n,n=s,s=e}qa(t,!0,n,null,i);break;case"together":qa(t,!1,null,null,void 0);break;default:t.memoizedState=null}return t.child}function ui(e,t){!(t.mode&1)&&e!==null&&(e.alternate=null,t.alternate=null,t.flags|=2)}function $t(e,t,n){if(e!==null&&(t.dependencies=e.dependencies),In|=t.lanes,!(n&t.childLanes))return null;if(e!==null&&t.child!==e.child)throw Error(O(153));if(t.child!==null){for(e=t.child,n=fn(e,e.pendingProps),t.child=n,n.return=t;e.sibling!==null;)e=e.sibling,n=n.sibling=fn(e,e.pendingProps),n.return=t;n.sibling=null}return t.child}function yg(e,t,n){switch(t.tag){case 3:Ff(t),gr();break;case 5:ff(t);break;case 1:Ze(t.type)&&Ei(t);break;case 4:Il(t,t.stateNode.containerInfo);break;case 10:var r=t.type._context,s=t.memoizedProps.value;pe(Oi,r._currentValue),r._currentValue=s;break;case 13:if(r=t.memoizedState,r!==null)return r.dehydrated!==null?(pe(xe,xe.current&1),t.flags|=128,null):n&t.child.childLanes?Df(e,t,n):(pe(xe,xe.current&1),e=$t(e,t,n),e!==null?e.sibling:null);pe(xe,xe.current&1);break;case 19:if(r=(n&t.childLanes)!==0,e.flags&128){if(r)return $f(e,t,n);t.flags|=128}if(s=t.memoizedState,s!==null&&(s.rendering=null,s.tail=null,s.lastEffect=null),pe(xe,xe.current),r)break;return null;case 22:case 23:return t.lanes=0,_f(e,t,n)}return $t(e,t,n)}var Uf,$o,Wf,Bf;Uf=function(e,t){for(var n=t.child;n!==null;){if(n.tag===5||n.tag===6)e.appendChild(n.stateNode);else if(n.tag!==4&&n.child!==null){n.child.return=n,n=n.child;continue}if(n===t)break;for(;n.sibling===null;){if(n.return===null||n.return===t)return;n=n.return}n.sibling.return=n.return,n=n.sibling}};$o=function(){};Wf=function(e,t,n,r){var s=e.memoizedProps;if(s!==r){e=t.stateNode,Cn(Ot.current);var i=null;switch(n){case"input":s=oo(e,s),r=oo(e,r),i=[];break;case"select":s=je({},s,{value:void 0}),r=je({},r,{value:void 0}),i=[];break;case"textarea":s=co(e,s),r=co(e,r),i=[];break;default:typeof s.onClick!="function"&&typeof r.onClick=="function"&&(e.onclick=Si)}po(n,r);var o;n=null;for(c in s)if(!r.hasOwnProperty(c)&&s.hasOwnProperty(c)&&s[c]!=null)if(c==="style"){var l=s[c];for(o in l)l.hasOwnProperty(o)&&(n||(n={}),n[o]="")}else c!=="dangerouslySetInnerHTML"&&c!=="children"&&c!=="suppressContentEditableWarning"&&c!=="suppressHydrationWarning"&&c!=="autoFocus"&&(is.hasOwnProperty(c)?i||(i=[]):(i=i||[]).push(c,null));for(c in r){var u=r[c];if(l=s!=null?s[c]:void 0,r.hasOwnProperty(c)&&u!==l&&(u!=null||l!=null))if(c==="style")if(l){for(o in l)!l.hasOwnProperty(o)||u&&u.hasOwnProperty(o)||(n||(n={}),n[o]="");for(o in u)u.hasOwnProperty(o)&&l[o]!==u[o]&&(n||(n={}),n[o]=u[o])}else n||(i||(i=[]),i.push(c,n)),n=u;else c==="dangerouslySetInnerHTML"?(u=u?u.__html:void 0,l=l?l.__html:void 0,u!=null&&l!==u&&(i=i||[]).push(c,u)):c==="children"?typeof u!="string"&&typeof u!="number"||(i=i||[]).push(c,""+u):c!=="suppressContentEditableWarning"&&c!=="suppressHydrationWarning"&&(is.hasOwnProperty(c)?(u!=null&&c==="onScroll"&&me("scroll",e),i||l===u||(i=[])):(i=i||[]).push(c,u))}n&&(i=i||[]).push("style",n);var c=i;(t.updateQueue=c)&&(t.flags|=4)}};Bf=function(e,t,n,r){n!==r&&(t.flags|=4)};function Rr(e,t){if(!ye)switch(e.tailMode){case"hidden":t=e.tail;for(var n=null;t!==null;)t.alternate!==null&&(n=t),t=t.sibling;n===null?e.tail=null:n.sibling=null;break;case"collapsed":n=e.tail;for(var r=null;n!==null;)n.alternate!==null&&(r=n),n=n.sibling;r===null?t||e.tail===null?e.tail=null:e.tail.sibling=null:r.sibling=null}}function $e(e){var t=e.alternate!==null&&e.alternate.child===e.child,n=0,r=0;if(t)for(var s=e.child;s!==null;)n|=s.lanes|s.childLanes,r|=s.subtreeFlags&14680064,r|=s.flags&14680064,s.return=e,s=s.sibling;else for(s=e.child;s!==null;)n|=s.lanes|s.childLanes,r|=s.subtreeFlags,r|=s.flags,s.return=e,s=s.sibling;return e.subtreeFlags|=r,e.childLanes=n,t}function vg(e,t,n){var r=t.pendingProps;switch(Pl(t),t.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return $e(t),null;case 1:return Ze(t.type)&&Ci(),$e(t),null;case 3:return r=t.stateNode,vr(),ge(Xe),ge(We),Ll(),r.pendingContext&&(r.context=r.pendingContext,r.pendingContext=null),(e===null||e.child===null)&&(Hs(t)?t.flags|=4:e===null||e.memoizedState.isDehydrated&&!(t.flags&256)||(t.flags|=1024,wt!==null&&(Ko(wt),wt=null))),$o(e,t),$e(t),null;case 5:_l(t);var s=Cn(ys.current);if(n=t.type,e!==null&&t.stateNode!=null)Wf(e,t,n,r,s),e.ref!==t.ref&&(t.flags|=512,t.flags|=2097152);else{if(!r){if(t.stateNode===null)throw Error(O(166));return $e(t),null}if(e=Cn(Ot.current),Hs(t)){r=t.stateNode,n=t.type;var i=t.memoizedProps;switch(r[Pt]=t,r[ms]=i,e=(t.mode&1)!==0,n){case"dialog":me("cancel",r),me("close",r);break;case"iframe":case"object":case"embed":me("load",r);break;case"video":case"audio":for(s=0;s<qr.length;s++)me(qr[s],r);break;case"source":me("error",r);break;case"img":case"image":case"link":me("error",r),me("load",r);break;case"details":me("toggle",r);break;case"input":yu(r,i),me("invalid",r);break;case"select":r._wrapperState={wasMultiple:!!i.multiple},me("invalid",r);break;case"textarea":xu(r,i),me("invalid",r)}po(n,i),s=null;for(var o in i)if(i.hasOwnProperty(o)){var l=i[o];o==="children"?typeof l=="string"?r.textContent!==l&&(i.suppressHydrationWarning!==!0&&Bs(r.textContent,l,e),s=["children",l]):typeof l=="number"&&r.textContent!==""+l&&(i.suppressHydrationWarning!==!0&&Bs(r.textContent,l,e),s=["children",""+l]):is.hasOwnProperty(o)&&l!=null&&o==="onScroll"&&me("scroll",r)}switch(n){case"input":Is(r),vu(r,i,!0);break;case"textarea":Is(r),wu(r);break;case"select":case"option":break;default:typeof i.onClick=="function"&&(r.onclick=Si)}r=s,t.updateQueue=r,r!==null&&(t.flags|=4)}else{o=s.nodeType===9?s:s.ownerDocument,e==="http://www.w3.org/1999/xhtml"&&(e=gd(n)),e==="http://www.w3.org/1999/xhtml"?n==="script"?(e=o.createElement("div"),e.innerHTML="<script><\/script>",e=e.removeChild(e.firstChild)):typeof r.is=="string"?e=o.createElement(n,{is:r.is}):(e=o.createElement(n),n==="select"&&(o=e,r.multiple?o.multiple=!0:r.size&&(o.size=r.size))):e=o.createElementNS(e,n),e[Pt]=t,e[ms]=r,Uf(e,t,!1,!1),t.stateNode=e;e:{switch(o=ho(n,r),n){case"dialog":me("cancel",e),me("close",e),s=r;break;case"iframe":case"object":case"embed":me("load",e),s=r;break;case"video":case"audio":for(s=0;s<qr.length;s++)me(qr[s],e);s=r;break;case"source":me("error",e),s=r;break;case"img":case"image":case"link":me("error",e),me("load",e),s=r;break;case"details":me("toggle",e),s=r;break;case"input":yu(e,r),s=oo(e,r),me("invalid",e);break;case"option":s=r;break;case"select":e._wrapperState={wasMultiple:!!r.multiple},s=je({},r,{value:void 0}),me("invalid",e);break;case"textarea":xu(e,r),s=co(e,r),me("invalid",e);break;default:s=r}po(n,s),l=s;for(i in l)if(l.hasOwnProperty(i)){var u=l[i];i==="style"?xd(e,u):i==="dangerouslySetInnerHTML"?(u=u?u.__html:void 0,u!=null&&yd(e,u)):i==="children"?typeof u=="string"?(n!=="textarea"||u!=="")&&as(e,u):typeof u=="number"&&as(e,""+u):i!=="suppressContentEditableWarning"&&i!=="suppressHydrationWarning"&&i!=="autoFocus"&&(is.hasOwnProperty(i)?u!=null&&i==="onScroll"&&me("scroll",e):u!=null&&pl(e,i,u,o))}switch(n){case"input":Is(e),vu(e,r,!1);break;case"textarea":Is(e),wu(e);break;case"option":r.value!=null&&e.setAttribute("value",""+mn(r.value));break;case"select":e.multiple=!!r.multiple,i=r.value,i!=null?ar(e,!!r.multiple,i,!1):r.defaultValue!=null&&ar(e,!!r.multiple,r.defaultValue,!0);break;default:typeof s.onClick=="function"&&(e.onclick=Si)}switch(n){case"button":case"input":case"select":case"textarea":r=!!r.autoFocus;break e;case"img":r=!0;break e;default:r=!1}}r&&(t.flags|=4)}t.ref!==null&&(t.flags|=512,t.flags|=2097152)}return $e(t),null;case 6:if(e&&t.stateNode!=null)Bf(e,t,e.memoizedProps,r);else{if(typeof r!="string"&&t.stateNode===null)throw Error(O(166));if(n=Cn(ys.current),Cn(Ot.current),Hs(t)){if(r=t.stateNode,n=t.memoizedProps,r[Pt]=t,(i=r.nodeValue!==n)&&(e=rt,e!==null))switch(e.tag){case 3:Bs(r.nodeValue,n,(e.mode&1)!==0);break;case 5:e.memoizedProps.suppressHydrationWarning!==!0&&Bs(r.nodeValue,n,(e.mode&1)!==0)}i&&(t.flags|=4)}else r=(n.nodeType===9?n:n.ownerDocument).createTextNode(r),r[Pt]=t,t.stateNode=r}return $e(t),null;case 13:if(ge(xe),r=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(ye&&nt!==null&&t.mode&1&&!(t.flags&128))of(),gr(),t.flags|=98560,i=!1;else if(i=Hs(t),r!==null&&r.dehydrated!==null){if(e===null){if(!i)throw Error(O(318));if(i=t.memoizedState,i=i!==null?i.dehydrated:null,!i)throw Error(O(317));i[Pt]=t}else gr(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;$e(t),i=!1}else wt!==null&&(Ko(wt),wt=null),i=!0;if(!i)return t.flags&65536?t:null}return t.flags&128?(t.lanes=n,t):(r=r!==null,r!==(e!==null&&e.memoizedState!==null)&&r&&(t.child.flags|=8192,t.mode&1&&(e===null||xe.current&1?ze===0&&(ze=3):Gl())),t.updateQueue!==null&&(t.flags|=4),$e(t),null);case 4:return vr(),$o(e,t),e===null&&ps(t.stateNode.containerInfo),$e(t),null;case 10:return Al(t.type._context),$e(t),null;case 17:return Ze(t.type)&&Ci(),$e(t),null;case 19:if(ge(xe),i=t.memoizedState,i===null)return $e(t),null;if(r=(t.flags&128)!==0,o=i.rendering,o===null)if(r)Rr(i,!1);else{if(ze!==0||e!==null&&e.flags&128)for(e=t.child;e!==null;){if(o=Mi(e),o!==null){for(t.flags|=128,Rr(i,!1),r=o.updateQueue,r!==null&&(t.updateQueue=r,t.flags|=4),t.subtreeFlags=0,r=n,n=t.child;n!==null;)i=n,e=r,i.flags&=14680066,o=i.alternate,o===null?(i.childLanes=0,i.lanes=e,i.child=null,i.subtreeFlags=0,i.memoizedProps=null,i.memoizedState=null,i.updateQueue=null,i.dependencies=null,i.stateNode=null):(i.childLanes=o.childLanes,i.lanes=o.lanes,i.child=o.child,i.subtreeFlags=0,i.deletions=null,i.memoizedProps=o.memoizedProps,i.memoizedState=o.memoizedState,i.updateQueue=o.updateQueue,i.type=o.type,e=o.dependencies,i.dependencies=e===null?null:{lanes:e.lanes,firstContext:e.firstContext}),n=n.sibling;return pe(xe,xe.current&1|2),t.child}e=e.sibling}i.tail!==null&&Se()>wr&&(t.flags|=128,r=!0,Rr(i,!1),t.lanes=4194304)}else{if(!r)if(e=Mi(o),e!==null){if(t.flags|=128,r=!0,n=e.updateQueue,n!==null&&(t.updateQueue=n,t.flags|=4),Rr(i,!0),i.tail===null&&i.tailMode==="hidden"&&!o.alternate&&!ye)return $e(t),null}else 2*Se()-i.renderingStartTime>wr&&n!==1073741824&&(t.flags|=128,r=!0,Rr(i,!1),t.lanes=4194304);i.isBackwards?(o.sibling=t.child,t.child=o):(n=i.last,n!==null?n.sibling=o:t.child=o,i.last=o)}return i.tail!==null?(t=i.tail,i.rendering=t,i.tail=t.sibling,i.renderingStartTime=Se(),t.sibling=null,n=xe.current,pe(xe,r?n&1|2:n&1),t):($e(t),null);case 22:case 23:return Kl(),r=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==r&&(t.flags|=8192),r&&t.mode&1?tt&1073741824&&($e(t),t.subtreeFlags&6&&(t.flags|=8192)):$e(t),null;case 24:return null;case 25:return null}throw Error(O(156,t.tag))}function xg(e,t){switch(Pl(t),t.tag){case 1:return Ze(t.type)&&Ci(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return vr(),ge(Xe),ge(We),Ll(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 5:return _l(t),null;case 13:if(ge(xe),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(O(340));gr()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return ge(xe),null;case 4:return vr(),null;case 10:return Al(t.type._context),null;case 22:case 23:return Kl(),null;case 24:return null;default:return null}}var Vs=!1,Ue=!1,wg=typeof WeakSet=="function"?WeakSet:Set,L=null;function nr(e,t){var n=e.ref;if(n!==null)if(typeof n=="function")try{n(null)}catch(r){Ne(e,t,r)}else n.current=null}function Uo(e,t,n){try{n()}catch(r){Ne(e,t,r)}}var uc=!1;function jg(e,t){if(ko=bi,e=Vd(),Cl(e)){if("selectionStart"in e)var n={start:e.selectionStart,end:e.selectionEnd};else e:{n=(n=e.ownerDocument)&&n.defaultView||window;var r=n.getSelection&&n.getSelection();if(r&&r.rangeCount!==0){n=r.anchorNode;var s=r.anchorOffset,i=r.focusNode;r=r.focusOffset;try{n.nodeType,i.nodeType}catch{n=null;break e}var o=0,l=-1,u=-1,c=0,d=0,p=e,h=null;t:for(;;){for(var v;p!==n||s!==0&&p.nodeType!==3||(l=o+s),p!==i||r!==0&&p.nodeType!==3||(u=o+r),p.nodeType===3&&(o+=p.nodeValue.length),(v=p.firstChild)!==null;)h=p,p=v;for(;;){if(p===e)break t;if(h===n&&++c===s&&(l=o),h===i&&++d===r&&(u=o),(v=p.nextSibling)!==null)break;p=h,h=p.parentNode}p=v}n=l===-1||u===-1?null:{start:l,end:u}}else n=null}n=n||{start:0,end:0}}else n=null;for(So={focusedElem:e,selectionRange:n},bi=!1,L=t;L!==null;)if(t=L,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,L=e;else for(;L!==null;){t=L;try{var x=t.alternate;if(t.flags&1024)switch(t.tag){case 0:case 11:case 15:break;case 1:if(x!==null){var w=x.memoizedProps,k=x.memoizedState,m=t.stateNode,f=m.getSnapshotBeforeUpdate(t.elementType===t.type?w:yt(t.type,w),k);m.__reactInternalSnapshotBeforeUpdate=f}break;case 3:var g=t.stateNode.containerInfo;g.nodeType===1?g.textContent="":g.nodeType===9&&g.documentElement&&g.removeChild(g.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(O(163))}}catch(b){Ne(t,t.return,b)}if(e=t.sibling,e!==null){e.return=t.return,L=e;break}L=t.return}return x=uc,uc=!1,x}function es(e,t,n){var r=t.updateQueue;if(r=r!==null?r.lastEffect:null,r!==null){var s=r=r.next;do{if((s.tag&e)===e){var i=s.destroy;s.destroy=void 0,i!==void 0&&Uo(t,n,i)}s=s.next}while(s!==r)}}function na(e,t){if(t=t.updateQueue,t=t!==null?t.lastEffect:null,t!==null){var n=t=t.next;do{if((n.tag&e)===e){var r=n.create;n.destroy=r()}n=n.next}while(n!==t)}}function Wo(e){var t=e.ref;if(t!==null){var n=e.stateNode;switch(e.tag){case 5:e=n;break;default:e=n}typeof t=="function"?t(e):t.current=e}}function Hf(e){var t=e.alternate;t!==null&&(e.alternate=null,Hf(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[Pt],delete t[ms],delete t[Po],delete t[rg],delete t[sg])),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}function qf(e){return e.tag===5||e.tag===3||e.tag===4}function cc(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||qf(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.flags&2||e.child===null||e.tag===4)continue e;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function Bo(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.nodeType===8?n.parentNode.insertBefore(e,t):n.insertBefore(e,t):(n.nodeType===8?(t=n.parentNode,t.insertBefore(e,n)):(t=n,t.appendChild(e)),n=n._reactRootContainer,n!=null||t.onclick!==null||(t.onclick=Si));else if(r!==4&&(e=e.child,e!==null))for(Bo(e,t,n),e=e.sibling;e!==null;)Bo(e,t,n),e=e.sibling}function Ho(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.insertBefore(e,t):n.appendChild(e);else if(r!==4&&(e=e.child,e!==null))for(Ho(e,t,n),e=e.sibling;e!==null;)Ho(e,t,n),e=e.sibling}var Ie=null,xt=!1;function qt(e,t,n){for(n=n.child;n!==null;)Qf(e,t,n),n=n.sibling}function Qf(e,t,n){if(Tt&&typeof Tt.onCommitFiberUnmount=="function")try{Tt.onCommitFiberUnmount(Ki,n)}catch{}switch(n.tag){case 5:Ue||nr(n,t);case 6:var r=Ie,s=xt;Ie=null,qt(e,t,n),Ie=r,xt=s,Ie!==null&&(xt?(e=Ie,n=n.stateNode,e.nodeType===8?e.parentNode.removeChild(n):e.removeChild(n)):Ie.removeChild(n.stateNode));break;case 18:Ie!==null&&(xt?(e=Ie,n=n.stateNode,e.nodeType===8?Fa(e.parentNode,n):e.nodeType===1&&Fa(e,n),cs(e)):Fa(Ie,n.stateNode));break;case 4:r=Ie,s=xt,Ie=n.stateNode.containerInfo,xt=!0,qt(e,t,n),Ie=r,xt=s;break;case 0:case 11:case 14:case 15:if(!Ue&&(r=n.updateQueue,r!==null&&(r=r.lastEffect,r!==null))){s=r=r.next;do{var i=s,o=i.destroy;i=i.tag,o!==void 0&&(i&2||i&4)&&Uo(n,t,o),s=s.next}while(s!==r)}qt(e,t,n);break;case 1:if(!Ue&&(nr(n,t),r=n.stateNode,typeof r.componentWillUnmount=="function"))try{r.props=n.memoizedProps,r.state=n.memoizedState,r.componentWillUnmount()}catch(l){Ne(n,t,l)}qt(e,t,n);break;case 21:qt(e,t,n);break;case 22:n.mode&1?(Ue=(r=Ue)||n.memoizedState!==null,qt(e,t,n),Ue=r):qt(e,t,n);break;default:qt(e,t,n)}}function dc(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var n=e.stateNode;n===null&&(n=e.stateNode=new wg),t.forEach(function(r){var s=Og.bind(null,e,r);n.has(r)||(n.add(r),r.then(s,s))})}}function mt(e,t){var n=t.deletions;if(n!==null)for(var r=0;r<n.length;r++){var s=n[r];try{var i=e,o=t,l=o;e:for(;l!==null;){switch(l.tag){case 5:Ie=l.stateNode,xt=!1;break e;case 3:Ie=l.stateNode.containerInfo,xt=!0;break e;case 4:Ie=l.stateNode.containerInfo,xt=!0;break e}l=l.return}if(Ie===null)throw Error(O(160));Qf(i,o,s),Ie=null,xt=!1;var u=s.alternate;u!==null&&(u.return=null),s.return=null}catch(c){Ne(s,t,c)}}if(t.subtreeFlags&12854)for(t=t.child;t!==null;)Vf(t,e),t=t.sibling}function Vf(e,t){var n=e.alternate,r=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:if(mt(t,e),Ct(e),r&4){try{es(3,e,e.return),na(3,e)}catch(w){Ne(e,e.return,w)}try{es(5,e,e.return)}catch(w){Ne(e,e.return,w)}}break;case 1:mt(t,e),Ct(e),r&512&&n!==null&&nr(n,n.return);break;case 5:if(mt(t,e),Ct(e),r&512&&n!==null&&nr(n,n.return),e.flags&32){var s=e.stateNode;try{as(s,"")}catch(w){Ne(e,e.return,w)}}if(r&4&&(s=e.stateNode,s!=null)){var i=e.memoizedProps,o=n!==null?n.memoizedProps:i,l=e.type,u=e.updateQueue;if(e.updateQueue=null,u!==null)try{l==="input"&&i.type==="radio"&&i.name!=null&&hd(s,i),ho(l,o);var c=ho(l,i);for(o=0;o<u.length;o+=2){var d=u[o],p=u[o+1];d==="style"?xd(s,p):d==="dangerouslySetInnerHTML"?yd(s,p):d==="children"?as(s,p):pl(s,d,p,c)}switch(l){case"input":lo(s,i);break;case"textarea":md(s,i);break;case"select":var h=s._wrapperState.wasMultiple;s._wrapperState.wasMultiple=!!i.multiple;var v=i.value;v!=null?ar(s,!!i.multiple,v,!1):h!==!!i.multiple&&(i.defaultValue!=null?ar(s,!!i.multiple,i.defaultValue,!0):ar(s,!!i.multiple,i.multiple?[]:"",!1))}s[ms]=i}catch(w){Ne(e,e.return,w)}}break;case 6:if(mt(t,e),Ct(e),r&4){if(e.stateNode===null)throw Error(O(162));s=e.stateNode,i=e.memoizedProps;try{s.nodeValue=i}catch(w){Ne(e,e.return,w)}}break;case 3:if(mt(t,e),Ct(e),r&4&&n!==null&&n.memoizedState.isDehydrated)try{cs(t.containerInfo)}catch(w){Ne(e,e.return,w)}break;case 4:mt(t,e),Ct(e);break;case 13:mt(t,e),Ct(e),s=e.child,s.flags&8192&&(i=s.memoizedState!==null,s.stateNode.isHidden=i,!i||s.alternate!==null&&s.alternate.memoizedState!==null||(Ql=Se())),r&4&&dc(e);break;case 22:if(d=n!==null&&n.memoizedState!==null,e.mode&1?(Ue=(c=Ue)||d,mt(t,e),Ue=c):mt(t,e),Ct(e),r&8192){if(c=e.memoizedState!==null,(e.stateNode.isHidden=c)&&!d&&e.mode&1)for(L=e,d=e.child;d!==null;){for(p=L=d;L!==null;){switch(h=L,v=h.child,h.tag){case 0:case 11:case 14:case 15:es(4,h,h.return);break;case 1:nr(h,h.return);var x=h.stateNode;if(typeof x.componentWillUnmount=="function"){r=h,n=h.return;try{t=r,x.props=t.memoizedProps,x.state=t.memoizedState,x.componentWillUnmount()}catch(w){Ne(r,n,w)}}break;case 5:nr(h,h.return);break;case 22:if(h.memoizedState!==null){pc(p);continue}}v!==null?(v.return=h,L=v):pc(p)}d=d.sibling}e:for(d=null,p=e;;){if(p.tag===5){if(d===null){d=p;try{s=p.stateNode,c?(i=s.style,typeof i.setProperty=="function"?i.setProperty("display","none","important"):i.display="none"):(l=p.stateNode,u=p.memoizedProps.style,o=u!=null&&u.hasOwnProperty("display")?u.display:null,l.style.display=vd("display",o))}catch(w){Ne(e,e.return,w)}}}else if(p.tag===6){if(d===null)try{p.stateNode.nodeValue=c?"":p.memoizedProps}catch(w){Ne(e,e.return,w)}}else if((p.tag!==22&&p.tag!==23||p.memoizedState===null||p===e)&&p.child!==null){p.child.return=p,p=p.child;continue}if(p===e)break e;for(;p.sibling===null;){if(p.return===null||p.return===e)break e;d===p&&(d=null),p=p.return}d===p&&(d=null),p.sibling.return=p.return,p=p.sibling}}break;case 19:mt(t,e),Ct(e),r&4&&dc(e);break;case 21:break;default:mt(t,e),Ct(e)}}function Ct(e){var t=e.flags;if(t&2){try{e:{for(var n=e.return;n!==null;){if(qf(n)){var r=n;break e}n=n.return}throw Error(O(160))}switch(r.tag){case 5:var s=r.stateNode;r.flags&32&&(as(s,""),r.flags&=-33);var i=cc(e);Ho(e,i,s);break;case 3:case 4:var o=r.stateNode.containerInfo,l=cc(e);Bo(e,l,o);break;default:throw Error(O(161))}}catch(u){Ne(e,e.return,u)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function bg(e,t,n){L=e,Kf(e)}function Kf(e,t,n){for(var r=(e.mode&1)!==0;L!==null;){var s=L,i=s.child;if(s.tag===22&&r){var o=s.memoizedState!==null||Vs;if(!o){var l=s.alternate,u=l!==null&&l.memoizedState!==null||Ue;l=Vs;var c=Ue;if(Vs=o,(Ue=u)&&!c)for(L=s;L!==null;)o=L,u=o.child,o.tag===22&&o.memoizedState!==null?hc(s):u!==null?(u.return=o,L=u):hc(s);for(;i!==null;)L=i,Kf(i),i=i.sibling;L=s,Vs=l,Ue=c}fc(e)}else s.subtreeFlags&8772&&i!==null?(i.return=s,L=i):fc(e)}}function fc(e){for(;L!==null;){var t=L;if(t.flags&8772){var n=t.alternate;try{if(t.flags&8772)switch(t.tag){case 0:case 11:case 15:Ue||na(5,t);break;case 1:var r=t.stateNode;if(t.flags&4&&!Ue)if(n===null)r.componentDidMount();else{var s=t.elementType===t.type?n.memoizedProps:yt(t.type,n.memoizedProps);r.componentDidUpdate(s,n.memoizedState,r.__reactInternalSnapshotBeforeUpdate)}var i=t.updateQueue;i!==null&&Yu(t,i,r);break;case 3:var o=t.updateQueue;if(o!==null){if(n=null,t.child!==null)switch(t.child.tag){case 5:n=t.child.stateNode;break;case 1:n=t.child.stateNode}Yu(t,o,n)}break;case 5:var l=t.stateNode;if(n===null&&t.flags&4){n=l;var u=t.memoizedProps;switch(t.type){case"button":case"input":case"select":case"textarea":u.autoFocus&&n.focus();break;case"img":u.src&&(n.src=u.src)}}break;case 6:break;case 4:break;case 12:break;case 13:if(t.memoizedState===null){var c=t.alternate;if(c!==null){var d=c.memoizedState;if(d!==null){var p=d.dehydrated;p!==null&&cs(p)}}}break;case 19:case 17:case 21:case 22:case 23:case 25:break;default:throw Error(O(163))}Ue||t.flags&512&&Wo(t)}catch(h){Ne(t,t.return,h)}}if(t===e){L=null;break}if(n=t.sibling,n!==null){n.return=t.return,L=n;break}L=t.return}}function pc(e){for(;L!==null;){var t=L;if(t===e){L=null;break}var n=t.sibling;if(n!==null){n.return=t.return,L=n;break}L=t.return}}function hc(e){for(;L!==null;){var t=L;try{switch(t.tag){case 0:case 11:case 15:var n=t.return;try{na(4,t)}catch(u){Ne(t,n,u)}break;case 1:var r=t.stateNode;if(typeof r.componentDidMount=="function"){var s=t.return;try{r.componentDidMount()}catch(u){Ne(t,s,u)}}var i=t.return;try{Wo(t)}catch(u){Ne(t,i,u)}break;case 5:var o=t.return;try{Wo(t)}catch(u){Ne(t,o,u)}}}catch(u){Ne(t,t.return,u)}if(t===e){L=null;break}var l=t.sibling;if(l!==null){l.return=t.return,L=l;break}L=t.return}}var Ng=Math.ceil,_i=Ut.ReactCurrentDispatcher,Hl=Ut.ReactCurrentOwner,dt=Ut.ReactCurrentBatchConfig,ie=0,Re=null,Ee=null,_e=0,tt=0,rr=vn(0),ze=0,js=null,In=0,ra=0,ql=0,ts=null,Ye=null,Ql=0,wr=1/0,zt=null,Li=!1,qo=null,cn=null,Ks=!1,nn=null,Fi=0,ns=0,Qo=null,ci=-1,di=0;function Qe(){return ie&6?Se():ci!==-1?ci:ci=Se()}function dn(e){return e.mode&1?ie&2&&_e!==0?_e&-_e:ag.transition!==null?(di===0&&(di=zd()),di):(e=le,e!==0||(e=window.event,e=e===void 0?16:Fd(e.type)),e):1}function bt(e,t,n,r){if(50<ns)throw ns=0,Qo=null,Error(O(185));Ss(e,n,r),(!(ie&2)||e!==Re)&&(e===Re&&(!(ie&2)&&(ra|=n),ze===4&&Zt(e,_e)),et(e,r),n===1&&ie===0&&!(t.mode&1)&&(wr=Se()+500,Zi&&xn()))}function et(e,t){var n=e.callbackNode;am(e,t);var r=ji(e,e===Re?_e:0);if(r===0)n!==null&&Nu(n),e.callbackNode=null,e.callbackPriority=0;else if(t=r&-r,e.callbackPriority!==t){if(n!=null&&Nu(n),t===1)e.tag===0?ig(mc.bind(null,e)):rf(mc.bind(null,e)),tg(function(){!(ie&6)&&xn()}),n=null;else{switch(Ad(r)){case 1:n=vl;break;case 4:n=Td;break;case 16:n=wi;break;case 536870912:n=Od;break;default:n=wi}n=np(n,Gf.bind(null,e))}e.callbackPriority=t,e.callbackNode=n}}function Gf(e,t){if(ci=-1,di=0,ie&6)throw Error(O(327));var n=e.callbackNode;if(dr()&&e.callbackNode!==n)return null;var r=ji(e,e===Re?_e:0);if(r===0)return null;if(r&30||r&e.expiredLanes||t)t=Di(e,r);else{t=r;var s=ie;ie|=2;var i=Jf();(Re!==e||_e!==t)&&(zt=null,wr=Se()+500,On(e,t));do try{Cg();break}catch(l){Yf(e,l)}while(1);zl(),_i.current=i,ie=s,Ee!==null?t=0:(Re=null,_e=0,t=ze)}if(t!==0){if(t===2&&(s=xo(e),s!==0&&(r=s,t=Vo(e,s))),t===1)throw n=js,On(e,0),Zt(e,r),et(e,Se()),n;if(t===6)Zt(e,r);else{if(s=e.current.alternate,!(r&30)&&!kg(s)&&(t=Di(e,r),t===2&&(i=xo(e),i!==0&&(r=i,t=Vo(e,i))),t===1))throw n=js,On(e,0),Zt(e,r),et(e,Se()),n;switch(e.finishedWork=s,e.finishedLanes=r,t){case 0:case 1:throw Error(O(345));case 2:Nn(e,Ye,zt);break;case 3:if(Zt(e,r),(r&130023424)===r&&(t=Ql+500-Se(),10<t)){if(ji(e,0)!==0)break;if(s=e.suspendedLanes,(s&r)!==r){Qe(),e.pingedLanes|=e.suspendedLanes&s;break}e.timeoutHandle=Eo(Nn.bind(null,e,Ye,zt),t);break}Nn(e,Ye,zt);break;case 4:if(Zt(e,r),(r&4194240)===r)break;for(t=e.eventTimes,s=-1;0<r;){var o=31-jt(r);i=1<<o,o=t[o],o>s&&(s=o),r&=~i}if(r=s,r=Se()-r,r=(120>r?120:480>r?480:1080>r?1080:1920>r?1920:3e3>r?3e3:4320>r?4320:1960*Ng(r/1960))-r,10<r){e.timeoutHandle=Eo(Nn.bind(null,e,Ye,zt),r);break}Nn(e,Ye,zt);break;case 5:Nn(e,Ye,zt);break;default:throw Error(O(329))}}}return et(e,Se()),e.callbackNode===n?Gf.bind(null,e):null}function Vo(e,t){var n=ts;return e.current.memoizedState.isDehydrated&&(On(e,t).flags|=256),e=Di(e,t),e!==2&&(t=Ye,Ye=n,t!==null&&Ko(t)),e}function Ko(e){Ye===null?Ye=e:Ye.push.apply(Ye,e)}function kg(e){for(var t=e;;){if(t.flags&16384){var n=t.updateQueue;if(n!==null&&(n=n.stores,n!==null))for(var r=0;r<n.length;r++){var s=n[r],i=s.getSnapshot;s=s.value;try{if(!Nt(i(),s))return!1}catch{return!1}}}if(n=t.child,t.subtreeFlags&16384&&n!==null)n.return=t,t=n;else{if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return!0;t=t.return}t.sibling.return=t.return,t=t.sibling}}return!0}function Zt(e,t){for(t&=~ql,t&=~ra,e.suspendedLanes|=t,e.pingedLanes&=~t,e=e.expirationTimes;0<t;){var n=31-jt(t),r=1<<n;e[n]=-1,t&=~r}}function mc(e){if(ie&6)throw Error(O(327));dr();var t=ji(e,0);if(!(t&1))return et(e,Se()),null;var n=Di(e,t);if(e.tag!==0&&n===2){var r=xo(e);r!==0&&(t=r,n=Vo(e,r))}if(n===1)throw n=js,On(e,0),Zt(e,t),et(e,Se()),n;if(n===6)throw Error(O(345));return e.finishedWork=e.current.alternate,e.finishedLanes=t,Nn(e,Ye,zt),et(e,Se()),null}function Vl(e,t){var n=ie;ie|=1;try{return e(t)}finally{ie=n,ie===0&&(wr=Se()+500,Zi&&xn())}}function _n(e){nn!==null&&nn.tag===0&&!(ie&6)&&dr();var t=ie;ie|=1;var n=dt.transition,r=le;try{if(dt.transition=null,le=1,e)return e()}finally{le=r,dt.transition=n,ie=t,!(ie&6)&&xn()}}function Kl(){tt=rr.current,ge(rr)}function On(e,t){e.finishedWork=null,e.finishedLanes=0;var n=e.timeoutHandle;if(n!==-1&&(e.timeoutHandle=-1,eg(n)),Ee!==null)for(n=Ee.return;n!==null;){var r=n;switch(Pl(r),r.tag){case 1:r=r.type.childContextTypes,r!=null&&Ci();break;case 3:vr(),ge(Xe),ge(We),Ll();break;case 5:_l(r);break;case 4:vr();break;case 13:ge(xe);break;case 19:ge(xe);break;case 10:Al(r.type._context);break;case 22:case 23:Kl()}n=n.return}if(Re=e,Ee=e=fn(e.current,null),_e=tt=t,ze=0,js=null,ql=ra=In=0,Ye=ts=null,Sn!==null){for(t=0;t<Sn.length;t++)if(n=Sn[t],r=n.interleaved,r!==null){n.interleaved=null;var s=r.next,i=n.pending;if(i!==null){var o=i.next;i.next=s,r.next=o}n.pending=r}Sn=null}return e}function Yf(e,t){do{var n=Ee;try{if(zl(),oi.current=Ii,Ri){for(var r=we.memoizedState;r!==null;){var s=r.queue;s!==null&&(s.pending=null),r=r.next}Ri=!1}if(Rn=0,Me=Oe=we=null,Zr=!1,vs=0,Hl.current=null,n===null||n.return===null){ze=1,js=t,Ee=null;break}e:{var i=e,o=n.return,l=n,u=t;if(t=_e,l.flags|=32768,u!==null&&typeof u=="object"&&typeof u.then=="function"){var c=u,d=l,p=d.tag;if(!(d.mode&1)&&(p===0||p===11||p===15)){var h=d.alternate;h?(d.updateQueue=h.updateQueue,d.memoizedState=h.memoizedState,d.lanes=h.lanes):(d.updateQueue=null,d.memoizedState=null)}var v=nc(o);if(v!==null){v.flags&=-257,rc(v,o,l,i,t),v.mode&1&&tc(i,c,t),t=v,u=c;var x=t.updateQueue;if(x===null){var w=new Set;w.add(u),t.updateQueue=w}else x.add(u);break e}else{if(!(t&1)){tc(i,c,t),Gl();break e}u=Error(O(426))}}else if(ye&&l.mode&1){var k=nc(o);if(k!==null){!(k.flags&65536)&&(k.flags|=256),rc(k,o,l,i,t),Tl(xr(u,l));break e}}i=u=xr(u,l),ze!==4&&(ze=2),ts===null?ts=[i]:ts.push(i),i=o;do{switch(i.tag){case 3:i.flags|=65536,t&=-t,i.lanes|=t;var m=Mf(i,u,t);Gu(i,m);break e;case 1:l=u;var f=i.type,g=i.stateNode;if(!(i.flags&128)&&(typeof f.getDerivedStateFromError=="function"||g!==null&&typeof g.componentDidCatch=="function"&&(cn===null||!cn.has(g)))){i.flags|=65536,t&=-t,i.lanes|=t;var b=Rf(i,l,t);Gu(i,b);break e}}i=i.return}while(i!==null)}Zf(n)}catch(E){t=E,Ee===n&&n!==null&&(Ee=n=n.return);continue}break}while(1)}function Jf(){var e=_i.current;return _i.current=Ii,e===null?Ii:e}function Gl(){(ze===0||ze===3||ze===2)&&(ze=4),Re===null||!(In&268435455)&&!(ra&268435455)||Zt(Re,_e)}function Di(e,t){var n=ie;ie|=2;var r=Jf();(Re!==e||_e!==t)&&(zt=null,On(e,t));do try{Sg();break}catch(s){Yf(e,s)}while(1);if(zl(),ie=n,_i.current=r,Ee!==null)throw Error(O(261));return Re=null,_e=0,ze}function Sg(){for(;Ee!==null;)Xf(Ee)}function Cg(){for(;Ee!==null&&!Jh();)Xf(Ee)}function Xf(e){var t=tp(e.alternate,e,tt);e.memoizedProps=e.pendingProps,t===null?Zf(e):Ee=t,Hl.current=null}function Zf(e){var t=e;do{var n=t.alternate;if(e=t.return,t.flags&32768){if(n=xg(n,t),n!==null){n.flags&=32767,Ee=n;return}if(e!==null)e.flags|=32768,e.subtreeFlags=0,e.deletions=null;else{ze=6,Ee=null;return}}else if(n=vg(n,t,tt),n!==null){Ee=n;return}if(t=t.sibling,t!==null){Ee=t;return}Ee=t=e}while(t!==null);ze===0&&(ze=5)}function Nn(e,t,n){var r=le,s=dt.transition;try{dt.transition=null,le=1,Eg(e,t,n,r)}finally{dt.transition=s,le=r}return null}function Eg(e,t,n,r){do dr();while(nn!==null);if(ie&6)throw Error(O(327));n=e.finishedWork;var s=e.finishedLanes;if(n===null)return null;if(e.finishedWork=null,e.finishedLanes=0,n===e.current)throw Error(O(177));e.callbackNode=null,e.callbackPriority=0;var i=n.lanes|n.childLanes;if(om(e,i),e===Re&&(Ee=Re=null,_e=0),!(n.subtreeFlags&2064)&&!(n.flags&2064)||Ks||(Ks=!0,np(wi,function(){return dr(),null})),i=(n.flags&15990)!==0,n.subtreeFlags&15990||i){i=dt.transition,dt.transition=null;var o=le;le=1;var l=ie;ie|=4,Hl.current=null,jg(e,n),Vf(n,e),Vm(So),bi=!!ko,So=ko=null,e.current=n,bg(n),Xh(),ie=l,le=o,dt.transition=i}else e.current=n;if(Ks&&(Ks=!1,nn=e,Fi=s),i=e.pendingLanes,i===0&&(cn=null),tm(n.stateNode),et(e,Se()),t!==null)for(r=e.onRecoverableError,n=0;n<t.length;n++)s=t[n],r(s.value,{componentStack:s.stack,digest:s.digest});if(Li)throw Li=!1,e=qo,qo=null,e;return Fi&1&&e.tag!==0&&dr(),i=e.pendingLanes,i&1?e===Qo?ns++:(ns=0,Qo=e):ns=0,xn(),null}function dr(){if(nn!==null){var e=Ad(Fi),t=dt.transition,n=le;try{if(dt.transition=null,le=16>e?16:e,nn===null)var r=!1;else{if(e=nn,nn=null,Fi=0,ie&6)throw Error(O(331));var s=ie;for(ie|=4,L=e.current;L!==null;){var i=L,o=i.child;if(L.flags&16){var l=i.deletions;if(l!==null){for(var u=0;u<l.length;u++){var c=l[u];for(L=c;L!==null;){var d=L;switch(d.tag){case 0:case 11:case 15:es(8,d,i)}var p=d.child;if(p!==null)p.return=d,L=p;else for(;L!==null;){d=L;var h=d.sibling,v=d.return;if(Hf(d),d===c){L=null;break}if(h!==null){h.return=v,L=h;break}L=v}}}var x=i.alternate;if(x!==null){var w=x.child;if(w!==null){x.child=null;do{var k=w.sibling;w.sibling=null,w=k}while(w!==null)}}L=i}}if(i.subtreeFlags&2064&&o!==null)o.return=i,L=o;else e:for(;L!==null;){if(i=L,i.flags&2048)switch(i.tag){case 0:case 11:case 15:es(9,i,i.return)}var m=i.sibling;if(m!==null){m.return=i.return,L=m;break e}L=i.return}}var f=e.current;for(L=f;L!==null;){o=L;var g=o.child;if(o.subtreeFlags&2064&&g!==null)g.return=o,L=g;else e:for(o=f;L!==null;){if(l=L,l.flags&2048)try{switch(l.tag){case 0:case 11:case 15:na(9,l)}}catch(E){Ne(l,l.return,E)}if(l===o){L=null;break e}var b=l.sibling;if(b!==null){b.return=l.return,L=b;break e}L=l.return}}if(ie=s,xn(),Tt&&typeof Tt.onPostCommitFiberRoot=="function")try{Tt.onPostCommitFiberRoot(Ki,e)}catch{}r=!0}return r}finally{le=n,dt.transition=t}}return!1}function gc(e,t,n){t=xr(n,t),t=Mf(e,t,1),e=un(e,t,1),t=Qe(),e!==null&&(Ss(e,1,t),et(e,t))}function Ne(e,t,n){if(e.tag===3)gc(e,e,n);else for(;t!==null;){if(t.tag===3){gc(t,e,n);break}else if(t.tag===1){var r=t.stateNode;if(typeof t.type.getDerivedStateFromError=="function"||typeof r.componentDidCatch=="function"&&(cn===null||!cn.has(r))){e=xr(n,e),e=Rf(t,e,1),t=un(t,e,1),e=Qe(),t!==null&&(Ss(t,1,e),et(t,e));break}}t=t.return}}function Pg(e,t,n){var r=e.pingCache;r!==null&&r.delete(t),t=Qe(),e.pingedLanes|=e.suspendedLanes&n,Re===e&&(_e&n)===n&&(ze===4||ze===3&&(_e&130023424)===_e&&500>Se()-Ql?On(e,0):ql|=n),et(e,t)}function ep(e,t){t===0&&(e.mode&1?(t=Fs,Fs<<=1,!(Fs&130023424)&&(Fs=4194304)):t=1);var n=Qe();e=Dt(e,t),e!==null&&(Ss(e,t,n),et(e,n))}function Tg(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),ep(e,n)}function Og(e,t){var n=0;switch(e.tag){case 13:var r=e.stateNode,s=e.memoizedState;s!==null&&(n=s.retryLane);break;case 19:r=e.stateNode;break;default:throw Error(O(314))}r!==null&&r.delete(t),ep(e,n)}var tp;tp=function(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps||Xe.current)Je=!0;else{if(!(e.lanes&n)&&!(t.flags&128))return Je=!1,yg(e,t,n);Je=!!(e.flags&131072)}else Je=!1,ye&&t.flags&1048576&&sf(t,Ti,t.index);switch(t.lanes=0,t.tag){case 2:var r=t.type;ui(e,t),e=t.pendingProps;var s=mr(t,We.current);cr(t,n),s=Dl(null,t,r,e,s,n);var i=$l();return t.flags|=1,typeof s=="object"&&s!==null&&typeof s.render=="function"&&s.$$typeof===void 0?(t.tag=1,t.memoizedState=null,t.updateQueue=null,Ze(r)?(i=!0,Ei(t)):i=!1,t.memoizedState=s.state!==null&&s.state!==void 0?s.state:null,Rl(t),s.updater=ta,t.stateNode=s,s._reactInternals=t,Ro(t,r,e,n),t=Lo(null,t,r,!0,i,n)):(t.tag=0,ye&&i&&El(t),He(null,t,s,n),t=t.child),t;case 16:r=t.elementType;e:{switch(ui(e,t),e=t.pendingProps,s=r._init,r=s(r._payload),t.type=r,s=t.tag=Ag(r),e=yt(r,e),s){case 0:t=_o(null,t,r,e,n);break e;case 1:t=ac(null,t,r,e,n);break e;case 11:t=sc(null,t,r,e,n);break e;case 14:t=ic(null,t,r,yt(r.type,e),n);break e}throw Error(O(306,r,""))}return t;case 0:return r=t.type,s=t.pendingProps,s=t.elementType===r?s:yt(r,s),_o(e,t,r,s,n);case 1:return r=t.type,s=t.pendingProps,s=t.elementType===r?s:yt(r,s),ac(e,t,r,s,n);case 3:e:{if(Ff(t),e===null)throw Error(O(387));r=t.pendingProps,i=t.memoizedState,s=i.element,df(e,t),Ai(t,r,null,n);var o=t.memoizedState;if(r=o.element,i.isDehydrated)if(i={element:r,isDehydrated:!1,cache:o.cache,pendingSuspenseBoundaries:o.pendingSuspenseBoundaries,transitions:o.transitions},t.updateQueue.baseState=i,t.memoizedState=i,t.flags&256){s=xr(Error(O(423)),t),t=oc(e,t,r,n,s);break e}else if(r!==s){s=xr(Error(O(424)),t),t=oc(e,t,r,n,s);break e}else for(nt=ln(t.stateNode.containerInfo.firstChild),rt=t,ye=!0,wt=null,n=uf(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if(gr(),r===s){t=$t(e,t,n);break e}He(e,t,r,n)}t=t.child}return t;case 5:return ff(t),e===null&&zo(t),r=t.type,s=t.pendingProps,i=e!==null?e.memoizedProps:null,o=s.children,Co(r,s)?o=null:i!==null&&Co(r,i)&&(t.flags|=32),Lf(e,t),He(e,t,o,n),t.child;case 6:return e===null&&zo(t),null;case 13:return Df(e,t,n);case 4:return Il(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=yr(t,null,r,n):He(e,t,r,n),t.child;case 11:return r=t.type,s=t.pendingProps,s=t.elementType===r?s:yt(r,s),sc(e,t,r,s,n);case 7:return He(e,t,t.pendingProps,n),t.child;case 8:return He(e,t,t.pendingProps.children,n),t.child;case 12:return He(e,t,t.pendingProps.children,n),t.child;case 10:e:{if(r=t.type._context,s=t.pendingProps,i=t.memoizedProps,o=s.value,pe(Oi,r._currentValue),r._currentValue=o,i!==null)if(Nt(i.value,o)){if(i.children===s.children&&!Xe.current){t=$t(e,t,n);break e}}else for(i=t.child,i!==null&&(i.return=t);i!==null;){var l=i.dependencies;if(l!==null){o=i.child;for(var u=l.firstContext;u!==null;){if(u.context===r){if(i.tag===1){u=_t(-1,n&-n),u.tag=2;var c=i.updateQueue;if(c!==null){c=c.shared;var d=c.pending;d===null?u.next=u:(u.next=d.next,d.next=u),c.pending=u}}i.lanes|=n,u=i.alternate,u!==null&&(u.lanes|=n),Ao(i.return,n,t),l.lanes|=n;break}u=u.next}}else if(i.tag===10)o=i.type===t.type?null:i.child;else if(i.tag===18){if(o=i.return,o===null)throw Error(O(341));o.lanes|=n,l=o.alternate,l!==null&&(l.lanes|=n),Ao(o,n,t),o=i.sibling}else o=i.child;if(o!==null)o.return=i;else for(o=i;o!==null;){if(o===t){o=null;break}if(i=o.sibling,i!==null){i.return=o.return,o=i;break}o=o.return}i=o}He(e,t,s.children,n),t=t.child}return t;case 9:return s=t.type,r=t.pendingProps.children,cr(t,n),s=ft(s),r=r(s),t.flags|=1,He(e,t,r,n),t.child;case 14:return r=t.type,s=yt(r,t.pendingProps),s=yt(r.type,s),ic(e,t,r,s,n);case 15:return If(e,t,t.type,t.pendingProps,n);case 17:return r=t.type,s=t.pendingProps,s=t.elementType===r?s:yt(r,s),ui(e,t),t.tag=1,Ze(r)?(e=!0,Ei(t)):e=!1,cr(t,n),Af(t,r,s),Ro(t,r,s,n),Lo(null,t,r,!0,e,n);case 19:return $f(e,t,n);case 22:return _f(e,t,n)}throw Error(O(156,t.tag))};function np(e,t){return Pd(e,t)}function zg(e,t,n,r){this.tag=e,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=r,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function ct(e,t,n,r){return new zg(e,t,n,r)}function Yl(e){return e=e.prototype,!(!e||!e.isReactComponent)}function Ag(e){if(typeof e=="function")return Yl(e)?1:0;if(e!=null){if(e=e.$$typeof,e===ml)return 11;if(e===gl)return 14}return 2}function fn(e,t){var n=e.alternate;return n===null?(n=ct(e.tag,t,e.key,e.mode),n.elementType=e.elementType,n.type=e.type,n.stateNode=e.stateNode,n.alternate=e,e.alternate=n):(n.pendingProps=t,n.type=e.type,n.flags=0,n.subtreeFlags=0,n.deletions=null),n.flags=e.flags&14680064,n.childLanes=e.childLanes,n.lanes=e.lanes,n.child=e.child,n.memoizedProps=e.memoizedProps,n.memoizedState=e.memoizedState,n.updateQueue=e.updateQueue,t=e.dependencies,n.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},n.sibling=e.sibling,n.index=e.index,n.ref=e.ref,n}function fi(e,t,n,r,s,i){var o=2;if(r=e,typeof e=="function")Yl(e)&&(o=1);else if(typeof e=="string")o=5;else e:switch(e){case Vn:return zn(n.children,s,i,t);case hl:o=8,s|=8;break;case ro:return e=ct(12,n,t,s|2),e.elementType=ro,e.lanes=i,e;case so:return e=ct(13,n,t,s),e.elementType=so,e.lanes=i,e;case io:return e=ct(19,n,t,s),e.elementType=io,e.lanes=i,e;case dd:return sa(n,s,i,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case ud:o=10;break e;case cd:o=9;break e;case ml:o=11;break e;case gl:o=14;break e;case Vt:o=16,r=null;break e}throw Error(O(130,e==null?e:typeof e,""))}return t=ct(o,n,t,s),t.elementType=e,t.type=r,t.lanes=i,t}function zn(e,t,n,r){return e=ct(7,e,r,t),e.lanes=n,e}function sa(e,t,n,r){return e=ct(22,e,r,t),e.elementType=dd,e.lanes=n,e.stateNode={isHidden:!1},e}function Qa(e,t,n){return e=ct(6,e,null,t),e.lanes=n,e}function Va(e,t,n){return t=ct(4,e.children!==null?e.children:[],e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function Mg(e,t,n,r,s){this.tag=t,this.containerInfo=e,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=Ea(0),this.expirationTimes=Ea(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Ea(0),this.identifierPrefix=r,this.onRecoverableError=s,this.mutableSourceEagerHydrationData=null}function Jl(e,t,n,r,s,i,o,l,u){return e=new Mg(e,t,n,l,u),t===1?(t=1,i===!0&&(t|=8)):t=0,i=ct(3,null,null,t),e.current=i,i.stateNode=e,i.memoizedState={element:r,isDehydrated:n,cache:null,transitions:null,pendingSuspenseBoundaries:null},Rl(i),e}function Rg(e,t,n){var r=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:Qn,key:r==null?null:""+r,children:e,containerInfo:t,implementation:n}}function rp(e){if(!e)return gn;e=e._reactInternals;e:{if(Fn(e)!==e||e.tag!==1)throw Error(O(170));var t=e;do{switch(t.tag){case 3:t=t.stateNode.context;break e;case 1:if(Ze(t.type)){t=t.stateNode.__reactInternalMemoizedMergedChildContext;break e}}t=t.return}while(t!==null);throw Error(O(171))}if(e.tag===1){var n=e.type;if(Ze(n))return nf(e,n,t)}return t}function sp(e,t,n,r,s,i,o,l,u){return e=Jl(n,r,!0,e,s,i,o,l,u),e.context=rp(null),n=e.current,r=Qe(),s=dn(n),i=_t(r,s),i.callback=t??null,un(n,i,s),e.current.lanes=s,Ss(e,s,r),et(e,r),e}function ia(e,t,n,r){var s=t.current,i=Qe(),o=dn(s);return n=rp(n),t.context===null?t.context=n:t.pendingContext=n,t=_t(i,o),t.payload={element:e},r=r===void 0?null:r,r!==null&&(t.callback=r),e=un(s,t,o),e!==null&&(bt(e,s,o,i),ai(e,s,o)),o}function $i(e){if(e=e.current,!e.child)return null;switch(e.child.tag){case 5:return e.child.stateNode;default:return e.child.stateNode}}function yc(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var n=e.retryLane;e.retryLane=n!==0&&n<t?n:t}}function Xl(e,t){yc(e,t),(e=e.alternate)&&yc(e,t)}function Ig(){return null}var ip=typeof reportError=="function"?reportError:function(e){console.error(e)};function Zl(e){this._internalRoot=e}aa.prototype.render=Zl.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(O(409));ia(e,t,null,null)};aa.prototype.unmount=Zl.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;_n(function(){ia(null,e,null,null)}),t[Ft]=null}};function aa(e){this._internalRoot=e}aa.prototype.unstable_scheduleHydration=function(e){if(e){var t=Id();e={blockedOn:null,target:e,priority:t};for(var n=0;n<Xt.length&&t!==0&&t<Xt[n].priority;n++);Xt.splice(n,0,e),n===0&&Ld(e)}};function eu(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function oa(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11&&(e.nodeType!==8||e.nodeValue!==" react-mount-point-unstable "))}function vc(){}function _g(e,t,n,r,s){if(s){if(typeof r=="function"){var i=r;r=function(){var c=$i(o);i.call(c)}}var o=sp(t,r,e,0,null,!1,!1,"",vc);return e._reactRootContainer=o,e[Ft]=o.current,ps(e.nodeType===8?e.parentNode:e),_n(),o}for(;s=e.lastChild;)e.removeChild(s);if(typeof r=="function"){var l=r;r=function(){var c=$i(u);l.call(c)}}var u=Jl(e,0,!1,null,null,!1,!1,"",vc);return e._reactRootContainer=u,e[Ft]=u.current,ps(e.nodeType===8?e.parentNode:e),_n(function(){ia(t,u,n,r)}),u}function la(e,t,n,r,s){var i=n._reactRootContainer;if(i){var o=i;if(typeof s=="function"){var l=s;s=function(){var u=$i(o);l.call(u)}}ia(t,o,e,s)}else o=_g(n,t,e,s,r);return $i(o)}Md=function(e){switch(e.tag){case 3:var t=e.stateNode;if(t.current.memoizedState.isDehydrated){var n=Hr(t.pendingLanes);n!==0&&(xl(t,n|1),et(t,Se()),!(ie&6)&&(wr=Se()+500,xn()))}break;case 13:_n(function(){var r=Dt(e,1);if(r!==null){var s=Qe();bt(r,e,1,s)}}),Xl(e,1)}};wl=function(e){if(e.tag===13){var t=Dt(e,134217728);if(t!==null){var n=Qe();bt(t,e,134217728,n)}Xl(e,134217728)}};Rd=function(e){if(e.tag===13){var t=dn(e),n=Dt(e,t);if(n!==null){var r=Qe();bt(n,e,t,r)}Xl(e,t)}};Id=function(){return le};_d=function(e,t){var n=le;try{return le=e,t()}finally{le=n}};go=function(e,t,n){switch(t){case"input":if(lo(e,n),t=n.name,n.type==="radio"&&t!=null){for(n=e;n.parentNode;)n=n.parentNode;for(n=n.querySelectorAll("input[name="+JSON.stringify(""+t)+'][type="radio"]'),t=0;t<n.length;t++){var r=n[t];if(r!==e&&r.form===e.form){var s=Xi(r);if(!s)throw Error(O(90));pd(r),lo(r,s)}}}break;case"textarea":md(e,n);break;case"select":t=n.value,t!=null&&ar(e,!!n.multiple,t,!1)}};bd=Vl;Nd=_n;var Lg={usingClientEntryPoint:!1,Events:[Es,Jn,Xi,wd,jd,Vl]},Ir={findFiberByHostInstance:kn,bundleType:0,version:"18.3.1",rendererPackageName:"react-dom"},Fg={bundleType:Ir.bundleType,version:Ir.version,rendererPackageName:Ir.rendererPackageName,rendererConfig:Ir.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setErrorHandler:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:Ut.ReactCurrentDispatcher,findHostInstanceByFiber:function(e){return e=Cd(e),e===null?null:e.stateNode},findFiberByHostInstance:Ir.findFiberByHostInstance||Ig,findHostInstancesForRefresh:null,scheduleRefresh:null,scheduleRoot:null,setRefreshHandler:null,getCurrentFiber:null,reconcilerVersion:"18.3.1-next-f1338f8080-20240426"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var Gs=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Gs.isDisabled&&Gs.supportsFiber)try{Ki=Gs.inject(Fg),Tt=Gs}catch{}}it.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=Lg;it.createPortal=function(e,t){var n=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!eu(t))throw Error(O(200));return Rg(e,t,null,n)};it.createRoot=function(e,t){if(!eu(e))throw Error(O(299));var n=!1,r="",s=ip;return t!=null&&(t.unstable_strictMode===!0&&(n=!0),t.identifierPrefix!==void 0&&(r=t.identifierPrefix),t.onRecoverableError!==void 0&&(s=t.onRecoverableError)),t=Jl(e,1,!1,null,null,n,!1,r,s),e[Ft]=t.current,ps(e.nodeType===8?e.parentNode:e),new Zl(t)};it.findDOMNode=function(e){if(e==null)return null;if(e.nodeType===1)return e;var t=e._reactInternals;if(t===void 0)throw typeof e.render=="function"?Error(O(188)):(e=Object.keys(e).join(","),Error(O(268,e)));return e=Cd(t),e=e===null?null:e.stateNode,e};it.flushSync=function(e){return _n(e)};it.hydrate=function(e,t,n){if(!oa(t))throw Error(O(200));return la(null,e,t,!0,n)};it.hydrateRoot=function(e,t,n){if(!eu(e))throw Error(O(405));var r=n!=null&&n.hydratedSources||null,s=!1,i="",o=ip;if(n!=null&&(n.unstable_strictMode===!0&&(s=!0),n.identifierPrefix!==void 0&&(i=n.identifierPrefix),n.onRecoverableError!==void 0&&(o=n.onRecoverableError)),t=sp(t,null,e,1,n??null,s,!1,i,o),e[Ft]=t.current,ps(e),r)for(e=0;e<r.length;e++)n=r[e],s=n._getVersion,s=s(n._source),t.mutableSourceEagerHydrationData==null?t.mutableSourceEagerHydrationData=[n,s]:t.mutableSourceEagerHydrationData.push(n,s);return new aa(t)};it.render=function(e,t,n){if(!oa(t))throw Error(O(200));return la(null,e,t,!1,n)};it.unmountComponentAtNode=function(e){if(!oa(e))throw Error(O(40));return e._reactRootContainer?(_n(function(){la(null,null,e,!1,function(){e._reactRootContainer=null,e[Ft]=null})}),!0):!1};it.unstable_batchedUpdates=Vl;it.unstable_renderSubtreeIntoContainer=function(e,t,n,r){if(!oa(n))throw Error(O(200));if(e==null||e._reactInternals===void 0)throw Error(O(38));return la(e,t,n,!1,r)};it.version="18.3.1-next-f1338f8080-20240426";function ap(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(ap)}catch(e){console.error(e)}}ap(),id.exports=it;var op=id.exports;const Dg=br(op);var xc=op;to.createRoot=xc.createRoot,to.hydrateRoot=xc.hydrateRoot;/**
41
+ * @remix-run/router v1.23.0
42
+ *
43
+ * Copyright (c) Remix Software Inc.
44
+ *
45
+ * This source code is licensed under the MIT license found in the
46
+ * LICENSE.md file in the root directory of this source tree.
47
+ *
48
+ * @license MIT
49
+ */function bs(){return bs=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},bs.apply(this,arguments)}var rn;(function(e){e.Pop="POP",e.Push="PUSH",e.Replace="REPLACE"})(rn||(rn={}));const wc="popstate";function $g(e){e===void 0&&(e={});function t(r,s){let{pathname:i,search:o,hash:l}=r.location;return Go("",{pathname:i,search:o,hash:l},s.state&&s.state.usr||null,s.state&&s.state.key||"default")}function n(r,s){return typeof s=="string"?s:Ui(s)}return Wg(t,n,null,e)}function Pe(e,t){if(e===!1||e===null||typeof e>"u")throw new Error(t)}function lp(e,t){if(!e){typeof console<"u"&&console.warn(t);try{throw new Error(t)}catch{}}}function Ug(){return Math.random().toString(36).substr(2,8)}function jc(e,t){return{usr:e.state,key:e.key,idx:t}}function Go(e,t,n,r){return n===void 0&&(n=null),bs({pathname:typeof e=="string"?e:e.pathname,search:"",hash:""},typeof t=="string"?Cr(t):t,{state:n,key:t&&t.key||r||Ug()})}function Ui(e){let{pathname:t="/",search:n="",hash:r=""}=e;return n&&n!=="?"&&(t+=n.charAt(0)==="?"?n:"?"+n),r&&r!=="#"&&(t+=r.charAt(0)==="#"?r:"#"+r),t}function Cr(e){let t={};if(e){let n=e.indexOf("#");n>=0&&(t.hash=e.substr(n),e=e.substr(0,n));let r=e.indexOf("?");r>=0&&(t.search=e.substr(r),e=e.substr(0,r)),e&&(t.pathname=e)}return t}function Wg(e,t,n,r){r===void 0&&(r={});let{window:s=document.defaultView,v5Compat:i=!1}=r,o=s.history,l=rn.Pop,u=null,c=d();c==null&&(c=0,o.replaceState(bs({},o.state,{idx:c}),""));function d(){return(o.state||{idx:null}).idx}function p(){l=rn.Pop;let k=d(),m=k==null?null:k-c;c=k,u&&u({action:l,location:w.location,delta:m})}function h(k,m){l=rn.Push;let f=Go(w.location,k,m);n&&n(f,k),c=d()+1;let g=jc(f,c),b=w.createHref(f);try{o.pushState(g,"",b)}catch(E){if(E instanceof DOMException&&E.name==="DataCloneError")throw E;s.location.assign(b)}i&&u&&u({action:l,location:w.location,delta:1})}function v(k,m){l=rn.Replace;let f=Go(w.location,k,m);n&&n(f,k),c=d();let g=jc(f,c),b=w.createHref(f);o.replaceState(g,"",b),i&&u&&u({action:l,location:w.location,delta:0})}function x(k){let m=s.location.origin!=="null"?s.location.origin:s.location.href,f=typeof k=="string"?k:Ui(k);return f=f.replace(/ $/,"%20"),Pe(m,"No window.location.(origin|href) available to create URL for href: "+f),new URL(f,m)}let w={get action(){return l},get location(){return e(s,o)},listen(k){if(u)throw new Error("A history only accepts one active listener");return s.addEventListener(wc,p),u=k,()=>{s.removeEventListener(wc,p),u=null}},createHref(k){return t(s,k)},createURL:x,encodeLocation(k){let m=x(k);return{pathname:m.pathname,search:m.search,hash:m.hash}},push:h,replace:v,go(k){return o.go(k)}};return w}var bc;(function(e){e.data="data",e.deferred="deferred",e.redirect="redirect",e.error="error"})(bc||(bc={}));function Bg(e,t,n){return n===void 0&&(n="/"),Hg(e,t,n,!1)}function Hg(e,t,n,r){let s=typeof t=="string"?Cr(t):t,i=tu(s.pathname||"/",n);if(i==null)return null;let o=up(e);qg(o);let l=null;for(let u=0;l==null&&u<o.length;++u){let c=n0(i);l=e0(o[u],c,r)}return l}function up(e,t,n,r){t===void 0&&(t=[]),n===void 0&&(n=[]),r===void 0&&(r="");let s=(i,o,l)=>{let u={relativePath:l===void 0?i.path||"":l,caseSensitive:i.caseSensitive===!0,childrenIndex:o,route:i};u.relativePath.startsWith("/")&&(Pe(u.relativePath.startsWith(r),'Absolute route path "'+u.relativePath+'" nested under path '+('"'+r+'" is not valid. An absolute child route path ')+"must start with the combined path of all its parent routes."),u.relativePath=u.relativePath.slice(r.length));let c=pn([r,u.relativePath]),d=n.concat(u);i.children&&i.children.length>0&&(Pe(i.index!==!0,"Index routes must not have child routes. Please remove "+('all child routes from route path "'+c+'".')),up(i.children,t,d,c)),!(i.path==null&&!i.index)&&t.push({path:c,score:Xg(c,i.index),routesMeta:d})};return e.forEach((i,o)=>{var l;if(i.path===""||!((l=i.path)!=null&&l.includes("?")))s(i,o);else for(let u of cp(i.path))s(i,o,u)}),t}function cp(e){let t=e.split("/");if(t.length===0)return[];let[n,...r]=t,s=n.endsWith("?"),i=n.replace(/\?$/,"");if(r.length===0)return s?[i,""]:[i];let o=cp(r.join("/")),l=[];return l.push(...o.map(u=>u===""?i:[i,u].join("/"))),s&&l.push(...o),l.map(u=>e.startsWith("/")&&u===""?"/":u)}function qg(e){e.sort((t,n)=>t.score!==n.score?n.score-t.score:Zg(t.routesMeta.map(r=>r.childrenIndex),n.routesMeta.map(r=>r.childrenIndex)))}const Qg=/^:[\w-]+$/,Vg=3,Kg=2,Gg=1,Yg=10,Jg=-2,Nc=e=>e==="*";function Xg(e,t){let n=e.split("/"),r=n.length;return n.some(Nc)&&(r+=Jg),t&&(r+=Kg),n.filter(s=>!Nc(s)).reduce((s,i)=>s+(Qg.test(i)?Vg:i===""?Gg:Yg),r)}function Zg(e,t){return e.length===t.length&&e.slice(0,-1).every((r,s)=>r===t[s])?e[e.length-1]-t[t.length-1]:0}function e0(e,t,n){n===void 0&&(n=!1);let{routesMeta:r}=e,s={},i="/",o=[];for(let l=0;l<r.length;++l){let u=r[l],c=l===r.length-1,d=i==="/"?t:t.slice(i.length)||"/",p=kc({path:u.relativePath,caseSensitive:u.caseSensitive,end:c},d),h=u.route;if(!p&&c&&n&&!r[r.length-1].route.index&&(p=kc({path:u.relativePath,caseSensitive:u.caseSensitive,end:!1},d)),!p)return null;Object.assign(s,p.params),o.push({params:s,pathname:pn([i,p.pathname]),pathnameBase:a0(pn([i,p.pathnameBase])),route:h}),p.pathnameBase!=="/"&&(i=pn([i,p.pathnameBase]))}return o}function kc(e,t){typeof e=="string"&&(e={path:e,caseSensitive:!1,end:!0});let[n,r]=t0(e.path,e.caseSensitive,e.end),s=t.match(n);if(!s)return null;let i=s[0],o=i.replace(/(.)\/+$/,"$1"),l=s.slice(1);return{params:r.reduce((c,d,p)=>{let{paramName:h,isOptional:v}=d;if(h==="*"){let w=l[p]||"";o=i.slice(0,i.length-w.length).replace(/(.)\/+$/,"$1")}const x=l[p];return v&&!x?c[h]=void 0:c[h]=(x||"").replace(/%2F/g,"/"),c},{}),pathname:i,pathnameBase:o,pattern:e}}function t0(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!0),lp(e==="*"||!e.endsWith("*")||e.endsWith("/*"),'Route path "'+e+'" will be treated as if it were '+('"'+e.replace(/\*$/,"/*")+'" because the `*` character must ')+"always follow a `/` in the pattern. To get rid of this warning, "+('please change the route path to "'+e.replace(/\*$/,"/*")+'".'));let r=[],s="^"+e.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(o,l,u)=>(r.push({paramName:l,isOptional:u!=null}),u?"/?([^\\/]+)?":"/([^\\/]+)"));return e.endsWith("*")?(r.push({paramName:"*"}),s+=e==="*"||e==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):n?s+="\\/*$":e!==""&&e!=="/"&&(s+="(?:(?=\\/|$))"),[new RegExp(s,t?void 0:"i"),r]}function n0(e){try{return e.split("/").map(t=>decodeURIComponent(t).replace(/\//g,"%2F")).join("/")}catch(t){return lp(!1,'The URL path "'+e+'" could not be decoded because it is is a malformed URL segment. This is probably due to a bad percent '+("encoding ("+t+").")),e}}function tu(e,t){if(t==="/")return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let n=t.endsWith("/")?t.length-1:t.length,r=e.charAt(n);return r&&r!=="/"?null:e.slice(n)||"/"}function r0(e,t){t===void 0&&(t="/");let{pathname:n,search:r="",hash:s=""}=typeof e=="string"?Cr(e):e;return{pathname:n?n.startsWith("/")?n:s0(n,t):t,search:o0(r),hash:l0(s)}}function s0(e,t){let n=t.replace(/\/+$/,"").split("/");return e.split("/").forEach(s=>{s===".."?n.length>1&&n.pop():s!=="."&&n.push(s)}),n.length>1?n.join("/"):"/"}function Ka(e,t,n,r){return"Cannot include a '"+e+"' character in a manually specified "+("`to."+t+"` field ["+JSON.stringify(r)+"]. Please separate it out to the ")+("`to."+n+"` field. Alternatively you may provide the full path as ")+'a string in <Link to="..."> and the router will parse it for you.'}function i0(e){return e.filter((t,n)=>n===0||t.route.path&&t.route.path.length>0)}function dp(e,t){let n=i0(e);return t?n.map((r,s)=>s===n.length-1?r.pathname:r.pathnameBase):n.map(r=>r.pathnameBase)}function fp(e,t,n,r){r===void 0&&(r=!1);let s;typeof e=="string"?s=Cr(e):(s=bs({},e),Pe(!s.pathname||!s.pathname.includes("?"),Ka("?","pathname","search",s)),Pe(!s.pathname||!s.pathname.includes("#"),Ka("#","pathname","hash",s)),Pe(!s.search||!s.search.includes("#"),Ka("#","search","hash",s)));let i=e===""||s.pathname==="",o=i?"/":s.pathname,l;if(o==null)l=n;else{let p=t.length-1;if(!r&&o.startsWith("..")){let h=o.split("/");for(;h[0]==="..";)h.shift(),p-=1;s.pathname=h.join("/")}l=p>=0?t[p]:"/"}let u=r0(s,l),c=o&&o!=="/"&&o.endsWith("/"),d=(i||o===".")&&n.endsWith("/");return!u.pathname.endsWith("/")&&(c||d)&&(u.pathname+="/"),u}const pn=e=>e.join("/").replace(/\/\/+/g,"/"),a0=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),o0=e=>!e||e==="?"?"":e.startsWith("?")?e:"?"+e,l0=e=>!e||e==="#"?"":e.startsWith("#")?e:"#"+e;function u0(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.internal=="boolean"&&"data"in e}const pp=["post","put","patch","delete"];new Set(pp);const c0=["get",...pp];new Set(c0);/**
50
+ * React Router v6.30.1
51
+ *
52
+ * Copyright (c) Remix Software Inc.
53
+ *
54
+ * This source code is licensed under the MIT license found in the
55
+ * LICENSE.md file in the root directory of this source tree.
56
+ *
57
+ * @license MIT
58
+ */function Ns(){return Ns=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Ns.apply(this,arguments)}const nu=N.createContext(null),d0=N.createContext(null),Dn=N.createContext(null),ua=N.createContext(null),$n=N.createContext({outlet:null,matches:[],isDataRoute:!1}),hp=N.createContext(null);function f0(e,t){let{relative:n}=t===void 0?{}:t;Ts()||Pe(!1);let{basename:r,navigator:s}=N.useContext(Dn),{hash:i,pathname:o,search:l}=gp(e,{relative:n}),u=o;return r!=="/"&&(u=o==="/"?r:pn([r,o])),s.createHref({pathname:u,search:l,hash:i})}function Ts(){return N.useContext(ua)!=null}function Os(){return Ts()||Pe(!1),N.useContext(ua).location}function mp(e){N.useContext(Dn).static||N.useLayoutEffect(e)}function p0(){let{isDataRoute:e}=N.useContext($n);return e?C0():h0()}function h0(){Ts()||Pe(!1);let e=N.useContext(nu),{basename:t,future:n,navigator:r}=N.useContext(Dn),{matches:s}=N.useContext($n),{pathname:i}=Os(),o=JSON.stringify(dp(s,n.v7_relativeSplatPath)),l=N.useRef(!1);return mp(()=>{l.current=!0}),N.useCallback(function(c,d){if(d===void 0&&(d={}),!l.current)return;if(typeof c=="number"){r.go(c);return}let p=fp(c,JSON.parse(o),i,d.relative==="path");e==null&&t!=="/"&&(p.pathname=p.pathname==="/"?t:pn([t,p.pathname])),(d.replace?r.replace:r.push)(p,d.state,d)},[t,r,o,i,e])}function gp(e,t){let{relative:n}=t===void 0?{}:t,{future:r}=N.useContext(Dn),{matches:s}=N.useContext($n),{pathname:i}=Os(),o=JSON.stringify(dp(s,r.v7_relativeSplatPath));return N.useMemo(()=>fp(e,JSON.parse(o),i,n==="path"),[e,o,i,n])}function m0(e,t){return g0(e,t)}function g0(e,t,n,r){Ts()||Pe(!1);let{navigator:s}=N.useContext(Dn),{matches:i}=N.useContext($n),o=i[i.length-1],l=o?o.params:{};o&&o.pathname;let u=o?o.pathnameBase:"/";o&&o.route;let c=Os(),d;if(t){var p;let k=typeof t=="string"?Cr(t):t;u==="/"||(p=k.pathname)!=null&&p.startsWith(u)||Pe(!1),d=k}else d=c;let h=d.pathname||"/",v=h;if(u!=="/"){let k=u.replace(/^\//,"").split("/");v="/"+h.replace(/^\//,"").split("/").slice(k.length).join("/")}let x=Bg(e,{pathname:v}),w=j0(x&&x.map(k=>Object.assign({},k,{params:Object.assign({},l,k.params),pathname:pn([u,s.encodeLocation?s.encodeLocation(k.pathname).pathname:k.pathname]),pathnameBase:k.pathnameBase==="/"?u:pn([u,s.encodeLocation?s.encodeLocation(k.pathnameBase).pathname:k.pathnameBase])})),i,n,r);return t&&w?N.createElement(ua.Provider,{value:{location:Ns({pathname:"/",search:"",hash:"",state:null,key:"default"},d),navigationType:rn.Pop}},w):w}function y0(){let e=S0(),t=u0(e)?e.status+" "+e.statusText:e instanceof Error?e.message:JSON.stringify(e),n=e instanceof Error?e.stack:null,s={padding:"0.5rem",backgroundColor:"rgba(200,200,200, 0.5)"},i=null;return N.createElement(N.Fragment,null,N.createElement("h2",null,"Unexpected Application Error!"),N.createElement("h3",{style:{fontStyle:"italic"}},t),n?N.createElement("pre",{style:s},n):null,i)}const v0=N.createElement(y0,null);class x0 extends N.Component{constructor(t){super(t),this.state={location:t.location,revalidation:t.revalidation,error:t.error}}static getDerivedStateFromError(t){return{error:t}}static getDerivedStateFromProps(t,n){return n.location!==t.location||n.revalidation!=="idle"&&t.revalidation==="idle"?{error:t.error,location:t.location,revalidation:t.revalidation}:{error:t.error!==void 0?t.error:n.error,location:n.location,revalidation:t.revalidation||n.revalidation}}componentDidCatch(t,n){console.error("React Router caught the following error during render",t,n)}render(){return this.state.error!==void 0?N.createElement($n.Provider,{value:this.props.routeContext},N.createElement(hp.Provider,{value:this.state.error,children:this.props.component})):this.props.children}}function w0(e){let{routeContext:t,match:n,children:r}=e,s=N.useContext(nu);return s&&s.static&&s.staticContext&&(n.route.errorElement||n.route.ErrorBoundary)&&(s.staticContext._deepestRenderedBoundaryId=n.route.id),N.createElement($n.Provider,{value:t},r)}function j0(e,t,n,r){var s;if(t===void 0&&(t=[]),n===void 0&&(n=null),r===void 0&&(r=null),e==null){var i;if(!n)return null;if(n.errors)e=n.matches;else if((i=r)!=null&&i.v7_partialHydration&&t.length===0&&!n.initialized&&n.matches.length>0)e=n.matches;else return null}let o=e,l=(s=n)==null?void 0:s.errors;if(l!=null){let d=o.findIndex(p=>p.route.id&&(l==null?void 0:l[p.route.id])!==void 0);d>=0||Pe(!1),o=o.slice(0,Math.min(o.length,d+1))}let u=!1,c=-1;if(n&&r&&r.v7_partialHydration)for(let d=0;d<o.length;d++){let p=o[d];if((p.route.HydrateFallback||p.route.hydrateFallbackElement)&&(c=d),p.route.id){let{loaderData:h,errors:v}=n,x=p.route.loader&&h[p.route.id]===void 0&&(!v||v[p.route.id]===void 0);if(p.route.lazy||x){u=!0,c>=0?o=o.slice(0,c+1):o=[o[0]];break}}}return o.reduceRight((d,p,h)=>{let v,x=!1,w=null,k=null;n&&(v=l&&p.route.id?l[p.route.id]:void 0,w=p.route.errorElement||v0,u&&(c<0&&h===0?(E0("route-fallback",!1),x=!0,k=null):c===h&&(x=!0,k=p.route.hydrateFallbackElement||null)));let m=t.concat(o.slice(0,h+1)),f=()=>{let g;return v?g=w:x?g=k:p.route.Component?g=N.createElement(p.route.Component,null):p.route.element?g=p.route.element:g=d,N.createElement(w0,{match:p,routeContext:{outlet:d,matches:m,isDataRoute:n!=null},children:g})};return n&&(p.route.ErrorBoundary||p.route.errorElement||h===0)?N.createElement(x0,{location:n.location,revalidation:n.revalidation,component:w,error:v,children:f(),routeContext:{outlet:null,matches:m,isDataRoute:!0}}):f()},null)}var yp=function(e){return e.UseBlocker="useBlocker",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e}(yp||{}),Wi=function(e){return e.UseBlocker="useBlocker",e.UseLoaderData="useLoaderData",e.UseActionData="useActionData",e.UseRouteError="useRouteError",e.UseNavigation="useNavigation",e.UseRouteLoaderData="useRouteLoaderData",e.UseMatches="useMatches",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e.UseRouteId="useRouteId",e}(Wi||{});function b0(e){let t=N.useContext(nu);return t||Pe(!1),t}function N0(e){let t=N.useContext(d0);return t||Pe(!1),t}function k0(e){let t=N.useContext($n);return t||Pe(!1),t}function vp(e){let t=k0(),n=t.matches[t.matches.length-1];return n.route.id||Pe(!1),n.route.id}function S0(){var e;let t=N.useContext(hp),n=N0(Wi.UseRouteError),r=vp(Wi.UseRouteError);return t!==void 0?t:(e=n.errors)==null?void 0:e[r]}function C0(){let{router:e}=b0(yp.UseNavigateStable),t=vp(Wi.UseNavigateStable),n=N.useRef(!1);return mp(()=>{n.current=!0}),N.useCallback(function(s,i){i===void 0&&(i={}),n.current&&(typeof s=="number"?e.navigate(s):e.navigate(s,Ns({fromRouteId:t},i)))},[e,t])}const Sc={};function E0(e,t,n){!t&&!Sc[e]&&(Sc[e]=!0)}function P0(e,t){e==null||e.v7_startTransition,(e==null?void 0:e.v7_relativeSplatPath)===void 0&&(!t||t.v7_relativeSplatPath),t&&(t.v7_fetcherPersist,t.v7_normalizeFormMethod,t.v7_partialHydration,t.v7_skipActionErrorRevalidation)}function Qr(e){Pe(!1)}function T0(e){let{basename:t="/",children:n=null,location:r,navigationType:s=rn.Pop,navigator:i,static:o=!1,future:l}=e;Ts()&&Pe(!1);let u=t.replace(/^\/*/,"/"),c=N.useMemo(()=>({basename:u,navigator:i,static:o,future:Ns({v7_relativeSplatPath:!1},l)}),[u,l,i,o]);typeof r=="string"&&(r=Cr(r));let{pathname:d="/",search:p="",hash:h="",state:v=null,key:x="default"}=r,w=N.useMemo(()=>{let k=tu(d,u);return k==null?null:{location:{pathname:k,search:p,hash:h,state:v,key:x},navigationType:s}},[u,d,p,h,v,x,s]);return w==null?null:N.createElement(Dn.Provider,{value:c},N.createElement(ua.Provider,{children:n,value:w}))}function O0(e){let{children:t,location:n}=e;return m0(Yo(t),n)}new Promise(()=>{});function Yo(e,t){t===void 0&&(t=[]);let n=[];return N.Children.forEach(e,(r,s)=>{if(!N.isValidElement(r))return;let i=[...t,s];if(r.type===N.Fragment){n.push.apply(n,Yo(r.props.children,i));return}r.type!==Qr&&Pe(!1),!r.props.index||!r.props.children||Pe(!1);let o={id:r.props.id||i.join("-"),caseSensitive:r.props.caseSensitive,element:r.props.element,Component:r.props.Component,index:r.props.index,path:r.props.path,loader:r.props.loader,action:r.props.action,errorElement:r.props.errorElement,ErrorBoundary:r.props.ErrorBoundary,hasErrorBoundary:r.props.ErrorBoundary!=null||r.props.errorElement!=null,shouldRevalidate:r.props.shouldRevalidate,handle:r.props.handle,lazy:r.props.lazy};r.props.children&&(o.children=Yo(r.props.children,i)),n.push(o)}),n}/**
59
+ * React Router DOM v6.30.1
60
+ *
61
+ * Copyright (c) Remix Software Inc.
62
+ *
63
+ * This source code is licensed under the MIT license found in the
64
+ * LICENSE.md file in the root directory of this source tree.
65
+ *
66
+ * @license MIT
67
+ */function Jo(){return Jo=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Jo.apply(this,arguments)}function z0(e,t){if(e==null)return{};var n={},r=Object.keys(e),s,i;for(i=0;i<r.length;i++)s=r[i],!(t.indexOf(s)>=0)&&(n[s]=e[s]);return n}function A0(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}function M0(e,t){return e.button===0&&(!t||t==="_self")&&!A0(e)}const R0=["onClick","relative","reloadDocument","replace","state","target","to","preventScrollReset","viewTransition"],I0="6";try{window.__reactRouterVersion=I0}catch{}const _0="startTransition",Cc=Ph[_0];function L0(e){let{basename:t,children:n,future:r,window:s}=e,i=N.useRef();i.current==null&&(i.current=$g({window:s,v5Compat:!0}));let o=i.current,[l,u]=N.useState({action:o.action,location:o.location}),{v7_startTransition:c}=r||{},d=N.useCallback(p=>{c&&Cc?Cc(()=>u(p)):u(p)},[u,c]);return N.useLayoutEffect(()=>o.listen(d),[o,d]),N.useEffect(()=>P0(r),[r]),N.createElement(T0,{basename:t,children:n,location:l.location,navigationType:l.action,navigator:o,future:r})}const F0=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u",D0=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,xp=N.forwardRef(function(t,n){let{onClick:r,relative:s,reloadDocument:i,replace:o,state:l,target:u,to:c,preventScrollReset:d,viewTransition:p}=t,h=z0(t,R0),{basename:v}=N.useContext(Dn),x,w=!1;if(typeof c=="string"&&D0.test(c)&&(x=c,F0))try{let g=new URL(window.location.href),b=c.startsWith("//")?new URL(g.protocol+c):new URL(c),E=tu(b.pathname,v);b.origin===g.origin&&E!=null?c=E+b.search+b.hash:w=!0}catch{}let k=f0(c,{relative:s}),m=$0(c,{replace:o,state:l,target:u,preventScrollReset:d,relative:s,viewTransition:p});function f(g){r&&r(g),g.defaultPrevented||m(g)}return N.createElement("a",Jo({},h,{href:x||k,onClick:w||i?r:f,ref:n,target:u}))});var Ec;(function(e){e.UseScrollRestoration="useScrollRestoration",e.UseSubmit="useSubmit",e.UseSubmitFetcher="useSubmitFetcher",e.UseFetcher="useFetcher",e.useViewTransitionState="useViewTransitionState"})(Ec||(Ec={}));var Pc;(function(e){e.UseFetcher="useFetcher",e.UseFetchers="useFetchers",e.UseScrollRestoration="useScrollRestoration"})(Pc||(Pc={}));function $0(e,t){let{target:n,replace:r,state:s,preventScrollReset:i,relative:o,viewTransition:l}=t===void 0?{}:t,u=p0(),c=Os(),d=gp(e,{relative:o});return N.useCallback(p=>{if(M0(p,n)){p.preventDefault();let h=r!==void 0?r:Ui(c)===Ui(d);u(e,{replace:h,state:s,preventScrollReset:i,relative:o,viewTransition:l})}},[c,u,d,r,s,n,e,i,o,l])}class ca{constructor(){this.listeners=new Set,this.subscribe=this.subscribe.bind(this)}subscribe(t){const n={listener:t};return this.listeners.add(n),this.onSubscribe(),()=>{this.listeners.delete(n),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}onSubscribe(){}onUnsubscribe(){}}const ru=typeof window>"u"||"Deno"in window;function vt(){}function U0(e,t){return typeof e=="function"?e(t):e}function W0(e){return typeof e=="number"&&e>=0&&e!==1/0}function B0(e,t){return Math.max(e+(t||0)-Date.now(),0)}function Ys(e,t,n){return da(e)?typeof t=="function"?{...n,queryKey:e,queryFn:t}:{...t,queryKey:e}:e}function Gt(e,t,n){return da(e)?[{...t,queryKey:e},n]:[e||{},t]}function Tc(e,t){const{type:n="all",exact:r,fetchStatus:s,predicate:i,queryKey:o,stale:l}=e;if(da(o)){if(r){if(t.queryHash!==su(o,t.options))return!1}else if(!Bi(t.queryKey,o))return!1}if(n!=="all"){const u=t.isActive();if(n==="active"&&!u||n==="inactive"&&u)return!1}return!(typeof l=="boolean"&&t.isStale()!==l||typeof s<"u"&&s!==t.state.fetchStatus||i&&!i(t))}function Oc(e,t){const{exact:n,fetching:r,predicate:s,mutationKey:i}=e;if(da(i)){if(!t.options.mutationKey)return!1;if(n){if(En(t.options.mutationKey)!==En(i))return!1}else if(!Bi(t.options.mutationKey,i))return!1}return!(typeof r=="boolean"&&t.state.status==="loading"!==r||s&&!s(t))}function su(e,t){return((t==null?void 0:t.queryKeyHashFn)||En)(e)}function En(e){return JSON.stringify(e,(t,n)=>Xo(n)?Object.keys(n).sort().reduce((r,s)=>(r[s]=n[s],r),{}):n)}function Bi(e,t){return wp(e,t)}function wp(e,t){return e===t?!0:typeof e!=typeof t?!1:e&&t&&typeof e=="object"&&typeof t=="object"?!Object.keys(t).some(n=>!wp(e[n],t[n])):!1}function jp(e,t){if(e===t)return e;const n=zc(e)&&zc(t);if(n||Xo(e)&&Xo(t)){const r=n?e.length:Object.keys(e).length,s=n?t:Object.keys(t),i=s.length,o=n?[]:{};let l=0;for(let u=0;u<i;u++){const c=n?u:s[u];o[c]=jp(e[c],t[c]),o[c]===e[c]&&l++}return r===i&&l===r?e:o}return t}function zc(e){return Array.isArray(e)&&e.length===Object.keys(e).length}function Xo(e){if(!Ac(e))return!1;const t=e.constructor;if(typeof t>"u")return!0;const n=t.prototype;return!(!Ac(n)||!n.hasOwnProperty("isPrototypeOf"))}function Ac(e){return Object.prototype.toString.call(e)==="[object Object]"}function da(e){return Array.isArray(e)}function bp(e){return new Promise(t=>{setTimeout(t,e)})}function Mc(e){bp(0).then(e)}function H0(){if(typeof AbortController=="function")return new AbortController}function q0(e,t,n){return n.isDataEqual!=null&&n.isDataEqual(e,t)?e:typeof n.structuralSharing=="function"?n.structuralSharing(e,t):n.structuralSharing!==!1?jp(e,t):t}class Q0 extends ca{constructor(){super(),this.setup=t=>{if(!ru&&window.addEventListener){const n=()=>t();return window.addEventListener("visibilitychange",n,!1),window.addEventListener("focus",n,!1),()=>{window.removeEventListener("visibilitychange",n),window.removeEventListener("focus",n)}}}}onSubscribe(){this.cleanup||this.setEventListener(this.setup)}onUnsubscribe(){if(!this.hasListeners()){var t;(t=this.cleanup)==null||t.call(this),this.cleanup=void 0}}setEventListener(t){var n;this.setup=t,(n=this.cleanup)==null||n.call(this),this.cleanup=t(r=>{typeof r=="boolean"?this.setFocused(r):this.onFocus()})}setFocused(t){this.focused!==t&&(this.focused=t,this.onFocus())}onFocus(){this.listeners.forEach(({listener:t})=>{t()})}isFocused(){return typeof this.focused=="boolean"?this.focused:typeof document>"u"?!0:[void 0,"visible","prerender"].includes(document.visibilityState)}}const Zo=new Q0,Rc=["online","offline"];class V0 extends ca{constructor(){super(),this.setup=t=>{if(!ru&&window.addEventListener){const n=()=>t();return Rc.forEach(r=>{window.addEventListener(r,n,!1)}),()=>{Rc.forEach(r=>{window.removeEventListener(r,n)})}}}}onSubscribe(){this.cleanup||this.setEventListener(this.setup)}onUnsubscribe(){if(!this.hasListeners()){var t;(t=this.cleanup)==null||t.call(this),this.cleanup=void 0}}setEventListener(t){var n;this.setup=t,(n=this.cleanup)==null||n.call(this),this.cleanup=t(r=>{typeof r=="boolean"?this.setOnline(r):this.onOnline()})}setOnline(t){this.online!==t&&(this.online=t,this.onOnline())}onOnline(){this.listeners.forEach(({listener:t})=>{t()})}isOnline(){return typeof this.online=="boolean"?this.online:typeof navigator>"u"||typeof navigator.onLine>"u"?!0:navigator.onLine}}const Hi=new V0;function K0(e){return Math.min(1e3*2**e,3e4)}function iu(e){return(e??"online")==="online"?Hi.isOnline():!0}class Np{constructor(t){this.revert=t==null?void 0:t.revert,this.silent=t==null?void 0:t.silent}}function Ga(e){return e instanceof Np}function kp(e){let t=!1,n=0,r=!1,s,i,o;const l=new Promise((k,m)=>{i=k,o=m}),u=k=>{r||(v(new Np(k)),e.abort==null||e.abort())},c=()=>{t=!0},d=()=>{t=!1},p=()=>!Zo.isFocused()||e.networkMode!=="always"&&!Hi.isOnline(),h=k=>{r||(r=!0,e.onSuccess==null||e.onSuccess(k),s==null||s(),i(k))},v=k=>{r||(r=!0,e.onError==null||e.onError(k),s==null||s(),o(k))},x=()=>new Promise(k=>{s=m=>{const f=r||!p();return f&&k(m),f},e.onPause==null||e.onPause()}).then(()=>{s=void 0,r||e.onContinue==null||e.onContinue()}),w=()=>{if(r)return;let k;try{k=e.fn()}catch(m){k=Promise.reject(m)}Promise.resolve(k).then(h).catch(m=>{var f,g;if(r)return;const b=(f=e.retry)!=null?f:3,E=(g=e.retryDelay)!=null?g:K0,T=typeof E=="function"?E(n,m):E,C=b===!0||typeof b=="number"&&n<b||typeof b=="function"&&b(n,m);if(t||!C){v(m);return}n++,e.onFail==null||e.onFail(n,m),bp(T).then(()=>{if(p())return x()}).then(()=>{t?v(m):w()})})};return iu(e.networkMode)?w():x().then(w),{promise:l,cancel:u,continue:()=>(s==null?void 0:s())?l:Promise.resolve(),cancelRetry:c,continueRetry:d}}const au=console;function G0(){let e=[],t=0,n=d=>{d()},r=d=>{d()};const s=d=>{let p;t++;try{p=d()}finally{t--,t||l()}return p},i=d=>{t?e.push(d):Mc(()=>{n(d)})},o=d=>(...p)=>{i(()=>{d(...p)})},l=()=>{const d=e;e=[],d.length&&Mc(()=>{r(()=>{d.forEach(p=>{n(p)})})})};return{batch:s,batchCalls:o,schedule:i,setNotifyFunction:d=>{n=d},setBatchNotifyFunction:d=>{r=d}}}const qe=G0();class Sp{destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),W0(this.cacheTime)&&(this.gcTimeout=setTimeout(()=>{this.optionalRemove()},this.cacheTime))}updateCacheTime(t){this.cacheTime=Math.max(this.cacheTime||0,t??(ru?1/0:5*60*1e3))}clearGcTimeout(){this.gcTimeout&&(clearTimeout(this.gcTimeout),this.gcTimeout=void 0)}}class Y0 extends Sp{constructor(t){super(),this.abortSignalConsumed=!1,this.defaultOptions=t.defaultOptions,this.setOptions(t.options),this.observers=[],this.cache=t.cache,this.logger=t.logger||au,this.queryKey=t.queryKey,this.queryHash=t.queryHash,this.initialState=t.state||J0(this.options),this.state=this.initialState,this.scheduleGc()}get meta(){return this.options.meta}setOptions(t){this.options={...this.defaultOptions,...t},this.updateCacheTime(this.options.cacheTime)}optionalRemove(){!this.observers.length&&this.state.fetchStatus==="idle"&&this.cache.remove(this)}setData(t,n){const r=q0(this.state.data,t,this.options);return this.dispatch({data:r,type:"success",dataUpdatedAt:n==null?void 0:n.updatedAt,manual:n==null?void 0:n.manual}),r}setState(t,n){this.dispatch({type:"setState",state:t,setStateOptions:n})}cancel(t){var n;const r=this.promise;return(n=this.retryer)==null||n.cancel(t),r?r.then(vt).catch(vt):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}reset(){this.destroy(),this.setState(this.initialState)}isActive(){return this.observers.some(t=>t.options.enabled!==!1)}isDisabled(){return this.getObserversCount()>0&&!this.isActive()}isStale(){return this.state.isInvalidated||!this.state.dataUpdatedAt||this.observers.some(t=>t.getCurrentResult().isStale)}isStaleByTime(t=0){return this.state.isInvalidated||!this.state.dataUpdatedAt||!B0(this.state.dataUpdatedAt,t)}onFocus(){var t;const n=this.observers.find(r=>r.shouldFetchOnWindowFocus());n&&n.refetch({cancelRefetch:!1}),(t=this.retryer)==null||t.continue()}onOnline(){var t;const n=this.observers.find(r=>r.shouldFetchOnReconnect());n&&n.refetch({cancelRefetch:!1}),(t=this.retryer)==null||t.continue()}addObserver(t){this.observers.includes(t)||(this.observers.push(t),this.clearGcTimeout(),this.cache.notify({type:"observerAdded",query:this,observer:t}))}removeObserver(t){this.observers.includes(t)&&(this.observers=this.observers.filter(n=>n!==t),this.observers.length||(this.retryer&&(this.abortSignalConsumed?this.retryer.cancel({revert:!0}):this.retryer.cancelRetry()),this.scheduleGc()),this.cache.notify({type:"observerRemoved",query:this,observer:t}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||this.dispatch({type:"invalidate"})}fetch(t,n){var r,s;if(this.state.fetchStatus!=="idle"){if(this.state.dataUpdatedAt&&n!=null&&n.cancelRefetch)this.cancel({silent:!0});else if(this.promise){var i;return(i=this.retryer)==null||i.continueRetry(),this.promise}}if(t&&this.setOptions(t),!this.options.queryFn){const v=this.observers.find(x=>x.options.queryFn);v&&this.setOptions(v.options)}const o=H0(),l={queryKey:this.queryKey,pageParam:void 0,meta:this.meta},u=v=>{Object.defineProperty(v,"signal",{enumerable:!0,get:()=>{if(o)return this.abortSignalConsumed=!0,o.signal}})};u(l);const c=()=>this.options.queryFn?(this.abortSignalConsumed=!1,this.options.queryFn(l)):Promise.reject("Missing queryFn for queryKey '"+this.options.queryHash+"'"),d={fetchOptions:n,options:this.options,queryKey:this.queryKey,state:this.state,fetchFn:c};if(u(d),(r=this.options.behavior)==null||r.onFetch(d),this.revertState=this.state,this.state.fetchStatus==="idle"||this.state.fetchMeta!==((s=d.fetchOptions)==null?void 0:s.meta)){var p;this.dispatch({type:"fetch",meta:(p=d.fetchOptions)==null?void 0:p.meta})}const h=v=>{if(Ga(v)&&v.silent||this.dispatch({type:"error",error:v}),!Ga(v)){var x,w,k,m;(x=(w=this.cache.config).onError)==null||x.call(w,v,this),(k=(m=this.cache.config).onSettled)==null||k.call(m,this.state.data,v,this)}this.isFetchingOptimistic||this.scheduleGc(),this.isFetchingOptimistic=!1};return this.retryer=kp({fn:d.fetchFn,abort:o==null?void 0:o.abort.bind(o),onSuccess:v=>{var x,w,k,m;if(typeof v>"u"){h(new Error(this.queryHash+" data is undefined"));return}this.setData(v),(x=(w=this.cache.config).onSuccess)==null||x.call(w,v,this),(k=(m=this.cache.config).onSettled)==null||k.call(m,v,this.state.error,this),this.isFetchingOptimistic||this.scheduleGc(),this.isFetchingOptimistic=!1},onError:h,onFail:(v,x)=>{this.dispatch({type:"failed",failureCount:v,error:x})},onPause:()=>{this.dispatch({type:"pause"})},onContinue:()=>{this.dispatch({type:"continue"})},retry:d.options.retry,retryDelay:d.options.retryDelay,networkMode:d.options.networkMode}),this.promise=this.retryer.promise,this.promise}dispatch(t){const n=r=>{var s,i;switch(t.type){case"failed":return{...r,fetchFailureCount:t.failureCount,fetchFailureReason:t.error};case"pause":return{...r,fetchStatus:"paused"};case"continue":return{...r,fetchStatus:"fetching"};case"fetch":return{...r,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:(s=t.meta)!=null?s:null,fetchStatus:iu(this.options.networkMode)?"fetching":"paused",...!r.dataUpdatedAt&&{error:null,status:"loading"}};case"success":return{...r,data:t.data,dataUpdateCount:r.dataUpdateCount+1,dataUpdatedAt:(i=t.dataUpdatedAt)!=null?i:Date.now(),error:null,isInvalidated:!1,status:"success",...!t.manual&&{fetchStatus:"idle",fetchFailureCount:0,fetchFailureReason:null}};case"error":const o=t.error;return Ga(o)&&o.revert&&this.revertState?{...this.revertState,fetchStatus:"idle"}:{...r,error:o,errorUpdateCount:r.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:r.fetchFailureCount+1,fetchFailureReason:o,fetchStatus:"idle",status:"error"};case"invalidate":return{...r,isInvalidated:!0};case"setState":return{...r,...t.state}}};this.state=n(this.state),qe.batch(()=>{this.observers.forEach(r=>{r.onQueryUpdate(t)}),this.cache.notify({query:this,type:"updated",action:t})})}}function J0(e){const t=typeof e.initialData=="function"?e.initialData():e.initialData,n=typeof t<"u",r=n?typeof e.initialDataUpdatedAt=="function"?e.initialDataUpdatedAt():e.initialDataUpdatedAt:0;return{data:t,dataUpdateCount:0,dataUpdatedAt:n?r??Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null,isInvalidated:!1,status:n?"success":"loading",fetchStatus:"idle"}}class X0 extends ca{constructor(t){super(),this.config=t||{},this.queries=[],this.queriesMap={}}build(t,n,r){var s;const i=n.queryKey,o=(s=n.queryHash)!=null?s:su(i,n);let l=this.get(o);return l||(l=new Y0({cache:this,logger:t.getLogger(),queryKey:i,queryHash:o,options:t.defaultQueryOptions(n),state:r,defaultOptions:t.getQueryDefaults(i)}),this.add(l)),l}add(t){this.queriesMap[t.queryHash]||(this.queriesMap[t.queryHash]=t,this.queries.push(t),this.notify({type:"added",query:t}))}remove(t){const n=this.queriesMap[t.queryHash];n&&(t.destroy(),this.queries=this.queries.filter(r=>r!==t),n===t&&delete this.queriesMap[t.queryHash],this.notify({type:"removed",query:t}))}clear(){qe.batch(()=>{this.queries.forEach(t=>{this.remove(t)})})}get(t){return this.queriesMap[t]}getAll(){return this.queries}find(t,n){const[r]=Gt(t,n);return typeof r.exact>"u"&&(r.exact=!0),this.queries.find(s=>Tc(r,s))}findAll(t,n){const[r]=Gt(t,n);return Object.keys(r).length>0?this.queries.filter(s=>Tc(r,s)):this.queries}notify(t){qe.batch(()=>{this.listeners.forEach(({listener:n})=>{n(t)})})}onFocus(){qe.batch(()=>{this.queries.forEach(t=>{t.onFocus()})})}onOnline(){qe.batch(()=>{this.queries.forEach(t=>{t.onOnline()})})}}class Z0 extends Sp{constructor(t){super(),this.defaultOptions=t.defaultOptions,this.mutationId=t.mutationId,this.mutationCache=t.mutationCache,this.logger=t.logger||au,this.observers=[],this.state=t.state||ey(),this.setOptions(t.options),this.scheduleGc()}setOptions(t){this.options={...this.defaultOptions,...t},this.updateCacheTime(this.options.cacheTime)}get meta(){return this.options.meta}setState(t){this.dispatch({type:"setState",state:t})}addObserver(t){this.observers.includes(t)||(this.observers.push(t),this.clearGcTimeout(),this.mutationCache.notify({type:"observerAdded",mutation:this,observer:t}))}removeObserver(t){this.observers=this.observers.filter(n=>n!==t),this.scheduleGc(),this.mutationCache.notify({type:"observerRemoved",mutation:this,observer:t})}optionalRemove(){this.observers.length||(this.state.status==="loading"?this.scheduleGc():this.mutationCache.remove(this))}continue(){var t,n;return(t=(n=this.retryer)==null?void 0:n.continue())!=null?t:this.execute()}async execute(){const t=()=>{var C;return this.retryer=kp({fn:()=>this.options.mutationFn?this.options.mutationFn(this.state.variables):Promise.reject("No mutationFn found"),onFail:(j,R)=>{this.dispatch({type:"failed",failureCount:j,error:R})},onPause:()=>{this.dispatch({type:"pause"})},onContinue:()=>{this.dispatch({type:"continue"})},retry:(C=this.options.retry)!=null?C:0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode}),this.retryer.promise},n=this.state.status==="loading";try{var r,s,i,o,l,u,c,d;if(!n){var p,h,v,x;this.dispatch({type:"loading",variables:this.options.variables}),await((p=(h=this.mutationCache.config).onMutate)==null?void 0:p.call(h,this.state.variables,this));const j=await((v=(x=this.options).onMutate)==null?void 0:v.call(x,this.state.variables));j!==this.state.context&&this.dispatch({type:"loading",context:j,variables:this.state.variables})}const C=await t();return await((r=(s=this.mutationCache.config).onSuccess)==null?void 0:r.call(s,C,this.state.variables,this.state.context,this)),await((i=(o=this.options).onSuccess)==null?void 0:i.call(o,C,this.state.variables,this.state.context)),await((l=(u=this.mutationCache.config).onSettled)==null?void 0:l.call(u,C,null,this.state.variables,this.state.context,this)),await((c=(d=this.options).onSettled)==null?void 0:c.call(d,C,null,this.state.variables,this.state.context)),this.dispatch({type:"success",data:C}),C}catch(C){try{var w,k,m,f,g,b,E,T;throw await((w=(k=this.mutationCache.config).onError)==null?void 0:w.call(k,C,this.state.variables,this.state.context,this)),await((m=(f=this.options).onError)==null?void 0:m.call(f,C,this.state.variables,this.state.context)),await((g=(b=this.mutationCache.config).onSettled)==null?void 0:g.call(b,void 0,C,this.state.variables,this.state.context,this)),await((E=(T=this.options).onSettled)==null?void 0:E.call(T,void 0,C,this.state.variables,this.state.context)),C}finally{this.dispatch({type:"error",error:C})}}}dispatch(t){const n=r=>{switch(t.type){case"failed":return{...r,failureCount:t.failureCount,failureReason:t.error};case"pause":return{...r,isPaused:!0};case"continue":return{...r,isPaused:!1};case"loading":return{...r,context:t.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:!iu(this.options.networkMode),status:"loading",variables:t.variables};case"success":return{...r,data:t.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1};case"error":return{...r,data:void 0,error:t.error,failureCount:r.failureCount+1,failureReason:t.error,isPaused:!1,status:"error"};case"setState":return{...r,...t.state}}};this.state=n(this.state),qe.batch(()=>{this.observers.forEach(r=>{r.onMutationUpdate(t)}),this.mutationCache.notify({mutation:this,type:"updated",action:t})})}}function ey(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0}}class ty extends ca{constructor(t){super(),this.config=t||{},this.mutations=[],this.mutationId=0}build(t,n,r){const s=new Z0({mutationCache:this,logger:t.getLogger(),mutationId:++this.mutationId,options:t.defaultMutationOptions(n),state:r,defaultOptions:n.mutationKey?t.getMutationDefaults(n.mutationKey):void 0});return this.add(s),s}add(t){this.mutations.push(t),this.notify({type:"added",mutation:t})}remove(t){this.mutations=this.mutations.filter(n=>n!==t),this.notify({type:"removed",mutation:t})}clear(){qe.batch(()=>{this.mutations.forEach(t=>{this.remove(t)})})}getAll(){return this.mutations}find(t){return typeof t.exact>"u"&&(t.exact=!0),this.mutations.find(n=>Oc(t,n))}findAll(t){return this.mutations.filter(n=>Oc(t,n))}notify(t){qe.batch(()=>{this.listeners.forEach(({listener:n})=>{n(t)})})}resumePausedMutations(){var t;return this.resuming=((t=this.resuming)!=null?t:Promise.resolve()).then(()=>{const n=this.mutations.filter(r=>r.state.isPaused);return qe.batch(()=>n.reduce((r,s)=>r.then(()=>s.continue().catch(vt)),Promise.resolve()))}).then(()=>{this.resuming=void 0}),this.resuming}}function ny(){return{onFetch:e=>{e.fetchFn=()=>{var t,n,r,s,i,o;const l=(t=e.fetchOptions)==null||(n=t.meta)==null?void 0:n.refetchPage,u=(r=e.fetchOptions)==null||(s=r.meta)==null?void 0:s.fetchMore,c=u==null?void 0:u.pageParam,d=(u==null?void 0:u.direction)==="forward",p=(u==null?void 0:u.direction)==="backward",h=((i=e.state.data)==null?void 0:i.pages)||[],v=((o=e.state.data)==null?void 0:o.pageParams)||[];let x=v,w=!1;const k=T=>{Object.defineProperty(T,"signal",{enumerable:!0,get:()=>{var C;if((C=e.signal)!=null&&C.aborted)w=!0;else{var j;(j=e.signal)==null||j.addEventListener("abort",()=>{w=!0})}return e.signal}})},m=e.options.queryFn||(()=>Promise.reject("Missing queryFn for queryKey '"+e.options.queryHash+"'")),f=(T,C,j,R)=>(x=R?[C,...x]:[...x,C],R?[j,...T]:[...T,j]),g=(T,C,j,R)=>{if(w)return Promise.reject("Cancelled");if(typeof j>"u"&&!C&&T.length)return Promise.resolve(T);const M={queryKey:e.queryKey,pageParam:j,meta:e.options.meta};k(M);const K=m(M);return Promise.resolve(K).then(Ce=>f(T,j,Ce,R))};let b;if(!h.length)b=g([]);else if(d){const T=typeof c<"u",C=T?c:Ic(e.options,h);b=g(h,T,C)}else if(p){const T=typeof c<"u",C=T?c:ry(e.options,h);b=g(h,T,C,!0)}else{x=[];const T=typeof e.options.getNextPageParam>"u";b=(l&&h[0]?l(h[0],0,h):!0)?g([],T,v[0]):Promise.resolve(f([],v[0],h[0]));for(let j=1;j<h.length;j++)b=b.then(R=>{if(l&&h[j]?l(h[j],j,h):!0){const K=T?v[j]:Ic(e.options,R);return g(R,T,K)}return Promise.resolve(f(R,v[j],h[j]))})}return b.then(T=>({pages:T,pageParams:x}))}}}}function Ic(e,t){return e.getNextPageParam==null?void 0:e.getNextPageParam(t[t.length-1],t)}function ry(e,t){return e.getPreviousPageParam==null?void 0:e.getPreviousPageParam(t[0],t)}class sy{constructor(t={}){this.queryCache=t.queryCache||new X0,this.mutationCache=t.mutationCache||new ty,this.logger=t.logger||au,this.defaultOptions=t.defaultOptions||{},this.queryDefaults=[],this.mutationDefaults=[],this.mountCount=0}mount(){this.mountCount++,this.mountCount===1&&(this.unsubscribeFocus=Zo.subscribe(()=>{Zo.isFocused()&&(this.resumePausedMutations(),this.queryCache.onFocus())}),this.unsubscribeOnline=Hi.subscribe(()=>{Hi.isOnline()&&(this.resumePausedMutations(),this.queryCache.onOnline())}))}unmount(){var t,n;this.mountCount--,this.mountCount===0&&((t=this.unsubscribeFocus)==null||t.call(this),this.unsubscribeFocus=void 0,(n=this.unsubscribeOnline)==null||n.call(this),this.unsubscribeOnline=void 0)}isFetching(t,n){const[r]=Gt(t,n);return r.fetchStatus="fetching",this.queryCache.findAll(r).length}isMutating(t){return this.mutationCache.findAll({...t,fetching:!0}).length}getQueryData(t,n){var r;return(r=this.queryCache.find(t,n))==null?void 0:r.state.data}ensureQueryData(t,n,r){const s=Ys(t,n,r),i=this.getQueryData(s.queryKey);return i?Promise.resolve(i):this.fetchQuery(s)}getQueriesData(t){return this.getQueryCache().findAll(t).map(({queryKey:n,state:r})=>{const s=r.data;return[n,s]})}setQueryData(t,n,r){const s=this.queryCache.find(t),i=s==null?void 0:s.state.data,o=U0(n,i);if(typeof o>"u")return;const l=Ys(t),u=this.defaultQueryOptions(l);return this.queryCache.build(this,u).setData(o,{...r,manual:!0})}setQueriesData(t,n,r){return qe.batch(()=>this.getQueryCache().findAll(t).map(({queryKey:s})=>[s,this.setQueryData(s,n,r)]))}getQueryState(t,n){var r;return(r=this.queryCache.find(t,n))==null?void 0:r.state}removeQueries(t,n){const[r]=Gt(t,n),s=this.queryCache;qe.batch(()=>{s.findAll(r).forEach(i=>{s.remove(i)})})}resetQueries(t,n,r){const[s,i]=Gt(t,n,r),o=this.queryCache,l={type:"active",...s};return qe.batch(()=>(o.findAll(s).forEach(u=>{u.reset()}),this.refetchQueries(l,i)))}cancelQueries(t,n,r){const[s,i={}]=Gt(t,n,r);typeof i.revert>"u"&&(i.revert=!0);const o=qe.batch(()=>this.queryCache.findAll(s).map(l=>l.cancel(i)));return Promise.all(o).then(vt).catch(vt)}invalidateQueries(t,n,r){const[s,i]=Gt(t,n,r);return qe.batch(()=>{var o,l;if(this.queryCache.findAll(s).forEach(c=>{c.invalidate()}),s.refetchType==="none")return Promise.resolve();const u={...s,type:(o=(l=s.refetchType)!=null?l:s.type)!=null?o:"active"};return this.refetchQueries(u,i)})}refetchQueries(t,n,r){const[s,i]=Gt(t,n,r),o=qe.batch(()=>this.queryCache.findAll(s).filter(u=>!u.isDisabled()).map(u=>{var c;return u.fetch(void 0,{...i,cancelRefetch:(c=i==null?void 0:i.cancelRefetch)!=null?c:!0,meta:{refetchPage:s.refetchPage}})}));let l=Promise.all(o).then(vt);return i!=null&&i.throwOnError||(l=l.catch(vt)),l}fetchQuery(t,n,r){const s=Ys(t,n,r),i=this.defaultQueryOptions(s);typeof i.retry>"u"&&(i.retry=!1);const o=this.queryCache.build(this,i);return o.isStaleByTime(i.staleTime)?o.fetch(i):Promise.resolve(o.state.data)}prefetchQuery(t,n,r){return this.fetchQuery(t,n,r).then(vt).catch(vt)}fetchInfiniteQuery(t,n,r){const s=Ys(t,n,r);return s.behavior=ny(),this.fetchQuery(s)}prefetchInfiniteQuery(t,n,r){return this.fetchInfiniteQuery(t,n,r).then(vt).catch(vt)}resumePausedMutations(){return this.mutationCache.resumePausedMutations()}getQueryCache(){return this.queryCache}getMutationCache(){return this.mutationCache}getLogger(){return this.logger}getDefaultOptions(){return this.defaultOptions}setDefaultOptions(t){this.defaultOptions=t}setQueryDefaults(t,n){const r=this.queryDefaults.find(s=>En(t)===En(s.queryKey));r?r.defaultOptions=n:this.queryDefaults.push({queryKey:t,defaultOptions:n})}getQueryDefaults(t){if(!t)return;const n=this.queryDefaults.find(r=>Bi(t,r.queryKey));return n==null?void 0:n.defaultOptions}setMutationDefaults(t,n){const r=this.mutationDefaults.find(s=>En(t)===En(s.mutationKey));r?r.defaultOptions=n:this.mutationDefaults.push({mutationKey:t,defaultOptions:n})}getMutationDefaults(t){if(!t)return;const n=this.mutationDefaults.find(r=>Bi(t,r.mutationKey));return n==null?void 0:n.defaultOptions}defaultQueryOptions(t){if(t!=null&&t._defaulted)return t;const n={...this.defaultOptions.queries,...this.getQueryDefaults(t==null?void 0:t.queryKey),...t,_defaulted:!0};return!n.queryHash&&n.queryKey&&(n.queryHash=su(n.queryKey,n)),typeof n.refetchOnReconnect>"u"&&(n.refetchOnReconnect=n.networkMode!=="always"),typeof n.useErrorBoundary>"u"&&(n.useErrorBoundary=!!n.suspense),n}defaultMutationOptions(t){return t!=null&&t._defaulted?t:{...this.defaultOptions.mutations,...this.getMutationDefaults(t==null?void 0:t.mutationKey),...t,_defaulted:!0}}clear(){this.queryCache.clear(),this.mutationCache.clear()}}const _c=N.createContext(void 0),iy=N.createContext(!1);function ay(e,t){return e||(t&&typeof window<"u"?(window.ReactQueryClientContext||(window.ReactQueryClientContext=_c),window.ReactQueryClientContext):_c)}const oy=({client:e,children:t,context:n,contextSharing:r=!1})=>{N.useEffect(()=>(e.mount(),()=>{e.unmount()}),[e]);const s=ay(n,r);return N.createElement(iy.Provider,{value:!n&&r},N.createElement(s.Provider,{value:e},t))};var Cp={exports:{}},ly="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED",uy=ly,cy=uy;function Ep(){}function Pp(){}Pp.resetWarningCache=Ep;var dy=function(){function e(r,s,i,o,l,u){if(u!==cy){var c=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw c.name="Invariant Violation",c}}e.isRequired=e;function t(){return e}var n={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:Pp,resetWarningCache:Ep};return n.PropTypes=n,n};Cp.exports=dy();var fy=Cp.exports;const se=br(fy);var py=typeof Element<"u",hy=typeof Map=="function",my=typeof Set=="function",gy=typeof ArrayBuffer=="function"&&!!ArrayBuffer.isView;function pi(e,t){if(e===t)return!0;if(e&&t&&typeof e=="object"&&typeof t=="object"){if(e.constructor!==t.constructor)return!1;var n,r,s;if(Array.isArray(e)){if(n=e.length,n!=t.length)return!1;for(r=n;r--!==0;)if(!pi(e[r],t[r]))return!1;return!0}var i;if(hy&&e instanceof Map&&t instanceof Map){if(e.size!==t.size)return!1;for(i=e.entries();!(r=i.next()).done;)if(!t.has(r.value[0]))return!1;for(i=e.entries();!(r=i.next()).done;)if(!pi(r.value[1],t.get(r.value[0])))return!1;return!0}if(my&&e instanceof Set&&t instanceof Set){if(e.size!==t.size)return!1;for(i=e.entries();!(r=i.next()).done;)if(!t.has(r.value[0]))return!1;return!0}if(gy&&ArrayBuffer.isView(e)&&ArrayBuffer.isView(t)){if(n=e.length,n!=t.length)return!1;for(r=n;r--!==0;)if(e[r]!==t[r])return!1;return!0}if(e.constructor===RegExp)return e.source===t.source&&e.flags===t.flags;if(e.valueOf!==Object.prototype.valueOf&&typeof e.valueOf=="function"&&typeof t.valueOf=="function")return e.valueOf()===t.valueOf();if(e.toString!==Object.prototype.toString&&typeof e.toString=="function"&&typeof t.toString=="function")return e.toString()===t.toString();if(s=Object.keys(e),n=s.length,n!==Object.keys(t).length)return!1;for(r=n;r--!==0;)if(!Object.prototype.hasOwnProperty.call(t,s[r]))return!1;if(py&&e instanceof Element)return!1;for(r=n;r--!==0;)if(!((s[r]==="_owner"||s[r]==="__v"||s[r]==="__o")&&e.$$typeof)&&!pi(e[s[r]],t[s[r]]))return!1;return!0}return e!==e&&t!==t}var yy=function(t,n){try{return pi(t,n)}catch(r){if((r.message||"").match(/stack|recursion/i))return console.warn("react-fast-compare cannot handle circular refs"),!1;throw r}};const vy=br(yy);var xy=function(e,t,n,r,s,i,o,l){if(!e){var u;if(t===void 0)u=new Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var c=[n,r,s,i,o,l],d=0;u=new Error(t.replace(/%s/g,function(){return c[d++]})),u.name="Invariant Violation"}throw u.framesToPop=1,u}},wy=xy;const Lc=br(wy);var jy=function(t,n,r,s){var i=r?r.call(s,t,n):void 0;if(i!==void 0)return!!i;if(t===n)return!0;if(typeof t!="object"||!t||typeof n!="object"||!n)return!1;var o=Object.keys(t),l=Object.keys(n);if(o.length!==l.length)return!1;for(var u=Object.prototype.hasOwnProperty.bind(n),c=0;c<o.length;c++){var d=o[c];if(!u(d))return!1;var p=t[d],h=n[d];if(i=r?r.call(s,p,h,d):void 0,i===!1||i===void 0&&p!==h)return!1}return!0};const by=br(jy);function ke(){return ke=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},ke.apply(this,arguments)}function ou(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,el(e,t)}function el(e,t){return el=Object.setPrototypeOf||function(n,r){return n.__proto__=r,n},el(e,t)}function Fc(e,t){if(e==null)return{};var n,r,s={},i=Object.keys(e);for(r=0;r<i.length;r++)t.indexOf(n=i[r])>=0||(s[n]=e[n]);return s}var B={BASE:"base",BODY:"body",HEAD:"head",HTML:"html",LINK:"link",META:"meta",NOSCRIPT:"noscript",SCRIPT:"script",STYLE:"style",TITLE:"title",FRAGMENT:"Symbol(react.fragment)"},Ny={rel:["amphtml","canonical","alternate"]},ky={type:["application/ld+json"]},Sy={charset:"",name:["robots","description"],property:["og:type","og:title","og:url","og:image","og:image:alt","og:description","twitter:url","twitter:title","twitter:description","twitter:image","twitter:image:alt","twitter:card","twitter:site"]},Dc=Object.keys(B).map(function(e){return B[e]}),qi={accesskey:"accessKey",charset:"charSet",class:"className",contenteditable:"contentEditable",contextmenu:"contextMenu","http-equiv":"httpEquiv",itemprop:"itemProp",tabindex:"tabIndex"},Cy=Object.keys(qi).reduce(function(e,t){return e[qi[t]]=t,e},{}),fr=function(e,t){for(var n=e.length-1;n>=0;n-=1){var r=e[n];if(Object.prototype.hasOwnProperty.call(r,t))return r[t]}return null},Ey=function(e){var t=fr(e,B.TITLE),n=fr(e,"titleTemplate");if(Array.isArray(t)&&(t=t.join("")),n&&t)return n.replace(/%s/g,function(){return t});var r=fr(e,"defaultTitle");return t||r||void 0},Py=function(e){return fr(e,"onChangeClientState")||function(){}},Ya=function(e,t){return t.filter(function(n){return n[e]!==void 0}).map(function(n){return n[e]}).reduce(function(n,r){return ke({},n,r)},{})},Ty=function(e,t){return t.filter(function(n){return n[B.BASE]!==void 0}).map(function(n){return n[B.BASE]}).reverse().reduce(function(n,r){if(!n.length)for(var s=Object.keys(r),i=0;i<s.length;i+=1){var o=s[i].toLowerCase();if(e.indexOf(o)!==-1&&r[o])return n.concat(r)}return n},[])},_r=function(e,t,n){var r={};return n.filter(function(s){return!!Array.isArray(s[e])||(s[e]!==void 0&&console&&typeof console.warn=="function"&&console.warn("Helmet: "+e+' should be of type "Array". Instead found type "'+typeof s[e]+'"'),!1)}).map(function(s){return s[e]}).reverse().reduce(function(s,i){var o={};i.filter(function(p){for(var h,v=Object.keys(p),x=0;x<v.length;x+=1){var w=v[x],k=w.toLowerCase();t.indexOf(k)===-1||h==="rel"&&p[h].toLowerCase()==="canonical"||k==="rel"&&p[k].toLowerCase()==="stylesheet"||(h=k),t.indexOf(w)===-1||w!=="innerHTML"&&w!=="cssText"&&w!=="itemprop"||(h=w)}if(!h||!p[h])return!1;var m=p[h].toLowerCase();return r[h]||(r[h]={}),o[h]||(o[h]={}),!r[h][m]&&(o[h][m]=!0,!0)}).reverse().forEach(function(p){return s.push(p)});for(var l=Object.keys(o),u=0;u<l.length;u+=1){var c=l[u],d=ke({},r[c],o[c]);r[c]=d}return s},[]).reverse()},Oy=function(e,t){if(Array.isArray(e)&&e.length){for(var n=0;n<e.length;n+=1)if(e[n][t])return!0}return!1},Tp=function(e){return Array.isArray(e)?e.join(""):e},Ja=function(e,t){return Array.isArray(e)?e.reduce(function(n,r){return function(s,i){for(var o=Object.keys(s),l=0;l<o.length;l+=1)if(i[o[l]]&&i[o[l]].includes(s[o[l]]))return!0;return!1}(r,t)?n.priority.push(r):n.default.push(r),n},{priority:[],default:[]}):{default:e}},$c=function(e,t){var n;return ke({},e,((n={})[t]=void 0,n))},zy=[B.NOSCRIPT,B.SCRIPT,B.STYLE],Xa=function(e,t){return t===void 0&&(t=!0),t===!1?String(e):String(e).replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/'/g,"&#x27;")},Uc=function(e){return Object.keys(e).reduce(function(t,n){var r=e[n]!==void 0?n+'="'+e[n]+'"':""+n;return t?t+" "+r:r},"")},Wc=function(e,t){return t===void 0&&(t={}),Object.keys(e).reduce(function(n,r){return n[qi[r]||r]=e[r],n},t)},hi=function(e,t){return t.map(function(n,r){var s,i=((s={key:r})["data-rh"]=!0,s);return Object.keys(n).forEach(function(o){var l=qi[o]||o;l==="innerHTML"||l==="cssText"?i.dangerouslySetInnerHTML={__html:n.innerHTML||n.cssText}:i[l]=n[o]}),_.createElement(e,i)})},ot=function(e,t,n){switch(e){case B.TITLE:return{toComponent:function(){return s=t.titleAttributes,(i={key:r=t.title})["data-rh"]=!0,o=Wc(s,i),[_.createElement(B.TITLE,o,r)];var r,s,i,o},toString:function(){return function(r,s,i,o){var l=Uc(i),u=Tp(s);return l?"<"+r+' data-rh="true" '+l+">"+Xa(u,o)+"</"+r+">":"<"+r+' data-rh="true">'+Xa(u,o)+"</"+r+">"}(e,t.title,t.titleAttributes,n)}};case"bodyAttributes":case"htmlAttributes":return{toComponent:function(){return Wc(t)},toString:function(){return Uc(t)}};default:return{toComponent:function(){return hi(e,t)},toString:function(){return function(r,s,i){return s.reduce(function(o,l){var u=Object.keys(l).filter(function(p){return!(p==="innerHTML"||p==="cssText")}).reduce(function(p,h){var v=l[h]===void 0?h:h+'="'+Xa(l[h],i)+'"';return p?p+" "+v:v},""),c=l.innerHTML||l.cssText||"",d=zy.indexOf(r)===-1;return o+"<"+r+' data-rh="true" '+u+(d?"/>":">"+c+"</"+r+">")},"")}(e,t,n)}}}},tl=function(e){var t=e.baseTag,n=e.bodyAttributes,r=e.encode,s=e.htmlAttributes,i=e.noscriptTags,o=e.styleTags,l=e.title,u=l===void 0?"":l,c=e.titleAttributes,d=e.linkTags,p=e.metaTags,h=e.scriptTags,v={toComponent:function(){},toString:function(){return""}};if(e.prioritizeSeoTags){var x=function(w){var k=w.linkTags,m=w.scriptTags,f=w.encode,g=Ja(w.metaTags,Sy),b=Ja(k,Ny),E=Ja(m,ky);return{priorityMethods:{toComponent:function(){return[].concat(hi(B.META,g.priority),hi(B.LINK,b.priority),hi(B.SCRIPT,E.priority))},toString:function(){return ot(B.META,g.priority,f)+" "+ot(B.LINK,b.priority,f)+" "+ot(B.SCRIPT,E.priority,f)}},metaTags:g.default,linkTags:b.default,scriptTags:E.default}}(e);v=x.priorityMethods,d=x.linkTags,p=x.metaTags,h=x.scriptTags}return{priority:v,base:ot(B.BASE,t,r),bodyAttributes:ot("bodyAttributes",n,r),htmlAttributes:ot("htmlAttributes",s,r),link:ot(B.LINK,d,r),meta:ot(B.META,p,r),noscript:ot(B.NOSCRIPT,i,r),script:ot(B.SCRIPT,h,r),style:ot(B.STYLE,o,r),title:ot(B.TITLE,{title:u,titleAttributes:c},r)}},Js=[],nl=function(e,t){var n=this;t===void 0&&(t=typeof document<"u"),this.instances=[],this.value={setHelmet:function(r){n.context.helmet=r},helmetInstances:{get:function(){return n.canUseDOM?Js:n.instances},add:function(r){(n.canUseDOM?Js:n.instances).push(r)},remove:function(r){var s=(n.canUseDOM?Js:n.instances).indexOf(r);(n.canUseDOM?Js:n.instances).splice(s,1)}}},this.context=e,this.canUseDOM=t,t||(e.helmet=tl({baseTag:[],bodyAttributes:{},encodeSpecialCharacters:!0,htmlAttributes:{},linkTags:[],metaTags:[],noscriptTags:[],scriptTags:[],styleTags:[],title:"",titleAttributes:{}}))},Op=_.createContext({}),Ay=se.shape({setHelmet:se.func,helmetInstances:se.shape({get:se.func,add:se.func,remove:se.func})}),My=typeof document<"u",sr=function(e){function t(n){var r;return(r=e.call(this,n)||this).helmetData=new nl(r.props.context,t.canUseDOM),r}return ou(t,e),t.prototype.render=function(){return _.createElement(Op.Provider,{value:this.helmetData.value},this.props.children)},t}(N.Component);sr.canUseDOM=My,sr.propTypes={context:se.shape({helmet:se.shape()}),children:se.node.isRequired},sr.defaultProps={context:{}},sr.displayName="HelmetProvider";var qn=function(e,t){var n,r=document.head||document.querySelector(B.HEAD),s=r.querySelectorAll(e+"[data-rh]"),i=[].slice.call(s),o=[];return t&&t.length&&t.forEach(function(l){var u=document.createElement(e);for(var c in l)Object.prototype.hasOwnProperty.call(l,c)&&(c==="innerHTML"?u.innerHTML=l.innerHTML:c==="cssText"?u.styleSheet?u.styleSheet.cssText=l.cssText:u.appendChild(document.createTextNode(l.cssText)):u.setAttribute(c,l[c]===void 0?"":l[c]));u.setAttribute("data-rh","true"),i.some(function(d,p){return n=p,u.isEqualNode(d)})?i.splice(n,1):o.push(u)}),i.forEach(function(l){return l.parentNode.removeChild(l)}),o.forEach(function(l){return r.appendChild(l)}),{oldTags:i,newTags:o}},Za=function(e,t){var n=document.getElementsByTagName(e)[0];if(n){for(var r=n.getAttribute("data-rh"),s=r?r.split(","):[],i=[].concat(s),o=Object.keys(t),l=0;l<o.length;l+=1){var u=o[l],c=t[u]||"";n.getAttribute(u)!==c&&n.setAttribute(u,c),s.indexOf(u)===-1&&s.push(u);var d=i.indexOf(u);d!==-1&&i.splice(d,1)}for(var p=i.length-1;p>=0;p-=1)n.removeAttribute(i[p]);s.length===i.length?n.removeAttribute("data-rh"):n.getAttribute("data-rh")!==o.join(",")&&n.setAttribute("data-rh",o.join(","))}},Bc=function(e,t){var n=e.baseTag,r=e.htmlAttributes,s=e.linkTags,i=e.metaTags,o=e.noscriptTags,l=e.onChangeClientState,u=e.scriptTags,c=e.styleTags,d=e.title,p=e.titleAttributes;Za(B.BODY,e.bodyAttributes),Za(B.HTML,r),function(w,k){w!==void 0&&document.title!==w&&(document.title=Tp(w)),Za(B.TITLE,k)}(d,p);var h={baseTag:qn(B.BASE,n),linkTags:qn(B.LINK,s),metaTags:qn(B.META,i),noscriptTags:qn(B.NOSCRIPT,o),scriptTags:qn(B.SCRIPT,u),styleTags:qn(B.STYLE,c)},v={},x={};Object.keys(h).forEach(function(w){var k=h[w],m=k.newTags,f=k.oldTags;m.length&&(v[w]=m),f.length&&(x[w]=h[w].oldTags)}),t&&t(),l(e,v,x)},Lr=null,Qi=function(e){function t(){for(var r,s=arguments.length,i=new Array(s),o=0;o<s;o++)i[o]=arguments[o];return(r=e.call.apply(e,[this].concat(i))||this).rendered=!1,r}ou(t,e);var n=t.prototype;return n.shouldComponentUpdate=function(r){return!by(r,this.props)},n.componentDidUpdate=function(){this.emitChange()},n.componentWillUnmount=function(){this.props.context.helmetInstances.remove(this),this.emitChange()},n.emitChange=function(){var r,s,i=this.props.context,o=i.setHelmet,l=null,u=(r=i.helmetInstances.get().map(function(c){var d=ke({},c.props);return delete d.context,d}),{baseTag:Ty(["href"],r),bodyAttributes:Ya("bodyAttributes",r),defer:fr(r,"defer"),encode:fr(r,"encodeSpecialCharacters"),htmlAttributes:Ya("htmlAttributes",r),linkTags:_r(B.LINK,["rel","href"],r),metaTags:_r(B.META,["name","charset","http-equiv","property","itemprop"],r),noscriptTags:_r(B.NOSCRIPT,["innerHTML"],r),onChangeClientState:Py(r),scriptTags:_r(B.SCRIPT,["src","innerHTML"],r),styleTags:_r(B.STYLE,["cssText"],r),title:Ey(r),titleAttributes:Ya("titleAttributes",r),prioritizeSeoTags:Oy(r,"prioritizeSeoTags")});sr.canUseDOM?(s=u,Lr&&cancelAnimationFrame(Lr),s.defer?Lr=requestAnimationFrame(function(){Bc(s,function(){Lr=null})}):(Bc(s),Lr=null)):tl&&(l=tl(u)),o(l)},n.init=function(){this.rendered||(this.rendered=!0,this.props.context.helmetInstances.add(this),this.emitChange())},n.render=function(){return this.init(),null},t}(N.Component);Qi.propTypes={context:Ay.isRequired},Qi.displayName="HelmetDispatcher";var Ry=["children"],Iy=["children"],hn=function(e){function t(){return e.apply(this,arguments)||this}ou(t,e);var n=t.prototype;return n.shouldComponentUpdate=function(r){return!vy($c(this.props,"helmetData"),$c(r,"helmetData"))},n.mapNestedChildrenToProps=function(r,s){if(!s)return null;switch(r.type){case B.SCRIPT:case B.NOSCRIPT:return{innerHTML:s};case B.STYLE:return{cssText:s};default:throw new Error("<"+r.type+" /> elements are self-closing and can not contain children. Refer to our API for more information.")}},n.flattenArrayTypeChildren=function(r){var s,i=r.child,o=r.arrayTypeChildren;return ke({},o,((s={})[i.type]=[].concat(o[i.type]||[],[ke({},r.newChildProps,this.mapNestedChildrenToProps(i,r.nestedChildren))]),s))},n.mapObjectTypeChildren=function(r){var s,i,o=r.child,l=r.newProps,u=r.newChildProps,c=r.nestedChildren;switch(o.type){case B.TITLE:return ke({},l,((s={})[o.type]=c,s.titleAttributes=ke({},u),s));case B.BODY:return ke({},l,{bodyAttributes:ke({},u)});case B.HTML:return ke({},l,{htmlAttributes:ke({},u)});default:return ke({},l,((i={})[o.type]=ke({},u),i))}},n.mapArrayTypeChildrenToProps=function(r,s){var i=ke({},s);return Object.keys(r).forEach(function(o){var l;i=ke({},i,((l={})[o]=r[o],l))}),i},n.warnOnInvalidChildren=function(r,s){return Lc(Dc.some(function(i){return r.type===i}),typeof r.type=="function"?"You may be attempting to nest <Helmet> components within each other, which is not allowed. Refer to our API for more information.":"Only elements types "+Dc.join(", ")+" are allowed. Helmet does not support rendering <"+r.type+"> elements. Refer to our API for more information."),Lc(!s||typeof s=="string"||Array.isArray(s)&&!s.some(function(i){return typeof i!="string"}),"Helmet expects a string as a child of <"+r.type+">. Did you forget to wrap your children in braces? ( <"+r.type+">{``}</"+r.type+"> ) Refer to our API for more information."),!0},n.mapChildrenToProps=function(r,s){var i=this,o={};return _.Children.forEach(r,function(l){if(l&&l.props){var u=l.props,c=u.children,d=Fc(u,Ry),p=Object.keys(d).reduce(function(v,x){return v[Cy[x]||x]=d[x],v},{}),h=l.type;switch(typeof h=="symbol"?h=h.toString():i.warnOnInvalidChildren(l,c),h){case B.FRAGMENT:s=i.mapChildrenToProps(c,s);break;case B.LINK:case B.META:case B.NOSCRIPT:case B.SCRIPT:case B.STYLE:o=i.flattenArrayTypeChildren({child:l,arrayTypeChildren:o,newChildProps:p,nestedChildren:c});break;default:s=i.mapObjectTypeChildren({child:l,newProps:s,newChildProps:p,nestedChildren:c})}}}),this.mapArrayTypeChildrenToProps(o,s)},n.render=function(){var r=this.props,s=r.children,i=Fc(r,Iy),o=ke({},i),l=i.helmetData;return s&&(o=this.mapChildrenToProps(s,o)),!l||l instanceof nl||(l=new nl(l.context,l.instances)),l?_.createElement(Qi,ke({},o,{context:l.value,helmetData:void 0})):_.createElement(Op.Consumer,null,function(u){return _.createElement(Qi,ke({},o,{context:u}))})},t}(N.Component);hn.propTypes={base:se.object,bodyAttributes:se.object,children:se.oneOfType([se.arrayOf(se.node),se.node]),defaultTitle:se.string,defer:se.bool,encodeSpecialCharacters:se.bool,htmlAttributes:se.object,link:se.arrayOf(se.object),meta:se.arrayOf(se.object),noscript:se.arrayOf(se.object),onChangeClientState:se.func,script:se.arrayOf(se.object),style:se.arrayOf(se.object),title:se.string,titleAttributes:se.object,titleTemplate:se.string,prioritizeSeoTags:se.bool,helmetData:se.object},hn.defaultProps={defer:!0,encodeSpecialCharacters:!0,prioritizeSeoTags:!1},hn.displayName="Helmet";function _y(e,{insertAt:t}={}){if(!e||typeof document>"u")return;let n=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css",t==="top"&&n.firstChild?n.insertBefore(r,n.firstChild):n.appendChild(r),r.styleSheet?r.styleSheet.cssText=e:r.appendChild(document.createTextNode(e))}_y(`[data-sonner-toaster]{position:fixed;width:var(--width);font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;--gray1: hsl(0, 0%, 99%);--gray2: hsl(0, 0%, 97.3%);--gray3: hsl(0, 0%, 95.1%);--gray4: hsl(0, 0%, 93%);--gray5: hsl(0, 0%, 90.9%);--gray6: hsl(0, 0%, 88.7%);--gray7: hsl(0, 0%, 85.8%);--gray8: hsl(0, 0%, 78%);--gray9: hsl(0, 0%, 56.1%);--gray10: hsl(0, 0%, 52.3%);--gray11: hsl(0, 0%, 43.5%);--gray12: hsl(0, 0%, 9%);--border-radius: 6px;box-sizing:border-box;padding:0;margin:0;list-style:none;outline:none;z-index:999999999}[data-sonner-toaster][data-x-position=right]{right:max(var(--offset),env(safe-area-inset-right))}[data-sonner-toaster][data-x-position=left]{left:max(var(--offset),env(safe-area-inset-left))}[data-sonner-toaster][data-x-position=center]{left:50%;transform:translate(-50%)}[data-sonner-toaster][data-y-position=top]{top:max(var(--offset),env(safe-area-inset-top))}[data-sonner-toaster][data-y-position=bottom]{bottom:max(var(--offset),env(safe-area-inset-bottom))}[data-sonner-toast]{--y: translateY(100%);--lift-amount: calc(var(--lift) * var(--gap));z-index:var(--z-index);position:absolute;opacity:0;transform:var(--y);touch-action:none;will-change:transform,opacity,height;transition:transform .4s,opacity .4s,height .4s,box-shadow .2s;box-sizing:border-box;outline:none}[data-sonner-toast][data-styled=true]{padding:16px;background:var(--normal-bg);border:1px solid var(--normal-border);color:var(--normal-text);border-radius:var(--border-radius);box-shadow:0 4px 12px #0000001a;width:var(--width);font-size:13px;display:flex;align-items:center;gap:6px}[data-sonner-toast]:focus-visible{box-shadow:0 4px 12px #0000001a,0 0 0 2px #0003}[data-sonner-toast][data-y-position=top]{top:0;--y: translateY(-100%);--lift: 1;--lift-amount: calc(1 * var(--gap))}[data-sonner-toast][data-y-position=bottom]{bottom:0;--y: translateY(100%);--lift: -1;--lift-amount: calc(var(--lift) * var(--gap))}[data-sonner-toast] [data-description]{font-weight:400;line-height:1.4;color:inherit}[data-sonner-toast] [data-title]{font-weight:500;line-height:1.5;color:inherit}[data-sonner-toast] [data-icon]{display:flex;height:16px;width:16px;position:relative;justify-content:flex-start;align-items:center;flex-shrink:0;margin-left:-3px;margin-right:4px}[data-sonner-toast][data-promise=true] [data-icon]>svg{opacity:0;transform:scale(.8);transform-origin:center;animation:sonner-fade-in .3s ease forwards}[data-sonner-toast] [data-icon]>*{flex-shrink:0}[data-sonner-toast] [data-icon] svg{margin-left:-1px}[data-sonner-toast] [data-content]{display:flex;flex-direction:column;gap:2px}[data-sonner-toast] [data-button]{border-radius:4px;padding-left:8px;padding-right:8px;height:24px;font-size:12px;color:var(--normal-bg);background:var(--normal-text);margin-left:auto;border:none;cursor:pointer;outline:none;transition:opacity .4s,box-shadow .2s}[data-sonner-toast] [data-button]:focus-visible{box-shadow:0 0 0 2px #0006}[data-sonner-toast] [data-button]:first-of-type{margin-left:auto}[data-sonner-toast] [data-cancel]{color:var(--color);background:var(--border-color)}[data-sonner-toast] [data-close-button]{position:absolute;left:0;top:0;height:20px;width:20px;display:flex;justify-content:center;align-items:center;padding:0;background:var(--gray1);color:var(--gray12);border:1px solid var(--gray4);transform:translate(-35%,-35%);border-radius:50%;opacity:0;cursor:pointer;z-index:1;transition:opacity .1s,background .2s,border-color .2s}[data-sonner-toast] [data-disabled=true]{cursor:not-allowed}[data-sonner-toast]:hover [data-close-button]{opacity:1}[data-sonner-toast]:hover [data-close-button]:hover{background:var(--gray2);border-color:var(--gray5)}[data-sonner-toast][data-swiping=true]:before{content:"";position:absolute;left:0;right:0;height:100%}[data-sonner-toast][data-y-position=top][data-swiping=true]:before{bottom:50%;transform:scaleY(3) translateY(50%)}[data-sonner-toast][data-y-position=bottom][data-swiping=true]:before{top:50%;transform:scaleY(3) translateY(-50%)}[data-sonner-toast][data-swiping=false][data-removed=true]:before{content:"";position:absolute;inset:0;transform:scaleY(2)}[data-sonner-toast]:after{content:"";position:absolute;left:0;height:calc(var(--gap) + 1px);bottom:100%;width:100%}[data-sonner-toast][data-mounted=true]{--y: translateY(0);opacity:1}[data-sonner-toast][data-expanded=false][data-front=false]{--scale: var(--toasts-before) * .05 + 1;--y: translateY(calc(var(--lift-amount) * var(--toasts-before))) scale(calc(-1 * var(--scale)));height:var(--front-toast-height)}[data-sonner-toast]>*{transition:opacity .4s}[data-sonner-toast][data-expanded=false][data-front=false][data-styled=true]>*{opacity:0}[data-sonner-toast][data-visible=false]{opacity:0;pointer-events:none}[data-sonner-toast][data-mounted=true][data-expanded=true]{--y: translateY(calc(var(--lift) * var(--offset)));height:var(--initial-height)}[data-sonner-toast][data-removed=true][data-front=true][data-swipe-out=false]{--y: translateY(calc(var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=true]{--y: translateY(calc(var(--lift) * var(--offset) + var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=false]{--y: translateY(40%);opacity:0;transition:transform .5s,opacity .2s}[data-sonner-toast][data-removed=true][data-front=false]:before{height:calc(var(--initial-height) + 20%)}[data-sonner-toast][data-swiping=true]{transform:var(--y) translateY(var(--swipe-amount, 0px));transition:none}[data-sonner-toast][data-swipe-out=true][data-y-position=bottom],[data-sonner-toast][data-swipe-out=true][data-y-position=top]{animation:swipe-out .2s ease-out forwards}@keyframes swipe-out{0%{transform:translateY(calc(var(--lift) * var(--offset) + var(--swipe-amount)));opacity:1}to{transform:translateY(calc(var(--lift) * var(--offset) + var(--swipe-amount) + var(--lift) * -100%));opacity:0}}@media (max-width: 600px){[data-sonner-toaster]{position:fixed;--mobile-offset: 16px;right:var(--mobile-offset);left:var(--mobile-offset);width:100%}[data-sonner-toaster] [data-sonner-toast]{left:0;right:0;width:calc(100% - 32px)}[data-sonner-toaster][data-x-position=left]{left:var(--mobile-offset)}[data-sonner-toaster][data-y-position=bottom]{bottom:20px}[data-sonner-toaster][data-y-position=top]{top:20px}[data-sonner-toaster][data-x-position=center]{left:var(--mobile-offset);right:var(--mobile-offset);transform:none}}[data-sonner-toaster][data-theme=light]{--normal-bg: #fff;--normal-border: var(--gray3);--normal-text: var(--gray12);--success-bg: hsl(143, 85%, 96%);--success-border: hsl(145, 92%, 91%);--success-text: hsl(140, 100%, 27%);--error-bg: hsl(359, 100%, 97%);--error-border: hsl(359, 100%, 94%);--error-text: hsl(360, 100%, 45%)}[data-sonner-toaster][data-theme=light] [data-sonner-toast][data-invert=true]{--normal-bg: #000;--normal-border: hsl(0, 0%, 20%);--normal-text: var(--gray1)}[data-sonner-toaster][data-theme=dark] [data-sonner-toast][data-invert=true]{--normal-bg: #fff;--normal-border: var(--gray3);--normal-text: var(--gray12)}[data-sonner-toaster][data-theme=dark]{--normal-bg: #000;--normal-border: hsl(0, 0%, 20%);--normal-text: var(--gray1);--success-bg: hsl(150, 100%, 6%);--success-border: hsl(147, 100%, 12%);--success-text: hsl(150, 86%, 65%);--error-bg: hsl(358, 76%, 10%);--error-border: hsl(357, 89%, 16%);--error-text: hsl(358, 100%, 81%)}[data-rich-colors=true] [data-sonner-toast][data-type=success],[data-rich-colors=true] [data-sonner-toast][data-type=success] [data-close-button]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true] [data-sonner-toast][data-type=error],[data-rich-colors=true] [data-sonner-toast][data-type=error] [data-close-button]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}.sonner-loading-wrapper{--size: 16px;height:var(--size);width:var(--size);position:absolute;inset:0;z-index:10}.sonner-loading-wrapper[data-visible=false]{transform-origin:center;animation:sonner-fade-out .2s ease forwards}.sonner-spinner{position:relative;top:50%;left:50%;height:var(--size);width:var(--size)}.sonner-loading-bar{animation:sonner-spin 1.2s linear infinite;background:var(--gray11);border-radius:6px;height:8%;left:-10%;position:absolute;top:-3.9%;width:24%}.sonner-loading-bar:nth-child(1){animation-delay:-1.2s;transform:rotate(.0001deg) translate(146%)}.sonner-loading-bar:nth-child(2){animation-delay:-1.1s;transform:rotate(30deg) translate(146%)}.sonner-loading-bar:nth-child(3){animation-delay:-1s;transform:rotate(60deg) translate(146%)}.sonner-loading-bar:nth-child(4){animation-delay:-.9s;transform:rotate(90deg) translate(146%)}.sonner-loading-bar:nth-child(5){animation-delay:-.8s;transform:rotate(120deg) translate(146%)}.sonner-loading-bar:nth-child(6){animation-delay:-.7s;transform:rotate(150deg) translate(146%)}.sonner-loading-bar:nth-child(7){animation-delay:-.6s;transform:rotate(180deg) translate(146%)}.sonner-loading-bar:nth-child(8){animation-delay:-.5s;transform:rotate(210deg) translate(146%)}.sonner-loading-bar:nth-child(9){animation-delay:-.4s;transform:rotate(240deg) translate(146%)}.sonner-loading-bar:nth-child(10){animation-delay:-.3s;transform:rotate(270deg) translate(146%)}.sonner-loading-bar:nth-child(11){animation-delay:-.2s;transform:rotate(300deg) translate(146%)}.sonner-loading-bar:nth-child(12){animation-delay:-.1s;transform:rotate(330deg) translate(146%)}@keyframes sonner-fade-in{0%{opacity:0;transform:scale(.8)}to{opacity:1;transform:scale(1)}}@keyframes sonner-fade-out{0%{opacity:1;transform:scale(1)}to{opacity:0;transform:scale(.8)}}@keyframes sonner-spin{0%{opacity:1}to{opacity:.15}}@media (prefers-reduced-motion){[data-sonner-toast],[data-sonner-toast]>*,.sonner-loading-bar{transition:none!important;animation:none!important}}
68
+ `);var Ly=e=>{switch(e){case"success":return $y;case"error":return Uy;default:return null}},Fy=Array(12).fill(0),Dy=({visible:e})=>_.createElement("div",{className:"sonner-loading-wrapper","data-visible":e},_.createElement("div",{className:"sonner-spinner"},Fy.map((t,n)=>_.createElement("div",{className:"sonner-loading-bar",key:`spinner-bar-${n}`})))),$y=_.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},_.createElement("path",{fillRule:"evenodd",d:"M10 18a8 8 0 100-16 8 8 0 000 16zm3.857-9.809a.75.75 0 00-1.214-.882l-3.483 4.79-1.88-1.88a.75.75 0 10-1.06 1.061l2.5 2.5a.75.75 0 001.137-.089l4-5.5z",clipRule:"evenodd"})),Uy=_.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},_.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-8-5a.75.75 0 01.75.75v4.5a.75.75 0 01-1.5 0v-4.5A.75.75 0 0110 5zm0 10a1 1 0 100-2 1 1 0 000 2z",clipRule:"evenodd"})),rl=0,Wy=class{constructor(){this.subscribe=e=>(this.subscribers.push(e),()=>{let t=this.subscribers.indexOf(e);this.subscribers.splice(t,1)}),this.publish=e=>{this.subscribers.forEach(t=>t(e))},this.addToast=e=>{this.publish(e),this.toasts=[...this.toasts,e]},this.create=e=>{var t;let{message:n,...r}=e,s=typeof(e==null?void 0:e.id)=="number"||((t=e.id)==null?void 0:t.length)>0?e.id:rl++;return this.toasts.find(i=>i.id===s)?this.toasts=this.toasts.map(i=>i.id===s?(this.publish({...i,...e,id:s,title:n}),{...i,...e,id:s,title:n}):i):this.addToast({title:n,...r,id:s}),s},this.dismiss=e=>(e||this.toasts.forEach(t=>{this.subscribers.forEach(n=>n({id:t.id,dismiss:!0}))}),this.subscribers.forEach(t=>t({id:e,dismiss:!0})),e),this.message=(e,t)=>this.create({...t,message:e}),this.error=(e,t)=>this.create({...t,message:e,type:"error"}),this.success=(e,t)=>this.create({...t,type:"success",message:e}),this.promise=(e,t)=>{let n=this.create({...t,promise:e,type:"loading",message:t.loading});return(e instanceof Promise?e:e()).then(r=>{let s=typeof t.success=="function"?t.success(r):t.success;this.create({id:n,type:"success",message:s})}).catch(r=>{let s=typeof t.error=="function"?t.error(r):t.error;this.create({id:n,type:"error",message:s})}),n},this.custom=(e,t)=>{let n=(t==null?void 0:t.id)||rl++;this.publish({jsx:e(n),id:n,...t})},this.subscribers=[],this.toasts=[]}},Yt=new Wy,By=(e,t)=>{let n=(t==null?void 0:t.id)||rl++;return Yt.addToast({title:e,...t,id:n}),n},Hy=By;Object.assign(Hy,{success:Yt.success,error:Yt.error,custom:Yt.custom,message:Yt.message,promise:Yt.promise,dismiss:Yt.dismiss});var qy=3,Qy="32px",Vy=4e3,Ky=356,zp=14,Gy=20,Yy=200,Jy=e=>{let{invert:t,toast:n,interacting:r,setHeights:s,visibleToasts:i,heights:o,index:l,toasts:u,expanded:c,removeToast:d,closeButton:p,style:h,className:v="",descriptionClassName:x="",duration:w,position:k,expandByDefault:m}=e,[f,g]=_.useState(!1),[b,E]=_.useState(!1),[T,C]=_.useState(!1),[j,R]=_.useState(!1),[M,K]=_.useState(0),[G,Ce]=_.useState(0),P=_.useRef(null),q=l===0,Y=l+1<=i,ae=n.type,A=n.className||"",F=n.descriptionClassName||"",U=_.useMemo(()=>o.findIndex(V=>V.toastId===n.id)||0,[o,n.id]),ee=_.useMemo(()=>n.duration||w||Vy,[n.duration,w]),Q=_.useRef(0),X=_.useRef(0),ue=_.useRef(ee),Ae=_.useRef(0),ve=_.useRef(null),[Ge,kt]=k.split("-"),Be=_.useMemo(()=>o.reduce((V,ce,Te)=>Te>=U?V:V+ce.height,0),[o,U]),be=n.invert||t,Er=ae==="loading";X.current=_.useMemo(()=>U*zp+Be,[U,Be]),_.useEffect(()=>{g(!0)},[]),_.useLayoutEffect(()=>{if(!f)return;let V=P.current,ce=V.style.height;V.style.height="auto";let Te=V.getBoundingClientRect().height;V.style.height=ce,Ce(Te),s(ht=>ht.find(St=>St.toastId===n.id)?ht.map(St=>St.toastId===n.id?{...St,height:Te}:St):[{toastId:n.id,height:Te},...ht])},[f,n.title,n.description,s,n.id]);let fe=_.useCallback(()=>{E(!0),K(X.current),s(V=>V.filter(ce=>ce.toastId!==n.id)),setTimeout(()=>{d(n)},Yy)},[n,d,s,X]);return _.useEffect(()=>{if(n.promise&&ae==="loading"||n.duration===1/0)return;let V;return c||r?(()=>{if(Ae.current<Q.current){let ce=new Date().getTime()-Q.current;ue.current=ue.current-ce}Ae.current=new Date().getTime()})():(Q.current=new Date().getTime(),V=setTimeout(()=>{var ce;(ce=n.onAutoClose)==null||ce.call(n,n),fe()},ue.current)),()=>clearTimeout(V)},[c,r,m,n,ee,fe,n.promise,ae]),_.useEffect(()=>{let V=P.current;if(V){let ce=V.getBoundingClientRect().height;return Ce(ce),s(Te=>[{toastId:n.id,height:ce},...Te]),()=>s(Te=>Te.filter(ht=>ht.toastId!==n.id))}},[s,n.id]),_.useEffect(()=>{n.delete&&fe()},[fe,n.delete]),_.createElement("li",{"aria-live":n.important?"assertive":"polite","aria-atomic":"true",role:"status",tabIndex:0,ref:P,className:v+" "+A,"data-sonner-toast":"","data-styled":!n.jsx,"data-mounted":f,"data-promise":!!n.promise,"data-removed":b,"data-visible":Y,"data-y-position":Ge,"data-x-position":kt,"data-index":l,"data-front":q,"data-swiping":T,"data-type":ae,"data-invert":be,"data-swipe-out":j,"data-expanded":!!(c||m&&f),style:{"--index":l,"--toasts-before":l,"--z-index":u.length-l,"--offset":`${b?M:X.current}px`,"--initial-height":m?"auto":`${G}px`,...h,...n.style},onPointerDown:V=>{Er||(K(X.current),V.target.setPointerCapture(V.pointerId),V.target.tagName!=="BUTTON"&&(C(!0),ve.current={x:V.clientX,y:V.clientY}))},onPointerUp:()=>{var V,ce,Te;if(j)return;ve.current=null;let ht=Number(((V=P.current)==null?void 0:V.style.getPropertyValue("--swipe-amount").replace("px",""))||0);if(Math.abs(ht)>=Gy){K(X.current),(ce=n.onDismiss)==null||ce.call(n,n),fe(),R(!0);return}(Te=P.current)==null||Te.style.setProperty("--swipe-amount","0px"),C(!1)},onPointerMove:V=>{var ce;if(!ve.current)return;let Te=V.clientY-ve.current.y,ht=V.clientX-ve.current.x,St=(Ge==="top"?Math.min:Math.max)(0,Te),Wn=V.pointerType==="touch"?10:2;Math.abs(St)>Wn?(ce=P.current)==null||ce.style.setProperty("--swipe-amount",`${Te}px`):Math.abs(ht)>Wn&&(ve.current=null)}},p&&!n.jsx?_.createElement("button",{"aria-label":"Close toast","data-disabled":Er,"data-close-button":!0,onClick:Er?void 0:()=>{var V;fe(),(V=n.onDismiss)==null||V.call(n,n)}},_.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"12",height:"12",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"},_.createElement("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),_.createElement("line",{x1:"6",y1:"6",x2:"18",y2:"18"}))):null,n.jsx||_.isValidElement(n.title)?n.jsx||n.title:_.createElement(_.Fragment,null,ae||n.icon||n.promise?_.createElement("div",{"data-icon":""},n.promise?_.createElement(Dy,{visible:ae==="loading"}):null,n.icon||Ly(ae)):null,_.createElement("div",{"data-content":""},_.createElement("div",{"data-title":""},n.title),n.description?_.createElement("div",{"data-description":"",className:x+F},n.description):null),n.cancel?_.createElement("button",{"data-button":!0,"data-cancel":!0,onClick:()=>{var V;fe(),(V=n.cancel)!=null&&V.onClick&&n.cancel.onClick()}},n.cancel.label):null,n.action?_.createElement("button",{"data-button":"",onClick:V=>{var ce;(ce=n.action)==null||ce.onClick(V),!V.defaultPrevented&&fe()}},n.action.label):null))},Xy=e=>{var t;let{invert:n,position:r="bottom-right",hotkey:s=["altKey","KeyT"],expand:i,closeButton:o,className:l,offset:u,theme:c="light",richColors:d,duration:p,style:h,visibleToasts:v=qy,toastOptions:x}=e,[w,k]=_.useState([]),[m,f]=_.useState([]),[g,b]=_.useState(!1),[E,T]=_.useState(!1),[C,j]=_.useState(c!=="system"?c:typeof window<"u"&&window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"),[R,M]=r.split("-"),K=_.useRef(null),G=s.join("+").replace(/Key/g,"").replace(/Digit/g,""),Ce=_.useCallback(P=>k(q=>q.filter(({id:Y})=>Y!==P.id)),[]);return _.useEffect(()=>Yt.subscribe(P=>{if(P.dismiss){k(q=>q.map(Y=>Y.id===P.id?{...Y,delete:!0}:Y));return}setTimeout(()=>{Dg.flushSync(()=>{k(q=>{let Y=q.findIndex(ae=>ae.id===P.id);return Y!==-1?[...q.slice(0,Y),{...q[Y],...P},...q.slice(Y+1)]:[P,...q]})})})}),[]),_.useEffect(()=>{if(c!=="system"){j(c);return}typeof window<"u"&&window.matchMedia("(prefers-color-scheme: dark)").addEventListener("change",({matches:P})=>{j(P?"dark":"light")})},[c]),_.useEffect(()=>{w.length<=1&&b(!1)},[w]),_.useEffect(()=>{let P=q=>{var Y,ae;s.every(A=>q[A]||q.code===A)&&(b(!0),(Y=K.current)==null||Y.focus()),q.code==="Escape"&&(document.activeElement===K.current||(ae=K.current)!=null&&ae.contains(document.activeElement))&&b(!1)};return document.addEventListener("keydown",P),()=>document.removeEventListener("keydown",P)},[s]),w.length?_.createElement("section",{"aria-label":`Notifications ${G}`,tabIndex:-1},_.createElement("ol",{tabIndex:-1,ref:K,className:l,"data-sonner-toaster":!0,"data-theme":C,"data-rich-colors":d,"data-y-position":R,"data-x-position":M,style:{"--front-toast-height":`${(t=m[0])==null?void 0:t.height}px`,"--offset":typeof u=="number"?`${u}px`:u||Qy,"--width":`${Ky}px`,"--gap":`${zp}px`,...h},onMouseEnter:()=>b(!0),onMouseMove:()=>b(!0),onMouseLeave:()=>{E||b(!1)},onPointerDown:()=>{T(!0)},onPointerUp:()=>T(!1)},w.map((P,q)=>_.createElement(Jy,{key:P.id,index:q,toast:P,duration:p,className:x==null?void 0:x.className,descriptionClassName:x==null?void 0:x.descriptionClassName,invert:n,visibleToasts:v,closeButton:o,interacting:E,position:r,style:x==null?void 0:x.style,removeToast:Ce,toasts:w,heights:m,setHeights:f,expandByDefault:i,expanded:g})))):null},Zy={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};const ev=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),re=(e,t)=>{const n=N.forwardRef(({color:r="currentColor",size:s=24,strokeWidth:i=2,absoluteStrokeWidth:o,children:l,...u},c)=>N.createElement("svg",{ref:c,...Zy,width:s,height:s,stroke:r,strokeWidth:o?Number(i)*24/Number(s):i,className:`lucide lucide-${ev(e)}`,...u},[...t.map(([d,p])=>N.createElement(d,p)),...(Array.isArray(l)?l:[l])||[]]));return n.displayName=`${e}`,n},eo=re("Activity",[["path",{d:"M22 12h-4l-3 9L9 3l-3 9H2",key:"d5dnw9"}]]),Jt=re("AlertCircle",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["line",{x1:"12",x2:"12",y1:"8",y2:"12",key:"1pkeuh"}],["line",{x1:"12",x2:"12.01",y1:"16",y2:"16",key:"4dfq90"}]]),sl=re("AlertTriangle",[["path",{d:"m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3Z",key:"c3ski4"}],["path",{d:"M12 9v4",key:"juzpu7"}],["path",{d:"M12 17h.01",key:"p32p05"}]]),tv=re("ArrowRight",[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"m12 5 7 7-7 7",key:"xquz4c"}]]),nv=re("BarChart3",[["path",{d:"M3 3v18h18",key:"1s2lah"}],["path",{d:"M18 17V9",key:"2bz60n"}],["path",{d:"M13 17V5",key:"1frdt8"}],["path",{d:"M8 17v-3",key:"17ska0"}]]),rv=re("Building2",[["path",{d:"M6 22V4a2 2 0 0 1 2-2h8a2 2 0 0 1 2 2v18Z",key:"1b4qmf"}],["path",{d:"M6 12H4a2 2 0 0 0-2 2v6a2 2 0 0 0 2 2h2",key:"i71pzd"}],["path",{d:"M18 9h2a2 2 0 0 1 2 2v9a2 2 0 0 1-2 2h-2",key:"10jefs"}],["path",{d:"M10 6h4",key:"1itunk"}],["path",{d:"M10 10h4",key:"tcdvrf"}],["path",{d:"M10 14h4",key:"kelpxr"}],["path",{d:"M10 18h4",key:"1ulq68"}]]),jr=re("CheckCircle",[["path",{d:"M22 11.08V12a10 10 0 1 1-5.93-9.14",key:"g774vq"}],["polyline",{points:"22 4 12 14.01 9 11.01",key:"6xbx8j"}]]),Fr=re("ChevronDown",[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]]),Dr=re("ChevronRight",[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]]),Mt=re("Clock",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["polyline",{points:"12 6 12 12 16 14",key:"68esgv"}]]),sv=re("FileCode",[["path",{d:"M14.5 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7.5L14.5 2z",key:"1nnpy2"}],["polyline",{points:"14 2 14 8 20 8",key:"1ew0cm"}],["path",{d:"m10 13-2 2 2 2",key:"17smn8"}],["path",{d:"m14 17 2-2-2-2",key:"14mezr"}]]),iv=re("Filter",[["polygon",{points:"22 3 2 3 10 12.46 10 19 14 21 14 12.46 22 3",key:"1yg77f"}]]),Ap=re("FolderOpen",[["path",{d:"m6 14 1.45-2.9A2 2 0 0 1 9.24 10H20a2 2 0 0 1 1.94 2.5l-1.55 6a2 2 0 0 1-1.94 1.5H4a2 2 0 0 1-2-2V5c0-1.1.9-2 2-2h3.93a2 2 0 0 1 1.66.9l.82 1.2a2 2 0 0 0 1.66.9H18a2 2 0 0 1 2 2v2",key:"1nmvlm"}]]),Mp=re("Home",[["path",{d:"m3 9 9-7 9 7v11a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2z",key:"y5dka4"}],["polyline",{points:"9 22 9 12 15 12 15 22",key:"e2us08"}]]),av=re("Layers",[["polygon",{points:"12 2 2 7 12 12 22 7 12 2",key:"1b0ttc"}],["polyline",{points:"2 17 12 22 22 17",key:"imjtdl"}],["polyline",{points:"2 12 12 17 22 12",key:"5dexcv"}]]),ir=re("Loader2",[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]]),rs=re("MapPin",[["path",{d:"M20 10c0 6-8 12-8 12s-8-6-8-12a8 8 0 0 1 16 0Z",key:"2oe9fu"}],["circle",{cx:"12",cy:"10",r:"3",key:"ilqhr7"}]]),ov=re("Menu",[["line",{x1:"4",x2:"20",y1:"12",y2:"12",key:"1e0a9i"}],["line",{x1:"4",x2:"20",y1:"6",y2:"6",key:"1owob3"}],["line",{x1:"4",x2:"20",y1:"18",y2:"18",key:"yk5zj1"}]]),lv=re("PauseCircle",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["line",{x1:"10",x2:"10",y1:"15",y2:"9",key:"c1nkhi"}],["line",{x1:"14",x2:"14",y1:"15",y2:"9",key:"h65svq"}]]),mi=re("PenSquare",[["path",{d:"M11 4H4a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2v-7",key:"1qinfi"}],["path",{d:"M18.5 2.5a2.12 2.12 0 0 1 3 3L12 15l-4 1 1-4Z",key:"w2jsv5"}]]),uv=re("PlayCircle",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["polygon",{points:"10 8 16 12 10 16 10 8",key:"1cimsy"}]]),pr=re("Plus",[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]]),en=re("RefreshCw",[["path",{d:"M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8",key:"v9h5vc"}],["path",{d:"M21 3v5h-5",key:"1q7to0"}],["path",{d:"M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16",key:"3uifl3"}],["path",{d:"M8 16H3v5",key:"1cv678"}]]),gi=re("Save",[["path",{d:"M19 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h11l5 5v11a2 2 0 0 1-2 2z",key:"1owoqh"}],["polyline",{points:"17 21 17 13 7 13 7 21",key:"1md35c"}],["polyline",{points:"7 3 7 8 15 8",key:"8nz8an"}]]),cv=re("Server",[["rect",{width:"20",height:"8",x:"2",y:"2",rx:"2",ry:"2",key:"ngkwjq"}],["rect",{width:"20",height:"8",x:"2",y:"14",rx:"2",ry:"2",key:"iecqi9"}],["line",{x1:"6",x2:"6.01",y1:"6",y2:"6",key:"16zg32"}],["line",{x1:"6",x2:"6.01",y1:"18",y2:"18",key:"nzw8ys"}]]),Vr=re("Settings",[["path",{d:"M12.22 2h-.44a2 2 0 0 0-2 2v.18a2 2 0 0 1-1 1.73l-.43.25a2 2 0 0 1-2 0l-.15-.08a2 2 0 0 0-2.73.73l-.22.38a2 2 0 0 0 .73 2.73l.15.1a2 2 0 0 1 1 1.72v.51a2 2 0 0 1-1 1.74l-.15.09a2 2 0 0 0-.73 2.73l.22.38a2 2 0 0 0 2.73.73l.15-.08a2 2 0 0 1 2 0l.43.25a2 2 0 0 1 1 1.73V20a2 2 0 0 0 2 2h.44a2 2 0 0 0 2-2v-.18a2 2 0 0 1 1-1.73l.43-.25a2 2 0 0 1 2 0l.15.08a2 2 0 0 0 2.73-.73l.22-.39a2 2 0 0 0-.73-2.73l-.15-.08a2 2 0 0 1-1-1.74v-.5a2 2 0 0 1 1-1.74l.15-.09a2 2 0 0 0 .73-2.73l-.22-.38a2 2 0 0 0-2.73-.73l-.15.08a2 2 0 0 1-2 0l-.43-.25a2 2 0 0 1-1-1.73V4a2 2 0 0 0-2-2z",key:"1qme2f"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]]),dv=re("Timer",[["line",{x1:"10",x2:"14",y1:"2",y2:"2",key:"14vaq8"}],["line",{x1:"12",x2:"15",y1:"14",y2:"11",key:"17fdiu"}],["circle",{cx:"12",cy:"14",r:"8",key:"1e1u0o"}]]),fv=re("ToggleLeft",[["rect",{width:"20",height:"12",x:"2",y:"6",rx:"6",ry:"6",key:"f2vt7d"}],["circle",{cx:"8",cy:"12",r:"2",key:"1nvbw3"}]]),pv=re("ToggleRight",[["rect",{width:"20",height:"12",x:"2",y:"6",rx:"6",ry:"6",key:"f2vt7d"}],["circle",{cx:"16",cy:"12",r:"2",key:"4ma0v8"}]]),ss=re("Trash2",[["path",{d:"M3 6h18",key:"d0wm0j"}],["path",{d:"M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6",key:"4alrt4"}],["path",{d:"M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2",key:"v07s0e"}],["line",{x1:"10",x2:"10",y1:"11",y2:"17",key:"1uufr5"}],["line",{x1:"14",x2:"14",y1:"11",y2:"17",key:"xtxkd"}]]),hv=re("TrendingUp",[["polyline",{points:"22 7 13.5 15.5 8.5 10.5 2 17",key:"126l90"}],["polyline",{points:"16 7 22 7 22 13",key:"kwv8wd"}]]),mv=re("User",[["path",{d:"M19 21v-2a4 4 0 0 0-4-4H9a4 4 0 0 0-4 4v2",key:"975kel"}],["circle",{cx:"12",cy:"7",r:"4",key:"17ys0d"}]]),gv=re("Users",[["path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2",key:"1yyitq"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}],["path",{d:"M22 21v-2a4 4 0 0 0-3-3.87",key:"kshegd"}],["path",{d:"M16 3.13a4 4 0 0 1 0 7.75",key:"1da9ce"}]]),Hc=re("XCircle",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m15 9-6 6",key:"1uzhvr"}],["path",{d:"m9 9 6 6",key:"z0biqf"}]]),Pn=re("X",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]]),Rp=re("Zap",[["polygon",{points:"13 2 3 14 12 14 11 22 21 10 12 10 13 2",key:"45s27k"}]]);function Ip(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e)){var s=e.length;for(t=0;t<s;t++)e[t]&&(n=Ip(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function yv(){for(var e,t,n=0,r="",s=arguments.length;n<s;n++)(e=arguments[n])&&(t=Ip(e))&&(r&&(r+=" "),r+=t);return r}function vv(){for(var e=0,t,n,r="";e<arguments.length;)(t=arguments[e++])&&(n=_p(t))&&(r&&(r+=" "),r+=n);return r}function _p(e){if(typeof e=="string")return e;for(var t,n="",r=0;r<e.length;r++)e[r]&&(t=_p(e[r]))&&(n&&(n+=" "),n+=t);return n}var lu="-";function xv(e){var t=jv(e),n=e.conflictingClassGroups,r=e.conflictingClassGroupModifiers,s=r===void 0?{}:r;function i(l){var u=l.split(lu);return u[0]===""&&u.length!==1&&u.shift(),Lp(u,t)||wv(l)}function o(l,u){var c=n[l]||[];return u&&s[l]?[].concat(c,s[l]):c}return{getClassGroupId:i,getConflictingClassGroupIds:o}}function Lp(e,t){var o;if(e.length===0)return t.classGroupId;var n=e[0],r=t.nextPart.get(n),s=r?Lp(e.slice(1),r):void 0;if(s)return s;if(t.validators.length!==0){var i=e.join(lu);return(o=t.validators.find(function(l){var u=l.validator;return u(i)}))==null?void 0:o.classGroupId}}var qc=/^\[(.+)\]$/;function wv(e){if(qc.test(e)){var t=qc.exec(e)[1],n=t==null?void 0:t.substring(0,t.indexOf(":"));if(n)return"arbitrary.."+n}}function jv(e){var t=e.theme,n=e.prefix,r={nextPart:new Map,validators:[]},s=Nv(Object.entries(e.classGroups),n);return s.forEach(function(i){var o=i[0],l=i[1];il(l,r,o,t)}),r}function il(e,t,n,r){e.forEach(function(s){if(typeof s=="string"){var i=s===""?t:Qc(t,s);i.classGroupId=n;return}if(typeof s=="function"){if(bv(s)){il(s(r),t,n,r);return}t.validators.push({validator:s,classGroupId:n});return}Object.entries(s).forEach(function(o){var l=o[0],u=o[1];il(u,Qc(t,l),n,r)})})}function Qc(e,t){var n=e;return t.split(lu).forEach(function(r){n.nextPart.has(r)||n.nextPart.set(r,{nextPart:new Map,validators:[]}),n=n.nextPart.get(r)}),n}function bv(e){return e.isThemeGetter}function Nv(e,t){return t?e.map(function(n){var r=n[0],s=n[1],i=s.map(function(o){return typeof o=="string"?t+o:typeof o=="object"?Object.fromEntries(Object.entries(o).map(function(l){var u=l[0],c=l[1];return[t+u,c]})):o});return[r,i]}):e}function kv(e){if(e<1)return{get:function(){},set:function(){}};var t=0,n=new Map,r=new Map;function s(i,o){n.set(i,o),t++,t>e&&(t=0,r=n,n=new Map)}return{get:function(o){var l=n.get(o);if(l!==void 0)return l;if((l=r.get(o))!==void 0)return s(o,l),l},set:function(o,l){n.has(o)?n.set(o,l):s(o,l)}}}var Fp="!";function Sv(e){var t=e.separator||":",n=t.length===1,r=t[0],s=t.length;return function(o){for(var l=[],u=0,c=0,d,p=0;p<o.length;p++){var h=o[p];if(u===0){if(h===r&&(n||o.slice(p,p+s)===t)){l.push(o.slice(c,p)),c=p+s;continue}if(h==="/"){d=p;continue}}h==="["?u++:h==="]"&&u--}var v=l.length===0?o:o.substring(c),x=v.startsWith(Fp),w=x?v.substring(1):v,k=d&&d>c?d-c:void 0;return{modifiers:l,hasImportantModifier:x,baseClassName:w,maybePostfixModifierPosition:k}}}function Cv(e){if(e.length<=1)return e;var t=[],n=[];return e.forEach(function(r){var s=r[0]==="[";s?(t.push.apply(t,n.sort().concat([r])),n=[]):n.push(r)}),t.push.apply(t,n.sort()),t}function Ev(e){return{cache:kv(e.cacheSize),splitModifiers:Sv(e),...xv(e)}}var Pv=/\s+/;function Tv(e,t){var n=t.splitModifiers,r=t.getClassGroupId,s=t.getConflictingClassGroupIds,i=new Set;return e.trim().split(Pv).map(function(o){var l=n(o),u=l.modifiers,c=l.hasImportantModifier,d=l.baseClassName,p=l.maybePostfixModifierPosition,h=r(p?d.substring(0,p):d),v=!!p;if(!h){if(!p)return{isTailwindClass:!1,originalClassName:o};if(h=r(d),!h)return{isTailwindClass:!1,originalClassName:o};v=!1}var x=Cv(u).join(":"),w=c?x+Fp:x;return{isTailwindClass:!0,modifierId:w,classGroupId:h,originalClassName:o,hasPostfixModifier:v}}).reverse().filter(function(o){if(!o.isTailwindClass)return!0;var l=o.modifierId,u=o.classGroupId,c=o.hasPostfixModifier,d=l+u;return i.has(d)?!1:(i.add(d),s(u,c).forEach(function(p){return i.add(l+p)}),!0)}).reverse().map(function(o){return o.originalClassName}).join(" ")}function Ov(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];var r,s,i,o=l;function l(c){var d=t[0],p=t.slice(1),h=p.reduce(function(v,x){return x(v)},d());return r=Ev(h),s=r.cache.get,i=r.cache.set,o=u,u(c)}function u(c){var d=s(c);if(d)return d;var p=Tv(c,r);return i(c,p),p}return function(){return o(vv.apply(null,arguments))}}function he(e){var t=function(r){return r[e]||[]};return t.isThemeGetter=!0,t}var Dp=/^\[(?:([a-z-]+):)?(.+)\]$/i,zv=/^\d+\/\d+$/,Av=new Set(["px","full","screen"]),Mv=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,Rv=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,Iv=/^-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/;function gt(e){return Tn(e)||Av.has(e)||zv.test(e)||al(e)}function al(e){return Un(e,"length",Uv)}function _v(e){return Un(e,"size",$p)}function Lv(e){return Un(e,"position",$p)}function Fv(e){return Un(e,"url",Wv)}function Xs(e){return Un(e,"number",Tn)}function Tn(e){return!Number.isNaN(Number(e))}function Dv(e){return e.endsWith("%")&&Tn(e.slice(0,-1))}function $r(e){return Vc(e)||Un(e,"number",Vc)}function ne(e){return Dp.test(e)}function Ur(){return!0}function Qt(e){return Mv.test(e)}function $v(e){return Un(e,"",Bv)}function Un(e,t,n){var r=Dp.exec(e);return r?r[1]?r[1]===t:n(r[2]):!1}function Uv(e){return Rv.test(e)}function $p(){return!1}function Wv(e){return e.startsWith("url(")}function Vc(e){return Number.isInteger(Number(e))}function Bv(e){return Iv.test(e)}function Hv(){var e=he("colors"),t=he("spacing"),n=he("blur"),r=he("brightness"),s=he("borderColor"),i=he("borderRadius"),o=he("borderSpacing"),l=he("borderWidth"),u=he("contrast"),c=he("grayscale"),d=he("hueRotate"),p=he("invert"),h=he("gap"),v=he("gradientColorStops"),x=he("gradientColorStopPositions"),w=he("inset"),k=he("margin"),m=he("opacity"),f=he("padding"),g=he("saturate"),b=he("scale"),E=he("sepia"),T=he("skew"),C=he("space"),j=he("translate"),R=function(){return["auto","contain","none"]},M=function(){return["auto","hidden","clip","visible","scroll"]},K=function(){return["auto",ne,t]},G=function(){return[ne,t]},Ce=function(){return["",gt]},P=function(){return["auto",Tn,ne]},q=function(){return["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"]},Y=function(){return["solid","dashed","dotted","double","none"]},ae=function(){return["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity","plus-lighter"]},A=function(){return["start","end","center","between","around","evenly","stretch"]},F=function(){return["","0",ne]},U=function(){return["auto","avoid","all","avoid-page","page","left","right","column"]},ee=function(){return[Tn,Xs]},Q=function(){return[Tn,ne]};return{cacheSize:500,theme:{colors:[Ur],spacing:[gt],blur:["none","",Qt,ne],brightness:ee(),borderColor:[e],borderRadius:["none","","full",Qt,ne],borderSpacing:G(),borderWidth:Ce(),contrast:ee(),grayscale:F(),hueRotate:Q(),invert:F(),gap:G(),gradientColorStops:[e],gradientColorStopPositions:[Dv,al],inset:K(),margin:K(),opacity:ee(),padding:G(),saturate:ee(),scale:ee(),sepia:F(),skew:Q(),space:G(),translate:G()},classGroups:{aspect:[{aspect:["auto","square","video",ne]}],container:["container"],columns:[{columns:[Qt]}],"break-after":[{"break-after":U()}],"break-before":[{"break-before":U()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],float:[{float:["right","left","none"]}],clear:[{clear:["left","right","both","none"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:[].concat(q(),[ne])}],overflow:[{overflow:M()}],"overflow-x":[{"overflow-x":M()}],"overflow-y":[{"overflow-y":M()}],overscroll:[{overscroll:R()}],"overscroll-x":[{"overscroll-x":R()}],"overscroll-y":[{"overscroll-y":R()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[w]}],"inset-x":[{"inset-x":[w]}],"inset-y":[{"inset-y":[w]}],start:[{start:[w]}],end:[{end:[w]}],top:[{top:[w]}],right:[{right:[w]}],bottom:[{bottom:[w]}],left:[{left:[w]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",$r]}],basis:[{basis:K()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",ne]}],grow:[{grow:F()}],shrink:[{shrink:F()}],order:[{order:["first","last","none",$r]}],"grid-cols":[{"grid-cols":[Ur]}],"col-start-end":[{col:["auto",{span:["full",$r]},ne]}],"col-start":[{"col-start":P()}],"col-end":[{"col-end":P()}],"grid-rows":[{"grid-rows":[Ur]}],"row-start-end":[{row:["auto",{span:[$r]},ne]}],"row-start":[{"row-start":P()}],"row-end":[{"row-end":P()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",ne]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",ne]}],gap:[{gap:[h]}],"gap-x":[{"gap-x":[h]}],"gap-y":[{"gap-y":[h]}],"justify-content":[{justify:["normal"].concat(A())}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal"].concat(A(),["baseline"])}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":[].concat(A(),["baseline"])}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[f]}],px:[{px:[f]}],py:[{py:[f]}],ps:[{ps:[f]}],pe:[{pe:[f]}],pt:[{pt:[f]}],pr:[{pr:[f]}],pb:[{pb:[f]}],pl:[{pl:[f]}],m:[{m:[k]}],mx:[{mx:[k]}],my:[{my:[k]}],ms:[{ms:[k]}],me:[{me:[k]}],mt:[{mt:[k]}],mr:[{mr:[k]}],mb:[{mb:[k]}],ml:[{ml:[k]}],"space-x":[{"space-x":[C]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[C]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit",ne,t]}],"min-w":[{"min-w":["min","max","fit",ne,gt]}],"max-w":[{"max-w":["0","none","full","min","max","fit","prose",{screen:[Qt]},Qt,ne]}],h:[{h:[ne,t,"auto","min","max","fit"]}],"min-h":[{"min-h":["min","max","fit",ne,gt]}],"max-h":[{"max-h":[ne,t,"min","max","fit"]}],"font-size":[{text:["base",Qt,al]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",Xs]}],"font-family":[{font:[Ur]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractons"],tracking:[{tracking:["tighter","tight","normal","wide","wider","widest",ne]}],"line-clamp":[{"line-clamp":["none",Tn,Xs]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",ne,gt]}],"list-image":[{"list-image":["none",ne]}],"list-style-type":[{list:["none","disc","decimal",ne]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[e]}],"placeholder-opacity":[{"placeholder-opacity":[m]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[e]}],"text-opacity":[{"text-opacity":[m]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[].concat(Y(),["wavy"])}],"text-decoration-thickness":[{decoration:["auto","from-font",gt]}],"underline-offset":[{"underline-offset":["auto",ne,gt]}],"text-decoration-color":[{decoration:[e]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],indent:[{indent:G()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",ne]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",ne]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[m]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[].concat(q(),[Lv])}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",_v]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},Fv]}],"bg-color":[{bg:[e]}],"gradient-from-pos":[{from:[x]}],"gradient-via-pos":[{via:[x]}],"gradient-to-pos":[{to:[x]}],"gradient-from":[{from:[v]}],"gradient-via":[{via:[v]}],"gradient-to":[{to:[v]}],rounded:[{rounded:[i]}],"rounded-s":[{"rounded-s":[i]}],"rounded-e":[{"rounded-e":[i]}],"rounded-t":[{"rounded-t":[i]}],"rounded-r":[{"rounded-r":[i]}],"rounded-b":[{"rounded-b":[i]}],"rounded-l":[{"rounded-l":[i]}],"rounded-ss":[{"rounded-ss":[i]}],"rounded-se":[{"rounded-se":[i]}],"rounded-ee":[{"rounded-ee":[i]}],"rounded-es":[{"rounded-es":[i]}],"rounded-tl":[{"rounded-tl":[i]}],"rounded-tr":[{"rounded-tr":[i]}],"rounded-br":[{"rounded-br":[i]}],"rounded-bl":[{"rounded-bl":[i]}],"border-w":[{border:[l]}],"border-w-x":[{"border-x":[l]}],"border-w-y":[{"border-y":[l]}],"border-w-s":[{"border-s":[l]}],"border-w-e":[{"border-e":[l]}],"border-w-t":[{"border-t":[l]}],"border-w-r":[{"border-r":[l]}],"border-w-b":[{"border-b":[l]}],"border-w-l":[{"border-l":[l]}],"border-opacity":[{"border-opacity":[m]}],"border-style":[{border:[].concat(Y(),["hidden"])}],"divide-x":[{"divide-x":[l]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[l]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[m]}],"divide-style":[{divide:Y()}],"border-color":[{border:[s]}],"border-color-x":[{"border-x":[s]}],"border-color-y":[{"border-y":[s]}],"border-color-t":[{"border-t":[s]}],"border-color-r":[{"border-r":[s]}],"border-color-b":[{"border-b":[s]}],"border-color-l":[{"border-l":[s]}],"divide-color":[{divide:[s]}],"outline-style":[{outline:[""].concat(Y())}],"outline-offset":[{"outline-offset":[ne,gt]}],"outline-w":[{outline:[gt]}],"outline-color":[{outline:[e]}],"ring-w":[{ring:Ce()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[e]}],"ring-opacity":[{"ring-opacity":[m]}],"ring-offset-w":[{"ring-offset":[gt]}],"ring-offset-color":[{"ring-offset":[e]}],shadow:[{shadow:["","inner","none",Qt,$v]}],"shadow-color":[{shadow:[Ur]}],opacity:[{opacity:[m]}],"mix-blend":[{"mix-blend":ae()}],"bg-blend":[{"bg-blend":ae()}],filter:[{filter:["","none"]}],blur:[{blur:[n]}],brightness:[{brightness:[r]}],contrast:[{contrast:[u]}],"drop-shadow":[{"drop-shadow":["","none",Qt,ne]}],grayscale:[{grayscale:[c]}],"hue-rotate":[{"hue-rotate":[d]}],invert:[{invert:[p]}],saturate:[{saturate:[g]}],sepia:[{sepia:[E]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[n]}],"backdrop-brightness":[{"backdrop-brightness":[r]}],"backdrop-contrast":[{"backdrop-contrast":[u]}],"backdrop-grayscale":[{"backdrop-grayscale":[c]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[d]}],"backdrop-invert":[{"backdrop-invert":[p]}],"backdrop-opacity":[{"backdrop-opacity":[m]}],"backdrop-saturate":[{"backdrop-saturate":[g]}],"backdrop-sepia":[{"backdrop-sepia":[E]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[o]}],"border-spacing-x":[{"border-spacing-x":[o]}],"border-spacing-y":[{"border-spacing-y":[o]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",ne]}],duration:[{duration:Q()}],ease:[{ease:["linear","in","out","in-out",ne]}],delay:[{delay:Q()}],animate:[{animate:["none","spin","ping","pulse","bounce",ne]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[b]}],"scale-x":[{"scale-x":[b]}],"scale-y":[{"scale-y":[b]}],rotate:[{rotate:[$r,ne]}],"translate-x":[{"translate-x":[j]}],"translate-y":[{"translate-y":[j]}],"skew-x":[{"skew-x":[T]}],"skew-y":[{"skew-y":[T]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",ne]}],accent:[{accent:["auto",e]}],appearance:["appearance-none"],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",ne]}],"caret-color":[{caret:[e]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":G()}],"scroll-mx":[{"scroll-mx":G()}],"scroll-my":[{"scroll-my":G()}],"scroll-ms":[{"scroll-ms":G()}],"scroll-me":[{"scroll-me":G()}],"scroll-mt":[{"scroll-mt":G()}],"scroll-mr":[{"scroll-mr":G()}],"scroll-mb":[{"scroll-mb":G()}],"scroll-ml":[{"scroll-ml":G()}],"scroll-p":[{"scroll-p":G()}],"scroll-px":[{"scroll-px":G()}],"scroll-py":[{"scroll-py":G()}],"scroll-ps":[{"scroll-ps":G()}],"scroll-pe":[{"scroll-pe":G()}],"scroll-pt":[{"scroll-pt":G()}],"scroll-pr":[{"scroll-pr":G()}],"scroll-pb":[{"scroll-pb":G()}],"scroll-pl":[{"scroll-pl":G()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","pinch-zoom","manipulation",{pan:["x","left","right","y","up","down"]}]}],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",ne]}],fill:[{fill:[e,"none"]}],"stroke-w":[{stroke:[gt,Xs]}],stroke:[{stroke:[e,"none"]}],sr:["sr-only","not-sr-only"]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"]},conflictingClassGroupModifiers:{"font-size":["leading"]}}}var qv=Ov(Hv);function Qv(...e){return qv(yv(e))}const Vv=[{name:"Dashboard",href:"/",icon:Mp},{name:"Organizations",href:"/organizations",icon:Vr},{name:"Service Mappings",href:"/service-mappings",icon:rs}];function Kv({children:e}){const t=Os(),[n,r]=N.useState(null);return N.useEffect(()=>{fetch("/api/health").then(s=>s.json()).then(s=>r({version:s.version,environment:s.environment})).catch(()=>r(null))},[]),a.jsxs("div",{className:"min-h-screen bg-background",style:{minHeight:"100vh",backgroundColor:"#ffffff"},children:[a.jsx("header",{className:"border-b border-border bg-card",style:{backgroundColor:"#f8f9fa",borderBottom:"1px solid #e0e0e0"},children:a.jsx("div",{className:"flex h-16 items-center px-6",children:a.jsxs("div",{className:"flex items-center space-x-4",children:[a.jsx(ov,{className:"h-6 w-6 md:hidden"}),a.jsx("h1",{className:"text-xl font-semibold text-foreground",style:{color:"#000000",fontSize:"1.25rem",fontWeight:"600"},children:"AI Agent Service"})]})})}),a.jsxs("div",{className:"flex",children:[a.jsx("aside",{className:"hidden w-64 border-r border-border bg-card md:block",children:a.jsx("nav",{className:"space-y-1 p-4",children:Vv.map(s=>{const i=t.pathname===s.href||s.href!=="/"&&t.pathname.startsWith(s.href);return a.jsxs(xp,{to:s.href,className:Qv("flex items-center space-x-3 rounded-lg px-3 py-2 text-sm font-medium transition-colors",i?"bg-primary text-primary-foreground":"text-muted-foreground hover:bg-accent hover:text-accent-foreground"),children:[a.jsx(s.icon,{className:"h-5 w-5"}),a.jsx("span",{children:s.name})]},s.name)})})}),a.jsx("main",{className:"flex-1 p-6",children:a.jsx("div",{className:"mx-auto max-w-7xl",children:e})})]}),a.jsx("footer",{className:"border-t border-border bg-card px-6 py-3",style:{backgroundColor:"#f8f9fa",borderTop:"1px solid #e0e0e0"},children:a.jsxs("div",{className:"flex justify-between items-center text-xs text-gray-500",children:[a.jsx("span",{children:"AI Agent Service"}),n&&a.jsxs("span",{children:["v",n.version]})]})})]})}const Gv={}.VITE_API_URL||"/api";function Yv(e){const t=e.startsWith("/")?e.slice(1):e;return`${Gv}/${t}`}async function Zs(e,t){const n=Yv(e);try{const r=await fetch(n,{...t,headers:{"Content-Type":"application/json",...t==null?void 0:t.headers}});if(!r.ok)throw new Error(`API request failed: ${r.status} ${r.statusText}`);return r}catch(r){throw console.error(`API request error for ${e}:`,r),r}}const ei={health:"health",ready:"ready",analysis:"analysis",analysisStatus:e=>`analysis/${e}`,queueQueued:"queue/queued",queueInProgress:"queue/in-progress",queueCompleted:"queue/completed",queueFailed:"queue/failed",workItemsHealth:"work-items/health",workItemsErrors:"work-items/errors",workItemsLogs:"work-items/logs",errorsRecent:"errors/recent",workspaceDiscover:"workspace/discover",workspaceList:"workspace/list",workspaceStats:e=>e?`workspace/stats/${e}`:"workspace/stats",websocketStatus:"websocket/status",websocketActivity:"websocket/activity",websocketWorker:"websocket/worker",websocketReconnect:"websocket/reconnect",usageStats:"usage/stats",usageHistory:"usage/history",usageRateLimit:"usage/rate-limit",analyticsProjects:"analytics/projects",analyticsStats:"analytics/stats",analyticsOperations:"analytics/operations"};function Jv(){var M,K,G,Ce;const[e,t]=N.useState([]),[n,r]=N.useState({queued:0,in_progress:0,completed:0,failed:0}),[s,i]=N.useState(!0),[o,l]=N.useState(null),[u,c]=N.useState("all"),[d,p]=N.useState("all"),[h,v]=N.useState(null);N.useEffect(()=>{const P=async()=>{var Y,ae,A,F,U,ee,Q,X;try{i(!0),l(null);const[ue,Ae,ve,Ge]=await Promise.allSettled([Zs(ei.queueQueued),Zs(ei.queueInProgress),Zs(ei.queueCompleted+"?limit=20"),Zs(ei.queueFailed+"?limit=20")]),kt=[],Be={queued:0,in_progress:0,completed:0,failed:0};if(ue.status==="fulfilled"&&ue.value.ok){const be=await ue.value.json();kt.push(...((Y=be.data)==null?void 0:Y.items)||[]),Be.queued=((ae=be.data)==null?void 0:ae.total)||0}if(Ae.status==="fulfilled"&&Ae.value.ok){const be=await Ae.value.json();kt.push(...((A=be.data)==null?void 0:A.items)||[]),Be.in_progress=((F=be.data)==null?void 0:F.total)||0}if(ve.status==="fulfilled"&&ve.value.ok){const be=await ve.value.json();kt.push(...((U=be.data)==null?void 0:U.items)||[]),Be.completed=((ee=be.data)==null?void 0:ee.total)||0}if(Ge.status==="fulfilled"&&Ge.value.ok){const be=await Ge.value.json();kt.push(...((Q=be.data)==null?void 0:Q.items)||[]),Be.failed=((X=be.data)==null?void 0:X.total)||0}t(kt),r(Be)}catch(ue){l(ue instanceof Error?ue.message:"Failed to fetch work queue data")}finally{i(!1)}};P();const q=setInterval(P,1e4);return()=>clearInterval(q)},[]);const x=N.useMemo(()=>{let P=[...e];return u!=="all"&&(P=P.filter(q=>q.status===u)),d!=="all"&&(P=P.filter(q=>q.type===d)),P.sort((q,Y)=>{const ae={in_progress:0,queued:1,failed:2,completed:3},A=ae[q.status]-ae[Y.status];if(A!==0)return A;const F=Y.priority-q.priority;return F!==0?F:new Date(Y.createdAt).getTime()-new Date(q.createdAt).getTime()}),P},[e,u,d]),w=P=>{const q=Math.floor(P/60),Y=Math.floor(q/60);return Y>0?`${Y}h ${q%60}m`:q>0?`${q}m`:`${P}s`},k=P=>{const q=new Date,Y=new Date(P),ae=q.getTime()-Y.getTime(),A=Math.floor(ae/(1e3*60));if(A<1)return"Just now";if(A<60)return`${A}m ago`;const F=Math.floor(A/60);return F<24?`${F}h ago`:`${Math.floor(F/24)}d ago`},m=P=>{switch(P){case"project_review":return"📋";case"code_review":return"🔍";case"story_implementation":return"⚡";case"development_planning":return"📊";default:return"📄"}},f=P=>P>=9?"text-red-600 bg-red-50":P>=7?"text-orange-600 bg-orange-50":P>=5?"text-yellow-600 bg-yellow-50":"text-green-600 bg-green-50",g=P=>P>=9?"Critical":P>=7?"High":P>=5?"Medium":"Low",b=P=>{switch(P){case"completed":return a.jsx(jr,{className:"w-4 h-4 text-green-600"});case"failed":return a.jsx(Jt,{className:"w-4 h-4 text-red-600"});case"in_progress":return a.jsx(ir,{className:"w-4 h-4 text-blue-600 animate-spin"});case"queued":return a.jsx(Mt,{className:"w-4 h-4 text-yellow-600"});default:return a.jsx(Mt,{className:"w-4 h-4 text-gray-400"})}},E=P=>{switch(P){case"completed":return"text-green-600 bg-green-50 border-green-200";case"failed":return"text-red-600 bg-red-50 border-red-200";case"in_progress":return"text-blue-600 bg-blue-50 border-blue-200";case"queued":return"text-yellow-600 bg-yellow-50 border-yellow-200";default:return"text-gray-600 bg-gray-50 border-gray-200"}},T=P=>{switch(P){case"in_progress":return"In Progress";case"queued":return"Queued";case"completed":return"Completed";case"failed":return"Failed";default:return P}},C=P=>{var q;return a.jsxs("div",{className:"border rounded-lg p-4 hover:bg-gray-50 transition-colors",children:[a.jsxs("div",{className:"flex items-start justify-between mb-2",children:[a.jsxs("div",{className:"flex items-center gap-2",children:[a.jsx("span",{className:"text-lg",children:m(P.type)}),a.jsxs("div",{children:[a.jsx("h4",{className:"font-medium text-sm",children:P.title}),a.jsx("p",{className:"text-xs text-gray-600",children:P.projectName})]})]}),a.jsxs("div",{className:"flex items-center gap-2",children:[a.jsxs("span",{className:`px-2 py-1 rounded border text-xs font-medium flex items-center gap-1 ${E(P.status)}`,children:[b(P.status),T(P.status)]}),a.jsx("span",{className:`px-2 py-1 rounded-full text-xs font-medium ${f(P.priority)}`,children:g(P.priority)}),P.estimatedDuration&&a.jsxs("span",{className:"text-xs text-gray-500 flex items-center gap-1",children:[a.jsx(Mt,{className:"w-3 h-3"}),w(Math.round(P.estimatedDuration/1e3))]}),P.actualDuration&&P.status==="completed"&&a.jsxs("span",{className:"text-xs text-gray-500 flex items-center gap-1",children:[a.jsx(Mt,{className:"w-3 h-3"}),w(Math.round(P.actualDuration/1e3))," actual"]})]})]}),P.description&&a.jsx("p",{className:"text-xs text-gray-600 mb-2 line-clamp-2",children:P.description}),P.progress&&P.status==="in_progress"&&a.jsxs("div",{className:"mb-2",children:[a.jsxs("div",{className:"flex justify-between text-xs text-gray-600 mb-1",children:[a.jsx("span",{children:P.progress.currentStep}),a.jsxs("span",{children:[P.progress.percentage,"%"]})]}),a.jsx("div",{className:"w-full bg-gray-200 rounded-full h-2",children:a.jsx("div",{className:"bg-blue-600 h-2 rounded-full transition-all duration-300",style:{width:`${P.progress.percentage}%`}})})]}),P.status==="failed"&&a.jsxs("div",{className:"mb-2 p-2 bg-red-50 rounded border border-red-200 flex items-center justify-between",children:[a.jsxs("div",{className:"flex items-center gap-2",children:[a.jsx(Jt,{className:"w-4 h-4 text-red-600"}),a.jsx("span",{className:"text-xs text-red-800 font-medium",children:"Work item failed"}),((q=P.metadata)==null?void 0:q.failedAt)&&a.jsxs("span",{className:"text-xs text-red-600",children:["• Failed: ",k(P.metadata.failedAt)]})]}),a.jsx("button",{onClick:Y=>{Y.stopPropagation(),v(P)},className:"px-2 py-1 text-xs bg-red-100 text-red-700 hover:bg-red-200 rounded transition-colors",children:"View Details"})]}),a.jsxs("div",{className:"flex justify-between items-center text-xs text-gray-500",children:[a.jsxs("span",{children:["Created ",k(P.createdAt)]}),P.assignedTo&&a.jsx("span",{className:"bg-blue-100 text-blue-800 px-2 py-1 rounded",children:P.assignedTo}),P.completedAt&&P.status==="completed"&&a.jsxs("span",{className:"text-green-600",children:["Completed ",k(P.completedAt)]})]})]},P.id)},j=n.queued+n.in_progress+n.completed+n.failed,R=u!=="all"||d!=="all";return s?a.jsx("div",{className:"rounded-lg border bg-card p-6",children:a.jsxs("div",{className:"flex items-center justify-center py-8",children:[a.jsx(ir,{className:"h-8 w-8 animate-spin text-blue-600"}),a.jsx("span",{className:"ml-2 text-sm text-gray-600",children:"Loading work queue..."})]})}):o?a.jsx("div",{className:"rounded-lg border bg-card p-6",children:a.jsxs("div",{className:"flex items-center justify-center py-8 text-red-600",children:[a.jsx(Jt,{className:"h-6 w-6 mr-2"}),a.jsx("span",{className:"text-sm",children:o})]})}):a.jsxs("div",{className:"rounded-lg border bg-card",children:[a.jsxs("div",{className:"p-6 border-b",children:[a.jsxs("div",{className:"flex items-center justify-between mb-4",children:[a.jsx("h3",{className:"text-lg font-medium",children:"Work Queue Status"}),a.jsxs("span",{className:"text-sm text-gray-500",children:[j," total items"]})]}),a.jsxs("div",{className:"space-y-3",children:[a.jsxs("div",{className:"flex items-center gap-2 flex-wrap",children:[a.jsx(iv,{className:"w-4 h-4 text-gray-400"}),a.jsx("span",{className:"text-sm text-gray-600 mr-2",children:"Status:"}),a.jsxs("button",{onClick:()=>c("all"),className:`px-3 py-1.5 rounded-full text-xs font-medium transition-colors ${u==="all"?"bg-gray-900 text-white":"bg-gray-100 text-gray-600 hover:bg-gray-200"}`,children:["All (",j,")"]}),a.jsxs("button",{onClick:()=>c("in_progress"),className:`px-3 py-1.5 rounded-full text-xs font-medium transition-colors flex items-center gap-1 ${u==="in_progress"?"bg-blue-600 text-white":"bg-blue-50 text-blue-600 hover:bg-blue-100"}`,children:[a.jsx(uv,{className:"w-3 h-3"}),"In Progress (",n.in_progress,")"]}),a.jsxs("button",{onClick:()=>c("queued"),className:`px-3 py-1.5 rounded-full text-xs font-medium transition-colors flex items-center gap-1 ${u==="queued"?"bg-yellow-600 text-white":"bg-yellow-50 text-yellow-600 hover:bg-yellow-100"}`,children:[a.jsx(lv,{className:"w-3 h-3"}),"Queued (",n.queued,")"]}),a.jsxs("button",{onClick:()=>c("completed"),className:`px-3 py-1.5 rounded-full text-xs font-medium transition-colors flex items-center gap-1 ${u==="completed"?"bg-green-600 text-white":"bg-green-50 text-green-600 hover:bg-green-100"}`,children:[a.jsx(jr,{className:"w-3 h-3"}),"Completed (",n.completed,")"]}),a.jsxs("button",{onClick:()=>c("failed"),className:`px-3 py-1.5 rounded-full text-xs font-medium transition-colors flex items-center gap-1 ${u==="failed"?"bg-red-600 text-white":"bg-red-50 text-red-600 hover:bg-red-100"}`,children:[a.jsx(Jt,{className:"w-3 h-3"}),"Failed (",n.failed,")"]})]}),a.jsxs("div",{className:"flex items-center gap-2 flex-wrap",children:[a.jsx("span",{className:"text-sm text-gray-600 ml-6 mr-2",children:"Type:"}),a.jsx("button",{onClick:()=>p("all"),className:`px-3 py-1.5 rounded-full text-xs font-medium transition-colors ${d==="all"?"bg-gray-900 text-white":"bg-gray-100 text-gray-600 hover:bg-gray-200"}`,children:"All Types"}),a.jsx("button",{onClick:()=>p("story_implementation"),className:`px-3 py-1.5 rounded-full text-xs font-medium transition-colors ${d==="story_implementation"?"bg-purple-600 text-white":"bg-purple-50 text-purple-600 hover:bg-purple-100"}`,children:"⚡ Story"}),a.jsx("button",{onClick:()=>p("project_review"),className:`px-3 py-1.5 rounded-full text-xs font-medium transition-colors ${d==="project_review"?"bg-indigo-600 text-white":"bg-indigo-50 text-indigo-600 hover:bg-indigo-100"}`,children:"📋 Review"}),a.jsx("button",{onClick:()=>p("development_planning"),className:`px-3 py-1.5 rounded-full text-xs font-medium transition-colors ${d==="development_planning"?"bg-cyan-600 text-white":"bg-cyan-50 text-cyan-600 hover:bg-cyan-100"}`,children:"📊 Planning"}),a.jsx("button",{onClick:()=>p("code_review"),className:`px-3 py-1.5 rounded-full text-xs font-medium transition-colors ${d==="code_review"?"bg-teal-600 text-white":"bg-teal-50 text-teal-600 hover:bg-teal-100"}`,children:"🔍 Code Review"})]}),R&&a.jsxs("button",{onClick:()=>{c("all"),p("all")},className:"flex items-center gap-1 text-xs text-gray-500 hover:text-gray-700 transition-colors ml-6",children:[a.jsx(Pn,{className:"w-3 h-3"}),"Clear filters"]})]})]}),a.jsxs("div",{className:"p-6",children:[a.jsx("div",{className:"space-y-3",children:x.length===0?a.jsxs("div",{className:"text-center py-8 text-gray-500",children:[a.jsx(Mt,{className:"w-12 h-12 mx-auto mb-2 opacity-50"}),a.jsx("p",{children:R?"No items match the selected filters":"No items in queue"})]}):x.map(P=>C(P))}),x.length>0&&a.jsxs("div",{className:"mt-4 text-center text-sm text-gray-500",children:["Showing ",x.length," of ",j," items"]})]}),h&&a.jsx("div",{className:"fixed inset-0 bg-black bg-opacity-50 flex items-center justify-center z-50",children:a.jsxs("div",{className:"bg-white rounded-lg p-6 max-w-2xl w-full mx-4 max-h-[80vh] overflow-y-auto",children:[a.jsxs("div",{className:"flex items-center justify-between mb-4",children:[a.jsxs("div",{className:"flex items-center gap-2",children:[a.jsx(Jt,{className:"w-5 h-5 text-red-600"}),a.jsx("h2",{className:"text-lg font-semibold text-gray-900",children:"Error Details"})]}),a.jsx("button",{onClick:()=>v(null),className:"text-gray-400 hover:text-gray-600 transition-colors",children:a.jsx("svg",{className:"w-6 h-6",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:a.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M6 18L18 6M6 6l12 12"})})})]}),a.jsxs("div",{className:"space-y-4",children:[a.jsxs("div",{className:"border rounded-lg p-4 bg-gray-50",children:[a.jsx("h3",{className:"font-medium text-gray-900 mb-2",children:"Work Item Information"}),a.jsxs("div",{className:"grid grid-cols-2 gap-4 text-sm",children:[a.jsxs("div",{children:[a.jsx("span",{className:"font-medium text-gray-600",children:"Type:"}),a.jsx("span",{className:"ml-2",children:h.type})]}),a.jsxs("div",{children:[a.jsx("span",{className:"font-medium text-gray-600",children:"Status:"}),a.jsx("span",{className:"ml-2 text-red-600",children:"Failed"})]}),a.jsxs("div",{children:[a.jsx("span",{className:"font-medium text-gray-600",children:"Project:"}),a.jsx("span",{className:"ml-2",children:h.projectName})]}),a.jsxs("div",{children:[a.jsx("span",{className:"font-medium text-gray-600",children:"Created:"}),a.jsxs("span",{className:"ml-2",children:[k(h.createdAt)," ago"]})]}),h.completedAt&&a.jsxs("div",{children:[a.jsx("span",{className:"font-medium text-gray-600",children:"Failed:"}),a.jsxs("span",{className:"ml-2",children:[k(h.completedAt)," ago"]})]}),h.assignedTo&&a.jsxs("div",{children:[a.jsx("span",{className:"font-medium text-gray-600",children:"Assigned to:"}),a.jsx("span",{className:"ml-2",children:h.assignedTo})]})]})]}),a.jsxs("div",{className:"border rounded-lg p-4 bg-red-50 border-red-200",children:[a.jsxs("h3",{className:"font-medium text-red-900 mb-2 flex items-center gap-2",children:[a.jsx(Jt,{className:"w-4 h-4"}),"Error Message"]}),a.jsx("p",{className:"text-red-800 text-sm",children:((M=h.metadata)==null?void 0:M.reason)||((K=h.metadata)==null?void 0:K.failureReason)||((G=h.metadata)==null?void 0:G.error)||"No specific error message available"})]}),((Ce=h.metadata)==null?void 0:Ce.errorHistory)&&h.metadata.errorHistory.length>0&&a.jsxs("div",{className:"border rounded-lg p-4",children:[a.jsx("h3",{className:"font-medium text-gray-900 mb-2",children:"Attempt History"}),a.jsxs("div",{className:"text-sm text-gray-600",children:[a.jsxs("p",{className:"mb-2",children:["This work item failed after ",h.metadata.errorHistory.length," attempt",h.metadata.errorHistory.length>1?"s":"",":"]}),a.jsx("div",{className:"space-y-2",children:h.metadata.errorHistory.map((P,q)=>a.jsxs("div",{className:"flex items-center justify-between p-2 bg-gray-50 rounded",children:[a.jsxs("span",{children:["Attempt #",P.attemptNumber||q+1]}),a.jsx("span",{className:"text-xs text-gray-500",children:P.timestamp&&k(P.timestamp)})]},q))})]})]}),h.metadata&&Object.keys(h.metadata).length>0&&a.jsxs("div",{className:"border rounded-lg p-4",children:[a.jsx("h3",{className:"font-medium text-gray-900 mb-2",children:"Additional Information"}),a.jsxs("details",{className:"text-sm",children:[a.jsx("summary",{className:"cursor-pointer text-gray-600 hover:text-gray-800",children:"View raw metadata"}),a.jsx("pre",{className:"mt-2 text-xs bg-gray-50 p-2 rounded overflow-x-auto",children:JSON.stringify(h.metadata,null,2)})]})]})]}),a.jsx("div",{className:"flex justify-end mt-6",children:a.jsx("button",{onClick:()=>v(null),className:"px-4 py-2 bg-gray-100 text-gray-700 rounded hover:bg-gray-200 transition-colors",children:"Close"})})]})})]})}function Xv(){const[e,t]=N.useState(null),[n,r]=N.useState(!0),[s,i]=N.useState(!1);N.useEffect(()=>{const d=async()=>{try{const h=await fetch("/api/smart-polling/metrics");if(h.ok){const v=await h.json();t(v.data)}}catch(h){console.error("Failed to fetch smart polling metrics:",h)}finally{r(!1)}};d();const p=setInterval(d,1e4);return()=>clearInterval(p)},[]);const o=async()=>{i(!0);try{if((await fetch("/api/smart-polling/force",{method:"POST"})).ok){const p=await fetch("/api/smart-polling/metrics");if(p.ok){const h=await p.json();t(h.data)}}}catch(d){console.error("Failed to force polling:",d)}finally{i(!1)}},l=d=>d<1e3?`${d}ms`:d<6e4?`${Math.round(d/1e3)}s`:`${Math.round(d/6e4)}m`,u=d=>{if(!d)return"Never";const p=new Date(d),v=new Date().getTime()-p.getTime();return v<6e4?`${Math.round(v/1e3)}s ago`:v<36e5?`${Math.round(v/6e4)}m ago`:p.toLocaleTimeString()},c=d=>d.isPolling?d.consecutiveErrors>=3?a.jsx(sl,{className:"h-4 w-4 text-red-500"}):d.consecutiveErrors>0?a.jsx(Mt,{className:"h-4 w-4 text-yellow-500"}):a.jsx(jr,{className:"h-4 w-4 text-green-500"}):a.jsx(dv,{className:"h-4 w-4 text-gray-500"});return n||!e?a.jsxs("div",{className:"rounded-lg border bg-card",children:[a.jsx("div",{className:"border-b border-border p-4",children:a.jsxs("div",{className:"flex items-center gap-2",children:[a.jsx(eo,{className:"h-5 w-5"}),a.jsx("h3",{className:"text-lg font-medium",children:"Smart Polling Status"})]})}),a.jsx("div",{className:"p-6",children:a.jsx("div",{className:"animate-pulse",children:a.jsxs("div",{className:"space-y-3",children:[a.jsx("div",{className:"h-4 bg-muted rounded"}),a.jsx("div",{className:"h-4 bg-muted rounded w-3/4"}),a.jsx("div",{className:"h-4 bg-muted rounded w-1/2"})]})})})]}):a.jsxs("div",{className:"rounded-lg border bg-card",children:[a.jsx("div",{className:"border-b border-border p-4",children:a.jsxs("div",{className:"flex items-center gap-2",children:[a.jsx(eo,{className:"h-5 w-5"}),a.jsx("h3",{className:"text-lg font-medium",children:"Smart Polling Status"}),a.jsxs("div",{className:"ml-auto flex items-center gap-4 text-sm text-muted-foreground",children:[a.jsxs("div",{className:"flex items-center gap-1",children:[a.jsx("div",{className:"w-2 h-2 rounded-full bg-green-500"}),"Active: ",e.activePolling,"/",e.totalOrganizations]}),a.jsxs("div",{className:"flex items-center gap-1",children:[a.jsx(Rp,{className:"h-3 w-3"}),"Avg: ",l(e.averageInterval)]}),a.jsxs("button",{onClick:o,disabled:s,className:"flex items-center gap-1 px-2 py-1 text-xs bg-blue-500 hover:bg-blue-600 disabled:bg-blue-300 text-white rounded transition-colors",title:"Force immediate polling for all organizations",children:[a.jsx(en,{className:`h-3 w-3 ${s?"animate-spin":""}`}),s?"Polling...":"Force Poll"]})]})]})}),a.jsxs("div",{className:"p-6",children:[a.jsxs("div",{className:"grid grid-cols-2 md:grid-cols-4 gap-4 mb-6",children:[a.jsxs("div",{className:"text-center",children:[a.jsx("div",{className:"text-2xl font-bold text-blue-600",children:e.totalPolls}),a.jsx("div",{className:"text-xs text-muted-foreground",children:"Total Polls"})]}),a.jsxs("div",{className:"text-center",children:[a.jsx("div",{className:"text-2xl font-bold text-green-600",children:e.totalClaimedWork}),a.jsx("div",{className:"text-xs text-muted-foreground",children:"Work Claimed"})]}),a.jsxs("div",{className:"text-center",children:[a.jsx("div",{className:"text-2xl font-bold text-red-600",children:e.totalErrors}),a.jsx("div",{className:"text-xs text-muted-foreground",children:"Total Errors"})]}),a.jsxs("div",{className:"text-center",children:[a.jsxs("div",{className:"text-2xl font-bold text-purple-600",children:[(e.errorRate*100).toFixed(1),"%"]}),a.jsx("div",{className:"text-xs text-muted-foreground",children:"Error Rate"})]})]}),a.jsxs("div",{className:"space-y-3",children:[a.jsx("h4",{className:"text-sm font-medium text-muted-foreground mb-3",children:"Organization Status"}),e.organizationStats.length===0?a.jsxs("div",{className:"text-center py-8 text-muted-foreground",children:[a.jsx(eo,{className:"h-8 w-8 mx-auto mb-2 opacity-50"}),a.jsx("p",{children:"No organizations configured"})]}):e.organizationStats.map(d=>a.jsxs("div",{className:"flex items-center gap-3 p-3 rounded-lg bg-muted/50",children:[a.jsx("div",{className:"flex-shrink-0",children:c(d)}),a.jsxs("div",{className:"flex-1 min-w-0",children:[a.jsxs("div",{className:"flex items-center gap-2 mb-1",children:[a.jsx("p",{className:"font-medium truncate",children:d.organizationName}),a.jsx("span",{className:`text-xs px-2 py-1 rounded ${d.isPolling?"bg-green-100 text-green-700":"bg-gray-100 text-gray-700"}`,children:d.isPolling?"Polling":"Stopped"})]}),a.jsxs("div",{className:"grid grid-cols-2 md:grid-cols-4 gap-2 text-xs text-muted-foreground",children:[a.jsxs("div",{children:[a.jsx("span",{className:"font-medium",children:"Interval:"})," ",l(d.currentInterval)]}),a.jsxs("div",{children:[a.jsx("span",{className:"font-medium",children:"Last Poll:"})," ",u(d.lastPollAt)]}),a.jsxs("div",{children:[a.jsx("span",{className:"font-medium",children:"Work Claimed:"})," ",d.claimedWorkCount]}),a.jsxs("div",{className:d.consecutiveErrors>0?"text-red-600":"",children:[a.jsx("span",{className:"font-medium",children:"Errors:"})," ",d.totalErrors,d.consecutiveErrors>0&&` (${d.consecutiveErrors} consecutive)`]})]})]}),a.jsxs("div",{className:"flex-shrink-0 text-right",children:[a.jsx("div",{className:"text-sm font-medium",children:d.totalPolls}),a.jsx("div",{className:"text-xs text-muted-foreground",children:"polls"})]})]},d.organizationId))]}),a.jsxs("div",{className:"mt-6 p-3 bg-muted/30 rounded-lg",children:[a.jsx("div",{className:"text-xs font-medium text-muted-foreground mb-2",children:"Status Indicators"}),a.jsxs("div",{className:"grid grid-cols-2 md:grid-cols-3 gap-2 text-xs",children:[a.jsxs("div",{className:"flex items-center gap-1",children:[a.jsx(jr,{className:"h-3 w-3 text-green-500"}),a.jsx("span",{children:"Healthy polling"})]}),a.jsxs("div",{className:"flex items-center gap-1",children:[a.jsx(Mt,{className:"h-3 w-3 text-yellow-500"}),a.jsx("span",{children:"Some errors"})]}),a.jsxs("div",{className:"flex items-center gap-1",children:[a.jsx(sl,{className:"h-3 w-3 text-red-500"}),a.jsx("span",{children:"Multiple failures"})]})]})]})]})]})}function Zv(){const[e,t]=N.useState(null),[n,r]=N.useState(!0);N.useEffect(()=>{const i=async()=>{try{const l=await fetch("/api/queue/stats");if(l.ok){const u=await l.json();t({queued:u.queued,inProgress:u.inProgress,completedToday:u.completed,completedThisWeek:u.completed,averageCompletionTime:u.averageCompletionTime*1e3,successRate:u.successRate,activeAgents:u.workers,totalProcessed:u.total})}}catch(l){console.error("Failed to fetch queue stats:",l)}finally{r(!1)}};i();const o=setInterval(i,3e4);return()=>clearInterval(o)},[]);const s=i=>i<1e3?`${i}ms`:i<6e4?`${(i/1e3).toFixed(1)}s`:`${(i/6e4).toFixed(1)}m`;return a.jsxs(a.Fragment,{children:[a.jsx(hn,{children:a.jsx("title",{children:"Dashboard - AI Agent Service"})}),a.jsxs("div",{className:"space-y-6",children:[a.jsxs("div",{children:[a.jsx("h2",{className:"text-3xl font-bold tracking-tight",children:"Dashboard"}),a.jsx("p",{className:"text-muted-foreground",children:"Overview of your AI Agent Service performance"})]}),a.jsxs("div",{className:"grid gap-4 md:grid-cols-2 lg:grid-cols-4",children:[a.jsxs("div",{className:"rounded-lg border bg-card p-6",children:[a.jsxs("div",{className:"flex items-center justify-between",children:[a.jsxs("div",{children:[a.jsx("p",{className:"text-sm font-medium text-muted-foreground",children:"Total Tasks"}),a.jsx("div",{className:"text-2xl font-bold text-blue-600",children:n?"-":(e==null?void 0:e.totalProcessed)||0})]}),a.jsx(nv,{className:"h-8 w-8 text-blue-600"})]}),a.jsx("p",{className:"text-xs text-muted-foreground mt-2",children:"All time"})]}),a.jsxs("div",{className:"rounded-lg border bg-card p-6",children:[a.jsxs("div",{className:"flex items-center justify-between",children:[a.jsxs("div",{children:[a.jsx("p",{className:"text-sm font-medium text-muted-foreground",children:"Success Rate"}),a.jsx("div",{className:"text-2xl font-bold text-green-600",children:n?"-":`${Math.round(((e==null?void 0:e.successRate)||0)*100)}%`})]}),a.jsx(hv,{className:"h-8 w-8 text-green-600"})]}),a.jsx("p",{className:"text-xs text-muted-foreground mt-2",children:"Overall performance"})]}),a.jsxs("div",{className:"rounded-lg border bg-card p-6",children:[a.jsxs("div",{className:"flex items-center justify-between",children:[a.jsxs("div",{children:[a.jsx("p",{className:"text-sm font-medium text-muted-foreground",children:"Avg Completion Time"}),a.jsx("div",{className:"text-2xl font-bold text-purple-600",children:n?"-":s((e==null?void 0:e.averageCompletionTime)||0)})]}),a.jsx(Mt,{className:"h-8 w-8 text-purple-600"})]}),a.jsx("p",{className:"text-xs text-muted-foreground mt-2",children:"Per task"})]}),a.jsxs("div",{className:"rounded-lg border bg-card p-6",children:[a.jsxs("div",{className:"flex items-center justify-between",children:[a.jsxs("div",{children:[a.jsx("p",{className:"text-sm font-medium text-muted-foreground",children:"Active Agents"}),a.jsx("div",{className:"text-2xl font-bold text-orange-600",children:n?"-":(e==null?void 0:e.activeAgents)||0})]}),a.jsx(gv,{className:"h-8 w-8 text-orange-600"})]}),a.jsx("p",{className:"text-xs text-muted-foreground mt-2",children:"Currently active"})]})]}),a.jsx(Xv,{}),a.jsx(Jv,{}),a.jsxs("div",{className:"rounded-lg border bg-card p-6",children:[a.jsx("h3",{className:"text-lg font-medium mb-4",children:"Welcome to AI Agent Service"}),a.jsx("p",{className:"text-muted-foreground",children:"This dashboard provides insights into your AI agent performance across multiple Task Shepherd organizations. Visit the Organizations page to manage connections and the Analytics page for detailed metrics."})]})]})]})}const ex=({organizationId:e,onComplete:t,onCancel:n})=>{const[r,s]=N.useState({id:"",name:"",description:""}),[i,o]=N.useState(!1),[l,u]=N.useState(null),c=async p=>{p.preventDefault(),u(null),o(!0);try{const h=await fetch(`/api/organizations/${e}/workspaces`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({...r,services:[]})});if(!h.ok){const x=await h.json();throw new Error(x.error||"Failed to create workspace")}const v=await h.json();if(v.success)t(v.data);else throw new Error(v.error||"Failed to create workspace")}catch(h){console.error("Failed to create workspace:",h),u(h instanceof Error?h.message:"Failed to create workspace")}finally{o(!1)}},d=r.id.trim()&&r.name.trim();return a.jsxs("div",{className:"max-w-2xl mx-auto bg-white rounded-lg shadow-lg",children:[a.jsx("div",{className:"px-6 py-4 border-b border-gray-200",children:a.jsxs("div",{className:"flex items-center justify-between",children:[a.jsx("h1",{className:"text-2xl font-bold text-gray-900",children:"Register Workspace"}),a.jsx("button",{onClick:n,className:"text-gray-400 hover:text-gray-600",children:a.jsx("svg",{className:"w-6 h-6",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:a.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M6 18L18 6M6 6l12 12"})})})]})}),a.jsxs("form",{onSubmit:c,className:"p-6 space-y-6",children:[l&&a.jsx("div",{className:"bg-red-50 border border-red-200 rounded-lg p-4",children:a.jsx("p",{className:"text-sm text-red-700",children:l})}),a.jsxs("div",{children:[a.jsxs("label",{htmlFor:"id",className:"block text-sm font-medium text-gray-700 mb-1",children:["Workspace ID ",a.jsx("span",{className:"text-red-500",children:"*"})]}),a.jsx("input",{type:"text",id:"id",value:r.id,onChange:p=>s({...r,id:p.target.value}),className:"block w-full px-3 py-2 border border-gray-300 rounded-md shadow-sm focus:outline-none focus:ring-blue-500 focus:border-blue-500",placeholder:"my-workspace",required:!0}),a.jsx("p",{className:"mt-1 text-sm text-gray-500",children:'A unique identifier for this workspace (e.g., "my-app", "project-name")'})]}),a.jsxs("div",{children:[a.jsxs("label",{htmlFor:"name",className:"block text-sm font-medium text-gray-700 mb-1",children:["Workspace Name ",a.jsx("span",{className:"text-red-500",children:"*"})]}),a.jsx("input",{type:"text",id:"name",value:r.name,onChange:p=>s({...r,name:p.target.value}),className:"block w-full px-3 py-2 border border-gray-300 rounded-md shadow-sm focus:outline-none focus:ring-blue-500 focus:border-blue-500",placeholder:"My Workspace",required:!0}),a.jsx("p",{className:"mt-1 text-sm text-gray-500",children:"A human-readable name for the workspace"})]}),a.jsxs("div",{children:[a.jsx("label",{htmlFor:"description",className:"block text-sm font-medium text-gray-700 mb-1",children:"Description"}),a.jsx("textarea",{id:"description",value:r.description,onChange:p=>s({...r,description:p.target.value}),rows:3,className:"block w-full px-3 py-2 border border-gray-300 rounded-md shadow-sm focus:outline-none focus:ring-blue-500 focus:border-blue-500",placeholder:"Optional description of this workspace"}),a.jsx("p",{className:"mt-1 text-sm text-gray-500",children:"Optional description of what this workspace contains"})]}),a.jsxs("div",{className:"bg-blue-50 border border-blue-200 rounded-lg p-4",children:[a.jsx("h3",{className:"text-sm font-medium text-blue-800 mb-2",children:"Note"}),a.jsx("p",{className:"text-sm text-blue-700",children:"The agent will handle mapping this workspace to a local path. You can manage services and additional workspace configuration through the main Task Shepherd UI after registration."})]}),a.jsxs("div",{className:"flex justify-end space-x-3 pt-4 border-t border-gray-200",children:[a.jsx("button",{type:"button",onClick:n,className:"px-4 py-2 text-sm font-medium text-gray-700 bg-white border border-gray-300 rounded-md hover:bg-gray-50",children:"Cancel"}),a.jsx("button",{type:"submit",disabled:!d||i,className:"px-4 py-2 text-sm font-medium text-white bg-blue-600 border border-transparent rounded-md hover:bg-blue-700 disabled:opacity-50 disabled:cursor-not-allowed",children:i?"Creating...":"Register Workspace"})]})]})]})},tx=({organizationId:e,workspace:t,onClose:n,onApplyChanges:r})=>{var C;const[s,i]=N.useState(!1),[o,l]=N.useState(null),[u,c]=N.useState(new Set),[d,p]=N.useState(null),[h,v]=N.useState({}),x=async()=>{i(!0);try{const j=await fetch(`/api/organizations/${e}/workspaces/${t.id}/analyze`,{method:"POST",headers:{"Content-Type":"application/json"}});if(!j.ok)throw new Error("Failed to analyze workspace");const R=await j.json();if(R.success)l(R.data);else throw new Error(R.error||"Analysis failed")}catch(j){console.error("Workspace analysis failed:",j),alert(j instanceof Error?j.message:"Failed to analyze workspace")}finally{i(!1)}},w=j=>{switch(j){case"found":return a.jsx(jr,{className:"w-4 h-4 text-green-500"});case"outdated":return a.jsx(sl,{className:"w-4 h-4 text-yellow-500"});case"missing":return a.jsx(Hc,{className:"w-4 h-4 text-red-500"});default:return null}},k=j=>{switch(j){case"add_service":return a.jsx(pr,{className:"w-4 h-4 text-green-500"});case"update_service":return a.jsx(en,{className:"w-4 h-4 text-blue-500"});case"remove_service":return a.jsx(Hc,{className:"w-4 h-4 text-red-500"});default:return a.jsx(tv,{className:"w-4 h-4 text-gray-500"})}},m=j=>{const R=new Set(u);R.has(j)?R.delete(j):R.add(j),c(R)},f=()=>{if(!o||u.size===0)return;const j=Array.from(u).map(R=>o.improvements[R]);r==null||r(j),n()},g=j=>{p(j.name),v({name:j.name,type:j.type,technology:j.technology,port:j.port,description:j.description})},b=()=>{p(null),v({})},E=async()=>{if(d)try{const j=await fetch(`/api/organizations/${e}/workspaces/${t.id}/services/${d}`,{method:"PATCH",headers:{"Content-Type":"application/json"},body:JSON.stringify(h)}),R=await j.json();if(j.ok&&R.success)p(null),v({}),await x();else throw new Error(R.error||"Failed to update service")}catch(j){console.error("Failed to update service:",j),alert(j instanceof Error?j.message:"Failed to update service")}},T=async j=>{if(confirm(`Are you sure you want to remove the service "${j}"? This action cannot be undone.`))try{const R=await fetch(`/api/organizations/${e}/workspaces/${t.id}/services/${j}`,{method:"DELETE"}),M=await R.json();if(R.ok&&M.success)await x();else throw new Error(M.error||"Failed to remove service")}catch(R){console.error("Failed to remove service:",R),alert(R instanceof Error?R.message:"Failed to remove service")}};return a.jsx("div",{className:"fixed inset-0 bg-black bg-opacity-50 flex items-center justify-center p-4 z-50",children:a.jsxs("div",{className:"bg-white rounded-lg shadow-xl max-w-6xl w-full max-h-[90vh] overflow-hidden",children:[a.jsxs("div",{className:"px-6 py-4 border-b border-gray-200",children:[a.jsxs("div",{className:"flex items-center justify-between",children:[a.jsxs("h1",{className:"text-2xl font-bold text-gray-900",children:["Analyze Workspace: ",t.name]}),a.jsx("button",{onClick:n,className:"text-gray-400 hover:text-gray-600",children:a.jsx(Pn,{className:"w-6 h-6"})})]}),a.jsx("p",{className:"mt-2 text-sm text-gray-600",children:"Analyze the current workspace configuration and discover improvements"})]}),a.jsxs("div",{className:"p-6 overflow-y-auto max-h-[calc(90vh-140px)]",children:[!o&&a.jsxs("div",{className:"text-center py-12",children:[a.jsxs("div",{className:"mb-6",children:[a.jsx("div",{className:"w-16 h-16 bg-blue-100 rounded-full flex items-center justify-center mx-auto mb-4",children:a.jsx(en,{className:"w-8 h-8 text-blue-600"})}),a.jsx("h3",{className:"text-lg font-medium text-gray-900 mb-2",children:"Ready to Analyze Workspace"}),a.jsx("p",{className:"text-gray-600 mb-6 max-w-md mx-auto",children:"This will scan the workspace directory and compare it with your current configuration to suggest improvements."}),a.jsx("div",{className:"bg-gray-50 rounded-lg p-4 mb-6",children:a.jsxs("div",{className:"text-sm text-gray-700",children:[a.jsxs("div",{children:[a.jsx("strong",{children:"Workspace:"})," ",t.name]}),a.jsxs("div",{children:[a.jsx("strong",{children:"Path:"})," ",a.jsx("code",{className:"font-mono text-xs",children:t.path})]}),a.jsxs("div",{children:[a.jsx("strong",{children:"Current services:"})," ",((C=t.services)==null?void 0:C.length)||0]})]})})]}),a.jsx("button",{onClick:x,disabled:s,className:"inline-flex items-center px-4 py-2 text-sm font-medium text-white bg-blue-600 border border-transparent rounded-md hover:bg-blue-700 disabled:opacity-50 disabled:cursor-not-allowed",children:s?a.jsxs(a.Fragment,{children:[a.jsx(en,{className:"w-4 h-4 mr-2 animate-spin"}),"Analyzing..."]}):a.jsxs(a.Fragment,{children:[a.jsx(en,{className:"w-4 h-4 mr-2"}),"Start Analysis"]})})]}),o&&a.jsxs("div",{className:"space-y-6",children:[a.jsxs("div",{className:"bg-blue-50 border border-blue-200 rounded-lg p-4",children:[a.jsx("h3",{className:"text-lg font-medium text-blue-900 mb-2",children:"Analysis Summary"}),a.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-3 gap-4 text-sm",children:[a.jsxs("div",{children:[a.jsx("div",{className:"text-blue-800 font-medium",children:"Current Services"}),a.jsxs("div",{className:"text-blue-600",children:[o.currentServices.length," configured"]})]}),a.jsxs("div",{children:[a.jsx("div",{className:"text-blue-800 font-medium",children:"Discovered Services"}),a.jsxs("div",{className:"text-blue-600",children:[o.discoveredServices.length," found"]})]}),a.jsxs("div",{children:[a.jsx("div",{className:"text-blue-800 font-medium",children:"Improvements"}),a.jsxs("div",{className:"text-blue-600",children:[o.improvements.length," suggested"]})]})]})]}),a.jsxs("div",{className:"bg-white border border-gray-200 rounded-lg p-4",children:[a.jsx("h3",{className:"text-lg font-medium text-gray-900 mb-4",children:"Current Services Status"}),o.currentServices.length>0?a.jsx("div",{className:"space-y-2",children:o.currentServices.map((j,R)=>a.jsx("div",{className:"p-3 bg-gray-50 rounded-lg border",children:d===j.name?a.jsxs("div",{className:"space-y-3",children:[a.jsxs("div",{className:"grid grid-cols-2 gap-3",children:[a.jsxs("div",{children:[a.jsx("label",{className:"block text-xs font-medium text-gray-700 mb-1",children:"Name"}),a.jsx("input",{type:"text",value:h.name||"",onChange:M=>v({...h,name:M.target.value}),className:"w-full text-xs px-2 py-1 border border-gray-300 rounded focus:outline-none focus:ring-1 focus:ring-blue-500"})]}),a.jsxs("div",{children:[a.jsx("label",{className:"block text-xs font-medium text-gray-700 mb-1",children:"Type"}),a.jsxs("select",{value:h.type||"backend",onChange:M=>v({...h,type:M.target.value}),className:"w-full text-xs px-2 py-1 border border-gray-300 rounded focus:outline-none focus:ring-1 focus:ring-blue-500",children:[a.jsx("option",{value:"backend",children:"Backend"}),a.jsx("option",{value:"frontend",children:"Frontend"}),a.jsx("option",{value:"database",children:"Database"}),a.jsx("option",{value:"cache",children:"Cache"}),a.jsx("option",{value:"queue",children:"Queue"}),a.jsx("option",{value:"api",children:"API"}),a.jsx("option",{value:"service",children:"Service"}),a.jsx("option",{value:"other",children:"Other"})]})]})]}),a.jsxs("div",{className:"grid grid-cols-2 gap-3",children:[a.jsxs("div",{children:[a.jsx("label",{className:"block text-xs font-medium text-gray-700 mb-1",children:"Technology"}),a.jsx("input",{type:"text",value:h.technology||"",onChange:M=>v({...h,technology:M.target.value}),className:"w-full text-xs px-2 py-1 border border-gray-300 rounded focus:outline-none focus:ring-1 focus:ring-blue-500",placeholder:"e.g., Node.js, Python"})]}),a.jsxs("div",{children:[a.jsx("label",{className:"block text-xs font-medium text-gray-700 mb-1",children:"Port"}),a.jsx("input",{type:"number",value:h.port||"",onChange:M=>v({...h,port:M.target.value?parseInt(M.target.value):void 0}),className:"w-full text-xs px-2 py-1 border border-gray-300 rounded focus:outline-none focus:ring-1 focus:ring-blue-500",placeholder:"3000"})]})]}),a.jsxs("div",{children:[a.jsx("label",{className:"block text-xs font-medium text-gray-700 mb-1",children:"Description"}),a.jsx("input",{type:"text",value:h.description||"",onChange:M=>v({...h,description:M.target.value}),className:"w-full text-xs px-2 py-1 border border-gray-300 rounded focus:outline-none focus:ring-1 focus:ring-blue-500",placeholder:"Optional description"})]}),a.jsxs("div",{className:"flex items-center justify-end gap-2 pt-2",children:[a.jsxs("button",{onClick:E,className:"inline-flex items-center px-3 py-1 text-xs bg-green-600 text-white rounded hover:bg-green-700",children:[a.jsx(gi,{className:"h-3 w-3 mr-1"}),"Save"]}),a.jsxs("button",{onClick:b,className:"inline-flex items-center px-3 py-1 text-xs bg-gray-600 text-white rounded hover:bg-gray-700",children:[a.jsx(Pn,{className:"h-3 w-3 mr-1"}),"Cancel"]})]})]}):a.jsxs("div",{className:"flex items-center justify-between",children:[a.jsxs("div",{className:"flex items-center gap-3",children:[w(j.status),a.jsxs("div",{children:[a.jsx("div",{className:"font-medium",children:j.name}),a.jsxs("div",{className:"text-sm text-gray-600",children:[j.type," ",j.technology&&`• ${j.technology}`," ",j.port&&`• Port ${j.port}`,j.description&&` • ${j.description}`]})]})]}),a.jsxs("div",{className:"flex items-center gap-2",children:[a.jsx("button",{onClick:()=>g(j),className:"p-1 text-gray-500 hover:text-orange-600 transition-colors",title:"Edit service",children:a.jsx(mi,{className:"h-3 w-3"})}),a.jsx("button",{onClick:()=>T(j.name),className:"p-1 text-gray-500 hover:text-red-600 transition-colors",title:"Remove service",children:a.jsx(ss,{className:"h-3 w-3"})}),a.jsx("span",{className:`px-2 py-1 text-xs rounded-full ${j.status==="found"?"bg-green-100 text-green-800":j.status==="outdated"?"bg-yellow-100 text-yellow-800":"bg-red-100 text-red-800"}`,children:j.status})]})]})},R))}):a.jsx("p",{className:"text-gray-600",children:"No services currently configured"})]}),o.improvements.length>0&&a.jsxs("div",{className:"bg-white border border-gray-200 rounded-lg p-4",children:[a.jsxs("h3",{className:"text-lg font-medium text-gray-900 mb-4",children:["Suggested Improvements (",o.improvements.length,")"]}),a.jsx("div",{className:"space-y-3",children:o.improvements.map((j,R)=>a.jsxs("div",{className:"flex items-start gap-3 p-3 border border-gray-200 rounded-lg hover:bg-gray-50",children:[a.jsx("input",{type:"checkbox",id:`improvement-${R}`,checked:u.has(R),onChange:()=>m(R),className:"mt-1 h-4 w-4 text-blue-600 focus:ring-blue-500 border-gray-300 rounded"}),a.jsxs("div",{className:"flex-1",children:[a.jsxs("div",{className:"flex items-center gap-2 mb-1",children:[k(j.type),a.jsx("span",{className:"font-medium",children:j.service}),a.jsx("span",{className:`px-2 py-1 text-xs rounded-full ${j.type==="add_service"?"bg-green-100 text-green-800":j.type==="update_service"?"bg-blue-100 text-blue-800":j.type==="remove_service"?"bg-red-100 text-red-800":"bg-gray-100 text-gray-800"}`,children:j.type.replace("_"," ")})]}),a.jsx("p",{className:"text-sm text-gray-700 mb-1",children:j.description}),a.jsx("p",{className:"text-xs text-gray-500",children:j.action})]})]},R))}),u.size>0&&a.jsx("div",{className:"mt-4 p-3 bg-blue-50 border border-blue-200 rounded-lg",children:a.jsxs("div",{className:"flex items-center justify-between",children:[a.jsxs("span",{className:"text-sm text-blue-800",children:[u.size," improvement(s) selected"]}),a.jsx("button",{onClick:f,className:"px-3 py-1 text-sm bg-blue-600 text-white rounded hover:bg-blue-700",children:"Apply Selected"})]})})]}),o.recommendations.length>0&&a.jsxs("div",{className:"bg-green-50 border border-green-200 rounded-lg p-4",children:[a.jsx("h3",{className:"text-sm font-medium text-green-800 mb-2",children:"Recommendations"}),a.jsx("ul",{className:"space-y-1",children:o.recommendations.map((j,R)=>a.jsxs("li",{className:"text-sm text-green-700",children:["• ",j]},R))})]}),o.warnings.length>0&&a.jsxs("div",{className:"bg-yellow-50 border border-yellow-200 rounded-lg p-4",children:[a.jsx("h3",{className:"text-sm font-medium text-yellow-800 mb-2",children:"Warnings"}),a.jsx("ul",{className:"space-y-1",children:o.warnings.map((j,R)=>a.jsxs("li",{className:"text-sm text-yellow-700",children:["• ",j]},R))})]}),a.jsx("div",{className:"text-center pt-4 border-t border-gray-200",children:a.jsxs("button",{onClick:x,disabled:s,className:"inline-flex items-center px-3 py-2 text-sm text-gray-600 bg-gray-100 border border-gray-300 rounded-md hover:bg-gray-200 disabled:opacity-50",children:[a.jsx(en,{className:`w-4 h-4 mr-2 ${s?"animate-spin":""}`}),"Re-analyze"]})})]})]})]})})};function nx(){const[e,t]=N.useState(null),[n,r]=N.useState(!0),[s,i]=N.useState(!1),[o,l]=N.useState({name:"",basePath:"",apiKey:""}),[u,c]=N.useState([]),[d,p]=N.useState(new Set),[h,v]=N.useState(new Set),[x,w]=N.useState(null),[k,m]=N.useState(null),[f,g]=N.useState(null),[b,E]=N.useState({name:"",id:"",path:"",description:""}),[T,C]=N.useState(new Set),[j,R]=N.useState(null),[M,K]=N.useState({name:"",type:"backend",port:"",url:"",technology:"",description:""}),[G,Ce]=N.useState(Date.now()),[P,q]=N.useState(null),[Y,ae]=N.useState(null),[A,F]=N.useState(null),[U,ee]=N.useState({}),[Q,X]=N.useState({}),[ue,Ae]=N.useState({}),[ve,Ge]=N.useState(!1),[kt,Be]=N.useState(null),[be,Er]=N.useState([]),[fe,V]=N.useState(new Set),[ce,Te]=N.useState({}),[ht,St]=N.useState(!1),[Wn,fa]=N.useState(!1),[Up,pa]=N.useState([]),[ha,Wp]=N.useState(new Set),[Bp,ma]=N.useState(null),[ga,zs]=N.useState(""),[uu,cu]=N.useState(!1),[wn,ya]=N.useState({}),[Bn,va]=N.useState(new Set);N.useEffect(()=>{As()},[]);const J=(y,S,I)=>{const D={id:Date.now().toString(),type:y,title:S,message:I,timestamp:Date.now()};c(W=>[...W,D]),y==="success"&&setTimeout(()=>{c(W=>W.filter(Z=>Z.id!==D.id))},5e3)},Hp=y=>{c(S=>S.filter(I=>I.id!==y))},As=async()=>{try{const y=await fetch("/api/organizations");if(y.ok){const S=await y.json();t(S.data),Ce(Date.now())}}catch(y){console.error("Failed to fetch organizations:",y)}finally{r(!1)}},jn=async()=>{await As()},xa=()=>{},wa=()=>{},ja=()=>{},qp=async y=>{try{const S=await fetch(`/api/project-mappings/organization/${y}`);if(S.ok){const I=await S.json();pa(I.mappings||[])}}catch(S){console.error("Failed to fetch project mappings:",S)}},Qp=async(y,S,I)=>{if(!ga.trim()){J("error","Invalid Path","Please enter a valid local path");return}cu(!0);try{const D=await fetch("/api/project-mappings",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({organizationId:y,projectId:S,localPath:ga,projectName:I})}),W=await D.json();D.ok&&W.success?(pa(Z=>{const de=Z.findIndex(oe=>oe.projectId===S);if(de>=0){const oe=[...Z];return oe[de]=W.mapping,oe}return[...Z,W.mapping]}),ma(null),zs(""),J("success","Mapping Saved",`Successfully mapped "${I}" to local path`)):J("error","Failed to Save Mapping",W.error||"Unknown error")}catch(D){console.error("Failed to save project mapping:",D),J("error","Network Error","Failed to save project mapping")}finally{cu(!1)}},Vp=async(y,S)=>{try{const I=await fetch(`/api/project-mappings/${y}/${S}`,{method:"DELETE"});if(I.ok)pa(D=>D.filter(W=>W.projectId!==S)),J("success","Mapping Removed","Project path mapping has been removed");else{const D=await I.json();J("error","Failed to Remove Mapping",D.error||"Unknown error")}}catch(I){console.error("Failed to remove project mapping:",I),J("error","Network Error","Failed to remove project mapping")}},Kp=y=>Up.find(S=>S.projectId===y),Gp=async y=>{const S=new Set(d);S.has(y)?S.delete(y):(S.add(y),await qp(y)),p(S)},Yp=async(y,S)=>{y.preventDefault();try{const I=await fetch(`/api/organizations/${S}/workspaces`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(b)}),D=await I.json();if(I.ok&&D.success&&D.data){if(e){const W=e.organizations.map(Z=>{if(Z.id===S){const de=Z.workspaces||[];return{...Z,workspaces:[...de,D.data],workspaceCount:(Z.workspaceCount||0)+1}}return Z});t({...e,organizations:W})}w(null),E({name:"",id:"",path:"",description:""}),xa(),J("success","Workspace Added",`Successfully added workspace "${b.name}"`)}else J("error","Failed to Add Workspace",D.message||D.error)}catch(I){console.error("Failed to add workspace:",I),J("error","Network Error","Failed to add workspace. Please try again.")}},Jp=async(y,S,I)=>{console.log("🔄 handleUpdateWorkspace called:",{orgId:y,workspaceId:S,updates:I});try{console.log("📡 Making PATCH request to:",`/api/organizations/${y}/workspaces/${S}`);const D=await fetch(`/api/organizations/${y}/workspaces/${S}`,{method:"PATCH",headers:{"Content-Type":"application/json"},body:JSON.stringify(I)});console.log("📨 Response status:",D.status,D.statusText);const W=await D.json();D.ok?(await jn(),J("success","Workspace Updated","Workspace settings updated successfully")):J("error","Failed to Update Workspace",W.message||W.error)}catch(D){console.error("Failed to update workspace:",D),J("error","Network Error","Failed to update workspace. Please try again.")}},Xp=y=>{ae(y.id),X({name:y.name,type:y.type,technology:y.technology,port:y.port,url:y.url,description:y.description})},Zp=()=>{ae(null),X({})},eh=async(y,S,I)=>{try{const D=await fetch(`/api/organizations/${y}/workspaces/${S}/services/${I}`,{method:"PATCH",headers:{"Content-Type":"application/json"},body:JSON.stringify(Q)}),W=await D.json();if(D.ok&&W.success)await jn(),ae(null),X({}),J("success","Service Updated","Service details updated successfully");else throw new Error(W.error||"Failed to update service")}catch(D){console.error("Failed to update service:",D),J("error","Update Failed",D instanceof Error?D.message:"Failed to update service")}},th=async(y,S,I,D)=>{if(confirm(`Are you sure you want to remove the service "${D}"? This action cannot be undone.`))try{const W=await fetch(`/api/organizations/${y}/workspaces/${S}/services/${I}`,{method:"DELETE"}),Z=await W.json();if(W.ok&&Z.success)await jn(),J("success","Service Removed",`Service "${D}" has been removed`);else throw new Error(Z.error||"Failed to remove service")}catch(W){console.error("Failed to remove service:",W),J("error","Removal Failed",W instanceof Error?W.message:"Failed to remove service")}},nh=async(y,S,I)=>{y.preventDefault();try{const D={...M,port:M.port?parseInt(M.port):void 0,isActive:!0},W=await fetch(`/api/organizations/${S}/workspaces/${I}/services`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(D)}),Z=await W.json();if(W.ok&&Z.success){if(e){const de=e.organizations.map(oe=>{var z;if(oe.id===S){const $=(z=oe.workspaces)==null?void 0:z.map(H=>{if(H.id===I){const Fe=H.services||[];return{...H,services:[...Fe,Z.data]}}return H});return{...oe,workspaces:$}}return oe});t({...e,organizations:de})}R(null),K({name:"",type:"backend",port:"",url:"",technology:"",description:""}),xa(),J("success","Service Added",`Successfully added service "${D.name}"`)}else J("error","Failed to Add Service",Z.message||Z.error)}catch(D){console.error("Failed to add service:",D),J("error","Network Error","Failed to add service. Please try again.")}},rh=async(y,S,I,D)=>{try{const W=await fetch(`/api/organizations/${y}/workspaces/${S}/services/${I}`,{method:"PATCH",headers:{"Content-Type":"application/json"},body:JSON.stringify({isActive:D})}),Z=await W.json();if(W.ok&&Z.success){if(e){const de=e.organizations.map(oe=>{var z;if(oe.id===y){const $=(z=oe.workspaces)==null?void 0:z.map(H=>{var Fe;if(H.id===S){const Wt=(Fe=H.services)==null?void 0:Fe.map(Bt=>Bt.id===I?{...Bt,isActive:D}:Bt);return{...H,services:Wt}}return H});return{...oe,workspaces:$}}return oe});t({...e,organizations:de})}J("success","Service Updated",`Service ${D?"activated":"deactivated"} successfully`)}else J("error","Failed to Update Service",Z.message||Z.error)}catch(W){console.error("Failed to update service:",W),J("error","Network Error","Failed to update service. Please try again.")}},sh=y=>{F(y.id),Ae({name:y.name,apiUrl:y.apiUrl,apiKey:"",enabled:y.enabled})},ih=()=>{F(null),Ae({})},ah=async y=>{Ge(!0);try{const S=await fetch(`/api/organizations/${y}`,{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify(ue)}),I=await S.json();if(S.ok&&I.success)await jn(),F(null),Ae({}),J("success","Organization Updated","Organization details updated successfully");else throw new Error(I.error||"Failed to update organization")}catch(S){console.error("Failed to update organization:",S),J("error","Update Failed",S instanceof Error?S.message:"Failed to update organization")}finally{Ge(!1)}},oh=async y=>{Be(y),St(!0);try{const[S,I]=await Promise.all([fetch(`/api/organizations/${y}/workspaces/available`),fetch(`/api/service-mappings/organization/${y}`)]),D=await S.json();if(S.ok&&D.success){Er(D.workspaces||[]);const W=new Set,Z={};if(D.workspaces.forEach(de=>{de.syncedLocally&&de.isActive!==!1?(W.add(de.id),Z[de.id]=de.localPath||de.path||""):Z[de.id]=de.path||""}),V(W),Te(Z),I.ok){const oe=(await I.json()).mappings||[],z={};oe.forEach($=>{z[`${$.workspaceId}:${$.serviceId}`]=$.localPath}),ya(z)}}else J("error","Failed to Fetch Workspaces",D.error||"Could not fetch available workspaces"),Be(null)}catch(S){console.error("Failed to fetch available workspaces:",S),J("error","Network Error","Failed to fetch available workspaces. Please try again."),Be(null)}finally{St(!1)}},lh=async y=>{fa(!0);try{if(fe.size>0){const oe=await fetch(`/api/organizations/${y}/workspaces/sync`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({workspaceIds:Array.from(fe)})}),z=await oe.json();if(!oe.ok){J("error","Failed to Sync Workspaces",z.message||z.error),fa(!1);return}for(const $ of fe){const H=be.find(Wt=>Wt.id===$),Fe=ce[$];H&&Fe&&Fe!==H.path&&await fetch(`/api/organizations/${y}/workspaces/${$}`,{method:"PATCH",headers:{"Content-Type":"application/json"},body:JSON.stringify({path:Fe})})}}const S=new Set(fe),I=be.filter(oe=>oe.syncedLocally&&!S.has(oe.id));for(const oe of I)await fetch(`/api/organizations/${y}/workspaces/${oe.id}`,{method:"PATCH",headers:{"Content-Type":"application/json"},body:JSON.stringify({isActive:!1})});let D=0;for(const[oe,z]of Object.entries(wn))if(z&&z.trim()){const[$,H]=oe.split(":");if(!$||!H)continue;let Fe="",Wt="";const Bt=be.find(Ht=>Ht.id===$);if(Bt!=null&&Bt.services){const Ht=Bt.services.find(dh=>dh.id===H);Ht&&(Fe=Ht.name,Wt=Ht.technology||"")}try{(await fetch("/api/service-mappings",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({organizationId:y,workspaceId:$,serviceId:H,localPath:z.trim(),serviceName:Fe,technology:Wt})})).ok&&D++}catch(Ht){console.error("Failed to save service mapping:",Ht)}}await jn();const W=fe.size,Z=I.length;let de="";W>0&&Z>0?de=`Saved ${W} workspace(s) and disabled ${Z} workspace(s)`:W>0?de=`Saved ${W} workspace(s)`:Z>0?de=`Disabled ${Z} workspace(s)`:de="No changes made",D>0&&(de+=`, ${D} service path(s) mapped`),J("success","Workspaces Updated",de),Be(null),va(new Set)}catch(S){console.error("Failed to save workspaces:",S),J("error","Network Error","Failed to save workspaces. Please try again.")}finally{fa(!1)}},uh=async y=>{y.preventDefault();try{const S=o.basePath.endsWith("/")?`${o.basePath}graphql`:`${o.basePath}/graphql`,I={name:o.name,apiUrl:S,apiKey:o.apiKey},D=await fetch("/api/organizations",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(I)}),W=await D.json();D.ok?(await As(),i(!1),l({name:"",basePath:"",apiKey:""}),xa(),J("success","Organization Added",`Successfully added "${o.name}"`)):J("error","Failed to Add Organization",W.message||W.error)}catch(S){console.error("Failed to add organization:",S),J("error","Network Error","Failed to connect to server. Please try again.")}},ch=async y=>{if(confirm("Are you sure you want to delete this organization?"))try{const S=await fetch(`/api/organizations/${y}`,{method:"DELETE"}),I=await S.json();S.ok?(await As(),J("success","Organization Deleted",I.message||"Organization deleted successfully")):J("error","Failed to Delete Organization",I.message||I.error)}catch(S){console.error("Failed to delete organization:",S),J("error","Network Error","Failed to delete organization. Please try again.")}};return a.jsxs(a.Fragment,{children:[a.jsx(hn,{children:a.jsx("title",{children:"Organizations - AI Agent Service"})}),a.jsxs("div",{className:"space-y-6",children:[a.jsxs("div",{className:"flex items-center justify-between",children:[a.jsxs("div",{children:[a.jsx("h2",{className:"text-3xl font-bold tracking-tight",children:"Organizations"}),a.jsx("p",{className:"text-muted-foreground",children:"Manage Task Shepherd organizations and API connections"})]}),a.jsxs("div",{className:"flex items-center gap-3",children:[a.jsxs("div",{className:"flex items-center gap-2 text-sm text-muted-foreground",children:[a.jsx(Mt,{className:"h-4 w-4"}),a.jsxs("span",{children:["Last updated: ",new Date(G).toLocaleTimeString()]})]}),a.jsxs("button",{onClick:jn,disabled:n,className:"inline-flex items-center px-3 py-2 text-sm text-gray-600 border border-gray-300 rounded-md hover:bg-gray-50 disabled:opacity-50",children:[a.jsx(en,{className:`h-4 w-4 mr-2 ${n?"animate-spin":""}`}),"Refresh"]}),a.jsxs("button",{onClick:()=>{i(!0)},className:"inline-flex items-center px-4 py-2 bg-blue-600 text-white rounded-md hover:bg-blue-700 focus:outline-none focus:ring-2 focus:ring-blue-500 focus:ring-offset-2",children:[a.jsx(pr,{className:"h-4 w-4 mr-2"}),"Add Organization"]})]})]}),u.filter(y=>!(y.type==="success"&&y.title==="Connection Test")).length>0&&a.jsx("div",{className:"space-y-2",children:u.filter(y=>!(y.type==="success"&&y.title==="Connection Test")).map(y=>a.jsxs("div",{className:`flex items-start justify-between p-3 rounded-md border text-sm ${y.type==="error"?"border-red-200 bg-red-50 text-red-800":"border-green-200 bg-green-50 text-green-800"}`,children:[a.jsxs("div",{className:"flex items-start space-x-2",children:[y.type==="error"?a.jsx(Jt,{className:"h-4 w-4 text-red-600 mt-0.5 flex-shrink-0"}):a.jsx(jr,{className:"h-4 w-4 text-green-600 mt-0.5 flex-shrink-0"}),a.jsxs("div",{children:[a.jsx("p",{className:"font-medium",children:y.title}),a.jsx("p",{className:"opacity-90",children:y.message}),y.type==="error"&&a.jsx("p",{className:"text-xs mt-1 opacity-75",children:"Check your API URL format and ensure the Agent API key is valid for this organization."})]})]}),a.jsx("button",{onClick:()=>Hp(y.id),className:"text-current opacity-60 hover:opacity-100 transition-opacity ml-2",children:a.jsx(Pn,{className:"h-3 w-3"})})]},y.id))}),!n&&e&&a.jsx("div",{className:"rounded-lg border bg-card p-6",children:a.jsxs("div",{className:"flex items-center gap-3",children:[a.jsx(Jt,{className:`h-5 w-5 ${e.setupCompleted?"text-green-600":"text-yellow-600"}`}),a.jsxs("div",{children:[a.jsx("h3",{className:"font-medium",children:e.setupCompleted?"Setup Complete":"Setup Required"}),a.jsx("p",{className:"text-sm text-muted-foreground",children:e.setupCompleted?`You have ${e.organizations.length} organization(s) configured.`:"Add your first organization to get started with Task Shepherd integration."})]})]})}),s&&a.jsxs("div",{className:"rounded-lg border bg-card p-6",children:[a.jsx("h3",{className:"text-lg font-medium mb-4",children:"Add New Organization"}),a.jsxs("form",{onSubmit:uh,className:"space-y-4",children:[a.jsxs("div",{children:[a.jsx("label",{htmlFor:"name",className:"block text-sm font-medium mb-2",children:"Organization Name"}),a.jsx("input",{type:"text",id:"name",value:o.name,onChange:y=>l({...o,name:y.target.value}),onFocus:wa,onBlur:ja,className:"w-full px-3 py-2 border border-gray-300 rounded-md focus:outline-none focus:ring-2 focus:ring-blue-500 focus:border-transparent",placeholder:"e.g. My Company",required:!0}),a.jsx("p",{className:"text-xs text-muted-foreground mt-1",children:"A friendly name to identify this Task Shepherd instance"})]}),a.jsxs("div",{children:[a.jsx("label",{htmlFor:"basePath",className:"block text-sm font-medium mb-2",children:"API Base Path"}),a.jsx("input",{type:"url",id:"basePath",value:o.basePath,onChange:y=>l({...o,basePath:y.target.value}),onFocus:wa,onBlur:ja,className:"w-full px-3 py-2 border border-gray-300 rounded-md focus:outline-none focus:ring-2 focus:ring-blue-500 focus:border-transparent",placeholder:"https://myorg.taskshepherd.com/api",required:!0}),a.jsx("p",{className:"text-xs text-muted-foreground mt-1",children:"Base API path (GraphQL will be appended automatically: /api → /api/graphql)"}),o.basePath&&a.jsxs("p",{className:"text-xs text-blue-600 mt-1",children:["GraphQL URL will be: ",a.jsx("code",{children:o.basePath.endsWith("/")?`${o.basePath}graphql`:`${o.basePath}/graphql`})]})]}),a.jsxs("div",{children:[a.jsx("label",{htmlFor:"apiKey",className:"block text-sm font-medium mb-2",children:"Agent API Key"}),a.jsx("input",{type:"password",id:"apiKey",value:o.apiKey,onChange:y=>l({...o,apiKey:y.target.value}),onFocus:wa,onBlur:ja,className:"w-full px-3 py-2 border border-gray-300 rounded-md focus:outline-none focus:ring-2 focus:ring-blue-500 focus:border-transparent",placeholder:"tks_agent_...",required:!0}),a.jsxs("p",{className:"text-xs text-muted-foreground mt-1",children:["Generate an ",a.jsx("strong",{children:"Agent API key"})," from your Task Shepherd organization settings → API Keys → Create Agent Key"]})]}),a.jsxs("div",{className:"flex justify-end gap-3 pt-2",children:[a.jsx("button",{type:"button",onClick:()=>{i(!1),l({name:"",basePath:"",apiKey:""}),c([])},className:"px-4 py-2 text-gray-600 border border-gray-300 rounded-md hover:bg-gray-50",children:"Cancel"}),a.jsx("button",{type:"submit",className:"px-4 py-2 bg-blue-600 text-white rounded-md hover:bg-blue-700",children:"Add Organization"})]})]})]}),n?a.jsx("div",{className:"text-center py-12",children:a.jsx("div",{className:"text-muted-foreground",children:"Loading organizations..."})}):(e==null?void 0:e.organizations.length)===0?a.jsxs("div",{className:"text-center py-12",children:[a.jsx(Vr,{className:"h-12 w-12 text-muted-foreground mx-auto mb-4"}),a.jsx("h3",{className:"text-lg font-medium mb-2",children:"No Organizations Configured"}),a.jsx("p",{className:"text-muted-foreground mb-4",children:"Add your first organization to start using the AI Agent Service with Task Shepherd."}),a.jsxs("button",{onClick:()=>{i(!0)},className:"inline-flex items-center px-4 py-2 bg-blue-600 text-white rounded-md hover:bg-blue-700",children:[a.jsx(pr,{className:"h-4 w-4 mr-2"}),"Add Organization"]})]}):a.jsx("div",{className:"grid gap-4",children:e==null?void 0:e.organizations.map(y=>{var W,Z,de,oe;const S=((W=y.workerRegistration)==null?void 0:W.registered)||!1,I=((Z=y.workerRegistration)==null?void 0:Z.lastHeartbeat)||y.createdAt,D=(de=y.workerRegistration)!=null&&de.lastHeartbeat?"Last heartbeat":"Created";return a.jsxs("div",{className:"rounded-lg border bg-card p-6",children:[a.jsxs("div",{className:"flex items-center justify-between",children:[a.jsx("div",{className:"flex-1",children:A===y.id?a.jsxs("div",{className:"space-y-3",children:[a.jsxs("div",{children:[a.jsx("label",{className:"block text-sm font-medium text-gray-700 mb-1",children:"Name"}),a.jsx("input",{type:"text",value:ue.name||"",onChange:z=>Ae({...ue,name:z.target.value}),className:"w-full px-3 py-2 border border-gray-300 rounded focus:outline-none focus:ring-2 focus:ring-blue-500"})]}),a.jsxs("div",{children:[a.jsx("label",{className:"block text-sm font-medium text-gray-700 mb-1",children:"API URL"}),a.jsx("input",{type:"text",value:ue.apiUrl||"",onChange:z=>Ae({...ue,apiUrl:z.target.value}),className:"w-full px-3 py-2 border border-gray-300 rounded focus:outline-none focus:ring-2 focus:ring-blue-500"})]}),a.jsxs("div",{children:[a.jsx("label",{className:"block text-sm font-medium text-gray-700 mb-1",children:"API Key"}),a.jsx("input",{type:"password",value:ue.apiKey||"",onChange:z=>Ae({...ue,apiKey:z.target.value}),className:"w-full px-3 py-2 border border-gray-300 rounded focus:outline-none focus:ring-2 focus:ring-blue-500",placeholder:"Leave empty to keep current key"})]}),a.jsxs("div",{className:"flex items-center",children:[a.jsx("input",{type:"checkbox",id:`enabled-${y.id}`,checked:ue.enabled??y.enabled,onChange:z=>Ae({...ue,enabled:z.target.checked}),className:"h-4 w-4 text-blue-600 focus:ring-blue-500 border-gray-300 rounded"}),a.jsx("label",{htmlFor:`enabled-${y.id}`,className:"ml-2 block text-sm text-gray-700",children:"Enabled"})]}),a.jsxs("div",{className:"flex gap-2",children:[a.jsxs("button",{onClick:()=>ah(y.id),disabled:ve,className:"inline-flex items-center gap-2 px-3 py-1.5 bg-blue-600 text-white text-sm rounded hover:bg-blue-700 disabled:opacity-50 disabled:cursor-not-allowed",children:[ve&&a.jsx(ir,{className:"h-4 w-4 animate-spin"}),ve?"Saving...":"Save"]}),a.jsx("button",{onClick:ih,disabled:ve,className:"px-3 py-1.5 bg-gray-200 text-gray-700 text-sm rounded hover:bg-gray-300 disabled:opacity-50 disabled:cursor-not-allowed",children:"Cancel"})]})]}):a.jsxs(a.Fragment,{children:[a.jsxs("div",{className:"flex items-center gap-3",children:[a.jsx("h3",{className:"font-medium",children:y.name}),a.jsxs("div",{className:`flex items-center gap-1 text-sm ${S?"text-green-600":"text-yellow-600"}`,children:[a.jsx("div",{className:`w-2 h-2 rounded-full ${S?"bg-green-600 animate-pulse":"bg-yellow-600"}`}),S?"Connected":"Not Connected"]})]}),a.jsx("p",{className:"text-sm text-muted-foreground mt-1",children:y.apiUrl}),I&&a.jsxs("p",{className:"text-xs text-muted-foreground mt-1",children:[D,": ",new Date(I).toLocaleString()]})]})}),A!==y.id&&a.jsx("div",{className:"flex items-start",children:a.jsx("button",{onClick:()=>sh(y),className:"p-2 text-gray-500 hover:text-blue-600 transition-colors",title:"Edit organization",children:a.jsx(mi,{className:"h-5 w-5"})})})]}),a.jsx("div",{className:"mt-4",children:!A&&a.jsxs(a.Fragment,{children:[S&&y.workerRegistration&&a.jsxs("div",{className:"mt-3 pt-3 border-t border-gray-100",children:[a.jsxs("div",{className:"flex items-center gap-2 mb-2",children:[a.jsx(mv,{className:"h-4 w-4 text-gray-500"}),a.jsx("span",{className:"text-sm font-medium",children:"Worker Details"})]}),a.jsxs("div",{className:"space-y-1",children:[y.workerRegistration.workerId&&a.jsxs("p",{className:"text-xs text-gray-600",children:["Worker ID: ",a.jsx("code",{className:"text-xs font-mono bg-gray-100 px-1 rounded",children:y.workerRegistration.workerId})]}),y.workerRegistration.capabilities&&y.workerRegistration.capabilities.length>0&&a.jsx("div",{className:"flex flex-wrap gap-1 mt-1",children:y.workerRegistration.capabilities.map(z=>a.jsxs("span",{className:"inline-flex items-center gap-1 px-1.5 py-0.5 text-xs bg-blue-100 text-blue-700 rounded",children:[a.jsx(Rp,{className:"h-3 w-3"}),z.replace("_"," ").toLowerCase()]},z))})]})]}),S&&a.jsxs("div",{className:"mt-3 pt-3 border-t border-gray-100",children:[a.jsxs("div",{className:"flex items-center justify-between mb-2",children:[a.jsxs("button",{onClick:()=>Gp(y.id),className:"flex items-center gap-2 hover:text-blue-600 transition-colors",children:[d.has(y.id)?a.jsx(Fr,{className:"h-4 w-4"}):a.jsx(Dr,{className:"h-4 w-4"}),a.jsx(Ap,{className:"h-4 w-4 text-gray-500"}),a.jsxs("span",{className:"text-sm font-medium",children:["Workspaces ",y.workspaceCount!==void 0&&`(${y.workspaceCount})`]})]}),a.jsx("div",{className:"flex items-center gap-2",children:a.jsxs("button",{onClick:()=>oh(y.id),className:"inline-flex items-center px-2 py-1 text-xs text-blue-600 border border-blue-200 rounded-md hover:bg-blue-50",children:[a.jsx(Vr,{className:"h-3 w-3 mr-1"}),"Manage"]})})]}),d.has(y.id)&&a.jsxs("div",{className:"mt-2 space-y-2",children:[h.has(y.id)?a.jsx("div",{className:"text-sm text-gray-500 text-center py-2",children:"Loading workspaces..."}):y.workspaces&&y.workspaces.length>0?y.workspaces.map(z=>a.jsxs("div",{className:"bg-gray-50 p-3 rounded-md",children:[a.jsxs("div",{className:"flex items-start justify-between",children:[a.jsx("div",{className:"flex-1",children:P===z.id?a.jsxs("div",{className:"space-y-2",children:[a.jsxs("div",{children:[a.jsx("label",{className:"block text-xs font-medium text-gray-700 mb-1",children:"Name"}),a.jsx("input",{type:"text",value:U.name||"",onChange:$=>ee({...U,name:$.target.value}),className:"w-full text-xs px-2 py-1 border border-gray-300 rounded focus:outline-none focus:ring-1 focus:ring-blue-500"})]}),a.jsxs("div",{children:[a.jsx("label",{className:"block text-xs font-medium text-gray-700 mb-1",children:"Path"}),a.jsx("input",{type:"text",value:U.path||"",onChange:$=>ee({...U,path:$.target.value}),className:"w-full text-xs px-2 py-1 border border-gray-300 rounded focus:outline-none focus:ring-1 focus:ring-blue-500"})]}),a.jsxs("div",{children:[a.jsx("label",{className:"block text-xs font-medium text-gray-700 mb-1",children:"Description"}),a.jsx("input",{type:"text",value:U.description||"",onChange:$=>ee({...U,description:$.target.value}),className:"w-full text-xs px-2 py-1 border border-gray-300 rounded focus:outline-none focus:ring-1 focus:ring-blue-500",placeholder:"Optional description"})]}),a.jsxs("p",{className:"text-xs text-gray-500",children:["ID: ",a.jsx("code",{className:"font-mono",children:z.id})]})]}):a.jsxs("div",{children:[a.jsxs("div",{className:"flex items-center gap-2",children:[a.jsx("h4",{className:"text-sm font-medium",children:z.name}),a.jsx("span",{className:`px-1.5 py-0.5 text-xs rounded ${z.isActive?"bg-green-100 text-green-700":"bg-gray-200 text-gray-600"}`,children:z.isActive?"Active":"Inactive"})]}),z.description&&a.jsx("p",{className:"text-xs text-gray-600 mt-1",children:z.description}),a.jsxs("div",{className:"mt-1 space-y-0.5",children:[a.jsxs("p",{className:"text-xs text-gray-500",children:["ID: ",a.jsx("code",{className:"font-mono",children:z.id})]}),a.jsxs("p",{className:"text-xs text-gray-500",children:["Path: ",a.jsx("code",{className:"font-mono",children:z.path})]}),z.projectCount!==void 0&&a.jsxs("p",{className:"text-xs text-gray-500",children:["Projects: ",z.projectCount]})]})]})}),a.jsx("div",{className:"flex items-center gap-1",children:a.jsx("button",{onClick:()=>Jp(y.id,z.id,{isActive:!z.isActive}),className:`p-1 transition-colors ${z.isActive?"text-green-500 hover:text-red-600":"text-gray-400 hover:text-green-600"}`,title:z.isActive?"Deactivate workspace":"Activate workspace",children:z.isActive?a.jsx(pv,{className:"h-3 w-3"}):a.jsx(fv,{className:"h-3 w-3"})})})]}),a.jsxs("div",{className:"mt-2 pt-2 border-t border-gray-200",children:[a.jsxs("div",{className:"flex items-center justify-between mb-1",children:[a.jsxs("button",{onClick:()=>{const $=`${y.id}-${z.id}`,H=new Set(T);H.has($)?H.delete($):H.add($),C(H)},className:"flex items-center gap-1 text-xs text-gray-600 hover:text-blue-600",children:[T.has(`${y.id}-${z.id}`)?a.jsx(Fr,{className:"h-3 w-3"}):a.jsx(Dr,{className:"h-3 w-3"}),"Services ",z.services?`(${z.services.length})`:"(0)"]}),a.jsx("button",{onClick:()=>{R({orgId:y.id,workspaceId:z.id})},className:"text-xs text-green-600 hover:text-green-700",children:a.jsx(pr,{className:"h-3 w-3"})})]}),T.has(`${y.id}-${z.id}`)&&a.jsx("div",{className:"space-y-1 ml-4",children:z.services&&z.services.length>0?z.services.map($=>a.jsx("div",{className:"bg-white p-2 rounded border",children:Y===$.id?a.jsxs("div",{className:"space-y-2",children:[a.jsxs("div",{className:"grid grid-cols-2 gap-2",children:[a.jsxs("div",{children:[a.jsx("label",{className:"block text-xs font-medium text-gray-700 mb-1",children:"Name"}),a.jsx("input",{type:"text",value:Q.name||"",onChange:H=>X({...Q,name:H.target.value}),className:"w-full text-xs px-2 py-1 border border-gray-300 rounded focus:outline-none focus:ring-1 focus:ring-blue-500"})]}),a.jsxs("div",{children:[a.jsx("label",{className:"block text-xs font-medium text-gray-700 mb-1",children:"Type"}),a.jsxs("select",{value:Q.type||"backend",onChange:H=>X({...Q,type:H.target.value}),className:"w-full text-xs px-2 py-1 border border-gray-300 rounded focus:outline-none focus:ring-1 focus:ring-blue-500",children:[a.jsx("option",{value:"backend",children:"Backend"}),a.jsx("option",{value:"frontend",children:"Frontend"}),a.jsx("option",{value:"database",children:"Database"}),a.jsx("option",{value:"cache",children:"Cache"}),a.jsx("option",{value:"queue",children:"Queue"}),a.jsx("option",{value:"api",children:"API"}),a.jsx("option",{value:"service",children:"Service"}),a.jsx("option",{value:"other",children:"Other"})]})]})]}),a.jsxs("div",{className:"grid grid-cols-2 gap-2",children:[a.jsxs("div",{children:[a.jsx("label",{className:"block text-xs font-medium text-gray-700 mb-1",children:"Technology"}),a.jsx("input",{type:"text",value:Q.technology||"",onChange:H=>X({...Q,technology:H.target.value}),className:"w-full text-xs px-2 py-1 border border-gray-300 rounded focus:outline-none focus:ring-1 focus:ring-blue-500",placeholder:"e.g., Node.js, Python"})]}),a.jsxs("div",{children:[a.jsx("label",{className:"block text-xs font-medium text-gray-700 mb-1",children:"Port"}),a.jsx("input",{type:"number",value:Q.port||"",onChange:H=>X({...Q,port:H.target.value?parseInt(H.target.value):void 0}),className:"w-full text-xs px-2 py-1 border border-gray-300 rounded focus:outline-none focus:ring-1 focus:ring-blue-500",placeholder:"3000"})]})]}),a.jsxs("div",{children:[a.jsx("label",{className:"block text-xs font-medium text-gray-700 mb-1",children:"URL"}),a.jsx("input",{type:"url",value:Q.url||"",onChange:H=>X({...Q,url:H.target.value}),className:"w-full text-xs px-2 py-1 border border-gray-300 rounded focus:outline-none focus:ring-1 focus:ring-blue-500",placeholder:"http://localhost:3000"})]}),a.jsxs("div",{children:[a.jsx("label",{className:"block text-xs font-medium text-gray-700 mb-1",children:"Description"}),a.jsx("input",{type:"text",value:Q.description||"",onChange:H=>X({...Q,description:H.target.value}),className:"w-full text-xs px-2 py-1 border border-gray-300 rounded focus:outline-none focus:ring-1 focus:ring-blue-500",placeholder:"Optional description"})]}),a.jsxs("div",{className:"flex items-center justify-end gap-1 pt-1",children:[a.jsx("button",{onClick:()=>eh(y.id,z.id,$.id),className:"px-2 py-1 text-xs bg-green-600 text-white rounded hover:bg-green-700",children:a.jsx(gi,{className:"h-3 w-3"})}),a.jsx("button",{onClick:Zp,className:"px-2 py-1 text-xs bg-gray-600 text-white rounded hover:bg-gray-700",children:a.jsx(Pn,{className:"h-3 w-3"})})]})]}):a.jsxs("div",{className:"flex items-center justify-between",children:[a.jsxs("div",{className:"flex items-center gap-2 text-xs",children:[a.jsx("span",{className:"font-medium",children:$.name}),a.jsxs("span",{className:"text-gray-500",children:["(",$.type,")"]}),$.port&&a.jsxs("span",{className:"text-gray-400",children:[":",$.port]}),$.technology&&a.jsx("span",{className:"px-1 py-0.5 bg-blue-100 text-blue-700 rounded text-xs",children:$.technology}),$.description&&a.jsxs("span",{className:"text-gray-400 italic",children:["- ",$.description]})]}),a.jsxs("div",{className:"flex items-center gap-1",children:[a.jsx("button",{onClick:()=>Xp($),className:"p-1 text-gray-500 hover:text-orange-600 transition-colors",title:"Edit service",children:a.jsx(mi,{className:"h-3 w-3"})}),a.jsx("button",{onClick:()=>th(y.id,z.id,$.id,$.name),className:"p-1 text-gray-500 hover:text-red-600 transition-colors",title:"Remove service",children:a.jsx(ss,{className:"h-3 w-3"})}),a.jsx("button",{onClick:()=>rh(y.id,z.id,$.id,!$.isActive),className:`px-1.5 py-0.5 rounded text-xs ${$.isActive?"bg-green-100 text-green-700":"bg-gray-100 text-gray-600"}`,children:$.isActive?"Active":"Inactive"})]})]})},$.id)):a.jsx("div",{className:"text-xs text-gray-500",children:"No services configured"})})]}),z.projects&&z.projects.length>0&&a.jsxs("div",{className:"mt-2 pt-2 border-t border-gray-200",children:[a.jsx("div",{className:"flex items-center justify-between mb-1",children:a.jsxs("button",{onClick:()=>{const $=`proj-${y.id}-${z.id}`,H=new Set(ha);H.has($)?H.delete($):H.add($),Wp(H)},className:"flex items-center gap-1 text-xs text-gray-600 hover:text-purple-600",children:[ha.has(`proj-${y.id}-${z.id}`)?a.jsx(Fr,{className:"h-3 w-3"}):a.jsx(Dr,{className:"h-3 w-3"}),a.jsx(rs,{className:"h-3 w-3 text-purple-500"}),"Projects (",z.projects.length,")"]})}),ha.has(`proj-${y.id}-${z.id}`)&&a.jsx("div",{className:"space-y-1 ml-4",children:z.projects.map($=>{const H=Kp($.id),Fe=Bp===$.id;return a.jsxs("div",{className:`bg-white p-2 rounded border ${H?"border-purple-300":"border-gray-200"}`,children:[a.jsxs("div",{className:"flex items-center justify-between",children:[a.jsxs("div",{className:"flex items-center gap-2 text-xs",children:[a.jsx(sv,{className:"h-3 w-3 text-gray-400"}),a.jsx("span",{className:"font-medium",children:$.name}),$.stage&&a.jsx("span",{className:"px-1 py-0.5 bg-gray-100 text-gray-600 rounded text-xs",children:$.stage}),H&&a.jsx("span",{className:"px-1 py-0.5 bg-purple-100 text-purple-700 rounded text-xs",children:"Mapped"})]}),a.jsxs("div",{className:"flex items-center gap-1",children:[H&&!Fe&&a.jsx("button",{onClick:()=>Vp(y.id,$.id),className:"p-1 text-gray-500 hover:text-red-600 transition-colors",title:"Remove mapping",children:a.jsx(ss,{className:"h-3 w-3"})}),!Fe&&a.jsx("button",{onClick:()=>{ma($.id),zs((H==null?void 0:H.localPath)||"")},className:"p-1 text-gray-500 hover:text-purple-600 transition-colors",title:H?"Edit path":"Set local path",children:a.jsx(mi,{className:"h-3 w-3"})})]})]}),H&&!Fe&&a.jsx("div",{className:"mt-1 text-xs text-purple-600",children:a.jsx("code",{className:"bg-purple-50 px-1 rounded",children:H.localPath})}),Fe&&a.jsxs("div",{className:"mt-2 flex gap-1",children:[a.jsx("input",{type:"text",value:ga,onChange:Wt=>zs(Wt.target.value),placeholder:"/path/to/local/project",className:"flex-1 text-xs px-2 py-1 border border-gray-300 rounded focus:outline-none focus:ring-1 focus:ring-purple-500"}),a.jsx("button",{onClick:()=>Qp(y.id,$.id,$.name),disabled:uu,className:"px-2 py-1 text-xs bg-purple-600 text-white rounded hover:bg-purple-700 disabled:opacity-50",children:uu?a.jsx(ir,{className:"h-3 w-3 animate-spin"}):a.jsx(gi,{className:"h-3 w-3"})}),a.jsx("button",{onClick:()=>{ma(null),zs("")},className:"px-2 py-1 text-xs bg-gray-200 text-gray-700 rounded hover:bg-gray-300",children:a.jsx(Pn,{className:"h-3 w-3"})})]})]},$.id)})})]})]},z.id)):a.jsx("div",{className:"text-sm text-gray-500 text-center py-2",children:'No workspaces configured. Click "Manage" to import from Task Shepherd.'}),(j==null?void 0:j.orgId)===y.id&&((oe=y.workspaces)==null?void 0:oe.some(z=>z.id===j.workspaceId))&&a.jsxs("div",{className:"bg-green-50 p-3 rounded-md border border-green-200",children:[a.jsx("h5",{className:"text-sm font-medium mb-2",children:"Add New Service"}),a.jsxs("form",{onSubmit:z=>nh(z,j.orgId,j.workspaceId),className:"space-y-2",children:[a.jsxs("div",{className:"grid grid-cols-2 gap-2",children:[a.jsx("input",{type:"text",placeholder:"Service Name",value:M.name,onChange:z=>K({...M,name:z.target.value}),className:"text-xs px-2 py-1 border border-gray-300 rounded focus:outline-none focus:ring-1 focus:ring-green-500",required:!0}),a.jsxs("select",{value:M.type,onChange:z=>K({...M,type:z.target.value}),className:"text-xs px-2 py-1 border border-gray-300 rounded focus:outline-none focus:ring-1 focus:ring-green-500",required:!0,children:[a.jsx("option",{value:"backend",children:"Backend"}),a.jsx("option",{value:"frontend",children:"Frontend"}),a.jsx("option",{value:"database",children:"Database"}),a.jsx("option",{value:"cache",children:"Cache"}),a.jsx("option",{value:"queue",children:"Queue"}),a.jsx("option",{value:"api",children:"API"}),a.jsx("option",{value:"service",children:"Service"}),a.jsx("option",{value:"other",children:"Other"})]})]}),a.jsxs("div",{className:"grid grid-cols-3 gap-2",children:[a.jsx("input",{type:"number",placeholder:"Port",value:M.port,onChange:z=>K({...M,port:z.target.value}),className:"text-xs px-2 py-1 border border-gray-300 rounded focus:outline-none focus:ring-1 focus:ring-green-500"}),a.jsx("input",{type:"text",placeholder:"Technology (e.g., Node.js)",value:M.technology,onChange:z=>K({...M,technology:z.target.value}),className:"text-xs px-2 py-1 border border-gray-300 rounded focus:outline-none focus:ring-1 focus:ring-green-500"}),a.jsx("input",{type:"url",placeholder:"URL (optional)",value:M.url,onChange:z=>K({...M,url:z.target.value}),className:"text-xs px-2 py-1 border border-gray-300 rounded focus:outline-none focus:ring-1 focus:ring-green-500"})]}),a.jsx("input",{type:"text",placeholder:"Description (optional)",value:M.description,onChange:z=>K({...M,description:z.target.value}),className:"w-full text-xs px-2 py-1 border border-gray-300 rounded focus:outline-none focus:ring-1 focus:ring-green-500"}),a.jsxs("div",{className:"flex justify-end gap-1",children:[a.jsx("button",{type:"button",onClick:()=>{R(null),K({name:"",type:"backend",port:"",url:"",technology:"",description:""})},className:"px-2 py-1 text-xs text-gray-600 border border-gray-300 rounded hover:bg-gray-50",children:"Cancel"}),a.jsx("button",{type:"submit",className:"px-2 py-1 text-xs bg-green-600 text-white rounded hover:bg-green-700",children:"Add Service"})]})]})]}),x===y.id&&a.jsxs("div",{className:"bg-blue-50 p-3 rounded-md border border-blue-200",children:[a.jsx("h5",{className:"text-sm font-medium mb-2",children:"Add New Workspace"}),a.jsxs("form",{onSubmit:z=>Yp(z,y.id),className:"space-y-2",children:[a.jsxs("div",{className:"grid grid-cols-2 gap-2",children:[a.jsx("input",{type:"text",placeholder:"Workspace Name",value:b.name,onChange:z=>E({...b,name:z.target.value}),className:"text-xs px-2 py-1 border border-gray-300 rounded focus:outline-none focus:ring-1 focus:ring-blue-500",required:!0}),a.jsx("input",{type:"text",placeholder:"Workspace ID",value:b.id,onChange:z=>E({...b,id:z.target.value}),className:"text-xs px-2 py-1 border border-gray-300 rounded focus:outline-none focus:ring-1 focus:ring-blue-500",required:!0})]}),a.jsx("input",{type:"text",placeholder:"Path (e.g., /home/user/projects/workspace)",value:b.path,onChange:z=>E({...b,path:z.target.value}),className:"w-full text-xs px-2 py-1 border border-gray-300 rounded focus:outline-none focus:ring-1 focus:ring-blue-500",required:!0}),a.jsx("input",{type:"text",placeholder:"Description (optional)",value:b.description,onChange:z=>E({...b,description:z.target.value}),className:"w-full text-xs px-2 py-1 border border-gray-300 rounded focus:outline-none focus:ring-1 focus:ring-blue-500"}),a.jsxs("div",{className:"flex justify-end gap-1",children:[a.jsx("button",{type:"button",onClick:()=>{w(null),E({name:"",id:"",path:"",description:""})},className:"px-2 py-1 text-xs text-gray-600 border border-gray-300 rounded hover:bg-gray-50",children:"Cancel"}),a.jsx("button",{type:"submit",className:"px-2 py-1 text-xs bg-blue-600 text-white rounded hover:bg-blue-700",children:"Add Workspace"})]})]})]})]})]})]})}),a.jsx("div",{className:"flex items-center gap-2 mt-4",children:a.jsxs("button",{onClick:()=>ch(y.id),className:"inline-flex items-center px-3 py-1 text-sm text-red-600 border border-red-200 rounded-md hover:bg-red-50",children:[a.jsx(ss,{className:"h-3 w-3 mr-1"}),"Delete"]})})]},y.id)})}),k&&a.jsx("div",{className:"fixed inset-0 bg-black bg-opacity-50 flex items-center justify-center p-4 z-50",children:a.jsx("div",{className:"bg-white rounded-lg shadow-xl max-w-6xl w-full max-h-[90vh] overflow-hidden",children:a.jsx(ex,{organizationId:k,onComplete:y=>{var I;if(e){const D=e.organizations.map(W=>{if(W.id===k){const Z=[...W.workspaces||[],y];return{...W,workspaces:Z,workspaceCount:Z.length}}return W});t({...e,organizations:D})}m(null);const S=((I=y.services)==null?void 0:I.length)||0;J("success","Workspace Created",`Successfully created workspace "${y.name}" with ${S} service(s) using wizard`)},onCancel:()=>{m(null)}})})}),f&&a.jsx(tx,{organizationId:f.orgId,workspace:f.workspace,onClose:()=>{g(null)},onApplyChanges:async y=>{console.log("🔧 Applying workspace analysis changes:",y);try{const S=await fetch(`/api/organizations/${f.orgId}/workspaces/${f.workspace.id}/apply-improvements`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({improvements:y})}),I=await S.json();if(S.ok&&I.success)J("success","Changes Applied",`Applied ${y.length} improvement(s) to workspace "${f.workspace.name}"`),await jn();else throw new Error(I.error||"Failed to apply changes")}catch(S){console.error("Failed to apply workspace changes:",S),J("error","Failed to Apply Changes",S instanceof Error?S.message:"Failed to apply workspace improvements")}}}),a.jsxs("div",{className:"space-y-4",children:[a.jsxs("div",{className:"rounded-lg border bg-green-50 p-6",children:[a.jsx("h3",{className:"text-lg font-medium mb-4",children:"Getting Your Task Shepherd API Information"}),a.jsxs("div",{className:"space-y-3 text-sm text-green-900",children:[a.jsxs("p",{children:[a.jsx("strong",{children:"Step 1:"})," Open your Task Shepherd frontend in a browser"]}),a.jsxs("p",{children:[a.jsx("strong",{children:"Step 2:"})," Copy the URL up to ",a.jsx("code",{children:"/api"})]}),a.jsxs("div",{className:"bg-green-100 p-3 rounded-md font-mono text-xs",children:[a.jsx("p",{children:a.jsx("strong",{children:"Example:"})}),a.jsxs("p",{children:["• Frontend URL: ",a.jsx("code",{children:"https://myorg.taskshepherd.com"})]}),a.jsxs("p",{children:["• API Base Path: ",a.jsx("code",{children:"https://myorg.taskshepherd.com/api"})]})]}),a.jsxs("p",{children:[a.jsx("strong",{children:"Step 3:"})," Generate an ",a.jsx("strong",{children:"Agent API key"})," from Organization Settings → API Keys → Create Agent Key"]})]})]}),kt&&a.jsx("div",{className:"fixed inset-0 bg-black bg-opacity-50 flex items-center justify-center z-50",children:a.jsxs("div",{className:"bg-white rounded-lg p-6 max-w-4xl w-full max-h-[90vh] overflow-y-auto m-4",children:[a.jsxs("div",{className:"flex justify-between items-center mb-4",children:[a.jsx("h2",{className:"text-xl font-semibold",children:"Manage Workspaces"}),a.jsx("button",{onClick:()=>Be(null),className:"text-gray-500 hover:text-gray-700",children:a.jsx(Pn,{className:"h-5 w-5"})})]}),ht?a.jsxs("div",{className:"flex items-center justify-center py-12",children:[a.jsx(ir,{className:"h-8 w-8 animate-spin text-blue-600"}),a.jsx("span",{className:"ml-2 text-gray-600",children:"Loading available workspaces..."})]}):a.jsxs("div",{className:"space-y-4",children:[a.jsx("p",{className:"text-sm text-gray-600",children:"Select workspaces to sync from Task Shepherd and configure local paths for each."}),be.length===0?a.jsx("div",{className:"text-center py-8 text-gray-500",children:"No workspaces available in this organization"}):a.jsxs("div",{className:"space-y-4",children:[be.filter(y=>y.isActive!==!1).length>0&&a.jsx("div",{className:"space-y-2",children:be.filter(y=>y.isActive!==!1).map(y=>a.jsx("div",{className:`border rounded-lg p-4 ${fe.has(y.id)?"border-blue-500 bg-blue-50":"border-gray-200"}`,children:a.jsxs("div",{className:"flex items-start gap-3",children:[a.jsx("input",{type:"checkbox",checked:fe.has(y.id),onChange:S=>{const I=new Set(fe);S.target.checked?I.add(y.id):I.delete(y.id),V(I)},className:"mt-1"}),a.jsxs("div",{className:"flex-1",children:[a.jsxs("div",{className:"flex items-center justify-between mb-2",children:[a.jsxs("div",{children:[a.jsx("h3",{className:"font-medium",children:y.name}),y.description&&a.jsx("p",{className:"text-sm text-gray-600",children:y.description})]}),y.syncedLocally&&a.jsx("span",{className:"text-xs px-2 py-1 bg-green-100 text-green-700 rounded",children:"Already Synced"})]}),a.jsxs("div",{className:"mt-2",children:[a.jsx("label",{className:"block text-sm font-medium text-gray-700 mb-1",children:"Local Path"}),a.jsx("input",{type:"text",value:ce[y.id]||"",onChange:S=>{Te({...ce,[y.id]:S.target.value})},placeholder:y.path||"Enter local directory path",className:"w-full px-3 py-2 border border-gray-300 rounded-md focus:outline-none focus:ring-1 focus:ring-blue-500 text-sm",disabled:!fe.has(y.id)}),a.jsxs("p",{className:"text-xs text-gray-500 mt-1",children:["Suggested path: ",y.path||"Not specified"]})]}),y.services&&y.services.length>0&&a.jsxs("div",{className:"mt-3 border-t pt-3",children:[a.jsxs("button",{type:"button",onClick:()=>{const S=new Set(Bn);S.has(y.id)?S.delete(y.id):S.add(y.id),va(S)},className:"flex items-center gap-2 text-sm font-medium text-gray-700 hover:text-gray-900",disabled:!fe.has(y.id),children:[Bn.has(y.id)?a.jsx(Fr,{className:"h-4 w-4"}):a.jsx(Dr,{className:"h-4 w-4"}),a.jsx(Vr,{className:"h-4 w-4"}),y.services.length," Service",y.services.length!==1?"s":""]}),Bn.has(y.id)&&a.jsx("div",{className:"mt-2 space-y-2 pl-6",children:y.services.map(S=>{const I=`${y.id}:${S.id}`;return a.jsxs("div",{className:"border rounded p-2 bg-gray-50",children:[a.jsxs("div",{className:"flex items-start justify-between mb-1",children:[a.jsxs("div",{children:[a.jsx("span",{className:"font-medium text-sm",children:S.name}),S.technology&&a.jsx("span",{className:"ml-2 text-xs px-1.5 py-0.5 bg-purple-100 text-purple-700 rounded",children:S.technology})]}),wn[I]&&a.jsx(rs,{className:"h-3 w-3 text-green-500"})]}),S.description&&a.jsx("p",{className:"text-xs text-gray-500 mb-2",children:S.description}),a.jsx("input",{type:"text",value:wn[I]||"",onChange:D=>{ya({...wn,[I]:D.target.value})},placeholder:"Service local path (optional, inherits from workspace)",className:"w-full px-2 py-1 border border-gray-300 rounded text-xs focus:outline-none focus:ring-1 focus:ring-blue-500",disabled:!fe.has(y.id)}),a.jsx("p",{className:"text-xs text-gray-400 mt-1",children:"Leave empty to use workspace path"})]},S.id)})})]}),(!y.services||y.services.length===0)&&a.jsx("p",{className:"text-sm text-gray-500 mt-2 italic",children:"No services defined"})]})]})},y.id))}),be.filter(y=>y.isActive===!1).length>0&&a.jsxs("div",{className:"space-y-2",children:[a.jsx("h4",{className:"text-sm font-medium text-gray-500",children:"Inactive Workspaces"}),be.filter(y=>y.isActive===!1).map(y=>a.jsx("div",{className:`border rounded-lg p-4 opacity-60 ${fe.has(y.id)?"border-blue-500 bg-blue-50":"border-gray-200"}`,children:a.jsxs("div",{className:"flex items-start gap-3",children:[a.jsx("input",{type:"checkbox",checked:fe.has(y.id),onChange:S=>{const I=new Set(fe);S.target.checked?I.add(y.id):I.delete(y.id),V(I)},className:"mt-1"}),a.jsxs("div",{className:"flex-1",children:[a.jsx("div",{className:"flex items-center justify-between mb-2",children:a.jsxs("div",{children:[a.jsxs("h3",{className:"font-medium flex items-center gap-2",children:[y.name,a.jsx("span",{className:"text-xs px-2 py-1 bg-gray-100 text-gray-600 rounded",children:"Inactive"})]}),y.description&&a.jsx("p",{className:"text-sm text-gray-600",children:y.description})]})}),a.jsxs("div",{className:"mt-2",children:[a.jsx("label",{className:"block text-sm font-medium text-gray-700 mb-1",children:"Local Path"}),a.jsx("input",{type:"text",value:ce[y.id]||"",onChange:S=>{Te({...ce,[y.id]:S.target.value})},placeholder:y.path||"Enter local directory path",className:"w-full px-3 py-2 border border-gray-300 rounded-md focus:outline-none focus:ring-1 focus:ring-blue-500 text-sm",disabled:!fe.has(y.id)}),a.jsxs("p",{className:"text-xs text-gray-500 mt-1",children:["Suggested path: ",y.path||"Not specified"]})]}),y.services&&y.services.length>0&&a.jsxs("div",{className:"mt-3 border-t pt-3",children:[a.jsxs("button",{type:"button",onClick:()=>{const S=new Set(Bn);S.has(y.id)?S.delete(y.id):S.add(y.id),va(S)},className:"flex items-center gap-2 text-sm font-medium text-gray-700 hover:text-gray-900",disabled:!fe.has(y.id),children:[Bn.has(y.id)?a.jsx(Fr,{className:"h-4 w-4"}):a.jsx(Dr,{className:"h-4 w-4"}),a.jsx(Vr,{className:"h-4 w-4"}),y.services.length," Service",y.services.length!==1?"s":""]}),Bn.has(y.id)&&a.jsx("div",{className:"mt-2 space-y-2 pl-6",children:y.services.map(S=>{const I=`${y.id}:${S.id}`;return a.jsxs("div",{className:"border rounded p-2 bg-gray-50",children:[a.jsxs("div",{className:"flex items-start justify-between mb-1",children:[a.jsxs("div",{children:[a.jsx("span",{className:"font-medium text-sm",children:S.name}),S.technology&&a.jsx("span",{className:"ml-2 text-xs px-1.5 py-0.5 bg-purple-100 text-purple-700 rounded",children:S.technology})]}),wn[I]&&a.jsx(rs,{className:"h-3 w-3 text-green-500"})]}),S.description&&a.jsx("p",{className:"text-xs text-gray-500 mb-2",children:S.description}),a.jsx("input",{type:"text",value:wn[I]||"",onChange:D=>{ya({...wn,[I]:D.target.value})},placeholder:"Service local path (optional, inherits from workspace)",className:"w-full px-2 py-1 border border-gray-300 rounded text-xs focus:outline-none focus:ring-1 focus:ring-blue-500",disabled:!fe.has(y.id)}),a.jsx("p",{className:"text-xs text-gray-400 mt-1",children:"Leave empty to use workspace path"})]},S.id)})})]}),(!y.services||y.services.length===0)&&a.jsx("p",{className:"text-sm text-gray-500 mt-2 italic",children:"No services defined"})]})]})},y.id))]})]}),a.jsxs("div",{className:"flex justify-end gap-2 mt-6 pt-4 border-t",children:[a.jsx("button",{onClick:()=>Be(null),className:"px-4 py-2 text-gray-600 hover:text-gray-800",disabled:Wn,children:"Cancel"}),a.jsx("button",{onClick:()=>lh(kt),disabled:Wn,className:"px-4 py-2 bg-blue-600 text-white rounded-md hover:bg-blue-700 disabled:opacity-50 disabled:cursor-not-allowed flex items-center gap-2",children:Wn?a.jsxs(a.Fragment,{children:[a.jsx(ir,{className:"h-4 w-4 animate-spin"}),"Saving..."]}):a.jsxs(a.Fragment,{children:[a.jsx(gi,{className:"h-4 w-4"}),"Save"]})})]})]})]})}),a.jsxs("div",{className:"rounded-lg border bg-blue-50 p-6",children:[a.jsx("h3",{className:"text-lg font-medium mb-4",children:"About Organization & Workspace Management"}),a.jsxs("div",{className:"space-y-2 text-sm text-blue-900",children:[a.jsxs("p",{children:["• ",a.jsx("strong",{children:"Organizations"})," represent different Task Shepherd instances you want to connect to"]}),a.jsxs("p",{children:["• Each organization needs an ",a.jsx("strong",{children:"Agent API key"})," (not a user API key) generated from the Task Shepherd organization settings"]}),a.jsxs("p",{children:["• ",a.jsx("strong",{children:"Workspaces"})," are collections of related projects within an organization"]}),a.jsxs("p",{children:["• Click ",a.jsx("strong",{children:"Manage"})," to select and sync workspaces from Task Shepherd with custom local paths"]}),a.jsx("p",{children:"• You can activate/deactivate workspaces to control which ones the agent works with"}),a.jsx("p",{children:"• The agent will automatically sync workspaces and accept work assignments from configured organizations"})]})]})]})]})]})}function rx(){const[e,t]=N.useState([]),[n,r]=N.useState(!0),[s,i]=N.useState(null),[o,l]=N.useState(!1),[u,c]=N.useState({organizationId:"",workspaceId:"",serviceId:"",localPath:"",serviceName:"",technology:"",notes:""}),[d,p]=N.useState(!1),h=async()=>{r(!0),i(null);try{const m=await fetch("/api/service-mappings");if(!m.ok)throw new Error("Failed to fetch service mappings");const f=await m.json();if(f.success)t(f.mappings);else throw new Error("Failed to fetch mappings")}catch(m){i(m instanceof Error?m.message:"Failed to fetch mappings")}finally{r(!1)}};N.useEffect(()=>{h()},[]);const v=async m=>{m.preventDefault(),p(!0),i(null);try{const f=await fetch("/api/service-mappings",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(u)}),g=await f.json();if(!f.ok||!g.success)throw new Error(g.error||"Failed to save mapping");await h(),l(!1),c({organizationId:"",workspaceId:"",serviceId:"",localPath:"",serviceName:"",technology:"",notes:""})}catch(f){i(f instanceof Error?f.message:"Failed to save mapping")}finally{p(!1)}},x=async m=>{if(confirm(`Delete mapping for ${m.serviceName||m.serviceId}?`))try{const f=await fetch(`/api/service-mappings/${encodeURIComponent(m.organizationId)}/${encodeURIComponent(m.workspaceId)}/${encodeURIComponent(m.serviceId)}`,{method:"DELETE"}),g=await f.json();if(!f.ok||!g.success)throw new Error(g.error||"Failed to delete mapping");await h()}catch(f){i(f instanceof Error?f.message:"Failed to delete mapping")}},w=m=>new Date(m).toLocaleDateString("en-US",{year:"numeric",month:"short",day:"numeric",hour:"2-digit",minute:"2-digit"}),k=e.reduce((m,f)=>(m[f.organizationId]||(m[f.organizationId]=[]),m[f.organizationId].push(f),m),{});return a.jsxs(a.Fragment,{children:[a.jsx(hn,{children:a.jsx("title",{children:"Service Mappings - AI Agent Service"})}),a.jsxs("div",{className:"space-y-6",children:[a.jsxs("div",{className:"flex items-center justify-between",children:[a.jsxs("div",{children:[a.jsx("h2",{className:"text-3xl font-bold tracking-tight",children:"Service Mappings"}),a.jsx("p",{className:"text-muted-foreground",children:"Map backend services to local filesystem paths for multi-repo workspaces"})]}),a.jsxs("div",{className:"flex gap-2",children:[a.jsxs("button",{onClick:h,disabled:n,className:"inline-flex items-center gap-2 px-4 py-2 rounded-md border bg-white hover:bg-gray-50 disabled:opacity-50",children:[a.jsx(en,{className:`h-4 w-4 ${n?"animate-spin":""}`}),"Refresh"]}),a.jsxs("button",{onClick:()=>l(!0),className:"inline-flex items-center gap-2 px-4 py-2 rounded-md bg-blue-600 text-white hover:bg-blue-700",children:[a.jsx(pr,{className:"h-4 w-4"}),"Add Mapping"]})]})]}),s&&a.jsx("div",{className:"p-4 bg-red-50 border border-red-200 rounded-lg text-red-700",children:s}),o&&a.jsxs("div",{className:"rounded-lg border bg-card p-6",children:[a.jsx("h3",{className:"text-lg font-medium mb-4",children:"Add Service Mapping"}),a.jsxs("form",{onSubmit:v,className:"space-y-4",children:[a.jsxs("div",{className:"grid gap-4 md:grid-cols-2",children:[a.jsxs("div",{children:[a.jsx("label",{className:"block text-sm font-medium mb-1",children:"Organization ID *"}),a.jsx("input",{type:"text",value:u.organizationId,onChange:m=>c({...u,organizationId:m.target.value}),required:!0,className:"w-full px-3 py-2 border rounded-md",placeholder:"org-..."})]}),a.jsxs("div",{children:[a.jsx("label",{className:"block text-sm font-medium mb-1",children:"Workspace ID *"}),a.jsx("input",{type:"text",value:u.workspaceId,onChange:m=>c({...u,workspaceId:m.target.value}),required:!0,className:"w-full px-3 py-2 border rounded-md",placeholder:"workspace-..."})]}),a.jsxs("div",{children:[a.jsx("label",{className:"block text-sm font-medium mb-1",children:"Service ID *"}),a.jsx("input",{type:"text",value:u.serviceId,onChange:m=>c({...u,serviceId:m.target.value}),required:!0,className:"w-full px-3 py-2 border rounded-md",placeholder:"service-..."})]}),a.jsxs("div",{children:[a.jsx("label",{className:"block text-sm font-medium mb-1",children:"Local Path *"}),a.jsx("input",{type:"text",value:u.localPath,onChange:m=>c({...u,localPath:m.target.value}),required:!0,className:"w-full px-3 py-2 border rounded-md",placeholder:"/path/to/service"})]}),a.jsxs("div",{children:[a.jsx("label",{className:"block text-sm font-medium mb-1",children:"Service Name"}),a.jsx("input",{type:"text",value:u.serviceName,onChange:m=>c({...u,serviceName:m.target.value}),className:"w-full px-3 py-2 border rounded-md",placeholder:"My Service"})]}),a.jsxs("div",{children:[a.jsx("label",{className:"block text-sm font-medium mb-1",children:"Technology"}),a.jsxs("select",{value:u.technology,onChange:m=>c({...u,technology:m.target.value}),className:"w-full px-3 py-2 border rounded-md",children:[a.jsx("option",{value:"",children:"Select..."}),a.jsx("option",{value:"NODEJS",children:"Node.js"}),a.jsx("option",{value:"REACT",children:"React"}),a.jsx("option",{value:"PYTHON",children:"Python"}),a.jsx("option",{value:"GO",children:"Go"}),a.jsx("option",{value:"RUST",children:"Rust"}),a.jsx("option",{value:"JAVA",children:"Java"}),a.jsx("option",{value:"OTHER",children:"Other"})]})]})]}),a.jsxs("div",{children:[a.jsx("label",{className:"block text-sm font-medium mb-1",children:"Notes"}),a.jsx("textarea",{value:u.notes,onChange:m=>c({...u,notes:m.target.value}),className:"w-full px-3 py-2 border rounded-md",rows:2,placeholder:"Optional notes about this mapping..."})]}),a.jsxs("div",{className:"flex gap-2 justify-end",children:[a.jsx("button",{type:"button",onClick:()=>l(!1),className:"px-4 py-2 rounded-md border hover:bg-gray-50",children:"Cancel"}),a.jsx("button",{type:"submit",disabled:d,className:"px-4 py-2 rounded-md bg-blue-600 text-white hover:bg-blue-700 disabled:opacity-50",children:d?"Saving...":"Save Mapping"})]})]})]}),n?a.jsx("div",{className:"text-center py-12 text-muted-foreground",children:"Loading mappings..."}):e.length===0?a.jsxs("div",{className:"rounded-lg border bg-card p-12 text-center",children:[a.jsx(rs,{className:"h-12 w-12 mx-auto text-muted-foreground mb-4"}),a.jsx("h3",{className:"text-lg font-medium mb-2",children:"No Service Mappings"}),a.jsx("p",{className:"text-muted-foreground mb-4",children:"Service mappings allow the agent to find local paths for multi-repo workspace services."}),a.jsxs("button",{onClick:()=>l(!0),className:"inline-flex items-center gap-2 px-4 py-2 rounded-md bg-blue-600 text-white hover:bg-blue-700",children:[a.jsx(pr,{className:"h-4 w-4"}),"Add First Mapping"]})]}):a.jsx("div",{className:"space-y-6",children:Object.entries(k).map(([m,f])=>a.jsxs("div",{className:"rounded-lg border bg-card",children:[a.jsx("div",{className:"px-6 py-4 border-b bg-gray-50 rounded-t-lg",children:a.jsxs("div",{className:"flex items-center gap-2",children:[a.jsx(rv,{className:"h-5 w-5 text-blue-600"}),a.jsxs("h3",{className:"font-medium",children:["Organization: ",m]}),a.jsxs("span",{className:"text-sm text-muted-foreground",children:["(",f.length," mapping",f.length!==1?"s":"",")"]})]})}),a.jsx("div",{className:"divide-y",children:f.map(g=>a.jsx("div",{className:"px-6 py-4 hover:bg-gray-50",children:a.jsxs("div",{className:"flex items-start justify-between",children:[a.jsxs("div",{className:"space-y-2",children:[a.jsxs("div",{className:"flex items-center gap-2",children:[a.jsx(cv,{className:"h-4 w-4 text-purple-600"}),a.jsx("span",{className:"font-medium",children:g.serviceName||g.serviceId}),g.technology&&a.jsx("span",{className:"px-2 py-0.5 text-xs bg-blue-100 text-blue-700 rounded",children:g.technology})]}),a.jsxs("div",{className:"flex items-center gap-4 text-sm text-muted-foreground",children:[a.jsxs("div",{className:"flex items-center gap-1",children:[a.jsx(av,{className:"h-4 w-4"}),a.jsxs("span",{children:["Workspace: ",g.workspaceId.slice(0,8),"..."]})]}),a.jsxs("div",{className:"flex items-center gap-1",children:[a.jsx(Ap,{className:"h-4 w-4"}),a.jsx("span",{className:"font-mono",children:g.localPath})]})]}),g.notes&&a.jsx("p",{className:"text-sm text-muted-foreground italic",children:g.notes}),a.jsxs("p",{className:"text-xs text-muted-foreground",children:["Mapped: ",w(g.mappedAt)]})]}),a.jsx("button",{onClick:()=>x(g),className:"p-2 text-red-600 hover:bg-red-50 rounded",title:"Delete mapping",children:a.jsx(ss,{className:"h-4 w-4"})})]})},`${g.organizationId}:${g.workspaceId}:${g.serviceId}`))})]},m))}),a.jsxs("div",{className:"rounded-lg border bg-blue-50 p-6",children:[a.jsx("h3",{className:"text-lg font-medium text-blue-900 mb-2",children:"About Service Mappings"}),a.jsx("p",{className:"text-blue-800 text-sm mb-4",children:"Service mappings are used by the agent to locate local source code for multi-repo workspaces. When processing work, the agent checks service mappings first, then falls back to workspace mappings."}),a.jsxs("ul",{className:"text-sm text-blue-700 space-y-1 list-disc list-inside",children:[a.jsx("li",{children:"Each mapping links a backend service ID to a local filesystem path"}),a.jsx("li",{children:"Service mappings take priority over workspace mappings"}),a.jsx("li",{children:"Use for multi-repo workspaces where services are in different directories"}),a.jsx("li",{children:"The agent can only process work for mapped services"})]})]})]})]})}function sx(){return a.jsxs(a.Fragment,{children:[a.jsx(hn,{children:a.jsx("title",{children:"404 - Page Not Found"})}),a.jsx("div",{className:"flex flex-col items-center justify-center min-h-[400px] text-center",children:a.jsxs("div",{className:"space-y-4",children:[a.jsx("h1",{className:"text-4xl font-bold",children:"404"}),a.jsx("h2",{className:"text-xl text-muted-foreground",children:"Page Not Found"}),a.jsx("p",{className:"text-muted-foreground max-w-md",children:"The page you're looking for doesn't exist or has been moved."}),a.jsxs(xp,{to:"/",className:"inline-flex items-center space-x-2 rounded-lg bg-primary px-4 py-2 text-primary-foreground hover:bg-primary/90",children:[a.jsx(Mp,{className:"h-4 w-4"}),a.jsx("span",{children:"Go Home"})]})]})})]})}function ix(){return a.jsxs(a.Fragment,{children:[a.jsxs(hn,{children:[a.jsx("title",{children:"AI Agent Service Dashboard"}),a.jsx("meta",{name:"description",content:"Analytics dashboard for AI agent service monitoring"})]}),a.jsx(Kv,{children:a.jsxs(O0,{children:[a.jsx(Qr,{path:"/",element:a.jsx(Zv,{})}),a.jsx(Qr,{path:"/organizations",element:a.jsx(nx,{})}),a.jsx(Qr,{path:"/service-mappings",element:a.jsx(rx,{})}),a.jsx(Qr,{path:"*",element:a.jsx(sx,{})})]})})]})}const ax=new sy({defaultOptions:{queries:{retry:1,refetchOnWindowFocus:!1,staleTime:1e3*60*5}}});to.createRoot(document.getElementById("root")).render(a.jsx(_.StrictMode,{children:a.jsx(sr,{children:a.jsx(oy,{client:ax,children:a.jsxs(L0,{children:[a.jsx(ix,{}),a.jsx(Xy,{position:"top-right"})]})})})}));
69
+ //# sourceMappingURL=index-e2c560a2.js.map