@amodalai/runtime-app 0.1.9
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/LICENSE +21 -0
- package/dist/assets/_virtual_amodal-manifest-DIezHQq3.js +1 -0
- package/dist/assets/index-CV-B6F_Z.js +277 -0
- package/dist/assets/index-D_9W94P3.css +1 -0
- package/dist/index.html +14 -0
- package/dist-dev/create-dev-middleware.d.ts +22 -0
- package/dist-dev/create-dev-middleware.js +53 -0
- package/dist-dev/vite-plugin-amodal.d.ts +35 -0
- package/dist-dev/vite-plugin-amodal.js +193 -0
- package/package.json +49 -0
|
@@ -0,0 +1,277 @@
|
|
|
1
|
+
var W0=Object.defineProperty;var Vh=e=>{throw TypeError(e)};var Q0=(e,r,i)=>r in e?W0(e,r,{enumerable:!0,configurable:!0,writable:!0,value:i}):e[r]=i;var $a=(e,r,i)=>Q0(e,typeof r!="symbol"?r+"":r,i),tc=(e,r,i)=>r.has(e)||Vh("Cannot "+i);var Q=(e,r,i)=>(tc(e,r,"read from private field"),i?i.call(e):r.get(e)),We=(e,r,i)=>r.has(e)?Vh("Cannot add the same private member more than once"):r instanceof WeakSet?r.add(e):r.set(e,i),Me=(e,r,i,l)=>(tc(e,r,"write to private field"),l?l.call(e,i):r.set(e,i),i),Dt=(e,r,i)=>(tc(e,r,"access private method"),i);var Wa=(e,r,i,l)=>({set _(a){Me(e,r,a,i)},get _(){return Q(e,r,l)}});function Im(e,r){for(var i=0;i<r.length;i++){const l=r[i];if(typeof l!="string"&&!Array.isArray(l)){for(const a in l)if(a!=="default"&&!(a in e)){const u=Object.getOwnPropertyDescriptor(l,a);u&&Object.defineProperty(e,a,u.get?u:{enumerable:!0,get:()=>l[a]})}}}return Object.freeze(Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}))}(function(){const r=document.createElement("link").relList;if(r&&r.supports&&r.supports("modulepreload"))return;for(const a of document.querySelectorAll('link[rel="modulepreload"]'))l(a);new MutationObserver(a=>{for(const u of a)if(u.type==="childList")for(const c of u.addedNodes)c.tagName==="LINK"&&c.rel==="modulepreload"&&l(c)}).observe(document,{childList:!0,subtree:!0});function i(a){const u={};return a.integrity&&(u.integrity=a.integrity),a.referrerPolicy&&(u.referrerPolicy=a.referrerPolicy),a.crossOrigin==="use-credentials"?u.credentials="include":a.crossOrigin==="anonymous"?u.credentials="omit":u.credentials="same-origin",u}function l(a){if(a.ep)return;a.ep=!0;const u=i(a);fetch(a.href,u)}})();function ds(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var nc={exports:{}},so={},rc={exports:{}},Ue={};/**
|
|
2
|
+
* @license React
|
|
3
|
+
* react.production.min.js
|
|
4
|
+
*
|
|
5
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
6
|
+
*
|
|
7
|
+
* This source code is licensed under the MIT license found in the
|
|
8
|
+
* LICENSE file in the root directory of this source tree.
|
|
9
|
+
*/var $h;function q0(){if($h)return Ue;$h=1;var e=Symbol.for("react.element"),r=Symbol.for("react.portal"),i=Symbol.for("react.fragment"),l=Symbol.for("react.strict_mode"),a=Symbol.for("react.profiler"),u=Symbol.for("react.provider"),c=Symbol.for("react.context"),f=Symbol.for("react.forward_ref"),p=Symbol.for("react.suspense"),m=Symbol.for("react.memo"),g=Symbol.for("react.lazy"),y=Symbol.iterator;function k(R){return R===null||typeof R!="object"?null:(R=y&&R[y]||R["@@iterator"],typeof R=="function"?R:null)}var x={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},T=Object.assign,N={};function b(R,q,C){this.props=R,this.context=q,this.refs=N,this.updater=C||x}b.prototype.isReactComponent={},b.prototype.setState=function(R,q){if(typeof R!="object"&&typeof R!="function"&&R!=null)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,R,q,"setState")},b.prototype.forceUpdate=function(R){this.updater.enqueueForceUpdate(this,R,"forceUpdate")};function P(){}P.prototype=b.prototype;function z(R,q,C){this.props=R,this.context=q,this.refs=N,this.updater=C||x}var I=z.prototype=new P;I.constructor=z,T(I,b.prototype),I.isPureReactComponent=!0;var F=Array.isArray,ee=Object.prototype.hasOwnProperty,B={current:null},D={key:!0,ref:!0,__self:!0,__source:!0};function G(R,q,C){var Ce,Ne={},ke=null,Fe=null;if(q!=null)for(Ce in q.ref!==void 0&&(Fe=q.ref),q.key!==void 0&&(ke=""+q.key),q)ee.call(q,Ce)&&!D.hasOwnProperty(Ce)&&(Ne[Ce]=q[Ce]);var De=arguments.length-2;if(De===1)Ne.children=C;else if(1<De){for(var qe=Array(De),mt=0;mt<De;mt++)qe[mt]=arguments[mt+2];Ne.children=qe}if(R&&R.defaultProps)for(Ce in De=R.defaultProps,De)Ne[Ce]===void 0&&(Ne[Ce]=De[Ce]);return{$$typeof:e,type:R,key:ke,ref:Fe,props:Ne,_owner:B.current}}function le(R,q){return{$$typeof:e,type:R.type,key:q,ref:R.ref,props:R.props,_owner:R._owner}}function re(R){return typeof R=="object"&&R!==null&&R.$$typeof===e}function $(R){var q={"=":"=0",":":"=2"};return"$"+R.replace(/[=:]/g,function(C){return q[C]})}var K=/\/+/g;function Se(R,q){return typeof R=="object"&&R!==null&&R.key!=null?$(""+R.key):q.toString(36)}function se(R,q,C,Ce,Ne){var ke=typeof R;(ke==="undefined"||ke==="boolean")&&(R=null);var Fe=!1;if(R===null)Fe=!0;else switch(ke){case"string":case"number":Fe=!0;break;case"object":switch(R.$$typeof){case e:case r:Fe=!0}}if(Fe)return Fe=R,Ne=Ne(Fe),R=Ce===""?"."+Se(Fe,0):Ce,F(Ne)?(C="",R!=null&&(C=R.replace(K,"$&/")+"/"),se(Ne,q,C,"",function(mt){return mt})):Ne!=null&&(re(Ne)&&(Ne=le(Ne,C+(!Ne.key||Fe&&Fe.key===Ne.key?"":(""+Ne.key).replace(K,"$&/")+"/")+R)),q.push(Ne)),1;if(Fe=0,Ce=Ce===""?".":Ce+":",F(R))for(var De=0;De<R.length;De++){ke=R[De];var qe=Ce+Se(ke,De);Fe+=se(ke,q,C,qe,Ne)}else if(qe=k(R),typeof qe=="function")for(R=qe.call(R),De=0;!(ke=R.next()).done;)ke=ke.value,qe=Ce+Se(ke,De++),Fe+=se(ke,q,C,qe,Ne);else if(ke==="object")throw q=String(R),Error("Objects are not valid as a React child (found: "+(q==="[object Object]"?"object with keys {"+Object.keys(R).join(", ")+"}":q)+"). If you meant to render a collection of children, use an array instead.");return Fe}function ne(R,q,C){if(R==null)return R;var Ce=[],Ne=0;return se(R,Ce,"","",function(ke){return q.call(C,ke,Ne++)}),Ce}function be(R){if(R._status===-1){var q=R._result;q=q(),q.then(function(C){(R._status===0||R._status===-1)&&(R._status=1,R._result=C)},function(C){(R._status===0||R._status===-1)&&(R._status=2,R._result=C)}),R._status===-1&&(R._status=0,R._result=q)}if(R._status===1)return R._result.default;throw R._result}var _e={current:null},Y={transition:null},ce={ReactCurrentDispatcher:_e,ReactCurrentBatchConfig:Y,ReactCurrentOwner:B};function S(){throw Error("act(...) is not supported in production builds of React.")}return Ue.Children={map:ne,forEach:function(R,q,C){ne(R,function(){q.apply(this,arguments)},C)},count:function(R){var q=0;return ne(R,function(){q++}),q},toArray:function(R){return ne(R,function(q){return q})||[]},only:function(R){if(!re(R))throw Error("React.Children.only expected to receive a single React element child.");return R}},Ue.Component=b,Ue.Fragment=i,Ue.Profiler=a,Ue.PureComponent=z,Ue.StrictMode=l,Ue.Suspense=p,Ue.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=ce,Ue.act=S,Ue.cloneElement=function(R,q,C){if(R==null)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+R+".");var Ce=T({},R.props),Ne=R.key,ke=R.ref,Fe=R._owner;if(q!=null){if(q.ref!==void 0&&(ke=q.ref,Fe=B.current),q.key!==void 0&&(Ne=""+q.key),R.type&&R.type.defaultProps)var De=R.type.defaultProps;for(qe in q)ee.call(q,qe)&&!D.hasOwnProperty(qe)&&(Ce[qe]=q[qe]===void 0&&De!==void 0?De[qe]:q[qe])}var qe=arguments.length-2;if(qe===1)Ce.children=C;else if(1<qe){De=Array(qe);for(var mt=0;mt<qe;mt++)De[mt]=arguments[mt+2];Ce.children=De}return{$$typeof:e,type:R.type,key:Ne,ref:ke,props:Ce,_owner:Fe}},Ue.createContext=function(R){return R={$$typeof:c,_currentValue:R,_currentValue2:R,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null},R.Provider={$$typeof:u,_context:R},R.Consumer=R},Ue.createElement=G,Ue.createFactory=function(R){var q=G.bind(null,R);return q.type=R,q},Ue.createRef=function(){return{current:null}},Ue.forwardRef=function(R){return{$$typeof:f,render:R}},Ue.isValidElement=re,Ue.lazy=function(R){return{$$typeof:g,_payload:{_status:-1,_result:R},_init:be}},Ue.memo=function(R,q){return{$$typeof:m,type:R,compare:q===void 0?null:q}},Ue.startTransition=function(R){var q=Y.transition;Y.transition={};try{R()}finally{Y.transition=q}},Ue.unstable_act=S,Ue.useCallback=function(R,q){return _e.current.useCallback(R,q)},Ue.useContext=function(R){return _e.current.useContext(R)},Ue.useDebugValue=function(){},Ue.useDeferredValue=function(R){return _e.current.useDeferredValue(R)},Ue.useEffect=function(R,q){return _e.current.useEffect(R,q)},Ue.useId=function(){return _e.current.useId()},Ue.useImperativeHandle=function(R,q,C){return _e.current.useImperativeHandle(R,q,C)},Ue.useInsertionEffect=function(R,q){return _e.current.useInsertionEffect(R,q)},Ue.useLayoutEffect=function(R,q){return _e.current.useLayoutEffect(R,q)},Ue.useMemo=function(R,q){return _e.current.useMemo(R,q)},Ue.useReducer=function(R,q,C){return _e.current.useReducer(R,q,C)},Ue.useRef=function(R){return _e.current.useRef(R)},Ue.useState=function(R){return _e.current.useState(R)},Ue.useSyncExternalStore=function(R,q,C){return _e.current.useSyncExternalStore(R,q,C)},Ue.useTransition=function(){return _e.current.useTransition()},Ue.version="18.3.1",Ue}var Wh;function Qc(){return Wh||(Wh=1,rc.exports=q0()),rc.exports}/**
|
|
10
|
+
* @license React
|
|
11
|
+
* react-jsx-runtime.production.min.js
|
|
12
|
+
*
|
|
13
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
14
|
+
*
|
|
15
|
+
* This source code is licensed under the MIT license found in the
|
|
16
|
+
* LICENSE file in the root directory of this source tree.
|
|
17
|
+
*/var Qh;function K0(){if(Qh)return so;Qh=1;var e=Qc(),r=Symbol.for("react.element"),i=Symbol.for("react.fragment"),l=Object.prototype.hasOwnProperty,a=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,u={key:!0,ref:!0,__self:!0,__source:!0};function c(f,p,m){var g,y={},k=null,x=null;m!==void 0&&(k=""+m),p.key!==void 0&&(k=""+p.key),p.ref!==void 0&&(x=p.ref);for(g in p)l.call(p,g)&&!u.hasOwnProperty(g)&&(y[g]=p[g]);if(f&&f.defaultProps)for(g in p=f.defaultProps,p)y[g]===void 0&&(y[g]=p[g]);return{$$typeof:r,type:f,key:k,ref:x,props:y,_owner:a.current}}return so.Fragment=i,so.jsx=c,so.jsxs=c,so}var qh;function G0(){return qh||(qh=1,nc.exports=K0()),nc.exports}var v=G0(),M=Qc();const Mm=ds(M),Y0=Im({__proto__:null,default:Mm},[M]);var ic={exports:{}},Jt={},lc={exports:{}},oc={};/**
|
|
18
|
+
* @license React
|
|
19
|
+
* scheduler.production.min.js
|
|
20
|
+
*
|
|
21
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
22
|
+
*
|
|
23
|
+
* This source code is licensed under the MIT license found in the
|
|
24
|
+
* LICENSE file in the root directory of this source tree.
|
|
25
|
+
*/var Kh;function X0(){return Kh||(Kh=1,function(e){function r(Y,ce){var S=Y.length;Y.push(ce);e:for(;0<S;){var R=S-1>>>1,q=Y[R];if(0<a(q,ce))Y[R]=ce,Y[S]=q,S=R;else break e}}function i(Y){return Y.length===0?null:Y[0]}function l(Y){if(Y.length===0)return null;var ce=Y[0],S=Y.pop();if(S!==ce){Y[0]=S;e:for(var R=0,q=Y.length,C=q>>>1;R<C;){var Ce=2*(R+1)-1,Ne=Y[Ce],ke=Ce+1,Fe=Y[ke];if(0>a(Ne,S))ke<q&&0>a(Fe,Ne)?(Y[R]=Fe,Y[ke]=S,R=ke):(Y[R]=Ne,Y[Ce]=S,R=Ce);else if(ke<q&&0>a(Fe,S))Y[R]=Fe,Y[ke]=S,R=ke;else break e}}return ce}function a(Y,ce){var S=Y.sortIndex-ce.sortIndex;return S!==0?S:Y.id-ce.id}if(typeof performance=="object"&&typeof performance.now=="function"){var u=performance;e.unstable_now=function(){return u.now()}}else{var c=Date,f=c.now();e.unstable_now=function(){return c.now()-f}}var p=[],m=[],g=1,y=null,k=3,x=!1,T=!1,N=!1,b=typeof setTimeout=="function"?setTimeout:null,P=typeof clearTimeout=="function"?clearTimeout:null,z=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function I(Y){for(var ce=i(m);ce!==null;){if(ce.callback===null)l(m);else if(ce.startTime<=Y)l(m),ce.sortIndex=ce.expirationTime,r(p,ce);else break;ce=i(m)}}function F(Y){if(N=!1,I(Y),!T)if(i(p)!==null)T=!0,be(ee);else{var ce=i(m);ce!==null&&_e(F,ce.startTime-Y)}}function ee(Y,ce){T=!1,N&&(N=!1,P(G),G=-1),x=!0;var S=k;try{for(I(ce),y=i(p);y!==null&&(!(y.expirationTime>ce)||Y&&!$());){var R=y.callback;if(typeof R=="function"){y.callback=null,k=y.priorityLevel;var q=R(y.expirationTime<=ce);ce=e.unstable_now(),typeof q=="function"?y.callback=q:y===i(p)&&l(p),I(ce)}else l(p);y=i(p)}if(y!==null)var C=!0;else{var Ce=i(m);Ce!==null&&_e(F,Ce.startTime-ce),C=!1}return C}finally{y=null,k=S,x=!1}}var B=!1,D=null,G=-1,le=5,re=-1;function $(){return!(e.unstable_now()-re<le)}function K(){if(D!==null){var Y=e.unstable_now();re=Y;var ce=!0;try{ce=D(!0,Y)}finally{ce?Se():(B=!1,D=null)}}else B=!1}var Se;if(typeof z=="function")Se=function(){z(K)};else if(typeof MessageChannel<"u"){var se=new MessageChannel,ne=se.port2;se.port1.onmessage=K,Se=function(){ne.postMessage(null)}}else Se=function(){b(K,0)};function be(Y){D=Y,B||(B=!0,Se())}function _e(Y,ce){G=b(function(){Y(e.unstable_now())},ce)}e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(Y){Y.callback=null},e.unstable_continueExecution=function(){T||x||(T=!0,be(ee))},e.unstable_forceFrameRate=function(Y){0>Y||125<Y?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):le=0<Y?Math.floor(1e3/Y):5},e.unstable_getCurrentPriorityLevel=function(){return k},e.unstable_getFirstCallbackNode=function(){return i(p)},e.unstable_next=function(Y){switch(k){case 1:case 2:case 3:var ce=3;break;default:ce=k}var S=k;k=ce;try{return Y()}finally{k=S}},e.unstable_pauseExecution=function(){},e.unstable_requestPaint=function(){},e.unstable_runWithPriority=function(Y,ce){switch(Y){case 1:case 2:case 3:case 4:case 5:break;default:Y=3}var S=k;k=Y;try{return ce()}finally{k=S}},e.unstable_scheduleCallback=function(Y,ce,S){var R=e.unstable_now();switch(typeof S=="object"&&S!==null?(S=S.delay,S=typeof S=="number"&&0<S?R+S:R):S=R,Y){case 1:var q=-1;break;case 2:q=250;break;case 5:q=1073741823;break;case 4:q=1e4;break;default:q=5e3}return q=S+q,Y={id:g++,callback:ce,priorityLevel:Y,startTime:S,expirationTime:q,sortIndex:-1},S>R?(Y.sortIndex=S,r(m,Y),i(p)===null&&Y===i(m)&&(N?(P(G),G=-1):N=!0,_e(F,S-R))):(Y.sortIndex=q,r(p,Y),T||x||(T=!0,be(ee))),Y},e.unstable_shouldYield=$,e.unstable_wrapCallback=function(Y){var ce=k;return function(){var S=k;k=ce;try{return Y.apply(this,arguments)}finally{k=S}}}}(oc)),oc}var Gh;function J0(){return Gh||(Gh=1,lc.exports=X0()),lc.exports}/**
|
|
26
|
+
* @license React
|
|
27
|
+
* react-dom.production.min.js
|
|
28
|
+
*
|
|
29
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
30
|
+
*
|
|
31
|
+
* This source code is licensed under the MIT license found in the
|
|
32
|
+
* LICENSE file in the root directory of this source tree.
|
|
33
|
+
*/var Yh;function Z0(){if(Yh)return Jt;Yh=1;var e=Qc(),r=J0();function i(t){for(var n="https://reactjs.org/docs/error-decoder.html?invariant="+t,o=1;o<arguments.length;o++)n+="&args[]="+encodeURIComponent(arguments[o]);return"Minified React error #"+t+"; visit "+n+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var l=new Set,a={};function u(t,n){c(t,n),c(t+"Capture",n)}function c(t,n){for(a[t]=n,t=0;t<n.length;t++)l.add(n[t])}var f=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),p=Object.prototype.hasOwnProperty,m=/^[: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]*$/,g={},y={};function k(t){return p.call(y,t)?!0:p.call(g,t)?!1:m.test(t)?y[t]=!0:(g[t]=!0,!1)}function x(t,n,o,s){if(o!==null&&o.type===0)return!1;switch(typeof n){case"function":case"symbol":return!0;case"boolean":return s?!1:o!==null?!o.acceptsBooleans:(t=t.toLowerCase().slice(0,5),t!=="data-"&&t!=="aria-");default:return!1}}function T(t,n,o,s){if(n===null||typeof n>"u"||x(t,n,o,s))return!0;if(s)return!1;if(o!==null)switch(o.type){case 3:return!n;case 4:return n===!1;case 5:return isNaN(n);case 6:return isNaN(n)||1>n}return!1}function N(t,n,o,s,d,h,w){this.acceptsBooleans=n===2||n===3||n===4,this.attributeName=s,this.attributeNamespace=d,this.mustUseProperty=o,this.propertyName=t,this.type=n,this.sanitizeURL=h,this.removeEmptyString=w}var b={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(t){b[t]=new N(t,0,!1,t,null,!1,!1)}),[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(t){var n=t[0];b[n]=new N(n,1,!1,t[1],null,!1,!1)}),["contentEditable","draggable","spellCheck","value"].forEach(function(t){b[t]=new N(t,2,!1,t.toLowerCase(),null,!1,!1)}),["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(t){b[t]=new N(t,2,!1,t,null,!1,!1)}),"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(t){b[t]=new N(t,3,!1,t.toLowerCase(),null,!1,!1)}),["checked","multiple","muted","selected"].forEach(function(t){b[t]=new N(t,3,!0,t,null,!1,!1)}),["capture","download"].forEach(function(t){b[t]=new N(t,4,!1,t,null,!1,!1)}),["cols","rows","size","span"].forEach(function(t){b[t]=new N(t,6,!1,t,null,!1,!1)}),["rowSpan","start"].forEach(function(t){b[t]=new N(t,5,!1,t.toLowerCase(),null,!1,!1)});var P=/[\-:]([a-z])/g;function z(t){return t[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(t){var n=t.replace(P,z);b[n]=new N(n,1,!1,t,null,!1,!1)}),"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(t){var n=t.replace(P,z);b[n]=new N(n,1,!1,t,"http://www.w3.org/1999/xlink",!1,!1)}),["xml:base","xml:lang","xml:space"].forEach(function(t){var n=t.replace(P,z);b[n]=new N(n,1,!1,t,"http://www.w3.org/XML/1998/namespace",!1,!1)}),["tabIndex","crossOrigin"].forEach(function(t){b[t]=new N(t,1,!1,t.toLowerCase(),null,!1,!1)}),b.xlinkHref=new N("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1),["src","href","action","formAction"].forEach(function(t){b[t]=new N(t,1,!1,t.toLowerCase(),null,!0,!0)});function I(t,n,o,s){var d=b.hasOwnProperty(n)?b[n]:null;(d!==null?d.type!==0:s||!(2<n.length)||n[0]!=="o"&&n[0]!=="O"||n[1]!=="n"&&n[1]!=="N")&&(T(n,o,d,s)&&(o=null),s||d===null?k(n)&&(o===null?t.removeAttribute(n):t.setAttribute(n,""+o)):d.mustUseProperty?t[d.propertyName]=o===null?d.type===3?!1:"":o:(n=d.attributeName,s=d.attributeNamespace,o===null?t.removeAttribute(n):(d=d.type,o=d===3||d===4&&o===!0?"":""+o,s?t.setAttributeNS(s,n,o):t.setAttribute(n,o))))}var F=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,ee=Symbol.for("react.element"),B=Symbol.for("react.portal"),D=Symbol.for("react.fragment"),G=Symbol.for("react.strict_mode"),le=Symbol.for("react.profiler"),re=Symbol.for("react.provider"),$=Symbol.for("react.context"),K=Symbol.for("react.forward_ref"),Se=Symbol.for("react.suspense"),se=Symbol.for("react.suspense_list"),ne=Symbol.for("react.memo"),be=Symbol.for("react.lazy"),_e=Symbol.for("react.offscreen"),Y=Symbol.iterator;function ce(t){return t===null||typeof t!="object"?null:(t=Y&&t[Y]||t["@@iterator"],typeof t=="function"?t:null)}var S=Object.assign,R;function q(t){if(R===void 0)try{throw Error()}catch(o){var n=o.stack.trim().match(/\n( *(at )?)/);R=n&&n[1]||""}return`
|
|
34
|
+
`+R+t}var C=!1;function Ce(t,n){if(!t||C)return"";C=!0;var o=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{if(n)if(n=function(){throw Error()},Object.defineProperty(n.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(n,[])}catch(H){var s=H}Reflect.construct(t,[],n)}else{try{n.call()}catch(H){s=H}t.call(n.prototype)}else{try{throw Error()}catch(H){s=H}t()}}catch(H){if(H&&s&&typeof H.stack=="string"){for(var d=H.stack.split(`
|
|
35
|
+
`),h=s.stack.split(`
|
|
36
|
+
`),w=d.length-1,E=h.length-1;1<=w&&0<=E&&d[w]!==h[E];)E--;for(;1<=w&&0<=E;w--,E--)if(d[w]!==h[E]){if(w!==1||E!==1)do if(w--,E--,0>E||d[w]!==h[E]){var _=`
|
|
37
|
+
`+d[w].replace(" at new "," at ");return t.displayName&&_.includes("<anonymous>")&&(_=_.replace("<anonymous>",t.displayName)),_}while(1<=w&&0<=E);break}}}finally{C=!1,Error.prepareStackTrace=o}return(t=t?t.displayName||t.name:"")?q(t):""}function Ne(t){switch(t.tag){case 5:return q(t.type);case 16:return q("Lazy");case 13:return q("Suspense");case 19:return q("SuspenseList");case 0:case 2:case 15:return t=Ce(t.type,!1),t;case 11:return t=Ce(t.type.render,!1),t;case 1:return t=Ce(t.type,!0),t;default:return""}}function ke(t){if(t==null)return null;if(typeof t=="function")return t.displayName||t.name||null;if(typeof t=="string")return t;switch(t){case D:return"Fragment";case B:return"Portal";case le:return"Profiler";case G:return"StrictMode";case Se:return"Suspense";case se:return"SuspenseList"}if(typeof t=="object")switch(t.$$typeof){case $:return(t.displayName||"Context")+".Consumer";case re:return(t._context.displayName||"Context")+".Provider";case K:var n=t.render;return t=t.displayName,t||(t=n.displayName||n.name||"",t=t!==""?"ForwardRef("+t+")":"ForwardRef"),t;case ne:return n=t.displayName||null,n!==null?n:ke(t.type)||"Memo";case be:n=t._payload,t=t._init;try{return ke(t(n))}catch{}}return null}function Fe(t){var n=t.type;switch(t.tag){case 24:return"Cache";case 9:return(n.displayName||"Context")+".Consumer";case 10:return(n._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return t=n.render,t=t.displayName||t.name||"",n.displayName||(t!==""?"ForwardRef("+t+")":"ForwardRef");case 7:return"Fragment";case 5:return n;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return ke(n);case 8:return n===G?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof n=="function")return n.displayName||n.name||null;if(typeof n=="string")return n}return null}function De(t){switch(typeof t){case"boolean":case"number":case"string":case"undefined":return t;case"object":return t;default:return""}}function qe(t){var n=t.type;return(t=t.nodeName)&&t.toLowerCase()==="input"&&(n==="checkbox"||n==="radio")}function mt(t){var n=qe(t)?"checked":"value",o=Object.getOwnPropertyDescriptor(t.constructor.prototype,n),s=""+t[n];if(!t.hasOwnProperty(n)&&typeof o<"u"&&typeof o.get=="function"&&typeof o.set=="function"){var d=o.get,h=o.set;return Object.defineProperty(t,n,{configurable:!0,get:function(){return d.call(this)},set:function(w){s=""+w,h.call(this,w)}}),Object.defineProperty(t,n,{enumerable:o.enumerable}),{getValue:function(){return s},setValue:function(w){s=""+w},stopTracking:function(){t._valueTracker=null,delete t[n]}}}}function Cn(t){t._valueTracker||(t._valueTracker=mt(t))}function kt(t){if(!t)return!1;var n=t._valueTracker;if(!n)return!0;var o=n.getValue(),s="";return t&&(s=qe(t)?t.checked?"true":"false":t.value),t=s,t!==o?(n.setValue(t),!0):!1}function rn(t){if(t=t||(typeof document<"u"?document:void 0),typeof t>"u")return null;try{return t.activeElement||t.body}catch{return t.body}}function vr(t,n){var o=n.checked;return S({},n,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:o??t._wrapperState.initialChecked})}function li(t,n){var o=n.defaultValue==null?"":n.defaultValue,s=n.checked!=null?n.checked:n.defaultChecked;o=De(n.value!=null?n.value:o),t._wrapperState={initialChecked:s,initialValue:o,controlled:n.type==="checkbox"||n.type==="radio"?n.checked!=null:n.value!=null}}function ln(t,n){n=n.checked,n!=null&&I(t,"checked",n,!1)}function xr(t,n){ln(t,n);var o=De(n.value),s=n.type;if(o!=null)s==="number"?(o===0&&t.value===""||t.value!=o)&&(t.value=""+o):t.value!==""+o&&(t.value=""+o);else if(s==="submit"||s==="reset"){t.removeAttribute("value");return}n.hasOwnProperty("value")?er(t,n.type,o):n.hasOwnProperty("defaultValue")&&er(t,n.type,De(n.defaultValue)),n.checked==null&&n.defaultChecked!=null&&(t.defaultChecked=!!n.defaultChecked)}function zi(t,n,o){if(n.hasOwnProperty("value")||n.hasOwnProperty("defaultValue")){var s=n.type;if(!(s!=="submit"&&s!=="reset"||n.value!==void 0&&n.value!==null))return;n=""+t._wrapperState.initialValue,o||n===t.value||(t.value=n),t.defaultValue=n}o=t.name,o!==""&&(t.name=""),t.defaultChecked=!!t._wrapperState.initialChecked,o!==""&&(t.name=o)}function er(t,n,o){(n!=="number"||rn(t.ownerDocument)!==t)&&(o==null?t.defaultValue=""+t._wrapperState.initialValue:t.defaultValue!==""+o&&(t.defaultValue=""+o))}var An=Array.isArray;function On(t,n,o,s){if(t=t.options,n){n={};for(var d=0;d<o.length;d++)n["$"+o[d]]=!0;for(o=0;o<t.length;o++)d=n.hasOwnProperty("$"+t[o].value),t[o].selected!==d&&(t[o].selected=d),d&&s&&(t[o].defaultSelected=!0)}else{for(o=""+De(o),n=null,d=0;d<t.length;d++){if(t[d].value===o){t[d].selected=!0,s&&(t[d].defaultSelected=!0);return}n!==null||t[d].disabled||(n=t[d])}n!==null&&(n.selected=!0)}}function oi(t,n){if(n.dangerouslySetInnerHTML!=null)throw Error(i(91));return S({},n,{value:void 0,defaultValue:void 0,children:""+t._wrapperState.initialValue})}function Di(t,n){var o=n.value;if(o==null){if(o=n.children,n=n.defaultValue,o!=null){if(n!=null)throw Error(i(92));if(An(o)){if(1<o.length)throw Error(i(93));o=o[0]}n=o}n==null&&(n=""),o=n}t._wrapperState={initialValue:De(o)}}function pn(t,n){var o=De(n.value),s=De(n.defaultValue);o!=null&&(o=""+o,o!==t.value&&(t.value=o),n.defaultValue==null&&t.defaultValue!==o&&(t.defaultValue=o)),s!=null&&(t.defaultValue=""+s)}function Fn(t){var n=t.textContent;n===t._wrapperState.initialValue&&n!==""&&n!==null&&(t.value=n)}function W(t){switch(t){case"svg":return"http://www.w3.org/2000/svg";case"math":return"http://www.w3.org/1998/Math/MathML";default:return"http://www.w3.org/1999/xhtml"}}function ae(t,n){return t==null||t==="http://www.w3.org/1999/xhtml"?W(n):t==="http://www.w3.org/2000/svg"&&n==="foreignObject"?"http://www.w3.org/1999/xhtml":t}var Ee,Re=function(t){return typeof MSApp<"u"&&MSApp.execUnsafeLocalFunction?function(n,o,s,d){MSApp.execUnsafeLocalFunction(function(){return t(n,o,s,d)})}:t}(function(t,n){if(t.namespaceURI!=="http://www.w3.org/2000/svg"||"innerHTML"in t)t.innerHTML=n;else{for(Ee=Ee||document.createElement("div"),Ee.innerHTML="<svg>"+n.valueOf().toString()+"</svg>",n=Ee.firstChild;t.firstChild;)t.removeChild(t.firstChild);for(;n.firstChild;)t.appendChild(n.firstChild)}});function Ve(t,n){if(n){var o=t.firstChild;if(o&&o===t.lastChild&&o.nodeType===3){o.nodeValue=n;return}}t.textContent=n}var gt={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},bn=["Webkit","ms","Moz","O"];Object.keys(gt).forEach(function(t){bn.forEach(function(n){n=n+t.charAt(0).toUpperCase()+t.substring(1),gt[n]=gt[t]})});function xt(t,n,o){return n==null||typeof n=="boolean"||n===""?"":o||typeof n!="number"||n===0||gt.hasOwnProperty(t)&>[t]?(""+n).trim():n+"px"}function Nn(t,n){t=t.style;for(var o in n)if(n.hasOwnProperty(o)){var s=o.indexOf("--")===0,d=xt(o,n[o],s);o==="float"&&(o="cssFloat"),s?t.setProperty(o,d):t[o]=d}}var Un=S({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function St(t,n){if(n){if(Un[t]&&(n.children!=null||n.dangerouslySetInnerHTML!=null))throw Error(i(137,t));if(n.dangerouslySetInnerHTML!=null){if(n.children!=null)throw Error(i(60));if(typeof n.dangerouslySetInnerHTML!="object"||!("__html"in n.dangerouslySetInnerHTML))throw Error(i(61))}if(n.style!=null&&typeof n.style!="object")throw Error(i(62))}}function mn(t,n){if(t.indexOf("-")===-1)return typeof n.is=="string";switch(t){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var At=null;function wr(t){return t=t.target||t.srcElement||window,t.correspondingUseElement&&(t=t.correspondingUseElement),t.nodeType===3?t.parentNode:t}var Ai=null,Bn=null,Hn=null;function Ao(t){if(t=ql(t)){if(typeof Ai!="function")throw Error(i(280));var n=t.stateNode;n&&(n=la(n),Ai(t.stateNode,t.type,n))}}function Nl(t){Bn?Hn?Hn.push(t):Hn=[t]:Bn=t}function Oo(){if(Bn){var t=Bn,n=Hn;if(Hn=Bn=null,Ao(t),n)for(t=0;t<n.length;t++)Ao(n[t])}}function Pl(t,n){return t(n)}function ai(){}var kr=!1;function Fo(t,n,o){if(kr)return t(n,o);kr=!0;try{return Pl(t,n,o)}finally{kr=!1,(Bn!==null||Hn!==null)&&(ai(),Oo())}}function si(t,n){var o=t.stateNode;if(o===null)return null;var s=la(o);if(s===null)return null;o=s[n];e:switch(n){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(s=!s.disabled)||(t=t.type,s=!(t==="button"||t==="input"||t==="select"||t==="textarea")),t=!s;break e;default:t=!1}if(t)return null;if(o&&typeof o!="function")throw Error(i(231,n,typeof o));return o}var j=!1;if(f)try{var A={};Object.defineProperty(A,"passive",{get:function(){j=!0}}),window.addEventListener("test",A,A),window.removeEventListener("test",A,A)}catch{j=!1}function V(t,n,o,s,d,h,w,E,_){var H=Array.prototype.slice.call(arguments,3);try{n.apply(o,H)}catch(Z){this.onError(Z)}}var X=!1,ue=null,we=!1,Te=null,me={onError:function(t){X=!0,ue=t}};function ye(t,n,o,s,d,h,w,E,_){X=!1,ue=null,V.apply(me,arguments)}function fe(t,n,o,s,d,h,w,E,_){if(ye.apply(this,arguments),X){if(X){var H=ue;X=!1,ue=null}else throw Error(i(198));we||(we=!0,Te=H)}}function pe(t){var n=t,o=t;if(t.alternate)for(;n.return;)n=n.return;else{t=n;do n=t,(n.flags&4098)!==0&&(o=n.return),t=n.return;while(t)}return n.tag===3?o:null}function ze(t){if(t.tag===13){var n=t.memoizedState;if(n===null&&(t=t.alternate,t!==null&&(n=t.memoizedState)),n!==null)return n.dehydrated}return null}function He(t){if(pe(t)!==t)throw Error(i(188))}function Nt(t){var n=t.alternate;if(!n){if(n=pe(t),n===null)throw Error(i(188));return n!==t?null:t}for(var o=t,s=n;;){var d=o.return;if(d===null)break;var h=d.alternate;if(h===null){if(s=d.return,s!==null){o=s;continue}break}if(d.child===h.child){for(h=d.child;h;){if(h===o)return He(d),t;if(h===s)return He(d),n;h=h.sibling}throw Error(i(188))}if(o.return!==s.return)o=d,s=h;else{for(var w=!1,E=d.child;E;){if(E===o){w=!0,o=d,s=h;break}if(E===s){w=!0,s=d,o=h;break}E=E.sibling}if(!w){for(E=h.child;E;){if(E===o){w=!0,o=h,s=d;break}if(E===s){w=!0,s=h,o=d;break}E=E.sibling}if(!w)throw Error(i(189))}}if(o.alternate!==s)throw Error(i(190))}if(o.tag!==3)throw Error(i(188));return o.stateNode.current===o?t:n}function Ze(t){return t=Nt(t),t!==null?Qe(t):null}function Qe(t){if(t.tag===5||t.tag===6)return t;for(t=t.child;t!==null;){var n=Qe(t);if(n!==null)return n;t=t.sibling}return null}var at=r.unstable_scheduleCallback,tr=r.unstable_cancelCallback,ui=r.unstable_shouldYield,Pn=r.unstable_requestPaint,Ge=r.unstable_now,jl=r.unstable_getCurrentPriorityLevel,nr=r.unstable_ImmediatePriority,Vn=r.unstable_UserBlockingPriority,rr=r.unstable_NormalPriority,Oi=r.unstable_LowPriority,$e=r.unstable_IdlePriority,nt=null,It=null;function ci(t){if(It&&typeof It.onCommitFiberRoot=="function")try{It.onCommitFiberRoot(nt,t,void 0,(t.current.flags&128)===128)}catch{}}var Ye=Math.clz32?Math.clz32:ks,Sr=Math.log,Uo=Math.LN2;function ks(t){return t>>>=0,t===0?32:31-(Sr(t)/Uo|0)|0}var Bo=64,Ho=4194304;function _l(t){switch(t&-t){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64: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&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return t&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return t}}function Vo(t,n){var o=t.pendingLanes;if(o===0)return 0;var s=0,d=t.suspendedLanes,h=t.pingedLanes,w=o&268435455;if(w!==0){var E=w&~d;E!==0?s=_l(E):(h&=w,h!==0&&(s=_l(h)))}else w=o&~d,w!==0?s=_l(w):h!==0&&(s=_l(h));if(s===0)return 0;if(n!==0&&n!==s&&(n&d)===0&&(d=s&-s,h=n&-n,d>=h||d===16&&(h&4194240)!==0))return n;if((s&4)!==0&&(s|=o&16),n=t.entangledLanes,n!==0)for(t=t.entanglements,n&=s;0<n;)o=31-Ye(n),d=1<<o,s|=t[o],n&=~d;return s}function cy(t,n){switch(t){case 1:case 2:case 4:return n+250;case 8:case 16:case 32:case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return n+5e3;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return-1;case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function dy(t,n){for(var o=t.suspendedLanes,s=t.pingedLanes,d=t.expirationTimes,h=t.pendingLanes;0<h;){var w=31-Ye(h),E=1<<w,_=d[w];_===-1?((E&o)===0||(E&s)!==0)&&(d[w]=cy(E,n)):_<=n&&(t.expiredLanes|=E),h&=~E}}function Ss(t){return t=t.pendingLanes&-1073741825,t!==0?t:t&1073741824?1073741824:0}function xd(){var t=Bo;return Bo<<=1,(Bo&4194240)===0&&(Bo=64),t}function Es(t){for(var n=[],o=0;31>o;o++)n.push(t);return n}function Tl(t,n,o){t.pendingLanes|=n,n!==536870912&&(t.suspendedLanes=0,t.pingedLanes=0),t=t.eventTimes,n=31-Ye(n),t[n]=o}function fy(t,n){var o=t.pendingLanes&~n;t.pendingLanes=n,t.suspendedLanes=0,t.pingedLanes=0,t.expiredLanes&=n,t.mutableReadLanes&=n,t.entangledLanes&=n,n=t.entanglements;var s=t.eventTimes;for(t=t.expirationTimes;0<o;){var d=31-Ye(o),h=1<<d;n[d]=0,s[d]=-1,t[d]=-1,o&=~h}}function Cs(t,n){var o=t.entangledLanes|=n;for(t=t.entanglements;o;){var s=31-Ye(o),d=1<<s;d&n|t[s]&n&&(t[s]|=n),o&=~d}}var et=0;function wd(t){return t&=-t,1<t?4<t?(t&268435455)!==0?16:536870912:4:1}var kd,bs,Sd,Ed,Cd,Ns=!1,$o=[],Er=null,Cr=null,br=null,Rl=new Map,Ll=new Map,Nr=[],hy="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset submit".split(" ");function bd(t,n){switch(t){case"focusin":case"focusout":Er=null;break;case"dragenter":case"dragleave":Cr=null;break;case"mouseover":case"mouseout":br=null;break;case"pointerover":case"pointerout":Rl.delete(n.pointerId);break;case"gotpointercapture":case"lostpointercapture":Ll.delete(n.pointerId)}}function Il(t,n,o,s,d,h){return t===null||t.nativeEvent!==h?(t={blockedOn:n,domEventName:o,eventSystemFlags:s,nativeEvent:h,targetContainers:[d]},n!==null&&(n=ql(n),n!==null&&bs(n)),t):(t.eventSystemFlags|=s,n=t.targetContainers,d!==null&&n.indexOf(d)===-1&&n.push(d),t)}function py(t,n,o,s,d){switch(n){case"focusin":return Er=Il(Er,t,n,o,s,d),!0;case"dragenter":return Cr=Il(Cr,t,n,o,s,d),!0;case"mouseover":return br=Il(br,t,n,o,s,d),!0;case"pointerover":var h=d.pointerId;return Rl.set(h,Il(Rl.get(h)||null,t,n,o,s,d)),!0;case"gotpointercapture":return h=d.pointerId,Ll.set(h,Il(Ll.get(h)||null,t,n,o,s,d)),!0}return!1}function Nd(t){var n=di(t.target);if(n!==null){var o=pe(n);if(o!==null){if(n=o.tag,n===13){if(n=ze(o),n!==null){t.blockedOn=n,Cd(t.priority,function(){Sd(o)});return}}else if(n===3&&o.stateNode.current.memoizedState.isDehydrated){t.blockedOn=o.tag===3?o.stateNode.containerInfo:null;return}}}t.blockedOn=null}function Wo(t){if(t.blockedOn!==null)return!1;for(var n=t.targetContainers;0<n.length;){var o=js(t.domEventName,t.eventSystemFlags,n[0],t.nativeEvent);if(o===null){o=t.nativeEvent;var s=new o.constructor(o.type,o);At=s,o.target.dispatchEvent(s),At=null}else return n=ql(o),n!==null&&bs(n),t.blockedOn=o,!1;n.shift()}return!0}function Pd(t,n,o){Wo(t)&&o.delete(n)}function my(){Ns=!1,Er!==null&&Wo(Er)&&(Er=null),Cr!==null&&Wo(Cr)&&(Cr=null),br!==null&&Wo(br)&&(br=null),Rl.forEach(Pd),Ll.forEach(Pd)}function Ml(t,n){t.blockedOn===n&&(t.blockedOn=null,Ns||(Ns=!0,r.unstable_scheduleCallback(r.unstable_NormalPriority,my)))}function zl(t){function n(d){return Ml(d,t)}if(0<$o.length){Ml($o[0],t);for(var o=1;o<$o.length;o++){var s=$o[o];s.blockedOn===t&&(s.blockedOn=null)}}for(Er!==null&&Ml(Er,t),Cr!==null&&Ml(Cr,t),br!==null&&Ml(br,t),Rl.forEach(n),Ll.forEach(n),o=0;o<Nr.length;o++)s=Nr[o],s.blockedOn===t&&(s.blockedOn=null);for(;0<Nr.length&&(o=Nr[0],o.blockedOn===null);)Nd(o),o.blockedOn===null&&Nr.shift()}var Fi=F.ReactCurrentBatchConfig,Qo=!0;function gy(t,n,o,s){var d=et,h=Fi.transition;Fi.transition=null;try{et=1,Ps(t,n,o,s)}finally{et=d,Fi.transition=h}}function yy(t,n,o,s){var d=et,h=Fi.transition;Fi.transition=null;try{et=4,Ps(t,n,o,s)}finally{et=d,Fi.transition=h}}function Ps(t,n,o,s){if(Qo){var d=js(t,n,o,s);if(d===null)Ws(t,n,s,qo,o),bd(t,s);else if(py(d,t,n,o,s))s.stopPropagation();else if(bd(t,s),n&4&&-1<hy.indexOf(t)){for(;d!==null;){var h=ql(d);if(h!==null&&kd(h),h=js(t,n,o,s),h===null&&Ws(t,n,s,qo,o),h===d)break;d=h}d!==null&&s.stopPropagation()}else Ws(t,n,s,null,o)}}var qo=null;function js(t,n,o,s){if(qo=null,t=wr(s),t=di(t),t!==null)if(n=pe(t),n===null)t=null;else if(o=n.tag,o===13){if(t=ze(n),t!==null)return t;t=null}else if(o===3){if(n.stateNode.current.memoizedState.isDehydrated)return n.tag===3?n.stateNode.containerInfo:null;t=null}else n!==t&&(t=null);return qo=t,null}function jd(t){switch(t){case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"resize":case"seeked":case"submit":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 1;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"toggle":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 4;case"message":switch(jl()){case nr:return 1;case Vn:return 4;case rr:case Oi:return 16;case $e:return 536870912;default:return 16}default:return 16}}var Pr=null,_s=null,Ko=null;function _d(){if(Ko)return Ko;var t,n=_s,o=n.length,s,d="value"in Pr?Pr.value:Pr.textContent,h=d.length;for(t=0;t<o&&n[t]===d[t];t++);var w=o-t;for(s=1;s<=w&&n[o-s]===d[h-s];s++);return Ko=d.slice(t,1<s?1-s:void 0)}function Go(t){var n=t.keyCode;return"charCode"in t?(t=t.charCode,t===0&&n===13&&(t=13)):t=n,t===10&&(t=13),32<=t||t===13?t:0}function Yo(){return!0}function Td(){return!1}function on(t){function n(o,s,d,h,w){this._reactName=o,this._targetInst=d,this.type=s,this.nativeEvent=h,this.target=w,this.currentTarget=null;for(var E in t)t.hasOwnProperty(E)&&(o=t[E],this[E]=o?o(h):h[E]);return this.isDefaultPrevented=(h.defaultPrevented!=null?h.defaultPrevented:h.returnValue===!1)?Yo:Td,this.isPropagationStopped=Td,this}return S(n.prototype,{preventDefault:function(){this.defaultPrevented=!0;var o=this.nativeEvent;o&&(o.preventDefault?o.preventDefault():typeof o.returnValue!="unknown"&&(o.returnValue=!1),this.isDefaultPrevented=Yo)},stopPropagation:function(){var o=this.nativeEvent;o&&(o.stopPropagation?o.stopPropagation():typeof o.cancelBubble!="unknown"&&(o.cancelBubble=!0),this.isPropagationStopped=Yo)},persist:function(){},isPersistent:Yo}),n}var Ui={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(t){return t.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},Ts=on(Ui),Dl=S({},Ui,{view:0,detail:0}),vy=on(Dl),Rs,Ls,Al,Xo=S({},Dl,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:Ms,button:0,buttons:0,relatedTarget:function(t){return t.relatedTarget===void 0?t.fromElement===t.srcElement?t.toElement:t.fromElement:t.relatedTarget},movementX:function(t){return"movementX"in t?t.movementX:(t!==Al&&(Al&&t.type==="mousemove"?(Rs=t.screenX-Al.screenX,Ls=t.screenY-Al.screenY):Ls=Rs=0,Al=t),Rs)},movementY:function(t){return"movementY"in t?t.movementY:Ls}}),Rd=on(Xo),xy=S({},Xo,{dataTransfer:0}),wy=on(xy),ky=S({},Dl,{relatedTarget:0}),Is=on(ky),Sy=S({},Ui,{animationName:0,elapsedTime:0,pseudoElement:0}),Ey=on(Sy),Cy=S({},Ui,{clipboardData:function(t){return"clipboardData"in t?t.clipboardData:window.clipboardData}}),by=on(Cy),Ny=S({},Ui,{data:0}),Ld=on(Ny),Py={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},jy={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"},_y={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function Ty(t){var n=this.nativeEvent;return n.getModifierState?n.getModifierState(t):(t=_y[t])?!!n[t]:!1}function Ms(){return Ty}var Ry=S({},Dl,{key:function(t){if(t.key){var n=Py[t.key]||t.key;if(n!=="Unidentified")return n}return t.type==="keypress"?(t=Go(t),t===13?"Enter":String.fromCharCode(t)):t.type==="keydown"||t.type==="keyup"?jy[t.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:Ms,charCode:function(t){return t.type==="keypress"?Go(t):0},keyCode:function(t){return t.type==="keydown"||t.type==="keyup"?t.keyCode:0},which:function(t){return t.type==="keypress"?Go(t):t.type==="keydown"||t.type==="keyup"?t.keyCode:0}}),Ly=on(Ry),Iy=S({},Xo,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),Id=on(Iy),My=S({},Dl,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:Ms}),zy=on(My),Dy=S({},Ui,{propertyName:0,elapsedTime:0,pseudoElement:0}),Ay=on(Dy),Oy=S({},Xo,{deltaX:function(t){return"deltaX"in t?t.deltaX:"wheelDeltaX"in t?-t.wheelDeltaX:0},deltaY:function(t){return"deltaY"in t?t.deltaY:"wheelDeltaY"in t?-t.wheelDeltaY:"wheelDelta"in t?-t.wheelDelta:0},deltaZ:0,deltaMode:0}),Fy=on(Oy),Uy=[9,13,27,32],zs=f&&"CompositionEvent"in window,Ol=null;f&&"documentMode"in document&&(Ol=document.documentMode);var By=f&&"TextEvent"in window&&!Ol,Md=f&&(!zs||Ol&&8<Ol&&11>=Ol),zd=" ",Dd=!1;function Ad(t,n){switch(t){case"keyup":return Uy.indexOf(n.keyCode)!==-1;case"keydown":return n.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function Od(t){return t=t.detail,typeof t=="object"&&"data"in t?t.data:null}var Bi=!1;function Hy(t,n){switch(t){case"compositionend":return Od(n);case"keypress":return n.which!==32?null:(Dd=!0,zd);case"textInput":return t=n.data,t===zd&&Dd?null:t;default:return null}}function Vy(t,n){if(Bi)return t==="compositionend"||!zs&&Ad(t,n)?(t=_d(),Ko=_s=Pr=null,Bi=!1,t):null;switch(t){case"paste":return null;case"keypress":if(!(n.ctrlKey||n.altKey||n.metaKey)||n.ctrlKey&&n.altKey){if(n.char&&1<n.char.length)return n.char;if(n.which)return String.fromCharCode(n.which)}return null;case"compositionend":return Md&&n.locale!=="ko"?null:n.data;default:return null}}var $y={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 Fd(t){var n=t&&t.nodeName&&t.nodeName.toLowerCase();return n==="input"?!!$y[t.type]:n==="textarea"}function Ud(t,n,o,s){Nl(s),n=na(n,"onChange"),0<n.length&&(o=new Ts("onChange","change",null,o,s),t.push({event:o,listeners:n}))}var Fl=null,Ul=null;function Wy(t){lf(t,0)}function Jo(t){var n=Qi(t);if(kt(n))return t}function Qy(t,n){if(t==="change")return n}var Bd=!1;if(f){var Ds;if(f){var As="oninput"in document;if(!As){var Hd=document.createElement("div");Hd.setAttribute("oninput","return;"),As=typeof Hd.oninput=="function"}Ds=As}else Ds=!1;Bd=Ds&&(!document.documentMode||9<document.documentMode)}function Vd(){Fl&&(Fl.detachEvent("onpropertychange",$d),Ul=Fl=null)}function $d(t){if(t.propertyName==="value"&&Jo(Ul)){var n=[];Ud(n,Ul,t,wr(t)),Fo(Wy,n)}}function qy(t,n,o){t==="focusin"?(Vd(),Fl=n,Ul=o,Fl.attachEvent("onpropertychange",$d)):t==="focusout"&&Vd()}function Ky(t){if(t==="selectionchange"||t==="keyup"||t==="keydown")return Jo(Ul)}function Gy(t,n){if(t==="click")return Jo(n)}function Yy(t,n){if(t==="input"||t==="change")return Jo(n)}function Xy(t,n){return t===n&&(t!==0||1/t===1/n)||t!==t&&n!==n}var jn=typeof Object.is=="function"?Object.is:Xy;function Bl(t,n){if(jn(t,n))return!0;if(typeof t!="object"||t===null||typeof n!="object"||n===null)return!1;var o=Object.keys(t),s=Object.keys(n);if(o.length!==s.length)return!1;for(s=0;s<o.length;s++){var d=o[s];if(!p.call(n,d)||!jn(t[d],n[d]))return!1}return!0}function Wd(t){for(;t&&t.firstChild;)t=t.firstChild;return t}function Qd(t,n){var o=Wd(t);t=0;for(var s;o;){if(o.nodeType===3){if(s=t+o.textContent.length,t<=n&&s>=n)return{node:o,offset:n-t};t=s}e:{for(;o;){if(o.nextSibling){o=o.nextSibling;break e}o=o.parentNode}o=void 0}o=Wd(o)}}function qd(t,n){return t&&n?t===n?!0:t&&t.nodeType===3?!1:n&&n.nodeType===3?qd(t,n.parentNode):"contains"in t?t.contains(n):t.compareDocumentPosition?!!(t.compareDocumentPosition(n)&16):!1:!1}function Kd(){for(var t=window,n=rn();n instanceof t.HTMLIFrameElement;){try{var o=typeof n.contentWindow.location.href=="string"}catch{o=!1}if(o)t=n.contentWindow;else break;n=rn(t.document)}return n}function Os(t){var n=t&&t.nodeName&&t.nodeName.toLowerCase();return n&&(n==="input"&&(t.type==="text"||t.type==="search"||t.type==="tel"||t.type==="url"||t.type==="password")||n==="textarea"||t.contentEditable==="true")}function Jy(t){var n=Kd(),o=t.focusedElem,s=t.selectionRange;if(n!==o&&o&&o.ownerDocument&&qd(o.ownerDocument.documentElement,o)){if(s!==null&&Os(o)){if(n=s.start,t=s.end,t===void 0&&(t=n),"selectionStart"in o)o.selectionStart=n,o.selectionEnd=Math.min(t,o.value.length);else if(t=(n=o.ownerDocument||document)&&n.defaultView||window,t.getSelection){t=t.getSelection();var d=o.textContent.length,h=Math.min(s.start,d);s=s.end===void 0?h:Math.min(s.end,d),!t.extend&&h>s&&(d=s,s=h,h=d),d=Qd(o,h);var w=Qd(o,s);d&&w&&(t.rangeCount!==1||t.anchorNode!==d.node||t.anchorOffset!==d.offset||t.focusNode!==w.node||t.focusOffset!==w.offset)&&(n=n.createRange(),n.setStart(d.node,d.offset),t.removeAllRanges(),h>s?(t.addRange(n),t.extend(w.node,w.offset)):(n.setEnd(w.node,w.offset),t.addRange(n)))}}for(n=[],t=o;t=t.parentNode;)t.nodeType===1&&n.push({element:t,left:t.scrollLeft,top:t.scrollTop});for(typeof o.focus=="function"&&o.focus(),o=0;o<n.length;o++)t=n[o],t.element.scrollLeft=t.left,t.element.scrollTop=t.top}}var Zy=f&&"documentMode"in document&&11>=document.documentMode,Hi=null,Fs=null,Hl=null,Us=!1;function Gd(t,n,o){var s=o.window===o?o.document:o.nodeType===9?o:o.ownerDocument;Us||Hi==null||Hi!==rn(s)||(s=Hi,"selectionStart"in s&&Os(s)?s={start:s.selectionStart,end:s.selectionEnd}:(s=(s.ownerDocument&&s.ownerDocument.defaultView||window).getSelection(),s={anchorNode:s.anchorNode,anchorOffset:s.anchorOffset,focusNode:s.focusNode,focusOffset:s.focusOffset}),Hl&&Bl(Hl,s)||(Hl=s,s=na(Fs,"onSelect"),0<s.length&&(n=new Ts("onSelect","select",null,n,o),t.push({event:n,listeners:s}),n.target=Hi)))}function Zo(t,n){var o={};return o[t.toLowerCase()]=n.toLowerCase(),o["Webkit"+t]="webkit"+n,o["Moz"+t]="moz"+n,o}var Vi={animationend:Zo("Animation","AnimationEnd"),animationiteration:Zo("Animation","AnimationIteration"),animationstart:Zo("Animation","AnimationStart"),transitionend:Zo("Transition","TransitionEnd")},Bs={},Yd={};f&&(Yd=document.createElement("div").style,"AnimationEvent"in window||(delete Vi.animationend.animation,delete Vi.animationiteration.animation,delete Vi.animationstart.animation),"TransitionEvent"in window||delete Vi.transitionend.transition);function ea(t){if(Bs[t])return Bs[t];if(!Vi[t])return t;var n=Vi[t],o;for(o in n)if(n.hasOwnProperty(o)&&o in Yd)return Bs[t]=n[o];return t}var Xd=ea("animationend"),Jd=ea("animationiteration"),Zd=ea("animationstart"),ef=ea("transitionend"),tf=new Map,nf="abort auxClick cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel".split(" ");function jr(t,n){tf.set(t,n),u(n,[t])}for(var Hs=0;Hs<nf.length;Hs++){var Vs=nf[Hs],e0=Vs.toLowerCase(),t0=Vs[0].toUpperCase()+Vs.slice(1);jr(e0,"on"+t0)}jr(Xd,"onAnimationEnd"),jr(Jd,"onAnimationIteration"),jr(Zd,"onAnimationStart"),jr("dblclick","onDoubleClick"),jr("focusin","onFocus"),jr("focusout","onBlur"),jr(ef,"onTransitionEnd"),c("onMouseEnter",["mouseout","mouseover"]),c("onMouseLeave",["mouseout","mouseover"]),c("onPointerEnter",["pointerout","pointerover"]),c("onPointerLeave",["pointerout","pointerover"]),u("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),u("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),u("onBeforeInput",["compositionend","keypress","textInput","paste"]),u("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),u("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),u("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Vl="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(" "),n0=new Set("cancel close invalid load scroll toggle".split(" ").concat(Vl));function rf(t,n,o){var s=t.type||"unknown-event";t.currentTarget=o,fe(s,n,void 0,t),t.currentTarget=null}function lf(t,n){n=(n&4)!==0;for(var o=0;o<t.length;o++){var s=t[o],d=s.event;s=s.listeners;e:{var h=void 0;if(n)for(var w=s.length-1;0<=w;w--){var E=s[w],_=E.instance,H=E.currentTarget;if(E=E.listener,_!==h&&d.isPropagationStopped())break e;rf(d,E,H),h=_}else for(w=0;w<s.length;w++){if(E=s[w],_=E.instance,H=E.currentTarget,E=E.listener,_!==h&&d.isPropagationStopped())break e;rf(d,E,H),h=_}}}if(we)throw t=Te,we=!1,Te=null,t}function st(t,n){var o=n[Xs];o===void 0&&(o=n[Xs]=new Set);var s=t+"__bubble";o.has(s)||(of(n,t,2,!1),o.add(s))}function $s(t,n,o){var s=0;n&&(s|=4),of(o,t,s,n)}var ta="_reactListening"+Math.random().toString(36).slice(2);function $l(t){if(!t[ta]){t[ta]=!0,l.forEach(function(o){o!=="selectionchange"&&(n0.has(o)||$s(o,!1,t),$s(o,!0,t))});var n=t.nodeType===9?t:t.ownerDocument;n===null||n[ta]||(n[ta]=!0,$s("selectionchange",!1,n))}}function of(t,n,o,s){switch(jd(n)){case 1:var d=gy;break;case 4:d=yy;break;default:d=Ps}o=d.bind(null,n,o,t),d=void 0,!j||n!=="touchstart"&&n!=="touchmove"&&n!=="wheel"||(d=!0),s?d!==void 0?t.addEventListener(n,o,{capture:!0,passive:d}):t.addEventListener(n,o,!0):d!==void 0?t.addEventListener(n,o,{passive:d}):t.addEventListener(n,o,!1)}function Ws(t,n,o,s,d){var h=s;if((n&1)===0&&(n&2)===0&&s!==null)e:for(;;){if(s===null)return;var w=s.tag;if(w===3||w===4){var E=s.stateNode.containerInfo;if(E===d||E.nodeType===8&&E.parentNode===d)break;if(w===4)for(w=s.return;w!==null;){var _=w.tag;if((_===3||_===4)&&(_=w.stateNode.containerInfo,_===d||_.nodeType===8&&_.parentNode===d))return;w=w.return}for(;E!==null;){if(w=di(E),w===null)return;if(_=w.tag,_===5||_===6){s=h=w;continue e}E=E.parentNode}}s=s.return}Fo(function(){var H=h,Z=wr(o),te=[];e:{var J=tf.get(t);if(J!==void 0){var de=Ts,ge=t;switch(t){case"keypress":if(Go(o)===0)break e;case"keydown":case"keyup":de=Ly;break;case"focusin":ge="focus",de=Is;break;case"focusout":ge="blur",de=Is;break;case"beforeblur":case"afterblur":de=Is;break;case"click":if(o.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":de=Rd;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":de=wy;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":de=zy;break;case Xd:case Jd:case Zd:de=Ey;break;case ef:de=Ay;break;case"scroll":de=vy;break;case"wheel":de=Fy;break;case"copy":case"cut":case"paste":de=by;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":de=Id}var ve=(n&4)!==0,wt=!ve&&t==="scroll",O=ve?J!==null?J+"Capture":null:J;ve=[];for(var L=H,U;L!==null;){U=L;var oe=U.stateNode;if(U.tag===5&&oe!==null&&(U=oe,O!==null&&(oe=si(L,O),oe!=null&&ve.push(Wl(L,oe,U)))),wt)break;L=L.return}0<ve.length&&(J=new de(J,ge,null,o,Z),te.push({event:J,listeners:ve}))}}if((n&7)===0){e:{if(J=t==="mouseover"||t==="pointerover",de=t==="mouseout"||t==="pointerout",J&&o!==At&&(ge=o.relatedTarget||o.fromElement)&&(di(ge)||ge[ir]))break e;if((de||J)&&(J=Z.window===Z?Z:(J=Z.ownerDocument)?J.defaultView||J.parentWindow:window,de?(ge=o.relatedTarget||o.toElement,de=H,ge=ge?di(ge):null,ge!==null&&(wt=pe(ge),ge!==wt||ge.tag!==5&&ge.tag!==6)&&(ge=null)):(de=null,ge=H),de!==ge)){if(ve=Rd,oe="onMouseLeave",O="onMouseEnter",L="mouse",(t==="pointerout"||t==="pointerover")&&(ve=Id,oe="onPointerLeave",O="onPointerEnter",L="pointer"),wt=de==null?J:Qi(de),U=ge==null?J:Qi(ge),J=new ve(oe,L+"leave",de,o,Z),J.target=wt,J.relatedTarget=U,oe=null,di(Z)===H&&(ve=new ve(O,L+"enter",ge,o,Z),ve.target=U,ve.relatedTarget=wt,oe=ve),wt=oe,de&&ge)t:{for(ve=de,O=ge,L=0,U=ve;U;U=$i(U))L++;for(U=0,oe=O;oe;oe=$i(oe))U++;for(;0<L-U;)ve=$i(ve),L--;for(;0<U-L;)O=$i(O),U--;for(;L--;){if(ve===O||O!==null&&ve===O.alternate)break t;ve=$i(ve),O=$i(O)}ve=null}else ve=null;de!==null&&af(te,J,de,ve,!1),ge!==null&&wt!==null&&af(te,wt,ge,ve,!0)}}e:{if(J=H?Qi(H):window,de=J.nodeName&&J.nodeName.toLowerCase(),de==="select"||de==="input"&&J.type==="file")var xe=Qy;else if(Fd(J))if(Bd)xe=Yy;else{xe=Ky;var Pe=qy}else(de=J.nodeName)&&de.toLowerCase()==="input"&&(J.type==="checkbox"||J.type==="radio")&&(xe=Gy);if(xe&&(xe=xe(t,H))){Ud(te,xe,o,Z);break e}Pe&&Pe(t,J,H),t==="focusout"&&(Pe=J._wrapperState)&&Pe.controlled&&J.type==="number"&&er(J,"number",J.value)}switch(Pe=H?Qi(H):window,t){case"focusin":(Fd(Pe)||Pe.contentEditable==="true")&&(Hi=Pe,Fs=H,Hl=null);break;case"focusout":Hl=Fs=Hi=null;break;case"mousedown":Us=!0;break;case"contextmenu":case"mouseup":case"dragend":Us=!1,Gd(te,o,Z);break;case"selectionchange":if(Zy)break;case"keydown":case"keyup":Gd(te,o,Z)}var je;if(zs)e:{switch(t){case"compositionstart":var Le="onCompositionStart";break e;case"compositionend":Le="onCompositionEnd";break e;case"compositionupdate":Le="onCompositionUpdate";break e}Le=void 0}else Bi?Ad(t,o)&&(Le="onCompositionEnd"):t==="keydown"&&o.keyCode===229&&(Le="onCompositionStart");Le&&(Md&&o.locale!=="ko"&&(Bi||Le!=="onCompositionStart"?Le==="onCompositionEnd"&&Bi&&(je=_d()):(Pr=Z,_s="value"in Pr?Pr.value:Pr.textContent,Bi=!0)),Pe=na(H,Le),0<Pe.length&&(Le=new Ld(Le,t,null,o,Z),te.push({event:Le,listeners:Pe}),je?Le.data=je:(je=Od(o),je!==null&&(Le.data=je)))),(je=By?Hy(t,o):Vy(t,o))&&(H=na(H,"onBeforeInput"),0<H.length&&(Z=new Ld("onBeforeInput","beforeinput",null,o,Z),te.push({event:Z,listeners:H}),Z.data=je))}lf(te,n)})}function Wl(t,n,o){return{instance:t,listener:n,currentTarget:o}}function na(t,n){for(var o=n+"Capture",s=[];t!==null;){var d=t,h=d.stateNode;d.tag===5&&h!==null&&(d=h,h=si(t,o),h!=null&&s.unshift(Wl(t,h,d)),h=si(t,n),h!=null&&s.push(Wl(t,h,d))),t=t.return}return s}function $i(t){if(t===null)return null;do t=t.return;while(t&&t.tag!==5);return t||null}function af(t,n,o,s,d){for(var h=n._reactName,w=[];o!==null&&o!==s;){var E=o,_=E.alternate,H=E.stateNode;if(_!==null&&_===s)break;E.tag===5&&H!==null&&(E=H,d?(_=si(o,h),_!=null&&w.unshift(Wl(o,_,E))):d||(_=si(o,h),_!=null&&w.push(Wl(o,_,E)))),o=o.return}w.length!==0&&t.push({event:n,listeners:w})}var r0=/\r\n?/g,i0=/\u0000|\uFFFD/g;function sf(t){return(typeof t=="string"?t:""+t).replace(r0,`
|
|
38
|
+
`).replace(i0,"")}function ra(t,n,o){if(n=sf(n),sf(t)!==n&&o)throw Error(i(425))}function ia(){}var Qs=null,qs=null;function Ks(t,n){return t==="textarea"||t==="noscript"||typeof n.children=="string"||typeof n.children=="number"||typeof n.dangerouslySetInnerHTML=="object"&&n.dangerouslySetInnerHTML!==null&&n.dangerouslySetInnerHTML.__html!=null}var Gs=typeof setTimeout=="function"?setTimeout:void 0,l0=typeof clearTimeout=="function"?clearTimeout:void 0,uf=typeof Promise=="function"?Promise:void 0,o0=typeof queueMicrotask=="function"?queueMicrotask:typeof uf<"u"?function(t){return uf.resolve(null).then(t).catch(a0)}:Gs;function a0(t){setTimeout(function(){throw t})}function Ys(t,n){var o=n,s=0;do{var d=o.nextSibling;if(t.removeChild(o),d&&d.nodeType===8)if(o=d.data,o==="/$"){if(s===0){t.removeChild(d),zl(n);return}s--}else o!=="$"&&o!=="$?"&&o!=="$!"||s++;o=d}while(o);zl(n)}function _r(t){for(;t!=null;t=t.nextSibling){var n=t.nodeType;if(n===1||n===3)break;if(n===8){if(n=t.data,n==="$"||n==="$!"||n==="$?")break;if(n==="/$")return null}}return t}function cf(t){t=t.previousSibling;for(var n=0;t;){if(t.nodeType===8){var o=t.data;if(o==="$"||o==="$!"||o==="$?"){if(n===0)return t;n--}else o==="/$"&&n++}t=t.previousSibling}return null}var Wi=Math.random().toString(36).slice(2),$n="__reactFiber$"+Wi,Ql="__reactProps$"+Wi,ir="__reactContainer$"+Wi,Xs="__reactEvents$"+Wi,s0="__reactListeners$"+Wi,u0="__reactHandles$"+Wi;function di(t){var n=t[$n];if(n)return n;for(var o=t.parentNode;o;){if(n=o[ir]||o[$n]){if(o=n.alternate,n.child!==null||o!==null&&o.child!==null)for(t=cf(t);t!==null;){if(o=t[$n])return o;t=cf(t)}return n}t=o,o=t.parentNode}return null}function ql(t){return t=t[$n]||t[ir],!t||t.tag!==5&&t.tag!==6&&t.tag!==13&&t.tag!==3?null:t}function Qi(t){if(t.tag===5||t.tag===6)return t.stateNode;throw Error(i(33))}function la(t){return t[Ql]||null}var Js=[],qi=-1;function Tr(t){return{current:t}}function ut(t){0>qi||(t.current=Js[qi],Js[qi]=null,qi--)}function it(t,n){qi++,Js[qi]=t.current,t.current=n}var Rr={},Ot=Tr(Rr),qt=Tr(!1),fi=Rr;function Ki(t,n){var o=t.type.contextTypes;if(!o)return Rr;var s=t.stateNode;if(s&&s.__reactInternalMemoizedUnmaskedChildContext===n)return s.__reactInternalMemoizedMaskedChildContext;var d={},h;for(h in o)d[h]=n[h];return s&&(t=t.stateNode,t.__reactInternalMemoizedUnmaskedChildContext=n,t.__reactInternalMemoizedMaskedChildContext=d),d}function Kt(t){return t=t.childContextTypes,t!=null}function oa(){ut(qt),ut(Ot)}function df(t,n,o){if(Ot.current!==Rr)throw Error(i(168));it(Ot,n),it(qt,o)}function ff(t,n,o){var s=t.stateNode;if(n=n.childContextTypes,typeof s.getChildContext!="function")return o;s=s.getChildContext();for(var d in s)if(!(d in n))throw Error(i(108,Fe(t)||"Unknown",d));return S({},o,s)}function aa(t){return t=(t=t.stateNode)&&t.__reactInternalMemoizedMergedChildContext||Rr,fi=Ot.current,it(Ot,t),it(qt,qt.current),!0}function hf(t,n,o){var s=t.stateNode;if(!s)throw Error(i(169));o?(t=ff(t,n,fi),s.__reactInternalMemoizedMergedChildContext=t,ut(qt),ut(Ot),it(Ot,t)):ut(qt),it(qt,o)}var lr=null,sa=!1,Zs=!1;function pf(t){lr===null?lr=[t]:lr.push(t)}function c0(t){sa=!0,pf(t)}function Lr(){if(!Zs&&lr!==null){Zs=!0;var t=0,n=et;try{var o=lr;for(et=1;t<o.length;t++){var s=o[t];do s=s(!0);while(s!==null)}lr=null,sa=!1}catch(d){throw lr!==null&&(lr=lr.slice(t+1)),at(nr,Lr),d}finally{et=n,Zs=!1}}return null}var Gi=[],Yi=0,ua=null,ca=0,gn=[],yn=0,hi=null,or=1,ar="";function pi(t,n){Gi[Yi++]=ca,Gi[Yi++]=ua,ua=t,ca=n}function mf(t,n,o){gn[yn++]=or,gn[yn++]=ar,gn[yn++]=hi,hi=t;var s=or;t=ar;var d=32-Ye(s)-1;s&=~(1<<d),o+=1;var h=32-Ye(n)+d;if(30<h){var w=d-d%5;h=(s&(1<<w)-1).toString(32),s>>=w,d-=w,or=1<<32-Ye(n)+d|o<<d|s,ar=h+t}else or=1<<h|o<<d|s,ar=t}function eu(t){t.return!==null&&(pi(t,1),mf(t,1,0))}function tu(t){for(;t===ua;)ua=Gi[--Yi],Gi[Yi]=null,ca=Gi[--Yi],Gi[Yi]=null;for(;t===hi;)hi=gn[--yn],gn[yn]=null,ar=gn[--yn],gn[yn]=null,or=gn[--yn],gn[yn]=null}var an=null,sn=null,dt=!1,_n=null;function gf(t,n){var o=kn(5,null,null,0);o.elementType="DELETED",o.stateNode=n,o.return=t,n=t.deletions,n===null?(t.deletions=[o],t.flags|=16):n.push(o)}function yf(t,n){switch(t.tag){case 5:var o=t.type;return n=n.nodeType!==1||o.toLowerCase()!==n.nodeName.toLowerCase()?null:n,n!==null?(t.stateNode=n,an=t,sn=_r(n.firstChild),!0):!1;case 6:return n=t.pendingProps===""||n.nodeType!==3?null:n,n!==null?(t.stateNode=n,an=t,sn=null,!0):!1;case 13:return n=n.nodeType!==8?null:n,n!==null?(o=hi!==null?{id:or,overflow:ar}:null,t.memoizedState={dehydrated:n,treeContext:o,retryLane:1073741824},o=kn(18,null,null,0),o.stateNode=n,o.return=t,t.child=o,an=t,sn=null,!0):!1;default:return!1}}function nu(t){return(t.mode&1)!==0&&(t.flags&128)===0}function ru(t){if(dt){var n=sn;if(n){var o=n;if(!yf(t,n)){if(nu(t))throw Error(i(418));n=_r(o.nextSibling);var s=an;n&&yf(t,n)?gf(s,o):(t.flags=t.flags&-4097|2,dt=!1,an=t)}}else{if(nu(t))throw Error(i(418));t.flags=t.flags&-4097|2,dt=!1,an=t}}}function vf(t){for(t=t.return;t!==null&&t.tag!==5&&t.tag!==3&&t.tag!==13;)t=t.return;an=t}function da(t){if(t!==an)return!1;if(!dt)return vf(t),dt=!0,!1;var n;if((n=t.tag!==3)&&!(n=t.tag!==5)&&(n=t.type,n=n!=="head"&&n!=="body"&&!Ks(t.type,t.memoizedProps)),n&&(n=sn)){if(nu(t))throw xf(),Error(i(418));for(;n;)gf(t,n),n=_r(n.nextSibling)}if(vf(t),t.tag===13){if(t=t.memoizedState,t=t!==null?t.dehydrated:null,!t)throw Error(i(317));e:{for(t=t.nextSibling,n=0;t;){if(t.nodeType===8){var o=t.data;if(o==="/$"){if(n===0){sn=_r(t.nextSibling);break e}n--}else o!=="$"&&o!=="$!"&&o!=="$?"||n++}t=t.nextSibling}sn=null}}else sn=an?_r(t.stateNode.nextSibling):null;return!0}function xf(){for(var t=sn;t;)t=_r(t.nextSibling)}function Xi(){sn=an=null,dt=!1}function iu(t){_n===null?_n=[t]:_n.push(t)}var d0=F.ReactCurrentBatchConfig;function Kl(t,n,o){if(t=o.ref,t!==null&&typeof t!="function"&&typeof t!="object"){if(o._owner){if(o=o._owner,o){if(o.tag!==1)throw Error(i(309));var s=o.stateNode}if(!s)throw Error(i(147,t));var d=s,h=""+t;return n!==null&&n.ref!==null&&typeof n.ref=="function"&&n.ref._stringRef===h?n.ref:(n=function(w){var E=d.refs;w===null?delete E[h]:E[h]=w},n._stringRef=h,n)}if(typeof t!="string")throw Error(i(284));if(!o._owner)throw Error(i(290,t))}return t}function fa(t,n){throw t=Object.prototype.toString.call(n),Error(i(31,t==="[object Object]"?"object with keys {"+Object.keys(n).join(", ")+"}":t))}function wf(t){var n=t._init;return n(t._payload)}function kf(t){function n(O,L){if(t){var U=O.deletions;U===null?(O.deletions=[L],O.flags|=16):U.push(L)}}function o(O,L){if(!t)return null;for(;L!==null;)n(O,L),L=L.sibling;return null}function s(O,L){for(O=new Map;L!==null;)L.key!==null?O.set(L.key,L):O.set(L.index,L),L=L.sibling;return O}function d(O,L){return O=Ur(O,L),O.index=0,O.sibling=null,O}function h(O,L,U){return O.index=U,t?(U=O.alternate,U!==null?(U=U.index,U<L?(O.flags|=2,L):U):(O.flags|=2,L)):(O.flags|=1048576,L)}function w(O){return t&&O.alternate===null&&(O.flags|=2),O}function E(O,L,U,oe){return L===null||L.tag!==6?(L=Gu(U,O.mode,oe),L.return=O,L):(L=d(L,U),L.return=O,L)}function _(O,L,U,oe){var xe=U.type;return xe===D?Z(O,L,U.props.children,oe,U.key):L!==null&&(L.elementType===xe||typeof xe=="object"&&xe!==null&&xe.$$typeof===be&&wf(xe)===L.type)?(oe=d(L,U.props),oe.ref=Kl(O,L,U),oe.return=O,oe):(oe=Da(U.type,U.key,U.props,null,O.mode,oe),oe.ref=Kl(O,L,U),oe.return=O,oe)}function H(O,L,U,oe){return L===null||L.tag!==4||L.stateNode.containerInfo!==U.containerInfo||L.stateNode.implementation!==U.implementation?(L=Yu(U,O.mode,oe),L.return=O,L):(L=d(L,U.children||[]),L.return=O,L)}function Z(O,L,U,oe,xe){return L===null||L.tag!==7?(L=Si(U,O.mode,oe,xe),L.return=O,L):(L=d(L,U),L.return=O,L)}function te(O,L,U){if(typeof L=="string"&&L!==""||typeof L=="number")return L=Gu(""+L,O.mode,U),L.return=O,L;if(typeof L=="object"&&L!==null){switch(L.$$typeof){case ee:return U=Da(L.type,L.key,L.props,null,O.mode,U),U.ref=Kl(O,null,L),U.return=O,U;case B:return L=Yu(L,O.mode,U),L.return=O,L;case be:var oe=L._init;return te(O,oe(L._payload),U)}if(An(L)||ce(L))return L=Si(L,O.mode,U,null),L.return=O,L;fa(O,L)}return null}function J(O,L,U,oe){var xe=L!==null?L.key:null;if(typeof U=="string"&&U!==""||typeof U=="number")return xe!==null?null:E(O,L,""+U,oe);if(typeof U=="object"&&U!==null){switch(U.$$typeof){case ee:return U.key===xe?_(O,L,U,oe):null;case B:return U.key===xe?H(O,L,U,oe):null;case be:return xe=U._init,J(O,L,xe(U._payload),oe)}if(An(U)||ce(U))return xe!==null?null:Z(O,L,U,oe,null);fa(O,U)}return null}function de(O,L,U,oe,xe){if(typeof oe=="string"&&oe!==""||typeof oe=="number")return O=O.get(U)||null,E(L,O,""+oe,xe);if(typeof oe=="object"&&oe!==null){switch(oe.$$typeof){case ee:return O=O.get(oe.key===null?U:oe.key)||null,_(L,O,oe,xe);case B:return O=O.get(oe.key===null?U:oe.key)||null,H(L,O,oe,xe);case be:var Pe=oe._init;return de(O,L,U,Pe(oe._payload),xe)}if(An(oe)||ce(oe))return O=O.get(U)||null,Z(L,O,oe,xe,null);fa(L,oe)}return null}function ge(O,L,U,oe){for(var xe=null,Pe=null,je=L,Le=L=0,Rt=null;je!==null&&Le<U.length;Le++){je.index>Le?(Rt=je,je=null):Rt=je.sibling;var Xe=J(O,je,U[Le],oe);if(Xe===null){je===null&&(je=Rt);break}t&&je&&Xe.alternate===null&&n(O,je),L=h(Xe,L,Le),Pe===null?xe=Xe:Pe.sibling=Xe,Pe=Xe,je=Rt}if(Le===U.length)return o(O,je),dt&&pi(O,Le),xe;if(je===null){for(;Le<U.length;Le++)je=te(O,U[Le],oe),je!==null&&(L=h(je,L,Le),Pe===null?xe=je:Pe.sibling=je,Pe=je);return dt&&pi(O,Le),xe}for(je=s(O,je);Le<U.length;Le++)Rt=de(je,O,Le,U[Le],oe),Rt!==null&&(t&&Rt.alternate!==null&&je.delete(Rt.key===null?Le:Rt.key),L=h(Rt,L,Le),Pe===null?xe=Rt:Pe.sibling=Rt,Pe=Rt);return t&&je.forEach(function(Br){return n(O,Br)}),dt&&pi(O,Le),xe}function ve(O,L,U,oe){var xe=ce(U);if(typeof xe!="function")throw Error(i(150));if(U=xe.call(U),U==null)throw Error(i(151));for(var Pe=xe=null,je=L,Le=L=0,Rt=null,Xe=U.next();je!==null&&!Xe.done;Le++,Xe=U.next()){je.index>Le?(Rt=je,je=null):Rt=je.sibling;var Br=J(O,je,Xe.value,oe);if(Br===null){je===null&&(je=Rt);break}t&&je&&Br.alternate===null&&n(O,je),L=h(Br,L,Le),Pe===null?xe=Br:Pe.sibling=Br,Pe=Br,je=Rt}if(Xe.done)return o(O,je),dt&&pi(O,Le),xe;if(je===null){for(;!Xe.done;Le++,Xe=U.next())Xe=te(O,Xe.value,oe),Xe!==null&&(L=h(Xe,L,Le),Pe===null?xe=Xe:Pe.sibling=Xe,Pe=Xe);return dt&&pi(O,Le),xe}for(je=s(O,je);!Xe.done;Le++,Xe=U.next())Xe=de(je,O,Le,Xe.value,oe),Xe!==null&&(t&&Xe.alternate!==null&&je.delete(Xe.key===null?Le:Xe.key),L=h(Xe,L,Le),Pe===null?xe=Xe:Pe.sibling=Xe,Pe=Xe);return t&&je.forEach(function($0){return n(O,$0)}),dt&&pi(O,Le),xe}function wt(O,L,U,oe){if(typeof U=="object"&&U!==null&&U.type===D&&U.key===null&&(U=U.props.children),typeof U=="object"&&U!==null){switch(U.$$typeof){case ee:e:{for(var xe=U.key,Pe=L;Pe!==null;){if(Pe.key===xe){if(xe=U.type,xe===D){if(Pe.tag===7){o(O,Pe.sibling),L=d(Pe,U.props.children),L.return=O,O=L;break e}}else if(Pe.elementType===xe||typeof xe=="object"&&xe!==null&&xe.$$typeof===be&&wf(xe)===Pe.type){o(O,Pe.sibling),L=d(Pe,U.props),L.ref=Kl(O,Pe,U),L.return=O,O=L;break e}o(O,Pe);break}else n(O,Pe);Pe=Pe.sibling}U.type===D?(L=Si(U.props.children,O.mode,oe,U.key),L.return=O,O=L):(oe=Da(U.type,U.key,U.props,null,O.mode,oe),oe.ref=Kl(O,L,U),oe.return=O,O=oe)}return w(O);case B:e:{for(Pe=U.key;L!==null;){if(L.key===Pe)if(L.tag===4&&L.stateNode.containerInfo===U.containerInfo&&L.stateNode.implementation===U.implementation){o(O,L.sibling),L=d(L,U.children||[]),L.return=O,O=L;break e}else{o(O,L);break}else n(O,L);L=L.sibling}L=Yu(U,O.mode,oe),L.return=O,O=L}return w(O);case be:return Pe=U._init,wt(O,L,Pe(U._payload),oe)}if(An(U))return ge(O,L,U,oe);if(ce(U))return ve(O,L,U,oe);fa(O,U)}return typeof U=="string"&&U!==""||typeof U=="number"?(U=""+U,L!==null&&L.tag===6?(o(O,L.sibling),L=d(L,U),L.return=O,O=L):(o(O,L),L=Gu(U,O.mode,oe),L.return=O,O=L),w(O)):o(O,L)}return wt}var Ji=kf(!0),Sf=kf(!1),ha=Tr(null),pa=null,Zi=null,lu=null;function ou(){lu=Zi=pa=null}function au(t){var n=ha.current;ut(ha),t._currentValue=n}function su(t,n,o){for(;t!==null;){var s=t.alternate;if((t.childLanes&n)!==n?(t.childLanes|=n,s!==null&&(s.childLanes|=n)):s!==null&&(s.childLanes&n)!==n&&(s.childLanes|=n),t===o)break;t=t.return}}function el(t,n){pa=t,lu=Zi=null,t=t.dependencies,t!==null&&t.firstContext!==null&&((t.lanes&n)!==0&&(Gt=!0),t.firstContext=null)}function vn(t){var n=t._currentValue;if(lu!==t)if(t={context:t,memoizedValue:n,next:null},Zi===null){if(pa===null)throw Error(i(308));Zi=t,pa.dependencies={lanes:0,firstContext:t}}else Zi=Zi.next=t;return n}var mi=null;function uu(t){mi===null?mi=[t]:mi.push(t)}function Ef(t,n,o,s){var d=n.interleaved;return d===null?(o.next=o,uu(n)):(o.next=d.next,d.next=o),n.interleaved=o,sr(t,s)}function sr(t,n){t.lanes|=n;var o=t.alternate;for(o!==null&&(o.lanes|=n),o=t,t=t.return;t!==null;)t.childLanes|=n,o=t.alternate,o!==null&&(o.childLanes|=n),o=t,t=t.return;return o.tag===3?o.stateNode:null}var Ir=!1;function cu(t){t.updateQueue={baseState:t.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function Cf(t,n){t=t.updateQueue,n.updateQueue===t&&(n.updateQueue={baseState:t.baseState,firstBaseUpdate:t.firstBaseUpdate,lastBaseUpdate:t.lastBaseUpdate,shared:t.shared,effects:t.effects})}function ur(t,n){return{eventTime:t,lane:n,tag:0,payload:null,callback:null,next:null}}function Mr(t,n,o){var s=t.updateQueue;if(s===null)return null;if(s=s.shared,(Ke&2)!==0){var d=s.pending;return d===null?n.next=n:(n.next=d.next,d.next=n),s.pending=n,sr(t,o)}return d=s.interleaved,d===null?(n.next=n,uu(s)):(n.next=d.next,d.next=n),s.interleaved=n,sr(t,o)}function ma(t,n,o){if(n=n.updateQueue,n!==null&&(n=n.shared,(o&4194240)!==0)){var s=n.lanes;s&=t.pendingLanes,o|=s,n.lanes=o,Cs(t,o)}}function bf(t,n){var o=t.updateQueue,s=t.alternate;if(s!==null&&(s=s.updateQueue,o===s)){var d=null,h=null;if(o=o.firstBaseUpdate,o!==null){do{var w={eventTime:o.eventTime,lane:o.lane,tag:o.tag,payload:o.payload,callback:o.callback,next:null};h===null?d=h=w:h=h.next=w,o=o.next}while(o!==null);h===null?d=h=n:h=h.next=n}else d=h=n;o={baseState:s.baseState,firstBaseUpdate:d,lastBaseUpdate:h,shared:s.shared,effects:s.effects},t.updateQueue=o;return}t=o.lastBaseUpdate,t===null?o.firstBaseUpdate=n:t.next=n,o.lastBaseUpdate=n}function ga(t,n,o,s){var d=t.updateQueue;Ir=!1;var h=d.firstBaseUpdate,w=d.lastBaseUpdate,E=d.shared.pending;if(E!==null){d.shared.pending=null;var _=E,H=_.next;_.next=null,w===null?h=H:w.next=H,w=_;var Z=t.alternate;Z!==null&&(Z=Z.updateQueue,E=Z.lastBaseUpdate,E!==w&&(E===null?Z.firstBaseUpdate=H:E.next=H,Z.lastBaseUpdate=_))}if(h!==null){var te=d.baseState;w=0,Z=H=_=null,E=h;do{var J=E.lane,de=E.eventTime;if((s&J)===J){Z!==null&&(Z=Z.next={eventTime:de,lane:0,tag:E.tag,payload:E.payload,callback:E.callback,next:null});e:{var ge=t,ve=E;switch(J=n,de=o,ve.tag){case 1:if(ge=ve.payload,typeof ge=="function"){te=ge.call(de,te,J);break e}te=ge;break e;case 3:ge.flags=ge.flags&-65537|128;case 0:if(ge=ve.payload,J=typeof ge=="function"?ge.call(de,te,J):ge,J==null)break e;te=S({},te,J);break e;case 2:Ir=!0}}E.callback!==null&&E.lane!==0&&(t.flags|=64,J=d.effects,J===null?d.effects=[E]:J.push(E))}else de={eventTime:de,lane:J,tag:E.tag,payload:E.payload,callback:E.callback,next:null},Z===null?(H=Z=de,_=te):Z=Z.next=de,w|=J;if(E=E.next,E===null){if(E=d.shared.pending,E===null)break;J=E,E=J.next,J.next=null,d.lastBaseUpdate=J,d.shared.pending=null}}while(!0);if(Z===null&&(_=te),d.baseState=_,d.firstBaseUpdate=H,d.lastBaseUpdate=Z,n=d.shared.interleaved,n!==null){d=n;do w|=d.lane,d=d.next;while(d!==n)}else h===null&&(d.shared.lanes=0);vi|=w,t.lanes=w,t.memoizedState=te}}function Nf(t,n,o){if(t=n.effects,n.effects=null,t!==null)for(n=0;n<t.length;n++){var s=t[n],d=s.callback;if(d!==null){if(s.callback=null,s=o,typeof d!="function")throw Error(i(191,d));d.call(s)}}}var Gl={},Wn=Tr(Gl),Yl=Tr(Gl),Xl=Tr(Gl);function gi(t){if(t===Gl)throw Error(i(174));return t}function du(t,n){switch(it(Xl,n),it(Yl,t),it(Wn,Gl),t=n.nodeType,t){case 9:case 11:n=(n=n.documentElement)?n.namespaceURI:ae(null,"");break;default:t=t===8?n.parentNode:n,n=t.namespaceURI||null,t=t.tagName,n=ae(n,t)}ut(Wn),it(Wn,n)}function tl(){ut(Wn),ut(Yl),ut(Xl)}function Pf(t){gi(Xl.current);var n=gi(Wn.current),o=ae(n,t.type);n!==o&&(it(Yl,t),it(Wn,o))}function fu(t){Yl.current===t&&(ut(Wn),ut(Yl))}var ht=Tr(0);function ya(t){for(var n=t;n!==null;){if(n.tag===13){var o=n.memoizedState;if(o!==null&&(o=o.dehydrated,o===null||o.data==="$?"||o.data==="$!"))return n}else if(n.tag===19&&n.memoizedProps.revealOrder!==void 0){if((n.flags&128)!==0)return n}else if(n.child!==null){n.child.return=n,n=n.child;continue}if(n===t)break;for(;n.sibling===null;){if(n.return===null||n.return===t)return null;n=n.return}n.sibling.return=n.return,n=n.sibling}return null}var hu=[];function pu(){for(var t=0;t<hu.length;t++)hu[t]._workInProgressVersionPrimary=null;hu.length=0}var va=F.ReactCurrentDispatcher,mu=F.ReactCurrentBatchConfig,yi=0,pt=null,Pt=null,_t=null,xa=!1,Jl=!1,Zl=0,f0=0;function Ft(){throw Error(i(321))}function gu(t,n){if(n===null)return!1;for(var o=0;o<n.length&&o<t.length;o++)if(!jn(t[o],n[o]))return!1;return!0}function yu(t,n,o,s,d,h){if(yi=h,pt=n,n.memoizedState=null,n.updateQueue=null,n.lanes=0,va.current=t===null||t.memoizedState===null?g0:y0,t=o(s,d),Jl){h=0;do{if(Jl=!1,Zl=0,25<=h)throw Error(i(301));h+=1,_t=Pt=null,n.updateQueue=null,va.current=v0,t=o(s,d)}while(Jl)}if(va.current=Sa,n=Pt!==null&&Pt.next!==null,yi=0,_t=Pt=pt=null,xa=!1,n)throw Error(i(300));return t}function vu(){var t=Zl!==0;return Zl=0,t}function Qn(){var t={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return _t===null?pt.memoizedState=_t=t:_t=_t.next=t,_t}function xn(){if(Pt===null){var t=pt.alternate;t=t!==null?t.memoizedState:null}else t=Pt.next;var n=_t===null?pt.memoizedState:_t.next;if(n!==null)_t=n,Pt=t;else{if(t===null)throw Error(i(310));Pt=t,t={memoizedState:Pt.memoizedState,baseState:Pt.baseState,baseQueue:Pt.baseQueue,queue:Pt.queue,next:null},_t===null?pt.memoizedState=_t=t:_t=_t.next=t}return _t}function eo(t,n){return typeof n=="function"?n(t):n}function xu(t){var n=xn(),o=n.queue;if(o===null)throw Error(i(311));o.lastRenderedReducer=t;var s=Pt,d=s.baseQueue,h=o.pending;if(h!==null){if(d!==null){var w=d.next;d.next=h.next,h.next=w}s.baseQueue=d=h,o.pending=null}if(d!==null){h=d.next,s=s.baseState;var E=w=null,_=null,H=h;do{var Z=H.lane;if((yi&Z)===Z)_!==null&&(_=_.next={lane:0,action:H.action,hasEagerState:H.hasEagerState,eagerState:H.eagerState,next:null}),s=H.hasEagerState?H.eagerState:t(s,H.action);else{var te={lane:Z,action:H.action,hasEagerState:H.hasEagerState,eagerState:H.eagerState,next:null};_===null?(E=_=te,w=s):_=_.next=te,pt.lanes|=Z,vi|=Z}H=H.next}while(H!==null&&H!==h);_===null?w=s:_.next=E,jn(s,n.memoizedState)||(Gt=!0),n.memoizedState=s,n.baseState=w,n.baseQueue=_,o.lastRenderedState=s}if(t=o.interleaved,t!==null){d=t;do h=d.lane,pt.lanes|=h,vi|=h,d=d.next;while(d!==t)}else d===null&&(o.lanes=0);return[n.memoizedState,o.dispatch]}function wu(t){var n=xn(),o=n.queue;if(o===null)throw Error(i(311));o.lastRenderedReducer=t;var s=o.dispatch,d=o.pending,h=n.memoizedState;if(d!==null){o.pending=null;var w=d=d.next;do h=t(h,w.action),w=w.next;while(w!==d);jn(h,n.memoizedState)||(Gt=!0),n.memoizedState=h,n.baseQueue===null&&(n.baseState=h),o.lastRenderedState=h}return[h,s]}function jf(){}function _f(t,n){var o=pt,s=xn(),d=n(),h=!jn(s.memoizedState,d);if(h&&(s.memoizedState=d,Gt=!0),s=s.queue,ku(Lf.bind(null,o,s,t),[t]),s.getSnapshot!==n||h||_t!==null&&_t.memoizedState.tag&1){if(o.flags|=2048,to(9,Rf.bind(null,o,s,d,n),void 0,null),Tt===null)throw Error(i(349));(yi&30)!==0||Tf(o,n,d)}return d}function Tf(t,n,o){t.flags|=16384,t={getSnapshot:n,value:o},n=pt.updateQueue,n===null?(n={lastEffect:null,stores:null},pt.updateQueue=n,n.stores=[t]):(o=n.stores,o===null?n.stores=[t]:o.push(t))}function Rf(t,n,o,s){n.value=o,n.getSnapshot=s,If(n)&&Mf(t)}function Lf(t,n,o){return o(function(){If(n)&&Mf(t)})}function If(t){var n=t.getSnapshot;t=t.value;try{var o=n();return!jn(t,o)}catch{return!0}}function Mf(t){var n=sr(t,1);n!==null&&In(n,t,1,-1)}function zf(t){var n=Qn();return typeof t=="function"&&(t=t()),n.memoizedState=n.baseState=t,t={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:eo,lastRenderedState:t},n.queue=t,t=t.dispatch=m0.bind(null,pt,t),[n.memoizedState,t]}function to(t,n,o,s){return t={tag:t,create:n,destroy:o,deps:s,next:null},n=pt.updateQueue,n===null?(n={lastEffect:null,stores:null},pt.updateQueue=n,n.lastEffect=t.next=t):(o=n.lastEffect,o===null?n.lastEffect=t.next=t:(s=o.next,o.next=t,t.next=s,n.lastEffect=t)),t}function Df(){return xn().memoizedState}function wa(t,n,o,s){var d=Qn();pt.flags|=t,d.memoizedState=to(1|n,o,void 0,s===void 0?null:s)}function ka(t,n,o,s){var d=xn();s=s===void 0?null:s;var h=void 0;if(Pt!==null){var w=Pt.memoizedState;if(h=w.destroy,s!==null&&gu(s,w.deps)){d.memoizedState=to(n,o,h,s);return}}pt.flags|=t,d.memoizedState=to(1|n,o,h,s)}function Af(t,n){return wa(8390656,8,t,n)}function ku(t,n){return ka(2048,8,t,n)}function Of(t,n){return ka(4,2,t,n)}function Ff(t,n){return ka(4,4,t,n)}function Uf(t,n){if(typeof n=="function")return t=t(),n(t),function(){n(null)};if(n!=null)return t=t(),n.current=t,function(){n.current=null}}function Bf(t,n,o){return o=o!=null?o.concat([t]):null,ka(4,4,Uf.bind(null,n,t),o)}function Su(){}function Hf(t,n){var o=xn();n=n===void 0?null:n;var s=o.memoizedState;return s!==null&&n!==null&&gu(n,s[1])?s[0]:(o.memoizedState=[t,n],t)}function Vf(t,n){var o=xn();n=n===void 0?null:n;var s=o.memoizedState;return s!==null&&n!==null&&gu(n,s[1])?s[0]:(t=t(),o.memoizedState=[t,n],t)}function $f(t,n,o){return(yi&21)===0?(t.baseState&&(t.baseState=!1,Gt=!0),t.memoizedState=o):(jn(o,n)||(o=xd(),pt.lanes|=o,vi|=o,t.baseState=!0),n)}function h0(t,n){var o=et;et=o!==0&&4>o?o:4,t(!0);var s=mu.transition;mu.transition={};try{t(!1),n()}finally{et=o,mu.transition=s}}function Wf(){return xn().memoizedState}function p0(t,n,o){var s=Or(t);if(o={lane:s,action:o,hasEagerState:!1,eagerState:null,next:null},Qf(t))qf(n,o);else if(o=Ef(t,n,o,s),o!==null){var d=Wt();In(o,t,s,d),Kf(o,n,s)}}function m0(t,n,o){var s=Or(t),d={lane:s,action:o,hasEagerState:!1,eagerState:null,next:null};if(Qf(t))qf(n,d);else{var h=t.alternate;if(t.lanes===0&&(h===null||h.lanes===0)&&(h=n.lastRenderedReducer,h!==null))try{var w=n.lastRenderedState,E=h(w,o);if(d.hasEagerState=!0,d.eagerState=E,jn(E,w)){var _=n.interleaved;_===null?(d.next=d,uu(n)):(d.next=_.next,_.next=d),n.interleaved=d;return}}catch{}finally{}o=Ef(t,n,d,s),o!==null&&(d=Wt(),In(o,t,s,d),Kf(o,n,s))}}function Qf(t){var n=t.alternate;return t===pt||n!==null&&n===pt}function qf(t,n){Jl=xa=!0;var o=t.pending;o===null?n.next=n:(n.next=o.next,o.next=n),t.pending=n}function Kf(t,n,o){if((o&4194240)!==0){var s=n.lanes;s&=t.pendingLanes,o|=s,n.lanes=o,Cs(t,o)}}var Sa={readContext:vn,useCallback:Ft,useContext:Ft,useEffect:Ft,useImperativeHandle:Ft,useInsertionEffect:Ft,useLayoutEffect:Ft,useMemo:Ft,useReducer:Ft,useRef:Ft,useState:Ft,useDebugValue:Ft,useDeferredValue:Ft,useTransition:Ft,useMutableSource:Ft,useSyncExternalStore:Ft,useId:Ft,unstable_isNewReconciler:!1},g0={readContext:vn,useCallback:function(t,n){return Qn().memoizedState=[t,n===void 0?null:n],t},useContext:vn,useEffect:Af,useImperativeHandle:function(t,n,o){return o=o!=null?o.concat([t]):null,wa(4194308,4,Uf.bind(null,n,t),o)},useLayoutEffect:function(t,n){return wa(4194308,4,t,n)},useInsertionEffect:function(t,n){return wa(4,2,t,n)},useMemo:function(t,n){var o=Qn();return n=n===void 0?null:n,t=t(),o.memoizedState=[t,n],t},useReducer:function(t,n,o){var s=Qn();return n=o!==void 0?o(n):n,s.memoizedState=s.baseState=n,t={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:t,lastRenderedState:n},s.queue=t,t=t.dispatch=p0.bind(null,pt,t),[s.memoizedState,t]},useRef:function(t){var n=Qn();return t={current:t},n.memoizedState=t},useState:zf,useDebugValue:Su,useDeferredValue:function(t){return Qn().memoizedState=t},useTransition:function(){var t=zf(!1),n=t[0];return t=h0.bind(null,t[1]),Qn().memoizedState=t,[n,t]},useMutableSource:function(){},useSyncExternalStore:function(t,n,o){var s=pt,d=Qn();if(dt){if(o===void 0)throw Error(i(407));o=o()}else{if(o=n(),Tt===null)throw Error(i(349));(yi&30)!==0||Tf(s,n,o)}d.memoizedState=o;var h={value:o,getSnapshot:n};return d.queue=h,Af(Lf.bind(null,s,h,t),[t]),s.flags|=2048,to(9,Rf.bind(null,s,h,o,n),void 0,null),o},useId:function(){var t=Qn(),n=Tt.identifierPrefix;if(dt){var o=ar,s=or;o=(s&~(1<<32-Ye(s)-1)).toString(32)+o,n=":"+n+"R"+o,o=Zl++,0<o&&(n+="H"+o.toString(32)),n+=":"}else o=f0++,n=":"+n+"r"+o.toString(32)+":";return t.memoizedState=n},unstable_isNewReconciler:!1},y0={readContext:vn,useCallback:Hf,useContext:vn,useEffect:ku,useImperativeHandle:Bf,useInsertionEffect:Of,useLayoutEffect:Ff,useMemo:Vf,useReducer:xu,useRef:Df,useState:function(){return xu(eo)},useDebugValue:Su,useDeferredValue:function(t){var n=xn();return $f(n,Pt.memoizedState,t)},useTransition:function(){var t=xu(eo)[0],n=xn().memoizedState;return[t,n]},useMutableSource:jf,useSyncExternalStore:_f,useId:Wf,unstable_isNewReconciler:!1},v0={readContext:vn,useCallback:Hf,useContext:vn,useEffect:ku,useImperativeHandle:Bf,useInsertionEffect:Of,useLayoutEffect:Ff,useMemo:Vf,useReducer:wu,useRef:Df,useState:function(){return wu(eo)},useDebugValue:Su,useDeferredValue:function(t){var n=xn();return Pt===null?n.memoizedState=t:$f(n,Pt.memoizedState,t)},useTransition:function(){var t=wu(eo)[0],n=xn().memoizedState;return[t,n]},useMutableSource:jf,useSyncExternalStore:_f,useId:Wf,unstable_isNewReconciler:!1};function Tn(t,n){if(t&&t.defaultProps){n=S({},n),t=t.defaultProps;for(var o in t)n[o]===void 0&&(n[o]=t[o]);return n}return n}function Eu(t,n,o,s){n=t.memoizedState,o=o(s,n),o=o==null?n:S({},n,o),t.memoizedState=o,t.lanes===0&&(t.updateQueue.baseState=o)}var Ea={isMounted:function(t){return(t=t._reactInternals)?pe(t)===t:!1},enqueueSetState:function(t,n,o){t=t._reactInternals;var s=Wt(),d=Or(t),h=ur(s,d);h.payload=n,o!=null&&(h.callback=o),n=Mr(t,h,d),n!==null&&(In(n,t,d,s),ma(n,t,d))},enqueueReplaceState:function(t,n,o){t=t._reactInternals;var s=Wt(),d=Or(t),h=ur(s,d);h.tag=1,h.payload=n,o!=null&&(h.callback=o),n=Mr(t,h,d),n!==null&&(In(n,t,d,s),ma(n,t,d))},enqueueForceUpdate:function(t,n){t=t._reactInternals;var o=Wt(),s=Or(t),d=ur(o,s);d.tag=2,n!=null&&(d.callback=n),n=Mr(t,d,s),n!==null&&(In(n,t,s,o),ma(n,t,s))}};function Gf(t,n,o,s,d,h,w){return t=t.stateNode,typeof t.shouldComponentUpdate=="function"?t.shouldComponentUpdate(s,h,w):n.prototype&&n.prototype.isPureReactComponent?!Bl(o,s)||!Bl(d,h):!0}function Yf(t,n,o){var s=!1,d=Rr,h=n.contextType;return typeof h=="object"&&h!==null?h=vn(h):(d=Kt(n)?fi:Ot.current,s=n.contextTypes,h=(s=s!=null)?Ki(t,d):Rr),n=new n(o,h),t.memoizedState=n.state!==null&&n.state!==void 0?n.state:null,n.updater=Ea,t.stateNode=n,n._reactInternals=t,s&&(t=t.stateNode,t.__reactInternalMemoizedUnmaskedChildContext=d,t.__reactInternalMemoizedMaskedChildContext=h),n}function Xf(t,n,o,s){t=n.state,typeof n.componentWillReceiveProps=="function"&&n.componentWillReceiveProps(o,s),typeof n.UNSAFE_componentWillReceiveProps=="function"&&n.UNSAFE_componentWillReceiveProps(o,s),n.state!==t&&Ea.enqueueReplaceState(n,n.state,null)}function Cu(t,n,o,s){var d=t.stateNode;d.props=o,d.state=t.memoizedState,d.refs={},cu(t);var h=n.contextType;typeof h=="object"&&h!==null?d.context=vn(h):(h=Kt(n)?fi:Ot.current,d.context=Ki(t,h)),d.state=t.memoizedState,h=n.getDerivedStateFromProps,typeof h=="function"&&(Eu(t,n,h,o),d.state=t.memoizedState),typeof n.getDerivedStateFromProps=="function"||typeof d.getSnapshotBeforeUpdate=="function"||typeof d.UNSAFE_componentWillMount!="function"&&typeof d.componentWillMount!="function"||(n=d.state,typeof d.componentWillMount=="function"&&d.componentWillMount(),typeof d.UNSAFE_componentWillMount=="function"&&d.UNSAFE_componentWillMount(),n!==d.state&&Ea.enqueueReplaceState(d,d.state,null),ga(t,o,d,s),d.state=t.memoizedState),typeof d.componentDidMount=="function"&&(t.flags|=4194308)}function nl(t,n){try{var o="",s=n;do o+=Ne(s),s=s.return;while(s);var d=o}catch(h){d=`
|
|
39
|
+
Error generating stack: `+h.message+`
|
|
40
|
+
`+h.stack}return{value:t,source:n,stack:d,digest:null}}function bu(t,n,o){return{value:t,source:null,stack:o??null,digest:n??null}}function Nu(t,n){try{console.error(n.value)}catch(o){setTimeout(function(){throw o})}}var x0=typeof WeakMap=="function"?WeakMap:Map;function Jf(t,n,o){o=ur(-1,o),o.tag=3,o.payload={element:null};var s=n.value;return o.callback=function(){Ta||(Ta=!0,Bu=s),Nu(t,n)},o}function Zf(t,n,o){o=ur(-1,o),o.tag=3;var s=t.type.getDerivedStateFromError;if(typeof s=="function"){var d=n.value;o.payload=function(){return s(d)},o.callback=function(){Nu(t,n)}}var h=t.stateNode;return h!==null&&typeof h.componentDidCatch=="function"&&(o.callback=function(){Nu(t,n),typeof s!="function"&&(Dr===null?Dr=new Set([this]):Dr.add(this));var w=n.stack;this.componentDidCatch(n.value,{componentStack:w!==null?w:""})}),o}function eh(t,n,o){var s=t.pingCache;if(s===null){s=t.pingCache=new x0;var d=new Set;s.set(n,d)}else d=s.get(n),d===void 0&&(d=new Set,s.set(n,d));d.has(o)||(d.add(o),t=I0.bind(null,t,n,o),n.then(t,t))}function th(t){do{var n;if((n=t.tag===13)&&(n=t.memoizedState,n=n!==null?n.dehydrated!==null:!0),n)return t;t=t.return}while(t!==null);return null}function nh(t,n,o,s,d){return(t.mode&1)===0?(t===n?t.flags|=65536:(t.flags|=128,o.flags|=131072,o.flags&=-52805,o.tag===1&&(o.alternate===null?o.tag=17:(n=ur(-1,1),n.tag=2,Mr(o,n,1))),o.lanes|=1),t):(t.flags|=65536,t.lanes=d,t)}var w0=F.ReactCurrentOwner,Gt=!1;function $t(t,n,o,s){n.child=t===null?Sf(n,null,o,s):Ji(n,t.child,o,s)}function rh(t,n,o,s,d){o=o.render;var h=n.ref;return el(n,d),s=yu(t,n,o,s,h,d),o=vu(),t!==null&&!Gt?(n.updateQueue=t.updateQueue,n.flags&=-2053,t.lanes&=~d,cr(t,n,d)):(dt&&o&&eu(n),n.flags|=1,$t(t,n,s,d),n.child)}function ih(t,n,o,s,d){if(t===null){var h=o.type;return typeof h=="function"&&!Ku(h)&&h.defaultProps===void 0&&o.compare===null&&o.defaultProps===void 0?(n.tag=15,n.type=h,lh(t,n,h,s,d)):(t=Da(o.type,null,s,n,n.mode,d),t.ref=n.ref,t.return=n,n.child=t)}if(h=t.child,(t.lanes&d)===0){var w=h.memoizedProps;if(o=o.compare,o=o!==null?o:Bl,o(w,s)&&t.ref===n.ref)return cr(t,n,d)}return n.flags|=1,t=Ur(h,s),t.ref=n.ref,t.return=n,n.child=t}function lh(t,n,o,s,d){if(t!==null){var h=t.memoizedProps;if(Bl(h,s)&&t.ref===n.ref)if(Gt=!1,n.pendingProps=s=h,(t.lanes&d)!==0)(t.flags&131072)!==0&&(Gt=!0);else return n.lanes=t.lanes,cr(t,n,d)}return Pu(t,n,o,s,d)}function oh(t,n,o){var s=n.pendingProps,d=s.children,h=t!==null?t.memoizedState:null;if(s.mode==="hidden")if((n.mode&1)===0)n.memoizedState={baseLanes:0,cachePool:null,transitions:null},it(il,un),un|=o;else{if((o&1073741824)===0)return t=h!==null?h.baseLanes|o:o,n.lanes=n.childLanes=1073741824,n.memoizedState={baseLanes:t,cachePool:null,transitions:null},n.updateQueue=null,it(il,un),un|=t,null;n.memoizedState={baseLanes:0,cachePool:null,transitions:null},s=h!==null?h.baseLanes:o,it(il,un),un|=s}else h!==null?(s=h.baseLanes|o,n.memoizedState=null):s=o,it(il,un),un|=s;return $t(t,n,d,o),n.child}function ah(t,n){var o=n.ref;(t===null&&o!==null||t!==null&&t.ref!==o)&&(n.flags|=512,n.flags|=2097152)}function Pu(t,n,o,s,d){var h=Kt(o)?fi:Ot.current;return h=Ki(n,h),el(n,d),o=yu(t,n,o,s,h,d),s=vu(),t!==null&&!Gt?(n.updateQueue=t.updateQueue,n.flags&=-2053,t.lanes&=~d,cr(t,n,d)):(dt&&s&&eu(n),n.flags|=1,$t(t,n,o,d),n.child)}function sh(t,n,o,s,d){if(Kt(o)){var h=!0;aa(n)}else h=!1;if(el(n,d),n.stateNode===null)ba(t,n),Yf(n,o,s),Cu(n,o,s,d),s=!0;else if(t===null){var w=n.stateNode,E=n.memoizedProps;w.props=E;var _=w.context,H=o.contextType;typeof H=="object"&&H!==null?H=vn(H):(H=Kt(o)?fi:Ot.current,H=Ki(n,H));var Z=o.getDerivedStateFromProps,te=typeof Z=="function"||typeof w.getSnapshotBeforeUpdate=="function";te||typeof w.UNSAFE_componentWillReceiveProps!="function"&&typeof w.componentWillReceiveProps!="function"||(E!==s||_!==H)&&Xf(n,w,s,H),Ir=!1;var J=n.memoizedState;w.state=J,ga(n,s,w,d),_=n.memoizedState,E!==s||J!==_||qt.current||Ir?(typeof Z=="function"&&(Eu(n,o,Z,s),_=n.memoizedState),(E=Ir||Gf(n,o,E,s,J,_,H))?(te||typeof w.UNSAFE_componentWillMount!="function"&&typeof w.componentWillMount!="function"||(typeof w.componentWillMount=="function"&&w.componentWillMount(),typeof w.UNSAFE_componentWillMount=="function"&&w.UNSAFE_componentWillMount()),typeof w.componentDidMount=="function"&&(n.flags|=4194308)):(typeof w.componentDidMount=="function"&&(n.flags|=4194308),n.memoizedProps=s,n.memoizedState=_),w.props=s,w.state=_,w.context=H,s=E):(typeof w.componentDidMount=="function"&&(n.flags|=4194308),s=!1)}else{w=n.stateNode,Cf(t,n),E=n.memoizedProps,H=n.type===n.elementType?E:Tn(n.type,E),w.props=H,te=n.pendingProps,J=w.context,_=o.contextType,typeof _=="object"&&_!==null?_=vn(_):(_=Kt(o)?fi:Ot.current,_=Ki(n,_));var de=o.getDerivedStateFromProps;(Z=typeof de=="function"||typeof w.getSnapshotBeforeUpdate=="function")||typeof w.UNSAFE_componentWillReceiveProps!="function"&&typeof w.componentWillReceiveProps!="function"||(E!==te||J!==_)&&Xf(n,w,s,_),Ir=!1,J=n.memoizedState,w.state=J,ga(n,s,w,d);var ge=n.memoizedState;E!==te||J!==ge||qt.current||Ir?(typeof de=="function"&&(Eu(n,o,de,s),ge=n.memoizedState),(H=Ir||Gf(n,o,H,s,J,ge,_)||!1)?(Z||typeof w.UNSAFE_componentWillUpdate!="function"&&typeof w.componentWillUpdate!="function"||(typeof w.componentWillUpdate=="function"&&w.componentWillUpdate(s,ge,_),typeof w.UNSAFE_componentWillUpdate=="function"&&w.UNSAFE_componentWillUpdate(s,ge,_)),typeof w.componentDidUpdate=="function"&&(n.flags|=4),typeof w.getSnapshotBeforeUpdate=="function"&&(n.flags|=1024)):(typeof w.componentDidUpdate!="function"||E===t.memoizedProps&&J===t.memoizedState||(n.flags|=4),typeof w.getSnapshotBeforeUpdate!="function"||E===t.memoizedProps&&J===t.memoizedState||(n.flags|=1024),n.memoizedProps=s,n.memoizedState=ge),w.props=s,w.state=ge,w.context=_,s=H):(typeof w.componentDidUpdate!="function"||E===t.memoizedProps&&J===t.memoizedState||(n.flags|=4),typeof w.getSnapshotBeforeUpdate!="function"||E===t.memoizedProps&&J===t.memoizedState||(n.flags|=1024),s=!1)}return ju(t,n,o,s,h,d)}function ju(t,n,o,s,d,h){ah(t,n);var w=(n.flags&128)!==0;if(!s&&!w)return d&&hf(n,o,!1),cr(t,n,h);s=n.stateNode,w0.current=n;var E=w&&typeof o.getDerivedStateFromError!="function"?null:s.render();return n.flags|=1,t!==null&&w?(n.child=Ji(n,t.child,null,h),n.child=Ji(n,null,E,h)):$t(t,n,E,h),n.memoizedState=s.state,d&&hf(n,o,!0),n.child}function uh(t){var n=t.stateNode;n.pendingContext?df(t,n.pendingContext,n.pendingContext!==n.context):n.context&&df(t,n.context,!1),du(t,n.containerInfo)}function ch(t,n,o,s,d){return Xi(),iu(d),n.flags|=256,$t(t,n,o,s),n.child}var _u={dehydrated:null,treeContext:null,retryLane:0};function Tu(t){return{baseLanes:t,cachePool:null,transitions:null}}function dh(t,n,o){var s=n.pendingProps,d=ht.current,h=!1,w=(n.flags&128)!==0,E;if((E=w)||(E=t!==null&&t.memoizedState===null?!1:(d&2)!==0),E?(h=!0,n.flags&=-129):(t===null||t.memoizedState!==null)&&(d|=1),it(ht,d&1),t===null)return ru(n),t=n.memoizedState,t!==null&&(t=t.dehydrated,t!==null)?((n.mode&1)===0?n.lanes=1:t.data==="$!"?n.lanes=8:n.lanes=1073741824,null):(w=s.children,t=s.fallback,h?(s=n.mode,h=n.child,w={mode:"hidden",children:w},(s&1)===0&&h!==null?(h.childLanes=0,h.pendingProps=w):h=Aa(w,s,0,null),t=Si(t,s,o,null),h.return=n,t.return=n,h.sibling=t,n.child=h,n.child.memoizedState=Tu(o),n.memoizedState=_u,t):Ru(n,w));if(d=t.memoizedState,d!==null&&(E=d.dehydrated,E!==null))return k0(t,n,w,s,E,d,o);if(h){h=s.fallback,w=n.mode,d=t.child,E=d.sibling;var _={mode:"hidden",children:s.children};return(w&1)===0&&n.child!==d?(s=n.child,s.childLanes=0,s.pendingProps=_,n.deletions=null):(s=Ur(d,_),s.subtreeFlags=d.subtreeFlags&14680064),E!==null?h=Ur(E,h):(h=Si(h,w,o,null),h.flags|=2),h.return=n,s.return=n,s.sibling=h,n.child=s,s=h,h=n.child,w=t.child.memoizedState,w=w===null?Tu(o):{baseLanes:w.baseLanes|o,cachePool:null,transitions:w.transitions},h.memoizedState=w,h.childLanes=t.childLanes&~o,n.memoizedState=_u,s}return h=t.child,t=h.sibling,s=Ur(h,{mode:"visible",children:s.children}),(n.mode&1)===0&&(s.lanes=o),s.return=n,s.sibling=null,t!==null&&(o=n.deletions,o===null?(n.deletions=[t],n.flags|=16):o.push(t)),n.child=s,n.memoizedState=null,s}function Ru(t,n){return n=Aa({mode:"visible",children:n},t.mode,0,null),n.return=t,t.child=n}function Ca(t,n,o,s){return s!==null&&iu(s),Ji(n,t.child,null,o),t=Ru(n,n.pendingProps.children),t.flags|=2,n.memoizedState=null,t}function k0(t,n,o,s,d,h,w){if(o)return n.flags&256?(n.flags&=-257,s=bu(Error(i(422))),Ca(t,n,w,s)):n.memoizedState!==null?(n.child=t.child,n.flags|=128,null):(h=s.fallback,d=n.mode,s=Aa({mode:"visible",children:s.children},d,0,null),h=Si(h,d,w,null),h.flags|=2,s.return=n,h.return=n,s.sibling=h,n.child=s,(n.mode&1)!==0&&Ji(n,t.child,null,w),n.child.memoizedState=Tu(w),n.memoizedState=_u,h);if((n.mode&1)===0)return Ca(t,n,w,null);if(d.data==="$!"){if(s=d.nextSibling&&d.nextSibling.dataset,s)var E=s.dgst;return s=E,h=Error(i(419)),s=bu(h,s,void 0),Ca(t,n,w,s)}if(E=(w&t.childLanes)!==0,Gt||E){if(s=Tt,s!==null){switch(w&-w){case 4:d=2;break;case 16:d=8;break;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:d=32;break;case 536870912:d=268435456;break;default:d=0}d=(d&(s.suspendedLanes|w))!==0?0:d,d!==0&&d!==h.retryLane&&(h.retryLane=d,sr(t,d),In(s,t,d,-1))}return qu(),s=bu(Error(i(421))),Ca(t,n,w,s)}return d.data==="$?"?(n.flags|=128,n.child=t.child,n=M0.bind(null,t),d._reactRetry=n,null):(t=h.treeContext,sn=_r(d.nextSibling),an=n,dt=!0,_n=null,t!==null&&(gn[yn++]=or,gn[yn++]=ar,gn[yn++]=hi,or=t.id,ar=t.overflow,hi=n),n=Ru(n,s.children),n.flags|=4096,n)}function fh(t,n,o){t.lanes|=n;var s=t.alternate;s!==null&&(s.lanes|=n),su(t.return,n,o)}function Lu(t,n,o,s,d){var h=t.memoizedState;h===null?t.memoizedState={isBackwards:n,rendering:null,renderingStartTime:0,last:s,tail:o,tailMode:d}:(h.isBackwards=n,h.rendering=null,h.renderingStartTime=0,h.last=s,h.tail=o,h.tailMode=d)}function hh(t,n,o){var s=n.pendingProps,d=s.revealOrder,h=s.tail;if($t(t,n,s.children,o),s=ht.current,(s&2)!==0)s=s&1|2,n.flags|=128;else{if(t!==null&&(t.flags&128)!==0)e:for(t=n.child;t!==null;){if(t.tag===13)t.memoizedState!==null&&fh(t,o,n);else if(t.tag===19)fh(t,o,n);else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===n)break e;for(;t.sibling===null;){if(t.return===null||t.return===n)break e;t=t.return}t.sibling.return=t.return,t=t.sibling}s&=1}if(it(ht,s),(n.mode&1)===0)n.memoizedState=null;else switch(d){case"forwards":for(o=n.child,d=null;o!==null;)t=o.alternate,t!==null&&ya(t)===null&&(d=o),o=o.sibling;o=d,o===null?(d=n.child,n.child=null):(d=o.sibling,o.sibling=null),Lu(n,!1,d,o,h);break;case"backwards":for(o=null,d=n.child,n.child=null;d!==null;){if(t=d.alternate,t!==null&&ya(t)===null){n.child=d;break}t=d.sibling,d.sibling=o,o=d,d=t}Lu(n,!0,o,null,h);break;case"together":Lu(n,!1,null,null,void 0);break;default:n.memoizedState=null}return n.child}function ba(t,n){(n.mode&1)===0&&t!==null&&(t.alternate=null,n.alternate=null,n.flags|=2)}function cr(t,n,o){if(t!==null&&(n.dependencies=t.dependencies),vi|=n.lanes,(o&n.childLanes)===0)return null;if(t!==null&&n.child!==t.child)throw Error(i(153));if(n.child!==null){for(t=n.child,o=Ur(t,t.pendingProps),n.child=o,o.return=n;t.sibling!==null;)t=t.sibling,o=o.sibling=Ur(t,t.pendingProps),o.return=n;o.sibling=null}return n.child}function S0(t,n,o){switch(n.tag){case 3:uh(n),Xi();break;case 5:Pf(n);break;case 1:Kt(n.type)&&aa(n);break;case 4:du(n,n.stateNode.containerInfo);break;case 10:var s=n.type._context,d=n.memoizedProps.value;it(ha,s._currentValue),s._currentValue=d;break;case 13:if(s=n.memoizedState,s!==null)return s.dehydrated!==null?(it(ht,ht.current&1),n.flags|=128,null):(o&n.child.childLanes)!==0?dh(t,n,o):(it(ht,ht.current&1),t=cr(t,n,o),t!==null?t.sibling:null);it(ht,ht.current&1);break;case 19:if(s=(o&n.childLanes)!==0,(t.flags&128)!==0){if(s)return hh(t,n,o);n.flags|=128}if(d=n.memoizedState,d!==null&&(d.rendering=null,d.tail=null,d.lastEffect=null),it(ht,ht.current),s)break;return null;case 22:case 23:return n.lanes=0,oh(t,n,o)}return cr(t,n,o)}var ph,Iu,mh,gh;ph=function(t,n){for(var o=n.child;o!==null;){if(o.tag===5||o.tag===6)t.appendChild(o.stateNode);else if(o.tag!==4&&o.child!==null){o.child.return=o,o=o.child;continue}if(o===n)break;for(;o.sibling===null;){if(o.return===null||o.return===n)return;o=o.return}o.sibling.return=o.return,o=o.sibling}},Iu=function(){},mh=function(t,n,o,s){var d=t.memoizedProps;if(d!==s){t=n.stateNode,gi(Wn.current);var h=null;switch(o){case"input":d=vr(t,d),s=vr(t,s),h=[];break;case"select":d=S({},d,{value:void 0}),s=S({},s,{value:void 0}),h=[];break;case"textarea":d=oi(t,d),s=oi(t,s),h=[];break;default:typeof d.onClick!="function"&&typeof s.onClick=="function"&&(t.onclick=ia)}St(o,s);var w;o=null;for(H in d)if(!s.hasOwnProperty(H)&&d.hasOwnProperty(H)&&d[H]!=null)if(H==="style"){var E=d[H];for(w in E)E.hasOwnProperty(w)&&(o||(o={}),o[w]="")}else H!=="dangerouslySetInnerHTML"&&H!=="children"&&H!=="suppressContentEditableWarning"&&H!=="suppressHydrationWarning"&&H!=="autoFocus"&&(a.hasOwnProperty(H)?h||(h=[]):(h=h||[]).push(H,null));for(H in s){var _=s[H];if(E=d!=null?d[H]:void 0,s.hasOwnProperty(H)&&_!==E&&(_!=null||E!=null))if(H==="style")if(E){for(w in E)!E.hasOwnProperty(w)||_&&_.hasOwnProperty(w)||(o||(o={}),o[w]="");for(w in _)_.hasOwnProperty(w)&&E[w]!==_[w]&&(o||(o={}),o[w]=_[w])}else o||(h||(h=[]),h.push(H,o)),o=_;else H==="dangerouslySetInnerHTML"?(_=_?_.__html:void 0,E=E?E.__html:void 0,_!=null&&E!==_&&(h=h||[]).push(H,_)):H==="children"?typeof _!="string"&&typeof _!="number"||(h=h||[]).push(H,""+_):H!=="suppressContentEditableWarning"&&H!=="suppressHydrationWarning"&&(a.hasOwnProperty(H)?(_!=null&&H==="onScroll"&&st("scroll",t),h||E===_||(h=[])):(h=h||[]).push(H,_))}o&&(h=h||[]).push("style",o);var H=h;(n.updateQueue=H)&&(n.flags|=4)}},gh=function(t,n,o,s){o!==s&&(n.flags|=4)};function no(t,n){if(!dt)switch(t.tailMode){case"hidden":n=t.tail;for(var o=null;n!==null;)n.alternate!==null&&(o=n),n=n.sibling;o===null?t.tail=null:o.sibling=null;break;case"collapsed":o=t.tail;for(var s=null;o!==null;)o.alternate!==null&&(s=o),o=o.sibling;s===null?n||t.tail===null?t.tail=null:t.tail.sibling=null:s.sibling=null}}function Ut(t){var n=t.alternate!==null&&t.alternate.child===t.child,o=0,s=0;if(n)for(var d=t.child;d!==null;)o|=d.lanes|d.childLanes,s|=d.subtreeFlags&14680064,s|=d.flags&14680064,d.return=t,d=d.sibling;else for(d=t.child;d!==null;)o|=d.lanes|d.childLanes,s|=d.subtreeFlags,s|=d.flags,d.return=t,d=d.sibling;return t.subtreeFlags|=s,t.childLanes=o,n}function E0(t,n,o){var s=n.pendingProps;switch(tu(n),n.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return Ut(n),null;case 1:return Kt(n.type)&&oa(),Ut(n),null;case 3:return s=n.stateNode,tl(),ut(qt),ut(Ot),pu(),s.pendingContext&&(s.context=s.pendingContext,s.pendingContext=null),(t===null||t.child===null)&&(da(n)?n.flags|=4:t===null||t.memoizedState.isDehydrated&&(n.flags&256)===0||(n.flags|=1024,_n!==null&&($u(_n),_n=null))),Iu(t,n),Ut(n),null;case 5:fu(n);var d=gi(Xl.current);if(o=n.type,t!==null&&n.stateNode!=null)mh(t,n,o,s,d),t.ref!==n.ref&&(n.flags|=512,n.flags|=2097152);else{if(!s){if(n.stateNode===null)throw Error(i(166));return Ut(n),null}if(t=gi(Wn.current),da(n)){s=n.stateNode,o=n.type;var h=n.memoizedProps;switch(s[$n]=n,s[Ql]=h,t=(n.mode&1)!==0,o){case"dialog":st("cancel",s),st("close",s);break;case"iframe":case"object":case"embed":st("load",s);break;case"video":case"audio":for(d=0;d<Vl.length;d++)st(Vl[d],s);break;case"source":st("error",s);break;case"img":case"image":case"link":st("error",s),st("load",s);break;case"details":st("toggle",s);break;case"input":li(s,h),st("invalid",s);break;case"select":s._wrapperState={wasMultiple:!!h.multiple},st("invalid",s);break;case"textarea":Di(s,h),st("invalid",s)}St(o,h),d=null;for(var w in h)if(h.hasOwnProperty(w)){var E=h[w];w==="children"?typeof E=="string"?s.textContent!==E&&(h.suppressHydrationWarning!==!0&&ra(s.textContent,E,t),d=["children",E]):typeof E=="number"&&s.textContent!==""+E&&(h.suppressHydrationWarning!==!0&&ra(s.textContent,E,t),d=["children",""+E]):a.hasOwnProperty(w)&&E!=null&&w==="onScroll"&&st("scroll",s)}switch(o){case"input":Cn(s),zi(s,h,!0);break;case"textarea":Cn(s),Fn(s);break;case"select":case"option":break;default:typeof h.onClick=="function"&&(s.onclick=ia)}s=d,n.updateQueue=s,s!==null&&(n.flags|=4)}else{w=d.nodeType===9?d:d.ownerDocument,t==="http://www.w3.org/1999/xhtml"&&(t=W(o)),t==="http://www.w3.org/1999/xhtml"?o==="script"?(t=w.createElement("div"),t.innerHTML="<script><\/script>",t=t.removeChild(t.firstChild)):typeof s.is=="string"?t=w.createElement(o,{is:s.is}):(t=w.createElement(o),o==="select"&&(w=t,s.multiple?w.multiple=!0:s.size&&(w.size=s.size))):t=w.createElementNS(t,o),t[$n]=n,t[Ql]=s,ph(t,n,!1,!1),n.stateNode=t;e:{switch(w=mn(o,s),o){case"dialog":st("cancel",t),st("close",t),d=s;break;case"iframe":case"object":case"embed":st("load",t),d=s;break;case"video":case"audio":for(d=0;d<Vl.length;d++)st(Vl[d],t);d=s;break;case"source":st("error",t),d=s;break;case"img":case"image":case"link":st("error",t),st("load",t),d=s;break;case"details":st("toggle",t),d=s;break;case"input":li(t,s),d=vr(t,s),st("invalid",t);break;case"option":d=s;break;case"select":t._wrapperState={wasMultiple:!!s.multiple},d=S({},s,{value:void 0}),st("invalid",t);break;case"textarea":Di(t,s),d=oi(t,s),st("invalid",t);break;default:d=s}St(o,d),E=d;for(h in E)if(E.hasOwnProperty(h)){var _=E[h];h==="style"?Nn(t,_):h==="dangerouslySetInnerHTML"?(_=_?_.__html:void 0,_!=null&&Re(t,_)):h==="children"?typeof _=="string"?(o!=="textarea"||_!=="")&&Ve(t,_):typeof _=="number"&&Ve(t,""+_):h!=="suppressContentEditableWarning"&&h!=="suppressHydrationWarning"&&h!=="autoFocus"&&(a.hasOwnProperty(h)?_!=null&&h==="onScroll"&&st("scroll",t):_!=null&&I(t,h,_,w))}switch(o){case"input":Cn(t),zi(t,s,!1);break;case"textarea":Cn(t),Fn(t);break;case"option":s.value!=null&&t.setAttribute("value",""+De(s.value));break;case"select":t.multiple=!!s.multiple,h=s.value,h!=null?On(t,!!s.multiple,h,!1):s.defaultValue!=null&&On(t,!!s.multiple,s.defaultValue,!0);break;default:typeof d.onClick=="function"&&(t.onclick=ia)}switch(o){case"button":case"input":case"select":case"textarea":s=!!s.autoFocus;break e;case"img":s=!0;break e;default:s=!1}}s&&(n.flags|=4)}n.ref!==null&&(n.flags|=512,n.flags|=2097152)}return Ut(n),null;case 6:if(t&&n.stateNode!=null)gh(t,n,t.memoizedProps,s);else{if(typeof s!="string"&&n.stateNode===null)throw Error(i(166));if(o=gi(Xl.current),gi(Wn.current),da(n)){if(s=n.stateNode,o=n.memoizedProps,s[$n]=n,(h=s.nodeValue!==o)&&(t=an,t!==null))switch(t.tag){case 3:ra(s.nodeValue,o,(t.mode&1)!==0);break;case 5:t.memoizedProps.suppressHydrationWarning!==!0&&ra(s.nodeValue,o,(t.mode&1)!==0)}h&&(n.flags|=4)}else s=(o.nodeType===9?o:o.ownerDocument).createTextNode(s),s[$n]=n,n.stateNode=s}return Ut(n),null;case 13:if(ut(ht),s=n.memoizedState,t===null||t.memoizedState!==null&&t.memoizedState.dehydrated!==null){if(dt&&sn!==null&&(n.mode&1)!==0&&(n.flags&128)===0)xf(),Xi(),n.flags|=98560,h=!1;else if(h=da(n),s!==null&&s.dehydrated!==null){if(t===null){if(!h)throw Error(i(318));if(h=n.memoizedState,h=h!==null?h.dehydrated:null,!h)throw Error(i(317));h[$n]=n}else Xi(),(n.flags&128)===0&&(n.memoizedState=null),n.flags|=4;Ut(n),h=!1}else _n!==null&&($u(_n),_n=null),h=!0;if(!h)return n.flags&65536?n:null}return(n.flags&128)!==0?(n.lanes=o,n):(s=s!==null,s!==(t!==null&&t.memoizedState!==null)&&s&&(n.child.flags|=8192,(n.mode&1)!==0&&(t===null||(ht.current&1)!==0?jt===0&&(jt=3):qu())),n.updateQueue!==null&&(n.flags|=4),Ut(n),null);case 4:return tl(),Iu(t,n),t===null&&$l(n.stateNode.containerInfo),Ut(n),null;case 10:return au(n.type._context),Ut(n),null;case 17:return Kt(n.type)&&oa(),Ut(n),null;case 19:if(ut(ht),h=n.memoizedState,h===null)return Ut(n),null;if(s=(n.flags&128)!==0,w=h.rendering,w===null)if(s)no(h,!1);else{if(jt!==0||t!==null&&(t.flags&128)!==0)for(t=n.child;t!==null;){if(w=ya(t),w!==null){for(n.flags|=128,no(h,!1),s=w.updateQueue,s!==null&&(n.updateQueue=s,n.flags|=4),n.subtreeFlags=0,s=o,o=n.child;o!==null;)h=o,t=s,h.flags&=14680066,w=h.alternate,w===null?(h.childLanes=0,h.lanes=t,h.child=null,h.subtreeFlags=0,h.memoizedProps=null,h.memoizedState=null,h.updateQueue=null,h.dependencies=null,h.stateNode=null):(h.childLanes=w.childLanes,h.lanes=w.lanes,h.child=w.child,h.subtreeFlags=0,h.deletions=null,h.memoizedProps=w.memoizedProps,h.memoizedState=w.memoizedState,h.updateQueue=w.updateQueue,h.type=w.type,t=w.dependencies,h.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext}),o=o.sibling;return it(ht,ht.current&1|2),n.child}t=t.sibling}h.tail!==null&&Ge()>ll&&(n.flags|=128,s=!0,no(h,!1),n.lanes=4194304)}else{if(!s)if(t=ya(w),t!==null){if(n.flags|=128,s=!0,o=t.updateQueue,o!==null&&(n.updateQueue=o,n.flags|=4),no(h,!0),h.tail===null&&h.tailMode==="hidden"&&!w.alternate&&!dt)return Ut(n),null}else 2*Ge()-h.renderingStartTime>ll&&o!==1073741824&&(n.flags|=128,s=!0,no(h,!1),n.lanes=4194304);h.isBackwards?(w.sibling=n.child,n.child=w):(o=h.last,o!==null?o.sibling=w:n.child=w,h.last=w)}return h.tail!==null?(n=h.tail,h.rendering=n,h.tail=n.sibling,h.renderingStartTime=Ge(),n.sibling=null,o=ht.current,it(ht,s?o&1|2:o&1),n):(Ut(n),null);case 22:case 23:return Qu(),s=n.memoizedState!==null,t!==null&&t.memoizedState!==null!==s&&(n.flags|=8192),s&&(n.mode&1)!==0?(un&1073741824)!==0&&(Ut(n),n.subtreeFlags&6&&(n.flags|=8192)):Ut(n),null;case 24:return null;case 25:return null}throw Error(i(156,n.tag))}function C0(t,n){switch(tu(n),n.tag){case 1:return Kt(n.type)&&oa(),t=n.flags,t&65536?(n.flags=t&-65537|128,n):null;case 3:return tl(),ut(qt),ut(Ot),pu(),t=n.flags,(t&65536)!==0&&(t&128)===0?(n.flags=t&-65537|128,n):null;case 5:return fu(n),null;case 13:if(ut(ht),t=n.memoizedState,t!==null&&t.dehydrated!==null){if(n.alternate===null)throw Error(i(340));Xi()}return t=n.flags,t&65536?(n.flags=t&-65537|128,n):null;case 19:return ut(ht),null;case 4:return tl(),null;case 10:return au(n.type._context),null;case 22:case 23:return Qu(),null;case 24:return null;default:return null}}var Na=!1,Bt=!1,b0=typeof WeakSet=="function"?WeakSet:Set,he=null;function rl(t,n){var o=t.ref;if(o!==null)if(typeof o=="function")try{o(null)}catch(s){yt(t,n,s)}else o.current=null}function Mu(t,n,o){try{o()}catch(s){yt(t,n,s)}}var yh=!1;function N0(t,n){if(Qs=Qo,t=Kd(),Os(t)){if("selectionStart"in t)var o={start:t.selectionStart,end:t.selectionEnd};else e:{o=(o=t.ownerDocument)&&o.defaultView||window;var s=o.getSelection&&o.getSelection();if(s&&s.rangeCount!==0){o=s.anchorNode;var d=s.anchorOffset,h=s.focusNode;s=s.focusOffset;try{o.nodeType,h.nodeType}catch{o=null;break e}var w=0,E=-1,_=-1,H=0,Z=0,te=t,J=null;t:for(;;){for(var de;te!==o||d!==0&&te.nodeType!==3||(E=w+d),te!==h||s!==0&&te.nodeType!==3||(_=w+s),te.nodeType===3&&(w+=te.nodeValue.length),(de=te.firstChild)!==null;)J=te,te=de;for(;;){if(te===t)break t;if(J===o&&++H===d&&(E=w),J===h&&++Z===s&&(_=w),(de=te.nextSibling)!==null)break;te=J,J=te.parentNode}te=de}o=E===-1||_===-1?null:{start:E,end:_}}else o=null}o=o||{start:0,end:0}}else o=null;for(qs={focusedElem:t,selectionRange:o},Qo=!1,he=n;he!==null;)if(n=he,t=n.child,(n.subtreeFlags&1028)!==0&&t!==null)t.return=n,he=t;else for(;he!==null;){n=he;try{var ge=n.alternate;if((n.flags&1024)!==0)switch(n.tag){case 0:case 11:case 15:break;case 1:if(ge!==null){var ve=ge.memoizedProps,wt=ge.memoizedState,O=n.stateNode,L=O.getSnapshotBeforeUpdate(n.elementType===n.type?ve:Tn(n.type,ve),wt);O.__reactInternalSnapshotBeforeUpdate=L}break;case 3:var U=n.stateNode.containerInfo;U.nodeType===1?U.textContent="":U.nodeType===9&&U.documentElement&&U.removeChild(U.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(i(163))}}catch(oe){yt(n,n.return,oe)}if(t=n.sibling,t!==null){t.return=n.return,he=t;break}he=n.return}return ge=yh,yh=!1,ge}function ro(t,n,o){var s=n.updateQueue;if(s=s!==null?s.lastEffect:null,s!==null){var d=s=s.next;do{if((d.tag&t)===t){var h=d.destroy;d.destroy=void 0,h!==void 0&&Mu(n,o,h)}d=d.next}while(d!==s)}}function Pa(t,n){if(n=n.updateQueue,n=n!==null?n.lastEffect:null,n!==null){var o=n=n.next;do{if((o.tag&t)===t){var s=o.create;o.destroy=s()}o=o.next}while(o!==n)}}function zu(t){var n=t.ref;if(n!==null){var o=t.stateNode;switch(t.tag){case 5:t=o;break;default:t=o}typeof n=="function"?n(t):n.current=t}}function vh(t){var n=t.alternate;n!==null&&(t.alternate=null,vh(n)),t.child=null,t.deletions=null,t.sibling=null,t.tag===5&&(n=t.stateNode,n!==null&&(delete n[$n],delete n[Ql],delete n[Xs],delete n[s0],delete n[u0])),t.stateNode=null,t.return=null,t.dependencies=null,t.memoizedProps=null,t.memoizedState=null,t.pendingProps=null,t.stateNode=null,t.updateQueue=null}function xh(t){return t.tag===5||t.tag===3||t.tag===4}function wh(t){e:for(;;){for(;t.sibling===null;){if(t.return===null||xh(t.return))return null;t=t.return}for(t.sibling.return=t.return,t=t.sibling;t.tag!==5&&t.tag!==6&&t.tag!==18;){if(t.flags&2||t.child===null||t.tag===4)continue e;t.child.return=t,t=t.child}if(!(t.flags&2))return t.stateNode}}function Du(t,n,o){var s=t.tag;if(s===5||s===6)t=t.stateNode,n?o.nodeType===8?o.parentNode.insertBefore(t,n):o.insertBefore(t,n):(o.nodeType===8?(n=o.parentNode,n.insertBefore(t,o)):(n=o,n.appendChild(t)),o=o._reactRootContainer,o!=null||n.onclick!==null||(n.onclick=ia));else if(s!==4&&(t=t.child,t!==null))for(Du(t,n,o),t=t.sibling;t!==null;)Du(t,n,o),t=t.sibling}function Au(t,n,o){var s=t.tag;if(s===5||s===6)t=t.stateNode,n?o.insertBefore(t,n):o.appendChild(t);else if(s!==4&&(t=t.child,t!==null))for(Au(t,n,o),t=t.sibling;t!==null;)Au(t,n,o),t=t.sibling}var Mt=null,Rn=!1;function zr(t,n,o){for(o=o.child;o!==null;)kh(t,n,o),o=o.sibling}function kh(t,n,o){if(It&&typeof It.onCommitFiberUnmount=="function")try{It.onCommitFiberUnmount(nt,o)}catch{}switch(o.tag){case 5:Bt||rl(o,n);case 6:var s=Mt,d=Rn;Mt=null,zr(t,n,o),Mt=s,Rn=d,Mt!==null&&(Rn?(t=Mt,o=o.stateNode,t.nodeType===8?t.parentNode.removeChild(o):t.removeChild(o)):Mt.removeChild(o.stateNode));break;case 18:Mt!==null&&(Rn?(t=Mt,o=o.stateNode,t.nodeType===8?Ys(t.parentNode,o):t.nodeType===1&&Ys(t,o),zl(t)):Ys(Mt,o.stateNode));break;case 4:s=Mt,d=Rn,Mt=o.stateNode.containerInfo,Rn=!0,zr(t,n,o),Mt=s,Rn=d;break;case 0:case 11:case 14:case 15:if(!Bt&&(s=o.updateQueue,s!==null&&(s=s.lastEffect,s!==null))){d=s=s.next;do{var h=d,w=h.destroy;h=h.tag,w!==void 0&&((h&2)!==0||(h&4)!==0)&&Mu(o,n,w),d=d.next}while(d!==s)}zr(t,n,o);break;case 1:if(!Bt&&(rl(o,n),s=o.stateNode,typeof s.componentWillUnmount=="function"))try{s.props=o.memoizedProps,s.state=o.memoizedState,s.componentWillUnmount()}catch(E){yt(o,n,E)}zr(t,n,o);break;case 21:zr(t,n,o);break;case 22:o.mode&1?(Bt=(s=Bt)||o.memoizedState!==null,zr(t,n,o),Bt=s):zr(t,n,o);break;default:zr(t,n,o)}}function Sh(t){var n=t.updateQueue;if(n!==null){t.updateQueue=null;var o=t.stateNode;o===null&&(o=t.stateNode=new b0),n.forEach(function(s){var d=z0.bind(null,t,s);o.has(s)||(o.add(s),s.then(d,d))})}}function Ln(t,n){var o=n.deletions;if(o!==null)for(var s=0;s<o.length;s++){var d=o[s];try{var h=t,w=n,E=w;e:for(;E!==null;){switch(E.tag){case 5:Mt=E.stateNode,Rn=!1;break e;case 3:Mt=E.stateNode.containerInfo,Rn=!0;break e;case 4:Mt=E.stateNode.containerInfo,Rn=!0;break e}E=E.return}if(Mt===null)throw Error(i(160));kh(h,w,d),Mt=null,Rn=!1;var _=d.alternate;_!==null&&(_.return=null),d.return=null}catch(H){yt(d,n,H)}}if(n.subtreeFlags&12854)for(n=n.child;n!==null;)Eh(n,t),n=n.sibling}function Eh(t,n){var o=t.alternate,s=t.flags;switch(t.tag){case 0:case 11:case 14:case 15:if(Ln(n,t),qn(t),s&4){try{ro(3,t,t.return),Pa(3,t)}catch(ve){yt(t,t.return,ve)}try{ro(5,t,t.return)}catch(ve){yt(t,t.return,ve)}}break;case 1:Ln(n,t),qn(t),s&512&&o!==null&&rl(o,o.return);break;case 5:if(Ln(n,t),qn(t),s&512&&o!==null&&rl(o,o.return),t.flags&32){var d=t.stateNode;try{Ve(d,"")}catch(ve){yt(t,t.return,ve)}}if(s&4&&(d=t.stateNode,d!=null)){var h=t.memoizedProps,w=o!==null?o.memoizedProps:h,E=t.type,_=t.updateQueue;if(t.updateQueue=null,_!==null)try{E==="input"&&h.type==="radio"&&h.name!=null&&ln(d,h),mn(E,w);var H=mn(E,h);for(w=0;w<_.length;w+=2){var Z=_[w],te=_[w+1];Z==="style"?Nn(d,te):Z==="dangerouslySetInnerHTML"?Re(d,te):Z==="children"?Ve(d,te):I(d,Z,te,H)}switch(E){case"input":xr(d,h);break;case"textarea":pn(d,h);break;case"select":var J=d._wrapperState.wasMultiple;d._wrapperState.wasMultiple=!!h.multiple;var de=h.value;de!=null?On(d,!!h.multiple,de,!1):J!==!!h.multiple&&(h.defaultValue!=null?On(d,!!h.multiple,h.defaultValue,!0):On(d,!!h.multiple,h.multiple?[]:"",!1))}d[Ql]=h}catch(ve){yt(t,t.return,ve)}}break;case 6:if(Ln(n,t),qn(t),s&4){if(t.stateNode===null)throw Error(i(162));d=t.stateNode,h=t.memoizedProps;try{d.nodeValue=h}catch(ve){yt(t,t.return,ve)}}break;case 3:if(Ln(n,t),qn(t),s&4&&o!==null&&o.memoizedState.isDehydrated)try{zl(n.containerInfo)}catch(ve){yt(t,t.return,ve)}break;case 4:Ln(n,t),qn(t);break;case 13:Ln(n,t),qn(t),d=t.child,d.flags&8192&&(h=d.memoizedState!==null,d.stateNode.isHidden=h,!h||d.alternate!==null&&d.alternate.memoizedState!==null||(Uu=Ge())),s&4&&Sh(t);break;case 22:if(Z=o!==null&&o.memoizedState!==null,t.mode&1?(Bt=(H=Bt)||Z,Ln(n,t),Bt=H):Ln(n,t),qn(t),s&8192){if(H=t.memoizedState!==null,(t.stateNode.isHidden=H)&&!Z&&(t.mode&1)!==0)for(he=t,Z=t.child;Z!==null;){for(te=he=Z;he!==null;){switch(J=he,de=J.child,J.tag){case 0:case 11:case 14:case 15:ro(4,J,J.return);break;case 1:rl(J,J.return);var ge=J.stateNode;if(typeof ge.componentWillUnmount=="function"){s=J,o=J.return;try{n=s,ge.props=n.memoizedProps,ge.state=n.memoizedState,ge.componentWillUnmount()}catch(ve){yt(s,o,ve)}}break;case 5:rl(J,J.return);break;case 22:if(J.memoizedState!==null){Nh(te);continue}}de!==null?(de.return=J,he=de):Nh(te)}Z=Z.sibling}e:for(Z=null,te=t;;){if(te.tag===5){if(Z===null){Z=te;try{d=te.stateNode,H?(h=d.style,typeof h.setProperty=="function"?h.setProperty("display","none","important"):h.display="none"):(E=te.stateNode,_=te.memoizedProps.style,w=_!=null&&_.hasOwnProperty("display")?_.display:null,E.style.display=xt("display",w))}catch(ve){yt(t,t.return,ve)}}}else if(te.tag===6){if(Z===null)try{te.stateNode.nodeValue=H?"":te.memoizedProps}catch(ve){yt(t,t.return,ve)}}else if((te.tag!==22&&te.tag!==23||te.memoizedState===null||te===t)&&te.child!==null){te.child.return=te,te=te.child;continue}if(te===t)break e;for(;te.sibling===null;){if(te.return===null||te.return===t)break e;Z===te&&(Z=null),te=te.return}Z===te&&(Z=null),te.sibling.return=te.return,te=te.sibling}}break;case 19:Ln(n,t),qn(t),s&4&&Sh(t);break;case 21:break;default:Ln(n,t),qn(t)}}function qn(t){var n=t.flags;if(n&2){try{e:{for(var o=t.return;o!==null;){if(xh(o)){var s=o;break e}o=o.return}throw Error(i(160))}switch(s.tag){case 5:var d=s.stateNode;s.flags&32&&(Ve(d,""),s.flags&=-33);var h=wh(t);Au(t,h,d);break;case 3:case 4:var w=s.stateNode.containerInfo,E=wh(t);Du(t,E,w);break;default:throw Error(i(161))}}catch(_){yt(t,t.return,_)}t.flags&=-3}n&4096&&(t.flags&=-4097)}function P0(t,n,o){he=t,Ch(t)}function Ch(t,n,o){for(var s=(t.mode&1)!==0;he!==null;){var d=he,h=d.child;if(d.tag===22&&s){var w=d.memoizedState!==null||Na;if(!w){var E=d.alternate,_=E!==null&&E.memoizedState!==null||Bt;E=Na;var H=Bt;if(Na=w,(Bt=_)&&!H)for(he=d;he!==null;)w=he,_=w.child,w.tag===22&&w.memoizedState!==null?Ph(d):_!==null?(_.return=w,he=_):Ph(d);for(;h!==null;)he=h,Ch(h),h=h.sibling;he=d,Na=E,Bt=H}bh(t)}else(d.subtreeFlags&8772)!==0&&h!==null?(h.return=d,he=h):bh(t)}}function bh(t){for(;he!==null;){var n=he;if((n.flags&8772)!==0){var o=n.alternate;try{if((n.flags&8772)!==0)switch(n.tag){case 0:case 11:case 15:Bt||Pa(5,n);break;case 1:var s=n.stateNode;if(n.flags&4&&!Bt)if(o===null)s.componentDidMount();else{var d=n.elementType===n.type?o.memoizedProps:Tn(n.type,o.memoizedProps);s.componentDidUpdate(d,o.memoizedState,s.__reactInternalSnapshotBeforeUpdate)}var h=n.updateQueue;h!==null&&Nf(n,h,s);break;case 3:var w=n.updateQueue;if(w!==null){if(o=null,n.child!==null)switch(n.child.tag){case 5:o=n.child.stateNode;break;case 1:o=n.child.stateNode}Nf(n,w,o)}break;case 5:var E=n.stateNode;if(o===null&&n.flags&4){o=E;var _=n.memoizedProps;switch(n.type){case"button":case"input":case"select":case"textarea":_.autoFocus&&o.focus();break;case"img":_.src&&(o.src=_.src)}}break;case 6:break;case 4:break;case 12:break;case 13:if(n.memoizedState===null){var H=n.alternate;if(H!==null){var Z=H.memoizedState;if(Z!==null){var te=Z.dehydrated;te!==null&&zl(te)}}}break;case 19:case 17:case 21:case 22:case 23:case 25:break;default:throw Error(i(163))}Bt||n.flags&512&&zu(n)}catch(J){yt(n,n.return,J)}}if(n===t){he=null;break}if(o=n.sibling,o!==null){o.return=n.return,he=o;break}he=n.return}}function Nh(t){for(;he!==null;){var n=he;if(n===t){he=null;break}var o=n.sibling;if(o!==null){o.return=n.return,he=o;break}he=n.return}}function Ph(t){for(;he!==null;){var n=he;try{switch(n.tag){case 0:case 11:case 15:var o=n.return;try{Pa(4,n)}catch(_){yt(n,o,_)}break;case 1:var s=n.stateNode;if(typeof s.componentDidMount=="function"){var d=n.return;try{s.componentDidMount()}catch(_){yt(n,d,_)}}var h=n.return;try{zu(n)}catch(_){yt(n,h,_)}break;case 5:var w=n.return;try{zu(n)}catch(_){yt(n,w,_)}}}catch(_){yt(n,n.return,_)}if(n===t){he=null;break}var E=n.sibling;if(E!==null){E.return=n.return,he=E;break}he=n.return}}var j0=Math.ceil,ja=F.ReactCurrentDispatcher,Ou=F.ReactCurrentOwner,wn=F.ReactCurrentBatchConfig,Ke=0,Tt=null,Et=null,zt=0,un=0,il=Tr(0),jt=0,io=null,vi=0,_a=0,Fu=0,lo=null,Yt=null,Uu=0,ll=1/0,dr=null,Ta=!1,Bu=null,Dr=null,Ra=!1,Ar=null,La=0,oo=0,Hu=null,Ia=-1,Ma=0;function Wt(){return(Ke&6)!==0?Ge():Ia!==-1?Ia:Ia=Ge()}function Or(t){return(t.mode&1)===0?1:(Ke&2)!==0&&zt!==0?zt&-zt:d0.transition!==null?(Ma===0&&(Ma=xd()),Ma):(t=et,t!==0||(t=window.event,t=t===void 0?16:jd(t.type)),t)}function In(t,n,o,s){if(50<oo)throw oo=0,Hu=null,Error(i(185));Tl(t,o,s),((Ke&2)===0||t!==Tt)&&(t===Tt&&((Ke&2)===0&&(_a|=o),jt===4&&Fr(t,zt)),Xt(t,s),o===1&&Ke===0&&(n.mode&1)===0&&(ll=Ge()+500,sa&&Lr()))}function Xt(t,n){var o=t.callbackNode;dy(t,n);var s=Vo(t,t===Tt?zt:0);if(s===0)o!==null&&tr(o),t.callbackNode=null,t.callbackPriority=0;else if(n=s&-s,t.callbackPriority!==n){if(o!=null&&tr(o),n===1)t.tag===0?c0(_h.bind(null,t)):pf(_h.bind(null,t)),o0(function(){(Ke&6)===0&&Lr()}),o=null;else{switch(wd(s)){case 1:o=nr;break;case 4:o=Vn;break;case 16:o=rr;break;case 536870912:o=$e;break;default:o=rr}o=Ah(o,jh.bind(null,t))}t.callbackPriority=n,t.callbackNode=o}}function jh(t,n){if(Ia=-1,Ma=0,(Ke&6)!==0)throw Error(i(327));var o=t.callbackNode;if(ol()&&t.callbackNode!==o)return null;var s=Vo(t,t===Tt?zt:0);if(s===0)return null;if((s&30)!==0||(s&t.expiredLanes)!==0||n)n=za(t,s);else{n=s;var d=Ke;Ke|=2;var h=Rh();(Tt!==t||zt!==n)&&(dr=null,ll=Ge()+500,wi(t,n));do try{R0();break}catch(E){Th(t,E)}while(!0);ou(),ja.current=h,Ke=d,Et!==null?n=0:(Tt=null,zt=0,n=jt)}if(n!==0){if(n===2&&(d=Ss(t),d!==0&&(s=d,n=Vu(t,d))),n===1)throw o=io,wi(t,0),Fr(t,s),Xt(t,Ge()),o;if(n===6)Fr(t,s);else{if(d=t.current.alternate,(s&30)===0&&!_0(d)&&(n=za(t,s),n===2&&(h=Ss(t),h!==0&&(s=h,n=Vu(t,h))),n===1))throw o=io,wi(t,0),Fr(t,s),Xt(t,Ge()),o;switch(t.finishedWork=d,t.finishedLanes=s,n){case 0:case 1:throw Error(i(345));case 2:ki(t,Yt,dr);break;case 3:if(Fr(t,s),(s&130023424)===s&&(n=Uu+500-Ge(),10<n)){if(Vo(t,0)!==0)break;if(d=t.suspendedLanes,(d&s)!==s){Wt(),t.pingedLanes|=t.suspendedLanes&d;break}t.timeoutHandle=Gs(ki.bind(null,t,Yt,dr),n);break}ki(t,Yt,dr);break;case 4:if(Fr(t,s),(s&4194240)===s)break;for(n=t.eventTimes,d=-1;0<s;){var w=31-Ye(s);h=1<<w,w=n[w],w>d&&(d=w),s&=~h}if(s=d,s=Ge()-s,s=(120>s?120:480>s?480:1080>s?1080:1920>s?1920:3e3>s?3e3:4320>s?4320:1960*j0(s/1960))-s,10<s){t.timeoutHandle=Gs(ki.bind(null,t,Yt,dr),s);break}ki(t,Yt,dr);break;case 5:ki(t,Yt,dr);break;default:throw Error(i(329))}}}return Xt(t,Ge()),t.callbackNode===o?jh.bind(null,t):null}function Vu(t,n){var o=lo;return t.current.memoizedState.isDehydrated&&(wi(t,n).flags|=256),t=za(t,n),t!==2&&(n=Yt,Yt=o,n!==null&&$u(n)),t}function $u(t){Yt===null?Yt=t:Yt.push.apply(Yt,t)}function _0(t){for(var n=t;;){if(n.flags&16384){var o=n.updateQueue;if(o!==null&&(o=o.stores,o!==null))for(var s=0;s<o.length;s++){var d=o[s],h=d.getSnapshot;d=d.value;try{if(!jn(h(),d))return!1}catch{return!1}}}if(o=n.child,n.subtreeFlags&16384&&o!==null)o.return=n,n=o;else{if(n===t)break;for(;n.sibling===null;){if(n.return===null||n.return===t)return!0;n=n.return}n.sibling.return=n.return,n=n.sibling}}return!0}function Fr(t,n){for(n&=~Fu,n&=~_a,t.suspendedLanes|=n,t.pingedLanes&=~n,t=t.expirationTimes;0<n;){var o=31-Ye(n),s=1<<o;t[o]=-1,n&=~s}}function _h(t){if((Ke&6)!==0)throw Error(i(327));ol();var n=Vo(t,0);if((n&1)===0)return Xt(t,Ge()),null;var o=za(t,n);if(t.tag!==0&&o===2){var s=Ss(t);s!==0&&(n=s,o=Vu(t,s))}if(o===1)throw o=io,wi(t,0),Fr(t,n),Xt(t,Ge()),o;if(o===6)throw Error(i(345));return t.finishedWork=t.current.alternate,t.finishedLanes=n,ki(t,Yt,dr),Xt(t,Ge()),null}function Wu(t,n){var o=Ke;Ke|=1;try{return t(n)}finally{Ke=o,Ke===0&&(ll=Ge()+500,sa&&Lr())}}function xi(t){Ar!==null&&Ar.tag===0&&(Ke&6)===0&&ol();var n=Ke;Ke|=1;var o=wn.transition,s=et;try{if(wn.transition=null,et=1,t)return t()}finally{et=s,wn.transition=o,Ke=n,(Ke&6)===0&&Lr()}}function Qu(){un=il.current,ut(il)}function wi(t,n){t.finishedWork=null,t.finishedLanes=0;var o=t.timeoutHandle;if(o!==-1&&(t.timeoutHandle=-1,l0(o)),Et!==null)for(o=Et.return;o!==null;){var s=o;switch(tu(s),s.tag){case 1:s=s.type.childContextTypes,s!=null&&oa();break;case 3:tl(),ut(qt),ut(Ot),pu();break;case 5:fu(s);break;case 4:tl();break;case 13:ut(ht);break;case 19:ut(ht);break;case 10:au(s.type._context);break;case 22:case 23:Qu()}o=o.return}if(Tt=t,Et=t=Ur(t.current,null),zt=un=n,jt=0,io=null,Fu=_a=vi=0,Yt=lo=null,mi!==null){for(n=0;n<mi.length;n++)if(o=mi[n],s=o.interleaved,s!==null){o.interleaved=null;var d=s.next,h=o.pending;if(h!==null){var w=h.next;h.next=d,s.next=w}o.pending=s}mi=null}return t}function Th(t,n){do{var o=Et;try{if(ou(),va.current=Sa,xa){for(var s=pt.memoizedState;s!==null;){var d=s.queue;d!==null&&(d.pending=null),s=s.next}xa=!1}if(yi=0,_t=Pt=pt=null,Jl=!1,Zl=0,Ou.current=null,o===null||o.return===null){jt=1,io=n,Et=null;break}e:{var h=t,w=o.return,E=o,_=n;if(n=zt,E.flags|=32768,_!==null&&typeof _=="object"&&typeof _.then=="function"){var H=_,Z=E,te=Z.tag;if((Z.mode&1)===0&&(te===0||te===11||te===15)){var J=Z.alternate;J?(Z.updateQueue=J.updateQueue,Z.memoizedState=J.memoizedState,Z.lanes=J.lanes):(Z.updateQueue=null,Z.memoizedState=null)}var de=th(w);if(de!==null){de.flags&=-257,nh(de,w,E,h,n),de.mode&1&&eh(h,H,n),n=de,_=H;var ge=n.updateQueue;if(ge===null){var ve=new Set;ve.add(_),n.updateQueue=ve}else ge.add(_);break e}else{if((n&1)===0){eh(h,H,n),qu();break e}_=Error(i(426))}}else if(dt&&E.mode&1){var wt=th(w);if(wt!==null){(wt.flags&65536)===0&&(wt.flags|=256),nh(wt,w,E,h,n),iu(nl(_,E));break e}}h=_=nl(_,E),jt!==4&&(jt=2),lo===null?lo=[h]:lo.push(h),h=w;do{switch(h.tag){case 3:h.flags|=65536,n&=-n,h.lanes|=n;var O=Jf(h,_,n);bf(h,O);break e;case 1:E=_;var L=h.type,U=h.stateNode;if((h.flags&128)===0&&(typeof L.getDerivedStateFromError=="function"||U!==null&&typeof U.componentDidCatch=="function"&&(Dr===null||!Dr.has(U)))){h.flags|=65536,n&=-n,h.lanes|=n;var oe=Zf(h,E,n);bf(h,oe);break e}}h=h.return}while(h!==null)}Ih(o)}catch(xe){n=xe,Et===o&&o!==null&&(Et=o=o.return);continue}break}while(!0)}function Rh(){var t=ja.current;return ja.current=Sa,t===null?Sa:t}function qu(){(jt===0||jt===3||jt===2)&&(jt=4),Tt===null||(vi&268435455)===0&&(_a&268435455)===0||Fr(Tt,zt)}function za(t,n){var o=Ke;Ke|=2;var s=Rh();(Tt!==t||zt!==n)&&(dr=null,wi(t,n));do try{T0();break}catch(d){Th(t,d)}while(!0);if(ou(),Ke=o,ja.current=s,Et!==null)throw Error(i(261));return Tt=null,zt=0,jt}function T0(){for(;Et!==null;)Lh(Et)}function R0(){for(;Et!==null&&!ui();)Lh(Et)}function Lh(t){var n=Dh(t.alternate,t,un);t.memoizedProps=t.pendingProps,n===null?Ih(t):Et=n,Ou.current=null}function Ih(t){var n=t;do{var o=n.alternate;if(t=n.return,(n.flags&32768)===0){if(o=E0(o,n,un),o!==null){Et=o;return}}else{if(o=C0(o,n),o!==null){o.flags&=32767,Et=o;return}if(t!==null)t.flags|=32768,t.subtreeFlags=0,t.deletions=null;else{jt=6,Et=null;return}}if(n=n.sibling,n!==null){Et=n;return}Et=n=t}while(n!==null);jt===0&&(jt=5)}function ki(t,n,o){var s=et,d=wn.transition;try{wn.transition=null,et=1,L0(t,n,o,s)}finally{wn.transition=d,et=s}return null}function L0(t,n,o,s){do ol();while(Ar!==null);if((Ke&6)!==0)throw Error(i(327));o=t.finishedWork;var d=t.finishedLanes;if(o===null)return null;if(t.finishedWork=null,t.finishedLanes=0,o===t.current)throw Error(i(177));t.callbackNode=null,t.callbackPriority=0;var h=o.lanes|o.childLanes;if(fy(t,h),t===Tt&&(Et=Tt=null,zt=0),(o.subtreeFlags&2064)===0&&(o.flags&2064)===0||Ra||(Ra=!0,Ah(rr,function(){return ol(),null})),h=(o.flags&15990)!==0,(o.subtreeFlags&15990)!==0||h){h=wn.transition,wn.transition=null;var w=et;et=1;var E=Ke;Ke|=4,Ou.current=null,N0(t,o),Eh(o,t),Jy(qs),Qo=!!Qs,qs=Qs=null,t.current=o,P0(o),Pn(),Ke=E,et=w,wn.transition=h}else t.current=o;if(Ra&&(Ra=!1,Ar=t,La=d),h=t.pendingLanes,h===0&&(Dr=null),ci(o.stateNode),Xt(t,Ge()),n!==null)for(s=t.onRecoverableError,o=0;o<n.length;o++)d=n[o],s(d.value,{componentStack:d.stack,digest:d.digest});if(Ta)throw Ta=!1,t=Bu,Bu=null,t;return(La&1)!==0&&t.tag!==0&&ol(),h=t.pendingLanes,(h&1)!==0?t===Hu?oo++:(oo=0,Hu=t):oo=0,Lr(),null}function ol(){if(Ar!==null){var t=wd(La),n=wn.transition,o=et;try{if(wn.transition=null,et=16>t?16:t,Ar===null)var s=!1;else{if(t=Ar,Ar=null,La=0,(Ke&6)!==0)throw Error(i(331));var d=Ke;for(Ke|=4,he=t.current;he!==null;){var h=he,w=h.child;if((he.flags&16)!==0){var E=h.deletions;if(E!==null){for(var _=0;_<E.length;_++){var H=E[_];for(he=H;he!==null;){var Z=he;switch(Z.tag){case 0:case 11:case 15:ro(8,Z,h)}var te=Z.child;if(te!==null)te.return=Z,he=te;else for(;he!==null;){Z=he;var J=Z.sibling,de=Z.return;if(vh(Z),Z===H){he=null;break}if(J!==null){J.return=de,he=J;break}he=de}}}var ge=h.alternate;if(ge!==null){var ve=ge.child;if(ve!==null){ge.child=null;do{var wt=ve.sibling;ve.sibling=null,ve=wt}while(ve!==null)}}he=h}}if((h.subtreeFlags&2064)!==0&&w!==null)w.return=h,he=w;else e:for(;he!==null;){if(h=he,(h.flags&2048)!==0)switch(h.tag){case 0:case 11:case 15:ro(9,h,h.return)}var O=h.sibling;if(O!==null){O.return=h.return,he=O;break e}he=h.return}}var L=t.current;for(he=L;he!==null;){w=he;var U=w.child;if((w.subtreeFlags&2064)!==0&&U!==null)U.return=w,he=U;else e:for(w=L;he!==null;){if(E=he,(E.flags&2048)!==0)try{switch(E.tag){case 0:case 11:case 15:Pa(9,E)}}catch(xe){yt(E,E.return,xe)}if(E===w){he=null;break e}var oe=E.sibling;if(oe!==null){oe.return=E.return,he=oe;break e}he=E.return}}if(Ke=d,Lr(),It&&typeof It.onPostCommitFiberRoot=="function")try{It.onPostCommitFiberRoot(nt,t)}catch{}s=!0}return s}finally{et=o,wn.transition=n}}return!1}function Mh(t,n,o){n=nl(o,n),n=Jf(t,n,1),t=Mr(t,n,1),n=Wt(),t!==null&&(Tl(t,1,n),Xt(t,n))}function yt(t,n,o){if(t.tag===3)Mh(t,t,o);else for(;n!==null;){if(n.tag===3){Mh(n,t,o);break}else if(n.tag===1){var s=n.stateNode;if(typeof n.type.getDerivedStateFromError=="function"||typeof s.componentDidCatch=="function"&&(Dr===null||!Dr.has(s))){t=nl(o,t),t=Zf(n,t,1),n=Mr(n,t,1),t=Wt(),n!==null&&(Tl(n,1,t),Xt(n,t));break}}n=n.return}}function I0(t,n,o){var s=t.pingCache;s!==null&&s.delete(n),n=Wt(),t.pingedLanes|=t.suspendedLanes&o,Tt===t&&(zt&o)===o&&(jt===4||jt===3&&(zt&130023424)===zt&&500>Ge()-Uu?wi(t,0):Fu|=o),Xt(t,n)}function zh(t,n){n===0&&((t.mode&1)===0?n=1:(n=Ho,Ho<<=1,(Ho&130023424)===0&&(Ho=4194304)));var o=Wt();t=sr(t,n),t!==null&&(Tl(t,n,o),Xt(t,o))}function M0(t){var n=t.memoizedState,o=0;n!==null&&(o=n.retryLane),zh(t,o)}function z0(t,n){var o=0;switch(t.tag){case 13:var s=t.stateNode,d=t.memoizedState;d!==null&&(o=d.retryLane);break;case 19:s=t.stateNode;break;default:throw Error(i(314))}s!==null&&s.delete(n),zh(t,o)}var Dh;Dh=function(t,n,o){if(t!==null)if(t.memoizedProps!==n.pendingProps||qt.current)Gt=!0;else{if((t.lanes&o)===0&&(n.flags&128)===0)return Gt=!1,S0(t,n,o);Gt=(t.flags&131072)!==0}else Gt=!1,dt&&(n.flags&1048576)!==0&&mf(n,ca,n.index);switch(n.lanes=0,n.tag){case 2:var s=n.type;ba(t,n),t=n.pendingProps;var d=Ki(n,Ot.current);el(n,o),d=yu(null,n,s,t,d,o);var h=vu();return n.flags|=1,typeof d=="object"&&d!==null&&typeof d.render=="function"&&d.$$typeof===void 0?(n.tag=1,n.memoizedState=null,n.updateQueue=null,Kt(s)?(h=!0,aa(n)):h=!1,n.memoizedState=d.state!==null&&d.state!==void 0?d.state:null,cu(n),d.updater=Ea,n.stateNode=d,d._reactInternals=n,Cu(n,s,t,o),n=ju(null,n,s,!0,h,o)):(n.tag=0,dt&&h&&eu(n),$t(null,n,d,o),n=n.child),n;case 16:s=n.elementType;e:{switch(ba(t,n),t=n.pendingProps,d=s._init,s=d(s._payload),n.type=s,d=n.tag=A0(s),t=Tn(s,t),d){case 0:n=Pu(null,n,s,t,o);break e;case 1:n=sh(null,n,s,t,o);break e;case 11:n=rh(null,n,s,t,o);break e;case 14:n=ih(null,n,s,Tn(s.type,t),o);break e}throw Error(i(306,s,""))}return n;case 0:return s=n.type,d=n.pendingProps,d=n.elementType===s?d:Tn(s,d),Pu(t,n,s,d,o);case 1:return s=n.type,d=n.pendingProps,d=n.elementType===s?d:Tn(s,d),sh(t,n,s,d,o);case 3:e:{if(uh(n),t===null)throw Error(i(387));s=n.pendingProps,h=n.memoizedState,d=h.element,Cf(t,n),ga(n,s,null,o);var w=n.memoizedState;if(s=w.element,h.isDehydrated)if(h={element:s,isDehydrated:!1,cache:w.cache,pendingSuspenseBoundaries:w.pendingSuspenseBoundaries,transitions:w.transitions},n.updateQueue.baseState=h,n.memoizedState=h,n.flags&256){d=nl(Error(i(423)),n),n=ch(t,n,s,o,d);break e}else if(s!==d){d=nl(Error(i(424)),n),n=ch(t,n,s,o,d);break e}else for(sn=_r(n.stateNode.containerInfo.firstChild),an=n,dt=!0,_n=null,o=Sf(n,null,s,o),n.child=o;o;)o.flags=o.flags&-3|4096,o=o.sibling;else{if(Xi(),s===d){n=cr(t,n,o);break e}$t(t,n,s,o)}n=n.child}return n;case 5:return Pf(n),t===null&&ru(n),s=n.type,d=n.pendingProps,h=t!==null?t.memoizedProps:null,w=d.children,Ks(s,d)?w=null:h!==null&&Ks(s,h)&&(n.flags|=32),ah(t,n),$t(t,n,w,o),n.child;case 6:return t===null&&ru(n),null;case 13:return dh(t,n,o);case 4:return du(n,n.stateNode.containerInfo),s=n.pendingProps,t===null?n.child=Ji(n,null,s,o):$t(t,n,s,o),n.child;case 11:return s=n.type,d=n.pendingProps,d=n.elementType===s?d:Tn(s,d),rh(t,n,s,d,o);case 7:return $t(t,n,n.pendingProps,o),n.child;case 8:return $t(t,n,n.pendingProps.children,o),n.child;case 12:return $t(t,n,n.pendingProps.children,o),n.child;case 10:e:{if(s=n.type._context,d=n.pendingProps,h=n.memoizedProps,w=d.value,it(ha,s._currentValue),s._currentValue=w,h!==null)if(jn(h.value,w)){if(h.children===d.children&&!qt.current){n=cr(t,n,o);break e}}else for(h=n.child,h!==null&&(h.return=n);h!==null;){var E=h.dependencies;if(E!==null){w=h.child;for(var _=E.firstContext;_!==null;){if(_.context===s){if(h.tag===1){_=ur(-1,o&-o),_.tag=2;var H=h.updateQueue;if(H!==null){H=H.shared;var Z=H.pending;Z===null?_.next=_:(_.next=Z.next,Z.next=_),H.pending=_}}h.lanes|=o,_=h.alternate,_!==null&&(_.lanes|=o),su(h.return,o,n),E.lanes|=o;break}_=_.next}}else if(h.tag===10)w=h.type===n.type?null:h.child;else if(h.tag===18){if(w=h.return,w===null)throw Error(i(341));w.lanes|=o,E=w.alternate,E!==null&&(E.lanes|=o),su(w,o,n),w=h.sibling}else w=h.child;if(w!==null)w.return=h;else for(w=h;w!==null;){if(w===n){w=null;break}if(h=w.sibling,h!==null){h.return=w.return,w=h;break}w=w.return}h=w}$t(t,n,d.children,o),n=n.child}return n;case 9:return d=n.type,s=n.pendingProps.children,el(n,o),d=vn(d),s=s(d),n.flags|=1,$t(t,n,s,o),n.child;case 14:return s=n.type,d=Tn(s,n.pendingProps),d=Tn(s.type,d),ih(t,n,s,d,o);case 15:return lh(t,n,n.type,n.pendingProps,o);case 17:return s=n.type,d=n.pendingProps,d=n.elementType===s?d:Tn(s,d),ba(t,n),n.tag=1,Kt(s)?(t=!0,aa(n)):t=!1,el(n,o),Yf(n,s,d),Cu(n,s,d,o),ju(null,n,s,!0,t,o);case 19:return hh(t,n,o);case 22:return oh(t,n,o)}throw Error(i(156,n.tag))};function Ah(t,n){return at(t,n)}function D0(t,n,o,s){this.tag=t,this.key=o,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=n,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=s,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function kn(t,n,o,s){return new D0(t,n,o,s)}function Ku(t){return t=t.prototype,!(!t||!t.isReactComponent)}function A0(t){if(typeof t=="function")return Ku(t)?1:0;if(t!=null){if(t=t.$$typeof,t===K)return 11;if(t===ne)return 14}return 2}function Ur(t,n){var o=t.alternate;return o===null?(o=kn(t.tag,n,t.key,t.mode),o.elementType=t.elementType,o.type=t.type,o.stateNode=t.stateNode,o.alternate=t,t.alternate=o):(o.pendingProps=n,o.type=t.type,o.flags=0,o.subtreeFlags=0,o.deletions=null),o.flags=t.flags&14680064,o.childLanes=t.childLanes,o.lanes=t.lanes,o.child=t.child,o.memoizedProps=t.memoizedProps,o.memoizedState=t.memoizedState,o.updateQueue=t.updateQueue,n=t.dependencies,o.dependencies=n===null?null:{lanes:n.lanes,firstContext:n.firstContext},o.sibling=t.sibling,o.index=t.index,o.ref=t.ref,o}function Da(t,n,o,s,d,h){var w=2;if(s=t,typeof t=="function")Ku(t)&&(w=1);else if(typeof t=="string")w=5;else e:switch(t){case D:return Si(o.children,d,h,n);case G:w=8,d|=8;break;case le:return t=kn(12,o,n,d|2),t.elementType=le,t.lanes=h,t;case Se:return t=kn(13,o,n,d),t.elementType=Se,t.lanes=h,t;case se:return t=kn(19,o,n,d),t.elementType=se,t.lanes=h,t;case _e:return Aa(o,d,h,n);default:if(typeof t=="object"&&t!==null)switch(t.$$typeof){case re:w=10;break e;case $:w=9;break e;case K:w=11;break e;case ne:w=14;break e;case be:w=16,s=null;break e}throw Error(i(130,t==null?t:typeof t,""))}return n=kn(w,o,n,d),n.elementType=t,n.type=s,n.lanes=h,n}function Si(t,n,o,s){return t=kn(7,t,s,n),t.lanes=o,t}function Aa(t,n,o,s){return t=kn(22,t,s,n),t.elementType=_e,t.lanes=o,t.stateNode={isHidden:!1},t}function Gu(t,n,o){return t=kn(6,t,null,n),t.lanes=o,t}function Yu(t,n,o){return n=kn(4,t.children!==null?t.children:[],t.key,n),n.lanes=o,n.stateNode={containerInfo:t.containerInfo,pendingChildren:null,implementation:t.implementation},n}function O0(t,n,o,s,d){this.tag=n,this.containerInfo=t,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=Es(0),this.expirationTimes=Es(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Es(0),this.identifierPrefix=s,this.onRecoverableError=d,this.mutableSourceEagerHydrationData=null}function Xu(t,n,o,s,d,h,w,E,_){return t=new O0(t,n,o,E,_),n===1?(n=1,h===!0&&(n|=8)):n=0,h=kn(3,null,null,n),t.current=h,h.stateNode=t,h.memoizedState={element:s,isDehydrated:o,cache:null,transitions:null,pendingSuspenseBoundaries:null},cu(h),t}function F0(t,n,o){var s=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:B,key:s==null?null:""+s,children:t,containerInfo:n,implementation:o}}function Oh(t){if(!t)return Rr;t=t._reactInternals;e:{if(pe(t)!==t||t.tag!==1)throw Error(i(170));var n=t;do{switch(n.tag){case 3:n=n.stateNode.context;break e;case 1:if(Kt(n.type)){n=n.stateNode.__reactInternalMemoizedMergedChildContext;break e}}n=n.return}while(n!==null);throw Error(i(171))}if(t.tag===1){var o=t.type;if(Kt(o))return ff(t,o,n)}return n}function Fh(t,n,o,s,d,h,w,E,_){return t=Xu(o,s,!0,t,d,h,w,E,_),t.context=Oh(null),o=t.current,s=Wt(),d=Or(o),h=ur(s,d),h.callback=n??null,Mr(o,h,d),t.current.lanes=d,Tl(t,d,s),Xt(t,s),t}function Oa(t,n,o,s){var d=n.current,h=Wt(),w=Or(d);return o=Oh(o),n.context===null?n.context=o:n.pendingContext=o,n=ur(h,w),n.payload={element:t},s=s===void 0?null:s,s!==null&&(n.callback=s),t=Mr(d,n,w),t!==null&&(In(t,d,w,h),ma(t,d,w)),w}function Fa(t){if(t=t.current,!t.child)return null;switch(t.child.tag){case 5:return t.child.stateNode;default:return t.child.stateNode}}function Uh(t,n){if(t=t.memoizedState,t!==null&&t.dehydrated!==null){var o=t.retryLane;t.retryLane=o!==0&&o<n?o:n}}function Ju(t,n){Uh(t,n),(t=t.alternate)&&Uh(t,n)}function U0(){return null}var Bh=typeof reportError=="function"?reportError:function(t){console.error(t)};function Zu(t){this._internalRoot=t}Ua.prototype.render=Zu.prototype.render=function(t){var n=this._internalRoot;if(n===null)throw Error(i(409));Oa(t,n,null,null)},Ua.prototype.unmount=Zu.prototype.unmount=function(){var t=this._internalRoot;if(t!==null){this._internalRoot=null;var n=t.containerInfo;xi(function(){Oa(null,t,null,null)}),n[ir]=null}};function Ua(t){this._internalRoot=t}Ua.prototype.unstable_scheduleHydration=function(t){if(t){var n=Ed();t={blockedOn:null,target:t,priority:n};for(var o=0;o<Nr.length&&n!==0&&n<Nr[o].priority;o++);Nr.splice(o,0,t),o===0&&Nd(t)}};function ec(t){return!(!t||t.nodeType!==1&&t.nodeType!==9&&t.nodeType!==11)}function Ba(t){return!(!t||t.nodeType!==1&&t.nodeType!==9&&t.nodeType!==11&&(t.nodeType!==8||t.nodeValue!==" react-mount-point-unstable "))}function Hh(){}function B0(t,n,o,s,d){if(d){if(typeof s=="function"){var h=s;s=function(){var H=Fa(w);h.call(H)}}var w=Fh(n,s,t,0,null,!1,!1,"",Hh);return t._reactRootContainer=w,t[ir]=w.current,$l(t.nodeType===8?t.parentNode:t),xi(),w}for(;d=t.lastChild;)t.removeChild(d);if(typeof s=="function"){var E=s;s=function(){var H=Fa(_);E.call(H)}}var _=Xu(t,0,!1,null,null,!1,!1,"",Hh);return t._reactRootContainer=_,t[ir]=_.current,$l(t.nodeType===8?t.parentNode:t),xi(function(){Oa(n,_,o,s)}),_}function Ha(t,n,o,s,d){var h=o._reactRootContainer;if(h){var w=h;if(typeof d=="function"){var E=d;d=function(){var _=Fa(w);E.call(_)}}Oa(n,w,t,d)}else w=B0(o,n,t,d,s);return Fa(w)}kd=function(t){switch(t.tag){case 3:var n=t.stateNode;if(n.current.memoizedState.isDehydrated){var o=_l(n.pendingLanes);o!==0&&(Cs(n,o|1),Xt(n,Ge()),(Ke&6)===0&&(ll=Ge()+500,Lr()))}break;case 13:xi(function(){var s=sr(t,1);if(s!==null){var d=Wt();In(s,t,1,d)}}),Ju(t,1)}},bs=function(t){if(t.tag===13){var n=sr(t,134217728);if(n!==null){var o=Wt();In(n,t,134217728,o)}Ju(t,134217728)}},Sd=function(t){if(t.tag===13){var n=Or(t),o=sr(t,n);if(o!==null){var s=Wt();In(o,t,n,s)}Ju(t,n)}},Ed=function(){return et},Cd=function(t,n){var o=et;try{return et=t,n()}finally{et=o}},Ai=function(t,n,o){switch(n){case"input":if(xr(t,o),n=o.name,o.type==="radio"&&n!=null){for(o=t;o.parentNode;)o=o.parentNode;for(o=o.querySelectorAll("input[name="+JSON.stringify(""+n)+'][type="radio"]'),n=0;n<o.length;n++){var s=o[n];if(s!==t&&s.form===t.form){var d=la(s);if(!d)throw Error(i(90));kt(s),xr(s,d)}}}break;case"textarea":pn(t,o);break;case"select":n=o.value,n!=null&&On(t,!!o.multiple,n,!1)}},Pl=Wu,ai=xi;var H0={usingClientEntryPoint:!1,Events:[ql,Qi,la,Nl,Oo,Wu]},ao={findFiberByHostInstance:di,bundleType:0,version:"18.3.1",rendererPackageName:"react-dom"},V0={bundleType:ao.bundleType,version:ao.version,rendererPackageName:ao.rendererPackageName,rendererConfig:ao.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setErrorHandler:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:F.ReactCurrentDispatcher,findHostInstanceByFiber:function(t){return t=Ze(t),t===null?null:t.stateNode},findFiberByHostInstance:ao.findFiberByHostInstance||U0,findHostInstancesForRefresh:null,scheduleRefresh:null,scheduleRoot:null,setRefreshHandler:null,getCurrentFiber:null,reconcilerVersion:"18.3.1-next-f1338f8080-20240426"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var Va=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Va.isDisabled&&Va.supportsFiber)try{nt=Va.inject(V0),It=Va}catch{}}return Jt.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=H0,Jt.createPortal=function(t,n){var o=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!ec(n))throw Error(i(200));return F0(t,n,null,o)},Jt.createRoot=function(t,n){if(!ec(t))throw Error(i(299));var o=!1,s="",d=Bh;return n!=null&&(n.unstable_strictMode===!0&&(o=!0),n.identifierPrefix!==void 0&&(s=n.identifierPrefix),n.onRecoverableError!==void 0&&(d=n.onRecoverableError)),n=Xu(t,1,!1,null,null,o,!1,s,d),t[ir]=n.current,$l(t.nodeType===8?t.parentNode:t),new Zu(n)},Jt.findDOMNode=function(t){if(t==null)return null;if(t.nodeType===1)return t;var n=t._reactInternals;if(n===void 0)throw typeof t.render=="function"?Error(i(188)):(t=Object.keys(t).join(","),Error(i(268,t)));return t=Ze(n),t=t===null?null:t.stateNode,t},Jt.flushSync=function(t){return xi(t)},Jt.hydrate=function(t,n,o){if(!Ba(n))throw Error(i(200));return Ha(null,t,n,!0,o)},Jt.hydrateRoot=function(t,n,o){if(!ec(t))throw Error(i(405));var s=o!=null&&o.hydratedSources||null,d=!1,h="",w=Bh;if(o!=null&&(o.unstable_strictMode===!0&&(d=!0),o.identifierPrefix!==void 0&&(h=o.identifierPrefix),o.onRecoverableError!==void 0&&(w=o.onRecoverableError)),n=Fh(n,null,t,1,o??null,d,!1,h,w),t[ir]=n.current,$l(t),s)for(t=0;t<s.length;t++)o=s[t],d=o._getVersion,d=d(o._source),n.mutableSourceEagerHydrationData==null?n.mutableSourceEagerHydrationData=[o,d]:n.mutableSourceEagerHydrationData.push(o,d);return new Ua(n)},Jt.render=function(t,n,o){if(!Ba(n))throw Error(i(200));return Ha(null,t,n,!1,o)},Jt.unmountComponentAtNode=function(t){if(!Ba(t))throw Error(i(40));return t._reactRootContainer?(xi(function(){Ha(null,null,t,!1,function(){t._reactRootContainer=null,t[ir]=null})}),!0):!1},Jt.unstable_batchedUpdates=Wu,Jt.unstable_renderSubtreeIntoContainer=function(t,n,o,s){if(!Ba(o))throw Error(i(200));if(t==null||t._reactInternals===void 0)throw Error(i(38));return Ha(t,n,o,!1,s)},Jt.version="18.3.1-next-f1338f8080-20240426",Jt}var Xh;function zm(){if(Xh)return ic.exports;Xh=1;function e(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e)}catch(r){console.error(r)}}return e(),ic.exports=Z0(),ic.exports}var Dm=zm();const Am=ds(Dm),ev=Im({__proto__:null,default:Am},[Dm]);var Qa={},Jh;function tv(){if(Jh)return Qa;Jh=1;var e=zm();return Qa.createRoot=e.createRoot,Qa.hydrateRoot=e.hydrateRoot,Qa}var nv=tv();/**
|
|
41
|
+
* @remix-run/router v1.23.2
|
|
42
|
+
*
|
|
43
|
+
* Copyright (c) Remix Software Inc.
|
|
44
|
+
*
|
|
45
|
+
* This source code is licensed under the MIT license found in the
|
|
46
|
+
* LICENSE.md file in the root directory of this source tree.
|
|
47
|
+
*
|
|
48
|
+
* @license MIT
|
|
49
|
+
*/function ft(){return ft=Object.assign?Object.assign.bind():function(e){for(var r=1;r<arguments.length;r++){var i=arguments[r];for(var l in i)Object.prototype.hasOwnProperty.call(i,l)&&(e[l]=i[l])}return e},ft.apply(this,arguments)}var bt;(function(e){e.Pop="POP",e.Push="PUSH",e.Replace="REPLACE"})(bt||(bt={}));const Zh="popstate";function rv(e){e===void 0&&(e={});function r(l,a){let{pathname:u,search:c,hash:f}=l.location;return Eo("",{pathname:u,search:c,hash:f},a.state&&a.state.usr||null,a.state&&a.state.key||"default")}function i(l,a){return typeof a=="string"?a:Ii(a)}return lv(r,i,null,e)}function Be(e,r){if(e===!1||e===null||typeof e>"u")throw new Error(r)}function Li(e,r){if(!e){typeof console<"u"&&console.warn(r);try{throw new Error(r)}catch{}}}function iv(){return Math.random().toString(36).substr(2,8)}function ep(e,r){return{usr:e.state,key:e.key,idx:r}}function Eo(e,r,i,l){return i===void 0&&(i=null),ft({pathname:typeof e=="string"?e:e.pathname,search:"",hash:""},typeof r=="string"?ti(r):r,{state:i,key:r&&r.key||l||iv()})}function Ii(e){let{pathname:r="/",search:i="",hash:l=""}=e;return i&&i!=="?"&&(r+=i.charAt(0)==="?"?i:"?"+i),l&&l!=="#"&&(r+=l.charAt(0)==="#"?l:"#"+l),r}function ti(e){let r={};if(e){let i=e.indexOf("#");i>=0&&(r.hash=e.substr(i),e=e.substr(0,i));let l=e.indexOf("?");l>=0&&(r.search=e.substr(l),e=e.substr(0,l)),e&&(r.pathname=e)}return r}function lv(e,r,i,l){l===void 0&&(l={});let{window:a=document.defaultView,v5Compat:u=!1}=l,c=a.history,f=bt.Pop,p=null,m=g();m==null&&(m=0,c.replaceState(ft({},c.state,{idx:m}),""));function g(){return(c.state||{idx:null}).idx}function y(){f=bt.Pop;let b=g(),P=b==null?null:b-m;m=b,p&&p({action:f,location:N.location,delta:P})}function k(b,P){f=bt.Push;let z=Eo(N.location,b,P);m=g()+1;let I=ep(z,m),F=N.createHref(z);try{c.pushState(I,"",F)}catch(ee){if(ee instanceof DOMException&&ee.name==="DataCloneError")throw ee;a.location.assign(F)}u&&p&&p({action:f,location:N.location,delta:1})}function x(b,P){f=bt.Replace;let z=Eo(N.location,b,P);m=g();let I=ep(z,m),F=N.createHref(z);c.replaceState(I,"",F),u&&p&&p({action:f,location:N.location,delta:0})}function T(b){let P=a.location.origin!=="null"?a.location.origin:a.location.href,z=typeof b=="string"?b:Ii(b);return z=z.replace(/ $/,"%20"),Be(P,"No window.location.(origin|href) available to create URL for href: "+z),new URL(z,P)}let N={get action(){return f},get location(){return e(a,c)},listen(b){if(p)throw new Error("A history only accepts one active listener");return a.addEventListener(Zh,y),p=b,()=>{a.removeEventListener(Zh,y),p=null}},createHref(b){return r(a,b)},createURL:T,encodeLocation(b){let P=T(b);return{pathname:P.pathname,search:P.search,hash:P.hash}},push:k,replace:x,go(b){return c.go(b)}};return N}var tt;(function(e){e.data="data",e.deferred="deferred",e.redirect="redirect",e.error="error"})(tt||(tt={}));const ov=new Set(["lazy","caseSensitive","path","id","index","children"]);function av(e){return e.index===!0}function rs(e,r,i,l){return i===void 0&&(i=[]),l===void 0&&(l={}),e.map((a,u)=>{let c=[...i,String(u)],f=typeof a.id=="string"?a.id:c.join("-");if(Be(a.index!==!0||!a.children,"Cannot specify children on an index route"),Be(!l[f],'Found a route id collision on id "'+f+`". Route id's must be globally unique within Data Router usages`),av(a)){let p=ft({},a,r(a),{id:f});return l[f]=p,p}else{let p=ft({},a,r(a),{id:f,children:void 0});return l[f]=p,a.children&&(p.children=rs(a.children,r,c,l)),p}})}function Ei(e,r,i){return i===void 0&&(i="/"),ts(e,r,i,!1)}function ts(e,r,i,l){let a=typeof r=="string"?ti(r):r,u=gr(a.pathname||"/",i);if(u==null)return null;let c=Om(e);uv(c);let f=null;for(let p=0;f==null&&p<c.length;++p){let m=wv(u);f=vv(c[p],m,l)}return f}function sv(e,r){let{route:i,pathname:l,params:a}=e;return{id:i.id,pathname:l,params:a,data:r[i.id],handle:i.handle}}function Om(e,r,i,l){r===void 0&&(r=[]),i===void 0&&(i=[]),l===void 0&&(l="");let a=(u,c,f)=>{let p={relativePath:f===void 0?u.path||"":f,caseSensitive:u.caseSensitive===!0,childrenIndex:c,route:u};p.relativePath.startsWith("/")&&(Be(p.relativePath.startsWith(l),'Absolute route path "'+p.relativePath+'" nested under path '+('"'+l+'" is not valid. An absolute child route path ')+"must start with the combined path of all its parent routes."),p.relativePath=p.relativePath.slice(l.length));let m=mr([l,p.relativePath]),g=i.concat(p);u.children&&u.children.length>0&&(Be(u.index!==!0,"Index routes must not have child routes. Please remove "+('all child routes from route path "'+m+'".')),Om(u.children,r,g,m)),!(u.path==null&&!u.index)&&r.push({path:m,score:gv(m,u.index),routesMeta:g})};return e.forEach((u,c)=>{var f;if(u.path===""||!((f=u.path)!=null&&f.includes("?")))a(u,c);else for(let p of Fm(u.path))a(u,c,p)}),r}function Fm(e){let r=e.split("/");if(r.length===0)return[];let[i,...l]=r,a=i.endsWith("?"),u=i.replace(/\?$/,"");if(l.length===0)return a?[u,""]:[u];let c=Fm(l.join("/")),f=[];return f.push(...c.map(p=>p===""?u:[u,p].join("/"))),a&&f.push(...c),f.map(p=>e.startsWith("/")&&p===""?"/":p)}function uv(e){e.sort((r,i)=>r.score!==i.score?i.score-r.score:yv(r.routesMeta.map(l=>l.childrenIndex),i.routesMeta.map(l=>l.childrenIndex)))}const cv=/^:[\w-]+$/,dv=3,fv=2,hv=1,pv=10,mv=-2,tp=e=>e==="*";function gv(e,r){let i=e.split("/"),l=i.length;return i.some(tp)&&(l+=mv),r&&(l+=fv),i.filter(a=>!tp(a)).reduce((a,u)=>a+(cv.test(u)?dv:u===""?hv:pv),l)}function yv(e,r){return e.length===r.length&&e.slice(0,-1).every((l,a)=>l===r[a])?e[e.length-1]-r[r.length-1]:0}function vv(e,r,i){i===void 0&&(i=!1);let{routesMeta:l}=e,a={},u="/",c=[];for(let f=0;f<l.length;++f){let p=l[f],m=f===l.length-1,g=u==="/"?r:r.slice(u.length)||"/",y=is({path:p.relativePath,caseSensitive:p.caseSensitive,end:m},g),k=p.route;if(!y&&m&&i&&!l[l.length-1].route.index&&(y=is({path:p.relativePath,caseSensitive:p.caseSensitive,end:!1},g)),!y)return null;Object.assign(a,y.params),c.push({params:a,pathname:mr([u,y.pathname]),pathnameBase:Cv(mr([u,y.pathnameBase])),route:k}),y.pathnameBase!=="/"&&(u=mr([u,y.pathnameBase]))}return c}function is(e,r){typeof e=="string"&&(e={path:e,caseSensitive:!1,end:!0});let[i,l]=xv(e.path,e.caseSensitive,e.end),a=r.match(i);if(!a)return null;let u=a[0],c=u.replace(/(.)\/+$/,"$1"),f=a.slice(1);return{params:l.reduce((m,g,y)=>{let{paramName:k,isOptional:x}=g;if(k==="*"){let N=f[y]||"";c=u.slice(0,u.length-N.length).replace(/(.)\/+$/,"$1")}const T=f[y];return x&&!T?m[k]=void 0:m[k]=(T||"").replace(/%2F/g,"/"),m},{}),pathname:u,pathnameBase:c,pattern:e}}function xv(e,r,i){r===void 0&&(r=!1),i===void 0&&(i=!0),Li(e==="*"||!e.endsWith("*")||e.endsWith("/*"),'Route path "'+e+'" will be treated as if it were '+('"'+e.replace(/\*$/,"/*")+'" because the `*` character must ')+"always follow a `/` in the pattern. To get rid of this warning, "+('please change the route path to "'+e.replace(/\*$/,"/*")+'".'));let l=[],a="^"+e.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(c,f,p)=>(l.push({paramName:f,isOptional:p!=null}),p?"/?([^\\/]+)?":"/([^\\/]+)"));return e.endsWith("*")?(l.push({paramName:"*"}),a+=e==="*"||e==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):i?a+="\\/*$":e!==""&&e!=="/"&&(a+="(?:(?=\\/|$))"),[new RegExp(a,r?void 0:"i"),l]}function wv(e){try{return e.split("/").map(r=>decodeURIComponent(r).replace(/\//g,"%2F")).join("/")}catch(r){return Li(!1,'The URL path "'+e+'" could not be decoded because it is is a malformed URL segment. This is probably due to a bad percent '+("encoding ("+r+").")),e}}function gr(e,r){if(r==="/")return e;if(!e.toLowerCase().startsWith(r.toLowerCase()))return null;let i=r.endsWith("/")?r.length-1:r.length,l=e.charAt(i);return l&&l!=="/"?null:e.slice(i)||"/"}const kv=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,Sv=e=>kv.test(e);function Ev(e,r){r===void 0&&(r="/");let{pathname:i,search:l="",hash:a=""}=typeof e=="string"?ti(e):e,u;if(i)if(Sv(i))u=i;else{if(i.includes("//")){let c=i;i=i.replace(/\/\/+/g,"/"),Li(!1,"Pathnames cannot have embedded double slashes - normalizing "+(c+" -> "+i))}i.startsWith("/")?u=np(i.substring(1),"/"):u=np(i,r)}else u=r;return{pathname:u,search:bv(l),hash:Nv(a)}}function np(e,r){let i=r.replace(/\/+$/,"").split("/");return e.split("/").forEach(a=>{a===".."?i.length>1&&i.pop():a!=="."&&i.push(a)}),i.length>1?i.join("/"):"/"}function ac(e,r,i,l){return"Cannot include a '"+e+"' character in a manually specified "+("`to."+r+"` field ["+JSON.stringify(l)+"]. Please separate it out to the ")+("`to."+i+"` field. Alternatively you may provide the full path as ")+'a string in <Link to="..."> and the router will parse it for you.'}function Um(e){return e.filter((r,i)=>i===0||r.route.path&&r.route.path.length>0)}function qc(e,r){let i=Um(e);return r?i.map((l,a)=>a===i.length-1?l.pathname:l.pathnameBase):i.map(l=>l.pathnameBase)}function Kc(e,r,i,l){l===void 0&&(l=!1);let a;typeof e=="string"?a=ti(e):(a=ft({},e),Be(!a.pathname||!a.pathname.includes("?"),ac("?","pathname","search",a)),Be(!a.pathname||!a.pathname.includes("#"),ac("#","pathname","hash",a)),Be(!a.search||!a.search.includes("#"),ac("#","search","hash",a)));let u=e===""||a.pathname==="",c=u?"/":a.pathname,f;if(c==null)f=i;else{let y=r.length-1;if(!l&&c.startsWith("..")){let k=c.split("/");for(;k[0]==="..";)k.shift(),y-=1;a.pathname=k.join("/")}f=y>=0?r[y]:"/"}let p=Ev(a,f),m=c&&c!=="/"&&c.endsWith("/"),g=(u||c===".")&&i.endsWith("/");return!p.pathname.endsWith("/")&&(m||g)&&(p.pathname+="/"),p}const mr=e=>e.join("/").replace(/\/\/+/g,"/"),Cv=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),bv=e=>!e||e==="?"?"":e.startsWith("?")?e:"?"+e,Nv=e=>!e||e==="#"?"":e.startsWith("#")?e:"#"+e;class ls{constructor(r,i,l,a){a===void 0&&(a=!1),this.status=r,this.statusText=i||"",this.internal=a,l instanceof Error?(this.data=l.toString(),this.error=l):this.data=l}}function Co(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.internal=="boolean"&&"data"in e}const Bm=["post","put","patch","delete"],Pv=new Set(Bm),jv=["get",...Bm],_v=new Set(jv),Tv=new Set([301,302,303,307,308]),Rv=new Set([307,308]),sc={state:"idle",location:void 0,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0},Lv={state:"idle",data:void 0,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0},uo={state:"unblocked",proceed:void 0,reset:void 0,location:void 0},Gc=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,Iv=e=>({hasErrorBoundary:!!e.hasErrorBoundary}),Hm="remix-router-transitions";function Mv(e){const r=e.window?e.window:typeof window<"u"?window:void 0,i=typeof r<"u"&&typeof r.document<"u"&&typeof r.document.createElement<"u",l=!i;Be(e.routes.length>0,"You must provide a non-empty routes array to createRouter");let a;if(e.mapRouteProperties)a=e.mapRouteProperties;else if(e.detectErrorBoundary){let j=e.detectErrorBoundary;a=A=>({hasErrorBoundary:j(A)})}else a=Iv;let u={},c=rs(e.routes,a,void 0,u),f,p=e.basename||"/",m=e.dataStrategy||Ov,g=e.patchRoutesOnNavigation,y=ft({v7_fetcherPersist:!1,v7_normalizeFormMethod:!1,v7_partialHydration:!1,v7_prependBasename:!1,v7_relativeSplatPath:!1,v7_skipActionErrorRevalidation:!1},e.future),k=null,x=new Set,T=null,N=null,b=null,P=e.hydrationData!=null,z=Ei(c,e.history.location,p),I=!1,F=null;if(z==null&&!g){let j=en(404,{pathname:e.history.location.pathname}),{matches:A,route:V}=hp(c);z=A,F={[V.id]:j}}z&&!e.hydrationData&&ai(z,c,e.history.location.pathname).active&&(z=null);let ee;if(z)if(z.some(j=>j.route.lazy))ee=!1;else if(!z.some(j=>j.route.loader))ee=!0;else if(y.v7_partialHydration){let j=e.hydrationData?e.hydrationData.loaderData:null,A=e.hydrationData?e.hydrationData.errors:null;if(A){let V=z.findIndex(X=>A[X.route.id]!==void 0);ee=z.slice(0,V+1).every(X=>!Nc(X.route,j,A))}else ee=z.every(V=>!Nc(V.route,j,A))}else ee=e.hydrationData!=null;else if(ee=!1,z=[],y.v7_partialHydration){let j=ai(null,c,e.history.location.pathname);j.active&&j.matches&&(I=!0,z=j.matches)}let B,D={historyAction:e.history.action,location:e.history.location,matches:z,initialized:ee,navigation:sc,restoreScrollPosition:e.hydrationData!=null?!1:null,preventScrollReset:!1,revalidation:"idle",loaderData:e.hydrationData&&e.hydrationData.loaderData||{},actionData:e.hydrationData&&e.hydrationData.actionData||null,errors:e.hydrationData&&e.hydrationData.errors||F,fetchers:new Map,blockers:new Map},G=bt.Pop,le=!1,re,$=!1,K=new Map,Se=null,se=!1,ne=!1,be=[],_e=new Set,Y=new Map,ce=0,S=-1,R=new Map,q=new Set,C=new Map,Ce=new Map,Ne=new Set,ke=new Map,Fe=new Map,De;function qe(){if(k=e.history.listen(j=>{let{action:A,location:V,delta:X}=j;if(De){De(),De=void 0;return}Li(Fe.size===0||X!=null,"You are trying to use a blocker on a POP navigation to a location that was not created by @remix-run/router. This will fail silently in production. This can happen if you are navigating outside the router via `window.history.pushState`/`window.location.hash` instead of using router navigation APIs. This can also happen if you are using createHashRouter and the user manually changes the URL.");let ue=Ai({currentLocation:D.location,nextLocation:V,historyAction:A});if(ue&&X!=null){let we=new Promise(Te=>{De=Te});e.history.go(X*-1),wr(ue,{state:"blocked",location:V,proceed(){wr(ue,{state:"proceeding",proceed:void 0,reset:void 0,location:V}),we.then(()=>e.history.go(X))},reset(){let Te=new Map(D.blockers);Te.set(ue,uo),kt({blockers:Te})}});return}return ln(A,V)}),i){Jv(r,K);let j=()=>Zv(r,K);r.addEventListener("pagehide",j),Se=()=>r.removeEventListener("pagehide",j)}return D.initialized||ln(bt.Pop,D.location,{initialHydration:!0}),B}function mt(){k&&k(),Se&&Se(),x.clear(),re&&re.abort(),D.fetchers.forEach((j,A)=>gt(A)),D.blockers.forEach((j,A)=>At(A))}function Cn(j){return x.add(j),()=>x.delete(j)}function kt(j,A){A===void 0&&(A={}),D=ft({},D,j);let V=[],X=[];y.v7_fetcherPersist&&D.fetchers.forEach((ue,we)=>{ue.state==="idle"&&(Ne.has(we)?X.push(we):V.push(we))}),Ne.forEach(ue=>{!D.fetchers.has(ue)&&!Y.has(ue)&&X.push(ue)}),[...x].forEach(ue=>ue(D,{deletedFetchers:X,viewTransitionOpts:A.viewTransitionOpts,flushSync:A.flushSync===!0})),y.v7_fetcherPersist?(V.forEach(ue=>D.fetchers.delete(ue)),X.forEach(ue=>gt(ue))):X.forEach(ue=>Ne.delete(ue))}function rn(j,A,V){var X,ue;let{flushSync:we}=V===void 0?{}:V,Te=D.actionData!=null&&D.navigation.formMethod!=null&&Dn(D.navigation.formMethod)&&D.navigation.state==="loading"&&((X=j.state)==null?void 0:X._isRedirect)!==!0,me;A.actionData?Object.keys(A.actionData).length>0?me=A.actionData:me=null:Te?me=D.actionData:me=null;let ye=A.loaderData?dp(D.loaderData,A.loaderData,A.matches||[],A.errors):D.loaderData,fe=D.blockers;fe.size>0&&(fe=new Map(fe),fe.forEach((He,Nt)=>fe.set(Nt,uo)));let pe=le===!0||D.navigation.formMethod!=null&&Dn(D.navigation.formMethod)&&((ue=j.state)==null?void 0:ue._isRedirect)!==!0;f&&(c=f,f=void 0),se||G===bt.Pop||(G===bt.Push?e.history.push(j,j.state):G===bt.Replace&&e.history.replace(j,j.state));let ze;if(G===bt.Pop){let He=K.get(D.location.pathname);He&&He.has(j.pathname)?ze={currentLocation:D.location,nextLocation:j}:K.has(j.pathname)&&(ze={currentLocation:j,nextLocation:D.location})}else if($){let He=K.get(D.location.pathname);He?He.add(j.pathname):(He=new Set([j.pathname]),K.set(D.location.pathname,He)),ze={currentLocation:D.location,nextLocation:j}}kt(ft({},A,{actionData:me,loaderData:ye,historyAction:G,location:j,initialized:!0,navigation:sc,revalidation:"idle",restoreScrollPosition:Pl(j,A.matches||D.matches),preventScrollReset:pe,blockers:fe}),{viewTransitionOpts:ze,flushSync:we===!0}),G=bt.Pop,le=!1,$=!1,se=!1,ne=!1,be=[]}async function vr(j,A){if(typeof j=="number"){e.history.go(j);return}let V=bc(D.location,D.matches,p,y.v7_prependBasename,j,y.v7_relativeSplatPath,A==null?void 0:A.fromRouteId,A==null?void 0:A.relative),{path:X,submission:ue,error:we}=rp(y.v7_normalizeFormMethod,!1,V,A),Te=D.location,me=Eo(D.location,X,A&&A.state);me=ft({},me,e.history.encodeLocation(me));let ye=A&&A.replace!=null?A.replace:void 0,fe=bt.Push;ye===!0?fe=bt.Replace:ye===!1||ue!=null&&Dn(ue.formMethod)&&ue.formAction===D.location.pathname+D.location.search&&(fe=bt.Replace);let pe=A&&"preventScrollReset"in A?A.preventScrollReset===!0:void 0,ze=(A&&A.flushSync)===!0,He=Ai({currentLocation:Te,nextLocation:me,historyAction:fe});if(He){wr(He,{state:"blocked",location:me,proceed(){wr(He,{state:"proceeding",proceed:void 0,reset:void 0,location:me}),vr(j,A)},reset(){let Nt=new Map(D.blockers);Nt.set(He,uo),kt({blockers:Nt})}});return}return await ln(fe,me,{submission:ue,pendingError:we,preventScrollReset:pe,replace:A&&A.replace,enableViewTransition:A&&A.viewTransition,flushSync:ze})}function li(){if(ae(),kt({revalidation:"loading"}),D.navigation.state!=="submitting"){if(D.navigation.state==="idle"){ln(D.historyAction,D.location,{startUninterruptedRevalidation:!0});return}ln(G||D.historyAction,D.navigation.location,{overrideNavigation:D.navigation,enableViewTransition:$===!0})}}async function ln(j,A,V){re&&re.abort(),re=null,G=j,se=(V&&V.startUninterruptedRevalidation)===!0,Oo(D.location,D.matches),le=(V&&V.preventScrollReset)===!0,$=(V&&V.enableViewTransition)===!0;let X=f||c,ue=V&&V.overrideNavigation,we=V!=null&&V.initialHydration&&D.matches&&D.matches.length>0&&!I?D.matches:Ei(X,A,p),Te=(V&&V.flushSync)===!0;if(we&&D.initialized&&!ne&&$v(D.location,A)&&!(V&&V.submission&&Dn(V.submission.formMethod))){rn(A,{matches:we},{flushSync:Te});return}let me=ai(we,X,A.pathname);if(me.active&&me.matches&&(we=me.matches),!we){let{error:Ze,notFoundMatches:Qe,route:at}=Bn(A.pathname);rn(A,{matches:Qe,loaderData:{},errors:{[at.id]:Ze}},{flushSync:Te});return}re=new AbortController;let ye=al(e.history,A,re.signal,V&&V.submission),fe;if(V&&V.pendingError)fe=[Ci(we).route.id,{type:tt.error,error:V.pendingError}];else if(V&&V.submission&&Dn(V.submission.formMethod)){let Ze=await xr(ye,A,V.submission,we,me.active,{replace:V.replace,flushSync:Te});if(Ze.shortCircuited)return;if(Ze.pendingActionResult){let[Qe,at]=Ze.pendingActionResult;if(fn(at)&&Co(at.error)&&at.error.status===404){re=null,rn(A,{matches:Ze.matches,loaderData:{},errors:{[Qe]:at.error}});return}}we=Ze.matches||we,fe=Ze.pendingActionResult,ue=uc(A,V.submission),Te=!1,me.active=!1,ye=al(e.history,ye.url,ye.signal)}let{shortCircuited:pe,matches:ze,loaderData:He,errors:Nt}=await zi(ye,A,we,me.active,ue,V&&V.submission,V&&V.fetcherSubmission,V&&V.replace,V&&V.initialHydration===!0,Te,fe);pe||(re=null,rn(A,ft({matches:ze||we},fp(fe),{loaderData:He,errors:Nt})))}async function xr(j,A,V,X,ue,we){we===void 0&&(we={}),ae();let Te=Yv(A,V);if(kt({navigation:Te},{flushSync:we.flushSync===!0}),ue){let fe=await kr(X,A.pathname,j.signal);if(fe.type==="aborted")return{shortCircuited:!0};if(fe.type==="error"){let pe=Ci(fe.partialMatches).route.id;return{matches:fe.partialMatches,pendingActionResult:[pe,{type:tt.error,error:fe.error}]}}else if(fe.matches)X=fe.matches;else{let{notFoundMatches:pe,error:ze,route:He}=Bn(A.pathname);return{matches:pe,pendingActionResult:[He.id,{type:tt.error,error:ze}]}}}let me,ye=xo(X,A);if(!ye.route.action&&!ye.route.lazy)me={type:tt.error,error:en(405,{method:j.method,pathname:A.pathname,routeId:ye.route.id})};else if(me=(await Fn("action",D,j,[ye],X,null))[ye.route.id],j.signal.aborted)return{shortCircuited:!0};if(bi(me)){let fe;return we&&we.replace!=null?fe=we.replace:fe=sp(me.response.headers.get("Location"),new URL(j.url),p,e.history)===D.location.pathname+D.location.search,await pn(j,me,!0,{submission:V,replace:fe}),{shortCircuited:!0}}if(ei(me))throw en(400,{type:"defer-action"});if(fn(me)){let fe=Ci(X,ye.route.id);return(we&&we.replace)!==!0&&(G=bt.Push),{matches:X,pendingActionResult:[fe.route.id,me]}}return{matches:X,pendingActionResult:[ye.route.id,me]}}async function zi(j,A,V,X,ue,we,Te,me,ye,fe,pe){let ze=ue||uc(A,we),He=we||Te||mp(ze),Nt=!se&&(!y.v7_partialHydration||!ye);if(X){if(Nt){let nt=er(pe);kt(ft({navigation:ze},nt!==void 0?{actionData:nt}:{}),{flushSync:fe})}let $e=await kr(V,A.pathname,j.signal);if($e.type==="aborted")return{shortCircuited:!0};if($e.type==="error"){let nt=Ci($e.partialMatches).route.id;return{matches:$e.partialMatches,loaderData:{},errors:{[nt]:$e.error}}}else if($e.matches)V=$e.matches;else{let{error:nt,notFoundMatches:It,route:ci}=Bn(A.pathname);return{matches:It,loaderData:{},errors:{[ci.id]:nt}}}}let Ze=f||c,[Qe,at]=lp(e.history,D,V,He,A,y.v7_partialHydration&&ye===!0,y.v7_skipActionErrorRevalidation,ne,be,_e,Ne,C,q,Ze,p,pe);if(Hn($e=>!(V&&V.some(nt=>nt.route.id===$e))||Qe&&Qe.some(nt=>nt.route.id===$e)),S=++ce,Qe.length===0&&at.length===0){let $e=Un();return rn(A,ft({matches:V,loaderData:{},errors:pe&&fn(pe[1])?{[pe[0]]:pe[1].error}:null},fp(pe),$e?{fetchers:new Map(D.fetchers)}:{}),{flushSync:fe}),{shortCircuited:!0}}if(Nt){let $e={};if(!X){$e.navigation=ze;let nt=er(pe);nt!==void 0&&($e.actionData=nt)}at.length>0&&($e.fetchers=An(at)),kt($e,{flushSync:fe})}at.forEach($e=>{xt($e.key),$e.controller&&Y.set($e.key,$e.controller)});let tr=()=>at.forEach($e=>xt($e.key));re&&re.signal.addEventListener("abort",tr);let{loaderResults:ui,fetcherResults:Pn}=await W(D,V,Qe,at,j);if(j.signal.aborted)return{shortCircuited:!0};re&&re.signal.removeEventListener("abort",tr),at.forEach($e=>Y.delete($e.key));let Ge=qa(ui);if(Ge)return await pn(j,Ge.result,!0,{replace:me}),{shortCircuited:!0};if(Ge=qa(Pn),Ge)return q.add(Ge.key),await pn(j,Ge.result,!0,{replace:me}),{shortCircuited:!0};let{loaderData:jl,errors:nr}=cp(D,V,ui,pe,at,Pn,ke);ke.forEach(($e,nt)=>{$e.subscribe(It=>{(It||$e.done)&&ke.delete(nt)})}),y.v7_partialHydration&&ye&&D.errors&&(nr=ft({},D.errors,nr));let Vn=Un(),rr=St(S),Oi=Vn||rr||at.length>0;return ft({matches:V,loaderData:jl,errors:nr},Oi?{fetchers:new Map(D.fetchers)}:{})}function er(j){if(j&&!fn(j[1]))return{[j[0]]:j[1].data};if(D.actionData)return Object.keys(D.actionData).length===0?null:D.actionData}function An(j){return j.forEach(A=>{let V=D.fetchers.get(A.key),X=co(void 0,V?V.data:void 0);D.fetchers.set(A.key,X)}),new Map(D.fetchers)}function On(j,A,V,X){if(l)throw new Error("router.fetch() was called during the server render, but it shouldn't be. You are likely calling a useFetcher() method in the body of your component. Try moving it to a useEffect or a callback.");xt(j);let ue=(X&&X.flushSync)===!0,we=f||c,Te=bc(D.location,D.matches,p,y.v7_prependBasename,V,y.v7_relativeSplatPath,A,X==null?void 0:X.relative),me=Ei(we,Te,p),ye=ai(me,we,Te);if(ye.active&&ye.matches&&(me=ye.matches),!me){Re(j,A,en(404,{pathname:Te}),{flushSync:ue});return}let{path:fe,submission:pe,error:ze}=rp(y.v7_normalizeFormMethod,!0,Te,X);if(ze){Re(j,A,ze,{flushSync:ue});return}let He=xo(me,fe),Nt=(X&&X.preventScrollReset)===!0;if(pe&&Dn(pe.formMethod)){oi(j,A,fe,He,me,ye.active,ue,Nt,pe);return}C.set(j,{routeId:A,path:fe}),Di(j,A,fe,He,me,ye.active,ue,Nt,pe)}async function oi(j,A,V,X,ue,we,Te,me,ye){ae(),C.delete(j);function fe(Ye){if(!Ye.route.action&&!Ye.route.lazy){let Sr=en(405,{method:ye.formMethod,pathname:V,routeId:A});return Re(j,A,Sr,{flushSync:Te}),!0}return!1}if(!we&&fe(X))return;let pe=D.fetchers.get(j);Ee(j,Xv(ye,pe),{flushSync:Te});let ze=new AbortController,He=al(e.history,V,ze.signal,ye);if(we){let Ye=await kr(ue,new URL(He.url).pathname,He.signal,j);if(Ye.type==="aborted")return;if(Ye.type==="error"){Re(j,A,Ye.error,{flushSync:Te});return}else if(Ye.matches){if(ue=Ye.matches,X=xo(ue,V),fe(X))return}else{Re(j,A,en(404,{pathname:V}),{flushSync:Te});return}}Y.set(j,ze);let Nt=ce,Qe=(await Fn("action",D,He,[X],ue,j))[X.route.id];if(He.signal.aborted){Y.get(j)===ze&&Y.delete(j);return}if(y.v7_fetcherPersist&&Ne.has(j)){if(bi(Qe)||fn(Qe)){Ee(j,Qr(void 0));return}}else{if(bi(Qe))if(Y.delete(j),S>Nt){Ee(j,Qr(void 0));return}else return q.add(j),Ee(j,co(ye)),pn(He,Qe,!1,{fetcherSubmission:ye,preventScrollReset:me});if(fn(Qe)){Re(j,A,Qe.error);return}}if(ei(Qe))throw en(400,{type:"defer-action"});let at=D.navigation.location||D.location,tr=al(e.history,at,ze.signal),ui=f||c,Pn=D.navigation.state!=="idle"?Ei(ui,D.navigation.location,p):D.matches;Be(Pn,"Didn't find any matches after fetcher action");let Ge=++ce;R.set(j,Ge);let jl=co(ye,Qe.data);D.fetchers.set(j,jl);let[nr,Vn]=lp(e.history,D,Pn,ye,at,!1,y.v7_skipActionErrorRevalidation,ne,be,_e,Ne,C,q,ui,p,[X.route.id,Qe]);Vn.filter(Ye=>Ye.key!==j).forEach(Ye=>{let Sr=Ye.key,Uo=D.fetchers.get(Sr),ks=co(void 0,Uo?Uo.data:void 0);D.fetchers.set(Sr,ks),xt(Sr),Ye.controller&&Y.set(Sr,Ye.controller)}),kt({fetchers:new Map(D.fetchers)});let rr=()=>Vn.forEach(Ye=>xt(Ye.key));ze.signal.addEventListener("abort",rr);let{loaderResults:Oi,fetcherResults:$e}=await W(D,Pn,nr,Vn,tr);if(ze.signal.aborted)return;ze.signal.removeEventListener("abort",rr),R.delete(j),Y.delete(j),Vn.forEach(Ye=>Y.delete(Ye.key));let nt=qa(Oi);if(nt)return pn(tr,nt.result,!1,{preventScrollReset:me});if(nt=qa($e),nt)return q.add(nt.key),pn(tr,nt.result,!1,{preventScrollReset:me});let{loaderData:It,errors:ci}=cp(D,Pn,Oi,void 0,Vn,$e,ke);if(D.fetchers.has(j)){let Ye=Qr(Qe.data);D.fetchers.set(j,Ye)}St(Ge),D.navigation.state==="loading"&&Ge>S?(Be(G,"Expected pending action"),re&&re.abort(),rn(D.navigation.location,{matches:Pn,loaderData:It,errors:ci,fetchers:new Map(D.fetchers)})):(kt({errors:ci,loaderData:dp(D.loaderData,It,Pn,ci),fetchers:new Map(D.fetchers)}),ne=!1)}async function Di(j,A,V,X,ue,we,Te,me,ye){let fe=D.fetchers.get(j);Ee(j,co(ye,fe?fe.data:void 0),{flushSync:Te});let pe=new AbortController,ze=al(e.history,V,pe.signal);if(we){let Qe=await kr(ue,new URL(ze.url).pathname,ze.signal,j);if(Qe.type==="aborted")return;if(Qe.type==="error"){Re(j,A,Qe.error,{flushSync:Te});return}else if(Qe.matches)ue=Qe.matches,X=xo(ue,V);else{Re(j,A,en(404,{pathname:V}),{flushSync:Te});return}}Y.set(j,pe);let He=ce,Ze=(await Fn("loader",D,ze,[X],ue,j))[X.route.id];if(ei(Ze)&&(Ze=await Yc(Ze,ze.signal,!0)||Ze),Y.get(j)===pe&&Y.delete(j),!ze.signal.aborted){if(Ne.has(j)){Ee(j,Qr(void 0));return}if(bi(Ze))if(S>He){Ee(j,Qr(void 0));return}else{q.add(j),await pn(ze,Ze,!1,{preventScrollReset:me});return}if(fn(Ze)){Re(j,A,Ze.error);return}Be(!ei(Ze),"Unhandled fetcher deferred data"),Ee(j,Qr(Ze.data))}}async function pn(j,A,V,X){let{submission:ue,fetcherSubmission:we,preventScrollReset:Te,replace:me}=X===void 0?{}:X;A.response.headers.has("X-Remix-Revalidate")&&(ne=!0);let ye=A.response.headers.get("Location");Be(ye,"Expected a Location header on the redirect Response"),ye=sp(ye,new URL(j.url),p,e.history);let fe=Eo(D.location,ye,{_isRedirect:!0});if(i){let Qe=!1;if(A.response.headers.has("X-Remix-Reload-Document"))Qe=!0;else if(Gc.test(ye)){const at=e.history.createURL(ye);Qe=at.origin!==r.location.origin||gr(at.pathname,p)==null}if(Qe){me?r.location.replace(ye):r.location.assign(ye);return}}re=null;let pe=me===!0||A.response.headers.has("X-Remix-Replace")?bt.Replace:bt.Push,{formMethod:ze,formAction:He,formEncType:Nt}=D.navigation;!ue&&!we&&ze&&He&&Nt&&(ue=mp(D.navigation));let Ze=ue||we;if(Rv.has(A.response.status)&&Ze&&Dn(Ze.formMethod))await ln(pe,fe,{submission:ft({},Ze,{formAction:ye}),preventScrollReset:Te||le,enableViewTransition:V?$:void 0});else{let Qe=uc(fe,ue);await ln(pe,fe,{overrideNavigation:Qe,fetcherSubmission:we,preventScrollReset:Te||le,enableViewTransition:V?$:void 0})}}async function Fn(j,A,V,X,ue,we){let Te,me={};try{Te=await Fv(m,j,A,V,X,ue,we,u,a)}catch(ye){return X.forEach(fe=>{me[fe.route.id]={type:tt.error,error:ye}}),me}for(let[ye,fe]of Object.entries(Te))if(Wv(fe)){let pe=fe.result;me[ye]={type:tt.redirect,response:Hv(pe,V,ye,ue,p,y.v7_relativeSplatPath)}}else me[ye]=await Bv(fe);return me}async function W(j,A,V,X,ue){let we=j.matches,Te=Fn("loader",j,ue,V,A,null),me=Promise.all(X.map(async pe=>{if(pe.matches&&pe.match&&pe.controller){let He=(await Fn("loader",j,al(e.history,pe.path,pe.controller.signal),[pe.match],pe.matches,pe.key))[pe.match.route.id];return{[pe.key]:He}}else return Promise.resolve({[pe.key]:{type:tt.error,error:en(404,{pathname:pe.path})}})})),ye=await Te,fe=(await me).reduce((pe,ze)=>Object.assign(pe,ze),{});return await Promise.all([Kv(A,ye,ue.signal,we,j.loaderData),Gv(A,fe,X)]),{loaderResults:ye,fetcherResults:fe}}function ae(){ne=!0,be.push(...Hn()),C.forEach((j,A)=>{Y.has(A)&&_e.add(A),xt(A)})}function Ee(j,A,V){V===void 0&&(V={}),D.fetchers.set(j,A),kt({fetchers:new Map(D.fetchers)},{flushSync:(V&&V.flushSync)===!0})}function Re(j,A,V,X){X===void 0&&(X={});let ue=Ci(D.matches,A);gt(j),kt({errors:{[ue.route.id]:V},fetchers:new Map(D.fetchers)},{flushSync:(X&&X.flushSync)===!0})}function Ve(j){return Ce.set(j,(Ce.get(j)||0)+1),Ne.has(j)&&Ne.delete(j),D.fetchers.get(j)||Lv}function gt(j){let A=D.fetchers.get(j);Y.has(j)&&!(A&&A.state==="loading"&&R.has(j))&&xt(j),C.delete(j),R.delete(j),q.delete(j),y.v7_fetcherPersist&&Ne.delete(j),_e.delete(j),D.fetchers.delete(j)}function bn(j){let A=(Ce.get(j)||0)-1;A<=0?(Ce.delete(j),Ne.add(j),y.v7_fetcherPersist||gt(j)):Ce.set(j,A),kt({fetchers:new Map(D.fetchers)})}function xt(j){let A=Y.get(j);A&&(A.abort(),Y.delete(j))}function Nn(j){for(let A of j){let V=Ve(A),X=Qr(V.data);D.fetchers.set(A,X)}}function Un(){let j=[],A=!1;for(let V of q){let X=D.fetchers.get(V);Be(X,"Expected fetcher: "+V),X.state==="loading"&&(q.delete(V),j.push(V),A=!0)}return Nn(j),A}function St(j){let A=[];for(let[V,X]of R)if(X<j){let ue=D.fetchers.get(V);Be(ue,"Expected fetcher: "+V),ue.state==="loading"&&(xt(V),R.delete(V),A.push(V))}return Nn(A),A.length>0}function mn(j,A){let V=D.blockers.get(j)||uo;return Fe.get(j)!==A&&Fe.set(j,A),V}function At(j){D.blockers.delete(j),Fe.delete(j)}function wr(j,A){let V=D.blockers.get(j)||uo;Be(V.state==="unblocked"&&A.state==="blocked"||V.state==="blocked"&&A.state==="blocked"||V.state==="blocked"&&A.state==="proceeding"||V.state==="blocked"&&A.state==="unblocked"||V.state==="proceeding"&&A.state==="unblocked","Invalid blocker state transition: "+V.state+" -> "+A.state);let X=new Map(D.blockers);X.set(j,A),kt({blockers:X})}function Ai(j){let{currentLocation:A,nextLocation:V,historyAction:X}=j;if(Fe.size===0)return;Fe.size>1&&Li(!1,"A router only supports one blocker at a time");let ue=Array.from(Fe.entries()),[we,Te]=ue[ue.length-1],me=D.blockers.get(we);if(!(me&&me.state==="proceeding")&&Te({currentLocation:A,nextLocation:V,historyAction:X}))return we}function Bn(j){let A=en(404,{pathname:j}),V=f||c,{matches:X,route:ue}=hp(V);return Hn(),{notFoundMatches:X,route:ue,error:A}}function Hn(j){let A=[];return ke.forEach((V,X)=>{(!j||j(X))&&(V.cancel(),A.push(X),ke.delete(X))}),A}function Ao(j,A,V){if(T=j,b=A,N=V||null,!P&&D.navigation===sc){P=!0;let X=Pl(D.location,D.matches);X!=null&&kt({restoreScrollPosition:X})}return()=>{T=null,b=null,N=null}}function Nl(j,A){return N&&N(j,A.map(X=>sv(X,D.loaderData)))||j.key}function Oo(j,A){if(T&&b){let V=Nl(j,A);T[V]=b()}}function Pl(j,A){if(T){let V=Nl(j,A),X=T[V];if(typeof X=="number")return X}return null}function ai(j,A,V){if(g)if(j){if(Object.keys(j[0].params).length>0)return{active:!0,matches:ts(A,V,p,!0)}}else return{active:!0,matches:ts(A,V,p,!0)||[]};return{active:!1,matches:null}}async function kr(j,A,V,X){if(!g)return{type:"success",matches:j};let ue=j;for(;;){let we=f==null,Te=f||c,me=u;try{await g({signal:V,path:A,matches:ue,fetcherKey:X,patch:(pe,ze)=>{V.aborted||ap(pe,ze,Te,me,a)}})}catch(pe){return{type:"error",error:pe,partialMatches:ue}}finally{we&&!V.aborted&&(c=[...c])}if(V.aborted)return{type:"aborted"};let ye=Ei(Te,A,p);if(ye)return{type:"success",matches:ye};let fe=ts(Te,A,p,!0);if(!fe||ue.length===fe.length&&ue.every((pe,ze)=>pe.route.id===fe[ze].route.id))return{type:"success",matches:null};ue=fe}}function Fo(j){u={},f=rs(j,a,void 0,u)}function si(j,A){let V=f==null;ap(j,A,f||c,u,a),V&&(c=[...c],kt({}))}return B={get basename(){return p},get future(){return y},get state(){return D},get routes(){return c},get window(){return r},initialize:qe,subscribe:Cn,enableScrollRestoration:Ao,navigate:vr,fetch:On,revalidate:li,createHref:j=>e.history.createHref(j),encodeLocation:j=>e.history.encodeLocation(j),getFetcher:Ve,deleteFetcher:bn,dispose:mt,getBlocker:mn,deleteBlocker:At,patchRoutes:si,_internalFetchControllers:Y,_internalActiveDeferreds:ke,_internalSetRoutes:Fo},B}function zv(e){return e!=null&&("formData"in e&&e.formData!=null||"body"in e&&e.body!==void 0)}function bc(e,r,i,l,a,u,c,f){let p,m;if(c){p=[];for(let y of r)if(p.push(y),y.route.id===c){m=y;break}}else p=r,m=r[r.length-1];let g=Kc(a||".",qc(p,u),gr(e.pathname,i)||e.pathname,f==="path");if(a==null&&(g.search=e.search,g.hash=e.hash),(a==null||a===""||a===".")&&m){let y=Xc(g.search);if(m.route.index&&!y)g.search=g.search?g.search.replace(/^\?/,"?index&"):"?index";else if(!m.route.index&&y){let k=new URLSearchParams(g.search),x=k.getAll("index");k.delete("index"),x.filter(N=>N).forEach(N=>k.append("index",N));let T=k.toString();g.search=T?"?"+T:""}}return l&&i!=="/"&&(g.pathname=g.pathname==="/"?i:mr([i,g.pathname])),Ii(g)}function rp(e,r,i,l){if(!l||!zv(l))return{path:i};if(l.formMethod&&!qv(l.formMethod))return{path:i,error:en(405,{method:l.formMethod})};let a=()=>({path:i,error:en(400,{type:"invalid-body"})}),u=l.formMethod||"get",c=e?u.toUpperCase():u.toLowerCase(),f=Wm(i);if(l.body!==void 0){if(l.formEncType==="text/plain"){if(!Dn(c))return a();let k=typeof l.body=="string"?l.body:l.body instanceof FormData||l.body instanceof URLSearchParams?Array.from(l.body.entries()).reduce((x,T)=>{let[N,b]=T;return""+x+N+"="+b+`
|
|
50
|
+
`},""):String(l.body);return{path:i,submission:{formMethod:c,formAction:f,formEncType:l.formEncType,formData:void 0,json:void 0,text:k}}}else if(l.formEncType==="application/json"){if(!Dn(c))return a();try{let k=typeof l.body=="string"?JSON.parse(l.body):l.body;return{path:i,submission:{formMethod:c,formAction:f,formEncType:l.formEncType,formData:void 0,json:k,text:void 0}}}catch{return a()}}}Be(typeof FormData=="function","FormData is not available in this environment");let p,m;if(l.formData)p=Pc(l.formData),m=l.formData;else if(l.body instanceof FormData)p=Pc(l.body),m=l.body;else if(l.body instanceof URLSearchParams)p=l.body,m=up(p);else if(l.body==null)p=new URLSearchParams,m=new FormData;else try{p=new URLSearchParams(l.body),m=up(p)}catch{return a()}let g={formMethod:c,formAction:f,formEncType:l&&l.formEncType||"application/x-www-form-urlencoded",formData:m,json:void 0,text:void 0};if(Dn(g.formMethod))return{path:i,submission:g};let y=ti(i);return r&&y.search&&Xc(y.search)&&p.append("index",""),y.search="?"+p,{path:Ii(y),submission:g}}function ip(e,r,i){i===void 0&&(i=!1);let l=e.findIndex(a=>a.route.id===r);return l>=0?e.slice(0,i?l+1:l):e}function lp(e,r,i,l,a,u,c,f,p,m,g,y,k,x,T,N){let b=N?fn(N[1])?N[1].error:N[1].data:void 0,P=e.createURL(r.location),z=e.createURL(a),I=i;u&&r.errors?I=ip(i,Object.keys(r.errors)[0],!0):N&&fn(N[1])&&(I=ip(i,N[0]));let F=N?N[1].statusCode:void 0,ee=c&&F&&F>=400,B=I.filter((G,le)=>{let{route:re}=G;if(re.lazy)return!0;if(re.loader==null)return!1;if(u)return Nc(re,r.loaderData,r.errors);if(Dv(r.loaderData,r.matches[le],G)||p.some(Se=>Se===G.route.id))return!0;let $=r.matches[le],K=G;return op(G,ft({currentUrl:P,currentParams:$.params,nextUrl:z,nextParams:K.params},l,{actionResult:b,actionStatus:F,defaultShouldRevalidate:ee?!1:f||P.pathname+P.search===z.pathname+z.search||P.search!==z.search||Vm($,K)}))}),D=[];return y.forEach((G,le)=>{if(u||!i.some(se=>se.route.id===G.routeId)||g.has(le))return;let re=Ei(x,G.path,T);if(!re){D.push({key:le,routeId:G.routeId,path:G.path,matches:null,match:null,controller:null});return}let $=r.fetchers.get(le),K=xo(re,G.path),Se=!1;k.has(le)?Se=!1:m.has(le)?(m.delete(le),Se=!0):$&&$.state!=="idle"&&$.data===void 0?Se=f:Se=op(K,ft({currentUrl:P,currentParams:r.matches[r.matches.length-1].params,nextUrl:z,nextParams:i[i.length-1].params},l,{actionResult:b,actionStatus:F,defaultShouldRevalidate:ee?!1:f})),Se&&D.push({key:le,routeId:G.routeId,path:G.path,matches:re,match:K,controller:new AbortController})}),[B,D]}function Nc(e,r,i){if(e.lazy)return!0;if(!e.loader)return!1;let l=r!=null&&r[e.id]!==void 0,a=i!=null&&i[e.id]!==void 0;return!l&&a?!1:typeof e.loader=="function"&&e.loader.hydrate===!0?!0:!l&&!a}function Dv(e,r,i){let l=!r||i.route.id!==r.route.id,a=e[i.route.id]===void 0;return l||a}function Vm(e,r){let i=e.route.path;return e.pathname!==r.pathname||i!=null&&i.endsWith("*")&&e.params["*"]!==r.params["*"]}function op(e,r){if(e.route.shouldRevalidate){let i=e.route.shouldRevalidate(r);if(typeof i=="boolean")return i}return r.defaultShouldRevalidate}function ap(e,r,i,l,a){var u;let c;if(e){let m=l[e];Be(m,"No route found to patch children into: routeId = "+e),m.children||(m.children=[]),c=m.children}else c=i;let f=r.filter(m=>!c.some(g=>$m(m,g))),p=rs(f,a,[e||"_","patch",String(((u=c)==null?void 0:u.length)||"0")],l);c.push(...p)}function $m(e,r){return"id"in e&&"id"in r&&e.id===r.id?!0:e.index===r.index&&e.path===r.path&&e.caseSensitive===r.caseSensitive?(!e.children||e.children.length===0)&&(!r.children||r.children.length===0)?!0:e.children.every((i,l)=>{var a;return(a=r.children)==null?void 0:a.some(u=>$m(i,u))}):!1}async function Av(e,r,i){if(!e.lazy)return;let l=await e.lazy();if(!e.lazy)return;let a=i[e.id];Be(a,"No route found in manifest");let u={};for(let c in l){let p=a[c]!==void 0&&c!=="hasErrorBoundary";Li(!p,'Route "'+a.id+'" has a static property "'+c+'" defined but its lazy function is also returning a value for this property. '+('The lazy route property "'+c+'" will be ignored.')),!p&&!ov.has(c)&&(u[c]=l[c])}Object.assign(a,u),Object.assign(a,ft({},r(a),{lazy:void 0}))}async function Ov(e){let{matches:r}=e,i=r.filter(a=>a.shouldLoad);return(await Promise.all(i.map(a=>a.resolve()))).reduce((a,u,c)=>Object.assign(a,{[i[c].route.id]:u}),{})}async function Fv(e,r,i,l,a,u,c,f,p,m){let g=u.map(x=>x.route.lazy?Av(x.route,p,f):void 0),y=u.map((x,T)=>{let N=g[T],b=a.some(z=>z.route.id===x.route.id);return ft({},x,{shouldLoad:b,resolve:async z=>(z&&l.method==="GET"&&(x.route.lazy||x.route.loader)&&(b=!0),b?Uv(r,l,x,N,z,m):Promise.resolve({type:tt.data,result:void 0}))})}),k=await e({matches:y,request:l,params:u[0].params,fetcherKey:c,context:m});try{await Promise.all(g)}catch{}return k}async function Uv(e,r,i,l,a,u){let c,f,p=m=>{let g,y=new Promise((T,N)=>g=N);f=()=>g(),r.signal.addEventListener("abort",f);let k=T=>typeof m!="function"?Promise.reject(new Error("You cannot call the handler for a route which defines a boolean "+('"'+e+'" [routeId: '+i.route.id+"]"))):m({request:r,params:i.params,context:u},...T!==void 0?[T]:[]),x=(async()=>{try{return{type:"data",result:await(a?a(N=>k(N)):k())}}catch(T){return{type:"error",result:T}}})();return Promise.race([x,y])};try{let m=i.route[e];if(l)if(m){let g,[y]=await Promise.all([p(m).catch(k=>{g=k}),l]);if(g!==void 0)throw g;c=y}else if(await l,m=i.route[e],m)c=await p(m);else if(e==="action"){let g=new URL(r.url),y=g.pathname+g.search;throw en(405,{method:r.method,pathname:y,routeId:i.route.id})}else return{type:tt.data,result:void 0};else if(m)c=await p(m);else{let g=new URL(r.url),y=g.pathname+g.search;throw en(404,{pathname:y})}Be(c.result!==void 0,"You defined "+(e==="action"?"an action":"a loader")+" for route "+('"'+i.route.id+"\" but didn't return anything from your `"+e+"` ")+"function. Please return a value or `null`.")}catch(m){return{type:tt.error,result:m}}finally{f&&r.signal.removeEventListener("abort",f)}return c}async function Bv(e){let{result:r,type:i}=e;if(Qm(r)){let y;try{let k=r.headers.get("Content-Type");k&&/\bapplication\/json\b/.test(k)?r.body==null?y=null:y=await r.json():y=await r.text()}catch(k){return{type:tt.error,error:k}}return i===tt.error?{type:tt.error,error:new ls(r.status,r.statusText,y),statusCode:r.status,headers:r.headers}:{type:tt.data,data:y,statusCode:r.status,headers:r.headers}}if(i===tt.error){if(pp(r)){var l,a;if(r.data instanceof Error){var u,c;return{type:tt.error,error:r.data,statusCode:(u=r.init)==null?void 0:u.status,headers:(c=r.init)!=null&&c.headers?new Headers(r.init.headers):void 0}}return{type:tt.error,error:new ls(((l=r.init)==null?void 0:l.status)||500,void 0,r.data),statusCode:Co(r)?r.status:void 0,headers:(a=r.init)!=null&&a.headers?new Headers(r.init.headers):void 0}}return{type:tt.error,error:r,statusCode:Co(r)?r.status:void 0}}if(Qv(r)){var f,p;return{type:tt.deferred,deferredData:r,statusCode:(f=r.init)==null?void 0:f.status,headers:((p=r.init)==null?void 0:p.headers)&&new Headers(r.init.headers)}}if(pp(r)){var m,g;return{type:tt.data,data:r.data,statusCode:(m=r.init)==null?void 0:m.status,headers:(g=r.init)!=null&&g.headers?new Headers(r.init.headers):void 0}}return{type:tt.data,data:r}}function Hv(e,r,i,l,a,u){let c=e.headers.get("Location");if(Be(c,"Redirects returned/thrown from loaders/actions must have a Location header"),!Gc.test(c)){let f=l.slice(0,l.findIndex(p=>p.route.id===i)+1);c=bc(new URL(r.url),f,a,!0,c,u),e.headers.set("Location",c)}return e}function sp(e,r,i,l){let a=["about:","blob:","chrome:","chrome-untrusted:","content:","data:","devtools:","file:","filesystem:","javascript:"];if(Gc.test(e)){let u=e,c=u.startsWith("//")?new URL(r.protocol+u):new URL(u);if(a.includes(c.protocol))throw new Error("Invalid redirect location");let f=gr(c.pathname,i)!=null;if(c.origin===r.origin&&f)return c.pathname+c.search+c.hash}try{let u=l.createURL(e);if(a.includes(u.protocol))throw new Error("Invalid redirect location")}catch{}return e}function al(e,r,i,l){let a=e.createURL(Wm(r)).toString(),u={signal:i};if(l&&Dn(l.formMethod)){let{formMethod:c,formEncType:f}=l;u.method=c.toUpperCase(),f==="application/json"?(u.headers=new Headers({"Content-Type":f}),u.body=JSON.stringify(l.json)):f==="text/plain"?u.body=l.text:f==="application/x-www-form-urlencoded"&&l.formData?u.body=Pc(l.formData):u.body=l.formData}return new Request(a,u)}function Pc(e){let r=new URLSearchParams;for(let[i,l]of e.entries())r.append(i,typeof l=="string"?l:l.name);return r}function up(e){let r=new FormData;for(let[i,l]of e.entries())r.append(i,l);return r}function Vv(e,r,i,l,a){let u={},c=null,f,p=!1,m={},g=i&&fn(i[1])?i[1].error:void 0;return e.forEach(y=>{if(!(y.route.id in r))return;let k=y.route.id,x=r[k];if(Be(!bi(x),"Cannot handle redirect results in processLoaderData"),fn(x)){let T=x.error;g!==void 0&&(T=g,g=void 0),c=c||{};{let N=Ci(e,k);c[N.route.id]==null&&(c[N.route.id]=T)}u[k]=void 0,p||(p=!0,f=Co(x.error)?x.error.status:500),x.headers&&(m[k]=x.headers)}else ei(x)?(l.set(k,x.deferredData),u[k]=x.deferredData.data,x.statusCode!=null&&x.statusCode!==200&&!p&&(f=x.statusCode),x.headers&&(m[k]=x.headers)):(u[k]=x.data,x.statusCode&&x.statusCode!==200&&!p&&(f=x.statusCode),x.headers&&(m[k]=x.headers))}),g!==void 0&&i&&(c={[i[0]]:g},u[i[0]]=void 0),{loaderData:u,errors:c,statusCode:f||200,loaderHeaders:m}}function cp(e,r,i,l,a,u,c){let{loaderData:f,errors:p}=Vv(r,i,l,c);return a.forEach(m=>{let{key:g,match:y,controller:k}=m,x=u[g];if(Be(x,"Did not find corresponding fetcher result"),!(k&&k.signal.aborted))if(fn(x)){let T=Ci(e.matches,y==null?void 0:y.route.id);p&&p[T.route.id]||(p=ft({},p,{[T.route.id]:x.error})),e.fetchers.delete(g)}else if(bi(x))Be(!1,"Unhandled fetcher revalidation redirect");else if(ei(x))Be(!1,"Unhandled fetcher deferred data");else{let T=Qr(x.data);e.fetchers.set(g,T)}}),{loaderData:f,errors:p}}function dp(e,r,i,l){let a=ft({},r);for(let u of i){let c=u.route.id;if(r.hasOwnProperty(c)?r[c]!==void 0&&(a[c]=r[c]):e[c]!==void 0&&u.route.loader&&(a[c]=e[c]),l&&l.hasOwnProperty(c))break}return a}function fp(e){return e?fn(e[1])?{actionData:{}}:{actionData:{[e[0]]:e[1].data}}:{}}function Ci(e,r){return(r?e.slice(0,e.findIndex(l=>l.route.id===r)+1):[...e]).reverse().find(l=>l.route.hasErrorBoundary===!0)||e[0]}function hp(e){let r=e.length===1?e[0]:e.find(i=>i.index||!i.path||i.path==="/")||{id:"__shim-error-route__"};return{matches:[{params:{},pathname:"",pathnameBase:"",route:r}],route:r}}function en(e,r){let{pathname:i,routeId:l,method:a,type:u,message:c}=r===void 0?{}:r,f="Unknown Server Error",p="Unknown @remix-run/router error";return e===400?(f="Bad Request",a&&i&&l?p="You made a "+a+' request to "'+i+'" but '+('did not provide a `loader` for route "'+l+'", ')+"so there is no way to handle the request.":u==="defer-action"?p="defer() is not supported in actions":u==="invalid-body"&&(p="Unable to encode submission body")):e===403?(f="Forbidden",p='Route "'+l+'" does not match URL "'+i+'"'):e===404?(f="Not Found",p='No route matches URL "'+i+'"'):e===405&&(f="Method Not Allowed",a&&i&&l?p="You made a "+a.toUpperCase()+' request to "'+i+'" but '+('did not provide an `action` for route "'+l+'", ')+"so there is no way to handle the request.":a&&(p='Invalid request method "'+a.toUpperCase()+'"')),new ls(e||500,f,new Error(p),!0)}function qa(e){let r=Object.entries(e);for(let i=r.length-1;i>=0;i--){let[l,a]=r[i];if(bi(a))return{key:l,result:a}}}function Wm(e){let r=typeof e=="string"?ti(e):e;return Ii(ft({},r,{hash:""}))}function $v(e,r){return e.pathname!==r.pathname||e.search!==r.search?!1:e.hash===""?r.hash!=="":e.hash===r.hash?!0:r.hash!==""}function Wv(e){return Qm(e.result)&&Tv.has(e.result.status)}function ei(e){return e.type===tt.deferred}function fn(e){return e.type===tt.error}function bi(e){return(e&&e.type)===tt.redirect}function pp(e){return typeof e=="object"&&e!=null&&"type"in e&&"data"in e&&"init"in e&&e.type==="DataWithResponseInit"}function Qv(e){let r=e;return r&&typeof r=="object"&&typeof r.data=="object"&&typeof r.subscribe=="function"&&typeof r.cancel=="function"&&typeof r.resolveData=="function"}function Qm(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.headers=="object"&&typeof e.body<"u"}function qv(e){return _v.has(e.toLowerCase())}function Dn(e){return Pv.has(e.toLowerCase())}async function Kv(e,r,i,l,a){let u=Object.entries(r);for(let c=0;c<u.length;c++){let[f,p]=u[c],m=e.find(k=>(k==null?void 0:k.route.id)===f);if(!m)continue;let g=l.find(k=>k.route.id===m.route.id),y=g!=null&&!Vm(g,m)&&(a&&a[m.route.id])!==void 0;ei(p)&&y&&await Yc(p,i,!1).then(k=>{k&&(r[f]=k)})}}async function Gv(e,r,i){for(let l=0;l<i.length;l++){let{key:a,routeId:u,controller:c}=i[l],f=r[a];e.find(m=>(m==null?void 0:m.route.id)===u)&&ei(f)&&(Be(c,"Expected an AbortController for revalidating fetcher deferred result"),await Yc(f,c.signal,!0).then(m=>{m&&(r[a]=m)}))}}async function Yc(e,r,i){if(i===void 0&&(i=!1),!await e.deferredData.resolveData(r)){if(i)try{return{type:tt.data,data:e.deferredData.unwrappedData}}catch(a){return{type:tt.error,error:a}}return{type:tt.data,data:e.deferredData.data}}}function Xc(e){return new URLSearchParams(e).getAll("index").some(r=>r==="")}function xo(e,r){let i=typeof r=="string"?ti(r).search:r.search;if(e[e.length-1].route.index&&Xc(i||""))return e[e.length-1];let l=Um(e);return l[l.length-1]}function mp(e){let{formMethod:r,formAction:i,formEncType:l,text:a,formData:u,json:c}=e;if(!(!r||!i||!l)){if(a!=null)return{formMethod:r,formAction:i,formEncType:l,formData:void 0,json:void 0,text:a};if(u!=null)return{formMethod:r,formAction:i,formEncType:l,formData:u,json:void 0,text:void 0};if(c!==void 0)return{formMethod:r,formAction:i,formEncType:l,formData:void 0,json:c,text:void 0}}}function uc(e,r){return r?{state:"loading",location:e,formMethod:r.formMethod,formAction:r.formAction,formEncType:r.formEncType,formData:r.formData,json:r.json,text:r.text}:{state:"loading",location:e,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0}}function Yv(e,r){return{state:"submitting",location:e,formMethod:r.formMethod,formAction:r.formAction,formEncType:r.formEncType,formData:r.formData,json:r.json,text:r.text}}function co(e,r){return e?{state:"loading",formMethod:e.formMethod,formAction:e.formAction,formEncType:e.formEncType,formData:e.formData,json:e.json,text:e.text,data:r}:{state:"loading",formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0,data:r}}function Xv(e,r){return{state:"submitting",formMethod:e.formMethod,formAction:e.formAction,formEncType:e.formEncType,formData:e.formData,json:e.json,text:e.text,data:r?r.data:void 0}}function Qr(e){return{state:"idle",formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0,data:e}}function Jv(e,r){try{let i=e.sessionStorage.getItem(Hm);if(i){let l=JSON.parse(i);for(let[a,u]of Object.entries(l||{}))u&&Array.isArray(u)&&r.set(a,new Set(u||[]))}}catch{}}function Zv(e,r){if(r.size>0){let i={};for(let[l,a]of r)i[l]=[...a];try{e.sessionStorage.setItem(Hm,JSON.stringify(i))}catch(l){Li(!1,"Failed to save applied view transitions in sessionStorage ("+l+").")}}}/**
|
|
51
|
+
* React Router v6.30.3
|
|
52
|
+
*
|
|
53
|
+
* Copyright (c) Remix Software Inc.
|
|
54
|
+
*
|
|
55
|
+
* This source code is licensed under the MIT license found in the
|
|
56
|
+
* LICENSE.md file in the root directory of this source tree.
|
|
57
|
+
*
|
|
58
|
+
* @license MIT
|
|
59
|
+
*/function os(){return os=Object.assign?Object.assign.bind():function(e){for(var r=1;r<arguments.length;r++){var i=arguments[r];for(var l in i)Object.prototype.hasOwnProperty.call(i,l)&&(e[l]=i[l])}return e},os.apply(this,arguments)}const Lo=M.createContext(null),Jc=M.createContext(null),ni=M.createContext(null),Zc=M.createContext(null),yr=M.createContext({outlet:null,matches:[],isDataRoute:!1}),qm=M.createContext(null);function ex(e,r){let{relative:i}=r===void 0?{}:r;Io()||Be(!1);let{basename:l,navigator:a}=M.useContext(ni),{hash:u,pathname:c,search:f}=hs(e,{relative:i}),p=c;return l!=="/"&&(p=c==="/"?l:mr([l,c])),a.createHref({pathname:p,search:f,hash:u})}function Io(){return M.useContext(Zc)!=null}function ri(){return Io()||Be(!1),M.useContext(Zc).location}function Km(e){M.useContext(ni).static||M.useLayoutEffect(e)}function Sl(){let{isDataRoute:e}=M.useContext(yr);return e?px():tx()}function tx(){Io()||Be(!1);let e=M.useContext(Lo),{basename:r,future:i,navigator:l}=M.useContext(ni),{matches:a}=M.useContext(yr),{pathname:u}=ri(),c=JSON.stringify(qc(a,i.v7_relativeSplatPath)),f=M.useRef(!1);return Km(()=>{f.current=!0}),M.useCallback(function(m,g){if(g===void 0&&(g={}),!f.current)return;if(typeof m=="number"){l.go(m);return}let y=Kc(m,JSON.parse(c),u,g.relative==="path");e==null&&r!=="/"&&(y.pathname=y.pathname==="/"?r:mr([r,y.pathname])),(g.replace?l.replace:l.push)(y,g.state,g)},[r,l,c,u,e])}const nx=M.createContext(null);function rx(e){let r=M.useContext(yr).outlet;return r&&M.createElement(nx.Provider,{value:e},r)}function fs(){let{matches:e}=M.useContext(yr),r=e[e.length-1];return r?r.params:{}}function hs(e,r){let{relative:i}=r===void 0?{}:r,{future:l}=M.useContext(ni),{matches:a}=M.useContext(yr),{pathname:u}=ri(),c=JSON.stringify(qc(a,l.v7_relativeSplatPath));return M.useMemo(()=>Kc(e,JSON.parse(c),u,i==="path"),[e,c,u,i])}function ix(e,r,i,l){Io()||Be(!1);let{navigator:a}=M.useContext(ni),{matches:u}=M.useContext(yr),c=u[u.length-1],f=c?c.params:{};c&&c.pathname;let p=c?c.pathnameBase:"/";c&&c.route;let m=ri(),g;g=m;let y=g.pathname||"/",k=y;if(p!=="/"){let N=p.replace(/^\//,"").split("/");k="/"+y.replace(/^\//,"").split("/").slice(N.length).join("/")}let x=Ei(e,{pathname:k});return ux(x&&x.map(N=>Object.assign({},N,{params:Object.assign({},f,N.params),pathname:mr([p,a.encodeLocation?a.encodeLocation(N.pathname).pathname:N.pathname]),pathnameBase:N.pathnameBase==="/"?p:mr([p,a.encodeLocation?a.encodeLocation(N.pathnameBase).pathname:N.pathnameBase])})),u,i,l)}function lx(){let e=hx(),r=Co(e)?e.status+" "+e.statusText:e instanceof Error?e.message:JSON.stringify(e),i=e instanceof Error?e.stack:null,a={padding:"0.5rem",backgroundColor:"rgba(200,200,200, 0.5)"};return M.createElement(M.Fragment,null,M.createElement("h2",null,"Unexpected Application Error!"),M.createElement("h3",{style:{fontStyle:"italic"}},r),i?M.createElement("pre",{style:a},i):null,null)}const ox=M.createElement(lx,null);class ax extends M.Component{constructor(r){super(r),this.state={location:r.location,revalidation:r.revalidation,error:r.error}}static getDerivedStateFromError(r){return{error:r}}static getDerivedStateFromProps(r,i){return i.location!==r.location||i.revalidation!=="idle"&&r.revalidation==="idle"?{error:r.error,location:r.location,revalidation:r.revalidation}:{error:r.error!==void 0?r.error:i.error,location:i.location,revalidation:r.revalidation||i.revalidation}}componentDidCatch(r,i){console.error("React Router caught the following error during render",r,i)}render(){return this.state.error!==void 0?M.createElement(yr.Provider,{value:this.props.routeContext},M.createElement(qm.Provider,{value:this.state.error,children:this.props.component})):this.props.children}}function sx(e){let{routeContext:r,match:i,children:l}=e,a=M.useContext(Lo);return a&&a.static&&a.staticContext&&(i.route.errorElement||i.route.ErrorBoundary)&&(a.staticContext._deepestRenderedBoundaryId=i.route.id),M.createElement(yr.Provider,{value:r},l)}function ux(e,r,i,l){var a;if(r===void 0&&(r=[]),i===void 0&&(i=null),l===void 0&&(l=null),e==null){var u;if(!i)return null;if(i.errors)e=i.matches;else if((u=l)!=null&&u.v7_partialHydration&&r.length===0&&!i.initialized&&i.matches.length>0)e=i.matches;else return null}let c=e,f=(a=i)==null?void 0:a.errors;if(f!=null){let g=c.findIndex(y=>y.route.id&&(f==null?void 0:f[y.route.id])!==void 0);g>=0||Be(!1),c=c.slice(0,Math.min(c.length,g+1))}let p=!1,m=-1;if(i&&l&&l.v7_partialHydration)for(let g=0;g<c.length;g++){let y=c[g];if((y.route.HydrateFallback||y.route.hydrateFallbackElement)&&(m=g),y.route.id){let{loaderData:k,errors:x}=i,T=y.route.loader&&k[y.route.id]===void 0&&(!x||x[y.route.id]===void 0);if(y.route.lazy||T){p=!0,m>=0?c=c.slice(0,m+1):c=[c[0]];break}}}return c.reduceRight((g,y,k)=>{let x,T=!1,N=null,b=null;i&&(x=f&&y.route.id?f[y.route.id]:void 0,N=y.route.errorElement||ox,p&&(m<0&&k===0?(mx("route-fallback"),T=!0,b=null):m===k&&(T=!0,b=y.route.hydrateFallbackElement||null)));let P=r.concat(c.slice(0,k+1)),z=()=>{let I;return x?I=N:T?I=b:y.route.Component?I=M.createElement(y.route.Component,null):y.route.element?I=y.route.element:I=g,M.createElement(sx,{match:y,routeContext:{outlet:g,matches:P,isDataRoute:i!=null},children:I})};return i&&(y.route.ErrorBoundary||y.route.errorElement||k===0)?M.createElement(ax,{location:i.location,revalidation:i.revalidation,component:N,error:x,children:z(),routeContext:{outlet:null,matches:P,isDataRoute:!0}}):z()},null)}var Gm=function(e){return e.UseBlocker="useBlocker",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e}(Gm||{}),Ym=function(e){return e.UseBlocker="useBlocker",e.UseLoaderData="useLoaderData",e.UseActionData="useActionData",e.UseRouteError="useRouteError",e.UseNavigation="useNavigation",e.UseRouteLoaderData="useRouteLoaderData",e.UseMatches="useMatches",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e.UseRouteId="useRouteId",e}(Ym||{});function cx(e){let r=M.useContext(Lo);return r||Be(!1),r}function dx(e){let r=M.useContext(Jc);return r||Be(!1),r}function fx(e){let r=M.useContext(yr);return r||Be(!1),r}function Xm(e){let r=fx(),i=r.matches[r.matches.length-1];return i.route.id||Be(!1),i.route.id}function hx(){var e;let r=M.useContext(qm),i=dx(Ym.UseRouteError),l=Xm();return r!==void 0?r:(e=i.errors)==null?void 0:e[l]}function px(){let{router:e}=cx(Gm.UseNavigateStable),r=Xm(),i=M.useRef(!1);return Km(()=>{i.current=!0}),M.useCallback(function(a,u){u===void 0&&(u={}),i.current&&(typeof a=="number"?e.navigate(a):e.navigate(a,os({fromRouteId:r},u)))},[e,r])}const gp={};function mx(e,r,i){gp[e]||(gp[e]=!0)}function gx(e,r){e==null||e.v7_startTransition,(e==null?void 0:e.v7_relativeSplatPath)===void 0&&(!r||r.v7_relativeSplatPath),r&&(r.v7_fetcherPersist,r.v7_normalizeFormMethod,r.v7_partialHydration,r.v7_skipActionErrorRevalidation)}function yx(e){return rx(e.context)}function vx(e){let{basename:r="/",children:i=null,location:l,navigationType:a=bt.Pop,navigator:u,static:c=!1,future:f}=e;Io()&&Be(!1);let p=r.replace(/^\/*/,"/"),m=M.useMemo(()=>({basename:p,navigator:u,static:c,future:os({v7_relativeSplatPath:!1},f)}),[p,f,u,c]);typeof l=="string"&&(l=ti(l));let{pathname:g="/",search:y="",hash:k="",state:x=null,key:T="default"}=l,N=M.useMemo(()=>{let b=gr(g,p);return b==null?null:{location:{pathname:b,search:y,hash:k,state:x,key:T},navigationType:a}},[p,g,y,k,x,T,a]);return N==null?null:M.createElement(ni.Provider,{value:m},M.createElement(Zc.Provider,{children:i,value:N}))}new Promise(()=>{});function xx(e){let r={hasErrorBoundary:e.ErrorBoundary!=null||e.errorElement!=null};return e.Component&&Object.assign(r,{element:M.createElement(e.Component),Component:void 0}),e.HydrateFallback&&Object.assign(r,{hydrateFallbackElement:M.createElement(e.HydrateFallback),HydrateFallback:void 0}),e.ErrorBoundary&&Object.assign(r,{errorElement:M.createElement(e.ErrorBoundary),ErrorBoundary:void 0}),r}/**
|
|
60
|
+
* React Router DOM v6.30.3
|
|
61
|
+
*
|
|
62
|
+
* Copyright (c) Remix Software Inc.
|
|
63
|
+
*
|
|
64
|
+
* This source code is licensed under the MIT license found in the
|
|
65
|
+
* LICENSE.md file in the root directory of this source tree.
|
|
66
|
+
*
|
|
67
|
+
* @license MIT
|
|
68
|
+
*/function kl(){return kl=Object.assign?Object.assign.bind():function(e){for(var r=1;r<arguments.length;r++){var i=arguments[r];for(var l in i)Object.prototype.hasOwnProperty.call(i,l)&&(e[l]=i[l])}return e},kl.apply(this,arguments)}function Jm(e,r){if(e==null)return{};var i={},l=Object.keys(e),a,u;for(u=0;u<l.length;u++)a=l[u],!(r.indexOf(a)>=0)&&(i[a]=e[a]);return i}function wx(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}function kx(e,r){return e.button===0&&(!r||r==="_self")&&!wx(e)}function jc(e){return e===void 0&&(e=""),new URLSearchParams(typeof e=="string"||Array.isArray(e)||e instanceof URLSearchParams?e:Object.keys(e).reduce((r,i)=>{let l=e[i];return r.concat(Array.isArray(l)?l.map(a=>[i,a]):[[i,l]])},[]))}function Sx(e,r){let i=jc(e);return r&&r.forEach((l,a)=>{i.has(a)||r.getAll(a).forEach(u=>{i.append(a,u)})}),i}const Ex=["onClick","relative","reloadDocument","replace","state","target","to","preventScrollReset","viewTransition"],Cx=["aria-current","caseSensitive","className","end","style","to","viewTransition","children"],bx="6";try{window.__reactRouterVersion=bx}catch{}function Nx(e,r){return Mv({basename:void 0,future:kl({},void 0,{v7_prependBasename:!0}),history:rv({window:void 0}),hydrationData:Px(),routes:e,mapRouteProperties:xx,dataStrategy:void 0,patchRoutesOnNavigation:void 0,window:void 0}).initialize()}function Px(){var e;let r=(e=window)==null?void 0:e.__staticRouterHydrationData;return r&&r.errors&&(r=kl({},r,{errors:jx(r.errors)})),r}function jx(e){if(!e)return null;let r=Object.entries(e),i={};for(let[l,a]of r)if(a&&a.__type==="RouteErrorResponse")i[l]=new ls(a.status,a.statusText,a.data,a.internal===!0);else if(a&&a.__type==="Error"){if(a.__subType){let u=window[a.__subType];if(typeof u=="function")try{let c=new u(a.message);c.stack="",i[l]=c}catch{}}if(i[l]==null){let u=new Error(a.message);u.stack="",i[l]=u}}else i[l]=a;return i}const Zm=M.createContext({isTransitioning:!1}),_x=M.createContext(new Map),Tx="startTransition",yp=Y0[Tx],Rx="flushSync",vp=ev[Rx];function Lx(e){yp?yp(e):e()}function fo(e){vp?vp(e):e()}class Ix{constructor(){this.status="pending",this.promise=new Promise((r,i)=>{this.resolve=l=>{this.status==="pending"&&(this.status="resolved",r(l))},this.reject=l=>{this.status==="pending"&&(this.status="rejected",i(l))}})}}function Mx(e){let{fallbackElement:r,router:i,future:l}=e,[a,u]=M.useState(i.state),[c,f]=M.useState(),[p,m]=M.useState({isTransitioning:!1}),[g,y]=M.useState(),[k,x]=M.useState(),[T,N]=M.useState(),b=M.useRef(new Map),{v7_startTransition:P}=l||{},z=M.useCallback(G=>{P?Lx(G):G()},[P]),I=M.useCallback((G,le)=>{let{deletedFetchers:re,flushSync:$,viewTransitionOpts:K}=le;G.fetchers.forEach((se,ne)=>{se.data!==void 0&&b.current.set(ne,se.data)}),re.forEach(se=>b.current.delete(se));let Se=i.window==null||i.window.document==null||typeof i.window.document.startViewTransition!="function";if(!K||Se){$?fo(()=>u(G)):z(()=>u(G));return}if($){fo(()=>{k&&(g&&g.resolve(),k.skipTransition()),m({isTransitioning:!0,flushSync:!0,currentLocation:K.currentLocation,nextLocation:K.nextLocation})});let se=i.window.document.startViewTransition(()=>{fo(()=>u(G))});se.finished.finally(()=>{fo(()=>{y(void 0),x(void 0),f(void 0),m({isTransitioning:!1})})}),fo(()=>x(se));return}k?(g&&g.resolve(),k.skipTransition(),N({state:G,currentLocation:K.currentLocation,nextLocation:K.nextLocation})):(f(G),m({isTransitioning:!0,flushSync:!1,currentLocation:K.currentLocation,nextLocation:K.nextLocation}))},[i.window,k,g,b,z]);M.useLayoutEffect(()=>i.subscribe(I),[i,I]),M.useEffect(()=>{p.isTransitioning&&!p.flushSync&&y(new Ix)},[p]),M.useEffect(()=>{if(g&&c&&i.window){let G=c,le=g.promise,re=i.window.document.startViewTransition(async()=>{z(()=>u(G)),await le});re.finished.finally(()=>{y(void 0),x(void 0),f(void 0),m({isTransitioning:!1})}),x(re)}},[z,c,g,i.window]),M.useEffect(()=>{g&&c&&a.location.key===c.location.key&&g.resolve()},[g,k,a.location,c]),M.useEffect(()=>{!p.isTransitioning&&T&&(f(T.state),m({isTransitioning:!0,flushSync:!1,currentLocation:T.currentLocation,nextLocation:T.nextLocation}),N(void 0))},[p.isTransitioning,T]),M.useEffect(()=>{},[]);let F=M.useMemo(()=>({createHref:i.createHref,encodeLocation:i.encodeLocation,go:G=>i.navigate(G),push:(G,le,re)=>i.navigate(G,{state:le,preventScrollReset:re==null?void 0:re.preventScrollReset}),replace:(G,le,re)=>i.navigate(G,{replace:!0,state:le,preventScrollReset:re==null?void 0:re.preventScrollReset})}),[i]),ee=i.basename||"/",B=M.useMemo(()=>({router:i,navigator:F,static:!1,basename:ee}),[i,F,ee]),D=M.useMemo(()=>({v7_relativeSplatPath:i.future.v7_relativeSplatPath}),[i.future.v7_relativeSplatPath]);return M.useEffect(()=>gx(l,i.future),[l,i.future]),M.createElement(M.Fragment,null,M.createElement(Lo.Provider,{value:B},M.createElement(Jc.Provider,{value:a},M.createElement(_x.Provider,{value:b.current},M.createElement(Zm.Provider,{value:p},M.createElement(vx,{basename:ee,location:a.location,navigationType:a.historyAction,navigator:F,future:D},a.initialized||i.future.v7_partialHydration?M.createElement(zx,{routes:i.routes,future:i.future,state:a}):r))))),null)}const zx=M.memo(Dx);function Dx(e){let{routes:r,future:i,state:l}=e;return ix(r,void 0,l,i)}const Ax=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u",Ox=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,ps=M.forwardRef(function(r,i){let{onClick:l,relative:a,reloadDocument:u,replace:c,state:f,target:p,to:m,preventScrollReset:g,viewTransition:y}=r,k=Jm(r,Ex),{basename:x}=M.useContext(ni),T,N=!1;if(typeof m=="string"&&Ox.test(m)&&(T=m,Ax))try{let I=new URL(window.location.href),F=m.startsWith("//")?new URL(I.protocol+m):new URL(m),ee=gr(F.pathname,x);F.origin===I.origin&&ee!=null?m=ee+F.search+F.hash:N=!0}catch{}let b=ex(m,{relative:a}),P=Ux(m,{replace:c,state:f,target:p,preventScrollReset:g,relative:a,viewTransition:y});function z(I){l&&l(I),I.defaultPrevented||P(I)}return M.createElement("a",kl({},k,{href:T||b,onClick:N||u?l:z,ref:i,target:p}))}),eg=M.forwardRef(function(r,i){let{"aria-current":l="page",caseSensitive:a=!1,className:u="",end:c=!1,style:f,to:p,viewTransition:m,children:g}=r,y=Jm(r,Cx),k=hs(p,{relative:y.relative}),x=ri(),T=M.useContext(Jc),{navigator:N,basename:b}=M.useContext(ni),P=T!=null&&Hx(k)&&m===!0,z=N.encodeLocation?N.encodeLocation(k).pathname:k.pathname,I=x.pathname,F=T&&T.navigation&&T.navigation.location?T.navigation.location.pathname:null;a||(I=I.toLowerCase(),F=F?F.toLowerCase():null,z=z.toLowerCase()),F&&b&&(F=gr(F,b)||F);const ee=z!=="/"&&z.endsWith("/")?z.length-1:z.length;let B=I===z||!c&&I.startsWith(z)&&I.charAt(ee)==="/",D=F!=null&&(F===z||!c&&F.startsWith(z)&&F.charAt(z.length)==="/"),G={isActive:B,isPending:D,isTransitioning:P},le=B?l:void 0,re;typeof u=="function"?re=u(G):re=[u,B?"active":null,D?"pending":null,P?"transitioning":null].filter(Boolean).join(" ");let $=typeof f=="function"?f(G):f;return M.createElement(ps,kl({},y,{"aria-current":le,className:re,ref:i,style:$,to:p,viewTransition:m}),typeof g=="function"?g(G):g)});var _c;(function(e){e.UseScrollRestoration="useScrollRestoration",e.UseSubmit="useSubmit",e.UseSubmitFetcher="useSubmitFetcher",e.UseFetcher="useFetcher",e.useViewTransitionState="useViewTransitionState"})(_c||(_c={}));var xp;(function(e){e.UseFetcher="useFetcher",e.UseFetchers="useFetchers",e.UseScrollRestoration="useScrollRestoration"})(xp||(xp={}));function Fx(e){let r=M.useContext(Lo);return r||Be(!1),r}function Ux(e,r){let{target:i,replace:l,state:a,preventScrollReset:u,relative:c,viewTransition:f}=r===void 0?{}:r,p=Sl(),m=ri(),g=hs(e,{relative:c});return M.useCallback(y=>{if(kx(y,i)){y.preventDefault();let k=l!==void 0?l:Ii(m)===Ii(g);p(e,{replace:k,state:a,preventScrollReset:u,relative:c,viewTransition:f})}},[m,p,g,l,a,i,e,u,c,f])}function Bx(e){let r=M.useRef(jc(e)),i=M.useRef(!1),l=ri(),a=M.useMemo(()=>Sx(l.search,i.current?null:r.current),[l.search]),u=Sl(),c=M.useCallback((f,p)=>{const m=jc(typeof f=="function"?f(a):f);i.current=!0,u("?"+m,p)},[u,a]);return[a,c]}function Hx(e,r){r===void 0&&(r={});let i=M.useContext(Zm);i==null&&Be(!1);let{basename:l}=Fx(_c.useViewTransitionState),a=hs(e,{relative:r.relative});if(!i.isTransitioning)return!1;let u=gr(i.currentLocation.pathname,l)||i.currentLocation.pathname,c=gr(i.nextLocation.pathname,l)||i.nextLocation.pathname;return is(a.pathname,c)!=null||is(a.pathname,u)!=null}var ms=class{constructor(){this.listeners=new Set,this.subscribe=this.subscribe.bind(this)}subscribe(e){return this.listeners.add(e),this.onSubscribe(),()=>{this.listeners.delete(e),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}onSubscribe(){}onUnsubscribe(){}},Ni,Kr,hl,Cm,Vx=(Cm=class extends ms{constructor(){super();We(this,Ni);We(this,Kr);We(this,hl);Me(this,hl,r=>{if(typeof window<"u"&&window.addEventListener){const i=()=>r();return window.addEventListener("visibilitychange",i,!1),()=>{window.removeEventListener("visibilitychange",i)}}})}onSubscribe(){Q(this,Kr)||this.setEventListener(Q(this,hl))}onUnsubscribe(){var r;this.hasListeners()||((r=Q(this,Kr))==null||r.call(this),Me(this,Kr,void 0))}setEventListener(r){var i;Me(this,hl,r),(i=Q(this,Kr))==null||i.call(this),Me(this,Kr,r(l=>{typeof l=="boolean"?this.setFocused(l):this.onFocus()}))}setFocused(r){Q(this,Ni)!==r&&(Me(this,Ni,r),this.onFocus())}onFocus(){const r=this.isFocused();this.listeners.forEach(i=>{i(r)})}isFocused(){var r;return typeof Q(this,Ni)=="boolean"?Q(this,Ni):((r=globalThis.document)==null?void 0:r.visibilityState)!=="hidden"}},Ni=new WeakMap,Kr=new WeakMap,hl=new WeakMap,Cm),tg=new Vx,$x={setTimeout:(e,r)=>setTimeout(e,r),clearTimeout:e=>clearTimeout(e),setInterval:(e,r)=>setInterval(e,r),clearInterval:e=>clearInterval(e)},Gr,Wc,bm,Wx=(bm=class{constructor(){We(this,Gr,$x);We(this,Wc,!1)}setTimeoutProvider(e){Me(this,Gr,e)}setTimeout(e,r){return Q(this,Gr).setTimeout(e,r)}clearTimeout(e){Q(this,Gr).clearTimeout(e)}setInterval(e,r){return Q(this,Gr).setInterval(e,r)}clearInterval(e){Q(this,Gr).clearInterval(e)}},Gr=new WeakMap,Wc=new WeakMap,bm),Tc=new Wx;function Qx(e){setTimeout(e,0)}var qx=typeof window>"u"||"Deno"in globalThis;function Mn(){}function Kx(e,r){return typeof e=="function"?e(r):e}function Gx(e){return typeof e=="number"&&e>=0&&e!==1/0}function Yx(e,r){return Math.max(e+(r||0)-Date.now(),0)}function Rc(e,r){return typeof e=="function"?e(r):e}function Xx(e,r){return typeof e=="function"?e(r):e}function wp(e,r){const{type:i="all",exact:l,fetchStatus:a,predicate:u,queryKey:c,stale:f}=e;if(c){if(l){if(r.queryHash!==ed(c,r.options))return!1}else if(!No(r.queryKey,c))return!1}if(i!=="all"){const p=r.isActive();if(i==="active"&&!p||i==="inactive"&&p)return!1}return!(typeof f=="boolean"&&r.isStale()!==f||a&&a!==r.state.fetchStatus||u&&!u(r))}function kp(e,r){const{exact:i,status:l,predicate:a,mutationKey:u}=e;if(u){if(!r.options.mutationKey)return!1;if(i){if(bo(r.options.mutationKey)!==bo(u))return!1}else if(!No(r.options.mutationKey,u))return!1}return!(l&&r.state.status!==l||a&&!a(r))}function ed(e,r){return((r==null?void 0:r.queryKeyHashFn)||bo)(e)}function bo(e){return JSON.stringify(e,(r,i)=>Lc(i)?Object.keys(i).sort().reduce((l,a)=>(l[a]=i[a],l),{}):i)}function No(e,r){return e===r?!0:typeof e!=typeof r?!1:e&&r&&typeof e=="object"&&typeof r=="object"?Object.keys(r).every(i=>No(e[i],r[i])):!1}var Jx=Object.prototype.hasOwnProperty;function ng(e,r,i=0){if(e===r)return e;if(i>500)return r;const l=Sp(e)&&Sp(r);if(!l&&!(Lc(e)&&Lc(r)))return r;const u=(l?e:Object.keys(e)).length,c=l?r:Object.keys(r),f=c.length,p=l?new Array(f):{};let m=0;for(let g=0;g<f;g++){const y=l?g:c[g],k=e[y],x=r[y];if(k===x){p[y]=k,(l?g<u:Jx.call(e,y))&&m++;continue}if(k===null||x===null||typeof k!="object"||typeof x!="object"){p[y]=x;continue}const T=ng(k,x,i+1);p[y]=T,T===k&&m++}return u===f&&m===u?e:p}function Sp(e){return Array.isArray(e)&&e.length===Object.keys(e).length}function Lc(e){if(!Ep(e))return!1;const r=e.constructor;if(r===void 0)return!0;const i=r.prototype;return!(!Ep(i)||!i.hasOwnProperty("isPrototypeOf")||Object.getPrototypeOf(e)!==Object.prototype)}function Ep(e){return Object.prototype.toString.call(e)==="[object Object]"}function Zx(e){return new Promise(r=>{Tc.setTimeout(r,e)})}function ew(e,r,i){return typeof i.structuralSharing=="function"?i.structuralSharing(e,r):i.structuralSharing!==!1?ng(e,r):r}function tw(e,r,i=0){const l=[...e,r];return i&&l.length>i?l.slice(1):l}function nw(e,r,i=0){const l=[r,...e];return i&&l.length>i?l.slice(0,-1):l}var td=Symbol();function rg(e,r){return!e.queryFn&&(r!=null&&r.initialPromise)?()=>r.initialPromise:!e.queryFn||e.queryFn===td?()=>Promise.reject(new Error(`Missing queryFn: '${e.queryHash}'`)):e.queryFn}function rw(e,r,i){let l=!1,a;return Object.defineProperty(e,"signal",{enumerable:!0,get:()=>(a??(a=r()),l||(l=!0,a.aborted?i():a.addEventListener("abort",i,{once:!0})),a)}),e}var ig=(()=>{let e=()=>qx;return{isServer(){return e()},setIsServer(r){e=r}}})();function iw(){let e,r;const i=new Promise((a,u)=>{e=a,r=u});i.status="pending",i.catch(()=>{});function l(a){Object.assign(i,a),delete i.resolve,delete i.reject}return i.resolve=a=>{l({status:"fulfilled",value:a}),e(a)},i.reject=a=>{l({status:"rejected",reason:a}),r(a)},i}var lw=Qx;function ow(){let e=[],r=0,i=f=>{f()},l=f=>{f()},a=lw;const u=f=>{r?e.push(f):a(()=>{i(f)})},c=()=>{const f=e;e=[],f.length&&a(()=>{l(()=>{f.forEach(p=>{i(p)})})})};return{batch:f=>{let p;r++;try{p=f()}finally{r--,r||c()}return p},batchCalls:f=>(...p)=>{u(()=>{f(...p)})},schedule:u,setNotifyFunction:f=>{i=f},setBatchNotifyFunction:f=>{l=f},setScheduler:f=>{a=f}}}var Qt=ow(),pl,Yr,ml,Nm,aw=(Nm=class extends ms{constructor(){super();We(this,pl,!0);We(this,Yr);We(this,ml);Me(this,ml,r=>{if(typeof window<"u"&&window.addEventListener){const i=()=>r(!0),l=()=>r(!1);return window.addEventListener("online",i,!1),window.addEventListener("offline",l,!1),()=>{window.removeEventListener("online",i),window.removeEventListener("offline",l)}}})}onSubscribe(){Q(this,Yr)||this.setEventListener(Q(this,ml))}onUnsubscribe(){var r;this.hasListeners()||((r=Q(this,Yr))==null||r.call(this),Me(this,Yr,void 0))}setEventListener(r){var i;Me(this,ml,r),(i=Q(this,Yr))==null||i.call(this),Me(this,Yr,r(this.setOnline.bind(this)))}setOnline(r){Q(this,pl)!==r&&(Me(this,pl,r),this.listeners.forEach(l=>{l(r)}))}isOnline(){return Q(this,pl)}},pl=new WeakMap,Yr=new WeakMap,ml=new WeakMap,Nm),as=new aw;function sw(e){return Math.min(1e3*2**e,3e4)}function lg(e){return(e??"online")==="online"?as.isOnline():!0}var Ic=class extends Error{constructor(e){super("CancelledError"),this.revert=e==null?void 0:e.revert,this.silent=e==null?void 0:e.silent}};function og(e){let r=!1,i=0,l;const a=iw(),u=()=>a.status!=="pending",c=N=>{var b;if(!u()){const P=new Ic(N);k(P),(b=e.onCancel)==null||b.call(e,P)}},f=()=>{r=!0},p=()=>{r=!1},m=()=>tg.isFocused()&&(e.networkMode==="always"||as.isOnline())&&e.canRun(),g=()=>lg(e.networkMode)&&e.canRun(),y=N=>{u()||(l==null||l(),a.resolve(N))},k=N=>{u()||(l==null||l(),a.reject(N))},x=()=>new Promise(N=>{var b;l=P=>{(u()||m())&&N(P)},(b=e.onPause)==null||b.call(e)}).then(()=>{var N;l=void 0,u()||(N=e.onContinue)==null||N.call(e)}),T=()=>{if(u())return;let N;const b=i===0?e.initialPromise:void 0;try{N=b??e.fn()}catch(P){N=Promise.reject(P)}Promise.resolve(N).then(y).catch(P=>{var B;if(u())return;const z=e.retry??(ig.isServer()?0:3),I=e.retryDelay??sw,F=typeof I=="function"?I(i,P):I,ee=z===!0||typeof z=="number"&&i<z||typeof z=="function"&&z(i,P);if(r||!ee){k(P);return}i++,(B=e.onFail)==null||B.call(e,i,P),Zx(F).then(()=>m()?void 0:x()).then(()=>{r?k(P):T()})})};return{promise:a,status:()=>a.status,cancel:c,continue:()=>(l==null||l(),a),cancelRetry:f,continueRetry:p,canStart:g,start:()=>(g()?T():x().then(T),a)}}var Pi,Pm,ag=(Pm=class{constructor(){We(this,Pi)}destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),Gx(this.gcTime)&&Me(this,Pi,Tc.setTimeout(()=>{this.optionalRemove()},this.gcTime))}updateGcTime(e){this.gcTime=Math.max(this.gcTime||0,e??(ig.isServer()?1/0:5*60*1e3))}clearGcTimeout(){Q(this,Pi)&&(Tc.clearTimeout(Q(this,Pi)),Me(this,Pi,void 0))}},Pi=new WeakMap,Pm),ji,gl,Sn,_i,Lt,_o,Ti,dn,sg,hr,jm,uw=(jm=class extends ag{constructor(r){super();We(this,dn);We(this,ji);We(this,gl);We(this,Sn);We(this,_i);We(this,Lt);We(this,_o);We(this,Ti);Me(this,Ti,!1),Me(this,_o,r.defaultOptions),this.setOptions(r.options),this.observers=[],Me(this,_i,r.client),Me(this,Sn,Q(this,_i).getQueryCache()),this.queryKey=r.queryKey,this.queryHash=r.queryHash,Me(this,ji,bp(this.options)),this.state=r.state??Q(this,ji),this.scheduleGc()}get meta(){return this.options.meta}get promise(){var r;return(r=Q(this,Lt))==null?void 0:r.promise}setOptions(r){if(this.options={...Q(this,_o),...r},this.updateGcTime(this.options.gcTime),this.state&&this.state.data===void 0){const i=bp(this.options);i.data!==void 0&&(this.setState(Cp(i.data,i.dataUpdatedAt)),Me(this,ji,i))}}optionalRemove(){!this.observers.length&&this.state.fetchStatus==="idle"&&Q(this,Sn).remove(this)}setData(r,i){const l=ew(this.state.data,r,this.options);return Dt(this,dn,hr).call(this,{data:l,type:"success",dataUpdatedAt:i==null?void 0:i.updatedAt,manual:i==null?void 0:i.manual}),l}setState(r,i){Dt(this,dn,hr).call(this,{type:"setState",state:r,setStateOptions:i})}cancel(r){var l,a;const i=(l=Q(this,Lt))==null?void 0:l.promise;return(a=Q(this,Lt))==null||a.cancel(r),i?i.then(Mn).catch(Mn):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}get resetState(){return Q(this,ji)}reset(){this.destroy(),this.setState(this.resetState)}isActive(){return this.observers.some(r=>Xx(r.options.enabled,this)!==!1)}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===td||!this.isFetched()}isFetched(){return this.state.dataUpdateCount+this.state.errorUpdateCount>0}isStatic(){return this.getObserversCount()>0?this.observers.some(r=>Rc(r.options.staleTime,this)==="static"):!1}isStale(){return this.getObserversCount()>0?this.observers.some(r=>r.getCurrentResult().isStale):this.state.data===void 0||this.state.isInvalidated}isStaleByTime(r=0){return this.state.data===void 0?!0:r==="static"?!1:this.state.isInvalidated?!0:!Yx(this.state.dataUpdatedAt,r)}onFocus(){var i;const r=this.observers.find(l=>l.shouldFetchOnWindowFocus());r==null||r.refetch({cancelRefetch:!1}),(i=Q(this,Lt))==null||i.continue()}onOnline(){var i;const r=this.observers.find(l=>l.shouldFetchOnReconnect());r==null||r.refetch({cancelRefetch:!1}),(i=Q(this,Lt))==null||i.continue()}addObserver(r){this.observers.includes(r)||(this.observers.push(r),this.clearGcTimeout(),Q(this,Sn).notify({type:"observerAdded",query:this,observer:r}))}removeObserver(r){this.observers.includes(r)&&(this.observers=this.observers.filter(i=>i!==r),this.observers.length||(Q(this,Lt)&&(Q(this,Ti)||Dt(this,dn,sg).call(this)?Q(this,Lt).cancel({revert:!0}):Q(this,Lt).cancelRetry()),this.scheduleGc()),Q(this,Sn).notify({type:"observerRemoved",query:this,observer:r}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||Dt(this,dn,hr).call(this,{type:"invalidate"})}async fetch(r,i){var p,m,g,y,k,x,T,N,b,P,z,I;if(this.state.fetchStatus!=="idle"&&((p=Q(this,Lt))==null?void 0:p.status())!=="rejected"){if(this.state.data!==void 0&&(i!=null&&i.cancelRefetch))this.cancel({silent:!0});else if(Q(this,Lt))return Q(this,Lt).continueRetry(),Q(this,Lt).promise}if(r&&this.setOptions(r),!this.options.queryFn){const F=this.observers.find(ee=>ee.options.queryFn);F&&this.setOptions(F.options)}const l=new AbortController,a=F=>{Object.defineProperty(F,"signal",{enumerable:!0,get:()=>(Me(this,Ti,!0),l.signal)})},u=()=>{const F=rg(this.options,i),B=(()=>{const D={client:Q(this,_i),queryKey:this.queryKey,meta:this.meta};return a(D),D})();return Me(this,Ti,!1),this.options.persister?this.options.persister(F,B,this):F(B)},f=(()=>{const F={fetchOptions:i,options:this.options,queryKey:this.queryKey,client:Q(this,_i),state:this.state,fetchFn:u};return a(F),F})();(m=this.options.behavior)==null||m.onFetch(f,this),Me(this,gl,this.state),(this.state.fetchStatus==="idle"||this.state.fetchMeta!==((g=f.fetchOptions)==null?void 0:g.meta))&&Dt(this,dn,hr).call(this,{type:"fetch",meta:(y=f.fetchOptions)==null?void 0:y.meta}),Me(this,Lt,og({initialPromise:i==null?void 0:i.initialPromise,fn:f.fetchFn,onCancel:F=>{F instanceof Ic&&F.revert&&this.setState({...Q(this,gl),fetchStatus:"idle"}),l.abort()},onFail:(F,ee)=>{Dt(this,dn,hr).call(this,{type:"failed",failureCount:F,error:ee})},onPause:()=>{Dt(this,dn,hr).call(this,{type:"pause"})},onContinue:()=>{Dt(this,dn,hr).call(this,{type:"continue"})},retry:f.options.retry,retryDelay:f.options.retryDelay,networkMode:f.options.networkMode,canRun:()=>!0}));try{const F=await Q(this,Lt).start();if(F===void 0)throw new Error(`${this.queryHash} data is undefined`);return this.setData(F),(x=(k=Q(this,Sn).config).onSuccess)==null||x.call(k,F,this),(N=(T=Q(this,Sn).config).onSettled)==null||N.call(T,F,this.state.error,this),F}catch(F){if(F instanceof Ic){if(F.silent)return Q(this,Lt).promise;if(F.revert){if(this.state.data===void 0)throw F;return this.state.data}}throw Dt(this,dn,hr).call(this,{type:"error",error:F}),(P=(b=Q(this,Sn).config).onError)==null||P.call(b,F,this),(I=(z=Q(this,Sn).config).onSettled)==null||I.call(z,this.state.data,F,this),F}finally{this.scheduleGc()}}},ji=new WeakMap,gl=new WeakMap,Sn=new WeakMap,_i=new WeakMap,Lt=new WeakMap,_o=new WeakMap,Ti=new WeakMap,dn=new WeakSet,sg=function(){return this.state.fetchStatus==="paused"&&this.state.status==="pending"},hr=function(r){const i=l=>{switch(r.type){case"failed":return{...l,fetchFailureCount:r.failureCount,fetchFailureReason:r.error};case"pause":return{...l,fetchStatus:"paused"};case"continue":return{...l,fetchStatus:"fetching"};case"fetch":return{...l,...cw(l.data,this.options),fetchMeta:r.meta??null};case"success":const a={...l,...Cp(r.data,r.dataUpdatedAt),dataUpdateCount:l.dataUpdateCount+1,...!r.manual&&{fetchStatus:"idle",fetchFailureCount:0,fetchFailureReason:null}};return Me(this,gl,r.manual?a:void 0),a;case"error":const u=r.error;return{...l,error:u,errorUpdateCount:l.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:l.fetchFailureCount+1,fetchFailureReason:u,fetchStatus:"idle",status:"error",isInvalidated:!0};case"invalidate":return{...l,isInvalidated:!0};case"setState":return{...l,...r.state}}};this.state=i(this.state),Qt.batch(()=>{this.observers.forEach(l=>{l.onQueryUpdate()}),Q(this,Sn).notify({query:this,type:"updated",action:r})})},jm);function cw(e,r){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:lg(r.networkMode)?"fetching":"paused",...e===void 0&&{error:null,status:"pending"}}}function Cp(e,r){return{data:e,dataUpdatedAt:r??Date.now(),error:null,isInvalidated:!1,status:"success"}}function bp(e){const r=typeof e.initialData=="function"?e.initialData():e.initialData,i=r!==void 0,l=i?typeof e.initialDataUpdatedAt=="function"?e.initialDataUpdatedAt():e.initialDataUpdatedAt:0;return{data:r,dataUpdateCount:0,dataUpdatedAt:i?l??Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null,isInvalidated:!1,status:i?"success":"pending",fetchStatus:"idle"}}function Np(e){return{onFetch:(r,i)=>{var g,y,k,x,T;const l=r.options,a=(k=(y=(g=r.fetchOptions)==null?void 0:g.meta)==null?void 0:y.fetchMore)==null?void 0:k.direction,u=((x=r.state.data)==null?void 0:x.pages)||[],c=((T=r.state.data)==null?void 0:T.pageParams)||[];let f={pages:[],pageParams:[]},p=0;const m=async()=>{let N=!1;const b=I=>{rw(I,()=>r.signal,()=>N=!0)},P=rg(r.options,r.fetchOptions),z=async(I,F,ee)=>{if(N)return Promise.reject();if(F==null&&I.pages.length)return Promise.resolve(I);const D=(()=>{const $={client:r.client,queryKey:r.queryKey,pageParam:F,direction:ee?"backward":"forward",meta:r.options.meta};return b($),$})(),G=await P(D),{maxPages:le}=r.options,re=ee?nw:tw;return{pages:re(I.pages,G,le),pageParams:re(I.pageParams,F,le)}};if(a&&u.length){const I=a==="backward",F=I?dw:Pp,ee={pages:u,pageParams:c},B=F(l,ee);f=await z(ee,B,I)}else{const I=e??u.length;do{const F=p===0?c[0]??l.initialPageParam:Pp(l,f);if(p>0&&F==null)break;f=await z(f,F),p++}while(p<I)}return f};r.options.persister?r.fetchFn=()=>{var N,b;return(b=(N=r.options).persister)==null?void 0:b.call(N,m,{client:r.client,queryKey:r.queryKey,meta:r.options.meta,signal:r.signal},i)}:r.fetchFn=m}}}function Pp(e,{pages:r,pageParams:i}){const l=r.length-1;return r.length>0?e.getNextPageParam(r[l],r,i[l],i):void 0}function dw(e,{pages:r,pageParams:i}){var l;return r.length>0?(l=e.getPreviousPageParam)==null?void 0:l.call(e,r[0],r,i[0],i):void 0}var To,Gn,Ht,Ri,Yn,qr,_m,fw=(_m=class extends ag{constructor(r){super();We(this,Yn);We(this,To);We(this,Gn);We(this,Ht);We(this,Ri);Me(this,To,r.client),this.mutationId=r.mutationId,Me(this,Ht,r.mutationCache),Me(this,Gn,[]),this.state=r.state||hw(),this.setOptions(r.options),this.scheduleGc()}setOptions(r){this.options=r,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(r){Q(this,Gn).includes(r)||(Q(this,Gn).push(r),this.clearGcTimeout(),Q(this,Ht).notify({type:"observerAdded",mutation:this,observer:r}))}removeObserver(r){Me(this,Gn,Q(this,Gn).filter(i=>i!==r)),this.scheduleGc(),Q(this,Ht).notify({type:"observerRemoved",mutation:this,observer:r})}optionalRemove(){Q(this,Gn).length||(this.state.status==="pending"?this.scheduleGc():Q(this,Ht).remove(this))}continue(){var r;return((r=Q(this,Ri))==null?void 0:r.continue())??this.execute(this.state.variables)}async execute(r){var c,f,p,m,g,y,k,x,T,N,b,P,z,I,F,ee,B,D;const i=()=>{Dt(this,Yn,qr).call(this,{type:"continue"})},l={client:Q(this,To),meta:this.options.meta,mutationKey:this.options.mutationKey};Me(this,Ri,og({fn:()=>this.options.mutationFn?this.options.mutationFn(r,l):Promise.reject(new Error("No mutationFn found")),onFail:(G,le)=>{Dt(this,Yn,qr).call(this,{type:"failed",failureCount:G,error:le})},onPause:()=>{Dt(this,Yn,qr).call(this,{type:"pause"})},onContinue:i,retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>Q(this,Ht).canRun(this)}));const a=this.state.status==="pending",u=!Q(this,Ri).canStart();try{if(a)i();else{Dt(this,Yn,qr).call(this,{type:"pending",variables:r,isPaused:u}),Q(this,Ht).config.onMutate&&await Q(this,Ht).config.onMutate(r,this,l);const le=await((f=(c=this.options).onMutate)==null?void 0:f.call(c,r,l));le!==this.state.context&&Dt(this,Yn,qr).call(this,{type:"pending",context:le,variables:r,isPaused:u})}const G=await Q(this,Ri).start();return await((m=(p=Q(this,Ht).config).onSuccess)==null?void 0:m.call(p,G,r,this.state.context,this,l)),await((y=(g=this.options).onSuccess)==null?void 0:y.call(g,G,r,this.state.context,l)),await((x=(k=Q(this,Ht).config).onSettled)==null?void 0:x.call(k,G,null,this.state.variables,this.state.context,this,l)),await((N=(T=this.options).onSettled)==null?void 0:N.call(T,G,null,r,this.state.context,l)),Dt(this,Yn,qr).call(this,{type:"success",data:G}),G}catch(G){try{await((P=(b=Q(this,Ht).config).onError)==null?void 0:P.call(b,G,r,this.state.context,this,l))}catch(le){Promise.reject(le)}try{await((I=(z=this.options).onError)==null?void 0:I.call(z,G,r,this.state.context,l))}catch(le){Promise.reject(le)}try{await((ee=(F=Q(this,Ht).config).onSettled)==null?void 0:ee.call(F,void 0,G,this.state.variables,this.state.context,this,l))}catch(le){Promise.reject(le)}try{await((D=(B=this.options).onSettled)==null?void 0:D.call(B,void 0,G,r,this.state.context,l))}catch(le){Promise.reject(le)}throw Dt(this,Yn,qr).call(this,{type:"error",error:G}),G}finally{Q(this,Ht).runNext(this)}}},To=new WeakMap,Gn=new WeakMap,Ht=new WeakMap,Ri=new WeakMap,Yn=new WeakSet,qr=function(r){const i=l=>{switch(r.type){case"failed":return{...l,failureCount:r.failureCount,failureReason:r.error};case"pause":return{...l,isPaused:!0};case"continue":return{...l,isPaused:!1};case"pending":return{...l,context:r.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:r.isPaused,status:"pending",variables:r.variables,submittedAt:Date.now()};case"success":return{...l,data:r.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1};case"error":return{...l,data:void 0,error:r.error,failureCount:l.failureCount+1,failureReason:r.error,isPaused:!1,status:"error"}}};this.state=i(this.state),Qt.batch(()=>{Q(this,Gn).forEach(l=>{l.onMutationUpdate(r)}),Q(this,Ht).notify({mutation:this,type:"updated",action:r})})},_m);function hw(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0}}var pr,zn,Ro,Tm,pw=(Tm=class extends ms{constructor(r={}){super();We(this,pr);We(this,zn);We(this,Ro);this.config=r,Me(this,pr,new Set),Me(this,zn,new Map),Me(this,Ro,0)}build(r,i,l){const a=new fw({client:r,mutationCache:this,mutationId:++Wa(this,Ro)._,options:r.defaultMutationOptions(i),state:l});return this.add(a),a}add(r){Q(this,pr).add(r);const i=Ka(r);if(typeof i=="string"){const l=Q(this,zn).get(i);l?l.push(r):Q(this,zn).set(i,[r])}this.notify({type:"added",mutation:r})}remove(r){if(Q(this,pr).delete(r)){const i=Ka(r);if(typeof i=="string"){const l=Q(this,zn).get(i);if(l)if(l.length>1){const a=l.indexOf(r);a!==-1&&l.splice(a,1)}else l[0]===r&&Q(this,zn).delete(i)}}this.notify({type:"removed",mutation:r})}canRun(r){const i=Ka(r);if(typeof i=="string"){const l=Q(this,zn).get(i),a=l==null?void 0:l.find(u=>u.state.status==="pending");return!a||a===r}else return!0}runNext(r){var l;const i=Ka(r);if(typeof i=="string"){const a=(l=Q(this,zn).get(i))==null?void 0:l.find(u=>u!==r&&u.state.isPaused);return(a==null?void 0:a.continue())??Promise.resolve()}else return Promise.resolve()}clear(){Qt.batch(()=>{Q(this,pr).forEach(r=>{this.notify({type:"removed",mutation:r})}),Q(this,pr).clear(),Q(this,zn).clear()})}getAll(){return Array.from(Q(this,pr))}find(r){const i={exact:!0,...r};return this.getAll().find(l=>kp(i,l))}findAll(r={}){return this.getAll().filter(i=>kp(r,i))}notify(r){Qt.batch(()=>{this.listeners.forEach(i=>{i(r)})})}resumePausedMutations(){const r=this.getAll().filter(i=>i.state.isPaused);return Qt.batch(()=>Promise.all(r.map(i=>i.continue().catch(Mn))))}},pr=new WeakMap,zn=new WeakMap,Ro=new WeakMap,Tm);function Ka(e){var r;return(r=e.options.scope)==null?void 0:r.id}var Xn,Rm,mw=(Rm=class extends ms{constructor(r={}){super();We(this,Xn);this.config=r,Me(this,Xn,new Map)}build(r,i,l){const a=i.queryKey,u=i.queryHash??ed(a,i);let c=this.get(u);return c||(c=new uw({client:r,queryKey:a,queryHash:u,options:r.defaultQueryOptions(i),state:l,defaultOptions:r.getQueryDefaults(a)}),this.add(c)),c}add(r){Q(this,Xn).has(r.queryHash)||(Q(this,Xn).set(r.queryHash,r),this.notify({type:"added",query:r}))}remove(r){const i=Q(this,Xn).get(r.queryHash);i&&(r.destroy(),i===r&&Q(this,Xn).delete(r.queryHash),this.notify({type:"removed",query:r}))}clear(){Qt.batch(()=>{this.getAll().forEach(r=>{this.remove(r)})})}get(r){return Q(this,Xn).get(r)}getAll(){return[...Q(this,Xn).values()]}find(r){const i={exact:!0,...r};return this.getAll().find(l=>wp(i,l))}findAll(r={}){const i=this.getAll();return Object.keys(r).length>0?i.filter(l=>wp(r,l)):i}notify(r){Qt.batch(()=>{this.listeners.forEach(i=>{i(r)})})}onFocus(){Qt.batch(()=>{this.getAll().forEach(r=>{r.onFocus()})})}onOnline(){Qt.batch(()=>{this.getAll().forEach(r=>{r.onOnline()})})}},Xn=new WeakMap,Rm),vt,Xr,Jr,yl,vl,Zr,xl,wl,Lm,gw=(Lm=class{constructor(e={}){We(this,vt);We(this,Xr);We(this,Jr);We(this,yl);We(this,vl);We(this,Zr);We(this,xl);We(this,wl);Me(this,vt,e.queryCache||new mw),Me(this,Xr,e.mutationCache||new pw),Me(this,Jr,e.defaultOptions||{}),Me(this,yl,new Map),Me(this,vl,new Map),Me(this,Zr,0)}mount(){Wa(this,Zr)._++,Q(this,Zr)===1&&(Me(this,xl,tg.subscribe(async e=>{e&&(await this.resumePausedMutations(),Q(this,vt).onFocus())})),Me(this,wl,as.subscribe(async e=>{e&&(await this.resumePausedMutations(),Q(this,vt).onOnline())})))}unmount(){var e,r;Wa(this,Zr)._--,Q(this,Zr)===0&&((e=Q(this,xl))==null||e.call(this),Me(this,xl,void 0),(r=Q(this,wl))==null||r.call(this),Me(this,wl,void 0))}isFetching(e){return Q(this,vt).findAll({...e,fetchStatus:"fetching"}).length}isMutating(e){return Q(this,Xr).findAll({...e,status:"pending"}).length}getQueryData(e){var i;const r=this.defaultQueryOptions({queryKey:e});return(i=Q(this,vt).get(r.queryHash))==null?void 0:i.state.data}ensureQueryData(e){const r=this.defaultQueryOptions(e),i=Q(this,vt).build(this,r),l=i.state.data;return l===void 0?this.fetchQuery(e):(e.revalidateIfStale&&i.isStaleByTime(Rc(r.staleTime,i))&&this.prefetchQuery(r),Promise.resolve(l))}getQueriesData(e){return Q(this,vt).findAll(e).map(({queryKey:r,state:i})=>{const l=i.data;return[r,l]})}setQueryData(e,r,i){const l=this.defaultQueryOptions({queryKey:e}),a=Q(this,vt).get(l.queryHash),u=a==null?void 0:a.state.data,c=Kx(r,u);if(c!==void 0)return Q(this,vt).build(this,l).setData(c,{...i,manual:!0})}setQueriesData(e,r,i){return Qt.batch(()=>Q(this,vt).findAll(e).map(({queryKey:l})=>[l,this.setQueryData(l,r,i)]))}getQueryState(e){var i;const r=this.defaultQueryOptions({queryKey:e});return(i=Q(this,vt).get(r.queryHash))==null?void 0:i.state}removeQueries(e){const r=Q(this,vt);Qt.batch(()=>{r.findAll(e).forEach(i=>{r.remove(i)})})}resetQueries(e,r){const i=Q(this,vt);return Qt.batch(()=>(i.findAll(e).forEach(l=>{l.reset()}),this.refetchQueries({type:"active",...e},r)))}cancelQueries(e,r={}){const i={revert:!0,...r},l=Qt.batch(()=>Q(this,vt).findAll(e).map(a=>a.cancel(i)));return Promise.all(l).then(Mn).catch(Mn)}invalidateQueries(e,r={}){return Qt.batch(()=>(Q(this,vt).findAll(e).forEach(i=>{i.invalidate()}),(e==null?void 0:e.refetchType)==="none"?Promise.resolve():this.refetchQueries({...e,type:(e==null?void 0:e.refetchType)??(e==null?void 0:e.type)??"active"},r)))}refetchQueries(e,r={}){const i={...r,cancelRefetch:r.cancelRefetch??!0},l=Qt.batch(()=>Q(this,vt).findAll(e).filter(a=>!a.isDisabled()&&!a.isStatic()).map(a=>{let u=a.fetch(void 0,i);return i.throwOnError||(u=u.catch(Mn)),a.state.fetchStatus==="paused"?Promise.resolve():u}));return Promise.all(l).then(Mn)}fetchQuery(e){const r=this.defaultQueryOptions(e);r.retry===void 0&&(r.retry=!1);const i=Q(this,vt).build(this,r);return i.isStaleByTime(Rc(r.staleTime,i))?i.fetch(r):Promise.resolve(i.state.data)}prefetchQuery(e){return this.fetchQuery(e).then(Mn).catch(Mn)}fetchInfiniteQuery(e){return e.behavior=Np(e.pages),this.fetchQuery(e)}prefetchInfiniteQuery(e){return this.fetchInfiniteQuery(e).then(Mn).catch(Mn)}ensureInfiniteQueryData(e){return e.behavior=Np(e.pages),this.ensureQueryData(e)}resumePausedMutations(){return as.isOnline()?Q(this,Xr).resumePausedMutations():Promise.resolve()}getQueryCache(){return Q(this,vt)}getMutationCache(){return Q(this,Xr)}getDefaultOptions(){return Q(this,Jr)}setDefaultOptions(e){Me(this,Jr,e)}setQueryDefaults(e,r){Q(this,yl).set(bo(e),{queryKey:e,defaultOptions:r})}getQueryDefaults(e){const r=[...Q(this,yl).values()],i={};return r.forEach(l=>{No(e,l.queryKey)&&Object.assign(i,l.defaultOptions)}),i}setMutationDefaults(e,r){Q(this,vl).set(bo(e),{mutationKey:e,defaultOptions:r})}getMutationDefaults(e){const r=[...Q(this,vl).values()],i={};return r.forEach(l=>{No(e,l.mutationKey)&&Object.assign(i,l.defaultOptions)}),i}defaultQueryOptions(e){if(e._defaulted)return e;const r={...Q(this,Jr).queries,...this.getQueryDefaults(e.queryKey),...e,_defaulted:!0};return r.queryHash||(r.queryHash=ed(r.queryKey,r)),r.refetchOnReconnect===void 0&&(r.refetchOnReconnect=r.networkMode!=="always"),r.throwOnError===void 0&&(r.throwOnError=!!r.suspense),!r.networkMode&&r.persister&&(r.networkMode="offlineFirst"),r.queryFn===td&&(r.enabled=!1),r}defaultMutationOptions(e){return e!=null&&e._defaulted?e:{...Q(this,Jr).mutations,...(e==null?void 0:e.mutationKey)&&this.getMutationDefaults(e.mutationKey),...e,_defaulted:!0}}clear(){Q(this,vt).clear(),Q(this,Xr).clear()}},vt=new WeakMap,Xr=new WeakMap,Jr=new WeakMap,yl=new WeakMap,vl=new WeakMap,Zr=new WeakMap,xl=new WeakMap,wl=new WeakMap,Lm),yw=M.createContext(void 0),vw=({client:e,children:r})=>(M.useEffect(()=>(e.mount(),()=>{e.unmount()}),[e]),v.jsx(yw.Provider,{value:e,children:r}));/**
|
|
69
|
+
* @license
|
|
70
|
+
* Copyright 2025 Amodal Labs, Inc.
|
|
71
|
+
* SPDX-License-Identifier: MIT
|
|
72
|
+
*/function jp(e){if(!e.startsWith("data: "))return null;const r=e.slice(6).trim();return r.length===0?null:JSON.parse(r)}async function*xw(e,r,i){const l={"Content-Type":"application/json",...i==null?void 0:i.headers},a=await fetch(e,{method:"POST",headers:l,body:JSON.stringify(r),signal:i==null?void 0:i.signal});if(!a.ok)throw new Error(`SSE request failed: ${String(a.status)} ${a.statusText}`);yield*ug(a)}async function*ww(e,r){const i=await fetch(e,{method:"GET",headers:r==null?void 0:r.headers,signal:r==null?void 0:r.signal});if(!i.ok)throw new Error(`SSE request failed: ${String(i.status)} ${i.statusText}`);yield*ug(i)}async function*ug(e){const r=e.body;if(!r)throw new Error("Response body is null");const i=r.getReader(),l=new TextDecoder;let a="";try{for(;;){const{done:u,value:c}=await i.read();if(u)break;a+=l.decode(c,{stream:!0});const f=a.split(`
|
|
73
|
+
`);a=f.pop()??"";for(const p of f){const m=p.trim();if(m.length===0)continue;const g=jp(m);g&&(yield g)}}if(a.trim().length>0){const u=jp(a.trim());u&&(yield u)}}finally{i.releaseLock()}}/**
|
|
74
|
+
* @license
|
|
75
|
+
* Copyright 2025 Amodal Labs, Inc.
|
|
76
|
+
* SPDX-License-Identifier: MIT
|
|
77
|
+
*/class kw{constructor(r){$a(this,"runtimeUrl");$a(this,"tenantId");$a(this,"getToken");this.runtimeUrl=r.runtimeUrl.replace(/\/$/,""),this.tenantId=r.tenantId,this.getToken=r.getToken}async authHeaders(){const r={};if(this.getToken){const i=await this.getToken();i&&(r.Authorization=`Bearer ${i}`)}return r}async*chatStream(r,i){const l=`${this.runtimeUrl}/chat`,a={message:r,tenant_id:this.tenantId};i!=null&&i.sessionId&&(a.session_id=i.sessionId),i!=null&&i.context&&(a.context=i.context);const u=await this.authHeaders();yield*xw(l,a,{signal:i==null?void 0:i.signal,headers:u})}async startTask(r,i){const l=`${this.runtimeUrl}/task`,a=await this.authHeaders(),u={prompt:r,tenant_id:this.tenantId};i&&(u.tenant_token=i);const c=await fetch(l,{method:"POST",headers:{"Content-Type":"application/json",...a},body:JSON.stringify(u)});if(!c.ok)throw new Error(`Start task failed: ${String(c.status)} ${c.statusText}`);return await c.json()}async getTaskStatus(r){const i=`${this.runtimeUrl}/task/${r}`,l=await this.authHeaders(),a=await fetch(i,{method:"GET",headers:l});if(!a.ok)throw new Error(`Get task status failed: ${String(a.status)} ${a.statusText}`);return await a.json()}async*streamTask(r,i){const l=`${this.runtimeUrl}/task/${r}/stream`,a=await this.authHeaders();yield*ww(l,{signal:i,headers:a})}async getStores(r){const i=`${this.runtimeUrl}/api/stores`,l=await this.authHeaders(),a=await fetch(i,{headers:l,signal:r});if(!a.ok)throw new Error(`Failed to fetch stores: ${String(a.status)}`);return(await a.json()).stores}async getStoreDocuments(r,i){const l=new URLSearchParams;i!=null&&i.filter&&l.set("filter",JSON.stringify(i.filter)),i!=null&&i.sort&&l.set("sort",i.sort),(i==null?void 0:i.limit)!==void 0&&l.set("limit",String(i.limit)),(i==null?void 0:i.offset)!==void 0&&l.set("offset",String(i.offset));const a=l.toString(),u=`${this.runtimeUrl}/api/stores/${r}${a?`?${a}`:""}`,c=await this.authHeaders(),f=await fetch(u,{headers:c,signal:i==null?void 0:i.signal});if(!f.ok)throw new Error(`Failed to fetch store documents: ${String(f.status)}`);return await f.json()}async getStoreDocument(r,i,l){const a=`${this.runtimeUrl}/api/stores/${r}/${encodeURIComponent(i)}`,u=await this.authHeaders(),c=await fetch(a,{headers:u,signal:l});if(!c.ok){if(c.status===404)return{document:null,history:[]};throw new Error(`Failed to fetch store document: ${String(c.status)}`)}return await c.json()}}const cg=M.createContext(null);function Sw({runtimeUrl:e,tenantId:r,getToken:i,children:l}){const a=M.useMemo(()=>new kw({runtimeUrl:e,tenantId:r,getToken:i}),[e,r,i]),u=M.useMemo(()=>({client:a,runtimeUrl:e,tenantId:r}),[a,e,r]);return v.jsx(cg.Provider,{value:u,children:l})}function nd(){const e=M.useContext(cg);if(!e)throw new Error("useAmodalContext must be used within an <AmodalProvider>");return e}/**
|
|
78
|
+
* @license
|
|
79
|
+
* Copyright 2025 Amodal Labs, Inc.
|
|
80
|
+
* SPDX-License-Identifier: MIT
|
|
81
|
+
*/const dg={messages:[],sessionId:null,isStreaming:!1,error:null,activeToolCalls:[],isHistorical:!1,usage:{inputTokens:0,outputTokens:0}};let _p=0;function Tp(){return _p++,`msg-${Date.now()}-${String(_p)}`}function Ew(e,r){switch(r.type){case"SEND_MESSAGE":{const i={type:"user",id:Tp(),text:r.text,timestamp:new Date().toISOString()},l={type:"assistant_text",id:Tp(),text:"",toolCalls:[],confirmations:[],skillActivations:[],kbProposals:[],widgets:[],contentBlocks:[],timestamp:new Date().toISOString()};return{...e,messages:[...e.messages,i,l],isStreaming:!0,error:null,activeToolCalls:[]}}case"STREAM_INIT":return{...e,sessionId:r.sessionId};case"STREAM_TEXT_DELTA":{const i=[...e.messages],l=i[i.length-1];if(l&&l.type==="assistant_text"){const a=[...l.contentBlocks],u=a[a.length-1];u&&u.type==="text"?a[a.length-1]={type:"text",text:u.text+r.content}:a.push({type:"text",text:r.content}),i[i.length-1]={...l,text:l.text+r.content,contentBlocks:a}}return{...e,messages:i}}case"STREAM_TOOL_CALL_START":{const i=[...e.messages],l=i[i.length-1],a={toolId:r.toolId,toolName:r.toolName,parameters:r.parameters,status:"running"};if(l&&l.type==="assistant_text"){const u=[...l.toolCalls,a],c=[...l.contentBlocks],f=c[c.length-1];f&&f.type==="tool_calls"?c[c.length-1]={type:"tool_calls",calls:[...f.calls,a]}:c.push({type:"tool_calls",calls:[a]}),i[i.length-1]={...l,toolCalls:u,contentBlocks:c}}return{...e,messages:i,activeToolCalls:[...e.activeToolCalls,a]}}case"STREAM_TOOL_CALL_RESULT":{const i=[...e.messages],l=i[i.length-1];if(l&&l.type==="assistant_text"){const u=p=>p.toolId===r.toolId?{...p,status:r.status,result:r.result,duration_ms:r.duration_ms,error:r.error}:p,c=l.toolCalls.map(u),f=l.contentBlocks.map(p=>p.type==="tool_calls"?{...p,calls:p.calls.map(u)}:p);i[i.length-1]={...l,toolCalls:c,contentBlocks:f}}const a=e.activeToolCalls.filter(u=>u.toolId!==r.toolId);return{...e,messages:i,activeToolCalls:a}}case"STREAM_SUBAGENT_EVENT":{const i=[...e.messages],l=i[i.length-1];if(l&&l.type==="assistant_text"){const a=f=>f.toolId===r.parentToolId?{...f,subagentEvents:[...f.subagentEvents??[],r.event]}:f,u=l.toolCalls.map(a),c=l.contentBlocks.map(f=>f.type==="tool_calls"?{...f,calls:f.calls.map(a)}:f);i[i.length-1]={...l,toolCalls:u,contentBlocks:c}}return{...e,messages:i}}case"STREAM_WIDGET":{const i=[...e.messages],l=i[i.length-1];if(l&&l.type==="assistant_text"){const a={type:"widget",widgetType:r.widgetType,data:r.data};i[i.length-1]={...l,contentBlocks:[...l.contentBlocks,a]}}return{...e,messages:i}}case"STREAM_CONFIRMATION_REQUIRED":{const i=[...e.messages],l=i[i.length-1];if(l&&l.type==="assistant_text"){const a={type:"confirmation",confirmation:r.confirmation};i[i.length-1]={...l,confirmations:[...l.confirmations,r.confirmation],contentBlocks:[...l.contentBlocks,a]}}return{...e,messages:i}}case"CONFIRMATION_RESPONDED":{const i=[...e.messages],l=i[i.length-1];if(l&&l.type==="assistant_text"){const a=l.confirmations.map(c=>c.correlationId===r.correlationId?{...c,status:r.approved?"approved":"denied"}:c),u=l.contentBlocks.map(c=>c.type==="confirmation"&&c.confirmation.correlationId===r.correlationId?{...c,confirmation:{...c.confirmation,status:r.approved?"approved":"denied"}}:c);i[i.length-1]={...l,confirmations:a,contentBlocks:u}}return{...e,messages:i}}case"STREAM_ERROR":return{...e,isStreaming:!1,error:r.message,activeToolCalls:[]};case"STREAM_DONE":{const i=[...e.messages],l=i[i.length-1];if(l&&l.type==="assistant_text"){const u=p=>p.status==="running"?{...p,status:"error",error:"Stopped"}:p,c=l.toolCalls.map(u),f=l.contentBlocks.map(p=>p.type==="tool_calls"?{...p,calls:p.calls.map(u)}:p);i[i.length-1]={...l,toolCalls:c,contentBlocks:f}}const a=r.usage?{inputTokens:e.usage.inputTokens+r.usage.inputTokens,outputTokens:e.usage.outputTokens+r.usage.outputTokens}:e.usage;return{...e,messages:i,isStreaming:!1,activeToolCalls:[],usage:a}}case"RESET":return{...dg};default:return e}}function fg(e){const{client:r}=nd(),[i,l]=M.useReducer(Ew,dg),a=M.useRef((e==null?void 0:e.initialSessionId)??null),u=M.useRef(null),c=M.useRef(e);c.current=e,a.current=i.sessionId??a.current;const f=M.useCallback(y=>{if(i.isStreaming)return;l({type:"SEND_MESSAGE",text:y});const k=new AbortController;u.current=k,(async()=>{var N,b,P,z,I,F,ee,B,D,G,le;let T=!1;try{const re=r.chatStream(y,{sessionId:a.current??void 0,context:(N=c.current)==null?void 0:N.context,signal:k.signal});for await(const $ of re)switch($.type){case"init":l({type:"STREAM_INIT",sessionId:$.session_id}),(P=(b=c.current)==null?void 0:b.onSessionCreated)==null||P.call(b,$.session_id);break;case"text_delta":l({type:"STREAM_TEXT_DELTA",content:$.content});break;case"tool_call_start":l({type:"STREAM_TOOL_CALL_START",toolId:$.tool_id,toolName:$.tool_name,parameters:$.parameters});break;case"tool_call_result":l({type:"STREAM_TOOL_CALL_RESULT",toolId:$.tool_id,status:$.status,result:$.result,duration_ms:$.duration_ms,error:$.error}),(I=(z=c.current)==null?void 0:z.onToolCall)==null||I.call(z,{toolId:$.tool_id,toolName:"",parameters:{},status:$.status,result:$.result,duration_ms:$.duration_ms,error:$.error});break;case"subagent_event":l({type:"STREAM_SUBAGENT_EVENT",parentToolId:$.parent_tool_id,event:{agentName:$.agent_name,eventType:$.event_type,toolName:$.tool_name,toolArgs:$.tool_args,result:$.result,text:$.text,error:$.error,timestamp:$.timestamp}});break;case"widget":l({type:"STREAM_WIDGET",widgetType:$.widget_type,data:$.data});break;case"confirmation_required":{const K={endpoint:$.endpoint,method:$.method,reason:$.reason,escalated:$.escalated,params:$.params,connectionName:$.connection_name,correlationId:$.correlation_id,status:"pending"};l({type:"STREAM_CONFIRMATION_REQUIRED",confirmation:K}),(ee=(F=c.current)==null?void 0:F.onConfirmation)==null||ee.call(F,K);break}case"error":l({type:"STREAM_ERROR",message:$.message});break;case"done":T=!0,l({type:"STREAM_DONE",usage:$.usage?{inputTokens:$.usage.input_tokens,outputTokens:$.usage.output_tokens}:void 0}),(D=(B=c.current)==null?void 0:B.onStreamEnd)==null||D.call(B);break;default:break}}catch(re){re instanceof DOMException&&re.name==="AbortError"||l({type:"STREAM_ERROR",message:re instanceof Error?re.message:"Unknown error"})}finally{u.current=null,!T&&!k.signal.aborted&&(l({type:"STREAM_DONE"}),(le=(G=c.current)==null?void 0:G.onStreamEnd)==null||le.call(G))}})()},[r,i.isStreaming]),p=M.useCallback(()=>{u.current&&(u.current.abort(),u.current=null),l({type:"STREAM_DONE"})},[]),m=M.useCallback(()=>{u.current&&(u.current.abort(),u.current=null),l({type:"RESET"})},[]),g=M.useCallback((y,k)=>{l({type:"CONFIRMATION_RESPONDED",correlationId:y,approved:k});const x=k?`I approve the action (correlation: ${y})`:`I deny the action (correlation: ${y})`;i.isStreaming||f(x)},[f,i.isStreaming]);return M.useEffect(()=>()=>{u.current&&u.current.abort()},[]),{messages:i.messages,send:f,stop:p,isStreaming:i.isStreaming,activeToolCalls:i.activeToolCalls,sessionId:i.sessionId,error:i.error,usage:i.usage,reset:m,respondToConfirmation:g}}/**
|
|
82
|
+
* @license
|
|
83
|
+
* Copyright 2025 Amodal Labs, Inc.
|
|
84
|
+
* SPDX-License-Identifier: MIT
|
|
85
|
+
*/function Cw({confirmation:e,onApprove:r,onDeny:i}){const l=e.status==="pending";return v.jsxs("div",{className:"amodal-confirm-card","data-testid":"confirm-card",children:[v.jsxs("div",{className:"amodal-confirm-card__header",children:[v.jsx("span",{className:"amodal-confirm-card__method",children:e.method}),v.jsx("span",{className:"amodal-confirm-card__endpoint",children:e.endpoint})]}),v.jsx("p",{className:"amodal-confirm-card__reason",children:e.reason}),l?v.jsxs("div",{className:"amodal-confirm-card__actions",children:[v.jsx("button",{className:"amodal-confirm-card__btn amodal-confirm-card__btn--approve",onClick:r,"data-testid":"confirm-approve",children:"Approve"}),v.jsx("button",{className:"amodal-confirm-card__btn amodal-confirm-card__btn--deny",onClick:i,"data-testid":"confirm-deny",children:"Deny"})]}):v.jsx("div",{className:"amodal-confirm-card__status","data-testid":"confirm-status",children:e.status==="approved"?"Approved":"Denied"})]})}/**
|
|
86
|
+
* @license
|
|
87
|
+
* Copyright 2025 Amodal Labs, Inc.
|
|
88
|
+
* SPDX-License-Identifier: MIT
|
|
89
|
+
*/function bw({confirmation:e,onApprove:r,onDeny:i}){const l=e.status==="pending";return v.jsxs("div",{className:"amodal-review-card","data-testid":"review-card",children:[v.jsxs("div",{className:"amodal-review-card__header",children:[v.jsx("span",{className:"amodal-review-card__method",children:e.method}),v.jsx("span",{className:"amodal-review-card__endpoint",children:e.endpoint}),e.escalated&&v.jsx("span",{className:"amodal-review-card__badge","data-testid":"escalation-badge",children:"Escalated"})]}),e.connectionName&&v.jsxs("div",{className:"amodal-review-card__connection",children:["Connection: ",e.connectionName]}),v.jsx("p",{className:"amodal-review-card__reason",children:e.reason}),e.params&&Object.keys(e.params).length>0&&v.jsxs("div",{className:"amodal-review-card__params","data-testid":"review-params",children:[v.jsx("div",{className:"amodal-review-card__params-title",children:"Parameters"}),v.jsx("pre",{className:"amodal-review-card__params-body",children:JSON.stringify(e.params,null,2)})]}),l?v.jsxs("div",{className:"amodal-review-card__actions",children:[v.jsx("button",{className:"amodal-review-card__btn amodal-review-card__btn--approve",onClick:r,"data-testid":"review-approve",children:"Approve"}),v.jsx("button",{className:"amodal-review-card__btn amodal-review-card__btn--deny",onClick:i,"data-testid":"review-deny",children:"Deny"})]}):v.jsx("div",{className:"amodal-review-card__status","data-testid":"review-status",children:e.status==="approved"?"Approved":"Denied"})]})}function Nw({placeholder:e="Type a message...",renderText:r,renderToolCall:i,renderConfirmation:l,className:a,...u}){const{messages:c,send:f,isStreaming:p,respondToConfirmation:m}=fg(u),[g,y]=M.useState(""),k=M.useRef(null),x=M.useCallback(N=>{N.preventDefault();const b=g.trim();b.length===0||p||(y(""),f(b))},[g,p,f]),T=["amodal-chat",a].filter(Boolean).join(" ");return v.jsxs("div",{className:T,"data-testid":"amodal-chat",children:[v.jsxs("div",{className:"amodal-chat__messages","data-testid":"message-list",children:[c.map(N=>{switch(N.type){case"user":return v.jsx("div",{className:"amodal-chat__message amodal-chat__message--user","data-testid":"user-message",children:N.text},N.id);case"assistant_text":return v.jsx("div",{className:"amodal-chat__message amodal-chat__message--assistant","data-testid":"assistant-message",children:N.contentBlocks.map((b,P)=>{switch(b.type){case"text":return v.jsx("div",{className:"amodal-chat__text",children:r?r(b.text):b.text},`text-${String(P)}`);case"tool_calls":return v.jsx("div",{className:"amodal-chat__tool-calls",children:b.calls.map(z=>i?v.jsx("div",{children:i(z)},z.toolId):v.jsxs("div",{className:"amodal-chat__tool-call","data-testid":"tool-call",children:[v.jsx("span",{className:"amodal-chat__tool-name",children:z.toolName}),v.jsx("span",{className:"amodal-chat__tool-status",children:z.status})]},z.toolId))},`tools-${String(P)}`);case"confirmation":{const z=b.confirmation,I=()=>{z.correlationId&&m(z.correlationId,!0)},F=()=>{z.correlationId&&m(z.correlationId,!1)};return l?v.jsx("div",{children:l(z,I,F)},`conf-${String(P)}`):z.escalated||z.params&&Object.keys(z.params).length>0?v.jsx(bw,{confirmation:z,onApprove:I,onDeny:F},`conf-${String(P)}`):v.jsx(Cw,{confirmation:z,onApprove:I,onDeny:F},`conf-${String(P)}`)}case"widget":return v.jsx("div",{className:"amodal-chat__widget","data-testid":"widget",children:b.widgetType},`widget-${String(P)}`);default:return null}})},N.id);case"error":return v.jsx("div",{className:"amodal-chat__message amodal-chat__message--error","data-testid":"error-message",children:N.message},N.id);default:return null}}),v.jsx("div",{ref:k})]}),v.jsxs("form",{className:"amodal-chat__input-bar",onSubmit:x,"data-testid":"input-bar",children:[v.jsx("input",{className:"amodal-chat__input",value:g,onChange:N=>y(N.target.value),placeholder:e,disabled:p,"data-testid":"chat-input"}),v.jsx("button",{className:"amodal-chat__send",type:"submit",disabled:p||g.trim().length===0,"data-testid":"send-button",children:"Send"})]})]})}/**
|
|
90
|
+
* @license
|
|
91
|
+
* Copyright 2025 Amodal Labs, Inc.
|
|
92
|
+
* SPDX-License-Identifier: MIT
|
|
93
|
+
*/function Pw(e,r){const{key:i,refreshInterval:l=3e4}=r,{client:a}=nd(),[u,c]=M.useState(null),[f,p]=M.useState([]),[m,g]=M.useState(!0),[y,k]=M.useState(null),x=M.useRef(null),T=M.useCallback(async()=>{x.current&&x.current.abort();const b=new AbortController;x.current=b;try{const P=await a.getStoreDocument(e,i,b.signal);c(P.document),p(P.history),k(null)}catch(P){P instanceof DOMException&&P.name==="AbortError"||k(P instanceof Error?P.message:"Failed to fetch document")}finally{g(!1),x.current=null}},[a,e,i]),N=M.useCallback(()=>{T()},[T]);return M.useEffect(()=>(g(!0),T(),()=>{x.current&&x.current.abort()}),[T]),M.useEffect(()=>{if(l<=0)return;const b=setInterval(()=>{T()},l);return()=>clearInterval(b)},[T,l]),{data:(u==null?void 0:u.payload)??null,meta:(u==null?void 0:u.meta)??null,document:u,history:f,isLoading:m,error:y,refetch:N}}/**
|
|
94
|
+
* @license
|
|
95
|
+
* Copyright 2025 Amodal Labs, Inc.
|
|
96
|
+
* SPDX-License-Identifier: MIT
|
|
97
|
+
*/function jw(e,r={}){const{filter:i,sort:l,limit:a=20,refreshInterval:u=3e4}=r,{client:c}=nd(),[f,p]=M.useState([]),[m,g]=M.useState(0),[y,k]=M.useState(!1),[x,T]=M.useState(!0),[N,b]=M.useState(null),P=M.useRef(null),z=i?JSON.stringify(i):"",I=M.useCallback(async()=>{P.current&&P.current.abort();const ee=new AbortController;P.current=ee;try{const B=await c.getStoreDocuments(e,{filter:z?JSON.parse(z):void 0,sort:l,limit:a,signal:ee.signal});p(B.documents),g(B.total),k(B.hasMore),b(null)}catch(B){B instanceof DOMException&&B.name==="AbortError"||b(B instanceof Error?B.message:"Failed to fetch store list")}finally{T(!1),P.current=null}},[c,e,z,l,a]),F=M.useCallback(()=>{I()},[I]);return M.useEffect(()=>(T(!0),I(),()=>{P.current&&P.current.abort()}),[I]),M.useEffect(()=>{if(u<=0)return;const ee=setInterval(()=>{I()},u);return()=>clearInterval(ee)},[I,u]),{data:f.map(ee=>ee.payload),documents:f,total:m,hasMore:y,isLoading:x,error:N,refetch:F}}/**
|
|
98
|
+
* @license
|
|
99
|
+
* Copyright 2025 Amodal Labs, Inc.
|
|
100
|
+
* SPDX-License-Identifier: MIT
|
|
101
|
+
*/M.createContext(null);const hg=M.createContext({name:"",model:"",provider:"",stores:[],connections:[],skills:[],automations:[],knowledge:[],resumeSessionId:null,isLoading:!0,error:null});function _w({runtimeUrl:e,children:r}){const[i,l]=M.useState({name:"",model:"",provider:"",stores:[],connections:[],skills:[],automations:[],knowledge:[],resumeSessionId:null,isLoading:!0,error:null});return M.useEffect(()=>{let a=!1;async function u(){try{const c=await fetch(`${e}/inspect/context`);let f="",p="",m="",g=[],y=[],k=[],x=[];if(c.ok){const b=await c.json();f=b.name??"",p=b.model??"",m=b.provider??"",g=b.connections??[],y=b.skills??[],k=b.automations??[],x=b.knowledge??[]}let T=[];try{const b=await fetch(`${e}/api/stores`);b.ok&&(T=(await b.json()).stores)}catch{}let N=null;try{const b=await fetch(`${e}/config`);b.ok&&(N=(await b.json()).resumeSessionId??null)}catch{}a||l({name:f,model:p,provider:m,stores:T,connections:g,skills:y,automations:k,knowledge:x,resumeSessionId:N,isLoading:!1,error:null})}catch(c){a||l(f=>({...f,isLoading:!1,error:c instanceof Error?c.message:"Failed to load manifest"}))}}return u(),()=>{a=!0}},[e]),v.jsx(hg.Provider,{value:i,children:r})}function Mo(){return M.useContext(hg)}/**
|
|
102
|
+
* @license lucide-react v0.469.0 - ISC
|
|
103
|
+
*
|
|
104
|
+
* This source code is licensed under the ISC license.
|
|
105
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
106
|
+
*/const Tw=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),pg=(...e)=>e.filter((r,i,l)=>!!r&&r.trim()!==""&&l.indexOf(r)===i).join(" ").trim();/**
|
|
107
|
+
* @license lucide-react v0.469.0 - ISC
|
|
108
|
+
*
|
|
109
|
+
* This source code is licensed under the ISC license.
|
|
110
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
111
|
+
*/var Rw={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};/**
|
|
112
|
+
* @license lucide-react v0.469.0 - ISC
|
|
113
|
+
*
|
|
114
|
+
* This source code is licensed under the ISC license.
|
|
115
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
116
|
+
*/const Lw=M.forwardRef(({color:e="currentColor",size:r=24,strokeWidth:i=2,absoluteStrokeWidth:l,className:a="",children:u,iconNode:c,...f},p)=>M.createElement("svg",{ref:p,...Rw,width:r,height:r,stroke:e,strokeWidth:l?Number(i)*24/Number(r):i,className:pg("lucide",a),...f},[...c.map(([m,g])=>M.createElement(m,g)),...Array.isArray(u)?u:[u]]));/**
|
|
117
|
+
* @license lucide-react v0.469.0 - ISC
|
|
118
|
+
*
|
|
119
|
+
* This source code is licensed under the ISC license.
|
|
120
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
121
|
+
*/const rt=(e,r)=>{const i=M.forwardRef(({className:l,...a},u)=>M.createElement(Lw,{ref:u,iconNode:r,className:pg(`lucide-${Tw(e)}`,l),...a}));return i.displayName=`${e}`,i};/**
|
|
122
|
+
* @license lucide-react v0.469.0 - ISC
|
|
123
|
+
*
|
|
124
|
+
* This source code is licensed under the ISC license.
|
|
125
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
126
|
+
*/const cc=rt("Activity",[["path",{d:"M22 12h-2.48a2 2 0 0 0-1.93 1.46l-2.35 8.36a.25.25 0 0 1-.48 0L9.24 2.18a.25.25 0 0 0-.48 0l-2.35 8.36A2 2 0 0 1 4.49 12H2",key:"169zse"}]]);/**
|
|
127
|
+
* @license lucide-react v0.469.0 - ISC
|
|
128
|
+
*
|
|
129
|
+
* This source code is licensed under the ISC license.
|
|
130
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
131
|
+
*/const mg=rt("ArrowLeft",[["path",{d:"m12 19-7-7 7-7",key:"1l729n"}],["path",{d:"M19 12H5",key:"x3x0zl"}]]);/**
|
|
132
|
+
* @license lucide-react v0.469.0 - ISC
|
|
133
|
+
*
|
|
134
|
+
* This source code is licensed under the ISC license.
|
|
135
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
136
|
+
*/const Rp=rt("BookOpen",[["path",{d:"M12 7v14",key:"1akyts"}],["path",{d:"M3 18a1 1 0 0 1-1-1V4a1 1 0 0 1 1-1h5a4 4 0 0 1 4 4 4 4 0 0 1 4-4h5a1 1 0 0 1 1 1v13a1 1 0 0 1-1 1h-6a3 3 0 0 0-3 3 3 3 0 0 0-3-3z",key:"ruj8y"}]]);/**
|
|
137
|
+
* @license lucide-react v0.469.0 - ISC
|
|
138
|
+
*
|
|
139
|
+
* This source code is licensed under the ISC license.
|
|
140
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
141
|
+
*/const Iw=rt("Check",[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]]);/**
|
|
142
|
+
* @license lucide-react v0.469.0 - ISC
|
|
143
|
+
*
|
|
144
|
+
* This source code is licensed under the ISC license.
|
|
145
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
146
|
+
*/const Mw=rt("ChevronDown",[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]]);/**
|
|
147
|
+
* @license lucide-react v0.469.0 - ISC
|
|
148
|
+
*
|
|
149
|
+
* This source code is licensed under the ISC license.
|
|
150
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
151
|
+
*/const gg=rt("ChevronRight",[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]]);/**
|
|
152
|
+
* @license lucide-react v0.469.0 - ISC
|
|
153
|
+
*
|
|
154
|
+
* This source code is licensed under the ISC license.
|
|
155
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
156
|
+
*/const zw=rt("ChevronUp",[["path",{d:"m18 15-6-6-6 6",key:"153udz"}]]);/**
|
|
157
|
+
* @license lucide-react v0.469.0 - ISC
|
|
158
|
+
*
|
|
159
|
+
* This source code is licensed under the ISC license.
|
|
160
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
161
|
+
*/const Dw=rt("CircleCheck",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]]);/**
|
|
162
|
+
* @license lucide-react v0.469.0 - ISC
|
|
163
|
+
*
|
|
164
|
+
* This source code is licensed under the ISC license.
|
|
165
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
166
|
+
*/const Aw=rt("CircleX",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m15 9-6 6",key:"1uzhvr"}],["path",{d:"m9 9 6 6",key:"z0biqf"}]]);/**
|
|
167
|
+
* @license lucide-react v0.469.0 - ISC
|
|
168
|
+
*
|
|
169
|
+
* This source code is licensed under the ISC license.
|
|
170
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
171
|
+
*/const yg=rt("Clock",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["polyline",{points:"12 6 12 12 16 14",key:"68esgv"}]]);/**
|
|
172
|
+
* @license lucide-react v0.469.0 - ISC
|
|
173
|
+
*
|
|
174
|
+
* This source code is licensed under the ISC license.
|
|
175
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
176
|
+
*/const Ow=rt("Cpu",[["rect",{width:"16",height:"16",x:"4",y:"4",rx:"2",key:"14l7u7"}],["rect",{width:"6",height:"6",x:"9",y:"9",rx:"1",key:"5aljv4"}],["path",{d:"M15 2v2",key:"13l42r"}],["path",{d:"M15 20v2",key:"15mkzm"}],["path",{d:"M2 15h2",key:"1gxd5l"}],["path",{d:"M2 9h2",key:"1bbxkp"}],["path",{d:"M20 15h2",key:"19e6y8"}],["path",{d:"M20 9h2",key:"19tzq7"}],["path",{d:"M9 2v2",key:"165o2o"}],["path",{d:"M9 20v2",key:"i2bqo8"}]]);/**
|
|
177
|
+
* @license lucide-react v0.469.0 - ISC
|
|
178
|
+
*
|
|
179
|
+
* This source code is licensed under the ISC license.
|
|
180
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
181
|
+
*/const vg=rt("Database",[["ellipse",{cx:"12",cy:"5",rx:"9",ry:"3",key:"msslwz"}],["path",{d:"M3 5V19A9 3 0 0 0 21 19V5",key:"1wlel7"}],["path",{d:"M3 12A9 3 0 0 0 21 12",key:"mv7ke4"}]]);/**
|
|
182
|
+
* @license lucide-react v0.469.0 - ISC
|
|
183
|
+
*
|
|
184
|
+
* This source code is licensed under the ISC license.
|
|
185
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
186
|
+
*/const Fw=rt("DollarSign",[["line",{x1:"12",x2:"12",y1:"2",y2:"22",key:"7eqyqh"}],["path",{d:"M17 5H9.5a3.5 3.5 0 0 0 0 7h5a3.5 3.5 0 0 1 0 7H6",key:"1b0p4s"}]]);/**
|
|
187
|
+
* @license lucide-react v0.469.0 - ISC
|
|
188
|
+
*
|
|
189
|
+
* This source code is licensed under the ISC license.
|
|
190
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
191
|
+
*/const Uw=rt("FileText",[["path",{d:"M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z",key:"1rqfz7"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4",key:"tnqrlb"}],["path",{d:"M10 9H8",key:"b1mrlr"}],["path",{d:"M16 13H8",key:"t4e002"}],["path",{d:"M16 17H8",key:"z1uh3a"}]]);/**
|
|
192
|
+
* @license lucide-react v0.469.0 - ISC
|
|
193
|
+
*
|
|
194
|
+
* This source code is licensed under the ISC license.
|
|
195
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
196
|
+
*/const xg=rt("LoaderCircle",[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]]);/**
|
|
197
|
+
* @license lucide-react v0.469.0 - ISC
|
|
198
|
+
*
|
|
199
|
+
* This source code is licensed under the ISC license.
|
|
200
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
201
|
+
*/const ss=rt("MessageSquare",[["path",{d:"M21 15a2 2 0 0 1-2 2H7l-4 4V5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2z",key:"1lielz"}]]);/**
|
|
202
|
+
* @license lucide-react v0.469.0 - ISC
|
|
203
|
+
*
|
|
204
|
+
* This source code is licensed under the ISC license.
|
|
205
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
206
|
+
*/const Bw=rt("Moon",[["path",{d:"M12 3a6 6 0 0 0 9 9 9 9 0 1 1-9-9Z",key:"a7tn18"}]]);/**
|
|
207
|
+
* @license lucide-react v0.469.0 - ISC
|
|
208
|
+
*
|
|
209
|
+
* This source code is licensed under the ISC license.
|
|
210
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
211
|
+
*/const wg=rt("Play",[["polygon",{points:"6 3 20 12 6 21 6 3",key:"1oa8hb"}]]);/**
|
|
212
|
+
* @license lucide-react v0.469.0 - ISC
|
|
213
|
+
*
|
|
214
|
+
* This source code is licensed under the ISC license.
|
|
215
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
216
|
+
*/const Lp=rt("Plug",[["path",{d:"M12 22v-5",key:"1ega77"}],["path",{d:"M9 8V2",key:"14iosj"}],["path",{d:"M15 8V2",key:"18g5xt"}],["path",{d:"M18 8v5a4 4 0 0 1-4 4h-4a4 4 0 0 1-4-4V8Z",key:"osxo6l"}]]);/**
|
|
217
|
+
* @license lucide-react v0.469.0 - ISC
|
|
218
|
+
*
|
|
219
|
+
* This source code is licensed under the ISC license.
|
|
220
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
221
|
+
*/const Hw=rt("Send",[["path",{d:"M14.536 21.686a.5.5 0 0 0 .937-.024l6.5-19a.496.496 0 0 0-.635-.635l-19 6.5a.5.5 0 0 0-.024.937l7.93 3.18a2 2 0 0 1 1.112 1.11z",key:"1ffxy3"}],["path",{d:"m21.854 2.147-10.94 10.939",key:"12cjpa"}]]);/**
|
|
222
|
+
* @license lucide-react v0.469.0 - ISC
|
|
223
|
+
*
|
|
224
|
+
* This source code is licensed under the ISC license.
|
|
225
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
226
|
+
*/const Ip=rt("Sparkles",[["path",{d:"M9.937 15.5A2 2 0 0 0 8.5 14.063l-6.135-1.582a.5.5 0 0 1 0-.962L8.5 9.936A2 2 0 0 0 9.937 8.5l1.582-6.135a.5.5 0 0 1 .963 0L14.063 8.5A2 2 0 0 0 15.5 9.937l6.135 1.581a.5.5 0 0 1 0 .964L15.5 14.063a2 2 0 0 0-1.437 1.437l-1.582 6.135a.5.5 0 0 1-.963 0z",key:"4pj2yx"}],["path",{d:"M20 3v4",key:"1olli1"}],["path",{d:"M22 5h-4",key:"1gvqau"}],["path",{d:"M4 17v2",key:"vumght"}],["path",{d:"M5 18H3",key:"zchphs"}]]);/**
|
|
227
|
+
* @license lucide-react v0.469.0 - ISC
|
|
228
|
+
*
|
|
229
|
+
* This source code is licensed under the ISC license.
|
|
230
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
231
|
+
*/const Vw=rt("SquarePen",[["path",{d:"M12 3H5a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2v-7",key:"1m0v6g"}],["path",{d:"M18.375 2.625a1 1 0 0 1 3 3l-9.013 9.014a2 2 0 0 1-.853.505l-2.873.84a.5.5 0 0 1-.62-.62l.84-2.873a2 2 0 0 1 .506-.852z",key:"ohrbg2"}]]);/**
|
|
232
|
+
* @license lucide-react v0.469.0 - ISC
|
|
233
|
+
*
|
|
234
|
+
* This source code is licensed under the ISC license.
|
|
235
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
236
|
+
*/const $w=rt("Square",[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}]]);/**
|
|
237
|
+
* @license lucide-react v0.469.0 - ISC
|
|
238
|
+
*
|
|
239
|
+
* This source code is licensed under the ISC license.
|
|
240
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
241
|
+
*/const Ww=rt("Sun",[["circle",{cx:"12",cy:"12",r:"4",key:"4exip2"}],["path",{d:"M12 2v2",key:"tus03m"}],["path",{d:"M12 20v2",key:"1lh1kg"}],["path",{d:"m4.93 4.93 1.41 1.41",key:"149t6j"}],["path",{d:"m17.66 17.66 1.41 1.41",key:"ptbguv"}],["path",{d:"M2 12h2",key:"1t8f8n"}],["path",{d:"M20 12h2",key:"1q8mjw"}],["path",{d:"m6.34 17.66-1.41 1.41",key:"1m8zz5"}],["path",{d:"m19.07 4.93-1.41 1.41",key:"1shlcs"}]]);/**
|
|
242
|
+
* @license lucide-react v0.469.0 - ISC
|
|
243
|
+
*
|
|
244
|
+
* This source code is licensed under the ISC license.
|
|
245
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
246
|
+
*/const Qw=rt("Wrench",[["path",{d:"M14.7 6.3a1 1 0 0 0 0 1.4l1.6 1.6a1 1 0 0 0 1.4 0l3.77-3.77a6 6 0 0 1-7.94 7.94l-6.91 6.91a2.12 2.12 0 0 1-3-3l6.91-6.91a6 6 0 0 1 7.94-7.94l-3.76 3.76z",key:"cbrjhi"}]]);/**
|
|
247
|
+
* @license lucide-react v0.469.0 - ISC
|
|
248
|
+
*
|
|
249
|
+
* This source code is licensed under the ISC license.
|
|
250
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
251
|
+
*/const kg=rt("X",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]]);/**
|
|
252
|
+
* @license lucide-react v0.469.0 - ISC
|
|
253
|
+
*
|
|
254
|
+
* This source code is licensed under the ISC license.
|
|
255
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
256
|
+
*/const Po=rt("Zap",[["path",{d:"M4 14a1 1 0 0 1-.78-1.63l9.9-10.2a.5.5 0 0 1 .86.46l-1.92 6.02A1 1 0 0 0 13 10h7a1 1 0 0 1 .78 1.63l-9.9 10.2a.5.5 0 0 1-.86-.46l1.92-6.02A1 1 0 0 0 11 14z",key:"1xq2db"}]]),qw="modulepreload",Kw=function(e){return"/"+e},Mp={},Gw=function(r,i,l){let a=Promise.resolve();if(i&&i.length>0){let c=function(m){return Promise.all(m.map(g=>Promise.resolve(g).then(y=>({status:"fulfilled",value:y}),y=>({status:"rejected",reason:y}))))};document.getElementsByTagName("link");const f=document.querySelector("meta[property=csp-nonce]"),p=(f==null?void 0:f.nonce)||(f==null?void 0:f.getAttribute("nonce"));a=c(i.map(m=>{if(m=Kw(m),m in Mp)return;Mp[m]=!0;const g=m.endsWith(".css"),y=g?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${m}"]${y}`))return;const k=document.createElement("link");if(k.rel=g?"stylesheet":qw,g||(k.as="script"),k.crossOrigin="",k.href=m,p&&k.setAttribute("nonce",p),document.head.appendChild(k),g)return new Promise((x,T)=>{k.addEventListener("load",x),k.addEventListener("error",()=>T(new Error(`Unable to preload CSS for ${m}`)))})}))}function u(c){const f=new Event("vite:preloadError",{cancelable:!0});if(f.payload=c,window.dispatchEvent(f),!f.defaultPrevented)throw c}return a.then(c=>{for(const f of c||[])f.status==="rejected"&&u(f.reason);return r().catch(u)})};function Sg(e){var r,i,l="";if(typeof e=="string"||typeof e=="number")l+=e;else if(typeof e=="object")if(Array.isArray(e)){var a=e.length;for(r=0;r<a;r++)e[r]&&(i=Sg(e[r]))&&(l&&(l+=" "),l+=i)}else for(i in e)e[i]&&(l&&(l+=" "),l+=i);return l}function Yw(){for(var e,r,i=0,l="",a=arguments.length;i<a;i++)(e=arguments[i])&&(r=Sg(e))&&(l&&(l+=" "),l+=r);return l}const rd="-",Xw=e=>{const r=Zw(e),{conflictingClassGroups:i,conflictingClassGroupModifiers:l}=e;return{getClassGroupId:c=>{const f=c.split(rd);return f[0]===""&&f.length!==1&&f.shift(),Eg(f,r)||Jw(c)},getConflictingClassGroupIds:(c,f)=>{const p=i[c]||[];return f&&l[c]?[...p,...l[c]]:p}}},Eg=(e,r)=>{var c;if(e.length===0)return r.classGroupId;const i=e[0],l=r.nextPart.get(i),a=l?Eg(e.slice(1),l):void 0;if(a)return a;if(r.validators.length===0)return;const u=e.join(rd);return(c=r.validators.find(({validator:f})=>f(u)))==null?void 0:c.classGroupId},zp=/^\[(.+)\]$/,Jw=e=>{if(zp.test(e)){const r=zp.exec(e)[1],i=r==null?void 0:r.substring(0,r.indexOf(":"));if(i)return"arbitrary.."+i}},Zw=e=>{const{theme:r,prefix:i}=e,l={nextPart:new Map,validators:[]};return t1(Object.entries(e.classGroups),i).forEach(([u,c])=>{Mc(c,l,u,r)}),l},Mc=(e,r,i,l)=>{e.forEach(a=>{if(typeof a=="string"){const u=a===""?r:Dp(r,a);u.classGroupId=i;return}if(typeof a=="function"){if(e1(a)){Mc(a(l),r,i,l);return}r.validators.push({validator:a,classGroupId:i});return}Object.entries(a).forEach(([u,c])=>{Mc(c,Dp(r,u),i,l)})})},Dp=(e,r)=>{let i=e;return r.split(rd).forEach(l=>{i.nextPart.has(l)||i.nextPart.set(l,{nextPart:new Map,validators:[]}),i=i.nextPart.get(l)}),i},e1=e=>e.isThemeGetter,t1=(e,r)=>r?e.map(([i,l])=>{const a=l.map(u=>typeof u=="string"?r+u:typeof u=="object"?Object.fromEntries(Object.entries(u).map(([c,f])=>[r+c,f])):u);return[i,a]}):e,n1=e=>{if(e<1)return{get:()=>{},set:()=>{}};let r=0,i=new Map,l=new Map;const a=(u,c)=>{i.set(u,c),r++,r>e&&(r=0,l=i,i=new Map)};return{get(u){let c=i.get(u);if(c!==void 0)return c;if((c=l.get(u))!==void 0)return a(u,c),c},set(u,c){i.has(u)?i.set(u,c):a(u,c)}}},Cg="!",r1=e=>{const{separator:r,experimentalParseClassName:i}=e,l=r.length===1,a=r[0],u=r.length,c=f=>{const p=[];let m=0,g=0,y;for(let b=0;b<f.length;b++){let P=f[b];if(m===0){if(P===a&&(l||f.slice(b,b+u)===r)){p.push(f.slice(g,b)),g=b+u;continue}if(P==="/"){y=b;continue}}P==="["?m++:P==="]"&&m--}const k=p.length===0?f:f.substring(g),x=k.startsWith(Cg),T=x?k.substring(1):k,N=y&&y>g?y-g:void 0;return{modifiers:p,hasImportantModifier:x,baseClassName:T,maybePostfixModifierPosition:N}};return i?f=>i({className:f,parseClassName:c}):c},i1=e=>{if(e.length<=1)return e;const r=[];let i=[];return e.forEach(l=>{l[0]==="["?(r.push(...i.sort(),l),i=[]):i.push(l)}),r.push(...i.sort()),r},l1=e=>({cache:n1(e.cacheSize),parseClassName:r1(e),...Xw(e)}),o1=/\s+/,a1=(e,r)=>{const{parseClassName:i,getClassGroupId:l,getConflictingClassGroupIds:a}=r,u=[],c=e.trim().split(o1);let f="";for(let p=c.length-1;p>=0;p-=1){const m=c[p],{modifiers:g,hasImportantModifier:y,baseClassName:k,maybePostfixModifierPosition:x}=i(m);let T=!!x,N=l(T?k.substring(0,x):k);if(!N){if(!T){f=m+(f.length>0?" "+f:f);continue}if(N=l(k),!N){f=m+(f.length>0?" "+f:f);continue}T=!1}const b=i1(g).join(":"),P=y?b+Cg:b,z=P+N;if(u.includes(z))continue;u.push(z);const I=a(N,T);for(let F=0;F<I.length;++F){const ee=I[F];u.push(P+ee)}f=m+(f.length>0?" "+f:f)}return f};function s1(){let e=0,r,i,l="";for(;e<arguments.length;)(r=arguments[e++])&&(i=bg(r))&&(l&&(l+=" "),l+=i);return l}const bg=e=>{if(typeof e=="string")return e;let r,i="";for(let l=0;l<e.length;l++)e[l]&&(r=bg(e[l]))&&(i&&(i+=" "),i+=r);return i};function u1(e,...r){let i,l,a,u=c;function c(p){const m=r.reduce((g,y)=>y(g),e());return i=l1(m),l=i.cache.get,a=i.cache.set,u=f,f(p)}function f(p){const m=l(p);if(m)return m;const g=a1(p,i);return a(p,g),g}return function(){return u(s1.apply(null,arguments))}}const ct=e=>{const r=i=>i[e]||[];return r.isThemeGetter=!0,r},Ng=/^\[(?:([a-z-]+):)?(.+)\]$/i,c1=/^\d+\/\d+$/,d1=new Set(["px","full","screen"]),f1=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,h1=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,p1=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/,m1=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,g1=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,fr=e=>cl(e)||d1.has(e)||c1.test(e),Hr=e=>El(e,"length",C1),cl=e=>!!e&&!Number.isNaN(Number(e)),dc=e=>El(e,"number",cl),ho=e=>!!e&&Number.isInteger(Number(e)),y1=e=>e.endsWith("%")&&cl(e.slice(0,-1)),Ae=e=>Ng.test(e),Vr=e=>f1.test(e),v1=new Set(["length","size","percentage"]),x1=e=>El(e,v1,Pg),w1=e=>El(e,"position",Pg),k1=new Set(["image","url"]),S1=e=>El(e,k1,N1),E1=e=>El(e,"",b1),po=()=>!0,El=(e,r,i)=>{const l=Ng.exec(e);return l?l[1]?typeof r=="string"?l[1]===r:r.has(l[1]):i(l[2]):!1},C1=e=>h1.test(e)&&!p1.test(e),Pg=()=>!1,b1=e=>m1.test(e),N1=e=>g1.test(e),P1=()=>{const e=ct("colors"),r=ct("spacing"),i=ct("blur"),l=ct("brightness"),a=ct("borderColor"),u=ct("borderRadius"),c=ct("borderSpacing"),f=ct("borderWidth"),p=ct("contrast"),m=ct("grayscale"),g=ct("hueRotate"),y=ct("invert"),k=ct("gap"),x=ct("gradientColorStops"),T=ct("gradientColorStopPositions"),N=ct("inset"),b=ct("margin"),P=ct("opacity"),z=ct("padding"),I=ct("saturate"),F=ct("scale"),ee=ct("sepia"),B=ct("skew"),D=ct("space"),G=ct("translate"),le=()=>["auto","contain","none"],re=()=>["auto","hidden","clip","visible","scroll"],$=()=>["auto",Ae,r],K=()=>[Ae,r],Se=()=>["",fr,Hr],se=()=>["auto",cl,Ae],ne=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],be=()=>["solid","dashed","dotted","double","none"],_e=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],Y=()=>["start","end","center","between","around","evenly","stretch"],ce=()=>["","0",Ae],S=()=>["auto","avoid","all","avoid-page","page","left","right","column"],R=()=>[cl,Ae];return{cacheSize:500,separator:":",theme:{colors:[po],spacing:[fr,Hr],blur:["none","",Vr,Ae],brightness:R(),borderColor:[e],borderRadius:["none","","full",Vr,Ae],borderSpacing:K(),borderWidth:Se(),contrast:R(),grayscale:ce(),hueRotate:R(),invert:ce(),gap:K(),gradientColorStops:[e],gradientColorStopPositions:[y1,Hr],inset:$(),margin:$(),opacity:R(),padding:K(),saturate:R(),scale:R(),sepia:ce(),skew:R(),space:K(),translate:K()},classGroups:{aspect:[{aspect:["auto","square","video",Ae]}],container:["container"],columns:[{columns:[Vr]}],"break-after":[{"break-after":S()}],"break-before":[{"break-before":S()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:[...ne(),Ae]}],overflow:[{overflow:re()}],"overflow-x":[{"overflow-x":re()}],"overflow-y":[{"overflow-y":re()}],overscroll:[{overscroll:le()}],"overscroll-x":[{"overscroll-x":le()}],"overscroll-y":[{"overscroll-y":le()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[N]}],"inset-x":[{"inset-x":[N]}],"inset-y":[{"inset-y":[N]}],start:[{start:[N]}],end:[{end:[N]}],top:[{top:[N]}],right:[{right:[N]}],bottom:[{bottom:[N]}],left:[{left:[N]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",ho,Ae]}],basis:[{basis:$()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",Ae]}],grow:[{grow:ce()}],shrink:[{shrink:ce()}],order:[{order:["first","last","none",ho,Ae]}],"grid-cols":[{"grid-cols":[po]}],"col-start-end":[{col:["auto",{span:["full",ho,Ae]},Ae]}],"col-start":[{"col-start":se()}],"col-end":[{"col-end":se()}],"grid-rows":[{"grid-rows":[po]}],"row-start-end":[{row:["auto",{span:[ho,Ae]},Ae]}],"row-start":[{"row-start":se()}],"row-end":[{"row-end":se()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",Ae]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",Ae]}],gap:[{gap:[k]}],"gap-x":[{"gap-x":[k]}],"gap-y":[{"gap-y":[k]}],"justify-content":[{justify:["normal",...Y()]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal",...Y(),"baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":[...Y(),"baseline"]}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[z]}],px:[{px:[z]}],py:[{py:[z]}],ps:[{ps:[z]}],pe:[{pe:[z]}],pt:[{pt:[z]}],pr:[{pr:[z]}],pb:[{pb:[z]}],pl:[{pl:[z]}],m:[{m:[b]}],mx:[{mx:[b]}],my:[{my:[b]}],ms:[{ms:[b]}],me:[{me:[b]}],mt:[{mt:[b]}],mr:[{mr:[b]}],mb:[{mb:[b]}],ml:[{ml:[b]}],"space-x":[{"space-x":[D]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[D]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",Ae,r]}],"min-w":[{"min-w":[Ae,r,"min","max","fit"]}],"max-w":[{"max-w":[Ae,r,"none","full","min","max","fit","prose",{screen:[Vr]},Vr]}],h:[{h:[Ae,r,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[Ae,r,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[Ae,r,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[Ae,r,"auto","min","max","fit"]}],"font-size":[{text:["base",Vr,Hr]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",dc]}],"font-family":[{font:[po]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractions"],tracking:[{tracking:["tighter","tight","normal","wide","wider","widest",Ae]}],"line-clamp":[{"line-clamp":["none",cl,dc]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",fr,Ae]}],"list-image":[{"list-image":["none",Ae]}],"list-style-type":[{list:["none","disc","decimal",Ae]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[e]}],"placeholder-opacity":[{"placeholder-opacity":[P]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[e]}],"text-opacity":[{"text-opacity":[P]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...be(),"wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",fr,Hr]}],"underline-offset":[{"underline-offset":["auto",fr,Ae]}],"text-decoration-color":[{decoration:[e]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:K()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",Ae]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",Ae]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[P]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[...ne(),w1]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",x1]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},S1]}],"bg-color":[{bg:[e]}],"gradient-from-pos":[{from:[T]}],"gradient-via-pos":[{via:[T]}],"gradient-to-pos":[{to:[T]}],"gradient-from":[{from:[x]}],"gradient-via":[{via:[x]}],"gradient-to":[{to:[x]}],rounded:[{rounded:[u]}],"rounded-s":[{"rounded-s":[u]}],"rounded-e":[{"rounded-e":[u]}],"rounded-t":[{"rounded-t":[u]}],"rounded-r":[{"rounded-r":[u]}],"rounded-b":[{"rounded-b":[u]}],"rounded-l":[{"rounded-l":[u]}],"rounded-ss":[{"rounded-ss":[u]}],"rounded-se":[{"rounded-se":[u]}],"rounded-ee":[{"rounded-ee":[u]}],"rounded-es":[{"rounded-es":[u]}],"rounded-tl":[{"rounded-tl":[u]}],"rounded-tr":[{"rounded-tr":[u]}],"rounded-br":[{"rounded-br":[u]}],"rounded-bl":[{"rounded-bl":[u]}],"border-w":[{border:[f]}],"border-w-x":[{"border-x":[f]}],"border-w-y":[{"border-y":[f]}],"border-w-s":[{"border-s":[f]}],"border-w-e":[{"border-e":[f]}],"border-w-t":[{"border-t":[f]}],"border-w-r":[{"border-r":[f]}],"border-w-b":[{"border-b":[f]}],"border-w-l":[{"border-l":[f]}],"border-opacity":[{"border-opacity":[P]}],"border-style":[{border:[...be(),"hidden"]}],"divide-x":[{"divide-x":[f]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[f]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[P]}],"divide-style":[{divide:be()}],"border-color":[{border:[a]}],"border-color-x":[{"border-x":[a]}],"border-color-y":[{"border-y":[a]}],"border-color-s":[{"border-s":[a]}],"border-color-e":[{"border-e":[a]}],"border-color-t":[{"border-t":[a]}],"border-color-r":[{"border-r":[a]}],"border-color-b":[{"border-b":[a]}],"border-color-l":[{"border-l":[a]}],"divide-color":[{divide:[a]}],"outline-style":[{outline:["",...be()]}],"outline-offset":[{"outline-offset":[fr,Ae]}],"outline-w":[{outline:[fr,Hr]}],"outline-color":[{outline:[e]}],"ring-w":[{ring:Se()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[e]}],"ring-opacity":[{"ring-opacity":[P]}],"ring-offset-w":[{"ring-offset":[fr,Hr]}],"ring-offset-color":[{"ring-offset":[e]}],shadow:[{shadow:["","inner","none",Vr,E1]}],"shadow-color":[{shadow:[po]}],opacity:[{opacity:[P]}],"mix-blend":[{"mix-blend":[..._e(),"plus-lighter","plus-darker"]}],"bg-blend":[{"bg-blend":_e()}],filter:[{filter:["","none"]}],blur:[{blur:[i]}],brightness:[{brightness:[l]}],contrast:[{contrast:[p]}],"drop-shadow":[{"drop-shadow":["","none",Vr,Ae]}],grayscale:[{grayscale:[m]}],"hue-rotate":[{"hue-rotate":[g]}],invert:[{invert:[y]}],saturate:[{saturate:[I]}],sepia:[{sepia:[ee]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[i]}],"backdrop-brightness":[{"backdrop-brightness":[l]}],"backdrop-contrast":[{"backdrop-contrast":[p]}],"backdrop-grayscale":[{"backdrop-grayscale":[m]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[g]}],"backdrop-invert":[{"backdrop-invert":[y]}],"backdrop-opacity":[{"backdrop-opacity":[P]}],"backdrop-saturate":[{"backdrop-saturate":[I]}],"backdrop-sepia":[{"backdrop-sepia":[ee]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[c]}],"border-spacing-x":[{"border-spacing-x":[c]}],"border-spacing-y":[{"border-spacing-y":[c]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",Ae]}],duration:[{duration:R()}],ease:[{ease:["linear","in","out","in-out",Ae]}],delay:[{delay:R()}],animate:[{animate:["none","spin","ping","pulse","bounce",Ae]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[F]}],"scale-x":[{"scale-x":[F]}],"scale-y":[{"scale-y":[F]}],rotate:[{rotate:[ho,Ae]}],"translate-x":[{"translate-x":[G]}],"translate-y":[{"translate-y":[G]}],"skew-x":[{"skew-x":[B]}],"skew-y":[{"skew-y":[B]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",Ae]}],accent:[{accent:["auto",e]}],appearance:[{appearance:["none","auto"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",Ae]}],"caret-color":[{caret:[e]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":K()}],"scroll-mx":[{"scroll-mx":K()}],"scroll-my":[{"scroll-my":K()}],"scroll-ms":[{"scroll-ms":K()}],"scroll-me":[{"scroll-me":K()}],"scroll-mt":[{"scroll-mt":K()}],"scroll-mr":[{"scroll-mr":K()}],"scroll-mb":[{"scroll-mb":K()}],"scroll-ml":[{"scroll-ml":K()}],"scroll-p":[{"scroll-p":K()}],"scroll-px":[{"scroll-px":K()}],"scroll-py":[{"scroll-py":K()}],"scroll-ps":[{"scroll-ps":K()}],"scroll-pe":[{"scroll-pe":K()}],"scroll-pt":[{"scroll-pt":K()}],"scroll-pr":[{"scroll-pr":K()}],"scroll-pb":[{"scroll-pb":K()}],"scroll-pl":[{"scroll-pl":K()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",Ae]}],fill:[{fill:[e,"none"]}],"stroke-w":[{stroke:[fr,Hr,dc]}],stroke:[{stroke:[e,"none"]}],sr:["sr-only","not-sr-only"],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-s","border-color-e","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]}}},j1=u1(P1);/**
|
|
257
|
+
* @license
|
|
258
|
+
* Copyright 2025 Amodal Labs, Inc.
|
|
259
|
+
* SPDX-License-Identifier: MIT
|
|
260
|
+
*/function gs(...e){return j1(Yw(e))}function Ap({to:e,children:r,end:i}){return v.jsx(eg,{to:e,end:i,className:({isActive:l})=>gs("flex items-center gap-2.5 px-3 py-[7px] rounded-md text-[13px] transition-colors duration-150",l?"bg-indigo-500/10 text-indigo-600 dark:text-indigo-400 font-medium":"text-gray-500 dark:text-white/50 hover:text-gray-800 dark:hover:text-white/80 hover:bg-gray-100 dark:hover:bg-white/[0.04]"),children:r})}function Ga({children:e,action:r}){return v.jsxs("div",{className:"px-3 pt-5 pb-1.5 flex items-center justify-between",children:[v.jsx("span",{className:"text-[10px] font-semibold text-gray-400 dark:text-white/25 uppercase tracking-widest",children:e}),r]})}function Ya({label:e,icon:r,children:i,count:l}){const[a,u]=M.useState(!1);return v.jsxs("div",{children:[v.jsxs("button",{onClick:()=>u(!a),className:"flex items-center gap-2 w-full px-3 py-[7px] rounded-md text-[13px] text-gray-500 dark:text-white/50 hover:text-gray-800 dark:hover:text-white/80 hover:bg-gray-100 dark:hover:bg-white/[0.04] transition-colors",children:[v.jsx(gg,{className:gs("h-3 w-3 shrink-0 transition-transform",a&&"rotate-90")}),r,v.jsx("span",{className:"flex-1 text-left",children:e}),v.jsx("span",{className:"text-[11px] text-gray-400 dark:text-white/25",children:String(l)})]}),a&&v.jsx("div",{className:"ml-3 space-y-0.5",children:i})]})}function Xa({icon:e,label:r}){return v.jsxs("div",{className:"flex items-center gap-2.5 px-3 py-[6px] text-[13px] text-gray-400 dark:text-white/40",children:[e,v.jsx("span",{className:"truncate",children:r})]})}function _1(){const{stores:e,connections:r,skills:i,automations:l,knowledge:a}=Mo(),[u,c]=M.useState([]),[f,p]=M.useState([]),m=Sl(),g=ri();return M.useEffect(()=>{fetch("/api/pages").then(y=>y.ok?y.json():null).then(y=>{if(y&&typeof y=="object"&&"pages"in y&&Array.isArray(y.pages)){const k=y.pages;c(k.map(x=>({name:x.name,filePath:""})))}}).catch(()=>{Gw(()=>import("./_virtual_amodal-manifest-DIezHQq3.js"),[]).then(y=>{c(y.pages.filter(k=>!k.hidden))}).catch(()=>{})})},[]),M.useEffect(()=>{fetch("/sessions").then(y=>y.ok?y.json():{sessions:[]}).then(y=>{if(y&&typeof y=="object"&&"sessions"in y&&Array.isArray(y.sessions)){const k=y.sessions;p(k.slice(0,10))}}).catch(()=>{})},[g.pathname]),v.jsx("aside",{className:"w-[260px] border-r border-gray-200 dark:border-white/[0.06] bg-gray-50 dark:bg-[#0f0f17] flex flex-col shrink-0 overflow-hidden",children:v.jsxs("nav",{className:"flex-1 overflow-y-auto scrollbar-thin px-2 py-2",children:[v.jsxs("button",{onClick:()=>{m("/")},className:"flex items-center gap-2.5 w-full px-3 py-2 mb-1 rounded-md text-[13px] text-gray-500 dark:text-white/60 hover:text-gray-800 dark:hover:text-white/90 hover:bg-gray-100 dark:hover:bg-white/[0.04] transition-colors",children:[v.jsx(Vw,{className:"h-4 w-4 shrink-0"}),"New chat"]}),f.length>0&&v.jsxs(v.Fragment,{children:[v.jsx(Ga,{action:v.jsx(eg,{to:"/sessions",className:"text-[10px] text-gray-400 dark:text-white/20 hover:text-gray-600 dark:hover:text-white/40 transition-colors",children:"View all"}),children:"Recent"}),v.jsx("div",{className:"space-y-0.5",children:f.map(y=>{const k=g.search.includes(y.id);return v.jsxs("button",{onClick:()=>{m(`/?resume=${y.id}`)},className:gs("flex items-center gap-2 w-full px-3 py-[6px] rounded-md text-[12px] text-left transition-colors duration-150 truncate",k?"bg-indigo-500/10 text-indigo-600 dark:text-indigo-400":"text-gray-400 dark:text-white/40 hover:text-gray-700 dark:hover:text-white/70 hover:bg-gray-100 dark:hover:bg-white/[0.03]"),children:[v.jsx(ss,{className:"h-3 w-3 shrink-0 opacity-40"}),v.jsx("span",{className:"truncate",children:y.summary})]},y.id)})})]}),u.length>0&&v.jsxs(v.Fragment,{children:[v.jsx(Ga,{children:"Pages"}),v.jsx("div",{className:"space-y-0.5",children:u.map(y=>v.jsxs(Ap,{to:`/pages/${y.name}`,children:[v.jsx(Uw,{className:"h-4 w-4 shrink-0"}),v.jsx("span",{className:"truncate",children:T1(y.name)})]},y.name))})]}),(r.length>0||i.length>0||a.length>0||l.length>0)&&v.jsx(Ga,{children:"Agent"}),r.length>0&&v.jsx(Ya,{label:"Connections",icon:v.jsx(Lp,{className:"h-3.5 w-3.5 shrink-0 text-emerald-500/60"}),count:r.length,children:r.map(y=>v.jsx(Xa,{icon:v.jsx(Lp,{className:"h-3 w-3 shrink-0 text-emerald-500/40"}),label:y},y))}),i.length>0&&v.jsx(Ya,{label:"Skills",icon:v.jsx(Ip,{className:"h-3.5 w-3.5 shrink-0 text-amber-500/60"}),count:i.length,children:i.map(y=>v.jsx(Xa,{icon:v.jsx(Ip,{className:"h-3 w-3 shrink-0 text-amber-500/40"}),label:y},y))}),a.length>0&&v.jsx(Ya,{label:"Knowledge",icon:v.jsx(Rp,{className:"h-3.5 w-3.5 shrink-0 text-blue-500/60"}),count:a.length,children:a.map(y=>v.jsx(Xa,{icon:v.jsx(Rp,{className:"h-3 w-3 shrink-0 text-blue-500/40"}),label:y},y))}),l.length>0&&v.jsx(Ya,{label:"Automations",icon:v.jsx(Po,{className:"h-3.5 w-3.5 shrink-0 text-purple-500/60"}),count:l.length,children:l.map(y=>v.jsx(Xa,{icon:v.jsx(Po,{className:"h-3 w-3 shrink-0 text-purple-500/40"}),label:y},y))}),e.length>0&&v.jsxs(v.Fragment,{children:[v.jsx(Ga,{children:"Entities"}),v.jsx("div",{className:"space-y-0.5",children:e.map(y=>v.jsxs(Ap,{to:`/entities/${y.name}`,children:[v.jsx(vg,{className:"h-4 w-4 shrink-0"}),v.jsx("span",{className:"flex-1 truncate",children:y.entity.name}),y.documentCount>0&&v.jsx("span",{className:"text-[11px] text-gray-400 dark:text-white/30 tabular-nums bg-gray-200 dark:bg-white/[0.06] px-1.5 py-0.5 rounded-full",children:y.documentCount.toLocaleString()})]},y.name))})]})]})})}function T1(e){return e.replace(/[-_]/g," ").replace(/\b\w/g,r=>r.toUpperCase())}function R1({isOpen:e,onClose:r}){return e?v.jsxs("div",{className:"w-[380px] border-l border-gray-200 bg-white flex flex-col shrink-0 animate-slide-in-right",children:[v.jsxs("div",{className:"flex items-center justify-between px-4 py-3 border-b border-gray-200",children:[v.jsx("span",{className:"text-sm font-medium text-gray-900",children:"Chat"}),v.jsx("button",{onClick:r,className:"h-6 w-6 rounded flex items-center justify-center text-gray-400 hover:text-gray-600 hover:bg-gray-100 transition-colors",children:v.jsx(kg,{className:"h-4 w-4"})})]}),v.jsx("div",{className:"flex-1 overflow-hidden",children:v.jsx(Nw,{})})]}):null}function L1(){const[e,r]=M.useState(()=>document.documentElement.classList.contains("dark")),i=M.useCallback(()=>{const l=!e;r(l),document.documentElement.classList.toggle("dark",l);try{localStorage.setItem("amodal-theme",l?"dark":"light")}catch{}},[e]);return M.useEffect(()=>{try{localStorage.getItem("amodal-theme")==="light"&&(r(!1),document.documentElement.classList.remove("dark"))}catch{}},[]),{dark:e,toggle:i}}function I1(){const[e,r]=M.useState(!1),l=ri().pathname==="/",{name:a,model:u}=Mo(),{dark:c,toggle:f}=L1();return v.jsxs("div",{className:"flex flex-col h-screen overflow-hidden bg-white dark:bg-[#0a0a0f]",children:[v.jsxs("header",{className:"h-14 bg-gray-50 dark:bg-[#0f0f17] border-b border-gray-200 dark:border-white/[0.06] text-gray-900 dark:text-white flex items-center justify-between px-5 shrink-0 z-20",children:[v.jsxs("div",{className:"flex items-center gap-3",children:[v.jsxs("svg",{width:"24",height:"24",viewBox:"0 0 32 32",fill:"none",children:[v.jsx("defs",{children:v.jsx("clipPath",{id:"logo-sq",children:v.jsx("rect",{x:"2",y:"10",width:"17",height:"17",rx:"3"})})}),v.jsx("rect",{x:"2",y:"10",width:"17",height:"17",rx:"3",fill:"#1E40AF"}),v.jsx("circle",{cx:"22",cy:"11",r:"10",fill:"#60A5FA",fillOpacity:"0.85"}),v.jsx("circle",{cx:"22",cy:"11",r:"10",fill:"#3B82F6",clipPath:"url(#logo-sq)"})]}),v.jsxs("div",{className:"flex items-center gap-2",children:[v.jsx("span",{className:"font-semibold tracking-tight text-[15px] text-gray-900 dark:text-white/90",children:"amodal"}),a&&v.jsxs(v.Fragment,{children:[v.jsx("span",{className:"text-gray-300 dark:text-white/20",children:"/"}),v.jsx("span",{className:"text-[13px] text-gray-500 dark:text-white/50 font-medium",children:a})]})]})]}),v.jsxs("div",{className:"flex items-center gap-3",children:[v.jsx("button",{onClick:f,className:"h-8 w-8 rounded-lg flex items-center justify-center text-gray-400 dark:text-white/30 hover:text-gray-600 dark:hover:text-white/60 hover:bg-gray-100 dark:hover:bg-white/[0.06] transition-colors",title:c?"Switch to light mode":"Switch to dark mode",children:c?v.jsx(Ww,{className:"h-4 w-4"}):v.jsx(Bw,{className:"h-4 w-4"})}),u&&v.jsx("span",{className:"text-[11px] text-gray-400 dark:text-white/25 font-mono",children:u.replace(/-\d{8}$/,"")}),v.jsxs("div",{className:"flex items-center gap-2",children:[v.jsx("div",{className:"h-2 w-2 rounded-full bg-emerald-400 animate-pulse"}),v.jsx("span",{className:"text-[11px] text-gray-400 dark:text-white/40 font-medium tracking-wide uppercase",children:"Connected"})]})]})]}),v.jsxs("div",{className:"flex flex-1 overflow-hidden",children:[v.jsx(_1,{}),v.jsx("main",{className:"flex-1 overflow-auto bg-white dark:bg-[#0a0a0f] scrollbar-thin",children:v.jsx(yx,{})}),!l&&!e&&v.jsx("button",{onClick:()=>r(!0),className:"fixed bottom-6 right-6 h-12 w-12 rounded-full bg-indigo-600 text-white shadow-lg shadow-indigo-500/20 flex items-center justify-center hover:bg-indigo-500 transition-colors z-10",title:"Open chat",children:v.jsx(ss,{className:"h-5 w-5"})}),!l&&v.jsx(R1,{isOpen:e,onClose:()=>r(!1)})]})]})}function M1(e,r){const i={};return(e[e.length-1]===""?[...e,""]:e).join((i.padRight?" ":"")+","+(i.padLeft===!1?"":" ")).trim()}const z1=/^[$_\p{ID_Start}][$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,D1=/^[$_\p{ID_Start}][-$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,A1={};function Op(e,r){return(A1.jsx?D1:z1).test(e)}const O1=/[ \t\n\f\r]/g;function F1(e){return typeof e=="object"?e.type==="text"?Fp(e.value):!1:Fp(e)}function Fp(e){return e.replace(O1,"")===""}class zo{constructor(r,i,l){this.normal=i,this.property=r,l&&(this.space=l)}}zo.prototype.normal={};zo.prototype.property={};zo.prototype.space=void 0;function jg(e,r){const i={},l={};for(const a of e)Object.assign(i,a.property),Object.assign(l,a.normal);return new zo(i,l,r)}function zc(e){return e.toLowerCase()}class nn{constructor(r,i){this.attribute=i,this.property=r}}nn.prototype.attribute="";nn.prototype.booleanish=!1;nn.prototype.boolean=!1;nn.prototype.commaOrSpaceSeparated=!1;nn.prototype.commaSeparated=!1;nn.prototype.defined=!1;nn.prototype.mustUseProperty=!1;nn.prototype.number=!1;nn.prototype.overloadedBoolean=!1;nn.prototype.property="";nn.prototype.spaceSeparated=!1;nn.prototype.space=void 0;let U1=0;const Oe=Mi(),Ct=Mi(),Dc=Mi(),ie=Mi(),lt=Mi(),dl=Mi(),cn=Mi();function Mi(){return 2**++U1}const Ac=Object.freeze(Object.defineProperty({__proto__:null,boolean:Oe,booleanish:Ct,commaOrSpaceSeparated:cn,commaSeparated:dl,number:ie,overloadedBoolean:Dc,spaceSeparated:lt},Symbol.toStringTag,{value:"Module"})),fc=Object.keys(Ac);class id extends nn{constructor(r,i,l,a){let u=-1;if(super(r,i),Up(this,"space",a),typeof l=="number")for(;++u<fc.length;){const c=fc[u];Up(this,fc[u],(l&Ac[c])===Ac[c])}}}id.prototype.defined=!0;function Up(e,r,i){i&&(e[r]=i)}function Cl(e){const r={},i={};for(const[l,a]of Object.entries(e.properties)){const u=new id(l,e.transform(e.attributes||{},l),a,e.space);e.mustUseProperty&&e.mustUseProperty.includes(l)&&(u.mustUseProperty=!0),r[l]=u,i[zc(l)]=l,i[zc(u.attribute)]=l}return new zo(r,i,e.space)}const _g=Cl({properties:{ariaActiveDescendant:null,ariaAtomic:Ct,ariaAutoComplete:null,ariaBusy:Ct,ariaChecked:Ct,ariaColCount:ie,ariaColIndex:ie,ariaColSpan:ie,ariaControls:lt,ariaCurrent:null,ariaDescribedBy:lt,ariaDetails:null,ariaDisabled:Ct,ariaDropEffect:lt,ariaErrorMessage:null,ariaExpanded:Ct,ariaFlowTo:lt,ariaGrabbed:Ct,ariaHasPopup:null,ariaHidden:Ct,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:lt,ariaLevel:ie,ariaLive:null,ariaModal:Ct,ariaMultiLine:Ct,ariaMultiSelectable:Ct,ariaOrientation:null,ariaOwns:lt,ariaPlaceholder:null,ariaPosInSet:ie,ariaPressed:Ct,ariaReadOnly:Ct,ariaRelevant:null,ariaRequired:Ct,ariaRoleDescription:lt,ariaRowCount:ie,ariaRowIndex:ie,ariaRowSpan:ie,ariaSelected:Ct,ariaSetSize:ie,ariaSort:null,ariaValueMax:ie,ariaValueMin:ie,ariaValueNow:ie,ariaValueText:null,role:null},transform(e,r){return r==="role"?r:"aria-"+r.slice(4).toLowerCase()}});function Tg(e,r){return r in e?e[r]:r}function Rg(e,r){return Tg(e,r.toLowerCase())}const B1=Cl({attributes:{acceptcharset:"accept-charset",classname:"class",htmlfor:"for",httpequiv:"http-equiv"},mustUseProperty:["checked","multiple","muted","selected"],properties:{abbr:null,accept:dl,acceptCharset:lt,accessKey:lt,action:null,allow:null,allowFullScreen:Oe,allowPaymentRequest:Oe,allowUserMedia:Oe,alt:null,as:null,async:Oe,autoCapitalize:null,autoComplete:lt,autoFocus:Oe,autoPlay:Oe,blocking:lt,capture:null,charSet:null,checked:Oe,cite:null,className:lt,cols:ie,colSpan:null,content:null,contentEditable:Ct,controls:Oe,controlsList:lt,coords:ie|dl,crossOrigin:null,data:null,dateTime:null,decoding:null,default:Oe,defer:Oe,dir:null,dirName:null,disabled:Oe,download:Dc,draggable:Ct,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:Oe,formTarget:null,headers:lt,height:ie,hidden:Dc,high:ie,href:null,hrefLang:null,htmlFor:lt,httpEquiv:lt,id:null,imageSizes:null,imageSrcSet:null,inert:Oe,inputMode:null,integrity:null,is:null,isMap:Oe,itemId:null,itemProp:lt,itemRef:lt,itemScope:Oe,itemType:lt,kind:null,label:null,lang:null,language:null,list:null,loading:null,loop:Oe,low:ie,manifest:null,max:null,maxLength:ie,media:null,method:null,min:null,minLength:ie,multiple:Oe,muted:Oe,name:null,nonce:null,noModule:Oe,noValidate:Oe,onAbort:null,onAfterPrint:null,onAuxClick:null,onBeforeMatch:null,onBeforePrint:null,onBeforeToggle:null,onBeforeUnload:null,onBlur:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onContextLost:null,onContextMenu:null,onContextRestored:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnded:null,onError:null,onFocus:null,onFormData:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLanguageChange:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadEnd:null,onLoadStart:null,onMessage:null,onMessageError:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRejectionHandled:null,onReset:null,onResize:null,onScroll:null,onScrollEnd:null,onSecurityPolicyViolation:null,onSeeked:null,onSeeking:null,onSelect:null,onSlotChange:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnhandledRejection:null,onUnload:null,onVolumeChange:null,onWaiting:null,onWheel:null,open:Oe,optimum:ie,pattern:null,ping:lt,placeholder:null,playsInline:Oe,popover:null,popoverTarget:null,popoverTargetAction:null,poster:null,preload:null,readOnly:Oe,referrerPolicy:null,rel:lt,required:Oe,reversed:Oe,rows:ie,rowSpan:ie,sandbox:lt,scope:null,scoped:Oe,seamless:Oe,selected:Oe,shadowRootClonable:Oe,shadowRootDelegatesFocus:Oe,shadowRootMode:null,shape:null,size:ie,sizes:null,slot:null,span:ie,spellCheck:Ct,src:null,srcDoc:null,srcLang:null,srcSet:null,start:ie,step:null,style:null,tabIndex:ie,target:null,title:null,translate:null,type:null,typeMustMatch:Oe,useMap:null,value:Ct,width:ie,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:lt,axis:null,background:null,bgColor:null,border:ie,borderColor:null,bottomMargin:ie,cellPadding:null,cellSpacing:null,char:null,charOff:null,classId:null,clear:null,code:null,codeBase:null,codeType:null,color:null,compact:Oe,declare:Oe,event:null,face:null,frame:null,frameBorder:null,hSpace:ie,leftMargin:ie,link:null,longDesc:null,lowSrc:null,marginHeight:ie,marginWidth:ie,noResize:Oe,noHref:Oe,noShade:Oe,noWrap:Oe,object:null,profile:null,prompt:null,rev:null,rightMargin:ie,rules:null,scheme:null,scrolling:Ct,standby:null,summary:null,text:null,topMargin:ie,valueType:null,version:null,vAlign:null,vLink:null,vSpace:ie,allowTransparency:null,autoCorrect:null,autoSave:null,disablePictureInPicture:Oe,disableRemotePlayback:Oe,prefix:null,property:null,results:ie,security:null,unselectable:null},space:"html",transform:Rg}),H1=Cl({attributes:{accentHeight:"accent-height",alignmentBaseline:"alignment-baseline",arabicForm:"arabic-form",baselineShift:"baseline-shift",capHeight:"cap-height",className:"class",clipPath:"clip-path",clipRule:"clip-rule",colorInterpolation:"color-interpolation",colorInterpolationFilters:"color-interpolation-filters",colorProfile:"color-profile",colorRendering:"color-rendering",crossOrigin:"crossorigin",dataType:"datatype",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",hrefLang:"hreflang",horizAdvX:"horiz-adv-x",horizOriginX:"horiz-origin-x",horizOriginY:"horiz-origin-y",imageRendering:"image-rendering",letterSpacing:"letter-spacing",lightingColor:"lighting-color",markerEnd:"marker-end",markerMid:"marker-mid",markerStart:"marker-start",navDown:"nav-down",navDownLeft:"nav-down-left",navDownRight:"nav-down-right",navLeft:"nav-left",navNext:"nav-next",navPrev:"nav-prev",navRight:"nav-right",navUp:"nav-up",navUpLeft:"nav-up-left",navUpRight:"nav-up-right",onAbort:"onabort",onActivate:"onactivate",onAfterPrint:"onafterprint",onBeforePrint:"onbeforeprint",onBegin:"onbegin",onCancel:"oncancel",onCanPlay:"oncanplay",onCanPlayThrough:"oncanplaythrough",onChange:"onchange",onClick:"onclick",onClose:"onclose",onCopy:"oncopy",onCueChange:"oncuechange",onCut:"oncut",onDblClick:"ondblclick",onDrag:"ondrag",onDragEnd:"ondragend",onDragEnter:"ondragenter",onDragExit:"ondragexit",onDragLeave:"ondragleave",onDragOver:"ondragover",onDragStart:"ondragstart",onDrop:"ondrop",onDurationChange:"ondurationchange",onEmptied:"onemptied",onEnd:"onend",onEnded:"onended",onError:"onerror",onFocus:"onfocus",onFocusIn:"onfocusin",onFocusOut:"onfocusout",onHashChange:"onhashchange",onInput:"oninput",onInvalid:"oninvalid",onKeyDown:"onkeydown",onKeyPress:"onkeypress",onKeyUp:"onkeyup",onLoad:"onload",onLoadedData:"onloadeddata",onLoadedMetadata:"onloadedmetadata",onLoadStart:"onloadstart",onMessage:"onmessage",onMouseDown:"onmousedown",onMouseEnter:"onmouseenter",onMouseLeave:"onmouseleave",onMouseMove:"onmousemove",onMouseOut:"onmouseout",onMouseOver:"onmouseover",onMouseUp:"onmouseup",onMouseWheel:"onmousewheel",onOffline:"onoffline",onOnline:"ononline",onPageHide:"onpagehide",onPageShow:"onpageshow",onPaste:"onpaste",onPause:"onpause",onPlay:"onplay",onPlaying:"onplaying",onPopState:"onpopstate",onProgress:"onprogress",onRateChange:"onratechange",onRepeat:"onrepeat",onReset:"onreset",onResize:"onresize",onScroll:"onscroll",onSeeked:"onseeked",onSeeking:"onseeking",onSelect:"onselect",onShow:"onshow",onStalled:"onstalled",onStorage:"onstorage",onSubmit:"onsubmit",onSuspend:"onsuspend",onTimeUpdate:"ontimeupdate",onToggle:"ontoggle",onUnload:"onunload",onVolumeChange:"onvolumechange",onWaiting:"onwaiting",onZoom:"onzoom",overlinePosition:"overline-position",overlineThickness:"overline-thickness",paintOrder:"paint-order",panose1:"panose-1",pointerEvents:"pointer-events",referrerPolicy:"referrerpolicy",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",tabIndex:"tabindex",textAnchor:"text-anchor",textDecoration:"text-decoration",textRendering:"text-rendering",transformOrigin:"transform-origin",typeOf:"typeof",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",xHeight:"x-height",playbackOrder:"playbackorder",timelineBegin:"timelinebegin"},properties:{about:cn,accentHeight:ie,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:ie,amplitude:ie,arabicForm:null,ascent:ie,attributeName:null,attributeType:null,azimuth:ie,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:ie,by:null,calcMode:null,capHeight:ie,className:lt,clip:null,clipPath:null,clipPathUnits:null,clipRule:null,color:null,colorInterpolation:null,colorInterpolationFilters:null,colorProfile:null,colorRendering:null,content:null,contentScriptType:null,contentStyleType:null,crossOrigin:null,cursor:null,cx:null,cy:null,d:null,dataType:null,defaultAction:null,descent:ie,diffuseConstant:ie,direction:null,display:null,dur:null,divisor:ie,dominantBaseline:null,download:Oe,dx:null,dy:null,edgeMode:null,editable:null,elevation:ie,enableBackground:null,end:null,event:null,exponent:ie,externalResourcesRequired:null,fill:null,fillOpacity:ie,fillRule:null,filter:null,filterRes:null,filterUnits:null,floodColor:null,floodOpacity:null,focusable:null,focusHighlight:null,fontFamily:null,fontSize:null,fontSizeAdjust:null,fontStretch:null,fontStyle:null,fontVariant:null,fontWeight:null,format:null,fr:null,from:null,fx:null,fy:null,g1:dl,g2:dl,glyphName:dl,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:ie,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:ie,horizOriginX:ie,horizOriginY:ie,id:null,ideographic:ie,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:ie,k:ie,k1:ie,k2:ie,k3:ie,k4:ie,kernelMatrix:cn,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:ie,local:null,markerEnd:null,markerMid:null,markerStart:null,markerHeight:null,markerUnits:null,markerWidth:null,mask:null,maskContentUnits:null,maskUnits:null,mathematical:null,max:null,media:null,mediaCharacterEncoding:null,mediaContentEncodings:null,mediaSize:ie,mediaTime:null,method:null,min:null,mode:null,name:null,navDown:null,navDownLeft:null,navDownRight:null,navLeft:null,navNext:null,navPrev:null,navRight:null,navUp:null,navUpLeft:null,navUpRight:null,numOctaves:null,observer:null,offset:null,onAbort:null,onActivate:null,onAfterPrint:null,onBeforePrint:null,onBegin:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnd:null,onEnded:null,onError:null,onFocus:null,onFocusIn:null,onFocusOut:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadStart:null,onMessage:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onMouseWheel:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRepeat:null,onReset:null,onResize:null,onScroll:null,onSeeked:null,onSeeking:null,onSelect:null,onShow:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnload:null,onVolumeChange:null,onWaiting:null,onZoom:null,opacity:null,operator:null,order:null,orient:null,orientation:null,origin:null,overflow:null,overlay:null,overlinePosition:ie,overlineThickness:ie,paintOrder:null,panose1:null,path:null,pathLength:ie,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:lt,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:ie,pointsAtY:ie,pointsAtZ:ie,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:cn,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:cn,rev:cn,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:cn,requiredFeatures:cn,requiredFonts:cn,requiredFormats:cn,resource:null,restart:null,result:null,rotate:null,rx:null,ry:null,scale:null,seed:null,shapeRendering:null,side:null,slope:null,snapshotTime:null,specularConstant:ie,specularExponent:ie,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:ie,strikethroughThickness:ie,string:null,stroke:null,strokeDashArray:cn,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:ie,strokeOpacity:ie,strokeWidth:null,style:null,surfaceScale:ie,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:cn,tabIndex:ie,tableValues:null,target:null,targetX:ie,targetY:ie,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:cn,to:null,transform:null,transformOrigin:null,u1:null,u2:null,underlinePosition:ie,underlineThickness:ie,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:ie,values:null,vAlphabetic:ie,vMathematical:ie,vectorEffect:null,vHanging:ie,vIdeographic:ie,version:null,vertAdvY:ie,vertOriginX:ie,vertOriginY:ie,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:ie,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null},space:"svg",transform:Tg}),Lg=Cl({properties:{xLinkActuate:null,xLinkArcRole:null,xLinkHref:null,xLinkRole:null,xLinkShow:null,xLinkTitle:null,xLinkType:null},space:"xlink",transform(e,r){return"xlink:"+r.slice(5).toLowerCase()}}),Ig=Cl({attributes:{xmlnsxlink:"xmlns:xlink"},properties:{xmlnsXLink:null,xmlns:null},space:"xmlns",transform:Rg}),Mg=Cl({properties:{xmlBase:null,xmlLang:null,xmlSpace:null},space:"xml",transform(e,r){return"xml:"+r.slice(3).toLowerCase()}}),V1={classId:"classID",dataType:"datatype",itemId:"itemID",strokeDashArray:"strokeDasharray",strokeDashOffset:"strokeDashoffset",strokeLineCap:"strokeLinecap",strokeLineJoin:"strokeLinejoin",strokeMiterLimit:"strokeMiterlimit",typeOf:"typeof",xLinkActuate:"xlinkActuate",xLinkArcRole:"xlinkArcrole",xLinkHref:"xlinkHref",xLinkRole:"xlinkRole",xLinkShow:"xlinkShow",xLinkTitle:"xlinkTitle",xLinkType:"xlinkType",xmlnsXLink:"xmlnsXlink"},$1=/[A-Z]/g,Bp=/-[a-z]/g,W1=/^data[-\w.:]+$/i;function Q1(e,r){const i=zc(r);let l=r,a=nn;if(i in e.normal)return e.property[e.normal[i]];if(i.length>4&&i.slice(0,4)==="data"&&W1.test(r)){if(r.charAt(4)==="-"){const u=r.slice(5).replace(Bp,K1);l="data"+u.charAt(0).toUpperCase()+u.slice(1)}else{const u=r.slice(4);if(!Bp.test(u)){let c=u.replace($1,q1);c.charAt(0)!=="-"&&(c="-"+c),r="data"+c}}a=id}return new a(l,r)}function q1(e){return"-"+e.toLowerCase()}function K1(e){return e.charAt(1).toUpperCase()}const G1=jg([_g,B1,Lg,Ig,Mg],"html"),ld=jg([_g,H1,Lg,Ig,Mg],"svg");function Y1(e){return e.join(" ").trim()}var sl={},hc,Hp;function X1(){if(Hp)return hc;Hp=1;var e=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,r=/\n/g,i=/^\s*/,l=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,a=/^:\s*/,u=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,c=/^[;\s]*/,f=/^\s+|\s+$/g,p=`
|
|
261
|
+
`,m="/",g="*",y="",k="comment",x="declaration";function T(b,P){if(typeof b!="string")throw new TypeError("First argument must be a string");if(!b)return[];P=P||{};var z=1,I=1;function F(se){var ne=se.match(r);ne&&(z+=ne.length);var be=se.lastIndexOf(p);I=~be?se.length-be:I+se.length}function ee(){var se={line:z,column:I};return function(ne){return ne.position=new B(se),le(),ne}}function B(se){this.start=se,this.end={line:z,column:I},this.source=P.source}B.prototype.content=b;function D(se){var ne=new Error(P.source+":"+z+":"+I+": "+se);if(ne.reason=se,ne.filename=P.source,ne.line=z,ne.column=I,ne.source=b,!P.silent)throw ne}function G(se){var ne=se.exec(b);if(ne){var be=ne[0];return F(be),b=b.slice(be.length),ne}}function le(){G(i)}function re(se){var ne;for(se=se||[];ne=$();)ne!==!1&&se.push(ne);return se}function $(){var se=ee();if(!(m!=b.charAt(0)||g!=b.charAt(1))){for(var ne=2;y!=b.charAt(ne)&&(g!=b.charAt(ne)||m!=b.charAt(ne+1));)++ne;if(ne+=2,y===b.charAt(ne-1))return D("End of comment missing");var be=b.slice(2,ne-2);return I+=2,F(be),b=b.slice(ne),I+=2,se({type:k,comment:be})}}function K(){var se=ee(),ne=G(l);if(ne){if($(),!G(a))return D("property missing ':'");var be=G(u),_e=se({type:x,property:N(ne[0].replace(e,y)),value:be?N(be[0].replace(e,y)):y});return G(c),_e}}function Se(){var se=[];re(se);for(var ne;ne=K();)ne!==!1&&(se.push(ne),re(se));return se}return le(),Se()}function N(b){return b?b.replace(f,y):y}return hc=T,hc}var Vp;function J1(){if(Vp)return sl;Vp=1;var e=sl&&sl.__importDefault||function(l){return l&&l.__esModule?l:{default:l}};Object.defineProperty(sl,"__esModule",{value:!0}),sl.default=i;const r=e(X1());function i(l,a){let u=null;if(!l||typeof l!="string")return u;const c=(0,r.default)(l),f=typeof a=="function";return c.forEach(p=>{if(p.type!=="declaration")return;const{property:m,value:g}=p;f?a(m,g,p):g&&(u=u||{},u[m]=g)}),u}return sl}var mo={},$p;function Z1(){if($p)return mo;$p=1,Object.defineProperty(mo,"__esModule",{value:!0}),mo.camelCase=void 0;var e=/^--[a-zA-Z0-9_-]+$/,r=/-([a-z])/g,i=/^[^-]+$/,l=/^-(webkit|moz|ms|o|khtml)-/,a=/^-(ms)-/,u=function(m){return!m||i.test(m)||e.test(m)},c=function(m,g){return g.toUpperCase()},f=function(m,g){return"".concat(g,"-")},p=function(m,g){return g===void 0&&(g={}),u(m)?m:(m=m.toLowerCase(),g.reactCompat?m=m.replace(a,f):m=m.replace(l,f),m.replace(r,c))};return mo.camelCase=p,mo}var go,Wp;function ek(){if(Wp)return go;Wp=1;var e=go&&go.__importDefault||function(a){return a&&a.__esModule?a:{default:a}},r=e(J1()),i=Z1();function l(a,u){var c={};return!a||typeof a!="string"||(0,r.default)(a,function(f,p){f&&p&&(c[(0,i.camelCase)(f,u)]=p)}),c}return l.default=l,go=l,go}var tk=ek();const nk=ds(tk),zg=Dg("end"),od=Dg("start");function Dg(e){return r;function r(i){const l=i&&i.position&&i.position[e]||{};if(typeof l.line=="number"&&l.line>0&&typeof l.column=="number"&&l.column>0)return{line:l.line,column:l.column,offset:typeof l.offset=="number"&&l.offset>-1?l.offset:void 0}}}function rk(e){const r=od(e),i=zg(e);if(r&&i)return{start:r,end:i}}function wo(e){return!e||typeof e!="object"?"":"position"in e||"type"in e?Qp(e.position):"start"in e||"end"in e?Qp(e):"line"in e||"column"in e?Oc(e):""}function Oc(e){return qp(e&&e.line)+":"+qp(e&&e.column)}function Qp(e){return Oc(e&&e.start)+"-"+Oc(e&&e.end)}function qp(e){return e&&typeof e=="number"?e:1}class Vt extends Error{constructor(r,i,l){super(),typeof i=="string"&&(l=i,i=void 0);let a="",u={},c=!1;if(i&&("line"in i&&"column"in i?u={place:i}:"start"in i&&"end"in i?u={place:i}:"type"in i?u={ancestors:[i],place:i.position}:u={...i}),typeof r=="string"?a=r:!u.cause&&r&&(c=!0,a=r.message,u.cause=r),!u.ruleId&&!u.source&&typeof l=="string"){const p=l.indexOf(":");p===-1?u.ruleId=l:(u.source=l.slice(0,p),u.ruleId=l.slice(p+1))}if(!u.place&&u.ancestors&&u.ancestors){const p=u.ancestors[u.ancestors.length-1];p&&(u.place=p.position)}const f=u.place&&"start"in u.place?u.place.start:u.place;this.ancestors=u.ancestors||void 0,this.cause=u.cause||void 0,this.column=f?f.column:void 0,this.fatal=void 0,this.file="",this.message=a,this.line=f?f.line:void 0,this.name=wo(u.place)||"1:1",this.place=u.place||void 0,this.reason=this.message,this.ruleId=u.ruleId||void 0,this.source=u.source||void 0,this.stack=c&&u.cause&&typeof u.cause.stack=="string"?u.cause.stack:"",this.actual=void 0,this.expected=void 0,this.note=void 0,this.url=void 0}}Vt.prototype.file="";Vt.prototype.name="";Vt.prototype.reason="";Vt.prototype.message="";Vt.prototype.stack="";Vt.prototype.column=void 0;Vt.prototype.line=void 0;Vt.prototype.ancestors=void 0;Vt.prototype.cause=void 0;Vt.prototype.fatal=void 0;Vt.prototype.place=void 0;Vt.prototype.ruleId=void 0;Vt.prototype.source=void 0;const ad={}.hasOwnProperty,ik=new Map,lk=/[A-Z]/g,ok=new Set(["table","tbody","thead","tfoot","tr"]),ak=new Set(["td","th"]),Ag="https://github.com/syntax-tree/hast-util-to-jsx-runtime";function sk(e,r){if(!r||r.Fragment===void 0)throw new TypeError("Expected `Fragment` in options");const i=r.filePath||void 0;let l;if(r.development){if(typeof r.jsxDEV!="function")throw new TypeError("Expected `jsxDEV` in options when `development: true`");l=gk(i,r.jsxDEV)}else{if(typeof r.jsx!="function")throw new TypeError("Expected `jsx` in production options");if(typeof r.jsxs!="function")throw new TypeError("Expected `jsxs` in production options");l=mk(i,r.jsx,r.jsxs)}const a={Fragment:r.Fragment,ancestors:[],components:r.components||{},create:l,elementAttributeNameCase:r.elementAttributeNameCase||"react",evaluater:r.createEvaluater?r.createEvaluater():void 0,filePath:i,ignoreInvalidStyle:r.ignoreInvalidStyle||!1,passKeys:r.passKeys!==!1,passNode:r.passNode||!1,schema:r.space==="svg"?ld:G1,stylePropertyNameCase:r.stylePropertyNameCase||"dom",tableCellAlignToStyle:r.tableCellAlignToStyle!==!1},u=Og(a,e,void 0);return u&&typeof u!="string"?u:a.create(e,a.Fragment,{children:u||void 0},void 0)}function Og(e,r,i){if(r.type==="element")return uk(e,r,i);if(r.type==="mdxFlowExpression"||r.type==="mdxTextExpression")return ck(e,r);if(r.type==="mdxJsxFlowElement"||r.type==="mdxJsxTextElement")return fk(e,r,i);if(r.type==="mdxjsEsm")return dk(e,r);if(r.type==="root")return hk(e,r,i);if(r.type==="text")return pk(e,r)}function uk(e,r,i){const l=e.schema;let a=l;r.tagName.toLowerCase()==="svg"&&l.space==="html"&&(a=ld,e.schema=a),e.ancestors.push(r);const u=Ug(e,r.tagName,!1),c=yk(e,r);let f=ud(e,r);return ok.has(r.tagName)&&(f=f.filter(function(p){return typeof p=="string"?!F1(p):!0})),Fg(e,c,u,r),sd(c,f),e.ancestors.pop(),e.schema=l,e.create(r,u,c,i)}function ck(e,r){if(r.data&&r.data.estree&&e.evaluater){const l=r.data.estree.body[0];return l.type,e.evaluater.evaluateExpression(l.expression)}jo(e,r.position)}function dk(e,r){if(r.data&&r.data.estree&&e.evaluater)return e.evaluater.evaluateProgram(r.data.estree);jo(e,r.position)}function fk(e,r,i){const l=e.schema;let a=l;r.name==="svg"&&l.space==="html"&&(a=ld,e.schema=a),e.ancestors.push(r);const u=r.name===null?e.Fragment:Ug(e,r.name,!0),c=vk(e,r),f=ud(e,r);return Fg(e,c,u,r),sd(c,f),e.ancestors.pop(),e.schema=l,e.create(r,u,c,i)}function hk(e,r,i){const l={};return sd(l,ud(e,r)),e.create(r,e.Fragment,l,i)}function pk(e,r){return r.value}function Fg(e,r,i,l){typeof i!="string"&&i!==e.Fragment&&e.passNode&&(r.node=l)}function sd(e,r){if(r.length>0){const i=r.length>1?r:r[0];i&&(e.children=i)}}function mk(e,r,i){return l;function l(a,u,c,f){const m=Array.isArray(c.children)?i:r;return f?m(u,c,f):m(u,c)}}function gk(e,r){return i;function i(l,a,u,c){const f=Array.isArray(u.children),p=od(l);return r(a,u,c,f,{columnNumber:p?p.column-1:void 0,fileName:e,lineNumber:p?p.line:void 0},void 0)}}function yk(e,r){const i={};let l,a;for(a in r.properties)if(a!=="children"&&ad.call(r.properties,a)){const u=xk(e,a,r.properties[a]);if(u){const[c,f]=u;e.tableCellAlignToStyle&&c==="align"&&typeof f=="string"&&ak.has(r.tagName)?l=f:i[c]=f}}if(l){const u=i.style||(i.style={});u[e.stylePropertyNameCase==="css"?"text-align":"textAlign"]=l}return i}function vk(e,r){const i={};for(const l of r.attributes)if(l.type==="mdxJsxExpressionAttribute")if(l.data&&l.data.estree&&e.evaluater){const u=l.data.estree.body[0];u.type;const c=u.expression;c.type;const f=c.properties[0];f.type,Object.assign(i,e.evaluater.evaluateExpression(f.argument))}else jo(e,r.position);else{const a=l.name;let u;if(l.value&&typeof l.value=="object")if(l.value.data&&l.value.data.estree&&e.evaluater){const f=l.value.data.estree.body[0];f.type,u=e.evaluater.evaluateExpression(f.expression)}else jo(e,r.position);else u=l.value===null?!0:l.value;i[a]=u}return i}function ud(e,r){const i=[];let l=-1;const a=e.passKeys?new Map:ik;for(;++l<r.children.length;){const u=r.children[l];let c;if(e.passKeys){const p=u.type==="element"?u.tagName:u.type==="mdxJsxFlowElement"||u.type==="mdxJsxTextElement"?u.name:void 0;if(p){const m=a.get(p)||0;c=p+"-"+m,a.set(p,m+1)}}const f=Og(e,u,c);f!==void 0&&i.push(f)}return i}function xk(e,r,i){const l=Q1(e.schema,r);if(!(i==null||typeof i=="number"&&Number.isNaN(i))){if(Array.isArray(i)&&(i=l.commaSeparated?M1(i):Y1(i)),l.property==="style"){let a=typeof i=="object"?i:wk(e,String(i));return e.stylePropertyNameCase==="css"&&(a=kk(a)),["style",a]}return[e.elementAttributeNameCase==="react"&&l.space?V1[l.property]||l.property:l.attribute,i]}}function wk(e,r){try{return nk(r,{reactCompat:!0})}catch(i){if(e.ignoreInvalidStyle)return{};const l=i,a=new Vt("Cannot parse `style` attribute",{ancestors:e.ancestors,cause:l,ruleId:"style",source:"hast-util-to-jsx-runtime"});throw a.file=e.filePath||void 0,a.url=Ag+"#cannot-parse-style-attribute",a}}function Ug(e,r,i){let l;if(!i)l={type:"Literal",value:r};else if(r.includes(".")){const a=r.split(".");let u=-1,c;for(;++u<a.length;){const f=Op(a[u])?{type:"Identifier",name:a[u]}:{type:"Literal",value:a[u]};c=c?{type:"MemberExpression",object:c,property:f,computed:!!(u&&f.type==="Literal"),optional:!1}:f}l=c}else l=Op(r)&&!/^[a-z]/.test(r)?{type:"Identifier",name:r}:{type:"Literal",value:r};if(l.type==="Literal"){const a=l.value;return ad.call(e.components,a)?e.components[a]:a}if(e.evaluater)return e.evaluater.evaluateExpression(l);jo(e)}function jo(e,r){const i=new Vt("Cannot handle MDX estrees without `createEvaluater`",{ancestors:e.ancestors,place:r,ruleId:"mdx-estree",source:"hast-util-to-jsx-runtime"});throw i.file=e.filePath||void 0,i.url=Ag+"#cannot-handle-mdx-estrees-without-createevaluater",i}function kk(e){const r={};let i;for(i in e)ad.call(e,i)&&(r[Sk(i)]=e[i]);return r}function Sk(e){let r=e.replace(lk,Ek);return r.slice(0,3)==="ms-"&&(r="-"+r),r}function Ek(e){return"-"+e.toLowerCase()}const pc={action:["form"],cite:["blockquote","del","ins","q"],data:["object"],formAction:["button","input"],href:["a","area","base","link"],icon:["menuitem"],itemId:null,manifest:["html"],ping:["a","area"],poster:["video"],src:["audio","embed","iframe","img","input","script","source","track","video"]},Ck={};function bk(e,r){const i=Ck,l=typeof i.includeImageAlt=="boolean"?i.includeImageAlt:!0,a=typeof i.includeHtml=="boolean"?i.includeHtml:!0;return Bg(e,l,a)}function Bg(e,r,i){if(Nk(e)){if("value"in e)return e.type==="html"&&!i?"":e.value;if(r&&"alt"in e&&e.alt)return e.alt;if("children"in e)return Kp(e.children,r,i)}return Array.isArray(e)?Kp(e,r,i):""}function Kp(e,r,i){const l=[];let a=-1;for(;++a<e.length;)l[a]=Bg(e[a],r,i);return l.join("")}function Nk(e){return!!(e&&typeof e=="object")}const Gp=document.createElement("i");function cd(e){const r="&"+e+";";Gp.innerHTML=r;const i=Gp.textContent;return i.charCodeAt(i.length-1)===59&&e!=="semi"||i===r?!1:i}function Zn(e,r,i,l){const a=e.length;let u=0,c;if(r<0?r=-r>a?0:a+r:r=r>a?a:r,i=i>0?i:0,l.length<1e4)c=Array.from(l),c.unshift(r,i),e.splice(...c);else for(i&&e.splice(r,i);u<l.length;)c=l.slice(u,u+1e4),c.unshift(r,0),e.splice(...c),u+=1e4,r+=1e4}function En(e,r){return e.length>0?(Zn(e,e.length,0,r),e):r}const Yp={}.hasOwnProperty;function Pk(e){const r={};let i=-1;for(;++i<e.length;)jk(r,e[i]);return r}function jk(e,r){let i;for(i in r){const a=(Yp.call(e,i)?e[i]:void 0)||(e[i]={}),u=r[i];let c;if(u)for(c in u){Yp.call(a,c)||(a[c]=[]);const f=u[c];_k(a[c],Array.isArray(f)?f:f?[f]:[])}}}function _k(e,r){let i=-1;const l=[];for(;++i<r.length;)(r[i].add==="after"?e:l).push(r[i]);Zn(e,0,0,l)}function Hg(e,r){const i=Number.parseInt(e,r);return i<9||i===11||i>13&&i<32||i>126&&i<160||i>55295&&i<57344||i>64975&&i<65008||(i&65535)===65535||(i&65535)===65534||i>1114111?"�":String.fromCodePoint(i)}function fl(e){return e.replace(/[\t\n\r ]+/g," ").replace(/^ | $/g,"").toLowerCase().toUpperCase()}const Jn=ii(/[A-Za-z]/),hn=ii(/[\dA-Za-z]/),Tk=ii(/[#-'*+\--9=?A-Z^-~]/);function Fc(e){return e!==null&&(e<32||e===127)}const Uc=ii(/\d/),Rk=ii(/[\dA-Fa-f]/),Lk=ii(/[!-/:-@[-`{-~]/);function Ie(e){return e!==null&&e<-2}function tn(e){return e!==null&&(e<0||e===32)}function Je(e){return e===-2||e===-1||e===32}const Ik=ii(new RegExp("\\p{P}|\\p{S}","u")),Mk=ii(/\s/);function ii(e){return r;function r(i){return i!==null&&i>-1&&e.test(String.fromCharCode(i))}}function bl(e){const r=[];let i=-1,l=0,a=0;for(;++i<e.length;){const u=e.charCodeAt(i);let c="";if(u===37&&hn(e.charCodeAt(i+1))&&hn(e.charCodeAt(i+2)))a=2;else if(u<128)/[!#$&-;=?-Z_a-z~]/.test(String.fromCharCode(u))||(c=String.fromCharCode(u));else if(u>55295&&u<57344){const f=e.charCodeAt(i+1);u<56320&&f>56319&&f<57344?(c=String.fromCharCode(u,f),a=1):c="�"}else c=String.fromCharCode(u);c&&(r.push(e.slice(l,i),encodeURIComponent(c)),l=i+a+1,c=""),a&&(i+=a,a=0)}return r.join("")+e.slice(l)}function ot(e,r,i,l){const a=l?l-1:Number.POSITIVE_INFINITY;let u=0;return c;function c(p){return Je(p)?(e.enter(i),f(p)):r(p)}function f(p){return Je(p)&&u++<a?(e.consume(p),f):(e.exit(i),r(p))}}const zk={tokenize:Dk};function Dk(e){const r=e.attempt(this.parser.constructs.contentInitial,l,a);let i;return r;function l(f){if(f===null){e.consume(f);return}return e.enter("lineEnding"),e.consume(f),e.exit("lineEnding"),ot(e,r,"linePrefix")}function a(f){return e.enter("paragraph"),u(f)}function u(f){const p=e.enter("chunkText",{contentType:"text",previous:i});return i&&(i.next=p),i=p,c(f)}function c(f){if(f===null){e.exit("chunkText"),e.exit("paragraph"),e.consume(f);return}return Ie(f)?(e.consume(f),e.exit("chunkText"),u):(e.consume(f),c)}}const Ak={tokenize:Ok},Xp={tokenize:Fk};function Ok(e){const r=this,i=[];let l=0,a,u,c;return f;function f(I){if(l<i.length){const F=i[l];return r.containerState=F[1],e.attempt(F[0].continuation,p,m)(I)}return m(I)}function p(I){if(l++,r.containerState._closeFlow){r.containerState._closeFlow=void 0,a&&z();const F=r.events.length;let ee=F,B;for(;ee--;)if(r.events[ee][0]==="exit"&&r.events[ee][1].type==="chunkFlow"){B=r.events[ee][1].end;break}P(l);let D=F;for(;D<r.events.length;)r.events[D][1].end={...B},D++;return Zn(r.events,ee+1,0,r.events.slice(F)),r.events.length=D,m(I)}return f(I)}function m(I){if(l===i.length){if(!a)return k(I);if(a.currentConstruct&&a.currentConstruct.concrete)return T(I);r.interrupt=!!(a.currentConstruct&&!a._gfmTableDynamicInterruptHack)}return r.containerState={},e.check(Xp,g,y)(I)}function g(I){return a&&z(),P(l),k(I)}function y(I){return r.parser.lazy[r.now().line]=l!==i.length,c=r.now().offset,T(I)}function k(I){return r.containerState={},e.attempt(Xp,x,T)(I)}function x(I){return l++,i.push([r.currentConstruct,r.containerState]),k(I)}function T(I){if(I===null){a&&z(),P(0),e.consume(I);return}return a=a||r.parser.flow(r.now()),e.enter("chunkFlow",{_tokenizer:a,contentType:"flow",previous:u}),N(I)}function N(I){if(I===null){b(e.exit("chunkFlow"),!0),P(0),e.consume(I);return}return Ie(I)?(e.consume(I),b(e.exit("chunkFlow")),l=0,r.interrupt=void 0,f):(e.consume(I),N)}function b(I,F){const ee=r.sliceStream(I);if(F&&ee.push(null),I.previous=u,u&&(u.next=I),u=I,a.defineSkip(I.start),a.write(ee),r.parser.lazy[I.start.line]){let B=a.events.length;for(;B--;)if(a.events[B][1].start.offset<c&&(!a.events[B][1].end||a.events[B][1].end.offset>c))return;const D=r.events.length;let G=D,le,re;for(;G--;)if(r.events[G][0]==="exit"&&r.events[G][1].type==="chunkFlow"){if(le){re=r.events[G][1].end;break}le=!0}for(P(l),B=D;B<r.events.length;)r.events[B][1].end={...re},B++;Zn(r.events,G+1,0,r.events.slice(D)),r.events.length=B}}function P(I){let F=i.length;for(;F-- >I;){const ee=i[F];r.containerState=ee[1],ee[0].exit.call(r,e)}i.length=I}function z(){a.write([null]),u=void 0,a=void 0,r.containerState._closeFlow=void 0}}function Fk(e,r,i){return ot(e,e.attempt(this.parser.constructs.document,r,i),"linePrefix",this.parser.constructs.disable.null.includes("codeIndented")?void 0:4)}function Jp(e){if(e===null||tn(e)||Mk(e))return 1;if(Ik(e))return 2}function dd(e,r,i){const l=[];let a=-1;for(;++a<e.length;){const u=e[a].resolveAll;u&&!l.includes(u)&&(r=u(r,i),l.push(u))}return r}const Bc={name:"attention",resolveAll:Uk,tokenize:Bk};function Uk(e,r){let i=-1,l,a,u,c,f,p,m,g;for(;++i<e.length;)if(e[i][0]==="enter"&&e[i][1].type==="attentionSequence"&&e[i][1]._close){for(l=i;l--;)if(e[l][0]==="exit"&&e[l][1].type==="attentionSequence"&&e[l][1]._open&&r.sliceSerialize(e[l][1]).charCodeAt(0)===r.sliceSerialize(e[i][1]).charCodeAt(0)){if((e[l][1]._close||e[i][1]._open)&&(e[i][1].end.offset-e[i][1].start.offset)%3&&!((e[l][1].end.offset-e[l][1].start.offset+e[i][1].end.offset-e[i][1].start.offset)%3))continue;p=e[l][1].end.offset-e[l][1].start.offset>1&&e[i][1].end.offset-e[i][1].start.offset>1?2:1;const y={...e[l][1].end},k={...e[i][1].start};Zp(y,-p),Zp(k,p),c={type:p>1?"strongSequence":"emphasisSequence",start:y,end:{...e[l][1].end}},f={type:p>1?"strongSequence":"emphasisSequence",start:{...e[i][1].start},end:k},u={type:p>1?"strongText":"emphasisText",start:{...e[l][1].end},end:{...e[i][1].start}},a={type:p>1?"strong":"emphasis",start:{...c.start},end:{...f.end}},e[l][1].end={...c.start},e[i][1].start={...f.end},m=[],e[l][1].end.offset-e[l][1].start.offset&&(m=En(m,[["enter",e[l][1],r],["exit",e[l][1],r]])),m=En(m,[["enter",a,r],["enter",c,r],["exit",c,r],["enter",u,r]]),m=En(m,dd(r.parser.constructs.insideSpan.null,e.slice(l+1,i),r)),m=En(m,[["exit",u,r],["enter",f,r],["exit",f,r],["exit",a,r]]),e[i][1].end.offset-e[i][1].start.offset?(g=2,m=En(m,[["enter",e[i][1],r],["exit",e[i][1],r]])):g=0,Zn(e,l-1,i-l+3,m),i=l+m.length-g-2;break}}for(i=-1;++i<e.length;)e[i][1].type==="attentionSequence"&&(e[i][1].type="data");return e}function Bk(e,r){const i=this.parser.constructs.attentionMarkers.null,l=this.previous,a=Jp(l);let u;return c;function c(p){return u=p,e.enter("attentionSequence"),f(p)}function f(p){if(p===u)return e.consume(p),f;const m=e.exit("attentionSequence"),g=Jp(p),y=!g||g===2&&a||i.includes(p),k=!a||a===2&&g||i.includes(l);return m._open=!!(u===42?y:y&&(a||!k)),m._close=!!(u===42?k:k&&(g||!y)),r(p)}}function Zp(e,r){e.column+=r,e.offset+=r,e._bufferIndex+=r}const Hk={name:"autolink",tokenize:Vk};function Vk(e,r,i){let l=0;return a;function a(x){return e.enter("autolink"),e.enter("autolinkMarker"),e.consume(x),e.exit("autolinkMarker"),e.enter("autolinkProtocol"),u}function u(x){return Jn(x)?(e.consume(x),c):x===64?i(x):m(x)}function c(x){return x===43||x===45||x===46||hn(x)?(l=1,f(x)):m(x)}function f(x){return x===58?(e.consume(x),l=0,p):(x===43||x===45||x===46||hn(x))&&l++<32?(e.consume(x),f):(l=0,m(x))}function p(x){return x===62?(e.exit("autolinkProtocol"),e.enter("autolinkMarker"),e.consume(x),e.exit("autolinkMarker"),e.exit("autolink"),r):x===null||x===32||x===60||Fc(x)?i(x):(e.consume(x),p)}function m(x){return x===64?(e.consume(x),g):Tk(x)?(e.consume(x),m):i(x)}function g(x){return hn(x)?y(x):i(x)}function y(x){return x===46?(e.consume(x),l=0,g):x===62?(e.exit("autolinkProtocol").type="autolinkEmail",e.enter("autolinkMarker"),e.consume(x),e.exit("autolinkMarker"),e.exit("autolink"),r):k(x)}function k(x){if((x===45||hn(x))&&l++<63){const T=x===45?k:y;return e.consume(x),T}return i(x)}}const ys={partial:!0,tokenize:$k};function $k(e,r,i){return l;function l(u){return Je(u)?ot(e,a,"linePrefix")(u):a(u)}function a(u){return u===null||Ie(u)?r(u):i(u)}}const Vg={continuation:{tokenize:Qk},exit:qk,name:"blockQuote",tokenize:Wk};function Wk(e,r,i){const l=this;return a;function a(c){if(c===62){const f=l.containerState;return f.open||(e.enter("blockQuote",{_container:!0}),f.open=!0),e.enter("blockQuotePrefix"),e.enter("blockQuoteMarker"),e.consume(c),e.exit("blockQuoteMarker"),u}return i(c)}function u(c){return Je(c)?(e.enter("blockQuotePrefixWhitespace"),e.consume(c),e.exit("blockQuotePrefixWhitespace"),e.exit("blockQuotePrefix"),r):(e.exit("blockQuotePrefix"),r(c))}}function Qk(e,r,i){const l=this;return a;function a(c){return Je(c)?ot(e,u,"linePrefix",l.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(c):u(c)}function u(c){return e.attempt(Vg,r,i)(c)}}function qk(e){e.exit("blockQuote")}const $g={name:"characterEscape",tokenize:Kk};function Kk(e,r,i){return l;function l(u){return e.enter("characterEscape"),e.enter("escapeMarker"),e.consume(u),e.exit("escapeMarker"),a}function a(u){return Lk(u)?(e.enter("characterEscapeValue"),e.consume(u),e.exit("characterEscapeValue"),e.exit("characterEscape"),r):i(u)}}const Wg={name:"characterReference",tokenize:Gk};function Gk(e,r,i){const l=this;let a=0,u,c;return f;function f(y){return e.enter("characterReference"),e.enter("characterReferenceMarker"),e.consume(y),e.exit("characterReferenceMarker"),p}function p(y){return y===35?(e.enter("characterReferenceMarkerNumeric"),e.consume(y),e.exit("characterReferenceMarkerNumeric"),m):(e.enter("characterReferenceValue"),u=31,c=hn,g(y))}function m(y){return y===88||y===120?(e.enter("characterReferenceMarkerHexadecimal"),e.consume(y),e.exit("characterReferenceMarkerHexadecimal"),e.enter("characterReferenceValue"),u=6,c=Rk,g):(e.enter("characterReferenceValue"),u=7,c=Uc,g(y))}function g(y){if(y===59&&a){const k=e.exit("characterReferenceValue");return c===hn&&!cd(l.sliceSerialize(k))?i(y):(e.enter("characterReferenceMarker"),e.consume(y),e.exit("characterReferenceMarker"),e.exit("characterReference"),r)}return c(y)&&a++<u?(e.consume(y),g):i(y)}}const em={partial:!0,tokenize:Xk},tm={concrete:!0,name:"codeFenced",tokenize:Yk};function Yk(e,r,i){const l=this,a={partial:!0,tokenize:ee};let u=0,c=0,f;return p;function p(B){return m(B)}function m(B){const D=l.events[l.events.length-1];return u=D&&D[1].type==="linePrefix"?D[2].sliceSerialize(D[1],!0).length:0,f=B,e.enter("codeFenced"),e.enter("codeFencedFence"),e.enter("codeFencedFenceSequence"),g(B)}function g(B){return B===f?(c++,e.consume(B),g):c<3?i(B):(e.exit("codeFencedFenceSequence"),Je(B)?ot(e,y,"whitespace")(B):y(B))}function y(B){return B===null||Ie(B)?(e.exit("codeFencedFence"),l.interrupt?r(B):e.check(em,N,F)(B)):(e.enter("codeFencedFenceInfo"),e.enter("chunkString",{contentType:"string"}),k(B))}function k(B){return B===null||Ie(B)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),y(B)):Je(B)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),ot(e,x,"whitespace")(B)):B===96&&B===f?i(B):(e.consume(B),k)}function x(B){return B===null||Ie(B)?y(B):(e.enter("codeFencedFenceMeta"),e.enter("chunkString",{contentType:"string"}),T(B))}function T(B){return B===null||Ie(B)?(e.exit("chunkString"),e.exit("codeFencedFenceMeta"),y(B)):B===96&&B===f?i(B):(e.consume(B),T)}function N(B){return e.attempt(a,F,b)(B)}function b(B){return e.enter("lineEnding"),e.consume(B),e.exit("lineEnding"),P}function P(B){return u>0&&Je(B)?ot(e,z,"linePrefix",u+1)(B):z(B)}function z(B){return B===null||Ie(B)?e.check(em,N,F)(B):(e.enter("codeFlowValue"),I(B))}function I(B){return B===null||Ie(B)?(e.exit("codeFlowValue"),z(B)):(e.consume(B),I)}function F(B){return e.exit("codeFenced"),r(B)}function ee(B,D,G){let le=0;return re;function re(ne){return B.enter("lineEnding"),B.consume(ne),B.exit("lineEnding"),$}function $(ne){return B.enter("codeFencedFence"),Je(ne)?ot(B,K,"linePrefix",l.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(ne):K(ne)}function K(ne){return ne===f?(B.enter("codeFencedFenceSequence"),Se(ne)):G(ne)}function Se(ne){return ne===f?(le++,B.consume(ne),Se):le>=c?(B.exit("codeFencedFenceSequence"),Je(ne)?ot(B,se,"whitespace")(ne):se(ne)):G(ne)}function se(ne){return ne===null||Ie(ne)?(B.exit("codeFencedFence"),D(ne)):G(ne)}}}function Xk(e,r,i){const l=this;return a;function a(c){return c===null?i(c):(e.enter("lineEnding"),e.consume(c),e.exit("lineEnding"),u)}function u(c){return l.parser.lazy[l.now().line]?i(c):r(c)}}const mc={name:"codeIndented",tokenize:Zk},Jk={partial:!0,tokenize:eS};function Zk(e,r,i){const l=this;return a;function a(m){return e.enter("codeIndented"),ot(e,u,"linePrefix",5)(m)}function u(m){const g=l.events[l.events.length-1];return g&&g[1].type==="linePrefix"&&g[2].sliceSerialize(g[1],!0).length>=4?c(m):i(m)}function c(m){return m===null?p(m):Ie(m)?e.attempt(Jk,c,p)(m):(e.enter("codeFlowValue"),f(m))}function f(m){return m===null||Ie(m)?(e.exit("codeFlowValue"),c(m)):(e.consume(m),f)}function p(m){return e.exit("codeIndented"),r(m)}}function eS(e,r,i){const l=this;return a;function a(c){return l.parser.lazy[l.now().line]?i(c):Ie(c)?(e.enter("lineEnding"),e.consume(c),e.exit("lineEnding"),a):ot(e,u,"linePrefix",5)(c)}function u(c){const f=l.events[l.events.length-1];return f&&f[1].type==="linePrefix"&&f[2].sliceSerialize(f[1],!0).length>=4?r(c):Ie(c)?a(c):i(c)}}const tS={name:"codeText",previous:rS,resolve:nS,tokenize:iS};function nS(e){let r=e.length-4,i=3,l,a;if((e[i][1].type==="lineEnding"||e[i][1].type==="space")&&(e[r][1].type==="lineEnding"||e[r][1].type==="space")){for(l=i;++l<r;)if(e[l][1].type==="codeTextData"){e[i][1].type="codeTextPadding",e[r][1].type="codeTextPadding",i+=2,r-=2;break}}for(l=i-1,r++;++l<=r;)a===void 0?l!==r&&e[l][1].type!=="lineEnding"&&(a=l):(l===r||e[l][1].type==="lineEnding")&&(e[a][1].type="codeTextData",l!==a+2&&(e[a][1].end=e[l-1][1].end,e.splice(a+2,l-a-2),r-=l-a-2,l=a+2),a=void 0);return e}function rS(e){return e!==96||this.events[this.events.length-1][1].type==="characterEscape"}function iS(e,r,i){let l=0,a,u;return c;function c(y){return e.enter("codeText"),e.enter("codeTextSequence"),f(y)}function f(y){return y===96?(e.consume(y),l++,f):(e.exit("codeTextSequence"),p(y))}function p(y){return y===null?i(y):y===32?(e.enter("space"),e.consume(y),e.exit("space"),p):y===96?(u=e.enter("codeTextSequence"),a=0,g(y)):Ie(y)?(e.enter("lineEnding"),e.consume(y),e.exit("lineEnding"),p):(e.enter("codeTextData"),m(y))}function m(y){return y===null||y===32||y===96||Ie(y)?(e.exit("codeTextData"),p(y)):(e.consume(y),m)}function g(y){return y===96?(e.consume(y),a++,g):a===l?(e.exit("codeTextSequence"),e.exit("codeText"),r(y)):(u.type="codeTextData",m(y))}}class lS{constructor(r){this.left=r?[...r]:[],this.right=[]}get(r){if(r<0||r>=this.left.length+this.right.length)throw new RangeError("Cannot access index `"+r+"` in a splice buffer of size `"+(this.left.length+this.right.length)+"`");return r<this.left.length?this.left[r]:this.right[this.right.length-r+this.left.length-1]}get length(){return this.left.length+this.right.length}shift(){return this.setCursor(0),this.right.pop()}slice(r,i){const l=i??Number.POSITIVE_INFINITY;return l<this.left.length?this.left.slice(r,l):r>this.left.length?this.right.slice(this.right.length-l+this.left.length,this.right.length-r+this.left.length).reverse():this.left.slice(r).concat(this.right.slice(this.right.length-l+this.left.length).reverse())}splice(r,i,l){const a=i||0;this.setCursor(Math.trunc(r));const u=this.right.splice(this.right.length-a,Number.POSITIVE_INFINITY);return l&&yo(this.left,l),u.reverse()}pop(){return this.setCursor(Number.POSITIVE_INFINITY),this.left.pop()}push(r){this.setCursor(Number.POSITIVE_INFINITY),this.left.push(r)}pushMany(r){this.setCursor(Number.POSITIVE_INFINITY),yo(this.left,r)}unshift(r){this.setCursor(0),this.right.push(r)}unshiftMany(r){this.setCursor(0),yo(this.right,r.reverse())}setCursor(r){if(!(r===this.left.length||r>this.left.length&&this.right.length===0||r<0&&this.left.length===0))if(r<this.left.length){const i=this.left.splice(r,Number.POSITIVE_INFINITY);yo(this.right,i.reverse())}else{const i=this.right.splice(this.left.length+this.right.length-r,Number.POSITIVE_INFINITY);yo(this.left,i.reverse())}}}function yo(e,r){let i=0;if(r.length<1e4)e.push(...r);else for(;i<r.length;)e.push(...r.slice(i,i+1e4)),i+=1e4}function Qg(e){const r={};let i=-1,l,a,u,c,f,p,m;const g=new lS(e);for(;++i<g.length;){for(;i in r;)i=r[i];if(l=g.get(i),i&&l[1].type==="chunkFlow"&&g.get(i-1)[1].type==="listItemPrefix"&&(p=l[1]._tokenizer.events,u=0,u<p.length&&p[u][1].type==="lineEndingBlank"&&(u+=2),u<p.length&&p[u][1].type==="content"))for(;++u<p.length&&p[u][1].type!=="content";)p[u][1].type==="chunkText"&&(p[u][1]._isInFirstContentOfListItem=!0,u++);if(l[0]==="enter")l[1].contentType&&(Object.assign(r,oS(g,i)),i=r[i],m=!0);else if(l[1]._container){for(u=i,a=void 0;u--;)if(c=g.get(u),c[1].type==="lineEnding"||c[1].type==="lineEndingBlank")c[0]==="enter"&&(a&&(g.get(a)[1].type="lineEndingBlank"),c[1].type="lineEnding",a=u);else if(!(c[1].type==="linePrefix"||c[1].type==="listItemIndent"))break;a&&(l[1].end={...g.get(a)[1].start},f=g.slice(a,i),f.unshift(l),g.splice(a,i-a+1,f))}}return Zn(e,0,Number.POSITIVE_INFINITY,g.slice(0)),!m}function oS(e,r){const i=e.get(r)[1],l=e.get(r)[2];let a=r-1;const u=[];let c=i._tokenizer;c||(c=l.parser[i.contentType](i.start),i._contentTypeTextTrailing&&(c._contentTypeTextTrailing=!0));const f=c.events,p=[],m={};let g,y,k=-1,x=i,T=0,N=0;const b=[N];for(;x;){for(;e.get(++a)[1]!==x;);u.push(a),x._tokenizer||(g=l.sliceStream(x),x.next||g.push(null),y&&c.defineSkip(x.start),x._isInFirstContentOfListItem&&(c._gfmTasklistFirstContentOfListItem=!0),c.write(g),x._isInFirstContentOfListItem&&(c._gfmTasklistFirstContentOfListItem=void 0)),y=x,x=x.next}for(x=i;++k<f.length;)f[k][0]==="exit"&&f[k-1][0]==="enter"&&f[k][1].type===f[k-1][1].type&&f[k][1].start.line!==f[k][1].end.line&&(N=k+1,b.push(N),x._tokenizer=void 0,x.previous=void 0,x=x.next);for(c.events=[],x?(x._tokenizer=void 0,x.previous=void 0):b.pop(),k=b.length;k--;){const P=f.slice(b[k],b[k+1]),z=u.pop();p.push([z,z+P.length-1]),e.splice(z,2,P)}for(p.reverse(),k=-1;++k<p.length;)m[T+p[k][0]]=T+p[k][1],T+=p[k][1]-p[k][0]-1;return m}const aS={resolve:uS,tokenize:cS},sS={partial:!0,tokenize:dS};function uS(e){return Qg(e),e}function cS(e,r){let i;return l;function l(f){return e.enter("content"),i=e.enter("chunkContent",{contentType:"content"}),a(f)}function a(f){return f===null?u(f):Ie(f)?e.check(sS,c,u)(f):(e.consume(f),a)}function u(f){return e.exit("chunkContent"),e.exit("content"),r(f)}function c(f){return e.consume(f),e.exit("chunkContent"),i.next=e.enter("chunkContent",{contentType:"content",previous:i}),i=i.next,a}}function dS(e,r,i){const l=this;return a;function a(c){return e.exit("chunkContent"),e.enter("lineEnding"),e.consume(c),e.exit("lineEnding"),ot(e,u,"linePrefix")}function u(c){if(c===null||Ie(c))return i(c);const f=l.events[l.events.length-1];return!l.parser.constructs.disable.null.includes("codeIndented")&&f&&f[1].type==="linePrefix"&&f[2].sliceSerialize(f[1],!0).length>=4?r(c):e.interrupt(l.parser.constructs.flow,i,r)(c)}}function qg(e,r,i,l,a,u,c,f,p){const m=p||Number.POSITIVE_INFINITY;let g=0;return y;function y(P){return P===60?(e.enter(l),e.enter(a),e.enter(u),e.consume(P),e.exit(u),k):P===null||P===32||P===41||Fc(P)?i(P):(e.enter(l),e.enter(c),e.enter(f),e.enter("chunkString",{contentType:"string"}),N(P))}function k(P){return P===62?(e.enter(u),e.consume(P),e.exit(u),e.exit(a),e.exit(l),r):(e.enter(f),e.enter("chunkString",{contentType:"string"}),x(P))}function x(P){return P===62?(e.exit("chunkString"),e.exit(f),k(P)):P===null||P===60||Ie(P)?i(P):(e.consume(P),P===92?T:x)}function T(P){return P===60||P===62||P===92?(e.consume(P),x):x(P)}function N(P){return!g&&(P===null||P===41||tn(P))?(e.exit("chunkString"),e.exit(f),e.exit(c),e.exit(l),r(P)):g<m&&P===40?(e.consume(P),g++,N):P===41?(e.consume(P),g--,N):P===null||P===32||P===40||Fc(P)?i(P):(e.consume(P),P===92?b:N)}function b(P){return P===40||P===41||P===92?(e.consume(P),N):N(P)}}function Kg(e,r,i,l,a,u){const c=this;let f=0,p;return m;function m(x){return e.enter(l),e.enter(a),e.consume(x),e.exit(a),e.enter(u),g}function g(x){return f>999||x===null||x===91||x===93&&!p||x===94&&!f&&"_hiddenFootnoteSupport"in c.parser.constructs?i(x):x===93?(e.exit(u),e.enter(a),e.consume(x),e.exit(a),e.exit(l),r):Ie(x)?(e.enter("lineEnding"),e.consume(x),e.exit("lineEnding"),g):(e.enter("chunkString",{contentType:"string"}),y(x))}function y(x){return x===null||x===91||x===93||Ie(x)||f++>999?(e.exit("chunkString"),g(x)):(e.consume(x),p||(p=!Je(x)),x===92?k:y)}function k(x){return x===91||x===92||x===93?(e.consume(x),f++,y):y(x)}}function Gg(e,r,i,l,a,u){let c;return f;function f(k){return k===34||k===39||k===40?(e.enter(l),e.enter(a),e.consume(k),e.exit(a),c=k===40?41:k,p):i(k)}function p(k){return k===c?(e.enter(a),e.consume(k),e.exit(a),e.exit(l),r):(e.enter(u),m(k))}function m(k){return k===c?(e.exit(u),p(c)):k===null?i(k):Ie(k)?(e.enter("lineEnding"),e.consume(k),e.exit("lineEnding"),ot(e,m,"linePrefix")):(e.enter("chunkString",{contentType:"string"}),g(k))}function g(k){return k===c||k===null||Ie(k)?(e.exit("chunkString"),m(k)):(e.consume(k),k===92?y:g)}function y(k){return k===c||k===92?(e.consume(k),g):g(k)}}function ko(e,r){let i;return l;function l(a){return Ie(a)?(e.enter("lineEnding"),e.consume(a),e.exit("lineEnding"),i=!0,l):Je(a)?ot(e,l,i?"linePrefix":"lineSuffix")(a):r(a)}}const fS={name:"definition",tokenize:pS},hS={partial:!0,tokenize:mS};function pS(e,r,i){const l=this;let a;return u;function u(x){return e.enter("definition"),c(x)}function c(x){return Kg.call(l,e,f,i,"definitionLabel","definitionLabelMarker","definitionLabelString")(x)}function f(x){return a=fl(l.sliceSerialize(l.events[l.events.length-1][1]).slice(1,-1)),x===58?(e.enter("definitionMarker"),e.consume(x),e.exit("definitionMarker"),p):i(x)}function p(x){return tn(x)?ko(e,m)(x):m(x)}function m(x){return qg(e,g,i,"definitionDestination","definitionDestinationLiteral","definitionDestinationLiteralMarker","definitionDestinationRaw","definitionDestinationString")(x)}function g(x){return e.attempt(hS,y,y)(x)}function y(x){return Je(x)?ot(e,k,"whitespace")(x):k(x)}function k(x){return x===null||Ie(x)?(e.exit("definition"),l.parser.defined.push(a),r(x)):i(x)}}function mS(e,r,i){return l;function l(f){return tn(f)?ko(e,a)(f):i(f)}function a(f){return Gg(e,u,i,"definitionTitle","definitionTitleMarker","definitionTitleString")(f)}function u(f){return Je(f)?ot(e,c,"whitespace")(f):c(f)}function c(f){return f===null||Ie(f)?r(f):i(f)}}const gS={name:"hardBreakEscape",tokenize:yS};function yS(e,r,i){return l;function l(u){return e.enter("hardBreakEscape"),e.consume(u),a}function a(u){return Ie(u)?(e.exit("hardBreakEscape"),r(u)):i(u)}}const vS={name:"headingAtx",resolve:xS,tokenize:wS};function xS(e,r){let i=e.length-2,l=3,a,u;return e[l][1].type==="whitespace"&&(l+=2),i-2>l&&e[i][1].type==="whitespace"&&(i-=2),e[i][1].type==="atxHeadingSequence"&&(l===i-1||i-4>l&&e[i-2][1].type==="whitespace")&&(i-=l+1===i?2:4),i>l&&(a={type:"atxHeadingText",start:e[l][1].start,end:e[i][1].end},u={type:"chunkText",start:e[l][1].start,end:e[i][1].end,contentType:"text"},Zn(e,l,i-l+1,[["enter",a,r],["enter",u,r],["exit",u,r],["exit",a,r]])),e}function wS(e,r,i){let l=0;return a;function a(g){return e.enter("atxHeading"),u(g)}function u(g){return e.enter("atxHeadingSequence"),c(g)}function c(g){return g===35&&l++<6?(e.consume(g),c):g===null||tn(g)?(e.exit("atxHeadingSequence"),f(g)):i(g)}function f(g){return g===35?(e.enter("atxHeadingSequence"),p(g)):g===null||Ie(g)?(e.exit("atxHeading"),r(g)):Je(g)?ot(e,f,"whitespace")(g):(e.enter("atxHeadingText"),m(g))}function p(g){return g===35?(e.consume(g),p):(e.exit("atxHeadingSequence"),f(g))}function m(g){return g===null||g===35||tn(g)?(e.exit("atxHeadingText"),f(g)):(e.consume(g),m)}}const kS=["address","article","aside","base","basefont","blockquote","body","caption","center","col","colgroup","dd","details","dialog","dir","div","dl","dt","fieldset","figcaption","figure","footer","form","frame","frameset","h1","h2","h3","h4","h5","h6","head","header","hr","html","iframe","legend","li","link","main","menu","menuitem","nav","noframes","ol","optgroup","option","p","param","search","section","summary","table","tbody","td","tfoot","th","thead","title","tr","track","ul"],nm=["pre","script","style","textarea"],SS={concrete:!0,name:"htmlFlow",resolveTo:bS,tokenize:NS},ES={partial:!0,tokenize:jS},CS={partial:!0,tokenize:PS};function bS(e){let r=e.length;for(;r--&&!(e[r][0]==="enter"&&e[r][1].type==="htmlFlow"););return r>1&&e[r-2][1].type==="linePrefix"&&(e[r][1].start=e[r-2][1].start,e[r+1][1].start=e[r-2][1].start,e.splice(r-2,2)),e}function NS(e,r,i){const l=this;let a,u,c,f,p;return m;function m(C){return g(C)}function g(C){return e.enter("htmlFlow"),e.enter("htmlFlowData"),e.consume(C),y}function y(C){return C===33?(e.consume(C),k):C===47?(e.consume(C),u=!0,N):C===63?(e.consume(C),a=3,l.interrupt?r:S):Jn(C)?(e.consume(C),c=String.fromCharCode(C),b):i(C)}function k(C){return C===45?(e.consume(C),a=2,x):C===91?(e.consume(C),a=5,f=0,T):Jn(C)?(e.consume(C),a=4,l.interrupt?r:S):i(C)}function x(C){return C===45?(e.consume(C),l.interrupt?r:S):i(C)}function T(C){const Ce="CDATA[";return C===Ce.charCodeAt(f++)?(e.consume(C),f===Ce.length?l.interrupt?r:K:T):i(C)}function N(C){return Jn(C)?(e.consume(C),c=String.fromCharCode(C),b):i(C)}function b(C){if(C===null||C===47||C===62||tn(C)){const Ce=C===47,Ne=c.toLowerCase();return!Ce&&!u&&nm.includes(Ne)?(a=1,l.interrupt?r(C):K(C)):kS.includes(c.toLowerCase())?(a=6,Ce?(e.consume(C),P):l.interrupt?r(C):K(C)):(a=7,l.interrupt&&!l.parser.lazy[l.now().line]?i(C):u?z(C):I(C))}return C===45||hn(C)?(e.consume(C),c+=String.fromCharCode(C),b):i(C)}function P(C){return C===62?(e.consume(C),l.interrupt?r:K):i(C)}function z(C){return Je(C)?(e.consume(C),z):re(C)}function I(C){return C===47?(e.consume(C),re):C===58||C===95||Jn(C)?(e.consume(C),F):Je(C)?(e.consume(C),I):re(C)}function F(C){return C===45||C===46||C===58||C===95||hn(C)?(e.consume(C),F):ee(C)}function ee(C){return C===61?(e.consume(C),B):Je(C)?(e.consume(C),ee):I(C)}function B(C){return C===null||C===60||C===61||C===62||C===96?i(C):C===34||C===39?(e.consume(C),p=C,D):Je(C)?(e.consume(C),B):G(C)}function D(C){return C===p?(e.consume(C),p=null,le):C===null||Ie(C)?i(C):(e.consume(C),D)}function G(C){return C===null||C===34||C===39||C===47||C===60||C===61||C===62||C===96||tn(C)?ee(C):(e.consume(C),G)}function le(C){return C===47||C===62||Je(C)?I(C):i(C)}function re(C){return C===62?(e.consume(C),$):i(C)}function $(C){return C===null||Ie(C)?K(C):Je(C)?(e.consume(C),$):i(C)}function K(C){return C===45&&a===2?(e.consume(C),be):C===60&&a===1?(e.consume(C),_e):C===62&&a===4?(e.consume(C),R):C===63&&a===3?(e.consume(C),S):C===93&&a===5?(e.consume(C),ce):Ie(C)&&(a===6||a===7)?(e.exit("htmlFlowData"),e.check(ES,q,Se)(C)):C===null||Ie(C)?(e.exit("htmlFlowData"),Se(C)):(e.consume(C),K)}function Se(C){return e.check(CS,se,q)(C)}function se(C){return e.enter("lineEnding"),e.consume(C),e.exit("lineEnding"),ne}function ne(C){return C===null||Ie(C)?Se(C):(e.enter("htmlFlowData"),K(C))}function be(C){return C===45?(e.consume(C),S):K(C)}function _e(C){return C===47?(e.consume(C),c="",Y):K(C)}function Y(C){if(C===62){const Ce=c.toLowerCase();return nm.includes(Ce)?(e.consume(C),R):K(C)}return Jn(C)&&c.length<8?(e.consume(C),c+=String.fromCharCode(C),Y):K(C)}function ce(C){return C===93?(e.consume(C),S):K(C)}function S(C){return C===62?(e.consume(C),R):C===45&&a===2?(e.consume(C),S):K(C)}function R(C){return C===null||Ie(C)?(e.exit("htmlFlowData"),q(C)):(e.consume(C),R)}function q(C){return e.exit("htmlFlow"),r(C)}}function PS(e,r,i){const l=this;return a;function a(c){return Ie(c)?(e.enter("lineEnding"),e.consume(c),e.exit("lineEnding"),u):i(c)}function u(c){return l.parser.lazy[l.now().line]?i(c):r(c)}}function jS(e,r,i){return l;function l(a){return e.enter("lineEnding"),e.consume(a),e.exit("lineEnding"),e.attempt(ys,r,i)}}const _S={name:"htmlText",tokenize:TS};function TS(e,r,i){const l=this;let a,u,c;return f;function f(S){return e.enter("htmlText"),e.enter("htmlTextData"),e.consume(S),p}function p(S){return S===33?(e.consume(S),m):S===47?(e.consume(S),ee):S===63?(e.consume(S),I):Jn(S)?(e.consume(S),G):i(S)}function m(S){return S===45?(e.consume(S),g):S===91?(e.consume(S),u=0,T):Jn(S)?(e.consume(S),z):i(S)}function g(S){return S===45?(e.consume(S),x):i(S)}function y(S){return S===null?i(S):S===45?(e.consume(S),k):Ie(S)?(c=y,_e(S)):(e.consume(S),y)}function k(S){return S===45?(e.consume(S),x):y(S)}function x(S){return S===62?be(S):S===45?k(S):y(S)}function T(S){const R="CDATA[";return S===R.charCodeAt(u++)?(e.consume(S),u===R.length?N:T):i(S)}function N(S){return S===null?i(S):S===93?(e.consume(S),b):Ie(S)?(c=N,_e(S)):(e.consume(S),N)}function b(S){return S===93?(e.consume(S),P):N(S)}function P(S){return S===62?be(S):S===93?(e.consume(S),P):N(S)}function z(S){return S===null||S===62?be(S):Ie(S)?(c=z,_e(S)):(e.consume(S),z)}function I(S){return S===null?i(S):S===63?(e.consume(S),F):Ie(S)?(c=I,_e(S)):(e.consume(S),I)}function F(S){return S===62?be(S):I(S)}function ee(S){return Jn(S)?(e.consume(S),B):i(S)}function B(S){return S===45||hn(S)?(e.consume(S),B):D(S)}function D(S){return Ie(S)?(c=D,_e(S)):Je(S)?(e.consume(S),D):be(S)}function G(S){return S===45||hn(S)?(e.consume(S),G):S===47||S===62||tn(S)?le(S):i(S)}function le(S){return S===47?(e.consume(S),be):S===58||S===95||Jn(S)?(e.consume(S),re):Ie(S)?(c=le,_e(S)):Je(S)?(e.consume(S),le):be(S)}function re(S){return S===45||S===46||S===58||S===95||hn(S)?(e.consume(S),re):$(S)}function $(S){return S===61?(e.consume(S),K):Ie(S)?(c=$,_e(S)):Je(S)?(e.consume(S),$):le(S)}function K(S){return S===null||S===60||S===61||S===62||S===96?i(S):S===34||S===39?(e.consume(S),a=S,Se):Ie(S)?(c=K,_e(S)):Je(S)?(e.consume(S),K):(e.consume(S),se)}function Se(S){return S===a?(e.consume(S),a=void 0,ne):S===null?i(S):Ie(S)?(c=Se,_e(S)):(e.consume(S),Se)}function se(S){return S===null||S===34||S===39||S===60||S===61||S===96?i(S):S===47||S===62||tn(S)?le(S):(e.consume(S),se)}function ne(S){return S===47||S===62||tn(S)?le(S):i(S)}function be(S){return S===62?(e.consume(S),e.exit("htmlTextData"),e.exit("htmlText"),r):i(S)}function _e(S){return e.exit("htmlTextData"),e.enter("lineEnding"),e.consume(S),e.exit("lineEnding"),Y}function Y(S){return Je(S)?ot(e,ce,"linePrefix",l.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(S):ce(S)}function ce(S){return e.enter("htmlTextData"),c(S)}}const fd={name:"labelEnd",resolveAll:MS,resolveTo:zS,tokenize:DS},RS={tokenize:AS},LS={tokenize:OS},IS={tokenize:FS};function MS(e){let r=-1;const i=[];for(;++r<e.length;){const l=e[r][1];if(i.push(e[r]),l.type==="labelImage"||l.type==="labelLink"||l.type==="labelEnd"){const a=l.type==="labelImage"?4:2;l.type="data",r+=a}}return e.length!==i.length&&Zn(e,0,e.length,i),e}function zS(e,r){let i=e.length,l=0,a,u,c,f;for(;i--;)if(a=e[i][1],u){if(a.type==="link"||a.type==="labelLink"&&a._inactive)break;e[i][0]==="enter"&&a.type==="labelLink"&&(a._inactive=!0)}else if(c){if(e[i][0]==="enter"&&(a.type==="labelImage"||a.type==="labelLink")&&!a._balanced&&(u=i,a.type!=="labelLink")){l=2;break}}else a.type==="labelEnd"&&(c=i);const p={type:e[u][1].type==="labelLink"?"link":"image",start:{...e[u][1].start},end:{...e[e.length-1][1].end}},m={type:"label",start:{...e[u][1].start},end:{...e[c][1].end}},g={type:"labelText",start:{...e[u+l+2][1].end},end:{...e[c-2][1].start}};return f=[["enter",p,r],["enter",m,r]],f=En(f,e.slice(u+1,u+l+3)),f=En(f,[["enter",g,r]]),f=En(f,dd(r.parser.constructs.insideSpan.null,e.slice(u+l+4,c-3),r)),f=En(f,[["exit",g,r],e[c-2],e[c-1],["exit",m,r]]),f=En(f,e.slice(c+1)),f=En(f,[["exit",p,r]]),Zn(e,u,e.length,f),e}function DS(e,r,i){const l=this;let a=l.events.length,u,c;for(;a--;)if((l.events[a][1].type==="labelImage"||l.events[a][1].type==="labelLink")&&!l.events[a][1]._balanced){u=l.events[a][1];break}return f;function f(k){return u?u._inactive?y(k):(c=l.parser.defined.includes(fl(l.sliceSerialize({start:u.end,end:l.now()}))),e.enter("labelEnd"),e.enter("labelMarker"),e.consume(k),e.exit("labelMarker"),e.exit("labelEnd"),p):i(k)}function p(k){return k===40?e.attempt(RS,g,c?g:y)(k):k===91?e.attempt(LS,g,c?m:y)(k):c?g(k):y(k)}function m(k){return e.attempt(IS,g,y)(k)}function g(k){return r(k)}function y(k){return u._balanced=!0,i(k)}}function AS(e,r,i){return l;function l(y){return e.enter("resource"),e.enter("resourceMarker"),e.consume(y),e.exit("resourceMarker"),a}function a(y){return tn(y)?ko(e,u)(y):u(y)}function u(y){return y===41?g(y):qg(e,c,f,"resourceDestination","resourceDestinationLiteral","resourceDestinationLiteralMarker","resourceDestinationRaw","resourceDestinationString",32)(y)}function c(y){return tn(y)?ko(e,p)(y):g(y)}function f(y){return i(y)}function p(y){return y===34||y===39||y===40?Gg(e,m,i,"resourceTitle","resourceTitleMarker","resourceTitleString")(y):g(y)}function m(y){return tn(y)?ko(e,g)(y):g(y)}function g(y){return y===41?(e.enter("resourceMarker"),e.consume(y),e.exit("resourceMarker"),e.exit("resource"),r):i(y)}}function OS(e,r,i){const l=this;return a;function a(f){return Kg.call(l,e,u,c,"reference","referenceMarker","referenceString")(f)}function u(f){return l.parser.defined.includes(fl(l.sliceSerialize(l.events[l.events.length-1][1]).slice(1,-1)))?r(f):i(f)}function c(f){return i(f)}}function FS(e,r,i){return l;function l(u){return e.enter("reference"),e.enter("referenceMarker"),e.consume(u),e.exit("referenceMarker"),a}function a(u){return u===93?(e.enter("referenceMarker"),e.consume(u),e.exit("referenceMarker"),e.exit("reference"),r):i(u)}}const US={name:"labelStartImage",resolveAll:fd.resolveAll,tokenize:BS};function BS(e,r,i){const l=this;return a;function a(f){return e.enter("labelImage"),e.enter("labelImageMarker"),e.consume(f),e.exit("labelImageMarker"),u}function u(f){return f===91?(e.enter("labelMarker"),e.consume(f),e.exit("labelMarker"),e.exit("labelImage"),c):i(f)}function c(f){return f===94&&"_hiddenFootnoteSupport"in l.parser.constructs?i(f):r(f)}}const HS={name:"labelStartLink",resolveAll:fd.resolveAll,tokenize:VS};function VS(e,r,i){const l=this;return a;function a(c){return e.enter("labelLink"),e.enter("labelMarker"),e.consume(c),e.exit("labelMarker"),e.exit("labelLink"),u}function u(c){return c===94&&"_hiddenFootnoteSupport"in l.parser.constructs?i(c):r(c)}}const gc={name:"lineEnding",tokenize:$S};function $S(e,r){return i;function i(l){return e.enter("lineEnding"),e.consume(l),e.exit("lineEnding"),ot(e,r,"linePrefix")}}const ns={name:"thematicBreak",tokenize:WS};function WS(e,r,i){let l=0,a;return u;function u(m){return e.enter("thematicBreak"),c(m)}function c(m){return a=m,f(m)}function f(m){return m===a?(e.enter("thematicBreakSequence"),p(m)):l>=3&&(m===null||Ie(m))?(e.exit("thematicBreak"),r(m)):i(m)}function p(m){return m===a?(e.consume(m),l++,p):(e.exit("thematicBreakSequence"),Je(m)?ot(e,f,"whitespace")(m):f(m))}}const Zt={continuation:{tokenize:GS},exit:XS,name:"list",tokenize:KS},QS={partial:!0,tokenize:JS},qS={partial:!0,tokenize:YS};function KS(e,r,i){const l=this,a=l.events[l.events.length-1];let u=a&&a[1].type==="linePrefix"?a[2].sliceSerialize(a[1],!0).length:0,c=0;return f;function f(x){const T=l.containerState.type||(x===42||x===43||x===45?"listUnordered":"listOrdered");if(T==="listUnordered"?!l.containerState.marker||x===l.containerState.marker:Uc(x)){if(l.containerState.type||(l.containerState.type=T,e.enter(T,{_container:!0})),T==="listUnordered")return e.enter("listItemPrefix"),x===42||x===45?e.check(ns,i,m)(x):m(x);if(!l.interrupt||x===49)return e.enter("listItemPrefix"),e.enter("listItemValue"),p(x)}return i(x)}function p(x){return Uc(x)&&++c<10?(e.consume(x),p):(!l.interrupt||c<2)&&(l.containerState.marker?x===l.containerState.marker:x===41||x===46)?(e.exit("listItemValue"),m(x)):i(x)}function m(x){return e.enter("listItemMarker"),e.consume(x),e.exit("listItemMarker"),l.containerState.marker=l.containerState.marker||x,e.check(ys,l.interrupt?i:g,e.attempt(QS,k,y))}function g(x){return l.containerState.initialBlankLine=!0,u++,k(x)}function y(x){return Je(x)?(e.enter("listItemPrefixWhitespace"),e.consume(x),e.exit("listItemPrefixWhitespace"),k):i(x)}function k(x){return l.containerState.size=u+l.sliceSerialize(e.exit("listItemPrefix"),!0).length,r(x)}}function GS(e,r,i){const l=this;return l.containerState._closeFlow=void 0,e.check(ys,a,u);function a(f){return l.containerState.furtherBlankLines=l.containerState.furtherBlankLines||l.containerState.initialBlankLine,ot(e,r,"listItemIndent",l.containerState.size+1)(f)}function u(f){return l.containerState.furtherBlankLines||!Je(f)?(l.containerState.furtherBlankLines=void 0,l.containerState.initialBlankLine=void 0,c(f)):(l.containerState.furtherBlankLines=void 0,l.containerState.initialBlankLine=void 0,e.attempt(qS,r,c)(f))}function c(f){return l.containerState._closeFlow=!0,l.interrupt=void 0,ot(e,e.attempt(Zt,r,i),"linePrefix",l.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(f)}}function YS(e,r,i){const l=this;return ot(e,a,"listItemIndent",l.containerState.size+1);function a(u){const c=l.events[l.events.length-1];return c&&c[1].type==="listItemIndent"&&c[2].sliceSerialize(c[1],!0).length===l.containerState.size?r(u):i(u)}}function XS(e){e.exit(this.containerState.type)}function JS(e,r,i){const l=this;return ot(e,a,"listItemPrefixWhitespace",l.parser.constructs.disable.null.includes("codeIndented")?void 0:5);function a(u){const c=l.events[l.events.length-1];return!Je(u)&&c&&c[1].type==="listItemPrefixWhitespace"?r(u):i(u)}}const rm={name:"setextUnderline",resolveTo:ZS,tokenize:eE};function ZS(e,r){let i=e.length,l,a,u;for(;i--;)if(e[i][0]==="enter"){if(e[i][1].type==="content"){l=i;break}e[i][1].type==="paragraph"&&(a=i)}else e[i][1].type==="content"&&e.splice(i,1),!u&&e[i][1].type==="definition"&&(u=i);const c={type:"setextHeading",start:{...e[l][1].start},end:{...e[e.length-1][1].end}};return e[a][1].type="setextHeadingText",u?(e.splice(a,0,["enter",c,r]),e.splice(u+1,0,["exit",e[l][1],r]),e[l][1].end={...e[u][1].end}):e[l][1]=c,e.push(["exit",c,r]),e}function eE(e,r,i){const l=this;let a;return u;function u(m){let g=l.events.length,y;for(;g--;)if(l.events[g][1].type!=="lineEnding"&&l.events[g][1].type!=="linePrefix"&&l.events[g][1].type!=="content"){y=l.events[g][1].type==="paragraph";break}return!l.parser.lazy[l.now().line]&&(l.interrupt||y)?(e.enter("setextHeadingLine"),a=m,c(m)):i(m)}function c(m){return e.enter("setextHeadingLineSequence"),f(m)}function f(m){return m===a?(e.consume(m),f):(e.exit("setextHeadingLineSequence"),Je(m)?ot(e,p,"lineSuffix")(m):p(m))}function p(m){return m===null||Ie(m)?(e.exit("setextHeadingLine"),r(m)):i(m)}}const tE={tokenize:nE};function nE(e){const r=this,i=e.attempt(ys,l,e.attempt(this.parser.constructs.flowInitial,a,ot(e,e.attempt(this.parser.constructs.flow,a,e.attempt(aS,a)),"linePrefix")));return i;function l(u){if(u===null){e.consume(u);return}return e.enter("lineEndingBlank"),e.consume(u),e.exit("lineEndingBlank"),r.currentConstruct=void 0,i}function a(u){if(u===null){e.consume(u);return}return e.enter("lineEnding"),e.consume(u),e.exit("lineEnding"),r.currentConstruct=void 0,i}}const rE={resolveAll:Xg()},iE=Yg("string"),lE=Yg("text");function Yg(e){return{resolveAll:Xg(e==="text"?oE:void 0),tokenize:r};function r(i){const l=this,a=this.parser.constructs[e],u=i.attempt(a,c,f);return c;function c(g){return m(g)?u(g):f(g)}function f(g){if(g===null){i.consume(g);return}return i.enter("data"),i.consume(g),p}function p(g){return m(g)?(i.exit("data"),u(g)):(i.consume(g),p)}function m(g){if(g===null)return!0;const y=a[g];let k=-1;if(y)for(;++k<y.length;){const x=y[k];if(!x.previous||x.previous.call(l,l.previous))return!0}return!1}}}function Xg(e){return r;function r(i,l){let a=-1,u;for(;++a<=i.length;)u===void 0?i[a]&&i[a][1].type==="data"&&(u=a,a++):(!i[a]||i[a][1].type!=="data")&&(a!==u+2&&(i[u][1].end=i[a-1][1].end,i.splice(u+2,a-u-2),a=u+2),u=void 0);return e?e(i,l):i}}function oE(e,r){let i=0;for(;++i<=e.length;)if((i===e.length||e[i][1].type==="lineEnding")&&e[i-1][1].type==="data"){const l=e[i-1][1],a=r.sliceStream(l);let u=a.length,c=-1,f=0,p;for(;u--;){const m=a[u];if(typeof m=="string"){for(c=m.length;m.charCodeAt(c-1)===32;)f++,c--;if(c)break;c=-1}else if(m===-2)p=!0,f++;else if(m!==-1){u++;break}}if(r._contentTypeTextTrailing&&i===e.length&&(f=0),f){const m={type:i===e.length||p||f<2?"lineSuffix":"hardBreakTrailing",start:{_bufferIndex:u?c:l.start._bufferIndex+c,_index:l.start._index+u,line:l.end.line,column:l.end.column-f,offset:l.end.offset-f},end:{...l.end}};l.end={...m.start},l.start.offset===l.end.offset?Object.assign(l,m):(e.splice(i,0,["enter",m,r],["exit",m,r]),i+=2)}i++}return e}const aE={42:Zt,43:Zt,45:Zt,48:Zt,49:Zt,50:Zt,51:Zt,52:Zt,53:Zt,54:Zt,55:Zt,56:Zt,57:Zt,62:Vg},sE={91:fS},uE={[-2]:mc,[-1]:mc,32:mc},cE={35:vS,42:ns,45:[rm,ns],60:SS,61:rm,95:ns,96:tm,126:tm},dE={38:Wg,92:$g},fE={[-5]:gc,[-4]:gc,[-3]:gc,33:US,38:Wg,42:Bc,60:[Hk,_S],91:HS,92:[gS,$g],93:fd,95:Bc,96:tS},hE={null:[Bc,rE]},pE={null:[42,95]},mE={null:[]},gE=Object.freeze(Object.defineProperty({__proto__:null,attentionMarkers:pE,contentInitial:sE,disable:mE,document:aE,flow:cE,flowInitial:uE,insideSpan:hE,string:dE,text:fE},Symbol.toStringTag,{value:"Module"}));function yE(e,r,i){let l={_bufferIndex:-1,_index:0,line:i&&i.line||1,column:i&&i.column||1,offset:i&&i.offset||0};const a={},u=[];let c=[],f=[];const p={attempt:D(ee),check:D(B),consume:z,enter:I,exit:F,interrupt:D(B,{interrupt:!0})},m={code:null,containerState:{},defineSkip:N,events:[],now:T,parser:e,previous:null,sliceSerialize:k,sliceStream:x,write:y};let g=r.tokenize.call(m,p);return r.resolveAll&&u.push(r),m;function y($){return c=En(c,$),b(),c[c.length-1]!==null?[]:(G(r,0),m.events=dd(u,m.events,m),m.events)}function k($,K){return xE(x($),K)}function x($){return vE(c,$)}function T(){const{_bufferIndex:$,_index:K,line:Se,column:se,offset:ne}=l;return{_bufferIndex:$,_index:K,line:Se,column:se,offset:ne}}function N($){a[$.line]=$.column,re()}function b(){let $;for(;l._index<c.length;){const K=c[l._index];if(typeof K=="string")for($=l._index,l._bufferIndex<0&&(l._bufferIndex=0);l._index===$&&l._bufferIndex<K.length;)P(K.charCodeAt(l._bufferIndex));else P(K)}}function P($){g=g($)}function z($){Ie($)?(l.line++,l.column=1,l.offset+=$===-3?2:1,re()):$!==-1&&(l.column++,l.offset++),l._bufferIndex<0?l._index++:(l._bufferIndex++,l._bufferIndex===c[l._index].length&&(l._bufferIndex=-1,l._index++)),m.previous=$}function I($,K){const Se=K||{};return Se.type=$,Se.start=T(),m.events.push(["enter",Se,m]),f.push(Se),Se}function F($){const K=f.pop();return K.end=T(),m.events.push(["exit",K,m]),K}function ee($,K){G($,K.from)}function B($,K){K.restore()}function D($,K){return Se;function Se(se,ne,be){let _e,Y,ce,S;return Array.isArray(se)?q(se):"tokenize"in se?q([se]):R(se);function R(ke){return Fe;function Fe(De){const qe=De!==null&&ke[De],mt=De!==null&&ke.null,Cn=[...Array.isArray(qe)?qe:qe?[qe]:[],...Array.isArray(mt)?mt:mt?[mt]:[]];return q(Cn)(De)}}function q(ke){return _e=ke,Y=0,ke.length===0?be:C(ke[Y])}function C(ke){return Fe;function Fe(De){return S=le(),ce=ke,ke.partial||(m.currentConstruct=ke),ke.name&&m.parser.constructs.disable.null.includes(ke.name)?Ne():ke.tokenize.call(K?Object.assign(Object.create(m),K):m,p,Ce,Ne)(De)}}function Ce(ke){return $(ce,S),ne}function Ne(ke){return S.restore(),++Y<_e.length?C(_e[Y]):be}}}function G($,K){$.resolveAll&&!u.includes($)&&u.push($),$.resolve&&Zn(m.events,K,m.events.length-K,$.resolve(m.events.slice(K),m)),$.resolveTo&&(m.events=$.resolveTo(m.events,m))}function le(){const $=T(),K=m.previous,Se=m.currentConstruct,se=m.events.length,ne=Array.from(f);return{from:se,restore:be};function be(){l=$,m.previous=K,m.currentConstruct=Se,m.events.length=se,f=ne,re()}}function re(){l.line in a&&l.column<2&&(l.column=a[l.line],l.offset+=a[l.line]-1)}}function vE(e,r){const i=r.start._index,l=r.start._bufferIndex,a=r.end._index,u=r.end._bufferIndex;let c;if(i===a)c=[e[i].slice(l,u)];else{if(c=e.slice(i,a),l>-1){const f=c[0];typeof f=="string"?c[0]=f.slice(l):c.shift()}u>0&&c.push(e[a].slice(0,u))}return c}function xE(e,r){let i=-1;const l=[];let a;for(;++i<e.length;){const u=e[i];let c;if(typeof u=="string")c=u;else switch(u){case-5:{c="\r";break}case-4:{c=`
|
|
262
|
+
`;break}case-3:{c=`\r
|
|
263
|
+
`;break}case-2:{c=r?" ":" ";break}case-1:{if(!r&&a)continue;c=" ";break}default:c=String.fromCharCode(u)}a=u===-2,l.push(c)}return l.join("")}function wE(e){const l={constructs:Pk([gE,...(e||{}).extensions||[]]),content:a(zk),defined:[],document:a(Ak),flow:a(tE),lazy:{},string:a(iE),text:a(lE)};return l;function a(u){return c;function c(f){return yE(l,u,f)}}}function kE(e){for(;!Qg(e););return e}const im=/[\0\t\n\r]/g;function SE(){let e=1,r="",i=!0,l;return a;function a(u,c,f){const p=[];let m,g,y,k,x;for(u=r+(typeof u=="string"?u.toString():new TextDecoder(c||void 0).decode(u)),y=0,r="",i&&(u.charCodeAt(0)===65279&&y++,i=void 0);y<u.length;){if(im.lastIndex=y,m=im.exec(u),k=m&&m.index!==void 0?m.index:u.length,x=u.charCodeAt(k),!m){r=u.slice(y);break}if(x===10&&y===k&&l)p.push(-3),l=void 0;else switch(l&&(p.push(-5),l=void 0),y<k&&(p.push(u.slice(y,k)),e+=k-y),x){case 0:{p.push(65533),e++;break}case 9:{for(g=Math.ceil(e/4)*4,p.push(-2);e++<g;)p.push(-1);break}case 10:{p.push(-4),e=1;break}default:l=!0,e=1}y=k+1}return f&&(l&&p.push(-5),r&&p.push(r),p.push(null)),p}}const EE=/\\([!-/:-@[-`{-~])|&(#(?:\d{1,7}|x[\da-f]{1,6})|[\da-z]{1,31});/gi;function CE(e){return e.replace(EE,bE)}function bE(e,r,i){if(r)return r;if(i.charCodeAt(0)===35){const a=i.charCodeAt(1),u=a===120||a===88;return Hg(i.slice(u?2:1),u?16:10)}return cd(i)||e}const Jg={}.hasOwnProperty;function NE(e,r,i){return r&&typeof r=="object"&&(i=r,r=void 0),PE(i)(kE(wE(i).document().write(SE()(e,r,!0))))}function PE(e){const r={transforms:[],canContainEols:["emphasis","fragment","heading","paragraph","strong"],enter:{autolink:u(er),autolinkProtocol:le,autolinkEmail:le,atxHeading:u(li),blockQuote:u(mt),characterEscape:le,characterReference:le,codeFenced:u(Cn),codeFencedFenceInfo:c,codeFencedFenceMeta:c,codeIndented:u(Cn,c),codeText:u(kt,c),codeTextData:le,data:le,codeFlowValue:le,definition:u(rn),definitionDestinationString:c,definitionLabelString:c,definitionTitleString:c,emphasis:u(vr),hardBreakEscape:u(ln),hardBreakTrailing:u(ln),htmlFlow:u(xr,c),htmlFlowData:le,htmlText:u(xr,c),htmlTextData:le,image:u(zi),label:c,link:u(er),listItem:u(On),listItemValue:k,listOrdered:u(An,y),listUnordered:u(An),paragraph:u(oi),reference:C,referenceString:c,resourceDestinationString:c,resourceTitleString:c,setextHeading:u(li),strong:u(Di),thematicBreak:u(Fn)},exit:{atxHeading:p(),atxHeadingSequence:ee,autolink:p(),autolinkEmail:qe,autolinkProtocol:De,blockQuote:p(),characterEscapeValue:re,characterReferenceMarkerHexadecimal:Ne,characterReferenceMarkerNumeric:Ne,characterReferenceValue:ke,characterReference:Fe,codeFenced:p(b),codeFencedFence:N,codeFencedFenceInfo:x,codeFencedFenceMeta:T,codeFlowValue:re,codeIndented:p(P),codeText:p(ne),codeTextData:re,data:re,definition:p(),definitionDestinationString:F,definitionLabelString:z,definitionTitleString:I,emphasis:p(),hardBreakEscape:p(K),hardBreakTrailing:p(K),htmlFlow:p(Se),htmlFlowData:re,htmlText:p(se),htmlTextData:re,image:p(_e),label:ce,labelText:Y,lineEnding:$,link:p(be),listItem:p(),listOrdered:p(),listUnordered:p(),paragraph:p(),referenceString:Ce,resourceDestinationString:S,resourceTitleString:R,resource:q,setextHeading:p(G),setextHeadingLineSequence:D,setextHeadingText:B,strong:p(),thematicBreak:p()}};Zg(r,(e||{}).mdastExtensions||[]);const i={};return l;function l(W){let ae={type:"root",children:[]};const Ee={stack:[ae],tokenStack:[],config:r,enter:f,exit:m,buffer:c,resume:g,data:i},Re=[];let Ve=-1;for(;++Ve<W.length;)if(W[Ve][1].type==="listOrdered"||W[Ve][1].type==="listUnordered")if(W[Ve][0]==="enter")Re.push(Ve);else{const gt=Re.pop();Ve=a(W,gt,Ve)}for(Ve=-1;++Ve<W.length;){const gt=r[W[Ve][0]];Jg.call(gt,W[Ve][1].type)&>[W[Ve][1].type].call(Object.assign({sliceSerialize:W[Ve][2].sliceSerialize},Ee),W[Ve][1])}if(Ee.tokenStack.length>0){const gt=Ee.tokenStack[Ee.tokenStack.length-1];(gt[1]||lm).call(Ee,void 0,gt[0])}for(ae.position={start:$r(W.length>0?W[0][1].start:{line:1,column:1,offset:0}),end:$r(W.length>0?W[W.length-2][1].end:{line:1,column:1,offset:0})},Ve=-1;++Ve<r.transforms.length;)ae=r.transforms[Ve](ae)||ae;return ae}function a(W,ae,Ee){let Re=ae-1,Ve=-1,gt=!1,bn,xt,Nn,Un;for(;++Re<=Ee;){const St=W[Re];switch(St[1].type){case"listUnordered":case"listOrdered":case"blockQuote":{St[0]==="enter"?Ve++:Ve--,Un=void 0;break}case"lineEndingBlank":{St[0]==="enter"&&(bn&&!Un&&!Ve&&!Nn&&(Nn=Re),Un=void 0);break}case"linePrefix":case"listItemValue":case"listItemMarker":case"listItemPrefix":case"listItemPrefixWhitespace":break;default:Un=void 0}if(!Ve&&St[0]==="enter"&&St[1].type==="listItemPrefix"||Ve===-1&&St[0]==="exit"&&(St[1].type==="listUnordered"||St[1].type==="listOrdered")){if(bn){let mn=Re;for(xt=void 0;mn--;){const At=W[mn];if(At[1].type==="lineEnding"||At[1].type==="lineEndingBlank"){if(At[0]==="exit")continue;xt&&(W[xt][1].type="lineEndingBlank",gt=!0),At[1].type="lineEnding",xt=mn}else if(!(At[1].type==="linePrefix"||At[1].type==="blockQuotePrefix"||At[1].type==="blockQuotePrefixWhitespace"||At[1].type==="blockQuoteMarker"||At[1].type==="listItemIndent"))break}Nn&&(!xt||Nn<xt)&&(bn._spread=!0),bn.end=Object.assign({},xt?W[xt][1].start:St[1].end),W.splice(xt||Re,0,["exit",bn,St[2]]),Re++,Ee++}if(St[1].type==="listItemPrefix"){const mn={type:"listItem",_spread:!1,start:Object.assign({},St[1].start),end:void 0};bn=mn,W.splice(Re,0,["enter",mn,St[2]]),Re++,Ee++,Nn=void 0,Un=!0}}}return W[ae][1]._spread=gt,Ee}function u(W,ae){return Ee;function Ee(Re){f.call(this,W(Re),Re),ae&&ae.call(this,Re)}}function c(){this.stack.push({type:"fragment",children:[]})}function f(W,ae,Ee){this.stack[this.stack.length-1].children.push(W),this.stack.push(W),this.tokenStack.push([ae,Ee||void 0]),W.position={start:$r(ae.start),end:void 0}}function p(W){return ae;function ae(Ee){W&&W.call(this,Ee),m.call(this,Ee)}}function m(W,ae){const Ee=this.stack.pop(),Re=this.tokenStack.pop();if(Re)Re[0].type!==W.type&&(ae?ae.call(this,W,Re[0]):(Re[1]||lm).call(this,W,Re[0]));else throw new Error("Cannot close `"+W.type+"` ("+wo({start:W.start,end:W.end})+"): it’s not open");Ee.position.end=$r(W.end)}function g(){return bk(this.stack.pop())}function y(){this.data.expectingFirstListItemValue=!0}function k(W){if(this.data.expectingFirstListItemValue){const ae=this.stack[this.stack.length-2];ae.start=Number.parseInt(this.sliceSerialize(W),10),this.data.expectingFirstListItemValue=void 0}}function x(){const W=this.resume(),ae=this.stack[this.stack.length-1];ae.lang=W}function T(){const W=this.resume(),ae=this.stack[this.stack.length-1];ae.meta=W}function N(){this.data.flowCodeInside||(this.buffer(),this.data.flowCodeInside=!0)}function b(){const W=this.resume(),ae=this.stack[this.stack.length-1];ae.value=W.replace(/^(\r?\n|\r)|(\r?\n|\r)$/g,""),this.data.flowCodeInside=void 0}function P(){const W=this.resume(),ae=this.stack[this.stack.length-1];ae.value=W.replace(/(\r?\n|\r)$/g,"")}function z(W){const ae=this.resume(),Ee=this.stack[this.stack.length-1];Ee.label=ae,Ee.identifier=fl(this.sliceSerialize(W)).toLowerCase()}function I(){const W=this.resume(),ae=this.stack[this.stack.length-1];ae.title=W}function F(){const W=this.resume(),ae=this.stack[this.stack.length-1];ae.url=W}function ee(W){const ae=this.stack[this.stack.length-1];if(!ae.depth){const Ee=this.sliceSerialize(W).length;ae.depth=Ee}}function B(){this.data.setextHeadingSlurpLineEnding=!0}function D(W){const ae=this.stack[this.stack.length-1];ae.depth=this.sliceSerialize(W).codePointAt(0)===61?1:2}function G(){this.data.setextHeadingSlurpLineEnding=void 0}function le(W){const Ee=this.stack[this.stack.length-1].children;let Re=Ee[Ee.length-1];(!Re||Re.type!=="text")&&(Re=pn(),Re.position={start:$r(W.start),end:void 0},Ee.push(Re)),this.stack.push(Re)}function re(W){const ae=this.stack.pop();ae.value+=this.sliceSerialize(W),ae.position.end=$r(W.end)}function $(W){const ae=this.stack[this.stack.length-1];if(this.data.atHardBreak){const Ee=ae.children[ae.children.length-1];Ee.position.end=$r(W.end),this.data.atHardBreak=void 0;return}!this.data.setextHeadingSlurpLineEnding&&r.canContainEols.includes(ae.type)&&(le.call(this,W),re.call(this,W))}function K(){this.data.atHardBreak=!0}function Se(){const W=this.resume(),ae=this.stack[this.stack.length-1];ae.value=W}function se(){const W=this.resume(),ae=this.stack[this.stack.length-1];ae.value=W}function ne(){const W=this.resume(),ae=this.stack[this.stack.length-1];ae.value=W}function be(){const W=this.stack[this.stack.length-1];if(this.data.inReference){const ae=this.data.referenceType||"shortcut";W.type+="Reference",W.referenceType=ae,delete W.url,delete W.title}else delete W.identifier,delete W.label;this.data.referenceType=void 0}function _e(){const W=this.stack[this.stack.length-1];if(this.data.inReference){const ae=this.data.referenceType||"shortcut";W.type+="Reference",W.referenceType=ae,delete W.url,delete W.title}else delete W.identifier,delete W.label;this.data.referenceType=void 0}function Y(W){const ae=this.sliceSerialize(W),Ee=this.stack[this.stack.length-2];Ee.label=CE(ae),Ee.identifier=fl(ae).toLowerCase()}function ce(){const W=this.stack[this.stack.length-1],ae=this.resume(),Ee=this.stack[this.stack.length-1];if(this.data.inReference=!0,Ee.type==="link"){const Re=W.children;Ee.children=Re}else Ee.alt=ae}function S(){const W=this.resume(),ae=this.stack[this.stack.length-1];ae.url=W}function R(){const W=this.resume(),ae=this.stack[this.stack.length-1];ae.title=W}function q(){this.data.inReference=void 0}function C(){this.data.referenceType="collapsed"}function Ce(W){const ae=this.resume(),Ee=this.stack[this.stack.length-1];Ee.label=ae,Ee.identifier=fl(this.sliceSerialize(W)).toLowerCase(),this.data.referenceType="full"}function Ne(W){this.data.characterReferenceType=W.type}function ke(W){const ae=this.sliceSerialize(W),Ee=this.data.characterReferenceType;let Re;Ee?(Re=Hg(ae,Ee==="characterReferenceMarkerNumeric"?10:16),this.data.characterReferenceType=void 0):Re=cd(ae);const Ve=this.stack[this.stack.length-1];Ve.value+=Re}function Fe(W){const ae=this.stack.pop();ae.position.end=$r(W.end)}function De(W){re.call(this,W);const ae=this.stack[this.stack.length-1];ae.url=this.sliceSerialize(W)}function qe(W){re.call(this,W);const ae=this.stack[this.stack.length-1];ae.url="mailto:"+this.sliceSerialize(W)}function mt(){return{type:"blockquote",children:[]}}function Cn(){return{type:"code",lang:null,meta:null,value:""}}function kt(){return{type:"inlineCode",value:""}}function rn(){return{type:"definition",identifier:"",label:null,title:null,url:""}}function vr(){return{type:"emphasis",children:[]}}function li(){return{type:"heading",depth:0,children:[]}}function ln(){return{type:"break"}}function xr(){return{type:"html",value:""}}function zi(){return{type:"image",title:null,url:"",alt:null}}function er(){return{type:"link",title:null,url:"",children:[]}}function An(W){return{type:"list",ordered:W.type==="listOrdered",start:null,spread:W._spread,children:[]}}function On(W){return{type:"listItem",spread:W._spread,checked:null,children:[]}}function oi(){return{type:"paragraph",children:[]}}function Di(){return{type:"strong",children:[]}}function pn(){return{type:"text",value:""}}function Fn(){return{type:"thematicBreak"}}}function $r(e){return{line:e.line,column:e.column,offset:e.offset}}function Zg(e,r){let i=-1;for(;++i<r.length;){const l=r[i];Array.isArray(l)?Zg(e,l):jE(e,l)}}function jE(e,r){let i;for(i in r)if(Jg.call(r,i))switch(i){case"canContainEols":{const l=r[i];l&&e[i].push(...l);break}case"transforms":{const l=r[i];l&&e[i].push(...l);break}case"enter":case"exit":{const l=r[i];l&&Object.assign(e[i],l);break}}}function lm(e,r){throw e?new Error("Cannot close `"+e.type+"` ("+wo({start:e.start,end:e.end})+"): a different token (`"+r.type+"`, "+wo({start:r.start,end:r.end})+") is open"):new Error("Cannot close document, a token (`"+r.type+"`, "+wo({start:r.start,end:r.end})+") is still open")}function _E(e){const r=this;r.parser=i;function i(l){return NE(l,{...r.data("settings"),...e,extensions:r.data("micromarkExtensions")||[],mdastExtensions:r.data("fromMarkdownExtensions")||[]})}}function TE(e,r){const i={type:"element",tagName:"blockquote",properties:{},children:e.wrap(e.all(r),!0)};return e.patch(r,i),e.applyData(r,i)}function RE(e,r){const i={type:"element",tagName:"br",properties:{},children:[]};return e.patch(r,i),[e.applyData(r,i),{type:"text",value:`
|
|
264
|
+
`}]}function LE(e,r){const i=r.value?r.value+`
|
|
265
|
+
`:"",l={},a=r.lang?r.lang.split(/\s+/):[];a.length>0&&(l.className=["language-"+a[0]]);let u={type:"element",tagName:"code",properties:l,children:[{type:"text",value:i}]};return r.meta&&(u.data={meta:r.meta}),e.patch(r,u),u=e.applyData(r,u),u={type:"element",tagName:"pre",properties:{},children:[u]},e.patch(r,u),u}function IE(e,r){const i={type:"element",tagName:"del",properties:{},children:e.all(r)};return e.patch(r,i),e.applyData(r,i)}function ME(e,r){const i={type:"element",tagName:"em",properties:{},children:e.all(r)};return e.patch(r,i),e.applyData(r,i)}function zE(e,r){const i=typeof e.options.clobberPrefix=="string"?e.options.clobberPrefix:"user-content-",l=String(r.identifier).toUpperCase(),a=bl(l.toLowerCase()),u=e.footnoteOrder.indexOf(l);let c,f=e.footnoteCounts.get(l);f===void 0?(f=0,e.footnoteOrder.push(l),c=e.footnoteOrder.length):c=u+1,f+=1,e.footnoteCounts.set(l,f);const p={type:"element",tagName:"a",properties:{href:"#"+i+"fn-"+a,id:i+"fnref-"+a+(f>1?"-"+f:""),dataFootnoteRef:!0,ariaDescribedBy:["footnote-label"]},children:[{type:"text",value:String(c)}]};e.patch(r,p);const m={type:"element",tagName:"sup",properties:{},children:[p]};return e.patch(r,m),e.applyData(r,m)}function DE(e,r){const i={type:"element",tagName:"h"+r.depth,properties:{},children:e.all(r)};return e.patch(r,i),e.applyData(r,i)}function AE(e,r){if(e.options.allowDangerousHtml){const i={type:"raw",value:r.value};return e.patch(r,i),e.applyData(r,i)}}function ey(e,r){const i=r.referenceType;let l="]";if(i==="collapsed"?l+="[]":i==="full"&&(l+="["+(r.label||r.identifier)+"]"),r.type==="imageReference")return[{type:"text",value:"!["+r.alt+l}];const a=e.all(r),u=a[0];u&&u.type==="text"?u.value="["+u.value:a.unshift({type:"text",value:"["});const c=a[a.length-1];return c&&c.type==="text"?c.value+=l:a.push({type:"text",value:l}),a}function OE(e,r){const i=String(r.identifier).toUpperCase(),l=e.definitionById.get(i);if(!l)return ey(e,r);const a={src:bl(l.url||""),alt:r.alt};l.title!==null&&l.title!==void 0&&(a.title=l.title);const u={type:"element",tagName:"img",properties:a,children:[]};return e.patch(r,u),e.applyData(r,u)}function FE(e,r){const i={src:bl(r.url)};r.alt!==null&&r.alt!==void 0&&(i.alt=r.alt),r.title!==null&&r.title!==void 0&&(i.title=r.title);const l={type:"element",tagName:"img",properties:i,children:[]};return e.patch(r,l),e.applyData(r,l)}function UE(e,r){const i={type:"text",value:r.value.replace(/\r?\n|\r/g," ")};e.patch(r,i);const l={type:"element",tagName:"code",properties:{},children:[i]};return e.patch(r,l),e.applyData(r,l)}function BE(e,r){const i=String(r.identifier).toUpperCase(),l=e.definitionById.get(i);if(!l)return ey(e,r);const a={href:bl(l.url||"")};l.title!==null&&l.title!==void 0&&(a.title=l.title);const u={type:"element",tagName:"a",properties:a,children:e.all(r)};return e.patch(r,u),e.applyData(r,u)}function HE(e,r){const i={href:bl(r.url)};r.title!==null&&r.title!==void 0&&(i.title=r.title);const l={type:"element",tagName:"a",properties:i,children:e.all(r)};return e.patch(r,l),e.applyData(r,l)}function VE(e,r,i){const l=e.all(r),a=i?$E(i):ty(r),u={},c=[];if(typeof r.checked=="boolean"){const g=l[0];let y;g&&g.type==="element"&&g.tagName==="p"?y=g:(y={type:"element",tagName:"p",properties:{},children:[]},l.unshift(y)),y.children.length>0&&y.children.unshift({type:"text",value:" "}),y.children.unshift({type:"element",tagName:"input",properties:{type:"checkbox",checked:r.checked,disabled:!0},children:[]}),u.className=["task-list-item"]}let f=-1;for(;++f<l.length;){const g=l[f];(a||f!==0||g.type!=="element"||g.tagName!=="p")&&c.push({type:"text",value:`
|
|
266
|
+
`}),g.type==="element"&&g.tagName==="p"&&!a?c.push(...g.children):c.push(g)}const p=l[l.length-1];p&&(a||p.type!=="element"||p.tagName!=="p")&&c.push({type:"text",value:`
|
|
267
|
+
`});const m={type:"element",tagName:"li",properties:u,children:c};return e.patch(r,m),e.applyData(r,m)}function $E(e){let r=!1;if(e.type==="list"){r=e.spread||!1;const i=e.children;let l=-1;for(;!r&&++l<i.length;)r=ty(i[l])}return r}function ty(e){const r=e.spread;return r??e.children.length>1}function WE(e,r){const i={},l=e.all(r);let a=-1;for(typeof r.start=="number"&&r.start!==1&&(i.start=r.start);++a<l.length;){const c=l[a];if(c.type==="element"&&c.tagName==="li"&&c.properties&&Array.isArray(c.properties.className)&&c.properties.className.includes("task-list-item")){i.className=["contains-task-list"];break}}const u={type:"element",tagName:r.ordered?"ol":"ul",properties:i,children:e.wrap(l,!0)};return e.patch(r,u),e.applyData(r,u)}function QE(e,r){const i={type:"element",tagName:"p",properties:{},children:e.all(r)};return e.patch(r,i),e.applyData(r,i)}function qE(e,r){const i={type:"root",children:e.wrap(e.all(r))};return e.patch(r,i),e.applyData(r,i)}function KE(e,r){const i={type:"element",tagName:"strong",properties:{},children:e.all(r)};return e.patch(r,i),e.applyData(r,i)}function GE(e,r){const i=e.all(r),l=i.shift(),a=[];if(l){const c={type:"element",tagName:"thead",properties:{},children:e.wrap([l],!0)};e.patch(r.children[0],c),a.push(c)}if(i.length>0){const c={type:"element",tagName:"tbody",properties:{},children:e.wrap(i,!0)},f=od(r.children[1]),p=zg(r.children[r.children.length-1]);f&&p&&(c.position={start:f,end:p}),a.push(c)}const u={type:"element",tagName:"table",properties:{},children:e.wrap(a,!0)};return e.patch(r,u),e.applyData(r,u)}function YE(e,r,i){const l=i?i.children:void 0,u=(l?l.indexOf(r):1)===0?"th":"td",c=i&&i.type==="table"?i.align:void 0,f=c?c.length:r.children.length;let p=-1;const m=[];for(;++p<f;){const y=r.children[p],k={},x=c?c[p]:void 0;x&&(k.align=x);let T={type:"element",tagName:u,properties:k,children:[]};y&&(T.children=e.all(y),e.patch(y,T),T=e.applyData(y,T)),m.push(T)}const g={type:"element",tagName:"tr",properties:{},children:e.wrap(m,!0)};return e.patch(r,g),e.applyData(r,g)}function XE(e,r){const i={type:"element",tagName:"td",properties:{},children:e.all(r)};return e.patch(r,i),e.applyData(r,i)}const om=9,am=32;function JE(e){const r=String(e),i=/\r?\n|\r/g;let l=i.exec(r),a=0;const u=[];for(;l;)u.push(sm(r.slice(a,l.index),a>0,!0),l[0]),a=l.index+l[0].length,l=i.exec(r);return u.push(sm(r.slice(a),a>0,!1)),u.join("")}function sm(e,r,i){let l=0,a=e.length;if(r){let u=e.codePointAt(l);for(;u===om||u===am;)l++,u=e.codePointAt(l)}if(i){let u=e.codePointAt(a-1);for(;u===om||u===am;)a--,u=e.codePointAt(a-1)}return a>l?e.slice(l,a):""}function ZE(e,r){const i={type:"text",value:JE(String(r.value))};return e.patch(r,i),e.applyData(r,i)}function eC(e,r){const i={type:"element",tagName:"hr",properties:{},children:[]};return e.patch(r,i),e.applyData(r,i)}const tC={blockquote:TE,break:RE,code:LE,delete:IE,emphasis:ME,footnoteReference:zE,heading:DE,html:AE,imageReference:OE,image:FE,inlineCode:UE,linkReference:BE,link:HE,listItem:VE,list:WE,paragraph:QE,root:qE,strong:KE,table:GE,tableCell:XE,tableRow:YE,text:ZE,thematicBreak:eC,toml:Ja,yaml:Ja,definition:Ja,footnoteDefinition:Ja};function Ja(){}const ny=-1,vs=0,So=1,us=2,hd=3,pd=4,md=5,gd=6,ry=7,iy=8,um=typeof self=="object"?self:globalThis,nC=(e,r)=>{const i=(a,u)=>(e.set(u,a),a),l=a=>{if(e.has(a))return e.get(a);const[u,c]=r[a];switch(u){case vs:case ny:return i(c,a);case So:{const f=i([],a);for(const p of c)f.push(l(p));return f}case us:{const f=i({},a);for(const[p,m]of c)f[l(p)]=l(m);return f}case hd:return i(new Date(c),a);case pd:{const{source:f,flags:p}=c;return i(new RegExp(f,p),a)}case md:{const f=i(new Map,a);for(const[p,m]of c)f.set(l(p),l(m));return f}case gd:{const f=i(new Set,a);for(const p of c)f.add(l(p));return f}case ry:{const{name:f,message:p}=c;return i(new um[f](p),a)}case iy:return i(BigInt(c),a);case"BigInt":return i(Object(BigInt(c)),a);case"ArrayBuffer":return i(new Uint8Array(c).buffer,c);case"DataView":{const{buffer:f}=new Uint8Array(c);return i(new DataView(f),c)}}return i(new um[u](c),a)};return l},cm=e=>nC(new Map,e)(0),ul="",{toString:rC}={},{keys:iC}=Object,vo=e=>{const r=typeof e;if(r!=="object"||!e)return[vs,r];const i=rC.call(e).slice(8,-1);switch(i){case"Array":return[So,ul];case"Object":return[us,ul];case"Date":return[hd,ul];case"RegExp":return[pd,ul];case"Map":return[md,ul];case"Set":return[gd,ul];case"DataView":return[So,i]}return i.includes("Array")?[So,i]:i.includes("Error")?[ry,i]:[us,i]},Za=([e,r])=>e===vs&&(r==="function"||r==="symbol"),lC=(e,r,i,l)=>{const a=(c,f)=>{const p=l.push(c)-1;return i.set(f,p),p},u=c=>{if(i.has(c))return i.get(c);let[f,p]=vo(c);switch(f){case vs:{let g=c;switch(p){case"bigint":f=iy,g=c.toString();break;case"function":case"symbol":if(e)throw new TypeError("unable to serialize "+p);g=null;break;case"undefined":return a([ny],c)}return a([f,g],c)}case So:{if(p){let k=c;return p==="DataView"?k=new Uint8Array(c.buffer):p==="ArrayBuffer"&&(k=new Uint8Array(c)),a([p,[...k]],c)}const g=[],y=a([f,g],c);for(const k of c)g.push(u(k));return y}case us:{if(p)switch(p){case"BigInt":return a([p,c.toString()],c);case"Boolean":case"Number":case"String":return a([p,c.valueOf()],c)}if(r&&"toJSON"in c)return u(c.toJSON());const g=[],y=a([f,g],c);for(const k of iC(c))(e||!Za(vo(c[k])))&&g.push([u(k),u(c[k])]);return y}case hd:return a([f,c.toISOString()],c);case pd:{const{source:g,flags:y}=c;return a([f,{source:g,flags:y}],c)}case md:{const g=[],y=a([f,g],c);for(const[k,x]of c)(e||!(Za(vo(k))||Za(vo(x))))&&g.push([u(k),u(x)]);return y}case gd:{const g=[],y=a([f,g],c);for(const k of c)(e||!Za(vo(k)))&&g.push(u(k));return y}}const{message:m}=c;return a([f,{name:p,message:m}],c)};return u},dm=(e,{json:r,lossy:i}={})=>{const l=[];return lC(!(r||i),!!r,new Map,l)(e),l},cs=typeof structuredClone=="function"?(e,r)=>r&&("json"in r||"lossy"in r)?cm(dm(e,r)):structuredClone(e):(e,r)=>cm(dm(e,r));function oC(e,r){const i=[{type:"text",value:"↩"}];return r>1&&i.push({type:"element",tagName:"sup",properties:{},children:[{type:"text",value:String(r)}]}),i}function aC(e,r){return"Back to reference "+(e+1)+(r>1?"-"+r:"")}function sC(e){const r=typeof e.options.clobberPrefix=="string"?e.options.clobberPrefix:"user-content-",i=e.options.footnoteBackContent||oC,l=e.options.footnoteBackLabel||aC,a=e.options.footnoteLabel||"Footnotes",u=e.options.footnoteLabelTagName||"h2",c=e.options.footnoteLabelProperties||{className:["sr-only"]},f=[];let p=-1;for(;++p<e.footnoteOrder.length;){const m=e.footnoteById.get(e.footnoteOrder[p]);if(!m)continue;const g=e.all(m),y=String(m.identifier).toUpperCase(),k=bl(y.toLowerCase());let x=0;const T=[],N=e.footnoteCounts.get(y);for(;N!==void 0&&++x<=N;){T.length>0&&T.push({type:"text",value:" "});let z=typeof i=="string"?i:i(p,x);typeof z=="string"&&(z={type:"text",value:z}),T.push({type:"element",tagName:"a",properties:{href:"#"+r+"fnref-"+k+(x>1?"-"+x:""),dataFootnoteBackref:"",ariaLabel:typeof l=="string"?l:l(p,x),className:["data-footnote-backref"]},children:Array.isArray(z)?z:[z]})}const b=g[g.length-1];if(b&&b.type==="element"&&b.tagName==="p"){const z=b.children[b.children.length-1];z&&z.type==="text"?z.value+=" ":b.children.push({type:"text",value:" "}),b.children.push(...T)}else g.push(...T);const P={type:"element",tagName:"li",properties:{id:r+"fn-"+k},children:e.wrap(g,!0)};e.patch(m,P),f.push(P)}if(f.length!==0)return{type:"element",tagName:"section",properties:{dataFootnotes:!0,className:["footnotes"]},children:[{type:"element",tagName:u,properties:{...cs(c),id:"footnote-label"},children:[{type:"text",value:a}]},{type:"text",value:`
|
|
268
|
+
`},{type:"element",tagName:"ol",properties:{},children:e.wrap(f,!0)},{type:"text",value:`
|
|
269
|
+
`}]}}const ly=function(e){if(e==null)return fC;if(typeof e=="function")return xs(e);if(typeof e=="object")return Array.isArray(e)?uC(e):cC(e);if(typeof e=="string")return dC(e);throw new Error("Expected function, string, or object as test")};function uC(e){const r=[];let i=-1;for(;++i<e.length;)r[i]=ly(e[i]);return xs(l);function l(...a){let u=-1;for(;++u<r.length;)if(r[u].apply(this,a))return!0;return!1}}function cC(e){const r=e;return xs(i);function i(l){const a=l;let u;for(u in e)if(a[u]!==r[u])return!1;return!0}}function dC(e){return xs(r);function r(i){return i&&i.type===e}}function xs(e){return r;function r(i,l,a){return!!(hC(i)&&e.call(this,i,typeof l=="number"?l:void 0,a||void 0))}}function fC(){return!0}function hC(e){return e!==null&&typeof e=="object"&&"type"in e}const oy=[],pC=!0,fm=!1,mC="skip";function gC(e,r,i,l){let a;typeof r=="function"&&typeof i!="function"?(l=i,i=r):a=r;const u=ly(a),c=l?-1:1;f(e,void 0,[])();function f(p,m,g){const y=p&&typeof p=="object"?p:{};if(typeof y.type=="string"){const x=typeof y.tagName=="string"?y.tagName:typeof y.name=="string"?y.name:void 0;Object.defineProperty(k,"name",{value:"node ("+(p.type+(x?"<"+x+">":""))+")"})}return k;function k(){let x=oy,T,N,b;if((!r||u(p,m,g[g.length-1]||void 0))&&(x=yC(i(p,g)),x[0]===fm))return x;if("children"in p&&p.children){const P=p;if(P.children&&x[0]!==mC)for(N=(l?P.children.length:-1)+c,b=g.concat(P);N>-1&&N<P.children.length;){const z=P.children[N];if(T=f(z,N,b)(),T[0]===fm)return T;N=typeof T[1]=="number"?T[1]:N+c}}return x}}}function yC(e){return Array.isArray(e)?e:typeof e=="number"?[pC,e]:e==null?oy:[e]}function ay(e,r,i,l){let a,u,c;typeof r=="function"&&typeof i!="function"?(u=void 0,c=r,a=i):(u=r,c=i,a=l),gC(e,u,f,a);function f(p,m){const g=m[m.length-1],y=g?g.children.indexOf(p):void 0;return c(p,y,g)}}const Hc={}.hasOwnProperty,vC={};function xC(e,r){const i=r||vC,l=new Map,a=new Map,u=new Map,c={...tC,...i.handlers},f={all:m,applyData:kC,definitionById:l,footnoteById:a,footnoteCounts:u,footnoteOrder:[],handlers:c,one:p,options:i,patch:wC,wrap:EC};return ay(e,function(g){if(g.type==="definition"||g.type==="footnoteDefinition"){const y=g.type==="definition"?l:a,k=String(g.identifier).toUpperCase();y.has(k)||y.set(k,g)}}),f;function p(g,y){const k=g.type,x=f.handlers[k];if(Hc.call(f.handlers,k)&&x)return x(f,g,y);if(f.options.passThrough&&f.options.passThrough.includes(k)){if("children"in g){const{children:N,...b}=g,P=cs(b);return P.children=f.all(g),P}return cs(g)}return(f.options.unknownHandler||SC)(f,g,y)}function m(g){const y=[];if("children"in g){const k=g.children;let x=-1;for(;++x<k.length;){const T=f.one(k[x],g);if(T){if(x&&k[x-1].type==="break"&&(!Array.isArray(T)&&T.type==="text"&&(T.value=hm(T.value)),!Array.isArray(T)&&T.type==="element")){const N=T.children[0];N&&N.type==="text"&&(N.value=hm(N.value))}Array.isArray(T)?y.push(...T):y.push(T)}}}return y}}function wC(e,r){e.position&&(r.position=rk(e))}function kC(e,r){let i=r;if(e&&e.data){const l=e.data.hName,a=e.data.hChildren,u=e.data.hProperties;if(typeof l=="string")if(i.type==="element")i.tagName=l;else{const c="children"in i?i.children:[i];i={type:"element",tagName:l,properties:{},children:c}}i.type==="element"&&u&&Object.assign(i.properties,cs(u)),"children"in i&&i.children&&a!==null&&a!==void 0&&(i.children=a)}return i}function SC(e,r){const i=r.data||{},l="value"in r&&!(Hc.call(i,"hProperties")||Hc.call(i,"hChildren"))?{type:"text",value:r.value}:{type:"element",tagName:"div",properties:{},children:e.all(r)};return e.patch(r,l),e.applyData(r,l)}function EC(e,r){const i=[];let l=-1;for(r&&i.push({type:"text",value:`
|
|
270
|
+
`});++l<e.length;)l&&i.push({type:"text",value:`
|
|
271
|
+
`}),i.push(e[l]);return r&&e.length>0&&i.push({type:"text",value:`
|
|
272
|
+
`}),i}function hm(e){let r=0,i=e.charCodeAt(r);for(;i===9||i===32;)r++,i=e.charCodeAt(r);return e.slice(r)}function pm(e,r){const i=xC(e,r),l=i.one(e,void 0),a=sC(i),u=Array.isArray(l)?{type:"root",children:l}:l||{type:"root",children:[]};return a&&u.children.push({type:"text",value:`
|
|
273
|
+
`},a),u}function CC(e,r){return e&&"run"in e?async function(i,l){const a=pm(i,{file:l,...r});await e.run(a,l)}:function(i,l){return pm(i,{file:l,...e||r})}}function mm(e){if(e)throw e}var yc,gm;function bC(){if(gm)return yc;gm=1;var e=Object.prototype.hasOwnProperty,r=Object.prototype.toString,i=Object.defineProperty,l=Object.getOwnPropertyDescriptor,a=function(m){return typeof Array.isArray=="function"?Array.isArray(m):r.call(m)==="[object Array]"},u=function(m){if(!m||r.call(m)!=="[object Object]")return!1;var g=e.call(m,"constructor"),y=m.constructor&&m.constructor.prototype&&e.call(m.constructor.prototype,"isPrototypeOf");if(m.constructor&&!g&&!y)return!1;var k;for(k in m);return typeof k>"u"||e.call(m,k)},c=function(m,g){i&&g.name==="__proto__"?i(m,g.name,{enumerable:!0,configurable:!0,value:g.newValue,writable:!0}):m[g.name]=g.newValue},f=function(m,g){if(g==="__proto__")if(e.call(m,g)){if(l)return l(m,g).value}else return;return m[g]};return yc=function p(){var m,g,y,k,x,T,N=arguments[0],b=1,P=arguments.length,z=!1;for(typeof N=="boolean"&&(z=N,N=arguments[1]||{},b=2),(N==null||typeof N!="object"&&typeof N!="function")&&(N={});b<P;++b)if(m=arguments[b],m!=null)for(g in m)y=f(N,g),k=f(m,g),N!==k&&(z&&k&&(u(k)||(x=a(k)))?(x?(x=!1,T=y&&a(y)?y:[]):T=y&&u(y)?y:{},c(N,{name:g,newValue:p(z,T,k)})):typeof k<"u"&&c(N,{name:g,newValue:k}));return N},yc}var NC=bC();const vc=ds(NC);function Vc(e){if(typeof e!="object"||e===null)return!1;const r=Object.getPrototypeOf(e);return(r===null||r===Object.prototype||Object.getPrototypeOf(r)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)}function PC(){const e=[],r={run:i,use:l};return r;function i(...a){let u=-1;const c=a.pop();if(typeof c!="function")throw new TypeError("Expected function as last argument, not "+c);f(null,...a);function f(p,...m){const g=e[++u];let y=-1;if(p){c(p);return}for(;++y<a.length;)(m[y]===null||m[y]===void 0)&&(m[y]=a[y]);a=m,g?jC(g,f)(...m):c(null,...m)}}function l(a){if(typeof a!="function")throw new TypeError("Expected `middelware` to be a function, not "+a);return e.push(a),r}}function jC(e,r){let i;return l;function l(...c){const f=e.length>c.length;let p;f&&c.push(a);try{p=e.apply(this,c)}catch(m){const g=m;if(f&&i)throw g;return a(g)}f||(p&&p.then&&typeof p.then=="function"?p.then(u,a):p instanceof Error?a(p):u(p))}function a(c,...f){i||(i=!0,r(c,...f))}function u(c){a(null,c)}}const Kn={basename:_C,dirname:TC,extname:RC,join:LC,sep:"/"};function _C(e,r){if(r!==void 0&&typeof r!="string")throw new TypeError('"ext" argument must be a string');Do(e);let i=0,l=-1,a=e.length,u;if(r===void 0||r.length===0||r.length>e.length){for(;a--;)if(e.codePointAt(a)===47){if(u){i=a+1;break}}else l<0&&(u=!0,l=a+1);return l<0?"":e.slice(i,l)}if(r===e)return"";let c=-1,f=r.length-1;for(;a--;)if(e.codePointAt(a)===47){if(u){i=a+1;break}}else c<0&&(u=!0,c=a+1),f>-1&&(e.codePointAt(a)===r.codePointAt(f--)?f<0&&(l=a):(f=-1,l=c));return i===l?l=c:l<0&&(l=e.length),e.slice(i,l)}function TC(e){if(Do(e),e.length===0)return".";let r=-1,i=e.length,l;for(;--i;)if(e.codePointAt(i)===47){if(l){r=i;break}}else l||(l=!0);return r<0?e.codePointAt(0)===47?"/":".":r===1&&e.codePointAt(0)===47?"//":e.slice(0,r)}function RC(e){Do(e);let r=e.length,i=-1,l=0,a=-1,u=0,c;for(;r--;){const f=e.codePointAt(r);if(f===47){if(c){l=r+1;break}continue}i<0&&(c=!0,i=r+1),f===46?a<0?a=r:u!==1&&(u=1):a>-1&&(u=-1)}return a<0||i<0||u===0||u===1&&a===i-1&&a===l+1?"":e.slice(a,i)}function LC(...e){let r=-1,i;for(;++r<e.length;)Do(e[r]),e[r]&&(i=i===void 0?e[r]:i+"/"+e[r]);return i===void 0?".":IC(i)}function IC(e){Do(e);const r=e.codePointAt(0)===47;let i=MC(e,!r);return i.length===0&&!r&&(i="."),i.length>0&&e.codePointAt(e.length-1)===47&&(i+="/"),r?"/"+i:i}function MC(e,r){let i="",l=0,a=-1,u=0,c=-1,f,p;for(;++c<=e.length;){if(c<e.length)f=e.codePointAt(c);else{if(f===47)break;f=47}if(f===47){if(!(a===c-1||u===1))if(a!==c-1&&u===2){if(i.length<2||l!==2||i.codePointAt(i.length-1)!==46||i.codePointAt(i.length-2)!==46){if(i.length>2){if(p=i.lastIndexOf("/"),p!==i.length-1){p<0?(i="",l=0):(i=i.slice(0,p),l=i.length-1-i.lastIndexOf("/")),a=c,u=0;continue}}else if(i.length>0){i="",l=0,a=c,u=0;continue}}r&&(i=i.length>0?i+"/..":"..",l=2)}else i.length>0?i+="/"+e.slice(a+1,c):i=e.slice(a+1,c),l=c-a-1;a=c,u=0}else f===46&&u>-1?u++:u=-1}return i}function Do(e){if(typeof e!="string")throw new TypeError("Path must be a string. Received "+JSON.stringify(e))}const zC={cwd:DC};function DC(){return"/"}function $c(e){return!!(e!==null&&typeof e=="object"&&"href"in e&&e.href&&"protocol"in e&&e.protocol&&e.auth===void 0)}function AC(e){if(typeof e=="string")e=new URL(e);else if(!$c(e)){const r=new TypeError('The "path" argument must be of type string or an instance of URL. Received `'+e+"`");throw r.code="ERR_INVALID_ARG_TYPE",r}if(e.protocol!=="file:"){const r=new TypeError("The URL must be of scheme file");throw r.code="ERR_INVALID_URL_SCHEME",r}return OC(e)}function OC(e){if(e.hostname!==""){const l=new TypeError('File URL host must be "localhost" or empty on darwin');throw l.code="ERR_INVALID_FILE_URL_HOST",l}const r=e.pathname;let i=-1;for(;++i<r.length;)if(r.codePointAt(i)===37&&r.codePointAt(i+1)===50){const l=r.codePointAt(i+2);if(l===70||l===102){const a=new TypeError("File URL path must not include encoded / characters");throw a.code="ERR_INVALID_FILE_URL_PATH",a}}return decodeURIComponent(r)}const xc=["history","path","basename","stem","extname","dirname"];class sy{constructor(r){let i;r?$c(r)?i={path:r}:typeof r=="string"||FC(r)?i={value:r}:i=r:i={},this.cwd="cwd"in i?"":zC.cwd(),this.data={},this.history=[],this.messages=[],this.value,this.map,this.result,this.stored;let l=-1;for(;++l<xc.length;){const u=xc[l];u in i&&i[u]!==void 0&&i[u]!==null&&(this[u]=u==="history"?[...i[u]]:i[u])}let a;for(a in i)xc.includes(a)||(this[a]=i[a])}get basename(){return typeof this.path=="string"?Kn.basename(this.path):void 0}set basename(r){kc(r,"basename"),wc(r,"basename"),this.path=Kn.join(this.dirname||"",r)}get dirname(){return typeof this.path=="string"?Kn.dirname(this.path):void 0}set dirname(r){ym(this.basename,"dirname"),this.path=Kn.join(r||"",this.basename)}get extname(){return typeof this.path=="string"?Kn.extname(this.path):void 0}set extname(r){if(wc(r,"extname"),ym(this.dirname,"extname"),r){if(r.codePointAt(0)!==46)throw new Error("`extname` must start with `.`");if(r.includes(".",1))throw new Error("`extname` cannot contain multiple dots")}this.path=Kn.join(this.dirname,this.stem+(r||""))}get path(){return this.history[this.history.length-1]}set path(r){$c(r)&&(r=AC(r)),kc(r,"path"),this.path!==r&&this.history.push(r)}get stem(){return typeof this.path=="string"?Kn.basename(this.path,this.extname):void 0}set stem(r){kc(r,"stem"),wc(r,"stem"),this.path=Kn.join(this.dirname||"",r+(this.extname||""))}fail(r,i,l){const a=this.message(r,i,l);throw a.fatal=!0,a}info(r,i,l){const a=this.message(r,i,l);return a.fatal=void 0,a}message(r,i,l){const a=new Vt(r,i,l);return this.path&&(a.name=this.path+":"+a.name,a.file=this.path),a.fatal=!1,this.messages.push(a),a}toString(r){return this.value===void 0?"":typeof this.value=="string"?this.value:new TextDecoder(r||void 0).decode(this.value)}}function wc(e,r){if(e&&e.includes(Kn.sep))throw new Error("`"+r+"` cannot be a path: did not expect `"+Kn.sep+"`")}function kc(e,r){if(!e)throw new Error("`"+r+"` cannot be empty")}function ym(e,r){if(!e)throw new Error("Setting `"+r+"` requires `path` to be set too")}function FC(e){return!!(e&&typeof e=="object"&&"byteLength"in e&&"byteOffset"in e)}const UC=function(e){const l=this.constructor.prototype,a=l[e],u=function(){return a.apply(u,arguments)};return Object.setPrototypeOf(u,l),u},BC={}.hasOwnProperty;class yd extends UC{constructor(){super("copy"),this.Compiler=void 0,this.Parser=void 0,this.attachers=[],this.compiler=void 0,this.freezeIndex=-1,this.frozen=void 0,this.namespace={},this.parser=void 0,this.transformers=PC()}copy(){const r=new yd;let i=-1;for(;++i<this.attachers.length;){const l=this.attachers[i];r.use(...l)}return r.data(vc(!0,{},this.namespace)),r}data(r,i){return typeof r=="string"?arguments.length===2?(Cc("data",this.frozen),this.namespace[r]=i,this):BC.call(this.namespace,r)&&this.namespace[r]||void 0:r?(Cc("data",this.frozen),this.namespace=r,this):this.namespace}freeze(){if(this.frozen)return this;const r=this;for(;++this.freezeIndex<this.attachers.length;){const[i,...l]=this.attachers[this.freezeIndex];if(l[0]===!1)continue;l[0]===!0&&(l[0]=void 0);const a=i.call(r,...l);typeof a=="function"&&this.transformers.use(a)}return this.frozen=!0,this.freezeIndex=Number.POSITIVE_INFINITY,this}parse(r){this.freeze();const i=es(r),l=this.parser||this.Parser;return Sc("parse",l),l(String(i),i)}process(r,i){const l=this;return this.freeze(),Sc("process",this.parser||this.Parser),Ec("process",this.compiler||this.Compiler),i?a(void 0,i):new Promise(a);function a(u,c){const f=es(r),p=l.parse(f);l.run(p,f,function(g,y,k){if(g||!y||!k)return m(g);const x=y,T=l.stringify(x,k);$C(T)?k.value=T:k.result=T,m(g,k)});function m(g,y){g||!y?c(g):u?u(y):i(void 0,y)}}}processSync(r){let i=!1,l;return this.freeze(),Sc("processSync",this.parser||this.Parser),Ec("processSync",this.compiler||this.Compiler),this.process(r,a),xm("processSync","process",i),l;function a(u,c){i=!0,mm(u),l=c}}run(r,i,l){vm(r),this.freeze();const a=this.transformers;return!l&&typeof i=="function"&&(l=i,i=void 0),l?u(void 0,l):new Promise(u);function u(c,f){const p=es(i);a.run(r,p,m);function m(g,y,k){const x=y||r;g?f(g):c?c(x):l(void 0,x,k)}}}runSync(r,i){let l=!1,a;return this.run(r,i,u),xm("runSync","run",l),a;function u(c,f){mm(c),a=f,l=!0}}stringify(r,i){this.freeze();const l=es(i),a=this.compiler||this.Compiler;return Ec("stringify",a),vm(r),a(r,l)}use(r,...i){const l=this.attachers,a=this.namespace;if(Cc("use",this.frozen),r!=null)if(typeof r=="function")p(r,i);else if(typeof r=="object")Array.isArray(r)?f(r):c(r);else throw new TypeError("Expected usable value, not `"+r+"`");return this;function u(m){if(typeof m=="function")p(m,[]);else if(typeof m=="object")if(Array.isArray(m)){const[g,...y]=m;p(g,y)}else c(m);else throw new TypeError("Expected usable value, not `"+m+"`")}function c(m){if(!("plugins"in m)&&!("settings"in m))throw new Error("Expected usable value but received an empty preset, which is probably a mistake: presets typically come with `plugins` and sometimes with `settings`, but this has neither");f(m.plugins),m.settings&&(a.settings=vc(!0,a.settings,m.settings))}function f(m){let g=-1;if(m!=null)if(Array.isArray(m))for(;++g<m.length;){const y=m[g];u(y)}else throw new TypeError("Expected a list of plugins, not `"+m+"`")}function p(m,g){let y=-1,k=-1;for(;++y<l.length;)if(l[y][0]===m){k=y;break}if(k===-1)l.push([m,...g]);else if(g.length>0){let[x,...T]=g;const N=l[k][1];Vc(N)&&Vc(x)&&(x=vc(!0,N,x)),l[k]=[m,x,...T]}}}}const HC=new yd().freeze();function Sc(e,r){if(typeof r!="function")throw new TypeError("Cannot `"+e+"` without `parser`")}function Ec(e,r){if(typeof r!="function")throw new TypeError("Cannot `"+e+"` without `compiler`")}function Cc(e,r){if(r)throw new Error("Cannot call `"+e+"` on a frozen processor.\nCreate a new processor first, by calling it: use `processor()` instead of `processor`.")}function vm(e){if(!Vc(e)||typeof e.type!="string")throw new TypeError("Expected node, got `"+e+"`")}function xm(e,r,i){if(!i)throw new Error("`"+e+"` finished async. Use `"+r+"` instead")}function es(e){return VC(e)?e:new sy(e)}function VC(e){return!!(e&&typeof e=="object"&&"message"in e&&"messages"in e)}function $C(e){return typeof e=="string"||WC(e)}function WC(e){return!!(e&&typeof e=="object"&&"byteLength"in e&&"byteOffset"in e)}const QC="https://github.com/remarkjs/react-markdown/blob/main/changelog.md",wm=[],km={allowDangerousHtml:!0},qC=/^(https?|ircs?|mailto|xmpp)$/i,KC=[{from:"astPlugins",id:"remove-buggy-html-in-markdown-parser"},{from:"allowDangerousHtml",id:"remove-buggy-html-in-markdown-parser"},{from:"allowNode",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"allowElement"},{from:"allowedTypes",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"allowedElements"},{from:"className",id:"remove-classname"},{from:"disallowedTypes",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"disallowedElements"},{from:"escapeHtml",id:"remove-buggy-html-in-markdown-parser"},{from:"includeElementIndex",id:"#remove-includeelementindex"},{from:"includeNodeIndex",id:"change-includenodeindex-to-includeelementindex"},{from:"linkTarget",id:"remove-linktarget"},{from:"plugins",id:"change-plugins-to-remarkplugins",to:"remarkPlugins"},{from:"rawSourcePos",id:"#remove-rawsourcepos"},{from:"renderers",id:"change-renderers-to-components",to:"components"},{from:"source",id:"change-source-to-children",to:"children"},{from:"sourcePos",id:"#remove-sourcepos"},{from:"transformImageUri",id:"#add-urltransform",to:"urlTransform"},{from:"transformLinkUri",id:"#add-urltransform",to:"urlTransform"}];function vd(e){const r=GC(e),i=YC(e);return XC(r.runSync(r.parse(i),i),e)}function GC(e){const r=e.rehypePlugins||wm,i=e.remarkPlugins||wm,l=e.remarkRehypeOptions?{...e.remarkRehypeOptions,...km}:km;return HC().use(_E).use(i).use(CC,l).use(r)}function YC(e){const r=e.children||"",i=new sy;return typeof r=="string"&&(i.value=r),i}function XC(e,r){const i=r.allowedElements,l=r.allowElement,a=r.components,u=r.disallowedElements,c=r.skipHtml,f=r.unwrapDisallowed,p=r.urlTransform||JC;for(const g of KC)Object.hasOwn(r,g.from)&&(""+g.from+(g.to?"use `"+g.to+"` instead":"remove it")+QC+g.id,void 0);return ay(e,m),sk(e,{Fragment:v.Fragment,components:a,ignoreInvalidStyle:!0,jsx:v.jsx,jsxs:v.jsxs,passKeys:!0,passNode:!0});function m(g,y,k){if(g.type==="raw"&&k&&typeof y=="number")return c?k.children.splice(y,1):k.children[y]={type:"text",value:g.value},y;if(g.type==="element"){let x;for(x in pc)if(Object.hasOwn(pc,x)&&Object.hasOwn(g.properties,x)){const T=g.properties[x],N=pc[x];(N===null||N.includes(g.tagName))&&(g.properties[x]=p(String(T||""),x,g))}}if(g.type==="element"){let x=i?!i.includes(g.tagName):u?u.includes(g.tagName):!1;if(!x&&l&&typeof y=="number"&&(x=!l(g,y,k)),x&&k&&typeof y=="number")return f&&g.children?k.children.splice(y,1,...g.children):k.children.splice(y,1),y}}}function JC(e){const r=e.indexOf(":"),i=e.indexOf("?"),l=e.indexOf("#"),a=e.indexOf("/");return r===-1||a!==-1&&r>a||i!==-1&&r>i||l!==-1&&r>l||qC.test(e.slice(0,r))?e:""}function ZC({call:e}){const r=e.status==="running",i=e.status==="error";return v.jsxs("div",{className:"flex items-center gap-2 px-3 py-2 my-1.5 rounded-lg bg-gray-100 dark:bg-zinc-800/50 border border-gray-200 dark:border-zinc-700/50 text-xs font-mono",children:[r?v.jsx(xg,{className:"h-3.5 w-3.5 text-indigo-400 animate-spin shrink-0"}):i?v.jsx(Aw,{className:"h-3.5 w-3.5 text-red-400 shrink-0"}):v.jsx(Dw,{className:"h-3.5 w-3.5 text-emerald-400 shrink-0"}),v.jsx("span",{className:"text-indigo-600 dark:text-indigo-300 font-semibold",children:e.toolName}),e.duration_ms!=null&&v.jsxs("span",{className:"text-zinc-500 ml-auto",children:[String(e.duration_ms),"ms"]})]})}function eb({confirmation:e,onApprove:r,onDeny:i}){const l=e.status==="approved"||e.status==="denied";return v.jsxs("div",{className:"my-2 p-3 rounded-lg border border-amber-500/30 bg-amber-500/5",children:[v.jsxs("div",{className:"flex items-center gap-2 text-sm font-medium text-amber-300 mb-1",children:[v.jsx(Qw,{className:"h-4 w-4"}),v.jsx("span",{className:"uppercase text-[11px] font-bold bg-indigo-500 text-white px-1.5 py-0.5 rounded",children:e.method}),v.jsx("span",{className:"text-zinc-300",children:e.endpoint})]}),e.reason&&v.jsx("p",{className:"text-xs text-zinc-400 mb-2",children:e.reason}),l?v.jsx("span",{className:`text-xs font-semibold ${e.status==="approved"?"text-emerald-400":"text-red-400"}`,children:e.status==="approved"?"Approved":"Denied"}):v.jsxs("div",{className:"flex gap-2",children:[v.jsx("button",{onClick:r,className:"px-3 py-1.5 text-xs font-medium rounded-md bg-emerald-600 text-white hover:bg-emerald-500 transition-colors",children:"Approve"}),v.jsx("button",{onClick:i,className:"px-3 py-1.5 text-xs font-medium rounded-md bg-zinc-700 text-zinc-300 border border-zinc-600 hover:bg-zinc-600 transition-colors",children:"Deny"})]})]})}function tb({blocks:e,respondToConfirmation:r}){return v.jsx(v.Fragment,{children:e.map((i,l)=>{switch(i.type){case"text":return v.jsx("div",{className:"prose dark:prose-invert prose-sm max-w-none prose-headings:text-gray-900 dark:prose-headings:text-zinc-200 prose-p:text-gray-900 dark:prose-p:text-zinc-300 prose-strong:text-gray-900 dark:prose-strong:text-zinc-200 prose-code:text-indigo-700 dark:prose-code:text-indigo-300 prose-code:bg-gray-100 dark:prose-code:bg-zinc-800 prose-code:px-1 prose-code:py-0.5 prose-code:rounded prose-pre:bg-gray-100 dark:prose-pre:bg-zinc-800/80 prose-pre:border prose-pre:border-gray-200 dark:prose-pre:border-zinc-700/50 prose-a:text-indigo-700 dark:prose-a:text-indigo-400 prose-li:text-gray-900 dark:prose-li:text-zinc-300",children:v.jsx(vd,{children:i.text})},`t-${String(l)}`);case"tool_calls":return v.jsx("div",{children:i.calls.map(a=>v.jsx(ZC,{call:a},a.toolId))},`tc-${String(l)}`);case"confirmation":{const a=i.confirmation;return v.jsx(eb,{confirmation:a,onApprove:()=>{a.correlationId&&r(a.correlationId,!0)},onDeny:()=>{a.correlationId&&r(a.correlationId,!1)}},`cf-${String(l)}`)}default:return null}})})}function nb(){const{resumeSessionId:e}=Mo(),[r]=Bx(),i=r.get("resume"),l=M.useMemo(()=>i??e,[i,e]),{messages:a,send:u,isStreaming:c,activeToolCalls:f,respondToConfirmation:p,usage:m}=fg({initialSessionId:l}),[g,y]=M.useState(""),[k,x]=M.useState([]),T=M.useRef(null),N=M.useRef(null);M.useEffect(()=>{if(!l){x([]);return}fetch(`/session/${encodeURIComponent(l)}`).then(I=>I.ok?I.json():null).then(I=>{if(I&&typeof I=="object"&&"messages"in I&&Array.isArray(I.messages)){const F=I.messages;x(F.filter(ee=>ee.role==="user"||ee.role==="assistant"))}}).catch(()=>{})},[l]),M.useEffect(()=>{var I;(I=T.current)==null||I.scrollIntoView({behavior:"smooth"})},[a,k]),M.useEffect(()=>{var I;c||(I=N.current)==null||I.focus()},[c]);const b=M.useCallback(I=>{I.preventDefault();const F=g.trim();!F||c||(y(""),N.current&&(N.current.style.height="auto"),u(F))},[g,c,u]),P=M.useCallback(I=>{if(I.key==="Enter"&&!I.shiftKey){I.preventDefault();const F=g.trim();F&&!c&&(y(""),N.current&&(N.current.style.height="auto"),u(F))}},[g,c,u]),z=a.length>0||k.length>0;return v.jsxs("div",{className:"h-full flex flex-col bg-white dark:bg-[#0a0a0f]",children:[v.jsx("div",{className:"flex-1 overflow-y-auto scrollbar-thin",children:z?v.jsxs("div",{className:"max-w-3xl mx-auto px-4 py-6",children:[k.map((I,F)=>v.jsx("div",{className:I.role==="user"?"mb-6 flex justify-end":"mb-6",children:I.role==="user"?v.jsx("div",{className:"max-w-[85%] px-4 py-3 rounded-2xl rounded-br-md bg-indigo-600/60 text-white/80 text-[14px] leading-relaxed",children:I.text}):v.jsx("div",{className:"text-[14px] text-gray-400 dark:text-zinc-400 prose dark:prose-invert prose-sm max-w-none prose-headings:text-gray-400 dark:prose-headings:text-zinc-400 prose-p:text-gray-400 dark:prose-p:text-zinc-400 prose-code:bg-gray-100 dark:prose-code:bg-zinc-800 prose-code:px-1 prose-code:py-0.5 prose-code:rounded prose-a:text-indigo-500/60 dark:prose-a:text-indigo-400/60",children:v.jsx(vd,{children:I.text})})},`hist-${String(F)}`)),k.length>0&&a.length===0&&v.jsx("div",{className:"text-center text-xs text-gray-400 dark:text-zinc-600 mb-4 py-2 border-t border-gray-200 dark:border-zinc-800/50",children:"Session resumed"}),a.map(I=>{switch(I.type){case"user":return v.jsx("div",{className:"mb-6 flex justify-end",children:v.jsx("div",{className:"max-w-[85%] px-4 py-3 rounded-2xl rounded-br-md bg-indigo-600 text-white text-[14px] leading-relaxed",children:I.text})},I.id);case"assistant_text":return v.jsx("div",{className:"mb-6",children:v.jsx("div",{className:"text-[14px] text-gray-900 dark:text-zinc-200",children:v.jsx(tb,{blocks:I.contentBlocks,respondToConfirmation:p})})},I.id);case"error":return v.jsx("div",{className:"mb-6 px-4 py-3 rounded-xl bg-red-500/10 border border-red-500/20 text-red-300 text-sm",children:I.message},I.id);default:return null}}),c&&f.length===0&&v.jsxs("div",{className:"flex items-center gap-2 text-zinc-500 text-sm mb-4",children:[v.jsx(xg,{className:"h-4 w-4 animate-spin"}),v.jsx("span",{children:"Thinking..."})]}),v.jsx("div",{ref:T})]}):v.jsxs("div",{className:"h-full flex flex-col items-center justify-center text-center px-4",children:[v.jsxs("svg",{width:"48",height:"48",viewBox:"0 0 32 32",fill:"none",className:"mb-5 opacity-30",children:[v.jsx("defs",{children:v.jsx("clipPath",{id:"empty-sq",children:v.jsx("rect",{x:"2",y:"10",width:"17",height:"17",rx:"3"})})}),v.jsx("rect",{x:"2",y:"10",width:"17",height:"17",rx:"3",fill:"#1E40AF"}),v.jsx("circle",{cx:"22",cy:"11",r:"10",fill:"#60A5FA",fillOpacity:"0.85"}),v.jsx("circle",{cx:"22",cy:"11",r:"10",fill:"#3B82F6",clipPath:"url(#empty-sq)"})]}),v.jsx("h2",{className:"text-lg font-medium text-gray-400 dark:text-zinc-400 mb-1",children:"What can I help with?"}),v.jsx("p",{className:"text-sm text-gray-400 dark:text-zinc-600 max-w-sm",children:"Ask me anything. I can search, analyze, and connect to your tools."})]})}),v.jsxs("div",{className:"border-t border-gray-200 dark:border-zinc-800/80 bg-gray-50 dark:bg-[#0f0f17] px-4 py-4",children:[v.jsxs("form",{onSubmit:b,className:"max-w-3xl mx-auto relative",children:[v.jsx("textarea",{ref:N,value:g,onChange:I=>{y(I.target.value);const F=I.target;F.style.height="auto",F.style.height=`${Math.min(F.scrollHeight,160)}px`},onKeyDown:P,placeholder:"Message...",disabled:c,rows:1,className:"w-full resize-none rounded-xl bg-white dark:bg-zinc-800/80 border border-gray-300 dark:border-zinc-700/60 px-4 py-3 pr-12 text-[14px] text-gray-900 dark:text-zinc-100 placeholder-gray-400 dark:placeholder-zinc-500 outline-none focus:border-indigo-500/60 focus:ring-1 focus:ring-indigo-500/20 transition-colors disabled:opacity-50 overflow-y-auto",style:{minHeight:"48px",maxHeight:"160px"}}),v.jsx("button",{type:"submit",disabled:c||g.trim().length===0,className:"absolute right-2 bottom-2 h-8 w-8 rounded-lg bg-indigo-600 text-white flex items-center justify-center hover:bg-indigo-500 transition-colors disabled:opacity-20 disabled:hover:bg-indigo-600",children:v.jsx(Hw,{className:"h-4 w-4"})})]}),(m.inputTokens>0||m.outputTokens>0)&&v.jsxs("div",{className:"max-w-3xl mx-auto mt-1.5 text-[11px] text-gray-400 dark:text-zinc-600 font-mono text-right",children:[(m.inputTokens+m.outputTokens).toLocaleString()," tokens (",m.inputTokens.toLocaleString()," in / ",m.outputTokens.toLocaleString()," out)"]})]})]})}function rb(e){const r=Date.now()-e,i=Math.floor(r/6e4);if(i<1)return"just now";if(i<60)return`${String(i)}m ago`;const l=Math.floor(i/60);if(l<24)return`${String(l)}h ago`;const a=Math.floor(l/24);return`${String(a)}d ago`}function ib(e){return new Date(e).toLocaleString(void 0,{month:"short",day:"numeric",hour:"numeric",minute:"2-digit"})}function lb(){const[e,r]=M.useState([]),[i,l]=M.useState(!0);return M.useEffect(()=>{fetch("/sessions").then(a=>a.ok?a.json():{sessions:[]}).then(a=>{a&&typeof a=="object"&&"sessions"in a&&Array.isArray(a.sessions)&&r(a.sessions)}).catch(()=>{}).finally(()=>l(!1))},[]),v.jsxs("div",{className:"h-full flex flex-col bg-[#0a0a0f]",children:[v.jsxs("div",{className:"border-b border-zinc-800/50 px-6 py-4",children:[v.jsx("h1",{className:"text-lg font-semibold text-zinc-200",children:"Sessions"}),v.jsxs("p",{className:"text-sm text-zinc-500 mt-0.5",children:[e.length," conversation",e.length!==1?"s":""]})]}),v.jsx("div",{className:"flex-1 overflow-y-auto scrollbar-thin",children:i?v.jsx("div",{className:"flex items-center justify-center h-32 text-zinc-500 text-sm",children:"Loading..."}):e.length===0?v.jsxs("div",{className:"flex flex-col items-center justify-center h-64 text-center px-4",children:[v.jsx(ss,{className:"h-8 w-8 text-zinc-700 mb-3"}),v.jsx("p",{className:"text-sm text-zinc-500",children:"No sessions yet. Start a conversation from the Chat page."})]}):v.jsx("div",{className:"divide-y divide-zinc-800/50",children:e.map(a=>v.jsxs(ps,{to:`/sessions/${a.id}`,className:"flex items-center gap-4 px-6 py-4 hover:bg-white/[0.02] transition-colors group",children:[v.jsx("div",{className:"h-9 w-9 rounded-lg bg-indigo-500/10 flex items-center justify-center shrink-0",children:v.jsx(ss,{className:"h-4 w-4 text-indigo-400"})}),v.jsxs("div",{className:"flex-1 min-w-0",children:[v.jsxs("div",{className:"flex items-center gap-2",children:[v.jsx("span",{className:"text-sm font-medium text-zinc-300 truncate font-mono",children:a.id.slice(0,8)}),v.jsx("span",{className:"text-xs text-zinc-600",children:a.tenantId})]}),v.jsxs("div",{className:"flex items-center gap-3 mt-1",children:[v.jsxs("span",{className:"flex items-center gap-1 text-xs text-zinc-500",children:[v.jsx(yg,{className:"h-3 w-3"}),ib(a.createdAt)]}),v.jsxs("span",{className:"text-xs text-zinc-600",children:["Last active ",rb(a.lastAccessedAt)]})]})]}),v.jsx(gg,{className:"h-4 w-4 text-zinc-700 group-hover:text-zinc-500 transition-colors shrink-0"})]},a.id))})})]})}function ob(){const{sessionId:e}=fs(),r=Sl(),[i,l]=M.useState([]),[a,u]=M.useState(!0),[c,f]=M.useState(null);M.useEffect(()=>{e&&fetch(`/session/${encodeURIComponent(e)}`).then(g=>{if(!g.ok)throw new Error("Session not found");return g.json()}).then(g=>{g&&typeof g=="object"&&"messages"in g&&Array.isArray(g.messages)&&l(g.messages)}).catch(g=>{f(g instanceof Error?g.message:"Failed to load session")}).finally(()=>u(!1))},[e]);const p=i.filter(g=>g.role==="user"),m=i.filter(g=>g.role==="assistant");return v.jsxs("div",{className:"h-full flex flex-col bg-[#0a0a0f]",children:[v.jsxs("div",{className:"border-b border-zinc-800/50 px-6 py-4 flex items-center justify-between",children:[v.jsxs("div",{className:"flex items-center gap-3",children:[v.jsx(ps,{to:"/sessions",className:"text-zinc-500 hover:text-zinc-300 transition-colors",children:v.jsx(mg,{className:"h-4 w-4"})}),v.jsxs("div",{children:[v.jsxs("h1",{className:"text-sm font-semibold text-zinc-200 font-mono",children:[e==null?void 0:e.slice(0,8),"..."]}),v.jsxs("div",{className:"flex items-center gap-3 mt-0.5",children:[v.jsxs("span",{className:"text-xs text-zinc-500",children:[p.length," messages"]}),v.jsxs("span",{className:"text-xs text-zinc-500",children:[m.length," responses"]})]})]})]}),v.jsxs("button",{onClick:()=>{r(`/?resume=${e??""}`)},className:"flex items-center gap-1.5 px-3 py-1.5 text-xs font-medium rounded-md bg-indigo-600 text-white hover:bg-indigo-500 transition-colors",children:[v.jsx(wg,{className:"h-3 w-3"}),"Resume"]})]}),v.jsx("div",{className:"flex-1 overflow-y-auto scrollbar-thin",children:a?v.jsx("div",{className:"flex items-center justify-center h-32 text-zinc-500 text-sm",children:"Loading..."}):c?v.jsx("div",{className:"flex items-center justify-center h-32 text-red-400 text-sm",children:c}):v.jsx("div",{className:"max-w-3xl mx-auto px-4 py-6",children:i.map((g,y)=>v.jsx("div",{className:g.role==="user"?"mb-6 flex justify-end":"mb-6",children:g.role==="user"?v.jsx("div",{className:"max-w-[85%] px-4 py-3 rounded-2xl rounded-br-md bg-indigo-600/70 text-white text-[14px] leading-relaxed",children:g.text}):v.jsx("div",{className:"text-[14px] text-zinc-300 prose prose-invert prose-sm max-w-none prose-headings:text-zinc-200 prose-p:text-zinc-300 prose-strong:text-zinc-200 prose-code:text-indigo-300 prose-code:bg-zinc-800 prose-code:px-1 prose-code:py-0.5 prose-code:rounded prose-pre:bg-zinc-800/80 prose-pre:border prose-pre:border-zinc-700/50 prose-a:text-indigo-400 prose-li:text-zinc-300",children:v.jsx(vd,{children:g.text})})},`msg-${String(y)}`))})})]})}const Sm=["bg-blue-100 text-blue-800","bg-green-100 text-green-800","bg-yellow-100 text-yellow-800","bg-red-100 text-red-800","bg-purple-100 text-purple-800","bg-pink-100 text-pink-800","bg-indigo-100 text-indigo-800","bg-orange-100 text-orange-800","bg-teal-100 text-teal-800","bg-cyan-100 text-cyan-800"];function ab(e){let r=0;for(let i=0;i<e.length;i++)r=(r<<5)-r+e.charCodeAt(i)|0;return Math.abs(r)}const sb={P1:"bg-red-100 text-red-800",P2:"bg-orange-100 text-orange-800",P3:"bg-yellow-100 text-yellow-800",P4:"bg-blue-100 text-blue-800",critical:"bg-red-100 text-red-800",at_risk:"bg-orange-100 text-orange-800",attention:"bg-yellow-100 text-yellow-800",healthy:"bg-green-100 text-green-800",active:"bg-green-100 text-green-800",resolved:"bg-gray-100 text-gray-800",false_positive:"bg-gray-100 text-gray-600",immediate:"bg-red-100 text-red-800",soon:"bg-yellow-100 text-yellow-800",when_convenient:"bg-blue-100 text-blue-800"};function ub({value:e,className:r}){const i=sb[e]??Sm[ab(e)%Sm.length];return v.jsx("span",{className:gs("inline-flex items-center rounded-full px-2 py-0.5 text-xs font-medium",i,r),children:e})}function ws({field:e,value:r,mode:i}){if(r==null)return v.jsx("span",{className:"text-muted-foreground",children:"—"});switch(e.type){case"string":return v.jsx(cb,{value:r,mode:i});case"number":return v.jsx(db,{value:r,field:e,mode:i});case"boolean":return v.jsx(fb,{value:r});case"datetime":return v.jsx(hb,{value:r,mode:i});case"enum":return v.jsx(ub,{value:String(r)});case"array":return v.jsx(pb,{value:r,field:e,mode:i});case"object":return v.jsx(mb,{value:r,field:e,mode:i});case"ref":return v.jsx(gb,{value:r,field:e});default:return v.jsx("span",{children:String(r)})}}function cb({value:e,mode:r}){const i=String(e);return r==="table"&&i.length>50?v.jsxs("span",{title:i,children:[i.slice(0,50),"…"]}):v.jsx("span",{children:i})}function db({value:e,field:r,mode:i}){const l=Number(e);if(r.min===0&&r.max===1){const a=Math.round(l*100);return i==="table"?v.jsxs("span",{className:"tabular-nums",children:[a,"%"]}):v.jsxs("div",{className:"flex items-center gap-2",children:[v.jsx("div",{className:"flex-1 h-2 bg-muted rounded-full max-w-[200px]",children:v.jsx("div",{className:"h-2 bg-primary rounded-full",style:{width:`${a}%`}})}),v.jsxs("span",{className:"text-sm tabular-nums",children:[a,"%"]})]})}return v.jsx("span",{className:"tabular-nums",children:l.toLocaleString()})}function fb({value:e}){return e?v.jsx(Iw,{className:"h-4 w-4 text-green-600"}):v.jsx(kg,{className:"h-4 w-4 text-muted-foreground"})}function hb({value:e,mode:r}){const i=new Date(String(e)),l=yb(i);return r==="table"?v.jsx("span",{className:"text-muted-foreground",title:i.toISOString(),children:l}):v.jsxs("div",{children:[v.jsx("div",{children:i.toLocaleString()}),v.jsx("div",{className:"text-xs text-muted-foreground",children:l})]})}function pb({value:e,field:r,mode:i}){return Array.isArray(e)?i==="table"?v.jsxs("span",{className:"inline-flex items-center rounded-full bg-muted px-2 py-0.5 text-xs",children:[e.length," item",e.length!==1?"s":""]}):e.length===0?v.jsx("span",{className:"text-muted-foreground",children:"Empty array"}):v.jsx("div",{className:"space-y-1",children:e.map((l,a)=>v.jsx("div",{className:"pl-3 border-l-2 border-muted",children:r.item?v.jsx(ws,{field:r.item,value:l,mode:"detail"}):v.jsx("span",{children:String(l)})},a))}):v.jsx("span",{children:String(e)})}function mb({value:e,field:r,mode:i}){if(typeof e!="object"||e===null)return v.jsx("span",{children:String(e)});if(i==="table")return v.jsx("span",{className:"text-muted-foreground",children:"{...}"});const l=e;return r.fields?v.jsx("div",{className:"border rounded-md divide-y",children:Object.entries(r.fields).map(([a,u])=>v.jsxs("div",{className:"px-3 py-2 flex",children:[v.jsx("div",{className:"w-32 text-xs font-medium text-muted-foreground shrink-0",children:a}),v.jsx("div",{className:"flex-1 min-w-0 text-sm",children:v.jsx(ws,{field:u,value:l[a],mode:"detail"})})]},a))}):v.jsx("pre",{className:"text-xs whitespace-pre-wrap bg-muted/30 rounded p-2",children:JSON.stringify(e,null,2)})}function gb({value:e,field:r}){const i=r.store;return i?v.jsx(ps,{to:`/entities/${i}/${String(e)}`,className:"text-primary hover:underline",children:String(e)}):v.jsx("span",{children:String(e)})}function yb(e){const i=Date.now()-e.getTime();if(i<0)return"just now";const l=Math.floor(i/1e3);if(l<60)return`${l}s ago`;const a=Math.floor(l/60);if(a<60)return`${a} min ago`;const u=Math.floor(a/60);if(u<24)return`${u}h ago`;const c=Math.floor(u/24);return c<30?`${c}d ago`:e.toLocaleDateString()}function vb({storeName:e,schema:r,keyTemplate:i,documents:l,total:a,onSortChange:u,onFilterChange:c}){const f=Sl(),p=Object.entries(r),[m,g]=M.useState(""),[y,k]=M.useState({}),x=i.replace(/[{}]/g,""),T=M.useCallback(b=>{const P=m===b?`-${b}`:b;g(P),u==null||u(P)},[m,u]),N=M.useCallback((b,P)=>{const z={...y};P===""?delete z[b]:z[b]=P,k(z),c==null||c(z)},[y,c]);return v.jsxs("div",{className:"bg-white border border-gray-200 rounded-lg overflow-hidden shadow-sm",children:[v.jsx("div",{className:"overflow-x-auto",children:v.jsxs("table",{className:"w-full text-sm",children:[v.jsxs("thead",{children:[v.jsx("tr",{className:"border-b border-gray-200 bg-gray-50/80",children:p.map(([b,P])=>v.jsx("th",{className:"px-4 py-3 text-left text-xs font-medium text-gray-500 uppercase tracking-wider cursor-pointer hover:text-gray-700 select-none transition-colors",onClick:()=>T(b),children:v.jsxs("span",{className:"inline-flex items-center gap-1",children:[b,m===b&&v.jsx(zw,{className:"h-3 w-3"}),m===`-${b}`&&v.jsx(Mw,{className:"h-3 w-3"})]})},b))}),p.some(([,b])=>b.type==="enum")&&v.jsx("tr",{className:"border-b border-gray-100 bg-gray-50/40",children:p.map(([b,P])=>v.jsx("th",{className:"px-4 py-1.5",children:P.type==="enum"&&P.values?v.jsxs("select",{className:"text-xs bg-white border border-gray-200 rounded px-1.5 py-1 w-full focus:outline-none focus:ring-1 focus:ring-indigo-500 focus:border-indigo-500 transition-colors",value:y[b]??"",onChange:z=>N(b,z.target.value),children:[v.jsx("option",{value:"",children:"All"}),P.values.map(z=>v.jsx("option",{value:z,children:z},z))]}):null},b))})]}),v.jsxs("tbody",{className:"divide-y divide-gray-100",children:[l.map(b=>{const P=String(b.payload[x]??b.key);return v.jsx("tr",{className:"hover:bg-indigo-50/40 cursor-pointer transition-colors duration-100",onClick:()=>f(`/entities/${e}/${P}`),children:p.map(([z,I])=>v.jsx("td",{className:"px-4 py-3 max-w-[220px]",children:v.jsx(ws,{field:I,value:b.payload[z],mode:"table"})},z))},b.key)}),l.length===0&&v.jsx("tr",{children:v.jsx("td",{colSpan:p.length,className:"px-4 py-16 text-center text-gray-400 text-sm",children:"No documents yet."})})]})]})}),a>0&&v.jsxs("div",{className:"px-4 py-2.5 border-t border-gray-100 bg-gray-50/50 text-xs text-gray-500",children:["Showing ",l.length," of ",a.toLocaleString()," document",a!==1?"s":""]})]})}function xb(){const{storeName:e}=fs(),{stores:r}=Mo(),[i,l]=M.useState(),[a,u]=M.useState(),c=r.find(x=>x.name===e),{documents:f,total:p,isLoading:m,error:g}=jw(e??"",{sort:i,filter:a,limit:50,refreshInterval:15e3}),y=M.useCallback(x=>{l(x)},[]),k=M.useCallback(x=>{u(Object.keys(x).length>0?x:void 0)},[]);return c?v.jsxs("div",{className:"max-w-[1200px] mx-auto px-6 pt-8 pb-12",children:[v.jsxs("div",{className:"flex items-center gap-3 mb-6",children:[v.jsx("div",{className:"h-9 w-9 rounded-lg bg-indigo-50 flex items-center justify-center",children:v.jsx(vg,{className:"h-5 w-5 text-indigo-500"})}),v.jsxs("div",{children:[v.jsx("h1",{className:"text-xl font-semibold tracking-tight",children:c.entity.name}),v.jsxs("p",{className:"text-sm text-gray-500",children:[p.toLocaleString()," document",p!==1?"s":""," in ",v.jsx("span",{className:"font-mono text-xs",children:c.name})]})]})]}),g&&v.jsx("div",{className:"mb-4 p-3 rounded-md bg-red-50 border border-red-200 text-red-700 text-sm",children:g}),m?v.jsx("div",{className:"flex items-center justify-center py-16 text-gray-400 text-sm",children:"Loading..."}):v.jsx(vb,{storeName:e??"",schema:c.entity.schema,keyTemplate:c.entity.key,documents:f,total:p,onSortChange:y,onFilterChange:k})]}):v.jsxs("div",{className:"flex items-center justify-center h-full text-gray-400 text-sm",children:["Store “",e,"” not found."]})}/**
|
|
274
|
+
* @license
|
|
275
|
+
* Copyright 2025 Amodal Labs, Inc.
|
|
276
|
+
* SPDX-License-Identifier: MIT
|
|
277
|
+
*/function wb({history:e}){return e.length===0?null:v.jsxs("div",{className:"border rounded-lg p-4 space-y-3",children:[v.jsx("h2",{className:"text-sm font-semibold text-muted-foreground uppercase tracking-wider",children:"Version History"}),v.jsx("div",{className:"space-y-3",children:e.map(r=>v.jsxs("div",{className:"relative pl-6 pb-3 border-l-2 border-muted last:pb-0",children:[v.jsx("div",{className:"absolute -left-[5px] top-1 h-2 w-2 rounded-full bg-muted-foreground"}),v.jsxs("div",{className:"flex items-center justify-between mb-1",children:[v.jsxs("span",{className:"text-sm font-medium",children:["v",r.version]}),v.jsx("span",{className:"text-xs text-muted-foreground",children:new Date(r.meta.computedAt).toLocaleString()})]}),v.jsxs("details",{className:"text-xs",children:[v.jsx("summary",{className:"cursor-pointer text-muted-foreground hover:text-foreground",children:"View payload"}),v.jsx("pre",{className:"mt-1 whitespace-pre-wrap bg-muted/30 rounded p-2 overflow-auto max-h-40",children:JSON.stringify(r.payload,null,2)})]})]},r.version))})]})}function kb({schema:e,document:r,meta:i,history:l,hasTrace:a}){return v.jsxs("div",{className:"space-y-5",children:[v.jsxs("div",{className:"flex items-center justify-between",children:[v.jsx("h1",{className:"text-xl font-semibold tracking-tight",children:r.key}),v.jsxs("div",{className:"flex items-center gap-2",children:[v.jsxs("span",{className:"text-xs text-gray-400 bg-gray-100 px-2 py-0.5 rounded font-mono",children:["v",r.version]}),i.stale&&v.jsx("span",{className:"px-2 py-0.5 rounded bg-amber-50 text-amber-700 border border-amber-200 text-xs font-medium",children:"Stale"})]})]}),v.jsx("div",{className:"bg-white border border-gray-200 rounded-lg shadow-sm divide-y divide-gray-100",children:Object.entries(e).map(([u,c])=>v.jsxs("div",{className:"px-5 py-3.5 flex",children:[v.jsxs("div",{className:"w-44 text-sm font-medium text-gray-500 shrink-0 pt-0.5",children:[u,c.nullable&&v.jsx("span",{className:"text-[10px] ml-1 text-gray-300",children:"?"})]}),v.jsx("div",{className:"text-sm flex-1 min-w-0",children:v.jsx(ws,{field:c,value:r.payload[u],mode:"detail"})})]},u))}),v.jsxs("div",{className:"bg-white border border-gray-200 rounded-lg shadow-sm p-5",children:[v.jsx("h2",{className:"text-xs font-semibold text-gray-400 uppercase tracking-widest mb-3",children:"Metadata"}),v.jsxs("div",{className:"grid grid-cols-2 lg:grid-cols-3 gap-3",children:[v.jsx(Wr,{icon:v.jsx(yg,{className:"h-3.5 w-3.5"}),label:"Computed",value:Sb(i.computedAt)}),i.ttl!==void 0&&v.jsx(Wr,{icon:v.jsx(cc,{className:"h-3.5 w-3.5"}),label:"TTL",value:`${i.ttl}s`}),i.modelUsed&&v.jsx(Wr,{icon:v.jsx(Ow,{className:"h-3.5 w-3.5"}),label:"Model",value:i.modelUsed}),i.durationMs!==void 0&&v.jsx(Wr,{icon:v.jsx(Po,{className:"h-3.5 w-3.5"}),label:"Duration",value:`${i.durationMs}ms`}),i.tokenCost!==void 0&&v.jsx(Wr,{icon:v.jsx(cc,{className:"h-3.5 w-3.5"}),label:"Tokens",value:i.tokenCost.toLocaleString()}),i.estimatedCostUsd!==void 0&&v.jsx(Wr,{icon:v.jsx(Fw,{className:"h-3.5 w-3.5"}),label:"Cost",value:`$${i.estimatedCostUsd.toFixed(4)}`}),i.automationId&&v.jsx(Wr,{icon:v.jsx(Po,{className:"h-3.5 w-3.5"}),label:"Automation",value:i.automationId}),i.skillId&&v.jsx(Wr,{icon:v.jsx(cc,{className:"h-3.5 w-3.5"}),label:"Skill",value:i.skillId})]})]}),a&&i.trace&&v.jsxs("details",{className:"bg-white border border-gray-200 rounded-lg shadow-sm group",children:[v.jsx("summary",{className:"px-5 py-3.5 cursor-pointer text-sm font-medium text-gray-500 hover:text-gray-700 transition-colors",children:"Reasoning Trace"}),v.jsx("pre",{className:"px-5 py-4 border-t border-gray-100 text-xs whitespace-pre-wrap text-gray-600 bg-gray-50/50 overflow-auto max-h-96 scrollbar-thin font-mono",children:i.trace})]}),v.jsx(wb,{history:l})]})}function Wr({icon:e,label:r,value:i}){return v.jsxs("div",{className:"flex items-center gap-2 text-sm",children:[v.jsx("span",{className:"text-gray-400",children:e}),v.jsxs("span",{className:"text-gray-500",children:[r,":"]}),v.jsx("span",{className:"text-gray-700 font-mono text-xs truncate",children:i})]})}function Sb(e){const r=new Date(e),l=Date.now()-r.getTime();return l<6e4?"just now":l<36e5?`${Math.floor(l/6e4)} min ago`:l<864e5?`${Math.floor(l/36e5)}h ago`:r.toLocaleString()}function Eb(){const{storeName:e,key:r}=fs(),i=Sl(),{stores:l}=Mo(),a=l.find(g=>g.name===e),{document:u,meta:c,history:f,isLoading:p,error:m}=Pw(e??"",{key:r??"",refreshInterval:15e3});return a?v.jsxs("div",{className:"max-w-[900px] mx-auto px-6 pt-8 pb-12",children:[v.jsxs("button",{onClick:()=>i(`/entities/${e}`),className:"flex items-center gap-1.5 text-sm text-gray-500 hover:text-indigo-600 mb-5 transition-colors",children:[v.jsx(mg,{className:"h-4 w-4"}),"Back to ",a.entity.name]}),m&&v.jsx("div",{className:"mb-4 p-3 rounded-md bg-red-50 border border-red-200 text-red-700 text-sm",children:m}),p?v.jsx("div",{className:"flex items-center justify-center py-16 text-gray-400 text-sm",children:"Loading..."}):!u||!c?v.jsx("div",{className:"flex items-center justify-center py-16 text-gray-400 text-sm",children:"Document not found."}):v.jsx(kb,{schema:a.entity.schema,document:u,meta:c,history:f,hasTrace:a.trace})]}):v.jsxs("div",{className:"flex items-center justify-center h-full text-gray-400 text-sm",children:["Store “",e,"” not found."]})}function Cb(){const[e,r]=M.useState([]),[i,l]=M.useState(!0);return M.useEffect(()=>{async function a(){try{const u=await fetch("/automations");if(u.ok){const c=await u.json();r(c.automations)}}catch{}finally{l(!1)}}a()},[]),v.jsxs("div",{className:"p-6",children:[v.jsx("h1",{className:"text-2xl font-bold mb-4",children:"Automations"}),i?v.jsx("div",{className:"text-muted-foreground text-sm",children:"Loading..."}):e.length===0?v.jsxs("div",{className:"text-muted-foreground text-sm",children:["No automations defined. Add ",v.jsx("code",{children:".json"})," or ",v.jsx("code",{children:".md"})," files to ",v.jsx("code",{children:"automations/"}),"."]}):v.jsx("div",{className:"space-y-3",children:e.map(a=>v.jsxs("div",{className:"border rounded-lg p-4 flex items-center justify-between",children:[v.jsxs("div",{className:"flex items-center gap-3",children:[v.jsx(Po,{className:"h-4 w-4 text-muted-foreground"}),v.jsxs("div",{children:[v.jsx("div",{className:"font-medium text-sm",children:a.name}),a.schedule&&v.jsx("div",{className:"text-xs text-muted-foreground",children:a.schedule})]})]}),v.jsx("div",{className:"flex items-center gap-2",children:a.running?v.jsxs("span",{className:"flex items-center gap-1 text-xs text-green-600",children:[v.jsx(wg,{className:"h-3 w-3"})," Running"]}):v.jsxs("span",{className:"flex items-center gap-1 text-xs text-muted-foreground",children:[v.jsx($w,{className:"h-3 w-3"})," Idle"]})})]},a.name))})]})}function bb(){const{pageName:e}=fs(),[r,i]=M.useState(null),[l,a]=M.useState(!1);return M.useEffect(()=>{if(!e)return;i(null),a(!1);const u=window.__AMODAL_PAGES__;if(u!=null&&u[e]){i(()=>u[e]);return}const c=document.createElement("script");c.src=`/pages-bundle/${e}.js`,c.onload=()=>{const f=window.__AMODAL_PAGES__;f!=null&&f[e]?i(()=>f[e]):a(!0)},c.onerror=()=>a(!0),document.head.appendChild(c)},[e]),l?v.jsx(Nb,{name:e??""}):r?v.jsx(r,{}):v.jsx("div",{className:"p-6 text-gray-500 dark:text-zinc-500 text-sm",children:"Loading page..."})}function Nb({name:e}){return v.jsxs("div",{className:"p-6",children:[v.jsx("h1",{className:"text-xl font-bold mb-2 text-gray-900 dark:text-zinc-200",children:"Page Not Found"}),v.jsx("p",{className:"text-gray-500 dark:text-zinc-500",children:e?`No page named "${e}" found in pages/.`:"No page specified."})]})}const Pb=Nx([{path:"/",element:v.jsx(I1,{}),children:[{index:!0,element:v.jsx(nb,{})},{path:"sessions",element:v.jsx(lb,{})},{path:"sessions/:sessionId",element:v.jsx(ob,{})},{path:"entities/:storeName",element:v.jsx(xb,{})},{path:"entities/:storeName/:key",element:v.jsx(Eb,{})},{path:"automations",element:v.jsx(Cb,{})},{path:"pages/:pageName",element:v.jsx(bb,{})}]}]),Em=window.location.origin,jb="local",_b=new gw({defaultOptions:{queries:{staleTime:1e4,refetchOnWindowFocus:!1}}});function Tb(){return v.jsx(vw,{client:_b,children:v.jsx(Sw,{runtimeUrl:Em,tenantId:jb,children:v.jsx(_w,{runtimeUrl:Em,children:v.jsx(Mx,{router:Pb})})})})}window.React=Mm;window.ReactDOM=Am;window.__AMODAL_PAGES__={};const uy=document.getElementById("app");if(!uy)throw new Error("Missing #app element");nv.createRoot(uy).render(v.jsx(M.StrictMode,{children:v.jsx(Tb,{})}));
|