apigrip 0.6.4 → 0.6.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,75 +0,0 @@
1
- (function(){const a=document.createElement("link").relList;if(a&&a.supports&&a.supports("modulepreload"))return;for(const c of document.querySelectorAll('link[rel="modulepreload"]'))s(c);new MutationObserver(c=>{for(const f of c)if(f.type==="childList")for(const d of f.addedNodes)d.tagName==="LINK"&&d.rel==="modulepreload"&&s(d)}).observe(document,{childList:!0,subtree:!0});function u(c){const f={};return c.integrity&&(f.integrity=c.integrity),c.referrerPolicy&&(f.referrerPolicy=c.referrerPolicy),c.crossOrigin==="use-credentials"?f.credentials="include":c.crossOrigin==="anonymous"?f.credentials="omit":f.credentials="same-origin",f}function s(c){if(c.ep)return;c.ep=!0;const f=u(c);fetch(c.href,f)}})();function jy(i){return i&&i.__esModule&&Object.prototype.hasOwnProperty.call(i,"default")?i.default:i}var Kc={exports:{}},su={};var op;function Oy(){if(op)return su;op=1;var i=Symbol.for("react.transitional.element"),a=Symbol.for("react.fragment");function u(s,c,f){var d=null;if(f!==void 0&&(d=""+f),c.key!==void 0&&(d=""+c.key),"key"in c){f={};for(var p in c)p!=="key"&&(f[p]=c[p])}else f=c;return c=f.ref,{$$typeof:i,type:s,key:d,ref:c!==void 0?c:null,props:f}}return su.Fragment=a,su.jsx=u,su.jsxs=u,su}var fp;function Ny(){return fp||(fp=1,Kc.exports=Oy()),Kc.exports}var b=Ny(),Jc={exports:{}},ru={},$c={exports:{}},Fc={};var hp;function My(){return hp||(hp=1,(function(i){function a(D,F){var re=D.length;D.push(F);e:for(;0<re;){var Be=re-1>>>1,He=D[Be];if(0<c(He,F))D[Be]=F,D[re]=He,re=Be;else break e}}function u(D){return D.length===0?null:D[0]}function s(D){if(D.length===0)return null;var F=D[0],re=D.pop();if(re!==F){D[0]=re;e:for(var Be=0,He=D.length,E=He>>>1;Be<E;){var L=2*(Be+1)-1,I=D[L],ee=L+1,ye=D[ee];if(0>c(I,re))ee<He&&0>c(ye,I)?(D[Be]=ye,D[ee]=re,Be=ee):(D[Be]=I,D[L]=re,Be=L);else if(ee<He&&0>c(ye,re))D[Be]=ye,D[ee]=re,Be=ee;else break e}}return F}function c(D,F){var re=D.sortIndex-F.sortIndex;return re!==0?re:D.id-F.id}if(i.unstable_now=void 0,typeof performance=="object"&&typeof performance.now=="function"){var f=performance;i.unstable_now=function(){return f.now()}}else{var d=Date,p=d.now();i.unstable_now=function(){return d.now()-p}}var g=[],y=[],x=1,A=null,z=3,q=!1,Q=!1,$=!1,X=!1,K=typeof setTimeout=="function"?setTimeout:null,se=typeof clearTimeout=="function"?clearTimeout:null,be=typeof setImmediate<"u"?setImmediate:null;function Se(D){for(var F=u(y);F!==null;){if(F.callback===null)s(y);else if(F.startTime<=D)s(y),F.sortIndex=F.expirationTime,a(g,F);else break;F=u(y)}}function oe(D){if($=!1,Se(D),!Q)if(u(g)!==null)Q=!0,ve||(ve=!0,me());else{var F=u(y);F!==null&&We(oe,F.startTime-D)}}var ve=!1,R=-1,w=5,P=-1;function Ve(){return X?!0:!(i.unstable_now()-P<w)}function W(){if(X=!1,ve){var D=i.unstable_now();P=D;var F=!0;try{e:{Q=!1,$&&($=!1,se(R),R=-1),q=!0;var re=z;try{t:{for(Se(D),A=u(g);A!==null&&!(A.expirationTime>D&&Ve());){var Be=A.callback;if(typeof Be=="function"){A.callback=null,z=A.priorityLevel;var He=Be(A.expirationTime<=D);if(D=i.unstable_now(),typeof He=="function"){A.callback=He,Se(D),F=!0;break t}A===u(g)&&s(g),Se(D)}else s(g);A=u(g)}if(A!==null)F=!0;else{var E=u(y);E!==null&&We(oe,E.startTime-D),F=!1}}break e}finally{A=null,z=re,q=!1}F=void 0}}finally{F?me():ve=!1}}}var me;if(typeof be=="function")me=function(){be(W)};else if(typeof MessageChannel<"u"){var et=new MessageChannel,Me=et.port2;et.port1.onmessage=W,me=function(){Me.postMessage(null)}}else me=function(){K(W,0)};function We(D,F){R=K(function(){D(i.unstable_now())},F)}i.unstable_IdlePriority=5,i.unstable_ImmediatePriority=1,i.unstable_LowPriority=4,i.unstable_NormalPriority=3,i.unstable_Profiling=null,i.unstable_UserBlockingPriority=2,i.unstable_cancelCallback=function(D){D.callback=null},i.unstable_forceFrameRate=function(D){0>D||125<D?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):w=0<D?Math.floor(1e3/D):5},i.unstable_getCurrentPriorityLevel=function(){return z},i.unstable_next=function(D){switch(z){case 1:case 2:case 3:var F=3;break;default:F=z}var re=z;z=F;try{return D()}finally{z=re}},i.unstable_requestPaint=function(){X=!0},i.unstable_runWithPriority=function(D,F){switch(D){case 1:case 2:case 3:case 4:case 5:break;default:D=3}var re=z;z=D;try{return F()}finally{z=re}},i.unstable_scheduleCallback=function(D,F,re){var Be=i.unstable_now();switch(typeof re=="object"&&re!==null?(re=re.delay,re=typeof re=="number"&&0<re?Be+re:Be):re=Be,D){case 1:var He=-1;break;case 2:He=250;break;case 5:He=1073741823;break;case 4:He=1e4;break;default:He=5e3}return He=re+He,D={id:x++,callback:F,priorityLevel:D,startTime:re,expirationTime:He,sortIndex:-1},re>Be?(D.sortIndex=re,a(y,D),u(g)===null&&D===u(y)&&($?(se(R),R=-1):$=!0,We(oe,re-Be))):(D.sortIndex=He,a(g,D),Q||q||(Q=!0,ve||(ve=!0,me()))),D},i.unstable_shouldYield=Ve,i.unstable_wrapCallback=function(D){var F=z;return function(){var re=z;z=F;try{return D.apply(this,arguments)}finally{z=re}}}})(Fc)),Fc}var dp;function zy(){return dp||(dp=1,$c.exports=My()),$c.exports}var Wc={exports:{}},xe={};var pp;function Ry(){if(pp)return xe;pp=1;var i=Symbol.for("react.transitional.element"),a=Symbol.for("react.portal"),u=Symbol.for("react.fragment"),s=Symbol.for("react.strict_mode"),c=Symbol.for("react.profiler"),f=Symbol.for("react.consumer"),d=Symbol.for("react.context"),p=Symbol.for("react.forward_ref"),g=Symbol.for("react.suspense"),y=Symbol.for("react.memo"),x=Symbol.for("react.lazy"),A=Symbol.for("react.activity"),z=Symbol.iterator;function q(E){return E===null||typeof E!="object"?null:(E=z&&E[z]||E["@@iterator"],typeof E=="function"?E:null)}var Q={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},$=Object.assign,X={};function K(E,L,I){this.props=E,this.context=L,this.refs=X,this.updater=I||Q}K.prototype.isReactComponent={},K.prototype.setState=function(E,L){if(typeof E!="object"&&typeof E!="function"&&E!=null)throw Error("takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,E,L,"setState")},K.prototype.forceUpdate=function(E){this.updater.enqueueForceUpdate(this,E,"forceUpdate")};function se(){}se.prototype=K.prototype;function be(E,L,I){this.props=E,this.context=L,this.refs=X,this.updater=I||Q}var Se=be.prototype=new se;Se.constructor=be,$(Se,K.prototype),Se.isPureReactComponent=!0;var oe=Array.isArray;function ve(){}var R={H:null,A:null,T:null,S:null},w=Object.prototype.hasOwnProperty;function P(E,L,I){var ee=I.ref;return{$$typeof:i,type:E,key:L,ref:ee!==void 0?ee:null,props:I}}function Ve(E,L){return P(E.type,L,E.props)}function W(E){return typeof E=="object"&&E!==null&&E.$$typeof===i}function me(E){var L={"=":"=0",":":"=2"};return"$"+E.replace(/[=:]/g,function(I){return L[I]})}var et=/\/+/g;function Me(E,L){return typeof E=="object"&&E!==null&&E.key!=null?me(""+E.key):L.toString(36)}function We(E){switch(E.status){case"fulfilled":return E.value;case"rejected":throw E.reason;default:switch(typeof E.status=="string"?E.then(ve,ve):(E.status="pending",E.then(function(L){E.status==="pending"&&(E.status="fulfilled",E.value=L)},function(L){E.status==="pending"&&(E.status="rejected",E.reason=L)})),E.status){case"fulfilled":return E.value;case"rejected":throw E.reason}}throw E}function D(E,L,I,ee,ye){var _e=typeof E;(_e==="undefined"||_e==="boolean")&&(E=null);var we=!1;if(E===null)we=!0;else switch(_e){case"bigint":case"string":case"number":we=!0;break;case"object":switch(E.$$typeof){case i:case a:we=!0;break;case x:return we=E._init,D(we(E._payload),L,I,ee,ye)}}if(we)return ye=ye(E),we=ee===""?"."+Me(E,0):ee,oe(ye)?(I="",we!=null&&(I=we.replace(et,"$&/")+"/"),D(ye,L,I,"",function(Lt){return Lt})):ye!=null&&(W(ye)&&(ye=Ve(ye,I+(ye.key==null||E&&E.key===ye.key?"":(""+ye.key).replace(et,"$&/")+"/")+we)),L.push(ye)),1;we=0;var dt=ee===""?".":ee+":";if(oe(E))for(var ut=0;ut<E.length;ut++)ee=E[ut],_e=dt+Me(ee,ut),we+=D(ee,L,I,_e,ye);else if(ut=q(E),typeof ut=="function")for(E=ut.call(E),ut=0;!(ee=E.next()).done;)ee=ee.value,_e=dt+Me(ee,ut++),we+=D(ee,L,I,_e,ye);else if(_e==="object"){if(typeof E.then=="function")return D(We(E),L,I,ee,ye);throw L=String(E),Error("Objects are not valid as a React child (found: "+(L==="[object Object]"?"object with keys {"+Object.keys(E).join(", ")+"}":L)+"). If you meant to render a collection of children, use an array instead.")}return we}function F(E,L,I){if(E==null)return E;var ee=[],ye=0;return D(E,ee,"","",function(_e){return L.call(I,_e,ye++)}),ee}function re(E){if(E._status===-1){var L=E._result;L=L(),L.then(function(I){(E._status===0||E._status===-1)&&(E._status=1,E._result=I)},function(I){(E._status===0||E._status===-1)&&(E._status=2,E._result=I)}),E._status===-1&&(E._status=0,E._result=L)}if(E._status===1)return E._result.default;throw E._result}var Be=typeof reportError=="function"?reportError:function(E){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var L=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof E=="object"&&E!==null&&typeof E.message=="string"?String(E.message):String(E),error:E});if(!window.dispatchEvent(L))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",E);return}console.error(E)},He={map:F,forEach:function(E,L,I){F(E,function(){L.apply(this,arguments)},I)},count:function(E){var L=0;return F(E,function(){L++}),L},toArray:function(E){return F(E,function(L){return L})||[]},only:function(E){if(!W(E))throw Error("React.Children.only expected to receive a single React element child.");return E}};return xe.Activity=A,xe.Children=He,xe.Component=K,xe.Fragment=u,xe.Profiler=c,xe.PureComponent=be,xe.StrictMode=s,xe.Suspense=g,xe.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=R,xe.__COMPILER_RUNTIME={__proto__:null,c:function(E){return R.H.useMemoCache(E)}},xe.cache=function(E){return function(){return E.apply(null,arguments)}},xe.cacheSignal=function(){return null},xe.cloneElement=function(E,L,I){if(E==null)throw Error("The argument must be a React element, but you passed "+E+".");var ee=$({},E.props),ye=E.key;if(L!=null)for(_e in L.key!==void 0&&(ye=""+L.key),L)!w.call(L,_e)||_e==="key"||_e==="__self"||_e==="__source"||_e==="ref"&&L.ref===void 0||(ee[_e]=L[_e]);var _e=arguments.length-2;if(_e===1)ee.children=I;else if(1<_e){for(var we=Array(_e),dt=0;dt<_e;dt++)we[dt]=arguments[dt+2];ee.children=we}return P(E.type,ye,ee)},xe.createContext=function(E){return E={$$typeof:d,_currentValue:E,_currentValue2:E,_threadCount:0,Provider:null,Consumer:null},E.Provider=E,E.Consumer={$$typeof:f,_context:E},E},xe.createElement=function(E,L,I){var ee,ye={},_e=null;if(L!=null)for(ee in L.key!==void 0&&(_e=""+L.key),L)w.call(L,ee)&&ee!=="key"&&ee!=="__self"&&ee!=="__source"&&(ye[ee]=L[ee]);var we=arguments.length-2;if(we===1)ye.children=I;else if(1<we){for(var dt=Array(we),ut=0;ut<we;ut++)dt[ut]=arguments[ut+2];ye.children=dt}if(E&&E.defaultProps)for(ee in we=E.defaultProps,we)ye[ee]===void 0&&(ye[ee]=we[ee]);return P(E,_e,ye)},xe.createRef=function(){return{current:null}},xe.forwardRef=function(E){return{$$typeof:p,render:E}},xe.isValidElement=W,xe.lazy=function(E){return{$$typeof:x,_payload:{_status:-1,_result:E},_init:re}},xe.memo=function(E,L){return{$$typeof:y,type:E,compare:L===void 0?null:L}},xe.startTransition=function(E){var L=R.T,I={};R.T=I;try{var ee=E(),ye=R.S;ye!==null&&ye(I,ee),typeof ee=="object"&&ee!==null&&typeof ee.then=="function"&&ee.then(ve,Be)}catch(_e){Be(_e)}finally{L!==null&&I.types!==null&&(L.types=I.types),R.T=L}},xe.unstable_useCacheRefresh=function(){return R.H.useCacheRefresh()},xe.use=function(E){return R.H.use(E)},xe.useActionState=function(E,L,I){return R.H.useActionState(E,L,I)},xe.useCallback=function(E,L){return R.H.useCallback(E,L)},xe.useContext=function(E){return R.H.useContext(E)},xe.useDebugValue=function(){},xe.useDeferredValue=function(E,L){return R.H.useDeferredValue(E,L)},xe.useEffect=function(E,L){return R.H.useEffect(E,L)},xe.useEffectEvent=function(E){return R.H.useEffectEvent(E)},xe.useId=function(){return R.H.useId()},xe.useImperativeHandle=function(E,L,I){return R.H.useImperativeHandle(E,L,I)},xe.useInsertionEffect=function(E,L){return R.H.useInsertionEffect(E,L)},xe.useLayoutEffect=function(E,L){return R.H.useLayoutEffect(E,L)},xe.useMemo=function(E,L){return R.H.useMemo(E,L)},xe.useOptimistic=function(E,L){return R.H.useOptimistic(E,L)},xe.useReducer=function(E,L,I){return R.H.useReducer(E,L,I)},xe.useRef=function(E){return R.H.useRef(E)},xe.useState=function(E){return R.H.useState(E)},xe.useSyncExternalStore=function(E,L,I){return R.H.useSyncExternalStore(E,L,I)},xe.useTransition=function(){return R.H.useTransition()},xe.version="19.2.4",xe}var gp;function bo(){return gp||(gp=1,Wc.exports=Ry()),Wc.exports}var Ic={exports:{}},Ht={};var mp;function Cy(){if(mp)return Ht;mp=1;var i=bo();function a(g){var y="https://react.dev/errors/"+g;if(1<arguments.length){y+="?args[]="+encodeURIComponent(arguments[1]);for(var x=2;x<arguments.length;x++)y+="&args[]="+encodeURIComponent(arguments[x])}return"Minified React error #"+g+"; visit "+y+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function u(){}var s={d:{f:u,r:function(){throw Error(a(522))},D:u,C:u,L:u,m:u,X:u,S:u,M:u},p:0,findDOMNode:null},c=Symbol.for("react.portal");function f(g,y,x){var A=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:c,key:A==null?null:""+A,children:g,containerInfo:y,implementation:x}}var d=i.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function p(g,y){if(g==="font")return"";if(typeof y=="string")return y==="use-credentials"?y:""}return Ht.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=s,Ht.createPortal=function(g,y){var x=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!y||y.nodeType!==1&&y.nodeType!==9&&y.nodeType!==11)throw Error(a(299));return f(g,y,null,x)},Ht.flushSync=function(g){var y=d.T,x=s.p;try{if(d.T=null,s.p=2,g)return g()}finally{d.T=y,s.p=x,s.d.f()}},Ht.preconnect=function(g,y){typeof g=="string"&&(y?(y=y.crossOrigin,y=typeof y=="string"?y==="use-credentials"?y:"":void 0):y=null,s.d.C(g,y))},Ht.prefetchDNS=function(g){typeof g=="string"&&s.d.D(g)},Ht.preinit=function(g,y){if(typeof g=="string"&&y&&typeof y.as=="string"){var x=y.as,A=p(x,y.crossOrigin),z=typeof y.integrity=="string"?y.integrity:void 0,q=typeof y.fetchPriority=="string"?y.fetchPriority:void 0;x==="style"?s.d.S(g,typeof y.precedence=="string"?y.precedence:void 0,{crossOrigin:A,integrity:z,fetchPriority:q}):x==="script"&&s.d.X(g,{crossOrigin:A,integrity:z,fetchPriority:q,nonce:typeof y.nonce=="string"?y.nonce:void 0})}},Ht.preinitModule=function(g,y){if(typeof g=="string")if(typeof y=="object"&&y!==null){if(y.as==null||y.as==="script"){var x=p(y.as,y.crossOrigin);s.d.M(g,{crossOrigin:x,integrity:typeof y.integrity=="string"?y.integrity:void 0,nonce:typeof y.nonce=="string"?y.nonce:void 0})}}else y==null&&s.d.M(g)},Ht.preload=function(g,y){if(typeof g=="string"&&typeof y=="object"&&y!==null&&typeof y.as=="string"){var x=y.as,A=p(x,y.crossOrigin);s.d.L(g,x,{crossOrigin:A,integrity:typeof y.integrity=="string"?y.integrity:void 0,nonce:typeof y.nonce=="string"?y.nonce:void 0,type:typeof y.type=="string"?y.type:void 0,fetchPriority:typeof y.fetchPriority=="string"?y.fetchPriority:void 0,referrerPolicy:typeof y.referrerPolicy=="string"?y.referrerPolicy:void 0,imageSrcSet:typeof y.imageSrcSet=="string"?y.imageSrcSet:void 0,imageSizes:typeof y.imageSizes=="string"?y.imageSizes:void 0,media:typeof y.media=="string"?y.media:void 0})}},Ht.preloadModule=function(g,y){if(typeof g=="string")if(y){var x=p(y.as,y.crossOrigin);s.d.m(g,{as:typeof y.as=="string"&&y.as!=="script"?y.as:void 0,crossOrigin:x,integrity:typeof y.integrity=="string"?y.integrity:void 0})}else s.d.m(g)},Ht.requestFormReset=function(g){s.d.r(g)},Ht.unstable_batchedUpdates=function(g,y){return g(y)},Ht.useFormState=function(g,y,x){return d.H.useFormState(g,y,x)},Ht.useFormStatus=function(){return d.H.useHostTransitionStatus()},Ht.version="19.2.4",Ht}var yp;function wy(){if(yp)return Ic.exports;yp=1;function i(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(i)}catch(a){console.error(a)}}return i(),Ic.exports=Cy(),Ic.exports}var bp;function Dy(){if(bp)return ru;bp=1;var i=zy(),a=bo(),u=wy();function s(e){var t="https://react.dev/errors/"+e;if(1<arguments.length){t+="?args[]="+encodeURIComponent(arguments[1]);for(var l=2;l<arguments.length;l++)t+="&args[]="+encodeURIComponent(arguments[l])}return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function c(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function f(e){var t=e,l=e;if(e.alternate)for(;t.return;)t=t.return;else{e=t;do t=e,(t.flags&4098)!==0&&(l=t.return),e=t.return;while(e)}return t.tag===3?l:null}function d(e){if(e.tag===13){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function p(e){if(e.tag===31){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function g(e){if(f(e)!==e)throw Error(s(188))}function y(e){var t=e.alternate;if(!t){if(t=f(e),t===null)throw Error(s(188));return t!==e?null:e}for(var l=e,n=t;;){var r=l.return;if(r===null)break;var o=r.alternate;if(o===null){if(n=r.return,n!==null){l=n;continue}break}if(r.child===o.child){for(o=r.child;o;){if(o===l)return g(r),e;if(o===n)return g(r),t;o=o.sibling}throw Error(s(188))}if(l.return!==n.return)l=r,n=o;else{for(var h=!1,m=r.child;m;){if(m===l){h=!0,l=r,n=o;break}if(m===n){h=!0,n=r,l=o;break}m=m.sibling}if(!h){for(m=o.child;m;){if(m===l){h=!0,l=o,n=r;break}if(m===n){h=!0,n=o,l=r;break}m=m.sibling}if(!h)throw Error(s(189))}}if(l.alternate!==n)throw Error(s(190))}if(l.tag!==3)throw Error(s(188));return l.stateNode.current===l?e:t}function x(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e;for(e=e.child;e!==null;){if(t=x(e),t!==null)return t;e=e.sibling}return null}var A=Object.assign,z=Symbol.for("react.element"),q=Symbol.for("react.transitional.element"),Q=Symbol.for("react.portal"),$=Symbol.for("react.fragment"),X=Symbol.for("react.strict_mode"),K=Symbol.for("react.profiler"),se=Symbol.for("react.consumer"),be=Symbol.for("react.context"),Se=Symbol.for("react.forward_ref"),oe=Symbol.for("react.suspense"),ve=Symbol.for("react.suspense_list"),R=Symbol.for("react.memo"),w=Symbol.for("react.lazy"),P=Symbol.for("react.activity"),Ve=Symbol.for("react.memo_cache_sentinel"),W=Symbol.iterator;function me(e){return e===null||typeof e!="object"?null:(e=W&&e[W]||e["@@iterator"],typeof e=="function"?e:null)}var et=Symbol.for("react.client.reference");function Me(e){if(e==null)return null;if(typeof e=="function")return e.$$typeof===et?null:e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case $:return"Fragment";case K:return"Profiler";case X:return"StrictMode";case oe:return"Suspense";case ve:return"SuspenseList";case P:return"Activity"}if(typeof e=="object")switch(e.$$typeof){case Q:return"Portal";case be:return e.displayName||"Context";case se:return(e._context.displayName||"Context")+".Consumer";case Se:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case R:return t=e.displayName||null,t!==null?t:Me(e.type)||"Memo";case w:t=e._payload,e=e._init;try{return Me(e(t))}catch{}}return null}var We=Array.isArray,D=a.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,F=u.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,re={pending:!1,data:null,method:null,action:null},Be=[],He=-1;function E(e){return{current:e}}function L(e){0>He||(e.current=Be[He],Be[He]=null,He--)}function I(e,t){He++,Be[He]=e.current,e.current=t}var ee=E(null),ye=E(null),_e=E(null),we=E(null);function dt(e,t){switch(I(_e,t),I(ye,e),I(ee,null),t.nodeType){case 9:case 11:e=(e=t.documentElement)&&(e=e.namespaceURI)?wd(e):0;break;default:if(e=t.tagName,t=t.namespaceURI)t=wd(t),e=Dd(t,e);else switch(e){case"svg":e=1;break;case"math":e=2;break;default:e=0}}L(ee),I(ee,e)}function ut(){L(ee),L(ye),L(_e)}function Lt(e){e.memoizedState!==null&&I(we,e);var t=ee.current,l=Dd(t,e.type);t!==l&&(I(ye,e),I(ee,l))}function yn(e){ye.current===e&&(L(ee),L(ye)),we.current===e&&(L(we),nu._currentValue=re)}var bn,In;function Pt(e){if(bn===void 0)try{throw Error()}catch(l){var t=l.stack.trim().match(/\n( *(at )?)/);bn=t&&t[1]||"",In=-1<l.stack.indexOf(`
2
- at`)?" (<anonymous>)":-1<l.stack.indexOf("@")?"@unknown:0:0":""}return`
3
- `+bn+e+In}var Yl=!1;function fl(e,t){if(!e||Yl)return"";Yl=!0;var l=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var n={DetermineComponentFrameRoot:function(){try{if(t){var G=function(){throw Error()};if(Object.defineProperty(G.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(G,[])}catch(C){var N=C}Reflect.construct(e,[],G)}else{try{G.call()}catch(C){N=C}e.call(G.prototype)}}else{try{throw Error()}catch(C){N=C}(G=e())&&typeof G.catch=="function"&&G.catch(function(){})}}catch(C){if(C&&N&&typeof C.stack=="string")return[C.stack,N.stack]}return[null,null]}};n.DetermineComponentFrameRoot.displayName="DetermineComponentFrameRoot";var r=Object.getOwnPropertyDescriptor(n.DetermineComponentFrameRoot,"name");r&&r.configurable&&Object.defineProperty(n.DetermineComponentFrameRoot,"name",{value:"DetermineComponentFrameRoot"});var o=n.DetermineComponentFrameRoot(),h=o[0],m=o[1];if(h&&m){var S=h.split(`
4
- `),O=m.split(`
5
- `);for(r=n=0;n<S.length&&!S[n].includes("DetermineComponentFrameRoot");)n++;for(;r<O.length&&!O[r].includes("DetermineComponentFrameRoot");)r++;if(n===S.length||r===O.length)for(n=S.length-1,r=O.length-1;1<=n&&0<=r&&S[n]!==O[r];)r--;for(;1<=n&&0<=r;n--,r--)if(S[n]!==O[r]){if(n!==1||r!==1)do if(n--,r--,0>r||S[n]!==O[r]){var B=`
6
- `+S[n].replace(" at new "," at ");return e.displayName&&B.includes("<anonymous>")&&(B=B.replace("<anonymous>",e.displayName)),B}while(1<=n&&0<=r);break}}}finally{Yl=!1,Error.prepareStackTrace=l}return(l=e?e.displayName||e.name:"")?Pt(l):""}function Ta(e,t){switch(e.tag){case 26:case 27:case 5:return Pt(e.type);case 16:return Pt("Lazy");case 13:return e.child!==t&&t!==null?Pt("Suspense Fallback"):Pt("Suspense");case 19:return Pt("SuspenseList");case 0:case 15:return fl(e.type,!1);case 11:return fl(e.type.render,!1);case 1:return fl(e.type,!0);case 31:return Pt("Activity");default:return""}}function vn(e){try{var t="",l=null;do t+=Ta(e,l),l=e,e=e.return;while(e);return t}catch(n){return`
7
- Error generating stack: `+n.message+`
8
- `+n.stack}}var Qt=Object.prototype.hasOwnProperty,Al=i.unstable_scheduleCallback,xn=i.unstable_cancelCallback,Pn=i.unstable_shouldYield,ea=i.unstable_requestPaint,st=i.unstable_now,kt=i.unstable_getCurrentPriorityLevel,Bt=i.unstable_ImmediatePriority,Cl=i.unstable_UserBlockingPriority,Xl=i.unstable_NormalPriority,Ql=i.unstable_LowPriority,Sn=i.unstable_IdlePriority,oi=i.log,fi=i.unstable_setDisableYieldValue,Zl=null,Ot=null;function hl(e){if(typeof oi=="function"&&fi(e),Ot&&typeof Ot.setStrictMode=="function")try{Ot.setStrictMode(Zl,e)}catch{}}var Mt=Math.clz32?Math.clz32:di,hi=Math.log,ta=Math.LN2;function di(e){return e>>>=0,e===0?32:31-(hi(e)/ta|0)|0}var el=256,Tl=262144,Vl=4194304;function V(e){var t=e&42;if(t!==0)return t;switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:return e&261888;case 262144:case 524288:case 1048576:case 2097152:return e&3932160;case 4194304:case 8388608:case 16777216:case 33554432:return e&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return e}}function v(e,t,l){var n=e.pendingLanes;if(n===0)return 0;var r=0,o=e.suspendedLanes,h=e.pingedLanes;e=e.warmLanes;var m=n&134217727;return m!==0?(n=m&~o,n!==0?r=V(n):(h&=m,h!==0?r=V(h):l||(l=m&~e,l!==0&&(r=V(l))))):(m=n&~o,m!==0?r=V(m):h!==0?r=V(h):l||(l=n&~e,l!==0&&(r=V(l)))),r===0?0:t!==0&&t!==r&&(t&o)===0&&(o=r&-r,l=t&-t,o>=l||o===32&&(l&4194048)!==0)?t:r}function M(e,t){return(e.pendingLanes&~(e.suspendedLanes&~e.pingedLanes)&t)===0}function Y(e,t){switch(e){case 1:case 2:case 4:case 8:case 64:return t+250;case 16:case 32:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t+5e3;case 4194304:case 8388608:case 16777216:case 33554432:return-1;case 67108864:case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function he(){var e=Vl;return Vl<<=1,(Vl&62914560)===0&&(Vl=4194304),e}function Ke(e){for(var t=[],l=0;31>l;l++)t.push(e);return t}function Ie(e,t){e.pendingLanes|=t,t!==268435456&&(e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0)}function ne(e,t,l,n,r,o){var h=e.pendingLanes;e.pendingLanes=l,e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0,e.expiredLanes&=l,e.entangledLanes&=l,e.errorRecoveryDisabledLanes&=l,e.shellSuspendCounter=0;var m=e.entanglements,S=e.expirationTimes,O=e.hiddenUpdates;for(l=h&~l;0<l;){var B=31-Mt(l),G=1<<B;m[B]=0,S[B]=-1;var N=O[B];if(N!==null)for(O[B]=null,B=0;B<N.length;B++){var C=N[B];C!==null&&(C.lane&=-536870913)}l&=~G}n!==0&&te(e,n,0),o!==0&&r===0&&e.tag!==0&&(e.suspendedLanes|=o&~(h&~t))}function te(e,t,l){e.pendingLanes|=t,e.suspendedLanes&=~t;var n=31-Mt(t);e.entangledLanes|=t,e.entanglements[n]=e.entanglements[n]|1073741824|l&261930}function pe(e,t){var l=e.entangledLanes|=t;for(e=e.entanglements;l;){var n=31-Mt(l),r=1<<n;r&t|e[n]&t&&(e[n]|=t),l&=~r}}function pt(e,t){var l=t&-t;return l=(l&42)!==0?1:rt(l),(l&(e.suspendedLanes|t))!==0?0:l}function rt(e){switch(e){case 2:e=1;break;case 8:e=4;break;case 32:e=16;break;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:e=128;break;case 268435456:e=134217728;break;default:e=0}return e}function Kl(e){return e&=-e,2<e?8<e?(e&134217727)!==0?32:268435456:8:2}function ja(){var e=F.p;return e!==0?e:(e=window.event,e===void 0?32:np(e.type))}function Oa(e,t){var l=F.p;try{return F.p=e,t()}finally{F.p=l}}var wl=Math.random().toString(36).slice(2),gt="__reactFiber$"+wl,Ut="__reactProps$"+wl,_n="__reactContainer$"+wl,pi="__reactEvents$"+wl,yu="__reactListeners$"+wl,Na="__reactHandles$"+wl,bu="__reactResources$"+wl,la="__reactMarker$"+wl;function gi(e){delete e[gt],delete e[Ut],delete e[pi],delete e[yu],delete e[Na]}function Gt(e){var t=e[gt];if(t)return t;for(var l=e.parentNode;l;){if(t=l[_n]||l[gt]){if(l=t.alternate,t.child!==null||l!==null&&l.child!==null)for(e=Gd(e);e!==null;){if(l=e[gt])return l;e=Gd(e)}return t}e=l,l=e.parentNode}return null}function Jl(e){if(e=e[gt]||e[_n]){var t=e.tag;if(t===5||t===6||t===13||t===31||t===26||t===27||t===3)return e}return null}function En(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e.stateNode;throw Error(s(33))}function An(e){var t=e[bu];return t||(t=e[bu]={hoistableStyles:new Map,hoistableScripts:new Map}),t}function xt(e){e[la]=!0}var vu=new Set,na={};function $l(e,t){Z(e,t),Z(e+"Capture",t)}function Z(e,t){for(na[e]=t,e=0;e<t.length;e++)vu.add(t[e])}var ue=RegExp("^[:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD][:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$"),je={},Ge={};function mt(e){return Qt.call(Ge,e)?!0:Qt.call(je,e)?!1:ue.test(e)?Ge[e]=!0:(je[e]=!0,!1)}function qt(e,t,l){if(mt(t))if(l===null)e.removeAttribute(t);else{switch(typeof l){case"undefined":case"function":case"symbol":e.removeAttribute(t);return;case"boolean":var n=t.toLowerCase().slice(0,5);if(n!=="data-"&&n!=="aria-"){e.removeAttribute(t);return}}e.setAttribute(t,""+l)}}function tl(e,t,l){if(l===null)e.removeAttribute(t);else{switch(typeof l){case"undefined":case"function":case"symbol":case"boolean":e.removeAttribute(t);return}e.setAttribute(t,""+l)}}function Zt(e,t,l,n){if(n===null)e.removeAttribute(l);else{switch(typeof n){case"undefined":case"function":case"symbol":case"boolean":e.removeAttribute(l);return}e.setAttributeNS(t,l,""+n)}}function tt(e){switch(typeof e){case"bigint":case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function ll(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function xu(e,t,l){var n=Object.getOwnPropertyDescriptor(e.constructor.prototype,t);if(!e.hasOwnProperty(t)&&typeof n<"u"&&typeof n.get=="function"&&typeof n.set=="function"){var r=n.get,o=n.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return r.call(this)},set:function(h){l=""+h,o.call(this,h)}}),Object.defineProperty(e,t,{enumerable:n.enumerable}),{getValue:function(){return l},setValue:function(h){l=""+h},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function Ma(e){if(!e._valueTracker){var t=ll(e)?"checked":"value";e._valueTracker=xu(e,t,""+e[t])}}function mi(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var l=t.getValue(),n="";return e&&(n=ll(e)?e.checked?"true":"false":e.value),e=n,e!==l?(t.setValue(e),!0):!1}function za(e){if(e=e||(typeof document<"u"?document:void 0),typeof e>"u")return null;try{return e.activeElement||e.body}catch{return e.body}}var Vs=/[\n"\\]/g;function Vt(e){return e.replace(Vs,function(t){return"\\"+t.charCodeAt(0).toString(16)+" "})}function yi(e,t,l,n,r,o,h,m){e.name="",h!=null&&typeof h!="function"&&typeof h!="symbol"&&typeof h!="boolean"?e.type=h:e.removeAttribute("type"),t!=null?h==="number"?(t===0&&e.value===""||e.value!=t)&&(e.value=""+tt(t)):e.value!==""+tt(t)&&(e.value=""+tt(t)):h!=="submit"&&h!=="reset"||e.removeAttribute("value"),t!=null?Ra(e,h,tt(t)):l!=null?Ra(e,h,tt(l)):n!=null&&e.removeAttribute("value"),r==null&&o!=null&&(e.defaultChecked=!!o),r!=null&&(e.checked=r&&typeof r!="function"&&typeof r!="symbol"),m!=null&&typeof m!="function"&&typeof m!="symbol"&&typeof m!="boolean"?e.name=""+tt(m):e.removeAttribute("name")}function aa(e,t,l,n,r,o,h,m){if(o!=null&&typeof o!="function"&&typeof o!="symbol"&&typeof o!="boolean"&&(e.type=o),t!=null||l!=null){if(!(o!=="submit"&&o!=="reset"||t!=null)){Ma(e);return}l=l!=null?""+tt(l):"",t=t!=null?""+tt(t):l,m||t===e.value||(e.value=t),e.defaultValue=t}n=n??r,n=typeof n!="function"&&typeof n!="symbol"&&!!n,e.checked=m?e.checked:!!n,e.defaultChecked=!!n,h!=null&&typeof h!="function"&&typeof h!="symbol"&&typeof h!="boolean"&&(e.name=h),Ma(e)}function Ra(e,t,l){t==="number"&&za(e.ownerDocument)===e||e.defaultValue===""+l||(e.defaultValue=""+l)}function zt(e,t,l,n){if(e=e.options,t){t={};for(var r=0;r<l.length;r++)t["$"+l[r]]=!0;for(l=0;l<e.length;l++)r=t.hasOwnProperty("$"+e[l].value),e[l].selected!==r&&(e[l].selected=r),r&&n&&(e[l].defaultSelected=!0)}else{for(l=""+tt(l),t=null,r=0;r<e.length;r++){if(e[r].value===l){e[r].selected=!0,n&&(e[r].defaultSelected=!0);return}t!==null||e[r].disabled||(t=e[r])}t!==null&&(t.selected=!0)}}function Su(e,t,l){if(t!=null&&(t=""+tt(t),t!==e.value&&(e.value=t),l==null)){e.defaultValue!==t&&(e.defaultValue=t);return}e.defaultValue=l!=null?""+tt(l):""}function Ca(e,t,l,n){if(t==null){if(n!=null){if(l!=null)throw Error(s(92));if(We(n)){if(1<n.length)throw Error(s(93));n=n[0]}l=n}l==null&&(l=""),t=l}l=tt(t),e.defaultValue=l,n=e.textContent,n===l&&n!==""&&n!==null&&(e.value=n),Ma(e)}function de(e,t){if(t){var l=e.firstChild;if(l&&l===e.lastChild&&l.nodeType===3){l.nodeValue=t;return}}e.textContent=t}var _u=new Set("animationIterationCount aspectRatio borderImageOutset borderImageSlice borderImageWidth boxFlex boxFlexGroup boxOrdinalGroup columnCount columns flex flexGrow flexPositive flexShrink flexNegative flexOrder gridArea gridRow gridRowEnd gridRowSpan gridRowStart gridColumn gridColumnEnd gridColumnSpan gridColumnStart fontWeight lineClamp lineHeight opacity order orphans scale tabSize widows zIndex zoom fillOpacity floodOpacity stopOpacity strokeDasharray strokeDashoffset strokeMiterlimit strokeOpacity strokeWidth MozAnimationIterationCount MozBoxFlex MozBoxFlexGroup MozLineClamp msAnimationIterationCount msFlex msZoom msFlexGrow msFlexNegative msFlexOrder msFlexPositive msFlexShrink msGridColumn msGridColumnSpan msGridRow msGridRowSpan WebkitAnimationIterationCount WebkitBoxFlex WebKitBoxFlexGroup WebkitBoxOrdinalGroup WebkitColumnCount WebkitColumns WebkitFlex WebkitFlexGrow WebkitFlexPositive WebkitFlexShrink WebkitLineClamp".split(" "));function St(e,t,l){var n=t.indexOf("--")===0;l==null||typeof l=="boolean"||l===""?n?e.setProperty(t,""):t==="float"?e.cssFloat="":e[t]="":n?e.setProperty(t,l):typeof l!="number"||l===0||_u.has(t)?t==="float"?e.cssFloat=l:e[t]=(""+l).trim():e[t]=l+"px"}function Ye(e,t,l){if(t!=null&&typeof t!="object")throw Error(s(62));if(e=e.style,l!=null){for(var n in l)!l.hasOwnProperty(n)||t!=null&&t.hasOwnProperty(n)||(n.indexOf("--")===0?e.setProperty(n,""):n==="float"?e.cssFloat="":e[n]="");for(var r in t)n=t[r],t.hasOwnProperty(r)&&l[r]!==n&&St(e,r,n)}else for(var o in t)t.hasOwnProperty(o)&&St(e,o,t[o])}function Tn(e){if(e.indexOf("-")===-1)return!1;switch(e){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var Fl=new Map([["acceptCharset","accept-charset"],["htmlFor","for"],["httpEquiv","http-equiv"],["crossOrigin","crossorigin"],["accentHeight","accent-height"],["alignmentBaseline","alignment-baseline"],["arabicForm","arabic-form"],["baselineShift","baseline-shift"],["capHeight","cap-height"],["clipPath","clip-path"],["clipRule","clip-rule"],["colorInterpolation","color-interpolation"],["colorInterpolationFilters","color-interpolation-filters"],["colorProfile","color-profile"],["colorRendering","color-rendering"],["dominantBaseline","dominant-baseline"],["enableBackground","enable-background"],["fillOpacity","fill-opacity"],["fillRule","fill-rule"],["floodColor","flood-color"],["floodOpacity","flood-opacity"],["fontFamily","font-family"],["fontSize","font-size"],["fontSizeAdjust","font-size-adjust"],["fontStretch","font-stretch"],["fontStyle","font-style"],["fontVariant","font-variant"],["fontWeight","font-weight"],["glyphName","glyph-name"],["glyphOrientationHorizontal","glyph-orientation-horizontal"],["glyphOrientationVertical","glyph-orientation-vertical"],["horizAdvX","horiz-adv-x"],["horizOriginX","horiz-origin-x"],["imageRendering","image-rendering"],["letterSpacing","letter-spacing"],["lightingColor","lighting-color"],["markerEnd","marker-end"],["markerMid","marker-mid"],["markerStart","marker-start"],["overlinePosition","overline-position"],["overlineThickness","overline-thickness"],["paintOrder","paint-order"],["panose-1","panose-1"],["pointerEvents","pointer-events"],["renderingIntent","rendering-intent"],["shapeRendering","shape-rendering"],["stopColor","stop-color"],["stopOpacity","stop-opacity"],["strikethroughPosition","strikethrough-position"],["strikethroughThickness","strikethrough-thickness"],["strokeDasharray","stroke-dasharray"],["strokeDashoffset","stroke-dashoffset"],["strokeLinecap","stroke-linecap"],["strokeLinejoin","stroke-linejoin"],["strokeMiterlimit","stroke-miterlimit"],["strokeOpacity","stroke-opacity"],["strokeWidth","stroke-width"],["textAnchor","text-anchor"],["textDecoration","text-decoration"],["textRendering","text-rendering"],["transformOrigin","transform-origin"],["underlinePosition","underline-position"],["underlineThickness","underline-thickness"],["unicodeBidi","unicode-bidi"],["unicodeRange","unicode-range"],["unitsPerEm","units-per-em"],["vAlphabetic","v-alphabetic"],["vHanging","v-hanging"],["vIdeographic","v-ideographic"],["vMathematical","v-mathematical"],["vectorEffect","vector-effect"],["vertAdvY","vert-adv-y"],["vertOriginX","vert-origin-x"],["vertOriginY","vert-origin-y"],["wordSpacing","word-spacing"],["writingMode","writing-mode"],["xmlnsXlink","xmlns:xlink"],["xHeight","x-height"]]),bi=/^[\u0000-\u001F ]*j[\r\n\t]*a[\r\n\t]*v[\r\n\t]*a[\r\n\t]*s[\r\n\t]*c[\r\n\t]*r[\r\n\t]*i[\r\n\t]*p[\r\n\t]*t[\r\n\t]*:/i;function jn(e){return bi.test(""+e)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":e}function J(){}var ae=null;function Ee(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var ze=null,ot=null;function dl(e){var t=Jl(e);if(t&&(e=t.stateNode)){var l=e[Ut]||null;e:switch(e=t.stateNode,t.type){case"input":if(yi(e,l.value,l.defaultValue,l.defaultValue,l.checked,l.defaultChecked,l.type,l.name),t=l.name,l.type==="radio"&&t!=null){for(l=e;l.parentNode;)l=l.parentNode;for(l=l.querySelectorAll('input[name="'+Vt(""+t)+'"][type="radio"]'),t=0;t<l.length;t++){var n=l[t];if(n!==e&&n.form===e.form){var r=n[Ut]||null;if(!r)throw Error(s(90));yi(n,r.value,r.defaultValue,r.defaultValue,r.checked,r.defaultChecked,r.type,r.name)}}for(t=0;t<l.length;t++)n=l[t],n.form===e.form&&mi(n)}break e;case"textarea":Su(e,l.value,l.defaultValue);break e;case"select":t=l.value,t!=null&&zt(e,!!l.multiple,t,!1)}}}var vi=!1;function Eu(e,t,l){if(vi)return e(t,l);vi=!0;try{var n=e(t);return n}finally{if(vi=!1,(ze!==null||ot!==null)&&(os(),ze&&(t=ze,e=ot,ot=ze=null,dl(t),e)))for(t=0;t<e.length;t++)dl(e[t])}}function xi(e,t){var l=e.stateNode;if(l===null)return null;var n=l[Ut]||null;if(n===null)return null;l=n[t];e:switch(t){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(n=!n.disabled)||(e=e.type,n=!(e==="button"||e==="input"||e==="select"||e==="textarea")),e=!n;break e;default:e=!1}if(e)return null;if(l&&typeof l!="function")throw Error(s(231,t,typeof l));return l}var Wl=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),Ks=!1;if(Wl)try{var Si={};Object.defineProperty(Si,"passive",{get:function(){Ks=!0}}),window.addEventListener("test",Si,Si),window.removeEventListener("test",Si,Si)}catch{Ks=!1}var On=null,Js=null,Au=null;function wo(){if(Au)return Au;var e,t=Js,l=t.length,n,r="value"in On?On.value:On.textContent,o=r.length;for(e=0;e<l&&t[e]===r[e];e++);var h=l-e;for(n=1;n<=h&&t[l-n]===r[o-n];n++);return Au=r.slice(e,1<n?1-n:void 0)}function Tu(e){var t=e.keyCode;return"charCode"in e?(e=e.charCode,e===0&&t===13&&(e=13)):e=t,e===10&&(e=13),32<=e||e===13?e:0}function ju(){return!0}function Do(){return!1}function Kt(e){function t(l,n,r,o,h){this._reactName=l,this._targetInst=r,this.type=n,this.nativeEvent=o,this.target=h,this.currentTarget=null;for(var m in e)e.hasOwnProperty(m)&&(l=e[m],this[m]=l?l(o):o[m]);return this.isDefaultPrevented=(o.defaultPrevented!=null?o.defaultPrevented:o.returnValue===!1)?ju:Do,this.isPropagationStopped=Do,this}return A(t.prototype,{preventDefault:function(){this.defaultPrevented=!0;var l=this.nativeEvent;l&&(l.preventDefault?l.preventDefault():typeof l.returnValue!="unknown"&&(l.returnValue=!1),this.isDefaultPrevented=ju)},stopPropagation:function(){var l=this.nativeEvent;l&&(l.stopPropagation?l.stopPropagation():typeof l.cancelBubble!="unknown"&&(l.cancelBubble=!0),this.isPropagationStopped=ju)},persist:function(){},isPersistent:ju}),t}var ia={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},Ou=Kt(ia),_i=A({},ia,{view:0,detail:0}),Ag=Kt(_i),$s,Fs,Ei,Nu=A({},_i,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:Is,button:0,buttons:0,relatedTarget:function(e){return e.relatedTarget===void 0?e.fromElement===e.srcElement?e.toElement:e.fromElement:e.relatedTarget},movementX:function(e){return"movementX"in e?e.movementX:(e!==Ei&&(Ei&&e.type==="mousemove"?($s=e.screenX-Ei.screenX,Fs=e.screenY-Ei.screenY):Fs=$s=0,Ei=e),$s)},movementY:function(e){return"movementY"in e?e.movementY:Fs}}),ko=Kt(Nu),Tg=A({},Nu,{dataTransfer:0}),jg=Kt(Tg),Og=A({},_i,{relatedTarget:0}),Ws=Kt(Og),Ng=A({},ia,{animationName:0,elapsedTime:0,pseudoElement:0}),Mg=Kt(Ng),zg=A({},ia,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),Rg=Kt(zg),Cg=A({},ia,{data:0}),Bo=Kt(Cg),wg={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},Dg={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"},kg={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function Bg(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=kg[e])?!!t[e]:!1}function Is(){return Bg}var Ug=A({},_i,{key:function(e){if(e.key){var t=wg[e.key]||e.key;if(t!=="Unidentified")return t}return e.type==="keypress"?(e=Tu(e),e===13?"Enter":String.fromCharCode(e)):e.type==="keydown"||e.type==="keyup"?Dg[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:Is,charCode:function(e){return e.type==="keypress"?Tu(e):0},keyCode:function(e){return e.type==="keydown"||e.type==="keyup"?e.keyCode:0},which:function(e){return e.type==="keypress"?Tu(e):e.type==="keydown"||e.type==="keyup"?e.keyCode:0}}),qg=Kt(Ug),Hg=A({},Nu,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),Uo=Kt(Hg),Lg=A({},_i,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:Is}),Gg=Kt(Lg),Yg=A({},ia,{propertyName:0,elapsedTime:0,pseudoElement:0}),Xg=Kt(Yg),Qg=A({},Nu,{deltaX:function(e){return"deltaX"in e?e.deltaX:"wheelDeltaX"in e?-e.wheelDeltaX:0},deltaY:function(e){return"deltaY"in e?e.deltaY:"wheelDeltaY"in e?-e.wheelDeltaY:"wheelDelta"in e?-e.wheelDelta:0},deltaZ:0,deltaMode:0}),Zg=Kt(Qg),Vg=A({},ia,{newState:0,oldState:0}),Kg=Kt(Vg),Jg=[9,13,27,32],Ps=Wl&&"CompositionEvent"in window,Ai=null;Wl&&"documentMode"in document&&(Ai=document.documentMode);var $g=Wl&&"TextEvent"in window&&!Ai,qo=Wl&&(!Ps||Ai&&8<Ai&&11>=Ai),Ho=" ",Lo=!1;function Go(e,t){switch(e){case"keyup":return Jg.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function Yo(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var wa=!1;function Fg(e,t){switch(e){case"compositionend":return Yo(t);case"keypress":return t.which!==32?null:(Lo=!0,Ho);case"textInput":return e=t.data,e===Ho&&Lo?null:e;default:return null}}function Wg(e,t){if(wa)return e==="compositionend"||!Ps&&Go(e,t)?(e=wo(),Au=Js=On=null,wa=!1,e):null;switch(e){case"paste":return null;case"keypress":if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1<t.char.length)return t.char;if(t.which)return String.fromCharCode(t.which)}return null;case"compositionend":return qo&&t.locale!=="ko"?null:t.data;default:return null}}var Ig={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 Xo(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t==="input"?!!Ig[e.type]:t==="textarea"}function Qo(e,t,l,n){ze?ot?ot.push(n):ot=[n]:ze=n,t=ys(t,"onChange"),0<t.length&&(l=new Ou("onChange","change",null,l,n),e.push({event:l,listeners:t}))}var Ti=null,ji=null;function Pg(e){Od(e,0)}function Mu(e){var t=En(e);if(mi(t))return e}function Zo(e,t){if(e==="change")return t}var Vo=!1;if(Wl){var er;if(Wl){var tr="oninput"in document;if(!tr){var Ko=document.createElement("div");Ko.setAttribute("oninput","return;"),tr=typeof Ko.oninput=="function"}er=tr}else er=!1;Vo=er&&(!document.documentMode||9<document.documentMode)}function Jo(){Ti&&(Ti.detachEvent("onpropertychange",$o),ji=Ti=null)}function $o(e){if(e.propertyName==="value"&&Mu(ji)){var t=[];Qo(t,ji,e,Ee(e)),Eu(Pg,t)}}function em(e,t,l){e==="focusin"?(Jo(),Ti=t,ji=l,Ti.attachEvent("onpropertychange",$o)):e==="focusout"&&Jo()}function tm(e){if(e==="selectionchange"||e==="keyup"||e==="keydown")return Mu(ji)}function lm(e,t){if(e==="click")return Mu(t)}function nm(e,t){if(e==="input"||e==="change")return Mu(t)}function am(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var nl=typeof Object.is=="function"?Object.is:am;function Oi(e,t){if(nl(e,t))return!0;if(typeof e!="object"||e===null||typeof t!="object"||t===null)return!1;var l=Object.keys(e),n=Object.keys(t);if(l.length!==n.length)return!1;for(n=0;n<l.length;n++){var r=l[n];if(!Qt.call(t,r)||!nl(e[r],t[r]))return!1}return!0}function Fo(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function Wo(e,t){var l=Fo(e);e=0;for(var n;l;){if(l.nodeType===3){if(n=e+l.textContent.length,e<=t&&n>=t)return{node:l,offset:t-e};e=n}e:{for(;l;){if(l.nextSibling){l=l.nextSibling;break e}l=l.parentNode}l=void 0}l=Fo(l)}}function Io(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?Io(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function Po(e){e=e!=null&&e.ownerDocument!=null&&e.ownerDocument.defaultView!=null?e.ownerDocument.defaultView:window;for(var t=za(e.document);t instanceof e.HTMLIFrameElement;){try{var l=typeof t.contentWindow.location.href=="string"}catch{l=!1}if(l)e=t.contentWindow;else break;t=za(e.document)}return t}function lr(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t==="input"&&(e.type==="text"||e.type==="search"||e.type==="tel"||e.type==="url"||e.type==="password")||t==="textarea"||e.contentEditable==="true")}var im=Wl&&"documentMode"in document&&11>=document.documentMode,Da=null,nr=null,Ni=null,ar=!1;function ef(e,t,l){var n=l.window===l?l.document:l.nodeType===9?l:l.ownerDocument;ar||Da==null||Da!==za(n)||(n=Da,"selectionStart"in n&&lr(n)?n={start:n.selectionStart,end:n.selectionEnd}:(n=(n.ownerDocument&&n.ownerDocument.defaultView||window).getSelection(),n={anchorNode:n.anchorNode,anchorOffset:n.anchorOffset,focusNode:n.focusNode,focusOffset:n.focusOffset}),Ni&&Oi(Ni,n)||(Ni=n,n=ys(nr,"onSelect"),0<n.length&&(t=new Ou("onSelect","select",null,t,l),e.push({event:t,listeners:n}),t.target=Da)))}function ua(e,t){var l={};return l[e.toLowerCase()]=t.toLowerCase(),l["Webkit"+e]="webkit"+t,l["Moz"+e]="moz"+t,l}var ka={animationend:ua("Animation","AnimationEnd"),animationiteration:ua("Animation","AnimationIteration"),animationstart:ua("Animation","AnimationStart"),transitionrun:ua("Transition","TransitionRun"),transitionstart:ua("Transition","TransitionStart"),transitioncancel:ua("Transition","TransitionCancel"),transitionend:ua("Transition","TransitionEnd")},ir={},tf={};Wl&&(tf=document.createElement("div").style,"AnimationEvent"in window||(delete ka.animationend.animation,delete ka.animationiteration.animation,delete ka.animationstart.animation),"TransitionEvent"in window||delete ka.transitionend.transition);function sa(e){if(ir[e])return ir[e];if(!ka[e])return e;var t=ka[e],l;for(l in t)if(t.hasOwnProperty(l)&&l in tf)return ir[e]=t[l];return e}var lf=sa("animationend"),nf=sa("animationiteration"),af=sa("animationstart"),um=sa("transitionrun"),sm=sa("transitionstart"),rm=sa("transitioncancel"),uf=sa("transitionend"),sf=new Map,ur="abort auxClick beforeToggle cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel".split(" ");ur.push("scrollEnd");function jl(e,t){sf.set(e,t),$l(t,[e])}var zu=typeof reportError=="function"?reportError:function(e){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var t=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof e=="object"&&e!==null&&typeof e.message=="string"?String(e.message):String(e),error:e});if(!window.dispatchEvent(t))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",e);return}console.error(e)},pl=[],Ba=0,sr=0;function Ru(){for(var e=Ba,t=sr=Ba=0;t<e;){var l=pl[t];pl[t++]=null;var n=pl[t];pl[t++]=null;var r=pl[t];pl[t++]=null;var o=pl[t];if(pl[t++]=null,n!==null&&r!==null){var h=n.pending;h===null?r.next=r:(r.next=h.next,h.next=r),n.pending=r}o!==0&&rf(l,r,o)}}function Cu(e,t,l,n){pl[Ba++]=e,pl[Ba++]=t,pl[Ba++]=l,pl[Ba++]=n,sr|=n,e.lanes|=n,e=e.alternate,e!==null&&(e.lanes|=n)}function rr(e,t,l,n){return Cu(e,t,l,n),wu(e)}function ra(e,t){return Cu(e,null,null,t),wu(e)}function rf(e,t,l){e.lanes|=l;var n=e.alternate;n!==null&&(n.lanes|=l);for(var r=!1,o=e.return;o!==null;)o.childLanes|=l,n=o.alternate,n!==null&&(n.childLanes|=l),o.tag===22&&(e=o.stateNode,e===null||e._visibility&1||(r=!0)),e=o,o=o.return;return e.tag===3?(o=e.stateNode,r&&t!==null&&(r=31-Mt(l),e=o.hiddenUpdates,n=e[r],n===null?e[r]=[t]:n.push(t),t.lane=l|536870912),o):null}function wu(e){if(50<Fi)throw Fi=0,yc=null,Error(s(185));for(var t=e.return;t!==null;)e=t,t=e.return;return e.tag===3?e.stateNode:null}var Ua={};function cm(e,t,l,n){this.tag=e,this.key=l,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=n,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function al(e,t,l,n){return new cm(e,t,l,n)}function cr(e){return e=e.prototype,!(!e||!e.isReactComponent)}function Il(e,t){var l=e.alternate;return l===null?(l=al(e.tag,t,e.key,e.mode),l.elementType=e.elementType,l.type=e.type,l.stateNode=e.stateNode,l.alternate=e,e.alternate=l):(l.pendingProps=t,l.type=e.type,l.flags=0,l.subtreeFlags=0,l.deletions=null),l.flags=e.flags&65011712,l.childLanes=e.childLanes,l.lanes=e.lanes,l.child=e.child,l.memoizedProps=e.memoizedProps,l.memoizedState=e.memoizedState,l.updateQueue=e.updateQueue,t=e.dependencies,l.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},l.sibling=e.sibling,l.index=e.index,l.ref=e.ref,l.refCleanup=e.refCleanup,l}function cf(e,t){e.flags&=65011714;var l=e.alternate;return l===null?(e.childLanes=0,e.lanes=t,e.child=null,e.subtreeFlags=0,e.memoizedProps=null,e.memoizedState=null,e.updateQueue=null,e.dependencies=null,e.stateNode=null):(e.childLanes=l.childLanes,e.lanes=l.lanes,e.child=l.child,e.subtreeFlags=0,e.deletions=null,e.memoizedProps=l.memoizedProps,e.memoizedState=l.memoizedState,e.updateQueue=l.updateQueue,e.type=l.type,t=l.dependencies,e.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext}),e}function Du(e,t,l,n,r,o){var h=0;if(n=e,typeof e=="function")cr(e)&&(h=1);else if(typeof e=="string")h=py(e,l,ee.current)?26:e==="html"||e==="head"||e==="body"?27:5;else e:switch(e){case P:return e=al(31,l,t,r),e.elementType=P,e.lanes=o,e;case $:return ca(l.children,r,o,t);case X:h=8,r|=24;break;case K:return e=al(12,l,t,r|2),e.elementType=K,e.lanes=o,e;case oe:return e=al(13,l,t,r),e.elementType=oe,e.lanes=o,e;case ve:return e=al(19,l,t,r),e.elementType=ve,e.lanes=o,e;default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case be:h=10;break e;case se:h=9;break e;case Se:h=11;break e;case R:h=14;break e;case w:h=16,n=null;break e}h=29,l=Error(s(130,e===null?"null":typeof e,"")),n=null}return t=al(h,l,t,r),t.elementType=e,t.type=n,t.lanes=o,t}function ca(e,t,l,n){return e=al(7,e,n,t),e.lanes=l,e}function or(e,t,l){return e=al(6,e,null,t),e.lanes=l,e}function of(e){var t=al(18,null,null,0);return t.stateNode=e,t}function fr(e,t,l){return t=al(4,e.children!==null?e.children:[],e.key,t),t.lanes=l,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}var ff=new WeakMap;function gl(e,t){if(typeof e=="object"&&e!==null){var l=ff.get(e);return l!==void 0?l:(t={value:e,source:t,stack:vn(t)},ff.set(e,t),t)}return{value:e,source:t,stack:vn(t)}}var qa=[],Ha=0,ku=null,Mi=0,ml=[],yl=0,Nn=null,Dl=1,kl="";function Pl(e,t){qa[Ha++]=Mi,qa[Ha++]=ku,ku=e,Mi=t}function hf(e,t,l){ml[yl++]=Dl,ml[yl++]=kl,ml[yl++]=Nn,Nn=e;var n=Dl;e=kl;var r=32-Mt(n)-1;n&=~(1<<r),l+=1;var o=32-Mt(t)+r;if(30<o){var h=r-r%5;o=(n&(1<<h)-1).toString(32),n>>=h,r-=h,Dl=1<<32-Mt(t)+r|l<<r|n,kl=o+e}else Dl=1<<o|l<<r|n,kl=e}function hr(e){e.return!==null&&(Pl(e,1),hf(e,1,0))}function dr(e){for(;e===ku;)ku=qa[--Ha],qa[Ha]=null,Mi=qa[--Ha],qa[Ha]=null;for(;e===Nn;)Nn=ml[--yl],ml[yl]=null,kl=ml[--yl],ml[yl]=null,Dl=ml[--yl],ml[yl]=null}function df(e,t){ml[yl++]=Dl,ml[yl++]=kl,ml[yl++]=Nn,Dl=t.id,kl=t.overflow,Nn=e}var Rt=null,nt=null,De=!1,Mn=null,bl=!1,pr=Error(s(519));function zn(e){var t=Error(s(418,1<arguments.length&&arguments[1]!==void 0&&arguments[1]?"text":"HTML",""));throw zi(gl(t,e)),pr}function pf(e){var t=e.stateNode,l=e.type,n=e.memoizedProps;switch(t[gt]=e,t[Ut]=n,l){case"dialog":Ne("cancel",t),Ne("close",t);break;case"iframe":case"object":case"embed":Ne("load",t);break;case"video":case"audio":for(l=0;l<Ii.length;l++)Ne(Ii[l],t);break;case"source":Ne("error",t);break;case"img":case"image":case"link":Ne("error",t),Ne("load",t);break;case"details":Ne("toggle",t);break;case"input":Ne("invalid",t),aa(t,n.value,n.defaultValue,n.checked,n.defaultChecked,n.type,n.name,!0);break;case"select":Ne("invalid",t);break;case"textarea":Ne("invalid",t),Ca(t,n.value,n.defaultValue,n.children)}l=n.children,typeof l!="string"&&typeof l!="number"&&typeof l!="bigint"||t.textContent===""+l||n.suppressHydrationWarning===!0||Rd(t.textContent,l)?(n.popover!=null&&(Ne("beforetoggle",t),Ne("toggle",t)),n.onScroll!=null&&Ne("scroll",t),n.onScrollEnd!=null&&Ne("scrollend",t),n.onClick!=null&&(t.onclick=J),t=!0):t=!1,t||zn(e,!0)}function gf(e){for(Rt=e.return;Rt;)switch(Rt.tag){case 5:case 31:case 13:bl=!1;return;case 27:case 3:bl=!0;return;default:Rt=Rt.return}}function La(e){if(e!==Rt)return!1;if(!De)return gf(e),De=!0,!1;var t=e.tag,l;if((l=t!==3&&t!==27)&&((l=t===5)&&(l=e.type,l=!(l!=="form"&&l!=="button")||Cc(e.type,e.memoizedProps)),l=!l),l&&nt&&zn(e),gf(e),t===13){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(s(317));nt=Ld(e)}else if(t===31){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(s(317));nt=Ld(e)}else t===27?(t=nt,Qn(e.type)?(e=Uc,Uc=null,nt=e):nt=t):nt=Rt?xl(e.stateNode.nextSibling):null;return!0}function oa(){nt=Rt=null,De=!1}function gr(){var e=Mn;return e!==null&&(Wt===null?Wt=e:Wt.push.apply(Wt,e),Mn=null),e}function zi(e){Mn===null?Mn=[e]:Mn.push(e)}var mr=E(null),fa=null,en=null;function Rn(e,t,l){I(mr,t._currentValue),t._currentValue=l}function tn(e){e._currentValue=mr.current,L(mr)}function yr(e,t,l){for(;e!==null;){var n=e.alternate;if((e.childLanes&t)!==t?(e.childLanes|=t,n!==null&&(n.childLanes|=t)):n!==null&&(n.childLanes&t)!==t&&(n.childLanes|=t),e===l)break;e=e.return}}function br(e,t,l,n){var r=e.child;for(r!==null&&(r.return=e);r!==null;){var o=r.dependencies;if(o!==null){var h=r.child;o=o.firstContext;e:for(;o!==null;){var m=o;o=r;for(var S=0;S<t.length;S++)if(m.context===t[S]){o.lanes|=l,m=o.alternate,m!==null&&(m.lanes|=l),yr(o.return,l,e),n||(h=null);break e}o=m.next}}else if(r.tag===18){if(h=r.return,h===null)throw Error(s(341));h.lanes|=l,o=h.alternate,o!==null&&(o.lanes|=l),yr(h,l,e),h=null}else h=r.child;if(h!==null)h.return=r;else for(h=r;h!==null;){if(h===e){h=null;break}if(r=h.sibling,r!==null){r.return=h.return,h=r;break}h=h.return}r=h}}function Ga(e,t,l,n){e=null;for(var r=t,o=!1;r!==null;){if(!o){if((r.flags&524288)!==0)o=!0;else if((r.flags&262144)!==0)break}if(r.tag===10){var h=r.alternate;if(h===null)throw Error(s(387));if(h=h.memoizedProps,h!==null){var m=r.type;nl(r.pendingProps.value,h.value)||(e!==null?e.push(m):e=[m])}}else if(r===we.current){if(h=r.alternate,h===null)throw Error(s(387));h.memoizedState.memoizedState!==r.memoizedState.memoizedState&&(e!==null?e.push(nu):e=[nu])}r=r.return}e!==null&&br(t,e,l,n),t.flags|=262144}function Bu(e){for(e=e.firstContext;e!==null;){if(!nl(e.context._currentValue,e.memoizedValue))return!0;e=e.next}return!1}function ha(e){fa=e,en=null,e=e.dependencies,e!==null&&(e.firstContext=null)}function Ct(e){return mf(fa,e)}function Uu(e,t){return fa===null&&ha(e),mf(e,t)}function mf(e,t){var l=t._currentValue;if(t={context:t,memoizedValue:l,next:null},en===null){if(e===null)throw Error(s(308));en=t,e.dependencies={lanes:0,firstContext:t},e.flags|=524288}else en=en.next=t;return l}var om=typeof AbortController<"u"?AbortController:function(){var e=[],t=this.signal={aborted:!1,addEventListener:function(l,n){e.push(n)}};this.abort=function(){t.aborted=!0,e.forEach(function(l){return l()})}},fm=i.unstable_scheduleCallback,hm=i.unstable_NormalPriority,_t={$$typeof:be,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function vr(){return{controller:new om,data:new Map,refCount:0}}function Ri(e){e.refCount--,e.refCount===0&&fm(hm,function(){e.controller.abort()})}var Ci=null,xr=0,Ya=0,Xa=null;function dm(e,t){if(Ci===null){var l=Ci=[];xr=0,Ya=Ec(),Xa={status:"pending",value:void 0,then:function(n){l.push(n)}}}return xr++,t.then(yf,yf),t}function yf(){if(--xr===0&&Ci!==null){Xa!==null&&(Xa.status="fulfilled");var e=Ci;Ci=null,Ya=0,Xa=null;for(var t=0;t<e.length;t++)(0,e[t])()}}function pm(e,t){var l=[],n={status:"pending",value:null,reason:null,then:function(r){l.push(r)}};return e.then(function(){n.status="fulfilled",n.value=t;for(var r=0;r<l.length;r++)(0,l[r])(t)},function(r){for(n.status="rejected",n.reason=r,r=0;r<l.length;r++)(0,l[r])(void 0)}),n}var bf=D.S;D.S=function(e,t){td=st(),typeof t=="object"&&t!==null&&typeof t.then=="function"&&dm(e,t),bf!==null&&bf(e,t)};var da=E(null);function Sr(){var e=da.current;return e!==null?e:Pe.pooledCache}function qu(e,t){t===null?I(da,da.current):I(da,t.pool)}function vf(){var e=Sr();return e===null?null:{parent:_t._currentValue,pool:e}}var Qa=Error(s(460)),_r=Error(s(474)),Hu=Error(s(542)),Lu={then:function(){}};function xf(e){return e=e.status,e==="fulfilled"||e==="rejected"}function Sf(e,t,l){switch(l=e[l],l===void 0?e.push(t):l!==t&&(t.then(J,J),t=l),t.status){case"fulfilled":return t.value;case"rejected":throw e=t.reason,Ef(e),e;default:if(typeof t.status=="string")t.then(J,J);else{if(e=Pe,e!==null&&100<e.shellSuspendCounter)throw Error(s(482));e=t,e.status="pending",e.then(function(n){if(t.status==="pending"){var r=t;r.status="fulfilled",r.value=n}},function(n){if(t.status==="pending"){var r=t;r.status="rejected",r.reason=n}})}switch(t.status){case"fulfilled":return t.value;case"rejected":throw e=t.reason,Ef(e),e}throw ga=t,Qa}}function pa(e){try{var t=e._init;return t(e._payload)}catch(l){throw l!==null&&typeof l=="object"&&typeof l.then=="function"?(ga=l,Qa):l}}var ga=null;function _f(){if(ga===null)throw Error(s(459));var e=ga;return ga=null,e}function Ef(e){if(e===Qa||e===Hu)throw Error(s(483))}var Za=null,wi=0;function Gu(e){var t=wi;return wi+=1,Za===null&&(Za=[]),Sf(Za,e,t)}function Di(e,t){t=t.props.ref,e.ref=t!==void 0?t:null}function Yu(e,t){throw t.$$typeof===z?Error(s(525)):(e=Object.prototype.toString.call(t),Error(s(31,e==="[object Object]"?"object with keys {"+Object.keys(t).join(", ")+"}":e)))}function Af(e){function t(T,_){if(e){var j=T.deletions;j===null?(T.deletions=[_],T.flags|=16):j.push(_)}}function l(T,_){if(!e)return null;for(;_!==null;)t(T,_),_=_.sibling;return null}function n(T){for(var _=new Map;T!==null;)T.key!==null?_.set(T.key,T):_.set(T.index,T),T=T.sibling;return _}function r(T,_){return T=Il(T,_),T.index=0,T.sibling=null,T}function o(T,_,j){return T.index=j,e?(j=T.alternate,j!==null?(j=j.index,j<_?(T.flags|=67108866,_):j):(T.flags|=67108866,_)):(T.flags|=1048576,_)}function h(T){return e&&T.alternate===null&&(T.flags|=67108866),T}function m(T,_,j,H){return _===null||_.tag!==6?(_=or(j,T.mode,H),_.return=T,_):(_=r(_,j),_.return=T,_)}function S(T,_,j,H){var ce=j.type;return ce===$?B(T,_,j.props.children,H,j.key):_!==null&&(_.elementType===ce||typeof ce=="object"&&ce!==null&&ce.$$typeof===w&&pa(ce)===_.type)?(_=r(_,j.props),Di(_,j),_.return=T,_):(_=Du(j.type,j.key,j.props,null,T.mode,H),Di(_,j),_.return=T,_)}function O(T,_,j,H){return _===null||_.tag!==4||_.stateNode.containerInfo!==j.containerInfo||_.stateNode.implementation!==j.implementation?(_=fr(j,T.mode,H),_.return=T,_):(_=r(_,j.children||[]),_.return=T,_)}function B(T,_,j,H,ce){return _===null||_.tag!==7?(_=ca(j,T.mode,H,ce),_.return=T,_):(_=r(_,j),_.return=T,_)}function G(T,_,j){if(typeof _=="string"&&_!==""||typeof _=="number"||typeof _=="bigint")return _=or(""+_,T.mode,j),_.return=T,_;if(typeof _=="object"&&_!==null){switch(_.$$typeof){case q:return j=Du(_.type,_.key,_.props,null,T.mode,j),Di(j,_),j.return=T,j;case Q:return _=fr(_,T.mode,j),_.return=T,_;case w:return _=pa(_),G(T,_,j)}if(We(_)||me(_))return _=ca(_,T.mode,j,null),_.return=T,_;if(typeof _.then=="function")return G(T,Gu(_),j);if(_.$$typeof===be)return G(T,Uu(T,_),j);Yu(T,_)}return null}function N(T,_,j,H){var ce=_!==null?_.key:null;if(typeof j=="string"&&j!==""||typeof j=="number"||typeof j=="bigint")return ce!==null?null:m(T,_,""+j,H);if(typeof j=="object"&&j!==null){switch(j.$$typeof){case q:return j.key===ce?S(T,_,j,H):null;case Q:return j.key===ce?O(T,_,j,H):null;case w:return j=pa(j),N(T,_,j,H)}if(We(j)||me(j))return ce!==null?null:B(T,_,j,H,null);if(typeof j.then=="function")return N(T,_,Gu(j),H);if(j.$$typeof===be)return N(T,_,Uu(T,j),H);Yu(T,j)}return null}function C(T,_,j,H,ce){if(typeof H=="string"&&H!==""||typeof H=="number"||typeof H=="bigint")return T=T.get(j)||null,m(_,T,""+H,ce);if(typeof H=="object"&&H!==null){switch(H.$$typeof){case q:return T=T.get(H.key===null?j:H.key)||null,S(_,T,H,ce);case Q:return T=T.get(H.key===null?j:H.key)||null,O(_,T,H,ce);case w:return H=pa(H),C(T,_,j,H,ce)}if(We(H)||me(H))return T=T.get(j)||null,B(_,T,H,ce,null);if(typeof H.then=="function")return C(T,_,j,Gu(H),ce);if(H.$$typeof===be)return C(T,_,j,Uu(_,H),ce);Yu(_,H)}return null}function le(T,_,j,H){for(var ce=null,Ue=null,ie=_,Te=_=0,Ce=null;ie!==null&&Te<j.length;Te++){ie.index>Te?(Ce=ie,ie=null):Ce=ie.sibling;var qe=N(T,ie,j[Te],H);if(qe===null){ie===null&&(ie=Ce);break}e&&ie&&qe.alternate===null&&t(T,ie),_=o(qe,_,Te),Ue===null?ce=qe:Ue.sibling=qe,Ue=qe,ie=Ce}if(Te===j.length)return l(T,ie),De&&Pl(T,Te),ce;if(ie===null){for(;Te<j.length;Te++)ie=G(T,j[Te],H),ie!==null&&(_=o(ie,_,Te),Ue===null?ce=ie:Ue.sibling=ie,Ue=ie);return De&&Pl(T,Te),ce}for(ie=n(ie);Te<j.length;Te++)Ce=C(ie,T,Te,j[Te],H),Ce!==null&&(e&&Ce.alternate!==null&&ie.delete(Ce.key===null?Te:Ce.key),_=o(Ce,_,Te),Ue===null?ce=Ce:Ue.sibling=Ce,Ue=Ce);return e&&ie.forEach(function($n){return t(T,$n)}),De&&Pl(T,Te),ce}function fe(T,_,j,H){if(j==null)throw Error(s(151));for(var ce=null,Ue=null,ie=_,Te=_=0,Ce=null,qe=j.next();ie!==null&&!qe.done;Te++,qe=j.next()){ie.index>Te?(Ce=ie,ie=null):Ce=ie.sibling;var $n=N(T,ie,qe.value,H);if($n===null){ie===null&&(ie=Ce);break}e&&ie&&$n.alternate===null&&t(T,ie),_=o($n,_,Te),Ue===null?ce=$n:Ue.sibling=$n,Ue=$n,ie=Ce}if(qe.done)return l(T,ie),De&&Pl(T,Te),ce;if(ie===null){for(;!qe.done;Te++,qe=j.next())qe=G(T,qe.value,H),qe!==null&&(_=o(qe,_,Te),Ue===null?ce=qe:Ue.sibling=qe,Ue=qe);return De&&Pl(T,Te),ce}for(ie=n(ie);!qe.done;Te++,qe=j.next())qe=C(ie,T,Te,qe.value,H),qe!==null&&(e&&qe.alternate!==null&&ie.delete(qe.key===null?Te:qe.key),_=o(qe,_,Te),Ue===null?ce=qe:Ue.sibling=qe,Ue=qe);return e&&ie.forEach(function(Ty){return t(T,Ty)}),De&&Pl(T,Te),ce}function Fe(T,_,j,H){if(typeof j=="object"&&j!==null&&j.type===$&&j.key===null&&(j=j.props.children),typeof j=="object"&&j!==null){switch(j.$$typeof){case q:e:{for(var ce=j.key;_!==null;){if(_.key===ce){if(ce=j.type,ce===$){if(_.tag===7){l(T,_.sibling),H=r(_,j.props.children),H.return=T,T=H;break e}}else if(_.elementType===ce||typeof ce=="object"&&ce!==null&&ce.$$typeof===w&&pa(ce)===_.type){l(T,_.sibling),H=r(_,j.props),Di(H,j),H.return=T,T=H;break e}l(T,_);break}else t(T,_);_=_.sibling}j.type===$?(H=ca(j.props.children,T.mode,H,j.key),H.return=T,T=H):(H=Du(j.type,j.key,j.props,null,T.mode,H),Di(H,j),H.return=T,T=H)}return h(T);case Q:e:{for(ce=j.key;_!==null;){if(_.key===ce)if(_.tag===4&&_.stateNode.containerInfo===j.containerInfo&&_.stateNode.implementation===j.implementation){l(T,_.sibling),H=r(_,j.children||[]),H.return=T,T=H;break e}else{l(T,_);break}else t(T,_);_=_.sibling}H=fr(j,T.mode,H),H.return=T,T=H}return h(T);case w:return j=pa(j),Fe(T,_,j,H)}if(We(j))return le(T,_,j,H);if(me(j)){if(ce=me(j),typeof ce!="function")throw Error(s(150));return j=ce.call(j),fe(T,_,j,H)}if(typeof j.then=="function")return Fe(T,_,Gu(j),H);if(j.$$typeof===be)return Fe(T,_,Uu(T,j),H);Yu(T,j)}return typeof j=="string"&&j!==""||typeof j=="number"||typeof j=="bigint"?(j=""+j,_!==null&&_.tag===6?(l(T,_.sibling),H=r(_,j),H.return=T,T=H):(l(T,_),H=or(j,T.mode,H),H.return=T,T=H),h(T)):l(T,_)}return function(T,_,j,H){try{wi=0;var ce=Fe(T,_,j,H);return Za=null,ce}catch(ie){if(ie===Qa||ie===Hu)throw ie;var Ue=al(29,ie,null,T.mode);return Ue.lanes=H,Ue.return=T,Ue}}}var ma=Af(!0),Tf=Af(!1),Cn=!1;function Er(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function Ar(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,callbacks:null})}function wn(e){return{lane:e,tag:0,payload:null,callback:null,next:null}}function Dn(e,t,l){var n=e.updateQueue;if(n===null)return null;if(n=n.shared,(Le&2)!==0){var r=n.pending;return r===null?t.next=t:(t.next=r.next,r.next=t),n.pending=t,t=wu(e),rf(e,null,l),t}return Cu(e,n,t,l),wu(e)}function ki(e,t,l){if(t=t.updateQueue,t!==null&&(t=t.shared,(l&4194048)!==0)){var n=t.lanes;n&=e.pendingLanes,l|=n,t.lanes=l,pe(e,l)}}function Tr(e,t){var l=e.updateQueue,n=e.alternate;if(n!==null&&(n=n.updateQueue,l===n)){var r=null,o=null;if(l=l.firstBaseUpdate,l!==null){do{var h={lane:l.lane,tag:l.tag,payload:l.payload,callback:null,next:null};o===null?r=o=h:o=o.next=h,l=l.next}while(l!==null);o===null?r=o=t:o=o.next=t}else r=o=t;l={baseState:n.baseState,firstBaseUpdate:r,lastBaseUpdate:o,shared:n.shared,callbacks:n.callbacks},e.updateQueue=l;return}e=l.lastBaseUpdate,e===null?l.firstBaseUpdate=t:e.next=t,l.lastBaseUpdate=t}var jr=!1;function Bi(){if(jr){var e=Xa;if(e!==null)throw e}}function Ui(e,t,l,n){jr=!1;var r=e.updateQueue;Cn=!1;var o=r.firstBaseUpdate,h=r.lastBaseUpdate,m=r.shared.pending;if(m!==null){r.shared.pending=null;var S=m,O=S.next;S.next=null,h===null?o=O:h.next=O,h=S;var B=e.alternate;B!==null&&(B=B.updateQueue,m=B.lastBaseUpdate,m!==h&&(m===null?B.firstBaseUpdate=O:m.next=O,B.lastBaseUpdate=S))}if(o!==null){var G=r.baseState;h=0,B=O=S=null,m=o;do{var N=m.lane&-536870913,C=N!==m.lane;if(C?(Re&N)===N:(n&N)===N){N!==0&&N===Ya&&(jr=!0),B!==null&&(B=B.next={lane:0,tag:m.tag,payload:m.payload,callback:null,next:null});e:{var le=e,fe=m;N=t;var Fe=l;switch(fe.tag){case 1:if(le=fe.payload,typeof le=="function"){G=le.call(Fe,G,N);break e}G=le;break e;case 3:le.flags=le.flags&-65537|128;case 0:if(le=fe.payload,N=typeof le=="function"?le.call(Fe,G,N):le,N==null)break e;G=A({},G,N);break e;case 2:Cn=!0}}N=m.callback,N!==null&&(e.flags|=64,C&&(e.flags|=8192),C=r.callbacks,C===null?r.callbacks=[N]:C.push(N))}else C={lane:N,tag:m.tag,payload:m.payload,callback:m.callback,next:null},B===null?(O=B=C,S=G):B=B.next=C,h|=N;if(m=m.next,m===null){if(m=r.shared.pending,m===null)break;C=m,m=C.next,C.next=null,r.lastBaseUpdate=C,r.shared.pending=null}}while(!0);B===null&&(S=G),r.baseState=S,r.firstBaseUpdate=O,r.lastBaseUpdate=B,o===null&&(r.shared.lanes=0),Hn|=h,e.lanes=h,e.memoizedState=G}}function jf(e,t){if(typeof e!="function")throw Error(s(191,e));e.call(t)}function Of(e,t){var l=e.callbacks;if(l!==null)for(e.callbacks=null,e=0;e<l.length;e++)jf(l[e],t)}var Va=E(null),Xu=E(0);function Nf(e,t){e=fn,I(Xu,e),I(Va,t),fn=e|t.baseLanes}function Or(){I(Xu,fn),I(Va,Va.current)}function Nr(){fn=Xu.current,L(Va),L(Xu)}var il=E(null),vl=null;function kn(e){var t=e.alternate;I(yt,yt.current&1),I(il,e),vl===null&&(t===null||Va.current!==null||t.memoizedState!==null)&&(vl=e)}function Mr(e){I(yt,yt.current),I(il,e),vl===null&&(vl=e)}function Mf(e){e.tag===22?(I(yt,yt.current),I(il,e),vl===null&&(vl=e)):Bn()}function Bn(){I(yt,yt.current),I(il,il.current)}function ul(e){L(il),vl===e&&(vl=null),L(yt)}var yt=E(0);function Qu(e){for(var t=e;t!==null;){if(t.tag===13){var l=t.memoizedState;if(l!==null&&(l=l.dehydrated,l===null||kc(l)||Bc(l)))return t}else if(t.tag===19&&(t.memoizedProps.revealOrder==="forwards"||t.memoizedProps.revealOrder==="backwards"||t.memoizedProps.revealOrder==="unstable_legacy-backwards"||t.memoizedProps.revealOrder==="together")){if((t.flags&128)!==0)return t}else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}var ln=0,Ae=null,Je=null,Et=null,Zu=!1,Ka=!1,ya=!1,Vu=0,qi=0,Ja=null,gm=0;function ft(){throw Error(s(321))}function zr(e,t){if(t===null)return!1;for(var l=0;l<t.length&&l<e.length;l++)if(!nl(e[l],t[l]))return!1;return!0}function Rr(e,t,l,n,r,o){return ln=o,Ae=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,D.H=e===null||e.memoizedState===null?hh:Vr,ya=!1,o=l(n,r),ya=!1,Ka&&(o=Rf(t,l,n,r)),zf(e),o}function zf(e){D.H=Gi;var t=Je!==null&&Je.next!==null;if(ln=0,Et=Je=Ae=null,Zu=!1,qi=0,Ja=null,t)throw Error(s(300));e===null||At||(e=e.dependencies,e!==null&&Bu(e)&&(At=!0))}function Rf(e,t,l,n){Ae=e;var r=0;do{if(Ka&&(Ja=null),qi=0,Ka=!1,25<=r)throw Error(s(301));if(r+=1,Et=Je=null,e.updateQueue!=null){var o=e.updateQueue;o.lastEffect=null,o.events=null,o.stores=null,o.memoCache!=null&&(o.memoCache.index=0)}D.H=dh,o=t(l,n)}while(Ka);return o}function mm(){var e=D.H,t=e.useState()[0];return t=typeof t.then=="function"?Hi(t):t,e=e.useState()[0],(Je!==null?Je.memoizedState:null)!==e&&(Ae.flags|=1024),t}function Cr(){var e=Vu!==0;return Vu=0,e}function wr(e,t,l){t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~l}function Dr(e){if(Zu){for(e=e.memoizedState;e!==null;){var t=e.queue;t!==null&&(t.pending=null),e=e.next}Zu=!1}ln=0,Et=Je=Ae=null,Ka=!1,qi=Vu=0,Ja=null}function Yt(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return Et===null?Ae.memoizedState=Et=e:Et=Et.next=e,Et}function bt(){if(Je===null){var e=Ae.alternate;e=e!==null?e.memoizedState:null}else e=Je.next;var t=Et===null?Ae.memoizedState:Et.next;if(t!==null)Et=t,Je=e;else{if(e===null)throw Ae.alternate===null?Error(s(467)):Error(s(310));Je=e,e={memoizedState:Je.memoizedState,baseState:Je.baseState,baseQueue:Je.baseQueue,queue:Je.queue,next:null},Et===null?Ae.memoizedState=Et=e:Et=Et.next=e}return Et}function Ku(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function Hi(e){var t=qi;return qi+=1,Ja===null&&(Ja=[]),e=Sf(Ja,e,t),t=Ae,(Et===null?t.memoizedState:Et.next)===null&&(t=t.alternate,D.H=t===null||t.memoizedState===null?hh:Vr),e}function Ju(e){if(e!==null&&typeof e=="object"){if(typeof e.then=="function")return Hi(e);if(e.$$typeof===be)return Ct(e)}throw Error(s(438,String(e)))}function kr(e){var t=null,l=Ae.updateQueue;if(l!==null&&(t=l.memoCache),t==null){var n=Ae.alternate;n!==null&&(n=n.updateQueue,n!==null&&(n=n.memoCache,n!=null&&(t={data:n.data.map(function(r){return r.slice()}),index:0})))}if(t==null&&(t={data:[],index:0}),l===null&&(l=Ku(),Ae.updateQueue=l),l.memoCache=t,l=t.data[t.index],l===void 0)for(l=t.data[t.index]=Array(e),n=0;n<e;n++)l[n]=Ve;return t.index++,l}function nn(e,t){return typeof t=="function"?t(e):t}function $u(e){var t=bt();return Br(t,Je,e)}function Br(e,t,l){var n=e.queue;if(n===null)throw Error(s(311));n.lastRenderedReducer=l;var r=e.baseQueue,o=n.pending;if(o!==null){if(r!==null){var h=r.next;r.next=o.next,o.next=h}t.baseQueue=r=o,n.pending=null}if(o=e.baseState,r===null)e.memoizedState=o;else{t=r.next;var m=h=null,S=null,O=t,B=!1;do{var G=O.lane&-536870913;if(G!==O.lane?(Re&G)===G:(ln&G)===G){var N=O.revertLane;if(N===0)S!==null&&(S=S.next={lane:0,revertLane:0,gesture:null,action:O.action,hasEagerState:O.hasEagerState,eagerState:O.eagerState,next:null}),G===Ya&&(B=!0);else if((ln&N)===N){O=O.next,N===Ya&&(B=!0);continue}else G={lane:0,revertLane:O.revertLane,gesture:null,action:O.action,hasEagerState:O.hasEagerState,eagerState:O.eagerState,next:null},S===null?(m=S=G,h=o):S=S.next=G,Ae.lanes|=N,Hn|=N;G=O.action,ya&&l(o,G),o=O.hasEagerState?O.eagerState:l(o,G)}else N={lane:G,revertLane:O.revertLane,gesture:O.gesture,action:O.action,hasEagerState:O.hasEagerState,eagerState:O.eagerState,next:null},S===null?(m=S=N,h=o):S=S.next=N,Ae.lanes|=G,Hn|=G;O=O.next}while(O!==null&&O!==t);if(S===null?h=o:S.next=m,!nl(o,e.memoizedState)&&(At=!0,B&&(l=Xa,l!==null)))throw l;e.memoizedState=o,e.baseState=h,e.baseQueue=S,n.lastRenderedState=o}return r===null&&(n.lanes=0),[e.memoizedState,n.dispatch]}function Ur(e){var t=bt(),l=t.queue;if(l===null)throw Error(s(311));l.lastRenderedReducer=e;var n=l.dispatch,r=l.pending,o=t.memoizedState;if(r!==null){l.pending=null;var h=r=r.next;do o=e(o,h.action),h=h.next;while(h!==r);nl(o,t.memoizedState)||(At=!0),t.memoizedState=o,t.baseQueue===null&&(t.baseState=o),l.lastRenderedState=o}return[o,n]}function Cf(e,t,l){var n=Ae,r=bt(),o=De;if(o){if(l===void 0)throw Error(s(407));l=l()}else l=t();var h=!nl((Je||r).memoizedState,l);if(h&&(r.memoizedState=l,At=!0),r=r.queue,Lr(kf.bind(null,n,r,e),[e]),r.getSnapshot!==t||h||Et!==null&&Et.memoizedState.tag&1){if(n.flags|=2048,$a(9,{destroy:void 0},Df.bind(null,n,r,l,t),null),Pe===null)throw Error(s(349));o||(ln&127)!==0||wf(n,t,l)}return l}function wf(e,t,l){e.flags|=16384,e={getSnapshot:t,value:l},t=Ae.updateQueue,t===null?(t=Ku(),Ae.updateQueue=t,t.stores=[e]):(l=t.stores,l===null?t.stores=[e]:l.push(e))}function Df(e,t,l,n){t.value=l,t.getSnapshot=n,Bf(t)&&Uf(e)}function kf(e,t,l){return l(function(){Bf(t)&&Uf(e)})}function Bf(e){var t=e.getSnapshot;e=e.value;try{var l=t();return!nl(e,l)}catch{return!0}}function Uf(e){var t=ra(e,2);t!==null&&It(t,e,2)}function qr(e){var t=Yt();if(typeof e=="function"){var l=e;if(e=l(),ya){hl(!0);try{l()}finally{hl(!1)}}}return t.memoizedState=t.baseState=e,t.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:nn,lastRenderedState:e},t}function qf(e,t,l,n){return e.baseState=l,Br(e,Je,typeof n=="function"?n:nn)}function ym(e,t,l,n,r){if(Iu(e))throw Error(s(485));if(e=t.action,e!==null){var o={payload:r,action:e,next:null,isTransition:!0,status:"pending",value:null,reason:null,listeners:[],then:function(h){o.listeners.push(h)}};D.T!==null?l(!0):o.isTransition=!1,n(o),l=t.pending,l===null?(o.next=t.pending=o,Hf(t,o)):(o.next=l.next,t.pending=l.next=o)}}function Hf(e,t){var l=t.action,n=t.payload,r=e.state;if(t.isTransition){var o=D.T,h={};D.T=h;try{var m=l(r,n),S=D.S;S!==null&&S(h,m),Lf(e,t,m)}catch(O){Hr(e,t,O)}finally{o!==null&&h.types!==null&&(o.types=h.types),D.T=o}}else try{o=l(r,n),Lf(e,t,o)}catch(O){Hr(e,t,O)}}function Lf(e,t,l){l!==null&&typeof l=="object"&&typeof l.then=="function"?l.then(function(n){Gf(e,t,n)},function(n){return Hr(e,t,n)}):Gf(e,t,l)}function Gf(e,t,l){t.status="fulfilled",t.value=l,Yf(t),e.state=l,t=e.pending,t!==null&&(l=t.next,l===t?e.pending=null:(l=l.next,t.next=l,Hf(e,l)))}function Hr(e,t,l){var n=e.pending;if(e.pending=null,n!==null){n=n.next;do t.status="rejected",t.reason=l,Yf(t),t=t.next;while(t!==n)}e.action=null}function Yf(e){e=e.listeners;for(var t=0;t<e.length;t++)(0,e[t])()}function Xf(e,t){return t}function Qf(e,t){if(De){var l=Pe.formState;if(l!==null){e:{var n=Ae;if(De){if(nt){t:{for(var r=nt,o=bl;r.nodeType!==8;){if(!o){r=null;break t}if(r=xl(r.nextSibling),r===null){r=null;break t}}o=r.data,r=o==="F!"||o==="F"?r:null}if(r){nt=xl(r.nextSibling),n=r.data==="F!";break e}}zn(n)}n=!1}n&&(t=l[0])}}return l=Yt(),l.memoizedState=l.baseState=t,n={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Xf,lastRenderedState:t},l.queue=n,l=ch.bind(null,Ae,n),n.dispatch=l,n=qr(!1),o=Zr.bind(null,Ae,!1,n.queue),n=Yt(),r={state:t,dispatch:null,action:e,pending:null},n.queue=r,l=ym.bind(null,Ae,r,o,l),r.dispatch=l,n.memoizedState=e,[t,l,!1]}function Zf(e){var t=bt();return Vf(t,Je,e)}function Vf(e,t,l){if(t=Br(e,t,Xf)[0],e=$u(nn)[0],typeof t=="object"&&t!==null&&typeof t.then=="function")try{var n=Hi(t)}catch(h){throw h===Qa?Hu:h}else n=t;t=bt();var r=t.queue,o=r.dispatch;return l!==t.memoizedState&&(Ae.flags|=2048,$a(9,{destroy:void 0},bm.bind(null,r,l),null)),[n,o,e]}function bm(e,t){e.action=t}function Kf(e){var t=bt(),l=Je;if(l!==null)return Vf(t,l,e);bt(),t=t.memoizedState,l=bt();var n=l.queue.dispatch;return l.memoizedState=e,[t,n,!1]}function $a(e,t,l,n){return e={tag:e,create:l,deps:n,inst:t,next:null},t=Ae.updateQueue,t===null&&(t=Ku(),Ae.updateQueue=t),l=t.lastEffect,l===null?t.lastEffect=e.next=e:(n=l.next,l.next=e,e.next=n,t.lastEffect=e),e}function Jf(){return bt().memoizedState}function Fu(e,t,l,n){var r=Yt();Ae.flags|=e,r.memoizedState=$a(1|t,{destroy:void 0},l,n===void 0?null:n)}function Wu(e,t,l,n){var r=bt();n=n===void 0?null:n;var o=r.memoizedState.inst;Je!==null&&n!==null&&zr(n,Je.memoizedState.deps)?r.memoizedState=$a(t,o,l,n):(Ae.flags|=e,r.memoizedState=$a(1|t,o,l,n))}function $f(e,t){Fu(8390656,8,e,t)}function Lr(e,t){Wu(2048,8,e,t)}function vm(e){Ae.flags|=4;var t=Ae.updateQueue;if(t===null)t=Ku(),Ae.updateQueue=t,t.events=[e];else{var l=t.events;l===null?t.events=[e]:l.push(e)}}function Ff(e){var t=bt().memoizedState;return vm({ref:t,nextImpl:e}),function(){if((Le&2)!==0)throw Error(s(440));return t.impl.apply(void 0,arguments)}}function Wf(e,t){return Wu(4,2,e,t)}function If(e,t){return Wu(4,4,e,t)}function Pf(e,t){if(typeof t=="function"){e=e();var l=t(e);return function(){typeof l=="function"?l():t(null)}}if(t!=null)return e=e(),t.current=e,function(){t.current=null}}function eh(e,t,l){l=l!=null?l.concat([e]):null,Wu(4,4,Pf.bind(null,t,e),l)}function Gr(){}function th(e,t){var l=bt();t=t===void 0?null:t;var n=l.memoizedState;return t!==null&&zr(t,n[1])?n[0]:(l.memoizedState=[e,t],e)}function lh(e,t){var l=bt();t=t===void 0?null:t;var n=l.memoizedState;if(t!==null&&zr(t,n[1]))return n[0];if(n=e(),ya){hl(!0);try{e()}finally{hl(!1)}}return l.memoizedState=[n,t],n}function Yr(e,t,l){return l===void 0||(ln&1073741824)!==0&&(Re&261930)===0?e.memoizedState=t:(e.memoizedState=l,e=nd(),Ae.lanes|=e,Hn|=e,l)}function nh(e,t,l,n){return nl(l,t)?l:Va.current!==null?(e=Yr(e,l,n),nl(e,t)||(At=!0),e):(ln&42)===0||(ln&1073741824)!==0&&(Re&261930)===0?(At=!0,e.memoizedState=l):(e=nd(),Ae.lanes|=e,Hn|=e,t)}function ah(e,t,l,n,r){var o=F.p;F.p=o!==0&&8>o?o:8;var h=D.T,m={};D.T=m,Zr(e,!1,t,l);try{var S=r(),O=D.S;if(O!==null&&O(m,S),S!==null&&typeof S=="object"&&typeof S.then=="function"){var B=pm(S,n);Li(e,t,B,cl(e))}else Li(e,t,n,cl(e))}catch(G){Li(e,t,{then:function(){},status:"rejected",reason:G},cl())}finally{F.p=o,h!==null&&m.types!==null&&(h.types=m.types),D.T=h}}function xm(){}function Xr(e,t,l,n){if(e.tag!==5)throw Error(s(476));var r=ih(e).queue;ah(e,r,t,re,l===null?xm:function(){return uh(e),l(n)})}function ih(e){var t=e.memoizedState;if(t!==null)return t;t={memoizedState:re,baseState:re,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:nn,lastRenderedState:re},next:null};var l={};return t.next={memoizedState:l,baseState:l,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:nn,lastRenderedState:l},next:null},e.memoizedState=t,e=e.alternate,e!==null&&(e.memoizedState=t),t}function uh(e){var t=ih(e);t.next===null&&(t=e.alternate.memoizedState),Li(e,t.next.queue,{},cl())}function Qr(){return Ct(nu)}function sh(){return bt().memoizedState}function rh(){return bt().memoizedState}function Sm(e){for(var t=e.return;t!==null;){switch(t.tag){case 24:case 3:var l=cl();e=wn(l);var n=Dn(t,e,l);n!==null&&(It(n,t,l),ki(n,t,l)),t={cache:vr()},e.payload=t;return}t=t.return}}function _m(e,t,l){var n=cl();l={lane:n,revertLane:0,gesture:null,action:l,hasEagerState:!1,eagerState:null,next:null},Iu(e)?oh(t,l):(l=rr(e,t,l,n),l!==null&&(It(l,e,n),fh(l,t,n)))}function ch(e,t,l){var n=cl();Li(e,t,l,n)}function Li(e,t,l,n){var r={lane:n,revertLane:0,gesture:null,action:l,hasEagerState:!1,eagerState:null,next:null};if(Iu(e))oh(t,r);else{var o=e.alternate;if(e.lanes===0&&(o===null||o.lanes===0)&&(o=t.lastRenderedReducer,o!==null))try{var h=t.lastRenderedState,m=o(h,l);if(r.hasEagerState=!0,r.eagerState=m,nl(m,h))return Cu(e,t,r,0),Pe===null&&Ru(),!1}catch{}if(l=rr(e,t,r,n),l!==null)return It(l,e,n),fh(l,t,n),!0}return!1}function Zr(e,t,l,n){if(n={lane:2,revertLane:Ec(),gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null},Iu(e)){if(t)throw Error(s(479))}else t=rr(e,l,n,2),t!==null&&It(t,e,2)}function Iu(e){var t=e.alternate;return e===Ae||t!==null&&t===Ae}function oh(e,t){Ka=Zu=!0;var l=e.pending;l===null?t.next=t:(t.next=l.next,l.next=t),e.pending=t}function fh(e,t,l){if((l&4194048)!==0){var n=t.lanes;n&=e.pendingLanes,l|=n,t.lanes=l,pe(e,l)}}var Gi={readContext:Ct,use:Ju,useCallback:ft,useContext:ft,useEffect:ft,useImperativeHandle:ft,useLayoutEffect:ft,useInsertionEffect:ft,useMemo:ft,useReducer:ft,useRef:ft,useState:ft,useDebugValue:ft,useDeferredValue:ft,useTransition:ft,useSyncExternalStore:ft,useId:ft,useHostTransitionStatus:ft,useFormState:ft,useActionState:ft,useOptimistic:ft,useMemoCache:ft,useCacheRefresh:ft};Gi.useEffectEvent=ft;var hh={readContext:Ct,use:Ju,useCallback:function(e,t){return Yt().memoizedState=[e,t===void 0?null:t],e},useContext:Ct,useEffect:$f,useImperativeHandle:function(e,t,l){l=l!=null?l.concat([e]):null,Fu(4194308,4,Pf.bind(null,t,e),l)},useLayoutEffect:function(e,t){return Fu(4194308,4,e,t)},useInsertionEffect:function(e,t){Fu(4,2,e,t)},useMemo:function(e,t){var l=Yt();t=t===void 0?null:t;var n=e();if(ya){hl(!0);try{e()}finally{hl(!1)}}return l.memoizedState=[n,t],n},useReducer:function(e,t,l){var n=Yt();if(l!==void 0){var r=l(t);if(ya){hl(!0);try{l(t)}finally{hl(!1)}}}else r=t;return n.memoizedState=n.baseState=r,e={pending:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:r},n.queue=e,e=e.dispatch=_m.bind(null,Ae,e),[n.memoizedState,e]},useRef:function(e){var t=Yt();return e={current:e},t.memoizedState=e},useState:function(e){e=qr(e);var t=e.queue,l=ch.bind(null,Ae,t);return t.dispatch=l,[e.memoizedState,l]},useDebugValue:Gr,useDeferredValue:function(e,t){var l=Yt();return Yr(l,e,t)},useTransition:function(){var e=qr(!1);return e=ah.bind(null,Ae,e.queue,!0,!1),Yt().memoizedState=e,[!1,e]},useSyncExternalStore:function(e,t,l){var n=Ae,r=Yt();if(De){if(l===void 0)throw Error(s(407));l=l()}else{if(l=t(),Pe===null)throw Error(s(349));(Re&127)!==0||wf(n,t,l)}r.memoizedState=l;var o={value:l,getSnapshot:t};return r.queue=o,$f(kf.bind(null,n,o,e),[e]),n.flags|=2048,$a(9,{destroy:void 0},Df.bind(null,n,o,l,t),null),l},useId:function(){var e=Yt(),t=Pe.identifierPrefix;if(De){var l=kl,n=Dl;l=(n&~(1<<32-Mt(n)-1)).toString(32)+l,t="_"+t+"R_"+l,l=Vu++,0<l&&(t+="H"+l.toString(32)),t+="_"}else l=gm++,t="_"+t+"r_"+l.toString(32)+"_";return e.memoizedState=t},useHostTransitionStatus:Qr,useFormState:Qf,useActionState:Qf,useOptimistic:function(e){var t=Yt();t.memoizedState=t.baseState=e;var l={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return t.queue=l,t=Zr.bind(null,Ae,!0,l),l.dispatch=t,[e,t]},useMemoCache:kr,useCacheRefresh:function(){return Yt().memoizedState=Sm.bind(null,Ae)},useEffectEvent:function(e){var t=Yt(),l={impl:e};return t.memoizedState=l,function(){if((Le&2)!==0)throw Error(s(440));return l.impl.apply(void 0,arguments)}}},Vr={readContext:Ct,use:Ju,useCallback:th,useContext:Ct,useEffect:Lr,useImperativeHandle:eh,useInsertionEffect:Wf,useLayoutEffect:If,useMemo:lh,useReducer:$u,useRef:Jf,useState:function(){return $u(nn)},useDebugValue:Gr,useDeferredValue:function(e,t){var l=bt();return nh(l,Je.memoizedState,e,t)},useTransition:function(){var e=$u(nn)[0],t=bt().memoizedState;return[typeof e=="boolean"?e:Hi(e),t]},useSyncExternalStore:Cf,useId:sh,useHostTransitionStatus:Qr,useFormState:Zf,useActionState:Zf,useOptimistic:function(e,t){var l=bt();return qf(l,Je,e,t)},useMemoCache:kr,useCacheRefresh:rh};Vr.useEffectEvent=Ff;var dh={readContext:Ct,use:Ju,useCallback:th,useContext:Ct,useEffect:Lr,useImperativeHandle:eh,useInsertionEffect:Wf,useLayoutEffect:If,useMemo:lh,useReducer:Ur,useRef:Jf,useState:function(){return Ur(nn)},useDebugValue:Gr,useDeferredValue:function(e,t){var l=bt();return Je===null?Yr(l,e,t):nh(l,Je.memoizedState,e,t)},useTransition:function(){var e=Ur(nn)[0],t=bt().memoizedState;return[typeof e=="boolean"?e:Hi(e),t]},useSyncExternalStore:Cf,useId:sh,useHostTransitionStatus:Qr,useFormState:Kf,useActionState:Kf,useOptimistic:function(e,t){var l=bt();return Je!==null?qf(l,Je,e,t):(l.baseState=e,[e,l.queue.dispatch])},useMemoCache:kr,useCacheRefresh:rh};dh.useEffectEvent=Ff;function Kr(e,t,l,n){t=e.memoizedState,l=l(n,t),l=l==null?t:A({},t,l),e.memoizedState=l,e.lanes===0&&(e.updateQueue.baseState=l)}var Jr={enqueueSetState:function(e,t,l){e=e._reactInternals;var n=cl(),r=wn(n);r.payload=t,l!=null&&(r.callback=l),t=Dn(e,r,n),t!==null&&(It(t,e,n),ki(t,e,n))},enqueueReplaceState:function(e,t,l){e=e._reactInternals;var n=cl(),r=wn(n);r.tag=1,r.payload=t,l!=null&&(r.callback=l),t=Dn(e,r,n),t!==null&&(It(t,e,n),ki(t,e,n))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var l=cl(),n=wn(l);n.tag=2,t!=null&&(n.callback=t),t=Dn(e,n,l),t!==null&&(It(t,e,l),ki(t,e,l))}};function ph(e,t,l,n,r,o,h){return e=e.stateNode,typeof e.shouldComponentUpdate=="function"?e.shouldComponentUpdate(n,o,h):t.prototype&&t.prototype.isPureReactComponent?!Oi(l,n)||!Oi(r,o):!0}function gh(e,t,l,n){e=t.state,typeof t.componentWillReceiveProps=="function"&&t.componentWillReceiveProps(l,n),typeof t.UNSAFE_componentWillReceiveProps=="function"&&t.UNSAFE_componentWillReceiveProps(l,n),t.state!==e&&Jr.enqueueReplaceState(t,t.state,null)}function ba(e,t){var l=t;if("ref"in t){l={};for(var n in t)n!=="ref"&&(l[n]=t[n])}if(e=e.defaultProps){l===t&&(l=A({},l));for(var r in e)l[r]===void 0&&(l[r]=e[r])}return l}function mh(e){zu(e)}function yh(e){console.error(e)}function bh(e){zu(e)}function Pu(e,t){try{var l=e.onUncaughtError;l(t.value,{componentStack:t.stack})}catch(n){setTimeout(function(){throw n})}}function vh(e,t,l){try{var n=e.onCaughtError;n(l.value,{componentStack:l.stack,errorBoundary:t.tag===1?t.stateNode:null})}catch(r){setTimeout(function(){throw r})}}function $r(e,t,l){return l=wn(l),l.tag=3,l.payload={element:null},l.callback=function(){Pu(e,t)},l}function xh(e){return e=wn(e),e.tag=3,e}function Sh(e,t,l,n){var r=l.type.getDerivedStateFromError;if(typeof r=="function"){var o=n.value;e.payload=function(){return r(o)},e.callback=function(){vh(t,l,n)}}var h=l.stateNode;h!==null&&typeof h.componentDidCatch=="function"&&(e.callback=function(){vh(t,l,n),typeof r!="function"&&(Ln===null?Ln=new Set([this]):Ln.add(this));var m=n.stack;this.componentDidCatch(n.value,{componentStack:m!==null?m:""})})}function Em(e,t,l,n,r){if(l.flags|=32768,n!==null&&typeof n=="object"&&typeof n.then=="function"){if(t=l.alternate,t!==null&&Ga(t,l,r,!0),l=il.current,l!==null){switch(l.tag){case 31:case 13:return vl===null?fs():l.alternate===null&&ht===0&&(ht=3),l.flags&=-257,l.flags|=65536,l.lanes=r,n===Lu?l.flags|=16384:(t=l.updateQueue,t===null?l.updateQueue=new Set([n]):t.add(n),xc(e,n,r)),!1;case 22:return l.flags|=65536,n===Lu?l.flags|=16384:(t=l.updateQueue,t===null?(t={transitions:null,markerInstances:null,retryQueue:new Set([n])},l.updateQueue=t):(l=t.retryQueue,l===null?t.retryQueue=new Set([n]):l.add(n)),xc(e,n,r)),!1}throw Error(s(435,l.tag))}return xc(e,n,r),fs(),!1}if(De)return t=il.current,t!==null?((t.flags&65536)===0&&(t.flags|=256),t.flags|=65536,t.lanes=r,n!==pr&&(e=Error(s(422),{cause:n}),zi(gl(e,l)))):(n!==pr&&(t=Error(s(423),{cause:n}),zi(gl(t,l))),e=e.current.alternate,e.flags|=65536,r&=-r,e.lanes|=r,n=gl(n,l),r=$r(e.stateNode,n,r),Tr(e,r),ht!==4&&(ht=2)),!1;var o=Error(s(520),{cause:n});if(o=gl(o,l),$i===null?$i=[o]:$i.push(o),ht!==4&&(ht=2),t===null)return!0;n=gl(n,l),l=t;do{switch(l.tag){case 3:return l.flags|=65536,e=r&-r,l.lanes|=e,e=$r(l.stateNode,n,e),Tr(l,e),!1;case 1:if(t=l.type,o=l.stateNode,(l.flags&128)===0&&(typeof t.getDerivedStateFromError=="function"||o!==null&&typeof o.componentDidCatch=="function"&&(Ln===null||!Ln.has(o))))return l.flags|=65536,r&=-r,l.lanes|=r,r=xh(r),Sh(r,e,l,n),Tr(l,r),!1}l=l.return}while(l!==null);return!1}var Fr=Error(s(461)),At=!1;function wt(e,t,l,n){t.child=e===null?Tf(t,null,l,n):ma(t,e.child,l,n)}function _h(e,t,l,n,r){l=l.render;var o=t.ref;if("ref"in n){var h={};for(var m in n)m!=="ref"&&(h[m]=n[m])}else h=n;return ha(t),n=Rr(e,t,l,h,o,r),m=Cr(),e!==null&&!At?(wr(e,t,r),an(e,t,r)):(De&&m&&hr(t),t.flags|=1,wt(e,t,n,r),t.child)}function Eh(e,t,l,n,r){if(e===null){var o=l.type;return typeof o=="function"&&!cr(o)&&o.defaultProps===void 0&&l.compare===null?(t.tag=15,t.type=o,Ah(e,t,o,n,r)):(e=Du(l.type,null,n,t,t.mode,r),e.ref=t.ref,e.return=t,t.child=e)}if(o=e.child,!ac(e,r)){var h=o.memoizedProps;if(l=l.compare,l=l!==null?l:Oi,l(h,n)&&e.ref===t.ref)return an(e,t,r)}return t.flags|=1,e=Il(o,n),e.ref=t.ref,e.return=t,t.child=e}function Ah(e,t,l,n,r){if(e!==null){var o=e.memoizedProps;if(Oi(o,n)&&e.ref===t.ref)if(At=!1,t.pendingProps=n=o,ac(e,r))(e.flags&131072)!==0&&(At=!0);else return t.lanes=e.lanes,an(e,t,r)}return Wr(e,t,l,n,r)}function Th(e,t,l,n){var r=n.children,o=e!==null?e.memoizedState:null;if(e===null&&t.stateNode===null&&(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),n.mode==="hidden"){if((t.flags&128)!==0){if(o=o!==null?o.baseLanes|l:l,e!==null){for(n=t.child=e.child,r=0;n!==null;)r=r|n.lanes|n.childLanes,n=n.sibling;n=r&~o}else n=0,t.child=null;return jh(e,t,o,l,n)}if((l&536870912)!==0)t.memoizedState={baseLanes:0,cachePool:null},e!==null&&qu(t,o!==null?o.cachePool:null),o!==null?Nf(t,o):Or(),Mf(t);else return n=t.lanes=536870912,jh(e,t,o!==null?o.baseLanes|l:l,l,n)}else o!==null?(qu(t,o.cachePool),Nf(t,o),Bn(),t.memoizedState=null):(e!==null&&qu(t,null),Or(),Bn());return wt(e,t,r,l),t.child}function Yi(e,t){return e!==null&&e.tag===22||t.stateNode!==null||(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),t.sibling}function jh(e,t,l,n,r){var o=Sr();return o=o===null?null:{parent:_t._currentValue,pool:o},t.memoizedState={baseLanes:l,cachePool:o},e!==null&&qu(t,null),Or(),Mf(t),e!==null&&Ga(e,t,n,!0),t.childLanes=r,null}function es(e,t){return t=ls({mode:t.mode,children:t.children},e.mode),t.ref=e.ref,e.child=t,t.return=e,t}function Oh(e,t,l){return ma(t,e.child,null,l),e=es(t,t.pendingProps),e.flags|=2,ul(t),t.memoizedState=null,e}function Am(e,t,l){var n=t.pendingProps,r=(t.flags&128)!==0;if(t.flags&=-129,e===null){if(De){if(n.mode==="hidden")return e=es(t,n),t.lanes=536870912,Yi(null,e);if(Mr(t),(e=nt)?(e=Hd(e,bl),e=e!==null&&e.data==="&"?e:null,e!==null&&(t.memoizedState={dehydrated:e,treeContext:Nn!==null?{id:Dl,overflow:kl}:null,retryLane:536870912,hydrationErrors:null},l=of(e),l.return=t,t.child=l,Rt=t,nt=null)):e=null,e===null)throw zn(t);return t.lanes=536870912,null}return es(t,n)}var o=e.memoizedState;if(o!==null){var h=o.dehydrated;if(Mr(t),r)if(t.flags&256)t.flags&=-257,t=Oh(e,t,l);else if(t.memoizedState!==null)t.child=e.child,t.flags|=128,t=null;else throw Error(s(558));else if(At||Ga(e,t,l,!1),r=(l&e.childLanes)!==0,At||r){if(n=Pe,n!==null&&(h=pt(n,l),h!==0&&h!==o.retryLane))throw o.retryLane=h,ra(e,h),It(n,e,h),Fr;fs(),t=Oh(e,t,l)}else e=o.treeContext,nt=xl(h.nextSibling),Rt=t,De=!0,Mn=null,bl=!1,e!==null&&df(t,e),t=es(t,n),t.flags|=4096;return t}return e=Il(e.child,{mode:n.mode,children:n.children}),e.ref=t.ref,t.child=e,e.return=t,e}function ts(e,t){var l=t.ref;if(l===null)e!==null&&e.ref!==null&&(t.flags|=4194816);else{if(typeof l!="function"&&typeof l!="object")throw Error(s(284));(e===null||e.ref!==l)&&(t.flags|=4194816)}}function Wr(e,t,l,n,r){return ha(t),l=Rr(e,t,l,n,void 0,r),n=Cr(),e!==null&&!At?(wr(e,t,r),an(e,t,r)):(De&&n&&hr(t),t.flags|=1,wt(e,t,l,r),t.child)}function Nh(e,t,l,n,r,o){return ha(t),t.updateQueue=null,l=Rf(t,n,l,r),zf(e),n=Cr(),e!==null&&!At?(wr(e,t,o),an(e,t,o)):(De&&n&&hr(t),t.flags|=1,wt(e,t,l,o),t.child)}function Mh(e,t,l,n,r){if(ha(t),t.stateNode===null){var o=Ua,h=l.contextType;typeof h=="object"&&h!==null&&(o=Ct(h)),o=new l(n,o),t.memoizedState=o.state!==null&&o.state!==void 0?o.state:null,o.updater=Jr,t.stateNode=o,o._reactInternals=t,o=t.stateNode,o.props=n,o.state=t.memoizedState,o.refs={},Er(t),h=l.contextType,o.context=typeof h=="object"&&h!==null?Ct(h):Ua,o.state=t.memoizedState,h=l.getDerivedStateFromProps,typeof h=="function"&&(Kr(t,l,h,n),o.state=t.memoizedState),typeof l.getDerivedStateFromProps=="function"||typeof o.getSnapshotBeforeUpdate=="function"||typeof o.UNSAFE_componentWillMount!="function"&&typeof o.componentWillMount!="function"||(h=o.state,typeof o.componentWillMount=="function"&&o.componentWillMount(),typeof o.UNSAFE_componentWillMount=="function"&&o.UNSAFE_componentWillMount(),h!==o.state&&Jr.enqueueReplaceState(o,o.state,null),Ui(t,n,o,r),Bi(),o.state=t.memoizedState),typeof o.componentDidMount=="function"&&(t.flags|=4194308),n=!0}else if(e===null){o=t.stateNode;var m=t.memoizedProps,S=ba(l,m);o.props=S;var O=o.context,B=l.contextType;h=Ua,typeof B=="object"&&B!==null&&(h=Ct(B));var G=l.getDerivedStateFromProps;B=typeof G=="function"||typeof o.getSnapshotBeforeUpdate=="function",m=t.pendingProps!==m,B||typeof o.UNSAFE_componentWillReceiveProps!="function"&&typeof o.componentWillReceiveProps!="function"||(m||O!==h)&&gh(t,o,n,h),Cn=!1;var N=t.memoizedState;o.state=N,Ui(t,n,o,r),Bi(),O=t.memoizedState,m||N!==O||Cn?(typeof G=="function"&&(Kr(t,l,G,n),O=t.memoizedState),(S=Cn||ph(t,l,S,n,N,O,h))?(B||typeof o.UNSAFE_componentWillMount!="function"&&typeof o.componentWillMount!="function"||(typeof o.componentWillMount=="function"&&o.componentWillMount(),typeof o.UNSAFE_componentWillMount=="function"&&o.UNSAFE_componentWillMount()),typeof o.componentDidMount=="function"&&(t.flags|=4194308)):(typeof o.componentDidMount=="function"&&(t.flags|=4194308),t.memoizedProps=n,t.memoizedState=O),o.props=n,o.state=O,o.context=h,n=S):(typeof o.componentDidMount=="function"&&(t.flags|=4194308),n=!1)}else{o=t.stateNode,Ar(e,t),h=t.memoizedProps,B=ba(l,h),o.props=B,G=t.pendingProps,N=o.context,O=l.contextType,S=Ua,typeof O=="object"&&O!==null&&(S=Ct(O)),m=l.getDerivedStateFromProps,(O=typeof m=="function"||typeof o.getSnapshotBeforeUpdate=="function")||typeof o.UNSAFE_componentWillReceiveProps!="function"&&typeof o.componentWillReceiveProps!="function"||(h!==G||N!==S)&&gh(t,o,n,S),Cn=!1,N=t.memoizedState,o.state=N,Ui(t,n,o,r),Bi();var C=t.memoizedState;h!==G||N!==C||Cn||e!==null&&e.dependencies!==null&&Bu(e.dependencies)?(typeof m=="function"&&(Kr(t,l,m,n),C=t.memoizedState),(B=Cn||ph(t,l,B,n,N,C,S)||e!==null&&e.dependencies!==null&&Bu(e.dependencies))?(O||typeof o.UNSAFE_componentWillUpdate!="function"&&typeof o.componentWillUpdate!="function"||(typeof o.componentWillUpdate=="function"&&o.componentWillUpdate(n,C,S),typeof o.UNSAFE_componentWillUpdate=="function"&&o.UNSAFE_componentWillUpdate(n,C,S)),typeof o.componentDidUpdate=="function"&&(t.flags|=4),typeof o.getSnapshotBeforeUpdate=="function"&&(t.flags|=1024)):(typeof o.componentDidUpdate!="function"||h===e.memoizedProps&&N===e.memoizedState||(t.flags|=4),typeof o.getSnapshotBeforeUpdate!="function"||h===e.memoizedProps&&N===e.memoizedState||(t.flags|=1024),t.memoizedProps=n,t.memoizedState=C),o.props=n,o.state=C,o.context=S,n=B):(typeof o.componentDidUpdate!="function"||h===e.memoizedProps&&N===e.memoizedState||(t.flags|=4),typeof o.getSnapshotBeforeUpdate!="function"||h===e.memoizedProps&&N===e.memoizedState||(t.flags|=1024),n=!1)}return o=n,ts(e,t),n=(t.flags&128)!==0,o||n?(o=t.stateNode,l=n&&typeof l.getDerivedStateFromError!="function"?null:o.render(),t.flags|=1,e!==null&&n?(t.child=ma(t,e.child,null,r),t.child=ma(t,null,l,r)):wt(e,t,l,r),t.memoizedState=o.state,e=t.child):e=an(e,t,r),e}function zh(e,t,l,n){return oa(),t.flags|=256,wt(e,t,l,n),t.child}var Ir={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function Pr(e){return{baseLanes:e,cachePool:vf()}}function ec(e,t,l){return e=e!==null?e.childLanes&~l:0,t&&(e|=rl),e}function Rh(e,t,l){var n=t.pendingProps,r=!1,o=(t.flags&128)!==0,h;if((h=o)||(h=e!==null&&e.memoizedState===null?!1:(yt.current&2)!==0),h&&(r=!0,t.flags&=-129),h=(t.flags&32)!==0,t.flags&=-33,e===null){if(De){if(r?kn(t):Bn(),(e=nt)?(e=Hd(e,bl),e=e!==null&&e.data!=="&"?e:null,e!==null&&(t.memoizedState={dehydrated:e,treeContext:Nn!==null?{id:Dl,overflow:kl}:null,retryLane:536870912,hydrationErrors:null},l=of(e),l.return=t,t.child=l,Rt=t,nt=null)):e=null,e===null)throw zn(t);return Bc(e)?t.lanes=32:t.lanes=536870912,null}var m=n.children;return n=n.fallback,r?(Bn(),r=t.mode,m=ls({mode:"hidden",children:m},r),n=ca(n,r,l,null),m.return=t,n.return=t,m.sibling=n,t.child=m,n=t.child,n.memoizedState=Pr(l),n.childLanes=ec(e,h,l),t.memoizedState=Ir,Yi(null,n)):(kn(t),tc(t,m))}var S=e.memoizedState;if(S!==null&&(m=S.dehydrated,m!==null)){if(o)t.flags&256?(kn(t),t.flags&=-257,t=lc(e,t,l)):t.memoizedState!==null?(Bn(),t.child=e.child,t.flags|=128,t=null):(Bn(),m=n.fallback,r=t.mode,n=ls({mode:"visible",children:n.children},r),m=ca(m,r,l,null),m.flags|=2,n.return=t,m.return=t,n.sibling=m,t.child=n,ma(t,e.child,null,l),n=t.child,n.memoizedState=Pr(l),n.childLanes=ec(e,h,l),t.memoizedState=Ir,t=Yi(null,n));else if(kn(t),Bc(m)){if(h=m.nextSibling&&m.nextSibling.dataset,h)var O=h.dgst;h=O,n=Error(s(419)),n.stack="",n.digest=h,zi({value:n,source:null,stack:null}),t=lc(e,t,l)}else if(At||Ga(e,t,l,!1),h=(l&e.childLanes)!==0,At||h){if(h=Pe,h!==null&&(n=pt(h,l),n!==0&&n!==S.retryLane))throw S.retryLane=n,ra(e,n),It(h,e,n),Fr;kc(m)||fs(),t=lc(e,t,l)}else kc(m)?(t.flags|=192,t.child=e.child,t=null):(e=S.treeContext,nt=xl(m.nextSibling),Rt=t,De=!0,Mn=null,bl=!1,e!==null&&df(t,e),t=tc(t,n.children),t.flags|=4096);return t}return r?(Bn(),m=n.fallback,r=t.mode,S=e.child,O=S.sibling,n=Il(S,{mode:"hidden",children:n.children}),n.subtreeFlags=S.subtreeFlags&65011712,O!==null?m=Il(O,m):(m=ca(m,r,l,null),m.flags|=2),m.return=t,n.return=t,n.sibling=m,t.child=n,Yi(null,n),n=t.child,m=e.child.memoizedState,m===null?m=Pr(l):(r=m.cachePool,r!==null?(S=_t._currentValue,r=r.parent!==S?{parent:S,pool:S}:r):r=vf(),m={baseLanes:m.baseLanes|l,cachePool:r}),n.memoizedState=m,n.childLanes=ec(e,h,l),t.memoizedState=Ir,Yi(e.child,n)):(kn(t),l=e.child,e=l.sibling,l=Il(l,{mode:"visible",children:n.children}),l.return=t,l.sibling=null,e!==null&&(h=t.deletions,h===null?(t.deletions=[e],t.flags|=16):h.push(e)),t.child=l,t.memoizedState=null,l)}function tc(e,t){return t=ls({mode:"visible",children:t},e.mode),t.return=e,e.child=t}function ls(e,t){return e=al(22,e,null,t),e.lanes=0,e}function lc(e,t,l){return ma(t,e.child,null,l),e=tc(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function Ch(e,t,l){e.lanes|=t;var n=e.alternate;n!==null&&(n.lanes|=t),yr(e.return,t,l)}function nc(e,t,l,n,r,o){var h=e.memoizedState;h===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:n,tail:l,tailMode:r,treeForkCount:o}:(h.isBackwards=t,h.rendering=null,h.renderingStartTime=0,h.last=n,h.tail=l,h.tailMode=r,h.treeForkCount=o)}function wh(e,t,l){var n=t.pendingProps,r=n.revealOrder,o=n.tail;n=n.children;var h=yt.current,m=(h&2)!==0;if(m?(h=h&1|2,t.flags|=128):h&=1,I(yt,h),wt(e,t,n,l),n=De?Mi:0,!m&&e!==null&&(e.flags&128)!==0)e:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&Ch(e,l,t);else if(e.tag===19)Ch(e,l,t);else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break e;for(;e.sibling===null;){if(e.return===null||e.return===t)break e;e=e.return}e.sibling.return=e.return,e=e.sibling}switch(r){case"forwards":for(l=t.child,r=null;l!==null;)e=l.alternate,e!==null&&Qu(e)===null&&(r=l),l=l.sibling;l=r,l===null?(r=t.child,t.child=null):(r=l.sibling,l.sibling=null),nc(t,!1,r,l,o,n);break;case"backwards":case"unstable_legacy-backwards":for(l=null,r=t.child,t.child=null;r!==null;){if(e=r.alternate,e!==null&&Qu(e)===null){t.child=r;break}e=r.sibling,r.sibling=l,l=r,r=e}nc(t,!0,l,null,o,n);break;case"together":nc(t,!1,null,null,void 0,n);break;default:t.memoizedState=null}return t.child}function an(e,t,l){if(e!==null&&(t.dependencies=e.dependencies),Hn|=t.lanes,(l&t.childLanes)===0)if(e!==null){if(Ga(e,t,l,!1),(l&t.childLanes)===0)return null}else return null;if(e!==null&&t.child!==e.child)throw Error(s(153));if(t.child!==null){for(e=t.child,l=Il(e,e.pendingProps),t.child=l,l.return=t;e.sibling!==null;)e=e.sibling,l=l.sibling=Il(e,e.pendingProps),l.return=t;l.sibling=null}return t.child}function ac(e,t){return(e.lanes&t)!==0?!0:(e=e.dependencies,!!(e!==null&&Bu(e)))}function Tm(e,t,l){switch(t.tag){case 3:dt(t,t.stateNode.containerInfo),Rn(t,_t,e.memoizedState.cache),oa();break;case 27:case 5:Lt(t);break;case 4:dt(t,t.stateNode.containerInfo);break;case 10:Rn(t,t.type,t.memoizedProps.value);break;case 31:if(t.memoizedState!==null)return t.flags|=128,Mr(t),null;break;case 13:var n=t.memoizedState;if(n!==null)return n.dehydrated!==null?(kn(t),t.flags|=128,null):(l&t.child.childLanes)!==0?Rh(e,t,l):(kn(t),e=an(e,t,l),e!==null?e.sibling:null);kn(t);break;case 19:var r=(e.flags&128)!==0;if(n=(l&t.childLanes)!==0,n||(Ga(e,t,l,!1),n=(l&t.childLanes)!==0),r){if(n)return wh(e,t,l);t.flags|=128}if(r=t.memoizedState,r!==null&&(r.rendering=null,r.tail=null,r.lastEffect=null),I(yt,yt.current),n)break;return null;case 22:return t.lanes=0,Th(e,t,l,t.pendingProps);case 24:Rn(t,_t,e.memoizedState.cache)}return an(e,t,l)}function Dh(e,t,l){if(e!==null)if(e.memoizedProps!==t.pendingProps)At=!0;else{if(!ac(e,l)&&(t.flags&128)===0)return At=!1,Tm(e,t,l);At=(e.flags&131072)!==0}else At=!1,De&&(t.flags&1048576)!==0&&hf(t,Mi,t.index);switch(t.lanes=0,t.tag){case 16:e:{var n=t.pendingProps;if(e=pa(t.elementType),t.type=e,typeof e=="function")cr(e)?(n=ba(e,n),t.tag=1,t=Mh(null,t,e,n,l)):(t.tag=0,t=Wr(null,t,e,n,l));else{if(e!=null){var r=e.$$typeof;if(r===Se){t.tag=11,t=_h(null,t,e,n,l);break e}else if(r===R){t.tag=14,t=Eh(null,t,e,n,l);break e}}throw t=Me(e)||e,Error(s(306,t,""))}}return t;case 0:return Wr(e,t,t.type,t.pendingProps,l);case 1:return n=t.type,r=ba(n,t.pendingProps),Mh(e,t,n,r,l);case 3:e:{if(dt(t,t.stateNode.containerInfo),e===null)throw Error(s(387));n=t.pendingProps;var o=t.memoizedState;r=o.element,Ar(e,t),Ui(t,n,null,l);var h=t.memoizedState;if(n=h.cache,Rn(t,_t,n),n!==o.cache&&br(t,[_t],l,!0),Bi(),n=h.element,o.isDehydrated)if(o={element:n,isDehydrated:!1,cache:h.cache},t.updateQueue.baseState=o,t.memoizedState=o,t.flags&256){t=zh(e,t,n,l);break e}else if(n!==r){r=gl(Error(s(424)),t),zi(r),t=zh(e,t,n,l);break e}else for(e=t.stateNode.containerInfo,e.nodeType===9?e=e.body:e=e.nodeName==="HTML"?e.ownerDocument.body:e,nt=xl(e.firstChild),Rt=t,De=!0,Mn=null,bl=!0,l=Tf(t,null,n,l),t.child=l;l;)l.flags=l.flags&-3|4096,l=l.sibling;else{if(oa(),n===r){t=an(e,t,l);break e}wt(e,t,n,l)}t=t.child}return t;case 26:return ts(e,t),e===null?(l=Zd(t.type,null,t.pendingProps,null))?t.memoizedState=l:De||(l=t.type,e=t.pendingProps,n=bs(_e.current).createElement(l),n[gt]=t,n[Ut]=e,Dt(n,l,e),xt(n),t.stateNode=n):t.memoizedState=Zd(t.type,e.memoizedProps,t.pendingProps,e.memoizedState),null;case 27:return Lt(t),e===null&&De&&(n=t.stateNode=Yd(t.type,t.pendingProps,_e.current),Rt=t,bl=!0,r=nt,Qn(t.type)?(Uc=r,nt=xl(n.firstChild)):nt=r),wt(e,t,t.pendingProps.children,l),ts(e,t),e===null&&(t.flags|=4194304),t.child;case 5:return e===null&&De&&((r=n=nt)&&(n=ty(n,t.type,t.pendingProps,bl),n!==null?(t.stateNode=n,Rt=t,nt=xl(n.firstChild),bl=!1,r=!0):r=!1),r||zn(t)),Lt(t),r=t.type,o=t.pendingProps,h=e!==null?e.memoizedProps:null,n=o.children,Cc(r,o)?n=null:h!==null&&Cc(r,h)&&(t.flags|=32),t.memoizedState!==null&&(r=Rr(e,t,mm,null,null,l),nu._currentValue=r),ts(e,t),wt(e,t,n,l),t.child;case 6:return e===null&&De&&((e=l=nt)&&(l=ly(l,t.pendingProps,bl),l!==null?(t.stateNode=l,Rt=t,nt=null,e=!0):e=!1),e||zn(t)),null;case 13:return Rh(e,t,l);case 4:return dt(t,t.stateNode.containerInfo),n=t.pendingProps,e===null?t.child=ma(t,null,n,l):wt(e,t,n,l),t.child;case 11:return _h(e,t,t.type,t.pendingProps,l);case 7:return wt(e,t,t.pendingProps,l),t.child;case 8:return wt(e,t,t.pendingProps.children,l),t.child;case 12:return wt(e,t,t.pendingProps.children,l),t.child;case 10:return n=t.pendingProps,Rn(t,t.type,n.value),wt(e,t,n.children,l),t.child;case 9:return r=t.type._context,n=t.pendingProps.children,ha(t),r=Ct(r),n=n(r),t.flags|=1,wt(e,t,n,l),t.child;case 14:return Eh(e,t,t.type,t.pendingProps,l);case 15:return Ah(e,t,t.type,t.pendingProps,l);case 19:return wh(e,t,l);case 31:return Am(e,t,l);case 22:return Th(e,t,l,t.pendingProps);case 24:return ha(t),n=Ct(_t),e===null?(r=Sr(),r===null&&(r=Pe,o=vr(),r.pooledCache=o,o.refCount++,o!==null&&(r.pooledCacheLanes|=l),r=o),t.memoizedState={parent:n,cache:r},Er(t),Rn(t,_t,r)):((e.lanes&l)!==0&&(Ar(e,t),Ui(t,null,null,l),Bi()),r=e.memoizedState,o=t.memoizedState,r.parent!==n?(r={parent:n,cache:n},t.memoizedState=r,t.lanes===0&&(t.memoizedState=t.updateQueue.baseState=r),Rn(t,_t,n)):(n=o.cache,Rn(t,_t,n),n!==r.cache&&br(t,[_t],l,!0))),wt(e,t,t.pendingProps.children,l),t.child;case 29:throw t.pendingProps}throw Error(s(156,t.tag))}function un(e){e.flags|=4}function ic(e,t,l,n,r){if((t=(e.mode&32)!==0)&&(t=!1),t){if(e.flags|=16777216,(r&335544128)===r)if(e.stateNode.complete)e.flags|=8192;else if(sd())e.flags|=8192;else throw ga=Lu,_r}else e.flags&=-16777217}function kh(e,t){if(t.type!=="stylesheet"||(t.state.loading&4)!==0)e.flags&=-16777217;else if(e.flags|=16777216,!Fd(t))if(sd())e.flags|=8192;else throw ga=Lu,_r}function ns(e,t){t!==null&&(e.flags|=4),e.flags&16384&&(t=e.tag!==22?he():536870912,e.lanes|=t,Pa|=t)}function Xi(e,t){if(!De)switch(e.tailMode){case"hidden":t=e.tail;for(var l=null;t!==null;)t.alternate!==null&&(l=t),t=t.sibling;l===null?e.tail=null:l.sibling=null;break;case"collapsed":l=e.tail;for(var n=null;l!==null;)l.alternate!==null&&(n=l),l=l.sibling;n===null?t||e.tail===null?e.tail=null:e.tail.sibling=null:n.sibling=null}}function at(e){var t=e.alternate!==null&&e.alternate.child===e.child,l=0,n=0;if(t)for(var r=e.child;r!==null;)l|=r.lanes|r.childLanes,n|=r.subtreeFlags&65011712,n|=r.flags&65011712,r.return=e,r=r.sibling;else for(r=e.child;r!==null;)l|=r.lanes|r.childLanes,n|=r.subtreeFlags,n|=r.flags,r.return=e,r=r.sibling;return e.subtreeFlags|=n,e.childLanes=l,t}function jm(e,t,l){var n=t.pendingProps;switch(dr(t),t.tag){case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return at(t),null;case 1:return at(t),null;case 3:return l=t.stateNode,n=null,e!==null&&(n=e.memoizedState.cache),t.memoizedState.cache!==n&&(t.flags|=2048),tn(_t),ut(),l.pendingContext&&(l.context=l.pendingContext,l.pendingContext=null),(e===null||e.child===null)&&(La(t)?un(t):e===null||e.memoizedState.isDehydrated&&(t.flags&256)===0||(t.flags|=1024,gr())),at(t),null;case 26:var r=t.type,o=t.memoizedState;return e===null?(un(t),o!==null?(at(t),kh(t,o)):(at(t),ic(t,r,null,n,l))):o?o!==e.memoizedState?(un(t),at(t),kh(t,o)):(at(t),t.flags&=-16777217):(e=e.memoizedProps,e!==n&&un(t),at(t),ic(t,r,e,n,l)),null;case 27:if(yn(t),l=_e.current,r=t.type,e!==null&&t.stateNode!=null)e.memoizedProps!==n&&un(t);else{if(!n){if(t.stateNode===null)throw Error(s(166));return at(t),null}e=ee.current,La(t)?pf(t):(e=Yd(r,n,l),t.stateNode=e,un(t))}return at(t),null;case 5:if(yn(t),r=t.type,e!==null&&t.stateNode!=null)e.memoizedProps!==n&&un(t);else{if(!n){if(t.stateNode===null)throw Error(s(166));return at(t),null}if(o=ee.current,La(t))pf(t);else{var h=bs(_e.current);switch(o){case 1:o=h.createElementNS("http://www.w3.org/2000/svg",r);break;case 2:o=h.createElementNS("http://www.w3.org/1998/Math/MathML",r);break;default:switch(r){case"svg":o=h.createElementNS("http://www.w3.org/2000/svg",r);break;case"math":o=h.createElementNS("http://www.w3.org/1998/Math/MathML",r);break;case"script":o=h.createElement("div"),o.innerHTML="<script><\/script>",o=o.removeChild(o.firstChild);break;case"select":o=typeof n.is=="string"?h.createElement("select",{is:n.is}):h.createElement("select"),n.multiple?o.multiple=!0:n.size&&(o.size=n.size);break;default:o=typeof n.is=="string"?h.createElement(r,{is:n.is}):h.createElement(r)}}o[gt]=t,o[Ut]=n;e:for(h=t.child;h!==null;){if(h.tag===5||h.tag===6)o.appendChild(h.stateNode);else if(h.tag!==4&&h.tag!==27&&h.child!==null){h.child.return=h,h=h.child;continue}if(h===t)break e;for(;h.sibling===null;){if(h.return===null||h.return===t)break e;h=h.return}h.sibling.return=h.return,h=h.sibling}t.stateNode=o;e:switch(Dt(o,r,n),r){case"button":case"input":case"select":case"textarea":n=!!n.autoFocus;break e;case"img":n=!0;break e;default:n=!1}n&&un(t)}}return at(t),ic(t,t.type,e===null?null:e.memoizedProps,t.pendingProps,l),null;case 6:if(e&&t.stateNode!=null)e.memoizedProps!==n&&un(t);else{if(typeof n!="string"&&t.stateNode===null)throw Error(s(166));if(e=_e.current,La(t)){if(e=t.stateNode,l=t.memoizedProps,n=null,r=Rt,r!==null)switch(r.tag){case 27:case 5:n=r.memoizedProps}e[gt]=t,e=!!(e.nodeValue===l||n!==null&&n.suppressHydrationWarning===!0||Rd(e.nodeValue,l)),e||zn(t,!0)}else e=bs(e).createTextNode(n),e[gt]=t,t.stateNode=e}return at(t),null;case 31:if(l=t.memoizedState,e===null||e.memoizedState!==null){if(n=La(t),l!==null){if(e===null){if(!n)throw Error(s(318));if(e=t.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(s(557));e[gt]=t}else oa(),(t.flags&128)===0&&(t.memoizedState=null),t.flags|=4;at(t),e=!1}else l=gr(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=l),e=!0;if(!e)return t.flags&256?(ul(t),t):(ul(t),null);if((t.flags&128)!==0)throw Error(s(558))}return at(t),null;case 13:if(n=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(r=La(t),n!==null&&n.dehydrated!==null){if(e===null){if(!r)throw Error(s(318));if(r=t.memoizedState,r=r!==null?r.dehydrated:null,!r)throw Error(s(317));r[gt]=t}else oa(),(t.flags&128)===0&&(t.memoizedState=null),t.flags|=4;at(t),r=!1}else r=gr(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=r),r=!0;if(!r)return t.flags&256?(ul(t),t):(ul(t),null)}return ul(t),(t.flags&128)!==0?(t.lanes=l,t):(l=n!==null,e=e!==null&&e.memoizedState!==null,l&&(n=t.child,r=null,n.alternate!==null&&n.alternate.memoizedState!==null&&n.alternate.memoizedState.cachePool!==null&&(r=n.alternate.memoizedState.cachePool.pool),o=null,n.memoizedState!==null&&n.memoizedState.cachePool!==null&&(o=n.memoizedState.cachePool.pool),o!==r&&(n.flags|=2048)),l!==e&&l&&(t.child.flags|=8192),ns(t,t.updateQueue),at(t),null);case 4:return ut(),e===null&&Oc(t.stateNode.containerInfo),at(t),null;case 10:return tn(t.type),at(t),null;case 19:if(L(yt),n=t.memoizedState,n===null)return at(t),null;if(r=(t.flags&128)!==0,o=n.rendering,o===null)if(r)Xi(n,!1);else{if(ht!==0||e!==null&&(e.flags&128)!==0)for(e=t.child;e!==null;){if(o=Qu(e),o!==null){for(t.flags|=128,Xi(n,!1),e=o.updateQueue,t.updateQueue=e,ns(t,e),t.subtreeFlags=0,e=l,l=t.child;l!==null;)cf(l,e),l=l.sibling;return I(yt,yt.current&1|2),De&&Pl(t,n.treeForkCount),t.child}e=e.sibling}n.tail!==null&&st()>rs&&(t.flags|=128,r=!0,Xi(n,!1),t.lanes=4194304)}else{if(!r)if(e=Qu(o),e!==null){if(t.flags|=128,r=!0,e=e.updateQueue,t.updateQueue=e,ns(t,e),Xi(n,!0),n.tail===null&&n.tailMode==="hidden"&&!o.alternate&&!De)return at(t),null}else 2*st()-n.renderingStartTime>rs&&l!==536870912&&(t.flags|=128,r=!0,Xi(n,!1),t.lanes=4194304);n.isBackwards?(o.sibling=t.child,t.child=o):(e=n.last,e!==null?e.sibling=o:t.child=o,n.last=o)}return n.tail!==null?(e=n.tail,n.rendering=e,n.tail=e.sibling,n.renderingStartTime=st(),e.sibling=null,l=yt.current,I(yt,r?l&1|2:l&1),De&&Pl(t,n.treeForkCount),e):(at(t),null);case 22:case 23:return ul(t),Nr(),n=t.memoizedState!==null,e!==null?e.memoizedState!==null!==n&&(t.flags|=8192):n&&(t.flags|=8192),n?(l&536870912)!==0&&(t.flags&128)===0&&(at(t),t.subtreeFlags&6&&(t.flags|=8192)):at(t),l=t.updateQueue,l!==null&&ns(t,l.retryQueue),l=null,e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(l=e.memoizedState.cachePool.pool),n=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(n=t.memoizedState.cachePool.pool),n!==l&&(t.flags|=2048),e!==null&&L(da),null;case 24:return l=null,e!==null&&(l=e.memoizedState.cache),t.memoizedState.cache!==l&&(t.flags|=2048),tn(_t),at(t),null;case 25:return null;case 30:return null}throw Error(s(156,t.tag))}function Om(e,t){switch(dr(t),t.tag){case 1:return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return tn(_t),ut(),e=t.flags,(e&65536)!==0&&(e&128)===0?(t.flags=e&-65537|128,t):null;case 26:case 27:case 5:return yn(t),null;case 31:if(t.memoizedState!==null){if(ul(t),t.alternate===null)throw Error(s(340));oa()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 13:if(ul(t),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(s(340));oa()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return L(yt),null;case 4:return ut(),null;case 10:return tn(t.type),null;case 22:case 23:return ul(t),Nr(),e!==null&&L(da),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 24:return tn(_t),null;case 25:return null;default:return null}}function Bh(e,t){switch(dr(t),t.tag){case 3:tn(_t),ut();break;case 26:case 27:case 5:yn(t);break;case 4:ut();break;case 31:t.memoizedState!==null&&ul(t);break;case 13:ul(t);break;case 19:L(yt);break;case 10:tn(t.type);break;case 22:case 23:ul(t),Nr(),e!==null&&L(da);break;case 24:tn(_t)}}function Qi(e,t){try{var l=t.updateQueue,n=l!==null?l.lastEffect:null;if(n!==null){var r=n.next;l=r;do{if((l.tag&e)===e){n=void 0;var o=l.create,h=l.inst;n=o(),h.destroy=n}l=l.next}while(l!==r)}}catch(m){Qe(t,t.return,m)}}function Un(e,t,l){try{var n=t.updateQueue,r=n!==null?n.lastEffect:null;if(r!==null){var o=r.next;n=o;do{if((n.tag&e)===e){var h=n.inst,m=h.destroy;if(m!==void 0){h.destroy=void 0,r=t;var S=l,O=m;try{O()}catch(B){Qe(r,S,B)}}}n=n.next}while(n!==o)}}catch(B){Qe(t,t.return,B)}}function Uh(e){var t=e.updateQueue;if(t!==null){var l=e.stateNode;try{Of(t,l)}catch(n){Qe(e,e.return,n)}}}function qh(e,t,l){l.props=ba(e.type,e.memoizedProps),l.state=e.memoizedState;try{l.componentWillUnmount()}catch(n){Qe(e,t,n)}}function Zi(e,t){try{var l=e.ref;if(l!==null){switch(e.tag){case 26:case 27:case 5:var n=e.stateNode;break;case 30:n=e.stateNode;break;default:n=e.stateNode}typeof l=="function"?e.refCleanup=l(n):l.current=n}}catch(r){Qe(e,t,r)}}function Bl(e,t){var l=e.ref,n=e.refCleanup;if(l!==null)if(typeof n=="function")try{n()}catch(r){Qe(e,t,r)}finally{e.refCleanup=null,e=e.alternate,e!=null&&(e.refCleanup=null)}else if(typeof l=="function")try{l(null)}catch(r){Qe(e,t,r)}else l.current=null}function Hh(e){var t=e.type,l=e.memoizedProps,n=e.stateNode;try{e:switch(t){case"button":case"input":case"select":case"textarea":l.autoFocus&&n.focus();break e;case"img":l.src?n.src=l.src:l.srcSet&&(n.srcset=l.srcSet)}}catch(r){Qe(e,e.return,r)}}function uc(e,t,l){try{var n=e.stateNode;$m(n,e.type,l,t),n[Ut]=t}catch(r){Qe(e,e.return,r)}}function Lh(e){return e.tag===5||e.tag===3||e.tag===26||e.tag===27&&Qn(e.type)||e.tag===4}function sc(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||Lh(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.tag===27&&Qn(e.type)||e.flags&2||e.child===null||e.tag===4)continue e;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function rc(e,t,l){var n=e.tag;if(n===5||n===6)e=e.stateNode,t?(l.nodeType===9?l.body:l.nodeName==="HTML"?l.ownerDocument.body:l).insertBefore(e,t):(t=l.nodeType===9?l.body:l.nodeName==="HTML"?l.ownerDocument.body:l,t.appendChild(e),l=l._reactRootContainer,l!=null||t.onclick!==null||(t.onclick=J));else if(n!==4&&(n===27&&Qn(e.type)&&(l=e.stateNode,t=null),e=e.child,e!==null))for(rc(e,t,l),e=e.sibling;e!==null;)rc(e,t,l),e=e.sibling}function as(e,t,l){var n=e.tag;if(n===5||n===6)e=e.stateNode,t?l.insertBefore(e,t):l.appendChild(e);else if(n!==4&&(n===27&&Qn(e.type)&&(l=e.stateNode),e=e.child,e!==null))for(as(e,t,l),e=e.sibling;e!==null;)as(e,t,l),e=e.sibling}function Gh(e){var t=e.stateNode,l=e.memoizedProps;try{for(var n=e.type,r=t.attributes;r.length;)t.removeAttributeNode(r[0]);Dt(t,n,l),t[gt]=e,t[Ut]=l}catch(o){Qe(e,e.return,o)}}var sn=!1,Tt=!1,cc=!1,Yh=typeof WeakSet=="function"?WeakSet:Set,Nt=null;function Nm(e,t){if(e=e.containerInfo,zc=Ts,e=Po(e),lr(e)){if("selectionStart"in e)var l={start:e.selectionStart,end:e.selectionEnd};else e:{l=(l=e.ownerDocument)&&l.defaultView||window;var n=l.getSelection&&l.getSelection();if(n&&n.rangeCount!==0){l=n.anchorNode;var r=n.anchorOffset,o=n.focusNode;n=n.focusOffset;try{l.nodeType,o.nodeType}catch{l=null;break e}var h=0,m=-1,S=-1,O=0,B=0,G=e,N=null;t:for(;;){for(var C;G!==l||r!==0&&G.nodeType!==3||(m=h+r),G!==o||n!==0&&G.nodeType!==3||(S=h+n),G.nodeType===3&&(h+=G.nodeValue.length),(C=G.firstChild)!==null;)N=G,G=C;for(;;){if(G===e)break t;if(N===l&&++O===r&&(m=h),N===o&&++B===n&&(S=h),(C=G.nextSibling)!==null)break;G=N,N=G.parentNode}G=C}l=m===-1||S===-1?null:{start:m,end:S}}else l=null}l=l||{start:0,end:0}}else l=null;for(Rc={focusedElem:e,selectionRange:l},Ts=!1,Nt=t;Nt!==null;)if(t=Nt,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,Nt=e;else for(;Nt!==null;){switch(t=Nt,o=t.alternate,e=t.flags,t.tag){case 0:if((e&4)!==0&&(e=t.updateQueue,e=e!==null?e.events:null,e!==null))for(l=0;l<e.length;l++)r=e[l],r.ref.impl=r.nextImpl;break;case 11:case 15:break;case 1:if((e&1024)!==0&&o!==null){e=void 0,l=t,r=o.memoizedProps,o=o.memoizedState,n=l.stateNode;try{var le=ba(l.type,r);e=n.getSnapshotBeforeUpdate(le,o),n.__reactInternalSnapshotBeforeUpdate=e}catch(fe){Qe(l,l.return,fe)}}break;case 3:if((e&1024)!==0){if(e=t.stateNode.containerInfo,l=e.nodeType,l===9)Dc(e);else if(l===1)switch(e.nodeName){case"HEAD":case"HTML":case"BODY":Dc(e);break;default:e.textContent=""}}break;case 5:case 26:case 27:case 6:case 4:case 17:break;default:if((e&1024)!==0)throw Error(s(163))}if(e=t.sibling,e!==null){e.return=t.return,Nt=e;break}Nt=t.return}}function Xh(e,t,l){var n=l.flags;switch(l.tag){case 0:case 11:case 15:cn(e,l),n&4&&Qi(5,l);break;case 1:if(cn(e,l),n&4)if(e=l.stateNode,t===null)try{e.componentDidMount()}catch(h){Qe(l,l.return,h)}else{var r=ba(l.type,t.memoizedProps);t=t.memoizedState;try{e.componentDidUpdate(r,t,e.__reactInternalSnapshotBeforeUpdate)}catch(h){Qe(l,l.return,h)}}n&64&&Uh(l),n&512&&Zi(l,l.return);break;case 3:if(cn(e,l),n&64&&(e=l.updateQueue,e!==null)){if(t=null,l.child!==null)switch(l.child.tag){case 27:case 5:t=l.child.stateNode;break;case 1:t=l.child.stateNode}try{Of(e,t)}catch(h){Qe(l,l.return,h)}}break;case 27:t===null&&n&4&&Gh(l);case 26:case 5:cn(e,l),t===null&&n&4&&Hh(l),n&512&&Zi(l,l.return);break;case 12:cn(e,l);break;case 31:cn(e,l),n&4&&Vh(e,l);break;case 13:cn(e,l),n&4&&Kh(e,l),n&64&&(e=l.memoizedState,e!==null&&(e=e.dehydrated,e!==null&&(l=Um.bind(null,l),ny(e,l))));break;case 22:if(n=l.memoizedState!==null||sn,!n){t=t!==null&&t.memoizedState!==null||Tt,r=sn;var o=Tt;sn=n,(Tt=t)&&!o?on(e,l,(l.subtreeFlags&8772)!==0):cn(e,l),sn=r,Tt=o}break;case 30:break;default:cn(e,l)}}function Qh(e){var t=e.alternate;t!==null&&(e.alternate=null,Qh(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&gi(t)),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}var ct=null,Jt=!1;function rn(e,t,l){for(l=l.child;l!==null;)Zh(e,t,l),l=l.sibling}function Zh(e,t,l){if(Ot&&typeof Ot.onCommitFiberUnmount=="function")try{Ot.onCommitFiberUnmount(Zl,l)}catch{}switch(l.tag){case 26:Tt||Bl(l,t),rn(e,t,l),l.memoizedState?l.memoizedState.count--:l.stateNode&&(l=l.stateNode,l.parentNode.removeChild(l));break;case 27:Tt||Bl(l,t);var n=ct,r=Jt;Qn(l.type)&&(ct=l.stateNode,Jt=!1),rn(e,t,l),eu(l.stateNode),ct=n,Jt=r;break;case 5:Tt||Bl(l,t);case 6:if(n=ct,r=Jt,ct=null,rn(e,t,l),ct=n,Jt=r,ct!==null)if(Jt)try{(ct.nodeType===9?ct.body:ct.nodeName==="HTML"?ct.ownerDocument.body:ct).removeChild(l.stateNode)}catch(o){Qe(l,t,o)}else try{ct.removeChild(l.stateNode)}catch(o){Qe(l,t,o)}break;case 18:ct!==null&&(Jt?(e=ct,Ud(e.nodeType===9?e.body:e.nodeName==="HTML"?e.ownerDocument.body:e,l.stateNode),si(e)):Ud(ct,l.stateNode));break;case 4:n=ct,r=Jt,ct=l.stateNode.containerInfo,Jt=!0,rn(e,t,l),ct=n,Jt=r;break;case 0:case 11:case 14:case 15:Un(2,l,t),Tt||Un(4,l,t),rn(e,t,l);break;case 1:Tt||(Bl(l,t),n=l.stateNode,typeof n.componentWillUnmount=="function"&&qh(l,t,n)),rn(e,t,l);break;case 21:rn(e,t,l);break;case 22:Tt=(n=Tt)||l.memoizedState!==null,rn(e,t,l),Tt=n;break;default:rn(e,t,l)}}function Vh(e,t){if(t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null))){e=e.dehydrated;try{si(e)}catch(l){Qe(t,t.return,l)}}}function Kh(e,t){if(t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null&&(e=e.dehydrated,e!==null))))try{si(e)}catch(l){Qe(t,t.return,l)}}function Mm(e){switch(e.tag){case 31:case 13:case 19:var t=e.stateNode;return t===null&&(t=e.stateNode=new Yh),t;case 22:return e=e.stateNode,t=e._retryCache,t===null&&(t=e._retryCache=new Yh),t;default:throw Error(s(435,e.tag))}}function is(e,t){var l=Mm(e);t.forEach(function(n){if(!l.has(n)){l.add(n);var r=qm.bind(null,e,n);n.then(r,r)}})}function $t(e,t){var l=t.deletions;if(l!==null)for(var n=0;n<l.length;n++){var r=l[n],o=e,h=t,m=h;e:for(;m!==null;){switch(m.tag){case 27:if(Qn(m.type)){ct=m.stateNode,Jt=!1;break e}break;case 5:ct=m.stateNode,Jt=!1;break e;case 3:case 4:ct=m.stateNode.containerInfo,Jt=!0;break e}m=m.return}if(ct===null)throw Error(s(160));Zh(o,h,r),ct=null,Jt=!1,o=r.alternate,o!==null&&(o.return=null),r.return=null}if(t.subtreeFlags&13886)for(t=t.child;t!==null;)Jh(t,e),t=t.sibling}var Ol=null;function Jh(e,t){var l=e.alternate,n=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:$t(t,e),Ft(e),n&4&&(Un(3,e,e.return),Qi(3,e),Un(5,e,e.return));break;case 1:$t(t,e),Ft(e),n&512&&(Tt||l===null||Bl(l,l.return)),n&64&&sn&&(e=e.updateQueue,e!==null&&(n=e.callbacks,n!==null&&(l=e.shared.hiddenCallbacks,e.shared.hiddenCallbacks=l===null?n:l.concat(n))));break;case 26:var r=Ol;if($t(t,e),Ft(e),n&512&&(Tt||l===null||Bl(l,l.return)),n&4){var o=l!==null?l.memoizedState:null;if(n=e.memoizedState,l===null)if(n===null)if(e.stateNode===null){e:{n=e.type,l=e.memoizedProps,r=r.ownerDocument||r;t:switch(n){case"title":o=r.getElementsByTagName("title")[0],(!o||o[la]||o[gt]||o.namespaceURI==="http://www.w3.org/2000/svg"||o.hasAttribute("itemprop"))&&(o=r.createElement(n),r.head.insertBefore(o,r.querySelector("head > title"))),Dt(o,n,l),o[gt]=e,xt(o),n=o;break e;case"link":var h=Jd("link","href",r).get(n+(l.href||""));if(h){for(var m=0;m<h.length;m++)if(o=h[m],o.getAttribute("href")===(l.href==null||l.href===""?null:l.href)&&o.getAttribute("rel")===(l.rel==null?null:l.rel)&&o.getAttribute("title")===(l.title==null?null:l.title)&&o.getAttribute("crossorigin")===(l.crossOrigin==null?null:l.crossOrigin)){h.splice(m,1);break t}}o=r.createElement(n),Dt(o,n,l),r.head.appendChild(o);break;case"meta":if(h=Jd("meta","content",r).get(n+(l.content||""))){for(m=0;m<h.length;m++)if(o=h[m],o.getAttribute("content")===(l.content==null?null:""+l.content)&&o.getAttribute("name")===(l.name==null?null:l.name)&&o.getAttribute("property")===(l.property==null?null:l.property)&&o.getAttribute("http-equiv")===(l.httpEquiv==null?null:l.httpEquiv)&&o.getAttribute("charset")===(l.charSet==null?null:l.charSet)){h.splice(m,1);break t}}o=r.createElement(n),Dt(o,n,l),r.head.appendChild(o);break;default:throw Error(s(468,n))}o[gt]=e,xt(o),n=o}e.stateNode=n}else $d(r,e.type,e.stateNode);else e.stateNode=Kd(r,n,e.memoizedProps);else o!==n?(o===null?l.stateNode!==null&&(l=l.stateNode,l.parentNode.removeChild(l)):o.count--,n===null?$d(r,e.type,e.stateNode):Kd(r,n,e.memoizedProps)):n===null&&e.stateNode!==null&&uc(e,e.memoizedProps,l.memoizedProps)}break;case 27:$t(t,e),Ft(e),n&512&&(Tt||l===null||Bl(l,l.return)),l!==null&&n&4&&uc(e,e.memoizedProps,l.memoizedProps);break;case 5:if($t(t,e),Ft(e),n&512&&(Tt||l===null||Bl(l,l.return)),e.flags&32){r=e.stateNode;try{de(r,"")}catch(le){Qe(e,e.return,le)}}n&4&&e.stateNode!=null&&(r=e.memoizedProps,uc(e,r,l!==null?l.memoizedProps:r)),n&1024&&(cc=!0);break;case 6:if($t(t,e),Ft(e),n&4){if(e.stateNode===null)throw Error(s(162));n=e.memoizedProps,l=e.stateNode;try{l.nodeValue=n}catch(le){Qe(e,e.return,le)}}break;case 3:if(Ss=null,r=Ol,Ol=vs(t.containerInfo),$t(t,e),Ol=r,Ft(e),n&4&&l!==null&&l.memoizedState.isDehydrated)try{si(t.containerInfo)}catch(le){Qe(e,e.return,le)}cc&&(cc=!1,$h(e));break;case 4:n=Ol,Ol=vs(e.stateNode.containerInfo),$t(t,e),Ft(e),Ol=n;break;case 12:$t(t,e),Ft(e);break;case 31:$t(t,e),Ft(e),n&4&&(n=e.updateQueue,n!==null&&(e.updateQueue=null,is(e,n)));break;case 13:$t(t,e),Ft(e),e.child.flags&8192&&e.memoizedState!==null!=(l!==null&&l.memoizedState!==null)&&(ss=st()),n&4&&(n=e.updateQueue,n!==null&&(e.updateQueue=null,is(e,n)));break;case 22:r=e.memoizedState!==null;var S=l!==null&&l.memoizedState!==null,O=sn,B=Tt;if(sn=O||r,Tt=B||S,$t(t,e),Tt=B,sn=O,Ft(e),n&8192)e:for(t=e.stateNode,t._visibility=r?t._visibility&-2:t._visibility|1,r&&(l===null||S||sn||Tt||va(e)),l=null,t=e;;){if(t.tag===5||t.tag===26){if(l===null){S=l=t;try{if(o=S.stateNode,r)h=o.style,typeof h.setProperty=="function"?h.setProperty("display","none","important"):h.display="none";else{m=S.stateNode;var G=S.memoizedProps.style,N=G!=null&&G.hasOwnProperty("display")?G.display:null;m.style.display=N==null||typeof N=="boolean"?"":(""+N).trim()}}catch(le){Qe(S,S.return,le)}}}else if(t.tag===6){if(l===null){S=t;try{S.stateNode.nodeValue=r?"":S.memoizedProps}catch(le){Qe(S,S.return,le)}}}else if(t.tag===18){if(l===null){S=t;try{var C=S.stateNode;r?qd(C,!0):qd(S.stateNode,!1)}catch(le){Qe(S,S.return,le)}}}else if((t.tag!==22&&t.tag!==23||t.memoizedState===null||t===e)&&t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break e;for(;t.sibling===null;){if(t.return===null||t.return===e)break e;l===t&&(l=null),t=t.return}l===t&&(l=null),t.sibling.return=t.return,t=t.sibling}n&4&&(n=e.updateQueue,n!==null&&(l=n.retryQueue,l!==null&&(n.retryQueue=null,is(e,l))));break;case 19:$t(t,e),Ft(e),n&4&&(n=e.updateQueue,n!==null&&(e.updateQueue=null,is(e,n)));break;case 30:break;case 21:break;default:$t(t,e),Ft(e)}}function Ft(e){var t=e.flags;if(t&2){try{for(var l,n=e.return;n!==null;){if(Lh(n)){l=n;break}n=n.return}if(l==null)throw Error(s(160));switch(l.tag){case 27:var r=l.stateNode,o=sc(e);as(e,o,r);break;case 5:var h=l.stateNode;l.flags&32&&(de(h,""),l.flags&=-33);var m=sc(e);as(e,m,h);break;case 3:case 4:var S=l.stateNode.containerInfo,O=sc(e);rc(e,O,S);break;default:throw Error(s(161))}}catch(B){Qe(e,e.return,B)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function $h(e){if(e.subtreeFlags&1024)for(e=e.child;e!==null;){var t=e;$h(t),t.tag===5&&t.flags&1024&&t.stateNode.reset(),e=e.sibling}}function cn(e,t){if(t.subtreeFlags&8772)for(t=t.child;t!==null;)Xh(e,t.alternate,t),t=t.sibling}function va(e){for(e=e.child;e!==null;){var t=e;switch(t.tag){case 0:case 11:case 14:case 15:Un(4,t,t.return),va(t);break;case 1:Bl(t,t.return);var l=t.stateNode;typeof l.componentWillUnmount=="function"&&qh(t,t.return,l),va(t);break;case 27:eu(t.stateNode);case 26:case 5:Bl(t,t.return),va(t);break;case 22:t.memoizedState===null&&va(t);break;case 30:va(t);break;default:va(t)}e=e.sibling}}function on(e,t,l){for(l=l&&(t.subtreeFlags&8772)!==0,t=t.child;t!==null;){var n=t.alternate,r=e,o=t,h=o.flags;switch(o.tag){case 0:case 11:case 15:on(r,o,l),Qi(4,o);break;case 1:if(on(r,o,l),n=o,r=n.stateNode,typeof r.componentDidMount=="function")try{r.componentDidMount()}catch(O){Qe(n,n.return,O)}if(n=o,r=n.updateQueue,r!==null){var m=n.stateNode;try{var S=r.shared.hiddenCallbacks;if(S!==null)for(r.shared.hiddenCallbacks=null,r=0;r<S.length;r++)jf(S[r],m)}catch(O){Qe(n,n.return,O)}}l&&h&64&&Uh(o),Zi(o,o.return);break;case 27:Gh(o);case 26:case 5:on(r,o,l),l&&n===null&&h&4&&Hh(o),Zi(o,o.return);break;case 12:on(r,o,l);break;case 31:on(r,o,l),l&&h&4&&Vh(r,o);break;case 13:on(r,o,l),l&&h&4&&Kh(r,o);break;case 22:o.memoizedState===null&&on(r,o,l),Zi(o,o.return);break;case 30:break;default:on(r,o,l)}t=t.sibling}}function oc(e,t){var l=null;e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(l=e.memoizedState.cachePool.pool),e=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(e=t.memoizedState.cachePool.pool),e!==l&&(e!=null&&e.refCount++,l!=null&&Ri(l))}function fc(e,t){e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&Ri(e))}function Nl(e,t,l,n){if(t.subtreeFlags&10256)for(t=t.child;t!==null;)Fh(e,t,l,n),t=t.sibling}function Fh(e,t,l,n){var r=t.flags;switch(t.tag){case 0:case 11:case 15:Nl(e,t,l,n),r&2048&&Qi(9,t);break;case 1:Nl(e,t,l,n);break;case 3:Nl(e,t,l,n),r&2048&&(e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&Ri(e)));break;case 12:if(r&2048){Nl(e,t,l,n),e=t.stateNode;try{var o=t.memoizedProps,h=o.id,m=o.onPostCommit;typeof m=="function"&&m(h,t.alternate===null?"mount":"update",e.passiveEffectDuration,-0)}catch(S){Qe(t,t.return,S)}}else Nl(e,t,l,n);break;case 31:Nl(e,t,l,n);break;case 13:Nl(e,t,l,n);break;case 23:break;case 22:o=t.stateNode,h=t.alternate,t.memoizedState!==null?o._visibility&2?Nl(e,t,l,n):Vi(e,t):o._visibility&2?Nl(e,t,l,n):(o._visibility|=2,Fa(e,t,l,n,(t.subtreeFlags&10256)!==0||!1)),r&2048&&oc(h,t);break;case 24:Nl(e,t,l,n),r&2048&&fc(t.alternate,t);break;default:Nl(e,t,l,n)}}function Fa(e,t,l,n,r){for(r=r&&((t.subtreeFlags&10256)!==0||!1),t=t.child;t!==null;){var o=e,h=t,m=l,S=n,O=h.flags;switch(h.tag){case 0:case 11:case 15:Fa(o,h,m,S,r),Qi(8,h);break;case 23:break;case 22:var B=h.stateNode;h.memoizedState!==null?B._visibility&2?Fa(o,h,m,S,r):Vi(o,h):(B._visibility|=2,Fa(o,h,m,S,r)),r&&O&2048&&oc(h.alternate,h);break;case 24:Fa(o,h,m,S,r),r&&O&2048&&fc(h.alternate,h);break;default:Fa(o,h,m,S,r)}t=t.sibling}}function Vi(e,t){if(t.subtreeFlags&10256)for(t=t.child;t!==null;){var l=e,n=t,r=n.flags;switch(n.tag){case 22:Vi(l,n),r&2048&&oc(n.alternate,n);break;case 24:Vi(l,n),r&2048&&fc(n.alternate,n);break;default:Vi(l,n)}t=t.sibling}}var Ki=8192;function Wa(e,t,l){if(e.subtreeFlags&Ki)for(e=e.child;e!==null;)Wh(e,t,l),e=e.sibling}function Wh(e,t,l){switch(e.tag){case 26:Wa(e,t,l),e.flags&Ki&&e.memoizedState!==null&&gy(l,Ol,e.memoizedState,e.memoizedProps);break;case 5:Wa(e,t,l);break;case 3:case 4:var n=Ol;Ol=vs(e.stateNode.containerInfo),Wa(e,t,l),Ol=n;break;case 22:e.memoizedState===null&&(n=e.alternate,n!==null&&n.memoizedState!==null?(n=Ki,Ki=16777216,Wa(e,t,l),Ki=n):Wa(e,t,l));break;default:Wa(e,t,l)}}function Ih(e){var t=e.alternate;if(t!==null&&(e=t.child,e!==null)){t.child=null;do t=e.sibling,e.sibling=null,e=t;while(e!==null)}}function Ji(e){var t=e.deletions;if((e.flags&16)!==0){if(t!==null)for(var l=0;l<t.length;l++){var n=t[l];Nt=n,ed(n,e)}Ih(e)}if(e.subtreeFlags&10256)for(e=e.child;e!==null;)Ph(e),e=e.sibling}function Ph(e){switch(e.tag){case 0:case 11:case 15:Ji(e),e.flags&2048&&Un(9,e,e.return);break;case 3:Ji(e);break;case 12:Ji(e);break;case 22:var t=e.stateNode;e.memoizedState!==null&&t._visibility&2&&(e.return===null||e.return.tag!==13)?(t._visibility&=-3,us(e)):Ji(e);break;default:Ji(e)}}function us(e){var t=e.deletions;if((e.flags&16)!==0){if(t!==null)for(var l=0;l<t.length;l++){var n=t[l];Nt=n,ed(n,e)}Ih(e)}for(e=e.child;e!==null;){switch(t=e,t.tag){case 0:case 11:case 15:Un(8,t,t.return),us(t);break;case 22:l=t.stateNode,l._visibility&2&&(l._visibility&=-3,us(t));break;default:us(t)}e=e.sibling}}function ed(e,t){for(;Nt!==null;){var l=Nt;switch(l.tag){case 0:case 11:case 15:Un(8,l,t);break;case 23:case 22:if(l.memoizedState!==null&&l.memoizedState.cachePool!==null){var n=l.memoizedState.cachePool.pool;n!=null&&n.refCount++}break;case 24:Ri(l.memoizedState.cache)}if(n=l.child,n!==null)n.return=l,Nt=n;else e:for(l=e;Nt!==null;){n=Nt;var r=n.sibling,o=n.return;if(Qh(n),n===l){Nt=null;break e}if(r!==null){r.return=o,Nt=r;break e}Nt=o}}}var zm={getCacheForType:function(e){var t=Ct(_t),l=t.data.get(e);return l===void 0&&(l=e(),t.data.set(e,l)),l},cacheSignal:function(){return Ct(_t).controller.signal}},Rm=typeof WeakMap=="function"?WeakMap:Map,Le=0,Pe=null,Oe=null,Re=0,Xe=0,sl=null,qn=!1,Ia=!1,hc=!1,fn=0,ht=0,Hn=0,xa=0,dc=0,rl=0,Pa=0,$i=null,Wt=null,pc=!1,ss=0,td=0,rs=1/0,cs=null,Ln=null,jt=0,Gn=null,ei=null,hn=0,gc=0,mc=null,ld=null,Fi=0,yc=null;function cl(){return(Le&2)!==0&&Re!==0?Re&-Re:D.T!==null?Ec():ja()}function nd(){if(rl===0)if((Re&536870912)===0||De){var e=Tl;Tl<<=1,(Tl&3932160)===0&&(Tl=262144),rl=e}else rl=536870912;return e=il.current,e!==null&&(e.flags|=32),rl}function It(e,t,l){(e===Pe&&(Xe===2||Xe===9)||e.cancelPendingCommit!==null)&&(ti(e,0),Yn(e,Re,rl,!1)),Ie(e,l),((Le&2)===0||e!==Pe)&&(e===Pe&&((Le&2)===0&&(xa|=l),ht===4&&Yn(e,Re,rl,!1)),Ul(e))}function ad(e,t,l){if((Le&6)!==0)throw Error(s(327));var n=!l&&(t&127)===0&&(t&e.expiredLanes)===0||M(e,t),r=n?Dm(e,t):vc(e,t,!0),o=n;do{if(r===0){Ia&&!n&&Yn(e,t,0,!1);break}else{if(l=e.current.alternate,o&&!Cm(l)){r=vc(e,t,!1),o=!1;continue}if(r===2){if(o=t,e.errorRecoveryDisabledLanes&o)var h=0;else h=e.pendingLanes&-536870913,h=h!==0?h:h&536870912?536870912:0;if(h!==0){t=h;e:{var m=e;r=$i;var S=m.current.memoizedState.isDehydrated;if(S&&(ti(m,h).flags|=256),h=vc(m,h,!1),h!==2){if(hc&&!S){m.errorRecoveryDisabledLanes|=o,xa|=o,r=4;break e}o=Wt,Wt=r,o!==null&&(Wt===null?Wt=o:Wt.push.apply(Wt,o))}r=h}if(o=!1,r!==2)continue}}if(r===1){ti(e,0),Yn(e,t,0,!0);break}e:{switch(n=e,o=r,o){case 0:case 1:throw Error(s(345));case 4:if((t&4194048)!==t)break;case 6:Yn(n,t,rl,!qn);break e;case 2:Wt=null;break;case 3:case 5:break;default:throw Error(s(329))}if((t&62914560)===t&&(r=ss+300-st(),10<r)){if(Yn(n,t,rl,!qn),v(n,0,!0)!==0)break e;hn=t,n.timeoutHandle=kd(id.bind(null,n,l,Wt,cs,pc,t,rl,xa,Pa,qn,o,"Throttled",-0,0),r);break e}id(n,l,Wt,cs,pc,t,rl,xa,Pa,qn,o,null,-0,0)}}break}while(!0);Ul(e)}function id(e,t,l,n,r,o,h,m,S,O,B,G,N,C){if(e.timeoutHandle=-1,G=t.subtreeFlags,G&8192||(G&16785408)===16785408){G={stylesheets:null,count:0,imgCount:0,imgBytes:0,suspenseyImages:[],waitingForImages:!0,waitingForViewTransition:!1,unsuspend:J},Wh(t,o,G);var le=(o&62914560)===o?ss-st():(o&4194048)===o?td-st():0;if(le=my(G,le),le!==null){hn=o,e.cancelPendingCommit=le(dd.bind(null,e,t,o,l,n,r,h,m,S,B,G,null,N,C)),Yn(e,o,h,!O);return}}dd(e,t,o,l,n,r,h,m,S)}function Cm(e){for(var t=e;;){var l=t.tag;if((l===0||l===11||l===15)&&t.flags&16384&&(l=t.updateQueue,l!==null&&(l=l.stores,l!==null)))for(var n=0;n<l.length;n++){var r=l[n],o=r.getSnapshot;r=r.value;try{if(!nl(o(),r))return!1}catch{return!1}}if(l=t.child,t.subtreeFlags&16384&&l!==null)l.return=t,t=l;else{if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return!0;t=t.return}t.sibling.return=t.return,t=t.sibling}}return!0}function Yn(e,t,l,n){t&=~dc,t&=~xa,e.suspendedLanes|=t,e.pingedLanes&=~t,n&&(e.warmLanes|=t),n=e.expirationTimes;for(var r=t;0<r;){var o=31-Mt(r),h=1<<o;n[o]=-1,r&=~h}l!==0&&te(e,l,t)}function os(){return(Le&6)===0?(Wi(0),!1):!0}function bc(){if(Oe!==null){if(Xe===0)var e=Oe.return;else e=Oe,en=fa=null,Dr(e),Za=null,wi=0,e=Oe;for(;e!==null;)Bh(e.alternate,e),e=e.return;Oe=null}}function ti(e,t){var l=e.timeoutHandle;l!==-1&&(e.timeoutHandle=-1,Im(l)),l=e.cancelPendingCommit,l!==null&&(e.cancelPendingCommit=null,l()),hn=0,bc(),Pe=e,Oe=l=Il(e.current,null),Re=t,Xe=0,sl=null,qn=!1,Ia=M(e,t),hc=!1,Pa=rl=dc=xa=Hn=ht=0,Wt=$i=null,pc=!1,(t&8)!==0&&(t|=t&32);var n=e.entangledLanes;if(n!==0)for(e=e.entanglements,n&=t;0<n;){var r=31-Mt(n),o=1<<r;t|=e[r],n&=~o}return fn=t,Ru(),l}function ud(e,t){Ae=null,D.H=Gi,t===Qa||t===Hu?(t=_f(),Xe=3):t===_r?(t=_f(),Xe=4):Xe=t===Fr?8:t!==null&&typeof t=="object"&&typeof t.then=="function"?6:1,sl=t,Oe===null&&(ht=1,Pu(e,gl(t,e.current)))}function sd(){var e=il.current;return e===null?!0:(Re&4194048)===Re?vl===null:(Re&62914560)===Re||(Re&536870912)!==0?e===vl:!1}function rd(){var e=D.H;return D.H=Gi,e===null?Gi:e}function cd(){var e=D.A;return D.A=zm,e}function fs(){ht=4,qn||(Re&4194048)!==Re&&il.current!==null||(Ia=!0),(Hn&134217727)===0&&(xa&134217727)===0||Pe===null||Yn(Pe,Re,rl,!1)}function vc(e,t,l){var n=Le;Le|=2;var r=rd(),o=cd();(Pe!==e||Re!==t)&&(cs=null,ti(e,t)),t=!1;var h=ht;e:do try{if(Xe!==0&&Oe!==null){var m=Oe,S=sl;switch(Xe){case 8:bc(),h=6;break e;case 3:case 2:case 9:case 6:il.current===null&&(t=!0);var O=Xe;if(Xe=0,sl=null,li(e,m,S,O),l&&Ia){h=0;break e}break;default:O=Xe,Xe=0,sl=null,li(e,m,S,O)}}wm(),h=ht;break}catch(B){ud(e,B)}while(!0);return t&&e.shellSuspendCounter++,en=fa=null,Le=n,D.H=r,D.A=o,Oe===null&&(Pe=null,Re=0,Ru()),h}function wm(){for(;Oe!==null;)od(Oe)}function Dm(e,t){var l=Le;Le|=2;var n=rd(),r=cd();Pe!==e||Re!==t?(cs=null,rs=st()+500,ti(e,t)):Ia=M(e,t);e:do try{if(Xe!==0&&Oe!==null){t=Oe;var o=sl;t:switch(Xe){case 1:Xe=0,sl=null,li(e,t,o,1);break;case 2:case 9:if(xf(o)){Xe=0,sl=null,fd(t);break}t=function(){Xe!==2&&Xe!==9||Pe!==e||(Xe=7),Ul(e)},o.then(t,t);break e;case 3:Xe=7;break e;case 4:Xe=5;break e;case 7:xf(o)?(Xe=0,sl=null,fd(t)):(Xe=0,sl=null,li(e,t,o,7));break;case 5:var h=null;switch(Oe.tag){case 26:h=Oe.memoizedState;case 5:case 27:var m=Oe;if(h?Fd(h):m.stateNode.complete){Xe=0,sl=null;var S=m.sibling;if(S!==null)Oe=S;else{var O=m.return;O!==null?(Oe=O,hs(O)):Oe=null}break t}}Xe=0,sl=null,li(e,t,o,5);break;case 6:Xe=0,sl=null,li(e,t,o,6);break;case 8:bc(),ht=6;break e;default:throw Error(s(462))}}km();break}catch(B){ud(e,B)}while(!0);return en=fa=null,D.H=n,D.A=r,Le=l,Oe!==null?0:(Pe=null,Re=0,Ru(),ht)}function km(){for(;Oe!==null&&!Pn();)od(Oe)}function od(e){var t=Dh(e.alternate,e,fn);e.memoizedProps=e.pendingProps,t===null?hs(e):Oe=t}function fd(e){var t=e,l=t.alternate;switch(t.tag){case 15:case 0:t=Nh(l,t,t.pendingProps,t.type,void 0,Re);break;case 11:t=Nh(l,t,t.pendingProps,t.type.render,t.ref,Re);break;case 5:Dr(t);default:Bh(l,t),t=Oe=cf(t,fn),t=Dh(l,t,fn)}e.memoizedProps=e.pendingProps,t===null?hs(e):Oe=t}function li(e,t,l,n){en=fa=null,Dr(t),Za=null,wi=0;var r=t.return;try{if(Em(e,r,t,l,Re)){ht=1,Pu(e,gl(l,e.current)),Oe=null;return}}catch(o){if(r!==null)throw Oe=r,o;ht=1,Pu(e,gl(l,e.current)),Oe=null;return}t.flags&32768?(De||n===1?e=!0:Ia||(Re&536870912)!==0?e=!1:(qn=e=!0,(n===2||n===9||n===3||n===6)&&(n=il.current,n!==null&&n.tag===13&&(n.flags|=16384))),hd(t,e)):hs(t)}function hs(e){var t=e;do{if((t.flags&32768)!==0){hd(t,qn);return}e=t.return;var l=jm(t.alternate,t,fn);if(l!==null){Oe=l;return}if(t=t.sibling,t!==null){Oe=t;return}Oe=t=e}while(t!==null);ht===0&&(ht=5)}function hd(e,t){do{var l=Om(e.alternate,e);if(l!==null){l.flags&=32767,Oe=l;return}if(l=e.return,l!==null&&(l.flags|=32768,l.subtreeFlags=0,l.deletions=null),!t&&(e=e.sibling,e!==null)){Oe=e;return}Oe=e=l}while(e!==null);ht=6,Oe=null}function dd(e,t,l,n,r,o,h,m,S){e.cancelPendingCommit=null;do ds();while(jt!==0);if((Le&6)!==0)throw Error(s(327));if(t!==null){if(t===e.current)throw Error(s(177));if(o=t.lanes|t.childLanes,o|=sr,ne(e,l,o,h,m,S),e===Pe&&(Oe=Pe=null,Re=0),ei=t,Gn=e,hn=l,gc=o,mc=r,ld=n,(t.subtreeFlags&10256)!==0||(t.flags&10256)!==0?(e.callbackNode=null,e.callbackPriority=0,Hm(Xl,function(){return bd(),null})):(e.callbackNode=null,e.callbackPriority=0),n=(t.flags&13878)!==0,(t.subtreeFlags&13878)!==0||n){n=D.T,D.T=null,r=F.p,F.p=2,h=Le,Le|=4;try{Nm(e,t,l)}finally{Le=h,F.p=r,D.T=n}}jt=1,pd(),gd(),md()}}function pd(){if(jt===1){jt=0;var e=Gn,t=ei,l=(t.flags&13878)!==0;if((t.subtreeFlags&13878)!==0||l){l=D.T,D.T=null;var n=F.p;F.p=2;var r=Le;Le|=4;try{Jh(t,e);var o=Rc,h=Po(e.containerInfo),m=o.focusedElem,S=o.selectionRange;if(h!==m&&m&&m.ownerDocument&&Io(m.ownerDocument.documentElement,m)){if(S!==null&&lr(m)){var O=S.start,B=S.end;if(B===void 0&&(B=O),"selectionStart"in m)m.selectionStart=O,m.selectionEnd=Math.min(B,m.value.length);else{var G=m.ownerDocument||document,N=G&&G.defaultView||window;if(N.getSelection){var C=N.getSelection(),le=m.textContent.length,fe=Math.min(S.start,le),Fe=S.end===void 0?fe:Math.min(S.end,le);!C.extend&&fe>Fe&&(h=Fe,Fe=fe,fe=h);var T=Wo(m,fe),_=Wo(m,Fe);if(T&&_&&(C.rangeCount!==1||C.anchorNode!==T.node||C.anchorOffset!==T.offset||C.focusNode!==_.node||C.focusOffset!==_.offset)){var j=G.createRange();j.setStart(T.node,T.offset),C.removeAllRanges(),fe>Fe?(C.addRange(j),C.extend(_.node,_.offset)):(j.setEnd(_.node,_.offset),C.addRange(j))}}}}for(G=[],C=m;C=C.parentNode;)C.nodeType===1&&G.push({element:C,left:C.scrollLeft,top:C.scrollTop});for(typeof m.focus=="function"&&m.focus(),m=0;m<G.length;m++){var H=G[m];H.element.scrollLeft=H.left,H.element.scrollTop=H.top}}Ts=!!zc,Rc=zc=null}finally{Le=r,F.p=n,D.T=l}}e.current=t,jt=2}}function gd(){if(jt===2){jt=0;var e=Gn,t=ei,l=(t.flags&8772)!==0;if((t.subtreeFlags&8772)!==0||l){l=D.T,D.T=null;var n=F.p;F.p=2;var r=Le;Le|=4;try{Xh(e,t.alternate,t)}finally{Le=r,F.p=n,D.T=l}}jt=3}}function md(){if(jt===4||jt===3){jt=0,ea();var e=Gn,t=ei,l=hn,n=ld;(t.subtreeFlags&10256)!==0||(t.flags&10256)!==0?jt=5:(jt=0,ei=Gn=null,yd(e,e.pendingLanes));var r=e.pendingLanes;if(r===0&&(Ln=null),Kl(l),t=t.stateNode,Ot&&typeof Ot.onCommitFiberRoot=="function")try{Ot.onCommitFiberRoot(Zl,t,void 0,(t.current.flags&128)===128)}catch{}if(n!==null){t=D.T,r=F.p,F.p=2,D.T=null;try{for(var o=e.onRecoverableError,h=0;h<n.length;h++){var m=n[h];o(m.value,{componentStack:m.stack})}}finally{D.T=t,F.p=r}}(hn&3)!==0&&ds(),Ul(e),r=e.pendingLanes,(l&261930)!==0&&(r&42)!==0?e===yc?Fi++:(Fi=0,yc=e):Fi=0,Wi(0)}}function yd(e,t){(e.pooledCacheLanes&=t)===0&&(t=e.pooledCache,t!=null&&(e.pooledCache=null,Ri(t)))}function ds(){return pd(),gd(),md(),bd()}function bd(){if(jt!==5)return!1;var e=Gn,t=gc;gc=0;var l=Kl(hn),n=D.T,r=F.p;try{F.p=32>l?32:l,D.T=null,l=mc,mc=null;var o=Gn,h=hn;if(jt=0,ei=Gn=null,hn=0,(Le&6)!==0)throw Error(s(331));var m=Le;if(Le|=4,Ph(o.current),Fh(o,o.current,h,l),Le=m,Wi(0,!1),Ot&&typeof Ot.onPostCommitFiberRoot=="function")try{Ot.onPostCommitFiberRoot(Zl,o)}catch{}return!0}finally{F.p=r,D.T=n,yd(e,t)}}function vd(e,t,l){t=gl(l,t),t=$r(e.stateNode,t,2),e=Dn(e,t,2),e!==null&&(Ie(e,2),Ul(e))}function Qe(e,t,l){if(e.tag===3)vd(e,e,l);else for(;t!==null;){if(t.tag===3){vd(t,e,l);break}else if(t.tag===1){var n=t.stateNode;if(typeof t.type.getDerivedStateFromError=="function"||typeof n.componentDidCatch=="function"&&(Ln===null||!Ln.has(n))){e=gl(l,e),l=xh(2),n=Dn(t,l,2),n!==null&&(Sh(l,n,t,e),Ie(n,2),Ul(n));break}}t=t.return}}function xc(e,t,l){var n=e.pingCache;if(n===null){n=e.pingCache=new Rm;var r=new Set;n.set(t,r)}else r=n.get(t),r===void 0&&(r=new Set,n.set(t,r));r.has(l)||(hc=!0,r.add(l),e=Bm.bind(null,e,t,l),t.then(e,e))}function Bm(e,t,l){var n=e.pingCache;n!==null&&n.delete(t),e.pingedLanes|=e.suspendedLanes&l,e.warmLanes&=~l,Pe===e&&(Re&l)===l&&(ht===4||ht===3&&(Re&62914560)===Re&&300>st()-ss?(Le&2)===0&&ti(e,0):dc|=l,Pa===Re&&(Pa=0)),Ul(e)}function xd(e,t){t===0&&(t=he()),e=ra(e,t),e!==null&&(Ie(e,t),Ul(e))}function Um(e){var t=e.memoizedState,l=0;t!==null&&(l=t.retryLane),xd(e,l)}function qm(e,t){var l=0;switch(e.tag){case 31:case 13:var n=e.stateNode,r=e.memoizedState;r!==null&&(l=r.retryLane);break;case 19:n=e.stateNode;break;case 22:n=e.stateNode._retryCache;break;default:throw Error(s(314))}n!==null&&n.delete(t),xd(e,l)}function Hm(e,t){return Al(e,t)}var ps=null,ni=null,Sc=!1,gs=!1,_c=!1,Xn=0;function Ul(e){e!==ni&&e.next===null&&(ni===null?ps=ni=e:ni=ni.next=e),gs=!0,Sc||(Sc=!0,Gm())}function Wi(e,t){if(!_c&&gs){_c=!0;do for(var l=!1,n=ps;n!==null;){if(e!==0){var r=n.pendingLanes;if(r===0)var o=0;else{var h=n.suspendedLanes,m=n.pingedLanes;o=(1<<31-Mt(42|e)+1)-1,o&=r&~(h&~m),o=o&201326741?o&201326741|1:o?o|2:0}o!==0&&(l=!0,Ad(n,o))}else o=Re,o=v(n,n===Pe?o:0,n.cancelPendingCommit!==null||n.timeoutHandle!==-1),(o&3)===0||M(n,o)||(l=!0,Ad(n,o));n=n.next}while(l);_c=!1}}function Lm(){Sd()}function Sd(){gs=Sc=!1;var e=0;Xn!==0&&Wm()&&(e=Xn);for(var t=st(),l=null,n=ps;n!==null;){var r=n.next,o=_d(n,t);o===0?(n.next=null,l===null?ps=r:l.next=r,r===null&&(ni=l)):(l=n,(e!==0||(o&3)!==0)&&(gs=!0)),n=r}jt!==0&&jt!==5||Wi(e),Xn!==0&&(Xn=0)}function _d(e,t){for(var l=e.suspendedLanes,n=e.pingedLanes,r=e.expirationTimes,o=e.pendingLanes&-62914561;0<o;){var h=31-Mt(o),m=1<<h,S=r[h];S===-1?((m&l)===0||(m&n)!==0)&&(r[h]=Y(m,t)):S<=t&&(e.expiredLanes|=m),o&=~m}if(t=Pe,l=Re,l=v(e,e===t?l:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),n=e.callbackNode,l===0||e===t&&(Xe===2||Xe===9)||e.cancelPendingCommit!==null)return n!==null&&n!==null&&xn(n),e.callbackNode=null,e.callbackPriority=0;if((l&3)===0||M(e,l)){if(t=l&-l,t===e.callbackPriority)return t;switch(n!==null&&xn(n),Kl(l)){case 2:case 8:l=Cl;break;case 32:l=Xl;break;case 268435456:l=Sn;break;default:l=Xl}return n=Ed.bind(null,e),l=Al(l,n),e.callbackPriority=t,e.callbackNode=l,t}return n!==null&&n!==null&&xn(n),e.callbackPriority=2,e.callbackNode=null,2}function Ed(e,t){if(jt!==0&&jt!==5)return e.callbackNode=null,e.callbackPriority=0,null;var l=e.callbackNode;if(ds()&&e.callbackNode!==l)return null;var n=Re;return n=v(e,e===Pe?n:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),n===0?null:(ad(e,n,t),_d(e,st()),e.callbackNode!=null&&e.callbackNode===l?Ed.bind(null,e):null)}function Ad(e,t){if(ds())return null;ad(e,t,!0)}function Gm(){Pm(function(){(Le&6)!==0?Al(Bt,Lm):Sd()})}function Ec(){if(Xn===0){var e=Ya;e===0&&(e=el,el<<=1,(el&261888)===0&&(el=256)),Xn=e}return Xn}function Td(e){return e==null||typeof e=="symbol"||typeof e=="boolean"?null:typeof e=="function"?e:jn(""+e)}function jd(e,t){var l=t.ownerDocument.createElement("input");return l.name=t.name,l.value=t.value,e.id&&l.setAttribute("form",e.id),t.parentNode.insertBefore(l,t),e=new FormData(e),l.parentNode.removeChild(l),e}function Ym(e,t,l,n,r){if(t==="submit"&&l&&l.stateNode===r){var o=Td((r[Ut]||null).action),h=n.submitter;h&&(t=(t=h[Ut]||null)?Td(t.formAction):h.getAttribute("formAction"),t!==null&&(o=t,h=null));var m=new Ou("action","action",null,n,r);e.push({event:m,listeners:[{instance:null,listener:function(){if(n.defaultPrevented){if(Xn!==0){var S=h?jd(r,h):new FormData(r);Xr(l,{pending:!0,data:S,method:r.method,action:o},null,S)}}else typeof o=="function"&&(m.preventDefault(),S=h?jd(r,h):new FormData(r),Xr(l,{pending:!0,data:S,method:r.method,action:o},o,S))},currentTarget:r}]})}}for(var Ac=0;Ac<ur.length;Ac++){var Tc=ur[Ac],Xm=Tc.toLowerCase(),Qm=Tc[0].toUpperCase()+Tc.slice(1);jl(Xm,"on"+Qm)}jl(lf,"onAnimationEnd"),jl(nf,"onAnimationIteration"),jl(af,"onAnimationStart"),jl("dblclick","onDoubleClick"),jl("focusin","onFocus"),jl("focusout","onBlur"),jl(um,"onTransitionRun"),jl(sm,"onTransitionStart"),jl(rm,"onTransitionCancel"),jl(uf,"onTransitionEnd"),Z("onMouseEnter",["mouseout","mouseover"]),Z("onMouseLeave",["mouseout","mouseover"]),Z("onPointerEnter",["pointerout","pointerover"]),Z("onPointerLeave",["pointerout","pointerover"]),$l("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),$l("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),$l("onBeforeInput",["compositionend","keypress","textInput","paste"]),$l("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),$l("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),$l("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Ii="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(" "),Zm=new Set("beforetoggle cancel close invalid load scroll scrollend toggle".split(" ").concat(Ii));function Od(e,t){t=(t&4)!==0;for(var l=0;l<e.length;l++){var n=e[l],r=n.event;n=n.listeners;e:{var o=void 0;if(t)for(var h=n.length-1;0<=h;h--){var m=n[h],S=m.instance,O=m.currentTarget;if(m=m.listener,S!==o&&r.isPropagationStopped())break e;o=m,r.currentTarget=O;try{o(r)}catch(B){zu(B)}r.currentTarget=null,o=S}else for(h=0;h<n.length;h++){if(m=n[h],S=m.instance,O=m.currentTarget,m=m.listener,S!==o&&r.isPropagationStopped())break e;o=m,r.currentTarget=O;try{o(r)}catch(B){zu(B)}r.currentTarget=null,o=S}}}}function Ne(e,t){var l=t[pi];l===void 0&&(l=t[pi]=new Set);var n=e+"__bubble";l.has(n)||(Nd(t,e,2,!1),l.add(n))}function jc(e,t,l){var n=0;t&&(n|=4),Nd(l,e,n,t)}var ms="_reactListening"+Math.random().toString(36).slice(2);function Oc(e){if(!e[ms]){e[ms]=!0,vu.forEach(function(l){l!=="selectionchange"&&(Zm.has(l)||jc(l,!1,e),jc(l,!0,e))});var t=e.nodeType===9?e:e.ownerDocument;t===null||t[ms]||(t[ms]=!0,jc("selectionchange",!1,t))}}function Nd(e,t,l,n){switch(np(t)){case 2:var r=vy;break;case 8:r=xy;break;default:r=Yc}l=r.bind(null,t,l,e),r=void 0,!Ks||t!=="touchstart"&&t!=="touchmove"&&t!=="wheel"||(r=!0),n?r!==void 0?e.addEventListener(t,l,{capture:!0,passive:r}):e.addEventListener(t,l,!0):r!==void 0?e.addEventListener(t,l,{passive:r}):e.addEventListener(t,l,!1)}function Nc(e,t,l,n,r){var o=n;if((t&1)===0&&(t&2)===0&&n!==null)e:for(;;){if(n===null)return;var h=n.tag;if(h===3||h===4){var m=n.stateNode.containerInfo;if(m===r)break;if(h===4)for(h=n.return;h!==null;){var S=h.tag;if((S===3||S===4)&&h.stateNode.containerInfo===r)return;h=h.return}for(;m!==null;){if(h=Gt(m),h===null)return;if(S=h.tag,S===5||S===6||S===26||S===27){n=o=h;continue e}m=m.parentNode}}n=n.return}Eu(function(){var O=o,B=Ee(l),G=[];e:{var N=sf.get(e);if(N!==void 0){var C=Ou,le=e;switch(e){case"keypress":if(Tu(l)===0)break e;case"keydown":case"keyup":C=qg;break;case"focusin":le="focus",C=Ws;break;case"focusout":le="blur",C=Ws;break;case"beforeblur":case"afterblur":C=Ws;break;case"click":if(l.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":C=ko;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":C=jg;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":C=Gg;break;case lf:case nf:case af:C=Mg;break;case uf:C=Xg;break;case"scroll":case"scrollend":C=Ag;break;case"wheel":C=Zg;break;case"copy":case"cut":case"paste":C=Rg;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":C=Uo;break;case"toggle":case"beforetoggle":C=Kg}var fe=(t&4)!==0,Fe=!fe&&(e==="scroll"||e==="scrollend"),T=fe?N!==null?N+"Capture":null:N;fe=[];for(var _=O,j;_!==null;){var H=_;if(j=H.stateNode,H=H.tag,H!==5&&H!==26&&H!==27||j===null||T===null||(H=xi(_,T),H!=null&&fe.push(Pi(_,H,j))),Fe)break;_=_.return}0<fe.length&&(N=new C(N,le,null,l,B),G.push({event:N,listeners:fe}))}}if((t&7)===0){e:{if(N=e==="mouseover"||e==="pointerover",C=e==="mouseout"||e==="pointerout",N&&l!==ae&&(le=l.relatedTarget||l.fromElement)&&(Gt(le)||le[_n]))break e;if((C||N)&&(N=B.window===B?B:(N=B.ownerDocument)?N.defaultView||N.parentWindow:window,C?(le=l.relatedTarget||l.toElement,C=O,le=le?Gt(le):null,le!==null&&(Fe=f(le),fe=le.tag,le!==Fe||fe!==5&&fe!==27&&fe!==6)&&(le=null)):(C=null,le=O),C!==le)){if(fe=ko,H="onMouseLeave",T="onMouseEnter",_="mouse",(e==="pointerout"||e==="pointerover")&&(fe=Uo,H="onPointerLeave",T="onPointerEnter",_="pointer"),Fe=C==null?N:En(C),j=le==null?N:En(le),N=new fe(H,_+"leave",C,l,B),N.target=Fe,N.relatedTarget=j,H=null,Gt(B)===O&&(fe=new fe(T,_+"enter",le,l,B),fe.target=j,fe.relatedTarget=Fe,H=fe),Fe=H,C&&le)t:{for(fe=Vm,T=C,_=le,j=0,H=T;H;H=fe(H))j++;H=0;for(var ce=_;ce;ce=fe(ce))H++;for(;0<j-H;)T=fe(T),j--;for(;0<H-j;)_=fe(_),H--;for(;j--;){if(T===_||_!==null&&T===_.alternate){fe=T;break t}T=fe(T),_=fe(_)}fe=null}else fe=null;C!==null&&Md(G,N,C,fe,!1),le!==null&&Fe!==null&&Md(G,Fe,le,fe,!0)}}e:{if(N=O?En(O):window,C=N.nodeName&&N.nodeName.toLowerCase(),C==="select"||C==="input"&&N.type==="file")var Ue=Zo;else if(Xo(N))if(Vo)Ue=nm;else{Ue=tm;var ie=em}else C=N.nodeName,!C||C.toLowerCase()!=="input"||N.type!=="checkbox"&&N.type!=="radio"?O&&Tn(O.elementType)&&(Ue=Zo):Ue=lm;if(Ue&&(Ue=Ue(e,O))){Qo(G,Ue,l,B);break e}ie&&ie(e,N,O),e==="focusout"&&O&&N.type==="number"&&O.memoizedProps.value!=null&&Ra(N,"number",N.value)}switch(ie=O?En(O):window,e){case"focusin":(Xo(ie)||ie.contentEditable==="true")&&(Da=ie,nr=O,Ni=null);break;case"focusout":Ni=nr=Da=null;break;case"mousedown":ar=!0;break;case"contextmenu":case"mouseup":case"dragend":ar=!1,ef(G,l,B);break;case"selectionchange":if(im)break;case"keydown":case"keyup":ef(G,l,B)}var Te;if(Ps)e:{switch(e){case"compositionstart":var Ce="onCompositionStart";break e;case"compositionend":Ce="onCompositionEnd";break e;case"compositionupdate":Ce="onCompositionUpdate";break e}Ce=void 0}else wa?Go(e,l)&&(Ce="onCompositionEnd"):e==="keydown"&&l.keyCode===229&&(Ce="onCompositionStart");Ce&&(qo&&l.locale!=="ko"&&(wa||Ce!=="onCompositionStart"?Ce==="onCompositionEnd"&&wa&&(Te=wo()):(On=B,Js="value"in On?On.value:On.textContent,wa=!0)),ie=ys(O,Ce),0<ie.length&&(Ce=new Bo(Ce,e,null,l,B),G.push({event:Ce,listeners:ie}),Te?Ce.data=Te:(Te=Yo(l),Te!==null&&(Ce.data=Te)))),(Te=$g?Fg(e,l):Wg(e,l))&&(Ce=ys(O,"onBeforeInput"),0<Ce.length&&(ie=new Bo("onBeforeInput","beforeinput",null,l,B),G.push({event:ie,listeners:Ce}),ie.data=Te)),Ym(G,e,O,l,B)}Od(G,t)})}function Pi(e,t,l){return{instance:e,listener:t,currentTarget:l}}function ys(e,t){for(var l=t+"Capture",n=[];e!==null;){var r=e,o=r.stateNode;if(r=r.tag,r!==5&&r!==26&&r!==27||o===null||(r=xi(e,l),r!=null&&n.unshift(Pi(e,r,o)),r=xi(e,t),r!=null&&n.push(Pi(e,r,o))),e.tag===3)return n;e=e.return}return[]}function Vm(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5&&e.tag!==27);return e||null}function Md(e,t,l,n,r){for(var o=t._reactName,h=[];l!==null&&l!==n;){var m=l,S=m.alternate,O=m.stateNode;if(m=m.tag,S!==null&&S===n)break;m!==5&&m!==26&&m!==27||O===null||(S=O,r?(O=xi(l,o),O!=null&&h.unshift(Pi(l,O,S))):r||(O=xi(l,o),O!=null&&h.push(Pi(l,O,S)))),l=l.return}h.length!==0&&e.push({event:t,listeners:h})}var Km=/\r\n?/g,Jm=/\u0000|\uFFFD/g;function zd(e){return(typeof e=="string"?e:""+e).replace(Km,`
9
- `).replace(Jm,"")}function Rd(e,t){return t=zd(t),zd(e)===t}function $e(e,t,l,n,r,o){switch(l){case"children":typeof n=="string"?t==="body"||t==="textarea"&&n===""||de(e,n):(typeof n=="number"||typeof n=="bigint")&&t!=="body"&&de(e,""+n);break;case"className":tl(e,"class",n);break;case"tabIndex":tl(e,"tabindex",n);break;case"dir":case"role":case"viewBox":case"width":case"height":tl(e,l,n);break;case"style":Ye(e,n,o);break;case"data":if(t!=="object"){tl(e,"data",n);break}case"src":case"href":if(n===""&&(t!=="a"||l!=="href")){e.removeAttribute(l);break}if(n==null||typeof n=="function"||typeof n=="symbol"||typeof n=="boolean"){e.removeAttribute(l);break}n=jn(""+n),e.setAttribute(l,n);break;case"action":case"formAction":if(typeof n=="function"){e.setAttribute(l,"javascript:throw new Error('A React form was unexpectedly submitted. If you called form.submit() manually, consider using form.requestSubmit() instead. If you\\'re trying to use event.stopPropagation() in a submit event handler, consider also calling event.preventDefault().')");break}else typeof o=="function"&&(l==="formAction"?(t!=="input"&&$e(e,t,"name",r.name,r,null),$e(e,t,"formEncType",r.formEncType,r,null),$e(e,t,"formMethod",r.formMethod,r,null),$e(e,t,"formTarget",r.formTarget,r,null)):($e(e,t,"encType",r.encType,r,null),$e(e,t,"method",r.method,r,null),$e(e,t,"target",r.target,r,null)));if(n==null||typeof n=="symbol"||typeof n=="boolean"){e.removeAttribute(l);break}n=jn(""+n),e.setAttribute(l,n);break;case"onClick":n!=null&&(e.onclick=J);break;case"onScroll":n!=null&&Ne("scroll",e);break;case"onScrollEnd":n!=null&&Ne("scrollend",e);break;case"dangerouslySetInnerHTML":if(n!=null){if(typeof n!="object"||!("__html"in n))throw Error(s(61));if(l=n.__html,l!=null){if(r.children!=null)throw Error(s(60));e.innerHTML=l}}break;case"multiple":e.multiple=n&&typeof n!="function"&&typeof n!="symbol";break;case"muted":e.muted=n&&typeof n!="function"&&typeof n!="symbol";break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":break;case"autoFocus":break;case"xlinkHref":if(n==null||typeof n=="function"||typeof n=="boolean"||typeof n=="symbol"){e.removeAttribute("xlink:href");break}l=jn(""+n),e.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",l);break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":n!=null&&typeof n!="function"&&typeof n!="symbol"?e.setAttribute(l,""+n):e.removeAttribute(l);break;case"inert":case"allowFullScreen":case"async":case"autoPlay":case"controls":case"default":case"defer":case"disabled":case"disablePictureInPicture":case"disableRemotePlayback":case"formNoValidate":case"hidden":case"loop":case"noModule":case"noValidate":case"open":case"playsInline":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"itemScope":n&&typeof n!="function"&&typeof n!="symbol"?e.setAttribute(l,""):e.removeAttribute(l);break;case"capture":case"download":n===!0?e.setAttribute(l,""):n!==!1&&n!=null&&typeof n!="function"&&typeof n!="symbol"?e.setAttribute(l,n):e.removeAttribute(l);break;case"cols":case"rows":case"size":case"span":n!=null&&typeof n!="function"&&typeof n!="symbol"&&!isNaN(n)&&1<=n?e.setAttribute(l,n):e.removeAttribute(l);break;case"rowSpan":case"start":n==null||typeof n=="function"||typeof n=="symbol"||isNaN(n)?e.removeAttribute(l):e.setAttribute(l,n);break;case"popover":Ne("beforetoggle",e),Ne("toggle",e),qt(e,"popover",n);break;case"xlinkActuate":Zt(e,"http://www.w3.org/1999/xlink","xlink:actuate",n);break;case"xlinkArcrole":Zt(e,"http://www.w3.org/1999/xlink","xlink:arcrole",n);break;case"xlinkRole":Zt(e,"http://www.w3.org/1999/xlink","xlink:role",n);break;case"xlinkShow":Zt(e,"http://www.w3.org/1999/xlink","xlink:show",n);break;case"xlinkTitle":Zt(e,"http://www.w3.org/1999/xlink","xlink:title",n);break;case"xlinkType":Zt(e,"http://www.w3.org/1999/xlink","xlink:type",n);break;case"xmlBase":Zt(e,"http://www.w3.org/XML/1998/namespace","xml:base",n);break;case"xmlLang":Zt(e,"http://www.w3.org/XML/1998/namespace","xml:lang",n);break;case"xmlSpace":Zt(e,"http://www.w3.org/XML/1998/namespace","xml:space",n);break;case"is":qt(e,"is",n);break;case"innerText":case"textContent":break;default:(!(2<l.length)||l[0]!=="o"&&l[0]!=="O"||l[1]!=="n"&&l[1]!=="N")&&(l=Fl.get(l)||l,qt(e,l,n))}}function Mc(e,t,l,n,r,o){switch(l){case"style":Ye(e,n,o);break;case"dangerouslySetInnerHTML":if(n!=null){if(typeof n!="object"||!("__html"in n))throw Error(s(61));if(l=n.__html,l!=null){if(r.children!=null)throw Error(s(60));e.innerHTML=l}}break;case"children":typeof n=="string"?de(e,n):(typeof n=="number"||typeof n=="bigint")&&de(e,""+n);break;case"onScroll":n!=null&&Ne("scroll",e);break;case"onScrollEnd":n!=null&&Ne("scrollend",e);break;case"onClick":n!=null&&(e.onclick=J);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"innerHTML":case"ref":break;case"innerText":case"textContent":break;default:if(!na.hasOwnProperty(l))e:{if(l[0]==="o"&&l[1]==="n"&&(r=l.endsWith("Capture"),t=l.slice(2,r?l.length-7:void 0),o=e[Ut]||null,o=o!=null?o[l]:null,typeof o=="function"&&e.removeEventListener(t,o,r),typeof n=="function")){typeof o!="function"&&o!==null&&(l in e?e[l]=null:e.hasAttribute(l)&&e.removeAttribute(l)),e.addEventListener(t,n,r);break e}l in e?e[l]=n:n===!0?e.setAttribute(l,""):qt(e,l,n)}}}function Dt(e,t,l){switch(t){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"img":Ne("error",e),Ne("load",e);var n=!1,r=!1,o;for(o in l)if(l.hasOwnProperty(o)){var h=l[o];if(h!=null)switch(o){case"src":n=!0;break;case"srcSet":r=!0;break;case"children":case"dangerouslySetInnerHTML":throw Error(s(137,t));default:$e(e,t,o,h,l,null)}}r&&$e(e,t,"srcSet",l.srcSet,l,null),n&&$e(e,t,"src",l.src,l,null);return;case"input":Ne("invalid",e);var m=o=h=r=null,S=null,O=null;for(n in l)if(l.hasOwnProperty(n)){var B=l[n];if(B!=null)switch(n){case"name":r=B;break;case"type":h=B;break;case"checked":S=B;break;case"defaultChecked":O=B;break;case"value":o=B;break;case"defaultValue":m=B;break;case"children":case"dangerouslySetInnerHTML":if(B!=null)throw Error(s(137,t));break;default:$e(e,t,n,B,l,null)}}aa(e,o,m,S,O,h,r,!1);return;case"select":Ne("invalid",e),n=h=o=null;for(r in l)if(l.hasOwnProperty(r)&&(m=l[r],m!=null))switch(r){case"value":o=m;break;case"defaultValue":h=m;break;case"multiple":n=m;default:$e(e,t,r,m,l,null)}t=o,l=h,e.multiple=!!n,t!=null?zt(e,!!n,t,!1):l!=null&&zt(e,!!n,l,!0);return;case"textarea":Ne("invalid",e),o=r=n=null;for(h in l)if(l.hasOwnProperty(h)&&(m=l[h],m!=null))switch(h){case"value":n=m;break;case"defaultValue":r=m;break;case"children":o=m;break;case"dangerouslySetInnerHTML":if(m!=null)throw Error(s(91));break;default:$e(e,t,h,m,l,null)}Ca(e,n,r,o);return;case"option":for(S in l)l.hasOwnProperty(S)&&(n=l[S],n!=null)&&(S==="selected"?e.selected=n&&typeof n!="function"&&typeof n!="symbol":$e(e,t,S,n,l,null));return;case"dialog":Ne("beforetoggle",e),Ne("toggle",e),Ne("cancel",e),Ne("close",e);break;case"iframe":case"object":Ne("load",e);break;case"video":case"audio":for(n=0;n<Ii.length;n++)Ne(Ii[n],e);break;case"image":Ne("error",e),Ne("load",e);break;case"details":Ne("toggle",e);break;case"embed":case"source":case"link":Ne("error",e),Ne("load",e);case"area":case"base":case"br":case"col":case"hr":case"keygen":case"meta":case"param":case"track":case"wbr":case"menuitem":for(O in l)if(l.hasOwnProperty(O)&&(n=l[O],n!=null))switch(O){case"children":case"dangerouslySetInnerHTML":throw Error(s(137,t));default:$e(e,t,O,n,l,null)}return;default:if(Tn(t)){for(B in l)l.hasOwnProperty(B)&&(n=l[B],n!==void 0&&Mc(e,t,B,n,l,void 0));return}}for(m in l)l.hasOwnProperty(m)&&(n=l[m],n!=null&&$e(e,t,m,n,l,null))}function $m(e,t,l,n){switch(t){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"input":var r=null,o=null,h=null,m=null,S=null,O=null,B=null;for(C in l){var G=l[C];if(l.hasOwnProperty(C)&&G!=null)switch(C){case"checked":break;case"value":break;case"defaultValue":S=G;default:n.hasOwnProperty(C)||$e(e,t,C,null,n,G)}}for(var N in n){var C=n[N];if(G=l[N],n.hasOwnProperty(N)&&(C!=null||G!=null))switch(N){case"type":o=C;break;case"name":r=C;break;case"checked":O=C;break;case"defaultChecked":B=C;break;case"value":h=C;break;case"defaultValue":m=C;break;case"children":case"dangerouslySetInnerHTML":if(C!=null)throw Error(s(137,t));break;default:C!==G&&$e(e,t,N,C,n,G)}}yi(e,h,m,S,O,B,o,r);return;case"select":C=h=m=N=null;for(o in l)if(S=l[o],l.hasOwnProperty(o)&&S!=null)switch(o){case"value":break;case"multiple":C=S;default:n.hasOwnProperty(o)||$e(e,t,o,null,n,S)}for(r in n)if(o=n[r],S=l[r],n.hasOwnProperty(r)&&(o!=null||S!=null))switch(r){case"value":N=o;break;case"defaultValue":m=o;break;case"multiple":h=o;default:o!==S&&$e(e,t,r,o,n,S)}t=m,l=h,n=C,N!=null?zt(e,!!l,N,!1):!!n!=!!l&&(t!=null?zt(e,!!l,t,!0):zt(e,!!l,l?[]:"",!1));return;case"textarea":C=N=null;for(m in l)if(r=l[m],l.hasOwnProperty(m)&&r!=null&&!n.hasOwnProperty(m))switch(m){case"value":break;case"children":break;default:$e(e,t,m,null,n,r)}for(h in n)if(r=n[h],o=l[h],n.hasOwnProperty(h)&&(r!=null||o!=null))switch(h){case"value":N=r;break;case"defaultValue":C=r;break;case"children":break;case"dangerouslySetInnerHTML":if(r!=null)throw Error(s(91));break;default:r!==o&&$e(e,t,h,r,n,o)}Su(e,N,C);return;case"option":for(var le in l)N=l[le],l.hasOwnProperty(le)&&N!=null&&!n.hasOwnProperty(le)&&(le==="selected"?e.selected=!1:$e(e,t,le,null,n,N));for(S in n)N=n[S],C=l[S],n.hasOwnProperty(S)&&N!==C&&(N!=null||C!=null)&&(S==="selected"?e.selected=N&&typeof N!="function"&&typeof N!="symbol":$e(e,t,S,N,n,C));return;case"img":case"link":case"area":case"base":case"br":case"col":case"embed":case"hr":case"keygen":case"meta":case"param":case"source":case"track":case"wbr":case"menuitem":for(var fe in l)N=l[fe],l.hasOwnProperty(fe)&&N!=null&&!n.hasOwnProperty(fe)&&$e(e,t,fe,null,n,N);for(O in n)if(N=n[O],C=l[O],n.hasOwnProperty(O)&&N!==C&&(N!=null||C!=null))switch(O){case"children":case"dangerouslySetInnerHTML":if(N!=null)throw Error(s(137,t));break;default:$e(e,t,O,N,n,C)}return;default:if(Tn(t)){for(var Fe in l)N=l[Fe],l.hasOwnProperty(Fe)&&N!==void 0&&!n.hasOwnProperty(Fe)&&Mc(e,t,Fe,void 0,n,N);for(B in n)N=n[B],C=l[B],!n.hasOwnProperty(B)||N===C||N===void 0&&C===void 0||Mc(e,t,B,N,n,C);return}}for(var T in l)N=l[T],l.hasOwnProperty(T)&&N!=null&&!n.hasOwnProperty(T)&&$e(e,t,T,null,n,N);for(G in n)N=n[G],C=l[G],!n.hasOwnProperty(G)||N===C||N==null&&C==null||$e(e,t,G,N,n,C)}function Cd(e){switch(e){case"css":case"script":case"font":case"img":case"image":case"input":case"link":return!0;default:return!1}}function Fm(){if(typeof performance.getEntriesByType=="function"){for(var e=0,t=0,l=performance.getEntriesByType("resource"),n=0;n<l.length;n++){var r=l[n],o=r.transferSize,h=r.initiatorType,m=r.duration;if(o&&m&&Cd(h)){for(h=0,m=r.responseEnd,n+=1;n<l.length;n++){var S=l[n],O=S.startTime;if(O>m)break;var B=S.transferSize,G=S.initiatorType;B&&Cd(G)&&(S=S.responseEnd,h+=B*(S<m?1:(m-O)/(S-O)))}if(--n,t+=8*(o+h)/(r.duration/1e3),e++,10<e)break}}if(0<e)return t/e/1e6}return navigator.connection&&(e=navigator.connection.downlink,typeof e=="number")?e:5}var zc=null,Rc=null;function bs(e){return e.nodeType===9?e:e.ownerDocument}function wd(e){switch(e){case"http://www.w3.org/2000/svg":return 1;case"http://www.w3.org/1998/Math/MathML":return 2;default:return 0}}function Dd(e,t){if(e===0)switch(t){case"svg":return 1;case"math":return 2;default:return 0}return e===1&&t==="foreignObject"?0:e}function Cc(e,t){return e==="textarea"||e==="noscript"||typeof t.children=="string"||typeof t.children=="number"||typeof t.children=="bigint"||typeof t.dangerouslySetInnerHTML=="object"&&t.dangerouslySetInnerHTML!==null&&t.dangerouslySetInnerHTML.__html!=null}var wc=null;function Wm(){var e=window.event;return e&&e.type==="popstate"?e===wc?!1:(wc=e,!0):(wc=null,!1)}var kd=typeof setTimeout=="function"?setTimeout:void 0,Im=typeof clearTimeout=="function"?clearTimeout:void 0,Bd=typeof Promise=="function"?Promise:void 0,Pm=typeof queueMicrotask=="function"?queueMicrotask:typeof Bd<"u"?function(e){return Bd.resolve(null).then(e).catch(ey)}:kd;function ey(e){setTimeout(function(){throw e})}function Qn(e){return e==="head"}function Ud(e,t){var l=t,n=0;do{var r=l.nextSibling;if(e.removeChild(l),r&&r.nodeType===8)if(l=r.data,l==="/$"||l==="/&"){if(n===0){e.removeChild(r),si(t);return}n--}else if(l==="$"||l==="$?"||l==="$~"||l==="$!"||l==="&")n++;else if(l==="html")eu(e.ownerDocument.documentElement);else if(l==="head"){l=e.ownerDocument.head,eu(l);for(var o=l.firstChild;o;){var h=o.nextSibling,m=o.nodeName;o[la]||m==="SCRIPT"||m==="STYLE"||m==="LINK"&&o.rel.toLowerCase()==="stylesheet"||l.removeChild(o),o=h}}else l==="body"&&eu(e.ownerDocument.body);l=r}while(l);si(t)}function qd(e,t){var l=e;e=0;do{var n=l.nextSibling;if(l.nodeType===1?t?(l._stashedDisplay=l.style.display,l.style.display="none"):(l.style.display=l._stashedDisplay||"",l.getAttribute("style")===""&&l.removeAttribute("style")):l.nodeType===3&&(t?(l._stashedText=l.nodeValue,l.nodeValue=""):l.nodeValue=l._stashedText||""),n&&n.nodeType===8)if(l=n.data,l==="/$"){if(e===0)break;e--}else l!=="$"&&l!=="$?"&&l!=="$~"&&l!=="$!"||e++;l=n}while(l)}function Dc(e){var t=e.firstChild;for(t&&t.nodeType===10&&(t=t.nextSibling);t;){var l=t;switch(t=t.nextSibling,l.nodeName){case"HTML":case"HEAD":case"BODY":Dc(l),gi(l);continue;case"SCRIPT":case"STYLE":continue;case"LINK":if(l.rel.toLowerCase()==="stylesheet")continue}e.removeChild(l)}}function ty(e,t,l,n){for(;e.nodeType===1;){var r=l;if(e.nodeName.toLowerCase()!==t.toLowerCase()){if(!n&&(e.nodeName!=="INPUT"||e.type!=="hidden"))break}else if(n){if(!e[la])switch(t){case"meta":if(!e.hasAttribute("itemprop"))break;return e;case"link":if(o=e.getAttribute("rel"),o==="stylesheet"&&e.hasAttribute("data-precedence"))break;if(o!==r.rel||e.getAttribute("href")!==(r.href==null||r.href===""?null:r.href)||e.getAttribute("crossorigin")!==(r.crossOrigin==null?null:r.crossOrigin)||e.getAttribute("title")!==(r.title==null?null:r.title))break;return e;case"style":if(e.hasAttribute("data-precedence"))break;return e;case"script":if(o=e.getAttribute("src"),(o!==(r.src==null?null:r.src)||e.getAttribute("type")!==(r.type==null?null:r.type)||e.getAttribute("crossorigin")!==(r.crossOrigin==null?null:r.crossOrigin))&&o&&e.hasAttribute("async")&&!e.hasAttribute("itemprop"))break;return e;default:return e}}else if(t==="input"&&e.type==="hidden"){var o=r.name==null?null:""+r.name;if(r.type==="hidden"&&e.getAttribute("name")===o)return e}else return e;if(e=xl(e.nextSibling),e===null)break}return null}function ly(e,t,l){if(t==="")return null;for(;e.nodeType!==3;)if((e.nodeType!==1||e.nodeName!=="INPUT"||e.type!=="hidden")&&!l||(e=xl(e.nextSibling),e===null))return null;return e}function Hd(e,t){for(;e.nodeType!==8;)if((e.nodeType!==1||e.nodeName!=="INPUT"||e.type!=="hidden")&&!t||(e=xl(e.nextSibling),e===null))return null;return e}function kc(e){return e.data==="$?"||e.data==="$~"}function Bc(e){return e.data==="$!"||e.data==="$?"&&e.ownerDocument.readyState!=="loading"}function ny(e,t){var l=e.ownerDocument;if(e.data==="$~")e._reactRetry=t;else if(e.data!=="$?"||l.readyState!=="loading")t();else{var n=function(){t(),l.removeEventListener("DOMContentLoaded",n)};l.addEventListener("DOMContentLoaded",n),e._reactRetry=n}}function xl(e){for(;e!=null;e=e.nextSibling){var t=e.nodeType;if(t===1||t===3)break;if(t===8){if(t=e.data,t==="$"||t==="$!"||t==="$?"||t==="$~"||t==="&"||t==="F!"||t==="F")break;if(t==="/$"||t==="/&")return null}}return e}var Uc=null;function Ld(e){e=e.nextSibling;for(var t=0;e;){if(e.nodeType===8){var l=e.data;if(l==="/$"||l==="/&"){if(t===0)return xl(e.nextSibling);t--}else l!=="$"&&l!=="$!"&&l!=="$?"&&l!=="$~"&&l!=="&"||t++}e=e.nextSibling}return null}function Gd(e){e=e.previousSibling;for(var t=0;e;){if(e.nodeType===8){var l=e.data;if(l==="$"||l==="$!"||l==="$?"||l==="$~"||l==="&"){if(t===0)return e;t--}else l!=="/$"&&l!=="/&"||t++}e=e.previousSibling}return null}function Yd(e,t,l){switch(t=bs(l),e){case"html":if(e=t.documentElement,!e)throw Error(s(452));return e;case"head":if(e=t.head,!e)throw Error(s(453));return e;case"body":if(e=t.body,!e)throw Error(s(454));return e;default:throw Error(s(451))}}function eu(e){for(var t=e.attributes;t.length;)e.removeAttributeNode(t[0]);gi(e)}var Sl=new Map,Xd=new Set;function vs(e){return typeof e.getRootNode=="function"?e.getRootNode():e.nodeType===9?e:e.ownerDocument}var dn=F.d;F.d={f:ay,r:iy,D:uy,C:sy,L:ry,m:cy,X:fy,S:oy,M:hy};function ay(){var e=dn.f(),t=os();return e||t}function iy(e){var t=Jl(e);t!==null&&t.tag===5&&t.type==="form"?uh(t):dn.r(e)}var ai=typeof document>"u"?null:document;function Qd(e,t,l){var n=ai;if(n&&typeof t=="string"&&t){var r=Vt(t);r='link[rel="'+e+'"][href="'+r+'"]',typeof l=="string"&&(r+='[crossorigin="'+l+'"]'),Xd.has(r)||(Xd.add(r),e={rel:e,crossOrigin:l,href:t},n.querySelector(r)===null&&(t=n.createElement("link"),Dt(t,"link",e),xt(t),n.head.appendChild(t)))}}function uy(e){dn.D(e),Qd("dns-prefetch",e,null)}function sy(e,t){dn.C(e,t),Qd("preconnect",e,t)}function ry(e,t,l){dn.L(e,t,l);var n=ai;if(n&&e&&t){var r='link[rel="preload"][as="'+Vt(t)+'"]';t==="image"&&l&&l.imageSrcSet?(r+='[imagesrcset="'+Vt(l.imageSrcSet)+'"]',typeof l.imageSizes=="string"&&(r+='[imagesizes="'+Vt(l.imageSizes)+'"]')):r+='[href="'+Vt(e)+'"]';var o=r;switch(t){case"style":o=ii(e);break;case"script":o=ui(e)}Sl.has(o)||(e=A({rel:"preload",href:t==="image"&&l&&l.imageSrcSet?void 0:e,as:t},l),Sl.set(o,e),n.querySelector(r)!==null||t==="style"&&n.querySelector(tu(o))||t==="script"&&n.querySelector(lu(o))||(t=n.createElement("link"),Dt(t,"link",e),xt(t),n.head.appendChild(t)))}}function cy(e,t){dn.m(e,t);var l=ai;if(l&&e){var n=t&&typeof t.as=="string"?t.as:"script",r='link[rel="modulepreload"][as="'+Vt(n)+'"][href="'+Vt(e)+'"]',o=r;switch(n){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":o=ui(e)}if(!Sl.has(o)&&(e=A({rel:"modulepreload",href:e},t),Sl.set(o,e),l.querySelector(r)===null)){switch(n){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(l.querySelector(lu(o)))return}n=l.createElement("link"),Dt(n,"link",e),xt(n),l.head.appendChild(n)}}}function oy(e,t,l){dn.S(e,t,l);var n=ai;if(n&&e){var r=An(n).hoistableStyles,o=ii(e);t=t||"default";var h=r.get(o);if(!h){var m={loading:0,preload:null};if(h=n.querySelector(tu(o)))m.loading=5;else{e=A({rel:"stylesheet",href:e,"data-precedence":t},l),(l=Sl.get(o))&&qc(e,l);var S=h=n.createElement("link");xt(S),Dt(S,"link",e),S._p=new Promise(function(O,B){S.onload=O,S.onerror=B}),S.addEventListener("load",function(){m.loading|=1}),S.addEventListener("error",function(){m.loading|=2}),m.loading|=4,xs(h,t,n)}h={type:"stylesheet",instance:h,count:1,state:m},r.set(o,h)}}}function fy(e,t){dn.X(e,t);var l=ai;if(l&&e){var n=An(l).hoistableScripts,r=ui(e),o=n.get(r);o||(o=l.querySelector(lu(r)),o||(e=A({src:e,async:!0},t),(t=Sl.get(r))&&Hc(e,t),o=l.createElement("script"),xt(o),Dt(o,"link",e),l.head.appendChild(o)),o={type:"script",instance:o,count:1,state:null},n.set(r,o))}}function hy(e,t){dn.M(e,t);var l=ai;if(l&&e){var n=An(l).hoistableScripts,r=ui(e),o=n.get(r);o||(o=l.querySelector(lu(r)),o||(e=A({src:e,async:!0,type:"module"},t),(t=Sl.get(r))&&Hc(e,t),o=l.createElement("script"),xt(o),Dt(o,"link",e),l.head.appendChild(o)),o={type:"script",instance:o,count:1,state:null},n.set(r,o))}}function Zd(e,t,l,n){var r=(r=_e.current)?vs(r):null;if(!r)throw Error(s(446));switch(e){case"meta":case"title":return null;case"style":return typeof l.precedence=="string"&&typeof l.href=="string"?(t=ii(l.href),l=An(r).hoistableStyles,n=l.get(t),n||(n={type:"style",instance:null,count:0,state:null},l.set(t,n)),n):{type:"void",instance:null,count:0,state:null};case"link":if(l.rel==="stylesheet"&&typeof l.href=="string"&&typeof l.precedence=="string"){e=ii(l.href);var o=An(r).hoistableStyles,h=o.get(e);if(h||(r=r.ownerDocument||r,h={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},o.set(e,h),(o=r.querySelector(tu(e)))&&!o._p&&(h.instance=o,h.state.loading=5),Sl.has(e)||(l={rel:"preload",as:"style",href:l.href,crossOrigin:l.crossOrigin,integrity:l.integrity,media:l.media,hrefLang:l.hrefLang,referrerPolicy:l.referrerPolicy},Sl.set(e,l),o||dy(r,e,l,h.state))),t&&n===null)throw Error(s(528,""));return h}if(t&&n!==null)throw Error(s(529,""));return null;case"script":return t=l.async,l=l.src,typeof l=="string"&&t&&typeof t!="function"&&typeof t!="symbol"?(t=ui(l),l=An(r).hoistableScripts,n=l.get(t),n||(n={type:"script",instance:null,count:0,state:null},l.set(t,n)),n):{type:"void",instance:null,count:0,state:null};default:throw Error(s(444,e))}}function ii(e){return'href="'+Vt(e)+'"'}function tu(e){return'link[rel="stylesheet"]['+e+"]"}function Vd(e){return A({},e,{"data-precedence":e.precedence,precedence:null})}function dy(e,t,l,n){e.querySelector('link[rel="preload"][as="style"]['+t+"]")?n.loading=1:(t=e.createElement("link"),n.preload=t,t.addEventListener("load",function(){return n.loading|=1}),t.addEventListener("error",function(){return n.loading|=2}),Dt(t,"link",l),xt(t),e.head.appendChild(t))}function ui(e){return'[src="'+Vt(e)+'"]'}function lu(e){return"script[async]"+e}function Kd(e,t,l){if(t.count++,t.instance===null)switch(t.type){case"style":var n=e.querySelector('style[data-href~="'+Vt(l.href)+'"]');if(n)return t.instance=n,xt(n),n;var r=A({},l,{"data-href":l.href,"data-precedence":l.precedence,href:null,precedence:null});return n=(e.ownerDocument||e).createElement("style"),xt(n),Dt(n,"style",r),xs(n,l.precedence,e),t.instance=n;case"stylesheet":r=ii(l.href);var o=e.querySelector(tu(r));if(o)return t.state.loading|=4,t.instance=o,xt(o),o;n=Vd(l),(r=Sl.get(r))&&qc(n,r),o=(e.ownerDocument||e).createElement("link"),xt(o);var h=o;return h._p=new Promise(function(m,S){h.onload=m,h.onerror=S}),Dt(o,"link",n),t.state.loading|=4,xs(o,l.precedence,e),t.instance=o;case"script":return o=ui(l.src),(r=e.querySelector(lu(o)))?(t.instance=r,xt(r),r):(n=l,(r=Sl.get(o))&&(n=A({},l),Hc(n,r)),e=e.ownerDocument||e,r=e.createElement("script"),xt(r),Dt(r,"link",n),e.head.appendChild(r),t.instance=r);case"void":return null;default:throw Error(s(443,t.type))}else t.type==="stylesheet"&&(t.state.loading&4)===0&&(n=t.instance,t.state.loading|=4,xs(n,l.precedence,e));return t.instance}function xs(e,t,l){for(var n=l.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),r=n.length?n[n.length-1]:null,o=r,h=0;h<n.length;h++){var m=n[h];if(m.dataset.precedence===t)o=m;else if(o!==r)break}o?o.parentNode.insertBefore(e,o.nextSibling):(t=l.nodeType===9?l.head:l,t.insertBefore(e,t.firstChild))}function qc(e,t){e.crossOrigin==null&&(e.crossOrigin=t.crossOrigin),e.referrerPolicy==null&&(e.referrerPolicy=t.referrerPolicy),e.title==null&&(e.title=t.title)}function Hc(e,t){e.crossOrigin==null&&(e.crossOrigin=t.crossOrigin),e.referrerPolicy==null&&(e.referrerPolicy=t.referrerPolicy),e.integrity==null&&(e.integrity=t.integrity)}var Ss=null;function Jd(e,t,l){if(Ss===null){var n=new Map,r=Ss=new Map;r.set(l,n)}else r=Ss,n=r.get(l),n||(n=new Map,r.set(l,n));if(n.has(e))return n;for(n.set(e,null),l=l.getElementsByTagName(e),r=0;r<l.length;r++){var o=l[r];if(!(o[la]||o[gt]||e==="link"&&o.getAttribute("rel")==="stylesheet")&&o.namespaceURI!=="http://www.w3.org/2000/svg"){var h=o.getAttribute(t)||"";h=e+h;var m=n.get(h);m?m.push(o):n.set(h,[o])}}return n}function $d(e,t,l){e=e.ownerDocument||e,e.head.insertBefore(l,t==="title"?e.querySelector("head > title"):null)}function py(e,t,l){if(l===1||t.itemProp!=null)return!1;switch(e){case"meta":case"title":return!0;case"style":if(typeof t.precedence!="string"||typeof t.href!="string"||t.href==="")break;return!0;case"link":if(typeof t.rel!="string"||typeof t.href!="string"||t.href===""||t.onLoad||t.onError)break;return t.rel==="stylesheet"?(e=t.disabled,typeof t.precedence=="string"&&e==null):!0;case"script":if(t.async&&typeof t.async!="function"&&typeof t.async!="symbol"&&!t.onLoad&&!t.onError&&t.src&&typeof t.src=="string")return!0}return!1}function Fd(e){return!(e.type==="stylesheet"&&(e.state.loading&3)===0)}function gy(e,t,l,n){if(l.type==="stylesheet"&&(typeof n.media!="string"||matchMedia(n.media).matches!==!1)&&(l.state.loading&4)===0){if(l.instance===null){var r=ii(n.href),o=t.querySelector(tu(r));if(o){t=o._p,t!==null&&typeof t=="object"&&typeof t.then=="function"&&(e.count++,e=_s.bind(e),t.then(e,e)),l.state.loading|=4,l.instance=o,xt(o);return}o=t.ownerDocument||t,n=Vd(n),(r=Sl.get(r))&&qc(n,r),o=o.createElement("link"),xt(o);var h=o;h._p=new Promise(function(m,S){h.onload=m,h.onerror=S}),Dt(o,"link",n),l.instance=o}e.stylesheets===null&&(e.stylesheets=new Map),e.stylesheets.set(l,t),(t=l.state.preload)&&(l.state.loading&3)===0&&(e.count++,l=_s.bind(e),t.addEventListener("load",l),t.addEventListener("error",l))}}var Lc=0;function my(e,t){return e.stylesheets&&e.count===0&&As(e,e.stylesheets),0<e.count||0<e.imgCount?function(l){var n=setTimeout(function(){if(e.stylesheets&&As(e,e.stylesheets),e.unsuspend){var o=e.unsuspend;e.unsuspend=null,o()}},6e4+t);0<e.imgBytes&&Lc===0&&(Lc=62500*Fm());var r=setTimeout(function(){if(e.waitingForImages=!1,e.count===0&&(e.stylesheets&&As(e,e.stylesheets),e.unsuspend)){var o=e.unsuspend;e.unsuspend=null,o()}},(e.imgBytes>Lc?50:800)+t);return e.unsuspend=l,function(){e.unsuspend=null,clearTimeout(n),clearTimeout(r)}}:null}function _s(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)As(this,this.stylesheets);else if(this.unsuspend){var e=this.unsuspend;this.unsuspend=null,e()}}}var Es=null;function As(e,t){e.stylesheets=null,e.unsuspend!==null&&(e.count++,Es=new Map,t.forEach(yy,e),Es=null,_s.call(e))}function yy(e,t){if(!(t.state.loading&4)){var l=Es.get(e);if(l)var n=l.get(null);else{l=new Map,Es.set(e,l);for(var r=e.querySelectorAll("link[data-precedence],style[data-precedence]"),o=0;o<r.length;o++){var h=r[o];(h.nodeName==="LINK"||h.getAttribute("media")!=="not all")&&(l.set(h.dataset.precedence,h),n=h)}n&&l.set(null,n)}r=t.instance,h=r.getAttribute("data-precedence"),o=l.get(h)||n,o===n&&l.set(null,r),l.set(h,r),this.count++,n=_s.bind(this),r.addEventListener("load",n),r.addEventListener("error",n),o?o.parentNode.insertBefore(r,o.nextSibling):(e=e.nodeType===9?e.head:e,e.insertBefore(r,e.firstChild)),t.state.loading|=4}}var nu={$$typeof:be,Provider:null,Consumer:null,_currentValue:re,_currentValue2:re,_threadCount:0};function by(e,t,l,n,r,o,h,m,S){this.tag=1,this.containerInfo=e,this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.next=this.pendingContext=this.context=this.cancelPendingCommit=null,this.callbackPriority=0,this.expirationTimes=Ke(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Ke(0),this.hiddenUpdates=Ke(null),this.identifierPrefix=n,this.onUncaughtError=r,this.onCaughtError=o,this.onRecoverableError=h,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=S,this.incompleteTransitions=new Map}function Wd(e,t,l,n,r,o,h,m,S,O,B,G){return e=new by(e,t,l,h,S,O,B,G,m),t=1,o===!0&&(t|=24),o=al(3,null,null,t),e.current=o,o.stateNode=e,t=vr(),t.refCount++,e.pooledCache=t,t.refCount++,o.memoizedState={element:n,isDehydrated:l,cache:t},Er(o),e}function Id(e){return e?(e=Ua,e):Ua}function Pd(e,t,l,n,r,o){r=Id(r),n.context===null?n.context=r:n.pendingContext=r,n=wn(t),n.payload={element:l},o=o===void 0?null:o,o!==null&&(n.callback=o),l=Dn(e,n,t),l!==null&&(It(l,e,t),ki(l,e,t))}function ep(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var l=e.retryLane;e.retryLane=l!==0&&l<t?l:t}}function Gc(e,t){ep(e,t),(e=e.alternate)&&ep(e,t)}function tp(e){if(e.tag===13||e.tag===31){var t=ra(e,67108864);t!==null&&It(t,e,67108864),Gc(e,67108864)}}function lp(e){if(e.tag===13||e.tag===31){var t=cl();t=rt(t);var l=ra(e,t);l!==null&&It(l,e,t),Gc(e,t)}}var Ts=!0;function vy(e,t,l,n){var r=D.T;D.T=null;var o=F.p;try{F.p=2,Yc(e,t,l,n)}finally{F.p=o,D.T=r}}function xy(e,t,l,n){var r=D.T;D.T=null;var o=F.p;try{F.p=8,Yc(e,t,l,n)}finally{F.p=o,D.T=r}}function Yc(e,t,l,n){if(Ts){var r=Xc(n);if(r===null)Nc(e,t,n,js,l),ap(e,n);else if(_y(r,e,t,l,n))n.stopPropagation();else if(ap(e,n),t&4&&-1<Sy.indexOf(e)){for(;r!==null;){var o=Jl(r);if(o!==null)switch(o.tag){case 3:if(o=o.stateNode,o.current.memoizedState.isDehydrated){var h=V(o.pendingLanes);if(h!==0){var m=o;for(m.pendingLanes|=2,m.entangledLanes|=2;h;){var S=1<<31-Mt(h);m.entanglements[1]|=S,h&=~S}Ul(o),(Le&6)===0&&(rs=st()+500,Wi(0))}}break;case 31:case 13:m=ra(o,2),m!==null&&It(m,o,2),os(),Gc(o,2)}if(o=Xc(n),o===null&&Nc(e,t,n,js,l),o===r)break;r=o}r!==null&&n.stopPropagation()}else Nc(e,t,n,null,l)}}function Xc(e){return e=Ee(e),Qc(e)}var js=null;function Qc(e){if(js=null,e=Gt(e),e!==null){var t=f(e);if(t===null)e=null;else{var l=t.tag;if(l===13){if(e=d(t),e!==null)return e;e=null}else if(l===31){if(e=p(t),e!==null)return e;e=null}else if(l===3){if(t.stateNode.current.memoizedState.isDehydrated)return t.tag===3?t.stateNode.containerInfo:null;e=null}else t!==e&&(e=null)}}return js=e,null}function np(e){switch(e){case"beforetoggle":case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"resize":case"seeked":case"submit":case"toggle":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 2;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 8;case"message":switch(kt()){case Bt:return 2;case Cl:return 8;case Xl:case Ql:return 32;case Sn:return 268435456;default:return 32}default:return 32}}var Zc=!1,Zn=null,Vn=null,Kn=null,au=new Map,iu=new Map,Jn=[],Sy="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset".split(" ");function ap(e,t){switch(e){case"focusin":case"focusout":Zn=null;break;case"dragenter":case"dragleave":Vn=null;break;case"mouseover":case"mouseout":Kn=null;break;case"pointerover":case"pointerout":au.delete(t.pointerId);break;case"gotpointercapture":case"lostpointercapture":iu.delete(t.pointerId)}}function uu(e,t,l,n,r,o){return e===null||e.nativeEvent!==o?(e={blockedOn:t,domEventName:l,eventSystemFlags:n,nativeEvent:o,targetContainers:[r]},t!==null&&(t=Jl(t),t!==null&&tp(t)),e):(e.eventSystemFlags|=n,t=e.targetContainers,r!==null&&t.indexOf(r)===-1&&t.push(r),e)}function _y(e,t,l,n,r){switch(t){case"focusin":return Zn=uu(Zn,e,t,l,n,r),!0;case"dragenter":return Vn=uu(Vn,e,t,l,n,r),!0;case"mouseover":return Kn=uu(Kn,e,t,l,n,r),!0;case"pointerover":var o=r.pointerId;return au.set(o,uu(au.get(o)||null,e,t,l,n,r)),!0;case"gotpointercapture":return o=r.pointerId,iu.set(o,uu(iu.get(o)||null,e,t,l,n,r)),!0}return!1}function ip(e){var t=Gt(e.target);if(t!==null){var l=f(t);if(l!==null){if(t=l.tag,t===13){if(t=d(l),t!==null){e.blockedOn=t,Oa(e.priority,function(){lp(l)});return}}else if(t===31){if(t=p(l),t!==null){e.blockedOn=t,Oa(e.priority,function(){lp(l)});return}}else if(t===3&&l.stateNode.current.memoizedState.isDehydrated){e.blockedOn=l.tag===3?l.stateNode.containerInfo:null;return}}}e.blockedOn=null}function Os(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var l=Xc(e.nativeEvent);if(l===null){l=e.nativeEvent;var n=new l.constructor(l.type,l);ae=n,l.target.dispatchEvent(n),ae=null}else return t=Jl(l),t!==null&&tp(t),e.blockedOn=l,!1;t.shift()}return!0}function up(e,t,l){Os(e)&&l.delete(t)}function Ey(){Zc=!1,Zn!==null&&Os(Zn)&&(Zn=null),Vn!==null&&Os(Vn)&&(Vn=null),Kn!==null&&Os(Kn)&&(Kn=null),au.forEach(up),iu.forEach(up)}function Ns(e,t){e.blockedOn===t&&(e.blockedOn=null,Zc||(Zc=!0,i.unstable_scheduleCallback(i.unstable_NormalPriority,Ey)))}var Ms=null;function sp(e){Ms!==e&&(Ms=e,i.unstable_scheduleCallback(i.unstable_NormalPriority,function(){Ms===e&&(Ms=null);for(var t=0;t<e.length;t+=3){var l=e[t],n=e[t+1],r=e[t+2];if(typeof n!="function"){if(Qc(n||l)===null)continue;break}var o=Jl(l);o!==null&&(e.splice(t,3),t-=3,Xr(o,{pending:!0,data:r,method:l.method,action:n},n,r))}}))}function si(e){function t(S){return Ns(S,e)}Zn!==null&&Ns(Zn,e),Vn!==null&&Ns(Vn,e),Kn!==null&&Ns(Kn,e),au.forEach(t),iu.forEach(t);for(var l=0;l<Jn.length;l++){var n=Jn[l];n.blockedOn===e&&(n.blockedOn=null)}for(;0<Jn.length&&(l=Jn[0],l.blockedOn===null);)ip(l),l.blockedOn===null&&Jn.shift();if(l=(e.ownerDocument||e).$$reactFormReplay,l!=null)for(n=0;n<l.length;n+=3){var r=l[n],o=l[n+1],h=r[Ut]||null;if(typeof o=="function")h||sp(l);else if(h){var m=null;if(o&&o.hasAttribute("formAction")){if(r=o,h=o[Ut]||null)m=h.formAction;else if(Qc(r)!==null)continue}else m=h.action;typeof m=="function"?l[n+1]=m:(l.splice(n,3),n-=3),sp(l)}}}function rp(){function e(o){o.canIntercept&&o.info==="react-transition"&&o.intercept({handler:function(){return new Promise(function(h){return r=h})},focusReset:"manual",scroll:"manual"})}function t(){r!==null&&(r(),r=null),n||setTimeout(l,20)}function l(){if(!n&&!navigation.transition){var o=navigation.currentEntry;o&&o.url!=null&&navigation.navigate(o.url,{state:o.getState(),info:"react-transition",history:"replace"})}}if(typeof navigation=="object"){var n=!1,r=null;return navigation.addEventListener("navigate",e),navigation.addEventListener("navigatesuccess",t),navigation.addEventListener("navigateerror",t),setTimeout(l,100),function(){n=!0,navigation.removeEventListener("navigate",e),navigation.removeEventListener("navigatesuccess",t),navigation.removeEventListener("navigateerror",t),r!==null&&(r(),r=null)}}}function Vc(e){this._internalRoot=e}zs.prototype.render=Vc.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(s(409));var l=t.current,n=cl();Pd(l,n,e,t,null,null)},zs.prototype.unmount=Vc.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;Pd(e.current,2,null,e,null,null),os(),t[_n]=null}};function zs(e){this._internalRoot=e}zs.prototype.unstable_scheduleHydration=function(e){if(e){var t=ja();e={blockedOn:null,target:e,priority:t};for(var l=0;l<Jn.length&&t!==0&&t<Jn[l].priority;l++);Jn.splice(l,0,e),l===0&&ip(e)}};var cp=a.version;if(cp!=="19.2.4")throw Error(s(527,cp,"19.2.4"));F.findDOMNode=function(e){var t=e._reactInternals;if(t===void 0)throw typeof e.render=="function"?Error(s(188)):(e=Object.keys(e).join(","),Error(s(268,e)));return e=y(t),e=e!==null?x(e):null,e=e===null?null:e.stateNode,e};var Ay={bundleType:0,version:"19.2.4",rendererPackageName:"react-dom",currentDispatcherRef:D,reconcilerVersion:"19.2.4"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var Rs=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Rs.isDisabled&&Rs.supportsFiber)try{Zl=Rs.inject(Ay),Ot=Rs}catch{}}return ru.createRoot=function(e,t){if(!c(e))throw Error(s(299));var l=!1,n="",r=mh,o=yh,h=bh;return t!=null&&(t.unstable_strictMode===!0&&(l=!0),t.identifierPrefix!==void 0&&(n=t.identifierPrefix),t.onUncaughtError!==void 0&&(r=t.onUncaughtError),t.onCaughtError!==void 0&&(o=t.onCaughtError),t.onRecoverableError!==void 0&&(h=t.onRecoverableError)),t=Wd(e,1,!1,null,null,l,n,null,r,o,h,rp),e[_n]=t.current,Oc(e),new Vc(t)},ru.hydrateRoot=function(e,t,l){if(!c(e))throw Error(s(299));var n=!1,r="",o=mh,h=yh,m=bh,S=null;return l!=null&&(l.unstable_strictMode===!0&&(n=!0),l.identifierPrefix!==void 0&&(r=l.identifierPrefix),l.onUncaughtError!==void 0&&(o=l.onUncaughtError),l.onCaughtError!==void 0&&(h=l.onCaughtError),l.onRecoverableError!==void 0&&(m=l.onRecoverableError),l.formState!==void 0&&(S=l.formState)),t=Wd(e,1,!0,t,l??null,n,r,S,o,h,m,rp),t.context=Id(null),l=t.current,n=cl(),n=rt(n),r=wn(n),r.callback=null,Dn(l,r,n),l=n,t.current.lanes=l,Ie(t,l),Ul(t),e[_n]=t.current,Oc(e),new zs(t)},ru.version="19.2.4",ru}var vp;function ky(){if(vp)return Jc.exports;vp=1;function i(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(i)}catch(a){console.error(a)}}return i(),Jc.exports=Dy(),Jc.exports}var By=ky(),k=bo();const Uy="/api";async function vt(i,a,u){const s={method:i,headers:{}};u!==void 0&&(s.headers["Content-Type"]="application/json",s.body=JSON.stringify(u));const c=await fetch(`${Uy}${a}`,s);if(!c.ok){const d=await c.text().catch(()=>"");throw new Error(`${c.status} ${c.statusText}: ${d}`)}return(c.headers.get("content-type")||"").includes("application/json")?c.json():c.text()}function qy(){return vt("GET","/project")}function Hy(i){return vt("PUT","/project/switch",{path:i})}function Cs(){return vt("GET","/projects")}function Ly(i,a){return vt("POST","/projects",{path:i,spec:a})}function Gy(i){return vt("DELETE","/projects",{path:i})}function xp(){return vt("GET","/project/spec/endpoints")}function Yy(i,a){return vt("GET",`/project/spec/endpoint?method=${encodeURIComponent(i)}&path=${encodeURIComponent(a)}`)}function Xy(i,a,u){let s=`?method=${encodeURIComponent(i)}&path=${encodeURIComponent(a)}`;return s+=`&contentType=${encodeURIComponent(u)}`,vt("GET",`/project/spec/endpoint/sample${s}`)}function Sp(){return vt("GET","/project/environments")}function Pc(){return vt("GET","/project/environments/resolved")}function Qy(i){return vt("PUT","/project/environments/base",i)}function Zy(i,a){return vt("PUT",`/project/environments/${encodeURIComponent(i)}`,a)}function Vy(i){return vt("PUT","/project/environments/active",{name:i})}function Ky(i){return vt("DELETE",`/project/environments/${encodeURIComponent(i)}`)}function Jy(i,a){return vt("GET",`/project/params?method=${encodeURIComponent(i)}&path=${encodeURIComponent(a)}`)}function _p(i,a,u){return vt("PUT",`/project/params?method=${encodeURIComponent(i)}&path=${encodeURIComponent(a)}`,u)}function $y(i){return vt("POST","/project/request/send",i)}function Fy(i,a,u,s){return vt("POST","/project/request/validate",{method:i,path:a,body:u,content_type:s})}function Wy(i){return vt("GET",`/browse?path=${encodeURIComponent(i||"~")}`)}function Iy(){return vt("GET","/preferences")}function Py(i){return vt("PATCH","/preferences",i)}function e0({onSpecReloaded:i,onSpecError:a,onGitChanged:u,onProjectSwitched:s}={}){const c=new EventSource("/api/events");return c.addEventListener("spec:reloaded",f=>{const d=f.data?JSON.parse(f.data):{};i&&i(d)}),c.addEventListener("spec:error",f=>{const d=f.data?JSON.parse(f.data):{};a&&a(d)}),c.addEventListener("git:changed",f=>{const d=f.data?JSON.parse(f.data):{};u&&u(d)}),c.addEventListener("project:switched",f=>{const d=f.data?JSON.parse(f.data):{};s&&s(d)}),c.onerror=()=>{},{disconnect(){c.close()}}}function t0({project:i,git:a,environments:u,activeEnv:s,onSwitchProject:c,onSetActiveEnv:f,onOpenEnvEditor:d,onOpenProjectDialog:p,toast:g,projects:y}){const x=[];u&&(x.push("Base"),u.environments&&Object.keys(u.environments).forEach(z=>x.push(z)));const A=i?.name||i?.path||"No project";return b.jsxs("div",{className:"topbar",children:[b.jsxs("div",{className:"topbar__section",children:[b.jsx("span",{className:"topbar__label",children:"Project"}),b.jsxs("select",{className:"topbar__select",value:i?.path||"",onChange:z=>{z.target.value&&c&&c(z.target.value)},children:[(!y||y.length===0)&&b.jsx("option",{value:"",children:A}),y&&y.map(z=>b.jsx("option",{value:z.path,children:z.name||z.path},z.path))]}),b.jsx("button",{className:"topbar__btn",onClick:p,title:"Open project",children:"Open"})]}),u&&b.jsxs("div",{className:"topbar__section",children:[b.jsx("span",{className:"topbar__label",children:"Env"}),b.jsx("select",{className:"topbar__select",value:s||"Base",onChange:z=>{f&&f(z.target.value==="Base"?null:z.target.value)},children:x.map(z=>b.jsx("option",{value:z,children:z},z))}),b.jsx("button",{className:"topbar__btn",onClick:d,title:"Edit environments (Ctrl+E)",children:"Edit"})]}),a&&b.jsxs("div",{className:"topbar__git",children:[b.jsx("span",{className:"topbar__git-branch",children:a.branch||"detached"}),a.commit&&b.jsx("span",{className:"topbar__git-commit",children:a.commit}),a.dirty&&b.jsx("span",{className:"topbar__git-dirty",children:"*"})]}),b.jsx("div",{className:"topbar__section--right",children:g&&b.jsx("span",{className:"topbar__toast",children:g},g)})]})}function vo({endpoint:i,selected:a,onSelect:u}){const s=`endpoint-item__method endpoint-item__method--${(i.method||"").toLowerCase()}`,c=`endpoint-item${a?" endpoint-item--selected":""}`;return b.jsxs("div",{className:c,onClick:()=>u(i),children:[b.jsx("span",{className:s,children:(i.method||"").toUpperCase()}),b.jsx("span",{className:"endpoint-item__path",children:i.path}),i.summary&&b.jsx("span",{className:"endpoint-item__summary",children:i.summary})]})}function l0({endpoints:i,selectedEndpoint:a,onSelect:u}){const s=k.useMemo(()=>{const f={};for(const d of i){const p=d.tags&&d.tags.length>0?d.tags:["default"];for(const g of p)f[g]||(f[g]=[]),f[g].push(d)}return f},[i]),c=Object.keys(s).sort();return b.jsx(b.Fragment,{children:c.map(f=>b.jsxs("div",{children:[b.jsx("div",{className:"endpoint-list__tag-header",children:f}),s[f].map(d=>b.jsx(vo,{endpoint:d,selected:a&&a.method===d.method&&a.path===d.path,onSelect:u},`${d.method}-${d.path}`))]},f))})}function n0(i){const a={__children:{},__endpoints:[]};for(const u of i){const s=u.path.replace(/^\//,"").split("/").filter(Boolean);let c=a;for(const f of s)c.__children[f]||(c.__children[f]={__children:{},__endpoints:[]}),c=c.__children[f];c.__endpoints.push(u)}return a}function Kp({name:i,node:a,depth:u,selectedEndpoint:s,onSelect:c,collapseState:f,onToggle:d}){const p=`${u}-${i}`,g=f[p]??!1,y=Object.keys(a.__children).sort();return!(y.length>0||a.__endpoints.length>0)&&!i?null:b.jsxs("div",{children:[i&&b.jsxs("div",{className:"endpoint-list__tree-folder",style:{paddingLeft:`${12+u*16}px`},onClick:()=>d(p),children:[b.jsx("span",{children:g?"▶":"▼"}),b.jsxs("span",{children:["/",i]})]}),!g&&b.jsxs("div",{children:[a.__endpoints.map(A=>b.jsx(vo,{endpoint:A,selected:s&&s.method===A.method&&s.path===A.path,onSelect:c},`${A.method}-${A.path}`)),y.map(A=>b.jsx(Kp,{name:A,node:a.__children[A],depth:u+1,selectedEndpoint:s,onSelect:c,collapseState:f,onToggle:d},A))]})]})}function a0({endpoints:i,selectedEndpoint:a,onSelect:u,collapseState:s,onToggle:c}){const f=k.useMemo(()=>n0(i),[i]),d=Object.keys(f.__children).sort();return b.jsxs(b.Fragment,{children:[f.__endpoints.map(p=>b.jsx(vo,{endpoint:p,selected:a&&a.method===p.method&&a.path===p.path,onSelect:u},`${p.method}-${p.path}`)),d.map(p=>b.jsx(Kp,{name:p,node:f.__children[p],depth:0,selectedEndpoint:a,onSelect:u,collapseState:s,onToggle:c},p))]})}function i0({endpoints:i,selectedEndpoint:a,onSelect:u,viewMode:s,onToggleViewMode:c,treeCollapseState:f,onToggleTreeNode:d,searchTerm:p,onSearchChange:g}){const y=k.useMemo(()=>{if(!p)return i||[];const x=p.toLowerCase();return(i||[]).filter(A=>A.path.toLowerCase().includes(x)||(A.method||"").toLowerCase().includes(x)||(A.summary||"").toLowerCase().includes(x))},[i,p]);return b.jsxs("div",{className:"endpoint-list",children:[b.jsx("div",{className:"endpoint-list__search",children:b.jsx("input",{className:"endpoint-list__search-input",type:"text",placeholder:"Search endpoints...",value:p,onChange:x=>g(x.target.value)})}),b.jsxs("div",{className:"endpoint-list__toolbar",children:[b.jsx("button",{className:`endpoint-list__view-btn${s==="tag"?" endpoint-list__view-btn--active":""}`,onClick:s!=="tag"?c:void 0,children:"Tags"}),b.jsx("button",{className:`endpoint-list__view-btn${s==="tree"?" endpoint-list__view-btn--active":""}`,onClick:s!=="tree"?c:void 0,children:"Tree"})]}),b.jsxs("div",{className:"endpoint-list__items",children:[s==="tag"?b.jsx(l0,{endpoints:y,selectedEndpoint:a,onSelect:u}):b.jsx(a0,{endpoints:y,selectedEndpoint:a,onSelect:u,collapseState:f||{},onToggle:d}),y.length===0&&b.jsx("div",{style:{padding:"16px",color:"var(--fg-muted)",textAlign:"center"},children:"No endpoints found"})]})]})}const no=/(\{\{\s*\w+\s*\}\})/g;function u0(i){if(!i)return" ";const a=i.split(no);return a.length===1?i||" ":a.map((u,s)=>no.test(u)?b.jsx("mark",{className:"hl-var",children:u},s):u)}function s0({className:i,value:a,...u}){const s=a&&no.test(a),c=k.useRef(null),f=k.useRef(null),[d,p]=k.useState(0);return k.useEffect(()=>{f.current&&(f.current.scrollLeft=d)},[d]),s?b.jsxs("div",{className:"hl-wrap",children:[b.jsx("div",{className:"hl-backdrop",ref:f,"aria-hidden":"true",children:u0(a)}),b.jsx("input",{ref:c,className:`${i} hl-input`,value:a,onScroll:g=>p(g.target.scrollLeft),...u})]}):b.jsx("input",{className:i,value:a,...u})}function r0(i,a){return!i||!a||typeof i!="string"||!/\{\{\s*(\w+)\s*\}\}/g.test(i)?null:i.replace(/\{\{\s*(\w+)\s*\}\}/g,(s,c)=>a[c]!==void 0?a[c]:s)}function eo({parameters:i,values:a,onChange:u,resolvedEnv:s}){return!i||i.length===0?null:b.jsx("div",{className:"param-form",children:i.map(c=>{const f=c.name,d=a[f]??"",p=r0(d,s);return b.jsxs("div",{className:"param-form__field",children:[b.jsxs("label",{className:"param-form__label",children:[f,c.required&&b.jsx("span",{className:"param-form__required",children:"*"})]}),c.description&&b.jsx("span",{className:"param-form__desc",children:c.description}),b.jsx(s0,{className:"param-form__input",type:"text",value:d,placeholder:c.schema?.default!=null?String(c.schema.default):"",onChange:g=>u(f,g.target.value),title:p||void 0}),p&&p!==d&&b.jsx("span",{className:"param-form__resolved",children:p})]},f)})})}function ao({schema:i,depth:a=0}){if(!i)return null;const u=a*16;if(i.type==="object"&&i.properties){const s=new Set(i.required||[]);return b.jsx("div",{style:{paddingLeft:u},children:Object.entries(i.properties).map(([c,f])=>b.jsxs("div",{className:"schema-view__prop",children:[b.jsx("span",{className:"schema-view__name",children:c}),b.jsx("span",{className:"schema-view__type",children:f.type||(f.items?"array":"object")}),s.has(c)&&b.jsx("span",{className:"schema-view__required",children:"required"}),f.description&&b.jsx("span",{className:"schema-view__desc",children:f.description}),f.enum&&b.jsxs("span",{className:"schema-view__enum",children:["enum: ",f.enum.join(", ")]}),f.type==="object"&&f.properties&&b.jsx(ao,{schema:f,depth:a+1}),f.type==="array"&&f.items?.type==="object"&&f.items.properties&&b.jsx(ao,{schema:f.items,depth:a+1})]},c))})}return null}function c0({endpoint:i,body:a,contentType:u,onBodyChange:s,onContentTypeChange:c,resolvedEnv:f}){const[d,p]=k.useState(null),[g,y]=k.useState(!1),[x,A]=k.useState(!1),z=k.useRef(null),Q=(i?.request_body||i?.requestBody)?.content||{},$=Object.keys(Q),X=u||$[0]||"application/json",K=X.includes("json"),se=X==="application/x-www-form-urlencoded",be=X.includes("multipart"),Se=se||be,oe=k.useMemo(()=>{if(!Se||!a)return[{key:"",value:"",type:"text"}];try{const W=JSON.parse(a);if(Array.isArray(W))return W.length>0?W:[{key:"",value:"",type:"text"}]}catch{}return[{key:"",value:"",type:"text"}]},[a,Se]);k.useEffect(()=>{if(!a||!i){p(null);return}return z.current&&clearTimeout(z.current),z.current=setTimeout(async()=>{try{const W=await Fy(i.method,i.path,a,X);p(W)}catch{p(null)}},600),()=>{z.current&&clearTimeout(z.current)}},[a,i,X]);const ve=k.useCallback(async()=>{if(i){y(!0);try{const W=await Xy(i.method,i.path,X),me=W?.sample??W;if(me==null)return;const et=typeof me=="string"?me:JSON.stringify(me,null,2);s(et)}catch{}finally{y(!1)}}},[i,X,s]),R=k.useCallback(W=>{s(JSON.stringify(W))},[s]),w=k.useCallback((W,me,et)=>{const Me=oe.map((We,D)=>D===W?{...We,[me]:et}:We);R(Me)},[oe,R]),P=k.useCallback(()=>{R([...oe,{key:"",value:"",type:"text"}])},[oe,R]),Ve=k.useCallback(W=>{const me=oe.filter((et,Me)=>Me!==W);R(me.length>0?me:[{key:"",value:"",type:"text"}])},[oe,R]);return b.jsxs("div",{children:[b.jsxs("div",{className:"body-editor__toolbar",children:[$.length>1&&b.jsx("select",{className:"body-editor__content-type",value:X,onChange:W=>c(W.target.value),children:$.map(W=>b.jsx("option",{value:W,children:W},W))}),$.length===1&&b.jsx("span",{style:{fontSize:"12px",color:"var(--fg-muted)",fontFamily:"var(--font-mono)"},children:X}),b.jsx("button",{className:"body-editor__sample-btn",onClick:ve,disabled:g,children:g?"Generating...":"Generate Sample"})]}),!Se&&b.jsx("textarea",{className:"body-editor__textarea",value:a||"",onChange:W=>s(W.target.value),placeholder:K?`{
10
-
11
- }`:"Request body...",spellCheck:!1}),Se&&b.jsxs("div",{children:[b.jsxs("table",{className:"body-editor__kv-table",children:[b.jsx("thead",{children:b.jsxs("tr",{children:[b.jsx("th",{children:"Key"}),b.jsx("th",{children:"Value"}),be&&b.jsx("th",{children:"Type"}),b.jsx("th",{})]})}),b.jsx("tbody",{children:oe.map((W,me)=>b.jsxs("tr",{children:[b.jsx("td",{children:b.jsx("input",{className:"body-editor__kv-input",type:"text",value:W.key||"",onChange:et=>w(me,"key",et.target.value),placeholder:"key"})}),b.jsx("td",{children:b.jsx("input",{className:"body-editor__kv-input",type:"text",value:W.value||"",onChange:et=>w(me,"value",et.target.value),placeholder:"value"})}),be&&b.jsx("td",{children:b.jsxs("select",{className:"body-editor__kv-input",value:W.type||"text",onChange:et=>w(me,"type",et.target.value),children:[b.jsx("option",{value:"text",children:"text"}),b.jsx("option",{value:"file",children:"file"})]})}),b.jsx("td",{children:b.jsx("button",{className:"body-editor__kv-remove",onClick:()=>Ve(me),title:"Remove row",children:"x"})})]},me))})]}),b.jsx("button",{className:"body-editor__kv-add",onClick:P,children:"+ Add Row"})]}),d&&b.jsxs("div",{className:`body-editor__validation body-editor__validation--${d.valid?"valid":"invalid"}`,children:[d.valid?"✓ Valid":`✗ ${(d.errors||[]).length} error(s)`,!d.valid&&d.errors&&d.errors.length>0&&b.jsx("div",{className:"validation-details__errors",children:d.errors.map((W,me)=>b.jsxs("div",{className:"validation-details__error",children:[W.path&&b.jsx("div",{className:"validation-details__error-path",children:W.path}),b.jsx("div",{className:"validation-details__error-msg",children:W.message||"Validation error"}),(W.expected||W.actual)&&b.jsxs("div",{className:"validation-details__error-detail",children:[W.expected&&b.jsxs(b.Fragment,{children:["Expected: ",String(W.expected)," "]}),W.actual&&b.jsxs(b.Fragment,{children:["Actual: ",String(W.actual)]})]})]},me))})]}),!d&&a&&b.jsx("div",{className:"body-editor__validation body-editor__validation--none",children:"— No schema validation"}),Q[X]?.schema&&b.jsxs("div",{className:"body-editor__schema",children:[b.jsxs("button",{className:"body-editor__schema-toggle",onClick:()=>A(W=>!W),children:[b.jsx("span",{children:"Schema"}),b.jsx("span",{className:`endpoint-doc__toggle-icon${x?" endpoint-doc__toggle-icon--expanded":""}`,children:"▶"})]}),x&&b.jsx("div",{className:"body-editor__schema-body",children:b.jsx(ao,{schema:Q[X].schema})})]})]})}function xo(){return{async:!1,breaks:!1,extensions:null,gfm:!0,hooks:null,pedantic:!1,renderer:null,silent:!1,tokenizer:null,walkTokens:null}}var Aa=xo();function Jp(i){Aa=i}var Sa={exec:()=>null};function ke(i,a=""){let u=typeof i=="string"?i:i.source,s={replace:(c,f)=>{let d=typeof f=="string"?f:f.source;return d=d.replace(Xt.caret,"$1"),u=u.replace(c,d),s},getRegex:()=>new RegExp(u,a)};return s}var o0=(()=>{try{return!!new RegExp("(?<=1)(?<!1)")}catch{return!1}})(),Xt={codeRemoveIndent:/^(?: {1,4}| {0,3}\t)/gm,outputLinkReplace:/\\([\[\]])/g,indentCodeCompensation:/^(\s+)(?:```)/,beginningSpace:/^\s+/,endingHash:/#$/,startingSpaceChar:/^ /,endingSpaceChar:/ $/,nonSpaceChar:/[^ ]/,newLineCharGlobal:/\n/g,tabCharGlobal:/\t/g,multipleSpaceGlobal:/\s+/g,blankLine:/^[ \t]*$/,doubleBlankLine:/\n[ \t]*\n[ \t]*$/,blockquoteStart:/^ {0,3}>/,blockquoteSetextReplace:/\n {0,3}((?:=+|-+) *)(?=\n|$)/g,blockquoteSetextReplace2:/^ {0,3}>[ \t]?/gm,listReplaceNesting:/^ {1,4}(?=( {4})*[^ ])/g,listIsTask:/^\[[ xX]\] +\S/,listReplaceTask:/^\[[ xX]\] +/,listTaskCheckbox:/\[[ xX]\]/,anyLine:/\n.*\n/,hrefBrackets:/^<(.*)>$/,tableDelimiter:/[:|]/,tableAlignChars:/^\||\| *$/g,tableRowBlankLine:/\n[ \t]*$/,tableAlignRight:/^ *-+: *$/,tableAlignCenter:/^ *:-+: *$/,tableAlignLeft:/^ *:-+ *$/,startATag:/^<a /i,endATag:/^<\/a>/i,startPreScriptTag:/^<(pre|code|kbd|script)(\s|>)/i,endPreScriptTag:/^<\/(pre|code|kbd|script)(\s|>)/i,startAngleBracket:/^</,endAngleBracket:/>$/,pedanticHrefTitle:/^([^'"]*[^\s])\s+(['"])(.*)\2/,unicodeAlphaNumeric:/[\p{L}\p{N}]/u,escapeTest:/[&<>"']/,escapeReplace:/[&<>"']/g,escapeTestNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,escapeReplaceNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/g,unescapeTest:/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/ig,caret:/(^|[^\[])\^/g,percentDecode:/%25/g,findPipe:/\|/g,splitPipe:/ \|/,slashPipe:/\\\|/g,carriageReturn:/\r\n|\r/g,spaceLine:/^ +$/gm,notSpaceStart:/^\S*/,endingNewline:/\n$/,listItemRegex:i=>new RegExp(`^( {0,3}${i})((?:[ ][^\\n]*)?(?:\\n|$))`),nextBulletRegex:i=>new RegExp(`^ {0,${Math.min(3,i-1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ ][^\\n]*)?(?:\\n|$))`),hrRegex:i=>new RegExp(`^ {0,${Math.min(3,i-1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`),fencesBeginRegex:i=>new RegExp(`^ {0,${Math.min(3,i-1)}}(?:\`\`\`|~~~)`),headingBeginRegex:i=>new RegExp(`^ {0,${Math.min(3,i-1)}}#`),htmlBeginRegex:i=>new RegExp(`^ {0,${Math.min(3,i-1)}}<(?:[a-z].*>|!--)`,"i"),blockquoteBeginRegex:i=>new RegExp(`^ {0,${Math.min(3,i-1)}}>`)},f0=/^(?:[ \t]*(?:\n|$))+/,h0=/^((?: {4}| {0,3}\t)[^\n]+(?:\n(?:[ \t]*(?:\n|$))*)?)+/,d0=/^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/,mu=/^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,p0=/^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,So=/ {0,3}(?:[*+-]|\d{1,9}[.)])/,$p=/^(?!bull |blockCode|fences|blockquote|heading|html|table)((?:.|\n(?!\s*?\n|bull |blockCode|fences|blockquote|heading|html|table))+?)\n {0,3}(=+|-+) *(?:\n+|$)/,Fp=ke($p).replace(/bull/g,So).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/\|table/g,"").getRegex(),g0=ke($p).replace(/bull/g,So).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/table/g,/ {0,3}\|?(?:[:\- ]*\|)+[\:\- ]*\n/).getRegex(),_o=/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/,m0=/^[^\n]+/,Eo=/(?!\s*\])(?:\\[\s\S]|[^\[\]\\])+/,y0=ke(/^ {0,3}\[(label)\]: *(?:\n[ \t]*)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n[ \t]*)?| *\n[ \t]*)(title))? *(?:\n+|$)/).replace("label",Eo).replace("title",/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(),b0=ke(/^(bull)([ \t][^\n]+?)?(?:\n|$)/).replace(/bull/g,So).getRegex(),Xs="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|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|search|section|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul",Ao=/<!--(?:-?>|[\s\S]*?(?:-->|$))/,v0=ke("^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:</\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|<![A-Z][\\s\\S]*?(?:>\\n*|$)|<!\\[CDATA\\[[\\s\\S]*?(?:\\]\\]>\\n*|$)|</?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|</(?!script|pre|style|textarea)[a-z][\\w-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$))","i").replace("comment",Ao).replace("tag",Xs).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),Wp=ke(_o).replace("hr",mu).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("|table","").replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)])[ \\t]").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",Xs).getRegex(),x0=ke(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace("paragraph",Wp).getRegex(),To={blockquote:x0,code:h0,def:y0,fences:d0,heading:p0,hr:mu,html:v0,lheading:Fp,list:b0,newline:f0,paragraph:Wp,table:Sa,text:m0},Ep=ke("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr",mu).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("blockquote"," {0,3}>").replace("code","(?: {4}| {0,3} )[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)])[ \\t]").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",Xs).getRegex(),S0={...To,lheading:g0,table:Ep,paragraph:ke(_o).replace("hr",mu).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("table",Ep).replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)])[ \\t]").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",Xs).getRegex()},_0={...To,html:ke(`^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:"[^"]*"|'[^']*'|\\s[^'"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`).replace("comment",Ao).replace(/tag/g,"(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),def:/^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^(#{1,6})(.*)(?:\n+|$)/,fences:Sa,lheading:/^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,paragraph:ke(_o).replace("hr",mu).replace("heading",` *#{1,6} *[^
12
- ]`).replace("lheading",Fp).replace("|table","").replace("blockquote"," {0,3}>").replace("|fences","").replace("|list","").replace("|html","").replace("|tag","").getRegex()},E0=/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,A0=/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,Ip=/^( {2,}|\\)\n(?!\s*$)/,T0=/^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\<!\[`*_]|\b_|$)|[^ ](?= {2,}\n)))/,Qs=/[\p{P}\p{S}]/u,jo=/[\s\p{P}\p{S}]/u,Pp=/[^\s\p{P}\p{S}]/u,j0=ke(/^((?![*_])punctSpace)/,"u").replace(/punctSpace/g,jo).getRegex(),eg=/(?!~)[\p{P}\p{S}]/u,O0=/(?!~)[\s\p{P}\p{S}]/u,N0=/(?:[^\s\p{P}\p{S}]|~)/u,tg=/(?![*_])[\p{P}\p{S}]/u,M0=/(?![*_])[\s\p{P}\p{S}]/u,z0=/(?:[^\s\p{P}\p{S}]|[*_])/u,R0=ke(/link|precode-code|html/,"g").replace("link",/\[(?:[^\[\]`]|(?<a>`+)[^`]+\k<a>(?!`))*?\]\((?:\\[\s\S]|[^\\\(\)]|\((?:\\[\s\S]|[^\\\(\)])*\))*\)/).replace("precode-",o0?"(?<!`)()":"(^^|[^`])").replace("code",/(?<b>`+)[^`]+\k<b>(?!`)/).replace("html",/<(?! )[^<>]*?>/).getRegex(),lg=/^(?:\*+(?:((?!\*)punct)|[^\s*]))|^_+(?:((?!_)punct)|([^\s_]))/,C0=ke(lg,"u").replace(/punct/g,Qs).getRegex(),w0=ke(lg,"u").replace(/punct/g,eg).getRegex(),ng="^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)punct(\\*+)(?=[\\s]|$)|notPunctSpace(\\*+)(?!\\*)(?=punctSpace|$)|(?!\\*)punctSpace(\\*+)(?=notPunctSpace)|[\\s](\\*+)(?!\\*)(?=punct)|(?!\\*)punct(\\*+)(?!\\*)(?=punct)|notPunctSpace(\\*+)(?=notPunctSpace)",D0=ke(ng,"gu").replace(/notPunctSpace/g,Pp).replace(/punctSpace/g,jo).replace(/punct/g,Qs).getRegex(),k0=ke(ng,"gu").replace(/notPunctSpace/g,N0).replace(/punctSpace/g,O0).replace(/punct/g,eg).getRegex(),B0=ke("^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)punct(_+)(?=[\\s]|$)|notPunctSpace(_+)(?!_)(?=punctSpace|$)|(?!_)punctSpace(_+)(?=notPunctSpace)|[\\s](_+)(?!_)(?=punct)|(?!_)punct(_+)(?!_)(?=punct)","gu").replace(/notPunctSpace/g,Pp).replace(/punctSpace/g,jo).replace(/punct/g,Qs).getRegex(),U0=ke(/^~~?(?:((?!~)punct)|[^\s~])/,"u").replace(/punct/g,tg).getRegex(),q0="^[^~]+(?=[^~])|(?!~)punct(~~?)(?=[\\s]|$)|notPunctSpace(~~?)(?!~)(?=punctSpace|$)|(?!~)punctSpace(~~?)(?=notPunctSpace)|[\\s](~~?)(?!~)(?=punct)|(?!~)punct(~~?)(?!~)(?=punct)|notPunctSpace(~~?)(?=notPunctSpace)",H0=ke(q0,"gu").replace(/notPunctSpace/g,z0).replace(/punctSpace/g,M0).replace(/punct/g,tg).getRegex(),L0=ke(/\\(punct)/,"gu").replace(/punct/g,Qs).getRegex(),G0=ke(/^<(scheme:[^\s\x00-\x1f<>]*|email)>/).replace("scheme",/[a-zA-Z][a-zA-Z0-9+.-]{1,31}/).replace("email",/[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/).getRegex(),Y0=ke(Ao).replace("(?:-->|$)","-->").getRegex(),X0=ke("^comment|^</[a-zA-Z][\\w:-]*\\s*>|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^<![a-zA-Z]+\\s[\\s\\S]*?>|^<!\\[CDATA\\[[\\s\\S]*?\\]\\]>").replace("comment",Y0).replace("attribute",/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/).getRegex(),Us=/(?:\[(?:\\[\s\S]|[^\[\]\\])*\]|\\[\s\S]|`+[^`]*?`+(?!`)|[^\[\]\\`])*?/,Q0=ke(/^!?\[(label)\]\(\s*(href)(?:(?:[ \t]*(?:\n[ \t]*)?)(title))?\s*\)/).replace("label",Us).replace("href",/<(?:\\.|[^\n<>\\])+>|[^ \t\n\x00-\x1f]*/).replace("title",/"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/).getRegex(),ag=ke(/^!?\[(label)\]\[(ref)\]/).replace("label",Us).replace("ref",Eo).getRegex(),ig=ke(/^!?\[(ref)\](?:\[\])?/).replace("ref",Eo).getRegex(),Z0=ke("reflink|nolink(?!\\()","g").replace("reflink",ag).replace("nolink",ig).getRegex(),Ap=/[hH][tT][tT][pP][sS]?|[fF][tT][pP]/,Oo={_backpedal:Sa,anyPunctuation:L0,autolink:G0,blockSkip:R0,br:Ip,code:A0,del:Sa,delLDelim:Sa,delRDelim:Sa,emStrongLDelim:C0,emStrongRDelimAst:D0,emStrongRDelimUnd:B0,escape:E0,link:Q0,nolink:ig,punctuation:j0,reflink:ag,reflinkSearch:Z0,tag:X0,text:T0,url:Sa},V0={...Oo,link:ke(/^!?\[(label)\]\((.*?)\)/).replace("label",Us).getRegex(),reflink:ke(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label",Us).getRegex()},io={...Oo,emStrongRDelimAst:k0,emStrongLDelim:w0,delLDelim:U0,delRDelim:H0,url:ke(/^((?:protocol):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/).replace("protocol",Ap).replace("email",/[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/).getRegex(),_backpedal:/(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,del:/^(~~?)(?=[^\s~])((?:\\[\s\S]|[^\\])*?(?:\\[\s\S]|[^\s~\\]))\1(?=[^~]|$)/,text:ke(/^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\<!\[`*~_]|\b_|protocol:\/\/|www\.|$)|[^ ](?= {2,}\n)|[^a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-](?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)))/).replace("protocol",Ap).getRegex()},K0={...io,br:ke(Ip).replace("{2,}","*").getRegex(),text:ke(io.text).replace("\\b_","\\b_| {2,}\\n").replace(/\{2,\}/g,"*").getRegex()},ws={normal:To,gfm:S0,pedantic:_0},cu={normal:Oo,gfm:io,breaks:K0,pedantic:V0},J0={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"},Tp=i=>J0[i];function ql(i,a){if(a){if(Xt.escapeTest.test(i))return i.replace(Xt.escapeReplace,Tp)}else if(Xt.escapeTestNoEncode.test(i))return i.replace(Xt.escapeReplaceNoEncode,Tp);return i}function jp(i){try{i=encodeURI(i).replace(Xt.percentDecode,"%")}catch{return null}return i}function Op(i,a){let u=i.replace(Xt.findPipe,(f,d,p)=>{let g=!1,y=d;for(;--y>=0&&p[y]==="\\";)g=!g;return g?"|":" |"}),s=u.split(Xt.splitPipe),c=0;if(s[0].trim()||s.shift(),s.length>0&&!s.at(-1)?.trim()&&s.pop(),a)if(s.length>a)s.splice(a);else for(;s.length<a;)s.push("");for(;c<s.length;c++)s[c]=s[c].trim().replace(Xt.slashPipe,"|");return s}function ou(i,a,u){let s=i.length;if(s===0)return"";let c=0;for(;c<s&&i.charAt(s-c-1)===a;)c++;return i.slice(0,s-c)}function $0(i,a){if(i.indexOf(a[1])===-1)return-1;let u=0;for(let s=0;s<i.length;s++)if(i[s]==="\\")s++;else if(i[s]===a[0])u++;else if(i[s]===a[1]&&(u--,u<0))return s;return u>0?-2:-1}function F0(i,a=0){let u=a,s="";for(let c of i)if(c===" "){let f=4-u%4;s+=" ".repeat(f),u+=f}else s+=c,u++;return s}function Np(i,a,u,s,c){let f=a.href,d=a.title||null,p=i[1].replace(c.other.outputLinkReplace,"$1");s.state.inLink=!0;let g={type:i[0].charAt(0)==="!"?"image":"link",raw:u,href:f,title:d,text:p,tokens:s.inlineTokens(p)};return s.state.inLink=!1,g}function W0(i,a,u){let s=i.match(u.other.indentCodeCompensation);if(s===null)return a;let c=s[1];return a.split(`
13
- `).map(f=>{let d=f.match(u.other.beginningSpace);if(d===null)return f;let[p]=d;return p.length>=c.length?f.slice(c.length):f}).join(`
14
- `)}var qs=class{options;rules;lexer;constructor(i){this.options=i||Aa}space(i){let a=this.rules.block.newline.exec(i);if(a&&a[0].length>0)return{type:"space",raw:a[0]}}code(i){let a=this.rules.block.code.exec(i);if(a){let u=a[0].replace(this.rules.other.codeRemoveIndent,"");return{type:"code",raw:a[0],codeBlockStyle:"indented",text:this.options.pedantic?u:ou(u,`
15
- `)}}}fences(i){let a=this.rules.block.fences.exec(i);if(a){let u=a[0],s=W0(u,a[3]||"",this.rules);return{type:"code",raw:u,lang:a[2]?a[2].trim().replace(this.rules.inline.anyPunctuation,"$1"):a[2],text:s}}}heading(i){let a=this.rules.block.heading.exec(i);if(a){let u=a[2].trim();if(this.rules.other.endingHash.test(u)){let s=ou(u,"#");(this.options.pedantic||!s||this.rules.other.endingSpaceChar.test(s))&&(u=s.trim())}return{type:"heading",raw:a[0],depth:a[1].length,text:u,tokens:this.lexer.inline(u)}}}hr(i){let a=this.rules.block.hr.exec(i);if(a)return{type:"hr",raw:ou(a[0],`
16
- `)}}blockquote(i){let a=this.rules.block.blockquote.exec(i);if(a){let u=ou(a[0],`
17
- `).split(`
18
- `),s="",c="",f=[];for(;u.length>0;){let d=!1,p=[],g;for(g=0;g<u.length;g++)if(this.rules.other.blockquoteStart.test(u[g]))p.push(u[g]),d=!0;else if(!d)p.push(u[g]);else break;u=u.slice(g);let y=p.join(`
19
- `),x=y.replace(this.rules.other.blockquoteSetextReplace,`
20
- $1`).replace(this.rules.other.blockquoteSetextReplace2,"");s=s?`${s}
21
- ${y}`:y,c=c?`${c}
22
- ${x}`:x;let A=this.lexer.state.top;if(this.lexer.state.top=!0,this.lexer.blockTokens(x,f,!0),this.lexer.state.top=A,u.length===0)break;let z=f.at(-1);if(z?.type==="code")break;if(z?.type==="blockquote"){let q=z,Q=q.raw+`
23
- `+u.join(`
24
- `),$=this.blockquote(Q);f[f.length-1]=$,s=s.substring(0,s.length-q.raw.length)+$.raw,c=c.substring(0,c.length-q.text.length)+$.text;break}else if(z?.type==="list"){let q=z,Q=q.raw+`
25
- `+u.join(`
26
- `),$=this.list(Q);f[f.length-1]=$,s=s.substring(0,s.length-z.raw.length)+$.raw,c=c.substring(0,c.length-q.raw.length)+$.raw,u=Q.substring(f.at(-1).raw.length).split(`
27
- `);continue}}return{type:"blockquote",raw:s,tokens:f,text:c}}}list(i){let a=this.rules.block.list.exec(i);if(a){let u=a[1].trim(),s=u.length>1,c={type:"list",raw:"",ordered:s,start:s?+u.slice(0,-1):"",loose:!1,items:[]};u=s?`\\d{1,9}\\${u.slice(-1)}`:`\\${u}`,this.options.pedantic&&(u=s?u:"[*+-]");let f=this.rules.other.listItemRegex(u),d=!1;for(;i;){let g=!1,y="",x="";if(!(a=f.exec(i))||this.rules.block.hr.test(i))break;y=a[0],i=i.substring(y.length);let A=F0(a[2].split(`
28
- `,1)[0],a[1].length),z=i.split(`
29
- `,1)[0],q=!A.trim(),Q=0;if(this.options.pedantic?(Q=2,x=A.trimStart()):q?Q=a[1].length+1:(Q=A.search(this.rules.other.nonSpaceChar),Q=Q>4?1:Q,x=A.slice(Q),Q+=a[1].length),q&&this.rules.other.blankLine.test(z)&&(y+=z+`
30
- `,i=i.substring(z.length+1),g=!0),!g){let $=this.rules.other.nextBulletRegex(Q),X=this.rules.other.hrRegex(Q),K=this.rules.other.fencesBeginRegex(Q),se=this.rules.other.headingBeginRegex(Q),be=this.rules.other.htmlBeginRegex(Q),Se=this.rules.other.blockquoteBeginRegex(Q);for(;i;){let oe=i.split(`
31
- `,1)[0],ve;if(z=oe,this.options.pedantic?(z=z.replace(this.rules.other.listReplaceNesting," "),ve=z):ve=z.replace(this.rules.other.tabCharGlobal," "),K.test(z)||se.test(z)||be.test(z)||Se.test(z)||$.test(z)||X.test(z))break;if(ve.search(this.rules.other.nonSpaceChar)>=Q||!z.trim())x+=`
32
- `+ve.slice(Q);else{if(q||A.replace(this.rules.other.tabCharGlobal," ").search(this.rules.other.nonSpaceChar)>=4||K.test(A)||se.test(A)||X.test(A))break;x+=`
33
- `+z}q=!z.trim(),y+=oe+`
34
- `,i=i.substring(oe.length+1),A=ve.slice(Q)}}c.loose||(d?c.loose=!0:this.rules.other.doubleBlankLine.test(y)&&(d=!0)),c.items.push({type:"list_item",raw:y,task:!!this.options.gfm&&this.rules.other.listIsTask.test(x),loose:!1,text:x,tokens:[]}),c.raw+=y}let p=c.items.at(-1);if(p)p.raw=p.raw.trimEnd(),p.text=p.text.trimEnd();else return;c.raw=c.raw.trimEnd();for(let g of c.items){if(this.lexer.state.top=!1,g.tokens=this.lexer.blockTokens(g.text,[]),g.task){if(g.text=g.text.replace(this.rules.other.listReplaceTask,""),g.tokens[0]?.type==="text"||g.tokens[0]?.type==="paragraph"){g.tokens[0].raw=g.tokens[0].raw.replace(this.rules.other.listReplaceTask,""),g.tokens[0].text=g.tokens[0].text.replace(this.rules.other.listReplaceTask,"");for(let x=this.lexer.inlineQueue.length-1;x>=0;x--)if(this.rules.other.listIsTask.test(this.lexer.inlineQueue[x].src)){this.lexer.inlineQueue[x].src=this.lexer.inlineQueue[x].src.replace(this.rules.other.listReplaceTask,"");break}}let y=this.rules.other.listTaskCheckbox.exec(g.raw);if(y){let x={type:"checkbox",raw:y[0]+" ",checked:y[0]!=="[ ]"};g.checked=x.checked,c.loose?g.tokens[0]&&["paragraph","text"].includes(g.tokens[0].type)&&"tokens"in g.tokens[0]&&g.tokens[0].tokens?(g.tokens[0].raw=x.raw+g.tokens[0].raw,g.tokens[0].text=x.raw+g.tokens[0].text,g.tokens[0].tokens.unshift(x)):g.tokens.unshift({type:"paragraph",raw:x.raw,text:x.raw,tokens:[x]}):g.tokens.unshift(x)}}if(!c.loose){let y=g.tokens.filter(A=>A.type==="space"),x=y.length>0&&y.some(A=>this.rules.other.anyLine.test(A.raw));c.loose=x}}if(c.loose)for(let g of c.items){g.loose=!0;for(let y of g.tokens)y.type==="text"&&(y.type="paragraph")}return c}}html(i){let a=this.rules.block.html.exec(i);if(a)return{type:"html",block:!0,raw:a[0],pre:a[1]==="pre"||a[1]==="script"||a[1]==="style",text:a[0]}}def(i){let a=this.rules.block.def.exec(i);if(a){let u=a[1].toLowerCase().replace(this.rules.other.multipleSpaceGlobal," "),s=a[2]?a[2].replace(this.rules.other.hrefBrackets,"$1").replace(this.rules.inline.anyPunctuation,"$1"):"",c=a[3]?a[3].substring(1,a[3].length-1).replace(this.rules.inline.anyPunctuation,"$1"):a[3];return{type:"def",tag:u,raw:a[0],href:s,title:c}}}table(i){let a=this.rules.block.table.exec(i);if(!a||!this.rules.other.tableDelimiter.test(a[2]))return;let u=Op(a[1]),s=a[2].replace(this.rules.other.tableAlignChars,"").split("|"),c=a[3]?.trim()?a[3].replace(this.rules.other.tableRowBlankLine,"").split(`
35
- `):[],f={type:"table",raw:a[0],header:[],align:[],rows:[]};if(u.length===s.length){for(let d of s)this.rules.other.tableAlignRight.test(d)?f.align.push("right"):this.rules.other.tableAlignCenter.test(d)?f.align.push("center"):this.rules.other.tableAlignLeft.test(d)?f.align.push("left"):f.align.push(null);for(let d=0;d<u.length;d++)f.header.push({text:u[d],tokens:this.lexer.inline(u[d]),header:!0,align:f.align[d]});for(let d of c)f.rows.push(Op(d,f.header.length).map((p,g)=>({text:p,tokens:this.lexer.inline(p),header:!1,align:f.align[g]})));return f}}lheading(i){let a=this.rules.block.lheading.exec(i);if(a)return{type:"heading",raw:a[0],depth:a[2].charAt(0)==="="?1:2,text:a[1],tokens:this.lexer.inline(a[1])}}paragraph(i){let a=this.rules.block.paragraph.exec(i);if(a){let u=a[1].charAt(a[1].length-1)===`
36
- `?a[1].slice(0,-1):a[1];return{type:"paragraph",raw:a[0],text:u,tokens:this.lexer.inline(u)}}}text(i){let a=this.rules.block.text.exec(i);if(a)return{type:"text",raw:a[0],text:a[0],tokens:this.lexer.inline(a[0])}}escape(i){let a=this.rules.inline.escape.exec(i);if(a)return{type:"escape",raw:a[0],text:a[1]}}tag(i){let a=this.rules.inline.tag.exec(i);if(a)return!this.lexer.state.inLink&&this.rules.other.startATag.test(a[0])?this.lexer.state.inLink=!0:this.lexer.state.inLink&&this.rules.other.endATag.test(a[0])&&(this.lexer.state.inLink=!1),!this.lexer.state.inRawBlock&&this.rules.other.startPreScriptTag.test(a[0])?this.lexer.state.inRawBlock=!0:this.lexer.state.inRawBlock&&this.rules.other.endPreScriptTag.test(a[0])&&(this.lexer.state.inRawBlock=!1),{type:"html",raw:a[0],inLink:this.lexer.state.inLink,inRawBlock:this.lexer.state.inRawBlock,block:!1,text:a[0]}}link(i){let a=this.rules.inline.link.exec(i);if(a){let u=a[2].trim();if(!this.options.pedantic&&this.rules.other.startAngleBracket.test(u)){if(!this.rules.other.endAngleBracket.test(u))return;let f=ou(u.slice(0,-1),"\\");if((u.length-f.length)%2===0)return}else{let f=$0(a[2],"()");if(f===-2)return;if(f>-1){let d=(a[0].indexOf("!")===0?5:4)+a[1].length+f;a[2]=a[2].substring(0,f),a[0]=a[0].substring(0,d).trim(),a[3]=""}}let s=a[2],c="";if(this.options.pedantic){let f=this.rules.other.pedanticHrefTitle.exec(s);f&&(s=f[1],c=f[3])}else c=a[3]?a[3].slice(1,-1):"";return s=s.trim(),this.rules.other.startAngleBracket.test(s)&&(this.options.pedantic&&!this.rules.other.endAngleBracket.test(u)?s=s.slice(1):s=s.slice(1,-1)),Np(a,{href:s&&s.replace(this.rules.inline.anyPunctuation,"$1"),title:c&&c.replace(this.rules.inline.anyPunctuation,"$1")},a[0],this.lexer,this.rules)}}reflink(i,a){let u;if((u=this.rules.inline.reflink.exec(i))||(u=this.rules.inline.nolink.exec(i))){let s=(u[2]||u[1]).replace(this.rules.other.multipleSpaceGlobal," "),c=a[s.toLowerCase()];if(!c){let f=u[0].charAt(0);return{type:"text",raw:f,text:f}}return Np(u,c,u[0],this.lexer,this.rules)}}emStrong(i,a,u=""){let s=this.rules.inline.emStrongLDelim.exec(i);if(!(!s||s[3]&&u.match(this.rules.other.unicodeAlphaNumeric))&&(!(s[1]||s[2])||!u||this.rules.inline.punctuation.exec(u))){let c=[...s[0]].length-1,f,d,p=c,g=0,y=s[0][0]==="*"?this.rules.inline.emStrongRDelimAst:this.rules.inline.emStrongRDelimUnd;for(y.lastIndex=0,a=a.slice(-1*i.length+c);(s=y.exec(a))!=null;){if(f=s[1]||s[2]||s[3]||s[4]||s[5]||s[6],!f)continue;if(d=[...f].length,s[3]||s[4]){p+=d;continue}else if((s[5]||s[6])&&c%3&&!((c+d)%3)){g+=d;continue}if(p-=d,p>0)continue;d=Math.min(d,d+p+g);let x=[...s[0]][0].length,A=i.slice(0,c+s.index+x+d);if(Math.min(c,d)%2){let q=A.slice(1,-1);return{type:"em",raw:A,text:q,tokens:this.lexer.inlineTokens(q)}}let z=A.slice(2,-2);return{type:"strong",raw:A,text:z,tokens:this.lexer.inlineTokens(z)}}}}codespan(i){let a=this.rules.inline.code.exec(i);if(a){let u=a[2].replace(this.rules.other.newLineCharGlobal," "),s=this.rules.other.nonSpaceChar.test(u),c=this.rules.other.startingSpaceChar.test(u)&&this.rules.other.endingSpaceChar.test(u);return s&&c&&(u=u.substring(1,u.length-1)),{type:"codespan",raw:a[0],text:u}}}br(i){let a=this.rules.inline.br.exec(i);if(a)return{type:"br",raw:a[0]}}del(i,a,u=""){let s=this.rules.inline.delLDelim.exec(i);if(s&&(!s[1]||!u||this.rules.inline.punctuation.exec(u))){let c=[...s[0]].length-1,f,d,p=c,g=this.rules.inline.delRDelim;for(g.lastIndex=0,a=a.slice(-1*i.length+c);(s=g.exec(a))!=null;){if(f=s[1]||s[2]||s[3]||s[4]||s[5]||s[6],!f||(d=[...f].length,d!==c))continue;if(s[3]||s[4]){p+=d;continue}if(p-=d,p>0)continue;d=Math.min(d,d+p);let y=[...s[0]][0].length,x=i.slice(0,c+s.index+y+d),A=x.slice(c,-c);return{type:"del",raw:x,text:A,tokens:this.lexer.inlineTokens(A)}}}}autolink(i){let a=this.rules.inline.autolink.exec(i);if(a){let u,s;return a[2]==="@"?(u=a[1],s="mailto:"+u):(u=a[1],s=u),{type:"link",raw:a[0],text:u,href:s,tokens:[{type:"text",raw:u,text:u}]}}}url(i){let a;if(a=this.rules.inline.url.exec(i)){let u,s;if(a[2]==="@")u=a[0],s="mailto:"+u;else{let c;do c=a[0],a[0]=this.rules.inline._backpedal.exec(a[0])?.[0]??"";while(c!==a[0]);u=a[0],a[1]==="www."?s="http://"+a[0]:s=a[0]}return{type:"link",raw:a[0],text:u,href:s,tokens:[{type:"text",raw:u,text:u}]}}}inlineText(i){let a=this.rules.inline.text.exec(i);if(a){let u=this.lexer.state.inRawBlock;return{type:"text",raw:a[0],text:a[0],escaped:u}}}},Ml=class uo{tokens;options;state;inlineQueue;tokenizer;constructor(a){this.tokens=[],this.tokens.links=Object.create(null),this.options=a||Aa,this.options.tokenizer=this.options.tokenizer||new qs,this.tokenizer=this.options.tokenizer,this.tokenizer.options=this.options,this.tokenizer.lexer=this,this.inlineQueue=[],this.state={inLink:!1,inRawBlock:!1,top:!0};let u={other:Xt,block:ws.normal,inline:cu.normal};this.options.pedantic?(u.block=ws.pedantic,u.inline=cu.pedantic):this.options.gfm&&(u.block=ws.gfm,this.options.breaks?u.inline=cu.breaks:u.inline=cu.gfm),this.tokenizer.rules=u}static get rules(){return{block:ws,inline:cu}}static lex(a,u){return new uo(u).lex(a)}static lexInline(a,u){return new uo(u).inlineTokens(a)}lex(a){a=a.replace(Xt.carriageReturn,`
37
- `),this.blockTokens(a,this.tokens);for(let u=0;u<this.inlineQueue.length;u++){let s=this.inlineQueue[u];this.inlineTokens(s.src,s.tokens)}return this.inlineQueue=[],this.tokens}blockTokens(a,u=[],s=!1){for(this.options.pedantic&&(a=a.replace(Xt.tabCharGlobal," ").replace(Xt.spaceLine,""));a;){let c;if(this.options.extensions?.block?.some(d=>(c=d.call({lexer:this},a,u))?(a=a.substring(c.raw.length),u.push(c),!0):!1))continue;if(c=this.tokenizer.space(a)){a=a.substring(c.raw.length);let d=u.at(-1);c.raw.length===1&&d!==void 0?d.raw+=`
38
- `:u.push(c);continue}if(c=this.tokenizer.code(a)){a=a.substring(c.raw.length);let d=u.at(-1);d?.type==="paragraph"||d?.type==="text"?(d.raw+=(d.raw.endsWith(`
39
- `)?"":`
40
- `)+c.raw,d.text+=`
41
- `+c.text,this.inlineQueue.at(-1).src=d.text):u.push(c);continue}if(c=this.tokenizer.fences(a)){a=a.substring(c.raw.length),u.push(c);continue}if(c=this.tokenizer.heading(a)){a=a.substring(c.raw.length),u.push(c);continue}if(c=this.tokenizer.hr(a)){a=a.substring(c.raw.length),u.push(c);continue}if(c=this.tokenizer.blockquote(a)){a=a.substring(c.raw.length),u.push(c);continue}if(c=this.tokenizer.list(a)){a=a.substring(c.raw.length),u.push(c);continue}if(c=this.tokenizer.html(a)){a=a.substring(c.raw.length),u.push(c);continue}if(c=this.tokenizer.def(a)){a=a.substring(c.raw.length);let d=u.at(-1);d?.type==="paragraph"||d?.type==="text"?(d.raw+=(d.raw.endsWith(`
42
- `)?"":`
43
- `)+c.raw,d.text+=`
44
- `+c.raw,this.inlineQueue.at(-1).src=d.text):this.tokens.links[c.tag]||(this.tokens.links[c.tag]={href:c.href,title:c.title},u.push(c));continue}if(c=this.tokenizer.table(a)){a=a.substring(c.raw.length),u.push(c);continue}if(c=this.tokenizer.lheading(a)){a=a.substring(c.raw.length),u.push(c);continue}let f=a;if(this.options.extensions?.startBlock){let d=1/0,p=a.slice(1),g;this.options.extensions.startBlock.forEach(y=>{g=y.call({lexer:this},p),typeof g=="number"&&g>=0&&(d=Math.min(d,g))}),d<1/0&&d>=0&&(f=a.substring(0,d+1))}if(this.state.top&&(c=this.tokenizer.paragraph(f))){let d=u.at(-1);s&&d?.type==="paragraph"?(d.raw+=(d.raw.endsWith(`
45
- `)?"":`
46
- `)+c.raw,d.text+=`
47
- `+c.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=d.text):u.push(c),s=f.length!==a.length,a=a.substring(c.raw.length);continue}if(c=this.tokenizer.text(a)){a=a.substring(c.raw.length);let d=u.at(-1);d?.type==="text"?(d.raw+=(d.raw.endsWith(`
48
- `)?"":`
49
- `)+c.raw,d.text+=`
50
- `+c.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=d.text):u.push(c);continue}if(a){let d="Infinite loop on byte: "+a.charCodeAt(0);if(this.options.silent){console.error(d);break}else throw new Error(d)}}return this.state.top=!0,u}inline(a,u=[]){return this.inlineQueue.push({src:a,tokens:u}),u}inlineTokens(a,u=[]){let s=a,c=null;if(this.tokens.links){let g=Object.keys(this.tokens.links);if(g.length>0)for(;(c=this.tokenizer.rules.inline.reflinkSearch.exec(s))!=null;)g.includes(c[0].slice(c[0].lastIndexOf("[")+1,-1))&&(s=s.slice(0,c.index)+"["+"a".repeat(c[0].length-2)+"]"+s.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex))}for(;(c=this.tokenizer.rules.inline.anyPunctuation.exec(s))!=null;)s=s.slice(0,c.index)+"++"+s.slice(this.tokenizer.rules.inline.anyPunctuation.lastIndex);let f;for(;(c=this.tokenizer.rules.inline.blockSkip.exec(s))!=null;)f=c[2]?c[2].length:0,s=s.slice(0,c.index+f)+"["+"a".repeat(c[0].length-f-2)+"]"+s.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);s=this.options.hooks?.emStrongMask?.call({lexer:this},s)??s;let d=!1,p="";for(;a;){d||(p=""),d=!1;let g;if(this.options.extensions?.inline?.some(x=>(g=x.call({lexer:this},a,u))?(a=a.substring(g.raw.length),u.push(g),!0):!1))continue;if(g=this.tokenizer.escape(a)){a=a.substring(g.raw.length),u.push(g);continue}if(g=this.tokenizer.tag(a)){a=a.substring(g.raw.length),u.push(g);continue}if(g=this.tokenizer.link(a)){a=a.substring(g.raw.length),u.push(g);continue}if(g=this.tokenizer.reflink(a,this.tokens.links)){a=a.substring(g.raw.length);let x=u.at(-1);g.type==="text"&&x?.type==="text"?(x.raw+=g.raw,x.text+=g.text):u.push(g);continue}if(g=this.tokenizer.emStrong(a,s,p)){a=a.substring(g.raw.length),u.push(g);continue}if(g=this.tokenizer.codespan(a)){a=a.substring(g.raw.length),u.push(g);continue}if(g=this.tokenizer.br(a)){a=a.substring(g.raw.length),u.push(g);continue}if(g=this.tokenizer.del(a,s,p)){a=a.substring(g.raw.length),u.push(g);continue}if(g=this.tokenizer.autolink(a)){a=a.substring(g.raw.length),u.push(g);continue}if(!this.state.inLink&&(g=this.tokenizer.url(a))){a=a.substring(g.raw.length),u.push(g);continue}let y=a;if(this.options.extensions?.startInline){let x=1/0,A=a.slice(1),z;this.options.extensions.startInline.forEach(q=>{z=q.call({lexer:this},A),typeof z=="number"&&z>=0&&(x=Math.min(x,z))}),x<1/0&&x>=0&&(y=a.substring(0,x+1))}if(g=this.tokenizer.inlineText(y)){a=a.substring(g.raw.length),g.raw.slice(-1)!=="_"&&(p=g.raw.slice(-1)),d=!0;let x=u.at(-1);x?.type==="text"?(x.raw+=g.raw,x.text+=g.text):u.push(g);continue}if(a){let x="Infinite loop on byte: "+a.charCodeAt(0);if(this.options.silent){console.error(x);break}else throw new Error(x)}}return u}},Hs=class{options;parser;constructor(i){this.options=i||Aa}space(i){return""}code({text:i,lang:a,escaped:u}){let s=(a||"").match(Xt.notSpaceStart)?.[0],c=i.replace(Xt.endingNewline,"")+`
51
- `;return s?'<pre><code class="language-'+ql(s)+'">'+(u?c:ql(c,!0))+`</code></pre>
52
- `:"<pre><code>"+(u?c:ql(c,!0))+`</code></pre>
53
- `}blockquote({tokens:i}){return`<blockquote>
54
- ${this.parser.parse(i)}</blockquote>
55
- `}html({text:i}){return i}def(i){return""}heading({tokens:i,depth:a}){return`<h${a}>${this.parser.parseInline(i)}</h${a}>
56
- `}hr(i){return`<hr>
57
- `}list(i){let a=i.ordered,u=i.start,s="";for(let d=0;d<i.items.length;d++){let p=i.items[d];s+=this.listitem(p)}let c=a?"ol":"ul",f=a&&u!==1?' start="'+u+'"':"";return"<"+c+f+`>
58
- `+s+"</"+c+`>
59
- `}listitem(i){return`<li>${this.parser.parse(i.tokens)}</li>
60
- `}checkbox({checked:i}){return"<input "+(i?'checked="" ':"")+'disabled="" type="checkbox"> '}paragraph({tokens:i}){return`<p>${this.parser.parseInline(i)}</p>
61
- `}table(i){let a="",u="";for(let c=0;c<i.header.length;c++)u+=this.tablecell(i.header[c]);a+=this.tablerow({text:u});let s="";for(let c=0;c<i.rows.length;c++){let f=i.rows[c];u="";for(let d=0;d<f.length;d++)u+=this.tablecell(f[d]);s+=this.tablerow({text:u})}return s&&(s=`<tbody>${s}</tbody>`),`<table>
62
- <thead>
63
- `+a+`</thead>
64
- `+s+`</table>
65
- `}tablerow({text:i}){return`<tr>
66
- ${i}</tr>
67
- `}tablecell(i){let a=this.parser.parseInline(i.tokens),u=i.header?"th":"td";return(i.align?`<${u} align="${i.align}">`:`<${u}>`)+a+`</${u}>
68
- `}strong({tokens:i}){return`<strong>${this.parser.parseInline(i)}</strong>`}em({tokens:i}){return`<em>${this.parser.parseInline(i)}</em>`}codespan({text:i}){return`<code>${ql(i,!0)}</code>`}br(i){return"<br>"}del({tokens:i}){return`<del>${this.parser.parseInline(i)}</del>`}link({href:i,title:a,tokens:u}){let s=this.parser.parseInline(u),c=jp(i);if(c===null)return s;i=c;let f='<a href="'+i+'"';return a&&(f+=' title="'+ql(a)+'"'),f+=">"+s+"</a>",f}image({href:i,title:a,text:u,tokens:s}){s&&(u=this.parser.parseInline(s,this.parser.textRenderer));let c=jp(i);if(c===null)return ql(u);i=c;let f=`<img src="${i}" alt="${ql(u)}"`;return a&&(f+=` title="${ql(a)}"`),f+=">",f}text(i){return"tokens"in i&&i.tokens?this.parser.parseInline(i.tokens):"escaped"in i&&i.escaped?i.text:ql(i.text)}},No=class{strong({text:i}){return i}em({text:i}){return i}codespan({text:i}){return i}del({text:i}){return i}html({text:i}){return i}text({text:i}){return i}link({text:i}){return""+i}image({text:i}){return""+i}br(){return""}checkbox({raw:i}){return i}},zl=class so{options;renderer;textRenderer;constructor(a){this.options=a||Aa,this.options.renderer=this.options.renderer||new Hs,this.renderer=this.options.renderer,this.renderer.options=this.options,this.renderer.parser=this,this.textRenderer=new No}static parse(a,u){return new so(u).parse(a)}static parseInline(a,u){return new so(u).parseInline(a)}parse(a){let u="";for(let s=0;s<a.length;s++){let c=a[s];if(this.options.extensions?.renderers?.[c.type]){let d=c,p=this.options.extensions.renderers[d.type].call({parser:this},d);if(p!==!1||!["space","hr","heading","code","table","blockquote","list","html","def","paragraph","text"].includes(d.type)){u+=p||"";continue}}let f=c;switch(f.type){case"space":{u+=this.renderer.space(f);break}case"hr":{u+=this.renderer.hr(f);break}case"heading":{u+=this.renderer.heading(f);break}case"code":{u+=this.renderer.code(f);break}case"table":{u+=this.renderer.table(f);break}case"blockquote":{u+=this.renderer.blockquote(f);break}case"list":{u+=this.renderer.list(f);break}case"checkbox":{u+=this.renderer.checkbox(f);break}case"html":{u+=this.renderer.html(f);break}case"def":{u+=this.renderer.def(f);break}case"paragraph":{u+=this.renderer.paragraph(f);break}case"text":{u+=this.renderer.text(f);break}default:{let d='Token with "'+f.type+'" type was not found.';if(this.options.silent)return console.error(d),"";throw new Error(d)}}}return u}parseInline(a,u=this.renderer){let s="";for(let c=0;c<a.length;c++){let f=a[c];if(this.options.extensions?.renderers?.[f.type]){let p=this.options.extensions.renderers[f.type].call({parser:this},f);if(p!==!1||!["escape","html","link","image","strong","em","codespan","br","del","text"].includes(f.type)){s+=p||"";continue}}let d=f;switch(d.type){case"escape":{s+=u.text(d);break}case"html":{s+=u.html(d);break}case"link":{s+=u.link(d);break}case"image":{s+=u.image(d);break}case"checkbox":{s+=u.checkbox(d);break}case"strong":{s+=u.strong(d);break}case"em":{s+=u.em(d);break}case"codespan":{s+=u.codespan(d);break}case"br":{s+=u.br(d);break}case"del":{s+=u.del(d);break}case"text":{s+=u.text(d);break}default:{let p='Token with "'+d.type+'" type was not found.';if(this.options.silent)return console.error(p),"";throw new Error(p)}}}return s}},du=class{options;block;constructor(i){this.options=i||Aa}static passThroughHooks=new Set(["preprocess","postprocess","processAllTokens","emStrongMask"]);static passThroughHooksRespectAsync=new Set(["preprocess","postprocess","processAllTokens"]);preprocess(i){return i}postprocess(i){return i}processAllTokens(i){return i}emStrongMask(i){return i}provideLexer(){return this.block?Ml.lex:Ml.lexInline}provideParser(){return this.block?zl.parse:zl.parseInline}},I0=class{defaults=xo();options=this.setOptions;parse=this.parseMarkdown(!0);parseInline=this.parseMarkdown(!1);Parser=zl;Renderer=Hs;TextRenderer=No;Lexer=Ml;Tokenizer=qs;Hooks=du;constructor(...i){this.use(...i)}walkTokens(i,a){let u=[];for(let s of i)switch(u=u.concat(a.call(this,s)),s.type){case"table":{let c=s;for(let f of c.header)u=u.concat(this.walkTokens(f.tokens,a));for(let f of c.rows)for(let d of f)u=u.concat(this.walkTokens(d.tokens,a));break}case"list":{let c=s;u=u.concat(this.walkTokens(c.items,a));break}default:{let c=s;this.defaults.extensions?.childTokens?.[c.type]?this.defaults.extensions.childTokens[c.type].forEach(f=>{let d=c[f].flat(1/0);u=u.concat(this.walkTokens(d,a))}):c.tokens&&(u=u.concat(this.walkTokens(c.tokens,a)))}}return u}use(...i){let a=this.defaults.extensions||{renderers:{},childTokens:{}};return i.forEach(u=>{let s={...u};if(s.async=this.defaults.async||s.async||!1,u.extensions&&(u.extensions.forEach(c=>{if(!c.name)throw new Error("extension name required");if("renderer"in c){let f=a.renderers[c.name];f?a.renderers[c.name]=function(...d){let p=c.renderer.apply(this,d);return p===!1&&(p=f.apply(this,d)),p}:a.renderers[c.name]=c.renderer}if("tokenizer"in c){if(!c.level||c.level!=="block"&&c.level!=="inline")throw new Error("extension level must be 'block' or 'inline'");let f=a[c.level];f?f.unshift(c.tokenizer):a[c.level]=[c.tokenizer],c.start&&(c.level==="block"?a.startBlock?a.startBlock.push(c.start):a.startBlock=[c.start]:c.level==="inline"&&(a.startInline?a.startInline.push(c.start):a.startInline=[c.start]))}"childTokens"in c&&c.childTokens&&(a.childTokens[c.name]=c.childTokens)}),s.extensions=a),u.renderer){let c=this.defaults.renderer||new Hs(this.defaults);for(let f in u.renderer){if(!(f in c))throw new Error(`renderer '${f}' does not exist`);if(["options","parser"].includes(f))continue;let d=f,p=u.renderer[d],g=c[d];c[d]=(...y)=>{let x=p.apply(c,y);return x===!1&&(x=g.apply(c,y)),x||""}}s.renderer=c}if(u.tokenizer){let c=this.defaults.tokenizer||new qs(this.defaults);for(let f in u.tokenizer){if(!(f in c))throw new Error(`tokenizer '${f}' does not exist`);if(["options","rules","lexer"].includes(f))continue;let d=f,p=u.tokenizer[d],g=c[d];c[d]=(...y)=>{let x=p.apply(c,y);return x===!1&&(x=g.apply(c,y)),x}}s.tokenizer=c}if(u.hooks){let c=this.defaults.hooks||new du;for(let f in u.hooks){if(!(f in c))throw new Error(`hook '${f}' does not exist`);if(["options","block"].includes(f))continue;let d=f,p=u.hooks[d],g=c[d];du.passThroughHooks.has(f)?c[d]=y=>{if(this.defaults.async&&du.passThroughHooksRespectAsync.has(f))return(async()=>{let A=await p.call(c,y);return g.call(c,A)})();let x=p.call(c,y);return g.call(c,x)}:c[d]=(...y)=>{if(this.defaults.async)return(async()=>{let A=await p.apply(c,y);return A===!1&&(A=await g.apply(c,y)),A})();let x=p.apply(c,y);return x===!1&&(x=g.apply(c,y)),x}}s.hooks=c}if(u.walkTokens){let c=this.defaults.walkTokens,f=u.walkTokens;s.walkTokens=function(d){let p=[];return p.push(f.call(this,d)),c&&(p=p.concat(c.call(this,d))),p}}this.defaults={...this.defaults,...s}}),this}setOptions(i){return this.defaults={...this.defaults,...i},this}lexer(i,a){return Ml.lex(i,a??this.defaults)}parser(i,a){return zl.parse(i,a??this.defaults)}parseMarkdown(i){return(a,u)=>{let s={...u},c={...this.defaults,...s},f=this.onError(!!c.silent,!!c.async);if(this.defaults.async===!0&&s.async===!1)return f(new Error("marked(): The async option was set to true by an extension. Remove async: false from the parse options object to return a Promise."));if(typeof a>"u"||a===null)return f(new Error("marked(): input parameter is undefined or null"));if(typeof a!="string")return f(new Error("marked(): input parameter is of type "+Object.prototype.toString.call(a)+", string expected"));if(c.hooks&&(c.hooks.options=c,c.hooks.block=i),c.async)return(async()=>{let d=c.hooks?await c.hooks.preprocess(a):a,p=await(c.hooks?await c.hooks.provideLexer():i?Ml.lex:Ml.lexInline)(d,c),g=c.hooks?await c.hooks.processAllTokens(p):p;c.walkTokens&&await Promise.all(this.walkTokens(g,c.walkTokens));let y=await(c.hooks?await c.hooks.provideParser():i?zl.parse:zl.parseInline)(g,c);return c.hooks?await c.hooks.postprocess(y):y})().catch(f);try{c.hooks&&(a=c.hooks.preprocess(a));let d=(c.hooks?c.hooks.provideLexer():i?Ml.lex:Ml.lexInline)(a,c);c.hooks&&(d=c.hooks.processAllTokens(d)),c.walkTokens&&this.walkTokens(d,c.walkTokens);let p=(c.hooks?c.hooks.provideParser():i?zl.parse:zl.parseInline)(d,c);return c.hooks&&(p=c.hooks.postprocess(p)),p}catch(d){return f(d)}}}onError(i,a){return u=>{if(u.message+=`
69
- Please report this to https://github.com/markedjs/marked.`,i){let s="<p>An error occurred:</p><pre>"+ql(u.message+"",!0)+"</pre>";return a?Promise.resolve(s):s}if(a)return Promise.reject(u);throw u}}},Ea=new I0;function Ze(i,a){return Ea.parse(i,a)}Ze.options=Ze.setOptions=function(i){return Ea.setOptions(i),Ze.defaults=Ea.defaults,Jp(Ze.defaults),Ze};Ze.getDefaults=xo;Ze.defaults=Aa;Ze.use=function(...i){return Ea.use(...i),Ze.defaults=Ea.defaults,Jp(Ze.defaults),Ze};Ze.walkTokens=function(i,a){return Ea.walkTokens(i,a)};Ze.parseInline=Ea.parseInline;Ze.Parser=zl;Ze.parser=zl.parse;Ze.Renderer=Hs;Ze.TextRenderer=No;Ze.Lexer=Ml;Ze.lexer=Ml.lex;Ze.Tokenizer=qs;Ze.Hooks=du;Ze.parse=Ze;Ze.options;Ze.setOptions;Ze.use;Ze.walkTokens;Ze.parseInline;zl.parse;Ml.lex;function P0({endpoint:i,collapsed:a,onToggle:u}){if(!i)return null;const s=i.summary||i.operationId||"",c=i.description||"",f=i.deprecated||!1,d=k.useMemo(()=>{if(!c)return"";try{return Ze(c)}catch{return c}},[c]);return!s&&!c&&!f?null:b.jsxs("div",{className:"endpoint-doc",children:[b.jsxs("button",{className:"endpoint-doc__toggle",onClick:u,children:[b.jsx("span",{children:s||"Documentation"}),b.jsx("span",{className:`endpoint-doc__toggle-icon${a?"":" endpoint-doc__toggle-icon--expanded"}`,children:"▶"})]}),!a&&b.jsxs("div",{className:"endpoint-doc__body",children:[f&&b.jsx("div",{className:"endpoint-doc__deprecated",children:"Deprecated - This endpoint is marked as deprecated"}),d&&b.jsx("div",{dangerouslySetInnerHTML:{__html:d}})]})]})}function eb({spec:i,endpoint:a,params:u,onParamsChange:s,onSend:c,sending:f,serverIndex:d,onServerIndexChange:p,serverVariables:g,onServerVariablesChange:y,preferences:x,resolvedEnv:A}){const[z,q]=k.useState(!1),Q=a?.servers||[],$=Q[d]||{},X=k.useMemo(()=>{const w=($.url||"").match(/\{([^}]+)\}/g);return w?w.map(P=>P.slice(1,-1)):[]},[$.url]);if(!a)return b.jsx("div",{style:{color:"var(--fg-muted)",padding:"32px",textAlign:"center"},children:"Select an endpoint to begin"});const K=a.parameters||[],se=K.filter(R=>R.in==="path"),be=K.filter(R=>R.in==="query"),Se=K.filter(R=>R.in==="header"),oe=(R,w,P)=>{s({...u,[R]:{...u[R]||{},[w]:P}})},ve=a.request_body||a.requestBody;return b.jsxs("div",{children:[Q.length>0&&b.jsxs("div",{className:"request-panel__section",children:[b.jsx("div",{className:"request-panel__section-title",children:"Server"}),b.jsx("select",{className:"request-panel__server-select",value:d,onChange:R=>p(Number(R.target.value)),children:Q.map((R,w)=>b.jsxs("option",{value:w,children:[R.url,R.description?` - ${R.description}`:""]},w))}),X.length>0&&b.jsx("div",{className:"request-panel__server-vars",children:X.map(R=>{const w=$.variables?.[R];return b.jsxs("div",{className:"param-form__field",children:[b.jsx("label",{className:"param-form__label",children:R}),w?.description&&b.jsx("span",{className:"param-form__desc",children:w.description}),b.jsx("input",{className:"param-form__input",type:"text",value:g[R]??w?.default??"",placeholder:w?.default||"",onChange:P=>y({...g,[R]:P.target.value})})]},R)})})]}),se.length>0&&b.jsxs("div",{className:"request-panel__section",children:[b.jsx("div",{className:"request-panel__section-title",children:"Path Parameters"}),b.jsx(eo,{parameters:se,values:u.path||{},onChange:(R,w)=>oe("path",R,w),resolvedEnv:A})]}),be.length>0&&b.jsxs("div",{className:"request-panel__section",children:[b.jsx("div",{className:"request-panel__section-title",children:"Query Parameters"}),b.jsx(eo,{parameters:be,values:u.query||{},onChange:(R,w)=>oe("query",R,w),resolvedEnv:A})]}),Se.length>0&&b.jsxs("div",{className:"request-panel__section",children:[b.jsx("div",{className:"request-panel__section-title",children:"Headers"}),b.jsx(eo,{parameters:Se,values:u.header||{},onChange:(R,w)=>oe("header",R,w),resolvedEnv:A})]}),ve&&b.jsxs("div",{className:"request-panel__section",children:[b.jsx("div",{className:"request-panel__section-title",children:"Request Body"}),b.jsx(c0,{endpoint:a,body:u.body||"",contentType:u.contentType||"",onBodyChange:R=>s({...u,body:R}),onContentTypeChange:R=>s({...u,contentType:R}),resolvedEnv:A})]}),b.jsxs("div",{className:"request-panel__send-bar",children:[b.jsx("button",{className:"request-panel__send-btn",onClick:c,disabled:f,children:f?"Sending...":"Send"}),f&&b.jsx("span",{className:"request-panel__spinner"})]}),b.jsx(P0,{endpoint:a,collapsed:z,onToggle:()=>q(R=>!R)})]})}var to,Mp;function tb(){if(Mp)return to;Mp=1;function i(v){return v instanceof Map?v.clear=v.delete=v.set=function(){throw new Error("map is read-only")}:v instanceof Set&&(v.add=v.clear=v.delete=function(){throw new Error("set is read-only")}),Object.freeze(v),Object.getOwnPropertyNames(v).forEach(M=>{const Y=v[M],he=typeof Y;(he==="object"||he==="function")&&!Object.isFrozen(Y)&&i(Y)}),v}class a{constructor(M){M.data===void 0&&(M.data={}),this.data=M.data,this.isMatchIgnored=!1}ignoreMatch(){this.isMatchIgnored=!0}}function u(v){return v.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/'/g,"&#x27;")}function s(v,...M){const Y=Object.create(null);for(const he in v)Y[he]=v[he];return M.forEach(function(he){for(const Ke in he)Y[Ke]=he[Ke]}),Y}const c="</span>",f=v=>!!v.scope,d=(v,{prefix:M})=>{if(v.startsWith("language:"))return v.replace("language:","language-");if(v.includes(".")){const Y=v.split(".");return[`${M}${Y.shift()}`,...Y.map((he,Ke)=>`${he}${"_".repeat(Ke+1)}`)].join(" ")}return`${M}${v}`};class p{constructor(M,Y){this.buffer="",this.classPrefix=Y.classPrefix,M.walk(this)}addText(M){this.buffer+=u(M)}openNode(M){if(!f(M))return;const Y=d(M.scope,{prefix:this.classPrefix});this.span(Y)}closeNode(M){f(M)&&(this.buffer+=c)}value(){return this.buffer}span(M){this.buffer+=`<span class="${M}">`}}const g=(v={})=>{const M={children:[]};return Object.assign(M,v),M};class y{constructor(){this.rootNode=g(),this.stack=[this.rootNode]}get top(){return this.stack[this.stack.length-1]}get root(){return this.rootNode}add(M){this.top.children.push(M)}openNode(M){const Y=g({scope:M});this.add(Y),this.stack.push(Y)}closeNode(){if(this.stack.length>1)return this.stack.pop()}closeAllNodes(){for(;this.closeNode(););}toJSON(){return JSON.stringify(this.rootNode,null,4)}walk(M){return this.constructor._walk(M,this.rootNode)}static _walk(M,Y){return typeof Y=="string"?M.addText(Y):Y.children&&(M.openNode(Y),Y.children.forEach(he=>this._walk(M,he)),M.closeNode(Y)),M}static _collapse(M){typeof M!="string"&&M.children&&(M.children.every(Y=>typeof Y=="string")?M.children=[M.children.join("")]:M.children.forEach(Y=>{y._collapse(Y)}))}}class x extends y{constructor(M){super(),this.options=M}addText(M){M!==""&&this.add(M)}startScope(M){this.openNode(M)}endScope(){this.closeNode()}__addSublanguage(M,Y){const he=M.root;Y&&(he.scope=`language:${Y}`),this.add(he)}toHTML(){return new p(this,this.options).value()}finalize(){return this.closeAllNodes(),!0}}function A(v){return v?typeof v=="string"?v:v.source:null}function z(v){return $("(?=",v,")")}function q(v){return $("(?:",v,")*")}function Q(v){return $("(?:",v,")?")}function $(...v){return v.map(Y=>A(Y)).join("")}function X(v){const M=v[v.length-1];return typeof M=="object"&&M.constructor===Object?(v.splice(v.length-1,1),M):{}}function K(...v){return"("+(X(v).capture?"":"?:")+v.map(he=>A(he)).join("|")+")"}function se(v){return new RegExp(v.toString()+"|").exec("").length-1}function be(v,M){const Y=v&&v.exec(M);return Y&&Y.index===0}const Se=/\[(?:[^\\\]]|\\.)*\]|\(\??|\\([1-9][0-9]*)|\\./;function oe(v,{joinWith:M}){let Y=0;return v.map(he=>{Y+=1;const Ke=Y;let Ie=A(he),ne="";for(;Ie.length>0;){const te=Se.exec(Ie);if(!te){ne+=Ie;break}ne+=Ie.substring(0,te.index),Ie=Ie.substring(te.index+te[0].length),te[0][0]==="\\"&&te[1]?ne+="\\"+String(Number(te[1])+Ke):(ne+=te[0],te[0]==="("&&Y++)}return ne}).map(he=>`(${he})`).join(M)}const ve=/\b\B/,R="[a-zA-Z]\\w*",w="[a-zA-Z_]\\w*",P="\\b\\d+(\\.\\d+)?",Ve="(-?)(\\b0[xX][a-fA-F0-9]+|(\\b\\d+(\\.\\d*)?|\\.\\d+)([eE][-+]?\\d+)?)",W="\\b(0b[01]+)",me="!|!=|!==|%|%=|&|&&|&=|\\*|\\*=|\\+|\\+=|,|-|-=|/=|/|:|;|<<|<<=|<=|<|===|==|=|>>>=|>>=|>=|>>>|>>|>|\\?|\\[|\\{|\\(|\\^|\\^=|\\||\\|=|\\|\\||~",et=(v={})=>{const M=/^#![ ]*\//;return v.binary&&(v.begin=$(M,/.*\b/,v.binary,/\b.*/)),s({scope:"meta",begin:M,end:/$/,relevance:0,"on:begin":(Y,he)=>{Y.index!==0&&he.ignoreMatch()}},v)},Me={begin:"\\\\[\\s\\S]",relevance:0},We={scope:"string",begin:"'",end:"'",illegal:"\\n",contains:[Me]},D={scope:"string",begin:'"',end:'"',illegal:"\\n",contains:[Me]},F={begin:/\b(a|an|the|are|I'm|isn't|don't|doesn't|won't|but|just|should|pretty|simply|enough|gonna|going|wtf|so|such|will|you|your|they|like|more)\b/},re=function(v,M,Y={}){const he=s({scope:"comment",begin:v,end:M,contains:[]},Y);he.contains.push({scope:"doctag",begin:"[ ]*(?=(TODO|FIXME|NOTE|BUG|OPTIMIZE|HACK|XXX):)",end:/(TODO|FIXME|NOTE|BUG|OPTIMIZE|HACK|XXX):/,excludeBegin:!0,relevance:0});const Ke=K("I","a","is","so","us","to","at","if","in","it","on",/[A-Za-z]+['](d|ve|re|ll|t|s|n)/,/[A-Za-z]+[-][a-z]+/,/[A-Za-z][a-z]{2,}/);return he.contains.push({begin:$(/[ ]+/,"(",Ke,/[.]?[:]?([.][ ]|[ ])/,"){3}")}),he},Be=re("//","$"),He=re("/\\*","\\*/"),E=re("#","$"),L={scope:"number",begin:P,relevance:0},I={scope:"number",begin:Ve,relevance:0},ee={scope:"number",begin:W,relevance:0},ye={scope:"regexp",begin:/\/(?=[^/\n]*\/)/,end:/\/[gimuy]*/,contains:[Me,{begin:/\[/,end:/\]/,relevance:0,contains:[Me]}]},_e={scope:"title",begin:R,relevance:0},we={scope:"title",begin:w,relevance:0},dt={begin:"\\.\\s*"+w,relevance:0};var Lt=Object.freeze({__proto__:null,APOS_STRING_MODE:We,BACKSLASH_ESCAPE:Me,BINARY_NUMBER_MODE:ee,BINARY_NUMBER_RE:W,COMMENT:re,C_BLOCK_COMMENT_MODE:He,C_LINE_COMMENT_MODE:Be,C_NUMBER_MODE:I,C_NUMBER_RE:Ve,END_SAME_AS_BEGIN:function(v){return Object.assign(v,{"on:begin":(M,Y)=>{Y.data._beginMatch=M[1]},"on:end":(M,Y)=>{Y.data._beginMatch!==M[1]&&Y.ignoreMatch()}})},HASH_COMMENT_MODE:E,IDENT_RE:R,MATCH_NOTHING_RE:ve,METHOD_GUARD:dt,NUMBER_MODE:L,NUMBER_RE:P,PHRASAL_WORDS_MODE:F,QUOTE_STRING_MODE:D,REGEXP_MODE:ye,RE_STARTERS_RE:me,SHEBANG:et,TITLE_MODE:_e,UNDERSCORE_IDENT_RE:w,UNDERSCORE_TITLE_MODE:we});function yn(v,M){v.input[v.index-1]==="."&&M.ignoreMatch()}function bn(v,M){v.className!==void 0&&(v.scope=v.className,delete v.className)}function In(v,M){M&&v.beginKeywords&&(v.begin="\\b("+v.beginKeywords.split(" ").join("|")+")(?!\\.)(?=\\b|\\s)",v.__beforeBegin=yn,v.keywords=v.keywords||v.beginKeywords,delete v.beginKeywords,v.relevance===void 0&&(v.relevance=0))}function Pt(v,M){Array.isArray(v.illegal)&&(v.illegal=K(...v.illegal))}function Yl(v,M){if(v.match){if(v.begin||v.end)throw new Error("begin & end are not supported with match");v.begin=v.match,delete v.match}}function fl(v,M){v.relevance===void 0&&(v.relevance=1)}const Ta=(v,M)=>{if(!v.beforeMatch)return;if(v.starts)throw new Error("beforeMatch cannot be used with starts");const Y=Object.assign({},v);Object.keys(v).forEach(he=>{delete v[he]}),v.keywords=Y.keywords,v.begin=$(Y.beforeMatch,z(Y.begin)),v.starts={relevance:0,contains:[Object.assign(Y,{endsParent:!0})]},v.relevance=0,delete Y.beforeMatch},vn=["of","and","for","in","not","or","if","then","parent","list","value"],Qt="keyword";function Al(v,M,Y=Qt){const he=Object.create(null);return typeof v=="string"?Ke(Y,v.split(" ")):Array.isArray(v)?Ke(Y,v):Object.keys(v).forEach(function(Ie){Object.assign(he,Al(v[Ie],M,Ie))}),he;function Ke(Ie,ne){M&&(ne=ne.map(te=>te.toLowerCase())),ne.forEach(function(te){const pe=te.split("|");he[pe[0]]=[Ie,xn(pe[0],pe[1])]})}}function xn(v,M){return M?Number(M):Pn(v)?0:1}function Pn(v){return vn.includes(v.toLowerCase())}const ea={},st=v=>{console.error(v)},kt=(v,...M)=>{console.log(`WARN: ${v}`,...M)},Bt=(v,M)=>{ea[`${v}/${M}`]||(console.log(`Deprecated as of ${v}. ${M}`),ea[`${v}/${M}`]=!0)},Cl=new Error;function Xl(v,M,{key:Y}){let he=0;const Ke=v[Y],Ie={},ne={};for(let te=1;te<=M.length;te++)ne[te+he]=Ke[te],Ie[te+he]=!0,he+=se(M[te-1]);v[Y]=ne,v[Y]._emit=Ie,v[Y]._multi=!0}function Ql(v){if(Array.isArray(v.begin)){if(v.skip||v.excludeBegin||v.returnBegin)throw st("skip, excludeBegin, returnBegin not compatible with beginScope: {}"),Cl;if(typeof v.beginScope!="object"||v.beginScope===null)throw st("beginScope must be object"),Cl;Xl(v,v.begin,{key:"beginScope"}),v.begin=oe(v.begin,{joinWith:""})}}function Sn(v){if(Array.isArray(v.end)){if(v.skip||v.excludeEnd||v.returnEnd)throw st("skip, excludeEnd, returnEnd not compatible with endScope: {}"),Cl;if(typeof v.endScope!="object"||v.endScope===null)throw st("endScope must be object"),Cl;Xl(v,v.end,{key:"endScope"}),v.end=oe(v.end,{joinWith:""})}}function oi(v){v.scope&&typeof v.scope=="object"&&v.scope!==null&&(v.beginScope=v.scope,delete v.scope)}function fi(v){oi(v),typeof v.beginScope=="string"&&(v.beginScope={_wrap:v.beginScope}),typeof v.endScope=="string"&&(v.endScope={_wrap:v.endScope}),Ql(v),Sn(v)}function Zl(v){function M(ne,te){return new RegExp(A(ne),"m"+(v.case_insensitive?"i":"")+(v.unicodeRegex?"u":"")+(te?"g":""))}class Y{constructor(){this.matchIndexes={},this.regexes=[],this.matchAt=1,this.position=0}addRule(te,pe){pe.position=this.position++,this.matchIndexes[this.matchAt]=pe,this.regexes.push([pe,te]),this.matchAt+=se(te)+1}compile(){this.regexes.length===0&&(this.exec=()=>null);const te=this.regexes.map(pe=>pe[1]);this.matcherRe=M(oe(te,{joinWith:"|"}),!0),this.lastIndex=0}exec(te){this.matcherRe.lastIndex=this.lastIndex;const pe=this.matcherRe.exec(te);if(!pe)return null;const pt=pe.findIndex((Kl,ja)=>ja>0&&Kl!==void 0),rt=this.matchIndexes[pt];return pe.splice(0,pt),Object.assign(pe,rt)}}class he{constructor(){this.rules=[],this.multiRegexes=[],this.count=0,this.lastIndex=0,this.regexIndex=0}getMatcher(te){if(this.multiRegexes[te])return this.multiRegexes[te];const pe=new Y;return this.rules.slice(te).forEach(([pt,rt])=>pe.addRule(pt,rt)),pe.compile(),this.multiRegexes[te]=pe,pe}resumingScanAtSamePosition(){return this.regexIndex!==0}considerAll(){this.regexIndex=0}addRule(te,pe){this.rules.push([te,pe]),pe.type==="begin"&&this.count++}exec(te){const pe=this.getMatcher(this.regexIndex);pe.lastIndex=this.lastIndex;let pt=pe.exec(te);if(this.resumingScanAtSamePosition()&&!(pt&&pt.index===this.lastIndex)){const rt=this.getMatcher(0);rt.lastIndex=this.lastIndex+1,pt=rt.exec(te)}return pt&&(this.regexIndex+=pt.position+1,this.regexIndex===this.count&&this.considerAll()),pt}}function Ke(ne){const te=new he;return ne.contains.forEach(pe=>te.addRule(pe.begin,{rule:pe,type:"begin"})),ne.terminatorEnd&&te.addRule(ne.terminatorEnd,{type:"end"}),ne.illegal&&te.addRule(ne.illegal,{type:"illegal"}),te}function Ie(ne,te){const pe=ne;if(ne.isCompiled)return pe;[bn,Yl,fi,Ta].forEach(rt=>rt(ne,te)),v.compilerExtensions.forEach(rt=>rt(ne,te)),ne.__beforeBegin=null,[In,Pt,fl].forEach(rt=>rt(ne,te)),ne.isCompiled=!0;let pt=null;return typeof ne.keywords=="object"&&ne.keywords.$pattern&&(ne.keywords=Object.assign({},ne.keywords),pt=ne.keywords.$pattern,delete ne.keywords.$pattern),pt=pt||/\w+/,ne.keywords&&(ne.keywords=Al(ne.keywords,v.case_insensitive)),pe.keywordPatternRe=M(pt,!0),te&&(ne.begin||(ne.begin=/\B|\b/),pe.beginRe=M(pe.begin),!ne.end&&!ne.endsWithParent&&(ne.end=/\B|\b/),ne.end&&(pe.endRe=M(pe.end)),pe.terminatorEnd=A(pe.end)||"",ne.endsWithParent&&te.terminatorEnd&&(pe.terminatorEnd+=(ne.end?"|":"")+te.terminatorEnd)),ne.illegal&&(pe.illegalRe=M(ne.illegal)),ne.contains||(ne.contains=[]),ne.contains=[].concat(...ne.contains.map(function(rt){return hl(rt==="self"?ne:rt)})),ne.contains.forEach(function(rt){Ie(rt,pe)}),ne.starts&&Ie(ne.starts,te),pe.matcher=Ke(pe),pe}if(v.compilerExtensions||(v.compilerExtensions=[]),v.contains&&v.contains.includes("self"))throw new Error("ERR: contains `self` is not supported at the top-level of a language. See documentation.");return v.classNameAliases=s(v.classNameAliases||{}),Ie(v)}function Ot(v){return v?v.endsWithParent||Ot(v.starts):!1}function hl(v){return v.variants&&!v.cachedVariants&&(v.cachedVariants=v.variants.map(function(M){return s(v,{variants:null},M)})),v.cachedVariants?v.cachedVariants:Ot(v)?s(v,{starts:v.starts?s(v.starts):null}):Object.isFrozen(v)?s(v):v}var Mt="11.11.1";class hi extends Error{constructor(M,Y){super(M),this.name="HTMLInjectionError",this.html=Y}}const ta=u,di=s,el=Symbol("nomatch"),Tl=7,Vl=function(v){const M=Object.create(null),Y=Object.create(null),he=[];let Ke=!0;const Ie="Could not find the language '{}', did you forget to load/include a language module?",ne={disableAutodetect:!0,name:"Plain text",contains:[]};let te={ignoreUnescapedHTML:!1,throwUnescapedHTML:!1,noHighlightRe:/^(no-?highlight)$/i,languageDetectRe:/\blang(?:uage)?-([\w-]+)\b/i,classPrefix:"hljs-",cssSelector:"pre code",languages:null,__emitter:x};function pe(Z){return te.noHighlightRe.test(Z)}function pt(Z){let ue=Z.className+" ";ue+=Z.parentNode?Z.parentNode.className:"";const je=te.languageDetectRe.exec(ue);if(je){const Ge=Gt(je[1]);return Ge||(kt(Ie.replace("{}",je[1])),kt("Falling back to no-highlight mode for this block.",Z)),Ge?je[1]:"no-highlight"}return ue.split(/\s+/).find(Ge=>pe(Ge)||Gt(Ge))}function rt(Z,ue,je){let Ge="",mt="";typeof ue=="object"?(Ge=Z,je=ue.ignoreIllegals,mt=ue.language):(Bt("10.7.0","highlight(lang, code, ...args) has been deprecated."),Bt("10.7.0",`Please use highlight(code, options) instead.
70
- https://github.com/highlightjs/highlight.js/issues/2277`),mt=Z,Ge=ue),je===void 0&&(je=!0);const qt={code:Ge,language:mt};na("before:highlight",qt);const tl=qt.result?qt.result:Kl(qt.language,qt.code,je);return tl.code=qt.code,na("after:highlight",tl),tl}function Kl(Z,ue,je,Ge){const mt=Object.create(null);function qt(J,ae){return J.keywords[ae]}function tl(){if(!de.keywords){St.addText(Ye);return}let J=0;de.keywordPatternRe.lastIndex=0;let ae=de.keywordPatternRe.exec(Ye),Ee="";for(;ae;){Ee+=Ye.substring(J,ae.index);const ze=zt.case_insensitive?ae[0].toLowerCase():ae[0],ot=qt(de,ze);if(ot){const[dl,vi]=ot;if(St.addText(Ee),Ee="",mt[ze]=(mt[ze]||0)+1,mt[ze]<=Tl&&(Tn+=vi),dl.startsWith("_"))Ee+=ae[0];else{const Eu=zt.classNameAliases[dl]||dl;ll(ae[0],Eu)}}else Ee+=ae[0];J=de.keywordPatternRe.lastIndex,ae=de.keywordPatternRe.exec(Ye)}Ee+=Ye.substring(J),St.addText(Ee)}function Zt(){if(Ye==="")return;let J=null;if(typeof de.subLanguage=="string"){if(!M[de.subLanguage]){St.addText(Ye);return}J=Kl(de.subLanguage,Ye,!0,_u[de.subLanguage]),_u[de.subLanguage]=J._top}else J=Oa(Ye,de.subLanguage.length?de.subLanguage:null);de.relevance>0&&(Tn+=J.relevance),St.__addSublanguage(J._emitter,J.language)}function tt(){de.subLanguage!=null?Zt():tl(),Ye=""}function ll(J,ae){J!==""&&(St.startScope(ae),St.addText(J),St.endScope())}function xu(J,ae){let Ee=1;const ze=ae.length-1;for(;Ee<=ze;){if(!J._emit[Ee]){Ee++;continue}const ot=zt.classNameAliases[J[Ee]]||J[Ee],dl=ae[Ee];ot?ll(dl,ot):(Ye=dl,tl(),Ye=""),Ee++}}function Ma(J,ae){return J.scope&&typeof J.scope=="string"&&St.openNode(zt.classNameAliases[J.scope]||J.scope),J.beginScope&&(J.beginScope._wrap?(ll(Ye,zt.classNameAliases[J.beginScope._wrap]||J.beginScope._wrap),Ye=""):J.beginScope._multi&&(xu(J.beginScope,ae),Ye="")),de=Object.create(J,{parent:{value:de}}),de}function mi(J,ae,Ee){let ze=be(J.endRe,Ee);if(ze){if(J["on:end"]){const ot=new a(J);J["on:end"](ae,ot),ot.isMatchIgnored&&(ze=!1)}if(ze){for(;J.endsParent&&J.parent;)J=J.parent;return J}}if(J.endsWithParent)return mi(J.parent,ae,Ee)}function za(J){return de.matcher.regexIndex===0?(Ye+=J[0],1):(jn=!0,0)}function Vs(J){const ae=J[0],Ee=J.rule,ze=new a(Ee),ot=[Ee.__beforeBegin,Ee["on:begin"]];for(const dl of ot)if(dl&&(dl(J,ze),ze.isMatchIgnored))return za(ae);return Ee.skip?Ye+=ae:(Ee.excludeBegin&&(Ye+=ae),tt(),!Ee.returnBegin&&!Ee.excludeBegin&&(Ye=ae)),Ma(Ee,J),Ee.returnBegin?0:ae.length}function Vt(J){const ae=J[0],Ee=ue.substring(J.index),ze=mi(de,J,Ee);if(!ze)return el;const ot=de;de.endScope&&de.endScope._wrap?(tt(),ll(ae,de.endScope._wrap)):de.endScope&&de.endScope._multi?(tt(),xu(de.endScope,J)):ot.skip?Ye+=ae:(ot.returnEnd||ot.excludeEnd||(Ye+=ae),tt(),ot.excludeEnd&&(Ye=ae));do de.scope&&St.closeNode(),!de.skip&&!de.subLanguage&&(Tn+=de.relevance),de=de.parent;while(de!==ze.parent);return ze.starts&&Ma(ze.starts,J),ot.returnEnd?0:ae.length}function yi(){const J=[];for(let ae=de;ae!==zt;ae=ae.parent)ae.scope&&J.unshift(ae.scope);J.forEach(ae=>St.openNode(ae))}let aa={};function Ra(J,ae){const Ee=ae&&ae[0];if(Ye+=J,Ee==null)return tt(),0;if(aa.type==="begin"&&ae.type==="end"&&aa.index===ae.index&&Ee===""){if(Ye+=ue.slice(ae.index,ae.index+1),!Ke){const ze=new Error(`0 width match regex (${Z})`);throw ze.languageName=Z,ze.badRule=aa.rule,ze}return 1}if(aa=ae,ae.type==="begin")return Vs(ae);if(ae.type==="illegal"&&!je){const ze=new Error('Illegal lexeme "'+Ee+'" for mode "'+(de.scope||"<unnamed>")+'"');throw ze.mode=de,ze}else if(ae.type==="end"){const ze=Vt(ae);if(ze!==el)return ze}if(ae.type==="illegal"&&Ee==="")return Ye+=`
71
- `,1;if(bi>1e5&&bi>ae.index*3)throw new Error("potential infinite loop, way more iterations than matches");return Ye+=Ee,Ee.length}const zt=Gt(Z);if(!zt)throw st(Ie.replace("{}",Z)),new Error('Unknown language: "'+Z+'"');const Su=Zl(zt);let Ca="",de=Ge||Su;const _u={},St=new te.__emitter(te);yi();let Ye="",Tn=0,Fl=0,bi=0,jn=!1;try{if(zt.__emitTokens)zt.__emitTokens(ue,St);else{for(de.matcher.considerAll();;){bi++,jn?jn=!1:de.matcher.considerAll(),de.matcher.lastIndex=Fl;const J=de.matcher.exec(ue);if(!J)break;const ae=ue.substring(Fl,J.index),Ee=Ra(ae,J);Fl=J.index+Ee}Ra(ue.substring(Fl))}return St.finalize(),Ca=St.toHTML(),{language:Z,value:Ca,relevance:Tn,illegal:!1,_emitter:St,_top:de}}catch(J){if(J.message&&J.message.includes("Illegal"))return{language:Z,value:ta(ue),illegal:!0,relevance:0,_illegalBy:{message:J.message,index:Fl,context:ue.slice(Fl-100,Fl+100),mode:J.mode,resultSoFar:Ca},_emitter:St};if(Ke)return{language:Z,value:ta(ue),illegal:!1,relevance:0,errorRaised:J,_emitter:St,_top:de};throw J}}function ja(Z){const ue={value:ta(Z),illegal:!1,relevance:0,_top:ne,_emitter:new te.__emitter(te)};return ue._emitter.addText(Z),ue}function Oa(Z,ue){ue=ue||te.languages||Object.keys(M);const je=ja(Z),Ge=ue.filter(Gt).filter(En).map(tt=>Kl(tt,Z,!1));Ge.unshift(je);const mt=Ge.sort((tt,ll)=>{if(tt.relevance!==ll.relevance)return ll.relevance-tt.relevance;if(tt.language&&ll.language){if(Gt(tt.language).supersetOf===ll.language)return 1;if(Gt(ll.language).supersetOf===tt.language)return-1}return 0}),[qt,tl]=mt,Zt=qt;return Zt.secondBest=tl,Zt}function wl(Z,ue,je){const Ge=ue&&Y[ue]||je;Z.classList.add("hljs"),Z.classList.add(`language-${Ge}`)}function gt(Z){let ue=null;const je=pt(Z);if(pe(je))return;if(na("before:highlightElement",{el:Z,language:je}),Z.dataset.highlighted){console.log("Element previously highlighted. To highlight again, first unset `dataset.highlighted`.",Z);return}if(Z.children.length>0&&(te.ignoreUnescapedHTML||(console.warn("One of your code blocks includes unescaped HTML. This is a potentially serious security risk."),console.warn("https://github.com/highlightjs/highlight.js/wiki/security"),console.warn("The element with unescaped HTML:"),console.warn(Z)),te.throwUnescapedHTML))throw new hi("One of your code blocks includes unescaped HTML.",Z.innerHTML);ue=Z;const Ge=ue.textContent,mt=je?rt(Ge,{language:je,ignoreIllegals:!0}):Oa(Ge);Z.innerHTML=mt.value,Z.dataset.highlighted="yes",wl(Z,je,mt.language),Z.result={language:mt.language,re:mt.relevance,relevance:mt.relevance},mt.secondBest&&(Z.secondBest={language:mt.secondBest.language,relevance:mt.secondBest.relevance}),na("after:highlightElement",{el:Z,result:mt,text:Ge})}function Ut(Z){te=di(te,Z)}const _n=()=>{Na(),Bt("10.6.0","initHighlighting() deprecated. Use highlightAll() now.")};function pi(){Na(),Bt("10.6.0","initHighlightingOnLoad() deprecated. Use highlightAll() now.")}let yu=!1;function Na(){function Z(){Na()}if(document.readyState==="loading"){yu||window.addEventListener("DOMContentLoaded",Z,!1),yu=!0;return}document.querySelectorAll(te.cssSelector).forEach(gt)}function bu(Z,ue){let je=null;try{je=ue(v)}catch(Ge){if(st("Language definition for '{}' could not be registered.".replace("{}",Z)),Ke)st(Ge);else throw Ge;je=ne}je.name||(je.name=Z),M[Z]=je,je.rawDefinition=ue.bind(null,v),je.aliases&&Jl(je.aliases,{languageName:Z})}function la(Z){delete M[Z];for(const ue of Object.keys(Y))Y[ue]===Z&&delete Y[ue]}function gi(){return Object.keys(M)}function Gt(Z){return Z=(Z||"").toLowerCase(),M[Z]||M[Y[Z]]}function Jl(Z,{languageName:ue}){typeof Z=="string"&&(Z=[Z]),Z.forEach(je=>{Y[je.toLowerCase()]=ue})}function En(Z){const ue=Gt(Z);return ue&&!ue.disableAutodetect}function An(Z){Z["before:highlightBlock"]&&!Z["before:highlightElement"]&&(Z["before:highlightElement"]=ue=>{Z["before:highlightBlock"](Object.assign({block:ue.el},ue))}),Z["after:highlightBlock"]&&!Z["after:highlightElement"]&&(Z["after:highlightElement"]=ue=>{Z["after:highlightBlock"](Object.assign({block:ue.el},ue))})}function xt(Z){An(Z),he.push(Z)}function vu(Z){const ue=he.indexOf(Z);ue!==-1&&he.splice(ue,1)}function na(Z,ue){const je=Z;he.forEach(function(Ge){Ge[je]&&Ge[je](ue)})}function $l(Z){return Bt("10.7.0","highlightBlock will be removed entirely in v12.0"),Bt("10.7.0","Please use highlightElement now."),gt(Z)}Object.assign(v,{highlight:rt,highlightAuto:Oa,highlightAll:Na,highlightElement:gt,highlightBlock:$l,configure:Ut,initHighlighting:_n,initHighlightingOnLoad:pi,registerLanguage:bu,unregisterLanguage:la,listLanguages:gi,getLanguage:Gt,registerAliases:Jl,autoDetection:En,inherit:di,addPlugin:xt,removePlugin:vu}),v.debugMode=function(){Ke=!1},v.safeMode=function(){Ke=!0},v.versionString=Mt,v.regex={concat:$,lookahead:z,either:K,optional:Q,anyNumberOfTimes:q};for(const Z in Lt)typeof Lt[Z]=="object"&&i(Lt[Z]);return Object.assign(v,Lt),v},V=Vl({});return V.newInstance=()=>Vl({}),to=V,V.HighlightJS=V,V.default=V,to}var lb=tb();const Zs=jy(lb);function nb(i){const a={className:"attr",begin:/"(\\.|[^\\"\r\n])*"(?=\s*:)/,relevance:1.01},u={match:/[{}[\],:]/,className:"punctuation",relevance:0},s=["true","false","null"],c={scope:"literal",beginKeywords:s.join(" ")};return{name:"JSON",aliases:["jsonc"],keywords:{literal:s},contains:[a,u,i.QUOTE_STRING_MODE,c,i.C_NUMBER_MODE,i.C_LINE_COMMENT_MODE,i.C_BLOCK_COMMENT_MODE],illegal:"\\S"}}function ab(i){const a=i.regex,u=a.concat(/[\p{L}_]/u,a.optional(/[\p{L}0-9_.-]*:/u),/[\p{L}0-9_.-]*/u),s=/[\p{L}0-9._:-]+/u,c={className:"symbol",begin:/&[a-z]+;|&#[0-9]+;|&#x[a-f0-9]+;/},f={begin:/\s/,contains:[{className:"keyword",begin:/#?[a-z_][a-z1-9_-]+/,illegal:/\n/}]},d=i.inherit(f,{begin:/\(/,end:/\)/}),p=i.inherit(i.APOS_STRING_MODE,{className:"string"}),g=i.inherit(i.QUOTE_STRING_MODE,{className:"string"}),y={endsWithParent:!0,illegal:/</,relevance:0,contains:[{className:"attr",begin:s,relevance:0},{begin:/=\s*/,relevance:0,contains:[{className:"string",endsParent:!0,variants:[{begin:/"/,end:/"/,contains:[c]},{begin:/'/,end:/'/,contains:[c]},{begin:/[^\s"'=<>`]+/}]}]}]};return{name:"HTML, XML",aliases:["html","xhtml","rss","atom","xjb","xsd","xsl","plist","wsf","svg"],case_insensitive:!0,unicodeRegex:!0,contains:[{className:"meta",begin:/<![a-z]/,end:/>/,relevance:10,contains:[f,g,p,d,{begin:/\[/,end:/\]/,contains:[{className:"meta",begin:/<![a-z]/,end:/>/,contains:[f,d,g,p]}]}]},i.COMMENT(/<!--/,/-->/,{relevance:10}),{begin:/<!\[CDATA\[/,end:/\]\]>/,relevance:10},c,{className:"meta",end:/\?>/,variants:[{begin:/<\?xml/,relevance:10,contains:[g]},{begin:/<\?[a-z][a-z0-9]+/}]},{className:"tag",begin:/<style(?=\s|>)/,end:/>/,keywords:{name:"style"},contains:[y],starts:{end:/<\/style>/,returnEnd:!0,subLanguage:["css","xml"]}},{className:"tag",begin:/<script(?=\s|>)/,end:/>/,keywords:{name:"script"},contains:[y],starts:{end:/<\/script>/,returnEnd:!0,subLanguage:["javascript","handlebars","xml"]}},{className:"tag",begin:/<>|<\/>/},{className:"tag",begin:a.concat(/</,a.lookahead(a.concat(u,a.either(/\/>/,/>/,/\s/)))),end:/\/?>/,contains:[{className:"name",begin:u,relevance:0,starts:y}]},{className:"tag",begin:a.concat(/<\//,a.lookahead(a.concat(u,/>/))),contains:[{className:"name",begin:u,relevance:0},{begin:/>/,relevance:0,endsParent:!0}]}]}}function ib(i){return{name:"Plain text",aliases:["text","txt"],disableAutodetect:!0}}function ug(i){let a=lt(Mo(i).tokens);const u=s=>a.node.apply(s,{userFuncArgs:{},variables:{}});return u.filter=a,u.ast=a.node,u.trace=s=>{let c=[];return a.node.trace(s,{userFuncArgs:{},variables:{}},c),{node:null,output:s,next:c}},u}function ub(i){return lt(Mo(i).tokens).node}function fu(i){return i>="a"&&i<="z"||i>="A"&&i<="Z"||i==="_"}function hu(i){return i>="0"&&i<="9"}function Hl(i,a="",u=" ",s=`
72
- `){let c=u?" ":"";if(typeof i>"u")return i;if(i===null)return"null";if(i instanceof Array){let f="[",d=!0;for(let p of Object.values(i))f+=(d?"":",")+s+a+u+Hl(p,a+u,u,s),d=!1;return f+=s+a+"]",f}else if(typeof i=="object"){let f="{",d=!0;for(let p of Object.keys(i))f+=(d?"":",")+s+a+u+'"'+p+'":'+c+Hl(i[p],a+u,u,s),d=!1;return f+=s+a+"}",f}else{if(typeof i=="string")return'"'+sg(i)+'"';if(typeof i=="number")return""+i;if(typeof i=="boolean")return i?"true":"false"}}function sg(i){return i=i.replace(/\\/g,"\\\\"),i=i.replace(/"/g,'\\"'),i=i.replace(/\n/g,"\\n"),i=i.replace(/[\x00-\x1f]/g,a=>"\\u00"+a.charCodeAt(0).toString(16).padStart(2,"0")),i}function*ro(i,a){let u=i[Symbol.iterator](),s=a[Symbol.iterator](),c=u.next(),f=s.next();for(;!c.done&&!f.done;)yield[c.value,f.value],c=u.next(),f=s.next()}function El(i,a){let u=U(i),s=U(a);if(u!=s)return El.typeOrder.indexOf(u)-El.typeOrder.indexOf(s);if(u=="boolean"){if(i&&!a)return 1;if(!i&&a)return-1}else{if(u=="number")return i-a;if(u=="string"){if(i<a)return-1;if(a<i)return 1}else if(u=="array"){for(let c=0;c<i.length;c++){let f=i[c],d=a[c];if(typeof f>"u"&&typeof d<"u")return-1;if(typeof f<"u"&&typeof d>"u")return 1;if(typeof f>"u")return 0;let p=El(f,d);if(p!=0)return p}return 0}else if(u=="object"){let c=Object.keys(i).sort(),f=Object.keys(a).sort(),d=El(c,f);if(d)return d;for(let p of c)if(d=El(i[p],a[p]),d)return d}}return 0}El.typeOrder=["null","boolean","number","string","array","object"];function zp(i,a,u=!1){let s=ub(a),c=(f,d)=>s.apply(f,d);return u&&(c=(f,d)=>s.paths(f,d)),function*(f,d,p){let g=d.userFuncArgs;d.userFuncArgs=Object.create(g);for(let y=0;y<i.length;y++){let x=i[y],A=p[y];d.userFuncArgs[x+"/0"]=A}yield*c(f,d),d.userFuncArgs=g}}function Rl(i,a,u){let s=i+"/"+a.length;gn[s]=zp(a,u),gn[s].params=Array.prototype.map.call(a,c=>({label:c,mode:"defer"})),gn[s+"-paths"]=zp(a,u,!0)}function Mo(i,a=0,u){let s=[];function c(d){throw d}let f;e:for(f=a;f<i.length;f++){let d=f,p=i[f];if(p!=" ")if(p=='"'||p=="'"){let g=p,y="",x=!1,A,z=0;for(f++;f<i.length;f++)if(A)A--,z*=16,z+=Number.parseInt(i[f],16),A==0&&(y+=String.fromCharCode(z),z=0);else if(x){let q=i[f];if(q=='"'||q=="'")y+=q;else if(q=="n")y+=`
73
- `;else if(q=="t")y+=" ";else if(q=="r")y+="\r";else if(q=="b")y+="\b";else if(q=="f")y+="\f";else if(q=="/")y+="/";else if(q=="\\")y+="\\";else if(q=="u")A=4;else if(q=="("){let Q=Mo(i,f+1,0);s.push({type:"quote-interp",value:y,location:d}),y="",s=s.concat(Q.tokens),f=Q.i}else throw"invalid escape "+q;x=!1}else if(i[f]=="\\")x=!0;else if(i[f]==g){s.push({type:"quote",value:y,location:d});continue e}else x=!1,y+=i[f];c("unterminated string literal")}else if(hu(p)){let g="";for(;hu(i[f])||i[f]==".";)g+=i[f++];s.push({type:"number",value:Number.parseFloat(g),location:d}),f--}else if(p=="."){let g=i[f+1];if(fu(g)){f++;let y="";for(;fu(i[f])||hu(i[f]);)y+=i[f++];s.push({type:"identifier-index",value:y,location:d}),f--}else g=="["?(f++,s.push({type:"dot-square",location:d})):g=="."?(f++,s.push({type:"dot-dot",location:d})):s.push({type:"dot",location:d})}else if(p=="$"){i[f+1],f++;let g="";for(;fu(i[f])||hu(i[f]);)g+=i[f],f++;s.push({type:"variable",name:g,location:d}),f--}else if(p=="[")s.push({type:"left-square",location:d});else if(p=="]")s.push({type:"right-square",location:d});else if(p=="(")s.push({type:"left-paren",location:d}),u++;else if(p==")"){if(s.push({type:"right-paren",location:d}),u--,u<0)return{tokens:s,i:f}}else if(p=="{")s.push({type:"left-brace",location:d});else if(p=="}")s.push({type:"right-brace",location:d});else if(p==",")s.push({type:"comma",location:d});else if(p==";")s.push({type:"semicolon",location:d});else if(p=="@")s.push({type:"at",location:d});else if(p=="?")s.push({type:"question",location:d});else if(p=="|")i[f+1]=="="?(s.push({type:"pipe-equals",location:d}),f++):s.push({type:"pipe",location:d});else if(p=="+"||p=="*"||p=="-"||p=="/"||p=="%"||p=="<"||p==">")p=="/"&&i[f+1]=="/"&&(p="//",f++),i[f+1]=="="?(p=="<"||p==">"?s.push({type:"op",op:p+"=",location:d}):s.push({type:"op-equals",op:p,location:d}),f++):s.push({type:"op",op:p});else if(p=="="){if(i[f+1]!="=")throw"plain assignment = is not supported";f++,s.push({type:"op",op:"==",location:d})}else if(p=="!"){if(i[f+1]!="=")throw"unexpected ! at "+d;f++,s.push({type:"op",op:"!=",location:d})}else if(fu(p)){let g="";for(;fu(i[f])||hu(i[f])||i[f]=="_";)g+=i[f++];g=="as"||g=="reduce"||g=="foreach"||g=="import"||g=="include"||g=="def"||g=="if"||g=="then"||g=="else"||g=="end"||g=="elif"?s.push({type:g,location:d}):s.push({type:"identifier",value:g,location:d}),f--}else p==":"&&s.push({type:"colon",location:d})}return s.push({type:"<end-of-program>",location:f}),{tokens:s,i:f}}function _l(i){return i?i.location:"<end>"}function lt(i,a=0,u=[]){let s=a,c=i[s],f=[],d=[];for(;c&&u.indexOf(c.type)==-1;){if(c.type=="identifier-index")f.push(new co(c.value));else if(c.type=="number")f.push(new pu(c.value));else if(c.type=="quote")f.push(new ci(c.value));else if(c.type=="dot")f.push(new wp);else if(c.type=="dot-dot")f.push(new yb);else if(c.type=="identifier")if(c.value=="true"||c.value=="false")f.push(new Dp(c.value=="true"));else if(c.value=="null")f.push(new Dp(null));else{let p=c.value,g=[];if(i[s+1]&&i[s+1].type=="left-paren")for(s++;i[s].type!="right-paren";){let y=lt(i,s+1,["semicolon","right-paren"]);g.push(y.node),s=y.i}f.push(new Nb(p+"/"+g.length,g))}else if(c.type=="dot-square"){let p=sb(i,s);f.push(p.node),s=p.i}else if(c.type=="left-square"){let p=lt(i,s+1,["right-square","colon"]);if(f.length){let g=pn(f);if(f=[],i[p.i].type=="colon"){p.node.length===0&&(p.node=new pu(0));let y=lt(i,p.i+1,["right-square"]);y.node.length===0&&(y.node=new pu(-1)),f.push(new ob(g,p.node,y.node)),p=y}else p.node.length===0?f.push(new db(g)):f.push(new cb(g,p.node))}else f.push(new pb(p.node));s=p.i}else if(c.type=="left-paren"){let p=lt(i,s+1,["right-paren"]);f.push(p.node),s=p.i}else if(c.type=="left-brace"){let p=rb(i,s+1);f.push(p.node),s=p.i}else if(c.type=="at"){let p=i[++s];if(!p||p.type!="identifier")throw"expected identifier after @ at "+_l(p);let g=p.value;if(!gu[g])throw"not a valid format: "+g;let y;i[s+1]&&i[s+1].type=="quote-interp"&&({q:y,i:s}=Rp(i,s+1),s=s),f.push(new Mb(g,y))}else if(c.type=="comma")d.push(pn(f)),f=[];else if(c.type=="pipe"||c.type=="as"){d.length&&(d.push(pn(f)),f=[new kp(d)],d=[]);let p=pn(f);if(c.type=="as"){let x=i[s+1];p=new dg(p,x.name),s+=2}let g=lt(i,s+1,u),y=g.node;s=g.i,i[s]&&u.indexOf(i[s].type)!=-1&&s--,f=[new gb(p,y)]}else if(c.type=="question"){let p=f.pop();if(!p)throw"unexpected ? without preceding filter at "+_l(c);f.push(new zb(p))}else if(c.type=="op"){if(f.length==0&&c.op=="-"&&i[s+1].type=="number"){i[s+1].value=-i[s+1].value,c=i[++s];continue}let p=pn(f);c.op;let g=[p,c],y=lt(i,s+1,["op","comma","pipe","right-paren","right-brace","right-square","<end-of-program>"].concat(u));for(s=y.i,g.push(y.node);s<i.length&&i[s].type=="op";){g.push(i[s]);let x=lt(i,s+1,["op","comma","pipe","right-paren","right-brace","right-square","<end-of-program>"].concat(u));s=x.i,g.push(x.node)}f=[Cp(g)],i[s]&&s--}else if(c.type=="pipe-equals"){let p=pn(f),g=lt(i,s+1,["comma","pipe","right-paren","right-brace","right-square","<end-of-program>"].concat(u));s=g.i-1;let y=g.node;f=[new Bp(p,y)]}else if(c.type=="op-equals"){let p=pn(f),g=lt(i,s+1,["comma","pipe","right-paren","right-brace","right-square","<end-of-program>"].concat(u));s=g.i;let y=g.node;y=Cp([new wp,{type:"op",op:c.op},y]),f=[new Bp(p,y)]}else if(c.type=="reduce"){let p=lt(i,s+1,["as"]);s=p.i;let g=p.node;s++;let y=i[s].name;if(s++,i[s].type!="left-paren")throw"expected left-paren in reduce at "+_l(i[s]);p=lt(i,s+1,["semicolon"]),s=p.i;let x=p.node;p=lt(i,s+1,["right-paren"]),s=p.i;let A=p.node;f.push(new Rb(g,y,x,A))}else if(c.type=="quote-interp"){let p;({q:p,i:s}=Rp(i,s)),f.push(p)}else if(c.type=="variable")f.push(new pg(c.name));else if(c.type=="if"){let p=[],g=[],y=null;for(;i[s]&&(i[s].type=="if"||i[s].type=="elif");){let x=lt(i,s+1,["then"]);if(!i[x.i]||i[x.i].type!="then")throw"expected then at "+_l(i[x.i])+", from "+i[s].type+" at "+i[s].location;let A=lt(i,x.i+1,["else","elif","end"]);if(A.i==x.i+1)throw"expected expression after then at "+_l(i[x.i+1])+", not "+i[x.i+1].type;s=A.i,p.push(x.node),g.push(A.node)}if(i[s]&&i[s].type=="else"){let x=lt(i,s+1,["end"]);s=x.i,y=x.node}if(!i[s]||i[s].type!="end")throw"expected end at "+_l(i[s])+" from if at "+c.location;f.push(new Cb(p,g,y))}else{if(c.type=="<end-of-program>"&&u.length==0)break;throw"could not handle token "+c.type+" at "+_l(c)+(u.length>0?", expected "+u.join("/"):"")}c=i[++s]}return d.length?(d.push(pn(f)),{node:new kp(d),i:s}):{node:pn(f),i:s}}function pn(i){return i.length==1?i[0]:new zo(i)}function Rp(i,a){let u=i[a],s=[],c=[];s.push(u.value);let f=lt(i,a+1,["right-paren"]);for(a=f.i+1,c.push(f.node);i[a].type=="quote-interp";)s.push(i[a].value),f=lt(i,a+1,["right-paren"]),a=f.i+1,c.push(f.node);return s.push(i[a].value),{q:new hb(s,c),i:a}}function sb(i,a=0){let u=a;if(i[u],u++,i[u].type=="right-square")return{node:new fg,i:u};let s=lt(i,u,["right-square","colon"]);if(i[s.i].type=="colon"){let c=s;return c.length===0&&(c.node=new pu(0)),s=lt(i,s.i+1,["right-square"]),s.length===0&&(s.node=new pu(-1)),{node:new fb(c.node,s.node),i:s.i}}return{node:new og(s.node),i:s.i}}function rb(i,a=0){let u=a,s=[];for(;i[u].type!="right-brace";){if(i[u].type=="identifier"){let c=i[u++];if(i[u].type=="colon"){let f=lt(i,u+1,["comma","right-brace"]);u=f.i,s.push({key:new ci(c.value),value:f.node}),u--}else i[u].type=="comma"?s.push({key:new ci(c.value),value:new co(c.value)}):i[u].type=="right-brace"&&(s.push({key:new ci(c.value),value:new co(c.value)}),u--)}else if(i[u].type=="quote"){let c=i[u++];if(i[u].type=="colon"){let f=lt(i,u+1,["comma","right-brace"]);u=f.i,s.push({key:new ci(c.value),value:f.node}),u--}else throw"unexpected "+i[u].type+", expected colon at "+_l(i[u])}else if(i[u].type=="left-paren"){let c=lt(i,u+1,["right-paren"]);if(u=c.i+1,i[u].type=="colon"){let f=lt(i,u+1,["comma","right-brace"]);u=f.i,s.push({key:c.node,value:f.node}),u--}else throw"unexpected "+i[u].type+", expected colon at "+_l(i[u])}else if(i[u].type=="variable"){let c=i[u++];if(i[u].type=="colon"){let f=lt(i,u+1,["comma","right-brace"]);u=f.i,s.push({key:new pg(c.name),value:f.node}),u--}else throw"unexpected "+i[u].type+", expected colon at "+_l(i[u])}else throw"unexpected "+i[u].type+" at "+_l(i[u])+" in object at "+_l(i[a-1]);u++,i[u].type=="comma"&&u++}return{node:new mb(s),i:u}}function Cp(i){const a={"+":5,"-":5,"*":10,"/":10,"%":10,"//":2,"==":3,"!=":3,">":3,"<":3,">=":3,"<=":3};let u=[],s=[];for(let d of i)if(d.type=="op"){for(;s.length&&a[s[0].op]>=a[d.op];)u.push(s.shift());s.unshift(d)}else u.push(d);for(let d of s)u.push(d);let c={"+":Bs,"*":bb,"-":vb,"/":xb,"%":Sb,"//":Ob,"==":hg,"!=":jb,"<":_b,">":Eb,"<=":Ab,">=":Tb},f=[];for(let d of u)if(d.type=="op"){let p=f.pop(),g=f.pop();f.push(new c[d.op](g,p))}else f.push(d);return f[0]}function rg(i,a,u,s){let c=s[0];for(let f of c.apply(i,a)){let d=[];u.push({node:c,output:f,next:d,variables:JSON.parse(JSON.stringify(a.variables))}),s.length>1&&rg(f,a,d,s.slice(1))}}function cg(i,a,u,s){let c=[],f=this;for(;f.source;)f.filter&&c.unshift(f.filter),f=f.source;c.unshift(f),rg(i,a,u,c)}function U(i){if(i===null)return"null";if(typeof i=="number")return"number";if(typeof i=="string")return"string";if(typeof i=="boolean")return"boolean";if(i instanceof Array)return"array";if(typeof i=="object")return"object"}class it{trace(a,u,s){for(let c of this.apply(a,u))s.push({node:this,output:c,next:[]})}toString(){return"<"+this.constructor.name+">"}*apply(a,u){throw"apply not implemented for "+this.constructor.name}}class zo extends it{constructor(a){super(),this.length=a.length;let u=a.pop();u&&(this.filter=u,this.source=a.length==1?a[0]:new zo(a))}*apply(a,u){if(this.filter)for(let s of this.source.apply(a,u))yield*this.filter.apply(s,u)}*paths(a,u){if(!this.filter)return[];for(let s of this.source.paths(a,u))for(let c of this.filter.paths(a,u))yield s.concat(c)}trace=cg;toString(){return(this.source?this.source.toString():"")+(this.filter?this.filter.toString():"")}}class cb extends it{constructor(a,u){super(),this.lhs=a,this.index=u}*apply(a,u){for(let s of this.lhs.apply(a,u)){let c=U(s);for(let f of this.index.apply(a,u)){if(c=="array"&&U(f)!="number")throw"Cannot index array with "+U(f)+" "+JSON.stringify(f);if(c=="object"&&U(f)!="string")throw"Cannot index object with "+U(f)+" "+JSON.stringify(f);typeof f=="number"&&f<0&&U(s)=="array"?yield s[s.length+f]:yield typeof s[f]>"u"?null:s[f]}}}*paths(a,u){for(let s of this.lhs.paths(a,u))for(let c of this.index.apply(a,u))yield s.concat([c])}toString(){return this.lhs.toString()+"["+this.index.toString()+"]"}}class ob extends it{constructor(a,u,s){super(),this.lhs=a,this.from=u,this.to=s}*apply(a,u){for(let s of this.lhs.apply(a,u))for(let c of this.from.apply(a,u)){c<0&&(c+=s.length);for(let f of this.to.apply(a,u))f<0&&(f+=s.length),yield s.slice(c,f)}}*paths(a,u){for(let s of this.lhs.paths(a,u))for(let c of this.from.apply(a,u))for(let f of this.to.apply(a,u))yield s.concat([{start:c,end:f}])}toString(){return this.lhs.toString()+"["+this.from.toString()+":"+this.to.toString()+"]"}}class og extends it{constructor(a){super(),this.index=a}*apply(a,u){let s=U(a);for(let c of this.index.apply(a,u)){if(s=="array"&&U(c)!="number")throw"Cannot index array with "+U(c)+" "+JSON.stringify(c);if(s=="object"&&U(c)!="string")throw"Cannot index object with "+U(c)+" "+JSON.stringify(c);typeof c=="number"&&c<0&&U(a)=="array"?yield a[a.length+c]:yield typeof a[c]>"u"?null:a[c]}}*paths(a,u){for(let s of this.index.apply(a,u))yield[s]}}class co extends og{constructor(a){super(new ci(a))}toString(){return"."+this.index.value}}class fb extends it{constructor(a,u){super(),this.from=a,this.to=u}*apply(a,u){for(let s of this.from.apply(a,u)){s<0&&(s+=a.length);for(let c of this.to.apply(a,u))c<0&&(c+=a.length),yield a.slice(s,c)}}*paths(a,u){for(let s of this.from.apply(a,u))for(let c of this.to.apply(a,u))yield[{start:s,end:c}]}toString(){return".["+this.from.toString()+":"+this.to.toString()+"]"}}class wp extends it{constructor(){super()}*apply(a,u){yield a}*paths(a,u){yield[]}toString(){return"."}}class Ro extends it{constructor(a){super(),this.value=a}*apply(){yield this.value}*paths(a,u){yield this.value}toString(){return JSON.stringify(this.value)}}class ci extends Ro{constructor(a){super(a)}}class hb extends it{constructor(a,u){super(),this.strings=a,this.interpolations=u}*apply(a,u){yield*this.applyEscape(a,gu.text,u)}*applyEscape(a,u,s,c=0){let f=this.strings[c];if(!this.interpolations[c])return yield f;for(let p of this.interpolations[c].apply(a,s))for(let g of this.applyEscape(a,u,s,c+1))yield f+u(p)+g}toString(){let a="";for(let u=0;u<this.strings.length;u++)a+=this.strings[u].replace("\\","\\\\").replace('"','\\"'),this.interpolations[u]&&(a+="\\("+this.interpolations[u].toString()+")");return'"'+a+'"'}}class pu extends Ro{constructor(a){super(a)}toString(){return this.value.toString()}}class Dp extends Ro{constructor(a){super(a)}toString(){return this.value?"true":"false"}}class db extends it{constructor(a){super(),this.source=a,this.filter=new fg}*apply(a,u){for(let s of this.source.apply(a,u))yield*Object.values(s)}*paths(a,u){for(let[s,c]of this.zip(this.source.paths(a,u),this.source.apply(a,u)))if(U(c)=="array")for(let f=0;f<c.length;f++)yield s.concat([f]);else for(let f of Object.keys(c))yield s.concat([f])}*zip(a,u){let s=a[Symbol.iterator](),c=u[Symbol.iterator](),f=s.next(),d=c.next();for(;!f.done&&!d.done;)yield[f.value,d.value],f=s.next(),d=c.next()}toString(){return this.source.toString()+"[]"}trace=cg}class fg extends it{constructor(){super()}*apply(a,u){U(a)=="array"?yield*a:yield*Object.values(a)}*paths(a,u){if(U(a)=="array")for(let s=0;s<a.length;s++)yield[s];else for(let s of Object.keys(a))yield[s]}toString(){return".[]"}}class kp extends it{constructor(a){super(),this.branches=a}*apply(a,u){for(let s of this.branches)yield*s.apply(a,u)}*paths(a,u){for(let s of this.branches)yield*s.paths(a,u)}toString(){return this.branches.join(", ")}}class pb extends it{constructor(a){super(),this.body=a}*apply(a,u){yield Array.from(this.body.apply(a,u))}toString(){return"["+this.body+"]"}}class gb extends it{constructor(a,u){super(),this.lhs=a,this.rhs=u,this.isPipe=!0}toString(){return`${this.lhs} | ${this.rhs}`}*apply(a,u){for(let s of this.lhs.apply(a,u))for(let c of this.rhs.apply(s,u))yield c}*paths(a,u){for(let[s,c]of this.zip(this.lhs.paths(a,u),this.lhs.apply(a,u)))for(let f of this.rhs.paths(c,u))yield s.concat(f)}*zip(a,u){let s=a[Symbol.iterator](),c=u[Symbol.iterator](),f=s.next(),d=c.next();for(;!f.done&&!d.done;)yield[f.value,d.value],f=s.next(),d=c.next()}trace(a,u,s){for(let c of this.lhs.apply(a,u)){let f=[],d={};this.lhs instanceof dg&&(d.variableValue=u.variables[this.lhs.name]),s.push({node:this.lhs,output:c,next:f,variables:JSON.parse(JSON.stringify(u.variables)),...d}),this.rhs.trace(c,u,f)}}}class mb extends it{constructor(a){super(),this.fields=a}*apply(a,u){let s={},c=[];for(let{key:f,value:d}of this.fields)for(let p of f.apply(a,u)){c.push(p),s[p]=[];for(let g of d.apply(a,u))s[p].push(g)}yield*this.helper(c,s,0,{})}*helper(a,u,s,c){if(s>=a.length){yield Object.assign({},c);return}let f=a[s];for(let d of u[f])c[f]=d,yield*this.helper(a,u,s+1,c)}toString(){return"{"+this.fields.map(({key:a,value:u})=>a.toString()+": "+u.toString()).join(", ")+"}"}}class yb extends it{constructor(){super()}*apply(a,u){yield*this.recurse(a)}*recurse(a){yield a;let u=U(a);if(u=="array"||u=="object")for(let s of Object.values(a))yield*this.recurse(s)}*paths(a,u){yield*this.recursePaths(a,[])}*recursePaths(a,u){yield u;let s=U(a);if(s=="array")for(let c=0;c<a.length;c++)yield*this.recursePaths(a[c],u.concat([c]));else if(s=="object")for(let[c,f]of Object.entries(a))yield*this.recursePaths(f,u.concat([c]))}toString(){return".."}}class Gl extends it{constructor(a,u){super(),this.l=a,this.r=u}*apply(a,u){for(let s of this.r.apply(a,u))for(let c of this.l.apply(a,u))yield this.combine(c,s,U(c),U(s))}trace(a,u,s){for(let c of this.l.apply(a,u)){let f=[];s.push({node:this.l,output:c,next:f,subsidiary:"left"});for(let d of this.r.apply(a,u)){let p=[];f.push({node:this.r,output:d,next:p,subsidiary:"right"});let g=this.combine(c,d,U(c),U(d)),y=[];p.push({node:this,output:g,next:y})}}}}class Bs extends Gl{constructor(a,u){super(a,u)}combine(a,u,s,c){if(s=="number"&&c=="number")return a+u;if(a===null)return u;if(u===null)return a;if(s=="string"&&c=="string")return a+u;if(s=="array"&&c=="array")return a.concat(u);if(s=="object"&&c=="object")return Object.assign(Object.assign({},a),u);throw"type mismatch in +:"+s+" and "+c+" cannot be added"}toString(){return this.l+" + "+this.r}}class bb extends Gl{constructor(a,u){super(a,u)}combine(a,u,s,c){if(s=="number"&&c=="number")return a*u;if(s=="number"&&c=="string")return this.repeat(u,a);if(s=="string"&&c=="number")return this.repeat(a,u);if(s=="object"&&c=="object")return this.merge(Object.assign({},a),u);throw"type mismatch in *:"+s+" and "+c+" cannot be multiplied"}repeat(a,u){if(u==0)return null;let s=[];for(let c=0;c<u;c++)s.push(a);return s.join("")}merge(a,u){for(let s of Object.keys(u))a.hasOwnProperty(s)?U(a[s])!="object"||U(u[s])!="object"?a[s]=u[s]:this.merge(a[s],u[s]):a[s]=u[s];return a}toString(){return this.l+" * "+this.r}}class vb extends Gl{constructor(a,u){super(a,u)}combine(a,u,s,c){if(s=="number"&&c=="number")return a-u;if(a==null||u==null)throw"type mismatch in -";if(s=="array"&&c=="array")return a.filter(f=>u.indexOf(f)==-1);throw"type mismatch in -:"+s+" and "+c+" cannot be subtracted"}toString(){return this.l+" - "+this.r}}class xb extends Gl{constructor(a,u){super(a,u)}combine(a,u,s,c){if(s=="number"&&c=="number")return a/u;if(s=="string"&&c=="string")return a.split(u);throw"type mismatch in -:"+s+" and "+c+" cannot be divided"}toString(){return this.l+" / "+this.r}}class Sb extends Gl{constructor(a,u){super(a,u)}combine(a,u,s,c){if(s=="number"&&c=="number")return a%u;throw"type mismatch in -:"+s+" and "+c+" cannot be divided (remainder)"}toString(){return this.l+" % "+this.r}}class _b extends Gl{constructor(a,u){super(a,u)}combine(a,u,s,c){return El(a,u)<0}toString(){return this.l+" < "+this.r}}class Eb extends Gl{constructor(a,u){super(a,u)}combine(a,u,s,c){return El(a,u)>0}toString(){return this.l+" > "+this.r}}class Ab extends Gl{constructor(a,u){super(a,u)}combine(a,u,s,c){return El(a,u)<=0}toString(){return this.l+" <= "+this.r}}class Tb extends Gl{constructor(a,u){super(a,u)}combine(a,u,s,c){return El(a,u)>=0}toString(){return this.l+" >= "+this.r}}class hg extends Gl{constructor(a,u){super(a,u)}combine(a,u,s,c){if(s!=c)return!1;if(s=="number"||s=="string"||s=="boolean"||s=="null")return a==u;if(s=="array"){if(a.length!=u.length)return!1;for(let p=0;p<a.length;p++)if(!this.combine(a[p],u[p],U(a[p]),U(u[p])))return!1;return!0}let f=Object.keys(a),d=Object.keys(u);if(f.length!=d.length)return!1;for(let p of f)if(!u.hasOwnProperty(p)||!this.combine(a[p],u[p],U(a[p]),U(u[p])))return!1;return!0}toString(){return this.l+" == "+this.r}}class jb extends hg{constructor(a,u){super(a,u)}combine(a,u,s,c){return!super.combine(a,u,s,c)}toString(){return this.l+" != "+this.r}}class Ob extends it{constructor(a,u){super(),this.lhs=a,this.rhs=u}*apply(a,u){let s=!1;for(let c of this.lhs.apply(a,u))c!==null&&(s=!0),yield c;s||(yield*this.rhs.apply(a,u))}toString(){return this.l+" // "+this.r}}class Bp extends it{constructor(a,u){super(),this.l=a,this.r=u}*apply(a,u){a=JSON.parse(JSON.stringify(a));for(let s of this.l.paths(a,u)){let c=this.r.apply(this.get(a,s),u).next();c.done?a=this.update(a,s,null,!0):a=this.update(a,s,c.value)}yield a}get(a,u){let s=a;for(let c of u)s=s[c];return s}update(a,u,s,c=!1){let f=a,d=u.pop();for(let p of u)f=f[p];return typeof d>"u"?s:(f[d]=s,c&&delete f[d],a)}toString(){return this.l+" |= "+this.r}}class Nb extends it{constructor(a,u){super(),this.name=a,this.args=u}apply(a,u){let s,c=u.userFuncArgs[this.name];if(c?s=function(f,d,p){return c.apply(f,d)}:s||(s=gn[this.name]),!s)throw"no such function "+this.name;return s(a,u,this.args)}paths(a,u){let s=u.userFuncArgs[this.name];if(s)return s.paths(a,u);let c=gn[this.name+"-paths"];if(!c)throw"no paths for "+this.name;return c(a,u,this.args)}trace(a,u,s){if(this.args.length==1&&!u.userFuncArgs[this.name]&&this.ordinary){let c=gn[this.name];if(c.params&&c.params.length>0&&c.params[0].mode=="defer")return super.trace(a,u,s);for(let f of this.args[0].apply(a,u)){let d=[],p="arg1";c.params&&c.params.length>0&&c.params[0].label&&(p=c.params[0].label),s.push({node:this.args[0],output:f,next:d,subsidiary:p});for(let g of c(a,u,[new wb(f)])){let y=[];d.push({node:this,output:g,next:y})}}}else return super.trace(a,u,s)}get ordinary(){let a=gn[this.name];return a?!(a.params&&a.params.length>0&&a.params[0].mode=="defer"):!0}toString(){return this.args.length==0?this.name.replace(/\/.*$/,""):this.name.replace(/\/.*$/,"")+"("+this.args.join("; ")+")"}}class Mb extends it{constructor(a,u){super(),this.name=a,this.string=u}*apply(a,u){if(typeof this.string>"u")return yield gu[this.name](a);yield*this.string.applyEscape(a,gu[this.name],u)}toString(){return this.string?"@"+this.name+" "+this.string:"@"+this.name}}class zb extends it{constructor(a){super(),this.inner=a}*apply(a,u){try{for(let s of this.inner.apply(a,u))s!==null&&(yield s)}catch{}}*paths(a,u){try{for(let[s,c]of ro(this.inner.apply(a,u),this.inner.paths(a,u)))s!==null&&(yield c)}catch{}}toString(){return this.inner+"?"}}class dg extends it{constructor(a,u){super(),this.value=a,this.name=u}*apply(a,u){for(let s of this.value.apply(a,u))u.variables[this.name]=s,yield a;delete u.variables[this.name]}toString(){return this.value+" as $"+this.name}}class pg extends it{constructor(a){super(),this.name=a}*apply(a,u){yield u.variables[this.name]}toString(){return"$"+this.name}}class Rb extends it{constructor(a,u,s,c){super(),this.generator=a,this.name=u,this.init=s,this.expr=c}*apply(a,u){for(let s of this.init.apply(a,u)){for(let c of this.generator.apply(a,u)){u.variables[this.name]=c;for(let f of this.expr.apply(s,u))s=f}delete u.variables[this.name],yield s}}toString(){return"reduce "+this.generator+" as $"+this.name+"("+this.init+"; "+this.expr+")"}}class Cb extends it{constructor(a,u,s){super(),this.conditions=a,this.thens=u,this.elseBranch=s}*apply(a,u){for(let[s,c]of ro(this.conditions,this.thens))for(let f of s.apply(a,u))if(f){for(let d of c.apply(a,u))yield d;return}if(this.elseBranch){yield*this.elseBranch.apply(a,u);return}yield a}toString(){let a="";for(let[u,s]of ro(this.conditions,this.thens))a+="if "+u+" then "+s+" el";return this.elseBranch?a+"se "+this.elseBranch+" end":a.slice(0,-2)+"end"}}class wb{constructor(a){this.value=a}*apply(a,u){yield this.value}toString(){return this.value.toString()}}const gu={text(i){return typeof i=="string"?i:Hl(i,"","","")},json(i){return Hl(i,"","","")},html(i){return typeof i!="string"&&(i=Hl(i,"","","")),i.replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/&/g,"&amp;").replace(/'/g,"&apos;").replace(/"/g,"&quot;")},uri(i){return typeof i!="string"&&(i=Hl(i,"","","")),encodeURIComponent(i)},urid(i){return typeof i!="string"&&(i=Hl(i,"","","")),decodeURIComponent(i)},csv(i){if(U(i)!="array")throw"cannot csv-format "+U(i)+", only array";return i.map(a=>{if(typeof a=="string")return'"'+a.replace(/"/g,'""')+'"';if(typeof a=="number")return""+a;if(a===null)return"";throw"type "+U(a)+" not valid in a csv row"}).join(",")},tsv(i){if(U(i)!="array")throw"cannot tsv-format "+U(i)+", only array";return i.map(a=>{if(typeof a=="string")return sg(a);if(typeof a=="number")return""+a;if(a===null)return"";throw"type "+U(a)+" not valid in a tsv row"}).join(" ")},base64(i){return typeof i!="string"&&(i=Hl(i,"","","")),btoa(i)},base64d(i){if(typeof i!="string")throw"can only base64-decode strings";return atob(i)},sh(i){let a=U(i);if(a=="string")return"'"+a.replace(/'/g,"'\\''")+"'";if(a=="number")return""+i;if(a=="boolean")return""+i;if(i===null)return"null";if(a==="array")return i.map(u=>{let s=U(u);if(s=="string")return"'"+u.replace(/'/g,"'\\''")+"'";if(s=="number")return""+u;if(s=="boolean")return""+u;if(u===null)return"null";throw s+" cannot be escaped for shell"}).join(" ");throw a+" cannot be escaped for shell"}},gn={"tostring/0":function*(i){yield gu.text(i)},"empty/0":function*(i){},"fromjson/0":function*(i){yield JSON.parse(i)},"path/1":Object.assign(function*(i,a,u){yield*u[0].paths(i,a)},{params:[{mode:"defer"}]}),"select/1":Object.assign(function*(i,a,u){let s=u[0];for(let c of s.apply(i,a))c!==!1&&c!==null&&(yield i)},{params:[{label:"predicate",mode:"eval"}]}),"select/1-paths":function*(i,a,u){let s=u[0];for(let c of s.apply(i,a))c!==!1&&c!==null&&(yield[])},"length/0":function*(i){let a=U(i);if(a=="string"||a=="array")return yield i.length;if(a=="null")return yield 0;if(a=="object")return yield Object.keys(i).length;throw"cannot compute length of "+a},"keys/0":function*(i){yield*Object.keys(i).sort()},"has/1":Object.assign(function*(i,a,u){let s=u[0];for(let c of s.apply(i,a))yield i.hasOwnProperty(c)},{params:[{label:"key"}]}),"has/1-paths":function*(i,a,u){let s=u[0];for(let c of s.apply(i,a))i.hasOwnProperty(c)&&(yield[])},"in/1":Object.assign(function*(i,a,u){let s=u[0];for(let c of s.apply(i,a))yield c.hasOwnProperty(i)},{params:[{label:"object"}]}),"in/1-paths":function*(i,a,u){let s=u[0];for(let c of s.apply(i,a))c.hasOwnProperty(i)&&(yield[])},"contains/1":Object.assign(function*(i,a,u){let s=u[0],c=U(i);for(let f of s.apply(i,a)){let d=U(f);if(c!=d)throw c+" and "+d+" cannot have their containment checked";yield Ls(i,f)}},{params:[{label:"element"}]}),"inside/1":Object.assign(function*(i,a,u){let s=u[0],c=U(i);for(let f of s.apply(i,a)){let d=U(f);if(c!=d)throw c+" and "+d+" cannot have their containment checked";yield Ls(f,i)}},{params:[{label:"container"}]}),"to_entries/0":function*(i,a){let u=U(i);if(u=="array"){let s=[];for(let c=0;c<i.length;c++)s.push({key:c,value:i[c]});yield s}else if(u=="object")yield Object.entries(i).map(s=>({key:s[0],value:s[1]}));else throw"cannot make entries from "+u},"from_entries/0":function*(i,a){let u=U(i);if(u=="array"){let s={};for(let{key:c,value:f}of i)s[c]=f;yield s}else throw"cannot use entries from "+u},"type/0":function*(i){yield U(i)},"range/1":Object.assign(function*(i,a,u){for(let s of u[0].apply(i,a))for(let c=0;c<s;c++)yield c},{params:[{mode:"defer"}]}),"range/2":function*(i,a,u){for(let s of u[0].apply(i,a))for(let c of u[1].apply(i,a))for(let f=s;f<c;f++)yield f},"range/3":function*(i,a,u){for(let s of u[0].apply(i,a))for(let c of u[1].apply(i,a))for(let f of u[2].apply(i,a))for(let d=s;d<c;d+=f)yield d},"any/0":function*(i,a){if(U(i)!="array")throw"any/0 requires array as input, not "+U(i);for(let u of i)if(u)return yield!0;yield!1},"any/1":Object.assign(function*(i,a,u){if(U(i)!="array")throw"any/1 requires array as input, not "+U(i);for(let s of i)for(let c of u[0].apply(s,a))if(c)return yield!0;yield!1},{params:[{mode:"defer"}]}),"any/2":function*(i,a,u){let s=u[0],c=u[1];for(let f of s.apply(i,a))for(let d of c.apply(f,a))if(d)return yield!0;yield!1},"all/0":function*(i,a){if(U(i)!="array")throw"all/0 requires array as input, not "+U(i);for(let u of i)if(!u)return yield!1;yield!0},"all/1":Object.assign(function*(i,a,u){if(U(i)!="array")throw"all/1 requires array as input, not "+U(i);for(let s of i)for(let c of u[0].apply(s,a))if(!c)return yield!1;yield!0},{params:[{mode:"defer"}]}),"all/2":function*(i,a,u){let s=u[0],c=u[1];for(let f of s.apply(i,a))for(let d of c.apply(f,a))if(!d)return yield!1;yield!0},"add/0":function*(i,a){if(U(i)!="array")throw"can only add up arrays";if(i.length==0)return yield null;if(i.length==1)return yield i[0];let u=Bs.prototype.combine(i[0],i[1],U(i[0]),U(i[1]));for(let s=2;s<i.length;s++)u=Bs.prototype.combine(u,i[s],U(u),U(i[s]));yield u},"add/1":Object.assign(function*(i,a,u){let s=null;for(let c of u[0].apply(i,a))s=Bs.prototype.combine(s,c,U(s),U(c));yield s},{params:[{label:"source"}]}),"tonumber/0":function*(i){yield Number.parseFloat(i)},"toboolean/0":function*(i){if(i==="false"||i===!1)yield!1;else if(i==="true"||i===!0)yield!0;else throw`cannot convert ${U(i)} (${Hl(i)}) to boolean`},"tojson/0":function*(i){yield JSON.stringify(i)},"fromjson/0":function*(i){yield JSON.parse(i)},"reverse/0":function*(i){if(U(i)!="array")throw"can only reverse arrays, not "+U(i);yield i.toReversed()},"sort/0":function*(i,a){if(U(i)!="array")throw"can only sort arrays, not "+U(i);yield Array.from(i).sort(El)},"sort_by/1":Object.assign(function*(i,a,u){if(U(i)!="array")throw"can only sort arrays, not "+U(i);let s=u[0],c=i.map(f=>({key:s.apply(f,a).next().value,value:f}));c.sort((f,d)=>El(f.key,d.key)),yield c.map(f=>f.value)},{params:[{mode:"defer"}]}),"explode/0":function*(i,a){if(U(i)!="string")throw"can only explode string, not "+U(i);let u=[];for(let s=0;s<i.length;s++){let c=i.charCodeAt(s);u.push(c),c>65535&&s++}yield u},"implode/0":function*(i,a){if(U(i)!="array")throw"can only implode array, not "+U(i);yield i.map(u=>String.fromCodePoint(u)).join("")},"split/1":Object.assign(function*(i,a,u){if(U(i)!="string")throw"can only split string, not "+U(i);for(let s of u[0].apply(i,a))yield i.split(s)},{params:[{label:"separator"}]}),"split/2":Object.assign(function*(i,a,u){if(U(i)!="string")throw"can only split string, not "+U(i);let s=u[1]?u[1].apply(i,a).next().value:"";s=ri(s);for(let c of u[0].apply(i,a)){let f=new RegExp(c,s);yield i.split(f)}},{params:[{label:"regex"},{label:"flags"}]}),"splits/1":Object.assign(function*(i,a,u){if(U(i)!="string")throw"can only split string, not "+U(i);for(let s of u[0].apply(i,a)){let c=new RegExp(s,"u");yield*i.split(c)}},{params:[{label:"regex"},{label:"flags"}]}),"splits/2":Object.assign(function*(i,a,u){if(U(i)!="string")throw"can only split string, not "+U(i);let s=u[1]?u[1].apply(i,a).next().value:"";s=ri(s);for(let c of u[0].apply(i,a)){let f=new RegExp(c,s);yield*i.split(f)}},{params:[{label:"regex"},{label:"flags"}]}),"join/1":Object.assign(function*(i,a,u){if(U(i)!="array")throw"can only join array, not "+U(i);let s=i.map(c=>{if(typeof c=="number")return""+c;if(typeof c=="string")return c;if(typeof c=="boolean")return""+c;if(c===null)return"";throw"cannot join "+U(c)});for(let c of u[0].apply(i,a))yield s.join(c)},{params:[{label:"delimiter"}]}),"getpath/1":Object.assign(function*(i,a,u){if(U(i)!="object"&&U(i)!="array")throw"can only get path from objects and arrays, not "+U(i);for(let s of u[0].apply(i,a)){let c=i;for(let f of s)if(c.hasOwnProperty(f))c=c[f];else{c=null;break}yield c}},{params:[{label:"paths"}]}),"setpath/2":Object.assign(function*(i,a,u){if(U(i)!="object"&&U(i)!="array"&&U(i)!="null")throw"can only set path on objects and arrays, not "+U(i);for(let s of u[0].apply(i,a)){let c=JSON.parse(JSON.stringify(i)),f=c;for(let d of s.slice(0,-1))c===null?U(d)=="number"?(c=[],f=c):(c={},f=c):f.hasOwnProperty(d)||(U(d)=="number"?f[d]=[]:f[d]={}),f=f[d];for(let d of u[1].apply(i,a)){let p=s[s.length-1];c===null?U(p)=="number"?(c=[],f=c):(c={},f=c):f.hasOwnProperty(p)||(U(p)=="number"?f=[]:f={}),f[p]=d}yield c}},{params:[{label:"paths"},{label:"value"}]}),"delpaths/1":Object.assign(function*(i,a,u){if(U(i)!="object"&&U(i)!="array")throw"can only delete paths from objects and arrays, not "+U(i);for(let s of u[0].apply(i,a)){let c=JSON.parse(JSON.stringify(i));for(let f of s){let d=c;for(let p of f.slice(0,-1))d.hasOwnProperty(p)||(d[p]={}),d=d[p];delete d[f[f.length-1]]}yield c}},{params:[{label:"paths"}]}),"ltrim/0":Object.assign(function*(i,a){if(U(i)!="string")throw"can only trim strings, not "+U(i);yield i.trimLeft()},{params:[]}),"rtrim/0":Object.assign(function*(i,a){if(U(i)!="string")throw"can only trim strings, not "+U(i);yield i.trimRight()},{params:[]}),"trim/0":Object.assign(function*(i,a){if(U(i)!="string")throw"can only trim strings, not "+U(i);yield i.trim()},{params:[]}),"trimstr/1":Object.assign(function*(i,a,u){if(U(i)!="string")throw"can only trim strings, not "+U(i);for(let s of u[0].apply(i,a)){let c=i;c.startsWith(s)&&(c=c.slice(s.length)),c.endsWith(s)&&(c=c.slice(0,-s.length)),yield c}},{params:[{label:"str"}]}),"ltrimstr/1":Object.assign(function*(i,a,u){if(U(i)!="string")throw"can only trim strings, not "+U(i);for(let s of u[0].apply(i,a)){let c=i;c.startsWith(s)&&(c=c.slice(s.length)),yield c}},{params:[{label:"str"}]}),"rtrimstr/1":Object.assign(function*(i,a,u){if(U(i)!="string")throw"can only trim strings, not "+U(i);for(let s of u[0].apply(i,a)){let c=i;c.endsWith(s)&&(c=c.slice(0,-s.length)),yield c}},{params:[{label:"str"}]}),"first/0":function*(i,a){if(U(i)!="array")throw"can only get first element of arrays, not "+U(i);if(i.length==0)return yield null;yield i[0]},"last/0":Object.assign(function*(i,a){if(U(i)!="array")throw"can only get last element of arrays, not "+U(i);if(i.length==0)return yield null;yield i[i.length-1]},{params:[]}),"nth/1":Object.assign(function*(i,a,u){if(U(i)!="array")throw"can only get nth element of arrays, not "+U(i);if(i.length==0)return yield null;for(let s of u[0].apply(i,a)){if(U(s)!="number")throw"nth index must be a number, not "+U(s);if(s<0)throw"negative indices not supported for nth";yield i[s]}},{params:[{label:"index"}]}),"first/1":Object.assign(function*(i,a,u){for(let s of u[0].apply(i,a))return yield s},{params:[{label:"generator"}]}),"last/1":Object.assign(function*(i,a,u){let s=null;for(let c of u[0].apply(i,a))s=c;yield s},{params:[{label:"generator"}]}),"limit/2":Object.assign(function*(i,a,u){for(let s of u[0].apply(i,a)){let c=0;for(let f of u[1].apply(i,a)){if(c>=s)break;yield f,c++}}},{params:[{label:"n"},{label:"expr"}]}),"skip/2":Object.assign(function*(i,a,u){for(let s of u[0].apply(i,a)){let c=0;for(let f of u[1].apply(i,a))c>=s&&(yield f),c++}},{params:[{label:"n"},{label:"expr"}]}),"walk/1":Object.assign(function*(i,a,u){yield*oo(i,a,u[0])},{params:[{label:"generator"}]}),"ascii_upcase/0":function*(i,a){if(U(i)!="string")throw"can only convert strings to uppercase, not "+U(i);yield i.replace(/./g,u=>u.charCodeAt(0)>=97&&u.charCodeAt(0)<=122?u.toUpperCase():u)},"ascii_downcase/0":function*(i,a){if(U(i)!="string")throw"can only convert strings to lowercase, not "+U(i);yield i.replace(/./g,u=>u.charCodeAt(0)>=65&&u.charCodeAt(0)<=90?u.toLowerCase():u)},"sub/2":Object.assign(function*(i,a,u){yield*Ds(i,a,u[0],u[1])},{params:[{label:"regex"},{label:"tostring"}]}),"sub/3":Object.assign(function*(i,a,u){let s=u[2].apply(i,a).next().value||"";yield*Ds(i,a,u[0],u[1],s)},{params:[{label:"regex"},{label:"tostring"},{label:"flags"}]}),"gsub/2":Object.assign(function*(i,a,u){return yield*Ds(i,a,u[0],u[1],"g")},{params:[{label:"regex"},{label:"tostring"}]}),"gsub/3":Object.assign(function*(i,a,u){let s=u[2].apply(i,a).next().value||"g";yield*Ds(i,a,u[0],u[1],s)},{params:[{label:"regex"},{label:"tostring"},{label:"flags"}]}),"test/1":Object.assign(function*(i,a,u){for(let s of u[0].apply(i,a))yield new RegExp(s,"u").test(i)},{params:[{label:"regex"}]}),"test/2":Object.assign(function*(i,a,u){let s=u[0].apply(i,a).next().value||"";for(let c of u[0].apply(i,a))yield new RegExp(c,ri(s)).test(i)},{params:[{label:"regex"},{label:"flags"}]}),"capture/1":Object.assign(function*(i,a,u){for(let s of u[0].apply(i,a)){let f=new RegExp(s,"u").exec(i);f&&(yield f.groups)}},{params:[{label:"regex"}]}),"capture/2":Object.assign(function*(i,a,u){let s=u[1].apply(i,a).next().value||"";s=ri(s);for(let c of u[0].apply(i,a)){let d=new RegExp(c,s).exec(i);d&&(yield d.groups)}},{params:[{label:"regex"},{label:"flags"}]}),"match/1":Object.assign(function*(i,a,u){let s="u";u[1]&&(s=ri(u[1].apply(i,a).next().value||"")),s+="d";let c=s.indexOf("g")>=0,f=0;for(let d of u[0].apply(i,a)){let p=new RegExp(d,s),g=p.exec(i);for(;g;){let y={offset:g.index,length:g[0].length,string:g[0],captures:[]};for(let x=1;x<g.length;x++){if(!g.indices[x])continue;let A=null;if(g.indices.groups){for(let[z,q]of Object.entries(g.indices.groups))if(g.indices[x][0]==q[0]&&g.indices[x][1]==q[1]){A=z;break}}y.captures.push({offset:g.indices[x][0],length:g[x].length,string:g[x],name:A})}if(yield y,g=p.exec(i),f++>1e3||!c)break}}},{params:[{label:"regex"}]})};gn["match/2"]=gn["match/1"];function*Ds(i,a,u,s,c=""){c=ri(c);for(let f of u.apply(i,a)){let d=new RegExp(f,c),p,g=0,y=[];for(;(p=d.exec(i))&&(y.push(i.slice(g,p.index)),y.push(p.groups),g=p.index+p[0].length,!(c.indexOf("g")<0)););if(y.length==0)return yield i;let x=i.slice(g),A=[];for(let q=0;q<y.length;q+=2){let Q=y[q],$=y[q+1],X=[];A.push(X);for(let K of s.apply($,a))X.push(Q+K)}let z=0;for(;;){let q="",Q=!1;for(let $=0;$<A.length;$++)typeof A[$][z]<"u"&&(Q=!0),q+=A[$][z]??"";if(!Q||(q+=x,yield q,z++,z>1e3))break}}}function ri(i){let a=["u"];if(i===null)return"u";for(let u of i)if(u=="g"||u=="i"||u=="m"||u=="s")a.push(u);else if(u=="p")a.push("s","m");else throw u=="x"||u=="l"||u=="n"?`jqjs does not have support for regex flag '${u}'`:`Invalid flag '${u}' in regex substitution`;return a.join("")}function*oo(i,a,u){if(U(i)=="array"){let s=[];for(let c of i)s.push(...oo(c,a,u));return yield*u.apply(s,a)}else if(U(i)=="object"){let s={};for(let c of Object.keys(i))for(let f of oo(i[c],a,u)){s[c]=f;break}return yield*u.apply(s,a)}yield*u.apply(i,a)}function Ls(i,a){let u=U(i),s=U(a);if(u!=s)return!1;if(u=="string")return i.indexOf(a)!=-1;if(u=="array"){for(let c of a){let f=!1;for(let d of i)if(Ls(d,c)){f=!0;break}if(!f)return!1}return!0}else if(u=="object"){for(let c of Object.keys(a))if(!i.hasOwnProperty(c)||!Ls(i[c],a[c]))return!1;return!0}else return i===a}Rl("map","f","[.[] | f]");Rl("map_values","f",".[] |= f");Rl("del","p","p |= empty");Rl("with_entries","w","to_entries | map(w) | from_entries");Rl("arrays","",'select(type == "array")');Rl("objects","",'select(type == "object")');Rl("booleans","",'select(type == "boolean")');Rl("strings","",'select(type == "string")');Rl("numbers","",'select(type == "number")');Rl("nulls","",'select(type == "null")');Rl("pick",["pathexps"],". as $in | reduce path(pathexps) as $a (null; setpath($a; $in|getpath($a)) )");function Db(i,a){let u=ug(i);return typeof a<"u"?u(a):u}const kb=Object.assign(Db,{compile:ug,prettyPrint:Hl});Zs.registerLanguage("json",nb);Zs.registerLanguage("xml",ab);Zs.registerLanguage("plaintext",ib);const Up=5*1024*1024;function Bb(i){return i?i.includes("json")?"json":i.includes("xml")||i.includes("html")?"xml":"plaintext":"plaintext"}function Ub({body:i,contentType:a,wrapEnabled:u,onToggleWrap:s}){const c=k.useRef(null),[f,d]=k.useState(!1),[p,g]=k.useState(""),y=k.useRef(null),x=k.useMemo(()=>Bb(a),[a]),A=x==="json",z=k.useMemo(()=>{if(!A||!i)return null;try{return JSON.parse(i)}catch{return null}},[i,A]),{displayBody:q,truncated:Q,filterError:$}=k.useMemo(()=>{let K=i||"",se=!1,be=null;if(K.length>Up&&(K=K.slice(0,Up),se=!0),A)try{const Se=JSON.parse(K);K=JSON.stringify(Se,null,2)}catch{}if(p.trim()&&z!==null)try{const oe=[...kb.compile(p.trim())(z)];oe.length===1?K=typeof oe[0]=="string"?oe[0]:JSON.stringify(oe[0],null,2):K=oe.map(ve=>typeof ve=="string"?JSON.stringify(ve):JSON.stringify(ve,null,2)).join(`
74
- `)}catch(Se){be=Se.message}return{displayBody:K,truncated:se,filterError:be}},[i,A,p,z]);k.useEffect(()=>{if(c.current&&q)try{const K=p.trim()&&!$?"json":x,se=Zs.highlight(q,{language:K});c.current.innerHTML=se.value}catch{c.current.textContent=q}},[q,x,p,$]);const X=k.useCallback(async()=>{const K=q||i||"";try{await navigator.clipboard.writeText(K),d(!0),setTimeout(()=>d(!1),1500)}catch{const se=document.createElement("textarea");se.value=K,document.body.appendChild(se),se.select(),document.execCommand("copy"),document.body.removeChild(se),d(!0),setTimeout(()=>d(!1),1500)}},[q,i]);return i?b.jsxs("div",{children:[b.jsxs("div",{className:"body-view__toolbar",children:[A&&b.jsxs("div",{className:"body-view__filter-group",children:[b.jsx("input",{ref:y,className:`body-view__filter${$?" body-view__filter--error":p.trim()?" body-view__filter--active":""}`,type:"text",placeholder:"jq filter, e.g. .data[0].name",value:p,onChange:K=>g(K.target.value),spellCheck:!1}),p&&b.jsx("button",{className:"body-view__filter-clear",onClick:()=>{g(""),y.current?.focus()},title:"Clear filter",children:"x"})]}),b.jsx("button",{className:`body-view__btn${u?" body-view__btn--active":""}`,onClick:s,children:"Wrap"}),b.jsx("button",{className:"body-view__btn",onClick:X,children:f?"Copied!":"Copy"})]}),$&&b.jsx("div",{className:"body-view__filter-error",children:$}),b.jsx("pre",{className:`body-view__pre ${u?"body-view__pre--wrap":"body-view__pre--nowrap"}`,children:b.jsx("code",{ref:c,children:q})}),Q&&b.jsx("div",{style:{color:"var(--method-put)",fontSize:"12px",marginTop:"8px"},children:"Response truncated at 5MB. Full response available in verbose view."})]}):b.jsx("div",{style:{color:"var(--fg-muted)"},children:"No response body"})}function qp({headers:i}){if(!i)return null;const a=Array.isArray(i)?i:Object.entries(i).map(([u,s])=>({name:u,value:s}));return a.length===0?null:b.jsxs("table",{className:"headers-view__table",children:[b.jsx("thead",{children:b.jsxs("tr",{children:[b.jsx("th",{children:"Header"}),b.jsx("th",{children:"Value"})]})}),b.jsx("tbody",{children:a.map((u,s)=>{const c=u.name||u[0]||"",f=u.value||u[1]||"";return b.jsxs("tr",{children:[b.jsx("td",{children:c}),b.jsx("td",{children:String(f)})]},`${c}-${s}`)})})]})}function qb({responseHeaders:i,requestHeaders:a}){const[u,s]=k.useState(!1);return b.jsxs("div",{children:[b.jsx(qp,{headers:i}),a&&b.jsxs("div",{children:[b.jsxs("div",{className:"headers-view__section-title",onClick:()=>s(c=>!c),children:[u?"▼":"▶"," Request Headers"]}),u&&b.jsx(qp,{headers:a})]}),!i&&!a&&b.jsx("div",{style:{color:"var(--fg-muted)"},children:"No headers available"})]})}function Hb(i){return i.startsWith("* ")?"verbose-view__line--comment":i.startsWith("> ")?"verbose-view__line--request":i.startsWith("< ")?"verbose-view__line--response":"verbose-view__line--other"}function Lb({verbose:i}){const a=k.useMemo(()=>i?i.split(`
75
- `):[],[i]);return i?b.jsx("div",{className:"verbose-view",children:a.map((u,s)=>b.jsx("div",{className:Hb(u),children:u||" "},s))}):b.jsx("div",{style:{color:"var(--fg-muted)"},children:"No verbose output available"})}function Gb({curlCommand:i}){const[a,u]=k.useState(!1),s=k.useCallback(async()=>{if(i)try{await navigator.clipboard.writeText(i),u(!0),setTimeout(()=>u(!1),1500)}catch{const c=document.createElement("textarea");c.value=i,document.body.appendChild(c),c.select(),document.execCommand("copy"),document.body.removeChild(c),u(!0),setTimeout(()=>u(!1),1500)}},[i]);return i?b.jsxs("div",{className:"curl-view",children:[b.jsx("button",{className:"copy-btn curl-view__copy-btn",onClick:s,children:a?"Copied!":"Copy"}),b.jsx("pre",{className:"curl-view__pre",children:b.jsx("code",{children:i})})]}):b.jsx("div",{style:{color:"var(--fg-muted)"},children:"No curl command available"})}function Yb({validation:i,expanded:a,onToggle:u}){if(!i)return b.jsx("span",{className:"validation-details",children:b.jsx("span",{className:"validation-details__indicator--none",children:"—"})});const{valid:s,errors:c}=i;return b.jsxs("div",{children:[b.jsx("span",{className:"validation-details",onClick:u,children:s?b.jsxs("span",{className:"validation-details__indicator--valid",children:["✓"," Valid"]}):b.jsxs("span",{className:"validation-details__indicator--invalid",children:["✗"," ",(c||[]).length," error(s)"]})}),a&&!s&&c&&c.length>0&&b.jsx("div",{className:"validation-details__errors",children:c.map((f,d)=>b.jsxs("div",{className:"validation-details__error",children:[f.path&&b.jsx("div",{className:"validation-details__error-path",children:f.path}),b.jsx("div",{className:"validation-details__error-msg",children:f.message||"Validation error"}),(f.expected||f.actual)&&b.jsxs("div",{className:"validation-details__error-detail",children:[f.expected&&b.jsxs(b.Fragment,{children:["Expected: ",String(f.expected)," "]}),f.actual&&b.jsxs(b.Fragment,{children:["Actual: ",String(f.actual)]})]})]},d))})]})}function Xb(i){if(!i)return"";const a=Number(i);return a>=200&&a<300?"response-panel__status--2xx":a>=300&&a<400?"response-panel__status--3xx":a>=400&&a<500?"response-panel__status--4xx":a>=500?"response-panel__status--5xx":""}function Qb(i){return i==null?"":i<1024?`${i} B`:i<1048576?`${(i/1024).toFixed(1)} KB`:`${(i/1048576).toFixed(2)} MB`}function Zb({response:i,sending:a}){const[u,s]=k.useState("body"),[c,f]=k.useState(!0),[d,p]=k.useState(null);if(a)return b.jsxs("div",{className:"response-panel__loading",children:[b.jsx("span",{className:"request-panel__spinner"}),b.jsx("span",{children:"Sending request..."})]});if(!i)return b.jsx("div",{className:"response-panel__empty",children:"Send a request to see the response"});if(i.error&&!i.status)return b.jsxs("div",{className:"response-panel__empty",style:{color:"var(--method-delete)"},children:["Error: ",i.error]});const g=["Body","Headers","Verbose","Curl"];return b.jsxs("div",{children:[b.jsxs("div",{className:"response-panel__header",children:[b.jsxs("span",{className:`response-panel__status ${Xb(i.status)}`,children:[i.status," ",i.status_text||i.statusText||""]}),i.timing?.total_ms!=null&&b.jsxs("span",{className:"response-panel__meta",children:[i.timing.total_ms," ms"]}),i.size_bytes!=null&&b.jsx("span",{className:"response-panel__meta",children:Qb(i.size_bytes)}),i.validation!==void 0&&b.jsx(Yb,{validation:i.validation,expanded:d??!i.validation?.valid,onToggle:()=>p(y=>y===null?i.validation?.valid:!y)})]}),b.jsx("div",{className:"response-panel__tabs",children:g.map(y=>b.jsx("button",{className:`response-panel__tab${u===y.toLowerCase()?" response-panel__tab--active":""}`,onClick:()=>s(y.toLowerCase()),children:y},y))}),u==="body"&&b.jsx(Ub,{body:i.body,contentType:i.contentType||i.content_type||i.headers?.["content-type"],wrapEnabled:c,onToggleWrap:()=>f(y=>!y)}),u==="headers"&&b.jsx(qb,{responseHeaders:i.headers,requestHeaders:i.requestHeaders||i.request_headers}),u==="verbose"&&b.jsx(Lb,{verbose:i.verbose}),u==="curl"&&b.jsx(Gb,{curlCommand:i.curl||i.curlCommand||i.curl_command})]})}function Vb({pairs:i,onChange:a}){const u=(f,d,p)=>{const g=i.map((y,x)=>x===f?{...y,[d]:p}:y);a(g)},s=()=>{a([...i,{key:"",value:""}])},c=f=>{const d=i.filter((p,g)=>g!==f);a(d.length>0?d:[{key:"",value:""}])};return b.jsxs("div",{children:[b.jsxs("table",{className:"body-editor__kv-table",children:[b.jsx("thead",{children:b.jsxs("tr",{children:[b.jsx("th",{children:"Variable"}),b.jsx("th",{children:"Value"}),b.jsx("th",{})]})}),b.jsx("tbody",{children:i.map((f,d)=>b.jsxs("tr",{children:[b.jsx("td",{children:b.jsx("input",{className:"body-editor__kv-input",type:"text",value:f.key||"",onChange:p=>u(d,"key",p.target.value),placeholder:"variable name"})}),b.jsx("td",{children:b.jsx("input",{className:"body-editor__kv-input",type:"text",value:f.value||"",onChange:p=>u(d,"value",p.target.value),placeholder:"value"})}),b.jsx("td",{children:b.jsx("button",{className:"body-editor__kv-remove",onClick:()=>c(d),title:"Remove",children:"x"})})]},d))})]}),b.jsx("button",{className:"body-editor__kv-add",onClick:s,children:"+ Add Variable"})]})}function Hp(i){return!i||Object.keys(i).length===0?[{key:"",value:""}]:Object.entries(i).map(([a,u])=>({key:a,value:String(u)}))}function Lp(i){const a={};for(const{key:u,value:s}of i)u&&(a[u]=s);return a}function Kb({environments:i,onSave:a,onClose:u}){const[s,c]=k.useState("base"),[f,d]=k.useState(""),[p,g]=k.useState({}),[y,x]=k.useState(!1);k.useEffect(()=>{if(!i)return;const X={};X.base=Hp(i.base),i.environments&&Object.entries(i.environments).forEach(([K,se])=>{X[K]=Hp(se)}),g(X)},[i]);const A=["base",...Object.keys(p).filter(X=>X!=="base").sort()],z=k.useCallback(()=>{const X=f.trim();!X||X==="base"||p[X]||(g(K=>({...K,[X]:[{key:"",value:""}]})),d(""),c(X))},[f,p]),q=k.useCallback(async X=>{if(X!=="base")try{await Ky(X),g(K=>{const se={...K};return delete se[X],se}),c("base"),a&&a()}catch{}},[a]),Q=k.useCallback(async()=>{x(!0);try{p.base&&await Qy(Lp(p.base));for(const[X,K]of Object.entries(p))X!=="base"&&await Zy(X,Lp(K));a&&a()}catch{}finally{x(!1)}},[p,a]),$=k.useCallback(X=>{X.key==="Escape"&&u()},[u]);return k.useEffect(()=>(document.addEventListener("keydown",$),()=>document.removeEventListener("keydown",$)),[$]),b.jsxs("div",{className:"env-editor",children:[b.jsx("div",{className:"env-editor__backdrop",onClick:u}),b.jsxs("div",{className:"env-editor__dialog",children:[b.jsxs("div",{className:"env-editor__header",children:[b.jsx("span",{className:"env-editor__title",children:"Environments"}),b.jsx("button",{className:"env-editor__close",onClick:u,children:"x"})]}),b.jsx("div",{className:"env-editor__tabs",children:A.map(X=>b.jsx("button",{className:`env-editor__tab${s===X?" env-editor__tab--active":""}`,onClick:()=>c(X),children:X==="base"?"Base":X},X))}),b.jsxs("div",{className:"env-editor__body",children:[b.jsxs("div",{className:"env-editor__new-env",children:[b.jsx("input",{className:"env-editor__new-env-input",type:"text",placeholder:"New environment name...",value:f,onChange:X=>d(X.target.value),onKeyDown:X=>{X.key==="Enter"&&z()}}),b.jsx("button",{className:"topbar__btn",onClick:z,children:"Add"})]}),p[s]&&b.jsx(Vb,{pairs:p[s],onChange:X=>g(K=>({...K,[s]:X}))})]}),b.jsxs("div",{className:"env-editor__footer",children:[s!=="base"&&b.jsxs("button",{className:"env-editor__delete-btn",onClick:()=>q(s),children:['Delete "',s,'"']}),b.jsx("button",{className:"env-editor__save-btn",onClick:Q,disabled:y,children:y?"Saving...":"Save"})]})]})]})}function mn(i){return Array.isArray?Array.isArray(i):yg(i)==="[object Array]"}function Jb(i){if(typeof i=="string")return i;let a=i+"";return a=="0"&&1/i==-1/0?"-0":a}function $b(i){return i==null?"":Jb(i)}function Ll(i){return typeof i=="string"}function gg(i){return typeof i=="number"}function Fb(i){return i===!0||i===!1||Wb(i)&&yg(i)=="[object Boolean]"}function mg(i){return typeof i=="object"}function Wb(i){return mg(i)&&i!==null}function ol(i){return i!=null}function lo(i){return!i.trim().length}function yg(i){return i==null?i===void 0?"[object Undefined]":"[object Null]":Object.prototype.toString.call(i)}const Ib="Incorrect 'index' type",Pb=i=>`Invalid value for key ${i}`,ev=i=>`Pattern length exceeds max of ${i}.`,tv=i=>`Missing ${i} property in key`,lv=i=>`Property 'weight' in key '${i}' must be a positive integer`,Gp=Object.prototype.hasOwnProperty;class nv{constructor(a){this._keys=[],this._keyMap={};let u=0;a.forEach(s=>{let c=bg(s);this._keys.push(c),this._keyMap[c.id]=c,u+=c.weight}),this._keys.forEach(s=>{s.weight/=u})}get(a){return this._keyMap[a]}keys(){return this._keys}toJSON(){return JSON.stringify(this._keys)}}function bg(i){let a=null,u=null,s=null,c=1,f=null;if(Ll(i)||mn(i))s=i,a=Yp(i),u=fo(i);else{if(!Gp.call(i,"name"))throw new Error(tv("name"));const d=i.name;if(s=d,Gp.call(i,"weight")&&(c=i.weight,c<=0))throw new Error(lv(d));a=Yp(d),u=fo(d),f=i.getFn}return{path:a,id:u,weight:c,src:s,getFn:f}}function Yp(i){return mn(i)?i:i.split(".")}function fo(i){return mn(i)?i.join("."):i}function av(i,a){let u=[],s=!1;const c=(f,d,p)=>{if(ol(f))if(!d[p])u.push(f);else{let g=d[p];const y=f[g];if(!ol(y))return;if(p===d.length-1&&(Ll(y)||gg(y)||Fb(y)))u.push($b(y));else if(mn(y)){s=!0;for(let x=0,A=y.length;x<A;x+=1)c(y[x],d,p+1)}else d.length&&c(y,d,p+1)}};return c(i,Ll(a)?a.split("."):a,0),s?u:u[0]}const iv={includeMatches:!1,findAllMatches:!1,minMatchCharLength:1},uv={isCaseSensitive:!1,ignoreDiacritics:!1,includeScore:!1,keys:[],shouldSort:!0,sortFn:(i,a)=>i.score===a.score?i.idx<a.idx?-1:1:i.score<a.score?-1:1},sv={location:0,threshold:.6,distance:100},rv={useExtendedSearch:!1,getFn:av,ignoreLocation:!1,ignoreFieldNorm:!1,fieldNormWeight:1};var ge={...uv,...iv,...sv,...rv};const cv=/[^ ]+/g;function ov(i=1,a=3){const u=new Map,s=Math.pow(10,a);return{get(c){const f=c.match(cv).length;if(u.has(f))return u.get(f);const d=1/Math.pow(f,.5*i),p=parseFloat(Math.round(d*s)/s);return u.set(f,p),p},clear(){u.clear()}}}class Co{constructor({getFn:a=ge.getFn,fieldNormWeight:u=ge.fieldNormWeight}={}){this.norm=ov(u,3),this.getFn=a,this.isCreated=!1,this.setIndexRecords()}setSources(a=[]){this.docs=a}setIndexRecords(a=[]){this.records=a}setKeys(a=[]){this.keys=a,this._keysMap={},a.forEach((u,s)=>{this._keysMap[u.id]=s})}create(){this.isCreated||!this.docs.length||(this.isCreated=!0,Ll(this.docs[0])?this.docs.forEach((a,u)=>{this._addString(a,u)}):this.docs.forEach((a,u)=>{this._addObject(a,u)}),this.norm.clear())}add(a){const u=this.size();Ll(a)?this._addString(a,u):this._addObject(a,u)}removeAt(a){this.records.splice(a,1);for(let u=a,s=this.size();u<s;u+=1)this.records[u].i-=1}getValueForItemAtKeyId(a,u){return a[this._keysMap[u]]}size(){return this.records.length}_addString(a,u){if(!ol(a)||lo(a))return;let s={v:a,i:u,n:this.norm.get(a)};this.records.push(s)}_addObject(a,u){let s={i:u,$:{}};this.keys.forEach((c,f)=>{let d=c.getFn?c.getFn(a):this.getFn(a,c.path);if(ol(d)){if(mn(d)){let p=[];const g=[{nestedArrIndex:-1,value:d}];for(;g.length;){const{nestedArrIndex:y,value:x}=g.pop();if(ol(x))if(Ll(x)&&!lo(x)){let A={v:x,i:y,n:this.norm.get(x)};p.push(A)}else mn(x)&&x.forEach((A,z)=>{g.push({nestedArrIndex:z,value:A})})}s.$[f]=p}else if(Ll(d)&&!lo(d)){let p={v:d,n:this.norm.get(d)};s.$[f]=p}}}),this.records.push(s)}toJSON(){return{keys:this.keys,records:this.records}}}function vg(i,a,{getFn:u=ge.getFn,fieldNormWeight:s=ge.fieldNormWeight}={}){const c=new Co({getFn:u,fieldNormWeight:s});return c.setKeys(i.map(bg)),c.setSources(a),c.create(),c}function fv(i,{getFn:a=ge.getFn,fieldNormWeight:u=ge.fieldNormWeight}={}){const{keys:s,records:c}=i,f=new Co({getFn:a,fieldNormWeight:u});return f.setKeys(s),f.setIndexRecords(c),f}function ks(i,{errors:a=0,currentLocation:u=0,expectedLocation:s=0,distance:c=ge.distance,ignoreLocation:f=ge.ignoreLocation}={}){const d=a/i.length;if(f)return d;const p=Math.abs(s-u);return c?d+p/c:p?1:d}function hv(i=[],a=ge.minMatchCharLength){let u=[],s=-1,c=-1,f=0;for(let d=i.length;f<d;f+=1){let p=i[f];p&&s===-1?s=f:!p&&s!==-1&&(c=f-1,c-s+1>=a&&u.push([s,c]),s=-1)}return i[f-1]&&f-s>=a&&u.push([s,f-1]),u}const _a=32;function dv(i,a,u,{location:s=ge.location,distance:c=ge.distance,threshold:f=ge.threshold,findAllMatches:d=ge.findAllMatches,minMatchCharLength:p=ge.minMatchCharLength,includeMatches:g=ge.includeMatches,ignoreLocation:y=ge.ignoreLocation}={}){if(a.length>_a)throw new Error(ev(_a));const x=a.length,A=i.length,z=Math.max(0,Math.min(s,A));let q=f,Q=z;const $=p>1||g,X=$?Array(A):[];let K;for(;(K=i.indexOf(a,Q))>-1;){let R=ks(a,{currentLocation:K,expectedLocation:z,distance:c,ignoreLocation:y});if(q=Math.min(R,q),Q=K+x,$){let w=0;for(;w<x;)X[K+w]=1,w+=1}}Q=-1;let se=[],be=1,Se=x+A;const oe=1<<x-1;for(let R=0;R<x;R+=1){let w=0,P=Se;for(;w<P;)ks(a,{errors:R,currentLocation:z+P,expectedLocation:z,distance:c,ignoreLocation:y})<=q?w=P:Se=P,P=Math.floor((Se-w)/2+w);Se=P;let Ve=Math.max(1,z-P+1),W=d?A:Math.min(z+P,A)+x,me=Array(W+2);me[W+1]=(1<<R)-1;for(let Me=W;Me>=Ve;Me-=1){let We=Me-1,D=u[i.charAt(We)];if($&&(X[We]=+!!D),me[Me]=(me[Me+1]<<1|1)&D,R&&(me[Me]|=(se[Me+1]|se[Me])<<1|1|se[Me+1]),me[Me]&oe&&(be=ks(a,{errors:R,currentLocation:We,expectedLocation:z,distance:c,ignoreLocation:y}),be<=q)){if(q=be,Q=We,Q<=z)break;Ve=Math.max(1,2*z-Q)}}if(ks(a,{errors:R+1,currentLocation:z,expectedLocation:z,distance:c,ignoreLocation:y})>q)break;se=me}const ve={isMatch:Q>=0,score:Math.max(.001,be)};if($){const R=hv(X,p);R.length?g&&(ve.indices=R):ve.isMatch=!1}return ve}function pv(i){let a={};for(let u=0,s=i.length;u<s;u+=1){const c=i.charAt(u);a[c]=(a[c]||0)|1<<s-u-1}return a}const Gs=String.prototype.normalize?(i=>i.normalize("NFD").replace(/[\u0300-\u036F\u0483-\u0489\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u0610-\u061A\u064B-\u065F\u0670\u06D6-\u06DC\u06DF-\u06E4\u06E7\u06E8\u06EA-\u06ED\u0711\u0730-\u074A\u07A6-\u07B0\u07EB-\u07F3\u07FD\u0816-\u0819\u081B-\u0823\u0825-\u0827\u0829-\u082D\u0859-\u085B\u08D3-\u08E1\u08E3-\u0903\u093A-\u093C\u093E-\u094F\u0951-\u0957\u0962\u0963\u0981-\u0983\u09BC\u09BE-\u09C4\u09C7\u09C8\u09CB-\u09CD\u09D7\u09E2\u09E3\u09FE\u0A01-\u0A03\u0A3C\u0A3E-\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A70\u0A71\u0A75\u0A81-\u0A83\u0ABC\u0ABE-\u0AC5\u0AC7-\u0AC9\u0ACB-\u0ACD\u0AE2\u0AE3\u0AFA-\u0AFF\u0B01-\u0B03\u0B3C\u0B3E-\u0B44\u0B47\u0B48\u0B4B-\u0B4D\u0B56\u0B57\u0B62\u0B63\u0B82\u0BBE-\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCD\u0BD7\u0C00-\u0C04\u0C3E-\u0C44\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C62\u0C63\u0C81-\u0C83\u0CBC\u0CBE-\u0CC4\u0CC6-\u0CC8\u0CCA-\u0CCD\u0CD5\u0CD6\u0CE2\u0CE3\u0D00-\u0D03\u0D3B\u0D3C\u0D3E-\u0D44\u0D46-\u0D48\u0D4A-\u0D4D\u0D57\u0D62\u0D63\u0D82\u0D83\u0DCA\u0DCF-\u0DD4\u0DD6\u0DD8-\u0DDF\u0DF2\u0DF3\u0E31\u0E34-\u0E3A\u0E47-\u0E4E\u0EB1\u0EB4-\u0EB9\u0EBB\u0EBC\u0EC8-\u0ECD\u0F18\u0F19\u0F35\u0F37\u0F39\u0F3E\u0F3F\u0F71-\u0F84\u0F86\u0F87\u0F8D-\u0F97\u0F99-\u0FBC\u0FC6\u102B-\u103E\u1056-\u1059\u105E-\u1060\u1062-\u1064\u1067-\u106D\u1071-\u1074\u1082-\u108D\u108F\u109A-\u109D\u135D-\u135F\u1712-\u1714\u1732-\u1734\u1752\u1753\u1772\u1773\u17B4-\u17D3\u17DD\u180B-\u180D\u1885\u1886\u18A9\u1920-\u192B\u1930-\u193B\u1A17-\u1A1B\u1A55-\u1A5E\u1A60-\u1A7C\u1A7F\u1AB0-\u1ABE\u1B00-\u1B04\u1B34-\u1B44\u1B6B-\u1B73\u1B80-\u1B82\u1BA1-\u1BAD\u1BE6-\u1BF3\u1C24-\u1C37\u1CD0-\u1CD2\u1CD4-\u1CE8\u1CED\u1CF2-\u1CF4\u1CF7-\u1CF9\u1DC0-\u1DF9\u1DFB-\u1DFF\u20D0-\u20F0\u2CEF-\u2CF1\u2D7F\u2DE0-\u2DFF\u302A-\u302F\u3099\u309A\uA66F-\uA672\uA674-\uA67D\uA69E\uA69F\uA6F0\uA6F1\uA802\uA806\uA80B\uA823-\uA827\uA880\uA881\uA8B4-\uA8C5\uA8E0-\uA8F1\uA8FF\uA926-\uA92D\uA947-\uA953\uA980-\uA983\uA9B3-\uA9C0\uA9E5\uAA29-\uAA36\uAA43\uAA4C\uAA4D\uAA7B-\uAA7D\uAAB0\uAAB2-\uAAB4\uAAB7\uAAB8\uAABE\uAABF\uAAC1\uAAEB-\uAAEF\uAAF5\uAAF6\uABE3-\uABEA\uABEC\uABED\uFB1E\uFE00-\uFE0F\uFE20-\uFE2F]/g,"")):(i=>i);class xg{constructor(a,{location:u=ge.location,threshold:s=ge.threshold,distance:c=ge.distance,includeMatches:f=ge.includeMatches,findAllMatches:d=ge.findAllMatches,minMatchCharLength:p=ge.minMatchCharLength,isCaseSensitive:g=ge.isCaseSensitive,ignoreDiacritics:y=ge.ignoreDiacritics,ignoreLocation:x=ge.ignoreLocation}={}){if(this.options={location:u,threshold:s,distance:c,includeMatches:f,findAllMatches:d,minMatchCharLength:p,isCaseSensitive:g,ignoreDiacritics:y,ignoreLocation:x},a=g?a:a.toLowerCase(),a=y?Gs(a):a,this.pattern=a,this.chunks=[],!this.pattern.length)return;const A=(q,Q)=>{this.chunks.push({pattern:q,alphabet:pv(q),startIndex:Q})},z=this.pattern.length;if(z>_a){let q=0;const Q=z%_a,$=z-Q;for(;q<$;)A(this.pattern.substr(q,_a),q),q+=_a;if(Q){const X=z-_a;A(this.pattern.substr(X),X)}}else A(this.pattern,0)}searchIn(a){const{isCaseSensitive:u,ignoreDiacritics:s,includeMatches:c}=this.options;if(a=u?a:a.toLowerCase(),a=s?Gs(a):a,this.pattern===a){let $={isMatch:!0,score:0};return c&&($.indices=[[0,a.length-1]]),$}const{location:f,distance:d,threshold:p,findAllMatches:g,minMatchCharLength:y,ignoreLocation:x}=this.options;let A=[],z=0,q=!1;this.chunks.forEach(({pattern:$,alphabet:X,startIndex:K})=>{const{isMatch:se,score:be,indices:Se}=dv(a,$,X,{location:f+K,distance:d,threshold:p,findAllMatches:g,minMatchCharLength:y,includeMatches:c,ignoreLocation:x});se&&(q=!0),z+=be,se&&Se&&(A=[...A,...Se])});let Q={isMatch:q,score:q?z/this.chunks.length:1};return q&&c&&(Q.indices=A),Q}}class Wn{constructor(a){this.pattern=a}static isMultiMatch(a){return Xp(a,this.multiRegex)}static isSingleMatch(a){return Xp(a,this.singleRegex)}search(){}}function Xp(i,a){const u=i.match(a);return u?u[1]:null}class gv extends Wn{constructor(a){super(a)}static get type(){return"exact"}static get multiRegex(){return/^="(.*)"$/}static get singleRegex(){return/^=(.*)$/}search(a){const u=a===this.pattern;return{isMatch:u,score:u?0:1,indices:[0,this.pattern.length-1]}}}class mv extends Wn{constructor(a){super(a)}static get type(){return"inverse-exact"}static get multiRegex(){return/^!"(.*)"$/}static get singleRegex(){return/^!(.*)$/}search(a){const s=a.indexOf(this.pattern)===-1;return{isMatch:s,score:s?0:1,indices:[0,a.length-1]}}}class yv extends Wn{constructor(a){super(a)}static get type(){return"prefix-exact"}static get multiRegex(){return/^\^"(.*)"$/}static get singleRegex(){return/^\^(.*)$/}search(a){const u=a.startsWith(this.pattern);return{isMatch:u,score:u?0:1,indices:[0,this.pattern.length-1]}}}class bv extends Wn{constructor(a){super(a)}static get type(){return"inverse-prefix-exact"}static get multiRegex(){return/^!\^"(.*)"$/}static get singleRegex(){return/^!\^(.*)$/}search(a){const u=!a.startsWith(this.pattern);return{isMatch:u,score:u?0:1,indices:[0,a.length-1]}}}class vv extends Wn{constructor(a){super(a)}static get type(){return"suffix-exact"}static get multiRegex(){return/^"(.*)"\$$/}static get singleRegex(){return/^(.*)\$$/}search(a){const u=a.endsWith(this.pattern);return{isMatch:u,score:u?0:1,indices:[a.length-this.pattern.length,a.length-1]}}}class xv extends Wn{constructor(a){super(a)}static get type(){return"inverse-suffix-exact"}static get multiRegex(){return/^!"(.*)"\$$/}static get singleRegex(){return/^!(.*)\$$/}search(a){const u=!a.endsWith(this.pattern);return{isMatch:u,score:u?0:1,indices:[0,a.length-1]}}}class Sg extends Wn{constructor(a,{location:u=ge.location,threshold:s=ge.threshold,distance:c=ge.distance,includeMatches:f=ge.includeMatches,findAllMatches:d=ge.findAllMatches,minMatchCharLength:p=ge.minMatchCharLength,isCaseSensitive:g=ge.isCaseSensitive,ignoreDiacritics:y=ge.ignoreDiacritics,ignoreLocation:x=ge.ignoreLocation}={}){super(a),this._bitapSearch=new xg(a,{location:u,threshold:s,distance:c,includeMatches:f,findAllMatches:d,minMatchCharLength:p,isCaseSensitive:g,ignoreDiacritics:y,ignoreLocation:x})}static get type(){return"fuzzy"}static get multiRegex(){return/^"(.*)"$/}static get singleRegex(){return/^(.*)$/}search(a){return this._bitapSearch.searchIn(a)}}class _g extends Wn{constructor(a){super(a)}static get type(){return"include"}static get multiRegex(){return/^'"(.*)"$/}static get singleRegex(){return/^'(.*)$/}search(a){let u=0,s;const c=[],f=this.pattern.length;for(;(s=a.indexOf(this.pattern,u))>-1;)u=s+f,c.push([s,u-1]);const d=!!c.length;return{isMatch:d,score:d?0:1,indices:c}}}const ho=[gv,_g,yv,bv,xv,vv,mv,Sg],Qp=ho.length,Sv=/ +(?=(?:[^\"]*\"[^\"]*\")*[^\"]*$)/,_v="|";function Ev(i,a={}){return i.split(_v).map(u=>{let s=u.trim().split(Sv).filter(f=>f&&!!f.trim()),c=[];for(let f=0,d=s.length;f<d;f+=1){const p=s[f];let g=!1,y=-1;for(;!g&&++y<Qp;){const x=ho[y];let A=x.isMultiMatch(p);A&&(c.push(new x(A,a)),g=!0)}if(!g)for(y=-1;++y<Qp;){const x=ho[y];let A=x.isSingleMatch(p);if(A){c.push(new x(A,a));break}}}return c})}const Av=new Set([Sg.type,_g.type]);class Tv{constructor(a,{isCaseSensitive:u=ge.isCaseSensitive,ignoreDiacritics:s=ge.ignoreDiacritics,includeMatches:c=ge.includeMatches,minMatchCharLength:f=ge.minMatchCharLength,ignoreLocation:d=ge.ignoreLocation,findAllMatches:p=ge.findAllMatches,location:g=ge.location,threshold:y=ge.threshold,distance:x=ge.distance}={}){this.query=null,this.options={isCaseSensitive:u,ignoreDiacritics:s,includeMatches:c,minMatchCharLength:f,findAllMatches:p,ignoreLocation:d,location:g,threshold:y,distance:x},a=u?a:a.toLowerCase(),a=s?Gs(a):a,this.pattern=a,this.query=Ev(this.pattern,this.options)}static condition(a,u){return u.useExtendedSearch}searchIn(a){const u=this.query;if(!u)return{isMatch:!1,score:1};const{includeMatches:s,isCaseSensitive:c,ignoreDiacritics:f}=this.options;a=c?a:a.toLowerCase(),a=f?Gs(a):a;let d=0,p=[],g=0;for(let y=0,x=u.length;y<x;y+=1){const A=u[y];p.length=0,d=0;for(let z=0,q=A.length;z<q;z+=1){const Q=A[z],{isMatch:$,indices:X,score:K}=Q.search(a);if($){if(d+=1,g+=K,s){const se=Q.constructor.type;Av.has(se)?p=[...p,...X]:p.push(X)}}else{g=0,d=0,p.length=0;break}}if(d){let z={isMatch:!0,score:g/d};return s&&(z.indices=p),z}}return{isMatch:!1,score:1}}}const po=[];function jv(...i){po.push(...i)}function go(i,a){for(let u=0,s=po.length;u<s;u+=1){let c=po[u];if(c.condition(i,a))return new c(i,a)}return new xg(i,a)}const Ys={AND:"$and",OR:"$or"},mo={PATH:"$path",PATTERN:"$val"},yo=i=>!!(i[Ys.AND]||i[Ys.OR]),Ov=i=>!!i[mo.PATH],Nv=i=>!mn(i)&&mg(i)&&!yo(i),Zp=i=>({[Ys.AND]:Object.keys(i).map(a=>({[a]:i[a]}))});function Eg(i,a,{auto:u=!0}={}){const s=c=>{let f=Object.keys(c);const d=Ov(c);if(!d&&f.length>1&&!yo(c))return s(Zp(c));if(Nv(c)){const g=d?c[mo.PATH]:f[0],y=d?c[mo.PATTERN]:c[g];if(!Ll(y))throw new Error(Pb(g));const x={keyId:fo(g),pattern:y};return u&&(x.searcher=go(y,a)),x}let p={children:[],operator:f[0]};return f.forEach(g=>{const y=c[g];mn(y)&&y.forEach(x=>{p.children.push(s(x))})}),p};return yo(i)||(i=Zp(i)),s(i)}function Mv(i,{ignoreFieldNorm:a=ge.ignoreFieldNorm}){i.forEach(u=>{let s=1;u.matches.forEach(({key:c,norm:f,score:d})=>{const p=c?c.weight:null;s*=Math.pow(d===0&&p?Number.EPSILON:d,(p||1)*(a?1:f))}),u.score=s})}function zv(i,a){const u=i.matches;a.matches=[],ol(u)&&u.forEach(s=>{if(!ol(s.indices)||!s.indices.length)return;const{indices:c,value:f}=s;let d={indices:c,value:f};s.key&&(d.key=s.key.src),s.idx>-1&&(d.refIndex=s.idx),a.matches.push(d)})}function Rv(i,a){a.score=i.score}function Cv(i,a,{includeMatches:u=ge.includeMatches,includeScore:s=ge.includeScore}={}){const c=[];return u&&c.push(zv),s&&c.push(Rv),i.map(f=>{const{idx:d}=f,p={item:a[d],refIndex:d};return c.length&&c.forEach(g=>{g(f,p)}),p})}class Fn{constructor(a,u={},s){this.options={...ge,...u},this.options.useExtendedSearch,this._keyStore=new nv(this.options.keys),this.setCollection(a,s)}setCollection(a,u){if(this._docs=a,u&&!(u instanceof Co))throw new Error(Ib);this._myIndex=u||vg(this.options.keys,this._docs,{getFn:this.options.getFn,fieldNormWeight:this.options.fieldNormWeight})}add(a){ol(a)&&(this._docs.push(a),this._myIndex.add(a))}remove(a=()=>!1){const u=[];for(let s=0,c=this._docs.length;s<c;s+=1){const f=this._docs[s];a(f,s)&&(this.removeAt(s),s-=1,c-=1,u.push(f))}return u}removeAt(a){this._docs.splice(a,1),this._myIndex.removeAt(a)}getIndex(){return this._myIndex}search(a,{limit:u=-1}={}){const{includeMatches:s,includeScore:c,shouldSort:f,sortFn:d,ignoreFieldNorm:p}=this.options;let g=Ll(a)?Ll(this._docs[0])?this._searchStringList(a):this._searchObjectList(a):this._searchLogical(a);return Mv(g,{ignoreFieldNorm:p}),f&&g.sort(d),gg(u)&&u>-1&&(g=g.slice(0,u)),Cv(g,this._docs,{includeMatches:s,includeScore:c})}_searchStringList(a){const u=go(a,this.options),{records:s}=this._myIndex,c=[];return s.forEach(({v:f,i:d,n:p})=>{if(!ol(f))return;const{isMatch:g,score:y,indices:x}=u.searchIn(f);g&&c.push({item:f,idx:d,matches:[{score:y,value:f,norm:p,indices:x}]})}),c}_searchLogical(a){const u=Eg(a,this.options),s=(p,g,y)=>{if(!p.children){const{keyId:A,searcher:z}=p,q=this._findMatches({key:this._keyStore.get(A),value:this._myIndex.getValueForItemAtKeyId(g,A),searcher:z});return q&&q.length?[{idx:y,item:g,matches:q}]:[]}const x=[];for(let A=0,z=p.children.length;A<z;A+=1){const q=p.children[A],Q=s(q,g,y);if(Q.length)x.push(...Q);else if(p.operator===Ys.AND)return[]}return x},c=this._myIndex.records,f={},d=[];return c.forEach(({$:p,i:g})=>{if(ol(p)){let y=s(u,p,g);y.length&&(f[g]||(f[g]={idx:g,item:p,matches:[]},d.push(f[g])),y.forEach(({matches:x})=>{f[g].matches.push(...x)}))}}),d}_searchObjectList(a){const u=go(a,this.options),{keys:s,records:c}=this._myIndex,f=[];return c.forEach(({$:d,i:p})=>{if(!ol(d))return;let g=[];s.forEach((y,x)=>{g.push(...this._findMatches({key:y,value:d[x],searcher:u}))}),g.length&&f.push({idx:p,item:d,matches:g})}),f}_findMatches({key:a,value:u,searcher:s}){if(!ol(u))return[];let c=[];if(mn(u))u.forEach(({v:f,i:d,n:p})=>{if(!ol(f))return;const{isMatch:g,score:y,indices:x}=s.searchIn(f);g&&c.push({score:y,key:a,value:f,idx:d,norm:p,indices:x})});else{const{v:f,n:d}=u,{isMatch:p,score:g,indices:y}=s.searchIn(f);p&&c.push({score:g,key:a,value:f,norm:d,indices:y})}return c}}Fn.version="7.1.0";Fn.createIndex=vg;Fn.parseIndex=fv;Fn.config=ge;Fn.parseQuery=Eg;jv(Tv);function wv({visible:i,onClose:a,projects:u,endpoints:s,actions:c,onSelectProject:f,onSelectEndpoint:d,onAction:p}){const[g,y]=k.useState(""),[x,A]=k.useState(0),z=k.useRef(null),q=k.useMemo(()=>new Fn(u||[],{keys:["name","path"],threshold:.4}),[u]),Q=k.useMemo(()=>new Fn(s||[],{keys:["method","path","summary","tags"],threshold:.4}),[s]),$=k.useMemo(()=>new Fn(c||[],{keys:["label"],threshold:.4}),[c]),X=k.useMemo(()=>{const R=[];if(!g)c&&c.length>0&&c.forEach(w=>R.push({type:"action",item:w})),u&&u.length>0&&u.forEach(w=>R.push({type:"project",item:w})),s&&s.length>0&&s.slice(0,20).forEach(w=>R.push({type:"endpoint",item:w}));else{const w=$.search(g,{limit:5}),P=q.search(g,{limit:5}),Ve=Q.search(g,{limit:15});w.forEach(W=>R.push({type:"action",item:W.item})),P.forEach(W=>R.push({type:"project",item:W.item})),Ve.forEach(W=>R.push({type:"endpoint",item:W.item}))}return R},[g,u,s,c,q,Q,$]);k.useEffect(()=>{A(0)},[g]),k.useEffect(()=>{i&&z.current&&z.current.focus()},[i]),k.useEffect(()=>{i&&y("")},[i]);const K=k.useCallback(R=>{R.type==="action"&&p?p(R.item):R.type==="project"&&f?f(R.item):R.type==="endpoint"&&d&&d(R.item)},[p,f,d]),se=k.useCallback(R=>{R.key==="Escape"?(R.preventDefault(),a()):R.key==="ArrowDown"?(R.preventDefault(),A(w=>Math.min(w+1,X.length-1))):R.key==="ArrowUp"?(R.preventDefault(),A(w=>Math.max(w-1,0))):R.key==="Enter"&&(R.preventDefault(),X[x]&&K(X[x]))},[a,X,x,K]);if(!i)return null;const be=X.filter(R=>R.type==="action"),Se=X.filter(R=>R.type==="project"),oe=X.filter(R=>R.type==="endpoint");let ve=0;return b.jsxs("div",{className:"command-palette",children:[b.jsx("div",{className:"command-palette__backdrop",onClick:a}),b.jsxs("div",{className:"command-palette__dialog",children:[b.jsx("input",{ref:z,className:"command-palette__input",type:"text",placeholder:"Search actions, projects, and endpoints...",value:g,onChange:R=>y(R.target.value),onKeyDown:se}),b.jsxs("div",{className:"command-palette__results",children:[be.length>0&&b.jsxs(b.Fragment,{children:[b.jsx("div",{className:"command-palette__section-title",children:"Actions"}),be.map(R=>{const w=ve++;return b.jsxs("div",{className:`command-palette__item${w===x?" command-palette__item--active":""}`,onClick:()=>K(R),onMouseEnter:()=>A(w),children:[b.jsx("span",{className:"command-palette__item-label",children:R.item.label}),R.item.shortcut&&b.jsx("span",{className:"command-palette__item-shortcut",children:R.item.shortcut})]},`act-${R.item.id}`)})]}),Se.length>0&&b.jsxs(b.Fragment,{children:[b.jsx("div",{className:"command-palette__section-title",children:"Projects"}),Se.map(R=>{const w=ve++;return b.jsxs("div",{className:`command-palette__item${w===x?" command-palette__item--active":""}`,onClick:()=>K(R),onMouseEnter:()=>A(w),children:[b.jsx("span",{className:"command-palette__item-label",children:R.item.name||R.item.path}),R.item.name&&b.jsx("span",{className:"command-palette__item-detail",children:R.item.path})]},`proj-${R.item.path}`)})]}),oe.length>0&&b.jsxs(b.Fragment,{children:[b.jsx("div",{className:"command-palette__section-title",children:"Endpoints"}),oe.map(R=>{const w=R.item,P=ve++;return b.jsxs("div",{className:`command-palette__item${P===x?" command-palette__item--active":""}`,onClick:()=>K(R),onMouseEnter:()=>A(P),children:[b.jsx("span",{className:`endpoint-item__method endpoint-item__method--${(w.method||"").toLowerCase()}`,children:(w.method||"").toUpperCase()}),b.jsx("span",{className:"command-palette__item-label",children:w.path}),w.summary&&b.jsx("span",{className:"command-palette__item-detail",children:w.summary})]},`ep-${w.method}-${w.path}`)})]}),X.length===0&&g&&b.jsx("div",{style:{padding:"16px",color:"var(--fg-muted)",textAlign:"center"},children:"No results found"})]})]})]})}function Dv({visible:i,onClose:a,projects:u,currentProject:s,onSwitch:c,onAdd:f,onRemove:d}){const[p,g]=k.useState(""),[y,x]=k.useState(0),[A,z]=k.useState(null),[q,Q]=k.useState(null),[$,X]=k.useState(null),[K,se]=k.useState("bookmarks"),be=k.useRef(null);k.useEffect(()=>{if(i){const w=s?.path||"",P=!!w;g(P?w+"/":""),x(0),z(P?w:null),Q(null),X(null),se(P?"browse":"bookmarks"),setTimeout(()=>be.current?.focus(),0)}},[i]),k.useEffect(()=>{A!==null&&(X(null),Wy(A).then(w=>{Q(w),x(0)}).catch(w=>{X(w.message||"Cannot browse"),Q(null)}))},[A]),k.useEffect(()=>{if(p.startsWith("/")||p.startsWith("~")){se("browse");const w=p.lastIndexOf("/"),P=w<=0?p.startsWith("~")?"~":"/":p.slice(0,w)||"/";P!==A&&z(P)}else K==="browse"&&!p&&(se("bookmarks"),z(null),Q(null))},[p]);const oe=k.useCallback(()=>{if(K==="browse"&&q){const Ve=p.slice((A||"").length).replace(/^\//,"").toLowerCase();let W=[];Ve||(q.parent&&W.push({type:"parent",path:q.parent,label:"..",detail:q.parent}),q.has_spec&&W.push({type:"open",path:q.path,label:". (open this directory)",detail:`spec: ${q.spec_file}`,hasSpec:!0}));for(const me of q.dirs)Ve&&!me.toLowerCase().includes(Ve)||W.push({type:"dir",path:`${q.path}/${me}`,label:me,detail:null});return W}const w=p.toLowerCase();let P=[];if(u&&u.length>0){const Ve=w?u.filter(W=>W.name.toLowerCase().includes(w)||W.path.toLowerCase().includes(w)):u;for(const W of Ve)P.push({type:"project",path:W.path,label:W.name,detail:W.path,isCurrent:W.path===s?.path})}return P.length===0&&!w&&P.push({type:"hint",label:"Type a path (e.g. /home/user/my-api) to browse",detail:""}),P},[K,q,A,p,u,s])(),ve=k.useCallback(async w=>{if(!(!w||w.type==="hint")){if(w.type==="parent"){const P=w.path;g(P+"/"),z(P),x(0);return}if(w.type==="dir"){g(w.path+"/"),z(w.path),x(0);return}try{await c(w.path),a()}catch(P){X(P.message||"Failed to open project")}}},[c,a]),R=k.useCallback(w=>{if(w.key==="Escape")w.preventDefault(),a();else if(w.key==="ArrowDown")w.preventDefault(),x(P=>Math.min(P+1,oe.length-1));else if(w.key==="ArrowUp")w.preventDefault(),x(P=>Math.max(P-1,0));else if(w.key==="Enter")if(w.preventDefault(),K==="browse"&&p&&!p.endsWith("/")){const P=p.replace(/\/$/,"");c(P).then(()=>a()).catch(Ve=>{X(Ve.message||"Failed to open")})}else oe[y]&&ve(oe[y]);else if(w.key==="Tab"){w.preventDefault();const P=oe[y];P&&(P.type==="dir"||P.type==="parent")&&ve(P)}},[a,oe,y,ve,K,p,c]);return i?b.jsxs("div",{className:"command-palette",children:[b.jsx("div",{className:"command-palette__backdrop",onClick:a}),b.jsxs("div",{className:"command-palette__dialog",children:[b.jsx("input",{ref:be,className:"command-palette__input",type:"text",placeholder:"Search bookmarks or type /path/to/project...",value:p,onChange:w=>g(w.target.value),onKeyDown:R}),$&&b.jsx("div",{style:{padding:"8px 16px",fontSize:"12px",color:"var(--method-delete)"},children:$}),K==="browse"&&q&&b.jsxs("div",{className:"command-palette__section-title",style:{display:"flex",justifyContent:"space-between"},children:[b.jsx("span",{children:q.path}),q.has_spec&&b.jsx("span",{style:{color:"var(--method-get)"},children:"spec found"})]}),b.jsxs("div",{className:"command-palette__results",children:[K==="bookmarks"&&oe.some(w=>w.type==="project")&&b.jsx("div",{className:"command-palette__section-title",children:"Bookmarked Projects"}),oe.map((w,P)=>{if(w.type==="hint")return b.jsx("div",{style:{padding:"16px",color:"var(--fg-muted)",textAlign:"center",fontSize:"13px"},children:w.label},"hint");const Ve=w.type==="parent"?"← ":w.type==="dir"?"📁 ":w.type==="open"?"→ ":w.isCurrent?"● ":"";return b.jsxs("div",{className:`command-palette__item${P===y?" command-palette__item--active":""}`,onClick:()=>ve(w),onMouseEnter:()=>x(P),children:[b.jsxs("span",{className:"command-palette__item-label",children:[Ve,w.label]}),w.detail&&b.jsx("span",{className:"command-palette__item-detail",children:w.detail})]},`${w.type}-${w.path}`)}),oe.length===0&&K==="browse"&&b.jsx("div",{style:{padding:"16px",color:"var(--fg-muted)",textAlign:"center"},children:q?"No subdirectories":"Loading..."})]}),b.jsxs("div",{style:{padding:"6px 16px",borderTop:"1px solid var(--border)",fontSize:"11px",color:"var(--fg-muted)",display:"flex",gap:"16px"},children:[b.jsx("span",{children:"Enter: open/navigate"}),b.jsx("span",{children:"Tab: enter directory"}),b.jsx("span",{children:"Esc: close"})]})]})]}):null}function Vp({onResize:i,onResizeStart:a,direction:u="horizontal"}){const s=k.useRef(!1),c=k.useCallback(f=>{f.preventDefault(),s.current=!0;const d=f.clientX,p=f.clientY;a&&a();const g=x=>{if(!s.current)return;const A=u==="horizontal"?x.clientX-d:x.clientY-p;i(A)},y=()=>{s.current=!1,document.removeEventListener("mousemove",g),document.removeEventListener("mouseup",y),document.body.style.cursor="",document.body.style.userSelect=""};document.body.style.cursor=u==="horizontal"?"col-resize":"row-resize",document.body.style.userSelect="none",document.addEventListener("mousemove",g),document.addEventListener("mouseup",y)},[i,a,u]);return b.jsx("div",{className:`resize-handle resize-handle--${u}`,onMouseDown:c})}function kv(){const[i,a]=k.useState(null),[u,s]=k.useState([]),[c,f]=k.useState([]),[d,p]=k.useState(null),[g,y]=k.useState(null),[x,A]=k.useState({}),[z,q]=k.useState(null),[Q,$]=k.useState(!1),[X,K]=k.useState(null),[se,be]=k.useState({global:{},project:{}}),[Se,oe]=k.useState(null),[ve,R]=k.useState(null),[w,P]=k.useState(null),[Ve,W]=k.useState({}),[me,et]=k.useState(!1),[Me,We]=k.useState(!1),[D,F]=k.useState(!1),[re,Be]=k.useState("tag"),[He,E]=k.useState({}),[L,I]=k.useState(""),[ee,ye]=k.useState(0),[_e,we]=k.useState({}),[dt,ut]=k.useState(()=>{try{return Number(localStorage.getItem("apigrip:sidebarWidth"))||280}catch{return 280}}),[Lt,yn]=k.useState(()=>{try{return Number(localStorage.getItem("apigrip:requestPanelRatio"))||.5}catch{return .5}}),bn=k.useRef(280),In=k.useRef(.5),Pt=k.useRef(null),Yl=k.useRef(null),fl=k.useRef(null),Ta=k.useRef(x),vn=k.useRef(d);Ta.current=x,vn.current=d;const Qt=k.useCallback((V,v,M)=>`apigrip:${V}:${v}:${M}`,[]),Al=k.useCallback((V,v,M)=>{try{localStorage.setItem(Qt("params",V,v),JSON.stringify(M))}catch{}},[Qt]),xn=k.useCallback((V,v)=>{try{const M=localStorage.getItem(Qt("params",V,v));return M?JSON.parse(M):null}catch{return null}},[Qt]),Pn=k.useCallback((V,v,M)=>{try{localStorage.setItem(Qt("response",V,v),JSON.stringify(M))}catch{}},[Qt]),ea=k.useCallback((V,v)=>{try{const M=localStorage.getItem(Qt("response",V,v));return M?JSON.parse(M):null}catch{return null}},[Qt]),st=k.useCallback(()=>{if(fl.current&&vn.current){clearTimeout(fl.current),fl.current=null;const V=vn.current;_p(V.method,V.path,Ta.current).catch(()=>{})}},[]),kt=k.useCallback(V=>{oe(V),Yl.current&&clearTimeout(Yl.current),Yl.current=setTimeout(()=>oe(null),3e3)},[]),Bt=k.useCallback(async()=>{const[V,v]=await Promise.allSettled([Iy(),Cs()]);be(V.status==="fulfilled"?V.value||{global:{},project:{}}:{global:{},project:{}}),s(v.status==="fulfilled"?v.value||[]:[]);const M=V.status==="fulfilled"&&(V.value?.global?.theme||V.value?.project?.theme)||"dark";document.documentElement.setAttribute("data-theme",M);try{localStorage.setItem("apigrip:theme",M)}catch{}try{const Y=await qy();a(Y),K(Y.git||null)}catch{a(null),K(null)}try{const Y=await xp();f(Array.isArray(Y)?Y:[])}catch{f([])}try{const Y=await Sp();R(Y),P(Y.active||null);const he=await Pc();W(he||{})}catch{}},[]);k.useEffect(()=>{Bt()},[Bt]),k.useEffect(()=>{const V=e0({onSpecReloaded:()=>{xp().then(v=>f(Array.isArray(v)?v:[])).catch(()=>{}),kt("Spec reloaded")},onSpecError:v=>{kt(`Spec error: ${v.message||"unknown"}`)},onGitChanged:v=>{K(v)},onProjectSwitched:()=>{Bt()}});return()=>V.disconnect()},[Bt,kt]);const Cl=k.useCallback(async V=>{st(),p(V),ye(0),we({});const v=xn(V.method,V.path);v&&A(v);const M=ea(V.method,V.path);q(M||null);try{const Y=await Yy(V.method,V.path);y(Y);const Ke=await Jy(V.method,V.path)||{};A(Ke),Al(V.method,V.path,Ke)}catch(Y){console.error("Failed to load endpoint:",Y)}},[st,xn,ea,Al]),Xl=k.useCallback(V=>{A(V),d&&(Al(d.method,d.path,V),fl.current&&clearTimeout(fl.current),fl.current=setTimeout(()=>{_p(d.method,d.path,V).catch(()=>{})},500))},[d,Al]),Ql=k.useCallback(async()=>{if(!(!g||Q)){$(!0),q(null);try{const v=(g.servers||[])[ee]||{},M={method:g.method,path:g.path,params:x,server_index:ee,server_variables:_e},Y=await $y(M);q(Y),Pn(g.method,g.path,Y)}catch(V){const v={error:V.message};q(v),Pn(g.method,g.path,v)}finally{$(!1)}}},[g,x,Q,ee,_e,Pn]),Sn=k.useCallback(async V=>{try{await Hy(V),await Bt(),p(null),y(null),q(null),kt("Project switched")}catch(v){kt(`Failed to switch: ${v.message}`)}},[Bt,kt]),oi=k.useCallback(async V=>{await Ly(V);const v=await Cs();s(v||[])},[]),fi=k.useCallback(async V=>{await Gy(V);const v=await Cs();s(v||[])},[]),Zl=k.useCallback(async V=>{try{await Vy(V),P(V);const v=await Pc();W(v||{})}catch(v){kt(`Failed to set env: ${v.message}`)}},[kt]),Ot=k.useCallback(async()=>{try{const V=await Sp();R(V);const v=await Pc();W(v||{}),kt("Environments saved")}catch(V){kt(`Env error: ${V.message}`)}},[kt]),hl=k.useCallback(()=>{bn.current=dt},[dt]),Mt=k.useCallback(V=>{const v=Math.max(160,Math.min(600,bn.current+V));ut(v);try{localStorage.setItem("apigrip:sidebarWidth",String(v))}catch{}},[]),hi=k.useCallback(()=>{In.current=Lt},[Lt]),ta=k.useCallback(V=>{if(!Pt.current)return;const v=Pt.current.offsetWidth;if(v<=0)return;const M=Math.max(.2,Math.min(.8,In.current+V/v));yn(M);try{localStorage.setItem("apigrip:requestPanelRatio",String(M))}catch{}},[]),el=navigator.platform?.startsWith("Mac")||navigator.userAgent?.includes("Mac")?"⌘":"Ctrl",Tl=k.useCallback(async()=>{const v=(se?.global?.theme||se?.project?.theme||"dark")==="dark"?"light":"dark";try{await Py({global:{theme:v}}),document.documentElement.setAttribute("data-theme",v);try{localStorage.setItem("apigrip:theme",v)}catch{}be(M=>({...M,global:{...M.global,theme:v}}))}catch{}},[se]),Vl=k.useMemo(()=>[{id:"env-editor",label:"Edit Environments",shortcut:`${el}+E`,handler:()=>et(!0)},{id:"open-project",label:"Open Project",shortcut:`${el}+O`,handler:()=>F(!0)},{id:"toggle-theme",label:"Toggle Theme",shortcut:`${el}+Shift+L`,handler:Tl},{id:"toggle-view",label:"Toggle View Mode (Tag/Tree)",shortcut:null,handler:()=>Be(V=>V==="tag"?"tree":"tag")},{id:"send-request",label:"Send Request",shortcut:`${el}+Enter`,handler:Ql}],[Tl,Ql,el]);return k.useEffect(()=>{Me&&Cs().then(V=>s(V||[])).catch(()=>{})},[Me]),k.useEffect(()=>{function V(v){const M=v.ctrlKey||v.metaKey;M&&v.key==="p"&&(v.preventDefault(),We(Y=>!Y)),M&&v.key==="Enter"&&(v.preventDefault(),Ql()),M&&v.key==="o"&&(v.preventDefault(),F(Y=>!Y)),M&&v.key==="e"&&(v.preventDefault(),et(Y=>!Y)),M&&v.shiftKey&&(v.key==="L"||v.key==="l")&&(v.preventDefault(),Tl())}return document.addEventListener("keydown",V),()=>document.removeEventListener("keydown",V)},[Ql,Tl]),b.jsxs("div",{className:"app",children:[b.jsx(t0,{project:i,git:X,environments:ve,activeEnv:w,onSwitchProject:Sn,onSetActiveEnv:Zl,onOpenEnvEditor:()=>et(!0),onOpenProjectDialog:()=>F(!0),toast:Se,projects:u}),b.jsxs("div",{className:"app__body",children:[b.jsx("div",{className:"app__sidebar",style:{width:dt},children:b.jsx(i0,{endpoints:c,selectedEndpoint:d,onSelect:Cl,viewMode:re,onToggleViewMode:()=>Be(V=>V==="tag"?"tree":"tag"),treeCollapseState:He,onToggleTreeNode:V=>E(v=>({...v,[V]:!v[V]})),searchTerm:L,onSearchChange:I})}),b.jsx(Vp,{direction:"horizontal",onResize:Mt,onResizeStart:hl}),b.jsxs("div",{className:"app__main",ref:Pt,children:[b.jsx("div",{className:"app__request-panel",style:{flex:`${Lt} 0 0%`},children:b.jsx(eb,{spec:i,endpoint:g,params:x,onParamsChange:Xl,onSend:Ql,sending:Q,serverIndex:ee,onServerIndexChange:ye,serverVariables:_e,onServerVariablesChange:we,preferences:se,resolvedEnv:Ve})}),b.jsx(Vp,{direction:"horizontal",onResize:ta,onResizeStart:hi}),b.jsx("div",{className:"app__response-panel",style:{flex:`${1-Lt} 0 0%`},children:b.jsx(Zb,{response:z,sending:Q})})]})]}),me&&b.jsx(Kb,{environments:ve,onSave:Ot,onClose:()=>et(!1)}),Me&&b.jsx(wv,{visible:Me,onClose:()=>We(!1),projects:u,endpoints:c,actions:Vl,onSelectProject:V=>{Sn(V.path),We(!1)},onSelectEndpoint:V=>{Cl(V),We(!1)},onAction:V=>{V.handler(),We(!1)}}),b.jsx(Dv,{visible:D,onClose:()=>F(!1),projects:u,currentProject:i,onSwitch:Sn,onAdd:oi,onRemove:fi})]})}By.createRoot(document.getElementById("root")).render(b.jsx(kv,{}));