@openparachute/vault 0.6.0-rc.1 → 0.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.parachute/module.json +14 -3
- package/README.md +7 -7
- package/core/src/core.test.ts +279 -26
- package/core/src/expand-visibility.test.ts +102 -0
- package/core/src/expand.ts +31 -3
- package/core/src/indexed-fields.ts +1 -1
- package/core/src/link-count.test.ts +301 -0
- package/core/src/links.ts +97 -2
- package/core/src/mcp.ts +201 -33
- package/core/src/notes.ts +44 -8
- package/core/src/obsidian-alignment.test.ts +375 -0
- package/core/src/obsidian.ts +234 -14
- package/core/src/portable-md.test.ts +40 -0
- package/core/src/portable-md.ts +142 -16
- package/core/src/schema.ts +58 -11
- package/core/src/store.ts +69 -22
- package/core/src/tag-expand-axis.test.ts +301 -0
- package/core/src/tag-hierarchy.ts +80 -0
- package/core/src/tag-schemas.ts +61 -46
- package/core/src/triggers-store.test.ts +100 -0
- package/core/src/triggers-store.ts +165 -0
- package/core/src/types.ts +68 -4
- package/core/src/vault-projection.ts +20 -0
- package/core/src/wikilinks.ts +2 -2
- package/package.json +2 -3
- package/src/admin-spa.test.ts +100 -10
- package/src/admin-spa.ts +48 -3
- package/src/auth-hub-jwt.test.ts +8 -1
- package/src/auth-status.ts +2 -2
- package/src/auth.test.ts +39 -3
- package/src/auth.ts +31 -2
- package/src/auto-transcribe.test.ts +51 -0
- package/src/auto-transcribe.ts +24 -6
- package/src/autostart.test.ts +75 -0
- package/src/autostart.ts +84 -0
- package/src/cli.ts +434 -140
- package/src/config.test.ts +109 -0
- package/src/config.ts +157 -10
- package/src/export-watch.test.ts +23 -0
- package/src/export-watch.ts +14 -0
- package/src/git-preflight.test.ts +70 -0
- package/src/git-preflight.ts +68 -0
- package/src/hub-jwt.test.ts +75 -2
- package/src/hub-jwt.ts +43 -6
- package/src/init-summary.test.ts +120 -5
- package/src/init-summary.ts +67 -25
- package/src/live-match.test.ts +198 -0
- package/src/live-match.ts +310 -0
- package/src/mcp-install.test.ts +93 -0
- package/src/mcp-install.ts +106 -0
- package/src/mcp-tools.ts +80 -7
- package/src/mirror-config.test.ts +14 -0
- package/src/mirror-config.ts +11 -0
- package/src/mirror-import.test.ts +110 -0
- package/src/mirror-import.ts +71 -13
- package/src/mirror-manager.test.ts +51 -0
- package/src/mirror-manager.ts +73 -11
- package/src/mirror-routes.test.ts +463 -1
- package/src/mirror-routes.ts +474 -4
- package/src/oauth-discovery.test.ts +55 -0
- package/src/oauth-discovery.ts +24 -5
- package/src/routes.ts +696 -121
- package/src/routing.test.ts +451 -5
- package/src/routing.ts +113 -5
- package/src/scopes.ts +1 -1
- package/src/server.ts +66 -4
- package/src/storage.test.ts +162 -0
- package/src/subscribe.test.ts +588 -0
- package/src/subscribe.ts +248 -0
- package/src/subscriptions.ts +295 -0
- package/src/tag-expand-routes.test.ts +45 -0
- package/src/tag-scope.ts +68 -1
- package/src/token-store.ts +7 -7
- package/src/transcription-worker.test.ts +471 -5
- package/src/transcription-worker.ts +212 -44
- package/src/triggers-api.test.ts +533 -0
- package/src/triggers-api.ts +295 -0
- package/src/triggers.ts +93 -7
- package/src/usage.test.ts +362 -0
- package/src/usage.ts +318 -0
- package/src/vault-create.test.ts +340 -12
- package/src/vault-name.test.ts +61 -3
- package/src/vault-name.ts +62 -14
- package/src/vault-remove.test.ts +187 -0
- package/src/vault-store.ts +10 -3
- package/src/vault.test.ts +1353 -62
- package/web/ui/dist/assets/index-CGL256oe.js +60 -0
- package/web/ui/dist/assets/index-J0pVP7I-.css +1 -0
- package/web/ui/dist/index.html +2 -2
- package/web/ui/dist/assets/index-DBe8Xiah.css +0 -1
- package/web/ui/dist/assets/index-DDRo6F4u.js +0 -60
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
(function(){const c=document.createElement("link").relList;if(c&&c.supports&&c.supports("modulepreload"))return;for(const h of document.querySelectorAll('link[rel="modulepreload"]'))r(h);new MutationObserver(h=>{for(const m of h)if(m.type==="childList")for(const y of m.addedNodes)y.tagName==="LINK"&&y.rel==="modulepreload"&&r(y)}).observe(document,{childList:!0,subtree:!0});function f(h){const m={};return h.integrity&&(m.integrity=h.integrity),h.referrerPolicy&&(m.referrerPolicy=h.referrerPolicy),h.crossOrigin==="use-credentials"?m.credentials="include":h.crossOrigin==="anonymous"?m.credentials="omit":m.credentials="same-origin",m}function r(h){if(h.ep)return;h.ep=!0;const m=f(h);fetch(h.href,m)}})();var Xc={exports:{}},La={};/**
|
|
2
|
+
* @license React
|
|
3
|
+
* react-jsx-runtime.production.js
|
|
4
|
+
*
|
|
5
|
+
* Copyright (c) Meta Platforms, Inc. and 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 Sh;function Zy(){if(Sh)return La;Sh=1;var u=Symbol.for("react.transitional.element"),c=Symbol.for("react.fragment");function f(r,h,m){var y=null;if(m!==void 0&&(y=""+m),h.key!==void 0&&(y=""+h.key),"key"in h){m={};for(var j in h)j!=="key"&&(m[j]=h[j])}else m=h;return h=m.ref,{$$typeof:u,type:r,key:y,ref:h!==void 0?h:null,props:m}}return La.Fragment=c,La.jsx=f,La.jsxs=f,La}var jh;function Ky(){return jh||(jh=1,Xc.exports=Zy()),Xc.exports}var s=Ky(),Qc={exports:{}},le={};/**
|
|
10
|
+
* @license React
|
|
11
|
+
* react.production.js
|
|
12
|
+
*
|
|
13
|
+
* Copyright (c) Meta Platforms, Inc. and 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 Eh;function Jy(){if(Eh)return le;Eh=1;var u=Symbol.for("react.transitional.element"),c=Symbol.for("react.portal"),f=Symbol.for("react.fragment"),r=Symbol.for("react.strict_mode"),h=Symbol.for("react.profiler"),m=Symbol.for("react.consumer"),y=Symbol.for("react.context"),j=Symbol.for("react.forward_ref"),b=Symbol.for("react.suspense"),v=Symbol.for("react.memo"),T=Symbol.for("react.lazy"),p=Symbol.for("react.activity"),R=Symbol.iterator;function G(E){return E===null||typeof E!="object"?null:(E=R&&E[R]||E["@@iterator"],typeof E=="function"?E:null)}var D={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},L=Object.assign,V={};function Y(E,B,J){this.props=E,this.context=B,this.refs=V,this.updater=J||D}Y.prototype.isReactComponent={},Y.prototype.setState=function(E,B){if(typeof E!="object"&&typeof E!="function"&&E!=null)throw Error("takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,E,B,"setState")},Y.prototype.forceUpdate=function(E){this.updater.enqueueForceUpdate(this,E,"forceUpdate")};function Z(){}Z.prototype=Y.prototype;function k(E,B,J){this.props=E,this.context=B,this.refs=V,this.updater=J||D}var O=k.prototype=new Z;O.constructor=k,L(O,Y.prototype),O.isPureReactComponent=!0;var q=Array.isArray;function X(){}var Q={H:null,A:null,T:null,S:null},ee=Object.prototype.hasOwnProperty;function me(E,B,J){var F=J.ref;return{$$typeof:u,type:E,key:B,ref:F!==void 0?F:null,props:J}}function tt(E,B){return me(E.type,B,E.props)}function We(E){return typeof E=="object"&&E!==null&&E.$$typeof===u}function $e(E){var B={"=":"=0",":":"=2"};return"$"+E.replace(/[=:]/g,function(J){return B[J]})}var Ht=/\/+/g;function xt(E,B){return typeof E=="object"&&E!==null&&E.key!=null?$e(""+E.key):B.toString(36)}function Ue(E){switch(E.status){case"fulfilled":return E.value;case"rejected":throw E.reason;default:switch(typeof E.status=="string"?E.then(X,X):(E.status="pending",E.then(function(B){E.status==="pending"&&(E.status="fulfilled",E.value=B)},function(B){E.status==="pending"&&(E.status="rejected",E.reason=B)})),E.status){case"fulfilled":return E.value;case"rejected":throw E.reason}}throw E}function M(E,B,J,F,ne){var ue=typeof E;(ue==="undefined"||ue==="boolean")&&(E=null);var ye=!1;if(E===null)ye=!0;else switch(ue){case"bigint":case"string":case"number":ye=!0;break;case"object":switch(E.$$typeof){case u:case c:ye=!0;break;case T:return ye=E._init,M(ye(E._payload),B,J,F,ne)}}if(ye)return ne=ne(E),ye=F===""?"."+xt(E,0):F,q(ne)?(J="",ye!=null&&(J=ye.replace(Ht,"$&/")+"/"),M(ne,B,J,"",function(Zn){return Zn})):ne!=null&&(We(ne)&&(ne=tt(ne,J+(ne.key==null||E&&E.key===ne.key?"":(""+ne.key).replace(Ht,"$&/")+"/")+ye)),B.push(ne)),1;ye=0;var Ie=F===""?".":F+":";if(q(E))for(var Me=0;Me<E.length;Me++)F=E[Me],ue=Ie+xt(F,Me),ye+=M(F,B,J,ue,ne);else if(Me=G(E),typeof Me=="function")for(E=Me.call(E),Me=0;!(F=E.next()).done;)F=F.value,ue=Ie+xt(F,Me++),ye+=M(F,B,J,ue,ne);else if(ue==="object"){if(typeof E.then=="function")return M(Ue(E),B,J,F,ne);throw B=String(E),Error("Objects are not valid as a React child (found: "+(B==="[object Object]"?"object with keys {"+Object.keys(E).join(", ")+"}":B)+"). If you meant to render a collection of children, use an array instead.")}return ye}function K(E,B,J){if(E==null)return E;var F=[],ne=0;return M(E,F,"","",function(ue){return B.call(J,ue,ne++)}),F}function te(E){if(E._status===-1){var B=E._result;B=B(),B.then(function(J){(E._status===0||E._status===-1)&&(E._status=1,E._result=J)},function(J){(E._status===0||E._status===-1)&&(E._status=2,E._result=J)}),E._status===-1&&(E._status=0,E._result=B)}if(E._status===1)return E._result.default;throw E._result}var be=typeof reportError=="function"?reportError:function(E){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var B=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof E=="object"&&E!==null&&typeof E.message=="string"?String(E.message):String(E),error:E});if(!window.dispatchEvent(B))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",E);return}console.error(E)},Ee={map:K,forEach:function(E,B,J){K(E,function(){B.apply(this,arguments)},J)},count:function(E){var B=0;return K(E,function(){B++}),B},toArray:function(E){return K(E,function(B){return B})||[]},only:function(E){if(!We(E))throw Error("React.Children.only expected to receive a single React element child.");return E}};return le.Activity=p,le.Children=Ee,le.Component=Y,le.Fragment=f,le.Profiler=h,le.PureComponent=k,le.StrictMode=r,le.Suspense=b,le.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=Q,le.__COMPILER_RUNTIME={__proto__:null,c:function(E){return Q.H.useMemoCache(E)}},le.cache=function(E){return function(){return E.apply(null,arguments)}},le.cacheSignal=function(){return null},le.cloneElement=function(E,B,J){if(E==null)throw Error("The argument must be a React element, but you passed "+E+".");var F=L({},E.props),ne=E.key;if(B!=null)for(ue in B.key!==void 0&&(ne=""+B.key),B)!ee.call(B,ue)||ue==="key"||ue==="__self"||ue==="__source"||ue==="ref"&&B.ref===void 0||(F[ue]=B[ue]);var ue=arguments.length-2;if(ue===1)F.children=J;else if(1<ue){for(var ye=Array(ue),Ie=0;Ie<ue;Ie++)ye[Ie]=arguments[Ie+2];F.children=ye}return me(E.type,ne,F)},le.createContext=function(E){return E={$$typeof:y,_currentValue:E,_currentValue2:E,_threadCount:0,Provider:null,Consumer:null},E.Provider=E,E.Consumer={$$typeof:m,_context:E},E},le.createElement=function(E,B,J){var F,ne={},ue=null;if(B!=null)for(F in B.key!==void 0&&(ue=""+B.key),B)ee.call(B,F)&&F!=="key"&&F!=="__self"&&F!=="__source"&&(ne[F]=B[F]);var ye=arguments.length-2;if(ye===1)ne.children=J;else if(1<ye){for(var Ie=Array(ye),Me=0;Me<ye;Me++)Ie[Me]=arguments[Me+2];ne.children=Ie}if(E&&E.defaultProps)for(F in ye=E.defaultProps,ye)ne[F]===void 0&&(ne[F]=ye[F]);return me(E,ue,ne)},le.createRef=function(){return{current:null}},le.forwardRef=function(E){return{$$typeof:j,render:E}},le.isValidElement=We,le.lazy=function(E){return{$$typeof:T,_payload:{_status:-1,_result:E},_init:te}},le.memo=function(E,B){return{$$typeof:v,type:E,compare:B===void 0?null:B}},le.startTransition=function(E){var B=Q.T,J={};Q.T=J;try{var F=E(),ne=Q.S;ne!==null&&ne(J,F),typeof F=="object"&&F!==null&&typeof F.then=="function"&&F.then(X,be)}catch(ue){be(ue)}finally{B!==null&&J.types!==null&&(B.types=J.types),Q.T=B}},le.unstable_useCacheRefresh=function(){return Q.H.useCacheRefresh()},le.use=function(E){return Q.H.use(E)},le.useActionState=function(E,B,J){return Q.H.useActionState(E,B,J)},le.useCallback=function(E,B){return Q.H.useCallback(E,B)},le.useContext=function(E){return Q.H.useContext(E)},le.useDebugValue=function(){},le.useDeferredValue=function(E,B){return Q.H.useDeferredValue(E,B)},le.useEffect=function(E,B){return Q.H.useEffect(E,B)},le.useEffectEvent=function(E){return Q.H.useEffectEvent(E)},le.useId=function(){return Q.H.useId()},le.useImperativeHandle=function(E,B,J){return Q.H.useImperativeHandle(E,B,J)},le.useInsertionEffect=function(E,B){return Q.H.useInsertionEffect(E,B)},le.useLayoutEffect=function(E,B){return Q.H.useLayoutEffect(E,B)},le.useMemo=function(E,B){return Q.H.useMemo(E,B)},le.useOptimistic=function(E,B){return Q.H.useOptimistic(E,B)},le.useReducer=function(E,B,J){return Q.H.useReducer(E,B,J)},le.useRef=function(E){return Q.H.useRef(E)},le.useState=function(E){return Q.H.useState(E)},le.useSyncExternalStore=function(E,B,J){return Q.H.useSyncExternalStore(E,B,J)},le.useTransition=function(){return Q.H.useTransition()},le.version="19.2.5",le}var Th;function ur(){return Th||(Th=1,Qc.exports=Jy()),Qc.exports}var x=ur(),Zc={exports:{}},qa={},Kc={exports:{}},Jc={};/**
|
|
18
|
+
* @license React
|
|
19
|
+
* scheduler.production.js
|
|
20
|
+
*
|
|
21
|
+
* Copyright (c) Meta Platforms, Inc. and 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
|
+
*/var _h;function $y(){return _h||(_h=1,(function(u){function c(M,K){var te=M.length;M.push(K);e:for(;0<te;){var be=te-1>>>1,Ee=M[be];if(0<h(Ee,K))M[be]=K,M[te]=Ee,te=be;else break e}}function f(M){return M.length===0?null:M[0]}function r(M){if(M.length===0)return null;var K=M[0],te=M.pop();if(te!==K){M[0]=te;e:for(var be=0,Ee=M.length,E=Ee>>>1;be<E;){var B=2*(be+1)-1,J=M[B],F=B+1,ne=M[F];if(0>h(J,te))F<Ee&&0>h(ne,J)?(M[be]=ne,M[F]=te,be=F):(M[be]=J,M[B]=te,be=B);else if(F<Ee&&0>h(ne,te))M[be]=ne,M[F]=te,be=F;else break e}}return K}function h(M,K){var te=M.sortIndex-K.sortIndex;return te!==0?te:M.id-K.id}if(u.unstable_now=void 0,typeof performance=="object"&&typeof performance.now=="function"){var m=performance;u.unstable_now=function(){return m.now()}}else{var y=Date,j=y.now();u.unstable_now=function(){return y.now()-j}}var b=[],v=[],T=1,p=null,R=3,G=!1,D=!1,L=!1,V=!1,Y=typeof setTimeout=="function"?setTimeout:null,Z=typeof clearTimeout=="function"?clearTimeout:null,k=typeof setImmediate<"u"?setImmediate:null;function O(M){for(var K=f(v);K!==null;){if(K.callback===null)r(v);else if(K.startTime<=M)r(v),K.sortIndex=K.expirationTime,c(b,K);else break;K=f(v)}}function q(M){if(L=!1,O(M),!D)if(f(b)!==null)D=!0,X||(X=!0,$e());else{var K=f(v);K!==null&&Ue(q,K.startTime-M)}}var X=!1,Q=-1,ee=5,me=-1;function tt(){return V?!0:!(u.unstable_now()-me<ee)}function We(){if(V=!1,X){var M=u.unstable_now();me=M;var K=!0;try{e:{D=!1,L&&(L=!1,Z(Q),Q=-1),G=!0;var te=R;try{t:{for(O(M),p=f(b);p!==null&&!(p.expirationTime>M&&tt());){var be=p.callback;if(typeof be=="function"){p.callback=null,R=p.priorityLevel;var Ee=be(p.expirationTime<=M);if(M=u.unstable_now(),typeof Ee=="function"){p.callback=Ee,O(M),K=!0;break t}p===f(b)&&r(b),O(M)}else r(b);p=f(b)}if(p!==null)K=!0;else{var E=f(v);E!==null&&Ue(q,E.startTime-M),K=!1}}break e}finally{p=null,R=te,G=!1}K=void 0}}finally{K?$e():X=!1}}}var $e;if(typeof k=="function")$e=function(){k(We)};else if(typeof MessageChannel<"u"){var Ht=new MessageChannel,xt=Ht.port2;Ht.port1.onmessage=We,$e=function(){xt.postMessage(null)}}else $e=function(){Y(We,0)};function Ue(M,K){Q=Y(function(){M(u.unstable_now())},K)}u.unstable_IdlePriority=5,u.unstable_ImmediatePriority=1,u.unstable_LowPriority=4,u.unstable_NormalPriority=3,u.unstable_Profiling=null,u.unstable_UserBlockingPriority=2,u.unstable_cancelCallback=function(M){M.callback=null},u.unstable_forceFrameRate=function(M){0>M||125<M?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):ee=0<M?Math.floor(1e3/M):5},u.unstable_getCurrentPriorityLevel=function(){return R},u.unstable_next=function(M){switch(R){case 1:case 2:case 3:var K=3;break;default:K=R}var te=R;R=K;try{return M()}finally{R=te}},u.unstable_requestPaint=function(){V=!0},u.unstable_runWithPriority=function(M,K){switch(M){case 1:case 2:case 3:case 4:case 5:break;default:M=3}var te=R;R=M;try{return K()}finally{R=te}},u.unstable_scheduleCallback=function(M,K,te){var be=u.unstable_now();switch(typeof te=="object"&&te!==null?(te=te.delay,te=typeof te=="number"&&0<te?be+te:be):te=be,M){case 1:var Ee=-1;break;case 2:Ee=250;break;case 5:Ee=1073741823;break;case 4:Ee=1e4;break;default:Ee=5e3}return Ee=te+Ee,M={id:T++,callback:K,priorityLevel:M,startTime:te,expirationTime:Ee,sortIndex:-1},te>be?(M.sortIndex=te,c(v,M),f(b)===null&&M===f(v)&&(L?(Z(Q),Q=-1):L=!0,Ue(q,te-be))):(M.sortIndex=Ee,c(b,M),D||G||(D=!0,X||(X=!0,$e()))),M},u.unstable_shouldYield=tt,u.unstable_wrapCallback=function(M){var K=R;return function(){var te=R;R=K;try{return M.apply(this,arguments)}finally{R=te}}}})(Jc)),Jc}var Nh;function Fy(){return Nh||(Nh=1,Kc.exports=$y()),Kc.exports}var $c={exports:{}},Fe={};/**
|
|
26
|
+
* @license React
|
|
27
|
+
* react-dom.production.js
|
|
28
|
+
*
|
|
29
|
+
* Copyright (c) Meta Platforms, Inc. and 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 Ah;function Wy(){if(Ah)return Fe;Ah=1;var u=ur();function c(b){var v="https://react.dev/errors/"+b;if(1<arguments.length){v+="?args[]="+encodeURIComponent(arguments[1]);for(var T=2;T<arguments.length;T++)v+="&args[]="+encodeURIComponent(arguments[T])}return"Minified React error #"+b+"; visit "+v+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function f(){}var r={d:{f,r:function(){throw Error(c(522))},D:f,C:f,L:f,m:f,X:f,S:f,M:f},p:0,findDOMNode:null},h=Symbol.for("react.portal");function m(b,v,T){var p=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:h,key:p==null?null:""+p,children:b,containerInfo:v,implementation:T}}var y=u.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function j(b,v){if(b==="font")return"";if(typeof v=="string")return v==="use-credentials"?v:""}return Fe.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=r,Fe.createPortal=function(b,v){var T=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!v||v.nodeType!==1&&v.nodeType!==9&&v.nodeType!==11)throw Error(c(299));return m(b,v,null,T)},Fe.flushSync=function(b){var v=y.T,T=r.p;try{if(y.T=null,r.p=2,b)return b()}finally{y.T=v,r.p=T,r.d.f()}},Fe.preconnect=function(b,v){typeof b=="string"&&(v?(v=v.crossOrigin,v=typeof v=="string"?v==="use-credentials"?v:"":void 0):v=null,r.d.C(b,v))},Fe.prefetchDNS=function(b){typeof b=="string"&&r.d.D(b)},Fe.preinit=function(b,v){if(typeof b=="string"&&v&&typeof v.as=="string"){var T=v.as,p=j(T,v.crossOrigin),R=typeof v.integrity=="string"?v.integrity:void 0,G=typeof v.fetchPriority=="string"?v.fetchPriority:void 0;T==="style"?r.d.S(b,typeof v.precedence=="string"?v.precedence:void 0,{crossOrigin:p,integrity:R,fetchPriority:G}):T==="script"&&r.d.X(b,{crossOrigin:p,integrity:R,fetchPriority:G,nonce:typeof v.nonce=="string"?v.nonce:void 0})}},Fe.preinitModule=function(b,v){if(typeof b=="string")if(typeof v=="object"&&v!==null){if(v.as==null||v.as==="script"){var T=j(v.as,v.crossOrigin);r.d.M(b,{crossOrigin:T,integrity:typeof v.integrity=="string"?v.integrity:void 0,nonce:typeof v.nonce=="string"?v.nonce:void 0})}}else v==null&&r.d.M(b)},Fe.preload=function(b,v){if(typeof b=="string"&&typeof v=="object"&&v!==null&&typeof v.as=="string"){var T=v.as,p=j(T,v.crossOrigin);r.d.L(b,T,{crossOrigin:p,integrity:typeof v.integrity=="string"?v.integrity:void 0,nonce:typeof v.nonce=="string"?v.nonce:void 0,type:typeof v.type=="string"?v.type:void 0,fetchPriority:typeof v.fetchPriority=="string"?v.fetchPriority:void 0,referrerPolicy:typeof v.referrerPolicy=="string"?v.referrerPolicy:void 0,imageSrcSet:typeof v.imageSrcSet=="string"?v.imageSrcSet:void 0,imageSizes:typeof v.imageSizes=="string"?v.imageSizes:void 0,media:typeof v.media=="string"?v.media:void 0})}},Fe.preloadModule=function(b,v){if(typeof b=="string")if(v){var T=j(v.as,v.crossOrigin);r.d.m(b,{as:typeof v.as=="string"&&v.as!=="script"?v.as:void 0,crossOrigin:T,integrity:typeof v.integrity=="string"?v.integrity:void 0})}else r.d.m(b)},Fe.requestFormReset=function(b){r.d.r(b)},Fe.unstable_batchedUpdates=function(b,v){return b(v)},Fe.useFormState=function(b,v,T){return y.H.useFormState(b,v,T)},Fe.useFormStatus=function(){return y.H.useHostTransitionStatus()},Fe.version="19.2.5",Fe}var Rh;function Iy(){if(Rh)return $c.exports;Rh=1;function u(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(u)}catch(c){console.error(c)}}return u(),$c.exports=Wy(),$c.exports}/**
|
|
34
|
+
* @license React
|
|
35
|
+
* react-dom-client.production.js
|
|
36
|
+
*
|
|
37
|
+
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
38
|
+
*
|
|
39
|
+
* This source code is licensed under the MIT license found in the
|
|
40
|
+
* LICENSE file in the root directory of this source tree.
|
|
41
|
+
*/var wh;function Py(){if(wh)return qa;wh=1;var u=Fy(),c=ur(),f=Iy();function r(e){var t="https://react.dev/errors/"+e;if(1<arguments.length){t+="?args[]="+encodeURIComponent(arguments[1]);for(var l=2;l<arguments.length;l++)t+="&args[]="+encodeURIComponent(arguments[l])}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."}function h(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function m(e){var t=e,l=e;if(e.alternate)for(;t.return;)t=t.return;else{e=t;do t=e,(t.flags&4098)!==0&&(l=t.return),e=t.return;while(e)}return t.tag===3?l:null}function y(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 j(e){if(e.tag===31){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function b(e){if(m(e)!==e)throw Error(r(188))}function v(e){var t=e.alternate;if(!t){if(t=m(e),t===null)throw Error(r(188));return t!==e?null:e}for(var l=e,n=t;;){var a=l.return;if(a===null)break;var i=a.alternate;if(i===null){if(n=a.return,n!==null){l=n;continue}break}if(a.child===i.child){for(i=a.child;i;){if(i===l)return b(a),e;if(i===n)return b(a),t;i=i.sibling}throw Error(r(188))}if(l.return!==n.return)l=a,n=i;else{for(var o=!1,d=a.child;d;){if(d===l){o=!0,l=a,n=i;break}if(d===n){o=!0,n=a,l=i;break}d=d.sibling}if(!o){for(d=i.child;d;){if(d===l){o=!0,l=i,n=a;break}if(d===n){o=!0,n=i,l=a;break}d=d.sibling}if(!o)throw Error(r(189))}}if(l.alternate!==n)throw Error(r(190))}if(l.tag!==3)throw Error(r(188));return l.stateNode.current===l?e:t}function T(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e;for(e=e.child;e!==null;){if(t=T(e),t!==null)return t;e=e.sibling}return null}var p=Object.assign,R=Symbol.for("react.element"),G=Symbol.for("react.transitional.element"),D=Symbol.for("react.portal"),L=Symbol.for("react.fragment"),V=Symbol.for("react.strict_mode"),Y=Symbol.for("react.profiler"),Z=Symbol.for("react.consumer"),k=Symbol.for("react.context"),O=Symbol.for("react.forward_ref"),q=Symbol.for("react.suspense"),X=Symbol.for("react.suspense_list"),Q=Symbol.for("react.memo"),ee=Symbol.for("react.lazy"),me=Symbol.for("react.activity"),tt=Symbol.for("react.memo_cache_sentinel"),We=Symbol.iterator;function $e(e){return e===null||typeof e!="object"?null:(e=We&&e[We]||e["@@iterator"],typeof e=="function"?e:null)}var Ht=Symbol.for("react.client.reference");function xt(e){if(e==null)return null;if(typeof e=="function")return e.$$typeof===Ht?null:e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case L:return"Fragment";case Y:return"Profiler";case V:return"StrictMode";case q:return"Suspense";case X:return"SuspenseList";case me:return"Activity"}if(typeof e=="object")switch(e.$$typeof){case D:return"Portal";case k:return e.displayName||"Context";case Z:return(e._context.displayName||"Context")+".Consumer";case O:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case Q:return t=e.displayName||null,t!==null?t:xt(e.type)||"Memo";case ee:t=e._payload,e=e._init;try{return xt(e(t))}catch{}}return null}var Ue=Array.isArray,M=c.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,K=f.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,te={pending:!1,data:null,method:null,action:null},be=[],Ee=-1;function E(e){return{current:e}}function B(e){0>Ee||(e.current=be[Ee],be[Ee]=null,Ee--)}function J(e,t){Ee++,be[Ee]=e.current,e.current=t}var F=E(null),ne=E(null),ue=E(null),ye=E(null);function Ie(e,t){switch(J(ue,t),J(ne,e),J(F,null),t.nodeType){case 9:case 11:e=(e=t.documentElement)&&(e=e.namespaceURI)?Xd(e):0;break;default:if(e=t.tagName,t=t.namespaceURI)t=Xd(t),e=Qd(t,e);else switch(e){case"svg":e=1;break;case"math":e=2;break;default:e=0}}B(F),J(F,e)}function Me(){B(F),B(ne),B(ue)}function Zn(e){e.memoizedState!==null&&J(ye,e);var t=F.current,l=Qd(t,e.type);t!==l&&(J(ne,e),J(F,l))}function Wa(e){ne.current===e&&(B(F),B(ne)),ye.current===e&&(B(ye),Ua._currentValue=te)}var Nu,gr;function Ll(e){if(Nu===void 0)try{throw Error()}catch(l){var t=l.stack.trim().match(/\n( *(at )?)/);Nu=t&&t[1]||"",gr=-1<l.stack.indexOf(`
|
|
42
|
+
at`)?" (<anonymous>)":-1<l.stack.indexOf("@")?"@unknown:0:0":""}return`
|
|
43
|
+
`+Nu+e+gr}var Au=!1;function Ru(e,t){if(!e||Au)return"";Au=!0;var l=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var n={DetermineComponentFrameRoot:function(){try{if(t){var H=function(){throw Error()};if(Object.defineProperty(H.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(H,[])}catch(z){var w=z}Reflect.construct(e,[],H)}else{try{H.call()}catch(z){w=z}e.call(H.prototype)}}else{try{throw Error()}catch(z){w=z}(H=e())&&typeof H.catch=="function"&&H.catch(function(){})}}catch(z){if(z&&w&&typeof z.stack=="string")return[z.stack,w.stack]}return[null,null]}};n.DetermineComponentFrameRoot.displayName="DetermineComponentFrameRoot";var a=Object.getOwnPropertyDescriptor(n.DetermineComponentFrameRoot,"name");a&&a.configurable&&Object.defineProperty(n.DetermineComponentFrameRoot,"name",{value:"DetermineComponentFrameRoot"});var i=n.DetermineComponentFrameRoot(),o=i[0],d=i[1];if(o&&d){var g=o.split(`
|
|
44
|
+
`),A=d.split(`
|
|
45
|
+
`);for(a=n=0;n<g.length&&!g[n].includes("DetermineComponentFrameRoot");)n++;for(;a<A.length&&!A[a].includes("DetermineComponentFrameRoot");)a++;if(n===g.length||a===A.length)for(n=g.length-1,a=A.length-1;1<=n&&0<=a&&g[n]!==A[a];)a--;for(;1<=n&&0<=a;n--,a--)if(g[n]!==A[a]){if(n!==1||a!==1)do if(n--,a--,0>a||g[n]!==A[a]){var C=`
|
|
46
|
+
`+g[n].replace(" at new "," at ");return e.displayName&&C.includes("<anonymous>")&&(C=C.replace("<anonymous>",e.displayName)),C}while(1<=n&&0<=a);break}}}finally{Au=!1,Error.prepareStackTrace=l}return(l=e?e.displayName||e.name:"")?Ll(l):""}function Em(e,t){switch(e.tag){case 26:case 27:case 5:return Ll(e.type);case 16:return Ll("Lazy");case 13:return e.child!==t&&t!==null?Ll("Suspense Fallback"):Ll("Suspense");case 19:return Ll("SuspenseList");case 0:case 15:return Ru(e.type,!1);case 11:return Ru(e.type.render,!1);case 1:return Ru(e.type,!0);case 31:return Ll("Activity");default:return""}}function br(e){try{var t="",l=null;do t+=Em(e,l),l=e,e=e.return;while(e);return t}catch(n){return`
|
|
47
|
+
Error generating stack: `+n.message+`
|
|
48
|
+
`+n.stack}}var wu=Object.prototype.hasOwnProperty,zu=u.unstable_scheduleCallback,Cu=u.unstable_cancelCallback,Tm=u.unstable_shouldYield,_m=u.unstable_requestPaint,ot=u.unstable_now,Nm=u.unstable_getCurrentPriorityLevel,xr=u.unstable_ImmediatePriority,Sr=u.unstable_UserBlockingPriority,Ia=u.unstable_NormalPriority,Am=u.unstable_LowPriority,jr=u.unstable_IdlePriority,Rm=u.log,wm=u.unstable_setDisableYieldValue,Kn=null,ft=null;function dl(e){if(typeof Rm=="function"&&wm(e),ft&&typeof ft.setStrictMode=="function")try{ft.setStrictMode(Kn,e)}catch{}}var dt=Math.clz32?Math.clz32:Mm,zm=Math.log,Cm=Math.LN2;function Mm(e){return e>>>=0,e===0?32:31-(zm(e)/Cm|0)|0}var Pa=256,ei=262144,ti=4194304;function ql(e){var t=e&42;if(t!==0)return t;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:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:return e&261888;case 262144:case 524288:case 1048576:case 2097152:return e&3932160;case 4194304:case 8388608:case 16777216:case 33554432:return e&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return e}}function li(e,t,l){var n=e.pendingLanes;if(n===0)return 0;var a=0,i=e.suspendedLanes,o=e.pingedLanes;e=e.warmLanes;var d=n&134217727;return d!==0?(n=d&~i,n!==0?a=ql(n):(o&=d,o!==0?a=ql(o):l||(l=d&~e,l!==0&&(a=ql(l))))):(d=n&~i,d!==0?a=ql(d):o!==0?a=ql(o):l||(l=n&~e,l!==0&&(a=ql(l)))),a===0?0:t!==0&&t!==a&&(t&i)===0&&(i=a&-a,l=t&-t,i>=l||i===32&&(l&4194048)!==0)?t:a}function Jn(e,t){return(e.pendingLanes&~(e.suspendedLanes&~e.pingedLanes)&t)===0}function Om(e,t){switch(e){case 1:case 2:case 4:case 8:case 64:return t+250;case 16:case 32:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t+5e3;case 4194304:case 8388608:case 16777216:case 33554432:return-1;case 67108864:case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function Er(){var e=ti;return ti<<=1,(ti&62914560)===0&&(ti=4194304),e}function Mu(e){for(var t=[],l=0;31>l;l++)t.push(e);return t}function $n(e,t){e.pendingLanes|=t,t!==268435456&&(e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0)}function Dm(e,t,l,n,a,i){var o=e.pendingLanes;e.pendingLanes=l,e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0,e.expiredLanes&=l,e.entangledLanes&=l,e.errorRecoveryDisabledLanes&=l,e.shellSuspendCounter=0;var d=e.entanglements,g=e.expirationTimes,A=e.hiddenUpdates;for(l=o&~l;0<l;){var C=31-dt(l),H=1<<C;d[C]=0,g[C]=-1;var w=A[C];if(w!==null)for(A[C]=null,C=0;C<w.length;C++){var z=w[C];z!==null&&(z.lane&=-536870913)}l&=~H}n!==0&&Tr(e,n,0),i!==0&&a===0&&e.tag!==0&&(e.suspendedLanes|=i&~(o&~t))}function Tr(e,t,l){e.pendingLanes|=t,e.suspendedLanes&=~t;var n=31-dt(t);e.entangledLanes|=t,e.entanglements[n]=e.entanglements[n]|1073741824|l&261930}function _r(e,t){var l=e.entangledLanes|=t;for(e=e.entanglements;l;){var n=31-dt(l),a=1<<n;a&t|e[n]&t&&(e[n]|=t),l&=~a}}function Nr(e,t){var l=t&-t;return l=(l&42)!==0?1:Ou(l),(l&(e.suspendedLanes|t))!==0?0:l}function Ou(e){switch(e){case 2:e=1;break;case 8:e=4;break;case 32:e=16;break;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:e=128;break;case 268435456:e=134217728;break;default:e=0}return e}function Du(e){return e&=-e,2<e?8<e?(e&134217727)!==0?32:268435456:8:2}function Ar(){var e=K.p;return e!==0?e:(e=window.event,e===void 0?32:mh(e.type))}function Rr(e,t){var l=K.p;try{return K.p=e,t()}finally{K.p=l}}var hl=Math.random().toString(36).slice(2),Ve="__reactFiber$"+hl,lt="__reactProps$"+hl,un="__reactContainer$"+hl,Uu="__reactEvents$"+hl,Um="__reactListeners$"+hl,km="__reactHandles$"+hl,wr="__reactResources$"+hl,Fn="__reactMarker$"+hl;function ku(e){delete e[Ve],delete e[lt],delete e[Uu],delete e[Um],delete e[km]}function sn(e){var t=e[Ve];if(t)return t;for(var l=e.parentNode;l;){if(t=l[un]||l[Ve]){if(l=t.alternate,t.child!==null||l!==null&&l.child!==null)for(e=Id(e);e!==null;){if(l=e[Ve])return l;e=Id(e)}return t}e=l,l=e.parentNode}return null}function cn(e){if(e=e[Ve]||e[un]){var t=e.tag;if(t===5||t===6||t===13||t===31||t===26||t===27||t===3)return e}return null}function Wn(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e.stateNode;throw Error(r(33))}function rn(e){var t=e[wr];return t||(t=e[wr]={hoistableStyles:new Map,hoistableScripts:new Map}),t}function Ye(e){e[Fn]=!0}var zr=new Set,Cr={};function Yl(e,t){on(e,t),on(e+"Capture",t)}function on(e,t){for(Cr[e]=t,e=0;e<t.length;e++)zr.add(t[e])}var Hm=RegExp("^[:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD][:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$"),Mr={},Or={};function Bm(e){return wu.call(Or,e)?!0:wu.call(Mr,e)?!1:Hm.test(e)?Or[e]=!0:(Mr[e]=!0,!1)}function ni(e,t,l){if(Bm(t))if(l===null)e.removeAttribute(t);else{switch(typeof l){case"undefined":case"function":case"symbol":e.removeAttribute(t);return;case"boolean":var n=t.toLowerCase().slice(0,5);if(n!=="data-"&&n!=="aria-"){e.removeAttribute(t);return}}e.setAttribute(t,""+l)}}function ai(e,t,l){if(l===null)e.removeAttribute(t);else{switch(typeof l){case"undefined":case"function":case"symbol":case"boolean":e.removeAttribute(t);return}e.setAttribute(t,""+l)}}function Qt(e,t,l,n){if(n===null)e.removeAttribute(l);else{switch(typeof n){case"undefined":case"function":case"symbol":case"boolean":e.removeAttribute(l);return}e.setAttributeNS(t,l,""+n)}}function St(e){switch(typeof e){case"bigint":case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function Dr(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function Lm(e,t,l){var n=Object.getOwnPropertyDescriptor(e.constructor.prototype,t);if(!e.hasOwnProperty(t)&&typeof n<"u"&&typeof n.get=="function"&&typeof n.set=="function"){var a=n.get,i=n.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return a.call(this)},set:function(o){l=""+o,i.call(this,o)}}),Object.defineProperty(e,t,{enumerable:n.enumerable}),{getValue:function(){return l},setValue:function(o){l=""+o},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function Hu(e){if(!e._valueTracker){var t=Dr(e)?"checked":"value";e._valueTracker=Lm(e,t,""+e[t])}}function Ur(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var l=t.getValue(),n="";return e&&(n=Dr(e)?e.checked?"true":"false":e.value),e=n,e!==l?(t.setValue(e),!0):!1}function ii(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}}var qm=/[\n"\\]/g;function jt(e){return e.replace(qm,function(t){return"\\"+t.charCodeAt(0).toString(16)+" "})}function Bu(e,t,l,n,a,i,o,d){e.name="",o!=null&&typeof o!="function"&&typeof o!="symbol"&&typeof o!="boolean"?e.type=o:e.removeAttribute("type"),t!=null?o==="number"?(t===0&&e.value===""||e.value!=t)&&(e.value=""+St(t)):e.value!==""+St(t)&&(e.value=""+St(t)):o!=="submit"&&o!=="reset"||e.removeAttribute("value"),t!=null?Lu(e,o,St(t)):l!=null?Lu(e,o,St(l)):n!=null&&e.removeAttribute("value"),a==null&&i!=null&&(e.defaultChecked=!!i),a!=null&&(e.checked=a&&typeof a!="function"&&typeof a!="symbol"),d!=null&&typeof d!="function"&&typeof d!="symbol"&&typeof d!="boolean"?e.name=""+St(d):e.removeAttribute("name")}function kr(e,t,l,n,a,i,o,d){if(i!=null&&typeof i!="function"&&typeof i!="symbol"&&typeof i!="boolean"&&(e.type=i),t!=null||l!=null){if(!(i!=="submit"&&i!=="reset"||t!=null)){Hu(e);return}l=l!=null?""+St(l):"",t=t!=null?""+St(t):l,d||t===e.value||(e.value=t),e.defaultValue=t}n=n??a,n=typeof n!="function"&&typeof n!="symbol"&&!!n,e.checked=d?e.checked:!!n,e.defaultChecked=!!n,o!=null&&typeof o!="function"&&typeof o!="symbol"&&typeof o!="boolean"&&(e.name=o),Hu(e)}function Lu(e,t,l){t==="number"&&ii(e.ownerDocument)===e||e.defaultValue===""+l||(e.defaultValue=""+l)}function fn(e,t,l,n){if(e=e.options,t){t={};for(var a=0;a<l.length;a++)t["$"+l[a]]=!0;for(l=0;l<e.length;l++)a=t.hasOwnProperty("$"+e[l].value),e[l].selected!==a&&(e[l].selected=a),a&&n&&(e[l].defaultSelected=!0)}else{for(l=""+St(l),t=null,a=0;a<e.length;a++){if(e[a].value===l){e[a].selected=!0,n&&(e[a].defaultSelected=!0);return}t!==null||e[a].disabled||(t=e[a])}t!==null&&(t.selected=!0)}}function Hr(e,t,l){if(t!=null&&(t=""+St(t),t!==e.value&&(e.value=t),l==null)){e.defaultValue!==t&&(e.defaultValue=t);return}e.defaultValue=l!=null?""+St(l):""}function Br(e,t,l,n){if(t==null){if(n!=null){if(l!=null)throw Error(r(92));if(Ue(n)){if(1<n.length)throw Error(r(93));n=n[0]}l=n}l==null&&(l=""),t=l}l=St(t),e.defaultValue=l,n=e.textContent,n===l&&n!==""&&n!==null&&(e.value=n),Hu(e)}function dn(e,t){if(t){var l=e.firstChild;if(l&&l===e.lastChild&&l.nodeType===3){l.nodeValue=t;return}}e.textContent=t}var Ym=new Set("animationIterationCount aspectRatio borderImageOutset borderImageSlice borderImageWidth boxFlex boxFlexGroup boxOrdinalGroup columnCount columns flex flexGrow flexPositive flexShrink flexNegative flexOrder gridArea gridRow gridRowEnd gridRowSpan gridRowStart gridColumn gridColumnEnd gridColumnSpan gridColumnStart fontWeight lineClamp lineHeight opacity order orphans scale tabSize widows zIndex zoom fillOpacity floodOpacity stopOpacity strokeDasharray strokeDashoffset strokeMiterlimit strokeOpacity strokeWidth MozAnimationIterationCount MozBoxFlex MozBoxFlexGroup MozLineClamp msAnimationIterationCount msFlex msZoom msFlexGrow msFlexNegative msFlexOrder msFlexPositive msFlexShrink msGridColumn msGridColumnSpan msGridRow msGridRowSpan WebkitAnimationIterationCount WebkitBoxFlex WebKitBoxFlexGroup WebkitBoxOrdinalGroup WebkitColumnCount WebkitColumns WebkitFlex WebkitFlexGrow WebkitFlexPositive WebkitFlexShrink WebkitLineClamp".split(" "));function Lr(e,t,l){var n=t.indexOf("--")===0;l==null||typeof l=="boolean"||l===""?n?e.setProperty(t,""):t==="float"?e.cssFloat="":e[t]="":n?e.setProperty(t,l):typeof l!="number"||l===0||Ym.has(t)?t==="float"?e.cssFloat=l:e[t]=(""+l).trim():e[t]=l+"px"}function qr(e,t,l){if(t!=null&&typeof t!="object")throw Error(r(62));if(e=e.style,l!=null){for(var n in l)!l.hasOwnProperty(n)||t!=null&&t.hasOwnProperty(n)||(n.indexOf("--")===0?e.setProperty(n,""):n==="float"?e.cssFloat="":e[n]="");for(var a in t)n=t[a],t.hasOwnProperty(a)&&l[a]!==n&&Lr(e,a,n)}else for(var i in t)t.hasOwnProperty(i)&&Lr(e,i,t[i])}function qu(e){if(e.indexOf("-")===-1)return!1;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 Gm=new Map([["acceptCharset","accept-charset"],["htmlFor","for"],["httpEquiv","http-equiv"],["crossOrigin","crossorigin"],["accentHeight","accent-height"],["alignmentBaseline","alignment-baseline"],["arabicForm","arabic-form"],["baselineShift","baseline-shift"],["capHeight","cap-height"],["clipPath","clip-path"],["clipRule","clip-rule"],["colorInterpolation","color-interpolation"],["colorInterpolationFilters","color-interpolation-filters"],["colorProfile","color-profile"],["colorRendering","color-rendering"],["dominantBaseline","dominant-baseline"],["enableBackground","enable-background"],["fillOpacity","fill-opacity"],["fillRule","fill-rule"],["floodColor","flood-color"],["floodOpacity","flood-opacity"],["fontFamily","font-family"],["fontSize","font-size"],["fontSizeAdjust","font-size-adjust"],["fontStretch","font-stretch"],["fontStyle","font-style"],["fontVariant","font-variant"],["fontWeight","font-weight"],["glyphName","glyph-name"],["glyphOrientationHorizontal","glyph-orientation-horizontal"],["glyphOrientationVertical","glyph-orientation-vertical"],["horizAdvX","horiz-adv-x"],["horizOriginX","horiz-origin-x"],["imageRendering","image-rendering"],["letterSpacing","letter-spacing"],["lightingColor","lighting-color"],["markerEnd","marker-end"],["markerMid","marker-mid"],["markerStart","marker-start"],["overlinePosition","overline-position"],["overlineThickness","overline-thickness"],["paintOrder","paint-order"],["panose-1","panose-1"],["pointerEvents","pointer-events"],["renderingIntent","rendering-intent"],["shapeRendering","shape-rendering"],["stopColor","stop-color"],["stopOpacity","stop-opacity"],["strikethroughPosition","strikethrough-position"],["strikethroughThickness","strikethrough-thickness"],["strokeDasharray","stroke-dasharray"],["strokeDashoffset","stroke-dashoffset"],["strokeLinecap","stroke-linecap"],["strokeLinejoin","stroke-linejoin"],["strokeMiterlimit","stroke-miterlimit"],["strokeOpacity","stroke-opacity"],["strokeWidth","stroke-width"],["textAnchor","text-anchor"],["textDecoration","text-decoration"],["textRendering","text-rendering"],["transformOrigin","transform-origin"],["underlinePosition","underline-position"],["underlineThickness","underline-thickness"],["unicodeBidi","unicode-bidi"],["unicodeRange","unicode-range"],["unitsPerEm","units-per-em"],["vAlphabetic","v-alphabetic"],["vHanging","v-hanging"],["vIdeographic","v-ideographic"],["vMathematical","v-mathematical"],["vectorEffect","vector-effect"],["vertAdvY","vert-adv-y"],["vertOriginX","vert-origin-x"],["vertOriginY","vert-origin-y"],["wordSpacing","word-spacing"],["writingMode","writing-mode"],["xmlnsXlink","xmlns:xlink"],["xHeight","x-height"]]),Vm=/^[\u0000-\u001F ]*j[\r\n\t]*a[\r\n\t]*v[\r\n\t]*a[\r\n\t]*s[\r\n\t]*c[\r\n\t]*r[\r\n\t]*i[\r\n\t]*p[\r\n\t]*t[\r\n\t]*:/i;function ui(e){return Vm.test(""+e)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":e}function Zt(){}var Yu=null;function Gu(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var hn=null,mn=null;function Yr(e){var t=cn(e);if(t&&(e=t.stateNode)){var l=e[lt]||null;e:switch(e=t.stateNode,t.type){case"input":if(Bu(e,l.value,l.defaultValue,l.defaultValue,l.checked,l.defaultChecked,l.type,l.name),t=l.name,l.type==="radio"&&t!=null){for(l=e;l.parentNode;)l=l.parentNode;for(l=l.querySelectorAll('input[name="'+jt(""+t)+'"][type="radio"]'),t=0;t<l.length;t++){var n=l[t];if(n!==e&&n.form===e.form){var a=n[lt]||null;if(!a)throw Error(r(90));Bu(n,a.value,a.defaultValue,a.defaultValue,a.checked,a.defaultChecked,a.type,a.name)}}for(t=0;t<l.length;t++)n=l[t],n.form===e.form&&Ur(n)}break e;case"textarea":Hr(e,l.value,l.defaultValue);break e;case"select":t=l.value,t!=null&&fn(e,!!l.multiple,t,!1)}}}var Vu=!1;function Gr(e,t,l){if(Vu)return e(t,l);Vu=!0;try{var n=e(t);return n}finally{if(Vu=!1,(hn!==null||mn!==null)&&(Ki(),hn&&(t=hn,e=mn,mn=hn=null,Yr(t),e)))for(t=0;t<e.length;t++)Yr(e[t])}}function In(e,t){var l=e.stateNode;if(l===null)return null;var n=l[lt]||null;if(n===null)return null;l=n[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":(n=!n.disabled)||(e=e.type,n=!(e==="button"||e==="input"||e==="select"||e==="textarea")),e=!n;break e;default:e=!1}if(e)return null;if(l&&typeof l!="function")throw Error(r(231,t,typeof l));return l}var Kt=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),Xu=!1;if(Kt)try{var Pn={};Object.defineProperty(Pn,"passive",{get:function(){Xu=!0}}),window.addEventListener("test",Pn,Pn),window.removeEventListener("test",Pn,Pn)}catch{Xu=!1}var ml=null,Qu=null,si=null;function Vr(){if(si)return si;var e,t=Qu,l=t.length,n,a="value"in ml?ml.value:ml.textContent,i=a.length;for(e=0;e<l&&t[e]===a[e];e++);var o=l-e;for(n=1;n<=o&&t[l-n]===a[i-n];n++);return si=a.slice(e,1<n?1-n:void 0)}function ci(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 ri(){return!0}function Xr(){return!1}function nt(e){function t(l,n,a,i,o){this._reactName=l,this._targetInst=a,this.type=n,this.nativeEvent=i,this.target=o,this.currentTarget=null;for(var d in e)e.hasOwnProperty(d)&&(l=e[d],this[d]=l?l(i):i[d]);return this.isDefaultPrevented=(i.defaultPrevented!=null?i.defaultPrevented:i.returnValue===!1)?ri:Xr,this.isPropagationStopped=Xr,this}return p(t.prototype,{preventDefault:function(){this.defaultPrevented=!0;var l=this.nativeEvent;l&&(l.preventDefault?l.preventDefault():typeof l.returnValue!="unknown"&&(l.returnValue=!1),this.isDefaultPrevented=ri)},stopPropagation:function(){var l=this.nativeEvent;l&&(l.stopPropagation?l.stopPropagation():typeof l.cancelBubble!="unknown"&&(l.cancelBubble=!0),this.isPropagationStopped=ri)},persist:function(){},isPersistent:ri}),t}var Gl={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},oi=nt(Gl),ea=p({},Gl,{view:0,detail:0}),Xm=nt(ea),Zu,Ku,ta,fi=p({},ea,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:$u,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!==ta&&(ta&&e.type==="mousemove"?(Zu=e.screenX-ta.screenX,Ku=e.screenY-ta.screenY):Ku=Zu=0,ta=e),Zu)},movementY:function(e){return"movementY"in e?e.movementY:Ku}}),Qr=nt(fi),Qm=p({},fi,{dataTransfer:0}),Zm=nt(Qm),Km=p({},ea,{relatedTarget:0}),Ju=nt(Km),Jm=p({},Gl,{animationName:0,elapsedTime:0,pseudoElement:0}),$m=nt(Jm),Fm=p({},Gl,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),Wm=nt(Fm),Im=p({},Gl,{data:0}),Zr=nt(Im),Pm={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},ev={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"},tv={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function lv(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=tv[e])?!!t[e]:!1}function $u(){return lv}var nv=p({},ea,{key:function(e){if(e.key){var t=Pm[e.key]||e.key;if(t!=="Unidentified")return t}return e.type==="keypress"?(e=ci(e),e===13?"Enter":String.fromCharCode(e)):e.type==="keydown"||e.type==="keyup"?ev[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:$u,charCode:function(e){return e.type==="keypress"?ci(e):0},keyCode:function(e){return e.type==="keydown"||e.type==="keyup"?e.keyCode:0},which:function(e){return e.type==="keypress"?ci(e):e.type==="keydown"||e.type==="keyup"?e.keyCode:0}}),av=nt(nv),iv=p({},fi,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),Kr=nt(iv),uv=p({},ea,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:$u}),sv=nt(uv),cv=p({},Gl,{propertyName:0,elapsedTime:0,pseudoElement:0}),rv=nt(cv),ov=p({},fi,{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}),fv=nt(ov),dv=p({},Gl,{newState:0,oldState:0}),hv=nt(dv),mv=[9,13,27,32],Fu=Kt&&"CompositionEvent"in window,la=null;Kt&&"documentMode"in document&&(la=document.documentMode);var vv=Kt&&"TextEvent"in window&&!la,Jr=Kt&&(!Fu||la&&8<la&&11>=la),$r=" ",Fr=!1;function Wr(e,t){switch(e){case"keyup":return mv.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function Ir(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var vn=!1;function yv(e,t){switch(e){case"compositionend":return Ir(t);case"keypress":return t.which!==32?null:(Fr=!0,$r);case"textInput":return e=t.data,e===$r&&Fr?null:e;default:return null}}function pv(e,t){if(vn)return e==="compositionend"||!Fu&&Wr(e,t)?(e=Vr(),si=Qu=ml=null,vn=!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 Jr&&t.locale!=="ko"?null:t.data;default:return null}}var gv={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 Pr(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t==="input"?!!gv[e.type]:t==="textarea"}function eo(e,t,l,n){hn?mn?mn.push(n):mn=[n]:hn=n,t=eu(t,"onChange"),0<t.length&&(l=new oi("onChange","change",null,l,n),e.push({event:l,listeners:t}))}var na=null,aa=null;function bv(e){Bd(e,0)}function di(e){var t=Wn(e);if(Ur(t))return e}function to(e,t){if(e==="change")return t}var lo=!1;if(Kt){var Wu;if(Kt){var Iu="oninput"in document;if(!Iu){var no=document.createElement("div");no.setAttribute("oninput","return;"),Iu=typeof no.oninput=="function"}Wu=Iu}else Wu=!1;lo=Wu&&(!document.documentMode||9<document.documentMode)}function ao(){na&&(na.detachEvent("onpropertychange",io),aa=na=null)}function io(e){if(e.propertyName==="value"&&di(aa)){var t=[];eo(t,aa,e,Gu(e)),Gr(bv,t)}}function xv(e,t,l){e==="focusin"?(ao(),na=t,aa=l,na.attachEvent("onpropertychange",io)):e==="focusout"&&ao()}function Sv(e){if(e==="selectionchange"||e==="keyup"||e==="keydown")return di(aa)}function jv(e,t){if(e==="click")return di(t)}function Ev(e,t){if(e==="input"||e==="change")return di(t)}function Tv(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var ht=typeof Object.is=="function"?Object.is:Tv;function ia(e,t){if(ht(e,t))return!0;if(typeof e!="object"||e===null||typeof t!="object"||t===null)return!1;var l=Object.keys(e),n=Object.keys(t);if(l.length!==n.length)return!1;for(n=0;n<l.length;n++){var a=l[n];if(!wu.call(t,a)||!ht(e[a],t[a]))return!1}return!0}function uo(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function so(e,t){var l=uo(e);e=0;for(var n;l;){if(l.nodeType===3){if(n=e+l.textContent.length,e<=t&&n>=t)return{node:l,offset:t-e};e=n}e:{for(;l;){if(l.nextSibling){l=l.nextSibling;break e}l=l.parentNode}l=void 0}l=uo(l)}}function co(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?co(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function ro(e){e=e!=null&&e.ownerDocument!=null&&e.ownerDocument.defaultView!=null?e.ownerDocument.defaultView:window;for(var t=ii(e.document);t instanceof e.HTMLIFrameElement;){try{var l=typeof t.contentWindow.location.href=="string"}catch{l=!1}if(l)e=t.contentWindow;else break;t=ii(e.document)}return t}function Pu(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")}var _v=Kt&&"documentMode"in document&&11>=document.documentMode,yn=null,es=null,ua=null,ts=!1;function oo(e,t,l){var n=l.window===l?l.document:l.nodeType===9?l:l.ownerDocument;ts||yn==null||yn!==ii(n)||(n=yn,"selectionStart"in n&&Pu(n)?n={start:n.selectionStart,end:n.selectionEnd}:(n=(n.ownerDocument&&n.ownerDocument.defaultView||window).getSelection(),n={anchorNode:n.anchorNode,anchorOffset:n.anchorOffset,focusNode:n.focusNode,focusOffset:n.focusOffset}),ua&&ia(ua,n)||(ua=n,n=eu(es,"onSelect"),0<n.length&&(t=new oi("onSelect","select",null,t,l),e.push({event:t,listeners:n}),t.target=yn)))}function Vl(e,t){var l={};return l[e.toLowerCase()]=t.toLowerCase(),l["Webkit"+e]="webkit"+t,l["Moz"+e]="moz"+t,l}var pn={animationend:Vl("Animation","AnimationEnd"),animationiteration:Vl("Animation","AnimationIteration"),animationstart:Vl("Animation","AnimationStart"),transitionrun:Vl("Transition","TransitionRun"),transitionstart:Vl("Transition","TransitionStart"),transitioncancel:Vl("Transition","TransitionCancel"),transitionend:Vl("Transition","TransitionEnd")},ls={},fo={};Kt&&(fo=document.createElement("div").style,"AnimationEvent"in window||(delete pn.animationend.animation,delete pn.animationiteration.animation,delete pn.animationstart.animation),"TransitionEvent"in window||delete pn.transitionend.transition);function Xl(e){if(ls[e])return ls[e];if(!pn[e])return e;var t=pn[e],l;for(l in t)if(t.hasOwnProperty(l)&&l in fo)return ls[e]=t[l];return e}var ho=Xl("animationend"),mo=Xl("animationiteration"),vo=Xl("animationstart"),Nv=Xl("transitionrun"),Av=Xl("transitionstart"),Rv=Xl("transitioncancel"),yo=Xl("transitionend"),po=new Map,ns="abort auxClick beforeToggle cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel".split(" ");ns.push("scrollEnd");function Ot(e,t){po.set(e,t),Yl(t,[e])}var hi=typeof reportError=="function"?reportError:function(e){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var t=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof e=="object"&&e!==null&&typeof e.message=="string"?String(e.message):String(e),error:e});if(!window.dispatchEvent(t))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",e);return}console.error(e)},Et=[],gn=0,as=0;function mi(){for(var e=gn,t=as=gn=0;t<e;){var l=Et[t];Et[t++]=null;var n=Et[t];Et[t++]=null;var a=Et[t];Et[t++]=null;var i=Et[t];if(Et[t++]=null,n!==null&&a!==null){var o=n.pending;o===null?a.next=a:(a.next=o.next,o.next=a),n.pending=a}i!==0&&go(l,a,i)}}function vi(e,t,l,n){Et[gn++]=e,Et[gn++]=t,Et[gn++]=l,Et[gn++]=n,as|=n,e.lanes|=n,e=e.alternate,e!==null&&(e.lanes|=n)}function is(e,t,l,n){return vi(e,t,l,n),yi(e)}function Ql(e,t){return vi(e,null,null,t),yi(e)}function go(e,t,l){e.lanes|=l;var n=e.alternate;n!==null&&(n.lanes|=l);for(var a=!1,i=e.return;i!==null;)i.childLanes|=l,n=i.alternate,n!==null&&(n.childLanes|=l),i.tag===22&&(e=i.stateNode,e===null||e._visibility&1||(a=!0)),e=i,i=i.return;return e.tag===3?(i=e.stateNode,a&&t!==null&&(a=31-dt(l),e=i.hiddenUpdates,n=e[a],n===null?e[a]=[t]:n.push(t),t.lane=l|536870912),i):null}function yi(e){if(50<Ra)throw Ra=0,mc=null,Error(r(185));for(var t=e.return;t!==null;)e=t,t=e.return;return e.tag===3?e.stateNode:null}var bn={};function wv(e,t,l,n){this.tag=e,this.key=l,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=n,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function mt(e,t,l,n){return new wv(e,t,l,n)}function us(e){return e=e.prototype,!(!e||!e.isReactComponent)}function Jt(e,t){var l=e.alternate;return l===null?(l=mt(e.tag,t,e.key,e.mode),l.elementType=e.elementType,l.type=e.type,l.stateNode=e.stateNode,l.alternate=e,e.alternate=l):(l.pendingProps=t,l.type=e.type,l.flags=0,l.subtreeFlags=0,l.deletions=null),l.flags=e.flags&65011712,l.childLanes=e.childLanes,l.lanes=e.lanes,l.child=e.child,l.memoizedProps=e.memoizedProps,l.memoizedState=e.memoizedState,l.updateQueue=e.updateQueue,t=e.dependencies,l.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},l.sibling=e.sibling,l.index=e.index,l.ref=e.ref,l.refCleanup=e.refCleanup,l}function bo(e,t){e.flags&=65011714;var l=e.alternate;return l===null?(e.childLanes=0,e.lanes=t,e.child=null,e.subtreeFlags=0,e.memoizedProps=null,e.memoizedState=null,e.updateQueue=null,e.dependencies=null,e.stateNode=null):(e.childLanes=l.childLanes,e.lanes=l.lanes,e.child=l.child,e.subtreeFlags=0,e.deletions=null,e.memoizedProps=l.memoizedProps,e.memoizedState=l.memoizedState,e.updateQueue=l.updateQueue,e.type=l.type,t=l.dependencies,e.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext}),e}function pi(e,t,l,n,a,i){var o=0;if(n=e,typeof e=="function")us(e)&&(o=1);else if(typeof e=="string")o=Dy(e,l,F.current)?26:e==="html"||e==="head"||e==="body"?27:5;else e:switch(e){case me:return e=mt(31,l,t,a),e.elementType=me,e.lanes=i,e;case L:return Zl(l.children,a,i,t);case V:o=8,a|=24;break;case Y:return e=mt(12,l,t,a|2),e.elementType=Y,e.lanes=i,e;case q:return e=mt(13,l,t,a),e.elementType=q,e.lanes=i,e;case X:return e=mt(19,l,t,a),e.elementType=X,e.lanes=i,e;default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case k:o=10;break e;case Z:o=9;break e;case O:o=11;break e;case Q:o=14;break e;case ee:o=16,n=null;break e}o=29,l=Error(r(130,e===null?"null":typeof e,"")),n=null}return t=mt(o,l,t,a),t.elementType=e,t.type=n,t.lanes=i,t}function Zl(e,t,l,n){return e=mt(7,e,n,t),e.lanes=l,e}function ss(e,t,l){return e=mt(6,e,null,t),e.lanes=l,e}function xo(e){var t=mt(18,null,null,0);return t.stateNode=e,t}function cs(e,t,l){return t=mt(4,e.children!==null?e.children:[],e.key,t),t.lanes=l,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}var So=new WeakMap;function Tt(e,t){if(typeof e=="object"&&e!==null){var l=So.get(e);return l!==void 0?l:(t={value:e,source:t,stack:br(t)},So.set(e,t),t)}return{value:e,source:t,stack:br(t)}}var xn=[],Sn=0,gi=null,sa=0,_t=[],Nt=0,vl=null,Bt=1,Lt="";function $t(e,t){xn[Sn++]=sa,xn[Sn++]=gi,gi=e,sa=t}function jo(e,t,l){_t[Nt++]=Bt,_t[Nt++]=Lt,_t[Nt++]=vl,vl=e;var n=Bt;e=Lt;var a=32-dt(n)-1;n&=~(1<<a),l+=1;var i=32-dt(t)+a;if(30<i){var o=a-a%5;i=(n&(1<<o)-1).toString(32),n>>=o,a-=o,Bt=1<<32-dt(t)+a|l<<a|n,Lt=i+e}else Bt=1<<i|l<<a|n,Lt=e}function rs(e){e.return!==null&&($t(e,1),jo(e,1,0))}function os(e){for(;e===gi;)gi=xn[--Sn],xn[Sn]=null,sa=xn[--Sn],xn[Sn]=null;for(;e===vl;)vl=_t[--Nt],_t[Nt]=null,Lt=_t[--Nt],_t[Nt]=null,Bt=_t[--Nt],_t[Nt]=null}function Eo(e,t){_t[Nt++]=Bt,_t[Nt++]=Lt,_t[Nt++]=vl,Bt=t.id,Lt=t.overflow,vl=e}var Xe=null,Ne=null,fe=!1,yl=null,At=!1,fs=Error(r(519));function pl(e){var t=Error(r(418,1<arguments.length&&arguments[1]!==void 0&&arguments[1]?"text":"HTML",""));throw ca(Tt(t,e)),fs}function To(e){var t=e.stateNode,l=e.type,n=e.memoizedProps;switch(t[Ve]=e,t[lt]=n,l){case"dialog":ce("cancel",t),ce("close",t);break;case"iframe":case"object":case"embed":ce("load",t);break;case"video":case"audio":for(l=0;l<za.length;l++)ce(za[l],t);break;case"source":ce("error",t);break;case"img":case"image":case"link":ce("error",t),ce("load",t);break;case"details":ce("toggle",t);break;case"input":ce("invalid",t),kr(t,n.value,n.defaultValue,n.checked,n.defaultChecked,n.type,n.name,!0);break;case"select":ce("invalid",t);break;case"textarea":ce("invalid",t),Br(t,n.value,n.defaultValue,n.children)}l=n.children,typeof l!="string"&&typeof l!="number"&&typeof l!="bigint"||t.textContent===""+l||n.suppressHydrationWarning===!0||Gd(t.textContent,l)?(n.popover!=null&&(ce("beforetoggle",t),ce("toggle",t)),n.onScroll!=null&&ce("scroll",t),n.onScrollEnd!=null&&ce("scrollend",t),n.onClick!=null&&(t.onclick=Zt),t=!0):t=!1,t||pl(e,!0)}function _o(e){for(Xe=e.return;Xe;)switch(Xe.tag){case 5:case 31:case 13:At=!1;return;case 27:case 3:At=!0;return;default:Xe=Xe.return}}function jn(e){if(e!==Xe)return!1;if(!fe)return _o(e),fe=!0,!1;var t=e.tag,l;if((l=t!==3&&t!==27)&&((l=t===5)&&(l=e.type,l=!(l!=="form"&&l!=="button")||wc(e.type,e.memoizedProps)),l=!l),l&&Ne&&pl(e),_o(e),t===13){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(r(317));Ne=Wd(e)}else if(t===31){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(r(317));Ne=Wd(e)}else t===27?(t=Ne,Cl(e.type)?(e=Dc,Dc=null,Ne=e):Ne=t):Ne=Xe?wt(e.stateNode.nextSibling):null;return!0}function Kl(){Ne=Xe=null,fe=!1}function ds(){var e=yl;return e!==null&&(st===null?st=e:st.push.apply(st,e),yl=null),e}function ca(e){yl===null?yl=[e]:yl.push(e)}var hs=E(null),Jl=null,Ft=null;function gl(e,t,l){J(hs,t._currentValue),t._currentValue=l}function Wt(e){e._currentValue=hs.current,B(hs)}function ms(e,t,l){for(;e!==null;){var n=e.alternate;if((e.childLanes&t)!==t?(e.childLanes|=t,n!==null&&(n.childLanes|=t)):n!==null&&(n.childLanes&t)!==t&&(n.childLanes|=t),e===l)break;e=e.return}}function vs(e,t,l,n){var a=e.child;for(a!==null&&(a.return=e);a!==null;){var i=a.dependencies;if(i!==null){var o=a.child;i=i.firstContext;e:for(;i!==null;){var d=i;i=a;for(var g=0;g<t.length;g++)if(d.context===t[g]){i.lanes|=l,d=i.alternate,d!==null&&(d.lanes|=l),ms(i.return,l,e),n||(o=null);break e}i=d.next}}else if(a.tag===18){if(o=a.return,o===null)throw Error(r(341));o.lanes|=l,i=o.alternate,i!==null&&(i.lanes|=l),ms(o,l,e),o=null}else o=a.child;if(o!==null)o.return=a;else for(o=a;o!==null;){if(o===e){o=null;break}if(a=o.sibling,a!==null){a.return=o.return,o=a;break}o=o.return}a=o}}function En(e,t,l,n){e=null;for(var a=t,i=!1;a!==null;){if(!i){if((a.flags&524288)!==0)i=!0;else if((a.flags&262144)!==0)break}if(a.tag===10){var o=a.alternate;if(o===null)throw Error(r(387));if(o=o.memoizedProps,o!==null){var d=a.type;ht(a.pendingProps.value,o.value)||(e!==null?e.push(d):e=[d])}}else if(a===ye.current){if(o=a.alternate,o===null)throw Error(r(387));o.memoizedState.memoizedState!==a.memoizedState.memoizedState&&(e!==null?e.push(Ua):e=[Ua])}a=a.return}e!==null&&vs(t,e,l,n),t.flags|=262144}function bi(e){for(e=e.firstContext;e!==null;){if(!ht(e.context._currentValue,e.memoizedValue))return!0;e=e.next}return!1}function $l(e){Jl=e,Ft=null,e=e.dependencies,e!==null&&(e.firstContext=null)}function Qe(e){return No(Jl,e)}function xi(e,t){return Jl===null&&$l(e),No(e,t)}function No(e,t){var l=t._currentValue;if(t={context:t,memoizedValue:l,next:null},Ft===null){if(e===null)throw Error(r(308));Ft=t,e.dependencies={lanes:0,firstContext:t},e.flags|=524288}else Ft=Ft.next=t;return l}var zv=typeof AbortController<"u"?AbortController:function(){var e=[],t=this.signal={aborted:!1,addEventListener:function(l,n){e.push(n)}};this.abort=function(){t.aborted=!0,e.forEach(function(l){return l()})}},Cv=u.unstable_scheduleCallback,Mv=u.unstable_NormalPriority,ke={$$typeof:k,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function ys(){return{controller:new zv,data:new Map,refCount:0}}function ra(e){e.refCount--,e.refCount===0&&Cv(Mv,function(){e.controller.abort()})}var oa=null,ps=0,Tn=0,_n=null;function Ov(e,t){if(oa===null){var l=oa=[];ps=0,Tn=xc(),_n={status:"pending",value:void 0,then:function(n){l.push(n)}}}return ps++,t.then(Ao,Ao),t}function Ao(){if(--ps===0&&oa!==null){_n!==null&&(_n.status="fulfilled");var e=oa;oa=null,Tn=0,_n=null;for(var t=0;t<e.length;t++)(0,e[t])()}}function Dv(e,t){var l=[],n={status:"pending",value:null,reason:null,then:function(a){l.push(a)}};return e.then(function(){n.status="fulfilled",n.value=t;for(var a=0;a<l.length;a++)(0,l[a])(t)},function(a){for(n.status="rejected",n.reason=a,a=0;a<l.length;a++)(0,l[a])(void 0)}),n}var Ro=M.S;M.S=function(e,t){dd=ot(),typeof t=="object"&&t!==null&&typeof t.then=="function"&&Ov(e,t),Ro!==null&&Ro(e,t)};var Fl=E(null);function gs(){var e=Fl.current;return e!==null?e:Te.pooledCache}function Si(e,t){t===null?J(Fl,Fl.current):J(Fl,t.pool)}function wo(){var e=gs();return e===null?null:{parent:ke._currentValue,pool:e}}var Nn=Error(r(460)),bs=Error(r(474)),ji=Error(r(542)),Ei={then:function(){}};function zo(e){return e=e.status,e==="fulfilled"||e==="rejected"}function Co(e,t,l){switch(l=e[l],l===void 0?e.push(t):l!==t&&(t.then(Zt,Zt),t=l),t.status){case"fulfilled":return t.value;case"rejected":throw e=t.reason,Oo(e),e;default:if(typeof t.status=="string")t.then(Zt,Zt);else{if(e=Te,e!==null&&100<e.shellSuspendCounter)throw Error(r(482));e=t,e.status="pending",e.then(function(n){if(t.status==="pending"){var a=t;a.status="fulfilled",a.value=n}},function(n){if(t.status==="pending"){var a=t;a.status="rejected",a.reason=n}})}switch(t.status){case"fulfilled":return t.value;case"rejected":throw e=t.reason,Oo(e),e}throw Il=t,Nn}}function Wl(e){try{var t=e._init;return t(e._payload)}catch(l){throw l!==null&&typeof l=="object"&&typeof l.then=="function"?(Il=l,Nn):l}}var Il=null;function Mo(){if(Il===null)throw Error(r(459));var e=Il;return Il=null,e}function Oo(e){if(e===Nn||e===ji)throw Error(r(483))}var An=null,fa=0;function Ti(e){var t=fa;return fa+=1,An===null&&(An=[]),Co(An,e,t)}function da(e,t){t=t.props.ref,e.ref=t!==void 0?t:null}function _i(e,t){throw t.$$typeof===R?Error(r(525)):(e=Object.prototype.toString.call(t),Error(r(31,e==="[object Object]"?"object with keys {"+Object.keys(t).join(", ")+"}":e)))}function Do(e){function t(_,S){if(e){var N=_.deletions;N===null?(_.deletions=[S],_.flags|=16):N.push(S)}}function l(_,S){if(!e)return null;for(;S!==null;)t(_,S),S=S.sibling;return null}function n(_){for(var S=new Map;_!==null;)_.key!==null?S.set(_.key,_):S.set(_.index,_),_=_.sibling;return S}function a(_,S){return _=Jt(_,S),_.index=0,_.sibling=null,_}function i(_,S,N){return _.index=N,e?(N=_.alternate,N!==null?(N=N.index,N<S?(_.flags|=67108866,S):N):(_.flags|=67108866,S)):(_.flags|=1048576,S)}function o(_){return e&&_.alternate===null&&(_.flags|=67108866),_}function d(_,S,N,U){return S===null||S.tag!==6?(S=ss(N,_.mode,U),S.return=_,S):(S=a(S,N),S.return=_,S)}function g(_,S,N,U){var I=N.type;return I===L?C(_,S,N.props.children,U,N.key):S!==null&&(S.elementType===I||typeof I=="object"&&I!==null&&I.$$typeof===ee&&Wl(I)===S.type)?(S=a(S,N.props),da(S,N),S.return=_,S):(S=pi(N.type,N.key,N.props,null,_.mode,U),da(S,N),S.return=_,S)}function A(_,S,N,U){return S===null||S.tag!==4||S.stateNode.containerInfo!==N.containerInfo||S.stateNode.implementation!==N.implementation?(S=cs(N,_.mode,U),S.return=_,S):(S=a(S,N.children||[]),S.return=_,S)}function C(_,S,N,U,I){return S===null||S.tag!==7?(S=Zl(N,_.mode,U,I),S.return=_,S):(S=a(S,N),S.return=_,S)}function H(_,S,N){if(typeof S=="string"&&S!==""||typeof S=="number"||typeof S=="bigint")return S=ss(""+S,_.mode,N),S.return=_,S;if(typeof S=="object"&&S!==null){switch(S.$$typeof){case G:return N=pi(S.type,S.key,S.props,null,_.mode,N),da(N,S),N.return=_,N;case D:return S=cs(S,_.mode,N),S.return=_,S;case ee:return S=Wl(S),H(_,S,N)}if(Ue(S)||$e(S))return S=Zl(S,_.mode,N,null),S.return=_,S;if(typeof S.then=="function")return H(_,Ti(S),N);if(S.$$typeof===k)return H(_,xi(_,S),N);_i(_,S)}return null}function w(_,S,N,U){var I=S!==null?S.key:null;if(typeof N=="string"&&N!==""||typeof N=="number"||typeof N=="bigint")return I!==null?null:d(_,S,""+N,U);if(typeof N=="object"&&N!==null){switch(N.$$typeof){case G:return N.key===I?g(_,S,N,U):null;case D:return N.key===I?A(_,S,N,U):null;case ee:return N=Wl(N),w(_,S,N,U)}if(Ue(N)||$e(N))return I!==null?null:C(_,S,N,U,null);if(typeof N.then=="function")return w(_,S,Ti(N),U);if(N.$$typeof===k)return w(_,S,xi(_,N),U);_i(_,N)}return null}function z(_,S,N,U,I){if(typeof U=="string"&&U!==""||typeof U=="number"||typeof U=="bigint")return _=_.get(N)||null,d(S,_,""+U,I);if(typeof U=="object"&&U!==null){switch(U.$$typeof){case G:return _=_.get(U.key===null?N:U.key)||null,g(S,_,U,I);case D:return _=_.get(U.key===null?N:U.key)||null,A(S,_,U,I);case ee:return U=Wl(U),z(_,S,N,U,I)}if(Ue(U)||$e(U))return _=_.get(N)||null,C(S,_,U,I,null);if(typeof U.then=="function")return z(_,S,N,Ti(U),I);if(U.$$typeof===k)return z(_,S,N,xi(S,U),I);_i(S,U)}return null}function $(_,S,N,U){for(var I=null,de=null,W=S,ie=S=0,oe=null;W!==null&&ie<N.length;ie++){W.index>ie?(oe=W,W=null):oe=W.sibling;var he=w(_,W,N[ie],U);if(he===null){W===null&&(W=oe);break}e&&W&&he.alternate===null&&t(_,W),S=i(he,S,ie),de===null?I=he:de.sibling=he,de=he,W=oe}if(ie===N.length)return l(_,W),fe&&$t(_,ie),I;if(W===null){for(;ie<N.length;ie++)W=H(_,N[ie],U),W!==null&&(S=i(W,S,ie),de===null?I=W:de.sibling=W,de=W);return fe&&$t(_,ie),I}for(W=n(W);ie<N.length;ie++)oe=z(W,_,ie,N[ie],U),oe!==null&&(e&&oe.alternate!==null&&W.delete(oe.key===null?ie:oe.key),S=i(oe,S,ie),de===null?I=oe:de.sibling=oe,de=oe);return e&&W.forEach(function(kl){return t(_,kl)}),fe&&$t(_,ie),I}function P(_,S,N,U){if(N==null)throw Error(r(151));for(var I=null,de=null,W=S,ie=S=0,oe=null,he=N.next();W!==null&&!he.done;ie++,he=N.next()){W.index>ie?(oe=W,W=null):oe=W.sibling;var kl=w(_,W,he.value,U);if(kl===null){W===null&&(W=oe);break}e&&W&&kl.alternate===null&&t(_,W),S=i(kl,S,ie),de===null?I=kl:de.sibling=kl,de=kl,W=oe}if(he.done)return l(_,W),fe&&$t(_,ie),I;if(W===null){for(;!he.done;ie++,he=N.next())he=H(_,he.value,U),he!==null&&(S=i(he,S,ie),de===null?I=he:de.sibling=he,de=he);return fe&&$t(_,ie),I}for(W=n(W);!he.done;ie++,he=N.next())he=z(W,_,ie,he.value,U),he!==null&&(e&&he.alternate!==null&&W.delete(he.key===null?ie:he.key),S=i(he,S,ie),de===null?I=he:de.sibling=he,de=he);return e&&W.forEach(function(Qy){return t(_,Qy)}),fe&&$t(_,ie),I}function je(_,S,N,U){if(typeof N=="object"&&N!==null&&N.type===L&&N.key===null&&(N=N.props.children),typeof N=="object"&&N!==null){switch(N.$$typeof){case G:e:{for(var I=N.key;S!==null;){if(S.key===I){if(I=N.type,I===L){if(S.tag===7){l(_,S.sibling),U=a(S,N.props.children),U.return=_,_=U;break e}}else if(S.elementType===I||typeof I=="object"&&I!==null&&I.$$typeof===ee&&Wl(I)===S.type){l(_,S.sibling),U=a(S,N.props),da(U,N),U.return=_,_=U;break e}l(_,S);break}else t(_,S);S=S.sibling}N.type===L?(U=Zl(N.props.children,_.mode,U,N.key),U.return=_,_=U):(U=pi(N.type,N.key,N.props,null,_.mode,U),da(U,N),U.return=_,_=U)}return o(_);case D:e:{for(I=N.key;S!==null;){if(S.key===I)if(S.tag===4&&S.stateNode.containerInfo===N.containerInfo&&S.stateNode.implementation===N.implementation){l(_,S.sibling),U=a(S,N.children||[]),U.return=_,_=U;break e}else{l(_,S);break}else t(_,S);S=S.sibling}U=cs(N,_.mode,U),U.return=_,_=U}return o(_);case ee:return N=Wl(N),je(_,S,N,U)}if(Ue(N))return $(_,S,N,U);if($e(N)){if(I=$e(N),typeof I!="function")throw Error(r(150));return N=I.call(N),P(_,S,N,U)}if(typeof N.then=="function")return je(_,S,Ti(N),U);if(N.$$typeof===k)return je(_,S,xi(_,N),U);_i(_,N)}return typeof N=="string"&&N!==""||typeof N=="number"||typeof N=="bigint"?(N=""+N,S!==null&&S.tag===6?(l(_,S.sibling),U=a(S,N),U.return=_,_=U):(l(_,S),U=ss(N,_.mode,U),U.return=_,_=U),o(_)):l(_,S)}return function(_,S,N,U){try{fa=0;var I=je(_,S,N,U);return An=null,I}catch(W){if(W===Nn||W===ji)throw W;var de=mt(29,W,null,_.mode);return de.lanes=U,de.return=_,de}finally{}}}var Pl=Do(!0),Uo=Do(!1),bl=!1;function xs(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function Ss(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,callbacks:null})}function xl(e){return{lane:e,tag:0,payload:null,callback:null,next:null}}function Sl(e,t,l){var n=e.updateQueue;if(n===null)return null;if(n=n.shared,(ve&2)!==0){var a=n.pending;return a===null?t.next=t:(t.next=a.next,a.next=t),n.pending=t,t=yi(e),go(e,null,l),t}return vi(e,n,t,l),yi(e)}function ha(e,t,l){if(t=t.updateQueue,t!==null&&(t=t.shared,(l&4194048)!==0)){var n=t.lanes;n&=e.pendingLanes,l|=n,t.lanes=l,_r(e,l)}}function js(e,t){var l=e.updateQueue,n=e.alternate;if(n!==null&&(n=n.updateQueue,l===n)){var a=null,i=null;if(l=l.firstBaseUpdate,l!==null){do{var o={lane:l.lane,tag:l.tag,payload:l.payload,callback:null,next:null};i===null?a=i=o:i=i.next=o,l=l.next}while(l!==null);i===null?a=i=t:i=i.next=t}else a=i=t;l={baseState:n.baseState,firstBaseUpdate:a,lastBaseUpdate:i,shared:n.shared,callbacks:n.callbacks},e.updateQueue=l;return}e=l.lastBaseUpdate,e===null?l.firstBaseUpdate=t:e.next=t,l.lastBaseUpdate=t}var Es=!1;function ma(){if(Es){var e=_n;if(e!==null)throw e}}function va(e,t,l,n){Es=!1;var a=e.updateQueue;bl=!1;var i=a.firstBaseUpdate,o=a.lastBaseUpdate,d=a.shared.pending;if(d!==null){a.shared.pending=null;var g=d,A=g.next;g.next=null,o===null?i=A:o.next=A,o=g;var C=e.alternate;C!==null&&(C=C.updateQueue,d=C.lastBaseUpdate,d!==o&&(d===null?C.firstBaseUpdate=A:d.next=A,C.lastBaseUpdate=g))}if(i!==null){var H=a.baseState;o=0,C=A=g=null,d=i;do{var w=d.lane&-536870913,z=w!==d.lane;if(z?(re&w)===w:(n&w)===w){w!==0&&w===Tn&&(Es=!0),C!==null&&(C=C.next={lane:0,tag:d.tag,payload:d.payload,callback:null,next:null});e:{var $=e,P=d;w=t;var je=l;switch(P.tag){case 1:if($=P.payload,typeof $=="function"){H=$.call(je,H,w);break e}H=$;break e;case 3:$.flags=$.flags&-65537|128;case 0:if($=P.payload,w=typeof $=="function"?$.call(je,H,w):$,w==null)break e;H=p({},H,w);break e;case 2:bl=!0}}w=d.callback,w!==null&&(e.flags|=64,z&&(e.flags|=8192),z=a.callbacks,z===null?a.callbacks=[w]:z.push(w))}else z={lane:w,tag:d.tag,payload:d.payload,callback:d.callback,next:null},C===null?(A=C=z,g=H):C=C.next=z,o|=w;if(d=d.next,d===null){if(d=a.shared.pending,d===null)break;z=d,d=z.next,z.next=null,a.lastBaseUpdate=z,a.shared.pending=null}}while(!0);C===null&&(g=H),a.baseState=g,a.firstBaseUpdate=A,a.lastBaseUpdate=C,i===null&&(a.shared.lanes=0),Nl|=o,e.lanes=o,e.memoizedState=H}}function ko(e,t){if(typeof e!="function")throw Error(r(191,e));e.call(t)}function Ho(e,t){var l=e.callbacks;if(l!==null)for(e.callbacks=null,e=0;e<l.length;e++)ko(l[e],t)}var Rn=E(null),Ni=E(0);function Bo(e,t){e=ul,J(Ni,e),J(Rn,t),ul=e|t.baseLanes}function Ts(){J(Ni,ul),J(Rn,Rn.current)}function _s(){ul=Ni.current,B(Rn),B(Ni)}var vt=E(null),Rt=null;function jl(e){var t=e.alternate;J(Oe,Oe.current&1),J(vt,e),Rt===null&&(t===null||Rn.current!==null||t.memoizedState!==null)&&(Rt=e)}function Ns(e){J(Oe,Oe.current),J(vt,e),Rt===null&&(Rt=e)}function Lo(e){e.tag===22?(J(Oe,Oe.current),J(vt,e),Rt===null&&(Rt=e)):El()}function El(){J(Oe,Oe.current),J(vt,vt.current)}function yt(e){B(vt),Rt===e&&(Rt=null),B(Oe)}var Oe=E(0);function Ai(e){for(var t=e;t!==null;){if(t.tag===13){var l=t.memoizedState;if(l!==null&&(l=l.dehydrated,l===null||Mc(l)||Oc(l)))return t}else if(t.tag===19&&(t.memoizedProps.revealOrder==="forwards"||t.memoizedProps.revealOrder==="backwards"||t.memoizedProps.revealOrder==="unstable_legacy-backwards"||t.memoizedProps.revealOrder==="together")){if((t.flags&128)!==0)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 It=0,ae=null,xe=null,He=null,Ri=!1,wn=!1,en=!1,wi=0,ya=0,zn=null,Uv=0;function ze(){throw Error(r(321))}function As(e,t){if(t===null)return!1;for(var l=0;l<t.length&&l<e.length;l++)if(!ht(e[l],t[l]))return!1;return!0}function Rs(e,t,l,n,a,i){return It=i,ae=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,M.H=e===null||e.memoizedState===null?Ef:Vs,en=!1,i=l(n,a),en=!1,wn&&(i=Yo(t,l,n,a)),qo(e),i}function qo(e){M.H=ba;var t=xe!==null&&xe.next!==null;if(It=0,He=xe=ae=null,Ri=!1,ya=0,zn=null,t)throw Error(r(300));e===null||Be||(e=e.dependencies,e!==null&&bi(e)&&(Be=!0))}function Yo(e,t,l,n){ae=e;var a=0;do{if(wn&&(zn=null),ya=0,wn=!1,25<=a)throw Error(r(301));if(a+=1,He=xe=null,e.updateQueue!=null){var i=e.updateQueue;i.lastEffect=null,i.events=null,i.stores=null,i.memoCache!=null&&(i.memoCache.index=0)}M.H=Tf,i=t(l,n)}while(wn);return i}function kv(){var e=M.H,t=e.useState()[0];return t=typeof t.then=="function"?pa(t):t,e=e.useState()[0],(xe!==null?xe.memoizedState:null)!==e&&(ae.flags|=1024),t}function ws(){var e=wi!==0;return wi=0,e}function zs(e,t,l){t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~l}function Cs(e){if(Ri){for(e=e.memoizedState;e!==null;){var t=e.queue;t!==null&&(t.pending=null),e=e.next}Ri=!1}It=0,He=xe=ae=null,wn=!1,ya=wi=0,zn=null}function Pe(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return He===null?ae.memoizedState=He=e:He=He.next=e,He}function De(){if(xe===null){var e=ae.alternate;e=e!==null?e.memoizedState:null}else e=xe.next;var t=He===null?ae.memoizedState:He.next;if(t!==null)He=t,xe=e;else{if(e===null)throw ae.alternate===null?Error(r(467)):Error(r(310));xe=e,e={memoizedState:xe.memoizedState,baseState:xe.baseState,baseQueue:xe.baseQueue,queue:xe.queue,next:null},He===null?ae.memoizedState=He=e:He=He.next=e}return He}function zi(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function pa(e){var t=ya;return ya+=1,zn===null&&(zn=[]),e=Co(zn,e,t),t=ae,(He===null?t.memoizedState:He.next)===null&&(t=t.alternate,M.H=t===null||t.memoizedState===null?Ef:Vs),e}function Ci(e){if(e!==null&&typeof e=="object"){if(typeof e.then=="function")return pa(e);if(e.$$typeof===k)return Qe(e)}throw Error(r(438,String(e)))}function Ms(e){var t=null,l=ae.updateQueue;if(l!==null&&(t=l.memoCache),t==null){var n=ae.alternate;n!==null&&(n=n.updateQueue,n!==null&&(n=n.memoCache,n!=null&&(t={data:n.data.map(function(a){return a.slice()}),index:0})))}if(t==null&&(t={data:[],index:0}),l===null&&(l=zi(),ae.updateQueue=l),l.memoCache=t,l=t.data[t.index],l===void 0)for(l=t.data[t.index]=Array(e),n=0;n<e;n++)l[n]=tt;return t.index++,l}function Pt(e,t){return typeof t=="function"?t(e):t}function Mi(e){var t=De();return Os(t,xe,e)}function Os(e,t,l){var n=e.queue;if(n===null)throw Error(r(311));n.lastRenderedReducer=l;var a=e.baseQueue,i=n.pending;if(i!==null){if(a!==null){var o=a.next;a.next=i.next,i.next=o}t.baseQueue=a=i,n.pending=null}if(i=e.baseState,a===null)e.memoizedState=i;else{t=a.next;var d=o=null,g=null,A=t,C=!1;do{var H=A.lane&-536870913;if(H!==A.lane?(re&H)===H:(It&H)===H){var w=A.revertLane;if(w===0)g!==null&&(g=g.next={lane:0,revertLane:0,gesture:null,action:A.action,hasEagerState:A.hasEagerState,eagerState:A.eagerState,next:null}),H===Tn&&(C=!0);else if((It&w)===w){A=A.next,w===Tn&&(C=!0);continue}else H={lane:0,revertLane:A.revertLane,gesture:null,action:A.action,hasEagerState:A.hasEagerState,eagerState:A.eagerState,next:null},g===null?(d=g=H,o=i):g=g.next=H,ae.lanes|=w,Nl|=w;H=A.action,en&&l(i,H),i=A.hasEagerState?A.eagerState:l(i,H)}else w={lane:H,revertLane:A.revertLane,gesture:A.gesture,action:A.action,hasEagerState:A.hasEagerState,eagerState:A.eagerState,next:null},g===null?(d=g=w,o=i):g=g.next=w,ae.lanes|=H,Nl|=H;A=A.next}while(A!==null&&A!==t);if(g===null?o=i:g.next=d,!ht(i,e.memoizedState)&&(Be=!0,C&&(l=_n,l!==null)))throw l;e.memoizedState=i,e.baseState=o,e.baseQueue=g,n.lastRenderedState=i}return a===null&&(n.lanes=0),[e.memoizedState,n.dispatch]}function Ds(e){var t=De(),l=t.queue;if(l===null)throw Error(r(311));l.lastRenderedReducer=e;var n=l.dispatch,a=l.pending,i=t.memoizedState;if(a!==null){l.pending=null;var o=a=a.next;do i=e(i,o.action),o=o.next;while(o!==a);ht(i,t.memoizedState)||(Be=!0),t.memoizedState=i,t.baseQueue===null&&(t.baseState=i),l.lastRenderedState=i}return[i,n]}function Go(e,t,l){var n=ae,a=De(),i=fe;if(i){if(l===void 0)throw Error(r(407));l=l()}else l=t();var o=!ht((xe||a).memoizedState,l);if(o&&(a.memoizedState=l,Be=!0),a=a.queue,Hs(Qo.bind(null,n,a,e),[e]),a.getSnapshot!==t||o||He!==null&&He.memoizedState.tag&1){if(n.flags|=2048,Cn(9,{destroy:void 0},Xo.bind(null,n,a,l,t),null),Te===null)throw Error(r(349));i||(It&127)!==0||Vo(n,t,l)}return l}function Vo(e,t,l){e.flags|=16384,e={getSnapshot:t,value:l},t=ae.updateQueue,t===null?(t=zi(),ae.updateQueue=t,t.stores=[e]):(l=t.stores,l===null?t.stores=[e]:l.push(e))}function Xo(e,t,l,n){t.value=l,t.getSnapshot=n,Zo(t)&&Ko(e)}function Qo(e,t,l){return l(function(){Zo(t)&&Ko(e)})}function Zo(e){var t=e.getSnapshot;e=e.value;try{var l=t();return!ht(e,l)}catch{return!0}}function Ko(e){var t=Ql(e,2);t!==null&&ct(t,e,2)}function Us(e){var t=Pe();if(typeof e=="function"){var l=e;if(e=l(),en){dl(!0);try{l()}finally{dl(!1)}}}return t.memoizedState=t.baseState=e,t.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Pt,lastRenderedState:e},t}function Jo(e,t,l,n){return e.baseState=l,Os(e,xe,typeof n=="function"?n:Pt)}function Hv(e,t,l,n,a){if(Ui(e))throw Error(r(485));if(e=t.action,e!==null){var i={payload:a,action:e,next:null,isTransition:!0,status:"pending",value:null,reason:null,listeners:[],then:function(o){i.listeners.push(o)}};M.T!==null?l(!0):i.isTransition=!1,n(i),l=t.pending,l===null?(i.next=t.pending=i,$o(t,i)):(i.next=l.next,t.pending=l.next=i)}}function $o(e,t){var l=t.action,n=t.payload,a=e.state;if(t.isTransition){var i=M.T,o={};M.T=o;try{var d=l(a,n),g=M.S;g!==null&&g(o,d),Fo(e,t,d)}catch(A){ks(e,t,A)}finally{i!==null&&o.types!==null&&(i.types=o.types),M.T=i}}else try{i=l(a,n),Fo(e,t,i)}catch(A){ks(e,t,A)}}function Fo(e,t,l){l!==null&&typeof l=="object"&&typeof l.then=="function"?l.then(function(n){Wo(e,t,n)},function(n){return ks(e,t,n)}):Wo(e,t,l)}function Wo(e,t,l){t.status="fulfilled",t.value=l,Io(t),e.state=l,t=e.pending,t!==null&&(l=t.next,l===t?e.pending=null:(l=l.next,t.next=l,$o(e,l)))}function ks(e,t,l){var n=e.pending;if(e.pending=null,n!==null){n=n.next;do t.status="rejected",t.reason=l,Io(t),t=t.next;while(t!==n)}e.action=null}function Io(e){e=e.listeners;for(var t=0;t<e.length;t++)(0,e[t])()}function Po(e,t){return t}function ef(e,t){if(fe){var l=Te.formState;if(l!==null){e:{var n=ae;if(fe){if(Ne){t:{for(var a=Ne,i=At;a.nodeType!==8;){if(!i){a=null;break t}if(a=wt(a.nextSibling),a===null){a=null;break t}}i=a.data,a=i==="F!"||i==="F"?a:null}if(a){Ne=wt(a.nextSibling),n=a.data==="F!";break e}}pl(n)}n=!1}n&&(t=l[0])}}return l=Pe(),l.memoizedState=l.baseState=t,n={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Po,lastRenderedState:t},l.queue=n,l=xf.bind(null,ae,n),n.dispatch=l,n=Us(!1),i=Gs.bind(null,ae,!1,n.queue),n=Pe(),a={state:t,dispatch:null,action:e,pending:null},n.queue=a,l=Hv.bind(null,ae,a,i,l),a.dispatch=l,n.memoizedState=e,[t,l,!1]}function tf(e){var t=De();return lf(t,xe,e)}function lf(e,t,l){if(t=Os(e,t,Po)[0],e=Mi(Pt)[0],typeof t=="object"&&t!==null&&typeof t.then=="function")try{var n=pa(t)}catch(o){throw o===Nn?ji:o}else n=t;t=De();var a=t.queue,i=a.dispatch;return l!==t.memoizedState&&(ae.flags|=2048,Cn(9,{destroy:void 0},Bv.bind(null,a,l),null)),[n,i,e]}function Bv(e,t){e.action=t}function nf(e){var t=De(),l=xe;if(l!==null)return lf(t,l,e);De(),t=t.memoizedState,l=De();var n=l.queue.dispatch;return l.memoizedState=e,[t,n,!1]}function Cn(e,t,l,n){return e={tag:e,create:l,deps:n,inst:t,next:null},t=ae.updateQueue,t===null&&(t=zi(),ae.updateQueue=t),l=t.lastEffect,l===null?t.lastEffect=e.next=e:(n=l.next,l.next=e,e.next=n,t.lastEffect=e),e}function af(){return De().memoizedState}function Oi(e,t,l,n){var a=Pe();ae.flags|=e,a.memoizedState=Cn(1|t,{destroy:void 0},l,n===void 0?null:n)}function Di(e,t,l,n){var a=De();n=n===void 0?null:n;var i=a.memoizedState.inst;xe!==null&&n!==null&&As(n,xe.memoizedState.deps)?a.memoizedState=Cn(t,i,l,n):(ae.flags|=e,a.memoizedState=Cn(1|t,i,l,n))}function uf(e,t){Oi(8390656,8,e,t)}function Hs(e,t){Di(2048,8,e,t)}function Lv(e){ae.flags|=4;var t=ae.updateQueue;if(t===null)t=zi(),ae.updateQueue=t,t.events=[e];else{var l=t.events;l===null?t.events=[e]:l.push(e)}}function sf(e){var t=De().memoizedState;return Lv({ref:t,nextImpl:e}),function(){if((ve&2)!==0)throw Error(r(440));return t.impl.apply(void 0,arguments)}}function cf(e,t){return Di(4,2,e,t)}function rf(e,t){return Di(4,4,e,t)}function of(e,t){if(typeof t=="function"){e=e();var l=t(e);return function(){typeof l=="function"?l():t(null)}}if(t!=null)return e=e(),t.current=e,function(){t.current=null}}function ff(e,t,l){l=l!=null?l.concat([e]):null,Di(4,4,of.bind(null,t,e),l)}function Bs(){}function df(e,t){var l=De();t=t===void 0?null:t;var n=l.memoizedState;return t!==null&&As(t,n[1])?n[0]:(l.memoizedState=[e,t],e)}function hf(e,t){var l=De();t=t===void 0?null:t;var n=l.memoizedState;if(t!==null&&As(t,n[1]))return n[0];if(n=e(),en){dl(!0);try{e()}finally{dl(!1)}}return l.memoizedState=[n,t],n}function Ls(e,t,l){return l===void 0||(It&1073741824)!==0&&(re&261930)===0?e.memoizedState=t:(e.memoizedState=l,e=md(),ae.lanes|=e,Nl|=e,l)}function mf(e,t,l,n){return ht(l,t)?l:Rn.current!==null?(e=Ls(e,l,n),ht(e,t)||(Be=!0),e):(It&42)===0||(It&1073741824)!==0&&(re&261930)===0?(Be=!0,e.memoizedState=l):(e=md(),ae.lanes|=e,Nl|=e,t)}function vf(e,t,l,n,a){var i=K.p;K.p=i!==0&&8>i?i:8;var o=M.T,d={};M.T=d,Gs(e,!1,t,l);try{var g=a(),A=M.S;if(A!==null&&A(d,g),g!==null&&typeof g=="object"&&typeof g.then=="function"){var C=Dv(g,n);ga(e,t,C,bt(e))}else ga(e,t,n,bt(e))}catch(H){ga(e,t,{then:function(){},status:"rejected",reason:H},bt())}finally{K.p=i,o!==null&&d.types!==null&&(o.types=d.types),M.T=o}}function qv(){}function qs(e,t,l,n){if(e.tag!==5)throw Error(r(476));var a=yf(e).queue;vf(e,a,t,te,l===null?qv:function(){return pf(e),l(n)})}function yf(e){var t=e.memoizedState;if(t!==null)return t;t={memoizedState:te,baseState:te,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Pt,lastRenderedState:te},next:null};var l={};return t.next={memoizedState:l,baseState:l,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Pt,lastRenderedState:l},next:null},e.memoizedState=t,e=e.alternate,e!==null&&(e.memoizedState=t),t}function pf(e){var t=yf(e);t.next===null&&(t=e.alternate.memoizedState),ga(e,t.next.queue,{},bt())}function Ys(){return Qe(Ua)}function gf(){return De().memoizedState}function bf(){return De().memoizedState}function Yv(e){for(var t=e.return;t!==null;){switch(t.tag){case 24:case 3:var l=bt();e=xl(l);var n=Sl(t,e,l);n!==null&&(ct(n,t,l),ha(n,t,l)),t={cache:ys()},e.payload=t;return}t=t.return}}function Gv(e,t,l){var n=bt();l={lane:n,revertLane:0,gesture:null,action:l,hasEagerState:!1,eagerState:null,next:null},Ui(e)?Sf(t,l):(l=is(e,t,l,n),l!==null&&(ct(l,e,n),jf(l,t,n)))}function xf(e,t,l){var n=bt();ga(e,t,l,n)}function ga(e,t,l,n){var a={lane:n,revertLane:0,gesture:null,action:l,hasEagerState:!1,eagerState:null,next:null};if(Ui(e))Sf(t,a);else{var i=e.alternate;if(e.lanes===0&&(i===null||i.lanes===0)&&(i=t.lastRenderedReducer,i!==null))try{var o=t.lastRenderedState,d=i(o,l);if(a.hasEagerState=!0,a.eagerState=d,ht(d,o))return vi(e,t,a,0),Te===null&&mi(),!1}catch{}finally{}if(l=is(e,t,a,n),l!==null)return ct(l,e,n),jf(l,t,n),!0}return!1}function Gs(e,t,l,n){if(n={lane:2,revertLane:xc(),gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null},Ui(e)){if(t)throw Error(r(479))}else t=is(e,l,n,2),t!==null&&ct(t,e,2)}function Ui(e){var t=e.alternate;return e===ae||t!==null&&t===ae}function Sf(e,t){wn=Ri=!0;var l=e.pending;l===null?t.next=t:(t.next=l.next,l.next=t),e.pending=t}function jf(e,t,l){if((l&4194048)!==0){var n=t.lanes;n&=e.pendingLanes,l|=n,t.lanes=l,_r(e,l)}}var ba={readContext:Qe,use:Ci,useCallback:ze,useContext:ze,useEffect:ze,useImperativeHandle:ze,useLayoutEffect:ze,useInsertionEffect:ze,useMemo:ze,useReducer:ze,useRef:ze,useState:ze,useDebugValue:ze,useDeferredValue:ze,useTransition:ze,useSyncExternalStore:ze,useId:ze,useHostTransitionStatus:ze,useFormState:ze,useActionState:ze,useOptimistic:ze,useMemoCache:ze,useCacheRefresh:ze};ba.useEffectEvent=ze;var Ef={readContext:Qe,use:Ci,useCallback:function(e,t){return Pe().memoizedState=[e,t===void 0?null:t],e},useContext:Qe,useEffect:uf,useImperativeHandle:function(e,t,l){l=l!=null?l.concat([e]):null,Oi(4194308,4,of.bind(null,t,e),l)},useLayoutEffect:function(e,t){return Oi(4194308,4,e,t)},useInsertionEffect:function(e,t){Oi(4,2,e,t)},useMemo:function(e,t){var l=Pe();t=t===void 0?null:t;var n=e();if(en){dl(!0);try{e()}finally{dl(!1)}}return l.memoizedState=[n,t],n},useReducer:function(e,t,l){var n=Pe();if(l!==void 0){var a=l(t);if(en){dl(!0);try{l(t)}finally{dl(!1)}}}else a=t;return n.memoizedState=n.baseState=a,e={pending:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:a},n.queue=e,e=e.dispatch=Gv.bind(null,ae,e),[n.memoizedState,e]},useRef:function(e){var t=Pe();return e={current:e},t.memoizedState=e},useState:function(e){e=Us(e);var t=e.queue,l=xf.bind(null,ae,t);return t.dispatch=l,[e.memoizedState,l]},useDebugValue:Bs,useDeferredValue:function(e,t){var l=Pe();return Ls(l,e,t)},useTransition:function(){var e=Us(!1);return e=vf.bind(null,ae,e.queue,!0,!1),Pe().memoizedState=e,[!1,e]},useSyncExternalStore:function(e,t,l){var n=ae,a=Pe();if(fe){if(l===void 0)throw Error(r(407));l=l()}else{if(l=t(),Te===null)throw Error(r(349));(re&127)!==0||Vo(n,t,l)}a.memoizedState=l;var i={value:l,getSnapshot:t};return a.queue=i,uf(Qo.bind(null,n,i,e),[e]),n.flags|=2048,Cn(9,{destroy:void 0},Xo.bind(null,n,i,l,t),null),l},useId:function(){var e=Pe(),t=Te.identifierPrefix;if(fe){var l=Lt,n=Bt;l=(n&~(1<<32-dt(n)-1)).toString(32)+l,t="_"+t+"R_"+l,l=wi++,0<l&&(t+="H"+l.toString(32)),t+="_"}else l=Uv++,t="_"+t+"r_"+l.toString(32)+"_";return e.memoizedState=t},useHostTransitionStatus:Ys,useFormState:ef,useActionState:ef,useOptimistic:function(e){var t=Pe();t.memoizedState=t.baseState=e;var l={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return t.queue=l,t=Gs.bind(null,ae,!0,l),l.dispatch=t,[e,t]},useMemoCache:Ms,useCacheRefresh:function(){return Pe().memoizedState=Yv.bind(null,ae)},useEffectEvent:function(e){var t=Pe(),l={impl:e};return t.memoizedState=l,function(){if((ve&2)!==0)throw Error(r(440));return l.impl.apply(void 0,arguments)}}},Vs={readContext:Qe,use:Ci,useCallback:df,useContext:Qe,useEffect:Hs,useImperativeHandle:ff,useInsertionEffect:cf,useLayoutEffect:rf,useMemo:hf,useReducer:Mi,useRef:af,useState:function(){return Mi(Pt)},useDebugValue:Bs,useDeferredValue:function(e,t){var l=De();return mf(l,xe.memoizedState,e,t)},useTransition:function(){var e=Mi(Pt)[0],t=De().memoizedState;return[typeof e=="boolean"?e:pa(e),t]},useSyncExternalStore:Go,useId:gf,useHostTransitionStatus:Ys,useFormState:tf,useActionState:tf,useOptimistic:function(e,t){var l=De();return Jo(l,xe,e,t)},useMemoCache:Ms,useCacheRefresh:bf};Vs.useEffectEvent=sf;var Tf={readContext:Qe,use:Ci,useCallback:df,useContext:Qe,useEffect:Hs,useImperativeHandle:ff,useInsertionEffect:cf,useLayoutEffect:rf,useMemo:hf,useReducer:Ds,useRef:af,useState:function(){return Ds(Pt)},useDebugValue:Bs,useDeferredValue:function(e,t){var l=De();return xe===null?Ls(l,e,t):mf(l,xe.memoizedState,e,t)},useTransition:function(){var e=Ds(Pt)[0],t=De().memoizedState;return[typeof e=="boolean"?e:pa(e),t]},useSyncExternalStore:Go,useId:gf,useHostTransitionStatus:Ys,useFormState:nf,useActionState:nf,useOptimistic:function(e,t){var l=De();return xe!==null?Jo(l,xe,e,t):(l.baseState=e,[e,l.queue.dispatch])},useMemoCache:Ms,useCacheRefresh:bf};Tf.useEffectEvent=sf;function Xs(e,t,l,n){t=e.memoizedState,l=l(n,t),l=l==null?t:p({},t,l),e.memoizedState=l,e.lanes===0&&(e.updateQueue.baseState=l)}var Qs={enqueueSetState:function(e,t,l){e=e._reactInternals;var n=bt(),a=xl(n);a.payload=t,l!=null&&(a.callback=l),t=Sl(e,a,n),t!==null&&(ct(t,e,n),ha(t,e,n))},enqueueReplaceState:function(e,t,l){e=e._reactInternals;var n=bt(),a=xl(n);a.tag=1,a.payload=t,l!=null&&(a.callback=l),t=Sl(e,a,n),t!==null&&(ct(t,e,n),ha(t,e,n))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var l=bt(),n=xl(l);n.tag=2,t!=null&&(n.callback=t),t=Sl(e,n,l),t!==null&&(ct(t,e,l),ha(t,e,l))}};function _f(e,t,l,n,a,i,o){return e=e.stateNode,typeof e.shouldComponentUpdate=="function"?e.shouldComponentUpdate(n,i,o):t.prototype&&t.prototype.isPureReactComponent?!ia(l,n)||!ia(a,i):!0}function Nf(e,t,l,n){e=t.state,typeof t.componentWillReceiveProps=="function"&&t.componentWillReceiveProps(l,n),typeof t.UNSAFE_componentWillReceiveProps=="function"&&t.UNSAFE_componentWillReceiveProps(l,n),t.state!==e&&Qs.enqueueReplaceState(t,t.state,null)}function tn(e,t){var l=t;if("ref"in t){l={};for(var n in t)n!=="ref"&&(l[n]=t[n])}if(e=e.defaultProps){l===t&&(l=p({},l));for(var a in e)l[a]===void 0&&(l[a]=e[a])}return l}function Af(e){hi(e)}function Rf(e){console.error(e)}function wf(e){hi(e)}function ki(e,t){try{var l=e.onUncaughtError;l(t.value,{componentStack:t.stack})}catch(n){setTimeout(function(){throw n})}}function zf(e,t,l){try{var n=e.onCaughtError;n(l.value,{componentStack:l.stack,errorBoundary:t.tag===1?t.stateNode:null})}catch(a){setTimeout(function(){throw a})}}function Zs(e,t,l){return l=xl(l),l.tag=3,l.payload={element:null},l.callback=function(){ki(e,t)},l}function Cf(e){return e=xl(e),e.tag=3,e}function Mf(e,t,l,n){var a=l.type.getDerivedStateFromError;if(typeof a=="function"){var i=n.value;e.payload=function(){return a(i)},e.callback=function(){zf(t,l,n)}}var o=l.stateNode;o!==null&&typeof o.componentDidCatch=="function"&&(e.callback=function(){zf(t,l,n),typeof a!="function"&&(Al===null?Al=new Set([this]):Al.add(this));var d=n.stack;this.componentDidCatch(n.value,{componentStack:d!==null?d:""})})}function Vv(e,t,l,n,a){if(l.flags|=32768,n!==null&&typeof n=="object"&&typeof n.then=="function"){if(t=l.alternate,t!==null&&En(t,l,a,!0),l=vt.current,l!==null){switch(l.tag){case 31:case 13:return Rt===null?Ji():l.alternate===null&&Ce===0&&(Ce=3),l.flags&=-257,l.flags|=65536,l.lanes=a,n===Ei?l.flags|=16384:(t=l.updateQueue,t===null?l.updateQueue=new Set([n]):t.add(n),pc(e,n,a)),!1;case 22:return l.flags|=65536,n===Ei?l.flags|=16384:(t=l.updateQueue,t===null?(t={transitions:null,markerInstances:null,retryQueue:new Set([n])},l.updateQueue=t):(l=t.retryQueue,l===null?t.retryQueue=new Set([n]):l.add(n)),pc(e,n,a)),!1}throw Error(r(435,l.tag))}return pc(e,n,a),Ji(),!1}if(fe)return t=vt.current,t!==null?((t.flags&65536)===0&&(t.flags|=256),t.flags|=65536,t.lanes=a,n!==fs&&(e=Error(r(422),{cause:n}),ca(Tt(e,l)))):(n!==fs&&(t=Error(r(423),{cause:n}),ca(Tt(t,l))),e=e.current.alternate,e.flags|=65536,a&=-a,e.lanes|=a,n=Tt(n,l),a=Zs(e.stateNode,n,a),js(e,a),Ce!==4&&(Ce=2)),!1;var i=Error(r(520),{cause:n});if(i=Tt(i,l),Aa===null?Aa=[i]:Aa.push(i),Ce!==4&&(Ce=2),t===null)return!0;n=Tt(n,l),l=t;do{switch(l.tag){case 3:return l.flags|=65536,e=a&-a,l.lanes|=e,e=Zs(l.stateNode,n,e),js(l,e),!1;case 1:if(t=l.type,i=l.stateNode,(l.flags&128)===0&&(typeof t.getDerivedStateFromError=="function"||i!==null&&typeof i.componentDidCatch=="function"&&(Al===null||!Al.has(i))))return l.flags|=65536,a&=-a,l.lanes|=a,a=Cf(a),Mf(a,e,l,n),js(l,a),!1}l=l.return}while(l!==null);return!1}var Ks=Error(r(461)),Be=!1;function Ze(e,t,l,n){t.child=e===null?Uo(t,null,l,n):Pl(t,e.child,l,n)}function Of(e,t,l,n,a){l=l.render;var i=t.ref;if("ref"in n){var o={};for(var d in n)d!=="ref"&&(o[d]=n[d])}else o=n;return $l(t),n=Rs(e,t,l,o,i,a),d=ws(),e!==null&&!Be?(zs(e,t,a),el(e,t,a)):(fe&&d&&rs(t),t.flags|=1,Ze(e,t,n,a),t.child)}function Df(e,t,l,n,a){if(e===null){var i=l.type;return typeof i=="function"&&!us(i)&&i.defaultProps===void 0&&l.compare===null?(t.tag=15,t.type=i,Uf(e,t,i,n,a)):(e=pi(l.type,null,n,t,t.mode,a),e.ref=t.ref,e.return=t,t.child=e)}if(i=e.child,!tc(e,a)){var o=i.memoizedProps;if(l=l.compare,l=l!==null?l:ia,l(o,n)&&e.ref===t.ref)return el(e,t,a)}return t.flags|=1,e=Jt(i,n),e.ref=t.ref,e.return=t,t.child=e}function Uf(e,t,l,n,a){if(e!==null){var i=e.memoizedProps;if(ia(i,n)&&e.ref===t.ref)if(Be=!1,t.pendingProps=n=i,tc(e,a))(e.flags&131072)!==0&&(Be=!0);else return t.lanes=e.lanes,el(e,t,a)}return Js(e,t,l,n,a)}function kf(e,t,l,n){var a=n.children,i=e!==null?e.memoizedState:null;if(e===null&&t.stateNode===null&&(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),n.mode==="hidden"){if((t.flags&128)!==0){if(i=i!==null?i.baseLanes|l:l,e!==null){for(n=t.child=e.child,a=0;n!==null;)a=a|n.lanes|n.childLanes,n=n.sibling;n=a&~i}else n=0,t.child=null;return Hf(e,t,i,l,n)}if((l&536870912)!==0)t.memoizedState={baseLanes:0,cachePool:null},e!==null&&Si(t,i!==null?i.cachePool:null),i!==null?Bo(t,i):Ts(),Lo(t);else return n=t.lanes=536870912,Hf(e,t,i!==null?i.baseLanes|l:l,l,n)}else i!==null?(Si(t,i.cachePool),Bo(t,i),El(),t.memoizedState=null):(e!==null&&Si(t,null),Ts(),El());return Ze(e,t,a,l),t.child}function xa(e,t){return e!==null&&e.tag===22||t.stateNode!==null||(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),t.sibling}function Hf(e,t,l,n,a){var i=gs();return i=i===null?null:{parent:ke._currentValue,pool:i},t.memoizedState={baseLanes:l,cachePool:i},e!==null&&Si(t,null),Ts(),Lo(t),e!==null&&En(e,t,n,!0),t.childLanes=a,null}function Hi(e,t){return t=Li({mode:t.mode,children:t.children},e.mode),t.ref=e.ref,e.child=t,t.return=e,t}function Bf(e,t,l){return Pl(t,e.child,null,l),e=Hi(t,t.pendingProps),e.flags|=2,yt(t),t.memoizedState=null,e}function Xv(e,t,l){var n=t.pendingProps,a=(t.flags&128)!==0;if(t.flags&=-129,e===null){if(fe){if(n.mode==="hidden")return e=Hi(t,n),t.lanes=536870912,xa(null,e);if(Ns(t),(e=Ne)?(e=Fd(e,At),e=e!==null&&e.data==="&"?e:null,e!==null&&(t.memoizedState={dehydrated:e,treeContext:vl!==null?{id:Bt,overflow:Lt}:null,retryLane:536870912,hydrationErrors:null},l=xo(e),l.return=t,t.child=l,Xe=t,Ne=null)):e=null,e===null)throw pl(t);return t.lanes=536870912,null}return Hi(t,n)}var i=e.memoizedState;if(i!==null){var o=i.dehydrated;if(Ns(t),a)if(t.flags&256)t.flags&=-257,t=Bf(e,t,l);else if(t.memoizedState!==null)t.child=e.child,t.flags|=128,t=null;else throw Error(r(558));else if(Be||En(e,t,l,!1),a=(l&e.childLanes)!==0,Be||a){if(n=Te,n!==null&&(o=Nr(n,l),o!==0&&o!==i.retryLane))throw i.retryLane=o,Ql(e,o),ct(n,e,o),Ks;Ji(),t=Bf(e,t,l)}else e=i.treeContext,Ne=wt(o.nextSibling),Xe=t,fe=!0,yl=null,At=!1,e!==null&&Eo(t,e),t=Hi(t,n),t.flags|=4096;return t}return e=Jt(e.child,{mode:n.mode,children:n.children}),e.ref=t.ref,t.child=e,e.return=t,e}function Bi(e,t){var l=t.ref;if(l===null)e!==null&&e.ref!==null&&(t.flags|=4194816);else{if(typeof l!="function"&&typeof l!="object")throw Error(r(284));(e===null||e.ref!==l)&&(t.flags|=4194816)}}function Js(e,t,l,n,a){return $l(t),l=Rs(e,t,l,n,void 0,a),n=ws(),e!==null&&!Be?(zs(e,t,a),el(e,t,a)):(fe&&n&&rs(t),t.flags|=1,Ze(e,t,l,a),t.child)}function Lf(e,t,l,n,a,i){return $l(t),t.updateQueue=null,l=Yo(t,n,l,a),qo(e),n=ws(),e!==null&&!Be?(zs(e,t,i),el(e,t,i)):(fe&&n&&rs(t),t.flags|=1,Ze(e,t,l,i),t.child)}function qf(e,t,l,n,a){if($l(t),t.stateNode===null){var i=bn,o=l.contextType;typeof o=="object"&&o!==null&&(i=Qe(o)),i=new l(n,i),t.memoizedState=i.state!==null&&i.state!==void 0?i.state:null,i.updater=Qs,t.stateNode=i,i._reactInternals=t,i=t.stateNode,i.props=n,i.state=t.memoizedState,i.refs={},xs(t),o=l.contextType,i.context=typeof o=="object"&&o!==null?Qe(o):bn,i.state=t.memoizedState,o=l.getDerivedStateFromProps,typeof o=="function"&&(Xs(t,l,o,n),i.state=t.memoizedState),typeof l.getDerivedStateFromProps=="function"||typeof i.getSnapshotBeforeUpdate=="function"||typeof i.UNSAFE_componentWillMount!="function"&&typeof i.componentWillMount!="function"||(o=i.state,typeof i.componentWillMount=="function"&&i.componentWillMount(),typeof i.UNSAFE_componentWillMount=="function"&&i.UNSAFE_componentWillMount(),o!==i.state&&Qs.enqueueReplaceState(i,i.state,null),va(t,n,i,a),ma(),i.state=t.memoizedState),typeof i.componentDidMount=="function"&&(t.flags|=4194308),n=!0}else if(e===null){i=t.stateNode;var d=t.memoizedProps,g=tn(l,d);i.props=g;var A=i.context,C=l.contextType;o=bn,typeof C=="object"&&C!==null&&(o=Qe(C));var H=l.getDerivedStateFromProps;C=typeof H=="function"||typeof i.getSnapshotBeforeUpdate=="function",d=t.pendingProps!==d,C||typeof i.UNSAFE_componentWillReceiveProps!="function"&&typeof i.componentWillReceiveProps!="function"||(d||A!==o)&&Nf(t,i,n,o),bl=!1;var w=t.memoizedState;i.state=w,va(t,n,i,a),ma(),A=t.memoizedState,d||w!==A||bl?(typeof H=="function"&&(Xs(t,l,H,n),A=t.memoizedState),(g=bl||_f(t,l,g,n,w,A,o))?(C||typeof i.UNSAFE_componentWillMount!="function"&&typeof i.componentWillMount!="function"||(typeof i.componentWillMount=="function"&&i.componentWillMount(),typeof i.UNSAFE_componentWillMount=="function"&&i.UNSAFE_componentWillMount()),typeof i.componentDidMount=="function"&&(t.flags|=4194308)):(typeof i.componentDidMount=="function"&&(t.flags|=4194308),t.memoizedProps=n,t.memoizedState=A),i.props=n,i.state=A,i.context=o,n=g):(typeof i.componentDidMount=="function"&&(t.flags|=4194308),n=!1)}else{i=t.stateNode,Ss(e,t),o=t.memoizedProps,C=tn(l,o),i.props=C,H=t.pendingProps,w=i.context,A=l.contextType,g=bn,typeof A=="object"&&A!==null&&(g=Qe(A)),d=l.getDerivedStateFromProps,(A=typeof d=="function"||typeof i.getSnapshotBeforeUpdate=="function")||typeof i.UNSAFE_componentWillReceiveProps!="function"&&typeof i.componentWillReceiveProps!="function"||(o!==H||w!==g)&&Nf(t,i,n,g),bl=!1,w=t.memoizedState,i.state=w,va(t,n,i,a),ma();var z=t.memoizedState;o!==H||w!==z||bl||e!==null&&e.dependencies!==null&&bi(e.dependencies)?(typeof d=="function"&&(Xs(t,l,d,n),z=t.memoizedState),(C=bl||_f(t,l,C,n,w,z,g)||e!==null&&e.dependencies!==null&&bi(e.dependencies))?(A||typeof i.UNSAFE_componentWillUpdate!="function"&&typeof i.componentWillUpdate!="function"||(typeof i.componentWillUpdate=="function"&&i.componentWillUpdate(n,z,g),typeof i.UNSAFE_componentWillUpdate=="function"&&i.UNSAFE_componentWillUpdate(n,z,g)),typeof i.componentDidUpdate=="function"&&(t.flags|=4),typeof i.getSnapshotBeforeUpdate=="function"&&(t.flags|=1024)):(typeof i.componentDidUpdate!="function"||o===e.memoizedProps&&w===e.memoizedState||(t.flags|=4),typeof i.getSnapshotBeforeUpdate!="function"||o===e.memoizedProps&&w===e.memoizedState||(t.flags|=1024),t.memoizedProps=n,t.memoizedState=z),i.props=n,i.state=z,i.context=g,n=C):(typeof i.componentDidUpdate!="function"||o===e.memoizedProps&&w===e.memoizedState||(t.flags|=4),typeof i.getSnapshotBeforeUpdate!="function"||o===e.memoizedProps&&w===e.memoizedState||(t.flags|=1024),n=!1)}return i=n,Bi(e,t),n=(t.flags&128)!==0,i||n?(i=t.stateNode,l=n&&typeof l.getDerivedStateFromError!="function"?null:i.render(),t.flags|=1,e!==null&&n?(t.child=Pl(t,e.child,null,a),t.child=Pl(t,null,l,a)):Ze(e,t,l,a),t.memoizedState=i.state,e=t.child):e=el(e,t,a),e}function Yf(e,t,l,n){return Kl(),t.flags|=256,Ze(e,t,l,n),t.child}var $s={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function Fs(e){return{baseLanes:e,cachePool:wo()}}function Ws(e,t,l){return e=e!==null?e.childLanes&~l:0,t&&(e|=gt),e}function Gf(e,t,l){var n=t.pendingProps,a=!1,i=(t.flags&128)!==0,o;if((o=i)||(o=e!==null&&e.memoizedState===null?!1:(Oe.current&2)!==0),o&&(a=!0,t.flags&=-129),o=(t.flags&32)!==0,t.flags&=-33,e===null){if(fe){if(a?jl(t):El(),(e=Ne)?(e=Fd(e,At),e=e!==null&&e.data!=="&"?e:null,e!==null&&(t.memoizedState={dehydrated:e,treeContext:vl!==null?{id:Bt,overflow:Lt}:null,retryLane:536870912,hydrationErrors:null},l=xo(e),l.return=t,t.child=l,Xe=t,Ne=null)):e=null,e===null)throw pl(t);return Oc(e)?t.lanes=32:t.lanes=536870912,null}var d=n.children;return n=n.fallback,a?(El(),a=t.mode,d=Li({mode:"hidden",children:d},a),n=Zl(n,a,l,null),d.return=t,n.return=t,d.sibling=n,t.child=d,n=t.child,n.memoizedState=Fs(l),n.childLanes=Ws(e,o,l),t.memoizedState=$s,xa(null,n)):(jl(t),Is(t,d))}var g=e.memoizedState;if(g!==null&&(d=g.dehydrated,d!==null)){if(i)t.flags&256?(jl(t),t.flags&=-257,t=Ps(e,t,l)):t.memoizedState!==null?(El(),t.child=e.child,t.flags|=128,t=null):(El(),d=n.fallback,a=t.mode,n=Li({mode:"visible",children:n.children},a),d=Zl(d,a,l,null),d.flags|=2,n.return=t,d.return=t,n.sibling=d,t.child=n,Pl(t,e.child,null,l),n=t.child,n.memoizedState=Fs(l),n.childLanes=Ws(e,o,l),t.memoizedState=$s,t=xa(null,n));else if(jl(t),Oc(d)){if(o=d.nextSibling&&d.nextSibling.dataset,o)var A=o.dgst;o=A,n=Error(r(419)),n.stack="",n.digest=o,ca({value:n,source:null,stack:null}),t=Ps(e,t,l)}else if(Be||En(e,t,l,!1),o=(l&e.childLanes)!==0,Be||o){if(o=Te,o!==null&&(n=Nr(o,l),n!==0&&n!==g.retryLane))throw g.retryLane=n,Ql(e,n),ct(o,e,n),Ks;Mc(d)||Ji(),t=Ps(e,t,l)}else Mc(d)?(t.flags|=192,t.child=e.child,t=null):(e=g.treeContext,Ne=wt(d.nextSibling),Xe=t,fe=!0,yl=null,At=!1,e!==null&&Eo(t,e),t=Is(t,n.children),t.flags|=4096);return t}return a?(El(),d=n.fallback,a=t.mode,g=e.child,A=g.sibling,n=Jt(g,{mode:"hidden",children:n.children}),n.subtreeFlags=g.subtreeFlags&65011712,A!==null?d=Jt(A,d):(d=Zl(d,a,l,null),d.flags|=2),d.return=t,n.return=t,n.sibling=d,t.child=n,xa(null,n),n=t.child,d=e.child.memoizedState,d===null?d=Fs(l):(a=d.cachePool,a!==null?(g=ke._currentValue,a=a.parent!==g?{parent:g,pool:g}:a):a=wo(),d={baseLanes:d.baseLanes|l,cachePool:a}),n.memoizedState=d,n.childLanes=Ws(e,o,l),t.memoizedState=$s,xa(e.child,n)):(jl(t),l=e.child,e=l.sibling,l=Jt(l,{mode:"visible",children:n.children}),l.return=t,l.sibling=null,e!==null&&(o=t.deletions,o===null?(t.deletions=[e],t.flags|=16):o.push(e)),t.child=l,t.memoizedState=null,l)}function Is(e,t){return t=Li({mode:"visible",children:t},e.mode),t.return=e,e.child=t}function Li(e,t){return e=mt(22,e,null,t),e.lanes=0,e}function Ps(e,t,l){return Pl(t,e.child,null,l),e=Is(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function Vf(e,t,l){e.lanes|=t;var n=e.alternate;n!==null&&(n.lanes|=t),ms(e.return,t,l)}function ec(e,t,l,n,a,i){var o=e.memoizedState;o===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:n,tail:l,tailMode:a,treeForkCount:i}:(o.isBackwards=t,o.rendering=null,o.renderingStartTime=0,o.last=n,o.tail=l,o.tailMode=a,o.treeForkCount=i)}function Xf(e,t,l){var n=t.pendingProps,a=n.revealOrder,i=n.tail;n=n.children;var o=Oe.current,d=(o&2)!==0;if(d?(o=o&1|2,t.flags|=128):o&=1,J(Oe,o),Ze(e,t,n,l),n=fe?sa:0,!d&&e!==null&&(e.flags&128)!==0)e:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&Vf(e,l,t);else if(e.tag===19)Vf(e,l,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}switch(a){case"forwards":for(l=t.child,a=null;l!==null;)e=l.alternate,e!==null&&Ai(e)===null&&(a=l),l=l.sibling;l=a,l===null?(a=t.child,t.child=null):(a=l.sibling,l.sibling=null),ec(t,!1,a,l,i,n);break;case"backwards":case"unstable_legacy-backwards":for(l=null,a=t.child,t.child=null;a!==null;){if(e=a.alternate,e!==null&&Ai(e)===null){t.child=a;break}e=a.sibling,a.sibling=l,l=a,a=e}ec(t,!0,l,null,i,n);break;case"together":ec(t,!1,null,null,void 0,n);break;default:t.memoizedState=null}return t.child}function el(e,t,l){if(e!==null&&(t.dependencies=e.dependencies),Nl|=t.lanes,(l&t.childLanes)===0)if(e!==null){if(En(e,t,l,!1),(l&t.childLanes)===0)return null}else return null;if(e!==null&&t.child!==e.child)throw Error(r(153));if(t.child!==null){for(e=t.child,l=Jt(e,e.pendingProps),t.child=l,l.return=t;e.sibling!==null;)e=e.sibling,l=l.sibling=Jt(e,e.pendingProps),l.return=t;l.sibling=null}return t.child}function tc(e,t){return(e.lanes&t)!==0?!0:(e=e.dependencies,!!(e!==null&&bi(e)))}function Qv(e,t,l){switch(t.tag){case 3:Ie(t,t.stateNode.containerInfo),gl(t,ke,e.memoizedState.cache),Kl();break;case 27:case 5:Zn(t);break;case 4:Ie(t,t.stateNode.containerInfo);break;case 10:gl(t,t.type,t.memoizedProps.value);break;case 31:if(t.memoizedState!==null)return t.flags|=128,Ns(t),null;break;case 13:var n=t.memoizedState;if(n!==null)return n.dehydrated!==null?(jl(t),t.flags|=128,null):(l&t.child.childLanes)!==0?Gf(e,t,l):(jl(t),e=el(e,t,l),e!==null?e.sibling:null);jl(t);break;case 19:var a=(e.flags&128)!==0;if(n=(l&t.childLanes)!==0,n||(En(e,t,l,!1),n=(l&t.childLanes)!==0),a){if(n)return Xf(e,t,l);t.flags|=128}if(a=t.memoizedState,a!==null&&(a.rendering=null,a.tail=null,a.lastEffect=null),J(Oe,Oe.current),n)break;return null;case 22:return t.lanes=0,kf(e,t,l,t.pendingProps);case 24:gl(t,ke,e.memoizedState.cache)}return el(e,t,l)}function Qf(e,t,l){if(e!==null)if(e.memoizedProps!==t.pendingProps)Be=!0;else{if(!tc(e,l)&&(t.flags&128)===0)return Be=!1,Qv(e,t,l);Be=(e.flags&131072)!==0}else Be=!1,fe&&(t.flags&1048576)!==0&&jo(t,sa,t.index);switch(t.lanes=0,t.tag){case 16:e:{var n=t.pendingProps;if(e=Wl(t.elementType),t.type=e,typeof e=="function")us(e)?(n=tn(e,n),t.tag=1,t=qf(null,t,e,n,l)):(t.tag=0,t=Js(null,t,e,n,l));else{if(e!=null){var a=e.$$typeof;if(a===O){t.tag=11,t=Of(null,t,e,n,l);break e}else if(a===Q){t.tag=14,t=Df(null,t,e,n,l);break e}}throw t=xt(e)||e,Error(r(306,t,""))}}return t;case 0:return Js(e,t,t.type,t.pendingProps,l);case 1:return n=t.type,a=tn(n,t.pendingProps),qf(e,t,n,a,l);case 3:e:{if(Ie(t,t.stateNode.containerInfo),e===null)throw Error(r(387));n=t.pendingProps;var i=t.memoizedState;a=i.element,Ss(e,t),va(t,n,null,l);var o=t.memoizedState;if(n=o.cache,gl(t,ke,n),n!==i.cache&&vs(t,[ke],l,!0),ma(),n=o.element,i.isDehydrated)if(i={element:n,isDehydrated:!1,cache:o.cache},t.updateQueue.baseState=i,t.memoizedState=i,t.flags&256){t=Yf(e,t,n,l);break e}else if(n!==a){a=Tt(Error(r(424)),t),ca(a),t=Yf(e,t,n,l);break e}else{switch(e=t.stateNode.containerInfo,e.nodeType){case 9:e=e.body;break;default:e=e.nodeName==="HTML"?e.ownerDocument.body:e}for(Ne=wt(e.firstChild),Xe=t,fe=!0,yl=null,At=!0,l=Uo(t,null,n,l),t.child=l;l;)l.flags=l.flags&-3|4096,l=l.sibling}else{if(Kl(),n===a){t=el(e,t,l);break e}Ze(e,t,n,l)}t=t.child}return t;case 26:return Bi(e,t),e===null?(l=lh(t.type,null,t.pendingProps,null))?t.memoizedState=l:fe||(l=t.type,e=t.pendingProps,n=tu(ue.current).createElement(l),n[Ve]=t,n[lt]=e,Ke(n,l,e),Ye(n),t.stateNode=n):t.memoizedState=lh(t.type,e.memoizedProps,t.pendingProps,e.memoizedState),null;case 27:return Zn(t),e===null&&fe&&(n=t.stateNode=Pd(t.type,t.pendingProps,ue.current),Xe=t,At=!0,a=Ne,Cl(t.type)?(Dc=a,Ne=wt(n.firstChild)):Ne=a),Ze(e,t,t.pendingProps.children,l),Bi(e,t),e===null&&(t.flags|=4194304),t.child;case 5:return e===null&&fe&&((a=n=Ne)&&(n=Sy(n,t.type,t.pendingProps,At),n!==null?(t.stateNode=n,Xe=t,Ne=wt(n.firstChild),At=!1,a=!0):a=!1),a||pl(t)),Zn(t),a=t.type,i=t.pendingProps,o=e!==null?e.memoizedProps:null,n=i.children,wc(a,i)?n=null:o!==null&&wc(a,o)&&(t.flags|=32),t.memoizedState!==null&&(a=Rs(e,t,kv,null,null,l),Ua._currentValue=a),Bi(e,t),Ze(e,t,n,l),t.child;case 6:return e===null&&fe&&((e=l=Ne)&&(l=jy(l,t.pendingProps,At),l!==null?(t.stateNode=l,Xe=t,Ne=null,e=!0):e=!1),e||pl(t)),null;case 13:return Gf(e,t,l);case 4:return Ie(t,t.stateNode.containerInfo),n=t.pendingProps,e===null?t.child=Pl(t,null,n,l):Ze(e,t,n,l),t.child;case 11:return Of(e,t,t.type,t.pendingProps,l);case 7:return Ze(e,t,t.pendingProps,l),t.child;case 8:return Ze(e,t,t.pendingProps.children,l),t.child;case 12:return Ze(e,t,t.pendingProps.children,l),t.child;case 10:return n=t.pendingProps,gl(t,t.type,n.value),Ze(e,t,n.children,l),t.child;case 9:return a=t.type._context,n=t.pendingProps.children,$l(t),a=Qe(a),n=n(a),t.flags|=1,Ze(e,t,n,l),t.child;case 14:return Df(e,t,t.type,t.pendingProps,l);case 15:return Uf(e,t,t.type,t.pendingProps,l);case 19:return Xf(e,t,l);case 31:return Xv(e,t,l);case 22:return kf(e,t,l,t.pendingProps);case 24:return $l(t),n=Qe(ke),e===null?(a=gs(),a===null&&(a=Te,i=ys(),a.pooledCache=i,i.refCount++,i!==null&&(a.pooledCacheLanes|=l),a=i),t.memoizedState={parent:n,cache:a},xs(t),gl(t,ke,a)):((e.lanes&l)!==0&&(Ss(e,t),va(t,null,null,l),ma()),a=e.memoizedState,i=t.memoizedState,a.parent!==n?(a={parent:n,cache:n},t.memoizedState=a,t.lanes===0&&(t.memoizedState=t.updateQueue.baseState=a),gl(t,ke,n)):(n=i.cache,gl(t,ke,n),n!==a.cache&&vs(t,[ke],l,!0))),Ze(e,t,t.pendingProps.children,l),t.child;case 29:throw t.pendingProps}throw Error(r(156,t.tag))}function tl(e){e.flags|=4}function lc(e,t,l,n,a){if((t=(e.mode&32)!==0)&&(t=!1),t){if(e.flags|=16777216,(a&335544128)===a)if(e.stateNode.complete)e.flags|=8192;else if(gd())e.flags|=8192;else throw Il=Ei,bs}else e.flags&=-16777217}function Zf(e,t){if(t.type!=="stylesheet"||(t.state.loading&4)!==0)e.flags&=-16777217;else if(e.flags|=16777216,!sh(t))if(gd())e.flags|=8192;else throw Il=Ei,bs}function qi(e,t){t!==null&&(e.flags|=4),e.flags&16384&&(t=e.tag!==22?Er():536870912,e.lanes|=t,Un|=t)}function Sa(e,t){if(!fe)switch(e.tailMode){case"hidden":t=e.tail;for(var l=null;t!==null;)t.alternate!==null&&(l=t),t=t.sibling;l===null?e.tail=null:l.sibling=null;break;case"collapsed":l=e.tail;for(var n=null;l!==null;)l.alternate!==null&&(n=l),l=l.sibling;n===null?t||e.tail===null?e.tail=null:e.tail.sibling=null:n.sibling=null}}function Ae(e){var t=e.alternate!==null&&e.alternate.child===e.child,l=0,n=0;if(t)for(var a=e.child;a!==null;)l|=a.lanes|a.childLanes,n|=a.subtreeFlags&65011712,n|=a.flags&65011712,a.return=e,a=a.sibling;else for(a=e.child;a!==null;)l|=a.lanes|a.childLanes,n|=a.subtreeFlags,n|=a.flags,a.return=e,a=a.sibling;return e.subtreeFlags|=n,e.childLanes=l,t}function Zv(e,t,l){var n=t.pendingProps;switch(os(t),t.tag){case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return Ae(t),null;case 1:return Ae(t),null;case 3:return l=t.stateNode,n=null,e!==null&&(n=e.memoizedState.cache),t.memoizedState.cache!==n&&(t.flags|=2048),Wt(ke),Me(),l.pendingContext&&(l.context=l.pendingContext,l.pendingContext=null),(e===null||e.child===null)&&(jn(t)?tl(t):e===null||e.memoizedState.isDehydrated&&(t.flags&256)===0||(t.flags|=1024,ds())),Ae(t),null;case 26:var a=t.type,i=t.memoizedState;return e===null?(tl(t),i!==null?(Ae(t),Zf(t,i)):(Ae(t),lc(t,a,null,n,l))):i?i!==e.memoizedState?(tl(t),Ae(t),Zf(t,i)):(Ae(t),t.flags&=-16777217):(e=e.memoizedProps,e!==n&&tl(t),Ae(t),lc(t,a,e,n,l)),null;case 27:if(Wa(t),l=ue.current,a=t.type,e!==null&&t.stateNode!=null)e.memoizedProps!==n&&tl(t);else{if(!n){if(t.stateNode===null)throw Error(r(166));return Ae(t),null}e=F.current,jn(t)?To(t):(e=Pd(a,n,l),t.stateNode=e,tl(t))}return Ae(t),null;case 5:if(Wa(t),a=t.type,e!==null&&t.stateNode!=null)e.memoizedProps!==n&&tl(t);else{if(!n){if(t.stateNode===null)throw Error(r(166));return Ae(t),null}if(i=F.current,jn(t))To(t);else{var o=tu(ue.current);switch(i){case 1:i=o.createElementNS("http://www.w3.org/2000/svg",a);break;case 2:i=o.createElementNS("http://www.w3.org/1998/Math/MathML",a);break;default:switch(a){case"svg":i=o.createElementNS("http://www.w3.org/2000/svg",a);break;case"math":i=o.createElementNS("http://www.w3.org/1998/Math/MathML",a);break;case"script":i=o.createElement("div"),i.innerHTML="<script><\/script>",i=i.removeChild(i.firstChild);break;case"select":i=typeof n.is=="string"?o.createElement("select",{is:n.is}):o.createElement("select"),n.multiple?i.multiple=!0:n.size&&(i.size=n.size);break;default:i=typeof n.is=="string"?o.createElement(a,{is:n.is}):o.createElement(a)}}i[Ve]=t,i[lt]=n;e:for(o=t.child;o!==null;){if(o.tag===5||o.tag===6)i.appendChild(o.stateNode);else if(o.tag!==4&&o.tag!==27&&o.child!==null){o.child.return=o,o=o.child;continue}if(o===t)break e;for(;o.sibling===null;){if(o.return===null||o.return===t)break e;o=o.return}o.sibling.return=o.return,o=o.sibling}t.stateNode=i;e:switch(Ke(i,a,n),a){case"button":case"input":case"select":case"textarea":n=!!n.autoFocus;break e;case"img":n=!0;break e;default:n=!1}n&&tl(t)}}return Ae(t),lc(t,t.type,e===null?null:e.memoizedProps,t.pendingProps,l),null;case 6:if(e&&t.stateNode!=null)e.memoizedProps!==n&&tl(t);else{if(typeof n!="string"&&t.stateNode===null)throw Error(r(166));if(e=ue.current,jn(t)){if(e=t.stateNode,l=t.memoizedProps,n=null,a=Xe,a!==null)switch(a.tag){case 27:case 5:n=a.memoizedProps}e[Ve]=t,e=!!(e.nodeValue===l||n!==null&&n.suppressHydrationWarning===!0||Gd(e.nodeValue,l)),e||pl(t,!0)}else e=tu(e).createTextNode(n),e[Ve]=t,t.stateNode=e}return Ae(t),null;case 31:if(l=t.memoizedState,e===null||e.memoizedState!==null){if(n=jn(t),l!==null){if(e===null){if(!n)throw Error(r(318));if(e=t.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(r(557));e[Ve]=t}else Kl(),(t.flags&128)===0&&(t.memoizedState=null),t.flags|=4;Ae(t),e=!1}else l=ds(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=l),e=!0;if(!e)return t.flags&256?(yt(t),t):(yt(t),null);if((t.flags&128)!==0)throw Error(r(558))}return Ae(t),null;case 13:if(n=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(a=jn(t),n!==null&&n.dehydrated!==null){if(e===null){if(!a)throw Error(r(318));if(a=t.memoizedState,a=a!==null?a.dehydrated:null,!a)throw Error(r(317));a[Ve]=t}else Kl(),(t.flags&128)===0&&(t.memoizedState=null),t.flags|=4;Ae(t),a=!1}else a=ds(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=a),a=!0;if(!a)return t.flags&256?(yt(t),t):(yt(t),null)}return yt(t),(t.flags&128)!==0?(t.lanes=l,t):(l=n!==null,e=e!==null&&e.memoizedState!==null,l&&(n=t.child,a=null,n.alternate!==null&&n.alternate.memoizedState!==null&&n.alternate.memoizedState.cachePool!==null&&(a=n.alternate.memoizedState.cachePool.pool),i=null,n.memoizedState!==null&&n.memoizedState.cachePool!==null&&(i=n.memoizedState.cachePool.pool),i!==a&&(n.flags|=2048)),l!==e&&l&&(t.child.flags|=8192),qi(t,t.updateQueue),Ae(t),null);case 4:return Me(),e===null&&Tc(t.stateNode.containerInfo),Ae(t),null;case 10:return Wt(t.type),Ae(t),null;case 19:if(B(Oe),n=t.memoizedState,n===null)return Ae(t),null;if(a=(t.flags&128)!==0,i=n.rendering,i===null)if(a)Sa(n,!1);else{if(Ce!==0||e!==null&&(e.flags&128)!==0)for(e=t.child;e!==null;){if(i=Ai(e),i!==null){for(t.flags|=128,Sa(n,!1),e=i.updateQueue,t.updateQueue=e,qi(t,e),t.subtreeFlags=0,e=l,l=t.child;l!==null;)bo(l,e),l=l.sibling;return J(Oe,Oe.current&1|2),fe&&$t(t,n.treeForkCount),t.child}e=e.sibling}n.tail!==null&&ot()>Qi&&(t.flags|=128,a=!0,Sa(n,!1),t.lanes=4194304)}else{if(!a)if(e=Ai(i),e!==null){if(t.flags|=128,a=!0,e=e.updateQueue,t.updateQueue=e,qi(t,e),Sa(n,!0),n.tail===null&&n.tailMode==="hidden"&&!i.alternate&&!fe)return Ae(t),null}else 2*ot()-n.renderingStartTime>Qi&&l!==536870912&&(t.flags|=128,a=!0,Sa(n,!1),t.lanes=4194304);n.isBackwards?(i.sibling=t.child,t.child=i):(e=n.last,e!==null?e.sibling=i:t.child=i,n.last=i)}return n.tail!==null?(e=n.tail,n.rendering=e,n.tail=e.sibling,n.renderingStartTime=ot(),e.sibling=null,l=Oe.current,J(Oe,a?l&1|2:l&1),fe&&$t(t,n.treeForkCount),e):(Ae(t),null);case 22:case 23:return yt(t),_s(),n=t.memoizedState!==null,e!==null?e.memoizedState!==null!==n&&(t.flags|=8192):n&&(t.flags|=8192),n?(l&536870912)!==0&&(t.flags&128)===0&&(Ae(t),t.subtreeFlags&6&&(t.flags|=8192)):Ae(t),l=t.updateQueue,l!==null&&qi(t,l.retryQueue),l=null,e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(l=e.memoizedState.cachePool.pool),n=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(n=t.memoizedState.cachePool.pool),n!==l&&(t.flags|=2048),e!==null&&B(Fl),null;case 24:return l=null,e!==null&&(l=e.memoizedState.cache),t.memoizedState.cache!==l&&(t.flags|=2048),Wt(ke),Ae(t),null;case 25:return null;case 30:return null}throw Error(r(156,t.tag))}function Kv(e,t){switch(os(t),t.tag){case 1:return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return Wt(ke),Me(),e=t.flags,(e&65536)!==0&&(e&128)===0?(t.flags=e&-65537|128,t):null;case 26:case 27:case 5:return Wa(t),null;case 31:if(t.memoizedState!==null){if(yt(t),t.alternate===null)throw Error(r(340));Kl()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 13:if(yt(t),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(r(340));Kl()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return B(Oe),null;case 4:return Me(),null;case 10:return Wt(t.type),null;case 22:case 23:return yt(t),_s(),e!==null&&B(Fl),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 24:return Wt(ke),null;case 25:return null;default:return null}}function Kf(e,t){switch(os(t),t.tag){case 3:Wt(ke),Me();break;case 26:case 27:case 5:Wa(t);break;case 4:Me();break;case 31:t.memoizedState!==null&&yt(t);break;case 13:yt(t);break;case 19:B(Oe);break;case 10:Wt(t.type);break;case 22:case 23:yt(t),_s(),e!==null&&B(Fl);break;case 24:Wt(ke)}}function ja(e,t){try{var l=t.updateQueue,n=l!==null?l.lastEffect:null;if(n!==null){var a=n.next;l=a;do{if((l.tag&e)===e){n=void 0;var i=l.create,o=l.inst;n=i(),o.destroy=n}l=l.next}while(l!==a)}}catch(d){ge(t,t.return,d)}}function Tl(e,t,l){try{var n=t.updateQueue,a=n!==null?n.lastEffect:null;if(a!==null){var i=a.next;n=i;do{if((n.tag&e)===e){var o=n.inst,d=o.destroy;if(d!==void 0){o.destroy=void 0,a=t;var g=l,A=d;try{A()}catch(C){ge(a,g,C)}}}n=n.next}while(n!==i)}}catch(C){ge(t,t.return,C)}}function Jf(e){var t=e.updateQueue;if(t!==null){var l=e.stateNode;try{Ho(t,l)}catch(n){ge(e,e.return,n)}}}function $f(e,t,l){l.props=tn(e.type,e.memoizedProps),l.state=e.memoizedState;try{l.componentWillUnmount()}catch(n){ge(e,t,n)}}function Ea(e,t){try{var l=e.ref;if(l!==null){switch(e.tag){case 26:case 27:case 5:var n=e.stateNode;break;case 30:n=e.stateNode;break;default:n=e.stateNode}typeof l=="function"?e.refCleanup=l(n):l.current=n}}catch(a){ge(e,t,a)}}function qt(e,t){var l=e.ref,n=e.refCleanup;if(l!==null)if(typeof n=="function")try{n()}catch(a){ge(e,t,a)}finally{e.refCleanup=null,e=e.alternate,e!=null&&(e.refCleanup=null)}else if(typeof l=="function")try{l(null)}catch(a){ge(e,t,a)}else l.current=null}function Ff(e){var t=e.type,l=e.memoizedProps,n=e.stateNode;try{e:switch(t){case"button":case"input":case"select":case"textarea":l.autoFocus&&n.focus();break e;case"img":l.src?n.src=l.src:l.srcSet&&(n.srcset=l.srcSet)}}catch(a){ge(e,e.return,a)}}function nc(e,t,l){try{var n=e.stateNode;vy(n,e.type,l,t),n[lt]=t}catch(a){ge(e,e.return,a)}}function Wf(e){return e.tag===5||e.tag===3||e.tag===26||e.tag===27&&Cl(e.type)||e.tag===4}function ac(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||Wf(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.tag===27&&Cl(e.type)||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 ic(e,t,l){var n=e.tag;if(n===5||n===6)e=e.stateNode,t?(l.nodeType===9?l.body:l.nodeName==="HTML"?l.ownerDocument.body:l).insertBefore(e,t):(t=l.nodeType===9?l.body:l.nodeName==="HTML"?l.ownerDocument.body:l,t.appendChild(e),l=l._reactRootContainer,l!=null||t.onclick!==null||(t.onclick=Zt));else if(n!==4&&(n===27&&Cl(e.type)&&(l=e.stateNode,t=null),e=e.child,e!==null))for(ic(e,t,l),e=e.sibling;e!==null;)ic(e,t,l),e=e.sibling}function Yi(e,t,l){var n=e.tag;if(n===5||n===6)e=e.stateNode,t?l.insertBefore(e,t):l.appendChild(e);else if(n!==4&&(n===27&&Cl(e.type)&&(l=e.stateNode),e=e.child,e!==null))for(Yi(e,t,l),e=e.sibling;e!==null;)Yi(e,t,l),e=e.sibling}function If(e){var t=e.stateNode,l=e.memoizedProps;try{for(var n=e.type,a=t.attributes;a.length;)t.removeAttributeNode(a[0]);Ke(t,n,l),t[Ve]=e,t[lt]=l}catch(i){ge(e,e.return,i)}}var ll=!1,Le=!1,uc=!1,Pf=typeof WeakSet=="function"?WeakSet:Set,Ge=null;function Jv(e,t){if(e=e.containerInfo,Ac=cu,e=ro(e),Pu(e)){if("selectionStart"in e)var l={start:e.selectionStart,end:e.selectionEnd};else e:{l=(l=e.ownerDocument)&&l.defaultView||window;var n=l.getSelection&&l.getSelection();if(n&&n.rangeCount!==0){l=n.anchorNode;var a=n.anchorOffset,i=n.focusNode;n=n.focusOffset;try{l.nodeType,i.nodeType}catch{l=null;break e}var o=0,d=-1,g=-1,A=0,C=0,H=e,w=null;t:for(;;){for(var z;H!==l||a!==0&&H.nodeType!==3||(d=o+a),H!==i||n!==0&&H.nodeType!==3||(g=o+n),H.nodeType===3&&(o+=H.nodeValue.length),(z=H.firstChild)!==null;)w=H,H=z;for(;;){if(H===e)break t;if(w===l&&++A===a&&(d=o),w===i&&++C===n&&(g=o),(z=H.nextSibling)!==null)break;H=w,w=H.parentNode}H=z}l=d===-1||g===-1?null:{start:d,end:g}}else l=null}l=l||{start:0,end:0}}else l=null;for(Rc={focusedElem:e,selectionRange:l},cu=!1,Ge=t;Ge!==null;)if(t=Ge,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,Ge=e;else for(;Ge!==null;){switch(t=Ge,i=t.alternate,e=t.flags,t.tag){case 0:if((e&4)!==0&&(e=t.updateQueue,e=e!==null?e.events:null,e!==null))for(l=0;l<e.length;l++)a=e[l],a.ref.impl=a.nextImpl;break;case 11:case 15:break;case 1:if((e&1024)!==0&&i!==null){e=void 0,l=t,a=i.memoizedProps,i=i.memoizedState,n=l.stateNode;try{var $=tn(l.type,a);e=n.getSnapshotBeforeUpdate($,i),n.__reactInternalSnapshotBeforeUpdate=e}catch(P){ge(l,l.return,P)}}break;case 3:if((e&1024)!==0){if(e=t.stateNode.containerInfo,l=e.nodeType,l===9)Cc(e);else if(l===1)switch(e.nodeName){case"HEAD":case"HTML":case"BODY":Cc(e);break;default:e.textContent=""}}break;case 5:case 26:case 27:case 6:case 4:case 17:break;default:if((e&1024)!==0)throw Error(r(163))}if(e=t.sibling,e!==null){e.return=t.return,Ge=e;break}Ge=t.return}}function ed(e,t,l){var n=l.flags;switch(l.tag){case 0:case 11:case 15:al(e,l),n&4&&ja(5,l);break;case 1:if(al(e,l),n&4)if(e=l.stateNode,t===null)try{e.componentDidMount()}catch(o){ge(l,l.return,o)}else{var a=tn(l.type,t.memoizedProps);t=t.memoizedState;try{e.componentDidUpdate(a,t,e.__reactInternalSnapshotBeforeUpdate)}catch(o){ge(l,l.return,o)}}n&64&&Jf(l),n&512&&Ea(l,l.return);break;case 3:if(al(e,l),n&64&&(e=l.updateQueue,e!==null)){if(t=null,l.child!==null)switch(l.child.tag){case 27:case 5:t=l.child.stateNode;break;case 1:t=l.child.stateNode}try{Ho(e,t)}catch(o){ge(l,l.return,o)}}break;case 27:t===null&&n&4&&If(l);case 26:case 5:al(e,l),t===null&&n&4&&Ff(l),n&512&&Ea(l,l.return);break;case 12:al(e,l);break;case 31:al(e,l),n&4&&nd(e,l);break;case 13:al(e,l),n&4&&ad(e,l),n&64&&(e=l.memoizedState,e!==null&&(e=e.dehydrated,e!==null&&(l=ny.bind(null,l),Ey(e,l))));break;case 22:if(n=l.memoizedState!==null||ll,!n){t=t!==null&&t.memoizedState!==null||Le,a=ll;var i=Le;ll=n,(Le=t)&&!i?il(e,l,(l.subtreeFlags&8772)!==0):al(e,l),ll=a,Le=i}break;case 30:break;default:al(e,l)}}function td(e){var t=e.alternate;t!==null&&(e.alternate=null,td(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&ku(t)),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}var Re=null,at=!1;function nl(e,t,l){for(l=l.child;l!==null;)ld(e,t,l),l=l.sibling}function ld(e,t,l){if(ft&&typeof ft.onCommitFiberUnmount=="function")try{ft.onCommitFiberUnmount(Kn,l)}catch{}switch(l.tag){case 26:Le||qt(l,t),nl(e,t,l),l.memoizedState?l.memoizedState.count--:l.stateNode&&(l=l.stateNode,l.parentNode.removeChild(l));break;case 27:Le||qt(l,t);var n=Re,a=at;Cl(l.type)&&(Re=l.stateNode,at=!1),nl(e,t,l),Ma(l.stateNode),Re=n,at=a;break;case 5:Le||qt(l,t);case 6:if(n=Re,a=at,Re=null,nl(e,t,l),Re=n,at=a,Re!==null)if(at)try{(Re.nodeType===9?Re.body:Re.nodeName==="HTML"?Re.ownerDocument.body:Re).removeChild(l.stateNode)}catch(i){ge(l,t,i)}else try{Re.removeChild(l.stateNode)}catch(i){ge(l,t,i)}break;case 18:Re!==null&&(at?(e=Re,Jd(e.nodeType===9?e.body:e.nodeName==="HTML"?e.ownerDocument.body:e,l.stateNode),Vn(e)):Jd(Re,l.stateNode));break;case 4:n=Re,a=at,Re=l.stateNode.containerInfo,at=!0,nl(e,t,l),Re=n,at=a;break;case 0:case 11:case 14:case 15:Tl(2,l,t),Le||Tl(4,l,t),nl(e,t,l);break;case 1:Le||(qt(l,t),n=l.stateNode,typeof n.componentWillUnmount=="function"&&$f(l,t,n)),nl(e,t,l);break;case 21:nl(e,t,l);break;case 22:Le=(n=Le)||l.memoizedState!==null,nl(e,t,l),Le=n;break;default:nl(e,t,l)}}function nd(e,t){if(t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null))){e=e.dehydrated;try{Vn(e)}catch(l){ge(t,t.return,l)}}}function ad(e,t){if(t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null&&(e=e.dehydrated,e!==null))))try{Vn(e)}catch(l){ge(t,t.return,l)}}function $v(e){switch(e.tag){case 31:case 13:case 19:var t=e.stateNode;return t===null&&(t=e.stateNode=new Pf),t;case 22:return e=e.stateNode,t=e._retryCache,t===null&&(t=e._retryCache=new Pf),t;default:throw Error(r(435,e.tag))}}function Gi(e,t){var l=$v(e);t.forEach(function(n){if(!l.has(n)){l.add(n);var a=ay.bind(null,e,n);n.then(a,a)}})}function it(e,t){var l=t.deletions;if(l!==null)for(var n=0;n<l.length;n++){var a=l[n],i=e,o=t,d=o;e:for(;d!==null;){switch(d.tag){case 27:if(Cl(d.type)){Re=d.stateNode,at=!1;break e}break;case 5:Re=d.stateNode,at=!1;break e;case 3:case 4:Re=d.stateNode.containerInfo,at=!0;break e}d=d.return}if(Re===null)throw Error(r(160));ld(i,o,a),Re=null,at=!1,i=a.alternate,i!==null&&(i.return=null),a.return=null}if(t.subtreeFlags&13886)for(t=t.child;t!==null;)id(t,e),t=t.sibling}var Dt=null;function id(e,t){var l=e.alternate,n=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:it(t,e),ut(e),n&4&&(Tl(3,e,e.return),ja(3,e),Tl(5,e,e.return));break;case 1:it(t,e),ut(e),n&512&&(Le||l===null||qt(l,l.return)),n&64&&ll&&(e=e.updateQueue,e!==null&&(n=e.callbacks,n!==null&&(l=e.shared.hiddenCallbacks,e.shared.hiddenCallbacks=l===null?n:l.concat(n))));break;case 26:var a=Dt;if(it(t,e),ut(e),n&512&&(Le||l===null||qt(l,l.return)),n&4){var i=l!==null?l.memoizedState:null;if(n=e.memoizedState,l===null)if(n===null)if(e.stateNode===null){e:{n=e.type,l=e.memoizedProps,a=a.ownerDocument||a;t:switch(n){case"title":i=a.getElementsByTagName("title")[0],(!i||i[Fn]||i[Ve]||i.namespaceURI==="http://www.w3.org/2000/svg"||i.hasAttribute("itemprop"))&&(i=a.createElement(n),a.head.insertBefore(i,a.querySelector("head > title"))),Ke(i,n,l),i[Ve]=e,Ye(i),n=i;break e;case"link":var o=ih("link","href",a).get(n+(l.href||""));if(o){for(var d=0;d<o.length;d++)if(i=o[d],i.getAttribute("href")===(l.href==null||l.href===""?null:l.href)&&i.getAttribute("rel")===(l.rel==null?null:l.rel)&&i.getAttribute("title")===(l.title==null?null:l.title)&&i.getAttribute("crossorigin")===(l.crossOrigin==null?null:l.crossOrigin)){o.splice(d,1);break t}}i=a.createElement(n),Ke(i,n,l),a.head.appendChild(i);break;case"meta":if(o=ih("meta","content",a).get(n+(l.content||""))){for(d=0;d<o.length;d++)if(i=o[d],i.getAttribute("content")===(l.content==null?null:""+l.content)&&i.getAttribute("name")===(l.name==null?null:l.name)&&i.getAttribute("property")===(l.property==null?null:l.property)&&i.getAttribute("http-equiv")===(l.httpEquiv==null?null:l.httpEquiv)&&i.getAttribute("charset")===(l.charSet==null?null:l.charSet)){o.splice(d,1);break t}}i=a.createElement(n),Ke(i,n,l),a.head.appendChild(i);break;default:throw Error(r(468,n))}i[Ve]=e,Ye(i),n=i}e.stateNode=n}else uh(a,e.type,e.stateNode);else e.stateNode=ah(a,n,e.memoizedProps);else i!==n?(i===null?l.stateNode!==null&&(l=l.stateNode,l.parentNode.removeChild(l)):i.count--,n===null?uh(a,e.type,e.stateNode):ah(a,n,e.memoizedProps)):n===null&&e.stateNode!==null&&nc(e,e.memoizedProps,l.memoizedProps)}break;case 27:it(t,e),ut(e),n&512&&(Le||l===null||qt(l,l.return)),l!==null&&n&4&&nc(e,e.memoizedProps,l.memoizedProps);break;case 5:if(it(t,e),ut(e),n&512&&(Le||l===null||qt(l,l.return)),e.flags&32){a=e.stateNode;try{dn(a,"")}catch($){ge(e,e.return,$)}}n&4&&e.stateNode!=null&&(a=e.memoizedProps,nc(e,a,l!==null?l.memoizedProps:a)),n&1024&&(uc=!0);break;case 6:if(it(t,e),ut(e),n&4){if(e.stateNode===null)throw Error(r(162));n=e.memoizedProps,l=e.stateNode;try{l.nodeValue=n}catch($){ge(e,e.return,$)}}break;case 3:if(au=null,a=Dt,Dt=lu(t.containerInfo),it(t,e),Dt=a,ut(e),n&4&&l!==null&&l.memoizedState.isDehydrated)try{Vn(t.containerInfo)}catch($){ge(e,e.return,$)}uc&&(uc=!1,ud(e));break;case 4:n=Dt,Dt=lu(e.stateNode.containerInfo),it(t,e),ut(e),Dt=n;break;case 12:it(t,e),ut(e);break;case 31:it(t,e),ut(e),n&4&&(n=e.updateQueue,n!==null&&(e.updateQueue=null,Gi(e,n)));break;case 13:it(t,e),ut(e),e.child.flags&8192&&e.memoizedState!==null!=(l!==null&&l.memoizedState!==null)&&(Xi=ot()),n&4&&(n=e.updateQueue,n!==null&&(e.updateQueue=null,Gi(e,n)));break;case 22:a=e.memoizedState!==null;var g=l!==null&&l.memoizedState!==null,A=ll,C=Le;if(ll=A||a,Le=C||g,it(t,e),Le=C,ll=A,ut(e),n&8192)e:for(t=e.stateNode,t._visibility=a?t._visibility&-2:t._visibility|1,a&&(l===null||g||ll||Le||ln(e)),l=null,t=e;;){if(t.tag===5||t.tag===26){if(l===null){g=l=t;try{if(i=g.stateNode,a)o=i.style,typeof o.setProperty=="function"?o.setProperty("display","none","important"):o.display="none";else{d=g.stateNode;var H=g.memoizedProps.style,w=H!=null&&H.hasOwnProperty("display")?H.display:null;d.style.display=w==null||typeof w=="boolean"?"":(""+w).trim()}}catch($){ge(g,g.return,$)}}}else if(t.tag===6){if(l===null){g=t;try{g.stateNode.nodeValue=a?"":g.memoizedProps}catch($){ge(g,g.return,$)}}}else if(t.tag===18){if(l===null){g=t;try{var z=g.stateNode;a?$d(z,!0):$d(g.stateNode,!1)}catch($){ge(g,g.return,$)}}}else if((t.tag!==22&&t.tag!==23||t.memoizedState===null||t===e)&&t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break e;for(;t.sibling===null;){if(t.return===null||t.return===e)break e;l===t&&(l=null),t=t.return}l===t&&(l=null),t.sibling.return=t.return,t=t.sibling}n&4&&(n=e.updateQueue,n!==null&&(l=n.retryQueue,l!==null&&(n.retryQueue=null,Gi(e,l))));break;case 19:it(t,e),ut(e),n&4&&(n=e.updateQueue,n!==null&&(e.updateQueue=null,Gi(e,n)));break;case 30:break;case 21:break;default:it(t,e),ut(e)}}function ut(e){var t=e.flags;if(t&2){try{for(var l,n=e.return;n!==null;){if(Wf(n)){l=n;break}n=n.return}if(l==null)throw Error(r(160));switch(l.tag){case 27:var a=l.stateNode,i=ac(e);Yi(e,i,a);break;case 5:var o=l.stateNode;l.flags&32&&(dn(o,""),l.flags&=-33);var d=ac(e);Yi(e,d,o);break;case 3:case 4:var g=l.stateNode.containerInfo,A=ac(e);ic(e,A,g);break;default:throw Error(r(161))}}catch(C){ge(e,e.return,C)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function ud(e){if(e.subtreeFlags&1024)for(e=e.child;e!==null;){var t=e;ud(t),t.tag===5&&t.flags&1024&&t.stateNode.reset(),e=e.sibling}}function al(e,t){if(t.subtreeFlags&8772)for(t=t.child;t!==null;)ed(e,t.alternate,t),t=t.sibling}function ln(e){for(e=e.child;e!==null;){var t=e;switch(t.tag){case 0:case 11:case 14:case 15:Tl(4,t,t.return),ln(t);break;case 1:qt(t,t.return);var l=t.stateNode;typeof l.componentWillUnmount=="function"&&$f(t,t.return,l),ln(t);break;case 27:Ma(t.stateNode);case 26:case 5:qt(t,t.return),ln(t);break;case 22:t.memoizedState===null&&ln(t);break;case 30:ln(t);break;default:ln(t)}e=e.sibling}}function il(e,t,l){for(l=l&&(t.subtreeFlags&8772)!==0,t=t.child;t!==null;){var n=t.alternate,a=e,i=t,o=i.flags;switch(i.tag){case 0:case 11:case 15:il(a,i,l),ja(4,i);break;case 1:if(il(a,i,l),n=i,a=n.stateNode,typeof a.componentDidMount=="function")try{a.componentDidMount()}catch(A){ge(n,n.return,A)}if(n=i,a=n.updateQueue,a!==null){var d=n.stateNode;try{var g=a.shared.hiddenCallbacks;if(g!==null)for(a.shared.hiddenCallbacks=null,a=0;a<g.length;a++)ko(g[a],d)}catch(A){ge(n,n.return,A)}}l&&o&64&&Jf(i),Ea(i,i.return);break;case 27:If(i);case 26:case 5:il(a,i,l),l&&n===null&&o&4&&Ff(i),Ea(i,i.return);break;case 12:il(a,i,l);break;case 31:il(a,i,l),l&&o&4&&nd(a,i);break;case 13:il(a,i,l),l&&o&4&&ad(a,i);break;case 22:i.memoizedState===null&&il(a,i,l),Ea(i,i.return);break;case 30:break;default:il(a,i,l)}t=t.sibling}}function sc(e,t){var l=null;e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(l=e.memoizedState.cachePool.pool),e=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(e=t.memoizedState.cachePool.pool),e!==l&&(e!=null&&e.refCount++,l!=null&&ra(l))}function cc(e,t){e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&ra(e))}function Ut(e,t,l,n){if(t.subtreeFlags&10256)for(t=t.child;t!==null;)sd(e,t,l,n),t=t.sibling}function sd(e,t,l,n){var a=t.flags;switch(t.tag){case 0:case 11:case 15:Ut(e,t,l,n),a&2048&&ja(9,t);break;case 1:Ut(e,t,l,n);break;case 3:Ut(e,t,l,n),a&2048&&(e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&ra(e)));break;case 12:if(a&2048){Ut(e,t,l,n),e=t.stateNode;try{var i=t.memoizedProps,o=i.id,d=i.onPostCommit;typeof d=="function"&&d(o,t.alternate===null?"mount":"update",e.passiveEffectDuration,-0)}catch(g){ge(t,t.return,g)}}else Ut(e,t,l,n);break;case 31:Ut(e,t,l,n);break;case 13:Ut(e,t,l,n);break;case 23:break;case 22:i=t.stateNode,o=t.alternate,t.memoizedState!==null?i._visibility&2?Ut(e,t,l,n):Ta(e,t):i._visibility&2?Ut(e,t,l,n):(i._visibility|=2,Mn(e,t,l,n,(t.subtreeFlags&10256)!==0||!1)),a&2048&&sc(o,t);break;case 24:Ut(e,t,l,n),a&2048&&cc(t.alternate,t);break;default:Ut(e,t,l,n)}}function Mn(e,t,l,n,a){for(a=a&&((t.subtreeFlags&10256)!==0||!1),t=t.child;t!==null;){var i=e,o=t,d=l,g=n,A=o.flags;switch(o.tag){case 0:case 11:case 15:Mn(i,o,d,g,a),ja(8,o);break;case 23:break;case 22:var C=o.stateNode;o.memoizedState!==null?C._visibility&2?Mn(i,o,d,g,a):Ta(i,o):(C._visibility|=2,Mn(i,o,d,g,a)),a&&A&2048&&sc(o.alternate,o);break;case 24:Mn(i,o,d,g,a),a&&A&2048&&cc(o.alternate,o);break;default:Mn(i,o,d,g,a)}t=t.sibling}}function Ta(e,t){if(t.subtreeFlags&10256)for(t=t.child;t!==null;){var l=e,n=t,a=n.flags;switch(n.tag){case 22:Ta(l,n),a&2048&&sc(n.alternate,n);break;case 24:Ta(l,n),a&2048&&cc(n.alternate,n);break;default:Ta(l,n)}t=t.sibling}}var _a=8192;function On(e,t,l){if(e.subtreeFlags&_a)for(e=e.child;e!==null;)cd(e,t,l),e=e.sibling}function cd(e,t,l){switch(e.tag){case 26:On(e,t,l),e.flags&_a&&e.memoizedState!==null&&Uy(l,Dt,e.memoizedState,e.memoizedProps);break;case 5:On(e,t,l);break;case 3:case 4:var n=Dt;Dt=lu(e.stateNode.containerInfo),On(e,t,l),Dt=n;break;case 22:e.memoizedState===null&&(n=e.alternate,n!==null&&n.memoizedState!==null?(n=_a,_a=16777216,On(e,t,l),_a=n):On(e,t,l));break;default:On(e,t,l)}}function rd(e){var t=e.alternate;if(t!==null&&(e=t.child,e!==null)){t.child=null;do t=e.sibling,e.sibling=null,e=t;while(e!==null)}}function Na(e){var t=e.deletions;if((e.flags&16)!==0){if(t!==null)for(var l=0;l<t.length;l++){var n=t[l];Ge=n,fd(n,e)}rd(e)}if(e.subtreeFlags&10256)for(e=e.child;e!==null;)od(e),e=e.sibling}function od(e){switch(e.tag){case 0:case 11:case 15:Na(e),e.flags&2048&&Tl(9,e,e.return);break;case 3:Na(e);break;case 12:Na(e);break;case 22:var t=e.stateNode;e.memoizedState!==null&&t._visibility&2&&(e.return===null||e.return.tag!==13)?(t._visibility&=-3,Vi(e)):Na(e);break;default:Na(e)}}function Vi(e){var t=e.deletions;if((e.flags&16)!==0){if(t!==null)for(var l=0;l<t.length;l++){var n=t[l];Ge=n,fd(n,e)}rd(e)}for(e=e.child;e!==null;){switch(t=e,t.tag){case 0:case 11:case 15:Tl(8,t,t.return),Vi(t);break;case 22:l=t.stateNode,l._visibility&2&&(l._visibility&=-3,Vi(t));break;default:Vi(t)}e=e.sibling}}function fd(e,t){for(;Ge!==null;){var l=Ge;switch(l.tag){case 0:case 11:case 15:Tl(8,l,t);break;case 23:case 22:if(l.memoizedState!==null&&l.memoizedState.cachePool!==null){var n=l.memoizedState.cachePool.pool;n!=null&&n.refCount++}break;case 24:ra(l.memoizedState.cache)}if(n=l.child,n!==null)n.return=l,Ge=n;else e:for(l=e;Ge!==null;){n=Ge;var a=n.sibling,i=n.return;if(td(n),n===l){Ge=null;break e}if(a!==null){a.return=i,Ge=a;break e}Ge=i}}}var Fv={getCacheForType:function(e){var t=Qe(ke),l=t.data.get(e);return l===void 0&&(l=e(),t.data.set(e,l)),l},cacheSignal:function(){return Qe(ke).controller.signal}},Wv=typeof WeakMap=="function"?WeakMap:Map,ve=0,Te=null,se=null,re=0,pe=0,pt=null,_l=!1,Dn=!1,rc=!1,ul=0,Ce=0,Nl=0,nn=0,oc=0,gt=0,Un=0,Aa=null,st=null,fc=!1,Xi=0,dd=0,Qi=1/0,Zi=null,Al=null,qe=0,Rl=null,kn=null,sl=0,dc=0,hc=null,hd=null,Ra=0,mc=null;function bt(){return(ve&2)!==0&&re!==0?re&-re:M.T!==null?xc():Ar()}function md(){if(gt===0)if((re&536870912)===0||fe){var e=ei;ei<<=1,(ei&3932160)===0&&(ei=262144),gt=e}else gt=536870912;return e=vt.current,e!==null&&(e.flags|=32),gt}function ct(e,t,l){(e===Te&&(pe===2||pe===9)||e.cancelPendingCommit!==null)&&(Hn(e,0),wl(e,re,gt,!1)),$n(e,l),((ve&2)===0||e!==Te)&&(e===Te&&((ve&2)===0&&(nn|=l),Ce===4&&wl(e,re,gt,!1)),Yt(e))}function vd(e,t,l){if((ve&6)!==0)throw Error(r(327));var n=!l&&(t&127)===0&&(t&e.expiredLanes)===0||Jn(e,t),a=n?ey(e,t):yc(e,t,!0),i=n;do{if(a===0){Dn&&!n&&wl(e,t,0,!1);break}else{if(l=e.current.alternate,i&&!Iv(l)){a=yc(e,t,!1),i=!1;continue}if(a===2){if(i=t,e.errorRecoveryDisabledLanes&i)var o=0;else o=e.pendingLanes&-536870913,o=o!==0?o:o&536870912?536870912:0;if(o!==0){t=o;e:{var d=e;a=Aa;var g=d.current.memoizedState.isDehydrated;if(g&&(Hn(d,o).flags|=256),o=yc(d,o,!1),o!==2){if(rc&&!g){d.errorRecoveryDisabledLanes|=i,nn|=i,a=4;break e}i=st,st=a,i!==null&&(st===null?st=i:st.push.apply(st,i))}a=o}if(i=!1,a!==2)continue}}if(a===1){Hn(e,0),wl(e,t,0,!0);break}e:{switch(n=e,i=a,i){case 0:case 1:throw Error(r(345));case 4:if((t&4194048)!==t)break;case 6:wl(n,t,gt,!_l);break e;case 2:st=null;break;case 3:case 5:break;default:throw Error(r(329))}if((t&62914560)===t&&(a=Xi+300-ot(),10<a)){if(wl(n,t,gt,!_l),li(n,0,!0)!==0)break e;sl=t,n.timeoutHandle=Zd(yd.bind(null,n,l,st,Zi,fc,t,gt,nn,Un,_l,i,"Throttled",-0,0),a);break e}yd(n,l,st,Zi,fc,t,gt,nn,Un,_l,i,null,-0,0)}}break}while(!0);Yt(e)}function yd(e,t,l,n,a,i,o,d,g,A,C,H,w,z){if(e.timeoutHandle=-1,H=t.subtreeFlags,H&8192||(H&16785408)===16785408){H={stylesheets:null,count:0,imgCount:0,imgBytes:0,suspenseyImages:[],waitingForImages:!0,waitingForViewTransition:!1,unsuspend:Zt},cd(t,i,H);var $=(i&62914560)===i?Xi-ot():(i&4194048)===i?dd-ot():0;if($=ky(H,$),$!==null){sl=i,e.cancelPendingCommit=$(Td.bind(null,e,t,i,l,n,a,o,d,g,C,H,null,w,z)),wl(e,i,o,!A);return}}Td(e,t,i,l,n,a,o,d,g)}function Iv(e){for(var t=e;;){var l=t.tag;if((l===0||l===11||l===15)&&t.flags&16384&&(l=t.updateQueue,l!==null&&(l=l.stores,l!==null)))for(var n=0;n<l.length;n++){var a=l[n],i=a.getSnapshot;a=a.value;try{if(!ht(i(),a))return!1}catch{return!1}}if(l=t.child,t.subtreeFlags&16384&&l!==null)l.return=t,t=l;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 wl(e,t,l,n){t&=~oc,t&=~nn,e.suspendedLanes|=t,e.pingedLanes&=~t,n&&(e.warmLanes|=t),n=e.expirationTimes;for(var a=t;0<a;){var i=31-dt(a),o=1<<i;n[i]=-1,a&=~o}l!==0&&Tr(e,l,t)}function Ki(){return(ve&6)===0?(wa(0),!1):!0}function vc(){if(se!==null){if(pe===0)var e=se.return;else e=se,Ft=Jl=null,Cs(e),An=null,fa=0,e=se;for(;e!==null;)Kf(e.alternate,e),e=e.return;se=null}}function Hn(e,t){var l=e.timeoutHandle;l!==-1&&(e.timeoutHandle=-1,gy(l)),l=e.cancelPendingCommit,l!==null&&(e.cancelPendingCommit=null,l()),sl=0,vc(),Te=e,se=l=Jt(e.current,null),re=t,pe=0,pt=null,_l=!1,Dn=Jn(e,t),rc=!1,Un=gt=oc=nn=Nl=Ce=0,st=Aa=null,fc=!1,(t&8)!==0&&(t|=t&32);var n=e.entangledLanes;if(n!==0)for(e=e.entanglements,n&=t;0<n;){var a=31-dt(n),i=1<<a;t|=e[a],n&=~i}return ul=t,mi(),l}function pd(e,t){ae=null,M.H=ba,t===Nn||t===ji?(t=Mo(),pe=3):t===bs?(t=Mo(),pe=4):pe=t===Ks?8:t!==null&&typeof t=="object"&&typeof t.then=="function"?6:1,pt=t,se===null&&(Ce=1,ki(e,Tt(t,e.current)))}function gd(){var e=vt.current;return e===null?!0:(re&4194048)===re?Rt===null:(re&62914560)===re||(re&536870912)!==0?e===Rt:!1}function bd(){var e=M.H;return M.H=ba,e===null?ba:e}function xd(){var e=M.A;return M.A=Fv,e}function Ji(){Ce=4,_l||(re&4194048)!==re&&vt.current!==null||(Dn=!0),(Nl&134217727)===0&&(nn&134217727)===0||Te===null||wl(Te,re,gt,!1)}function yc(e,t,l){var n=ve;ve|=2;var a=bd(),i=xd();(Te!==e||re!==t)&&(Zi=null,Hn(e,t)),t=!1;var o=Ce;e:do try{if(pe!==0&&se!==null){var d=se,g=pt;switch(pe){case 8:vc(),o=6;break e;case 3:case 2:case 9:case 6:vt.current===null&&(t=!0);var A=pe;if(pe=0,pt=null,Bn(e,d,g,A),l&&Dn){o=0;break e}break;default:A=pe,pe=0,pt=null,Bn(e,d,g,A)}}Pv(),o=Ce;break}catch(C){pd(e,C)}while(!0);return t&&e.shellSuspendCounter++,Ft=Jl=null,ve=n,M.H=a,M.A=i,se===null&&(Te=null,re=0,mi()),o}function Pv(){for(;se!==null;)Sd(se)}function ey(e,t){var l=ve;ve|=2;var n=bd(),a=xd();Te!==e||re!==t?(Zi=null,Qi=ot()+500,Hn(e,t)):Dn=Jn(e,t);e:do try{if(pe!==0&&se!==null){t=se;var i=pt;t:switch(pe){case 1:pe=0,pt=null,Bn(e,t,i,1);break;case 2:case 9:if(zo(i)){pe=0,pt=null,jd(t);break}t=function(){pe!==2&&pe!==9||Te!==e||(pe=7),Yt(e)},i.then(t,t);break e;case 3:pe=7;break e;case 4:pe=5;break e;case 7:zo(i)?(pe=0,pt=null,jd(t)):(pe=0,pt=null,Bn(e,t,i,7));break;case 5:var o=null;switch(se.tag){case 26:o=se.memoizedState;case 5:case 27:var d=se;if(o?sh(o):d.stateNode.complete){pe=0,pt=null;var g=d.sibling;if(g!==null)se=g;else{var A=d.return;A!==null?(se=A,$i(A)):se=null}break t}}pe=0,pt=null,Bn(e,t,i,5);break;case 6:pe=0,pt=null,Bn(e,t,i,6);break;case 8:vc(),Ce=6;break e;default:throw Error(r(462))}}ty();break}catch(C){pd(e,C)}while(!0);return Ft=Jl=null,M.H=n,M.A=a,ve=l,se!==null?0:(Te=null,re=0,mi(),Ce)}function ty(){for(;se!==null&&!Tm();)Sd(se)}function Sd(e){var t=Qf(e.alternate,e,ul);e.memoizedProps=e.pendingProps,t===null?$i(e):se=t}function jd(e){var t=e,l=t.alternate;switch(t.tag){case 15:case 0:t=Lf(l,t,t.pendingProps,t.type,void 0,re);break;case 11:t=Lf(l,t,t.pendingProps,t.type.render,t.ref,re);break;case 5:Cs(t);default:Kf(l,t),t=se=bo(t,ul),t=Qf(l,t,ul)}e.memoizedProps=e.pendingProps,t===null?$i(e):se=t}function Bn(e,t,l,n){Ft=Jl=null,Cs(t),An=null,fa=0;var a=t.return;try{if(Vv(e,a,t,l,re)){Ce=1,ki(e,Tt(l,e.current)),se=null;return}}catch(i){if(a!==null)throw se=a,i;Ce=1,ki(e,Tt(l,e.current)),se=null;return}t.flags&32768?(fe||n===1?e=!0:Dn||(re&536870912)!==0?e=!1:(_l=e=!0,(n===2||n===9||n===3||n===6)&&(n=vt.current,n!==null&&n.tag===13&&(n.flags|=16384))),Ed(t,e)):$i(t)}function $i(e){var t=e;do{if((t.flags&32768)!==0){Ed(t,_l);return}e=t.return;var l=Zv(t.alternate,t,ul);if(l!==null){se=l;return}if(t=t.sibling,t!==null){se=t;return}se=t=e}while(t!==null);Ce===0&&(Ce=5)}function Ed(e,t){do{var l=Kv(e.alternate,e);if(l!==null){l.flags&=32767,se=l;return}if(l=e.return,l!==null&&(l.flags|=32768,l.subtreeFlags=0,l.deletions=null),!t&&(e=e.sibling,e!==null)){se=e;return}se=e=l}while(e!==null);Ce=6,se=null}function Td(e,t,l,n,a,i,o,d,g){e.cancelPendingCommit=null;do Fi();while(qe!==0);if((ve&6)!==0)throw Error(r(327));if(t!==null){if(t===e.current)throw Error(r(177));if(i=t.lanes|t.childLanes,i|=as,Dm(e,l,i,o,d,g),e===Te&&(se=Te=null,re=0),kn=t,Rl=e,sl=l,dc=i,hc=a,hd=n,(t.subtreeFlags&10256)!==0||(t.flags&10256)!==0?(e.callbackNode=null,e.callbackPriority=0,iy(Ia,function(){return wd(),null})):(e.callbackNode=null,e.callbackPriority=0),n=(t.flags&13878)!==0,(t.subtreeFlags&13878)!==0||n){n=M.T,M.T=null,a=K.p,K.p=2,o=ve,ve|=4;try{Jv(e,t,l)}finally{ve=o,K.p=a,M.T=n}}qe=1,_d(),Nd(),Ad()}}function _d(){if(qe===1){qe=0;var e=Rl,t=kn,l=(t.flags&13878)!==0;if((t.subtreeFlags&13878)!==0||l){l=M.T,M.T=null;var n=K.p;K.p=2;var a=ve;ve|=4;try{id(t,e);var i=Rc,o=ro(e.containerInfo),d=i.focusedElem,g=i.selectionRange;if(o!==d&&d&&d.ownerDocument&&co(d.ownerDocument.documentElement,d)){if(g!==null&&Pu(d)){var A=g.start,C=g.end;if(C===void 0&&(C=A),"selectionStart"in d)d.selectionStart=A,d.selectionEnd=Math.min(C,d.value.length);else{var H=d.ownerDocument||document,w=H&&H.defaultView||window;if(w.getSelection){var z=w.getSelection(),$=d.textContent.length,P=Math.min(g.start,$),je=g.end===void 0?P:Math.min(g.end,$);!z.extend&&P>je&&(o=je,je=P,P=o);var _=so(d,P),S=so(d,je);if(_&&S&&(z.rangeCount!==1||z.anchorNode!==_.node||z.anchorOffset!==_.offset||z.focusNode!==S.node||z.focusOffset!==S.offset)){var N=H.createRange();N.setStart(_.node,_.offset),z.removeAllRanges(),P>je?(z.addRange(N),z.extend(S.node,S.offset)):(N.setEnd(S.node,S.offset),z.addRange(N))}}}}for(H=[],z=d;z=z.parentNode;)z.nodeType===1&&H.push({element:z,left:z.scrollLeft,top:z.scrollTop});for(typeof d.focus=="function"&&d.focus(),d=0;d<H.length;d++){var U=H[d];U.element.scrollLeft=U.left,U.element.scrollTop=U.top}}cu=!!Ac,Rc=Ac=null}finally{ve=a,K.p=n,M.T=l}}e.current=t,qe=2}}function Nd(){if(qe===2){qe=0;var e=Rl,t=kn,l=(t.flags&8772)!==0;if((t.subtreeFlags&8772)!==0||l){l=M.T,M.T=null;var n=K.p;K.p=2;var a=ve;ve|=4;try{ed(e,t.alternate,t)}finally{ve=a,K.p=n,M.T=l}}qe=3}}function Ad(){if(qe===4||qe===3){qe=0,_m();var e=Rl,t=kn,l=sl,n=hd;(t.subtreeFlags&10256)!==0||(t.flags&10256)!==0?qe=5:(qe=0,kn=Rl=null,Rd(e,e.pendingLanes));var a=e.pendingLanes;if(a===0&&(Al=null),Du(l),t=t.stateNode,ft&&typeof ft.onCommitFiberRoot=="function")try{ft.onCommitFiberRoot(Kn,t,void 0,(t.current.flags&128)===128)}catch{}if(n!==null){t=M.T,a=K.p,K.p=2,M.T=null;try{for(var i=e.onRecoverableError,o=0;o<n.length;o++){var d=n[o];i(d.value,{componentStack:d.stack})}}finally{M.T=t,K.p=a}}(sl&3)!==0&&Fi(),Yt(e),a=e.pendingLanes,(l&261930)!==0&&(a&42)!==0?e===mc?Ra++:(Ra=0,mc=e):Ra=0,wa(0)}}function Rd(e,t){(e.pooledCacheLanes&=t)===0&&(t=e.pooledCache,t!=null&&(e.pooledCache=null,ra(t)))}function Fi(){return _d(),Nd(),Ad(),wd()}function wd(){if(qe!==5)return!1;var e=Rl,t=dc;dc=0;var l=Du(sl),n=M.T,a=K.p;try{K.p=32>l?32:l,M.T=null,l=hc,hc=null;var i=Rl,o=sl;if(qe=0,kn=Rl=null,sl=0,(ve&6)!==0)throw Error(r(331));var d=ve;if(ve|=4,od(i.current),sd(i,i.current,o,l),ve=d,wa(0,!1),ft&&typeof ft.onPostCommitFiberRoot=="function")try{ft.onPostCommitFiberRoot(Kn,i)}catch{}return!0}finally{K.p=a,M.T=n,Rd(e,t)}}function zd(e,t,l){t=Tt(l,t),t=Zs(e.stateNode,t,2),e=Sl(e,t,2),e!==null&&($n(e,2),Yt(e))}function ge(e,t,l){if(e.tag===3)zd(e,e,l);else for(;t!==null;){if(t.tag===3){zd(t,e,l);break}else if(t.tag===1){var n=t.stateNode;if(typeof t.type.getDerivedStateFromError=="function"||typeof n.componentDidCatch=="function"&&(Al===null||!Al.has(n))){e=Tt(l,e),l=Cf(2),n=Sl(t,l,2),n!==null&&(Mf(l,n,t,e),$n(n,2),Yt(n));break}}t=t.return}}function pc(e,t,l){var n=e.pingCache;if(n===null){n=e.pingCache=new Wv;var a=new Set;n.set(t,a)}else a=n.get(t),a===void 0&&(a=new Set,n.set(t,a));a.has(l)||(rc=!0,a.add(l),e=ly.bind(null,e,t,l),t.then(e,e))}function ly(e,t,l){var n=e.pingCache;n!==null&&n.delete(t),e.pingedLanes|=e.suspendedLanes&l,e.warmLanes&=~l,Te===e&&(re&l)===l&&(Ce===4||Ce===3&&(re&62914560)===re&&300>ot()-Xi?(ve&2)===0&&Hn(e,0):oc|=l,Un===re&&(Un=0)),Yt(e)}function Cd(e,t){t===0&&(t=Er()),e=Ql(e,t),e!==null&&($n(e,t),Yt(e))}function ny(e){var t=e.memoizedState,l=0;t!==null&&(l=t.retryLane),Cd(e,l)}function ay(e,t){var l=0;switch(e.tag){case 31:case 13:var n=e.stateNode,a=e.memoizedState;a!==null&&(l=a.retryLane);break;case 19:n=e.stateNode;break;case 22:n=e.stateNode._retryCache;break;default:throw Error(r(314))}n!==null&&n.delete(t),Cd(e,l)}function iy(e,t){return zu(e,t)}var Wi=null,Ln=null,gc=!1,Ii=!1,bc=!1,zl=0;function Yt(e){e!==Ln&&e.next===null&&(Ln===null?Wi=Ln=e:Ln=Ln.next=e),Ii=!0,gc||(gc=!0,sy())}function wa(e,t){if(!bc&&Ii){bc=!0;do for(var l=!1,n=Wi;n!==null;){if(e!==0){var a=n.pendingLanes;if(a===0)var i=0;else{var o=n.suspendedLanes,d=n.pingedLanes;i=(1<<31-dt(42|e)+1)-1,i&=a&~(o&~d),i=i&201326741?i&201326741|1:i?i|2:0}i!==0&&(l=!0,Ud(n,i))}else i=re,i=li(n,n===Te?i:0,n.cancelPendingCommit!==null||n.timeoutHandle!==-1),(i&3)===0||Jn(n,i)||(l=!0,Ud(n,i));n=n.next}while(l);bc=!1}}function uy(){Md()}function Md(){Ii=gc=!1;var e=0;zl!==0&&py()&&(e=zl);for(var t=ot(),l=null,n=Wi;n!==null;){var a=n.next,i=Od(n,t);i===0?(n.next=null,l===null?Wi=a:l.next=a,a===null&&(Ln=l)):(l=n,(e!==0||(i&3)!==0)&&(Ii=!0)),n=a}qe!==0&&qe!==5||wa(e),zl!==0&&(zl=0)}function Od(e,t){for(var l=e.suspendedLanes,n=e.pingedLanes,a=e.expirationTimes,i=e.pendingLanes&-62914561;0<i;){var o=31-dt(i),d=1<<o,g=a[o];g===-1?((d&l)===0||(d&n)!==0)&&(a[o]=Om(d,t)):g<=t&&(e.expiredLanes|=d),i&=~d}if(t=Te,l=re,l=li(e,e===t?l:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),n=e.callbackNode,l===0||e===t&&(pe===2||pe===9)||e.cancelPendingCommit!==null)return n!==null&&n!==null&&Cu(n),e.callbackNode=null,e.callbackPriority=0;if((l&3)===0||Jn(e,l)){if(t=l&-l,t===e.callbackPriority)return t;switch(n!==null&&Cu(n),Du(l)){case 2:case 8:l=Sr;break;case 32:l=Ia;break;case 268435456:l=jr;break;default:l=Ia}return n=Dd.bind(null,e),l=zu(l,n),e.callbackPriority=t,e.callbackNode=l,t}return n!==null&&n!==null&&Cu(n),e.callbackPriority=2,e.callbackNode=null,2}function Dd(e,t){if(qe!==0&&qe!==5)return e.callbackNode=null,e.callbackPriority=0,null;var l=e.callbackNode;if(Fi()&&e.callbackNode!==l)return null;var n=re;return n=li(e,e===Te?n:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),n===0?null:(vd(e,n,t),Od(e,ot()),e.callbackNode!=null&&e.callbackNode===l?Dd.bind(null,e):null)}function Ud(e,t){if(Fi())return null;vd(e,t,!0)}function sy(){by(function(){(ve&6)!==0?zu(xr,uy):Md()})}function xc(){if(zl===0){var e=Tn;e===0&&(e=Pa,Pa<<=1,(Pa&261888)===0&&(Pa=256)),zl=e}return zl}function kd(e){return e==null||typeof e=="symbol"||typeof e=="boolean"?null:typeof e=="function"?e:ui(""+e)}function Hd(e,t){var l=t.ownerDocument.createElement("input");return l.name=t.name,l.value=t.value,e.id&&l.setAttribute("form",e.id),t.parentNode.insertBefore(l,t),e=new FormData(e),l.parentNode.removeChild(l),e}function cy(e,t,l,n,a){if(t==="submit"&&l&&l.stateNode===a){var i=kd((a[lt]||null).action),o=n.submitter;o&&(t=(t=o[lt]||null)?kd(t.formAction):o.getAttribute("formAction"),t!==null&&(i=t,o=null));var d=new oi("action","action",null,n,a);e.push({event:d,listeners:[{instance:null,listener:function(){if(n.defaultPrevented){if(zl!==0){var g=o?Hd(a,o):new FormData(a);qs(l,{pending:!0,data:g,method:a.method,action:i},null,g)}}else typeof i=="function"&&(d.preventDefault(),g=o?Hd(a,o):new FormData(a),qs(l,{pending:!0,data:g,method:a.method,action:i},i,g))},currentTarget:a}]})}}for(var Sc=0;Sc<ns.length;Sc++){var jc=ns[Sc],ry=jc.toLowerCase(),oy=jc[0].toUpperCase()+jc.slice(1);Ot(ry,"on"+oy)}Ot(ho,"onAnimationEnd"),Ot(mo,"onAnimationIteration"),Ot(vo,"onAnimationStart"),Ot("dblclick","onDoubleClick"),Ot("focusin","onFocus"),Ot("focusout","onBlur"),Ot(Nv,"onTransitionRun"),Ot(Av,"onTransitionStart"),Ot(Rv,"onTransitionCancel"),Ot(yo,"onTransitionEnd"),on("onMouseEnter",["mouseout","mouseover"]),on("onMouseLeave",["mouseout","mouseover"]),on("onPointerEnter",["pointerout","pointerover"]),on("onPointerLeave",["pointerout","pointerover"]),Yl("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),Yl("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),Yl("onBeforeInput",["compositionend","keypress","textInput","paste"]),Yl("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),Yl("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),Yl("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var za="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(" "),fy=new Set("beforetoggle cancel close invalid load scroll scrollend toggle".split(" ").concat(za));function Bd(e,t){t=(t&4)!==0;for(var l=0;l<e.length;l++){var n=e[l],a=n.event;n=n.listeners;e:{var i=void 0;if(t)for(var o=n.length-1;0<=o;o--){var d=n[o],g=d.instance,A=d.currentTarget;if(d=d.listener,g!==i&&a.isPropagationStopped())break e;i=d,a.currentTarget=A;try{i(a)}catch(C){hi(C)}a.currentTarget=null,i=g}else for(o=0;o<n.length;o++){if(d=n[o],g=d.instance,A=d.currentTarget,d=d.listener,g!==i&&a.isPropagationStopped())break e;i=d,a.currentTarget=A;try{i(a)}catch(C){hi(C)}a.currentTarget=null,i=g}}}}function ce(e,t){var l=t[Uu];l===void 0&&(l=t[Uu]=new Set);var n=e+"__bubble";l.has(n)||(Ld(t,e,2,!1),l.add(n))}function Ec(e,t,l){var n=0;t&&(n|=4),Ld(l,e,n,t)}var Pi="_reactListening"+Math.random().toString(36).slice(2);function Tc(e){if(!e[Pi]){e[Pi]=!0,zr.forEach(function(l){l!=="selectionchange"&&(fy.has(l)||Ec(l,!1,e),Ec(l,!0,e))});var t=e.nodeType===9?e:e.ownerDocument;t===null||t[Pi]||(t[Pi]=!0,Ec("selectionchange",!1,t))}}function Ld(e,t,l,n){switch(mh(t)){case 2:var a=Ly;break;case 8:a=qy;break;default:a=Lc}l=a.bind(null,t,l,e),a=void 0,!Xu||t!=="touchstart"&&t!=="touchmove"&&t!=="wheel"||(a=!0),n?a!==void 0?e.addEventListener(t,l,{capture:!0,passive:a}):e.addEventListener(t,l,!0):a!==void 0?e.addEventListener(t,l,{passive:a}):e.addEventListener(t,l,!1)}function _c(e,t,l,n,a){var i=n;if((t&1)===0&&(t&2)===0&&n!==null)e:for(;;){if(n===null)return;var o=n.tag;if(o===3||o===4){var d=n.stateNode.containerInfo;if(d===a)break;if(o===4)for(o=n.return;o!==null;){var g=o.tag;if((g===3||g===4)&&o.stateNode.containerInfo===a)return;o=o.return}for(;d!==null;){if(o=sn(d),o===null)return;if(g=o.tag,g===5||g===6||g===26||g===27){n=i=o;continue e}d=d.parentNode}}n=n.return}Gr(function(){var A=i,C=Gu(l),H=[];e:{var w=po.get(e);if(w!==void 0){var z=oi,$=e;switch(e){case"keypress":if(ci(l)===0)break e;case"keydown":case"keyup":z=av;break;case"focusin":$="focus",z=Ju;break;case"focusout":$="blur",z=Ju;break;case"beforeblur":case"afterblur":z=Ju;break;case"click":if(l.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":z=Qr;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":z=Zm;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":z=sv;break;case ho:case mo:case vo:z=$m;break;case yo:z=rv;break;case"scroll":case"scrollend":z=Xm;break;case"wheel":z=fv;break;case"copy":case"cut":case"paste":z=Wm;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":z=Kr;break;case"toggle":case"beforetoggle":z=hv}var P=(t&4)!==0,je=!P&&(e==="scroll"||e==="scrollend"),_=P?w!==null?w+"Capture":null:w;P=[];for(var S=A,N;S!==null;){var U=S;if(N=U.stateNode,U=U.tag,U!==5&&U!==26&&U!==27||N===null||_===null||(U=In(S,_),U!=null&&P.push(Ca(S,U,N))),je)break;S=S.return}0<P.length&&(w=new z(w,$,null,l,C),H.push({event:w,listeners:P}))}}if((t&7)===0){e:{if(w=e==="mouseover"||e==="pointerover",z=e==="mouseout"||e==="pointerout",w&&l!==Yu&&($=l.relatedTarget||l.fromElement)&&(sn($)||$[un]))break e;if((z||w)&&(w=C.window===C?C:(w=C.ownerDocument)?w.defaultView||w.parentWindow:window,z?($=l.relatedTarget||l.toElement,z=A,$=$?sn($):null,$!==null&&(je=m($),P=$.tag,$!==je||P!==5&&P!==27&&P!==6)&&($=null)):(z=null,$=A),z!==$)){if(P=Qr,U="onMouseLeave",_="onMouseEnter",S="mouse",(e==="pointerout"||e==="pointerover")&&(P=Kr,U="onPointerLeave",_="onPointerEnter",S="pointer"),je=z==null?w:Wn(z),N=$==null?w:Wn($),w=new P(U,S+"leave",z,l,C),w.target=je,w.relatedTarget=N,U=null,sn(C)===A&&(P=new P(_,S+"enter",$,l,C),P.target=N,P.relatedTarget=je,U=P),je=U,z&&$)t:{for(P=dy,_=z,S=$,N=0,U=_;U;U=P(U))N++;U=0;for(var I=S;I;I=P(I))U++;for(;0<N-U;)_=P(_),N--;for(;0<U-N;)S=P(S),U--;for(;N--;){if(_===S||S!==null&&_===S.alternate){P=_;break t}_=P(_),S=P(S)}P=null}else P=null;z!==null&&qd(H,w,z,P,!1),$!==null&&je!==null&&qd(H,je,$,P,!0)}}e:{if(w=A?Wn(A):window,z=w.nodeName&&w.nodeName.toLowerCase(),z==="select"||z==="input"&&w.type==="file")var de=to;else if(Pr(w))if(lo)de=Ev;else{de=Sv;var W=xv}else z=w.nodeName,!z||z.toLowerCase()!=="input"||w.type!=="checkbox"&&w.type!=="radio"?A&&qu(A.elementType)&&(de=to):de=jv;if(de&&(de=de(e,A))){eo(H,de,l,C);break e}W&&W(e,w,A),e==="focusout"&&A&&w.type==="number"&&A.memoizedProps.value!=null&&Lu(w,"number",w.value)}switch(W=A?Wn(A):window,e){case"focusin":(Pr(W)||W.contentEditable==="true")&&(yn=W,es=A,ua=null);break;case"focusout":ua=es=yn=null;break;case"mousedown":ts=!0;break;case"contextmenu":case"mouseup":case"dragend":ts=!1,oo(H,l,C);break;case"selectionchange":if(_v)break;case"keydown":case"keyup":oo(H,l,C)}var ie;if(Fu)e:{switch(e){case"compositionstart":var oe="onCompositionStart";break e;case"compositionend":oe="onCompositionEnd";break e;case"compositionupdate":oe="onCompositionUpdate";break e}oe=void 0}else vn?Wr(e,l)&&(oe="onCompositionEnd"):e==="keydown"&&l.keyCode===229&&(oe="onCompositionStart");oe&&(Jr&&l.locale!=="ko"&&(vn||oe!=="onCompositionStart"?oe==="onCompositionEnd"&&vn&&(ie=Vr()):(ml=C,Qu="value"in ml?ml.value:ml.textContent,vn=!0)),W=eu(A,oe),0<W.length&&(oe=new Zr(oe,e,null,l,C),H.push({event:oe,listeners:W}),ie?oe.data=ie:(ie=Ir(l),ie!==null&&(oe.data=ie)))),(ie=vv?yv(e,l):pv(e,l))&&(oe=eu(A,"onBeforeInput"),0<oe.length&&(W=new Zr("onBeforeInput","beforeinput",null,l,C),H.push({event:W,listeners:oe}),W.data=ie)),cy(H,e,A,l,C)}Bd(H,t)})}function Ca(e,t,l){return{instance:e,listener:t,currentTarget:l}}function eu(e,t){for(var l=t+"Capture",n=[];e!==null;){var a=e,i=a.stateNode;if(a=a.tag,a!==5&&a!==26&&a!==27||i===null||(a=In(e,l),a!=null&&n.unshift(Ca(e,a,i)),a=In(e,t),a!=null&&n.push(Ca(e,a,i))),e.tag===3)return n;e=e.return}return[]}function dy(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5&&e.tag!==27);return e||null}function qd(e,t,l,n,a){for(var i=t._reactName,o=[];l!==null&&l!==n;){var d=l,g=d.alternate,A=d.stateNode;if(d=d.tag,g!==null&&g===n)break;d!==5&&d!==26&&d!==27||A===null||(g=A,a?(A=In(l,i),A!=null&&o.unshift(Ca(l,A,g))):a||(A=In(l,i),A!=null&&o.push(Ca(l,A,g)))),l=l.return}o.length!==0&&e.push({event:t,listeners:o})}var hy=/\r\n?/g,my=/\u0000|\uFFFD/g;function Yd(e){return(typeof e=="string"?e:""+e).replace(hy,`
|
|
49
|
+
`).replace(my,"")}function Gd(e,t){return t=Yd(t),Yd(e)===t}function Se(e,t,l,n,a,i){switch(l){case"children":typeof n=="string"?t==="body"||t==="textarea"&&n===""||dn(e,n):(typeof n=="number"||typeof n=="bigint")&&t!=="body"&&dn(e,""+n);break;case"className":ai(e,"class",n);break;case"tabIndex":ai(e,"tabindex",n);break;case"dir":case"role":case"viewBox":case"width":case"height":ai(e,l,n);break;case"style":qr(e,n,i);break;case"data":if(t!=="object"){ai(e,"data",n);break}case"src":case"href":if(n===""&&(t!=="a"||l!=="href")){e.removeAttribute(l);break}if(n==null||typeof n=="function"||typeof n=="symbol"||typeof n=="boolean"){e.removeAttribute(l);break}n=ui(""+n),e.setAttribute(l,n);break;case"action":case"formAction":if(typeof n=="function"){e.setAttribute(l,"javascript:throw new Error('A React form was unexpectedly submitted. If you called form.submit() manually, consider using form.requestSubmit() instead. If you\\'re trying to use event.stopPropagation() in a submit event handler, consider also calling event.preventDefault().')");break}else typeof i=="function"&&(l==="formAction"?(t!=="input"&&Se(e,t,"name",a.name,a,null),Se(e,t,"formEncType",a.formEncType,a,null),Se(e,t,"formMethod",a.formMethod,a,null),Se(e,t,"formTarget",a.formTarget,a,null)):(Se(e,t,"encType",a.encType,a,null),Se(e,t,"method",a.method,a,null),Se(e,t,"target",a.target,a,null)));if(n==null||typeof n=="symbol"||typeof n=="boolean"){e.removeAttribute(l);break}n=ui(""+n),e.setAttribute(l,n);break;case"onClick":n!=null&&(e.onclick=Zt);break;case"onScroll":n!=null&&ce("scroll",e);break;case"onScrollEnd":n!=null&&ce("scrollend",e);break;case"dangerouslySetInnerHTML":if(n!=null){if(typeof n!="object"||!("__html"in n))throw Error(r(61));if(l=n.__html,l!=null){if(a.children!=null)throw Error(r(60));e.innerHTML=l}}break;case"multiple":e.multiple=n&&typeof n!="function"&&typeof n!="symbol";break;case"muted":e.muted=n&&typeof n!="function"&&typeof n!="symbol";break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":break;case"autoFocus":break;case"xlinkHref":if(n==null||typeof n=="function"||typeof n=="boolean"||typeof n=="symbol"){e.removeAttribute("xlink:href");break}l=ui(""+n),e.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",l);break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":n!=null&&typeof n!="function"&&typeof n!="symbol"?e.setAttribute(l,""+n):e.removeAttribute(l);break;case"inert":case"allowFullScreen":case"async":case"autoPlay":case"controls":case"default":case"defer":case"disabled":case"disablePictureInPicture":case"disableRemotePlayback":case"formNoValidate":case"hidden":case"loop":case"noModule":case"noValidate":case"open":case"playsInline":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"itemScope":n&&typeof n!="function"&&typeof n!="symbol"?e.setAttribute(l,""):e.removeAttribute(l);break;case"capture":case"download":n===!0?e.setAttribute(l,""):n!==!1&&n!=null&&typeof n!="function"&&typeof n!="symbol"?e.setAttribute(l,n):e.removeAttribute(l);break;case"cols":case"rows":case"size":case"span":n!=null&&typeof n!="function"&&typeof n!="symbol"&&!isNaN(n)&&1<=n?e.setAttribute(l,n):e.removeAttribute(l);break;case"rowSpan":case"start":n==null||typeof n=="function"||typeof n=="symbol"||isNaN(n)?e.removeAttribute(l):e.setAttribute(l,n);break;case"popover":ce("beforetoggle",e),ce("toggle",e),ni(e,"popover",n);break;case"xlinkActuate":Qt(e,"http://www.w3.org/1999/xlink","xlink:actuate",n);break;case"xlinkArcrole":Qt(e,"http://www.w3.org/1999/xlink","xlink:arcrole",n);break;case"xlinkRole":Qt(e,"http://www.w3.org/1999/xlink","xlink:role",n);break;case"xlinkShow":Qt(e,"http://www.w3.org/1999/xlink","xlink:show",n);break;case"xlinkTitle":Qt(e,"http://www.w3.org/1999/xlink","xlink:title",n);break;case"xlinkType":Qt(e,"http://www.w3.org/1999/xlink","xlink:type",n);break;case"xmlBase":Qt(e,"http://www.w3.org/XML/1998/namespace","xml:base",n);break;case"xmlLang":Qt(e,"http://www.w3.org/XML/1998/namespace","xml:lang",n);break;case"xmlSpace":Qt(e,"http://www.w3.org/XML/1998/namespace","xml:space",n);break;case"is":ni(e,"is",n);break;case"innerText":case"textContent":break;default:(!(2<l.length)||l[0]!=="o"&&l[0]!=="O"||l[1]!=="n"&&l[1]!=="N")&&(l=Gm.get(l)||l,ni(e,l,n))}}function Nc(e,t,l,n,a,i){switch(l){case"style":qr(e,n,i);break;case"dangerouslySetInnerHTML":if(n!=null){if(typeof n!="object"||!("__html"in n))throw Error(r(61));if(l=n.__html,l!=null){if(a.children!=null)throw Error(r(60));e.innerHTML=l}}break;case"children":typeof n=="string"?dn(e,n):(typeof n=="number"||typeof n=="bigint")&&dn(e,""+n);break;case"onScroll":n!=null&&ce("scroll",e);break;case"onScrollEnd":n!=null&&ce("scrollend",e);break;case"onClick":n!=null&&(e.onclick=Zt);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"innerHTML":case"ref":break;case"innerText":case"textContent":break;default:if(!Cr.hasOwnProperty(l))e:{if(l[0]==="o"&&l[1]==="n"&&(a=l.endsWith("Capture"),t=l.slice(2,a?l.length-7:void 0),i=e[lt]||null,i=i!=null?i[l]:null,typeof i=="function"&&e.removeEventListener(t,i,a),typeof n=="function")){typeof i!="function"&&i!==null&&(l in e?e[l]=null:e.hasAttribute(l)&&e.removeAttribute(l)),e.addEventListener(t,n,a);break e}l in e?e[l]=n:n===!0?e.setAttribute(l,""):ni(e,l,n)}}}function Ke(e,t,l){switch(t){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"img":ce("error",e),ce("load",e);var n=!1,a=!1,i;for(i in l)if(l.hasOwnProperty(i)){var o=l[i];if(o!=null)switch(i){case"src":n=!0;break;case"srcSet":a=!0;break;case"children":case"dangerouslySetInnerHTML":throw Error(r(137,t));default:Se(e,t,i,o,l,null)}}a&&Se(e,t,"srcSet",l.srcSet,l,null),n&&Se(e,t,"src",l.src,l,null);return;case"input":ce("invalid",e);var d=i=o=a=null,g=null,A=null;for(n in l)if(l.hasOwnProperty(n)){var C=l[n];if(C!=null)switch(n){case"name":a=C;break;case"type":o=C;break;case"checked":g=C;break;case"defaultChecked":A=C;break;case"value":i=C;break;case"defaultValue":d=C;break;case"children":case"dangerouslySetInnerHTML":if(C!=null)throw Error(r(137,t));break;default:Se(e,t,n,C,l,null)}}kr(e,i,d,g,A,o,a,!1);return;case"select":ce("invalid",e),n=o=i=null;for(a in l)if(l.hasOwnProperty(a)&&(d=l[a],d!=null))switch(a){case"value":i=d;break;case"defaultValue":o=d;break;case"multiple":n=d;default:Se(e,t,a,d,l,null)}t=i,l=o,e.multiple=!!n,t!=null?fn(e,!!n,t,!1):l!=null&&fn(e,!!n,l,!0);return;case"textarea":ce("invalid",e),i=a=n=null;for(o in l)if(l.hasOwnProperty(o)&&(d=l[o],d!=null))switch(o){case"value":n=d;break;case"defaultValue":a=d;break;case"children":i=d;break;case"dangerouslySetInnerHTML":if(d!=null)throw Error(r(91));break;default:Se(e,t,o,d,l,null)}Br(e,n,a,i);return;case"option":for(g in l)if(l.hasOwnProperty(g)&&(n=l[g],n!=null))switch(g){case"selected":e.selected=n&&typeof n!="function"&&typeof n!="symbol";break;default:Se(e,t,g,n,l,null)}return;case"dialog":ce("beforetoggle",e),ce("toggle",e),ce("cancel",e),ce("close",e);break;case"iframe":case"object":ce("load",e);break;case"video":case"audio":for(n=0;n<za.length;n++)ce(za[n],e);break;case"image":ce("error",e),ce("load",e);break;case"details":ce("toggle",e);break;case"embed":case"source":case"link":ce("error",e),ce("load",e);case"area":case"base":case"br":case"col":case"hr":case"keygen":case"meta":case"param":case"track":case"wbr":case"menuitem":for(A in l)if(l.hasOwnProperty(A)&&(n=l[A],n!=null))switch(A){case"children":case"dangerouslySetInnerHTML":throw Error(r(137,t));default:Se(e,t,A,n,l,null)}return;default:if(qu(t)){for(C in l)l.hasOwnProperty(C)&&(n=l[C],n!==void 0&&Nc(e,t,C,n,l,void 0));return}}for(d in l)l.hasOwnProperty(d)&&(n=l[d],n!=null&&Se(e,t,d,n,l,null))}function vy(e,t,l,n){switch(t){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"input":var a=null,i=null,o=null,d=null,g=null,A=null,C=null;for(z in l){var H=l[z];if(l.hasOwnProperty(z)&&H!=null)switch(z){case"checked":break;case"value":break;case"defaultValue":g=H;default:n.hasOwnProperty(z)||Se(e,t,z,null,n,H)}}for(var w in n){var z=n[w];if(H=l[w],n.hasOwnProperty(w)&&(z!=null||H!=null))switch(w){case"type":i=z;break;case"name":a=z;break;case"checked":A=z;break;case"defaultChecked":C=z;break;case"value":o=z;break;case"defaultValue":d=z;break;case"children":case"dangerouslySetInnerHTML":if(z!=null)throw Error(r(137,t));break;default:z!==H&&Se(e,t,w,z,n,H)}}Bu(e,o,d,g,A,C,i,a);return;case"select":z=o=d=w=null;for(i in l)if(g=l[i],l.hasOwnProperty(i)&&g!=null)switch(i){case"value":break;case"multiple":z=g;default:n.hasOwnProperty(i)||Se(e,t,i,null,n,g)}for(a in n)if(i=n[a],g=l[a],n.hasOwnProperty(a)&&(i!=null||g!=null))switch(a){case"value":w=i;break;case"defaultValue":d=i;break;case"multiple":o=i;default:i!==g&&Se(e,t,a,i,n,g)}t=d,l=o,n=z,w!=null?fn(e,!!l,w,!1):!!n!=!!l&&(t!=null?fn(e,!!l,t,!0):fn(e,!!l,l?[]:"",!1));return;case"textarea":z=w=null;for(d in l)if(a=l[d],l.hasOwnProperty(d)&&a!=null&&!n.hasOwnProperty(d))switch(d){case"value":break;case"children":break;default:Se(e,t,d,null,n,a)}for(o in n)if(a=n[o],i=l[o],n.hasOwnProperty(o)&&(a!=null||i!=null))switch(o){case"value":w=a;break;case"defaultValue":z=a;break;case"children":break;case"dangerouslySetInnerHTML":if(a!=null)throw Error(r(91));break;default:a!==i&&Se(e,t,o,a,n,i)}Hr(e,w,z);return;case"option":for(var $ in l)if(w=l[$],l.hasOwnProperty($)&&w!=null&&!n.hasOwnProperty($))switch($){case"selected":e.selected=!1;break;default:Se(e,t,$,null,n,w)}for(g in n)if(w=n[g],z=l[g],n.hasOwnProperty(g)&&w!==z&&(w!=null||z!=null))switch(g){case"selected":e.selected=w&&typeof w!="function"&&typeof w!="symbol";break;default:Se(e,t,g,w,n,z)}return;case"img":case"link":case"area":case"base":case"br":case"col":case"embed":case"hr":case"keygen":case"meta":case"param":case"source":case"track":case"wbr":case"menuitem":for(var P in l)w=l[P],l.hasOwnProperty(P)&&w!=null&&!n.hasOwnProperty(P)&&Se(e,t,P,null,n,w);for(A in n)if(w=n[A],z=l[A],n.hasOwnProperty(A)&&w!==z&&(w!=null||z!=null))switch(A){case"children":case"dangerouslySetInnerHTML":if(w!=null)throw Error(r(137,t));break;default:Se(e,t,A,w,n,z)}return;default:if(qu(t)){for(var je in l)w=l[je],l.hasOwnProperty(je)&&w!==void 0&&!n.hasOwnProperty(je)&&Nc(e,t,je,void 0,n,w);for(C in n)w=n[C],z=l[C],!n.hasOwnProperty(C)||w===z||w===void 0&&z===void 0||Nc(e,t,C,w,n,z);return}}for(var _ in l)w=l[_],l.hasOwnProperty(_)&&w!=null&&!n.hasOwnProperty(_)&&Se(e,t,_,null,n,w);for(H in n)w=n[H],z=l[H],!n.hasOwnProperty(H)||w===z||w==null&&z==null||Se(e,t,H,w,n,z)}function Vd(e){switch(e){case"css":case"script":case"font":case"img":case"image":case"input":case"link":return!0;default:return!1}}function yy(){if(typeof performance.getEntriesByType=="function"){for(var e=0,t=0,l=performance.getEntriesByType("resource"),n=0;n<l.length;n++){var a=l[n],i=a.transferSize,o=a.initiatorType,d=a.duration;if(i&&d&&Vd(o)){for(o=0,d=a.responseEnd,n+=1;n<l.length;n++){var g=l[n],A=g.startTime;if(A>d)break;var C=g.transferSize,H=g.initiatorType;C&&Vd(H)&&(g=g.responseEnd,o+=C*(g<d?1:(d-A)/(g-A)))}if(--n,t+=8*(i+o)/(a.duration/1e3),e++,10<e)break}}if(0<e)return t/e/1e6}return navigator.connection&&(e=navigator.connection.downlink,typeof e=="number")?e:5}var Ac=null,Rc=null;function tu(e){return e.nodeType===9?e:e.ownerDocument}function Xd(e){switch(e){case"http://www.w3.org/2000/svg":return 1;case"http://www.w3.org/1998/Math/MathML":return 2;default:return 0}}function Qd(e,t){if(e===0)switch(t){case"svg":return 1;case"math":return 2;default:return 0}return e===1&&t==="foreignObject"?0:e}function wc(e,t){return e==="textarea"||e==="noscript"||typeof t.children=="string"||typeof t.children=="number"||typeof t.children=="bigint"||typeof t.dangerouslySetInnerHTML=="object"&&t.dangerouslySetInnerHTML!==null&&t.dangerouslySetInnerHTML.__html!=null}var zc=null;function py(){var e=window.event;return e&&e.type==="popstate"?e===zc?!1:(zc=e,!0):(zc=null,!1)}var Zd=typeof setTimeout=="function"?setTimeout:void 0,gy=typeof clearTimeout=="function"?clearTimeout:void 0,Kd=typeof Promise=="function"?Promise:void 0,by=typeof queueMicrotask=="function"?queueMicrotask:typeof Kd<"u"?function(e){return Kd.resolve(null).then(e).catch(xy)}:Zd;function xy(e){setTimeout(function(){throw e})}function Cl(e){return e==="head"}function Jd(e,t){var l=t,n=0;do{var a=l.nextSibling;if(e.removeChild(l),a&&a.nodeType===8)if(l=a.data,l==="/$"||l==="/&"){if(n===0){e.removeChild(a),Vn(t);return}n--}else if(l==="$"||l==="$?"||l==="$~"||l==="$!"||l==="&")n++;else if(l==="html")Ma(e.ownerDocument.documentElement);else if(l==="head"){l=e.ownerDocument.head,Ma(l);for(var i=l.firstChild;i;){var o=i.nextSibling,d=i.nodeName;i[Fn]||d==="SCRIPT"||d==="STYLE"||d==="LINK"&&i.rel.toLowerCase()==="stylesheet"||l.removeChild(i),i=o}}else l==="body"&&Ma(e.ownerDocument.body);l=a}while(l);Vn(t)}function $d(e,t){var l=e;e=0;do{var n=l.nextSibling;if(l.nodeType===1?t?(l._stashedDisplay=l.style.display,l.style.display="none"):(l.style.display=l._stashedDisplay||"",l.getAttribute("style")===""&&l.removeAttribute("style")):l.nodeType===3&&(t?(l._stashedText=l.nodeValue,l.nodeValue=""):l.nodeValue=l._stashedText||""),n&&n.nodeType===8)if(l=n.data,l==="/$"){if(e===0)break;e--}else l!=="$"&&l!=="$?"&&l!=="$~"&&l!=="$!"||e++;l=n}while(l)}function Cc(e){var t=e.firstChild;for(t&&t.nodeType===10&&(t=t.nextSibling);t;){var l=t;switch(t=t.nextSibling,l.nodeName){case"HTML":case"HEAD":case"BODY":Cc(l),ku(l);continue;case"SCRIPT":case"STYLE":continue;case"LINK":if(l.rel.toLowerCase()==="stylesheet")continue}e.removeChild(l)}}function Sy(e,t,l,n){for(;e.nodeType===1;){var a=l;if(e.nodeName.toLowerCase()!==t.toLowerCase()){if(!n&&(e.nodeName!=="INPUT"||e.type!=="hidden"))break}else if(n){if(!e[Fn])switch(t){case"meta":if(!e.hasAttribute("itemprop"))break;return e;case"link":if(i=e.getAttribute("rel"),i==="stylesheet"&&e.hasAttribute("data-precedence"))break;if(i!==a.rel||e.getAttribute("href")!==(a.href==null||a.href===""?null:a.href)||e.getAttribute("crossorigin")!==(a.crossOrigin==null?null:a.crossOrigin)||e.getAttribute("title")!==(a.title==null?null:a.title))break;return e;case"style":if(e.hasAttribute("data-precedence"))break;return e;case"script":if(i=e.getAttribute("src"),(i!==(a.src==null?null:a.src)||e.getAttribute("type")!==(a.type==null?null:a.type)||e.getAttribute("crossorigin")!==(a.crossOrigin==null?null:a.crossOrigin))&&i&&e.hasAttribute("async")&&!e.hasAttribute("itemprop"))break;return e;default:return e}}else if(t==="input"&&e.type==="hidden"){var i=a.name==null?null:""+a.name;if(a.type==="hidden"&&e.getAttribute("name")===i)return e}else return e;if(e=wt(e.nextSibling),e===null)break}return null}function jy(e,t,l){if(t==="")return null;for(;e.nodeType!==3;)if((e.nodeType!==1||e.nodeName!=="INPUT"||e.type!=="hidden")&&!l||(e=wt(e.nextSibling),e===null))return null;return e}function Fd(e,t){for(;e.nodeType!==8;)if((e.nodeType!==1||e.nodeName!=="INPUT"||e.type!=="hidden")&&!t||(e=wt(e.nextSibling),e===null))return null;return e}function Mc(e){return e.data==="$?"||e.data==="$~"}function Oc(e){return e.data==="$!"||e.data==="$?"&&e.ownerDocument.readyState!=="loading"}function Ey(e,t){var l=e.ownerDocument;if(e.data==="$~")e._reactRetry=t;else if(e.data!=="$?"||l.readyState!=="loading")t();else{var n=function(){t(),l.removeEventListener("DOMContentLoaded",n)};l.addEventListener("DOMContentLoaded",n),e._reactRetry=n}}function wt(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==="$?"||t==="$~"||t==="&"||t==="F!"||t==="F")break;if(t==="/$"||t==="/&")return null}}return e}var Dc=null;function Wd(e){e=e.nextSibling;for(var t=0;e;){if(e.nodeType===8){var l=e.data;if(l==="/$"||l==="/&"){if(t===0)return wt(e.nextSibling);t--}else l!=="$"&&l!=="$!"&&l!=="$?"&&l!=="$~"&&l!=="&"||t++}e=e.nextSibling}return null}function Id(e){e=e.previousSibling;for(var t=0;e;){if(e.nodeType===8){var l=e.data;if(l==="$"||l==="$!"||l==="$?"||l==="$~"||l==="&"){if(t===0)return e;t--}else l!=="/$"&&l!=="/&"||t++}e=e.previousSibling}return null}function Pd(e,t,l){switch(t=tu(l),e){case"html":if(e=t.documentElement,!e)throw Error(r(452));return e;case"head":if(e=t.head,!e)throw Error(r(453));return e;case"body":if(e=t.body,!e)throw Error(r(454));return e;default:throw Error(r(451))}}function Ma(e){for(var t=e.attributes;t.length;)e.removeAttributeNode(t[0]);ku(e)}var zt=new Map,eh=new Set;function lu(e){return typeof e.getRootNode=="function"?e.getRootNode():e.nodeType===9?e:e.ownerDocument}var cl=K.d;K.d={f:Ty,r:_y,D:Ny,C:Ay,L:Ry,m:wy,X:Cy,S:zy,M:My};function Ty(){var e=cl.f(),t=Ki();return e||t}function _y(e){var t=cn(e);t!==null&&t.tag===5&&t.type==="form"?pf(t):cl.r(e)}var qn=typeof document>"u"?null:document;function th(e,t,l){var n=qn;if(n&&typeof t=="string"&&t){var a=jt(t);a='link[rel="'+e+'"][href="'+a+'"]',typeof l=="string"&&(a+='[crossorigin="'+l+'"]'),eh.has(a)||(eh.add(a),e={rel:e,crossOrigin:l,href:t},n.querySelector(a)===null&&(t=n.createElement("link"),Ke(t,"link",e),Ye(t),n.head.appendChild(t)))}}function Ny(e){cl.D(e),th("dns-prefetch",e,null)}function Ay(e,t){cl.C(e,t),th("preconnect",e,t)}function Ry(e,t,l){cl.L(e,t,l);var n=qn;if(n&&e&&t){var a='link[rel="preload"][as="'+jt(t)+'"]';t==="image"&&l&&l.imageSrcSet?(a+='[imagesrcset="'+jt(l.imageSrcSet)+'"]',typeof l.imageSizes=="string"&&(a+='[imagesizes="'+jt(l.imageSizes)+'"]')):a+='[href="'+jt(e)+'"]';var i=a;switch(t){case"style":i=Yn(e);break;case"script":i=Gn(e)}zt.has(i)||(e=p({rel:"preload",href:t==="image"&&l&&l.imageSrcSet?void 0:e,as:t},l),zt.set(i,e),n.querySelector(a)!==null||t==="style"&&n.querySelector(Oa(i))||t==="script"&&n.querySelector(Da(i))||(t=n.createElement("link"),Ke(t,"link",e),Ye(t),n.head.appendChild(t)))}}function wy(e,t){cl.m(e,t);var l=qn;if(l&&e){var n=t&&typeof t.as=="string"?t.as:"script",a='link[rel="modulepreload"][as="'+jt(n)+'"][href="'+jt(e)+'"]',i=a;switch(n){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":i=Gn(e)}if(!zt.has(i)&&(e=p({rel:"modulepreload",href:e},t),zt.set(i,e),l.querySelector(a)===null)){switch(n){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(l.querySelector(Da(i)))return}n=l.createElement("link"),Ke(n,"link",e),Ye(n),l.head.appendChild(n)}}}function zy(e,t,l){cl.S(e,t,l);var n=qn;if(n&&e){var a=rn(n).hoistableStyles,i=Yn(e);t=t||"default";var o=a.get(i);if(!o){var d={loading:0,preload:null};if(o=n.querySelector(Oa(i)))d.loading=5;else{e=p({rel:"stylesheet",href:e,"data-precedence":t},l),(l=zt.get(i))&&Uc(e,l);var g=o=n.createElement("link");Ye(g),Ke(g,"link",e),g._p=new Promise(function(A,C){g.onload=A,g.onerror=C}),g.addEventListener("load",function(){d.loading|=1}),g.addEventListener("error",function(){d.loading|=2}),d.loading|=4,nu(o,t,n)}o={type:"stylesheet",instance:o,count:1,state:d},a.set(i,o)}}}function Cy(e,t){cl.X(e,t);var l=qn;if(l&&e){var n=rn(l).hoistableScripts,a=Gn(e),i=n.get(a);i||(i=l.querySelector(Da(a)),i||(e=p({src:e,async:!0},t),(t=zt.get(a))&&kc(e,t),i=l.createElement("script"),Ye(i),Ke(i,"link",e),l.head.appendChild(i)),i={type:"script",instance:i,count:1,state:null},n.set(a,i))}}function My(e,t){cl.M(e,t);var l=qn;if(l&&e){var n=rn(l).hoistableScripts,a=Gn(e),i=n.get(a);i||(i=l.querySelector(Da(a)),i||(e=p({src:e,async:!0,type:"module"},t),(t=zt.get(a))&&kc(e,t),i=l.createElement("script"),Ye(i),Ke(i,"link",e),l.head.appendChild(i)),i={type:"script",instance:i,count:1,state:null},n.set(a,i))}}function lh(e,t,l,n){var a=(a=ue.current)?lu(a):null;if(!a)throw Error(r(446));switch(e){case"meta":case"title":return null;case"style":return typeof l.precedence=="string"&&typeof l.href=="string"?(t=Yn(l.href),l=rn(a).hoistableStyles,n=l.get(t),n||(n={type:"style",instance:null,count:0,state:null},l.set(t,n)),n):{type:"void",instance:null,count:0,state:null};case"link":if(l.rel==="stylesheet"&&typeof l.href=="string"&&typeof l.precedence=="string"){e=Yn(l.href);var i=rn(a).hoistableStyles,o=i.get(e);if(o||(a=a.ownerDocument||a,o={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},i.set(e,o),(i=a.querySelector(Oa(e)))&&!i._p&&(o.instance=i,o.state.loading=5),zt.has(e)||(l={rel:"preload",as:"style",href:l.href,crossOrigin:l.crossOrigin,integrity:l.integrity,media:l.media,hrefLang:l.hrefLang,referrerPolicy:l.referrerPolicy},zt.set(e,l),i||Oy(a,e,l,o.state))),t&&n===null)throw Error(r(528,""));return o}if(t&&n!==null)throw Error(r(529,""));return null;case"script":return t=l.async,l=l.src,typeof l=="string"&&t&&typeof t!="function"&&typeof t!="symbol"?(t=Gn(l),l=rn(a).hoistableScripts,n=l.get(t),n||(n={type:"script",instance:null,count:0,state:null},l.set(t,n)),n):{type:"void",instance:null,count:0,state:null};default:throw Error(r(444,e))}}function Yn(e){return'href="'+jt(e)+'"'}function Oa(e){return'link[rel="stylesheet"]['+e+"]"}function nh(e){return p({},e,{"data-precedence":e.precedence,precedence:null})}function Oy(e,t,l,n){e.querySelector('link[rel="preload"][as="style"]['+t+"]")?n.loading=1:(t=e.createElement("link"),n.preload=t,t.addEventListener("load",function(){return n.loading|=1}),t.addEventListener("error",function(){return n.loading|=2}),Ke(t,"link",l),Ye(t),e.head.appendChild(t))}function Gn(e){return'[src="'+jt(e)+'"]'}function Da(e){return"script[async]"+e}function ah(e,t,l){if(t.count++,t.instance===null)switch(t.type){case"style":var n=e.querySelector('style[data-href~="'+jt(l.href)+'"]');if(n)return t.instance=n,Ye(n),n;var a=p({},l,{"data-href":l.href,"data-precedence":l.precedence,href:null,precedence:null});return n=(e.ownerDocument||e).createElement("style"),Ye(n),Ke(n,"style",a),nu(n,l.precedence,e),t.instance=n;case"stylesheet":a=Yn(l.href);var i=e.querySelector(Oa(a));if(i)return t.state.loading|=4,t.instance=i,Ye(i),i;n=nh(l),(a=zt.get(a))&&Uc(n,a),i=(e.ownerDocument||e).createElement("link"),Ye(i);var o=i;return o._p=new Promise(function(d,g){o.onload=d,o.onerror=g}),Ke(i,"link",n),t.state.loading|=4,nu(i,l.precedence,e),t.instance=i;case"script":return i=Gn(l.src),(a=e.querySelector(Da(i)))?(t.instance=a,Ye(a),a):(n=l,(a=zt.get(i))&&(n=p({},l),kc(n,a)),e=e.ownerDocument||e,a=e.createElement("script"),Ye(a),Ke(a,"link",n),e.head.appendChild(a),t.instance=a);case"void":return null;default:throw Error(r(443,t.type))}else t.type==="stylesheet"&&(t.state.loading&4)===0&&(n=t.instance,t.state.loading|=4,nu(n,l.precedence,e));return t.instance}function nu(e,t,l){for(var n=l.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),a=n.length?n[n.length-1]:null,i=a,o=0;o<n.length;o++){var d=n[o];if(d.dataset.precedence===t)i=d;else if(i!==a)break}i?i.parentNode.insertBefore(e,i.nextSibling):(t=l.nodeType===9?l.head:l,t.insertBefore(e,t.firstChild))}function Uc(e,t){e.crossOrigin==null&&(e.crossOrigin=t.crossOrigin),e.referrerPolicy==null&&(e.referrerPolicy=t.referrerPolicy),e.title==null&&(e.title=t.title)}function kc(e,t){e.crossOrigin==null&&(e.crossOrigin=t.crossOrigin),e.referrerPolicy==null&&(e.referrerPolicy=t.referrerPolicy),e.integrity==null&&(e.integrity=t.integrity)}var au=null;function ih(e,t,l){if(au===null){var n=new Map,a=au=new Map;a.set(l,n)}else a=au,n=a.get(l),n||(n=new Map,a.set(l,n));if(n.has(e))return n;for(n.set(e,null),l=l.getElementsByTagName(e),a=0;a<l.length;a++){var i=l[a];if(!(i[Fn]||i[Ve]||e==="link"&&i.getAttribute("rel")==="stylesheet")&&i.namespaceURI!=="http://www.w3.org/2000/svg"){var o=i.getAttribute(t)||"";o=e+o;var d=n.get(o);d?d.push(i):n.set(o,[i])}}return n}function uh(e,t,l){e=e.ownerDocument||e,e.head.insertBefore(l,t==="title"?e.querySelector("head > title"):null)}function Dy(e,t,l){if(l===1||t.itemProp!=null)return!1;switch(e){case"meta":case"title":return!0;case"style":if(typeof t.precedence!="string"||typeof t.href!="string"||t.href==="")break;return!0;case"link":if(typeof t.rel!="string"||typeof t.href!="string"||t.href===""||t.onLoad||t.onError)break;switch(t.rel){case"stylesheet":return e=t.disabled,typeof t.precedence=="string"&&e==null;default:return!0}case"script":if(t.async&&typeof t.async!="function"&&typeof t.async!="symbol"&&!t.onLoad&&!t.onError&&t.src&&typeof t.src=="string")return!0}return!1}function sh(e){return!(e.type==="stylesheet"&&(e.state.loading&3)===0)}function Uy(e,t,l,n){if(l.type==="stylesheet"&&(typeof n.media!="string"||matchMedia(n.media).matches!==!1)&&(l.state.loading&4)===0){if(l.instance===null){var a=Yn(n.href),i=t.querySelector(Oa(a));if(i){t=i._p,t!==null&&typeof t=="object"&&typeof t.then=="function"&&(e.count++,e=iu.bind(e),t.then(e,e)),l.state.loading|=4,l.instance=i,Ye(i);return}i=t.ownerDocument||t,n=nh(n),(a=zt.get(a))&&Uc(n,a),i=i.createElement("link"),Ye(i);var o=i;o._p=new Promise(function(d,g){o.onload=d,o.onerror=g}),Ke(i,"link",n),l.instance=i}e.stylesheets===null&&(e.stylesheets=new Map),e.stylesheets.set(l,t),(t=l.state.preload)&&(l.state.loading&3)===0&&(e.count++,l=iu.bind(e),t.addEventListener("load",l),t.addEventListener("error",l))}}var Hc=0;function ky(e,t){return e.stylesheets&&e.count===0&&su(e,e.stylesheets),0<e.count||0<e.imgCount?function(l){var n=setTimeout(function(){if(e.stylesheets&&su(e,e.stylesheets),e.unsuspend){var i=e.unsuspend;e.unsuspend=null,i()}},6e4+t);0<e.imgBytes&&Hc===0&&(Hc=62500*yy());var a=setTimeout(function(){if(e.waitingForImages=!1,e.count===0&&(e.stylesheets&&su(e,e.stylesheets),e.unsuspend)){var i=e.unsuspend;e.unsuspend=null,i()}},(e.imgBytes>Hc?50:800)+t);return e.unsuspend=l,function(){e.unsuspend=null,clearTimeout(n),clearTimeout(a)}}:null}function iu(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)su(this,this.stylesheets);else if(this.unsuspend){var e=this.unsuspend;this.unsuspend=null,e()}}}var uu=null;function su(e,t){e.stylesheets=null,e.unsuspend!==null&&(e.count++,uu=new Map,t.forEach(Hy,e),uu=null,iu.call(e))}function Hy(e,t){if(!(t.state.loading&4)){var l=uu.get(e);if(l)var n=l.get(null);else{l=new Map,uu.set(e,l);for(var a=e.querySelectorAll("link[data-precedence],style[data-precedence]"),i=0;i<a.length;i++){var o=a[i];(o.nodeName==="LINK"||o.getAttribute("media")!=="not all")&&(l.set(o.dataset.precedence,o),n=o)}n&&l.set(null,n)}a=t.instance,o=a.getAttribute("data-precedence"),i=l.get(o)||n,i===n&&l.set(null,a),l.set(o,a),this.count++,n=iu.bind(this),a.addEventListener("load",n),a.addEventListener("error",n),i?i.parentNode.insertBefore(a,i.nextSibling):(e=e.nodeType===9?e.head:e,e.insertBefore(a,e.firstChild)),t.state.loading|=4}}var Ua={$$typeof:k,Provider:null,Consumer:null,_currentValue:te,_currentValue2:te,_threadCount:0};function By(e,t,l,n,a,i,o,d,g){this.tag=1,this.containerInfo=e,this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.next=this.pendingContext=this.context=this.cancelPendingCommit=null,this.callbackPriority=0,this.expirationTimes=Mu(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Mu(0),this.hiddenUpdates=Mu(null),this.identifierPrefix=n,this.onUncaughtError=a,this.onCaughtError=i,this.onRecoverableError=o,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=g,this.incompleteTransitions=new Map}function ch(e,t,l,n,a,i,o,d,g,A,C,H){return e=new By(e,t,l,o,g,A,C,H,d),t=1,i===!0&&(t|=24),i=mt(3,null,null,t),e.current=i,i.stateNode=e,t=ys(),t.refCount++,e.pooledCache=t,t.refCount++,i.memoizedState={element:n,isDehydrated:l,cache:t},xs(i),e}function rh(e){return e?(e=bn,e):bn}function oh(e,t,l,n,a,i){a=rh(a),n.context===null?n.context=a:n.pendingContext=a,n=xl(t),n.payload={element:l},i=i===void 0?null:i,i!==null&&(n.callback=i),l=Sl(e,n,t),l!==null&&(ct(l,e,t),ha(l,e,t))}function fh(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var l=e.retryLane;e.retryLane=l!==0&&l<t?l:t}}function Bc(e,t){fh(e,t),(e=e.alternate)&&fh(e,t)}function dh(e){if(e.tag===13||e.tag===31){var t=Ql(e,67108864);t!==null&&ct(t,e,67108864),Bc(e,67108864)}}function hh(e){if(e.tag===13||e.tag===31){var t=bt();t=Ou(t);var l=Ql(e,t);l!==null&&ct(l,e,t),Bc(e,t)}}var cu=!0;function Ly(e,t,l,n){var a=M.T;M.T=null;var i=K.p;try{K.p=2,Lc(e,t,l,n)}finally{K.p=i,M.T=a}}function qy(e,t,l,n){var a=M.T;M.T=null;var i=K.p;try{K.p=8,Lc(e,t,l,n)}finally{K.p=i,M.T=a}}function Lc(e,t,l,n){if(cu){var a=qc(n);if(a===null)_c(e,t,n,ru,l),vh(e,n);else if(Gy(a,e,t,l,n))n.stopPropagation();else if(vh(e,n),t&4&&-1<Yy.indexOf(e)){for(;a!==null;){var i=cn(a);if(i!==null)switch(i.tag){case 3:if(i=i.stateNode,i.current.memoizedState.isDehydrated){var o=ql(i.pendingLanes);if(o!==0){var d=i;for(d.pendingLanes|=2,d.entangledLanes|=2;o;){var g=1<<31-dt(o);d.entanglements[1]|=g,o&=~g}Yt(i),(ve&6)===0&&(Qi=ot()+500,wa(0))}}break;case 31:case 13:d=Ql(i,2),d!==null&&ct(d,i,2),Ki(),Bc(i,2)}if(i=qc(n),i===null&&_c(e,t,n,ru,l),i===a)break;a=i}a!==null&&n.stopPropagation()}else _c(e,t,n,null,l)}}function qc(e){return e=Gu(e),Yc(e)}var ru=null;function Yc(e){if(ru=null,e=sn(e),e!==null){var t=m(e);if(t===null)e=null;else{var l=t.tag;if(l===13){if(e=y(t),e!==null)return e;e=null}else if(l===31){if(e=j(t),e!==null)return e;e=null}else if(l===3){if(t.stateNode.current.memoizedState.isDehydrated)return t.tag===3?t.stateNode.containerInfo:null;e=null}else t!==e&&(e=null)}}return ru=e,null}function mh(e){switch(e){case"beforetoggle":case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"resize":case"seeked":case"submit":case"toggle":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 2;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 8;case"message":switch(Nm()){case xr:return 2;case Sr:return 8;case Ia:case Am:return 32;case jr:return 268435456;default:return 32}default:return 32}}var Gc=!1,Ml=null,Ol=null,Dl=null,ka=new Map,Ha=new Map,Ul=[],Yy="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset".split(" ");function vh(e,t){switch(e){case"focusin":case"focusout":Ml=null;break;case"dragenter":case"dragleave":Ol=null;break;case"mouseover":case"mouseout":Dl=null;break;case"pointerover":case"pointerout":ka.delete(t.pointerId);break;case"gotpointercapture":case"lostpointercapture":Ha.delete(t.pointerId)}}function Ba(e,t,l,n,a,i){return e===null||e.nativeEvent!==i?(e={blockedOn:t,domEventName:l,eventSystemFlags:n,nativeEvent:i,targetContainers:[a]},t!==null&&(t=cn(t),t!==null&&dh(t)),e):(e.eventSystemFlags|=n,t=e.targetContainers,a!==null&&t.indexOf(a)===-1&&t.push(a),e)}function Gy(e,t,l,n,a){switch(t){case"focusin":return Ml=Ba(Ml,e,t,l,n,a),!0;case"dragenter":return Ol=Ba(Ol,e,t,l,n,a),!0;case"mouseover":return Dl=Ba(Dl,e,t,l,n,a),!0;case"pointerover":var i=a.pointerId;return ka.set(i,Ba(ka.get(i)||null,e,t,l,n,a)),!0;case"gotpointercapture":return i=a.pointerId,Ha.set(i,Ba(Ha.get(i)||null,e,t,l,n,a)),!0}return!1}function yh(e){var t=sn(e.target);if(t!==null){var l=m(t);if(l!==null){if(t=l.tag,t===13){if(t=y(l),t!==null){e.blockedOn=t,Rr(e.priority,function(){hh(l)});return}}else if(t===31){if(t=j(l),t!==null){e.blockedOn=t,Rr(e.priority,function(){hh(l)});return}}else if(t===3&&l.stateNode.current.memoizedState.isDehydrated){e.blockedOn=l.tag===3?l.stateNode.containerInfo:null;return}}}e.blockedOn=null}function ou(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var l=qc(e.nativeEvent);if(l===null){l=e.nativeEvent;var n=new l.constructor(l.type,l);Yu=n,l.target.dispatchEvent(n),Yu=null}else return t=cn(l),t!==null&&dh(t),e.blockedOn=l,!1;t.shift()}return!0}function ph(e,t,l){ou(e)&&l.delete(t)}function Vy(){Gc=!1,Ml!==null&&ou(Ml)&&(Ml=null),Ol!==null&&ou(Ol)&&(Ol=null),Dl!==null&&ou(Dl)&&(Dl=null),ka.forEach(ph),Ha.forEach(ph)}function fu(e,t){e.blockedOn===t&&(e.blockedOn=null,Gc||(Gc=!0,u.unstable_scheduleCallback(u.unstable_NormalPriority,Vy)))}var du=null;function gh(e){du!==e&&(du=e,u.unstable_scheduleCallback(u.unstable_NormalPriority,function(){du===e&&(du=null);for(var t=0;t<e.length;t+=3){var l=e[t],n=e[t+1],a=e[t+2];if(typeof n!="function"){if(Yc(n||l)===null)continue;break}var i=cn(l);i!==null&&(e.splice(t,3),t-=3,qs(i,{pending:!0,data:a,method:l.method,action:n},n,a))}}))}function Vn(e){function t(g){return fu(g,e)}Ml!==null&&fu(Ml,e),Ol!==null&&fu(Ol,e),Dl!==null&&fu(Dl,e),ka.forEach(t),Ha.forEach(t);for(var l=0;l<Ul.length;l++){var n=Ul[l];n.blockedOn===e&&(n.blockedOn=null)}for(;0<Ul.length&&(l=Ul[0],l.blockedOn===null);)yh(l),l.blockedOn===null&&Ul.shift();if(l=(e.ownerDocument||e).$$reactFormReplay,l!=null)for(n=0;n<l.length;n+=3){var a=l[n],i=l[n+1],o=a[lt]||null;if(typeof i=="function")o||gh(l);else if(o){var d=null;if(i&&i.hasAttribute("formAction")){if(a=i,o=i[lt]||null)d=o.formAction;else if(Yc(a)!==null)continue}else d=o.action;typeof d=="function"?l[n+1]=d:(l.splice(n,3),n-=3),gh(l)}}}function bh(){function e(i){i.canIntercept&&i.info==="react-transition"&&i.intercept({handler:function(){return new Promise(function(o){return a=o})},focusReset:"manual",scroll:"manual"})}function t(){a!==null&&(a(),a=null),n||setTimeout(l,20)}function l(){if(!n&&!navigation.transition){var i=navigation.currentEntry;i&&i.url!=null&&navigation.navigate(i.url,{state:i.getState(),info:"react-transition",history:"replace"})}}if(typeof navigation=="object"){var n=!1,a=null;return navigation.addEventListener("navigate",e),navigation.addEventListener("navigatesuccess",t),navigation.addEventListener("navigateerror",t),setTimeout(l,100),function(){n=!0,navigation.removeEventListener("navigate",e),navigation.removeEventListener("navigatesuccess",t),navigation.removeEventListener("navigateerror",t),a!==null&&(a(),a=null)}}}function Vc(e){this._internalRoot=e}hu.prototype.render=Vc.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(r(409));var l=t.current,n=bt();oh(l,n,e,t,null,null)},hu.prototype.unmount=Vc.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;oh(e.current,2,null,e,null,null),Ki(),t[un]=null}};function hu(e){this._internalRoot=e}hu.prototype.unstable_scheduleHydration=function(e){if(e){var t=Ar();e={blockedOn:null,target:e,priority:t};for(var l=0;l<Ul.length&&t!==0&&t<Ul[l].priority;l++);Ul.splice(l,0,e),l===0&&yh(e)}};var xh=c.version;if(xh!=="19.2.5")throw Error(r(527,xh,"19.2.5"));K.findDOMNode=function(e){var t=e._reactInternals;if(t===void 0)throw typeof e.render=="function"?Error(r(188)):(e=Object.keys(e).join(","),Error(r(268,e)));return e=v(t),e=e!==null?T(e):null,e=e===null?null:e.stateNode,e};var Xy={bundleType:0,version:"19.2.5",rendererPackageName:"react-dom",currentDispatcherRef:M,reconcilerVersion:"19.2.5"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var mu=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!mu.isDisabled&&mu.supportsFiber)try{Kn=mu.inject(Xy),ft=mu}catch{}}return qa.createRoot=function(e,t){if(!h(e))throw Error(r(299));var l=!1,n="",a=Af,i=Rf,o=wf;return t!=null&&(t.unstable_strictMode===!0&&(l=!0),t.identifierPrefix!==void 0&&(n=t.identifierPrefix),t.onUncaughtError!==void 0&&(a=t.onUncaughtError),t.onCaughtError!==void 0&&(i=t.onCaughtError),t.onRecoverableError!==void 0&&(o=t.onRecoverableError)),t=ch(e,1,!1,null,null,l,n,null,a,i,o,bh),e[un]=t.current,Tc(e),new Vc(t)},qa.hydrateRoot=function(e,t,l){if(!h(e))throw Error(r(299));var n=!1,a="",i=Af,o=Rf,d=wf,g=null;return l!=null&&(l.unstable_strictMode===!0&&(n=!0),l.identifierPrefix!==void 0&&(a=l.identifierPrefix),l.onUncaughtError!==void 0&&(i=l.onUncaughtError),l.onCaughtError!==void 0&&(o=l.onCaughtError),l.onRecoverableError!==void 0&&(d=l.onRecoverableError),l.formState!==void 0&&(g=l.formState)),t=ch(e,1,!0,t,l??null,n,a,g,i,o,d,bh),t.context=rh(null),l=t.current,n=bt(),n=Ou(n),a=xl(n),a.callback=null,Sl(l,a,n),l=n,t.current.lanes=l,$n(t,l),Yt(t),e[un]=t.current,Tc(e),new hu(t)},qa.version="19.2.5",qa}var zh;function ep(){if(zh)return Zc.exports;zh=1;function u(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(u)}catch(c){console.error(c)}}return u(),Zc.exports=Py(),Zc.exports}var tp=ep();/**
|
|
50
|
+
* react-router v7.14.2
|
|
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
|
+
*/var Ch="popstate";function Mh(u){return typeof u=="object"&&u!=null&&"pathname"in u&&"search"in u&&"hash"in u&&"state"in u&&"key"in u}function lp(u={}){function c(r,h){var v;let m=(v=h.state)==null?void 0:v.masked,{pathname:y,search:j,hash:b}=m||r.location;return lr("",{pathname:y,search:j,hash:b},h.state&&h.state.usr||null,h.state&&h.state.key||"default",m?{pathname:r.location.pathname,search:r.location.search,hash:r.location.hash}:void 0)}function f(r,h){return typeof h=="string"?h:Xa(h)}return ap(c,f,null,u)}function we(u,c){if(u===!1||u===null||typeof u>"u")throw new Error(c)}function Vt(u,c){if(!u){typeof console<"u"&&console.warn(c);try{throw new Error(c)}catch{}}}function np(){return Math.random().toString(36).substring(2,10)}function Oh(u,c){return{usr:u.state,key:u.key,idx:c,masked:u.unstable_mask?{pathname:u.pathname,search:u.search,hash:u.hash}:void 0}}function lr(u,c,f=null,r,h){return{pathname:typeof u=="string"?u:u.pathname,search:"",hash:"",...typeof c=="string"?Xn(c):c,state:f,key:c&&c.key||r||np(),unstable_mask:h}}function Xa({pathname:u="/",search:c="",hash:f=""}){return c&&c!=="?"&&(u+=c.charAt(0)==="?"?c:"?"+c),f&&f!=="#"&&(u+=f.charAt(0)==="#"?f:"#"+f),u}function Xn(u){let c={};if(u){let f=u.indexOf("#");f>=0&&(c.hash=u.substring(f),u=u.substring(0,f));let r=u.indexOf("?");r>=0&&(c.search=u.substring(r),u=u.substring(0,r)),u&&(c.pathname=u)}return c}function ap(u,c,f,r={}){let{window:h=document.defaultView,v5Compat:m=!1}=r,y=h.history,j="POP",b=null,v=T();v==null&&(v=0,y.replaceState({...y.state,idx:v},""));function T(){return(y.state||{idx:null}).idx}function p(){j="POP";let V=T(),Y=V==null?null:V-v;v=V,b&&b({action:j,location:L.location,delta:Y})}function R(V,Y){j="PUSH";let Z=Mh(V)?V:lr(L.location,V,Y);v=T()+1;let k=Oh(Z,v),O=L.createHref(Z.unstable_mask||Z);try{y.pushState(k,"",O)}catch(q){if(q instanceof DOMException&&q.name==="DataCloneError")throw q;h.location.assign(O)}m&&b&&b({action:j,location:L.location,delta:1})}function G(V,Y){j="REPLACE";let Z=Mh(V)?V:lr(L.location,V,Y);v=T();let k=Oh(Z,v),O=L.createHref(Z.unstable_mask||Z);y.replaceState(k,"",O),m&&b&&b({action:j,location:L.location,delta:0})}function D(V){return ip(V)}let L={get action(){return j},get location(){return u(h,y)},listen(V){if(b)throw new Error("A history only accepts one active listener");return h.addEventListener(Ch,p),b=V,()=>{h.removeEventListener(Ch,p),b=null}},createHref(V){return c(h,V)},createURL:D,encodeLocation(V){let Y=D(V);return{pathname:Y.pathname,search:Y.search,hash:Y.hash}},push:R,replace:G,go(V){return y.go(V)}};return L}function ip(u,c=!1){let f="http://localhost";typeof window<"u"&&(f=window.location.origin!=="null"?window.location.origin:window.location.href),we(f,"No window.location.(origin|href) available to create URL");let r=typeof u=="string"?u:Xa(u);return r=r.replace(/ $/,"%20"),!c&&r.startsWith("//")&&(r=f+r),new URL(r,f)}function Zh(u,c,f="/"){return up(u,c,f,!1)}function up(u,c,f,r){let h=typeof c=="string"?Xn(c):c,m=ol(h.pathname||"/",f);if(m==null)return null;let y=Kh(u);sp(y);let j=null;for(let b=0;j==null&&b<y.length;++b){let v=gp(m);j=yp(y[b],v,r)}return j}function Kh(u,c=[],f=[],r="",h=!1){let m=(y,j,b=h,v)=>{let T={relativePath:v===void 0?y.path||"":v,caseSensitive:y.caseSensitive===!0,childrenIndex:j,route:y};if(T.relativePath.startsWith("/")){if(!T.relativePath.startsWith(r)&&b)return;we(T.relativePath.startsWith(r),`Absolute route path "${T.relativePath}" nested under path "${r}" is not valid. An absolute child route path must start with the combined path of all its parent routes.`),T.relativePath=T.relativePath.slice(r.length)}let p=kt([r,T.relativePath]),R=f.concat(T);y.children&&y.children.length>0&&(we(y.index!==!0,`Index routes must not have child routes. Please remove all child routes from route path "${p}".`),Kh(y.children,c,R,p,b)),!(y.path==null&&!y.index)&&c.push({path:p,score:mp(p,y.index),routesMeta:R})};return u.forEach((y,j)=>{var b;if(y.path===""||!((b=y.path)!=null&&b.includes("?")))m(y,j);else for(let v of Jh(y.path))m(y,j,!0,v)}),c}function Jh(u){let c=u.split("/");if(c.length===0)return[];let[f,...r]=c,h=f.endsWith("?"),m=f.replace(/\?$/,"");if(r.length===0)return h?[m,""]:[m];let y=Jh(r.join("/")),j=[];return j.push(...y.map(b=>b===""?m:[m,b].join("/"))),h&&j.push(...y),j.map(b=>u.startsWith("/")&&b===""?"/":b)}function sp(u){u.sort((c,f)=>c.score!==f.score?f.score-c.score:vp(c.routesMeta.map(r=>r.childrenIndex),f.routesMeta.map(r=>r.childrenIndex)))}var cp=/^:[\w-]+$/,rp=3,op=2,fp=1,dp=10,hp=-2,Dh=u=>u==="*";function mp(u,c){let f=u.split("/"),r=f.length;return f.some(Dh)&&(r+=hp),c&&(r+=op),f.filter(h=>!Dh(h)).reduce((h,m)=>h+(cp.test(m)?rp:m===""?fp:dp),r)}function vp(u,c){return u.length===c.length&&u.slice(0,-1).every((r,h)=>r===c[h])?u[u.length-1]-c[c.length-1]:0}function yp(u,c,f=!1){let{routesMeta:r}=u,h={},m="/",y=[];for(let j=0;j<r.length;++j){let b=r[j],v=j===r.length-1,T=m==="/"?c:c.slice(m.length)||"/",p=gu({path:b.relativePath,caseSensitive:b.caseSensitive,end:v},T),R=b.route;if(!p&&v&&f&&!r[r.length-1].route.index&&(p=gu({path:b.relativePath,caseSensitive:b.caseSensitive,end:!1},T)),!p)return null;Object.assign(h,p.params),y.push({params:h,pathname:kt([m,p.pathname]),pathnameBase:jp(kt([m,p.pathnameBase])),route:R}),p.pathnameBase!=="/"&&(m=kt([m,p.pathnameBase]))}return y}function gu(u,c){typeof u=="string"&&(u={path:u,caseSensitive:!1,end:!0});let[f,r]=pp(u.path,u.caseSensitive,u.end),h=c.match(f);if(!h)return null;let m=h[0],y=m.replace(/(.)\/+$/,"$1"),j=h.slice(1);return{params:r.reduce((v,{paramName:T,isOptional:p},R)=>{if(T==="*"){let D=j[R]||"";y=m.slice(0,m.length-D.length).replace(/(.)\/+$/,"$1")}const G=j[R];return p&&!G?v[T]=void 0:v[T]=(G||"").replace(/%2F/g,"/"),v},{}),pathname:m,pathnameBase:y,pattern:u}}function pp(u,c=!1,f=!0){Vt(u==="*"||!u.endsWith("*")||u.endsWith("/*"),`Route path "${u}" will be treated as if it were "${u.replace(/\*$/,"/*")}" because the \`*\` character must always follow a \`/\` in the pattern. To get rid of this warning, please change the route path to "${u.replace(/\*$/,"/*")}".`);let r=[],h="^"+u.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(y,j,b,v,T)=>{if(r.push({paramName:j,isOptional:b!=null}),b){let p=T.charAt(v+y.length);return p&&p!=="/"?"/([^\\/]*)":"(?:/([^\\/]*))?"}return"/([^\\/]+)"}).replace(/\/([\w-]+)\?(\/|$)/g,"(/$1)?$2");return u.endsWith("*")?(r.push({paramName:"*"}),h+=u==="*"||u==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):f?h+="\\/*$":u!==""&&u!=="/"&&(h+="(?:(?=\\/|$))"),[new RegExp(h,c?void 0:"i"),r]}function gp(u){try{return u.split("/").map(c=>decodeURIComponent(c).replace(/\//g,"%2F")).join("/")}catch(c){return Vt(!1,`The URL path "${u}" could not be decoded because it is a malformed URL segment. This is probably due to a bad percent encoding (${c}).`),u}}function ol(u,c){if(c==="/")return u;if(!u.toLowerCase().startsWith(c.toLowerCase()))return null;let f=c.endsWith("/")?c.length-1:c.length,r=u.charAt(f);return r&&r!=="/"?null:u.slice(f)||"/"}var bp=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i;function xp(u,c="/"){let{pathname:f,search:r="",hash:h=""}=typeof u=="string"?Xn(u):u,m;return f?(f=Fh(f),f.startsWith("/")?m=Uh(f.substring(1),"/"):m=Uh(f,c)):m=c,{pathname:m,search:Ep(r),hash:Tp(h)}}function Uh(u,c){let f=bu(c).split("/");return u.split("/").forEach(h=>{h===".."?f.length>1&&f.pop():h!=="."&&f.push(h)}),f.length>1?f.join("/"):"/"}function Fc(u,c,f,r){return`Cannot include a '${u}' character in a manually specified \`to.${c}\` field [${JSON.stringify(r)}]. Please separate it out to the \`to.${f}\` field. Alternatively you may provide the full path as a string in <Link to="..."> and the router will parse it for you.`}function Sp(u){return u.filter((c,f)=>f===0||c.route.path&&c.route.path.length>0)}function $h(u){let c=Sp(u);return c.map((f,r)=>r===c.length-1?f.pathname:f.pathnameBase)}function sr(u,c,f,r=!1){let h;typeof u=="string"?h=Xn(u):(h={...u},we(!h.pathname||!h.pathname.includes("?"),Fc("?","pathname","search",h)),we(!h.pathname||!h.pathname.includes("#"),Fc("#","pathname","hash",h)),we(!h.search||!h.search.includes("#"),Fc("#","search","hash",h)));let m=u===""||h.pathname==="",y=m?"/":h.pathname,j;if(y==null)j=f;else{let p=c.length-1;if(!r&&y.startsWith("..")){let R=y.split("/");for(;R[0]==="..";)R.shift(),p-=1;h.pathname=R.join("/")}j=p>=0?c[p]:"/"}let b=xp(h,j),v=y&&y!=="/"&&y.endsWith("/"),T=(m||y===".")&&f.endsWith("/");return!b.pathname.endsWith("/")&&(v||T)&&(b.pathname+="/"),b}var Fh=u=>u.replace(/\/\/+/g,"/"),kt=u=>Fh(u.join("/")),bu=u=>u.replace(/\/+$/,""),jp=u=>bu(u).replace(/^\/*/,"/"),Ep=u=>!u||u==="?"?"":u.startsWith("?")?u:"?"+u,Tp=u=>!u||u==="#"?"":u.startsWith("#")?u:"#"+u,_p=class{constructor(u,c,f,r=!1){this.status=u,this.statusText=c||"",this.internal=r,f instanceof Error?(this.data=f.toString(),this.error=f):this.data=f}};function Np(u){return u!=null&&typeof u.status=="number"&&typeof u.statusText=="string"&&typeof u.internal=="boolean"&&"data"in u}function Ap(u){let c=u.map(f=>f.route.path).filter(Boolean);return kt(c)||"/"}var Wh=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";function Ih(u,c){let f=u;if(typeof f!="string"||!bp.test(f))return{absoluteURL:void 0,isExternal:!1,to:f};let r=f,h=!1;if(Wh)try{let m=new URL(window.location.href),y=f.startsWith("//")?new URL(m.protocol+f):new URL(f),j=ol(y.pathname,c);y.origin===m.origin&&j!=null?f=j+y.search+y.hash:h=!0}catch{Vt(!1,`<Link to="${f}"> contains an invalid URL which will probably break when clicked - please update to a valid URL path.`)}return{absoluteURL:r,isExternal:h,to:f}}Object.getOwnPropertyNames(Object.prototype).sort().join("\0");var Ph=["POST","PUT","PATCH","DELETE"];new Set(Ph);var Rp=["GET",...Ph];new Set(Rp);var Qn=x.createContext(null);Qn.displayName="DataRouter";var Su=x.createContext(null);Su.displayName="DataRouterState";var em=x.createContext(!1);function wp(){return x.useContext(em)}var tm=x.createContext({isTransitioning:!1});tm.displayName="ViewTransition";var zp=x.createContext(new Map);zp.displayName="Fetchers";var Cp=x.createContext(null);Cp.displayName="Await";var Mt=x.createContext(null);Mt.displayName="Navigation";var Ka=x.createContext(null);Ka.displayName="Location";var Xt=x.createContext({outlet:null,matches:[],isDataRoute:!1});Xt.displayName="Route";var cr=x.createContext(null);cr.displayName="RouteError";var lm="REACT_ROUTER_ERROR",Mp="REDIRECT",Op="ROUTE_ERROR_RESPONSE";function Dp(u){if(u.startsWith(`${lm}:${Mp}:{`))try{let c=JSON.parse(u.slice(28));if(typeof c=="object"&&c&&typeof c.status=="number"&&typeof c.statusText=="string"&&typeof c.location=="string"&&typeof c.reloadDocument=="boolean"&&typeof c.replace=="boolean")return c}catch{}}function Up(u){if(u.startsWith(`${lm}:${Op}:{`))try{let c=JSON.parse(u.slice(40));if(typeof c=="object"&&c&&typeof c.status=="number"&&typeof c.statusText=="string")return new _p(c.status,c.statusText,c.data)}catch{}}function kp(u,{relative:c}={}){we(Ja(),"useHref() may be used only in the context of a <Router> component.");let{basename:f,navigator:r}=x.useContext(Mt),{hash:h,pathname:m,search:y}=$a(u,{relative:c}),j=m;return f!=="/"&&(j=m==="/"?f:kt([f,m])),r.createHref({pathname:j,search:y,hash:h})}function Ja(){return x.useContext(Ka)!=null}function fl(){return we(Ja(),"useLocation() may be used only in the context of a <Router> component."),x.useContext(Ka).location}var nm="You should call navigate() in a React.useEffect(), not when your component is first rendered.";function am(u){x.useContext(Mt).static||x.useLayoutEffect(u)}function Hp(){let{isDataRoute:u}=x.useContext(Xt);return u?Fp():Bp()}function Bp(){we(Ja(),"useNavigate() may be used only in the context of a <Router> component.");let u=x.useContext(Qn),{basename:c,navigator:f}=x.useContext(Mt),{matches:r}=x.useContext(Xt),{pathname:h}=fl(),m=JSON.stringify($h(r)),y=x.useRef(!1);return am(()=>{y.current=!0}),x.useCallback((b,v={})=>{if(Vt(y.current,nm),!y.current)return;if(typeof b=="number"){f.go(b);return}let T=sr(b,JSON.parse(m),h,v.relative==="path");u==null&&c!=="/"&&(T.pathname=T.pathname==="/"?c:kt([c,T.pathname])),(v.replace?f.replace:f.push)(T,v.state,v)},[c,f,m,h,u])}x.createContext(null);function rr(){let{matches:u}=x.useContext(Xt),c=u[u.length-1];return(c==null?void 0:c.params)??{}}function $a(u,{relative:c}={}){let{matches:f}=x.useContext(Xt),{pathname:r}=fl(),h=JSON.stringify($h(f));return x.useMemo(()=>sr(u,JSON.parse(h),r,c==="path"),[u,h,r,c])}function Lp(u,c){return im(u,c)}function im(u,c,f){var V;we(Ja(),"useRoutes() may be used only in the context of a <Router> component.");let{navigator:r}=x.useContext(Mt),{matches:h}=x.useContext(Xt),m=h[h.length-1],y=m?m.params:{},j=m?m.pathname:"/",b=m?m.pathnameBase:"/",v=m&&m.route;{let Y=v&&v.path||"";sm(j,!v||Y.endsWith("*")||Y.endsWith("*?"),`You rendered descendant <Routes> (or called \`useRoutes()\`) at "${j}" (under <Route path="${Y}">) but the parent route path has no trailing "*". This means if you navigate deeper, the parent won't match anymore and therefore the child routes will never render.
|
|
59
|
+
|
|
60
|
+
Please change the parent <Route path="${Y}"> to <Route path="${Y==="/"?"*":`${Y}/*`}">.`)}let T=fl(),p;if(c){let Y=typeof c=="string"?Xn(c):c;we(b==="/"||((V=Y.pathname)==null?void 0:V.startsWith(b)),`When overriding the location using \`<Routes location>\` or \`useRoutes(routes, location)\`, the location pathname must begin with the portion of the URL pathname that was matched by all parent routes. The current pathname base is "${b}" but pathname "${Y.pathname}" was given in the \`location\` prop.`),p=Y}else p=T;let R=p.pathname||"/",G=R;if(b!=="/"){let Y=b.replace(/^\//,"").split("/");G="/"+R.replace(/^\//,"").split("/").slice(Y.length).join("/")}let D=Zh(u,{pathname:G});Vt(v||D!=null,`No routes matched location "${p.pathname}${p.search}${p.hash}" `),Vt(D==null||D[D.length-1].route.element!==void 0||D[D.length-1].route.Component!==void 0||D[D.length-1].route.lazy!==void 0,`Matched leaf route at location "${p.pathname}${p.search}${p.hash}" does not have an element or Component. This means it will render an <Outlet /> with a null value by default resulting in an "empty" page.`);let L=Xp(D&&D.map(Y=>Object.assign({},Y,{params:Object.assign({},y,Y.params),pathname:kt([b,r.encodeLocation?r.encodeLocation(Y.pathname.replace(/%/g,"%25").replace(/\?/g,"%3F").replace(/#/g,"%23")).pathname:Y.pathname]),pathnameBase:Y.pathnameBase==="/"?b:kt([b,r.encodeLocation?r.encodeLocation(Y.pathnameBase.replace(/%/g,"%25").replace(/\?/g,"%3F").replace(/#/g,"%23")).pathname:Y.pathnameBase])})),h,f);return c&&L?x.createElement(Ka.Provider,{value:{location:{pathname:"/",search:"",hash:"",state:null,key:"default",unstable_mask:void 0,...p},navigationType:"POP"}},L):L}function qp(){let u=$p(),c=Np(u)?`${u.status} ${u.statusText}`:u instanceof Error?u.message:JSON.stringify(u),f=u instanceof Error?u.stack:null,r="rgba(200,200,200, 0.5)",h={padding:"0.5rem",backgroundColor:r},m={padding:"2px 4px",backgroundColor:r},y=null;return console.error("Error handled by React Router default ErrorBoundary:",u),y=x.createElement(x.Fragment,null,x.createElement("p",null,"💿 Hey developer 👋"),x.createElement("p",null,"You can provide a way better UX than this when your app throws errors by providing your own ",x.createElement("code",{style:m},"ErrorBoundary")," or"," ",x.createElement("code",{style:m},"errorElement")," prop on your route.")),x.createElement(x.Fragment,null,x.createElement("h2",null,"Unexpected Application Error!"),x.createElement("h3",{style:{fontStyle:"italic"}},c),f?x.createElement("pre",{style:h},f):null,y)}var Yp=x.createElement(qp,null),um=class extends x.Component{constructor(u){super(u),this.state={location:u.location,revalidation:u.revalidation,error:u.error}}static getDerivedStateFromError(u){return{error:u}}static getDerivedStateFromProps(u,c){return c.location!==u.location||c.revalidation!=="idle"&&u.revalidation==="idle"?{error:u.error,location:u.location,revalidation:u.revalidation}:{error:u.error!==void 0?u.error:c.error,location:c.location,revalidation:u.revalidation||c.revalidation}}componentDidCatch(u,c){this.props.onError?this.props.onError(u,c):console.error("React Router caught the following error during render",u)}render(){let u=this.state.error;if(this.context&&typeof u=="object"&&u&&"digest"in u&&typeof u.digest=="string"){const f=Up(u.digest);f&&(u=f)}let c=u!==void 0?x.createElement(Xt.Provider,{value:this.props.routeContext},x.createElement(cr.Provider,{value:u,children:this.props.component})):this.props.children;return this.context?x.createElement(Gp,{error:u},c):c}};um.contextType=em;var Wc=new WeakMap;function Gp({children:u,error:c}){let{basename:f}=x.useContext(Mt);if(typeof c=="object"&&c&&"digest"in c&&typeof c.digest=="string"){let r=Dp(c.digest);if(r){let h=Wc.get(c);if(h)throw h;let m=Ih(r.location,f);if(Wh&&!Wc.get(c))if(m.isExternal||r.reloadDocument)window.location.href=m.absoluteURL||m.to;else{const y=Promise.resolve().then(()=>window.__reactRouterDataRouter.navigate(m.to,{replace:r.replace}));throw Wc.set(c,y),y}return x.createElement("meta",{httpEquiv:"refresh",content:`0;url=${m.absoluteURL||m.to}`})}}return u}function Vp({routeContext:u,match:c,children:f}){let r=x.useContext(Qn);return r&&r.static&&r.staticContext&&(c.route.errorElement||c.route.ErrorBoundary)&&(r.staticContext._deepestRenderedBoundaryId=c.route.id),x.createElement(Xt.Provider,{value:u},f)}function Xp(u,c=[],f){let r=f==null?void 0:f.state;if(u==null){if(!r)return null;if(r.errors)u=r.matches;else if(c.length===0&&!r.initialized&&r.matches.length>0)u=r.matches;else return null}let h=u,m=r==null?void 0:r.errors;if(m!=null){let T=h.findIndex(p=>p.route.id&&(m==null?void 0:m[p.route.id])!==void 0);we(T>=0,`Could not find a matching route for errors on route IDs: ${Object.keys(m).join(",")}`),h=h.slice(0,Math.min(h.length,T+1))}let y=!1,j=-1;if(f&&r){y=r.renderFallback;for(let T=0;T<h.length;T++){let p=h[T];if((p.route.HydrateFallback||p.route.hydrateFallbackElement)&&(j=T),p.route.id){let{loaderData:R,errors:G}=r,D=p.route.loader&&!R.hasOwnProperty(p.route.id)&&(!G||G[p.route.id]===void 0);if(p.route.lazy||D){f.isStatic&&(y=!0),j>=0?h=h.slice(0,j+1):h=[h[0]];break}}}}let b=f==null?void 0:f.onError,v=r&&b?(T,p)=>{var R,G;b(T,{location:r.location,params:((G=(R=r.matches)==null?void 0:R[0])==null?void 0:G.params)??{},unstable_pattern:Ap(r.matches),errorInfo:p})}:void 0;return h.reduceRight((T,p,R)=>{let G,D=!1,L=null,V=null;r&&(G=m&&p.route.id?m[p.route.id]:void 0,L=p.route.errorElement||Yp,y&&(j<0&&R===0?(sm("route-fallback",!1,"No `HydrateFallback` element provided to render during initial hydration"),D=!0,V=null):j===R&&(D=!0,V=p.route.hydrateFallbackElement||null)));let Y=c.concat(h.slice(0,R+1)),Z=()=>{let k;return G?k=L:D?k=V:p.route.Component?k=x.createElement(p.route.Component,null):p.route.element?k=p.route.element:k=T,x.createElement(Vp,{match:p,routeContext:{outlet:T,matches:Y,isDataRoute:r!=null},children:k})};return r&&(p.route.ErrorBoundary||p.route.errorElement||R===0)?x.createElement(um,{location:r.location,revalidation:r.revalidation,component:L,error:G,children:Z(),routeContext:{outlet:null,matches:Y,isDataRoute:!0},onError:v}):Z()},null)}function or(u){return`${u} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function Qp(u){let c=x.useContext(Qn);return we(c,or(u)),c}function Zp(u){let c=x.useContext(Su);return we(c,or(u)),c}function Kp(u){let c=x.useContext(Xt);return we(c,or(u)),c}function fr(u){let c=Kp(u),f=c.matches[c.matches.length-1];return we(f.route.id,`${u} can only be used on routes that contain a unique "id"`),f.route.id}function Jp(){return fr("useRouteId")}function $p(){var r;let u=x.useContext(cr),c=Zp("useRouteError"),f=fr("useRouteError");return u!==void 0?u:(r=c.errors)==null?void 0:r[f]}function Fp(){let{router:u}=Qp("useNavigate"),c=fr("useNavigate"),f=x.useRef(!1);return am(()=>{f.current=!0}),x.useCallback(async(h,m={})=>{Vt(f.current,nm),f.current&&(typeof h=="number"?await u.navigate(h):await u.navigate(h,{fromRouteId:c,...m}))},[u,c])}var kh={};function sm(u,c,f){!c&&!kh[u]&&(kh[u]=!0,Vt(!1,f))}x.memo(Wp);function Wp({routes:u,future:c,state:f,isStatic:r,onError:h}){return im(u,void 0,{state:f,isStatic:r,onError:h})}function Ct(u){we(!1,"A <Route> is only ever to be used as the child of <Routes> element, never rendered directly. Please wrap your <Route> in a <Routes>.")}function Ip({basename:u="/",children:c=null,location:f,navigationType:r="POP",navigator:h,static:m=!1,unstable_useTransitions:y}){we(!Ja(),"You cannot render a <Router> inside another <Router>. You should never have more than one in your app.");let j=u.replace(/^\/*/,"/"),b=x.useMemo(()=>({basename:j,navigator:h,static:m,unstable_useTransitions:y,future:{}}),[j,h,m,y]);typeof f=="string"&&(f=Xn(f));let{pathname:v="/",search:T="",hash:p="",state:R=null,key:G="default",unstable_mask:D}=f,L=x.useMemo(()=>{let V=ol(v,j);return V==null?null:{location:{pathname:V,search:T,hash:p,state:R,key:G,unstable_mask:D},navigationType:r}},[j,v,T,p,R,G,r,D]);return Vt(L!=null,`<Router basename="${j}"> is not able to match the URL "${v}${T}${p}" because it does not start with the basename, so the <Router> won't render anything.`),L==null?null:x.createElement(Mt.Provider,{value:b},x.createElement(Ka.Provider,{children:c,value:L}))}function Ic({children:u,location:c}){return Lp(nr(u),c)}function nr(u,c=[]){let f=[];return x.Children.forEach(u,(r,h)=>{if(!x.isValidElement(r))return;let m=[...c,h];if(r.type===x.Fragment){f.push.apply(f,nr(r.props.children,m));return}we(r.type===Ct,`[${typeof r.type=="string"?r.type:r.type.name}] is not a <Route> component. All component children of <Routes> must be a <Route> or <React.Fragment>`),we(!r.props.index||!r.props.children,"An index route cannot have child routes.");let y={id:r.props.id||m.join("-"),caseSensitive:r.props.caseSensitive,element:r.props.element,Component:r.props.Component,index:r.props.index,path:r.props.path,middleware:r.props.middleware,loader:r.props.loader,action:r.props.action,hydrateFallbackElement:r.props.hydrateFallbackElement,HydrateFallback:r.props.HydrateFallback,errorElement:r.props.errorElement,ErrorBoundary:r.props.ErrorBoundary,hasErrorBoundary:r.props.hasErrorBoundary===!0||r.props.ErrorBoundary!=null||r.props.errorElement!=null,shouldRevalidate:r.props.shouldRevalidate,handle:r.props.handle,lazy:r.props.lazy};r.props.children&&(y.children=nr(r.props.children,m)),f.push(y)}),f}var yu="get",pu="application/x-www-form-urlencoded";function ju(u){return typeof HTMLElement<"u"&&u instanceof HTMLElement}function Pp(u){return ju(u)&&u.tagName.toLowerCase()==="button"}function eg(u){return ju(u)&&u.tagName.toLowerCase()==="form"}function tg(u){return ju(u)&&u.tagName.toLowerCase()==="input"}function lg(u){return!!(u.metaKey||u.altKey||u.ctrlKey||u.shiftKey)}function ng(u,c){return u.button===0&&(!c||c==="_self")&&!lg(u)}var vu=null;function ag(){if(vu===null)try{new FormData(document.createElement("form"),0),vu=!1}catch{vu=!0}return vu}var ig=new Set(["application/x-www-form-urlencoded","multipart/form-data","text/plain"]);function Pc(u){return u!=null&&!ig.has(u)?(Vt(!1,`"${u}" is not a valid \`encType\` for \`<Form>\`/\`<fetcher.Form>\` and will default to "${pu}"`),null):u}function ug(u,c){let f,r,h,m,y;if(eg(u)){let j=u.getAttribute("action");r=j?ol(j,c):null,f=u.getAttribute("method")||yu,h=Pc(u.getAttribute("enctype"))||pu,m=new FormData(u)}else if(Pp(u)||tg(u)&&(u.type==="submit"||u.type==="image")){let j=u.form;if(j==null)throw new Error('Cannot submit a <button> or <input type="submit"> without a <form>');let b=u.getAttribute("formaction")||j.getAttribute("action");if(r=b?ol(b,c):null,f=u.getAttribute("formmethod")||j.getAttribute("method")||yu,h=Pc(u.getAttribute("formenctype"))||Pc(j.getAttribute("enctype"))||pu,m=new FormData(j,u),!ag()){let{name:v,type:T,value:p}=u;if(T==="image"){let R=v?`${v}.`:"";m.append(`${R}x`,"0"),m.append(`${R}y`,"0")}else v&&m.append(v,p)}}else{if(ju(u))throw new Error('Cannot submit element that is not <form>, <button>, or <input type="submit|image">');f=yu,r=null,h=pu,y=u}return m&&h==="text/plain"&&(y=m,m=void 0),{action:r,method:f.toLowerCase(),encType:h,formData:m,body:y}}Object.getOwnPropertyNames(Object.prototype).sort().join("\0");function dr(u,c){if(u===!1||u===null||typeof u>"u")throw new Error(c)}function cm(u,c,f,r){let h=typeof u=="string"?new URL(u,typeof window>"u"?"server://singlefetch/":window.location.origin):u;return f?h.pathname.endsWith("/")?h.pathname=`${h.pathname}_.${r}`:h.pathname=`${h.pathname}.${r}`:h.pathname==="/"?h.pathname=`_root.${r}`:c&&ol(h.pathname,c)==="/"?h.pathname=`${bu(c)}/_root.${r}`:h.pathname=`${bu(h.pathname)}.${r}`,h}async function sg(u,c){if(u.id in c)return c[u.id];try{let f=await import(u.module);return c[u.id]=f,f}catch(f){return console.error(`Error loading route module \`${u.module}\`, reloading page...`),console.error(f),window.__reactRouterContext&&window.__reactRouterContext.isSpaMode,window.location.reload(),new Promise(()=>{})}}function cg(u){return u==null?!1:u.href==null?u.rel==="preload"&&typeof u.imageSrcSet=="string"&&typeof u.imageSizes=="string":typeof u.rel=="string"&&typeof u.href=="string"}async function rg(u,c,f){let r=await Promise.all(u.map(async h=>{let m=c.routes[h.route.id];if(m){let y=await sg(m,f);return y.links?y.links():[]}return[]}));return hg(r.flat(1).filter(cg).filter(h=>h.rel==="stylesheet"||h.rel==="preload").map(h=>h.rel==="stylesheet"?{...h,rel:"prefetch",as:"style"}:{...h,rel:"prefetch"}))}function Hh(u,c,f,r,h,m){let y=(b,v)=>f[v]?b.route.id!==f[v].route.id:!0,j=(b,v)=>{var T;return f[v].pathname!==b.pathname||((T=f[v].route.path)==null?void 0:T.endsWith("*"))&&f[v].params["*"]!==b.params["*"]};return m==="assets"?c.filter((b,v)=>y(b,v)||j(b,v)):m==="data"?c.filter((b,v)=>{var p;let T=r.routes[b.route.id];if(!T||!T.hasLoader)return!1;if(y(b,v)||j(b,v))return!0;if(b.route.shouldRevalidate){let R=b.route.shouldRevalidate({currentUrl:new URL(h.pathname+h.search+h.hash,window.origin),currentParams:((p=f[0])==null?void 0:p.params)||{},nextUrl:new URL(u,window.origin),nextParams:b.params,defaultShouldRevalidate:!0});if(typeof R=="boolean")return R}return!0}):[]}function og(u,c,{includeHydrateFallback:f}={}){return fg(u.map(r=>{let h=c.routes[r.route.id];if(!h)return[];let m=[h.module];return h.clientActionModule&&(m=m.concat(h.clientActionModule)),h.clientLoaderModule&&(m=m.concat(h.clientLoaderModule)),f&&h.hydrateFallbackModule&&(m=m.concat(h.hydrateFallbackModule)),h.imports&&(m=m.concat(h.imports)),m}).flat(1))}function fg(u){return[...new Set(u)]}function dg(u){let c={},f=Object.keys(u).sort();for(let r of f)c[r]=u[r];return c}function hg(u,c){let f=new Set;return new Set(c),u.reduce((r,h)=>{let m=JSON.stringify(dg(h));return f.has(m)||(f.add(m),r.push({key:m,link:h})),r},[])}function hr(){let u=x.useContext(Qn);return dr(u,"You must render this element inside a <DataRouterContext.Provider> element"),u}function mg(){let u=x.useContext(Su);return dr(u,"You must render this element inside a <DataRouterStateContext.Provider> element"),u}var mr=x.createContext(void 0);mr.displayName="FrameworkContext";function vr(){let u=x.useContext(mr);return dr(u,"You must render this element inside a <HydratedRouter> element"),u}function vg(u,c){let f=x.useContext(mr),[r,h]=x.useState(!1),[m,y]=x.useState(!1),{onFocus:j,onBlur:b,onMouseEnter:v,onMouseLeave:T,onTouchStart:p}=c,R=x.useRef(null);x.useEffect(()=>{if(u==="render"&&y(!0),u==="viewport"){let L=Y=>{Y.forEach(Z=>{y(Z.isIntersecting)})},V=new IntersectionObserver(L,{threshold:.5});return R.current&&V.observe(R.current),()=>{V.disconnect()}}},[u]),x.useEffect(()=>{if(r){let L=setTimeout(()=>{y(!0)},100);return()=>{clearTimeout(L)}}},[r]);let G=()=>{h(!0)},D=()=>{h(!1),y(!1)};return f?u!=="intent"?[m,R,{}]:[m,R,{onFocus:Ya(j,G),onBlur:Ya(b,D),onMouseEnter:Ya(v,G),onMouseLeave:Ya(T,D),onTouchStart:Ya(p,G)}]:[!1,R,{}]}function Ya(u,c){return f=>{u&&u(f),f.defaultPrevented||c(f)}}function yg({page:u,...c}){let f=wp(),{router:r}=hr(),h=x.useMemo(()=>Zh(r.routes,u,r.basename),[r.routes,u,r.basename]);return h?f?x.createElement(gg,{page:u,matches:h,...c}):x.createElement(bg,{page:u,matches:h,...c}):null}function pg(u){let{manifest:c,routeModules:f}=vr(),[r,h]=x.useState([]);return x.useEffect(()=>{let m=!1;return rg(u,c,f).then(y=>{m||h(y)}),()=>{m=!0}},[u,c,f]),r}function gg({page:u,matches:c,...f}){let r=fl(),{future:h}=vr(),{basename:m}=hr(),y=x.useMemo(()=>{if(u===r.pathname+r.search+r.hash)return[];let j=cm(u,m,h.unstable_trailingSlashAwareDataRequests,"rsc"),b=!1,v=[];for(let T of c)typeof T.route.shouldRevalidate=="function"?b=!0:v.push(T.route.id);return b&&v.length>0&&j.searchParams.set("_routes",v.join(",")),[j.pathname+j.search]},[m,h.unstable_trailingSlashAwareDataRequests,u,r,c]);return x.createElement(x.Fragment,null,y.map(j=>x.createElement("link",{key:j,rel:"prefetch",as:"fetch",href:j,...f})))}function bg({page:u,matches:c,...f}){let r=fl(),{future:h,manifest:m,routeModules:y}=vr(),{basename:j}=hr(),{loaderData:b,matches:v}=mg(),T=x.useMemo(()=>Hh(u,c,v,m,r,"data"),[u,c,v,m,r]),p=x.useMemo(()=>Hh(u,c,v,m,r,"assets"),[u,c,v,m,r]),R=x.useMemo(()=>{if(u===r.pathname+r.search+r.hash)return[];let L=new Set,V=!1;if(c.forEach(Z=>{var O;let k=m.routes[Z.route.id];!k||!k.hasLoader||(!T.some(q=>q.route.id===Z.route.id)&&Z.route.id in b&&((O=y[Z.route.id])!=null&&O.shouldRevalidate)||k.hasClientLoader?V=!0:L.add(Z.route.id))}),L.size===0)return[];let Y=cm(u,j,h.unstable_trailingSlashAwareDataRequests,"data");return V&&L.size>0&&Y.searchParams.set("_routes",c.filter(Z=>L.has(Z.route.id)).map(Z=>Z.route.id).join(",")),[Y.pathname+Y.search]},[j,h.unstable_trailingSlashAwareDataRequests,b,r,m,T,c,u,y]),G=x.useMemo(()=>og(p,m),[p,m]),D=pg(p);return x.createElement(x.Fragment,null,R.map(L=>x.createElement("link",{key:L,rel:"prefetch",as:"fetch",href:L,...f})),G.map(L=>x.createElement("link",{key:L,rel:"modulepreload",href:L,...f})),D.map(({key:L,link:V})=>x.createElement("link",{key:L,nonce:f.nonce,...V,crossOrigin:V.crossOrigin??f.crossOrigin})))}function xg(...u){return c=>{u.forEach(f=>{typeof f=="function"?f(c):f!=null&&(f.current=c)})}}var Sg=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";try{Sg&&(window.__reactRouterVersion="7.14.2")}catch{}function jg({basename:u,children:c,unstable_useTransitions:f,window:r}){let h=x.useRef();h.current==null&&(h.current=lp({window:r,v5Compat:!0}));let m=h.current,[y,j]=x.useState({action:m.action,location:m.location}),b=x.useCallback(v=>{f===!1?j(v):x.startTransition(()=>j(v))},[f]);return x.useLayoutEffect(()=>m.listen(b),[m,b]),x.createElement(Ip,{basename:u,children:c,location:y.location,navigationType:y.action,navigator:m,unstable_useTransitions:f})}var rm=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,Je=x.forwardRef(function({onClick:c,discover:f="render",prefetch:r="none",relative:h,reloadDocument:m,replace:y,unstable_mask:j,state:b,target:v,to:T,preventScrollReset:p,viewTransition:R,unstable_defaultShouldRevalidate:G,...D},L){let{basename:V,navigator:Y,unstable_useTransitions:Z}=x.useContext(Mt),k=typeof T=="string"&&rm.test(T),O=Ih(T,V);T=O.to;let q=kp(T,{relative:h}),X=fl(),Q=null;if(j){let Ue=sr(j,[],X.unstable_mask?X.unstable_mask.pathname:"/",!0);V!=="/"&&(Ue.pathname=Ue.pathname==="/"?V:kt([V,Ue.pathname])),Q=Y.createHref(Ue)}let[ee,me,tt]=vg(r,D),We=Ng(T,{replace:y,unstable_mask:j,state:b,target:v,preventScrollReset:p,relative:h,viewTransition:R,unstable_defaultShouldRevalidate:G,unstable_useTransitions:Z});function $e(Ue){c&&c(Ue),Ue.defaultPrevented||We(Ue)}let Ht=!(O.isExternal||m),xt=x.createElement("a",{...D,...tt,href:(Ht?Q:void 0)||O.absoluteURL||q,onClick:Ht?$e:c,ref:xg(L,me),target:v,"data-discover":!k&&f==="render"?"true":void 0});return ee&&!k?x.createElement(x.Fragment,null,xt,x.createElement(yg,{page:q})):xt});Je.displayName="Link";var Eg=x.forwardRef(function({"aria-current":c="page",caseSensitive:f=!1,className:r="",end:h=!1,style:m,to:y,viewTransition:j,children:b,...v},T){let p=$a(y,{relative:v.relative}),R=fl(),G=x.useContext(Su),{navigator:D,basename:L}=x.useContext(Mt),V=G!=null&&Cg(p)&&j===!0,Y=D.encodeLocation?D.encodeLocation(p).pathname:p.pathname,Z=R.pathname,k=G&&G.navigation&&G.navigation.location?G.navigation.location.pathname:null;f||(Z=Z.toLowerCase(),k=k?k.toLowerCase():null,Y=Y.toLowerCase()),k&&L&&(k=ol(k,L)||k);const O=Y!=="/"&&Y.endsWith("/")?Y.length-1:Y.length;let q=Z===Y||!h&&Z.startsWith(Y)&&Z.charAt(O)==="/",X=k!=null&&(k===Y||!h&&k.startsWith(Y)&&k.charAt(Y.length)==="/"),Q={isActive:q,isPending:X,isTransitioning:V},ee=q?c:void 0,me;typeof r=="function"?me=r(Q):me=[r,q?"active":null,X?"pending":null,V?"transitioning":null].filter(Boolean).join(" ");let tt=typeof m=="function"?m(Q):m;return x.createElement(Je,{...v,"aria-current":ee,className:me,ref:T,style:tt,to:y,viewTransition:j},typeof b=="function"?b(Q):b)});Eg.displayName="NavLink";var Tg=x.forwardRef(({discover:u="render",fetcherKey:c,navigate:f,reloadDocument:r,replace:h,state:m,method:y=yu,action:j,onSubmit:b,relative:v,preventScrollReset:T,viewTransition:p,unstable_defaultShouldRevalidate:R,...G},D)=>{let{unstable_useTransitions:L}=x.useContext(Mt),V=wg(),Y=zg(j,{relative:v}),Z=y.toLowerCase()==="get"?"get":"post",k=typeof j=="string"&&rm.test(j),O=q=>{if(b&&b(q),q.defaultPrevented)return;q.preventDefault();let X=q.nativeEvent.submitter,Q=(X==null?void 0:X.getAttribute("formmethod"))||y,ee=()=>V(X||q.currentTarget,{fetcherKey:c,method:Q,navigate:f,replace:h,state:m,relative:v,preventScrollReset:T,viewTransition:p,unstable_defaultShouldRevalidate:R});L&&f!==!1?x.startTransition(()=>ee()):ee()};return x.createElement("form",{ref:D,method:Z,action:Y,onSubmit:r?b:O,...G,"data-discover":!k&&u==="render"?"true":void 0})});Tg.displayName="Form";function _g(u){return`${u} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function om(u){let c=x.useContext(Qn);return we(c,_g(u)),c}function Ng(u,{target:c,replace:f,unstable_mask:r,state:h,preventScrollReset:m,relative:y,viewTransition:j,unstable_defaultShouldRevalidate:b,unstable_useTransitions:v}={}){let T=Hp(),p=fl(),R=$a(u,{relative:y});return x.useCallback(G=>{if(ng(G,c)){G.preventDefault();let D=f!==void 0?f:Xa(p)===Xa(R),L=()=>T(u,{replace:D,unstable_mask:r,state:h,preventScrollReset:m,relative:y,viewTransition:j,unstable_defaultShouldRevalidate:b});v?x.startTransition(()=>L()):L()}},[p,T,R,f,r,h,c,u,m,y,j,b,v])}var Ag=0,Rg=()=>`__${String(++Ag)}__`;function wg(){let{router:u}=om("useSubmit"),{basename:c}=x.useContext(Mt),f=Jp(),r=u.fetch,h=u.navigate;return x.useCallback(async(m,y={})=>{let{action:j,method:b,encType:v,formData:T,body:p}=ug(m,c);if(y.navigate===!1){let R=y.fetcherKey||Rg();await r(R,f,y.action||j,{unstable_defaultShouldRevalidate:y.unstable_defaultShouldRevalidate,preventScrollReset:y.preventScrollReset,formData:T,body:p,formMethod:y.method||b,formEncType:y.encType||v,flushSync:y.flushSync})}else await h(y.action||j,{unstable_defaultShouldRevalidate:y.unstable_defaultShouldRevalidate,preventScrollReset:y.preventScrollReset,formData:T,body:p,formMethod:y.method||b,formEncType:y.encType||v,replace:y.replace,state:y.state,fromRouteId:f,flushSync:y.flushSync,viewTransition:y.viewTransition})},[r,h,c,f])}function zg(u,{relative:c}={}){let{basename:f}=x.useContext(Mt),r=x.useContext(Xt);we(r,"useFormAction must be used inside a RouteContext");let[h]=r.matches.slice(-1),m={...$a(u||".",{relative:c})},y=fl();if(u==null){m.search=y.search;let j=new URLSearchParams(m.search),b=j.getAll("index");if(b.some(T=>T==="")){j.delete("index"),b.filter(p=>p).forEach(p=>j.append("index",p));let T=j.toString();m.search=T?`?${T}`:""}}return(!u||u===".")&&h.route.index&&(m.search=m.search?m.search.replace(/^\?/,"?index&"):"?index"),f!=="/"&&(m.pathname=m.pathname==="/"?f:kt([f,m.pathname])),Xa(m)}function Cg(u,{relative:c}={}){let f=x.useContext(tm);we(f!=null,"`useViewTransitionState` must be used within `react-router-dom`'s `RouterProvider`. Did you accidentally import `RouterProvider` from `react-router`?");let{basename:r}=om("useViewTransitionState"),h=$a(u,{relative:c});if(!f.isTransitioning)return!1;let m=ol(f.currentLocation.pathname,r)||f.currentLocation.pathname,y=ol(f.nextLocation.pathname,r)||f.nextLocation.pathname;return gu(h.pathname,y)!=null||gu(h.pathname,m)!=null}const fm=/^\/vault\/admin(?=\/|$)/,dm=/^\/vault\/([^/]+)\/admin(?=\/|$)/;function yr(){return typeof window>"u"?!1:fm.test(window.location.pathname)}function hm(){if(typeof window>"u"||yr())return null;const u=window.location.pathname.match(dm);if(!u)return null;try{return decodeURIComponent(u[1])}catch{return null}}function Mg(){if(typeof window>"u")return"";const u=window.location.pathname;if(fm.test(u))return"/vault/admin";const c=u.match(dm);return c?`/vault/${c[1]}/admin`:u==="/admin"||u.startsWith("/admin/")?"/admin":""}let Hl=null,Gt=null,an=null,rl=null,Bh=!1;const Og=.8,Dg=1e3,Ug=3e4;function kg(){if(typeof window>"u")return;const u=window.location.hash;if(!u||u.length<2)return;const c=new URLSearchParams(u.slice(1)),f=c.get("token");if(!f)return;Hl=f,Gt=null,c.delete("token");const r=c.toString(),h=r.length>0?`#${r}`:"",m=`${window.location.pathname}${window.location.search}${h}`;window.history.replaceState(null,"",m)}function pr(){return Hl}function Hg(){Hl=null,Gt=null,rl=null,Eu()}async function Qa(u){if(typeof window>"u")return{kind:"network-error",message:"no window"};let c;try{c=await fetch(`/admin/vault-admin-token/${encodeURIComponent(u)}`,{method:"GET",headers:{accept:"application/json"},credentials:"same-origin"})}catch(r){return{kind:"network-error",message:r instanceof Error?r.message:String(r)}}if(c.status===401||c.status===403||c.status===404)return{kind:"auth-required",status:c.status};if(!c.ok)return{kind:"network-error",message:`hub returned ${c.status}`};let f;try{f=await c.json()}catch(r){return{kind:"network-error",message:r instanceof Error?r.message:"could not parse mint response"}}return typeof f.token!="string"||f.token.length===0?{kind:"network-error",message:"mint response missing token"}:(Hl=f.token,Gt=f.expires_at?Bg(f.expires_at):null,rl=u,mm(),Yg(),{kind:"ok",token:f.token})}function Bg(u){const c=Date.parse(u);return Number.isNaN(c)?null:c}async function ar(u){if(Hl){if(Gt===null||Gt>Date.now())return{kind:"ok",token:Hl};Hl=null,Gt=null,Eu()}return Qa(u)}async function Lg(u){typeof window>"u"||Hl||await Qa(u).catch(()=>{})}function mm(){if(Eu(),Gt===null||rl===null||typeof document<"u"&&document.visibilityState==="hidden")return;const u=Date.now(),c=Gt-u;if(c<=0)return;const f=Math.max(Math.floor(c*Og),Dg);an=setTimeout(()=>{qg()},f)}function Eu(){an!==null&&(clearTimeout(an),an=null)}async function qg(){if(an=null,rl===null)return;const u=await Qa(rl);u.kind!=="ok"&&(typeof console<"u"&&console.warn("[vault-admin-spa] proactive token refresh failed; will retry once",u),an=setTimeout(()=>{an=null,rl!==null&&Qa(rl).catch(()=>{})},Ug))}function Yg(){Bh||typeof document>"u"||(Bh=!0,document.addEventListener("visibilitychange",()=>{if(document.visibilityState==="hidden"){Eu();return}if(rl!==null){if(Gt!==null&&Gt<=Date.now()){Qa(rl).catch(()=>{});return}mm()}}))}class _e extends Error{constructor(c,f){super(f),this.status=c,this.name="HttpError"}}async function et(u,c,f={}){let r=pr();if(!r){const v=await ar(u);if(v.kind!=="ok")throw new _e(401,"no admin token — sign in to the hub to refresh");r=v.token}const{headers:h,...m}=f,y=v=>({accept:"application/json",...h??{},authorization:`Bearer ${v}`}),j=await fetch(c,{...m,headers:y(r)});if(j.status!==401)return j;Hg();const b=await ar(u);return b.kind!=="ok"?j:fetch(c,{...m,headers:y(b.token)})}async function vm(){const u=await fetch("/vaults/list",{headers:{accept:"application/json"}});if(u.status===404)return[];if(!u.ok)throw new _e(u.status,`vaults/list fetch failed: ${u.status}`);return(await u.json()).vaults??[]}async function Gg(u){const c=await et(u,`/vault/${encodeURIComponent(u)}/`);if(!c.ok)throw new _e(c.status,await rt(c));return await c.json()}async function Vg(u){const c=await et(u,`/vault/${encodeURIComponent(u)}/.parachute/mirror`);if(!c.ok)throw new _e(c.status,await rt(c));return await c.json()}async function Xg(u,c){const f=await et(u,`/vault/${encodeURIComponent(u)}/.parachute/mirror`,{method:"PUT",headers:{"content-type":"application/json"},body:JSON.stringify(c)});if(!f.ok)throw new _e(f.status,await rt(f));return await f.json()}async function Qg(u){const c=await et(u,`/vault/${encodeURIComponent(u)}/.parachute/mirror/run-now`,{method:"POST"});if(!c.ok)throw new _e(c.status,await rt(c));return await c.json()}async function Zg(u){const c=await et(u,`/vault/${encodeURIComponent(u)}/.parachute/mirror/push-now`,{method:"POST"});if(!c.ok)throw new _e(c.status,await rt(c));return await c.json()}async function ym(u){const c=await et(u,`/vault/${encodeURIComponent(u)}/.parachute/mirror/auth`);if(!c.ok)throw new _e(c.status,await rt(c));return await c.json()}async function Kg(u){const c=await et(u,`/vault/${encodeURIComponent(u)}/.parachute/mirror/auth`,{method:"DELETE"});if(!c.ok)throw new _e(c.status,await rt(c));return await c.json()}async function Jg(u){const c=await et(u,`/vault/${encodeURIComponent(u)}/.parachute/mirror/auth/github/device-code`,{method:"POST"});if(!c.ok)throw new _e(c.status,await rt(c));return await c.json()}async function $g(u,c){const f=await et(u,`/vault/${encodeURIComponent(u)}/.parachute/mirror/auth/github/poll`,{method:"POST",headers:{"content-type":"application/json"},body:JSON.stringify({polling_id:c})});if(!f.ok&&f.status!==404)throw new _e(f.status,await rt(f));return await f.json()}async function Fg(u,c){const f=await et(u,`/vault/${encodeURIComponent(u)}/.parachute/mirror/auth/pat`,{method:"POST",headers:{"content-type":"application/json"},body:JSON.stringify(c)});if(!f.ok)throw new _e(f.status,await rt(f));return await f.json()}async function pm(u){const c=await et(u,`/vault/${encodeURIComponent(u)}/.parachute/mirror/auth/github/repos`);if(!c.ok)throw new _e(c.status,await rt(c));return await c.json()}async function Wg(u,c){const f=await et(u,`/vault/${encodeURIComponent(u)}/.parachute/mirror/auth/github/create-repo`,{method:"POST",headers:{"content-type":"application/json"},body:JSON.stringify(c)});if(!f.ok)throw new _e(f.status,await rt(f));return await f.json()}async function Ig(u,c){const f=await et(u,`/vault/${encodeURIComponent(u)}/.parachute/mirror/auth/github/select-repo`,{method:"POST",headers:{"content-type":"application/json"},body:JSON.stringify(c)});if(!f.ok)throw new _e(f.status,await rt(f));return await f.json()}async function Pg(u,c){const f=await et(u,`/vault/${encodeURIComponent(u)}/.parachute/mirror/import`,{method:"POST",headers:{"content-type":"application/json"},body:JSON.stringify(c)});if(!f.ok)throw new _e(f.status,await rt(f));return await f.json()}async function rt(u){try{const c=await u.text(),f=JSON.parse(c);if(f.error_description)return f.error_description;if(f.message)return f.message;if(f.error)return f.error;if(c)return c}catch{}return`${u.status} ${u.statusText}`}function gm(u){const c=u.split(".");if(c.length!==3)return null;try{const f=c[1].replace(/-/g,"+").replace(/_/g,"/"),r=f.length%4===0?"":"=".repeat(4-f.length%4),h=atob(f+r),m=JSON.parse(h);return m===null||typeof m!="object"?null:m}catch{return null}}function e0(u){if(!u)return[];const c=gm(u);if(!c)return[];const f=c.scope;if(typeof f=="string"&&f.length>0)return f.split(/\s+/).filter(h=>h.length>0);const r=c.scopes;return Array.isArray(r)?r.filter(h=>typeof h=="string"&&h.length>0):[]}function bm(u){return e0(pr()).includes(`vault:${u}:admin`)}function xm(){const u=pr();if(!u)return null;const c=gm(u);if(!c)return null;const f=c.iss;return typeof f!="string"||f.length===0?null:f.replace(/\/$/,"")}let Ga=null,Va=null;function t0(u){const c=Date.parse(u);return Number.isNaN(c)?null:c}async function l0(){if(typeof window>"u")return{kind:"network-error",message:"no window"};let u;try{u=await fetch("/admin/host-admin-token",{method:"GET",headers:{accept:"application/json"},credentials:"same-origin"})}catch(f){return{kind:"network-error",message:f instanceof Error?f.message:String(f)}}if(u.status===403)return{kind:"forbidden"};if(u.status===401||u.status===404)return{kind:"auth-required",status:u.status};if(!u.ok)return{kind:"network-error",message:`hub returned ${u.status}`};let c;try{c=await u.json()}catch(f){return{kind:"network-error",message:f instanceof Error?f.message:"could not parse host-admin mint response"}}return typeof c.token!="string"||c.token.length===0?{kind:"network-error",message:"host-admin mint response missing token"}:(Ga=c.token,Va=c.expires_at?t0(c.expires_at):null,{kind:"ok",token:c.token})}async function xu(){if(Ga){if(Va===null||Va>Date.now())return{kind:"ok",token:Ga};Ga=null,Va=null}return l0()}function n0(){Ga=null,Va=null}class Bl extends Error{constructor(c,f,r){super(f),this.status=c,this.disposition=r,this.name="HostAdminError"}}async function Fa(u,c={}){let f;const r=await xu();if(r.kind!=="ok")throw Lh(r);f=r.token;const{headers:h,...m}=c,y=v=>({accept:"application/json",...h??{},authorization:`Bearer ${v}`}),j=await fetch(u,{...m,headers:y(f)});if(j.status!==401)return j;n0();const b=await xu();if(b.kind!=="ok")throw Lh(b);return fetch(u,{...m,headers:y(b.token)})}function Lh(u){return u.kind==="forbidden"?new Bl(403,"host-admin token mint forbidden — not the hub admin","forbidden"):u.kind==="auth-required"?new Bl(u.status,"no host-admin session — sign in to the hub to manage tokens","auth-required"):new Bl(0,u.message,"network-error")}function Za(){if(typeof window>"u")return;const u=xm();window.location.href=u?`${u}/account/`:"/account/"}async function a0(){let u;try{u=await fetch("/.well-known/parachute.json",{headers:{accept:"application/json"}})}catch(h){return{kind:"error",message:h instanceof Error?h.message:String(h)}}if(u.status===404)return{kind:"no-hub"};if(!u.ok)return{kind:"error",message:`well-known fetch failed: ${u.status}`};let c;try{c=await u.json()}catch{return{kind:"no-hub"}}const f=Array.isArray(c.vaults)?c.vaults:[],r=[];for(const h of f){const m=h??{};typeof m.name=="string"&&r.push({name:m.name,url:typeof m.url=="string"?m.url:"",version:typeof m.version=="string"?m.version:"",...typeof m.managementUrl=="string"?{managementUrl:m.managementUrl}:{}})}return{kind:"ok",vaults:r}}async function i0(u){var j,b;const c=await fetch(`/admin/vault-admin-token/${encodeURIComponent(u)}`,{method:"GET",headers:{accept:"application/json"},credentials:"same-origin"});if(!c.ok)throw new Error(`vault-admin-token mint failed: ${c.status}`);const f=await c.json();if(typeof f.token!="string"||f.token.length===0)throw new Error("vault-admin-token mint returned no token");const r=await fetch(`/vault/${encodeURIComponent(u)}/.parachute/usage`,{headers:{accept:"application/json",authorization:`Bearer ${f.token}`}});if(!r.ok)throw new Error(`usage fetch failed: ${r.status}`);const h=await r.json(),m=(j=h.counts)==null?void 0:j.notes,y=(b=h.bytes)==null?void 0:b.total;if(typeof m!="number"||typeof y!="number")throw new Error("usage report malformed");return{notes:m,totalBytes:y}}function u0(u){if(!Number.isFinite(u)||u<0)return"0 B";if(u<1024)return`${Math.round(u)} B`;const c=u/1024;if(c<1024)return`${Math.round(c)} KB`;const f=c/1024;return f<1024?`${f.toFixed(1)} MB`:`${(f/1024).toFixed(1)} GB`}const s0=/^[a-z0-9_-]+$/,c0=new Set(["list","new","assets","admin"]);function r0(u){return u.length===0?null:s0.test(u)?u.length<2||u.length>32?"Vault names must be 2–32 characters long.":c0.has(u)?`"${u}" is a reserved name.`:null:"Lowercase letters, numbers, hyphens, and underscores only."}class ir extends Error{constructor(c,f,r){super(f),this.status=c,this.code=r,this.name="VaultsApiError"}}async function Sm(u){let c,f=`${u.status}`;try{const r=await u.json();typeof r.error=="string"&&(c=r.error),f=r.error_description??r.error??f}catch{}return new ir(u.status,f,c)}async function o0(u){const c=await Fa("/vaults",{method:"POST",headers:{"content-type":"application/json"},body:JSON.stringify({name:u})});if(!c.ok)throw await Sm(c);const f=await c.json(),r={name:f.name,url:f.url,version:f.version,created:c.status===201};return f.token&&(r.token=f.token),f.token_guidance&&(r.tokenGuidance=f.token_guidance),r}async function f0(u){const c=await Fa(`/vaults/${encodeURIComponent(u)}`,{method:"DELETE",headers:{"content-type":"application/json"},body:JSON.stringify({confirm:u})});if(!c.ok)throw await Sm(c);const f=await c.json();return{name:f.name,cascade:f.cascade,warnings:f.warnings??[]}}const qh=5e3;function Tu({vaultName:u,status:c,onRecovered:f,ensure:r}){const h=c===403;if(x.useEffect(()=>{if(h)return;let b=!1,v=null;const T=async()=>{if(b||typeof document<"u"&&document.visibilityState!=="visible")return;const R=await(r?r():ar(u??""));if(!b){if(R.kind==="ok"){f();return}v=setTimeout(()=>void T(),qh)}},p=()=>{typeof document>"u"||document.visibilityState==="visible"&&(v!==null&&(clearTimeout(v),v=null),T())};return v=setTimeout(()=>void T(),qh),typeof document<"u"&&document.addEventListener("visibilitychange",p),()=>{b=!0,v!==null&&clearTimeout(v),typeof document<"u"&&document.removeEventListener("visibilitychange",p)}},[u,f,h,r]),h)return s.jsxs("div",{className:"warn-banner",role:"status",children:[s.jsxs("p",{style:{margin:"0 0 0.5rem"},children:["You're signed in, but vault management is restricted to the hub admin."," ",s.jsx("a",{href:"/account/",children:"Go to your account →"})]}),s.jsx("p",{className:"dim",style:{margin:0,fontSize:"0.85rem"},children:"Ask the hub admin if you need access to manage this vault."})]});const m=d0(),y=`/login?next=${encodeURIComponent(m)}`,j=c===404?"This hub doesn't host a vault by that name.":"You're not signed in to the hub.";return s.jsxs("div",{className:"warn-banner",role:"status",children:[s.jsxs("p",{style:{margin:"0 0 0.5rem"},children:[j," ",s.jsx("a",{href:y,children:"Sign in to the hub →"})]}),s.jsx("p",{className:"dim",style:{margin:0,fontSize:"0.85rem"},children:"After signing in, this page will refresh automatically."})]})}function d0(){return typeof window>"u"?"/":`${window.location.pathname}${window.location.search}${window.location.hash}`}function h0(){const[u,c]=x.useState({kind:"loading"}),[f,r]=x.useState({kind:"checking"}),[h,m]=x.useState({}),[y,j]=x.useState({kind:"idle"}),[b,v]=x.useState(""),[T,p]=x.useState({kind:"idle"}),[R,G]=x.useState(0);x.useEffect(()=>{let k=!1;return a0().then(async O=>{if(!k){if(O.kind==="ok"){c({kind:"ok",vaults:O.vaults});return}if(O.kind==="no-hub"){const q=await vm().catch(()=>[]);if(k)return;c({kind:"no-hub",names:q});return}c({kind:"error",message:O.message})}}),()=>{k=!0}},[R]),x.useEffect(()=>{if(u.kind!=="ok"||f.kind==="ok")return;let k=!1;return xu().then(O=>{k||(O.kind==="ok"?r({kind:"ok"}):O.kind==="forbidden"?r({kind:"banner",status:403}):O.kind==="auth-required"?r({kind:"banner",status:O.status}):r({kind:"banner",status:null}))}),()=>{k=!0}},[u.kind]),x.useEffect(()=>{if(u.kind!=="ok")return;const k=u.vaults.map(q=>q.name);if(k.length===0)return;let O=!1;m(q=>{const X={...q};for(const Q of k)X[Q]||(X[Q]={kind:"loading"});return X});for(const q of k)i0(q).then(X=>{O||m(Q=>({...Q,[q]:{kind:"ok",usage:X}}))}).catch(()=>{O||m(X=>({...X,[q]:{kind:"error"}}))});return()=>{O=!0}},[u]);const D=x.useCallback(()=>{r({kind:"ok"}),m({}),G(k=>k+1)},[]),L=r0(b);async function V(k){if(k.preventDefault(),!(b.length===0||L)){j({kind:"submitting"});try{const O=await o0(b);j({kind:"created",result:O}),v(""),G(q=>q+1)}catch(O){if(O instanceof Bl){if(O.disposition==="forbidden"){Za();return}r({kind:"banner",status:O.status||null}),j({kind:"idle"});return}const q=O instanceof ir?`${O.status}: ${O.message}`:O instanceof Error?O.message:String(O);j({kind:"error",message:q})}}}async function Y(k){p({kind:"deleting",name:k});try{const O=await f0(k);p({kind:"done",result:O}),m(q=>{const X={...q};return delete X[k],X}),G(q=>q+1)}catch(O){if(O instanceof Bl){if(O.disposition==="forbidden"){Za();return}r({kind:"banner",status:O.status||null}),p({kind:"idle"});return}const q=O instanceof ir||O instanceof Error?O.message:String(O);p({kind:"error",name:k,message:q})}}if(u.kind==="loading")return s.jsxs("div",{children:[s.jsx("h2",{children:"Vaults"}),s.jsx("p",{className:"muted",children:"Loading…"})]});if(u.kind==="no-hub")return s.jsxs("div",{children:[s.jsx("h2",{children:"Vaults"}),s.jsxs("div",{className:"warn-banner",role:"status",children:[s.jsx("p",{style:{margin:"0 0 0.5rem"},children:"This page is being served directly by the vault daemon — there's no hub on this origin, so vault management (create / delete) isn't available here."}),s.jsxs("p",{className:"dim",style:{margin:0,fontSize:"0.85rem"},children:["The hub origin is the front door: open ",s.jsx("code",{children:"/vault/admin/"})," on your hub (port 1939 by default) to manage vaults. Read-only vault names below."]})]}),u.names.length>0?s.jsx("div",{style:{marginTop:"1rem"},children:u.names.map(k=>s.jsxs("a",{href:`/vault/${encodeURIComponent(k)}/admin/`,className:"vault-row",children:[s.jsx("div",{className:"body",children:s.jsx("div",{className:"name",children:s.jsx("code",{children:k})})}),s.jsx("div",{className:"chev",children:"→"})]},k))}):null]});if(u.kind==="error")return s.jsxs("div",{children:[s.jsx("h2",{children:"Vaults"}),s.jsx("div",{className:"error-banner",children:s.jsx("code",{children:u.message})}),s.jsx("button",{type:"button",className:"secondary",onClick:()=>G(k=>k+1),children:"Retry"})]});const Z=f.kind==="ok";return s.jsxs("div",{children:[s.jsx("div",{className:"list-header",children:s.jsxs("h2",{children:["Vaults (",u.vaults.length,")"]})}),f.kind==="banner"?s.jsx(Tu,{status:f.status,onRecovered:D,ensure:xu}):null,s.jsxs("p",{className:"muted",children:["Vaults registered with this hub. ",s.jsx("strong",{children:"Manage"})," opens each vault's own admin page (a full page load — use your browser's back button to return here)."]}),T.kind==="done"?s.jsx(v0,{result:T.result,onDismiss:()=>p({kind:"idle"})}):null,u.vaults.length===0?s.jsxs("div",{className:"empty",children:["No vaults yet",Z?" — create your first below.":"."]}):s.jsx("div",{style:{marginTop:"1rem"},children:u.vaults.map(k=>{const O=h[k.name],q=(O==null?void 0:O.kind)==="ok"?`${O.usage.notes} ${O.usage.notes===1?"note":"notes"} · ${u0(O.usage.totalBytes)}`:(O==null?void 0:O.kind)==="loading"?"…":"—",X=T.kind==="confirming"&&T.name===k.name,Q=T.kind==="deleting"&&T.name===k.name,ee=T.kind==="error"&&T.name===k.name?T.message:null;return s.jsxs("div",{className:"vault-row-group",children:[s.jsxs("div",{className:"vault-row",children:[s.jsxs("div",{className:"body",children:[s.jsxs("div",{className:"name",children:[s.jsx("code",{children:k.name}),k.version?s.jsxs("span",{className:"tag muted",title:"Vault version",children:[" ","v",k.version]}):null]}),s.jsx("div",{className:"dim vault-usage","data-testid":`vault-usage-${k.name}`,children:q}),ee?s.jsx("div",{className:"error-banner",style:{marginTop:"0.5rem"},children:s.jsx("code",{children:ee})}):null]}),s.jsxs("div",{className:"vault-row-actions",children:[s.jsx("a",{href:`/vault/${encodeURIComponent(k.name)}/admin/`,children:s.jsx("button",{type:"button",children:"Manage"})}),Z?s.jsx("button",{type:"button",className:"secondary",disabled:Q,onClick:()=>p(X?{kind:"idle"}:{kind:"confirming",name:k.name,typed:""}),children:Q?"Deleting…":"Delete"}):null]})]}),X&&T.kind==="confirming"?s.jsxs("div",{className:"section",style:{marginTop:"0.5rem"},children:[s.jsxs("p",{style:{margin:"0 0 0.5rem"},children:["Deleting ",s.jsx("code",{children:k.name})," permanently destroys its notes and revokes every token, grant, assignment, and invite naming it. Type the vault name to confirm:"]}),s.jsxs("div",{className:"row",style:{display:"flex",gap:"0.5rem"},children:[s.jsx("input",{type:"text","aria-label":`Type ${k.name} to confirm deletion`,placeholder:k.name,value:T.typed,onChange:me=>p({kind:"confirming",name:k.name,typed:me.target.value})}),s.jsx("button",{type:"button",disabled:T.typed!==k.name,onClick:()=>void Y(k.name),children:"Delete this vault"}),s.jsx("button",{type:"button",className:"secondary",onClick:()=>p({kind:"idle"}),children:"Cancel"})]})]}):null]},k.name)})}),Z?s.jsxs("div",{className:"section",style:{marginTop:"1.5rem"},children:[s.jsx("h3",{style:{margin:"0 0 0.85rem",fontSize:"1rem",fontWeight:500},children:"Create a vault"}),y.kind==="created"?s.jsx(m0,{result:y.result,onDone:()=>j({kind:"idle"})}):s.jsxs("form",{onSubmit:k=>void V(k),children:[y.kind==="error"?s.jsxs("div",{className:"error-banner",style:{marginBottom:"0.5rem"},children:["Couldn't create vault: ",s.jsx("code",{children:y.message})]}):null,s.jsxs("div",{className:"row",style:{display:"flex",gap:"0.5rem"},children:[s.jsx("input",{id:"new-vault-name",type:"text","aria-label":"New vault name",value:b,onChange:k=>v(k.target.value),placeholder:"e.g. work, home, scratch",disabled:y.kind==="submitting"}),s.jsx("button",{type:"submit",disabled:b.length===0||!!L||y.kind==="submitting",children:y.kind==="submitting"?"Creating…":"Create vault"})]}),L?s.jsx("div",{className:"field-error",children:L}):s.jsxs("div",{className:"dim",style:{fontSize:"0.85rem",marginTop:"0.35rem"},children:["Lowercase letters, numbers, hyphens, underscores. Becomes the path under"," ",s.jsx("code",{children:"/vault/<name>"}),"."]})]})]}):null]})}function m0({result:u,onDone:c}){const[f,r]=x.useState(!1),h=async()=>{if(u.token)try{await navigator.clipboard.writeText(u.token),r(!0),setTimeout(()=>r(!1),2e3)}catch{}};return u.token?s.jsxs("div",{className:"mint-banner",children:[s.jsxs("h4",{style:{margin:"0 0 0.5rem"},children:["Vault ",s.jsx("code",{children:u.name})," created — access token (shown once)"]}),s.jsxs("p",{className:"muted",children:["A hub-issued JWT scoped ",s.jsxs("code",{children:["vault:",u.name,":admin"]}),". This is the only time it's shown — copy it somewhere safe. You don't need it for the OAuth connect path; for a header-auth token later, mint a scope-narrow one with"," ",s.jsxs("code",{children:["parachute auth mint-token --scope vault:",u.name,":read"]}),"."]}),s.jsxs("div",{className:"token-box",children:[s.jsx("code",{children:u.token}),s.jsx("button",{type:"button",className:"secondary",onClick:()=>void h(),children:f?"Copied":"Copy"})]}),s.jsx("div",{className:"actions",style:{marginTop:"0.5rem"},children:s.jsx("button",{type:"button",onClick:c,children:"Done — I've saved the token"})})]}):u.created?s.jsxs("div",{className:"section",children:[s.jsxs("p",{children:["Vault ",s.jsx("code",{children:u.name})," was created",u.tokenGuidance?s.jsxs(s.Fragment,{children:[" ","— ",s.jsx("span",{className:"muted",children:u.tokenGuidance})]}):s.jsx("span",{className:"muted",children:" (no bootstrap token was minted)"}),". Connect over OAuth (no token needed), or mint a scope-narrow header-auth token with"," ",s.jsxs("code",{children:["parachute auth mint-token --scope vault:",u.name,":read"]}),"."]}),s.jsx("button",{type:"button",onClick:c,children:"Done"})]}):s.jsxs("div",{className:"section",children:[s.jsxs("p",{children:["Vault ",s.jsx("code",{children:u.name})," already existed; nothing new was created."]}),s.jsx("button",{type:"button",onClick:c,children:"Continue"})]})}function v0({result:u,onDismiss:c}){const f=u.cascade;return s.jsxs("div",{className:"section",role:"status",style:{marginTop:"0.75rem"},children:[s.jsxs("h3",{style:{margin:"0 0 0.5rem",fontSize:"1rem",fontWeight:500},children:["Vault ",s.jsx("code",{children:u.name})," deleted"]}),s.jsxs("ul",{style:{margin:"0 0 0.5rem"},children:[s.jsxs("li",{children:[f.tokens_revoked," token(s) revoked"]}),s.jsxs("li",{children:[f.grants_rewritten," grant(s) rewritten, ",f.grants_dropped," dropped"]}),s.jsxs("li",{children:[f.user_vaults_removed," user assignment(s) removed"]}),s.jsxs("li",{children:[f.invites_invalidated," invite(s) invalidated"]}),s.jsxs("li",{children:[f.connections_torn_down," connection(s) torn down"]}),s.jsxs("li",{children:["vault data ",f.vault_removed?"removed":"NOT removed","; module"," ",f.module_restarted?"restarted":"not restarted"]})]}),f.orphaned_channels.length>0?s.jsxs("div",{className:"warn-banner",style:{marginBottom:"0.5rem"},children:["Orphaned channel(s) still reference this vault:"," ",f.orphaned_channels.map((r,h)=>s.jsxs("span",{children:[h>0?", ":"",s.jsx("code",{children:r})]},r))," ","— remove them from the channel module's own admin page."]}):null,u.warnings.length>0?s.jsx("div",{className:"warn-banner",style:{marginBottom:"0.5rem"},children:u.warnings.map(r=>s.jsxs("div",{children:[s.jsx("code",{children:r.step}),": ",r.detail]},r.step))}):null,s.jsx("button",{type:"button",className:"secondary",onClick:c,children:"Dismiss"})]})}function Yh({vaultName:u}={}){const c=rr(),f=u??c.name,r=u!==void 0,h=r?"/tokens":`/vault/${encodeURIComponent(f??"")}/tokens`,m=r?"/mirror":`/vault/${encodeURIComponent(f??"")}/mirror`,[y,j]=x.useState({kind:"loading"}),[b,v]=x.useState(0),T=x.useCallback(()=>v(G=>G+1),[]);if(x.useEffect(()=>{let G=!1;if(!f){j({kind:"missing"});return}return j({kind:"loading"}),Gg(f).then(D=>{G||j({kind:"ok",vault:D})}).catch(D=>{if(G)return;if(D instanceof _e){if(D.status===401||D.status===403){j({kind:"auth-required",status:D.status});return}if(D.status===404){j({kind:"missing"});return}j({kind:"error",message:`${D.status}: ${D.message}`});return}const L=D instanceof Error?D.message:String(D);j({kind:"error",message:L})}),()=>{G=!0}},[f,b]),y.kind==="loading")return s.jsxs("div",{children:[s.jsx("h2",{children:"Vault"}),s.jsx("p",{className:"muted",children:"Loading…"})]});if(y.kind==="auth-required")return s.jsxs("div",{children:[s.jsxs("h2",{children:["Vault ",s.jsx("code",{children:f})]}),s.jsx(Tu,{vaultName:f??"",status:y.status,onRecovered:T}),r?null:s.jsx(Je,{to:"/",children:"← Back to vaults"})]});if(y.kind==="missing")return s.jsxs("div",{children:[s.jsx("h2",{children:"Vault not found"}),s.jsxs("p",{className:"muted",children:["No vault named ",s.jsx("code",{children:f})," is registered on this server."]}),r?null:s.jsx(Je,{to:"/",children:"← Back to vaults"})]});if(y.kind==="error")return s.jsxs("div",{children:[s.jsxs("h2",{children:["Vault ",s.jsx("code",{children:f})]}),s.jsx("div",{className:"error-banner",children:s.jsx("code",{children:y.message})}),r?null:s.jsx(Je,{to:"/",children:"← Back to vaults"})]});const{vault:p}=y,R=`/vault/${p.name}`;return s.jsxs("div",{children:[s.jsxs("div",{className:"list-header",children:[s.jsxs("h2",{children:["Vault ",s.jsx("code",{children:p.name})]}),r?null:s.jsx(Je,{to:"/",className:"muted",children:"← All vaults"})]}),s.jsxs("div",{className:"kv section",children:[s.jsx("div",{children:"Name"}),s.jsx("div",{children:s.jsx("code",{children:p.name})}),p.description?s.jsxs(s.Fragment,{children:[s.jsx("div",{children:"Description"}),s.jsx("div",{children:p.description})]}):null,s.jsx("div",{children:"Mount"}),s.jsx("div",{children:s.jsx("code",{children:R})}),p.createdAt?s.jsxs(s.Fragment,{children:[s.jsx("div",{children:"Created"}),s.jsx("div",{children:s.jsx("code",{children:p.createdAt})})]}):null]}),s.jsxs("div",{className:"section",children:[s.jsx("h3",{style:{margin:"0 0 0.85rem",fontSize:"1rem",fontWeight:500},children:"Stats"}),s.jsxs("div",{className:"stats",children:[s.jsxs("div",{className:"stat",children:[s.jsx("div",{className:"label",children:"Notes"}),s.jsx("div",{className:"value",children:p.stats.totalNotes})]}),s.jsxs("div",{className:"stat",children:[s.jsx("div",{className:"label",children:"Tags"}),s.jsx("div",{className:"value",children:p.stats.tagCount})]}),s.jsxs("div",{className:"stat",children:[s.jsx("div",{className:"label",children:"Attachments"}),s.jsx("div",{className:"value",children:p.stats.attachmentCount})]}),s.jsxs("div",{className:"stat",children:[s.jsx("div",{className:"label",children:"Links"}),s.jsx("div",{className:"value",children:p.stats.linkCount})]})]})]}),s.jsxs("div",{className:"section",children:[s.jsx("h3",{style:{margin:"0 0 0.85rem",fontSize:"1rem",fontWeight:500},children:"Manage"}),s.jsxs("ul",{className:"manage-list",children:[s.jsxs("li",{children:[s.jsx(Je,{to:h,children:"Tokens →"}),s.jsx("span",{className:"dim",children:" mint, list, and revoke hub access tokens (JWTs)"})]}),s.jsxs("li",{children:[s.jsx(Je,{to:m,children:"Git backup →"}),s.jsx("span",{className:"dim",children:" mirror this vault to a git repository on a schedule, or on demand"})]}),s.jsx(y0,{vaultName:p.name})]})]})]})}function y0({vaultName:u}){const c=xm();if(!c)return s.jsxs("li",{children:[s.jsx("span",{children:"Permissions →"}),s.jsxs("span",{className:"dim",children:[" ","grants are managed on hub (the OAuth issuer); link will be live when hub ships its permissions UI."]})]});const f=`${c}/hub/permissions?vault=${encodeURIComponent(u)}`;return s.jsxs("li",{children:[s.jsx("a",{href:f,children:"Permissions →"}),s.jsxs("span",{className:"dim",children:[" ","grants are managed on hub (the OAuth issuer); link will be live when hub ships its permissions UI."]})]})}const p0=[{value:"events",label:"On change (default)"},{value:"manual",label:"Manual only"}],g0=[{id:"history",label:"History",subtext:"Local audit trail. Hidden under vault data. Events-driven.",apply:u=>({...u,enabled:!0,location:"internal",sync_mode:"events",auto_commit:!0,auto_push:!1})},{id:"live",label:"External folder mirror",subtext:"Visible folder. Open in Obsidian, push to GitHub. Events-driven.",apply:u=>({...u,enabled:!0,location:"external",sync_mode:"events",auto_commit:!0})},{id:"manual",label:"Manual Export",subtext:"Snapshot on demand. No auto-fire.",apply:u=>({...u,enabled:!0,location:"external",sync_mode:"manual",auto_commit:!0,auto_push:!1})}];function Gh({vaultName:u}={}){const c=rr(),f=u??c.name,r=u!==void 0,h=r?"/":`/vault/${encodeURIComponent(f??"")}`,[m,y]=x.useState({kind:"loading"}),[j,b]=x.useState(0);x.useEffect(()=>{let T=!1;if(f)return y({kind:"loading"}),Vg(f).then(p=>{T||y({kind:"ok",snapshot:p})}).catch(p=>{if(T)return;if(p instanceof _e&&(p.status===401||p.status===403)){y({kind:"auth-required",status:p.status});return}const R=p instanceof Error?p.message:String(p);y({kind:"error",message:R})}),()=>{T=!0}},[f,j]);const v=x.useCallback(()=>b(T=>T+1),[]);return f?s.jsxs("div",{children:[s.jsxs("div",{className:"list-header",children:[s.jsxs("h2",{children:["Backup for ",s.jsx("code",{children:f})]}),s.jsx(Je,{to:h,className:"muted",children:"← Vault detail"})]}),m.kind==="loading"?s.jsx("p",{className:"muted",children:"Loading…"}):null,m.kind==="auth-required"?s.jsx(Tu,{vaultName:f,status:m.status,onRecovered:v}):null,m.kind==="error"?s.jsx("div",{className:"error-banner",children:s.jsx("code",{children:m.message})}):null,m.kind==="ok"?s.jsx(b0,{vaultName:f,snapshot:m.snapshot,onRefresh:()=>b(T=>T+1),onSnapshot:T=>y({kind:"ok",snapshot:T})}):null]}):s.jsxs("div",{children:[s.jsx("h2",{children:"Mirror"}),s.jsx("p",{className:"muted",children:"Missing vault name."}),r?null:s.jsx(Je,{to:"/",children:"← Back to vaults"})]})}function b0({vaultName:u,snapshot:c,onRefresh:f,onSnapshot:r}){const h=bm(u),[m,y]=x.useState(null),[j,b]=x.useState(null);x.useEffect(()=>{if(!h)return;let p=!1;return ym(u).then(R=>{p||y(R)}).catch(R=>{p||b(R instanceof Error?R.message:String(R))}),()=>{p=!0}},[u,h]);const[v,T]=x.useState(!1);return s.jsxs(s.Fragment,{children:[s.jsx(x0,{status:c.status,config:c.config,creds:m}),h?null:s.jsxs("div",{className:"warn-banner",children:["You're viewing this page with a read-only token. Saving config + manual run require ",s.jsxs("code",{children:["vault:",u,":admin"]}),`. Re-enter from the hub directory's "Manage" link with an admin-scoped session to make changes.`]}),h?s.jsx(E0,{vaultName:u,creds:m,credsError:j,onCredsChanged:y,onCredsSaved:()=>{f()},locationIsExternal:c.config.location==="external"}):null,s.jsxs("div",{className:"section",children:[s.jsx("button",{type:"button",className:"secondary",onClick:()=>T(p=>!p),"aria-expanded":v,children:v?"Hide advanced settings":"Advanced settings"}),v?null:s.jsx("p",{className:"dim",style:{margin:"0.6rem 0 0"},children:"Manual exports, run-now, an external (Obsidian-visible) mirror folder, commit settings, and import-from-a-repo. Most owners never need these."})]}),v?s.jsxs(s.Fragment,{children:[s.jsx(S0,{status:c.status,config:c.config,creds:m,canRun:h&&c.status.enabled,vaultName:u,onSnapshot:r}),s.jsx(j0,{vaultName:u,initial:c.config,readOnly:!h,creds:m,onSaved:p=>{r(p),f()}}),h?s.jsx(R0,{vaultName:u,creds:m}):null]}):null]})}function x0({status:u,config:c,creds:f}){var y;if(!c.enabled)return s.jsxs("div",{className:"warn-banner",role:"status",children:[s.jsx("strong",{children:"Version history is off."})," This vault isn't saving a local history of changes right now. Open ",s.jsx("strong",{children:"Advanced settings"})," ","below to turn it back on."]});const r=!!(f!=null&&f.active_method),h=c.auto_push&&r,m=(f==null?void 0:f.active_method)==="github_oauth"?(y=f.github_oauth)==null?void 0:y.user_login:void 0;return s.jsxs("div",{className:"mint-banner",role:"status",style:{marginBottom:"1rem"},children:[h?s.jsxs(s.Fragment,{children:[s.jsx("strong",{children:"✓ Version history + backed up off this machine."})," ",m?s.jsxs(s.Fragment,{children:["Every change is saved locally and pushed to GitHub as"," ",s.jsxs("code",{children:["@",m]}),"."]}):s.jsx(s.Fragment,{children:"Every change is saved locally and pushed to your git remote automatically."})]}):s.jsxs(s.Fragment,{children:[s.jsx("strong",{children:"✓ Version history — on."})," Your vault automatically saves a full local history of every change. Want an off-machine copy too? Use ",s.jsx("strong",{children:"Back up to GitHub"})," below."]}),u.last_error?s.jsxs("p",{className:"dim",style:{margin:"0.5rem 0 0"},children:["Heads up — the last backup pass reported an error. See"," ",s.jsx("strong",{children:"Advanced settings"})," below for details."]}):null]})}function S0({status:u,config:c,creds:f,canRun:r,vaultName:h,onSnapshot:m}){const y=c.enabled,[j,b]=x.useState(!1),[v,T]=x.useState(!1),[p,R]=x.useState(null),G=async()=>{b(!0),R(null);try{const Y=await Qg(h);m(Y)}catch(Y){R(Y instanceof Error?Y.message:String(Y))}finally{b(!1)}},D=async()=>{T(!0),R(null);try{const Y=await Zg(h);m(Y)}catch(Y){R(Y instanceof Error?Y.message:String(Y))}finally{T(!1)}},L=!!(f!=null&&f.active_method)||c.auto_push,V=!r||v||!L;return s.jsxs("div",{className:"section",children:[s.jsx("h3",{style:{margin:"0 0 0.85rem",fontSize:"1rem",fontWeight:500},children:"Status"}),s.jsxs("div",{className:"kv",children:[s.jsx("div",{children:"Enabled"}),s.jsx("div",{children:y?s.jsx("code",{children:"yes"}):s.jsx("code",{children:"no"})}),s.jsx("div",{children:"Watch loop"}),s.jsx("div",{children:u.watch_running?s.jsx("code",{children:"running"}):s.jsx("code",{children:"stopped"})}),s.jsx("div",{children:"Path"}),s.jsx("div",{children:u.mirror_path?s.jsx("code",{children:u.mirror_path}):s.jsx("span",{className:"dim",children:"—"})}),s.jsx("div",{children:"Last export"}),s.jsx("div",{children:u.last_export_at?s.jsxs(s.Fragment,{children:[s.jsx("code",{children:u.last_export_at}),u.last_export_notes_count!==null?s.jsxs("span",{className:"dim",children:[" ","· ",u.last_export_notes_count," note",u.last_export_notes_count===1?"":"s"]}):null]}):s.jsx("span",{className:"dim",children:"never"})}),s.jsx("div",{children:"Last commit"}),s.jsx("div",{children:u.last_commit_sha?s.jsx("code",{children:u.last_commit_sha.slice(0,10)}):s.jsx("span",{className:"dim",children:"—"})}),s.jsx("div",{children:"Last push"}),s.jsx("div",{children:u.last_push_at?s.jsxs(s.Fragment,{children:[s.jsx("code",{children:u.last_push_at}),u.last_push_sha?s.jsxs("span",{className:"dim",children:[" ","· ",s.jsx("code",{children:u.last_push_sha.slice(0,10)})]}):null]}):s.jsx("span",{className:"dim",children:"never"})}),u.commits_unpushed!==null&&u.commits_unpushed>0?s.jsxs(s.Fragment,{children:[s.jsx("div",{}),s.jsxs("div",{className:"dim",children:[u.commits_unpushed," commit",u.commits_unpushed===1?"":"s"," ready to push"]})]}):null]}),u.last_push_error?s.jsxs("div",{className:"error-banner",style:{marginTop:"1rem"},children:[s.jsx("strong",{children:"Last push failed:"})," ",s.jsx("code",{children:u.last_push_error})]}):null,u.last_error?s.jsxs("div",{className:"error-banner",style:{marginTop:"1rem"},children:[s.jsx("strong",{children:"Last error:"})," ",s.jsx("code",{children:u.last_error})]}):null,p?s.jsx("div",{className:"error-banner",style:{marginTop:"1rem"},children:s.jsx("code",{children:p})}):null,s.jsxs("div",{className:"actions",children:[s.jsx("button",{type:"button",onClick:G,disabled:!r||j,title:y?r?void 0:"Admin scope required to trigger a manual export.":"Enable the mirror first, then trigger a manual export.",children:j?"Running…":"Run export now"}),s.jsx("button",{type:"button",className:"secondary",onClick:D,disabled:V,title:y?r?L?void 0:"Wire credentials or turn on auto-push to push to a remote.":"Admin scope required to push.":"Enable the mirror first, then push.",children:v?"Pushing…":"Push now"})]})]})}function j0({vaultName:u,initial:c,readOnly:f,creds:r,onSaved:h}){const[m,y]=x.useState(c),[j,b]=x.useState(!1),[v,T]=x.useState(!1),[p,R]=x.useState(null),[G,D]=x.useState(null),[L,V]=x.useState(0);x.useEffect(()=>{y(c)},[c]);const Y=O=>{const q=O.apply(m);y(q)},Z=O=>{y(q=>({...q,sync_mode:O}))},k=async O=>{if(O.preventDefault(),!f){T(!0),R(null),D(null);try{const q=await Xg(u,m);h(q),V(X=>X+1),setTimeout(()=>V(0),3e3)}catch(q){if(q instanceof _e){const X=q.message;R(X);const Q=X.toLowerCase();Q.includes("external_path")?D("external_path"):Q.includes("commit_template")?D("commit_template"):Q.includes("safety_net_seconds")?D("safety_net_seconds"):Q.includes("sync_mode")?D("sync_mode"):Q.includes("auto_push")?D("auto_push"):Q.includes("location")?D("location"):D(null)}else R(q instanceof Error?q.message:String(q))}finally{T(!1)}}};return s.jsxs("form",{className:"section",onSubmit:k,children:[s.jsx("h3",{style:{margin:"0 0 0.85rem",fontSize:"1rem",fontWeight:500},children:"Configuration"}),s.jsxs("div",{className:"form-row",children:[s.jsxs("label",{children:[s.jsx("input",{type:"checkbox",checked:m.enabled,disabled:f,onChange:O=>y(q=>({...q,enabled:O.target.checked})),style:{width:"auto",marginRight:"0.5rem"}}),"Enable mirror"]}),s.jsx("p",{className:"dim",style:{margin:"0.35rem 0 0"},children:"Master switch. When off, no export / commit / push runs."})]}),s.jsxs("div",{className:"form-row",children:[s.jsx("label",{children:"Presets"}),s.jsxs("p",{className:"dim",style:{marginTop:0,marginBottom:"0.5rem",fontSize:"0.9em"},children:[s.jsx("strong",{children:"History"})," is the default every vault ships with — vault manages the history folder under its own data dir, no path to pick, no remote to configure. ",s.jsx("strong",{children:"External folder mirror"})," +"," ",s.jsx("strong",{children:"Manual Export"})," are for operators who want to point at a visible folder (Obsidian, GitHub)."]}),s.jsx("div",{className:"preset-grid",children:g0.map(O=>s.jsxs("button",{type:"button",className:"preset-card",disabled:f,onClick:()=>Y(O),"aria-label":`Apply ${O.label} preset`,children:[s.jsx("strong",{children:O.label}),s.jsx("span",{className:"dim",children:O.subtext})]},O.id))})]}),s.jsxs("div",{className:"form-row",children:[s.jsx("label",{children:"Location"}),s.jsxs("div",{children:[s.jsxs("label",{className:"radio-row",children:[s.jsx("input",{type:"radio",name:"location",value:"internal",checked:m.location==="internal",disabled:f,onChange:()=>y(O=>({...O,location:"internal"}))}),s.jsxs("span",{children:["Internal ",s.jsx("span",{className:"dim",children:"— hidden under vault data dir"})]})]}),s.jsxs("label",{className:"radio-row",children:[s.jsx("input",{type:"radio",name:"location",value:"external",checked:m.location==="external",disabled:f,onChange:()=>y(O=>({...O,location:"external"}))}),s.jsxs("span",{children:["External ",s.jsx("span",{className:"dim",children:"— operator-picked path"})]})]})]})]}),m.location==="external"?s.jsxs("div",{className:"form-row",children:[s.jsx("label",{htmlFor:"external-path",children:"External path"}),s.jsx("input",{id:"external-path",type:"text",value:m.external_path??"",disabled:f,onChange:O=>y(q=>({...q,external_path:O.target.value.length>0?O.target.value:null})),placeholder:"/Users/you/Documents/vault-mirror","aria-invalid":G==="external_path"}),s.jsxs("div",{className:"warn-banner",style:{marginTop:"0.5rem"},role:"alert",children:["Path must exist AND be a git repo (run ",s.jsx("code",{children:"git init"})," first if needed)."]})]}):null,s.jsxs("div",{className:"form-row",children:[s.jsx("label",{htmlFor:"sync-mode-select",children:"Sync mode"}),s.jsx("select",{id:"sync-mode-select",value:m.sync_mode,disabled:f,onChange:O=>Z(O.target.value),children:p0.map(O=>s.jsx("option",{value:O.value,children:O.label},O.value))}),s.jsx("p",{className:"dim",style:{margin:"0.35rem 0 0"},children:m.sync_mode==="manual"?'No auto-fire. Exports only run when you click "Run export now" (or run `parachute-vault export` from the CLI).':"Every change to a note, tag, or attachment triggers an export within ~500ms. A background safety check runs hourly to catch anything missed."})]}),s.jsxs("div",{className:"form-row",children:[s.jsxs("label",{children:[s.jsx("input",{type:"checkbox",checked:m.auto_commit,disabled:f,onChange:O=>y(q=>({...q,auto_commit:O.target.checked})),style:{width:"auto",marginRight:"0.5rem"}}),"Commit after each export"]}),m.auto_commit?null:s.jsx("p",{className:"hint",style:{marginTop:"0.25rem",fontSize:"0.85em"},children:"Note: the export cursor still advances after each pass. Subsequent runs only re-export notes written since the last pass — even when triggered manually."})]}),m.location==="external"||r!=null&&r.active_method?s.jsxs("div",{className:"form-row",children:[s.jsxs("label",{children:[s.jsx("input",{type:"checkbox",checked:m.auto_push,disabled:f,onChange:O=>y(q=>({...q,auto_push:O.target.checked})),style:{width:"auto",marginRight:"0.5rem"}}),"Push after each commit"]}),s.jsx("p",{className:"dim",style:{margin:"0.35rem 0 0",fontSize:"0.9em"},children:"When credentials are configured, vault can push the mirror's commits to your remote regardless of whether the mirror folder lives under vault's data dir or somewhere visible."}),m.auto_push?r!=null&&r.active_method?s.jsxs("div",{className:"info-banner",style:{marginTop:"0.5rem"},role:"status",children:[r.active_method==="github_oauth"&&r.github_oauth?s.jsxs(s.Fragment,{children:["Will push to ",s.jsxs("code",{children:["@",r.github_oauth.user_login]})," on GitHub."]}):r.active_method==="pat"&&r.pat?s.jsxs(s.Fragment,{children:["Will push using saved credential: ",s.jsx("code",{children:r.pat.label}),"."]}):s.jsx(s.Fragment,{children:"Will push using saved credential."})," ","Failed pushes are logged but won't crash the export."]}):s.jsxs("div",{className:"warn-banner",style:{marginTop:"0.5rem"},role:"alert",children:["Auto-push needs git credentials. Either connect GitHub in the"," ",s.jsx("strong",{children:"Back up to GitHub"})," section above, or paste a Personal Access Token + remote URL there. Failed pushes are logged but won't crash the export."]}):null]}):null,s.jsx("div",{className:"form-row",children:s.jsxs("button",{type:"button",className:"secondary",onClick:()=>b(O=>!O),children:[j?"Hide":"Show"," advanced"]})}),j?s.jsxs("div",{className:"form-row",children:[s.jsx("label",{htmlFor:"commit-template",children:"Commit template"}),s.jsx("input",{id:"commit-template",type:"text",value:m.commit_template,disabled:f,onChange:O=>y(q=>({...q,commit_template:O.target.value})),"aria-invalid":G==="commit_template"}),s.jsxs("p",{className:"dim",style:{margin:"0.35rem 0 0"},children:["Supports ",s.jsx("code",{children:"{{date}}"}),", ",s.jsx("code",{children:"{{notes_changed}}"}),","," ",s.jsx("code",{children:"{{plural}}"}),", ",s.jsx("code",{children:"{{first_note_title}}"}),","," ",s.jsx("code",{children:"{{vault_name}}"}),"."]})]}):null,p?s.jsx("div",{className:"error-banner",role:"alert",children:s.jsx("code",{children:p})}):null,L>0?s.jsx("div",{className:"mint-banner",style:{padding:"0.75rem 1rem",marginBottom:"1rem"},role:"status",children:"Saved."}):null,s.jsx("div",{className:"actions",children:s.jsx("button",{type:"submit",disabled:f||v,children:v?"Saving…":"Save"})})]})}function E0({vaultName:u,creds:c,credsError:f,onCredsChanged:r,onCredsSaved:h,locationIsExternal:m}){const[y,j]=x.useState(!1),[b,v]=x.useState(!1),[T,p]=x.useState(!1),[R,G]=x.useState(null),[D,L]=x.useState(null),V=(c==null?void 0:c.active_method)!==null&&(c==null?void 0:c.active_method)!==void 0,Y=async()=>{if(confirm("Disconnect git remote credentials? Auto-push will stop working until you reconnect.")){p(!0),G(null);try{const Z=await Kg(u);r(Z)}catch(Z){G(Z instanceof Error?Z.message:String(Z))}finally{p(!1)}}};return s.jsxs("div",{className:"section",id:"git-remote-section",children:[s.jsx("h3",{style:{margin:"0 0 0.85rem",fontSize:"1rem",fontWeight:500},children:V?"Backed up to a git remote":"Back up to GitHub"}),s.jsx("p",{className:"dim",style:{marginTop:0},children:V?s.jsxs(s.Fragment,{children:["Your vault pushes its history to an off-machine git remote. Credentials are stored on this server with ",s.jsx("code",{children:"0600"})," file permissions — never sent to GitHub or any third party."]}):s.jsxs(s.Fragment,{children:["Keep an off-machine copy: push your vault's history to GitHub (or any HTTPS git host). Credentials are stored on this server with"," ",s.jsx("code",{children:"0600"})," file permissions, never sent to a third party."]})}),!m&&!(c!=null&&c.active_method)?s.jsx("div",{className:"info-banner",style:{marginBottom:"0.75rem"},role:"status",children:"Internal mirrors live under the vault's data directory. To push them to a remote, paste a Personal Access Token + remote URL below — that wires the remote and turns on auto-push automatically."}):null,f?s.jsxs("div",{className:"error-banner",role:"alert",children:["Could not load credential status: ",s.jsx("code",{children:f})]}):null,V?s.jsxs("div",{className:"kv",style:{marginBottom:"0.75rem"},children:[s.jsx("div",{children:"Status"}),s.jsx("div",{children:(c==null?void 0:c.active_method)==="github_oauth"&&c.github_oauth?s.jsxs(s.Fragment,{children:["Connected to ",s.jsxs("code",{children:["@",c.github_oauth.user_login]})," on GitHub"]}):(c==null?void 0:c.active_method)==="pat"&&c.pat?s.jsxs(s.Fragment,{children:["Custom credential: ",s.jsx("code",{children:c.pat.label})]}):null}),(c==null?void 0:c.active_method)==="github_oauth"&&c.github_oauth?s.jsxs(s.Fragment,{children:[s.jsx("div",{children:"Token"}),s.jsxs("div",{children:[s.jsx("code",{children:c.github_oauth.token_preview})," ",s.jsxs("span",{className:"dim",children:["· scope ",c.github_oauth.scope||"—"," · authorized"," ",c.github_oauth.authorized_at.slice(0,10)]})]})]}):null,(c==null?void 0:c.active_method)==="pat"&&c.pat?s.jsxs(s.Fragment,{children:[s.jsx("div",{children:"Remote"}),s.jsx("div",{children:s.jsx("code",{children:c.pat.remote_url})}),s.jsx("div",{children:"Token"}),s.jsx("div",{children:s.jsx("code",{children:c.pat.token_preview})})]}):null]}):s.jsx("p",{className:"dim",children:"Not connected. Auto-push won't work until you connect. Personal Access Token is the universal path (works with GitHub, GitLab, Gitea, Bitbucket, anything that takes an HTTPS token); the GitHub shortcut just saves a step for GitHub users."}),R?s.jsx("div",{className:"error-banner",role:"alert",children:s.jsx("code",{children:R})}):null,D?s.jsxs("div",{className:"mint-banner",style:{marginBottom:"0.75rem"},role:"status",children:[s.jsx("strong",{children:"Credentials saved."})," ",(()=>{const Z=D,k=Z.initial_push.fired&&Z.initial_push.pushed?Z.initial_push.sha:void 0,O=Z.initial_push.fired&&!Z.initial_push.pushed?Z.initial_push.error:void 0;return Z.auto_push_was_already_enabled?k?s.jsxs(s.Fragment,{children:["Auto-push was already on; just pushed"," ",s.jsx("code",{children:k.slice(0,10)}),"."]}):O?s.jsx(s.Fragment,{children:"Auto-push was already on; the push attempt failed — see Advanced settings → Status for details."}):s.jsx(s.Fragment,{children:"Auto-push was already on; nothing to push right now."}):Z.auto_push_enabled?k?s.jsxs(s.Fragment,{children:["Auto-push enabled and the first push landed"," ",s.jsx("code",{children:k.slice(0,10)}),". Your next commit will push to the remote too."]}):O?s.jsx(s.Fragment,{children:"Auto-push enabled. The initial push attempt failed — see Advanced settings → Status for the error."}):s.jsx(s.Fragment,{children:"Auto-push enabled. Your next commit will push to the remote."}):s.jsx(s.Fragment,{children:"Credentials wired. Auto-push remains off; flip it on in Advanced settings → Configuration to push commits automatically."})})()," ",s.jsx("button",{type:"button",className:"secondary",onClick:()=>L(null),style:{marginLeft:"0.5rem"},"aria-label":"Dismiss",children:"Dismiss"})]}):null,s.jsx("div",{className:"actions",children:V?s.jsx("button",{type:"button",className:"secondary",onClick:Y,disabled:T,children:T?"Disconnecting…":"Disconnect"}):s.jsxs(s.Fragment,{children:[s.jsx("button",{type:"button",onClick:()=>v(!0),children:"Use Personal Access Token"}),s.jsx("button",{type:"button",className:"secondary",onClick:()=>j(!0),children:"Connect GitHub (one-click for GitHub users)"})]})}),y?s.jsx(T0,{vaultName:u,onClose:()=>j(!1),onConnected:(Z,k)=>{r(Z),k&&(L(k),h(k)),j(!1)}}):null,b?s.jsx(A0,{vaultName:u,onClose:()=>v(!1),onSaved:Z=>{r(Z),L(Z),h(Z),v(!1)}}):null]})}function T0({vaultName:u,onClose:c,onConnected:f}){const[r,h]=x.useState({kind:"starting"}),[m,y]=x.useState(Date.now()),j=x.useRef(!1);x.useEffect(()=>{const v=setInterval(()=>y(Date.now()),1e3);return()=>clearInterval(v)},[]),x.useEffect(()=>{let v=!1;return j.current=!1,Jg(u).then(T=>{v||h({kind:"polling",code:T,pollIntervalMs:Math.max(T.interval,1)*1e3,startedAt:Date.now()})}).catch(T=>{v||h({kind:"error",message:T instanceof Error?T.message:String(T)})}),()=>{v=!0,j.current=!0}},[u]),x.useEffect(()=>{if(r.kind!=="polling")return;const v=r.code;let T=!1,p=null,R=r.pollIntervalMs;const G=async()=>{if(!(T||j.current))try{const D=await $g(u,v.polling_id);if(T)return;if(D.state==="granted"){h({kind:"granted",user:{login:D.user.login}});return}if(D.state==="denied"){h({kind:"error",message:"Authorization denied."});return}if(D.state==="expired"){h({kind:"error",message:"The device code expired. Try again."});return}D.state==="slow_down"&&(R=D.interval*1e3),p=setTimeout(G,R)}catch(D){if(T)return;h({kind:"error",message:D instanceof Error?D.message:String(D)})}};return p=setTimeout(G,R),()=>{T=!0,p&&clearTimeout(p)}},[r,u]);const b=async v=>{try{await navigator.clipboard.writeText(v)}catch{}};return s.jsx("div",{className:"modal-backdrop",role:"dialog","aria-modal":"true",children:s.jsxs("div",{className:"modal",children:[s.jsxs("div",{className:"list-header",children:[s.jsx("h3",{style:{margin:0},children:"Connect GitHub"}),s.jsx("button",{type:"button",className:"secondary",onClick:c,children:"Close"})]}),r.kind==="starting"?s.jsx("p",{className:"muted",children:"Requesting device code from GitHub…"}):null,r.kind==="polling"?s.jsxs(s.Fragment,{children:[s.jsxs("p",{children:[s.jsx("strong",{children:"Step 1."})," Open"," ",s.jsx("a",{href:r.code.verification_uri,target:"_blank",rel:"noreferrer",children:r.code.verification_uri})," ","in your browser."]}),s.jsxs("p",{children:[s.jsx("strong",{children:"Step 2."})," Enter this code:"]}),s.jsxs("div",{className:"device-code-row",children:[s.jsx("code",{className:"device-code",children:r.code.user_code}),s.jsx("button",{type:"button",className:"secondary",onClick:()=>b(r.code.user_code),children:"Copy"})]}),s.jsxs("p",{className:"dim",children:["Waiting for authorization…"," ",_0(r.code.expires_in,r.startedAt,m)]})]}):null,r.kind==="granted"?s.jsx(N0,{vaultName:u,user:r.user,onPicked:async(v,T)=>{const p=await Ig(u,{owner:v,name:T}),R=await ym(u);f(R,p)},onError:v=>h({kind:"error",message:v})}):null,r.kind==="error"?s.jsxs(s.Fragment,{children:[s.jsx("div",{className:"error-banner",role:"alert",children:s.jsx("code",{children:r.message})}),s.jsxs("div",{className:"actions",children:[s.jsx("button",{type:"button",onClick:()=>h({kind:"starting"}),children:"Try again"}),s.jsx("button",{type:"button",className:"secondary",onClick:c,children:"Close"})]})]}):null]})})}function _0(u,c,f){const r=Math.floor((f-c)/1e3),h=Math.max(0,u-r),m=Math.floor(h/60),y=h%60;return`${m}:${String(y).padStart(2,"0")} remaining`}function N0({vaultName:u,user:c,onPicked:f,onError:r}){const[h,m]=x.useState(null),[y,j]=x.useState(!1),[b,v]=x.useState(""),[T,p]=x.useState(null),[R,G]=x.useState(!1),[D,L]=x.useState(""),[V,Y]=x.useState(!1);x.useEffect(()=>{let q=!1;return pm(u).then(({repos:X,truncated:Q})=>{q||(m(X),j(!!Q))}).catch(X=>{q||r(X instanceof Error?X.message:String(X))}),()=>{q=!0}},[u,r]);const Z=(h??[]).filter(q=>b.length===0?!0:q.full_name.toLowerCase().includes(b.toLowerCase())),k=async(q,X)=>{p(`${q}/${X}`);try{await f(q,X)}catch(Q){r(Q instanceof Error?Q.message:String(Q))}finally{p(null)}},O=async()=>{if(D.trim().length!==0){G(!0);try{const q=await Wg(u,{name:D.trim(),description:"Parachute Vault mirror",private:!0});await f(q.owner,q.name)}catch(q){r(q instanceof Error?q.message:String(q))}finally{G(!1)}}};return s.jsxs(s.Fragment,{children:[s.jsxs("p",{children:["Authorized as ",s.jsxs("code",{children:["@",c.login]}),". Pick a repository to push the mirror to:"]}),s.jsx("div",{className:"form-row",children:s.jsx("input",{type:"search",placeholder:"Filter by name…",value:b,onChange:q=>v(q.target.value)})}),y?s.jsx("p",{className:"muted",style:{fontSize:"0.85em"},children:"Showing the first 300 repos. Use the filter above to narrow down — or paste the clone URL directly via Personal Access Token below if your repo isn't here."}):null,h===null?s.jsx("p",{className:"muted",children:"Loading repos…"}):null,h!==null?s.jsxs("div",{className:"repo-list",children:[Z.length===0&&b.length>0?s.jsxs("p",{className:"dim",children:['No repos match "',b,'".']}):null,Z.length===0&&b.length===0&&h.length===0?s.jsx("p",{className:"dim",children:"You don't own any repos on this account yet."}):null,Z.map(q=>s.jsxs("button",{type:"button",className:"repo-row",onClick:()=>k(q.owner,q.name),disabled:T!==null,children:[s.jsxs("span",{children:[s.jsx("strong",{children:q.name}),q.private?s.jsx("span",{className:"dim",children:" · private"}):null]}),s.jsx("span",{className:"dim",children:q.updated_at.slice(0,10)})]},q.full_name))]}):null,V?s.jsxs("div",{className:"form-row",style:{marginTop:"0.75rem"},children:[s.jsx("label",{htmlFor:"new-repo-name",children:"New repo name"}),s.jsx("input",{id:"new-repo-name",type:"text",value:D,placeholder:"my-vault-backup",onChange:q=>L(q.target.value)}),s.jsxs("div",{className:"actions",children:[s.jsx("button",{type:"button",onClick:O,disabled:R||D.trim().length===0,children:R?"Creating…":"Create"}),s.jsx("button",{type:"button",className:"secondary",onClick:()=>Y(!1),disabled:R,children:"Cancel"})]})]}):s.jsx("div",{className:"actions",style:{marginTop:"0.75rem"},children:s.jsx("button",{type:"button",className:"secondary",onClick:()=>Y(!0),children:"+ Create new private repo"})})]})}function A0({vaultName:u,onClose:c,onSaved:f}){const[r,h]=x.useState(""),[m,y]=x.useState(""),[j,b]=x.useState(""),[v,T]=x.useState(!1),[p,R]=x.useState(null),G=async D=>{D.preventDefault(),T(!0),R(null);try{const L=await Fg(u,{token:r.trim(),remote_url:m.trim(),label:j.trim()||void 0});f(L)}catch(L){R(L instanceof Error?L.message:String(L))}finally{T(!1)}};return s.jsx("div",{className:"modal-backdrop",role:"dialog","aria-modal":"true",children:s.jsxs("div",{className:"modal",children:[s.jsxs("div",{className:"list-header",children:[s.jsx("h3",{style:{margin:0},children:"Use Personal Access Token"}),s.jsx("button",{type:"button",className:"secondary",onClick:c,disabled:v,children:"Close"})]}),s.jsxs("p",{className:"dim",children:["Works for any provider that supports HTTPS push with a token in the URL (GitHub, GitLab, Codeberg, Gitea, …). The token is stored with"," ",s.jsx("code",{children:"0600"})," file perms on this server."]}),s.jsxs("form",{onSubmit:G,children:[s.jsxs("div",{className:"form-row",children:[s.jsx("label",{htmlFor:"pat-token",children:"Token"}),s.jsx("input",{id:"pat-token",type:"password",value:r,autoComplete:"off",onChange:D=>h(D.target.value),placeholder:"ghp_… or glpat-… or similar",required:!0})]}),s.jsxs("div",{className:"form-row",children:[s.jsx("label",{htmlFor:"pat-url",children:"Remote URL"}),s.jsx("input",{id:"pat-url",type:"url",value:m,onChange:D=>y(D.target.value),placeholder:"https://github.com/owner/repo.git",required:!0}),s.jsxs("p",{className:"dim",style:{margin:"0.35rem 0 0"},children:["We'll embed your token in the URL before saving (using GitHub's"," ",s.jsx("code",{children:"x-access-token"})," convention). The URL you see on disk will carry the token; ensure the file isn't shared."]})]}),s.jsxs("div",{className:"form-row",children:[s.jsx("label",{htmlFor:"pat-label",children:"Label (optional)"}),s.jsx("input",{id:"pat-label",type:"text",value:j,onChange:D=>b(D.target.value),placeholder:"GitHub PAT for backup"})]}),p?s.jsx("div",{className:"error-banner",role:"alert",children:s.jsx("code",{children:p})}):null,s.jsxs("div",{className:"actions",children:[s.jsx("button",{type:"submit",disabled:v,children:v?"Validating…":"Validate & save"}),s.jsx("button",{type:"button",className:"secondary",onClick:c,disabled:v,children:"Cancel"})]})]})]})})}function R0({vaultName:u,creds:c}){const[f,r]=x.useState(""),[h,m]=x.useState("merge"),[y,j]=x.useState(!1),[b,v]=x.useState(""),[T,p]=x.useState(!0),[R,G]=x.useState({kind:"idle"}),[D,L]=x.useState(""),[V,Y]=x.useState(!1),Z=(c==null?void 0:c.active_method)==="github_oauth"&&c.github_oauth!==null,k=(c==null?void 0:c.active_method)!==null&&(c==null?void 0:c.active_method)!==void 0,O=h!=="replace"||D.trim()===u,q=R.kind!=="running"&&f.trim().length>0&&O&&(!y||b.trim().length>0),X=async()=>{G({kind:"running",stage:"cloning"});let ee;y?ee={kind:"pat",token:b.trim()}:k?ee=null:ee={kind:"none"};try{const me=window.setTimeout(()=>G(We=>We.kind==="running"?{kind:"running",stage:"importing"}:We),1500),tt=await Pg(u,{remote_url:f.trim(),mode:h,credentials:ee,enable_sync:T});window.clearTimeout(me),G({kind:"success",result:tt,remoteUrl:f.trim(),mode:h})}catch(me){const tt=me instanceof _e?`${me.status===409?"Already running. ":""}${me.message}`:me instanceof Error?me.message:String(me);G({kind:"error",message:tt})}},Q=()=>{G({kind:"idle"}),L("")};return s.jsxs("div",{className:"section",children:[s.jsx("h3",{style:{margin:"0 0 0.85rem",fontSize:"1rem",fontWeight:500},children:"Import from a git repo"}),s.jsxs("p",{className:"dim",style:{marginTop:0},children:["Pull a vault state from a remote git repo into ",s.jsx("strong",{children:"this"})," vault. Use this to load a vault someone has been mirroring, or to sync a vault between machines you control. The remote must be a Parachute vault export (created by ",s.jsx("code",{children:"parachute-vault export"})," or the mirror's export flow)."]}),s.jsxs("div",{className:"warn-banner",style:{marginBottom:"1rem"},role:"note",children:[s.jsx("strong",{children:"One vault per remote."})," Multiple vaults pushing to the same git repo isn't a supported shape — the last push wins, and vaults that diverge silently overwrite each other. Today's working pattern is one vault per remote. Active two-way sync is a future direction; for now, do exports from one place and imports as snapshots elsewhere."]}),R.kind==="success"?s.jsx(w0,{vaultName:u,result:R.result,remoteUrl:R.remoteUrl,mode:R.mode,onReset:Q}):s.jsxs(s.Fragment,{children:[s.jsxs("div",{className:"form-row",children:[s.jsx("label",{htmlFor:"import-remote-url",children:"Remote URL"}),s.jsx("input",{id:"import-remote-url",type:"text",value:f,placeholder:"https://github.com/aaron/my-vault.git",onChange:ee=>r(ee.target.value),disabled:R.kind==="running"}),Z?s.jsxs("p",{className:"dim",style:{margin:"0.35rem 0 0",fontSize:"0.9em"},children:["Or"," ",s.jsx("button",{type:"button",onClick:()=>Y(!0),disabled:R.kind==="running",style:{background:"none",border:"none",padding:0,color:"var(--accent)",textDecoration:"underline",cursor:"pointer",fontSize:"inherit"},children:"pick from your GitHub repos"}),"."]}):null,!k&&!y?s.jsx("p",{className:"hint",style:{marginTop:"0.35rem",fontSize:"0.85em"},children:"No saved git credentials. The import will be unauthenticated — works for public repos; private repos will fail with a clear error. Use the one-time credential toggle below if needed."}):null]}),s.jsxs("div",{className:"form-row",children:[s.jsx("label",{children:"Mode"}),s.jsxs("label",{className:"radio-row",children:[s.jsx("input",{type:"radio",name:"import-mode",value:"merge",checked:h==="merge",onChange:()=>{m("merge"),L("")},disabled:R.kind==="running"}),s.jsxs("span",{children:[s.jsx("strong",{children:"Merge"})," ",s.jsxs("span",{className:"dim",children:["— upsert by id. Notes in the remote get created/updated; any notes that exist only locally ",s.jsx("strong",{children:"survive"}),"."]})]})]}),s.jsxs("label",{className:"radio-row",children:[s.jsx("input",{type:"radio",name:"import-mode",value:"replace",checked:h==="replace",onChange:()=>m("replace"),disabled:R.kind==="running"}),s.jsxs("span",{children:[s.jsx("strong",{children:"Replace"})," ",s.jsxs("span",{className:"dim",children:["— wipe this vault first, then import. The remote becomes the new source of truth. ",s.jsx("strong",{children:"Destructive."})]})]})]})]}),h==="replace"?s.jsxs("div",{className:"form-row",children:[s.jsxs("div",{className:"error-banner",role:"alert",style:{marginBottom:"0.5rem"},children:[s.jsxs("strong",{children:['Replace will delete every note in vault "',u,'" before importing.']})," To confirm, type the vault name below:"]}),s.jsx("input",{id:"import-confirm-name",type:"text",value:D,placeholder:u,onChange:ee=>L(ee.target.value),disabled:R.kind==="running","aria-label":"Type vault name to confirm"})]}):null,s.jsxs("div",{className:"form-row",children:[s.jsxs("label",{children:[s.jsx("input",{type:"checkbox",checked:y,onChange:ee=>j(ee.target.checked),disabled:R.kind==="running",style:{width:"auto",marginRight:"0.5rem"}}),"One-time credential for this import only"]}),s.jsx("p",{className:"dim",style:{margin:"0.35rem 0 0",fontSize:"0.85em"},children:"Use a different Personal Access Token just for this clone, without changing your saved credentials."}),y?s.jsx("input",{id:"import-per-call-pat",type:"password",value:b,placeholder:"ghp_… or similar",onChange:ee=>v(ee.target.value),disabled:R.kind==="running",autoComplete:"off",style:{marginTop:"0.5rem"}}):null]}),s.jsxs("div",{className:"form-row",children:[s.jsxs("label",{children:[s.jsx("input",{type:"checkbox",checked:T,onChange:ee=>p(ee.target.checked),disabled:R.kind==="running",style:{width:"auto",marginRight:"0.5rem"}}),"Also sync changes back to this repo"]}),s.jsx("p",{className:"dim",style:{margin:"0.35rem 0 0",fontSize:"0.85em"},children:"Pushes future changes to this repo automatically. Uses the access you provide above."})]}),R.kind==="error"?s.jsx("div",{className:"error-banner",role:"alert",children:s.jsx("code",{children:R.message})}):null,s.jsx("div",{className:"actions",children:s.jsx("button",{type:"button",onClick:X,disabled:!q,title:O?f.trim().length===0?"Provide a remote URL.":y&&b.trim().length===0?"Provide a token for one-time credential.":void 0:"Type the vault name to confirm Replace.",children:R.kind==="running"?R.stage==="cloning"?"Cloning…":"Importing…":"Start import"})})]}),V?s.jsx(z0,{vaultName:u,onClose:()=>Y(!1),onPicked:ee=>{r(ee),Y(!1)}}):null]})}function w0({vaultName:u,result:c,remoteUrl:f,mode:r,onReset:h}){return s.jsxs(s.Fragment,{children:[s.jsxs("div",{className:"mint-banner",role:"status",style:{marginBottom:"0.75rem"},children:[s.jsx("strong",{children:"Import succeeded."})," Imported ",c.notes_imported," note",c.notes_imported===1?"":"s",", ",c.tags_imported," tag schema",c.tags_imported===1?"":"s",", ",c.attachments_imported," ","attachment",c.attachments_imported===1?"":"s",r==="replace"&&c.notes_deleted!==void 0?`, wiped ${c.notes_deleted} pre-existing note${c.notes_deleted===1?"":"s"}`:"","."]}),c.warnings.length>0?s.jsxs("details",{style:{marginBottom:"0.75rem"},children:[s.jsxs("summary",{children:[c.warnings.length," warning",c.warnings.length===1?"":"s"," ","(see details)"]}),s.jsx("ul",{style:{marginTop:"0.5rem"},children:c.warnings.map((m,y)=>s.jsx("li",{children:s.jsx("code",{style:{fontSize:"0.85em"},children:m})},y))})]}):null,c.sync_enabled?s.jsxs("div",{className:"mint-banner",style:{marginBottom:"0.75rem"},role:"status",children:[s.jsx("strong",{children:"Sync enabled."})," Changes to vault ",s.jsx("code",{children:u})," ","now push back to ",s.jsx("code",{children:f})," automatically."]}):c.sync_warning?s.jsxs("div",{className:"info-banner",style:{marginBottom:"0.75rem"},role:"status",children:[s.jsxs("p",{style:{marginTop:0},children:[s.jsx("strong",{children:"Sync not enabled."})," ",c.sync_warning]}),s.jsxs("p",{className:"dim",style:{marginBottom:0,fontSize:"0.9em"},children:["You can still set up Sync from the"," ",s.jsx("button",{type:"button",onClick:()=>{var m;return(m=document.getElementById("git-remote-section"))==null?void 0:m.scrollIntoView({behavior:"smooth",block:"start"})},style:{background:"none",border:"none",padding:0,color:"var(--accent)",textDecoration:"underline",cursor:"pointer",fontSize:"inherit"},children:"Git remote section"})," ","above."]})]}):null,s.jsx("div",{className:"actions",children:s.jsx("button",{type:"button",className:"secondary",onClick:h,children:"Run another import"})})]})}function z0({vaultName:u,onClose:c,onPicked:f}){const[r,h]=x.useState(null),[m,y]=x.useState(!1),[j,b]=x.useState(""),[v,T]=x.useState(null);x.useEffect(()=>{let R=!1;return pm(u).then(({repos:G,truncated:D})=>{R||(h(G),y(!!D))}).catch(G=>{R||T(G instanceof Error?G.message:String(G))}),()=>{R=!0}},[u]);const p=(r??[]).filter(R=>j.length===0?!0:R.full_name.toLowerCase().includes(j.toLowerCase()));return s.jsx("div",{className:"modal-backdrop",role:"dialog","aria-modal":"true",children:s.jsxs("div",{className:"modal",children:[s.jsxs("div",{className:"list-header",children:[s.jsx("h3",{style:{margin:0},children:"Pick a repo to import from"}),s.jsx("button",{type:"button",className:"secondary",onClick:c,children:"Close"})]}),v?s.jsx("div",{className:"error-banner",role:"alert",children:s.jsx("code",{children:v})}):null,s.jsx("div",{className:"form-row",children:s.jsx("input",{type:"search",placeholder:"Filter by name…",value:j,onChange:R=>b(R.target.value)})}),m?s.jsx("p",{className:"muted",style:{fontSize:"0.85em"},children:"Showing the first 300 repos. Use the filter above to narrow down."}):null,r===null&&!v?s.jsx("p",{className:"muted",children:"Loading repos…"}):null,r!==null?s.jsxs("div",{className:"repo-list",children:[p.length===0&&j.length>0?s.jsxs("p",{className:"dim",children:['No repos match "',j,'".']}):null,p.length===0&&j.length===0&&r.length===0?s.jsx("p",{className:"dim",children:"You don't own any repos on this account."}):null,p.map(R=>s.jsxs("button",{type:"button",className:"repo-row",onClick:()=>f(R.clone_url),children:[s.jsxs("span",{children:[s.jsx("strong",{children:R.name}),R.private?s.jsx("span",{className:"dim",children:" · private"}):null]}),s.jsx("span",{className:"dim",children:R.updated_at.slice(0,10)})]},R.full_name))]}):null]})})}const C0=[30,90,180,365],Vh=90,M0=1440*60;function O0(u){if(!u)return null;const c=u.scoped_tags;if(!Array.isArray(c))return null;const f=c.filter(r=>typeof r=="string"&&r.length>0);return f.length>0?f:null}function D0(u){return{jti:u.jti,label:u.subject,scopes:Array.isArray(u.scopes)?u.scopes:[],scoped_tags:O0(u.permissions),expires_at:u.expires_at??null,revoked_at:u.revoked_at??null,created_at:u.created_at}}async function U0(u,c){const f={scope:`vault:${u}:${c.verb}`,expires_in:c.ttlDays*M0,subject:c.label};c.scopedTags.length>0&&(f.permissions={scoped_tags:c.scopedTags});const r=await Fa("/api/auth/mint-token",{method:"POST",headers:{"content-type":"application/json"},body:JSON.stringify(f)});if(!r.ok)throw new _e(r.status,await _u(r));const h=await r.json();return{jti:h.jti,token:h.token,scope:h.scope,expires_at:h.expires_at??null}}async function k0(u){const c=`vault:${u}:`,f=[];let r=null;for(let h=0;h<1e3;h++){const m=new URLSearchParams({revoked:"all"});r&&m.set("cursor",r);const y=await Fa(`/api/auth/tokens?${m.toString()}`);if(!y.ok)throw new _e(y.status,await _u(y));const j=await y.json(),b=Array.isArray(j.tokens)?j.tokens:[];if(f.push(...b),r=j.next_cursor??null,!r)break}return f.filter(h=>Array.isArray(h.scopes)&&h.scopes.some(m=>m.startsWith(c))).map(D0)}async function H0(u){const c=await Fa("/api/auth/revoke-token",{method:"POST",headers:{"content-type":"application/json"},body:JSON.stringify({jti:u})});if(!c.ok)throw new _e(c.status,await _u(c))}async function B0(u){const c=await et(u,`/vault/${encodeURIComponent(u)}/api/tags`);if(!c.ok)throw new _e(c.status,await _u(c));const f=await c.json();return Array.isArray(f)?f:[]}async function _u(u){try{const c=await u.text(),f=JSON.parse(c);if(f.error_description)return f.error_description;if(f.message)return f.message;if(f.error)return f.error;if(c)return c}catch{}return`${u.status} ${u.statusText}`}const L0=["read","write","admin"],q0={30:"30 days",90:"90 days",180:"180 days",365:"1 year (max)"};function Y0(u){return u instanceof Bl?u.disposition==="forbidden"?(Za(),{kind:"auth-required",status:403}):u.disposition==="auth-required"?{kind:"auth-required",status:u.status}:{kind:"error",message:u.message}:u instanceof _e&&(u.status===401||u.status===403)?{kind:"auth-required",status:u.status}:{kind:"error",message:u instanceof Error?u.message:String(u)}}function Xh({vaultName:u}={}){const c=rr(),f=u??c.name,r=u!==void 0,h=r?"/":`/vault/${encodeURIComponent(f??"")}`,[m,y]=x.useState({kind:"loading"}),[j,b]=x.useState(null),[v,T]=x.useState(null),[p,R]=x.useState(0);x.useEffect(()=>{let L=!1;if(f)return y({kind:"loading"}),k0(f).then(V=>{L||y({kind:"ok",tokens:V})}).catch(V=>{L||y(Y0(V))}),()=>{L=!0}},[f,p]);const G=x.useCallback(()=>R(L=>L+1),[]);if(x.useEffect(()=>{if(!j)return;const L=V=>{V.preventDefault(),V.returnValue=""};return window.addEventListener("beforeunload",L),()=>window.removeEventListener("beforeunload",L)},[j]),!f)return s.jsxs("div",{children:[s.jsx("h2",{children:"Tokens"}),s.jsx("p",{className:"muted",children:"Missing vault name."}),r?null:s.jsx(Je,{to:"/",children:"← Back to vaults"})]});const D=bm(f);return s.jsxs("div",{children:[s.jsxs("div",{className:"list-header",children:[s.jsxs("h2",{children:["Tokens for ",s.jsx("code",{children:f})]}),s.jsx(Je,{to:h,className:"muted",children:"← Vault detail"})]}),D?null:s.jsxs("div",{className:"warn-banner",children:["You're viewing this page with a read-only token. Mint and revoke require"," ",s.jsxs("code",{children:["vault:",f,":admin"]}),`. Re-enter from the hub directory's "Manage" link with an admin-scoped session to manage tokens.`]}),j?s.jsx(G0,{result:j,onDismiss:()=>b(null)}):null,m.kind==="ok"&&D&&!j?s.jsx(V0,{vaultName:f,onMinted:L=>{b(L),R(V=>V+1)}}):null,s.jsxs("div",{className:"section",children:[s.jsx("h3",{style:{margin:"0 0 0.85rem",fontSize:"1rem",fontWeight:500},children:"Existing tokens"}),m.kind==="loading"?s.jsx("p",{className:"muted",children:"Loading…"}):null,m.kind==="auth-required"?s.jsx(Tu,{vaultName:f,status:m.status,onRecovered:G}):null,m.kind==="error"?s.jsx("div",{className:"error-banner",children:s.jsx("code",{children:m.message})}):null,m.kind==="ok"?s.jsx(X0,{tokens:m.tokens,allowRevoke:D,confirmingJti:v,onAskConfirm:T,onRevoked:()=>{T(null),R(L=>L+1)}}):null]})]})}function G0({result:u,onDismiss:c}){const[f,r]=x.useState(!1),h=async()=>{try{await navigator.clipboard.writeText(u.token),r(!0),setTimeout(()=>r(!1),2e3)}catch{}};return s.jsxs("div",{className:"mint-banner",children:[s.jsx("h3",{children:"New token (shown once)"}),s.jsx("p",{className:"muted",children:"This is the only time the vault will show this token. Copy it now and store it somewhere safe — a password manager, the operator's notes, paraclaw's secrets store. If you lose it, revoke it and mint a new one."}),s.jsxs("div",{className:"token-box",children:[s.jsx("code",{children:u.token}),s.jsx("button",{type:"button",onClick:h,className:"secondary",children:f?"Copied":"Copy"})]}),s.jsx("p",{className:"warn",children:"⚠ Don't dismiss this banner until you've saved the token."}),s.jsx("div",{className:"actions",children:s.jsx("button",{type:"button",onClick:c,children:"Done — I've saved the token"})})]})}function V0({vaultName:u,onMinted:c}){const[f,r]=x.useState(""),[h,m]=x.useState("admin"),[y,j]=x.useState(Vh),[b,v]=x.useState(!1),[T,p]=x.useState(null),[R,G]=x.useState([]),[D,L]=x.useState(null),[V,Y]=x.useState(new Set);x.useEffect(()=>{let X=!1;return B0(u).then(Q=>{if(X)return;const ee=Q.map(me=>me.name).filter(me=>!me.includes("/")).sort();G(ee)}).catch(Q=>{X||L(Q instanceof Error?Q.message:String(Q))}),()=>{X=!0}},[u]);const Z=f.trim(),k=Z.length===0,O=X=>{Y(Q=>{const ee=new Set(Q);return ee.has(X)?ee.delete(X):ee.add(X),ee})},q=async X=>{if(X.preventDefault(),k){p("label required — give the token a recognizable name");return}v(!0),p(null);try{const Q=await U0(u,{verb:h,label:Z,scopedTags:[...V],ttlDays:y});c(Q),r(""),m("admin"),j(Vh),Y(new Set)}catch(Q){if(Q instanceof Bl&&Q.disposition==="forbidden"){Za();return}p(Q instanceof Error?Q.message:String(Q))}finally{v(!1)}};return s.jsxs("form",{onSubmit:q,className:"section",children:[s.jsx("h3",{style:{margin:"0 0 0.85rem",fontSize:"1rem",fontWeight:500},children:"Mint a token"}),s.jsx("p",{className:"dim",style:{margin:"0 0 0.85rem"},children:"Issues a hub-signed token (JWT) scoped to this vault. Store it like a password — it's shown once and can't be re-displayed."}),T?s.jsx("div",{className:"error-banner",children:s.jsx("code",{children:T})}):null,s.jsxs("div",{className:"form-row",children:[s.jsxs("label",{htmlFor:"mint-label",children:["Label ",s.jsx("span",{className:"dim",children:"(required)"})]}),s.jsx("input",{id:"mint-label",type:"text",value:f,onChange:X=>r(X.target.value),placeholder:"e.g. ci, paraclaw-prod, my-laptop",maxLength:120,required:!0})]}),s.jsxs("div",{className:"form-row",children:[s.jsx("label",{htmlFor:"mint-scope",children:"Scope"}),s.jsx("select",{id:"mint-scope",value:h,onChange:X=>m(X.target.value),children:L0.map(X=>s.jsx("option",{value:X,children:X==="read"?"read — query notes only":X==="write"?"write — query + create/update notes":"admin — full control (incl. token mgmt)"},X))}),s.jsxs("p",{className:"dim",style:{margin:"0.35rem 0 0"},children:["Issued as ",s.jsxs("code",{children:["vault:",u,":",h]}),". Lower scopes inherit narrower powers."]})]}),s.jsxs("div",{className:"form-row",children:[s.jsx("label",{htmlFor:"mint-ttl",children:"Expires after"}),s.jsx("select",{id:"mint-ttl",value:y,onChange:X=>j(Number(X.target.value)),children:C0.map(X=>s.jsx("option",{value:X,children:q0[X]??`${X} days`},X))}),s.jsx("p",{className:"dim",style:{margin:"0.35rem 0 0"},children:"The token stops working after this. Rotate before it lapses."})]}),s.jsxs("div",{className:"form-row",children:[s.jsxs("label",{children:["Tag scope ",s.jsx("span",{className:"dim",children:"(optional)"})]}),D?s.jsxs("p",{className:"dim",style:{margin:"0.35rem 0 0"},children:["Couldn't load tags: ",s.jsx("code",{children:D}),". Token will be unscoped."]}):R.length===0?s.jsx("p",{className:"dim",style:{margin:"0.35rem 0 0"},children:"No root tags in this vault yet — token will see the full vault."}):s.jsxs(s.Fragment,{children:[s.jsx("div",{className:"tag-picker",children:R.map(X=>s.jsxs("label",{className:"tag-checkbox",children:[s.jsx("input",{type:"checkbox",checked:V.has(X),onChange:()=>O(X)}),s.jsx("code",{children:X})]},X))}),s.jsx("p",{className:"dim",style:{margin:"0.35rem 0 0"},children:V.size===0?"Nothing selected — token sees the full vault (unscoped).":`Token limited to: ${[...V].join(", ")}. Sub-tags (e.g. health/food) are reachable when their root is selected.`})]})]}),s.jsx("div",{className:"actions",children:s.jsx("button",{type:"submit",disabled:b||k,children:b?"Minting…":"Mint token"})})]})}function X0({tokens:u,allowRevoke:c,confirmingJti:f,onAskConfirm:r,onRevoked:h}){return u.length===0?s.jsx("p",{className:"muted",children:"No tokens yet. Mint one above to get started."}):s.jsx("div",{className:"token-list",children:u.map(m=>s.jsx(Q0,{token:m,allowRevoke:c,confirming:f===m.jti,onAskConfirm:r,onRevoked:h},m.jti))})}function Q0({token:u,allowRevoke:c,confirming:f,onAskConfirm:r,onRevoked:h}){const[m,y]=x.useState(!1),[j,b]=x.useState(null),v=u.revoked_at!==null,T=async()=>{y(!0),b(null);try{await H0(u.jti),h()}catch(p){if(p instanceof Bl&&p.disposition==="forbidden"){Za();return}b(p instanceof Error?p.message:String(p)),y(!1)}};return s.jsxs("div",{className:"token-row",children:[s.jsxs("div",{className:"body",children:[s.jsxs("div",{className:"name",children:[s.jsx("strong",{children:u.label??"(unlabeled)"}),s.jsx("code",{className:"dim",children:u.jti}),v?s.jsx("code",{className:"scope-tag",title:"This token has been revoked and no longer works.",children:"revoked"}):null]}),s.jsxs("div",{className:"meta",children:[s.jsx("span",{className:"dim",children:"scopes:"})," ",u.scopes.length>0?u.scopes.map(p=>s.jsx("code",{className:"scope-tag",children:p},p)):s.jsx("span",{className:"dim",children:"(none)"})]}),u.scoped_tags&&u.scoped_tags.length>0?s.jsxs("div",{className:"meta",children:[s.jsx("span",{className:"dim",children:"tags:"})," ",u.scoped_tags.map(p=>s.jsxs("code",{className:"scope-tag tag-pill",children:["#",p]},p))]}):null,s.jsxs("div",{className:"meta dim",children:["created ",u.created_at,u.expires_at?` · expires ${u.expires_at}`:"",v&&u.revoked_at?` · revoked ${u.revoked_at}`:""]}),j?s.jsx("div",{className:"error-banner",style:{marginTop:"0.5rem"},children:s.jsx("code",{children:j})}):null]}),c&&!v?f?s.jsxs("div",{className:"actions",children:[s.jsx("button",{type:"button",onClick:T,disabled:m,children:m?"Revoking…":"Confirm revoke"}),s.jsx("button",{type:"button",className:"secondary",onClick:()=>r(null),disabled:m,children:"Cancel"})]}):s.jsx("button",{type:"button",className:"secondary",onClick:()=>r(u.jti),children:"Revoke"}):null]})}function Z0(){const[u,c]=x.useState({kind:"loading"});return x.useEffect(()=>{let f=!1;return vm().then(r=>{f||c({kind:"ok",vaults:r})}).catch(r=>{if(f)return;const h=r instanceof _e?`${r.status}: ${r.message}`:r instanceof Error?r.message:String(r);c({kind:"error",message:h})}),()=>{f=!0}},[]),u.kind==="loading"?s.jsxs("div",{children:[s.jsx("h2",{children:"Vaults"}),s.jsx("p",{className:"muted",children:"Loading…"})]}):u.kind==="error"?s.jsxs("div",{children:[s.jsx("h2",{children:"Vaults"}),s.jsx("div",{className:"error-banner",children:s.jsx("code",{children:u.message})})]}):u.vaults.length===0?s.jsxs("div",{children:[s.jsx("h2",{children:"Vaults"}),s.jsxs("div",{className:"empty",children:["No vaults yet. Run ",s.jsx("code",{children:"parachute-vault create <name>"})," on the host to create one."]})]}):s.jsxs("div",{children:[s.jsx("div",{className:"list-header",children:s.jsx("h2",{children:"Vaults"})}),u.vaults.map(f=>s.jsxs(Je,{to:`/vault/${f}`,className:"vault-row",children:[s.jsx("div",{className:"body",children:s.jsx("div",{className:"name",children:s.jsx("code",{children:f})})}),s.jsx("div",{className:"chev",children:"→"})]},f))]})}function K0(){const u=yr(),c=u?null:hm();return s.jsxs("div",{className:"page",children:[s.jsxs("nav",{className:"nav",children:[s.jsxs(Je,{to:"/",className:"brand",children:["Parachute Vault ",s.jsx("span",{className:"sub",children:"admin"})]}),c?s.jsx(Je,{to:"/",children:s.jsx("code",{children:c})}):s.jsx(Je,{to:"/",children:"Vaults"})]}),u?s.jsxs(Ic,{children:[s.jsx(Ct,{path:"/",element:s.jsx(h0,{})}),s.jsx(Ct,{path:"*",element:s.jsx(er,{})})]}):c?s.jsxs(Ic,{children:[s.jsx(Ct,{path:"/",element:s.jsx(Yh,{vaultName:c})}),s.jsx(Ct,{path:"/tokens",element:s.jsx(Xh,{vaultName:c})}),s.jsx(Ct,{path:"/mirror",element:s.jsx(Gh,{vaultName:c})}),s.jsx(Ct,{path:"*",element:s.jsx(er,{})})]}):s.jsxs(Ic,{children:[s.jsx(Ct,{path:"/",element:s.jsx(Z0,{})}),s.jsx(Ct,{path:"/vault/:name",element:s.jsx(Yh,{})}),s.jsx(Ct,{path:"/vault/:name/tokens",element:s.jsx(Xh,{})}),s.jsx(Ct,{path:"/vault/:name/mirror",element:s.jsx(Gh,{})}),s.jsx(Ct,{path:"*",element:s.jsx(er,{})})]})]})}function er(){return s.jsxs("div",{className:"empty",children:["404 — back to ",s.jsx(Je,{to:"/",children:"vault"}),"."]})}kg();const jm=document.getElementById("root");if(!jm)throw new Error("#root not found");function tr(){tp.createRoot(jm).render(s.jsx(x.StrictMode,{children:s.jsx(jg,{basename:Mg(),children:s.jsx(K0,{})})}))}const Qh=hm();!yr()&&Qh?Lg(Qh).then(tr,tr):tr();
|