@package-broker/ui 0.11.0 → 0.12.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const n of document.querySelectorAll('link[rel="modulepreload"]'))l(n);new MutationObserver(n=>{for(const o of n)if(o.type==="childList")for(const s of o.addedNodes)s.tagName==="LINK"&&s.rel==="modulepreload"&&l(s)}).observe(document,{childList:!0,subtree:!0});function i(n){const o={};return n.integrity&&(o.integrity=n.integrity),n.referrerPolicy&&(o.referrerPolicy=n.referrerPolicy),n.crossOrigin==="use-credentials"?o.credentials="include":n.crossOrigin==="anonymous"?o.credentials="omit":o.credentials="same-origin",o}function l(n){if(n.ep)return;n.ep=!0;const o=i(n);fetch(n.href,o)}})();function _o(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var ym={exports:{}},Wl={};var Ax;function pO(){if(Ax)return Wl;Ax=1;var e=Symbol.for("react.transitional.element"),t=Symbol.for("react.fragment");function i(l,n,o){var s=null;if(o!==void 0&&(s=""+o),n.key!==void 0&&(s=""+n.key),"key"in n){o={};for(var f in n)f!=="key"&&(o[f]=n[f])}else o=n;return n=o.ref,{$$typeof:e,type:l,key:s,ref:n!==void 0?n:null,props:o}}return Wl.Fragment=t,Wl.jsx=i,Wl.jsxs=i,Wl}var Rx;function gO(){return Rx||(Rx=1,ym.exports=pO()),ym.exports}var y=gO(),bm={exports:{}},we={};var Ix;function vO(){if(Ix)return we;Ix=1;var e=Symbol.for("react.transitional.element"),t=Symbol.for("react.portal"),i=Symbol.for("react.fragment"),l=Symbol.for("react.strict_mode"),n=Symbol.for("react.profiler"),o=Symbol.for("react.consumer"),s=Symbol.for("react.context"),f=Symbol.for("react.forward_ref"),m=Symbol.for("react.suspense"),d=Symbol.for("react.memo"),p=Symbol.for("react.lazy"),v=Symbol.for("react.activity"),b=Symbol.iterator;function x(T){return T===null||typeof T!="object"?null:(T=b&&T[b]||T["@@iterator"],typeof T=="function"?T:null)}var S={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},w=Object.assign,j={};function E(T,Z,$){this.props=T,this.context=Z,this.refs=j,this.updater=$||S}E.prototype.isReactComponent={},E.prototype.setState=function(T,Z){if(typeof T!="object"&&typeof T!="function"&&T!=null)throw Error("takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,T,Z,"setState")},E.prototype.forceUpdate=function(T){this.updater.enqueueForceUpdate(this,T,"forceUpdate")};function O(){}O.prototype=E.prototype;function N(T,Z,$){this.props=T,this.context=Z,this.refs=j,this.updater=$||S}var G=N.prototype=new O;G.constructor=N,w(G,E.prototype),G.isPureReactComponent=!0;var J=Array.isArray;function R(){}var X={H:null,A:null,T:null,S:null},Q=Object.prototype.hasOwnProperty;function me(T,Z,$){var oe=$.ref;return{$$typeof:e,type:T,key:Z,ref:oe!==void 0?oe:null,props:$}}function B(T,Z){return me(T.type,Z,T.props)}function ue(T){return typeof T=="object"&&T!==null&&T.$$typeof===e}function ce(T){var Z={"=":"=0",":":"=2"};return"$"+T.replace(/[=:]/g,function($){return Z[$]})}var ke=/\/+/g;function M(T,Z){return typeof T=="object"&&T!==null&&T.key!=null?ce(""+T.key):Z.toString(36)}function U(T){switch(T.status){case"fulfilled":return T.value;case"rejected":throw T.reason;default:switch(typeof T.status=="string"?T.then(R,R):(T.status="pending",T.then(function(Z){T.status==="pending"&&(T.status="fulfilled",T.value=Z)},function(Z){T.status==="pending"&&(T.status="rejected",T.reason=Z)})),T.status){case"fulfilled":return T.value;case"rejected":throw T.reason}}throw T}function A(T,Z,$,oe,de){var pe=typeof T;(pe==="undefined"||pe==="boolean")&&(T=null);var Ie=!1;if(T===null)Ie=!0;else switch(pe){case"bigint":case"string":case"number":Ie=!0;break;case"object":switch(T.$$typeof){case e:case t:Ie=!0;break;case p:return Ie=T._init,A(Ie(T._payload),Z,$,oe,de)}}if(Ie)return de=de(T),Ie=oe===""?"."+M(T,0):oe,J(de)?($="",Ie!=null&&($=Ie.replace(ke,"$&/")+"/"),A(de,Z,$,"",function(gn){return gn})):de!=null&&(ue(de)&&(de=B(de,$+(de.key==null||T&&T.key===de.key?"":(""+de.key).replace(ke,"$&/")+"/")+Ie)),Z.push(de)),1;Ie=0;var ot=oe===""?".":oe+":";if(J(T))for(var Ve=0;Ve<T.length;Ve++)oe=T[Ve],pe=ot+M(oe,Ve),Ie+=A(oe,Z,$,pe,de);else if(Ve=x(T),typeof Ve=="function")for(T=Ve.call(T),Ve=0;!(oe=T.next()).done;)oe=oe.value,pe=ot+M(oe,Ve++),Ie+=A(oe,Z,$,pe,de);else if(pe==="object"){if(typeof T.then=="function")return A(U(T),Z,$,oe,de);throw Z=String(T),Error("Objects are not valid as a React child (found: "+(Z==="[object Object]"?"object with keys {"+Object.keys(T).join(", ")+"}":Z)+"). If you meant to render a collection of children, use an array instead.")}return Ie}function q(T,Z,$){if(T==null)return T;var oe=[],de=0;return A(T,oe,"","",function(pe){return Z.call($,pe,de++)}),oe}function te(T){if(T._status===-1){var Z=T._result;Z=Z(),Z.then(function($){(T._status===0||T._status===-1)&&(T._status=1,T._result=$)},function($){(T._status===0||T._status===-1)&&(T._status=2,T._result=$)}),T._status===-1&&(T._status=0,T._result=Z)}if(T._status===1)return T._result.default;throw T._result}var ie=typeof reportError=="function"?reportError:function(T){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var Z=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof T=="object"&&T!==null&&typeof T.message=="string"?String(T.message):String(T),error:T});if(!window.dispatchEvent(Z))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",T);return}console.error(T)},z={map:q,forEach:function(T,Z,$){q(T,function(){Z.apply(this,arguments)},$)},count:function(T){var Z=0;return q(T,function(){Z++}),Z},toArray:function(T){return q(T,function(Z){return Z})||[]},only:function(T){if(!ue(T))throw Error("React.Children.only expected to receive a single React element child.");return T}};return we.Activity=v,we.Children=z,we.Component=E,we.Fragment=i,we.Profiler=n,we.PureComponent=N,we.StrictMode=l,we.Suspense=m,we.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=X,we.__COMPILER_RUNTIME={__proto__:null,c:function(T){return X.H.useMemoCache(T)}},we.cache=function(T){return function(){return T.apply(null,arguments)}},we.cacheSignal=function(){return null},we.cloneElement=function(T,Z,$){if(T==null)throw Error("The argument must be a React element, but you passed "+T+".");var oe=w({},T.props),de=T.key;if(Z!=null)for(pe in Z.key!==void 0&&(de=""+Z.key),Z)!Q.call(Z,pe)||pe==="key"||pe==="__self"||pe==="__source"||pe==="ref"&&Z.ref===void 0||(oe[pe]=Z[pe]);var pe=arguments.length-2;if(pe===1)oe.children=$;else if(1<pe){for(var Ie=Array(pe),ot=0;ot<pe;ot++)Ie[ot]=arguments[ot+2];oe.children=Ie}return me(T.type,de,oe)},we.createContext=function(T){return T={$$typeof:s,_currentValue:T,_currentValue2:T,_threadCount:0,Provider:null,Consumer:null},T.Provider=T,T.Consumer={$$typeof:o,_context:T},T},we.createElement=function(T,Z,$){var oe,de={},pe=null;if(Z!=null)for(oe in Z.key!==void 0&&(pe=""+Z.key),Z)Q.call(Z,oe)&&oe!=="key"&&oe!=="__self"&&oe!=="__source"&&(de[oe]=Z[oe]);var Ie=arguments.length-2;if(Ie===1)de.children=$;else if(1<Ie){for(var ot=Array(Ie),Ve=0;Ve<Ie;Ve++)ot[Ve]=arguments[Ve+2];de.children=ot}if(T&&T.defaultProps)for(oe in Ie=T.defaultProps,Ie)de[oe]===void 0&&(de[oe]=Ie[oe]);return me(T,pe,de)},we.createRef=function(){return{current:null}},we.forwardRef=function(T){return{$$typeof:f,render:T}},we.isValidElement=ue,we.lazy=function(T){return{$$typeof:p,_payload:{_status:-1,_result:T},_init:te}},we.memo=function(T,Z){return{$$typeof:d,type:T,compare:Z===void 0?null:Z}},we.startTransition=function(T){var Z=X.T,$={};X.T=$;try{var oe=T(),de=X.S;de!==null&&de($,oe),typeof oe=="object"&&oe!==null&&typeof oe.then=="function"&&oe.then(R,ie)}catch(pe){ie(pe)}finally{Z!==null&&$.types!==null&&(Z.types=$.types),X.T=Z}},we.unstable_useCacheRefresh=function(){return X.H.useCacheRefresh()},we.use=function(T){return X.H.use(T)},we.useActionState=function(T,Z,$){return X.H.useActionState(T,Z,$)},we.useCallback=function(T,Z){return X.H.useCallback(T,Z)},we.useContext=function(T){return X.H.useContext(T)},we.useDebugValue=function(){},we.useDeferredValue=function(T,Z){return X.H.useDeferredValue(T,Z)},we.useEffect=function(T,Z){return X.H.useEffect(T,Z)},we.useEffectEvent=function(T){return X.H.useEffectEvent(T)},we.useId=function(){return X.H.useId()},we.useImperativeHandle=function(T,Z,$){return X.H.useImperativeHandle(T,Z,$)},we.useInsertionEffect=function(T,Z){return X.H.useInsertionEffect(T,Z)},we.useLayoutEffect=function(T,Z){return X.H.useLayoutEffect(T,Z)},we.useMemo=function(T,Z){return X.H.useMemo(T,Z)},we.useOptimistic=function(T,Z){return X.H.useOptimistic(T,Z)},we.useReducer=function(T,Z,$){return X.H.useReducer(T,Z,$)},we.useRef=function(T){return X.H.useRef(T)},we.useState=function(T){return X.H.useState(T)},we.useSyncExternalStore=function(T,Z,$){return X.H.useSyncExternalStore(T,Z,$)},we.useTransition=function(){return X.H.useTransition()},we.version="19.2.3",we}var Ux;function dp(){return Ux||(Ux=1,bm.exports=vO()),bm.exports}var C=dp();const yO=_o(C);var xm={exports:{}},eo={},_m={exports:{}},Sm={};var Lx;function bO(){return Lx||(Lx=1,(function(e){function t(A,q){var te=A.length;A.push(q);e:for(;0<te;){var ie=te-1>>>1,z=A[ie];if(0<n(z,q))A[ie]=q,A[te]=z,te=ie;else break e}}function i(A){return A.length===0?null:A[0]}function l(A){if(A.length===0)return null;var q=A[0],te=A.pop();if(te!==q){A[0]=te;e:for(var ie=0,z=A.length,T=z>>>1;ie<T;){var Z=2*(ie+1)-1,$=A[Z],oe=Z+1,de=A[oe];if(0>n($,te))oe<z&&0>n(de,$)?(A[ie]=de,A[oe]=te,ie=oe):(A[ie]=$,A[Z]=te,ie=Z);else if(oe<z&&0>n(de,te))A[ie]=de,A[oe]=te,ie=oe;else break e}}return q}function n(A,q){var te=A.sortIndex-q.sortIndex;return te!==0?te:A.id-q.id}if(e.unstable_now=void 0,typeof performance=="object"&&typeof performance.now=="function"){var o=performance;e.unstable_now=function(){return o.now()}}else{var s=Date,f=s.now();e.unstable_now=function(){return s.now()-f}}var m=[],d=[],p=1,v=null,b=3,x=!1,S=!1,w=!1,j=!1,E=typeof setTimeout=="function"?setTimeout:null,O=typeof clearTimeout=="function"?clearTimeout:null,N=typeof setImmediate<"u"?setImmediate:null;function G(A){for(var q=i(d);q!==null;){if(q.callback===null)l(d);else if(q.startTime<=A)l(d),q.sortIndex=q.expirationTime,t(m,q);else break;q=i(d)}}function J(A){if(w=!1,G(A),!S)if(i(m)!==null)S=!0,R||(R=!0,ce());else{var q=i(d);q!==null&&U(J,q.startTime-A)}}var R=!1,X=-1,Q=5,me=-1;function B(){return j?!0:!(e.unstable_now()-me<Q)}function ue(){if(j=!1,R){var A=e.unstable_now();me=A;var q=!0;try{e:{S=!1,w&&(w=!1,O(X),X=-1),x=!0;var te=b;try{t:{for(G(A),v=i(m);v!==null&&!(v.expirationTime>A&&B());){var ie=v.callback;if(typeof ie=="function"){v.callback=null,b=v.priorityLevel;var z=ie(v.expirationTime<=A);if(A=e.unstable_now(),typeof z=="function"){v.callback=z,G(A),q=!0;break t}v===i(m)&&l(m),G(A)}else l(m);v=i(m)}if(v!==null)q=!0;else{var T=i(d);T!==null&&U(J,T.startTime-A),q=!1}}break e}finally{v=null,b=te,x=!1}q=void 0}}finally{q?ce():R=!1}}}var ce;if(typeof N=="function")ce=function(){N(ue)};else if(typeof MessageChannel<"u"){var ke=new MessageChannel,M=ke.port2;ke.port1.onmessage=ue,ce=function(){M.postMessage(null)}}else ce=function(){E(ue,0)};function U(A,q){X=E(function(){A(e.unstable_now())},q)}e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(A){A.callback=null},e.unstable_forceFrameRate=function(A){0>A||125<A?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):Q=0<A?Math.floor(1e3/A):5},e.unstable_getCurrentPriorityLevel=function(){return b},e.unstable_next=function(A){switch(b){case 1:case 2:case 3:var q=3;break;default:q=b}var te=b;b=q;try{return A()}finally{b=te}},e.unstable_requestPaint=function(){j=!0},e.unstable_runWithPriority=function(A,q){switch(A){case 1:case 2:case 3:case 4:case 5:break;default:A=3}var te=b;b=A;try{return q()}finally{b=te}},e.unstable_scheduleCallback=function(A,q,te){var ie=e.unstable_now();switch(typeof te=="object"&&te!==null?(te=te.delay,te=typeof te=="number"&&0<te?ie+te:ie):te=ie,A){case 1:var z=-1;break;case 2:z=250;break;case 5:z=1073741823;break;case 4:z=1e4;break;default:z=5e3}return z=te+z,A={id:p++,callback:q,priorityLevel:A,startTime:te,expirationTime:z,sortIndex:-1},te>ie?(A.sortIndex=te,t(d,A),i(m)===null&&A===i(d)&&(w?(O(X),X=-1):w=!0,U(J,te-ie))):(A.sortIndex=z,t(m,A),S||x||(S=!0,R||(R=!0,ce()))),A},e.unstable_shouldYield=B,e.unstable_wrapCallback=function(A){var q=b;return function(){var te=b;b=q;try{return A.apply(this,arguments)}finally{b=te}}}})(Sm)),Sm}var Mx;function xO(){return Mx||(Mx=1,_m.exports=bO()),_m.exports}var km={exports:{}},Dt={};var Px;function _O(){if(Px)return Dt;Px=1;var e=dp();function t(m){var d="https://react.dev/errors/"+m;if(1<arguments.length){d+="?args[]="+encodeURIComponent(arguments[1]);for(var p=2;p<arguments.length;p++)d+="&args[]="+encodeURIComponent(arguments[p])}return"Minified React error #"+m+"; visit "+d+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function i(){}var l={d:{f:i,r:function(){throw Error(t(522))},D:i,C:i,L:i,m:i,X:i,S:i,M:i},p:0,findDOMNode:null},n=Symbol.for("react.portal");function o(m,d,p){var v=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:n,key:v==null?null:""+v,children:m,containerInfo:d,implementation:p}}var s=e.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function f(m,d){if(m==="font")return"";if(typeof d=="string")return d==="use-credentials"?d:""}return Dt.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=l,Dt.createPortal=function(m,d){var p=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!d||d.nodeType!==1&&d.nodeType!==9&&d.nodeType!==11)throw Error(t(299));return o(m,d,null,p)},Dt.flushSync=function(m){var d=s.T,p=l.p;try{if(s.T=null,l.p=2,m)return m()}finally{s.T=d,l.p=p,l.d.f()}},Dt.preconnect=function(m,d){typeof m=="string"&&(d?(d=d.crossOrigin,d=typeof d=="string"?d==="use-credentials"?d:"":void 0):d=null,l.d.C(m,d))},Dt.prefetchDNS=function(m){typeof m=="string"&&l.d.D(m)},Dt.preinit=function(m,d){if(typeof m=="string"&&d&&typeof d.as=="string"){var p=d.as,v=f(p,d.crossOrigin),b=typeof d.integrity=="string"?d.integrity:void 0,x=typeof d.fetchPriority=="string"?d.fetchPriority:void 0;p==="style"?l.d.S(m,typeof d.precedence=="string"?d.precedence:void 0,{crossOrigin:v,integrity:b,fetchPriority:x}):p==="script"&&l.d.X(m,{crossOrigin:v,integrity:b,fetchPriority:x,nonce:typeof d.nonce=="string"?d.nonce:void 0})}},Dt.preinitModule=function(m,d){if(typeof m=="string")if(typeof d=="object"&&d!==null){if(d.as==null||d.as==="script"){var p=f(d.as,d.crossOrigin);l.d.M(m,{crossOrigin:p,integrity:typeof d.integrity=="string"?d.integrity:void 0,nonce:typeof d.nonce=="string"?d.nonce:void 0})}}else d==null&&l.d.M(m)},Dt.preload=function(m,d){if(typeof m=="string"&&typeof d=="object"&&d!==null&&typeof d.as=="string"){var p=d.as,v=f(p,d.crossOrigin);l.d.L(m,p,{crossOrigin:v,integrity:typeof d.integrity=="string"?d.integrity:void 0,nonce:typeof d.nonce=="string"?d.nonce:void 0,type:typeof d.type=="string"?d.type:void 0,fetchPriority:typeof d.fetchPriority=="string"?d.fetchPriority:void 0,referrerPolicy:typeof d.referrerPolicy=="string"?d.referrerPolicy:void 0,imageSrcSet:typeof d.imageSrcSet=="string"?d.imageSrcSet:void 0,imageSizes:typeof d.imageSizes=="string"?d.imageSizes:void 0,media:typeof d.media=="string"?d.media:void 0})}},Dt.preloadModule=function(m,d){if(typeof m=="string")if(d){var p=f(d.as,d.crossOrigin);l.d.m(m,{as:typeof d.as=="string"&&d.as!=="script"?d.as:void 0,crossOrigin:p,integrity:typeof d.integrity=="string"?d.integrity:void 0})}else l.d.m(m)},Dt.requestFormReset=function(m){l.d.r(m)},Dt.unstable_batchedUpdates=function(m,d){return m(d)},Dt.useFormState=function(m,d,p){return s.H.useFormState(m,d,p)},Dt.useFormStatus=function(){return s.H.useHostTransitionStatus()},Dt.version="19.2.3",Dt}var Zx;function SO(){if(Zx)return km.exports;Zx=1;function e(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e)}catch(t){console.error(t)}}return e(),km.exports=_O(),km.exports}var qx;function kO(){if(qx)return eo;qx=1;var e=xO(),t=dp(),i=SO();function l(r){var a="https://react.dev/errors/"+r;if(1<arguments.length){a+="?args[]="+encodeURIComponent(arguments[1]);for(var u=2;u<arguments.length;u++)a+="&args[]="+encodeURIComponent(arguments[u])}return"Minified React error #"+r+"; visit "+a+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function n(r){return!(!r||r.nodeType!==1&&r.nodeType!==9&&r.nodeType!==11)}function o(r){var a=r,u=r;if(r.alternate)for(;a.return;)a=a.return;else{r=a;do a=r,(a.flags&4098)!==0&&(u=a.return),r=a.return;while(r)}return a.tag===3?u:null}function s(r){if(r.tag===13){var a=r.memoizedState;if(a===null&&(r=r.alternate,r!==null&&(a=r.memoizedState)),a!==null)return a.dehydrated}return null}function f(r){if(r.tag===31){var a=r.memoizedState;if(a===null&&(r=r.alternate,r!==null&&(a=r.memoizedState)),a!==null)return a.dehydrated}return null}function m(r){if(o(r)!==r)throw Error(l(188))}function d(r){var a=r.alternate;if(!a){if(a=o(r),a===null)throw Error(l(188));return a!==r?null:r}for(var u=r,c=a;;){var h=u.return;if(h===null)break;var g=h.alternate;if(g===null){if(c=h.return,c!==null){u=c;continue}break}if(h.child===g.child){for(g=h.child;g;){if(g===u)return m(h),r;if(g===c)return m(h),a;g=g.sibling}throw Error(l(188))}if(u.return!==c.return)u=h,c=g;else{for(var _=!1,k=h.child;k;){if(k===u){_=!0,u=h,c=g;break}if(k===c){_=!0,c=h,u=g;break}k=k.sibling}if(!_){for(k=g.child;k;){if(k===u){_=!0,u=g,c=h;break}if(k===c){_=!0,c=g,u=h;break}k=k.sibling}if(!_)throw Error(l(189))}}if(u.alternate!==c)throw Error(l(190))}if(u.tag!==3)throw Error(l(188));return u.stateNode.current===u?r:a}function p(r){var a=r.tag;if(a===5||a===26||a===27||a===6)return r;for(r=r.child;r!==null;){if(a=p(r),a!==null)return a;r=r.sibling}return null}var v=Object.assign,b=Symbol.for("react.element"),x=Symbol.for("react.transitional.element"),S=Symbol.for("react.portal"),w=Symbol.for("react.fragment"),j=Symbol.for("react.strict_mode"),E=Symbol.for("react.profiler"),O=Symbol.for("react.consumer"),N=Symbol.for("react.context"),G=Symbol.for("react.forward_ref"),J=Symbol.for("react.suspense"),R=Symbol.for("react.suspense_list"),X=Symbol.for("react.memo"),Q=Symbol.for("react.lazy"),me=Symbol.for("react.activity"),B=Symbol.for("react.memo_cache_sentinel"),ue=Symbol.iterator;function ce(r){return r===null||typeof r!="object"?null:(r=ue&&r[ue]||r["@@iterator"],typeof r=="function"?r:null)}var ke=Symbol.for("react.client.reference");function M(r){if(r==null)return null;if(typeof r=="function")return r.$$typeof===ke?null:r.displayName||r.name||null;if(typeof r=="string")return r;switch(r){case w:return"Fragment";case E:return"Profiler";case j:return"StrictMode";case J:return"Suspense";case R:return"SuspenseList";case me:return"Activity"}if(typeof r=="object")switch(r.$$typeof){case S:return"Portal";case N:return r.displayName||"Context";case O:return(r._context.displayName||"Context")+".Consumer";case G:var a=r.render;return r=r.displayName,r||(r=a.displayName||a.name||"",r=r!==""?"ForwardRef("+r+")":"ForwardRef"),r;case X:return a=r.displayName||null,a!==null?a:M(r.type)||"Memo";case Q:a=r._payload,r=r._init;try{return M(r(a))}catch{}}return null}var U=Array.isArray,A=t.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,q=i.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,te={pending:!1,data:null,method:null,action:null},ie=[],z=-1;function T(r){return{current:r}}function Z(r){0>z||(r.current=ie[z],ie[z]=null,z--)}function $(r,a){z++,ie[z]=r.current,r.current=a}var oe=T(null),de=T(null),pe=T(null),Ie=T(null);function ot(r,a){switch($(pe,a),$(de,r),$(oe,null),a.nodeType){case 9:case 11:r=(r=a.documentElement)&&(r=r.namespaceURI)?rx(r):0;break;default:if(r=a.tagName,a=a.namespaceURI)a=rx(a),r=ix(a,r);else switch(r){case"svg":r=1;break;case"math":r=2;break;default:r=0}}Z(oe),$(oe,r)}function Ve(){Z(oe),Z(de),Z(pe)}function gn(r){r.memoizedState!==null&&$(Ie,r);var a=oe.current,u=ix(a,r.type);a!==u&&($(de,r),$(oe,u))}function rr(r){de.current===r&&(Z(oe),Z(de)),Ie.current===r&&(Z(Ie),Jl._currentValue=te)}var ll,eu;function ir(r){if(ll===void 0)try{throw Error()}catch(u){var a=u.stack.trim().match(/\n( *(at )?)/);ll=a&&a[1]||"",eu=-1<u.stack.indexOf(`
|
|
2
|
+
at`)?" (<anonymous>)":-1<u.stack.indexOf("@")?"@unknown:0:0":""}return`
|
|
3
|
+
`+ll+r+eu}var Gi=!1;function Vi(r,a){if(!r||Gi)return"";Gi=!0;var u=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var c={DetermineComponentFrameRoot:function(){try{if(a){var ne=function(){throw Error()};if(Object.defineProperty(ne.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(ne,[])}catch(Y){var V=Y}Reflect.construct(r,[],ne)}else{try{ne.call()}catch(Y){V=Y}r.call(ne.prototype)}}else{try{throw Error()}catch(Y){V=Y}(ne=r())&&typeof ne.catch=="function"&&ne.catch(function(){})}}catch(Y){if(Y&&V&&typeof Y.stack=="string")return[Y.stack,V.stack]}return[null,null]}};c.DetermineComponentFrameRoot.displayName="DetermineComponentFrameRoot";var h=Object.getOwnPropertyDescriptor(c.DetermineComponentFrameRoot,"name");h&&h.configurable&&Object.defineProperty(c.DetermineComponentFrameRoot,"name",{value:"DetermineComponentFrameRoot"});var g=c.DetermineComponentFrameRoot(),_=g[0],k=g[1];if(_&&k){var D=_.split(`
|
|
4
|
+
`),H=k.split(`
|
|
5
|
+
`);for(h=c=0;c<D.length&&!D[c].includes("DetermineComponentFrameRoot");)c++;for(;h<H.length&&!H[h].includes("DetermineComponentFrameRoot");)h++;if(c===D.length||h===H.length)for(c=D.length-1,h=H.length-1;1<=c&&0<=h&&D[c]!==H[h];)h--;for(;1<=c&&0<=h;c--,h--)if(D[c]!==H[h]){if(c!==1||h!==1)do if(c--,h--,0>h||D[c]!==H[h]){var K=`
|
|
6
|
+
`+D[c].replace(" at new "," at ");return r.displayName&&K.includes("<anonymous>")&&(K=K.replace("<anonymous>",r.displayName)),K}while(1<=c&&0<=h);break}}}finally{Gi=!1,Error.prepareStackTrace=u}return(u=r?r.displayName||r.name:"")?ir(u):""}function tu(r,a){switch(r.tag){case 26:case 27:case 5:return ir(r.type);case 16:return ir("Lazy");case 13:return r.child!==a&&a!==null?ir("Suspense Fallback"):ir("Suspense");case 19:return ir("SuspenseList");case 0:case 15:return Vi(r.type,!1);case 11:return Vi(r.type.render,!1);case 1:return Vi(r.type,!0);case 31:return ir("Activity");default:return""}}function nu(r){try{var a="",u=null;do a+=tu(r,u),u=r,r=r.return;while(r);return a}catch(c){return`
|
|
7
|
+
Error generating stack: `+c.message+`
|
|
8
|
+
`+c.stack}}var Yi=Object.prototype.hasOwnProperty,Ji=e.unstable_scheduleCallback,ol=e.unstable_cancelCallback,nf=e.unstable_shouldYield,rf=e.unstable_requestPaint,Lt=e.unstable_now,af=e.unstable_getCurrentPriorityLevel,W=e.unstable_ImmediatePriority,se=e.unstable_UserBlockingPriority,_e=e.unstable_NormalPriority,Ce=e.unstable_LowPriority,Be=e.unstable_IdlePriority,nn=e.log,ar=e.unstable_setDisableYieldValue,Mt=null,St=null;function Ht(r){if(typeof nn=="function"&&ar(r),St&&typeof St.setStrictMode=="function")try{St.setStrictMode(Mt,r)}catch{}}var Qe=Math.clz32?Math.clz32:tN,Cr=Math.log,In=Math.LN2;function tN(r){return r>>>=0,r===0?32:31-(Cr(r)/In|0)|0}var ru=256,iu=262144,au=4194304;function di(r){var a=r&42;if(a!==0)return a;switch(r&-r){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 r&261888;case 262144:case 524288:case 1048576:case 2097152:return r&3932160;case 4194304:case 8388608:case 16777216:case 33554432:return r&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return r}}function lu(r,a,u){var c=r.pendingLanes;if(c===0)return 0;var h=0,g=r.suspendedLanes,_=r.pingedLanes;r=r.warmLanes;var k=c&134217727;return k!==0?(c=k&~g,c!==0?h=di(c):(_&=k,_!==0?h=di(_):u||(u=k&~r,u!==0&&(h=di(u))))):(k=c&~g,k!==0?h=di(k):_!==0?h=di(_):u||(u=c&~r,u!==0&&(h=di(u)))),h===0?0:a!==0&&a!==h&&(a&g)===0&&(g=h&-h,u=a&-a,g>=u||g===32&&(u&4194048)!==0)?a:h}function ul(r,a){return(r.pendingLanes&~(r.suspendedLanes&~r.pingedLanes)&a)===0}function nN(r,a){switch(r){case 1:case 2:case 4:case 8:case 64:return a+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 a+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 Lv(){var r=au;return au<<=1,(au&62914560)===0&&(au=4194304),r}function lf(r){for(var a=[],u=0;31>u;u++)a.push(r);return a}function sl(r,a){r.pendingLanes|=a,a!==268435456&&(r.suspendedLanes=0,r.pingedLanes=0,r.warmLanes=0)}function rN(r,a,u,c,h,g){var _=r.pendingLanes;r.pendingLanes=u,r.suspendedLanes=0,r.pingedLanes=0,r.warmLanes=0,r.expiredLanes&=u,r.entangledLanes&=u,r.errorRecoveryDisabledLanes&=u,r.shellSuspendCounter=0;var k=r.entanglements,D=r.expirationTimes,H=r.hiddenUpdates;for(u=_&~u;0<u;){var K=31-Qe(u),ne=1<<K;k[K]=0,D[K]=-1;var V=H[K];if(V!==null)for(H[K]=null,K=0;K<V.length;K++){var Y=V[K];Y!==null&&(Y.lane&=-536870913)}u&=~ne}c!==0&&Mv(r,c,0),g!==0&&h===0&&r.tag!==0&&(r.suspendedLanes|=g&~(_&~a))}function Mv(r,a,u){r.pendingLanes|=a,r.suspendedLanes&=~a;var c=31-Qe(a);r.entangledLanes|=a,r.entanglements[c]=r.entanglements[c]|1073741824|u&261930}function Pv(r,a){var u=r.entangledLanes|=a;for(r=r.entanglements;u;){var c=31-Qe(u),h=1<<c;h&a|r[c]&a&&(r[c]|=a),u&=~h}}function Zv(r,a){var u=a&-a;return u=(u&42)!==0?1:of(u),(u&(r.suspendedLanes|a))!==0?0:u}function of(r){switch(r){case 2:r=1;break;case 8:r=4;break;case 32:r=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:r=128;break;case 268435456:r=134217728;break;default:r=0}return r}function uf(r){return r&=-r,2<r?8<r?(r&134217727)!==0?32:268435456:8:2}function qv(){var r=q.p;return r!==0?r:(r=window.event,r===void 0?32:jx(r.type))}function Fv(r,a){var u=q.p;try{return q.p=r,a()}finally{q.p=u}}var Dr=Math.random().toString(36).slice(2),zt="__reactFiber$"+Dr,Gt="__reactProps$"+Dr,Xi="__reactContainer$"+Dr,sf="__reactEvents$"+Dr,iN="__reactListeners$"+Dr,aN="__reactHandles$"+Dr,Bv="__reactResources$"+Dr,cl="__reactMarker$"+Dr;function cf(r){delete r[zt],delete r[Gt],delete r[sf],delete r[iN],delete r[aN]}function Qi(r){var a=r[zt];if(a)return a;for(var u=r.parentNode;u;){if(a=u[Xi]||u[zt]){if(u=a.alternate,a.child!==null||u!==null&&u.child!==null)for(r=fx(r);r!==null;){if(u=r[zt])return u;r=fx(r)}return a}r=u,u=r.parentNode}return null}function Ki(r){if(r=r[zt]||r[Xi]){var a=r.tag;if(a===5||a===6||a===13||a===31||a===26||a===27||a===3)return r}return null}function fl(r){var a=r.tag;if(a===5||a===26||a===27||a===6)return r.stateNode;throw Error(l(33))}function Wi(r){var a=r[Bv];return a||(a=r[Bv]={hoistableStyles:new Map,hoistableScripts:new Map}),a}function $t(r){r[cl]=!0}var Hv=new Set,Gv={};function mi(r,a){ea(r,a),ea(r+"Capture",a)}function ea(r,a){for(Gv[r]=a,r=0;r<a.length;r++)Hv.add(a[r])}var lN=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]*$"),Vv={},Yv={};function oN(r){return Yi.call(Yv,r)?!0:Yi.call(Vv,r)?!1:lN.test(r)?Yv[r]=!0:(Vv[r]=!0,!1)}function ou(r,a,u){if(oN(a))if(u===null)r.removeAttribute(a);else{switch(typeof u){case"undefined":case"function":case"symbol":r.removeAttribute(a);return;case"boolean":var c=a.toLowerCase().slice(0,5);if(c!=="data-"&&c!=="aria-"){r.removeAttribute(a);return}}r.setAttribute(a,""+u)}}function uu(r,a,u){if(u===null)r.removeAttribute(a);else{switch(typeof u){case"undefined":case"function":case"symbol":case"boolean":r.removeAttribute(a);return}r.setAttribute(a,""+u)}}function lr(r,a,u,c){if(c===null)r.removeAttribute(u);else{switch(typeof c){case"undefined":case"function":case"symbol":case"boolean":r.removeAttribute(u);return}r.setAttributeNS(a,u,""+c)}}function vn(r){switch(typeof r){case"bigint":case"boolean":case"number":case"string":case"undefined":return r;case"object":return r;default:return""}}function Jv(r){var a=r.type;return(r=r.nodeName)&&r.toLowerCase()==="input"&&(a==="checkbox"||a==="radio")}function uN(r,a,u){var c=Object.getOwnPropertyDescriptor(r.constructor.prototype,a);if(!r.hasOwnProperty(a)&&typeof c<"u"&&typeof c.get=="function"&&typeof c.set=="function"){var h=c.get,g=c.set;return Object.defineProperty(r,a,{configurable:!0,get:function(){return h.call(this)},set:function(_){u=""+_,g.call(this,_)}}),Object.defineProperty(r,a,{enumerable:c.enumerable}),{getValue:function(){return u},setValue:function(_){u=""+_},stopTracking:function(){r._valueTracker=null,delete r[a]}}}}function ff(r){if(!r._valueTracker){var a=Jv(r)?"checked":"value";r._valueTracker=uN(r,a,""+r[a])}}function Xv(r){if(!r)return!1;var a=r._valueTracker;if(!a)return!0;var u=a.getValue(),c="";return r&&(c=Jv(r)?r.checked?"true":"false":r.value),r=c,r!==u?(a.setValue(r),!0):!1}function su(r){if(r=r||(typeof document<"u"?document:void 0),typeof r>"u")return null;try{return r.activeElement||r.body}catch{return r.body}}var sN=/[\n"\\]/g;function yn(r){return r.replace(sN,function(a){return"\\"+a.charCodeAt(0).toString(16)+" "})}function df(r,a,u,c,h,g,_,k){r.name="",_!=null&&typeof _!="function"&&typeof _!="symbol"&&typeof _!="boolean"?r.type=_:r.removeAttribute("type"),a!=null?_==="number"?(a===0&&r.value===""||r.value!=a)&&(r.value=""+vn(a)):r.value!==""+vn(a)&&(r.value=""+vn(a)):_!=="submit"&&_!=="reset"||r.removeAttribute("value"),a!=null?mf(r,_,vn(a)):u!=null?mf(r,_,vn(u)):c!=null&&r.removeAttribute("value"),h==null&&g!=null&&(r.defaultChecked=!!g),h!=null&&(r.checked=h&&typeof h!="function"&&typeof h!="symbol"),k!=null&&typeof k!="function"&&typeof k!="symbol"&&typeof k!="boolean"?r.name=""+vn(k):r.removeAttribute("name")}function Qv(r,a,u,c,h,g,_,k){if(g!=null&&typeof g!="function"&&typeof g!="symbol"&&typeof g!="boolean"&&(r.type=g),a!=null||u!=null){if(!(g!=="submit"&&g!=="reset"||a!=null)){ff(r);return}u=u!=null?""+vn(u):"",a=a!=null?""+vn(a):u,k||a===r.value||(r.value=a),r.defaultValue=a}c=c??h,c=typeof c!="function"&&typeof c!="symbol"&&!!c,r.checked=k?r.checked:!!c,r.defaultChecked=!!c,_!=null&&typeof _!="function"&&typeof _!="symbol"&&typeof _!="boolean"&&(r.name=_),ff(r)}function mf(r,a,u){a==="number"&&su(r.ownerDocument)===r||r.defaultValue===""+u||(r.defaultValue=""+u)}function ta(r,a,u,c){if(r=r.options,a){a={};for(var h=0;h<u.length;h++)a["$"+u[h]]=!0;for(u=0;u<r.length;u++)h=a.hasOwnProperty("$"+r[u].value),r[u].selected!==h&&(r[u].selected=h),h&&c&&(r[u].defaultSelected=!0)}else{for(u=""+vn(u),a=null,h=0;h<r.length;h++){if(r[h].value===u){r[h].selected=!0,c&&(r[h].defaultSelected=!0);return}a!==null||r[h].disabled||(a=r[h])}a!==null&&(a.selected=!0)}}function Kv(r,a,u){if(a!=null&&(a=""+vn(a),a!==r.value&&(r.value=a),u==null)){r.defaultValue!==a&&(r.defaultValue=a);return}r.defaultValue=u!=null?""+vn(u):""}function Wv(r,a,u,c){if(a==null){if(c!=null){if(u!=null)throw Error(l(92));if(U(c)){if(1<c.length)throw Error(l(93));c=c[0]}u=c}u==null&&(u=""),a=u}u=vn(a),r.defaultValue=u,c=r.textContent,c===u&&c!==""&&c!==null&&(r.value=c),ff(r)}function na(r,a){if(a){var u=r.firstChild;if(u&&u===r.lastChild&&u.nodeType===3){u.nodeValue=a;return}}r.textContent=a}var cN=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 ey(r,a,u){var c=a.indexOf("--")===0;u==null||typeof u=="boolean"||u===""?c?r.setProperty(a,""):a==="float"?r.cssFloat="":r[a]="":c?r.setProperty(a,u):typeof u!="number"||u===0||cN.has(a)?a==="float"?r.cssFloat=u:r[a]=(""+u).trim():r[a]=u+"px"}function ty(r,a,u){if(a!=null&&typeof a!="object")throw Error(l(62));if(r=r.style,u!=null){for(var c in u)!u.hasOwnProperty(c)||a!=null&&a.hasOwnProperty(c)||(c.indexOf("--")===0?r.setProperty(c,""):c==="float"?r.cssFloat="":r[c]="");for(var h in a)c=a[h],a.hasOwnProperty(h)&&u[h]!==c&&ey(r,h,c)}else for(var g in a)a.hasOwnProperty(g)&&ey(r,g,a[g])}function hf(r){if(r.indexOf("-")===-1)return!1;switch(r){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 fN=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"]]),dN=/^[\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 cu(r){return dN.test(""+r)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":r}function or(){}var pf=null;function gf(r){return r=r.target||r.srcElement||window,r.correspondingUseElement&&(r=r.correspondingUseElement),r.nodeType===3?r.parentNode:r}var ra=null,ia=null;function ny(r){var a=Ki(r);if(a&&(r=a.stateNode)){var u=r[Gt]||null;e:switch(r=a.stateNode,a.type){case"input":if(df(r,u.value,u.defaultValue,u.defaultValue,u.checked,u.defaultChecked,u.type,u.name),a=u.name,u.type==="radio"&&a!=null){for(u=r;u.parentNode;)u=u.parentNode;for(u=u.querySelectorAll('input[name="'+yn(""+a)+'"][type="radio"]'),a=0;a<u.length;a++){var c=u[a];if(c!==r&&c.form===r.form){var h=c[Gt]||null;if(!h)throw Error(l(90));df(c,h.value,h.defaultValue,h.defaultValue,h.checked,h.defaultChecked,h.type,h.name)}}for(a=0;a<u.length;a++)c=u[a],c.form===r.form&&Xv(c)}break e;case"textarea":Kv(r,u.value,u.defaultValue);break e;case"select":a=u.value,a!=null&&ta(r,!!u.multiple,a,!1)}}}var vf=!1;function ry(r,a,u){if(vf)return r(a,u);vf=!0;try{var c=r(a);return c}finally{if(vf=!1,(ra!==null||ia!==null)&&(Qu(),ra&&(a=ra,r=ia,ia=ra=null,ny(a),r)))for(a=0;a<r.length;a++)ny(r[a])}}function dl(r,a){var u=r.stateNode;if(u===null)return null;var c=u[Gt]||null;if(c===null)return null;u=c[a];e:switch(a){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(c=!c.disabled)||(r=r.type,c=!(r==="button"||r==="input"||r==="select"||r==="textarea")),r=!c;break e;default:r=!1}if(r)return null;if(u&&typeof u!="function")throw Error(l(231,a,typeof u));return u}var ur=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),yf=!1;if(ur)try{var ml={};Object.defineProperty(ml,"passive",{get:function(){yf=!0}}),window.addEventListener("test",ml,ml),window.removeEventListener("test",ml,ml)}catch{yf=!1}var Ar=null,bf=null,fu=null;function iy(){if(fu)return fu;var r,a=bf,u=a.length,c,h="value"in Ar?Ar.value:Ar.textContent,g=h.length;for(r=0;r<u&&a[r]===h[r];r++);var _=u-r;for(c=1;c<=_&&a[u-c]===h[g-c];c++);return fu=h.slice(r,1<c?1-c:void 0)}function du(r){var a=r.keyCode;return"charCode"in r?(r=r.charCode,r===0&&a===13&&(r=13)):r=a,r===10&&(r=13),32<=r||r===13?r:0}function mu(){return!0}function ay(){return!1}function Vt(r){function a(u,c,h,g,_){this._reactName=u,this._targetInst=h,this.type=c,this.nativeEvent=g,this.target=_,this.currentTarget=null;for(var k in r)r.hasOwnProperty(k)&&(u=r[k],this[k]=u?u(g):g[k]);return this.isDefaultPrevented=(g.defaultPrevented!=null?g.defaultPrevented:g.returnValue===!1)?mu:ay,this.isPropagationStopped=ay,this}return v(a.prototype,{preventDefault:function(){this.defaultPrevented=!0;var u=this.nativeEvent;u&&(u.preventDefault?u.preventDefault():typeof u.returnValue!="unknown"&&(u.returnValue=!1),this.isDefaultPrevented=mu)},stopPropagation:function(){var u=this.nativeEvent;u&&(u.stopPropagation?u.stopPropagation():typeof u.cancelBubble!="unknown"&&(u.cancelBubble=!0),this.isPropagationStopped=mu)},persist:function(){},isPersistent:mu}),a}var hi={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(r){return r.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},hu=Vt(hi),hl=v({},hi,{view:0,detail:0}),mN=Vt(hl),xf,_f,pl,pu=v({},hl,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:kf,button:0,buttons:0,relatedTarget:function(r){return r.relatedTarget===void 0?r.fromElement===r.srcElement?r.toElement:r.fromElement:r.relatedTarget},movementX:function(r){return"movementX"in r?r.movementX:(r!==pl&&(pl&&r.type==="mousemove"?(xf=r.screenX-pl.screenX,_f=r.screenY-pl.screenY):_f=xf=0,pl=r),xf)},movementY:function(r){return"movementY"in r?r.movementY:_f}}),ly=Vt(pu),hN=v({},pu,{dataTransfer:0}),pN=Vt(hN),gN=v({},hl,{relatedTarget:0}),Sf=Vt(gN),vN=v({},hi,{animationName:0,elapsedTime:0,pseudoElement:0}),yN=Vt(vN),bN=v({},hi,{clipboardData:function(r){return"clipboardData"in r?r.clipboardData:window.clipboardData}}),xN=Vt(bN),_N=v({},hi,{data:0}),oy=Vt(_N),SN={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},kN={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"},wN={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function $N(r){var a=this.nativeEvent;return a.getModifierState?a.getModifierState(r):(r=wN[r])?!!a[r]:!1}function kf(){return $N}var EN=v({},hl,{key:function(r){if(r.key){var a=SN[r.key]||r.key;if(a!=="Unidentified")return a}return r.type==="keypress"?(r=du(r),r===13?"Enter":String.fromCharCode(r)):r.type==="keydown"||r.type==="keyup"?kN[r.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:kf,charCode:function(r){return r.type==="keypress"?du(r):0},keyCode:function(r){return r.type==="keydown"||r.type==="keyup"?r.keyCode:0},which:function(r){return r.type==="keypress"?du(r):r.type==="keydown"||r.type==="keyup"?r.keyCode:0}}),jN=Vt(EN),zN=v({},pu,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),uy=Vt(zN),NN=v({},hl,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:kf}),ON=Vt(NN),TN=v({},hi,{propertyName:0,elapsedTime:0,pseudoElement:0}),CN=Vt(TN),DN=v({},pu,{deltaX:function(r){return"deltaX"in r?r.deltaX:"wheelDeltaX"in r?-r.wheelDeltaX:0},deltaY:function(r){return"deltaY"in r?r.deltaY:"wheelDeltaY"in r?-r.wheelDeltaY:"wheelDelta"in r?-r.wheelDelta:0},deltaZ:0,deltaMode:0}),AN=Vt(DN),RN=v({},hi,{newState:0,oldState:0}),IN=Vt(RN),UN=[9,13,27,32],wf=ur&&"CompositionEvent"in window,gl=null;ur&&"documentMode"in document&&(gl=document.documentMode);var LN=ur&&"TextEvent"in window&&!gl,sy=ur&&(!wf||gl&&8<gl&&11>=gl),cy=" ",fy=!1;function dy(r,a){switch(r){case"keyup":return UN.indexOf(a.keyCode)!==-1;case"keydown":return a.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function my(r){return r=r.detail,typeof r=="object"&&"data"in r?r.data:null}var aa=!1;function MN(r,a){switch(r){case"compositionend":return my(a);case"keypress":return a.which!==32?null:(fy=!0,cy);case"textInput":return r=a.data,r===cy&&fy?null:r;default:return null}}function PN(r,a){if(aa)return r==="compositionend"||!wf&&dy(r,a)?(r=iy(),fu=bf=Ar=null,aa=!1,r):null;switch(r){case"paste":return null;case"keypress":if(!(a.ctrlKey||a.altKey||a.metaKey)||a.ctrlKey&&a.altKey){if(a.char&&1<a.char.length)return a.char;if(a.which)return String.fromCharCode(a.which)}return null;case"compositionend":return sy&&a.locale!=="ko"?null:a.data;default:return null}}var ZN={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 hy(r){var a=r&&r.nodeName&&r.nodeName.toLowerCase();return a==="input"?!!ZN[r.type]:a==="textarea"}function py(r,a,u,c){ra?ia?ia.push(c):ia=[c]:ra=c,a=is(a,"onChange"),0<a.length&&(u=new hu("onChange","change",null,u,c),r.push({event:u,listeners:a}))}var vl=null,yl=null;function qN(r){Q0(r,0)}function gu(r){var a=fl(r);if(Xv(a))return r}function gy(r,a){if(r==="change")return a}var vy=!1;if(ur){var $f;if(ur){var Ef="oninput"in document;if(!Ef){var yy=document.createElement("div");yy.setAttribute("oninput","return;"),Ef=typeof yy.oninput=="function"}$f=Ef}else $f=!1;vy=$f&&(!document.documentMode||9<document.documentMode)}function by(){vl&&(vl.detachEvent("onpropertychange",xy),yl=vl=null)}function xy(r){if(r.propertyName==="value"&&gu(yl)){var a=[];py(a,yl,r,gf(r)),ry(qN,a)}}function FN(r,a,u){r==="focusin"?(by(),vl=a,yl=u,vl.attachEvent("onpropertychange",xy)):r==="focusout"&&by()}function BN(r){if(r==="selectionchange"||r==="keyup"||r==="keydown")return gu(yl)}function HN(r,a){if(r==="click")return gu(a)}function GN(r,a){if(r==="input"||r==="change")return gu(a)}function VN(r,a){return r===a&&(r!==0||1/r===1/a)||r!==r&&a!==a}var rn=typeof Object.is=="function"?Object.is:VN;function bl(r,a){if(rn(r,a))return!0;if(typeof r!="object"||r===null||typeof a!="object"||a===null)return!1;var u=Object.keys(r),c=Object.keys(a);if(u.length!==c.length)return!1;for(c=0;c<u.length;c++){var h=u[c];if(!Yi.call(a,h)||!rn(r[h],a[h]))return!1}return!0}function _y(r){for(;r&&r.firstChild;)r=r.firstChild;return r}function Sy(r,a){var u=_y(r);r=0;for(var c;u;){if(u.nodeType===3){if(c=r+u.textContent.length,r<=a&&c>=a)return{node:u,offset:a-r};r=c}e:{for(;u;){if(u.nextSibling){u=u.nextSibling;break e}u=u.parentNode}u=void 0}u=_y(u)}}function ky(r,a){return r&&a?r===a?!0:r&&r.nodeType===3?!1:a&&a.nodeType===3?ky(r,a.parentNode):"contains"in r?r.contains(a):r.compareDocumentPosition?!!(r.compareDocumentPosition(a)&16):!1:!1}function wy(r){r=r!=null&&r.ownerDocument!=null&&r.ownerDocument.defaultView!=null?r.ownerDocument.defaultView:window;for(var a=su(r.document);a instanceof r.HTMLIFrameElement;){try{var u=typeof a.contentWindow.location.href=="string"}catch{u=!1}if(u)r=a.contentWindow;else break;a=su(r.document)}return a}function jf(r){var a=r&&r.nodeName&&r.nodeName.toLowerCase();return a&&(a==="input"&&(r.type==="text"||r.type==="search"||r.type==="tel"||r.type==="url"||r.type==="password")||a==="textarea"||r.contentEditable==="true")}var YN=ur&&"documentMode"in document&&11>=document.documentMode,la=null,zf=null,xl=null,Nf=!1;function $y(r,a,u){var c=u.window===u?u.document:u.nodeType===9?u:u.ownerDocument;Nf||la==null||la!==su(c)||(c=la,"selectionStart"in c&&jf(c)?c={start:c.selectionStart,end:c.selectionEnd}:(c=(c.ownerDocument&&c.ownerDocument.defaultView||window).getSelection(),c={anchorNode:c.anchorNode,anchorOffset:c.anchorOffset,focusNode:c.focusNode,focusOffset:c.focusOffset}),xl&&bl(xl,c)||(xl=c,c=is(zf,"onSelect"),0<c.length&&(a=new hu("onSelect","select",null,a,u),r.push({event:a,listeners:c}),a.target=la)))}function pi(r,a){var u={};return u[r.toLowerCase()]=a.toLowerCase(),u["Webkit"+r]="webkit"+a,u["Moz"+r]="moz"+a,u}var oa={animationend:pi("Animation","AnimationEnd"),animationiteration:pi("Animation","AnimationIteration"),animationstart:pi("Animation","AnimationStart"),transitionrun:pi("Transition","TransitionRun"),transitionstart:pi("Transition","TransitionStart"),transitioncancel:pi("Transition","TransitionCancel"),transitionend:pi("Transition","TransitionEnd")},Of={},Ey={};ur&&(Ey=document.createElement("div").style,"AnimationEvent"in window||(delete oa.animationend.animation,delete oa.animationiteration.animation,delete oa.animationstart.animation),"TransitionEvent"in window||delete oa.transitionend.transition);function gi(r){if(Of[r])return Of[r];if(!oa[r])return r;var a=oa[r],u;for(u in a)if(a.hasOwnProperty(u)&&u in Ey)return Of[r]=a[u];return r}var jy=gi("animationend"),zy=gi("animationiteration"),Ny=gi("animationstart"),JN=gi("transitionrun"),XN=gi("transitionstart"),QN=gi("transitioncancel"),Oy=gi("transitionend"),Ty=new Map,Tf="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(" ");Tf.push("scrollEnd");function Un(r,a){Ty.set(r,a),mi(a,[r])}var vu=typeof reportError=="function"?reportError:function(r){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var a=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof r=="object"&&r!==null&&typeof r.message=="string"?String(r.message):String(r),error:r});if(!window.dispatchEvent(a))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",r);return}console.error(r)},bn=[],ua=0,Cf=0;function yu(){for(var r=ua,a=Cf=ua=0;a<r;){var u=bn[a];bn[a++]=null;var c=bn[a];bn[a++]=null;var h=bn[a];bn[a++]=null;var g=bn[a];if(bn[a++]=null,c!==null&&h!==null){var _=c.pending;_===null?h.next=h:(h.next=_.next,_.next=h),c.pending=h}g!==0&&Cy(u,h,g)}}function bu(r,a,u,c){bn[ua++]=r,bn[ua++]=a,bn[ua++]=u,bn[ua++]=c,Cf|=c,r.lanes|=c,r=r.alternate,r!==null&&(r.lanes|=c)}function Df(r,a,u,c){return bu(r,a,u,c),xu(r)}function vi(r,a){return bu(r,null,null,a),xu(r)}function Cy(r,a,u){r.lanes|=u;var c=r.alternate;c!==null&&(c.lanes|=u);for(var h=!1,g=r.return;g!==null;)g.childLanes|=u,c=g.alternate,c!==null&&(c.childLanes|=u),g.tag===22&&(r=g.stateNode,r===null||r._visibility&1||(h=!0)),r=g,g=g.return;return r.tag===3?(g=r.stateNode,h&&a!==null&&(h=31-Qe(u),r=g.hiddenUpdates,c=r[h],c===null?r[h]=[a]:c.push(a),a.lane=u|536870912),g):null}function xu(r){if(50<ql)throw ql=0,qd=null,Error(l(185));for(var a=r.return;a!==null;)r=a,a=r.return;return r.tag===3?r.stateNode:null}var sa={};function KN(r,a,u,c){this.tag=r,this.key=u,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=a,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=c,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function an(r,a,u,c){return new KN(r,a,u,c)}function Af(r){return r=r.prototype,!(!r||!r.isReactComponent)}function sr(r,a){var u=r.alternate;return u===null?(u=an(r.tag,a,r.key,r.mode),u.elementType=r.elementType,u.type=r.type,u.stateNode=r.stateNode,u.alternate=r,r.alternate=u):(u.pendingProps=a,u.type=r.type,u.flags=0,u.subtreeFlags=0,u.deletions=null),u.flags=r.flags&65011712,u.childLanes=r.childLanes,u.lanes=r.lanes,u.child=r.child,u.memoizedProps=r.memoizedProps,u.memoizedState=r.memoizedState,u.updateQueue=r.updateQueue,a=r.dependencies,u.dependencies=a===null?null:{lanes:a.lanes,firstContext:a.firstContext},u.sibling=r.sibling,u.index=r.index,u.ref=r.ref,u.refCleanup=r.refCleanup,u}function Dy(r,a){r.flags&=65011714;var u=r.alternate;return u===null?(r.childLanes=0,r.lanes=a,r.child=null,r.subtreeFlags=0,r.memoizedProps=null,r.memoizedState=null,r.updateQueue=null,r.dependencies=null,r.stateNode=null):(r.childLanes=u.childLanes,r.lanes=u.lanes,r.child=u.child,r.subtreeFlags=0,r.deletions=null,r.memoizedProps=u.memoizedProps,r.memoizedState=u.memoizedState,r.updateQueue=u.updateQueue,r.type=u.type,a=u.dependencies,r.dependencies=a===null?null:{lanes:a.lanes,firstContext:a.firstContext}),r}function _u(r,a,u,c,h,g){var _=0;if(c=r,typeof r=="function")Af(r)&&(_=1);else if(typeof r=="string")_=rO(r,u,oe.current)?26:r==="html"||r==="head"||r==="body"?27:5;else e:switch(r){case me:return r=an(31,u,a,h),r.elementType=me,r.lanes=g,r;case w:return yi(u.children,h,g,a);case j:_=8,h|=24;break;case E:return r=an(12,u,a,h|2),r.elementType=E,r.lanes=g,r;case J:return r=an(13,u,a,h),r.elementType=J,r.lanes=g,r;case R:return r=an(19,u,a,h),r.elementType=R,r.lanes=g,r;default:if(typeof r=="object"&&r!==null)switch(r.$$typeof){case N:_=10;break e;case O:_=9;break e;case G:_=11;break e;case X:_=14;break e;case Q:_=16,c=null;break e}_=29,u=Error(l(130,r===null?"null":typeof r,"")),c=null}return a=an(_,u,a,h),a.elementType=r,a.type=c,a.lanes=g,a}function yi(r,a,u,c){return r=an(7,r,c,a),r.lanes=u,r}function Rf(r,a,u){return r=an(6,r,null,a),r.lanes=u,r}function Ay(r){var a=an(18,null,null,0);return a.stateNode=r,a}function If(r,a,u){return a=an(4,r.children!==null?r.children:[],r.key,a),a.lanes=u,a.stateNode={containerInfo:r.containerInfo,pendingChildren:null,implementation:r.implementation},a}var Ry=new WeakMap;function xn(r,a){if(typeof r=="object"&&r!==null){var u=Ry.get(r);return u!==void 0?u:(a={value:r,source:a,stack:nu(a)},Ry.set(r,a),a)}return{value:r,source:a,stack:nu(a)}}var ca=[],fa=0,Su=null,_l=0,_n=[],Sn=0,Rr=null,Gn=1,Vn="";function cr(r,a){ca[fa++]=_l,ca[fa++]=Su,Su=r,_l=a}function Iy(r,a,u){_n[Sn++]=Gn,_n[Sn++]=Vn,_n[Sn++]=Rr,Rr=r;var c=Gn;r=Vn;var h=32-Qe(c)-1;c&=~(1<<h),u+=1;var g=32-Qe(a)+h;if(30<g){var _=h-h%5;g=(c&(1<<_)-1).toString(32),c>>=_,h-=_,Gn=1<<32-Qe(a)+h|u<<h|c,Vn=g+r}else Gn=1<<g|u<<h|c,Vn=r}function Uf(r){r.return!==null&&(cr(r,1),Iy(r,1,0))}function Lf(r){for(;r===Su;)Su=ca[--fa],ca[fa]=null,_l=ca[--fa],ca[fa]=null;for(;r===Rr;)Rr=_n[--Sn],_n[Sn]=null,Vn=_n[--Sn],_n[Sn]=null,Gn=_n[--Sn],_n[Sn]=null}function Uy(r,a){_n[Sn++]=Gn,_n[Sn++]=Vn,_n[Sn++]=Rr,Gn=a.id,Vn=a.overflow,Rr=r}var Nt=null,it=null,Me=!1,Ir=null,kn=!1,Mf=Error(l(519));function Ur(r){var a=Error(l(418,1<arguments.length&&arguments[1]!==void 0&&arguments[1]?"text":"HTML",""));throw Sl(xn(a,r)),Mf}function Ly(r){var a=r.stateNode,u=r.type,c=r.memoizedProps;switch(a[zt]=r,a[Gt]=c,u){case"dialog":Ae("cancel",a),Ae("close",a);break;case"iframe":case"object":case"embed":Ae("load",a);break;case"video":case"audio":for(u=0;u<Bl.length;u++)Ae(Bl[u],a);break;case"source":Ae("error",a);break;case"img":case"image":case"link":Ae("error",a),Ae("load",a);break;case"details":Ae("toggle",a);break;case"input":Ae("invalid",a),Qv(a,c.value,c.defaultValue,c.checked,c.defaultChecked,c.type,c.name,!0);break;case"select":Ae("invalid",a);break;case"textarea":Ae("invalid",a),Wv(a,c.value,c.defaultValue,c.children)}u=c.children,typeof u!="string"&&typeof u!="number"&&typeof u!="bigint"||a.textContent===""+u||c.suppressHydrationWarning===!0||tx(a.textContent,u)?(c.popover!=null&&(Ae("beforetoggle",a),Ae("toggle",a)),c.onScroll!=null&&Ae("scroll",a),c.onScrollEnd!=null&&Ae("scrollend",a),c.onClick!=null&&(a.onclick=or),a=!0):a=!1,a||Ur(r,!0)}function My(r){for(Nt=r.return;Nt;)switch(Nt.tag){case 5:case 31:case 13:kn=!1;return;case 27:case 3:kn=!0;return;default:Nt=Nt.return}}function da(r){if(r!==Nt)return!1;if(!Me)return My(r),Me=!0,!1;var a=r.tag,u;if((u=a!==3&&a!==27)&&((u=a===5)&&(u=r.type,u=!(u!=="form"&&u!=="button")||rm(r.type,r.memoizedProps)),u=!u),u&&it&&Ur(r),My(r),a===13){if(r=r.memoizedState,r=r!==null?r.dehydrated:null,!r)throw Error(l(317));it=cx(r)}else if(a===31){if(r=r.memoizedState,r=r!==null?r.dehydrated:null,!r)throw Error(l(317));it=cx(r)}else a===27?(a=it,Qr(r.type)?(r=um,um=null,it=r):it=a):it=Nt?$n(r.stateNode.nextSibling):null;return!0}function bi(){it=Nt=null,Me=!1}function Pf(){var r=Ir;return r!==null&&(Qt===null?Qt=r:Qt.push.apply(Qt,r),Ir=null),r}function Sl(r){Ir===null?Ir=[r]:Ir.push(r)}var Zf=T(null),xi=null,fr=null;function Lr(r,a,u){$(Zf,a._currentValue),a._currentValue=u}function dr(r){r._currentValue=Zf.current,Z(Zf)}function qf(r,a,u){for(;r!==null;){var c=r.alternate;if((r.childLanes&a)!==a?(r.childLanes|=a,c!==null&&(c.childLanes|=a)):c!==null&&(c.childLanes&a)!==a&&(c.childLanes|=a),r===u)break;r=r.return}}function Ff(r,a,u,c){var h=r.child;for(h!==null&&(h.return=r);h!==null;){var g=h.dependencies;if(g!==null){var _=h.child;g=g.firstContext;e:for(;g!==null;){var k=g;g=h;for(var D=0;D<a.length;D++)if(k.context===a[D]){g.lanes|=u,k=g.alternate,k!==null&&(k.lanes|=u),qf(g.return,u,r),c||(_=null);break e}g=k.next}}else if(h.tag===18){if(_=h.return,_===null)throw Error(l(341));_.lanes|=u,g=_.alternate,g!==null&&(g.lanes|=u),qf(_,u,r),_=null}else _=h.child;if(_!==null)_.return=h;else for(_=h;_!==null;){if(_===r){_=null;break}if(h=_.sibling,h!==null){h.return=_.return,_=h;break}_=_.return}h=_}}function ma(r,a,u,c){r=null;for(var h=a,g=!1;h!==null;){if(!g){if((h.flags&524288)!==0)g=!0;else if((h.flags&262144)!==0)break}if(h.tag===10){var _=h.alternate;if(_===null)throw Error(l(387));if(_=_.memoizedProps,_!==null){var k=h.type;rn(h.pendingProps.value,_.value)||(r!==null?r.push(k):r=[k])}}else if(h===Ie.current){if(_=h.alternate,_===null)throw Error(l(387));_.memoizedState.memoizedState!==h.memoizedState.memoizedState&&(r!==null?r.push(Jl):r=[Jl])}h=h.return}r!==null&&Ff(a,r,u,c),a.flags|=262144}function ku(r){for(r=r.firstContext;r!==null;){if(!rn(r.context._currentValue,r.memoizedValue))return!0;r=r.next}return!1}function _i(r){xi=r,fr=null,r=r.dependencies,r!==null&&(r.firstContext=null)}function Ot(r){return Py(xi,r)}function wu(r,a){return xi===null&&_i(r),Py(r,a)}function Py(r,a){var u=a._currentValue;if(a={context:a,memoizedValue:u,next:null},fr===null){if(r===null)throw Error(l(308));fr=a,r.dependencies={lanes:0,firstContext:a},r.flags|=524288}else fr=fr.next=a;return u}var WN=typeof AbortController<"u"?AbortController:function(){var r=[],a=this.signal={aborted:!1,addEventListener:function(u,c){r.push(c)}};this.abort=function(){a.aborted=!0,r.forEach(function(u){return u()})}},e2=e.unstable_scheduleCallback,t2=e.unstable_NormalPriority,vt={$$typeof:N,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function Bf(){return{controller:new WN,data:new Map,refCount:0}}function kl(r){r.refCount--,r.refCount===0&&e2(t2,function(){r.controller.abort()})}var wl=null,Hf=0,ha=0,pa=null;function n2(r,a){if(wl===null){var u=wl=[];Hf=0,ha=Yd(),pa={status:"pending",value:void 0,then:function(c){u.push(c)}}}return Hf++,a.then(Zy,Zy),a}function Zy(){if(--Hf===0&&wl!==null){pa!==null&&(pa.status="fulfilled");var r=wl;wl=null,ha=0,pa=null;for(var a=0;a<r.length;a++)(0,r[a])()}}function r2(r,a){var u=[],c={status:"pending",value:null,reason:null,then:function(h){u.push(h)}};return r.then(function(){c.status="fulfilled",c.value=a;for(var h=0;h<u.length;h++)(0,u[h])(a)},function(h){for(c.status="rejected",c.reason=h,h=0;h<u.length;h++)(0,u[h])(void 0)}),c}var qy=A.S;A.S=function(r,a){$0=Lt(),typeof a=="object"&&a!==null&&typeof a.then=="function"&&n2(r,a),qy!==null&&qy(r,a)};var Si=T(null);function Gf(){var r=Si.current;return r!==null?r:Ke.pooledCache}function $u(r,a){a===null?$(Si,Si.current):$(Si,a.pool)}function Fy(){var r=Gf();return r===null?null:{parent:vt._currentValue,pool:r}}var ga=Error(l(460)),Vf=Error(l(474)),Eu=Error(l(542)),ju={then:function(){}};function By(r){return r=r.status,r==="fulfilled"||r==="rejected"}function Hy(r,a,u){switch(u=r[u],u===void 0?r.push(a):u!==a&&(a.then(or,or),a=u),a.status){case"fulfilled":return a.value;case"rejected":throw r=a.reason,Vy(r),r;default:if(typeof a.status=="string")a.then(or,or);else{if(r=Ke,r!==null&&100<r.shellSuspendCounter)throw Error(l(482));r=a,r.status="pending",r.then(function(c){if(a.status==="pending"){var h=a;h.status="fulfilled",h.value=c}},function(c){if(a.status==="pending"){var h=a;h.status="rejected",h.reason=c}})}switch(a.status){case"fulfilled":return a.value;case"rejected":throw r=a.reason,Vy(r),r}throw wi=a,ga}}function ki(r){try{var a=r._init;return a(r._payload)}catch(u){throw u!==null&&typeof u=="object"&&typeof u.then=="function"?(wi=u,ga):u}}var wi=null;function Gy(){if(wi===null)throw Error(l(459));var r=wi;return wi=null,r}function Vy(r){if(r===ga||r===Eu)throw Error(l(483))}var va=null,$l=0;function zu(r){var a=$l;return $l+=1,va===null&&(va=[]),Hy(va,r,a)}function El(r,a){a=a.props.ref,r.ref=a!==void 0?a:null}function Nu(r,a){throw a.$$typeof===b?Error(l(525)):(r=Object.prototype.toString.call(a),Error(l(31,r==="[object Object]"?"object with keys {"+Object.keys(a).join(", ")+"}":r)))}function Yy(r){function a(L,I){if(r){var F=L.deletions;F===null?(L.deletions=[I],L.flags|=16):F.push(I)}}function u(L,I){if(!r)return null;for(;I!==null;)a(L,I),I=I.sibling;return null}function c(L){for(var I=new Map;L!==null;)L.key!==null?I.set(L.key,L):I.set(L.index,L),L=L.sibling;return I}function h(L,I){return L=sr(L,I),L.index=0,L.sibling=null,L}function g(L,I,F){return L.index=F,r?(F=L.alternate,F!==null?(F=F.index,F<I?(L.flags|=67108866,I):F):(L.flags|=67108866,I)):(L.flags|=1048576,I)}function _(L){return r&&L.alternate===null&&(L.flags|=67108866),L}function k(L,I,F,ee){return I===null||I.tag!==6?(I=Rf(F,L.mode,ee),I.return=L,I):(I=h(I,F),I.return=L,I)}function D(L,I,F,ee){var ve=F.type;return ve===w?K(L,I,F.props.children,ee,F.key):I!==null&&(I.elementType===ve||typeof ve=="object"&&ve!==null&&ve.$$typeof===Q&&ki(ve)===I.type)?(I=h(I,F.props),El(I,F),I.return=L,I):(I=_u(F.type,F.key,F.props,null,L.mode,ee),El(I,F),I.return=L,I)}function H(L,I,F,ee){return I===null||I.tag!==4||I.stateNode.containerInfo!==F.containerInfo||I.stateNode.implementation!==F.implementation?(I=If(F,L.mode,ee),I.return=L,I):(I=h(I,F.children||[]),I.return=L,I)}function K(L,I,F,ee,ve){return I===null||I.tag!==7?(I=yi(F,L.mode,ee,ve),I.return=L,I):(I=h(I,F),I.return=L,I)}function ne(L,I,F){if(typeof I=="string"&&I!==""||typeof I=="number"||typeof I=="bigint")return I=Rf(""+I,L.mode,F),I.return=L,I;if(typeof I=="object"&&I!==null){switch(I.$$typeof){case x:return F=_u(I.type,I.key,I.props,null,L.mode,F),El(F,I),F.return=L,F;case S:return I=If(I,L.mode,F),I.return=L,I;case Q:return I=ki(I),ne(L,I,F)}if(U(I)||ce(I))return I=yi(I,L.mode,F,null),I.return=L,I;if(typeof I.then=="function")return ne(L,zu(I),F);if(I.$$typeof===N)return ne(L,wu(L,I),F);Nu(L,I)}return null}function V(L,I,F,ee){var ve=I!==null?I.key:null;if(typeof F=="string"&&F!==""||typeof F=="number"||typeof F=="bigint")return ve!==null?null:k(L,I,""+F,ee);if(typeof F=="object"&&F!==null){switch(F.$$typeof){case x:return F.key===ve?D(L,I,F,ee):null;case S:return F.key===ve?H(L,I,F,ee):null;case Q:return F=ki(F),V(L,I,F,ee)}if(U(F)||ce(F))return ve!==null?null:K(L,I,F,ee,null);if(typeof F.then=="function")return V(L,I,zu(F),ee);if(F.$$typeof===N)return V(L,I,wu(L,F),ee);Nu(L,F)}return null}function Y(L,I,F,ee,ve){if(typeof ee=="string"&&ee!==""||typeof ee=="number"||typeof ee=="bigint")return L=L.get(F)||null,k(I,L,""+ee,ve);if(typeof ee=="object"&&ee!==null){switch(ee.$$typeof){case x:return L=L.get(ee.key===null?F:ee.key)||null,D(I,L,ee,ve);case S:return L=L.get(ee.key===null?F:ee.key)||null,H(I,L,ee,ve);case Q:return ee=ki(ee),Y(L,I,F,ee,ve)}if(U(ee)||ce(ee))return L=L.get(F)||null,K(I,L,ee,ve,null);if(typeof ee.then=="function")return Y(L,I,F,zu(ee),ve);if(ee.$$typeof===N)return Y(L,I,F,wu(I,ee),ve);Nu(I,ee)}return null}function he(L,I,F,ee){for(var ve=null,Ze=null,ge=I,Ne=I=0,Le=null;ge!==null&&Ne<F.length;Ne++){ge.index>Ne?(Le=ge,ge=null):Le=ge.sibling;var qe=V(L,ge,F[Ne],ee);if(qe===null){ge===null&&(ge=Le);break}r&&ge&&qe.alternate===null&&a(L,ge),I=g(qe,I,Ne),Ze===null?ve=qe:Ze.sibling=qe,Ze=qe,ge=Le}if(Ne===F.length)return u(L,ge),Me&&cr(L,Ne),ve;if(ge===null){for(;Ne<F.length;Ne++)ge=ne(L,F[Ne],ee),ge!==null&&(I=g(ge,I,Ne),Ze===null?ve=ge:Ze.sibling=ge,Ze=ge);return Me&&cr(L,Ne),ve}for(ge=c(ge);Ne<F.length;Ne++)Le=Y(ge,L,Ne,F[Ne],ee),Le!==null&&(r&&Le.alternate!==null&&ge.delete(Le.key===null?Ne:Le.key),I=g(Le,I,Ne),Ze===null?ve=Le:Ze.sibling=Le,Ze=Le);return r&&ge.forEach(function(ni){return a(L,ni)}),Me&&cr(L,Ne),ve}function be(L,I,F,ee){if(F==null)throw Error(l(151));for(var ve=null,Ze=null,ge=I,Ne=I=0,Le=null,qe=F.next();ge!==null&&!qe.done;Ne++,qe=F.next()){ge.index>Ne?(Le=ge,ge=null):Le=ge.sibling;var ni=V(L,ge,qe.value,ee);if(ni===null){ge===null&&(ge=Le);break}r&&ge&&ni.alternate===null&&a(L,ge),I=g(ni,I,Ne),Ze===null?ve=ni:Ze.sibling=ni,Ze=ni,ge=Le}if(qe.done)return u(L,ge),Me&&cr(L,Ne),ve;if(ge===null){for(;!qe.done;Ne++,qe=F.next())qe=ne(L,qe.value,ee),qe!==null&&(I=g(qe,I,Ne),Ze===null?ve=qe:Ze.sibling=qe,Ze=qe);return Me&&cr(L,Ne),ve}for(ge=c(ge);!qe.done;Ne++,qe=F.next())qe=Y(ge,L,Ne,qe.value,ee),qe!==null&&(r&&qe.alternate!==null&&ge.delete(qe.key===null?Ne:qe.key),I=g(qe,I,Ne),Ze===null?ve=qe:Ze.sibling=qe,Ze=qe);return r&&ge.forEach(function(hO){return a(L,hO)}),Me&&cr(L,Ne),ve}function Xe(L,I,F,ee){if(typeof F=="object"&&F!==null&&F.type===w&&F.key===null&&(F=F.props.children),typeof F=="object"&&F!==null){switch(F.$$typeof){case x:e:{for(var ve=F.key;I!==null;){if(I.key===ve){if(ve=F.type,ve===w){if(I.tag===7){u(L,I.sibling),ee=h(I,F.props.children),ee.return=L,L=ee;break e}}else if(I.elementType===ve||typeof ve=="object"&&ve!==null&&ve.$$typeof===Q&&ki(ve)===I.type){u(L,I.sibling),ee=h(I,F.props),El(ee,F),ee.return=L,L=ee;break e}u(L,I);break}else a(L,I);I=I.sibling}F.type===w?(ee=yi(F.props.children,L.mode,ee,F.key),ee.return=L,L=ee):(ee=_u(F.type,F.key,F.props,null,L.mode,ee),El(ee,F),ee.return=L,L=ee)}return _(L);case S:e:{for(ve=F.key;I!==null;){if(I.key===ve)if(I.tag===4&&I.stateNode.containerInfo===F.containerInfo&&I.stateNode.implementation===F.implementation){u(L,I.sibling),ee=h(I,F.children||[]),ee.return=L,L=ee;break e}else{u(L,I);break}else a(L,I);I=I.sibling}ee=If(F,L.mode,ee),ee.return=L,L=ee}return _(L);case Q:return F=ki(F),Xe(L,I,F,ee)}if(U(F))return he(L,I,F,ee);if(ce(F)){if(ve=ce(F),typeof ve!="function")throw Error(l(150));return F=ve.call(F),be(L,I,F,ee)}if(typeof F.then=="function")return Xe(L,I,zu(F),ee);if(F.$$typeof===N)return Xe(L,I,wu(L,F),ee);Nu(L,F)}return typeof F=="string"&&F!==""||typeof F=="number"||typeof F=="bigint"?(F=""+F,I!==null&&I.tag===6?(u(L,I.sibling),ee=h(I,F),ee.return=L,L=ee):(u(L,I),ee=Rf(F,L.mode,ee),ee.return=L,L=ee),_(L)):u(L,I)}return function(L,I,F,ee){try{$l=0;var ve=Xe(L,I,F,ee);return va=null,ve}catch(ge){if(ge===ga||ge===Eu)throw ge;var Ze=an(29,ge,null,L.mode);return Ze.lanes=ee,Ze.return=L,Ze}}}var $i=Yy(!0),Jy=Yy(!1),Mr=!1;function Yf(r){r.updateQueue={baseState:r.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function Jf(r,a){r=r.updateQueue,a.updateQueue===r&&(a.updateQueue={baseState:r.baseState,firstBaseUpdate:r.firstBaseUpdate,lastBaseUpdate:r.lastBaseUpdate,shared:r.shared,callbacks:null})}function Pr(r){return{lane:r,tag:0,payload:null,callback:null,next:null}}function Zr(r,a,u){var c=r.updateQueue;if(c===null)return null;if(c=c.shared,(Fe&2)!==0){var h=c.pending;return h===null?a.next=a:(a.next=h.next,h.next=a),c.pending=a,a=xu(r),Cy(r,null,u),a}return bu(r,c,a,u),xu(r)}function jl(r,a,u){if(a=a.updateQueue,a!==null&&(a=a.shared,(u&4194048)!==0)){var c=a.lanes;c&=r.pendingLanes,u|=c,a.lanes=u,Pv(r,u)}}function Xf(r,a){var u=r.updateQueue,c=r.alternate;if(c!==null&&(c=c.updateQueue,u===c)){var h=null,g=null;if(u=u.firstBaseUpdate,u!==null){do{var _={lane:u.lane,tag:u.tag,payload:u.payload,callback:null,next:null};g===null?h=g=_:g=g.next=_,u=u.next}while(u!==null);g===null?h=g=a:g=g.next=a}else h=g=a;u={baseState:c.baseState,firstBaseUpdate:h,lastBaseUpdate:g,shared:c.shared,callbacks:c.callbacks},r.updateQueue=u;return}r=u.lastBaseUpdate,r===null?u.firstBaseUpdate=a:r.next=a,u.lastBaseUpdate=a}var Qf=!1;function zl(){if(Qf){var r=pa;if(r!==null)throw r}}function Nl(r,a,u,c){Qf=!1;var h=r.updateQueue;Mr=!1;var g=h.firstBaseUpdate,_=h.lastBaseUpdate,k=h.shared.pending;if(k!==null){h.shared.pending=null;var D=k,H=D.next;D.next=null,_===null?g=H:_.next=H,_=D;var K=r.alternate;K!==null&&(K=K.updateQueue,k=K.lastBaseUpdate,k!==_&&(k===null?K.firstBaseUpdate=H:k.next=H,K.lastBaseUpdate=D))}if(g!==null){var ne=h.baseState;_=0,K=H=D=null,k=g;do{var V=k.lane&-536870913,Y=V!==k.lane;if(Y?(Ue&V)===V:(c&V)===V){V!==0&&V===ha&&(Qf=!0),K!==null&&(K=K.next={lane:0,tag:k.tag,payload:k.payload,callback:null,next:null});e:{var he=r,be=k;V=a;var Xe=u;switch(be.tag){case 1:if(he=be.payload,typeof he=="function"){ne=he.call(Xe,ne,V);break e}ne=he;break e;case 3:he.flags=he.flags&-65537|128;case 0:if(he=be.payload,V=typeof he=="function"?he.call(Xe,ne,V):he,V==null)break e;ne=v({},ne,V);break e;case 2:Mr=!0}}V=k.callback,V!==null&&(r.flags|=64,Y&&(r.flags|=8192),Y=h.callbacks,Y===null?h.callbacks=[V]:Y.push(V))}else Y={lane:V,tag:k.tag,payload:k.payload,callback:k.callback,next:null},K===null?(H=K=Y,D=ne):K=K.next=Y,_|=V;if(k=k.next,k===null){if(k=h.shared.pending,k===null)break;Y=k,k=Y.next,Y.next=null,h.lastBaseUpdate=Y,h.shared.pending=null}}while(!0);K===null&&(D=ne),h.baseState=D,h.firstBaseUpdate=H,h.lastBaseUpdate=K,g===null&&(h.shared.lanes=0),Gr|=_,r.lanes=_,r.memoizedState=ne}}function Xy(r,a){if(typeof r!="function")throw Error(l(191,r));r.call(a)}function Qy(r,a){var u=r.callbacks;if(u!==null)for(r.callbacks=null,r=0;r<u.length;r++)Xy(u[r],a)}var ya=T(null),Ou=T(0);function Ky(r,a){r=_r,$(Ou,r),$(ya,a),_r=r|a.baseLanes}function Kf(){$(Ou,_r),$(ya,ya.current)}function Wf(){_r=Ou.current,Z(ya),Z(Ou)}var ln=T(null),wn=null;function qr(r){var a=r.alternate;$(mt,mt.current&1),$(ln,r),wn===null&&(a===null||ya.current!==null||a.memoizedState!==null)&&(wn=r)}function ed(r){$(mt,mt.current),$(ln,r),wn===null&&(wn=r)}function Wy(r){r.tag===22?($(mt,mt.current),$(ln,r),wn===null&&(wn=r)):Fr()}function Fr(){$(mt,mt.current),$(ln,ln.current)}function on(r){Z(ln),wn===r&&(wn=null),Z(mt)}var mt=T(0);function Tu(r){for(var a=r;a!==null;){if(a.tag===13){var u=a.memoizedState;if(u!==null&&(u=u.dehydrated,u===null||lm(u)||om(u)))return a}else if(a.tag===19&&(a.memoizedProps.revealOrder==="forwards"||a.memoizedProps.revealOrder==="backwards"||a.memoizedProps.revealOrder==="unstable_legacy-backwards"||a.memoizedProps.revealOrder==="together")){if((a.flags&128)!==0)return a}else if(a.child!==null){a.child.return=a,a=a.child;continue}if(a===r)break;for(;a.sibling===null;){if(a.return===null||a.return===r)return null;a=a.return}a.sibling.return=a.return,a=a.sibling}return null}var mr=0,Ee=null,Ye=null,yt=null,Cu=!1,ba=!1,Ei=!1,Du=0,Ol=0,xa=null,i2=0;function ft(){throw Error(l(321))}function td(r,a){if(a===null)return!1;for(var u=0;u<a.length&&u<r.length;u++)if(!rn(r[u],a[u]))return!1;return!0}function nd(r,a,u,c,h,g){return mr=g,Ee=a,a.memoizedState=null,a.updateQueue=null,a.lanes=0,A.H=r===null||r.memoizedState===null?Ib:vd,Ei=!1,g=u(c,h),Ei=!1,ba&&(g=tb(a,u,c,h)),eb(r),g}function eb(r){A.H=Dl;var a=Ye!==null&&Ye.next!==null;if(mr=0,yt=Ye=Ee=null,Cu=!1,Ol=0,xa=null,a)throw Error(l(300));r===null||bt||(r=r.dependencies,r!==null&&ku(r)&&(bt=!0))}function tb(r,a,u,c){Ee=r;var h=0;do{if(ba&&(xa=null),Ol=0,ba=!1,25<=h)throw Error(l(301));if(h+=1,yt=Ye=null,r.updateQueue!=null){var g=r.updateQueue;g.lastEffect=null,g.events=null,g.stores=null,g.memoCache!=null&&(g.memoCache.index=0)}A.H=Ub,g=a(u,c)}while(ba);return g}function a2(){var r=A.H,a=r.useState()[0];return a=typeof a.then=="function"?Tl(a):a,r=r.useState()[0],(Ye!==null?Ye.memoizedState:null)!==r&&(Ee.flags|=1024),a}function rd(){var r=Du!==0;return Du=0,r}function id(r,a,u){a.updateQueue=r.updateQueue,a.flags&=-2053,r.lanes&=~u}function ad(r){if(Cu){for(r=r.memoizedState;r!==null;){var a=r.queue;a!==null&&(a.pending=null),r=r.next}Cu=!1}mr=0,yt=Ye=Ee=null,ba=!1,Ol=Du=0,xa=null}function Pt(){var r={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return yt===null?Ee.memoizedState=yt=r:yt=yt.next=r,yt}function ht(){if(Ye===null){var r=Ee.alternate;r=r!==null?r.memoizedState:null}else r=Ye.next;var a=yt===null?Ee.memoizedState:yt.next;if(a!==null)yt=a,Ye=r;else{if(r===null)throw Ee.alternate===null?Error(l(467)):Error(l(310));Ye=r,r={memoizedState:Ye.memoizedState,baseState:Ye.baseState,baseQueue:Ye.baseQueue,queue:Ye.queue,next:null},yt===null?Ee.memoizedState=yt=r:yt=yt.next=r}return yt}function Au(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function Tl(r){var a=Ol;return Ol+=1,xa===null&&(xa=[]),r=Hy(xa,r,a),a=Ee,(yt===null?a.memoizedState:yt.next)===null&&(a=a.alternate,A.H=a===null||a.memoizedState===null?Ib:vd),r}function Ru(r){if(r!==null&&typeof r=="object"){if(typeof r.then=="function")return Tl(r);if(r.$$typeof===N)return Ot(r)}throw Error(l(438,String(r)))}function ld(r){var a=null,u=Ee.updateQueue;if(u!==null&&(a=u.memoCache),a==null){var c=Ee.alternate;c!==null&&(c=c.updateQueue,c!==null&&(c=c.memoCache,c!=null&&(a={data:c.data.map(function(h){return h.slice()}),index:0})))}if(a==null&&(a={data:[],index:0}),u===null&&(u=Au(),Ee.updateQueue=u),u.memoCache=a,u=a.data[a.index],u===void 0)for(u=a.data[a.index]=Array(r),c=0;c<r;c++)u[c]=B;return a.index++,u}function hr(r,a){return typeof a=="function"?a(r):a}function Iu(r){var a=ht();return od(a,Ye,r)}function od(r,a,u){var c=r.queue;if(c===null)throw Error(l(311));c.lastRenderedReducer=u;var h=r.baseQueue,g=c.pending;if(g!==null){if(h!==null){var _=h.next;h.next=g.next,g.next=_}a.baseQueue=h=g,c.pending=null}if(g=r.baseState,h===null)r.memoizedState=g;else{a=h.next;var k=_=null,D=null,H=a,K=!1;do{var ne=H.lane&-536870913;if(ne!==H.lane?(Ue&ne)===ne:(mr&ne)===ne){var V=H.revertLane;if(V===0)D!==null&&(D=D.next={lane:0,revertLane:0,gesture:null,action:H.action,hasEagerState:H.hasEagerState,eagerState:H.eagerState,next:null}),ne===ha&&(K=!0);else if((mr&V)===V){H=H.next,V===ha&&(K=!0);continue}else ne={lane:0,revertLane:H.revertLane,gesture:null,action:H.action,hasEagerState:H.hasEagerState,eagerState:H.eagerState,next:null},D===null?(k=D=ne,_=g):D=D.next=ne,Ee.lanes|=V,Gr|=V;ne=H.action,Ei&&u(g,ne),g=H.hasEagerState?H.eagerState:u(g,ne)}else V={lane:ne,revertLane:H.revertLane,gesture:H.gesture,action:H.action,hasEagerState:H.hasEagerState,eagerState:H.eagerState,next:null},D===null?(k=D=V,_=g):D=D.next=V,Ee.lanes|=ne,Gr|=ne;H=H.next}while(H!==null&&H!==a);if(D===null?_=g:D.next=k,!rn(g,r.memoizedState)&&(bt=!0,K&&(u=pa,u!==null)))throw u;r.memoizedState=g,r.baseState=_,r.baseQueue=D,c.lastRenderedState=g}return h===null&&(c.lanes=0),[r.memoizedState,c.dispatch]}function ud(r){var a=ht(),u=a.queue;if(u===null)throw Error(l(311));u.lastRenderedReducer=r;var c=u.dispatch,h=u.pending,g=a.memoizedState;if(h!==null){u.pending=null;var _=h=h.next;do g=r(g,_.action),_=_.next;while(_!==h);rn(g,a.memoizedState)||(bt=!0),a.memoizedState=g,a.baseQueue===null&&(a.baseState=g),u.lastRenderedState=g}return[g,c]}function nb(r,a,u){var c=Ee,h=ht(),g=Me;if(g){if(u===void 0)throw Error(l(407));u=u()}else u=a();var _=!rn((Ye||h).memoizedState,u);if(_&&(h.memoizedState=u,bt=!0),h=h.queue,fd(ab.bind(null,c,h,r),[r]),h.getSnapshot!==a||_||yt!==null&&yt.memoizedState.tag&1){if(c.flags|=2048,_a(9,{destroy:void 0},ib.bind(null,c,h,u,a),null),Ke===null)throw Error(l(349));g||(mr&127)!==0||rb(c,a,u)}return u}function rb(r,a,u){r.flags|=16384,r={getSnapshot:a,value:u},a=Ee.updateQueue,a===null?(a=Au(),Ee.updateQueue=a,a.stores=[r]):(u=a.stores,u===null?a.stores=[r]:u.push(r))}function ib(r,a,u,c){a.value=u,a.getSnapshot=c,lb(a)&&ob(r)}function ab(r,a,u){return u(function(){lb(a)&&ob(r)})}function lb(r){var a=r.getSnapshot;r=r.value;try{var u=a();return!rn(r,u)}catch{return!0}}function ob(r){var a=vi(r,2);a!==null&&Kt(a,r,2)}function sd(r){var a=Pt();if(typeof r=="function"){var u=r;if(r=u(),Ei){Ht(!0);try{u()}finally{Ht(!1)}}}return a.memoizedState=a.baseState=r,a.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:hr,lastRenderedState:r},a}function ub(r,a,u,c){return r.baseState=u,od(r,Ye,typeof c=="function"?c:hr)}function l2(r,a,u,c,h){if(Mu(r))throw Error(l(485));if(r=a.action,r!==null){var g={payload:h,action:r,next:null,isTransition:!0,status:"pending",value:null,reason:null,listeners:[],then:function(_){g.listeners.push(_)}};A.T!==null?u(!0):g.isTransition=!1,c(g),u=a.pending,u===null?(g.next=a.pending=g,sb(a,g)):(g.next=u.next,a.pending=u.next=g)}}function sb(r,a){var u=a.action,c=a.payload,h=r.state;if(a.isTransition){var g=A.T,_={};A.T=_;try{var k=u(h,c),D=A.S;D!==null&&D(_,k),cb(r,a,k)}catch(H){cd(r,a,H)}finally{g!==null&&_.types!==null&&(g.types=_.types),A.T=g}}else try{g=u(h,c),cb(r,a,g)}catch(H){cd(r,a,H)}}function cb(r,a,u){u!==null&&typeof u=="object"&&typeof u.then=="function"?u.then(function(c){fb(r,a,c)},function(c){return cd(r,a,c)}):fb(r,a,u)}function fb(r,a,u){a.status="fulfilled",a.value=u,db(a),r.state=u,a=r.pending,a!==null&&(u=a.next,u===a?r.pending=null:(u=u.next,a.next=u,sb(r,u)))}function cd(r,a,u){var c=r.pending;if(r.pending=null,c!==null){c=c.next;do a.status="rejected",a.reason=u,db(a),a=a.next;while(a!==c)}r.action=null}function db(r){r=r.listeners;for(var a=0;a<r.length;a++)(0,r[a])()}function mb(r,a){return a}function hb(r,a){if(Me){var u=Ke.formState;if(u!==null){e:{var c=Ee;if(Me){if(it){t:{for(var h=it,g=kn;h.nodeType!==8;){if(!g){h=null;break t}if(h=$n(h.nextSibling),h===null){h=null;break t}}g=h.data,h=g==="F!"||g==="F"?h:null}if(h){it=$n(h.nextSibling),c=h.data==="F!";break e}}Ur(c)}c=!1}c&&(a=u[0])}}return u=Pt(),u.memoizedState=u.baseState=a,c={pending:null,lanes:0,dispatch:null,lastRenderedReducer:mb,lastRenderedState:a},u.queue=c,u=Db.bind(null,Ee,c),c.dispatch=u,c=sd(!1),g=gd.bind(null,Ee,!1,c.queue),c=Pt(),h={state:a,dispatch:null,action:r,pending:null},c.queue=h,u=l2.bind(null,Ee,h,g,u),h.dispatch=u,c.memoizedState=r,[a,u,!1]}function pb(r){var a=ht();return gb(a,Ye,r)}function gb(r,a,u){if(a=od(r,a,mb)[0],r=Iu(hr)[0],typeof a=="object"&&a!==null&&typeof a.then=="function")try{var c=Tl(a)}catch(_){throw _===ga?Eu:_}else c=a;a=ht();var h=a.queue,g=h.dispatch;return u!==a.memoizedState&&(Ee.flags|=2048,_a(9,{destroy:void 0},o2.bind(null,h,u),null)),[c,g,r]}function o2(r,a){r.action=a}function vb(r){var a=ht(),u=Ye;if(u!==null)return gb(a,u,r);ht(),a=a.memoizedState,u=ht();var c=u.queue.dispatch;return u.memoizedState=r,[a,c,!1]}function _a(r,a,u,c){return r={tag:r,create:u,deps:c,inst:a,next:null},a=Ee.updateQueue,a===null&&(a=Au(),Ee.updateQueue=a),u=a.lastEffect,u===null?a.lastEffect=r.next=r:(c=u.next,u.next=r,r.next=c,a.lastEffect=r),r}function yb(){return ht().memoizedState}function Uu(r,a,u,c){var h=Pt();Ee.flags|=r,h.memoizedState=_a(1|a,{destroy:void 0},u,c===void 0?null:c)}function Lu(r,a,u,c){var h=ht();c=c===void 0?null:c;var g=h.memoizedState.inst;Ye!==null&&c!==null&&td(c,Ye.memoizedState.deps)?h.memoizedState=_a(a,g,u,c):(Ee.flags|=r,h.memoizedState=_a(1|a,g,u,c))}function bb(r,a){Uu(8390656,8,r,a)}function fd(r,a){Lu(2048,8,r,a)}function u2(r){Ee.flags|=4;var a=Ee.updateQueue;if(a===null)a=Au(),Ee.updateQueue=a,a.events=[r];else{var u=a.events;u===null?a.events=[r]:u.push(r)}}function xb(r){var a=ht().memoizedState;return u2({ref:a,nextImpl:r}),function(){if((Fe&2)!==0)throw Error(l(440));return a.impl.apply(void 0,arguments)}}function _b(r,a){return Lu(4,2,r,a)}function Sb(r,a){return Lu(4,4,r,a)}function kb(r,a){if(typeof a=="function"){r=r();var u=a(r);return function(){typeof u=="function"?u():a(null)}}if(a!=null)return r=r(),a.current=r,function(){a.current=null}}function wb(r,a,u){u=u!=null?u.concat([r]):null,Lu(4,4,kb.bind(null,a,r),u)}function dd(){}function $b(r,a){var u=ht();a=a===void 0?null:a;var c=u.memoizedState;return a!==null&&td(a,c[1])?c[0]:(u.memoizedState=[r,a],r)}function Eb(r,a){var u=ht();a=a===void 0?null:a;var c=u.memoizedState;if(a!==null&&td(a,c[1]))return c[0];if(c=r(),Ei){Ht(!0);try{r()}finally{Ht(!1)}}return u.memoizedState=[c,a],c}function md(r,a,u){return u===void 0||(mr&1073741824)!==0&&(Ue&261930)===0?r.memoizedState=a:(r.memoizedState=u,r=j0(),Ee.lanes|=r,Gr|=r,u)}function jb(r,a,u,c){return rn(u,a)?u:ya.current!==null?(r=md(r,u,c),rn(r,a)||(bt=!0),r):(mr&42)===0||(mr&1073741824)!==0&&(Ue&261930)===0?(bt=!0,r.memoizedState=u):(r=j0(),Ee.lanes|=r,Gr|=r,a)}function zb(r,a,u,c,h){var g=q.p;q.p=g!==0&&8>g?g:8;var _=A.T,k={};A.T=k,gd(r,!1,a,u);try{var D=h(),H=A.S;if(H!==null&&H(k,D),D!==null&&typeof D=="object"&&typeof D.then=="function"){var K=r2(D,c);Cl(r,a,K,cn(r))}else Cl(r,a,c,cn(r))}catch(ne){Cl(r,a,{then:function(){},status:"rejected",reason:ne},cn())}finally{q.p=g,_!==null&&k.types!==null&&(_.types=k.types),A.T=_}}function s2(){}function hd(r,a,u,c){if(r.tag!==5)throw Error(l(476));var h=Nb(r).queue;zb(r,h,a,te,u===null?s2:function(){return Ob(r),u(c)})}function Nb(r){var a=r.memoizedState;if(a!==null)return a;a={memoizedState:te,baseState:te,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:hr,lastRenderedState:te},next:null};var u={};return a.next={memoizedState:u,baseState:u,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:hr,lastRenderedState:u},next:null},r.memoizedState=a,r=r.alternate,r!==null&&(r.memoizedState=a),a}function Ob(r){var a=Nb(r);a.next===null&&(a=r.alternate.memoizedState),Cl(r,a.next.queue,{},cn())}function pd(){return Ot(Jl)}function Tb(){return ht().memoizedState}function Cb(){return ht().memoizedState}function c2(r){for(var a=r.return;a!==null;){switch(a.tag){case 24:case 3:var u=cn();r=Pr(u);var c=Zr(a,r,u);c!==null&&(Kt(c,a,u),jl(c,a,u)),a={cache:Bf()},r.payload=a;return}a=a.return}}function f2(r,a,u){var c=cn();u={lane:c,revertLane:0,gesture:null,action:u,hasEagerState:!1,eagerState:null,next:null},Mu(r)?Ab(a,u):(u=Df(r,a,u,c),u!==null&&(Kt(u,r,c),Rb(u,a,c)))}function Db(r,a,u){var c=cn();Cl(r,a,u,c)}function Cl(r,a,u,c){var h={lane:c,revertLane:0,gesture:null,action:u,hasEagerState:!1,eagerState:null,next:null};if(Mu(r))Ab(a,h);else{var g=r.alternate;if(r.lanes===0&&(g===null||g.lanes===0)&&(g=a.lastRenderedReducer,g!==null))try{var _=a.lastRenderedState,k=g(_,u);if(h.hasEagerState=!0,h.eagerState=k,rn(k,_))return bu(r,a,h,0),Ke===null&&yu(),!1}catch{}if(u=Df(r,a,h,c),u!==null)return Kt(u,r,c),Rb(u,a,c),!0}return!1}function gd(r,a,u,c){if(c={lane:2,revertLane:Yd(),gesture:null,action:c,hasEagerState:!1,eagerState:null,next:null},Mu(r)){if(a)throw Error(l(479))}else a=Df(r,u,c,2),a!==null&&Kt(a,r,2)}function Mu(r){var a=r.alternate;return r===Ee||a!==null&&a===Ee}function Ab(r,a){ba=Cu=!0;var u=r.pending;u===null?a.next=a:(a.next=u.next,u.next=a),r.pending=a}function Rb(r,a,u){if((u&4194048)!==0){var c=a.lanes;c&=r.pendingLanes,u|=c,a.lanes=u,Pv(r,u)}}var Dl={readContext:Ot,use:Ru,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};Dl.useEffectEvent=ft;var Ib={readContext:Ot,use:Ru,useCallback:function(r,a){return Pt().memoizedState=[r,a===void 0?null:a],r},useContext:Ot,useEffect:bb,useImperativeHandle:function(r,a,u){u=u!=null?u.concat([r]):null,Uu(4194308,4,kb.bind(null,a,r),u)},useLayoutEffect:function(r,a){return Uu(4194308,4,r,a)},useInsertionEffect:function(r,a){Uu(4,2,r,a)},useMemo:function(r,a){var u=Pt();a=a===void 0?null:a;var c=r();if(Ei){Ht(!0);try{r()}finally{Ht(!1)}}return u.memoizedState=[c,a],c},useReducer:function(r,a,u){var c=Pt();if(u!==void 0){var h=u(a);if(Ei){Ht(!0);try{u(a)}finally{Ht(!1)}}}else h=a;return c.memoizedState=c.baseState=h,r={pending:null,lanes:0,dispatch:null,lastRenderedReducer:r,lastRenderedState:h},c.queue=r,r=r.dispatch=f2.bind(null,Ee,r),[c.memoizedState,r]},useRef:function(r){var a=Pt();return r={current:r},a.memoizedState=r},useState:function(r){r=sd(r);var a=r.queue,u=Db.bind(null,Ee,a);return a.dispatch=u,[r.memoizedState,u]},useDebugValue:dd,useDeferredValue:function(r,a){var u=Pt();return md(u,r,a)},useTransition:function(){var r=sd(!1);return r=zb.bind(null,Ee,r.queue,!0,!1),Pt().memoizedState=r,[!1,r]},useSyncExternalStore:function(r,a,u){var c=Ee,h=Pt();if(Me){if(u===void 0)throw Error(l(407));u=u()}else{if(u=a(),Ke===null)throw Error(l(349));(Ue&127)!==0||rb(c,a,u)}h.memoizedState=u;var g={value:u,getSnapshot:a};return h.queue=g,bb(ab.bind(null,c,g,r),[r]),c.flags|=2048,_a(9,{destroy:void 0},ib.bind(null,c,g,u,a),null),u},useId:function(){var r=Pt(),a=Ke.identifierPrefix;if(Me){var u=Vn,c=Gn;u=(c&~(1<<32-Qe(c)-1)).toString(32)+u,a="_"+a+"R_"+u,u=Du++,0<u&&(a+="H"+u.toString(32)),a+="_"}else u=i2++,a="_"+a+"r_"+u.toString(32)+"_";return r.memoizedState=a},useHostTransitionStatus:pd,useFormState:hb,useActionState:hb,useOptimistic:function(r){var a=Pt();a.memoizedState=a.baseState=r;var u={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return a.queue=u,a=gd.bind(null,Ee,!0,u),u.dispatch=a,[r,a]},useMemoCache:ld,useCacheRefresh:function(){return Pt().memoizedState=c2.bind(null,Ee)},useEffectEvent:function(r){var a=Pt(),u={impl:r};return a.memoizedState=u,function(){if((Fe&2)!==0)throw Error(l(440));return u.impl.apply(void 0,arguments)}}},vd={readContext:Ot,use:Ru,useCallback:$b,useContext:Ot,useEffect:fd,useImperativeHandle:wb,useInsertionEffect:_b,useLayoutEffect:Sb,useMemo:Eb,useReducer:Iu,useRef:yb,useState:function(){return Iu(hr)},useDebugValue:dd,useDeferredValue:function(r,a){var u=ht();return jb(u,Ye.memoizedState,r,a)},useTransition:function(){var r=Iu(hr)[0],a=ht().memoizedState;return[typeof r=="boolean"?r:Tl(r),a]},useSyncExternalStore:nb,useId:Tb,useHostTransitionStatus:pd,useFormState:pb,useActionState:pb,useOptimistic:function(r,a){var u=ht();return ub(u,Ye,r,a)},useMemoCache:ld,useCacheRefresh:Cb};vd.useEffectEvent=xb;var Ub={readContext:Ot,use:Ru,useCallback:$b,useContext:Ot,useEffect:fd,useImperativeHandle:wb,useInsertionEffect:_b,useLayoutEffect:Sb,useMemo:Eb,useReducer:ud,useRef:yb,useState:function(){return ud(hr)},useDebugValue:dd,useDeferredValue:function(r,a){var u=ht();return Ye===null?md(u,r,a):jb(u,Ye.memoizedState,r,a)},useTransition:function(){var r=ud(hr)[0],a=ht().memoizedState;return[typeof r=="boolean"?r:Tl(r),a]},useSyncExternalStore:nb,useId:Tb,useHostTransitionStatus:pd,useFormState:vb,useActionState:vb,useOptimistic:function(r,a){var u=ht();return Ye!==null?ub(u,Ye,r,a):(u.baseState=r,[r,u.queue.dispatch])},useMemoCache:ld,useCacheRefresh:Cb};Ub.useEffectEvent=xb;function yd(r,a,u,c){a=r.memoizedState,u=u(c,a),u=u==null?a:v({},a,u),r.memoizedState=u,r.lanes===0&&(r.updateQueue.baseState=u)}var bd={enqueueSetState:function(r,a,u){r=r._reactInternals;var c=cn(),h=Pr(c);h.payload=a,u!=null&&(h.callback=u),a=Zr(r,h,c),a!==null&&(Kt(a,r,c),jl(a,r,c))},enqueueReplaceState:function(r,a,u){r=r._reactInternals;var c=cn(),h=Pr(c);h.tag=1,h.payload=a,u!=null&&(h.callback=u),a=Zr(r,h,c),a!==null&&(Kt(a,r,c),jl(a,r,c))},enqueueForceUpdate:function(r,a){r=r._reactInternals;var u=cn(),c=Pr(u);c.tag=2,a!=null&&(c.callback=a),a=Zr(r,c,u),a!==null&&(Kt(a,r,u),jl(a,r,u))}};function Lb(r,a,u,c,h,g,_){return r=r.stateNode,typeof r.shouldComponentUpdate=="function"?r.shouldComponentUpdate(c,g,_):a.prototype&&a.prototype.isPureReactComponent?!bl(u,c)||!bl(h,g):!0}function Mb(r,a,u,c){r=a.state,typeof a.componentWillReceiveProps=="function"&&a.componentWillReceiveProps(u,c),typeof a.UNSAFE_componentWillReceiveProps=="function"&&a.UNSAFE_componentWillReceiveProps(u,c),a.state!==r&&bd.enqueueReplaceState(a,a.state,null)}function ji(r,a){var u=a;if("ref"in a){u={};for(var c in a)c!=="ref"&&(u[c]=a[c])}if(r=r.defaultProps){u===a&&(u=v({},u));for(var h in r)u[h]===void 0&&(u[h]=r[h])}return u}function Pb(r){vu(r)}function Zb(r){console.error(r)}function qb(r){vu(r)}function Pu(r,a){try{var u=r.onUncaughtError;u(a.value,{componentStack:a.stack})}catch(c){setTimeout(function(){throw c})}}function Fb(r,a,u){try{var c=r.onCaughtError;c(u.value,{componentStack:u.stack,errorBoundary:a.tag===1?a.stateNode:null})}catch(h){setTimeout(function(){throw h})}}function xd(r,a,u){return u=Pr(u),u.tag=3,u.payload={element:null},u.callback=function(){Pu(r,a)},u}function Bb(r){return r=Pr(r),r.tag=3,r}function Hb(r,a,u,c){var h=u.type.getDerivedStateFromError;if(typeof h=="function"){var g=c.value;r.payload=function(){return h(g)},r.callback=function(){Fb(a,u,c)}}var _=u.stateNode;_!==null&&typeof _.componentDidCatch=="function"&&(r.callback=function(){Fb(a,u,c),typeof h!="function"&&(Vr===null?Vr=new Set([this]):Vr.add(this));var k=c.stack;this.componentDidCatch(c.value,{componentStack:k!==null?k:""})})}function d2(r,a,u,c,h){if(u.flags|=32768,c!==null&&typeof c=="object"&&typeof c.then=="function"){if(a=u.alternate,a!==null&&ma(a,u,h,!0),u=ln.current,u!==null){switch(u.tag){case 31:case 13:return wn===null?Ku():u.alternate===null&&dt===0&&(dt=3),u.flags&=-257,u.flags|=65536,u.lanes=h,c===ju?u.flags|=16384:(a=u.updateQueue,a===null?u.updateQueue=new Set([c]):a.add(c),Hd(r,c,h)),!1;case 22:return u.flags|=65536,c===ju?u.flags|=16384:(a=u.updateQueue,a===null?(a={transitions:null,markerInstances:null,retryQueue:new Set([c])},u.updateQueue=a):(u=a.retryQueue,u===null?a.retryQueue=new Set([c]):u.add(c)),Hd(r,c,h)),!1}throw Error(l(435,u.tag))}return Hd(r,c,h),Ku(),!1}if(Me)return a=ln.current,a!==null?((a.flags&65536)===0&&(a.flags|=256),a.flags|=65536,a.lanes=h,c!==Mf&&(r=Error(l(422),{cause:c}),Sl(xn(r,u)))):(c!==Mf&&(a=Error(l(423),{cause:c}),Sl(xn(a,u))),r=r.current.alternate,r.flags|=65536,h&=-h,r.lanes|=h,c=xn(c,u),h=xd(r.stateNode,c,h),Xf(r,h),dt!==4&&(dt=2)),!1;var g=Error(l(520),{cause:c});if(g=xn(g,u),Zl===null?Zl=[g]:Zl.push(g),dt!==4&&(dt=2),a===null)return!0;c=xn(c,u),u=a;do{switch(u.tag){case 3:return u.flags|=65536,r=h&-h,u.lanes|=r,r=xd(u.stateNode,c,r),Xf(u,r),!1;case 1:if(a=u.type,g=u.stateNode,(u.flags&128)===0&&(typeof a.getDerivedStateFromError=="function"||g!==null&&typeof g.componentDidCatch=="function"&&(Vr===null||!Vr.has(g))))return u.flags|=65536,h&=-h,u.lanes|=h,h=Bb(h),Hb(h,r,u,c),Xf(u,h),!1}u=u.return}while(u!==null);return!1}var _d=Error(l(461)),bt=!1;function Tt(r,a,u,c){a.child=r===null?Jy(a,null,u,c):$i(a,r.child,u,c)}function Gb(r,a,u,c,h){u=u.render;var g=a.ref;if("ref"in c){var _={};for(var k in c)k!=="ref"&&(_[k]=c[k])}else _=c;return _i(a),c=nd(r,a,u,_,g,h),k=rd(),r!==null&&!bt?(id(r,a,h),pr(r,a,h)):(Me&&k&&Uf(a),a.flags|=1,Tt(r,a,c,h),a.child)}function Vb(r,a,u,c,h){if(r===null){var g=u.type;return typeof g=="function"&&!Af(g)&&g.defaultProps===void 0&&u.compare===null?(a.tag=15,a.type=g,Yb(r,a,g,c,h)):(r=_u(u.type,null,c,a,a.mode,h),r.ref=a.ref,r.return=a,a.child=r)}if(g=r.child,!Nd(r,h)){var _=g.memoizedProps;if(u=u.compare,u=u!==null?u:bl,u(_,c)&&r.ref===a.ref)return pr(r,a,h)}return a.flags|=1,r=sr(g,c),r.ref=a.ref,r.return=a,a.child=r}function Yb(r,a,u,c,h){if(r!==null){var g=r.memoizedProps;if(bl(g,c)&&r.ref===a.ref)if(bt=!1,a.pendingProps=c=g,Nd(r,h))(r.flags&131072)!==0&&(bt=!0);else return a.lanes=r.lanes,pr(r,a,h)}return Sd(r,a,u,c,h)}function Jb(r,a,u,c){var h=c.children,g=r!==null?r.memoizedState:null;if(r===null&&a.stateNode===null&&(a.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),c.mode==="hidden"){if((a.flags&128)!==0){if(g=g!==null?g.baseLanes|u:u,r!==null){for(c=a.child=r.child,h=0;c!==null;)h=h|c.lanes|c.childLanes,c=c.sibling;c=h&~g}else c=0,a.child=null;return Xb(r,a,g,u,c)}if((u&536870912)!==0)a.memoizedState={baseLanes:0,cachePool:null},r!==null&&$u(a,g!==null?g.cachePool:null),g!==null?Ky(a,g):Kf(),Wy(a);else return c=a.lanes=536870912,Xb(r,a,g!==null?g.baseLanes|u:u,u,c)}else g!==null?($u(a,g.cachePool),Ky(a,g),Fr(),a.memoizedState=null):(r!==null&&$u(a,null),Kf(),Fr());return Tt(r,a,h,u),a.child}function Al(r,a){return r!==null&&r.tag===22||a.stateNode!==null||(a.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),a.sibling}function Xb(r,a,u,c,h){var g=Gf();return g=g===null?null:{parent:vt._currentValue,pool:g},a.memoizedState={baseLanes:u,cachePool:g},r!==null&&$u(a,null),Kf(),Wy(a),r!==null&&ma(r,a,c,!0),a.childLanes=h,null}function Zu(r,a){return a=Fu({mode:a.mode,children:a.children},r.mode),a.ref=r.ref,r.child=a,a.return=r,a}function Qb(r,a,u){return $i(a,r.child,null,u),r=Zu(a,a.pendingProps),r.flags|=2,on(a),a.memoizedState=null,r}function m2(r,a,u){var c=a.pendingProps,h=(a.flags&128)!==0;if(a.flags&=-129,r===null){if(Me){if(c.mode==="hidden")return r=Zu(a,c),a.lanes=536870912,Al(null,r);if(ed(a),(r=it)?(r=sx(r,kn),r=r!==null&&r.data==="&"?r:null,r!==null&&(a.memoizedState={dehydrated:r,treeContext:Rr!==null?{id:Gn,overflow:Vn}:null,retryLane:536870912,hydrationErrors:null},u=Ay(r),u.return=a,a.child=u,Nt=a,it=null)):r=null,r===null)throw Ur(a);return a.lanes=536870912,null}return Zu(a,c)}var g=r.memoizedState;if(g!==null){var _=g.dehydrated;if(ed(a),h)if(a.flags&256)a.flags&=-257,a=Qb(r,a,u);else if(a.memoizedState!==null)a.child=r.child,a.flags|=128,a=null;else throw Error(l(558));else if(bt||ma(r,a,u,!1),h=(u&r.childLanes)!==0,bt||h){if(c=Ke,c!==null&&(_=Zv(c,u),_!==0&&_!==g.retryLane))throw g.retryLane=_,vi(r,_),Kt(c,r,_),_d;Ku(),a=Qb(r,a,u)}else r=g.treeContext,it=$n(_.nextSibling),Nt=a,Me=!0,Ir=null,kn=!1,r!==null&&Uy(a,r),a=Zu(a,c),a.flags|=4096;return a}return r=sr(r.child,{mode:c.mode,children:c.children}),r.ref=a.ref,a.child=r,r.return=a,r}function qu(r,a){var u=a.ref;if(u===null)r!==null&&r.ref!==null&&(a.flags|=4194816);else{if(typeof u!="function"&&typeof u!="object")throw Error(l(284));(r===null||r.ref!==u)&&(a.flags|=4194816)}}function Sd(r,a,u,c,h){return _i(a),u=nd(r,a,u,c,void 0,h),c=rd(),r!==null&&!bt?(id(r,a,h),pr(r,a,h)):(Me&&c&&Uf(a),a.flags|=1,Tt(r,a,u,h),a.child)}function Kb(r,a,u,c,h,g){return _i(a),a.updateQueue=null,u=tb(a,c,u,h),eb(r),c=rd(),r!==null&&!bt?(id(r,a,g),pr(r,a,g)):(Me&&c&&Uf(a),a.flags|=1,Tt(r,a,u,g),a.child)}function Wb(r,a,u,c,h){if(_i(a),a.stateNode===null){var g=sa,_=u.contextType;typeof _=="object"&&_!==null&&(g=Ot(_)),g=new u(c,g),a.memoizedState=g.state!==null&&g.state!==void 0?g.state:null,g.updater=bd,a.stateNode=g,g._reactInternals=a,g=a.stateNode,g.props=c,g.state=a.memoizedState,g.refs={},Yf(a),_=u.contextType,g.context=typeof _=="object"&&_!==null?Ot(_):sa,g.state=a.memoizedState,_=u.getDerivedStateFromProps,typeof _=="function"&&(yd(a,u,_,c),g.state=a.memoizedState),typeof u.getDerivedStateFromProps=="function"||typeof g.getSnapshotBeforeUpdate=="function"||typeof g.UNSAFE_componentWillMount!="function"&&typeof g.componentWillMount!="function"||(_=g.state,typeof g.componentWillMount=="function"&&g.componentWillMount(),typeof g.UNSAFE_componentWillMount=="function"&&g.UNSAFE_componentWillMount(),_!==g.state&&bd.enqueueReplaceState(g,g.state,null),Nl(a,c,g,h),zl(),g.state=a.memoizedState),typeof g.componentDidMount=="function"&&(a.flags|=4194308),c=!0}else if(r===null){g=a.stateNode;var k=a.memoizedProps,D=ji(u,k);g.props=D;var H=g.context,K=u.contextType;_=sa,typeof K=="object"&&K!==null&&(_=Ot(K));var ne=u.getDerivedStateFromProps;K=typeof ne=="function"||typeof g.getSnapshotBeforeUpdate=="function",k=a.pendingProps!==k,K||typeof g.UNSAFE_componentWillReceiveProps!="function"&&typeof g.componentWillReceiveProps!="function"||(k||H!==_)&&Mb(a,g,c,_),Mr=!1;var V=a.memoizedState;g.state=V,Nl(a,c,g,h),zl(),H=a.memoizedState,k||V!==H||Mr?(typeof ne=="function"&&(yd(a,u,ne,c),H=a.memoizedState),(D=Mr||Lb(a,u,D,c,V,H,_))?(K||typeof g.UNSAFE_componentWillMount!="function"&&typeof g.componentWillMount!="function"||(typeof g.componentWillMount=="function"&&g.componentWillMount(),typeof g.UNSAFE_componentWillMount=="function"&&g.UNSAFE_componentWillMount()),typeof g.componentDidMount=="function"&&(a.flags|=4194308)):(typeof g.componentDidMount=="function"&&(a.flags|=4194308),a.memoizedProps=c,a.memoizedState=H),g.props=c,g.state=H,g.context=_,c=D):(typeof g.componentDidMount=="function"&&(a.flags|=4194308),c=!1)}else{g=a.stateNode,Jf(r,a),_=a.memoizedProps,K=ji(u,_),g.props=K,ne=a.pendingProps,V=g.context,H=u.contextType,D=sa,typeof H=="object"&&H!==null&&(D=Ot(H)),k=u.getDerivedStateFromProps,(H=typeof k=="function"||typeof g.getSnapshotBeforeUpdate=="function")||typeof g.UNSAFE_componentWillReceiveProps!="function"&&typeof g.componentWillReceiveProps!="function"||(_!==ne||V!==D)&&Mb(a,g,c,D),Mr=!1,V=a.memoizedState,g.state=V,Nl(a,c,g,h),zl();var Y=a.memoizedState;_!==ne||V!==Y||Mr||r!==null&&r.dependencies!==null&&ku(r.dependencies)?(typeof k=="function"&&(yd(a,u,k,c),Y=a.memoizedState),(K=Mr||Lb(a,u,K,c,V,Y,D)||r!==null&&r.dependencies!==null&&ku(r.dependencies))?(H||typeof g.UNSAFE_componentWillUpdate!="function"&&typeof g.componentWillUpdate!="function"||(typeof g.componentWillUpdate=="function"&&g.componentWillUpdate(c,Y,D),typeof g.UNSAFE_componentWillUpdate=="function"&&g.UNSAFE_componentWillUpdate(c,Y,D)),typeof g.componentDidUpdate=="function"&&(a.flags|=4),typeof g.getSnapshotBeforeUpdate=="function"&&(a.flags|=1024)):(typeof g.componentDidUpdate!="function"||_===r.memoizedProps&&V===r.memoizedState||(a.flags|=4),typeof g.getSnapshotBeforeUpdate!="function"||_===r.memoizedProps&&V===r.memoizedState||(a.flags|=1024),a.memoizedProps=c,a.memoizedState=Y),g.props=c,g.state=Y,g.context=D,c=K):(typeof g.componentDidUpdate!="function"||_===r.memoizedProps&&V===r.memoizedState||(a.flags|=4),typeof g.getSnapshotBeforeUpdate!="function"||_===r.memoizedProps&&V===r.memoizedState||(a.flags|=1024),c=!1)}return g=c,qu(r,a),c=(a.flags&128)!==0,g||c?(g=a.stateNode,u=c&&typeof u.getDerivedStateFromError!="function"?null:g.render(),a.flags|=1,r!==null&&c?(a.child=$i(a,r.child,null,h),a.child=$i(a,null,u,h)):Tt(r,a,u,h),a.memoizedState=g.state,r=a.child):r=pr(r,a,h),r}function e0(r,a,u,c){return bi(),a.flags|=256,Tt(r,a,u,c),a.child}var kd={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function wd(r){return{baseLanes:r,cachePool:Fy()}}function $d(r,a,u){return r=r!==null?r.childLanes&~u:0,a&&(r|=sn),r}function t0(r,a,u){var c=a.pendingProps,h=!1,g=(a.flags&128)!==0,_;if((_=g)||(_=r!==null&&r.memoizedState===null?!1:(mt.current&2)!==0),_&&(h=!0,a.flags&=-129),_=(a.flags&32)!==0,a.flags&=-33,r===null){if(Me){if(h?qr(a):Fr(),(r=it)?(r=sx(r,kn),r=r!==null&&r.data!=="&"?r:null,r!==null&&(a.memoizedState={dehydrated:r,treeContext:Rr!==null?{id:Gn,overflow:Vn}:null,retryLane:536870912,hydrationErrors:null},u=Ay(r),u.return=a,a.child=u,Nt=a,it=null)):r=null,r===null)throw Ur(a);return om(r)?a.lanes=32:a.lanes=536870912,null}var k=c.children;return c=c.fallback,h?(Fr(),h=a.mode,k=Fu({mode:"hidden",children:k},h),c=yi(c,h,u,null),k.return=a,c.return=a,k.sibling=c,a.child=k,c=a.child,c.memoizedState=wd(u),c.childLanes=$d(r,_,u),a.memoizedState=kd,Al(null,c)):(qr(a),Ed(a,k))}var D=r.memoizedState;if(D!==null&&(k=D.dehydrated,k!==null)){if(g)a.flags&256?(qr(a),a.flags&=-257,a=jd(r,a,u)):a.memoizedState!==null?(Fr(),a.child=r.child,a.flags|=128,a=null):(Fr(),k=c.fallback,h=a.mode,c=Fu({mode:"visible",children:c.children},h),k=yi(k,h,u,null),k.flags|=2,c.return=a,k.return=a,c.sibling=k,a.child=c,$i(a,r.child,null,u),c=a.child,c.memoizedState=wd(u),c.childLanes=$d(r,_,u),a.memoizedState=kd,a=Al(null,c));else if(qr(a),om(k)){if(_=k.nextSibling&&k.nextSibling.dataset,_)var H=_.dgst;_=H,c=Error(l(419)),c.stack="",c.digest=_,Sl({value:c,source:null,stack:null}),a=jd(r,a,u)}else if(bt||ma(r,a,u,!1),_=(u&r.childLanes)!==0,bt||_){if(_=Ke,_!==null&&(c=Zv(_,u),c!==0&&c!==D.retryLane))throw D.retryLane=c,vi(r,c),Kt(_,r,c),_d;lm(k)||Ku(),a=jd(r,a,u)}else lm(k)?(a.flags|=192,a.child=r.child,a=null):(r=D.treeContext,it=$n(k.nextSibling),Nt=a,Me=!0,Ir=null,kn=!1,r!==null&&Uy(a,r),a=Ed(a,c.children),a.flags|=4096);return a}return h?(Fr(),k=c.fallback,h=a.mode,D=r.child,H=D.sibling,c=sr(D,{mode:"hidden",children:c.children}),c.subtreeFlags=D.subtreeFlags&65011712,H!==null?k=sr(H,k):(k=yi(k,h,u,null),k.flags|=2),k.return=a,c.return=a,c.sibling=k,a.child=c,Al(null,c),c=a.child,k=r.child.memoizedState,k===null?k=wd(u):(h=k.cachePool,h!==null?(D=vt._currentValue,h=h.parent!==D?{parent:D,pool:D}:h):h=Fy(),k={baseLanes:k.baseLanes|u,cachePool:h}),c.memoizedState=k,c.childLanes=$d(r,_,u),a.memoizedState=kd,Al(r.child,c)):(qr(a),u=r.child,r=u.sibling,u=sr(u,{mode:"visible",children:c.children}),u.return=a,u.sibling=null,r!==null&&(_=a.deletions,_===null?(a.deletions=[r],a.flags|=16):_.push(r)),a.child=u,a.memoizedState=null,u)}function Ed(r,a){return a=Fu({mode:"visible",children:a},r.mode),a.return=r,r.child=a}function Fu(r,a){return r=an(22,r,null,a),r.lanes=0,r}function jd(r,a,u){return $i(a,r.child,null,u),r=Ed(a,a.pendingProps.children),r.flags|=2,a.memoizedState=null,r}function n0(r,a,u){r.lanes|=a;var c=r.alternate;c!==null&&(c.lanes|=a),qf(r.return,a,u)}function zd(r,a,u,c,h,g){var _=r.memoizedState;_===null?r.memoizedState={isBackwards:a,rendering:null,renderingStartTime:0,last:c,tail:u,tailMode:h,treeForkCount:g}:(_.isBackwards=a,_.rendering=null,_.renderingStartTime=0,_.last=c,_.tail=u,_.tailMode=h,_.treeForkCount=g)}function r0(r,a,u){var c=a.pendingProps,h=c.revealOrder,g=c.tail;c=c.children;var _=mt.current,k=(_&2)!==0;if(k?(_=_&1|2,a.flags|=128):_&=1,$(mt,_),Tt(r,a,c,u),c=Me?_l:0,!k&&r!==null&&(r.flags&128)!==0)e:for(r=a.child;r!==null;){if(r.tag===13)r.memoizedState!==null&&n0(r,u,a);else if(r.tag===19)n0(r,u,a);else if(r.child!==null){r.child.return=r,r=r.child;continue}if(r===a)break e;for(;r.sibling===null;){if(r.return===null||r.return===a)break e;r=r.return}r.sibling.return=r.return,r=r.sibling}switch(h){case"forwards":for(u=a.child,h=null;u!==null;)r=u.alternate,r!==null&&Tu(r)===null&&(h=u),u=u.sibling;u=h,u===null?(h=a.child,a.child=null):(h=u.sibling,u.sibling=null),zd(a,!1,h,u,g,c);break;case"backwards":case"unstable_legacy-backwards":for(u=null,h=a.child,a.child=null;h!==null;){if(r=h.alternate,r!==null&&Tu(r)===null){a.child=h;break}r=h.sibling,h.sibling=u,u=h,h=r}zd(a,!0,u,null,g,c);break;case"together":zd(a,!1,null,null,void 0,c);break;default:a.memoizedState=null}return a.child}function pr(r,a,u){if(r!==null&&(a.dependencies=r.dependencies),Gr|=a.lanes,(u&a.childLanes)===0)if(r!==null){if(ma(r,a,u,!1),(u&a.childLanes)===0)return null}else return null;if(r!==null&&a.child!==r.child)throw Error(l(153));if(a.child!==null){for(r=a.child,u=sr(r,r.pendingProps),a.child=u,u.return=a;r.sibling!==null;)r=r.sibling,u=u.sibling=sr(r,r.pendingProps),u.return=a;u.sibling=null}return a.child}function Nd(r,a){return(r.lanes&a)!==0?!0:(r=r.dependencies,!!(r!==null&&ku(r)))}function h2(r,a,u){switch(a.tag){case 3:ot(a,a.stateNode.containerInfo),Lr(a,vt,r.memoizedState.cache),bi();break;case 27:case 5:gn(a);break;case 4:ot(a,a.stateNode.containerInfo);break;case 10:Lr(a,a.type,a.memoizedProps.value);break;case 31:if(a.memoizedState!==null)return a.flags|=128,ed(a),null;break;case 13:var c=a.memoizedState;if(c!==null)return c.dehydrated!==null?(qr(a),a.flags|=128,null):(u&a.child.childLanes)!==0?t0(r,a,u):(qr(a),r=pr(r,a,u),r!==null?r.sibling:null);qr(a);break;case 19:var h=(r.flags&128)!==0;if(c=(u&a.childLanes)!==0,c||(ma(r,a,u,!1),c=(u&a.childLanes)!==0),h){if(c)return r0(r,a,u);a.flags|=128}if(h=a.memoizedState,h!==null&&(h.rendering=null,h.tail=null,h.lastEffect=null),$(mt,mt.current),c)break;return null;case 22:return a.lanes=0,Jb(r,a,u,a.pendingProps);case 24:Lr(a,vt,r.memoizedState.cache)}return pr(r,a,u)}function i0(r,a,u){if(r!==null)if(r.memoizedProps!==a.pendingProps)bt=!0;else{if(!Nd(r,u)&&(a.flags&128)===0)return bt=!1,h2(r,a,u);bt=(r.flags&131072)!==0}else bt=!1,Me&&(a.flags&1048576)!==0&&Iy(a,_l,a.index);switch(a.lanes=0,a.tag){case 16:e:{var c=a.pendingProps;if(r=ki(a.elementType),a.type=r,typeof r=="function")Af(r)?(c=ji(r,c),a.tag=1,a=Wb(null,a,r,c,u)):(a.tag=0,a=Sd(null,a,r,c,u));else{if(r!=null){var h=r.$$typeof;if(h===G){a.tag=11,a=Gb(null,a,r,c,u);break e}else if(h===X){a.tag=14,a=Vb(null,a,r,c,u);break e}}throw a=M(r)||r,Error(l(306,a,""))}}return a;case 0:return Sd(r,a,a.type,a.pendingProps,u);case 1:return c=a.type,h=ji(c,a.pendingProps),Wb(r,a,c,h,u);case 3:e:{if(ot(a,a.stateNode.containerInfo),r===null)throw Error(l(387));c=a.pendingProps;var g=a.memoizedState;h=g.element,Jf(r,a),Nl(a,c,null,u);var _=a.memoizedState;if(c=_.cache,Lr(a,vt,c),c!==g.cache&&Ff(a,[vt],u,!0),zl(),c=_.element,g.isDehydrated)if(g={element:c,isDehydrated:!1,cache:_.cache},a.updateQueue.baseState=g,a.memoizedState=g,a.flags&256){a=e0(r,a,c,u);break e}else if(c!==h){h=xn(Error(l(424)),a),Sl(h),a=e0(r,a,c,u);break e}else for(r=a.stateNode.containerInfo,r.nodeType===9?r=r.body:r=r.nodeName==="HTML"?r.ownerDocument.body:r,it=$n(r.firstChild),Nt=a,Me=!0,Ir=null,kn=!0,u=Jy(a,null,c,u),a.child=u;u;)u.flags=u.flags&-3|4096,u=u.sibling;else{if(bi(),c===h){a=pr(r,a,u);break e}Tt(r,a,c,u)}a=a.child}return a;case 26:return qu(r,a),r===null?(u=px(a.type,null,a.pendingProps,null))?a.memoizedState=u:Me||(u=a.type,r=a.pendingProps,c=as(pe.current).createElement(u),c[zt]=a,c[Gt]=r,Ct(c,u,r),$t(c),a.stateNode=c):a.memoizedState=px(a.type,r.memoizedProps,a.pendingProps,r.memoizedState),null;case 27:return gn(a),r===null&&Me&&(c=a.stateNode=dx(a.type,a.pendingProps,pe.current),Nt=a,kn=!0,h=it,Qr(a.type)?(um=h,it=$n(c.firstChild)):it=h),Tt(r,a,a.pendingProps.children,u),qu(r,a),r===null&&(a.flags|=4194304),a.child;case 5:return r===null&&Me&&((h=c=it)&&(c=B2(c,a.type,a.pendingProps,kn),c!==null?(a.stateNode=c,Nt=a,it=$n(c.firstChild),kn=!1,h=!0):h=!1),h||Ur(a)),gn(a),h=a.type,g=a.pendingProps,_=r!==null?r.memoizedProps:null,c=g.children,rm(h,g)?c=null:_!==null&&rm(h,_)&&(a.flags|=32),a.memoizedState!==null&&(h=nd(r,a,a2,null,null,u),Jl._currentValue=h),qu(r,a),Tt(r,a,c,u),a.child;case 6:return r===null&&Me&&((r=u=it)&&(u=H2(u,a.pendingProps,kn),u!==null?(a.stateNode=u,Nt=a,it=null,r=!0):r=!1),r||Ur(a)),null;case 13:return t0(r,a,u);case 4:return ot(a,a.stateNode.containerInfo),c=a.pendingProps,r===null?a.child=$i(a,null,c,u):Tt(r,a,c,u),a.child;case 11:return Gb(r,a,a.type,a.pendingProps,u);case 7:return Tt(r,a,a.pendingProps,u),a.child;case 8:return Tt(r,a,a.pendingProps.children,u),a.child;case 12:return Tt(r,a,a.pendingProps.children,u),a.child;case 10:return c=a.pendingProps,Lr(a,a.type,c.value),Tt(r,a,c.children,u),a.child;case 9:return h=a.type._context,c=a.pendingProps.children,_i(a),h=Ot(h),c=c(h),a.flags|=1,Tt(r,a,c,u),a.child;case 14:return Vb(r,a,a.type,a.pendingProps,u);case 15:return Yb(r,a,a.type,a.pendingProps,u);case 19:return r0(r,a,u);case 31:return m2(r,a,u);case 22:return Jb(r,a,u,a.pendingProps);case 24:return _i(a),c=Ot(vt),r===null?(h=Gf(),h===null&&(h=Ke,g=Bf(),h.pooledCache=g,g.refCount++,g!==null&&(h.pooledCacheLanes|=u),h=g),a.memoizedState={parent:c,cache:h},Yf(a),Lr(a,vt,h)):((r.lanes&u)!==0&&(Jf(r,a),Nl(a,null,null,u),zl()),h=r.memoizedState,g=a.memoizedState,h.parent!==c?(h={parent:c,cache:c},a.memoizedState=h,a.lanes===0&&(a.memoizedState=a.updateQueue.baseState=h),Lr(a,vt,c)):(c=g.cache,Lr(a,vt,c),c!==h.cache&&Ff(a,[vt],u,!0))),Tt(r,a,a.pendingProps.children,u),a.child;case 29:throw a.pendingProps}throw Error(l(156,a.tag))}function gr(r){r.flags|=4}function Od(r,a,u,c,h){if((a=(r.mode&32)!==0)&&(a=!1),a){if(r.flags|=16777216,(h&335544128)===h)if(r.stateNode.complete)r.flags|=8192;else if(T0())r.flags|=8192;else throw wi=ju,Vf}else r.flags&=-16777217}function a0(r,a){if(a.type!=="stylesheet"||(a.state.loading&4)!==0)r.flags&=-16777217;else if(r.flags|=16777216,!xx(a))if(T0())r.flags|=8192;else throw wi=ju,Vf}function Bu(r,a){a!==null&&(r.flags|=4),r.flags&16384&&(a=r.tag!==22?Lv():536870912,r.lanes|=a,$a|=a)}function Rl(r,a){if(!Me)switch(r.tailMode){case"hidden":a=r.tail;for(var u=null;a!==null;)a.alternate!==null&&(u=a),a=a.sibling;u===null?r.tail=null:u.sibling=null;break;case"collapsed":u=r.tail;for(var c=null;u!==null;)u.alternate!==null&&(c=u),u=u.sibling;c===null?a||r.tail===null?r.tail=null:r.tail.sibling=null:c.sibling=null}}function at(r){var a=r.alternate!==null&&r.alternate.child===r.child,u=0,c=0;if(a)for(var h=r.child;h!==null;)u|=h.lanes|h.childLanes,c|=h.subtreeFlags&65011712,c|=h.flags&65011712,h.return=r,h=h.sibling;else for(h=r.child;h!==null;)u|=h.lanes|h.childLanes,c|=h.subtreeFlags,c|=h.flags,h.return=r,h=h.sibling;return r.subtreeFlags|=c,r.childLanes=u,a}function p2(r,a,u){var c=a.pendingProps;switch(Lf(a),a.tag){case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return at(a),null;case 1:return at(a),null;case 3:return u=a.stateNode,c=null,r!==null&&(c=r.memoizedState.cache),a.memoizedState.cache!==c&&(a.flags|=2048),dr(vt),Ve(),u.pendingContext&&(u.context=u.pendingContext,u.pendingContext=null),(r===null||r.child===null)&&(da(a)?gr(a):r===null||r.memoizedState.isDehydrated&&(a.flags&256)===0||(a.flags|=1024,Pf())),at(a),null;case 26:var h=a.type,g=a.memoizedState;return r===null?(gr(a),g!==null?(at(a),a0(a,g)):(at(a),Od(a,h,null,c,u))):g?g!==r.memoizedState?(gr(a),at(a),a0(a,g)):(at(a),a.flags&=-16777217):(r=r.memoizedProps,r!==c&&gr(a),at(a),Od(a,h,r,c,u)),null;case 27:if(rr(a),u=pe.current,h=a.type,r!==null&&a.stateNode!=null)r.memoizedProps!==c&&gr(a);else{if(!c){if(a.stateNode===null)throw Error(l(166));return at(a),null}r=oe.current,da(a)?Ly(a):(r=dx(h,c,u),a.stateNode=r,gr(a))}return at(a),null;case 5:if(rr(a),h=a.type,r!==null&&a.stateNode!=null)r.memoizedProps!==c&&gr(a);else{if(!c){if(a.stateNode===null)throw Error(l(166));return at(a),null}if(g=oe.current,da(a))Ly(a);else{var _=as(pe.current);switch(g){case 1:g=_.createElementNS("http://www.w3.org/2000/svg",h);break;case 2:g=_.createElementNS("http://www.w3.org/1998/Math/MathML",h);break;default:switch(h){case"svg":g=_.createElementNS("http://www.w3.org/2000/svg",h);break;case"math":g=_.createElementNS("http://www.w3.org/1998/Math/MathML",h);break;case"script":g=_.createElement("div"),g.innerHTML="<script><\/script>",g=g.removeChild(g.firstChild);break;case"select":g=typeof c.is=="string"?_.createElement("select",{is:c.is}):_.createElement("select"),c.multiple?g.multiple=!0:c.size&&(g.size=c.size);break;default:g=typeof c.is=="string"?_.createElement(h,{is:c.is}):_.createElement(h)}}g[zt]=a,g[Gt]=c;e:for(_=a.child;_!==null;){if(_.tag===5||_.tag===6)g.appendChild(_.stateNode);else if(_.tag!==4&&_.tag!==27&&_.child!==null){_.child.return=_,_=_.child;continue}if(_===a)break e;for(;_.sibling===null;){if(_.return===null||_.return===a)break e;_=_.return}_.sibling.return=_.return,_=_.sibling}a.stateNode=g;e:switch(Ct(g,h,c),h){case"button":case"input":case"select":case"textarea":c=!!c.autoFocus;break e;case"img":c=!0;break e;default:c=!1}c&&gr(a)}}return at(a),Od(a,a.type,r===null?null:r.memoizedProps,a.pendingProps,u),null;case 6:if(r&&a.stateNode!=null)r.memoizedProps!==c&&gr(a);else{if(typeof c!="string"&&a.stateNode===null)throw Error(l(166));if(r=pe.current,da(a)){if(r=a.stateNode,u=a.memoizedProps,c=null,h=Nt,h!==null)switch(h.tag){case 27:case 5:c=h.memoizedProps}r[zt]=a,r=!!(r.nodeValue===u||c!==null&&c.suppressHydrationWarning===!0||tx(r.nodeValue,u)),r||Ur(a,!0)}else r=as(r).createTextNode(c),r[zt]=a,a.stateNode=r}return at(a),null;case 31:if(u=a.memoizedState,r===null||r.memoizedState!==null){if(c=da(a),u!==null){if(r===null){if(!c)throw Error(l(318));if(r=a.memoizedState,r=r!==null?r.dehydrated:null,!r)throw Error(l(557));r[zt]=a}else bi(),(a.flags&128)===0&&(a.memoizedState=null),a.flags|=4;at(a),r=!1}else u=Pf(),r!==null&&r.memoizedState!==null&&(r.memoizedState.hydrationErrors=u),r=!0;if(!r)return a.flags&256?(on(a),a):(on(a),null);if((a.flags&128)!==0)throw Error(l(558))}return at(a),null;case 13:if(c=a.memoizedState,r===null||r.memoizedState!==null&&r.memoizedState.dehydrated!==null){if(h=da(a),c!==null&&c.dehydrated!==null){if(r===null){if(!h)throw Error(l(318));if(h=a.memoizedState,h=h!==null?h.dehydrated:null,!h)throw Error(l(317));h[zt]=a}else bi(),(a.flags&128)===0&&(a.memoizedState=null),a.flags|=4;at(a),h=!1}else h=Pf(),r!==null&&r.memoizedState!==null&&(r.memoizedState.hydrationErrors=h),h=!0;if(!h)return a.flags&256?(on(a),a):(on(a),null)}return on(a),(a.flags&128)!==0?(a.lanes=u,a):(u=c!==null,r=r!==null&&r.memoizedState!==null,u&&(c=a.child,h=null,c.alternate!==null&&c.alternate.memoizedState!==null&&c.alternate.memoizedState.cachePool!==null&&(h=c.alternate.memoizedState.cachePool.pool),g=null,c.memoizedState!==null&&c.memoizedState.cachePool!==null&&(g=c.memoizedState.cachePool.pool),g!==h&&(c.flags|=2048)),u!==r&&u&&(a.child.flags|=8192),Bu(a,a.updateQueue),at(a),null);case 4:return Ve(),r===null&&Kd(a.stateNode.containerInfo),at(a),null;case 10:return dr(a.type),at(a),null;case 19:if(Z(mt),c=a.memoizedState,c===null)return at(a),null;if(h=(a.flags&128)!==0,g=c.rendering,g===null)if(h)Rl(c,!1);else{if(dt!==0||r!==null&&(r.flags&128)!==0)for(r=a.child;r!==null;){if(g=Tu(r),g!==null){for(a.flags|=128,Rl(c,!1),r=g.updateQueue,a.updateQueue=r,Bu(a,r),a.subtreeFlags=0,r=u,u=a.child;u!==null;)Dy(u,r),u=u.sibling;return $(mt,mt.current&1|2),Me&&cr(a,c.treeForkCount),a.child}r=r.sibling}c.tail!==null&&Lt()>Ju&&(a.flags|=128,h=!0,Rl(c,!1),a.lanes=4194304)}else{if(!h)if(r=Tu(g),r!==null){if(a.flags|=128,h=!0,r=r.updateQueue,a.updateQueue=r,Bu(a,r),Rl(c,!0),c.tail===null&&c.tailMode==="hidden"&&!g.alternate&&!Me)return at(a),null}else 2*Lt()-c.renderingStartTime>Ju&&u!==536870912&&(a.flags|=128,h=!0,Rl(c,!1),a.lanes=4194304);c.isBackwards?(g.sibling=a.child,a.child=g):(r=c.last,r!==null?r.sibling=g:a.child=g,c.last=g)}return c.tail!==null?(r=c.tail,c.rendering=r,c.tail=r.sibling,c.renderingStartTime=Lt(),r.sibling=null,u=mt.current,$(mt,h?u&1|2:u&1),Me&&cr(a,c.treeForkCount),r):(at(a),null);case 22:case 23:return on(a),Wf(),c=a.memoizedState!==null,r!==null?r.memoizedState!==null!==c&&(a.flags|=8192):c&&(a.flags|=8192),c?(u&536870912)!==0&&(a.flags&128)===0&&(at(a),a.subtreeFlags&6&&(a.flags|=8192)):at(a),u=a.updateQueue,u!==null&&Bu(a,u.retryQueue),u=null,r!==null&&r.memoizedState!==null&&r.memoizedState.cachePool!==null&&(u=r.memoizedState.cachePool.pool),c=null,a.memoizedState!==null&&a.memoizedState.cachePool!==null&&(c=a.memoizedState.cachePool.pool),c!==u&&(a.flags|=2048),r!==null&&Z(Si),null;case 24:return u=null,r!==null&&(u=r.memoizedState.cache),a.memoizedState.cache!==u&&(a.flags|=2048),dr(vt),at(a),null;case 25:return null;case 30:return null}throw Error(l(156,a.tag))}function g2(r,a){switch(Lf(a),a.tag){case 1:return r=a.flags,r&65536?(a.flags=r&-65537|128,a):null;case 3:return dr(vt),Ve(),r=a.flags,(r&65536)!==0&&(r&128)===0?(a.flags=r&-65537|128,a):null;case 26:case 27:case 5:return rr(a),null;case 31:if(a.memoizedState!==null){if(on(a),a.alternate===null)throw Error(l(340));bi()}return r=a.flags,r&65536?(a.flags=r&-65537|128,a):null;case 13:if(on(a),r=a.memoizedState,r!==null&&r.dehydrated!==null){if(a.alternate===null)throw Error(l(340));bi()}return r=a.flags,r&65536?(a.flags=r&-65537|128,a):null;case 19:return Z(mt),null;case 4:return Ve(),null;case 10:return dr(a.type),null;case 22:case 23:return on(a),Wf(),r!==null&&Z(Si),r=a.flags,r&65536?(a.flags=r&-65537|128,a):null;case 24:return dr(vt),null;case 25:return null;default:return null}}function l0(r,a){switch(Lf(a),a.tag){case 3:dr(vt),Ve();break;case 26:case 27:case 5:rr(a);break;case 4:Ve();break;case 31:a.memoizedState!==null&&on(a);break;case 13:on(a);break;case 19:Z(mt);break;case 10:dr(a.type);break;case 22:case 23:on(a),Wf(),r!==null&&Z(Si);break;case 24:dr(vt)}}function Il(r,a){try{var u=a.updateQueue,c=u!==null?u.lastEffect:null;if(c!==null){var h=c.next;u=h;do{if((u.tag&r)===r){c=void 0;var g=u.create,_=u.inst;c=g(),_.destroy=c}u=u.next}while(u!==h)}}catch(k){Ge(a,a.return,k)}}function Br(r,a,u){try{var c=a.updateQueue,h=c!==null?c.lastEffect:null;if(h!==null){var g=h.next;c=g;do{if((c.tag&r)===r){var _=c.inst,k=_.destroy;if(k!==void 0){_.destroy=void 0,h=a;var D=u,H=k;try{H()}catch(K){Ge(h,D,K)}}}c=c.next}while(c!==g)}}catch(K){Ge(a,a.return,K)}}function o0(r){var a=r.updateQueue;if(a!==null){var u=r.stateNode;try{Qy(a,u)}catch(c){Ge(r,r.return,c)}}}function u0(r,a,u){u.props=ji(r.type,r.memoizedProps),u.state=r.memoizedState;try{u.componentWillUnmount()}catch(c){Ge(r,a,c)}}function Ul(r,a){try{var u=r.ref;if(u!==null){switch(r.tag){case 26:case 27:case 5:var c=r.stateNode;break;case 30:c=r.stateNode;break;default:c=r.stateNode}typeof u=="function"?r.refCleanup=u(c):u.current=c}}catch(h){Ge(r,a,h)}}function Yn(r,a){var u=r.ref,c=r.refCleanup;if(u!==null)if(typeof c=="function")try{c()}catch(h){Ge(r,a,h)}finally{r.refCleanup=null,r=r.alternate,r!=null&&(r.refCleanup=null)}else if(typeof u=="function")try{u(null)}catch(h){Ge(r,a,h)}else u.current=null}function s0(r){var a=r.type,u=r.memoizedProps,c=r.stateNode;try{e:switch(a){case"button":case"input":case"select":case"textarea":u.autoFocus&&c.focus();break e;case"img":u.src?c.src=u.src:u.srcSet&&(c.srcset=u.srcSet)}}catch(h){Ge(r,r.return,h)}}function Td(r,a,u){try{var c=r.stateNode;L2(c,r.type,u,a),c[Gt]=a}catch(h){Ge(r,r.return,h)}}function c0(r){return r.tag===5||r.tag===3||r.tag===26||r.tag===27&&Qr(r.type)||r.tag===4}function Cd(r){e:for(;;){for(;r.sibling===null;){if(r.return===null||c0(r.return))return null;r=r.return}for(r.sibling.return=r.return,r=r.sibling;r.tag!==5&&r.tag!==6&&r.tag!==18;){if(r.tag===27&&Qr(r.type)||r.flags&2||r.child===null||r.tag===4)continue e;r.child.return=r,r=r.child}if(!(r.flags&2))return r.stateNode}}function Dd(r,a,u){var c=r.tag;if(c===5||c===6)r=r.stateNode,a?(u.nodeType===9?u.body:u.nodeName==="HTML"?u.ownerDocument.body:u).insertBefore(r,a):(a=u.nodeType===9?u.body:u.nodeName==="HTML"?u.ownerDocument.body:u,a.appendChild(r),u=u._reactRootContainer,u!=null||a.onclick!==null||(a.onclick=or));else if(c!==4&&(c===27&&Qr(r.type)&&(u=r.stateNode,a=null),r=r.child,r!==null))for(Dd(r,a,u),r=r.sibling;r!==null;)Dd(r,a,u),r=r.sibling}function Hu(r,a,u){var c=r.tag;if(c===5||c===6)r=r.stateNode,a?u.insertBefore(r,a):u.appendChild(r);else if(c!==4&&(c===27&&Qr(r.type)&&(u=r.stateNode),r=r.child,r!==null))for(Hu(r,a,u),r=r.sibling;r!==null;)Hu(r,a,u),r=r.sibling}function f0(r){var a=r.stateNode,u=r.memoizedProps;try{for(var c=r.type,h=a.attributes;h.length;)a.removeAttributeNode(h[0]);Ct(a,c,u),a[zt]=r,a[Gt]=u}catch(g){Ge(r,r.return,g)}}var vr=!1,xt=!1,Ad=!1,d0=typeof WeakSet=="function"?WeakSet:Set,Et=null;function v2(r,a){if(r=r.containerInfo,tm=ds,r=wy(r),jf(r)){if("selectionStart"in r)var u={start:r.selectionStart,end:r.selectionEnd};else e:{u=(u=r.ownerDocument)&&u.defaultView||window;var c=u.getSelection&&u.getSelection();if(c&&c.rangeCount!==0){u=c.anchorNode;var h=c.anchorOffset,g=c.focusNode;c=c.focusOffset;try{u.nodeType,g.nodeType}catch{u=null;break e}var _=0,k=-1,D=-1,H=0,K=0,ne=r,V=null;t:for(;;){for(var Y;ne!==u||h!==0&&ne.nodeType!==3||(k=_+h),ne!==g||c!==0&&ne.nodeType!==3||(D=_+c),ne.nodeType===3&&(_+=ne.nodeValue.length),(Y=ne.firstChild)!==null;)V=ne,ne=Y;for(;;){if(ne===r)break t;if(V===u&&++H===h&&(k=_),V===g&&++K===c&&(D=_),(Y=ne.nextSibling)!==null)break;ne=V,V=ne.parentNode}ne=Y}u=k===-1||D===-1?null:{start:k,end:D}}else u=null}u=u||{start:0,end:0}}else u=null;for(nm={focusedElem:r,selectionRange:u},ds=!1,Et=a;Et!==null;)if(a=Et,r=a.child,(a.subtreeFlags&1028)!==0&&r!==null)r.return=a,Et=r;else for(;Et!==null;){switch(a=Et,g=a.alternate,r=a.flags,a.tag){case 0:if((r&4)!==0&&(r=a.updateQueue,r=r!==null?r.events:null,r!==null))for(u=0;u<r.length;u++)h=r[u],h.ref.impl=h.nextImpl;break;case 11:case 15:break;case 1:if((r&1024)!==0&&g!==null){r=void 0,u=a,h=g.memoizedProps,g=g.memoizedState,c=u.stateNode;try{var he=ji(u.type,h);r=c.getSnapshotBeforeUpdate(he,g),c.__reactInternalSnapshotBeforeUpdate=r}catch(be){Ge(u,u.return,be)}}break;case 3:if((r&1024)!==0){if(r=a.stateNode.containerInfo,u=r.nodeType,u===9)am(r);else if(u===1)switch(r.nodeName){case"HEAD":case"HTML":case"BODY":am(r);break;default:r.textContent=""}}break;case 5:case 26:case 27:case 6:case 4:case 17:break;default:if((r&1024)!==0)throw Error(l(163))}if(r=a.sibling,r!==null){r.return=a.return,Et=r;break}Et=a.return}}function m0(r,a,u){var c=u.flags;switch(u.tag){case 0:case 11:case 15:br(r,u),c&4&&Il(5,u);break;case 1:if(br(r,u),c&4)if(r=u.stateNode,a===null)try{r.componentDidMount()}catch(_){Ge(u,u.return,_)}else{var h=ji(u.type,a.memoizedProps);a=a.memoizedState;try{r.componentDidUpdate(h,a,r.__reactInternalSnapshotBeforeUpdate)}catch(_){Ge(u,u.return,_)}}c&64&&o0(u),c&512&&Ul(u,u.return);break;case 3:if(br(r,u),c&64&&(r=u.updateQueue,r!==null)){if(a=null,u.child!==null)switch(u.child.tag){case 27:case 5:a=u.child.stateNode;break;case 1:a=u.child.stateNode}try{Qy(r,a)}catch(_){Ge(u,u.return,_)}}break;case 27:a===null&&c&4&&f0(u);case 26:case 5:br(r,u),a===null&&c&4&&s0(u),c&512&&Ul(u,u.return);break;case 12:br(r,u);break;case 31:br(r,u),c&4&&g0(r,u);break;case 13:br(r,u),c&4&&v0(r,u),c&64&&(r=u.memoizedState,r!==null&&(r=r.dehydrated,r!==null&&(u=E2.bind(null,u),G2(r,u))));break;case 22:if(c=u.memoizedState!==null||vr,!c){a=a!==null&&a.memoizedState!==null||xt,h=vr;var g=xt;vr=c,(xt=a)&&!g?xr(r,u,(u.subtreeFlags&8772)!==0):br(r,u),vr=h,xt=g}break;case 30:break;default:br(r,u)}}function h0(r){var a=r.alternate;a!==null&&(r.alternate=null,h0(a)),r.child=null,r.deletions=null,r.sibling=null,r.tag===5&&(a=r.stateNode,a!==null&&cf(a)),r.stateNode=null,r.return=null,r.dependencies=null,r.memoizedProps=null,r.memoizedState=null,r.pendingProps=null,r.stateNode=null,r.updateQueue=null}var ut=null,Yt=!1;function yr(r,a,u){for(u=u.child;u!==null;)p0(r,a,u),u=u.sibling}function p0(r,a,u){if(St&&typeof St.onCommitFiberUnmount=="function")try{St.onCommitFiberUnmount(Mt,u)}catch{}switch(u.tag){case 26:xt||Yn(u,a),yr(r,a,u),u.memoizedState?u.memoizedState.count--:u.stateNode&&(u=u.stateNode,u.parentNode.removeChild(u));break;case 27:xt||Yn(u,a);var c=ut,h=Yt;Qr(u.type)&&(ut=u.stateNode,Yt=!1),yr(r,a,u),Gl(u.stateNode),ut=c,Yt=h;break;case 5:xt||Yn(u,a);case 6:if(c=ut,h=Yt,ut=null,yr(r,a,u),ut=c,Yt=h,ut!==null)if(Yt)try{(ut.nodeType===9?ut.body:ut.nodeName==="HTML"?ut.ownerDocument.body:ut).removeChild(u.stateNode)}catch(g){Ge(u,a,g)}else try{ut.removeChild(u.stateNode)}catch(g){Ge(u,a,g)}break;case 18:ut!==null&&(Yt?(r=ut,ox(r.nodeType===9?r.body:r.nodeName==="HTML"?r.ownerDocument.body:r,u.stateNode),Da(r)):ox(ut,u.stateNode));break;case 4:c=ut,h=Yt,ut=u.stateNode.containerInfo,Yt=!0,yr(r,a,u),ut=c,Yt=h;break;case 0:case 11:case 14:case 15:Br(2,u,a),xt||Br(4,u,a),yr(r,a,u);break;case 1:xt||(Yn(u,a),c=u.stateNode,typeof c.componentWillUnmount=="function"&&u0(u,a,c)),yr(r,a,u);break;case 21:yr(r,a,u);break;case 22:xt=(c=xt)||u.memoizedState!==null,yr(r,a,u),xt=c;break;default:yr(r,a,u)}}function g0(r,a){if(a.memoizedState===null&&(r=a.alternate,r!==null&&(r=r.memoizedState,r!==null))){r=r.dehydrated;try{Da(r)}catch(u){Ge(a,a.return,u)}}}function v0(r,a){if(a.memoizedState===null&&(r=a.alternate,r!==null&&(r=r.memoizedState,r!==null&&(r=r.dehydrated,r!==null))))try{Da(r)}catch(u){Ge(a,a.return,u)}}function y2(r){switch(r.tag){case 31:case 13:case 19:var a=r.stateNode;return a===null&&(a=r.stateNode=new d0),a;case 22:return r=r.stateNode,a=r._retryCache,a===null&&(a=r._retryCache=new d0),a;default:throw Error(l(435,r.tag))}}function Gu(r,a){var u=y2(r);a.forEach(function(c){if(!u.has(c)){u.add(c);var h=j2.bind(null,r,c);c.then(h,h)}})}function Jt(r,a){var u=a.deletions;if(u!==null)for(var c=0;c<u.length;c++){var h=u[c],g=r,_=a,k=_;e:for(;k!==null;){switch(k.tag){case 27:if(Qr(k.type)){ut=k.stateNode,Yt=!1;break e}break;case 5:ut=k.stateNode,Yt=!1;break e;case 3:case 4:ut=k.stateNode.containerInfo,Yt=!0;break e}k=k.return}if(ut===null)throw Error(l(160));p0(g,_,h),ut=null,Yt=!1,g=h.alternate,g!==null&&(g.return=null),h.return=null}if(a.subtreeFlags&13886)for(a=a.child;a!==null;)y0(a,r),a=a.sibling}var Ln=null;function y0(r,a){var u=r.alternate,c=r.flags;switch(r.tag){case 0:case 11:case 14:case 15:Jt(a,r),Xt(r),c&4&&(Br(3,r,r.return),Il(3,r),Br(5,r,r.return));break;case 1:Jt(a,r),Xt(r),c&512&&(xt||u===null||Yn(u,u.return)),c&64&&vr&&(r=r.updateQueue,r!==null&&(c=r.callbacks,c!==null&&(u=r.shared.hiddenCallbacks,r.shared.hiddenCallbacks=u===null?c:u.concat(c))));break;case 26:var h=Ln;if(Jt(a,r),Xt(r),c&512&&(xt||u===null||Yn(u,u.return)),c&4){var g=u!==null?u.memoizedState:null;if(c=r.memoizedState,u===null)if(c===null)if(r.stateNode===null){e:{c=r.type,u=r.memoizedProps,h=h.ownerDocument||h;t:switch(c){case"title":g=h.getElementsByTagName("title")[0],(!g||g[cl]||g[zt]||g.namespaceURI==="http://www.w3.org/2000/svg"||g.hasAttribute("itemprop"))&&(g=h.createElement(c),h.head.insertBefore(g,h.querySelector("head > title"))),Ct(g,c,u),g[zt]=r,$t(g),c=g;break e;case"link":var _=yx("link","href",h).get(c+(u.href||""));if(_){for(var k=0;k<_.length;k++)if(g=_[k],g.getAttribute("href")===(u.href==null||u.href===""?null:u.href)&&g.getAttribute("rel")===(u.rel==null?null:u.rel)&&g.getAttribute("title")===(u.title==null?null:u.title)&&g.getAttribute("crossorigin")===(u.crossOrigin==null?null:u.crossOrigin)){_.splice(k,1);break t}}g=h.createElement(c),Ct(g,c,u),h.head.appendChild(g);break;case"meta":if(_=yx("meta","content",h).get(c+(u.content||""))){for(k=0;k<_.length;k++)if(g=_[k],g.getAttribute("content")===(u.content==null?null:""+u.content)&&g.getAttribute("name")===(u.name==null?null:u.name)&&g.getAttribute("property")===(u.property==null?null:u.property)&&g.getAttribute("http-equiv")===(u.httpEquiv==null?null:u.httpEquiv)&&g.getAttribute("charset")===(u.charSet==null?null:u.charSet)){_.splice(k,1);break t}}g=h.createElement(c),Ct(g,c,u),h.head.appendChild(g);break;default:throw Error(l(468,c))}g[zt]=r,$t(g),c=g}r.stateNode=c}else bx(h,r.type,r.stateNode);else r.stateNode=vx(h,c,r.memoizedProps);else g!==c?(g===null?u.stateNode!==null&&(u=u.stateNode,u.parentNode.removeChild(u)):g.count--,c===null?bx(h,r.type,r.stateNode):vx(h,c,r.memoizedProps)):c===null&&r.stateNode!==null&&Td(r,r.memoizedProps,u.memoizedProps)}break;case 27:Jt(a,r),Xt(r),c&512&&(xt||u===null||Yn(u,u.return)),u!==null&&c&4&&Td(r,r.memoizedProps,u.memoizedProps);break;case 5:if(Jt(a,r),Xt(r),c&512&&(xt||u===null||Yn(u,u.return)),r.flags&32){h=r.stateNode;try{na(h,"")}catch(he){Ge(r,r.return,he)}}c&4&&r.stateNode!=null&&(h=r.memoizedProps,Td(r,h,u!==null?u.memoizedProps:h)),c&1024&&(Ad=!0);break;case 6:if(Jt(a,r),Xt(r),c&4){if(r.stateNode===null)throw Error(l(162));c=r.memoizedProps,u=r.stateNode;try{u.nodeValue=c}catch(he){Ge(r,r.return,he)}}break;case 3:if(us=null,h=Ln,Ln=ls(a.containerInfo),Jt(a,r),Ln=h,Xt(r),c&4&&u!==null&&u.memoizedState.isDehydrated)try{Da(a.containerInfo)}catch(he){Ge(r,r.return,he)}Ad&&(Ad=!1,b0(r));break;case 4:c=Ln,Ln=ls(r.stateNode.containerInfo),Jt(a,r),Xt(r),Ln=c;break;case 12:Jt(a,r),Xt(r);break;case 31:Jt(a,r),Xt(r),c&4&&(c=r.updateQueue,c!==null&&(r.updateQueue=null,Gu(r,c)));break;case 13:Jt(a,r),Xt(r),r.child.flags&8192&&r.memoizedState!==null!=(u!==null&&u.memoizedState!==null)&&(Yu=Lt()),c&4&&(c=r.updateQueue,c!==null&&(r.updateQueue=null,Gu(r,c)));break;case 22:h=r.memoizedState!==null;var D=u!==null&&u.memoizedState!==null,H=vr,K=xt;if(vr=H||h,xt=K||D,Jt(a,r),xt=K,vr=H,Xt(r),c&8192)e:for(a=r.stateNode,a._visibility=h?a._visibility&-2:a._visibility|1,h&&(u===null||D||vr||xt||zi(r)),u=null,a=r;;){if(a.tag===5||a.tag===26){if(u===null){D=u=a;try{if(g=D.stateNode,h)_=g.style,typeof _.setProperty=="function"?_.setProperty("display","none","important"):_.display="none";else{k=D.stateNode;var ne=D.memoizedProps.style,V=ne!=null&&ne.hasOwnProperty("display")?ne.display:null;k.style.display=V==null||typeof V=="boolean"?"":(""+V).trim()}}catch(he){Ge(D,D.return,he)}}}else if(a.tag===6){if(u===null){D=a;try{D.stateNode.nodeValue=h?"":D.memoizedProps}catch(he){Ge(D,D.return,he)}}}else if(a.tag===18){if(u===null){D=a;try{var Y=D.stateNode;h?ux(Y,!0):ux(D.stateNode,!1)}catch(he){Ge(D,D.return,he)}}}else if((a.tag!==22&&a.tag!==23||a.memoizedState===null||a===r)&&a.child!==null){a.child.return=a,a=a.child;continue}if(a===r)break e;for(;a.sibling===null;){if(a.return===null||a.return===r)break e;u===a&&(u=null),a=a.return}u===a&&(u=null),a.sibling.return=a.return,a=a.sibling}c&4&&(c=r.updateQueue,c!==null&&(u=c.retryQueue,u!==null&&(c.retryQueue=null,Gu(r,u))));break;case 19:Jt(a,r),Xt(r),c&4&&(c=r.updateQueue,c!==null&&(r.updateQueue=null,Gu(r,c)));break;case 30:break;case 21:break;default:Jt(a,r),Xt(r)}}function Xt(r){var a=r.flags;if(a&2){try{for(var u,c=r.return;c!==null;){if(c0(c)){u=c;break}c=c.return}if(u==null)throw Error(l(160));switch(u.tag){case 27:var h=u.stateNode,g=Cd(r);Hu(r,g,h);break;case 5:var _=u.stateNode;u.flags&32&&(na(_,""),u.flags&=-33);var k=Cd(r);Hu(r,k,_);break;case 3:case 4:var D=u.stateNode.containerInfo,H=Cd(r);Dd(r,H,D);break;default:throw Error(l(161))}}catch(K){Ge(r,r.return,K)}r.flags&=-3}a&4096&&(r.flags&=-4097)}function b0(r){if(r.subtreeFlags&1024)for(r=r.child;r!==null;){var a=r;b0(a),a.tag===5&&a.flags&1024&&a.stateNode.reset(),r=r.sibling}}function br(r,a){if(a.subtreeFlags&8772)for(a=a.child;a!==null;)m0(r,a.alternate,a),a=a.sibling}function zi(r){for(r=r.child;r!==null;){var a=r;switch(a.tag){case 0:case 11:case 14:case 15:Br(4,a,a.return),zi(a);break;case 1:Yn(a,a.return);var u=a.stateNode;typeof u.componentWillUnmount=="function"&&u0(a,a.return,u),zi(a);break;case 27:Gl(a.stateNode);case 26:case 5:Yn(a,a.return),zi(a);break;case 22:a.memoizedState===null&&zi(a);break;case 30:zi(a);break;default:zi(a)}r=r.sibling}}function xr(r,a,u){for(u=u&&(a.subtreeFlags&8772)!==0,a=a.child;a!==null;){var c=a.alternate,h=r,g=a,_=g.flags;switch(g.tag){case 0:case 11:case 15:xr(h,g,u),Il(4,g);break;case 1:if(xr(h,g,u),c=g,h=c.stateNode,typeof h.componentDidMount=="function")try{h.componentDidMount()}catch(H){Ge(c,c.return,H)}if(c=g,h=c.updateQueue,h!==null){var k=c.stateNode;try{var D=h.shared.hiddenCallbacks;if(D!==null)for(h.shared.hiddenCallbacks=null,h=0;h<D.length;h++)Xy(D[h],k)}catch(H){Ge(c,c.return,H)}}u&&_&64&&o0(g),Ul(g,g.return);break;case 27:f0(g);case 26:case 5:xr(h,g,u),u&&c===null&&_&4&&s0(g),Ul(g,g.return);break;case 12:xr(h,g,u);break;case 31:xr(h,g,u),u&&_&4&&g0(h,g);break;case 13:xr(h,g,u),u&&_&4&&v0(h,g);break;case 22:g.memoizedState===null&&xr(h,g,u),Ul(g,g.return);break;case 30:break;default:xr(h,g,u)}a=a.sibling}}function Rd(r,a){var u=null;r!==null&&r.memoizedState!==null&&r.memoizedState.cachePool!==null&&(u=r.memoizedState.cachePool.pool),r=null,a.memoizedState!==null&&a.memoizedState.cachePool!==null&&(r=a.memoizedState.cachePool.pool),r!==u&&(r!=null&&r.refCount++,u!=null&&kl(u))}function Id(r,a){r=null,a.alternate!==null&&(r=a.alternate.memoizedState.cache),a=a.memoizedState.cache,a!==r&&(a.refCount++,r!=null&&kl(r))}function Mn(r,a,u,c){if(a.subtreeFlags&10256)for(a=a.child;a!==null;)x0(r,a,u,c),a=a.sibling}function x0(r,a,u,c){var h=a.flags;switch(a.tag){case 0:case 11:case 15:Mn(r,a,u,c),h&2048&&Il(9,a);break;case 1:Mn(r,a,u,c);break;case 3:Mn(r,a,u,c),h&2048&&(r=null,a.alternate!==null&&(r=a.alternate.memoizedState.cache),a=a.memoizedState.cache,a!==r&&(a.refCount++,r!=null&&kl(r)));break;case 12:if(h&2048){Mn(r,a,u,c),r=a.stateNode;try{var g=a.memoizedProps,_=g.id,k=g.onPostCommit;typeof k=="function"&&k(_,a.alternate===null?"mount":"update",r.passiveEffectDuration,-0)}catch(D){Ge(a,a.return,D)}}else Mn(r,a,u,c);break;case 31:Mn(r,a,u,c);break;case 13:Mn(r,a,u,c);break;case 23:break;case 22:g=a.stateNode,_=a.alternate,a.memoizedState!==null?g._visibility&2?Mn(r,a,u,c):Ll(r,a):g._visibility&2?Mn(r,a,u,c):(g._visibility|=2,Sa(r,a,u,c,(a.subtreeFlags&10256)!==0||!1)),h&2048&&Rd(_,a);break;case 24:Mn(r,a,u,c),h&2048&&Id(a.alternate,a);break;default:Mn(r,a,u,c)}}function Sa(r,a,u,c,h){for(h=h&&((a.subtreeFlags&10256)!==0||!1),a=a.child;a!==null;){var g=r,_=a,k=u,D=c,H=_.flags;switch(_.tag){case 0:case 11:case 15:Sa(g,_,k,D,h),Il(8,_);break;case 23:break;case 22:var K=_.stateNode;_.memoizedState!==null?K._visibility&2?Sa(g,_,k,D,h):Ll(g,_):(K._visibility|=2,Sa(g,_,k,D,h)),h&&H&2048&&Rd(_.alternate,_);break;case 24:Sa(g,_,k,D,h),h&&H&2048&&Id(_.alternate,_);break;default:Sa(g,_,k,D,h)}a=a.sibling}}function Ll(r,a){if(a.subtreeFlags&10256)for(a=a.child;a!==null;){var u=r,c=a,h=c.flags;switch(c.tag){case 22:Ll(u,c),h&2048&&Rd(c.alternate,c);break;case 24:Ll(u,c),h&2048&&Id(c.alternate,c);break;default:Ll(u,c)}a=a.sibling}}var Ml=8192;function ka(r,a,u){if(r.subtreeFlags&Ml)for(r=r.child;r!==null;)_0(r,a,u),r=r.sibling}function _0(r,a,u){switch(r.tag){case 26:ka(r,a,u),r.flags&Ml&&r.memoizedState!==null&&iO(u,Ln,r.memoizedState,r.memoizedProps);break;case 5:ka(r,a,u);break;case 3:case 4:var c=Ln;Ln=ls(r.stateNode.containerInfo),ka(r,a,u),Ln=c;break;case 22:r.memoizedState===null&&(c=r.alternate,c!==null&&c.memoizedState!==null?(c=Ml,Ml=16777216,ka(r,a,u),Ml=c):ka(r,a,u));break;default:ka(r,a,u)}}function S0(r){var a=r.alternate;if(a!==null&&(r=a.child,r!==null)){a.child=null;do a=r.sibling,r.sibling=null,r=a;while(r!==null)}}function Pl(r){var a=r.deletions;if((r.flags&16)!==0){if(a!==null)for(var u=0;u<a.length;u++){var c=a[u];Et=c,w0(c,r)}S0(r)}if(r.subtreeFlags&10256)for(r=r.child;r!==null;)k0(r),r=r.sibling}function k0(r){switch(r.tag){case 0:case 11:case 15:Pl(r),r.flags&2048&&Br(9,r,r.return);break;case 3:Pl(r);break;case 12:Pl(r);break;case 22:var a=r.stateNode;r.memoizedState!==null&&a._visibility&2&&(r.return===null||r.return.tag!==13)?(a._visibility&=-3,Vu(r)):Pl(r);break;default:Pl(r)}}function Vu(r){var a=r.deletions;if((r.flags&16)!==0){if(a!==null)for(var u=0;u<a.length;u++){var c=a[u];Et=c,w0(c,r)}S0(r)}for(r=r.child;r!==null;){switch(a=r,a.tag){case 0:case 11:case 15:Br(8,a,a.return),Vu(a);break;case 22:u=a.stateNode,u._visibility&2&&(u._visibility&=-3,Vu(a));break;default:Vu(a)}r=r.sibling}}function w0(r,a){for(;Et!==null;){var u=Et;switch(u.tag){case 0:case 11:case 15:Br(8,u,a);break;case 23:case 22:if(u.memoizedState!==null&&u.memoizedState.cachePool!==null){var c=u.memoizedState.cachePool.pool;c!=null&&c.refCount++}break;case 24:kl(u.memoizedState.cache)}if(c=u.child,c!==null)c.return=u,Et=c;else e:for(u=r;Et!==null;){c=Et;var h=c.sibling,g=c.return;if(h0(c),c===u){Et=null;break e}if(h!==null){h.return=g,Et=h;break e}Et=g}}}var b2={getCacheForType:function(r){var a=Ot(vt),u=a.data.get(r);return u===void 0&&(u=r(),a.data.set(r,u)),u},cacheSignal:function(){return Ot(vt).controller.signal}},x2=typeof WeakMap=="function"?WeakMap:Map,Fe=0,Ke=null,De=null,Ue=0,He=0,un=null,Hr=!1,wa=!1,Ud=!1,_r=0,dt=0,Gr=0,Ni=0,Ld=0,sn=0,$a=0,Zl=null,Qt=null,Md=!1,Yu=0,$0=0,Ju=1/0,Xu=null,Vr=null,kt=0,Yr=null,Ea=null,Sr=0,Pd=0,Zd=null,E0=null,ql=0,qd=null;function cn(){return(Fe&2)!==0&&Ue!==0?Ue&-Ue:A.T!==null?Yd():qv()}function j0(){if(sn===0)if((Ue&536870912)===0||Me){var r=iu;iu<<=1,(iu&3932160)===0&&(iu=262144),sn=r}else sn=536870912;return r=ln.current,r!==null&&(r.flags|=32),sn}function Kt(r,a,u){(r===Ke&&(He===2||He===9)||r.cancelPendingCommit!==null)&&(ja(r,0),Jr(r,Ue,sn,!1)),sl(r,u),((Fe&2)===0||r!==Ke)&&(r===Ke&&((Fe&2)===0&&(Ni|=u),dt===4&&Jr(r,Ue,sn,!1)),Jn(r))}function z0(r,a,u){if((Fe&6)!==0)throw Error(l(327));var c=!u&&(a&127)===0&&(a&r.expiredLanes)===0||ul(r,a),h=c?k2(r,a):Bd(r,a,!0),g=c;do{if(h===0){wa&&!c&&Jr(r,a,0,!1);break}else{if(u=r.current.alternate,g&&!_2(u)){h=Bd(r,a,!1),g=!1;continue}if(h===2){if(g=a,r.errorRecoveryDisabledLanes&g)var _=0;else _=r.pendingLanes&-536870913,_=_!==0?_:_&536870912?536870912:0;if(_!==0){a=_;e:{var k=r;h=Zl;var D=k.current.memoizedState.isDehydrated;if(D&&(ja(k,_).flags|=256),_=Bd(k,_,!1),_!==2){if(Ud&&!D){k.errorRecoveryDisabledLanes|=g,Ni|=g,h=4;break e}g=Qt,Qt=h,g!==null&&(Qt===null?Qt=g:Qt.push.apply(Qt,g))}h=_}if(g=!1,h!==2)continue}}if(h===1){ja(r,0),Jr(r,a,0,!0);break}e:{switch(c=r,g=h,g){case 0:case 1:throw Error(l(345));case 4:if((a&4194048)!==a)break;case 6:Jr(c,a,sn,!Hr);break e;case 2:Qt=null;break;case 3:case 5:break;default:throw Error(l(329))}if((a&62914560)===a&&(h=Yu+300-Lt(),10<h)){if(Jr(c,a,sn,!Hr),lu(c,0,!0)!==0)break e;Sr=a,c.timeoutHandle=ax(N0.bind(null,c,u,Qt,Xu,Md,a,sn,Ni,$a,Hr,g,"Throttled",-0,0),h);break e}N0(c,u,Qt,Xu,Md,a,sn,Ni,$a,Hr,g,null,-0,0)}}break}while(!0);Jn(r)}function N0(r,a,u,c,h,g,_,k,D,H,K,ne,V,Y){if(r.timeoutHandle=-1,ne=a.subtreeFlags,ne&8192||(ne&16785408)===16785408){ne={stylesheets:null,count:0,imgCount:0,imgBytes:0,suspenseyImages:[],waitingForImages:!0,waitingForViewTransition:!1,unsuspend:or},_0(a,g,ne);var he=(g&62914560)===g?Yu-Lt():(g&4194048)===g?$0-Lt():0;if(he=aO(ne,he),he!==null){Sr=g,r.cancelPendingCommit=he(U0.bind(null,r,a,g,u,c,h,_,k,D,K,ne,null,V,Y)),Jr(r,g,_,!H);return}}U0(r,a,g,u,c,h,_,k,D)}function _2(r){for(var a=r;;){var u=a.tag;if((u===0||u===11||u===15)&&a.flags&16384&&(u=a.updateQueue,u!==null&&(u=u.stores,u!==null)))for(var c=0;c<u.length;c++){var h=u[c],g=h.getSnapshot;h=h.value;try{if(!rn(g(),h))return!1}catch{return!1}}if(u=a.child,a.subtreeFlags&16384&&u!==null)u.return=a,a=u;else{if(a===r)break;for(;a.sibling===null;){if(a.return===null||a.return===r)return!0;a=a.return}a.sibling.return=a.return,a=a.sibling}}return!0}function Jr(r,a,u,c){a&=~Ld,a&=~Ni,r.suspendedLanes|=a,r.pingedLanes&=~a,c&&(r.warmLanes|=a),c=r.expirationTimes;for(var h=a;0<h;){var g=31-Qe(h),_=1<<g;c[g]=-1,h&=~_}u!==0&&Mv(r,u,a)}function Qu(){return(Fe&6)===0?(Fl(0),!1):!0}function Fd(){if(De!==null){if(He===0)var r=De.return;else r=De,fr=xi=null,ad(r),va=null,$l=0,r=De;for(;r!==null;)l0(r.alternate,r),r=r.return;De=null}}function ja(r,a){var u=r.timeoutHandle;u!==-1&&(r.timeoutHandle=-1,Z2(u)),u=r.cancelPendingCommit,u!==null&&(r.cancelPendingCommit=null,u()),Sr=0,Fd(),Ke=r,De=u=sr(r.current,null),Ue=a,He=0,un=null,Hr=!1,wa=ul(r,a),Ud=!1,$a=sn=Ld=Ni=Gr=dt=0,Qt=Zl=null,Md=!1,(a&8)!==0&&(a|=a&32);var c=r.entangledLanes;if(c!==0)for(r=r.entanglements,c&=a;0<c;){var h=31-Qe(c),g=1<<h;a|=r[h],c&=~g}return _r=a,yu(),u}function O0(r,a){Ee=null,A.H=Dl,a===ga||a===Eu?(a=Gy(),He=3):a===Vf?(a=Gy(),He=4):He=a===_d?8:a!==null&&typeof a=="object"&&typeof a.then=="function"?6:1,un=a,De===null&&(dt=1,Pu(r,xn(a,r.current)))}function T0(){var r=ln.current;return r===null?!0:(Ue&4194048)===Ue?wn===null:(Ue&62914560)===Ue||(Ue&536870912)!==0?r===wn:!1}function C0(){var r=A.H;return A.H=Dl,r===null?Dl:r}function D0(){var r=A.A;return A.A=b2,r}function Ku(){dt=4,Hr||(Ue&4194048)!==Ue&&ln.current!==null||(wa=!0),(Gr&134217727)===0&&(Ni&134217727)===0||Ke===null||Jr(Ke,Ue,sn,!1)}function Bd(r,a,u){var c=Fe;Fe|=2;var h=C0(),g=D0();(Ke!==r||Ue!==a)&&(Xu=null,ja(r,a)),a=!1;var _=dt;e:do try{if(He!==0&&De!==null){var k=De,D=un;switch(He){case 8:Fd(),_=6;break e;case 3:case 2:case 9:case 6:ln.current===null&&(a=!0);var H=He;if(He=0,un=null,za(r,k,D,H),u&&wa){_=0;break e}break;default:H=He,He=0,un=null,za(r,k,D,H)}}S2(),_=dt;break}catch(K){O0(r,K)}while(!0);return a&&r.shellSuspendCounter++,fr=xi=null,Fe=c,A.H=h,A.A=g,De===null&&(Ke=null,Ue=0,yu()),_}function S2(){for(;De!==null;)A0(De)}function k2(r,a){var u=Fe;Fe|=2;var c=C0(),h=D0();Ke!==r||Ue!==a?(Xu=null,Ju=Lt()+500,ja(r,a)):wa=ul(r,a);e:do try{if(He!==0&&De!==null){a=De;var g=un;t:switch(He){case 1:He=0,un=null,za(r,a,g,1);break;case 2:case 9:if(By(g)){He=0,un=null,R0(a);break}a=function(){He!==2&&He!==9||Ke!==r||(He=7),Jn(r)},g.then(a,a);break e;case 3:He=7;break e;case 4:He=5;break e;case 7:By(g)?(He=0,un=null,R0(a)):(He=0,un=null,za(r,a,g,7));break;case 5:var _=null;switch(De.tag){case 26:_=De.memoizedState;case 5:case 27:var k=De;if(_?xx(_):k.stateNode.complete){He=0,un=null;var D=k.sibling;if(D!==null)De=D;else{var H=k.return;H!==null?(De=H,Wu(H)):De=null}break t}}He=0,un=null,za(r,a,g,5);break;case 6:He=0,un=null,za(r,a,g,6);break;case 8:Fd(),dt=6;break e;default:throw Error(l(462))}}w2();break}catch(K){O0(r,K)}while(!0);return fr=xi=null,A.H=c,A.A=h,Fe=u,De!==null?0:(Ke=null,Ue=0,yu(),dt)}function w2(){for(;De!==null&&!nf();)A0(De)}function A0(r){var a=i0(r.alternate,r,_r);r.memoizedProps=r.pendingProps,a===null?Wu(r):De=a}function R0(r){var a=r,u=a.alternate;switch(a.tag){case 15:case 0:a=Kb(u,a,a.pendingProps,a.type,void 0,Ue);break;case 11:a=Kb(u,a,a.pendingProps,a.type.render,a.ref,Ue);break;case 5:ad(a);default:l0(u,a),a=De=Dy(a,_r),a=i0(u,a,_r)}r.memoizedProps=r.pendingProps,a===null?Wu(r):De=a}function za(r,a,u,c){fr=xi=null,ad(a),va=null,$l=0;var h=a.return;try{if(d2(r,h,a,u,Ue)){dt=1,Pu(r,xn(u,r.current)),De=null;return}}catch(g){if(h!==null)throw De=h,g;dt=1,Pu(r,xn(u,r.current)),De=null;return}a.flags&32768?(Me||c===1?r=!0:wa||(Ue&536870912)!==0?r=!1:(Hr=r=!0,(c===2||c===9||c===3||c===6)&&(c=ln.current,c!==null&&c.tag===13&&(c.flags|=16384))),I0(a,r)):Wu(a)}function Wu(r){var a=r;do{if((a.flags&32768)!==0){I0(a,Hr);return}r=a.return;var u=p2(a.alternate,a,_r);if(u!==null){De=u;return}if(a=a.sibling,a!==null){De=a;return}De=a=r}while(a!==null);dt===0&&(dt=5)}function I0(r,a){do{var u=g2(r.alternate,r);if(u!==null){u.flags&=32767,De=u;return}if(u=r.return,u!==null&&(u.flags|=32768,u.subtreeFlags=0,u.deletions=null),!a&&(r=r.sibling,r!==null)){De=r;return}De=r=u}while(r!==null);dt=6,De=null}function U0(r,a,u,c,h,g,_,k,D){r.cancelPendingCommit=null;do es();while(kt!==0);if((Fe&6)!==0)throw Error(l(327));if(a!==null){if(a===r.current)throw Error(l(177));if(g=a.lanes|a.childLanes,g|=Cf,rN(r,u,g,_,k,D),r===Ke&&(De=Ke=null,Ue=0),Ea=a,Yr=r,Sr=u,Pd=g,Zd=h,E0=c,(a.subtreeFlags&10256)!==0||(a.flags&10256)!==0?(r.callbackNode=null,r.callbackPriority=0,z2(_e,function(){return q0(),null})):(r.callbackNode=null,r.callbackPriority=0),c=(a.flags&13878)!==0,(a.subtreeFlags&13878)!==0||c){c=A.T,A.T=null,h=q.p,q.p=2,_=Fe,Fe|=4;try{v2(r,a,u)}finally{Fe=_,q.p=h,A.T=c}}kt=1,L0(),M0(),P0()}}function L0(){if(kt===1){kt=0;var r=Yr,a=Ea,u=(a.flags&13878)!==0;if((a.subtreeFlags&13878)!==0||u){u=A.T,A.T=null;var c=q.p;q.p=2;var h=Fe;Fe|=4;try{y0(a,r);var g=nm,_=wy(r.containerInfo),k=g.focusedElem,D=g.selectionRange;if(_!==k&&k&&k.ownerDocument&&ky(k.ownerDocument.documentElement,k)){if(D!==null&&jf(k)){var H=D.start,K=D.end;if(K===void 0&&(K=H),"selectionStart"in k)k.selectionStart=H,k.selectionEnd=Math.min(K,k.value.length);else{var ne=k.ownerDocument||document,V=ne&&ne.defaultView||window;if(V.getSelection){var Y=V.getSelection(),he=k.textContent.length,be=Math.min(D.start,he),Xe=D.end===void 0?be:Math.min(D.end,he);!Y.extend&&be>Xe&&(_=Xe,Xe=be,be=_);var L=Sy(k,be),I=Sy(k,Xe);if(L&&I&&(Y.rangeCount!==1||Y.anchorNode!==L.node||Y.anchorOffset!==L.offset||Y.focusNode!==I.node||Y.focusOffset!==I.offset)){var F=ne.createRange();F.setStart(L.node,L.offset),Y.removeAllRanges(),be>Xe?(Y.addRange(F),Y.extend(I.node,I.offset)):(F.setEnd(I.node,I.offset),Y.addRange(F))}}}}for(ne=[],Y=k;Y=Y.parentNode;)Y.nodeType===1&&ne.push({element:Y,left:Y.scrollLeft,top:Y.scrollTop});for(typeof k.focus=="function"&&k.focus(),k=0;k<ne.length;k++){var ee=ne[k];ee.element.scrollLeft=ee.left,ee.element.scrollTop=ee.top}}ds=!!tm,nm=tm=null}finally{Fe=h,q.p=c,A.T=u}}r.current=a,kt=2}}function M0(){if(kt===2){kt=0;var r=Yr,a=Ea,u=(a.flags&8772)!==0;if((a.subtreeFlags&8772)!==0||u){u=A.T,A.T=null;var c=q.p;q.p=2;var h=Fe;Fe|=4;try{m0(r,a.alternate,a)}finally{Fe=h,q.p=c,A.T=u}}kt=3}}function P0(){if(kt===4||kt===3){kt=0,rf();var r=Yr,a=Ea,u=Sr,c=E0;(a.subtreeFlags&10256)!==0||(a.flags&10256)!==0?kt=5:(kt=0,Ea=Yr=null,Z0(r,r.pendingLanes));var h=r.pendingLanes;if(h===0&&(Vr=null),uf(u),a=a.stateNode,St&&typeof St.onCommitFiberRoot=="function")try{St.onCommitFiberRoot(Mt,a,void 0,(a.current.flags&128)===128)}catch{}if(c!==null){a=A.T,h=q.p,q.p=2,A.T=null;try{for(var g=r.onRecoverableError,_=0;_<c.length;_++){var k=c[_];g(k.value,{componentStack:k.stack})}}finally{A.T=a,q.p=h}}(Sr&3)!==0&&es(),Jn(r),h=r.pendingLanes,(u&261930)!==0&&(h&42)!==0?r===qd?ql++:(ql=0,qd=r):ql=0,Fl(0)}}function Z0(r,a){(r.pooledCacheLanes&=a)===0&&(a=r.pooledCache,a!=null&&(r.pooledCache=null,kl(a)))}function es(){return L0(),M0(),P0(),q0()}function q0(){if(kt!==5)return!1;var r=Yr,a=Pd;Pd=0;var u=uf(Sr),c=A.T,h=q.p;try{q.p=32>u?32:u,A.T=null,u=Zd,Zd=null;var g=Yr,_=Sr;if(kt=0,Ea=Yr=null,Sr=0,(Fe&6)!==0)throw Error(l(331));var k=Fe;if(Fe|=4,k0(g.current),x0(g,g.current,_,u),Fe=k,Fl(0,!1),St&&typeof St.onPostCommitFiberRoot=="function")try{St.onPostCommitFiberRoot(Mt,g)}catch{}return!0}finally{q.p=h,A.T=c,Z0(r,a)}}function F0(r,a,u){a=xn(u,a),a=xd(r.stateNode,a,2),r=Zr(r,a,2),r!==null&&(sl(r,2),Jn(r))}function Ge(r,a,u){if(r.tag===3)F0(r,r,u);else for(;a!==null;){if(a.tag===3){F0(a,r,u);break}else if(a.tag===1){var c=a.stateNode;if(typeof a.type.getDerivedStateFromError=="function"||typeof c.componentDidCatch=="function"&&(Vr===null||!Vr.has(c))){r=xn(u,r),u=Bb(2),c=Zr(a,u,2),c!==null&&(Hb(u,c,a,r),sl(c,2),Jn(c));break}}a=a.return}}function Hd(r,a,u){var c=r.pingCache;if(c===null){c=r.pingCache=new x2;var h=new Set;c.set(a,h)}else h=c.get(a),h===void 0&&(h=new Set,c.set(a,h));h.has(u)||(Ud=!0,h.add(u),r=$2.bind(null,r,a,u),a.then(r,r))}function $2(r,a,u){var c=r.pingCache;c!==null&&c.delete(a),r.pingedLanes|=r.suspendedLanes&u,r.warmLanes&=~u,Ke===r&&(Ue&u)===u&&(dt===4||dt===3&&(Ue&62914560)===Ue&&300>Lt()-Yu?(Fe&2)===0&&ja(r,0):Ld|=u,$a===Ue&&($a=0)),Jn(r)}function B0(r,a){a===0&&(a=Lv()),r=vi(r,a),r!==null&&(sl(r,a),Jn(r))}function E2(r){var a=r.memoizedState,u=0;a!==null&&(u=a.retryLane),B0(r,u)}function j2(r,a){var u=0;switch(r.tag){case 31:case 13:var c=r.stateNode,h=r.memoizedState;h!==null&&(u=h.retryLane);break;case 19:c=r.stateNode;break;case 22:c=r.stateNode._retryCache;break;default:throw Error(l(314))}c!==null&&c.delete(a),B0(r,u)}function z2(r,a){return Ji(r,a)}var ts=null,Na=null,Gd=!1,ns=!1,Vd=!1,Xr=0;function Jn(r){r!==Na&&r.next===null&&(Na===null?ts=Na=r:Na=Na.next=r),ns=!0,Gd||(Gd=!0,O2())}function Fl(r,a){if(!Vd&&ns){Vd=!0;do for(var u=!1,c=ts;c!==null;){if(r!==0){var h=c.pendingLanes;if(h===0)var g=0;else{var _=c.suspendedLanes,k=c.pingedLanes;g=(1<<31-Qe(42|r)+1)-1,g&=h&~(_&~k),g=g&201326741?g&201326741|1:g?g|2:0}g!==0&&(u=!0,Y0(c,g))}else g=Ue,g=lu(c,c===Ke?g:0,c.cancelPendingCommit!==null||c.timeoutHandle!==-1),(g&3)===0||ul(c,g)||(u=!0,Y0(c,g));c=c.next}while(u);Vd=!1}}function N2(){H0()}function H0(){ns=Gd=!1;var r=0;Xr!==0&&P2()&&(r=Xr);for(var a=Lt(),u=null,c=ts;c!==null;){var h=c.next,g=G0(c,a);g===0?(c.next=null,u===null?ts=h:u.next=h,h===null&&(Na=u)):(u=c,(r!==0||(g&3)!==0)&&(ns=!0)),c=h}kt!==0&&kt!==5||Fl(r),Xr!==0&&(Xr=0)}function G0(r,a){for(var u=r.suspendedLanes,c=r.pingedLanes,h=r.expirationTimes,g=r.pendingLanes&-62914561;0<g;){var _=31-Qe(g),k=1<<_,D=h[_];D===-1?((k&u)===0||(k&c)!==0)&&(h[_]=nN(k,a)):D<=a&&(r.expiredLanes|=k),g&=~k}if(a=Ke,u=Ue,u=lu(r,r===a?u:0,r.cancelPendingCommit!==null||r.timeoutHandle!==-1),c=r.callbackNode,u===0||r===a&&(He===2||He===9)||r.cancelPendingCommit!==null)return c!==null&&c!==null&&ol(c),r.callbackNode=null,r.callbackPriority=0;if((u&3)===0||ul(r,u)){if(a=u&-u,a===r.callbackPriority)return a;switch(c!==null&&ol(c),uf(u)){case 2:case 8:u=se;break;case 32:u=_e;break;case 268435456:u=Be;break;default:u=_e}return c=V0.bind(null,r),u=Ji(u,c),r.callbackPriority=a,r.callbackNode=u,a}return c!==null&&c!==null&&ol(c),r.callbackPriority=2,r.callbackNode=null,2}function V0(r,a){if(kt!==0&&kt!==5)return r.callbackNode=null,r.callbackPriority=0,null;var u=r.callbackNode;if(es()&&r.callbackNode!==u)return null;var c=Ue;return c=lu(r,r===Ke?c:0,r.cancelPendingCommit!==null||r.timeoutHandle!==-1),c===0?null:(z0(r,c,a),G0(r,Lt()),r.callbackNode!=null&&r.callbackNode===u?V0.bind(null,r):null)}function Y0(r,a){if(es())return null;z0(r,a,!0)}function O2(){q2(function(){(Fe&6)!==0?Ji(W,N2):H0()})}function Yd(){if(Xr===0){var r=ha;r===0&&(r=ru,ru<<=1,(ru&261888)===0&&(ru=256)),Xr=r}return Xr}function J0(r){return r==null||typeof r=="symbol"||typeof r=="boolean"?null:typeof r=="function"?r:cu(""+r)}function X0(r,a){var u=a.ownerDocument.createElement("input");return u.name=a.name,u.value=a.value,r.id&&u.setAttribute("form",r.id),a.parentNode.insertBefore(u,a),r=new FormData(r),u.parentNode.removeChild(u),r}function T2(r,a,u,c,h){if(a==="submit"&&u&&u.stateNode===h){var g=J0((h[Gt]||null).action),_=c.submitter;_&&(a=(a=_[Gt]||null)?J0(a.formAction):_.getAttribute("formAction"),a!==null&&(g=a,_=null));var k=new hu("action","action",null,c,h);r.push({event:k,listeners:[{instance:null,listener:function(){if(c.defaultPrevented){if(Xr!==0){var D=_?X0(h,_):new FormData(h);hd(u,{pending:!0,data:D,method:h.method,action:g},null,D)}}else typeof g=="function"&&(k.preventDefault(),D=_?X0(h,_):new FormData(h),hd(u,{pending:!0,data:D,method:h.method,action:g},g,D))},currentTarget:h}]})}}for(var Jd=0;Jd<Tf.length;Jd++){var Xd=Tf[Jd],C2=Xd.toLowerCase(),D2=Xd[0].toUpperCase()+Xd.slice(1);Un(C2,"on"+D2)}Un(jy,"onAnimationEnd"),Un(zy,"onAnimationIteration"),Un(Ny,"onAnimationStart"),Un("dblclick","onDoubleClick"),Un("focusin","onFocus"),Un("focusout","onBlur"),Un(JN,"onTransitionRun"),Un(XN,"onTransitionStart"),Un(QN,"onTransitionCancel"),Un(Oy,"onTransitionEnd"),ea("onMouseEnter",["mouseout","mouseover"]),ea("onMouseLeave",["mouseout","mouseover"]),ea("onPointerEnter",["pointerout","pointerover"]),ea("onPointerLeave",["pointerout","pointerover"]),mi("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),mi("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),mi("onBeforeInput",["compositionend","keypress","textInput","paste"]),mi("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),mi("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),mi("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Bl="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(" "),A2=new Set("beforetoggle cancel close invalid load scroll scrollend toggle".split(" ").concat(Bl));function Q0(r,a){a=(a&4)!==0;for(var u=0;u<r.length;u++){var c=r[u],h=c.event;c=c.listeners;e:{var g=void 0;if(a)for(var _=c.length-1;0<=_;_--){var k=c[_],D=k.instance,H=k.currentTarget;if(k=k.listener,D!==g&&h.isPropagationStopped())break e;g=k,h.currentTarget=H;try{g(h)}catch(K){vu(K)}h.currentTarget=null,g=D}else for(_=0;_<c.length;_++){if(k=c[_],D=k.instance,H=k.currentTarget,k=k.listener,D!==g&&h.isPropagationStopped())break e;g=k,h.currentTarget=H;try{g(h)}catch(K){vu(K)}h.currentTarget=null,g=D}}}}function Ae(r,a){var u=a[sf];u===void 0&&(u=a[sf]=new Set);var c=r+"__bubble";u.has(c)||(K0(a,r,2,!1),u.add(c))}function Qd(r,a,u){var c=0;a&&(c|=4),K0(u,r,c,a)}var rs="_reactListening"+Math.random().toString(36).slice(2);function Kd(r){if(!r[rs]){r[rs]=!0,Hv.forEach(function(u){u!=="selectionchange"&&(A2.has(u)||Qd(u,!1,r),Qd(u,!0,r))});var a=r.nodeType===9?r:r.ownerDocument;a===null||a[rs]||(a[rs]=!0,Qd("selectionchange",!1,a))}}function K0(r,a,u,c){switch(jx(a)){case 2:var h=uO;break;case 8:h=sO;break;default:h=mm}u=h.bind(null,a,u,r),h=void 0,!yf||a!=="touchstart"&&a!=="touchmove"&&a!=="wheel"||(h=!0),c?h!==void 0?r.addEventListener(a,u,{capture:!0,passive:h}):r.addEventListener(a,u,!0):h!==void 0?r.addEventListener(a,u,{passive:h}):r.addEventListener(a,u,!1)}function Wd(r,a,u,c,h){var g=c;if((a&1)===0&&(a&2)===0&&c!==null)e:for(;;){if(c===null)return;var _=c.tag;if(_===3||_===4){var k=c.stateNode.containerInfo;if(k===h)break;if(_===4)for(_=c.return;_!==null;){var D=_.tag;if((D===3||D===4)&&_.stateNode.containerInfo===h)return;_=_.return}for(;k!==null;){if(_=Qi(k),_===null)return;if(D=_.tag,D===5||D===6||D===26||D===27){c=g=_;continue e}k=k.parentNode}}c=c.return}ry(function(){var H=g,K=gf(u),ne=[];e:{var V=Ty.get(r);if(V!==void 0){var Y=hu,he=r;switch(r){case"keypress":if(du(u)===0)break e;case"keydown":case"keyup":Y=jN;break;case"focusin":he="focus",Y=Sf;break;case"focusout":he="blur",Y=Sf;break;case"beforeblur":case"afterblur":Y=Sf;break;case"click":if(u.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":Y=ly;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":Y=pN;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":Y=ON;break;case jy:case zy:case Ny:Y=yN;break;case Oy:Y=CN;break;case"scroll":case"scrollend":Y=mN;break;case"wheel":Y=AN;break;case"copy":case"cut":case"paste":Y=xN;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":Y=uy;break;case"toggle":case"beforetoggle":Y=IN}var be=(a&4)!==0,Xe=!be&&(r==="scroll"||r==="scrollend"),L=be?V!==null?V+"Capture":null:V;be=[];for(var I=H,F;I!==null;){var ee=I;if(F=ee.stateNode,ee=ee.tag,ee!==5&&ee!==26&&ee!==27||F===null||L===null||(ee=dl(I,L),ee!=null&&be.push(Hl(I,ee,F))),Xe)break;I=I.return}0<be.length&&(V=new Y(V,he,null,u,K),ne.push({event:V,listeners:be}))}}if((a&7)===0){e:{if(V=r==="mouseover"||r==="pointerover",Y=r==="mouseout"||r==="pointerout",V&&u!==pf&&(he=u.relatedTarget||u.fromElement)&&(Qi(he)||he[Xi]))break e;if((Y||V)&&(V=K.window===K?K:(V=K.ownerDocument)?V.defaultView||V.parentWindow:window,Y?(he=u.relatedTarget||u.toElement,Y=H,he=he?Qi(he):null,he!==null&&(Xe=o(he),be=he.tag,he!==Xe||be!==5&&be!==27&&be!==6)&&(he=null)):(Y=null,he=H),Y!==he)){if(be=ly,ee="onMouseLeave",L="onMouseEnter",I="mouse",(r==="pointerout"||r==="pointerover")&&(be=uy,ee="onPointerLeave",L="onPointerEnter",I="pointer"),Xe=Y==null?V:fl(Y),F=he==null?V:fl(he),V=new be(ee,I+"leave",Y,u,K),V.target=Xe,V.relatedTarget=F,ee=null,Qi(K)===H&&(be=new be(L,I+"enter",he,u,K),be.target=F,be.relatedTarget=Xe,ee=be),Xe=ee,Y&&he)t:{for(be=R2,L=Y,I=he,F=0,ee=L;ee;ee=be(ee))F++;ee=0;for(var ve=I;ve;ve=be(ve))ee++;for(;0<F-ee;)L=be(L),F--;for(;0<ee-F;)I=be(I),ee--;for(;F--;){if(L===I||I!==null&&L===I.alternate){be=L;break t}L=be(L),I=be(I)}be=null}else be=null;Y!==null&&W0(ne,V,Y,be,!1),he!==null&&Xe!==null&&W0(ne,Xe,he,be,!0)}}e:{if(V=H?fl(H):window,Y=V.nodeName&&V.nodeName.toLowerCase(),Y==="select"||Y==="input"&&V.type==="file")var Ze=gy;else if(hy(V))if(vy)Ze=GN;else{Ze=BN;var ge=FN}else Y=V.nodeName,!Y||Y.toLowerCase()!=="input"||V.type!=="checkbox"&&V.type!=="radio"?H&&hf(H.elementType)&&(Ze=gy):Ze=HN;if(Ze&&(Ze=Ze(r,H))){py(ne,Ze,u,K);break e}ge&&ge(r,V,H),r==="focusout"&&H&&V.type==="number"&&H.memoizedProps.value!=null&&mf(V,"number",V.value)}switch(ge=H?fl(H):window,r){case"focusin":(hy(ge)||ge.contentEditable==="true")&&(la=ge,zf=H,xl=null);break;case"focusout":xl=zf=la=null;break;case"mousedown":Nf=!0;break;case"contextmenu":case"mouseup":case"dragend":Nf=!1,$y(ne,u,K);break;case"selectionchange":if(YN)break;case"keydown":case"keyup":$y(ne,u,K)}var Ne;if(wf)e:{switch(r){case"compositionstart":var Le="onCompositionStart";break e;case"compositionend":Le="onCompositionEnd";break e;case"compositionupdate":Le="onCompositionUpdate";break e}Le=void 0}else aa?dy(r,u)&&(Le="onCompositionEnd"):r==="keydown"&&u.keyCode===229&&(Le="onCompositionStart");Le&&(sy&&u.locale!=="ko"&&(aa||Le!=="onCompositionStart"?Le==="onCompositionEnd"&&aa&&(Ne=iy()):(Ar=K,bf="value"in Ar?Ar.value:Ar.textContent,aa=!0)),ge=is(H,Le),0<ge.length&&(Le=new oy(Le,r,null,u,K),ne.push({event:Le,listeners:ge}),Ne?Le.data=Ne:(Ne=my(u),Ne!==null&&(Le.data=Ne)))),(Ne=LN?MN(r,u):PN(r,u))&&(Le=is(H,"onBeforeInput"),0<Le.length&&(ge=new oy("onBeforeInput","beforeinput",null,u,K),ne.push({event:ge,listeners:Le}),ge.data=Ne)),T2(ne,r,H,u,K)}Q0(ne,a)})}function Hl(r,a,u){return{instance:r,listener:a,currentTarget:u}}function is(r,a){for(var u=a+"Capture",c=[];r!==null;){var h=r,g=h.stateNode;if(h=h.tag,h!==5&&h!==26&&h!==27||g===null||(h=dl(r,u),h!=null&&c.unshift(Hl(r,h,g)),h=dl(r,a),h!=null&&c.push(Hl(r,h,g))),r.tag===3)return c;r=r.return}return[]}function R2(r){if(r===null)return null;do r=r.return;while(r&&r.tag!==5&&r.tag!==27);return r||null}function W0(r,a,u,c,h){for(var g=a._reactName,_=[];u!==null&&u!==c;){var k=u,D=k.alternate,H=k.stateNode;if(k=k.tag,D!==null&&D===c)break;k!==5&&k!==26&&k!==27||H===null||(D=H,h?(H=dl(u,g),H!=null&&_.unshift(Hl(u,H,D))):h||(H=dl(u,g),H!=null&&_.push(Hl(u,H,D)))),u=u.return}_.length!==0&&r.push({event:a,listeners:_})}var I2=/\r\n?/g,U2=/\u0000|\uFFFD/g;function ex(r){return(typeof r=="string"?r:""+r).replace(I2,`
|
|
9
|
+
`).replace(U2,"")}function tx(r,a){return a=ex(a),ex(r)===a}function Je(r,a,u,c,h,g){switch(u){case"children":typeof c=="string"?a==="body"||a==="textarea"&&c===""||na(r,c):(typeof c=="number"||typeof c=="bigint")&&a!=="body"&&na(r,""+c);break;case"className":uu(r,"class",c);break;case"tabIndex":uu(r,"tabindex",c);break;case"dir":case"role":case"viewBox":case"width":case"height":uu(r,u,c);break;case"style":ty(r,c,g);break;case"data":if(a!=="object"){uu(r,"data",c);break}case"src":case"href":if(c===""&&(a!=="a"||u!=="href")){r.removeAttribute(u);break}if(c==null||typeof c=="function"||typeof c=="symbol"||typeof c=="boolean"){r.removeAttribute(u);break}c=cu(""+c),r.setAttribute(u,c);break;case"action":case"formAction":if(typeof c=="function"){r.setAttribute(u,"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 g=="function"&&(u==="formAction"?(a!=="input"&&Je(r,a,"name",h.name,h,null),Je(r,a,"formEncType",h.formEncType,h,null),Je(r,a,"formMethod",h.formMethod,h,null),Je(r,a,"formTarget",h.formTarget,h,null)):(Je(r,a,"encType",h.encType,h,null),Je(r,a,"method",h.method,h,null),Je(r,a,"target",h.target,h,null)));if(c==null||typeof c=="symbol"||typeof c=="boolean"){r.removeAttribute(u);break}c=cu(""+c),r.setAttribute(u,c);break;case"onClick":c!=null&&(r.onclick=or);break;case"onScroll":c!=null&&Ae("scroll",r);break;case"onScrollEnd":c!=null&&Ae("scrollend",r);break;case"dangerouslySetInnerHTML":if(c!=null){if(typeof c!="object"||!("__html"in c))throw Error(l(61));if(u=c.__html,u!=null){if(h.children!=null)throw Error(l(60));r.innerHTML=u}}break;case"multiple":r.multiple=c&&typeof c!="function"&&typeof c!="symbol";break;case"muted":r.muted=c&&typeof c!="function"&&typeof c!="symbol";break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":break;case"autoFocus":break;case"xlinkHref":if(c==null||typeof c=="function"||typeof c=="boolean"||typeof c=="symbol"){r.removeAttribute("xlink:href");break}u=cu(""+c),r.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",u);break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":c!=null&&typeof c!="function"&&typeof c!="symbol"?r.setAttribute(u,""+c):r.removeAttribute(u);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":c&&typeof c!="function"&&typeof c!="symbol"?r.setAttribute(u,""):r.removeAttribute(u);break;case"capture":case"download":c===!0?r.setAttribute(u,""):c!==!1&&c!=null&&typeof c!="function"&&typeof c!="symbol"?r.setAttribute(u,c):r.removeAttribute(u);break;case"cols":case"rows":case"size":case"span":c!=null&&typeof c!="function"&&typeof c!="symbol"&&!isNaN(c)&&1<=c?r.setAttribute(u,c):r.removeAttribute(u);break;case"rowSpan":case"start":c==null||typeof c=="function"||typeof c=="symbol"||isNaN(c)?r.removeAttribute(u):r.setAttribute(u,c);break;case"popover":Ae("beforetoggle",r),Ae("toggle",r),ou(r,"popover",c);break;case"xlinkActuate":lr(r,"http://www.w3.org/1999/xlink","xlink:actuate",c);break;case"xlinkArcrole":lr(r,"http://www.w3.org/1999/xlink","xlink:arcrole",c);break;case"xlinkRole":lr(r,"http://www.w3.org/1999/xlink","xlink:role",c);break;case"xlinkShow":lr(r,"http://www.w3.org/1999/xlink","xlink:show",c);break;case"xlinkTitle":lr(r,"http://www.w3.org/1999/xlink","xlink:title",c);break;case"xlinkType":lr(r,"http://www.w3.org/1999/xlink","xlink:type",c);break;case"xmlBase":lr(r,"http://www.w3.org/XML/1998/namespace","xml:base",c);break;case"xmlLang":lr(r,"http://www.w3.org/XML/1998/namespace","xml:lang",c);break;case"xmlSpace":lr(r,"http://www.w3.org/XML/1998/namespace","xml:space",c);break;case"is":ou(r,"is",c);break;case"innerText":case"textContent":break;default:(!(2<u.length)||u[0]!=="o"&&u[0]!=="O"||u[1]!=="n"&&u[1]!=="N")&&(u=fN.get(u)||u,ou(r,u,c))}}function em(r,a,u,c,h,g){switch(u){case"style":ty(r,c,g);break;case"dangerouslySetInnerHTML":if(c!=null){if(typeof c!="object"||!("__html"in c))throw Error(l(61));if(u=c.__html,u!=null){if(h.children!=null)throw Error(l(60));r.innerHTML=u}}break;case"children":typeof c=="string"?na(r,c):(typeof c=="number"||typeof c=="bigint")&&na(r,""+c);break;case"onScroll":c!=null&&Ae("scroll",r);break;case"onScrollEnd":c!=null&&Ae("scrollend",r);break;case"onClick":c!=null&&(r.onclick=or);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"innerHTML":case"ref":break;case"innerText":case"textContent":break;default:if(!Gv.hasOwnProperty(u))e:{if(u[0]==="o"&&u[1]==="n"&&(h=u.endsWith("Capture"),a=u.slice(2,h?u.length-7:void 0),g=r[Gt]||null,g=g!=null?g[u]:null,typeof g=="function"&&r.removeEventListener(a,g,h),typeof c=="function")){typeof g!="function"&&g!==null&&(u in r?r[u]=null:r.hasAttribute(u)&&r.removeAttribute(u)),r.addEventListener(a,c,h);break e}u in r?r[u]=c:c===!0?r.setAttribute(u,""):ou(r,u,c)}}}function Ct(r,a,u){switch(a){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"img":Ae("error",r),Ae("load",r);var c=!1,h=!1,g;for(g in u)if(u.hasOwnProperty(g)){var _=u[g];if(_!=null)switch(g){case"src":c=!0;break;case"srcSet":h=!0;break;case"children":case"dangerouslySetInnerHTML":throw Error(l(137,a));default:Je(r,a,g,_,u,null)}}h&&Je(r,a,"srcSet",u.srcSet,u,null),c&&Je(r,a,"src",u.src,u,null);return;case"input":Ae("invalid",r);var k=g=_=h=null,D=null,H=null;for(c in u)if(u.hasOwnProperty(c)){var K=u[c];if(K!=null)switch(c){case"name":h=K;break;case"type":_=K;break;case"checked":D=K;break;case"defaultChecked":H=K;break;case"value":g=K;break;case"defaultValue":k=K;break;case"children":case"dangerouslySetInnerHTML":if(K!=null)throw Error(l(137,a));break;default:Je(r,a,c,K,u,null)}}Qv(r,g,k,D,H,_,h,!1);return;case"select":Ae("invalid",r),c=_=g=null;for(h in u)if(u.hasOwnProperty(h)&&(k=u[h],k!=null))switch(h){case"value":g=k;break;case"defaultValue":_=k;break;case"multiple":c=k;default:Je(r,a,h,k,u,null)}a=g,u=_,r.multiple=!!c,a!=null?ta(r,!!c,a,!1):u!=null&&ta(r,!!c,u,!0);return;case"textarea":Ae("invalid",r),g=h=c=null;for(_ in u)if(u.hasOwnProperty(_)&&(k=u[_],k!=null))switch(_){case"value":c=k;break;case"defaultValue":h=k;break;case"children":g=k;break;case"dangerouslySetInnerHTML":if(k!=null)throw Error(l(91));break;default:Je(r,a,_,k,u,null)}Wv(r,c,h,g);return;case"option":for(D in u)u.hasOwnProperty(D)&&(c=u[D],c!=null)&&(D==="selected"?r.selected=c&&typeof c!="function"&&typeof c!="symbol":Je(r,a,D,c,u,null));return;case"dialog":Ae("beforetoggle",r),Ae("toggle",r),Ae("cancel",r),Ae("close",r);break;case"iframe":case"object":Ae("load",r);break;case"video":case"audio":for(c=0;c<Bl.length;c++)Ae(Bl[c],r);break;case"image":Ae("error",r),Ae("load",r);break;case"details":Ae("toggle",r);break;case"embed":case"source":case"link":Ae("error",r),Ae("load",r);case"area":case"base":case"br":case"col":case"hr":case"keygen":case"meta":case"param":case"track":case"wbr":case"menuitem":for(H in u)if(u.hasOwnProperty(H)&&(c=u[H],c!=null))switch(H){case"children":case"dangerouslySetInnerHTML":throw Error(l(137,a));default:Je(r,a,H,c,u,null)}return;default:if(hf(a)){for(K in u)u.hasOwnProperty(K)&&(c=u[K],c!==void 0&&em(r,a,K,c,u,void 0));return}}for(k in u)u.hasOwnProperty(k)&&(c=u[k],c!=null&&Je(r,a,k,c,u,null))}function L2(r,a,u,c){switch(a){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"input":var h=null,g=null,_=null,k=null,D=null,H=null,K=null;for(Y in u){var ne=u[Y];if(u.hasOwnProperty(Y)&&ne!=null)switch(Y){case"checked":break;case"value":break;case"defaultValue":D=ne;default:c.hasOwnProperty(Y)||Je(r,a,Y,null,c,ne)}}for(var V in c){var Y=c[V];if(ne=u[V],c.hasOwnProperty(V)&&(Y!=null||ne!=null))switch(V){case"type":g=Y;break;case"name":h=Y;break;case"checked":H=Y;break;case"defaultChecked":K=Y;break;case"value":_=Y;break;case"defaultValue":k=Y;break;case"children":case"dangerouslySetInnerHTML":if(Y!=null)throw Error(l(137,a));break;default:Y!==ne&&Je(r,a,V,Y,c,ne)}}df(r,_,k,D,H,K,g,h);return;case"select":Y=_=k=V=null;for(g in u)if(D=u[g],u.hasOwnProperty(g)&&D!=null)switch(g){case"value":break;case"multiple":Y=D;default:c.hasOwnProperty(g)||Je(r,a,g,null,c,D)}for(h in c)if(g=c[h],D=u[h],c.hasOwnProperty(h)&&(g!=null||D!=null))switch(h){case"value":V=g;break;case"defaultValue":k=g;break;case"multiple":_=g;default:g!==D&&Je(r,a,h,g,c,D)}a=k,u=_,c=Y,V!=null?ta(r,!!u,V,!1):!!c!=!!u&&(a!=null?ta(r,!!u,a,!0):ta(r,!!u,u?[]:"",!1));return;case"textarea":Y=V=null;for(k in u)if(h=u[k],u.hasOwnProperty(k)&&h!=null&&!c.hasOwnProperty(k))switch(k){case"value":break;case"children":break;default:Je(r,a,k,null,c,h)}for(_ in c)if(h=c[_],g=u[_],c.hasOwnProperty(_)&&(h!=null||g!=null))switch(_){case"value":V=h;break;case"defaultValue":Y=h;break;case"children":break;case"dangerouslySetInnerHTML":if(h!=null)throw Error(l(91));break;default:h!==g&&Je(r,a,_,h,c,g)}Kv(r,V,Y);return;case"option":for(var he in u)V=u[he],u.hasOwnProperty(he)&&V!=null&&!c.hasOwnProperty(he)&&(he==="selected"?r.selected=!1:Je(r,a,he,null,c,V));for(D in c)V=c[D],Y=u[D],c.hasOwnProperty(D)&&V!==Y&&(V!=null||Y!=null)&&(D==="selected"?r.selected=V&&typeof V!="function"&&typeof V!="symbol":Je(r,a,D,V,c,Y));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 be in u)V=u[be],u.hasOwnProperty(be)&&V!=null&&!c.hasOwnProperty(be)&&Je(r,a,be,null,c,V);for(H in c)if(V=c[H],Y=u[H],c.hasOwnProperty(H)&&V!==Y&&(V!=null||Y!=null))switch(H){case"children":case"dangerouslySetInnerHTML":if(V!=null)throw Error(l(137,a));break;default:Je(r,a,H,V,c,Y)}return;default:if(hf(a)){for(var Xe in u)V=u[Xe],u.hasOwnProperty(Xe)&&V!==void 0&&!c.hasOwnProperty(Xe)&&em(r,a,Xe,void 0,c,V);for(K in c)V=c[K],Y=u[K],!c.hasOwnProperty(K)||V===Y||V===void 0&&Y===void 0||em(r,a,K,V,c,Y);return}}for(var L in u)V=u[L],u.hasOwnProperty(L)&&V!=null&&!c.hasOwnProperty(L)&&Je(r,a,L,null,c,V);for(ne in c)V=c[ne],Y=u[ne],!c.hasOwnProperty(ne)||V===Y||V==null&&Y==null||Je(r,a,ne,V,c,Y)}function nx(r){switch(r){case"css":case"script":case"font":case"img":case"image":case"input":case"link":return!0;default:return!1}}function M2(){if(typeof performance.getEntriesByType=="function"){for(var r=0,a=0,u=performance.getEntriesByType("resource"),c=0;c<u.length;c++){var h=u[c],g=h.transferSize,_=h.initiatorType,k=h.duration;if(g&&k&&nx(_)){for(_=0,k=h.responseEnd,c+=1;c<u.length;c++){var D=u[c],H=D.startTime;if(H>k)break;var K=D.transferSize,ne=D.initiatorType;K&&nx(ne)&&(D=D.responseEnd,_+=K*(D<k?1:(k-H)/(D-H)))}if(--c,a+=8*(g+_)/(h.duration/1e3),r++,10<r)break}}if(0<r)return a/r/1e6}return navigator.connection&&(r=navigator.connection.downlink,typeof r=="number")?r:5}var tm=null,nm=null;function as(r){return r.nodeType===9?r:r.ownerDocument}function rx(r){switch(r){case"http://www.w3.org/2000/svg":return 1;case"http://www.w3.org/1998/Math/MathML":return 2;default:return 0}}function ix(r,a){if(r===0)switch(a){case"svg":return 1;case"math":return 2;default:return 0}return r===1&&a==="foreignObject"?0:r}function rm(r,a){return r==="textarea"||r==="noscript"||typeof a.children=="string"||typeof a.children=="number"||typeof a.children=="bigint"||typeof a.dangerouslySetInnerHTML=="object"&&a.dangerouslySetInnerHTML!==null&&a.dangerouslySetInnerHTML.__html!=null}var im=null;function P2(){var r=window.event;return r&&r.type==="popstate"?r===im?!1:(im=r,!0):(im=null,!1)}var ax=typeof setTimeout=="function"?setTimeout:void 0,Z2=typeof clearTimeout=="function"?clearTimeout:void 0,lx=typeof Promise=="function"?Promise:void 0,q2=typeof queueMicrotask=="function"?queueMicrotask:typeof lx<"u"?function(r){return lx.resolve(null).then(r).catch(F2)}:ax;function F2(r){setTimeout(function(){throw r})}function Qr(r){return r==="head"}function ox(r,a){var u=a,c=0;do{var h=u.nextSibling;if(r.removeChild(u),h&&h.nodeType===8)if(u=h.data,u==="/$"||u==="/&"){if(c===0){r.removeChild(h),Da(a);return}c--}else if(u==="$"||u==="$?"||u==="$~"||u==="$!"||u==="&")c++;else if(u==="html")Gl(r.ownerDocument.documentElement);else if(u==="head"){u=r.ownerDocument.head,Gl(u);for(var g=u.firstChild;g;){var _=g.nextSibling,k=g.nodeName;g[cl]||k==="SCRIPT"||k==="STYLE"||k==="LINK"&&g.rel.toLowerCase()==="stylesheet"||u.removeChild(g),g=_}}else u==="body"&&Gl(r.ownerDocument.body);u=h}while(u);Da(a)}function ux(r,a){var u=r;r=0;do{var c=u.nextSibling;if(u.nodeType===1?a?(u._stashedDisplay=u.style.display,u.style.display="none"):(u.style.display=u._stashedDisplay||"",u.getAttribute("style")===""&&u.removeAttribute("style")):u.nodeType===3&&(a?(u._stashedText=u.nodeValue,u.nodeValue=""):u.nodeValue=u._stashedText||""),c&&c.nodeType===8)if(u=c.data,u==="/$"){if(r===0)break;r--}else u!=="$"&&u!=="$?"&&u!=="$~"&&u!=="$!"||r++;u=c}while(u)}function am(r){var a=r.firstChild;for(a&&a.nodeType===10&&(a=a.nextSibling);a;){var u=a;switch(a=a.nextSibling,u.nodeName){case"HTML":case"HEAD":case"BODY":am(u),cf(u);continue;case"SCRIPT":case"STYLE":continue;case"LINK":if(u.rel.toLowerCase()==="stylesheet")continue}r.removeChild(u)}}function B2(r,a,u,c){for(;r.nodeType===1;){var h=u;if(r.nodeName.toLowerCase()!==a.toLowerCase()){if(!c&&(r.nodeName!=="INPUT"||r.type!=="hidden"))break}else if(c){if(!r[cl])switch(a){case"meta":if(!r.hasAttribute("itemprop"))break;return r;case"link":if(g=r.getAttribute("rel"),g==="stylesheet"&&r.hasAttribute("data-precedence"))break;if(g!==h.rel||r.getAttribute("href")!==(h.href==null||h.href===""?null:h.href)||r.getAttribute("crossorigin")!==(h.crossOrigin==null?null:h.crossOrigin)||r.getAttribute("title")!==(h.title==null?null:h.title))break;return r;case"style":if(r.hasAttribute("data-precedence"))break;return r;case"script":if(g=r.getAttribute("src"),(g!==(h.src==null?null:h.src)||r.getAttribute("type")!==(h.type==null?null:h.type)||r.getAttribute("crossorigin")!==(h.crossOrigin==null?null:h.crossOrigin))&&g&&r.hasAttribute("async")&&!r.hasAttribute("itemprop"))break;return r;default:return r}}else if(a==="input"&&r.type==="hidden"){var g=h.name==null?null:""+h.name;if(h.type==="hidden"&&r.getAttribute("name")===g)return r}else return r;if(r=$n(r.nextSibling),r===null)break}return null}function H2(r,a,u){if(a==="")return null;for(;r.nodeType!==3;)if((r.nodeType!==1||r.nodeName!=="INPUT"||r.type!=="hidden")&&!u||(r=$n(r.nextSibling),r===null))return null;return r}function sx(r,a){for(;r.nodeType!==8;)if((r.nodeType!==1||r.nodeName!=="INPUT"||r.type!=="hidden")&&!a||(r=$n(r.nextSibling),r===null))return null;return r}function lm(r){return r.data==="$?"||r.data==="$~"}function om(r){return r.data==="$!"||r.data==="$?"&&r.ownerDocument.readyState!=="loading"}function G2(r,a){var u=r.ownerDocument;if(r.data==="$~")r._reactRetry=a;else if(r.data!=="$?"||u.readyState!=="loading")a();else{var c=function(){a(),u.removeEventListener("DOMContentLoaded",c)};u.addEventListener("DOMContentLoaded",c),r._reactRetry=c}}function $n(r){for(;r!=null;r=r.nextSibling){var a=r.nodeType;if(a===1||a===3)break;if(a===8){if(a=r.data,a==="$"||a==="$!"||a==="$?"||a==="$~"||a==="&"||a==="F!"||a==="F")break;if(a==="/$"||a==="/&")return null}}return r}var um=null;function cx(r){r=r.nextSibling;for(var a=0;r;){if(r.nodeType===8){var u=r.data;if(u==="/$"||u==="/&"){if(a===0)return $n(r.nextSibling);a--}else u!=="$"&&u!=="$!"&&u!=="$?"&&u!=="$~"&&u!=="&"||a++}r=r.nextSibling}return null}function fx(r){r=r.previousSibling;for(var a=0;r;){if(r.nodeType===8){var u=r.data;if(u==="$"||u==="$!"||u==="$?"||u==="$~"||u==="&"){if(a===0)return r;a--}else u!=="/$"&&u!=="/&"||a++}r=r.previousSibling}return null}function dx(r,a,u){switch(a=as(u),r){case"html":if(r=a.documentElement,!r)throw Error(l(452));return r;case"head":if(r=a.head,!r)throw Error(l(453));return r;case"body":if(r=a.body,!r)throw Error(l(454));return r;default:throw Error(l(451))}}function Gl(r){for(var a=r.attributes;a.length;)r.removeAttributeNode(a[0]);cf(r)}var En=new Map,mx=new Set;function ls(r){return typeof r.getRootNode=="function"?r.getRootNode():r.nodeType===9?r:r.ownerDocument}var kr=q.d;q.d={f:V2,r:Y2,D:J2,C:X2,L:Q2,m:K2,X:eO,S:W2,M:tO};function V2(){var r=kr.f(),a=Qu();return r||a}function Y2(r){var a=Ki(r);a!==null&&a.tag===5&&a.type==="form"?Ob(a):kr.r(r)}var Oa=typeof document>"u"?null:document;function hx(r,a,u){var c=Oa;if(c&&typeof a=="string"&&a){var h=yn(a);h='link[rel="'+r+'"][href="'+h+'"]',typeof u=="string"&&(h+='[crossorigin="'+u+'"]'),mx.has(h)||(mx.add(h),r={rel:r,crossOrigin:u,href:a},c.querySelector(h)===null&&(a=c.createElement("link"),Ct(a,"link",r),$t(a),c.head.appendChild(a)))}}function J2(r){kr.D(r),hx("dns-prefetch",r,null)}function X2(r,a){kr.C(r,a),hx("preconnect",r,a)}function Q2(r,a,u){kr.L(r,a,u);var c=Oa;if(c&&r&&a){var h='link[rel="preload"][as="'+yn(a)+'"]';a==="image"&&u&&u.imageSrcSet?(h+='[imagesrcset="'+yn(u.imageSrcSet)+'"]',typeof u.imageSizes=="string"&&(h+='[imagesizes="'+yn(u.imageSizes)+'"]')):h+='[href="'+yn(r)+'"]';var g=h;switch(a){case"style":g=Ta(r);break;case"script":g=Ca(r)}En.has(g)||(r=v({rel:"preload",href:a==="image"&&u&&u.imageSrcSet?void 0:r,as:a},u),En.set(g,r),c.querySelector(h)!==null||a==="style"&&c.querySelector(Vl(g))||a==="script"&&c.querySelector(Yl(g))||(a=c.createElement("link"),Ct(a,"link",r),$t(a),c.head.appendChild(a)))}}function K2(r,a){kr.m(r,a);var u=Oa;if(u&&r){var c=a&&typeof a.as=="string"?a.as:"script",h='link[rel="modulepreload"][as="'+yn(c)+'"][href="'+yn(r)+'"]',g=h;switch(c){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":g=Ca(r)}if(!En.has(g)&&(r=v({rel:"modulepreload",href:r},a),En.set(g,r),u.querySelector(h)===null)){switch(c){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(u.querySelector(Yl(g)))return}c=u.createElement("link"),Ct(c,"link",r),$t(c),u.head.appendChild(c)}}}function W2(r,a,u){kr.S(r,a,u);var c=Oa;if(c&&r){var h=Wi(c).hoistableStyles,g=Ta(r);a=a||"default";var _=h.get(g);if(!_){var k={loading:0,preload:null};if(_=c.querySelector(Vl(g)))k.loading=5;else{r=v({rel:"stylesheet",href:r,"data-precedence":a},u),(u=En.get(g))&&sm(r,u);var D=_=c.createElement("link");$t(D),Ct(D,"link",r),D._p=new Promise(function(H,K){D.onload=H,D.onerror=K}),D.addEventListener("load",function(){k.loading|=1}),D.addEventListener("error",function(){k.loading|=2}),k.loading|=4,os(_,a,c)}_={type:"stylesheet",instance:_,count:1,state:k},h.set(g,_)}}}function eO(r,a){kr.X(r,a);var u=Oa;if(u&&r){var c=Wi(u).hoistableScripts,h=Ca(r),g=c.get(h);g||(g=u.querySelector(Yl(h)),g||(r=v({src:r,async:!0},a),(a=En.get(h))&&cm(r,a),g=u.createElement("script"),$t(g),Ct(g,"link",r),u.head.appendChild(g)),g={type:"script",instance:g,count:1,state:null},c.set(h,g))}}function tO(r,a){kr.M(r,a);var u=Oa;if(u&&r){var c=Wi(u).hoistableScripts,h=Ca(r),g=c.get(h);g||(g=u.querySelector(Yl(h)),g||(r=v({src:r,async:!0,type:"module"},a),(a=En.get(h))&&cm(r,a),g=u.createElement("script"),$t(g),Ct(g,"link",r),u.head.appendChild(g)),g={type:"script",instance:g,count:1,state:null},c.set(h,g))}}function px(r,a,u,c){var h=(h=pe.current)?ls(h):null;if(!h)throw Error(l(446));switch(r){case"meta":case"title":return null;case"style":return typeof u.precedence=="string"&&typeof u.href=="string"?(a=Ta(u.href),u=Wi(h).hoistableStyles,c=u.get(a),c||(c={type:"style",instance:null,count:0,state:null},u.set(a,c)),c):{type:"void",instance:null,count:0,state:null};case"link":if(u.rel==="stylesheet"&&typeof u.href=="string"&&typeof u.precedence=="string"){r=Ta(u.href);var g=Wi(h).hoistableStyles,_=g.get(r);if(_||(h=h.ownerDocument||h,_={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},g.set(r,_),(g=h.querySelector(Vl(r)))&&!g._p&&(_.instance=g,_.state.loading=5),En.has(r)||(u={rel:"preload",as:"style",href:u.href,crossOrigin:u.crossOrigin,integrity:u.integrity,media:u.media,hrefLang:u.hrefLang,referrerPolicy:u.referrerPolicy},En.set(r,u),g||nO(h,r,u,_.state))),a&&c===null)throw Error(l(528,""));return _}if(a&&c!==null)throw Error(l(529,""));return null;case"script":return a=u.async,u=u.src,typeof u=="string"&&a&&typeof a!="function"&&typeof a!="symbol"?(a=Ca(u),u=Wi(h).hoistableScripts,c=u.get(a),c||(c={type:"script",instance:null,count:0,state:null},u.set(a,c)),c):{type:"void",instance:null,count:0,state:null};default:throw Error(l(444,r))}}function Ta(r){return'href="'+yn(r)+'"'}function Vl(r){return'link[rel="stylesheet"]['+r+"]"}function gx(r){return v({},r,{"data-precedence":r.precedence,precedence:null})}function nO(r,a,u,c){r.querySelector('link[rel="preload"][as="style"]['+a+"]")?c.loading=1:(a=r.createElement("link"),c.preload=a,a.addEventListener("load",function(){return c.loading|=1}),a.addEventListener("error",function(){return c.loading|=2}),Ct(a,"link",u),$t(a),r.head.appendChild(a))}function Ca(r){return'[src="'+yn(r)+'"]'}function Yl(r){return"script[async]"+r}function vx(r,a,u){if(a.count++,a.instance===null)switch(a.type){case"style":var c=r.querySelector('style[data-href~="'+yn(u.href)+'"]');if(c)return a.instance=c,$t(c),c;var h=v({},u,{"data-href":u.href,"data-precedence":u.precedence,href:null,precedence:null});return c=(r.ownerDocument||r).createElement("style"),$t(c),Ct(c,"style",h),os(c,u.precedence,r),a.instance=c;case"stylesheet":h=Ta(u.href);var g=r.querySelector(Vl(h));if(g)return a.state.loading|=4,a.instance=g,$t(g),g;c=gx(u),(h=En.get(h))&&sm(c,h),g=(r.ownerDocument||r).createElement("link"),$t(g);var _=g;return _._p=new Promise(function(k,D){_.onload=k,_.onerror=D}),Ct(g,"link",c),a.state.loading|=4,os(g,u.precedence,r),a.instance=g;case"script":return g=Ca(u.src),(h=r.querySelector(Yl(g)))?(a.instance=h,$t(h),h):(c=u,(h=En.get(g))&&(c=v({},u),cm(c,h)),r=r.ownerDocument||r,h=r.createElement("script"),$t(h),Ct(h,"link",c),r.head.appendChild(h),a.instance=h);case"void":return null;default:throw Error(l(443,a.type))}else a.type==="stylesheet"&&(a.state.loading&4)===0&&(c=a.instance,a.state.loading|=4,os(c,u.precedence,r));return a.instance}function os(r,a,u){for(var c=u.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),h=c.length?c[c.length-1]:null,g=h,_=0;_<c.length;_++){var k=c[_];if(k.dataset.precedence===a)g=k;else if(g!==h)break}g?g.parentNode.insertBefore(r,g.nextSibling):(a=u.nodeType===9?u.head:u,a.insertBefore(r,a.firstChild))}function sm(r,a){r.crossOrigin==null&&(r.crossOrigin=a.crossOrigin),r.referrerPolicy==null&&(r.referrerPolicy=a.referrerPolicy),r.title==null&&(r.title=a.title)}function cm(r,a){r.crossOrigin==null&&(r.crossOrigin=a.crossOrigin),r.referrerPolicy==null&&(r.referrerPolicy=a.referrerPolicy),r.integrity==null&&(r.integrity=a.integrity)}var us=null;function yx(r,a,u){if(us===null){var c=new Map,h=us=new Map;h.set(u,c)}else h=us,c=h.get(u),c||(c=new Map,h.set(u,c));if(c.has(r))return c;for(c.set(r,null),u=u.getElementsByTagName(r),h=0;h<u.length;h++){var g=u[h];if(!(g[cl]||g[zt]||r==="link"&&g.getAttribute("rel")==="stylesheet")&&g.namespaceURI!=="http://www.w3.org/2000/svg"){var _=g.getAttribute(a)||"";_=r+_;var k=c.get(_);k?k.push(g):c.set(_,[g])}}return c}function bx(r,a,u){r=r.ownerDocument||r,r.head.insertBefore(u,a==="title"?r.querySelector("head > title"):null)}function rO(r,a,u){if(u===1||a.itemProp!=null)return!1;switch(r){case"meta":case"title":return!0;case"style":if(typeof a.precedence!="string"||typeof a.href!="string"||a.href==="")break;return!0;case"link":if(typeof a.rel!="string"||typeof a.href!="string"||a.href===""||a.onLoad||a.onError)break;return a.rel==="stylesheet"?(r=a.disabled,typeof a.precedence=="string"&&r==null):!0;case"script":if(a.async&&typeof a.async!="function"&&typeof a.async!="symbol"&&!a.onLoad&&!a.onError&&a.src&&typeof a.src=="string")return!0}return!1}function xx(r){return!(r.type==="stylesheet"&&(r.state.loading&3)===0)}function iO(r,a,u,c){if(u.type==="stylesheet"&&(typeof c.media!="string"||matchMedia(c.media).matches!==!1)&&(u.state.loading&4)===0){if(u.instance===null){var h=Ta(c.href),g=a.querySelector(Vl(h));if(g){a=g._p,a!==null&&typeof a=="object"&&typeof a.then=="function"&&(r.count++,r=ss.bind(r),a.then(r,r)),u.state.loading|=4,u.instance=g,$t(g);return}g=a.ownerDocument||a,c=gx(c),(h=En.get(h))&&sm(c,h),g=g.createElement("link"),$t(g);var _=g;_._p=new Promise(function(k,D){_.onload=k,_.onerror=D}),Ct(g,"link",c),u.instance=g}r.stylesheets===null&&(r.stylesheets=new Map),r.stylesheets.set(u,a),(a=u.state.preload)&&(u.state.loading&3)===0&&(r.count++,u=ss.bind(r),a.addEventListener("load",u),a.addEventListener("error",u))}}var fm=0;function aO(r,a){return r.stylesheets&&r.count===0&&fs(r,r.stylesheets),0<r.count||0<r.imgCount?function(u){var c=setTimeout(function(){if(r.stylesheets&&fs(r,r.stylesheets),r.unsuspend){var g=r.unsuspend;r.unsuspend=null,g()}},6e4+a);0<r.imgBytes&&fm===0&&(fm=62500*M2());var h=setTimeout(function(){if(r.waitingForImages=!1,r.count===0&&(r.stylesheets&&fs(r,r.stylesheets),r.unsuspend)){var g=r.unsuspend;r.unsuspend=null,g()}},(r.imgBytes>fm?50:800)+a);return r.unsuspend=u,function(){r.unsuspend=null,clearTimeout(c),clearTimeout(h)}}:null}function ss(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)fs(this,this.stylesheets);else if(this.unsuspend){var r=this.unsuspend;this.unsuspend=null,r()}}}var cs=null;function fs(r,a){r.stylesheets=null,r.unsuspend!==null&&(r.count++,cs=new Map,a.forEach(lO,r),cs=null,ss.call(r))}function lO(r,a){if(!(a.state.loading&4)){var u=cs.get(r);if(u)var c=u.get(null);else{u=new Map,cs.set(r,u);for(var h=r.querySelectorAll("link[data-precedence],style[data-precedence]"),g=0;g<h.length;g++){var _=h[g];(_.nodeName==="LINK"||_.getAttribute("media")!=="not all")&&(u.set(_.dataset.precedence,_),c=_)}c&&u.set(null,c)}h=a.instance,_=h.getAttribute("data-precedence"),g=u.get(_)||c,g===c&&u.set(null,h),u.set(_,h),this.count++,c=ss.bind(this),h.addEventListener("load",c),h.addEventListener("error",c),g?g.parentNode.insertBefore(h,g.nextSibling):(r=r.nodeType===9?r.head:r,r.insertBefore(h,r.firstChild)),a.state.loading|=4}}var Jl={$$typeof:N,Provider:null,Consumer:null,_currentValue:te,_currentValue2:te,_threadCount:0};function oO(r,a,u,c,h,g,_,k,D){this.tag=1,this.containerInfo=r,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=lf(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=lf(0),this.hiddenUpdates=lf(null),this.identifierPrefix=c,this.onUncaughtError=h,this.onCaughtError=g,this.onRecoverableError=_,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=D,this.incompleteTransitions=new Map}function _x(r,a,u,c,h,g,_,k,D,H,K,ne){return r=new oO(r,a,u,_,D,H,K,ne,k),a=1,g===!0&&(a|=24),g=an(3,null,null,a),r.current=g,g.stateNode=r,a=Bf(),a.refCount++,r.pooledCache=a,a.refCount++,g.memoizedState={element:c,isDehydrated:u,cache:a},Yf(g),r}function Sx(r){return r?(r=sa,r):sa}function kx(r,a,u,c,h,g){h=Sx(h),c.context===null?c.context=h:c.pendingContext=h,c=Pr(a),c.payload={element:u},g=g===void 0?null:g,g!==null&&(c.callback=g),u=Zr(r,c,a),u!==null&&(Kt(u,r,a),jl(u,r,a))}function wx(r,a){if(r=r.memoizedState,r!==null&&r.dehydrated!==null){var u=r.retryLane;r.retryLane=u!==0&&u<a?u:a}}function dm(r,a){wx(r,a),(r=r.alternate)&&wx(r,a)}function $x(r){if(r.tag===13||r.tag===31){var a=vi(r,67108864);a!==null&&Kt(a,r,67108864),dm(r,67108864)}}function Ex(r){if(r.tag===13||r.tag===31){var a=cn();a=of(a);var u=vi(r,a);u!==null&&Kt(u,r,a),dm(r,a)}}var ds=!0;function uO(r,a,u,c){var h=A.T;A.T=null;var g=q.p;try{q.p=2,mm(r,a,u,c)}finally{q.p=g,A.T=h}}function sO(r,a,u,c){var h=A.T;A.T=null;var g=q.p;try{q.p=8,mm(r,a,u,c)}finally{q.p=g,A.T=h}}function mm(r,a,u,c){if(ds){var h=hm(c);if(h===null)Wd(r,a,c,ms,u),zx(r,c);else if(fO(h,r,a,u,c))c.stopPropagation();else if(zx(r,c),a&4&&-1<cO.indexOf(r)){for(;h!==null;){var g=Ki(h);if(g!==null)switch(g.tag){case 3:if(g=g.stateNode,g.current.memoizedState.isDehydrated){var _=di(g.pendingLanes);if(_!==0){var k=g;for(k.pendingLanes|=2,k.entangledLanes|=2;_;){var D=1<<31-Qe(_);k.entanglements[1]|=D,_&=~D}Jn(g),(Fe&6)===0&&(Ju=Lt()+500,Fl(0))}}break;case 31:case 13:k=vi(g,2),k!==null&&Kt(k,g,2),Qu(),dm(g,2)}if(g=hm(c),g===null&&Wd(r,a,c,ms,u),g===h)break;h=g}h!==null&&c.stopPropagation()}else Wd(r,a,c,null,u)}}function hm(r){return r=gf(r),pm(r)}var ms=null;function pm(r){if(ms=null,r=Qi(r),r!==null){var a=o(r);if(a===null)r=null;else{var u=a.tag;if(u===13){if(r=s(a),r!==null)return r;r=null}else if(u===31){if(r=f(a),r!==null)return r;r=null}else if(u===3){if(a.stateNode.current.memoizedState.isDehydrated)return a.tag===3?a.stateNode.containerInfo:null;r=null}else a!==r&&(r=null)}}return ms=r,null}function jx(r){switch(r){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(af()){case W:return 2;case se:return 8;case _e:case Ce:return 32;case Be:return 268435456;default:return 32}default:return 32}}var gm=!1,Kr=null,Wr=null,ei=null,Xl=new Map,Ql=new Map,ti=[],cO="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 zx(r,a){switch(r){case"focusin":case"focusout":Kr=null;break;case"dragenter":case"dragleave":Wr=null;break;case"mouseover":case"mouseout":ei=null;break;case"pointerover":case"pointerout":Xl.delete(a.pointerId);break;case"gotpointercapture":case"lostpointercapture":Ql.delete(a.pointerId)}}function Kl(r,a,u,c,h,g){return r===null||r.nativeEvent!==g?(r={blockedOn:a,domEventName:u,eventSystemFlags:c,nativeEvent:g,targetContainers:[h]},a!==null&&(a=Ki(a),a!==null&&$x(a)),r):(r.eventSystemFlags|=c,a=r.targetContainers,h!==null&&a.indexOf(h)===-1&&a.push(h),r)}function fO(r,a,u,c,h){switch(a){case"focusin":return Kr=Kl(Kr,r,a,u,c,h),!0;case"dragenter":return Wr=Kl(Wr,r,a,u,c,h),!0;case"mouseover":return ei=Kl(ei,r,a,u,c,h),!0;case"pointerover":var g=h.pointerId;return Xl.set(g,Kl(Xl.get(g)||null,r,a,u,c,h)),!0;case"gotpointercapture":return g=h.pointerId,Ql.set(g,Kl(Ql.get(g)||null,r,a,u,c,h)),!0}return!1}function Nx(r){var a=Qi(r.target);if(a!==null){var u=o(a);if(u!==null){if(a=u.tag,a===13){if(a=s(u),a!==null){r.blockedOn=a,Fv(r.priority,function(){Ex(u)});return}}else if(a===31){if(a=f(u),a!==null){r.blockedOn=a,Fv(r.priority,function(){Ex(u)});return}}else if(a===3&&u.stateNode.current.memoizedState.isDehydrated){r.blockedOn=u.tag===3?u.stateNode.containerInfo:null;return}}}r.blockedOn=null}function hs(r){if(r.blockedOn!==null)return!1;for(var a=r.targetContainers;0<a.length;){var u=hm(r.nativeEvent);if(u===null){u=r.nativeEvent;var c=new u.constructor(u.type,u);pf=c,u.target.dispatchEvent(c),pf=null}else return a=Ki(u),a!==null&&$x(a),r.blockedOn=u,!1;a.shift()}return!0}function Ox(r,a,u){hs(r)&&u.delete(a)}function dO(){gm=!1,Kr!==null&&hs(Kr)&&(Kr=null),Wr!==null&&hs(Wr)&&(Wr=null),ei!==null&&hs(ei)&&(ei=null),Xl.forEach(Ox),Ql.forEach(Ox)}function ps(r,a){r.blockedOn===a&&(r.blockedOn=null,gm||(gm=!0,e.unstable_scheduleCallback(e.unstable_NormalPriority,dO)))}var gs=null;function Tx(r){gs!==r&&(gs=r,e.unstable_scheduleCallback(e.unstable_NormalPriority,function(){gs===r&&(gs=null);for(var a=0;a<r.length;a+=3){var u=r[a],c=r[a+1],h=r[a+2];if(typeof c!="function"){if(pm(c||u)===null)continue;break}var g=Ki(u);g!==null&&(r.splice(a,3),a-=3,hd(g,{pending:!0,data:h,method:u.method,action:c},c,h))}}))}function Da(r){function a(D){return ps(D,r)}Kr!==null&&ps(Kr,r),Wr!==null&&ps(Wr,r),ei!==null&&ps(ei,r),Xl.forEach(a),Ql.forEach(a);for(var u=0;u<ti.length;u++){var c=ti[u];c.blockedOn===r&&(c.blockedOn=null)}for(;0<ti.length&&(u=ti[0],u.blockedOn===null);)Nx(u),u.blockedOn===null&&ti.shift();if(u=(r.ownerDocument||r).$$reactFormReplay,u!=null)for(c=0;c<u.length;c+=3){var h=u[c],g=u[c+1],_=h[Gt]||null;if(typeof g=="function")_||Tx(u);else if(_){var k=null;if(g&&g.hasAttribute("formAction")){if(h=g,_=g[Gt]||null)k=_.formAction;else if(pm(h)!==null)continue}else k=_.action;typeof k=="function"?u[c+1]=k:(u.splice(c,3),c-=3),Tx(u)}}}function Cx(){function r(g){g.canIntercept&&g.info==="react-transition"&&g.intercept({handler:function(){return new Promise(function(_){return h=_})},focusReset:"manual",scroll:"manual"})}function a(){h!==null&&(h(),h=null),c||setTimeout(u,20)}function u(){if(!c&&!navigation.transition){var g=navigation.currentEntry;g&&g.url!=null&&navigation.navigate(g.url,{state:g.getState(),info:"react-transition",history:"replace"})}}if(typeof navigation=="object"){var c=!1,h=null;return navigation.addEventListener("navigate",r),navigation.addEventListener("navigatesuccess",a),navigation.addEventListener("navigateerror",a),setTimeout(u,100),function(){c=!0,navigation.removeEventListener("navigate",r),navigation.removeEventListener("navigatesuccess",a),navigation.removeEventListener("navigateerror",a),h!==null&&(h(),h=null)}}}function vm(r){this._internalRoot=r}vs.prototype.render=vm.prototype.render=function(r){var a=this._internalRoot;if(a===null)throw Error(l(409));var u=a.current,c=cn();kx(u,c,r,a,null,null)},vs.prototype.unmount=vm.prototype.unmount=function(){var r=this._internalRoot;if(r!==null){this._internalRoot=null;var a=r.containerInfo;kx(r.current,2,null,r,null,null),Qu(),a[Xi]=null}};function vs(r){this._internalRoot=r}vs.prototype.unstable_scheduleHydration=function(r){if(r){var a=qv();r={blockedOn:null,target:r,priority:a};for(var u=0;u<ti.length&&a!==0&&a<ti[u].priority;u++);ti.splice(u,0,r),u===0&&Nx(r)}};var Dx=t.version;if(Dx!=="19.2.3")throw Error(l(527,Dx,"19.2.3"));q.findDOMNode=function(r){var a=r._reactInternals;if(a===void 0)throw typeof r.render=="function"?Error(l(188)):(r=Object.keys(r).join(","),Error(l(268,r)));return r=d(a),r=r!==null?p(r):null,r=r===null?null:r.stateNode,r};var mO={bundleType:0,version:"19.2.3",rendererPackageName:"react-dom",currentDispatcherRef:A,reconcilerVersion:"19.2.3"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var ys=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!ys.isDisabled&&ys.supportsFiber)try{Mt=ys.inject(mO),St=ys}catch{}}return eo.createRoot=function(r,a){if(!n(r))throw Error(l(299));var u=!1,c="",h=Pb,g=Zb,_=qb;return a!=null&&(a.unstable_strictMode===!0&&(u=!0),a.identifierPrefix!==void 0&&(c=a.identifierPrefix),a.onUncaughtError!==void 0&&(h=a.onUncaughtError),a.onCaughtError!==void 0&&(g=a.onCaughtError),a.onRecoverableError!==void 0&&(_=a.onRecoverableError)),a=_x(r,1,!1,null,null,u,c,null,h,g,_,Cx),r[Xi]=a.current,Kd(r),new vm(a)},eo.hydrateRoot=function(r,a,u){if(!n(r))throw Error(l(299));var c=!1,h="",g=Pb,_=Zb,k=qb,D=null;return u!=null&&(u.unstable_strictMode===!0&&(c=!0),u.identifierPrefix!==void 0&&(h=u.identifierPrefix),u.onUncaughtError!==void 0&&(g=u.onUncaughtError),u.onCaughtError!==void 0&&(_=u.onCaughtError),u.onRecoverableError!==void 0&&(k=u.onRecoverableError),u.formState!==void 0&&(D=u.formState)),a=_x(r,1,!0,a,u??null,c,h,D,g,_,k,Cx),a.context=Sx(null),u=a.current,c=cn(),c=of(c),h=Pr(c),h.callback=null,Zr(u,h,c),u=c,a.current.lanes=u,sl(a,u),Jn(a),r[Xi]=a.current,Kd(r),new vs(a)},eo.version="19.2.3",eo}var Fx;function wO(){if(Fx)return xm.exports;Fx=1;function e(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e)}catch(t){console.error(t)}}return e(),xm.exports=kO(),xm.exports}var $O=wO();const EO=_o($O);var Bx="popstate";function jO(e={}){function t(l,n){let{pathname:o,search:s,hash:f}=l.location;return Uh("",{pathname:o,search:s,hash:f},n.state&&n.state.usr||null,n.state&&n.state.key||"default")}function i(l,n){return typeof n=="string"?n:fo(n)}return NO(t,i,null,e)}function ct(e,t){if(e===!1||e===null||typeof e>"u")throw new Error(t)}function Tn(e,t){if(!e){typeof console<"u"&&console.warn(t);try{throw new Error(t)}catch{}}}function zO(){return Math.random().toString(36).substring(2,10)}function Hx(e,t){return{usr:e.state,key:e.key,idx:t}}function Uh(e,t,i=null,l){return{pathname:typeof e=="string"?e:e.pathname,search:"",hash:"",...typeof t=="string"?Qa(t):t,state:i,key:t&&t.key||l||zO()}}function fo({pathname:e="/",search:t="",hash:i=""}){return t&&t!=="?"&&(e+=t.charAt(0)==="?"?t:"?"+t),i&&i!=="#"&&(e+=i.charAt(0)==="#"?i:"#"+i),e}function Qa(e){let t={};if(e){let i=e.indexOf("#");i>=0&&(t.hash=e.substring(i),e=e.substring(0,i));let l=e.indexOf("?");l>=0&&(t.search=e.substring(l),e=e.substring(0,l)),e&&(t.pathname=e)}return t}function NO(e,t,i,l={}){let{window:n=document.defaultView,v5Compat:o=!1}=l,s=n.history,f="POP",m=null,d=p();d==null&&(d=0,s.replaceState({...s.state,idx:d},""));function p(){return(s.state||{idx:null}).idx}function v(){f="POP";let j=p(),E=j==null?null:j-d;d=j,m&&m({action:f,location:w.location,delta:E})}function b(j,E){f="PUSH";let O=Uh(w.location,j,E);d=p()+1;let N=Hx(O,d),G=w.createHref(O);try{s.pushState(N,"",G)}catch(J){if(J instanceof DOMException&&J.name==="DataCloneError")throw J;n.location.assign(G)}o&&m&&m({action:f,location:w.location,delta:1})}function x(j,E){f="REPLACE";let O=Uh(w.location,j,E);d=p();let N=Hx(O,d),G=w.createHref(O);s.replaceState(N,"",G),o&&m&&m({action:f,location:w.location,delta:0})}function S(j){return OO(j)}let w={get action(){return f},get location(){return e(n,s)},listen(j){if(m)throw new Error("A history only accepts one active listener");return n.addEventListener(Bx,v),m=j,()=>{n.removeEventListener(Bx,v),m=null}},createHref(j){return t(n,j)},createURL:S,encodeLocation(j){let E=S(j);return{pathname:E.pathname,search:E.search,hash:E.hash}},push:b,replace:x,go(j){return s.go(j)}};return w}function OO(e,t=!1){let i="http://localhost";typeof window<"u"&&(i=window.location.origin!=="null"?window.location.origin:window.location.href),ct(i,"No window.location.(origin|href) available to create URL");let l=typeof e=="string"?e:fo(e);return l=l.replace(/ $/,"%20"),!t&&l.startsWith("//")&&(l=i+l),new URL(l,i)}function dS(e,t,i="/"){return TO(e,t,i,!1)}function TO(e,t,i,l){let n=typeof t=="string"?Qa(t):t,o=zr(n.pathname||"/",i);if(o==null)return null;let s=mS(e);CO(s);let f=null;for(let m=0;f==null&&m<s.length;++m){let d=FO(o);f=ZO(s[m],d,l)}return f}function mS(e,t=[],i=[],l="",n=!1){let o=(s,f,m=n,d)=>{let p={relativePath:d===void 0?s.path||"":d,caseSensitive:s.caseSensitive===!0,childrenIndex:f,route:s};if(p.relativePath.startsWith("/")){if(!p.relativePath.startsWith(l)&&m)return;ct(p.relativePath.startsWith(l),`Absolute route path "${p.relativePath}" nested under path "${l}" is not valid. An absolute child route path must start with the combined path of all its parent routes.`),p.relativePath=p.relativePath.slice(l.length)}let v=Er([l,p.relativePath]),b=i.concat(p);s.children&&s.children.length>0&&(ct(s.index!==!0,`Index routes must not have child routes. Please remove all child routes from route path "${v}".`),mS(s.children,t,b,v,m)),!(s.path==null&&!s.index)&&t.push({path:v,score:MO(v,s.index),routesMeta:b})};return e.forEach((s,f)=>{if(s.path===""||!s.path?.includes("?"))o(s,f);else for(let m of hS(s.path))o(s,f,!0,m)}),t}function hS(e){let t=e.split("/");if(t.length===0)return[];let[i,...l]=t,n=i.endsWith("?"),o=i.replace(/\?$/,"");if(l.length===0)return n?[o,""]:[o];let s=hS(l.join("/")),f=[];return f.push(...s.map(m=>m===""?o:[o,m].join("/"))),n&&f.push(...s),f.map(m=>e.startsWith("/")&&m===""?"/":m)}function CO(e){e.sort((t,i)=>t.score!==i.score?i.score-t.score:PO(t.routesMeta.map(l=>l.childrenIndex),i.routesMeta.map(l=>l.childrenIndex)))}var DO=/^:[\w-]+$/,AO=3,RO=2,IO=1,UO=10,LO=-2,Gx=e=>e==="*";function MO(e,t){let i=e.split("/"),l=i.length;return i.some(Gx)&&(l+=LO),t&&(l+=RO),i.filter(n=>!Gx(n)).reduce((n,o)=>n+(DO.test(o)?AO:o===""?IO:UO),l)}function PO(e,t){return e.length===t.length&&e.slice(0,-1).every((l,n)=>l===t[n])?e[e.length-1]-t[t.length-1]:0}function ZO(e,t,i=!1){let{routesMeta:l}=e,n={},o="/",s=[];for(let f=0;f<l.length;++f){let m=l[f],d=f===l.length-1,p=o==="/"?t:t.slice(o.length)||"/",v=Ds({path:m.relativePath,caseSensitive:m.caseSensitive,end:d},p),b=m.route;if(!v&&d&&i&&!l[l.length-1].route.index&&(v=Ds({path:m.relativePath,caseSensitive:m.caseSensitive,end:!1},p)),!v)return null;Object.assign(n,v.params),s.push({params:n,pathname:Er([o,v.pathname]),pathnameBase:VO(Er([o,v.pathnameBase])),route:b}),v.pathnameBase!=="/"&&(o=Er([o,v.pathnameBase]))}return s}function Ds(e,t){typeof e=="string"&&(e={path:e,caseSensitive:!1,end:!0});let[i,l]=qO(e.path,e.caseSensitive,e.end),n=t.match(i);if(!n)return null;let o=n[0],s=o.replace(/(.)\/+$/,"$1"),f=n.slice(1);return{params:l.reduce((d,{paramName:p,isOptional:v},b)=>{if(p==="*"){let S=f[b]||"";s=o.slice(0,o.length-S.length).replace(/(.)\/+$/,"$1")}const x=f[b];return v&&!x?d[p]=void 0:d[p]=(x||"").replace(/%2F/g,"/"),d},{}),pathname:o,pathnameBase:s,pattern:e}}function qO(e,t=!1,i=!0){Tn(e==="*"||!e.endsWith("*")||e.endsWith("/*"),`Route path "${e}" will be treated as if it were "${e.replace(/\*$/,"/*")}" because the \`*\` character must always follow a \`/\` in the pattern. To get rid of this warning, please change the route path to "${e.replace(/\*$/,"/*")}".`);let l=[],n="^"+e.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(s,f,m)=>(l.push({paramName:f,isOptional:m!=null}),m?"/?([^\\/]+)?":"/([^\\/]+)")).replace(/\/([\w-]+)\?(\/|$)/g,"(/$1)?$2");return e.endsWith("*")?(l.push({paramName:"*"}),n+=e==="*"||e==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):i?n+="\\/*$":e!==""&&e!=="/"&&(n+="(?:(?=\\/|$))"),[new RegExp(n,t?void 0:"i"),l]}function FO(e){try{return e.split("/").map(t=>decodeURIComponent(t).replace(/\//g,"%2F")).join("/")}catch(t){return Tn(!1,`The URL path "${e}" could not be decoded because it is a malformed URL segment. This is probably due to a bad percent encoding (${t}).`),e}}function zr(e,t){if(t==="/")return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let i=t.endsWith("/")?t.length-1:t.length,l=e.charAt(i);return l&&l!=="/"?null:e.slice(i)||"/"}var pS=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,BO=e=>pS.test(e);function HO(e,t="/"){let{pathname:i,search:l="",hash:n=""}=typeof e=="string"?Qa(e):e,o;if(i)if(BO(i))o=i;else{if(i.includes("//")){let s=i;i=i.replace(/\/\/+/g,"/"),Tn(!1,`Pathnames cannot have embedded double slashes - normalizing ${s} -> ${i}`)}i.startsWith("/")?o=Vx(i.substring(1),"/"):o=Vx(i,t)}else o=t;return{pathname:o,search:YO(l),hash:JO(n)}}function Vx(e,t){let i=t.replace(/\/+$/,"").split("/");return e.split("/").forEach(n=>{n===".."?i.length>1&&i.pop():n!=="."&&i.push(n)}),i.length>1?i.join("/"):"/"}function wm(e,t,i,l){return`Cannot include a '${e}' character in a manually specified \`to.${t}\` field [${JSON.stringify(l)}]. Please separate it out to the \`to.${i}\` field. Alternatively you may provide the full path as a string in <Link to="..."> and the router will parse it for you.`}function GO(e){return e.filter((t,i)=>i===0||t.route.path&&t.route.path.length>0)}function gS(e){let t=GO(e);return t.map((i,l)=>l===t.length-1?i.pathname:i.pathnameBase)}function vS(e,t,i,l=!1){let n;typeof e=="string"?n=Qa(e):(n={...e},ct(!n.pathname||!n.pathname.includes("?"),wm("?","pathname","search",n)),ct(!n.pathname||!n.pathname.includes("#"),wm("#","pathname","hash",n)),ct(!n.search||!n.search.includes("#"),wm("#","search","hash",n)));let o=e===""||n.pathname==="",s=o?"/":n.pathname,f;if(s==null)f=i;else{let v=t.length-1;if(!l&&s.startsWith("..")){let b=s.split("/");for(;b[0]==="..";)b.shift(),v-=1;n.pathname=b.join("/")}f=v>=0?t[v]:"/"}let m=HO(n,f),d=s&&s!=="/"&&s.endsWith("/"),p=(o||s===".")&&i.endsWith("/");return!m.pathname.endsWith("/")&&(d||p)&&(m.pathname+="/"),m}var Er=e=>e.join("/").replace(/\/\/+/g,"/"),VO=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),YO=e=>!e||e==="?"?"":e.startsWith("?")?e:"?"+e,JO=e=>!e||e==="#"?"":e.startsWith("#")?e:"#"+e,XO=class{constructor(e,t,i,l=!1){this.status=e,this.statusText=t||"",this.internal=l,i instanceof Error?(this.data=i.toString(),this.error=i):this.data=i}};function QO(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.internal=="boolean"&&"data"in e}function KO(e){return e.map(t=>t.route.path).filter(Boolean).join("/").replace(/\/\/*/g,"/")||"/"}var yS=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";function bS(e,t){let i=e;if(typeof i!="string"||!pS.test(i))return{absoluteURL:void 0,isExternal:!1,to:i};let l=i,n=!1;if(yS)try{let o=new URL(window.location.href),s=i.startsWith("//")?new URL(o.protocol+i):new URL(i),f=zr(s.pathname,t);s.origin===o.origin&&f!=null?i=f+s.search+s.hash:n=!0}catch{Tn(!1,`<Link to="${i}"> contains an invalid URL which will probably break when clicked - please update to a valid URL path.`)}return{absoluteURL:l,isExternal:n,to:i}}Object.getOwnPropertyNames(Object.prototype).sort().join("\0");var xS=["POST","PUT","PATCH","DELETE"];new Set(xS);var WO=["GET",...xS];new Set(WO);var Ka=C.createContext(null);Ka.displayName="DataRouter";var Js=C.createContext(null);Js.displayName="DataRouterState";var eT=C.createContext(!1),_S=C.createContext({isTransitioning:!1});_S.displayName="ViewTransition";var tT=C.createContext(new Map);tT.displayName="Fetchers";var nT=C.createContext(null);nT.displayName="Await";var An=C.createContext(null);An.displayName="Navigation";var So=C.createContext(null);So.displayName="Location";var Wn=C.createContext({outlet:null,matches:[],isDataRoute:!1});Wn.displayName="Route";var mp=C.createContext(null);mp.displayName="RouteError";var SS="REACT_ROUTER_ERROR",rT="REDIRECT",iT="ROUTE_ERROR_RESPONSE";function aT(e){if(e.startsWith(`${SS}:${rT}:{`))try{let t=JSON.parse(e.slice(28));if(typeof t=="object"&&t&&typeof t.status=="number"&&typeof t.statusText=="string"&&typeof t.location=="string"&&typeof t.reloadDocument=="boolean"&&typeof t.replace=="boolean")return t}catch{}}function lT(e){if(e.startsWith(`${SS}:${iT}:{`))try{let t=JSON.parse(e.slice(40));if(typeof t=="object"&&t&&typeof t.status=="number"&&typeof t.statusText=="string")return new XO(t.status,t.statusText,t.data)}catch{}}function oT(e,{relative:t}={}){ct(ko(),"useHref() may be used only in the context of a <Router> component.");let{basename:i,navigator:l}=C.useContext(An),{hash:n,pathname:o,search:s}=$o(e,{relative:t}),f=o;return i!=="/"&&(f=o==="/"?i:Er([i,o])),l.createHref({pathname:f,search:s,hash:n})}function ko(){return C.useContext(So)!=null}function er(){return ct(ko(),"useLocation() may be used only in the context of a <Router> component."),C.useContext(So).location}var kS="You should call navigate() in a React.useEffect(), not when your component is first rendered.";function wS(e){C.useContext(An).static||C.useLayoutEffect(e)}function wo(){let{isDataRoute:e}=C.useContext(Wn);return e?xT():uT()}function uT(){ct(ko(),"useNavigate() may be used only in the context of a <Router> component.");let e=C.useContext(Ka),{basename:t,navigator:i}=C.useContext(An),{matches:l}=C.useContext(Wn),{pathname:n}=er(),o=JSON.stringify(gS(l)),s=C.useRef(!1);return wS(()=>{s.current=!0}),C.useCallback((m,d={})=>{if(Tn(s.current,kS),!s.current)return;if(typeof m=="number"){i.go(m);return}let p=vS(m,JSON.parse(o),n,d.relative==="path");e==null&&t!=="/"&&(p.pathname=p.pathname==="/"?t:Er([t,p.pathname])),(d.replace?i.replace:i.push)(p,d.state,d)},[t,i,o,n,e])}C.createContext(null);function $S(){let{matches:e}=C.useContext(Wn),t=e[e.length-1];return t?t.params:{}}function $o(e,{relative:t}={}){let{matches:i}=C.useContext(Wn),{pathname:l}=er(),n=JSON.stringify(gS(i));return C.useMemo(()=>vS(e,JSON.parse(n),l,t==="path"),[e,n,l,t])}function sT(e,t){return ES(e,t)}function ES(e,t,i,l,n){ct(ko(),"useRoutes() may be used only in the context of a <Router> component.");let{navigator:o}=C.useContext(An),{matches:s}=C.useContext(Wn),f=s[s.length-1],m=f?f.params:{},d=f?f.pathname:"/",p=f?f.pathnameBase:"/",v=f&&f.route;{let O=v&&v.path||"";zS(d,!v||O.endsWith("*")||O.endsWith("*?"),`You rendered descendant <Routes> (or called \`useRoutes()\`) at "${d}" (under <Route path="${O}">) but the parent route path has no trailing "*". This means if you navigate deeper, the parent won't match anymore and therefore the child routes will never render.
|
|
10
|
+
|
|
11
|
+
Please change the parent <Route path="${O}"> to <Route path="${O==="/"?"*":`${O}/*`}">.`)}let b=er(),x;if(t){let O=typeof t=="string"?Qa(t):t;ct(p==="/"||O.pathname?.startsWith(p),`When overriding the location using \`<Routes location>\` or \`useRoutes(routes, location)\`, the location pathname must begin with the portion of the URL pathname that was matched by all parent routes. The current pathname base is "${p}" but pathname "${O.pathname}" was given in the \`location\` prop.`),x=O}else x=b;let S=x.pathname||"/",w=S;if(p!=="/"){let O=p.replace(/^\//,"").split("/");w="/"+S.replace(/^\//,"").split("/").slice(O.length).join("/")}let j=dS(e,{pathname:w});Tn(v||j!=null,`No routes matched location "${x.pathname}${x.search}${x.hash}" `),Tn(j==null||j[j.length-1].route.element!==void 0||j[j.length-1].route.Component!==void 0||j[j.length-1].route.lazy!==void 0,`Matched leaf route at location "${x.pathname}${x.search}${x.hash}" does not have an element or Component. This means it will render an <Outlet /> with a null value by default resulting in an "empty" page.`);let E=hT(j&&j.map(O=>Object.assign({},O,{params:Object.assign({},m,O.params),pathname:Er([p,o.encodeLocation?o.encodeLocation(O.pathname.replace(/\?/g,"%3F").replace(/#/g,"%23")).pathname:O.pathname]),pathnameBase:O.pathnameBase==="/"?p:Er([p,o.encodeLocation?o.encodeLocation(O.pathnameBase.replace(/\?/g,"%3F").replace(/#/g,"%23")).pathname:O.pathnameBase])})),s,i,l,n);return t&&E?C.createElement(So.Provider,{value:{location:{pathname:"/",search:"",hash:"",state:null,key:"default",...x},navigationType:"POP"}},E):E}function cT(){let e=bT(),t=QO(e)?`${e.status} ${e.statusText}`:e instanceof Error?e.message:JSON.stringify(e),i=e instanceof Error?e.stack:null,l="rgba(200,200,200, 0.5)",n={padding:"0.5rem",backgroundColor:l},o={padding:"2px 4px",backgroundColor:l},s=null;return console.error("Error handled by React Router default ErrorBoundary:",e),s=C.createElement(C.Fragment,null,C.createElement("p",null,"💿 Hey developer 👋"),C.createElement("p",null,"You can provide a way better UX than this when your app throws errors by providing your own ",C.createElement("code",{style:o},"ErrorBoundary")," or"," ",C.createElement("code",{style:o},"errorElement")," prop on your route.")),C.createElement(C.Fragment,null,C.createElement("h2",null,"Unexpected Application Error!"),C.createElement("h3",{style:{fontStyle:"italic"}},t),i?C.createElement("pre",{style:n},i):null,s)}var fT=C.createElement(cT,null),jS=class extends C.Component{constructor(e){super(e),this.state={location:e.location,revalidation:e.revalidation,error:e.error}}static getDerivedStateFromError(e){return{error:e}}static getDerivedStateFromProps(e,t){return t.location!==e.location||t.revalidation!=="idle"&&e.revalidation==="idle"?{error:e.error,location:e.location,revalidation:e.revalidation}:{error:e.error!==void 0?e.error:t.error,location:t.location,revalidation:e.revalidation||t.revalidation}}componentDidCatch(e,t){this.props.onError?this.props.onError(e,t):console.error("React Router caught the following error during render",e)}render(){let e=this.state.error;if(this.context&&typeof e=="object"&&e&&"digest"in e&&typeof e.digest=="string"){const i=lT(e.digest);i&&(e=i)}let t=e!==void 0?C.createElement(Wn.Provider,{value:this.props.routeContext},C.createElement(mp.Provider,{value:e,children:this.props.component})):this.props.children;return this.context?C.createElement(dT,{error:e},t):t}};jS.contextType=eT;var $m=new WeakMap;function dT({children:e,error:t}){let{basename:i}=C.useContext(An);if(typeof t=="object"&&t&&"digest"in t&&typeof t.digest=="string"){let l=aT(t.digest);if(l){let n=$m.get(t);if(n)throw n;let o=bS(l.location,i);if(yS&&!$m.get(t))if(o.isExternal||l.reloadDocument)window.location.href=o.absoluteURL||o.to;else{const s=Promise.resolve().then(()=>window.__reactRouterDataRouter.navigate(o.to,{replace:l.replace}));throw $m.set(t,s),s}return C.createElement("meta",{httpEquiv:"refresh",content:`0;url=${o.absoluteURL||o.to}`})}}return e}function mT({routeContext:e,match:t,children:i}){let l=C.useContext(Ka);return l&&l.static&&l.staticContext&&(t.route.errorElement||t.route.ErrorBoundary)&&(l.staticContext._deepestRenderedBoundaryId=t.route.id),C.createElement(Wn.Provider,{value:e},i)}function hT(e,t=[],i=null,l=null,n=null){if(e==null){if(!i)return null;if(i.errors)e=i.matches;else if(t.length===0&&!i.initialized&&i.matches.length>0)e=i.matches;else return null}let o=e,s=i?.errors;if(s!=null){let p=o.findIndex(v=>v.route.id&&s?.[v.route.id]!==void 0);ct(p>=0,`Could not find a matching route for errors on route IDs: ${Object.keys(s).join(",")}`),o=o.slice(0,Math.min(o.length,p+1))}let f=!1,m=-1;if(i)for(let p=0;p<o.length;p++){let v=o[p];if((v.route.HydrateFallback||v.route.hydrateFallbackElement)&&(m=p),v.route.id){let{loaderData:b,errors:x}=i,S=v.route.loader&&!b.hasOwnProperty(v.route.id)&&(!x||x[v.route.id]===void 0);if(v.route.lazy||S){f=!0,m>=0?o=o.slice(0,m+1):o=[o[0]];break}}}let d=i&&l?(p,v)=>{l(p,{location:i.location,params:i.matches?.[0]?.params??{},unstable_pattern:KO(i.matches),errorInfo:v})}:void 0;return o.reduceRight((p,v,b)=>{let x,S=!1,w=null,j=null;i&&(x=s&&v.route.id?s[v.route.id]:void 0,w=v.route.errorElement||fT,f&&(m<0&&b===0?(zS("route-fallback",!1,"No `HydrateFallback` element provided to render during initial hydration"),S=!0,j=null):m===b&&(S=!0,j=v.route.hydrateFallbackElement||null)));let E=t.concat(o.slice(0,b+1)),O=()=>{let N;return x?N=w:S?N=j:v.route.Component?N=C.createElement(v.route.Component,null):v.route.element?N=v.route.element:N=p,C.createElement(mT,{match:v,routeContext:{outlet:p,matches:E,isDataRoute:i!=null},children:N})};return i&&(v.route.ErrorBoundary||v.route.errorElement||b===0)?C.createElement(jS,{location:i.location,revalidation:i.revalidation,component:w,error:x,children:O(),routeContext:{outlet:null,matches:E,isDataRoute:!0},onError:d}):O()},null)}function hp(e){return`${e} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function pT(e){let t=C.useContext(Ka);return ct(t,hp(e)),t}function gT(e){let t=C.useContext(Js);return ct(t,hp(e)),t}function vT(e){let t=C.useContext(Wn);return ct(t,hp(e)),t}function pp(e){let t=vT(e),i=t.matches[t.matches.length-1];return ct(i.route.id,`${e} can only be used on routes that contain a unique "id"`),i.route.id}function yT(){return pp("useRouteId")}function bT(){let e=C.useContext(mp),t=gT("useRouteError"),i=pp("useRouteError");return e!==void 0?e:t.errors?.[i]}function xT(){let{router:e}=pT("useNavigate"),t=pp("useNavigate"),i=C.useRef(!1);return wS(()=>{i.current=!0}),C.useCallback(async(n,o={})=>{Tn(i.current,kS),i.current&&(typeof n=="number"?await e.navigate(n):await e.navigate(n,{fromRouteId:t,...o}))},[e,t])}var Yx={};function zS(e,t,i){!t&&!Yx[e]&&(Yx[e]=!0,Tn(!1,i))}C.memo(_T);function _T({routes:e,future:t,state:i,onError:l}){return ES(e,void 0,i,l,t)}function $r(e){ct(!1,"A <Route> is only ever to be used as the child of <Routes> element, never rendered directly. Please wrap your <Route> in a <Routes>.")}function ST({basename:e="/",children:t=null,location:i,navigationType:l="POP",navigator:n,static:o=!1,unstable_useTransitions:s}){ct(!ko(),"You cannot render a <Router> inside another <Router>. You should never have more than one in your app.");let f=e.replace(/^\/*/,"/"),m=C.useMemo(()=>({basename:f,navigator:n,static:o,unstable_useTransitions:s,future:{}}),[f,n,o,s]);typeof i=="string"&&(i=Qa(i));let{pathname:d="/",search:p="",hash:v="",state:b=null,key:x="default"}=i,S=C.useMemo(()=>{let w=zr(d,f);return w==null?null:{location:{pathname:w,search:p,hash:v,state:b,key:x},navigationType:l}},[f,d,p,v,b,x,l]);return Tn(S!=null,`<Router basename="${f}"> is not able to match the URL "${d}${p}${v}" because it does not start with the basename, so the <Router> won't render anything.`),S==null?null:C.createElement(An.Provider,{value:m},C.createElement(So.Provider,{children:t,value:S}))}function Jx({children:e,location:t}){return sT(Lh(e),t)}function Lh(e,t=[]){let i=[];return C.Children.forEach(e,(l,n)=>{if(!C.isValidElement(l))return;let o=[...t,n];if(l.type===C.Fragment){i.push.apply(i,Lh(l.props.children,o));return}ct(l.type===$r,`[${typeof l.type=="string"?l.type:l.type.name}] is not a <Route> component. All component children of <Routes> must be a <Route> or <React.Fragment>`),ct(!l.props.index||!l.props.children,"An index route cannot have child routes.");let s={id:l.props.id||o.join("-"),caseSensitive:l.props.caseSensitive,element:l.props.element,Component:l.props.Component,index:l.props.index,path:l.props.path,middleware:l.props.middleware,loader:l.props.loader,action:l.props.action,hydrateFallbackElement:l.props.hydrateFallbackElement,HydrateFallback:l.props.HydrateFallback,errorElement:l.props.errorElement,ErrorBoundary:l.props.ErrorBoundary,hasErrorBoundary:l.props.hasErrorBoundary===!0||l.props.ErrorBoundary!=null||l.props.errorElement!=null,shouldRevalidate:l.props.shouldRevalidate,handle:l.props.handle,lazy:l.props.lazy};l.props.children&&(s.children=Lh(l.props.children,o)),i.push(s)}),i}var Os="get",Ts="application/x-www-form-urlencoded";function Xs(e){return typeof HTMLElement<"u"&&e instanceof HTMLElement}function kT(e){return Xs(e)&&e.tagName.toLowerCase()==="button"}function wT(e){return Xs(e)&&e.tagName.toLowerCase()==="form"}function $T(e){return Xs(e)&&e.tagName.toLowerCase()==="input"}function ET(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}function jT(e,t){return e.button===0&&(!t||t==="_self")&&!ET(e)}function Mh(e=""){return new URLSearchParams(typeof e=="string"||Array.isArray(e)||e instanceof URLSearchParams?e:Object.keys(e).reduce((t,i)=>{let l=e[i];return t.concat(Array.isArray(l)?l.map(n=>[i,n]):[[i,l]])},[]))}function zT(e,t){let i=Mh(e);return t&&t.forEach((l,n)=>{i.has(n)||t.getAll(n).forEach(o=>{i.append(n,o)})}),i}var bs=null;function NT(){if(bs===null)try{new FormData(document.createElement("form"),0),bs=!1}catch{bs=!0}return bs}var OT=new Set(["application/x-www-form-urlencoded","multipart/form-data","text/plain"]);function Em(e){return e!=null&&!OT.has(e)?(Tn(!1,`"${e}" is not a valid \`encType\` for \`<Form>\`/\`<fetcher.Form>\` and will default to "${Ts}"`),null):e}function TT(e,t){let i,l,n,o,s;if(wT(e)){let f=e.getAttribute("action");l=f?zr(f,t):null,i=e.getAttribute("method")||Os,n=Em(e.getAttribute("enctype"))||Ts,o=new FormData(e)}else if(kT(e)||$T(e)&&(e.type==="submit"||e.type==="image")){let f=e.form;if(f==null)throw new Error('Cannot submit a <button> or <input type="submit"> without a <form>');let m=e.getAttribute("formaction")||f.getAttribute("action");if(l=m?zr(m,t):null,i=e.getAttribute("formmethod")||f.getAttribute("method")||Os,n=Em(e.getAttribute("formenctype"))||Em(f.getAttribute("enctype"))||Ts,o=new FormData(f,e),!NT()){let{name:d,type:p,value:v}=e;if(p==="image"){let b=d?`${d}.`:"";o.append(`${b}x`,"0"),o.append(`${b}y`,"0")}else d&&o.append(d,v)}}else{if(Xs(e))throw new Error('Cannot submit element that is not <form>, <button>, or <input type="submit|image">');i=Os,l=null,n=Ts,s=e}return o&&n==="text/plain"&&(s=o,o=void 0),{action:l,method:i.toLowerCase(),encType:n,formData:o,body:s}}Object.getOwnPropertyNames(Object.prototype).sort().join("\0");function gp(e,t){if(e===!1||e===null||typeof e>"u")throw new Error(t)}function CT(e,t,i){let l=typeof e=="string"?new URL(e,typeof window>"u"?"server://singlefetch/":window.location.origin):e;return l.pathname==="/"?l.pathname=`_root.${i}`:t&&zr(l.pathname,t)==="/"?l.pathname=`${t.replace(/\/$/,"")}/_root.${i}`:l.pathname=`${l.pathname.replace(/\/$/,"")}.${i}`,l}async function DT(e,t){if(e.id in t)return t[e.id];try{let i=await import(e.module);return t[e.id]=i,i}catch(i){return console.error(`Error loading route module \`${e.module}\`, reloading page...`),console.error(i),window.__reactRouterContext&&window.__reactRouterContext.isSpaMode,window.location.reload(),new Promise(()=>{})}}function AT(e){return e==null?!1:e.href==null?e.rel==="preload"&&typeof e.imageSrcSet=="string"&&typeof e.imageSizes=="string":typeof e.rel=="string"&&typeof e.href=="string"}async function RT(e,t,i){let l=await Promise.all(e.map(async n=>{let o=t.routes[n.route.id];if(o){let s=await DT(o,i);return s.links?s.links():[]}return[]}));return MT(l.flat(1).filter(AT).filter(n=>n.rel==="stylesheet"||n.rel==="preload").map(n=>n.rel==="stylesheet"?{...n,rel:"prefetch",as:"style"}:{...n,rel:"prefetch"}))}function Xx(e,t,i,l,n,o){let s=(m,d)=>i[d]?m.route.id!==i[d].route.id:!0,f=(m,d)=>i[d].pathname!==m.pathname||i[d].route.path?.endsWith("*")&&i[d].params["*"]!==m.params["*"];return o==="assets"?t.filter((m,d)=>s(m,d)||f(m,d)):o==="data"?t.filter((m,d)=>{let p=l.routes[m.route.id];if(!p||!p.hasLoader)return!1;if(s(m,d)||f(m,d))return!0;if(m.route.shouldRevalidate){let v=m.route.shouldRevalidate({currentUrl:new URL(n.pathname+n.search+n.hash,window.origin),currentParams:i[0]?.params||{},nextUrl:new URL(e,window.origin),nextParams:m.params,defaultShouldRevalidate:!0});if(typeof v=="boolean")return v}return!0}):[]}function IT(e,t,{includeHydrateFallback:i}={}){return UT(e.map(l=>{let n=t.routes[l.route.id];if(!n)return[];let o=[n.module];return n.clientActionModule&&(o=o.concat(n.clientActionModule)),n.clientLoaderModule&&(o=o.concat(n.clientLoaderModule)),i&&n.hydrateFallbackModule&&(o=o.concat(n.hydrateFallbackModule)),n.imports&&(o=o.concat(n.imports)),o}).flat(1))}function UT(e){return[...new Set(e)]}function LT(e){let t={},i=Object.keys(e).sort();for(let l of i)t[l]=e[l];return t}function MT(e,t){let i=new Set;return new Set(t),e.reduce((l,n)=>{let o=JSON.stringify(LT(n));return i.has(o)||(i.add(o),l.push({key:o,link:n})),l},[])}function NS(){let e=C.useContext(Ka);return gp(e,"You must render this element inside a <DataRouterContext.Provider> element"),e}function PT(){let e=C.useContext(Js);return gp(e,"You must render this element inside a <DataRouterStateContext.Provider> element"),e}var vp=C.createContext(void 0);vp.displayName="FrameworkContext";function OS(){let e=C.useContext(vp);return gp(e,"You must render this element inside a <HydratedRouter> element"),e}function ZT(e,t){let i=C.useContext(vp),[l,n]=C.useState(!1),[o,s]=C.useState(!1),{onFocus:f,onBlur:m,onMouseEnter:d,onMouseLeave:p,onTouchStart:v}=t,b=C.useRef(null);C.useEffect(()=>{if(e==="render"&&s(!0),e==="viewport"){let w=E=>{E.forEach(O=>{s(O.isIntersecting)})},j=new IntersectionObserver(w,{threshold:.5});return b.current&&j.observe(b.current),()=>{j.disconnect()}}},[e]),C.useEffect(()=>{if(l){let w=setTimeout(()=>{s(!0)},100);return()=>{clearTimeout(w)}}},[l]);let x=()=>{n(!0)},S=()=>{n(!1),s(!1)};return i?e!=="intent"?[o,b,{}]:[o,b,{onFocus:to(f,x),onBlur:to(m,S),onMouseEnter:to(d,x),onMouseLeave:to(p,S),onTouchStart:to(v,x)}]:[!1,b,{}]}function to(e,t){return i=>{e&&e(i),i.defaultPrevented||t(i)}}function qT({page:e,...t}){let{router:i}=NS(),l=C.useMemo(()=>dS(i.routes,e,i.basename),[i.routes,e,i.basename]);return l?C.createElement(BT,{page:e,matches:l,...t}):null}function FT(e){let{manifest:t,routeModules:i}=OS(),[l,n]=C.useState([]);return C.useEffect(()=>{let o=!1;return RT(e,t,i).then(s=>{o||n(s)}),()=>{o=!0}},[e,t,i]),l}function BT({page:e,matches:t,...i}){let l=er(),{manifest:n,routeModules:o}=OS(),{basename:s}=NS(),{loaderData:f,matches:m}=PT(),d=C.useMemo(()=>Xx(e,t,m,n,l,"data"),[e,t,m,n,l]),p=C.useMemo(()=>Xx(e,t,m,n,l,"assets"),[e,t,m,n,l]),v=C.useMemo(()=>{if(e===l.pathname+l.search+l.hash)return[];let S=new Set,w=!1;if(t.forEach(E=>{let O=n.routes[E.route.id];!O||!O.hasLoader||(!d.some(N=>N.route.id===E.route.id)&&E.route.id in f&&o[E.route.id]?.shouldRevalidate||O.hasClientLoader?w=!0:S.add(E.route.id))}),S.size===0)return[];let j=CT(e,s,"data");return w&&S.size>0&&j.searchParams.set("_routes",t.filter(E=>S.has(E.route.id)).map(E=>E.route.id).join(",")),[j.pathname+j.search]},[s,f,l,n,d,t,e,o]),b=C.useMemo(()=>IT(p,n),[p,n]),x=FT(p);return C.createElement(C.Fragment,null,v.map(S=>C.createElement("link",{key:S,rel:"prefetch",as:"fetch",href:S,...i})),b.map(S=>C.createElement("link",{key:S,rel:"modulepreload",href:S,...i})),x.map(({key:S,link:w})=>C.createElement("link",{key:S,nonce:i.nonce,...w})))}function HT(...e){return t=>{e.forEach(i=>{typeof i=="function"?i(t):i!=null&&(i.current=t)})}}var GT=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";try{GT&&(window.__reactRouterVersion="7.11.0")}catch{}function VT({basename:e,children:t,unstable_useTransitions:i,window:l}){let n=C.useRef();n.current==null&&(n.current=jO({window:l,v5Compat:!0}));let o=n.current,[s,f]=C.useState({action:o.action,location:o.location}),m=C.useCallback(d=>{i===!1?f(d):C.startTransition(()=>f(d))},[i]);return C.useLayoutEffect(()=>o.listen(m),[o,m]),C.createElement(ST,{basename:e,children:t,location:s.location,navigationType:s.action,navigator:o,unstable_useTransitions:i})}var TS=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,Za=C.forwardRef(function({onClick:t,discover:i="render",prefetch:l="none",relative:n,reloadDocument:o,replace:s,state:f,target:m,to:d,preventScrollReset:p,viewTransition:v,unstable_defaultShouldRevalidate:b,...x},S){let{basename:w,unstable_useTransitions:j}=C.useContext(An),E=typeof d=="string"&&TS.test(d),O=bS(d,w);d=O.to;let N=oT(d,{relative:n}),[G,J,R]=ZT(l,x),X=XT(d,{replace:s,state:f,target:m,preventScrollReset:p,relative:n,viewTransition:v,unstable_defaultShouldRevalidate:b,unstable_useTransitions:j});function Q(B){t&&t(B),B.defaultPrevented||X(B)}let me=C.createElement("a",{...x,...R,href:O.absoluteURL||N,onClick:O.isExternal||o?t:Q,ref:HT(S,J),target:m,"data-discover":!E&&i==="render"?"true":void 0});return G&&!E?C.createElement(C.Fragment,null,me,C.createElement(qT,{page:N})):me});Za.displayName="Link";var Ph=C.forwardRef(function({"aria-current":t="page",caseSensitive:i=!1,className:l="",end:n=!1,style:o,to:s,viewTransition:f,children:m,...d},p){let v=$o(s,{relative:d.relative}),b=er(),x=C.useContext(Js),{navigator:S,basename:w}=C.useContext(An),j=x!=null&&n6(v)&&f===!0,E=S.encodeLocation?S.encodeLocation(v).pathname:v.pathname,O=b.pathname,N=x&&x.navigation&&x.navigation.location?x.navigation.location.pathname:null;i||(O=O.toLowerCase(),N=N?N.toLowerCase():null,E=E.toLowerCase()),N&&w&&(N=zr(N,w)||N);const G=E!=="/"&&E.endsWith("/")?E.length-1:E.length;let J=O===E||!n&&O.startsWith(E)&&O.charAt(G)==="/",R=N!=null&&(N===E||!n&&N.startsWith(E)&&N.charAt(E.length)==="/"),X={isActive:J,isPending:R,isTransitioning:j},Q=J?t:void 0,me;typeof l=="function"?me=l(X):me=[l,J?"active":null,R?"pending":null,j?"transitioning":null].filter(Boolean).join(" ");let B=typeof o=="function"?o(X):o;return C.createElement(Za,{...d,"aria-current":Q,className:me,ref:p,style:B,to:s,viewTransition:f},typeof m=="function"?m(X):m)});Ph.displayName="NavLink";var YT=C.forwardRef(({discover:e="render",fetcherKey:t,navigate:i,reloadDocument:l,replace:n,state:o,method:s=Os,action:f,onSubmit:m,relative:d,preventScrollReset:p,viewTransition:v,unstable_defaultShouldRevalidate:b,...x},S)=>{let{unstable_useTransitions:w}=C.useContext(An),j=e6(),E=t6(f,{relative:d}),O=s.toLowerCase()==="get"?"get":"post",N=typeof f=="string"&&TS.test(f),G=J=>{if(m&&m(J),J.defaultPrevented)return;J.preventDefault();let R=J.nativeEvent.submitter,X=R?.getAttribute("formmethod")||s,Q=()=>j(R||J.currentTarget,{fetcherKey:t,method:X,navigate:i,replace:n,state:o,relative:d,preventScrollReset:p,viewTransition:v,unstable_defaultShouldRevalidate:b});w&&i!==!1?C.startTransition(()=>Q()):Q()};return C.createElement("form",{ref:S,method:O,action:E,onSubmit:l?m:G,...x,"data-discover":!N&&e==="render"?"true":void 0})});YT.displayName="Form";function JT(e){return`${e} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function CS(e){let t=C.useContext(Ka);return ct(t,JT(e)),t}function XT(e,{target:t,replace:i,state:l,preventScrollReset:n,relative:o,viewTransition:s,unstable_defaultShouldRevalidate:f,unstable_useTransitions:m}={}){let d=wo(),p=er(),v=$o(e,{relative:o});return C.useCallback(b=>{if(jT(b,t)){b.preventDefault();let x=i!==void 0?i:fo(p)===fo(v),S=()=>d(e,{replace:x,state:l,preventScrollReset:n,relative:o,viewTransition:s,unstable_defaultShouldRevalidate:f});m?C.startTransition(()=>S()):S()}},[p,d,v,i,l,t,e,n,o,s,f,m])}function QT(e){Tn(typeof URLSearchParams<"u","You cannot use the `useSearchParams` hook in a browser that does not support the URLSearchParams API. If you need to support Internet Explorer 11, we recommend you load a polyfill such as https://github.com/ungap/url-search-params.");let t=C.useRef(Mh(e)),i=C.useRef(!1),l=er(),n=C.useMemo(()=>zT(l.search,i.current?null:t.current),[l.search]),o=wo(),s=C.useCallback((f,m)=>{const d=Mh(typeof f=="function"?f(new URLSearchParams(n)):f);i.current=!0,o("?"+d,m)},[o,n]);return[n,s]}var KT=0,WT=()=>`__${String(++KT)}__`;function e6(){let{router:e}=CS("useSubmit"),{basename:t}=C.useContext(An),i=yT(),l=e.fetch,n=e.navigate;return C.useCallback(async(o,s={})=>{let{action:f,method:m,encType:d,formData:p,body:v}=TT(o,t);if(s.navigate===!1){let b=s.fetcherKey||WT();await l(b,i,s.action||f,{unstable_defaultShouldRevalidate:s.unstable_defaultShouldRevalidate,preventScrollReset:s.preventScrollReset,formData:p,body:v,formMethod:s.method||m,formEncType:s.encType||d,flushSync:s.flushSync})}else await n(s.action||f,{unstable_defaultShouldRevalidate:s.unstable_defaultShouldRevalidate,preventScrollReset:s.preventScrollReset,formData:p,body:v,formMethod:s.method||m,formEncType:s.encType||d,replace:s.replace,state:s.state,fromRouteId:i,flushSync:s.flushSync,viewTransition:s.viewTransition})},[l,n,t,i])}function t6(e,{relative:t}={}){let{basename:i}=C.useContext(An),l=C.useContext(Wn);ct(l,"useFormAction must be used inside a RouteContext");let[n]=l.matches.slice(-1),o={...$o(e||".",{relative:t})},s=er();if(e==null){o.search=s.search;let f=new URLSearchParams(o.search),m=f.getAll("index");if(m.some(p=>p==="")){f.delete("index"),m.filter(v=>v).forEach(v=>f.append("index",v));let p=f.toString();o.search=p?`?${p}`:""}}return(!e||e===".")&&n.route.index&&(o.search=o.search?o.search.replace(/^\?/,"?index&"):"?index"),i!=="/"&&(o.pathname=o.pathname==="/"?i:Er([i,o.pathname])),fo(o)}function n6(e,{relative:t}={}){let i=C.useContext(_S);ct(i!=null,"`useViewTransitionState` must be used within `react-router-dom`'s `RouterProvider`. Did you accidentally import `RouterProvider` from `react-router`?");let{basename:l}=CS("useViewTransitionState"),n=$o(e,{relative:t});if(!i.isTransitioning)return!1;let o=zr(i.currentLocation.pathname,l)||i.currentLocation.pathname,s=zr(i.nextLocation.pathname,l)||i.nextLocation.pathname;return Ds(n.pathname,s)!=null||Ds(n.pathname,o)!=null}var Wa=class{constructor(){this.listeners=new Set,this.subscribe=this.subscribe.bind(this)}subscribe(e){return this.listeners.add(e),this.onSubscribe(),()=>{this.listeners.delete(e),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}onSubscribe(){}onUnsubscribe(){}},r6={setTimeout:(e,t)=>setTimeout(e,t),clearTimeout:e=>clearTimeout(e),setInterval:(e,t)=>setInterval(e,t),clearInterval:e=>clearInterval(e)},i6=class{#e=r6;#t=!1;setTimeoutProvider(e){this.#e=e}setTimeout(e,t){return this.#e.setTimeout(e,t)}clearTimeout(e){this.#e.clearTimeout(e)}setInterval(e,t){return this.#e.setInterval(e,t)}clearInterval(e){this.#e.clearInterval(e)}},Ti=new i6;function a6(e){setTimeout(e,0)}var Ai=typeof window>"u"||"Deno"in globalThis;function qt(){}function l6(e,t){return typeof e=="function"?e(t):e}function Zh(e){return typeof e=="number"&&e>=0&&e!==1/0}function DS(e,t){return Math.max(e+(t||0)-Date.now(),0)}function li(e,t){return typeof e=="function"?e(t):e}function jn(e,t){return typeof e=="function"?e(t):e}function Qx(e,t){const{type:i="all",exact:l,fetchStatus:n,predicate:o,queryKey:s,stale:f}=e;if(s){if(l){if(t.queryHash!==yp(s,t.options))return!1}else if(!mo(t.queryKey,s))return!1}if(i!=="all"){const m=t.isActive();if(i==="active"&&!m||i==="inactive"&&m)return!1}return!(typeof f=="boolean"&&t.isStale()!==f||n&&n!==t.state.fetchStatus||o&&!o(t))}function Kx(e,t){const{exact:i,status:l,predicate:n,mutationKey:o}=e;if(o){if(!t.options.mutationKey)return!1;if(i){if(Ri(t.options.mutationKey)!==Ri(o))return!1}else if(!mo(t.options.mutationKey,o))return!1}return!(l&&t.state.status!==l||n&&!n(t))}function yp(e,t){return(t?.queryKeyHashFn||Ri)(e)}function Ri(e){return JSON.stringify(e,(t,i)=>qh(i)?Object.keys(i).sort().reduce((l,n)=>(l[n]=i[n],l),{}):i)}function mo(e,t){return e===t?!0:typeof e!=typeof t?!1:e&&t&&typeof e=="object"&&typeof t=="object"?Object.keys(t).every(i=>mo(e[i],t[i])):!1}var o6=Object.prototype.hasOwnProperty;function AS(e,t){if(e===t)return e;const i=Wx(e)&&Wx(t);if(!i&&!(qh(e)&&qh(t)))return t;const n=(i?e:Object.keys(e)).length,o=i?t:Object.keys(t),s=o.length,f=i?new Array(s):{};let m=0;for(let d=0;d<s;d++){const p=i?d:o[d],v=e[p],b=t[p];if(v===b){f[p]=v,(i?d<n:o6.call(e,p))&&m++;continue}if(v===null||b===null||typeof v!="object"||typeof b!="object"){f[p]=b;continue}const x=AS(v,b);f[p]=x,x===v&&m++}return n===s&&m===n?e:f}function As(e,t){if(!t||Object.keys(e).length!==Object.keys(t).length)return!1;for(const i in e)if(e[i]!==t[i])return!1;return!0}function Wx(e){return Array.isArray(e)&&e.length===Object.keys(e).length}function qh(e){if(!e_(e))return!1;const t=e.constructor;if(t===void 0)return!0;const i=t.prototype;return!(!e_(i)||!i.hasOwnProperty("isPrototypeOf")||Object.getPrototypeOf(e)!==Object.prototype)}function e_(e){return Object.prototype.toString.call(e)==="[object Object]"}function u6(e){return new Promise(t=>{Ti.setTimeout(t,e)})}function Fh(e,t,i){return typeof i.structuralSharing=="function"?i.structuralSharing(e,t):i.structuralSharing!==!1?AS(e,t):t}function s6(e,t,i=0){const l=[...e,t];return i&&l.length>i?l.slice(1):l}function c6(e,t,i=0){const l=[t,...e];return i&&l.length>i?l.slice(0,-1):l}var bp=Symbol();function RS(e,t){return!e.queryFn&&t?.initialPromise?()=>t.initialPromise:!e.queryFn||e.queryFn===bp?()=>Promise.reject(new Error(`Missing queryFn: '${e.queryHash}'`)):e.queryFn}function xp(e,t){return typeof e=="function"?e(...t):!!e}function f6(e,t,i){let l=!1,n;return Object.defineProperty(e,"signal",{enumerable:!0,get:()=>(n??=t(),l||(l=!0,n.aborted?i():n.addEventListener("abort",i,{once:!0})),n)}),e}var d6=class extends Wa{#e;#t;#n;constructor(){super(),this.#n=e=>{if(!Ai&&window.addEventListener){const t=()=>e();return window.addEventListener("visibilitychange",t,!1),()=>{window.removeEventListener("visibilitychange",t)}}}}onSubscribe(){this.#t||this.setEventListener(this.#n)}onUnsubscribe(){this.hasListeners()||(this.#t?.(),this.#t=void 0)}setEventListener(e){this.#n=e,this.#t?.(),this.#t=e(t=>{typeof t=="boolean"?this.setFocused(t):this.onFocus()})}setFocused(e){this.#e!==e&&(this.#e=e,this.onFocus())}onFocus(){const e=this.isFocused();this.listeners.forEach(t=>{t(e)})}isFocused(){return typeof this.#e=="boolean"?this.#e:globalThis.document?.visibilityState!=="hidden"}},_p=new d6;function Bh(){let e,t;const i=new Promise((n,o)=>{e=n,t=o});i.status="pending",i.catch(()=>{});function l(n){Object.assign(i,n),delete i.resolve,delete i.reject}return i.resolve=n=>{l({status:"fulfilled",value:n}),e(n)},i.reject=n=>{l({status:"rejected",reason:n}),t(n)},i}var m6=a6;function h6(){let e=[],t=0,i=f=>{f()},l=f=>{f()},n=m6;const o=f=>{t?e.push(f):n(()=>{i(f)})},s=()=>{const f=e;e=[],f.length&&n(()=>{l(()=>{f.forEach(m=>{i(m)})})})};return{batch:f=>{let m;t++;try{m=f()}finally{t--,t||s()}return m},batchCalls:f=>(...m)=>{o(()=>{f(...m)})},schedule:o,setNotifyFunction:f=>{i=f},setBatchNotifyFunction:f=>{l=f},setScheduler:f=>{n=f}}}var wt=h6(),p6=class extends Wa{#e=!0;#t;#n;constructor(){super(),this.#n=e=>{if(!Ai&&window.addEventListener){const t=()=>e(!0),i=()=>e(!1);return window.addEventListener("online",t,!1),window.addEventListener("offline",i,!1),()=>{window.removeEventListener("online",t),window.removeEventListener("offline",i)}}}}onSubscribe(){this.#t||this.setEventListener(this.#n)}onUnsubscribe(){this.hasListeners()||(this.#t?.(),this.#t=void 0)}setEventListener(e){this.#n=e,this.#t?.(),this.#t=e(this.setOnline.bind(this))}setOnline(e){this.#e!==e&&(this.#e=e,this.listeners.forEach(i=>{i(e)}))}isOnline(){return this.#e}},Rs=new p6;function g6(e){return Math.min(1e3*2**e,3e4)}function IS(e){return(e??"online")==="online"?Rs.isOnline():!0}var Hh=class extends Error{constructor(e){super("CancelledError"),this.revert=e?.revert,this.silent=e?.silent}};function US(e){let t=!1,i=0,l;const n=Bh(),o=()=>n.status!=="pending",s=w=>{if(!o()){const j=new Hh(w);b(j),e.onCancel?.(j)}},f=()=>{t=!0},m=()=>{t=!1},d=()=>_p.isFocused()&&(e.networkMode==="always"||Rs.isOnline())&&e.canRun(),p=()=>IS(e.networkMode)&&e.canRun(),v=w=>{o()||(l?.(),n.resolve(w))},b=w=>{o()||(l?.(),n.reject(w))},x=()=>new Promise(w=>{l=j=>{(o()||d())&&w(j)},e.onPause?.()}).then(()=>{l=void 0,o()||e.onContinue?.()}),S=()=>{if(o())return;let w;const j=i===0?e.initialPromise:void 0;try{w=j??e.fn()}catch(E){w=Promise.reject(E)}Promise.resolve(w).then(v).catch(E=>{if(o())return;const O=e.retry??(Ai?0:3),N=e.retryDelay??g6,G=typeof N=="function"?N(i,E):N,J=O===!0||typeof O=="number"&&i<O||typeof O=="function"&&O(i,E);if(t||!J){b(E);return}i++,e.onFail?.(i,E),u6(G).then(()=>d()?void 0:x()).then(()=>{t?b(E):S()})})};return{promise:n,status:()=>n.status,cancel:s,continue:()=>(l?.(),n),cancelRetry:f,continueRetry:m,canStart:p,start:()=>(p()?S():x().then(S),n)}}var LS=class{#e;destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),Zh(this.gcTime)&&(this.#e=Ti.setTimeout(()=>{this.optionalRemove()},this.gcTime))}updateGcTime(e){this.gcTime=Math.max(this.gcTime||0,e??(Ai?1/0:300*1e3))}clearGcTimeout(){this.#e&&(Ti.clearTimeout(this.#e),this.#e=void 0)}},v6=class extends LS{#e;#t;#n;#i;#r;#l;#o;constructor(e){super(),this.#o=!1,this.#l=e.defaultOptions,this.setOptions(e.options),this.observers=[],this.#i=e.client,this.#n=this.#i.getQueryCache(),this.queryKey=e.queryKey,this.queryHash=e.queryHash,this.#e=n_(this.options),this.state=e.state??this.#e,this.scheduleGc()}get meta(){return this.options.meta}get promise(){return this.#r?.promise}setOptions(e){if(this.options={...this.#l,...e},this.updateGcTime(this.options.gcTime),this.state&&this.state.data===void 0){const t=n_(this.options);t.data!==void 0&&(this.setState(t_(t.data,t.dataUpdatedAt)),this.#e=t)}}optionalRemove(){!this.observers.length&&this.state.fetchStatus==="idle"&&this.#n.remove(this)}setData(e,t){const i=Fh(this.state.data,e,this.options);return this.#a({data:i,type:"success",dataUpdatedAt:t?.updatedAt,manual:t?.manual}),i}setState(e,t){this.#a({type:"setState",state:e,setStateOptions:t})}cancel(e){const t=this.#r?.promise;return this.#r?.cancel(e),t?t.then(qt).catch(qt):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}reset(){this.destroy(),this.setState(this.#e)}isActive(){return this.observers.some(e=>jn(e.options.enabled,this)!==!1)}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===bp||this.state.dataUpdateCount+this.state.errorUpdateCount===0}isStatic(){return this.getObserversCount()>0?this.observers.some(e=>li(e.options.staleTime,this)==="static"):!1}isStale(){return this.getObserversCount()>0?this.observers.some(e=>e.getCurrentResult().isStale):this.state.data===void 0||this.state.isInvalidated}isStaleByTime(e=0){return this.state.data===void 0?!0:e==="static"?!1:this.state.isInvalidated?!0:!DS(this.state.dataUpdatedAt,e)}onFocus(){this.observers.find(t=>t.shouldFetchOnWindowFocus())?.refetch({cancelRefetch:!1}),this.#r?.continue()}onOnline(){this.observers.find(t=>t.shouldFetchOnReconnect())?.refetch({cancelRefetch:!1}),this.#r?.continue()}addObserver(e){this.observers.includes(e)||(this.observers.push(e),this.clearGcTimeout(),this.#n.notify({type:"observerAdded",query:this,observer:e}))}removeObserver(e){this.observers.includes(e)&&(this.observers=this.observers.filter(t=>t!==e),this.observers.length||(this.#r&&(this.#o?this.#r.cancel({revert:!0}):this.#r.cancelRetry()),this.scheduleGc()),this.#n.notify({type:"observerRemoved",query:this,observer:e}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||this.#a({type:"invalidate"})}async fetch(e,t){if(this.state.fetchStatus!=="idle"&&this.#r?.status()!=="rejected"){if(this.state.data!==void 0&&t?.cancelRefetch)this.cancel({silent:!0});else if(this.#r)return this.#r.continueRetry(),this.#r.promise}if(e&&this.setOptions(e),!this.options.queryFn){const f=this.observers.find(m=>m.options.queryFn);f&&this.setOptions(f.options)}const i=new AbortController,l=f=>{Object.defineProperty(f,"signal",{enumerable:!0,get:()=>(this.#o=!0,i.signal)})},n=()=>{const f=RS(this.options,t),d=(()=>{const p={client:this.#i,queryKey:this.queryKey,meta:this.meta};return l(p),p})();return this.#o=!1,this.options.persister?this.options.persister(f,d,this):f(d)},s=(()=>{const f={fetchOptions:t,options:this.options,queryKey:this.queryKey,client:this.#i,state:this.state,fetchFn:n};return l(f),f})();this.options.behavior?.onFetch(s,this),this.#t=this.state,(this.state.fetchStatus==="idle"||this.state.fetchMeta!==s.fetchOptions?.meta)&&this.#a({type:"fetch",meta:s.fetchOptions?.meta}),this.#r=US({initialPromise:t?.initialPromise,fn:s.fetchFn,onCancel:f=>{f instanceof Hh&&f.revert&&this.setState({...this.#t,fetchStatus:"idle"}),i.abort()},onFail:(f,m)=>{this.#a({type:"failed",failureCount:f,error:m})},onPause:()=>{this.#a({type:"pause"})},onContinue:()=>{this.#a({type:"continue"})},retry:s.options.retry,retryDelay:s.options.retryDelay,networkMode:s.options.networkMode,canRun:()=>!0});try{const f=await this.#r.start();if(f===void 0)throw new Error(`${this.queryHash} data is undefined`);return this.setData(f),this.#n.config.onSuccess?.(f,this),this.#n.config.onSettled?.(f,this.state.error,this),f}catch(f){if(f instanceof Hh){if(f.silent)return this.#r.promise;if(f.revert){if(this.state.data===void 0)throw f;return this.state.data}}throw this.#a({type:"error",error:f}),this.#n.config.onError?.(f,this),this.#n.config.onSettled?.(this.state.data,f,this),f}finally{this.scheduleGc()}}#a(e){const t=i=>{switch(e.type){case"failed":return{...i,fetchFailureCount:e.failureCount,fetchFailureReason:e.error};case"pause":return{...i,fetchStatus:"paused"};case"continue":return{...i,fetchStatus:"fetching"};case"fetch":return{...i,...MS(i.data,this.options),fetchMeta:e.meta??null};case"success":const l={...i,...t_(e.data,e.dataUpdatedAt),dataUpdateCount:i.dataUpdateCount+1,...!e.manual&&{fetchStatus:"idle",fetchFailureCount:0,fetchFailureReason:null}};return this.#t=e.manual?l:void 0,l;case"error":const n=e.error;return{...i,error:n,errorUpdateCount:i.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:i.fetchFailureCount+1,fetchFailureReason:n,fetchStatus:"idle",status:"error",isInvalidated:!0};case"invalidate":return{...i,isInvalidated:!0};case"setState":return{...i,...e.state}}};this.state=t(this.state),wt.batch(()=>{this.observers.forEach(i=>{i.onQueryUpdate()}),this.#n.notify({query:this,type:"updated",action:e})})}};function MS(e,t){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:IS(t.networkMode)?"fetching":"paused",...e===void 0&&{error:null,status:"pending"}}}function t_(e,t){return{data:e,dataUpdatedAt:t??Date.now(),error:null,isInvalidated:!1,status:"success"}}function n_(e){const t=typeof e.initialData=="function"?e.initialData():e.initialData,i=t!==void 0,l=i?typeof e.initialDataUpdatedAt=="function"?e.initialDataUpdatedAt():e.initialDataUpdatedAt:0;return{data:t,dataUpdateCount:0,dataUpdatedAt:i?l??Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null,isInvalidated:!1,status:i?"success":"pending",fetchStatus:"idle"}}var y6=class extends Wa{constructor(e,t){super(),this.options=t,this.#e=e,this.#a=null,this.#o=Bh(),this.bindMethods(),this.setOptions(t)}#e;#t=void 0;#n=void 0;#i=void 0;#r;#l;#o;#a;#p;#d;#m;#s;#c;#u;#h=new Set;bindMethods(){this.refetch=this.refetch.bind(this)}onSubscribe(){this.listeners.size===1&&(this.#t.addObserver(this),r_(this.#t,this.options)?this.#f():this.updateResult(),this.#b())}onUnsubscribe(){this.hasListeners()||this.destroy()}shouldFetchOnReconnect(){return Gh(this.#t,this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return Gh(this.#t,this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=new Set,this.#x(),this.#_(),this.#t.removeObserver(this)}setOptions(e){const t=this.options,i=this.#t;if(this.options=this.#e.defaultQueryOptions(e),this.options.enabled!==void 0&&typeof this.options.enabled!="boolean"&&typeof this.options.enabled!="function"&&typeof jn(this.options.enabled,this.#t)!="boolean")throw new Error("Expected enabled to be a boolean or a callback that returns a boolean");this.#S(),this.#t.setOptions(this.options),t._defaulted&&!As(this.options,t)&&this.#e.getQueryCache().notify({type:"observerOptionsUpdated",query:this.#t,observer:this});const l=this.hasListeners();l&&i_(this.#t,i,this.options,t)&&this.#f(),this.updateResult(),l&&(this.#t!==i||jn(this.options.enabled,this.#t)!==jn(t.enabled,this.#t)||li(this.options.staleTime,this.#t)!==li(t.staleTime,this.#t))&&this.#g();const n=this.#v();l&&(this.#t!==i||jn(this.options.enabled,this.#t)!==jn(t.enabled,this.#t)||n!==this.#u)&&this.#y(n)}getOptimisticResult(e){const t=this.#e.getQueryCache().build(this.#e,e),i=this.createResult(t,e);return x6(this,i)&&(this.#i=i,this.#l=this.options,this.#r=this.#t.state),i}getCurrentResult(){return this.#i}trackResult(e,t){return new Proxy(e,{get:(i,l)=>(this.trackProp(l),t?.(l),l==="promise"&&(this.trackProp("data"),!this.options.experimental_prefetchInRender&&this.#o.status==="pending"&&this.#o.reject(new Error("experimental_prefetchInRender feature flag is not enabled"))),Reflect.get(i,l))})}trackProp(e){this.#h.add(e)}getCurrentQuery(){return this.#t}refetch({...e}={}){return this.fetch({...e})}fetchOptimistic(e){const t=this.#e.defaultQueryOptions(e),i=this.#e.getQueryCache().build(this.#e,t);return i.fetch().then(()=>this.createResult(i,t))}fetch(e){return this.#f({...e,cancelRefetch:e.cancelRefetch??!0}).then(()=>(this.updateResult(),this.#i))}#f(e){this.#S();let t=this.#t.fetch(this.options,e);return e?.throwOnError||(t=t.catch(qt)),t}#g(){this.#x();const e=li(this.options.staleTime,this.#t);if(Ai||this.#i.isStale||!Zh(e))return;const i=DS(this.#i.dataUpdatedAt,e)+1;this.#s=Ti.setTimeout(()=>{this.#i.isStale||this.updateResult()},i)}#v(){return(typeof this.options.refetchInterval=="function"?this.options.refetchInterval(this.#t):this.options.refetchInterval)??!1}#y(e){this.#_(),this.#u=e,!(Ai||jn(this.options.enabled,this.#t)===!1||!Zh(this.#u)||this.#u===0)&&(this.#c=Ti.setInterval(()=>{(this.options.refetchIntervalInBackground||_p.isFocused())&&this.#f()},this.#u))}#b(){this.#g(),this.#y(this.#v())}#x(){this.#s&&(Ti.clearTimeout(this.#s),this.#s=void 0)}#_(){this.#c&&(Ti.clearInterval(this.#c),this.#c=void 0)}createResult(e,t){const i=this.#t,l=this.options,n=this.#i,o=this.#r,s=this.#l,m=e!==i?e.state:this.#n,{state:d}=e;let p={...d},v=!1,b;if(t._optimisticResults){const Q=this.hasListeners(),me=!Q&&r_(e,t),B=Q&&i_(e,i,t,l);(me||B)&&(p={...p,...MS(d.data,e.options)}),t._optimisticResults==="isRestoring"&&(p.fetchStatus="idle")}let{error:x,errorUpdatedAt:S,status:w}=p;b=p.data;let j=!1;if(t.placeholderData!==void 0&&b===void 0&&w==="pending"){let Q;n?.isPlaceholderData&&t.placeholderData===s?.placeholderData?(Q=n.data,j=!0):Q=typeof t.placeholderData=="function"?t.placeholderData(this.#m?.state.data,this.#m):t.placeholderData,Q!==void 0&&(w="success",b=Fh(n?.data,Q,t),v=!0)}if(t.select&&b!==void 0&&!j)if(n&&b===o?.data&&t.select===this.#p)b=this.#d;else try{this.#p=t.select,b=t.select(b),b=Fh(n?.data,b,t),this.#d=b,this.#a=null}catch(Q){this.#a=Q}this.#a&&(x=this.#a,b=this.#d,S=Date.now(),w="error");const E=p.fetchStatus==="fetching",O=w==="pending",N=w==="error",G=O&&E,J=b!==void 0,X={status:w,fetchStatus:p.fetchStatus,isPending:O,isSuccess:w==="success",isError:N,isInitialLoading:G,isLoading:G,data:b,dataUpdatedAt:p.dataUpdatedAt,error:x,errorUpdatedAt:S,failureCount:p.fetchFailureCount,failureReason:p.fetchFailureReason,errorUpdateCount:p.errorUpdateCount,isFetched:p.dataUpdateCount>0||p.errorUpdateCount>0,isFetchedAfterMount:p.dataUpdateCount>m.dataUpdateCount||p.errorUpdateCount>m.errorUpdateCount,isFetching:E,isRefetching:E&&!O,isLoadingError:N&&!J,isPaused:p.fetchStatus==="paused",isPlaceholderData:v,isRefetchError:N&&J,isStale:Sp(e,t),refetch:this.refetch,promise:this.#o,isEnabled:jn(t.enabled,e)!==!1};if(this.options.experimental_prefetchInRender){const Q=ue=>{X.status==="error"?ue.reject(X.error):X.data!==void 0&&ue.resolve(X.data)},me=()=>{const ue=this.#o=X.promise=Bh();Q(ue)},B=this.#o;switch(B.status){case"pending":e.queryHash===i.queryHash&&Q(B);break;case"fulfilled":(X.status==="error"||X.data!==B.value)&&me();break;case"rejected":(X.status!=="error"||X.error!==B.reason)&&me();break}}return X}updateResult(){const e=this.#i,t=this.createResult(this.#t,this.options);if(this.#r=this.#t.state,this.#l=this.options,this.#r.data!==void 0&&(this.#m=this.#t),As(t,e))return;this.#i=t;const i=()=>{if(!e)return!0;const{notifyOnChangeProps:l}=this.options,n=typeof l=="function"?l():l;if(n==="all"||!n&&!this.#h.size)return!0;const o=new Set(n??this.#h);return this.options.throwOnError&&o.add("error"),Object.keys(this.#i).some(s=>{const f=s;return this.#i[f]!==e[f]&&o.has(f)})};this.#k({listeners:i()})}#S(){const e=this.#e.getQueryCache().build(this.#e,this.options);if(e===this.#t)return;const t=this.#t;this.#t=e,this.#n=e.state,this.hasListeners()&&(t?.removeObserver(this),e.addObserver(this))}onQueryUpdate(){this.updateResult(),this.hasListeners()&&this.#b()}#k(e){wt.batch(()=>{e.listeners&&this.listeners.forEach(t=>{t(this.#i)}),this.#e.getQueryCache().notify({query:this.#t,type:"observerResultsUpdated"})})}};function b6(e,t){return jn(t.enabled,e)!==!1&&e.state.data===void 0&&!(e.state.status==="error"&&t.retryOnMount===!1)}function r_(e,t){return b6(e,t)||e.state.data!==void 0&&Gh(e,t,t.refetchOnMount)}function Gh(e,t,i){if(jn(t.enabled,e)!==!1&&li(t.staleTime,e)!=="static"){const l=typeof i=="function"?i(e):i;return l==="always"||l!==!1&&Sp(e,t)}return!1}function i_(e,t,i,l){return(e!==t||jn(l.enabled,e)===!1)&&(!i.suspense||e.state.status!=="error")&&Sp(e,i)}function Sp(e,t){return jn(t.enabled,e)!==!1&&e.isStaleByTime(li(t.staleTime,e))}function x6(e,t){return!As(e.getCurrentResult(),t)}function a_(e){return{onFetch:(t,i)=>{const l=t.options,n=t.fetchOptions?.meta?.fetchMore?.direction,o=t.state.data?.pages||[],s=t.state.data?.pageParams||[];let f={pages:[],pageParams:[]},m=0;const d=async()=>{let p=!1;const v=S=>{f6(S,()=>t.signal,()=>p=!0)},b=RS(t.options,t.fetchOptions),x=async(S,w,j)=>{if(p)return Promise.reject();if(w==null&&S.pages.length)return Promise.resolve(S);const O=(()=>{const R={client:t.client,queryKey:t.queryKey,pageParam:w,direction:j?"backward":"forward",meta:t.options.meta};return v(R),R})(),N=await b(O),{maxPages:G}=t.options,J=j?c6:s6;return{pages:J(S.pages,N,G),pageParams:J(S.pageParams,w,G)}};if(n&&o.length){const S=n==="backward",w=S?_6:l_,j={pages:o,pageParams:s},E=w(l,j);f=await x(j,E,S)}else{const S=e??o.length;do{const w=m===0?s[0]??l.initialPageParam:l_(l,f);if(m>0&&w==null)break;f=await x(f,w),m++}while(m<S)}return f};t.options.persister?t.fetchFn=()=>t.options.persister?.(d,{client:t.client,queryKey:t.queryKey,meta:t.options.meta,signal:t.signal},i):t.fetchFn=d}}}function l_(e,{pages:t,pageParams:i}){const l=t.length-1;return t.length>0?e.getNextPageParam(t[l],t,i[l],i):void 0}function _6(e,{pages:t,pageParams:i}){return t.length>0?e.getPreviousPageParam?.(t[0],t,i[0],i):void 0}var S6=class extends LS{#e;#t;#n;#i;constructor(e){super(),this.#e=e.client,this.mutationId=e.mutationId,this.#n=e.mutationCache,this.#t=[],this.state=e.state||PS(),this.setOptions(e.options),this.scheduleGc()}setOptions(e){this.options=e,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(e){this.#t.includes(e)||(this.#t.push(e),this.clearGcTimeout(),this.#n.notify({type:"observerAdded",mutation:this,observer:e}))}removeObserver(e){this.#t=this.#t.filter(t=>t!==e),this.scheduleGc(),this.#n.notify({type:"observerRemoved",mutation:this,observer:e})}optionalRemove(){this.#t.length||(this.state.status==="pending"?this.scheduleGc():this.#n.remove(this))}continue(){return this.#i?.continue()??this.execute(this.state.variables)}async execute(e){const t=()=>{this.#r({type:"continue"})},i={client:this.#e,meta:this.options.meta,mutationKey:this.options.mutationKey};this.#i=US({fn:()=>this.options.mutationFn?this.options.mutationFn(e,i):Promise.reject(new Error("No mutationFn found")),onFail:(o,s)=>{this.#r({type:"failed",failureCount:o,error:s})},onPause:()=>{this.#r({type:"pause"})},onContinue:t,retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>this.#n.canRun(this)});const l=this.state.status==="pending",n=!this.#i.canStart();try{if(l)t();else{this.#r({type:"pending",variables:e,isPaused:n}),await this.#n.config.onMutate?.(e,this,i);const s=await this.options.onMutate?.(e,i);s!==this.state.context&&this.#r({type:"pending",context:s,variables:e,isPaused:n})}const o=await this.#i.start();return await this.#n.config.onSuccess?.(o,e,this.state.context,this,i),await this.options.onSuccess?.(o,e,this.state.context,i),await this.#n.config.onSettled?.(o,null,this.state.variables,this.state.context,this,i),await this.options.onSettled?.(o,null,e,this.state.context,i),this.#r({type:"success",data:o}),o}catch(o){try{await this.#n.config.onError?.(o,e,this.state.context,this,i)}catch(s){Promise.reject(s)}try{await this.options.onError?.(o,e,this.state.context,i)}catch(s){Promise.reject(s)}try{await this.#n.config.onSettled?.(void 0,o,this.state.variables,this.state.context,this,i)}catch(s){Promise.reject(s)}try{await this.options.onSettled?.(void 0,o,e,this.state.context,i)}catch(s){Promise.reject(s)}throw this.#r({type:"error",error:o}),o}finally{this.#n.runNext(this)}}#r(e){const t=i=>{switch(e.type){case"failed":return{...i,failureCount:e.failureCount,failureReason:e.error};case"pause":return{...i,isPaused:!0};case"continue":return{...i,isPaused:!1};case"pending":return{...i,context:e.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:e.isPaused,status:"pending",variables:e.variables,submittedAt:Date.now()};case"success":return{...i,data:e.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1};case"error":return{...i,data:void 0,error:e.error,failureCount:i.failureCount+1,failureReason:e.error,isPaused:!1,status:"error"}}};this.state=t(this.state),wt.batch(()=>{this.#t.forEach(i=>{i.onMutationUpdate(e)}),this.#n.notify({mutation:this,type:"updated",action:e})})}};function PS(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0}}var k6=class extends Wa{constructor(e={}){super(),this.config=e,this.#e=new Set,this.#t=new Map,this.#n=0}#e;#t;#n;build(e,t,i){const l=new S6({client:e,mutationCache:this,mutationId:++this.#n,options:e.defaultMutationOptions(t),state:i});return this.add(l),l}add(e){this.#e.add(e);const t=xs(e);if(typeof t=="string"){const i=this.#t.get(t);i?i.push(e):this.#t.set(t,[e])}this.notify({type:"added",mutation:e})}remove(e){if(this.#e.delete(e)){const t=xs(e);if(typeof t=="string"){const i=this.#t.get(t);if(i)if(i.length>1){const l=i.indexOf(e);l!==-1&&i.splice(l,1)}else i[0]===e&&this.#t.delete(t)}}this.notify({type:"removed",mutation:e})}canRun(e){const t=xs(e);if(typeof t=="string"){const l=this.#t.get(t)?.find(n=>n.state.status==="pending");return!l||l===e}else return!0}runNext(e){const t=xs(e);return typeof t=="string"?this.#t.get(t)?.find(l=>l!==e&&l.state.isPaused)?.continue()??Promise.resolve():Promise.resolve()}clear(){wt.batch(()=>{this.#e.forEach(e=>{this.notify({type:"removed",mutation:e})}),this.#e.clear(),this.#t.clear()})}getAll(){return Array.from(this.#e)}find(e){const t={exact:!0,...e};return this.getAll().find(i=>Kx(t,i))}findAll(e={}){return this.getAll().filter(t=>Kx(e,t))}notify(e){wt.batch(()=>{this.listeners.forEach(t=>{t(e)})})}resumePausedMutations(){const e=this.getAll().filter(t=>t.state.isPaused);return wt.batch(()=>Promise.all(e.map(t=>t.continue().catch(qt))))}};function xs(e){return e.options.scope?.id}var w6=class extends Wa{#e;#t=void 0;#n;#i;constructor(t,i){super(),this.#e=t,this.setOptions(i),this.bindMethods(),this.#r()}bindMethods(){this.mutate=this.mutate.bind(this),this.reset=this.reset.bind(this)}setOptions(t){const i=this.options;this.options=this.#e.defaultMutationOptions(t),As(this.options,i)||this.#e.getMutationCache().notify({type:"observerOptionsUpdated",mutation:this.#n,observer:this}),i?.mutationKey&&this.options.mutationKey&&Ri(i.mutationKey)!==Ri(this.options.mutationKey)?this.reset():this.#n?.state.status==="pending"&&this.#n.setOptions(this.options)}onUnsubscribe(){this.hasListeners()||this.#n?.removeObserver(this)}onMutationUpdate(t){this.#r(),this.#l(t)}getCurrentResult(){return this.#t}reset(){this.#n?.removeObserver(this),this.#n=void 0,this.#r(),this.#l()}mutate(t,i){return this.#i=i,this.#n?.removeObserver(this),this.#n=this.#e.getMutationCache().build(this.#e,this.options),this.#n.addObserver(this),this.#n.execute(t)}#r(){const t=this.#n?.state??PS();this.#t={...t,isPending:t.status==="pending",isSuccess:t.status==="success",isError:t.status==="error",isIdle:t.status==="idle",mutate:this.mutate,reset:this.reset}}#l(t){wt.batch(()=>{if(this.#i&&this.hasListeners()){const i=this.#t.variables,l=this.#t.context,n={client:this.#e,meta:this.options.meta,mutationKey:this.options.mutationKey};if(t?.type==="success"){try{this.#i.onSuccess?.(t.data,i,l,n)}catch(o){Promise.reject(o)}try{this.#i.onSettled?.(t.data,null,i,l,n)}catch(o){Promise.reject(o)}}else if(t?.type==="error"){try{this.#i.onError?.(t.error,i,l,n)}catch(o){Promise.reject(o)}try{this.#i.onSettled?.(void 0,t.error,i,l,n)}catch(o){Promise.reject(o)}}}this.listeners.forEach(i=>{i(this.#t)})})}},$6=class extends Wa{constructor(e={}){super(),this.config=e,this.#e=new Map}#e;build(e,t,i){const l=t.queryKey,n=t.queryHash??yp(l,t);let o=this.get(n);return o||(o=new v6({client:e,queryKey:l,queryHash:n,options:e.defaultQueryOptions(t),state:i,defaultOptions:e.getQueryDefaults(l)}),this.add(o)),o}add(e){this.#e.has(e.queryHash)||(this.#e.set(e.queryHash,e),this.notify({type:"added",query:e}))}remove(e){const t=this.#e.get(e.queryHash);t&&(e.destroy(),t===e&&this.#e.delete(e.queryHash),this.notify({type:"removed",query:e}))}clear(){wt.batch(()=>{this.getAll().forEach(e=>{this.remove(e)})})}get(e){return this.#e.get(e)}getAll(){return[...this.#e.values()]}find(e){const t={exact:!0,...e};return this.getAll().find(i=>Qx(t,i))}findAll(e={}){const t=this.getAll();return Object.keys(e).length>0?t.filter(i=>Qx(e,i)):t}notify(e){wt.batch(()=>{this.listeners.forEach(t=>{t(e)})})}onFocus(){wt.batch(()=>{this.getAll().forEach(e=>{e.onFocus()})})}onOnline(){wt.batch(()=>{this.getAll().forEach(e=>{e.onOnline()})})}},E6=class{#e;#t;#n;#i;#r;#l;#o;#a;constructor(e={}){this.#e=e.queryCache||new $6,this.#t=e.mutationCache||new k6,this.#n=e.defaultOptions||{},this.#i=new Map,this.#r=new Map,this.#l=0}mount(){this.#l++,this.#l===1&&(this.#o=_p.subscribe(async e=>{e&&(await this.resumePausedMutations(),this.#e.onFocus())}),this.#a=Rs.subscribe(async e=>{e&&(await this.resumePausedMutations(),this.#e.onOnline())}))}unmount(){this.#l--,this.#l===0&&(this.#o?.(),this.#o=void 0,this.#a?.(),this.#a=void 0)}isFetching(e){return this.#e.findAll({...e,fetchStatus:"fetching"}).length}isMutating(e){return this.#t.findAll({...e,status:"pending"}).length}getQueryData(e){const t=this.defaultQueryOptions({queryKey:e});return this.#e.get(t.queryHash)?.state.data}ensureQueryData(e){const t=this.defaultQueryOptions(e),i=this.#e.build(this,t),l=i.state.data;return l===void 0?this.fetchQuery(e):(e.revalidateIfStale&&i.isStaleByTime(li(t.staleTime,i))&&this.prefetchQuery(t),Promise.resolve(l))}getQueriesData(e){return this.#e.findAll(e).map(({queryKey:t,state:i})=>{const l=i.data;return[t,l]})}setQueryData(e,t,i){const l=this.defaultQueryOptions({queryKey:e}),o=this.#e.get(l.queryHash)?.state.data,s=l6(t,o);if(s!==void 0)return this.#e.build(this,l).setData(s,{...i,manual:!0})}setQueriesData(e,t,i){return wt.batch(()=>this.#e.findAll(e).map(({queryKey:l})=>[l,this.setQueryData(l,t,i)]))}getQueryState(e){const t=this.defaultQueryOptions({queryKey:e});return this.#e.get(t.queryHash)?.state}removeQueries(e){const t=this.#e;wt.batch(()=>{t.findAll(e).forEach(i=>{t.remove(i)})})}resetQueries(e,t){const i=this.#e;return wt.batch(()=>(i.findAll(e).forEach(l=>{l.reset()}),this.refetchQueries({type:"active",...e},t)))}cancelQueries(e,t={}){const i={revert:!0,...t},l=wt.batch(()=>this.#e.findAll(e).map(n=>n.cancel(i)));return Promise.all(l).then(qt).catch(qt)}invalidateQueries(e,t={}){return wt.batch(()=>(this.#e.findAll(e).forEach(i=>{i.invalidate()}),e?.refetchType==="none"?Promise.resolve():this.refetchQueries({...e,type:e?.refetchType??e?.type??"active"},t)))}refetchQueries(e,t={}){const i={...t,cancelRefetch:t.cancelRefetch??!0},l=wt.batch(()=>this.#e.findAll(e).filter(n=>!n.isDisabled()&&!n.isStatic()).map(n=>{let o=n.fetch(void 0,i);return i.throwOnError||(o=o.catch(qt)),n.state.fetchStatus==="paused"?Promise.resolve():o}));return Promise.all(l).then(qt)}fetchQuery(e){const t=this.defaultQueryOptions(e);t.retry===void 0&&(t.retry=!1);const i=this.#e.build(this,t);return i.isStaleByTime(li(t.staleTime,i))?i.fetch(t):Promise.resolve(i.state.data)}prefetchQuery(e){return this.fetchQuery(e).then(qt).catch(qt)}fetchInfiniteQuery(e){return e.behavior=a_(e.pages),this.fetchQuery(e)}prefetchInfiniteQuery(e){return this.fetchInfiniteQuery(e).then(qt).catch(qt)}ensureInfiniteQueryData(e){return e.behavior=a_(e.pages),this.ensureQueryData(e)}resumePausedMutations(){return Rs.isOnline()?this.#t.resumePausedMutations():Promise.resolve()}getQueryCache(){return this.#e}getMutationCache(){return this.#t}getDefaultOptions(){return this.#n}setDefaultOptions(e){this.#n=e}setQueryDefaults(e,t){this.#i.set(Ri(e),{queryKey:e,defaultOptions:t})}getQueryDefaults(e){const t=[...this.#i.values()],i={};return t.forEach(l=>{mo(e,l.queryKey)&&Object.assign(i,l.defaultOptions)}),i}setMutationDefaults(e,t){this.#r.set(Ri(e),{mutationKey:e,defaultOptions:t})}getMutationDefaults(e){const t=[...this.#r.values()],i={};return t.forEach(l=>{mo(e,l.mutationKey)&&Object.assign(i,l.defaultOptions)}),i}defaultQueryOptions(e){if(e._defaulted)return e;const t={...this.#n.queries,...this.getQueryDefaults(e.queryKey),...e,_defaulted:!0};return t.queryHash||(t.queryHash=yp(t.queryKey,t)),t.refetchOnReconnect===void 0&&(t.refetchOnReconnect=t.networkMode!=="always"),t.throwOnError===void 0&&(t.throwOnError=!!t.suspense),!t.networkMode&&t.persister&&(t.networkMode="offlineFirst"),t.queryFn===bp&&(t.enabled=!1),t}defaultMutationOptions(e){return e?._defaulted?e:{...this.#n.mutations,...e?.mutationKey&&this.getMutationDefaults(e.mutationKey),...e,_defaulted:!0}}clear(){this.#e.clear(),this.#t.clear()}},ZS=C.createContext(void 0),qn=e=>{const t=C.useContext(ZS);if(!t)throw new Error("No QueryClient set, use QueryClientProvider to set one");return t},j6=({client:e,children:t})=>(C.useEffect(()=>(e.mount(),()=>{e.unmount()}),[e]),y.jsx(ZS.Provider,{value:e,children:t})),qS=C.createContext(!1),z6=()=>C.useContext(qS);qS.Provider;function N6(){let e=!1;return{clearReset:()=>{e=!1},reset:()=>{e=!0},isReset:()=>e}}var O6=C.createContext(N6()),T6=()=>C.useContext(O6),C6=(e,t,i)=>{const l=i?.state.error&&typeof e.throwOnError=="function"?xp(e.throwOnError,[i.state.error,i]):e.throwOnError;(e.suspense||e.experimental_prefetchInRender||l)&&(t.isReset()||(e.retryOnMount=!1))},D6=e=>{C.useEffect(()=>{e.clearReset()},[e])},A6=({result:e,errorResetBoundary:t,throwOnError:i,query:l,suspense:n})=>e.isError&&!t.isReset()&&!e.isFetching&&l&&(n&&e.data===void 0||xp(i,[e.error,l])),R6=e=>{if(e.suspense){const i=n=>n==="static"?n:Math.max(n??1e3,1e3),l=e.staleTime;e.staleTime=typeof l=="function"?(...n)=>i(l(...n)):i(l),typeof e.gcTime=="number"&&(e.gcTime=Math.max(e.gcTime,1e3))}},I6=(e,t)=>e.isLoading&&e.isFetching&&!t,U6=(e,t)=>e?.suspense&&t.isPending,o_=(e,t,i)=>t.fetchOptimistic(e).catch(()=>{i.clearReset()});function L6(e,t,i){const l=z6(),n=T6(),o=qn(),s=o.defaultQueryOptions(e);o.getDefaultOptions().queries?._experimental_beforeQuery?.(s);const f=o.getQueryCache().get(s.queryHash);s._optimisticResults=l?"isRestoring":"optimistic",R6(s),C6(s,n,f),D6(n);const m=!o.getQueryCache().get(s.queryHash),[d]=C.useState(()=>new t(o,s)),p=d.getOptimisticResult(s),v=!l&&e.subscribed!==!1;if(C.useSyncExternalStore(C.useCallback(b=>{const x=v?d.subscribe(wt.batchCalls(b)):qt;return d.updateResult(),x},[d,v]),()=>d.getCurrentResult(),()=>d.getCurrentResult()),C.useEffect(()=>{d.setOptions(s)},[s,d]),U6(s,p))throw o_(s,d,n);if(A6({result:p,errorResetBoundary:n,throwOnError:s.throwOnError,query:f,suspense:s.suspense}))throw p.error;return o.getDefaultOptions().queries?._experimental_afterQuery?.(s,p),s.experimental_prefetchInRender&&!Ai&&I6(p,l)&&(m?o_(s,d,n):f?.promise)?.catch(qt).finally(()=>{d.updateResult()}),s.notifyOnChangeProps?p:d.trackResult(p)}function dn(e,t){return L6(e,y6)}function Cn(e,t){const i=qn(),[l]=C.useState(()=>new w6(i,e));C.useEffect(()=>{l.setOptions(e)},[l,e]);const n=C.useSyncExternalStore(C.useCallback(s=>l.subscribe(wt.batchCalls(s)),[l]),()=>l.getCurrentResult(),()=>l.getCurrentResult()),o=C.useCallback((s,f)=>{l.mutate(s,f).catch(qt)},[l]);if(n.error&&xp(l.options.throwOnError,[n.error]))throw n.error;return{...n,mutate:o,mutateAsync:n.mutate}}const M6=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),P6=e=>e.replace(/^([A-Z])|[\s-_]+(\w)/g,(t,i,l)=>l?l.toUpperCase():i.toLowerCase()),u_=e=>{const t=P6(e);return t.charAt(0).toUpperCase()+t.slice(1)},FS=(...e)=>e.filter((t,i,l)=>!!t&&t.trim()!==""&&l.indexOf(t)===i).join(" ").trim(),Z6=e=>{for(const t in e)if(t.startsWith("aria-")||t==="role"||t==="title")return!0};var q6={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};const F6=C.forwardRef(({color:e="currentColor",size:t=24,strokeWidth:i=2,absoluteStrokeWidth:l,className:n="",children:o,iconNode:s,...f},m)=>C.createElement("svg",{ref:m,...q6,width:t,height:t,stroke:e,strokeWidth:l?Number(i)*24/Number(t):i,className:FS("lucide",n),...!o&&!Z6(f)&&{"aria-hidden":"true"},...f},[...s.map(([d,p])=>C.createElement(d,p)),...Array.isArray(o)?o:[o]]));const gt=(e,t)=>{const i=C.forwardRef(({className:l,...n},o)=>C.createElement(F6,{ref:o,iconNode:t,className:FS(`lucide-${M6(u_(e))}`,`lucide-${e}`,l),...n}));return i.displayName=u_(e),i};const B6=[["path",{d:"M3 3v16a2 2 0 0 0 2 2h16",key:"c24i48"}],["path",{d:"M18 17V9",key:"2bz60n"}],["path",{d:"M13 17V5",key:"1frdt8"}],["path",{d:"M8 17v-3",key:"17ska0"}]],H6=gt("chart-column",B6);const G6=[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]],BS=gt("check",G6);const V6=[["rect",{width:"8",height:"4",x:"8",y:"2",rx:"1",ry:"1",key:"tgr4d6"}],["path",{d:"M16 4h2a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2V6a2 2 0 0 1 2-2h2",key:"116196"}],["path",{d:"M12 11h4",key:"1jrz19"}],["path",{d:"M12 16h4",key:"n85exb"}],["path",{d:"M8 11h.01",key:"1dfujw"}],["path",{d:"M8 16h.01",key:"18s6g9"}]],HS=gt("clipboard-list",V6);const Y6=[["path",{d:"M12 15V3",key:"m9g1x1"}],["path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4",key:"ih7n3h"}],["path",{d:"m7 10 5 5 5-5",key:"brsn70"}]],J6=gt("download",Y6);const X6=[["path",{d:"M2 9.5a5.5 5.5 0 0 1 9.591-3.676.56.56 0 0 0 .818 0A5.49 5.49 0 0 1 22 9.5c0 2.29-1.5 4-3 5.5l-5.492 5.313a2 2 0 0 1-3 .019L5 15c-1.5-1.5-3-3.2-3-5.5",key:"mvr1a0"}]],Vh=gt("heart",X6);const Q6=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 16v-4",key:"1dtifu"}],["path",{d:"M12 8h.01",key:"e9boi3"}]],K6=gt("info",Q6);const W6=[["path",{d:"m15.5 7.5 2.3 2.3a1 1 0 0 0 1.4 0l2.1-2.1a1 1 0 0 0 0-1.4L19 4",key:"g0fldk"}],["path",{d:"m21 2-9.6 9.6",key:"1j0ho8"}],["circle",{cx:"7.5",cy:"15.5",r:"5.5",key:"yqb3hr"}]],kp=gt("key",W6);const eC=[["path",{d:"m16 17 5-5-5-5",key:"1bji2h"}],["path",{d:"M21 12H9",key:"dn1m92"}],["path",{d:"M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4",key:"1uf3rs"}]],tC=gt("log-out",eC);const nC=[["path",{d:"m22 7-8.991 5.727a2 2 0 0 1-2.009 0L2 7",key:"132q7q"}],["rect",{x:"2",y:"4",width:"20",height:"16",rx:"2",key:"izxlao"}]],rC=gt("mail",nC);const iC=[["path",{d:"M12 3v6",key:"1holv5"}],["path",{d:"M16.76 3a2 2 0 0 1 1.8 1.1l2.23 4.479a2 2 0 0 1 .21.891V19a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V9.472a2 2 0 0 1 .211-.894L5.45 4.1A2 2 0 0 1 7.24 3z",key:"187q7i"}],["path",{d:"M3.054 9.013h17.893",key:"grwhos"}]],aC=gt("package-2",iC);const lC=[["path",{d:"M11 21.73a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16V8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.73z",key:"1a0edw"}],["path",{d:"M12 22V12",key:"d0xqtd"}],["polyline",{points:"3.29 7 12 12 20.71 7",key:"ousv84"}],["path",{d:"m7.5 4.27 9 5.15",key:"1c824w"}]],Ii=gt("package",lC);const oC=[["path",{d:"M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z",key:"1a8usu"}]],uC=gt("pen",oC);const sC=[["path",{d:"M15.2 3a2 2 0 0 1 1.4.6l3.8 3.8a2 2 0 0 1 .6 1.4V19a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2z",key:"1c8476"}],["path",{d:"M17 21v-7a1 1 0 0 0-1-1H8a1 1 0 0 0-1 1v7",key:"1ydtos"}],["path",{d:"M7 3v4a1 1 0 0 0 1 1h7",key:"t51u73"}]],cC=gt("save",sC);const fC=[["path",{d:"M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z",key:"oel41y"}]],Qs=gt("shield",fC);const dC=[["rect",{width:"14",height:"20",x:"5",y:"2",rx:"2",ry:"2",key:"1yt0o3"}],["path",{d:"M12 18h.01",key:"mhygvu"}]],mC=gt("smartphone",dC);const hC=[["path",{d:"M10 11v6",key:"nco0om"}],["path",{d:"M14 11v6",key:"outv1u"}],["path",{d:"M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6",key:"miytrc"}],["path",{d:"M3 6h18",key:"d0wm0j"}],["path",{d:"M8 6V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2",key:"e791ji"}]],pC=gt("trash-2",hC);const gC=[["path",{d:"m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3",key:"wmoenq"}],["path",{d:"M12 9v4",key:"juzpu7"}],["path",{d:"M12 17h.01",key:"p32p05"}]],vC=gt("triangle-alert",gC);const yC=[["path",{d:"M12 3v12",key:"1x0j5s"}],["path",{d:"m17 8-5-5-5 5",key:"7q97r8"}],["path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4",key:"ih7n3h"}]],s_=gt("upload",yC);const bC=[["path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2",key:"1yyitq"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}],["line",{x1:"19",x2:"19",y1:"8",y2:"14",key:"1bvyxn"}],["line",{x1:"22",x2:"16",y1:"11",y2:"11",key:"1shjgl"}]],xC=gt("user-plus",bC);const _C=[["path",{d:"M19 21v-2a4 4 0 0 0-4-4H9a4 4 0 0 0-4 4v2",key:"975kel"}],["circle",{cx:"12",cy:"7",r:"4",key:"17ys0d"}]],Yh=gt("user",_C);const SC=[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]],Ui=gt("x",SC),Eo="/api",kC="composer_proxy_admin_token";function jo(){return typeof window<"u"?localStorage.getItem(kC):null}async function lt(e,t={}){const i=jo(),l={"Content-Type":"application/json",...t.headers};i&&(l.Authorization=`Bearer ${i}`);const n=await fetch(`${Eo}${e}`,{...t,headers:l});if(!n.ok){const o=await n.json().catch(()=>({message:"Unknown error"}));throw new Error(o.message||`HTTP ${n.status}`)}return n.json()}async function wC(){try{const t=await(await fetch(`${Eo}/auth/check`,{headers:{"Content-Type":"application/json"}})).json();return{authRequired:t.authRequired??!0,setupRequired:t.setupRequired??!1}}catch{return{authRequired:!0,setupRequired:!1}}}async function $C(e){return lt("/setup",{method:"POST",body:JSON.stringify(e)})}async function EC(){return lt("/stats")}async function GS(){return lt("/repositories")}async function jC(e){return lt("/repositories",{method:"POST",body:JSON.stringify(e)})}async function zC(e,t){return lt(`/repositories/${e}`,{method:"PUT",body:JSON.stringify(t)})}async function NC(e){return lt(`/repositories/${e}`,{method:"DELETE"})}async function OC(e){return lt(`/repositories/${e}/sync`,{method:"POST"})}async function TC(){return lt("/tokens")}async function CC(e){return lt("/tokens",{method:"POST",body:JSON.stringify(e)})}async function DC(e,t){return lt(`/tokens/${e}`,{method:"PATCH",body:JSON.stringify(t)})}async function AC(e){return lt(`/tokens/${e}`,{method:"DELETE"})}async function RC(e){const t=e?`?search=${encodeURIComponent(e)}`:"";return lt(`/packages${t}`)}async function IC(e){return lt(`/packages/${encodeURIComponent(e)}`)}async function UC(e){const t=jo(),i=new FormData;i.append("file",e);const l={};t&&(l.Authorization=`Bearer ${t}`);const n=await fetch(`${Eo}/packages/upload`,{method:"POST",headers:l,body:i});if(!n.ok){const o=await n.json().catch(()=>({message:"Upload failed"}));throw o.details&&o.details.length>0?new Error(`${o.message||"Upload failed"}
|
|
12
|
+
${o.details.join(`
|
|
13
|
+
`)}`):new Error(o.message||`HTTP ${n.status}`)}return n.json()}async function LC(e,t){const i=jo(),l={"Content-Type":"text/markdown"};i&&(l.Authorization=`Bearer ${i}`);const n=await fetch(`${Eo}/packages/${encodeURIComponent(e)}/${encodeURIComponent(t)}/readme`,{headers:l});if(!n.ok){if(n.status===404)return null;throw new Error(`HTTP ${n.status}`)}return n.text()}async function MC(e,t){const i=jo(),l={"Content-Type":"text/markdown"};i&&(l.Authorization=`Bearer ${i}`);const n=await fetch(`${Eo}/packages/${encodeURIComponent(e)}/${encodeURIComponent(t)}/changelog`,{headers:l});if(!n.ok){if(n.status===404)return null;throw new Error(`HTTP ${n.status}`)}return n.text()}async function PC(e,t){return lt(`/packages/${encodeURIComponent(e)}/${encodeURIComponent(t)}/stats`)}async function VS(e,t){return lt(`/packages/${encodeURIComponent(e)}/${encodeURIComponent(t)}`,{method:"DELETE"})}async function Ks(){return lt("/settings")}async function ZC(e){return lt("/settings/packagist-mirroring",{method:"PUT",body:JSON.stringify({enabled:e})})}async function qC(e,t){return lt("/packages/add-from-mirror",{method:"POST",body:JSON.stringify({repository_id:e,package_names:t})})}async function FC(){return lt("/users").then(e=>e.users)}async function BC(e){return lt("/users",{method:"POST",body:JSON.stringify(e)})}async function HC(e){return lt(`/users/${e}`,{method:"DELETE"})}async function GC(){return lt("/auth/2fa/setup",{method:"POST"})}async function VC(e,t){return lt("/auth/2fa/enable",{method:"POST",body:JSON.stringify({secret:e,code:t})})}async function YC(){return lt("/auth/2fa/disable",{method:"POST"})}async function JC(e,t){return lt("/auth/invite/accept",{method:"POST",body:JSON.stringify({token:e,password:t})})}const c_="composer_proxy_sponsor_banner_dismissed";function XC(){const[e,t]=C.useState(!1);C.useEffect(()=>{if(typeof window<"u"){const l=localStorage.getItem(c_);t(l==="true")}},[]);const i=()=>{t(!0),typeof window<"u"&&localStorage.setItem(c_,"true")};return e?null:y.jsxs("div",{className:"relative bg-gradient-to-r from-pink-500/10 via-purple-500/10 to-pink-500/10 border border-pink-500/20 rounded-lg p-4 mb-6",children:[y.jsx("button",{onClick:i,className:"absolute top-2 right-2 text-slate-400 hover:text-slate-200 transition","aria-label":"Dismiss",children:y.jsx(Ui,{className:"w-4 h-4"})}),y.jsx("div",{className:"pr-8",children:y.jsxs("div",{className:"flex items-start gap-3",children:[y.jsx(Vh,{className:"w-6 h-6 text-pink-400 fill-pink-400"}),y.jsxs("div",{className:"flex-1",children:[y.jsx("p",{className:"text-slate-200 font-medium mb-1",children:"Enjoying this project? Consider sponsoring!"}),y.jsx("p",{className:"text-slate-400 text-sm mb-3",children:"Built during evenings and weekends. Your support helps keep it going and funds new features, better docs, and faster bug fixes."}),y.jsxs("a",{href:"https://github.com/sponsors/lbajsarowicz",target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center gap-2 px-4 py-2 bg-gradient-to-r from-pink-500 to-purple-600 hover:from-pink-600 hover:to-purple-700 text-white text-sm font-semibold rounded-lg shadow-lg shadow-pink-500/25 transition",children:[y.jsx(Vh,{className:"w-4 h-4 fill-current"}),y.jsx("span",{children:"Sponsor on GitHub"})]})]})]})})]})}function QC(){const{data:e,isLoading:t,error:i}=dn({queryKey:["stats"],queryFn:EC,refetchInterval:3e4}),l=[{title:"Active Repositories",value:e?.active_repos??0,icon:Ii,color:"from-primary-500 to-primary-700"},{title:"Cached Packages",value:e?.cached_packages??0,icon:HS,color:"from-accent-500 to-accent-700"},{title:"Total Downloads",value:e?.total_downloads??0,icon:J6,color:"from-emerald-500 to-emerald-700"}];return i?(console.error("Dashboard Error:",i),y.jsx("div",{className:"card p-6","data-testid":"dashboard-error",children:y.jsxs("p",{className:"text-red-400",children:["Error loading stats: ",i.message]})})):y.jsxs("div",{className:"space-y-8","data-testid":"dashboard-page",children:[y.jsxs("div",{children:[y.jsx("h2",{className:"font-display text-2xl font-bold text-slate-100 mb-2","data-testid":"dashboard-heading",children:"Dashboard"}),y.jsx("p",{className:"text-slate-400",children:"Overview of your Composer proxy"})]}),y.jsx(XC,{}),y.jsx("div",{className:"grid grid-cols-1 md:grid-cols-3 gap-6","data-testid":"stats-cards",children:l.map(n=>y.jsxs("div",{className:"card p-6","data-testid":`stat-card-${n.title.toLowerCase().replace(/\s+/g,"-")}`,children:[y.jsxs("div",{className:"flex items-center justify-between mb-4",children:[y.jsx("div",{className:`w-12 h-12 rounded-xl bg-gradient-to-br ${n.color} flex items-center justify-center shadow-lg`,children:y.jsx(n.icon,{className:"w-6 h-6 text-white"})}),t&&y.jsx("div",{className:"w-6 h-6 border-2 border-slate-600 border-t-primary-500 rounded-full animate-spin","aria-label":"Loading"})]}),y.jsx("p",{className:"text-slate-400 text-sm mb-1",children:n.title}),y.jsx("p",{className:"font-display text-3xl font-bold text-slate-100",children:t?"...":n.value.toLocaleString()})]},n.title))}),y.jsxs("div",{className:"card p-6","data-testid":"quick-start-section",children:[y.jsx("h3",{className:"font-display text-lg font-semibold text-slate-100 mb-4",children:"Quick Start"}),y.jsxs("div",{className:"space-y-4 text-slate-300",children:[y.jsxs("div",{className:"flex items-start gap-3",children:[y.jsx("span",{className:"text-primary-400 font-bold",children:"1."}),y.jsxs("p",{children:["Add a ",y.jsx("strong",{children:"repository source"})," in the Repositories tab"]})]}),y.jsxs("div",{className:"flex items-start gap-3",children:[y.jsx("span",{className:"text-primary-400 font-bold",children:"2."}),y.jsxs("p",{children:["Generate an ",y.jsx("strong",{children:"access token"})," in the Access Tokens tab"]})]}),y.jsxs("div",{className:"flex items-start gap-3",children:[y.jsx("span",{className:"text-primary-400 font-bold",children:"3."}),y.jsxs("div",{className:"flex-1",children:[y.jsx("p",{className:"mb-3",children:"Configure your project to use this proxy:"}),y.jsxs("div",{className:"mb-4","data-testid":"composer-cli-config",children:[y.jsx("p",{className:"text-sm text-slate-400 mb-2",children:"Using Composer CLI:"}),y.jsx("pre",{className:"bg-slate-950 rounded-lg p-4 overflow-x-auto text-sm text-slate-300",children:y.jsxs("code",{"data-testid":"composer-cli-command",children:["composer config repositories.proxy composer ",window.location.origin]})})]}),y.jsxs("div",{"data-testid":"composer-json-config",children:[y.jsx("p",{className:"text-sm text-slate-400 mb-2",children:"Or manually edit composer.json:"}),y.jsx("pre",{className:"bg-slate-950 rounded-lg p-4 overflow-x-auto text-sm text-slate-300",children:y.jsx("code",{"data-testid":"composer-json-code",children:`{
|
|
14
|
+
"repositories": [
|
|
15
|
+
{
|
|
16
|
+
"type": "composer",
|
|
17
|
+
"url": "${window.location.origin}"
|
|
18
|
+
}
|
|
19
|
+
]
|
|
20
|
+
}`})})]})]})]})]})]})]})}const Is={http_basic:{label:"HTTP Basic (Username/Password)",fields:[{name:"username",label:"Username",type:"text"},{name:"password",label:"Password",type:"password"}]},github_token:{label:"GitHub Token",fields:[{name:"token",label:"Personal Access Token",type:"password"}]},gitlab_token:{label:"GitLab Token",fields:[{name:"token",label:"Personal/Project Access Token",type:"password"}]},bitbucket_app_password:{label:"Bitbucket App Password",fields:[{name:"username",label:"Username",type:"text"},{name:"password",label:"App Password",type:"password"}]},bitbucket_api_token:{label:"Bitbucket API Token",fields:[{name:"token",label:"Token",type:"password"}]},bitbucket_api_key:{label:"Bitbucket API Key",fields:[{name:"key",label:"API Key",type:"password"}]},bitbucket_server_pat:{label:"Bitbucket Server PAT",fields:[{name:"token",label:"Personal Access Token",type:"password"}]},bearer_token:{label:"Bearer Token",fields:[{name:"token",label:"Token",type:"password"}]},none:{label:"No Authentication",fields:[]}},Us={composer:["http_basic","bearer_token"],git:["github_token","gitlab_token","bitbucket_app_password","bitbucket_api_token","bitbucket_api_key","bitbucket_server_pat"]};function Ma(e,t){var i={};for(var l in e)Object.prototype.hasOwnProperty.call(e,l)&&t.indexOf(l)<0&&(i[l]=e[l]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var n=0,l=Object.getOwnPropertySymbols(e);n<l.length;n++)t.indexOf(l[n])<0&&Object.prototype.propertyIsEnumerable.call(e,l[n])&&(i[l[n]]=e[l[n]]);return i}const KC={ZodAny:"any",ZodArray:"array",ZodBigInt:"bigint",ZodBoolean:"boolean",ZodDefault:"default",ZodPrefault:"prefault",ZodTransform:"transform",ZodEnum:"enum",ZodIntersection:"intersection",ZodLiteral:"literal",ZodNever:"never",ZodNull:"null",ZodNullable:"nullable",ZodNumber:"number",ZodNonOptional:"nonoptional",ZodObject:"object",ZodOptional:"optional",ZodPipe:"pipe",ZodReadonly:"readonly",ZodRecord:"record",ZodString:"string",ZodTuple:"tuple",ZodType:"type",ZodUnion:"union",ZodDiscriminatedUnion:"union",ZodUnknown:"unknown",ZodVoid:"void",ZodDate:"date"};function ii(e,t){return(Array.isArray(t)?t:[t]).some(l=>{var n;const o=((n=e?.def)===null||n===void 0?void 0:n.type)===KC[l];return l==="ZodDiscriminatedUnion"?o&&"discriminator"in e.def:o})}function Aa(e){return"def"in e}let WC=class{constructor(){this._map=new Map,this._idmap=new Map}add(t,...i){const l=i[0];if(this._map.set(t,l),l&&typeof l=="object"&&"id"in l){if(this._idmap.has(l.id))throw new Error(`ID ${l.id} already exists in the registry`);this._idmap.set(l.id,t)}return this}clear(){return this._map=new Map,this._idmap=new Map,this}remove(t){const i=this._map.get(t);return i&&typeof i=="object"&&"id"in i&&this._idmap.delete(i.id),this._map.delete(t),this}get(t){const i=t._zod.parent;if(i){const l={...this.get(i)??{}};return delete l.id,{...l,...this._map.get(t)}}return this._map.get(t)}has(t){return this._map.has(t)}};function eD(){return new WC}function jm(e){return e===void 0}function tD(e,t){const i={};return Object.entries(e).forEach(([l,n])=>{t.some(o=>o===l)||(i[l]=n)}),i}function zm(e,t){const i={};return Object.entries(e).forEach(([l,n])=>{t(n,l)||(i[l]=n)}),i}const f_=eD();class ai{static collectMetadata(t,i){const l=this.getMetadataFromRegistry(t),n=Object.assign(Object.assign({},l?._internal),i?._internal),o=Object.assign(Object.assign({},l?.param),i?.param),s=Object.assign(Object.assign(Object.assign(Object.assign({},Object.keys(n).length>0?{_internal:n}:{}),l),i),Object.keys(o).length>0?{param:o}:{});if(ii(t,["ZodOptional","ZodNullable","ZodDefault","ZodPrefault","ZodReadonly","ZodNonOptional"])&&Aa(t._zod.def.innerType))return this.collectMetadata(t._zod.def.innerType,s);if(ii(t,"ZodPipe")){const f=t._zod.def.in,m=t._zod.def.out;if(ii(f,"ZodTransform")&&Aa(m))return this.collectMetadata(m,s);if(Aa(f))return this.collectMetadata(f,s)}return s}static getMetadata(t){return this.collectMetadata(t)}static getOpenApiMetadata(t){const i=this.collectMetadata(t);return Ma(i??{},["_internal"])}static getInternalMetadata(t){var i;return(i=this.collectMetadata(t))===null||i===void 0?void 0:i._internal}static getParamMetadata(t){const i=this.collectMetadata(t);return Object.assign(Object.assign({},i),{param:Object.assign(Object.assign({},i?.description?{description:i.description}:{}),i?.param)})}static buildSchemaMetadata(t){return zm(tD(t,["param","_internal"]),jm)}static buildParameterMetadata(t){return zm(t,jm)}static applySchemaMetadata(t,i){return zm(Object.assign(Object.assign({},t),this.buildSchemaMetadata(i)),jm)}static getRefId(t){var i;return(i=this.getInternalMetadata(t))===null||i===void 0?void 0:i.refId}static unwrapChained(t){return this.unwrapUntil(t)}static getDefaultValue(t){var i;const l=(i=this.unwrapUntil(t,"ZodDefault"))!==null&&i!==void 0?i:this.unwrapUntil(t,"ZodPrefault");return l?._zod.def.defaultValue}static unwrapUntil(t,i){if(i&&ii(t,i))return t;if(ii(t,["ZodOptional","ZodNullable","ZodDefault","ZodPrefault","ZodReadonly","ZodNonOptional"])&&Aa(t._zod.def.innerType))return this.unwrapUntil(t._zod.def.innerType,i);if(ii(t,"ZodPipe")){const l=t._zod.def.in,n=t._zod.def.out;if(ii(l,"ZodTransform")&&Aa(n))return this.unwrapUntil(n,i);if(Aa(l))return this.unwrapUntil(l,i)}return i?void 0:t}static getMetadataFromInternalRegistry(t){return f_.get(t)}static getMetadataFromRegistry(t){const i=this.getMetadataFromInternalRegistry(t),l=t.meta();if(!i)return l;const{_internal:n}=i,o=Ma(i,["_internal"]),s=l??{},{id:f,title:m}=s,d=Ma(s,["id","title"]);return Object.assign(Object.assign(Object.assign({_internal:Object.assign(Object.assign({},f?{refId:f}:{}),n)},o),m?{description:m}:{}),d)}static setMetadataInRegistry(t,i){f_.add(t,i)}}function wr(e,t){const i=e[t];typeof i=="function"&&(e[t]=function(...l){const n=i.apply(this,l),o=ai.getMetadataFromRegistry(this);return o&&ai.setMetadataInRegistry(n,o),n})}function nD(e){typeof e.ZodType.prototype.openapi<"u"||(e.ZodType.prototype.openapi=function(...t){const{refId:i,metadata:l,options:n}=rD(...t),o=l??{},{param:s}=o,f=Ma(o,["param"]),m=ai.getMetadataFromRegistry(this),d=m??{},{_internal:p}=d,v=Ma(d,["_internal"]),b=Object.assign(Object.assign(Object.assign({},p),n),i?{refId:i}:void 0),x=Object.assign(Object.assign(Object.assign({},v),f),v?.param||s?{param:Object.assign(Object.assign({},v?.param),s)}:void 0),S=new this.constructor(this._def);if(ai.setMetadataInRegistry(S,Object.assign(Object.assign({},Object.keys(b).length>0?{_internal:b}:void 0),x)),ii(S,"ZodObject")){const j=ai.getMetadataFromRegistry(S),E=S.extend;S.extend=function(...O){const N=E.apply(S,O),G=j??{},{_internal:J}=G,R=Ma(G,["_internal"]);return ai.setMetadataInRegistry(N,{_internal:{extendedFrom:J?.refId?{refId:J.refId,schema:S}:J?.extendedFrom}}),N.openapi(R)},wr(S,"catchall")}wr(S,"optional"),wr(S,"nullable"),wr(S,"default"),wr(S,"transform"),wr(S,"refine"),wr(S,"length"),wr(S,"min"),wr(S,"max");const w=S.meta;return S.meta=function(...j){const E=w.apply(this,j);if(j[0]){const O=ai.getMetadataFromInternalRegistry(this);O&&ai.setMetadataInRegistry(E,Object.assign(Object.assign({},O),j[0]))}return E},S})}function rD(e,t,i){return typeof e=="string"?{refId:e,metadata:t,options:i}:{refId:void 0,metadata:e,options:t}}new Set(".\\+*[^]$()");const YS=Object.freeze({status:"aborted"});function P(e,t,i){function l(f,m){if(f._zod||Object.defineProperty(f,"_zod",{value:{def:m,constr:s,traits:new Set},enumerable:!1}),f._zod.traits.has(e))return;f._zod.traits.add(e),t(f,m);const d=s.prototype,p=Object.keys(d);for(let v=0;v<p.length;v++){const b=p[v];b in f||(f[b]=d[b].bind(f))}}const n=i?.Parent??Object;class o extends n{}Object.defineProperty(o,"name",{value:e});function s(f){var m;const d=i?.Parent?new o:this;l(d,f),(m=d._zod).deferred??(m.deferred=[]);for(const p of d._zod.deferred)p();return d}return Object.defineProperty(s,"init",{value:l}),Object.defineProperty(s,Symbol.hasInstance,{value:f=>i?.Parent&&f instanceof i.Parent?!0:f?._zod?.traits?.has(e)}),Object.defineProperty(s,"name",{value:e}),s}const JS=Symbol("zod_brand");class Di extends Error{constructor(){super("Encountered Promise during synchronous parse. Use .parseAsync() instead.")}}class Ws extends Error{constructor(t){super(`Encountered unidirectional transform during encode: ${t}`),this.name="ZodEncodeError"}}const Ls={};function It(e){return e&&Object.assign(Ls,e),Ls}function iD(e){return e}function aD(e){return e}function lD(e){}function oD(e){throw new Error("Unexpected value in exhaustive check")}function uD(e){}function ec(e){const t=Object.values(e).filter(l=>typeof l=="number");return Object.entries(e).filter(([l,n])=>t.indexOf(+l)===-1).map(([l,n])=>n)}function ae(e,t="|"){return e.map(i=>xe(i)).join(t)}function Ms(e,t){return typeof t=="bigint"?t.toString():t}function zo(e){return{get value(){{const t=e();return Object.defineProperty(this,"value",{value:t}),t}}}}function qi(e){return e==null}function tc(e){const t=e.startsWith("^")?1:0,i=e.endsWith("$")?e.length-1:e.length;return e.slice(t,i)}function XS(e,t){const i=(e.toString().split(".")[1]||"").length,l=t.toString();let n=(l.split(".")[1]||"").length;if(n===0&&/\d?e-\d?/.test(l)){const m=l.match(/\d?e-(\d?)/);m?.[1]&&(n=Number.parseInt(m[1]))}const o=i>n?i:n,s=Number.parseInt(e.toFixed(o).replace(".","")),f=Number.parseInt(t.toFixed(o).replace(".",""));return s%f/10**o}const d_=Symbol("evaluating");function Te(e,t,i){let l;Object.defineProperty(e,t,{get(){if(l!==d_)return l===void 0&&(l=d_,l=i()),l},set(n){Object.defineProperty(e,t,{value:n})},configurable:!0})}function sD(e){return Object.create(Object.getPrototypeOf(e),Object.getOwnPropertyDescriptors(e))}function ci(e,t,i){Object.defineProperty(e,t,{value:i,writable:!0,enumerable:!0,configurable:!0})}function tr(...e){const t={};for(const i of e){const l=Object.getOwnPropertyDescriptors(i);Object.assign(t,l)}return Object.defineProperties({},t)}function cD(e){return tr(e._zod.def)}function fD(e,t){return t?t.reduce((i,l)=>i?.[l],e):e}function dD(e){const t=Object.keys(e),i=t.map(l=>e[l]);return Promise.all(i).then(l=>{const n={};for(let o=0;o<t.length;o++)n[t[o]]=l[o];return n})}function mD(e=10){const t="abcdefghijklmnopqrstuvwxyz";let i="";for(let l=0;l<e;l++)i+=t[Math.floor(Math.random()*t.length)];return i}function Jh(e){return JSON.stringify(e)}function QS(e){return e.toLowerCase().trim().replace(/[^\w\s-]/g,"").replace(/[\s_-]+/g,"-").replace(/^-+|-+$/g,"")}const wp="captureStackTrace"in Error?Error.captureStackTrace:(...e)=>{};function qa(e){return typeof e=="object"&&e!==null&&!Array.isArray(e)}const KS=zo(()=>{if(typeof navigator<"u"&&navigator?.userAgent?.includes("Cloudflare"))return!1;try{const e=Function;return new e(""),!0}catch{return!1}});function Li(e){if(qa(e)===!1)return!1;const t=e.constructor;if(t===void 0||typeof t!="function")return!0;const i=t.prototype;return!(qa(i)===!1||Object.prototype.hasOwnProperty.call(i,"isPrototypeOf")===!1)}function nc(e){return Li(e)?{...e}:Array.isArray(e)?[...e]:e}function hD(e){let t=0;for(const i in e)Object.prototype.hasOwnProperty.call(e,i)&&t++;return t}const pD=e=>{const t=typeof e;switch(t){case"undefined":return"undefined";case"string":return"string";case"number":return Number.isNaN(e)?"nan":"number";case"boolean":return"boolean";case"function":return"function";case"bigint":return"bigint";case"symbol":return"symbol";case"object":return Array.isArray(e)?"array":e===null?"null":e.then&&typeof e.then=="function"&&e.catch&&typeof e.catch=="function"?"promise":typeof Map<"u"&&e instanceof Map?"map":typeof Set<"u"&&e instanceof Set?"set":typeof Date<"u"&&e instanceof Date?"date":typeof File<"u"&&e instanceof File?"file":"object";default:throw new Error(`Unknown data type: ${t}`)}},Ps=new Set(["string","number","symbol"]),WS=new Set(["string","number","bigint","boolean","symbol","undefined"]);function Nr(e){return e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function Rn(e,t,i){const l=new e._zod.constr(t??e._zod.def);return(!t||i?.parent)&&(l._zod.parent=e),l}function re(e){const t=e;if(!t)return{};if(typeof t=="string")return{error:()=>t};if(t?.message!==void 0){if(t?.error!==void 0)throw new Error("Cannot specify both `message` and `error` params");t.error=t.message}return delete t.message,typeof t.error=="string"?{...t,error:()=>t.error}:t}function gD(e){let t;return new Proxy({},{get(i,l,n){return t??(t=e()),Reflect.get(t,l,n)},set(i,l,n,o){return t??(t=e()),Reflect.set(t,l,n,o)},has(i,l){return t??(t=e()),Reflect.has(t,l)},deleteProperty(i,l){return t??(t=e()),Reflect.deleteProperty(t,l)},ownKeys(i){return t??(t=e()),Reflect.ownKeys(t)},getOwnPropertyDescriptor(i,l){return t??(t=e()),Reflect.getOwnPropertyDescriptor(t,l)},defineProperty(i,l,n){return t??(t=e()),Reflect.defineProperty(t,l,n)}})}function xe(e){return typeof e=="bigint"?e.toString()+"n":typeof e=="string"?`"${e}"`:`${e}`}function ek(e){return Object.keys(e).filter(t=>e[t]._zod.optin==="optional"&&e[t]._zod.optout==="optional")}const tk={safeint:[Number.MIN_SAFE_INTEGER,Number.MAX_SAFE_INTEGER],int32:[-2147483648,2147483647],uint32:[0,4294967295],float32:[-34028234663852886e22,34028234663852886e22],float64:[-Number.MAX_VALUE,Number.MAX_VALUE]},nk={int64:[BigInt("-9223372036854775808"),BigInt("9223372036854775807")],uint64:[BigInt(0),BigInt("18446744073709551615")]};function rk(e,t){const i=e._zod.def,l=i.checks;if(l&&l.length>0)throw new Error(".pick() cannot be used on object schemas containing refinements");const o=tr(e._zod.def,{get shape(){const s={};for(const f in t){if(!(f in i.shape))throw new Error(`Unrecognized key: "${f}"`);t[f]&&(s[f]=i.shape[f])}return ci(this,"shape",s),s},checks:[]});return Rn(e,o)}function ik(e,t){const i=e._zod.def,l=i.checks;if(l&&l.length>0)throw new Error(".omit() cannot be used on object schemas containing refinements");const o=tr(e._zod.def,{get shape(){const s={...e._zod.def.shape};for(const f in t){if(!(f in i.shape))throw new Error(`Unrecognized key: "${f}"`);t[f]&&delete s[f]}return ci(this,"shape",s),s},checks:[]});return Rn(e,o)}function ak(e,t){if(!Li(t))throw new Error("Invalid input to extend: expected a plain object");const i=e._zod.def.checks;if(i&&i.length>0){const o=e._zod.def.shape;for(const s in t)if(Object.getOwnPropertyDescriptor(o,s)!==void 0)throw new Error("Cannot overwrite keys on object schemas containing refinements. Use `.safeExtend()` instead.")}const n=tr(e._zod.def,{get shape(){const o={...e._zod.def.shape,...t};return ci(this,"shape",o),o}});return Rn(e,n)}function lk(e,t){if(!Li(t))throw new Error("Invalid input to safeExtend: expected a plain object");const i=tr(e._zod.def,{get shape(){const l={...e._zod.def.shape,...t};return ci(this,"shape",l),l}});return Rn(e,i)}function ok(e,t){const i=tr(e._zod.def,{get shape(){const l={...e._zod.def.shape,...t._zod.def.shape};return ci(this,"shape",l),l},get catchall(){return t._zod.def.catchall},checks:[]});return Rn(e,i)}function uk(e,t,i){const n=t._zod.def.checks;if(n&&n.length>0)throw new Error(".partial() cannot be used on object schemas containing refinements");const s=tr(t._zod.def,{get shape(){const f=t._zod.def.shape,m={...f};if(i)for(const d in i){if(!(d in f))throw new Error(`Unrecognized key: "${d}"`);i[d]&&(m[d]=e?new e({type:"optional",innerType:f[d]}):f[d])}else for(const d in f)m[d]=e?new e({type:"optional",innerType:f[d]}):f[d];return ci(this,"shape",m),m},checks:[]});return Rn(t,s)}function sk(e,t,i){const l=tr(t._zod.def,{get shape(){const n=t._zod.def.shape,o={...n};if(i)for(const s in i){if(!(s in o))throw new Error(`Unrecognized key: "${s}"`);i[s]&&(o[s]=new e({type:"nonoptional",innerType:n[s]}))}else for(const s in n)o[s]=new e({type:"nonoptional",innerType:n[s]});return ci(this,"shape",o),o}});return Rn(t,l)}function Ci(e,t=0){if(e.aborted===!0)return!0;for(let i=t;i<e.issues.length;i++)if(e.issues[i]?.continue!==!0)return!0;return!1}function Pn(e,t){return t.map(i=>{var l;return(l=i).path??(l.path=[]),i.path.unshift(e),i})}function oo(e){return typeof e=="string"?e:e?.message}function Dn(e,t,i){const l={...e,path:e.path??[]};if(!e.message){const n=oo(e.inst?._zod.def?.error?.(e))??oo(t?.error?.(e))??oo(i.customError?.(e))??oo(i.localeError?.(e))??"Invalid input";l.message=n}return delete l.inst,delete l.continue,t?.reportInput||delete l.input,l}function rc(e){return e instanceof Set?"set":e instanceof Map?"map":e instanceof File?"file":"unknown"}function ic(e){return Array.isArray(e)?"array":typeof e=="string"?"string":"unknown"}function Se(e){const t=typeof e;switch(t){case"number":return Number.isNaN(e)?"nan":"number";case"object":{if(e===null)return"null";if(Array.isArray(e))return"array";const i=e;if(i&&Object.getPrototypeOf(i)!==Object.prototype&&"constructor"in i&&i.constructor)return i.constructor.name}}return t}function Fa(...e){const[t,i,l]=e;return typeof t=="string"?{message:t,code:"custom",input:i,inst:l}:{...t}}function vD(e){return Object.entries(e).filter(([t,i])=>Number.isNaN(Number.parseInt(t,10))).map(t=>t[1])}function ck(e){const t=atob(e),i=new Uint8Array(t.length);for(let l=0;l<t.length;l++)i[l]=t.charCodeAt(l);return i}function fk(e){let t="";for(let i=0;i<e.length;i++)t+=String.fromCharCode(e[i]);return btoa(t)}function yD(e){const t=e.replace(/-/g,"+").replace(/_/g,"/"),i="=".repeat((4-t.length%4)%4);return ck(t+i)}function bD(e){return fk(e).replace(/\+/g,"-").replace(/\//g,"_").replace(/=/g,"")}function xD(e){const t=e.replace(/^0x/,"");if(t.length%2!==0)throw new Error("Invalid hex string length");const i=new Uint8Array(t.length/2);for(let l=0;l<t.length;l+=2)i[l/2]=Number.parseInt(t.slice(l,l+2),16);return i}function _D(e){return Array.from(e).map(t=>t.toString(16).padStart(2,"0")).join("")}class SD{constructor(...t){}}const dk=Object.freeze(Object.defineProperty({__proto__:null,BIGINT_FORMAT_RANGES:nk,Class:SD,NUMBER_FORMAT_RANGES:tk,aborted:Ci,allowsEval:KS,assert:uD,assertEqual:iD,assertIs:lD,assertNever:oD,assertNotEqual:aD,assignProp:ci,base64ToUint8Array:ck,base64urlToUint8Array:yD,cached:zo,captureStackTrace:wp,cleanEnum:vD,cleanRegex:tc,clone:Rn,cloneDef:cD,createTransparentProxy:gD,defineLazy:Te,esc:Jh,escapeRegex:Nr,extend:ak,finalizeIssue:Dn,floatSafeRemainder:XS,getElementAtPath:fD,getEnumValues:ec,getLengthableOrigin:ic,getParsedType:pD,getSizableOrigin:rc,hexToUint8Array:xD,isObject:qa,isPlainObject:Li,issue:Fa,joinValues:ae,jsonStringifyReplacer:Ms,merge:ok,mergeDefs:tr,normalizeParams:re,nullish:qi,numKeys:hD,objectClone:sD,omit:ik,optionalKeys:ek,parsedType:Se,partial:uk,pick:rk,prefixIssues:Pn,primitiveTypes:WS,promiseAllObject:dD,propertyKeyTypes:Ps,randomString:mD,required:sk,safeExtend:lk,shallowClone:nc,slugify:QS,stringifyPrimitive:xe,uint8ArrayToBase64:fk,uint8ArrayToBase64url:bD,uint8ArrayToHex:_D,unwrapMessage:oo},Symbol.toStringTag,{value:"Module"})),mk=(e,t)=>{e.name="$ZodError",Object.defineProperty(e,"_zod",{value:e._zod,enumerable:!1}),Object.defineProperty(e,"issues",{value:t,enumerable:!1}),e.message=JSON.stringify(t,Ms,2),Object.defineProperty(e,"toString",{value:()=>e.message,enumerable:!1})},$p=P("$ZodError",mk),hn=P("$ZodError",mk,{Parent:Error});function Ep(e,t=i=>i.message){const i={},l=[];for(const n of e.issues)n.path.length>0?(i[n.path[0]]=i[n.path[0]]||[],i[n.path[0]].push(t(n))):l.push(t(n));return{formErrors:l,fieldErrors:i}}function jp(e,t=i=>i.message){const i={_errors:[]},l=n=>{for(const o of n.issues)if(o.code==="invalid_union"&&o.errors.length)o.errors.map(s=>l({issues:s}));else if(o.code==="invalid_key")l({issues:o.issues});else if(o.code==="invalid_element")l({issues:o.issues});else if(o.path.length===0)i._errors.push(t(o));else{let s=i,f=0;for(;f<o.path.length;){const m=o.path[f];f===o.path.length-1?(s[m]=s[m]||{_errors:[]},s[m]._errors.push(t(o))):s[m]=s[m]||{_errors:[]},s=s[m],f++}}};return l(e),i}function hk(e,t=i=>i.message){const i={errors:[]},l=(n,o=[])=>{var s,f;for(const m of n.issues)if(m.code==="invalid_union"&&m.errors.length)m.errors.map(d=>l({issues:d},m.path));else if(m.code==="invalid_key")l({issues:m.issues},m.path);else if(m.code==="invalid_element")l({issues:m.issues},m.path);else{const d=[...o,...m.path];if(d.length===0){i.errors.push(t(m));continue}let p=i,v=0;for(;v<d.length;){const b=d[v],x=v===d.length-1;typeof b=="string"?(p.properties??(p.properties={}),(s=p.properties)[b]??(s[b]={errors:[]}),p=p.properties[b]):(p.items??(p.items=[]),(f=p.items)[b]??(f[b]={errors:[]}),p=p.items[b]),x&&p.errors.push(t(m)),v++}}};return l(e),i}function pk(e){const t=[],i=e.map(l=>typeof l=="object"?l.key:l);for(const l of i)typeof l=="number"?t.push(`[${l}]`):typeof l=="symbol"?t.push(`[${JSON.stringify(String(l))}]`):/[^\w$]/.test(l)?t.push(`[${JSON.stringify(l)}]`):(t.length&&t.push("."),t.push(l));return t.join("")}function gk(e){const t=[],i=[...e.issues].sort((l,n)=>(l.path??[]).length-(n.path??[]).length);for(const l of i)t.push(`✖ ${l.message}`),l.path?.length&&t.push(` → at ${pk(l.path)}`);return t.join(`
|
|
21
|
+
`)}const No=e=>(t,i,l,n)=>{const o=l?Object.assign(l,{async:!1}):{async:!1},s=t._zod.run({value:i,issues:[]},o);if(s instanceof Promise)throw new Di;if(s.issues.length){const f=new(n?.Err??e)(s.issues.map(m=>Dn(m,o,It())));throw wp(f,n?.callee),f}return s.value},Xh=No(hn),Oo=e=>async(t,i,l,n)=>{const o=l?Object.assign(l,{async:!0}):{async:!0};let s=t._zod.run({value:i,issues:[]},o);if(s instanceof Promise&&(s=await s),s.issues.length){const f=new(n?.Err??e)(s.issues.map(m=>Dn(m,o,It())));throw wp(f,n?.callee),f}return s.value},Qh=Oo(hn),To=e=>(t,i,l)=>{const n=l?{...l,async:!1}:{async:!1},o=t._zod.run({value:i,issues:[]},n);if(o instanceof Promise)throw new Di;return o.issues.length?{success:!1,error:new(e??$p)(o.issues.map(s=>Dn(s,n,It())))}:{success:!0,data:o.value}},vk=To(hn),Co=e=>async(t,i,l)=>{const n=l?Object.assign(l,{async:!0}):{async:!0};let o=t._zod.run({value:i,issues:[]},n);return o instanceof Promise&&(o=await o),o.issues.length?{success:!1,error:new e(o.issues.map(s=>Dn(s,n,It())))}:{success:!0,data:o.value}},yk=Co(hn),zp=e=>(t,i,l)=>{const n=l?Object.assign(l,{direction:"backward"}):{direction:"backward"};return No(e)(t,i,n)},kD=zp(hn),Np=e=>(t,i,l)=>No(e)(t,i,l),wD=Np(hn),Op=e=>async(t,i,l)=>{const n=l?Object.assign(l,{direction:"backward"}):{direction:"backward"};return Oo(e)(t,i,n)},$D=Op(hn),Tp=e=>async(t,i,l)=>Oo(e)(t,i,l),ED=Tp(hn),Cp=e=>(t,i,l)=>{const n=l?Object.assign(l,{direction:"backward"}):{direction:"backward"};return To(e)(t,i,n)},jD=Cp(hn),Dp=e=>(t,i,l)=>To(e)(t,i,l),zD=Dp(hn),Ap=e=>async(t,i,l)=>{const n=l?Object.assign(l,{direction:"backward"}):{direction:"backward"};return Co(e)(t,i,n)},ND=Ap(hn),Rp=e=>async(t,i,l)=>Co(e)(t,i,l),OD=Rp(hn),bk=/^[cC][^\s-]{8,}$/,xk=/^[0-9a-z]+$/,_k=/^[0-9A-HJKMNP-TV-Za-hjkmnp-tv-z]{26}$/,Sk=/^[0-9a-vA-V]{20}$/,kk=/^[A-Za-z0-9]{27}$/,wk=/^[a-zA-Z0-9_-]{21}$/,$k=/^P(?:(\d+W)|(?!.*W)(?=\d|T\d)(\d+Y)?(\d+M)?(\d+D)?(T(?=\d)(\d+H)?(\d+M)?(\d+([.,]\d+)?S)?)?)$/,TD=/^[-+]?P(?!$)(?:(?:[-+]?\d+Y)|(?:[-+]?\d+[.,]\d+Y$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:(?:[-+]?\d+W)|(?:[-+]?\d+[.,]\d+W$))?(?:(?:[-+]?\d+D)|(?:[-+]?\d+[.,]\d+D$))?(?:T(?=[\d+-])(?:(?:[-+]?\d+H)|(?:[-+]?\d+[.,]\d+H$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:[-+]?\d+(?:[.,]\d+)?S)?)??$/,Ek=/^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$/,Ba=e=>e?new RegExp(`^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-${e}[0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12})$`):/^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$/,CD=Ba(4),DD=Ba(6),AD=Ba(7),jk=/^(?!\.)(?!.*\.\.)([A-Za-z0-9_'+\-\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\-]*\.)+[A-Za-z]{2,}$/,RD=/^[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])?)*$/,ID=/^(([^<>()\[\]\\.,;:\s@"]+(\.[^<>()\[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/,zk=/^[^\s@"]{1,64}@[^\s@]{1,255}$/u,UD=zk,LD=/^[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])?)*$/,MD="^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$";function Nk(){return new RegExp(MD,"u")}const Ok=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])$/,Tk=/^(([0-9a-fA-F]{1,4}:){7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:))$/,Ck=e=>{const t=Nr(e??":");return new RegExp(`^(?:[0-9A-F]{2}${t}){5}[0-9A-F]{2}$|^(?:[0-9a-f]{2}${t}){5}[0-9a-f]{2}$`)},Dk=/^((25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\/([0-9]|[1-2][0-9]|3[0-2])$/,Ak=/^(([0-9a-fA-F]{1,4}:){7}[0-9a-fA-F]{1,4}|::|([0-9a-fA-F]{1,4})?::([0-9a-fA-F]{1,4}:?){0,6})\/(12[0-8]|1[01][0-9]|[1-9]?[0-9])$/,Rk=/^$|^(?:[0-9a-zA-Z+/]{4})*(?:(?:[0-9a-zA-Z+/]{2}==)|(?:[0-9a-zA-Z+/]{3}=))?$/,Ip=/^[A-Za-z0-9_-]*$/,Ik=/^(?=.{1,253}\.?$)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[-0-9a-zA-Z]{0,61}[0-9a-zA-Z])?)*\.?$/,Uk=/^([a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?\.)+[a-zA-Z]{2,}$/,Lk=/^\+[1-9]\d{6,14}$/,Mk="(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))",Pk=new RegExp(`^${Mk}$`);function Zk(e){const t="(?:[01]\\d|2[0-3]):[0-5]\\d";return typeof e.precision=="number"?e.precision===-1?`${t}`:e.precision===0?`${t}:[0-5]\\d`:`${t}:[0-5]\\d\\.\\d{${e.precision}}`:`${t}(?::[0-5]\\d(?:\\.\\d+)?)?`}function qk(e){return new RegExp(`^${Zk(e)}$`)}function Fk(e){const t=Zk({precision:e.precision}),i=["Z"];e.local&&i.push(""),e.offset&&i.push("([+-](?:[01]\\d|2[0-3]):[0-5]\\d)");const l=`${t}(?:${i.join("|")})`;return new RegExp(`^${Mk}T(?:${l})$`)}const Bk=e=>{const t=e?`[\\s\\S]{${e?.minimum??0},${e?.maximum??""}}`:"[\\s\\S]*";return new RegExp(`^${t}$`)},Hk=/^-?\d+n?$/,Gk=/^-?\d+$/,Up=/^-?\d+(?:\.\d+)?$/,Vk=/^(?:true|false)$/i,Yk=/^null$/i,Jk=/^undefined$/i,Xk=/^[^A-Z]*$/,Qk=/^[^a-z]*$/,Kk=/^[0-9a-fA-F]*$/;function Do(e,t){return new RegExp(`^[A-Za-z0-9+/]{${e}}${t}$`)}function Ao(e){return new RegExp(`^[A-Za-z0-9_-]{${e}}$`)}const PD=/^[0-9a-fA-F]{32}$/,ZD=Do(22,"=="),qD=Ao(22),FD=/^[0-9a-fA-F]{40}$/,BD=Do(27,"="),HD=Ao(27),GD=/^[0-9a-fA-F]{64}$/,VD=Do(43,"="),YD=Ao(43),JD=/^[0-9a-fA-F]{96}$/,XD=Do(64,""),QD=Ao(64),KD=/^[0-9a-fA-F]{128}$/,WD=Do(86,"=="),eA=Ao(86),Lp=Object.freeze(Object.defineProperty({__proto__:null,base64:Rk,base64url:Ip,bigint:Hk,boolean:Vk,browserEmail:LD,cidrv4:Dk,cidrv6:Ak,cuid:bk,cuid2:xk,date:Pk,datetime:Fk,domain:Uk,duration:$k,e164:Lk,email:jk,emoji:Nk,extendedDuration:TD,guid:Ek,hex:Kk,hostname:Ik,html5Email:RD,idnEmail:UD,integer:Gk,ipv4:Ok,ipv6:Tk,ksuid:kk,lowercase:Xk,mac:Ck,md5_base64:ZD,md5_base64url:qD,md5_hex:PD,nanoid:wk,null:Yk,number:Up,rfc5322Email:ID,sha1_base64:BD,sha1_base64url:HD,sha1_hex:FD,sha256_base64:VD,sha256_base64url:YD,sha256_hex:GD,sha384_base64:XD,sha384_base64url:QD,sha384_hex:JD,sha512_base64:WD,sha512_base64url:eA,sha512_hex:KD,string:Bk,time:qk,ulid:_k,undefined:Jk,unicodeEmail:zk,uppercase:Qk,uuid:Ba,uuid4:CD,uuid6:DD,uuid7:AD,xid:Sk},Symbol.toStringTag,{value:"Module"})),st=P("$ZodCheck",(e,t)=>{var i;e._zod??(e._zod={}),e._zod.def=t,(i=e._zod).onattach??(i.onattach=[])}),Wk={number:"number",bigint:"bigint",object:"date"},Mp=P("$ZodCheckLessThan",(e,t)=>{st.init(e,t);const i=Wk[typeof t.value];e._zod.onattach.push(l=>{const n=l._zod.bag,o=(t.inclusive?n.maximum:n.exclusiveMaximum)??Number.POSITIVE_INFINITY;t.value<o&&(t.inclusive?n.maximum=t.value:n.exclusiveMaximum=t.value)}),e._zod.check=l=>{(t.inclusive?l.value<=t.value:l.value<t.value)||l.issues.push({origin:i,code:"too_big",maximum:typeof t.value=="object"?t.value.getTime():t.value,input:l.value,inclusive:t.inclusive,inst:e,continue:!t.abort})}}),Pp=P("$ZodCheckGreaterThan",(e,t)=>{st.init(e,t);const i=Wk[typeof t.value];e._zod.onattach.push(l=>{const n=l._zod.bag,o=(t.inclusive?n.minimum:n.exclusiveMinimum)??Number.NEGATIVE_INFINITY;t.value>o&&(t.inclusive?n.minimum=t.value:n.exclusiveMinimum=t.value)}),e._zod.check=l=>{(t.inclusive?l.value>=t.value:l.value>t.value)||l.issues.push({origin:i,code:"too_small",minimum:typeof t.value=="object"?t.value.getTime():t.value,input:l.value,inclusive:t.inclusive,inst:e,continue:!t.abort})}}),ew=P("$ZodCheckMultipleOf",(e,t)=>{st.init(e,t),e._zod.onattach.push(i=>{var l;(l=i._zod.bag).multipleOf??(l.multipleOf=t.value)}),e._zod.check=i=>{if(typeof i.value!=typeof t.value)throw new Error("Cannot mix number and bigint in multiple_of check.");(typeof i.value=="bigint"?i.value%t.value===BigInt(0):XS(i.value,t.value)===0)||i.issues.push({origin:typeof i.value,code:"not_multiple_of",divisor:t.value,input:i.value,inst:e,continue:!t.abort})}}),tw=P("$ZodCheckNumberFormat",(e,t)=>{st.init(e,t),t.format=t.format||"float64";const i=t.format?.includes("int"),l=i?"int":"number",[n,o]=tk[t.format];e._zod.onattach.push(s=>{const f=s._zod.bag;f.format=t.format,f.minimum=n,f.maximum=o,i&&(f.pattern=Gk)}),e._zod.check=s=>{const f=s.value;if(i){if(!Number.isInteger(f)){s.issues.push({expected:l,format:t.format,code:"invalid_type",continue:!1,input:f,inst:e});return}if(!Number.isSafeInteger(f)){f>0?s.issues.push({input:f,code:"too_big",maximum:Number.MAX_SAFE_INTEGER,note:"Integers must be within the safe integer range.",inst:e,origin:l,inclusive:!0,continue:!t.abort}):s.issues.push({input:f,code:"too_small",minimum:Number.MIN_SAFE_INTEGER,note:"Integers must be within the safe integer range.",inst:e,origin:l,inclusive:!0,continue:!t.abort});return}}f<n&&s.issues.push({origin:"number",input:f,code:"too_small",minimum:n,inclusive:!0,inst:e,continue:!t.abort}),f>o&&s.issues.push({origin:"number",input:f,code:"too_big",maximum:o,inclusive:!0,inst:e,continue:!t.abort})}}),nw=P("$ZodCheckBigIntFormat",(e,t)=>{st.init(e,t);const[i,l]=nk[t.format];e._zod.onattach.push(n=>{const o=n._zod.bag;o.format=t.format,o.minimum=i,o.maximum=l}),e._zod.check=n=>{const o=n.value;o<i&&n.issues.push({origin:"bigint",input:o,code:"too_small",minimum:i,inclusive:!0,inst:e,continue:!t.abort}),o>l&&n.issues.push({origin:"bigint",input:o,code:"too_big",maximum:l,inclusive:!0,inst:e,continue:!t.abort})}}),rw=P("$ZodCheckMaxSize",(e,t)=>{var i;st.init(e,t),(i=e._zod.def).when??(i.when=l=>{const n=l.value;return!qi(n)&&n.size!==void 0}),e._zod.onattach.push(l=>{const n=l._zod.bag.maximum??Number.POSITIVE_INFINITY;t.maximum<n&&(l._zod.bag.maximum=t.maximum)}),e._zod.check=l=>{const n=l.value;n.size<=t.maximum||l.issues.push({origin:rc(n),code:"too_big",maximum:t.maximum,inclusive:!0,input:n,inst:e,continue:!t.abort})}}),iw=P("$ZodCheckMinSize",(e,t)=>{var i;st.init(e,t),(i=e._zod.def).when??(i.when=l=>{const n=l.value;return!qi(n)&&n.size!==void 0}),e._zod.onattach.push(l=>{const n=l._zod.bag.minimum??Number.NEGATIVE_INFINITY;t.minimum>n&&(l._zod.bag.minimum=t.minimum)}),e._zod.check=l=>{const n=l.value;n.size>=t.minimum||l.issues.push({origin:rc(n),code:"too_small",minimum:t.minimum,inclusive:!0,input:n,inst:e,continue:!t.abort})}}),aw=P("$ZodCheckSizeEquals",(e,t)=>{var i;st.init(e,t),(i=e._zod.def).when??(i.when=l=>{const n=l.value;return!qi(n)&&n.size!==void 0}),e._zod.onattach.push(l=>{const n=l._zod.bag;n.minimum=t.size,n.maximum=t.size,n.size=t.size}),e._zod.check=l=>{const n=l.value,o=n.size;if(o===t.size)return;const s=o>t.size;l.issues.push({origin:rc(n),...s?{code:"too_big",maximum:t.size}:{code:"too_small",minimum:t.size},inclusive:!0,exact:!0,input:l.value,inst:e,continue:!t.abort})}}),lw=P("$ZodCheckMaxLength",(e,t)=>{var i;st.init(e,t),(i=e._zod.def).when??(i.when=l=>{const n=l.value;return!qi(n)&&n.length!==void 0}),e._zod.onattach.push(l=>{const n=l._zod.bag.maximum??Number.POSITIVE_INFINITY;t.maximum<n&&(l._zod.bag.maximum=t.maximum)}),e._zod.check=l=>{const n=l.value;if(n.length<=t.maximum)return;const s=ic(n);l.issues.push({origin:s,code:"too_big",maximum:t.maximum,inclusive:!0,input:n,inst:e,continue:!t.abort})}}),ow=P("$ZodCheckMinLength",(e,t)=>{var i;st.init(e,t),(i=e._zod.def).when??(i.when=l=>{const n=l.value;return!qi(n)&&n.length!==void 0}),e._zod.onattach.push(l=>{const n=l._zod.bag.minimum??Number.NEGATIVE_INFINITY;t.minimum>n&&(l._zod.bag.minimum=t.minimum)}),e._zod.check=l=>{const n=l.value;if(n.length>=t.minimum)return;const s=ic(n);l.issues.push({origin:s,code:"too_small",minimum:t.minimum,inclusive:!0,input:n,inst:e,continue:!t.abort})}}),uw=P("$ZodCheckLengthEquals",(e,t)=>{var i;st.init(e,t),(i=e._zod.def).when??(i.when=l=>{const n=l.value;return!qi(n)&&n.length!==void 0}),e._zod.onattach.push(l=>{const n=l._zod.bag;n.minimum=t.length,n.maximum=t.length,n.length=t.length}),e._zod.check=l=>{const n=l.value,o=n.length;if(o===t.length)return;const s=ic(n),f=o>t.length;l.issues.push({origin:s,...f?{code:"too_big",maximum:t.length}:{code:"too_small",minimum:t.length},inclusive:!0,exact:!0,input:l.value,inst:e,continue:!t.abort})}}),Ro=P("$ZodCheckStringFormat",(e,t)=>{var i,l;st.init(e,t),e._zod.onattach.push(n=>{const o=n._zod.bag;o.format=t.format,t.pattern&&(o.patterns??(o.patterns=new Set),o.patterns.add(t.pattern))}),t.pattern?(i=e._zod).check??(i.check=n=>{t.pattern.lastIndex=0,!t.pattern.test(n.value)&&n.issues.push({origin:"string",code:"invalid_format",format:t.format,input:n.value,...t.pattern?{pattern:t.pattern.toString()}:{},inst:e,continue:!t.abort})}):(l=e._zod).check??(l.check=()=>{})}),sw=P("$ZodCheckRegex",(e,t)=>{Ro.init(e,t),e._zod.check=i=>{t.pattern.lastIndex=0,!t.pattern.test(i.value)&&i.issues.push({origin:"string",code:"invalid_format",format:"regex",input:i.value,pattern:t.pattern.toString(),inst:e,continue:!t.abort})}}),cw=P("$ZodCheckLowerCase",(e,t)=>{t.pattern??(t.pattern=Xk),Ro.init(e,t)}),fw=P("$ZodCheckUpperCase",(e,t)=>{t.pattern??(t.pattern=Qk),Ro.init(e,t)}),dw=P("$ZodCheckIncludes",(e,t)=>{st.init(e,t);const i=Nr(t.includes),l=new RegExp(typeof t.position=="number"?`^.{${t.position}}${i}`:i);t.pattern=l,e._zod.onattach.push(n=>{const o=n._zod.bag;o.patterns??(o.patterns=new Set),o.patterns.add(l)}),e._zod.check=n=>{n.value.includes(t.includes,t.position)||n.issues.push({origin:"string",code:"invalid_format",format:"includes",includes:t.includes,input:n.value,inst:e,continue:!t.abort})}}),mw=P("$ZodCheckStartsWith",(e,t)=>{st.init(e,t);const i=new RegExp(`^${Nr(t.prefix)}.*`);t.pattern??(t.pattern=i),e._zod.onattach.push(l=>{const n=l._zod.bag;n.patterns??(n.patterns=new Set),n.patterns.add(i)}),e._zod.check=l=>{l.value.startsWith(t.prefix)||l.issues.push({origin:"string",code:"invalid_format",format:"starts_with",prefix:t.prefix,input:l.value,inst:e,continue:!t.abort})}}),hw=P("$ZodCheckEndsWith",(e,t)=>{st.init(e,t);const i=new RegExp(`.*${Nr(t.suffix)}$`);t.pattern??(t.pattern=i),e._zod.onattach.push(l=>{const n=l._zod.bag;n.patterns??(n.patterns=new Set),n.patterns.add(i)}),e._zod.check=l=>{l.value.endsWith(t.suffix)||l.issues.push({origin:"string",code:"invalid_format",format:"ends_with",suffix:t.suffix,input:l.value,inst:e,continue:!t.abort})}});function m_(e,t,i){e.issues.length&&t.issues.push(...Pn(i,e.issues))}const pw=P("$ZodCheckProperty",(e,t)=>{st.init(e,t),e._zod.check=i=>{const l=t.schema._zod.run({value:i.value[t.property],issues:[]},{});if(l instanceof Promise)return l.then(n=>m_(n,i,t.property));m_(l,i,t.property)}}),gw=P("$ZodCheckMimeType",(e,t)=>{st.init(e,t);const i=new Set(t.mime);e._zod.onattach.push(l=>{l._zod.bag.mime=t.mime}),e._zod.check=l=>{i.has(l.value.type)||l.issues.push({code:"invalid_value",values:t.mime,input:l.value.type,inst:e,continue:!t.abort})}}),vw=P("$ZodCheckOverwrite",(e,t)=>{st.init(e,t),e._zod.check=i=>{i.value=t.tx(i.value)}});class yw{constructor(t=[]){this.content=[],this.indent=0,this&&(this.args=t)}indented(t){this.indent+=1,t(this),this.indent-=1}write(t){if(typeof t=="function"){t(this,{execution:"sync"}),t(this,{execution:"async"});return}const l=t.split(`
|
|
22
|
+
`).filter(s=>s),n=Math.min(...l.map(s=>s.length-s.trimStart().length)),o=l.map(s=>s.slice(n)).map(s=>" ".repeat(this.indent*2)+s);for(const s of o)this.content.push(s)}compile(){const t=Function,i=this?.args,n=[...(this?.content??[""]).map(o=>` ${o}`)];return new t(...i,n.join(`
|
|
23
|
+
`))}}const bw={major:4,minor:3,patch:2},$e=P("$ZodType",(e,t)=>{var i;e??(e={}),e._zod.def=t,e._zod.bag=e._zod.bag||{},e._zod.version=bw;const l=[...e._zod.def.checks??[]];e._zod.traits.has("$ZodCheck")&&l.unshift(e);for(const n of l)for(const o of n._zod.onattach)o(e);if(l.length===0)(i=e._zod).deferred??(i.deferred=[]),e._zod.deferred?.push(()=>{e._zod.run=e._zod.parse});else{const n=(s,f,m)=>{let d=Ci(s),p;for(const v of f){if(v._zod.def.when){if(!v._zod.def.when(s))continue}else if(d)continue;const b=s.issues.length,x=v._zod.check(s);if(x instanceof Promise&&m?.async===!1)throw new Di;if(p||x instanceof Promise)p=(p??Promise.resolve()).then(async()=>{await x,s.issues.length!==b&&(d||(d=Ci(s,b)))});else{if(s.issues.length===b)continue;d||(d=Ci(s,b))}}return p?p.then(()=>s):s},o=(s,f,m)=>{if(Ci(s))return s.aborted=!0,s;const d=n(f,l,m);if(d instanceof Promise){if(m.async===!1)throw new Di;return d.then(p=>e._zod.parse(p,m))}return e._zod.parse(d,m)};e._zod.run=(s,f)=>{if(f.skipChecks)return e._zod.parse(s,f);if(f.direction==="backward"){const d=e._zod.parse({value:s.value,issues:[]},{...f,skipChecks:!0});return d instanceof Promise?d.then(p=>o(p,s,f)):o(d,s,f)}const m=e._zod.parse(s,f);if(m instanceof Promise){if(f.async===!1)throw new Di;return m.then(d=>n(d,l,f))}return n(m,l,f)}}Te(e,"~standard",()=>({validate:n=>{try{const o=vk(e,n);return o.success?{value:o.data}:{issues:o.error?.issues}}catch{return yk(e,n).then(s=>s.success?{value:s.data}:{issues:s.error?.issues})}},vendor:"zod",version:1}))}),Io=P("$ZodString",(e,t)=>{$e.init(e,t),e._zod.pattern=[...e?._zod.bag?.patterns??[]].pop()??Bk(e._zod.bag),e._zod.parse=(i,l)=>{if(t.coerce)try{i.value=String(i.value)}catch{}return typeof i.value=="string"||i.issues.push({expected:"string",code:"invalid_type",input:i.value,inst:e}),i}}),tt=P("$ZodStringFormat",(e,t)=>{Ro.init(e,t),Io.init(e,t)}),xw=P("$ZodGUID",(e,t)=>{t.pattern??(t.pattern=Ek),tt.init(e,t)}),_w=P("$ZodUUID",(e,t)=>{if(t.version){const l={v1:1,v2:2,v3:3,v4:4,v5:5,v6:6,v7:7,v8:8}[t.version];if(l===void 0)throw new Error(`Invalid UUID version: "${t.version}"`);t.pattern??(t.pattern=Ba(l))}else t.pattern??(t.pattern=Ba());tt.init(e,t)}),Sw=P("$ZodEmail",(e,t)=>{t.pattern??(t.pattern=jk),tt.init(e,t)}),kw=P("$ZodURL",(e,t)=>{tt.init(e,t),e._zod.check=i=>{try{const l=i.value.trim(),n=new URL(l);t.hostname&&(t.hostname.lastIndex=0,t.hostname.test(n.hostname)||i.issues.push({code:"invalid_format",format:"url",note:"Invalid hostname",pattern:t.hostname.source,input:i.value,inst:e,continue:!t.abort})),t.protocol&&(t.protocol.lastIndex=0,t.protocol.test(n.protocol.endsWith(":")?n.protocol.slice(0,-1):n.protocol)||i.issues.push({code:"invalid_format",format:"url",note:"Invalid protocol",pattern:t.protocol.source,input:i.value,inst:e,continue:!t.abort})),t.normalize?i.value=n.href:i.value=l;return}catch{i.issues.push({code:"invalid_format",format:"url",input:i.value,inst:e,continue:!t.abort})}}}),ww=P("$ZodEmoji",(e,t)=>{t.pattern??(t.pattern=Nk()),tt.init(e,t)}),$w=P("$ZodNanoID",(e,t)=>{t.pattern??(t.pattern=wk),tt.init(e,t)}),Ew=P("$ZodCUID",(e,t)=>{t.pattern??(t.pattern=bk),tt.init(e,t)}),jw=P("$ZodCUID2",(e,t)=>{t.pattern??(t.pattern=xk),tt.init(e,t)}),zw=P("$ZodULID",(e,t)=>{t.pattern??(t.pattern=_k),tt.init(e,t)}),Nw=P("$ZodXID",(e,t)=>{t.pattern??(t.pattern=Sk),tt.init(e,t)}),Ow=P("$ZodKSUID",(e,t)=>{t.pattern??(t.pattern=kk),tt.init(e,t)}),Tw=P("$ZodISODateTime",(e,t)=>{t.pattern??(t.pattern=Fk(t)),tt.init(e,t)}),Cw=P("$ZodISODate",(e,t)=>{t.pattern??(t.pattern=Pk),tt.init(e,t)}),Dw=P("$ZodISOTime",(e,t)=>{t.pattern??(t.pattern=qk(t)),tt.init(e,t)}),Aw=P("$ZodISODuration",(e,t)=>{t.pattern??(t.pattern=$k),tt.init(e,t)}),Rw=P("$ZodIPv4",(e,t)=>{t.pattern??(t.pattern=Ok),tt.init(e,t),e._zod.bag.format="ipv4"}),Iw=P("$ZodIPv6",(e,t)=>{t.pattern??(t.pattern=Tk),tt.init(e,t),e._zod.bag.format="ipv6",e._zod.check=i=>{try{new URL(`http://[${i.value}]`)}catch{i.issues.push({code:"invalid_format",format:"ipv6",input:i.value,inst:e,continue:!t.abort})}}}),Uw=P("$ZodMAC",(e,t)=>{t.pattern??(t.pattern=Ck(t.delimiter)),tt.init(e,t),e._zod.bag.format="mac"}),Lw=P("$ZodCIDRv4",(e,t)=>{t.pattern??(t.pattern=Dk),tt.init(e,t)}),Mw=P("$ZodCIDRv6",(e,t)=>{t.pattern??(t.pattern=Ak),tt.init(e,t),e._zod.check=i=>{const l=i.value.split("/");try{if(l.length!==2)throw new Error;const[n,o]=l;if(!o)throw new Error;const s=Number(o);if(`${s}`!==o)throw new Error;if(s<0||s>128)throw new Error;new URL(`http://[${n}]`)}catch{i.issues.push({code:"invalid_format",format:"cidrv6",input:i.value,inst:e,continue:!t.abort})}}});function Zp(e){if(e==="")return!0;if(e.length%4!==0)return!1;try{return atob(e),!0}catch{return!1}}const Pw=P("$ZodBase64",(e,t)=>{t.pattern??(t.pattern=Rk),tt.init(e,t),e._zod.bag.contentEncoding="base64",e._zod.check=i=>{Zp(i.value)||i.issues.push({code:"invalid_format",format:"base64",input:i.value,inst:e,continue:!t.abort})}});function Zw(e){if(!Ip.test(e))return!1;const t=e.replace(/[-_]/g,l=>l==="-"?"+":"/"),i=t.padEnd(Math.ceil(t.length/4)*4,"=");return Zp(i)}const qw=P("$ZodBase64URL",(e,t)=>{t.pattern??(t.pattern=Ip),tt.init(e,t),e._zod.bag.contentEncoding="base64url",e._zod.check=i=>{Zw(i.value)||i.issues.push({code:"invalid_format",format:"base64url",input:i.value,inst:e,continue:!t.abort})}}),Fw=P("$ZodE164",(e,t)=>{t.pattern??(t.pattern=Lk),tt.init(e,t)});function Bw(e,t=null){try{const i=e.split(".");if(i.length!==3)return!1;const[l]=i;if(!l)return!1;const n=JSON.parse(atob(l));return!("typ"in n&&n?.typ!=="JWT"||!n.alg||t&&(!("alg"in n)||n.alg!==t))}catch{return!1}}const Hw=P("$ZodJWT",(e,t)=>{tt.init(e,t),e._zod.check=i=>{Bw(i.value,t.alg)||i.issues.push({code:"invalid_format",format:"jwt",input:i.value,inst:e,continue:!t.abort})}}),Gw=P("$ZodCustomStringFormat",(e,t)=>{tt.init(e,t),e._zod.check=i=>{t.fn(i.value)||i.issues.push({code:"invalid_format",format:t.format,input:i.value,inst:e,continue:!t.abort})}}),qp=P("$ZodNumber",(e,t)=>{$e.init(e,t),e._zod.pattern=e._zod.bag.pattern??Up,e._zod.parse=(i,l)=>{if(t.coerce)try{i.value=Number(i.value)}catch{}const n=i.value;if(typeof n=="number"&&!Number.isNaN(n)&&Number.isFinite(n))return i;const o=typeof n=="number"?Number.isNaN(n)?"NaN":Number.isFinite(n)?void 0:"Infinity":void 0;return i.issues.push({expected:"number",code:"invalid_type",input:n,inst:e,...o?{received:o}:{}}),i}}),Vw=P("$ZodNumberFormat",(e,t)=>{tw.init(e,t),qp.init(e,t)}),Fp=P("$ZodBoolean",(e,t)=>{$e.init(e,t),e._zod.pattern=Vk,e._zod.parse=(i,l)=>{if(t.coerce)try{i.value=!!i.value}catch{}const n=i.value;return typeof n=="boolean"||i.issues.push({expected:"boolean",code:"invalid_type",input:n,inst:e}),i}}),Bp=P("$ZodBigInt",(e,t)=>{$e.init(e,t),e._zod.pattern=Hk,e._zod.parse=(i,l)=>{if(t.coerce)try{i.value=BigInt(i.value)}catch{}return typeof i.value=="bigint"||i.issues.push({expected:"bigint",code:"invalid_type",input:i.value,inst:e}),i}}),Yw=P("$ZodBigIntFormat",(e,t)=>{nw.init(e,t),Bp.init(e,t)}),Jw=P("$ZodSymbol",(e,t)=>{$e.init(e,t),e._zod.parse=(i,l)=>{const n=i.value;return typeof n=="symbol"||i.issues.push({expected:"symbol",code:"invalid_type",input:n,inst:e}),i}}),Xw=P("$ZodUndefined",(e,t)=>{$e.init(e,t),e._zod.pattern=Jk,e._zod.values=new Set([void 0]),e._zod.optin="optional",e._zod.optout="optional",e._zod.parse=(i,l)=>{const n=i.value;return typeof n>"u"||i.issues.push({expected:"undefined",code:"invalid_type",input:n,inst:e}),i}}),Qw=P("$ZodNull",(e,t)=>{$e.init(e,t),e._zod.pattern=Yk,e._zod.values=new Set([null]),e._zod.parse=(i,l)=>{const n=i.value;return n===null||i.issues.push({expected:"null",code:"invalid_type",input:n,inst:e}),i}}),Kw=P("$ZodAny",(e,t)=>{$e.init(e,t),e._zod.parse=i=>i}),Ww=P("$ZodUnknown",(e,t)=>{$e.init(e,t),e._zod.parse=i=>i}),e$=P("$ZodNever",(e,t)=>{$e.init(e,t),e._zod.parse=(i,l)=>(i.issues.push({expected:"never",code:"invalid_type",input:i.value,inst:e}),i)}),t$=P("$ZodVoid",(e,t)=>{$e.init(e,t),e._zod.parse=(i,l)=>{const n=i.value;return typeof n>"u"||i.issues.push({expected:"void",code:"invalid_type",input:n,inst:e}),i}}),n$=P("$ZodDate",(e,t)=>{$e.init(e,t),e._zod.parse=(i,l)=>{if(t.coerce)try{i.value=new Date(i.value)}catch{}const n=i.value,o=n instanceof Date;return o&&!Number.isNaN(n.getTime())||i.issues.push({expected:"date",code:"invalid_type",input:n,...o?{received:"Invalid Date"}:{},inst:e}),i}});function h_(e,t,i){e.issues.length&&t.issues.push(...Pn(i,e.issues)),t.value[i]=e.value}const r$=P("$ZodArray",(e,t)=>{$e.init(e,t),e._zod.parse=(i,l)=>{const n=i.value;if(!Array.isArray(n))return i.issues.push({expected:"array",code:"invalid_type",input:n,inst:e}),i;i.value=Array(n.length);const o=[];for(let s=0;s<n.length;s++){const f=n[s],m=t.element._zod.run({value:f,issues:[]},l);m instanceof Promise?o.push(m.then(d=>h_(d,i,s))):h_(m,i,s)}return o.length?Promise.all(o).then(()=>i):i}});function Zs(e,t,i,l,n){if(e.issues.length){if(n&&!(i in l))return;t.issues.push(...Pn(i,e.issues))}e.value===void 0?i in l&&(t.value[i]=void 0):t.value[i]=e.value}function i$(e){const t=Object.keys(e.shape);for(const l of t)if(!e.shape?.[l]?._zod?.traits?.has("$ZodType"))throw new Error(`Invalid element at key "${l}": expected a Zod schema`);const i=ek(e.shape);return{...e,keys:t,keySet:new Set(t),numKeys:t.length,optionalKeys:new Set(i)}}function a$(e,t,i,l,n,o){const s=[],f=n.keySet,m=n.catchall._zod,d=m.def.type,p=m.optout==="optional";for(const v in t){if(f.has(v))continue;if(d==="never"){s.push(v);continue}const b=m.run({value:t[v],issues:[]},l);b instanceof Promise?e.push(b.then(x=>Zs(x,i,v,t,p))):Zs(b,i,v,t,p)}return s.length&&i.issues.push({code:"unrecognized_keys",keys:s,input:t,inst:o}),e.length?Promise.all(e).then(()=>i):i}const l$=P("$ZodObject",(e,t)=>{if($e.init(e,t),!Object.getOwnPropertyDescriptor(t,"shape")?.get){const f=t.shape;Object.defineProperty(t,"shape",{get:()=>{const m={...f};return Object.defineProperty(t,"shape",{value:m}),m}})}const l=zo(()=>i$(t));Te(e._zod,"propValues",()=>{const f=t.shape,m={};for(const d in f){const p=f[d]._zod;if(p.values){m[d]??(m[d]=new Set);for(const v of p.values)m[d].add(v)}}return m});const n=qa,o=t.catchall;let s;e._zod.parse=(f,m)=>{s??(s=l.value);const d=f.value;if(!n(d))return f.issues.push({expected:"object",code:"invalid_type",input:d,inst:e}),f;f.value={};const p=[],v=s.shape;for(const b of s.keys){const x=v[b],S=x._zod.optout==="optional",w=x._zod.run({value:d[b],issues:[]},m);w instanceof Promise?p.push(w.then(j=>Zs(j,f,b,d,S))):Zs(w,f,b,d,S)}return o?a$(p,d,f,m,l.value,e):p.length?Promise.all(p).then(()=>f):f}}),o$=P("$ZodObjectJIT",(e,t)=>{l$.init(e,t);const i=e._zod.parse,l=zo(()=>i$(t)),n=b=>{const x=new yw(["shape","payload","ctx"]),S=l.value,w=N=>{const G=Jh(N);return`shape[${G}]._zod.run({ value: input[${G}], issues: [] }, ctx)`};x.write("const input = payload.value;");const j=Object.create(null);let E=0;for(const N of S.keys)j[N]=`key_${E++}`;x.write("const newResult = {};");for(const N of S.keys){const G=j[N],J=Jh(N),X=b[N]?._zod?.optout==="optional";x.write(`const ${G} = ${w(N)};`),X?x.write(`
|
|
24
|
+
if (${G}.issues.length) {
|
|
25
|
+
if (${J} in input) {
|
|
26
|
+
payload.issues = payload.issues.concat(${G}.issues.map(iss => ({
|
|
27
|
+
...iss,
|
|
28
|
+
path: iss.path ? [${J}, ...iss.path] : [${J}]
|
|
29
|
+
})));
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
if (${G}.value === undefined) {
|
|
34
|
+
if (${J} in input) {
|
|
35
|
+
newResult[${J}] = undefined;
|
|
36
|
+
}
|
|
37
|
+
} else {
|
|
38
|
+
newResult[${J}] = ${G}.value;
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
`):x.write(`
|
|
42
|
+
if (${G}.issues.length) {
|
|
43
|
+
payload.issues = payload.issues.concat(${G}.issues.map(iss => ({
|
|
44
|
+
...iss,
|
|
45
|
+
path: iss.path ? [${J}, ...iss.path] : [${J}]
|
|
46
|
+
})));
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
if (${G}.value === undefined) {
|
|
50
|
+
if (${J} in input) {
|
|
51
|
+
newResult[${J}] = undefined;
|
|
52
|
+
}
|
|
53
|
+
} else {
|
|
54
|
+
newResult[${J}] = ${G}.value;
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
`)}x.write("payload.value = newResult;"),x.write("return payload;");const O=x.compile();return(N,G)=>O(b,N,G)};let o;const s=qa,f=!Ls.jitless,d=f&&KS.value,p=t.catchall;let v;e._zod.parse=(b,x)=>{v??(v=l.value);const S=b.value;return s(S)?f&&d&&x?.async===!1&&x.jitless!==!0?(o||(o=n(t.shape)),b=o(b,x),p?a$([],S,b,x,v,e):b):i(b,x):(b.issues.push({expected:"object",code:"invalid_type",input:S,inst:e}),b)}});function p_(e,t,i,l){for(const o of e)if(o.issues.length===0)return t.value=o.value,t;const n=e.filter(o=>!Ci(o));return n.length===1?(t.value=n[0].value,n[0]):(t.issues.push({code:"invalid_union",input:t.value,inst:i,errors:e.map(o=>o.issues.map(s=>Dn(s,l,It())))}),t)}const ac=P("$ZodUnion",(e,t)=>{$e.init(e,t),Te(e._zod,"optin",()=>t.options.some(n=>n._zod.optin==="optional")?"optional":void 0),Te(e._zod,"optout",()=>t.options.some(n=>n._zod.optout==="optional")?"optional":void 0),Te(e._zod,"values",()=>{if(t.options.every(n=>n._zod.values))return new Set(t.options.flatMap(n=>Array.from(n._zod.values)))}),Te(e._zod,"pattern",()=>{if(t.options.every(n=>n._zod.pattern)){const n=t.options.map(o=>o._zod.pattern);return new RegExp(`^(${n.map(o=>tc(o.source)).join("|")})$`)}});const i=t.options.length===1,l=t.options[0]._zod.run;e._zod.parse=(n,o)=>{if(i)return l(n,o);let s=!1;const f=[];for(const m of t.options){const d=m._zod.run({value:n.value,issues:[]},o);if(d instanceof Promise)f.push(d),s=!0;else{if(d.issues.length===0)return d;f.push(d)}}return s?Promise.all(f).then(m=>p_(m,n,e,o)):p_(f,n,e,o)}});function g_(e,t,i,l){const n=e.filter(o=>o.issues.length===0);return n.length===1?(t.value=n[0].value,t):(n.length===0?t.issues.push({code:"invalid_union",input:t.value,inst:i,errors:e.map(o=>o.issues.map(s=>Dn(s,l,It())))}):t.issues.push({code:"invalid_union",input:t.value,inst:i,errors:[],inclusive:!1}),t)}const u$=P("$ZodXor",(e,t)=>{ac.init(e,t),t.inclusive=!1;const i=t.options.length===1,l=t.options[0]._zod.run;e._zod.parse=(n,o)=>{if(i)return l(n,o);let s=!1;const f=[];for(const m of t.options){const d=m._zod.run({value:n.value,issues:[]},o);d instanceof Promise?(f.push(d),s=!0):f.push(d)}return s?Promise.all(f).then(m=>g_(m,n,e,o)):g_(f,n,e,o)}}),s$=P("$ZodDiscriminatedUnion",(e,t)=>{t.inclusive=!1,ac.init(e,t);const i=e._zod.parse;Te(e._zod,"propValues",()=>{const n={};for(const o of t.options){const s=o._zod.propValues;if(!s||Object.keys(s).length===0)throw new Error(`Invalid discriminated union option at index "${t.options.indexOf(o)}"`);for(const[f,m]of Object.entries(s)){n[f]||(n[f]=new Set);for(const d of m)n[f].add(d)}}return n});const l=zo(()=>{const n=t.options,o=new Map;for(const s of n){const f=s._zod.propValues?.[t.discriminator];if(!f||f.size===0)throw new Error(`Invalid discriminated union option at index "${t.options.indexOf(s)}"`);for(const m of f){if(o.has(m))throw new Error(`Duplicate discriminator value "${String(m)}"`);o.set(m,s)}}return o});e._zod.parse=(n,o)=>{const s=n.value;if(!qa(s))return n.issues.push({code:"invalid_type",expected:"object",input:s,inst:e}),n;const f=l.value.get(s?.[t.discriminator]);return f?f._zod.run(n,o):t.unionFallback?i(n,o):(n.issues.push({code:"invalid_union",errors:[],note:"No matching discriminator",discriminator:t.discriminator,input:s,path:[t.discriminator],inst:e}),n)}}),c$=P("$ZodIntersection",(e,t)=>{$e.init(e,t),e._zod.parse=(i,l)=>{const n=i.value,o=t.left._zod.run({value:n,issues:[]},l),s=t.right._zod.run({value:n,issues:[]},l);return o instanceof Promise||s instanceof Promise?Promise.all([o,s]).then(([m,d])=>v_(i,m,d)):v_(i,o,s)}});function Kh(e,t){if(e===t)return{valid:!0,data:e};if(e instanceof Date&&t instanceof Date&&+e==+t)return{valid:!0,data:e};if(Li(e)&&Li(t)){const i=Object.keys(t),l=Object.keys(e).filter(o=>i.indexOf(o)!==-1),n={...e,...t};for(const o of l){const s=Kh(e[o],t[o]);if(!s.valid)return{valid:!1,mergeErrorPath:[o,...s.mergeErrorPath]};n[o]=s.data}return{valid:!0,data:n}}if(Array.isArray(e)&&Array.isArray(t)){if(e.length!==t.length)return{valid:!1,mergeErrorPath:[]};const i=[];for(let l=0;l<e.length;l++){const n=e[l],o=t[l],s=Kh(n,o);if(!s.valid)return{valid:!1,mergeErrorPath:[l,...s.mergeErrorPath]};i.push(s.data)}return{valid:!0,data:i}}return{valid:!1,mergeErrorPath:[]}}function v_(e,t,i){const l=new Map;let n;for(const f of t.issues)if(f.code==="unrecognized_keys"){n??(n=f);for(const m of f.keys)l.has(m)||l.set(m,{}),l.get(m).l=!0}else e.issues.push(f);for(const f of i.issues)if(f.code==="unrecognized_keys")for(const m of f.keys)l.has(m)||l.set(m,{}),l.get(m).r=!0;else e.issues.push(f);const o=[...l].filter(([,f])=>f.l&&f.r).map(([f])=>f);if(o.length&&n&&e.issues.push({...n,keys:o}),Ci(e))return e;const s=Kh(t.value,i.value);if(!s.valid)throw new Error(`Unmergable intersection. Error path: ${JSON.stringify(s.mergeErrorPath)}`);return e.value=s.data,e}const Hp=P("$ZodTuple",(e,t)=>{$e.init(e,t);const i=t.items;e._zod.parse=(l,n)=>{const o=l.value;if(!Array.isArray(o))return l.issues.push({input:o,inst:e,expected:"tuple",code:"invalid_type"}),l;l.value=[];const s=[],f=[...i].reverse().findIndex(p=>p._zod.optin!=="optional"),m=f===-1?0:i.length-f;if(!t.rest){const p=o.length>i.length,v=o.length<m-1;if(p||v)return l.issues.push({...p?{code:"too_big",maximum:i.length,inclusive:!0}:{code:"too_small",minimum:i.length},input:o,inst:e,origin:"array"}),l}let d=-1;for(const p of i){if(d++,d>=o.length&&d>=m)continue;const v=p._zod.run({value:o[d],issues:[]},n);v instanceof Promise?s.push(v.then(b=>_s(b,l,d))):_s(v,l,d)}if(t.rest){const p=o.slice(i.length);for(const v of p){d++;const b=t.rest._zod.run({value:v,issues:[]},n);b instanceof Promise?s.push(b.then(x=>_s(x,l,d))):_s(b,l,d)}}return s.length?Promise.all(s).then(()=>l):l}});function _s(e,t,i){e.issues.length&&t.issues.push(...Pn(i,e.issues)),t.value[i]=e.value}const f$=P("$ZodRecord",(e,t)=>{$e.init(e,t),e._zod.parse=(i,l)=>{const n=i.value;if(!Li(n))return i.issues.push({expected:"record",code:"invalid_type",input:n,inst:e}),i;const o=[],s=t.keyType._zod.values;if(s){i.value={};const f=new Set;for(const d of s)if(typeof d=="string"||typeof d=="number"||typeof d=="symbol"){f.add(typeof d=="number"?d.toString():d);const p=t.valueType._zod.run({value:n[d],issues:[]},l);p instanceof Promise?o.push(p.then(v=>{v.issues.length&&i.issues.push(...Pn(d,v.issues)),i.value[d]=v.value})):(p.issues.length&&i.issues.push(...Pn(d,p.issues)),i.value[d]=p.value)}let m;for(const d in n)f.has(d)||(m=m??[],m.push(d));m&&m.length>0&&i.issues.push({code:"unrecognized_keys",input:n,inst:e,keys:m})}else{i.value={};for(const f of Reflect.ownKeys(n)){if(f==="__proto__")continue;let m=t.keyType._zod.run({value:f,issues:[]},l);if(m instanceof Promise)throw new Error("Async schemas not supported in object keys currently");if(typeof f=="string"&&Up.test(f)&&m.issues.length&&m.issues.some(v=>v.code==="invalid_type"&&v.expected==="number")){const v=t.keyType._zod.run({value:Number(f),issues:[]},l);if(v instanceof Promise)throw new Error("Async schemas not supported in object keys currently");v.issues.length===0&&(m=v)}if(m.issues.length){t.mode==="loose"?i.value[f]=n[f]:i.issues.push({code:"invalid_key",origin:"record",issues:m.issues.map(v=>Dn(v,l,It())),input:f,path:[f],inst:e});continue}const p=t.valueType._zod.run({value:n[f],issues:[]},l);p instanceof Promise?o.push(p.then(v=>{v.issues.length&&i.issues.push(...Pn(f,v.issues)),i.value[m.value]=v.value})):(p.issues.length&&i.issues.push(...Pn(f,p.issues)),i.value[m.value]=p.value)}}return o.length?Promise.all(o).then(()=>i):i}}),d$=P("$ZodMap",(e,t)=>{$e.init(e,t),e._zod.parse=(i,l)=>{const n=i.value;if(!(n instanceof Map))return i.issues.push({expected:"map",code:"invalid_type",input:n,inst:e}),i;const o=[];i.value=new Map;for(const[s,f]of n){const m=t.keyType._zod.run({value:s,issues:[]},l),d=t.valueType._zod.run({value:f,issues:[]},l);m instanceof Promise||d instanceof Promise?o.push(Promise.all([m,d]).then(([p,v])=>{y_(p,v,i,s,n,e,l)})):y_(m,d,i,s,n,e,l)}return o.length?Promise.all(o).then(()=>i):i}});function y_(e,t,i,l,n,o,s){e.issues.length&&(Ps.has(typeof l)?i.issues.push(...Pn(l,e.issues)):i.issues.push({code:"invalid_key",origin:"map",input:n,inst:o,issues:e.issues.map(f=>Dn(f,s,It()))})),t.issues.length&&(Ps.has(typeof l)?i.issues.push(...Pn(l,t.issues)):i.issues.push({origin:"map",code:"invalid_element",input:n,inst:o,key:l,issues:t.issues.map(f=>Dn(f,s,It()))})),i.value.set(e.value,t.value)}const m$=P("$ZodSet",(e,t)=>{$e.init(e,t),e._zod.parse=(i,l)=>{const n=i.value;if(!(n instanceof Set))return i.issues.push({input:n,inst:e,expected:"set",code:"invalid_type"}),i;const o=[];i.value=new Set;for(const s of n){const f=t.valueType._zod.run({value:s,issues:[]},l);f instanceof Promise?o.push(f.then(m=>b_(m,i))):b_(f,i)}return o.length?Promise.all(o).then(()=>i):i}});function b_(e,t){e.issues.length&&t.issues.push(...e.issues),t.value.add(e.value)}const h$=P("$ZodEnum",(e,t)=>{$e.init(e,t);const i=ec(t.entries),l=new Set(i);e._zod.values=l,e._zod.pattern=new RegExp(`^(${i.filter(n=>Ps.has(typeof n)).map(n=>typeof n=="string"?Nr(n):n.toString()).join("|")})$`),e._zod.parse=(n,o)=>{const s=n.value;return l.has(s)||n.issues.push({code:"invalid_value",values:i,input:s,inst:e}),n}}),p$=P("$ZodLiteral",(e,t)=>{if($e.init(e,t),t.values.length===0)throw new Error("Cannot create literal schema with no valid values");const i=new Set(t.values);e._zod.values=i,e._zod.pattern=new RegExp(`^(${t.values.map(l=>typeof l=="string"?Nr(l):l?Nr(l.toString()):String(l)).join("|")})$`),e._zod.parse=(l,n)=>{const o=l.value;return i.has(o)||l.issues.push({code:"invalid_value",values:t.values,input:o,inst:e}),l}}),g$=P("$ZodFile",(e,t)=>{$e.init(e,t),e._zod.parse=(i,l)=>{const n=i.value;return n instanceof File||i.issues.push({expected:"file",code:"invalid_type",input:n,inst:e}),i}}),v$=P("$ZodTransform",(e,t)=>{$e.init(e,t),e._zod.parse=(i,l)=>{if(l.direction==="backward")throw new Ws(e.constructor.name);const n=t.transform(i.value,i);if(l.async)return(n instanceof Promise?n:Promise.resolve(n)).then(s=>(i.value=s,i));if(n instanceof Promise)throw new Di;return i.value=n,i}});function x_(e,t){return e.issues.length&&t===void 0?{issues:[],value:void 0}:e}const Gp=P("$ZodOptional",(e,t)=>{$e.init(e,t),e._zod.optin="optional",e._zod.optout="optional",Te(e._zod,"values",()=>t.innerType._zod.values?new Set([...t.innerType._zod.values,void 0]):void 0),Te(e._zod,"pattern",()=>{const i=t.innerType._zod.pattern;return i?new RegExp(`^(${tc(i.source)})?$`):void 0}),e._zod.parse=(i,l)=>{if(t.innerType._zod.optin==="optional"){const n=t.innerType._zod.run(i,l);return n instanceof Promise?n.then(o=>x_(o,i.value)):x_(n,i.value)}return i.value===void 0?i:t.innerType._zod.run(i,l)}}),y$=P("$ZodExactOptional",(e,t)=>{Gp.init(e,t),Te(e._zod,"values",()=>t.innerType._zod.values),Te(e._zod,"pattern",()=>t.innerType._zod.pattern),e._zod.parse=(i,l)=>t.innerType._zod.run(i,l)}),b$=P("$ZodNullable",(e,t)=>{$e.init(e,t),Te(e._zod,"optin",()=>t.innerType._zod.optin),Te(e._zod,"optout",()=>t.innerType._zod.optout),Te(e._zod,"pattern",()=>{const i=t.innerType._zod.pattern;return i?new RegExp(`^(${tc(i.source)}|null)$`):void 0}),Te(e._zod,"values",()=>t.innerType._zod.values?new Set([...t.innerType._zod.values,null]):void 0),e._zod.parse=(i,l)=>i.value===null?i:t.innerType._zod.run(i,l)}),x$=P("$ZodDefault",(e,t)=>{$e.init(e,t),e._zod.optin="optional",Te(e._zod,"values",()=>t.innerType._zod.values),e._zod.parse=(i,l)=>{if(l.direction==="backward")return t.innerType._zod.run(i,l);if(i.value===void 0)return i.value=t.defaultValue,i;const n=t.innerType._zod.run(i,l);return n instanceof Promise?n.then(o=>__(o,t)):__(n,t)}});function __(e,t){return e.value===void 0&&(e.value=t.defaultValue),e}const _$=P("$ZodPrefault",(e,t)=>{$e.init(e,t),e._zod.optin="optional",Te(e._zod,"values",()=>t.innerType._zod.values),e._zod.parse=(i,l)=>(l.direction==="backward"||i.value===void 0&&(i.value=t.defaultValue),t.innerType._zod.run(i,l))}),S$=P("$ZodNonOptional",(e,t)=>{$e.init(e,t),Te(e._zod,"values",()=>{const i=t.innerType._zod.values;return i?new Set([...i].filter(l=>l!==void 0)):void 0}),e._zod.parse=(i,l)=>{const n=t.innerType._zod.run(i,l);return n instanceof Promise?n.then(o=>S_(o,e)):S_(n,e)}});function S_(e,t){return!e.issues.length&&e.value===void 0&&e.issues.push({code:"invalid_type",expected:"nonoptional",input:e.value,inst:t}),e}const k$=P("$ZodSuccess",(e,t)=>{$e.init(e,t),e._zod.parse=(i,l)=>{if(l.direction==="backward")throw new Ws("ZodSuccess");const n=t.innerType._zod.run(i,l);return n instanceof Promise?n.then(o=>(i.value=o.issues.length===0,i)):(i.value=n.issues.length===0,i)}}),w$=P("$ZodCatch",(e,t)=>{$e.init(e,t),Te(e._zod,"optin",()=>t.innerType._zod.optin),Te(e._zod,"optout",()=>t.innerType._zod.optout),Te(e._zod,"values",()=>t.innerType._zod.values),e._zod.parse=(i,l)=>{if(l.direction==="backward")return t.innerType._zod.run(i,l);const n=t.innerType._zod.run(i,l);return n instanceof Promise?n.then(o=>(i.value=o.value,o.issues.length&&(i.value=t.catchValue({...i,error:{issues:o.issues.map(s=>Dn(s,l,It()))},input:i.value}),i.issues=[]),i)):(i.value=n.value,n.issues.length&&(i.value=t.catchValue({...i,error:{issues:n.issues.map(o=>Dn(o,l,It()))},input:i.value}),i.issues=[]),i)}}),$$=P("$ZodNaN",(e,t)=>{$e.init(e,t),e._zod.parse=(i,l)=>((typeof i.value!="number"||!Number.isNaN(i.value))&&i.issues.push({input:i.value,inst:e,expected:"nan",code:"invalid_type"}),i)}),E$=P("$ZodPipe",(e,t)=>{$e.init(e,t),Te(e._zod,"values",()=>t.in._zod.values),Te(e._zod,"optin",()=>t.in._zod.optin),Te(e._zod,"optout",()=>t.out._zod.optout),Te(e._zod,"propValues",()=>t.in._zod.propValues),e._zod.parse=(i,l)=>{if(l.direction==="backward"){const o=t.out._zod.run(i,l);return o instanceof Promise?o.then(s=>Ss(s,t.in,l)):Ss(o,t.in,l)}const n=t.in._zod.run(i,l);return n instanceof Promise?n.then(o=>Ss(o,t.out,l)):Ss(n,t.out,l)}});function Ss(e,t,i){return e.issues.length?(e.aborted=!0,e):t._zod.run({value:e.value,issues:e.issues},i)}const Vp=P("$ZodCodec",(e,t)=>{$e.init(e,t),Te(e._zod,"values",()=>t.in._zod.values),Te(e._zod,"optin",()=>t.in._zod.optin),Te(e._zod,"optout",()=>t.out._zod.optout),Te(e._zod,"propValues",()=>t.in._zod.propValues),e._zod.parse=(i,l)=>{if((l.direction||"forward")==="forward"){const o=t.in._zod.run(i,l);return o instanceof Promise?o.then(s=>ks(s,t,l)):ks(o,t,l)}else{const o=t.out._zod.run(i,l);return o instanceof Promise?o.then(s=>ks(s,t,l)):ks(o,t,l)}}});function ks(e,t,i){if(e.issues.length)return e.aborted=!0,e;if((i.direction||"forward")==="forward"){const n=t.transform(e.value,e);return n instanceof Promise?n.then(o=>ws(e,o,t.out,i)):ws(e,n,t.out,i)}else{const n=t.reverseTransform(e.value,e);return n instanceof Promise?n.then(o=>ws(e,o,t.in,i)):ws(e,n,t.in,i)}}function ws(e,t,i,l){return e.issues.length?(e.aborted=!0,e):i._zod.run({value:t,issues:e.issues},l)}const j$=P("$ZodReadonly",(e,t)=>{$e.init(e,t),Te(e._zod,"propValues",()=>t.innerType._zod.propValues),Te(e._zod,"values",()=>t.innerType._zod.values),Te(e._zod,"optin",()=>t.innerType?._zod?.optin),Te(e._zod,"optout",()=>t.innerType?._zod?.optout),e._zod.parse=(i,l)=>{if(l.direction==="backward")return t.innerType._zod.run(i,l);const n=t.innerType._zod.run(i,l);return n instanceof Promise?n.then(k_):k_(n)}});function k_(e){return e.value=Object.freeze(e.value),e}const z$=P("$ZodTemplateLiteral",(e,t)=>{$e.init(e,t);const i=[];for(const l of t.parts)if(typeof l=="object"&&l!==null){if(!l._zod.pattern)throw new Error(`Invalid template literal part, no pattern found: ${[...l._zod.traits].shift()}`);const n=l._zod.pattern instanceof RegExp?l._zod.pattern.source:l._zod.pattern;if(!n)throw new Error(`Invalid template literal part: ${l._zod.traits}`);const o=n.startsWith("^")?1:0,s=n.endsWith("$")?n.length-1:n.length;i.push(n.slice(o,s))}else if(l===null||WS.has(typeof l))i.push(Nr(`${l}`));else throw new Error(`Invalid template literal part: ${l}`);e._zod.pattern=new RegExp(`^${i.join("")}$`),e._zod.parse=(l,n)=>typeof l.value!="string"?(l.issues.push({input:l.value,inst:e,expected:"string",code:"invalid_type"}),l):(e._zod.pattern.lastIndex=0,e._zod.pattern.test(l.value)||l.issues.push({input:l.value,inst:e,code:"invalid_format",format:t.format??"template_literal",pattern:e._zod.pattern.source}),l)}),N$=P("$ZodFunction",(e,t)=>($e.init(e,t),e._def=t,e._zod.def=t,e.implement=i=>{if(typeof i!="function")throw new Error("implement() must be called with a function");return function(...l){const n=e._def.input?Xh(e._def.input,l):l,o=Reflect.apply(i,this,n);return e._def.output?Xh(e._def.output,o):o}},e.implementAsync=i=>{if(typeof i!="function")throw new Error("implementAsync() must be called with a function");return async function(...l){const n=e._def.input?await Qh(e._def.input,l):l,o=await Reflect.apply(i,this,n);return e._def.output?await Qh(e._def.output,o):o}},e._zod.parse=(i,l)=>typeof i.value!="function"?(i.issues.push({code:"invalid_type",expected:"function",input:i.value,inst:e}),i):(e._def.output&&e._def.output._zod.def.type==="promise"?i.value=e.implementAsync(i.value):i.value=e.implement(i.value),i),e.input=(...i)=>{const l=e.constructor;return Array.isArray(i[0])?new l({type:"function",input:new Hp({type:"tuple",items:i[0],rest:i[1]}),output:e._def.output}):new l({type:"function",input:i[0],output:e._def.output})},e.output=i=>{const l=e.constructor;return new l({type:"function",input:e._def.input,output:i})},e)),O$=P("$ZodPromise",(e,t)=>{$e.init(e,t),e._zod.parse=(i,l)=>Promise.resolve(i.value).then(n=>t.innerType._zod.run({value:n,issues:[]},l))}),T$=P("$ZodLazy",(e,t)=>{$e.init(e,t),Te(e._zod,"innerType",()=>t.getter()),Te(e._zod,"pattern",()=>e._zod.innerType?._zod?.pattern),Te(e._zod,"propValues",()=>e._zod.innerType?._zod?.propValues),Te(e._zod,"optin",()=>e._zod.innerType?._zod?.optin??void 0),Te(e._zod,"optout",()=>e._zod.innerType?._zod?.optout??void 0),e._zod.parse=(i,l)=>e._zod.innerType._zod.run(i,l)}),C$=P("$ZodCustom",(e,t)=>{st.init(e,t),$e.init(e,t),e._zod.parse=(i,l)=>i,e._zod.check=i=>{const l=i.value,n=t.fn(l);if(n instanceof Promise)return n.then(o=>w_(o,i,l,e));w_(n,i,l,e)}});function w_(e,t,i,l){if(!e){const n={code:"custom",input:i,inst:l,path:[...l._zod.def.path??[]],continue:!l._zod.def.abort};l._zod.def.params&&(n.params=l._zod.def.params),t.issues.push(Fa(n))}}const tA=()=>{const e={string:{unit:"حرف",verb:"أن يحوي"},file:{unit:"بايت",verb:"أن يحوي"},array:{unit:"عنصر",verb:"أن يحوي"},set:{unit:"عنصر",verb:"أن يحوي"}};function t(n){return e[n]??null}const i={regex:"مدخل",email:"بريد إلكتروني",url:"رابط",emoji:"إيموجي",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"تاريخ ووقت بمعيار ISO",date:"تاريخ بمعيار ISO",time:"وقت بمعيار ISO",duration:"مدة بمعيار ISO",ipv4:"عنوان IPv4",ipv6:"عنوان IPv6",cidrv4:"مدى عناوين بصيغة IPv4",cidrv6:"مدى عناوين بصيغة IPv6",base64:"نَص بترميز base64-encoded",base64url:"نَص بترميز base64url-encoded",json_string:"نَص على هيئة JSON",e164:"رقم هاتف بمعيار E.164",jwt:"JWT",template_literal:"مدخل"},l={nan:"NaN"};return n=>{switch(n.code){case"invalid_type":{const o=l[n.expected]??n.expected,s=Se(n.input),f=l[s]??s;return/^[A-Z]/.test(n.expected)?`مدخلات غير مقبولة: يفترض إدخال instanceof ${n.expected}، ولكن تم إدخال ${f}`:`مدخلات غير مقبولة: يفترض إدخال ${o}، ولكن تم إدخال ${f}`}case"invalid_value":return n.values.length===1?`مدخلات غير مقبولة: يفترض إدخال ${xe(n.values[0])}`:`اختيار غير مقبول: يتوقع انتقاء أحد هذه الخيارات: ${ae(n.values,"|")}`;case"too_big":{const o=n.inclusive?"<=":"<",s=t(n.origin);return s?` أكبر من اللازم: يفترض أن تكون ${n.origin??"القيمة"} ${o} ${n.maximum.toString()} ${s.unit??"عنصر"}`:`أكبر من اللازم: يفترض أن تكون ${n.origin??"القيمة"} ${o} ${n.maximum.toString()}`}case"too_small":{const o=n.inclusive?">=":">",s=t(n.origin);return s?`أصغر من اللازم: يفترض لـ ${n.origin} أن يكون ${o} ${n.minimum.toString()} ${s.unit}`:`أصغر من اللازم: يفترض لـ ${n.origin} أن يكون ${o} ${n.minimum.toString()}`}case"invalid_format":{const o=n;return o.format==="starts_with"?`نَص غير مقبول: يجب أن يبدأ بـ "${n.prefix}"`:o.format==="ends_with"?`نَص غير مقبول: يجب أن ينتهي بـ "${o.suffix}"`:o.format==="includes"?`نَص غير مقبول: يجب أن يتضمَّن "${o.includes}"`:o.format==="regex"?`نَص غير مقبول: يجب أن يطابق النمط ${o.pattern}`:`${i[o.format]??n.format} غير مقبول`}case"not_multiple_of":return`رقم غير مقبول: يجب أن يكون من مضاعفات ${n.divisor}`;case"unrecognized_keys":return`معرف${n.keys.length>1?"ات":""} غريب${n.keys.length>1?"ة":""}: ${ae(n.keys,"، ")}`;case"invalid_key":return`معرف غير مقبول في ${n.origin}`;case"invalid_union":return"مدخل غير مقبول";case"invalid_element":return`مدخل غير مقبول في ${n.origin}`;default:return"مدخل غير مقبول"}}};function nA(){return{localeError:tA()}}const rA=()=>{const e={string:{unit:"simvol",verb:"olmalıdır"},file:{unit:"bayt",verb:"olmalıdır"},array:{unit:"element",verb:"olmalıdır"},set:{unit:"element",verb:"olmalıdır"}};function t(n){return e[n]??null}const i={regex:"input",email:"email address",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO datetime",date:"ISO date",time:"ISO time",duration:"ISO duration",ipv4:"IPv4 address",ipv6:"IPv6 address",cidrv4:"IPv4 range",cidrv6:"IPv6 range",base64:"base64-encoded string",base64url:"base64url-encoded string",json_string:"JSON string",e164:"E.164 number",jwt:"JWT",template_literal:"input"},l={nan:"NaN"};return n=>{switch(n.code){case"invalid_type":{const o=l[n.expected]??n.expected,s=Se(n.input),f=l[s]??s;return/^[A-Z]/.test(n.expected)?`Yanlış dəyər: gözlənilən instanceof ${n.expected}, daxil olan ${f}`:`Yanlış dəyər: gözlənilən ${o}, daxil olan ${f}`}case"invalid_value":return n.values.length===1?`Yanlış dəyər: gözlənilən ${xe(n.values[0])}`:`Yanlış seçim: aşağıdakılardan biri olmalıdır: ${ae(n.values,"|")}`;case"too_big":{const o=n.inclusive?"<=":"<",s=t(n.origin);return s?`Çox böyük: gözlənilən ${n.origin??"dəyər"} ${o}${n.maximum.toString()} ${s.unit??"element"}`:`Çox böyük: gözlənilən ${n.origin??"dəyər"} ${o}${n.maximum.toString()}`}case"too_small":{const o=n.inclusive?">=":">",s=t(n.origin);return s?`Çox kiçik: gözlənilən ${n.origin} ${o}${n.minimum.toString()} ${s.unit}`:`Çox kiçik: gözlənilən ${n.origin} ${o}${n.minimum.toString()}`}case"invalid_format":{const o=n;return o.format==="starts_with"?`Yanlış mətn: "${o.prefix}" ilə başlamalıdır`:o.format==="ends_with"?`Yanlış mətn: "${o.suffix}" ilə bitməlidir`:o.format==="includes"?`Yanlış mətn: "${o.includes}" daxil olmalıdır`:o.format==="regex"?`Yanlış mətn: ${o.pattern} şablonuna uyğun olmalıdır`:`Yanlış ${i[o.format]??n.format}`}case"not_multiple_of":return`Yanlış ədəd: ${n.divisor} ilə bölünə bilən olmalıdır`;case"unrecognized_keys":return`Tanınmayan açar${n.keys.length>1?"lar":""}: ${ae(n.keys,", ")}`;case"invalid_key":return`${n.origin} daxilində yanlış açar`;case"invalid_union":return"Yanlış dəyər";case"invalid_element":return`${n.origin} daxilində yanlış dəyər`;default:return"Yanlış dəyər"}}};function iA(){return{localeError:rA()}}function $_(e,t,i,l){const n=Math.abs(e),o=n%10,s=n%100;return s>=11&&s<=19?l:o===1?t:o>=2&&o<=4?i:l}const aA=()=>{const e={string:{unit:{one:"сімвал",few:"сімвалы",many:"сімвалаў"},verb:"мець"},array:{unit:{one:"элемент",few:"элементы",many:"элементаў"},verb:"мець"},set:{unit:{one:"элемент",few:"элементы",many:"элементаў"},verb:"мець"},file:{unit:{one:"байт",few:"байты",many:"байтаў"},verb:"мець"}};function t(n){return e[n]??null}const i={regex:"увод",email:"email адрас",url:"URL",emoji:"эмодзі",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO дата і час",date:"ISO дата",time:"ISO час",duration:"ISO працягласць",ipv4:"IPv4 адрас",ipv6:"IPv6 адрас",cidrv4:"IPv4 дыяпазон",cidrv6:"IPv6 дыяпазон",base64:"радок у фармаце base64",base64url:"радок у фармаце base64url",json_string:"JSON радок",e164:"нумар E.164",jwt:"JWT",template_literal:"увод"},l={nan:"NaN",number:"лік",array:"масіў"};return n=>{switch(n.code){case"invalid_type":{const o=l[n.expected]??n.expected,s=Se(n.input),f=l[s]??s;return/^[A-Z]/.test(n.expected)?`Няправільны ўвод: чакаўся instanceof ${n.expected}, атрымана ${f}`:`Няправільны ўвод: чакаўся ${o}, атрымана ${f}`}case"invalid_value":return n.values.length===1?`Няправільны ўвод: чакалася ${xe(n.values[0])}`:`Няправільны варыянт: чакаўся адзін з ${ae(n.values,"|")}`;case"too_big":{const o=n.inclusive?"<=":"<",s=t(n.origin);if(s){const f=Number(n.maximum),m=$_(f,s.unit.one,s.unit.few,s.unit.many);return`Занадта вялікі: чакалася, што ${n.origin??"значэнне"} павінна ${s.verb} ${o}${n.maximum.toString()} ${m}`}return`Занадта вялікі: чакалася, што ${n.origin??"значэнне"} павінна быць ${o}${n.maximum.toString()}`}case"too_small":{const o=n.inclusive?">=":">",s=t(n.origin);if(s){const f=Number(n.minimum),m=$_(f,s.unit.one,s.unit.few,s.unit.many);return`Занадта малы: чакалася, што ${n.origin} павінна ${s.verb} ${o}${n.minimum.toString()} ${m}`}return`Занадта малы: чакалася, што ${n.origin} павінна быць ${o}${n.minimum.toString()}`}case"invalid_format":{const o=n;return o.format==="starts_with"?`Няправільны радок: павінен пачынацца з "${o.prefix}"`:o.format==="ends_with"?`Няправільны радок: павінен заканчвацца на "${o.suffix}"`:o.format==="includes"?`Няправільны радок: павінен змяшчаць "${o.includes}"`:o.format==="regex"?`Няправільны радок: павінен адпавядаць шаблону ${o.pattern}`:`Няправільны ${i[o.format]??n.format}`}case"not_multiple_of":return`Няправільны лік: павінен быць кратным ${n.divisor}`;case"unrecognized_keys":return`Нераспазнаны ${n.keys.length>1?"ключы":"ключ"}: ${ae(n.keys,", ")}`;case"invalid_key":return`Няправільны ключ у ${n.origin}`;case"invalid_union":return"Няправільны ўвод";case"invalid_element":return`Няправільнае значэнне ў ${n.origin}`;default:return"Няправільны ўвод"}}};function lA(){return{localeError:aA()}}const oA=()=>{const e={string:{unit:"символа",verb:"да съдържа"},file:{unit:"байта",verb:"да съдържа"},array:{unit:"елемента",verb:"да съдържа"},set:{unit:"елемента",verb:"да съдържа"}};function t(n){return e[n]??null}const i={regex:"вход",email:"имейл адрес",url:"URL",emoji:"емоджи",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO време",date:"ISO дата",time:"ISO време",duration:"ISO продължителност",ipv4:"IPv4 адрес",ipv6:"IPv6 адрес",cidrv4:"IPv4 диапазон",cidrv6:"IPv6 диапазон",base64:"base64-кодиран низ",base64url:"base64url-кодиран низ",json_string:"JSON низ",e164:"E.164 номер",jwt:"JWT",template_literal:"вход"},l={nan:"NaN",number:"число",array:"масив"};return n=>{switch(n.code){case"invalid_type":{const o=l[n.expected]??n.expected,s=Se(n.input),f=l[s]??s;return/^[A-Z]/.test(n.expected)?`Невалиден вход: очакван instanceof ${n.expected}, получен ${f}`:`Невалиден вход: очакван ${o}, получен ${f}`}case"invalid_value":return n.values.length===1?`Невалиден вход: очакван ${xe(n.values[0])}`:`Невалидна опция: очаквано едно от ${ae(n.values,"|")}`;case"too_big":{const o=n.inclusive?"<=":"<",s=t(n.origin);return s?`Твърде голямо: очаква се ${n.origin??"стойност"} да съдържа ${o}${n.maximum.toString()} ${s.unit??"елемента"}`:`Твърде голямо: очаква се ${n.origin??"стойност"} да бъде ${o}${n.maximum.toString()}`}case"too_small":{const o=n.inclusive?">=":">",s=t(n.origin);return s?`Твърде малко: очаква се ${n.origin} да съдържа ${o}${n.minimum.toString()} ${s.unit}`:`Твърде малко: очаква се ${n.origin} да бъде ${o}${n.minimum.toString()}`}case"invalid_format":{const o=n;if(o.format==="starts_with")return`Невалиден низ: трябва да започва с "${o.prefix}"`;if(o.format==="ends_with")return`Невалиден низ: трябва да завършва с "${o.suffix}"`;if(o.format==="includes")return`Невалиден низ: трябва да включва "${o.includes}"`;if(o.format==="regex")return`Невалиден низ: трябва да съвпада с ${o.pattern}`;let s="Невалиден";return o.format==="emoji"&&(s="Невалидно"),o.format==="datetime"&&(s="Невалидно"),o.format==="date"&&(s="Невалидна"),o.format==="time"&&(s="Невалидно"),o.format==="duration"&&(s="Невалидна"),`${s} ${i[o.format]??n.format}`}case"not_multiple_of":return`Невалидно число: трябва да бъде кратно на ${n.divisor}`;case"unrecognized_keys":return`Неразпознат${n.keys.length>1?"и":""} ключ${n.keys.length>1?"ове":""}: ${ae(n.keys,", ")}`;case"invalid_key":return`Невалиден ключ в ${n.origin}`;case"invalid_union":return"Невалиден вход";case"invalid_element":return`Невалидна стойност в ${n.origin}`;default:return"Невалиден вход"}}};function uA(){return{localeError:oA()}}const sA=()=>{const e={string:{unit:"caràcters",verb:"contenir"},file:{unit:"bytes",verb:"contenir"},array:{unit:"elements",verb:"contenir"},set:{unit:"elements",verb:"contenir"}};function t(n){return e[n]??null}const i={regex:"entrada",email:"adreça electrònica",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"data i hora ISO",date:"data ISO",time:"hora ISO",duration:"durada ISO",ipv4:"adreça IPv4",ipv6:"adreça IPv6",cidrv4:"rang IPv4",cidrv6:"rang IPv6",base64:"cadena codificada en base64",base64url:"cadena codificada en base64url",json_string:"cadena JSON",e164:"número E.164",jwt:"JWT",template_literal:"entrada"},l={nan:"NaN"};return n=>{switch(n.code){case"invalid_type":{const o=l[n.expected]??n.expected,s=Se(n.input),f=l[s]??s;return/^[A-Z]/.test(n.expected)?`Tipus invàlid: s'esperava instanceof ${n.expected}, s'ha rebut ${f}`:`Tipus invàlid: s'esperava ${o}, s'ha rebut ${f}`}case"invalid_value":return n.values.length===1?`Valor invàlid: s'esperava ${xe(n.values[0])}`:`Opció invàlida: s'esperava una de ${ae(n.values," o ")}`;case"too_big":{const o=n.inclusive?"com a màxim":"menys de",s=t(n.origin);return s?`Massa gran: s'esperava que ${n.origin??"el valor"} contingués ${o} ${n.maximum.toString()} ${s.unit??"elements"}`:`Massa gran: s'esperava que ${n.origin??"el valor"} fos ${o} ${n.maximum.toString()}`}case"too_small":{const o=n.inclusive?"com a mínim":"més de",s=t(n.origin);return s?`Massa petit: s'esperava que ${n.origin} contingués ${o} ${n.minimum.toString()} ${s.unit}`:`Massa petit: s'esperava que ${n.origin} fos ${o} ${n.minimum.toString()}`}case"invalid_format":{const o=n;return o.format==="starts_with"?`Format invàlid: ha de començar amb "${o.prefix}"`:o.format==="ends_with"?`Format invàlid: ha d'acabar amb "${o.suffix}"`:o.format==="includes"?`Format invàlid: ha d'incloure "${o.includes}"`:o.format==="regex"?`Format invàlid: ha de coincidir amb el patró ${o.pattern}`:`Format invàlid per a ${i[o.format]??n.format}`}case"not_multiple_of":return`Número invàlid: ha de ser múltiple de ${n.divisor}`;case"unrecognized_keys":return`Clau${n.keys.length>1?"s":""} no reconeguda${n.keys.length>1?"s":""}: ${ae(n.keys,", ")}`;case"invalid_key":return`Clau invàlida a ${n.origin}`;case"invalid_union":return"Entrada invàlida";case"invalid_element":return`Element invàlid a ${n.origin}`;default:return"Entrada invàlida"}}};function cA(){return{localeError:sA()}}const fA=()=>{const e={string:{unit:"znaků",verb:"mít"},file:{unit:"bajtů",verb:"mít"},array:{unit:"prvků",verb:"mít"},set:{unit:"prvků",verb:"mít"}};function t(n){return e[n]??null}const i={regex:"regulární výraz",email:"e-mailová adresa",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"datum a čas ve formátu ISO",date:"datum ve formátu ISO",time:"čas ve formátu ISO",duration:"doba trvání ISO",ipv4:"IPv4 adresa",ipv6:"IPv6 adresa",cidrv4:"rozsah IPv4",cidrv6:"rozsah IPv6",base64:"řetězec zakódovaný ve formátu base64",base64url:"řetězec zakódovaný ve formátu base64url",json_string:"řetězec ve formátu JSON",e164:"číslo E.164",jwt:"JWT",template_literal:"vstup"},l={nan:"NaN",number:"číslo",string:"řetězec",function:"funkce",array:"pole"};return n=>{switch(n.code){case"invalid_type":{const o=l[n.expected]??n.expected,s=Se(n.input),f=l[s]??s;return/^[A-Z]/.test(n.expected)?`Neplatný vstup: očekáváno instanceof ${n.expected}, obdrženo ${f}`:`Neplatný vstup: očekáváno ${o}, obdrženo ${f}`}case"invalid_value":return n.values.length===1?`Neplatný vstup: očekáváno ${xe(n.values[0])}`:`Neplatná možnost: očekávána jedna z hodnot ${ae(n.values,"|")}`;case"too_big":{const o=n.inclusive?"<=":"<",s=t(n.origin);return s?`Hodnota je příliš velká: ${n.origin??"hodnota"} musí mít ${o}${n.maximum.toString()} ${s.unit??"prvků"}`:`Hodnota je příliš velká: ${n.origin??"hodnota"} musí být ${o}${n.maximum.toString()}`}case"too_small":{const o=n.inclusive?">=":">",s=t(n.origin);return s?`Hodnota je příliš malá: ${n.origin??"hodnota"} musí mít ${o}${n.minimum.toString()} ${s.unit??"prvků"}`:`Hodnota je příliš malá: ${n.origin??"hodnota"} musí být ${o}${n.minimum.toString()}`}case"invalid_format":{const o=n;return o.format==="starts_with"?`Neplatný řetězec: musí začínat na "${o.prefix}"`:o.format==="ends_with"?`Neplatný řetězec: musí končit na "${o.suffix}"`:o.format==="includes"?`Neplatný řetězec: musí obsahovat "${o.includes}"`:o.format==="regex"?`Neplatný řetězec: musí odpovídat vzoru ${o.pattern}`:`Neplatný formát ${i[o.format]??n.format}`}case"not_multiple_of":return`Neplatné číslo: musí být násobkem ${n.divisor}`;case"unrecognized_keys":return`Neznámé klíče: ${ae(n.keys,", ")}`;case"invalid_key":return`Neplatný klíč v ${n.origin}`;case"invalid_union":return"Neplatný vstup";case"invalid_element":return`Neplatná hodnota v ${n.origin}`;default:return"Neplatný vstup"}}};function dA(){return{localeError:fA()}}const mA=()=>{const e={string:{unit:"tegn",verb:"havde"},file:{unit:"bytes",verb:"havde"},array:{unit:"elementer",verb:"indeholdt"},set:{unit:"elementer",verb:"indeholdt"}};function t(n){return e[n]??null}const i={regex:"input",email:"e-mailadresse",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO dato- og klokkeslæt",date:"ISO-dato",time:"ISO-klokkeslæt",duration:"ISO-varighed",ipv4:"IPv4-område",ipv6:"IPv6-område",cidrv4:"IPv4-spektrum",cidrv6:"IPv6-spektrum",base64:"base64-kodet streng",base64url:"base64url-kodet streng",json_string:"JSON-streng",e164:"E.164-nummer",jwt:"JWT",template_literal:"input"},l={nan:"NaN",string:"streng",number:"tal",boolean:"boolean",array:"liste",object:"objekt",set:"sæt",file:"fil"};return n=>{switch(n.code){case"invalid_type":{const o=l[n.expected]??n.expected,s=Se(n.input),f=l[s]??s;return/^[A-Z]/.test(n.expected)?`Ugyldigt input: forventede instanceof ${n.expected}, fik ${f}`:`Ugyldigt input: forventede ${o}, fik ${f}`}case"invalid_value":return n.values.length===1?`Ugyldig værdi: forventede ${xe(n.values[0])}`:`Ugyldigt valg: forventede en af følgende ${ae(n.values,"|")}`;case"too_big":{const o=n.inclusive?"<=":"<",s=t(n.origin),f=l[n.origin]??n.origin;return s?`For stor: forventede ${f??"value"} ${s.verb} ${o} ${n.maximum.toString()} ${s.unit??"elementer"}`:`For stor: forventede ${f??"value"} havde ${o} ${n.maximum.toString()}`}case"too_small":{const o=n.inclusive?">=":">",s=t(n.origin),f=l[n.origin]??n.origin;return s?`For lille: forventede ${f} ${s.verb} ${o} ${n.minimum.toString()} ${s.unit}`:`For lille: forventede ${f} havde ${o} ${n.minimum.toString()}`}case"invalid_format":{const o=n;return o.format==="starts_with"?`Ugyldig streng: skal starte med "${o.prefix}"`:o.format==="ends_with"?`Ugyldig streng: skal ende med "${o.suffix}"`:o.format==="includes"?`Ugyldig streng: skal indeholde "${o.includes}"`:o.format==="regex"?`Ugyldig streng: skal matche mønsteret ${o.pattern}`:`Ugyldig ${i[o.format]??n.format}`}case"not_multiple_of":return`Ugyldigt tal: skal være deleligt med ${n.divisor}`;case"unrecognized_keys":return`${n.keys.length>1?"Ukendte nøgler":"Ukendt nøgle"}: ${ae(n.keys,", ")}`;case"invalid_key":return`Ugyldig nøgle i ${n.origin}`;case"invalid_union":return"Ugyldigt input: matcher ingen af de tilladte typer";case"invalid_element":return`Ugyldig værdi i ${n.origin}`;default:return"Ugyldigt input"}}};function hA(){return{localeError:mA()}}const pA=()=>{const e={string:{unit:"Zeichen",verb:"zu haben"},file:{unit:"Bytes",verb:"zu haben"},array:{unit:"Elemente",verb:"zu haben"},set:{unit:"Elemente",verb:"zu haben"}};function t(n){return e[n]??null}const i={regex:"Eingabe",email:"E-Mail-Adresse",url:"URL",emoji:"Emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO-Datum und -Uhrzeit",date:"ISO-Datum",time:"ISO-Uhrzeit",duration:"ISO-Dauer",ipv4:"IPv4-Adresse",ipv6:"IPv6-Adresse",cidrv4:"IPv4-Bereich",cidrv6:"IPv6-Bereich",base64:"Base64-codierter String",base64url:"Base64-URL-codierter String",json_string:"JSON-String",e164:"E.164-Nummer",jwt:"JWT",template_literal:"Eingabe"},l={nan:"NaN",number:"Zahl",array:"Array"};return n=>{switch(n.code){case"invalid_type":{const o=l[n.expected]??n.expected,s=Se(n.input),f=l[s]??s;return/^[A-Z]/.test(n.expected)?`Ungültige Eingabe: erwartet instanceof ${n.expected}, erhalten ${f}`:`Ungültige Eingabe: erwartet ${o}, erhalten ${f}`}case"invalid_value":return n.values.length===1?`Ungültige Eingabe: erwartet ${xe(n.values[0])}`:`Ungültige Option: erwartet eine von ${ae(n.values,"|")}`;case"too_big":{const o=n.inclusive?"<=":"<",s=t(n.origin);return s?`Zu groß: erwartet, dass ${n.origin??"Wert"} ${o}${n.maximum.toString()} ${s.unit??"Elemente"} hat`:`Zu groß: erwartet, dass ${n.origin??"Wert"} ${o}${n.maximum.toString()} ist`}case"too_small":{const o=n.inclusive?">=":">",s=t(n.origin);return s?`Zu klein: erwartet, dass ${n.origin} ${o}${n.minimum.toString()} ${s.unit} hat`:`Zu klein: erwartet, dass ${n.origin} ${o}${n.minimum.toString()} ist`}case"invalid_format":{const o=n;return o.format==="starts_with"?`Ungültiger String: muss mit "${o.prefix}" beginnen`:o.format==="ends_with"?`Ungültiger String: muss mit "${o.suffix}" enden`:o.format==="includes"?`Ungültiger String: muss "${o.includes}" enthalten`:o.format==="regex"?`Ungültiger String: muss dem Muster ${o.pattern} entsprechen`:`Ungültig: ${i[o.format]??n.format}`}case"not_multiple_of":return`Ungültige Zahl: muss ein Vielfaches von ${n.divisor} sein`;case"unrecognized_keys":return`${n.keys.length>1?"Unbekannte Schlüssel":"Unbekannter Schlüssel"}: ${ae(n.keys,", ")}`;case"invalid_key":return`Ungültiger Schlüssel in ${n.origin}`;case"invalid_union":return"Ungültige Eingabe";case"invalid_element":return`Ungültiger Wert in ${n.origin}`;default:return"Ungültige Eingabe"}}};function gA(){return{localeError:pA()}}const vA=()=>{const e={string:{unit:"characters",verb:"to have"},file:{unit:"bytes",verb:"to have"},array:{unit:"items",verb:"to have"},set:{unit:"items",verb:"to have"},map:{unit:"entries",verb:"to have"}};function t(n){return e[n]??null}const i={regex:"input",email:"email address",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO datetime",date:"ISO date",time:"ISO time",duration:"ISO duration",ipv4:"IPv4 address",ipv6:"IPv6 address",mac:"MAC address",cidrv4:"IPv4 range",cidrv6:"IPv6 range",base64:"base64-encoded string",base64url:"base64url-encoded string",json_string:"JSON string",e164:"E.164 number",jwt:"JWT",template_literal:"input"},l={nan:"NaN"};return n=>{switch(n.code){case"invalid_type":{const o=l[n.expected]??n.expected,s=Se(n.input),f=l[s]??s;return`Invalid input: expected ${o}, received ${f}`}case"invalid_value":return n.values.length===1?`Invalid input: expected ${xe(n.values[0])}`:`Invalid option: expected one of ${ae(n.values,"|")}`;case"too_big":{const o=n.inclusive?"<=":"<",s=t(n.origin);return s?`Too big: expected ${n.origin??"value"} to have ${o}${n.maximum.toString()} ${s.unit??"elements"}`:`Too big: expected ${n.origin??"value"} to be ${o}${n.maximum.toString()}`}case"too_small":{const o=n.inclusive?">=":">",s=t(n.origin);return s?`Too small: expected ${n.origin} to have ${o}${n.minimum.toString()} ${s.unit}`:`Too small: expected ${n.origin} to be ${o}${n.minimum.toString()}`}case"invalid_format":{const o=n;return o.format==="starts_with"?`Invalid string: must start with "${o.prefix}"`:o.format==="ends_with"?`Invalid string: must end with "${o.suffix}"`:o.format==="includes"?`Invalid string: must include "${o.includes}"`:o.format==="regex"?`Invalid string: must match pattern ${o.pattern}`:`Invalid ${i[o.format]??n.format}`}case"not_multiple_of":return`Invalid number: must be a multiple of ${n.divisor}`;case"unrecognized_keys":return`Unrecognized key${n.keys.length>1?"s":""}: ${ae(n.keys,", ")}`;case"invalid_key":return`Invalid key in ${n.origin}`;case"invalid_union":return"Invalid input";case"invalid_element":return`Invalid value in ${n.origin}`;default:return"Invalid input"}}};function D$(){return{localeError:vA()}}const yA=()=>{const e={string:{unit:"karaktrojn",verb:"havi"},file:{unit:"bajtojn",verb:"havi"},array:{unit:"elementojn",verb:"havi"},set:{unit:"elementojn",verb:"havi"}};function t(n){return e[n]??null}const i={regex:"enigo",email:"retadreso",url:"URL",emoji:"emoĝio",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO-datotempo",date:"ISO-dato",time:"ISO-tempo",duration:"ISO-daŭro",ipv4:"IPv4-adreso",ipv6:"IPv6-adreso",cidrv4:"IPv4-rango",cidrv6:"IPv6-rango",base64:"64-ume kodita karaktraro",base64url:"URL-64-ume kodita karaktraro",json_string:"JSON-karaktraro",e164:"E.164-nombro",jwt:"JWT",template_literal:"enigo"},l={nan:"NaN",number:"nombro",array:"tabelo",null:"senvalora"};return n=>{switch(n.code){case"invalid_type":{const o=l[n.expected]??n.expected,s=Se(n.input),f=l[s]??s;return/^[A-Z]/.test(n.expected)?`Nevalida enigo: atendiĝis instanceof ${n.expected}, riceviĝis ${f}`:`Nevalida enigo: atendiĝis ${o}, riceviĝis ${f}`}case"invalid_value":return n.values.length===1?`Nevalida enigo: atendiĝis ${xe(n.values[0])}`:`Nevalida opcio: atendiĝis unu el ${ae(n.values,"|")}`;case"too_big":{const o=n.inclusive?"<=":"<",s=t(n.origin);return s?`Tro granda: atendiĝis ke ${n.origin??"valoro"} havu ${o}${n.maximum.toString()} ${s.unit??"elementojn"}`:`Tro granda: atendiĝis ke ${n.origin??"valoro"} havu ${o}${n.maximum.toString()}`}case"too_small":{const o=n.inclusive?">=":">",s=t(n.origin);return s?`Tro malgranda: atendiĝis ke ${n.origin} havu ${o}${n.minimum.toString()} ${s.unit}`:`Tro malgranda: atendiĝis ke ${n.origin} estu ${o}${n.minimum.toString()}`}case"invalid_format":{const o=n;return o.format==="starts_with"?`Nevalida karaktraro: devas komenciĝi per "${o.prefix}"`:o.format==="ends_with"?`Nevalida karaktraro: devas finiĝi per "${o.suffix}"`:o.format==="includes"?`Nevalida karaktraro: devas inkluzivi "${o.includes}"`:o.format==="regex"?`Nevalida karaktraro: devas kongrui kun la modelo ${o.pattern}`:`Nevalida ${i[o.format]??n.format}`}case"not_multiple_of":return`Nevalida nombro: devas esti oblo de ${n.divisor}`;case"unrecognized_keys":return`Nekonata${n.keys.length>1?"j":""} ŝlosilo${n.keys.length>1?"j":""}: ${ae(n.keys,", ")}`;case"invalid_key":return`Nevalida ŝlosilo en ${n.origin}`;case"invalid_union":return"Nevalida enigo";case"invalid_element":return`Nevalida valoro en ${n.origin}`;default:return"Nevalida enigo"}}};function bA(){return{localeError:yA()}}const xA=()=>{const e={string:{unit:"caracteres",verb:"tener"},file:{unit:"bytes",verb:"tener"},array:{unit:"elementos",verb:"tener"},set:{unit:"elementos",verb:"tener"}};function t(n){return e[n]??null}const i={regex:"entrada",email:"dirección de correo electrónico",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"fecha y hora ISO",date:"fecha ISO",time:"hora ISO",duration:"duración ISO",ipv4:"dirección IPv4",ipv6:"dirección IPv6",cidrv4:"rango IPv4",cidrv6:"rango IPv6",base64:"cadena codificada en base64",base64url:"URL codificada en base64",json_string:"cadena JSON",e164:"número E.164",jwt:"JWT",template_literal:"entrada"},l={nan:"NaN",string:"texto",number:"número",boolean:"booleano",array:"arreglo",object:"objeto",set:"conjunto",file:"archivo",date:"fecha",bigint:"número grande",symbol:"símbolo",undefined:"indefinido",null:"nulo",function:"función",map:"mapa",record:"registro",tuple:"tupla",enum:"enumeración",union:"unión",literal:"literal",promise:"promesa",void:"vacío",never:"nunca",unknown:"desconocido",any:"cualquiera"};return n=>{switch(n.code){case"invalid_type":{const o=l[n.expected]??n.expected,s=Se(n.input),f=l[s]??s;return/^[A-Z]/.test(n.expected)?`Entrada inválida: se esperaba instanceof ${n.expected}, recibido ${f}`:`Entrada inválida: se esperaba ${o}, recibido ${f}`}case"invalid_value":return n.values.length===1?`Entrada inválida: se esperaba ${xe(n.values[0])}`:`Opción inválida: se esperaba una de ${ae(n.values,"|")}`;case"too_big":{const o=n.inclusive?"<=":"<",s=t(n.origin),f=l[n.origin]??n.origin;return s?`Demasiado grande: se esperaba que ${f??"valor"} tuviera ${o}${n.maximum.toString()} ${s.unit??"elementos"}`:`Demasiado grande: se esperaba que ${f??"valor"} fuera ${o}${n.maximum.toString()}`}case"too_small":{const o=n.inclusive?">=":">",s=t(n.origin),f=l[n.origin]??n.origin;return s?`Demasiado pequeño: se esperaba que ${f} tuviera ${o}${n.minimum.toString()} ${s.unit}`:`Demasiado pequeño: se esperaba que ${f} fuera ${o}${n.minimum.toString()}`}case"invalid_format":{const o=n;return o.format==="starts_with"?`Cadena inválida: debe comenzar con "${o.prefix}"`:o.format==="ends_with"?`Cadena inválida: debe terminar en "${o.suffix}"`:o.format==="includes"?`Cadena inválida: debe incluir "${o.includes}"`:o.format==="regex"?`Cadena inválida: debe coincidir con el patrón ${o.pattern}`:`Inválido ${i[o.format]??n.format}`}case"not_multiple_of":return`Número inválido: debe ser múltiplo de ${n.divisor}`;case"unrecognized_keys":return`Llave${n.keys.length>1?"s":""} desconocida${n.keys.length>1?"s":""}: ${ae(n.keys,", ")}`;case"invalid_key":return`Llave inválida en ${l[n.origin]??n.origin}`;case"invalid_union":return"Entrada inválida";case"invalid_element":return`Valor inválido en ${l[n.origin]??n.origin}`;default:return"Entrada inválida"}}};function _A(){return{localeError:xA()}}const SA=()=>{const e={string:{unit:"کاراکتر",verb:"داشته باشد"},file:{unit:"بایت",verb:"داشته باشد"},array:{unit:"آیتم",verb:"داشته باشد"},set:{unit:"آیتم",verb:"داشته باشد"}};function t(n){return e[n]??null}const i={regex:"ورودی",email:"آدرس ایمیل",url:"URL",emoji:"ایموجی",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"تاریخ و زمان ایزو",date:"تاریخ ایزو",time:"زمان ایزو",duration:"مدت زمان ایزو",ipv4:"IPv4 آدرس",ipv6:"IPv6 آدرس",cidrv4:"IPv4 دامنه",cidrv6:"IPv6 دامنه",base64:"base64-encoded رشته",base64url:"base64url-encoded رشته",json_string:"JSON رشته",e164:"E.164 عدد",jwt:"JWT",template_literal:"ورودی"},l={nan:"NaN",number:"عدد",array:"آرایه"};return n=>{switch(n.code){case"invalid_type":{const o=l[n.expected]??n.expected,s=Se(n.input),f=l[s]??s;return/^[A-Z]/.test(n.expected)?`ورودی نامعتبر: میبایست instanceof ${n.expected} میبود، ${f} دریافت شد`:`ورودی نامعتبر: میبایست ${o} میبود، ${f} دریافت شد`}case"invalid_value":return n.values.length===1?`ورودی نامعتبر: میبایست ${xe(n.values[0])} میبود`:`گزینه نامعتبر: میبایست یکی از ${ae(n.values,"|")} میبود`;case"too_big":{const o=n.inclusive?"<=":"<",s=t(n.origin);return s?`خیلی بزرگ: ${n.origin??"مقدار"} باید ${o}${n.maximum.toString()} ${s.unit??"عنصر"} باشد`:`خیلی بزرگ: ${n.origin??"مقدار"} باید ${o}${n.maximum.toString()} باشد`}case"too_small":{const o=n.inclusive?">=":">",s=t(n.origin);return s?`خیلی کوچک: ${n.origin} باید ${o}${n.minimum.toString()} ${s.unit} باشد`:`خیلی کوچک: ${n.origin} باید ${o}${n.minimum.toString()} باشد`}case"invalid_format":{const o=n;return o.format==="starts_with"?`رشته نامعتبر: باید با "${o.prefix}" شروع شود`:o.format==="ends_with"?`رشته نامعتبر: باید با "${o.suffix}" تمام شود`:o.format==="includes"?`رشته نامعتبر: باید شامل "${o.includes}" باشد`:o.format==="regex"?`رشته نامعتبر: باید با الگوی ${o.pattern} مطابقت داشته باشد`:`${i[o.format]??n.format} نامعتبر`}case"not_multiple_of":return`عدد نامعتبر: باید مضرب ${n.divisor} باشد`;case"unrecognized_keys":return`کلید${n.keys.length>1?"های":""} ناشناس: ${ae(n.keys,", ")}`;case"invalid_key":return`کلید ناشناس در ${n.origin}`;case"invalid_union":return"ورودی نامعتبر";case"invalid_element":return`مقدار نامعتبر در ${n.origin}`;default:return"ورودی نامعتبر"}}};function kA(){return{localeError:SA()}}const wA=()=>{const e={string:{unit:"merkkiä",subject:"merkkijonon"},file:{unit:"tavua",subject:"tiedoston"},array:{unit:"alkiota",subject:"listan"},set:{unit:"alkiota",subject:"joukon"},number:{unit:"",subject:"luvun"},bigint:{unit:"",subject:"suuren kokonaisluvun"},int:{unit:"",subject:"kokonaisluvun"},date:{unit:"",subject:"päivämäärän"}};function t(n){return e[n]??null}const i={regex:"säännöllinen lauseke",email:"sähköpostiosoite",url:"URL-osoite",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO-aikaleima",date:"ISO-päivämäärä",time:"ISO-aika",duration:"ISO-kesto",ipv4:"IPv4-osoite",ipv6:"IPv6-osoite",cidrv4:"IPv4-alue",cidrv6:"IPv6-alue",base64:"base64-koodattu merkkijono",base64url:"base64url-koodattu merkkijono",json_string:"JSON-merkkijono",e164:"E.164-luku",jwt:"JWT",template_literal:"templaattimerkkijono"},l={nan:"NaN"};return n=>{switch(n.code){case"invalid_type":{const o=l[n.expected]??n.expected,s=Se(n.input),f=l[s]??s;return/^[A-Z]/.test(n.expected)?`Virheellinen tyyppi: odotettiin instanceof ${n.expected}, oli ${f}`:`Virheellinen tyyppi: odotettiin ${o}, oli ${f}`}case"invalid_value":return n.values.length===1?`Virheellinen syöte: täytyy olla ${xe(n.values[0])}`:`Virheellinen valinta: täytyy olla yksi seuraavista: ${ae(n.values,"|")}`;case"too_big":{const o=n.inclusive?"<=":"<",s=t(n.origin);return s?`Liian suuri: ${s.subject} täytyy olla ${o}${n.maximum.toString()} ${s.unit}`.trim():`Liian suuri: arvon täytyy olla ${o}${n.maximum.toString()}`}case"too_small":{const o=n.inclusive?">=":">",s=t(n.origin);return s?`Liian pieni: ${s.subject} täytyy olla ${o}${n.minimum.toString()} ${s.unit}`.trim():`Liian pieni: arvon täytyy olla ${o}${n.minimum.toString()}`}case"invalid_format":{const o=n;return o.format==="starts_with"?`Virheellinen syöte: täytyy alkaa "${o.prefix}"`:o.format==="ends_with"?`Virheellinen syöte: täytyy loppua "${o.suffix}"`:o.format==="includes"?`Virheellinen syöte: täytyy sisältää "${o.includes}"`:o.format==="regex"?`Virheellinen syöte: täytyy vastata säännöllistä lauseketta ${o.pattern}`:`Virheellinen ${i[o.format]??n.format}`}case"not_multiple_of":return`Virheellinen luku: täytyy olla luvun ${n.divisor} monikerta`;case"unrecognized_keys":return`${n.keys.length>1?"Tuntemattomat avaimet":"Tuntematon avain"}: ${ae(n.keys,", ")}`;case"invalid_key":return"Virheellinen avain tietueessa";case"invalid_union":return"Virheellinen unioni";case"invalid_element":return"Virheellinen arvo joukossa";default:return"Virheellinen syöte"}}};function $A(){return{localeError:wA()}}const EA=()=>{const e={string:{unit:"caractères",verb:"avoir"},file:{unit:"octets",verb:"avoir"},array:{unit:"éléments",verb:"avoir"},set:{unit:"éléments",verb:"avoir"}};function t(n){return e[n]??null}const i={regex:"entrée",email:"adresse e-mail",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"date et heure ISO",date:"date ISO",time:"heure ISO",duration:"durée ISO",ipv4:"adresse IPv4",ipv6:"adresse IPv6",cidrv4:"plage IPv4",cidrv6:"plage IPv6",base64:"chaîne encodée en base64",base64url:"chaîne encodée en base64url",json_string:"chaîne JSON",e164:"numéro E.164",jwt:"JWT",template_literal:"entrée"},l={nan:"NaN",number:"nombre",array:"tableau"};return n=>{switch(n.code){case"invalid_type":{const o=l[n.expected]??n.expected,s=Se(n.input),f=l[s]??s;return/^[A-Z]/.test(n.expected)?`Entrée invalide : instanceof ${n.expected} attendu, ${f} reçu`:`Entrée invalide : ${o} attendu, ${f} reçu`}case"invalid_value":return n.values.length===1?`Entrée invalide : ${xe(n.values[0])} attendu`:`Option invalide : une valeur parmi ${ae(n.values,"|")} attendue`;case"too_big":{const o=n.inclusive?"<=":"<",s=t(n.origin);return s?`Trop grand : ${n.origin??"valeur"} doit ${s.verb} ${o}${n.maximum.toString()} ${s.unit??"élément(s)"}`:`Trop grand : ${n.origin??"valeur"} doit être ${o}${n.maximum.toString()}`}case"too_small":{const o=n.inclusive?">=":">",s=t(n.origin);return s?`Trop petit : ${n.origin} doit ${s.verb} ${o}${n.minimum.toString()} ${s.unit}`:`Trop petit : ${n.origin} doit être ${o}${n.minimum.toString()}`}case"invalid_format":{const o=n;return o.format==="starts_with"?`Chaîne invalide : doit commencer par "${o.prefix}"`:o.format==="ends_with"?`Chaîne invalide : doit se terminer par "${o.suffix}"`:o.format==="includes"?`Chaîne invalide : doit inclure "${o.includes}"`:o.format==="regex"?`Chaîne invalide : doit correspondre au modèle ${o.pattern}`:`${i[o.format]??n.format} invalide`}case"not_multiple_of":return`Nombre invalide : doit être un multiple de ${n.divisor}`;case"unrecognized_keys":return`Clé${n.keys.length>1?"s":""} non reconnue${n.keys.length>1?"s":""} : ${ae(n.keys,", ")}`;case"invalid_key":return`Clé invalide dans ${n.origin}`;case"invalid_union":return"Entrée invalide";case"invalid_element":return`Valeur invalide dans ${n.origin}`;default:return"Entrée invalide"}}};function jA(){return{localeError:EA()}}const zA=()=>{const e={string:{unit:"caractères",verb:"avoir"},file:{unit:"octets",verb:"avoir"},array:{unit:"éléments",verb:"avoir"},set:{unit:"éléments",verb:"avoir"}};function t(n){return e[n]??null}const i={regex:"entrée",email:"adresse courriel",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"date-heure ISO",date:"date ISO",time:"heure ISO",duration:"durée ISO",ipv4:"adresse IPv4",ipv6:"adresse IPv6",cidrv4:"plage IPv4",cidrv6:"plage IPv6",base64:"chaîne encodée en base64",base64url:"chaîne encodée en base64url",json_string:"chaîne JSON",e164:"numéro E.164",jwt:"JWT",template_literal:"entrée"},l={nan:"NaN"};return n=>{switch(n.code){case"invalid_type":{const o=l[n.expected]??n.expected,s=Se(n.input),f=l[s]??s;return/^[A-Z]/.test(n.expected)?`Entrée invalide : attendu instanceof ${n.expected}, reçu ${f}`:`Entrée invalide : attendu ${o}, reçu ${f}`}case"invalid_value":return n.values.length===1?`Entrée invalide : attendu ${xe(n.values[0])}`:`Option invalide : attendu l'une des valeurs suivantes ${ae(n.values,"|")}`;case"too_big":{const o=n.inclusive?"≤":"<",s=t(n.origin);return s?`Trop grand : attendu que ${n.origin??"la valeur"} ait ${o}${n.maximum.toString()} ${s.unit}`:`Trop grand : attendu que ${n.origin??"la valeur"} soit ${o}${n.maximum.toString()}`}case"too_small":{const o=n.inclusive?"≥":">",s=t(n.origin);return s?`Trop petit : attendu que ${n.origin} ait ${o}${n.minimum.toString()} ${s.unit}`:`Trop petit : attendu que ${n.origin} soit ${o}${n.minimum.toString()}`}case"invalid_format":{const o=n;return o.format==="starts_with"?`Chaîne invalide : doit commencer par "${o.prefix}"`:o.format==="ends_with"?`Chaîne invalide : doit se terminer par "${o.suffix}"`:o.format==="includes"?`Chaîne invalide : doit inclure "${o.includes}"`:o.format==="regex"?`Chaîne invalide : doit correspondre au motif ${o.pattern}`:`${i[o.format]??n.format} invalide`}case"not_multiple_of":return`Nombre invalide : doit être un multiple de ${n.divisor}`;case"unrecognized_keys":return`Clé${n.keys.length>1?"s":""} non reconnue${n.keys.length>1?"s":""} : ${ae(n.keys,", ")}`;case"invalid_key":return`Clé invalide dans ${n.origin}`;case"invalid_union":return"Entrée invalide";case"invalid_element":return`Valeur invalide dans ${n.origin}`;default:return"Entrée invalide"}}};function NA(){return{localeError:zA()}}const OA=()=>{const e={string:{label:"מחרוזת",gender:"f"},number:{label:"מספר",gender:"m"},boolean:{label:"ערך בוליאני",gender:"m"},bigint:{label:"BigInt",gender:"m"},date:{label:"תאריך",gender:"m"},array:{label:"מערך",gender:"m"},object:{label:"אובייקט",gender:"m"},null:{label:"ערך ריק (null)",gender:"m"},undefined:{label:"ערך לא מוגדר (undefined)",gender:"m"},symbol:{label:"סימבול (Symbol)",gender:"m"},function:{label:"פונקציה",gender:"f"},map:{label:"מפה (Map)",gender:"f"},set:{label:"קבוצה (Set)",gender:"f"},file:{label:"קובץ",gender:"m"},promise:{label:"Promise",gender:"m"},NaN:{label:"NaN",gender:"m"},unknown:{label:"ערך לא ידוע",gender:"m"},value:{label:"ערך",gender:"m"}},t={string:{unit:"תווים",shortLabel:"קצר",longLabel:"ארוך"},file:{unit:"בייטים",shortLabel:"קטן",longLabel:"גדול"},array:{unit:"פריטים",shortLabel:"קטן",longLabel:"גדול"},set:{unit:"פריטים",shortLabel:"קטן",longLabel:"גדול"},number:{unit:"",shortLabel:"קטן",longLabel:"גדול"}},i=d=>d?e[d]:void 0,l=d=>{const p=i(d);return p?p.label:d??e.unknown.label},n=d=>`ה${l(d)}`,o=d=>(i(d)?.gender??"m")==="f"?"צריכה להיות":"צריך להיות",s=d=>d?t[d]??null:null,f={regex:{label:"קלט",gender:"m"},email:{label:"כתובת אימייל",gender:"f"},url:{label:"כתובת רשת",gender:"f"},emoji:{label:"אימוג'י",gender:"m"},uuid:{label:"UUID",gender:"m"},nanoid:{label:"nanoid",gender:"m"},guid:{label:"GUID",gender:"m"},cuid:{label:"cuid",gender:"m"},cuid2:{label:"cuid2",gender:"m"},ulid:{label:"ULID",gender:"m"},xid:{label:"XID",gender:"m"},ksuid:{label:"KSUID",gender:"m"},datetime:{label:"תאריך וזמן ISO",gender:"m"},date:{label:"תאריך ISO",gender:"m"},time:{label:"זמן ISO",gender:"m"},duration:{label:"משך זמן ISO",gender:"m"},ipv4:{label:"כתובת IPv4",gender:"f"},ipv6:{label:"כתובת IPv6",gender:"f"},cidrv4:{label:"טווח IPv4",gender:"m"},cidrv6:{label:"טווח IPv6",gender:"m"},base64:{label:"מחרוזת בבסיס 64",gender:"f"},base64url:{label:"מחרוזת בבסיס 64 לכתובות רשת",gender:"f"},json_string:{label:"מחרוזת JSON",gender:"f"},e164:{label:"מספר E.164",gender:"m"},jwt:{label:"JWT",gender:"m"},ends_with:{label:"קלט",gender:"m"},includes:{label:"קלט",gender:"m"},lowercase:{label:"קלט",gender:"m"},starts_with:{label:"קלט",gender:"m"},uppercase:{label:"קלט",gender:"m"}},m={nan:"NaN"};return d=>{switch(d.code){case"invalid_type":{const p=d.expected,v=m[p??""]??l(p),b=Se(d.input),x=m[b]??e[b]?.label??b;return/^[A-Z]/.test(d.expected)?`קלט לא תקין: צריך להיות instanceof ${d.expected}, התקבל ${x}`:`קלט לא תקין: צריך להיות ${v}, התקבל ${x}`}case"invalid_value":{if(d.values.length===1)return`ערך לא תקין: הערך חייב להיות ${xe(d.values[0])}`;const p=d.values.map(x=>xe(x));if(d.values.length===2)return`ערך לא תקין: האפשרויות המתאימות הן ${p[0]} או ${p[1]}`;const v=p[p.length-1];return`ערך לא תקין: האפשרויות המתאימות הן ${p.slice(0,-1).join(", ")} או ${v}`}case"too_big":{const p=s(d.origin),v=n(d.origin??"value");if(d.origin==="string")return`${p?.longLabel??"ארוך"} מדי: ${v} צריכה להכיל ${d.maximum.toString()} ${p?.unit??""} ${d.inclusive?"או פחות":"לכל היותר"}`.trim();if(d.origin==="number"){const S=d.inclusive?`קטן או שווה ל-${d.maximum}`:`קטן מ-${d.maximum}`;return`גדול מדי: ${v} צריך להיות ${S}`}if(d.origin==="array"||d.origin==="set"){const S=d.origin==="set"?"צריכה":"צריך",w=d.inclusive?`${d.maximum} ${p?.unit??""} או פחות`:`פחות מ-${d.maximum} ${p?.unit??""}`;return`גדול מדי: ${v} ${S} להכיל ${w}`.trim()}const b=d.inclusive?"<=":"<",x=o(d.origin??"value");return p?.unit?`${p.longLabel} מדי: ${v} ${x} ${b}${d.maximum.toString()} ${p.unit}`:`${p?.longLabel??"גדול"} מדי: ${v} ${x} ${b}${d.maximum.toString()}`}case"too_small":{const p=s(d.origin),v=n(d.origin??"value");if(d.origin==="string")return`${p?.shortLabel??"קצר"} מדי: ${v} צריכה להכיל ${d.minimum.toString()} ${p?.unit??""} ${d.inclusive?"או יותר":"לפחות"}`.trim();if(d.origin==="number"){const S=d.inclusive?`גדול או שווה ל-${d.minimum}`:`גדול מ-${d.minimum}`;return`קטן מדי: ${v} צריך להיות ${S}`}if(d.origin==="array"||d.origin==="set"){const S=d.origin==="set"?"צריכה":"צריך";if(d.minimum===1&&d.inclusive){const j=(d.origin==="set","לפחות פריט אחד");return`קטן מדי: ${v} ${S} להכיל ${j}`}const w=d.inclusive?`${d.minimum} ${p?.unit??""} או יותר`:`יותר מ-${d.minimum} ${p?.unit??""}`;return`קטן מדי: ${v} ${S} להכיל ${w}`.trim()}const b=d.inclusive?">=":">",x=o(d.origin??"value");return p?.unit?`${p.shortLabel} מדי: ${v} ${x} ${b}${d.minimum.toString()} ${p.unit}`:`${p?.shortLabel??"קטן"} מדי: ${v} ${x} ${b}${d.minimum.toString()}`}case"invalid_format":{const p=d;if(p.format==="starts_with")return`המחרוזת חייבת להתחיל ב "${p.prefix}"`;if(p.format==="ends_with")return`המחרוזת חייבת להסתיים ב "${p.suffix}"`;if(p.format==="includes")return`המחרוזת חייבת לכלול "${p.includes}"`;if(p.format==="regex")return`המחרוזת חייבת להתאים לתבנית ${p.pattern}`;const v=f[p.format],b=v?.label??p.format,S=(v?.gender??"m")==="f"?"תקינה":"תקין";return`${b} לא ${S}`}case"not_multiple_of":return`מספר לא תקין: חייב להיות מכפלה של ${d.divisor}`;case"unrecognized_keys":return`מפתח${d.keys.length>1?"ות":""} לא מזוה${d.keys.length>1?"ים":"ה"}: ${ae(d.keys,", ")}`;case"invalid_key":return"שדה לא תקין באובייקט";case"invalid_union":return"קלט לא תקין";case"invalid_element":return`ערך לא תקין ב${n(d.origin??"array")}`;default:return"קלט לא תקין"}}};function TA(){return{localeError:OA()}}const CA=()=>{const e={string:{unit:"karakter",verb:"legyen"},file:{unit:"byte",verb:"legyen"},array:{unit:"elem",verb:"legyen"},set:{unit:"elem",verb:"legyen"}};function t(n){return e[n]??null}const i={regex:"bemenet",email:"email cím",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO időbélyeg",date:"ISO dátum",time:"ISO idő",duration:"ISO időintervallum",ipv4:"IPv4 cím",ipv6:"IPv6 cím",cidrv4:"IPv4 tartomány",cidrv6:"IPv6 tartomány",base64:"base64-kódolt string",base64url:"base64url-kódolt string",json_string:"JSON string",e164:"E.164 szám",jwt:"JWT",template_literal:"bemenet"},l={nan:"NaN",number:"szám",array:"tömb"};return n=>{switch(n.code){case"invalid_type":{const o=l[n.expected]??n.expected,s=Se(n.input),f=l[s]??s;return/^[A-Z]/.test(n.expected)?`Érvénytelen bemenet: a várt érték instanceof ${n.expected}, a kapott érték ${f}`:`Érvénytelen bemenet: a várt érték ${o}, a kapott érték ${f}`}case"invalid_value":return n.values.length===1?`Érvénytelen bemenet: a várt érték ${xe(n.values[0])}`:`Érvénytelen opció: valamelyik érték várt ${ae(n.values,"|")}`;case"too_big":{const o=n.inclusive?"<=":"<",s=t(n.origin);return s?`Túl nagy: ${n.origin??"érték"} mérete túl nagy ${o}${n.maximum.toString()} ${s.unit??"elem"}`:`Túl nagy: a bemeneti érték ${n.origin??"érték"} túl nagy: ${o}${n.maximum.toString()}`}case"too_small":{const o=n.inclusive?">=":">",s=t(n.origin);return s?`Túl kicsi: a bemeneti érték ${n.origin} mérete túl kicsi ${o}${n.minimum.toString()} ${s.unit}`:`Túl kicsi: a bemeneti érték ${n.origin} túl kicsi ${o}${n.minimum.toString()}`}case"invalid_format":{const o=n;return o.format==="starts_with"?`Érvénytelen string: "${o.prefix}" értékkel kell kezdődnie`:o.format==="ends_with"?`Érvénytelen string: "${o.suffix}" értékkel kell végződnie`:o.format==="includes"?`Érvénytelen string: "${o.includes}" értéket kell tartalmaznia`:o.format==="regex"?`Érvénytelen string: ${o.pattern} mintának kell megfelelnie`:`Érvénytelen ${i[o.format]??n.format}`}case"not_multiple_of":return`Érvénytelen szám: ${n.divisor} többszörösének kell lennie`;case"unrecognized_keys":return`Ismeretlen kulcs${n.keys.length>1?"s":""}: ${ae(n.keys,", ")}`;case"invalid_key":return`Érvénytelen kulcs ${n.origin}`;case"invalid_union":return"Érvénytelen bemenet";case"invalid_element":return`Érvénytelen érték: ${n.origin}`;default:return"Érvénytelen bemenet"}}};function DA(){return{localeError:CA()}}function E_(e,t,i){return Math.abs(e)===1?t:i}function Ra(e){if(!e)return"";const t=["ա","ե","ը","ի","ո","ու","օ"],i=e[e.length-1];return e+(t.includes(i)?"ն":"ը")}const AA=()=>{const e={string:{unit:{one:"նշան",many:"նշաններ"},verb:"ունենալ"},file:{unit:{one:"բայթ",many:"բայթեր"},verb:"ունենալ"},array:{unit:{one:"տարր",many:"տարրեր"},verb:"ունենալ"},set:{unit:{one:"տարր",many:"տարրեր"},verb:"ունենալ"}};function t(n){return e[n]??null}const i={regex:"մուտք",email:"էլ. հասցե",url:"URL",emoji:"էմոջի",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO ամսաթիվ և ժամ",date:"ISO ամսաթիվ",time:"ISO ժամ",duration:"ISO տևողություն",ipv4:"IPv4 հասցե",ipv6:"IPv6 հասցե",cidrv4:"IPv4 միջակայք",cidrv6:"IPv6 միջակայք",base64:"base64 ձևաչափով տող",base64url:"base64url ձևաչափով տող",json_string:"JSON տող",e164:"E.164 համար",jwt:"JWT",template_literal:"մուտք"},l={nan:"NaN",number:"թիվ",array:"զանգված"};return n=>{switch(n.code){case"invalid_type":{const o=l[n.expected]??n.expected,s=Se(n.input),f=l[s]??s;return/^[A-Z]/.test(n.expected)?`Սխալ մուտքագրում․ սպասվում էր instanceof ${n.expected}, ստացվել է ${f}`:`Սխալ մուտքագրում․ սպասվում էր ${o}, ստացվել է ${f}`}case"invalid_value":return n.values.length===1?`Սխալ մուտքագրում․ սպասվում էր ${xe(n.values[1])}`:`Սխալ տարբերակ․ սպասվում էր հետևյալներից մեկը՝ ${ae(n.values,"|")}`;case"too_big":{const o=n.inclusive?"<=":"<",s=t(n.origin);if(s){const f=Number(n.maximum),m=E_(f,s.unit.one,s.unit.many);return`Չափազանց մեծ արժեք․ սպասվում է, որ ${Ra(n.origin??"արժեք")} կունենա ${o}${n.maximum.toString()} ${m}`}return`Չափազանց մեծ արժեք․ սպասվում է, որ ${Ra(n.origin??"արժեք")} լինի ${o}${n.maximum.toString()}`}case"too_small":{const o=n.inclusive?">=":">",s=t(n.origin);if(s){const f=Number(n.minimum),m=E_(f,s.unit.one,s.unit.many);return`Չափազանց փոքր արժեք․ սպասվում է, որ ${Ra(n.origin)} կունենա ${o}${n.minimum.toString()} ${m}`}return`Չափազանց փոքր արժեք․ սպասվում է, որ ${Ra(n.origin)} լինի ${o}${n.minimum.toString()}`}case"invalid_format":{const o=n;return o.format==="starts_with"?`Սխալ տող․ պետք է սկսվի "${o.prefix}"-ով`:o.format==="ends_with"?`Սխալ տող․ պետք է ավարտվի "${o.suffix}"-ով`:o.format==="includes"?`Սխալ տող․ պետք է պարունակի "${o.includes}"`:o.format==="regex"?`Սխալ տող․ պետք է համապատասխանի ${o.pattern} ձևաչափին`:`Սխալ ${i[o.format]??n.format}`}case"not_multiple_of":return`Սխալ թիվ․ պետք է բազմապատիկ լինի ${n.divisor}-ի`;case"unrecognized_keys":return`Չճանաչված բանալի${n.keys.length>1?"ներ":""}. ${ae(n.keys,", ")}`;case"invalid_key":return`Սխալ բանալի ${Ra(n.origin)}-ում`;case"invalid_union":return"Սխալ մուտքագրում";case"invalid_element":return`Սխալ արժեք ${Ra(n.origin)}-ում`;default:return"Սխալ մուտքագրում"}}};function RA(){return{localeError:AA()}}const IA=()=>{const e={string:{unit:"karakter",verb:"memiliki"},file:{unit:"byte",verb:"memiliki"},array:{unit:"item",verb:"memiliki"},set:{unit:"item",verb:"memiliki"}};function t(n){return e[n]??null}const i={regex:"input",email:"alamat email",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"tanggal dan waktu format ISO",date:"tanggal format ISO",time:"jam format ISO",duration:"durasi format ISO",ipv4:"alamat IPv4",ipv6:"alamat IPv6",cidrv4:"rentang alamat IPv4",cidrv6:"rentang alamat IPv6",base64:"string dengan enkode base64",base64url:"string dengan enkode base64url",json_string:"string JSON",e164:"angka E.164",jwt:"JWT",template_literal:"input"},l={nan:"NaN"};return n=>{switch(n.code){case"invalid_type":{const o=l[n.expected]??n.expected,s=Se(n.input),f=l[s]??s;return/^[A-Z]/.test(n.expected)?`Input tidak valid: diharapkan instanceof ${n.expected}, diterima ${f}`:`Input tidak valid: diharapkan ${o}, diterima ${f}`}case"invalid_value":return n.values.length===1?`Input tidak valid: diharapkan ${xe(n.values[0])}`:`Pilihan tidak valid: diharapkan salah satu dari ${ae(n.values,"|")}`;case"too_big":{const o=n.inclusive?"<=":"<",s=t(n.origin);return s?`Terlalu besar: diharapkan ${n.origin??"value"} memiliki ${o}${n.maximum.toString()} ${s.unit??"elemen"}`:`Terlalu besar: diharapkan ${n.origin??"value"} menjadi ${o}${n.maximum.toString()}`}case"too_small":{const o=n.inclusive?">=":">",s=t(n.origin);return s?`Terlalu kecil: diharapkan ${n.origin} memiliki ${o}${n.minimum.toString()} ${s.unit}`:`Terlalu kecil: diharapkan ${n.origin} menjadi ${o}${n.minimum.toString()}`}case"invalid_format":{const o=n;return o.format==="starts_with"?`String tidak valid: harus dimulai dengan "${o.prefix}"`:o.format==="ends_with"?`String tidak valid: harus berakhir dengan "${o.suffix}"`:o.format==="includes"?`String tidak valid: harus menyertakan "${o.includes}"`:o.format==="regex"?`String tidak valid: harus sesuai pola ${o.pattern}`:`${i[o.format]??n.format} tidak valid`}case"not_multiple_of":return`Angka tidak valid: harus kelipatan dari ${n.divisor}`;case"unrecognized_keys":return`Kunci tidak dikenali ${n.keys.length>1?"s":""}: ${ae(n.keys,", ")}`;case"invalid_key":return`Kunci tidak valid di ${n.origin}`;case"invalid_union":return"Input tidak valid";case"invalid_element":return`Nilai tidak valid di ${n.origin}`;default:return"Input tidak valid"}}};function UA(){return{localeError:IA()}}const LA=()=>{const e={string:{unit:"stafi",verb:"að hafa"},file:{unit:"bæti",verb:"að hafa"},array:{unit:"hluti",verb:"að hafa"},set:{unit:"hluti",verb:"að hafa"}};function t(n){return e[n]??null}const i={regex:"gildi",email:"netfang",url:"vefslóð",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO dagsetning og tími",date:"ISO dagsetning",time:"ISO tími",duration:"ISO tímalengd",ipv4:"IPv4 address",ipv6:"IPv6 address",cidrv4:"IPv4 range",cidrv6:"IPv6 range",base64:"base64-encoded strengur",base64url:"base64url-encoded strengur",json_string:"JSON strengur",e164:"E.164 tölugildi",jwt:"JWT",template_literal:"gildi"},l={nan:"NaN",number:"númer",array:"fylki"};return n=>{switch(n.code){case"invalid_type":{const o=l[n.expected]??n.expected,s=Se(n.input),f=l[s]??s;return/^[A-Z]/.test(n.expected)?`Rangt gildi: Þú slóst inn ${f} þar sem á að vera instanceof ${n.expected}`:`Rangt gildi: Þú slóst inn ${f} þar sem á að vera ${o}`}case"invalid_value":return n.values.length===1?`Rangt gildi: gert ráð fyrir ${xe(n.values[0])}`:`Ógilt val: má vera eitt af eftirfarandi ${ae(n.values,"|")}`;case"too_big":{const o=n.inclusive?"<=":"<",s=t(n.origin);return s?`Of stórt: gert er ráð fyrir að ${n.origin??"gildi"} hafi ${o}${n.maximum.toString()} ${s.unit??"hluti"}`:`Of stórt: gert er ráð fyrir að ${n.origin??"gildi"} sé ${o}${n.maximum.toString()}`}case"too_small":{const o=n.inclusive?">=":">",s=t(n.origin);return s?`Of lítið: gert er ráð fyrir að ${n.origin} hafi ${o}${n.minimum.toString()} ${s.unit}`:`Of lítið: gert er ráð fyrir að ${n.origin} sé ${o}${n.minimum.toString()}`}case"invalid_format":{const o=n;return o.format==="starts_with"?`Ógildur strengur: verður að byrja á "${o.prefix}"`:o.format==="ends_with"?`Ógildur strengur: verður að enda á "${o.suffix}"`:o.format==="includes"?`Ógildur strengur: verður að innihalda "${o.includes}"`:o.format==="regex"?`Ógildur strengur: verður að fylgja mynstri ${o.pattern}`:`Rangt ${i[o.format]??n.format}`}case"not_multiple_of":return`Röng tala: verður að vera margfeldi af ${n.divisor}`;case"unrecognized_keys":return`Óþekkt ${n.keys.length>1?"ir lyklar":"ur lykill"}: ${ae(n.keys,", ")}`;case"invalid_key":return`Rangur lykill í ${n.origin}`;case"invalid_union":return"Rangt gildi";case"invalid_element":return`Rangt gildi í ${n.origin}`;default:return"Rangt gildi"}}};function MA(){return{localeError:LA()}}const PA=()=>{const e={string:{unit:"caratteri",verb:"avere"},file:{unit:"byte",verb:"avere"},array:{unit:"elementi",verb:"avere"},set:{unit:"elementi",verb:"avere"}};function t(n){return e[n]??null}const i={regex:"input",email:"indirizzo email",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"data e ora ISO",date:"data ISO",time:"ora ISO",duration:"durata ISO",ipv4:"indirizzo IPv4",ipv6:"indirizzo IPv6",cidrv4:"intervallo IPv4",cidrv6:"intervallo IPv6",base64:"stringa codificata in base64",base64url:"URL codificata in base64",json_string:"stringa JSON",e164:"numero E.164",jwt:"JWT",template_literal:"input"},l={nan:"NaN",number:"numero",array:"vettore"};return n=>{switch(n.code){case"invalid_type":{const o=l[n.expected]??n.expected,s=Se(n.input),f=l[s]??s;return/^[A-Z]/.test(n.expected)?`Input non valido: atteso instanceof ${n.expected}, ricevuto ${f}`:`Input non valido: atteso ${o}, ricevuto ${f}`}case"invalid_value":return n.values.length===1?`Input non valido: atteso ${xe(n.values[0])}`:`Opzione non valida: atteso uno tra ${ae(n.values,"|")}`;case"too_big":{const o=n.inclusive?"<=":"<",s=t(n.origin);return s?`Troppo grande: ${n.origin??"valore"} deve avere ${o}${n.maximum.toString()} ${s.unit??"elementi"}`:`Troppo grande: ${n.origin??"valore"} deve essere ${o}${n.maximum.toString()}`}case"too_small":{const o=n.inclusive?">=":">",s=t(n.origin);return s?`Troppo piccolo: ${n.origin} deve avere ${o}${n.minimum.toString()} ${s.unit}`:`Troppo piccolo: ${n.origin} deve essere ${o}${n.minimum.toString()}`}case"invalid_format":{const o=n;return o.format==="starts_with"?`Stringa non valida: deve iniziare con "${o.prefix}"`:o.format==="ends_with"?`Stringa non valida: deve terminare con "${o.suffix}"`:o.format==="includes"?`Stringa non valida: deve includere "${o.includes}"`:o.format==="regex"?`Stringa non valida: deve corrispondere al pattern ${o.pattern}`:`Invalid ${i[o.format]??n.format}`}case"not_multiple_of":return`Numero non valido: deve essere un multiplo di ${n.divisor}`;case"unrecognized_keys":return`Chiav${n.keys.length>1?"i":"e"} non riconosciut${n.keys.length>1?"e":"a"}: ${ae(n.keys,", ")}`;case"invalid_key":return`Chiave non valida in ${n.origin}`;case"invalid_union":return"Input non valido";case"invalid_element":return`Valore non valido in ${n.origin}`;default:return"Input non valido"}}};function ZA(){return{localeError:PA()}}const qA=()=>{const e={string:{unit:"文字",verb:"である"},file:{unit:"バイト",verb:"である"},array:{unit:"要素",verb:"である"},set:{unit:"要素",verb:"である"}};function t(n){return e[n]??null}const i={regex:"入力値",email:"メールアドレス",url:"URL",emoji:"絵文字",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO日時",date:"ISO日付",time:"ISO時刻",duration:"ISO期間",ipv4:"IPv4アドレス",ipv6:"IPv6アドレス",cidrv4:"IPv4範囲",cidrv6:"IPv6範囲",base64:"base64エンコード文字列",base64url:"base64urlエンコード文字列",json_string:"JSON文字列",e164:"E.164番号",jwt:"JWT",template_literal:"入力値"},l={nan:"NaN",number:"数値",array:"配列"};return n=>{switch(n.code){case"invalid_type":{const o=l[n.expected]??n.expected,s=Se(n.input),f=l[s]??s;return/^[A-Z]/.test(n.expected)?`無効な入力: instanceof ${n.expected}が期待されましたが、${f}が入力されました`:`無効な入力: ${o}が期待されましたが、${f}が入力されました`}case"invalid_value":return n.values.length===1?`無効な入力: ${xe(n.values[0])}が期待されました`:`無効な選択: ${ae(n.values,"、")}のいずれかである必要があります`;case"too_big":{const o=n.inclusive?"以下である":"より小さい",s=t(n.origin);return s?`大きすぎる値: ${n.origin??"値"}は${n.maximum.toString()}${s.unit??"要素"}${o}必要があります`:`大きすぎる値: ${n.origin??"値"}は${n.maximum.toString()}${o}必要があります`}case"too_small":{const o=n.inclusive?"以上である":"より大きい",s=t(n.origin);return s?`小さすぎる値: ${n.origin}は${n.minimum.toString()}${s.unit}${o}必要があります`:`小さすぎる値: ${n.origin}は${n.minimum.toString()}${o}必要があります`}case"invalid_format":{const o=n;return o.format==="starts_with"?`無効な文字列: "${o.prefix}"で始まる必要があります`:o.format==="ends_with"?`無効な文字列: "${o.suffix}"で終わる必要があります`:o.format==="includes"?`無効な文字列: "${o.includes}"を含む必要があります`:o.format==="regex"?`無効な文字列: パターン${o.pattern}に一致する必要があります`:`無効な${i[o.format]??n.format}`}case"not_multiple_of":return`無効な数値: ${n.divisor}の倍数である必要があります`;case"unrecognized_keys":return`認識されていないキー${n.keys.length>1?"群":""}: ${ae(n.keys,"、")}`;case"invalid_key":return`${n.origin}内の無効なキー`;case"invalid_union":return"無効な入力";case"invalid_element":return`${n.origin}内の無効な値`;default:return"無効な入力"}}};function FA(){return{localeError:qA()}}const BA=()=>{const e={string:{unit:"სიმბოლო",verb:"უნდა შეიცავდეს"},file:{unit:"ბაიტი",verb:"უნდა შეიცავდეს"},array:{unit:"ელემენტი",verb:"უნდა შეიცავდეს"},set:{unit:"ელემენტი",verb:"უნდა შეიცავდეს"}};function t(n){return e[n]??null}const i={regex:"შეყვანა",email:"ელ-ფოსტის მისამართი",url:"URL",emoji:"ემოჯი",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"თარიღი-დრო",date:"თარიღი",time:"დრო",duration:"ხანგრძლივობა",ipv4:"IPv4 მისამართი",ipv6:"IPv6 მისამართი",cidrv4:"IPv4 დიაპაზონი",cidrv6:"IPv6 დიაპაზონი",base64:"base64-კოდირებული სტრინგი",base64url:"base64url-კოდირებული სტრინგი",json_string:"JSON სტრინგი",e164:"E.164 ნომერი",jwt:"JWT",template_literal:"შეყვანა"},l={nan:"NaN",number:"რიცხვი",string:"სტრინგი",boolean:"ბულეანი",function:"ფუნქცია",array:"მასივი"};return n=>{switch(n.code){case"invalid_type":{const o=l[n.expected]??n.expected,s=Se(n.input),f=l[s]??s;return/^[A-Z]/.test(n.expected)?`არასწორი შეყვანა: მოსალოდნელი instanceof ${n.expected}, მიღებული ${f}`:`არასწორი შეყვანა: მოსალოდნელი ${o}, მიღებული ${f}`}case"invalid_value":return n.values.length===1?`არასწორი შეყვანა: მოსალოდნელი ${xe(n.values[0])}`:`არასწორი ვარიანტი: მოსალოდნელია ერთ-ერთი ${ae(n.values,"|")}-დან`;case"too_big":{const o=n.inclusive?"<=":"<",s=t(n.origin);return s?`ზედმეტად დიდი: მოსალოდნელი ${n.origin??"მნიშვნელობა"} ${s.verb} ${o}${n.maximum.toString()} ${s.unit}`:`ზედმეტად დიდი: მოსალოდნელი ${n.origin??"მნიშვნელობა"} იყოს ${o}${n.maximum.toString()}`}case"too_small":{const o=n.inclusive?">=":">",s=t(n.origin);return s?`ზედმეტად პატარა: მოსალოდნელი ${n.origin} ${s.verb} ${o}${n.minimum.toString()} ${s.unit}`:`ზედმეტად პატარა: მოსალოდნელი ${n.origin} იყოს ${o}${n.minimum.toString()}`}case"invalid_format":{const o=n;return o.format==="starts_with"?`არასწორი სტრინგი: უნდა იწყებოდეს "${o.prefix}"-ით`:o.format==="ends_with"?`არასწორი სტრინგი: უნდა მთავრდებოდეს "${o.suffix}"-ით`:o.format==="includes"?`არასწორი სტრინგი: უნდა შეიცავდეს "${o.includes}"-ს`:o.format==="regex"?`არასწორი სტრინგი: უნდა შეესაბამებოდეს შაბლონს ${o.pattern}`:`არასწორი ${i[o.format]??n.format}`}case"not_multiple_of":return`არასწორი რიცხვი: უნდა იყოს ${n.divisor}-ის ჯერადი`;case"unrecognized_keys":return`უცნობი გასაღებ${n.keys.length>1?"ები":"ი"}: ${ae(n.keys,", ")}`;case"invalid_key":return`არასწორი გასაღები ${n.origin}-ში`;case"invalid_union":return"არასწორი შეყვანა";case"invalid_element":return`არასწორი მნიშვნელობა ${n.origin}-ში`;default:return"არასწორი შეყვანა"}}};function HA(){return{localeError:BA()}}const GA=()=>{const e={string:{unit:"តួអក្សរ",verb:"គួរមាន"},file:{unit:"បៃ",verb:"គួរមាន"},array:{unit:"ធាតុ",verb:"គួរមាន"},set:{unit:"ធាតុ",verb:"គួរមាន"}};function t(n){return e[n]??null}const i={regex:"ទិន្នន័យបញ្ចូល",email:"អាសយដ្ឋានអ៊ីមែល",url:"URL",emoji:"សញ្ញាអារម្មណ៍",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"កាលបរិច្ឆេទ និងម៉ោង ISO",date:"កាលបរិច្ឆេទ ISO",time:"ម៉ោង ISO",duration:"រយៈពេល ISO",ipv4:"អាសយដ្ឋាន IPv4",ipv6:"អាសយដ្ឋាន IPv6",cidrv4:"ដែនអាសយដ្ឋាន IPv4",cidrv6:"ដែនអាសយដ្ឋាន IPv6",base64:"ខ្សែអក្សរអ៊ិកូដ base64",base64url:"ខ្សែអក្សរអ៊ិកូដ base64url",json_string:"ខ្សែអក្សរ JSON",e164:"លេខ E.164",jwt:"JWT",template_literal:"ទិន្នន័យបញ្ចូល"},l={nan:"NaN",number:"លេខ",array:"អារេ (Array)",null:"គ្មានតម្លៃ (null)"};return n=>{switch(n.code){case"invalid_type":{const o=l[n.expected]??n.expected,s=Se(n.input),f=l[s]??s;return/^[A-Z]/.test(n.expected)?`ទិន្នន័យបញ្ចូលមិនត្រឹមត្រូវ៖ ត្រូវការ instanceof ${n.expected} ប៉ុន្តែទទួលបាន ${f}`:`ទិន្នន័យបញ្ចូលមិនត្រឹមត្រូវ៖ ត្រូវការ ${o} ប៉ុន្តែទទួលបាន ${f}`}case"invalid_value":return n.values.length===1?`ទិន្នន័យបញ្ចូលមិនត្រឹមត្រូវ៖ ត្រូវការ ${xe(n.values[0])}`:`ជម្រើសមិនត្រឹមត្រូវ៖ ត្រូវជាមួយក្នុងចំណោម ${ae(n.values,"|")}`;case"too_big":{const o=n.inclusive?"<=":"<",s=t(n.origin);return s?`ធំពេក៖ ត្រូវការ ${n.origin??"តម្លៃ"} ${o} ${n.maximum.toString()} ${s.unit??"ធាតុ"}`:`ធំពេក៖ ត្រូវការ ${n.origin??"តម្លៃ"} ${o} ${n.maximum.toString()}`}case"too_small":{const o=n.inclusive?">=":">",s=t(n.origin);return s?`តូចពេក៖ ត្រូវការ ${n.origin} ${o} ${n.minimum.toString()} ${s.unit}`:`តូចពេក៖ ត្រូវការ ${n.origin} ${o} ${n.minimum.toString()}`}case"invalid_format":{const o=n;return o.format==="starts_with"?`ខ្សែអក្សរមិនត្រឹមត្រូវ៖ ត្រូវចាប់ផ្តើមដោយ "${o.prefix}"`:o.format==="ends_with"?`ខ្សែអក្សរមិនត្រឹមត្រូវ៖ ត្រូវបញ្ចប់ដោយ "${o.suffix}"`:o.format==="includes"?`ខ្សែអក្សរមិនត្រឹមត្រូវ៖ ត្រូវមាន "${o.includes}"`:o.format==="regex"?`ខ្សែអក្សរមិនត្រឹមត្រូវ៖ ត្រូវតែផ្គូផ្គងនឹងទម្រង់ដែលបានកំណត់ ${o.pattern}`:`មិនត្រឹមត្រូវ៖ ${i[o.format]??n.format}`}case"not_multiple_of":return`លេខមិនត្រឹមត្រូវ៖ ត្រូវតែជាពហុគុណនៃ ${n.divisor}`;case"unrecognized_keys":return`រកឃើញសោមិនស្គាល់៖ ${ae(n.keys,", ")}`;case"invalid_key":return`សោមិនត្រឹមត្រូវនៅក្នុង ${n.origin}`;case"invalid_union":return"ទិន្នន័យមិនត្រឹមត្រូវ";case"invalid_element":return`ទិន្នន័យមិនត្រឹមត្រូវនៅក្នុង ${n.origin}`;default:return"ទិន្នន័យមិនត្រឹមត្រូវ"}}};function A$(){return{localeError:GA()}}function VA(){return A$()}const YA=()=>{const e={string:{unit:"문자",verb:"to have"},file:{unit:"바이트",verb:"to have"},array:{unit:"개",verb:"to have"},set:{unit:"개",verb:"to have"}};function t(n){return e[n]??null}const i={regex:"입력",email:"이메일 주소",url:"URL",emoji:"이모지",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO 날짜시간",date:"ISO 날짜",time:"ISO 시간",duration:"ISO 기간",ipv4:"IPv4 주소",ipv6:"IPv6 주소",cidrv4:"IPv4 범위",cidrv6:"IPv6 범위",base64:"base64 인코딩 문자열",base64url:"base64url 인코딩 문자열",json_string:"JSON 문자열",e164:"E.164 번호",jwt:"JWT",template_literal:"입력"},l={nan:"NaN"};return n=>{switch(n.code){case"invalid_type":{const o=l[n.expected]??n.expected,s=Se(n.input),f=l[s]??s;return/^[A-Z]/.test(n.expected)?`잘못된 입력: 예상 타입은 instanceof ${n.expected}, 받은 타입은 ${f}입니다`:`잘못된 입력: 예상 타입은 ${o}, 받은 타입은 ${f}입니다`}case"invalid_value":return n.values.length===1?`잘못된 입력: 값은 ${xe(n.values[0])} 이어야 합니다`:`잘못된 옵션: ${ae(n.values,"또는 ")} 중 하나여야 합니다`;case"too_big":{const o=n.inclusive?"이하":"미만",s=o==="미만"?"이어야 합니다":"여야 합니다",f=t(n.origin),m=f?.unit??"요소";return f?`${n.origin??"값"}이 너무 큽니다: ${n.maximum.toString()}${m} ${o}${s}`:`${n.origin??"값"}이 너무 큽니다: ${n.maximum.toString()} ${o}${s}`}case"too_small":{const o=n.inclusive?"이상":"초과",s=o==="이상"?"이어야 합니다":"여야 합니다",f=t(n.origin),m=f?.unit??"요소";return f?`${n.origin??"값"}이 너무 작습니다: ${n.minimum.toString()}${m} ${o}${s}`:`${n.origin??"값"}이 너무 작습니다: ${n.minimum.toString()} ${o}${s}`}case"invalid_format":{const o=n;return o.format==="starts_with"?`잘못된 문자열: "${o.prefix}"(으)로 시작해야 합니다`:o.format==="ends_with"?`잘못된 문자열: "${o.suffix}"(으)로 끝나야 합니다`:o.format==="includes"?`잘못된 문자열: "${o.includes}"을(를) 포함해야 합니다`:o.format==="regex"?`잘못된 문자열: 정규식 ${o.pattern} 패턴과 일치해야 합니다`:`잘못된 ${i[o.format]??n.format}`}case"not_multiple_of":return`잘못된 숫자: ${n.divisor}의 배수여야 합니다`;case"unrecognized_keys":return`인식할 수 없는 키: ${ae(n.keys,", ")}`;case"invalid_key":return`잘못된 키: ${n.origin}`;case"invalid_union":return"잘못된 입력";case"invalid_element":return`잘못된 값: ${n.origin}`;default:return"잘못된 입력"}}};function JA(){return{localeError:YA()}}const no=e=>e.charAt(0).toUpperCase()+e.slice(1);function j_(e){const t=Math.abs(e),i=t%10,l=t%100;return l>=11&&l<=19||i===0?"many":i===1?"one":"few"}const XA=()=>{const e={string:{unit:{one:"simbolis",few:"simboliai",many:"simbolių"},verb:{smaller:{inclusive:"turi būti ne ilgesnė kaip",notInclusive:"turi būti trumpesnė kaip"},bigger:{inclusive:"turi būti ne trumpesnė kaip",notInclusive:"turi būti ilgesnė kaip"}}},file:{unit:{one:"baitas",few:"baitai",many:"baitų"},verb:{smaller:{inclusive:"turi būti ne didesnis kaip",notInclusive:"turi būti mažesnis kaip"},bigger:{inclusive:"turi būti ne mažesnis kaip",notInclusive:"turi būti didesnis kaip"}}},array:{unit:{one:"elementą",few:"elementus",many:"elementų"},verb:{smaller:{inclusive:"turi turėti ne daugiau kaip",notInclusive:"turi turėti mažiau kaip"},bigger:{inclusive:"turi turėti ne mažiau kaip",notInclusive:"turi turėti daugiau kaip"}}},set:{unit:{one:"elementą",few:"elementus",many:"elementų"},verb:{smaller:{inclusive:"turi turėti ne daugiau kaip",notInclusive:"turi turėti mažiau kaip"},bigger:{inclusive:"turi turėti ne mažiau kaip",notInclusive:"turi turėti daugiau kaip"}}}};function t(n,o,s,f){const m=e[n]??null;return m===null?m:{unit:m.unit[o],verb:m.verb[f][s?"inclusive":"notInclusive"]}}const i={regex:"įvestis",email:"el. pašto adresas",url:"URL",emoji:"jaustukas",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO data ir laikas",date:"ISO data",time:"ISO laikas",duration:"ISO trukmė",ipv4:"IPv4 adresas",ipv6:"IPv6 adresas",cidrv4:"IPv4 tinklo prefiksas (CIDR)",cidrv6:"IPv6 tinklo prefiksas (CIDR)",base64:"base64 užkoduota eilutė",base64url:"base64url užkoduota eilutė",json_string:"JSON eilutė",e164:"E.164 numeris",jwt:"JWT",template_literal:"įvestis"},l={nan:"NaN",number:"skaičius",bigint:"sveikasis skaičius",string:"eilutė",boolean:"loginė reikšmė",undefined:"neapibrėžta reikšmė",function:"funkcija",symbol:"simbolis",array:"masyvas",object:"objektas",null:"nulinė reikšmė"};return n=>{switch(n.code){case"invalid_type":{const o=l[n.expected]??n.expected,s=Se(n.input),f=l[s]??s;return/^[A-Z]/.test(n.expected)?`Gautas tipas ${f}, o tikėtasi - instanceof ${n.expected}`:`Gautas tipas ${f}, o tikėtasi - ${o}`}case"invalid_value":return n.values.length===1?`Privalo būti ${xe(n.values[0])}`:`Privalo būti vienas iš ${ae(n.values,"|")} pasirinkimų`;case"too_big":{const o=l[n.origin]??n.origin,s=t(n.origin,j_(Number(n.maximum)),n.inclusive??!1,"smaller");if(s?.verb)return`${no(o??n.origin??"reikšmė")} ${s.verb} ${n.maximum.toString()} ${s.unit??"elementų"}`;const f=n.inclusive?"ne didesnis kaip":"mažesnis kaip";return`${no(o??n.origin??"reikšmė")} turi būti ${f} ${n.maximum.toString()} ${s?.unit}`}case"too_small":{const o=l[n.origin]??n.origin,s=t(n.origin,j_(Number(n.minimum)),n.inclusive??!1,"bigger");if(s?.verb)return`${no(o??n.origin??"reikšmė")} ${s.verb} ${n.minimum.toString()} ${s.unit??"elementų"}`;const f=n.inclusive?"ne mažesnis kaip":"didesnis kaip";return`${no(o??n.origin??"reikšmė")} turi būti ${f} ${n.minimum.toString()} ${s?.unit}`}case"invalid_format":{const o=n;return o.format==="starts_with"?`Eilutė privalo prasidėti "${o.prefix}"`:o.format==="ends_with"?`Eilutė privalo pasibaigti "${o.suffix}"`:o.format==="includes"?`Eilutė privalo įtraukti "${o.includes}"`:o.format==="regex"?`Eilutė privalo atitikti ${o.pattern}`:`Neteisingas ${i[o.format]??n.format}`}case"not_multiple_of":return`Skaičius privalo būti ${n.divisor} kartotinis.`;case"unrecognized_keys":return`Neatpažint${n.keys.length>1?"i":"as"} rakt${n.keys.length>1?"ai":"as"}: ${ae(n.keys,", ")}`;case"invalid_key":return"Rastas klaidingas raktas";case"invalid_union":return"Klaidinga įvestis";case"invalid_element":{const o=l[n.origin]??n.origin;return`${no(o??n.origin??"reikšmė")} turi klaidingą įvestį`}default:return"Klaidinga įvestis"}}};function QA(){return{localeError:XA()}}const KA=()=>{const e={string:{unit:"знаци",verb:"да имаат"},file:{unit:"бајти",verb:"да имаат"},array:{unit:"ставки",verb:"да имаат"},set:{unit:"ставки",verb:"да имаат"}};function t(n){return e[n]??null}const i={regex:"внес",email:"адреса на е-пошта",url:"URL",emoji:"емоџи",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO датум и време",date:"ISO датум",time:"ISO време",duration:"ISO времетраење",ipv4:"IPv4 адреса",ipv6:"IPv6 адреса",cidrv4:"IPv4 опсег",cidrv6:"IPv6 опсег",base64:"base64-енкодирана низа",base64url:"base64url-енкодирана низа",json_string:"JSON низа",e164:"E.164 број",jwt:"JWT",template_literal:"внес"},l={nan:"NaN",number:"број",array:"низа"};return n=>{switch(n.code){case"invalid_type":{const o=l[n.expected]??n.expected,s=Se(n.input),f=l[s]??s;return/^[A-Z]/.test(n.expected)?`Грешен внес: се очекува instanceof ${n.expected}, примено ${f}`:`Грешен внес: се очекува ${o}, примено ${f}`}case"invalid_value":return n.values.length===1?`Invalid input: expected ${xe(n.values[0])}`:`Грешана опција: се очекува една ${ae(n.values,"|")}`;case"too_big":{const o=n.inclusive?"<=":"<",s=t(n.origin);return s?`Премногу голем: се очекува ${n.origin??"вредноста"} да има ${o}${n.maximum.toString()} ${s.unit??"елементи"}`:`Премногу голем: се очекува ${n.origin??"вредноста"} да биде ${o}${n.maximum.toString()}`}case"too_small":{const o=n.inclusive?">=":">",s=t(n.origin);return s?`Премногу мал: се очекува ${n.origin} да има ${o}${n.minimum.toString()} ${s.unit}`:`Премногу мал: се очекува ${n.origin} да биде ${o}${n.minimum.toString()}`}case"invalid_format":{const o=n;return o.format==="starts_with"?`Неважечка низа: мора да започнува со "${o.prefix}"`:o.format==="ends_with"?`Неважечка низа: мора да завршува со "${o.suffix}"`:o.format==="includes"?`Неважечка низа: мора да вклучува "${o.includes}"`:o.format==="regex"?`Неважечка низа: мора да одгоара на патернот ${o.pattern}`:`Invalid ${i[o.format]??n.format}`}case"not_multiple_of":return`Грешен број: мора да биде делив со ${n.divisor}`;case"unrecognized_keys":return`${n.keys.length>1?"Непрепознаени клучеви":"Непрепознаен клуч"}: ${ae(n.keys,", ")}`;case"invalid_key":return`Грешен клуч во ${n.origin}`;case"invalid_union":return"Грешен внес";case"invalid_element":return`Грешна вредност во ${n.origin}`;default:return"Грешен внес"}}};function WA(){return{localeError:KA()}}const eR=()=>{const e={string:{unit:"aksara",verb:"mempunyai"},file:{unit:"bait",verb:"mempunyai"},array:{unit:"elemen",verb:"mempunyai"},set:{unit:"elemen",verb:"mempunyai"}};function t(n){return e[n]??null}const i={regex:"input",email:"alamat e-mel",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"tarikh masa ISO",date:"tarikh ISO",time:"masa ISO",duration:"tempoh ISO",ipv4:"alamat IPv4",ipv6:"alamat IPv6",cidrv4:"julat IPv4",cidrv6:"julat IPv6",base64:"string dikodkan base64",base64url:"string dikodkan base64url",json_string:"string JSON",e164:"nombor E.164",jwt:"JWT",template_literal:"input"},l={nan:"NaN",number:"nombor"};return n=>{switch(n.code){case"invalid_type":{const o=l[n.expected]??n.expected,s=Se(n.input),f=l[s]??s;return/^[A-Z]/.test(n.expected)?`Input tidak sah: dijangka instanceof ${n.expected}, diterima ${f}`:`Input tidak sah: dijangka ${o}, diterima ${f}`}case"invalid_value":return n.values.length===1?`Input tidak sah: dijangka ${xe(n.values[0])}`:`Pilihan tidak sah: dijangka salah satu daripada ${ae(n.values,"|")}`;case"too_big":{const o=n.inclusive?"<=":"<",s=t(n.origin);return s?`Terlalu besar: dijangka ${n.origin??"nilai"} ${s.verb} ${o}${n.maximum.toString()} ${s.unit??"elemen"}`:`Terlalu besar: dijangka ${n.origin??"nilai"} adalah ${o}${n.maximum.toString()}`}case"too_small":{const o=n.inclusive?">=":">",s=t(n.origin);return s?`Terlalu kecil: dijangka ${n.origin} ${s.verb} ${o}${n.minimum.toString()} ${s.unit}`:`Terlalu kecil: dijangka ${n.origin} adalah ${o}${n.minimum.toString()}`}case"invalid_format":{const o=n;return o.format==="starts_with"?`String tidak sah: mesti bermula dengan "${o.prefix}"`:o.format==="ends_with"?`String tidak sah: mesti berakhir dengan "${o.suffix}"`:o.format==="includes"?`String tidak sah: mesti mengandungi "${o.includes}"`:o.format==="regex"?`String tidak sah: mesti sepadan dengan corak ${o.pattern}`:`${i[o.format]??n.format} tidak sah`}case"not_multiple_of":return`Nombor tidak sah: perlu gandaan ${n.divisor}`;case"unrecognized_keys":return`Kunci tidak dikenali: ${ae(n.keys,", ")}`;case"invalid_key":return`Kunci tidak sah dalam ${n.origin}`;case"invalid_union":return"Input tidak sah";case"invalid_element":return`Nilai tidak sah dalam ${n.origin}`;default:return"Input tidak sah"}}};function tR(){return{localeError:eR()}}const nR=()=>{const e={string:{unit:"tekens",verb:"heeft"},file:{unit:"bytes",verb:"heeft"},array:{unit:"elementen",verb:"heeft"},set:{unit:"elementen",verb:"heeft"}};function t(n){return e[n]??null}const i={regex:"invoer",email:"emailadres",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO datum en tijd",date:"ISO datum",time:"ISO tijd",duration:"ISO duur",ipv4:"IPv4-adres",ipv6:"IPv6-adres",cidrv4:"IPv4-bereik",cidrv6:"IPv6-bereik",base64:"base64-gecodeerde tekst",base64url:"base64 URL-gecodeerde tekst",json_string:"JSON string",e164:"E.164-nummer",jwt:"JWT",template_literal:"invoer"},l={nan:"NaN",number:"getal"};return n=>{switch(n.code){case"invalid_type":{const o=l[n.expected]??n.expected,s=Se(n.input),f=l[s]??s;return/^[A-Z]/.test(n.expected)?`Ongeldige invoer: verwacht instanceof ${n.expected}, ontving ${f}`:`Ongeldige invoer: verwacht ${o}, ontving ${f}`}case"invalid_value":return n.values.length===1?`Ongeldige invoer: verwacht ${xe(n.values[0])}`:`Ongeldige optie: verwacht één van ${ae(n.values,"|")}`;case"too_big":{const o=n.inclusive?"<=":"<",s=t(n.origin),f=n.origin==="date"?"laat":n.origin==="string"?"lang":"groot";return s?`Te ${f}: verwacht dat ${n.origin??"waarde"} ${o}${n.maximum.toString()} ${s.unit??"elementen"} ${s.verb}`:`Te ${f}: verwacht dat ${n.origin??"waarde"} ${o}${n.maximum.toString()} is`}case"too_small":{const o=n.inclusive?">=":">",s=t(n.origin),f=n.origin==="date"?"vroeg":n.origin==="string"?"kort":"klein";return s?`Te ${f}: verwacht dat ${n.origin} ${o}${n.minimum.toString()} ${s.unit} ${s.verb}`:`Te ${f}: verwacht dat ${n.origin} ${o}${n.minimum.toString()} is`}case"invalid_format":{const o=n;return o.format==="starts_with"?`Ongeldige tekst: moet met "${o.prefix}" beginnen`:o.format==="ends_with"?`Ongeldige tekst: moet op "${o.suffix}" eindigen`:o.format==="includes"?`Ongeldige tekst: moet "${o.includes}" bevatten`:o.format==="regex"?`Ongeldige tekst: moet overeenkomen met patroon ${o.pattern}`:`Ongeldig: ${i[o.format]??n.format}`}case"not_multiple_of":return`Ongeldig getal: moet een veelvoud van ${n.divisor} zijn`;case"unrecognized_keys":return`Onbekende key${n.keys.length>1?"s":""}: ${ae(n.keys,", ")}`;case"invalid_key":return`Ongeldige key in ${n.origin}`;case"invalid_union":return"Ongeldige invoer";case"invalid_element":return`Ongeldige waarde in ${n.origin}`;default:return"Ongeldige invoer"}}};function rR(){return{localeError:nR()}}const iR=()=>{const e={string:{unit:"tegn",verb:"å ha"},file:{unit:"bytes",verb:"å ha"},array:{unit:"elementer",verb:"å inneholde"},set:{unit:"elementer",verb:"å inneholde"}};function t(n){return e[n]??null}const i={regex:"input",email:"e-postadresse",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO dato- og klokkeslett",date:"ISO-dato",time:"ISO-klokkeslett",duration:"ISO-varighet",ipv4:"IPv4-område",ipv6:"IPv6-område",cidrv4:"IPv4-spekter",cidrv6:"IPv6-spekter",base64:"base64-enkodet streng",base64url:"base64url-enkodet streng",json_string:"JSON-streng",e164:"E.164-nummer",jwt:"JWT",template_literal:"input"},l={nan:"NaN",number:"tall",array:"liste"};return n=>{switch(n.code){case"invalid_type":{const o=l[n.expected]??n.expected,s=Se(n.input),f=l[s]??s;return/^[A-Z]/.test(n.expected)?`Ugyldig input: forventet instanceof ${n.expected}, fikk ${f}`:`Ugyldig input: forventet ${o}, fikk ${f}`}case"invalid_value":return n.values.length===1?`Ugyldig verdi: forventet ${xe(n.values[0])}`:`Ugyldig valg: forventet en av ${ae(n.values,"|")}`;case"too_big":{const o=n.inclusive?"<=":"<",s=t(n.origin);return s?`For stor(t): forventet ${n.origin??"value"} til å ha ${o}${n.maximum.toString()} ${s.unit??"elementer"}`:`For stor(t): forventet ${n.origin??"value"} til å ha ${o}${n.maximum.toString()}`}case"too_small":{const o=n.inclusive?">=":">",s=t(n.origin);return s?`For lite(n): forventet ${n.origin} til å ha ${o}${n.minimum.toString()} ${s.unit}`:`For lite(n): forventet ${n.origin} til å ha ${o}${n.minimum.toString()}`}case"invalid_format":{const o=n;return o.format==="starts_with"?`Ugyldig streng: må starte med "${o.prefix}"`:o.format==="ends_with"?`Ugyldig streng: må ende med "${o.suffix}"`:o.format==="includes"?`Ugyldig streng: må inneholde "${o.includes}"`:o.format==="regex"?`Ugyldig streng: må matche mønsteret ${o.pattern}`:`Ugyldig ${i[o.format]??n.format}`}case"not_multiple_of":return`Ugyldig tall: må være et multiplum av ${n.divisor}`;case"unrecognized_keys":return`${n.keys.length>1?"Ukjente nøkler":"Ukjent nøkkel"}: ${ae(n.keys,", ")}`;case"invalid_key":return`Ugyldig nøkkel i ${n.origin}`;case"invalid_union":return"Ugyldig input";case"invalid_element":return`Ugyldig verdi i ${n.origin}`;default:return"Ugyldig input"}}};function aR(){return{localeError:iR()}}const lR=()=>{const e={string:{unit:"harf",verb:"olmalıdır"},file:{unit:"bayt",verb:"olmalıdır"},array:{unit:"unsur",verb:"olmalıdır"},set:{unit:"unsur",verb:"olmalıdır"}};function t(n){return e[n]??null}const i={regex:"giren",email:"epostagâh",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO hengâmı",date:"ISO tarihi",time:"ISO zamanı",duration:"ISO müddeti",ipv4:"IPv4 nişânı",ipv6:"IPv6 nişânı",cidrv4:"IPv4 menzili",cidrv6:"IPv6 menzili",base64:"base64-şifreli metin",base64url:"base64url-şifreli metin",json_string:"JSON metin",e164:"E.164 sayısı",jwt:"JWT",template_literal:"giren"},l={nan:"NaN",number:"numara",array:"saf",null:"gayb"};return n=>{switch(n.code){case"invalid_type":{const o=l[n.expected]??n.expected,s=Se(n.input),f=l[s]??s;return/^[A-Z]/.test(n.expected)?`Fâsit giren: umulan instanceof ${n.expected}, alınan ${f}`:`Fâsit giren: umulan ${o}, alınan ${f}`}case"invalid_value":return n.values.length===1?`Fâsit giren: umulan ${xe(n.values[0])}`:`Fâsit tercih: mûteberler ${ae(n.values,"|")}`;case"too_big":{const o=n.inclusive?"<=":"<",s=t(n.origin);return s?`Fazla büyük: ${n.origin??"value"}, ${o}${n.maximum.toString()} ${s.unit??"elements"} sahip olmalıydı.`:`Fazla büyük: ${n.origin??"value"}, ${o}${n.maximum.toString()} olmalıydı.`}case"too_small":{const o=n.inclusive?">=":">",s=t(n.origin);return s?`Fazla küçük: ${n.origin}, ${o}${n.minimum.toString()} ${s.unit} sahip olmalıydı.`:`Fazla küçük: ${n.origin}, ${o}${n.minimum.toString()} olmalıydı.`}case"invalid_format":{const o=n;return o.format==="starts_with"?`Fâsit metin: "${o.prefix}" ile başlamalı.`:o.format==="ends_with"?`Fâsit metin: "${o.suffix}" ile bitmeli.`:o.format==="includes"?`Fâsit metin: "${o.includes}" ihtivâ etmeli.`:o.format==="regex"?`Fâsit metin: ${o.pattern} nakşına uymalı.`:`Fâsit ${i[o.format]??n.format}`}case"not_multiple_of":return`Fâsit sayı: ${n.divisor} katı olmalıydı.`;case"unrecognized_keys":return`Tanınmayan anahtar ${n.keys.length>1?"s":""}: ${ae(n.keys,", ")}`;case"invalid_key":return`${n.origin} için tanınmayan anahtar var.`;case"invalid_union":return"Giren tanınamadı.";case"invalid_element":return`${n.origin} için tanınmayan kıymet var.`;default:return"Kıymet tanınamadı."}}};function oR(){return{localeError:lR()}}const uR=()=>{const e={string:{unit:"توکي",verb:"ولري"},file:{unit:"بایټس",verb:"ولري"},array:{unit:"توکي",verb:"ولري"},set:{unit:"توکي",verb:"ولري"}};function t(n){return e[n]??null}const i={regex:"ورودي",email:"بریښنالیک",url:"یو آر ال",emoji:"ایموجي",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"نیټه او وخت",date:"نېټه",time:"وخت",duration:"موده",ipv4:"د IPv4 پته",ipv6:"د IPv6 پته",cidrv4:"د IPv4 ساحه",cidrv6:"د IPv6 ساحه",base64:"base64-encoded متن",base64url:"base64url-encoded متن",json_string:"JSON متن",e164:"د E.164 شمېره",jwt:"JWT",template_literal:"ورودي"},l={nan:"NaN",number:"عدد",array:"ارې"};return n=>{switch(n.code){case"invalid_type":{const o=l[n.expected]??n.expected,s=Se(n.input),f=l[s]??s;return/^[A-Z]/.test(n.expected)?`ناسم ورودي: باید instanceof ${n.expected} وای, مګر ${f} ترلاسه شو`:`ناسم ورودي: باید ${o} وای, مګر ${f} ترلاسه شو`}case"invalid_value":return n.values.length===1?`ناسم ورودي: باید ${xe(n.values[0])} وای`:`ناسم انتخاب: باید یو له ${ae(n.values,"|")} څخه وای`;case"too_big":{const o=n.inclusive?"<=":"<",s=t(n.origin);return s?`ډیر لوی: ${n.origin??"ارزښت"} باید ${o}${n.maximum.toString()} ${s.unit??"عنصرونه"} ولري`:`ډیر لوی: ${n.origin??"ارزښت"} باید ${o}${n.maximum.toString()} وي`}case"too_small":{const o=n.inclusive?">=":">",s=t(n.origin);return s?`ډیر کوچنی: ${n.origin} باید ${o}${n.minimum.toString()} ${s.unit} ولري`:`ډیر کوچنی: ${n.origin} باید ${o}${n.minimum.toString()} وي`}case"invalid_format":{const o=n;return o.format==="starts_with"?`ناسم متن: باید د "${o.prefix}" سره پیل شي`:o.format==="ends_with"?`ناسم متن: باید د "${o.suffix}" سره پای ته ورسيږي`:o.format==="includes"?`ناسم متن: باید "${o.includes}" ولري`:o.format==="regex"?`ناسم متن: باید د ${o.pattern} سره مطابقت ولري`:`${i[o.format]??n.format} ناسم دی`}case"not_multiple_of":return`ناسم عدد: باید د ${n.divisor} مضرب وي`;case"unrecognized_keys":return`ناسم ${n.keys.length>1?"کلیډونه":"کلیډ"}: ${ae(n.keys,", ")}`;case"invalid_key":return`ناسم کلیډ په ${n.origin} کې`;case"invalid_union":return"ناسمه ورودي";case"invalid_element":return`ناسم عنصر په ${n.origin} کې`;default:return"ناسمه ورودي"}}};function sR(){return{localeError:uR()}}const cR=()=>{const e={string:{unit:"znaków",verb:"mieć"},file:{unit:"bajtów",verb:"mieć"},array:{unit:"elementów",verb:"mieć"},set:{unit:"elementów",verb:"mieć"}};function t(n){return e[n]??null}const i={regex:"wyrażenie",email:"adres email",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"data i godzina w formacie ISO",date:"data w formacie ISO",time:"godzina w formacie ISO",duration:"czas trwania ISO",ipv4:"adres IPv4",ipv6:"adres IPv6",cidrv4:"zakres IPv4",cidrv6:"zakres IPv6",base64:"ciąg znaków zakodowany w formacie base64",base64url:"ciąg znaków zakodowany w formacie base64url",json_string:"ciąg znaków w formacie JSON",e164:"liczba E.164",jwt:"JWT",template_literal:"wejście"},l={nan:"NaN",number:"liczba",array:"tablica"};return n=>{switch(n.code){case"invalid_type":{const o=l[n.expected]??n.expected,s=Se(n.input),f=l[s]??s;return/^[A-Z]/.test(n.expected)?`Nieprawidłowe dane wejściowe: oczekiwano instanceof ${n.expected}, otrzymano ${f}`:`Nieprawidłowe dane wejściowe: oczekiwano ${o}, otrzymano ${f}`}case"invalid_value":return n.values.length===1?`Nieprawidłowe dane wejściowe: oczekiwano ${xe(n.values[0])}`:`Nieprawidłowa opcja: oczekiwano jednej z wartości ${ae(n.values,"|")}`;case"too_big":{const o=n.inclusive?"<=":"<",s=t(n.origin);return s?`Za duża wartość: oczekiwano, że ${n.origin??"wartość"} będzie mieć ${o}${n.maximum.toString()} ${s.unit??"elementów"}`:`Zbyt duż(y/a/e): oczekiwano, że ${n.origin??"wartość"} będzie wynosić ${o}${n.maximum.toString()}`}case"too_small":{const o=n.inclusive?">=":">",s=t(n.origin);return s?`Za mała wartość: oczekiwano, że ${n.origin??"wartość"} będzie mieć ${o}${n.minimum.toString()} ${s.unit??"elementów"}`:`Zbyt mał(y/a/e): oczekiwano, że ${n.origin??"wartość"} będzie wynosić ${o}${n.minimum.toString()}`}case"invalid_format":{const o=n;return o.format==="starts_with"?`Nieprawidłowy ciąg znaków: musi zaczynać się od "${o.prefix}"`:o.format==="ends_with"?`Nieprawidłowy ciąg znaków: musi kończyć się na "${o.suffix}"`:o.format==="includes"?`Nieprawidłowy ciąg znaków: musi zawierać "${o.includes}"`:o.format==="regex"?`Nieprawidłowy ciąg znaków: musi odpowiadać wzorcowi ${o.pattern}`:`Nieprawidłow(y/a/e) ${i[o.format]??n.format}`}case"not_multiple_of":return`Nieprawidłowa liczba: musi być wielokrotnością ${n.divisor}`;case"unrecognized_keys":return`Nierozpoznane klucze${n.keys.length>1?"s":""}: ${ae(n.keys,", ")}`;case"invalid_key":return`Nieprawidłowy klucz w ${n.origin}`;case"invalid_union":return"Nieprawidłowe dane wejściowe";case"invalid_element":return`Nieprawidłowa wartość w ${n.origin}`;default:return"Nieprawidłowe dane wejściowe"}}};function fR(){return{localeError:cR()}}const dR=()=>{const e={string:{unit:"caracteres",verb:"ter"},file:{unit:"bytes",verb:"ter"},array:{unit:"itens",verb:"ter"},set:{unit:"itens",verb:"ter"}};function t(n){return e[n]??null}const i={regex:"padrão",email:"endereço de e-mail",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"data e hora ISO",date:"data ISO",time:"hora ISO",duration:"duração ISO",ipv4:"endereço IPv4",ipv6:"endereço IPv6",cidrv4:"faixa de IPv4",cidrv6:"faixa de IPv6",base64:"texto codificado em base64",base64url:"URL codificada em base64",json_string:"texto JSON",e164:"número E.164",jwt:"JWT",template_literal:"entrada"},l={nan:"NaN",number:"número",null:"nulo"};return n=>{switch(n.code){case"invalid_type":{const o=l[n.expected]??n.expected,s=Se(n.input),f=l[s]??s;return/^[A-Z]/.test(n.expected)?`Tipo inválido: esperado instanceof ${n.expected}, recebido ${f}`:`Tipo inválido: esperado ${o}, recebido ${f}`}case"invalid_value":return n.values.length===1?`Entrada inválida: esperado ${xe(n.values[0])}`:`Opção inválida: esperada uma das ${ae(n.values,"|")}`;case"too_big":{const o=n.inclusive?"<=":"<",s=t(n.origin);return s?`Muito grande: esperado que ${n.origin??"valor"} tivesse ${o}${n.maximum.toString()} ${s.unit??"elementos"}`:`Muito grande: esperado que ${n.origin??"valor"} fosse ${o}${n.maximum.toString()}`}case"too_small":{const o=n.inclusive?">=":">",s=t(n.origin);return s?`Muito pequeno: esperado que ${n.origin} tivesse ${o}${n.minimum.toString()} ${s.unit}`:`Muito pequeno: esperado que ${n.origin} fosse ${o}${n.minimum.toString()}`}case"invalid_format":{const o=n;return o.format==="starts_with"?`Texto inválido: deve começar com "${o.prefix}"`:o.format==="ends_with"?`Texto inválido: deve terminar com "${o.suffix}"`:o.format==="includes"?`Texto inválido: deve incluir "${o.includes}"`:o.format==="regex"?`Texto inválido: deve corresponder ao padrão ${o.pattern}`:`${i[o.format]??n.format} inválido`}case"not_multiple_of":return`Número inválido: deve ser múltiplo de ${n.divisor}`;case"unrecognized_keys":return`Chave${n.keys.length>1?"s":""} desconhecida${n.keys.length>1?"s":""}: ${ae(n.keys,", ")}`;case"invalid_key":return`Chave inválida em ${n.origin}`;case"invalid_union":return"Entrada inválida";case"invalid_element":return`Valor inválido em ${n.origin}`;default:return"Campo inválido"}}};function mR(){return{localeError:dR()}}function z_(e,t,i,l){const n=Math.abs(e),o=n%10,s=n%100;return s>=11&&s<=19?l:o===1?t:o>=2&&o<=4?i:l}const hR=()=>{const e={string:{unit:{one:"символ",few:"символа",many:"символов"},verb:"иметь"},file:{unit:{one:"байт",few:"байта",many:"байт"},verb:"иметь"},array:{unit:{one:"элемент",few:"элемента",many:"элементов"},verb:"иметь"},set:{unit:{one:"элемент",few:"элемента",many:"элементов"},verb:"иметь"}};function t(n){return e[n]??null}const i={regex:"ввод",email:"email адрес",url:"URL",emoji:"эмодзи",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO дата и время",date:"ISO дата",time:"ISO время",duration:"ISO длительность",ipv4:"IPv4 адрес",ipv6:"IPv6 адрес",cidrv4:"IPv4 диапазон",cidrv6:"IPv6 диапазон",base64:"строка в формате base64",base64url:"строка в формате base64url",json_string:"JSON строка",e164:"номер E.164",jwt:"JWT",template_literal:"ввод"},l={nan:"NaN",number:"число",array:"массив"};return n=>{switch(n.code){case"invalid_type":{const o=l[n.expected]??n.expected,s=Se(n.input),f=l[s]??s;return/^[A-Z]/.test(n.expected)?`Неверный ввод: ожидалось instanceof ${n.expected}, получено ${f}`:`Неверный ввод: ожидалось ${o}, получено ${f}`}case"invalid_value":return n.values.length===1?`Неверный ввод: ожидалось ${xe(n.values[0])}`:`Неверный вариант: ожидалось одно из ${ae(n.values,"|")}`;case"too_big":{const o=n.inclusive?"<=":"<",s=t(n.origin);if(s){const f=Number(n.maximum),m=z_(f,s.unit.one,s.unit.few,s.unit.many);return`Слишком большое значение: ожидалось, что ${n.origin??"значение"} будет иметь ${o}${n.maximum.toString()} ${m}`}return`Слишком большое значение: ожидалось, что ${n.origin??"значение"} будет ${o}${n.maximum.toString()}`}case"too_small":{const o=n.inclusive?">=":">",s=t(n.origin);if(s){const f=Number(n.minimum),m=z_(f,s.unit.one,s.unit.few,s.unit.many);return`Слишком маленькое значение: ожидалось, что ${n.origin} будет иметь ${o}${n.minimum.toString()} ${m}`}return`Слишком маленькое значение: ожидалось, что ${n.origin} будет ${o}${n.minimum.toString()}`}case"invalid_format":{const o=n;return o.format==="starts_with"?`Неверная строка: должна начинаться с "${o.prefix}"`:o.format==="ends_with"?`Неверная строка: должна заканчиваться на "${o.suffix}"`:o.format==="includes"?`Неверная строка: должна содержать "${o.includes}"`:o.format==="regex"?`Неверная строка: должна соответствовать шаблону ${o.pattern}`:`Неверный ${i[o.format]??n.format}`}case"not_multiple_of":return`Неверное число: должно быть кратным ${n.divisor}`;case"unrecognized_keys":return`Нераспознанн${n.keys.length>1?"ые":"ый"} ключ${n.keys.length>1?"и":""}: ${ae(n.keys,", ")}`;case"invalid_key":return`Неверный ключ в ${n.origin}`;case"invalid_union":return"Неверные входные данные";case"invalid_element":return`Неверное значение в ${n.origin}`;default:return"Неверные входные данные"}}};function pR(){return{localeError:hR()}}const gR=()=>{const e={string:{unit:"znakov",verb:"imeti"},file:{unit:"bajtov",verb:"imeti"},array:{unit:"elementov",verb:"imeti"},set:{unit:"elementov",verb:"imeti"}};function t(n){return e[n]??null}const i={regex:"vnos",email:"e-poštni naslov",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO datum in čas",date:"ISO datum",time:"ISO čas",duration:"ISO trajanje",ipv4:"IPv4 naslov",ipv6:"IPv6 naslov",cidrv4:"obseg IPv4",cidrv6:"obseg IPv6",base64:"base64 kodiran niz",base64url:"base64url kodiran niz",json_string:"JSON niz",e164:"E.164 številka",jwt:"JWT",template_literal:"vnos"},l={nan:"NaN",number:"število",array:"tabela"};return n=>{switch(n.code){case"invalid_type":{const o=l[n.expected]??n.expected,s=Se(n.input),f=l[s]??s;return/^[A-Z]/.test(n.expected)?`Neveljaven vnos: pričakovano instanceof ${n.expected}, prejeto ${f}`:`Neveljaven vnos: pričakovano ${o}, prejeto ${f}`}case"invalid_value":return n.values.length===1?`Neveljaven vnos: pričakovano ${xe(n.values[0])}`:`Neveljavna možnost: pričakovano eno izmed ${ae(n.values,"|")}`;case"too_big":{const o=n.inclusive?"<=":"<",s=t(n.origin);return s?`Preveliko: pričakovano, da bo ${n.origin??"vrednost"} imelo ${o}${n.maximum.toString()} ${s.unit??"elementov"}`:`Preveliko: pričakovano, da bo ${n.origin??"vrednost"} ${o}${n.maximum.toString()}`}case"too_small":{const o=n.inclusive?">=":">",s=t(n.origin);return s?`Premajhno: pričakovano, da bo ${n.origin} imelo ${o}${n.minimum.toString()} ${s.unit}`:`Premajhno: pričakovano, da bo ${n.origin} ${o}${n.minimum.toString()}`}case"invalid_format":{const o=n;return o.format==="starts_with"?`Neveljaven niz: mora se začeti z "${o.prefix}"`:o.format==="ends_with"?`Neveljaven niz: mora se končati z "${o.suffix}"`:o.format==="includes"?`Neveljaven niz: mora vsebovati "${o.includes}"`:o.format==="regex"?`Neveljaven niz: mora ustrezati vzorcu ${o.pattern}`:`Neveljaven ${i[o.format]??n.format}`}case"not_multiple_of":return`Neveljavno število: mora biti večkratnik ${n.divisor}`;case"unrecognized_keys":return`Neprepoznan${n.keys.length>1?"i ključi":" ključ"}: ${ae(n.keys,", ")}`;case"invalid_key":return`Neveljaven ključ v ${n.origin}`;case"invalid_union":return"Neveljaven vnos";case"invalid_element":return`Neveljavna vrednost v ${n.origin}`;default:return"Neveljaven vnos"}}};function vR(){return{localeError:gR()}}const yR=()=>{const e={string:{unit:"tecken",verb:"att ha"},file:{unit:"bytes",verb:"att ha"},array:{unit:"objekt",verb:"att innehålla"},set:{unit:"objekt",verb:"att innehålla"}};function t(n){return e[n]??null}const i={regex:"reguljärt uttryck",email:"e-postadress",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO-datum och tid",date:"ISO-datum",time:"ISO-tid",duration:"ISO-varaktighet",ipv4:"IPv4-intervall",ipv6:"IPv6-intervall",cidrv4:"IPv4-spektrum",cidrv6:"IPv6-spektrum",base64:"base64-kodad sträng",base64url:"base64url-kodad sträng",json_string:"JSON-sträng",e164:"E.164-nummer",jwt:"JWT",template_literal:"mall-literal"},l={nan:"NaN",number:"antal",array:"lista"};return n=>{switch(n.code){case"invalid_type":{const o=l[n.expected]??n.expected,s=Se(n.input),f=l[s]??s;return/^[A-Z]/.test(n.expected)?`Ogiltig inmatning: förväntat instanceof ${n.expected}, fick ${f}`:`Ogiltig inmatning: förväntat ${o}, fick ${f}`}case"invalid_value":return n.values.length===1?`Ogiltig inmatning: förväntat ${xe(n.values[0])}`:`Ogiltigt val: förväntade en av ${ae(n.values,"|")}`;case"too_big":{const o=n.inclusive?"<=":"<",s=t(n.origin);return s?`För stor(t): förväntade ${n.origin??"värdet"} att ha ${o}${n.maximum.toString()} ${s.unit??"element"}`:`För stor(t): förväntat ${n.origin??"värdet"} att ha ${o}${n.maximum.toString()}`}case"too_small":{const o=n.inclusive?">=":">",s=t(n.origin);return s?`För lite(t): förväntade ${n.origin??"värdet"} att ha ${o}${n.minimum.toString()} ${s.unit}`:`För lite(t): förväntade ${n.origin??"värdet"} att ha ${o}${n.minimum.toString()}`}case"invalid_format":{const o=n;return o.format==="starts_with"?`Ogiltig sträng: måste börja med "${o.prefix}"`:o.format==="ends_with"?`Ogiltig sträng: måste sluta med "${o.suffix}"`:o.format==="includes"?`Ogiltig sträng: måste innehålla "${o.includes}"`:o.format==="regex"?`Ogiltig sträng: måste matcha mönstret "${o.pattern}"`:`Ogiltig(t) ${i[o.format]??n.format}`}case"not_multiple_of":return`Ogiltigt tal: måste vara en multipel av ${n.divisor}`;case"unrecognized_keys":return`${n.keys.length>1?"Okända nycklar":"Okänd nyckel"}: ${ae(n.keys,", ")}`;case"invalid_key":return`Ogiltig nyckel i ${n.origin??"värdet"}`;case"invalid_union":return"Ogiltig input";case"invalid_element":return`Ogiltigt värde i ${n.origin??"värdet"}`;default:return"Ogiltig input"}}};function bR(){return{localeError:yR()}}const xR=()=>{const e={string:{unit:"எழுத்துக்கள்",verb:"கொண்டிருக்க வேண்டும்"},file:{unit:"பைட்டுகள்",verb:"கொண்டிருக்க வேண்டும்"},array:{unit:"உறுப்புகள்",verb:"கொண்டிருக்க வேண்டும்"},set:{unit:"உறுப்புகள்",verb:"கொண்டிருக்க வேண்டும்"}};function t(n){return e[n]??null}const i={regex:"உள்ளீடு",email:"மின்னஞ்சல் முகவரி",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO தேதி நேரம்",date:"ISO தேதி",time:"ISO நேரம்",duration:"ISO கால அளவு",ipv4:"IPv4 முகவரி",ipv6:"IPv6 முகவரி",cidrv4:"IPv4 வரம்பு",cidrv6:"IPv6 வரம்பு",base64:"base64-encoded சரம்",base64url:"base64url-encoded சரம்",json_string:"JSON சரம்",e164:"E.164 எண்",jwt:"JWT",template_literal:"input"},l={nan:"NaN",number:"எண்",array:"அணி",null:"வெறுமை"};return n=>{switch(n.code){case"invalid_type":{const o=l[n.expected]??n.expected,s=Se(n.input),f=l[s]??s;return/^[A-Z]/.test(n.expected)?`தவறான உள்ளீடு: எதிர்பார்க்கப்பட்டது instanceof ${n.expected}, பெறப்பட்டது ${f}`:`தவறான உள்ளீடு: எதிர்பார்க்கப்பட்டது ${o}, பெறப்பட்டது ${f}`}case"invalid_value":return n.values.length===1?`தவறான உள்ளீடு: எதிர்பார்க்கப்பட்டது ${xe(n.values[0])}`:`தவறான விருப்பம்: எதிர்பார்க்கப்பட்டது ${ae(n.values,"|")} இல் ஒன்று`;case"too_big":{const o=n.inclusive?"<=":"<",s=t(n.origin);return s?`மிக பெரியது: எதிர்பார்க்கப்பட்டது ${n.origin??"மதிப்பு"} ${o}${n.maximum.toString()} ${s.unit??"உறுப்புகள்"} ஆக இருக்க வேண்டும்`:`மிக பெரியது: எதிர்பார்க்கப்பட்டது ${n.origin??"மதிப்பு"} ${o}${n.maximum.toString()} ஆக இருக்க வேண்டும்`}case"too_small":{const o=n.inclusive?">=":">",s=t(n.origin);return s?`மிகச் சிறியது: எதிர்பார்க்கப்பட்டது ${n.origin} ${o}${n.minimum.toString()} ${s.unit} ஆக இருக்க வேண்டும்`:`மிகச் சிறியது: எதிர்பார்க்கப்பட்டது ${n.origin} ${o}${n.minimum.toString()} ஆக இருக்க வேண்டும்`}case"invalid_format":{const o=n;return o.format==="starts_with"?`தவறான சரம்: "${o.prefix}" இல் தொடங்க வேண்டும்`:o.format==="ends_with"?`தவறான சரம்: "${o.suffix}" இல் முடிவடைய வேண்டும்`:o.format==="includes"?`தவறான சரம்: "${o.includes}" ஐ உள்ளடக்க வேண்டும்`:o.format==="regex"?`தவறான சரம்: ${o.pattern} முறைபாட்டுடன் பொருந்த வேண்டும்`:`தவறான ${i[o.format]??n.format}`}case"not_multiple_of":return`தவறான எண்: ${n.divisor} இன் பலமாக இருக்க வேண்டும்`;case"unrecognized_keys":return`அடையாளம் தெரியாத விசை${n.keys.length>1?"கள்":""}: ${ae(n.keys,", ")}`;case"invalid_key":return`${n.origin} இல் தவறான விசை`;case"invalid_union":return"தவறான உள்ளீடு";case"invalid_element":return`${n.origin} இல் தவறான மதிப்பு`;default:return"தவறான உள்ளீடு"}}};function _R(){return{localeError:xR()}}const SR=()=>{const e={string:{unit:"ตัวอักษร",verb:"ควรมี"},file:{unit:"ไบต์",verb:"ควรมี"},array:{unit:"รายการ",verb:"ควรมี"},set:{unit:"รายการ",verb:"ควรมี"}};function t(n){return e[n]??null}const i={regex:"ข้อมูลที่ป้อน",email:"ที่อยู่อีเมล",url:"URL",emoji:"อิโมจิ",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"วันที่เวลาแบบ ISO",date:"วันที่แบบ ISO",time:"เวลาแบบ ISO",duration:"ช่วงเวลาแบบ ISO",ipv4:"ที่อยู่ IPv4",ipv6:"ที่อยู่ IPv6",cidrv4:"ช่วง IP แบบ IPv4",cidrv6:"ช่วง IP แบบ IPv6",base64:"ข้อความแบบ Base64",base64url:"ข้อความแบบ Base64 สำหรับ URL",json_string:"ข้อความแบบ JSON",e164:"เบอร์โทรศัพท์ระหว่างประเทศ (E.164)",jwt:"โทเคน JWT",template_literal:"ข้อมูลที่ป้อน"},l={nan:"NaN",number:"ตัวเลข",array:"อาร์เรย์ (Array)",null:"ไม่มีค่า (null)"};return n=>{switch(n.code){case"invalid_type":{const o=l[n.expected]??n.expected,s=Se(n.input),f=l[s]??s;return/^[A-Z]/.test(n.expected)?`ประเภทข้อมูลไม่ถูกต้อง: ควรเป็น instanceof ${n.expected} แต่ได้รับ ${f}`:`ประเภทข้อมูลไม่ถูกต้อง: ควรเป็น ${o} แต่ได้รับ ${f}`}case"invalid_value":return n.values.length===1?`ค่าไม่ถูกต้อง: ควรเป็น ${xe(n.values[0])}`:`ตัวเลือกไม่ถูกต้อง: ควรเป็นหนึ่งใน ${ae(n.values,"|")}`;case"too_big":{const o=n.inclusive?"ไม่เกิน":"น้อยกว่า",s=t(n.origin);return s?`เกินกำหนด: ${n.origin??"ค่า"} ควรมี${o} ${n.maximum.toString()} ${s.unit??"รายการ"}`:`เกินกำหนด: ${n.origin??"ค่า"} ควรมี${o} ${n.maximum.toString()}`}case"too_small":{const o=n.inclusive?"อย่างน้อย":"มากกว่า",s=t(n.origin);return s?`น้อยกว่ากำหนด: ${n.origin} ควรมี${o} ${n.minimum.toString()} ${s.unit}`:`น้อยกว่ากำหนด: ${n.origin} ควรมี${o} ${n.minimum.toString()}`}case"invalid_format":{const o=n;return o.format==="starts_with"?`รูปแบบไม่ถูกต้อง: ข้อความต้องขึ้นต้นด้วย "${o.prefix}"`:o.format==="ends_with"?`รูปแบบไม่ถูกต้อง: ข้อความต้องลงท้ายด้วย "${o.suffix}"`:o.format==="includes"?`รูปแบบไม่ถูกต้อง: ข้อความต้องมี "${o.includes}" อยู่ในข้อความ`:o.format==="regex"?`รูปแบบไม่ถูกต้อง: ต้องตรงกับรูปแบบที่กำหนด ${o.pattern}`:`รูปแบบไม่ถูกต้อง: ${i[o.format]??n.format}`}case"not_multiple_of":return`ตัวเลขไม่ถูกต้อง: ต้องเป็นจำนวนที่หารด้วย ${n.divisor} ได้ลงตัว`;case"unrecognized_keys":return`พบคีย์ที่ไม่รู้จัก: ${ae(n.keys,", ")}`;case"invalid_key":return`คีย์ไม่ถูกต้องใน ${n.origin}`;case"invalid_union":return"ข้อมูลไม่ถูกต้อง: ไม่ตรงกับรูปแบบยูเนียนที่กำหนดไว้";case"invalid_element":return`ข้อมูลไม่ถูกต้องใน ${n.origin}`;default:return"ข้อมูลไม่ถูกต้อง"}}};function kR(){return{localeError:SR()}}const wR=()=>{const e={string:{unit:"karakter",verb:"olmalı"},file:{unit:"bayt",verb:"olmalı"},array:{unit:"öğe",verb:"olmalı"},set:{unit:"öğe",verb:"olmalı"}};function t(n){return e[n]??null}const i={regex:"girdi",email:"e-posta adresi",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO tarih ve saat",date:"ISO tarih",time:"ISO saat",duration:"ISO süre",ipv4:"IPv4 adresi",ipv6:"IPv6 adresi",cidrv4:"IPv4 aralığı",cidrv6:"IPv6 aralığı",base64:"base64 ile şifrelenmiş metin",base64url:"base64url ile şifrelenmiş metin",json_string:"JSON dizesi",e164:"E.164 sayısı",jwt:"JWT",template_literal:"Şablon dizesi"},l={nan:"NaN"};return n=>{switch(n.code){case"invalid_type":{const o=l[n.expected]??n.expected,s=Se(n.input),f=l[s]??s;return/^[A-Z]/.test(n.expected)?`Geçersiz değer: beklenen instanceof ${n.expected}, alınan ${f}`:`Geçersiz değer: beklenen ${o}, alınan ${f}`}case"invalid_value":return n.values.length===1?`Geçersiz değer: beklenen ${xe(n.values[0])}`:`Geçersiz seçenek: aşağıdakilerden biri olmalı: ${ae(n.values,"|")}`;case"too_big":{const o=n.inclusive?"<=":"<",s=t(n.origin);return s?`Çok büyük: beklenen ${n.origin??"değer"} ${o}${n.maximum.toString()} ${s.unit??"öğe"}`:`Çok büyük: beklenen ${n.origin??"değer"} ${o}${n.maximum.toString()}`}case"too_small":{const o=n.inclusive?">=":">",s=t(n.origin);return s?`Çok küçük: beklenen ${n.origin} ${o}${n.minimum.toString()} ${s.unit}`:`Çok küçük: beklenen ${n.origin} ${o}${n.minimum.toString()}`}case"invalid_format":{const o=n;return o.format==="starts_with"?`Geçersiz metin: "${o.prefix}" ile başlamalı`:o.format==="ends_with"?`Geçersiz metin: "${o.suffix}" ile bitmeli`:o.format==="includes"?`Geçersiz metin: "${o.includes}" içermeli`:o.format==="regex"?`Geçersiz metin: ${o.pattern} desenine uymalı`:`Geçersiz ${i[o.format]??n.format}`}case"not_multiple_of":return`Geçersiz sayı: ${n.divisor} ile tam bölünebilmeli`;case"unrecognized_keys":return`Tanınmayan anahtar${n.keys.length>1?"lar":""}: ${ae(n.keys,", ")}`;case"invalid_key":return`${n.origin} içinde geçersiz anahtar`;case"invalid_union":return"Geçersiz değer";case"invalid_element":return`${n.origin} içinde geçersiz değer`;default:return"Geçersiz değer"}}};function $R(){return{localeError:wR()}}const ER=()=>{const e={string:{unit:"символів",verb:"матиме"},file:{unit:"байтів",verb:"матиме"},array:{unit:"елементів",verb:"матиме"},set:{unit:"елементів",verb:"матиме"}};function t(n){return e[n]??null}const i={regex:"вхідні дані",email:"адреса електронної пошти",url:"URL",emoji:"емодзі",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"дата та час ISO",date:"дата ISO",time:"час ISO",duration:"тривалість ISO",ipv4:"адреса IPv4",ipv6:"адреса IPv6",cidrv4:"діапазон IPv4",cidrv6:"діапазон IPv6",base64:"рядок у кодуванні base64",base64url:"рядок у кодуванні base64url",json_string:"рядок JSON",e164:"номер E.164",jwt:"JWT",template_literal:"вхідні дані"},l={nan:"NaN",number:"число",array:"масив"};return n=>{switch(n.code){case"invalid_type":{const o=l[n.expected]??n.expected,s=Se(n.input),f=l[s]??s;return/^[A-Z]/.test(n.expected)?`Неправильні вхідні дані: очікується instanceof ${n.expected}, отримано ${f}`:`Неправильні вхідні дані: очікується ${o}, отримано ${f}`}case"invalid_value":return n.values.length===1?`Неправильні вхідні дані: очікується ${xe(n.values[0])}`:`Неправильна опція: очікується одне з ${ae(n.values,"|")}`;case"too_big":{const o=n.inclusive?"<=":"<",s=t(n.origin);return s?`Занадто велике: очікується, що ${n.origin??"значення"} ${s.verb} ${o}${n.maximum.toString()} ${s.unit??"елементів"}`:`Занадто велике: очікується, що ${n.origin??"значення"} буде ${o}${n.maximum.toString()}`}case"too_small":{const o=n.inclusive?">=":">",s=t(n.origin);return s?`Занадто мале: очікується, що ${n.origin} ${s.verb} ${o}${n.minimum.toString()} ${s.unit}`:`Занадто мале: очікується, що ${n.origin} буде ${o}${n.minimum.toString()}`}case"invalid_format":{const o=n;return o.format==="starts_with"?`Неправильний рядок: повинен починатися з "${o.prefix}"`:o.format==="ends_with"?`Неправильний рядок: повинен закінчуватися на "${o.suffix}"`:o.format==="includes"?`Неправильний рядок: повинен містити "${o.includes}"`:o.format==="regex"?`Неправильний рядок: повинен відповідати шаблону ${o.pattern}`:`Неправильний ${i[o.format]??n.format}`}case"not_multiple_of":return`Неправильне число: повинно бути кратним ${n.divisor}`;case"unrecognized_keys":return`Нерозпізнаний ключ${n.keys.length>1?"і":""}: ${ae(n.keys,", ")}`;case"invalid_key":return`Неправильний ключ у ${n.origin}`;case"invalid_union":return"Неправильні вхідні дані";case"invalid_element":return`Неправильне значення у ${n.origin}`;default:return"Неправильні вхідні дані"}}};function R$(){return{localeError:ER()}}function jR(){return R$()}const zR=()=>{const e={string:{unit:"حروف",verb:"ہونا"},file:{unit:"بائٹس",verb:"ہونا"},array:{unit:"آئٹمز",verb:"ہونا"},set:{unit:"آئٹمز",verb:"ہونا"}};function t(n){return e[n]??null}const i={regex:"ان پٹ",email:"ای میل ایڈریس",url:"یو آر ایل",emoji:"ایموجی",uuid:"یو یو آئی ڈی",uuidv4:"یو یو آئی ڈی وی 4",uuidv6:"یو یو آئی ڈی وی 6",nanoid:"نینو آئی ڈی",guid:"جی یو آئی ڈی",cuid:"سی یو آئی ڈی",cuid2:"سی یو آئی ڈی 2",ulid:"یو ایل آئی ڈی",xid:"ایکس آئی ڈی",ksuid:"کے ایس یو آئی ڈی",datetime:"آئی ایس او ڈیٹ ٹائم",date:"آئی ایس او تاریخ",time:"آئی ایس او وقت",duration:"آئی ایس او مدت",ipv4:"آئی پی وی 4 ایڈریس",ipv6:"آئی پی وی 6 ایڈریس",cidrv4:"آئی پی وی 4 رینج",cidrv6:"آئی پی وی 6 رینج",base64:"بیس 64 ان کوڈڈ سٹرنگ",base64url:"بیس 64 یو آر ایل ان کوڈڈ سٹرنگ",json_string:"جے ایس او این سٹرنگ",e164:"ای 164 نمبر",jwt:"جے ڈبلیو ٹی",template_literal:"ان پٹ"},l={nan:"NaN",number:"نمبر",array:"آرے",null:"نل"};return n=>{switch(n.code){case"invalid_type":{const o=l[n.expected]??n.expected,s=Se(n.input),f=l[s]??s;return/^[A-Z]/.test(n.expected)?`غلط ان پٹ: instanceof ${n.expected} متوقع تھا، ${f} موصول ہوا`:`غلط ان پٹ: ${o} متوقع تھا، ${f} موصول ہوا`}case"invalid_value":return n.values.length===1?`غلط ان پٹ: ${xe(n.values[0])} متوقع تھا`:`غلط آپشن: ${ae(n.values,"|")} میں سے ایک متوقع تھا`;case"too_big":{const o=n.inclusive?"<=":"<",s=t(n.origin);return s?`بہت بڑا: ${n.origin??"ویلیو"} کے ${o}${n.maximum.toString()} ${s.unit??"عناصر"} ہونے متوقع تھے`:`بہت بڑا: ${n.origin??"ویلیو"} کا ${o}${n.maximum.toString()} ہونا متوقع تھا`}case"too_small":{const o=n.inclusive?">=":">",s=t(n.origin);return s?`بہت چھوٹا: ${n.origin} کے ${o}${n.minimum.toString()} ${s.unit} ہونے متوقع تھے`:`بہت چھوٹا: ${n.origin} کا ${o}${n.minimum.toString()} ہونا متوقع تھا`}case"invalid_format":{const o=n;return o.format==="starts_with"?`غلط سٹرنگ: "${o.prefix}" سے شروع ہونا چاہیے`:o.format==="ends_with"?`غلط سٹرنگ: "${o.suffix}" پر ختم ہونا چاہیے`:o.format==="includes"?`غلط سٹرنگ: "${o.includes}" شامل ہونا چاہیے`:o.format==="regex"?`غلط سٹرنگ: پیٹرن ${o.pattern} سے میچ ہونا چاہیے`:`غلط ${i[o.format]??n.format}`}case"not_multiple_of":return`غلط نمبر: ${n.divisor} کا مضاعف ہونا چاہیے`;case"unrecognized_keys":return`غیر تسلیم شدہ کی${n.keys.length>1?"ز":""}: ${ae(n.keys,"، ")}`;case"invalid_key":return`${n.origin} میں غلط کی`;case"invalid_union":return"غلط ان پٹ";case"invalid_element":return`${n.origin} میں غلط ویلیو`;default:return"غلط ان پٹ"}}};function NR(){return{localeError:zR()}}const OR=()=>{const e={string:{unit:"belgi",verb:"bo‘lishi kerak"},file:{unit:"bayt",verb:"bo‘lishi kerak"},array:{unit:"element",verb:"bo‘lishi kerak"},set:{unit:"element",verb:"bo‘lishi kerak"}};function t(n){return e[n]??null}const i={regex:"kirish",email:"elektron pochta manzili",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO sana va vaqti",date:"ISO sana",time:"ISO vaqt",duration:"ISO davomiylik",ipv4:"IPv4 manzil",ipv6:"IPv6 manzil",mac:"MAC manzil",cidrv4:"IPv4 diapazon",cidrv6:"IPv6 diapazon",base64:"base64 kodlangan satr",base64url:"base64url kodlangan satr",json_string:"JSON satr",e164:"E.164 raqam",jwt:"JWT",template_literal:"kirish"},l={nan:"NaN",number:"raqam",array:"massiv"};return n=>{switch(n.code){case"invalid_type":{const o=l[n.expected]??n.expected,s=Se(n.input),f=l[s]??s;return/^[A-Z]/.test(n.expected)?`Noto‘g‘ri kirish: kutilgan instanceof ${n.expected}, qabul qilingan ${f}`:`Noto‘g‘ri kirish: kutilgan ${o}, qabul qilingan ${f}`}case"invalid_value":return n.values.length===1?`Noto‘g‘ri kirish: kutilgan ${xe(n.values[0])}`:`Noto‘g‘ri variant: quyidagilardan biri kutilgan ${ae(n.values,"|")}`;case"too_big":{const o=n.inclusive?"<=":"<",s=t(n.origin);return s?`Juda katta: kutilgan ${n.origin??"qiymat"} ${o}${n.maximum.toString()} ${s.unit} ${s.verb}`:`Juda katta: kutilgan ${n.origin??"qiymat"} ${o}${n.maximum.toString()}`}case"too_small":{const o=n.inclusive?">=":">",s=t(n.origin);return s?`Juda kichik: kutilgan ${n.origin} ${o}${n.minimum.toString()} ${s.unit} ${s.verb}`:`Juda kichik: kutilgan ${n.origin} ${o}${n.minimum.toString()}`}case"invalid_format":{const o=n;return o.format==="starts_with"?`Noto‘g‘ri satr: "${o.prefix}" bilan boshlanishi kerak`:o.format==="ends_with"?`Noto‘g‘ri satr: "${o.suffix}" bilan tugashi kerak`:o.format==="includes"?`Noto‘g‘ri satr: "${o.includes}" ni o‘z ichiga olishi kerak`:o.format==="regex"?`Noto‘g‘ri satr: ${o.pattern} shabloniga mos kelishi kerak`:`Noto‘g‘ri ${i[o.format]??n.format}`}case"not_multiple_of":return`Noto‘g‘ri raqam: ${n.divisor} ning karralisi bo‘lishi kerak`;case"unrecognized_keys":return`Noma’lum kalit${n.keys.length>1?"lar":""}: ${ae(n.keys,", ")}`;case"invalid_key":return`${n.origin} dagi kalit noto‘g‘ri`;case"invalid_union":return"Noto‘g‘ri kirish";case"invalid_element":return`${n.origin} da noto‘g‘ri qiymat`;default:return"Noto‘g‘ri kirish"}}};function TR(){return{localeError:OR()}}const CR=()=>{const e={string:{unit:"ký tự",verb:"có"},file:{unit:"byte",verb:"có"},array:{unit:"phần tử",verb:"có"},set:{unit:"phần tử",verb:"có"}};function t(n){return e[n]??null}const i={regex:"đầu vào",email:"địa chỉ email",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ngày giờ ISO",date:"ngày ISO",time:"giờ ISO",duration:"khoảng thời gian ISO",ipv4:"địa chỉ IPv4",ipv6:"địa chỉ IPv6",cidrv4:"dải IPv4",cidrv6:"dải IPv6",base64:"chuỗi mã hóa base64",base64url:"chuỗi mã hóa base64url",json_string:"chuỗi JSON",e164:"số E.164",jwt:"JWT",template_literal:"đầu vào"},l={nan:"NaN",number:"số",array:"mảng"};return n=>{switch(n.code){case"invalid_type":{const o=l[n.expected]??n.expected,s=Se(n.input),f=l[s]??s;return/^[A-Z]/.test(n.expected)?`Đầu vào không hợp lệ: mong đợi instanceof ${n.expected}, nhận được ${f}`:`Đầu vào không hợp lệ: mong đợi ${o}, nhận được ${f}`}case"invalid_value":return n.values.length===1?`Đầu vào không hợp lệ: mong đợi ${xe(n.values[0])}`:`Tùy chọn không hợp lệ: mong đợi một trong các giá trị ${ae(n.values,"|")}`;case"too_big":{const o=n.inclusive?"<=":"<",s=t(n.origin);return s?`Quá lớn: mong đợi ${n.origin??"giá trị"} ${s.verb} ${o}${n.maximum.toString()} ${s.unit??"phần tử"}`:`Quá lớn: mong đợi ${n.origin??"giá trị"} ${o}${n.maximum.toString()}`}case"too_small":{const o=n.inclusive?">=":">",s=t(n.origin);return s?`Quá nhỏ: mong đợi ${n.origin} ${s.verb} ${o}${n.minimum.toString()} ${s.unit}`:`Quá nhỏ: mong đợi ${n.origin} ${o}${n.minimum.toString()}`}case"invalid_format":{const o=n;return o.format==="starts_with"?`Chuỗi không hợp lệ: phải bắt đầu bằng "${o.prefix}"`:o.format==="ends_with"?`Chuỗi không hợp lệ: phải kết thúc bằng "${o.suffix}"`:o.format==="includes"?`Chuỗi không hợp lệ: phải bao gồm "${o.includes}"`:o.format==="regex"?`Chuỗi không hợp lệ: phải khớp với mẫu ${o.pattern}`:`${i[o.format]??n.format} không hợp lệ`}case"not_multiple_of":return`Số không hợp lệ: phải là bội số của ${n.divisor}`;case"unrecognized_keys":return`Khóa không được nhận dạng: ${ae(n.keys,", ")}`;case"invalid_key":return`Khóa không hợp lệ trong ${n.origin}`;case"invalid_union":return"Đầu vào không hợp lệ";case"invalid_element":return`Giá trị không hợp lệ trong ${n.origin}`;default:return"Đầu vào không hợp lệ"}}};function DR(){return{localeError:CR()}}const AR=()=>{const e={string:{unit:"字符",verb:"包含"},file:{unit:"字节",verb:"包含"},array:{unit:"项",verb:"包含"},set:{unit:"项",verb:"包含"}};function t(n){return e[n]??null}const i={regex:"输入",email:"电子邮件",url:"URL",emoji:"表情符号",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO日期时间",date:"ISO日期",time:"ISO时间",duration:"ISO时长",ipv4:"IPv4地址",ipv6:"IPv6地址",cidrv4:"IPv4网段",cidrv6:"IPv6网段",base64:"base64编码字符串",base64url:"base64url编码字符串",json_string:"JSON字符串",e164:"E.164号码",jwt:"JWT",template_literal:"输入"},l={nan:"NaN",number:"数字",array:"数组",null:"空值(null)"};return n=>{switch(n.code){case"invalid_type":{const o=l[n.expected]??n.expected,s=Se(n.input),f=l[s]??s;return/^[A-Z]/.test(n.expected)?`无效输入:期望 instanceof ${n.expected},实际接收 ${f}`:`无效输入:期望 ${o},实际接收 ${f}`}case"invalid_value":return n.values.length===1?`无效输入:期望 ${xe(n.values[0])}`:`无效选项:期望以下之一 ${ae(n.values,"|")}`;case"too_big":{const o=n.inclusive?"<=":"<",s=t(n.origin);return s?`数值过大:期望 ${n.origin??"值"} ${o}${n.maximum.toString()} ${s.unit??"个元素"}`:`数值过大:期望 ${n.origin??"值"} ${o}${n.maximum.toString()}`}case"too_small":{const o=n.inclusive?">=":">",s=t(n.origin);return s?`数值过小:期望 ${n.origin} ${o}${n.minimum.toString()} ${s.unit}`:`数值过小:期望 ${n.origin} ${o}${n.minimum.toString()}`}case"invalid_format":{const o=n;return o.format==="starts_with"?`无效字符串:必须以 "${o.prefix}" 开头`:o.format==="ends_with"?`无效字符串:必须以 "${o.suffix}" 结尾`:o.format==="includes"?`无效字符串:必须包含 "${o.includes}"`:o.format==="regex"?`无效字符串:必须满足正则表达式 ${o.pattern}`:`无效${i[o.format]??n.format}`}case"not_multiple_of":return`无效数字:必须是 ${n.divisor} 的倍数`;case"unrecognized_keys":return`出现未知的键(key): ${ae(n.keys,", ")}`;case"invalid_key":return`${n.origin} 中的键(key)无效`;case"invalid_union":return"无效输入";case"invalid_element":return`${n.origin} 中包含无效值(value)`;default:return"无效输入"}}};function RR(){return{localeError:AR()}}const IR=()=>{const e={string:{unit:"字元",verb:"擁有"},file:{unit:"位元組",verb:"擁有"},array:{unit:"項目",verb:"擁有"},set:{unit:"項目",verb:"擁有"}};function t(n){return e[n]??null}const i={regex:"輸入",email:"郵件地址",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO 日期時間",date:"ISO 日期",time:"ISO 時間",duration:"ISO 期間",ipv4:"IPv4 位址",ipv6:"IPv6 位址",cidrv4:"IPv4 範圍",cidrv6:"IPv6 範圍",base64:"base64 編碼字串",base64url:"base64url 編碼字串",json_string:"JSON 字串",e164:"E.164 數值",jwt:"JWT",template_literal:"輸入"},l={nan:"NaN"};return n=>{switch(n.code){case"invalid_type":{const o=l[n.expected]??n.expected,s=Se(n.input),f=l[s]??s;return/^[A-Z]/.test(n.expected)?`無效的輸入值:預期為 instanceof ${n.expected},但收到 ${f}`:`無效的輸入值:預期為 ${o},但收到 ${f}`}case"invalid_value":return n.values.length===1?`無效的輸入值:預期為 ${xe(n.values[0])}`:`無效的選項:預期為以下其中之一 ${ae(n.values,"|")}`;case"too_big":{const o=n.inclusive?"<=":"<",s=t(n.origin);return s?`數值過大:預期 ${n.origin??"值"} 應為 ${o}${n.maximum.toString()} ${s.unit??"個元素"}`:`數值過大:預期 ${n.origin??"值"} 應為 ${o}${n.maximum.toString()}`}case"too_small":{const o=n.inclusive?">=":">",s=t(n.origin);return s?`數值過小:預期 ${n.origin} 應為 ${o}${n.minimum.toString()} ${s.unit}`:`數值過小:預期 ${n.origin} 應為 ${o}${n.minimum.toString()}`}case"invalid_format":{const o=n;return o.format==="starts_with"?`無效的字串:必須以 "${o.prefix}" 開頭`:o.format==="ends_with"?`無效的字串:必須以 "${o.suffix}" 結尾`:o.format==="includes"?`無效的字串:必須包含 "${o.includes}"`:o.format==="regex"?`無效的字串:必須符合格式 ${o.pattern}`:`無效的 ${i[o.format]??n.format}`}case"not_multiple_of":return`無效的數字:必須為 ${n.divisor} 的倍數`;case"unrecognized_keys":return`無法識別的鍵值${n.keys.length>1?"們":""}:${ae(n.keys,"、")}`;case"invalid_key":return`${n.origin} 中有無效的鍵值`;case"invalid_union":return"無效的輸入值";case"invalid_element":return`${n.origin} 中有無效的值`;default:return"無效的輸入值"}}};function UR(){return{localeError:IR()}}const LR=()=>{const e={string:{unit:"àmi",verb:"ní"},file:{unit:"bytes",verb:"ní"},array:{unit:"nkan",verb:"ní"},set:{unit:"nkan",verb:"ní"}};function t(n){return e[n]??null}const i={regex:"ẹ̀rọ ìbáwọlé",email:"àdírẹ́sì ìmẹ́lì",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"àkókò ISO",date:"ọjọ́ ISO",time:"àkókò ISO",duration:"àkókò tó pé ISO",ipv4:"àdírẹ́sì IPv4",ipv6:"àdírẹ́sì IPv6",cidrv4:"àgbègbè IPv4",cidrv6:"àgbègbè IPv6",base64:"ọ̀rọ̀ tí a kọ́ ní base64",base64url:"ọ̀rọ̀ base64url",json_string:"ọ̀rọ̀ JSON",e164:"nọ́mbà E.164",jwt:"JWT",template_literal:"ẹ̀rọ ìbáwọlé"},l={nan:"NaN",number:"nọ́mbà",array:"akopọ"};return n=>{switch(n.code){case"invalid_type":{const o=l[n.expected]??n.expected,s=Se(n.input),f=l[s]??s;return/^[A-Z]/.test(n.expected)?`Ìbáwọlé aṣìṣe: a ní láti fi instanceof ${n.expected}, àmọ̀ a rí ${f}`:`Ìbáwọlé aṣìṣe: a ní láti fi ${o}, àmọ̀ a rí ${f}`}case"invalid_value":return n.values.length===1?`Ìbáwọlé aṣìṣe: a ní láti fi ${xe(n.values[0])}`:`Àṣàyàn aṣìṣe: yan ọ̀kan lára ${ae(n.values,"|")}`;case"too_big":{const o=n.inclusive?"<=":"<",s=t(n.origin);return s?`Tó pọ̀ jù: a ní láti jẹ́ pé ${n.origin??"iye"} ${s.verb} ${o}${n.maximum} ${s.unit}`:`Tó pọ̀ jù: a ní láti jẹ́ ${o}${n.maximum}`}case"too_small":{const o=n.inclusive?">=":">",s=t(n.origin);return s?`Kéré ju: a ní láti jẹ́ pé ${n.origin} ${s.verb} ${o}${n.minimum} ${s.unit}`:`Kéré ju: a ní láti jẹ́ ${o}${n.minimum}`}case"invalid_format":{const o=n;return o.format==="starts_with"?`Ọ̀rọ̀ aṣìṣe: gbọ́dọ̀ bẹ̀rẹ̀ pẹ̀lú "${o.prefix}"`:o.format==="ends_with"?`Ọ̀rọ̀ aṣìṣe: gbọ́dọ̀ parí pẹ̀lú "${o.suffix}"`:o.format==="includes"?`Ọ̀rọ̀ aṣìṣe: gbọ́dọ̀ ní "${o.includes}"`:o.format==="regex"?`Ọ̀rọ̀ aṣìṣe: gbọ́dọ̀ bá àpẹẹrẹ mu ${o.pattern}`:`Aṣìṣe: ${i[o.format]??n.format}`}case"not_multiple_of":return`Nọ́mbà aṣìṣe: gbọ́dọ̀ jẹ́ èyà pípín ti ${n.divisor}`;case"unrecognized_keys":return`Bọtìnì àìmọ̀: ${ae(n.keys,", ")}`;case"invalid_key":return`Bọtìnì aṣìṣe nínú ${n.origin}`;case"invalid_union":return"Ìbáwọlé aṣìṣe";case"invalid_element":return`Iye aṣìṣe nínú ${n.origin}`;default:return"Ìbáwọlé aṣìṣe"}}};function MR(){return{localeError:LR()}}const I$=Object.freeze(Object.defineProperty({__proto__:null,ar:nA,az:iA,be:lA,bg:uA,ca:cA,cs:dA,da:hA,de:gA,en:D$,eo:bA,es:_A,fa:kA,fi:$A,fr:jA,frCA:NA,he:TA,hu:DA,hy:RA,id:UA,is:MA,it:ZA,ja:FA,ka:HA,kh:VA,km:A$,ko:JA,lt:QA,mk:WA,ms:tR,nl:rR,no:aR,ota:oR,pl:fR,ps:sR,pt:mR,ru:pR,sl:vR,sv:bR,ta:_R,th:kR,tr:$R,ua:jR,uk:R$,ur:NR,uz:TR,vi:DR,yo:MR,zhCN:RR,zhTW:UR},Symbol.toStringTag,{value:"Module"}));var N_;const U$=Symbol("ZodOutput"),L$=Symbol("ZodInput");class M${constructor(){this._map=new WeakMap,this._idmap=new Map}add(t,...i){const l=i[0];return this._map.set(t,l),l&&typeof l=="object"&&"id"in l&&this._idmap.set(l.id,t),this}clear(){return this._map=new WeakMap,this._idmap=new Map,this}remove(t){const i=this._map.get(t);return i&&typeof i=="object"&&"id"in i&&this._idmap.delete(i.id),this._map.delete(t),this}get(t){const i=t._zod.parent;if(i){const l={...this.get(i)??{}};delete l.id;const n={...l,...this._map.get(t)};return Object.keys(n).length?n:void 0}return this._map.get(t)}has(t){return this._map.has(t)}}function Yp(){return new M$}(N_=globalThis).__zod_globalRegistry??(N_.__zod_globalRegistry=Yp());const Nn=globalThis.__zod_globalRegistry;function P$(e,t){return new e({type:"string",...re(t)})}function Z$(e,t){return new e({type:"string",coerce:!0,...re(t)})}function Jp(e,t){return new e({type:"string",format:"email",check:"string_format",abort:!1,...re(t)})}function qs(e,t){return new e({type:"string",format:"guid",check:"string_format",abort:!1,...re(t)})}function Xp(e,t){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,...re(t)})}function Qp(e,t){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v4",...re(t)})}function Kp(e,t){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v6",...re(t)})}function Wp(e,t){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v7",...re(t)})}function lc(e,t){return new e({type:"string",format:"url",check:"string_format",abort:!1,...re(t)})}function eg(e,t){return new e({type:"string",format:"emoji",check:"string_format",abort:!1,...re(t)})}function tg(e,t){return new e({type:"string",format:"nanoid",check:"string_format",abort:!1,...re(t)})}function ng(e,t){return new e({type:"string",format:"cuid",check:"string_format",abort:!1,...re(t)})}function rg(e,t){return new e({type:"string",format:"cuid2",check:"string_format",abort:!1,...re(t)})}function ig(e,t){return new e({type:"string",format:"ulid",check:"string_format",abort:!1,...re(t)})}function ag(e,t){return new e({type:"string",format:"xid",check:"string_format",abort:!1,...re(t)})}function lg(e,t){return new e({type:"string",format:"ksuid",check:"string_format",abort:!1,...re(t)})}function og(e,t){return new e({type:"string",format:"ipv4",check:"string_format",abort:!1,...re(t)})}function ug(e,t){return new e({type:"string",format:"ipv6",check:"string_format",abort:!1,...re(t)})}function q$(e,t){return new e({type:"string",format:"mac",check:"string_format",abort:!1,...re(t)})}function sg(e,t){return new e({type:"string",format:"cidrv4",check:"string_format",abort:!1,...re(t)})}function cg(e,t){return new e({type:"string",format:"cidrv6",check:"string_format",abort:!1,...re(t)})}function fg(e,t){return new e({type:"string",format:"base64",check:"string_format",abort:!1,...re(t)})}function dg(e,t){return new e({type:"string",format:"base64url",check:"string_format",abort:!1,...re(t)})}function mg(e,t){return new e({type:"string",format:"e164",check:"string_format",abort:!1,...re(t)})}function hg(e,t){return new e({type:"string",format:"jwt",check:"string_format",abort:!1,...re(t)})}const F$={Any:null,Minute:-1,Second:0,Millisecond:3,Microsecond:6};function B$(e,t){return new e({type:"string",format:"datetime",check:"string_format",offset:!1,local:!1,precision:null,...re(t)})}function H$(e,t){return new e({type:"string",format:"date",check:"string_format",...re(t)})}function G$(e,t){return new e({type:"string",format:"time",check:"string_format",precision:null,...re(t)})}function V$(e,t){return new e({type:"string",format:"duration",check:"string_format",...re(t)})}function Y$(e,t){return new e({type:"number",checks:[],...re(t)})}function J$(e,t){return new e({type:"number",coerce:!0,checks:[],...re(t)})}function X$(e,t){return new e({type:"number",check:"number_format",abort:!1,format:"safeint",...re(t)})}function Q$(e,t){return new e({type:"number",check:"number_format",abort:!1,format:"float32",...re(t)})}function K$(e,t){return new e({type:"number",check:"number_format",abort:!1,format:"float64",...re(t)})}function W$(e,t){return new e({type:"number",check:"number_format",abort:!1,format:"int32",...re(t)})}function eE(e,t){return new e({type:"number",check:"number_format",abort:!1,format:"uint32",...re(t)})}function tE(e,t){return new e({type:"boolean",...re(t)})}function nE(e,t){return new e({type:"boolean",coerce:!0,...re(t)})}function rE(e,t){return new e({type:"bigint",...re(t)})}function iE(e,t){return new e({type:"bigint",coerce:!0,...re(t)})}function aE(e,t){return new e({type:"bigint",check:"bigint_format",abort:!1,format:"int64",...re(t)})}function lE(e,t){return new e({type:"bigint",check:"bigint_format",abort:!1,format:"uint64",...re(t)})}function oE(e,t){return new e({type:"symbol",...re(t)})}function uE(e,t){return new e({type:"undefined",...re(t)})}function sE(e,t){return new e({type:"null",...re(t)})}function cE(e){return new e({type:"any"})}function fE(e){return new e({type:"unknown"})}function dE(e,t){return new e({type:"never",...re(t)})}function mE(e,t){return new e({type:"void",...re(t)})}function hE(e,t){return new e({type:"date",...re(t)})}function pE(e,t){return new e({type:"date",coerce:!0,...re(t)})}function gE(e,t){return new e({type:"nan",...re(t)})}function oi(e,t){return new Mp({check:"less_than",...re(t),value:e,inclusive:!1})}function On(e,t){return new Mp({check:"less_than",...re(t),value:e,inclusive:!0})}function ui(e,t){return new Pp({check:"greater_than",...re(t),value:e,inclusive:!1})}function en(e,t){return new Pp({check:"greater_than",...re(t),value:e,inclusive:!0})}function pg(e){return ui(0,e)}function gg(e){return oi(0,e)}function vg(e){return On(0,e)}function yg(e){return en(0,e)}function Ha(e,t){return new ew({check:"multiple_of",...re(t),value:e})}function el(e,t){return new rw({check:"max_size",...re(t),maximum:e})}function si(e,t){return new iw({check:"min_size",...re(t),minimum:e})}function Uo(e,t){return new aw({check:"size_equals",...re(t),size:e})}function Lo(e,t){return new lw({check:"max_length",...re(t),maximum:e})}function Mi(e,t){return new ow({check:"min_length",...re(t),minimum:e})}function Mo(e,t){return new uw({check:"length_equals",...re(t),length:e})}function oc(e,t){return new sw({check:"string_format",format:"regex",...re(t),pattern:e})}function uc(e){return new cw({check:"string_format",format:"lowercase",...re(e)})}function sc(e){return new fw({check:"string_format",format:"uppercase",...re(e)})}function cc(e,t){return new dw({check:"string_format",format:"includes",...re(t),includes:e})}function fc(e,t){return new mw({check:"string_format",format:"starts_with",...re(t),prefix:e})}function dc(e,t){return new hw({check:"string_format",format:"ends_with",...re(t),suffix:e})}function bg(e,t,i){return new pw({check:"property",property:e,schema:t,...re(i)})}function mc(e,t){return new gw({check:"mime_type",mime:e,...re(t)})}function Or(e){return new vw({check:"overwrite",tx:e})}function hc(e){return Or(t=>t.normalize(e))}function pc(){return Or(e=>e.trim())}function gc(){return Or(e=>e.toLowerCase())}function vc(){return Or(e=>e.toUpperCase())}function yc(){return Or(e=>QS(e))}function vE(e,t,i){return new e({type:"array",element:t,...re(i)})}function PR(e,t,i){return new e({type:"union",options:t,...re(i)})}function ZR(e,t,i){return new e({type:"union",options:t,inclusive:!1,...re(i)})}function qR(e,t,i,l){return new e({type:"union",options:i,discriminator:t,...re(l)})}function FR(e,t,i){return new e({type:"intersection",left:t,right:i})}function BR(e,t,i,l){const n=i instanceof $e,o=n?l:i,s=n?i:null;return new e({type:"tuple",items:t,rest:s,...re(o)})}function HR(e,t,i,l){return new e({type:"record",keyType:t,valueType:i,...re(l)})}function GR(e,t,i,l){return new e({type:"map",keyType:t,valueType:i,...re(l)})}function VR(e,t,i){return new e({type:"set",valueType:t,...re(i)})}function YR(e,t,i){const l=Array.isArray(t)?Object.fromEntries(t.map(n=>[n,n])):t;return new e({type:"enum",entries:l,...re(i)})}function JR(e,t,i){return new e({type:"enum",entries:t,...re(i)})}function XR(e,t,i){return new e({type:"literal",values:Array.isArray(t)?t:[t],...re(i)})}function yE(e,t){return new e({type:"file",...re(t)})}function QR(e,t){return new e({type:"transform",transform:t})}function KR(e,t){return new e({type:"optional",innerType:t})}function WR(e,t){return new e({type:"nullable",innerType:t})}function eI(e,t,i){return new e({type:"default",innerType:t,get defaultValue(){return typeof i=="function"?i():nc(i)}})}function tI(e,t,i){return new e({type:"nonoptional",innerType:t,...re(i)})}function nI(e,t){return new e({type:"success",innerType:t})}function rI(e,t,i){return new e({type:"catch",innerType:t,catchValue:typeof i=="function"?i:()=>i})}function iI(e,t,i){return new e({type:"pipe",in:t,out:i})}function aI(e,t){return new e({type:"readonly",innerType:t})}function lI(e,t,i){return new e({type:"template_literal",parts:t,...re(i)})}function oI(e,t){return new e({type:"lazy",getter:t})}function uI(e,t){return new e({type:"promise",innerType:t})}function bE(e,t,i){const l=re(i);return l.abort??(l.abort=!0),new e({type:"custom",check:"custom",fn:t,...l})}function xE(e,t,i){return new e({type:"custom",check:"custom",fn:t,...re(i)})}function _E(e){const t=SE(i=>(i.addIssue=l=>{if(typeof l=="string")i.issues.push(Fa(l,i.value,t._zod.def));else{const n=l;n.fatal&&(n.continue=!1),n.code??(n.code="custom"),n.input??(n.input=i.value),n.inst??(n.inst=t),n.continue??(n.continue=!t._zod.def.abort),i.issues.push(Fa(n))}},e(i.value,i)));return t}function SE(e,t){const i=new st({check:"custom",...re(t)});return i._zod.check=e,i}function kE(e){const t=new st({check:"describe"});return t._zod.onattach=[i=>{const l=Nn.get(i)??{};Nn.add(i,{...l,description:e})}],t._zod.check=()=>{},t}function wE(e){const t=new st({check:"meta"});return t._zod.onattach=[i=>{const l=Nn.get(i)??{};Nn.add(i,{...l,...e})}],t._zod.check=()=>{},t}function $E(e,t){const i=re(t);let l=i.truthy??["true","1","yes","on","y","enabled"],n=i.falsy??["false","0","no","off","n","disabled"];i.case!=="sensitive"&&(l=l.map(x=>typeof x=="string"?x.toLowerCase():x),n=n.map(x=>typeof x=="string"?x.toLowerCase():x));const o=new Set(l),s=new Set(n),f=e.Codec??Vp,m=e.Boolean??Fp,d=e.String??Io,p=new d({type:"string",error:i.error}),v=new m({type:"boolean",error:i.error}),b=new f({type:"pipe",in:p,out:v,transform:((x,S)=>{let w=x;return i.case!=="sensitive"&&(w=w.toLowerCase()),o.has(w)?!0:s.has(w)?!1:(S.issues.push({code:"invalid_value",expected:"stringbool",values:[...o,...s],input:S.value,inst:b,continue:!1}),{})}),reverseTransform:((x,S)=>x===!0?l[0]||"true":n[0]||"false"),error:i.error});return b}function Po(e,t,i,l={}){const n=re(l),o={...re(l),check:"string_format",type:"string",format:t,fn:typeof i=="function"?i:f=>i.test(f),...n};return i instanceof RegExp&&(o.pattern=i),new e(o)}function Ga(e){let t=e?.target??"draft-2020-12";return t==="draft-4"&&(t="draft-04"),t==="draft-7"&&(t="draft-07"),{processors:e.processors??{},metadataRegistry:e?.metadata??Nn,target:t,unrepresentable:e?.unrepresentable??"throw",override:e?.override??(()=>{}),io:e?.io??"output",counter:0,seen:new Map,cycles:e?.cycles??"ref",reused:e?.reused??"inline",external:e?.external??void 0}}function et(e,t,i={path:[],schemaPath:[]}){var l;const n=e._zod.def,o=t.seen.get(e);if(o)return o.count++,i.schemaPath.includes(e)&&(o.cycle=i.path),o.schema;const s={schema:{},count:1,cycle:void 0,path:i.path};t.seen.set(e,s);const f=e._zod.toJSONSchema?.();if(f)s.schema=f;else{const p={...i,schemaPath:[...i.schemaPath,e],path:i.path};if(e._zod.processJSONSchema)e._zod.processJSONSchema(t,s.schema,p);else{const b=s.schema,x=t.processors[n.type];if(!x)throw new Error(`[toJSONSchema]: Non-representable type encountered: ${n.type}`);x(e,t,b,p)}const v=e._zod.parent;v&&(s.ref||(s.ref=v),et(v,t,p),t.seen.get(v).isParent=!0)}const m=t.metadataRegistry.get(e);return m&&Object.assign(s.schema,m),t.io==="input"&&Zt(e)&&(delete s.schema.examples,delete s.schema.default),t.io==="input"&&s.schema._prefault&&((l=s.schema).default??(l.default=s.schema._prefault)),delete s.schema._prefault,t.seen.get(e).schema}function Va(e,t){const i=e.seen.get(t);if(!i)throw new Error("Unprocessed schema. This is a bug in Zod.");const l=new Map;for(const s of e.seen.entries()){const f=e.metadataRegistry.get(s[0])?.id;if(f){const m=l.get(f);if(m&&m!==s[0])throw new Error(`Duplicate schema id "${f}" detected during JSON Schema conversion. Two different schemas cannot share the same id when converted together.`);l.set(f,s[0])}}const n=s=>{const f=e.target==="draft-2020-12"?"$defs":"definitions";if(e.external){const v=e.external.registry.get(s[0])?.id,b=e.external.uri??(S=>S);if(v)return{ref:b(v)};const x=s[1].defId??s[1].schema.id??`schema${e.counter++}`;return s[1].defId=x,{defId:x,ref:`${b("__shared")}#/${f}/${x}`}}if(s[1]===i)return{ref:"#"};const d=`#/${f}/`,p=s[1].schema.id??`__schema${e.counter++}`;return{defId:p,ref:d+p}},o=s=>{if(s[1].schema.$ref)return;const f=s[1],{ref:m,defId:d}=n(s);f.def={...f.schema},d&&(f.defId=d);const p=f.schema;for(const v in p)delete p[v];p.$ref=m};if(e.cycles==="throw")for(const s of e.seen.entries()){const f=s[1];if(f.cycle)throw new Error(`Cycle detected: #/${f.cycle?.join("/")}/<root>
|
|
58
|
+
|
|
59
|
+
Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.`)}for(const s of e.seen.entries()){const f=s[1];if(t===s[0]){o(s);continue}if(e.external){const d=e.external.registry.get(s[0])?.id;if(t!==s[0]&&d){o(s);continue}}if(e.metadataRegistry.get(s[0])?.id){o(s);continue}if(f.cycle){o(s);continue}if(f.count>1&&e.reused==="ref"){o(s);continue}}}function Ya(e,t){const i=e.seen.get(t);if(!i)throw new Error("Unprocessed schema. This is a bug in Zod.");const l=s=>{const f=e.seen.get(s);if(f.ref===null)return;const m=f.def??f.schema,d={...m},p=f.ref;if(f.ref=null,p){l(p);const b=e.seen.get(p),x=b.schema;if(x.$ref&&(e.target==="draft-07"||e.target==="draft-04"||e.target==="openapi-3.0")?(m.allOf=m.allOf??[],m.allOf.push(x)):Object.assign(m,x),Object.assign(m,d),s._zod.parent===p)for(const w in m)w==="$ref"||w==="allOf"||w in d||delete m[w];if(x.$ref)for(const w in m)w==="$ref"||w==="allOf"||w in b.def&&JSON.stringify(m[w])===JSON.stringify(b.def[w])&&delete m[w]}const v=s._zod.parent;if(v&&v!==p){l(v);const b=e.seen.get(v);if(b?.schema.$ref&&(m.$ref=b.schema.$ref,b.def))for(const x in m)x==="$ref"||x==="allOf"||x in b.def&&JSON.stringify(m[x])===JSON.stringify(b.def[x])&&delete m[x]}e.override({zodSchema:s,jsonSchema:m,path:f.path??[]})};for(const s of[...e.seen.entries()].reverse())l(s[0]);const n={};if(e.target==="draft-2020-12"?n.$schema="https://json-schema.org/draft/2020-12/schema":e.target==="draft-07"?n.$schema="http://json-schema.org/draft-07/schema#":e.target==="draft-04"?n.$schema="http://json-schema.org/draft-04/schema#":e.target,e.external?.uri){const s=e.external.registry.get(t)?.id;if(!s)throw new Error("Schema is missing an `id` property");n.$id=e.external.uri(s)}Object.assign(n,i.def??i.schema);const o=e.external?.defs??{};for(const s of e.seen.entries()){const f=s[1];f.def&&f.defId&&(o[f.defId]=f.def)}e.external||Object.keys(o).length>0&&(e.target==="draft-2020-12"?n.$defs=o:n.definitions=o);try{const s=JSON.parse(JSON.stringify(n));return Object.defineProperty(s,"~standard",{value:{...t["~standard"],jsonSchema:{input:ho(t,"input",e.processors),output:ho(t,"output",e.processors)}},enumerable:!1,writable:!1}),s}catch{throw new Error("Error converting schema to JSON.")}}function Zt(e,t){const i=t??{seen:new Set};if(i.seen.has(e))return!1;i.seen.add(e);const l=e._zod.def;if(l.type==="transform")return!0;if(l.type==="array")return Zt(l.element,i);if(l.type==="set")return Zt(l.valueType,i);if(l.type==="lazy")return Zt(l.getter(),i);if(l.type==="promise"||l.type==="optional"||l.type==="nonoptional"||l.type==="nullable"||l.type==="readonly"||l.type==="default"||l.type==="prefault")return Zt(l.innerType,i);if(l.type==="intersection")return Zt(l.left,i)||Zt(l.right,i);if(l.type==="record"||l.type==="map")return Zt(l.keyType,i)||Zt(l.valueType,i);if(l.type==="pipe")return Zt(l.in,i)||Zt(l.out,i);if(l.type==="object"){for(const n in l.shape)if(Zt(l.shape[n],i))return!0;return!1}if(l.type==="union"){for(const n of l.options)if(Zt(n,i))return!0;return!1}if(l.type==="tuple"){for(const n of l.items)if(Zt(n,i))return!0;return!!(l.rest&&Zt(l.rest,i))}return!1}const EE=(e,t={})=>i=>{const l=Ga({...i,processors:t});return et(e,l),Va(l,e),Ya(l,e)},ho=(e,t,i={})=>l=>{const{libraryOptions:n,target:o}=l??{},s=Ga({...n??{},target:o,io:t,processors:i});return et(e,s),Va(s,e),Ya(s,e)},sI={guid:"uuid",url:"uri",datetime:"date-time",json_string:"json-string",regex:""},jE=(e,t,i,l)=>{const n=i;n.type="string";const{minimum:o,maximum:s,format:f,patterns:m,contentEncoding:d}=e._zod.bag;if(typeof o=="number"&&(n.minLength=o),typeof s=="number"&&(n.maxLength=s),f&&(n.format=sI[f]??f,n.format===""&&delete n.format,f==="time"&&delete n.format),d&&(n.contentEncoding=d),m&&m.size>0){const p=[...m];p.length===1?n.pattern=p[0].source:p.length>1&&(n.allOf=[...p.map(v=>({...t.target==="draft-07"||t.target==="draft-04"||t.target==="openapi-3.0"?{type:"string"}:{},pattern:v.source}))])}},zE=(e,t,i,l)=>{const n=i,{minimum:o,maximum:s,format:f,multipleOf:m,exclusiveMaximum:d,exclusiveMinimum:p}=e._zod.bag;typeof f=="string"&&f.includes("int")?n.type="integer":n.type="number",typeof p=="number"&&(t.target==="draft-04"||t.target==="openapi-3.0"?(n.minimum=p,n.exclusiveMinimum=!0):n.exclusiveMinimum=p),typeof o=="number"&&(n.minimum=o,typeof p=="number"&&t.target!=="draft-04"&&(p>=o?delete n.minimum:delete n.exclusiveMinimum)),typeof d=="number"&&(t.target==="draft-04"||t.target==="openapi-3.0"?(n.maximum=d,n.exclusiveMaximum=!0):n.exclusiveMaximum=d),typeof s=="number"&&(n.maximum=s,typeof d=="number"&&t.target!=="draft-04"&&(d<=s?delete n.maximum:delete n.exclusiveMaximum)),typeof m=="number"&&(n.multipleOf=m)},NE=(e,t,i,l)=>{i.type="boolean"},OE=(e,t,i,l)=>{if(t.unrepresentable==="throw")throw new Error("BigInt cannot be represented in JSON Schema")},TE=(e,t,i,l)=>{if(t.unrepresentable==="throw")throw new Error("Symbols cannot be represented in JSON Schema")},CE=(e,t,i,l)=>{t.target==="openapi-3.0"?(i.type="string",i.nullable=!0,i.enum=[null]):i.type="null"},DE=(e,t,i,l)=>{if(t.unrepresentable==="throw")throw new Error("Undefined cannot be represented in JSON Schema")},AE=(e,t,i,l)=>{if(t.unrepresentable==="throw")throw new Error("Void cannot be represented in JSON Schema")},RE=(e,t,i,l)=>{i.not={}},IE=(e,t,i,l)=>{},UE=(e,t,i,l)=>{},LE=(e,t,i,l)=>{if(t.unrepresentable==="throw")throw new Error("Date cannot be represented in JSON Schema")},ME=(e,t,i,l)=>{const n=e._zod.def,o=ec(n.entries);o.every(s=>typeof s=="number")&&(i.type="number"),o.every(s=>typeof s=="string")&&(i.type="string"),i.enum=o},PE=(e,t,i,l)=>{const n=e._zod.def,o=[];for(const s of n.values)if(s===void 0){if(t.unrepresentable==="throw")throw new Error("Literal `undefined` cannot be represented in JSON Schema")}else if(typeof s=="bigint"){if(t.unrepresentable==="throw")throw new Error("BigInt literals cannot be represented in JSON Schema");o.push(Number(s))}else o.push(s);if(o.length!==0)if(o.length===1){const s=o[0];i.type=s===null?"null":typeof s,t.target==="draft-04"||t.target==="openapi-3.0"?i.enum=[s]:i.const=s}else o.every(s=>typeof s=="number")&&(i.type="number"),o.every(s=>typeof s=="string")&&(i.type="string"),o.every(s=>typeof s=="boolean")&&(i.type="boolean"),o.every(s=>s===null)&&(i.type="null"),i.enum=o},ZE=(e,t,i,l)=>{if(t.unrepresentable==="throw")throw new Error("NaN cannot be represented in JSON Schema")},qE=(e,t,i,l)=>{const n=i,o=e._zod.pattern;if(!o)throw new Error("Pattern not found in template literal");n.type="string",n.pattern=o.source},FE=(e,t,i,l)=>{const n=i,o={type:"string",format:"binary",contentEncoding:"binary"},{minimum:s,maximum:f,mime:m}=e._zod.bag;s!==void 0&&(o.minLength=s),f!==void 0&&(o.maxLength=f),m?m.length===1?(o.contentMediaType=m[0],Object.assign(n,o)):(Object.assign(n,o),n.anyOf=m.map(d=>({contentMediaType:d}))):Object.assign(n,o)},BE=(e,t,i,l)=>{i.type="boolean"},HE=(e,t,i,l)=>{if(t.unrepresentable==="throw")throw new Error("Custom types cannot be represented in JSON Schema")},GE=(e,t,i,l)=>{if(t.unrepresentable==="throw")throw new Error("Function types cannot be represented in JSON Schema")},VE=(e,t,i,l)=>{if(t.unrepresentable==="throw")throw new Error("Transforms cannot be represented in JSON Schema")},YE=(e,t,i,l)=>{if(t.unrepresentable==="throw")throw new Error("Map cannot be represented in JSON Schema")},JE=(e,t,i,l)=>{if(t.unrepresentable==="throw")throw new Error("Set cannot be represented in JSON Schema")},XE=(e,t,i,l)=>{const n=i,o=e._zod.def,{minimum:s,maximum:f}=e._zod.bag;typeof s=="number"&&(n.minItems=s),typeof f=="number"&&(n.maxItems=f),n.type="array",n.items=et(o.element,t,{...l,path:[...l.path,"items"]})},QE=(e,t,i,l)=>{const n=i,o=e._zod.def;n.type="object",n.properties={};const s=o.shape;for(const d in s)n.properties[d]=et(s[d],t,{...l,path:[...l.path,"properties",d]});const f=new Set(Object.keys(s)),m=new Set([...f].filter(d=>{const p=o.shape[d]._zod;return t.io==="input"?p.optin===void 0:p.optout===void 0}));m.size>0&&(n.required=Array.from(m)),o.catchall?._zod.def.type==="never"?n.additionalProperties=!1:o.catchall?o.catchall&&(n.additionalProperties=et(o.catchall,t,{...l,path:[...l.path,"additionalProperties"]})):t.io==="output"&&(n.additionalProperties=!1)},xg=(e,t,i,l)=>{const n=e._zod.def,o=n.inclusive===!1,s=n.options.map((f,m)=>et(f,t,{...l,path:[...l.path,o?"oneOf":"anyOf",m]}));o?i.oneOf=s:i.anyOf=s},KE=(e,t,i,l)=>{const n=e._zod.def,o=et(n.left,t,{...l,path:[...l.path,"allOf",0]}),s=et(n.right,t,{...l,path:[...l.path,"allOf",1]}),f=d=>"allOf"in d&&Object.keys(d).length===1,m=[...f(o)?o.allOf:[o],...f(s)?s.allOf:[s]];i.allOf=m},WE=(e,t,i,l)=>{const n=i,o=e._zod.def;n.type="array";const s=t.target==="draft-2020-12"?"prefixItems":"items",f=t.target==="draft-2020-12"||t.target==="openapi-3.0"?"items":"additionalItems",m=o.items.map((b,x)=>et(b,t,{...l,path:[...l.path,s,x]})),d=o.rest?et(o.rest,t,{...l,path:[...l.path,f,...t.target==="openapi-3.0"?[o.items.length]:[]]}):null;t.target==="draft-2020-12"?(n.prefixItems=m,d&&(n.items=d)):t.target==="openapi-3.0"?(n.items={anyOf:m},d&&n.items.anyOf.push(d),n.minItems=m.length,d||(n.maxItems=m.length)):(n.items=m,d&&(n.additionalItems=d));const{minimum:p,maximum:v}=e._zod.bag;typeof p=="number"&&(n.minItems=p),typeof v=="number"&&(n.maxItems=v)},ej=(e,t,i,l)=>{const n=i,o=e._zod.def;n.type="object",(t.target==="draft-07"||t.target==="draft-2020-12")&&(n.propertyNames=et(o.keyType,t,{...l,path:[...l.path,"propertyNames"]})),n.additionalProperties=et(o.valueType,t,{...l,path:[...l.path,"additionalProperties"]});const s=o.keyType._zod.def;if(s.type==="enum"){const m=ec(s.entries).filter(d=>typeof d=="string"||typeof d=="number");m.length>0&&(n.required=m)}},tj=(e,t,i,l)=>{const n=e._zod.def,o=et(n.innerType,t,l),s=t.seen.get(e);t.target==="openapi-3.0"?(s.ref=n.innerType,i.nullable=!0):i.anyOf=[o,{type:"null"}]},nj=(e,t,i,l)=>{const n=e._zod.def;et(n.innerType,t,l);const o=t.seen.get(e);o.ref=n.innerType},rj=(e,t,i,l)=>{const n=e._zod.def;et(n.innerType,t,l);const o=t.seen.get(e);o.ref=n.innerType,i.default=JSON.parse(JSON.stringify(n.defaultValue))},ij=(e,t,i,l)=>{const n=e._zod.def;et(n.innerType,t,l);const o=t.seen.get(e);o.ref=n.innerType,t.io==="input"&&(i._prefault=JSON.parse(JSON.stringify(n.defaultValue)))},aj=(e,t,i,l)=>{const n=e._zod.def;et(n.innerType,t,l);const o=t.seen.get(e);o.ref=n.innerType;let s;try{s=n.catchValue(void 0)}catch{throw new Error("Dynamic catch values are not supported in JSON Schema")}i.default=s},lj=(e,t,i,l)=>{const n=e._zod.def,o=t.io==="input"?n.in._zod.def.type==="transform"?n.out:n.in:n.out;et(o,t,l);const s=t.seen.get(e);s.ref=o},oj=(e,t,i,l)=>{const n=e._zod.def;et(n.innerType,t,l);const o=t.seen.get(e);o.ref=n.innerType,i.readOnly=!0},uj=(e,t,i,l)=>{const n=e._zod.def;et(n.innerType,t,l);const o=t.seen.get(e);o.ref=n.innerType},_g=(e,t,i,l)=>{const n=e._zod.def;et(n.innerType,t,l);const o=t.seen.get(e);o.ref=n.innerType},sj=(e,t,i,l)=>{const n=e._zod.innerType;et(n,t,l);const o=t.seen.get(e);o.ref=n},Wh={string:jE,number:zE,boolean:NE,bigint:OE,symbol:TE,null:CE,undefined:DE,void:AE,never:RE,any:IE,unknown:UE,date:LE,enum:ME,literal:PE,nan:ZE,template_literal:qE,file:FE,success:BE,custom:HE,function:GE,transform:VE,map:YE,set:JE,array:XE,object:QE,union:xg,intersection:KE,tuple:WE,record:ej,nullable:tj,nonoptional:nj,default:rj,prefault:ij,catch:aj,pipe:lj,readonly:oj,promise:uj,optional:_g,lazy:sj};function cj(e,t){if("_idmap"in e){const l=e,n=Ga({...t,processors:Wh}),o={};for(const m of l._idmap.entries()){const[d,p]=m;et(p,n)}const s={},f={registry:l,uri:t?.uri,defs:o};n.external=f;for(const m of l._idmap.entries()){const[d,p]=m;Va(n,p),s[d]=Ya(n,p)}if(Object.keys(o).length>0){const m=n.target==="draft-2020-12"?"$defs":"definitions";s.__shared={[m]:o}}return{schemas:s}}const i=Ga({...t,processors:Wh});return et(e,i),Va(i,e),Ya(i,e)}class cI{get metadataRegistry(){return this.ctx.metadataRegistry}get target(){return this.ctx.target}get unrepresentable(){return this.ctx.unrepresentable}get override(){return this.ctx.override}get io(){return this.ctx.io}get counter(){return this.ctx.counter}set counter(t){this.ctx.counter=t}get seen(){return this.ctx.seen}constructor(t){let i=t?.target??"draft-2020-12";i==="draft-4"&&(i="draft-04"),i==="draft-7"&&(i="draft-07"),this.ctx=Ga({processors:Wh,target:i,...t?.metadata&&{metadata:t.metadata},...t?.unrepresentable&&{unrepresentable:t.unrepresentable},...t?.override&&{override:t.override},...t?.io&&{io:t.io}})}process(t,i={path:[],schemaPath:[]}){return et(t,this.ctx,i)}emit(t,i){i&&(i.cycles&&(this.ctx.cycles=i.cycles),i.reused&&(this.ctx.reused=i.reused),i.external&&(this.ctx.external=i.external)),Va(this.ctx,t);const l=Ya(this.ctx,t),{"~standard":n,...o}=l;return o}}const fI=Object.freeze(Object.defineProperty({__proto__:null},Symbol.toStringTag,{value:"Module"})),dI=Object.freeze(Object.defineProperty({__proto__:null,$ZodAny:Kw,$ZodArray:r$,$ZodAsyncError:Di,$ZodBase64:Pw,$ZodBase64URL:qw,$ZodBigInt:Bp,$ZodBigIntFormat:Yw,$ZodBoolean:Fp,$ZodCIDRv4:Lw,$ZodCIDRv6:Mw,$ZodCUID:Ew,$ZodCUID2:jw,$ZodCatch:w$,$ZodCheck:st,$ZodCheckBigIntFormat:nw,$ZodCheckEndsWith:hw,$ZodCheckGreaterThan:Pp,$ZodCheckIncludes:dw,$ZodCheckLengthEquals:uw,$ZodCheckLessThan:Mp,$ZodCheckLowerCase:cw,$ZodCheckMaxLength:lw,$ZodCheckMaxSize:rw,$ZodCheckMimeType:gw,$ZodCheckMinLength:ow,$ZodCheckMinSize:iw,$ZodCheckMultipleOf:ew,$ZodCheckNumberFormat:tw,$ZodCheckOverwrite:vw,$ZodCheckProperty:pw,$ZodCheckRegex:sw,$ZodCheckSizeEquals:aw,$ZodCheckStartsWith:mw,$ZodCheckStringFormat:Ro,$ZodCheckUpperCase:fw,$ZodCodec:Vp,$ZodCustom:C$,$ZodCustomStringFormat:Gw,$ZodDate:n$,$ZodDefault:x$,$ZodDiscriminatedUnion:s$,$ZodE164:Fw,$ZodEmail:Sw,$ZodEmoji:ww,$ZodEncodeError:Ws,$ZodEnum:h$,$ZodError:$p,$ZodExactOptional:y$,$ZodFile:g$,$ZodFunction:N$,$ZodGUID:xw,$ZodIPv4:Rw,$ZodIPv6:Iw,$ZodISODate:Cw,$ZodISODateTime:Tw,$ZodISODuration:Aw,$ZodISOTime:Dw,$ZodIntersection:c$,$ZodJWT:Hw,$ZodKSUID:Ow,$ZodLazy:T$,$ZodLiteral:p$,$ZodMAC:Uw,$ZodMap:d$,$ZodNaN:$$,$ZodNanoID:$w,$ZodNever:e$,$ZodNonOptional:S$,$ZodNull:Qw,$ZodNullable:b$,$ZodNumber:qp,$ZodNumberFormat:Vw,$ZodObject:l$,$ZodObjectJIT:o$,$ZodOptional:Gp,$ZodPipe:E$,$ZodPrefault:_$,$ZodPromise:O$,$ZodReadonly:j$,$ZodRealError:hn,$ZodRecord:f$,$ZodRegistry:M$,$ZodSet:m$,$ZodString:Io,$ZodStringFormat:tt,$ZodSuccess:k$,$ZodSymbol:Jw,$ZodTemplateLiteral:z$,$ZodTransform:v$,$ZodTuple:Hp,$ZodType:$e,$ZodULID:zw,$ZodURL:kw,$ZodUUID:_w,$ZodUndefined:Xw,$ZodUnion:ac,$ZodUnknown:Ww,$ZodVoid:t$,$ZodXID:Nw,$ZodXor:u$,$brand:JS,$constructor:P,$input:L$,$output:U$,Doc:yw,JSONSchema:fI,JSONSchemaGenerator:cI,NEVER:YS,TimePrecision:F$,_any:cE,_array:vE,_base64:fg,_base64url:dg,_bigint:rE,_boolean:tE,_catch:rI,_check:SE,_cidrv4:sg,_cidrv6:cg,_coercedBigint:iE,_coercedBoolean:nE,_coercedDate:pE,_coercedNumber:J$,_coercedString:Z$,_cuid:ng,_cuid2:rg,_custom:bE,_date:hE,_decode:Np,_decodeAsync:Tp,_default:eI,_discriminatedUnion:qR,_e164:mg,_email:Jp,_emoji:eg,_encode:zp,_encodeAsync:Op,_endsWith:dc,_enum:YR,_file:yE,_float32:Q$,_float64:K$,_gt:ui,_gte:en,_guid:qs,_includes:cc,_int:X$,_int32:W$,_int64:aE,_intersection:FR,_ipv4:og,_ipv6:ug,_isoDate:H$,_isoDateTime:B$,_isoDuration:V$,_isoTime:G$,_jwt:hg,_ksuid:lg,_lazy:oI,_length:Mo,_literal:XR,_lowercase:uc,_lt:oi,_lte:On,_mac:q$,_map:GR,_max:On,_maxLength:Lo,_maxSize:el,_mime:mc,_min:en,_minLength:Mi,_minSize:si,_multipleOf:Ha,_nan:gE,_nanoid:tg,_nativeEnum:JR,_negative:gg,_never:dE,_nonnegative:yg,_nonoptional:tI,_nonpositive:vg,_normalize:hc,_null:sE,_nullable:WR,_number:Y$,_optional:KR,_overwrite:Or,_parse:No,_parseAsync:Oo,_pipe:iI,_positive:pg,_promise:uI,_property:bg,_readonly:aI,_record:HR,_refine:xE,_regex:oc,_safeDecode:Dp,_safeDecodeAsync:Rp,_safeEncode:Cp,_safeEncodeAsync:Ap,_safeParse:To,_safeParseAsync:Co,_set:VR,_size:Uo,_slugify:yc,_startsWith:fc,_string:P$,_stringFormat:Po,_stringbool:$E,_success:nI,_superRefine:_E,_symbol:oE,_templateLiteral:lI,_toLowerCase:gc,_toUpperCase:vc,_transform:QR,_trim:pc,_tuple:BR,_uint32:eE,_uint64:lE,_ulid:ig,_undefined:uE,_union:PR,_unknown:fE,_uppercase:sc,_url:lc,_uuid:Xp,_uuidv4:Qp,_uuidv6:Kp,_uuidv7:Wp,_void:mE,_xid:ag,_xor:ZR,clone:Rn,config:It,createStandardJSONSchemaMethod:ho,createToJSONSchemaMethod:EE,decode:wD,decodeAsync:ED,describe:kE,encode:kD,encodeAsync:$D,extractDefs:Va,finalize:Ya,flattenError:Ep,formatError:jp,globalConfig:Ls,globalRegistry:Nn,initializeContext:Ga,isValidBase64:Zp,isValidBase64URL:Zw,isValidJWT:Bw,locales:I$,meta:wE,parse:Xh,parseAsync:Qh,prettifyError:gk,process:et,regexes:Lp,registry:Yp,safeDecode:zD,safeDecodeAsync:OD,safeEncode:jD,safeEncodeAsync:ND,safeParse:vk,safeParseAsync:yk,toDotPath:pk,toJSONSchema:cj,treeifyError:hk,util:dk,version:bw},Symbol.toStringTag,{value:"Module"})),mI=Object.freeze(Object.defineProperty({__proto__:null,endsWith:dc,gt:ui,gte:en,includes:cc,length:Mo,lowercase:uc,lt:oi,lte:On,maxLength:Lo,maxSize:el,mime:mc,minLength:Mi,minSize:si,multipleOf:Ha,negative:gg,nonnegative:yg,nonpositive:vg,normalize:hc,overwrite:Or,positive:pg,property:bg,regex:oc,size:Uo,slugify:yc,startsWith:fc,toLowerCase:gc,toUpperCase:vc,trim:pc,uppercase:sc},Symbol.toStringTag,{value:"Module"})),Sg=P("ZodISODateTime",(e,t)=>{Tw.init(e,t),nt.init(e,t)});function fj(e){return B$(Sg,e)}const kg=P("ZodISODate",(e,t)=>{Cw.init(e,t),nt.init(e,t)});function dj(e){return H$(kg,e)}const wg=P("ZodISOTime",(e,t)=>{Dw.init(e,t),nt.init(e,t)});function mj(e){return G$(wg,e)}const $g=P("ZodISODuration",(e,t)=>{Aw.init(e,t),nt.init(e,t)});function hj(e){return V$($g,e)}const pj=Object.freeze(Object.defineProperty({__proto__:null,ZodISODate:kg,ZodISODateTime:Sg,ZodISODuration:$g,ZodISOTime:wg,date:dj,datetime:fj,duration:hj,time:mj},Symbol.toStringTag,{value:"Module"})),gj=(e,t)=>{$p.init(e,t),e.name="ZodError",Object.defineProperties(e,{format:{value:i=>jp(e,i)},flatten:{value:i=>Ep(e,i)},addIssue:{value:i=>{e.issues.push(i),e.message=JSON.stringify(e.issues,Ms,2)}},addIssues:{value:i=>{e.issues.push(...i),e.message=JSON.stringify(e.issues,Ms,2)}},isEmpty:{get(){return e.issues.length===0}}})},hI=P("ZodError",gj),pn=P("ZodError",gj,{Parent:Error}),vj=No(pn),yj=Oo(pn),bj=To(pn),xj=Co(pn),_j=zp(pn),Sj=Np(pn),kj=Op(pn),wj=Tp(pn),$j=Cp(pn),Ej=Dp(pn),jj=Ap(pn),zj=Rp(pn),ze=P("ZodType",(e,t)=>($e.init(e,t),Object.assign(e["~standard"],{jsonSchema:{input:ho(e,"input"),output:ho(e,"output")}}),e.toJSONSchema=EE(e,{}),e.def=t,e.type=t.type,Object.defineProperty(e,"_def",{value:t}),e.check=(...i)=>e.clone(tr(t,{checks:[...t.checks??[],...i.map(l=>typeof l=="function"?{_zod:{check:l,def:{check:"custom"},onattach:[]}}:l)]}),{parent:!0}),e.with=e.check,e.clone=(i,l)=>Rn(e,i,l),e.brand=()=>e,e.register=((i,l)=>(i.add(e,l),e)),e.parse=(i,l)=>vj(e,i,l,{callee:e.parse}),e.safeParse=(i,l)=>bj(e,i,l),e.parseAsync=async(i,l)=>yj(e,i,l,{callee:e.parseAsync}),e.safeParseAsync=async(i,l)=>xj(e,i,l),e.spa=e.safeParseAsync,e.encode=(i,l)=>_j(e,i,l),e.decode=(i,l)=>Sj(e,i,l),e.encodeAsync=async(i,l)=>kj(e,i,l),e.decodeAsync=async(i,l)=>wj(e,i,l),e.safeEncode=(i,l)=>$j(e,i,l),e.safeDecode=(i,l)=>Ej(e,i,l),e.safeEncodeAsync=async(i,l)=>jj(e,i,l),e.safeDecodeAsync=async(i,l)=>zj(e,i,l),e.refine=(i,l)=>e.check(dv(i,l)),e.superRefine=i=>e.check(mv(i)),e.overwrite=i=>e.check(Or(i)),e.optional=()=>go(e),e.exactOptional=()=>Yg(e),e.nullable=()=>vo(e),e.nullish=()=>go(vo(e)),e.nonoptional=i=>ev(e,i),e.array=()=>Bi(e),e.or=i=>Mc([e,i]),e.and=i=>Mg(e,i),e.transform=i=>yo(e,Zc(i)),e.default=i=>Qg(e,i),e.prefault=i=>Wg(e,i),e.catch=i=>rv(e,i),e.pipe=i=>yo(e,i),e.readonly=()=>lv(e),e.describe=i=>{const l=e.clone();return Nn.add(l,{description:i}),l},Object.defineProperty(e,"description",{get(){return Nn.get(e)?.description},configurable:!0}),e.meta=(...i)=>{if(i.length===0)return Nn.get(e);const l=e.clone();return Nn.add(l,i[0]),l},e.isOptional=()=>e.safeParse(void 0).success,e.isNullable=()=>e.safeParse(null).success,e.apply=i=>i(e),e)),bc=P("_ZodString",(e,t)=>{Io.init(e,t),ze.init(e,t),e._zod.processJSONSchema=(l,n,o)=>jE(e,l,n);const i=e._zod.bag;e.format=i.format??null,e.minLength=i.minimum??null,e.maxLength=i.maximum??null,e.regex=(...l)=>e.check(oc(...l)),e.includes=(...l)=>e.check(cc(...l)),e.startsWith=(...l)=>e.check(fc(...l)),e.endsWith=(...l)=>e.check(dc(...l)),e.min=(...l)=>e.check(Mi(...l)),e.max=(...l)=>e.check(Lo(...l)),e.length=(...l)=>e.check(Mo(...l)),e.nonempty=(...l)=>e.check(Mi(1,...l)),e.lowercase=l=>e.check(uc(l)),e.uppercase=l=>e.check(sc(l)),e.trim=()=>e.check(pc()),e.normalize=(...l)=>e.check(hc(...l)),e.toLowerCase=()=>e.check(gc()),e.toUpperCase=()=>e.check(vc()),e.slugify=()=>e.check(yc())}),Zo=P("ZodString",(e,t)=>{Io.init(e,t),bc.init(e,t),e.email=i=>e.check(Jp(xc,i)),e.url=i=>e.check(lc(qo,i)),e.jwt=i=>e.check(hg(Rc,i)),e.emoji=i=>e.check(eg(_c,i)),e.guid=i=>e.check(qs(po,i)),e.uuid=i=>e.check(Xp(Kn,i)),e.uuidv4=i=>e.check(Qp(Kn,i)),e.uuidv6=i=>e.check(Kp(Kn,i)),e.uuidv7=i=>e.check(Wp(Kn,i)),e.nanoid=i=>e.check(tg(Sc,i)),e.guid=i=>e.check(qs(po,i)),e.cuid=i=>e.check(ng(kc,i)),e.cuid2=i=>e.check(rg(wc,i)),e.ulid=i=>e.check(ig($c,i)),e.base64=i=>e.check(fg(Cc,i)),e.base64url=i=>e.check(dg(Dc,i)),e.xid=i=>e.check(ag(Ec,i)),e.ksuid=i=>e.check(lg(jc,i)),e.ipv4=i=>e.check(og(zc,i)),e.ipv6=i=>e.check(ug(Nc,i)),e.cidrv4=i=>e.check(sg(Oc,i)),e.cidrv6=i=>e.check(cg(Tc,i)),e.e164=i=>e.check(mg(Ac,i)),e.datetime=i=>e.check(fj(i)),e.date=i=>e.check(dj(i)),e.time=i=>e.check(mj(i)),e.duration=i=>e.check(hj(i))});function je(e){return P$(Zo,e)}const nt=P("ZodStringFormat",(e,t)=>{tt.init(e,t),bc.init(e,t)}),xc=P("ZodEmail",(e,t)=>{Sw.init(e,t),nt.init(e,t)});function Nj(e){return Jp(xc,e)}const po=P("ZodGUID",(e,t)=>{xw.init(e,t),nt.init(e,t)});function Oj(e){return qs(po,e)}const Kn=P("ZodUUID",(e,t)=>{_w.init(e,t),nt.init(e,t)});function Tj(e){return Xp(Kn,e)}function Cj(e){return Qp(Kn,e)}function Dj(e){return Kp(Kn,e)}function Aj(e){return Wp(Kn,e)}const qo=P("ZodURL",(e,t)=>{kw.init(e,t),nt.init(e,t)});function Rj(e){return lc(qo,e)}function Ij(e){return lc(qo,{protocol:/^https?$/,hostname:Uk,...re(e)})}const _c=P("ZodEmoji",(e,t)=>{ww.init(e,t),nt.init(e,t)});function Uj(e){return eg(_c,e)}const Sc=P("ZodNanoID",(e,t)=>{$w.init(e,t),nt.init(e,t)});function Lj(e){return tg(Sc,e)}const kc=P("ZodCUID",(e,t)=>{Ew.init(e,t),nt.init(e,t)});function Mj(e){return ng(kc,e)}const wc=P("ZodCUID2",(e,t)=>{jw.init(e,t),nt.init(e,t)});function Pj(e){return rg(wc,e)}const $c=P("ZodULID",(e,t)=>{zw.init(e,t),nt.init(e,t)});function Zj(e){return ig($c,e)}const Ec=P("ZodXID",(e,t)=>{Nw.init(e,t),nt.init(e,t)});function qj(e){return ag(Ec,e)}const jc=P("ZodKSUID",(e,t)=>{Ow.init(e,t),nt.init(e,t)});function Fj(e){return lg(jc,e)}const zc=P("ZodIPv4",(e,t)=>{Rw.init(e,t),nt.init(e,t)});function Bj(e){return og(zc,e)}const Eg=P("ZodMAC",(e,t)=>{Uw.init(e,t),nt.init(e,t)});function Hj(e){return q$(Eg,e)}const Nc=P("ZodIPv6",(e,t)=>{Iw.init(e,t),nt.init(e,t)});function Gj(e){return ug(Nc,e)}const Oc=P("ZodCIDRv4",(e,t)=>{Lw.init(e,t),nt.init(e,t)});function Vj(e){return sg(Oc,e)}const Tc=P("ZodCIDRv6",(e,t)=>{Mw.init(e,t),nt.init(e,t)});function Yj(e){return cg(Tc,e)}const Cc=P("ZodBase64",(e,t)=>{Pw.init(e,t),nt.init(e,t)});function Jj(e){return fg(Cc,e)}const Dc=P("ZodBase64URL",(e,t)=>{qw.init(e,t),nt.init(e,t)});function Xj(e){return dg(Dc,e)}const Ac=P("ZodE164",(e,t)=>{Fw.init(e,t),nt.init(e,t)});function Qj(e){return mg(Ac,e)}const Rc=P("ZodJWT",(e,t)=>{Hw.init(e,t),nt.init(e,t)});function Kj(e){return hg(Rc,e)}const tl=P("ZodCustomStringFormat",(e,t)=>{Gw.init(e,t),nt.init(e,t)});function Wj(e,t,i={}){return Po(tl,e,t,i)}function e4(e){return Po(tl,"hostname",Ik,e)}function t4(e){return Po(tl,"hex",Kk,e)}function n4(e,t){const i=t?.enc??"hex",l=`${e}_${i}`,n=Lp[l];if(!n)throw new Error(`Unrecognized hash format: ${l}`);return Po(tl,l,n,t)}const Fo=P("ZodNumber",(e,t)=>{qp.init(e,t),ze.init(e,t),e._zod.processJSONSchema=(l,n,o)=>zE(e,l,n),e.gt=(l,n)=>e.check(ui(l,n)),e.gte=(l,n)=>e.check(en(l,n)),e.min=(l,n)=>e.check(en(l,n)),e.lt=(l,n)=>e.check(oi(l,n)),e.lte=(l,n)=>e.check(On(l,n)),e.max=(l,n)=>e.check(On(l,n)),e.int=l=>e.check(Fs(l)),e.safe=l=>e.check(Fs(l)),e.positive=l=>e.check(ui(0,l)),e.nonnegative=l=>e.check(en(0,l)),e.negative=l=>e.check(oi(0,l)),e.nonpositive=l=>e.check(On(0,l)),e.multipleOf=(l,n)=>e.check(Ha(l,n)),e.step=(l,n)=>e.check(Ha(l,n)),e.finite=()=>e;const i=e._zod.bag;e.minValue=Math.max(i.minimum??Number.NEGATIVE_INFINITY,i.exclusiveMinimum??Number.NEGATIVE_INFINITY)??null,e.maxValue=Math.min(i.maximum??Number.POSITIVE_INFINITY,i.exclusiveMaximum??Number.POSITIVE_INFINITY)??null,e.isInt=(i.format??"").includes("int")||Number.isSafeInteger(i.multipleOf??.5),e.isFinite=!0,e.format=i.format??null});function jt(e){return Y$(Fo,e)}const Fi=P("ZodNumberFormat",(e,t)=>{Vw.init(e,t),Fo.init(e,t)});function Fs(e){return X$(Fi,e)}function r4(e){return Q$(Fi,e)}function i4(e){return K$(Fi,e)}function a4(e){return W$(Fi,e)}function l4(e){return eE(Fi,e)}const Bo=P("ZodBoolean",(e,t)=>{Fp.init(e,t),ze.init(e,t),e._zod.processJSONSchema=(i,l,n)=>NE(e,i,l)});function jr(e){return tE(Bo,e)}const Ho=P("ZodBigInt",(e,t)=>{Bp.init(e,t),ze.init(e,t),e._zod.processJSONSchema=(l,n,o)=>OE(e,l),e.gte=(l,n)=>e.check(en(l,n)),e.min=(l,n)=>e.check(en(l,n)),e.gt=(l,n)=>e.check(ui(l,n)),e.gte=(l,n)=>e.check(en(l,n)),e.min=(l,n)=>e.check(en(l,n)),e.lt=(l,n)=>e.check(oi(l,n)),e.lte=(l,n)=>e.check(On(l,n)),e.max=(l,n)=>e.check(On(l,n)),e.positive=l=>e.check(ui(BigInt(0),l)),e.negative=l=>e.check(oi(BigInt(0),l)),e.nonpositive=l=>e.check(On(BigInt(0),l)),e.nonnegative=l=>e.check(en(BigInt(0),l)),e.multipleOf=(l,n)=>e.check(Ha(l,n));const i=e._zod.bag;e.minValue=i.minimum??null,e.maxValue=i.maximum??null,e.format=i.format??null});function o4(e){return rE(Ho,e)}const Ic=P("ZodBigIntFormat",(e,t)=>{Yw.init(e,t),Ho.init(e,t)});function u4(e){return aE(Ic,e)}function s4(e){return lE(Ic,e)}const jg=P("ZodSymbol",(e,t)=>{Jw.init(e,t),ze.init(e,t),e._zod.processJSONSchema=(i,l,n)=>TE(e,i)});function c4(e){return oE(jg,e)}const zg=P("ZodUndefined",(e,t)=>{Xw.init(e,t),ze.init(e,t),e._zod.processJSONSchema=(i,l,n)=>DE(e,i)});function f4(e){return uE(zg,e)}const Ng=P("ZodNull",(e,t)=>{Qw.init(e,t),ze.init(e,t),e._zod.processJSONSchema=(i,l,n)=>CE(e,i,l)});function Og(e){return sE(Ng,e)}const Tg=P("ZodAny",(e,t)=>{Kw.init(e,t),ze.init(e,t),e._zod.processJSONSchema=(i,l,n)=>IE()});function d4(){return cE(Tg)}const Cg=P("ZodUnknown",(e,t)=>{Ww.init(e,t),ze.init(e,t),e._zod.processJSONSchema=(i,l,n)=>UE()});function Pi(){return fE(Cg)}const Dg=P("ZodNever",(e,t)=>{e$.init(e,t),ze.init(e,t),e._zod.processJSONSchema=(i,l,n)=>RE(e,i,l)});function Uc(e){return dE(Dg,e)}const Ag=P("ZodVoid",(e,t)=>{t$.init(e,t),ze.init(e,t),e._zod.processJSONSchema=(i,l,n)=>AE(e,i)});function m4(e){return mE(Ag,e)}const Lc=P("ZodDate",(e,t)=>{n$.init(e,t),ze.init(e,t),e._zod.processJSONSchema=(l,n,o)=>LE(e,l),e.min=(l,n)=>e.check(en(l,n)),e.max=(l,n)=>e.check(On(l,n));const i=e._zod.bag;e.minDate=i.minimum?new Date(i.minimum):null,e.maxDate=i.maximum?new Date(i.maximum):null});function h4(e){return hE(Lc,e)}const Rg=P("ZodArray",(e,t)=>{r$.init(e,t),ze.init(e,t),e._zod.processJSONSchema=(i,l,n)=>XE(e,i,l,n),e.element=t.element,e.min=(i,l)=>e.check(Mi(i,l)),e.nonempty=i=>e.check(Mi(1,i)),e.max=(i,l)=>e.check(Lo(i,l)),e.length=(i,l)=>e.check(Mo(i,l)),e.unwrap=()=>e.element});function Bi(e,t){return vE(Rg,e,t)}function p4(e){const t=e._zod.def.shape;return Fn(Object.keys(t))}const Go=P("ZodObject",(e,t)=>{o$.init(e,t),ze.init(e,t),e._zod.processJSONSchema=(i,l,n)=>QE(e,i,l,n),Te(e,"shape",()=>t.shape),e.keyof=()=>Fn(Object.keys(e._zod.def.shape)),e.catchall=i=>e.clone({...e._zod.def,catchall:i}),e.passthrough=()=>e.clone({...e._zod.def,catchall:Pi()}),e.loose=()=>e.clone({...e._zod.def,catchall:Pi()}),e.strict=()=>e.clone({...e._zod.def,catchall:Uc()}),e.strip=()=>e.clone({...e._zod.def,catchall:void 0}),e.extend=i=>ak(e,i),e.safeExtend=i=>lk(e,i),e.merge=i=>ok(e,i),e.pick=i=>rk(e,i),e.omit=i=>ik(e,i),e.partial=(...i)=>uk(qc,e,i[0]),e.required=(...i)=>sk(Fc,e,i[0])});function pt(e,t){const i={type:"object",shape:e??{},...re(t)};return new Go(i)}function g4(e,t){return new Go({type:"object",shape:e,catchall:Uc(),...re(t)})}function v4(e,t){return new Go({type:"object",shape:e,catchall:Pi(),...re(t)})}const Vo=P("ZodUnion",(e,t)=>{ac.init(e,t),ze.init(e,t),e._zod.processJSONSchema=(i,l,n)=>xg(e,i,l,n),e.options=t.options});function Mc(e,t){return new Vo({type:"union",options:e,...re(t)})}const Ig=P("ZodXor",(e,t)=>{Vo.init(e,t),u$.init(e,t),e._zod.processJSONSchema=(i,l,n)=>xg(e,i,l,n),e.options=t.options});function y4(e,t){return new Ig({type:"union",options:e,inclusive:!1,...re(t)})}const Ug=P("ZodDiscriminatedUnion",(e,t)=>{Vo.init(e,t),s$.init(e,t)});function b4(e,t,i){return new Ug({type:"union",options:t,discriminator:e,...re(i)})}const Lg=P("ZodIntersection",(e,t)=>{c$.init(e,t),ze.init(e,t),e._zod.processJSONSchema=(i,l,n)=>KE(e,i,l,n)});function Mg(e,t){return new Lg({type:"intersection",left:e,right:t})}const Pg=P("ZodTuple",(e,t)=>{Hp.init(e,t),ze.init(e,t),e._zod.processJSONSchema=(i,l,n)=>WE(e,i,l,n),e.rest=i=>e.clone({...e._zod.def,rest:i})});function Zg(e,t,i){const l=t instanceof $e,n=l?i:t,o=l?t:null;return new Pg({type:"tuple",items:e,rest:o,...re(n)})}const Yo=P("ZodRecord",(e,t)=>{f$.init(e,t),ze.init(e,t),e._zod.processJSONSchema=(i,l,n)=>ej(e,i,l,n),e.keyType=t.keyType,e.valueType=t.valueType});function Pc(e,t,i){return new Yo({type:"record",keyType:e,valueType:t,...re(i)})}function x4(e,t,i){const l=Rn(e);return l._zod.values=void 0,new Yo({type:"record",keyType:l,valueType:t,...re(i)})}function _4(e,t,i){return new Yo({type:"record",keyType:e,valueType:t,mode:"loose",...re(i)})}const qg=P("ZodMap",(e,t)=>{d$.init(e,t),ze.init(e,t),e._zod.processJSONSchema=(i,l,n)=>YE(e,i),e.keyType=t.keyType,e.valueType=t.valueType,e.min=(...i)=>e.check(si(...i)),e.nonempty=i=>e.check(si(1,i)),e.max=(...i)=>e.check(el(...i)),e.size=(...i)=>e.check(Uo(...i))});function S4(e,t,i){return new qg({type:"map",keyType:e,valueType:t,...re(i)})}const Fg=P("ZodSet",(e,t)=>{m$.init(e,t),ze.init(e,t),e._zod.processJSONSchema=(i,l,n)=>JE(e,i),e.min=(...i)=>e.check(si(...i)),e.nonempty=i=>e.check(si(1,i)),e.max=(...i)=>e.check(el(...i)),e.size=(...i)=>e.check(Uo(...i))});function k4(e,t){return new Fg({type:"set",valueType:e,...re(t)})}const Ja=P("ZodEnum",(e,t)=>{h$.init(e,t),ze.init(e,t),e._zod.processJSONSchema=(l,n,o)=>ME(e,l,n),e.enum=t.entries,e.options=Object.values(t.entries);const i=new Set(Object.keys(t.entries));e.extract=(l,n)=>{const o={};for(const s of l)if(i.has(s))o[s]=t.entries[s];else throw new Error(`Key ${s} not found in enum`);return new Ja({...t,checks:[],...re(n),entries:o})},e.exclude=(l,n)=>{const o={...t.entries};for(const s of l)if(i.has(s))delete o[s];else throw new Error(`Key ${s} not found in enum`);return new Ja({...t,checks:[],...re(n),entries:o})}});function Fn(e,t){const i=Array.isArray(e)?Object.fromEntries(e.map(l=>[l,l])):e;return new Ja({type:"enum",entries:i,...re(t)})}function w4(e,t){return new Ja({type:"enum",entries:e,...re(t)})}const Bg=P("ZodLiteral",(e,t)=>{p$.init(e,t),ze.init(e,t),e._zod.processJSONSchema=(i,l,n)=>PE(e,i,l),e.values=new Set(t.values),Object.defineProperty(e,"value",{get(){if(t.values.length>1)throw new Error("This schema contains multiple valid literal values. Use `.values` instead.");return t.values[0]}})});function $4(e,t){return new Bg({type:"literal",values:Array.isArray(e)?e:[e],...re(t)})}const Hg=P("ZodFile",(e,t)=>{g$.init(e,t),ze.init(e,t),e._zod.processJSONSchema=(i,l,n)=>FE(e,i,l),e.min=(i,l)=>e.check(si(i,l)),e.max=(i,l)=>e.check(el(i,l)),e.mime=(i,l)=>e.check(mc(Array.isArray(i)?i:[i],l))});function E4(e){return yE(Hg,e)}const Gg=P("ZodTransform",(e,t)=>{v$.init(e,t),ze.init(e,t),e._zod.processJSONSchema=(i,l,n)=>VE(e,i),e._zod.parse=(i,l)=>{if(l.direction==="backward")throw new Ws(e.constructor.name);i.addIssue=o=>{if(typeof o=="string")i.issues.push(Fa(o,i.value,t));else{const s=o;s.fatal&&(s.continue=!1),s.code??(s.code="custom"),s.input??(s.input=i.value),s.inst??(s.inst=e),i.issues.push(Fa(s))}};const n=t.transform(i.value,i);return n instanceof Promise?n.then(o=>(i.value=o,i)):(i.value=n,i)}});function Zc(e){return new Gg({type:"transform",transform:e})}const qc=P("ZodOptional",(e,t)=>{Gp.init(e,t),ze.init(e,t),e._zod.processJSONSchema=(i,l,n)=>_g(e,i,l,n),e.unwrap=()=>e._zod.def.innerType});function go(e){return new qc({type:"optional",innerType:e})}const Vg=P("ZodExactOptional",(e,t)=>{y$.init(e,t),ze.init(e,t),e._zod.processJSONSchema=(i,l,n)=>_g(e,i,l,n),e.unwrap=()=>e._zod.def.innerType});function Yg(e){return new Vg({type:"optional",innerType:e})}const Jg=P("ZodNullable",(e,t)=>{b$.init(e,t),ze.init(e,t),e._zod.processJSONSchema=(i,l,n)=>tj(e,i,l,n),e.unwrap=()=>e._zod.def.innerType});function vo(e){return new Jg({type:"nullable",innerType:e})}function j4(e){return go(vo(e))}const Xg=P("ZodDefault",(e,t)=>{x$.init(e,t),ze.init(e,t),e._zod.processJSONSchema=(i,l,n)=>rj(e,i,l,n),e.unwrap=()=>e._zod.def.innerType,e.removeDefault=e.unwrap});function Qg(e,t){return new Xg({type:"default",innerType:e,get defaultValue(){return typeof t=="function"?t():nc(t)}})}const Kg=P("ZodPrefault",(e,t)=>{_$.init(e,t),ze.init(e,t),e._zod.processJSONSchema=(i,l,n)=>ij(e,i,l,n),e.unwrap=()=>e._zod.def.innerType});function Wg(e,t){return new Kg({type:"prefault",innerType:e,get defaultValue(){return typeof t=="function"?t():nc(t)}})}const Fc=P("ZodNonOptional",(e,t)=>{S$.init(e,t),ze.init(e,t),e._zod.processJSONSchema=(i,l,n)=>nj(e,i,l,n),e.unwrap=()=>e._zod.def.innerType});function ev(e,t){return new Fc({type:"nonoptional",innerType:e,...re(t)})}const tv=P("ZodSuccess",(e,t)=>{k$.init(e,t),ze.init(e,t),e._zod.processJSONSchema=(i,l,n)=>BE(e,i,l),e.unwrap=()=>e._zod.def.innerType});function z4(e){return new tv({type:"success",innerType:e})}const nv=P("ZodCatch",(e,t)=>{w$.init(e,t),ze.init(e,t),e._zod.processJSONSchema=(i,l,n)=>aj(e,i,l,n),e.unwrap=()=>e._zod.def.innerType,e.removeCatch=e.unwrap});function rv(e,t){return new nv({type:"catch",innerType:e,catchValue:typeof t=="function"?t:()=>t})}const iv=P("ZodNaN",(e,t)=>{$$.init(e,t),ze.init(e,t),e._zod.processJSONSchema=(i,l,n)=>ZE(e,i)});function N4(e){return gE(iv,e)}const Bc=P("ZodPipe",(e,t)=>{E$.init(e,t),ze.init(e,t),e._zod.processJSONSchema=(i,l,n)=>lj(e,i,l,n),e.in=t.in,e.out=t.out});function yo(e,t){return new Bc({type:"pipe",in:e,out:t})}const Hc=P("ZodCodec",(e,t)=>{Bc.init(e,t),Vp.init(e,t)});function O4(e,t,i){return new Hc({type:"pipe",in:e,out:t,transform:i.decode,reverseTransform:i.encode})}const av=P("ZodReadonly",(e,t)=>{j$.init(e,t),ze.init(e,t),e._zod.processJSONSchema=(i,l,n)=>oj(e,i,l,n),e.unwrap=()=>e._zod.def.innerType});function lv(e){return new av({type:"readonly",innerType:e})}const ov=P("ZodTemplateLiteral",(e,t)=>{z$.init(e,t),ze.init(e,t),e._zod.processJSONSchema=(i,l,n)=>qE(e,i,l)});function T4(e,t){return new ov({type:"template_literal",parts:e,...re(t)})}const uv=P("ZodLazy",(e,t)=>{T$.init(e,t),ze.init(e,t),e._zod.processJSONSchema=(i,l,n)=>sj(e,i,l,n),e.unwrap=()=>e._zod.def.getter()});function sv(e){return new uv({type:"lazy",getter:e})}const cv=P("ZodPromise",(e,t)=>{O$.init(e,t),ze.init(e,t),e._zod.processJSONSchema=(i,l,n)=>uj(e,i,l,n),e.unwrap=()=>e._zod.def.innerType});function C4(e){return new cv({type:"promise",innerType:e})}const fv=P("ZodFunction",(e,t)=>{N$.init(e,t),ze.init(e,t),e._zod.processJSONSchema=(i,l,n)=>GE(e,i)});function Bs(e){return new fv({type:"function",input:Array.isArray(e?.input)?Zg(e?.input):e?.input??Bi(Pi()),output:e?.output??Pi()})}const Jo=P("ZodCustom",(e,t)=>{C$.init(e,t),ze.init(e,t),e._zod.processJSONSchema=(i,l,n)=>HE(e,i)});function D4(e){const t=new st({check:"custom"});return t._zod.check=e,t}function A4(e,t){return bE(Jo,e??(()=>!0),t)}function dv(e,t={}){return xE(Jo,e,t)}function mv(e){return _E(e)}const R4=kE,I4=wE;function U4(e,t={}){const i=new Jo({type:"custom",check:"custom",fn:l=>l instanceof e,abort:!0,...re(t)});return i._zod.bag.Class=e,i._zod.check=l=>{l.value instanceof e||l.issues.push({code:"invalid_type",expected:e.name,input:l.value,inst:i,path:[...i._zod.def.path??[]]})},i}const L4=(...e)=>$E({Codec:Hc,Boolean:Bo,String:Zo},...e);function M4(e){const t=sv(()=>Mc([je(e),jt(),jr(),Og(),Bi(t),Pc(je(),t)]));return t}function P4(e,t){return yo(Zc(e),t)}const pI=Object.freeze(Object.defineProperty({__proto__:null,ZodAny:Tg,ZodArray:Rg,ZodBase64:Cc,ZodBase64URL:Dc,ZodBigInt:Ho,ZodBigIntFormat:Ic,ZodBoolean:Bo,ZodCIDRv4:Oc,ZodCIDRv6:Tc,ZodCUID:kc,ZodCUID2:wc,ZodCatch:nv,ZodCodec:Hc,ZodCustom:Jo,ZodCustomStringFormat:tl,ZodDate:Lc,ZodDefault:Xg,ZodDiscriminatedUnion:Ug,ZodE164:Ac,ZodEmail:xc,ZodEmoji:_c,ZodEnum:Ja,ZodExactOptional:Vg,ZodFile:Hg,ZodFunction:fv,ZodGUID:po,ZodIPv4:zc,ZodIPv6:Nc,ZodIntersection:Lg,ZodJWT:Rc,ZodKSUID:jc,ZodLazy:uv,ZodLiteral:Bg,ZodMAC:Eg,ZodMap:qg,ZodNaN:iv,ZodNanoID:Sc,ZodNever:Dg,ZodNonOptional:Fc,ZodNull:Ng,ZodNullable:Jg,ZodNumber:Fo,ZodNumberFormat:Fi,ZodObject:Go,ZodOptional:qc,ZodPipe:Bc,ZodPrefault:Kg,ZodPromise:cv,ZodReadonly:av,ZodRecord:Yo,ZodSet:Fg,ZodString:Zo,ZodStringFormat:nt,ZodSuccess:tv,ZodSymbol:jg,ZodTemplateLiteral:ov,ZodTransform:Gg,ZodTuple:Pg,ZodType:ze,ZodULID:$c,ZodURL:qo,ZodUUID:Kn,ZodUndefined:zg,ZodUnion:Vo,ZodUnknown:Cg,ZodVoid:Ag,ZodXID:Ec,ZodXor:Ig,_ZodString:bc,_default:Qg,_function:Bs,any:d4,array:Bi,base64:Jj,base64url:Xj,bigint:o4,boolean:jr,catch:rv,check:D4,cidrv4:Vj,cidrv6:Yj,codec:O4,cuid:Mj,cuid2:Pj,custom:A4,date:h4,describe:R4,discriminatedUnion:b4,e164:Qj,email:Nj,emoji:Uj,enum:Fn,exactOptional:Yg,file:E4,float32:r4,float64:i4,function:Bs,guid:Oj,hash:n4,hex:t4,hostname:e4,httpUrl:Ij,instanceof:U4,int:Fs,int32:a4,int64:u4,intersection:Mg,ipv4:Bj,ipv6:Gj,json:M4,jwt:Kj,keyof:p4,ksuid:Fj,lazy:sv,literal:$4,looseObject:v4,looseRecord:_4,mac:Hj,map:S4,meta:I4,nan:N4,nanoid:Lj,nativeEnum:w4,never:Uc,nonoptional:ev,null:Og,nullable:vo,nullish:j4,number:jt,object:pt,optional:go,partialRecord:x4,pipe:yo,prefault:Wg,preprocess:P4,promise:C4,readonly:lv,record:Pc,refine:dv,set:k4,strictObject:g4,string:je,stringFormat:Wj,stringbool:L4,success:z4,superRefine:mv,symbol:c4,templateLiteral:T4,transform:Zc,tuple:Zg,uint32:l4,uint64:s4,ulid:Zj,undefined:f4,union:Mc,unknown:Pi,url:Rj,uuid:Tj,uuidv4:Cj,uuidv6:Dj,uuidv7:Aj,void:m4,xid:qj,xor:y4},Symbol.toStringTag,{value:"Module"})),gI={invalid_type:"invalid_type",too_big:"too_big",too_small:"too_small",invalid_format:"invalid_format",not_multiple_of:"not_multiple_of",unrecognized_keys:"unrecognized_keys",invalid_union:"invalid_union",invalid_key:"invalid_key",invalid_element:"invalid_element",invalid_value:"invalid_value",custom:"custom"};function vI(e){It({customError:e})}function yI(){return It().customError}var ep;ep||(ep={});const fe={...pI,...mI,iso:pj},bI=new Set(["$schema","$ref","$defs","definitions","$id","id","$comment","$anchor","$vocabulary","$dynamicRef","$dynamicAnchor","type","enum","const","anyOf","oneOf","allOf","not","properties","required","additionalProperties","patternProperties","propertyNames","minProperties","maxProperties","items","prefixItems","additionalItems","minItems","maxItems","uniqueItems","contains","minContains","maxContains","minLength","maxLength","pattern","format","minimum","maximum","exclusiveMinimum","exclusiveMaximum","multipleOf","description","default","contentEncoding","contentMediaType","contentSchema","unevaluatedItems","unevaluatedProperties","if","then","else","dependentSchemas","dependentRequired","nullable","readOnly"]);function xI(e,t){const i=e.$schema;return i==="https://json-schema.org/draft/2020-12/schema"?"draft-2020-12":i==="http://json-schema.org/draft-07/schema#"?"draft-7":i==="http://json-schema.org/draft-04/schema#"?"draft-4":t??"draft-2020-12"}function _I(e,t){if(!e.startsWith("#"))throw new Error("External $ref is not supported, only local refs (#/...) are allowed");const i=e.slice(1).split("/").filter(Boolean);if(i.length===0)return t.rootSchema;const l=t.version==="draft-2020-12"?"$defs":"definitions";if(i[0]===l){const n=i[1];if(!n||!t.defs[n])throw new Error(`Reference not found: ${e}`);return t.defs[n]}throw new Error(`Reference not found: ${e}`)}function Z4(e,t){if(e.not!==void 0){if(typeof e.not=="object"&&Object.keys(e.not).length===0)return fe.never();throw new Error("not is not supported in Zod (except { not: {} } for never)")}if(e.unevaluatedItems!==void 0)throw new Error("unevaluatedItems is not supported");if(e.unevaluatedProperties!==void 0)throw new Error("unevaluatedProperties is not supported");if(e.if!==void 0||e.then!==void 0||e.else!==void 0)throw new Error("Conditional schemas (if/then/else) are not supported");if(e.dependentSchemas!==void 0||e.dependentRequired!==void 0)throw new Error("dependentSchemas and dependentRequired are not supported");if(e.$ref){const n=e.$ref;if(t.refs.has(n))return t.refs.get(n);if(t.processing.has(n))return fe.lazy(()=>{if(!t.refs.has(n))throw new Error(`Circular reference not resolved: ${n}`);return t.refs.get(n)});t.processing.add(n);const o=_I(n,t),s=At(o,t);return t.refs.set(n,s),t.processing.delete(n),s}if(e.enum!==void 0){const n=e.enum;if(t.version==="openapi-3.0"&&e.nullable===!0&&n.length===1&&n[0]===null)return fe.null();if(n.length===0)return fe.never();if(n.length===1)return fe.literal(n[0]);if(n.every(s=>typeof s=="string"))return fe.enum(n);const o=n.map(s=>fe.literal(s));return o.length<2?o[0]:fe.union([o[0],o[1],...o.slice(2)])}if(e.const!==void 0)return fe.literal(e.const);const i=e.type;if(Array.isArray(i)){const n=i.map(o=>{const s={...e,type:o};return Z4(s,t)});return n.length===0?fe.never():n.length===1?n[0]:fe.union(n)}if(!i)return fe.any();let l;switch(i){case"string":{let n=fe.string();if(e.format){const o=e.format;o==="email"?n=n.check(fe.email()):o==="uri"||o==="uri-reference"?n=n.check(fe.url()):o==="uuid"||o==="guid"?n=n.check(fe.uuid()):o==="date-time"?n=n.check(fe.iso.datetime()):o==="date"?n=n.check(fe.iso.date()):o==="time"?n=n.check(fe.iso.time()):o==="duration"?n=n.check(fe.iso.duration()):o==="ipv4"?n=n.check(fe.ipv4()):o==="ipv6"?n=n.check(fe.ipv6()):o==="mac"?n=n.check(fe.mac()):o==="cidr"?n=n.check(fe.cidrv4()):o==="cidr-v6"?n=n.check(fe.cidrv6()):o==="base64"?n=n.check(fe.base64()):o==="base64url"?n=n.check(fe.base64url()):o==="e164"?n=n.check(fe.e164()):o==="jwt"?n=n.check(fe.jwt()):o==="emoji"?n=n.check(fe.emoji()):o==="nanoid"?n=n.check(fe.nanoid()):o==="cuid"?n=n.check(fe.cuid()):o==="cuid2"?n=n.check(fe.cuid2()):o==="ulid"?n=n.check(fe.ulid()):o==="xid"?n=n.check(fe.xid()):o==="ksuid"&&(n=n.check(fe.ksuid()))}typeof e.minLength=="number"&&(n=n.min(e.minLength)),typeof e.maxLength=="number"&&(n=n.max(e.maxLength)),e.pattern&&(n=n.regex(new RegExp(e.pattern))),l=n;break}case"number":case"integer":{let n=i==="integer"?fe.number().int():fe.number();typeof e.minimum=="number"&&(n=n.min(e.minimum)),typeof e.maximum=="number"&&(n=n.max(e.maximum)),typeof e.exclusiveMinimum=="number"?n=n.gt(e.exclusiveMinimum):e.exclusiveMinimum===!0&&typeof e.minimum=="number"&&(n=n.gt(e.minimum)),typeof e.exclusiveMaximum=="number"?n=n.lt(e.exclusiveMaximum):e.exclusiveMaximum===!0&&typeof e.maximum=="number"&&(n=n.lt(e.maximum)),typeof e.multipleOf=="number"&&(n=n.multipleOf(e.multipleOf)),l=n;break}case"boolean":{l=fe.boolean();break}case"null":{l=fe.null();break}case"object":{const n={},o=e.properties||{},s=new Set(e.required||[]);for(const[m,d]of Object.entries(o)){const p=At(d,t);n[m]=s.has(m)?p:p.optional()}if(e.propertyNames){const m=At(e.propertyNames,t),d=e.additionalProperties&&typeof e.additionalProperties=="object"?At(e.additionalProperties,t):fe.any();if(Object.keys(n).length===0){l=fe.record(m,d);break}const p=fe.object(n).passthrough(),v=fe.looseRecord(m,d);l=fe.intersection(p,v);break}if(e.patternProperties){const m=e.patternProperties,d=Object.keys(m),p=[];for(const b of d){const x=At(m[b],t),S=fe.string().regex(new RegExp(b));p.push(fe.looseRecord(S,x))}const v=[];if(Object.keys(n).length>0&&v.push(fe.object(n).passthrough()),v.push(...p),v.length===0)l=fe.object({}).passthrough();else if(v.length===1)l=v[0];else{let b=fe.intersection(v[0],v[1]);for(let x=2;x<v.length;x++)b=fe.intersection(b,v[x]);l=b}break}const f=fe.object(n);e.additionalProperties===!1?l=f.strict():typeof e.additionalProperties=="object"?l=f.catchall(At(e.additionalProperties,t)):l=f.passthrough();break}case"array":{const n=e.prefixItems,o=e.items;if(n&&Array.isArray(n)){const s=n.map(m=>At(m,t)),f=o&&typeof o=="object"&&!Array.isArray(o)?At(o,t):void 0;f?l=fe.tuple(s).rest(f):l=fe.tuple(s),typeof e.minItems=="number"&&(l=l.check(fe.minLength(e.minItems))),typeof e.maxItems=="number"&&(l=l.check(fe.maxLength(e.maxItems)))}else if(Array.isArray(o)){const s=o.map(m=>At(m,t)),f=e.additionalItems&&typeof e.additionalItems=="object"?At(e.additionalItems,t):void 0;f?l=fe.tuple(s).rest(f):l=fe.tuple(s),typeof e.minItems=="number"&&(l=l.check(fe.minLength(e.minItems))),typeof e.maxItems=="number"&&(l=l.check(fe.maxLength(e.maxItems)))}else if(o!==void 0){const s=At(o,t);let f=fe.array(s);typeof e.minItems=="number"&&(f=f.min(e.minItems)),typeof e.maxItems=="number"&&(f=f.max(e.maxItems)),l=f}else l=fe.array(fe.any());break}default:throw new Error(`Unsupported type: ${i}`)}return e.description&&(l=l.describe(e.description)),e.default!==void 0&&(l=l.default(e.default)),l}function At(e,t){if(typeof e=="boolean")return e?fe.any():fe.never();let i=Z4(e,t);const l=e.type||e.enum!==void 0||e.const!==void 0;if(e.anyOf&&Array.isArray(e.anyOf)){const f=e.anyOf.map(d=>At(d,t)),m=fe.union(f);i=l?fe.intersection(i,m):m}if(e.oneOf&&Array.isArray(e.oneOf)){const f=e.oneOf.map(d=>At(d,t)),m=fe.xor(f);i=l?fe.intersection(i,m):m}if(e.allOf&&Array.isArray(e.allOf))if(e.allOf.length===0)i=l?i:fe.any();else{let f=l?i:At(e.allOf[0],t);const m=l?0:1;for(let d=m;d<e.allOf.length;d++)f=fe.intersection(f,At(e.allOf[d],t));i=f}e.nullable===!0&&t.version==="openapi-3.0"&&(i=fe.nullable(i)),e.readOnly===!0&&(i=fe.readonly(i));const n={},o=["$id","id","$comment","$anchor","$vocabulary","$dynamicRef","$dynamicAnchor"];for(const f of o)f in e&&(n[f]=e[f]);const s=["contentEncoding","contentMediaType","contentSchema"];for(const f of s)f in e&&(n[f]=e[f]);for(const f of Object.keys(e))bI.has(f)||(n[f]=e[f]);return Object.keys(n).length>0&&t.registry.add(i,n),i}function SI(e,t){if(typeof e=="boolean")return e?fe.any():fe.never();const i=xI(e,t?.defaultTarget),l=e.$defs||e.definitions||{},n={version:i,defs:l,refs:new Map,processing:new Set,rootSchema:e,registry:t?.registry??Nn};return At(e,n)}function kI(e){return Z$(Zo,e)}function wI(e){return J$(Fo,e)}function $I(e){return nE(Bo,e)}function EI(e){return iE(Ho,e)}function jI(e){return pE(Lc,e)}const zI=Object.freeze(Object.defineProperty({__proto__:null,bigint:EI,boolean:$I,date:jI,number:wI,string:kI},Symbol.toStringTag,{value:"Module"}));It(D$());const NI=Object.freeze(Object.defineProperty({__proto__:null,$brand:JS,$input:L$,$output:U$,NEVER:YS,TimePrecision:F$,ZodAny:Tg,ZodArray:Rg,ZodBase64:Cc,ZodBase64URL:Dc,ZodBigInt:Ho,ZodBigIntFormat:Ic,ZodBoolean:Bo,ZodCIDRv4:Oc,ZodCIDRv6:Tc,ZodCUID:kc,ZodCUID2:wc,ZodCatch:nv,ZodCodec:Hc,ZodCustom:Jo,ZodCustomStringFormat:tl,ZodDate:Lc,ZodDefault:Xg,ZodDiscriminatedUnion:Ug,ZodE164:Ac,ZodEmail:xc,ZodEmoji:_c,ZodEnum:Ja,ZodError:hI,ZodExactOptional:Vg,ZodFile:Hg,get ZodFirstPartyTypeKind(){return ep},ZodFunction:fv,ZodGUID:po,ZodIPv4:zc,ZodIPv6:Nc,ZodISODate:kg,ZodISODateTime:Sg,ZodISODuration:$g,ZodISOTime:wg,ZodIntersection:Lg,ZodIssueCode:gI,ZodJWT:Rc,ZodKSUID:jc,ZodLazy:uv,ZodLiteral:Bg,ZodMAC:Eg,ZodMap:qg,ZodNaN:iv,ZodNanoID:Sc,ZodNever:Dg,ZodNonOptional:Fc,ZodNull:Ng,ZodNullable:Jg,ZodNumber:Fo,ZodNumberFormat:Fi,ZodObject:Go,ZodOptional:qc,ZodPipe:Bc,ZodPrefault:Kg,ZodPromise:cv,ZodReadonly:av,ZodRealError:pn,ZodRecord:Yo,ZodSet:Fg,ZodString:Zo,ZodStringFormat:nt,ZodSuccess:tv,ZodSymbol:jg,ZodTemplateLiteral:ov,ZodTransform:Gg,ZodTuple:Pg,ZodType:ze,ZodULID:$c,ZodURL:qo,ZodUUID:Kn,ZodUndefined:zg,ZodUnion:Vo,ZodUnknown:Cg,ZodVoid:Ag,ZodXID:Ec,ZodXor:Ig,_ZodString:bc,_default:Qg,_function:Bs,any:d4,array:Bi,base64:Jj,base64url:Xj,bigint:o4,boolean:jr,catch:rv,check:D4,cidrv4:Vj,cidrv6:Yj,clone:Rn,codec:O4,coerce:zI,config:It,core:dI,cuid:Mj,cuid2:Pj,custom:A4,date:h4,decode:Sj,decodeAsync:wj,describe:R4,discriminatedUnion:b4,e164:Qj,email:Nj,emoji:Uj,encode:_j,encodeAsync:kj,endsWith:dc,enum:Fn,exactOptional:Yg,file:E4,flattenError:Ep,float32:r4,float64:i4,formatError:jp,fromJSONSchema:SI,function:Bs,getErrorMap:yI,globalRegistry:Nn,gt:ui,gte:en,guid:Oj,hash:n4,hex:t4,hostname:e4,httpUrl:Ij,includes:cc,instanceof:U4,int:Fs,int32:a4,int64:u4,intersection:Mg,ipv4:Bj,ipv6:Gj,iso:pj,json:M4,jwt:Kj,keyof:p4,ksuid:Fj,lazy:sv,length:Mo,literal:$4,locales:I$,looseObject:v4,looseRecord:_4,lowercase:uc,lt:oi,lte:On,mac:Hj,map:S4,maxLength:Lo,maxSize:el,meta:I4,mime:mc,minLength:Mi,minSize:si,multipleOf:Ha,nan:N4,nanoid:Lj,nativeEnum:w4,negative:gg,never:Uc,nonnegative:yg,nonoptional:ev,nonpositive:vg,normalize:hc,null:Og,nullable:vo,nullish:j4,number:jt,object:pt,optional:go,overwrite:Or,parse:vj,parseAsync:yj,partialRecord:x4,pipe:yo,positive:pg,prefault:Wg,preprocess:P4,prettifyError:gk,promise:C4,property:bg,readonly:lv,record:Pc,refine:dv,regex:oc,regexes:Lp,registry:Yp,safeDecode:Ej,safeDecodeAsync:zj,safeEncode:$j,safeEncodeAsync:jj,safeParse:bj,safeParseAsync:xj,set:k4,setErrorMap:vI,size:Uo,slugify:yc,startsWith:fc,strictObject:g4,string:je,stringFormat:Wj,stringbool:L4,success:z4,superRefine:mv,symbol:c4,templateLiteral:T4,toJSONSchema:cj,toLowerCase:gc,toUpperCase:vc,transform:Zc,treeifyError:hk,trim:pc,tuple:Zg,uint32:l4,uint64:s4,ulid:Zj,undefined:f4,union:Mc,unknown:Pi,uppercase:sc,url:Rj,util:dk,uuid:Tj,uuidv4:Cj,uuidv6:Dj,uuidv7:Aj,void:m4,xid:qj,xor:y4},Symbol.toStringTag,{value:"Module"}));nD(NI);const q4=Fn(["http_basic","github_token","gitlab_token","bitbucket_app_password","bitbucket_api_token","bitbucket_api_key","bitbucket_server_pat","bearer_token"]),F4=Fn(["git","composer","artifact"]),OI=pt({url:je().url("Invalid repository URL"),vcs_type:F4,credential_type:q4,auth_credentials:Pc(je(),je()).refine(e=>Object.keys(e).length>0,"At least one credential field is required"),composer_json_path:je().optional(),package_filter:je().optional()});OI.partial();pt({id:je(),url:je(),vcs_type:F4,credential_type:q4,composer_json_path:je().nullable(),package_filter:je().nullable(),status:Fn(["pending","active","error","syncing"]),error_message:je().nullable(),last_synced_at:jt().nullable(),created_at:jt()});const B4=Fn(["readonly","write"]);pt({description:je().min(1,"Description is required"),permissions:B4.default("readonly"),rate_limit_max:jt().int().min(0).max(25e3,"Rate limit cannot exceed 25,000 requests/hour").nullable().default(1e3),expires_at:jt().int().positive().optional()});pt({description:je().min(1,"Description is required").optional(),rate_limit_max:jt().int().min(0).max(25e3,"Rate limit cannot exceed 25,000 requests/hour").nullable().optional()});const TI=pt({id:je(),description:je(),permissions:B4,rate_limit_max:jt().nullable(),created_at:jt(),expires_at:jt().nullable(),last_used_at:jt().nullable()});pt({email:je().email("Invalid email address"),password:je().min(1,"Password is required"),code:je().optional()});pt({token:je(),user:pt({id:je(),email:je(),role:Fn(["admin","viewer"]),two_factor_enabled:jr()})});const H4=pt({id:je(),email:je(),role:Fn(["admin","viewer"]),two_factor_enabled:jr()});pt({users:Bi(H4)});pt({email:je().email("Invalid email address"),password:je().optional(),role:Fn(["admin","viewer"]).default("viewer")});pt({message:je(),user:H4});pt({error:je(),message:je().optional(),code:je().optional(),requestId:je().optional()});pt({status:je(),timestamp:jt()});pt({active_repos:jt(),cached_packages:jt(),total_downloads:jt()});pt({kv_available:jr(),packagist_mirroring_enabled:jr(),package_caching_enabled:jr()});pt({enabled:jr()});const CI=pt({id:je(),name:je(),version:je(),repo_id:je(),dist_url:je().nullable(),source_dist_url:je().nullable(),released_at:jt().nullable(),created_at:jt()});pt({name:je(),versions:Bi(CI)});TI.extend({token:je()});const G4=C.createContext(void 0),Nm="composer_proxy_admin_token";function DI({children:e}){const[t,i]=C.useState(()=>typeof window<"u"?localStorage.getItem(Nm):null),[l,n]=C.useState(null),[o,s]=C.useState(null);C.useEffect(()=>{t?fetch("/api/auth/me",{headers:{Authorization:`Bearer ${t}`}}).then(v=>{if(v.ok)return v.json();throw new Error("Failed to fetch user")}).then(v=>n(v.user)).catch(v=>{console.error("AuthContext: Failed to fetch user",v),s(v.message||"Unknown auth error"),m()}):n(null)},[t]);const f=v=>{i(v),localStorage.setItem(Nm,v),s(null)},m=()=>{i(null),n(null),localStorage.removeItem(Nm)},d=t!==null&&t.length>0,p=l?.role==="admin";return y.jsx(G4.Provider,{value:{adminToken:t,isAuthenticated:d,user:l,isAdmin:p,login:f,logout:m,authError:o},children:e})}function nl(){const e=C.useContext(G4);if(e===void 0)throw new Error("useAuth must be used within an AuthProvider");return e}function AI(){const[e,t]=C.useState(!1),[i,l]=C.useState(null),n=qn(),{data:o=[],isLoading:s}=dn({queryKey:["repositories"],queryFn:GS}),{data:f}=dn({queryKey:["settings"],queryFn:Ks}),m=f?.packagist_mirroring_enabled??!0,d=o.filter(S=>S.id!=="packagist"||m),p=Cn({mutationFn:NC,onSuccess:()=>{n.invalidateQueries({queryKey:["repositories"]})}}),v=Cn({mutationFn:OC,onSuccess:()=>{n.invalidateQueries({queryKey:["repositories"]})}}),b=S=>{const w={active:"bg-emerald-500/20 text-emerald-400 border-emerald-500/30",error:"bg-red-500/20 text-red-400 border-red-500/30",pending:"bg-yellow-500/20 text-yellow-400 border-yellow-500/30",syncing:"bg-blue-500/20 text-blue-400 border-blue-500/30"};return y.jsx("span",{className:`px-2 py-1 text-xs font-medium rounded-full border ${w[S]}`,children:S})},{isAdmin:x}=nl();return y.jsxs("div",{className:"space-y-8","data-testid":"repositories-page",children:[y.jsxs("div",{className:"flex items-center justify-between",children:[y.jsxs("div",{children:[y.jsx("h2",{className:"font-display text-2xl font-bold text-slate-100 mb-2","data-testid":"repositories-heading",children:"Repositories"}),y.jsx("p",{className:"text-slate-400",children:"Manage your package sources. Packages are loaded on-demand when requested."})]}),x&&y.jsx("button",{onClick:()=>t(!0),className:"btn-primary","data-testid":"add-repository-button","aria-label":"Add new repository",children:"+ Add Repository"})]}),y.jsx("div",{className:"card overflow-hidden",children:s?y.jsx("div",{className:"p-8 text-center",children:y.jsx("div",{className:"w-8 h-8 border-2 border-slate-600 border-t-primary-500 rounded-full animate-spin mx-auto"})}):d.length===0?y.jsxs("div",{className:"p-8 text-center text-slate-400",children:["No repositories configured yet. ",x?"Add your first repository to get started.":"Ask an admin to configure repositories."]}):y.jsxs("table",{className:"w-full",children:[y.jsx("thead",{className:"bg-slate-800/50 border-b border-slate-700",children:y.jsxs("tr",{children:[y.jsx("th",{className:"px-6 py-3 text-left text-xs font-medium text-slate-400 uppercase tracking-wider",children:"URL"}),y.jsx("th",{className:"px-6 py-3 text-left text-xs font-medium text-slate-400 uppercase tracking-wider",children:"Type"}),y.jsx("th",{className:"px-6 py-3 text-left text-xs font-medium text-slate-400 uppercase tracking-wider",children:"Status"}),y.jsx("th",{className:"px-6 py-3 text-left text-xs font-medium text-slate-400 uppercase tracking-wider",children:"Last Tested"}),x&&y.jsx("th",{className:"px-6 py-3 text-right text-xs font-medium text-slate-400 uppercase tracking-wider",children:"Actions"})]})}),y.jsx("tbody",{className:"divide-y divide-slate-800",children:d.map(S=>{const w=S.id==="packagist";return y.jsxs("tr",{className:"hover:bg-slate-800/30",children:[y.jsxs("td",{className:"px-6 py-4",children:[y.jsxs("div",{className:"text-sm text-slate-200 font-medium truncate max-w-xs",children:[S.url,w&&y.jsx("span",{className:"ml-2 text-xs text-slate-500",children:"(Public Packagist)"})]}),S.error_message&&y.jsx("div",{className:"text-xs text-red-400 mt-1",children:S.error_message})]}),y.jsxs("td",{className:"px-6 py-4 text-sm text-slate-400",children:[S.vcs_type," / ",S.credential_type]}),y.jsx("td",{className:"px-6 py-4",children:b(S.status)}),y.jsx("td",{className:"px-6 py-4 text-sm text-slate-400",children:S.last_synced_at?new Date(S.last_synced_at*1e3).toLocaleString():"Never"}),x&&y.jsxs("td",{className:"px-6 py-4 text-right space-x-3",children:[!w&&y.jsxs(y.Fragment,{children:[y.jsx("button",{onClick:()=>v.mutate(S.id),disabled:v.isPending||S.status==="syncing",className:"text-primary-400 hover:text-primary-300 text-sm disabled:opacity-50",title:"Test connection and validate credentials. Packages are loaded on-demand when requested.",children:S.status==="syncing"?"Testing...":"Test"}),y.jsx("button",{onClick:()=>l(S),className:"text-slate-400 hover:text-slate-200 text-sm",children:"Edit"}),y.jsx("button",{onClick:()=>{confirm("Delete this repository?")&&p.mutate(S.id)},className:"text-red-400 hover:text-red-300 text-sm",children:"Delete"})]}),w&&y.jsx("span",{className:"text-xs text-slate-500 italic",children:"Managed by system"})]})]},S.id)})})]})}),y.jsx(UI,{}),e&&y.jsx(RI,{onClose:()=>t(!1)}),i&&y.jsx(II,{repository:i,onClose:()=>l(null)})]})}function RI({onClose:e}){const[t,i]=C.useState(""),[l,n]=C.useState("composer"),[o,s]=C.useState("http_basic"),[f,m]=C.useState({}),[d,p]=C.useState(""),[v,b]=C.useState(""),x=qn(),S=Cn({mutationFn:jC,onSuccess:()=>{x.invalidateQueries({queryKey:["repositories"]}),e()}}),w=Us[l]||[],j=Is[o]?.fields||[],E=N=>{n(N);const G=Us[N]||[];G.length>0&&!G.includes(o)&&(s(G[0]),m({}))},O=N=>{N.preventDefault(),S.mutate({url:t,vcs_type:l,credential_type:o,auth_credentials:f,composer_json_path:d||void 0,package_filter:v||void 0})};return y.jsx("div",{className:"fixed inset-0 bg-black/50 backdrop-blur-sm flex items-center justify-center z-50",children:y.jsxs("div",{className:"card max-w-lg w-full mx-4 p-6",children:[y.jsxs("div",{className:"flex items-center justify-between mb-6",children:[y.jsx("h3",{className:"font-display text-xl font-bold text-slate-100",children:"Add Repository"}),y.jsx("button",{onClick:e,className:"text-slate-400 hover:text-slate-200",children:y.jsx(Ui,{className:"w-4 h-4"})})]}),y.jsxs("form",{onSubmit:O,className:"space-y-4",children:[y.jsxs("div",{children:[y.jsx("label",{className:"label",children:"Repository URL"}),y.jsx("input",{type:"url",value:t,onChange:N=>i(N.target.value),placeholder:"https://github.com/owner/repo or https://composer.example.com",className:"input w-full",required:!0})]}),y.jsxs("div",{className:"grid grid-cols-2 gap-4",children:[y.jsxs("div",{children:[y.jsx("label",{className:"label",children:"Source Type"}),y.jsxs("select",{value:l,onChange:N=>E(N.target.value),className:"input w-full",children:[y.jsx("option",{value:"composer",children:"Composer Repository"}),y.jsx("option",{value:"git",children:"Git Repository"})]})]}),y.jsxs("div",{children:[y.jsx("label",{className:"label",children:"Credential Type"}),y.jsx("select",{value:o,onChange:N=>{s(N.target.value),m({})},className:"input w-full",children:w.map(N=>y.jsx("option",{value:N,children:Is[N]?.label||N},N))})]})]}),j.map(N=>y.jsxs("div",{children:[y.jsx("label",{className:"label",children:N.label}),y.jsx("input",{type:N.type,value:f[N.name]||"",onChange:G=>m(J=>({...J,[N.name]:G.target.value})),className:"input w-full",required:!0})]},N.name)),l==="git"&&y.jsxs("div",{children:[y.jsx("label",{className:"label",children:"Composer.json Path (optional)"}),y.jsx("input",{type:"text",value:d,onChange:N=>p(N.target.value),placeholder:"**/composer.json",className:"input w-full"}),y.jsx("p",{className:"text-xs text-slate-500 mt-1",children:"Glob pattern to find composer.json files. Default: **/composer.json"})]}),l==="composer"&&y.jsxs("div",{children:[y.jsx("label",{className:"label",children:"Package Filter (optional)"}),y.jsx("input",{type:"text",value:v,onChange:N=>b(N.target.value),placeholder:"vendor/package1, vendor/package2",className:"input w-full"}),y.jsx("p",{className:"text-xs text-slate-500 mt-1",children:"Comma-separated list of packages to filter. Optional - leave empty to allow all packages. Packages are loaded on-demand when requested by Composer."})]}),y.jsxs("div",{className:"flex justify-end gap-3 pt-4",children:[y.jsx("button",{type:"button",onClick:e,className:"btn-secondary",children:"Cancel"}),y.jsx("button",{type:"submit",className:"btn-primary",disabled:S.isPending,children:S.isPending?"Adding...":"Add Repository"})]}),S.error&&y.jsx("p",{className:"text-red-400 text-sm",children:S.error.message})]})]})})}function II({repository:e,onClose:t}){const[i,l]=C.useState(e.url),[n,o]=C.useState(e.vcs_type),[s,f]=C.useState(e.credential_type),[m,d]=C.useState({}),[p,v]=C.useState(e.composer_json_path||""),[b,x]=C.useState(e.package_filter||""),S=qn(),w=Cn({mutationFn:G=>zC(e.id,G),onSuccess:()=>{S.invalidateQueries({queryKey:["repositories"]}),t()}}),j=Us[n]||[],E=Is[s]?.fields||[],O=G=>{o(G);const J=Us[G]||[];J.length>0&&!J.includes(s)&&(f(J[0]),d({}))},N=G=>{G.preventDefault();const J={};if(i!==e.url&&(J.url=i),n!==e.vcs_type&&(J.vcs_type=n),s!==e.credential_type&&(J.credential_type=s),Object.values(m).some(X=>X.trim()!=="")&&(J.auth_credentials=m),p!==(e.composer_json_path||"")&&(J.composer_json_path=p||void 0),b!==(e.package_filter||"")&&(J.package_filter=b||void 0),Object.keys(J).length===0){t();return}w.mutate(J)};return y.jsx("div",{className:"fixed inset-0 bg-black/50 backdrop-blur-sm flex items-center justify-center z-50",children:y.jsxs("div",{className:"card max-w-lg w-full mx-4 p-6",children:[y.jsxs("div",{className:"flex items-center justify-between mb-6",children:[y.jsx("h3",{className:"font-display text-xl font-bold text-slate-100",children:"Edit Repository"}),y.jsx("button",{onClick:t,className:"text-slate-400 hover:text-slate-200",children:y.jsx(Ui,{className:"w-4 h-4"})})]}),y.jsxs("form",{onSubmit:N,className:"space-y-4",children:[y.jsxs("div",{children:[y.jsx("label",{className:"label",children:"Repository URL"}),y.jsx("input",{type:"url",value:i,onChange:G=>l(G.target.value),placeholder:"https://github.com/owner/repo or https://composer.example.com",className:"input w-full",required:!0})]}),y.jsxs("div",{className:"grid grid-cols-2 gap-4",children:[y.jsxs("div",{children:[y.jsx("label",{className:"label",children:"Source Type"}),y.jsxs("select",{value:n,onChange:G=>O(G.target.value),className:"input w-full",children:[y.jsx("option",{value:"composer",children:"Composer Repository"}),y.jsx("option",{value:"git",children:"Git Repository"})]})]}),y.jsxs("div",{children:[y.jsx("label",{className:"label",children:"Credential Type"}),y.jsx("select",{value:s,onChange:G=>{f(G.target.value),d({})},className:"input w-full",children:j.map(G=>y.jsx("option",{value:G,children:Is[G]?.label||G},G))})]})]}),y.jsxs("div",{className:"space-y-4",children:[y.jsx("p",{className:"text-xs text-slate-500",children:"Leave credential fields empty to keep current values."}),E.map(G=>y.jsxs("div",{children:[y.jsx("label",{className:"label",children:G.label}),y.jsx("input",{type:G.type,value:m[G.name]||"",onChange:J=>d(R=>({...R,[G.name]:J.target.value})),placeholder:"Leave empty to keep current",className:"input w-full"})]},G.name))]}),n==="git"&&y.jsxs("div",{children:[y.jsx("label",{className:"label",children:"Composer.json Path (optional)"}),y.jsx("input",{type:"text",value:p,onChange:G=>v(G.target.value),placeholder:"**/composer.json",className:"input w-full"}),y.jsx("p",{className:"text-xs text-slate-500 mt-1",children:"Glob pattern to find composer.json files. Default: **/composer.json"})]}),n==="composer"&&y.jsxs("div",{children:[y.jsx("label",{className:"label",children:"Package Filter (optional)"}),y.jsx("input",{type:"text",value:b,onChange:G=>x(G.target.value),placeholder:"vendor/package1, vendor/package2",className:"input w-full"}),y.jsx("p",{className:"text-xs text-slate-500 mt-1",children:"Comma-separated list of packages to filter. Optional - leave empty to allow all packages. Packages are loaded on-demand when requested by Composer."})]}),y.jsxs("div",{className:"flex justify-end gap-3 pt-4",children:[y.jsx("button",{type:"button",onClick:t,className:"btn-secondary",children:"Cancel"}),y.jsx("button",{type:"submit",className:"btn-primary",disabled:w.isPending,children:w.isPending?"Saving...":"Save Changes"})]}),w.error&&y.jsx("p",{className:"text-red-400 text-sm",children:w.error.message})]})]})})}function UI(){const e=qn(),{isAdmin:t}=nl(),{data:i,isLoading:l}=dn({queryKey:["settings"],queryFn:Ks}),n=Cn({mutationFn:ZC,onSuccess:()=>{e.invalidateQueries({queryKey:["settings"]})}}),o=i?.packagist_mirroring_enabled??!0,s=()=>{t&&n.mutate(!o)};return y.jsxs("div",{className:"card p-6 mt-8",children:[y.jsxs("div",{className:"flex items-start justify-between",children:[y.jsxs("div",{className:"flex-1",children:[y.jsx("h3",{className:"font-display text-lg font-semibold text-slate-100 mb-2",children:"Public Packagist Mirroring"}),y.jsxs("p",{className:"text-slate-400 text-sm mb-4",children:["When enabled, packages not found in your private repositories will be proxied from"," ",y.jsx("a",{href:"https://packagist.org",target:"_blank",rel:"noopener noreferrer",className:"text-primary-400 hover:underline",children:"packagist.org"}),". This allows Composer to resolve public dependencies through this proxy."]}),y.jsxs("div",{className:"bg-slate-800/50 rounded-lg p-4 text-sm",children:[y.jsx("p",{className:"text-slate-300 mb-2",children:y.jsx("strong",{children:"When to disable:"})}),y.jsxs("ul",{className:"list-disc list-inside text-slate-400 space-y-1",children:[y.jsx("li",{children:"You're using Magento Marketplace or another private repository as your primary source"}),y.jsx("li",{children:"You want to ensure only private packages are served by this proxy"}),y.jsx("li",{children:"You have a separate Packagist mirror configured in your Composer"})]})]})]}),y.jsxs("div",{className:"ml-8 flex flex-col items-center",children:[y.jsx("button",{onClick:s,disabled:l||n.isPending||!t,className:`relative inline-flex h-7 w-14 flex-shrink-0 cursor-pointer rounded-full border-2 border-transparent transition-colors duration-200 ease-in-out focus:outline-none focus:ring-2 focus:ring-primary-500 focus:ring-offset-2 focus:ring-offset-slate-900 disabled:opacity-50 ${o?"bg-primary-600":"bg-slate-700"}`,role:"switch","aria-checked":o,children:y.jsx("span",{className:`pointer-events-none inline-block h-6 w-6 transform rounded-full bg-white shadow ring-0 transition duration-200 ease-in-out ${o?"translate-x-7":"translate-x-0"}`})}),y.jsx("span",{className:"mt-2 text-xs text-slate-500",children:l?"Loading...":o?"Enabled":"Disabled"})]})]}),n.isError&&y.jsxs("p",{className:"text-red-400 text-sm mt-4",children:["Failed to update setting: ",n.error.message]})]})}function LI(){const[e,t]=C.useState(!1),[i,l]=C.useState(null),n=qn(),{isAdmin:o}=nl(),{data:s=[],isLoading:f}=dn({queryKey:["tokens"],queryFn:TC}),{data:m,isLoading:d}=dn({queryKey:["settings"],queryFn:Ks}),p=m?.kv_available??!1,v=f||d,b=Cn({mutationFn:({id:S,data:w})=>DC(S,w),onSuccess:()=>{n.invalidateQueries({queryKey:["tokens"]})}}),x=Cn({mutationFn:AC,onSuccess:()=>{n.invalidateQueries({queryKey:["tokens"]})}});return y.jsxs("div",{className:"space-y-8","data-testid":"tokens-page",children:[y.jsxs("div",{className:"flex items-center justify-between",children:[y.jsxs("div",{children:[y.jsx("h2",{className:"font-display text-2xl font-bold text-slate-100 mb-2","data-testid":"tokens-heading",children:"Access Tokens"}),y.jsx("p",{className:"text-slate-400",children:"Manage tokens for Composer authentication"})]}),o&&y.jsx("button",{onClick:()=>t(!0),className:"btn-primary","data-testid":"generate-token-button","aria-label":"Generate new access token",children:"+ Generate Token"})]}),y.jsx("div",{className:"card overflow-hidden",children:v?y.jsx("div",{className:"p-8 text-center",children:y.jsx("div",{className:"w-8 h-8 border-2 border-slate-600 border-t-primary-500 rounded-full animate-spin mx-auto"})}):s.length===0?y.jsxs("div",{className:"p-8 text-center text-slate-400",children:["No tokens generated yet. ",o?"Create your first token to authenticate Composer.":"Ask an admin to generate tokens."]}):y.jsxs("table",{className:"w-full",children:[y.jsx("thead",{className:"bg-slate-800/50 border-b border-slate-700",children:y.jsxs("tr",{children:[y.jsx("th",{className:"px-6 py-3 text-left text-xs font-medium text-slate-400 uppercase tracking-wider",children:"Description"}),y.jsx("th",{className:"px-6 py-3 text-left text-xs font-medium text-slate-400 uppercase tracking-wider",children:"Permissions"}),y.jsx("th",{className:"px-6 py-3 text-left text-xs font-medium text-slate-400 uppercase tracking-wider",children:"Rate Limit"}),y.jsx("th",{className:"px-6 py-3 text-left text-xs font-medium text-slate-400 uppercase tracking-wider",children:"Created"}),y.jsx("th",{className:"px-6 py-3 text-left text-xs font-medium text-slate-400 uppercase tracking-wider",children:"Last Used"}),o&&y.jsx("th",{className:"px-6 py-3 text-right text-xs font-medium text-slate-400 uppercase tracking-wider",children:"Actions"})]})}),y.jsx("tbody",{className:"divide-y divide-slate-800",children:s.map(S=>y.jsx(MI,{token:S,onUpdate:w=>b.mutate({id:S.id,data:w}),onDelete:()=>{confirm("Revoke this token?")&&x.mutate(S.id)},isUpdating:b.isPending,kvAvailable:p,isAdmin:o},S.id))})]})}),e&&y.jsx(PI,{onClose:()=>{t(!1),l(null)},onCreated:S=>{l(S)},newToken:i,kvAvailable:p})]})}function MI({token:e,onUpdate:t,onDelete:i,isUpdating:l,kvAvailable:n,isAdmin:o}){const[s,f]=C.useState(!1),[m,d]=C.useState(e.description),p=!!e.rate_limit_max&&e.rate_limit_max>0,[v,b]=C.useState(n&&p),[x,S]=C.useState(p?String(e.rate_limit_max):""),w=()=>{const E=n&&v&&x!==""?parseInt(x,10):null;t({description:m,...n?{rate_limit_max:E===null||isNaN(E)?null:E}:{}}),f(!1)},j=()=>{const E=!!e.rate_limit_max&&e.rate_limit_max>0;d(e.description),b(n&&E),S(E?String(e.rate_limit_max):""),f(!1)};return y.jsxs("tr",{className:"hover:bg-slate-800/30",children:[y.jsx("td",{className:"px-6 py-4 text-sm text-slate-200 font-medium",children:s?y.jsx("input",{type:"text",value:m,onChange:E=>d(E.target.value),className:"input w-full text-sm",autoFocus:!0}):e.description}),y.jsx("td",{className:"px-6 py-4 text-sm text-slate-400",children:y.jsx("div",{className:"flex items-center gap-2",children:e.permissions==="readonly"?y.jsxs(y.Fragment,{children:[y.jsx(Qs,{className:"w-4 h-4"}),y.jsx("span",{children:"Read-only"})]}):y.jsxs(y.Fragment,{children:[y.jsx(kp,{className:"w-4 h-4"}),y.jsx("span",{children:"Write"})]})})}),y.jsx("td",{className:"px-6 py-4 text-sm text-slate-400",children:s?y.jsxs("div",{className:"space-y-2",children:[!n&&y.jsx("p",{className:"text-xs text-slate-500 italic",children:"Configure KV to enable rate limiting"}),y.jsxs("label",{className:"flex items-center gap-2 text-xs text-slate-300",children:[y.jsx("input",{type:"checkbox",checked:v,onChange:E=>{const O=E.target.checked;b(O),O&&x===""&&S("1000"),O||S("")},disabled:!n}),"Enabled"]}),y.jsx("input",{type:"number",value:x,onChange:E=>S(E.target.value),min:0,max:25e3,className:"input w-40 text-sm",disabled:!v||!n,placeholder:"Unlimited"})]}):n?e.rate_limit_max===null||e.rate_limit_max===0?"Unlimited":`${e.rate_limit_max.toLocaleString()}/hour`:y.jsx("span",{className:"text-slate-500 italic",children:"KV not configured"})}),y.jsx("td",{className:"px-6 py-4 text-sm text-slate-400",children:new Date(e.created_at*1e3).toLocaleString()}),y.jsx("td",{className:"px-6 py-4 text-sm text-slate-400",children:e.last_used_at?new Date(e.last_used_at*1e3).toLocaleString():"Never"}),o&&y.jsx("td",{className:"px-6 py-4 text-right",children:y.jsx("div",{className:"flex items-center justify-end gap-2",children:s?y.jsxs(y.Fragment,{children:[y.jsx("button",{onClick:w,disabled:l,className:"text-green-400 hover:text-green-300 text-sm flex items-center gap-1",title:"Save",children:y.jsx(cC,{className:"w-4 h-4"})}),y.jsx("button",{onClick:j,disabled:l,className:"text-slate-400 hover:text-slate-200 text-sm",title:"Cancel",children:y.jsx(Ui,{className:"w-4 h-4"})})]}):y.jsxs(y.Fragment,{children:[y.jsx("button",{onClick:()=>f(!0),className:"text-blue-400 hover:text-blue-300 text-sm flex items-center gap-1",title:"Edit",children:y.jsx(uC,{className:"w-4 h-4"})}),y.jsx("button",{onClick:i,className:"text-red-400 hover:text-red-300 text-sm",title:"Revoke",children:"Revoke"})]})})})]})}function PI({onClose:e,onCreated:t,newToken:i,kvAvailable:l}){const[n,o]=C.useState(""),[s,f]=C.useState("readonly"),[m,d]=C.useState(!1),[p,v]=C.useState(""),[b,x]=C.useState(!1),S=qn(),w=Cn({mutationFn:CC,onSuccess:O=>{S.invalidateQueries({queryKey:["tokens"]}),t(O)}}),j=O=>{O.preventDefault();const N=l&&m&&p!==""?parseInt(p,10):null;w.mutate({description:n,permissions:s,rate_limit_max:N===null||isNaN(N)?null:N})},E=O=>{navigator.clipboard.writeText(O),x(!0),setTimeout(()=>x(!1),2e3)};if(i){const O=JSON.stringify({"http-basic":{[window.location.host]:{username:"token",password:i.token}}},null,2);return y.jsx("div",{className:"fixed inset-0 bg-black/50 backdrop-blur-sm flex items-center justify-center z-50",children:y.jsxs("div",{className:"card max-w-lg w-full mx-4 p-6",children:[y.jsxs("div",{className:"flex items-center justify-between mb-6",children:[y.jsx("h3",{className:"font-display text-xl font-bold text-slate-100",children:"Token Generated!"}),y.jsx("button",{onClick:e,className:"text-slate-400 hover:text-slate-200",children:y.jsx(Ui,{className:"w-4 h-4"})})]}),y.jsxs("div",{className:"bg-yellow-500/10 border border-yellow-500/30 rounded-lg p-4 mb-6 flex items-start gap-2",children:[y.jsx(vC,{className:"w-4 h-4 text-yellow-400 mt-0.5 flex-shrink-0"}),y.jsx("p",{className:"text-yellow-400 text-sm",children:"Copy this token now! It won't be shown again."})]}),y.jsxs("div",{className:"space-y-4",children:[y.jsxs("div",{children:[y.jsx("label",{className:"label",children:"Token"}),y.jsxs("div",{className:"flex gap-2",children:[y.jsx("input",{type:"text",value:i.token,readOnly:!0,className:"input w-full font-mono text-xs"}),y.jsxs("button",{onClick:()=>E(i.token),className:"btn-secondary flex items-center gap-1",children:[b?y.jsx(BS,{className:"w-4 h-4"}):null,b?"Copied":"Copy"]})]})]}),y.jsxs("div",{children:[y.jsx("label",{className:"label",children:"auth.json snippet"}),y.jsx("pre",{className:"bg-slate-950 rounded-lg p-4 overflow-x-auto text-xs text-slate-300",children:y.jsx("code",{children:O})}),y.jsx("button",{onClick:()=>E(O),className:"btn-secondary mt-2 text-sm",children:"Copy auth.json"})]})]}),y.jsx("div",{className:"flex justify-end mt-6",children:y.jsx("button",{onClick:e,className:"btn-primary",children:"Done"})})]})})}return y.jsx("div",{className:"fixed inset-0 bg-black/50 backdrop-blur-sm flex items-center justify-center z-50",children:y.jsxs("div",{className:"card max-w-md w-full mx-4 p-6",children:[y.jsxs("div",{className:"flex items-center justify-between mb-6",children:[y.jsx("h3",{className:"font-display text-xl font-bold text-slate-100",children:"Generate Token"}),y.jsx("button",{onClick:e,className:"text-slate-400 hover:text-slate-200",children:y.jsx(Ui,{className:"w-4 h-4"})})]}),y.jsxs("form",{onSubmit:j,className:"space-y-4",children:[y.jsxs("div",{children:[y.jsx("label",{className:"label",children:"Description"}),y.jsx("input",{type:"text",value:n,onChange:O=>o(O.target.value),placeholder:"e.g., CI/CD Pipeline",className:"input w-full",required:!0})]}),y.jsxs("div",{children:[y.jsx("label",{className:"label",children:"Permissions"}),y.jsxs("div",{className:"space-y-2",children:[y.jsxs("label",{className:"flex items-start gap-3 p-3 rounded-lg border border-slate-700 bg-slate-800/50 cursor-pointer hover:bg-slate-800/70 transition-colors",children:[y.jsx("input",{type:"radio",name:"permissions",value:"readonly",checked:s==="readonly",onChange:O=>f(O.target.value),className:"mt-0.5"}),y.jsxs("div",{className:"flex-1",children:[y.jsxs("div",{className:"flex items-center gap-2 text-slate-200 font-medium",children:[y.jsx(Qs,{className:"w-4 h-4"}),"Read-only"]}),y.jsx("p",{className:"text-xs text-slate-400 mt-1",children:"Can only download packages (composer install)"})]})]}),y.jsxs("label",{className:"flex items-start gap-3 p-3 rounded-lg border border-slate-700 bg-slate-800/50 cursor-pointer hover:bg-slate-800/70 transition-colors",children:[y.jsx("input",{type:"radio",name:"permissions",value:"write",checked:s==="write",onChange:O=>f(O.target.value),className:"mt-0.5"}),y.jsxs("div",{className:"flex-1",children:[y.jsxs("div",{className:"flex items-center gap-2 text-slate-200 font-medium",children:[y.jsx(kp,{className:"w-4 h-4"}),"Write"]}),y.jsx("p",{className:"text-xs text-slate-400 mt-1",children:"Can fetch metadata and sync packages (composer require/update)"})]})]})]})]}),y.jsxs("div",{children:[y.jsx("label",{className:"label",children:"Rate Limit (requests/hour)"}),y.jsxs("div",{className:"space-y-2",children:[!l&&y.jsx("p",{className:"text-xs text-slate-500 italic",children:"Configure KV to enable rate limiting"}),y.jsxs("label",{className:"flex items-center gap-2 text-sm text-slate-300",children:[y.jsx("input",{type:"checkbox",checked:m,onChange:O=>{const N=O.target.checked;d(N),N&&p===""&&v("1000"),N||v("")},disabled:!l}),"Enable rate limiting"]}),y.jsx("input",{type:"number",value:p,onChange:O=>v(O.target.value),placeholder:"Unlimited",min:0,max:25e3,className:"input w-full",disabled:!m||!l}),y.jsx("p",{className:"text-xs text-slate-400",children:"When disabled, no rate limit is enforced (no KV operations)."})]})]}),y.jsxs("div",{className:"flex justify-end gap-3 pt-4",children:[y.jsx("button",{type:"button",onClick:e,className:"btn-secondary",children:"Cancel"}),y.jsx("button",{type:"submit",className:"btn-primary",disabled:w.isPending,children:w.isPending?"Generating...":"Generate Token"})]}),w.error&&y.jsx("p",{className:"text-red-400 text-sm",children:w.error.message})]})]})})}var $s={exports:{}},Om,O_;function Gc(){if(O_)return Om;O_=1;const e="2.0.0",t=256,i=Number.MAX_SAFE_INTEGER||9007199254740991,l=16,n=t-6;return Om={MAX_LENGTH:t,MAX_SAFE_COMPONENT_LENGTH:l,MAX_SAFE_BUILD_LENGTH:n,MAX_SAFE_INTEGER:i,RELEASE_TYPES:["major","premajor","minor","preminor","patch","prepatch","prerelease"],SEMVER_SPEC_VERSION:e,FLAG_INCLUDE_PRERELEASE:1,FLAG_LOOSE:2},Om}var Tm,T_;function Vc(){if(T_)return Tm;T_=1;var e={};return Tm=typeof process=="object"&&e&&e.NODE_DEBUG&&/\bsemver\b/i.test(e.NODE_DEBUG)?(...i)=>console.error("SEMVER",...i):()=>{},Tm}var C_;function Xo(){return C_||(C_=1,(function(e,t){const{MAX_SAFE_COMPONENT_LENGTH:i,MAX_SAFE_BUILD_LENGTH:l,MAX_LENGTH:n}=Gc(),o=Vc();t=e.exports={};const s=t.re=[],f=t.safeRe=[],m=t.src=[],d=t.safeSrc=[],p=t.t={};let v=0;const b="[a-zA-Z0-9-]",x=[["\\s",1],["\\d",n],[b,l]],S=j=>{for(const[E,O]of x)j=j.split(`${E}*`).join(`${E}{0,${O}}`).split(`${E}+`).join(`${E}{1,${O}}`);return j},w=(j,E,O)=>{const N=S(E),G=v++;o(j,G,E),p[j]=G,m[G]=E,d[G]=N,s[G]=new RegExp(E,O?"g":void 0),f[G]=new RegExp(N,O?"g":void 0)};w("NUMERICIDENTIFIER","0|[1-9]\\d*"),w("NUMERICIDENTIFIERLOOSE","\\d+"),w("NONNUMERICIDENTIFIER",`\\d*[a-zA-Z-]${b}*`),w("MAINVERSION",`(${m[p.NUMERICIDENTIFIER]})\\.(${m[p.NUMERICIDENTIFIER]})\\.(${m[p.NUMERICIDENTIFIER]})`),w("MAINVERSIONLOOSE",`(${m[p.NUMERICIDENTIFIERLOOSE]})\\.(${m[p.NUMERICIDENTIFIERLOOSE]})\\.(${m[p.NUMERICIDENTIFIERLOOSE]})`),w("PRERELEASEIDENTIFIER",`(?:${m[p.NONNUMERICIDENTIFIER]}|${m[p.NUMERICIDENTIFIER]})`),w("PRERELEASEIDENTIFIERLOOSE",`(?:${m[p.NONNUMERICIDENTIFIER]}|${m[p.NUMERICIDENTIFIERLOOSE]})`),w("PRERELEASE",`(?:-(${m[p.PRERELEASEIDENTIFIER]}(?:\\.${m[p.PRERELEASEIDENTIFIER]})*))`),w("PRERELEASELOOSE",`(?:-?(${m[p.PRERELEASEIDENTIFIERLOOSE]}(?:\\.${m[p.PRERELEASEIDENTIFIERLOOSE]})*))`),w("BUILDIDENTIFIER",`${b}+`),w("BUILD",`(?:\\+(${m[p.BUILDIDENTIFIER]}(?:\\.${m[p.BUILDIDENTIFIER]})*))`),w("FULLPLAIN",`v?${m[p.MAINVERSION]}${m[p.PRERELEASE]}?${m[p.BUILD]}?`),w("FULL",`^${m[p.FULLPLAIN]}$`),w("LOOSEPLAIN",`[v=\\s]*${m[p.MAINVERSIONLOOSE]}${m[p.PRERELEASELOOSE]}?${m[p.BUILD]}?`),w("LOOSE",`^${m[p.LOOSEPLAIN]}$`),w("GTLT","((?:<|>)?=?)"),w("XRANGEIDENTIFIERLOOSE",`${m[p.NUMERICIDENTIFIERLOOSE]}|x|X|\\*`),w("XRANGEIDENTIFIER",`${m[p.NUMERICIDENTIFIER]}|x|X|\\*`),w("XRANGEPLAIN",`[v=\\s]*(${m[p.XRANGEIDENTIFIER]})(?:\\.(${m[p.XRANGEIDENTIFIER]})(?:\\.(${m[p.XRANGEIDENTIFIER]})(?:${m[p.PRERELEASE]})?${m[p.BUILD]}?)?)?`),w("XRANGEPLAINLOOSE",`[v=\\s]*(${m[p.XRANGEIDENTIFIERLOOSE]})(?:\\.(${m[p.XRANGEIDENTIFIERLOOSE]})(?:\\.(${m[p.XRANGEIDENTIFIERLOOSE]})(?:${m[p.PRERELEASELOOSE]})?${m[p.BUILD]}?)?)?`),w("XRANGE",`^${m[p.GTLT]}\\s*${m[p.XRANGEPLAIN]}$`),w("XRANGELOOSE",`^${m[p.GTLT]}\\s*${m[p.XRANGEPLAINLOOSE]}$`),w("COERCEPLAIN",`(^|[^\\d])(\\d{1,${i}})(?:\\.(\\d{1,${i}}))?(?:\\.(\\d{1,${i}}))?`),w("COERCE",`${m[p.COERCEPLAIN]}(?:$|[^\\d])`),w("COERCEFULL",m[p.COERCEPLAIN]+`(?:${m[p.PRERELEASE]})?(?:${m[p.BUILD]})?(?:$|[^\\d])`),w("COERCERTL",m[p.COERCE],!0),w("COERCERTLFULL",m[p.COERCEFULL],!0),w("LONETILDE","(?:~>?)"),w("TILDETRIM",`(\\s*)${m[p.LONETILDE]}\\s+`,!0),t.tildeTrimReplace="$1~",w("TILDE",`^${m[p.LONETILDE]}${m[p.XRANGEPLAIN]}$`),w("TILDELOOSE",`^${m[p.LONETILDE]}${m[p.XRANGEPLAINLOOSE]}$`),w("LONECARET","(?:\\^)"),w("CARETTRIM",`(\\s*)${m[p.LONECARET]}\\s+`,!0),t.caretTrimReplace="$1^",w("CARET",`^${m[p.LONECARET]}${m[p.XRANGEPLAIN]}$`),w("CARETLOOSE",`^${m[p.LONECARET]}${m[p.XRANGEPLAINLOOSE]}$`),w("COMPARATORLOOSE",`^${m[p.GTLT]}\\s*(${m[p.LOOSEPLAIN]})$|^$`),w("COMPARATOR",`^${m[p.GTLT]}\\s*(${m[p.FULLPLAIN]})$|^$`),w("COMPARATORTRIM",`(\\s*)${m[p.GTLT]}\\s*(${m[p.LOOSEPLAIN]}|${m[p.XRANGEPLAIN]})`,!0),t.comparatorTrimReplace="$1$2$3",w("HYPHENRANGE",`^\\s*(${m[p.XRANGEPLAIN]})\\s+-\\s+(${m[p.XRANGEPLAIN]})\\s*$`),w("HYPHENRANGELOOSE",`^\\s*(${m[p.XRANGEPLAINLOOSE]})\\s+-\\s+(${m[p.XRANGEPLAINLOOSE]})\\s*$`),w("STAR","(<|>)?=?\\s*\\*"),w("GTE0","^\\s*>=\\s*0\\.0\\.0\\s*$"),w("GTE0PRE","^\\s*>=\\s*0\\.0\\.0-0\\s*$")})($s,$s.exports)),$s.exports}var Cm,D_;function hv(){if(D_)return Cm;D_=1;const e=Object.freeze({loose:!0}),t=Object.freeze({});return Cm=l=>l?typeof l!="object"?e:l:t,Cm}var Dm,A_;function V4(){if(A_)return Dm;A_=1;const e=/^[0-9]+$/,t=(l,n)=>{if(typeof l=="number"&&typeof n=="number")return l===n?0:l<n?-1:1;const o=e.test(l),s=e.test(n);return o&&s&&(l=+l,n=+n),l===n?0:o&&!s?-1:s&&!o?1:l<n?-1:1};return Dm={compareIdentifiers:t,rcompareIdentifiers:(l,n)=>t(n,l)},Dm}var Am,R_;function Bt(){if(R_)return Am;R_=1;const e=Vc(),{MAX_LENGTH:t,MAX_SAFE_INTEGER:i}=Gc(),{safeRe:l,t:n}=Xo(),o=hv(),{compareIdentifiers:s}=V4();class f{constructor(d,p){if(p=o(p),d instanceof f){if(d.loose===!!p.loose&&d.includePrerelease===!!p.includePrerelease)return d;d=d.version}else if(typeof d!="string")throw new TypeError(`Invalid version. Must be a string. Got type "${typeof d}".`);if(d.length>t)throw new TypeError(`version is longer than ${t} characters`);e("SemVer",d,p),this.options=p,this.loose=!!p.loose,this.includePrerelease=!!p.includePrerelease;const v=d.trim().match(p.loose?l[n.LOOSE]:l[n.FULL]);if(!v)throw new TypeError(`Invalid Version: ${d}`);if(this.raw=d,this.major=+v[1],this.minor=+v[2],this.patch=+v[3],this.major>i||this.major<0)throw new TypeError("Invalid major version");if(this.minor>i||this.minor<0)throw new TypeError("Invalid minor version");if(this.patch>i||this.patch<0)throw new TypeError("Invalid patch version");v[4]?this.prerelease=v[4].split(".").map(b=>{if(/^[0-9]+$/.test(b)){const x=+b;if(x>=0&&x<i)return x}return b}):this.prerelease=[],this.build=v[5]?v[5].split("."):[],this.format()}format(){return this.version=`${this.major}.${this.minor}.${this.patch}`,this.prerelease.length&&(this.version+=`-${this.prerelease.join(".")}`),this.version}toString(){return this.version}compare(d){if(e("SemVer.compare",this.version,this.options,d),!(d instanceof f)){if(typeof d=="string"&&d===this.version)return 0;d=new f(d,this.options)}return d.version===this.version?0:this.compareMain(d)||this.comparePre(d)}compareMain(d){return d instanceof f||(d=new f(d,this.options)),this.major<d.major?-1:this.major>d.major?1:this.minor<d.minor?-1:this.minor>d.minor?1:this.patch<d.patch?-1:this.patch>d.patch?1:0}comparePre(d){if(d instanceof f||(d=new f(d,this.options)),this.prerelease.length&&!d.prerelease.length)return-1;if(!this.prerelease.length&&d.prerelease.length)return 1;if(!this.prerelease.length&&!d.prerelease.length)return 0;let p=0;do{const v=this.prerelease[p],b=d.prerelease[p];if(e("prerelease compare",p,v,b),v===void 0&&b===void 0)return 0;if(b===void 0)return 1;if(v===void 0)return-1;if(v===b)continue;return s(v,b)}while(++p)}compareBuild(d){d instanceof f||(d=new f(d,this.options));let p=0;do{const v=this.build[p],b=d.build[p];if(e("build compare",p,v,b),v===void 0&&b===void 0)return 0;if(b===void 0)return 1;if(v===void 0)return-1;if(v===b)continue;return s(v,b)}while(++p)}inc(d,p,v){if(d.startsWith("pre")){if(!p&&v===!1)throw new Error("invalid increment argument: identifier is empty");if(p){const b=`-${p}`.match(this.options.loose?l[n.PRERELEASELOOSE]:l[n.PRERELEASE]);if(!b||b[1]!==p)throw new Error(`invalid identifier: ${p}`)}}switch(d){case"premajor":this.prerelease.length=0,this.patch=0,this.minor=0,this.major++,this.inc("pre",p,v);break;case"preminor":this.prerelease.length=0,this.patch=0,this.minor++,this.inc("pre",p,v);break;case"prepatch":this.prerelease.length=0,this.inc("patch",p,v),this.inc("pre",p,v);break;case"prerelease":this.prerelease.length===0&&this.inc("patch",p,v),this.inc("pre",p,v);break;case"release":if(this.prerelease.length===0)throw new Error(`version ${this.raw} is not a prerelease`);this.prerelease.length=0;break;case"major":(this.minor!==0||this.patch!==0||this.prerelease.length===0)&&this.major++,this.minor=0,this.patch=0,this.prerelease=[];break;case"minor":(this.patch!==0||this.prerelease.length===0)&&this.minor++,this.patch=0,this.prerelease=[];break;case"patch":this.prerelease.length===0&&this.patch++,this.prerelease=[];break;case"pre":{const b=Number(v)?1:0;if(this.prerelease.length===0)this.prerelease=[b];else{let x=this.prerelease.length;for(;--x>=0;)typeof this.prerelease[x]=="number"&&(this.prerelease[x]++,x=-2);if(x===-1){if(p===this.prerelease.join(".")&&v===!1)throw new Error("invalid increment argument: identifier already exists");this.prerelease.push(b)}}if(p){let x=[p,b];v===!1&&(x=[p]),s(this.prerelease[0],p)===0?isNaN(this.prerelease[1])&&(this.prerelease=x):this.prerelease=x}break}default:throw new Error(`invalid increment argument: ${d}`)}return this.raw=this.format(),this.build.length&&(this.raw+=`+${this.build.join(".")}`),this}}return Am=f,Am}var Rm,I_;function rl(){if(I_)return Rm;I_=1;const e=Bt();return Rm=(i,l,n=!1)=>{if(i instanceof e)return i;try{return new e(i,l)}catch(o){if(!n)return null;throw o}},Rm}var Im,U_;function ZI(){if(U_)return Im;U_=1;const e=rl();return Im=(i,l)=>{const n=e(i,l);return n?n.version:null},Im}var Um,L_;function qI(){if(L_)return Um;L_=1;const e=rl();return Um=(i,l)=>{const n=e(i.trim().replace(/^[=v]+/,""),l);return n?n.version:null},Um}var Lm,M_;function FI(){if(M_)return Lm;M_=1;const e=Bt();return Lm=(i,l,n,o,s)=>{typeof n=="string"&&(s=o,o=n,n=void 0);try{return new e(i instanceof e?i.version:i,n).inc(l,o,s).version}catch{return null}},Lm}var Mm,P_;function BI(){if(P_)return Mm;P_=1;const e=rl();return Mm=(i,l)=>{const n=e(i,null,!0),o=e(l,null,!0),s=n.compare(o);if(s===0)return null;const f=s>0,m=f?n:o,d=f?o:n,p=!!m.prerelease.length;if(!!d.prerelease.length&&!p){if(!d.patch&&!d.minor)return"major";if(d.compareMain(m)===0)return d.minor&&!d.patch?"minor":"patch"}const b=p?"pre":"";return n.major!==o.major?b+"major":n.minor!==o.minor?b+"minor":n.patch!==o.patch?b+"patch":"prerelease"},Mm}var Pm,Z_;function HI(){if(Z_)return Pm;Z_=1;const e=Bt();return Pm=(i,l)=>new e(i,l).major,Pm}var Zm,q_;function GI(){if(q_)return Zm;q_=1;const e=Bt();return Zm=(i,l)=>new e(i,l).minor,Zm}var qm,F_;function VI(){if(F_)return qm;F_=1;const e=Bt();return qm=(i,l)=>new e(i,l).patch,qm}var Fm,B_;function YI(){if(B_)return Fm;B_=1;const e=rl();return Fm=(i,l)=>{const n=e(i,l);return n&&n.prerelease.length?n.prerelease:null},Fm}var Bm,H_;function Bn(){if(H_)return Bm;H_=1;const e=Bt();return Bm=(i,l,n)=>new e(i,n).compare(new e(l,n)),Bm}var Hm,G_;function JI(){if(G_)return Hm;G_=1;const e=Bn();return Hm=(i,l,n)=>e(l,i,n),Hm}var Gm,V_;function XI(){if(V_)return Gm;V_=1;const e=Bn();return Gm=(i,l)=>e(i,l,!0),Gm}var Vm,Y_;function pv(){if(Y_)return Vm;Y_=1;const e=Bt();return Vm=(i,l,n)=>{const o=new e(i,n),s=new e(l,n);return o.compare(s)||o.compareBuild(s)},Vm}var Ym,J_;function QI(){if(J_)return Ym;J_=1;const e=pv();return Ym=(i,l)=>i.sort((n,o)=>e(n,o,l)),Ym}var Jm,X_;function KI(){if(X_)return Jm;X_=1;const e=pv();return Jm=(i,l)=>i.sort((n,o)=>e(o,n,l)),Jm}var Xm,Q_;function Yc(){if(Q_)return Xm;Q_=1;const e=Bn();return Xm=(i,l,n)=>e(i,l,n)>0,Xm}var Qm,K_;function gv(){if(K_)return Qm;K_=1;const e=Bn();return Qm=(i,l,n)=>e(i,l,n)<0,Qm}var Km,W_;function Y4(){if(W_)return Km;W_=1;const e=Bn();return Km=(i,l,n)=>e(i,l,n)===0,Km}var Wm,e1;function J4(){if(e1)return Wm;e1=1;const e=Bn();return Wm=(i,l,n)=>e(i,l,n)!==0,Wm}var eh,t1;function vv(){if(t1)return eh;t1=1;const e=Bn();return eh=(i,l,n)=>e(i,l,n)>=0,eh}var th,n1;function yv(){if(n1)return th;n1=1;const e=Bn();return th=(i,l,n)=>e(i,l,n)<=0,th}var nh,r1;function X4(){if(r1)return nh;r1=1;const e=Y4(),t=J4(),i=Yc(),l=vv(),n=gv(),o=yv();return nh=(f,m,d,p)=>{switch(m){case"===":return typeof f=="object"&&(f=f.version),typeof d=="object"&&(d=d.version),f===d;case"!==":return typeof f=="object"&&(f=f.version),typeof d=="object"&&(d=d.version),f!==d;case"":case"=":case"==":return e(f,d,p);case"!=":return t(f,d,p);case">":return i(f,d,p);case">=":return l(f,d,p);case"<":return n(f,d,p);case"<=":return o(f,d,p);default:throw new TypeError(`Invalid operator: ${m}`)}},nh}var rh,i1;function WI(){if(i1)return rh;i1=1;const e=Bt(),t=rl(),{safeRe:i,t:l}=Xo();return rh=(o,s)=>{if(o instanceof e)return o;if(typeof o=="number"&&(o=String(o)),typeof o!="string")return null;s=s||{};let f=null;if(!s.rtl)f=o.match(s.includePrerelease?i[l.COERCEFULL]:i[l.COERCE]);else{const x=s.includePrerelease?i[l.COERCERTLFULL]:i[l.COERCERTL];let S;for(;(S=x.exec(o))&&(!f||f.index+f[0].length!==o.length);)(!f||S.index+S[0].length!==f.index+f[0].length)&&(f=S),x.lastIndex=S.index+S[1].length+S[2].length;x.lastIndex=-1}if(f===null)return null;const m=f[2],d=f[3]||"0",p=f[4]||"0",v=s.includePrerelease&&f[5]?`-${f[5]}`:"",b=s.includePrerelease&&f[6]?`+${f[6]}`:"";return t(`${m}.${d}.${p}${v}${b}`,s)},rh}var ih,a1;function eU(){if(a1)return ih;a1=1;class e{constructor(){this.max=1e3,this.map=new Map}get(i){const l=this.map.get(i);if(l!==void 0)return this.map.delete(i),this.map.set(i,l),l}delete(i){return this.map.delete(i)}set(i,l){if(!this.delete(i)&&l!==void 0){if(this.map.size>=this.max){const o=this.map.keys().next().value;this.delete(o)}this.map.set(i,l)}return this}}return ih=e,ih}var ah,l1;function Hn(){if(l1)return ah;l1=1;const e=/\s+/g;class t{constructor(U,A){if(A=n(A),U instanceof t)return U.loose===!!A.loose&&U.includePrerelease===!!A.includePrerelease?U:new t(U.raw,A);if(U instanceof o)return this.raw=U.value,this.set=[[U]],this.formatted=void 0,this;if(this.options=A,this.loose=!!A.loose,this.includePrerelease=!!A.includePrerelease,this.raw=U.trim().replace(e," "),this.set=this.raw.split("||").map(q=>this.parseRange(q.trim())).filter(q=>q.length),!this.set.length)throw new TypeError(`Invalid SemVer Range: ${this.raw}`);if(this.set.length>1){const q=this.set[0];if(this.set=this.set.filter(te=>!w(te[0])),this.set.length===0)this.set=[q];else if(this.set.length>1){for(const te of this.set)if(te.length===1&&j(te[0])){this.set=[te];break}}}this.formatted=void 0}get range(){if(this.formatted===void 0){this.formatted="";for(let U=0;U<this.set.length;U++){U>0&&(this.formatted+="||");const A=this.set[U];for(let q=0;q<A.length;q++)q>0&&(this.formatted+=" "),this.formatted+=A[q].toString().trim()}}return this.formatted}format(){return this.range}toString(){return this.range}parseRange(U){const q=((this.options.includePrerelease&&x)|(this.options.loose&&S))+":"+U,te=l.get(q);if(te)return te;const ie=this.options.loose,z=ie?m[d.HYPHENRANGELOOSE]:m[d.HYPHENRANGE];U=U.replace(z,ce(this.options.includePrerelease)),s("hyphen replace",U),U=U.replace(m[d.COMPARATORTRIM],p),s("comparator trim",U),U=U.replace(m[d.TILDETRIM],v),s("tilde trim",U),U=U.replace(m[d.CARETTRIM],b),s("caret trim",U);let T=U.split(" ").map(de=>O(de,this.options)).join(" ").split(/\s+/).map(de=>ue(de,this.options));ie&&(T=T.filter(de=>(s("loose invalid filter",de,this.options),!!de.match(m[d.COMPARATORLOOSE])))),s("range list",T);const Z=new Map,$=T.map(de=>new o(de,this.options));for(const de of $){if(w(de))return[de];Z.set(de.value,de)}Z.size>1&&Z.has("")&&Z.delete("");const oe=[...Z.values()];return l.set(q,oe),oe}intersects(U,A){if(!(U instanceof t))throw new TypeError("a Range is required");return this.set.some(q=>E(q,A)&&U.set.some(te=>E(te,A)&&q.every(ie=>te.every(z=>ie.intersects(z,A)))))}test(U){if(!U)return!1;if(typeof U=="string")try{U=new f(U,this.options)}catch{return!1}for(let A=0;A<this.set.length;A++)if(ke(this.set[A],U,this.options))return!0;return!1}}ah=t;const i=eU(),l=new i,n=hv(),o=Jc(),s=Vc(),f=Bt(),{safeRe:m,t:d,comparatorTrimReplace:p,tildeTrimReplace:v,caretTrimReplace:b}=Xo(),{FLAG_INCLUDE_PRERELEASE:x,FLAG_LOOSE:S}=Gc(),w=M=>M.value==="<0.0.0-0",j=M=>M.value==="",E=(M,U)=>{let A=!0;const q=M.slice();let te=q.pop();for(;A&&q.length;)A=q.every(ie=>te.intersects(ie,U)),te=q.pop();return A},O=(M,U)=>(M=M.replace(m[d.BUILD],""),s("comp",M,U),M=R(M,U),s("caret",M),M=G(M,U),s("tildes",M),M=Q(M,U),s("xrange",M),M=B(M,U),s("stars",M),M),N=M=>!M||M.toLowerCase()==="x"||M==="*",G=(M,U)=>M.trim().split(/\s+/).map(A=>J(A,U)).join(" "),J=(M,U)=>{const A=U.loose?m[d.TILDELOOSE]:m[d.TILDE];return M.replace(A,(q,te,ie,z,T)=>{s("tilde",M,q,te,ie,z,T);let Z;return N(te)?Z="":N(ie)?Z=`>=${te}.0.0 <${+te+1}.0.0-0`:N(z)?Z=`>=${te}.${ie}.0 <${te}.${+ie+1}.0-0`:T?(s("replaceTilde pr",T),Z=`>=${te}.${ie}.${z}-${T} <${te}.${+ie+1}.0-0`):Z=`>=${te}.${ie}.${z} <${te}.${+ie+1}.0-0`,s("tilde return",Z),Z})},R=(M,U)=>M.trim().split(/\s+/).map(A=>X(A,U)).join(" "),X=(M,U)=>{s("caret",M,U);const A=U.loose?m[d.CARETLOOSE]:m[d.CARET],q=U.includePrerelease?"-0":"";return M.replace(A,(te,ie,z,T,Z)=>{s("caret",M,te,ie,z,T,Z);let $;return N(ie)?$="":N(z)?$=`>=${ie}.0.0${q} <${+ie+1}.0.0-0`:N(T)?ie==="0"?$=`>=${ie}.${z}.0${q} <${ie}.${+z+1}.0-0`:$=`>=${ie}.${z}.0${q} <${+ie+1}.0.0-0`:Z?(s("replaceCaret pr",Z),ie==="0"?z==="0"?$=`>=${ie}.${z}.${T}-${Z} <${ie}.${z}.${+T+1}-0`:$=`>=${ie}.${z}.${T}-${Z} <${ie}.${+z+1}.0-0`:$=`>=${ie}.${z}.${T}-${Z} <${+ie+1}.0.0-0`):(s("no pr"),ie==="0"?z==="0"?$=`>=${ie}.${z}.${T}${q} <${ie}.${z}.${+T+1}-0`:$=`>=${ie}.${z}.${T}${q} <${ie}.${+z+1}.0-0`:$=`>=${ie}.${z}.${T} <${+ie+1}.0.0-0`),s("caret return",$),$})},Q=(M,U)=>(s("replaceXRanges",M,U),M.split(/\s+/).map(A=>me(A,U)).join(" ")),me=(M,U)=>{M=M.trim();const A=U.loose?m[d.XRANGELOOSE]:m[d.XRANGE];return M.replace(A,(q,te,ie,z,T,Z)=>{s("xRange",M,q,te,ie,z,T,Z);const $=N(ie),oe=$||N(z),de=oe||N(T),pe=de;return te==="="&&pe&&(te=""),Z=U.includePrerelease?"-0":"",$?te===">"||te==="<"?q="<0.0.0-0":q="*":te&&pe?(oe&&(z=0),T=0,te===">"?(te=">=",oe?(ie=+ie+1,z=0,T=0):(z=+z+1,T=0)):te==="<="&&(te="<",oe?ie=+ie+1:z=+z+1),te==="<"&&(Z="-0"),q=`${te+ie}.${z}.${T}${Z}`):oe?q=`>=${ie}.0.0${Z} <${+ie+1}.0.0-0`:de&&(q=`>=${ie}.${z}.0${Z} <${ie}.${+z+1}.0-0`),s("xRange return",q),q})},B=(M,U)=>(s("replaceStars",M,U),M.trim().replace(m[d.STAR],"")),ue=(M,U)=>(s("replaceGTE0",M,U),M.trim().replace(m[U.includePrerelease?d.GTE0PRE:d.GTE0],"")),ce=M=>(U,A,q,te,ie,z,T,Z,$,oe,de,pe)=>(N(q)?A="":N(te)?A=`>=${q}.0.0${M?"-0":""}`:N(ie)?A=`>=${q}.${te}.0${M?"-0":""}`:z?A=`>=${A}`:A=`>=${A}${M?"-0":""}`,N($)?Z="":N(oe)?Z=`<${+$+1}.0.0-0`:N(de)?Z=`<${$}.${+oe+1}.0-0`:pe?Z=`<=${$}.${oe}.${de}-${pe}`:M?Z=`<${$}.${oe}.${+de+1}-0`:Z=`<=${Z}`,`${A} ${Z}`.trim()),ke=(M,U,A)=>{for(let q=0;q<M.length;q++)if(!M[q].test(U))return!1;if(U.prerelease.length&&!A.includePrerelease){for(let q=0;q<M.length;q++)if(s(M[q].semver),M[q].semver!==o.ANY&&M[q].semver.prerelease.length>0){const te=M[q].semver;if(te.major===U.major&&te.minor===U.minor&&te.patch===U.patch)return!0}return!1}return!0};return ah}var lh,o1;function Jc(){if(o1)return lh;o1=1;const e=Symbol("SemVer ANY");class t{static get ANY(){return e}constructor(p,v){if(v=i(v),p instanceof t){if(p.loose===!!v.loose)return p;p=p.value}p=p.trim().split(/\s+/).join(" "),s("comparator",p,v),this.options=v,this.loose=!!v.loose,this.parse(p),this.semver===e?this.value="":this.value=this.operator+this.semver.version,s("comp",this)}parse(p){const v=this.options.loose?l[n.COMPARATORLOOSE]:l[n.COMPARATOR],b=p.match(v);if(!b)throw new TypeError(`Invalid comparator: ${p}`);this.operator=b[1]!==void 0?b[1]:"",this.operator==="="&&(this.operator=""),b[2]?this.semver=new f(b[2],this.options.loose):this.semver=e}toString(){return this.value}test(p){if(s("Comparator.test",p,this.options.loose),this.semver===e||p===e)return!0;if(typeof p=="string")try{p=new f(p,this.options)}catch{return!1}return o(p,this.operator,this.semver,this.options)}intersects(p,v){if(!(p instanceof t))throw new TypeError("a Comparator is required");return this.operator===""?this.value===""?!0:new m(p.value,v).test(this.value):p.operator===""?p.value===""?!0:new m(this.value,v).test(p.semver):(v=i(v),v.includePrerelease&&(this.value==="<0.0.0-0"||p.value==="<0.0.0-0")||!v.includePrerelease&&(this.value.startsWith("<0.0.0")||p.value.startsWith("<0.0.0"))?!1:!!(this.operator.startsWith(">")&&p.operator.startsWith(">")||this.operator.startsWith("<")&&p.operator.startsWith("<")||this.semver.version===p.semver.version&&this.operator.includes("=")&&p.operator.includes("=")||o(this.semver,"<",p.semver,v)&&this.operator.startsWith(">")&&p.operator.startsWith("<")||o(this.semver,">",p.semver,v)&&this.operator.startsWith("<")&&p.operator.startsWith(">")))}}lh=t;const i=hv(),{safeRe:l,t:n}=Xo(),o=X4(),s=Vc(),f=Bt(),m=Hn();return lh}var oh,u1;function Xc(){if(u1)return oh;u1=1;const e=Hn();return oh=(i,l,n)=>{try{l=new e(l,n)}catch{return!1}return l.test(i)},oh}var uh,s1;function tU(){if(s1)return uh;s1=1;const e=Hn();return uh=(i,l)=>new e(i,l).set.map(n=>n.map(o=>o.value).join(" ").trim().split(" ")),uh}var sh,c1;function nU(){if(c1)return sh;c1=1;const e=Bt(),t=Hn();return sh=(l,n,o)=>{let s=null,f=null,m=null;try{m=new t(n,o)}catch{return null}return l.forEach(d=>{m.test(d)&&(!s||f.compare(d)===-1)&&(s=d,f=new e(s,o))}),s},sh}var ch,f1;function rU(){if(f1)return ch;f1=1;const e=Bt(),t=Hn();return ch=(l,n,o)=>{let s=null,f=null,m=null;try{m=new t(n,o)}catch{return null}return l.forEach(d=>{m.test(d)&&(!s||f.compare(d)===1)&&(s=d,f=new e(s,o))}),s},ch}var fh,d1;function iU(){if(d1)return fh;d1=1;const e=Bt(),t=Hn(),i=Yc();return fh=(n,o)=>{n=new t(n,o);let s=new e("0.0.0");if(n.test(s)||(s=new e("0.0.0-0"),n.test(s)))return s;s=null;for(let f=0;f<n.set.length;++f){const m=n.set[f];let d=null;m.forEach(p=>{const v=new e(p.semver.version);switch(p.operator){case">":v.prerelease.length===0?v.patch++:v.prerelease.push(0),v.raw=v.format();case"":case">=":(!d||i(v,d))&&(d=v);break;case"<":case"<=":break;default:throw new Error(`Unexpected operation: ${p.operator}`)}}),d&&(!s||i(s,d))&&(s=d)}return s&&n.test(s)?s:null},fh}var dh,m1;function aU(){if(m1)return dh;m1=1;const e=Hn();return dh=(i,l)=>{try{return new e(i,l).range||"*"}catch{return null}},dh}var mh,h1;function bv(){if(h1)return mh;h1=1;const e=Bt(),t=Jc(),{ANY:i}=t,l=Hn(),n=Xc(),o=Yc(),s=gv(),f=yv(),m=vv();return mh=(p,v,b,x)=>{p=new e(p,x),v=new l(v,x);let S,w,j,E,O;switch(b){case">":S=o,w=f,j=s,E=">",O=">=";break;case"<":S=s,w=m,j=o,E="<",O="<=";break;default:throw new TypeError('Must provide a hilo val of "<" or ">"')}if(n(p,v,x))return!1;for(let N=0;N<v.set.length;++N){const G=v.set[N];let J=null,R=null;if(G.forEach(X=>{X.semver===i&&(X=new t(">=0.0.0")),J=J||X,R=R||X,S(X.semver,J.semver,x)?J=X:j(X.semver,R.semver,x)&&(R=X)}),J.operator===E||J.operator===O||(!R.operator||R.operator===E)&&w(p,R.semver))return!1;if(R.operator===O&&j(p,R.semver))return!1}return!0},mh}var hh,p1;function lU(){if(p1)return hh;p1=1;const e=bv();return hh=(i,l,n)=>e(i,l,">",n),hh}var ph,g1;function oU(){if(g1)return ph;g1=1;const e=bv();return ph=(i,l,n)=>e(i,l,"<",n),ph}var gh,v1;function uU(){if(v1)return gh;v1=1;const e=Hn();return gh=(i,l,n)=>(i=new e(i,n),l=new e(l,n),i.intersects(l,n)),gh}var vh,y1;function sU(){if(y1)return vh;y1=1;const e=Xc(),t=Bn();return vh=(i,l,n)=>{const o=[];let s=null,f=null;const m=i.sort((b,x)=>t(b,x,n));for(const b of m)e(b,l,n)?(f=b,s||(s=b)):(f&&o.push([s,f]),f=null,s=null);s&&o.push([s,null]);const d=[];for(const[b,x]of o)b===x?d.push(b):!x&&b===m[0]?d.push("*"):x?b===m[0]?d.push(`<=${x}`):d.push(`${b} - ${x}`):d.push(`>=${b}`);const p=d.join(" || "),v=typeof l.raw=="string"?l.raw:String(l);return p.length<v.length?p:l},vh}var yh,b1;function cU(){if(b1)return yh;b1=1;const e=Hn(),t=Jc(),{ANY:i}=t,l=Xc(),n=Bn(),o=(v,b,x={})=>{if(v===b)return!0;v=new e(v,x),b=new e(b,x);let S=!1;e:for(const w of v.set){for(const j of b.set){const E=m(w,j,x);if(S=S||E!==null,E)continue e}if(S)return!1}return!0},s=[new t(">=0.0.0-0")],f=[new t(">=0.0.0")],m=(v,b,x)=>{if(v===b)return!0;if(v.length===1&&v[0].semver===i){if(b.length===1&&b[0].semver===i)return!0;x.includePrerelease?v=s:v=f}if(b.length===1&&b[0].semver===i){if(x.includePrerelease)return!0;b=f}const S=new Set;let w,j;for(const Q of v)Q.operator===">"||Q.operator===">="?w=d(w,Q,x):Q.operator==="<"||Q.operator==="<="?j=p(j,Q,x):S.add(Q.semver);if(S.size>1)return null;let E;if(w&&j){if(E=n(w.semver,j.semver,x),E>0)return null;if(E===0&&(w.operator!==">="||j.operator!=="<="))return null}for(const Q of S){if(w&&!l(Q,String(w),x)||j&&!l(Q,String(j),x))return null;for(const me of b)if(!l(Q,String(me),x))return!1;return!0}let O,N,G,J,R=j&&!x.includePrerelease&&j.semver.prerelease.length?j.semver:!1,X=w&&!x.includePrerelease&&w.semver.prerelease.length?w.semver:!1;R&&R.prerelease.length===1&&j.operator==="<"&&R.prerelease[0]===0&&(R=!1);for(const Q of b){if(J=J||Q.operator===">"||Q.operator===">=",G=G||Q.operator==="<"||Q.operator==="<=",w){if(X&&Q.semver.prerelease&&Q.semver.prerelease.length&&Q.semver.major===X.major&&Q.semver.minor===X.minor&&Q.semver.patch===X.patch&&(X=!1),Q.operator===">"||Q.operator===">="){if(O=d(w,Q,x),O===Q&&O!==w)return!1}else if(w.operator===">="&&!l(w.semver,String(Q),x))return!1}if(j){if(R&&Q.semver.prerelease&&Q.semver.prerelease.length&&Q.semver.major===R.major&&Q.semver.minor===R.minor&&Q.semver.patch===R.patch&&(R=!1),Q.operator==="<"||Q.operator==="<="){if(N=p(j,Q,x),N===Q&&N!==j)return!1}else if(j.operator==="<="&&!l(j.semver,String(Q),x))return!1}if(!Q.operator&&(j||w)&&E!==0)return!1}return!(w&&G&&!j&&E!==0||j&&J&&!w&&E!==0||X||R)},d=(v,b,x)=>{if(!v)return b;const S=n(v.semver,b.semver,x);return S>0?v:S<0||b.operator===">"&&v.operator===">="?b:v},p=(v,b,x)=>{if(!v)return b;const S=n(v.semver,b.semver,x);return S<0?v:S>0||b.operator==="<"&&v.operator==="<="?b:v};return yh=o,yh}var bh,x1;function fU(){if(x1)return bh;x1=1;const e=Xo(),t=Gc(),i=Bt(),l=V4(),n=rl(),o=ZI(),s=qI(),f=FI(),m=BI(),d=HI(),p=GI(),v=VI(),b=YI(),x=Bn(),S=JI(),w=XI(),j=pv(),E=QI(),O=KI(),N=Yc(),G=gv(),J=Y4(),R=J4(),X=vv(),Q=yv(),me=X4(),B=WI(),ue=Jc(),ce=Hn(),ke=Xc(),M=tU(),U=nU(),A=rU(),q=iU(),te=aU(),ie=bv(),z=lU(),T=oU(),Z=uU(),$=sU(),oe=cU();return bh={parse:n,valid:o,clean:s,inc:f,diff:m,major:d,minor:p,patch:v,prerelease:b,compare:x,rcompare:S,compareLoose:w,compareBuild:j,sort:E,rsort:O,gt:N,lt:G,eq:J,neq:R,gte:X,lte:Q,cmp:me,coerce:B,Comparator:ue,Range:ce,satisfies:ke,toComparators:M,maxSatisfying:U,minSatisfying:A,minVersion:q,validRange:te,outside:ie,gtr:z,ltr:T,intersects:Z,simplifyRange:$,subset:oe,SemVer:i,re:e.re,src:e.src,tokens:e.t,SEMVER_SPEC_VERSION:t.SEMVER_SPEC_VERSION,RELEASE_TYPES:t.RELEASE_TYPES,compareIdentifiers:l.compareIdentifiers,rcompareIdentifiers:l.rcompareIdentifiers},bh}var dU=fU();const Qn=_o(dU),mU="composer_proxy_admin_token";function hU(){return typeof window<"u"?localStorage.getItem(mU):null}function pU({distUrl:e}){const[t,i]=C.useState(!1),[l,n]=C.useState(null),o=async s=>{s.stopPropagation(),i(!0),n(null);try{const f=hU(),m={};f&&(m.Authorization=`Bearer ${f}`);const d=await fetch(e,{headers:m});if(!d.ok)throw new Error(`Download failed: ${d.status} ${d.statusText}`);const p=await d.blob(),v=window.URL.createObjectURL(p),b=document.createElement("a");b.href=v,b.download=e.split("/").pop()||"package.zip",document.body.appendChild(b),b.click(),document.body.removeChild(b),window.URL.revokeObjectURL(v)}catch(f){n(f instanceof Error?f.message:"Download failed")}finally{i(!1)}};return l?y.jsxs("div",{className:"flex flex-col items-end gap-1",children:[y.jsx("button",{onClick:o,className:"text-red-400 hover:text-red-300 text-sm","data-testid":"download-button",children:"Retry"}),y.jsx("span",{className:"text-xs text-red-500",children:l})]}):y.jsx("button",{onClick:o,disabled:t,className:"text-primary-400 hover:text-primary-300 text-sm disabled:opacity-50 disabled:cursor-not-allowed","data-testid":"download-button",children:t?"Downloading...":"Download"})}function gU(){const[e,t]=C.useState(""),[i,l]=C.useState(!1),{data:n=[],isLoading:o}=dn({queryKey:["packages",e],queryFn:()=>RC(e||void 0)}),s=n.reduce((f,m)=>(f[m.name]||(f[m.name]=[]),f[m.name].push(m),f),{});return y.jsxs("div",{className:"space-y-8","data-testid":"packages-page",children:[y.jsxs("div",{className:"flex items-center justify-between",children:[y.jsxs("div",{children:[y.jsx("h2",{className:"font-display text-2xl font-bold text-slate-100 mb-2","data-testid":"packages-heading",children:"Packages"}),y.jsx("p",{className:"text-slate-400",children:"Browse cached packages"})]}),y.jsxs("div",{className:"flex items-center gap-3",children:[y.jsx("div",{className:"w-72",children:y.jsx("input",{type:"text",value:e,onChange:f=>t(f.target.value),placeholder:"Search packages...",className:"input w-full","data-testid":"package-search-input","aria-label":"Search packages"})}),y.jsx("button",{onClick:()=>l(!0),className:"btn-primary","data-testid":"add-packages-button",children:"Add Package"})]})]}),i&&y.jsx(yU,{onClose:()=>l(!1)}),y.jsx("div",{className:"space-y-4","data-testid":"packages-list",children:o?y.jsx("div",{className:"card p-8 text-center","data-testid":"packages-loading",children:y.jsx("div",{className:"w-8 h-8 border-2 border-slate-600 border-t-primary-500 rounded-full animate-spin mx-auto","aria-label":"Loading packages"})}):Object.keys(s).length===0?y.jsx("div",{className:"card p-8 text-center text-slate-400","data-testid":"packages-empty",role:"status","aria-live":"polite",children:"No packages found matching your search."}):Object.entries(s).map(([f,m])=>y.jsx(vU,{name:f,versions:m},f))})]})}function vU({name:e,versions:t}){const[i,l]=C.useState(!1),[n,o]=C.useState(!1),[s,f]=C.useState(null),m=qn(),d=Cn({mutationFn:({packageName:j,version:E})=>VS(j,E),onSuccess:()=>{m.invalidateQueries({queryKey:["packages"]}),f(null)}}),p=C.useMemo(()=>[...t].sort((j,E)=>{const O=/^\d+$/.test(j.version),N=/^\d+$/.test(E.version);if(O&&N){const Q=parseInt(j.version,10);return parseInt(E.version,10)-Q}if(O&&!N&&Qn.valid(E.version))return 1;if(!O&&N&&Qn.valid(j.version))return-1;const G=Qn.valid(j.version),J=Qn.valid(E.version);if(G&&J)return Qn.rcompare(j.version,E.version);if(G&&!J)return-1;if(!G&&J)return 1;const R=j.version.match(/^(\d+)/),X=E.version.match(/^(\d+)/);if(R&&X){const Q=parseInt(R[1],10),me=parseInt(X[1],10);if(Q!==me)return me-Q}return E.version.localeCompare(j.version,void 0,{numeric:!0,sensitivity:"base"})}),[t]),v=p[0],b=n?p:p.slice(0,5),x=p.length>5,w=(j=>{if(!j)return[];try{const E=JSON.parse(j);return Array.isArray(E)?E:[E]}catch{return[j]}})(v.license);return y.jsxs("div",{className:"card","data-testid":"package-card","data-package-name":e,children:[y.jsxs("div",{className:"p-4 flex items-center justify-between cursor-pointer hover:bg-slate-800/30",onClick:()=>l(!i),role:"button","aria-expanded":i,"aria-label":`${e} package, ${t.length} versions`,"data-testid":"package-header",children:[y.jsxs("div",{className:"flex items-center gap-4 flex-1 min-w-0",children:[y.jsx("div",{className:"w-10 h-10 bg-gradient-to-br from-primary-500/20 to-accent-500/20 rounded-lg flex items-center justify-center flex-shrink-0",children:y.jsx(Ii,{className:"w-5 h-5 text-primary-400"})}),y.jsxs("div",{className:"flex-1 min-w-0",children:[y.jsxs("div",{className:"flex items-center gap-2 mb-1",children:[y.jsx(Za,{to:(()=>{const[j,...E]=e.split("/"),O=E.join("/");return`/packages/${j}/${O}`})(),onClick:j=>j.stopPropagation(),className:"font-medium text-slate-100 hover:text-primary-400 transition-colors truncate",children:e}),v.package_type&&y.jsx("span",{className:"px-2 py-0.5 text-xs bg-slate-700 text-slate-300 rounded",children:v.package_type}),w.length>0&&y.jsx("span",{className:"px-2 py-0.5 text-xs bg-slate-700 text-slate-300 rounded",children:w[0]})]}),v.description&&y.jsx("p",{className:"text-sm text-slate-400 truncate mb-1",children:v.description}),y.jsxs("p",{className:"text-sm text-slate-500",children:[t.length," version",t.length!==1?"s":""," • Latest:"," ",y.jsx("span",{className:"text-primary-400",children:v.version})]})]})]}),y.jsx("span",{className:"text-slate-400","aria-hidden":"true","data-testid":"package-expand-toggle",children:i?"▼":"▶"})]}),i&&y.jsxs("div",{className:"border-t border-slate-800 p-4",role:"region","aria-label":`Versions for ${e}`,children:[y.jsx("h4",{className:"text-sm font-medium text-slate-400 mb-3",children:"Versions"}),y.jsxs("div",{className:"space-y-2",role:"list",children:[b.map(j=>y.jsxs("div",{className:"flex items-center justify-between p-3 bg-slate-800/50 rounded-lg","data-testid":"version-row","data-version":j.version,role:"listitem",children:[y.jsxs("div",{className:"flex items-center gap-2 flex-1 min-w-0",children:[y.jsx("span",{className:"font-medium text-slate-200",children:j.version}),j.released_at&&y.jsx("span",{className:"text-sm text-slate-500","aria-label":`Released ${new Date(j.released_at*1e3).toLocaleDateString()}`,children:new Date(j.released_at*1e3).toLocaleDateString()}),j.is_manual_upload===1&&y.jsx("span",{className:"px-2 py-0.5 text-xs bg-blue-600/20 text-blue-400 border border-blue-500/30 rounded",children:"📤 Manual"})]}),y.jsxs("div",{className:"flex items-center gap-2",children:[y.jsx(pU,{distUrl:j.dist_url}),s===j.version?y.jsxs("div",{className:"flex gap-1",children:[y.jsx("button",{onClick:E=>{E.stopPropagation(),d.mutate({packageName:e,version:j.version})},disabled:d.isPending,className:"px-2 py-1 text-xs bg-red-600 hover:bg-red-500 text-white rounded disabled:opacity-50",title:"Confirm delete",children:d.isPending?"...":"Delete"}),y.jsx("button",{onClick:E=>{E.stopPropagation(),f(null)},className:"px-2 py-1 text-xs bg-slate-600 hover:bg-slate-500 text-white rounded",title:"Cancel",children:"Cancel"})]}):y.jsx("button",{onClick:E=>{E.stopPropagation(),f(j.version)},className:"p-1.5 text-slate-500 hover:text-red-400 hover:bg-red-500/10 rounded transition-colors",title:"Delete this version",children:y.jsx("svg",{className:"w-4 h-4",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:y.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M19 7l-.867 12.142A2 2 0 0116.138 21H7.862a2 2 0 01-1.995-1.858L5 7m5 4v6m4-6v6m1-10V4a1 1 0 00-1-1h-4a1 1 0 00-1 1v3M4 7h16"})})})]})]},j.id)),d.isError&&y.jsx("div",{className:"p-2 bg-red-500/10 border border-red-500/30 rounded text-sm text-red-400",children:d.error instanceof Error?d.error.message:"Failed to delete"})]}),x&&!n&&y.jsx("button",{onClick:j=>{j.stopPropagation(),o(!0)},className:"mt-3 text-sm text-primary-400 hover:text-primary-300","data-testid":"show-all-versions-button","aria-label":"Show all versions",children:"Show all"})]})]})}function yU({onClose:e}){const[t,i]=C.useState("fetch"),[l,n]=C.useState(""),[o,s]=C.useState(""),[f,m]=C.useState(null),[d,p]=C.useState(!1),v=qn(),{data:b=[]}=dn({queryKey:["repositories"],queryFn:GS}),{data:x}=dn({queryKey:["settings"],queryFn:Ks}),S=C.useMemo(()=>{const X=b.filter(Q=>Q.vcs_type==="composer"&&Q.status==="active").filter(Q=>!(x?.packagist_mirroring_enabled&&Q.url==="https://repo.packagist.org")).map(Q=>({...Q,displayName:Q.url}));return x?.packagist_mirroring_enabled&&X.unshift({id:"packagist",url:"https://repo.packagist.org",vcs_type:"composer",credential_type:"none",composer_json_path:null,package_filter:null,status:"active",error_message:null,last_synced_at:null,created_at:0,displayName:"Packagist.org"}),X},[b,x]);C.useMemo(()=>{S.length>0&&!o&&s(S[0].id)},[S,o]);const w=Cn({mutationFn:R=>qC(R.repositoryId,R.packageNames),onSuccess:()=>{v.invalidateQueries({queryKey:["packages"]}),e()}}),j=Cn({mutationFn:R=>UC(R),onSuccess:()=>{v.invalidateQueries({queryKey:["packages"]}),m(null),e()}}),E=R=>{if(R.preventDefault(),t==="fetch"){const X=l.split(/[,\s\n]+/).map(Q=>Q.trim()).filter(Q=>Q.length>0);if(X.length===0||!o)return;w.mutate({repositoryId:o,packageNames:X})}else{if(!f)return;j.mutate(f)}},O=R=>{R.preventDefault(),p(!0)},N=R=>{R.preventDefault(),p(!1)},G=R=>{R.preventDefault(),p(!1);const X=Array.from(R.dataTransfer.files);if(X.length>0){const Q=X[0];Q.name.endsWith(".zip")?m(Q):alert("Please upload a ZIP file")}},J=R=>{const X=R.target.files;X&&X.length>0&&m(X[0])};return y.jsx("div",{className:"fixed inset-0 bg-black/50 backdrop-blur-sm flex items-center justify-center z-50",children:y.jsxs("div",{className:"card max-w-2xl w-full mx-4 p-6 max-h-[90vh] overflow-y-auto",children:[y.jsxs("div",{className:"flex items-center justify-between mb-6",children:[y.jsx("h3",{className:"font-display text-xl font-bold text-slate-100",children:"Add Package"}),y.jsx("button",{onClick:e,className:"text-slate-400 hover:text-slate-200",children:y.jsx(Ui,{className:"w-4 h-4"})})]}),y.jsxs("div",{className:"flex gap-2 mb-6 border-b border-slate-700",children:[y.jsx("button",{onClick:()=>i("fetch"),className:`px-4 py-2 font-medium transition-colors border-b-2 ${t==="fetch"?"border-primary-500 text-primary-400":"border-transparent text-slate-400 hover:text-slate-200"}`,children:y.jsxs("div",{className:"flex items-center gap-2",children:[y.jsx(aC,{className:"w-4 h-4"}),"Fetch from Repository"]})}),y.jsx("button",{onClick:()=>i("upload"),className:`px-4 py-2 font-medium transition-colors border-b-2 ${t==="upload"?"border-primary-500 text-primary-400":"border-transparent text-slate-400 hover:text-slate-200"}`,children:y.jsxs("div",{className:"flex items-center gap-2",children:[y.jsx(s_,{className:"w-4 h-4"}),"Upload Package"]})})]}),y.jsxs("form",{onSubmit:E,className:"space-y-4",children:[t==="fetch"?y.jsxs(y.Fragment,{children:[y.jsxs("div",{children:[y.jsx("label",{className:"label",children:"Package name(s), separated by comma, spaces or newlines"}),y.jsx("textarea",{value:l,onChange:R=>n(R.target.value),placeholder:`vendor/package1
|
|
60
|
+
vendor/package2
|
|
61
|
+
vendor/package3`,className:"input w-full min-h-[120px] resize-y font-mono text-sm",required:!0})]}),y.jsxs("div",{children:[y.jsx("label",{className:"label",children:"Mirrored Repository"}),y.jsx("select",{value:o,onChange:R=>s(R.target.value),className:"input w-full",required:!0,children:S.length===0?y.jsx("option",{value:"",children:"No repositories available"}):S.map(R=>y.jsx("option",{value:R.id,children:R.displayName},R.id))}),y.jsx("p",{className:"text-xs text-slate-500 mt-1",children:"You can set up mirrored third party repositories on the settings page."})]}),w.error&&y.jsx("div",{className:"bg-red-500/10 border border-red-500/50 rounded-lg p-3",children:y.jsx("p",{className:"text-red-400 text-sm",children:w.error.message})}),w.data&&y.jsxs("div",{className:"bg-slate-800/50 rounded-lg p-4",children:[y.jsx("p",{className:"text-slate-200 text-sm mb-2",children:w.data.message}),y.jsx("div",{className:"space-y-1 text-xs",children:w.data.results.map((R,X)=>y.jsxs("div",{className:R.success?"text-green-400":"text-red-400",children:[R.package,": ",R.success?`✓ ${R.versions} version(s) stored`:`✗ ${R.error}`]},X))})]})]}):y.jsxs(y.Fragment,{children:[y.jsxs("div",{children:[y.jsx("label",{className:"label",children:"Package Archive (ZIP)"}),y.jsxs("div",{onDragOver:O,onDragLeave:N,onDrop:G,className:`border-2 border-dashed rounded-lg p-8 text-center transition-colors ${d?"border-primary-500 bg-primary-500/10":"border-slate-700 hover:border-slate-600"}`,children:[y.jsx(s_,{className:"w-12 h-12 mx-auto mb-4 text-slate-400"}),f?y.jsxs("div",{children:[y.jsx("p",{className:"text-slate-200 font-medium mb-1",children:f.name}),y.jsxs("p",{className:"text-slate-400 text-sm mb-4",children:[(f.size/1024/1024).toFixed(2)," MB"]}),y.jsx("button",{type:"button",onClick:()=>m(null),className:"text-primary-400 hover:text-primary-300 text-sm",children:"Choose different file"})]}):y.jsxs("div",{children:[y.jsx("p",{className:"text-slate-200 mb-2",children:"Drag and drop a ZIP file here, or click to browse"}),y.jsx("input",{type:"file",accept:".zip",onChange:J,className:"hidden",id:"file-upload"}),y.jsx("label",{htmlFor:"file-upload",className:"inline-block px-4 py-2 bg-slate-700 hover:bg-slate-600 rounded-lg cursor-pointer text-sm",children:"Browse Files"}),y.jsx("p",{className:"text-slate-500 text-xs mt-2",children:"Maximum file size: 100MB"})]})]}),y.jsx("p",{className:"text-xs text-slate-500 mt-2",children:"The ZIP archive must contain a valid composer.json file in the root or first-level directory."})]}),j.error&&y.jsx("div",{className:"bg-red-500/10 border border-red-500/50 rounded-lg p-3",children:y.jsx("p",{className:"text-red-400 text-sm whitespace-pre-wrap",children:j.error.message})})]}),y.jsxs("div",{className:"flex justify-end gap-3 pt-4",children:[y.jsx("button",{type:"button",onClick:e,className:"btn-secondary",children:"Cancel"}),y.jsx("button",{type:"submit",className:"btn-primary",disabled:t==="fetch"?w.isPending||S.length===0:j.isPending||!f,children:t==="fetch"?w.isPending?"Adding...":"Add":j.isPending?"Uploading...":"Upload"})]})]})]})})}function bU(e,t){const i={};return(e[e.length-1]===""?[...e,""]:e).join((i.padRight?" ":"")+","+(i.padLeft===!1?"":" ")).trim()}const xU=/^[$_\p{ID_Start}][$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,_U=/^[$_\p{ID_Start}][-$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,SU={};function _1(e,t){return(SU.jsx?_U:xU).test(e)}const kU=/[ \t\n\f\r]/g;function wU(e){return typeof e=="object"?e.type==="text"?S1(e.value):!1:S1(e)}function S1(e){return e.replace(kU,"")===""}class Qo{constructor(t,i,l){this.normal=i,this.property=t,l&&(this.space=l)}}Qo.prototype.normal={};Qo.prototype.property={};Qo.prototype.space=void 0;function Q4(e,t){const i={},l={};for(const n of e)Object.assign(i,n.property),Object.assign(l,n.normal);return new Qo(i,l,t)}function tp(e){return e.toLowerCase()}class tn{constructor(t,i){this.attribute=i,this.property=t}}tn.prototype.attribute="";tn.prototype.booleanish=!1;tn.prototype.boolean=!1;tn.prototype.commaOrSpaceSeparated=!1;tn.prototype.commaSeparated=!1;tn.prototype.defined=!1;tn.prototype.mustUseProperty=!1;tn.prototype.number=!1;tn.prototype.overloadedBoolean=!1;tn.prototype.property="";tn.prototype.spaceSeparated=!1;tn.prototype.space=void 0;let $U=0;const Oe=Hi(),_t=Hi(),np=Hi(),le=Hi(),rt=Hi(),Pa=Hi(),fn=Hi();function Hi(){return 2**++$U}const rp=Object.freeze(Object.defineProperty({__proto__:null,boolean:Oe,booleanish:_t,commaOrSpaceSeparated:fn,commaSeparated:Pa,number:le,overloadedBoolean:np,spaceSeparated:rt},Symbol.toStringTag,{value:"Module"})),xh=Object.keys(rp);class xv extends tn{constructor(t,i,l,n){let o=-1;if(super(t,i),k1(this,"space",n),typeof l=="number")for(;++o<xh.length;){const s=xh[o];k1(this,xh[o],(l&rp[s])===rp[s])}}}xv.prototype.defined=!0;function k1(e,t,i){i&&(e[t]=i)}function il(e){const t={},i={};for(const[l,n]of Object.entries(e.properties)){const o=new xv(l,e.transform(e.attributes||{},l),n,e.space);e.mustUseProperty&&e.mustUseProperty.includes(l)&&(o.mustUseProperty=!0),t[l]=o,i[tp(l)]=l,i[tp(o.attribute)]=l}return new Qo(t,i,e.space)}const K4=il({properties:{ariaActiveDescendant:null,ariaAtomic:_t,ariaAutoComplete:null,ariaBusy:_t,ariaChecked:_t,ariaColCount:le,ariaColIndex:le,ariaColSpan:le,ariaControls:rt,ariaCurrent:null,ariaDescribedBy:rt,ariaDetails:null,ariaDisabled:_t,ariaDropEffect:rt,ariaErrorMessage:null,ariaExpanded:_t,ariaFlowTo:rt,ariaGrabbed:_t,ariaHasPopup:null,ariaHidden:_t,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:rt,ariaLevel:le,ariaLive:null,ariaModal:_t,ariaMultiLine:_t,ariaMultiSelectable:_t,ariaOrientation:null,ariaOwns:rt,ariaPlaceholder:null,ariaPosInSet:le,ariaPressed:_t,ariaReadOnly:_t,ariaRelevant:null,ariaRequired:_t,ariaRoleDescription:rt,ariaRowCount:le,ariaRowIndex:le,ariaRowSpan:le,ariaSelected:_t,ariaSetSize:le,ariaSort:null,ariaValueMax:le,ariaValueMin:le,ariaValueNow:le,ariaValueText:null,role:null},transform(e,t){return t==="role"?t:"aria-"+t.slice(4).toLowerCase()}});function W4(e,t){return t in e?e[t]:t}function ez(e,t){return W4(e,t.toLowerCase())}const EU=il({attributes:{acceptcharset:"accept-charset",classname:"class",htmlfor:"for",httpequiv:"http-equiv"},mustUseProperty:["checked","multiple","muted","selected"],properties:{abbr:null,accept:Pa,acceptCharset:rt,accessKey:rt,action:null,allow:null,allowFullScreen:Oe,allowPaymentRequest:Oe,allowUserMedia:Oe,alt:null,as:null,async:Oe,autoCapitalize:null,autoComplete:rt,autoFocus:Oe,autoPlay:Oe,blocking:rt,capture:null,charSet:null,checked:Oe,cite:null,className:rt,cols:le,colSpan:null,content:null,contentEditable:_t,controls:Oe,controlsList:rt,coords:le|Pa,crossOrigin:null,data:null,dateTime:null,decoding:null,default:Oe,defer:Oe,dir:null,dirName:null,disabled:Oe,download:np,draggable:_t,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:Oe,formTarget:null,headers:rt,height:le,hidden:np,high:le,href:null,hrefLang:null,htmlFor:rt,httpEquiv:rt,id:null,imageSizes:null,imageSrcSet:null,inert:Oe,inputMode:null,integrity:null,is:null,isMap:Oe,itemId:null,itemProp:rt,itemRef:rt,itemScope:Oe,itemType:rt,kind:null,label:null,lang:null,language:null,list:null,loading:null,loop:Oe,low:le,manifest:null,max:null,maxLength:le,media:null,method:null,min:null,minLength:le,multiple:Oe,muted:Oe,name:null,nonce:null,noModule:Oe,noValidate:Oe,onAbort:null,onAfterPrint:null,onAuxClick:null,onBeforeMatch:null,onBeforePrint:null,onBeforeToggle:null,onBeforeUnload:null,onBlur:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onContextLost:null,onContextMenu:null,onContextRestored:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnded:null,onError:null,onFocus:null,onFormData:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLanguageChange:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadEnd:null,onLoadStart:null,onMessage:null,onMessageError:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRejectionHandled:null,onReset:null,onResize:null,onScroll:null,onScrollEnd:null,onSecurityPolicyViolation:null,onSeeked:null,onSeeking:null,onSelect:null,onSlotChange:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnhandledRejection:null,onUnload:null,onVolumeChange:null,onWaiting:null,onWheel:null,open:Oe,optimum:le,pattern:null,ping:rt,placeholder:null,playsInline:Oe,popover:null,popoverTarget:null,popoverTargetAction:null,poster:null,preload:null,readOnly:Oe,referrerPolicy:null,rel:rt,required:Oe,reversed:Oe,rows:le,rowSpan:le,sandbox:rt,scope:null,scoped:Oe,seamless:Oe,selected:Oe,shadowRootClonable:Oe,shadowRootDelegatesFocus:Oe,shadowRootMode:null,shape:null,size:le,sizes:null,slot:null,span:le,spellCheck:_t,src:null,srcDoc:null,srcLang:null,srcSet:null,start:le,step:null,style:null,tabIndex:le,target:null,title:null,translate:null,type:null,typeMustMatch:Oe,useMap:null,value:_t,width:le,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:rt,axis:null,background:null,bgColor:null,border:le,borderColor:null,bottomMargin:le,cellPadding:null,cellSpacing:null,char:null,charOff:null,classId:null,clear:null,code:null,codeBase:null,codeType:null,color:null,compact:Oe,declare:Oe,event:null,face:null,frame:null,frameBorder:null,hSpace:le,leftMargin:le,link:null,longDesc:null,lowSrc:null,marginHeight:le,marginWidth:le,noResize:Oe,noHref:Oe,noShade:Oe,noWrap:Oe,object:null,profile:null,prompt:null,rev:null,rightMargin:le,rules:null,scheme:null,scrolling:_t,standby:null,summary:null,text:null,topMargin:le,valueType:null,version:null,vAlign:null,vLink:null,vSpace:le,allowTransparency:null,autoCorrect:null,autoSave:null,disablePictureInPicture:Oe,disableRemotePlayback:Oe,prefix:null,property:null,results:le,security:null,unselectable:null},space:"html",transform:ez}),jU=il({attributes:{accentHeight:"accent-height",alignmentBaseline:"alignment-baseline",arabicForm:"arabic-form",baselineShift:"baseline-shift",capHeight:"cap-height",className:"class",clipPath:"clip-path",clipRule:"clip-rule",colorInterpolation:"color-interpolation",colorInterpolationFilters:"color-interpolation-filters",colorProfile:"color-profile",colorRendering:"color-rendering",crossOrigin:"crossorigin",dataType:"datatype",dominantBaseline:"dominant-baseline",enableBackground:"enable-background",fillOpacity:"fill-opacity",fillRule:"fill-rule",floodColor:"flood-color",floodOpacity:"flood-opacity",fontFamily:"font-family",fontSize:"font-size",fontSizeAdjust:"font-size-adjust",fontStretch:"font-stretch",fontStyle:"font-style",fontVariant:"font-variant",fontWeight:"font-weight",glyphName:"glyph-name",glyphOrientationHorizontal:"glyph-orientation-horizontal",glyphOrientationVertical:"glyph-orientation-vertical",hrefLang:"hreflang",horizAdvX:"horiz-adv-x",horizOriginX:"horiz-origin-x",horizOriginY:"horiz-origin-y",imageRendering:"image-rendering",letterSpacing:"letter-spacing",lightingColor:"lighting-color",markerEnd:"marker-end",markerMid:"marker-mid",markerStart:"marker-start",navDown:"nav-down",navDownLeft:"nav-down-left",navDownRight:"nav-down-right",navLeft:"nav-left",navNext:"nav-next",navPrev:"nav-prev",navRight:"nav-right",navUp:"nav-up",navUpLeft:"nav-up-left",navUpRight:"nav-up-right",onAbort:"onabort",onActivate:"onactivate",onAfterPrint:"onafterprint",onBeforePrint:"onbeforeprint",onBegin:"onbegin",onCancel:"oncancel",onCanPlay:"oncanplay",onCanPlayThrough:"oncanplaythrough",onChange:"onchange",onClick:"onclick",onClose:"onclose",onCopy:"oncopy",onCueChange:"oncuechange",onCut:"oncut",onDblClick:"ondblclick",onDrag:"ondrag",onDragEnd:"ondragend",onDragEnter:"ondragenter",onDragExit:"ondragexit",onDragLeave:"ondragleave",onDragOver:"ondragover",onDragStart:"ondragstart",onDrop:"ondrop",onDurationChange:"ondurationchange",onEmptied:"onemptied",onEnd:"onend",onEnded:"onended",onError:"onerror",onFocus:"onfocus",onFocusIn:"onfocusin",onFocusOut:"onfocusout",onHashChange:"onhashchange",onInput:"oninput",onInvalid:"oninvalid",onKeyDown:"onkeydown",onKeyPress:"onkeypress",onKeyUp:"onkeyup",onLoad:"onload",onLoadedData:"onloadeddata",onLoadedMetadata:"onloadedmetadata",onLoadStart:"onloadstart",onMessage:"onmessage",onMouseDown:"onmousedown",onMouseEnter:"onmouseenter",onMouseLeave:"onmouseleave",onMouseMove:"onmousemove",onMouseOut:"onmouseout",onMouseOver:"onmouseover",onMouseUp:"onmouseup",onMouseWheel:"onmousewheel",onOffline:"onoffline",onOnline:"ononline",onPageHide:"onpagehide",onPageShow:"onpageshow",onPaste:"onpaste",onPause:"onpause",onPlay:"onplay",onPlaying:"onplaying",onPopState:"onpopstate",onProgress:"onprogress",onRateChange:"onratechange",onRepeat:"onrepeat",onReset:"onreset",onResize:"onresize",onScroll:"onscroll",onSeeked:"onseeked",onSeeking:"onseeking",onSelect:"onselect",onShow:"onshow",onStalled:"onstalled",onStorage:"onstorage",onSubmit:"onsubmit",onSuspend:"onsuspend",onTimeUpdate:"ontimeupdate",onToggle:"ontoggle",onUnload:"onunload",onVolumeChange:"onvolumechange",onWaiting:"onwaiting",onZoom:"onzoom",overlinePosition:"overline-position",overlineThickness:"overline-thickness",paintOrder:"paint-order",panose1:"panose-1",pointerEvents:"pointer-events",referrerPolicy:"referrerpolicy",renderingIntent:"rendering-intent",shapeRendering:"shape-rendering",stopColor:"stop-color",stopOpacity:"stop-opacity",strikethroughPosition:"strikethrough-position",strikethroughThickness:"strikethrough-thickness",strokeDashArray:"stroke-dasharray",strokeDashOffset:"stroke-dashoffset",strokeLineCap:"stroke-linecap",strokeLineJoin:"stroke-linejoin",strokeMiterLimit:"stroke-miterlimit",strokeOpacity:"stroke-opacity",strokeWidth:"stroke-width",tabIndex:"tabindex",textAnchor:"text-anchor",textDecoration:"text-decoration",textRendering:"text-rendering",transformOrigin:"transform-origin",typeOf:"typeof",underlinePosition:"underline-position",underlineThickness:"underline-thickness",unicodeBidi:"unicode-bidi",unicodeRange:"unicode-range",unitsPerEm:"units-per-em",vAlphabetic:"v-alphabetic",vHanging:"v-hanging",vIdeographic:"v-ideographic",vMathematical:"v-mathematical",vectorEffect:"vector-effect",vertAdvY:"vert-adv-y",vertOriginX:"vert-origin-x",vertOriginY:"vert-origin-y",wordSpacing:"word-spacing",writingMode:"writing-mode",xHeight:"x-height",playbackOrder:"playbackorder",timelineBegin:"timelinebegin"},properties:{about:fn,accentHeight:le,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:le,amplitude:le,arabicForm:null,ascent:le,attributeName:null,attributeType:null,azimuth:le,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:le,by:null,calcMode:null,capHeight:le,className:rt,clip:null,clipPath:null,clipPathUnits:null,clipRule:null,color:null,colorInterpolation:null,colorInterpolationFilters:null,colorProfile:null,colorRendering:null,content:null,contentScriptType:null,contentStyleType:null,crossOrigin:null,cursor:null,cx:null,cy:null,d:null,dataType:null,defaultAction:null,descent:le,diffuseConstant:le,direction:null,display:null,dur:null,divisor:le,dominantBaseline:null,download:Oe,dx:null,dy:null,edgeMode:null,editable:null,elevation:le,enableBackground:null,end:null,event:null,exponent:le,externalResourcesRequired:null,fill:null,fillOpacity:le,fillRule:null,filter:null,filterRes:null,filterUnits:null,floodColor:null,floodOpacity:null,focusable:null,focusHighlight:null,fontFamily:null,fontSize:null,fontSizeAdjust:null,fontStretch:null,fontStyle:null,fontVariant:null,fontWeight:null,format:null,fr:null,from:null,fx:null,fy:null,g1:Pa,g2:Pa,glyphName:Pa,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:le,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:le,horizOriginX:le,horizOriginY:le,id:null,ideographic:le,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:le,k:le,k1:le,k2:le,k3:le,k4:le,kernelMatrix:fn,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:le,local:null,markerEnd:null,markerMid:null,markerStart:null,markerHeight:null,markerUnits:null,markerWidth:null,mask:null,maskContentUnits:null,maskUnits:null,mathematical:null,max:null,media:null,mediaCharacterEncoding:null,mediaContentEncodings:null,mediaSize:le,mediaTime:null,method:null,min:null,mode:null,name:null,navDown:null,navDownLeft:null,navDownRight:null,navLeft:null,navNext:null,navPrev:null,navRight:null,navUp:null,navUpLeft:null,navUpRight:null,numOctaves:null,observer:null,offset:null,onAbort:null,onActivate:null,onAfterPrint:null,onBeforePrint:null,onBegin:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnd:null,onEnded:null,onError:null,onFocus:null,onFocusIn:null,onFocusOut:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadStart:null,onMessage:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onMouseWheel:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRepeat:null,onReset:null,onResize:null,onScroll:null,onSeeked:null,onSeeking:null,onSelect:null,onShow:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnload:null,onVolumeChange:null,onWaiting:null,onZoom:null,opacity:null,operator:null,order:null,orient:null,orientation:null,origin:null,overflow:null,overlay:null,overlinePosition:le,overlineThickness:le,paintOrder:null,panose1:null,path:null,pathLength:le,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:rt,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:le,pointsAtY:le,pointsAtZ:le,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:fn,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:fn,rev:fn,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:fn,requiredFeatures:fn,requiredFonts:fn,requiredFormats:fn,resource:null,restart:null,result:null,rotate:null,rx:null,ry:null,scale:null,seed:null,shapeRendering:null,side:null,slope:null,snapshotTime:null,specularConstant:le,specularExponent:le,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:le,strikethroughThickness:le,string:null,stroke:null,strokeDashArray:fn,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:le,strokeOpacity:le,strokeWidth:null,style:null,surfaceScale:le,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:fn,tabIndex:le,tableValues:null,target:null,targetX:le,targetY:le,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:fn,to:null,transform:null,transformOrigin:null,u1:null,u2:null,underlinePosition:le,underlineThickness:le,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:le,values:null,vAlphabetic:le,vMathematical:le,vectorEffect:null,vHanging:le,vIdeographic:le,version:null,vertAdvY:le,vertOriginX:le,vertOriginY:le,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:le,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null},space:"svg",transform:W4}),tz=il({properties:{xLinkActuate:null,xLinkArcRole:null,xLinkHref:null,xLinkRole:null,xLinkShow:null,xLinkTitle:null,xLinkType:null},space:"xlink",transform(e,t){return"xlink:"+t.slice(5).toLowerCase()}}),nz=il({attributes:{xmlnsxlink:"xmlns:xlink"},properties:{xmlnsXLink:null,xmlns:null},space:"xmlns",transform:ez}),rz=il({properties:{xmlBase:null,xmlLang:null,xmlSpace:null},space:"xml",transform(e,t){return"xml:"+t.slice(3).toLowerCase()}}),zU={classId:"classID",dataType:"datatype",itemId:"itemID",strokeDashArray:"strokeDasharray",strokeDashOffset:"strokeDashoffset",strokeLineCap:"strokeLinecap",strokeLineJoin:"strokeLinejoin",strokeMiterLimit:"strokeMiterlimit",typeOf:"typeof",xLinkActuate:"xlinkActuate",xLinkArcRole:"xlinkArcrole",xLinkHref:"xlinkHref",xLinkRole:"xlinkRole",xLinkShow:"xlinkShow",xLinkTitle:"xlinkTitle",xLinkType:"xlinkType",xmlnsXLink:"xmlnsXlink"},NU=/[A-Z]/g,w1=/-[a-z]/g,OU=/^data[-\w.:]+$/i;function TU(e,t){const i=tp(t);let l=t,n=tn;if(i in e.normal)return e.property[e.normal[i]];if(i.length>4&&i.slice(0,4)==="data"&&OU.test(t)){if(t.charAt(4)==="-"){const o=t.slice(5).replace(w1,DU);l="data"+o.charAt(0).toUpperCase()+o.slice(1)}else{const o=t.slice(4);if(!w1.test(o)){let s=o.replace(NU,CU);s.charAt(0)!=="-"&&(s="-"+s),t="data"+s}}n=xv}return new n(l,t)}function CU(e){return"-"+e.toLowerCase()}function DU(e){return e.charAt(1).toUpperCase()}const AU=Q4([K4,EU,tz,nz,rz],"html"),_v=Q4([K4,jU,tz,nz,rz],"svg");function RU(e){return e.join(" ").trim()}var Ia={},_h,$1;function IU(){if($1)return _h;$1=1;var e=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,t=/\n/g,i=/^\s*/,l=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,n=/^:\s*/,o=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,s=/^[;\s]*/,f=/^\s+|\s+$/g,m=`
|
|
62
|
+
`,d="/",p="*",v="",b="comment",x="declaration";function S(j,E){if(typeof j!="string")throw new TypeError("First argument must be a string");if(!j)return[];E=E||{};var O=1,N=1;function G(M){var U=M.match(t);U&&(O+=U.length);var A=M.lastIndexOf(m);N=~A?M.length-A:N+M.length}function J(){var M={line:O,column:N};return function(U){return U.position=new R(M),me(),U}}function R(M){this.start=M,this.end={line:O,column:N},this.source=E.source}R.prototype.content=j;function X(M){var U=new Error(E.source+":"+O+":"+N+": "+M);if(U.reason=M,U.filename=E.source,U.line=O,U.column=N,U.source=j,!E.silent)throw U}function Q(M){var U=M.exec(j);if(U){var A=U[0];return G(A),j=j.slice(A.length),U}}function me(){Q(i)}function B(M){var U;for(M=M||[];U=ue();)U!==!1&&M.push(U);return M}function ue(){var M=J();if(!(d!=j.charAt(0)||p!=j.charAt(1))){for(var U=2;v!=j.charAt(U)&&(p!=j.charAt(U)||d!=j.charAt(U+1));)++U;if(U+=2,v===j.charAt(U-1))return X("End of comment missing");var A=j.slice(2,U-2);return N+=2,G(A),j=j.slice(U),N+=2,M({type:b,comment:A})}}function ce(){var M=J(),U=Q(l);if(U){if(ue(),!Q(n))return X("property missing ':'");var A=Q(o),q=M({type:x,property:w(U[0].replace(e,v)),value:A?w(A[0].replace(e,v)):v});return Q(s),q}}function ke(){var M=[];B(M);for(var U;U=ce();)U!==!1&&(M.push(U),B(M));return M}return me(),ke()}function w(j){return j?j.replace(f,v):v}return _h=S,_h}var E1;function UU(){if(E1)return Ia;E1=1;var e=Ia&&Ia.__importDefault||function(l){return l&&l.__esModule?l:{default:l}};Object.defineProperty(Ia,"__esModule",{value:!0}),Ia.default=i;const t=e(IU());function i(l,n){let o=null;if(!l||typeof l!="string")return o;const s=(0,t.default)(l),f=typeof n=="function";return s.forEach(m=>{if(m.type!=="declaration")return;const{property:d,value:p}=m;f?n(d,p,m):p&&(o=o||{},o[d]=p)}),o}return Ia}var ro={},j1;function LU(){if(j1)return ro;j1=1,Object.defineProperty(ro,"__esModule",{value:!0}),ro.camelCase=void 0;var e=/^--[a-zA-Z0-9_-]+$/,t=/-([a-z])/g,i=/^[^-]+$/,l=/^-(webkit|moz|ms|o|khtml)-/,n=/^-(ms)-/,o=function(d){return!d||i.test(d)||e.test(d)},s=function(d,p){return p.toUpperCase()},f=function(d,p){return"".concat(p,"-")},m=function(d,p){return p===void 0&&(p={}),o(d)?d:(d=d.toLowerCase(),p.reactCompat?d=d.replace(n,f):d=d.replace(l,f),d.replace(t,s))};return ro.camelCase=m,ro}var io,z1;function MU(){if(z1)return io;z1=1;var e=io&&io.__importDefault||function(n){return n&&n.__esModule?n:{default:n}},t=e(UU()),i=LU();function l(n,o){var s={};return!n||typeof n!="string"||(0,t.default)(n,function(f,m){f&&m&&(s[(0,i.camelCase)(f,o)]=m)}),s}return l.default=l,io=l,io}var PU=MU();const ZU=_o(PU),iz=az("end"),Sv=az("start");function az(e){return t;function t(i){const l=i&&i.position&&i.position[e]||{};if(typeof l.line=="number"&&l.line>0&&typeof l.column=="number"&&l.column>0)return{line:l.line,column:l.column,offset:typeof l.offset=="number"&&l.offset>-1?l.offset:void 0}}}function qU(e){const t=Sv(e),i=iz(e);if(t&&i)return{start:t,end:i}}function uo(e){return!e||typeof e!="object"?"":"position"in e||"type"in e?N1(e.position):"start"in e||"end"in e?N1(e):"line"in e||"column"in e?ip(e):""}function ip(e){return O1(e&&e.line)+":"+O1(e&&e.column)}function N1(e){return ip(e&&e.start)+"-"+ip(e&&e.end)}function O1(e){return e&&typeof e=="number"?e:1}class Ut extends Error{constructor(t,i,l){super(),typeof i=="string"&&(l=i,i=void 0);let n="",o={},s=!1;if(i&&("line"in i&&"column"in i?o={place:i}:"start"in i&&"end"in i?o={place:i}:"type"in i?o={ancestors:[i],place:i.position}:o={...i}),typeof t=="string"?n=t:!o.cause&&t&&(s=!0,n=t.message,o.cause=t),!o.ruleId&&!o.source&&typeof l=="string"){const m=l.indexOf(":");m===-1?o.ruleId=l:(o.source=l.slice(0,m),o.ruleId=l.slice(m+1))}if(!o.place&&o.ancestors&&o.ancestors){const m=o.ancestors[o.ancestors.length-1];m&&(o.place=m.position)}const f=o.place&&"start"in o.place?o.place.start:o.place;this.ancestors=o.ancestors||void 0,this.cause=o.cause||void 0,this.column=f?f.column:void 0,this.fatal=void 0,this.file="",this.message=n,this.line=f?f.line:void 0,this.name=uo(o.place)||"1:1",this.place=o.place||void 0,this.reason=this.message,this.ruleId=o.ruleId||void 0,this.source=o.source||void 0,this.stack=s&&o.cause&&typeof o.cause.stack=="string"?o.cause.stack:"",this.actual=void 0,this.expected=void 0,this.note=void 0,this.url=void 0}}Ut.prototype.file="";Ut.prototype.name="";Ut.prototype.reason="";Ut.prototype.message="";Ut.prototype.stack="";Ut.prototype.column=void 0;Ut.prototype.line=void 0;Ut.prototype.ancestors=void 0;Ut.prototype.cause=void 0;Ut.prototype.fatal=void 0;Ut.prototype.place=void 0;Ut.prototype.ruleId=void 0;Ut.prototype.source=void 0;const kv={}.hasOwnProperty,FU=new Map,BU=/[A-Z]/g,HU=new Set(["table","tbody","thead","tfoot","tr"]),GU=new Set(["td","th"]),lz="https://github.com/syntax-tree/hast-util-to-jsx-runtime";function VU(e,t){if(!t||t.Fragment===void 0)throw new TypeError("Expected `Fragment` in options");const i=t.filePath||void 0;let l;if(t.development){if(typeof t.jsxDEV!="function")throw new TypeError("Expected `jsxDEV` in options when `development: true`");l=t3(i,t.jsxDEV)}else{if(typeof t.jsx!="function")throw new TypeError("Expected `jsx` in production options");if(typeof t.jsxs!="function")throw new TypeError("Expected `jsxs` in production options");l=e3(i,t.jsx,t.jsxs)}const n={Fragment:t.Fragment,ancestors:[],components:t.components||{},create:l,elementAttributeNameCase:t.elementAttributeNameCase||"react",evaluater:t.createEvaluater?t.createEvaluater():void 0,filePath:i,ignoreInvalidStyle:t.ignoreInvalidStyle||!1,passKeys:t.passKeys!==!1,passNode:t.passNode||!1,schema:t.space==="svg"?_v:AU,stylePropertyNameCase:t.stylePropertyNameCase||"dom",tableCellAlignToStyle:t.tableCellAlignToStyle!==!1},o=oz(n,e,void 0);return o&&typeof o!="string"?o:n.create(e,n.Fragment,{children:o||void 0},void 0)}function oz(e,t,i){if(t.type==="element")return YU(e,t,i);if(t.type==="mdxFlowExpression"||t.type==="mdxTextExpression")return JU(e,t);if(t.type==="mdxJsxFlowElement"||t.type==="mdxJsxTextElement")return QU(e,t,i);if(t.type==="mdxjsEsm")return XU(e,t);if(t.type==="root")return KU(e,t,i);if(t.type==="text")return WU(e,t)}function YU(e,t,i){const l=e.schema;let n=l;t.tagName.toLowerCase()==="svg"&&l.space==="html"&&(n=_v,e.schema=n),e.ancestors.push(t);const o=sz(e,t.tagName,!1),s=n3(e,t);let f=$v(e,t);return HU.has(t.tagName)&&(f=f.filter(function(m){return typeof m=="string"?!wU(m):!0})),uz(e,s,o,t),wv(s,f),e.ancestors.pop(),e.schema=l,e.create(t,o,s,i)}function JU(e,t){if(t.data&&t.data.estree&&e.evaluater){const l=t.data.estree.body[0];return l.type,e.evaluater.evaluateExpression(l.expression)}bo(e,t.position)}function XU(e,t){if(t.data&&t.data.estree&&e.evaluater)return e.evaluater.evaluateProgram(t.data.estree);bo(e,t.position)}function QU(e,t,i){const l=e.schema;let n=l;t.name==="svg"&&l.space==="html"&&(n=_v,e.schema=n),e.ancestors.push(t);const o=t.name===null?e.Fragment:sz(e,t.name,!0),s=r3(e,t),f=$v(e,t);return uz(e,s,o,t),wv(s,f),e.ancestors.pop(),e.schema=l,e.create(t,o,s,i)}function KU(e,t,i){const l={};return wv(l,$v(e,t)),e.create(t,e.Fragment,l,i)}function WU(e,t){return t.value}function uz(e,t,i,l){typeof i!="string"&&i!==e.Fragment&&e.passNode&&(t.node=l)}function wv(e,t){if(t.length>0){const i=t.length>1?t:t[0];i&&(e.children=i)}}function e3(e,t,i){return l;function l(n,o,s,f){const d=Array.isArray(s.children)?i:t;return f?d(o,s,f):d(o,s)}}function t3(e,t){return i;function i(l,n,o,s){const f=Array.isArray(o.children),m=Sv(l);return t(n,o,s,f,{columnNumber:m?m.column-1:void 0,fileName:e,lineNumber:m?m.line:void 0},void 0)}}function n3(e,t){const i={};let l,n;for(n in t.properties)if(n!=="children"&&kv.call(t.properties,n)){const o=i3(e,n,t.properties[n]);if(o){const[s,f]=o;e.tableCellAlignToStyle&&s==="align"&&typeof f=="string"&&GU.has(t.tagName)?l=f:i[s]=f}}if(l){const o=i.style||(i.style={});o[e.stylePropertyNameCase==="css"?"text-align":"textAlign"]=l}return i}function r3(e,t){const i={};for(const l of t.attributes)if(l.type==="mdxJsxExpressionAttribute")if(l.data&&l.data.estree&&e.evaluater){const o=l.data.estree.body[0];o.type;const s=o.expression;s.type;const f=s.properties[0];f.type,Object.assign(i,e.evaluater.evaluateExpression(f.argument))}else bo(e,t.position);else{const n=l.name;let o;if(l.value&&typeof l.value=="object")if(l.value.data&&l.value.data.estree&&e.evaluater){const f=l.value.data.estree.body[0];f.type,o=e.evaluater.evaluateExpression(f.expression)}else bo(e,t.position);else o=l.value===null?!0:l.value;i[n]=o}return i}function $v(e,t){const i=[];let l=-1;const n=e.passKeys?new Map:FU;for(;++l<t.children.length;){const o=t.children[l];let s;if(e.passKeys){const m=o.type==="element"?o.tagName:o.type==="mdxJsxFlowElement"||o.type==="mdxJsxTextElement"?o.name:void 0;if(m){const d=n.get(m)||0;s=m+"-"+d,n.set(m,d+1)}}const f=oz(e,o,s);f!==void 0&&i.push(f)}return i}function i3(e,t,i){const l=TU(e.schema,t);if(!(i==null||typeof i=="number"&&Number.isNaN(i))){if(Array.isArray(i)&&(i=l.commaSeparated?bU(i):RU(i)),l.property==="style"){let n=typeof i=="object"?i:a3(e,String(i));return e.stylePropertyNameCase==="css"&&(n=l3(n)),["style",n]}return[e.elementAttributeNameCase==="react"&&l.space?zU[l.property]||l.property:l.attribute,i]}}function a3(e,t){try{return ZU(t,{reactCompat:!0})}catch(i){if(e.ignoreInvalidStyle)return{};const l=i,n=new Ut("Cannot parse `style` attribute",{ancestors:e.ancestors,cause:l,ruleId:"style",source:"hast-util-to-jsx-runtime"});throw n.file=e.filePath||void 0,n.url=lz+"#cannot-parse-style-attribute",n}}function sz(e,t,i){let l;if(!i)l={type:"Literal",value:t};else if(t.includes(".")){const n=t.split(".");let o=-1,s;for(;++o<n.length;){const f=_1(n[o])?{type:"Identifier",name:n[o]}:{type:"Literal",value:n[o]};s=s?{type:"MemberExpression",object:s,property:f,computed:!!(o&&f.type==="Literal"),optional:!1}:f}l=s}else l=_1(t)&&!/^[a-z]/.test(t)?{type:"Identifier",name:t}:{type:"Literal",value:t};if(l.type==="Literal"){const n=l.value;return kv.call(e.components,n)?e.components[n]:n}if(e.evaluater)return e.evaluater.evaluateExpression(l);bo(e)}function bo(e,t){const i=new Ut("Cannot handle MDX estrees without `createEvaluater`",{ancestors:e.ancestors,place:t,ruleId:"mdx-estree",source:"hast-util-to-jsx-runtime"});throw i.file=e.filePath||void 0,i.url=lz+"#cannot-handle-mdx-estrees-without-createevaluater",i}function l3(e){const t={};let i;for(i in e)kv.call(e,i)&&(t[o3(i)]=e[i]);return t}function o3(e){let t=e.replace(BU,u3);return t.slice(0,3)==="ms-"&&(t="-"+t),t}function u3(e){return"-"+e.toLowerCase()}const Sh={action:["form"],cite:["blockquote","del","ins","q"],data:["object"],formAction:["button","input"],href:["a","area","base","link"],icon:["menuitem"],itemId:null,manifest:["html"],ping:["a","area"],poster:["video"],src:["audio","embed","iframe","img","input","script","source","track","video"]},s3={};function Ev(e,t){const i=s3,l=typeof i.includeImageAlt=="boolean"?i.includeImageAlt:!0,n=typeof i.includeHtml=="boolean"?i.includeHtml:!0;return cz(e,l,n)}function cz(e,t,i){if(c3(e)){if("value"in e)return e.type==="html"&&!i?"":e.value;if(t&&"alt"in e&&e.alt)return e.alt;if("children"in e)return T1(e.children,t,i)}return Array.isArray(e)?T1(e,t,i):""}function T1(e,t,i){const l=[];let n=-1;for(;++n<e.length;)l[n]=cz(e[n],t,i);return l.join("")}function c3(e){return!!(e&&typeof e=="object")}const C1=document.createElement("i");function jv(e){const t="&"+e+";";C1.innerHTML=t;const i=C1.textContent;return i.charCodeAt(i.length-1)===59&&e!=="semi"||i===t?!1:i}function mn(e,t,i,l){const n=e.length;let o=0,s;if(t<0?t=-t>n?0:n+t:t=t>n?n:t,i=i>0?i:0,l.length<1e4)s=Array.from(l),s.unshift(t,i),e.splice(...s);else for(i&&e.splice(t,i);o<l.length;)s=l.slice(o,o+1e4),s.unshift(t,0),e.splice(...s),o+=1e4,t+=1e4}function zn(e,t){return e.length>0?(mn(e,e.length,0,t),e):t}const D1={}.hasOwnProperty;function fz(e){const t={};let i=-1;for(;++i<e.length;)f3(t,e[i]);return t}function f3(e,t){let i;for(i in t){const n=(D1.call(e,i)?e[i]:void 0)||(e[i]={}),o=t[i];let s;if(o)for(s in o){D1.call(n,s)||(n[s]=[]);const f=o[s];d3(n[s],Array.isArray(f)?f:f?[f]:[])}}}function d3(e,t){let i=-1;const l=[];for(;++i<t.length;)(t[i].add==="after"?e:l).push(t[i]);mn(e,0,0,l)}function dz(e,t){const i=Number.parseInt(e,t);return i<9||i===11||i>13&&i<32||i>126&&i<160||i>55295&&i<57344||i>64975&&i<65008||(i&65535)===65535||(i&65535)===65534||i>1114111?"�":String.fromCodePoint(i)}function Zn(e){return e.replace(/[\t\n\r ]+/g," ").replace(/^ | $/g,"").toLowerCase().toUpperCase()}const Ft=fi(/[A-Za-z]/),Rt=fi(/[\dA-Za-z]/),m3=fi(/[#-'*+\--9=?A-Z^-~]/);function Hs(e){return e!==null&&(e<32||e===127)}const ap=fi(/\d/),h3=fi(/[\dA-Fa-f]/),p3=fi(/[!-/:-@[-`{-~]/);function ye(e){return e!==null&&e<-2}function We(e){return e!==null&&(e<0||e===32)}function Re(e){return e===-2||e===-1||e===32}const Qc=fi(new RegExp("\\p{P}|\\p{S}","u")),Zi=fi(/\s/);function fi(e){return t;function t(i){return i!==null&&i>-1&&e.test(String.fromCharCode(i))}}function al(e){const t=[];let i=-1,l=0,n=0;for(;++i<e.length;){const o=e.charCodeAt(i);let s="";if(o===37&&Rt(e.charCodeAt(i+1))&&Rt(e.charCodeAt(i+2)))n=2;else if(o<128)/[!#$&-;=?-Z_a-z~]/.test(String.fromCharCode(o))||(s=String.fromCharCode(o));else if(o>55295&&o<57344){const f=e.charCodeAt(i+1);o<56320&&f>56319&&f<57344?(s=String.fromCharCode(o,f),n=1):s="�"}else s=String.fromCharCode(o);s&&(t.push(e.slice(l,i),encodeURIComponent(s)),l=i+n+1,s=""),n&&(i+=n,n=0)}return t.join("")+e.slice(l)}function Pe(e,t,i,l){const n=l?l-1:Number.POSITIVE_INFINITY;let o=0;return s;function s(m){return Re(m)?(e.enter(i),f(m)):t(m)}function f(m){return Re(m)&&o++<n?(e.consume(m),f):(e.exit(i),t(m))}}const g3={tokenize:v3};function v3(e){const t=e.attempt(this.parser.constructs.contentInitial,l,n);let i;return t;function l(f){if(f===null){e.consume(f);return}return e.enter("lineEnding"),e.consume(f),e.exit("lineEnding"),Pe(e,t,"linePrefix")}function n(f){return e.enter("paragraph"),o(f)}function o(f){const m=e.enter("chunkText",{contentType:"text",previous:i});return i&&(i.next=m),i=m,s(f)}function s(f){if(f===null){e.exit("chunkText"),e.exit("paragraph"),e.consume(f);return}return ye(f)?(e.consume(f),e.exit("chunkText"),o):(e.consume(f),s)}}const y3={tokenize:b3},A1={tokenize:x3};function b3(e){const t=this,i=[];let l=0,n,o,s;return f;function f(N){if(l<i.length){const G=i[l];return t.containerState=G[1],e.attempt(G[0].continuation,m,d)(N)}return d(N)}function m(N){if(l++,t.containerState._closeFlow){t.containerState._closeFlow=void 0,n&&O();const G=t.events.length;let J=G,R;for(;J--;)if(t.events[J][0]==="exit"&&t.events[J][1].type==="chunkFlow"){R=t.events[J][1].end;break}E(l);let X=G;for(;X<t.events.length;)t.events[X][1].end={...R},X++;return mn(t.events,J+1,0,t.events.slice(G)),t.events.length=X,d(N)}return f(N)}function d(N){if(l===i.length){if(!n)return b(N);if(n.currentConstruct&&n.currentConstruct.concrete)return S(N);t.interrupt=!!(n.currentConstruct&&!n._gfmTableDynamicInterruptHack)}return t.containerState={},e.check(A1,p,v)(N)}function p(N){return n&&O(),E(l),b(N)}function v(N){return t.parser.lazy[t.now().line]=l!==i.length,s=t.now().offset,S(N)}function b(N){return t.containerState={},e.attempt(A1,x,S)(N)}function x(N){return l++,i.push([t.currentConstruct,t.containerState]),b(N)}function S(N){if(N===null){n&&O(),E(0),e.consume(N);return}return n=n||t.parser.flow(t.now()),e.enter("chunkFlow",{_tokenizer:n,contentType:"flow",previous:o}),w(N)}function w(N){if(N===null){j(e.exit("chunkFlow"),!0),E(0),e.consume(N);return}return ye(N)?(e.consume(N),j(e.exit("chunkFlow")),l=0,t.interrupt=void 0,f):(e.consume(N),w)}function j(N,G){const J=t.sliceStream(N);if(G&&J.push(null),N.previous=o,o&&(o.next=N),o=N,n.defineSkip(N.start),n.write(J),t.parser.lazy[N.start.line]){let R=n.events.length;for(;R--;)if(n.events[R][1].start.offset<s&&(!n.events[R][1].end||n.events[R][1].end.offset>s))return;const X=t.events.length;let Q=X,me,B;for(;Q--;)if(t.events[Q][0]==="exit"&&t.events[Q][1].type==="chunkFlow"){if(me){B=t.events[Q][1].end;break}me=!0}for(E(l),R=X;R<t.events.length;)t.events[R][1].end={...B},R++;mn(t.events,Q+1,0,t.events.slice(X)),t.events.length=R}}function E(N){let G=i.length;for(;G-- >N;){const J=i[G];t.containerState=J[1],J[0].exit.call(t,e)}i.length=N}function O(){n.write([null]),o=void 0,n=void 0,t.containerState._closeFlow=void 0}}function x3(e,t,i){return Pe(e,e.attempt(this.parser.constructs.document,t,i),"linePrefix",this.parser.constructs.disable.null.includes("codeIndented")?void 0:4)}function Xa(e){if(e===null||We(e)||Zi(e))return 1;if(Qc(e))return 2}function Kc(e,t,i){const l=[];let n=-1;for(;++n<e.length;){const o=e[n].resolveAll;o&&!l.includes(o)&&(t=o(t,i),l.push(o))}return t}const lp={name:"attention",resolveAll:_3,tokenize:S3};function _3(e,t){let i=-1,l,n,o,s,f,m,d,p;for(;++i<e.length;)if(e[i][0]==="enter"&&e[i][1].type==="attentionSequence"&&e[i][1]._close){for(l=i;l--;)if(e[l][0]==="exit"&&e[l][1].type==="attentionSequence"&&e[l][1]._open&&t.sliceSerialize(e[l][1]).charCodeAt(0)===t.sliceSerialize(e[i][1]).charCodeAt(0)){if((e[l][1]._close||e[i][1]._open)&&(e[i][1].end.offset-e[i][1].start.offset)%3&&!((e[l][1].end.offset-e[l][1].start.offset+e[i][1].end.offset-e[i][1].start.offset)%3))continue;m=e[l][1].end.offset-e[l][1].start.offset>1&&e[i][1].end.offset-e[i][1].start.offset>1?2:1;const v={...e[l][1].end},b={...e[i][1].start};R1(v,-m),R1(b,m),s={type:m>1?"strongSequence":"emphasisSequence",start:v,end:{...e[l][1].end}},f={type:m>1?"strongSequence":"emphasisSequence",start:{...e[i][1].start},end:b},o={type:m>1?"strongText":"emphasisText",start:{...e[l][1].end},end:{...e[i][1].start}},n={type:m>1?"strong":"emphasis",start:{...s.start},end:{...f.end}},e[l][1].end={...s.start},e[i][1].start={...f.end},d=[],e[l][1].end.offset-e[l][1].start.offset&&(d=zn(d,[["enter",e[l][1],t],["exit",e[l][1],t]])),d=zn(d,[["enter",n,t],["enter",s,t],["exit",s,t],["enter",o,t]]),d=zn(d,Kc(t.parser.constructs.insideSpan.null,e.slice(l+1,i),t)),d=zn(d,[["exit",o,t],["enter",f,t],["exit",f,t],["exit",n,t]]),e[i][1].end.offset-e[i][1].start.offset?(p=2,d=zn(d,[["enter",e[i][1],t],["exit",e[i][1],t]])):p=0,mn(e,l-1,i-l+3,d),i=l+d.length-p-2;break}}for(i=-1;++i<e.length;)e[i][1].type==="attentionSequence"&&(e[i][1].type="data");return e}function S3(e,t){const i=this.parser.constructs.attentionMarkers.null,l=this.previous,n=Xa(l);let o;return s;function s(m){return o=m,e.enter("attentionSequence"),f(m)}function f(m){if(m===o)return e.consume(m),f;const d=e.exit("attentionSequence"),p=Xa(m),v=!p||p===2&&n||i.includes(m),b=!n||n===2&&p||i.includes(l);return d._open=!!(o===42?v:v&&(n||!b)),d._close=!!(o===42?b:b&&(p||!v)),t(m)}}function R1(e,t){e.column+=t,e.offset+=t,e._bufferIndex+=t}const k3={name:"autolink",tokenize:w3};function w3(e,t,i){let l=0;return n;function n(x){return e.enter("autolink"),e.enter("autolinkMarker"),e.consume(x),e.exit("autolinkMarker"),e.enter("autolinkProtocol"),o}function o(x){return Ft(x)?(e.consume(x),s):x===64?i(x):d(x)}function s(x){return x===43||x===45||x===46||Rt(x)?(l=1,f(x)):d(x)}function f(x){return x===58?(e.consume(x),l=0,m):(x===43||x===45||x===46||Rt(x))&&l++<32?(e.consume(x),f):(l=0,d(x))}function m(x){return x===62?(e.exit("autolinkProtocol"),e.enter("autolinkMarker"),e.consume(x),e.exit("autolinkMarker"),e.exit("autolink"),t):x===null||x===32||x===60||Hs(x)?i(x):(e.consume(x),m)}function d(x){return x===64?(e.consume(x),p):m3(x)?(e.consume(x),d):i(x)}function p(x){return Rt(x)?v(x):i(x)}function v(x){return x===46?(e.consume(x),l=0,p):x===62?(e.exit("autolinkProtocol").type="autolinkEmail",e.enter("autolinkMarker"),e.consume(x),e.exit("autolinkMarker"),e.exit("autolink"),t):b(x)}function b(x){if((x===45||Rt(x))&&l++<63){const S=x===45?b:v;return e.consume(x),S}return i(x)}}const Ko={partial:!0,tokenize:$3};function $3(e,t,i){return l;function l(o){return Re(o)?Pe(e,n,"linePrefix")(o):n(o)}function n(o){return o===null||ye(o)?t(o):i(o)}}const mz={continuation:{tokenize:j3},exit:z3,name:"blockQuote",tokenize:E3};function E3(e,t,i){const l=this;return n;function n(s){if(s===62){const f=l.containerState;return f.open||(e.enter("blockQuote",{_container:!0}),f.open=!0),e.enter("blockQuotePrefix"),e.enter("blockQuoteMarker"),e.consume(s),e.exit("blockQuoteMarker"),o}return i(s)}function o(s){return Re(s)?(e.enter("blockQuotePrefixWhitespace"),e.consume(s),e.exit("blockQuotePrefixWhitespace"),e.exit("blockQuotePrefix"),t):(e.exit("blockQuotePrefix"),t(s))}}function j3(e,t,i){const l=this;return n;function n(s){return Re(s)?Pe(e,o,"linePrefix",l.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(s):o(s)}function o(s){return e.attempt(mz,t,i)(s)}}function z3(e){e.exit("blockQuote")}const hz={name:"characterEscape",tokenize:N3};function N3(e,t,i){return l;function l(o){return e.enter("characterEscape"),e.enter("escapeMarker"),e.consume(o),e.exit("escapeMarker"),n}function n(o){return p3(o)?(e.enter("characterEscapeValue"),e.consume(o),e.exit("characterEscapeValue"),e.exit("characterEscape"),t):i(o)}}const pz={name:"characterReference",tokenize:O3};function O3(e,t,i){const l=this;let n=0,o,s;return f;function f(v){return e.enter("characterReference"),e.enter("characterReferenceMarker"),e.consume(v),e.exit("characterReferenceMarker"),m}function m(v){return v===35?(e.enter("characterReferenceMarkerNumeric"),e.consume(v),e.exit("characterReferenceMarkerNumeric"),d):(e.enter("characterReferenceValue"),o=31,s=Rt,p(v))}function d(v){return v===88||v===120?(e.enter("characterReferenceMarkerHexadecimal"),e.consume(v),e.exit("characterReferenceMarkerHexadecimal"),e.enter("characterReferenceValue"),o=6,s=h3,p):(e.enter("characterReferenceValue"),o=7,s=ap,p(v))}function p(v){if(v===59&&n){const b=e.exit("characterReferenceValue");return s===Rt&&!jv(l.sliceSerialize(b))?i(v):(e.enter("characterReferenceMarker"),e.consume(v),e.exit("characterReferenceMarker"),e.exit("characterReference"),t)}return s(v)&&n++<o?(e.consume(v),p):i(v)}}const I1={partial:!0,tokenize:C3},U1={concrete:!0,name:"codeFenced",tokenize:T3};function T3(e,t,i){const l=this,n={partial:!0,tokenize:J};let o=0,s=0,f;return m;function m(R){return d(R)}function d(R){const X=l.events[l.events.length-1];return o=X&&X[1].type==="linePrefix"?X[2].sliceSerialize(X[1],!0).length:0,f=R,e.enter("codeFenced"),e.enter("codeFencedFence"),e.enter("codeFencedFenceSequence"),p(R)}function p(R){return R===f?(s++,e.consume(R),p):s<3?i(R):(e.exit("codeFencedFenceSequence"),Re(R)?Pe(e,v,"whitespace")(R):v(R))}function v(R){return R===null||ye(R)?(e.exit("codeFencedFence"),l.interrupt?t(R):e.check(I1,w,G)(R)):(e.enter("codeFencedFenceInfo"),e.enter("chunkString",{contentType:"string"}),b(R))}function b(R){return R===null||ye(R)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),v(R)):Re(R)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),Pe(e,x,"whitespace")(R)):R===96&&R===f?i(R):(e.consume(R),b)}function x(R){return R===null||ye(R)?v(R):(e.enter("codeFencedFenceMeta"),e.enter("chunkString",{contentType:"string"}),S(R))}function S(R){return R===null||ye(R)?(e.exit("chunkString"),e.exit("codeFencedFenceMeta"),v(R)):R===96&&R===f?i(R):(e.consume(R),S)}function w(R){return e.attempt(n,G,j)(R)}function j(R){return e.enter("lineEnding"),e.consume(R),e.exit("lineEnding"),E}function E(R){return o>0&&Re(R)?Pe(e,O,"linePrefix",o+1)(R):O(R)}function O(R){return R===null||ye(R)?e.check(I1,w,G)(R):(e.enter("codeFlowValue"),N(R))}function N(R){return R===null||ye(R)?(e.exit("codeFlowValue"),O(R)):(e.consume(R),N)}function G(R){return e.exit("codeFenced"),t(R)}function J(R,X,Q){let me=0;return B;function B(U){return R.enter("lineEnding"),R.consume(U),R.exit("lineEnding"),ue}function ue(U){return R.enter("codeFencedFence"),Re(U)?Pe(R,ce,"linePrefix",l.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(U):ce(U)}function ce(U){return U===f?(R.enter("codeFencedFenceSequence"),ke(U)):Q(U)}function ke(U){return U===f?(me++,R.consume(U),ke):me>=s?(R.exit("codeFencedFenceSequence"),Re(U)?Pe(R,M,"whitespace")(U):M(U)):Q(U)}function M(U){return U===null||ye(U)?(R.exit("codeFencedFence"),X(U)):Q(U)}}}function C3(e,t,i){const l=this;return n;function n(s){return s===null?i(s):(e.enter("lineEnding"),e.consume(s),e.exit("lineEnding"),o)}function o(s){return l.parser.lazy[l.now().line]?i(s):t(s)}}const kh={name:"codeIndented",tokenize:A3},D3={partial:!0,tokenize:R3};function A3(e,t,i){const l=this;return n;function n(d){return e.enter("codeIndented"),Pe(e,o,"linePrefix",5)(d)}function o(d){const p=l.events[l.events.length-1];return p&&p[1].type==="linePrefix"&&p[2].sliceSerialize(p[1],!0).length>=4?s(d):i(d)}function s(d){return d===null?m(d):ye(d)?e.attempt(D3,s,m)(d):(e.enter("codeFlowValue"),f(d))}function f(d){return d===null||ye(d)?(e.exit("codeFlowValue"),s(d)):(e.consume(d),f)}function m(d){return e.exit("codeIndented"),t(d)}}function R3(e,t,i){const l=this;return n;function n(s){return l.parser.lazy[l.now().line]?i(s):ye(s)?(e.enter("lineEnding"),e.consume(s),e.exit("lineEnding"),n):Pe(e,o,"linePrefix",5)(s)}function o(s){const f=l.events[l.events.length-1];return f&&f[1].type==="linePrefix"&&f[2].sliceSerialize(f[1],!0).length>=4?t(s):ye(s)?n(s):i(s)}}const I3={name:"codeText",previous:L3,resolve:U3,tokenize:M3};function U3(e){let t=e.length-4,i=3,l,n;if((e[i][1].type==="lineEnding"||e[i][1].type==="space")&&(e[t][1].type==="lineEnding"||e[t][1].type==="space")){for(l=i;++l<t;)if(e[l][1].type==="codeTextData"){e[i][1].type="codeTextPadding",e[t][1].type="codeTextPadding",i+=2,t-=2;break}}for(l=i-1,t++;++l<=t;)n===void 0?l!==t&&e[l][1].type!=="lineEnding"&&(n=l):(l===t||e[l][1].type==="lineEnding")&&(e[n][1].type="codeTextData",l!==n+2&&(e[n][1].end=e[l-1][1].end,e.splice(n+2,l-n-2),t-=l-n-2,l=n+2),n=void 0);return e}function L3(e){return e!==96||this.events[this.events.length-1][1].type==="characterEscape"}function M3(e,t,i){let l=0,n,o;return s;function s(v){return e.enter("codeText"),e.enter("codeTextSequence"),f(v)}function f(v){return v===96?(e.consume(v),l++,f):(e.exit("codeTextSequence"),m(v))}function m(v){return v===null?i(v):v===32?(e.enter("space"),e.consume(v),e.exit("space"),m):v===96?(o=e.enter("codeTextSequence"),n=0,p(v)):ye(v)?(e.enter("lineEnding"),e.consume(v),e.exit("lineEnding"),m):(e.enter("codeTextData"),d(v))}function d(v){return v===null||v===32||v===96||ye(v)?(e.exit("codeTextData"),m(v)):(e.consume(v),d)}function p(v){return v===96?(e.consume(v),n++,p):n===l?(e.exit("codeTextSequence"),e.exit("codeText"),t(v)):(o.type="codeTextData",d(v))}}class P3{constructor(t){this.left=t?[...t]:[],this.right=[]}get(t){if(t<0||t>=this.left.length+this.right.length)throw new RangeError("Cannot access index `"+t+"` in a splice buffer of size `"+(this.left.length+this.right.length)+"`");return t<this.left.length?this.left[t]:this.right[this.right.length-t+this.left.length-1]}get length(){return this.left.length+this.right.length}shift(){return this.setCursor(0),this.right.pop()}slice(t,i){const l=i??Number.POSITIVE_INFINITY;return l<this.left.length?this.left.slice(t,l):t>this.left.length?this.right.slice(this.right.length-l+this.left.length,this.right.length-t+this.left.length).reverse():this.left.slice(t).concat(this.right.slice(this.right.length-l+this.left.length).reverse())}splice(t,i,l){const n=i||0;this.setCursor(Math.trunc(t));const o=this.right.splice(this.right.length-n,Number.POSITIVE_INFINITY);return l&&ao(this.left,l),o.reverse()}pop(){return this.setCursor(Number.POSITIVE_INFINITY),this.left.pop()}push(t){this.setCursor(Number.POSITIVE_INFINITY),this.left.push(t)}pushMany(t){this.setCursor(Number.POSITIVE_INFINITY),ao(this.left,t)}unshift(t){this.setCursor(0),this.right.push(t)}unshiftMany(t){this.setCursor(0),ao(this.right,t.reverse())}setCursor(t){if(!(t===this.left.length||t>this.left.length&&this.right.length===0||t<0&&this.left.length===0))if(t<this.left.length){const i=this.left.splice(t,Number.POSITIVE_INFINITY);ao(this.right,i.reverse())}else{const i=this.right.splice(this.left.length+this.right.length-t,Number.POSITIVE_INFINITY);ao(this.left,i.reverse())}}}function ao(e,t){let i=0;if(t.length<1e4)e.push(...t);else for(;i<t.length;)e.push(...t.slice(i,i+1e4)),i+=1e4}function gz(e){const t={};let i=-1,l,n,o,s,f,m,d;const p=new P3(e);for(;++i<p.length;){for(;i in t;)i=t[i];if(l=p.get(i),i&&l[1].type==="chunkFlow"&&p.get(i-1)[1].type==="listItemPrefix"&&(m=l[1]._tokenizer.events,o=0,o<m.length&&m[o][1].type==="lineEndingBlank"&&(o+=2),o<m.length&&m[o][1].type==="content"))for(;++o<m.length&&m[o][1].type!=="content";)m[o][1].type==="chunkText"&&(m[o][1]._isInFirstContentOfListItem=!0,o++);if(l[0]==="enter")l[1].contentType&&(Object.assign(t,Z3(p,i)),i=t[i],d=!0);else if(l[1]._container){for(o=i,n=void 0;o--;)if(s=p.get(o),s[1].type==="lineEnding"||s[1].type==="lineEndingBlank")s[0]==="enter"&&(n&&(p.get(n)[1].type="lineEndingBlank"),s[1].type="lineEnding",n=o);else if(!(s[1].type==="linePrefix"||s[1].type==="listItemIndent"))break;n&&(l[1].end={...p.get(n)[1].start},f=p.slice(n,i),f.unshift(l),p.splice(n,i-n+1,f))}}return mn(e,0,Number.POSITIVE_INFINITY,p.slice(0)),!d}function Z3(e,t){const i=e.get(t)[1],l=e.get(t)[2];let n=t-1;const o=[];let s=i._tokenizer;s||(s=l.parser[i.contentType](i.start),i._contentTypeTextTrailing&&(s._contentTypeTextTrailing=!0));const f=s.events,m=[],d={};let p,v,b=-1,x=i,S=0,w=0;const j=[w];for(;x;){for(;e.get(++n)[1]!==x;);o.push(n),x._tokenizer||(p=l.sliceStream(x),x.next||p.push(null),v&&s.defineSkip(x.start),x._isInFirstContentOfListItem&&(s._gfmTasklistFirstContentOfListItem=!0),s.write(p),x._isInFirstContentOfListItem&&(s._gfmTasklistFirstContentOfListItem=void 0)),v=x,x=x.next}for(x=i;++b<f.length;)f[b][0]==="exit"&&f[b-1][0]==="enter"&&f[b][1].type===f[b-1][1].type&&f[b][1].start.line!==f[b][1].end.line&&(w=b+1,j.push(w),x._tokenizer=void 0,x.previous=void 0,x=x.next);for(s.events=[],x?(x._tokenizer=void 0,x.previous=void 0):j.pop(),b=j.length;b--;){const E=f.slice(j[b],j[b+1]),O=o.pop();m.push([O,O+E.length-1]),e.splice(O,2,E)}for(m.reverse(),b=-1;++b<m.length;)d[S+m[b][0]]=S+m[b][1],S+=m[b][1]-m[b][0]-1;return d}const q3={resolve:B3,tokenize:H3},F3={partial:!0,tokenize:G3};function B3(e){return gz(e),e}function H3(e,t){let i;return l;function l(f){return e.enter("content"),i=e.enter("chunkContent",{contentType:"content"}),n(f)}function n(f){return f===null?o(f):ye(f)?e.check(F3,s,o)(f):(e.consume(f),n)}function o(f){return e.exit("chunkContent"),e.exit("content"),t(f)}function s(f){return e.consume(f),e.exit("chunkContent"),i.next=e.enter("chunkContent",{contentType:"content",previous:i}),i=i.next,n}}function G3(e,t,i){const l=this;return n;function n(s){return e.exit("chunkContent"),e.enter("lineEnding"),e.consume(s),e.exit("lineEnding"),Pe(e,o,"linePrefix")}function o(s){if(s===null||ye(s))return i(s);const f=l.events[l.events.length-1];return!l.parser.constructs.disable.null.includes("codeIndented")&&f&&f[1].type==="linePrefix"&&f[2].sliceSerialize(f[1],!0).length>=4?t(s):e.interrupt(l.parser.constructs.flow,i,t)(s)}}function vz(e,t,i,l,n,o,s,f,m){const d=m||Number.POSITIVE_INFINITY;let p=0;return v;function v(E){return E===60?(e.enter(l),e.enter(n),e.enter(o),e.consume(E),e.exit(o),b):E===null||E===32||E===41||Hs(E)?i(E):(e.enter(l),e.enter(s),e.enter(f),e.enter("chunkString",{contentType:"string"}),w(E))}function b(E){return E===62?(e.enter(o),e.consume(E),e.exit(o),e.exit(n),e.exit(l),t):(e.enter(f),e.enter("chunkString",{contentType:"string"}),x(E))}function x(E){return E===62?(e.exit("chunkString"),e.exit(f),b(E)):E===null||E===60||ye(E)?i(E):(e.consume(E),E===92?S:x)}function S(E){return E===60||E===62||E===92?(e.consume(E),x):x(E)}function w(E){return!p&&(E===null||E===41||We(E))?(e.exit("chunkString"),e.exit(f),e.exit(s),e.exit(l),t(E)):p<d&&E===40?(e.consume(E),p++,w):E===41?(e.consume(E),p--,w):E===null||E===32||E===40||Hs(E)?i(E):(e.consume(E),E===92?j:w)}function j(E){return E===40||E===41||E===92?(e.consume(E),w):w(E)}}function yz(e,t,i,l,n,o){const s=this;let f=0,m;return d;function d(x){return e.enter(l),e.enter(n),e.consume(x),e.exit(n),e.enter(o),p}function p(x){return f>999||x===null||x===91||x===93&&!m||x===94&&!f&&"_hiddenFootnoteSupport"in s.parser.constructs?i(x):x===93?(e.exit(o),e.enter(n),e.consume(x),e.exit(n),e.exit(l),t):ye(x)?(e.enter("lineEnding"),e.consume(x),e.exit("lineEnding"),p):(e.enter("chunkString",{contentType:"string"}),v(x))}function v(x){return x===null||x===91||x===93||ye(x)||f++>999?(e.exit("chunkString"),p(x)):(e.consume(x),m||(m=!Re(x)),x===92?b:v)}function b(x){return x===91||x===92||x===93?(e.consume(x),f++,v):v(x)}}function bz(e,t,i,l,n,o){let s;return f;function f(b){return b===34||b===39||b===40?(e.enter(l),e.enter(n),e.consume(b),e.exit(n),s=b===40?41:b,m):i(b)}function m(b){return b===s?(e.enter(n),e.consume(b),e.exit(n),e.exit(l),t):(e.enter(o),d(b))}function d(b){return b===s?(e.exit(o),m(s)):b===null?i(b):ye(b)?(e.enter("lineEnding"),e.consume(b),e.exit("lineEnding"),Pe(e,d,"linePrefix")):(e.enter("chunkString",{contentType:"string"}),p(b))}function p(b){return b===s||b===null||ye(b)?(e.exit("chunkString"),d(b)):(e.consume(b),b===92?v:p)}function v(b){return b===s||b===92?(e.consume(b),p):p(b)}}function so(e,t){let i;return l;function l(n){return ye(n)?(e.enter("lineEnding"),e.consume(n),e.exit("lineEnding"),i=!0,l):Re(n)?Pe(e,l,i?"linePrefix":"lineSuffix")(n):t(n)}}const V3={name:"definition",tokenize:J3},Y3={partial:!0,tokenize:X3};function J3(e,t,i){const l=this;let n;return o;function o(x){return e.enter("definition"),s(x)}function s(x){return yz.call(l,e,f,i,"definitionLabel","definitionLabelMarker","definitionLabelString")(x)}function f(x){return n=Zn(l.sliceSerialize(l.events[l.events.length-1][1]).slice(1,-1)),x===58?(e.enter("definitionMarker"),e.consume(x),e.exit("definitionMarker"),m):i(x)}function m(x){return We(x)?so(e,d)(x):d(x)}function d(x){return vz(e,p,i,"definitionDestination","definitionDestinationLiteral","definitionDestinationLiteralMarker","definitionDestinationRaw","definitionDestinationString")(x)}function p(x){return e.attempt(Y3,v,v)(x)}function v(x){return Re(x)?Pe(e,b,"whitespace")(x):b(x)}function b(x){return x===null||ye(x)?(e.exit("definition"),l.parser.defined.push(n),t(x)):i(x)}}function X3(e,t,i){return l;function l(f){return We(f)?so(e,n)(f):i(f)}function n(f){return bz(e,o,i,"definitionTitle","definitionTitleMarker","definitionTitleString")(f)}function o(f){return Re(f)?Pe(e,s,"whitespace")(f):s(f)}function s(f){return f===null||ye(f)?t(f):i(f)}}const Q3={name:"hardBreakEscape",tokenize:K3};function K3(e,t,i){return l;function l(o){return e.enter("hardBreakEscape"),e.consume(o),n}function n(o){return ye(o)?(e.exit("hardBreakEscape"),t(o)):i(o)}}const W3={name:"headingAtx",resolve:eL,tokenize:tL};function eL(e,t){let i=e.length-2,l=3,n,o;return e[l][1].type==="whitespace"&&(l+=2),i-2>l&&e[i][1].type==="whitespace"&&(i-=2),e[i][1].type==="atxHeadingSequence"&&(l===i-1||i-4>l&&e[i-2][1].type==="whitespace")&&(i-=l+1===i?2:4),i>l&&(n={type:"atxHeadingText",start:e[l][1].start,end:e[i][1].end},o={type:"chunkText",start:e[l][1].start,end:e[i][1].end,contentType:"text"},mn(e,l,i-l+1,[["enter",n,t],["enter",o,t],["exit",o,t],["exit",n,t]])),e}function tL(e,t,i){let l=0;return n;function n(p){return e.enter("atxHeading"),o(p)}function o(p){return e.enter("atxHeadingSequence"),s(p)}function s(p){return p===35&&l++<6?(e.consume(p),s):p===null||We(p)?(e.exit("atxHeadingSequence"),f(p)):i(p)}function f(p){return p===35?(e.enter("atxHeadingSequence"),m(p)):p===null||ye(p)?(e.exit("atxHeading"),t(p)):Re(p)?Pe(e,f,"whitespace")(p):(e.enter("atxHeadingText"),d(p))}function m(p){return p===35?(e.consume(p),m):(e.exit("atxHeadingSequence"),f(p))}function d(p){return p===null||p===35||We(p)?(e.exit("atxHeadingText"),f(p)):(e.consume(p),d)}}const nL=["address","article","aside","base","basefont","blockquote","body","caption","center","col","colgroup","dd","details","dialog","dir","div","dl","dt","fieldset","figcaption","figure","footer","form","frame","frameset","h1","h2","h3","h4","h5","h6","head","header","hr","html","iframe","legend","li","link","main","menu","menuitem","nav","noframes","ol","optgroup","option","p","param","search","section","summary","table","tbody","td","tfoot","th","thead","title","tr","track","ul"],L1=["pre","script","style","textarea"],rL={concrete:!0,name:"htmlFlow",resolveTo:lL,tokenize:oL},iL={partial:!0,tokenize:sL},aL={partial:!0,tokenize:uL};function lL(e){let t=e.length;for(;t--&&!(e[t][0]==="enter"&&e[t][1].type==="htmlFlow"););return t>1&&e[t-2][1].type==="linePrefix"&&(e[t][1].start=e[t-2][1].start,e[t+1][1].start=e[t-2][1].start,e.splice(t-2,2)),e}function oL(e,t,i){const l=this;let n,o,s,f,m;return d;function d($){return p($)}function p($){return e.enter("htmlFlow"),e.enter("htmlFlowData"),e.consume($),v}function v($){return $===33?(e.consume($),b):$===47?(e.consume($),o=!0,w):$===63?(e.consume($),n=3,l.interrupt?t:z):Ft($)?(e.consume($),s=String.fromCharCode($),j):i($)}function b($){return $===45?(e.consume($),n=2,x):$===91?(e.consume($),n=5,f=0,S):Ft($)?(e.consume($),n=4,l.interrupt?t:z):i($)}function x($){return $===45?(e.consume($),l.interrupt?t:z):i($)}function S($){const oe="CDATA[";return $===oe.charCodeAt(f++)?(e.consume($),f===oe.length?l.interrupt?t:ce:S):i($)}function w($){return Ft($)?(e.consume($),s=String.fromCharCode($),j):i($)}function j($){if($===null||$===47||$===62||We($)){const oe=$===47,de=s.toLowerCase();return!oe&&!o&&L1.includes(de)?(n=1,l.interrupt?t($):ce($)):nL.includes(s.toLowerCase())?(n=6,oe?(e.consume($),E):l.interrupt?t($):ce($)):(n=7,l.interrupt&&!l.parser.lazy[l.now().line]?i($):o?O($):N($))}return $===45||Rt($)?(e.consume($),s+=String.fromCharCode($),j):i($)}function E($){return $===62?(e.consume($),l.interrupt?t:ce):i($)}function O($){return Re($)?(e.consume($),O):B($)}function N($){return $===47?(e.consume($),B):$===58||$===95||Ft($)?(e.consume($),G):Re($)?(e.consume($),N):B($)}function G($){return $===45||$===46||$===58||$===95||Rt($)?(e.consume($),G):J($)}function J($){return $===61?(e.consume($),R):Re($)?(e.consume($),J):N($)}function R($){return $===null||$===60||$===61||$===62||$===96?i($):$===34||$===39?(e.consume($),m=$,X):Re($)?(e.consume($),R):Q($)}function X($){return $===m?(e.consume($),m=null,me):$===null||ye($)?i($):(e.consume($),X)}function Q($){return $===null||$===34||$===39||$===47||$===60||$===61||$===62||$===96||We($)?J($):(e.consume($),Q)}function me($){return $===47||$===62||Re($)?N($):i($)}function B($){return $===62?(e.consume($),ue):i($)}function ue($){return $===null||ye($)?ce($):Re($)?(e.consume($),ue):i($)}function ce($){return $===45&&n===2?(e.consume($),A):$===60&&n===1?(e.consume($),q):$===62&&n===4?(e.consume($),T):$===63&&n===3?(e.consume($),z):$===93&&n===5?(e.consume($),ie):ye($)&&(n===6||n===7)?(e.exit("htmlFlowData"),e.check(iL,Z,ke)($)):$===null||ye($)?(e.exit("htmlFlowData"),ke($)):(e.consume($),ce)}function ke($){return e.check(aL,M,Z)($)}function M($){return e.enter("lineEnding"),e.consume($),e.exit("lineEnding"),U}function U($){return $===null||ye($)?ke($):(e.enter("htmlFlowData"),ce($))}function A($){return $===45?(e.consume($),z):ce($)}function q($){return $===47?(e.consume($),s="",te):ce($)}function te($){if($===62){const oe=s.toLowerCase();return L1.includes(oe)?(e.consume($),T):ce($)}return Ft($)&&s.length<8?(e.consume($),s+=String.fromCharCode($),te):ce($)}function ie($){return $===93?(e.consume($),z):ce($)}function z($){return $===62?(e.consume($),T):$===45&&n===2?(e.consume($),z):ce($)}function T($){return $===null||ye($)?(e.exit("htmlFlowData"),Z($)):(e.consume($),T)}function Z($){return e.exit("htmlFlow"),t($)}}function uL(e,t,i){const l=this;return n;function n(s){return ye(s)?(e.enter("lineEnding"),e.consume(s),e.exit("lineEnding"),o):i(s)}function o(s){return l.parser.lazy[l.now().line]?i(s):t(s)}}function sL(e,t,i){return l;function l(n){return e.enter("lineEnding"),e.consume(n),e.exit("lineEnding"),e.attempt(Ko,t,i)}}const cL={name:"htmlText",tokenize:fL};function fL(e,t,i){const l=this;let n,o,s;return f;function f(z){return e.enter("htmlText"),e.enter("htmlTextData"),e.consume(z),m}function m(z){return z===33?(e.consume(z),d):z===47?(e.consume(z),J):z===63?(e.consume(z),N):Ft(z)?(e.consume(z),Q):i(z)}function d(z){return z===45?(e.consume(z),p):z===91?(e.consume(z),o=0,S):Ft(z)?(e.consume(z),O):i(z)}function p(z){return z===45?(e.consume(z),x):i(z)}function v(z){return z===null?i(z):z===45?(e.consume(z),b):ye(z)?(s=v,q(z)):(e.consume(z),v)}function b(z){return z===45?(e.consume(z),x):v(z)}function x(z){return z===62?A(z):z===45?b(z):v(z)}function S(z){const T="CDATA[";return z===T.charCodeAt(o++)?(e.consume(z),o===T.length?w:S):i(z)}function w(z){return z===null?i(z):z===93?(e.consume(z),j):ye(z)?(s=w,q(z)):(e.consume(z),w)}function j(z){return z===93?(e.consume(z),E):w(z)}function E(z){return z===62?A(z):z===93?(e.consume(z),E):w(z)}function O(z){return z===null||z===62?A(z):ye(z)?(s=O,q(z)):(e.consume(z),O)}function N(z){return z===null?i(z):z===63?(e.consume(z),G):ye(z)?(s=N,q(z)):(e.consume(z),N)}function G(z){return z===62?A(z):N(z)}function J(z){return Ft(z)?(e.consume(z),R):i(z)}function R(z){return z===45||Rt(z)?(e.consume(z),R):X(z)}function X(z){return ye(z)?(s=X,q(z)):Re(z)?(e.consume(z),X):A(z)}function Q(z){return z===45||Rt(z)?(e.consume(z),Q):z===47||z===62||We(z)?me(z):i(z)}function me(z){return z===47?(e.consume(z),A):z===58||z===95||Ft(z)?(e.consume(z),B):ye(z)?(s=me,q(z)):Re(z)?(e.consume(z),me):A(z)}function B(z){return z===45||z===46||z===58||z===95||Rt(z)?(e.consume(z),B):ue(z)}function ue(z){return z===61?(e.consume(z),ce):ye(z)?(s=ue,q(z)):Re(z)?(e.consume(z),ue):me(z)}function ce(z){return z===null||z===60||z===61||z===62||z===96?i(z):z===34||z===39?(e.consume(z),n=z,ke):ye(z)?(s=ce,q(z)):Re(z)?(e.consume(z),ce):(e.consume(z),M)}function ke(z){return z===n?(e.consume(z),n=void 0,U):z===null?i(z):ye(z)?(s=ke,q(z)):(e.consume(z),ke)}function M(z){return z===null||z===34||z===39||z===60||z===61||z===96?i(z):z===47||z===62||We(z)?me(z):(e.consume(z),M)}function U(z){return z===47||z===62||We(z)?me(z):i(z)}function A(z){return z===62?(e.consume(z),e.exit("htmlTextData"),e.exit("htmlText"),t):i(z)}function q(z){return e.exit("htmlTextData"),e.enter("lineEnding"),e.consume(z),e.exit("lineEnding"),te}function te(z){return Re(z)?Pe(e,ie,"linePrefix",l.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(z):ie(z)}function ie(z){return e.enter("htmlTextData"),s(z)}}const zv={name:"labelEnd",resolveAll:pL,resolveTo:gL,tokenize:vL},dL={tokenize:yL},mL={tokenize:bL},hL={tokenize:xL};function pL(e){let t=-1;const i=[];for(;++t<e.length;){const l=e[t][1];if(i.push(e[t]),l.type==="labelImage"||l.type==="labelLink"||l.type==="labelEnd"){const n=l.type==="labelImage"?4:2;l.type="data",t+=n}}return e.length!==i.length&&mn(e,0,e.length,i),e}function gL(e,t){let i=e.length,l=0,n,o,s,f;for(;i--;)if(n=e[i][1],o){if(n.type==="link"||n.type==="labelLink"&&n._inactive)break;e[i][0]==="enter"&&n.type==="labelLink"&&(n._inactive=!0)}else if(s){if(e[i][0]==="enter"&&(n.type==="labelImage"||n.type==="labelLink")&&!n._balanced&&(o=i,n.type!=="labelLink")){l=2;break}}else n.type==="labelEnd"&&(s=i);const m={type:e[o][1].type==="labelLink"?"link":"image",start:{...e[o][1].start},end:{...e[e.length-1][1].end}},d={type:"label",start:{...e[o][1].start},end:{...e[s][1].end}},p={type:"labelText",start:{...e[o+l+2][1].end},end:{...e[s-2][1].start}};return f=[["enter",m,t],["enter",d,t]],f=zn(f,e.slice(o+1,o+l+3)),f=zn(f,[["enter",p,t]]),f=zn(f,Kc(t.parser.constructs.insideSpan.null,e.slice(o+l+4,s-3),t)),f=zn(f,[["exit",p,t],e[s-2],e[s-1],["exit",d,t]]),f=zn(f,e.slice(s+1)),f=zn(f,[["exit",m,t]]),mn(e,o,e.length,f),e}function vL(e,t,i){const l=this;let n=l.events.length,o,s;for(;n--;)if((l.events[n][1].type==="labelImage"||l.events[n][1].type==="labelLink")&&!l.events[n][1]._balanced){o=l.events[n][1];break}return f;function f(b){return o?o._inactive?v(b):(s=l.parser.defined.includes(Zn(l.sliceSerialize({start:o.end,end:l.now()}))),e.enter("labelEnd"),e.enter("labelMarker"),e.consume(b),e.exit("labelMarker"),e.exit("labelEnd"),m):i(b)}function m(b){return b===40?e.attempt(dL,p,s?p:v)(b):b===91?e.attempt(mL,p,s?d:v)(b):s?p(b):v(b)}function d(b){return e.attempt(hL,p,v)(b)}function p(b){return t(b)}function v(b){return o._balanced=!0,i(b)}}function yL(e,t,i){return l;function l(v){return e.enter("resource"),e.enter("resourceMarker"),e.consume(v),e.exit("resourceMarker"),n}function n(v){return We(v)?so(e,o)(v):o(v)}function o(v){return v===41?p(v):vz(e,s,f,"resourceDestination","resourceDestinationLiteral","resourceDestinationLiteralMarker","resourceDestinationRaw","resourceDestinationString",32)(v)}function s(v){return We(v)?so(e,m)(v):p(v)}function f(v){return i(v)}function m(v){return v===34||v===39||v===40?bz(e,d,i,"resourceTitle","resourceTitleMarker","resourceTitleString")(v):p(v)}function d(v){return We(v)?so(e,p)(v):p(v)}function p(v){return v===41?(e.enter("resourceMarker"),e.consume(v),e.exit("resourceMarker"),e.exit("resource"),t):i(v)}}function bL(e,t,i){const l=this;return n;function n(f){return yz.call(l,e,o,s,"reference","referenceMarker","referenceString")(f)}function o(f){return l.parser.defined.includes(Zn(l.sliceSerialize(l.events[l.events.length-1][1]).slice(1,-1)))?t(f):i(f)}function s(f){return i(f)}}function xL(e,t,i){return l;function l(o){return e.enter("reference"),e.enter("referenceMarker"),e.consume(o),e.exit("referenceMarker"),n}function n(o){return o===93?(e.enter("referenceMarker"),e.consume(o),e.exit("referenceMarker"),e.exit("reference"),t):i(o)}}const _L={name:"labelStartImage",resolveAll:zv.resolveAll,tokenize:SL};function SL(e,t,i){const l=this;return n;function n(f){return e.enter("labelImage"),e.enter("labelImageMarker"),e.consume(f),e.exit("labelImageMarker"),o}function o(f){return f===91?(e.enter("labelMarker"),e.consume(f),e.exit("labelMarker"),e.exit("labelImage"),s):i(f)}function s(f){return f===94&&"_hiddenFootnoteSupport"in l.parser.constructs?i(f):t(f)}}const kL={name:"labelStartLink",resolveAll:zv.resolveAll,tokenize:wL};function wL(e,t,i){const l=this;return n;function n(s){return e.enter("labelLink"),e.enter("labelMarker"),e.consume(s),e.exit("labelMarker"),e.exit("labelLink"),o}function o(s){return s===94&&"_hiddenFootnoteSupport"in l.parser.constructs?i(s):t(s)}}const wh={name:"lineEnding",tokenize:$L};function $L(e,t){return i;function i(l){return e.enter("lineEnding"),e.consume(l),e.exit("lineEnding"),Pe(e,t,"linePrefix")}}const Cs={name:"thematicBreak",tokenize:EL};function EL(e,t,i){let l=0,n;return o;function o(d){return e.enter("thematicBreak"),s(d)}function s(d){return n=d,f(d)}function f(d){return d===n?(e.enter("thematicBreakSequence"),m(d)):l>=3&&(d===null||ye(d))?(e.exit("thematicBreak"),t(d)):i(d)}function m(d){return d===n?(e.consume(d),l++,m):(e.exit("thematicBreakSequence"),Re(d)?Pe(e,f,"whitespace")(d):f(d))}}const Wt={continuation:{tokenize:OL},exit:CL,name:"list",tokenize:NL},jL={partial:!0,tokenize:DL},zL={partial:!0,tokenize:TL};function NL(e,t,i){const l=this,n=l.events[l.events.length-1];let o=n&&n[1].type==="linePrefix"?n[2].sliceSerialize(n[1],!0).length:0,s=0;return f;function f(x){const S=l.containerState.type||(x===42||x===43||x===45?"listUnordered":"listOrdered");if(S==="listUnordered"?!l.containerState.marker||x===l.containerState.marker:ap(x)){if(l.containerState.type||(l.containerState.type=S,e.enter(S,{_container:!0})),S==="listUnordered")return e.enter("listItemPrefix"),x===42||x===45?e.check(Cs,i,d)(x):d(x);if(!l.interrupt||x===49)return e.enter("listItemPrefix"),e.enter("listItemValue"),m(x)}return i(x)}function m(x){return ap(x)&&++s<10?(e.consume(x),m):(!l.interrupt||s<2)&&(l.containerState.marker?x===l.containerState.marker:x===41||x===46)?(e.exit("listItemValue"),d(x)):i(x)}function d(x){return e.enter("listItemMarker"),e.consume(x),e.exit("listItemMarker"),l.containerState.marker=l.containerState.marker||x,e.check(Ko,l.interrupt?i:p,e.attempt(jL,b,v))}function p(x){return l.containerState.initialBlankLine=!0,o++,b(x)}function v(x){return Re(x)?(e.enter("listItemPrefixWhitespace"),e.consume(x),e.exit("listItemPrefixWhitespace"),b):i(x)}function b(x){return l.containerState.size=o+l.sliceSerialize(e.exit("listItemPrefix"),!0).length,t(x)}}function OL(e,t,i){const l=this;return l.containerState._closeFlow=void 0,e.check(Ko,n,o);function n(f){return l.containerState.furtherBlankLines=l.containerState.furtherBlankLines||l.containerState.initialBlankLine,Pe(e,t,"listItemIndent",l.containerState.size+1)(f)}function o(f){return l.containerState.furtherBlankLines||!Re(f)?(l.containerState.furtherBlankLines=void 0,l.containerState.initialBlankLine=void 0,s(f)):(l.containerState.furtherBlankLines=void 0,l.containerState.initialBlankLine=void 0,e.attempt(zL,t,s)(f))}function s(f){return l.containerState._closeFlow=!0,l.interrupt=void 0,Pe(e,e.attempt(Wt,t,i),"linePrefix",l.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(f)}}function TL(e,t,i){const l=this;return Pe(e,n,"listItemIndent",l.containerState.size+1);function n(o){const s=l.events[l.events.length-1];return s&&s[1].type==="listItemIndent"&&s[2].sliceSerialize(s[1],!0).length===l.containerState.size?t(o):i(o)}}function CL(e){e.exit(this.containerState.type)}function DL(e,t,i){const l=this;return Pe(e,n,"listItemPrefixWhitespace",l.parser.constructs.disable.null.includes("codeIndented")?void 0:5);function n(o){const s=l.events[l.events.length-1];return!Re(o)&&s&&s[1].type==="listItemPrefixWhitespace"?t(o):i(o)}}const M1={name:"setextUnderline",resolveTo:AL,tokenize:RL};function AL(e,t){let i=e.length,l,n,o;for(;i--;)if(e[i][0]==="enter"){if(e[i][1].type==="content"){l=i;break}e[i][1].type==="paragraph"&&(n=i)}else e[i][1].type==="content"&&e.splice(i,1),!o&&e[i][1].type==="definition"&&(o=i);const s={type:"setextHeading",start:{...e[l][1].start},end:{...e[e.length-1][1].end}};return e[n][1].type="setextHeadingText",o?(e.splice(n,0,["enter",s,t]),e.splice(o+1,0,["exit",e[l][1],t]),e[l][1].end={...e[o][1].end}):e[l][1]=s,e.push(["exit",s,t]),e}function RL(e,t,i){const l=this;let n;return o;function o(d){let p=l.events.length,v;for(;p--;)if(l.events[p][1].type!=="lineEnding"&&l.events[p][1].type!=="linePrefix"&&l.events[p][1].type!=="content"){v=l.events[p][1].type==="paragraph";break}return!l.parser.lazy[l.now().line]&&(l.interrupt||v)?(e.enter("setextHeadingLine"),n=d,s(d)):i(d)}function s(d){return e.enter("setextHeadingLineSequence"),f(d)}function f(d){return d===n?(e.consume(d),f):(e.exit("setextHeadingLineSequence"),Re(d)?Pe(e,m,"lineSuffix")(d):m(d))}function m(d){return d===null||ye(d)?(e.exit("setextHeadingLine"),t(d)):i(d)}}const IL={tokenize:UL};function UL(e){const t=this,i=e.attempt(Ko,l,e.attempt(this.parser.constructs.flowInitial,n,Pe(e,e.attempt(this.parser.constructs.flow,n,e.attempt(q3,n)),"linePrefix")));return i;function l(o){if(o===null){e.consume(o);return}return e.enter("lineEndingBlank"),e.consume(o),e.exit("lineEndingBlank"),t.currentConstruct=void 0,i}function n(o){if(o===null){e.consume(o);return}return e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),t.currentConstruct=void 0,i}}const LL={resolveAll:_z()},ML=xz("string"),PL=xz("text");function xz(e){return{resolveAll:_z(e==="text"?ZL:void 0),tokenize:t};function t(i){const l=this,n=this.parser.constructs[e],o=i.attempt(n,s,f);return s;function s(p){return d(p)?o(p):f(p)}function f(p){if(p===null){i.consume(p);return}return i.enter("data"),i.consume(p),m}function m(p){return d(p)?(i.exit("data"),o(p)):(i.consume(p),m)}function d(p){if(p===null)return!0;const v=n[p];let b=-1;if(v)for(;++b<v.length;){const x=v[b];if(!x.previous||x.previous.call(l,l.previous))return!0}return!1}}}function _z(e){return t;function t(i,l){let n=-1,o;for(;++n<=i.length;)o===void 0?i[n]&&i[n][1].type==="data"&&(o=n,n++):(!i[n]||i[n][1].type!=="data")&&(n!==o+2&&(i[o][1].end=i[n-1][1].end,i.splice(o+2,n-o-2),n=o+2),o=void 0);return e?e(i,l):i}}function ZL(e,t){let i=0;for(;++i<=e.length;)if((i===e.length||e[i][1].type==="lineEnding")&&e[i-1][1].type==="data"){const l=e[i-1][1],n=t.sliceStream(l);let o=n.length,s=-1,f=0,m;for(;o--;){const d=n[o];if(typeof d=="string"){for(s=d.length;d.charCodeAt(s-1)===32;)f++,s--;if(s)break;s=-1}else if(d===-2)m=!0,f++;else if(d!==-1){o++;break}}if(t._contentTypeTextTrailing&&i===e.length&&(f=0),f){const d={type:i===e.length||m||f<2?"lineSuffix":"hardBreakTrailing",start:{_bufferIndex:o?s:l.start._bufferIndex+s,_index:l.start._index+o,line:l.end.line,column:l.end.column-f,offset:l.end.offset-f},end:{...l.end}};l.end={...d.start},l.start.offset===l.end.offset?Object.assign(l,d):(e.splice(i,0,["enter",d,t],["exit",d,t]),i+=2)}i++}return e}const qL={42:Wt,43:Wt,45:Wt,48:Wt,49:Wt,50:Wt,51:Wt,52:Wt,53:Wt,54:Wt,55:Wt,56:Wt,57:Wt,62:mz},FL={91:V3},BL={[-2]:kh,[-1]:kh,32:kh},HL={35:W3,42:Cs,45:[M1,Cs],60:rL,61:M1,95:Cs,96:U1,126:U1},GL={38:pz,92:hz},VL={[-5]:wh,[-4]:wh,[-3]:wh,33:_L,38:pz,42:lp,60:[k3,cL],91:kL,92:[Q3,hz],93:zv,95:lp,96:I3},YL={null:[lp,LL]},JL={null:[42,95]},XL={null:[]},QL=Object.freeze(Object.defineProperty({__proto__:null,attentionMarkers:JL,contentInitial:FL,disable:XL,document:qL,flow:HL,flowInitial:BL,insideSpan:YL,string:GL,text:VL},Symbol.toStringTag,{value:"Module"}));function KL(e,t,i){let l={_bufferIndex:-1,_index:0,line:i&&i.line||1,column:i&&i.column||1,offset:i&&i.offset||0};const n={},o=[];let s=[],f=[];const m={attempt:X(J),check:X(R),consume:O,enter:N,exit:G,interrupt:X(R,{interrupt:!0})},d={code:null,containerState:{},defineSkip:w,events:[],now:S,parser:e,previous:null,sliceSerialize:b,sliceStream:x,write:v};let p=t.tokenize.call(d,m);return t.resolveAll&&o.push(t),d;function v(ue){return s=zn(s,ue),j(),s[s.length-1]!==null?[]:(Q(t,0),d.events=Kc(o,d.events,d),d.events)}function b(ue,ce){return eM(x(ue),ce)}function x(ue){return WL(s,ue)}function S(){const{_bufferIndex:ue,_index:ce,line:ke,column:M,offset:U}=l;return{_bufferIndex:ue,_index:ce,line:ke,column:M,offset:U}}function w(ue){n[ue.line]=ue.column,B()}function j(){let ue;for(;l._index<s.length;){const ce=s[l._index];if(typeof ce=="string")for(ue=l._index,l._bufferIndex<0&&(l._bufferIndex=0);l._index===ue&&l._bufferIndex<ce.length;)E(ce.charCodeAt(l._bufferIndex));else E(ce)}}function E(ue){p=p(ue)}function O(ue){ye(ue)?(l.line++,l.column=1,l.offset+=ue===-3?2:1,B()):ue!==-1&&(l.column++,l.offset++),l._bufferIndex<0?l._index++:(l._bufferIndex++,l._bufferIndex===s[l._index].length&&(l._bufferIndex=-1,l._index++)),d.previous=ue}function N(ue,ce){const ke=ce||{};return ke.type=ue,ke.start=S(),d.events.push(["enter",ke,d]),f.push(ke),ke}function G(ue){const ce=f.pop();return ce.end=S(),d.events.push(["exit",ce,d]),ce}function J(ue,ce){Q(ue,ce.from)}function R(ue,ce){ce.restore()}function X(ue,ce){return ke;function ke(M,U,A){let q,te,ie,z;return Array.isArray(M)?Z(M):"tokenize"in M?Z([M]):T(M);function T(pe){return Ie;function Ie(ot){const Ve=ot!==null&&pe[ot],gn=ot!==null&&pe.null,rr=[...Array.isArray(Ve)?Ve:Ve?[Ve]:[],...Array.isArray(gn)?gn:gn?[gn]:[]];return Z(rr)(ot)}}function Z(pe){return q=pe,te=0,pe.length===0?A:$(pe[te])}function $(pe){return Ie;function Ie(ot){return z=me(),ie=pe,pe.partial||(d.currentConstruct=pe),pe.name&&d.parser.constructs.disable.null.includes(pe.name)?de():pe.tokenize.call(ce?Object.assign(Object.create(d),ce):d,m,oe,de)(ot)}}function oe(pe){return ue(ie,z),U}function de(pe){return z.restore(),++te<q.length?$(q[te]):A}}}function Q(ue,ce){ue.resolveAll&&!o.includes(ue)&&o.push(ue),ue.resolve&&mn(d.events,ce,d.events.length-ce,ue.resolve(d.events.slice(ce),d)),ue.resolveTo&&(d.events=ue.resolveTo(d.events,d))}function me(){const ue=S(),ce=d.previous,ke=d.currentConstruct,M=d.events.length,U=Array.from(f);return{from:M,restore:A};function A(){l=ue,d.previous=ce,d.currentConstruct=ke,d.events.length=M,f=U,B()}}function B(){l.line in n&&l.column<2&&(l.column=n[l.line],l.offset+=n[l.line]-1)}}function WL(e,t){const i=t.start._index,l=t.start._bufferIndex,n=t.end._index,o=t.end._bufferIndex;let s;if(i===n)s=[e[i].slice(l,o)];else{if(s=e.slice(i,n),l>-1){const f=s[0];typeof f=="string"?s[0]=f.slice(l):s.shift()}o>0&&s.push(e[n].slice(0,o))}return s}function eM(e,t){let i=-1;const l=[];let n;for(;++i<e.length;){const o=e[i];let s;if(typeof o=="string")s=o;else switch(o){case-5:{s="\r";break}case-4:{s=`
|
|
63
|
+
`;break}case-3:{s=`\r
|
|
64
|
+
`;break}case-2:{s=t?" ":" ";break}case-1:{if(!t&&n)continue;s=" ";break}default:s=String.fromCharCode(o)}n=o===-2,l.push(s)}return l.join("")}function tM(e){const l={constructs:fz([QL,...(e||{}).extensions||[]]),content:n(g3),defined:[],document:n(y3),flow:n(IL),lazy:{},string:n(ML),text:n(PL)};return l;function n(o){return s;function s(f){return KL(l,o,f)}}}function nM(e){for(;!gz(e););return e}const P1=/[\0\t\n\r]/g;function rM(){let e=1,t="",i=!0,l;return n;function n(o,s,f){const m=[];let d,p,v,b,x;for(o=t+(typeof o=="string"?o.toString():new TextDecoder(s||void 0).decode(o)),v=0,t="",i&&(o.charCodeAt(0)===65279&&v++,i=void 0);v<o.length;){if(P1.lastIndex=v,d=P1.exec(o),b=d&&d.index!==void 0?d.index:o.length,x=o.charCodeAt(b),!d){t=o.slice(v);break}if(x===10&&v===b&&l)m.push(-3),l=void 0;else switch(l&&(m.push(-5),l=void 0),v<b&&(m.push(o.slice(v,b)),e+=b-v),x){case 0:{m.push(65533),e++;break}case 9:{for(p=Math.ceil(e/4)*4,m.push(-2);e++<p;)m.push(-1);break}case 10:{m.push(-4),e=1;break}default:l=!0,e=1}v=b+1}return f&&(l&&m.push(-5),t&&m.push(t),m.push(null)),m}}const iM=/\\([!-/:-@[-`{-~])|&(#(?:\d{1,7}|x[\da-f]{1,6})|[\da-z]{1,31});/gi;function aM(e){return e.replace(iM,lM)}function lM(e,t,i){if(t)return t;if(i.charCodeAt(0)===35){const n=i.charCodeAt(1),o=n===120||n===88;return dz(i.slice(o?2:1),o?16:10)}return jv(i)||e}const Sz={}.hasOwnProperty;function oM(e,t,i){return typeof t!="string"&&(i=t,t=void 0),uM(i)(nM(tM(i).document().write(rM()(e,t,!0))))}function uM(e){const t={transforms:[],canContainEols:["emphasis","fragment","heading","paragraph","strong"],enter:{autolink:o(Yi),autolinkProtocol:me,autolinkEmail:me,atxHeading:o(Gi),blockQuote:o(gn),characterEscape:me,characterReference:me,codeFenced:o(rr),codeFencedFenceInfo:s,codeFencedFenceMeta:s,codeIndented:o(rr,s),codeText:o(ll,s),codeTextData:me,data:me,codeFlowValue:me,definition:o(eu),definitionDestinationString:s,definitionLabelString:s,definitionTitleString:s,emphasis:o(ir),hardBreakEscape:o(Vi),hardBreakTrailing:o(Vi),htmlFlow:o(tu,s),htmlFlowData:me,htmlText:o(tu,s),htmlTextData:me,image:o(nu),label:s,link:o(Yi),listItem:o(ol),listItemValue:b,listOrdered:o(Ji,v),listUnordered:o(Ji),paragraph:o(nf),reference:$,referenceString:s,resourceDestinationString:s,resourceTitleString:s,setextHeading:o(Gi),strong:o(rf),thematicBreak:o(af)},exit:{atxHeading:m(),atxHeadingSequence:J,autolink:m(),autolinkEmail:Ve,autolinkProtocol:ot,blockQuote:m(),characterEscapeValue:B,characterReferenceMarkerHexadecimal:de,characterReferenceMarkerNumeric:de,characterReferenceValue:pe,characterReference:Ie,codeFenced:m(j),codeFencedFence:w,codeFencedFenceInfo:x,codeFencedFenceMeta:S,codeFlowValue:B,codeIndented:m(E),codeText:m(U),codeTextData:B,data:B,definition:m(),definitionDestinationString:G,definitionLabelString:O,definitionTitleString:N,emphasis:m(),hardBreakEscape:m(ce),hardBreakTrailing:m(ce),htmlFlow:m(ke),htmlFlowData:B,htmlText:m(M),htmlTextData:B,image:m(q),label:ie,labelText:te,lineEnding:ue,link:m(A),listItem:m(),listOrdered:m(),listUnordered:m(),paragraph:m(),referenceString:oe,resourceDestinationString:z,resourceTitleString:T,resource:Z,setextHeading:m(Q),setextHeadingLineSequence:X,setextHeadingText:R,strong:m(),thematicBreak:m()}};kz(t,(e||{}).mdastExtensions||[]);const i={};return l;function l(W){let se={type:"root",children:[]};const _e={stack:[se],tokenStack:[],config:t,enter:f,exit:d,buffer:s,resume:p,data:i},Ce=[];let Be=-1;for(;++Be<W.length;)if(W[Be][1].type==="listOrdered"||W[Be][1].type==="listUnordered")if(W[Be][0]==="enter")Ce.push(Be);else{const nn=Ce.pop();Be=n(W,nn,Be)}for(Be=-1;++Be<W.length;){const nn=t[W[Be][0]];Sz.call(nn,W[Be][1].type)&&nn[W[Be][1].type].call(Object.assign({sliceSerialize:W[Be][2].sliceSerialize},_e),W[Be][1])}if(_e.tokenStack.length>0){const nn=_e.tokenStack[_e.tokenStack.length-1];(nn[1]||Z1).call(_e,void 0,nn[0])}for(se.position={start:ri(W.length>0?W[0][1].start:{line:1,column:1,offset:0}),end:ri(W.length>0?W[W.length-2][1].end:{line:1,column:1,offset:0})},Be=-1;++Be<t.transforms.length;)se=t.transforms[Be](se)||se;return se}function n(W,se,_e){let Ce=se-1,Be=-1,nn=!1,ar,Mt,St,Ht;for(;++Ce<=_e;){const Qe=W[Ce];switch(Qe[1].type){case"listUnordered":case"listOrdered":case"blockQuote":{Qe[0]==="enter"?Be++:Be--,Ht=void 0;break}case"lineEndingBlank":{Qe[0]==="enter"&&(ar&&!Ht&&!Be&&!St&&(St=Ce),Ht=void 0);break}case"linePrefix":case"listItemValue":case"listItemMarker":case"listItemPrefix":case"listItemPrefixWhitespace":break;default:Ht=void 0}if(!Be&&Qe[0]==="enter"&&Qe[1].type==="listItemPrefix"||Be===-1&&Qe[0]==="exit"&&(Qe[1].type==="listUnordered"||Qe[1].type==="listOrdered")){if(ar){let Cr=Ce;for(Mt=void 0;Cr--;){const In=W[Cr];if(In[1].type==="lineEnding"||In[1].type==="lineEndingBlank"){if(In[0]==="exit")continue;Mt&&(W[Mt][1].type="lineEndingBlank",nn=!0),In[1].type="lineEnding",Mt=Cr}else if(!(In[1].type==="linePrefix"||In[1].type==="blockQuotePrefix"||In[1].type==="blockQuotePrefixWhitespace"||In[1].type==="blockQuoteMarker"||In[1].type==="listItemIndent"))break}St&&(!Mt||St<Mt)&&(ar._spread=!0),ar.end=Object.assign({},Mt?W[Mt][1].start:Qe[1].end),W.splice(Mt||Ce,0,["exit",ar,Qe[2]]),Ce++,_e++}if(Qe[1].type==="listItemPrefix"){const Cr={type:"listItem",_spread:!1,start:Object.assign({},Qe[1].start),end:void 0};ar=Cr,W.splice(Ce,0,["enter",Cr,Qe[2]]),Ce++,_e++,St=void 0,Ht=!0}}}return W[se][1]._spread=nn,_e}function o(W,se){return _e;function _e(Ce){f.call(this,W(Ce),Ce),se&&se.call(this,Ce)}}function s(){this.stack.push({type:"fragment",children:[]})}function f(W,se,_e){this.stack[this.stack.length-1].children.push(W),this.stack.push(W),this.tokenStack.push([se,_e||void 0]),W.position={start:ri(se.start),end:void 0}}function m(W){return se;function se(_e){W&&W.call(this,_e),d.call(this,_e)}}function d(W,se){const _e=this.stack.pop(),Ce=this.tokenStack.pop();if(Ce)Ce[0].type!==W.type&&(se?se.call(this,W,Ce[0]):(Ce[1]||Z1).call(this,W,Ce[0]));else throw new Error("Cannot close `"+W.type+"` ("+uo({start:W.start,end:W.end})+"): it’s not open");_e.position.end=ri(W.end)}function p(){return Ev(this.stack.pop())}function v(){this.data.expectingFirstListItemValue=!0}function b(W){if(this.data.expectingFirstListItemValue){const se=this.stack[this.stack.length-2];se.start=Number.parseInt(this.sliceSerialize(W),10),this.data.expectingFirstListItemValue=void 0}}function x(){const W=this.resume(),se=this.stack[this.stack.length-1];se.lang=W}function S(){const W=this.resume(),se=this.stack[this.stack.length-1];se.meta=W}function w(){this.data.flowCodeInside||(this.buffer(),this.data.flowCodeInside=!0)}function j(){const W=this.resume(),se=this.stack[this.stack.length-1];se.value=W.replace(/^(\r?\n|\r)|(\r?\n|\r)$/g,""),this.data.flowCodeInside=void 0}function E(){const W=this.resume(),se=this.stack[this.stack.length-1];se.value=W.replace(/(\r?\n|\r)$/g,"")}function O(W){const se=this.resume(),_e=this.stack[this.stack.length-1];_e.label=se,_e.identifier=Zn(this.sliceSerialize(W)).toLowerCase()}function N(){const W=this.resume(),se=this.stack[this.stack.length-1];se.title=W}function G(){const W=this.resume(),se=this.stack[this.stack.length-1];se.url=W}function J(W){const se=this.stack[this.stack.length-1];if(!se.depth){const _e=this.sliceSerialize(W).length;se.depth=_e}}function R(){this.data.setextHeadingSlurpLineEnding=!0}function X(W){const se=this.stack[this.stack.length-1];se.depth=this.sliceSerialize(W).codePointAt(0)===61?1:2}function Q(){this.data.setextHeadingSlurpLineEnding=void 0}function me(W){const _e=this.stack[this.stack.length-1].children;let Ce=_e[_e.length-1];(!Ce||Ce.type!=="text")&&(Ce=Lt(),Ce.position={start:ri(W.start),end:void 0},_e.push(Ce)),this.stack.push(Ce)}function B(W){const se=this.stack.pop();se.value+=this.sliceSerialize(W),se.position.end=ri(W.end)}function ue(W){const se=this.stack[this.stack.length-1];if(this.data.atHardBreak){const _e=se.children[se.children.length-1];_e.position.end=ri(W.end),this.data.atHardBreak=void 0;return}!this.data.setextHeadingSlurpLineEnding&&t.canContainEols.includes(se.type)&&(me.call(this,W),B.call(this,W))}function ce(){this.data.atHardBreak=!0}function ke(){const W=this.resume(),se=this.stack[this.stack.length-1];se.value=W}function M(){const W=this.resume(),se=this.stack[this.stack.length-1];se.value=W}function U(){const W=this.resume(),se=this.stack[this.stack.length-1];se.value=W}function A(){const W=this.stack[this.stack.length-1];if(this.data.inReference){const se=this.data.referenceType||"shortcut";W.type+="Reference",W.referenceType=se,delete W.url,delete W.title}else delete W.identifier,delete W.label;this.data.referenceType=void 0}function q(){const W=this.stack[this.stack.length-1];if(this.data.inReference){const se=this.data.referenceType||"shortcut";W.type+="Reference",W.referenceType=se,delete W.url,delete W.title}else delete W.identifier,delete W.label;this.data.referenceType=void 0}function te(W){const se=this.sliceSerialize(W),_e=this.stack[this.stack.length-2];_e.label=aM(se),_e.identifier=Zn(se).toLowerCase()}function ie(){const W=this.stack[this.stack.length-1],se=this.resume(),_e=this.stack[this.stack.length-1];if(this.data.inReference=!0,_e.type==="link"){const Ce=W.children;_e.children=Ce}else _e.alt=se}function z(){const W=this.resume(),se=this.stack[this.stack.length-1];se.url=W}function T(){const W=this.resume(),se=this.stack[this.stack.length-1];se.title=W}function Z(){this.data.inReference=void 0}function $(){this.data.referenceType="collapsed"}function oe(W){const se=this.resume(),_e=this.stack[this.stack.length-1];_e.label=se,_e.identifier=Zn(this.sliceSerialize(W)).toLowerCase(),this.data.referenceType="full"}function de(W){this.data.characterReferenceType=W.type}function pe(W){const se=this.sliceSerialize(W),_e=this.data.characterReferenceType;let Ce;_e?(Ce=dz(se,_e==="characterReferenceMarkerNumeric"?10:16),this.data.characterReferenceType=void 0):Ce=jv(se);const Be=this.stack[this.stack.length-1];Be.value+=Ce}function Ie(W){const se=this.stack.pop();se.position.end=ri(W.end)}function ot(W){B.call(this,W);const se=this.stack[this.stack.length-1];se.url=this.sliceSerialize(W)}function Ve(W){B.call(this,W);const se=this.stack[this.stack.length-1];se.url="mailto:"+this.sliceSerialize(W)}function gn(){return{type:"blockquote",children:[]}}function rr(){return{type:"code",lang:null,meta:null,value:""}}function ll(){return{type:"inlineCode",value:""}}function eu(){return{type:"definition",identifier:"",label:null,title:null,url:""}}function ir(){return{type:"emphasis",children:[]}}function Gi(){return{type:"heading",depth:0,children:[]}}function Vi(){return{type:"break"}}function tu(){return{type:"html",value:""}}function nu(){return{type:"image",title:null,url:"",alt:null}}function Yi(){return{type:"link",title:null,url:"",children:[]}}function Ji(W){return{type:"list",ordered:W.type==="listOrdered",start:null,spread:W._spread,children:[]}}function ol(W){return{type:"listItem",spread:W._spread,checked:null,children:[]}}function nf(){return{type:"paragraph",children:[]}}function rf(){return{type:"strong",children:[]}}function Lt(){return{type:"text",value:""}}function af(){return{type:"thematicBreak"}}}function ri(e){return{line:e.line,column:e.column,offset:e.offset}}function kz(e,t){let i=-1;for(;++i<t.length;){const l=t[i];Array.isArray(l)?kz(e,l):sM(e,l)}}function sM(e,t){let i;for(i in t)if(Sz.call(t,i))switch(i){case"canContainEols":{const l=t[i];l&&e[i].push(...l);break}case"transforms":{const l=t[i];l&&e[i].push(...l);break}case"enter":case"exit":{const l=t[i];l&&Object.assign(e[i],l);break}}}function Z1(e,t){throw e?new Error("Cannot close `"+e.type+"` ("+uo({start:e.start,end:e.end})+"): a different token (`"+t.type+"`, "+uo({start:t.start,end:t.end})+") is open"):new Error("Cannot close document, a token (`"+t.type+"`, "+uo({start:t.start,end:t.end})+") is still open")}function cM(e){const t=this;t.parser=i;function i(l){return oM(l,{...t.data("settings"),...e,extensions:t.data("micromarkExtensions")||[],mdastExtensions:t.data("fromMarkdownExtensions")||[]})}}function fM(e,t){const i={type:"element",tagName:"blockquote",properties:{},children:e.wrap(e.all(t),!0)};return e.patch(t,i),e.applyData(t,i)}function dM(e,t){const i={type:"element",tagName:"br",properties:{},children:[]};return e.patch(t,i),[e.applyData(t,i),{type:"text",value:`
|
|
65
|
+
`}]}function mM(e,t){const i=t.value?t.value+`
|
|
66
|
+
`:"",l={},n=t.lang?t.lang.split(/\s+/):[];n.length>0&&(l.className=["language-"+n[0]]);let o={type:"element",tagName:"code",properties:l,children:[{type:"text",value:i}]};return t.meta&&(o.data={meta:t.meta}),e.patch(t,o),o=e.applyData(t,o),o={type:"element",tagName:"pre",properties:{},children:[o]},e.patch(t,o),o}function hM(e,t){const i={type:"element",tagName:"del",properties:{},children:e.all(t)};return e.patch(t,i),e.applyData(t,i)}function pM(e,t){const i={type:"element",tagName:"em",properties:{},children:e.all(t)};return e.patch(t,i),e.applyData(t,i)}function gM(e,t){const i=typeof e.options.clobberPrefix=="string"?e.options.clobberPrefix:"user-content-",l=String(t.identifier).toUpperCase(),n=al(l.toLowerCase()),o=e.footnoteOrder.indexOf(l);let s,f=e.footnoteCounts.get(l);f===void 0?(f=0,e.footnoteOrder.push(l),s=e.footnoteOrder.length):s=o+1,f+=1,e.footnoteCounts.set(l,f);const m={type:"element",tagName:"a",properties:{href:"#"+i+"fn-"+n,id:i+"fnref-"+n+(f>1?"-"+f:""),dataFootnoteRef:!0,ariaDescribedBy:["footnote-label"]},children:[{type:"text",value:String(s)}]};e.patch(t,m);const d={type:"element",tagName:"sup",properties:{},children:[m]};return e.patch(t,d),e.applyData(t,d)}function vM(e,t){const i={type:"element",tagName:"h"+t.depth,properties:{},children:e.all(t)};return e.patch(t,i),e.applyData(t,i)}function yM(e,t){if(e.options.allowDangerousHtml){const i={type:"raw",value:t.value};return e.patch(t,i),e.applyData(t,i)}}function wz(e,t){const i=t.referenceType;let l="]";if(i==="collapsed"?l+="[]":i==="full"&&(l+="["+(t.label||t.identifier)+"]"),t.type==="imageReference")return[{type:"text",value:"!["+t.alt+l}];const n=e.all(t),o=n[0];o&&o.type==="text"?o.value="["+o.value:n.unshift({type:"text",value:"["});const s=n[n.length-1];return s&&s.type==="text"?s.value+=l:n.push({type:"text",value:l}),n}function bM(e,t){const i=String(t.identifier).toUpperCase(),l=e.definitionById.get(i);if(!l)return wz(e,t);const n={src:al(l.url||""),alt:t.alt};l.title!==null&&l.title!==void 0&&(n.title=l.title);const o={type:"element",tagName:"img",properties:n,children:[]};return e.patch(t,o),e.applyData(t,o)}function xM(e,t){const i={src:al(t.url)};t.alt!==null&&t.alt!==void 0&&(i.alt=t.alt),t.title!==null&&t.title!==void 0&&(i.title=t.title);const l={type:"element",tagName:"img",properties:i,children:[]};return e.patch(t,l),e.applyData(t,l)}function _M(e,t){const i={type:"text",value:t.value.replace(/\r?\n|\r/g," ")};e.patch(t,i);const l={type:"element",tagName:"code",properties:{},children:[i]};return e.patch(t,l),e.applyData(t,l)}function SM(e,t){const i=String(t.identifier).toUpperCase(),l=e.definitionById.get(i);if(!l)return wz(e,t);const n={href:al(l.url||"")};l.title!==null&&l.title!==void 0&&(n.title=l.title);const o={type:"element",tagName:"a",properties:n,children:e.all(t)};return e.patch(t,o),e.applyData(t,o)}function kM(e,t){const i={href:al(t.url)};t.title!==null&&t.title!==void 0&&(i.title=t.title);const l={type:"element",tagName:"a",properties:i,children:e.all(t)};return e.patch(t,l),e.applyData(t,l)}function wM(e,t,i){const l=e.all(t),n=i?$M(i):$z(t),o={},s=[];if(typeof t.checked=="boolean"){const p=l[0];let v;p&&p.type==="element"&&p.tagName==="p"?v=p:(v={type:"element",tagName:"p",properties:{},children:[]},l.unshift(v)),v.children.length>0&&v.children.unshift({type:"text",value:" "}),v.children.unshift({type:"element",tagName:"input",properties:{type:"checkbox",checked:t.checked,disabled:!0},children:[]}),o.className=["task-list-item"]}let f=-1;for(;++f<l.length;){const p=l[f];(n||f!==0||p.type!=="element"||p.tagName!=="p")&&s.push({type:"text",value:`
|
|
67
|
+
`}),p.type==="element"&&p.tagName==="p"&&!n?s.push(...p.children):s.push(p)}const m=l[l.length-1];m&&(n||m.type!=="element"||m.tagName!=="p")&&s.push({type:"text",value:`
|
|
68
|
+
`});const d={type:"element",tagName:"li",properties:o,children:s};return e.patch(t,d),e.applyData(t,d)}function $M(e){let t=!1;if(e.type==="list"){t=e.spread||!1;const i=e.children;let l=-1;for(;!t&&++l<i.length;)t=$z(i[l])}return t}function $z(e){const t=e.spread;return t??e.children.length>1}function EM(e,t){const i={},l=e.all(t);let n=-1;for(typeof t.start=="number"&&t.start!==1&&(i.start=t.start);++n<l.length;){const s=l[n];if(s.type==="element"&&s.tagName==="li"&&s.properties&&Array.isArray(s.properties.className)&&s.properties.className.includes("task-list-item")){i.className=["contains-task-list"];break}}const o={type:"element",tagName:t.ordered?"ol":"ul",properties:i,children:e.wrap(l,!0)};return e.patch(t,o),e.applyData(t,o)}function jM(e,t){const i={type:"element",tagName:"p",properties:{},children:e.all(t)};return e.patch(t,i),e.applyData(t,i)}function zM(e,t){const i={type:"root",children:e.wrap(e.all(t))};return e.patch(t,i),e.applyData(t,i)}function NM(e,t){const i={type:"element",tagName:"strong",properties:{},children:e.all(t)};return e.patch(t,i),e.applyData(t,i)}function OM(e,t){const i=e.all(t),l=i.shift(),n=[];if(l){const s={type:"element",tagName:"thead",properties:{},children:e.wrap([l],!0)};e.patch(t.children[0],s),n.push(s)}if(i.length>0){const s={type:"element",tagName:"tbody",properties:{},children:e.wrap(i,!0)},f=Sv(t.children[1]),m=iz(t.children[t.children.length-1]);f&&m&&(s.position={start:f,end:m}),n.push(s)}const o={type:"element",tagName:"table",properties:{},children:e.wrap(n,!0)};return e.patch(t,o),e.applyData(t,o)}function TM(e,t,i){const l=i?i.children:void 0,o=(l?l.indexOf(t):1)===0?"th":"td",s=i&&i.type==="table"?i.align:void 0,f=s?s.length:t.children.length;let m=-1;const d=[];for(;++m<f;){const v=t.children[m],b={},x=s?s[m]:void 0;x&&(b.align=x);let S={type:"element",tagName:o,properties:b,children:[]};v&&(S.children=e.all(v),e.patch(v,S),S=e.applyData(v,S)),d.push(S)}const p={type:"element",tagName:"tr",properties:{},children:e.wrap(d,!0)};return e.patch(t,p),e.applyData(t,p)}function CM(e,t){const i={type:"element",tagName:"td",properties:{},children:e.all(t)};return e.patch(t,i),e.applyData(t,i)}const q1=9,F1=32;function DM(e){const t=String(e),i=/\r?\n|\r/g;let l=i.exec(t),n=0;const o=[];for(;l;)o.push(B1(t.slice(n,l.index),n>0,!0),l[0]),n=l.index+l[0].length,l=i.exec(t);return o.push(B1(t.slice(n),n>0,!1)),o.join("")}function B1(e,t,i){let l=0,n=e.length;if(t){let o=e.codePointAt(l);for(;o===q1||o===F1;)l++,o=e.codePointAt(l)}if(i){let o=e.codePointAt(n-1);for(;o===q1||o===F1;)n--,o=e.codePointAt(n-1)}return n>l?e.slice(l,n):""}function AM(e,t){const i={type:"text",value:DM(String(t.value))};return e.patch(t,i),e.applyData(t,i)}function RM(e,t){const i={type:"element",tagName:"hr",properties:{},children:[]};return e.patch(t,i),e.applyData(t,i)}const IM={blockquote:fM,break:dM,code:mM,delete:hM,emphasis:pM,footnoteReference:gM,heading:vM,html:yM,imageReference:bM,image:xM,inlineCode:_M,linkReference:SM,link:kM,listItem:wM,list:EM,paragraph:jM,root:zM,strong:NM,table:OM,tableCell:CM,tableRow:TM,text:AM,thematicBreak:RM,toml:Es,yaml:Es,definition:Es,footnoteDefinition:Es};function Es(){}const Ez=-1,Wc=0,co=1,Gs=2,Nv=3,Ov=4,Tv=5,Cv=6,jz=7,zz=8,H1=typeof self=="object"?self:globalThis,UM=(e,t)=>{const i=(n,o)=>(e.set(o,n),n),l=n=>{if(e.has(n))return e.get(n);const[o,s]=t[n];switch(o){case Wc:case Ez:return i(s,n);case co:{const f=i([],n);for(const m of s)f.push(l(m));return f}case Gs:{const f=i({},n);for(const[m,d]of s)f[l(m)]=l(d);return f}case Nv:return i(new Date(s),n);case Ov:{const{source:f,flags:m}=s;return i(new RegExp(f,m),n)}case Tv:{const f=i(new Map,n);for(const[m,d]of s)f.set(l(m),l(d));return f}case Cv:{const f=i(new Set,n);for(const m of s)f.add(l(m));return f}case jz:{const{name:f,message:m}=s;return i(new H1[f](m),n)}case zz:return i(BigInt(s),n);case"BigInt":return i(Object(BigInt(s)),n);case"ArrayBuffer":return i(new Uint8Array(s).buffer,s);case"DataView":{const{buffer:f}=new Uint8Array(s);return i(new DataView(f),s)}}return i(new H1[o](s),n)};return l},G1=e=>UM(new Map,e)(0),Ua="",{toString:LM}={},{keys:MM}=Object,lo=e=>{const t=typeof e;if(t!=="object"||!e)return[Wc,t];const i=LM.call(e).slice(8,-1);switch(i){case"Array":return[co,Ua];case"Object":return[Gs,Ua];case"Date":return[Nv,Ua];case"RegExp":return[Ov,Ua];case"Map":return[Tv,Ua];case"Set":return[Cv,Ua];case"DataView":return[co,i]}return i.includes("Array")?[co,i]:i.includes("Error")?[jz,i]:[Gs,i]},js=([e,t])=>e===Wc&&(t==="function"||t==="symbol"),PM=(e,t,i,l)=>{const n=(s,f)=>{const m=l.push(s)-1;return i.set(f,m),m},o=s=>{if(i.has(s))return i.get(s);let[f,m]=lo(s);switch(f){case Wc:{let p=s;switch(m){case"bigint":f=zz,p=s.toString();break;case"function":case"symbol":if(e)throw new TypeError("unable to serialize "+m);p=null;break;case"undefined":return n([Ez],s)}return n([f,p],s)}case co:{if(m){let b=s;return m==="DataView"?b=new Uint8Array(s.buffer):m==="ArrayBuffer"&&(b=new Uint8Array(s)),n([m,[...b]],s)}const p=[],v=n([f,p],s);for(const b of s)p.push(o(b));return v}case Gs:{if(m)switch(m){case"BigInt":return n([m,s.toString()],s);case"Boolean":case"Number":case"String":return n([m,s.valueOf()],s)}if(t&&"toJSON"in s)return o(s.toJSON());const p=[],v=n([f,p],s);for(const b of MM(s))(e||!js(lo(s[b])))&&p.push([o(b),o(s[b])]);return v}case Nv:return n([f,s.toISOString()],s);case Ov:{const{source:p,flags:v}=s;return n([f,{source:p,flags:v}],s)}case Tv:{const p=[],v=n([f,p],s);for(const[b,x]of s)(e||!(js(lo(b))||js(lo(x))))&&p.push([o(b),o(x)]);return v}case Cv:{const p=[],v=n([f,p],s);for(const b of s)(e||!js(lo(b)))&&p.push(o(b));return v}}const{message:d}=s;return n([f,{name:m,message:d}],s)};return o},V1=(e,{json:t,lossy:i}={})=>{const l=[];return PM(!(t||i),!!t,new Map,l)(e),l},Vs=typeof structuredClone=="function"?(e,t)=>t&&("json"in t||"lossy"in t)?G1(V1(e,t)):structuredClone(e):(e,t)=>G1(V1(e,t));function ZM(e,t){const i=[{type:"text",value:"↩"}];return t>1&&i.push({type:"element",tagName:"sup",properties:{},children:[{type:"text",value:String(t)}]}),i}function qM(e,t){return"Back to reference "+(e+1)+(t>1?"-"+t:"")}function FM(e){const t=typeof e.options.clobberPrefix=="string"?e.options.clobberPrefix:"user-content-",i=e.options.footnoteBackContent||ZM,l=e.options.footnoteBackLabel||qM,n=e.options.footnoteLabel||"Footnotes",o=e.options.footnoteLabelTagName||"h2",s=e.options.footnoteLabelProperties||{className:["sr-only"]},f=[];let m=-1;for(;++m<e.footnoteOrder.length;){const d=e.footnoteById.get(e.footnoteOrder[m]);if(!d)continue;const p=e.all(d),v=String(d.identifier).toUpperCase(),b=al(v.toLowerCase());let x=0;const S=[],w=e.footnoteCounts.get(v);for(;w!==void 0&&++x<=w;){S.length>0&&S.push({type:"text",value:" "});let O=typeof i=="string"?i:i(m,x);typeof O=="string"&&(O={type:"text",value:O}),S.push({type:"element",tagName:"a",properties:{href:"#"+t+"fnref-"+b+(x>1?"-"+x:""),dataFootnoteBackref:"",ariaLabel:typeof l=="string"?l:l(m,x),className:["data-footnote-backref"]},children:Array.isArray(O)?O:[O]})}const j=p[p.length-1];if(j&&j.type==="element"&&j.tagName==="p"){const O=j.children[j.children.length-1];O&&O.type==="text"?O.value+=" ":j.children.push({type:"text",value:" "}),j.children.push(...S)}else p.push(...S);const E={type:"element",tagName:"li",properties:{id:t+"fn-"+b},children:e.wrap(p,!0)};e.patch(d,E),f.push(E)}if(f.length!==0)return{type:"element",tagName:"section",properties:{dataFootnotes:!0,className:["footnotes"]},children:[{type:"element",tagName:o,properties:{...Vs(s),id:"footnote-label"},children:[{type:"text",value:n}]},{type:"text",value:`
|
|
69
|
+
`},{type:"element",tagName:"ol",properties:{},children:e.wrap(f,!0)},{type:"text",value:`
|
|
70
|
+
`}]}}const ef=(function(e){if(e==null)return VM;if(typeof e=="function")return tf(e);if(typeof e=="object")return Array.isArray(e)?BM(e):HM(e);if(typeof e=="string")return GM(e);throw new Error("Expected function, string, or object as test")});function BM(e){const t=[];let i=-1;for(;++i<e.length;)t[i]=ef(e[i]);return tf(l);function l(...n){let o=-1;for(;++o<t.length;)if(t[o].apply(this,n))return!0;return!1}}function HM(e){const t=e;return tf(i);function i(l){const n=l;let o;for(o in e)if(n[o]!==t[o])return!1;return!0}}function GM(e){return tf(t);function t(i){return i&&i.type===e}}function tf(e){return t;function t(i,l,n){return!!(YM(i)&&e.call(this,i,typeof l=="number"?l:void 0,n||void 0))}}function VM(){return!0}function YM(e){return e!==null&&typeof e=="object"&&"type"in e}const Nz=[],JM=!0,op=!1,XM="skip";function Oz(e,t,i,l){let n;typeof t=="function"&&typeof i!="function"?(l=i,i=t):n=t;const o=ef(n),s=l?-1:1;f(e,void 0,[])();function f(m,d,p){const v=m&&typeof m=="object"?m:{};if(typeof v.type=="string"){const x=typeof v.tagName=="string"?v.tagName:typeof v.name=="string"?v.name:void 0;Object.defineProperty(b,"name",{value:"node ("+(m.type+(x?"<"+x+">":""))+")"})}return b;function b(){let x=Nz,S,w,j;if((!t||o(m,d,p[p.length-1]||void 0))&&(x=QM(i(m,p)),x[0]===op))return x;if("children"in m&&m.children){const E=m;if(E.children&&x[0]!==XM)for(w=(l?E.children.length:-1)+s,j=p.concat(E);w>-1&&w<E.children.length;){const O=E.children[w];if(S=f(O,w,j)(),S[0]===op)return S;w=typeof S[1]=="number"?S[1]:w+s}}return x}}}function QM(e){return Array.isArray(e)?e:typeof e=="number"?[JM,e]:e==null?Nz:[e]}function Dv(e,t,i,l){let n,o,s;typeof t=="function"&&typeof i!="function"?(o=void 0,s=t,n=i):(o=t,s=i,n=l),Oz(e,o,f,n);function f(m,d){const p=d[d.length-1],v=p?p.children.indexOf(m):void 0;return s(m,v,p)}}const up={}.hasOwnProperty,KM={};function WM(e,t){const i=t||KM,l=new Map,n=new Map,o=new Map,s={...IM,...i.handlers},f={all:d,applyData:t5,definitionById:l,footnoteById:n,footnoteCounts:o,footnoteOrder:[],handlers:s,one:m,options:i,patch:e5,wrap:r5};return Dv(e,function(p){if(p.type==="definition"||p.type==="footnoteDefinition"){const v=p.type==="definition"?l:n,b=String(p.identifier).toUpperCase();v.has(b)||v.set(b,p)}}),f;function m(p,v){const b=p.type,x=f.handlers[b];if(up.call(f.handlers,b)&&x)return x(f,p,v);if(f.options.passThrough&&f.options.passThrough.includes(b)){if("children"in p){const{children:w,...j}=p,E=Vs(j);return E.children=f.all(p),E}return Vs(p)}return(f.options.unknownHandler||n5)(f,p,v)}function d(p){const v=[];if("children"in p){const b=p.children;let x=-1;for(;++x<b.length;){const S=f.one(b[x],p);if(S){if(x&&b[x-1].type==="break"&&(!Array.isArray(S)&&S.type==="text"&&(S.value=Y1(S.value)),!Array.isArray(S)&&S.type==="element")){const w=S.children[0];w&&w.type==="text"&&(w.value=Y1(w.value))}Array.isArray(S)?v.push(...S):v.push(S)}}}return v}}function e5(e,t){e.position&&(t.position=qU(e))}function t5(e,t){let i=t;if(e&&e.data){const l=e.data.hName,n=e.data.hChildren,o=e.data.hProperties;if(typeof l=="string")if(i.type==="element")i.tagName=l;else{const s="children"in i?i.children:[i];i={type:"element",tagName:l,properties:{},children:s}}i.type==="element"&&o&&Object.assign(i.properties,Vs(o)),"children"in i&&i.children&&n!==null&&n!==void 0&&(i.children=n)}return i}function n5(e,t){const i=t.data||{},l="value"in t&&!(up.call(i,"hProperties")||up.call(i,"hChildren"))?{type:"text",value:t.value}:{type:"element",tagName:"div",properties:{},children:e.all(t)};return e.patch(t,l),e.applyData(t,l)}function r5(e,t){const i=[];let l=-1;for(t&&i.push({type:"text",value:`
|
|
71
|
+
`});++l<e.length;)l&&i.push({type:"text",value:`
|
|
72
|
+
`}),i.push(e[l]);return t&&e.length>0&&i.push({type:"text",value:`
|
|
73
|
+
`}),i}function Y1(e){let t=0,i=e.charCodeAt(t);for(;i===9||i===32;)t++,i=e.charCodeAt(t);return e.slice(t)}function J1(e,t){const i=WM(e,t),l=i.one(e,void 0),n=FM(i),o=Array.isArray(l)?{type:"root",children:l}:l||{type:"root",children:[]};return n&&o.children.push({type:"text",value:`
|
|
74
|
+
`},n),o}function i5(e,t){return e&&"run"in e?async function(i,l){const n=J1(i,{file:l,...t});await e.run(n,l)}:function(i,l){return J1(i,{file:l,...e||t})}}function X1(e){if(e)throw e}var $h,Q1;function a5(){if(Q1)return $h;Q1=1;var e=Object.prototype.hasOwnProperty,t=Object.prototype.toString,i=Object.defineProperty,l=Object.getOwnPropertyDescriptor,n=function(d){return typeof Array.isArray=="function"?Array.isArray(d):t.call(d)==="[object Array]"},o=function(d){if(!d||t.call(d)!=="[object Object]")return!1;var p=e.call(d,"constructor"),v=d.constructor&&d.constructor.prototype&&e.call(d.constructor.prototype,"isPrototypeOf");if(d.constructor&&!p&&!v)return!1;var b;for(b in d);return typeof b>"u"||e.call(d,b)},s=function(d,p){i&&p.name==="__proto__"?i(d,p.name,{enumerable:!0,configurable:!0,value:p.newValue,writable:!0}):d[p.name]=p.newValue},f=function(d,p){if(p==="__proto__")if(e.call(d,p)){if(l)return l(d,p).value}else return;return d[p]};return $h=function m(){var d,p,v,b,x,S,w=arguments[0],j=1,E=arguments.length,O=!1;for(typeof w=="boolean"&&(O=w,w=arguments[1]||{},j=2),(w==null||typeof w!="object"&&typeof w!="function")&&(w={});j<E;++j)if(d=arguments[j],d!=null)for(p in d)v=f(w,p),b=f(d,p),w!==b&&(O&&b&&(o(b)||(x=n(b)))?(x?(x=!1,S=v&&n(v)?v:[]):S=v&&o(v)?v:{},s(w,{name:p,newValue:m(O,S,b)})):typeof b<"u"&&s(w,{name:p,newValue:b}));return w},$h}var l5=a5();const Eh=_o(l5);function sp(e){if(typeof e!="object"||e===null)return!1;const t=Object.getPrototypeOf(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)}function o5(){const e=[],t={run:i,use:l};return t;function i(...n){let o=-1;const s=n.pop();if(typeof s!="function")throw new TypeError("Expected function as last argument, not "+s);f(null,...n);function f(m,...d){const p=e[++o];let v=-1;if(m){s(m);return}for(;++v<n.length;)(d[v]===null||d[v]===void 0)&&(d[v]=n[v]);n=d,p?u5(p,f)(...d):s(null,...d)}}function l(n){if(typeof n!="function")throw new TypeError("Expected `middelware` to be a function, not "+n);return e.push(n),t}}function u5(e,t){let i;return l;function l(...s){const f=e.length>s.length;let m;f&&s.push(n);try{m=e.apply(this,s)}catch(d){const p=d;if(f&&i)throw p;return n(p)}f||(m&&m.then&&typeof m.then=="function"?m.then(o,n):m instanceof Error?n(m):o(m))}function n(s,...f){i||(i=!0,t(s,...f))}function o(s){n(null,s)}}const Xn={basename:s5,dirname:c5,extname:f5,join:d5,sep:"/"};function s5(e,t){if(t!==void 0&&typeof t!="string")throw new TypeError('"ext" argument must be a string');Wo(e);let i=0,l=-1,n=e.length,o;if(t===void 0||t.length===0||t.length>e.length){for(;n--;)if(e.codePointAt(n)===47){if(o){i=n+1;break}}else l<0&&(o=!0,l=n+1);return l<0?"":e.slice(i,l)}if(t===e)return"";let s=-1,f=t.length-1;for(;n--;)if(e.codePointAt(n)===47){if(o){i=n+1;break}}else s<0&&(o=!0,s=n+1),f>-1&&(e.codePointAt(n)===t.codePointAt(f--)?f<0&&(l=n):(f=-1,l=s));return i===l?l=s:l<0&&(l=e.length),e.slice(i,l)}function c5(e){if(Wo(e),e.length===0)return".";let t=-1,i=e.length,l;for(;--i;)if(e.codePointAt(i)===47){if(l){t=i;break}}else l||(l=!0);return t<0?e.codePointAt(0)===47?"/":".":t===1&&e.codePointAt(0)===47?"//":e.slice(0,t)}function f5(e){Wo(e);let t=e.length,i=-1,l=0,n=-1,o=0,s;for(;t--;){const f=e.codePointAt(t);if(f===47){if(s){l=t+1;break}continue}i<0&&(s=!0,i=t+1),f===46?n<0?n=t:o!==1&&(o=1):n>-1&&(o=-1)}return n<0||i<0||o===0||o===1&&n===i-1&&n===l+1?"":e.slice(n,i)}function d5(...e){let t=-1,i;for(;++t<e.length;)Wo(e[t]),e[t]&&(i=i===void 0?e[t]:i+"/"+e[t]);return i===void 0?".":m5(i)}function m5(e){Wo(e);const t=e.codePointAt(0)===47;let i=h5(e,!t);return i.length===0&&!t&&(i="."),i.length>0&&e.codePointAt(e.length-1)===47&&(i+="/"),t?"/"+i:i}function h5(e,t){let i="",l=0,n=-1,o=0,s=-1,f,m;for(;++s<=e.length;){if(s<e.length)f=e.codePointAt(s);else{if(f===47)break;f=47}if(f===47){if(!(n===s-1||o===1))if(n!==s-1&&o===2){if(i.length<2||l!==2||i.codePointAt(i.length-1)!==46||i.codePointAt(i.length-2)!==46){if(i.length>2){if(m=i.lastIndexOf("/"),m!==i.length-1){m<0?(i="",l=0):(i=i.slice(0,m),l=i.length-1-i.lastIndexOf("/")),n=s,o=0;continue}}else if(i.length>0){i="",l=0,n=s,o=0;continue}}t&&(i=i.length>0?i+"/..":"..",l=2)}else i.length>0?i+="/"+e.slice(n+1,s):i=e.slice(n+1,s),l=s-n-1;n=s,o=0}else f===46&&o>-1?o++:o=-1}return i}function Wo(e){if(typeof e!="string")throw new TypeError("Path must be a string. Received "+JSON.stringify(e))}const p5={cwd:g5};function g5(){return"/"}function cp(e){return!!(e!==null&&typeof e=="object"&&"href"in e&&e.href&&"protocol"in e&&e.protocol&&e.auth===void 0)}function v5(e){if(typeof e=="string")e=new URL(e);else if(!cp(e)){const t=new TypeError('The "path" argument must be of type string or an instance of URL. Received `'+e+"`");throw t.code="ERR_INVALID_ARG_TYPE",t}if(e.protocol!=="file:"){const t=new TypeError("The URL must be of scheme file");throw t.code="ERR_INVALID_URL_SCHEME",t}return y5(e)}function y5(e){if(e.hostname!==""){const l=new TypeError('File URL host must be "localhost" or empty on darwin');throw l.code="ERR_INVALID_FILE_URL_HOST",l}const t=e.pathname;let i=-1;for(;++i<t.length;)if(t.codePointAt(i)===37&&t.codePointAt(i+1)===50){const l=t.codePointAt(i+2);if(l===70||l===102){const n=new TypeError("File URL path must not include encoded / characters");throw n.code="ERR_INVALID_FILE_URL_PATH",n}}return decodeURIComponent(t)}const jh=["history","path","basename","stem","extname","dirname"];class Tz{constructor(t){let i;t?cp(t)?i={path:t}:typeof t=="string"||b5(t)?i={value:t}:i=t:i={},this.cwd="cwd"in i?"":p5.cwd(),this.data={},this.history=[],this.messages=[],this.value,this.map,this.result,this.stored;let l=-1;for(;++l<jh.length;){const o=jh[l];o in i&&i[o]!==void 0&&i[o]!==null&&(this[o]=o==="history"?[...i[o]]:i[o])}let n;for(n in i)jh.includes(n)||(this[n]=i[n])}get basename(){return typeof this.path=="string"?Xn.basename(this.path):void 0}set basename(t){Nh(t,"basename"),zh(t,"basename"),this.path=Xn.join(this.dirname||"",t)}get dirname(){return typeof this.path=="string"?Xn.dirname(this.path):void 0}set dirname(t){K1(this.basename,"dirname"),this.path=Xn.join(t||"",this.basename)}get extname(){return typeof this.path=="string"?Xn.extname(this.path):void 0}set extname(t){if(zh(t,"extname"),K1(this.dirname,"extname"),t){if(t.codePointAt(0)!==46)throw new Error("`extname` must start with `.`");if(t.includes(".",1))throw new Error("`extname` cannot contain multiple dots")}this.path=Xn.join(this.dirname,this.stem+(t||""))}get path(){return this.history[this.history.length-1]}set path(t){cp(t)&&(t=v5(t)),Nh(t,"path"),this.path!==t&&this.history.push(t)}get stem(){return typeof this.path=="string"?Xn.basename(this.path,this.extname):void 0}set stem(t){Nh(t,"stem"),zh(t,"stem"),this.path=Xn.join(this.dirname||"",t+(this.extname||""))}fail(t,i,l){const n=this.message(t,i,l);throw n.fatal=!0,n}info(t,i,l){const n=this.message(t,i,l);return n.fatal=void 0,n}message(t,i,l){const n=new Ut(t,i,l);return this.path&&(n.name=this.path+":"+n.name,n.file=this.path),n.fatal=!1,this.messages.push(n),n}toString(t){return this.value===void 0?"":typeof this.value=="string"?this.value:new TextDecoder(t||void 0).decode(this.value)}}function zh(e,t){if(e&&e.includes(Xn.sep))throw new Error("`"+t+"` cannot be a path: did not expect `"+Xn.sep+"`")}function Nh(e,t){if(!e)throw new Error("`"+t+"` cannot be empty")}function K1(e,t){if(!e)throw new Error("Setting `"+t+"` requires `path` to be set too")}function b5(e){return!!(e&&typeof e=="object"&&"byteLength"in e&&"byteOffset"in e)}const x5=(function(e){const l=this.constructor.prototype,n=l[e],o=function(){return n.apply(o,arguments)};return Object.setPrototypeOf(o,l),o}),_5={}.hasOwnProperty;class Av extends x5{constructor(){super("copy"),this.Compiler=void 0,this.Parser=void 0,this.attachers=[],this.compiler=void 0,this.freezeIndex=-1,this.frozen=void 0,this.namespace={},this.parser=void 0,this.transformers=o5()}copy(){const t=new Av;let i=-1;for(;++i<this.attachers.length;){const l=this.attachers[i];t.use(...l)}return t.data(Eh(!0,{},this.namespace)),t}data(t,i){return typeof t=="string"?arguments.length===2?(Ch("data",this.frozen),this.namespace[t]=i,this):_5.call(this.namespace,t)&&this.namespace[t]||void 0:t?(Ch("data",this.frozen),this.namespace=t,this):this.namespace}freeze(){if(this.frozen)return this;const t=this;for(;++this.freezeIndex<this.attachers.length;){const[i,...l]=this.attachers[this.freezeIndex];if(l[0]===!1)continue;l[0]===!0&&(l[0]=void 0);const n=i.call(t,...l);typeof n=="function"&&this.transformers.use(n)}return this.frozen=!0,this.freezeIndex=Number.POSITIVE_INFINITY,this}parse(t){this.freeze();const i=zs(t),l=this.parser||this.Parser;return Oh("parse",l),l(String(i),i)}process(t,i){const l=this;return this.freeze(),Oh("process",this.parser||this.Parser),Th("process",this.compiler||this.Compiler),i?n(void 0,i):new Promise(n);function n(o,s){const f=zs(t),m=l.parse(f);l.run(m,f,function(p,v,b){if(p||!v||!b)return d(p);const x=v,S=l.stringify(x,b);w5(S)?b.value=S:b.result=S,d(p,b)});function d(p,v){p||!v?s(p):o?o(v):i(void 0,v)}}}processSync(t){let i=!1,l;return this.freeze(),Oh("processSync",this.parser||this.Parser),Th("processSync",this.compiler||this.Compiler),this.process(t,n),eS("processSync","process",i),l;function n(o,s){i=!0,X1(o),l=s}}run(t,i,l){W1(t),this.freeze();const n=this.transformers;return!l&&typeof i=="function"&&(l=i,i=void 0),l?o(void 0,l):new Promise(o);function o(s,f){const m=zs(i);n.run(t,m,d);function d(p,v,b){const x=v||t;p?f(p):s?s(x):l(void 0,x,b)}}}runSync(t,i){let l=!1,n;return this.run(t,i,o),eS("runSync","run",l),n;function o(s,f){X1(s),n=f,l=!0}}stringify(t,i){this.freeze();const l=zs(i),n=this.compiler||this.Compiler;return Th("stringify",n),W1(t),n(t,l)}use(t,...i){const l=this.attachers,n=this.namespace;if(Ch("use",this.frozen),t!=null)if(typeof t=="function")m(t,i);else if(typeof t=="object")Array.isArray(t)?f(t):s(t);else throw new TypeError("Expected usable value, not `"+t+"`");return this;function o(d){if(typeof d=="function")m(d,[]);else if(typeof d=="object")if(Array.isArray(d)){const[p,...v]=d;m(p,v)}else s(d);else throw new TypeError("Expected usable value, not `"+d+"`")}function s(d){if(!("plugins"in d)&&!("settings"in d))throw new Error("Expected usable value but received an empty preset, which is probably a mistake: presets typically come with `plugins` and sometimes with `settings`, but this has neither");f(d.plugins),d.settings&&(n.settings=Eh(!0,n.settings,d.settings))}function f(d){let p=-1;if(d!=null)if(Array.isArray(d))for(;++p<d.length;){const v=d[p];o(v)}else throw new TypeError("Expected a list of plugins, not `"+d+"`")}function m(d,p){let v=-1,b=-1;for(;++v<l.length;)if(l[v][0]===d){b=v;break}if(b===-1)l.push([d,...p]);else if(p.length>0){let[x,...S]=p;const w=l[b][1];sp(w)&&sp(x)&&(x=Eh(!0,w,x)),l[b]=[d,x,...S]}}}}const S5=new Av().freeze();function Oh(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `parser`")}function Th(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `compiler`")}function Ch(e,t){if(t)throw new Error("Cannot call `"+e+"` on a frozen processor.\nCreate a new processor first, by calling it: use `processor()` instead of `processor`.")}function W1(e){if(!sp(e)||typeof e.type!="string")throw new TypeError("Expected node, got `"+e+"`")}function eS(e,t,i){if(!i)throw new Error("`"+e+"` finished async. Use `"+t+"` instead")}function zs(e){return k5(e)?e:new Tz(e)}function k5(e){return!!(e&&typeof e=="object"&&"message"in e&&"messages"in e)}function w5(e){return typeof e=="string"||$5(e)}function $5(e){return!!(e&&typeof e=="object"&&"byteLength"in e&&"byteOffset"in e)}const E5="https://github.com/remarkjs/react-markdown/blob/main/changelog.md",tS=[],nS={allowDangerousHtml:!0},j5=/^(https?|ircs?|mailto|xmpp)$/i,z5=[{from:"astPlugins",id:"remove-buggy-html-in-markdown-parser"},{from:"allowDangerousHtml",id:"remove-buggy-html-in-markdown-parser"},{from:"allowNode",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"allowElement"},{from:"allowedTypes",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"allowedElements"},{from:"className",id:"remove-classname"},{from:"disallowedTypes",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"disallowedElements"},{from:"escapeHtml",id:"remove-buggy-html-in-markdown-parser"},{from:"includeElementIndex",id:"#remove-includeelementindex"},{from:"includeNodeIndex",id:"change-includenodeindex-to-includeelementindex"},{from:"linkTarget",id:"remove-linktarget"},{from:"plugins",id:"change-plugins-to-remarkplugins",to:"remarkPlugins"},{from:"rawSourcePos",id:"#remove-rawsourcepos"},{from:"renderers",id:"change-renderers-to-components",to:"components"},{from:"source",id:"change-source-to-children",to:"children"},{from:"sourcePos",id:"#remove-sourcepos"},{from:"transformImageUri",id:"#add-urltransform",to:"urlTransform"},{from:"transformLinkUri",id:"#add-urltransform",to:"urlTransform"}];function rS(e){const t=N5(e),i=O5(e);return T5(t.runSync(t.parse(i),i),e)}function N5(e){const t=e.rehypePlugins||tS,i=e.remarkPlugins||tS,l=e.remarkRehypeOptions?{...e.remarkRehypeOptions,...nS}:nS;return S5().use(cM).use(i).use(i5,l).use(t)}function O5(e){const t=e.children||"",i=new Tz;return typeof t=="string"&&(i.value=t),i}function T5(e,t){const i=t.allowedElements,l=t.allowElement,n=t.components,o=t.disallowedElements,s=t.skipHtml,f=t.unwrapDisallowed,m=t.urlTransform||C5;for(const p of z5)Object.hasOwn(t,p.from)&&(""+p.from+(p.to?"use `"+p.to+"` instead":"remove it")+E5+p.id,void 0);return Dv(e,d),VU(e,{Fragment:y.Fragment,components:n,ignoreInvalidStyle:!0,jsx:y.jsx,jsxs:y.jsxs,passKeys:!0,passNode:!0});function d(p,v,b){if(p.type==="raw"&&b&&typeof v=="number")return s?b.children.splice(v,1):b.children[v]={type:"text",value:p.value},v;if(p.type==="element"){let x;for(x in Sh)if(Object.hasOwn(Sh,x)&&Object.hasOwn(p.properties,x)){const S=p.properties[x],w=Sh[x];(w===null||w.includes(p.tagName))&&(p.properties[x]=m(String(S||""),x,p))}}if(p.type==="element"){let x=i?!i.includes(p.tagName):o?o.includes(p.tagName):!1;if(!x&&l&&typeof v=="number"&&(x=!l(p,v,b)),x&&b&&typeof v=="number")return f&&p.children?b.children.splice(v,1,...p.children):b.children.splice(v,1),v}}}function C5(e){const t=e.indexOf(":"),i=e.indexOf("?"),l=e.indexOf("#"),n=e.indexOf("/");return t===-1||n!==-1&&t>n||i!==-1&&t>i||l!==-1&&t>l||j5.test(e.slice(0,t))?e:""}function iS(e,t){const i=String(e);if(typeof t!="string")throw new TypeError("Expected character");let l=0,n=i.indexOf(t);for(;n!==-1;)l++,n=i.indexOf(t,n+t.length);return l}function D5(e){if(typeof e!="string")throw new TypeError("Expected a string");return e.replace(/[|\\{}()[\]^$+*?.]/g,"\\$&").replace(/-/g,"\\x2d")}function A5(e,t,i){const n=ef((i||{}).ignore||[]),o=R5(t);let s=-1;for(;++s<o.length;)Oz(e,"text",f);function f(d,p){let v=-1,b;for(;++v<p.length;){const x=p[v],S=b?b.children:void 0;if(n(x,S?S.indexOf(x):void 0,b))return;b=x}if(b)return m(d,p)}function m(d,p){const v=p[p.length-1],b=o[s][0],x=o[s][1];let S=0;const j=v.children.indexOf(d);let E=!1,O=[];b.lastIndex=0;let N=b.exec(d.value);for(;N;){const G=N.index,J={index:N.index,input:N.input,stack:[...p,d]};let R=x(...N,J);if(typeof R=="string"&&(R=R.length>0?{type:"text",value:R}:void 0),R===!1?b.lastIndex=G+1:(S!==G&&O.push({type:"text",value:d.value.slice(S,G)}),Array.isArray(R)?O.push(...R):R&&O.push(R),S=G+N[0].length,E=!0),!b.global)break;N=b.exec(d.value)}return E?(S<d.value.length&&O.push({type:"text",value:d.value.slice(S)}),v.children.splice(j,1,...O)):O=[d],j+O.length}}function R5(e){const t=[];if(!Array.isArray(e))throw new TypeError("Expected find and replace tuple or list of tuples");const i=!e[0]||Array.isArray(e[0])?e:[e];let l=-1;for(;++l<i.length;){const n=i[l];t.push([I5(n[0]),U5(n[1])])}return t}function I5(e){return typeof e=="string"?new RegExp(D5(e),"g"):e}function U5(e){return typeof e=="function"?e:function(){return e}}const Dh="phrasing",Ah=["autolink","link","image","label"];function L5(){return{transforms:[H5],enter:{literalAutolink:P5,literalAutolinkEmail:Rh,literalAutolinkHttp:Rh,literalAutolinkWww:Rh},exit:{literalAutolink:B5,literalAutolinkEmail:F5,literalAutolinkHttp:Z5,literalAutolinkWww:q5}}}function M5(){return{unsafe:[{character:"@",before:"[+\\-.\\w]",after:"[\\-.\\w]",inConstruct:Dh,notInConstruct:Ah},{character:".",before:"[Ww]",after:"[\\-.\\w]",inConstruct:Dh,notInConstruct:Ah},{character:":",before:"[ps]",after:"\\/",inConstruct:Dh,notInConstruct:Ah}]}}function P5(e){this.enter({type:"link",title:null,url:"",children:[]},e)}function Rh(e){this.config.enter.autolinkProtocol.call(this,e)}function Z5(e){this.config.exit.autolinkProtocol.call(this,e)}function q5(e){this.config.exit.data.call(this,e);const t=this.stack[this.stack.length-1];t.type,t.url="http://"+this.sliceSerialize(e)}function F5(e){this.config.exit.autolinkEmail.call(this,e)}function B5(e){this.exit(e)}function H5(e){A5(e,[[/(https?:\/\/|www(?=\.))([-.\w]+)([^ \t\r\n]*)/gi,G5],[new RegExp("(?<=^|\\s|\\p{P}|\\p{S})([-.\\w+]+)@([-\\w]+(?:\\.[-\\w]+)+)","gu"),V5]],{ignore:["link","linkReference"]})}function G5(e,t,i,l,n){let o="";if(!Cz(n)||(/^w/i.test(t)&&(i=t+i,t="",o="http://"),!Y5(i)))return!1;const s=J5(i+l);if(!s[0])return!1;const f={type:"link",title:null,url:o+t+s[0],children:[{type:"text",value:t+s[0]}]};return s[1]?[f,{type:"text",value:s[1]}]:f}function V5(e,t,i,l){return!Cz(l,!0)||/[-\d_]$/.test(i)?!1:{type:"link",title:null,url:"mailto:"+t+"@"+i,children:[{type:"text",value:t+"@"+i}]}}function Y5(e){const t=e.split(".");return!(t.length<2||t[t.length-1]&&(/_/.test(t[t.length-1])||!/[a-zA-Z\d]/.test(t[t.length-1]))||t[t.length-2]&&(/_/.test(t[t.length-2])||!/[a-zA-Z\d]/.test(t[t.length-2])))}function J5(e){const t=/[!"&'),.:;<>?\]}]+$/.exec(e);if(!t)return[e,void 0];e=e.slice(0,t.index);let i=t[0],l=i.indexOf(")");const n=iS(e,"(");let o=iS(e,")");for(;l!==-1&&n>o;)e+=i.slice(0,l+1),i=i.slice(l+1),l=i.indexOf(")"),o++;return[e,i]}function Cz(e,t){const i=e.input.charCodeAt(e.index-1);return(e.index===0||Zi(i)||Qc(i))&&(!t||i!==47)}Dz.peek=iP;function X5(){this.buffer()}function Q5(e){this.enter({type:"footnoteReference",identifier:"",label:""},e)}function K5(){this.buffer()}function W5(e){this.enter({type:"footnoteDefinition",identifier:"",label:"",children:[]},e)}function eP(e){const t=this.resume(),i=this.stack[this.stack.length-1];i.type,i.identifier=Zn(this.sliceSerialize(e)).toLowerCase(),i.label=t}function tP(e){this.exit(e)}function nP(e){const t=this.resume(),i=this.stack[this.stack.length-1];i.type,i.identifier=Zn(this.sliceSerialize(e)).toLowerCase(),i.label=t}function rP(e){this.exit(e)}function iP(){return"["}function Dz(e,t,i,l){const n=i.createTracker(l);let o=n.move("[^");const s=i.enter("footnoteReference"),f=i.enter("reference");return o+=n.move(i.safe(i.associationId(e),{after:"]",before:o})),f(),s(),o+=n.move("]"),o}function aP(){return{enter:{gfmFootnoteCallString:X5,gfmFootnoteCall:Q5,gfmFootnoteDefinitionLabelString:K5,gfmFootnoteDefinition:W5},exit:{gfmFootnoteCallString:eP,gfmFootnoteCall:tP,gfmFootnoteDefinitionLabelString:nP,gfmFootnoteDefinition:rP}}}function lP(e){let t=!1;return e&&e.firstLineBlank&&(t=!0),{handlers:{footnoteDefinition:i,footnoteReference:Dz},unsafe:[{character:"[",inConstruct:["label","phrasing","reference"]}]};function i(l,n,o,s){const f=o.createTracker(s);let m=f.move("[^");const d=o.enter("footnoteDefinition"),p=o.enter("label");return m+=f.move(o.safe(o.associationId(l),{before:m,after:"]"})),p(),m+=f.move("]:"),l.children&&l.children.length>0&&(f.shift(4),m+=f.move((t?`
|
|
75
|
+
`:" ")+o.indentLines(o.containerFlow(l,f.current()),t?Az:oP))),d(),m}}function oP(e,t,i){return t===0?e:Az(e,t,i)}function Az(e,t,i){return(i?"":" ")+e}const uP=["autolink","destinationLiteral","destinationRaw","reference","titleQuote","titleApostrophe"];Rz.peek=mP;function sP(){return{canContainEols:["delete"],enter:{strikethrough:fP},exit:{strikethrough:dP}}}function cP(){return{unsafe:[{character:"~",inConstruct:"phrasing",notInConstruct:uP}],handlers:{delete:Rz}}}function fP(e){this.enter({type:"delete",children:[]},e)}function dP(e){this.exit(e)}function Rz(e,t,i,l){const n=i.createTracker(l),o=i.enter("strikethrough");let s=n.move("~~");return s+=i.containerPhrasing(e,{...n.current(),before:s,after:"~"}),s+=n.move("~~"),o(),s}function mP(){return"~"}function hP(e){return e.length}function pP(e,t){const i=t||{},l=(i.align||[]).concat(),n=i.stringLength||hP,o=[],s=[],f=[],m=[];let d=0,p=-1;for(;++p<e.length;){const w=[],j=[];let E=-1;for(e[p].length>d&&(d=e[p].length);++E<e[p].length;){const O=gP(e[p][E]);if(i.alignDelimiters!==!1){const N=n(O);j[E]=N,(m[E]===void 0||N>m[E])&&(m[E]=N)}w.push(O)}s[p]=w,f[p]=j}let v=-1;if(typeof l=="object"&&"length"in l)for(;++v<d;)o[v]=aS(l[v]);else{const w=aS(l);for(;++v<d;)o[v]=w}v=-1;const b=[],x=[];for(;++v<d;){const w=o[v];let j="",E="";w===99?(j=":",E=":"):w===108?j=":":w===114&&(E=":");let O=i.alignDelimiters===!1?1:Math.max(1,m[v]-j.length-E.length);const N=j+"-".repeat(O)+E;i.alignDelimiters!==!1&&(O=j.length+O+E.length,O>m[v]&&(m[v]=O),x[v]=O),b[v]=N}s.splice(1,0,b),f.splice(1,0,x),p=-1;const S=[];for(;++p<s.length;){const w=s[p],j=f[p];v=-1;const E=[];for(;++v<d;){const O=w[v]||"";let N="",G="";if(i.alignDelimiters!==!1){const J=m[v]-(j[v]||0),R=o[v];R===114?N=" ".repeat(J):R===99?J%2?(N=" ".repeat(J/2+.5),G=" ".repeat(J/2-.5)):(N=" ".repeat(J/2),G=N):G=" ".repeat(J)}i.delimiterStart!==!1&&!v&&E.push("|"),i.padding!==!1&&!(i.alignDelimiters===!1&&O==="")&&(i.delimiterStart!==!1||v)&&E.push(" "),i.alignDelimiters!==!1&&E.push(N),E.push(O),i.alignDelimiters!==!1&&E.push(G),i.padding!==!1&&E.push(" "),(i.delimiterEnd!==!1||v!==d-1)&&E.push("|")}S.push(i.delimiterEnd===!1?E.join("").replace(/ +$/,""):E.join(""))}return S.join(`
|
|
76
|
+
`)}function gP(e){return e==null?"":String(e)}function aS(e){const t=typeof e=="string"?e.codePointAt(0):0;return t===67||t===99?99:t===76||t===108?108:t===82||t===114?114:0}function vP(e,t,i,l){const n=i.enter("blockquote"),o=i.createTracker(l);o.move("> "),o.shift(2);const s=i.indentLines(i.containerFlow(e,o.current()),yP);return n(),s}function yP(e,t,i){return">"+(i?"":" ")+e}function bP(e,t){return lS(e,t.inConstruct,!0)&&!lS(e,t.notInConstruct,!1)}function lS(e,t,i){if(typeof t=="string"&&(t=[t]),!t||t.length===0)return i;let l=-1;for(;++l<t.length;)if(e.includes(t[l]))return!0;return!1}function oS(e,t,i,l){let n=-1;for(;++n<i.unsafe.length;)if(i.unsafe[n].character===`
|
|
77
|
+
`&&bP(i.stack,i.unsafe[n]))return/[ \t]/.test(l.before)?"":" ";return`\\
|
|
78
|
+
`}function xP(e,t){const i=String(e);let l=i.indexOf(t),n=l,o=0,s=0;if(typeof t!="string")throw new TypeError("Expected substring");for(;l!==-1;)l===n?++o>s&&(s=o):o=1,n=l+t.length,l=i.indexOf(t,n);return s}function _P(e,t){return!!(t.options.fences===!1&&e.value&&!e.lang&&/[^ \r\n]/.test(e.value)&&!/^[\t ]*(?:[\r\n]|$)|(?:^|[\r\n])[\t ]*$/.test(e.value))}function SP(e){const t=e.options.fence||"`";if(t!=="`"&&t!=="~")throw new Error("Cannot serialize code with `"+t+"` for `options.fence`, expected `` ` `` or `~`");return t}function kP(e,t,i,l){const n=SP(i),o=e.value||"",s=n==="`"?"GraveAccent":"Tilde";if(_P(e,i)){const v=i.enter("codeIndented"),b=i.indentLines(o,wP);return v(),b}const f=i.createTracker(l),m=n.repeat(Math.max(xP(o,n)+1,3)),d=i.enter("codeFenced");let p=f.move(m);if(e.lang){const v=i.enter(`codeFencedLang${s}`);p+=f.move(i.safe(e.lang,{before:p,after:" ",encode:["`"],...f.current()})),v()}if(e.lang&&e.meta){const v=i.enter(`codeFencedMeta${s}`);p+=f.move(" "),p+=f.move(i.safe(e.meta,{before:p,after:`
|
|
79
|
+
`,encode:["`"],...f.current()})),v()}return p+=f.move(`
|
|
80
|
+
`),o&&(p+=f.move(o+`
|
|
81
|
+
`)),p+=f.move(m),d(),p}function wP(e,t,i){return(i?"":" ")+e}function Rv(e){const t=e.options.quote||'"';if(t!=='"'&&t!=="'")throw new Error("Cannot serialize title with `"+t+"` for `options.quote`, expected `\"`, or `'`");return t}function $P(e,t,i,l){const n=Rv(i),o=n==='"'?"Quote":"Apostrophe",s=i.enter("definition");let f=i.enter("label");const m=i.createTracker(l);let d=m.move("[");return d+=m.move(i.safe(i.associationId(e),{before:d,after:"]",...m.current()})),d+=m.move("]: "),f(),!e.url||/[\0- \u007F]/.test(e.url)?(f=i.enter("destinationLiteral"),d+=m.move("<"),d+=m.move(i.safe(e.url,{before:d,after:">",...m.current()})),d+=m.move(">")):(f=i.enter("destinationRaw"),d+=m.move(i.safe(e.url,{before:d,after:e.title?" ":`
|
|
82
|
+
`,...m.current()}))),f(),e.title&&(f=i.enter(`title${o}`),d+=m.move(" "+n),d+=m.move(i.safe(e.title,{before:d,after:n,...m.current()})),d+=m.move(n),f()),s(),d}function EP(e){const t=e.options.emphasis||"*";if(t!=="*"&&t!=="_")throw new Error("Cannot serialize emphasis with `"+t+"` for `options.emphasis`, expected `*`, or `_`");return t}function xo(e){return"&#x"+e.toString(16).toUpperCase()+";"}function Ys(e,t,i){const l=Xa(e),n=Xa(t);return l===void 0?n===void 0?i==="_"?{inside:!0,outside:!0}:{inside:!1,outside:!1}:n===1?{inside:!0,outside:!0}:{inside:!1,outside:!0}:l===1?n===void 0?{inside:!1,outside:!1}:n===1?{inside:!0,outside:!0}:{inside:!1,outside:!1}:n===void 0?{inside:!1,outside:!1}:n===1?{inside:!0,outside:!1}:{inside:!1,outside:!1}}Iz.peek=jP;function Iz(e,t,i,l){const n=EP(i),o=i.enter("emphasis"),s=i.createTracker(l),f=s.move(n);let m=s.move(i.containerPhrasing(e,{after:n,before:f,...s.current()}));const d=m.charCodeAt(0),p=Ys(l.before.charCodeAt(l.before.length-1),d,n);p.inside&&(m=xo(d)+m.slice(1));const v=m.charCodeAt(m.length-1),b=Ys(l.after.charCodeAt(0),v,n);b.inside&&(m=m.slice(0,-1)+xo(v));const x=s.move(n);return o(),i.attentionEncodeSurroundingInfo={after:b.outside,before:p.outside},f+m+x}function jP(e,t,i){return i.options.emphasis||"*"}function zP(e,t){let i=!1;return Dv(e,function(l){if("value"in l&&/\r?\n|\r/.test(l.value)||l.type==="break")return i=!0,op}),!!((!e.depth||e.depth<3)&&Ev(e)&&(t.options.setext||i))}function NP(e,t,i,l){const n=Math.max(Math.min(6,e.depth||1),1),o=i.createTracker(l);if(zP(e,i)){const p=i.enter("headingSetext"),v=i.enter("phrasing"),b=i.containerPhrasing(e,{...o.current(),before:`
|
|
83
|
+
`,after:`
|
|
84
|
+
`});return v(),p(),b+`
|
|
85
|
+
`+(n===1?"=":"-").repeat(b.length-(Math.max(b.lastIndexOf("\r"),b.lastIndexOf(`
|
|
86
|
+
`))+1))}const s="#".repeat(n),f=i.enter("headingAtx"),m=i.enter("phrasing");o.move(s+" ");let d=i.containerPhrasing(e,{before:"# ",after:`
|
|
87
|
+
`,...o.current()});return/^[\t ]/.test(d)&&(d=xo(d.charCodeAt(0))+d.slice(1)),d=d?s+" "+d:s,i.options.closeAtx&&(d+=" "+s),m(),f(),d}Uz.peek=OP;function Uz(e){return e.value||""}function OP(){return"<"}Lz.peek=TP;function Lz(e,t,i,l){const n=Rv(i),o=n==='"'?"Quote":"Apostrophe",s=i.enter("image");let f=i.enter("label");const m=i.createTracker(l);let d=m.move("![");return d+=m.move(i.safe(e.alt,{before:d,after:"]",...m.current()})),d+=m.move("]("),f(),!e.url&&e.title||/[\0- \u007F]/.test(e.url)?(f=i.enter("destinationLiteral"),d+=m.move("<"),d+=m.move(i.safe(e.url,{before:d,after:">",...m.current()})),d+=m.move(">")):(f=i.enter("destinationRaw"),d+=m.move(i.safe(e.url,{before:d,after:e.title?" ":")",...m.current()}))),f(),e.title&&(f=i.enter(`title${o}`),d+=m.move(" "+n),d+=m.move(i.safe(e.title,{before:d,after:n,...m.current()})),d+=m.move(n),f()),d+=m.move(")"),s(),d}function TP(){return"!"}Mz.peek=CP;function Mz(e,t,i,l){const n=e.referenceType,o=i.enter("imageReference");let s=i.enter("label");const f=i.createTracker(l);let m=f.move("![");const d=i.safe(e.alt,{before:m,after:"]",...f.current()});m+=f.move(d+"]["),s();const p=i.stack;i.stack=[],s=i.enter("reference");const v=i.safe(i.associationId(e),{before:m,after:"]",...f.current()});return s(),i.stack=p,o(),n==="full"||!d||d!==v?m+=f.move(v+"]"):n==="shortcut"?m=m.slice(0,-1):m+=f.move("]"),m}function CP(){return"!"}Pz.peek=DP;function Pz(e,t,i){let l=e.value||"",n="`",o=-1;for(;new RegExp("(^|[^`])"+n+"([^`]|$)").test(l);)n+="`";for(/[^ \r\n]/.test(l)&&(/^[ \r\n]/.test(l)&&/[ \r\n]$/.test(l)||/^`|`$/.test(l))&&(l=" "+l+" ");++o<i.unsafe.length;){const s=i.unsafe[o],f=i.compilePattern(s);let m;if(s.atBreak)for(;m=f.exec(l);){let d=m.index;l.charCodeAt(d)===10&&l.charCodeAt(d-1)===13&&d--,l=l.slice(0,d)+" "+l.slice(m.index+1)}}return n+l+n}function DP(){return"`"}function Zz(e,t){const i=Ev(e);return!!(!t.options.resourceLink&&e.url&&!e.title&&e.children&&e.children.length===1&&e.children[0].type==="text"&&(i===e.url||"mailto:"+i===e.url)&&/^[a-z][a-z+.-]+:/i.test(e.url)&&!/[\0- <>\u007F]/.test(e.url))}qz.peek=AP;function qz(e,t,i,l){const n=Rv(i),o=n==='"'?"Quote":"Apostrophe",s=i.createTracker(l);let f,m;if(Zz(e,i)){const p=i.stack;i.stack=[],f=i.enter("autolink");let v=s.move("<");return v+=s.move(i.containerPhrasing(e,{before:v,after:">",...s.current()})),v+=s.move(">"),f(),i.stack=p,v}f=i.enter("link"),m=i.enter("label");let d=s.move("[");return d+=s.move(i.containerPhrasing(e,{before:d,after:"](",...s.current()})),d+=s.move("]("),m(),!e.url&&e.title||/[\0- \u007F]/.test(e.url)?(m=i.enter("destinationLiteral"),d+=s.move("<"),d+=s.move(i.safe(e.url,{before:d,after:">",...s.current()})),d+=s.move(">")):(m=i.enter("destinationRaw"),d+=s.move(i.safe(e.url,{before:d,after:e.title?" ":")",...s.current()}))),m(),e.title&&(m=i.enter(`title${o}`),d+=s.move(" "+n),d+=s.move(i.safe(e.title,{before:d,after:n,...s.current()})),d+=s.move(n),m()),d+=s.move(")"),f(),d}function AP(e,t,i){return Zz(e,i)?"<":"["}Fz.peek=RP;function Fz(e,t,i,l){const n=e.referenceType,o=i.enter("linkReference");let s=i.enter("label");const f=i.createTracker(l);let m=f.move("[");const d=i.containerPhrasing(e,{before:m,after:"]",...f.current()});m+=f.move(d+"]["),s();const p=i.stack;i.stack=[],s=i.enter("reference");const v=i.safe(i.associationId(e),{before:m,after:"]",...f.current()});return s(),i.stack=p,o(),n==="full"||!d||d!==v?m+=f.move(v+"]"):n==="shortcut"?m=m.slice(0,-1):m+=f.move("]"),m}function RP(){return"["}function Iv(e){const t=e.options.bullet||"*";if(t!=="*"&&t!=="+"&&t!=="-")throw new Error("Cannot serialize items with `"+t+"` for `options.bullet`, expected `*`, `+`, or `-`");return t}function IP(e){const t=Iv(e),i=e.options.bulletOther;if(!i)return t==="*"?"-":"*";if(i!=="*"&&i!=="+"&&i!=="-")throw new Error("Cannot serialize items with `"+i+"` for `options.bulletOther`, expected `*`, `+`, or `-`");if(i===t)throw new Error("Expected `bullet` (`"+t+"`) and `bulletOther` (`"+i+"`) to be different");return i}function UP(e){const t=e.options.bulletOrdered||".";if(t!=="."&&t!==")")throw new Error("Cannot serialize items with `"+t+"` for `options.bulletOrdered`, expected `.` or `)`");return t}function Bz(e){const t=e.options.rule||"*";if(t!=="*"&&t!=="-"&&t!=="_")throw new Error("Cannot serialize rules with `"+t+"` for `options.rule`, expected `*`, `-`, or `_`");return t}function LP(e,t,i,l){const n=i.enter("list"),o=i.bulletCurrent;let s=e.ordered?UP(i):Iv(i);const f=e.ordered?s==="."?")":".":IP(i);let m=t&&i.bulletLastUsed?s===i.bulletLastUsed:!1;if(!e.ordered){const p=e.children?e.children[0]:void 0;if((s==="*"||s==="-")&&p&&(!p.children||!p.children[0])&&i.stack[i.stack.length-1]==="list"&&i.stack[i.stack.length-2]==="listItem"&&i.stack[i.stack.length-3]==="list"&&i.stack[i.stack.length-4]==="listItem"&&i.indexStack[i.indexStack.length-1]===0&&i.indexStack[i.indexStack.length-2]===0&&i.indexStack[i.indexStack.length-3]===0&&(m=!0),Bz(i)===s&&p){let v=-1;for(;++v<e.children.length;){const b=e.children[v];if(b&&b.type==="listItem"&&b.children&&b.children[0]&&b.children[0].type==="thematicBreak"){m=!0;break}}}}m&&(s=f),i.bulletCurrent=s;const d=i.containerFlow(e,l);return i.bulletLastUsed=s,i.bulletCurrent=o,n(),d}function MP(e){const t=e.options.listItemIndent||"one";if(t!=="tab"&&t!=="one"&&t!=="mixed")throw new Error("Cannot serialize items with `"+t+"` for `options.listItemIndent`, expected `tab`, `one`, or `mixed`");return t}function PP(e,t,i,l){const n=MP(i);let o=i.bulletCurrent||Iv(i);t&&t.type==="list"&&t.ordered&&(o=(typeof t.start=="number"&&t.start>-1?t.start:1)+(i.options.incrementListMarker===!1?0:t.children.indexOf(e))+o);let s=o.length+1;(n==="tab"||n==="mixed"&&(t&&t.type==="list"&&t.spread||e.spread))&&(s=Math.ceil(s/4)*4);const f=i.createTracker(l);f.move(o+" ".repeat(s-o.length)),f.shift(s);const m=i.enter("listItem"),d=i.indentLines(i.containerFlow(e,f.current()),p);return m(),d;function p(v,b,x){return b?(x?"":" ".repeat(s))+v:(x?o:o+" ".repeat(s-o.length))+v}}function ZP(e,t,i,l){const n=i.enter("paragraph"),o=i.enter("phrasing"),s=i.containerPhrasing(e,l);return o(),n(),s}const qP=ef(["break","delete","emphasis","footnote","footnoteReference","image","imageReference","inlineCode","inlineMath","link","linkReference","mdxJsxTextElement","mdxTextExpression","strong","text","textDirective"]);function FP(e,t,i,l){return(e.children.some(function(s){return qP(s)})?i.containerPhrasing:i.containerFlow).call(i,e,l)}function BP(e){const t=e.options.strong||"*";if(t!=="*"&&t!=="_")throw new Error("Cannot serialize strong with `"+t+"` for `options.strong`, expected `*`, or `_`");return t}Hz.peek=HP;function Hz(e,t,i,l){const n=BP(i),o=i.enter("strong"),s=i.createTracker(l),f=s.move(n+n);let m=s.move(i.containerPhrasing(e,{after:n,before:f,...s.current()}));const d=m.charCodeAt(0),p=Ys(l.before.charCodeAt(l.before.length-1),d,n);p.inside&&(m=xo(d)+m.slice(1));const v=m.charCodeAt(m.length-1),b=Ys(l.after.charCodeAt(0),v,n);b.inside&&(m=m.slice(0,-1)+xo(v));const x=s.move(n+n);return o(),i.attentionEncodeSurroundingInfo={after:b.outside,before:p.outside},f+m+x}function HP(e,t,i){return i.options.strong||"*"}function GP(e,t,i,l){return i.safe(e.value,l)}function VP(e){const t=e.options.ruleRepetition||3;if(t<3)throw new Error("Cannot serialize rules with repetition `"+t+"` for `options.ruleRepetition`, expected `3` or more");return t}function YP(e,t,i){const l=(Bz(i)+(i.options.ruleSpaces?" ":"")).repeat(VP(i));return i.options.ruleSpaces?l.slice(0,-1):l}const Gz={blockquote:vP,break:oS,code:kP,definition:$P,emphasis:Iz,hardBreak:oS,heading:NP,html:Uz,image:Lz,imageReference:Mz,inlineCode:Pz,link:qz,linkReference:Fz,list:LP,listItem:PP,paragraph:ZP,root:FP,strong:Hz,text:GP,thematicBreak:YP};function JP(){return{enter:{table:XP,tableData:uS,tableHeader:uS,tableRow:KP},exit:{codeText:WP,table:QP,tableData:Ih,tableHeader:Ih,tableRow:Ih}}}function XP(e){const t=e._align;this.enter({type:"table",align:t.map(function(i){return i==="none"?null:i}),children:[]},e),this.data.inTable=!0}function QP(e){this.exit(e),this.data.inTable=void 0}function KP(e){this.enter({type:"tableRow",children:[]},e)}function Ih(e){this.exit(e)}function uS(e){this.enter({type:"tableCell",children:[]},e)}function WP(e){let t=this.resume();this.data.inTable&&(t=t.replace(/\\([\\|])/g,e9));const i=this.stack[this.stack.length-1];i.type,i.value=t,this.exit(e)}function e9(e,t){return t==="|"?t:e}function t9(e){const t=e||{},i=t.tableCellPadding,l=t.tablePipeAlign,n=t.stringLength,o=i?" ":"|";return{unsafe:[{character:"\r",inConstruct:"tableCell"},{character:`
|
|
88
|
+
`,inConstruct:"tableCell"},{atBreak:!0,character:"|",after:"[ :-]"},{character:"|",inConstruct:"tableCell"},{atBreak:!0,character:":",after:"-"},{atBreak:!0,character:"-",after:"[:|-]"}],handlers:{inlineCode:b,table:s,tableCell:m,tableRow:f}};function s(x,S,w,j){return d(p(x,w,j),x.align)}function f(x,S,w,j){const E=v(x,w,j),O=d([E]);return O.slice(0,O.indexOf(`
|
|
89
|
+
`))}function m(x,S,w,j){const E=w.enter("tableCell"),O=w.enter("phrasing"),N=w.containerPhrasing(x,{...j,before:o,after:o});return O(),E(),N}function d(x,S){return pP(x,{align:S,alignDelimiters:l,padding:i,stringLength:n})}function p(x,S,w){const j=x.children;let E=-1;const O=[],N=S.enter("table");for(;++E<j.length;)O[E]=v(j[E],S,w);return N(),O}function v(x,S,w){const j=x.children;let E=-1;const O=[],N=S.enter("tableRow");for(;++E<j.length;)O[E]=m(j[E],x,S,w);return N(),O}function b(x,S,w){let j=Gz.inlineCode(x,S,w);return w.stack.includes("tableCell")&&(j=j.replace(/\|/g,"\\$&")),j}}function n9(){return{exit:{taskListCheckValueChecked:sS,taskListCheckValueUnchecked:sS,paragraph:i9}}}function r9(){return{unsafe:[{atBreak:!0,character:"-",after:"[:|-]"}],handlers:{listItem:a9}}}function sS(e){const t=this.stack[this.stack.length-2];t.type,t.checked=e.type==="taskListCheckValueChecked"}function i9(e){const t=this.stack[this.stack.length-2];if(t&&t.type==="listItem"&&typeof t.checked=="boolean"){const i=this.stack[this.stack.length-1];i.type;const l=i.children[0];if(l&&l.type==="text"){const n=t.children;let o=-1,s;for(;++o<n.length;){const f=n[o];if(f.type==="paragraph"){s=f;break}}s===i&&(l.value=l.value.slice(1),l.value.length===0?i.children.shift():i.position&&l.position&&typeof l.position.start.offset=="number"&&(l.position.start.column++,l.position.start.offset++,i.position.start=Object.assign({},l.position.start)))}}this.exit(e)}function a9(e,t,i,l){const n=e.children[0],o=typeof e.checked=="boolean"&&n&&n.type==="paragraph",s="["+(e.checked?"x":" ")+"] ",f=i.createTracker(l);o&&f.move(s);let m=Gz.listItem(e,t,i,{...l,...f.current()});return o&&(m=m.replace(/^(?:[*+-]|\d+\.)([\r\n]| {1,3})/,d)),m;function d(p){return p+s}}function l9(){return[L5(),aP(),sP(),JP(),n9()]}function o9(e){return{extensions:[M5(),lP(e),cP(),t9(e),r9()]}}const u9={tokenize:h9,partial:!0},Vz={tokenize:p9,partial:!0},Yz={tokenize:g9,partial:!0},Jz={tokenize:v9,partial:!0},s9={tokenize:y9,partial:!0},Xz={name:"wwwAutolink",tokenize:d9,previous:Kz},Qz={name:"protocolAutolink",tokenize:m9,previous:Wz},Tr={name:"emailAutolink",tokenize:f9,previous:eN},nr={};function c9(){return{text:nr}}let Oi=48;for(;Oi<123;)nr[Oi]=Tr,Oi++,Oi===58?Oi=65:Oi===91&&(Oi=97);nr[43]=Tr;nr[45]=Tr;nr[46]=Tr;nr[95]=Tr;nr[72]=[Tr,Qz];nr[104]=[Tr,Qz];nr[87]=[Tr,Xz];nr[119]=[Tr,Xz];function f9(e,t,i){const l=this;let n,o;return s;function s(v){return!fp(v)||!eN.call(l,l.previous)||Uv(l.events)?i(v):(e.enter("literalAutolink"),e.enter("literalAutolinkEmail"),f(v))}function f(v){return fp(v)?(e.consume(v),f):v===64?(e.consume(v),m):i(v)}function m(v){return v===46?e.check(s9,p,d)(v):v===45||v===95||Rt(v)?(o=!0,e.consume(v),m):p(v)}function d(v){return e.consume(v),n=!0,m}function p(v){return o&&n&&Ft(l.previous)?(e.exit("literalAutolinkEmail"),e.exit("literalAutolink"),t(v)):i(v)}}function d9(e,t,i){const l=this;return n;function n(s){return s!==87&&s!==119||!Kz.call(l,l.previous)||Uv(l.events)?i(s):(e.enter("literalAutolink"),e.enter("literalAutolinkWww"),e.check(u9,e.attempt(Vz,e.attempt(Yz,o),i),i)(s))}function o(s){return e.exit("literalAutolinkWww"),e.exit("literalAutolink"),t(s)}}function m9(e,t,i){const l=this;let n="",o=!1;return s;function s(v){return(v===72||v===104)&&Wz.call(l,l.previous)&&!Uv(l.events)?(e.enter("literalAutolink"),e.enter("literalAutolinkHttp"),n+=String.fromCodePoint(v),e.consume(v),f):i(v)}function f(v){if(Ft(v)&&n.length<5)return n+=String.fromCodePoint(v),e.consume(v),f;if(v===58){const b=n.toLowerCase();if(b==="http"||b==="https")return e.consume(v),m}return i(v)}function m(v){return v===47?(e.consume(v),o?d:(o=!0,m)):i(v)}function d(v){return v===null||Hs(v)||We(v)||Zi(v)||Qc(v)?i(v):e.attempt(Vz,e.attempt(Yz,p),i)(v)}function p(v){return e.exit("literalAutolinkHttp"),e.exit("literalAutolink"),t(v)}}function h9(e,t,i){let l=0;return n;function n(s){return(s===87||s===119)&&l<3?(l++,e.consume(s),n):s===46&&l===3?(e.consume(s),o):i(s)}function o(s){return s===null?i(s):t(s)}}function p9(e,t,i){let l,n,o;return s;function s(d){return d===46||d===95?e.check(Jz,m,f)(d):d===null||We(d)||Zi(d)||d!==45&&Qc(d)?m(d):(o=!0,e.consume(d),s)}function f(d){return d===95?l=!0:(n=l,l=void 0),e.consume(d),s}function m(d){return n||l||!o?i(d):t(d)}}function g9(e,t){let i=0,l=0;return n;function n(s){return s===40?(i++,e.consume(s),n):s===41&&l<i?o(s):s===33||s===34||s===38||s===39||s===41||s===42||s===44||s===46||s===58||s===59||s===60||s===63||s===93||s===95||s===126?e.check(Jz,t,o)(s):s===null||We(s)||Zi(s)?t(s):(e.consume(s),n)}function o(s){return s===41&&l++,e.consume(s),n}}function v9(e,t,i){return l;function l(f){return f===33||f===34||f===39||f===41||f===42||f===44||f===46||f===58||f===59||f===63||f===95||f===126?(e.consume(f),l):f===38?(e.consume(f),o):f===93?(e.consume(f),n):f===60||f===null||We(f)||Zi(f)?t(f):i(f)}function n(f){return f===null||f===40||f===91||We(f)||Zi(f)?t(f):l(f)}function o(f){return Ft(f)?s(f):i(f)}function s(f){return f===59?(e.consume(f),l):Ft(f)?(e.consume(f),s):i(f)}}function y9(e,t,i){return l;function l(o){return e.consume(o),n}function n(o){return Rt(o)?i(o):t(o)}}function Kz(e){return e===null||e===40||e===42||e===95||e===91||e===93||e===126||We(e)}function Wz(e){return!Ft(e)}function eN(e){return!(e===47||fp(e))}function fp(e){return e===43||e===45||e===46||e===95||Rt(e)}function Uv(e){let t=e.length,i=!1;for(;t--;){const l=e[t][1];if((l.type==="labelLink"||l.type==="labelImage")&&!l._balanced){i=!0;break}if(l._gfmAutolinkLiteralWalkedInto){i=!1;break}}return e.length>0&&!i&&(e[e.length-1][1]._gfmAutolinkLiteralWalkedInto=!0),i}const b9={tokenize:j9,partial:!0};function x9(){return{document:{91:{name:"gfmFootnoteDefinition",tokenize:w9,continuation:{tokenize:$9},exit:E9}},text:{91:{name:"gfmFootnoteCall",tokenize:k9},93:{name:"gfmPotentialFootnoteCall",add:"after",tokenize:_9,resolveTo:S9}}}}function _9(e,t,i){const l=this;let n=l.events.length;const o=l.parser.gfmFootnotes||(l.parser.gfmFootnotes=[]);let s;for(;n--;){const m=l.events[n][1];if(m.type==="labelImage"){s=m;break}if(m.type==="gfmFootnoteCall"||m.type==="labelLink"||m.type==="label"||m.type==="image"||m.type==="link")break}return f;function f(m){if(!s||!s._balanced)return i(m);const d=Zn(l.sliceSerialize({start:s.end,end:l.now()}));return d.codePointAt(0)!==94||!o.includes(d.slice(1))?i(m):(e.enter("gfmFootnoteCallLabelMarker"),e.consume(m),e.exit("gfmFootnoteCallLabelMarker"),t(m))}}function S9(e,t){let i=e.length;for(;i--;)if(e[i][1].type==="labelImage"&&e[i][0]==="enter"){e[i][1];break}e[i+1][1].type="data",e[i+3][1].type="gfmFootnoteCallLabelMarker";const l={type:"gfmFootnoteCall",start:Object.assign({},e[i+3][1].start),end:Object.assign({},e[e.length-1][1].end)},n={type:"gfmFootnoteCallMarker",start:Object.assign({},e[i+3][1].end),end:Object.assign({},e[i+3][1].end)};n.end.column++,n.end.offset++,n.end._bufferIndex++;const o={type:"gfmFootnoteCallString",start:Object.assign({},n.end),end:Object.assign({},e[e.length-1][1].start)},s={type:"chunkString",contentType:"string",start:Object.assign({},o.start),end:Object.assign({},o.end)},f=[e[i+1],e[i+2],["enter",l,t],e[i+3],e[i+4],["enter",n,t],["exit",n,t],["enter",o,t],["enter",s,t],["exit",s,t],["exit",o,t],e[e.length-2],e[e.length-1],["exit",l,t]];return e.splice(i,e.length-i+1,...f),e}function k9(e,t,i){const l=this,n=l.parser.gfmFootnotes||(l.parser.gfmFootnotes=[]);let o=0,s;return f;function f(v){return e.enter("gfmFootnoteCall"),e.enter("gfmFootnoteCallLabelMarker"),e.consume(v),e.exit("gfmFootnoteCallLabelMarker"),m}function m(v){return v!==94?i(v):(e.enter("gfmFootnoteCallMarker"),e.consume(v),e.exit("gfmFootnoteCallMarker"),e.enter("gfmFootnoteCallString"),e.enter("chunkString").contentType="string",d)}function d(v){if(o>999||v===93&&!s||v===null||v===91||We(v))return i(v);if(v===93){e.exit("chunkString");const b=e.exit("gfmFootnoteCallString");return n.includes(Zn(l.sliceSerialize(b)))?(e.enter("gfmFootnoteCallLabelMarker"),e.consume(v),e.exit("gfmFootnoteCallLabelMarker"),e.exit("gfmFootnoteCall"),t):i(v)}return We(v)||(s=!0),o++,e.consume(v),v===92?p:d}function p(v){return v===91||v===92||v===93?(e.consume(v),o++,d):d(v)}}function w9(e,t,i){const l=this,n=l.parser.gfmFootnotes||(l.parser.gfmFootnotes=[]);let o,s=0,f;return m;function m(S){return e.enter("gfmFootnoteDefinition")._container=!0,e.enter("gfmFootnoteDefinitionLabel"),e.enter("gfmFootnoteDefinitionLabelMarker"),e.consume(S),e.exit("gfmFootnoteDefinitionLabelMarker"),d}function d(S){return S===94?(e.enter("gfmFootnoteDefinitionMarker"),e.consume(S),e.exit("gfmFootnoteDefinitionMarker"),e.enter("gfmFootnoteDefinitionLabelString"),e.enter("chunkString").contentType="string",p):i(S)}function p(S){if(s>999||S===93&&!f||S===null||S===91||We(S))return i(S);if(S===93){e.exit("chunkString");const w=e.exit("gfmFootnoteDefinitionLabelString");return o=Zn(l.sliceSerialize(w)),e.enter("gfmFootnoteDefinitionLabelMarker"),e.consume(S),e.exit("gfmFootnoteDefinitionLabelMarker"),e.exit("gfmFootnoteDefinitionLabel"),b}return We(S)||(f=!0),s++,e.consume(S),S===92?v:p}function v(S){return S===91||S===92||S===93?(e.consume(S),s++,p):p(S)}function b(S){return S===58?(e.enter("definitionMarker"),e.consume(S),e.exit("definitionMarker"),n.includes(o)||n.push(o),Pe(e,x,"gfmFootnoteDefinitionWhitespace")):i(S)}function x(S){return t(S)}}function $9(e,t,i){return e.check(Ko,t,e.attempt(b9,t,i))}function E9(e){e.exit("gfmFootnoteDefinition")}function j9(e,t,i){const l=this;return Pe(e,n,"gfmFootnoteDefinitionIndent",5);function n(o){const s=l.events[l.events.length-1];return s&&s[1].type==="gfmFootnoteDefinitionIndent"&&s[2].sliceSerialize(s[1],!0).length===4?t(o):i(o)}}function z9(e){let i=(e||{}).singleTilde;const l={name:"strikethrough",tokenize:o,resolveAll:n};return i==null&&(i=!0),{text:{126:l},insideSpan:{null:[l]},attentionMarkers:{null:[126]}};function n(s,f){let m=-1;for(;++m<s.length;)if(s[m][0]==="enter"&&s[m][1].type==="strikethroughSequenceTemporary"&&s[m][1]._close){let d=m;for(;d--;)if(s[d][0]==="exit"&&s[d][1].type==="strikethroughSequenceTemporary"&&s[d][1]._open&&s[m][1].end.offset-s[m][1].start.offset===s[d][1].end.offset-s[d][1].start.offset){s[m][1].type="strikethroughSequence",s[d][1].type="strikethroughSequence";const p={type:"strikethrough",start:Object.assign({},s[d][1].start),end:Object.assign({},s[m][1].end)},v={type:"strikethroughText",start:Object.assign({},s[d][1].end),end:Object.assign({},s[m][1].start)},b=[["enter",p,f],["enter",s[d][1],f],["exit",s[d][1],f],["enter",v,f]],x=f.parser.constructs.insideSpan.null;x&&mn(b,b.length,0,Kc(x,s.slice(d+1,m),f)),mn(b,b.length,0,[["exit",v,f],["enter",s[m][1],f],["exit",s[m][1],f],["exit",p,f]]),mn(s,d-1,m-d+3,b),m=d+b.length-2;break}}for(m=-1;++m<s.length;)s[m][1].type==="strikethroughSequenceTemporary"&&(s[m][1].type="data");return s}function o(s,f,m){const d=this.previous,p=this.events;let v=0;return b;function b(S){return d===126&&p[p.length-1][1].type!=="characterEscape"?m(S):(s.enter("strikethroughSequenceTemporary"),x(S))}function x(S){const w=Xa(d);if(S===126)return v>1?m(S):(s.consume(S),v++,x);if(v<2&&!i)return m(S);const j=s.exit("strikethroughSequenceTemporary"),E=Xa(S);return j._open=!E||E===2&&!!w,j._close=!w||w===2&&!!E,f(S)}}}class N9{constructor(){this.map=[]}add(t,i,l){O9(this,t,i,l)}consume(t){if(this.map.sort(function(o,s){return o[0]-s[0]}),this.map.length===0)return;let i=this.map.length;const l=[];for(;i>0;)i-=1,l.push(t.slice(this.map[i][0]+this.map[i][1]),this.map[i][2]),t.length=this.map[i][0];l.push(t.slice()),t.length=0;let n=l.pop();for(;n;){for(const o of n)t.push(o);n=l.pop()}this.map.length=0}}function O9(e,t,i,l){let n=0;if(!(i===0&&l.length===0)){for(;n<e.map.length;){if(e.map[n][0]===t){e.map[n][1]+=i,e.map[n][2].push(...l);return}n+=1}e.map.push([t,i,l])}}function T9(e,t){let i=!1;const l=[];for(;t<e.length;){const n=e[t];if(i){if(n[0]==="enter")n[1].type==="tableContent"&&l.push(e[t+1][1].type==="tableDelimiterMarker"?"left":"none");else if(n[1].type==="tableContent"){if(e[t-1][1].type==="tableDelimiterMarker"){const o=l.length-1;l[o]=l[o]==="left"?"center":"right"}}else if(n[1].type==="tableDelimiterRow")break}else n[0]==="enter"&&n[1].type==="tableDelimiterRow"&&(i=!0);t+=1}return l}function C9(){return{flow:{null:{name:"table",tokenize:D9,resolveAll:A9}}}}function D9(e,t,i){const l=this;let n=0,o=0,s;return f;function f(B){let ue=l.events.length-1;for(;ue>-1;){const M=l.events[ue][1].type;if(M==="lineEnding"||M==="linePrefix")ue--;else break}const ce=ue>-1?l.events[ue][1].type:null,ke=ce==="tableHead"||ce==="tableRow"?R:m;return ke===R&&l.parser.lazy[l.now().line]?i(B):ke(B)}function m(B){return e.enter("tableHead"),e.enter("tableRow"),d(B)}function d(B){return B===124||(s=!0,o+=1),p(B)}function p(B){return B===null?i(B):ye(B)?o>1?(o=0,l.interrupt=!0,e.exit("tableRow"),e.enter("lineEnding"),e.consume(B),e.exit("lineEnding"),x):i(B):Re(B)?Pe(e,p,"whitespace")(B):(o+=1,s&&(s=!1,n+=1),B===124?(e.enter("tableCellDivider"),e.consume(B),e.exit("tableCellDivider"),s=!0,p):(e.enter("data"),v(B)))}function v(B){return B===null||B===124||We(B)?(e.exit("data"),p(B)):(e.consume(B),B===92?b:v)}function b(B){return B===92||B===124?(e.consume(B),v):v(B)}function x(B){return l.interrupt=!1,l.parser.lazy[l.now().line]?i(B):(e.enter("tableDelimiterRow"),s=!1,Re(B)?Pe(e,S,"linePrefix",l.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(B):S(B))}function S(B){return B===45||B===58?j(B):B===124?(s=!0,e.enter("tableCellDivider"),e.consume(B),e.exit("tableCellDivider"),w):J(B)}function w(B){return Re(B)?Pe(e,j,"whitespace")(B):j(B)}function j(B){return B===58?(o+=1,s=!0,e.enter("tableDelimiterMarker"),e.consume(B),e.exit("tableDelimiterMarker"),E):B===45?(o+=1,E(B)):B===null||ye(B)?G(B):J(B)}function E(B){return B===45?(e.enter("tableDelimiterFiller"),O(B)):J(B)}function O(B){return B===45?(e.consume(B),O):B===58?(s=!0,e.exit("tableDelimiterFiller"),e.enter("tableDelimiterMarker"),e.consume(B),e.exit("tableDelimiterMarker"),N):(e.exit("tableDelimiterFiller"),N(B))}function N(B){return Re(B)?Pe(e,G,"whitespace")(B):G(B)}function G(B){return B===124?S(B):B===null||ye(B)?!s||n!==o?J(B):(e.exit("tableDelimiterRow"),e.exit("tableHead"),t(B)):J(B)}function J(B){return i(B)}function R(B){return e.enter("tableRow"),X(B)}function X(B){return B===124?(e.enter("tableCellDivider"),e.consume(B),e.exit("tableCellDivider"),X):B===null||ye(B)?(e.exit("tableRow"),t(B)):Re(B)?Pe(e,X,"whitespace")(B):(e.enter("data"),Q(B))}function Q(B){return B===null||B===124||We(B)?(e.exit("data"),X(B)):(e.consume(B),B===92?me:Q)}function me(B){return B===92||B===124?(e.consume(B),Q):Q(B)}}function A9(e,t){let i=-1,l=!0,n=0,o=[0,0,0,0],s=[0,0,0,0],f=!1,m=0,d,p,v;const b=new N9;for(;++i<e.length;){const x=e[i],S=x[1];x[0]==="enter"?S.type==="tableHead"?(f=!1,m!==0&&(cS(b,t,m,d,p),p=void 0,m=0),d={type:"table",start:Object.assign({},S.start),end:Object.assign({},S.end)},b.add(i,0,[["enter",d,t]])):S.type==="tableRow"||S.type==="tableDelimiterRow"?(l=!0,v=void 0,o=[0,0,0,0],s=[0,i+1,0,0],f&&(f=!1,p={type:"tableBody",start:Object.assign({},S.start),end:Object.assign({},S.end)},b.add(i,0,[["enter",p,t]])),n=S.type==="tableDelimiterRow"?2:p?3:1):n&&(S.type==="data"||S.type==="tableDelimiterMarker"||S.type==="tableDelimiterFiller")?(l=!1,s[2]===0&&(o[1]!==0&&(s[0]=s[1],v=Ns(b,t,o,n,void 0,v),o=[0,0,0,0]),s[2]=i)):S.type==="tableCellDivider"&&(l?l=!1:(o[1]!==0&&(s[0]=s[1],v=Ns(b,t,o,n,void 0,v)),o=s,s=[o[1],i,0,0])):S.type==="tableHead"?(f=!0,m=i):S.type==="tableRow"||S.type==="tableDelimiterRow"?(m=i,o[1]!==0?(s[0]=s[1],v=Ns(b,t,o,n,i,v)):s[1]!==0&&(v=Ns(b,t,s,n,i,v)),n=0):n&&(S.type==="data"||S.type==="tableDelimiterMarker"||S.type==="tableDelimiterFiller")&&(s[3]=i)}for(m!==0&&cS(b,t,m,d,p),b.consume(t.events),i=-1;++i<t.events.length;){const x=t.events[i];x[0]==="enter"&&x[1].type==="table"&&(x[1]._align=T9(t.events,i))}return e}function Ns(e,t,i,l,n,o){const s=l===1?"tableHeader":l===2?"tableDelimiter":"tableData",f="tableContent";i[0]!==0&&(o.end=Object.assign({},La(t.events,i[0])),e.add(i[0],0,[["exit",o,t]]));const m=La(t.events,i[1]);if(o={type:s,start:Object.assign({},m),end:Object.assign({},m)},e.add(i[1],0,[["enter",o,t]]),i[2]!==0){const d=La(t.events,i[2]),p=La(t.events,i[3]),v={type:f,start:Object.assign({},d),end:Object.assign({},p)};if(e.add(i[2],0,[["enter",v,t]]),l!==2){const b=t.events[i[2]],x=t.events[i[3]];if(b[1].end=Object.assign({},x[1].end),b[1].type="chunkText",b[1].contentType="text",i[3]>i[2]+1){const S=i[2]+1,w=i[3]-i[2]-1;e.add(S,w,[])}}e.add(i[3]+1,0,[["exit",v,t]])}return n!==void 0&&(o.end=Object.assign({},La(t.events,n)),e.add(n,0,[["exit",o,t]]),o=void 0),o}function cS(e,t,i,l,n){const o=[],s=La(t.events,i);n&&(n.end=Object.assign({},s),o.push(["exit",n,t])),l.end=Object.assign({},s),o.push(["exit",l,t]),e.add(i+1,0,o)}function La(e,t){const i=e[t],l=i[0]==="enter"?"start":"end";return i[1][l]}const R9={name:"tasklistCheck",tokenize:U9};function I9(){return{text:{91:R9}}}function U9(e,t,i){const l=this;return n;function n(m){return l.previous!==null||!l._gfmTasklistFirstContentOfListItem?i(m):(e.enter("taskListCheck"),e.enter("taskListCheckMarker"),e.consume(m),e.exit("taskListCheckMarker"),o)}function o(m){return We(m)?(e.enter("taskListCheckValueUnchecked"),e.consume(m),e.exit("taskListCheckValueUnchecked"),s):m===88||m===120?(e.enter("taskListCheckValueChecked"),e.consume(m),e.exit("taskListCheckValueChecked"),s):i(m)}function s(m){return m===93?(e.enter("taskListCheckMarker"),e.consume(m),e.exit("taskListCheckMarker"),e.exit("taskListCheck"),f):i(m)}function f(m){return ye(m)?t(m):Re(m)?e.check({tokenize:L9},t,i)(m):i(m)}}function L9(e,t,i){return Pe(e,l,"whitespace");function l(n){return n===null?i(n):t(n)}}function M9(e){return fz([c9(),x9(),z9(e),C9(),I9()])}const P9={};function fS(e){const t=this,i=e||P9,l=t.data(),n=l.micromarkExtensions||(l.micromarkExtensions=[]),o=l.fromMarkdownExtensions||(l.fromMarkdownExtensions=[]),s=l.toMarkdownExtensions||(l.toMarkdownExtensions=[]);n.push(M9(i)),o.push(l9()),s.push(o9(i))}const Z9="composer_proxy_admin_token";function q9(){return typeof window<"u"?localStorage.getItem(Z9):null}function F9({distUrl:e,version:t}){const[i,l]=C.useState(!1),[n,o]=C.useState(null),s=async f=>{f.stopPropagation(),l(!0),o(null);try{const m=q9(),d={};m&&(d.Authorization=`Bearer ${m}`);const p=await fetch(e,{headers:d});if(!p.ok)throw new Error(`Download failed: ${p.status} ${p.statusText}`);const v=await p.blob(),b=window.URL.createObjectURL(v),x=document.createElement("a");x.href=b,x.download=e.split("/").pop()||"package.zip",document.body.appendChild(x),x.click(),document.body.removeChild(x),window.URL.revokeObjectURL(b)}catch(m){o(m instanceof Error?m.message:"Download failed")}finally{l(!1)}};return n?y.jsxs("div",{className:"flex flex-col items-end gap-1",children:[y.jsx("button",{onClick:s,className:"text-red-400 hover:text-red-300 text-sm",children:"Retry"}),y.jsx("span",{className:"text-xs text-red-500",children:n})]}):y.jsx("button",{onClick:s,disabled:i,className:"btn-primary text-sm disabled:opacity-50 disabled:cursor-not-allowed",children:i?"Downloading...":`Download ${t}`})}function B9({text:e,label:t}){const[i,l]=C.useState(!1),n=async()=>{try{await navigator.clipboard.writeText(e),l(!0),setTimeout(()=>l(!1),2e3)}catch(o){console.error("Failed to copy:",o)}};return y.jsx("button",{onClick:n,className:"px-3 py-1.5 bg-slate-800 hover:bg-slate-700 border border-slate-700 rounded-lg text-sm text-slate-300 hover:text-slate-100 transition-colors flex items-center gap-2",title:i?"Copied!":`Copy ${t||"command"}`,children:i?y.jsxs(y.Fragment,{children:[y.jsx("span",{children:"✓"}),y.jsx("span",{children:"Copied!"})]}):y.jsxs(y.Fragment,{children:[y.jsx("span",{children:"📋"}),y.jsx("span",{children:"Copy"})]})})}function H9(){const{vendor:e,package:t}=$S(),i=er(),l=wo(),n=qn(),o=e&&t?`${e}/${t}`:null,s=()=>{const M=i.hash;return M.startsWith("#version--")?M.replace("#version--",""):null},[f,m]=C.useState(s()),[d,p]=C.useState(!1),[v,b]=C.useState(!1),[x,S]=C.useState(null);C.useEffect(()=>{const M=s();M!==f&&m(M)},[i.hash]);const w=M=>{m(M),window.location.hash=`version--${M}`},{data:j,isLoading:E}=dn({queryKey:["package",o],queryFn:()=>IC(o),enabled:!!o}),O=C.useMemo(()=>j?.versions?[...j.versions].sort((M,U)=>{const A=/^\d+$/.test(M.version),q=/^\d+$/.test(U.version);if(A&&q){const Z=parseInt(M.version,10);return parseInt(U.version,10)-Z}if(A&&!q&&Qn.valid(U.version))return 1;if(!A&&q&&Qn.valid(M.version))return-1;const te=Qn.valid(M.version),ie=Qn.valid(U.version);if(te&&ie)return Qn.rcompare(M.version,U.version);if(te&&!ie)return-1;if(!te&&ie)return 1;const z=M.version.match(/^(\d+)/),T=U.version.match(/^(\d+)/);if(z&&T){const Z=parseInt(z[1],10),$=parseInt(T[1],10);if(Z!==$)return $-Z}return U.version.localeCompare(M.version,void 0,{numeric:!0,sensitivity:"base"})}):[],[j]),N=C.useMemo(()=>O.length?f&&O.find(M=>M.version===f)||O[0]:null,[O,f]),{data:G,isLoading:J}=dn({queryKey:["readme",o,N?.version],queryFn:()=>LC(o,N.version),enabled:!!o&&!!N}),R=C.useMemo(()=>!O.length||!N?!1:N.version===O[0].version,[O,N]),{data:X,isLoading:Q}=dn({queryKey:["changelog",o,N?.version],queryFn:()=>MC(o,N.version),enabled:!!o&&!!N&&R}),{data:me,isLoading:B}=dn({queryKey:["stats",o,N?.version],queryFn:()=>PC(o,N.version),enabled:!!o&&!!N}),ue=Cn({mutationFn:({name:M,version:U})=>VS(M,U),onSuccess:(M,{version:U})=>{if(n.invalidateQueries({queryKey:["package",o]}),n.invalidateQueries({queryKey:["packages"]}),S(null),N?.version===U){const A=O.filter(q=>q.version!==U);A.length>0?w(A[0].version):l("/packages")}}}),ce=M=>{if(!M)return[];try{const U=JSON.parse(M);return Array.isArray(U)?U:[U]}catch{return[M]}};if(E)return y.jsx("div",{className:"flex items-center justify-center min-h-[400px]",children:y.jsx("div",{className:"w-8 h-8 border-2 border-slate-600 border-t-primary-500 rounded-full animate-spin"})});if(!o)return y.jsxs("div",{className:"card p-8 text-center",children:[y.jsx("p",{className:"text-slate-400",children:"Invalid package name"}),y.jsx(Za,{to:"/packages",className:"text-primary-400 hover:text-primary-300 mt-4 inline-block",children:"← Back to packages"})]});if(!j||!N)return y.jsxs("div",{className:"card p-8 text-center",children:[y.jsxs("p",{className:"text-slate-400",children:["Package not found: ",o]}),y.jsx(Za,{to:"/packages",className:"text-primary-400 hover:text-primary-300 mt-4 inline-block",children:"← Back to packages"})]});const ke=ce(N.license);return y.jsxs("div",{className:"space-y-6",children:[y.jsx("div",{className:"card p-6",children:y.jsx("div",{className:"flex items-start justify-between gap-4",children:y.jsxs("div",{className:"flex-1 min-w-0",children:[y.jsxs("div",{className:"flex items-center gap-3 mb-2 flex-wrap",children:[y.jsx("h1",{className:"font-display text-3xl font-bold text-slate-100",children:j.name}),y.jsx("select",{value:f||N.version,onChange:M=>w(M.target.value),className:"px-3 py-1.5 bg-slate-800 border border-slate-700 rounded-lg text-slate-100 focus:outline-none focus:ring-2 focus:ring-primary-500 text-sm",children:O.map(M=>y.jsxs("option",{value:M.version,children:[M.version,M.is_manual_upload?" (manual)":""]},M.version))}),N.is_manual_upload===1&&y.jsx("span",{className:"px-2.5 py-1 text-xs font-medium bg-blue-600/20 text-blue-400 border border-blue-500/30 rounded-full",children:"📤 Manual Upload"})]}),N.description&&y.jsx("p",{className:"text-slate-300 text-lg",children:N.description})]})})}),y.jsxs("div",{className:"grid grid-cols-1 lg:grid-cols-3 gap-6",children:[y.jsxs("div",{className:"lg:col-span-2",children:[y.jsxs("div",{className:"card p-6",children:[y.jsx("h2",{className:"text-xl font-bold text-slate-100 mb-4",children:"README.md"}),J?y.jsx("div",{className:"flex items-center justify-center py-12",children:y.jsx("div",{className:"w-6 h-6 border-2 border-slate-600 border-t-primary-500 rounded-full animate-spin"})}):G?y.jsxs(y.Fragment,{children:[y.jsxs("div",{className:`prose prose-invert max-w-none ${d?"":"max-h-[300px] overflow-hidden relative"}`,children:[!d&&y.jsx("div",{className:"absolute bottom-0 left-0 right-0 h-20 bg-gradient-to-t from-slate-900 to-transparent pointer-events-none"}),y.jsx("div",{className:"markdown-content",children:y.jsx(rS,{remarkPlugins:[fS],components:{a:({node:M,...U})=>y.jsx("a",{...U,className:"text-primary-400 hover:text-primary-300",target:"_blank",rel:"noopener noreferrer"}),code:({node:M,className:U,children:A,...q})=>!U?y.jsx("code",{className:"px-1.5 py-0.5 bg-slate-800 rounded text-sm text-primary-300",...q,children:A}):y.jsx("code",{className:"block p-4 bg-slate-900 rounded-lg overflow-x-auto text-sm",...q,children:A})},children:G})})]}),!d&&y.jsx("button",{onClick:()=>p(!0),className:"mt-4 text-primary-400 hover:text-primary-300 text-sm font-medium transition-colors",children:"Expand full README →"}),d&&y.jsx("button",{onClick:()=>p(!1),className:"mt-4 text-primary-400 hover:text-primary-300 text-sm font-medium transition-colors",children:"Collapse README ↑"})]}):y.jsxs("div",{className:"text-center py-12 text-slate-500",children:[y.jsx("p",{className:"mb-2",children:"📄 No README available for this version"}),y.jsx("p",{className:"text-sm text-slate-600",children:"No README file exists in this package version"})]})]}),R&&y.jsxs("div",{className:"card p-6 mt-6",children:[y.jsx("h2",{className:"text-xl font-bold text-slate-100 mb-4",children:"CHANGELOG"}),Q?y.jsx("div",{className:"flex items-center justify-center py-12",children:y.jsx("div",{className:"w-6 h-6 border-2 border-slate-600 border-t-primary-500 rounded-full animate-spin"})}):X?y.jsxs(y.Fragment,{children:[y.jsxs("div",{className:`prose prose-invert max-w-none ${v?"":"max-h-[300px] overflow-hidden relative"}`,children:[!v&&y.jsx("div",{className:"absolute bottom-0 left-0 right-0 h-20 bg-gradient-to-t from-slate-900 to-transparent pointer-events-none"}),y.jsx("div",{className:"markdown-content",children:y.jsx(rS,{remarkPlugins:[fS],components:{a:({node:M,...U})=>y.jsx("a",{...U,className:"text-primary-400 hover:text-primary-300",target:"_blank",rel:"noopener noreferrer"}),code:({node:M,className:U,children:A,...q})=>!U?y.jsx("code",{className:"px-1.5 py-0.5 bg-slate-800 rounded text-sm text-primary-300",...q,children:A}):y.jsx("code",{className:"block p-4 bg-slate-900 rounded-lg overflow-x-auto text-sm",...q,children:A})},children:X})})]}),!v&&y.jsx("button",{onClick:()=>b(!0),className:"mt-4 text-primary-400 hover:text-primary-300 text-sm font-medium transition-colors",children:"Expand full CHANGELOG →"}),v&&y.jsx("button",{onClick:()=>b(!1),className:"mt-4 text-primary-400 hover:text-primary-300 text-sm font-medium transition-colors",children:"Collapse CHANGELOG ↑"})]}):y.jsxs("div",{className:"text-center py-12 text-slate-500",children:[y.jsx("p",{className:"mb-2",children:"📝 No CHANGELOG available"}),y.jsx("p",{className:"text-sm text-slate-600",children:"No CHANGELOG file exists in this package version"})]})]})]}),y.jsxs("div",{className:"space-y-6",children:[y.jsxs("div",{className:"card p-6",children:[y.jsx("h3",{className:"text-lg font-semibold text-slate-100 mb-4",children:"Get Package"}),y.jsxs("div",{className:"space-y-4",children:[y.jsxs("div",{children:[y.jsx("label",{className:"block text-sm text-slate-400 mb-2",children:"Install via Composer"}),y.jsxs("div",{className:"flex items-center gap-2",children:[y.jsxs("code",{className:"flex-1 min-w-0 px-3 py-2 bg-slate-900 border border-slate-700 rounded-lg text-sm text-primary-300 font-mono break-all",children:["composer require ",j.name,":",N.version]}),y.jsx(B9,{text:`composer require ${j.name}:${N.version}`})]})]}),y.jsx("div",{className:"pt-2 border-t border-slate-700",children:y.jsx(F9,{distUrl:N.dist_url,version:N.version})})]})]}),y.jsxs("div",{className:"card p-6",children:[y.jsx("h3",{className:"text-lg font-semibold text-slate-100 mb-4",children:"About Package"}),y.jsxs("div",{className:"space-y-4",children:[N.package_type&&y.jsxs("div",{children:[y.jsx("span",{className:"text-sm text-slate-400 block mb-1",children:"Type"}),y.jsx("span",{className:"px-3 py-1 text-sm bg-slate-700 text-slate-200 rounded-lg inline-block",children:N.package_type})]}),ke.length>0&&y.jsxs("div",{children:[y.jsx("span",{className:"text-sm text-slate-400 block mb-1",children:"License"}),y.jsx("span",{className:"px-3 py-1 text-sm bg-slate-700 text-slate-200 rounded-lg inline-block",children:ke.join(", ")})]}),N.homepage&&y.jsxs("div",{children:[y.jsx("span",{className:"text-sm text-slate-400 block mb-1",children:"Homepage"}),y.jsxs("a",{href:N.homepage,target:"_blank",rel:"noopener noreferrer",className:"flex items-center gap-2 text-primary-400 hover:text-primary-300 transition-colors text-sm min-w-0",children:[y.jsx("span",{className:"flex-shrink-0",children:"🌐"}),y.jsx("span",{className:"truncate block min-w-0",children:N.homepage}),y.jsx("span",{className:"text-slate-500 flex-shrink-0",children:"→"})]})]}),y.jsxs("div",{className:"pt-2 border-t border-slate-700 space-y-2",children:[y.jsx("span",{className:"text-sm text-slate-400 block mb-1",children:"Statistics"}),B?y.jsxs("div",{className:"flex items-center gap-2 text-sm text-slate-500",children:[y.jsx("div",{className:"w-4 h-4 border-2 border-slate-600 border-t-primary-500 rounded-full animate-spin"}),y.jsx("span",{children:"Loading stats..."})]}):me?y.jsxs(y.Fragment,{children:[y.jsxs("div",{className:"text-sm",children:[y.jsx("span",{className:"text-slate-400",children:"Downloads: "}),y.jsx("span",{className:"text-slate-200 font-medium",children:me.downloads.toLocaleString()})]}),me.lastDownloadedAt?y.jsxs("div",{className:"text-sm",children:[y.jsx("span",{className:"text-slate-400",children:"Last downloaded: "}),y.jsx("span",{className:"text-slate-200",children:new Date(me.lastDownloadedAt*1e3).toLocaleDateString()})]}):y.jsx("div",{className:"text-sm text-slate-500",children:"Never downloaded"})]}):y.jsx("div",{className:"text-sm text-slate-500",children:"No download statistics available"})]})]})]}),y.jsxs("div",{className:"card p-6",children:[y.jsxs("h3",{className:"text-lg font-semibold text-slate-100 mb-4",children:["Versions (",O.length,")"]}),y.jsx("div",{className:"space-y-2 max-h-96 overflow-y-auto",children:O.map(M=>y.jsx("div",{className:`px-3 py-2 rounded-lg transition-colors ${(f||N.version)===M.version?"bg-primary-500/20":"bg-slate-800/50 hover:bg-slate-800"}`,children:y.jsxs("div",{className:"flex items-center justify-between gap-2",children:[y.jsx("button",{onClick:()=>w(M.version),className:`flex-1 text-left font-medium ${(f||N.version)===M.version?"text-primary-400":"text-slate-300"}`,children:M.version}),y.jsxs("div",{className:"flex items-center gap-2 flex-shrink-0",children:[M.is_manual_upload===1&&y.jsx("span",{className:"px-1.5 py-0.5 text-[10px] bg-blue-600/20 text-blue-400 rounded",title:"Manually uploaded",children:"📤"}),M.released_at&&y.jsx("span",{className:"text-xs text-slate-500",children:new Date(M.released_at*1e3).toLocaleDateString()}),x===M.version?y.jsxs("div",{className:"flex gap-1",children:[y.jsx("button",{onClick:()=>ue.mutate({name:o,version:M.version}),disabled:ue.isPending,className:"px-2 py-0.5 text-xs bg-red-600 hover:bg-red-500 text-white rounded disabled:opacity-50",title:"Confirm delete",children:ue.isPending?"...":"✓"}),y.jsx("button",{onClick:()=>S(null),className:"px-2 py-0.5 text-xs bg-slate-600 hover:bg-slate-500 text-white rounded",title:"Cancel",children:"✕"})]}):y.jsx("button",{onClick:U=>{U.stopPropagation(),S(M.version)},className:"p-1 text-slate-500 hover:text-red-400 hover:bg-red-500/10 rounded transition-colors",title:"Delete this version",children:y.jsx("svg",{className:"w-3.5 h-3.5",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:y.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M19 7l-.867 12.142A2 2 0 0116.138 21H7.862a2 2 0 01-1.995-1.858L5 7m5 4v6m4-6v6m1-10V4a1 1 0 00-1-1h-4a1 1 0 00-1 1v3M4 7h16"})})})]})]})},M.version))}),ue.isError&&y.jsx("div",{className:"mt-3 p-2 bg-red-500/10 border border-red-500/30 rounded text-sm text-red-400",children:ue.error instanceof Error?ue.error.message:"Failed to delete"})]})]})]})]})}function G9({onSuccess:e}){const{login:t,authError:i}=nl(),[l,n]=C.useState(""),[o,s]=C.useState(""),[f,m]=C.useState(""),[d,p]=C.useState(null),[v,b]=C.useState(!1),x=async S=>{S.preventDefault(),d!=="2FA required"&&p(null),b(!0);try{const w=await fetch("/api/auth/login",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({email:l,password:o,code:f})}),j=await w.json();w.ok&&j.token?(t(j.token),e()):j.code==="2fa_required"?p("2FA required"):p(j.message||j.error||"Invalid credentials")}catch{p("Failed to connect to server")}finally{b(!1)}};return y.jsx("div",{className:"min-h-screen flex items-center justify-center bg-gradient-to-br from-slate-900 via-slate-800 to-slate-900",children:y.jsx("div",{className:"max-w-md w-full mx-4",children:y.jsxs("div",{className:"bg-slate-800/50 backdrop-blur-sm rounded-2xl shadow-2xl border border-slate-700/50 p-8",children:[y.jsxs("div",{className:"text-center mb-8",children:[y.jsx("div",{className:"inline-flex items-center justify-center w-16 h-16 rounded-2xl bg-gradient-to-br from-orange-500 to-amber-600 mb-4",children:y.jsx(Ii,{className:"w-8 h-8 text-white"})}),y.jsx("h1",{className:"text-2xl font-bold text-white",children:"Composer Proxy"}),y.jsx("p",{className:"text-slate-400 mt-1",children:"Sign in to manage your packages"})]}),y.jsxs("form",{onSubmit:x,className:"space-y-5","data-testid":"login-form",children:[i&&y.jsxs("div",{role:"alert","aria-live":"polite","data-testid":"auth-context-error",className:"bg-red-500/10 border border-red-500/50 rounded-lg p-4 text-red-400 text-sm mb-4",children:["Auth Error: ",i]}),d&&y.jsx("div",{role:"alert","aria-live":"polite","data-testid":"login-error",className:"bg-red-500/10 border border-red-500/50 rounded-lg p-4 text-red-400 text-sm",children:d}),y.jsxs("div",{children:[y.jsx("label",{htmlFor:"email",className:"block text-sm font-medium text-slate-300 mb-2",children:"Email"}),y.jsx("input",{id:"email",type:"email",value:l,onChange:S=>n(S.target.value),className:"w-full px-4 py-3 bg-slate-900/50 border border-slate-600 rounded-lg text-white placeholder-slate-500 focus:outline-none focus:ring-2 focus:ring-orange-500 focus:border-transparent transition",placeholder:"admin@example.com",required:!0,"aria-label":"Email address",disabled:v})]}),y.jsxs("div",{children:[y.jsx("label",{htmlFor:"password",className:"block text-sm font-medium text-slate-300 mb-2",children:"Password"}),y.jsx("input",{id:"password",type:"password",value:o,onChange:S=>s(S.target.value),className:"w-full px-4 py-3 bg-slate-900/50 border border-slate-600 rounded-lg text-white placeholder-slate-500 focus:outline-none focus:ring-2 focus:ring-orange-500 focus:border-transparent transition",placeholder:"Enter your password",required:!0,"aria-label":"Password",disabled:v})]}),d==="2FA required"&&y.jsxs("div",{className:"animate-in fade-in slide-in-from-top-2 duration-300",children:[y.jsx("label",{htmlFor:"code",className:"block text-sm font-medium text-slate-300 mb-2",children:"2FA Code"}),y.jsx("input",{id:"code",type:"text",value:f,onChange:S=>m(S.target.value),className:"w-full px-4 py-3 bg-slate-900/50 border border-slate-600 rounded-lg text-white placeholder-slate-500 focus:outline-none focus:ring-2 focus:ring-orange-500 focus:border-transparent transition",placeholder:"000000",required:!0,autoFocus:!0,maxLength:6,pattern:"\\d{6}","aria-label":"2FA Code",disabled:v})]}),y.jsx("button",{type:"submit",disabled:v||!l||!o||d==="2FA required"&&f.length!==6,className:"w-full py-3 px-4 bg-gradient-to-r from-orange-500 to-amber-600 hover:from-orange-600 hover:to-amber-700 text-white font-semibold rounded-lg shadow-lg shadow-orange-500/25 transition disabled:opacity-50 disabled:cursor-not-allowed","aria-label":"Sign in",children:v?"Signing in...":"Sign In"})]})]})})})}function V9(){const{token:e}=$S(),t=wo(),[i,l]=C.useState(""),[n,o]=C.useState(""),[s,f]=C.useState(""),[m,d]=C.useState(!1),[p]=QT(),v=p.get("token"),b=e||v,x=async S=>{if(S.preventDefault(),!b){f("Invalid invite link");return}if(i!==n){f("Passwords do not match");return}if(i.length<8){f("Password must be at least 8 characters");return}d(!0),f("");try{await JC(b,i),t("/login",{state:{message:"Password set successfully! Please login."}})}catch(w){f(w.message||"Failed to accept invite")}finally{d(!1)}};return b?y.jsx("div",{className:"min-h-screen flex items-center justify-center bg-gradient-to-br from-slate-900 via-slate-800 to-slate-900",children:y.jsx("div",{className:"max-w-md w-full mx-4",children:y.jsxs("div",{className:"bg-slate-800/50 backdrop-blur-sm rounded-2xl shadow-2xl border border-slate-700/50 p-8",children:[y.jsxs("div",{className:"text-center mb-8",children:[y.jsx("div",{className:"inline-flex items-center justify-center w-16 h-16 rounded-2xl bg-gradient-to-br from-orange-500 to-amber-600 mb-4",children:y.jsx(Ii,{className:"w-8 h-8 text-white"})}),y.jsx("h1",{className:"text-2xl font-bold text-white",children:"Welcome"}),y.jsx("p",{className:"text-slate-400 mt-1",children:"Set your password to accept the invitation"})]}),y.jsxs("form",{className:"space-y-5",onSubmit:x,children:[y.jsxs("div",{children:[y.jsx("label",{htmlFor:"password",className:"block text-sm font-medium text-slate-300 mb-2",children:"New Password"}),y.jsx("input",{id:"password",name:"password",type:"password",required:!0,value:i,onChange:S=>l(S.target.value),className:"w-full px-4 py-3 bg-slate-900/50 border border-slate-600 rounded-lg text-white placeholder-slate-500 focus:outline-none focus:ring-2 focus:ring-orange-500 focus:border-transparent transition",placeholder:"Minimum 8 characters",minLength:8})]}),y.jsxs("div",{children:[y.jsx("label",{htmlFor:"confirmPassword",className:"block text-sm font-medium text-slate-300 mb-2",children:"Confirm Password"}),y.jsx("input",{id:"confirmPassword",name:"confirmPassword",type:"password",required:!0,value:n,onChange:S=>o(S.target.value),className:"w-full px-4 py-3 bg-slate-900/50 border border-slate-600 rounded-lg text-white placeholder-slate-500 focus:outline-none focus:ring-2 focus:ring-orange-500 focus:border-transparent transition",placeholder:"Confirm your password"})]}),s&&y.jsx("div",{className:"bg-red-500/10 border border-red-500/50 rounded-lg p-4 text-red-400 text-sm",children:s}),y.jsx("button",{type:"submit",disabled:m,className:"w-full py-3 px-4 bg-gradient-to-r from-orange-500 to-amber-600 hover:from-orange-600 hover:to-amber-700 text-white font-semibold rounded-lg shadow-lg shadow-orange-500/25 transition disabled:opacity-50 disabled:cursor-not-allowed",children:m?"Setting password...":"Set Password and Login"})]})]})})}):y.jsx("div",{className:"min-h-screen flex items-center justify-center bg-gradient-to-br from-slate-900 via-slate-800 to-slate-900",children:y.jsx("div",{className:"max-w-md w-full mx-4",children:y.jsxs("div",{className:"bg-slate-800/50 backdrop-blur-sm rounded-2xl shadow-2xl border border-slate-700/50 p-8 text-center",children:[y.jsx("h2",{className:"text-2xl font-bold text-white mb-2",children:"Invalid Invite Link"}),y.jsx("p",{className:"text-slate-400",children:"Please check the link in your email."})]})})})}function Y9({onSuccess:e}){const[t,i]=C.useState(""),[l,n]=C.useState(""),[o,s]=C.useState(null),[f,m]=C.useState(!1),d=async p=>{p.preventDefault(),s(null),m(!0);try{await $C({email:t,password:l}),e()}catch(v){s(v.message||"Failed to complete setup")}finally{m(!1)}};return y.jsx("div",{className:"min-h-screen flex items-center justify-center bg-gradient-to-br from-slate-900 via-slate-800 to-slate-900",children:y.jsx("div",{className:"max-w-md w-full mx-4",children:y.jsxs("div",{className:"bg-slate-800/50 backdrop-blur-sm rounded-2xl shadow-2xl border border-slate-700/50 p-8",children:[y.jsxs("div",{className:"text-center mb-8",children:[y.jsx("div",{className:"inline-flex items-center justify-center w-16 h-16 rounded-2xl bg-gradient-to-br from-green-500 to-emerald-600 mb-4",children:y.jsx(Ii,{className:"w-8 h-8 text-white"})}),y.jsx("h1",{className:"text-2xl font-bold text-white",children:"Welcome!"}),y.jsx("p",{className:"text-slate-400 mt-1",children:"Create your Admin account to get started"})]}),y.jsxs("form",{onSubmit:d,className:"space-y-5","data-testid":"setup-form",children:[o&&y.jsx("div",{role:"alert","aria-live":"polite","data-testid":"setup-error",className:"bg-red-500/10 border border-red-500/50 rounded-lg p-4 text-red-400 text-sm",children:o}),y.jsxs("div",{children:[y.jsx("label",{htmlFor:"email",className:"block text-sm font-medium text-slate-300 mb-2",children:"Admin Email"}),y.jsx("input",{id:"email",type:"email",value:t,onChange:p=>i(p.target.value),className:"w-full px-4 py-3 bg-slate-900/50 border border-slate-600 rounded-lg text-white placeholder-slate-500 focus:outline-none focus:ring-2 focus:ring-green-500 focus:border-transparent transition",placeholder:"admin@example.com",required:!0,"aria-label":"Email address"})]}),y.jsxs("div",{children:[y.jsx("label",{htmlFor:"password",className:"block text-sm font-medium text-slate-300 mb-2",children:"Create Password"}),y.jsx("input",{id:"password",type:"password",value:l,onChange:p=>n(p.target.value),className:"w-full px-4 py-3 bg-slate-900/50 border border-slate-600 rounded-lg text-white placeholder-slate-500 focus:outline-none focus:ring-2 focus:ring-green-500 focus:border-transparent transition",placeholder:"Choose a strong password",required:!0,minLength:8,"aria-label":"Password"})]}),y.jsx("button",{type:"submit",disabled:f||!t||!l,className:"w-full py-3 px-4 bg-gradient-to-r from-green-500 to-emerald-600 hover:from-green-600 hover:to-emerald-700 text-white font-semibold rounded-lg shadow-lg shadow-green-500/25 transition disabled:opacity-50 disabled:cursor-not-allowed","aria-label":"Create Account",children:f?"Setting up...":"Create Account"})]})]})})})}function J9(){const[e,t]=C.useState([]),[i,l]=C.useState(!0),[n,o]=C.useState(null),[s,f]=C.useState(!1),{isAdmin:m}=nl(),[d,p]=C.useState(""),[v,b]=C.useState("viewer"),[x,S]=C.useState(!1);C.useEffect(()=>{w()},[]);const w=async()=>{try{const O=await FC();t(O)}catch(O){o(O.message)}finally{l(!1)}},j=async O=>{if(window.confirm("Are you sure you want to delete this user?"))try{await HC(O),t(e.filter(N=>N.id!==O))}catch(N){alert(N.message)}},E=async O=>{O.preventDefault(),S(!0);try{await BC({email:d,role:v}),f(!1),p(""),w(),alert("User invited successfully. They will receive an email to set their password.")}catch(N){alert(N.message)}finally{S(!1)}};return i?y.jsx("div",{className:"text-slate-400",children:"Loading users..."}):y.jsxs("div",{className:"space-y-6",children:[y.jsxs("div",{className:"flex items-center justify-between",children:[y.jsxs("div",{children:[y.jsx("h1",{className:"text-2xl font-bold text-slate-100",children:"Users"}),y.jsx("p",{className:"text-slate-400",children:"Manage access to the Composer Proxy"})]}),m&&y.jsxs("button",{onClick:()=>f(!0),className:"flex items-center gap-2 px-4 py-2 bg-primary-600 hover:bg-primary-500 text-white rounded-lg transition",children:[y.jsx(xC,{className:"w-5 h-5"}),"Invite User"]})]}),n&&y.jsx("div",{className:"bg-red-500/10 border border-red-500/50 rounded-lg p-4 text-red-400",children:n}),y.jsx("div",{className:"bg-slate-800/50 border border-slate-700 rounded-xl overflow-hidden",children:y.jsxs("table",{className:"w-full text-left border-collapse",children:[y.jsx("thead",{children:y.jsxs("tr",{className:"bg-slate-800 border-b border-slate-700",children:[y.jsx("th",{className:"px-6 py-4 text-sm font-semibold text-slate-300",children:"User"}),y.jsx("th",{className:"px-6 py-4 text-sm font-semibold text-slate-300",children:"Role"}),y.jsx("th",{className:"px-6 py-4 text-sm font-semibold text-slate-300",children:"Status"}),y.jsx("th",{className:"px-6 py-4 text-sm font-semibold text-slate-300",children:"Created"}),m&&y.jsx("th",{className:"px-6 py-4 text-right text-sm font-semibold text-slate-300",children:"Actions"})]})}),y.jsx("tbody",{className:"divide-y divide-slate-700",children:e.map(O=>y.jsxs("tr",{className:"hover:bg-slate-800/30 transition",children:[y.jsx("td",{className:"px-6 py-4",children:y.jsxs("div",{className:"flex items-center gap-3",children:[y.jsx("div",{className:"w-8 h-8 rounded-full bg-slate-700 flex items-center justify-center",children:y.jsx(Yh,{className:"w-4 h-4 text-slate-400"})}),y.jsxs("div",{children:[y.jsx("div",{className:"text-slate-200 font-medium",children:O.email}),y.jsx("div",{className:"text-xs text-slate-500 font-mono",children:O.id})]})]})}),y.jsx("td",{className:"px-6 py-4",children:y.jsxs("div",{className:"flex items-center gap-1.5 px-2.5 py-1 rounded-full bg-slate-700/50 border border-slate-600 w-fit",children:[y.jsx(Qs,{className:"w-3 h-3 text-primary-400"}),y.jsx("span",{className:"text-xs font-medium text-slate-300 capitalize",children:O.role})]})}),y.jsx("td",{className:"px-6 py-4",children:y.jsx("span",{className:`inline-flex items-center px-2.5 py-0.5 rounded-full text-xs font-medium ${O.status==="active"?"bg-green-500/10 text-green-400 border border-green-500/20":"bg-yellow-500/10 text-yellow-400 border border-yellow-500/20"}`,children:O.status})}),y.jsx("td",{className:"px-6 py-4 text-sm text-slate-400",children:new Date(O.created_at*1e3).toLocaleDateString()}),m&&y.jsx("td",{className:"px-6 py-4 text-right",children:y.jsx("button",{onClick:()=>j(O.id),className:"p-2 text-slate-400 hover:text-red-400 hover:bg-red-500/10 rounded-lg transition",title:"Delete User",children:y.jsx(pC,{className:"w-4 h-4"})})})]},O.id))})]})}),s&&y.jsx("div",{className:"fixed inset-0 bg-slate-900/80 backdrop-blur-sm z-50 flex items-center justify-center p-4",children:y.jsxs("div",{className:"bg-slate-800 border border-slate-700 rounded-xl shadow-2xl max-w-md w-full p-6",children:[y.jsx("h2",{className:"text-xl font-bold text-white mb-4",children:"Invite New User"}),y.jsxs("form",{onSubmit:E,className:"space-y-4",children:[y.jsxs("div",{children:[y.jsx("label",{className:"block text-sm font-medium text-slate-400 mb-1",children:"Email"}),y.jsxs("div",{className:"relative",children:[y.jsx(rC,{className:"absolute left-3 top-1/2 -translate-y-1/2 w-4 h-4 text-slate-500"}),y.jsx("input",{type:"email",value:d,onChange:O=>p(O.target.value),className:"w-full bg-slate-900 border border-slate-700 rounded-lg pl-9 pr-4 py-2 text-slate-200 focus:outline-none focus:ring-2 focus:ring-primary-500",placeholder:"user@example.com",required:!0})]})]}),y.jsxs("div",{children:[y.jsx("label",{className:"block text-sm font-medium text-slate-400 mb-1",children:"Role"}),y.jsxs("select",{value:v,onChange:O=>b(O.target.value),className:"w-full bg-slate-900 border border-slate-700 rounded-lg px-4 py-2 text-slate-200 focus:outline-none focus:ring-2 focus:ring-primary-500",children:[y.jsx("option",{value:"viewer",children:"Viewer"}),y.jsx("option",{value:"admin",children:"Admin"})]})]}),y.jsxs("div",{className:"flex justify-end gap-3 mt-6",children:[y.jsx("button",{type:"button",onClick:()=>f(!1),className:"px-4 py-2 text-slate-300 hover:text-white transition",children:"Cancel"}),y.jsx("button",{type:"submit",disabled:x,className:"px-4 py-2 bg-primary-600 hover:bg-primary-500 text-white rounded-lg transition disabled:opacity-50",children:x?"Inviting...":"Invite User"})]})]})]})})]})}function X9(){const[e,t]=C.useState(null),[i,l]=C.useState(!0),[n,o]=C.useState(null),[s,f]=C.useState(""),[m,d]=C.useState(null),[p,v]=C.useState(null),[b,x]=C.useState(!1);C.useEffect(()=>{S()},[]);const S=async()=>{try{const O=jo(),G=await(await fetch("/api/auth/me",{headers:{Authorization:`Bearer ${O}`}})).json();G.user&&t(G.user)}catch(O){console.error("Failed to fetch user",O)}finally{l(!1)}},w=async()=>{x(!0),v(null);try{const O=await GC();o(O)}catch{v("Failed to start 2FA setup")}finally{x(!1)}},j=async()=>{if(n){x(!0),v(null);try{const O=await VC(n.secret,s);d(O.recoveryCodes),o(null),f(""),await S()}catch{v("Invalid code")}finally{x(!1)}}},E=async()=>{if(confirm("Are you sure you want to disable 2FA? Your account will be less secure.")){x(!0),v(null);try{await YC(),await S()}catch{v("Failed to disable 2FA")}finally{x(!1)}}};return i?y.jsx("div",{className:"p-8 text-center text-slate-400",children:"Loading profile..."}):y.jsxs("div",{className:"space-y-6",children:[y.jsx("div",{className:"flex items-center justify-between",children:y.jsx("h1",{className:"text-2xl font-bold text-slate-100 font-display",children:"My Profile"})}),y.jsxs("div",{className:"bg-slate-800 rounded-lg border border-slate-700 p-6",children:[y.jsxs("div",{className:"flex items-center gap-4 mb-6",children:[y.jsx("div",{className:"w-16 h-16 bg-slate-700 rounded-full flex items-center justify-center text-2xl font-bold text-slate-300",children:e?.email[0].toUpperCase()}),y.jsxs("div",{children:[y.jsx("h2",{className:"text-xl font-semibold text-white",children:e?.email}),y.jsx("span",{className:"inline-flex items-center px-2.5 py-0.5 rounded-full text-xs font-medium bg-blue-500/10 text-blue-400 border border-blue-500/20 capitalize",children:e?.role})]})]}),y.jsxs("div",{className:"border-t border-slate-700 pt-6",children:[y.jsxs("h3",{className:"text-lg font-medium text-white mb-4 flex items-center gap-2",children:[y.jsx(Qs,{className:"w-5 h-5 text-orange-500"}),"Security"]}),y.jsxs("div",{className:"bg-slate-900/50 rounded-lg p-6 border border-slate-700/50",children:[y.jsxs("div",{className:"flex items-start justify-between mb-4",children:[y.jsxs("div",{children:[y.jsxs("h4",{className:"font-medium text-slate-200 flex items-center gap-2",children:["Two-Factor Authentication (2FA)",e?.two_factor_enabled&&y.jsx("span",{className:"text-xs bg-green-500/10 text-green-400 border border-green-500/20 px-2 py-0.5 rounded-full",children:"Enabled"})]}),y.jsx("p",{className:"text-sm text-slate-400 mt-1",children:"Add an extra layer of security to your account by requiring a code from your authenticator app."})]}),!e?.two_factor_enabled&&!n&&y.jsx("button",{onClick:w,disabled:b,className:"px-4 py-2 bg-orange-600 hover:bg-orange-700 text-white rounded-lg text-sm font-medium transition",children:"Enable 2FA"}),e?.two_factor_enabled&&y.jsx("button",{onClick:E,disabled:b,className:"px-4 py-2 bg-red-500/10 hover:bg-red-500/20 text-red-400 border border-red-500/20 rounded-lg text-sm font-medium transition",children:"Disable"})]}),n&&y.jsxs("div",{className:"mt-6 p-4 bg-slate-800 rounded-lg border border-slate-700 animate-in fade-in slide-in-from-top-4",children:[y.jsxs("h5",{className:"font-medium text-white mb-4 flex items-center gap-2",children:[y.jsx(mC,{className:"w-4 h-4"}),"Scan QR Code"]}),y.jsxs("div",{className:"grid md:grid-cols-2 gap-8",children:[y.jsxs("div",{className:"flex flex-col items-center",children:[y.jsx("div",{className:"bg-white p-2 rounded-lg mb-4",children:y.jsx("img",{src:n.qrCode,alt:"2FA QR Code",className:"w-48 h-48"})}),y.jsx("p",{className:"text-xs text-slate-500 text-center max-w-xs",children:"Scan this code with Google Authenticator, Authy, or 1Password."})]}),y.jsxs("div",{className:"flex flex-col justify-center space-y-4",children:[y.jsxs("div",{children:[y.jsx("label",{className:"block text-sm font-medium text-slate-400 mb-1",children:"Manual Entry Code"}),y.jsx("code",{className:"block w-full p-2 bg-slate-900 rounded text-slate-300 font-mono text-sm select-all",children:n.secret})]}),y.jsxs("div",{children:[y.jsx("label",{className:"block text-sm font-medium text-slate-400 mb-1",children:"Verification Code"}),y.jsxs("div",{className:"flex gap-2",children:[y.jsx("input",{type:"text",value:s,onChange:O=>f(O.target.value),placeholder:"000000",maxLength:6,className:"bg-slate-900 border border-slate-600 rounded px-3 py-2 text-white w-32 focus:ring-2 focus:ring-orange-500 outline-none"}),y.jsx("button",{onClick:j,disabled:s.length!==6||b,className:"px-4 py-2 bg-orange-600 hover:bg-orange-700 text-white rounded font-medium disabled:opacity-50",children:"Verify & Enable"})]}),p&&y.jsx("p",{className:"text-red-400 text-sm mt-2",children:p})]})]})]})]}),m&&y.jsxs("div",{className:"mt-6 p-4 bg-green-500/10 border border-green-500/20 rounded-lg",children:[y.jsxs("div",{className:"flex items-center gap-2 text-green-400 font-medium mb-2",children:[y.jsx(BS,{className:"w-5 h-5"}),"2FA Enabled Successfully!"]}),y.jsx("div",{className:"mb-4 text-slate-300 text-sm",children:"Please save these recovery codes in a secure place. You will need them if you lose access to your authenticator device."}),y.jsx("div",{className:"grid grid-cols-2 gap-2 font-mono text-sm bg-slate-900 p-4 rounded border border-slate-700",children:m.map(O=>y.jsx("div",{className:"text-slate-300 select-all",children:O},O))}),y.jsx("button",{onClick:()=>d(null),className:"mt-4 text-sm text-slate-400 hover:text-white underline",children:"I have saved these codes"})]})]})]})]})]})}function Q9(){const{isAuthenticated:e,logout:t}=nl(),[i,l]=C.useState(null),[n,o]=C.useState(!1),[s,f]=C.useState(!0),m=er(),d=wo(),[p]=C.useState(()=>m.pathname+m.search);if(C.useEffect(()=>{wC().then(({authRequired:b,setupRequired:x})=>{l(b),o(x),f(!1)})},[]),s)return y.jsx("div",{className:"min-h-screen flex items-center justify-center bg-gradient-to-br from-slate-900 via-slate-800 to-slate-900",children:y.jsx("div",{className:"text-slate-400",children:"Loading..."})});if(n)return y.jsx(Y9,{onSuccess:()=>o(!1)});if(m.pathname.startsWith("/invite/"))return y.jsx(Jx,{children:y.jsx($r,{path:"/invite/:token",element:y.jsx(V9,{})})});if(i&&!e)return y.jsx(G9,{onSuccess:()=>d(p||"/",{replace:!0})});const v=[{path:"/",label:"Dashboard",icon:H6},{path:"/repositories",label:"Repositories",icon:Ii},{path:"/tokens",label:"Access Tokens",icon:kp},{path:"/packages",label:"Packages",icon:HS},{path:"/users",label:"Users",icon:Yh}];return y.jsxs("div",{className:"min-h-screen overflow-x-hidden",children:[y.jsx("header",{className:"bg-slate-900/90 backdrop-blur-sm border-b border-slate-800 sticky top-0 z-50",children:y.jsx("div",{className:"max-w-7xl mx-auto px-4 sm:px-6 lg:px-8",children:y.jsxs("div",{className:"flex items-center justify-between h-16",children:[y.jsxs(Za,{to:"/",className:"flex items-center gap-3 hover:opacity-80 transition-opacity",children:[y.jsx("div",{className:"w-10 h-10 bg-gradient-to-br from-primary-500 to-accent-600 rounded-lg flex items-center justify-center",children:y.jsx(Ii,{className:"w-6 h-6 text-white"})}),y.jsxs("div",{children:[y.jsx("h1",{className:"font-display font-bold text-lg text-slate-100",children:"PACKAGE.broker"}),y.jsx("p",{className:"text-xs text-slate-500",children:"Serverless Edition"})]})]}),y.jsxs("div",{className:"flex items-center gap-4",children:[y.jsxs("nav",{className:"flex items-center gap-1",role:"navigation","aria-label":"Main navigation",children:[v.map(b=>y.jsxs(Ph,{to:b.path,end:b.path==="/","data-testid":`nav-${b.path==="/"?"dashboard":b.path.slice(1)}`,className:({isActive:x})=>`px-4 py-2 rounded-lg font-medium text-sm transition-all duration-200 flex items-center gap-2 ${x?"bg-slate-800 text-primary-400 shadow-lg":"text-slate-400 hover:text-slate-200 hover:bg-slate-800/50"}`,children:[y.jsx(b.icon,{className:"w-5 h-5 flex-shrink-0"}),y.jsx("span",{children:b.label})]},b.path)),y.jsxs("a",{href:"https://package.broker",target:"_blank",rel:"noopener noreferrer",className:"px-4 py-2 rounded-lg font-medium text-sm text-slate-400 hover:text-slate-200 hover:bg-slate-800/50 transition-all duration-200 flex items-center gap-2","data-testid":"nav-about",children:[y.jsx(K6,{className:"w-5 h-5 flex-shrink-0"}),y.jsx("span",{children:"About"})]})]}),e&&y.jsxs("div",{className:"flex items-center gap-2 pl-2 border-l border-slate-700 ml-2",children:[y.jsx(Ph,{to:"/profile",className:({isActive:b})=>`px-3 py-2 text-sm rounded-lg transition flex items-center gap-1 ${b?"text-white bg-slate-800":"text-slate-400 hover:text-slate-200"}`,title:"Profile Settings",children:y.jsx(Yh,{className:"w-4 h-4"})}),y.jsx("button",{onClick:t,className:"px-3 py-2 text-sm text-slate-400 hover:text-red-400 transition flex items-center gap-1",title:"Sign out","aria-label":"Sign out","data-testid":"logout-button",children:y.jsx(tC,{className:"w-4 h-4"})})]})]})]})})}),y.jsx("main",{className:"max-w-7xl mx-auto px-4 sm:px-6 lg:px-8 py-8",children:y.jsxs(Jx,{children:[y.jsx($r,{path:"/",element:y.jsx(QC,{})}),y.jsx($r,{path:"/repositories",element:y.jsx(AI,{})}),y.jsx($r,{path:"/tokens",element:y.jsx(LI,{})}),y.jsx($r,{path:"/packages",element:y.jsx(gU,{})}),y.jsx($r,{path:"/packages/:vendor/:package",element:y.jsx(H9,{})}),y.jsx($r,{path:"/users",element:y.jsx(J9,{})}),y.jsx($r,{path:"/profile",element:y.jsx(X9,{})})]})}),y.jsx("footer",{className:"border-t border-slate-800 mt-16 py-8",children:y.jsx("div",{className:"max-w-7xl mx-auto px-4 sm:px-6 lg:px-8",children:y.jsxs("div",{className:"flex flex-col md:flex-row items-center justify-between gap-4",children:[y.jsxs("div",{className:"text-center md:text-left",children:[y.jsx("p",{className:"text-slate-300 font-medium mb-1",children:"PACKAGE.broker"}),y.jsx("p",{className:"text-slate-500 text-sm",children:"A lightweight, self-hosted Composer proxy running on Cloudflare's edge network"})]}),y.jsxs("div",{className:"flex flex-col items-center md:items-end gap-2",children:[y.jsxs("div",{className:"flex items-center gap-4 text-sm",children:[y.jsx("a",{href:"https://github.com/package-broker/server",target:"_blank",rel:"noopener noreferrer",className:"text-slate-400 hover:text-slate-200 transition",children:"GitHub"}),y.jsxs("a",{href:"https://github.com/sponsors/lbajsarowicz",target:"_blank",rel:"noopener noreferrer",className:"text-pink-400 hover:text-pink-300 transition flex items-center gap-1",children:[y.jsx(Vh,{className:"w-4 h-4 fill-current"}),"Sponsor"]})]}),y.jsxs("p",{className:"text-slate-500 text-xs",children:["© ",new Date().getFullYear()," Łukasz Bajsarowicz • Licensed under AGPL-3.0"]})]})]})})})]})}function K9(){return y.jsx(DI,{children:y.jsx(Q9,{})})}const W9=new E6({defaultOptions:{queries:{staleTime:1e3*60,refetchOnWindowFocus:!1}}});EO.createRoot(document.getElementById("root")).render(y.jsx(yO.StrictMode,{children:y.jsx(VT,{children:y.jsx(j6,{client:W9,children:y.jsx(K9,{})})})}));
|