@iconoma/studio 0.0.6 → 0.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/api/index.d.ts.map +1 -1
- package/dist/api/index.js +11 -4
- package/dist/api/target-clients/react-native.js +2 -2
- package/dist/api/target-clients/react.js +3 -3
- package/dist/api/types.d.ts +1 -0
- package/dist/api/types.d.ts.map +1 -1
- package/dist/api/utils.d.ts +2 -1
- package/dist/api/utils.d.ts.map +1 -1
- package/dist/api/utils.js +9 -1
- package/dist/client/assets/{base-80a1f760-BT0jtgRF.js → base-80a1f760-Dmh1zEm4.js} +1 -1
- package/dist/client/assets/{consoleHook-59e792cb-Cx_lbHFa.js → consoleHook-59e792cb-BPY7C9Z6.js} +1 -1
- package/dist/client/assets/{index-599aeaf7-CQg58cdW.js → index-599aeaf7-DZk7eK7p.js} +1 -1
- package/dist/client/assets/index-6Qr3P4GY.js +800 -0
- package/dist/client/assets/index-D0bEDwlV.css +1 -0
- package/dist/client/assets/{index-CbKTZMip.js → index-De8hZx0A.js} +1 -1
- package/dist/client/assets/{index-D98HewIt.js → index-lohWKmM3.js} +1 -1
- package/dist/client/index.html +2 -2
- package/dist/server/entry-server.js +95 -21
- package/package.json +1 -1
- package/dist/client/assets/index-7c_AX7XK.js +0 -800
- package/dist/client/assets/index-Bdj-eDET.css +0 -1
|
@@ -1,800 +0,0 @@
|
|
|
1
|
-
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/index-D98HewIt.js","assets/base-80a1f760-BT0jtgRF.js","assets/consoleHook-59e792cb-Cx_lbHFa.js","assets/index-599aeaf7-CQg58cdW.js","assets/index-CbKTZMip.js"])))=>i.map(i=>d[i]);
|
|
2
|
-
function vz(t,e){for(var n=0;n<e.length;n++){const r=e[n];if(typeof r!="string"&&!Array.isArray(r)){for(const i in r)if(i!=="default"&&!(i in t)){const a=Object.getOwnPropertyDescriptor(r,i);a&&Object.defineProperty(t,i,a.get?a:{enumerable:!0,get:()=>r[i]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}(function(){const e=document.createElement("link").relList;if(e&&e.supports&&e.supports("modulepreload"))return;for(const i of document.querySelectorAll('link[rel="modulepreload"]'))r(i);new MutationObserver(i=>{for(const a of i)if(a.type==="childList")for(const o of a.addedNodes)o.tagName==="LINK"&&o.rel==="modulepreload"&&r(o)}).observe(document,{childList:!0,subtree:!0});function n(i){const a={};return i.integrity&&(a.integrity=i.integrity),i.referrerPolicy&&(a.referrerPolicy=i.referrerPolicy),i.crossOrigin==="use-credentials"?a.credentials="include":i.crossOrigin==="anonymous"?a.credentials="omit":a.credentials="same-origin",a}function r(i){if(i.ep)return;i.ep=!0;const a=n(i);fetch(i.href,a)}})();function Nc(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var zv={exports:{}},zu={};var BC;function yz(){if(BC)return zu;BC=1;var t=Symbol.for("react.transitional.element"),e=Symbol.for("react.fragment");function n(r,i,a){var o=null;if(a!==void 0&&(o=""+a),i.key!==void 0&&(o=""+i.key),"key"in i){a={};for(var c in i)c!=="key"&&(a[c]=i[c])}else a=i;return i=a.ref,{$$typeof:t,type:r,key:o,ref:i!==void 0?i:null,props:a}}return zu.Fragment=e,zu.jsx=n,zu.jsxs=n,zu}var IC;function bz(){return IC||(IC=1,zv.exports=yz()),zv.exports}var v=bz(),Lv={exports:{}},nt={};var qC;function xz(){if(qC)return nt;qC=1;var t=Symbol.for("react.transitional.element"),e=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),r=Symbol.for("react.strict_mode"),i=Symbol.for("react.profiler"),a=Symbol.for("react.consumer"),o=Symbol.for("react.context"),c=Symbol.for("react.forward_ref"),u=Symbol.for("react.suspense"),f=Symbol.for("react.memo"),h=Symbol.for("react.lazy"),m=Symbol.for("react.activity"),g=Symbol.iterator;function y(A){return A===null||typeof A!="object"?null:(A=g&&A[g]||A["@@iterator"],typeof A=="function"?A:null)}var x={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},S=Object.assign,k={};function T(A,N,L){this.props=A,this.context=N,this.refs=k,this.updater=L||x}T.prototype.isReactComponent={},T.prototype.setState=function(A,N){if(typeof A!="object"&&typeof A!="function"&&A!=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,A,N,"setState")},T.prototype.forceUpdate=function(A){this.updater.enqueueForceUpdate(this,A,"forceUpdate")};function C(){}C.prototype=T.prototype;function E(A,N,L){this.props=A,this.context=N,this.refs=k,this.updater=L||x}var R=E.prototype=new C;R.constructor=E,S(R,T.prototype),R.isPureReactComponent=!0;var $=Array.isArray;function P(){}var _={H:null,A:null,T:null,S:null},M=Object.prototype.hasOwnProperty;function V(A,N,L){var q=L.ref;return{$$typeof:t,type:A,key:N,ref:q!==void 0?q:null,props:L}}function F(A,N){return V(A.type,N,A.props)}function W(A){return typeof A=="object"&&A!==null&&A.$$typeof===t}function I(A){var N={"=":"=0",":":"=2"};return"$"+A.replace(/[=:]/g,function(L){return N[L]})}var ne=/\/+/g;function ee(A,N){return typeof A=="object"&&A!==null&&A.key!=null?I(""+A.key):N.toString(36)}function pe(A){switch(A.status){case"fulfilled":return A.value;case"rejected":throw A.reason;default:switch(typeof A.status=="string"?A.then(P,P):(A.status="pending",A.then(function(N){A.status==="pending"&&(A.status="fulfilled",A.value=N)},function(N){A.status==="pending"&&(A.status="rejected",A.reason=N)})),A.status){case"fulfilled":return A.value;case"rejected":throw A.reason}}throw A}function D(A,N,L,q,se){var he=typeof A;(he==="undefined"||he==="boolean")&&(A=null);var H=!1;if(A===null)H=!0;else switch(he){case"bigint":case"string":case"number":H=!0;break;case"object":switch(A.$$typeof){case t:case e:H=!0;break;case h:return H=A._init,D(H(A._payload),N,L,q,se)}}if(H)return se=se(A),H=q===""?"."+ee(A,0):q,$(se)?(L="",H!=null&&(L=H.replace(ne,"$&/")+"/"),D(se,N,L,"",function(ke){return ke})):se!=null&&(W(se)&&(se=F(se,L+(se.key==null||A&&A.key===se.key?"":(""+se.key).replace(ne,"$&/")+"/")+H)),N.push(se)),1;H=0;var ge=q===""?".":q+":";if($(A))for(var xe=0;xe<A.length;xe++)q=A[xe],he=ge+ee(q,xe),H+=D(q,N,L,he,se);else if(xe=y(A),typeof xe=="function")for(A=xe.call(A),xe=0;!(q=A.next()).done;)q=q.value,he=ge+ee(q,xe++),H+=D(q,N,L,he,se);else if(he==="object"){if(typeof A.then=="function")return D(pe(A),N,L,q,se);throw N=String(A),Error("Objects are not valid as a React child (found: "+(N==="[object Object]"?"object with keys {"+Object.keys(A).join(", ")+"}":N)+"). If you meant to render a collection of children, use an array instead.")}return H}function G(A,N,L){if(A==null)return A;var q=[],se=0;return D(A,q,"","",function(he){return N.call(L,he,se++)}),q}function B(A){if(A._status===-1){var N=A._result;N=N(),N.then(function(L){(A._status===0||A._status===-1)&&(A._status=1,A._result=L)},function(L){(A._status===0||A._status===-1)&&(A._status=2,A._result=L)}),A._status===-1&&(A._status=0,A._result=N)}if(A._status===1)return A._result.default;throw A._result}var ye=typeof reportError=="function"?reportError:function(A){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var N=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof A=="object"&&A!==null&&typeof A.message=="string"?String(A.message):String(A),error:A});if(!window.dispatchEvent(N))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",A);return}console.error(A)},X={map:G,forEach:function(A,N,L){G(A,function(){N.apply(this,arguments)},L)},count:function(A){var N=0;return G(A,function(){N++}),N},toArray:function(A){return G(A,function(N){return N})||[]},only:function(A){if(!W(A))throw Error("React.Children.only expected to receive a single React element child.");return A}};return nt.Activity=m,nt.Children=X,nt.Component=T,nt.Fragment=n,nt.Profiler=i,nt.PureComponent=E,nt.StrictMode=r,nt.Suspense=u,nt.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=_,nt.__COMPILER_RUNTIME={__proto__:null,c:function(A){return _.H.useMemoCache(A)}},nt.cache=function(A){return function(){return A.apply(null,arguments)}},nt.cacheSignal=function(){return null},nt.cloneElement=function(A,N,L){if(A==null)throw Error("The argument must be a React element, but you passed "+A+".");var q=S({},A.props),se=A.key;if(N!=null)for(he in N.key!==void 0&&(se=""+N.key),N)!M.call(N,he)||he==="key"||he==="__self"||he==="__source"||he==="ref"&&N.ref===void 0||(q[he]=N[he]);var he=arguments.length-2;if(he===1)q.children=L;else if(1<he){for(var H=Array(he),ge=0;ge<he;ge++)H[ge]=arguments[ge+2];q.children=H}return V(A.type,se,q)},nt.createContext=function(A){return A={$$typeof:o,_currentValue:A,_currentValue2:A,_threadCount:0,Provider:null,Consumer:null},A.Provider=A,A.Consumer={$$typeof:a,_context:A},A},nt.createElement=function(A,N,L){var q,se={},he=null;if(N!=null)for(q in N.key!==void 0&&(he=""+N.key),N)M.call(N,q)&&q!=="key"&&q!=="__self"&&q!=="__source"&&(se[q]=N[q]);var H=arguments.length-2;if(H===1)se.children=L;else if(1<H){for(var ge=Array(H),xe=0;xe<H;xe++)ge[xe]=arguments[xe+2];se.children=ge}if(A&&A.defaultProps)for(q in H=A.defaultProps,H)se[q]===void 0&&(se[q]=H[q]);return V(A,he,se)},nt.createRef=function(){return{current:null}},nt.forwardRef=function(A){return{$$typeof:c,render:A}},nt.isValidElement=W,nt.lazy=function(A){return{$$typeof:h,_payload:{_status:-1,_result:A},_init:B}},nt.memo=function(A,N){return{$$typeof:f,type:A,compare:N===void 0?null:N}},nt.startTransition=function(A){var N=_.T,L={};_.T=L;try{var q=A(),se=_.S;se!==null&&se(L,q),typeof q=="object"&&q!==null&&typeof q.then=="function"&&q.then(P,ye)}catch(he){ye(he)}finally{N!==null&&L.types!==null&&(N.types=L.types),_.T=N}},nt.unstable_useCacheRefresh=function(){return _.H.useCacheRefresh()},nt.use=function(A){return _.H.use(A)},nt.useActionState=function(A,N,L){return _.H.useActionState(A,N,L)},nt.useCallback=function(A,N){return _.H.useCallback(A,N)},nt.useContext=function(A){return _.H.useContext(A)},nt.useDebugValue=function(){},nt.useDeferredValue=function(A,N){return _.H.useDeferredValue(A,N)},nt.useEffect=function(A,N){return _.H.useEffect(A,N)},nt.useEffectEvent=function(A){return _.H.useEffectEvent(A)},nt.useId=function(){return _.H.useId()},nt.useImperativeHandle=function(A,N,L){return _.H.useImperativeHandle(A,N,L)},nt.useInsertionEffect=function(A,N){return _.H.useInsertionEffect(A,N)},nt.useLayoutEffect=function(A,N){return _.H.useLayoutEffect(A,N)},nt.useMemo=function(A,N){return _.H.useMemo(A,N)},nt.useOptimistic=function(A,N){return _.H.useOptimistic(A,N)},nt.useReducer=function(A,N,L){return _.H.useReducer(A,N,L)},nt.useRef=function(A){return _.H.useRef(A)},nt.useState=function(A){return _.H.useState(A)},nt.useSyncExternalStore=function(A,N,L){return _.H.useSyncExternalStore(A,N,L)},nt.useTransition=function(){return _.H.useTransition()},nt.version="19.2.3",nt}var UC;function nx(){return UC||(UC=1,Lv.exports=xz()),Lv.exports}var w=nx();const le=Nc(w),rx=vz({__proto__:null,default:le},[w]);var Zv={exports:{}},Lu={},Vv={exports:{}},Xv={};var YC;function Sz(){return YC||(YC=1,(function(t){function e(D,G){var B=D.length;D.push(G);e:for(;0<B;){var ye=B-1>>>1,X=D[ye];if(0<i(X,G))D[ye]=G,D[B]=X,B=ye;else break e}}function n(D){return D.length===0?null:D[0]}function r(D){if(D.length===0)return null;var G=D[0],B=D.pop();if(B!==G){D[0]=B;e:for(var ye=0,X=D.length,A=X>>>1;ye<A;){var N=2*(ye+1)-1,L=D[N],q=N+1,se=D[q];if(0>i(L,B))q<X&&0>i(se,L)?(D[ye]=se,D[q]=B,ye=q):(D[ye]=L,D[N]=B,ye=N);else if(q<X&&0>i(se,B))D[ye]=se,D[q]=B,ye=q;else break e}}return G}function i(D,G){var B=D.sortIndex-G.sortIndex;return B!==0?B:D.id-G.id}if(t.unstable_now=void 0,typeof performance=="object"&&typeof performance.now=="function"){var a=performance;t.unstable_now=function(){return a.now()}}else{var o=Date,c=o.now();t.unstable_now=function(){return o.now()-c}}var u=[],f=[],h=1,m=null,g=3,y=!1,x=!1,S=!1,k=!1,T=typeof setTimeout=="function"?setTimeout:null,C=typeof clearTimeout=="function"?clearTimeout:null,E=typeof setImmediate<"u"?setImmediate:null;function R(D){for(var G=n(f);G!==null;){if(G.callback===null)r(f);else if(G.startTime<=D)r(f),G.sortIndex=G.expirationTime,e(u,G);else break;G=n(f)}}function $(D){if(S=!1,R(D),!x)if(n(u)!==null)x=!0,P||(P=!0,I());else{var G=n(f);G!==null&&pe($,G.startTime-D)}}var P=!1,_=-1,M=5,V=-1;function F(){return k?!0:!(t.unstable_now()-V<M)}function W(){if(k=!1,P){var D=t.unstable_now();V=D;var G=!0;try{e:{x=!1,S&&(S=!1,C(_),_=-1),y=!0;var B=g;try{t:{for(R(D),m=n(u);m!==null&&!(m.expirationTime>D&&F());){var ye=m.callback;if(typeof ye=="function"){m.callback=null,g=m.priorityLevel;var X=ye(m.expirationTime<=D);if(D=t.unstable_now(),typeof X=="function"){m.callback=X,R(D),G=!0;break t}m===n(u)&&r(u),R(D)}else r(u);m=n(u)}if(m!==null)G=!0;else{var A=n(f);A!==null&&pe($,A.startTime-D),G=!1}}break e}finally{m=null,g=B,y=!1}G=void 0}}finally{G?I():P=!1}}}var I;if(typeof E=="function")I=function(){E(W)};else if(typeof MessageChannel<"u"){var ne=new MessageChannel,ee=ne.port2;ne.port1.onmessage=W,I=function(){ee.postMessage(null)}}else I=function(){T(W,0)};function pe(D,G){_=T(function(){D(t.unstable_now())},G)}t.unstable_IdlePriority=5,t.unstable_ImmediatePriority=1,t.unstable_LowPriority=4,t.unstable_NormalPriority=3,t.unstable_Profiling=null,t.unstable_UserBlockingPriority=2,t.unstable_cancelCallback=function(D){D.callback=null},t.unstable_forceFrameRate=function(D){0>D||125<D?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):M=0<D?Math.floor(1e3/D):5},t.unstable_getCurrentPriorityLevel=function(){return g},t.unstable_next=function(D){switch(g){case 1:case 2:case 3:var G=3;break;default:G=g}var B=g;g=G;try{return D()}finally{g=B}},t.unstable_requestPaint=function(){k=!0},t.unstable_runWithPriority=function(D,G){switch(D){case 1:case 2:case 3:case 4:case 5:break;default:D=3}var B=g;g=D;try{return G()}finally{g=B}},t.unstable_scheduleCallback=function(D,G,B){var ye=t.unstable_now();switch(typeof B=="object"&&B!==null?(B=B.delay,B=typeof B=="number"&&0<B?ye+B:ye):B=ye,D){case 1:var X=-1;break;case 2:X=250;break;case 5:X=1073741823;break;case 4:X=1e4;break;default:X=5e3}return X=B+X,D={id:h++,callback:G,priorityLevel:D,startTime:B,expirationTime:X,sortIndex:-1},B>ye?(D.sortIndex=B,e(f,D),n(u)===null&&D===n(f)&&(S?(C(_),_=-1):S=!0,pe($,B-ye))):(D.sortIndex=X,e(u,D),x||y||(x=!0,P||(P=!0,I()))),D},t.unstable_shouldYield=F,t.unstable_wrapCallback=function(D){var G=g;return function(){var B=g;g=G;try{return D.apply(this,arguments)}finally{g=B}}}})(Xv)),Xv}var FC;function wz(){return FC||(FC=1,Vv.exports=Sz()),Vv.exports}var Bv={exports:{}},Yn={};var WC;function kz(){if(WC)return Yn;WC=1;var t=nx();function e(u){var f="https://react.dev/errors/"+u;if(1<arguments.length){f+="?args[]="+encodeURIComponent(arguments[1]);for(var h=2;h<arguments.length;h++)f+="&args[]="+encodeURIComponent(arguments[h])}return"Minified React error #"+u+"; visit "+f+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function n(){}var r={d:{f:n,r:function(){throw Error(e(522))},D:n,C:n,L:n,m:n,X:n,S:n,M:n},p:0,findDOMNode:null},i=Symbol.for("react.portal");function a(u,f,h){var m=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:i,key:m==null?null:""+m,children:u,containerInfo:f,implementation:h}}var o=t.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function c(u,f){if(u==="font")return"";if(typeof f=="string")return f==="use-credentials"?f:""}return Yn.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=r,Yn.createPortal=function(u,f){var h=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!f||f.nodeType!==1&&f.nodeType!==9&&f.nodeType!==11)throw Error(e(299));return a(u,f,null,h)},Yn.flushSync=function(u){var f=o.T,h=r.p;try{if(o.T=null,r.p=2,u)return u()}finally{o.T=f,r.p=h,r.d.f()}},Yn.preconnect=function(u,f){typeof u=="string"&&(f?(f=f.crossOrigin,f=typeof f=="string"?f==="use-credentials"?f:"":void 0):f=null,r.d.C(u,f))},Yn.prefetchDNS=function(u){typeof u=="string"&&r.d.D(u)},Yn.preinit=function(u,f){if(typeof u=="string"&&f&&typeof f.as=="string"){var h=f.as,m=c(h,f.crossOrigin),g=typeof f.integrity=="string"?f.integrity:void 0,y=typeof f.fetchPriority=="string"?f.fetchPriority:void 0;h==="style"?r.d.S(u,typeof f.precedence=="string"?f.precedence:void 0,{crossOrigin:m,integrity:g,fetchPriority:y}):h==="script"&&r.d.X(u,{crossOrigin:m,integrity:g,fetchPriority:y,nonce:typeof f.nonce=="string"?f.nonce:void 0})}},Yn.preinitModule=function(u,f){if(typeof u=="string")if(typeof f=="object"&&f!==null){if(f.as==null||f.as==="script"){var h=c(f.as,f.crossOrigin);r.d.M(u,{crossOrigin:h,integrity:typeof f.integrity=="string"?f.integrity:void 0,nonce:typeof f.nonce=="string"?f.nonce:void 0})}}else f==null&&r.d.M(u)},Yn.preload=function(u,f){if(typeof u=="string"&&typeof f=="object"&&f!==null&&typeof f.as=="string"){var h=f.as,m=c(h,f.crossOrigin);r.d.L(u,h,{crossOrigin:m,integrity:typeof f.integrity=="string"?f.integrity:void 0,nonce:typeof f.nonce=="string"?f.nonce:void 0,type:typeof f.type=="string"?f.type:void 0,fetchPriority:typeof f.fetchPriority=="string"?f.fetchPriority:void 0,referrerPolicy:typeof f.referrerPolicy=="string"?f.referrerPolicy:void 0,imageSrcSet:typeof f.imageSrcSet=="string"?f.imageSrcSet:void 0,imageSizes:typeof f.imageSizes=="string"?f.imageSizes:void 0,media:typeof f.media=="string"?f.media:void 0})}},Yn.preloadModule=function(u,f){if(typeof u=="string")if(f){var h=c(f.as,f.crossOrigin);r.d.m(u,{as:typeof f.as=="string"&&f.as!=="script"?f.as:void 0,crossOrigin:h,integrity:typeof f.integrity=="string"?f.integrity:void 0})}else r.d.m(u)},Yn.requestFormReset=function(u){r.d.r(u)},Yn.unstable_batchedUpdates=function(u,f){return u(f)},Yn.useFormState=function(u,f,h){return o.H.useFormState(u,f,h)},Yn.useFormStatus=function(){return o.H.useHostTransitionStatus()},Yn.version="19.2.3",Yn}var GC;function _A(){if(GC)return Bv.exports;GC=1;function t(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(t)}catch(e){console.error(e)}}return t(),Bv.exports=kz(),Bv.exports}var HC;function Cz(){if(HC)return Lu;HC=1;var t=wz(),e=nx(),n=_A();function r(s){var l="https://react.dev/errors/"+s;if(1<arguments.length){l+="?args[]="+encodeURIComponent(arguments[1]);for(var d=2;d<arguments.length;d++)l+="&args[]="+encodeURIComponent(arguments[d])}return"Minified React error #"+s+"; visit "+l+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function i(s){return!(!s||s.nodeType!==1&&s.nodeType!==9&&s.nodeType!==11)}function a(s){var l=s,d=s;if(s.alternate)for(;l.return;)l=l.return;else{s=l;do l=s,(l.flags&4098)!==0&&(d=l.return),s=l.return;while(s)}return l.tag===3?d:null}function o(s){if(s.tag===13){var l=s.memoizedState;if(l===null&&(s=s.alternate,s!==null&&(l=s.memoizedState)),l!==null)return l.dehydrated}return null}function c(s){if(s.tag===31){var l=s.memoizedState;if(l===null&&(s=s.alternate,s!==null&&(l=s.memoizedState)),l!==null)return l.dehydrated}return null}function u(s){if(a(s)!==s)throw Error(r(188))}function f(s){var l=s.alternate;if(!l){if(l=a(s),l===null)throw Error(r(188));return l!==s?null:s}for(var d=s,p=l;;){var O=d.return;if(O===null)break;var b=O.alternate;if(b===null){if(p=O.return,p!==null){d=p;continue}break}if(O.child===b.child){for(b=O.child;b;){if(b===d)return u(O),s;if(b===p)return u(O),l;b=b.sibling}throw Error(r(188))}if(d.return!==p.return)d=O,p=b;else{for(var Q=!1,j=O.child;j;){if(j===d){Q=!0,d=O,p=b;break}if(j===p){Q=!0,p=O,d=b;break}j=j.sibling}if(!Q){for(j=b.child;j;){if(j===d){Q=!0,d=b,p=O;break}if(j===p){Q=!0,p=b,d=O;break}j=j.sibling}if(!Q)throw Error(r(189))}}if(d.alternate!==p)throw Error(r(190))}if(d.tag!==3)throw Error(r(188));return d.stateNode.current===d?s:l}function h(s){var l=s.tag;if(l===5||l===26||l===27||l===6)return s;for(s=s.child;s!==null;){if(l=h(s),l!==null)return l;s=s.sibling}return null}var m=Object.assign,g=Symbol.for("react.element"),y=Symbol.for("react.transitional.element"),x=Symbol.for("react.portal"),S=Symbol.for("react.fragment"),k=Symbol.for("react.strict_mode"),T=Symbol.for("react.profiler"),C=Symbol.for("react.consumer"),E=Symbol.for("react.context"),R=Symbol.for("react.forward_ref"),$=Symbol.for("react.suspense"),P=Symbol.for("react.suspense_list"),_=Symbol.for("react.memo"),M=Symbol.for("react.lazy"),V=Symbol.for("react.activity"),F=Symbol.for("react.memo_cache_sentinel"),W=Symbol.iterator;function I(s){return s===null||typeof s!="object"?null:(s=W&&s[W]||s["@@iterator"],typeof s=="function"?s:null)}var ne=Symbol.for("react.client.reference");function ee(s){if(s==null)return null;if(typeof s=="function")return s.$$typeof===ne?null:s.displayName||s.name||null;if(typeof s=="string")return s;switch(s){case S:return"Fragment";case T:return"Profiler";case k:return"StrictMode";case $:return"Suspense";case P:return"SuspenseList";case V:return"Activity"}if(typeof s=="object")switch(s.$$typeof){case x:return"Portal";case E:return s.displayName||"Context";case C:return(s._context.displayName||"Context")+".Consumer";case R:var l=s.render;return s=s.displayName,s||(s=l.displayName||l.name||"",s=s!==""?"ForwardRef("+s+")":"ForwardRef"),s;case _:return l=s.displayName||null,l!==null?l:ee(s.type)||"Memo";case M:l=s._payload,s=s._init;try{return ee(s(l))}catch{}}return null}var pe=Array.isArray,D=e.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,G=n.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,B={pending:!1,data:null,method:null,action:null},ye=[],X=-1;function A(s){return{current:s}}function N(s){0>X||(s.current=ye[X],ye[X]=null,X--)}function L(s,l){X++,ye[X]=s.current,s.current=l}var q=A(null),se=A(null),he=A(null),H=A(null);function ge(s,l){switch(L(he,l),L(se,s),L(q,null),l.nodeType){case 9:case 11:s=(s=l.documentElement)&&(s=s.namespaceURI)?fC(s):0;break;default:if(s=l.tagName,l=l.namespaceURI)l=fC(l),s=hC(l,s);else switch(s){case"svg":s=1;break;case"math":s=2;break;default:s=0}}N(q),L(q,s)}function xe(){N(q),N(se),N(he)}function ke(s){s.memoizedState!==null&&L(H,s);var l=q.current,d=hC(l,s.type);l!==d&&(L(se,s),L(q,d))}function Ce(s){se.current===s&&(N(q),N(se)),H.current===s&&(N(H),ju._currentValue=B)}var Re,We;function Pe(s){if(Re===void 0)try{throw Error()}catch(d){var l=d.stack.trim().match(/\n( *(at )?)/);Re=l&&l[1]||"",We=-1<d.stack.indexOf(`
|
|
3
|
-
at`)?" (<anonymous>)":-1<d.stack.indexOf("@")?"@unknown:0:0":""}return`
|
|
4
|
-
`+Re+s+We}var ht=!1;function Ke(s,l){if(!s||ht)return"";ht=!0;var d=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var p={DetermineComponentFrameRoot:function(){try{if(l){var be=function(){throw Error()};if(Object.defineProperty(be.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(be,[])}catch(de){var ae=de}Reflect.construct(s,[],be)}else{try{be.call()}catch(de){ae=de}s.call(be.prototype)}}else{try{throw Error()}catch(de){ae=de}(be=s())&&typeof be.catch=="function"&&be.catch(function(){})}}catch(de){if(de&&ae&&typeof de.stack=="string")return[de.stack,ae.stack]}return[null,null]}};p.DetermineComponentFrameRoot.displayName="DetermineComponentFrameRoot";var O=Object.getOwnPropertyDescriptor(p.DetermineComponentFrameRoot,"name");O&&O.configurable&&Object.defineProperty(p.DetermineComponentFrameRoot,"name",{value:"DetermineComponentFrameRoot"});var b=p.DetermineComponentFrameRoot(),Q=b[0],j=b[1];if(Q&&j){var Z=Q.split(`
|
|
5
|
-
`),ie=j.split(`
|
|
6
|
-
`);for(O=p=0;p<Z.length&&!Z[p].includes("DetermineComponentFrameRoot");)p++;for(;O<ie.length&&!ie[O].includes("DetermineComponentFrameRoot");)O++;if(p===Z.length||O===ie.length)for(p=Z.length-1,O=ie.length-1;1<=p&&0<=O&&Z[p]!==ie[O];)O--;for(;1<=p&&0<=O;p--,O--)if(Z[p]!==ie[O]){if(p!==1||O!==1)do if(p--,O--,0>O||Z[p]!==ie[O]){var me=`
|
|
7
|
-
`+Z[p].replace(" at new "," at ");return s.displayName&&me.includes("<anonymous>")&&(me=me.replace("<anonymous>",s.displayName)),me}while(1<=p&&0<=O);break}}}finally{ht=!1,Error.prepareStackTrace=d}return(d=s?s.displayName||s.name:"")?Pe(d):""}function tt(s,l){switch(s.tag){case 26:case 27:case 5:return Pe(s.type);case 16:return Pe("Lazy");case 13:return s.child!==l&&l!==null?Pe("Suspense Fallback"):Pe("Suspense");case 19:return Pe("SuspenseList");case 0:case 15:return Ke(s.type,!1);case 11:return Ke(s.type.render,!1);case 1:return Ke(s.type,!0);case 31:return Pe("Activity");default:return""}}function bt(s){try{var l="",d=null;do l+=tt(s,d),d=s,s=s.return;while(s);return l}catch(p){return`
|
|
8
|
-
Error generating stack: `+p.message+`
|
|
9
|
-
`+p.stack}}var Ue=Object.prototype.hasOwnProperty,Ge=t.unstable_scheduleCallback,z=t.unstable_cancelCallback,Y=t.unstable_shouldYield,oe=t.unstable_requestPaint,te=t.unstable_now,fe=t.unstable_getCurrentPriorityLevel,Oe=t.unstable_ImmediatePriority,Te=t.unstable_UserBlockingPriority,Ye=t.unstable_NormalPriority,ot=t.unstable_LowPriority,kt=t.unstable_IdlePriority,Dn=t.log,Kt=t.unstable_setDisableYieldValue,er=null,Wt=null;function kn(s){if(typeof Dn=="function"&&Kt(s),Wt&&typeof Wt.setStrictMode=="function")try{Wt.setStrictMode(er,s)}catch{}}var rn=Math.clz32?Math.clz32:tr,Zi=Math.log,gi=Math.LN2;function tr(s){return s>>>=0,s===0?32:31-(Zi(s)/gi|0)|0}var tl=256,nl=262144,to=4194304;function Vi(s){var l=s&42;if(l!==0)return l;switch(s&-s){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 s&261888;case 262144:case 524288:case 1048576:case 2097152:return s&3932160;case 4194304:case 8388608:case 16777216:case 33554432:return s&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return s}}function Je(s,l,d){var p=s.pendingLanes;if(p===0)return 0;var O=0,b=s.suspendedLanes,Q=s.pingedLanes;s=s.warmLanes;var j=p&134217727;return j!==0?(p=j&~b,p!==0?O=Vi(p):(Q&=j,Q!==0?O=Vi(Q):d||(d=j&~s,d!==0&&(O=Vi(d))))):(j=p&~b,j!==0?O=Vi(j):Q!==0?O=Vi(Q):d||(d=p&~s,d!==0&&(O=Vi(d)))),O===0?0:l!==0&&l!==O&&(l&b)===0&&(b=O&-O,d=l&-l,b>=d||b===32&&(d&4194048)!==0)?l:O}function Gt(s,l){return(s.pendingLanes&~(s.suspendedLanes&~s.pingedLanes)&l)===0}function _n(s,l){switch(s){case 1:case 2:case 4:case 8:case 64:return l+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 l+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 Un(){var s=to;return to<<=1,(to&62914560)===0&&(to=4194304),s}function es(s){for(var l=[],d=0;31>d;d++)l.push(s);return l}function Jt(s,l){s.pendingLanes|=l,l!==268435456&&(s.suspendedLanes=0,s.pingedLanes=0,s.warmLanes=0)}function dr(s,l,d,p,O,b){var Q=s.pendingLanes;s.pendingLanes=d,s.suspendedLanes=0,s.pingedLanes=0,s.warmLanes=0,s.expiredLanes&=d,s.entangledLanes&=d,s.errorRecoveryDisabledLanes&=d,s.shellSuspendCounter=0;var j=s.entanglements,Z=s.expirationTimes,ie=s.hiddenUpdates;for(d=Q&~d;0<d;){var me=31-rn(d),be=1<<me;j[me]=0,Z[me]=-1;var ae=ie[me];if(ae!==null)for(ie[me]=null,me=0;me<ae.length;me++){var de=ae[me];de!==null&&(de.lane&=-536870913)}d&=~be}p!==0&&no(s,p,0),b!==0&&O===0&&s.tag!==0&&(s.suspendedLanes|=b&~(Q&~l))}function no(s,l,d){s.pendingLanes|=l,s.suspendedLanes&=~l;var p=31-rn(l);s.entangledLanes|=l,s.entanglements[p]=s.entanglements[p]|1073741824|d&261930}function fr(s,l){var d=s.entangledLanes|=l;for(s=s.entanglements;d;){var p=31-rn(d),O=1<<p;O&l|s[p]&l&&(s[p]|=l),d&=~O}}function hr(s,l){var d=l&-l;return d=(d&42)!==0?1:rl(d),(d&(s.suspendedLanes|l))!==0?0:d}function rl(s){switch(s){case 2:s=1;break;case 8:s=4;break;case 32:s=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:s=128;break;case 268435456:s=134217728;break;default:s=0}return s}function Oi(s){return s&=-s,2<s?8<s?(s&134217727)!==0?32:268435456:8:2}function Qg(){var s=G.p;return s!==0?s:(s=window.event,s===void 0?32:NC(s.type))}function K1(s,l){var d=G.p;try{return G.p=s,l()}finally{G.p=d}}var ts=Math.random().toString(36).slice(2),zn="__reactFiber$"+ts,pr="__reactProps$"+ts,il="__reactContainer$"+ts,Ag="__reactEvents$"+ts,o3="__reactListeners$"+ts,l3="__reactHandles$"+ts,J1="__reactResources$"+ts,Wc="__reactMarker$"+ts;function Rg(s){delete s[zn],delete s[pr],delete s[Ag],delete s[o3],delete s[l3]}function al(s){var l=s[zn];if(l)return l;for(var d=s.parentNode;d;){if(l=d[il]||d[zn]){if(d=l.alternate,l.child!==null||d!==null&&d.child!==null)for(s=bC(s);s!==null;){if(d=s[zn])return d;s=bC(s)}return l}s=d,d=s.parentNode}return null}function sl(s){if(s=s[zn]||s[il]){var l=s.tag;if(l===5||l===6||l===13||l===31||l===26||l===27||l===3)return s}return null}function Gc(s){var l=s.tag;if(l===5||l===26||l===27||l===6)return s.stateNode;throw Error(r(33))}function ol(s){var l=s[J1];return l||(l=s[J1]={hoistableStyles:new Map,hoistableScripts:new Map}),l}function $n(s){s[Wc]=!0}var eS=new Set,tS={};function ro(s,l){ll(s,l),ll(s+"Capture",l)}function ll(s,l){for(tS[s]=l,s=0;s<l.length;s++)eS.add(l[s])}var c3=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]*$"),nS={},rS={};function u3(s){return Ue.call(rS,s)?!0:Ue.call(nS,s)?!1:c3.test(s)?rS[s]=!0:(nS[s]=!0,!1)}function pf(s,l,d){if(u3(l))if(d===null)s.removeAttribute(l);else{switch(typeof d){case"undefined":case"function":case"symbol":s.removeAttribute(l);return;case"boolean":var p=l.toLowerCase().slice(0,5);if(p!=="data-"&&p!=="aria-"){s.removeAttribute(l);return}}s.setAttribute(l,""+d)}}function mf(s,l,d){if(d===null)s.removeAttribute(l);else{switch(typeof d){case"undefined":case"function":case"symbol":case"boolean":s.removeAttribute(l);return}s.setAttribute(l,""+d)}}function Oa(s,l,d,p){if(p===null)s.removeAttribute(d);else{switch(typeof p){case"undefined":case"function":case"symbol":case"boolean":s.removeAttribute(d);return}s.setAttributeNS(l,d,""+p)}}function Ur(s){switch(typeof s){case"bigint":case"boolean":case"number":case"string":case"undefined":return s;case"object":return s;default:return""}}function iS(s){var l=s.type;return(s=s.nodeName)&&s.toLowerCase()==="input"&&(l==="checkbox"||l==="radio")}function d3(s,l,d){var p=Object.getOwnPropertyDescriptor(s.constructor.prototype,l);if(!s.hasOwnProperty(l)&&typeof p<"u"&&typeof p.get=="function"&&typeof p.set=="function"){var O=p.get,b=p.set;return Object.defineProperty(s,l,{configurable:!0,get:function(){return O.call(this)},set:function(Q){d=""+Q,b.call(this,Q)}}),Object.defineProperty(s,l,{enumerable:p.enumerable}),{getValue:function(){return d},setValue:function(Q){d=""+Q},stopTracking:function(){s._valueTracker=null,delete s[l]}}}}function _g(s){if(!s._valueTracker){var l=iS(s)?"checked":"value";s._valueTracker=d3(s,l,""+s[l])}}function aS(s){if(!s)return!1;var l=s._valueTracker;if(!l)return!0;var d=l.getValue(),p="";return s&&(p=iS(s)?s.checked?"true":"false":s.value),s=p,s!==d?(l.setValue(s),!0):!1}function gf(s){if(s=s||(typeof document<"u"?document:void 0),typeof s>"u")return null;try{return s.activeElement||s.body}catch{return s.body}}var f3=/[\n"\\]/g;function Yr(s){return s.replace(f3,function(l){return"\\"+l.charCodeAt(0).toString(16)+" "})}function $g(s,l,d,p,O,b,Q,j){s.name="",Q!=null&&typeof Q!="function"&&typeof Q!="symbol"&&typeof Q!="boolean"?s.type=Q:s.removeAttribute("type"),l!=null?Q==="number"?(l===0&&s.value===""||s.value!=l)&&(s.value=""+Ur(l)):s.value!==""+Ur(l)&&(s.value=""+Ur(l)):Q!=="submit"&&Q!=="reset"||s.removeAttribute("value"),l!=null?Pg(s,Q,Ur(l)):d!=null?Pg(s,Q,Ur(d)):p!=null&&s.removeAttribute("value"),O==null&&b!=null&&(s.defaultChecked=!!b),O!=null&&(s.checked=O&&typeof O!="function"&&typeof O!="symbol"),j!=null&&typeof j!="function"&&typeof j!="symbol"&&typeof j!="boolean"?s.name=""+Ur(j):s.removeAttribute("name")}function sS(s,l,d,p,O,b,Q,j){if(b!=null&&typeof b!="function"&&typeof b!="symbol"&&typeof b!="boolean"&&(s.type=b),l!=null||d!=null){if(!(b!=="submit"&&b!=="reset"||l!=null)){_g(s);return}d=d!=null?""+Ur(d):"",l=l!=null?""+Ur(l):d,j||l===s.value||(s.value=l),s.defaultValue=l}p=p??O,p=typeof p!="function"&&typeof p!="symbol"&&!!p,s.checked=j?s.checked:!!p,s.defaultChecked=!!p,Q!=null&&typeof Q!="function"&&typeof Q!="symbol"&&typeof Q!="boolean"&&(s.name=Q),_g(s)}function Pg(s,l,d){l==="number"&&gf(s.ownerDocument)===s||s.defaultValue===""+d||(s.defaultValue=""+d)}function cl(s,l,d,p){if(s=s.options,l){l={};for(var O=0;O<d.length;O++)l["$"+d[O]]=!0;for(d=0;d<s.length;d++)O=l.hasOwnProperty("$"+s[d].value),s[d].selected!==O&&(s[d].selected=O),O&&p&&(s[d].defaultSelected=!0)}else{for(d=""+Ur(d),l=null,O=0;O<s.length;O++){if(s[O].value===d){s[O].selected=!0,p&&(s[O].defaultSelected=!0);return}l!==null||s[O].disabled||(l=s[O])}l!==null&&(l.selected=!0)}}function oS(s,l,d){if(l!=null&&(l=""+Ur(l),l!==s.value&&(s.value=l),d==null)){s.defaultValue!==l&&(s.defaultValue=l);return}s.defaultValue=d!=null?""+Ur(d):""}function lS(s,l,d,p){if(l==null){if(p!=null){if(d!=null)throw Error(r(92));if(pe(p)){if(1<p.length)throw Error(r(93));p=p[0]}d=p}d==null&&(d=""),l=d}d=Ur(l),s.defaultValue=d,p=s.textContent,p===d&&p!==""&&p!==null&&(s.value=p),_g(s)}function ul(s,l){if(l){var d=s.firstChild;if(d&&d===s.lastChild&&d.nodeType===3){d.nodeValue=l;return}}s.textContent=l}var h3=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 cS(s,l,d){var p=l.indexOf("--")===0;d==null||typeof d=="boolean"||d===""?p?s.setProperty(l,""):l==="float"?s.cssFloat="":s[l]="":p?s.setProperty(l,d):typeof d!="number"||d===0||h3.has(l)?l==="float"?s.cssFloat=d:s[l]=(""+d).trim():s[l]=d+"px"}function uS(s,l,d){if(l!=null&&typeof l!="object")throw Error(r(62));if(s=s.style,d!=null){for(var p in d)!d.hasOwnProperty(p)||l!=null&&l.hasOwnProperty(p)||(p.indexOf("--")===0?s.setProperty(p,""):p==="float"?s.cssFloat="":s[p]="");for(var O in l)p=l[O],l.hasOwnProperty(O)&&d[O]!==p&&cS(s,O,p)}else for(var b in l)l.hasOwnProperty(b)&&cS(s,b,l[b])}function jg(s){if(s.indexOf("-")===-1)return!1;switch(s){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 p3=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"]]),m3=/^[\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 Of(s){return m3.test(""+s)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":s}function va(){}var Mg=null;function Ng(s){return s=s.target||s.srcElement||window,s.correspondingUseElement&&(s=s.correspondingUseElement),s.nodeType===3?s.parentNode:s}var dl=null,fl=null;function dS(s){var l=sl(s);if(l&&(s=l.stateNode)){var d=s[pr]||null;e:switch(s=l.stateNode,l.type){case"input":if($g(s,d.value,d.defaultValue,d.defaultValue,d.checked,d.defaultChecked,d.type,d.name),l=d.name,d.type==="radio"&&l!=null){for(d=s;d.parentNode;)d=d.parentNode;for(d=d.querySelectorAll('input[name="'+Yr(""+l)+'"][type="radio"]'),l=0;l<d.length;l++){var p=d[l];if(p!==s&&p.form===s.form){var O=p[pr]||null;if(!O)throw Error(r(90));$g(p,O.value,O.defaultValue,O.defaultValue,O.checked,O.defaultChecked,O.type,O.name)}}for(l=0;l<d.length;l++)p=d[l],p.form===s.form&&aS(p)}break e;case"textarea":oS(s,d.value,d.defaultValue);break e;case"select":l=d.value,l!=null&&cl(s,!!d.multiple,l,!1)}}}var Dg=!1;function fS(s,l,d){if(Dg)return s(l,d);Dg=!0;try{var p=s(l);return p}finally{if(Dg=!1,(dl!==null||fl!==null)&&(ih(),dl&&(l=dl,s=fl,fl=dl=null,dS(l),s)))for(l=0;l<s.length;l++)dS(s[l])}}function Hc(s,l){var d=s.stateNode;if(d===null)return null;var p=d[pr]||null;if(p===null)return null;d=p[l];e:switch(l){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(p=!p.disabled)||(s=s.type,p=!(s==="button"||s==="input"||s==="select"||s==="textarea")),s=!p;break e;default:s=!1}if(s)return null;if(d&&typeof d!="function")throw Error(r(231,l,typeof d));return d}var ya=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),zg=!1;if(ya)try{var Kc={};Object.defineProperty(Kc,"passive",{get:function(){zg=!0}}),window.addEventListener("test",Kc,Kc),window.removeEventListener("test",Kc,Kc)}catch{zg=!1}var ns=null,Lg=null,vf=null;function hS(){if(vf)return vf;var s,l=Lg,d=l.length,p,O="value"in ns?ns.value:ns.textContent,b=O.length;for(s=0;s<d&&l[s]===O[s];s++);var Q=d-s;for(p=1;p<=Q&&l[d-p]===O[b-p];p++);return vf=O.slice(s,1<p?1-p:void 0)}function yf(s){var l=s.keyCode;return"charCode"in s?(s=s.charCode,s===0&&l===13&&(s=13)):s=l,s===10&&(s=13),32<=s||s===13?s:0}function bf(){return!0}function pS(){return!1}function mr(s){function l(d,p,O,b,Q){this._reactName=d,this._targetInst=O,this.type=p,this.nativeEvent=b,this.target=Q,this.currentTarget=null;for(var j in s)s.hasOwnProperty(j)&&(d=s[j],this[j]=d?d(b):b[j]);return this.isDefaultPrevented=(b.defaultPrevented!=null?b.defaultPrevented:b.returnValue===!1)?bf:pS,this.isPropagationStopped=pS,this}return m(l.prototype,{preventDefault:function(){this.defaultPrevented=!0;var d=this.nativeEvent;d&&(d.preventDefault?d.preventDefault():typeof d.returnValue!="unknown"&&(d.returnValue=!1),this.isDefaultPrevented=bf)},stopPropagation:function(){var d=this.nativeEvent;d&&(d.stopPropagation?d.stopPropagation():typeof d.cancelBubble!="unknown"&&(d.cancelBubble=!0),this.isPropagationStopped=bf)},persist:function(){},isPersistent:bf}),l}var io={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(s){return s.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},xf=mr(io),Jc=m({},io,{view:0,detail:0}),g3=mr(Jc),Zg,Vg,eu,Sf=m({},Jc,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:Bg,button:0,buttons:0,relatedTarget:function(s){return s.relatedTarget===void 0?s.fromElement===s.srcElement?s.toElement:s.fromElement:s.relatedTarget},movementX:function(s){return"movementX"in s?s.movementX:(s!==eu&&(eu&&s.type==="mousemove"?(Zg=s.screenX-eu.screenX,Vg=s.screenY-eu.screenY):Vg=Zg=0,eu=s),Zg)},movementY:function(s){return"movementY"in s?s.movementY:Vg}}),mS=mr(Sf),O3=m({},Sf,{dataTransfer:0}),v3=mr(O3),y3=m({},Jc,{relatedTarget:0}),Xg=mr(y3),b3=m({},io,{animationName:0,elapsedTime:0,pseudoElement:0}),x3=mr(b3),S3=m({},io,{clipboardData:function(s){return"clipboardData"in s?s.clipboardData:window.clipboardData}}),w3=mr(S3),k3=m({},io,{data:0}),gS=mr(k3),C3={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},T3={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"},E3={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function Q3(s){var l=this.nativeEvent;return l.getModifierState?l.getModifierState(s):(s=E3[s])?!!l[s]:!1}function Bg(){return Q3}var A3=m({},Jc,{key:function(s){if(s.key){var l=C3[s.key]||s.key;if(l!=="Unidentified")return l}return s.type==="keypress"?(s=yf(s),s===13?"Enter":String.fromCharCode(s)):s.type==="keydown"||s.type==="keyup"?T3[s.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:Bg,charCode:function(s){return s.type==="keypress"?yf(s):0},keyCode:function(s){return s.type==="keydown"||s.type==="keyup"?s.keyCode:0},which:function(s){return s.type==="keypress"?yf(s):s.type==="keydown"||s.type==="keyup"?s.keyCode:0}}),R3=mr(A3),_3=m({},Sf,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),OS=mr(_3),$3=m({},Jc,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:Bg}),P3=mr($3),j3=m({},io,{propertyName:0,elapsedTime:0,pseudoElement:0}),M3=mr(j3),N3=m({},Sf,{deltaX:function(s){return"deltaX"in s?s.deltaX:"wheelDeltaX"in s?-s.wheelDeltaX:0},deltaY:function(s){return"deltaY"in s?s.deltaY:"wheelDeltaY"in s?-s.wheelDeltaY:"wheelDelta"in s?-s.wheelDelta:0},deltaZ:0,deltaMode:0}),D3=mr(N3),z3=m({},io,{newState:0,oldState:0}),L3=mr(z3),Z3=[9,13,27,32],Ig=ya&&"CompositionEvent"in window,tu=null;ya&&"documentMode"in document&&(tu=document.documentMode);var V3=ya&&"TextEvent"in window&&!tu,vS=ya&&(!Ig||tu&&8<tu&&11>=tu),yS=" ",bS=!1;function xS(s,l){switch(s){case"keyup":return Z3.indexOf(l.keyCode)!==-1;case"keydown":return l.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function SS(s){return s=s.detail,typeof s=="object"&&"data"in s?s.data:null}var hl=!1;function X3(s,l){switch(s){case"compositionend":return SS(l);case"keypress":return l.which!==32?null:(bS=!0,yS);case"textInput":return s=l.data,s===yS&&bS?null:s;default:return null}}function B3(s,l){if(hl)return s==="compositionend"||!Ig&&xS(s,l)?(s=hS(),vf=Lg=ns=null,hl=!1,s):null;switch(s){case"paste":return null;case"keypress":if(!(l.ctrlKey||l.altKey||l.metaKey)||l.ctrlKey&&l.altKey){if(l.char&&1<l.char.length)return l.char;if(l.which)return String.fromCharCode(l.which)}return null;case"compositionend":return vS&&l.locale!=="ko"?null:l.data;default:return null}}var I3={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 wS(s){var l=s&&s.nodeName&&s.nodeName.toLowerCase();return l==="input"?!!I3[s.type]:l==="textarea"}function kS(s,l,d,p){dl?fl?fl.push(p):fl=[p]:dl=p,l=dh(l,"onChange"),0<l.length&&(d=new xf("onChange","change",null,d,p),s.push({event:d,listeners:l}))}var nu=null,ru=null;function q3(s){sC(s,0)}function wf(s){var l=Gc(s);if(aS(l))return s}function CS(s,l){if(s==="change")return l}var TS=!1;if(ya){var qg;if(ya){var Ug="oninput"in document;if(!Ug){var ES=document.createElement("div");ES.setAttribute("oninput","return;"),Ug=typeof ES.oninput=="function"}qg=Ug}else qg=!1;TS=qg&&(!document.documentMode||9<document.documentMode)}function QS(){nu&&(nu.detachEvent("onpropertychange",AS),ru=nu=null)}function AS(s){if(s.propertyName==="value"&&wf(ru)){var l=[];kS(l,ru,s,Ng(s)),fS(q3,l)}}function U3(s,l,d){s==="focusin"?(QS(),nu=l,ru=d,nu.attachEvent("onpropertychange",AS)):s==="focusout"&&QS()}function Y3(s){if(s==="selectionchange"||s==="keyup"||s==="keydown")return wf(ru)}function F3(s,l){if(s==="click")return wf(l)}function W3(s,l){if(s==="input"||s==="change")return wf(l)}function G3(s,l){return s===l&&(s!==0||1/s===1/l)||s!==s&&l!==l}var Rr=typeof Object.is=="function"?Object.is:G3;function iu(s,l){if(Rr(s,l))return!0;if(typeof s!="object"||s===null||typeof l!="object"||l===null)return!1;var d=Object.keys(s),p=Object.keys(l);if(d.length!==p.length)return!1;for(p=0;p<d.length;p++){var O=d[p];if(!Ue.call(l,O)||!Rr(s[O],l[O]))return!1}return!0}function RS(s){for(;s&&s.firstChild;)s=s.firstChild;return s}function _S(s,l){var d=RS(s);s=0;for(var p;d;){if(d.nodeType===3){if(p=s+d.textContent.length,s<=l&&p>=l)return{node:d,offset:l-s};s=p}e:{for(;d;){if(d.nextSibling){d=d.nextSibling;break e}d=d.parentNode}d=void 0}d=RS(d)}}function $S(s,l){return s&&l?s===l?!0:s&&s.nodeType===3?!1:l&&l.nodeType===3?$S(s,l.parentNode):"contains"in s?s.contains(l):s.compareDocumentPosition?!!(s.compareDocumentPosition(l)&16):!1:!1}function PS(s){s=s!=null&&s.ownerDocument!=null&&s.ownerDocument.defaultView!=null?s.ownerDocument.defaultView:window;for(var l=gf(s.document);l instanceof s.HTMLIFrameElement;){try{var d=typeof l.contentWindow.location.href=="string"}catch{d=!1}if(d)s=l.contentWindow;else break;l=gf(s.document)}return l}function Yg(s){var l=s&&s.nodeName&&s.nodeName.toLowerCase();return l&&(l==="input"&&(s.type==="text"||s.type==="search"||s.type==="tel"||s.type==="url"||s.type==="password")||l==="textarea"||s.contentEditable==="true")}var H3=ya&&"documentMode"in document&&11>=document.documentMode,pl=null,Fg=null,au=null,Wg=!1;function jS(s,l,d){var p=d.window===d?d.document:d.nodeType===9?d:d.ownerDocument;Wg||pl==null||pl!==gf(p)||(p=pl,"selectionStart"in p&&Yg(p)?p={start:p.selectionStart,end:p.selectionEnd}:(p=(p.ownerDocument&&p.ownerDocument.defaultView||window).getSelection(),p={anchorNode:p.anchorNode,anchorOffset:p.anchorOffset,focusNode:p.focusNode,focusOffset:p.focusOffset}),au&&iu(au,p)||(au=p,p=dh(Fg,"onSelect"),0<p.length&&(l=new xf("onSelect","select",null,l,d),s.push({event:l,listeners:p}),l.target=pl)))}function ao(s,l){var d={};return d[s.toLowerCase()]=l.toLowerCase(),d["Webkit"+s]="webkit"+l,d["Moz"+s]="moz"+l,d}var ml={animationend:ao("Animation","AnimationEnd"),animationiteration:ao("Animation","AnimationIteration"),animationstart:ao("Animation","AnimationStart"),transitionrun:ao("Transition","TransitionRun"),transitionstart:ao("Transition","TransitionStart"),transitioncancel:ao("Transition","TransitionCancel"),transitionend:ao("Transition","TransitionEnd")},Gg={},MS={};ya&&(MS=document.createElement("div").style,"AnimationEvent"in window||(delete ml.animationend.animation,delete ml.animationiteration.animation,delete ml.animationstart.animation),"TransitionEvent"in window||delete ml.transitionend.transition);function so(s){if(Gg[s])return Gg[s];if(!ml[s])return s;var l=ml[s],d;for(d in l)if(l.hasOwnProperty(d)&&d in MS)return Gg[s]=l[d];return s}var NS=so("animationend"),DS=so("animationiteration"),zS=so("animationstart"),K3=so("transitionrun"),J3=so("transitionstart"),eD=so("transitioncancel"),LS=so("transitionend"),ZS=new Map,Hg="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(" ");Hg.push("scrollEnd");function vi(s,l){ZS.set(s,l),ro(l,[s])}var kf=typeof reportError=="function"?reportError:function(s){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var l=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof s=="object"&&s!==null&&typeof s.message=="string"?String(s.message):String(s),error:s});if(!window.dispatchEvent(l))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",s);return}console.error(s)},Fr=[],gl=0,Kg=0;function Cf(){for(var s=gl,l=Kg=gl=0;l<s;){var d=Fr[l];Fr[l++]=null;var p=Fr[l];Fr[l++]=null;var O=Fr[l];Fr[l++]=null;var b=Fr[l];if(Fr[l++]=null,p!==null&&O!==null){var Q=p.pending;Q===null?O.next=O:(O.next=Q.next,Q.next=O),p.pending=O}b!==0&&VS(d,O,b)}}function Tf(s,l,d,p){Fr[gl++]=s,Fr[gl++]=l,Fr[gl++]=d,Fr[gl++]=p,Kg|=p,s.lanes|=p,s=s.alternate,s!==null&&(s.lanes|=p)}function Jg(s,l,d,p){return Tf(s,l,d,p),Ef(s)}function oo(s,l){return Tf(s,null,null,l),Ef(s)}function VS(s,l,d){s.lanes|=d;var p=s.alternate;p!==null&&(p.lanes|=d);for(var O=!1,b=s.return;b!==null;)b.childLanes|=d,p=b.alternate,p!==null&&(p.childLanes|=d),b.tag===22&&(s=b.stateNode,s===null||s._visibility&1||(O=!0)),s=b,b=b.return;return s.tag===3?(b=s.stateNode,O&&l!==null&&(O=31-rn(d),s=b.hiddenUpdates,p=s[O],p===null?s[O]=[l]:p.push(l),l.lane=d|536870912),b):null}function Ef(s){if(50<Eu)throw Eu=0,lv=null,Error(r(185));for(var l=s.return;l!==null;)s=l,l=s.return;return s.tag===3?s.stateNode:null}var Ol={};function tD(s,l,d,p){this.tag=s,this.key=d,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=l,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=p,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function _r(s,l,d,p){return new tD(s,l,d,p)}function eO(s){return s=s.prototype,!(!s||!s.isReactComponent)}function ba(s,l){var d=s.alternate;return d===null?(d=_r(s.tag,l,s.key,s.mode),d.elementType=s.elementType,d.type=s.type,d.stateNode=s.stateNode,d.alternate=s,s.alternate=d):(d.pendingProps=l,d.type=s.type,d.flags=0,d.subtreeFlags=0,d.deletions=null),d.flags=s.flags&65011712,d.childLanes=s.childLanes,d.lanes=s.lanes,d.child=s.child,d.memoizedProps=s.memoizedProps,d.memoizedState=s.memoizedState,d.updateQueue=s.updateQueue,l=s.dependencies,d.dependencies=l===null?null:{lanes:l.lanes,firstContext:l.firstContext},d.sibling=s.sibling,d.index=s.index,d.ref=s.ref,d.refCleanup=s.refCleanup,d}function XS(s,l){s.flags&=65011714;var d=s.alternate;return d===null?(s.childLanes=0,s.lanes=l,s.child=null,s.subtreeFlags=0,s.memoizedProps=null,s.memoizedState=null,s.updateQueue=null,s.dependencies=null,s.stateNode=null):(s.childLanes=d.childLanes,s.lanes=d.lanes,s.child=d.child,s.subtreeFlags=0,s.deletions=null,s.memoizedProps=d.memoizedProps,s.memoizedState=d.memoizedState,s.updateQueue=d.updateQueue,s.type=d.type,l=d.dependencies,s.dependencies=l===null?null:{lanes:l.lanes,firstContext:l.firstContext}),s}function Qf(s,l,d,p,O,b){var Q=0;if(p=s,typeof s=="function")eO(s)&&(Q=1);else if(typeof s=="string")Q=sz(s,d,q.current)?26:s==="html"||s==="head"||s==="body"?27:5;else e:switch(s){case V:return s=_r(31,d,l,O),s.elementType=V,s.lanes=b,s;case S:return lo(d.children,O,b,l);case k:Q=8,O|=24;break;case T:return s=_r(12,d,l,O|2),s.elementType=T,s.lanes=b,s;case $:return s=_r(13,d,l,O),s.elementType=$,s.lanes=b,s;case P:return s=_r(19,d,l,O),s.elementType=P,s.lanes=b,s;default:if(typeof s=="object"&&s!==null)switch(s.$$typeof){case E:Q=10;break e;case C:Q=9;break e;case R:Q=11;break e;case _:Q=14;break e;case M:Q=16,p=null;break e}Q=29,d=Error(r(130,s===null?"null":typeof s,"")),p=null}return l=_r(Q,d,l,O),l.elementType=s,l.type=p,l.lanes=b,l}function lo(s,l,d,p){return s=_r(7,s,p,l),s.lanes=d,s}function tO(s,l,d){return s=_r(6,s,null,l),s.lanes=d,s}function BS(s){var l=_r(18,null,null,0);return l.stateNode=s,l}function nO(s,l,d){return l=_r(4,s.children!==null?s.children:[],s.key,l),l.lanes=d,l.stateNode={containerInfo:s.containerInfo,pendingChildren:null,implementation:s.implementation},l}var IS=new WeakMap;function Wr(s,l){if(typeof s=="object"&&s!==null){var d=IS.get(s);return d!==void 0?d:(l={value:s,source:l,stack:bt(l)},IS.set(s,l),l)}return{value:s,source:l,stack:bt(l)}}var vl=[],yl=0,Af=null,su=0,Gr=[],Hr=0,rs=null,Xi=1,Bi="";function xa(s,l){vl[yl++]=su,vl[yl++]=Af,Af=s,su=l}function qS(s,l,d){Gr[Hr++]=Xi,Gr[Hr++]=Bi,Gr[Hr++]=rs,rs=s;var p=Xi;s=Bi;var O=32-rn(p)-1;p&=~(1<<O),d+=1;var b=32-rn(l)+O;if(30<b){var Q=O-O%5;b=(p&(1<<Q)-1).toString(32),p>>=Q,O-=Q,Xi=1<<32-rn(l)+O|d<<O|p,Bi=b+s}else Xi=1<<b|d<<O|p,Bi=s}function rO(s){s.return!==null&&(xa(s,1),qS(s,1,0))}function iO(s){for(;s===Af;)Af=vl[--yl],vl[yl]=null,su=vl[--yl],vl[yl]=null;for(;s===rs;)rs=Gr[--Hr],Gr[Hr]=null,Bi=Gr[--Hr],Gr[Hr]=null,Xi=Gr[--Hr],Gr[Hr]=null}function US(s,l){Gr[Hr++]=Xi,Gr[Hr++]=Bi,Gr[Hr++]=rs,Xi=l.id,Bi=l.overflow,rs=s}var Ln=null,Yt=null,yt=!1,is=null,Kr=!1,aO=Error(r(519));function as(s){var l=Error(r(418,1<arguments.length&&arguments[1]!==void 0&&arguments[1]?"text":"HTML",""));throw ou(Wr(l,s)),aO}function YS(s){var l=s.stateNode,d=s.type,p=s.memoizedProps;switch(l[zn]=s,l[pr]=p,d){case"dialog":gt("cancel",l),gt("close",l);break;case"iframe":case"object":case"embed":gt("load",l);break;case"video":case"audio":for(d=0;d<Au.length;d++)gt(Au[d],l);break;case"source":gt("error",l);break;case"img":case"image":case"link":gt("error",l),gt("load",l);break;case"details":gt("toggle",l);break;case"input":gt("invalid",l),sS(l,p.value,p.defaultValue,p.checked,p.defaultChecked,p.type,p.name,!0);break;case"select":gt("invalid",l);break;case"textarea":gt("invalid",l),lS(l,p.value,p.defaultValue,p.children)}d=p.children,typeof d!="string"&&typeof d!="number"&&typeof d!="bigint"||l.textContent===""+d||p.suppressHydrationWarning===!0||uC(l.textContent,d)?(p.popover!=null&&(gt("beforetoggle",l),gt("toggle",l)),p.onScroll!=null&>("scroll",l),p.onScrollEnd!=null&>("scrollend",l),p.onClick!=null&&(l.onclick=va),l=!0):l=!1,l||as(s,!0)}function FS(s){for(Ln=s.return;Ln;)switch(Ln.tag){case 5:case 31:case 13:Kr=!1;return;case 27:case 3:Kr=!0;return;default:Ln=Ln.return}}function bl(s){if(s!==Ln)return!1;if(!yt)return FS(s),yt=!0,!1;var l=s.tag,d;if((d=l!==3&&l!==27)&&((d=l===5)&&(d=s.type,d=!(d!=="form"&&d!=="button")||wv(s.type,s.memoizedProps)),d=!d),d&&Yt&&as(s),FS(s),l===13){if(s=s.memoizedState,s=s!==null?s.dehydrated:null,!s)throw Error(r(317));Yt=yC(s)}else if(l===31){if(s=s.memoizedState,s=s!==null?s.dehydrated:null,!s)throw Error(r(317));Yt=yC(s)}else l===27?(l=Yt,ys(s.type)?(s=Qv,Qv=null,Yt=s):Yt=l):Yt=Ln?ei(s.stateNode.nextSibling):null;return!0}function co(){Yt=Ln=null,yt=!1}function sO(){var s=is;return s!==null&&(yr===null?yr=s:yr.push.apply(yr,s),is=null),s}function ou(s){is===null?is=[s]:is.push(s)}var oO=A(null),uo=null,Sa=null;function ss(s,l,d){L(oO,l._currentValue),l._currentValue=d}function wa(s){s._currentValue=oO.current,N(oO)}function lO(s,l,d){for(;s!==null;){var p=s.alternate;if((s.childLanes&l)!==l?(s.childLanes|=l,p!==null&&(p.childLanes|=l)):p!==null&&(p.childLanes&l)!==l&&(p.childLanes|=l),s===d)break;s=s.return}}function cO(s,l,d,p){var O=s.child;for(O!==null&&(O.return=s);O!==null;){var b=O.dependencies;if(b!==null){var Q=O.child;b=b.firstContext;e:for(;b!==null;){var j=b;b=O;for(var Z=0;Z<l.length;Z++)if(j.context===l[Z]){b.lanes|=d,j=b.alternate,j!==null&&(j.lanes|=d),lO(b.return,d,s),p||(Q=null);break e}b=j.next}}else if(O.tag===18){if(Q=O.return,Q===null)throw Error(r(341));Q.lanes|=d,b=Q.alternate,b!==null&&(b.lanes|=d),lO(Q,d,s),Q=null}else Q=O.child;if(Q!==null)Q.return=O;else for(Q=O;Q!==null;){if(Q===s){Q=null;break}if(O=Q.sibling,O!==null){O.return=Q.return,Q=O;break}Q=Q.return}O=Q}}function xl(s,l,d,p){s=null;for(var O=l,b=!1;O!==null;){if(!b){if((O.flags&524288)!==0)b=!0;else if((O.flags&262144)!==0)break}if(O.tag===10){var Q=O.alternate;if(Q===null)throw Error(r(387));if(Q=Q.memoizedProps,Q!==null){var j=O.type;Rr(O.pendingProps.value,Q.value)||(s!==null?s.push(j):s=[j])}}else if(O===H.current){if(Q=O.alternate,Q===null)throw Error(r(387));Q.memoizedState.memoizedState!==O.memoizedState.memoizedState&&(s!==null?s.push(ju):s=[ju])}O=O.return}s!==null&&cO(l,s,d,p),l.flags|=262144}function Rf(s){for(s=s.firstContext;s!==null;){if(!Rr(s.context._currentValue,s.memoizedValue))return!0;s=s.next}return!1}function fo(s){uo=s,Sa=null,s=s.dependencies,s!==null&&(s.firstContext=null)}function Zn(s){return WS(uo,s)}function _f(s,l){return uo===null&&fo(s),WS(s,l)}function WS(s,l){var d=l._currentValue;if(l={context:l,memoizedValue:d,next:null},Sa===null){if(s===null)throw Error(r(308));Sa=l,s.dependencies={lanes:0,firstContext:l},s.flags|=524288}else Sa=Sa.next=l;return d}var nD=typeof AbortController<"u"?AbortController:function(){var s=[],l=this.signal={aborted:!1,addEventListener:function(d,p){s.push(p)}};this.abort=function(){l.aborted=!0,s.forEach(function(d){return d()})}},rD=t.unstable_scheduleCallback,iD=t.unstable_NormalPriority,pn={$$typeof:E,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function uO(){return{controller:new nD,data:new Map,refCount:0}}function lu(s){s.refCount--,s.refCount===0&&rD(iD,function(){s.controller.abort()})}var cu=null,dO=0,Sl=0,wl=null;function aD(s,l){if(cu===null){var d=cu=[];dO=0,Sl=pv(),wl={status:"pending",value:void 0,then:function(p){d.push(p)}}}return dO++,l.then(GS,GS),l}function GS(){if(--dO===0&&cu!==null){wl!==null&&(wl.status="fulfilled");var s=cu;cu=null,Sl=0,wl=null;for(var l=0;l<s.length;l++)(0,s[l])()}}function sD(s,l){var d=[],p={status:"pending",value:null,reason:null,then:function(O){d.push(O)}};return s.then(function(){p.status="fulfilled",p.value=l;for(var O=0;O<d.length;O++)(0,d[O])(l)},function(O){for(p.status="rejected",p.reason=O,O=0;O<d.length;O++)(0,d[O])(void 0)}),p}var HS=D.S;D.S=function(s,l){jk=te(),typeof l=="object"&&l!==null&&typeof l.then=="function"&&aD(s,l),HS!==null&&HS(s,l)};var ho=A(null);function fO(){var s=ho.current;return s!==null?s:Xt.pooledCache}function $f(s,l){l===null?L(ho,ho.current):L(ho,l.pool)}function KS(){var s=fO();return s===null?null:{parent:pn._currentValue,pool:s}}var kl=Error(r(460)),hO=Error(r(474)),Pf=Error(r(542)),jf={then:function(){}};function JS(s){return s=s.status,s==="fulfilled"||s==="rejected"}function ew(s,l,d){switch(d=s[d],d===void 0?s.push(l):d!==l&&(l.then(va,va),l=d),l.status){case"fulfilled":return l.value;case"rejected":throw s=l.reason,nw(s),s;default:if(typeof l.status=="string")l.then(va,va);else{if(s=Xt,s!==null&&100<s.shellSuspendCounter)throw Error(r(482));s=l,s.status="pending",s.then(function(p){if(l.status==="pending"){var O=l;O.status="fulfilled",O.value=p}},function(p){if(l.status==="pending"){var O=l;O.status="rejected",O.reason=p}})}switch(l.status){case"fulfilled":return l.value;case"rejected":throw s=l.reason,nw(s),s}throw mo=l,kl}}function po(s){try{var l=s._init;return l(s._payload)}catch(d){throw d!==null&&typeof d=="object"&&typeof d.then=="function"?(mo=d,kl):d}}var mo=null;function tw(){if(mo===null)throw Error(r(459));var s=mo;return mo=null,s}function nw(s){if(s===kl||s===Pf)throw Error(r(483))}var Cl=null,uu=0;function Mf(s){var l=uu;return uu+=1,Cl===null&&(Cl=[]),ew(Cl,s,l)}function du(s,l){l=l.props.ref,s.ref=l!==void 0?l:null}function Nf(s,l){throw l.$$typeof===g?Error(r(525)):(s=Object.prototype.toString.call(l),Error(r(31,s==="[object Object]"?"object with keys {"+Object.keys(l).join(", ")+"}":s)))}function rw(s){function l(K,U){if(s){var re=K.deletions;re===null?(K.deletions=[U],K.flags|=16):re.push(U)}}function d(K,U){if(!s)return null;for(;U!==null;)l(K,U),U=U.sibling;return null}function p(K){for(var U=new Map;K!==null;)K.key!==null?U.set(K.key,K):U.set(K.index,K),K=K.sibling;return U}function O(K,U){return K=ba(K,U),K.index=0,K.sibling=null,K}function b(K,U,re){return K.index=re,s?(re=K.alternate,re!==null?(re=re.index,re<U?(K.flags|=67108866,U):re):(K.flags|=67108866,U)):(K.flags|=1048576,U)}function Q(K){return s&&K.alternate===null&&(K.flags|=67108866),K}function j(K,U,re,ve){return U===null||U.tag!==6?(U=tO(re,K.mode,ve),U.return=K,U):(U=O(U,re),U.return=K,U)}function Z(K,U,re,ve){var Ie=re.type;return Ie===S?me(K,U,re.props.children,ve,re.key):U!==null&&(U.elementType===Ie||typeof Ie=="object"&&Ie!==null&&Ie.$$typeof===M&&po(Ie)===U.type)?(U=O(U,re.props),du(U,re),U.return=K,U):(U=Qf(re.type,re.key,re.props,null,K.mode,ve),du(U,re),U.return=K,U)}function ie(K,U,re,ve){return U===null||U.tag!==4||U.stateNode.containerInfo!==re.containerInfo||U.stateNode.implementation!==re.implementation?(U=nO(re,K.mode,ve),U.return=K,U):(U=O(U,re.children||[]),U.return=K,U)}function me(K,U,re,ve,Ie){return U===null||U.tag!==7?(U=lo(re,K.mode,ve,Ie),U.return=K,U):(U=O(U,re),U.return=K,U)}function be(K,U,re){if(typeof U=="string"&&U!==""||typeof U=="number"||typeof U=="bigint")return U=tO(""+U,K.mode,re),U.return=K,U;if(typeof U=="object"&&U!==null){switch(U.$$typeof){case y:return re=Qf(U.type,U.key,U.props,null,K.mode,re),du(re,U),re.return=K,re;case x:return U=nO(U,K.mode,re),U.return=K,U;case M:return U=po(U),be(K,U,re)}if(pe(U)||I(U))return U=lo(U,K.mode,re,null),U.return=K,U;if(typeof U.then=="function")return be(K,Mf(U),re);if(U.$$typeof===E)return be(K,_f(K,U),re);Nf(K,U)}return null}function ae(K,U,re,ve){var Ie=U!==null?U.key:null;if(typeof re=="string"&&re!==""||typeof re=="number"||typeof re=="bigint")return Ie!==null?null:j(K,U,""+re,ve);if(typeof re=="object"&&re!==null){switch(re.$$typeof){case y:return re.key===Ie?Z(K,U,re,ve):null;case x:return re.key===Ie?ie(K,U,re,ve):null;case M:return re=po(re),ae(K,U,re,ve)}if(pe(re)||I(re))return Ie!==null?null:me(K,U,re,ve,null);if(typeof re.then=="function")return ae(K,U,Mf(re),ve);if(re.$$typeof===E)return ae(K,U,_f(K,re),ve);Nf(K,re)}return null}function de(K,U,re,ve,Ie){if(typeof ve=="string"&&ve!==""||typeof ve=="number"||typeof ve=="bigint")return K=K.get(re)||null,j(U,K,""+ve,Ie);if(typeof ve=="object"&&ve!==null){switch(ve.$$typeof){case y:return K=K.get(ve.key===null?re:ve.key)||null,Z(U,K,ve,Ie);case x:return K=K.get(ve.key===null?re:ve.key)||null,ie(U,K,ve,Ie);case M:return ve=po(ve),de(K,U,re,ve,Ie)}if(pe(ve)||I(ve))return K=K.get(re)||null,me(U,K,ve,Ie,null);if(typeof ve.then=="function")return de(K,U,re,Mf(ve),Ie);if(ve.$$typeof===E)return de(K,U,re,_f(U,ve),Ie);Nf(U,ve)}return null}function je(K,U,re,ve){for(var Ie=null,Ct=null,Le=U,lt=U=0,vt=null;Le!==null&<<re.length;lt++){Le.index>lt?(vt=Le,Le=null):vt=Le.sibling;var Tt=ae(K,Le,re[lt],ve);if(Tt===null){Le===null&&(Le=vt);break}s&&Le&&Tt.alternate===null&&l(K,Le),U=b(Tt,U,lt),Ct===null?Ie=Tt:Ct.sibling=Tt,Ct=Tt,Le=vt}if(lt===re.length)return d(K,Le),yt&&xa(K,lt),Ie;if(Le===null){for(;lt<re.length;lt++)Le=be(K,re[lt],ve),Le!==null&&(U=b(Le,U,lt),Ct===null?Ie=Le:Ct.sibling=Le,Ct=Le);return yt&&xa(K,lt),Ie}for(Le=p(Le);lt<re.length;lt++)vt=de(Le,K,lt,re[lt],ve),vt!==null&&(s&&vt.alternate!==null&&Le.delete(vt.key===null?lt:vt.key),U=b(vt,U,lt),Ct===null?Ie=vt:Ct.sibling=vt,Ct=vt);return s&&Le.forEach(function(ks){return l(K,ks)}),yt&&xa(K,lt),Ie}function Fe(K,U,re,ve){if(re==null)throw Error(r(151));for(var Ie=null,Ct=null,Le=U,lt=U=0,vt=null,Tt=re.next();Le!==null&&!Tt.done;lt++,Tt=re.next()){Le.index>lt?(vt=Le,Le=null):vt=Le.sibling;var ks=ae(K,Le,Tt.value,ve);if(ks===null){Le===null&&(Le=vt);break}s&&Le&&ks.alternate===null&&l(K,Le),U=b(ks,U,lt),Ct===null?Ie=ks:Ct.sibling=ks,Ct=ks,Le=vt}if(Tt.done)return d(K,Le),yt&&xa(K,lt),Ie;if(Le===null){for(;!Tt.done;lt++,Tt=re.next())Tt=be(K,Tt.value,ve),Tt!==null&&(U=b(Tt,U,lt),Ct===null?Ie=Tt:Ct.sibling=Tt,Ct=Tt);return yt&&xa(K,lt),Ie}for(Le=p(Le);!Tt.done;lt++,Tt=re.next())Tt=de(Le,K,lt,Tt.value,ve),Tt!==null&&(s&&Tt.alternate!==null&&Le.delete(Tt.key===null?lt:Tt.key),U=b(Tt,U,lt),Ct===null?Ie=Tt:Ct.sibling=Tt,Ct=Tt);return s&&Le.forEach(function(Oz){return l(K,Oz)}),yt&&xa(K,lt),Ie}function Lt(K,U,re,ve){if(typeof re=="object"&&re!==null&&re.type===S&&re.key===null&&(re=re.props.children),typeof re=="object"&&re!==null){switch(re.$$typeof){case y:e:{for(var Ie=re.key;U!==null;){if(U.key===Ie){if(Ie=re.type,Ie===S){if(U.tag===7){d(K,U.sibling),ve=O(U,re.props.children),ve.return=K,K=ve;break e}}else if(U.elementType===Ie||typeof Ie=="object"&&Ie!==null&&Ie.$$typeof===M&&po(Ie)===U.type){d(K,U.sibling),ve=O(U,re.props),du(ve,re),ve.return=K,K=ve;break e}d(K,U);break}else l(K,U);U=U.sibling}re.type===S?(ve=lo(re.props.children,K.mode,ve,re.key),ve.return=K,K=ve):(ve=Qf(re.type,re.key,re.props,null,K.mode,ve),du(ve,re),ve.return=K,K=ve)}return Q(K);case x:e:{for(Ie=re.key;U!==null;){if(U.key===Ie)if(U.tag===4&&U.stateNode.containerInfo===re.containerInfo&&U.stateNode.implementation===re.implementation){d(K,U.sibling),ve=O(U,re.children||[]),ve.return=K,K=ve;break e}else{d(K,U);break}else l(K,U);U=U.sibling}ve=nO(re,K.mode,ve),ve.return=K,K=ve}return Q(K);case M:return re=po(re),Lt(K,U,re,ve)}if(pe(re))return je(K,U,re,ve);if(I(re)){if(Ie=I(re),typeof Ie!="function")throw Error(r(150));return re=Ie.call(re),Fe(K,U,re,ve)}if(typeof re.then=="function")return Lt(K,U,Mf(re),ve);if(re.$$typeof===E)return Lt(K,U,_f(K,re),ve);Nf(K,re)}return typeof re=="string"&&re!==""||typeof re=="number"||typeof re=="bigint"?(re=""+re,U!==null&&U.tag===6?(d(K,U.sibling),ve=O(U,re),ve.return=K,K=ve):(d(K,U),ve=tO(re,K.mode,ve),ve.return=K,K=ve),Q(K)):d(K,U)}return function(K,U,re,ve){try{uu=0;var Ie=Lt(K,U,re,ve);return Cl=null,Ie}catch(Le){if(Le===kl||Le===Pf)throw Le;var Ct=_r(29,Le,null,K.mode);return Ct.lanes=ve,Ct.return=K,Ct}}}var go=rw(!0),iw=rw(!1),os=!1;function pO(s){s.updateQueue={baseState:s.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function mO(s,l){s=s.updateQueue,l.updateQueue===s&&(l.updateQueue={baseState:s.baseState,firstBaseUpdate:s.firstBaseUpdate,lastBaseUpdate:s.lastBaseUpdate,shared:s.shared,callbacks:null})}function ls(s){return{lane:s,tag:0,payload:null,callback:null,next:null}}function cs(s,l,d){var p=s.updateQueue;if(p===null)return null;if(p=p.shared,(Qt&2)!==0){var O=p.pending;return O===null?l.next=l:(l.next=O.next,O.next=l),p.pending=l,l=Ef(s),VS(s,null,d),l}return Tf(s,p,l,d),Ef(s)}function fu(s,l,d){if(l=l.updateQueue,l!==null&&(l=l.shared,(d&4194048)!==0)){var p=l.lanes;p&=s.pendingLanes,d|=p,l.lanes=d,fr(s,d)}}function gO(s,l){var d=s.updateQueue,p=s.alternate;if(p!==null&&(p=p.updateQueue,d===p)){var O=null,b=null;if(d=d.firstBaseUpdate,d!==null){do{var Q={lane:d.lane,tag:d.tag,payload:d.payload,callback:null,next:null};b===null?O=b=Q:b=b.next=Q,d=d.next}while(d!==null);b===null?O=b=l:b=b.next=l}else O=b=l;d={baseState:p.baseState,firstBaseUpdate:O,lastBaseUpdate:b,shared:p.shared,callbacks:p.callbacks},s.updateQueue=d;return}s=d.lastBaseUpdate,s===null?d.firstBaseUpdate=l:s.next=l,d.lastBaseUpdate=l}var OO=!1;function hu(){if(OO){var s=wl;if(s!==null)throw s}}function pu(s,l,d,p){OO=!1;var O=s.updateQueue;os=!1;var b=O.firstBaseUpdate,Q=O.lastBaseUpdate,j=O.shared.pending;if(j!==null){O.shared.pending=null;var Z=j,ie=Z.next;Z.next=null,Q===null?b=ie:Q.next=ie,Q=Z;var me=s.alternate;me!==null&&(me=me.updateQueue,j=me.lastBaseUpdate,j!==Q&&(j===null?me.firstBaseUpdate=ie:j.next=ie,me.lastBaseUpdate=Z))}if(b!==null){var be=O.baseState;Q=0,me=ie=Z=null,j=b;do{var ae=j.lane&-536870913,de=ae!==j.lane;if(de?(Ot&ae)===ae:(p&ae)===ae){ae!==0&&ae===Sl&&(OO=!0),me!==null&&(me=me.next={lane:0,tag:j.tag,payload:j.payload,callback:null,next:null});e:{var je=s,Fe=j;ae=l;var Lt=d;switch(Fe.tag){case 1:if(je=Fe.payload,typeof je=="function"){be=je.call(Lt,be,ae);break e}be=je;break e;case 3:je.flags=je.flags&-65537|128;case 0:if(je=Fe.payload,ae=typeof je=="function"?je.call(Lt,be,ae):je,ae==null)break e;be=m({},be,ae);break e;case 2:os=!0}}ae=j.callback,ae!==null&&(s.flags|=64,de&&(s.flags|=8192),de=O.callbacks,de===null?O.callbacks=[ae]:de.push(ae))}else de={lane:ae,tag:j.tag,payload:j.payload,callback:j.callback,next:null},me===null?(ie=me=de,Z=be):me=me.next=de,Q|=ae;if(j=j.next,j===null){if(j=O.shared.pending,j===null)break;de=j,j=de.next,de.next=null,O.lastBaseUpdate=de,O.shared.pending=null}}while(!0);me===null&&(Z=be),O.baseState=Z,O.firstBaseUpdate=ie,O.lastBaseUpdate=me,b===null&&(O.shared.lanes=0),ps|=Q,s.lanes=Q,s.memoizedState=be}}function aw(s,l){if(typeof s!="function")throw Error(r(191,s));s.call(l)}function sw(s,l){var d=s.callbacks;if(d!==null)for(s.callbacks=null,s=0;s<d.length;s++)aw(d[s],l)}var Tl=A(null),Df=A(0);function ow(s,l){s=$a,L(Df,s),L(Tl,l),$a=s|l.baseLanes}function vO(){L(Df,$a),L(Tl,Tl.current)}function yO(){$a=Df.current,N(Tl),N(Df)}var $r=A(null),Jr=null;function us(s){var l=s.alternate;L(ln,ln.current&1),L($r,s),Jr===null&&(l===null||Tl.current!==null||l.memoizedState!==null)&&(Jr=s)}function bO(s){L(ln,ln.current),L($r,s),Jr===null&&(Jr=s)}function lw(s){s.tag===22?(L(ln,ln.current),L($r,s),Jr===null&&(Jr=s)):ds()}function ds(){L(ln,ln.current),L($r,$r.current)}function Pr(s){N($r),Jr===s&&(Jr=null),N(ln)}var ln=A(0);function zf(s){for(var l=s;l!==null;){if(l.tag===13){var d=l.memoizedState;if(d!==null&&(d=d.dehydrated,d===null||Tv(d)||Ev(d)))return l}else if(l.tag===19&&(l.memoizedProps.revealOrder==="forwards"||l.memoizedProps.revealOrder==="backwards"||l.memoizedProps.revealOrder==="unstable_legacy-backwards"||l.memoizedProps.revealOrder==="together")){if((l.flags&128)!==0)return l}else if(l.child!==null){l.child.return=l,l=l.child;continue}if(l===s)break;for(;l.sibling===null;){if(l.return===null||l.return===s)return null;l=l.return}l.sibling.return=l.return,l=l.sibling}return null}var ka=0,at=null,Dt=null,mn=null,Lf=!1,El=!1,Oo=!1,Zf=0,mu=0,Ql=null,oD=0;function an(){throw Error(r(321))}function xO(s,l){if(l===null)return!1;for(var d=0;d<l.length&&d<s.length;d++)if(!Rr(s[d],l[d]))return!1;return!0}function SO(s,l,d,p,O,b){return ka=b,at=l,l.memoizedState=null,l.updateQueue=null,l.lanes=0,D.H=s===null||s.memoizedState===null?qw:DO,Oo=!1,b=d(p,O),Oo=!1,El&&(b=uw(l,d,p,O)),cw(s),b}function cw(s){D.H=vu;var l=Dt!==null&&Dt.next!==null;if(ka=0,mn=Dt=at=null,Lf=!1,mu=0,Ql=null,l)throw Error(r(300));s===null||gn||(s=s.dependencies,s!==null&&Rf(s)&&(gn=!0))}function uw(s,l,d,p){at=s;var O=0;do{if(El&&(Ql=null),mu=0,El=!1,25<=O)throw Error(r(301));if(O+=1,mn=Dt=null,s.updateQueue!=null){var b=s.updateQueue;b.lastEffect=null,b.events=null,b.stores=null,b.memoCache!=null&&(b.memoCache.index=0)}D.H=Uw,b=l(d,p)}while(El);return b}function lD(){var s=D.H,l=s.useState()[0];return l=typeof l.then=="function"?gu(l):l,s=s.useState()[0],(Dt!==null?Dt.memoizedState:null)!==s&&(at.flags|=1024),l}function wO(){var s=Zf!==0;return Zf=0,s}function kO(s,l,d){l.updateQueue=s.updateQueue,l.flags&=-2053,s.lanes&=~d}function CO(s){if(Lf){for(s=s.memoizedState;s!==null;){var l=s.queue;l!==null&&(l.pending=null),s=s.next}Lf=!1}ka=0,mn=Dt=at=null,El=!1,mu=Zf=0,Ql=null}function nr(){var s={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return mn===null?at.memoizedState=mn=s:mn=mn.next=s,mn}function cn(){if(Dt===null){var s=at.alternate;s=s!==null?s.memoizedState:null}else s=Dt.next;var l=mn===null?at.memoizedState:mn.next;if(l!==null)mn=l,Dt=s;else{if(s===null)throw at.alternate===null?Error(r(467)):Error(r(310));Dt=s,s={memoizedState:Dt.memoizedState,baseState:Dt.baseState,baseQueue:Dt.baseQueue,queue:Dt.queue,next:null},mn===null?at.memoizedState=mn=s:mn=mn.next=s}return mn}function Vf(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function gu(s){var l=mu;return mu+=1,Ql===null&&(Ql=[]),s=ew(Ql,s,l),l=at,(mn===null?l.memoizedState:mn.next)===null&&(l=l.alternate,D.H=l===null||l.memoizedState===null?qw:DO),s}function Xf(s){if(s!==null&&typeof s=="object"){if(typeof s.then=="function")return gu(s);if(s.$$typeof===E)return Zn(s)}throw Error(r(438,String(s)))}function TO(s){var l=null,d=at.updateQueue;if(d!==null&&(l=d.memoCache),l==null){var p=at.alternate;p!==null&&(p=p.updateQueue,p!==null&&(p=p.memoCache,p!=null&&(l={data:p.data.map(function(O){return O.slice()}),index:0})))}if(l==null&&(l={data:[],index:0}),d===null&&(d=Vf(),at.updateQueue=d),d.memoCache=l,d=l.data[l.index],d===void 0)for(d=l.data[l.index]=Array(s),p=0;p<s;p++)d[p]=F;return l.index++,d}function Ca(s,l){return typeof l=="function"?l(s):l}function Bf(s){var l=cn();return EO(l,Dt,s)}function EO(s,l,d){var p=s.queue;if(p===null)throw Error(r(311));p.lastRenderedReducer=d;var O=s.baseQueue,b=p.pending;if(b!==null){if(O!==null){var Q=O.next;O.next=b.next,b.next=Q}l.baseQueue=O=b,p.pending=null}if(b=s.baseState,O===null)s.memoizedState=b;else{l=O.next;var j=Q=null,Z=null,ie=l,me=!1;do{var be=ie.lane&-536870913;if(be!==ie.lane?(Ot&be)===be:(ka&be)===be){var ae=ie.revertLane;if(ae===0)Z!==null&&(Z=Z.next={lane:0,revertLane:0,gesture:null,action:ie.action,hasEagerState:ie.hasEagerState,eagerState:ie.eagerState,next:null}),be===Sl&&(me=!0);else if((ka&ae)===ae){ie=ie.next,ae===Sl&&(me=!0);continue}else be={lane:0,revertLane:ie.revertLane,gesture:null,action:ie.action,hasEagerState:ie.hasEagerState,eagerState:ie.eagerState,next:null},Z===null?(j=Z=be,Q=b):Z=Z.next=be,at.lanes|=ae,ps|=ae;be=ie.action,Oo&&d(b,be),b=ie.hasEagerState?ie.eagerState:d(b,be)}else ae={lane:be,revertLane:ie.revertLane,gesture:ie.gesture,action:ie.action,hasEagerState:ie.hasEagerState,eagerState:ie.eagerState,next:null},Z===null?(j=Z=ae,Q=b):Z=Z.next=ae,at.lanes|=be,ps|=be;ie=ie.next}while(ie!==null&&ie!==l);if(Z===null?Q=b:Z.next=j,!Rr(b,s.memoizedState)&&(gn=!0,me&&(d=wl,d!==null)))throw d;s.memoizedState=b,s.baseState=Q,s.baseQueue=Z,p.lastRenderedState=b}return O===null&&(p.lanes=0),[s.memoizedState,p.dispatch]}function QO(s){var l=cn(),d=l.queue;if(d===null)throw Error(r(311));d.lastRenderedReducer=s;var p=d.dispatch,O=d.pending,b=l.memoizedState;if(O!==null){d.pending=null;var Q=O=O.next;do b=s(b,Q.action),Q=Q.next;while(Q!==O);Rr(b,l.memoizedState)||(gn=!0),l.memoizedState=b,l.baseQueue===null&&(l.baseState=b),d.lastRenderedState=b}return[b,p]}function dw(s,l,d){var p=at,O=cn(),b=yt;if(b){if(d===void 0)throw Error(r(407));d=d()}else d=l();var Q=!Rr((Dt||O).memoizedState,d);if(Q&&(O.memoizedState=d,gn=!0),O=O.queue,_O(pw.bind(null,p,O,s),[s]),O.getSnapshot!==l||Q||mn!==null&&mn.memoizedState.tag&1){if(p.flags|=2048,Al(9,{destroy:void 0},hw.bind(null,p,O,d,l),null),Xt===null)throw Error(r(349));b||(ka&127)!==0||fw(p,l,d)}return d}function fw(s,l,d){s.flags|=16384,s={getSnapshot:l,value:d},l=at.updateQueue,l===null?(l=Vf(),at.updateQueue=l,l.stores=[s]):(d=l.stores,d===null?l.stores=[s]:d.push(s))}function hw(s,l,d,p){l.value=d,l.getSnapshot=p,mw(l)&&gw(s)}function pw(s,l,d){return d(function(){mw(l)&&gw(s)})}function mw(s){var l=s.getSnapshot;s=s.value;try{var d=l();return!Rr(s,d)}catch{return!0}}function gw(s){var l=oo(s,2);l!==null&&br(l,s,2)}function AO(s){var l=nr();if(typeof s=="function"){var d=s;if(s=d(),Oo){kn(!0);try{d()}finally{kn(!1)}}}return l.memoizedState=l.baseState=s,l.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Ca,lastRenderedState:s},l}function Ow(s,l,d,p){return s.baseState=d,EO(s,Dt,typeof p=="function"?p:Ca)}function cD(s,l,d,p,O){if(Uf(s))throw Error(r(485));if(s=l.action,s!==null){var b={payload:O,action:s,next:null,isTransition:!0,status:"pending",value:null,reason:null,listeners:[],then:function(Q){b.listeners.push(Q)}};D.T!==null?d(!0):b.isTransition=!1,p(b),d=l.pending,d===null?(b.next=l.pending=b,vw(l,b)):(b.next=d.next,l.pending=d.next=b)}}function vw(s,l){var d=l.action,p=l.payload,O=s.state;if(l.isTransition){var b=D.T,Q={};D.T=Q;try{var j=d(O,p),Z=D.S;Z!==null&&Z(Q,j),yw(s,l,j)}catch(ie){RO(s,l,ie)}finally{b!==null&&Q.types!==null&&(b.types=Q.types),D.T=b}}else try{b=d(O,p),yw(s,l,b)}catch(ie){RO(s,l,ie)}}function yw(s,l,d){d!==null&&typeof d=="object"&&typeof d.then=="function"?d.then(function(p){bw(s,l,p)},function(p){return RO(s,l,p)}):bw(s,l,d)}function bw(s,l,d){l.status="fulfilled",l.value=d,xw(l),s.state=d,l=s.pending,l!==null&&(d=l.next,d===l?s.pending=null:(d=d.next,l.next=d,vw(s,d)))}function RO(s,l,d){var p=s.pending;if(s.pending=null,p!==null){p=p.next;do l.status="rejected",l.reason=d,xw(l),l=l.next;while(l!==p)}s.action=null}function xw(s){s=s.listeners;for(var l=0;l<s.length;l++)(0,s[l])()}function Sw(s,l){return l}function ww(s,l){if(yt){var d=Xt.formState;if(d!==null){e:{var p=at;if(yt){if(Yt){t:{for(var O=Yt,b=Kr;O.nodeType!==8;){if(!b){O=null;break t}if(O=ei(O.nextSibling),O===null){O=null;break t}}b=O.data,O=b==="F!"||b==="F"?O:null}if(O){Yt=ei(O.nextSibling),p=O.data==="F!";break e}}as(p)}p=!1}p&&(l=d[0])}}return d=nr(),d.memoizedState=d.baseState=l,p={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Sw,lastRenderedState:l},d.queue=p,d=Xw.bind(null,at,p),p.dispatch=d,p=AO(!1),b=NO.bind(null,at,!1,p.queue),p=nr(),O={state:l,dispatch:null,action:s,pending:null},p.queue=O,d=cD.bind(null,at,O,b,d),O.dispatch=d,p.memoizedState=s,[l,d,!1]}function kw(s){var l=cn();return Cw(l,Dt,s)}function Cw(s,l,d){if(l=EO(s,l,Sw)[0],s=Bf(Ca)[0],typeof l=="object"&&l!==null&&typeof l.then=="function")try{var p=gu(l)}catch(Q){throw Q===kl?Pf:Q}else p=l;l=cn();var O=l.queue,b=O.dispatch;return d!==l.memoizedState&&(at.flags|=2048,Al(9,{destroy:void 0},uD.bind(null,O,d),null)),[p,b,s]}function uD(s,l){s.action=l}function Tw(s){var l=cn(),d=Dt;if(d!==null)return Cw(l,d,s);cn(),l=l.memoizedState,d=cn();var p=d.queue.dispatch;return d.memoizedState=s,[l,p,!1]}function Al(s,l,d,p){return s={tag:s,create:d,deps:p,inst:l,next:null},l=at.updateQueue,l===null&&(l=Vf(),at.updateQueue=l),d=l.lastEffect,d===null?l.lastEffect=s.next=s:(p=d.next,d.next=s,s.next=p,l.lastEffect=s),s}function Ew(){return cn().memoizedState}function If(s,l,d,p){var O=nr();at.flags|=s,O.memoizedState=Al(1|l,{destroy:void 0},d,p===void 0?null:p)}function qf(s,l,d,p){var O=cn();p=p===void 0?null:p;var b=O.memoizedState.inst;Dt!==null&&p!==null&&xO(p,Dt.memoizedState.deps)?O.memoizedState=Al(l,b,d,p):(at.flags|=s,O.memoizedState=Al(1|l,b,d,p))}function Qw(s,l){If(8390656,8,s,l)}function _O(s,l){qf(2048,8,s,l)}function dD(s){at.flags|=4;var l=at.updateQueue;if(l===null)l=Vf(),at.updateQueue=l,l.events=[s];else{var d=l.events;d===null?l.events=[s]:d.push(s)}}function Aw(s){var l=cn().memoizedState;return dD({ref:l,nextImpl:s}),function(){if((Qt&2)!==0)throw Error(r(440));return l.impl.apply(void 0,arguments)}}function Rw(s,l){return qf(4,2,s,l)}function _w(s,l){return qf(4,4,s,l)}function $w(s,l){if(typeof l=="function"){s=s();var d=l(s);return function(){typeof d=="function"?d():l(null)}}if(l!=null)return s=s(),l.current=s,function(){l.current=null}}function Pw(s,l,d){d=d!=null?d.concat([s]):null,qf(4,4,$w.bind(null,l,s),d)}function $O(){}function jw(s,l){var d=cn();l=l===void 0?null:l;var p=d.memoizedState;return l!==null&&xO(l,p[1])?p[0]:(d.memoizedState=[s,l],s)}function Mw(s,l){var d=cn();l=l===void 0?null:l;var p=d.memoizedState;if(l!==null&&xO(l,p[1]))return p[0];if(p=s(),Oo){kn(!0);try{s()}finally{kn(!1)}}return d.memoizedState=[p,l],p}function PO(s,l,d){return d===void 0||(ka&1073741824)!==0&&(Ot&261930)===0?s.memoizedState=l:(s.memoizedState=d,s=Nk(),at.lanes|=s,ps|=s,d)}function Nw(s,l,d,p){return Rr(d,l)?d:Tl.current!==null?(s=PO(s,d,p),Rr(s,l)||(gn=!0),s):(ka&42)===0||(ka&1073741824)!==0&&(Ot&261930)===0?(gn=!0,s.memoizedState=d):(s=Nk(),at.lanes|=s,ps|=s,l)}function Dw(s,l,d,p,O){var b=G.p;G.p=b!==0&&8>b?b:8;var Q=D.T,j={};D.T=j,NO(s,!1,l,d);try{var Z=O(),ie=D.S;if(ie!==null&&ie(j,Z),Z!==null&&typeof Z=="object"&&typeof Z.then=="function"){var me=sD(Z,p);Ou(s,l,me,Nr(s))}else Ou(s,l,p,Nr(s))}catch(be){Ou(s,l,{then:function(){},status:"rejected",reason:be},Nr())}finally{G.p=b,Q!==null&&j.types!==null&&(Q.types=j.types),D.T=Q}}function fD(){}function jO(s,l,d,p){if(s.tag!==5)throw Error(r(476));var O=zw(s).queue;Dw(s,O,l,B,d===null?fD:function(){return Lw(s),d(p)})}function zw(s){var l=s.memoizedState;if(l!==null)return l;l={memoizedState:B,baseState:B,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Ca,lastRenderedState:B},next:null};var d={};return l.next={memoizedState:d,baseState:d,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Ca,lastRenderedState:d},next:null},s.memoizedState=l,s=s.alternate,s!==null&&(s.memoizedState=l),l}function Lw(s){var l=zw(s);l.next===null&&(l=s.alternate.memoizedState),Ou(s,l.next.queue,{},Nr())}function MO(){return Zn(ju)}function Zw(){return cn().memoizedState}function Vw(){return cn().memoizedState}function hD(s){for(var l=s.return;l!==null;){switch(l.tag){case 24:case 3:var d=Nr();s=ls(d);var p=cs(l,s,d);p!==null&&(br(p,l,d),fu(p,l,d)),l={cache:uO()},s.payload=l;return}l=l.return}}function pD(s,l,d){var p=Nr();d={lane:p,revertLane:0,gesture:null,action:d,hasEagerState:!1,eagerState:null,next:null},Uf(s)?Bw(l,d):(d=Jg(s,l,d,p),d!==null&&(br(d,s,p),Iw(d,l,p)))}function Xw(s,l,d){var p=Nr();Ou(s,l,d,p)}function Ou(s,l,d,p){var O={lane:p,revertLane:0,gesture:null,action:d,hasEagerState:!1,eagerState:null,next:null};if(Uf(s))Bw(l,O);else{var b=s.alternate;if(s.lanes===0&&(b===null||b.lanes===0)&&(b=l.lastRenderedReducer,b!==null))try{var Q=l.lastRenderedState,j=b(Q,d);if(O.hasEagerState=!0,O.eagerState=j,Rr(j,Q))return Tf(s,l,O,0),Xt===null&&Cf(),!1}catch{}if(d=Jg(s,l,O,p),d!==null)return br(d,s,p),Iw(d,l,p),!0}return!1}function NO(s,l,d,p){if(p={lane:2,revertLane:pv(),gesture:null,action:p,hasEagerState:!1,eagerState:null,next:null},Uf(s)){if(l)throw Error(r(479))}else l=Jg(s,d,p,2),l!==null&&br(l,s,2)}function Uf(s){var l=s.alternate;return s===at||l!==null&&l===at}function Bw(s,l){El=Lf=!0;var d=s.pending;d===null?l.next=l:(l.next=d.next,d.next=l),s.pending=l}function Iw(s,l,d){if((d&4194048)!==0){var p=l.lanes;p&=s.pendingLanes,d|=p,l.lanes=d,fr(s,d)}}var vu={readContext:Zn,use:Xf,useCallback:an,useContext:an,useEffect:an,useImperativeHandle:an,useLayoutEffect:an,useInsertionEffect:an,useMemo:an,useReducer:an,useRef:an,useState:an,useDebugValue:an,useDeferredValue:an,useTransition:an,useSyncExternalStore:an,useId:an,useHostTransitionStatus:an,useFormState:an,useActionState:an,useOptimistic:an,useMemoCache:an,useCacheRefresh:an};vu.useEffectEvent=an;var qw={readContext:Zn,use:Xf,useCallback:function(s,l){return nr().memoizedState=[s,l===void 0?null:l],s},useContext:Zn,useEffect:Qw,useImperativeHandle:function(s,l,d){d=d!=null?d.concat([s]):null,If(4194308,4,$w.bind(null,l,s),d)},useLayoutEffect:function(s,l){return If(4194308,4,s,l)},useInsertionEffect:function(s,l){If(4,2,s,l)},useMemo:function(s,l){var d=nr();l=l===void 0?null:l;var p=s();if(Oo){kn(!0);try{s()}finally{kn(!1)}}return d.memoizedState=[p,l],p},useReducer:function(s,l,d){var p=nr();if(d!==void 0){var O=d(l);if(Oo){kn(!0);try{d(l)}finally{kn(!1)}}}else O=l;return p.memoizedState=p.baseState=O,s={pending:null,lanes:0,dispatch:null,lastRenderedReducer:s,lastRenderedState:O},p.queue=s,s=s.dispatch=pD.bind(null,at,s),[p.memoizedState,s]},useRef:function(s){var l=nr();return s={current:s},l.memoizedState=s},useState:function(s){s=AO(s);var l=s.queue,d=Xw.bind(null,at,l);return l.dispatch=d,[s.memoizedState,d]},useDebugValue:$O,useDeferredValue:function(s,l){var d=nr();return PO(d,s,l)},useTransition:function(){var s=AO(!1);return s=Dw.bind(null,at,s.queue,!0,!1),nr().memoizedState=s,[!1,s]},useSyncExternalStore:function(s,l,d){var p=at,O=nr();if(yt){if(d===void 0)throw Error(r(407));d=d()}else{if(d=l(),Xt===null)throw Error(r(349));(Ot&127)!==0||fw(p,l,d)}O.memoizedState=d;var b={value:d,getSnapshot:l};return O.queue=b,Qw(pw.bind(null,p,b,s),[s]),p.flags|=2048,Al(9,{destroy:void 0},hw.bind(null,p,b,d,l),null),d},useId:function(){var s=nr(),l=Xt.identifierPrefix;if(yt){var d=Bi,p=Xi;d=(p&~(1<<32-rn(p)-1)).toString(32)+d,l="_"+l+"R_"+d,d=Zf++,0<d&&(l+="H"+d.toString(32)),l+="_"}else d=oD++,l="_"+l+"r_"+d.toString(32)+"_";return s.memoizedState=l},useHostTransitionStatus:MO,useFormState:ww,useActionState:ww,useOptimistic:function(s){var l=nr();l.memoizedState=l.baseState=s;var d={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return l.queue=d,l=NO.bind(null,at,!0,d),d.dispatch=l,[s,l]},useMemoCache:TO,useCacheRefresh:function(){return nr().memoizedState=hD.bind(null,at)},useEffectEvent:function(s){var l=nr(),d={impl:s};return l.memoizedState=d,function(){if((Qt&2)!==0)throw Error(r(440));return d.impl.apply(void 0,arguments)}}},DO={readContext:Zn,use:Xf,useCallback:jw,useContext:Zn,useEffect:_O,useImperativeHandle:Pw,useInsertionEffect:Rw,useLayoutEffect:_w,useMemo:Mw,useReducer:Bf,useRef:Ew,useState:function(){return Bf(Ca)},useDebugValue:$O,useDeferredValue:function(s,l){var d=cn();return Nw(d,Dt.memoizedState,s,l)},useTransition:function(){var s=Bf(Ca)[0],l=cn().memoizedState;return[typeof s=="boolean"?s:gu(s),l]},useSyncExternalStore:dw,useId:Zw,useHostTransitionStatus:MO,useFormState:kw,useActionState:kw,useOptimistic:function(s,l){var d=cn();return Ow(d,Dt,s,l)},useMemoCache:TO,useCacheRefresh:Vw};DO.useEffectEvent=Aw;var Uw={readContext:Zn,use:Xf,useCallback:jw,useContext:Zn,useEffect:_O,useImperativeHandle:Pw,useInsertionEffect:Rw,useLayoutEffect:_w,useMemo:Mw,useReducer:QO,useRef:Ew,useState:function(){return QO(Ca)},useDebugValue:$O,useDeferredValue:function(s,l){var d=cn();return Dt===null?PO(d,s,l):Nw(d,Dt.memoizedState,s,l)},useTransition:function(){var s=QO(Ca)[0],l=cn().memoizedState;return[typeof s=="boolean"?s:gu(s),l]},useSyncExternalStore:dw,useId:Zw,useHostTransitionStatus:MO,useFormState:Tw,useActionState:Tw,useOptimistic:function(s,l){var d=cn();return Dt!==null?Ow(d,Dt,s,l):(d.baseState=s,[s,d.queue.dispatch])},useMemoCache:TO,useCacheRefresh:Vw};Uw.useEffectEvent=Aw;function zO(s,l,d,p){l=s.memoizedState,d=d(p,l),d=d==null?l:m({},l,d),s.memoizedState=d,s.lanes===0&&(s.updateQueue.baseState=d)}var LO={enqueueSetState:function(s,l,d){s=s._reactInternals;var p=Nr(),O=ls(p);O.payload=l,d!=null&&(O.callback=d),l=cs(s,O,p),l!==null&&(br(l,s,p),fu(l,s,p))},enqueueReplaceState:function(s,l,d){s=s._reactInternals;var p=Nr(),O=ls(p);O.tag=1,O.payload=l,d!=null&&(O.callback=d),l=cs(s,O,p),l!==null&&(br(l,s,p),fu(l,s,p))},enqueueForceUpdate:function(s,l){s=s._reactInternals;var d=Nr(),p=ls(d);p.tag=2,l!=null&&(p.callback=l),l=cs(s,p,d),l!==null&&(br(l,s,d),fu(l,s,d))}};function Yw(s,l,d,p,O,b,Q){return s=s.stateNode,typeof s.shouldComponentUpdate=="function"?s.shouldComponentUpdate(p,b,Q):l.prototype&&l.prototype.isPureReactComponent?!iu(d,p)||!iu(O,b):!0}function Fw(s,l,d,p){s=l.state,typeof l.componentWillReceiveProps=="function"&&l.componentWillReceiveProps(d,p),typeof l.UNSAFE_componentWillReceiveProps=="function"&&l.UNSAFE_componentWillReceiveProps(d,p),l.state!==s&&LO.enqueueReplaceState(l,l.state,null)}function vo(s,l){var d=l;if("ref"in l){d={};for(var p in l)p!=="ref"&&(d[p]=l[p])}if(s=s.defaultProps){d===l&&(d=m({},d));for(var O in s)d[O]===void 0&&(d[O]=s[O])}return d}function Ww(s){kf(s)}function Gw(s){console.error(s)}function Hw(s){kf(s)}function Yf(s,l){try{var d=s.onUncaughtError;d(l.value,{componentStack:l.stack})}catch(p){setTimeout(function(){throw p})}}function Kw(s,l,d){try{var p=s.onCaughtError;p(d.value,{componentStack:d.stack,errorBoundary:l.tag===1?l.stateNode:null})}catch(O){setTimeout(function(){throw O})}}function ZO(s,l,d){return d=ls(d),d.tag=3,d.payload={element:null},d.callback=function(){Yf(s,l)},d}function Jw(s){return s=ls(s),s.tag=3,s}function ek(s,l,d,p){var O=d.type.getDerivedStateFromError;if(typeof O=="function"){var b=p.value;s.payload=function(){return O(b)},s.callback=function(){Kw(l,d,p)}}var Q=d.stateNode;Q!==null&&typeof Q.componentDidCatch=="function"&&(s.callback=function(){Kw(l,d,p),typeof O!="function"&&(ms===null?ms=new Set([this]):ms.add(this));var j=p.stack;this.componentDidCatch(p.value,{componentStack:j!==null?j:""})})}function mD(s,l,d,p,O){if(d.flags|=32768,p!==null&&typeof p=="object"&&typeof p.then=="function"){if(l=d.alternate,l!==null&&xl(l,d,O,!0),d=$r.current,d!==null){switch(d.tag){case 31:case 13:return Jr===null?ah():d.alternate===null&&sn===0&&(sn=3),d.flags&=-257,d.flags|=65536,d.lanes=O,p===jf?d.flags|=16384:(l=d.updateQueue,l===null?d.updateQueue=new Set([p]):l.add(p),dv(s,p,O)),!1;case 22:return d.flags|=65536,p===jf?d.flags|=16384:(l=d.updateQueue,l===null?(l={transitions:null,markerInstances:null,retryQueue:new Set([p])},d.updateQueue=l):(d=l.retryQueue,d===null?l.retryQueue=new Set([p]):d.add(p)),dv(s,p,O)),!1}throw Error(r(435,d.tag))}return dv(s,p,O),ah(),!1}if(yt)return l=$r.current,l!==null?((l.flags&65536)===0&&(l.flags|=256),l.flags|=65536,l.lanes=O,p!==aO&&(s=Error(r(422),{cause:p}),ou(Wr(s,d)))):(p!==aO&&(l=Error(r(423),{cause:p}),ou(Wr(l,d))),s=s.current.alternate,s.flags|=65536,O&=-O,s.lanes|=O,p=Wr(p,d),O=ZO(s.stateNode,p,O),gO(s,O),sn!==4&&(sn=2)),!1;var b=Error(r(520),{cause:p});if(b=Wr(b,d),Tu===null?Tu=[b]:Tu.push(b),sn!==4&&(sn=2),l===null)return!0;p=Wr(p,d),d=l;do{switch(d.tag){case 3:return d.flags|=65536,s=O&-O,d.lanes|=s,s=ZO(d.stateNode,p,s),gO(d,s),!1;case 1:if(l=d.type,b=d.stateNode,(d.flags&128)===0&&(typeof l.getDerivedStateFromError=="function"||b!==null&&typeof b.componentDidCatch=="function"&&(ms===null||!ms.has(b))))return d.flags|=65536,O&=-O,d.lanes|=O,O=Jw(O),ek(O,s,d,p),gO(d,O),!1}d=d.return}while(d!==null);return!1}var VO=Error(r(461)),gn=!1;function Vn(s,l,d,p){l.child=s===null?iw(l,null,d,p):go(l,s.child,d,p)}function tk(s,l,d,p,O){d=d.render;var b=l.ref;if("ref"in p){var Q={};for(var j in p)j!=="ref"&&(Q[j]=p[j])}else Q=p;return fo(l),p=SO(s,l,d,Q,b,O),j=wO(),s!==null&&!gn?(kO(s,l,O),Ta(s,l,O)):(yt&&j&&rO(l),l.flags|=1,Vn(s,l,p,O),l.child)}function nk(s,l,d,p,O){if(s===null){var b=d.type;return typeof b=="function"&&!eO(b)&&b.defaultProps===void 0&&d.compare===null?(l.tag=15,l.type=b,rk(s,l,b,p,O)):(s=Qf(d.type,null,p,l,l.mode,O),s.ref=l.ref,s.return=l,l.child=s)}if(b=s.child,!WO(s,O)){var Q=b.memoizedProps;if(d=d.compare,d=d!==null?d:iu,d(Q,p)&&s.ref===l.ref)return Ta(s,l,O)}return l.flags|=1,s=ba(b,p),s.ref=l.ref,s.return=l,l.child=s}function rk(s,l,d,p,O){if(s!==null){var b=s.memoizedProps;if(iu(b,p)&&s.ref===l.ref)if(gn=!1,l.pendingProps=p=b,WO(s,O))(s.flags&131072)!==0&&(gn=!0);else return l.lanes=s.lanes,Ta(s,l,O)}return XO(s,l,d,p,O)}function ik(s,l,d,p){var O=p.children,b=s!==null?s.memoizedState:null;if(s===null&&l.stateNode===null&&(l.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),p.mode==="hidden"){if((l.flags&128)!==0){if(b=b!==null?b.baseLanes|d:d,s!==null){for(p=l.child=s.child,O=0;p!==null;)O=O|p.lanes|p.childLanes,p=p.sibling;p=O&~b}else p=0,l.child=null;return ak(s,l,b,d,p)}if((d&536870912)!==0)l.memoizedState={baseLanes:0,cachePool:null},s!==null&&$f(l,b!==null?b.cachePool:null),b!==null?ow(l,b):vO(),lw(l);else return p=l.lanes=536870912,ak(s,l,b!==null?b.baseLanes|d:d,d,p)}else b!==null?($f(l,b.cachePool),ow(l,b),ds(),l.memoizedState=null):(s!==null&&$f(l,null),vO(),ds());return Vn(s,l,O,d),l.child}function yu(s,l){return s!==null&&s.tag===22||l.stateNode!==null||(l.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),l.sibling}function ak(s,l,d,p,O){var b=fO();return b=b===null?null:{parent:pn._currentValue,pool:b},l.memoizedState={baseLanes:d,cachePool:b},s!==null&&$f(l,null),vO(),lw(l),s!==null&&xl(s,l,p,!0),l.childLanes=O,null}function Ff(s,l){return l=Gf({mode:l.mode,children:l.children},s.mode),l.ref=s.ref,s.child=l,l.return=s,l}function sk(s,l,d){return go(l,s.child,null,d),s=Ff(l,l.pendingProps),s.flags|=2,Pr(l),l.memoizedState=null,s}function gD(s,l,d){var p=l.pendingProps,O=(l.flags&128)!==0;if(l.flags&=-129,s===null){if(yt){if(p.mode==="hidden")return s=Ff(l,p),l.lanes=536870912,yu(null,s);if(bO(l),(s=Yt)?(s=vC(s,Kr),s=s!==null&&s.data==="&"?s:null,s!==null&&(l.memoizedState={dehydrated:s,treeContext:rs!==null?{id:Xi,overflow:Bi}:null,retryLane:536870912,hydrationErrors:null},d=BS(s),d.return=l,l.child=d,Ln=l,Yt=null)):s=null,s===null)throw as(l);return l.lanes=536870912,null}return Ff(l,p)}var b=s.memoizedState;if(b!==null){var Q=b.dehydrated;if(bO(l),O)if(l.flags&256)l.flags&=-257,l=sk(s,l,d);else if(l.memoizedState!==null)l.child=s.child,l.flags|=128,l=null;else throw Error(r(558));else if(gn||xl(s,l,d,!1),O=(d&s.childLanes)!==0,gn||O){if(p=Xt,p!==null&&(Q=hr(p,d),Q!==0&&Q!==b.retryLane))throw b.retryLane=Q,oo(s,Q),br(p,s,Q),VO;ah(),l=sk(s,l,d)}else s=b.treeContext,Yt=ei(Q.nextSibling),Ln=l,yt=!0,is=null,Kr=!1,s!==null&&US(l,s),l=Ff(l,p),l.flags|=4096;return l}return s=ba(s.child,{mode:p.mode,children:p.children}),s.ref=l.ref,l.child=s,s.return=l,s}function Wf(s,l){var d=l.ref;if(d===null)s!==null&&s.ref!==null&&(l.flags|=4194816);else{if(typeof d!="function"&&typeof d!="object")throw Error(r(284));(s===null||s.ref!==d)&&(l.flags|=4194816)}}function XO(s,l,d,p,O){return fo(l),d=SO(s,l,d,p,void 0,O),p=wO(),s!==null&&!gn?(kO(s,l,O),Ta(s,l,O)):(yt&&p&&rO(l),l.flags|=1,Vn(s,l,d,O),l.child)}function ok(s,l,d,p,O,b){return fo(l),l.updateQueue=null,d=uw(l,p,d,O),cw(s),p=wO(),s!==null&&!gn?(kO(s,l,b),Ta(s,l,b)):(yt&&p&&rO(l),l.flags|=1,Vn(s,l,d,b),l.child)}function lk(s,l,d,p,O){if(fo(l),l.stateNode===null){var b=Ol,Q=d.contextType;typeof Q=="object"&&Q!==null&&(b=Zn(Q)),b=new d(p,b),l.memoizedState=b.state!==null&&b.state!==void 0?b.state:null,b.updater=LO,l.stateNode=b,b._reactInternals=l,b=l.stateNode,b.props=p,b.state=l.memoizedState,b.refs={},pO(l),Q=d.contextType,b.context=typeof Q=="object"&&Q!==null?Zn(Q):Ol,b.state=l.memoizedState,Q=d.getDerivedStateFromProps,typeof Q=="function"&&(zO(l,d,Q,p),b.state=l.memoizedState),typeof d.getDerivedStateFromProps=="function"||typeof b.getSnapshotBeforeUpdate=="function"||typeof b.UNSAFE_componentWillMount!="function"&&typeof b.componentWillMount!="function"||(Q=b.state,typeof b.componentWillMount=="function"&&b.componentWillMount(),typeof b.UNSAFE_componentWillMount=="function"&&b.UNSAFE_componentWillMount(),Q!==b.state&&LO.enqueueReplaceState(b,b.state,null),pu(l,p,b,O),hu(),b.state=l.memoizedState),typeof b.componentDidMount=="function"&&(l.flags|=4194308),p=!0}else if(s===null){b=l.stateNode;var j=l.memoizedProps,Z=vo(d,j);b.props=Z;var ie=b.context,me=d.contextType;Q=Ol,typeof me=="object"&&me!==null&&(Q=Zn(me));var be=d.getDerivedStateFromProps;me=typeof be=="function"||typeof b.getSnapshotBeforeUpdate=="function",j=l.pendingProps!==j,me||typeof b.UNSAFE_componentWillReceiveProps!="function"&&typeof b.componentWillReceiveProps!="function"||(j||ie!==Q)&&Fw(l,b,p,Q),os=!1;var ae=l.memoizedState;b.state=ae,pu(l,p,b,O),hu(),ie=l.memoizedState,j||ae!==ie||os?(typeof be=="function"&&(zO(l,d,be,p),ie=l.memoizedState),(Z=os||Yw(l,d,Z,p,ae,ie,Q))?(me||typeof b.UNSAFE_componentWillMount!="function"&&typeof b.componentWillMount!="function"||(typeof b.componentWillMount=="function"&&b.componentWillMount(),typeof b.UNSAFE_componentWillMount=="function"&&b.UNSAFE_componentWillMount()),typeof b.componentDidMount=="function"&&(l.flags|=4194308)):(typeof b.componentDidMount=="function"&&(l.flags|=4194308),l.memoizedProps=p,l.memoizedState=ie),b.props=p,b.state=ie,b.context=Q,p=Z):(typeof b.componentDidMount=="function"&&(l.flags|=4194308),p=!1)}else{b=l.stateNode,mO(s,l),Q=l.memoizedProps,me=vo(d,Q),b.props=me,be=l.pendingProps,ae=b.context,ie=d.contextType,Z=Ol,typeof ie=="object"&&ie!==null&&(Z=Zn(ie)),j=d.getDerivedStateFromProps,(ie=typeof j=="function"||typeof b.getSnapshotBeforeUpdate=="function")||typeof b.UNSAFE_componentWillReceiveProps!="function"&&typeof b.componentWillReceiveProps!="function"||(Q!==be||ae!==Z)&&Fw(l,b,p,Z),os=!1,ae=l.memoizedState,b.state=ae,pu(l,p,b,O),hu();var de=l.memoizedState;Q!==be||ae!==de||os||s!==null&&s.dependencies!==null&&Rf(s.dependencies)?(typeof j=="function"&&(zO(l,d,j,p),de=l.memoizedState),(me=os||Yw(l,d,me,p,ae,de,Z)||s!==null&&s.dependencies!==null&&Rf(s.dependencies))?(ie||typeof b.UNSAFE_componentWillUpdate!="function"&&typeof b.componentWillUpdate!="function"||(typeof b.componentWillUpdate=="function"&&b.componentWillUpdate(p,de,Z),typeof b.UNSAFE_componentWillUpdate=="function"&&b.UNSAFE_componentWillUpdate(p,de,Z)),typeof b.componentDidUpdate=="function"&&(l.flags|=4),typeof b.getSnapshotBeforeUpdate=="function"&&(l.flags|=1024)):(typeof b.componentDidUpdate!="function"||Q===s.memoizedProps&&ae===s.memoizedState||(l.flags|=4),typeof b.getSnapshotBeforeUpdate!="function"||Q===s.memoizedProps&&ae===s.memoizedState||(l.flags|=1024),l.memoizedProps=p,l.memoizedState=de),b.props=p,b.state=de,b.context=Z,p=me):(typeof b.componentDidUpdate!="function"||Q===s.memoizedProps&&ae===s.memoizedState||(l.flags|=4),typeof b.getSnapshotBeforeUpdate!="function"||Q===s.memoizedProps&&ae===s.memoizedState||(l.flags|=1024),p=!1)}return b=p,Wf(s,l),p=(l.flags&128)!==0,b||p?(b=l.stateNode,d=p&&typeof d.getDerivedStateFromError!="function"?null:b.render(),l.flags|=1,s!==null&&p?(l.child=go(l,s.child,null,O),l.child=go(l,null,d,O)):Vn(s,l,d,O),l.memoizedState=b.state,s=l.child):s=Ta(s,l,O),s}function ck(s,l,d,p){return co(),l.flags|=256,Vn(s,l,d,p),l.child}var BO={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function IO(s){return{baseLanes:s,cachePool:KS()}}function qO(s,l,d){return s=s!==null?s.childLanes&~d:0,l&&(s|=Mr),s}function uk(s,l,d){var p=l.pendingProps,O=!1,b=(l.flags&128)!==0,Q;if((Q=b)||(Q=s!==null&&s.memoizedState===null?!1:(ln.current&2)!==0),Q&&(O=!0,l.flags&=-129),Q=(l.flags&32)!==0,l.flags&=-33,s===null){if(yt){if(O?us(l):ds(),(s=Yt)?(s=vC(s,Kr),s=s!==null&&s.data!=="&"?s:null,s!==null&&(l.memoizedState={dehydrated:s,treeContext:rs!==null?{id:Xi,overflow:Bi}:null,retryLane:536870912,hydrationErrors:null},d=BS(s),d.return=l,l.child=d,Ln=l,Yt=null)):s=null,s===null)throw as(l);return Ev(s)?l.lanes=32:l.lanes=536870912,null}var j=p.children;return p=p.fallback,O?(ds(),O=l.mode,j=Gf({mode:"hidden",children:j},O),p=lo(p,O,d,null),j.return=l,p.return=l,j.sibling=p,l.child=j,p=l.child,p.memoizedState=IO(d),p.childLanes=qO(s,Q,d),l.memoizedState=BO,yu(null,p)):(us(l),UO(l,j))}var Z=s.memoizedState;if(Z!==null&&(j=Z.dehydrated,j!==null)){if(b)l.flags&256?(us(l),l.flags&=-257,l=YO(s,l,d)):l.memoizedState!==null?(ds(),l.child=s.child,l.flags|=128,l=null):(ds(),j=p.fallback,O=l.mode,p=Gf({mode:"visible",children:p.children},O),j=lo(j,O,d,null),j.flags|=2,p.return=l,j.return=l,p.sibling=j,l.child=p,go(l,s.child,null,d),p=l.child,p.memoizedState=IO(d),p.childLanes=qO(s,Q,d),l.memoizedState=BO,l=yu(null,p));else if(us(l),Ev(j)){if(Q=j.nextSibling&&j.nextSibling.dataset,Q)var ie=Q.dgst;Q=ie,p=Error(r(419)),p.stack="",p.digest=Q,ou({value:p,source:null,stack:null}),l=YO(s,l,d)}else if(gn||xl(s,l,d,!1),Q=(d&s.childLanes)!==0,gn||Q){if(Q=Xt,Q!==null&&(p=hr(Q,d),p!==0&&p!==Z.retryLane))throw Z.retryLane=p,oo(s,p),br(Q,s,p),VO;Tv(j)||ah(),l=YO(s,l,d)}else Tv(j)?(l.flags|=192,l.child=s.child,l=null):(s=Z.treeContext,Yt=ei(j.nextSibling),Ln=l,yt=!0,is=null,Kr=!1,s!==null&&US(l,s),l=UO(l,p.children),l.flags|=4096);return l}return O?(ds(),j=p.fallback,O=l.mode,Z=s.child,ie=Z.sibling,p=ba(Z,{mode:"hidden",children:p.children}),p.subtreeFlags=Z.subtreeFlags&65011712,ie!==null?j=ba(ie,j):(j=lo(j,O,d,null),j.flags|=2),j.return=l,p.return=l,p.sibling=j,l.child=p,yu(null,p),p=l.child,j=s.child.memoizedState,j===null?j=IO(d):(O=j.cachePool,O!==null?(Z=pn._currentValue,O=O.parent!==Z?{parent:Z,pool:Z}:O):O=KS(),j={baseLanes:j.baseLanes|d,cachePool:O}),p.memoizedState=j,p.childLanes=qO(s,Q,d),l.memoizedState=BO,yu(s.child,p)):(us(l),d=s.child,s=d.sibling,d=ba(d,{mode:"visible",children:p.children}),d.return=l,d.sibling=null,s!==null&&(Q=l.deletions,Q===null?(l.deletions=[s],l.flags|=16):Q.push(s)),l.child=d,l.memoizedState=null,d)}function UO(s,l){return l=Gf({mode:"visible",children:l},s.mode),l.return=s,s.child=l}function Gf(s,l){return s=_r(22,s,null,l),s.lanes=0,s}function YO(s,l,d){return go(l,s.child,null,d),s=UO(l,l.pendingProps.children),s.flags|=2,l.memoizedState=null,s}function dk(s,l,d){s.lanes|=l;var p=s.alternate;p!==null&&(p.lanes|=l),lO(s.return,l,d)}function FO(s,l,d,p,O,b){var Q=s.memoizedState;Q===null?s.memoizedState={isBackwards:l,rendering:null,renderingStartTime:0,last:p,tail:d,tailMode:O,treeForkCount:b}:(Q.isBackwards=l,Q.rendering=null,Q.renderingStartTime=0,Q.last=p,Q.tail=d,Q.tailMode=O,Q.treeForkCount=b)}function fk(s,l,d){var p=l.pendingProps,O=p.revealOrder,b=p.tail;p=p.children;var Q=ln.current,j=(Q&2)!==0;if(j?(Q=Q&1|2,l.flags|=128):Q&=1,L(ln,Q),Vn(s,l,p,d),p=yt?su:0,!j&&s!==null&&(s.flags&128)!==0)e:for(s=l.child;s!==null;){if(s.tag===13)s.memoizedState!==null&&dk(s,d,l);else if(s.tag===19)dk(s,d,l);else if(s.child!==null){s.child.return=s,s=s.child;continue}if(s===l)break e;for(;s.sibling===null;){if(s.return===null||s.return===l)break e;s=s.return}s.sibling.return=s.return,s=s.sibling}switch(O){case"forwards":for(d=l.child,O=null;d!==null;)s=d.alternate,s!==null&&zf(s)===null&&(O=d),d=d.sibling;d=O,d===null?(O=l.child,l.child=null):(O=d.sibling,d.sibling=null),FO(l,!1,O,d,b,p);break;case"backwards":case"unstable_legacy-backwards":for(d=null,O=l.child,l.child=null;O!==null;){if(s=O.alternate,s!==null&&zf(s)===null){l.child=O;break}s=O.sibling,O.sibling=d,d=O,O=s}FO(l,!0,d,null,b,p);break;case"together":FO(l,!1,null,null,void 0,p);break;default:l.memoizedState=null}return l.child}function Ta(s,l,d){if(s!==null&&(l.dependencies=s.dependencies),ps|=l.lanes,(d&l.childLanes)===0)if(s!==null){if(xl(s,l,d,!1),(d&l.childLanes)===0)return null}else return null;if(s!==null&&l.child!==s.child)throw Error(r(153));if(l.child!==null){for(s=l.child,d=ba(s,s.pendingProps),l.child=d,d.return=l;s.sibling!==null;)s=s.sibling,d=d.sibling=ba(s,s.pendingProps),d.return=l;d.sibling=null}return l.child}function WO(s,l){return(s.lanes&l)!==0?!0:(s=s.dependencies,!!(s!==null&&Rf(s)))}function OD(s,l,d){switch(l.tag){case 3:ge(l,l.stateNode.containerInfo),ss(l,pn,s.memoizedState.cache),co();break;case 27:case 5:ke(l);break;case 4:ge(l,l.stateNode.containerInfo);break;case 10:ss(l,l.type,l.memoizedProps.value);break;case 31:if(l.memoizedState!==null)return l.flags|=128,bO(l),null;break;case 13:var p=l.memoizedState;if(p!==null)return p.dehydrated!==null?(us(l),l.flags|=128,null):(d&l.child.childLanes)!==0?uk(s,l,d):(us(l),s=Ta(s,l,d),s!==null?s.sibling:null);us(l);break;case 19:var O=(s.flags&128)!==0;if(p=(d&l.childLanes)!==0,p||(xl(s,l,d,!1),p=(d&l.childLanes)!==0),O){if(p)return fk(s,l,d);l.flags|=128}if(O=l.memoizedState,O!==null&&(O.rendering=null,O.tail=null,O.lastEffect=null),L(ln,ln.current),p)break;return null;case 22:return l.lanes=0,ik(s,l,d,l.pendingProps);case 24:ss(l,pn,s.memoizedState.cache)}return Ta(s,l,d)}function hk(s,l,d){if(s!==null)if(s.memoizedProps!==l.pendingProps)gn=!0;else{if(!WO(s,d)&&(l.flags&128)===0)return gn=!1,OD(s,l,d);gn=(s.flags&131072)!==0}else gn=!1,yt&&(l.flags&1048576)!==0&&qS(l,su,l.index);switch(l.lanes=0,l.tag){case 16:e:{var p=l.pendingProps;if(s=po(l.elementType),l.type=s,typeof s=="function")eO(s)?(p=vo(s,p),l.tag=1,l=lk(null,l,s,p,d)):(l.tag=0,l=XO(null,l,s,p,d));else{if(s!=null){var O=s.$$typeof;if(O===R){l.tag=11,l=tk(null,l,s,p,d);break e}else if(O===_){l.tag=14,l=nk(null,l,s,p,d);break e}}throw l=ee(s)||s,Error(r(306,l,""))}}return l;case 0:return XO(s,l,l.type,l.pendingProps,d);case 1:return p=l.type,O=vo(p,l.pendingProps),lk(s,l,p,O,d);case 3:e:{if(ge(l,l.stateNode.containerInfo),s===null)throw Error(r(387));p=l.pendingProps;var b=l.memoizedState;O=b.element,mO(s,l),pu(l,p,null,d);var Q=l.memoizedState;if(p=Q.cache,ss(l,pn,p),p!==b.cache&&cO(l,[pn],d,!0),hu(),p=Q.element,b.isDehydrated)if(b={element:p,isDehydrated:!1,cache:Q.cache},l.updateQueue.baseState=b,l.memoizedState=b,l.flags&256){l=ck(s,l,p,d);break e}else if(p!==O){O=Wr(Error(r(424)),l),ou(O),l=ck(s,l,p,d);break e}else for(s=l.stateNode.containerInfo,s.nodeType===9?s=s.body:s=s.nodeName==="HTML"?s.ownerDocument.body:s,Yt=ei(s.firstChild),Ln=l,yt=!0,is=null,Kr=!0,d=iw(l,null,p,d),l.child=d;d;)d.flags=d.flags&-3|4096,d=d.sibling;else{if(co(),p===O){l=Ta(s,l,d);break e}Vn(s,l,p,d)}l=l.child}return l;case 26:return Wf(s,l),s===null?(d=kC(l.type,null,l.pendingProps,null))?l.memoizedState=d:yt||(d=l.type,s=l.pendingProps,p=fh(he.current).createElement(d),p[zn]=l,p[pr]=s,Xn(p,d,s),$n(p),l.stateNode=p):l.memoizedState=kC(l.type,s.memoizedProps,l.pendingProps,s.memoizedState),null;case 27:return ke(l),s===null&&yt&&(p=l.stateNode=xC(l.type,l.pendingProps,he.current),Ln=l,Kr=!0,O=Yt,ys(l.type)?(Qv=O,Yt=ei(p.firstChild)):Yt=O),Vn(s,l,l.pendingProps.children,d),Wf(s,l),s===null&&(l.flags|=4194304),l.child;case 5:return s===null&&yt&&((O=p=Yt)&&(p=YD(p,l.type,l.pendingProps,Kr),p!==null?(l.stateNode=p,Ln=l,Yt=ei(p.firstChild),Kr=!1,O=!0):O=!1),O||as(l)),ke(l),O=l.type,b=l.pendingProps,Q=s!==null?s.memoizedProps:null,p=b.children,wv(O,b)?p=null:Q!==null&&wv(O,Q)&&(l.flags|=32),l.memoizedState!==null&&(O=SO(s,l,lD,null,null,d),ju._currentValue=O),Wf(s,l),Vn(s,l,p,d),l.child;case 6:return s===null&&yt&&((s=d=Yt)&&(d=FD(d,l.pendingProps,Kr),d!==null?(l.stateNode=d,Ln=l,Yt=null,s=!0):s=!1),s||as(l)),null;case 13:return uk(s,l,d);case 4:return ge(l,l.stateNode.containerInfo),p=l.pendingProps,s===null?l.child=go(l,null,p,d):Vn(s,l,p,d),l.child;case 11:return tk(s,l,l.type,l.pendingProps,d);case 7:return Vn(s,l,l.pendingProps,d),l.child;case 8:return Vn(s,l,l.pendingProps.children,d),l.child;case 12:return Vn(s,l,l.pendingProps.children,d),l.child;case 10:return p=l.pendingProps,ss(l,l.type,p.value),Vn(s,l,p.children,d),l.child;case 9:return O=l.type._context,p=l.pendingProps.children,fo(l),O=Zn(O),p=p(O),l.flags|=1,Vn(s,l,p,d),l.child;case 14:return nk(s,l,l.type,l.pendingProps,d);case 15:return rk(s,l,l.type,l.pendingProps,d);case 19:return fk(s,l,d);case 31:return gD(s,l,d);case 22:return ik(s,l,d,l.pendingProps);case 24:return fo(l),p=Zn(pn),s===null?(O=fO(),O===null&&(O=Xt,b=uO(),O.pooledCache=b,b.refCount++,b!==null&&(O.pooledCacheLanes|=d),O=b),l.memoizedState={parent:p,cache:O},pO(l),ss(l,pn,O)):((s.lanes&d)!==0&&(mO(s,l),pu(l,null,null,d),hu()),O=s.memoizedState,b=l.memoizedState,O.parent!==p?(O={parent:p,cache:p},l.memoizedState=O,l.lanes===0&&(l.memoizedState=l.updateQueue.baseState=O),ss(l,pn,p)):(p=b.cache,ss(l,pn,p),p!==O.cache&&cO(l,[pn],d,!0))),Vn(s,l,l.pendingProps.children,d),l.child;case 29:throw l.pendingProps}throw Error(r(156,l.tag))}function Ea(s){s.flags|=4}function GO(s,l,d,p,O){if((l=(s.mode&32)!==0)&&(l=!1),l){if(s.flags|=16777216,(O&335544128)===O)if(s.stateNode.complete)s.flags|=8192;else if(Zk())s.flags|=8192;else throw mo=jf,hO}else s.flags&=-16777217}function pk(s,l){if(l.type!=="stylesheet"||(l.state.loading&4)!==0)s.flags&=-16777217;else if(s.flags|=16777216,!AC(l))if(Zk())s.flags|=8192;else throw mo=jf,hO}function Hf(s,l){l!==null&&(s.flags|=4),s.flags&16384&&(l=s.tag!==22?Un():536870912,s.lanes|=l,Pl|=l)}function bu(s,l){if(!yt)switch(s.tailMode){case"hidden":l=s.tail;for(var d=null;l!==null;)l.alternate!==null&&(d=l),l=l.sibling;d===null?s.tail=null:d.sibling=null;break;case"collapsed":d=s.tail;for(var p=null;d!==null;)d.alternate!==null&&(p=d),d=d.sibling;p===null?l||s.tail===null?s.tail=null:s.tail.sibling=null:p.sibling=null}}function Ft(s){var l=s.alternate!==null&&s.alternate.child===s.child,d=0,p=0;if(l)for(var O=s.child;O!==null;)d|=O.lanes|O.childLanes,p|=O.subtreeFlags&65011712,p|=O.flags&65011712,O.return=s,O=O.sibling;else for(O=s.child;O!==null;)d|=O.lanes|O.childLanes,p|=O.subtreeFlags,p|=O.flags,O.return=s,O=O.sibling;return s.subtreeFlags|=p,s.childLanes=d,l}function vD(s,l,d){var p=l.pendingProps;switch(iO(l),l.tag){case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return Ft(l),null;case 1:return Ft(l),null;case 3:return d=l.stateNode,p=null,s!==null&&(p=s.memoizedState.cache),l.memoizedState.cache!==p&&(l.flags|=2048),wa(pn),xe(),d.pendingContext&&(d.context=d.pendingContext,d.pendingContext=null),(s===null||s.child===null)&&(bl(l)?Ea(l):s===null||s.memoizedState.isDehydrated&&(l.flags&256)===0||(l.flags|=1024,sO())),Ft(l),null;case 26:var O=l.type,b=l.memoizedState;return s===null?(Ea(l),b!==null?(Ft(l),pk(l,b)):(Ft(l),GO(l,O,null,p,d))):b?b!==s.memoizedState?(Ea(l),Ft(l),pk(l,b)):(Ft(l),l.flags&=-16777217):(s=s.memoizedProps,s!==p&&Ea(l),Ft(l),GO(l,O,s,p,d)),null;case 27:if(Ce(l),d=he.current,O=l.type,s!==null&&l.stateNode!=null)s.memoizedProps!==p&&Ea(l);else{if(!p){if(l.stateNode===null)throw Error(r(166));return Ft(l),null}s=q.current,bl(l)?YS(l):(s=xC(O,p,d),l.stateNode=s,Ea(l))}return Ft(l),null;case 5:if(Ce(l),O=l.type,s!==null&&l.stateNode!=null)s.memoizedProps!==p&&Ea(l);else{if(!p){if(l.stateNode===null)throw Error(r(166));return Ft(l),null}if(b=q.current,bl(l))YS(l);else{var Q=fh(he.current);switch(b){case 1:b=Q.createElementNS("http://www.w3.org/2000/svg",O);break;case 2:b=Q.createElementNS("http://www.w3.org/1998/Math/MathML",O);break;default:switch(O){case"svg":b=Q.createElementNS("http://www.w3.org/2000/svg",O);break;case"math":b=Q.createElementNS("http://www.w3.org/1998/Math/MathML",O);break;case"script":b=Q.createElement("div"),b.innerHTML="<script><\/script>",b=b.removeChild(b.firstChild);break;case"select":b=typeof p.is=="string"?Q.createElement("select",{is:p.is}):Q.createElement("select"),p.multiple?b.multiple=!0:p.size&&(b.size=p.size);break;default:b=typeof p.is=="string"?Q.createElement(O,{is:p.is}):Q.createElement(O)}}b[zn]=l,b[pr]=p;e:for(Q=l.child;Q!==null;){if(Q.tag===5||Q.tag===6)b.appendChild(Q.stateNode);else if(Q.tag!==4&&Q.tag!==27&&Q.child!==null){Q.child.return=Q,Q=Q.child;continue}if(Q===l)break e;for(;Q.sibling===null;){if(Q.return===null||Q.return===l)break e;Q=Q.return}Q.sibling.return=Q.return,Q=Q.sibling}l.stateNode=b;e:switch(Xn(b,O,p),O){case"button":case"input":case"select":case"textarea":p=!!p.autoFocus;break e;case"img":p=!0;break e;default:p=!1}p&&Ea(l)}}return Ft(l),GO(l,l.type,s===null?null:s.memoizedProps,l.pendingProps,d),null;case 6:if(s&&l.stateNode!=null)s.memoizedProps!==p&&Ea(l);else{if(typeof p!="string"&&l.stateNode===null)throw Error(r(166));if(s=he.current,bl(l)){if(s=l.stateNode,d=l.memoizedProps,p=null,O=Ln,O!==null)switch(O.tag){case 27:case 5:p=O.memoizedProps}s[zn]=l,s=!!(s.nodeValue===d||p!==null&&p.suppressHydrationWarning===!0||uC(s.nodeValue,d)),s||as(l,!0)}else s=fh(s).createTextNode(p),s[zn]=l,l.stateNode=s}return Ft(l),null;case 31:if(d=l.memoizedState,s===null||s.memoizedState!==null){if(p=bl(l),d!==null){if(s===null){if(!p)throw Error(r(318));if(s=l.memoizedState,s=s!==null?s.dehydrated:null,!s)throw Error(r(557));s[zn]=l}else co(),(l.flags&128)===0&&(l.memoizedState=null),l.flags|=4;Ft(l),s=!1}else d=sO(),s!==null&&s.memoizedState!==null&&(s.memoizedState.hydrationErrors=d),s=!0;if(!s)return l.flags&256?(Pr(l),l):(Pr(l),null);if((l.flags&128)!==0)throw Error(r(558))}return Ft(l),null;case 13:if(p=l.memoizedState,s===null||s.memoizedState!==null&&s.memoizedState.dehydrated!==null){if(O=bl(l),p!==null&&p.dehydrated!==null){if(s===null){if(!O)throw Error(r(318));if(O=l.memoizedState,O=O!==null?O.dehydrated:null,!O)throw Error(r(317));O[zn]=l}else co(),(l.flags&128)===0&&(l.memoizedState=null),l.flags|=4;Ft(l),O=!1}else O=sO(),s!==null&&s.memoizedState!==null&&(s.memoizedState.hydrationErrors=O),O=!0;if(!O)return l.flags&256?(Pr(l),l):(Pr(l),null)}return Pr(l),(l.flags&128)!==0?(l.lanes=d,l):(d=p!==null,s=s!==null&&s.memoizedState!==null,d&&(p=l.child,O=null,p.alternate!==null&&p.alternate.memoizedState!==null&&p.alternate.memoizedState.cachePool!==null&&(O=p.alternate.memoizedState.cachePool.pool),b=null,p.memoizedState!==null&&p.memoizedState.cachePool!==null&&(b=p.memoizedState.cachePool.pool),b!==O&&(p.flags|=2048)),d!==s&&d&&(l.child.flags|=8192),Hf(l,l.updateQueue),Ft(l),null);case 4:return xe(),s===null&&vv(l.stateNode.containerInfo),Ft(l),null;case 10:return wa(l.type),Ft(l),null;case 19:if(N(ln),p=l.memoizedState,p===null)return Ft(l),null;if(O=(l.flags&128)!==0,b=p.rendering,b===null)if(O)bu(p,!1);else{if(sn!==0||s!==null&&(s.flags&128)!==0)for(s=l.child;s!==null;){if(b=zf(s),b!==null){for(l.flags|=128,bu(p,!1),s=b.updateQueue,l.updateQueue=s,Hf(l,s),l.subtreeFlags=0,s=d,d=l.child;d!==null;)XS(d,s),d=d.sibling;return L(ln,ln.current&1|2),yt&&xa(l,p.treeForkCount),l.child}s=s.sibling}p.tail!==null&&te()>nh&&(l.flags|=128,O=!0,bu(p,!1),l.lanes=4194304)}else{if(!O)if(s=zf(b),s!==null){if(l.flags|=128,O=!0,s=s.updateQueue,l.updateQueue=s,Hf(l,s),bu(p,!0),p.tail===null&&p.tailMode==="hidden"&&!b.alternate&&!yt)return Ft(l),null}else 2*te()-p.renderingStartTime>nh&&d!==536870912&&(l.flags|=128,O=!0,bu(p,!1),l.lanes=4194304);p.isBackwards?(b.sibling=l.child,l.child=b):(s=p.last,s!==null?s.sibling=b:l.child=b,p.last=b)}return p.tail!==null?(s=p.tail,p.rendering=s,p.tail=s.sibling,p.renderingStartTime=te(),s.sibling=null,d=ln.current,L(ln,O?d&1|2:d&1),yt&&xa(l,p.treeForkCount),s):(Ft(l),null);case 22:case 23:return Pr(l),yO(),p=l.memoizedState!==null,s!==null?s.memoizedState!==null!==p&&(l.flags|=8192):p&&(l.flags|=8192),p?(d&536870912)!==0&&(l.flags&128)===0&&(Ft(l),l.subtreeFlags&6&&(l.flags|=8192)):Ft(l),d=l.updateQueue,d!==null&&Hf(l,d.retryQueue),d=null,s!==null&&s.memoizedState!==null&&s.memoizedState.cachePool!==null&&(d=s.memoizedState.cachePool.pool),p=null,l.memoizedState!==null&&l.memoizedState.cachePool!==null&&(p=l.memoizedState.cachePool.pool),p!==d&&(l.flags|=2048),s!==null&&N(ho),null;case 24:return d=null,s!==null&&(d=s.memoizedState.cache),l.memoizedState.cache!==d&&(l.flags|=2048),wa(pn),Ft(l),null;case 25:return null;case 30:return null}throw Error(r(156,l.tag))}function yD(s,l){switch(iO(l),l.tag){case 1:return s=l.flags,s&65536?(l.flags=s&-65537|128,l):null;case 3:return wa(pn),xe(),s=l.flags,(s&65536)!==0&&(s&128)===0?(l.flags=s&-65537|128,l):null;case 26:case 27:case 5:return Ce(l),null;case 31:if(l.memoizedState!==null){if(Pr(l),l.alternate===null)throw Error(r(340));co()}return s=l.flags,s&65536?(l.flags=s&-65537|128,l):null;case 13:if(Pr(l),s=l.memoizedState,s!==null&&s.dehydrated!==null){if(l.alternate===null)throw Error(r(340));co()}return s=l.flags,s&65536?(l.flags=s&-65537|128,l):null;case 19:return N(ln),null;case 4:return xe(),null;case 10:return wa(l.type),null;case 22:case 23:return Pr(l),yO(),s!==null&&N(ho),s=l.flags,s&65536?(l.flags=s&-65537|128,l):null;case 24:return wa(pn),null;case 25:return null;default:return null}}function mk(s,l){switch(iO(l),l.tag){case 3:wa(pn),xe();break;case 26:case 27:case 5:Ce(l);break;case 4:xe();break;case 31:l.memoizedState!==null&&Pr(l);break;case 13:Pr(l);break;case 19:N(ln);break;case 10:wa(l.type);break;case 22:case 23:Pr(l),yO(),s!==null&&N(ho);break;case 24:wa(pn)}}function xu(s,l){try{var d=l.updateQueue,p=d!==null?d.lastEffect:null;if(p!==null){var O=p.next;d=O;do{if((d.tag&s)===s){p=void 0;var b=d.create,Q=d.inst;p=b(),Q.destroy=p}d=d.next}while(d!==O)}}catch(j){$t(l,l.return,j)}}function fs(s,l,d){try{var p=l.updateQueue,O=p!==null?p.lastEffect:null;if(O!==null){var b=O.next;p=b;do{if((p.tag&s)===s){var Q=p.inst,j=Q.destroy;if(j!==void 0){Q.destroy=void 0,O=l;var Z=d,ie=j;try{ie()}catch(me){$t(O,Z,me)}}}p=p.next}while(p!==b)}}catch(me){$t(l,l.return,me)}}function gk(s){var l=s.updateQueue;if(l!==null){var d=s.stateNode;try{sw(l,d)}catch(p){$t(s,s.return,p)}}}function Ok(s,l,d){d.props=vo(s.type,s.memoizedProps),d.state=s.memoizedState;try{d.componentWillUnmount()}catch(p){$t(s,l,p)}}function Su(s,l){try{var d=s.ref;if(d!==null){switch(s.tag){case 26:case 27:case 5:var p=s.stateNode;break;case 30:p=s.stateNode;break;default:p=s.stateNode}typeof d=="function"?s.refCleanup=d(p):d.current=p}}catch(O){$t(s,l,O)}}function Ii(s,l){var d=s.ref,p=s.refCleanup;if(d!==null)if(typeof p=="function")try{p()}catch(O){$t(s,l,O)}finally{s.refCleanup=null,s=s.alternate,s!=null&&(s.refCleanup=null)}else if(typeof d=="function")try{d(null)}catch(O){$t(s,l,O)}else d.current=null}function vk(s){var l=s.type,d=s.memoizedProps,p=s.stateNode;try{e:switch(l){case"button":case"input":case"select":case"textarea":d.autoFocus&&p.focus();break e;case"img":d.src?p.src=d.src:d.srcSet&&(p.srcset=d.srcSet)}}catch(O){$t(s,s.return,O)}}function HO(s,l,d){try{var p=s.stateNode;VD(p,s.type,d,l),p[pr]=l}catch(O){$t(s,s.return,O)}}function yk(s){return s.tag===5||s.tag===3||s.tag===26||s.tag===27&&ys(s.type)||s.tag===4}function KO(s){e:for(;;){for(;s.sibling===null;){if(s.return===null||yk(s.return))return null;s=s.return}for(s.sibling.return=s.return,s=s.sibling;s.tag!==5&&s.tag!==6&&s.tag!==18;){if(s.tag===27&&ys(s.type)||s.flags&2||s.child===null||s.tag===4)continue e;s.child.return=s,s=s.child}if(!(s.flags&2))return s.stateNode}}function JO(s,l,d){var p=s.tag;if(p===5||p===6)s=s.stateNode,l?(d.nodeType===9?d.body:d.nodeName==="HTML"?d.ownerDocument.body:d).insertBefore(s,l):(l=d.nodeType===9?d.body:d.nodeName==="HTML"?d.ownerDocument.body:d,l.appendChild(s),d=d._reactRootContainer,d!=null||l.onclick!==null||(l.onclick=va));else if(p!==4&&(p===27&&ys(s.type)&&(d=s.stateNode,l=null),s=s.child,s!==null))for(JO(s,l,d),s=s.sibling;s!==null;)JO(s,l,d),s=s.sibling}function Kf(s,l,d){var p=s.tag;if(p===5||p===6)s=s.stateNode,l?d.insertBefore(s,l):d.appendChild(s);else if(p!==4&&(p===27&&ys(s.type)&&(d=s.stateNode),s=s.child,s!==null))for(Kf(s,l,d),s=s.sibling;s!==null;)Kf(s,l,d),s=s.sibling}function bk(s){var l=s.stateNode,d=s.memoizedProps;try{for(var p=s.type,O=l.attributes;O.length;)l.removeAttributeNode(O[0]);Xn(l,p,d),l[zn]=s,l[pr]=d}catch(b){$t(s,s.return,b)}}var Qa=!1,On=!1,ev=!1,xk=typeof WeakSet=="function"?WeakSet:Set,Pn=null;function bD(s,l){if(s=s.containerInfo,xv=yh,s=PS(s),Yg(s)){if("selectionStart"in s)var d={start:s.selectionStart,end:s.selectionEnd};else e:{d=(d=s.ownerDocument)&&d.defaultView||window;var p=d.getSelection&&d.getSelection();if(p&&p.rangeCount!==0){d=p.anchorNode;var O=p.anchorOffset,b=p.focusNode;p=p.focusOffset;try{d.nodeType,b.nodeType}catch{d=null;break e}var Q=0,j=-1,Z=-1,ie=0,me=0,be=s,ae=null;t:for(;;){for(var de;be!==d||O!==0&&be.nodeType!==3||(j=Q+O),be!==b||p!==0&&be.nodeType!==3||(Z=Q+p),be.nodeType===3&&(Q+=be.nodeValue.length),(de=be.firstChild)!==null;)ae=be,be=de;for(;;){if(be===s)break t;if(ae===d&&++ie===O&&(j=Q),ae===b&&++me===p&&(Z=Q),(de=be.nextSibling)!==null)break;be=ae,ae=be.parentNode}be=de}d=j===-1||Z===-1?null:{start:j,end:Z}}else d=null}d=d||{start:0,end:0}}else d=null;for(Sv={focusedElem:s,selectionRange:d},yh=!1,Pn=l;Pn!==null;)if(l=Pn,s=l.child,(l.subtreeFlags&1028)!==0&&s!==null)s.return=l,Pn=s;else for(;Pn!==null;){switch(l=Pn,b=l.alternate,s=l.flags,l.tag){case 0:if((s&4)!==0&&(s=l.updateQueue,s=s!==null?s.events:null,s!==null))for(d=0;d<s.length;d++)O=s[d],O.ref.impl=O.nextImpl;break;case 11:case 15:break;case 1:if((s&1024)!==0&&b!==null){s=void 0,d=l,O=b.memoizedProps,b=b.memoizedState,p=d.stateNode;try{var je=vo(d.type,O);s=p.getSnapshotBeforeUpdate(je,b),p.__reactInternalSnapshotBeforeUpdate=s}catch(Fe){$t(d,d.return,Fe)}}break;case 3:if((s&1024)!==0){if(s=l.stateNode.containerInfo,d=s.nodeType,d===9)Cv(s);else if(d===1)switch(s.nodeName){case"HEAD":case"HTML":case"BODY":Cv(s);break;default:s.textContent=""}}break;case 5:case 26:case 27:case 6:case 4:case 17:break;default:if((s&1024)!==0)throw Error(r(163))}if(s=l.sibling,s!==null){s.return=l.return,Pn=s;break}Pn=l.return}}function Sk(s,l,d){var p=d.flags;switch(d.tag){case 0:case 11:case 15:Ra(s,d),p&4&&xu(5,d);break;case 1:if(Ra(s,d),p&4)if(s=d.stateNode,l===null)try{s.componentDidMount()}catch(Q){$t(d,d.return,Q)}else{var O=vo(d.type,l.memoizedProps);l=l.memoizedState;try{s.componentDidUpdate(O,l,s.__reactInternalSnapshotBeforeUpdate)}catch(Q){$t(d,d.return,Q)}}p&64&&gk(d),p&512&&Su(d,d.return);break;case 3:if(Ra(s,d),p&64&&(s=d.updateQueue,s!==null)){if(l=null,d.child!==null)switch(d.child.tag){case 27:case 5:l=d.child.stateNode;break;case 1:l=d.child.stateNode}try{sw(s,l)}catch(Q){$t(d,d.return,Q)}}break;case 27:l===null&&p&4&&bk(d);case 26:case 5:Ra(s,d),l===null&&p&4&&vk(d),p&512&&Su(d,d.return);break;case 12:Ra(s,d);break;case 31:Ra(s,d),p&4&&Ck(s,d);break;case 13:Ra(s,d),p&4&&Tk(s,d),p&64&&(s=d.memoizedState,s!==null&&(s=s.dehydrated,s!==null&&(d=AD.bind(null,d),WD(s,d))));break;case 22:if(p=d.memoizedState!==null||Qa,!p){l=l!==null&&l.memoizedState!==null||On,O=Qa;var b=On;Qa=p,(On=l)&&!b?_a(s,d,(d.subtreeFlags&8772)!==0):Ra(s,d),Qa=O,On=b}break;case 30:break;default:Ra(s,d)}}function wk(s){var l=s.alternate;l!==null&&(s.alternate=null,wk(l)),s.child=null,s.deletions=null,s.sibling=null,s.tag===5&&(l=s.stateNode,l!==null&&Rg(l)),s.stateNode=null,s.return=null,s.dependencies=null,s.memoizedProps=null,s.memoizedState=null,s.pendingProps=null,s.stateNode=null,s.updateQueue=null}var Ht=null,gr=!1;function Aa(s,l,d){for(d=d.child;d!==null;)kk(s,l,d),d=d.sibling}function kk(s,l,d){if(Wt&&typeof Wt.onCommitFiberUnmount=="function")try{Wt.onCommitFiberUnmount(er,d)}catch{}switch(d.tag){case 26:On||Ii(d,l),Aa(s,l,d),d.memoizedState?d.memoizedState.count--:d.stateNode&&(d=d.stateNode,d.parentNode.removeChild(d));break;case 27:On||Ii(d,l);var p=Ht,O=gr;ys(d.type)&&(Ht=d.stateNode,gr=!1),Aa(s,l,d),_u(d.stateNode),Ht=p,gr=O;break;case 5:On||Ii(d,l);case 6:if(p=Ht,O=gr,Ht=null,Aa(s,l,d),Ht=p,gr=O,Ht!==null)if(gr)try{(Ht.nodeType===9?Ht.body:Ht.nodeName==="HTML"?Ht.ownerDocument.body:Ht).removeChild(d.stateNode)}catch(b){$t(d,l,b)}else try{Ht.removeChild(d.stateNode)}catch(b){$t(d,l,b)}break;case 18:Ht!==null&&(gr?(s=Ht,gC(s.nodeType===9?s.body:s.nodeName==="HTML"?s.ownerDocument.body:s,d.stateNode),Vl(s)):gC(Ht,d.stateNode));break;case 4:p=Ht,O=gr,Ht=d.stateNode.containerInfo,gr=!0,Aa(s,l,d),Ht=p,gr=O;break;case 0:case 11:case 14:case 15:fs(2,d,l),On||fs(4,d,l),Aa(s,l,d);break;case 1:On||(Ii(d,l),p=d.stateNode,typeof p.componentWillUnmount=="function"&&Ok(d,l,p)),Aa(s,l,d);break;case 21:Aa(s,l,d);break;case 22:On=(p=On)||d.memoizedState!==null,Aa(s,l,d),On=p;break;default:Aa(s,l,d)}}function Ck(s,l){if(l.memoizedState===null&&(s=l.alternate,s!==null&&(s=s.memoizedState,s!==null))){s=s.dehydrated;try{Vl(s)}catch(d){$t(l,l.return,d)}}}function Tk(s,l){if(l.memoizedState===null&&(s=l.alternate,s!==null&&(s=s.memoizedState,s!==null&&(s=s.dehydrated,s!==null))))try{Vl(s)}catch(d){$t(l,l.return,d)}}function xD(s){switch(s.tag){case 31:case 13:case 19:var l=s.stateNode;return l===null&&(l=s.stateNode=new xk),l;case 22:return s=s.stateNode,l=s._retryCache,l===null&&(l=s._retryCache=new xk),l;default:throw Error(r(435,s.tag))}}function Jf(s,l){var d=xD(s);l.forEach(function(p){if(!d.has(p)){d.add(p);var O=RD.bind(null,s,p);p.then(O,O)}})}function Or(s,l){var d=l.deletions;if(d!==null)for(var p=0;p<d.length;p++){var O=d[p],b=s,Q=l,j=Q;e:for(;j!==null;){switch(j.tag){case 27:if(ys(j.type)){Ht=j.stateNode,gr=!1;break e}break;case 5:Ht=j.stateNode,gr=!1;break e;case 3:case 4:Ht=j.stateNode.containerInfo,gr=!0;break e}j=j.return}if(Ht===null)throw Error(r(160));kk(b,Q,O),Ht=null,gr=!1,b=O.alternate,b!==null&&(b.return=null),O.return=null}if(l.subtreeFlags&13886)for(l=l.child;l!==null;)Ek(l,s),l=l.sibling}var yi=null;function Ek(s,l){var d=s.alternate,p=s.flags;switch(s.tag){case 0:case 11:case 14:case 15:Or(l,s),vr(s),p&4&&(fs(3,s,s.return),xu(3,s),fs(5,s,s.return));break;case 1:Or(l,s),vr(s),p&512&&(On||d===null||Ii(d,d.return)),p&64&&Qa&&(s=s.updateQueue,s!==null&&(p=s.callbacks,p!==null&&(d=s.shared.hiddenCallbacks,s.shared.hiddenCallbacks=d===null?p:d.concat(p))));break;case 26:var O=yi;if(Or(l,s),vr(s),p&512&&(On||d===null||Ii(d,d.return)),p&4){var b=d!==null?d.memoizedState:null;if(p=s.memoizedState,d===null)if(p===null)if(s.stateNode===null){e:{p=s.type,d=s.memoizedProps,O=O.ownerDocument||O;t:switch(p){case"title":b=O.getElementsByTagName("title")[0],(!b||b[Wc]||b[zn]||b.namespaceURI==="http://www.w3.org/2000/svg"||b.hasAttribute("itemprop"))&&(b=O.createElement(p),O.head.insertBefore(b,O.querySelector("head > title"))),Xn(b,p,d),b[zn]=s,$n(b),p=b;break e;case"link":var Q=EC("link","href",O).get(p+(d.href||""));if(Q){for(var j=0;j<Q.length;j++)if(b=Q[j],b.getAttribute("href")===(d.href==null||d.href===""?null:d.href)&&b.getAttribute("rel")===(d.rel==null?null:d.rel)&&b.getAttribute("title")===(d.title==null?null:d.title)&&b.getAttribute("crossorigin")===(d.crossOrigin==null?null:d.crossOrigin)){Q.splice(j,1);break t}}b=O.createElement(p),Xn(b,p,d),O.head.appendChild(b);break;case"meta":if(Q=EC("meta","content",O).get(p+(d.content||""))){for(j=0;j<Q.length;j++)if(b=Q[j],b.getAttribute("content")===(d.content==null?null:""+d.content)&&b.getAttribute("name")===(d.name==null?null:d.name)&&b.getAttribute("property")===(d.property==null?null:d.property)&&b.getAttribute("http-equiv")===(d.httpEquiv==null?null:d.httpEquiv)&&b.getAttribute("charset")===(d.charSet==null?null:d.charSet)){Q.splice(j,1);break t}}b=O.createElement(p),Xn(b,p,d),O.head.appendChild(b);break;default:throw Error(r(468,p))}b[zn]=s,$n(b),p=b}s.stateNode=p}else QC(O,s.type,s.stateNode);else s.stateNode=TC(O,p,s.memoizedProps);else b!==p?(b===null?d.stateNode!==null&&(d=d.stateNode,d.parentNode.removeChild(d)):b.count--,p===null?QC(O,s.type,s.stateNode):TC(O,p,s.memoizedProps)):p===null&&s.stateNode!==null&&HO(s,s.memoizedProps,d.memoizedProps)}break;case 27:Or(l,s),vr(s),p&512&&(On||d===null||Ii(d,d.return)),d!==null&&p&4&&HO(s,s.memoizedProps,d.memoizedProps);break;case 5:if(Or(l,s),vr(s),p&512&&(On||d===null||Ii(d,d.return)),s.flags&32){O=s.stateNode;try{ul(O,"")}catch(je){$t(s,s.return,je)}}p&4&&s.stateNode!=null&&(O=s.memoizedProps,HO(s,O,d!==null?d.memoizedProps:O)),p&1024&&(ev=!0);break;case 6:if(Or(l,s),vr(s),p&4){if(s.stateNode===null)throw Error(r(162));p=s.memoizedProps,d=s.stateNode;try{d.nodeValue=p}catch(je){$t(s,s.return,je)}}break;case 3:if(mh=null,O=yi,yi=hh(l.containerInfo),Or(l,s),yi=O,vr(s),p&4&&d!==null&&d.memoizedState.isDehydrated)try{Vl(l.containerInfo)}catch(je){$t(s,s.return,je)}ev&&(ev=!1,Qk(s));break;case 4:p=yi,yi=hh(s.stateNode.containerInfo),Or(l,s),vr(s),yi=p;break;case 12:Or(l,s),vr(s);break;case 31:Or(l,s),vr(s),p&4&&(p=s.updateQueue,p!==null&&(s.updateQueue=null,Jf(s,p)));break;case 13:Or(l,s),vr(s),s.child.flags&8192&&s.memoizedState!==null!=(d!==null&&d.memoizedState!==null)&&(th=te()),p&4&&(p=s.updateQueue,p!==null&&(s.updateQueue=null,Jf(s,p)));break;case 22:O=s.memoizedState!==null;var Z=d!==null&&d.memoizedState!==null,ie=Qa,me=On;if(Qa=ie||O,On=me||Z,Or(l,s),On=me,Qa=ie,vr(s),p&8192)e:for(l=s.stateNode,l._visibility=O?l._visibility&-2:l._visibility|1,O&&(d===null||Z||Qa||On||yo(s)),d=null,l=s;;){if(l.tag===5||l.tag===26){if(d===null){Z=d=l;try{if(b=Z.stateNode,O)Q=b.style,typeof Q.setProperty=="function"?Q.setProperty("display","none","important"):Q.display="none";else{j=Z.stateNode;var be=Z.memoizedProps.style,ae=be!=null&&be.hasOwnProperty("display")?be.display:null;j.style.display=ae==null||typeof ae=="boolean"?"":(""+ae).trim()}}catch(je){$t(Z,Z.return,je)}}}else if(l.tag===6){if(d===null){Z=l;try{Z.stateNode.nodeValue=O?"":Z.memoizedProps}catch(je){$t(Z,Z.return,je)}}}else if(l.tag===18){if(d===null){Z=l;try{var de=Z.stateNode;O?OC(de,!0):OC(Z.stateNode,!1)}catch(je){$t(Z,Z.return,je)}}}else if((l.tag!==22&&l.tag!==23||l.memoizedState===null||l===s)&&l.child!==null){l.child.return=l,l=l.child;continue}if(l===s)break e;for(;l.sibling===null;){if(l.return===null||l.return===s)break e;d===l&&(d=null),l=l.return}d===l&&(d=null),l.sibling.return=l.return,l=l.sibling}p&4&&(p=s.updateQueue,p!==null&&(d=p.retryQueue,d!==null&&(p.retryQueue=null,Jf(s,d))));break;case 19:Or(l,s),vr(s),p&4&&(p=s.updateQueue,p!==null&&(s.updateQueue=null,Jf(s,p)));break;case 30:break;case 21:break;default:Or(l,s),vr(s)}}function vr(s){var l=s.flags;if(l&2){try{for(var d,p=s.return;p!==null;){if(yk(p)){d=p;break}p=p.return}if(d==null)throw Error(r(160));switch(d.tag){case 27:var O=d.stateNode,b=KO(s);Kf(s,b,O);break;case 5:var Q=d.stateNode;d.flags&32&&(ul(Q,""),d.flags&=-33);var j=KO(s);Kf(s,j,Q);break;case 3:case 4:var Z=d.stateNode.containerInfo,ie=KO(s);JO(s,ie,Z);break;default:throw Error(r(161))}}catch(me){$t(s,s.return,me)}s.flags&=-3}l&4096&&(s.flags&=-4097)}function Qk(s){if(s.subtreeFlags&1024)for(s=s.child;s!==null;){var l=s;Qk(l),l.tag===5&&l.flags&1024&&l.stateNode.reset(),s=s.sibling}}function Ra(s,l){if(l.subtreeFlags&8772)for(l=l.child;l!==null;)Sk(s,l.alternate,l),l=l.sibling}function yo(s){for(s=s.child;s!==null;){var l=s;switch(l.tag){case 0:case 11:case 14:case 15:fs(4,l,l.return),yo(l);break;case 1:Ii(l,l.return);var d=l.stateNode;typeof d.componentWillUnmount=="function"&&Ok(l,l.return,d),yo(l);break;case 27:_u(l.stateNode);case 26:case 5:Ii(l,l.return),yo(l);break;case 22:l.memoizedState===null&&yo(l);break;case 30:yo(l);break;default:yo(l)}s=s.sibling}}function _a(s,l,d){for(d=d&&(l.subtreeFlags&8772)!==0,l=l.child;l!==null;){var p=l.alternate,O=s,b=l,Q=b.flags;switch(b.tag){case 0:case 11:case 15:_a(O,b,d),xu(4,b);break;case 1:if(_a(O,b,d),p=b,O=p.stateNode,typeof O.componentDidMount=="function")try{O.componentDidMount()}catch(ie){$t(p,p.return,ie)}if(p=b,O=p.updateQueue,O!==null){var j=p.stateNode;try{var Z=O.shared.hiddenCallbacks;if(Z!==null)for(O.shared.hiddenCallbacks=null,O=0;O<Z.length;O++)aw(Z[O],j)}catch(ie){$t(p,p.return,ie)}}d&&Q&64&&gk(b),Su(b,b.return);break;case 27:bk(b);case 26:case 5:_a(O,b,d),d&&p===null&&Q&4&&vk(b),Su(b,b.return);break;case 12:_a(O,b,d);break;case 31:_a(O,b,d),d&&Q&4&&Ck(O,b);break;case 13:_a(O,b,d),d&&Q&4&&Tk(O,b);break;case 22:b.memoizedState===null&&_a(O,b,d),Su(b,b.return);break;case 30:break;default:_a(O,b,d)}l=l.sibling}}function tv(s,l){var d=null;s!==null&&s.memoizedState!==null&&s.memoizedState.cachePool!==null&&(d=s.memoizedState.cachePool.pool),s=null,l.memoizedState!==null&&l.memoizedState.cachePool!==null&&(s=l.memoizedState.cachePool.pool),s!==d&&(s!=null&&s.refCount++,d!=null&&lu(d))}function nv(s,l){s=null,l.alternate!==null&&(s=l.alternate.memoizedState.cache),l=l.memoizedState.cache,l!==s&&(l.refCount++,s!=null&&lu(s))}function bi(s,l,d,p){if(l.subtreeFlags&10256)for(l=l.child;l!==null;)Ak(s,l,d,p),l=l.sibling}function Ak(s,l,d,p){var O=l.flags;switch(l.tag){case 0:case 11:case 15:bi(s,l,d,p),O&2048&&xu(9,l);break;case 1:bi(s,l,d,p);break;case 3:bi(s,l,d,p),O&2048&&(s=null,l.alternate!==null&&(s=l.alternate.memoizedState.cache),l=l.memoizedState.cache,l!==s&&(l.refCount++,s!=null&&lu(s)));break;case 12:if(O&2048){bi(s,l,d,p),s=l.stateNode;try{var b=l.memoizedProps,Q=b.id,j=b.onPostCommit;typeof j=="function"&&j(Q,l.alternate===null?"mount":"update",s.passiveEffectDuration,-0)}catch(Z){$t(l,l.return,Z)}}else bi(s,l,d,p);break;case 31:bi(s,l,d,p);break;case 13:bi(s,l,d,p);break;case 23:break;case 22:b=l.stateNode,Q=l.alternate,l.memoizedState!==null?b._visibility&2?bi(s,l,d,p):wu(s,l):b._visibility&2?bi(s,l,d,p):(b._visibility|=2,Rl(s,l,d,p,(l.subtreeFlags&10256)!==0||!1)),O&2048&&tv(Q,l);break;case 24:bi(s,l,d,p),O&2048&&nv(l.alternate,l);break;default:bi(s,l,d,p)}}function Rl(s,l,d,p,O){for(O=O&&((l.subtreeFlags&10256)!==0||!1),l=l.child;l!==null;){var b=s,Q=l,j=d,Z=p,ie=Q.flags;switch(Q.tag){case 0:case 11:case 15:Rl(b,Q,j,Z,O),xu(8,Q);break;case 23:break;case 22:var me=Q.stateNode;Q.memoizedState!==null?me._visibility&2?Rl(b,Q,j,Z,O):wu(b,Q):(me._visibility|=2,Rl(b,Q,j,Z,O)),O&&ie&2048&&tv(Q.alternate,Q);break;case 24:Rl(b,Q,j,Z,O),O&&ie&2048&&nv(Q.alternate,Q);break;default:Rl(b,Q,j,Z,O)}l=l.sibling}}function wu(s,l){if(l.subtreeFlags&10256)for(l=l.child;l!==null;){var d=s,p=l,O=p.flags;switch(p.tag){case 22:wu(d,p),O&2048&&tv(p.alternate,p);break;case 24:wu(d,p),O&2048&&nv(p.alternate,p);break;default:wu(d,p)}l=l.sibling}}var ku=8192;function _l(s,l,d){if(s.subtreeFlags&ku)for(s=s.child;s!==null;)Rk(s,l,d),s=s.sibling}function Rk(s,l,d){switch(s.tag){case 26:_l(s,l,d),s.flags&ku&&s.memoizedState!==null&&oz(d,yi,s.memoizedState,s.memoizedProps);break;case 5:_l(s,l,d);break;case 3:case 4:var p=yi;yi=hh(s.stateNode.containerInfo),_l(s,l,d),yi=p;break;case 22:s.memoizedState===null&&(p=s.alternate,p!==null&&p.memoizedState!==null?(p=ku,ku=16777216,_l(s,l,d),ku=p):_l(s,l,d));break;default:_l(s,l,d)}}function _k(s){var l=s.alternate;if(l!==null&&(s=l.child,s!==null)){l.child=null;do l=s.sibling,s.sibling=null,s=l;while(s!==null)}}function Cu(s){var l=s.deletions;if((s.flags&16)!==0){if(l!==null)for(var d=0;d<l.length;d++){var p=l[d];Pn=p,Pk(p,s)}_k(s)}if(s.subtreeFlags&10256)for(s=s.child;s!==null;)$k(s),s=s.sibling}function $k(s){switch(s.tag){case 0:case 11:case 15:Cu(s),s.flags&2048&&fs(9,s,s.return);break;case 3:Cu(s);break;case 12:Cu(s);break;case 22:var l=s.stateNode;s.memoizedState!==null&&l._visibility&2&&(s.return===null||s.return.tag!==13)?(l._visibility&=-3,eh(s)):Cu(s);break;default:Cu(s)}}function eh(s){var l=s.deletions;if((s.flags&16)!==0){if(l!==null)for(var d=0;d<l.length;d++){var p=l[d];Pn=p,Pk(p,s)}_k(s)}for(s=s.child;s!==null;){switch(l=s,l.tag){case 0:case 11:case 15:fs(8,l,l.return),eh(l);break;case 22:d=l.stateNode,d._visibility&2&&(d._visibility&=-3,eh(l));break;default:eh(l)}s=s.sibling}}function Pk(s,l){for(;Pn!==null;){var d=Pn;switch(d.tag){case 0:case 11:case 15:fs(8,d,l);break;case 23:case 22:if(d.memoizedState!==null&&d.memoizedState.cachePool!==null){var p=d.memoizedState.cachePool.pool;p!=null&&p.refCount++}break;case 24:lu(d.memoizedState.cache)}if(p=d.child,p!==null)p.return=d,Pn=p;else e:for(d=s;Pn!==null;){p=Pn;var O=p.sibling,b=p.return;if(wk(p),p===d){Pn=null;break e}if(O!==null){O.return=b,Pn=O;break e}Pn=b}}}var SD={getCacheForType:function(s){var l=Zn(pn),d=l.data.get(s);return d===void 0&&(d=s(),l.data.set(s,d)),d},cacheSignal:function(){return Zn(pn).controller.signal}},wD=typeof WeakMap=="function"?WeakMap:Map,Qt=0,Xt=null,mt=null,Ot=0,_t=0,jr=null,hs=!1,$l=!1,rv=!1,$a=0,sn=0,ps=0,bo=0,iv=0,Mr=0,Pl=0,Tu=null,yr=null,av=!1,th=0,jk=0,nh=1/0,rh=null,ms=null,Cn=0,gs=null,jl=null,Pa=0,sv=0,ov=null,Mk=null,Eu=0,lv=null;function Nr(){return(Qt&2)!==0&&Ot!==0?Ot&-Ot:D.T!==null?pv():Qg()}function Nk(){if(Mr===0)if((Ot&536870912)===0||yt){var s=nl;nl<<=1,(nl&3932160)===0&&(nl=262144),Mr=s}else Mr=536870912;return s=$r.current,s!==null&&(s.flags|=32),Mr}function br(s,l,d){(s===Xt&&(_t===2||_t===9)||s.cancelPendingCommit!==null)&&(Ml(s,0),Os(s,Ot,Mr,!1)),Jt(s,d),((Qt&2)===0||s!==Xt)&&(s===Xt&&((Qt&2)===0&&(bo|=d),sn===4&&Os(s,Ot,Mr,!1)),qi(s))}function Dk(s,l,d){if((Qt&6)!==0)throw Error(r(327));var p=!d&&(l&127)===0&&(l&s.expiredLanes)===0||Gt(s,l),O=p?TD(s,l):uv(s,l,!0),b=p;do{if(O===0){$l&&!p&&Os(s,l,0,!1);break}else{if(d=s.current.alternate,b&&!kD(d)){O=uv(s,l,!1),b=!1;continue}if(O===2){if(b=l,s.errorRecoveryDisabledLanes&b)var Q=0;else Q=s.pendingLanes&-536870913,Q=Q!==0?Q:Q&536870912?536870912:0;if(Q!==0){l=Q;e:{var j=s;O=Tu;var Z=j.current.memoizedState.isDehydrated;if(Z&&(Ml(j,Q).flags|=256),Q=uv(j,Q,!1),Q!==2){if(rv&&!Z){j.errorRecoveryDisabledLanes|=b,bo|=b,O=4;break e}b=yr,yr=O,b!==null&&(yr===null?yr=b:yr.push.apply(yr,b))}O=Q}if(b=!1,O!==2)continue}}if(O===1){Ml(s,0),Os(s,l,0,!0);break}e:{switch(p=s,b=O,b){case 0:case 1:throw Error(r(345));case 4:if((l&4194048)!==l)break;case 6:Os(p,l,Mr,!hs);break e;case 2:yr=null;break;case 3:case 5:break;default:throw Error(r(329))}if((l&62914560)===l&&(O=th+300-te(),10<O)){if(Os(p,l,Mr,!hs),Je(p,0,!0)!==0)break e;Pa=l,p.timeoutHandle=pC(zk.bind(null,p,d,yr,rh,av,l,Mr,bo,Pl,hs,b,"Throttled",-0,0),O);break e}zk(p,d,yr,rh,av,l,Mr,bo,Pl,hs,b,null,-0,0)}}break}while(!0);qi(s)}function zk(s,l,d,p,O,b,Q,j,Z,ie,me,be,ae,de){if(s.timeoutHandle=-1,be=l.subtreeFlags,be&8192||(be&16785408)===16785408){be={stylesheets:null,count:0,imgCount:0,imgBytes:0,suspenseyImages:[],waitingForImages:!0,waitingForViewTransition:!1,unsuspend:va},Rk(l,b,be);var je=(b&62914560)===b?th-te():(b&4194048)===b?jk-te():0;if(je=lz(be,je),je!==null){Pa=b,s.cancelPendingCommit=je(Uk.bind(null,s,l,b,d,p,O,Q,j,Z,me,be,null,ae,de)),Os(s,b,Q,!ie);return}}Uk(s,l,b,d,p,O,Q,j,Z)}function kD(s){for(var l=s;;){var d=l.tag;if((d===0||d===11||d===15)&&l.flags&16384&&(d=l.updateQueue,d!==null&&(d=d.stores,d!==null)))for(var p=0;p<d.length;p++){var O=d[p],b=O.getSnapshot;O=O.value;try{if(!Rr(b(),O))return!1}catch{return!1}}if(d=l.child,l.subtreeFlags&16384&&d!==null)d.return=l,l=d;else{if(l===s)break;for(;l.sibling===null;){if(l.return===null||l.return===s)return!0;l=l.return}l.sibling.return=l.return,l=l.sibling}}return!0}function Os(s,l,d,p){l&=~iv,l&=~bo,s.suspendedLanes|=l,s.pingedLanes&=~l,p&&(s.warmLanes|=l),p=s.expirationTimes;for(var O=l;0<O;){var b=31-rn(O),Q=1<<b;p[b]=-1,O&=~Q}d!==0&&no(s,d,l)}function ih(){return(Qt&6)===0?(Qu(0),!1):!0}function cv(){if(mt!==null){if(_t===0)var s=mt.return;else s=mt,Sa=uo=null,CO(s),Cl=null,uu=0,s=mt;for(;s!==null;)mk(s.alternate,s),s=s.return;mt=null}}function Ml(s,l){var d=s.timeoutHandle;d!==-1&&(s.timeoutHandle=-1,ID(d)),d=s.cancelPendingCommit,d!==null&&(s.cancelPendingCommit=null,d()),Pa=0,cv(),Xt=s,mt=d=ba(s.current,null),Ot=l,_t=0,jr=null,hs=!1,$l=Gt(s,l),rv=!1,Pl=Mr=iv=bo=ps=sn=0,yr=Tu=null,av=!1,(l&8)!==0&&(l|=l&32);var p=s.entangledLanes;if(p!==0)for(s=s.entanglements,p&=l;0<p;){var O=31-rn(p),b=1<<O;l|=s[O],p&=~b}return $a=l,Cf(),d}function Lk(s,l){at=null,D.H=vu,l===kl||l===Pf?(l=tw(),_t=3):l===hO?(l=tw(),_t=4):_t=l===VO?8:l!==null&&typeof l=="object"&&typeof l.then=="function"?6:1,jr=l,mt===null&&(sn=1,Yf(s,Wr(l,s.current)))}function Zk(){var s=$r.current;return s===null?!0:(Ot&4194048)===Ot?Jr===null:(Ot&62914560)===Ot||(Ot&536870912)!==0?s===Jr:!1}function Vk(){var s=D.H;return D.H=vu,s===null?vu:s}function Xk(){var s=D.A;return D.A=SD,s}function ah(){sn=4,hs||(Ot&4194048)!==Ot&&$r.current!==null||($l=!0),(ps&134217727)===0&&(bo&134217727)===0||Xt===null||Os(Xt,Ot,Mr,!1)}function uv(s,l,d){var p=Qt;Qt|=2;var O=Vk(),b=Xk();(Xt!==s||Ot!==l)&&(rh=null,Ml(s,l)),l=!1;var Q=sn;e:do try{if(_t!==0&&mt!==null){var j=mt,Z=jr;switch(_t){case 8:cv(),Q=6;break e;case 3:case 2:case 9:case 6:$r.current===null&&(l=!0);var ie=_t;if(_t=0,jr=null,Nl(s,j,Z,ie),d&&$l){Q=0;break e}break;default:ie=_t,_t=0,jr=null,Nl(s,j,Z,ie)}}CD(),Q=sn;break}catch(me){Lk(s,me)}while(!0);return l&&s.shellSuspendCounter++,Sa=uo=null,Qt=p,D.H=O,D.A=b,mt===null&&(Xt=null,Ot=0,Cf()),Q}function CD(){for(;mt!==null;)Bk(mt)}function TD(s,l){var d=Qt;Qt|=2;var p=Vk(),O=Xk();Xt!==s||Ot!==l?(rh=null,nh=te()+500,Ml(s,l)):$l=Gt(s,l);e:do try{if(_t!==0&&mt!==null){l=mt;var b=jr;t:switch(_t){case 1:_t=0,jr=null,Nl(s,l,b,1);break;case 2:case 9:if(JS(b)){_t=0,jr=null,Ik(l);break}l=function(){_t!==2&&_t!==9||Xt!==s||(_t=7),qi(s)},b.then(l,l);break e;case 3:_t=7;break e;case 4:_t=5;break e;case 7:JS(b)?(_t=0,jr=null,Ik(l)):(_t=0,jr=null,Nl(s,l,b,7));break;case 5:var Q=null;switch(mt.tag){case 26:Q=mt.memoizedState;case 5:case 27:var j=mt;if(Q?AC(Q):j.stateNode.complete){_t=0,jr=null;var Z=j.sibling;if(Z!==null)mt=Z;else{var ie=j.return;ie!==null?(mt=ie,sh(ie)):mt=null}break t}}_t=0,jr=null,Nl(s,l,b,5);break;case 6:_t=0,jr=null,Nl(s,l,b,6);break;case 8:cv(),sn=6;break e;default:throw Error(r(462))}}ED();break}catch(me){Lk(s,me)}while(!0);return Sa=uo=null,D.H=p,D.A=O,Qt=d,mt!==null?0:(Xt=null,Ot=0,Cf(),sn)}function ED(){for(;mt!==null&&!Y();)Bk(mt)}function Bk(s){var l=hk(s.alternate,s,$a);s.memoizedProps=s.pendingProps,l===null?sh(s):mt=l}function Ik(s){var l=s,d=l.alternate;switch(l.tag){case 15:case 0:l=ok(d,l,l.pendingProps,l.type,void 0,Ot);break;case 11:l=ok(d,l,l.pendingProps,l.type.render,l.ref,Ot);break;case 5:CO(l);default:mk(d,l),l=mt=XS(l,$a),l=hk(d,l,$a)}s.memoizedProps=s.pendingProps,l===null?sh(s):mt=l}function Nl(s,l,d,p){Sa=uo=null,CO(l),Cl=null,uu=0;var O=l.return;try{if(mD(s,O,l,d,Ot)){sn=1,Yf(s,Wr(d,s.current)),mt=null;return}}catch(b){if(O!==null)throw mt=O,b;sn=1,Yf(s,Wr(d,s.current)),mt=null;return}l.flags&32768?(yt||p===1?s=!0:$l||(Ot&536870912)!==0?s=!1:(hs=s=!0,(p===2||p===9||p===3||p===6)&&(p=$r.current,p!==null&&p.tag===13&&(p.flags|=16384))),qk(l,s)):sh(l)}function sh(s){var l=s;do{if((l.flags&32768)!==0){qk(l,hs);return}s=l.return;var d=vD(l.alternate,l,$a);if(d!==null){mt=d;return}if(l=l.sibling,l!==null){mt=l;return}mt=l=s}while(l!==null);sn===0&&(sn=5)}function qk(s,l){do{var d=yD(s.alternate,s);if(d!==null){d.flags&=32767,mt=d;return}if(d=s.return,d!==null&&(d.flags|=32768,d.subtreeFlags=0,d.deletions=null),!l&&(s=s.sibling,s!==null)){mt=s;return}mt=s=d}while(s!==null);sn=6,mt=null}function Uk(s,l,d,p,O,b,Q,j,Z){s.cancelPendingCommit=null;do oh();while(Cn!==0);if((Qt&6)!==0)throw Error(r(327));if(l!==null){if(l===s.current)throw Error(r(177));if(b=l.lanes|l.childLanes,b|=Kg,dr(s,d,b,Q,j,Z),s===Xt&&(mt=Xt=null,Ot=0),jl=l,gs=s,Pa=d,sv=b,ov=O,Mk=p,(l.subtreeFlags&10256)!==0||(l.flags&10256)!==0?(s.callbackNode=null,s.callbackPriority=0,_D(Ye,function(){return Hk(),null})):(s.callbackNode=null,s.callbackPriority=0),p=(l.flags&13878)!==0,(l.subtreeFlags&13878)!==0||p){p=D.T,D.T=null,O=G.p,G.p=2,Q=Qt,Qt|=4;try{bD(s,l,d)}finally{Qt=Q,G.p=O,D.T=p}}Cn=1,Yk(),Fk(),Wk()}}function Yk(){if(Cn===1){Cn=0;var s=gs,l=jl,d=(l.flags&13878)!==0;if((l.subtreeFlags&13878)!==0||d){d=D.T,D.T=null;var p=G.p;G.p=2;var O=Qt;Qt|=4;try{Ek(l,s);var b=Sv,Q=PS(s.containerInfo),j=b.focusedElem,Z=b.selectionRange;if(Q!==j&&j&&j.ownerDocument&&$S(j.ownerDocument.documentElement,j)){if(Z!==null&&Yg(j)){var ie=Z.start,me=Z.end;if(me===void 0&&(me=ie),"selectionStart"in j)j.selectionStart=ie,j.selectionEnd=Math.min(me,j.value.length);else{var be=j.ownerDocument||document,ae=be&&be.defaultView||window;if(ae.getSelection){var de=ae.getSelection(),je=j.textContent.length,Fe=Math.min(Z.start,je),Lt=Z.end===void 0?Fe:Math.min(Z.end,je);!de.extend&&Fe>Lt&&(Q=Lt,Lt=Fe,Fe=Q);var K=_S(j,Fe),U=_S(j,Lt);if(K&&U&&(de.rangeCount!==1||de.anchorNode!==K.node||de.anchorOffset!==K.offset||de.focusNode!==U.node||de.focusOffset!==U.offset)){var re=be.createRange();re.setStart(K.node,K.offset),de.removeAllRanges(),Fe>Lt?(de.addRange(re),de.extend(U.node,U.offset)):(re.setEnd(U.node,U.offset),de.addRange(re))}}}}for(be=[],de=j;de=de.parentNode;)de.nodeType===1&&be.push({element:de,left:de.scrollLeft,top:de.scrollTop});for(typeof j.focus=="function"&&j.focus(),j=0;j<be.length;j++){var ve=be[j];ve.element.scrollLeft=ve.left,ve.element.scrollTop=ve.top}}yh=!!xv,Sv=xv=null}finally{Qt=O,G.p=p,D.T=d}}s.current=l,Cn=2}}function Fk(){if(Cn===2){Cn=0;var s=gs,l=jl,d=(l.flags&8772)!==0;if((l.subtreeFlags&8772)!==0||d){d=D.T,D.T=null;var p=G.p;G.p=2;var O=Qt;Qt|=4;try{Sk(s,l.alternate,l)}finally{Qt=O,G.p=p,D.T=d}}Cn=3}}function Wk(){if(Cn===4||Cn===3){Cn=0,oe();var s=gs,l=jl,d=Pa,p=Mk;(l.subtreeFlags&10256)!==0||(l.flags&10256)!==0?Cn=5:(Cn=0,jl=gs=null,Gk(s,s.pendingLanes));var O=s.pendingLanes;if(O===0&&(ms=null),Oi(d),l=l.stateNode,Wt&&typeof Wt.onCommitFiberRoot=="function")try{Wt.onCommitFiberRoot(er,l,void 0,(l.current.flags&128)===128)}catch{}if(p!==null){l=D.T,O=G.p,G.p=2,D.T=null;try{for(var b=s.onRecoverableError,Q=0;Q<p.length;Q++){var j=p[Q];b(j.value,{componentStack:j.stack})}}finally{D.T=l,G.p=O}}(Pa&3)!==0&&oh(),qi(s),O=s.pendingLanes,(d&261930)!==0&&(O&42)!==0?s===lv?Eu++:(Eu=0,lv=s):Eu=0,Qu(0)}}function Gk(s,l){(s.pooledCacheLanes&=l)===0&&(l=s.pooledCache,l!=null&&(s.pooledCache=null,lu(l)))}function oh(){return Yk(),Fk(),Wk(),Hk()}function Hk(){if(Cn!==5)return!1;var s=gs,l=sv;sv=0;var d=Oi(Pa),p=D.T,O=G.p;try{G.p=32>d?32:d,D.T=null,d=ov,ov=null;var b=gs,Q=Pa;if(Cn=0,jl=gs=null,Pa=0,(Qt&6)!==0)throw Error(r(331));var j=Qt;if(Qt|=4,$k(b.current),Ak(b,b.current,Q,d),Qt=j,Qu(0,!1),Wt&&typeof Wt.onPostCommitFiberRoot=="function")try{Wt.onPostCommitFiberRoot(er,b)}catch{}return!0}finally{G.p=O,D.T=p,Gk(s,l)}}function Kk(s,l,d){l=Wr(d,l),l=ZO(s.stateNode,l,2),s=cs(s,l,2),s!==null&&(Jt(s,2),qi(s))}function $t(s,l,d){if(s.tag===3)Kk(s,s,d);else for(;l!==null;){if(l.tag===3){Kk(l,s,d);break}else if(l.tag===1){var p=l.stateNode;if(typeof l.type.getDerivedStateFromError=="function"||typeof p.componentDidCatch=="function"&&(ms===null||!ms.has(p))){s=Wr(d,s),d=Jw(2),p=cs(l,d,2),p!==null&&(ek(d,p,l,s),Jt(p,2),qi(p));break}}l=l.return}}function dv(s,l,d){var p=s.pingCache;if(p===null){p=s.pingCache=new wD;var O=new Set;p.set(l,O)}else O=p.get(l),O===void 0&&(O=new Set,p.set(l,O));O.has(d)||(rv=!0,O.add(d),s=QD.bind(null,s,l,d),l.then(s,s))}function QD(s,l,d){var p=s.pingCache;p!==null&&p.delete(l),s.pingedLanes|=s.suspendedLanes&d,s.warmLanes&=~d,Xt===s&&(Ot&d)===d&&(sn===4||sn===3&&(Ot&62914560)===Ot&&300>te()-th?(Qt&2)===0&&Ml(s,0):iv|=d,Pl===Ot&&(Pl=0)),qi(s)}function Jk(s,l){l===0&&(l=Un()),s=oo(s,l),s!==null&&(Jt(s,l),qi(s))}function AD(s){var l=s.memoizedState,d=0;l!==null&&(d=l.retryLane),Jk(s,d)}function RD(s,l){var d=0;switch(s.tag){case 31:case 13:var p=s.stateNode,O=s.memoizedState;O!==null&&(d=O.retryLane);break;case 19:p=s.stateNode;break;case 22:p=s.stateNode._retryCache;break;default:throw Error(r(314))}p!==null&&p.delete(l),Jk(s,d)}function _D(s,l){return Ge(s,l)}var lh=null,Dl=null,fv=!1,ch=!1,hv=!1,vs=0;function qi(s){s!==Dl&&s.next===null&&(Dl===null?lh=Dl=s:Dl=Dl.next=s),ch=!0,fv||(fv=!0,PD())}function Qu(s,l){if(!hv&&ch){hv=!0;do for(var d=!1,p=lh;p!==null;){if(s!==0){var O=p.pendingLanes;if(O===0)var b=0;else{var Q=p.suspendedLanes,j=p.pingedLanes;b=(1<<31-rn(42|s)+1)-1,b&=O&~(Q&~j),b=b&201326741?b&201326741|1:b?b|2:0}b!==0&&(d=!0,rC(p,b))}else b=Ot,b=Je(p,p===Xt?b:0,p.cancelPendingCommit!==null||p.timeoutHandle!==-1),(b&3)===0||Gt(p,b)||(d=!0,rC(p,b));p=p.next}while(d);hv=!1}}function $D(){eC()}function eC(){ch=fv=!1;var s=0;vs!==0&&BD()&&(s=vs);for(var l=te(),d=null,p=lh;p!==null;){var O=p.next,b=tC(p,l);b===0?(p.next=null,d===null?lh=O:d.next=O,O===null&&(Dl=d)):(d=p,(s!==0||(b&3)!==0)&&(ch=!0)),p=O}Cn!==0&&Cn!==5||Qu(s),vs!==0&&(vs=0)}function tC(s,l){for(var d=s.suspendedLanes,p=s.pingedLanes,O=s.expirationTimes,b=s.pendingLanes&-62914561;0<b;){var Q=31-rn(b),j=1<<Q,Z=O[Q];Z===-1?((j&d)===0||(j&p)!==0)&&(O[Q]=_n(j,l)):Z<=l&&(s.expiredLanes|=j),b&=~j}if(l=Xt,d=Ot,d=Je(s,s===l?d:0,s.cancelPendingCommit!==null||s.timeoutHandle!==-1),p=s.callbackNode,d===0||s===l&&(_t===2||_t===9)||s.cancelPendingCommit!==null)return p!==null&&p!==null&&z(p),s.callbackNode=null,s.callbackPriority=0;if((d&3)===0||Gt(s,d)){if(l=d&-d,l===s.callbackPriority)return l;switch(p!==null&&z(p),Oi(d)){case 2:case 8:d=Te;break;case 32:d=Ye;break;case 268435456:d=kt;break;default:d=Ye}return p=nC.bind(null,s),d=Ge(d,p),s.callbackPriority=l,s.callbackNode=d,l}return p!==null&&p!==null&&z(p),s.callbackPriority=2,s.callbackNode=null,2}function nC(s,l){if(Cn!==0&&Cn!==5)return s.callbackNode=null,s.callbackPriority=0,null;var d=s.callbackNode;if(oh()&&s.callbackNode!==d)return null;var p=Ot;return p=Je(s,s===Xt?p:0,s.cancelPendingCommit!==null||s.timeoutHandle!==-1),p===0?null:(Dk(s,p,l),tC(s,te()),s.callbackNode!=null&&s.callbackNode===d?nC.bind(null,s):null)}function rC(s,l){if(oh())return null;Dk(s,l,!0)}function PD(){qD(function(){(Qt&6)!==0?Ge(Oe,$D):eC()})}function pv(){if(vs===0){var s=Sl;s===0&&(s=tl,tl<<=1,(tl&261888)===0&&(tl=256)),vs=s}return vs}function iC(s){return s==null||typeof s=="symbol"||typeof s=="boolean"?null:typeof s=="function"?s:Of(""+s)}function aC(s,l){var d=l.ownerDocument.createElement("input");return d.name=l.name,d.value=l.value,s.id&&d.setAttribute("form",s.id),l.parentNode.insertBefore(d,l),s=new FormData(s),d.parentNode.removeChild(d),s}function jD(s,l,d,p,O){if(l==="submit"&&d&&d.stateNode===O){var b=iC((O[pr]||null).action),Q=p.submitter;Q&&(l=(l=Q[pr]||null)?iC(l.formAction):Q.getAttribute("formAction"),l!==null&&(b=l,Q=null));var j=new xf("action","action",null,p,O);s.push({event:j,listeners:[{instance:null,listener:function(){if(p.defaultPrevented){if(vs!==0){var Z=Q?aC(O,Q):new FormData(O);jO(d,{pending:!0,data:Z,method:O.method,action:b},null,Z)}}else typeof b=="function"&&(j.preventDefault(),Z=Q?aC(O,Q):new FormData(O),jO(d,{pending:!0,data:Z,method:O.method,action:b},b,Z))},currentTarget:O}]})}}for(var mv=0;mv<Hg.length;mv++){var gv=Hg[mv],MD=gv.toLowerCase(),ND=gv[0].toUpperCase()+gv.slice(1);vi(MD,"on"+ND)}vi(NS,"onAnimationEnd"),vi(DS,"onAnimationIteration"),vi(zS,"onAnimationStart"),vi("dblclick","onDoubleClick"),vi("focusin","onFocus"),vi("focusout","onBlur"),vi(K3,"onTransitionRun"),vi(J3,"onTransitionStart"),vi(eD,"onTransitionCancel"),vi(LS,"onTransitionEnd"),ll("onMouseEnter",["mouseout","mouseover"]),ll("onMouseLeave",["mouseout","mouseover"]),ll("onPointerEnter",["pointerout","pointerover"]),ll("onPointerLeave",["pointerout","pointerover"]),ro("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),ro("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),ro("onBeforeInput",["compositionend","keypress","textInput","paste"]),ro("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),ro("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),ro("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Au="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(" "),DD=new Set("beforetoggle cancel close invalid load scroll scrollend toggle".split(" ").concat(Au));function sC(s,l){l=(l&4)!==0;for(var d=0;d<s.length;d++){var p=s[d],O=p.event;p=p.listeners;e:{var b=void 0;if(l)for(var Q=p.length-1;0<=Q;Q--){var j=p[Q],Z=j.instance,ie=j.currentTarget;if(j=j.listener,Z!==b&&O.isPropagationStopped())break e;b=j,O.currentTarget=ie;try{b(O)}catch(me){kf(me)}O.currentTarget=null,b=Z}else for(Q=0;Q<p.length;Q++){if(j=p[Q],Z=j.instance,ie=j.currentTarget,j=j.listener,Z!==b&&O.isPropagationStopped())break e;b=j,O.currentTarget=ie;try{b(O)}catch(me){kf(me)}O.currentTarget=null,b=Z}}}}function gt(s,l){var d=l[Ag];d===void 0&&(d=l[Ag]=new Set);var p=s+"__bubble";d.has(p)||(oC(l,s,2,!1),d.add(p))}function Ov(s,l,d){var p=0;l&&(p|=4),oC(d,s,p,l)}var uh="_reactListening"+Math.random().toString(36).slice(2);function vv(s){if(!s[uh]){s[uh]=!0,eS.forEach(function(d){d!=="selectionchange"&&(DD.has(d)||Ov(d,!1,s),Ov(d,!0,s))});var l=s.nodeType===9?s:s.ownerDocument;l===null||l[uh]||(l[uh]=!0,Ov("selectionchange",!1,l))}}function oC(s,l,d,p){switch(NC(l)){case 2:var O=dz;break;case 8:O=fz;break;default:O=Pv}d=O.bind(null,l,d,s),O=void 0,!zg||l!=="touchstart"&&l!=="touchmove"&&l!=="wheel"||(O=!0),p?O!==void 0?s.addEventListener(l,d,{capture:!0,passive:O}):s.addEventListener(l,d,!0):O!==void 0?s.addEventListener(l,d,{passive:O}):s.addEventListener(l,d,!1)}function yv(s,l,d,p,O){var b=p;if((l&1)===0&&(l&2)===0&&p!==null)e:for(;;){if(p===null)return;var Q=p.tag;if(Q===3||Q===4){var j=p.stateNode.containerInfo;if(j===O)break;if(Q===4)for(Q=p.return;Q!==null;){var Z=Q.tag;if((Z===3||Z===4)&&Q.stateNode.containerInfo===O)return;Q=Q.return}for(;j!==null;){if(Q=al(j),Q===null)return;if(Z=Q.tag,Z===5||Z===6||Z===26||Z===27){p=b=Q;continue e}j=j.parentNode}}p=p.return}fS(function(){var ie=b,me=Ng(d),be=[];e:{var ae=ZS.get(s);if(ae!==void 0){var de=xf,je=s;switch(s){case"keypress":if(yf(d)===0)break e;case"keydown":case"keyup":de=R3;break;case"focusin":je="focus",de=Xg;break;case"focusout":je="blur",de=Xg;break;case"beforeblur":case"afterblur":de=Xg;break;case"click":if(d.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":de=mS;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":de=v3;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":de=P3;break;case NS:case DS:case zS:de=x3;break;case LS:de=M3;break;case"scroll":case"scrollend":de=g3;break;case"wheel":de=D3;break;case"copy":case"cut":case"paste":de=w3;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":de=OS;break;case"toggle":case"beforetoggle":de=L3}var Fe=(l&4)!==0,Lt=!Fe&&(s==="scroll"||s==="scrollend"),K=Fe?ae!==null?ae+"Capture":null:ae;Fe=[];for(var U=ie,re;U!==null;){var ve=U;if(re=ve.stateNode,ve=ve.tag,ve!==5&&ve!==26&&ve!==27||re===null||K===null||(ve=Hc(U,K),ve!=null&&Fe.push(Ru(U,ve,re))),Lt)break;U=U.return}0<Fe.length&&(ae=new de(ae,je,null,d,me),be.push({event:ae,listeners:Fe}))}}if((l&7)===0){e:{if(ae=s==="mouseover"||s==="pointerover",de=s==="mouseout"||s==="pointerout",ae&&d!==Mg&&(je=d.relatedTarget||d.fromElement)&&(al(je)||je[il]))break e;if((de||ae)&&(ae=me.window===me?me:(ae=me.ownerDocument)?ae.defaultView||ae.parentWindow:window,de?(je=d.relatedTarget||d.toElement,de=ie,je=je?al(je):null,je!==null&&(Lt=a(je),Fe=je.tag,je!==Lt||Fe!==5&&Fe!==27&&Fe!==6)&&(je=null)):(de=null,je=ie),de!==je)){if(Fe=mS,ve="onMouseLeave",K="onMouseEnter",U="mouse",(s==="pointerout"||s==="pointerover")&&(Fe=OS,ve="onPointerLeave",K="onPointerEnter",U="pointer"),Lt=de==null?ae:Gc(de),re=je==null?ae:Gc(je),ae=new Fe(ve,U+"leave",de,d,me),ae.target=Lt,ae.relatedTarget=re,ve=null,al(me)===ie&&(Fe=new Fe(K,U+"enter",je,d,me),Fe.target=re,Fe.relatedTarget=Lt,ve=Fe),Lt=ve,de&&je)t:{for(Fe=zD,K=de,U=je,re=0,ve=K;ve;ve=Fe(ve))re++;ve=0;for(var Ie=U;Ie;Ie=Fe(Ie))ve++;for(;0<re-ve;)K=Fe(K),re--;for(;0<ve-re;)U=Fe(U),ve--;for(;re--;){if(K===U||U!==null&&K===U.alternate){Fe=K;break t}K=Fe(K),U=Fe(U)}Fe=null}else Fe=null;de!==null&&lC(be,ae,de,Fe,!1),je!==null&&Lt!==null&&lC(be,Lt,je,Fe,!0)}}e:{if(ae=ie?Gc(ie):window,de=ae.nodeName&&ae.nodeName.toLowerCase(),de==="select"||de==="input"&&ae.type==="file")var Ct=CS;else if(wS(ae))if(TS)Ct=W3;else{Ct=Y3;var Le=U3}else de=ae.nodeName,!de||de.toLowerCase()!=="input"||ae.type!=="checkbox"&&ae.type!=="radio"?ie&&jg(ie.elementType)&&(Ct=CS):Ct=F3;if(Ct&&(Ct=Ct(s,ie))){kS(be,Ct,d,me);break e}Le&&Le(s,ae,ie),s==="focusout"&&ie&&ae.type==="number"&&ie.memoizedProps.value!=null&&Pg(ae,"number",ae.value)}switch(Le=ie?Gc(ie):window,s){case"focusin":(wS(Le)||Le.contentEditable==="true")&&(pl=Le,Fg=ie,au=null);break;case"focusout":au=Fg=pl=null;break;case"mousedown":Wg=!0;break;case"contextmenu":case"mouseup":case"dragend":Wg=!1,jS(be,d,me);break;case"selectionchange":if(H3)break;case"keydown":case"keyup":jS(be,d,me)}var lt;if(Ig)e:{switch(s){case"compositionstart":var vt="onCompositionStart";break e;case"compositionend":vt="onCompositionEnd";break e;case"compositionupdate":vt="onCompositionUpdate";break e}vt=void 0}else hl?xS(s,d)&&(vt="onCompositionEnd"):s==="keydown"&&d.keyCode===229&&(vt="onCompositionStart");vt&&(vS&&d.locale!=="ko"&&(hl||vt!=="onCompositionStart"?vt==="onCompositionEnd"&&hl&&(lt=hS()):(ns=me,Lg="value"in ns?ns.value:ns.textContent,hl=!0)),Le=dh(ie,vt),0<Le.length&&(vt=new gS(vt,s,null,d,me),be.push({event:vt,listeners:Le}),lt?vt.data=lt:(lt=SS(d),lt!==null&&(vt.data=lt)))),(lt=V3?X3(s,d):B3(s,d))&&(vt=dh(ie,"onBeforeInput"),0<vt.length&&(Le=new gS("onBeforeInput","beforeinput",null,d,me),be.push({event:Le,listeners:vt}),Le.data=lt)),jD(be,s,ie,d,me)}sC(be,l)})}function Ru(s,l,d){return{instance:s,listener:l,currentTarget:d}}function dh(s,l){for(var d=l+"Capture",p=[];s!==null;){var O=s,b=O.stateNode;if(O=O.tag,O!==5&&O!==26&&O!==27||b===null||(O=Hc(s,d),O!=null&&p.unshift(Ru(s,O,b)),O=Hc(s,l),O!=null&&p.push(Ru(s,O,b))),s.tag===3)return p;s=s.return}return[]}function zD(s){if(s===null)return null;do s=s.return;while(s&&s.tag!==5&&s.tag!==27);return s||null}function lC(s,l,d,p,O){for(var b=l._reactName,Q=[];d!==null&&d!==p;){var j=d,Z=j.alternate,ie=j.stateNode;if(j=j.tag,Z!==null&&Z===p)break;j!==5&&j!==26&&j!==27||ie===null||(Z=ie,O?(ie=Hc(d,b),ie!=null&&Q.unshift(Ru(d,ie,Z))):O||(ie=Hc(d,b),ie!=null&&Q.push(Ru(d,ie,Z)))),d=d.return}Q.length!==0&&s.push({event:l,listeners:Q})}var LD=/\r\n?/g,ZD=/\u0000|\uFFFD/g;function cC(s){return(typeof s=="string"?s:""+s).replace(LD,`
|
|
10
|
-
`).replace(ZD,"")}function uC(s,l){return l=cC(l),cC(s)===l}function zt(s,l,d,p,O,b){switch(d){case"children":typeof p=="string"?l==="body"||l==="textarea"&&p===""||ul(s,p):(typeof p=="number"||typeof p=="bigint")&&l!=="body"&&ul(s,""+p);break;case"className":mf(s,"class",p);break;case"tabIndex":mf(s,"tabindex",p);break;case"dir":case"role":case"viewBox":case"width":case"height":mf(s,d,p);break;case"style":uS(s,p,b);break;case"data":if(l!=="object"){mf(s,"data",p);break}case"src":case"href":if(p===""&&(l!=="a"||d!=="href")){s.removeAttribute(d);break}if(p==null||typeof p=="function"||typeof p=="symbol"||typeof p=="boolean"){s.removeAttribute(d);break}p=Of(""+p),s.setAttribute(d,p);break;case"action":case"formAction":if(typeof p=="function"){s.setAttribute(d,"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 b=="function"&&(d==="formAction"?(l!=="input"&&zt(s,l,"name",O.name,O,null),zt(s,l,"formEncType",O.formEncType,O,null),zt(s,l,"formMethod",O.formMethod,O,null),zt(s,l,"formTarget",O.formTarget,O,null)):(zt(s,l,"encType",O.encType,O,null),zt(s,l,"method",O.method,O,null),zt(s,l,"target",O.target,O,null)));if(p==null||typeof p=="symbol"||typeof p=="boolean"){s.removeAttribute(d);break}p=Of(""+p),s.setAttribute(d,p);break;case"onClick":p!=null&&(s.onclick=va);break;case"onScroll":p!=null&>("scroll",s);break;case"onScrollEnd":p!=null&>("scrollend",s);break;case"dangerouslySetInnerHTML":if(p!=null){if(typeof p!="object"||!("__html"in p))throw Error(r(61));if(d=p.__html,d!=null){if(O.children!=null)throw Error(r(60));s.innerHTML=d}}break;case"multiple":s.multiple=p&&typeof p!="function"&&typeof p!="symbol";break;case"muted":s.muted=p&&typeof p!="function"&&typeof p!="symbol";break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":break;case"autoFocus":break;case"xlinkHref":if(p==null||typeof p=="function"||typeof p=="boolean"||typeof p=="symbol"){s.removeAttribute("xlink:href");break}d=Of(""+p),s.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",d);break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":p!=null&&typeof p!="function"&&typeof p!="symbol"?s.setAttribute(d,""+p):s.removeAttribute(d);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":p&&typeof p!="function"&&typeof p!="symbol"?s.setAttribute(d,""):s.removeAttribute(d);break;case"capture":case"download":p===!0?s.setAttribute(d,""):p!==!1&&p!=null&&typeof p!="function"&&typeof p!="symbol"?s.setAttribute(d,p):s.removeAttribute(d);break;case"cols":case"rows":case"size":case"span":p!=null&&typeof p!="function"&&typeof p!="symbol"&&!isNaN(p)&&1<=p?s.setAttribute(d,p):s.removeAttribute(d);break;case"rowSpan":case"start":p==null||typeof p=="function"||typeof p=="symbol"||isNaN(p)?s.removeAttribute(d):s.setAttribute(d,p);break;case"popover":gt("beforetoggle",s),gt("toggle",s),pf(s,"popover",p);break;case"xlinkActuate":Oa(s,"http://www.w3.org/1999/xlink","xlink:actuate",p);break;case"xlinkArcrole":Oa(s,"http://www.w3.org/1999/xlink","xlink:arcrole",p);break;case"xlinkRole":Oa(s,"http://www.w3.org/1999/xlink","xlink:role",p);break;case"xlinkShow":Oa(s,"http://www.w3.org/1999/xlink","xlink:show",p);break;case"xlinkTitle":Oa(s,"http://www.w3.org/1999/xlink","xlink:title",p);break;case"xlinkType":Oa(s,"http://www.w3.org/1999/xlink","xlink:type",p);break;case"xmlBase":Oa(s,"http://www.w3.org/XML/1998/namespace","xml:base",p);break;case"xmlLang":Oa(s,"http://www.w3.org/XML/1998/namespace","xml:lang",p);break;case"xmlSpace":Oa(s,"http://www.w3.org/XML/1998/namespace","xml:space",p);break;case"is":pf(s,"is",p);break;case"innerText":case"textContent":break;default:(!(2<d.length)||d[0]!=="o"&&d[0]!=="O"||d[1]!=="n"&&d[1]!=="N")&&(d=p3.get(d)||d,pf(s,d,p))}}function bv(s,l,d,p,O,b){switch(d){case"style":uS(s,p,b);break;case"dangerouslySetInnerHTML":if(p!=null){if(typeof p!="object"||!("__html"in p))throw Error(r(61));if(d=p.__html,d!=null){if(O.children!=null)throw Error(r(60));s.innerHTML=d}}break;case"children":typeof p=="string"?ul(s,p):(typeof p=="number"||typeof p=="bigint")&&ul(s,""+p);break;case"onScroll":p!=null&>("scroll",s);break;case"onScrollEnd":p!=null&>("scrollend",s);break;case"onClick":p!=null&&(s.onclick=va);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"innerHTML":case"ref":break;case"innerText":case"textContent":break;default:if(!tS.hasOwnProperty(d))e:{if(d[0]==="o"&&d[1]==="n"&&(O=d.endsWith("Capture"),l=d.slice(2,O?d.length-7:void 0),b=s[pr]||null,b=b!=null?b[d]:null,typeof b=="function"&&s.removeEventListener(l,b,O),typeof p=="function")){typeof b!="function"&&b!==null&&(d in s?s[d]=null:s.hasAttribute(d)&&s.removeAttribute(d)),s.addEventListener(l,p,O);break e}d in s?s[d]=p:p===!0?s.setAttribute(d,""):pf(s,d,p)}}}function Xn(s,l,d){switch(l){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"img":gt("error",s),gt("load",s);var p=!1,O=!1,b;for(b in d)if(d.hasOwnProperty(b)){var Q=d[b];if(Q!=null)switch(b){case"src":p=!0;break;case"srcSet":O=!0;break;case"children":case"dangerouslySetInnerHTML":throw Error(r(137,l));default:zt(s,l,b,Q,d,null)}}O&&zt(s,l,"srcSet",d.srcSet,d,null),p&&zt(s,l,"src",d.src,d,null);return;case"input":gt("invalid",s);var j=b=Q=O=null,Z=null,ie=null;for(p in d)if(d.hasOwnProperty(p)){var me=d[p];if(me!=null)switch(p){case"name":O=me;break;case"type":Q=me;break;case"checked":Z=me;break;case"defaultChecked":ie=me;break;case"value":b=me;break;case"defaultValue":j=me;break;case"children":case"dangerouslySetInnerHTML":if(me!=null)throw Error(r(137,l));break;default:zt(s,l,p,me,d,null)}}sS(s,b,j,Z,ie,Q,O,!1);return;case"select":gt("invalid",s),p=Q=b=null;for(O in d)if(d.hasOwnProperty(O)&&(j=d[O],j!=null))switch(O){case"value":b=j;break;case"defaultValue":Q=j;break;case"multiple":p=j;default:zt(s,l,O,j,d,null)}l=b,d=Q,s.multiple=!!p,l!=null?cl(s,!!p,l,!1):d!=null&&cl(s,!!p,d,!0);return;case"textarea":gt("invalid",s),b=O=p=null;for(Q in d)if(d.hasOwnProperty(Q)&&(j=d[Q],j!=null))switch(Q){case"value":p=j;break;case"defaultValue":O=j;break;case"children":b=j;break;case"dangerouslySetInnerHTML":if(j!=null)throw Error(r(91));break;default:zt(s,l,Q,j,d,null)}lS(s,p,O,b);return;case"option":for(Z in d)d.hasOwnProperty(Z)&&(p=d[Z],p!=null)&&(Z==="selected"?s.selected=p&&typeof p!="function"&&typeof p!="symbol":zt(s,l,Z,p,d,null));return;case"dialog":gt("beforetoggle",s),gt("toggle",s),gt("cancel",s),gt("close",s);break;case"iframe":case"object":gt("load",s);break;case"video":case"audio":for(p=0;p<Au.length;p++)gt(Au[p],s);break;case"image":gt("error",s),gt("load",s);break;case"details":gt("toggle",s);break;case"embed":case"source":case"link":gt("error",s),gt("load",s);case"area":case"base":case"br":case"col":case"hr":case"keygen":case"meta":case"param":case"track":case"wbr":case"menuitem":for(ie in d)if(d.hasOwnProperty(ie)&&(p=d[ie],p!=null))switch(ie){case"children":case"dangerouslySetInnerHTML":throw Error(r(137,l));default:zt(s,l,ie,p,d,null)}return;default:if(jg(l)){for(me in d)d.hasOwnProperty(me)&&(p=d[me],p!==void 0&&bv(s,l,me,p,d,void 0));return}}for(j in d)d.hasOwnProperty(j)&&(p=d[j],p!=null&&zt(s,l,j,p,d,null))}function VD(s,l,d,p){switch(l){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"input":var O=null,b=null,Q=null,j=null,Z=null,ie=null,me=null;for(de in d){var be=d[de];if(d.hasOwnProperty(de)&&be!=null)switch(de){case"checked":break;case"value":break;case"defaultValue":Z=be;default:p.hasOwnProperty(de)||zt(s,l,de,null,p,be)}}for(var ae in p){var de=p[ae];if(be=d[ae],p.hasOwnProperty(ae)&&(de!=null||be!=null))switch(ae){case"type":b=de;break;case"name":O=de;break;case"checked":ie=de;break;case"defaultChecked":me=de;break;case"value":Q=de;break;case"defaultValue":j=de;break;case"children":case"dangerouslySetInnerHTML":if(de!=null)throw Error(r(137,l));break;default:de!==be&&zt(s,l,ae,de,p,be)}}$g(s,Q,j,Z,ie,me,b,O);return;case"select":de=Q=j=ae=null;for(b in d)if(Z=d[b],d.hasOwnProperty(b)&&Z!=null)switch(b){case"value":break;case"multiple":de=Z;default:p.hasOwnProperty(b)||zt(s,l,b,null,p,Z)}for(O in p)if(b=p[O],Z=d[O],p.hasOwnProperty(O)&&(b!=null||Z!=null))switch(O){case"value":ae=b;break;case"defaultValue":j=b;break;case"multiple":Q=b;default:b!==Z&&zt(s,l,O,b,p,Z)}l=j,d=Q,p=de,ae!=null?cl(s,!!d,ae,!1):!!p!=!!d&&(l!=null?cl(s,!!d,l,!0):cl(s,!!d,d?[]:"",!1));return;case"textarea":de=ae=null;for(j in d)if(O=d[j],d.hasOwnProperty(j)&&O!=null&&!p.hasOwnProperty(j))switch(j){case"value":break;case"children":break;default:zt(s,l,j,null,p,O)}for(Q in p)if(O=p[Q],b=d[Q],p.hasOwnProperty(Q)&&(O!=null||b!=null))switch(Q){case"value":ae=O;break;case"defaultValue":de=O;break;case"children":break;case"dangerouslySetInnerHTML":if(O!=null)throw Error(r(91));break;default:O!==b&&zt(s,l,Q,O,p,b)}oS(s,ae,de);return;case"option":for(var je in d)ae=d[je],d.hasOwnProperty(je)&&ae!=null&&!p.hasOwnProperty(je)&&(je==="selected"?s.selected=!1:zt(s,l,je,null,p,ae));for(Z in p)ae=p[Z],de=d[Z],p.hasOwnProperty(Z)&&ae!==de&&(ae!=null||de!=null)&&(Z==="selected"?s.selected=ae&&typeof ae!="function"&&typeof ae!="symbol":zt(s,l,Z,ae,p,de));return;case"img":case"link":case"area":case"base":case"br":case"col":case"embed":case"hr":case"keygen":case"meta":case"param":case"source":case"track":case"wbr":case"menuitem":for(var Fe in d)ae=d[Fe],d.hasOwnProperty(Fe)&&ae!=null&&!p.hasOwnProperty(Fe)&&zt(s,l,Fe,null,p,ae);for(ie in p)if(ae=p[ie],de=d[ie],p.hasOwnProperty(ie)&&ae!==de&&(ae!=null||de!=null))switch(ie){case"children":case"dangerouslySetInnerHTML":if(ae!=null)throw Error(r(137,l));break;default:zt(s,l,ie,ae,p,de)}return;default:if(jg(l)){for(var Lt in d)ae=d[Lt],d.hasOwnProperty(Lt)&&ae!==void 0&&!p.hasOwnProperty(Lt)&&bv(s,l,Lt,void 0,p,ae);for(me in p)ae=p[me],de=d[me],!p.hasOwnProperty(me)||ae===de||ae===void 0&&de===void 0||bv(s,l,me,ae,p,de);return}}for(var K in d)ae=d[K],d.hasOwnProperty(K)&&ae!=null&&!p.hasOwnProperty(K)&&zt(s,l,K,null,p,ae);for(be in p)ae=p[be],de=d[be],!p.hasOwnProperty(be)||ae===de||ae==null&&de==null||zt(s,l,be,ae,p,de)}function dC(s){switch(s){case"css":case"script":case"font":case"img":case"image":case"input":case"link":return!0;default:return!1}}function XD(){if(typeof performance.getEntriesByType=="function"){for(var s=0,l=0,d=performance.getEntriesByType("resource"),p=0;p<d.length;p++){var O=d[p],b=O.transferSize,Q=O.initiatorType,j=O.duration;if(b&&j&&dC(Q)){for(Q=0,j=O.responseEnd,p+=1;p<d.length;p++){var Z=d[p],ie=Z.startTime;if(ie>j)break;var me=Z.transferSize,be=Z.initiatorType;me&&dC(be)&&(Z=Z.responseEnd,Q+=me*(Z<j?1:(j-ie)/(Z-ie)))}if(--p,l+=8*(b+Q)/(O.duration/1e3),s++,10<s)break}}if(0<s)return l/s/1e6}return navigator.connection&&(s=navigator.connection.downlink,typeof s=="number")?s:5}var xv=null,Sv=null;function fh(s){return s.nodeType===9?s:s.ownerDocument}function fC(s){switch(s){case"http://www.w3.org/2000/svg":return 1;case"http://www.w3.org/1998/Math/MathML":return 2;default:return 0}}function hC(s,l){if(s===0)switch(l){case"svg":return 1;case"math":return 2;default:return 0}return s===1&&l==="foreignObject"?0:s}function wv(s,l){return s==="textarea"||s==="noscript"||typeof l.children=="string"||typeof l.children=="number"||typeof l.children=="bigint"||typeof l.dangerouslySetInnerHTML=="object"&&l.dangerouslySetInnerHTML!==null&&l.dangerouslySetInnerHTML.__html!=null}var kv=null;function BD(){var s=window.event;return s&&s.type==="popstate"?s===kv?!1:(kv=s,!0):(kv=null,!1)}var pC=typeof setTimeout=="function"?setTimeout:void 0,ID=typeof clearTimeout=="function"?clearTimeout:void 0,mC=typeof Promise=="function"?Promise:void 0,qD=typeof queueMicrotask=="function"?queueMicrotask:typeof mC<"u"?function(s){return mC.resolve(null).then(s).catch(UD)}:pC;function UD(s){setTimeout(function(){throw s})}function ys(s){return s==="head"}function gC(s,l){var d=l,p=0;do{var O=d.nextSibling;if(s.removeChild(d),O&&O.nodeType===8)if(d=O.data,d==="/$"||d==="/&"){if(p===0){s.removeChild(O),Vl(l);return}p--}else if(d==="$"||d==="$?"||d==="$~"||d==="$!"||d==="&")p++;else if(d==="html")_u(s.ownerDocument.documentElement);else if(d==="head"){d=s.ownerDocument.head,_u(d);for(var b=d.firstChild;b;){var Q=b.nextSibling,j=b.nodeName;b[Wc]||j==="SCRIPT"||j==="STYLE"||j==="LINK"&&b.rel.toLowerCase()==="stylesheet"||d.removeChild(b),b=Q}}else d==="body"&&_u(s.ownerDocument.body);d=O}while(d);Vl(l)}function OC(s,l){var d=s;s=0;do{var p=d.nextSibling;if(d.nodeType===1?l?(d._stashedDisplay=d.style.display,d.style.display="none"):(d.style.display=d._stashedDisplay||"",d.getAttribute("style")===""&&d.removeAttribute("style")):d.nodeType===3&&(l?(d._stashedText=d.nodeValue,d.nodeValue=""):d.nodeValue=d._stashedText||""),p&&p.nodeType===8)if(d=p.data,d==="/$"){if(s===0)break;s--}else d!=="$"&&d!=="$?"&&d!=="$~"&&d!=="$!"||s++;d=p}while(d)}function Cv(s){var l=s.firstChild;for(l&&l.nodeType===10&&(l=l.nextSibling);l;){var d=l;switch(l=l.nextSibling,d.nodeName){case"HTML":case"HEAD":case"BODY":Cv(d),Rg(d);continue;case"SCRIPT":case"STYLE":continue;case"LINK":if(d.rel.toLowerCase()==="stylesheet")continue}s.removeChild(d)}}function YD(s,l,d,p){for(;s.nodeType===1;){var O=d;if(s.nodeName.toLowerCase()!==l.toLowerCase()){if(!p&&(s.nodeName!=="INPUT"||s.type!=="hidden"))break}else if(p){if(!s[Wc])switch(l){case"meta":if(!s.hasAttribute("itemprop"))break;return s;case"link":if(b=s.getAttribute("rel"),b==="stylesheet"&&s.hasAttribute("data-precedence"))break;if(b!==O.rel||s.getAttribute("href")!==(O.href==null||O.href===""?null:O.href)||s.getAttribute("crossorigin")!==(O.crossOrigin==null?null:O.crossOrigin)||s.getAttribute("title")!==(O.title==null?null:O.title))break;return s;case"style":if(s.hasAttribute("data-precedence"))break;return s;case"script":if(b=s.getAttribute("src"),(b!==(O.src==null?null:O.src)||s.getAttribute("type")!==(O.type==null?null:O.type)||s.getAttribute("crossorigin")!==(O.crossOrigin==null?null:O.crossOrigin))&&b&&s.hasAttribute("async")&&!s.hasAttribute("itemprop"))break;return s;default:return s}}else if(l==="input"&&s.type==="hidden"){var b=O.name==null?null:""+O.name;if(O.type==="hidden"&&s.getAttribute("name")===b)return s}else return s;if(s=ei(s.nextSibling),s===null)break}return null}function FD(s,l,d){if(l==="")return null;for(;s.nodeType!==3;)if((s.nodeType!==1||s.nodeName!=="INPUT"||s.type!=="hidden")&&!d||(s=ei(s.nextSibling),s===null))return null;return s}function vC(s,l){for(;s.nodeType!==8;)if((s.nodeType!==1||s.nodeName!=="INPUT"||s.type!=="hidden")&&!l||(s=ei(s.nextSibling),s===null))return null;return s}function Tv(s){return s.data==="$?"||s.data==="$~"}function Ev(s){return s.data==="$!"||s.data==="$?"&&s.ownerDocument.readyState!=="loading"}function WD(s,l){var d=s.ownerDocument;if(s.data==="$~")s._reactRetry=l;else if(s.data!=="$?"||d.readyState!=="loading")l();else{var p=function(){l(),d.removeEventListener("DOMContentLoaded",p)};d.addEventListener("DOMContentLoaded",p),s._reactRetry=p}}function ei(s){for(;s!=null;s=s.nextSibling){var l=s.nodeType;if(l===1||l===3)break;if(l===8){if(l=s.data,l==="$"||l==="$!"||l==="$?"||l==="$~"||l==="&"||l==="F!"||l==="F")break;if(l==="/$"||l==="/&")return null}}return s}var Qv=null;function yC(s){s=s.nextSibling;for(var l=0;s;){if(s.nodeType===8){var d=s.data;if(d==="/$"||d==="/&"){if(l===0)return ei(s.nextSibling);l--}else d!=="$"&&d!=="$!"&&d!=="$?"&&d!=="$~"&&d!=="&"||l++}s=s.nextSibling}return null}function bC(s){s=s.previousSibling;for(var l=0;s;){if(s.nodeType===8){var d=s.data;if(d==="$"||d==="$!"||d==="$?"||d==="$~"||d==="&"){if(l===0)return s;l--}else d!=="/$"&&d!=="/&"||l++}s=s.previousSibling}return null}function xC(s,l,d){switch(l=fh(d),s){case"html":if(s=l.documentElement,!s)throw Error(r(452));return s;case"head":if(s=l.head,!s)throw Error(r(453));return s;case"body":if(s=l.body,!s)throw Error(r(454));return s;default:throw Error(r(451))}}function _u(s){for(var l=s.attributes;l.length;)s.removeAttributeNode(l[0]);Rg(s)}var ti=new Map,SC=new Set;function hh(s){return typeof s.getRootNode=="function"?s.getRootNode():s.nodeType===9?s:s.ownerDocument}var ja=G.d;G.d={f:GD,r:HD,D:KD,C:JD,L:ez,m:tz,X:rz,S:nz,M:iz};function GD(){var s=ja.f(),l=ih();return s||l}function HD(s){var l=sl(s);l!==null&&l.tag===5&&l.type==="form"?Lw(l):ja.r(s)}var zl=typeof document>"u"?null:document;function wC(s,l,d){var p=zl;if(p&&typeof l=="string"&&l){var O=Yr(l);O='link[rel="'+s+'"][href="'+O+'"]',typeof d=="string"&&(O+='[crossorigin="'+d+'"]'),SC.has(O)||(SC.add(O),s={rel:s,crossOrigin:d,href:l},p.querySelector(O)===null&&(l=p.createElement("link"),Xn(l,"link",s),$n(l),p.head.appendChild(l)))}}function KD(s){ja.D(s),wC("dns-prefetch",s,null)}function JD(s,l){ja.C(s,l),wC("preconnect",s,l)}function ez(s,l,d){ja.L(s,l,d);var p=zl;if(p&&s&&l){var O='link[rel="preload"][as="'+Yr(l)+'"]';l==="image"&&d&&d.imageSrcSet?(O+='[imagesrcset="'+Yr(d.imageSrcSet)+'"]',typeof d.imageSizes=="string"&&(O+='[imagesizes="'+Yr(d.imageSizes)+'"]')):O+='[href="'+Yr(s)+'"]';var b=O;switch(l){case"style":b=Ll(s);break;case"script":b=Zl(s)}ti.has(b)||(s=m({rel:"preload",href:l==="image"&&d&&d.imageSrcSet?void 0:s,as:l},d),ti.set(b,s),p.querySelector(O)!==null||l==="style"&&p.querySelector($u(b))||l==="script"&&p.querySelector(Pu(b))||(l=p.createElement("link"),Xn(l,"link",s),$n(l),p.head.appendChild(l)))}}function tz(s,l){ja.m(s,l);var d=zl;if(d&&s){var p=l&&typeof l.as=="string"?l.as:"script",O='link[rel="modulepreload"][as="'+Yr(p)+'"][href="'+Yr(s)+'"]',b=O;switch(p){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":b=Zl(s)}if(!ti.has(b)&&(s=m({rel:"modulepreload",href:s},l),ti.set(b,s),d.querySelector(O)===null)){switch(p){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(d.querySelector(Pu(b)))return}p=d.createElement("link"),Xn(p,"link",s),$n(p),d.head.appendChild(p)}}}function nz(s,l,d){ja.S(s,l,d);var p=zl;if(p&&s){var O=ol(p).hoistableStyles,b=Ll(s);l=l||"default";var Q=O.get(b);if(!Q){var j={loading:0,preload:null};if(Q=p.querySelector($u(b)))j.loading=5;else{s=m({rel:"stylesheet",href:s,"data-precedence":l},d),(d=ti.get(b))&&Av(s,d);var Z=Q=p.createElement("link");$n(Z),Xn(Z,"link",s),Z._p=new Promise(function(ie,me){Z.onload=ie,Z.onerror=me}),Z.addEventListener("load",function(){j.loading|=1}),Z.addEventListener("error",function(){j.loading|=2}),j.loading|=4,ph(Q,l,p)}Q={type:"stylesheet",instance:Q,count:1,state:j},O.set(b,Q)}}}function rz(s,l){ja.X(s,l);var d=zl;if(d&&s){var p=ol(d).hoistableScripts,O=Zl(s),b=p.get(O);b||(b=d.querySelector(Pu(O)),b||(s=m({src:s,async:!0},l),(l=ti.get(O))&&Rv(s,l),b=d.createElement("script"),$n(b),Xn(b,"link",s),d.head.appendChild(b)),b={type:"script",instance:b,count:1,state:null},p.set(O,b))}}function iz(s,l){ja.M(s,l);var d=zl;if(d&&s){var p=ol(d).hoistableScripts,O=Zl(s),b=p.get(O);b||(b=d.querySelector(Pu(O)),b||(s=m({src:s,async:!0,type:"module"},l),(l=ti.get(O))&&Rv(s,l),b=d.createElement("script"),$n(b),Xn(b,"link",s),d.head.appendChild(b)),b={type:"script",instance:b,count:1,state:null},p.set(O,b))}}function kC(s,l,d,p){var O=(O=he.current)?hh(O):null;if(!O)throw Error(r(446));switch(s){case"meta":case"title":return null;case"style":return typeof d.precedence=="string"&&typeof d.href=="string"?(l=Ll(d.href),d=ol(O).hoistableStyles,p=d.get(l),p||(p={type:"style",instance:null,count:0,state:null},d.set(l,p)),p):{type:"void",instance:null,count:0,state:null};case"link":if(d.rel==="stylesheet"&&typeof d.href=="string"&&typeof d.precedence=="string"){s=Ll(d.href);var b=ol(O).hoistableStyles,Q=b.get(s);if(Q||(O=O.ownerDocument||O,Q={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},b.set(s,Q),(b=O.querySelector($u(s)))&&!b._p&&(Q.instance=b,Q.state.loading=5),ti.has(s)||(d={rel:"preload",as:"style",href:d.href,crossOrigin:d.crossOrigin,integrity:d.integrity,media:d.media,hrefLang:d.hrefLang,referrerPolicy:d.referrerPolicy},ti.set(s,d),b||az(O,s,d,Q.state))),l&&p===null)throw Error(r(528,""));return Q}if(l&&p!==null)throw Error(r(529,""));return null;case"script":return l=d.async,d=d.src,typeof d=="string"&&l&&typeof l!="function"&&typeof l!="symbol"?(l=Zl(d),d=ol(O).hoistableScripts,p=d.get(l),p||(p={type:"script",instance:null,count:0,state:null},d.set(l,p)),p):{type:"void",instance:null,count:0,state:null};default:throw Error(r(444,s))}}function Ll(s){return'href="'+Yr(s)+'"'}function $u(s){return'link[rel="stylesheet"]['+s+"]"}function CC(s){return m({},s,{"data-precedence":s.precedence,precedence:null})}function az(s,l,d,p){s.querySelector('link[rel="preload"][as="style"]['+l+"]")?p.loading=1:(l=s.createElement("link"),p.preload=l,l.addEventListener("load",function(){return p.loading|=1}),l.addEventListener("error",function(){return p.loading|=2}),Xn(l,"link",d),$n(l),s.head.appendChild(l))}function Zl(s){return'[src="'+Yr(s)+'"]'}function Pu(s){return"script[async]"+s}function TC(s,l,d){if(l.count++,l.instance===null)switch(l.type){case"style":var p=s.querySelector('style[data-href~="'+Yr(d.href)+'"]');if(p)return l.instance=p,$n(p),p;var O=m({},d,{"data-href":d.href,"data-precedence":d.precedence,href:null,precedence:null});return p=(s.ownerDocument||s).createElement("style"),$n(p),Xn(p,"style",O),ph(p,d.precedence,s),l.instance=p;case"stylesheet":O=Ll(d.href);var b=s.querySelector($u(O));if(b)return l.state.loading|=4,l.instance=b,$n(b),b;p=CC(d),(O=ti.get(O))&&Av(p,O),b=(s.ownerDocument||s).createElement("link"),$n(b);var Q=b;return Q._p=new Promise(function(j,Z){Q.onload=j,Q.onerror=Z}),Xn(b,"link",p),l.state.loading|=4,ph(b,d.precedence,s),l.instance=b;case"script":return b=Zl(d.src),(O=s.querySelector(Pu(b)))?(l.instance=O,$n(O),O):(p=d,(O=ti.get(b))&&(p=m({},d),Rv(p,O)),s=s.ownerDocument||s,O=s.createElement("script"),$n(O),Xn(O,"link",p),s.head.appendChild(O),l.instance=O);case"void":return null;default:throw Error(r(443,l.type))}else l.type==="stylesheet"&&(l.state.loading&4)===0&&(p=l.instance,l.state.loading|=4,ph(p,d.precedence,s));return l.instance}function ph(s,l,d){for(var p=d.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),O=p.length?p[p.length-1]:null,b=O,Q=0;Q<p.length;Q++){var j=p[Q];if(j.dataset.precedence===l)b=j;else if(b!==O)break}b?b.parentNode.insertBefore(s,b.nextSibling):(l=d.nodeType===9?d.head:d,l.insertBefore(s,l.firstChild))}function Av(s,l){s.crossOrigin==null&&(s.crossOrigin=l.crossOrigin),s.referrerPolicy==null&&(s.referrerPolicy=l.referrerPolicy),s.title==null&&(s.title=l.title)}function Rv(s,l){s.crossOrigin==null&&(s.crossOrigin=l.crossOrigin),s.referrerPolicy==null&&(s.referrerPolicy=l.referrerPolicy),s.integrity==null&&(s.integrity=l.integrity)}var mh=null;function EC(s,l,d){if(mh===null){var p=new Map,O=mh=new Map;O.set(d,p)}else O=mh,p=O.get(d),p||(p=new Map,O.set(d,p));if(p.has(s))return p;for(p.set(s,null),d=d.getElementsByTagName(s),O=0;O<d.length;O++){var b=d[O];if(!(b[Wc]||b[zn]||s==="link"&&b.getAttribute("rel")==="stylesheet")&&b.namespaceURI!=="http://www.w3.org/2000/svg"){var Q=b.getAttribute(l)||"";Q=s+Q;var j=p.get(Q);j?j.push(b):p.set(Q,[b])}}return p}function QC(s,l,d){s=s.ownerDocument||s,s.head.insertBefore(d,l==="title"?s.querySelector("head > title"):null)}function sz(s,l,d){if(d===1||l.itemProp!=null)return!1;switch(s){case"meta":case"title":return!0;case"style":if(typeof l.precedence!="string"||typeof l.href!="string"||l.href==="")break;return!0;case"link":if(typeof l.rel!="string"||typeof l.href!="string"||l.href===""||l.onLoad||l.onError)break;return l.rel==="stylesheet"?(s=l.disabled,typeof l.precedence=="string"&&s==null):!0;case"script":if(l.async&&typeof l.async!="function"&&typeof l.async!="symbol"&&!l.onLoad&&!l.onError&&l.src&&typeof l.src=="string")return!0}return!1}function AC(s){return!(s.type==="stylesheet"&&(s.state.loading&3)===0)}function oz(s,l,d,p){if(d.type==="stylesheet"&&(typeof p.media!="string"||matchMedia(p.media).matches!==!1)&&(d.state.loading&4)===0){if(d.instance===null){var O=Ll(p.href),b=l.querySelector($u(O));if(b){l=b._p,l!==null&&typeof l=="object"&&typeof l.then=="function"&&(s.count++,s=gh.bind(s),l.then(s,s)),d.state.loading|=4,d.instance=b,$n(b);return}b=l.ownerDocument||l,p=CC(p),(O=ti.get(O))&&Av(p,O),b=b.createElement("link"),$n(b);var Q=b;Q._p=new Promise(function(j,Z){Q.onload=j,Q.onerror=Z}),Xn(b,"link",p),d.instance=b}s.stylesheets===null&&(s.stylesheets=new Map),s.stylesheets.set(d,l),(l=d.state.preload)&&(d.state.loading&3)===0&&(s.count++,d=gh.bind(s),l.addEventListener("load",d),l.addEventListener("error",d))}}var _v=0;function lz(s,l){return s.stylesheets&&s.count===0&&vh(s,s.stylesheets),0<s.count||0<s.imgCount?function(d){var p=setTimeout(function(){if(s.stylesheets&&vh(s,s.stylesheets),s.unsuspend){var b=s.unsuspend;s.unsuspend=null,b()}},6e4+l);0<s.imgBytes&&_v===0&&(_v=62500*XD());var O=setTimeout(function(){if(s.waitingForImages=!1,s.count===0&&(s.stylesheets&&vh(s,s.stylesheets),s.unsuspend)){var b=s.unsuspend;s.unsuspend=null,b()}},(s.imgBytes>_v?50:800)+l);return s.unsuspend=d,function(){s.unsuspend=null,clearTimeout(p),clearTimeout(O)}}:null}function gh(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)vh(this,this.stylesheets);else if(this.unsuspend){var s=this.unsuspend;this.unsuspend=null,s()}}}var Oh=null;function vh(s,l){s.stylesheets=null,s.unsuspend!==null&&(s.count++,Oh=new Map,l.forEach(cz,s),Oh=null,gh.call(s))}function cz(s,l){if(!(l.state.loading&4)){var d=Oh.get(s);if(d)var p=d.get(null);else{d=new Map,Oh.set(s,d);for(var O=s.querySelectorAll("link[data-precedence],style[data-precedence]"),b=0;b<O.length;b++){var Q=O[b];(Q.nodeName==="LINK"||Q.getAttribute("media")!=="not all")&&(d.set(Q.dataset.precedence,Q),p=Q)}p&&d.set(null,p)}O=l.instance,Q=O.getAttribute("data-precedence"),b=d.get(Q)||p,b===p&&d.set(null,O),d.set(Q,O),this.count++,p=gh.bind(this),O.addEventListener("load",p),O.addEventListener("error",p),b?b.parentNode.insertBefore(O,b.nextSibling):(s=s.nodeType===9?s.head:s,s.insertBefore(O,s.firstChild)),l.state.loading|=4}}var ju={$$typeof:E,Provider:null,Consumer:null,_currentValue:B,_currentValue2:B,_threadCount:0};function uz(s,l,d,p,O,b,Q,j,Z){this.tag=1,this.containerInfo=s,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=es(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=es(0),this.hiddenUpdates=es(null),this.identifierPrefix=p,this.onUncaughtError=O,this.onCaughtError=b,this.onRecoverableError=Q,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=Z,this.incompleteTransitions=new Map}function RC(s,l,d,p,O,b,Q,j,Z,ie,me,be){return s=new uz(s,l,d,Q,Z,ie,me,be,j),l=1,b===!0&&(l|=24),b=_r(3,null,null,l),s.current=b,b.stateNode=s,l=uO(),l.refCount++,s.pooledCache=l,l.refCount++,b.memoizedState={element:p,isDehydrated:d,cache:l},pO(b),s}function _C(s){return s?(s=Ol,s):Ol}function $C(s,l,d,p,O,b){O=_C(O),p.context===null?p.context=O:p.pendingContext=O,p=ls(l),p.payload={element:d},b=b===void 0?null:b,b!==null&&(p.callback=b),d=cs(s,p,l),d!==null&&(br(d,s,l),fu(d,s,l))}function PC(s,l){if(s=s.memoizedState,s!==null&&s.dehydrated!==null){var d=s.retryLane;s.retryLane=d!==0&&d<l?d:l}}function $v(s,l){PC(s,l),(s=s.alternate)&&PC(s,l)}function jC(s){if(s.tag===13||s.tag===31){var l=oo(s,67108864);l!==null&&br(l,s,67108864),$v(s,67108864)}}function MC(s){if(s.tag===13||s.tag===31){var l=Nr();l=rl(l);var d=oo(s,l);d!==null&&br(d,s,l),$v(s,l)}}var yh=!0;function dz(s,l,d,p){var O=D.T;D.T=null;var b=G.p;try{G.p=2,Pv(s,l,d,p)}finally{G.p=b,D.T=O}}function fz(s,l,d,p){var O=D.T;D.T=null;var b=G.p;try{G.p=8,Pv(s,l,d,p)}finally{G.p=b,D.T=O}}function Pv(s,l,d,p){if(yh){var O=jv(p);if(O===null)yv(s,l,p,bh,d),DC(s,p);else if(pz(O,s,l,d,p))p.stopPropagation();else if(DC(s,p),l&4&&-1<hz.indexOf(s)){for(;O!==null;){var b=sl(O);if(b!==null)switch(b.tag){case 3:if(b=b.stateNode,b.current.memoizedState.isDehydrated){var Q=Vi(b.pendingLanes);if(Q!==0){var j=b;for(j.pendingLanes|=2,j.entangledLanes|=2;Q;){var Z=1<<31-rn(Q);j.entanglements[1]|=Z,Q&=~Z}qi(b),(Qt&6)===0&&(nh=te()+500,Qu(0))}}break;case 31:case 13:j=oo(b,2),j!==null&&br(j,b,2),ih(),$v(b,2)}if(b=jv(p),b===null&&yv(s,l,p,bh,d),b===O)break;O=b}O!==null&&p.stopPropagation()}else yv(s,l,p,null,d)}}function jv(s){return s=Ng(s),Mv(s)}var bh=null;function Mv(s){if(bh=null,s=al(s),s!==null){var l=a(s);if(l===null)s=null;else{var d=l.tag;if(d===13){if(s=o(l),s!==null)return s;s=null}else if(d===31){if(s=c(l),s!==null)return s;s=null}else if(d===3){if(l.stateNode.current.memoizedState.isDehydrated)return l.tag===3?l.stateNode.containerInfo:null;s=null}else l!==s&&(s=null)}}return bh=s,null}function NC(s){switch(s){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(fe()){case Oe:return 2;case Te:return 8;case Ye:case ot:return 32;case kt:return 268435456;default:return 32}default:return 32}}var Nv=!1,bs=null,xs=null,Ss=null,Mu=new Map,Nu=new Map,ws=[],hz="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 DC(s,l){switch(s){case"focusin":case"focusout":bs=null;break;case"dragenter":case"dragleave":xs=null;break;case"mouseover":case"mouseout":Ss=null;break;case"pointerover":case"pointerout":Mu.delete(l.pointerId);break;case"gotpointercapture":case"lostpointercapture":Nu.delete(l.pointerId)}}function Du(s,l,d,p,O,b){return s===null||s.nativeEvent!==b?(s={blockedOn:l,domEventName:d,eventSystemFlags:p,nativeEvent:b,targetContainers:[O]},l!==null&&(l=sl(l),l!==null&&jC(l)),s):(s.eventSystemFlags|=p,l=s.targetContainers,O!==null&&l.indexOf(O)===-1&&l.push(O),s)}function pz(s,l,d,p,O){switch(l){case"focusin":return bs=Du(bs,s,l,d,p,O),!0;case"dragenter":return xs=Du(xs,s,l,d,p,O),!0;case"mouseover":return Ss=Du(Ss,s,l,d,p,O),!0;case"pointerover":var b=O.pointerId;return Mu.set(b,Du(Mu.get(b)||null,s,l,d,p,O)),!0;case"gotpointercapture":return b=O.pointerId,Nu.set(b,Du(Nu.get(b)||null,s,l,d,p,O)),!0}return!1}function zC(s){var l=al(s.target);if(l!==null){var d=a(l);if(d!==null){if(l=d.tag,l===13){if(l=o(d),l!==null){s.blockedOn=l,K1(s.priority,function(){MC(d)});return}}else if(l===31){if(l=c(d),l!==null){s.blockedOn=l,K1(s.priority,function(){MC(d)});return}}else if(l===3&&d.stateNode.current.memoizedState.isDehydrated){s.blockedOn=d.tag===3?d.stateNode.containerInfo:null;return}}}s.blockedOn=null}function xh(s){if(s.blockedOn!==null)return!1;for(var l=s.targetContainers;0<l.length;){var d=jv(s.nativeEvent);if(d===null){d=s.nativeEvent;var p=new d.constructor(d.type,d);Mg=p,d.target.dispatchEvent(p),Mg=null}else return l=sl(d),l!==null&&jC(l),s.blockedOn=d,!1;l.shift()}return!0}function LC(s,l,d){xh(s)&&d.delete(l)}function mz(){Nv=!1,bs!==null&&xh(bs)&&(bs=null),xs!==null&&xh(xs)&&(xs=null),Ss!==null&&xh(Ss)&&(Ss=null),Mu.forEach(LC),Nu.forEach(LC)}function Sh(s,l){s.blockedOn===l&&(s.blockedOn=null,Nv||(Nv=!0,t.unstable_scheduleCallback(t.unstable_NormalPriority,mz)))}var wh=null;function ZC(s){wh!==s&&(wh=s,t.unstable_scheduleCallback(t.unstable_NormalPriority,function(){wh===s&&(wh=null);for(var l=0;l<s.length;l+=3){var d=s[l],p=s[l+1],O=s[l+2];if(typeof p!="function"){if(Mv(p||d)===null)continue;break}var b=sl(d);b!==null&&(s.splice(l,3),l-=3,jO(b,{pending:!0,data:O,method:d.method,action:p},p,O))}}))}function Vl(s){function l(Z){return Sh(Z,s)}bs!==null&&Sh(bs,s),xs!==null&&Sh(xs,s),Ss!==null&&Sh(Ss,s),Mu.forEach(l),Nu.forEach(l);for(var d=0;d<ws.length;d++){var p=ws[d];p.blockedOn===s&&(p.blockedOn=null)}for(;0<ws.length&&(d=ws[0],d.blockedOn===null);)zC(d),d.blockedOn===null&&ws.shift();if(d=(s.ownerDocument||s).$$reactFormReplay,d!=null)for(p=0;p<d.length;p+=3){var O=d[p],b=d[p+1],Q=O[pr]||null;if(typeof b=="function")Q||ZC(d);else if(Q){var j=null;if(b&&b.hasAttribute("formAction")){if(O=b,Q=b[pr]||null)j=Q.formAction;else if(Mv(O)!==null)continue}else j=Q.action;typeof j=="function"?d[p+1]=j:(d.splice(p,3),p-=3),ZC(d)}}}function VC(){function s(b){b.canIntercept&&b.info==="react-transition"&&b.intercept({handler:function(){return new Promise(function(Q){return O=Q})},focusReset:"manual",scroll:"manual"})}function l(){O!==null&&(O(),O=null),p||setTimeout(d,20)}function d(){if(!p&&!navigation.transition){var b=navigation.currentEntry;b&&b.url!=null&&navigation.navigate(b.url,{state:b.getState(),info:"react-transition",history:"replace"})}}if(typeof navigation=="object"){var p=!1,O=null;return navigation.addEventListener("navigate",s),navigation.addEventListener("navigatesuccess",l),navigation.addEventListener("navigateerror",l),setTimeout(d,100),function(){p=!0,navigation.removeEventListener("navigate",s),navigation.removeEventListener("navigatesuccess",l),navigation.removeEventListener("navigateerror",l),O!==null&&(O(),O=null)}}}function Dv(s){this._internalRoot=s}kh.prototype.render=Dv.prototype.render=function(s){var l=this._internalRoot;if(l===null)throw Error(r(409));var d=l.current,p=Nr();$C(d,p,s,l,null,null)},kh.prototype.unmount=Dv.prototype.unmount=function(){var s=this._internalRoot;if(s!==null){this._internalRoot=null;var l=s.containerInfo;$C(s.current,2,null,s,null,null),ih(),l[il]=null}};function kh(s){this._internalRoot=s}kh.prototype.unstable_scheduleHydration=function(s){if(s){var l=Qg();s={blockedOn:null,target:s,priority:l};for(var d=0;d<ws.length&&l!==0&&l<ws[d].priority;d++);ws.splice(d,0,s),d===0&&zC(s)}};var XC=e.version;if(XC!=="19.2.3")throw Error(r(527,XC,"19.2.3"));G.findDOMNode=function(s){var l=s._reactInternals;if(l===void 0)throw typeof s.render=="function"?Error(r(188)):(s=Object.keys(s).join(","),Error(r(268,s)));return s=f(l),s=s!==null?h(s):null,s=s===null?null:s.stateNode,s};var gz={bundleType:0,version:"19.2.3",rendererPackageName:"react-dom",currentDispatcherRef:D,reconcilerVersion:"19.2.3"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var Ch=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Ch.isDisabled&&Ch.supportsFiber)try{er=Ch.inject(gz),Wt=Ch}catch{}}return Lu.createRoot=function(s,l){if(!i(s))throw Error(r(299));var d=!1,p="",O=Ww,b=Gw,Q=Hw;return l!=null&&(l.unstable_strictMode===!0&&(d=!0),l.identifierPrefix!==void 0&&(p=l.identifierPrefix),l.onUncaughtError!==void 0&&(O=l.onUncaughtError),l.onCaughtError!==void 0&&(b=l.onCaughtError),l.onRecoverableError!==void 0&&(Q=l.onRecoverableError)),l=RC(s,1,!1,null,null,d,p,null,O,b,Q,VC),s[il]=l.current,vv(s),new Dv(l)},Lu.hydrateRoot=function(s,l,d){if(!i(s))throw Error(r(299));var p=!1,O="",b=Ww,Q=Gw,j=Hw,Z=null;return d!=null&&(d.unstable_strictMode===!0&&(p=!0),d.identifierPrefix!==void 0&&(O=d.identifierPrefix),d.onUncaughtError!==void 0&&(b=d.onUncaughtError),d.onCaughtError!==void 0&&(Q=d.onCaughtError),d.onRecoverableError!==void 0&&(j=d.onRecoverableError),d.formState!==void 0&&(Z=d.formState)),l=RC(s,1,!0,l,d??null,p,O,Z,b,Q,j,VC),l.context=_C(null),d=l.current,p=Nr(),p=rl(p),O=ls(p),O.callback=null,cs(d,O,p),d=p,l.current.lanes=d,Jt(l,d),qi(l),s[il]=l.current,vv(s),new kh(l)},Lu.version="19.2.3",Lu}var KC;function Tz(){if(KC)return Zv.exports;KC=1;function t(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(t)}catch(e){console.error(e)}}return t(),Zv.exports=Cz(),Zv.exports}var Ez=Tz();const Qz={theme:"system",setTheme:()=>null},$A=w.createContext(Qz);function Az({children:t,defaultTheme:e="system",storageKey:n="iconoma-studio-theme",...r}){const[i,a]=w.useState(()=>(typeof window<"u"?localStorage.getItem(n):e)||e);w.useEffect(()=>{const c=window.document.documentElement;if(c.classList.remove("light","dark"),i==="system"){const u=window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light";c.classList.add(u);return}c.classList.add(i)},[i]);const o={theme:i,setTheme:c=>{a(c),!(typeof window>"u")&&localStorage.setItem(n,c)}};return v.jsx($A.Provider,{...r,value:o,children:t})}const PA=()=>{const t=w.useContext($A);if(t===void 0)throw new Error("useTheme must be used within a ThemeProvider");return t};var JC="popstate";function Rz(t={}){function e(r,i){let{pathname:a,search:o,hash:c}=r.location;return s0("",{pathname:a,search:o,hash:c},i.state&&i.state.usr||null,i.state&&i.state.key||"default")}function n(r,i){return typeof i=="string"?i:Mo(i)}return $z(e,n,null,t)}function nn(t,e){if(t===!1||t===null||typeof t>"u")throw new Error(e)}function li(t,e){if(!t){typeof console<"u"&&console.warn(e);try{throw new Error(e)}catch{}}}function _z(){return Math.random().toString(36).substring(2,10)}function eT(t,e){return{usr:t.state,key:t.key,idx:e}}function s0(t,e,n=null,r){return{pathname:typeof t=="string"?t:t.pathname,search:"",hash:"",...typeof e=="string"?Go(e):e,state:n,key:e&&e.key||r||_z()}}function Mo({pathname:t="/",search:e="",hash:n=""}){return e&&e!=="?"&&(t+=e.charAt(0)==="?"?e:"?"+e),n&&n!=="#"&&(t+=n.charAt(0)==="#"?n:"#"+n),t}function Go(t){let e={};if(t){let n=t.indexOf("#");n>=0&&(e.hash=t.substring(n),t=t.substring(0,n));let r=t.indexOf("?");r>=0&&(e.search=t.substring(r),t=t.substring(0,r)),t&&(e.pathname=t)}return e}function $z(t,e,n,r={}){let{window:i=document.defaultView,v5Compat:a=!1}=r,o=i.history,c="POP",u=null,f=h();f==null&&(f=0,o.replaceState({...o.state,idx:f},""));function h(){return(o.state||{idx:null}).idx}function m(){c="POP";let k=h(),T=k==null?null:k-f;f=k,u&&u({action:c,location:S.location,delta:T})}function g(k,T){c="PUSH";let C=s0(S.location,k,T);f=h()+1;let E=eT(C,f),R=S.createHref(C);try{o.pushState(E,"",R)}catch($){if($ instanceof DOMException&&$.name==="DataCloneError")throw $;i.location.assign(R)}a&&u&&u({action:c,location:S.location,delta:1})}function y(k,T){c="REPLACE";let C=s0(S.location,k,T);f=h();let E=eT(C,f),R=S.createHref(C);o.replaceState(E,"",R),a&&u&&u({action:c,location:S.location,delta:0})}function x(k){return Pz(k)}let S={get action(){return c},get location(){return t(i,o)},listen(k){if(u)throw new Error("A history only accepts one active listener");return i.addEventListener(JC,m),u=k,()=>{i.removeEventListener(JC,m),u=null}},createHref(k){return e(i,k)},createURL:x,encodeLocation(k){let T=x(k);return{pathname:T.pathname,search:T.search,hash:T.hash}},push:g,replace:y,go(k){return o.go(k)}};return S}function Pz(t,e=!1){let n="http://localhost";typeof window<"u"&&(n=window.location.origin!=="null"?window.location.origin:window.location.href),nn(n,"No window.location.(origin|href) available to create URL");let r=typeof t=="string"?t:Mo(t);return r=r.replace(/ $/,"%20"),!e&&r.startsWith("//")&&(r=n+r),new URL(r,n)}function jA(t,e,n="/"){return jz(t,e,n,!1)}function jz(t,e,n,r){let i=typeof e=="string"?Go(e):e,a=Ya(i.pathname||"/",n);if(a==null)return null;let o=MA(t);Mz(o);let c=null;for(let u=0;c==null&&u<o.length;++u){let f=Uz(a);c=Iz(o[u],f,r)}return c}function MA(t,e=[],n=[],r="",i=!1){let a=(o,c,u=i,f)=>{let h={relativePath:f===void 0?o.path||"":f,caseSensitive:o.caseSensitive===!0,childrenIndex:c,route:o};if(h.relativePath.startsWith("/")){if(!h.relativePath.startsWith(r)&&u)return;nn(h.relativePath.startsWith(r),`Absolute route path "${h.relativePath}" nested under path "${r}" is not valid. An absolute child route path must start with the combined path of all its parent routes.`),h.relativePath=h.relativePath.slice(r.length)}let m=Xa([r,h.relativePath]),g=n.concat(h);o.children&&o.children.length>0&&(nn(o.index!==!0,`Index routes must not have child routes. Please remove all child routes from route path "${m}".`),MA(o.children,e,g,m,u)),!(o.path==null&&!o.index)&&e.push({path:m,score:Xz(m,o.index),routesMeta:g})};return t.forEach((o,c)=>{if(o.path===""||!o.path?.includes("?"))a(o,c);else for(let u of NA(o.path))a(o,c,!0,u)}),e}function NA(t){let e=t.split("/");if(e.length===0)return[];let[n,...r]=e,i=n.endsWith("?"),a=n.replace(/\?$/,"");if(r.length===0)return i?[a,""]:[a];let o=NA(r.join("/")),c=[];return c.push(...o.map(u=>u===""?a:[a,u].join("/"))),i&&c.push(...o),c.map(u=>t.startsWith("/")&&u===""?"/":u)}function Mz(t){t.sort((e,n)=>e.score!==n.score?n.score-e.score:Bz(e.routesMeta.map(r=>r.childrenIndex),n.routesMeta.map(r=>r.childrenIndex)))}var Nz=/^:[\w-]+$/,Dz=3,zz=2,Lz=1,Zz=10,Vz=-2,tT=t=>t==="*";function Xz(t,e){let n=t.split("/"),r=n.length;return n.some(tT)&&(r+=Vz),e&&(r+=zz),n.filter(i=>!tT(i)).reduce((i,a)=>i+(Nz.test(a)?Dz:a===""?Lz:Zz),r)}function Bz(t,e){return t.length===e.length&&t.slice(0,-1).every((r,i)=>r===e[i])?t[t.length-1]-e[e.length-1]:0}function Iz(t,e,n=!1){let{routesMeta:r}=t,i={},a="/",o=[];for(let c=0;c<r.length;++c){let u=r[c],f=c===r.length-1,h=a==="/"?e:e.slice(a.length)||"/",m=_p({path:u.relativePath,caseSensitive:u.caseSensitive,end:f},h),g=u.route;if(!m&&f&&n&&!r[r.length-1].route.index&&(m=_p({path:u.relativePath,caseSensitive:u.caseSensitive,end:!1},h)),!m)return null;Object.assign(i,m.params),o.push({params:i,pathname:Xa([a,m.pathname]),pathnameBase:Gz(Xa([a,m.pathnameBase])),route:g}),m.pathnameBase!=="/"&&(a=Xa([a,m.pathnameBase]))}return o}function _p(t,e){typeof t=="string"&&(t={path:t,caseSensitive:!1,end:!0});let[n,r]=qz(t.path,t.caseSensitive,t.end),i=e.match(n);if(!i)return null;let a=i[0],o=a.replace(/(.)\/+$/,"$1"),c=i.slice(1);return{params:r.reduce((f,{paramName:h,isOptional:m},g)=>{if(h==="*"){let x=c[g]||"";o=a.slice(0,a.length-x.length).replace(/(.)\/+$/,"$1")}const y=c[g];return m&&!y?f[h]=void 0:f[h]=(y||"").replace(/%2F/g,"/"),f},{}),pathname:a,pathnameBase:o,pattern:t}}function qz(t,e=!1,n=!0){li(t==="*"||!t.endsWith("*")||t.endsWith("/*"),`Route path "${t}" will be treated as if it were "${t.replace(/\*$/,"/*")}" because the \`*\` character must always follow a \`/\` in the pattern. To get rid of this warning, please change the route path to "${t.replace(/\*$/,"/*")}".`);let r=[],i="^"+t.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(o,c,u)=>(r.push({paramName:c,isOptional:u!=null}),u?"/?([^\\/]+)?":"/([^\\/]+)")).replace(/\/([\w-]+)\?(\/|$)/g,"(/$1)?$2");return t.endsWith("*")?(r.push({paramName:"*"}),i+=t==="*"||t==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):n?i+="\\/*$":t!==""&&t!=="/"&&(i+="(?:(?=\\/|$))"),[new RegExp(i,e?void 0:"i"),r]}function Uz(t){try{return t.split("/").map(e=>decodeURIComponent(e).replace(/\//g,"%2F")).join("/")}catch(e){return li(!1,`The URL path "${t}" could not be decoded because it is a malformed URL segment. This is probably due to a bad percent encoding (${e}).`),t}}function Ya(t,e){if(e==="/")return t;if(!t.toLowerCase().startsWith(e.toLowerCase()))return null;let n=e.endsWith("/")?e.length-1:e.length,r=t.charAt(n);return r&&r!=="/"?null:t.slice(n)||"/"}var DA=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,Yz=t=>DA.test(t);function Fz(t,e="/"){let{pathname:n,search:r="",hash:i=""}=typeof t=="string"?Go(t):t,a;if(n)if(Yz(n))a=n;else{if(n.includes("//")){let o=n;n=n.replace(/\/\/+/g,"/"),li(!1,`Pathnames cannot have embedded double slashes - normalizing ${o} -> ${n}`)}n.startsWith("/")?a=nT(n.substring(1),"/"):a=nT(n,e)}else a=e;return{pathname:a,search:Hz(r),hash:Kz(i)}}function nT(t,e){let n=e.replace(/\/+$/,"").split("/");return t.split("/").forEach(i=>{i===".."?n.length>1&&n.pop():i!=="."&&n.push(i)}),n.length>1?n.join("/"):"/"}function Iv(t,e,n,r){return`Cannot include a '${t}' character in a manually specified \`to.${e}\` field [${JSON.stringify(r)}]. Please separate it out to the \`to.${n}\` field. Alternatively you may provide the full path as a string in <Link to="..."> and the router will parse it for you.`}function Wz(t){return t.filter((e,n)=>n===0||e.route.path&&e.route.path.length>0)}function zA(t){let e=Wz(t);return e.map((n,r)=>r===e.length-1?n.pathname:n.pathnameBase)}function LA(t,e,n,r=!1){let i;typeof t=="string"?i=Go(t):(i={...t},nn(!i.pathname||!i.pathname.includes("?"),Iv("?","pathname","search",i)),nn(!i.pathname||!i.pathname.includes("#"),Iv("#","pathname","hash",i)),nn(!i.search||!i.search.includes("#"),Iv("#","search","hash",i)));let a=t===""||i.pathname==="",o=a?"/":i.pathname,c;if(o==null)c=n;else{let m=e.length-1;if(!r&&o.startsWith("..")){let g=o.split("/");for(;g[0]==="..";)g.shift(),m-=1;i.pathname=g.join("/")}c=m>=0?e[m]:"/"}let u=Fz(i,c),f=o&&o!=="/"&&o.endsWith("/"),h=(a||o===".")&&n.endsWith("/");return!u.pathname.endsWith("/")&&(f||h)&&(u.pathname+="/"),u}var Xa=t=>t.join("/").replace(/\/\/+/g,"/"),Gz=t=>t.replace(/\/+$/,"").replace(/^\/*/,"/"),Hz=t=>!t||t==="?"?"":t.startsWith("?")?t:"?"+t,Kz=t=>!t||t==="#"?"":t.startsWith("#")?t:"#"+t,Jz=class{constructor(t,e,n,r=!1){this.status=t,this.statusText=e||"",this.internal=r,n instanceof Error?(this.data=n.toString(),this.error=n):this.data=n}};function e4(t){return t!=null&&typeof t.status=="number"&&typeof t.statusText=="string"&&typeof t.internal=="boolean"&&"data"in t}function t4(t){return t.map(e=>e.route.path).filter(Boolean).join("/").replace(/\/\/*/g,"/")||"/"}var ZA=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";function VA(t,e){let n=t;if(typeof n!="string"||!DA.test(n))return{absoluteURL:void 0,isExternal:!1,to:n};let r=n,i=!1;if(ZA)try{let a=new URL(window.location.href),o=n.startsWith("//")?new URL(a.protocol+n):new URL(n),c=Ya(o.pathname,e);o.origin===a.origin&&c!=null?n=c+o.search+o.hash:i=!0}catch{li(!1,`<Link to="${n}"> contains an invalid URL which will probably break when clicked - please update to a valid URL path.`)}return{absoluteURL:r,isExternal:i,to:n}}Object.getOwnPropertyNames(Object.prototype).sort().join("\0");var XA=["POST","PUT","PATCH","DELETE"];new Set(XA);var n4=["GET",...XA];new Set(n4);var Dc=w.createContext(null);Dc.displayName="DataRouter";var Tm=w.createContext(null);Tm.displayName="DataRouterState";var r4=w.createContext(!1),BA=w.createContext({isTransitioning:!1});BA.displayName="ViewTransition";var i4=w.createContext(new Map);i4.displayName="Fetchers";var a4=w.createContext(null);a4.displayName="Await";var di=w.createContext(null);di.displayName="Navigation";var Bd=w.createContext(null);Bd.displayName="Location";var $i=w.createContext({outlet:null,matches:[],isDataRoute:!1});$i.displayName="Route";var ix=w.createContext(null);ix.displayName="RouteError";var IA="REACT_ROUTER_ERROR",s4="REDIRECT",o4="ROUTE_ERROR_RESPONSE";function l4(t){if(t.startsWith(`${IA}:${s4}:{`))try{let e=JSON.parse(t.slice(28));if(typeof e=="object"&&e&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.location=="string"&&typeof e.reloadDocument=="boolean"&&typeof e.replace=="boolean")return e}catch{}}function c4(t){if(t.startsWith(`${IA}:${o4}:{`))try{let e=JSON.parse(t.slice(40));if(typeof e=="object"&&e&&typeof e.status=="number"&&typeof e.statusText=="string")return new Jz(e.status,e.statusText,e.data)}catch{}}function u4(t,{relative:e}={}){nn(Id(),"useHref() may be used only in the context of a <Router> component.");let{basename:n,navigator:r}=w.useContext(di),{hash:i,pathname:a,search:o}=qd(t,{relative:e}),c=a;return n!=="/"&&(c=a==="/"?n:Xa([n,a])),r.createHref({pathname:c,search:o,hash:i})}function Id(){return w.useContext(Bd)!=null}function Gs(){return nn(Id(),"useLocation() may be used only in the context of a <Router> component."),w.useContext(Bd).location}var qA="You should call navigate() in a React.useEffect(), not when your component is first rendered.";function UA(t){w.useContext(di).static||w.useLayoutEffect(t)}function Ho(){let{isDataRoute:t}=w.useContext($i);return t?C4():d4()}function d4(){nn(Id(),"useNavigate() may be used only in the context of a <Router> component.");let t=w.useContext(Dc),{basename:e,navigator:n}=w.useContext(di),{matches:r}=w.useContext($i),{pathname:i}=Gs(),a=JSON.stringify(zA(r)),o=w.useRef(!1);return UA(()=>{o.current=!0}),w.useCallback((u,f={})=>{if(li(o.current,qA),!o.current)return;if(typeof u=="number"){n.go(u);return}let h=LA(u,JSON.parse(a),i,f.relative==="path");t==null&&e!=="/"&&(h.pathname=h.pathname==="/"?e:Xa([e,h.pathname])),(f.replace?n.replace:n.push)(h,f.state,f)},[e,n,a,i,t])}var f4=w.createContext(null);function h4(t){let e=w.useContext($i).outlet;return w.useMemo(()=>e&&w.createElement(f4.Provider,{value:t},e),[e,t])}function YA(){let{matches:t}=w.useContext($i),e=t[t.length-1];return e?e.params:{}}function qd(t,{relative:e}={}){let{matches:n}=w.useContext($i),{pathname:r}=Gs(),i=JSON.stringify(zA(n));return w.useMemo(()=>LA(t,JSON.parse(i),r,e==="path"),[t,i,r,e])}function p4(t,e){return FA(t,e)}function FA(t,e,n,r,i){nn(Id(),"useRoutes() may be used only in the context of a <Router> component.");let{navigator:a}=w.useContext(di),{matches:o}=w.useContext($i),c=o[o.length-1],u=c?c.params:{},f=c?c.pathname:"/",h=c?c.pathnameBase:"/",m=c&&c.route;{let C=m&&m.path||"";GA(f,!m||C.endsWith("*")||C.endsWith("*?"),`You rendered descendant <Routes> (or called \`useRoutes()\`) at "${f}" (under <Route path="${C}">) 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.
|
|
11
|
-
|
|
12
|
-
Please change the parent <Route path="${C}"> to <Route path="${C==="/"?"*":`${C}/*`}">.`)}let g=Gs(),y;if(e){let C=typeof e=="string"?Go(e):e;nn(h==="/"||C.pathname?.startsWith(h),`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 "${h}" but pathname "${C.pathname}" was given in the \`location\` prop.`),y=C}else y=g;let x=y.pathname||"/",S=x;if(h!=="/"){let C=h.replace(/^\//,"").split("/");S="/"+x.replace(/^\//,"").split("/").slice(C.length).join("/")}let k=jA(t,{pathname:S});li(m||k!=null,`No routes matched location "${y.pathname}${y.search}${y.hash}" `),li(k==null||k[k.length-1].route.element!==void 0||k[k.length-1].route.Component!==void 0||k[k.length-1].route.lazy!==void 0,`Matched leaf route at location "${y.pathname}${y.search}${y.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 T=y4(k&&k.map(C=>Object.assign({},C,{params:Object.assign({},u,C.params),pathname:Xa([h,a.encodeLocation?a.encodeLocation(C.pathname.replace(/\?/g,"%3F").replace(/#/g,"%23")).pathname:C.pathname]),pathnameBase:C.pathnameBase==="/"?h:Xa([h,a.encodeLocation?a.encodeLocation(C.pathnameBase.replace(/\?/g,"%3F").replace(/#/g,"%23")).pathname:C.pathnameBase])})),o,n,r,i);return e&&T?w.createElement(Bd.Provider,{value:{location:{pathname:"/",search:"",hash:"",state:null,key:"default",...y},navigationType:"POP"}},T):T}function m4(){let t=k4(),e=e4(t)?`${t.status} ${t.statusText}`:t instanceof Error?t.message:JSON.stringify(t),n=t instanceof Error?t.stack:null,r="rgba(200,200,200, 0.5)",i={padding:"0.5rem",backgroundColor:r},a={padding:"2px 4px",backgroundColor:r},o=null;return console.error("Error handled by React Router default ErrorBoundary:",t),o=w.createElement(w.Fragment,null,w.createElement("p",null,"💿 Hey developer 👋"),w.createElement("p",null,"You can provide a way better UX than this when your app throws errors by providing your own ",w.createElement("code",{style:a},"ErrorBoundary")," or"," ",w.createElement("code",{style:a},"errorElement")," prop on your route.")),w.createElement(w.Fragment,null,w.createElement("h2",null,"Unexpected Application Error!"),w.createElement("h3",{style:{fontStyle:"italic"}},e),n?w.createElement("pre",{style:i},n):null,o)}var g4=w.createElement(m4,null),WA=class extends w.Component{constructor(t){super(t),this.state={location:t.location,revalidation:t.revalidation,error:t.error}}static getDerivedStateFromError(t){return{error:t}}static getDerivedStateFromProps(t,e){return e.location!==t.location||e.revalidation!=="idle"&&t.revalidation==="idle"?{error:t.error,location:t.location,revalidation:t.revalidation}:{error:t.error!==void 0?t.error:e.error,location:e.location,revalidation:t.revalidation||e.revalidation}}componentDidCatch(t,e){this.props.onError?this.props.onError(t,e):console.error("React Router caught the following error during render",t)}render(){let t=this.state.error;if(this.context&&typeof t=="object"&&t&&"digest"in t&&typeof t.digest=="string"){const n=c4(t.digest);n&&(t=n)}let e=t!==void 0?w.createElement($i.Provider,{value:this.props.routeContext},w.createElement(ix.Provider,{value:t,children:this.props.component})):this.props.children;return this.context?w.createElement(O4,{error:t},e):e}};WA.contextType=r4;var qv=new WeakMap;function O4({children:t,error:e}){let{basename:n}=w.useContext(di);if(typeof e=="object"&&e&&"digest"in e&&typeof e.digest=="string"){let r=l4(e.digest);if(r){let i=qv.get(e);if(i)throw i;let a=VA(r.location,n);if(ZA&&!qv.get(e))if(a.isExternal||r.reloadDocument)window.location.href=a.absoluteURL||a.to;else{const o=Promise.resolve().then(()=>window.__reactRouterDataRouter.navigate(a.to,{replace:r.replace}));throw qv.set(e,o),o}return w.createElement("meta",{httpEquiv:"refresh",content:`0;url=${a.absoluteURL||a.to}`})}}return t}function v4({routeContext:t,match:e,children:n}){let r=w.useContext(Dc);return r&&r.static&&r.staticContext&&(e.route.errorElement||e.route.ErrorBoundary)&&(r.staticContext._deepestRenderedBoundaryId=e.route.id),w.createElement($i.Provider,{value:t},n)}function y4(t,e=[],n=null,r=null,i=null){if(t==null){if(!n)return null;if(n.errors)t=n.matches;else if(e.length===0&&!n.initialized&&n.matches.length>0)t=n.matches;else return null}let a=t,o=n?.errors;if(o!=null){let h=a.findIndex(m=>m.route.id&&o?.[m.route.id]!==void 0);nn(h>=0,`Could not find a matching route for errors on route IDs: ${Object.keys(o).join(",")}`),a=a.slice(0,Math.min(a.length,h+1))}let c=!1,u=-1;if(n)for(let h=0;h<a.length;h++){let m=a[h];if((m.route.HydrateFallback||m.route.hydrateFallbackElement)&&(u=h),m.route.id){let{loaderData:g,errors:y}=n,x=m.route.loader&&!g.hasOwnProperty(m.route.id)&&(!y||y[m.route.id]===void 0);if(m.route.lazy||x){c=!0,u>=0?a=a.slice(0,u+1):a=[a[0]];break}}}let f=n&&r?(h,m)=>{r(h,{location:n.location,params:n.matches?.[0]?.params??{},unstable_pattern:t4(n.matches),errorInfo:m})}:void 0;return a.reduceRight((h,m,g)=>{let y,x=!1,S=null,k=null;n&&(y=o&&m.route.id?o[m.route.id]:void 0,S=m.route.errorElement||g4,c&&(u<0&&g===0?(GA("route-fallback",!1,"No `HydrateFallback` element provided to render during initial hydration"),x=!0,k=null):u===g&&(x=!0,k=m.route.hydrateFallbackElement||null)));let T=e.concat(a.slice(0,g+1)),C=()=>{let E;return y?E=S:x?E=k:m.route.Component?E=w.createElement(m.route.Component,null):m.route.element?E=m.route.element:E=h,w.createElement(v4,{match:m,routeContext:{outlet:h,matches:T,isDataRoute:n!=null},children:E})};return n&&(m.route.ErrorBoundary||m.route.errorElement||g===0)?w.createElement(WA,{location:n.location,revalidation:n.revalidation,component:S,error:y,children:C(),routeContext:{outlet:null,matches:T,isDataRoute:!0},onError:f}):C()},null)}function ax(t){return`${t} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function b4(t){let e=w.useContext(Dc);return nn(e,ax(t)),e}function x4(t){let e=w.useContext(Tm);return nn(e,ax(t)),e}function S4(t){let e=w.useContext($i);return nn(e,ax(t)),e}function sx(t){let e=S4(t),n=e.matches[e.matches.length-1];return nn(n.route.id,`${t} can only be used on routes that contain a unique "id"`),n.route.id}function w4(){return sx("useRouteId")}function k4(){let t=w.useContext(ix),e=x4("useRouteError"),n=sx("useRouteError");return t!==void 0?t:e.errors?.[n]}function C4(){let{router:t}=b4("useNavigate"),e=sx("useNavigate"),n=w.useRef(!1);return UA(()=>{n.current=!0}),w.useCallback(async(i,a={})=>{li(n.current,qA),n.current&&(typeof i=="number"?await t.navigate(i):await t.navigate(i,{fromRouteId:e,...a}))},[t,e])}var rT={};function GA(t,e,n){!e&&!rT[t]&&(rT[t]=!0,li(!1,n))}w.memo(T4);function T4({routes:t,future:e,state:n,onError:r}){return FA(t,void 0,n,r,e)}function E4(t){return h4(t.context)}function Fl(t){nn(!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 HA({basename:t="/",children:e=null,location:n,navigationType:r="POP",navigator:i,static:a=!1,unstable_useTransitions:o}){nn(!Id(),"You cannot render a <Router> inside another <Router>. You should never have more than one in your app.");let c=t.replace(/^\/*/,"/"),u=w.useMemo(()=>({basename:c,navigator:i,static:a,unstable_useTransitions:o,future:{}}),[c,i,a,o]);typeof n=="string"&&(n=Go(n));let{pathname:f="/",search:h="",hash:m="",state:g=null,key:y="default"}=n,x=w.useMemo(()=>{let S=Ya(f,c);return S==null?null:{location:{pathname:S,search:h,hash:m,state:g,key:y},navigationType:r}},[c,f,h,m,g,y,r]);return li(x!=null,`<Router basename="${c}"> is not able to match the URL "${f}${h}${m}" because it does not start with the basename, so the <Router> won't render anything.`),x==null?null:w.createElement(di.Provider,{value:u},w.createElement(Bd.Provider,{children:e,value:x}))}function Q4({children:t,location:e}){return p4(o0(t),e)}function o0(t,e=[]){let n=[];return w.Children.forEach(t,(r,i)=>{if(!w.isValidElement(r))return;let a=[...e,i];if(r.type===w.Fragment){n.push.apply(n,o0(r.props.children,a));return}nn(r.type===Fl,`[${typeof r.type=="string"?r.type:r.type.name}] is not a <Route> component. All component children of <Routes> must be a <Route> or <React.Fragment>`),nn(!r.props.index||!r.props.children,"An index route cannot have child routes.");let o={id:r.props.id||a.join("-"),caseSensitive:r.props.caseSensitive,element:r.props.element,Component:r.props.Component,index:r.props.index,path:r.props.path,middleware:r.props.middleware,loader:r.props.loader,action:r.props.action,hydrateFallbackElement:r.props.hydrateFallbackElement,HydrateFallback:r.props.HydrateFallback,errorElement:r.props.errorElement,ErrorBoundary:r.props.ErrorBoundary,hasErrorBoundary:r.props.hasErrorBoundary===!0||r.props.ErrorBoundary!=null||r.props.errorElement!=null,shouldRevalidate:r.props.shouldRevalidate,handle:r.props.handle,lazy:r.props.lazy};r.props.children&&(o.children=o0(r.props.children,a)),n.push(o)}),n}var lp="get",cp="application/x-www-form-urlencoded";function Em(t){return typeof HTMLElement<"u"&&t instanceof HTMLElement}function A4(t){return Em(t)&&t.tagName.toLowerCase()==="button"}function R4(t){return Em(t)&&t.tagName.toLowerCase()==="form"}function _4(t){return Em(t)&&t.tagName.toLowerCase()==="input"}function $4(t){return!!(t.metaKey||t.altKey||t.ctrlKey||t.shiftKey)}function P4(t,e){return t.button===0&&(!e||e==="_self")&&!$4(t)}function l0(t=""){return new URLSearchParams(typeof t=="string"||Array.isArray(t)||t instanceof URLSearchParams?t:Object.keys(t).reduce((e,n)=>{let r=t[n];return e.concat(Array.isArray(r)?r.map(i=>[n,i]):[[n,r]])},[]))}function j4(t,e){let n=l0(t);return e&&e.forEach((r,i)=>{n.has(i)||e.getAll(i).forEach(a=>{n.append(i,a)})}),n}var Th=null;function M4(){if(Th===null)try{new FormData(document.createElement("form"),0),Th=!1}catch{Th=!0}return Th}var N4=new Set(["application/x-www-form-urlencoded","multipart/form-data","text/plain"]);function Uv(t){return t!=null&&!N4.has(t)?(li(!1,`"${t}" is not a valid \`encType\` for \`<Form>\`/\`<fetcher.Form>\` and will default to "${cp}"`),null):t}function D4(t,e){let n,r,i,a,o;if(R4(t)){let c=t.getAttribute("action");r=c?Ya(c,e):null,n=t.getAttribute("method")||lp,i=Uv(t.getAttribute("enctype"))||cp,a=new FormData(t)}else if(A4(t)||_4(t)&&(t.type==="submit"||t.type==="image")){let c=t.form;if(c==null)throw new Error('Cannot submit a <button> or <input type="submit"> without a <form>');let u=t.getAttribute("formaction")||c.getAttribute("action");if(r=u?Ya(u,e):null,n=t.getAttribute("formmethod")||c.getAttribute("method")||lp,i=Uv(t.getAttribute("formenctype"))||Uv(c.getAttribute("enctype"))||cp,a=new FormData(c,t),!M4()){let{name:f,type:h,value:m}=t;if(h==="image"){let g=f?`${f}.`:"";a.append(`${g}x`,"0"),a.append(`${g}y`,"0")}else f&&a.append(f,m)}}else{if(Em(t))throw new Error('Cannot submit element that is not <form>, <button>, or <input type="submit|image">');n=lp,r=null,i=cp,o=t}return a&&i==="text/plain"&&(o=a,a=void 0),{action:r,method:n.toLowerCase(),encType:i,formData:a,body:o}}Object.getOwnPropertyNames(Object.prototype).sort().join("\0");function ox(t,e){if(t===!1||t===null||typeof t>"u")throw new Error(e)}function z4(t,e,n){let r=typeof t=="string"?new URL(t,typeof window>"u"?"server://singlefetch/":window.location.origin):t;return r.pathname==="/"?r.pathname=`_root.${n}`:e&&Ya(r.pathname,e)==="/"?r.pathname=`${e.replace(/\/$/,"")}/_root.${n}`:r.pathname=`${r.pathname.replace(/\/$/,"")}.${n}`,r}async function L4(t,e){if(t.id in e)return e[t.id];try{let n=await import(t.module);return e[t.id]=n,n}catch(n){return console.error(`Error loading route module \`${t.module}\`, reloading page...`),console.error(n),window.__reactRouterContext&&window.__reactRouterContext.isSpaMode,window.location.reload(),new Promise(()=>{})}}function Z4(t){return t==null?!1:t.href==null?t.rel==="preload"&&typeof t.imageSrcSet=="string"&&typeof t.imageSizes=="string":typeof t.rel=="string"&&typeof t.href=="string"}async function V4(t,e,n){let r=await Promise.all(t.map(async i=>{let a=e.routes[i.route.id];if(a){let o=await L4(a,n);return o.links?o.links():[]}return[]}));return q4(r.flat(1).filter(Z4).filter(i=>i.rel==="stylesheet"||i.rel==="preload").map(i=>i.rel==="stylesheet"?{...i,rel:"prefetch",as:"style"}:{...i,rel:"prefetch"}))}function iT(t,e,n,r,i,a){let o=(u,f)=>n[f]?u.route.id!==n[f].route.id:!0,c=(u,f)=>n[f].pathname!==u.pathname||n[f].route.path?.endsWith("*")&&n[f].params["*"]!==u.params["*"];return a==="assets"?e.filter((u,f)=>o(u,f)||c(u,f)):a==="data"?e.filter((u,f)=>{let h=r.routes[u.route.id];if(!h||!h.hasLoader)return!1;if(o(u,f)||c(u,f))return!0;if(u.route.shouldRevalidate){let m=u.route.shouldRevalidate({currentUrl:new URL(i.pathname+i.search+i.hash,window.origin),currentParams:n[0]?.params||{},nextUrl:new URL(t,window.origin),nextParams:u.params,defaultShouldRevalidate:!0});if(typeof m=="boolean")return m}return!0}):[]}function X4(t,e,{includeHydrateFallback:n}={}){return B4(t.map(r=>{let i=e.routes[r.route.id];if(!i)return[];let a=[i.module];return i.clientActionModule&&(a=a.concat(i.clientActionModule)),i.clientLoaderModule&&(a=a.concat(i.clientLoaderModule)),n&&i.hydrateFallbackModule&&(a=a.concat(i.hydrateFallbackModule)),i.imports&&(a=a.concat(i.imports)),a}).flat(1))}function B4(t){return[...new Set(t)]}function I4(t){let e={},n=Object.keys(t).sort();for(let r of n)e[r]=t[r];return e}function q4(t,e){let n=new Set;return new Set(e),t.reduce((r,i)=>{let a=JSON.stringify(I4(i));return n.has(a)||(n.add(a),r.push({key:a,link:i})),r},[])}function KA(){let t=w.useContext(Dc);return ox(t,"You must render this element inside a <DataRouterContext.Provider> element"),t}function U4(){let t=w.useContext(Tm);return ox(t,"You must render this element inside a <DataRouterStateContext.Provider> element"),t}var lx=w.createContext(void 0);lx.displayName="FrameworkContext";function JA(){let t=w.useContext(lx);return ox(t,"You must render this element inside a <HydratedRouter> element"),t}function Y4(t,e){let n=w.useContext(lx),[r,i]=w.useState(!1),[a,o]=w.useState(!1),{onFocus:c,onBlur:u,onMouseEnter:f,onMouseLeave:h,onTouchStart:m}=e,g=w.useRef(null);w.useEffect(()=>{if(t==="render"&&o(!0),t==="viewport"){let S=T=>{T.forEach(C=>{o(C.isIntersecting)})},k=new IntersectionObserver(S,{threshold:.5});return g.current&&k.observe(g.current),()=>{k.disconnect()}}},[t]),w.useEffect(()=>{if(r){let S=setTimeout(()=>{o(!0)},100);return()=>{clearTimeout(S)}}},[r]);let y=()=>{i(!0)},x=()=>{i(!1),o(!1)};return n?t!=="intent"?[a,g,{}]:[a,g,{onFocus:Zu(c,y),onBlur:Zu(u,x),onMouseEnter:Zu(f,y),onMouseLeave:Zu(h,x),onTouchStart:Zu(m,y)}]:[!1,g,{}]}function Zu(t,e){return n=>{t&&t(n),n.defaultPrevented||e(n)}}function F4({page:t,...e}){let{router:n}=KA(),r=w.useMemo(()=>jA(n.routes,t,n.basename),[n.routes,t,n.basename]);return r?w.createElement(G4,{page:t,matches:r,...e}):null}function W4(t){let{manifest:e,routeModules:n}=JA(),[r,i]=w.useState([]);return w.useEffect(()=>{let a=!1;return V4(t,e,n).then(o=>{a||i(o)}),()=>{a=!0}},[t,e,n]),r}function G4({page:t,matches:e,...n}){let r=Gs(),{manifest:i,routeModules:a}=JA(),{basename:o}=KA(),{loaderData:c,matches:u}=U4(),f=w.useMemo(()=>iT(t,e,u,i,r,"data"),[t,e,u,i,r]),h=w.useMemo(()=>iT(t,e,u,i,r,"assets"),[t,e,u,i,r]),m=w.useMemo(()=>{if(t===r.pathname+r.search+r.hash)return[];let x=new Set,S=!1;if(e.forEach(T=>{let C=i.routes[T.route.id];!C||!C.hasLoader||(!f.some(E=>E.route.id===T.route.id)&&T.route.id in c&&a[T.route.id]?.shouldRevalidate||C.hasClientLoader?S=!0:x.add(T.route.id))}),x.size===0)return[];let k=z4(t,o,"data");return S&&x.size>0&&k.searchParams.set("_routes",e.filter(T=>x.has(T.route.id)).map(T=>T.route.id).join(",")),[k.pathname+k.search]},[o,c,r,i,f,e,t,a]),g=w.useMemo(()=>X4(h,i),[h,i]),y=W4(h);return w.createElement(w.Fragment,null,m.map(x=>w.createElement("link",{key:x,rel:"prefetch",as:"fetch",href:x,...n})),g.map(x=>w.createElement("link",{key:x,rel:"modulepreload",href:x,...n})),y.map(({key:x,link:S})=>w.createElement("link",{key:x,nonce:n.nonce,...S})))}function H4(...t){return e=>{t.forEach(n=>{typeof n=="function"?n(e):n!=null&&(n.current=e)})}}var K4=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";try{K4&&(window.__reactRouterVersion="7.11.0")}catch{}function J4({basename:t,children:e,unstable_useTransitions:n,window:r}){let i=w.useRef();i.current==null&&(i.current=Rz({window:r,v5Compat:!0}));let a=i.current,[o,c]=w.useState({action:a.action,location:a.location}),u=w.useCallback(f=>{n===!1?c(f):w.startTransition(()=>c(f))},[n]);return w.useLayoutEffect(()=>a.listen(u),[a,u]),w.createElement(HA,{basename:t,children:e,location:o.location,navigationType:o.action,navigator:a,unstable_useTransitions:n})}var eR=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,No=w.forwardRef(function({onClick:e,discover:n="render",prefetch:r="none",relative:i,reloadDocument:a,replace:o,state:c,target:u,to:f,preventScrollReset:h,viewTransition:m,unstable_defaultShouldRevalidate:g,...y},x){let{basename:S,unstable_useTransitions:k}=w.useContext(di),T=typeof f=="string"&&eR.test(f),C=VA(f,S);f=C.to;let E=u4(f,{relative:i}),[R,$,P]=Y4(r,y),_=rL(f,{replace:o,state:c,target:u,preventScrollReset:h,relative:i,viewTransition:m,unstable_defaultShouldRevalidate:g,unstable_useTransitions:k});function M(F){e&&e(F),F.defaultPrevented||_(F)}let V=w.createElement("a",{...y,...P,href:C.absoluteURL||E,onClick:C.isExternal||a?e:M,ref:H4(x,$),target:u,"data-discover":!T&&n==="render"?"true":void 0});return R&&!T?w.createElement(w.Fragment,null,V,w.createElement(F4,{page:E})):V});No.displayName="Link";var eL=w.forwardRef(function({"aria-current":e="page",caseSensitive:n=!1,className:r="",end:i=!1,style:a,to:o,viewTransition:c,children:u,...f},h){let m=qd(o,{relative:f.relative}),g=Gs(),y=w.useContext(Tm),{navigator:x,basename:S}=w.useContext(di),k=y!=null&&cL(m)&&c===!0,T=x.encodeLocation?x.encodeLocation(m).pathname:m.pathname,C=g.pathname,E=y&&y.navigation&&y.navigation.location?y.navigation.location.pathname:null;n||(C=C.toLowerCase(),E=E?E.toLowerCase():null,T=T.toLowerCase()),E&&S&&(E=Ya(E,S)||E);const R=T!=="/"&&T.endsWith("/")?T.length-1:T.length;let $=C===T||!i&&C.startsWith(T)&&C.charAt(R)==="/",P=E!=null&&(E===T||!i&&E.startsWith(T)&&E.charAt(T.length)==="/"),_={isActive:$,isPending:P,isTransitioning:k},M=$?e:void 0,V;typeof r=="function"?V=r(_):V=[r,$?"active":null,P?"pending":null,k?"transitioning":null].filter(Boolean).join(" ");let F=typeof a=="function"?a(_):a;return w.createElement(No,{...f,"aria-current":M,className:V,ref:h,style:F,to:o,viewTransition:c},typeof u=="function"?u(_):u)});eL.displayName="NavLink";var tL=w.forwardRef(({discover:t="render",fetcherKey:e,navigate:n,reloadDocument:r,replace:i,state:a,method:o=lp,action:c,onSubmit:u,relative:f,preventScrollReset:h,viewTransition:m,unstable_defaultShouldRevalidate:g,...y},x)=>{let{unstable_useTransitions:S}=w.useContext(di),k=oL(),T=lL(c,{relative:f}),C=o.toLowerCase()==="get"?"get":"post",E=typeof c=="string"&&eR.test(c),R=$=>{if(u&&u($),$.defaultPrevented)return;$.preventDefault();let P=$.nativeEvent.submitter,_=P?.getAttribute("formmethod")||o,M=()=>k(P||$.currentTarget,{fetcherKey:e,method:_,navigate:n,replace:i,state:a,relative:f,preventScrollReset:h,viewTransition:m,unstable_defaultShouldRevalidate:g});S&&n!==!1?w.startTransition(()=>M()):M()};return w.createElement("form",{ref:x,method:C,action:T,onSubmit:r?u:R,...y,"data-discover":!E&&t==="render"?"true":void 0})});tL.displayName="Form";function nL(t){return`${t} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function tR(t){let e=w.useContext(Dc);return nn(e,nL(t)),e}function rL(t,{target:e,replace:n,state:r,preventScrollReset:i,relative:a,viewTransition:o,unstable_defaultShouldRevalidate:c,unstable_useTransitions:u}={}){let f=Ho(),h=Gs(),m=qd(t,{relative:a});return w.useCallback(g=>{if(P4(g,e)){g.preventDefault();let y=n!==void 0?n:Mo(h)===Mo(m),x=()=>f(t,{replace:y,state:r,preventScrollReset:i,relative:a,viewTransition:o,unstable_defaultShouldRevalidate:c});u?w.startTransition(()=>x()):x()}},[h,f,m,n,r,e,t,i,a,o,c,u])}function iL(t){li(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 e=w.useRef(l0(t)),n=w.useRef(!1),r=Gs(),i=w.useMemo(()=>j4(r.search,n.current?null:e.current),[r.search]),a=Ho(),o=w.useCallback((c,u)=>{const f=l0(typeof c=="function"?c(new URLSearchParams(i)):c);n.current=!0,a("?"+f,u)},[a,i]);return[i,o]}var aL=0,sL=()=>`__${String(++aL)}__`;function oL(){let{router:t}=tR("useSubmit"),{basename:e}=w.useContext(di),n=w4(),r=t.fetch,i=t.navigate;return w.useCallback(async(a,o={})=>{let{action:c,method:u,encType:f,formData:h,body:m}=D4(a,e);if(o.navigate===!1){let g=o.fetcherKey||sL();await r(g,n,o.action||c,{unstable_defaultShouldRevalidate:o.unstable_defaultShouldRevalidate,preventScrollReset:o.preventScrollReset,formData:h,body:m,formMethod:o.method||u,formEncType:o.encType||f,flushSync:o.flushSync})}else await i(o.action||c,{unstable_defaultShouldRevalidate:o.unstable_defaultShouldRevalidate,preventScrollReset:o.preventScrollReset,formData:h,body:m,formMethod:o.method||u,formEncType:o.encType||f,replace:o.replace,state:o.state,fromRouteId:n,flushSync:o.flushSync,viewTransition:o.viewTransition})},[r,i,e,n])}function lL(t,{relative:e}={}){let{basename:n}=w.useContext(di),r=w.useContext($i);nn(r,"useFormAction must be used inside a RouteContext");let[i]=r.matches.slice(-1),a={...qd(t||".",{relative:e})},o=Gs();if(t==null){a.search=o.search;let c=new URLSearchParams(a.search),u=c.getAll("index");if(u.some(h=>h==="")){c.delete("index"),u.filter(m=>m).forEach(m=>c.append("index",m));let h=c.toString();a.search=h?`?${h}`:""}}return(!t||t===".")&&i.route.index&&(a.search=a.search?a.search.replace(/^\?/,"?index&"):"?index"),n!=="/"&&(a.pathname=a.pathname==="/"?n:Xa([n,a.pathname])),Mo(a)}function cL(t,{relative:e}={}){let n=w.useContext(BA);nn(n!=null,"`useViewTransitionState` must be used within `react-router-dom`'s `RouterProvider`. Did you accidentally import `RouterProvider` from `react-router`?");let{basename:r}=tR("useViewTransitionState"),i=qd(t,{relative:e});if(!n.isTransitioning)return!1;let a=Ya(n.currentLocation.pathname,r)||n.currentLocation.pathname,o=Ya(n.nextLocation.pathname,r)||n.nextLocation.pathname;return _p(i.pathname,o)!=null||_p(i.pathname,a)!=null}function uL({basename:t,children:e,location:n="/"}){typeof n=="string"&&(n=Go(n));let r="POP",i={pathname:n.pathname||"/",search:n.search||"",hash:n.hash||"",state:n.state!=null?n.state:null,key:n.key||"default"},a=dL();return w.createElement(HA,{basename:t,children:e,location:i,navigationType:r,navigator:a,static:!0,unstable_useTransitions:!1})}function dL(){return{createHref:fL,encodeLocation:hL,push(t){throw new Error(`You cannot use navigator.push() on the server because it is a stateless environment. This error was probably triggered when you did a \`navigate(${JSON.stringify(t)})\` somewhere in your app.`)},replace(t){throw new Error(`You cannot use navigator.replace() on the server because it is a stateless environment. This error was probably triggered when you did a \`navigate(${JSON.stringify(t)}, { replace: true })\` somewhere in your app.`)},go(t){throw new Error(`You cannot use navigator.go() on the server because it is a stateless environment. This error was probably triggered when you did a \`navigate(${t})\` somewhere in your app.`)},back(){throw new Error("You cannot use navigator.back() on the server because it is a stateless environment.")},forward(){throw new Error("You cannot use navigator.forward() on the server because it is a stateless environment.")}}}function fL(t){return typeof t=="string"?t:Mo(t)}function hL(t){let e=typeof t=="string"?t:Mo(t);e=e.replace(/ $/,"%20");let n=pL.test(e)?new URL(e):new URL(e,"http://localhost");return{pathname:n.pathname,search:n.search,hash:n.hash}}var pL=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,zc=class{constructor(){this.listeners=new Set,this.subscribe=this.subscribe.bind(this)}subscribe(t){return this.listeners.add(t),this.onSubscribe(),()=>{this.listeners.delete(t),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}onSubscribe(){}onUnsubscribe(){}},mL={setTimeout:(t,e)=>setTimeout(t,e),clearTimeout:t=>clearTimeout(t),setInterval:(t,e)=>setInterval(t,e),clearInterval:t=>clearInterval(t)},gL=class{#e=mL;#t=!1;setTimeoutProvider(t){this.#e=t}setTimeout(t,e){return this.#e.setTimeout(t,e)}clearTimeout(t){this.#e.clearTimeout(t)}setInterval(t,e){return this.#e.setInterval(t,e)}clearInterval(t){this.#e.clearInterval(t)}},Eo=new gL;function OL(t){setTimeout(t,0)}var Do=typeof window>"u"||"Deno"in globalThis;function ar(){}function vL(t,e){return typeof t=="function"?t(e):t}function c0(t){return typeof t=="number"&&t>=0&&t!==1/0}function nR(t,e){return Math.max(t+(e||0)-Date.now(),0)}function Ns(t,e){return typeof t=="function"?t(e):t}function ni(t,e){return typeof t=="function"?t(e):t}function aT(t,e){const{type:n="all",exact:r,fetchStatus:i,predicate:a,queryKey:o,stale:c}=t;if(o){if(r){if(e.queryHash!==cx(o,e.options))return!1}else if(!vd(e.queryKey,o))return!1}if(n!=="all"){const u=e.isActive();if(n==="active"&&!u||n==="inactive"&&u)return!1}return!(typeof c=="boolean"&&e.isStale()!==c||i&&i!==e.state.fetchStatus||a&&!a(e))}function sT(t,e){const{exact:n,status:r,predicate:i,mutationKey:a}=t;if(a){if(!e.options.mutationKey)return!1;if(n){if(zo(e.options.mutationKey)!==zo(a))return!1}else if(!vd(e.options.mutationKey,a))return!1}return!(r&&e.state.status!==r||i&&!i(e))}function cx(t,e){return(e?.queryKeyHashFn||zo)(t)}function zo(t){return JSON.stringify(t,(e,n)=>u0(n)?Object.keys(n).sort().reduce((r,i)=>(r[i]=n[i],r),{}):n)}function vd(t,e){return t===e?!0:typeof t!=typeof e?!1:t&&e&&typeof t=="object"&&typeof e=="object"?Object.keys(e).every(n=>vd(t[n],e[n])):!1}var yL=Object.prototype.hasOwnProperty;function rR(t,e){if(t===e)return t;const n=oT(t)&&oT(e);if(!n&&!(u0(t)&&u0(e)))return e;const i=(n?t:Object.keys(t)).length,a=n?e:Object.keys(e),o=a.length,c=n?new Array(o):{};let u=0;for(let f=0;f<o;f++){const h=n?f:a[f],m=t[h],g=e[h];if(m===g){c[h]=m,(n?f<i:yL.call(t,h))&&u++;continue}if(m===null||g===null||typeof m!="object"||typeof g!="object"){c[h]=g;continue}const y=rR(m,g);c[h]=y,y===m&&u++}return i===o&&u===i?t:c}function $p(t,e){if(!e||Object.keys(t).length!==Object.keys(e).length)return!1;for(const n in t)if(t[n]!==e[n])return!1;return!0}function oT(t){return Array.isArray(t)&&t.length===Object.keys(t).length}function u0(t){if(!lT(t))return!1;const e=t.constructor;if(e===void 0)return!0;const n=e.prototype;return!(!lT(n)||!n.hasOwnProperty("isPrototypeOf")||Object.getPrototypeOf(t)!==Object.prototype)}function lT(t){return Object.prototype.toString.call(t)==="[object Object]"}function bL(t){return new Promise(e=>{Eo.setTimeout(e,t)})}function d0(t,e,n){return typeof n.structuralSharing=="function"?n.structuralSharing(t,e):n.structuralSharing!==!1?rR(t,e):e}function xL(t,e,n=0){const r=[...t,e];return n&&r.length>n?r.slice(1):r}function SL(t,e,n=0){const r=[e,...t];return n&&r.length>n?r.slice(0,-1):r}var ux=Symbol();function iR(t,e){return!t.queryFn&&e?.initialPromise?()=>e.initialPromise:!t.queryFn||t.queryFn===ux?()=>Promise.reject(new Error(`Missing queryFn: '${t.queryHash}'`)):t.queryFn}function aR(t,e){return typeof t=="function"?t(...e):!!t}var wL=class extends zc{#e;#t;#n;constructor(){super(),this.#n=t=>{if(!Do&&window.addEventListener){const e=()=>t();return window.addEventListener("visibilitychange",e,!1),()=>{window.removeEventListener("visibilitychange",e)}}}}onSubscribe(){this.#t||this.setEventListener(this.#n)}onUnsubscribe(){this.hasListeners()||(this.#t?.(),this.#t=void 0)}setEventListener(t){this.#n=t,this.#t?.(),this.#t=t(e=>{typeof e=="boolean"?this.setFocused(e):this.onFocus()})}setFocused(t){this.#e!==t&&(this.#e=t,this.onFocus())}onFocus(){const t=this.isFocused();this.listeners.forEach(e=>{e(t)})}isFocused(){return typeof this.#e=="boolean"?this.#e:globalThis.document?.visibilityState!=="hidden"}},dx=new wL;function f0(){let t,e;const n=new Promise((i,a)=>{t=i,e=a});n.status="pending",n.catch(()=>{});function r(i){Object.assign(n,i),delete n.resolve,delete n.reject}return n.resolve=i=>{r({status:"fulfilled",value:i}),t(i)},n.reject=i=>{r({status:"rejected",reason:i}),e(i)},n}var kL=OL;function CL(){let t=[],e=0,n=c=>{c()},r=c=>{c()},i=kL;const a=c=>{e?t.push(c):i(()=>{n(c)})},o=()=>{const c=t;t=[],c.length&&i(()=>{r(()=>{c.forEach(u=>{n(u)})})})};return{batch:c=>{let u;e++;try{u=c()}finally{e--,e||o()}return u},batchCalls:c=>(...u)=>{a(()=>{c(...u)})},schedule:a,setNotifyFunction:c=>{n=c},setBatchNotifyFunction:c=>{r=c},setScheduler:c=>{i=c}}}var An=CL(),TL=class extends zc{#e=!0;#t;#n;constructor(){super(),this.#n=t=>{if(!Do&&window.addEventListener){const e=()=>t(!0),n=()=>t(!1);return window.addEventListener("online",e,!1),window.addEventListener("offline",n,!1),()=>{window.removeEventListener("online",e),window.removeEventListener("offline",n)}}}}onSubscribe(){this.#t||this.setEventListener(this.#n)}onUnsubscribe(){this.hasListeners()||(this.#t?.(),this.#t=void 0)}setEventListener(t){this.#n=t,this.#t?.(),this.#t=t(this.setOnline.bind(this))}setOnline(t){this.#e!==t&&(this.#e=t,this.listeners.forEach(n=>{n(t)}))}isOnline(){return this.#e}},Pp=new TL;function EL(t){return Math.min(1e3*2**t,3e4)}function sR(t){return(t??"online")==="online"?Pp.isOnline():!0}var h0=class extends Error{constructor(t){super("CancelledError"),this.revert=t?.revert,this.silent=t?.silent}};function oR(t){let e=!1,n=0,r;const i=f0(),a=()=>i.status!=="pending",o=S=>{if(!a()){const k=new h0(S);g(k),t.onCancel?.(k)}},c=()=>{e=!0},u=()=>{e=!1},f=()=>dx.isFocused()&&(t.networkMode==="always"||Pp.isOnline())&&t.canRun(),h=()=>sR(t.networkMode)&&t.canRun(),m=S=>{a()||(r?.(),i.resolve(S))},g=S=>{a()||(r?.(),i.reject(S))},y=()=>new Promise(S=>{r=k=>{(a()||f())&&S(k)},t.onPause?.()}).then(()=>{r=void 0,a()||t.onContinue?.()}),x=()=>{if(a())return;let S;const k=n===0?t.initialPromise:void 0;try{S=k??t.fn()}catch(T){S=Promise.reject(T)}Promise.resolve(S).then(m).catch(T=>{if(a())return;const C=t.retry??(Do?0:3),E=t.retryDelay??EL,R=typeof E=="function"?E(n,T):E,$=C===!0||typeof C=="number"&&n<C||typeof C=="function"&&C(n,T);if(e||!$){g(T);return}n++,t.onFail?.(n,T),bL(R).then(()=>f()?void 0:y()).then(()=>{e?g(T):x()})})};return{promise:i,status:()=>i.status,cancel:o,continue:()=>(r?.(),i),cancelRetry:c,continueRetry:u,canStart:h,start:()=>(h()?x():y().then(x),i)}}var lR=class{#e;destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),c0(this.gcTime)&&(this.#e=Eo.setTimeout(()=>{this.optionalRemove()},this.gcTime))}updateGcTime(t){this.gcTime=Math.max(this.gcTime||0,t??(Do?1/0:300*1e3))}clearGcTimeout(){this.#e&&(Eo.clearTimeout(this.#e),this.#e=void 0)}},QL=class extends lR{#e;#t;#n;#i;#r;#s;#o;constructor(t){super(),this.#o=!1,this.#s=t.defaultOptions,this.setOptions(t.options),this.observers=[],this.#i=t.client,this.#n=this.#i.getQueryCache(),this.queryKey=t.queryKey,this.queryHash=t.queryHash,this.#e=uT(this.options),this.state=t.state??this.#e,this.scheduleGc()}get meta(){return this.options.meta}get promise(){return this.#r?.promise}setOptions(t){if(this.options={...this.#s,...t},this.updateGcTime(this.options.gcTime),this.state&&this.state.data===void 0){const e=uT(this.options);e.data!==void 0&&(this.setState(cT(e.data,e.dataUpdatedAt)),this.#e=e)}}optionalRemove(){!this.observers.length&&this.state.fetchStatus==="idle"&&this.#n.remove(this)}setData(t,e){const n=d0(this.state.data,t,this.options);return this.#a({data:n,type:"success",dataUpdatedAt:e?.updatedAt,manual:e?.manual}),n}setState(t,e){this.#a({type:"setState",state:t,setStateOptions:e})}cancel(t){const e=this.#r?.promise;return this.#r?.cancel(t),e?e.then(ar).catch(ar):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}reset(){this.destroy(),this.setState(this.#e)}isActive(){return this.observers.some(t=>ni(t.options.enabled,this)!==!1)}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===ux||this.state.dataUpdateCount+this.state.errorUpdateCount===0}isStatic(){return this.getObserversCount()>0?this.observers.some(t=>Ns(t.options.staleTime,this)==="static"):!1}isStale(){return this.getObserversCount()>0?this.observers.some(t=>t.getCurrentResult().isStale):this.state.data===void 0||this.state.isInvalidated}isStaleByTime(t=0){return this.state.data===void 0?!0:t==="static"?!1:this.state.isInvalidated?!0:!nR(this.state.dataUpdatedAt,t)}onFocus(){this.observers.find(e=>e.shouldFetchOnWindowFocus())?.refetch({cancelRefetch:!1}),this.#r?.continue()}onOnline(){this.observers.find(e=>e.shouldFetchOnReconnect())?.refetch({cancelRefetch:!1}),this.#r?.continue()}addObserver(t){this.observers.includes(t)||(this.observers.push(t),this.clearGcTimeout(),this.#n.notify({type:"observerAdded",query:this,observer:t}))}removeObserver(t){this.observers.includes(t)&&(this.observers=this.observers.filter(e=>e!==t),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:t}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||this.#a({type:"invalidate"})}async fetch(t,e){if(this.state.fetchStatus!=="idle"&&this.#r?.status()!=="rejected"){if(this.state.data!==void 0&&e?.cancelRefetch)this.cancel({silent:!0});else if(this.#r)return this.#r.continueRetry(),this.#r.promise}if(t&&this.setOptions(t),!this.options.queryFn){const c=this.observers.find(u=>u.options.queryFn);c&&this.setOptions(c.options)}const n=new AbortController,r=c=>{Object.defineProperty(c,"signal",{enumerable:!0,get:()=>(this.#o=!0,n.signal)})},i=()=>{const c=iR(this.options,e),f=(()=>{const h={client:this.#i,queryKey:this.queryKey,meta:this.meta};return r(h),h})();return this.#o=!1,this.options.persister?this.options.persister(c,f,this):c(f)},o=(()=>{const c={fetchOptions:e,options:this.options,queryKey:this.queryKey,client:this.#i,state:this.state,fetchFn:i};return r(c),c})();this.options.behavior?.onFetch(o,this),this.#t=this.state,(this.state.fetchStatus==="idle"||this.state.fetchMeta!==o.fetchOptions?.meta)&&this.#a({type:"fetch",meta:o.fetchOptions?.meta}),this.#r=oR({initialPromise:e?.initialPromise,fn:o.fetchFn,onCancel:c=>{c instanceof h0&&c.revert&&this.setState({...this.#t,fetchStatus:"idle"}),n.abort()},onFail:(c,u)=>{this.#a({type:"failed",failureCount:c,error:u})},onPause:()=>{this.#a({type:"pause"})},onContinue:()=>{this.#a({type:"continue"})},retry:o.options.retry,retryDelay:o.options.retryDelay,networkMode:o.options.networkMode,canRun:()=>!0});try{const c=await this.#r.start();if(c===void 0)throw new Error(`${this.queryHash} data is undefined`);return this.setData(c),this.#n.config.onSuccess?.(c,this),this.#n.config.onSettled?.(c,this.state.error,this),c}catch(c){if(c instanceof h0){if(c.silent)return this.#r.promise;if(c.revert){if(this.state.data===void 0)throw c;return this.state.data}}throw this.#a({type:"error",error:c}),this.#n.config.onError?.(c,this),this.#n.config.onSettled?.(this.state.data,c,this),c}finally{this.scheduleGc()}}#a(t){const e=n=>{switch(t.type){case"failed":return{...n,fetchFailureCount:t.failureCount,fetchFailureReason:t.error};case"pause":return{...n,fetchStatus:"paused"};case"continue":return{...n,fetchStatus:"fetching"};case"fetch":return{...n,...cR(n.data,this.options),fetchMeta:t.meta??null};case"success":const r={...n,...cT(t.data,t.dataUpdatedAt),dataUpdateCount:n.dataUpdateCount+1,...!t.manual&&{fetchStatus:"idle",fetchFailureCount:0,fetchFailureReason:null}};return this.#t=t.manual?r:void 0,r;case"error":const i=t.error;return{...n,error:i,errorUpdateCount:n.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:n.fetchFailureCount+1,fetchFailureReason:i,fetchStatus:"idle",status:"error"};case"invalidate":return{...n,isInvalidated:!0};case"setState":return{...n,...t.state}}};this.state=e(this.state),An.batch(()=>{this.observers.forEach(n=>{n.onQueryUpdate()}),this.#n.notify({query:this,type:"updated",action:t})})}};function cR(t,e){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:sR(e.networkMode)?"fetching":"paused",...t===void 0&&{error:null,status:"pending"}}}function cT(t,e){return{data:t,dataUpdatedAt:e??Date.now(),error:null,isInvalidated:!1,status:"success"}}function uT(t){const e=typeof t.initialData=="function"?t.initialData():t.initialData,n=e!==void 0,r=n?typeof t.initialDataUpdatedAt=="function"?t.initialDataUpdatedAt():t.initialDataUpdatedAt:0;return{data:e,dataUpdateCount:0,dataUpdatedAt:n?r??Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null,isInvalidated:!1,status:n?"success":"pending",fetchStatus:"idle"}}var AL=class extends zc{constructor(t,e){super(),this.options=e,this.#e=t,this.#a=null,this.#o=f0(),this.bindMethods(),this.setOptions(e)}#e;#t=void 0;#n=void 0;#i=void 0;#r;#s;#o;#a;#m;#f;#h;#c;#u;#l;#p=new Set;bindMethods(){this.refetch=this.refetch.bind(this)}onSubscribe(){this.listeners.size===1&&(this.#t.addObserver(this),dT(this.#t,this.options)?this.#d():this.updateResult(),this.#y())}onUnsubscribe(){this.hasListeners()||this.destroy()}shouldFetchOnReconnect(){return p0(this.#t,this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return p0(this.#t,this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=new Set,this.#b(),this.#x(),this.#t.removeObserver(this)}setOptions(t){const e=this.options,n=this.#t;if(this.options=this.#e.defaultQueryOptions(t),this.options.enabled!==void 0&&typeof this.options.enabled!="boolean"&&typeof this.options.enabled!="function"&&typeof ni(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),e._defaulted&&!$p(this.options,e)&&this.#e.getQueryCache().notify({type:"observerOptionsUpdated",query:this.#t,observer:this});const r=this.hasListeners();r&&fT(this.#t,n,this.options,e)&&this.#d(),this.updateResult(),r&&(this.#t!==n||ni(this.options.enabled,this.#t)!==ni(e.enabled,this.#t)||Ns(this.options.staleTime,this.#t)!==Ns(e.staleTime,this.#t))&&this.#g();const i=this.#O();r&&(this.#t!==n||ni(this.options.enabled,this.#t)!==ni(e.enabled,this.#t)||i!==this.#l)&&this.#v(i)}getOptimisticResult(t){const e=this.#e.getQueryCache().build(this.#e,t),n=this.createResult(e,t);return _L(this,n)&&(this.#i=n,this.#s=this.options,this.#r=this.#t.state),n}getCurrentResult(){return this.#i}trackResult(t,e){return new Proxy(t,{get:(n,r)=>(this.trackProp(r),e?.(r),r==="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(n,r))})}trackProp(t){this.#p.add(t)}getCurrentQuery(){return this.#t}refetch({...t}={}){return this.fetch({...t})}fetchOptimistic(t){const e=this.#e.defaultQueryOptions(t),n=this.#e.getQueryCache().build(this.#e,e);return n.fetch().then(()=>this.createResult(n,e))}fetch(t){return this.#d({...t,cancelRefetch:t.cancelRefetch??!0}).then(()=>(this.updateResult(),this.#i))}#d(t){this.#S();let e=this.#t.fetch(this.options,t);return t?.throwOnError||(e=e.catch(ar)),e}#g(){this.#b();const t=Ns(this.options.staleTime,this.#t);if(Do||this.#i.isStale||!c0(t))return;const n=nR(this.#i.dataUpdatedAt,t)+1;this.#c=Eo.setTimeout(()=>{this.#i.isStale||this.updateResult()},n)}#O(){return(typeof this.options.refetchInterval=="function"?this.options.refetchInterval(this.#t):this.options.refetchInterval)??!1}#v(t){this.#x(),this.#l=t,!(Do||ni(this.options.enabled,this.#t)===!1||!c0(this.#l)||this.#l===0)&&(this.#u=Eo.setInterval(()=>{(this.options.refetchIntervalInBackground||dx.isFocused())&&this.#d()},this.#l))}#y(){this.#g(),this.#v(this.#O())}#b(){this.#c&&(Eo.clearTimeout(this.#c),this.#c=void 0)}#x(){this.#u&&(Eo.clearInterval(this.#u),this.#u=void 0)}createResult(t,e){const n=this.#t,r=this.options,i=this.#i,a=this.#r,o=this.#s,u=t!==n?t.state:this.#n,{state:f}=t;let h={...f},m=!1,g;if(e._optimisticResults){const M=this.hasListeners(),V=!M&&dT(t,e),F=M&&fT(t,n,e,r);(V||F)&&(h={...h,...cR(f.data,t.options)}),e._optimisticResults==="isRestoring"&&(h.fetchStatus="idle")}let{error:y,errorUpdatedAt:x,status:S}=h;g=h.data;let k=!1;if(e.placeholderData!==void 0&&g===void 0&&S==="pending"){let M;i?.isPlaceholderData&&e.placeholderData===o?.placeholderData?(M=i.data,k=!0):M=typeof e.placeholderData=="function"?e.placeholderData(this.#h?.state.data,this.#h):e.placeholderData,M!==void 0&&(S="success",g=d0(i?.data,M,e),m=!0)}if(e.select&&g!==void 0&&!k)if(i&&g===a?.data&&e.select===this.#m)g=this.#f;else try{this.#m=e.select,g=e.select(g),g=d0(i?.data,g,e),this.#f=g,this.#a=null}catch(M){this.#a=M}this.#a&&(y=this.#a,g=this.#f,x=Date.now(),S="error");const T=h.fetchStatus==="fetching",C=S==="pending",E=S==="error",R=C&&T,$=g!==void 0,_={status:S,fetchStatus:h.fetchStatus,isPending:C,isSuccess:S==="success",isError:E,isInitialLoading:R,isLoading:R,data:g,dataUpdatedAt:h.dataUpdatedAt,error:y,errorUpdatedAt:x,failureCount:h.fetchFailureCount,failureReason:h.fetchFailureReason,errorUpdateCount:h.errorUpdateCount,isFetched:h.dataUpdateCount>0||h.errorUpdateCount>0,isFetchedAfterMount:h.dataUpdateCount>u.dataUpdateCount||h.errorUpdateCount>u.errorUpdateCount,isFetching:T,isRefetching:T&&!C,isLoadingError:E&&!$,isPaused:h.fetchStatus==="paused",isPlaceholderData:m,isRefetchError:E&&$,isStale:fx(t,e),refetch:this.refetch,promise:this.#o,isEnabled:ni(e.enabled,t)!==!1};if(this.options.experimental_prefetchInRender){const M=W=>{_.status==="error"?W.reject(_.error):_.data!==void 0&&W.resolve(_.data)},V=()=>{const W=this.#o=_.promise=f0();M(W)},F=this.#o;switch(F.status){case"pending":t.queryHash===n.queryHash&&M(F);break;case"fulfilled":(_.status==="error"||_.data!==F.value)&&V();break;case"rejected":(_.status!=="error"||_.error!==F.reason)&&V();break}}return _}updateResult(){const t=this.#i,e=this.createResult(this.#t,this.options);if(this.#r=this.#t.state,this.#s=this.options,this.#r.data!==void 0&&(this.#h=this.#t),$p(e,t))return;this.#i=e;const n=()=>{if(!t)return!0;const{notifyOnChangeProps:r}=this.options,i=typeof r=="function"?r():r;if(i==="all"||!i&&!this.#p.size)return!0;const a=new Set(i??this.#p);return this.options.throwOnError&&a.add("error"),Object.keys(this.#i).some(o=>{const c=o;return this.#i[c]!==t[c]&&a.has(c)})};this.#w({listeners:n()})}#S(){const t=this.#e.getQueryCache().build(this.#e,this.options);if(t===this.#t)return;const e=this.#t;this.#t=t,this.#n=t.state,this.hasListeners()&&(e?.removeObserver(this),t.addObserver(this))}onQueryUpdate(){this.updateResult(),this.hasListeners()&&this.#y()}#w(t){An.batch(()=>{t.listeners&&this.listeners.forEach(e=>{e(this.#i)}),this.#e.getQueryCache().notify({query:this.#t,type:"observerResultsUpdated"})})}};function RL(t,e){return ni(e.enabled,t)!==!1&&t.state.data===void 0&&!(t.state.status==="error"&&e.retryOnMount===!1)}function dT(t,e){return RL(t,e)||t.state.data!==void 0&&p0(t,e,e.refetchOnMount)}function p0(t,e,n){if(ni(e.enabled,t)!==!1&&Ns(e.staleTime,t)!=="static"){const r=typeof n=="function"?n(t):n;return r==="always"||r!==!1&&fx(t,e)}return!1}function fT(t,e,n,r){return(t!==e||ni(r.enabled,t)===!1)&&(!n.suspense||t.state.status!=="error")&&fx(t,n)}function fx(t,e){return ni(e.enabled,t)!==!1&&t.isStaleByTime(Ns(e.staleTime,t))}function _L(t,e){return!$p(t.getCurrentResult(),e)}function hT(t){return{onFetch:(e,n)=>{const r=e.options,i=e.fetchOptions?.meta?.fetchMore?.direction,a=e.state.data?.pages||[],o=e.state.data?.pageParams||[];let c={pages:[],pageParams:[]},u=0;const f=async()=>{let h=!1;const m=x=>{Object.defineProperty(x,"signal",{enumerable:!0,get:()=>(e.signal.aborted?h=!0:e.signal.addEventListener("abort",()=>{h=!0}),e.signal)})},g=iR(e.options,e.fetchOptions),y=async(x,S,k)=>{if(h)return Promise.reject();if(S==null&&x.pages.length)return Promise.resolve(x);const C=(()=>{const P={client:e.client,queryKey:e.queryKey,pageParam:S,direction:k?"backward":"forward",meta:e.options.meta};return m(P),P})(),E=await g(C),{maxPages:R}=e.options,$=k?SL:xL;return{pages:$(x.pages,E,R),pageParams:$(x.pageParams,S,R)}};if(i&&a.length){const x=i==="backward",S=x?$L:pT,k={pages:a,pageParams:o},T=S(r,k);c=await y(k,T,x)}else{const x=t??a.length;do{const S=u===0?o[0]??r.initialPageParam:pT(r,c);if(u>0&&S==null)break;c=await y(c,S),u++}while(u<x)}return c};e.options.persister?e.fetchFn=()=>e.options.persister?.(f,{client:e.client,queryKey:e.queryKey,meta:e.options.meta,signal:e.signal},n):e.fetchFn=f}}}function pT(t,{pages:e,pageParams:n}){const r=e.length-1;return e.length>0?t.getNextPageParam(e[r],e,n[r],n):void 0}function $L(t,{pages:e,pageParams:n}){return e.length>0?t.getPreviousPageParam?.(e[0],e,n[0],n):void 0}var PL=class extends lR{#e;#t;#n;#i;constructor(t){super(),this.#e=t.client,this.mutationId=t.mutationId,this.#n=t.mutationCache,this.#t=[],this.state=t.state||uR(),this.setOptions(t.options),this.scheduleGc()}setOptions(t){this.options=t,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(t){this.#t.includes(t)||(this.#t.push(t),this.clearGcTimeout(),this.#n.notify({type:"observerAdded",mutation:this,observer:t}))}removeObserver(t){this.#t=this.#t.filter(e=>e!==t),this.scheduleGc(),this.#n.notify({type:"observerRemoved",mutation:this,observer:t})}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(t){const e=()=>{this.#r({type:"continue"})},n={client:this.#e,meta:this.options.meta,mutationKey:this.options.mutationKey};this.#i=oR({fn:()=>this.options.mutationFn?this.options.mutationFn(t,n):Promise.reject(new Error("No mutationFn found")),onFail:(a,o)=>{this.#r({type:"failed",failureCount:a,error:o})},onPause:()=>{this.#r({type:"pause"})},onContinue:e,retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>this.#n.canRun(this)});const r=this.state.status==="pending",i=!this.#i.canStart();try{if(r)e();else{this.#r({type:"pending",variables:t,isPaused:i}),await this.#n.config.onMutate?.(t,this,n);const o=await this.options.onMutate?.(t,n);o!==this.state.context&&this.#r({type:"pending",context:o,variables:t,isPaused:i})}const a=await this.#i.start();return await this.#n.config.onSuccess?.(a,t,this.state.context,this,n),await this.options.onSuccess?.(a,t,this.state.context,n),await this.#n.config.onSettled?.(a,null,this.state.variables,this.state.context,this,n),await this.options.onSettled?.(a,null,t,this.state.context,n),this.#r({type:"success",data:a}),a}catch(a){try{throw await this.#n.config.onError?.(a,t,this.state.context,this,n),await this.options.onError?.(a,t,this.state.context,n),await this.#n.config.onSettled?.(void 0,a,this.state.variables,this.state.context,this,n),await this.options.onSettled?.(void 0,a,t,this.state.context,n),a}finally{this.#r({type:"error",error:a})}}finally{this.#n.runNext(this)}}#r(t){const e=n=>{switch(t.type){case"failed":return{...n,failureCount:t.failureCount,failureReason:t.error};case"pause":return{...n,isPaused:!0};case"continue":return{...n,isPaused:!1};case"pending":return{...n,context:t.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:t.isPaused,status:"pending",variables:t.variables,submittedAt:Date.now()};case"success":return{...n,data:t.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1};case"error":return{...n,data:void 0,error:t.error,failureCount:n.failureCount+1,failureReason:t.error,isPaused:!1,status:"error"}}};this.state=e(this.state),An.batch(()=>{this.#t.forEach(n=>{n.onMutationUpdate(t)}),this.#n.notify({mutation:this,type:"updated",action:t})})}};function uR(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0}}var jL=class extends zc{constructor(t={}){super(),this.config=t,this.#e=new Set,this.#t=new Map,this.#n=0}#e;#t;#n;build(t,e,n){const r=new PL({client:t,mutationCache:this,mutationId:++this.#n,options:t.defaultMutationOptions(e),state:n});return this.add(r),r}add(t){this.#e.add(t);const e=Eh(t);if(typeof e=="string"){const n=this.#t.get(e);n?n.push(t):this.#t.set(e,[t])}this.notify({type:"added",mutation:t})}remove(t){if(this.#e.delete(t)){const e=Eh(t);if(typeof e=="string"){const n=this.#t.get(e);if(n)if(n.length>1){const r=n.indexOf(t);r!==-1&&n.splice(r,1)}else n[0]===t&&this.#t.delete(e)}}this.notify({type:"removed",mutation:t})}canRun(t){const e=Eh(t);if(typeof e=="string"){const r=this.#t.get(e)?.find(i=>i.state.status==="pending");return!r||r===t}else return!0}runNext(t){const e=Eh(t);return typeof e=="string"?this.#t.get(e)?.find(r=>r!==t&&r.state.isPaused)?.continue()??Promise.resolve():Promise.resolve()}clear(){An.batch(()=>{this.#e.forEach(t=>{this.notify({type:"removed",mutation:t})}),this.#e.clear(),this.#t.clear()})}getAll(){return Array.from(this.#e)}find(t){const e={exact:!0,...t};return this.getAll().find(n=>sT(e,n))}findAll(t={}){return this.getAll().filter(e=>sT(t,e))}notify(t){An.batch(()=>{this.listeners.forEach(e=>{e(t)})})}resumePausedMutations(){const t=this.getAll().filter(e=>e.state.isPaused);return An.batch(()=>Promise.all(t.map(e=>e.continue().catch(ar))))}};function Eh(t){return t.options.scope?.id}var ML=class extends zc{#e;#t=void 0;#n;#i;constructor(e,n){super(),this.#e=e,this.setOptions(n),this.bindMethods(),this.#r()}bindMethods(){this.mutate=this.mutate.bind(this),this.reset=this.reset.bind(this)}setOptions(e){const n=this.options;this.options=this.#e.defaultMutationOptions(e),$p(this.options,n)||this.#e.getMutationCache().notify({type:"observerOptionsUpdated",mutation:this.#n,observer:this}),n?.mutationKey&&this.options.mutationKey&&zo(n.mutationKey)!==zo(this.options.mutationKey)?this.reset():this.#n?.state.status==="pending"&&this.#n.setOptions(this.options)}onUnsubscribe(){this.hasListeners()||this.#n?.removeObserver(this)}onMutationUpdate(e){this.#r(),this.#s(e)}getCurrentResult(){return this.#t}reset(){this.#n?.removeObserver(this),this.#n=void 0,this.#r(),this.#s()}mutate(e,n){return this.#i=n,this.#n?.removeObserver(this),this.#n=this.#e.getMutationCache().build(this.#e,this.options),this.#n.addObserver(this),this.#n.execute(e)}#r(){const e=this.#n?.state??uR();this.#t={...e,isPending:e.status==="pending",isSuccess:e.status==="success",isError:e.status==="error",isIdle:e.status==="idle",mutate:this.mutate,reset:this.reset}}#s(e){An.batch(()=>{if(this.#i&&this.hasListeners()){const n=this.#t.variables,r=this.#t.context,i={client:this.#e,meta:this.options.meta,mutationKey:this.options.mutationKey};e?.type==="success"?(this.#i.onSuccess?.(e.data,n,r,i),this.#i.onSettled?.(e.data,null,n,r,i)):e?.type==="error"&&(this.#i.onError?.(e.error,n,r,i),this.#i.onSettled?.(void 0,e.error,n,r,i))}this.listeners.forEach(n=>{n(this.#t)})})}},NL=class extends zc{constructor(t={}){super(),this.config=t,this.#e=new Map}#e;build(t,e,n){const r=e.queryKey,i=e.queryHash??cx(r,e);let a=this.get(i);return a||(a=new QL({client:t,queryKey:r,queryHash:i,options:t.defaultQueryOptions(e),state:n,defaultOptions:t.getQueryDefaults(r)}),this.add(a)),a}add(t){this.#e.has(t.queryHash)||(this.#e.set(t.queryHash,t),this.notify({type:"added",query:t}))}remove(t){const e=this.#e.get(t.queryHash);e&&(t.destroy(),e===t&&this.#e.delete(t.queryHash),this.notify({type:"removed",query:t}))}clear(){An.batch(()=>{this.getAll().forEach(t=>{this.remove(t)})})}get(t){return this.#e.get(t)}getAll(){return[...this.#e.values()]}find(t){const e={exact:!0,...t};return this.getAll().find(n=>aT(e,n))}findAll(t={}){const e=this.getAll();return Object.keys(t).length>0?e.filter(n=>aT(t,n)):e}notify(t){An.batch(()=>{this.listeners.forEach(e=>{e(t)})})}onFocus(){An.batch(()=>{this.getAll().forEach(t=>{t.onFocus()})})}onOnline(){An.batch(()=>{this.getAll().forEach(t=>{t.onOnline()})})}},DL=class{#e;#t;#n;#i;#r;#s;#o;#a;constructor(t={}){this.#e=t.queryCache||new NL,this.#t=t.mutationCache||new jL,this.#n=t.defaultOptions||{},this.#i=new Map,this.#r=new Map,this.#s=0}mount(){this.#s++,this.#s===1&&(this.#o=dx.subscribe(async t=>{t&&(await this.resumePausedMutations(),this.#e.onFocus())}),this.#a=Pp.subscribe(async t=>{t&&(await this.resumePausedMutations(),this.#e.onOnline())}))}unmount(){this.#s--,this.#s===0&&(this.#o?.(),this.#o=void 0,this.#a?.(),this.#a=void 0)}isFetching(t){return this.#e.findAll({...t,fetchStatus:"fetching"}).length}isMutating(t){return this.#t.findAll({...t,status:"pending"}).length}getQueryData(t){const e=this.defaultQueryOptions({queryKey:t});return this.#e.get(e.queryHash)?.state.data}ensureQueryData(t){const e=this.defaultQueryOptions(t),n=this.#e.build(this,e),r=n.state.data;return r===void 0?this.fetchQuery(t):(t.revalidateIfStale&&n.isStaleByTime(Ns(e.staleTime,n))&&this.prefetchQuery(e),Promise.resolve(r))}getQueriesData(t){return this.#e.findAll(t).map(({queryKey:e,state:n})=>{const r=n.data;return[e,r]})}setQueryData(t,e,n){const r=this.defaultQueryOptions({queryKey:t}),a=this.#e.get(r.queryHash)?.state.data,o=vL(e,a);if(o!==void 0)return this.#e.build(this,r).setData(o,{...n,manual:!0})}setQueriesData(t,e,n){return An.batch(()=>this.#e.findAll(t).map(({queryKey:r})=>[r,this.setQueryData(r,e,n)]))}getQueryState(t){const e=this.defaultQueryOptions({queryKey:t});return this.#e.get(e.queryHash)?.state}removeQueries(t){const e=this.#e;An.batch(()=>{e.findAll(t).forEach(n=>{e.remove(n)})})}resetQueries(t,e){const n=this.#e;return An.batch(()=>(n.findAll(t).forEach(r=>{r.reset()}),this.refetchQueries({type:"active",...t},e)))}cancelQueries(t,e={}){const n={revert:!0,...e},r=An.batch(()=>this.#e.findAll(t).map(i=>i.cancel(n)));return Promise.all(r).then(ar).catch(ar)}invalidateQueries(t,e={}){return An.batch(()=>(this.#e.findAll(t).forEach(n=>{n.invalidate()}),t?.refetchType==="none"?Promise.resolve():this.refetchQueries({...t,type:t?.refetchType??t?.type??"active"},e)))}refetchQueries(t,e={}){const n={...e,cancelRefetch:e.cancelRefetch??!0},r=An.batch(()=>this.#e.findAll(t).filter(i=>!i.isDisabled()&&!i.isStatic()).map(i=>{let a=i.fetch(void 0,n);return n.throwOnError||(a=a.catch(ar)),i.state.fetchStatus==="paused"?Promise.resolve():a}));return Promise.all(r).then(ar)}fetchQuery(t){const e=this.defaultQueryOptions(t);e.retry===void 0&&(e.retry=!1);const n=this.#e.build(this,e);return n.isStaleByTime(Ns(e.staleTime,n))?n.fetch(e):Promise.resolve(n.state.data)}prefetchQuery(t){return this.fetchQuery(t).then(ar).catch(ar)}fetchInfiniteQuery(t){return t.behavior=hT(t.pages),this.fetchQuery(t)}prefetchInfiniteQuery(t){return this.fetchInfiniteQuery(t).then(ar).catch(ar)}ensureInfiniteQueryData(t){return t.behavior=hT(t.pages),this.ensureQueryData(t)}resumePausedMutations(){return Pp.isOnline()?this.#t.resumePausedMutations():Promise.resolve()}getQueryCache(){return this.#e}getMutationCache(){return this.#t}getDefaultOptions(){return this.#n}setDefaultOptions(t){this.#n=t}setQueryDefaults(t,e){this.#i.set(zo(t),{queryKey:t,defaultOptions:e})}getQueryDefaults(t){const e=[...this.#i.values()],n={};return e.forEach(r=>{vd(t,r.queryKey)&&Object.assign(n,r.defaultOptions)}),n}setMutationDefaults(t,e){this.#r.set(zo(t),{mutationKey:t,defaultOptions:e})}getMutationDefaults(t){const e=[...this.#r.values()],n={};return e.forEach(r=>{vd(t,r.mutationKey)&&Object.assign(n,r.defaultOptions)}),n}defaultQueryOptions(t){if(t._defaulted)return t;const e={...this.#n.queries,...this.getQueryDefaults(t.queryKey),...t,_defaulted:!0};return e.queryHash||(e.queryHash=cx(e.queryKey,e)),e.refetchOnReconnect===void 0&&(e.refetchOnReconnect=e.networkMode!=="always"),e.throwOnError===void 0&&(e.throwOnError=!!e.suspense),!e.networkMode&&e.persister&&(e.networkMode="offlineFirst"),e.queryFn===ux&&(e.enabled=!1),e}defaultMutationOptions(t){return t?._defaulted?t:{...this.#n.mutations,...t?.mutationKey&&this.getMutationDefaults(t.mutationKey),...t,_defaulted:!0}}clear(){this.#e.clear(),this.#t.clear()}},dR=w.createContext(void 0),Ud=t=>{const e=w.useContext(dR);if(!e)throw new Error("No QueryClient set, use QueryClientProvider to set one");return e},zL=({client:t,children:e})=>(w.useEffect(()=>(t.mount(),()=>{t.unmount()}),[t]),v.jsx(dR.Provider,{value:t,children:e})),fR=w.createContext(!1),LL=()=>w.useContext(fR);fR.Provider;function ZL(){let t=!1;return{clearReset:()=>{t=!1},reset:()=>{t=!0},isReset:()=>t}}var VL=w.createContext(ZL()),XL=()=>w.useContext(VL),BL=(t,e)=>{(t.suspense||t.throwOnError||t.experimental_prefetchInRender)&&(e.isReset()||(t.retryOnMount=!1))},IL=t=>{w.useEffect(()=>{t.clearReset()},[t])},qL=({result:t,errorResetBoundary:e,throwOnError:n,query:r,suspense:i})=>t.isError&&!e.isReset()&&!t.isFetching&&r&&(i&&t.data===void 0||aR(n,[t.error,r])),UL=t=>{if(t.suspense){const n=i=>i==="static"?i:Math.max(i??1e3,1e3),r=t.staleTime;t.staleTime=typeof r=="function"?(...i)=>n(r(...i)):n(r),typeof t.gcTime=="number"&&(t.gcTime=Math.max(t.gcTime,1e3))}},YL=(t,e)=>t.isLoading&&t.isFetching&&!e,FL=(t,e)=>t?.suspense&&e.isPending,mT=(t,e,n)=>e.fetchOptimistic(t).catch(()=>{n.clearReset()});function WL(t,e,n){const r=LL(),i=XL(),a=Ud(),o=a.defaultQueryOptions(t);a.getDefaultOptions().queries?._experimental_beforeQuery?.(o),o._optimisticResults=r?"isRestoring":"optimistic",UL(o),BL(o,i),IL(i);const c=!a.getQueryCache().get(o.queryHash),[u]=w.useState(()=>new e(a,o)),f=u.getOptimisticResult(o),h=!r&&t.subscribed!==!1;if(w.useSyncExternalStore(w.useCallback(m=>{const g=h?u.subscribe(An.batchCalls(m)):ar;return u.updateResult(),g},[u,h]),()=>u.getCurrentResult(),()=>u.getCurrentResult()),w.useEffect(()=>{u.setOptions(o)},[o,u]),FL(o,f))throw mT(o,u,i);if(qL({result:f,errorResetBoundary:i,throwOnError:o.throwOnError,query:a.getQueryCache().get(o.queryHash),suspense:o.suspense}))throw f.error;return a.getDefaultOptions().queries?._experimental_afterQuery?.(o,f),o.experimental_prefetchInRender&&!Do&&YL(f,r)&&(c?mT(o,u,i):a.getQueryCache().get(o.queryHash)?.promise)?.catch(ar).finally(()=>{u.updateResult()}),o.notifyOnChangeProps?f:u.trackResult(f)}function Yd(t,e){return WL(t,AL)}function Qm(t,e){const n=Ud(),[r]=w.useState(()=>new ML(n,t));w.useEffect(()=>{r.setOptions(t)},[r,t]);const i=w.useSyncExternalStore(w.useCallback(o=>r.subscribe(An.batchCalls(o)),[r]),()=>r.getCurrentResult(),()=>r.getCurrentResult()),a=w.useCallback((o,c)=>{r.mutate(o,c).catch(ar)},[r]);if(i.error&&aR(r.options.throwOnError,[i.error]))throw i.error;return{...i,mutate:a,mutateAsync:i.mutate}}function hR(t,e){return function(){return t.apply(e,arguments)}}const{toString:GL}=Object.prototype,{getPrototypeOf:hx}=Object,{iterator:Am,toStringTag:pR}=Symbol,Rm=(t=>e=>{const n=GL.call(e);return t[n]||(t[n]=n.slice(8,-1).toLowerCase())})(Object.create(null)),Pi=t=>(t=t.toLowerCase(),e=>Rm(e)===t),_m=t=>e=>typeof e===t,{isArray:Lc}=Array,hc=_m("undefined");function Fd(t){return t!==null&&!hc(t)&&t.constructor!==null&&!hc(t.constructor)&&Er(t.constructor.isBuffer)&&t.constructor.isBuffer(t)}const mR=Pi("ArrayBuffer");function HL(t){let e;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?e=ArrayBuffer.isView(t):e=t&&t.buffer&&mR(t.buffer),e}const KL=_m("string"),Er=_m("function"),gR=_m("number"),Wd=t=>t!==null&&typeof t=="object",JL=t=>t===!0||t===!1,up=t=>{if(Rm(t)!=="object")return!1;const e=hx(t);return(e===null||e===Object.prototype||Object.getPrototypeOf(e)===null)&&!(pR in t)&&!(Am in t)},eZ=t=>{if(!Wd(t)||Fd(t))return!1;try{return Object.keys(t).length===0&&Object.getPrototypeOf(t)===Object.prototype}catch{return!1}},tZ=Pi("Date"),nZ=Pi("File"),rZ=Pi("Blob"),iZ=Pi("FileList"),aZ=t=>Wd(t)&&Er(t.pipe),sZ=t=>{let e;return t&&(typeof FormData=="function"&&t instanceof FormData||Er(t.append)&&((e=Rm(t))==="formdata"||e==="object"&&Er(t.toString)&&t.toString()==="[object FormData]"))},oZ=Pi("URLSearchParams"),[lZ,cZ,uZ,dZ]=["ReadableStream","Request","Response","Headers"].map(Pi),fZ=t=>t.trim?t.trim():t.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function Gd(t,e,{allOwnKeys:n=!1}={}){if(t===null||typeof t>"u")return;let r,i;if(typeof t!="object"&&(t=[t]),Lc(t))for(r=0,i=t.length;r<i;r++)e.call(null,t[r],r,t);else{if(Fd(t))return;const a=n?Object.getOwnPropertyNames(t):Object.keys(t),o=a.length;let c;for(r=0;r<o;r++)c=a[r],e.call(null,t[c],c,t)}}function OR(t,e){if(Fd(t))return null;e=e.toLowerCase();const n=Object.keys(t);let r=n.length,i;for(;r-- >0;)if(i=n[r],e===i.toLowerCase())return i;return null}const Qo=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global,vR=t=>!hc(t)&&t!==Qo;function m0(){const{caseless:t,skipUndefined:e}=vR(this)&&this||{},n={},r=(i,a)=>{const o=t&&OR(n,a)||a;up(n[o])&&up(i)?n[o]=m0(n[o],i):up(i)?n[o]=m0({},i):Lc(i)?n[o]=i.slice():(!e||!hc(i))&&(n[o]=i)};for(let i=0,a=arguments.length;i<a;i++)arguments[i]&&Gd(arguments[i],r);return n}const hZ=(t,e,n,{allOwnKeys:r}={})=>(Gd(e,(i,a)=>{n&&Er(i)?t[a]=hR(i,n):t[a]=i},{allOwnKeys:r}),t),pZ=t=>(t.charCodeAt(0)===65279&&(t=t.slice(1)),t),mZ=(t,e,n,r)=>{t.prototype=Object.create(e.prototype,r),t.prototype.constructor=t,Object.defineProperty(t,"super",{value:e.prototype}),n&&Object.assign(t.prototype,n)},gZ=(t,e,n,r)=>{let i,a,o;const c={};if(e=e||{},t==null)return e;do{for(i=Object.getOwnPropertyNames(t),a=i.length;a-- >0;)o=i[a],(!r||r(o,t,e))&&!c[o]&&(e[o]=t[o],c[o]=!0);t=n!==!1&&hx(t)}while(t&&(!n||n(t,e))&&t!==Object.prototype);return e},OZ=(t,e,n)=>{t=String(t),(n===void 0||n>t.length)&&(n=t.length),n-=e.length;const r=t.indexOf(e,n);return r!==-1&&r===n},vZ=t=>{if(!t)return null;if(Lc(t))return t;let e=t.length;if(!gR(e))return null;const n=new Array(e);for(;e-- >0;)n[e]=t[e];return n},yZ=(t=>e=>t&&e instanceof t)(typeof Uint8Array<"u"&&hx(Uint8Array)),bZ=(t,e)=>{const r=(t&&t[Am]).call(t);let i;for(;(i=r.next())&&!i.done;){const a=i.value;e.call(t,a[0],a[1])}},xZ=(t,e)=>{let n;const r=[];for(;(n=t.exec(e))!==null;)r.push(n);return r},SZ=Pi("HTMLFormElement"),wZ=t=>t.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(n,r,i){return r.toUpperCase()+i}),gT=(({hasOwnProperty:t})=>(e,n)=>t.call(e,n))(Object.prototype),kZ=Pi("RegExp"),yR=(t,e)=>{const n=Object.getOwnPropertyDescriptors(t),r={};Gd(n,(i,a)=>{let o;(o=e(i,a,t))!==!1&&(r[a]=o||i)}),Object.defineProperties(t,r)},CZ=t=>{yR(t,(e,n)=>{if(Er(t)&&["arguments","caller","callee"].indexOf(n)!==-1)return!1;const r=t[n];if(Er(r)){if(e.enumerable=!1,"writable"in e){e.writable=!1;return}e.set||(e.set=()=>{throw Error("Can not rewrite read-only method '"+n+"'")})}})},TZ=(t,e)=>{const n={},r=i=>{i.forEach(a=>{n[a]=!0})};return Lc(t)?r(t):r(String(t).split(e)),n},EZ=()=>{},QZ=(t,e)=>t!=null&&Number.isFinite(t=+t)?t:e;function AZ(t){return!!(t&&Er(t.append)&&t[pR]==="FormData"&&t[Am])}const RZ=t=>{const e=new Array(10),n=(r,i)=>{if(Wd(r)){if(e.indexOf(r)>=0)return;if(Fd(r))return r;if(!("toJSON"in r)){e[i]=r;const a=Lc(r)?[]:{};return Gd(r,(o,c)=>{const u=n(o,i+1);!hc(u)&&(a[c]=u)}),e[i]=void 0,a}}return r};return n(t,0)},_Z=Pi("AsyncFunction"),$Z=t=>t&&(Wd(t)||Er(t))&&Er(t.then)&&Er(t.catch),bR=((t,e)=>t?setImmediate:e?((n,r)=>(Qo.addEventListener("message",({source:i,data:a})=>{i===Qo&&a===n&&r.length&&r.shift()()},!1),i=>{r.push(i),Qo.postMessage(n,"*")}))(`axios@${Math.random()}`,[]):n=>setTimeout(n))(typeof setImmediate=="function",Er(Qo.postMessage)),PZ=typeof queueMicrotask<"u"?queueMicrotask.bind(Qo):typeof process<"u"&&process.nextTick||bR,jZ=t=>t!=null&&Er(t[Am]),ce={isArray:Lc,isArrayBuffer:mR,isBuffer:Fd,isFormData:sZ,isArrayBufferView:HL,isString:KL,isNumber:gR,isBoolean:JL,isObject:Wd,isPlainObject:up,isEmptyObject:eZ,isReadableStream:lZ,isRequest:cZ,isResponse:uZ,isHeaders:dZ,isUndefined:hc,isDate:tZ,isFile:nZ,isBlob:rZ,isRegExp:kZ,isFunction:Er,isStream:aZ,isURLSearchParams:oZ,isTypedArray:yZ,isFileList:iZ,forEach:Gd,merge:m0,extend:hZ,trim:fZ,stripBOM:pZ,inherits:mZ,toFlatObject:gZ,kindOf:Rm,kindOfTest:Pi,endsWith:OZ,toArray:vZ,forEachEntry:bZ,matchAll:xZ,isHTMLForm:SZ,hasOwnProperty:gT,hasOwnProp:gT,reduceDescriptors:yR,freezeMethods:CZ,toObjectSet:TZ,toCamelCase:wZ,noop:EZ,toFiniteNumber:QZ,findKey:OR,global:Qo,isContextDefined:vR,isSpecCompliantForm:AZ,toJSONObject:RZ,isAsyncFn:_Z,isThenable:$Z,setImmediate:bR,asap:PZ,isIterable:jZ};function st(t,e,n,r,i){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack,this.message=t,this.name="AxiosError",e&&(this.code=e),n&&(this.config=n),r&&(this.request=r),i&&(this.response=i,this.status=i.status?i.status:null)}ce.inherits(st,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:ce.toJSONObject(this.config),code:this.code,status:this.status}}});const xR=st.prototype,SR={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED","ERR_NOT_SUPPORT","ERR_INVALID_URL"].forEach(t=>{SR[t]={value:t}});Object.defineProperties(st,SR);Object.defineProperty(xR,"isAxiosError",{value:!0});st.from=(t,e,n,r,i,a)=>{const o=Object.create(xR);ce.toFlatObject(t,o,function(h){return h!==Error.prototype},f=>f!=="isAxiosError");const c=t&&t.message?t.message:"Error",u=e==null&&t?t.code:e;return st.call(o,c,u,n,r,i),t&&o.cause==null&&Object.defineProperty(o,"cause",{value:t,configurable:!0}),o.name=t&&t.name||"Error",a&&Object.assign(o,a),o};const MZ=null;function g0(t){return ce.isPlainObject(t)||ce.isArray(t)}function wR(t){return ce.endsWith(t,"[]")?t.slice(0,-2):t}function OT(t,e,n){return t?t.concat(e).map(function(i,a){return i=wR(i),!n&&a?"["+i+"]":i}).join(n?".":""):e}function NZ(t){return ce.isArray(t)&&!t.some(g0)}const DZ=ce.toFlatObject(ce,{},null,function(e){return/^is[A-Z]/.test(e)});function $m(t,e,n){if(!ce.isObject(t))throw new TypeError("target must be an object");e=e||new FormData,n=ce.toFlatObject(n,{metaTokens:!0,dots:!1,indexes:!1},!1,function(S,k){return!ce.isUndefined(k[S])});const r=n.metaTokens,i=n.visitor||h,a=n.dots,o=n.indexes,u=(n.Blob||typeof Blob<"u"&&Blob)&&ce.isSpecCompliantForm(e);if(!ce.isFunction(i))throw new TypeError("visitor must be a function");function f(x){if(x===null)return"";if(ce.isDate(x))return x.toISOString();if(ce.isBoolean(x))return x.toString();if(!u&&ce.isBlob(x))throw new st("Blob is not supported. Use a Buffer instead.");return ce.isArrayBuffer(x)||ce.isTypedArray(x)?u&&typeof Blob=="function"?new Blob([x]):Buffer.from(x):x}function h(x,S,k){let T=x;if(x&&!k&&typeof x=="object"){if(ce.endsWith(S,"{}"))S=r?S:S.slice(0,-2),x=JSON.stringify(x);else if(ce.isArray(x)&&NZ(x)||(ce.isFileList(x)||ce.endsWith(S,"[]"))&&(T=ce.toArray(x)))return S=wR(S),T.forEach(function(E,R){!(ce.isUndefined(E)||E===null)&&e.append(o===!0?OT([S],R,a):o===null?S:S+"[]",f(E))}),!1}return g0(x)?!0:(e.append(OT(k,S,a),f(x)),!1)}const m=[],g=Object.assign(DZ,{defaultVisitor:h,convertValue:f,isVisitable:g0});function y(x,S){if(!ce.isUndefined(x)){if(m.indexOf(x)!==-1)throw Error("Circular reference detected in "+S.join("."));m.push(x),ce.forEach(x,function(T,C){(!(ce.isUndefined(T)||T===null)&&i.call(e,T,ce.isString(C)?C.trim():C,S,g))===!0&&y(T,S?S.concat(C):[C])}),m.pop()}}if(!ce.isObject(t))throw new TypeError("data must be an object");return y(t),e}function vT(t){const e={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(t).replace(/[!'()~]|%20|%00/g,function(r){return e[r]})}function px(t,e){this._pairs=[],t&&$m(t,this,e)}const kR=px.prototype;kR.append=function(e,n){this._pairs.push([e,n])};kR.toString=function(e){const n=e?function(r){return e.call(this,r,vT)}:vT;return this._pairs.map(function(i){return n(i[0])+"="+n(i[1])},"").join("&")};function zZ(t){return encodeURIComponent(t).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+")}function CR(t,e,n){if(!e)return t;const r=n&&n.encode||zZ;ce.isFunction(n)&&(n={serialize:n});const i=n&&n.serialize;let a;if(i?a=i(e,n):a=ce.isURLSearchParams(e)?e.toString():new px(e,n).toString(r),a){const o=t.indexOf("#");o!==-1&&(t=t.slice(0,o)),t+=(t.indexOf("?")===-1?"?":"&")+a}return t}class yT{constructor(){this.handlers=[]}use(e,n,r){return this.handlers.push({fulfilled:e,rejected:n,synchronous:r?r.synchronous:!1,runWhen:r?r.runWhen:null}),this.handlers.length-1}eject(e){this.handlers[e]&&(this.handlers[e]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(e){ce.forEach(this.handlers,function(r){r!==null&&e(r)})}}const TR={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},LZ=typeof URLSearchParams<"u"?URLSearchParams:px,ZZ=typeof FormData<"u"?FormData:null,VZ=typeof Blob<"u"?Blob:null,XZ={isBrowser:!0,classes:{URLSearchParams:LZ,FormData:ZZ,Blob:VZ},protocols:["http","https","file","blob","url","data"]},mx=typeof window<"u"&&typeof document<"u",O0=typeof navigator=="object"&&navigator||void 0,BZ=mx&&(!O0||["ReactNative","NativeScript","NS"].indexOf(O0.product)<0),IZ=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",qZ=mx&&window.location.href||"http://localhost",UZ=Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:mx,hasStandardBrowserEnv:BZ,hasStandardBrowserWebWorkerEnv:IZ,navigator:O0,origin:qZ},Symbol.toStringTag,{value:"Module"})),Gn={...UZ,...XZ};function YZ(t,e){return $m(t,new Gn.classes.URLSearchParams,{visitor:function(n,r,i,a){return Gn.isNode&&ce.isBuffer(n)?(this.append(r,n.toString("base64")),!1):a.defaultVisitor.apply(this,arguments)},...e})}function FZ(t){return ce.matchAll(/\w+|\[(\w*)]/g,t).map(e=>e[0]==="[]"?"":e[1]||e[0])}function WZ(t){const e={},n=Object.keys(t);let r;const i=n.length;let a;for(r=0;r<i;r++)a=n[r],e[a]=t[a];return e}function ER(t){function e(n,r,i,a){let o=n[a++];if(o==="__proto__")return!0;const c=Number.isFinite(+o),u=a>=n.length;return o=!o&&ce.isArray(i)?i.length:o,u?(ce.hasOwnProp(i,o)?i[o]=[i[o],r]:i[o]=r,!c):((!i[o]||!ce.isObject(i[o]))&&(i[o]=[]),e(n,r,i[o],a)&&ce.isArray(i[o])&&(i[o]=WZ(i[o])),!c)}if(ce.isFormData(t)&&ce.isFunction(t.entries)){const n={};return ce.forEachEntry(t,(r,i)=>{e(FZ(r),i,n,0)}),n}return null}function GZ(t,e,n){if(ce.isString(t))try{return(e||JSON.parse)(t),ce.trim(t)}catch(r){if(r.name!=="SyntaxError")throw r}return(n||JSON.stringify)(t)}const Hd={transitional:TR,adapter:["xhr","http","fetch"],transformRequest:[function(e,n){const r=n.getContentType()||"",i=r.indexOf("application/json")>-1,a=ce.isObject(e);if(a&&ce.isHTMLForm(e)&&(e=new FormData(e)),ce.isFormData(e))return i?JSON.stringify(ER(e)):e;if(ce.isArrayBuffer(e)||ce.isBuffer(e)||ce.isStream(e)||ce.isFile(e)||ce.isBlob(e)||ce.isReadableStream(e))return e;if(ce.isArrayBufferView(e))return e.buffer;if(ce.isURLSearchParams(e))return n.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),e.toString();let c;if(a){if(r.indexOf("application/x-www-form-urlencoded")>-1)return YZ(e,this.formSerializer).toString();if((c=ce.isFileList(e))||r.indexOf("multipart/form-data")>-1){const u=this.env&&this.env.FormData;return $m(c?{"files[]":e}:e,u&&new u,this.formSerializer)}}return a||i?(n.setContentType("application/json",!1),GZ(e)):e}],transformResponse:[function(e){const n=this.transitional||Hd.transitional,r=n&&n.forcedJSONParsing,i=this.responseType==="json";if(ce.isResponse(e)||ce.isReadableStream(e))return e;if(e&&ce.isString(e)&&(r&&!this.responseType||i)){const o=!(n&&n.silentJSONParsing)&&i;try{return JSON.parse(e,this.parseReviver)}catch(c){if(o)throw c.name==="SyntaxError"?st.from(c,st.ERR_BAD_RESPONSE,this,null,this.response):c}}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:Gn.classes.FormData,Blob:Gn.classes.Blob},validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};ce.forEach(["delete","get","head","post","put","patch"],t=>{Hd.headers[t]={}});const HZ=ce.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),KZ=t=>{const e={};let n,r,i;return t&&t.split(`
|
|
13
|
-
`).forEach(function(o){i=o.indexOf(":"),n=o.substring(0,i).trim().toLowerCase(),r=o.substring(i+1).trim(),!(!n||e[n]&&HZ[n])&&(n==="set-cookie"?e[n]?e[n].push(r):e[n]=[r]:e[n]=e[n]?e[n]+", "+r:r)}),e},bT=Symbol("internals");function Vu(t){return t&&String(t).trim().toLowerCase()}function dp(t){return t===!1||t==null?t:ce.isArray(t)?t.map(dp):String(t)}function JZ(t){const e=Object.create(null),n=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let r;for(;r=n.exec(t);)e[r[1]]=r[2];return e}const e6=t=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(t.trim());function Yv(t,e,n,r,i){if(ce.isFunction(r))return r.call(this,e,n);if(i&&(e=n),!!ce.isString(e)){if(ce.isString(r))return e.indexOf(r)!==-1;if(ce.isRegExp(r))return r.test(e)}}function t6(t){return t.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(e,n,r)=>n.toUpperCase()+r)}function n6(t,e){const n=ce.toCamelCase(" "+e);["get","set","has"].forEach(r=>{Object.defineProperty(t,r+n,{value:function(i,a,o){return this[r].call(this,e,i,a,o)},configurable:!0})})}let Qr=class{constructor(e){e&&this.set(e)}set(e,n,r){const i=this;function a(c,u,f){const h=Vu(u);if(!h)throw new Error("header name must be a non-empty string");const m=ce.findKey(i,h);(!m||i[m]===void 0||f===!0||f===void 0&&i[m]!==!1)&&(i[m||u]=dp(c))}const o=(c,u)=>ce.forEach(c,(f,h)=>a(f,h,u));if(ce.isPlainObject(e)||e instanceof this.constructor)o(e,n);else if(ce.isString(e)&&(e=e.trim())&&!e6(e))o(KZ(e),n);else if(ce.isObject(e)&&ce.isIterable(e)){let c={},u,f;for(const h of e){if(!ce.isArray(h))throw TypeError("Object iterator must return a key-value pair");c[f=h[0]]=(u=c[f])?ce.isArray(u)?[...u,h[1]]:[u,h[1]]:h[1]}o(c,n)}else e!=null&&a(n,e,r);return this}get(e,n){if(e=Vu(e),e){const r=ce.findKey(this,e);if(r){const i=this[r];if(!n)return i;if(n===!0)return JZ(i);if(ce.isFunction(n))return n.call(this,i,r);if(ce.isRegExp(n))return n.exec(i);throw new TypeError("parser must be boolean|regexp|function")}}}has(e,n){if(e=Vu(e),e){const r=ce.findKey(this,e);return!!(r&&this[r]!==void 0&&(!n||Yv(this,this[r],r,n)))}return!1}delete(e,n){const r=this;let i=!1;function a(o){if(o=Vu(o),o){const c=ce.findKey(r,o);c&&(!n||Yv(r,r[c],c,n))&&(delete r[c],i=!0)}}return ce.isArray(e)?e.forEach(a):a(e),i}clear(e){const n=Object.keys(this);let r=n.length,i=!1;for(;r--;){const a=n[r];(!e||Yv(this,this[a],a,e,!0))&&(delete this[a],i=!0)}return i}normalize(e){const n=this,r={};return ce.forEach(this,(i,a)=>{const o=ce.findKey(r,a);if(o){n[o]=dp(i),delete n[a];return}const c=e?t6(a):String(a).trim();c!==a&&delete n[a],n[c]=dp(i),r[c]=!0}),this}concat(...e){return this.constructor.concat(this,...e)}toJSON(e){const n=Object.create(null);return ce.forEach(this,(r,i)=>{r!=null&&r!==!1&&(n[i]=e&&ce.isArray(r)?r.join(", "):r)}),n}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([e,n])=>e+": "+n).join(`
|
|
14
|
-
`)}getSetCookie(){return this.get("set-cookie")||[]}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(e){return e instanceof this?e:new this(e)}static concat(e,...n){const r=new this(e);return n.forEach(i=>r.set(i)),r}static accessor(e){const r=(this[bT]=this[bT]={accessors:{}}).accessors,i=this.prototype;function a(o){const c=Vu(o);r[c]||(n6(i,o),r[c]=!0)}return ce.isArray(e)?e.forEach(a):a(e),this}};Qr.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]);ce.reduceDescriptors(Qr.prototype,({value:t},e)=>{let n=e[0].toUpperCase()+e.slice(1);return{get:()=>t,set(r){this[n]=r}}});ce.freezeMethods(Qr);function Fv(t,e){const n=this||Hd,r=e||n,i=Qr.from(r.headers);let a=r.data;return ce.forEach(t,function(c){a=c.call(n,a,i.normalize(),e?e.status:void 0)}),i.normalize(),a}function QR(t){return!!(t&&t.__CANCEL__)}function Zc(t,e,n){st.call(this,t??"canceled",st.ERR_CANCELED,e,n),this.name="CanceledError"}ce.inherits(Zc,st,{__CANCEL__:!0});function AR(t,e,n){const r=n.config.validateStatus;!n.status||!r||r(n.status)?t(n):e(new st("Request failed with status code "+n.status,[st.ERR_BAD_REQUEST,st.ERR_BAD_RESPONSE][Math.floor(n.status/100)-4],n.config,n.request,n))}function r6(t){const e=/^([-+\w]{1,25})(:?\/\/|:)/.exec(t);return e&&e[1]||""}function i6(t,e){t=t||10;const n=new Array(t),r=new Array(t);let i=0,a=0,o;return e=e!==void 0?e:1e3,function(u){const f=Date.now(),h=r[a];o||(o=f),n[i]=u,r[i]=f;let m=a,g=0;for(;m!==i;)g+=n[m++],m=m%t;if(i=(i+1)%t,i===a&&(a=(a+1)%t),f-o<e)return;const y=h&&f-h;return y?Math.round(g*1e3/y):void 0}}function a6(t,e){let n=0,r=1e3/e,i,a;const o=(f,h=Date.now())=>{n=h,i=null,a&&(clearTimeout(a),a=null),t(...f)};return[(...f)=>{const h=Date.now(),m=h-n;m>=r?o(f,h):(i=f,a||(a=setTimeout(()=>{a=null,o(i)},r-m)))},()=>i&&o(i)]}const jp=(t,e,n=3)=>{let r=0;const i=i6(50,250);return a6(a=>{const o=a.loaded,c=a.lengthComputable?a.total:void 0,u=o-r,f=i(u),h=o<=c;r=o;const m={loaded:o,total:c,progress:c?o/c:void 0,bytes:u,rate:f||void 0,estimated:f&&c&&h?(c-o)/f:void 0,event:a,lengthComputable:c!=null,[e?"download":"upload"]:!0};t(m)},n)},xT=(t,e)=>{const n=t!=null;return[r=>e[0]({lengthComputable:n,total:t,loaded:r}),e[1]]},ST=t=>(...e)=>ce.asap(()=>t(...e)),s6=Gn.hasStandardBrowserEnv?((t,e)=>n=>(n=new URL(n,Gn.origin),t.protocol===n.protocol&&t.host===n.host&&(e||t.port===n.port)))(new URL(Gn.origin),Gn.navigator&&/(msie|trident)/i.test(Gn.navigator.userAgent)):()=>!0,o6=Gn.hasStandardBrowserEnv?{write(t,e,n,r,i,a,o){if(typeof document>"u")return;const c=[`${t}=${encodeURIComponent(e)}`];ce.isNumber(n)&&c.push(`expires=${new Date(n).toUTCString()}`),ce.isString(r)&&c.push(`path=${r}`),ce.isString(i)&&c.push(`domain=${i}`),a===!0&&c.push("secure"),ce.isString(o)&&c.push(`SameSite=${o}`),document.cookie=c.join("; ")},read(t){if(typeof document>"u")return null;const e=document.cookie.match(new RegExp("(?:^|; )"+t+"=([^;]*)"));return e?decodeURIComponent(e[1]):null},remove(t){this.write(t,"",Date.now()-864e5,"/")}}:{write(){},read(){return null},remove(){}};function l6(t){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(t)}function c6(t,e){return e?t.replace(/\/?\/$/,"")+"/"+e.replace(/^\/+/,""):t}function RR(t,e,n){let r=!l6(e);return t&&(r||n==!1)?c6(t,e):e}const wT=t=>t instanceof Qr?{...t}:t;function Lo(t,e){e=e||{};const n={};function r(f,h,m,g){return ce.isPlainObject(f)&&ce.isPlainObject(h)?ce.merge.call({caseless:g},f,h):ce.isPlainObject(h)?ce.merge({},h):ce.isArray(h)?h.slice():h}function i(f,h,m,g){if(ce.isUndefined(h)){if(!ce.isUndefined(f))return r(void 0,f,m,g)}else return r(f,h,m,g)}function a(f,h){if(!ce.isUndefined(h))return r(void 0,h)}function o(f,h){if(ce.isUndefined(h)){if(!ce.isUndefined(f))return r(void 0,f)}else return r(void 0,h)}function c(f,h,m){if(m in e)return r(f,h);if(m in t)return r(void 0,f)}const u={url:a,method:a,data:a,baseURL:o,transformRequest:o,transformResponse:o,paramsSerializer:o,timeout:o,timeoutMessage:o,withCredentials:o,withXSRFToken:o,adapter:o,responseType:o,xsrfCookieName:o,xsrfHeaderName:o,onUploadProgress:o,onDownloadProgress:o,decompress:o,maxContentLength:o,maxBodyLength:o,beforeRedirect:o,transport:o,httpAgent:o,httpsAgent:o,cancelToken:o,socketPath:o,responseEncoding:o,validateStatus:c,headers:(f,h,m)=>i(wT(f),wT(h),m,!0)};return ce.forEach(Object.keys({...t,...e}),function(h){const m=u[h]||i,g=m(t[h],e[h],h);ce.isUndefined(g)&&m!==c||(n[h]=g)}),n}const _R=t=>{const e=Lo({},t);let{data:n,withXSRFToken:r,xsrfHeaderName:i,xsrfCookieName:a,headers:o,auth:c}=e;if(e.headers=o=Qr.from(o),e.url=CR(RR(e.baseURL,e.url,e.allowAbsoluteUrls),t.params,t.paramsSerializer),c&&o.set("Authorization","Basic "+btoa((c.username||"")+":"+(c.password?unescape(encodeURIComponent(c.password)):""))),ce.isFormData(n)){if(Gn.hasStandardBrowserEnv||Gn.hasStandardBrowserWebWorkerEnv)o.setContentType(void 0);else if(ce.isFunction(n.getHeaders)){const u=n.getHeaders(),f=["content-type","content-length"];Object.entries(u).forEach(([h,m])=>{f.includes(h.toLowerCase())&&o.set(h,m)})}}if(Gn.hasStandardBrowserEnv&&(r&&ce.isFunction(r)&&(r=r(e)),r||r!==!1&&s6(e.url))){const u=i&&a&&o6.read(a);u&&o.set(i,u)}return e},u6=typeof XMLHttpRequest<"u",d6=u6&&function(t){return new Promise(function(n,r){const i=_R(t);let a=i.data;const o=Qr.from(i.headers).normalize();let{responseType:c,onUploadProgress:u,onDownloadProgress:f}=i,h,m,g,y,x;function S(){y&&y(),x&&x(),i.cancelToken&&i.cancelToken.unsubscribe(h),i.signal&&i.signal.removeEventListener("abort",h)}let k=new XMLHttpRequest;k.open(i.method.toUpperCase(),i.url,!0),k.timeout=i.timeout;function T(){if(!k)return;const E=Qr.from("getAllResponseHeaders"in k&&k.getAllResponseHeaders()),$={data:!c||c==="text"||c==="json"?k.responseText:k.response,status:k.status,statusText:k.statusText,headers:E,config:t,request:k};AR(function(_){n(_),S()},function(_){r(_),S()},$),k=null}"onloadend"in k?k.onloadend=T:k.onreadystatechange=function(){!k||k.readyState!==4||k.status===0&&!(k.responseURL&&k.responseURL.indexOf("file:")===0)||setTimeout(T)},k.onabort=function(){k&&(r(new st("Request aborted",st.ECONNABORTED,t,k)),k=null)},k.onerror=function(R){const $=R&&R.message?R.message:"Network Error",P=new st($,st.ERR_NETWORK,t,k);P.event=R||null,r(P),k=null},k.ontimeout=function(){let R=i.timeout?"timeout of "+i.timeout+"ms exceeded":"timeout exceeded";const $=i.transitional||TR;i.timeoutErrorMessage&&(R=i.timeoutErrorMessage),r(new st(R,$.clarifyTimeoutError?st.ETIMEDOUT:st.ECONNABORTED,t,k)),k=null},a===void 0&&o.setContentType(null),"setRequestHeader"in k&&ce.forEach(o.toJSON(),function(R,$){k.setRequestHeader($,R)}),ce.isUndefined(i.withCredentials)||(k.withCredentials=!!i.withCredentials),c&&c!=="json"&&(k.responseType=i.responseType),f&&([g,x]=jp(f,!0),k.addEventListener("progress",g)),u&&k.upload&&([m,y]=jp(u),k.upload.addEventListener("progress",m),k.upload.addEventListener("loadend",y)),(i.cancelToken||i.signal)&&(h=E=>{k&&(r(!E||E.type?new Zc(null,t,k):E),k.abort(),k=null)},i.cancelToken&&i.cancelToken.subscribe(h),i.signal&&(i.signal.aborted?h():i.signal.addEventListener("abort",h)));const C=r6(i.url);if(C&&Gn.protocols.indexOf(C)===-1){r(new st("Unsupported protocol "+C+":",st.ERR_BAD_REQUEST,t));return}k.send(a||null)})},f6=(t,e)=>{const{length:n}=t=t?t.filter(Boolean):[];if(e||n){let r=new AbortController,i;const a=function(f){if(!i){i=!0,c();const h=f instanceof Error?f:this.reason;r.abort(h instanceof st?h:new Zc(h instanceof Error?h.message:h))}};let o=e&&setTimeout(()=>{o=null,a(new st(`timeout ${e} of ms exceeded`,st.ETIMEDOUT))},e);const c=()=>{t&&(o&&clearTimeout(o),o=null,t.forEach(f=>{f.unsubscribe?f.unsubscribe(a):f.removeEventListener("abort",a)}),t=null)};t.forEach(f=>f.addEventListener("abort",a));const{signal:u}=r;return u.unsubscribe=()=>ce.asap(c),u}},h6=function*(t,e){let n=t.byteLength;if(n<e){yield t;return}let r=0,i;for(;r<n;)i=r+e,yield t.slice(r,i),r=i},p6=async function*(t,e){for await(const n of m6(t))yield*h6(n,e)},m6=async function*(t){if(t[Symbol.asyncIterator]){yield*t;return}const e=t.getReader();try{for(;;){const{done:n,value:r}=await e.read();if(n)break;yield r}}finally{await e.cancel()}},kT=(t,e,n,r)=>{const i=p6(t,e);let a=0,o,c=u=>{o||(o=!0,r&&r(u))};return new ReadableStream({async pull(u){try{const{done:f,value:h}=await i.next();if(f){c(),u.close();return}let m=h.byteLength;if(n){let g=a+=m;n(g)}u.enqueue(new Uint8Array(h))}catch(f){throw c(f),f}},cancel(u){return c(u),i.return()}},{highWaterMark:2})},CT=64*1024,{isFunction:Qh}=ce,g6=(({Request:t,Response:e})=>({Request:t,Response:e}))(ce.global),{ReadableStream:TT,TextEncoder:ET}=ce.global,QT=(t,...e)=>{try{return!!t(...e)}catch{return!1}},O6=t=>{t=ce.merge.call({skipUndefined:!0},g6,t);const{fetch:e,Request:n,Response:r}=t,i=e?Qh(e):typeof fetch=="function",a=Qh(n),o=Qh(r);if(!i)return!1;const c=i&&Qh(TT),u=i&&(typeof ET=="function"?(x=>S=>x.encode(S))(new ET):async x=>new Uint8Array(await new n(x).arrayBuffer())),f=a&&c&&QT(()=>{let x=!1;const S=new n(Gn.origin,{body:new TT,method:"POST",get duplex(){return x=!0,"half"}}).headers.has("Content-Type");return x&&!S}),h=o&&c&&QT(()=>ce.isReadableStream(new r("").body)),m={stream:h&&(x=>x.body)};i&&["text","arrayBuffer","blob","formData","stream"].forEach(x=>{!m[x]&&(m[x]=(S,k)=>{let T=S&&S[x];if(T)return T.call(S);throw new st(`Response type '${x}' is not supported`,st.ERR_NOT_SUPPORT,k)})});const g=async x=>{if(x==null)return 0;if(ce.isBlob(x))return x.size;if(ce.isSpecCompliantForm(x))return(await new n(Gn.origin,{method:"POST",body:x}).arrayBuffer()).byteLength;if(ce.isArrayBufferView(x)||ce.isArrayBuffer(x))return x.byteLength;if(ce.isURLSearchParams(x)&&(x=x+""),ce.isString(x))return(await u(x)).byteLength},y=async(x,S)=>{const k=ce.toFiniteNumber(x.getContentLength());return k??g(S)};return async x=>{let{url:S,method:k,data:T,signal:C,cancelToken:E,timeout:R,onDownloadProgress:$,onUploadProgress:P,responseType:_,headers:M,withCredentials:V="same-origin",fetchOptions:F}=_R(x),W=e||fetch;_=_?(_+"").toLowerCase():"text";let I=f6([C,E&&E.toAbortSignal()],R),ne=null;const ee=I&&I.unsubscribe&&(()=>{I.unsubscribe()});let pe;try{if(P&&f&&k!=="get"&&k!=="head"&&(pe=await y(M,T))!==0){let A=new n(S,{method:"POST",body:T,duplex:"half"}),N;if(ce.isFormData(T)&&(N=A.headers.get("content-type"))&&M.setContentType(N),A.body){const[L,q]=xT(pe,jp(ST(P)));T=kT(A.body,CT,L,q)}}ce.isString(V)||(V=V?"include":"omit");const D=a&&"credentials"in n.prototype,G={...F,signal:I,method:k.toUpperCase(),headers:M.normalize().toJSON(),body:T,duplex:"half",credentials:D?V:void 0};ne=a&&new n(S,G);let B=await(a?W(ne,F):W(S,G));const ye=h&&(_==="stream"||_==="response");if(h&&($||ye&&ee)){const A={};["status","statusText","headers"].forEach(se=>{A[se]=B[se]});const N=ce.toFiniteNumber(B.headers.get("content-length")),[L,q]=$&&xT(N,jp(ST($),!0))||[];B=new r(kT(B.body,CT,L,()=>{q&&q(),ee&&ee()}),A)}_=_||"text";let X=await m[ce.findKey(m,_)||"text"](B,x);return!ye&&ee&&ee(),await new Promise((A,N)=>{AR(A,N,{data:X,headers:Qr.from(B.headers),status:B.status,statusText:B.statusText,config:x,request:ne})})}catch(D){throw ee&&ee(),D&&D.name==="TypeError"&&/Load failed|fetch/i.test(D.message)?Object.assign(new st("Network Error",st.ERR_NETWORK,x,ne),{cause:D.cause||D}):st.from(D,D&&D.code,x,ne)}}},v6=new Map,$R=t=>{let e=t&&t.env||{};const{fetch:n,Request:r,Response:i}=e,a=[r,i,n];let o=a.length,c=o,u,f,h=v6;for(;c--;)u=a[c],f=h.get(u),f===void 0&&h.set(u,f=c?new Map:O6(e)),h=f;return f};$R();const gx={http:MZ,xhr:d6,fetch:{get:$R}};ce.forEach(gx,(t,e)=>{if(t){try{Object.defineProperty(t,"name",{value:e})}catch{}Object.defineProperty(t,"adapterName",{value:e})}});const AT=t=>`- ${t}`,y6=t=>ce.isFunction(t)||t===null||t===!1;function b6(t,e){t=ce.isArray(t)?t:[t];const{length:n}=t;let r,i;const a={};for(let o=0;o<n;o++){r=t[o];let c;if(i=r,!y6(r)&&(i=gx[(c=String(r)).toLowerCase()],i===void 0))throw new st(`Unknown adapter '${c}'`);if(i&&(ce.isFunction(i)||(i=i.get(e))))break;a[c||"#"+o]=i}if(!i){const o=Object.entries(a).map(([u,f])=>`adapter ${u} `+(f===!1?"is not supported by the environment":"is not available in the build"));let c=n?o.length>1?`since :
|
|
15
|
-
`+o.map(AT).join(`
|
|
16
|
-
`):" "+AT(o[0]):"as no adapter specified";throw new st("There is no suitable adapter to dispatch the request "+c,"ERR_NOT_SUPPORT")}return i}const PR={getAdapter:b6,adapters:gx};function Wv(t){if(t.cancelToken&&t.cancelToken.throwIfRequested(),t.signal&&t.signal.aborted)throw new Zc(null,t)}function RT(t){return Wv(t),t.headers=Qr.from(t.headers),t.data=Fv.call(t,t.transformRequest),["post","put","patch"].indexOf(t.method)!==-1&&t.headers.setContentType("application/x-www-form-urlencoded",!1),PR.getAdapter(t.adapter||Hd.adapter,t)(t).then(function(r){return Wv(t),r.data=Fv.call(t,t.transformResponse,r),r.headers=Qr.from(r.headers),r},function(r){return QR(r)||(Wv(t),r&&r.response&&(r.response.data=Fv.call(t,t.transformResponse,r.response),r.response.headers=Qr.from(r.response.headers))),Promise.reject(r)})}const jR="1.13.2",Pm={};["object","boolean","number","function","string","symbol"].forEach((t,e)=>{Pm[t]=function(r){return typeof r===t||"a"+(e<1?"n ":" ")+t}});const _T={};Pm.transitional=function(e,n,r){function i(a,o){return"[Axios v"+jR+"] Transitional option '"+a+"'"+o+(r?". "+r:"")}return(a,o,c)=>{if(e===!1)throw new st(i(o," has been removed"+(n?" in "+n:"")),st.ERR_DEPRECATED);return n&&!_T[o]&&(_T[o]=!0,console.warn(i(o," has been deprecated since v"+n+" and will be removed in the near future"))),e?e(a,o,c):!0}};Pm.spelling=function(e){return(n,r)=>(console.warn(`${r} is likely a misspelling of ${e}`),!0)};function x6(t,e,n){if(typeof t!="object")throw new st("options must be an object",st.ERR_BAD_OPTION_VALUE);const r=Object.keys(t);let i=r.length;for(;i-- >0;){const a=r[i],o=e[a];if(o){const c=t[a],u=c===void 0||o(c,a,t);if(u!==!0)throw new st("option "+a+" must be "+u,st.ERR_BAD_OPTION_VALUE);continue}if(n!==!0)throw new st("Unknown option "+a,st.ERR_BAD_OPTION)}}const fp={assertOptions:x6,validators:Pm},Ui=fp.validators;let Po=class{constructor(e){this.defaults=e||{},this.interceptors={request:new yT,response:new yT}}async request(e,n){try{return await this._request(e,n)}catch(r){if(r instanceof Error){let i={};Error.captureStackTrace?Error.captureStackTrace(i):i=new Error;const a=i.stack?i.stack.replace(/^.+\n/,""):"";try{r.stack?a&&!String(r.stack).endsWith(a.replace(/^.+\n.+\n/,""))&&(r.stack+=`
|
|
17
|
-
`+a):r.stack=a}catch{}}throw r}}_request(e,n){typeof e=="string"?(n=n||{},n.url=e):n=e||{},n=Lo(this.defaults,n);const{transitional:r,paramsSerializer:i,headers:a}=n;r!==void 0&&fp.assertOptions(r,{silentJSONParsing:Ui.transitional(Ui.boolean),forcedJSONParsing:Ui.transitional(Ui.boolean),clarifyTimeoutError:Ui.transitional(Ui.boolean)},!1),i!=null&&(ce.isFunction(i)?n.paramsSerializer={serialize:i}:fp.assertOptions(i,{encode:Ui.function,serialize:Ui.function},!0)),n.allowAbsoluteUrls!==void 0||(this.defaults.allowAbsoluteUrls!==void 0?n.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:n.allowAbsoluteUrls=!0),fp.assertOptions(n,{baseUrl:Ui.spelling("baseURL"),withXsrfToken:Ui.spelling("withXSRFToken")},!0),n.method=(n.method||this.defaults.method||"get").toLowerCase();let o=a&&ce.merge(a.common,a[n.method]);a&&ce.forEach(["delete","get","head","post","put","patch","common"],x=>{delete a[x]}),n.headers=Qr.concat(o,a);const c=[];let u=!0;this.interceptors.request.forEach(function(S){typeof S.runWhen=="function"&&S.runWhen(n)===!1||(u=u&&S.synchronous,c.unshift(S.fulfilled,S.rejected))});const f=[];this.interceptors.response.forEach(function(S){f.push(S.fulfilled,S.rejected)});let h,m=0,g;if(!u){const x=[RT.bind(this),void 0];for(x.unshift(...c),x.push(...f),g=x.length,h=Promise.resolve(n);m<g;)h=h.then(x[m++],x[m++]);return h}g=c.length;let y=n;for(;m<g;){const x=c[m++],S=c[m++];try{y=x(y)}catch(k){S.call(this,k);break}}try{h=RT.call(this,y)}catch(x){return Promise.reject(x)}for(m=0,g=f.length;m<g;)h=h.then(f[m++],f[m++]);return h}getUri(e){e=Lo(this.defaults,e);const n=RR(e.baseURL,e.url,e.allowAbsoluteUrls);return CR(n,e.params,e.paramsSerializer)}};ce.forEach(["delete","get","head","options"],function(e){Po.prototype[e]=function(n,r){return this.request(Lo(r||{},{method:e,url:n,data:(r||{}).data}))}});ce.forEach(["post","put","patch"],function(e){function n(r){return function(a,o,c){return this.request(Lo(c||{},{method:e,headers:r?{"Content-Type":"multipart/form-data"}:{},url:a,data:o}))}}Po.prototype[e]=n(),Po.prototype[e+"Form"]=n(!0)});let S6=class MR{constructor(e){if(typeof e!="function")throw new TypeError("executor must be a function.");let n;this.promise=new Promise(function(a){n=a});const r=this;this.promise.then(i=>{if(!r._listeners)return;let a=r._listeners.length;for(;a-- >0;)r._listeners[a](i);r._listeners=null}),this.promise.then=i=>{let a;const o=new Promise(c=>{r.subscribe(c),a=c}).then(i);return o.cancel=function(){r.unsubscribe(a)},o},e(function(a,o,c){r.reason||(r.reason=new Zc(a,o,c),n(r.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(e){if(this.reason){e(this.reason);return}this._listeners?this._listeners.push(e):this._listeners=[e]}unsubscribe(e){if(!this._listeners)return;const n=this._listeners.indexOf(e);n!==-1&&this._listeners.splice(n,1)}toAbortSignal(){const e=new AbortController,n=r=>{e.abort(r)};return this.subscribe(n),e.signal.unsubscribe=()=>this.unsubscribe(n),e.signal}static source(){let e;return{token:new MR(function(i){e=i}),cancel:e}}};function w6(t){return function(n){return t.apply(null,n)}}function k6(t){return ce.isObject(t)&&t.isAxiosError===!0}const v0={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511,WebServerIsDown:521,ConnectionTimedOut:522,OriginIsUnreachable:523,TimeoutOccurred:524,SslHandshakeFailed:525,InvalidSslCertificate:526};Object.entries(v0).forEach(([t,e])=>{v0[e]=t});function NR(t){const e=new Po(t),n=hR(Po.prototype.request,e);return ce.extend(n,Po.prototype,e,{allOwnKeys:!0}),ce.extend(n,e,null,{allOwnKeys:!0}),n.create=function(i){return NR(Lo(t,i))},n}const Mt=NR(Hd);Mt.Axios=Po;Mt.CanceledError=Zc;Mt.CancelToken=S6;Mt.isCancel=QR;Mt.VERSION=jR;Mt.toFormData=$m;Mt.AxiosError=st;Mt.Cancel=Mt.CanceledError;Mt.all=function(e){return Promise.all(e)};Mt.spread=w6;Mt.isAxiosError=k6;Mt.mergeConfig=Lo;Mt.AxiosHeaders=Qr;Mt.formToJSON=t=>ER(ce.isHTMLForm(t)?new FormData(t):t);Mt.getAdapter=PR.getAdapter;Mt.HttpStatusCode=v0;Mt.default=Mt;const{Axios:Cae,AxiosError:Tae,CanceledError:Eae,isCancel:Qae,CancelToken:Aae,VERSION:Rae,all:_ae,Cancel:$ae,isAxiosError:Pae,spread:jae,toFormData:Mae,AxiosHeaders:Nae,HttpStatusCode:Dae,formToJSON:zae,getAdapter:Lae,mergeConfig:Zae}=Mt;function C6(){const t=Ud();return Qm({mutationFn:e=>Mt.post("/api/icons/create",e).then(n=>n.data),onSuccess:e=>{t.invalidateQueries({queryKey:["icons"]});const n=e.icon.name.toLowerCase().replace(/ /g,"-");t.invalidateQueries({queryKey:["icon",n]})}})}function T6(){return Yd({queryKey:["icons"],queryFn:()=>Mt.get("/api/icons").then(t=>t.data)})}function DR(t){return Yd({queryKey:["icon",t],queryFn:()=>Mt.get(`/api/icons/${t}`).then(e=>e.data),enabled:!!t})}function E6(){const t=Ud();return Qm({mutationFn:e=>Mt.delete(`/api/icons/${e}`).then(n=>n.data),onSuccess:()=>{t.invalidateQueries({queryKey:["icons"]})}})}const zR=w.createContext(void 0),Q6=({children:t})=>{const e=typeof window<"u"?localStorage.getItem("iconoma-studio-preview-color"):"#e5e5e5",[n,r]=w.useState(e||"#e5e5e5"),[i,a]=w.useState(null),o=()=>{if(typeof window>"u")return{};try{const h=localStorage.getItem("iconoma-studio-color-variables");if(h)return JSON.parse(h)}catch{}return{}},[c,u]=w.useState(o),f=(h,m)=>{u(g=>{const y={...g,[h]:m};return typeof window<"u"&&localStorage.setItem("iconoma-studio-color-variables",JSON.stringify(y)),y})};return w.useEffect(()=>{localStorage.setItem("iconoma-studio-preview-color",n)},[n]),v.jsx(zR.Provider,{value:{previewColor:n,setPreviewColor:r,colorPickerHint:i,setColorPickerHint:a,colorVariableValues:c,setColorVariableValue:f},children:t})};function jm(){const t=w.useContext(zR);if(!t)throw new Error("useStudio must be used within a StudioProvider");return t}function Kd(){return Yd({queryKey:["config"],queryFn:()=>Mt.get("/api/config").then(t=>t.data)})}function A6(){return Qm({mutationFn:t=>Mt.post("/api/config/changes",t).then(e=>e.data)})}function Ox(){const t=Ud();return Qm({mutationFn:e=>Mt.post("/api/config",e).then(n=>n.data),onSuccess:()=>{t.invalidateQueries({queryKey:["config"]})}})}function nc({content:t,className:e,style:n}){const{previewColor:r,colorVariableValues:i}=jm(),{data:a}=Kd(),o=a?.colorVariables||[],c=w.useMemo(()=>{const u={color:r};return o.forEach(f=>{const h=i[f]||"#e5e5e5";u[f]=h}),u},[r,i,o]);return v.jsx("div",{className:e,style:{...c,...n},dangerouslySetInnerHTML:{__html:t}})}function $T(t,e){if(typeof t=="function")return t(e);t!=null&&(t.current=e)}function vx(...t){return e=>{let n=!1;const r=t.map(i=>{const a=$T(i,e);return!n&&typeof a=="function"&&(n=!0),a});if(n)return()=>{for(let i=0;i<r.length;i++){const a=r[i];typeof a=="function"?a():$T(t[i],null)}}}}function ft(...t){return w.useCallback(vx(...t),t)}var R6=Symbol.for("react.lazy"),Mp=rx[" use ".trim().toString()];function _6(t){return typeof t=="object"&&t!==null&&"then"in t}function LR(t){return t!=null&&typeof t=="object"&&"$$typeof"in t&&t.$$typeof===R6&&"_payload"in t&&_6(t._payload)}function ZR(t){const e=$6(t),n=w.forwardRef((r,i)=>{let{children:a,...o}=r;LR(a)&&typeof Mp=="function"&&(a=Mp(a._payload));const c=w.Children.toArray(a),u=c.find(j6);if(u){const f=u.props.children,h=c.map(m=>m===u?w.Children.count(f)>1?w.Children.only(null):w.isValidElement(f)?f.props.children:null:m);return v.jsx(e,{...o,ref:i,children:w.isValidElement(f)?w.cloneElement(f,void 0,h):null})}return v.jsx(e,{...o,ref:i,children:a})});return n.displayName=`${t}.Slot`,n}var VR=ZR("Slot");function $6(t){const e=w.forwardRef((n,r)=>{let{children:i,...a}=n;if(LR(i)&&typeof Mp=="function"&&(i=Mp(i._payload)),w.isValidElement(i)){const o=N6(i),c=M6(a,i.props);return i.type!==w.Fragment&&(c.ref=r?vx(r,o):o),w.cloneElement(i,c)}return w.Children.count(i)>1?w.Children.only(null):null});return e.displayName=`${t}.SlotClone`,e}var P6=Symbol("radix.slottable");function j6(t){return w.isValidElement(t)&&typeof t.type=="function"&&"__radixId"in t.type&&t.type.__radixId===P6}function M6(t,e){const n={...e};for(const r in e){const i=t[r],a=e[r];/^on[A-Z]/.test(r)?i&&a?n[r]=(...c)=>{const u=a(...c);return i(...c),u}:i&&(n[r]=i):r==="style"?n[r]={...i,...a}:r==="className"&&(n[r]=[i,a].filter(Boolean).join(" "))}return{...t,...n}}function N6(t){let e=Object.getOwnPropertyDescriptor(t.props,"ref")?.get,n=e&&"isReactWarning"in e&&e.isReactWarning;return n?t.ref:(e=Object.getOwnPropertyDescriptor(t,"ref")?.get,n=e&&"isReactWarning"in e&&e.isReactWarning,n?t.props.ref:t.props.ref||t.ref)}function XR(t){var e,n,r="";if(typeof t=="string"||typeof t=="number")r+=t;else if(typeof t=="object")if(Array.isArray(t)){var i=t.length;for(e=0;e<i;e++)t[e]&&(n=XR(t[e]))&&(r&&(r+=" "),r+=n)}else for(n in t)t[n]&&(r&&(r+=" "),r+=n);return r}function BR(){for(var t,e,n=0,r="",i=arguments.length;n<i;n++)(t=arguments[n])&&(e=XR(t))&&(r&&(r+=" "),r+=e);return r}const PT=t=>typeof t=="boolean"?`${t}`:t===0?"0":t,jT=BR,Mm=(t,e)=>n=>{var r;if(e?.variants==null)return jT(t,n?.class,n?.className);const{variants:i,defaultVariants:a}=e,o=Object.keys(i).map(f=>{const h=n?.[f],m=a?.[f];if(h===null)return null;const g=PT(h)||PT(m);return i[f][g]}),c=n&&Object.entries(n).reduce((f,h)=>{let[m,g]=h;return g===void 0||(f[m]=g),f},{}),u=e==null||(r=e.compoundVariants)===null||r===void 0?void 0:r.reduce((f,h)=>{let{class:m,className:g,...y}=h;return Object.entries(y).every(x=>{let[S,k]=x;return Array.isArray(k)?k.includes({...a,...c}[S]):{...a,...c}[S]===k})?[...f,m,g]:f},[]);return jT(t,o,u,n?.class,n?.className)},D6=(t,e)=>{const n=new Array(t.length+e.length);for(let r=0;r<t.length;r++)n[r]=t[r];for(let r=0;r<e.length;r++)n[t.length+r]=e[r];return n},z6=(t,e)=>({classGroupId:t,validator:e}),IR=(t=new Map,e=null,n)=>({nextPart:t,validators:e,classGroupId:n}),Np="-",MT=[],L6="arbitrary..",Z6=t=>{const e=X6(t),{conflictingClassGroups:n,conflictingClassGroupModifiers:r}=t;return{getClassGroupId:o=>{if(o.startsWith("[")&&o.endsWith("]"))return V6(o);const c=o.split(Np),u=c[0]===""&&c.length>1?1:0;return qR(c,u,e)},getConflictingClassGroupIds:(o,c)=>{if(c){const u=r[o],f=n[o];return u?f?D6(f,u):u:f||MT}return n[o]||MT}}},qR=(t,e,n)=>{if(t.length-e===0)return n.classGroupId;const i=t[e],a=n.nextPart.get(i);if(a){const f=qR(t,e+1,a);if(f)return f}const o=n.validators;if(o===null)return;const c=e===0?t.join(Np):t.slice(e).join(Np),u=o.length;for(let f=0;f<u;f++){const h=o[f];if(h.validator(c))return h.classGroupId}},V6=t=>t.slice(1,-1).indexOf(":")===-1?void 0:(()=>{const e=t.slice(1,-1),n=e.indexOf(":"),r=e.slice(0,n);return r?L6+r:void 0})(),X6=t=>{const{theme:e,classGroups:n}=t;return B6(n,e)},B6=(t,e)=>{const n=IR();for(const r in t){const i=t[r];yx(i,n,r,e)}return n},yx=(t,e,n,r)=>{const i=t.length;for(let a=0;a<i;a++){const o=t[a];I6(o,e,n,r)}},I6=(t,e,n,r)=>{if(typeof t=="string"){q6(t,e,n);return}if(typeof t=="function"){U6(t,e,n,r);return}Y6(t,e,n,r)},q6=(t,e,n)=>{const r=t===""?e:UR(e,t);r.classGroupId=n},U6=(t,e,n,r)=>{if(F6(t)){yx(t(r),e,n,r);return}e.validators===null&&(e.validators=[]),e.validators.push(z6(n,t))},Y6=(t,e,n,r)=>{const i=Object.entries(t),a=i.length;for(let o=0;o<a;o++){const[c,u]=i[o];yx(u,UR(e,c),n,r)}},UR=(t,e)=>{let n=t;const r=e.split(Np),i=r.length;for(let a=0;a<i;a++){const o=r[a];let c=n.nextPart.get(o);c||(c=IR(),n.nextPart.set(o,c)),n=c}return n},F6=t=>"isThemeGetter"in t&&t.isThemeGetter===!0,W6=t=>{if(t<1)return{get:()=>{},set:()=>{}};let e=0,n=Object.create(null),r=Object.create(null);const i=(a,o)=>{n[a]=o,e++,e>t&&(e=0,r=n,n=Object.create(null))};return{get(a){let o=n[a];if(o!==void 0)return o;if((o=r[a])!==void 0)return i(a,o),o},set(a,o){a in n?n[a]=o:i(a,o)}}},y0="!",NT=":",G6=[],DT=(t,e,n,r,i)=>({modifiers:t,hasImportantModifier:e,baseClassName:n,maybePostfixModifierPosition:r,isExternal:i}),H6=t=>{const{prefix:e,experimentalParseClassName:n}=t;let r=i=>{const a=[];let o=0,c=0,u=0,f;const h=i.length;for(let S=0;S<h;S++){const k=i[S];if(o===0&&c===0){if(k===NT){a.push(i.slice(u,S)),u=S+1;continue}if(k==="/"){f=S;continue}}k==="["?o++:k==="]"?o--:k==="("?c++:k===")"&&c--}const m=a.length===0?i:i.slice(u);let g=m,y=!1;m.endsWith(y0)?(g=m.slice(0,-1),y=!0):m.startsWith(y0)&&(g=m.slice(1),y=!0);const x=f&&f>u?f-u:void 0;return DT(a,y,g,x)};if(e){const i=e+NT,a=r;r=o=>o.startsWith(i)?a(o.slice(i.length)):DT(G6,!1,o,void 0,!0)}if(n){const i=r;r=a=>n({className:a,parseClassName:i})}return r},K6=t=>{const e=new Map;return t.orderSensitiveModifiers.forEach((n,r)=>{e.set(n,1e6+r)}),n=>{const r=[];let i=[];for(let a=0;a<n.length;a++){const o=n[a],c=o[0]==="[",u=e.has(o);c||u?(i.length>0&&(i.sort(),r.push(...i),i=[]),r.push(o)):i.push(o)}return i.length>0&&(i.sort(),r.push(...i)),r}},J6=t=>({cache:W6(t.cacheSize),parseClassName:H6(t),sortModifiers:K6(t),...Z6(t)}),eV=/\s+/,tV=(t,e)=>{const{parseClassName:n,getClassGroupId:r,getConflictingClassGroupIds:i,sortModifiers:a}=e,o=[],c=t.trim().split(eV);let u="";for(let f=c.length-1;f>=0;f-=1){const h=c[f],{isExternal:m,modifiers:g,hasImportantModifier:y,baseClassName:x,maybePostfixModifierPosition:S}=n(h);if(m){u=h+(u.length>0?" "+u:u);continue}let k=!!S,T=r(k?x.substring(0,S):x);if(!T){if(!k){u=h+(u.length>0?" "+u:u);continue}if(T=r(x),!T){u=h+(u.length>0?" "+u:u);continue}k=!1}const C=g.length===0?"":g.length===1?g[0]:a(g).join(":"),E=y?C+y0:C,R=E+T;if(o.indexOf(R)>-1)continue;o.push(R);const $=i(T,k);for(let P=0;P<$.length;++P){const _=$[P];o.push(E+_)}u=h+(u.length>0?" "+u:u)}return u},nV=(...t)=>{let e=0,n,r,i="";for(;e<t.length;)(n=t[e++])&&(r=YR(n))&&(i&&(i+=" "),i+=r);return i},YR=t=>{if(typeof t=="string")return t;let e,n="";for(let r=0;r<t.length;r++)t[r]&&(e=YR(t[r]))&&(n&&(n+=" "),n+=e);return n},rV=(t,...e)=>{let n,r,i,a;const o=u=>{const f=e.reduce((h,m)=>m(h),t());return n=J6(f),r=n.cache.get,i=n.cache.set,a=c,c(u)},c=u=>{const f=r(u);if(f)return f;const h=tV(u,n);return i(u,h),h};return a=o,(...u)=>a(nV(...u))},iV=[],Tn=t=>{const e=n=>n[t]||iV;return e.isThemeGetter=!0,e},FR=/^\[(?:(\w[\w-]*):)?(.+)\]$/i,WR=/^\((?:(\w[\w-]*):)?(.+)\)$/i,aV=/^\d+\/\d+$/,sV=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,oV=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,lV=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/,cV=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,uV=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,Xl=t=>aV.test(t),ut=t=>!!t&&!Number.isNaN(Number(t)),Cs=t=>!!t&&Number.isInteger(Number(t)),Gv=t=>t.endsWith("%")&&ut(t.slice(0,-1)),Ma=t=>sV.test(t),dV=()=>!0,fV=t=>oV.test(t)&&!lV.test(t),GR=()=>!1,hV=t=>cV.test(t),pV=t=>uV.test(t),mV=t=>!Ne(t)&&!De(t),gV=t=>Vc(t,JR,GR),Ne=t=>FR.test(t),xo=t=>Vc(t,e_,fV),Hv=t=>Vc(t,xV,ut),zT=t=>Vc(t,HR,GR),OV=t=>Vc(t,KR,pV),Ah=t=>Vc(t,t_,hV),De=t=>WR.test(t),Xu=t=>Xc(t,e_),vV=t=>Xc(t,SV),LT=t=>Xc(t,HR),yV=t=>Xc(t,JR),bV=t=>Xc(t,KR),Rh=t=>Xc(t,t_,!0),Vc=(t,e,n)=>{const r=FR.exec(t);return r?r[1]?e(r[1]):n(r[2]):!1},Xc=(t,e,n=!1)=>{const r=WR.exec(t);return r?r[1]?e(r[1]):n:!1},HR=t=>t==="position"||t==="percentage",KR=t=>t==="image"||t==="url",JR=t=>t==="length"||t==="size"||t==="bg-size",e_=t=>t==="length",xV=t=>t==="number",SV=t=>t==="family-name",t_=t=>t==="shadow",wV=()=>{const t=Tn("color"),e=Tn("font"),n=Tn("text"),r=Tn("font-weight"),i=Tn("tracking"),a=Tn("leading"),o=Tn("breakpoint"),c=Tn("container"),u=Tn("spacing"),f=Tn("radius"),h=Tn("shadow"),m=Tn("inset-shadow"),g=Tn("text-shadow"),y=Tn("drop-shadow"),x=Tn("blur"),S=Tn("perspective"),k=Tn("aspect"),T=Tn("ease"),C=Tn("animate"),E=()=>["auto","avoid","all","avoid-page","page","left","right","column"],R=()=>["center","top","bottom","left","right","top-left","left-top","top-right","right-top","bottom-right","right-bottom","bottom-left","left-bottom"],$=()=>[...R(),De,Ne],P=()=>["auto","hidden","clip","visible","scroll"],_=()=>["auto","contain","none"],M=()=>[De,Ne,u],V=()=>[Xl,"full","auto",...M()],F=()=>[Cs,"none","subgrid",De,Ne],W=()=>["auto",{span:["full",Cs,De,Ne]},Cs,De,Ne],I=()=>[Cs,"auto",De,Ne],ne=()=>["auto","min","max","fr",De,Ne],ee=()=>["start","end","center","between","around","evenly","stretch","baseline","center-safe","end-safe"],pe=()=>["start","end","center","stretch","center-safe","end-safe"],D=()=>["auto",...M()],G=()=>[Xl,"auto","full","dvw","dvh","lvw","lvh","svw","svh","min","max","fit",...M()],B=()=>[t,De,Ne],ye=()=>[...R(),LT,zT,{position:[De,Ne]}],X=()=>["no-repeat",{repeat:["","x","y","space","round"]}],A=()=>["auto","cover","contain",yV,gV,{size:[De,Ne]}],N=()=>[Gv,Xu,xo],L=()=>["","none","full",f,De,Ne],q=()=>["",ut,Xu,xo],se=()=>["solid","dashed","dotted","double"],he=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],H=()=>[ut,Gv,LT,zT],ge=()=>["","none",x,De,Ne],xe=()=>["none",ut,De,Ne],ke=()=>["none",ut,De,Ne],Ce=()=>[ut,De,Ne],Re=()=>[Xl,"full",...M()];return{cacheSize:500,theme:{animate:["spin","ping","pulse","bounce"],aspect:["video"],blur:[Ma],breakpoint:[Ma],color:[dV],container:[Ma],"drop-shadow":[Ma],ease:["in","out","in-out"],font:[mV],"font-weight":["thin","extralight","light","normal","medium","semibold","bold","extrabold","black"],"inset-shadow":[Ma],leading:["none","tight","snug","normal","relaxed","loose"],perspective:["dramatic","near","normal","midrange","distant","none"],radius:[Ma],shadow:[Ma],spacing:["px",ut],text:[Ma],"text-shadow":[Ma],tracking:["tighter","tight","normal","wide","wider","widest"]},classGroups:{aspect:[{aspect:["auto","square",Xl,Ne,De,k]}],container:["container"],columns:[{columns:[ut,Ne,De,c]}],"break-after":[{"break-after":E()}],"break-before":[{"break-before":E()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],sr:["sr-only","not-sr-only"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:$()}],overflow:[{overflow:P()}],"overflow-x":[{"overflow-x":P()}],"overflow-y":[{"overflow-y":P()}],overscroll:[{overscroll:_()}],"overscroll-x":[{"overscroll-x":_()}],"overscroll-y":[{"overscroll-y":_()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:V()}],"inset-x":[{"inset-x":V()}],"inset-y":[{"inset-y":V()}],start:[{start:V()}],end:[{end:V()}],top:[{top:V()}],right:[{right:V()}],bottom:[{bottom:V()}],left:[{left:V()}],visibility:["visible","invisible","collapse"],z:[{z:[Cs,"auto",De,Ne]}],basis:[{basis:[Xl,"full","auto",c,...M()]}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["nowrap","wrap","wrap-reverse"]}],flex:[{flex:[ut,Xl,"auto","initial","none",Ne]}],grow:[{grow:["",ut,De,Ne]}],shrink:[{shrink:["",ut,De,Ne]}],order:[{order:[Cs,"first","last","none",De,Ne]}],"grid-cols":[{"grid-cols":F()}],"col-start-end":[{col:W()}],"col-start":[{"col-start":I()}],"col-end":[{"col-end":I()}],"grid-rows":[{"grid-rows":F()}],"row-start-end":[{row:W()}],"row-start":[{"row-start":I()}],"row-end":[{"row-end":I()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":ne()}],"auto-rows":[{"auto-rows":ne()}],gap:[{gap:M()}],"gap-x":[{"gap-x":M()}],"gap-y":[{"gap-y":M()}],"justify-content":[{justify:[...ee(),"normal"]}],"justify-items":[{"justify-items":[...pe(),"normal"]}],"justify-self":[{"justify-self":["auto",...pe()]}],"align-content":[{content:["normal",...ee()]}],"align-items":[{items:[...pe(),{baseline:["","last"]}]}],"align-self":[{self:["auto",...pe(),{baseline:["","last"]}]}],"place-content":[{"place-content":ee()}],"place-items":[{"place-items":[...pe(),"baseline"]}],"place-self":[{"place-self":["auto",...pe()]}],p:[{p:M()}],px:[{px:M()}],py:[{py:M()}],ps:[{ps:M()}],pe:[{pe:M()}],pt:[{pt:M()}],pr:[{pr:M()}],pb:[{pb:M()}],pl:[{pl:M()}],m:[{m:D()}],mx:[{mx:D()}],my:[{my:D()}],ms:[{ms:D()}],me:[{me:D()}],mt:[{mt:D()}],mr:[{mr:D()}],mb:[{mb:D()}],ml:[{ml:D()}],"space-x":[{"space-x":M()}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":M()}],"space-y-reverse":["space-y-reverse"],size:[{size:G()}],w:[{w:[c,"screen",...G()]}],"min-w":[{"min-w":[c,"screen","none",...G()]}],"max-w":[{"max-w":[c,"screen","none","prose",{screen:[o]},...G()]}],h:[{h:["screen","lh",...G()]}],"min-h":[{"min-h":["screen","lh","none",...G()]}],"max-h":[{"max-h":["screen","lh",...G()]}],"font-size":[{text:["base",n,Xu,xo]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:[r,De,Hv]}],"font-stretch":[{"font-stretch":["ultra-condensed","extra-condensed","condensed","semi-condensed","normal","semi-expanded","expanded","extra-expanded","ultra-expanded",Gv,Ne]}],"font-family":[{font:[vV,Ne,e]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractions"],tracking:[{tracking:[i,De,Ne]}],"line-clamp":[{"line-clamp":[ut,"none",De,Hv]}],leading:[{leading:[a,...M()]}],"list-image":[{"list-image":["none",De,Ne]}],"list-style-position":[{list:["inside","outside"]}],"list-style-type":[{list:["disc","decimal","none",De,Ne]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"placeholder-color":[{placeholder:B()}],"text-color":[{text:B()}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...se(),"wavy"]}],"text-decoration-thickness":[{decoration:[ut,"from-font","auto",De,xo]}],"text-decoration-color":[{decoration:B()}],"underline-offset":[{"underline-offset":[ut,"auto",De,Ne]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:M()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",De,Ne]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],wrap:[{wrap:["break-word","anywhere","normal"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",De,Ne]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:ye()}],"bg-repeat":[{bg:X()}],"bg-size":[{bg:A()}],"bg-image":[{bg:["none",{linear:[{to:["t","tr","r","br","b","bl","l","tl"]},Cs,De,Ne],radial:["",De,Ne],conic:[Cs,De,Ne]},bV,OV]}],"bg-color":[{bg:B()}],"gradient-from-pos":[{from:N()}],"gradient-via-pos":[{via:N()}],"gradient-to-pos":[{to:N()}],"gradient-from":[{from:B()}],"gradient-via":[{via:B()}],"gradient-to":[{to:B()}],rounded:[{rounded:L()}],"rounded-s":[{"rounded-s":L()}],"rounded-e":[{"rounded-e":L()}],"rounded-t":[{"rounded-t":L()}],"rounded-r":[{"rounded-r":L()}],"rounded-b":[{"rounded-b":L()}],"rounded-l":[{"rounded-l":L()}],"rounded-ss":[{"rounded-ss":L()}],"rounded-se":[{"rounded-se":L()}],"rounded-ee":[{"rounded-ee":L()}],"rounded-es":[{"rounded-es":L()}],"rounded-tl":[{"rounded-tl":L()}],"rounded-tr":[{"rounded-tr":L()}],"rounded-br":[{"rounded-br":L()}],"rounded-bl":[{"rounded-bl":L()}],"border-w":[{border:q()}],"border-w-x":[{"border-x":q()}],"border-w-y":[{"border-y":q()}],"border-w-s":[{"border-s":q()}],"border-w-e":[{"border-e":q()}],"border-w-t":[{"border-t":q()}],"border-w-r":[{"border-r":q()}],"border-w-b":[{"border-b":q()}],"border-w-l":[{"border-l":q()}],"divide-x":[{"divide-x":q()}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":q()}],"divide-y-reverse":["divide-y-reverse"],"border-style":[{border:[...se(),"hidden","none"]}],"divide-style":[{divide:[...se(),"hidden","none"]}],"border-color":[{border:B()}],"border-color-x":[{"border-x":B()}],"border-color-y":[{"border-y":B()}],"border-color-s":[{"border-s":B()}],"border-color-e":[{"border-e":B()}],"border-color-t":[{"border-t":B()}],"border-color-r":[{"border-r":B()}],"border-color-b":[{"border-b":B()}],"border-color-l":[{"border-l":B()}],"divide-color":[{divide:B()}],"outline-style":[{outline:[...se(),"none","hidden"]}],"outline-offset":[{"outline-offset":[ut,De,Ne]}],"outline-w":[{outline:["",ut,Xu,xo]}],"outline-color":[{outline:B()}],shadow:[{shadow:["","none",h,Rh,Ah]}],"shadow-color":[{shadow:B()}],"inset-shadow":[{"inset-shadow":["none",m,Rh,Ah]}],"inset-shadow-color":[{"inset-shadow":B()}],"ring-w":[{ring:q()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:B()}],"ring-offset-w":[{"ring-offset":[ut,xo]}],"ring-offset-color":[{"ring-offset":B()}],"inset-ring-w":[{"inset-ring":q()}],"inset-ring-color":[{"inset-ring":B()}],"text-shadow":[{"text-shadow":["none",g,Rh,Ah]}],"text-shadow-color":[{"text-shadow":B()}],opacity:[{opacity:[ut,De,Ne]}],"mix-blend":[{"mix-blend":[...he(),"plus-darker","plus-lighter"]}],"bg-blend":[{"bg-blend":he()}],"mask-clip":[{"mask-clip":["border","padding","content","fill","stroke","view"]},"mask-no-clip"],"mask-composite":[{mask:["add","subtract","intersect","exclude"]}],"mask-image-linear-pos":[{"mask-linear":[ut]}],"mask-image-linear-from-pos":[{"mask-linear-from":H()}],"mask-image-linear-to-pos":[{"mask-linear-to":H()}],"mask-image-linear-from-color":[{"mask-linear-from":B()}],"mask-image-linear-to-color":[{"mask-linear-to":B()}],"mask-image-t-from-pos":[{"mask-t-from":H()}],"mask-image-t-to-pos":[{"mask-t-to":H()}],"mask-image-t-from-color":[{"mask-t-from":B()}],"mask-image-t-to-color":[{"mask-t-to":B()}],"mask-image-r-from-pos":[{"mask-r-from":H()}],"mask-image-r-to-pos":[{"mask-r-to":H()}],"mask-image-r-from-color":[{"mask-r-from":B()}],"mask-image-r-to-color":[{"mask-r-to":B()}],"mask-image-b-from-pos":[{"mask-b-from":H()}],"mask-image-b-to-pos":[{"mask-b-to":H()}],"mask-image-b-from-color":[{"mask-b-from":B()}],"mask-image-b-to-color":[{"mask-b-to":B()}],"mask-image-l-from-pos":[{"mask-l-from":H()}],"mask-image-l-to-pos":[{"mask-l-to":H()}],"mask-image-l-from-color":[{"mask-l-from":B()}],"mask-image-l-to-color":[{"mask-l-to":B()}],"mask-image-x-from-pos":[{"mask-x-from":H()}],"mask-image-x-to-pos":[{"mask-x-to":H()}],"mask-image-x-from-color":[{"mask-x-from":B()}],"mask-image-x-to-color":[{"mask-x-to":B()}],"mask-image-y-from-pos":[{"mask-y-from":H()}],"mask-image-y-to-pos":[{"mask-y-to":H()}],"mask-image-y-from-color":[{"mask-y-from":B()}],"mask-image-y-to-color":[{"mask-y-to":B()}],"mask-image-radial":[{"mask-radial":[De,Ne]}],"mask-image-radial-from-pos":[{"mask-radial-from":H()}],"mask-image-radial-to-pos":[{"mask-radial-to":H()}],"mask-image-radial-from-color":[{"mask-radial-from":B()}],"mask-image-radial-to-color":[{"mask-radial-to":B()}],"mask-image-radial-shape":[{"mask-radial":["circle","ellipse"]}],"mask-image-radial-size":[{"mask-radial":[{closest:["side","corner"],farthest:["side","corner"]}]}],"mask-image-radial-pos":[{"mask-radial-at":R()}],"mask-image-conic-pos":[{"mask-conic":[ut]}],"mask-image-conic-from-pos":[{"mask-conic-from":H()}],"mask-image-conic-to-pos":[{"mask-conic-to":H()}],"mask-image-conic-from-color":[{"mask-conic-from":B()}],"mask-image-conic-to-color":[{"mask-conic-to":B()}],"mask-mode":[{mask:["alpha","luminance","match"]}],"mask-origin":[{"mask-origin":["border","padding","content","fill","stroke","view"]}],"mask-position":[{mask:ye()}],"mask-repeat":[{mask:X()}],"mask-size":[{mask:A()}],"mask-type":[{"mask-type":["alpha","luminance"]}],"mask-image":[{mask:["none",De,Ne]}],filter:[{filter:["","none",De,Ne]}],blur:[{blur:ge()}],brightness:[{brightness:[ut,De,Ne]}],contrast:[{contrast:[ut,De,Ne]}],"drop-shadow":[{"drop-shadow":["","none",y,Rh,Ah]}],"drop-shadow-color":[{"drop-shadow":B()}],grayscale:[{grayscale:["",ut,De,Ne]}],"hue-rotate":[{"hue-rotate":[ut,De,Ne]}],invert:[{invert:["",ut,De,Ne]}],saturate:[{saturate:[ut,De,Ne]}],sepia:[{sepia:["",ut,De,Ne]}],"backdrop-filter":[{"backdrop-filter":["","none",De,Ne]}],"backdrop-blur":[{"backdrop-blur":ge()}],"backdrop-brightness":[{"backdrop-brightness":[ut,De,Ne]}],"backdrop-contrast":[{"backdrop-contrast":[ut,De,Ne]}],"backdrop-grayscale":[{"backdrop-grayscale":["",ut,De,Ne]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[ut,De,Ne]}],"backdrop-invert":[{"backdrop-invert":["",ut,De,Ne]}],"backdrop-opacity":[{"backdrop-opacity":[ut,De,Ne]}],"backdrop-saturate":[{"backdrop-saturate":[ut,De,Ne]}],"backdrop-sepia":[{"backdrop-sepia":["",ut,De,Ne]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":M()}],"border-spacing-x":[{"border-spacing-x":M()}],"border-spacing-y":[{"border-spacing-y":M()}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["","all","colors","opacity","shadow","transform","none",De,Ne]}],"transition-behavior":[{transition:["normal","discrete"]}],duration:[{duration:[ut,"initial",De,Ne]}],ease:[{ease:["linear","initial",T,De,Ne]}],delay:[{delay:[ut,De,Ne]}],animate:[{animate:["none",C,De,Ne]}],backface:[{backface:["hidden","visible"]}],perspective:[{perspective:[S,De,Ne]}],"perspective-origin":[{"perspective-origin":$()}],rotate:[{rotate:xe()}],"rotate-x":[{"rotate-x":xe()}],"rotate-y":[{"rotate-y":xe()}],"rotate-z":[{"rotate-z":xe()}],scale:[{scale:ke()}],"scale-x":[{"scale-x":ke()}],"scale-y":[{"scale-y":ke()}],"scale-z":[{"scale-z":ke()}],"scale-3d":["scale-3d"],skew:[{skew:Ce()}],"skew-x":[{"skew-x":Ce()}],"skew-y":[{"skew-y":Ce()}],transform:[{transform:[De,Ne,"","none","gpu","cpu"]}],"transform-origin":[{origin:$()}],"transform-style":[{transform:["3d","flat"]}],translate:[{translate:Re()}],"translate-x":[{"translate-x":Re()}],"translate-y":[{"translate-y":Re()}],"translate-z":[{"translate-z":Re()}],"translate-none":["translate-none"],accent:[{accent:B()}],appearance:[{appearance:["none","auto"]}],"caret-color":[{caret:B()}],"color-scheme":[{scheme:["normal","dark","light","light-dark","only-dark","only-light"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",De,Ne]}],"field-sizing":[{"field-sizing":["fixed","content"]}],"pointer-events":[{"pointer-events":["auto","none"]}],resize:[{resize:["none","","y","x"]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":M()}],"scroll-mx":[{"scroll-mx":M()}],"scroll-my":[{"scroll-my":M()}],"scroll-ms":[{"scroll-ms":M()}],"scroll-me":[{"scroll-me":M()}],"scroll-mt":[{"scroll-mt":M()}],"scroll-mr":[{"scroll-mr":M()}],"scroll-mb":[{"scroll-mb":M()}],"scroll-ml":[{"scroll-ml":M()}],"scroll-p":[{"scroll-p":M()}],"scroll-px":[{"scroll-px":M()}],"scroll-py":[{"scroll-py":M()}],"scroll-ps":[{"scroll-ps":M()}],"scroll-pe":[{"scroll-pe":M()}],"scroll-pt":[{"scroll-pt":M()}],"scroll-pr":[{"scroll-pr":M()}],"scroll-pb":[{"scroll-pb":M()}],"scroll-pl":[{"scroll-pl":M()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",De,Ne]}],fill:[{fill:["none",...B()]}],"stroke-w":[{stroke:[ut,Xu,xo,Hv]}],stroke:[{stroke:["none",...B()]}],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-x","border-w-y","border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-x","border-color-y","border-color-s","border-color-e","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],translate:["translate-x","translate-y","translate-none"],"translate-none":["translate","translate-x","translate-y","translate-z"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]},orderSensitiveModifiers:["*","**","after","backdrop","before","details-content","file","first-letter","first-line","marker","placeholder","selection"]}},kV=rV(wV);function Be(...t){return kV(BR(t))}const CV=Mm("cursor-pointer inline-flex items-center justify-center gap-2 whitespace-nowrap rounded-md text-sm font-medium transition-all disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg:not([class*='size-'])]:size-4 shrink-0 [&_svg]:shrink-0 outline-none focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive",{variants:{variant:{default:"bg-primary text-primary-foreground shadow-xs hover:bg-primary/90",destructive:"bg-destructive text-white shadow-xs hover:bg-destructive/90 focus-visible:ring-destructive/20 dark:focus-visible:ring-destructive/40 dark:bg-destructive/60",outline:"border bg-background shadow-xs hover:bg-accent hover:text-accent-foreground dark:bg-input/30 dark:border-input dark:hover:bg-input/50",secondary:"bg-secondary text-secondary-foreground shadow-xs hover:bg-secondary/80",ghost:"hover:bg-accent hover:text-accent-foreground dark:hover:bg-accent/50",link:"text-primary underline-offset-4 hover:underline",selectable:"group relative border bg-background border-input hover:bg-accent hover:text-accent-foreground data-[selected=true]:bg-primary/10 data-[selected=true]:border-primary data-[selected=true]:text-primary dark:data-[selected=true]:bg-primary/20 data-[selected=true]:shadow-sm"},size:{default:"h-9 px-4 py-2 has-[>svg]:px-3",sm:"h-8 rounded-md gap-1.5 px-3 has-[>svg]:px-2.5",lg:"h-10 rounded-md px-6 has-[>svg]:px-4",icon:"size-9"}},defaultVariants:{variant:"default",size:"default"}});function Rt({className:t,variant:e,size:n,asChild:r=!1,selected:i,...a}){const o=r?VR:"button";return v.jsx(o,{"data-slot":"button","data-selected":i,className:Be(CV({variant:e,size:n,className:t})),...a})}const TV=t=>t.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),n_=(...t)=>t.filter((e,n,r)=>!!e&&e.trim()!==""&&r.indexOf(e)===n).join(" ").trim();var EV={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 QV=w.forwardRef(({color:t="currentColor",size:e=24,strokeWidth:n=2,absoluteStrokeWidth:r,className:i="",children:a,iconNode:o,...c},u)=>w.createElement("svg",{ref:u,...EV,width:e,height:e,stroke:t,strokeWidth:r?Number(n)*24/Number(e):n,className:n_("lucide",i),...c},[...o.map(([f,h])=>w.createElement(f,h)),...Array.isArray(a)?a:[a]]));const Nt=(t,e)=>{const n=w.forwardRef(({className:r,...i},a)=>w.createElement(QV,{ref:a,iconNode:e,className:n_(`lucide-${TV(t)}`,r),...i}));return n.displayName=`${t}`,n};const AV=[["path",{d:"M12 5v14",key:"s699le"}],["path",{d:"m19 12-7 7-7-7",key:"1idqje"}]],RV=Nt("ArrowDown",AV);const _V=[["path",{d:"m12 19-7-7 7-7",key:"1l729n"}],["path",{d:"M19 12H5",key:"x3x0zl"}]],$V=Nt("ArrowLeft",_V);const PV=[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"m12 5 7 7-7 7",key:"xquz4c"}]],jV=Nt("ArrowRight",PV);const MV=[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]],rc=Nt("Check",MV);const NV=[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]],Jd=Nt("ChevronDown",NV);const DV=[["path",{d:"m18 15-6-6-6 6",key:"153udz"}]],zV=Nt("ChevronUp",DV);const LV=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]],r_=Nt("CircleCheck",LV);const ZV=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m15 9-6 6",key:"1uzhvr"}],["path",{d:"m9 9 6 6",key:"z0biqf"}]],VV=Nt("CircleX",ZV);const XV=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["polyline",{points:"12 6 12 12 16 14",key:"68esgv"}]],BV=Nt("Clock",XV);const IV=[["path",{d:"m18 16 4-4-4-4",key:"1inbqp"}],["path",{d:"m6 8-4 4 4 4",key:"15zrgr"}],["path",{d:"m14.5 4-5 16",key:"e7oirm"}]],qV=Nt("CodeXml",IV);const UV=[["rect",{width:"14",height:"14",x:"8",y:"8",rx:"2",ry:"2",key:"17jyea"}],["path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2",key:"zix9uf"}]],Kv=Nt("Copy",UV);const YV=[["path",{d:"M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z",key:"1rqfz7"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4",key:"tnqrlb"}],["path",{d:"M9 15h6",key:"cctwl0"}],["path",{d:"M12 18v-6",key:"17g6i2"}]],i_=Nt("FilePlus",YV);const FV=[["path",{d:"M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z",key:"1rqfz7"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4",key:"tnqrlb"}],["path",{d:"M10 9H8",key:"b1mrlr"}],["path",{d:"M16 13H8",key:"t4e002"}],["path",{d:"M16 17H8",key:"z1uh3a"}]],a_=Nt("FileText",FV);const WV=[["path",{d:"M15 22v-4a4.8 4.8 0 0 0-1-3.5c3 0 6-2 6-5.5.08-1.25-.27-2.48-1-3.5.28-1.15.28-2.35 0-3.5 0 0-1 0-3 1.5-2.64-.5-5.36-.5-8 0C6 2 5 2 5 2c-.3 1.15-.3 2.35 0 3.5A5.403 5.403 0 0 0 4 9c0 3.5 3 5.5 6 5.5-.39.49-.68 1.05-.85 1.65-.17.6-.22 1.23-.15 1.85v4",key:"tonef"}],["path",{d:"M9 18c-4.51 2-5-2-7-2",key:"9comsn"}]],GV=Nt("Github",WV);const HV=[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}],["path",{d:"M3 9h18",key:"1pudct"}],["path",{d:"M3 15h18",key:"5xshup"}],["path",{d:"M9 3v18",key:"fh3hqa"}],["path",{d:"M15 3v18",key:"14nvp0"}]],KV=Nt("Grid3x3",HV);const JV=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 16v-4",key:"1dtifu"}],["path",{d:"M12 8h.01",key:"e9boi3"}]],e8=Nt("Info",JV);const t8=[["path",{d:"M3 12h.01",key:"nlz23k"}],["path",{d:"M3 18h.01",key:"1tta3j"}],["path",{d:"M3 6h.01",key:"1rqtza"}],["path",{d:"M8 12h13",key:"1za7za"}],["path",{d:"M8 18h13",key:"1lx6n3"}],["path",{d:"M8 6h13",key:"ik3vkj"}]],n8=Nt("List",t8);const r8=[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]],s_=Nt("LoaderCircle",r8);const i8=[["path",{d:"M5 12h14",key:"1ays0h"}]],o_=Nt("Minus",i8);const a8=[["path",{d:"m15 9-6 6",key:"1uzhvr"}],["path",{d:"M2.586 16.726A2 2 0 0 1 2 15.312V8.688a2 2 0 0 1 .586-1.414l4.688-4.688A2 2 0 0 1 8.688 2h6.624a2 2 0 0 1 1.414.586l4.688 4.688A2 2 0 0 1 22 8.688v6.624a2 2 0 0 1-.586 1.414l-4.688 4.688a2 2 0 0 1-1.414.586H8.688a2 2 0 0 1-1.414-.586z",key:"2d38gg"}],["path",{d:"m9 9 6 6",key:"z0biqf"}]],s8=Nt("OctagonX",a8);const o8=[["path",{d:"m19 11-8-8-8.6 8.6a2 2 0 0 0 0 2.8l5.2 5.2c.8.8 2 .8 2.8 0L19 11Z",key:"irua1i"}],["path",{d:"m5 2 5 5",key:"1lls2c"}],["path",{d:"M2 13h15",key:"1hkzvu"}],["path",{d:"M22 20a2 2 0 1 1-4 0c0-1.6 1.7-2.4 2-4 .3 1.6 2 2.4 2 4Z",key:"xk76lq"}]],l8=Nt("PaintBucket",o8);const c8=[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]],ef=Nt("Plus",c8);const u8=[["path",{d:"M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8",key:"v9h5vc"}],["path",{d:"M21 3v5h-5",key:"1q7to0"}],["path",{d:"M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16",key:"3uifl3"}],["path",{d:"M8 16H3v5",key:"1cv678"}]],d8=Nt("RefreshCw",u8);const f8=[["path",{d:"M12.22 2h-.44a2 2 0 0 0-2 2v.18a2 2 0 0 1-1 1.73l-.43.25a2 2 0 0 1-2 0l-.15-.08a2 2 0 0 0-2.73.73l-.22.38a2 2 0 0 0 .73 2.73l.15.1a2 2 0 0 1 1 1.72v.51a2 2 0 0 1-1 1.74l-.15.09a2 2 0 0 0-.73 2.73l.22.38a2 2 0 0 0 2.73.73l.15-.08a2 2 0 0 1 2 0l.43.25a2 2 0 0 1 1 1.73V20a2 2 0 0 0 2 2h.44a2 2 0 0 0 2-2v-.18a2 2 0 0 1 1-1.73l.43-.25a2 2 0 0 1 2 0l.15.08a2 2 0 0 0 2.73-.73l.22-.39a2 2 0 0 0-.73-2.73l-.15-.08a2 2 0 0 1-1-1.74v-.5a2 2 0 0 1 1-1.74l.15-.09a2 2 0 0 0 .73-2.73l-.22-.38a2 2 0 0 0-2.73-.73l-.15.08a2 2 0 0 1-2 0l-.43-.25a2 2 0 0 1-1-1.73V4a2 2 0 0 0-2-2z",key:"1qme2f"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]],h8=Nt("Settings",f8);const p8=[["rect",{width:"14",height:"20",x:"5",y:"2",rx:"2",ry:"2",key:"1yt0o3"}],["path",{d:"M12 18h.01",key:"mhygvu"}]],m8=Nt("Smartphone",p8);const g8=[["path",{d:"M12 3H5a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2v-7",key:"1m0v6g"}],["path",{d:"M18.375 2.625a1 1 0 0 1 3 3l-9.013 9.014a2 2 0 0 1-.853.505l-2.873.84a.5.5 0 0 1-.62-.62l.84-2.873a2 2 0 0 1 .506-.852z",key:"ohrbg2"}]],O8=Nt("SquarePen",g8);const v8=[["path",{d:"M3 6h18",key:"d0wm0j"}],["path",{d:"M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6",key:"4alrt4"}],["path",{d:"M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2",key:"v07s0e"}],["line",{x1:"10",x2:"10",y1:"11",y2:"17",key:"1uufr5"}],["line",{x1:"14",x2:"14",y1:"11",y2:"17",key:"xtxkd"}]],l_=Nt("Trash2",v8);const y8=[["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"}]],b8=Nt("TriangleAlert",y8);const x8=[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]],c_=Nt("X",x8);var tf=_A();const u_=Nc(tf);function S8(t){if(typeof document>"u")return;let e=document.head||document.getElementsByTagName("head")[0],n=document.createElement("style");n.type="text/css",e.appendChild(n),n.styleSheet?n.styleSheet.cssText=t:n.appendChild(document.createTextNode(t))}const w8=t=>{switch(t){case"success":return T8;case"info":return Q8;case"warning":return E8;case"error":return A8;default:return null}},k8=Array(12).fill(0),C8=({visible:t,className:e})=>le.createElement("div",{className:["sonner-loading-wrapper",e].filter(Boolean).join(" "),"data-visible":t},le.createElement("div",{className:"sonner-spinner"},k8.map((n,r)=>le.createElement("div",{className:"sonner-loading-bar",key:`spinner-bar-${r}`})))),T8=le.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},le.createElement("path",{fillRule:"evenodd",d:"M10 18a8 8 0 100-16 8 8 0 000 16zm3.857-9.809a.75.75 0 00-1.214-.882l-3.483 4.79-1.88-1.88a.75.75 0 10-1.06 1.061l2.5 2.5a.75.75 0 001.137-.089l4-5.5z",clipRule:"evenodd"})),E8=le.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",height:"20",width:"20"},le.createElement("path",{fillRule:"evenodd",d:"M9.401 3.003c1.155-2 4.043-2 5.197 0l7.355 12.748c1.154 2-.29 4.5-2.599 4.5H4.645c-2.309 0-3.752-2.5-2.598-4.5L9.4 3.003zM12 8.25a.75.75 0 01.75.75v3.75a.75.75 0 01-1.5 0V9a.75.75 0 01.75-.75zm0 8.25a.75.75 0 100-1.5.75.75 0 000 1.5z",clipRule:"evenodd"})),Q8=le.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},le.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7-4a1 1 0 11-2 0 1 1 0 012 0zM9 9a.75.75 0 000 1.5h.253a.25.25 0 01.244.304l-.459 2.066A1.75 1.75 0 0010.747 15H11a.75.75 0 000-1.5h-.253a.25.25 0 01-.244-.304l.459-2.066A1.75 1.75 0 009.253 9H9z",clipRule:"evenodd"})),A8=le.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},le.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-8-5a.75.75 0 01.75.75v4.5a.75.75 0 01-1.5 0v-4.5A.75.75 0 0110 5zm0 10a1 1 0 100-2 1 1 0 000 2z",clipRule:"evenodd"})),R8=le.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"12",height:"12",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"},le.createElement("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),le.createElement("line",{x1:"6",y1:"6",x2:"18",y2:"18"})),_8=()=>{const[t,e]=le.useState(document.hidden);return le.useEffect(()=>{const n=()=>{e(document.hidden)};return document.addEventListener("visibilitychange",n),()=>window.removeEventListener("visibilitychange",n)},[]),t};let b0=1;class $8{constructor(){this.subscribe=e=>(this.subscribers.push(e),()=>{const n=this.subscribers.indexOf(e);this.subscribers.splice(n,1)}),this.publish=e=>{this.subscribers.forEach(n=>n(e))},this.addToast=e=>{this.publish(e),this.toasts=[...this.toasts,e]},this.create=e=>{var n;const{message:r,...i}=e,a=typeof e?.id=="number"||((n=e.id)==null?void 0:n.length)>0?e.id:b0++,o=this.toasts.find(u=>u.id===a),c=e.dismissible===void 0?!0:e.dismissible;return this.dismissedToasts.has(a)&&this.dismissedToasts.delete(a),o?this.toasts=this.toasts.map(u=>u.id===a?(this.publish({...u,...e,id:a,title:r}),{...u,...e,id:a,dismissible:c,title:r}):u):this.addToast({title:r,...i,dismissible:c,id:a}),a},this.dismiss=e=>(e?(this.dismissedToasts.add(e),requestAnimationFrame(()=>this.subscribers.forEach(n=>n({id:e,dismiss:!0})))):this.toasts.forEach(n=>{this.subscribers.forEach(r=>r({id:n.id,dismiss:!0}))}),e),this.message=(e,n)=>this.create({...n,message:e}),this.error=(e,n)=>this.create({...n,message:e,type:"error"}),this.success=(e,n)=>this.create({...n,type:"success",message:e}),this.info=(e,n)=>this.create({...n,type:"info",message:e}),this.warning=(e,n)=>this.create({...n,type:"warning",message:e}),this.loading=(e,n)=>this.create({...n,type:"loading",message:e}),this.promise=(e,n)=>{if(!n)return;let r;n.loading!==void 0&&(r=this.create({...n,promise:e,type:"loading",message:n.loading,description:typeof n.description!="function"?n.description:void 0}));const i=Promise.resolve(e instanceof Function?e():e);let a=r!==void 0,o;const c=i.then(async f=>{if(o=["resolve",f],le.isValidElement(f))a=!1,this.create({id:r,type:"default",message:f});else if(j8(f)&&!f.ok){a=!1;const m=typeof n.error=="function"?await n.error(`HTTP error! status: ${f.status}`):n.error,g=typeof n.description=="function"?await n.description(`HTTP error! status: ${f.status}`):n.description,x=typeof m=="object"&&!le.isValidElement(m)?m:{message:m};this.create({id:r,type:"error",description:g,...x})}else if(f instanceof Error){a=!1;const m=typeof n.error=="function"?await n.error(f):n.error,g=typeof n.description=="function"?await n.description(f):n.description,x=typeof m=="object"&&!le.isValidElement(m)?m:{message:m};this.create({id:r,type:"error",description:g,...x})}else if(n.success!==void 0){a=!1;const m=typeof n.success=="function"?await n.success(f):n.success,g=typeof n.description=="function"?await n.description(f):n.description,x=typeof m=="object"&&!le.isValidElement(m)?m:{message:m};this.create({id:r,type:"success",description:g,...x})}}).catch(async f=>{if(o=["reject",f],n.error!==void 0){a=!1;const h=typeof n.error=="function"?await n.error(f):n.error,m=typeof n.description=="function"?await n.description(f):n.description,y=typeof h=="object"&&!le.isValidElement(h)?h:{message:h};this.create({id:r,type:"error",description:m,...y})}}).finally(()=>{a&&(this.dismiss(r),r=void 0),n.finally==null||n.finally.call(n)}),u=()=>new Promise((f,h)=>c.then(()=>o[0]==="reject"?h(o[1]):f(o[1])).catch(h));return typeof r!="string"&&typeof r!="number"?{unwrap:u}:Object.assign(r,{unwrap:u})},this.custom=(e,n)=>{const r=n?.id||b0++;return this.create({jsx:e(r),id:r,...n}),r},this.getActiveToasts=()=>this.toasts.filter(e=>!this.dismissedToasts.has(e.id)),this.subscribers=[],this.toasts=[],this.dismissedToasts=new Set}}const Sr=new $8,P8=(t,e)=>{const n=e?.id||b0++;return Sr.addToast({title:t,...e,id:n}),n},j8=t=>t&&typeof t=="object"&&"ok"in t&&typeof t.ok=="boolean"&&"status"in t&&typeof t.status=="number",M8=P8,N8=()=>Sr.toasts,D8=()=>Sr.getActiveToasts(),bn=Object.assign(M8,{success:Sr.success,info:Sr.info,warning:Sr.warning,error:Sr.error,custom:Sr.custom,message:Sr.message,promise:Sr.promise,dismiss:Sr.dismiss,loading:Sr.loading},{getHistory:N8,getToasts:D8});S8("[data-sonner-toaster][dir=ltr],html[dir=ltr]{--toast-icon-margin-start:-3px;--toast-icon-margin-end:4px;--toast-svg-margin-start:-1px;--toast-svg-margin-end:0px;--toast-button-margin-start:auto;--toast-button-margin-end:0;--toast-close-button-start:0;--toast-close-button-end:unset;--toast-close-button-transform:translate(-35%, -35%)}[data-sonner-toaster][dir=rtl],html[dir=rtl]{--toast-icon-margin-start:4px;--toast-icon-margin-end:-3px;--toast-svg-margin-start:0px;--toast-svg-margin-end:-1px;--toast-button-margin-start:0;--toast-button-margin-end:auto;--toast-close-button-start:unset;--toast-close-button-end:0;--toast-close-button-transform:translate(35%, -35%)}[data-sonner-toaster]{position:fixed;width:var(--width);font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;--gray1:hsl(0, 0%, 99%);--gray2:hsl(0, 0%, 97.3%);--gray3:hsl(0, 0%, 95.1%);--gray4:hsl(0, 0%, 93%);--gray5:hsl(0, 0%, 90.9%);--gray6:hsl(0, 0%, 88.7%);--gray7:hsl(0, 0%, 85.8%);--gray8:hsl(0, 0%, 78%);--gray9:hsl(0, 0%, 56.1%);--gray10:hsl(0, 0%, 52.3%);--gray11:hsl(0, 0%, 43.5%);--gray12:hsl(0, 0%, 9%);--border-radius:8px;box-sizing:border-box;padding:0;margin:0;list-style:none;outline:0;z-index:999999999;transition:transform .4s ease}@media (hover:none) and (pointer:coarse){[data-sonner-toaster][data-lifted=true]{transform:none}}[data-sonner-toaster][data-x-position=right]{right:var(--offset-right)}[data-sonner-toaster][data-x-position=left]{left:var(--offset-left)}[data-sonner-toaster][data-x-position=center]{left:50%;transform:translateX(-50%)}[data-sonner-toaster][data-y-position=top]{top:var(--offset-top)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--offset-bottom)}[data-sonner-toast]{--y:translateY(100%);--lift-amount:calc(var(--lift) * var(--gap));z-index:var(--z-index);position:absolute;opacity:0;transform:var(--y);touch-action:none;transition:transform .4s,opacity .4s,height .4s,box-shadow .2s;box-sizing:border-box;outline:0;overflow-wrap:anywhere}[data-sonner-toast][data-styled=true]{padding:16px;background:var(--normal-bg);border:1px solid var(--normal-border);color:var(--normal-text);border-radius:var(--border-radius);box-shadow:0 4px 12px rgba(0,0,0,.1);width:var(--width);font-size:13px;display:flex;align-items:center;gap:6px}[data-sonner-toast]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-y-position=top]{top:0;--y:translateY(-100%);--lift:1;--lift-amount:calc(1 * var(--gap))}[data-sonner-toast][data-y-position=bottom]{bottom:0;--y:translateY(100%);--lift:-1;--lift-amount:calc(var(--lift) * var(--gap))}[data-sonner-toast][data-styled=true] [data-description]{font-weight:400;line-height:1.4;color:#3f3f3f}[data-rich-colors=true][data-sonner-toast][data-styled=true] [data-description]{color:inherit}[data-sonner-toaster][data-sonner-theme=dark] [data-description]{color:#e8e8e8}[data-sonner-toast][data-styled=true] [data-title]{font-weight:500;line-height:1.5;color:inherit}[data-sonner-toast][data-styled=true] [data-icon]{display:flex;height:16px;width:16px;position:relative;justify-content:flex-start;align-items:center;flex-shrink:0;margin-left:var(--toast-icon-margin-start);margin-right:var(--toast-icon-margin-end)}[data-sonner-toast][data-promise=true] [data-icon]>svg{opacity:0;transform:scale(.8);transform-origin:center;animation:sonner-fade-in .3s ease forwards}[data-sonner-toast][data-styled=true] [data-icon]>*{flex-shrink:0}[data-sonner-toast][data-styled=true] [data-icon] svg{margin-left:var(--toast-svg-margin-start);margin-right:var(--toast-svg-margin-end)}[data-sonner-toast][data-styled=true] [data-content]{display:flex;flex-direction:column;gap:2px}[data-sonner-toast][data-styled=true] [data-button]{border-radius:4px;padding-left:8px;padding-right:8px;height:24px;font-size:12px;color:var(--normal-bg);background:var(--normal-text);margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end);border:none;font-weight:500;cursor:pointer;outline:0;display:flex;align-items:center;flex-shrink:0;transition:opacity .4s,box-shadow .2s}[data-sonner-toast][data-styled=true] [data-button]:focus-visible{box-shadow:0 0 0 2px rgba(0,0,0,.4)}[data-sonner-toast][data-styled=true] [data-button]:first-of-type{margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end)}[data-sonner-toast][data-styled=true] [data-cancel]{color:var(--normal-text);background:rgba(0,0,0,.08)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-styled=true] [data-cancel]{background:rgba(255,255,255,.3)}[data-sonner-toast][data-styled=true] [data-close-button]{position:absolute;left:var(--toast-close-button-start);right:var(--toast-close-button-end);top:0;height:20px;width:20px;display:flex;justify-content:center;align-items:center;padding:0;color:var(--gray12);background:var(--normal-bg);border:1px solid var(--gray4);transform:var(--toast-close-button-transform);border-radius:50%;cursor:pointer;z-index:1;transition:opacity .1s,background .2s,border-color .2s}[data-sonner-toast][data-styled=true] [data-close-button]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-styled=true] [data-disabled=true]{cursor:not-allowed}[data-sonner-toast][data-styled=true]:hover [data-close-button]:hover{background:var(--gray2);border-color:var(--gray5)}[data-sonner-toast][data-swiping=true]::before{content:'';position:absolute;left:-100%;right:-100%;height:100%;z-index:-1}[data-sonner-toast][data-y-position=top][data-swiping=true]::before{bottom:50%;transform:scaleY(3) translateY(50%)}[data-sonner-toast][data-y-position=bottom][data-swiping=true]::before{top:50%;transform:scaleY(3) translateY(-50%)}[data-sonner-toast][data-swiping=false][data-removed=true]::before{content:'';position:absolute;inset:0;transform:scaleY(2)}[data-sonner-toast][data-expanded=true]::after{content:'';position:absolute;left:0;height:calc(var(--gap) + 1px);bottom:100%;width:100%}[data-sonner-toast][data-mounted=true]{--y:translateY(0);opacity:1}[data-sonner-toast][data-expanded=false][data-front=false]{--scale:var(--toasts-before) * 0.05 + 1;--y:translateY(calc(var(--lift-amount) * var(--toasts-before))) scale(calc(-1 * var(--scale)));height:var(--front-toast-height)}[data-sonner-toast]>*{transition:opacity .4s}[data-sonner-toast][data-x-position=right]{right:0}[data-sonner-toast][data-x-position=left]{left:0}[data-sonner-toast][data-expanded=false][data-front=false][data-styled=true]>*{opacity:0}[data-sonner-toast][data-visible=false]{opacity:0;pointer-events:none}[data-sonner-toast][data-mounted=true][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset)));height:var(--initial-height)}[data-sonner-toast][data-removed=true][data-front=true][data-swipe-out=false]{--y:translateY(calc(var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset) + var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=false]{--y:translateY(40%);opacity:0;transition:transform .5s,opacity .2s}[data-sonner-toast][data-removed=true][data-front=false]::before{height:calc(var(--initial-height) + 20%)}[data-sonner-toast][data-swiping=true]{transform:var(--y) translateY(var(--swipe-amount-y,0)) translateX(var(--swipe-amount-x,0));transition:none}[data-sonner-toast][data-swiped=true]{user-select:none}[data-sonner-toast][data-swipe-out=true][data-y-position=bottom],[data-sonner-toast][data-swipe-out=true][data-y-position=top]{animation-duration:.2s;animation-timing-function:ease-out;animation-fill-mode:forwards}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=left]{animation-name:swipe-out-left}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=right]{animation-name:swipe-out-right}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=up]{animation-name:swipe-out-up}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=down]{animation-name:swipe-out-down}@keyframes swipe-out-left{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) - 100%));opacity:0}}@keyframes swipe-out-right{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) + 100%));opacity:0}}@keyframes swipe-out-up{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) - 100%));opacity:0}}@keyframes swipe-out-down{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) + 100%));opacity:0}}@media (max-width:600px){[data-sonner-toaster]{position:fixed;right:var(--mobile-offset-right);left:var(--mobile-offset-left);width:100%}[data-sonner-toaster][dir=rtl]{left:calc(var(--mobile-offset-left) * -1)}[data-sonner-toaster] [data-sonner-toast]{left:0;right:0;width:calc(100% - var(--mobile-offset-left) * 2)}[data-sonner-toaster][data-x-position=left]{left:var(--mobile-offset-left)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--mobile-offset-bottom)}[data-sonner-toaster][data-y-position=top]{top:var(--mobile-offset-top)}[data-sonner-toaster][data-x-position=center]{left:var(--mobile-offset-left);right:var(--mobile-offset-right);transform:none}}[data-sonner-toaster][data-sonner-theme=light]{--normal-bg:#fff;--normal-border:var(--gray4);--normal-text:var(--gray12);--success-bg:hsl(143, 85%, 96%);--success-border:hsl(145, 92%, 87%);--success-text:hsl(140, 100%, 27%);--info-bg:hsl(208, 100%, 97%);--info-border:hsl(221, 91%, 93%);--info-text:hsl(210, 92%, 45%);--warning-bg:hsl(49, 100%, 97%);--warning-border:hsl(49, 91%, 84%);--warning-text:hsl(31, 92%, 45%);--error-bg:hsl(359, 100%, 97%);--error-border:hsl(359, 100%, 94%);--error-text:hsl(360, 100%, 45%)}[data-sonner-toaster][data-sonner-theme=light] [data-sonner-toast][data-invert=true]{--normal-bg:#000;--normal-border:hsl(0, 0%, 20%);--normal-text:var(--gray1)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-invert=true]{--normal-bg:#fff;--normal-border:var(--gray3);--normal-text:var(--gray12)}[data-sonner-toaster][data-sonner-theme=dark]{--normal-bg:#000;--normal-bg-hover:hsl(0, 0%, 12%);--normal-border:hsl(0, 0%, 20%);--normal-border-hover:hsl(0, 0%, 25%);--normal-text:var(--gray1);--success-bg:hsl(150, 100%, 6%);--success-border:hsl(147, 100%, 12%);--success-text:hsl(150, 86%, 65%);--info-bg:hsl(215, 100%, 6%);--info-border:hsl(223, 43%, 17%);--info-text:hsl(216, 87%, 65%);--warning-bg:hsl(64, 100%, 6%);--warning-border:hsl(60, 100%, 9%);--warning-text:hsl(46, 87%, 65%);--error-bg:hsl(358, 76%, 10%);--error-border:hsl(357, 89%, 16%);--error-text:hsl(358, 100%, 81%)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]{background:var(--normal-bg);border-color:var(--normal-border);color:var(--normal-text)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]:hover{background:var(--normal-bg-hover);border-color:var(--normal-border-hover)}[data-rich-colors=true][data-sonner-toast][data-type=success]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=success] [data-close-button]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=info]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=info] [data-close-button]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning] [data-close-button]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=error]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}[data-rich-colors=true][data-sonner-toast][data-type=error] [data-close-button]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}.sonner-loading-wrapper{--size:16px;height:var(--size);width:var(--size);position:absolute;inset:0;z-index:10}.sonner-loading-wrapper[data-visible=false]{transform-origin:center;animation:sonner-fade-out .2s ease forwards}.sonner-spinner{position:relative;top:50%;left:50%;height:var(--size);width:var(--size)}.sonner-loading-bar{animation:sonner-spin 1.2s linear infinite;background:var(--gray11);border-radius:6px;height:8%;left:-10%;position:absolute;top:-3.9%;width:24%}.sonner-loading-bar:first-child{animation-delay:-1.2s;transform:rotate(.0001deg) translate(146%)}.sonner-loading-bar:nth-child(2){animation-delay:-1.1s;transform:rotate(30deg) translate(146%)}.sonner-loading-bar:nth-child(3){animation-delay:-1s;transform:rotate(60deg) translate(146%)}.sonner-loading-bar:nth-child(4){animation-delay:-.9s;transform:rotate(90deg) translate(146%)}.sonner-loading-bar:nth-child(5){animation-delay:-.8s;transform:rotate(120deg) translate(146%)}.sonner-loading-bar:nth-child(6){animation-delay:-.7s;transform:rotate(150deg) translate(146%)}.sonner-loading-bar:nth-child(7){animation-delay:-.6s;transform:rotate(180deg) translate(146%)}.sonner-loading-bar:nth-child(8){animation-delay:-.5s;transform:rotate(210deg) translate(146%)}.sonner-loading-bar:nth-child(9){animation-delay:-.4s;transform:rotate(240deg) translate(146%)}.sonner-loading-bar:nth-child(10){animation-delay:-.3s;transform:rotate(270deg) translate(146%)}.sonner-loading-bar:nth-child(11){animation-delay:-.2s;transform:rotate(300deg) translate(146%)}.sonner-loading-bar:nth-child(12){animation-delay:-.1s;transform:rotate(330deg) translate(146%)}@keyframes sonner-fade-in{0%{opacity:0;transform:scale(.8)}100%{opacity:1;transform:scale(1)}}@keyframes sonner-fade-out{0%{opacity:1;transform:scale(1)}100%{opacity:0;transform:scale(.8)}}@keyframes sonner-spin{0%{opacity:1}100%{opacity:.15}}@media (prefers-reduced-motion){.sonner-loading-bar,[data-sonner-toast],[data-sonner-toast]>*{transition:none!important;animation:none!important}}.sonner-loader{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);transform-origin:center;transition:opacity .2s,transform .2s}.sonner-loader[data-visible=false]{opacity:0;transform:scale(.8) translate(-50%,-50%)}");function _h(t){return t.label!==void 0}const z8=3,L8="24px",Z8="16px",ZT=4e3,V8=356,X8=14,B8=45,I8=200;function Yi(...t){return t.filter(Boolean).join(" ")}function q8(t){const[e,n]=t.split("-"),r=[];return e&&r.push(e),n&&r.push(n),r}const U8=t=>{var e,n,r,i,a,o,c,u,f;const{invert:h,toast:m,unstyled:g,interacting:y,setHeights:x,visibleToasts:S,heights:k,index:T,toasts:C,expanded:E,removeToast:R,defaultRichColors:$,closeButton:P,style:_,cancelButtonStyle:M,actionButtonStyle:V,className:F="",descriptionClassName:W="",duration:I,position:ne,gap:ee,expandByDefault:pe,classNames:D,icons:G,closeButtonAriaLabel:B="Close toast"}=t,[ye,X]=le.useState(null),[A,N]=le.useState(null),[L,q]=le.useState(!1),[se,he]=le.useState(!1),[H,ge]=le.useState(!1),[xe,ke]=le.useState(!1),[Ce,Re]=le.useState(!1),[We,Pe]=le.useState(0),[ht,Ke]=le.useState(0),tt=le.useRef(m.duration||I||ZT),bt=le.useRef(null),Ue=le.useRef(null),Ge=T===0,z=T+1<=S,Y=m.type,oe=m.dismissible!==!1,te=m.className||"",fe=m.descriptionClassName||"",Oe=le.useMemo(()=>k.findIndex(Je=>Je.toastId===m.id)||0,[k,m.id]),Te=le.useMemo(()=>{var Je;return(Je=m.closeButton)!=null?Je:P},[m.closeButton,P]),Ye=le.useMemo(()=>m.duration||I||ZT,[m.duration,I]),ot=le.useRef(0),kt=le.useRef(0),Dn=le.useRef(0),Kt=le.useRef(null),[er,Wt]=ne.split("-"),kn=le.useMemo(()=>k.reduce((Je,Gt,_n)=>_n>=Oe?Je:Je+Gt.height,0),[k,Oe]),rn=_8(),Zi=m.invert||h,gi=Y==="loading";kt.current=le.useMemo(()=>Oe*ee+kn,[Oe,kn]),le.useEffect(()=>{tt.current=Ye},[Ye]),le.useEffect(()=>{q(!0)},[]),le.useEffect(()=>{const Je=Ue.current;if(Je){const Gt=Je.getBoundingClientRect().height;return Ke(Gt),x(_n=>[{toastId:m.id,height:Gt,position:m.position},..._n]),()=>x(_n=>_n.filter(Un=>Un.toastId!==m.id))}},[x,m.id]),le.useLayoutEffect(()=>{if(!L)return;const Je=Ue.current,Gt=Je.style.height;Je.style.height="auto";const _n=Je.getBoundingClientRect().height;Je.style.height=Gt,Ke(_n),x(Un=>Un.find(Jt=>Jt.toastId===m.id)?Un.map(Jt=>Jt.toastId===m.id?{...Jt,height:_n}:Jt):[{toastId:m.id,height:_n,position:m.position},...Un])},[L,m.title,m.description,x,m.id,m.jsx,m.action,m.cancel]);const tr=le.useCallback(()=>{he(!0),Pe(kt.current),x(Je=>Je.filter(Gt=>Gt.toastId!==m.id)),setTimeout(()=>{R(m)},I8)},[m,R,x,kt]);le.useEffect(()=>{if(m.promise&&Y==="loading"||m.duration===1/0||m.type==="loading")return;let Je;return E||y||rn?(()=>{if(Dn.current<ot.current){const Un=new Date().getTime()-ot.current;tt.current=tt.current-Un}Dn.current=new Date().getTime()})():tt.current!==1/0&&(ot.current=new Date().getTime(),Je=setTimeout(()=>{m.onAutoClose==null||m.onAutoClose.call(m,m),tr()},tt.current)),()=>clearTimeout(Je)},[E,y,m,Y,rn,tr]),le.useEffect(()=>{m.delete&&(tr(),m.onDismiss==null||m.onDismiss.call(m,m))},[tr,m.delete]);function tl(){var Je;if(G?.loading){var Gt;return le.createElement("div",{className:Yi(D?.loader,m==null||(Gt=m.classNames)==null?void 0:Gt.loader,"sonner-loader"),"data-visible":Y==="loading"},G.loading)}return le.createElement(C8,{className:Yi(D?.loader,m==null||(Je=m.classNames)==null?void 0:Je.loader),visible:Y==="loading"})}const nl=m.icon||G?.[Y]||w8(Y);var to,Vi;return le.createElement("li",{tabIndex:0,ref:Ue,className:Yi(F,te,D?.toast,m==null||(e=m.classNames)==null?void 0:e.toast,D?.default,D?.[Y],m==null||(n=m.classNames)==null?void 0:n[Y]),"data-sonner-toast":"","data-rich-colors":(to=m.richColors)!=null?to:$,"data-styled":!(m.jsx||m.unstyled||g),"data-mounted":L,"data-promise":!!m.promise,"data-swiped":Ce,"data-removed":se,"data-visible":z,"data-y-position":er,"data-x-position":Wt,"data-index":T,"data-front":Ge,"data-swiping":H,"data-dismissible":oe,"data-type":Y,"data-invert":Zi,"data-swipe-out":xe,"data-swipe-direction":A,"data-expanded":!!(E||pe&&L),"data-testid":m.testId,style:{"--index":T,"--toasts-before":T,"--z-index":C.length-T,"--offset":`${se?We:kt.current}px`,"--initial-height":pe?"auto":`${ht}px`,..._,...m.style},onDragEnd:()=>{ge(!1),X(null),Kt.current=null},onPointerDown:Je=>{Je.button!==2&&(gi||!oe||(bt.current=new Date,Pe(kt.current),Je.target.setPointerCapture(Je.pointerId),Je.target.tagName!=="BUTTON"&&(ge(!0),Kt.current={x:Je.clientX,y:Je.clientY})))},onPointerUp:()=>{var Je,Gt,_n;if(xe||!oe)return;Kt.current=null;const Un=Number(((Je=Ue.current)==null?void 0:Je.style.getPropertyValue("--swipe-amount-x").replace("px",""))||0),es=Number(((Gt=Ue.current)==null?void 0:Gt.style.getPropertyValue("--swipe-amount-y").replace("px",""))||0),Jt=new Date().getTime()-((_n=bt.current)==null?void 0:_n.getTime()),dr=ye==="x"?Un:es,no=Math.abs(dr)/Jt;if(Math.abs(dr)>=B8||no>.11){Pe(kt.current),m.onDismiss==null||m.onDismiss.call(m,m),N(ye==="x"?Un>0?"right":"left":es>0?"down":"up"),tr(),ke(!0);return}else{var fr,hr;(fr=Ue.current)==null||fr.style.setProperty("--swipe-amount-x","0px"),(hr=Ue.current)==null||hr.style.setProperty("--swipe-amount-y","0px")}Re(!1),ge(!1),X(null)},onPointerMove:Je=>{var Gt,_n,Un;if(!Kt.current||!oe||((Gt=window.getSelection())==null?void 0:Gt.toString().length)>0)return;const Jt=Je.clientY-Kt.current.y,dr=Je.clientX-Kt.current.x;var no;const fr=(no=t.swipeDirections)!=null?no:q8(ne);!ye&&(Math.abs(dr)>1||Math.abs(Jt)>1)&&X(Math.abs(dr)>Math.abs(Jt)?"x":"y");let hr={x:0,y:0};const rl=Oi=>1/(1.5+Math.abs(Oi)/20);if(ye==="y"){if(fr.includes("top")||fr.includes("bottom"))if(fr.includes("top")&&Jt<0||fr.includes("bottom")&&Jt>0)hr.y=Jt;else{const Oi=Jt*rl(Jt);hr.y=Math.abs(Oi)<Math.abs(Jt)?Oi:Jt}}else if(ye==="x"&&(fr.includes("left")||fr.includes("right")))if(fr.includes("left")&&dr<0||fr.includes("right")&&dr>0)hr.x=dr;else{const Oi=dr*rl(dr);hr.x=Math.abs(Oi)<Math.abs(dr)?Oi:dr}(Math.abs(hr.x)>0||Math.abs(hr.y)>0)&&Re(!0),(_n=Ue.current)==null||_n.style.setProperty("--swipe-amount-x",`${hr.x}px`),(Un=Ue.current)==null||Un.style.setProperty("--swipe-amount-y",`${hr.y}px`)}},Te&&!m.jsx&&Y!=="loading"?le.createElement("button",{"aria-label":B,"data-disabled":gi,"data-close-button":!0,onClick:gi||!oe?()=>{}:()=>{tr(),m.onDismiss==null||m.onDismiss.call(m,m)},className:Yi(D?.closeButton,m==null||(r=m.classNames)==null?void 0:r.closeButton)},(Vi=G?.close)!=null?Vi:R8):null,(Y||m.icon||m.promise)&&m.icon!==null&&(G?.[Y]!==null||m.icon)?le.createElement("div",{"data-icon":"",className:Yi(D?.icon,m==null||(i=m.classNames)==null?void 0:i.icon)},m.promise||m.type==="loading"&&!m.icon?m.icon||tl():null,m.type!=="loading"?nl:null):null,le.createElement("div",{"data-content":"",className:Yi(D?.content,m==null||(a=m.classNames)==null?void 0:a.content)},le.createElement("div",{"data-title":"",className:Yi(D?.title,m==null||(o=m.classNames)==null?void 0:o.title)},m.jsx?m.jsx:typeof m.title=="function"?m.title():m.title),m.description?le.createElement("div",{"data-description":"",className:Yi(W,fe,D?.description,m==null||(c=m.classNames)==null?void 0:c.description)},typeof m.description=="function"?m.description():m.description):null),le.isValidElement(m.cancel)?m.cancel:m.cancel&&_h(m.cancel)?le.createElement("button",{"data-button":!0,"data-cancel":!0,style:m.cancelButtonStyle||M,onClick:Je=>{_h(m.cancel)&&oe&&(m.cancel.onClick==null||m.cancel.onClick.call(m.cancel,Je),tr())},className:Yi(D?.cancelButton,m==null||(u=m.classNames)==null?void 0:u.cancelButton)},m.cancel.label):null,le.isValidElement(m.action)?m.action:m.action&&_h(m.action)?le.createElement("button",{"data-button":!0,"data-action":!0,style:m.actionButtonStyle||V,onClick:Je=>{_h(m.action)&&(m.action.onClick==null||m.action.onClick.call(m.action,Je),!Je.defaultPrevented&&tr())},className:Yi(D?.actionButton,m==null||(f=m.classNames)==null?void 0:f.actionButton)},m.action.label):null)};function VT(){if(typeof window>"u"||typeof document>"u")return"ltr";const t=document.documentElement.getAttribute("dir");return t==="auto"||!t?window.getComputedStyle(document.documentElement).direction:t}function Y8(t,e){const n={};return[t,e].forEach((r,i)=>{const a=i===1,o=a?"--mobile-offset":"--offset",c=a?Z8:L8;function u(f){["top","right","bottom","left"].forEach(h=>{n[`${o}-${h}`]=typeof f=="number"?`${f}px`:f})}typeof r=="number"||typeof r=="string"?u(r):typeof r=="object"?["top","right","bottom","left"].forEach(f=>{r[f]===void 0?n[`${o}-${f}`]=c:n[`${o}-${f}`]=typeof r[f]=="number"?`${r[f]}px`:r[f]}):u(c)}),n}const F8=le.forwardRef(function(e,n){const{id:r,invert:i,position:a="bottom-right",hotkey:o=["altKey","KeyT"],expand:c,closeButton:u,className:f,offset:h,mobileOffset:m,theme:g="light",richColors:y,duration:x,style:S,visibleToasts:k=z8,toastOptions:T,dir:C=VT(),gap:E=X8,icons:R,containerAriaLabel:$="Notifications"}=e,[P,_]=le.useState([]),M=le.useMemo(()=>r?P.filter(L=>L.toasterId===r):P.filter(L=>!L.toasterId),[P,r]),V=le.useMemo(()=>Array.from(new Set([a].concat(M.filter(L=>L.position).map(L=>L.position)))),[M,a]),[F,W]=le.useState([]),[I,ne]=le.useState(!1),[ee,pe]=le.useState(!1),[D,G]=le.useState(g!=="system"?g:typeof window<"u"&&window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"),B=le.useRef(null),ye=o.join("+").replace(/Key/g,"").replace(/Digit/g,""),X=le.useRef(null),A=le.useRef(!1),N=le.useCallback(L=>{_(q=>{var se;return(se=q.find(he=>he.id===L.id))!=null&&se.delete||Sr.dismiss(L.id),q.filter(({id:he})=>he!==L.id)})},[]);return le.useEffect(()=>Sr.subscribe(L=>{if(L.dismiss){requestAnimationFrame(()=>{_(q=>q.map(se=>se.id===L.id?{...se,delete:!0}:se))});return}setTimeout(()=>{u_.flushSync(()=>{_(q=>{const se=q.findIndex(he=>he.id===L.id);return se!==-1?[...q.slice(0,se),{...q[se],...L},...q.slice(se+1)]:[L,...q]})})})}),[P]),le.useEffect(()=>{if(g!=="system"){G(g);return}if(g==="system"&&(window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?G("dark"):G("light")),typeof window>"u")return;const L=window.matchMedia("(prefers-color-scheme: dark)");try{L.addEventListener("change",({matches:q})=>{G(q?"dark":"light")})}catch{L.addListener(({matches:se})=>{try{G(se?"dark":"light")}catch(he){console.error(he)}})}},[g]),le.useEffect(()=>{P.length<=1&&ne(!1)},[P]),le.useEffect(()=>{const L=q=>{var se;if(o.every(ge=>q[ge]||q.code===ge)){var H;ne(!0),(H=B.current)==null||H.focus()}q.code==="Escape"&&(document.activeElement===B.current||(se=B.current)!=null&&se.contains(document.activeElement))&&ne(!1)};return document.addEventListener("keydown",L),()=>document.removeEventListener("keydown",L)},[o]),le.useEffect(()=>{if(B.current)return()=>{X.current&&(X.current.focus({preventScroll:!0}),X.current=null,A.current=!1)}},[B.current]),le.createElement("section",{ref:n,"aria-label":`${$} ${ye}`,tabIndex:-1,"aria-live":"polite","aria-relevant":"additions text","aria-atomic":"false",suppressHydrationWarning:!0},V.map((L,q)=>{var se;const[he,H]=L.split("-");return M.length?le.createElement("ol",{key:L,dir:C==="auto"?VT():C,tabIndex:-1,ref:B,className:f,"data-sonner-toaster":!0,"data-sonner-theme":D,"data-y-position":he,"data-x-position":H,style:{"--front-toast-height":`${((se=F[0])==null?void 0:se.height)||0}px`,"--width":`${V8}px`,"--gap":`${E}px`,...S,...Y8(h,m)},onBlur:ge=>{A.current&&!ge.currentTarget.contains(ge.relatedTarget)&&(A.current=!1,X.current&&(X.current.focus({preventScroll:!0}),X.current=null))},onFocus:ge=>{ge.target instanceof HTMLElement&&ge.target.dataset.dismissible==="false"||A.current||(A.current=!0,X.current=ge.relatedTarget)},onMouseEnter:()=>ne(!0),onMouseMove:()=>ne(!0),onMouseLeave:()=>{ee||ne(!1)},onDragEnd:()=>ne(!1),onPointerDown:ge=>{ge.target instanceof HTMLElement&&ge.target.dataset.dismissible==="false"||pe(!0)},onPointerUp:()=>pe(!1)},M.filter(ge=>!ge.position&&q===0||ge.position===L).map((ge,xe)=>{var ke,Ce;return le.createElement(U8,{key:ge.id,icons:R,index:xe,toast:ge,defaultRichColors:y,duration:(ke=T?.duration)!=null?ke:x,className:T?.className,descriptionClassName:T?.descriptionClassName,invert:i,visibleToasts:k,closeButton:(Ce=T?.closeButton)!=null?Ce:u,interacting:ee,position:L,style:T?.style,unstyled:T?.unstyled,classNames:T?.classNames,cancelButtonStyle:T?.cancelButtonStyle,actionButtonStyle:T?.actionButtonStyle,closeButtonAriaLabel:T?.closeButtonAriaLabel,removeToast:N,toasts:M.filter(Re=>Re.position==ge.position),heights:F.filter(Re=>Re.position==ge.position),setHeights:W,expandByDefault:c,gap:E,expanded:I,swipeDirections:e.swipeDirections})})):null}))});function W8(){const[t,e]=w.useState("system"),[n,r]=w.useState(!1);return w.useEffect(()=>{r(!0);const i=()=>{if(typeof window>"u")return"system";const u=document.documentElement,f=u.classList.contains("dark"),h=u.classList.contains("light");return f?"dark":h?"light":window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"};e(i());const a=new MutationObserver(()=>{e(i())});a.observe(document.documentElement,{attributes:!0,attributeFilter:["class"]});const o=window.matchMedia("(prefers-color-scheme: dark)"),c=()=>e(i());return o.addEventListener("change",c),()=>{a.disconnect(),o.removeEventListener("change",c)}},[]),{theme:t,mounted:n}}function G8({...t}){const{theme:e,mounted:n}=W8(),r=n?e:"system";return v.jsx(F8,{theme:r,className:"toaster group",icons:{success:v.jsx(r_,{className:"size-4"}),info:v.jsx(e8,{className:"size-4"}),warning:v.jsx(b8,{className:"size-4"}),error:v.jsx(s8,{className:"size-4"}),loading:v.jsx(s_,{className:"size-4 animate-spin"})},style:{"--normal-bg":"var(--popover)","--normal-text":"var(--popover-foreground)","--normal-border":"var(--border)","--border-radius":"var(--radius)"},...t})}const H8=({...t})=>typeof window>"u"?null:v.jsx(G8,{...t});function d_({iconKey:t,pascalName:e,svgContent:n,colorVariableKeys:r=[]}){const{data:i}=Kd(),{previewColor:a,colorVariableValues:o}=jm(),[c,u]=w.useState(""),[f,h]=w.useState(null),m=w.useMemo(()=>{if(!i)return[];const _=[];return i&&!i.svg.inLock&&_.push("svg"),i.extraTargets.some(M=>M.targetId==="react")&&_.push("react"),i.extraTargets.some(M=>M.targetId==="react-native")&&_.push("react-native"),_.length>0&&!c&&_[0]&&u(_[0]),_},[i,c]);w.useEffect(()=>{m.length>0&&!c&&m[0]&&u(m[0])},[m,c]);const g=()=>{if(!i)return"";const _=i.extraTargets.find(M=>M.targetId==="react");return _?_.outputPath.replace("{name}",t):""},y=()=>{if(!i)return"";const _=i.extraTargets.find(M=>M.targetId==="react-native");return _?_.outputPath.replace("{name}",t):""},S=r.filter(_=>_.startsWith("var(")&&_.endsWith(")")).map(_=>{const M=_.match(/var\((--[^)]+)\)/);return M?M[1]:null}).filter(Boolean),k=()=>{const _=`import { ${e} } from "${g()}";`,M=[];if(M.push(`color: "${a}"`),S.forEach(F=>{const W=o[F]||"#6B7280";M.push(`"${F}": "${W}"`)}),M.length===0)return`${_}
|
|
18
|
-
|
|
19
|
-
<div className="text-2xl">
|
|
20
|
-
<${e} />
|
|
21
|
-
</div>`;const V=`{ ${M.join(", ")} }`;return`${_}
|
|
22
|
-
|
|
23
|
-
<div style={${V}} className="text-2xl">
|
|
24
|
-
<${e} />
|
|
25
|
-
</div>`},T=()=>{const _=[];return _.push(`color: "${a}"`),S.forEach(M=>{const V=o[M]||"#6B7280";_.push(`${M}: "${V}"`)}),`<div style="${_.join("; ")}">
|
|
26
|
-
${n}
|
|
27
|
-
</div>`},C=()=>{const _=`import { ${e} } from "${y()}";`,M=[];return M.push(`color="${a}"`),M.push("size={24}"),`${_}
|
|
28
|
-
|
|
29
|
-
<${e} ${M.join(" ")} />`},E=T(),R=k(),$=C(),P=async(_,M)=>{try{await navigator.clipboard.writeText(_),h(M),bn.success("Code copied to clipboard"),setTimeout(()=>h(null),2e3)}catch{bn.error("Failed to copy code")}};return m.length===0?null:v.jsxs("div",{className:"rounded-xl border bg-card shadow-sm overflow-hidden w-full",children:[v.jsx("div",{className:"flex border-b",children:m.map(_=>v.jsx("button",{onClick:()=>u(_),className:`px-6 py-3 text-sm font-medium transition-all ${c===_?"border-b-2 border-primary text-primary bg-background":"text-muted-foreground hover:text-foreground hover:bg-muted/50"}`,children:_==="svg"?"Pure SVG":_==="react"?"React":"React Native"},_))}),v.jsxs("div",{className:"p-6",children:[c==="svg"&&v.jsxs("div",{className:"relative",children:[v.jsx("pre",{className:"rounded-lg bg-background border p-4 text-sm overflow-x-auto pr-12",children:v.jsx("code",{className:"text-foreground",children:E})}),v.jsx(Rt,{variant:"ghost",size:"sm",className:"absolute top-2 right-2 h-8 w-8 p-0",onClick:()=>P(E,"svg"),children:f==="svg"?v.jsx(rc,{className:"size-4 text-green-500"}):v.jsx(Kv,{className:"size-4"})})]}),c==="react"&&v.jsxs("div",{className:"relative",children:[v.jsx("pre",{className:"rounded-lg bg-background border p-4 text-sm overflow-x-auto pr-12",children:v.jsx("code",{className:"text-foreground",children:R})}),v.jsx(Rt,{variant:"ghost",size:"sm",className:"absolute top-2 right-2 h-8 w-8 p-0",onClick:()=>P(R,"react"),children:f==="react"?v.jsx(rc,{className:"size-4 text-green-500"}):v.jsx(Kv,{className:"size-4"})})]}),c==="react-native"&&v.jsxs("div",{className:"relative",children:[v.jsx("pre",{className:"rounded-lg bg-background border p-4 text-sm overflow-x-auto pr-12",children:v.jsx("code",{className:"text-foreground",children:$})}),v.jsx(Rt,{variant:"ghost",size:"sm",className:"absolute top-2 right-2 h-8 w-8 p-0",onClick:()=>P($,"react-native"),children:f==="react-native"?v.jsx(rc,{className:"size-4 text-green-500"}):v.jsx(Kv,{className:"size-4"})})]})]})]})}function Ci({className:t,type:e,...n}){return v.jsx("input",{type:e,"data-slot":"input",className:Be("file:text-foreground placeholder:text-muted-foreground selection:bg-primary selection:text-primary-foreground dark:bg-input/30 border-input h-9 w-full min-w-0 rounded-md border bg-transparent px-3 py-1 text-base shadow-xs transition-[color,box-shadow] outline-none file:inline-flex file:h-7 file:border-0 file:bg-transparent file:text-sm file:font-medium disabled:pointer-events-none disabled:cursor-not-allowed disabled:opacity-50 md:text-sm","focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px]","aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive",t),...n})}function yd(t,[e,n]){return Math.min(n,Math.max(e,t))}function He(t,e,{checkForDefaultPrevented:n=!0}={}){return function(i){if(t?.(i),n===!1||!i.defaultPrevented)return e?.(i)}}function K8(t,e){const n=w.createContext(e),r=a=>{const{children:o,...c}=a,u=w.useMemo(()=>c,Object.values(c));return v.jsx(n.Provider,{value:u,children:o})};r.displayName=t+"Provider";function i(a){const o=w.useContext(n);if(o)return o;if(e!==void 0)return e;throw new Error(`\`${a}\` must be used within \`${t}\``)}return[r,i]}function pa(t,e=[]){let n=[];function r(a,o){const c=w.createContext(o),u=n.length;n=[...n,o];const f=m=>{const{scope:g,children:y,...x}=m,S=g?.[t]?.[u]||c,k=w.useMemo(()=>x,Object.values(x));return v.jsx(S.Provider,{value:k,children:y})};f.displayName=a+"Provider";function h(m,g){const y=g?.[t]?.[u]||c,x=w.useContext(y);if(x)return x;if(o!==void 0)return o;throw new Error(`\`${m}\` must be used within \`${a}\``)}return[f,h]}const i=()=>{const a=n.map(o=>w.createContext(o));return function(c){const u=c?.[t]||a;return w.useMemo(()=>({[`__scope${t}`]:{...c,[t]:u}}),[c,u])}};return i.scopeName=t,[r,J8(i,...e)]}function J8(...t){const e=t[0];if(t.length===1)return e;const n=()=>{const r=t.map(i=>({useScope:i(),scopeName:i.scopeName}));return function(a){const o=r.reduce((c,{useScope:u,scopeName:f})=>{const m=u(a)[`__scope${f}`];return{...c,...m}},{});return w.useMemo(()=>({[`__scope${e.scopeName}`]:o}),[o])}};return n.scopeName=e.scopeName,n}function pc(t){const e=eX(t),n=w.forwardRef((r,i)=>{const{children:a,...o}=r,c=w.Children.toArray(a),u=c.find(nX);if(u){const f=u.props.children,h=c.map(m=>m===u?w.Children.count(f)>1?w.Children.only(null):w.isValidElement(f)?f.props.children:null:m);return v.jsx(e,{...o,ref:i,children:w.isValidElement(f)?w.cloneElement(f,void 0,h):null})}return v.jsx(e,{...o,ref:i,children:a})});return n.displayName=`${t}.Slot`,n}function eX(t){const e=w.forwardRef((n,r)=>{const{children:i,...a}=n;if(w.isValidElement(i)){const o=iX(i),c=rX(a,i.props);return i.type!==w.Fragment&&(c.ref=r?vx(r,o):o),w.cloneElement(i,c)}return w.Children.count(i)>1?w.Children.only(null):null});return e.displayName=`${t}.SlotClone`,e}var tX=Symbol("radix.slottable");function nX(t){return w.isValidElement(t)&&typeof t.type=="function"&&"__radixId"in t.type&&t.type.__radixId===tX}function rX(t,e){const n={...e};for(const r in e){const i=t[r],a=e[r];/^on[A-Z]/.test(r)?i&&a?n[r]=(...c)=>{const u=a(...c);return i(...c),u}:i&&(n[r]=i):r==="style"?n[r]={...i,...a}:r==="className"&&(n[r]=[i,a].filter(Boolean).join(" "))}return{...t,...n}}function iX(t){let e=Object.getOwnPropertyDescriptor(t.props,"ref")?.get,n=e&&"isReactWarning"in e&&e.isReactWarning;return n?t.ref:(e=Object.getOwnPropertyDescriptor(t,"ref")?.get,n=e&&"isReactWarning"in e&&e.isReactWarning,n?t.props.ref:t.props.ref||t.ref)}function bx(t){const e=t+"CollectionProvider",[n,r]=pa(e),[i,a]=n(e,{collectionRef:{current:null},itemMap:new Map}),o=S=>{const{scope:k,children:T}=S,C=le.useRef(null),E=le.useRef(new Map).current;return v.jsx(i,{scope:k,itemMap:E,collectionRef:C,children:T})};o.displayName=e;const c=t+"CollectionSlot",u=pc(c),f=le.forwardRef((S,k)=>{const{scope:T,children:C}=S,E=a(c,T),R=ft(k,E.collectionRef);return v.jsx(u,{ref:R,children:C})});f.displayName=c;const h=t+"CollectionItemSlot",m="data-radix-collection-item",g=pc(h),y=le.forwardRef((S,k)=>{const{scope:T,children:C,...E}=S,R=le.useRef(null),$=ft(k,R),P=a(h,T);return le.useEffect(()=>(P.itemMap.set(R,{ref:R,...E}),()=>{P.itemMap.delete(R)})),v.jsx(g,{[m]:"",ref:$,children:C})});y.displayName=h;function x(S){const k=a(t+"CollectionConsumer",S);return le.useCallback(()=>{const C=k.collectionRef.current;if(!C)return[];const E=Array.from(C.querySelectorAll(`[${m}]`));return Array.from(k.itemMap.values()).sort((P,_)=>E.indexOf(P.ref.current)-E.indexOf(_.ref.current))},[k.collectionRef,k.itemMap])}return[{Provider:o,Slot:f,ItemSlot:y},x,r]}var aX=w.createContext(void 0);function Nm(t){const e=w.useContext(aX);return t||e||"ltr"}var sX=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],et=sX.reduce((t,e)=>{const n=pc(`Primitive.${e}`),r=w.forwardRef((i,a)=>{const{asChild:o,...c}=i,u=o?n:e;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),v.jsx(u,{...c,ref:a})});return r.displayName=`Primitive.${e}`,{...t,[e]:r}},{});function oX(t,e){t&&tf.flushSync(()=>t.dispatchEvent(e))}function kr(t){const e=w.useRef(t);return w.useEffect(()=>{e.current=t}),w.useMemo(()=>(...n)=>e.current?.(...n),[])}function lX(t,e=globalThis?.document){const n=kr(t);w.useEffect(()=>{const r=i=>{i.key==="Escape"&&n(i)};return e.addEventListener("keydown",r,{capture:!0}),()=>e.removeEventListener("keydown",r,{capture:!0})},[n,e])}var cX="DismissableLayer",x0="dismissableLayer.update",uX="dismissableLayer.pointerDownOutside",dX="dismissableLayer.focusOutside",XT,f_=w.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),Dm=w.forwardRef((t,e)=>{const{disableOutsidePointerEvents:n=!1,onEscapeKeyDown:r,onPointerDownOutside:i,onFocusOutside:a,onInteractOutside:o,onDismiss:c,...u}=t,f=w.useContext(f_),[h,m]=w.useState(null),g=h?.ownerDocument??globalThis?.document,[,y]=w.useState({}),x=ft(e,_=>m(_)),S=Array.from(f.layers),[k]=[...f.layersWithOutsidePointerEventsDisabled].slice(-1),T=S.indexOf(k),C=h?S.indexOf(h):-1,E=f.layersWithOutsidePointerEventsDisabled.size>0,R=C>=T,$=pX(_=>{const M=_.target,V=[...f.branches].some(F=>F.contains(M));!R||V||(i?.(_),o?.(_),_.defaultPrevented||c?.())},g),P=mX(_=>{const M=_.target;[...f.branches].some(F=>F.contains(M))||(a?.(_),o?.(_),_.defaultPrevented||c?.())},g);return lX(_=>{C===f.layers.size-1&&(r?.(_),!_.defaultPrevented&&c&&(_.preventDefault(),c()))},g),w.useEffect(()=>{if(h)return n&&(f.layersWithOutsidePointerEventsDisabled.size===0&&(XT=g.body.style.pointerEvents,g.body.style.pointerEvents="none"),f.layersWithOutsidePointerEventsDisabled.add(h)),f.layers.add(h),BT(),()=>{n&&f.layersWithOutsidePointerEventsDisabled.size===1&&(g.body.style.pointerEvents=XT)}},[h,g,n,f]),w.useEffect(()=>()=>{h&&(f.layers.delete(h),f.layersWithOutsidePointerEventsDisabled.delete(h),BT())},[h,f]),w.useEffect(()=>{const _=()=>y({});return document.addEventListener(x0,_),()=>document.removeEventListener(x0,_)},[]),v.jsx(et.div,{...u,ref:x,style:{pointerEvents:E?R?"auto":"none":void 0,...t.style},onFocusCapture:He(t.onFocusCapture,P.onFocusCapture),onBlurCapture:He(t.onBlurCapture,P.onBlurCapture),onPointerDownCapture:He(t.onPointerDownCapture,$.onPointerDownCapture)})});Dm.displayName=cX;var fX="DismissableLayerBranch",hX=w.forwardRef((t,e)=>{const n=w.useContext(f_),r=w.useRef(null),i=ft(e,r);return w.useEffect(()=>{const a=r.current;if(a)return n.branches.add(a),()=>{n.branches.delete(a)}},[n.branches]),v.jsx(et.div,{...t,ref:i})});hX.displayName=fX;function pX(t,e=globalThis?.document){const n=kr(t),r=w.useRef(!1),i=w.useRef(()=>{});return w.useEffect(()=>{const a=c=>{if(c.target&&!r.current){let u=function(){h_(uX,n,f,{discrete:!0})};const f={originalEvent:c};c.pointerType==="touch"?(e.removeEventListener("click",i.current),i.current=u,e.addEventListener("click",i.current,{once:!0})):u()}else e.removeEventListener("click",i.current);r.current=!1},o=window.setTimeout(()=>{e.addEventListener("pointerdown",a)},0);return()=>{window.clearTimeout(o),e.removeEventListener("pointerdown",a),e.removeEventListener("click",i.current)}},[e,n]),{onPointerDownCapture:()=>r.current=!0}}function mX(t,e=globalThis?.document){const n=kr(t),r=w.useRef(!1);return w.useEffect(()=>{const i=a=>{a.target&&!r.current&&h_(dX,n,{originalEvent:a},{discrete:!1})};return e.addEventListener("focusin",i),()=>e.removeEventListener("focusin",i)},[e,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}function BT(){const t=new CustomEvent(x0);document.dispatchEvent(t)}function h_(t,e,n,{discrete:r}){const i=n.originalEvent.target,a=new CustomEvent(t,{bubbles:!1,cancelable:!0,detail:n});e&&i.addEventListener(t,e,{once:!0}),r?oX(i,a):i.dispatchEvent(a)}var Jv=0;function xx(){w.useEffect(()=>{const t=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",t[0]??IT()),document.body.insertAdjacentElement("beforeend",t[1]??IT()),Jv++,()=>{Jv===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(e=>e.remove()),Jv--}},[])}function IT(){const t=document.createElement("span");return t.setAttribute("data-radix-focus-guard",""),t.tabIndex=0,t.style.outline="none",t.style.opacity="0",t.style.position="fixed",t.style.pointerEvents="none",t}var ey="focusScope.autoFocusOnMount",ty="focusScope.autoFocusOnUnmount",qT={bubbles:!1,cancelable:!0},gX="FocusScope",zm=w.forwardRef((t,e)=>{const{loop:n=!1,trapped:r=!1,onMountAutoFocus:i,onUnmountAutoFocus:a,...o}=t,[c,u]=w.useState(null),f=kr(i),h=kr(a),m=w.useRef(null),g=ft(e,S=>u(S)),y=w.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;w.useEffect(()=>{if(r){let S=function(E){if(y.paused||!c)return;const R=E.target;c.contains(R)?m.current=R:Ts(m.current,{select:!0})},k=function(E){if(y.paused||!c)return;const R=E.relatedTarget;R!==null&&(c.contains(R)||Ts(m.current,{select:!0}))},T=function(E){if(document.activeElement===document.body)for(const $ of E)$.removedNodes.length>0&&Ts(c)};document.addEventListener("focusin",S),document.addEventListener("focusout",k);const C=new MutationObserver(T);return c&&C.observe(c,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",S),document.removeEventListener("focusout",k),C.disconnect()}}},[r,c,y.paused]),w.useEffect(()=>{if(c){YT.add(y);const S=document.activeElement;if(!c.contains(S)){const T=new CustomEvent(ey,qT);c.addEventListener(ey,f),c.dispatchEvent(T),T.defaultPrevented||(OX(SX(p_(c)),{select:!0}),document.activeElement===S&&Ts(c))}return()=>{c.removeEventListener(ey,f),setTimeout(()=>{const T=new CustomEvent(ty,qT);c.addEventListener(ty,h),c.dispatchEvent(T),T.defaultPrevented||Ts(S??document.body,{select:!0}),c.removeEventListener(ty,h),YT.remove(y)},0)}}},[c,f,h,y]);const x=w.useCallback(S=>{if(!n&&!r||y.paused)return;const k=S.key==="Tab"&&!S.altKey&&!S.ctrlKey&&!S.metaKey,T=document.activeElement;if(k&&T){const C=S.currentTarget,[E,R]=vX(C);E&&R?!S.shiftKey&&T===R?(S.preventDefault(),n&&Ts(E,{select:!0})):S.shiftKey&&T===E&&(S.preventDefault(),n&&Ts(R,{select:!0})):T===C&&S.preventDefault()}},[n,r,y.paused]);return v.jsx(et.div,{tabIndex:-1,...o,ref:g,onKeyDown:x})});zm.displayName=gX;function OX(t,{select:e=!1}={}){const n=document.activeElement;for(const r of t)if(Ts(r,{select:e}),document.activeElement!==n)return}function vX(t){const e=p_(t),n=UT(e,t),r=UT(e.reverse(),t);return[n,r]}function p_(t){const e=[],n=document.createTreeWalker(t,NodeFilter.SHOW_ELEMENT,{acceptNode:r=>{const i=r.tagName==="INPUT"&&r.type==="hidden";return r.disabled||r.hidden||i?NodeFilter.FILTER_SKIP:r.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)e.push(n.currentNode);return e}function UT(t,e){for(const n of t)if(!yX(n,{upTo:e}))return n}function yX(t,{upTo:e}){if(getComputedStyle(t).visibility==="hidden")return!0;for(;t;){if(e!==void 0&&t===e)return!1;if(getComputedStyle(t).display==="none")return!0;t=t.parentElement}return!1}function bX(t){return t instanceof HTMLInputElement&&"select"in t}function Ts(t,{select:e=!1}={}){if(t&&t.focus){const n=document.activeElement;t.focus({preventScroll:!0}),t!==n&&bX(t)&&e&&t.select()}}var YT=xX();function xX(){let t=[];return{add(e){const n=t[0];e!==n&&n?.pause(),t=FT(t,e),t.unshift(e)},remove(e){t=FT(t,e),t[0]?.resume()}}}function FT(t,e){const n=[...t],r=n.indexOf(e);return r!==-1&&n.splice(r,1),n}function SX(t){return t.filter(e=>e.tagName!=="A")}var jn=globalThis?.document?w.useLayoutEffect:()=>{},wX=rx[" useId ".trim().toString()]||(()=>{}),kX=0;function Ba(t){const[e,n]=w.useState(wX());return jn(()=>{n(r=>r??String(kX++))},[t]),t||(e?`radix-${e}`:"")}const CX=["top","right","bottom","left"],Vs=Math.min,Vr=Math.max,Dp=Math.round,$h=Math.floor,ca=t=>({x:t,y:t}),TX={left:"right",right:"left",bottom:"top",top:"bottom"},EX={start:"end",end:"start"};function S0(t,e,n){return Vr(t,Vs(e,n))}function Fa(t,e){return typeof t=="function"?t(e):t}function Wa(t){return t.split("-")[0]}function Bc(t){return t.split("-")[1]}function Sx(t){return t==="x"?"y":"x"}function wx(t){return t==="y"?"height":"width"}const QX=new Set(["top","bottom"]);function ia(t){return QX.has(Wa(t))?"y":"x"}function kx(t){return Sx(ia(t))}function AX(t,e,n){n===void 0&&(n=!1);const r=Bc(t),i=kx(t),a=wx(i);let o=i==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return e.reference[a]>e.floating[a]&&(o=zp(o)),[o,zp(o)]}function RX(t){const e=zp(t);return[w0(t),e,w0(e)]}function w0(t){return t.replace(/start|end/g,e=>EX[e])}const WT=["left","right"],GT=["right","left"],_X=["top","bottom"],$X=["bottom","top"];function PX(t,e,n){switch(t){case"top":case"bottom":return n?e?GT:WT:e?WT:GT;case"left":case"right":return e?_X:$X;default:return[]}}function jX(t,e,n,r){const i=Bc(t);let a=PX(Wa(t),n==="start",r);return i&&(a=a.map(o=>o+"-"+i),e&&(a=a.concat(a.map(w0)))),a}function zp(t){return t.replace(/left|right|bottom|top/g,e=>TX[e])}function MX(t){return{top:0,right:0,bottom:0,left:0,...t}}function m_(t){return typeof t!="number"?MX(t):{top:t,right:t,bottom:t,left:t}}function Lp(t){const{x:e,y:n,width:r,height:i}=t;return{width:r,height:i,top:n,left:e,right:e+r,bottom:n+i,x:e,y:n}}function HT(t,e,n){let{reference:r,floating:i}=t;const a=ia(e),o=kx(e),c=wx(o),u=Wa(e),f=a==="y",h=r.x+r.width/2-i.width/2,m=r.y+r.height/2-i.height/2,g=r[c]/2-i[c]/2;let y;switch(u){case"top":y={x:h,y:r.y-i.height};break;case"bottom":y={x:h,y:r.y+r.height};break;case"right":y={x:r.x+r.width,y:m};break;case"left":y={x:r.x-i.width,y:m};break;default:y={x:r.x,y:r.y}}switch(Bc(e)){case"start":y[o]-=g*(n&&f?-1:1);break;case"end":y[o]+=g*(n&&f?-1:1);break}return y}const NX=async(t,e,n)=>{const{placement:r="bottom",strategy:i="absolute",middleware:a=[],platform:o}=n,c=a.filter(Boolean),u=await(o.isRTL==null?void 0:o.isRTL(e));let f=await o.getElementRects({reference:t,floating:e,strategy:i}),{x:h,y:m}=HT(f,r,u),g=r,y={},x=0;for(let S=0;S<c.length;S++){const{name:k,fn:T}=c[S],{x:C,y:E,data:R,reset:$}=await T({x:h,y:m,initialPlacement:r,placement:g,strategy:i,middlewareData:y,rects:f,platform:o,elements:{reference:t,floating:e}});h=C??h,m=E??m,y={...y,[k]:{...y[k],...R}},$&&x<=50&&(x++,typeof $=="object"&&($.placement&&(g=$.placement),$.rects&&(f=$.rects===!0?await o.getElementRects({reference:t,floating:e,strategy:i}):$.rects),{x:h,y:m}=HT(f,g,u)),S=-1)}return{x:h,y:m,placement:g,strategy:i,middlewareData:y}};async function bd(t,e){var n;e===void 0&&(e={});const{x:r,y:i,platform:a,rects:o,elements:c,strategy:u}=t,{boundary:f="clippingAncestors",rootBoundary:h="viewport",elementContext:m="floating",altBoundary:g=!1,padding:y=0}=Fa(e,t),x=m_(y),k=c[g?m==="floating"?"reference":"floating":m],T=Lp(await a.getClippingRect({element:(n=await(a.isElement==null?void 0:a.isElement(k)))==null||n?k:k.contextElement||await(a.getDocumentElement==null?void 0:a.getDocumentElement(c.floating)),boundary:f,rootBoundary:h,strategy:u})),C=m==="floating"?{x:r,y:i,width:o.floating.width,height:o.floating.height}:o.reference,E=await(a.getOffsetParent==null?void 0:a.getOffsetParent(c.floating)),R=await(a.isElement==null?void 0:a.isElement(E))?await(a.getScale==null?void 0:a.getScale(E))||{x:1,y:1}:{x:1,y:1},$=Lp(a.convertOffsetParentRelativeRectToViewportRelativeRect?await a.convertOffsetParentRelativeRectToViewportRelativeRect({elements:c,rect:C,offsetParent:E,strategy:u}):C);return{top:(T.top-$.top+x.top)/R.y,bottom:($.bottom-T.bottom+x.bottom)/R.y,left:(T.left-$.left+x.left)/R.x,right:($.right-T.right+x.right)/R.x}}const DX=t=>({name:"arrow",options:t,async fn(e){const{x:n,y:r,placement:i,rects:a,platform:o,elements:c,middlewareData:u}=e,{element:f,padding:h=0}=Fa(t,e)||{};if(f==null)return{};const m=m_(h),g={x:n,y:r},y=kx(i),x=wx(y),S=await o.getDimensions(f),k=y==="y",T=k?"top":"left",C=k?"bottom":"right",E=k?"clientHeight":"clientWidth",R=a.reference[x]+a.reference[y]-g[y]-a.floating[x],$=g[y]-a.reference[y],P=await(o.getOffsetParent==null?void 0:o.getOffsetParent(f));let _=P?P[E]:0;(!_||!await(o.isElement==null?void 0:o.isElement(P)))&&(_=c.floating[E]||a.floating[x]);const M=R/2-$/2,V=_/2-S[x]/2-1,F=Vs(m[T],V),W=Vs(m[C],V),I=F,ne=_-S[x]-W,ee=_/2-S[x]/2+M,pe=S0(I,ee,ne),D=!u.arrow&&Bc(i)!=null&&ee!==pe&&a.reference[x]/2-(ee<I?F:W)-S[x]/2<0,G=D?ee<I?ee-I:ee-ne:0;return{[y]:g[y]+G,data:{[y]:pe,centerOffset:ee-pe-G,...D&&{alignmentOffset:G}},reset:D}}}),zX=function(t){return t===void 0&&(t={}),{name:"flip",options:t,async fn(e){var n,r;const{placement:i,middlewareData:a,rects:o,initialPlacement:c,platform:u,elements:f}=e,{mainAxis:h=!0,crossAxis:m=!0,fallbackPlacements:g,fallbackStrategy:y="bestFit",fallbackAxisSideDirection:x="none",flipAlignment:S=!0,...k}=Fa(t,e);if((n=a.arrow)!=null&&n.alignmentOffset)return{};const T=Wa(i),C=ia(c),E=Wa(c)===c,R=await(u.isRTL==null?void 0:u.isRTL(f.floating)),$=g||(E||!S?[zp(c)]:RX(c)),P=x!=="none";!g&&P&&$.push(...jX(c,S,x,R));const _=[c,...$],M=await bd(e,k),V=[];let F=((r=a.flip)==null?void 0:r.overflows)||[];if(h&&V.push(M[T]),m){const ee=AX(i,o,R);V.push(M[ee[0]],M[ee[1]])}if(F=[...F,{placement:i,overflows:V}],!V.every(ee=>ee<=0)){var W,I;const ee=(((W=a.flip)==null?void 0:W.index)||0)+1,pe=_[ee];if(pe&&(!(m==="alignment"?C!==ia(pe):!1)||F.every(B=>ia(B.placement)===C?B.overflows[0]>0:!0)))return{data:{index:ee,overflows:F},reset:{placement:pe}};let D=(I=F.filter(G=>G.overflows[0]<=0).sort((G,B)=>G.overflows[1]-B.overflows[1])[0])==null?void 0:I.placement;if(!D)switch(y){case"bestFit":{var ne;const G=(ne=F.filter(B=>{if(P){const ye=ia(B.placement);return ye===C||ye==="y"}return!0}).map(B=>[B.placement,B.overflows.filter(ye=>ye>0).reduce((ye,X)=>ye+X,0)]).sort((B,ye)=>B[1]-ye[1])[0])==null?void 0:ne[0];G&&(D=G);break}case"initialPlacement":D=c;break}if(i!==D)return{reset:{placement:D}}}return{}}}};function KT(t,e){return{top:t.top-e.height,right:t.right-e.width,bottom:t.bottom-e.height,left:t.left-e.width}}function JT(t){return CX.some(e=>t[e]>=0)}const LX=function(t){return t===void 0&&(t={}),{name:"hide",options:t,async fn(e){const{rects:n}=e,{strategy:r="referenceHidden",...i}=Fa(t,e);switch(r){case"referenceHidden":{const a=await bd(e,{...i,elementContext:"reference"}),o=KT(a,n.reference);return{data:{referenceHiddenOffsets:o,referenceHidden:JT(o)}}}case"escaped":{const a=await bd(e,{...i,altBoundary:!0}),o=KT(a,n.floating);return{data:{escapedOffsets:o,escaped:JT(o)}}}default:return{}}}}},g_=new Set(["left","top"]);async function ZX(t,e){const{placement:n,platform:r,elements:i}=t,a=await(r.isRTL==null?void 0:r.isRTL(i.floating)),o=Wa(n),c=Bc(n),u=ia(n)==="y",f=g_.has(o)?-1:1,h=a&&u?-1:1,m=Fa(e,t);let{mainAxis:g,crossAxis:y,alignmentAxis:x}=typeof m=="number"?{mainAxis:m,crossAxis:0,alignmentAxis:null}:{mainAxis:m.mainAxis||0,crossAxis:m.crossAxis||0,alignmentAxis:m.alignmentAxis};return c&&typeof x=="number"&&(y=c==="end"?x*-1:x),u?{x:y*h,y:g*f}:{x:g*f,y:y*h}}const VX=function(t){return t===void 0&&(t=0),{name:"offset",options:t,async fn(e){var n,r;const{x:i,y:a,placement:o,middlewareData:c}=e,u=await ZX(e,t);return o===((n=c.offset)==null?void 0:n.placement)&&(r=c.arrow)!=null&&r.alignmentOffset?{}:{x:i+u.x,y:a+u.y,data:{...u,placement:o}}}}},XX=function(t){return t===void 0&&(t={}),{name:"shift",options:t,async fn(e){const{x:n,y:r,placement:i}=e,{mainAxis:a=!0,crossAxis:o=!1,limiter:c={fn:k=>{let{x:T,y:C}=k;return{x:T,y:C}}},...u}=Fa(t,e),f={x:n,y:r},h=await bd(e,u),m=ia(Wa(i)),g=Sx(m);let y=f[g],x=f[m];if(a){const k=g==="y"?"top":"left",T=g==="y"?"bottom":"right",C=y+h[k],E=y-h[T];y=S0(C,y,E)}if(o){const k=m==="y"?"top":"left",T=m==="y"?"bottom":"right",C=x+h[k],E=x-h[T];x=S0(C,x,E)}const S=c.fn({...e,[g]:y,[m]:x});return{...S,data:{x:S.x-n,y:S.y-r,enabled:{[g]:a,[m]:o}}}}}},BX=function(t){return t===void 0&&(t={}),{options:t,fn(e){const{x:n,y:r,placement:i,rects:a,middlewareData:o}=e,{offset:c=0,mainAxis:u=!0,crossAxis:f=!0}=Fa(t,e),h={x:n,y:r},m=ia(i),g=Sx(m);let y=h[g],x=h[m];const S=Fa(c,e),k=typeof S=="number"?{mainAxis:S,crossAxis:0}:{mainAxis:0,crossAxis:0,...S};if(u){const E=g==="y"?"height":"width",R=a.reference[g]-a.floating[E]+k.mainAxis,$=a.reference[g]+a.reference[E]-k.mainAxis;y<R?y=R:y>$&&(y=$)}if(f){var T,C;const E=g==="y"?"width":"height",R=g_.has(Wa(i)),$=a.reference[m]-a.floating[E]+(R&&((T=o.offset)==null?void 0:T[m])||0)+(R?0:k.crossAxis),P=a.reference[m]+a.reference[E]+(R?0:((C=o.offset)==null?void 0:C[m])||0)-(R?k.crossAxis:0);x<$?x=$:x>P&&(x=P)}return{[g]:y,[m]:x}}}},IX=function(t){return t===void 0&&(t={}),{name:"size",options:t,async fn(e){var n,r;const{placement:i,rects:a,platform:o,elements:c}=e,{apply:u=()=>{},...f}=Fa(t,e),h=await bd(e,f),m=Wa(i),g=Bc(i),y=ia(i)==="y",{width:x,height:S}=a.floating;let k,T;m==="top"||m==="bottom"?(k=m,T=g===(await(o.isRTL==null?void 0:o.isRTL(c.floating))?"start":"end")?"left":"right"):(T=m,k=g==="end"?"top":"bottom");const C=S-h.top-h.bottom,E=x-h.left-h.right,R=Vs(S-h[k],C),$=Vs(x-h[T],E),P=!e.middlewareData.shift;let _=R,M=$;if((n=e.middlewareData.shift)!=null&&n.enabled.x&&(M=E),(r=e.middlewareData.shift)!=null&&r.enabled.y&&(_=C),P&&!g){const F=Vr(h.left,0),W=Vr(h.right,0),I=Vr(h.top,0),ne=Vr(h.bottom,0);y?M=x-2*(F!==0||W!==0?F+W:Vr(h.left,h.right)):_=S-2*(I!==0||ne!==0?I+ne:Vr(h.top,h.bottom))}await u({...e,availableWidth:M,availableHeight:_});const V=await o.getDimensions(c.floating);return x!==V.width||S!==V.height?{reset:{rects:!0}}:{}}}};function Lm(){return typeof window<"u"}function Ic(t){return O_(t)?(t.nodeName||"").toLowerCase():"#document"}function Br(t){var e;return(t==null||(e=t.ownerDocument)==null?void 0:e.defaultView)||window}function ma(t){var e;return(e=(O_(t)?t.ownerDocument:t.document)||window.document)==null?void 0:e.documentElement}function O_(t){return Lm()?t instanceof Node||t instanceof Br(t).Node:!1}function Qi(t){return Lm()?t instanceof Element||t instanceof Br(t).Element:!1}function ha(t){return Lm()?t instanceof HTMLElement||t instanceof Br(t).HTMLElement:!1}function e2(t){return!Lm()||typeof ShadowRoot>"u"?!1:t instanceof ShadowRoot||t instanceof Br(t).ShadowRoot}const qX=new Set(["inline","contents"]);function nf(t){const{overflow:e,overflowX:n,overflowY:r,display:i}=Ai(t);return/auto|scroll|overlay|hidden|clip/.test(e+r+n)&&!qX.has(i)}const UX=new Set(["table","td","th"]);function YX(t){return UX.has(Ic(t))}const FX=[":popover-open",":modal"];function Zm(t){return FX.some(e=>{try{return t.matches(e)}catch{return!1}})}const WX=["transform","translate","scale","rotate","perspective"],GX=["transform","translate","scale","rotate","perspective","filter"],HX=["paint","layout","strict","content"];function Cx(t){const e=Tx(),n=Qi(t)?Ai(t):t;return WX.some(r=>n[r]?n[r]!=="none":!1)||(n.containerType?n.containerType!=="normal":!1)||!e&&(n.backdropFilter?n.backdropFilter!=="none":!1)||!e&&(n.filter?n.filter!=="none":!1)||GX.some(r=>(n.willChange||"").includes(r))||HX.some(r=>(n.contain||"").includes(r))}function KX(t){let e=Xs(t);for(;ha(e)&&!mc(e);){if(Cx(e))return e;if(Zm(e))return null;e=Xs(e)}return null}function Tx(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}const JX=new Set(["html","body","#document"]);function mc(t){return JX.has(Ic(t))}function Ai(t){return Br(t).getComputedStyle(t)}function Vm(t){return Qi(t)?{scrollLeft:t.scrollLeft,scrollTop:t.scrollTop}:{scrollLeft:t.scrollX,scrollTop:t.scrollY}}function Xs(t){if(Ic(t)==="html")return t;const e=t.assignedSlot||t.parentNode||e2(t)&&t.host||ma(t);return e2(e)?e.host:e}function v_(t){const e=Xs(t);return mc(e)?t.ownerDocument?t.ownerDocument.body:t.body:ha(e)&&nf(e)?e:v_(e)}function xd(t,e,n){var r;e===void 0&&(e=[]),n===void 0&&(n=!0);const i=v_(t),a=i===((r=t.ownerDocument)==null?void 0:r.body),o=Br(i);if(a){const c=k0(o);return e.concat(o,o.visualViewport||[],nf(i)?i:[],c&&n?xd(c):[])}return e.concat(i,xd(i,[],n))}function k0(t){return t.parent&&Object.getPrototypeOf(t.parent)?t.frameElement:null}function y_(t){const e=Ai(t);let n=parseFloat(e.width)||0,r=parseFloat(e.height)||0;const i=ha(t),a=i?t.offsetWidth:n,o=i?t.offsetHeight:r,c=Dp(n)!==a||Dp(r)!==o;return c&&(n=a,r=o),{width:n,height:r,$:c}}function Ex(t){return Qi(t)?t:t.contextElement}function ic(t){const e=Ex(t);if(!ha(e))return ca(1);const n=e.getBoundingClientRect(),{width:r,height:i,$:a}=y_(e);let o=(a?Dp(n.width):n.width)/r,c=(a?Dp(n.height):n.height)/i;return(!o||!Number.isFinite(o))&&(o=1),(!c||!Number.isFinite(c))&&(c=1),{x:o,y:c}}const eB=ca(0);function b_(t){const e=Br(t);return!Tx()||!e.visualViewport?eB:{x:e.visualViewport.offsetLeft,y:e.visualViewport.offsetTop}}function tB(t,e,n){return e===void 0&&(e=!1),!n||e&&n!==Br(t)?!1:e}function Zo(t,e,n,r){e===void 0&&(e=!1),n===void 0&&(n=!1);const i=t.getBoundingClientRect(),a=Ex(t);let o=ca(1);e&&(r?Qi(r)&&(o=ic(r)):o=ic(t));const c=tB(a,n,r)?b_(a):ca(0);let u=(i.left+c.x)/o.x,f=(i.top+c.y)/o.y,h=i.width/o.x,m=i.height/o.y;if(a){const g=Br(a),y=r&&Qi(r)?Br(r):r;let x=g,S=k0(x);for(;S&&r&&y!==x;){const k=ic(S),T=S.getBoundingClientRect(),C=Ai(S),E=T.left+(S.clientLeft+parseFloat(C.paddingLeft))*k.x,R=T.top+(S.clientTop+parseFloat(C.paddingTop))*k.y;u*=k.x,f*=k.y,h*=k.x,m*=k.y,u+=E,f+=R,x=Br(S),S=k0(x)}}return Lp({width:h,height:m,x:u,y:f})}function Xm(t,e){const n=Vm(t).scrollLeft;return e?e.left+n:Zo(ma(t)).left+n}function x_(t,e){const n=t.getBoundingClientRect(),r=n.left+e.scrollLeft-Xm(t,n),i=n.top+e.scrollTop;return{x:r,y:i}}function nB(t){let{elements:e,rect:n,offsetParent:r,strategy:i}=t;const a=i==="fixed",o=ma(r),c=e?Zm(e.floating):!1;if(r===o||c&&a)return n;let u={scrollLeft:0,scrollTop:0},f=ca(1);const h=ca(0),m=ha(r);if((m||!m&&!a)&&((Ic(r)!=="body"||nf(o))&&(u=Vm(r)),ha(r))){const y=Zo(r);f=ic(r),h.x=y.x+r.clientLeft,h.y=y.y+r.clientTop}const g=o&&!m&&!a?x_(o,u):ca(0);return{width:n.width*f.x,height:n.height*f.y,x:n.x*f.x-u.scrollLeft*f.x+h.x+g.x,y:n.y*f.y-u.scrollTop*f.y+h.y+g.y}}function rB(t){return Array.from(t.getClientRects())}function iB(t){const e=ma(t),n=Vm(t),r=t.ownerDocument.body,i=Vr(e.scrollWidth,e.clientWidth,r.scrollWidth,r.clientWidth),a=Vr(e.scrollHeight,e.clientHeight,r.scrollHeight,r.clientHeight);let o=-n.scrollLeft+Xm(t);const c=-n.scrollTop;return Ai(r).direction==="rtl"&&(o+=Vr(e.clientWidth,r.clientWidth)-i),{width:i,height:a,x:o,y:c}}const t2=25;function aB(t,e){const n=Br(t),r=ma(t),i=n.visualViewport;let a=r.clientWidth,o=r.clientHeight,c=0,u=0;if(i){a=i.width,o=i.height;const h=Tx();(!h||h&&e==="fixed")&&(c=i.offsetLeft,u=i.offsetTop)}const f=Xm(r);if(f<=0){const h=r.ownerDocument,m=h.body,g=getComputedStyle(m),y=h.compatMode==="CSS1Compat"&&parseFloat(g.marginLeft)+parseFloat(g.marginRight)||0,x=Math.abs(r.clientWidth-m.clientWidth-y);x<=t2&&(a-=x)}else f<=t2&&(a+=f);return{width:a,height:o,x:c,y:u}}const sB=new Set(["absolute","fixed"]);function oB(t,e){const n=Zo(t,!0,e==="fixed"),r=n.top+t.clientTop,i=n.left+t.clientLeft,a=ha(t)?ic(t):ca(1),o=t.clientWidth*a.x,c=t.clientHeight*a.y,u=i*a.x,f=r*a.y;return{width:o,height:c,x:u,y:f}}function n2(t,e,n){let r;if(e==="viewport")r=aB(t,n);else if(e==="document")r=iB(ma(t));else if(Qi(e))r=oB(e,n);else{const i=b_(t);r={x:e.x-i.x,y:e.y-i.y,width:e.width,height:e.height}}return Lp(r)}function S_(t,e){const n=Xs(t);return n===e||!Qi(n)||mc(n)?!1:Ai(n).position==="fixed"||S_(n,e)}function lB(t,e){const n=e.get(t);if(n)return n;let r=xd(t,[],!1).filter(c=>Qi(c)&&Ic(c)!=="body"),i=null;const a=Ai(t).position==="fixed";let o=a?Xs(t):t;for(;Qi(o)&&!mc(o);){const c=Ai(o),u=Cx(o);!u&&c.position==="fixed"&&(i=null),(a?!u&&!i:!u&&c.position==="static"&&!!i&&sB.has(i.position)||nf(o)&&!u&&S_(t,o))?r=r.filter(h=>h!==o):i=c,o=Xs(o)}return e.set(t,r),r}function cB(t){let{element:e,boundary:n,rootBoundary:r,strategy:i}=t;const o=[...n==="clippingAncestors"?Zm(e)?[]:lB(e,this._c):[].concat(n),r],c=o[0],u=o.reduce((f,h)=>{const m=n2(e,h,i);return f.top=Vr(m.top,f.top),f.right=Vs(m.right,f.right),f.bottom=Vs(m.bottom,f.bottom),f.left=Vr(m.left,f.left),f},n2(e,c,i));return{width:u.right-u.left,height:u.bottom-u.top,x:u.left,y:u.top}}function uB(t){const{width:e,height:n}=y_(t);return{width:e,height:n}}function dB(t,e,n){const r=ha(e),i=ma(e),a=n==="fixed",o=Zo(t,!0,a,e);let c={scrollLeft:0,scrollTop:0};const u=ca(0);function f(){u.x=Xm(i)}if(r||!r&&!a)if((Ic(e)!=="body"||nf(i))&&(c=Vm(e)),r){const y=Zo(e,!0,a,e);u.x=y.x+e.clientLeft,u.y=y.y+e.clientTop}else i&&f();a&&!r&&i&&f();const h=i&&!r&&!a?x_(i,c):ca(0),m=o.left+c.scrollLeft-u.x-h.x,g=o.top+c.scrollTop-u.y-h.y;return{x:m,y:g,width:o.width,height:o.height}}function ny(t){return Ai(t).position==="static"}function r2(t,e){if(!ha(t)||Ai(t).position==="fixed")return null;if(e)return e(t);let n=t.offsetParent;return ma(t)===n&&(n=n.ownerDocument.body),n}function w_(t,e){const n=Br(t);if(Zm(t))return n;if(!ha(t)){let i=Xs(t);for(;i&&!mc(i);){if(Qi(i)&&!ny(i))return i;i=Xs(i)}return n}let r=r2(t,e);for(;r&&YX(r)&&ny(r);)r=r2(r,e);return r&&mc(r)&&ny(r)&&!Cx(r)?n:r||KX(t)||n}const fB=async function(t){const e=this.getOffsetParent||w_,n=this.getDimensions,r=await n(t.floating);return{reference:dB(t.reference,await e(t.floating),t.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function hB(t){return Ai(t).direction==="rtl"}const pB={convertOffsetParentRelativeRectToViewportRelativeRect:nB,getDocumentElement:ma,getClippingRect:cB,getOffsetParent:w_,getElementRects:fB,getClientRects:rB,getDimensions:uB,getScale:ic,isElement:Qi,isRTL:hB};function k_(t,e){return t.x===e.x&&t.y===e.y&&t.width===e.width&&t.height===e.height}function mB(t,e){let n=null,r;const i=ma(t);function a(){var c;clearTimeout(r),(c=n)==null||c.disconnect(),n=null}function o(c,u){c===void 0&&(c=!1),u===void 0&&(u=1),a();const f=t.getBoundingClientRect(),{left:h,top:m,width:g,height:y}=f;if(c||e(),!g||!y)return;const x=$h(m),S=$h(i.clientWidth-(h+g)),k=$h(i.clientHeight-(m+y)),T=$h(h),E={rootMargin:-x+"px "+-S+"px "+-k+"px "+-T+"px",threshold:Vr(0,Vs(1,u))||1};let R=!0;function $(P){const _=P[0].intersectionRatio;if(_!==u){if(!R)return o();_?o(!1,_):r=setTimeout(()=>{o(!1,1e-7)},1e3)}_===1&&!k_(f,t.getBoundingClientRect())&&o(),R=!1}try{n=new IntersectionObserver($,{...E,root:i.ownerDocument})}catch{n=new IntersectionObserver($,E)}n.observe(t)}return o(!0),a}function gB(t,e,n,r){r===void 0&&(r={});const{ancestorScroll:i=!0,ancestorResize:a=!0,elementResize:o=typeof ResizeObserver=="function",layoutShift:c=typeof IntersectionObserver=="function",animationFrame:u=!1}=r,f=Ex(t),h=i||a?[...f?xd(f):[],...xd(e)]:[];h.forEach(T=>{i&&T.addEventListener("scroll",n,{passive:!0}),a&&T.addEventListener("resize",n)});const m=f&&c?mB(f,n):null;let g=-1,y=null;o&&(y=new ResizeObserver(T=>{let[C]=T;C&&C.target===f&&y&&(y.unobserve(e),cancelAnimationFrame(g),g=requestAnimationFrame(()=>{var E;(E=y)==null||E.observe(e)})),n()}),f&&!u&&y.observe(f),y.observe(e));let x,S=u?Zo(t):null;u&&k();function k(){const T=Zo(t);S&&!k_(S,T)&&n(),S=T,x=requestAnimationFrame(k)}return n(),()=>{var T;h.forEach(C=>{i&&C.removeEventListener("scroll",n),a&&C.removeEventListener("resize",n)}),m?.(),(T=y)==null||T.disconnect(),y=null,u&&cancelAnimationFrame(x)}}const OB=VX,vB=XX,yB=zX,bB=IX,xB=LX,i2=DX,SB=BX,wB=(t,e,n)=>{const r=new Map,i={platform:pB,...n},a={...i.platform,_c:r};return NX(t,e,{...i,platform:a})};var kB=typeof document<"u",CB=function(){},hp=kB?w.useLayoutEffect:CB;function Zp(t,e){if(t===e)return!0;if(typeof t!=typeof e)return!1;if(typeof t=="function"&&t.toString()===e.toString())return!0;let n,r,i;if(t&&e&&typeof t=="object"){if(Array.isArray(t)){if(n=t.length,n!==e.length)return!1;for(r=n;r--!==0;)if(!Zp(t[r],e[r]))return!1;return!0}if(i=Object.keys(t),n=i.length,n!==Object.keys(e).length)return!1;for(r=n;r--!==0;)if(!{}.hasOwnProperty.call(e,i[r]))return!1;for(r=n;r--!==0;){const a=i[r];if(!(a==="_owner"&&t.$$typeof)&&!Zp(t[a],e[a]))return!1}return!0}return t!==t&&e!==e}function C_(t){return typeof window>"u"?1:(t.ownerDocument.defaultView||window).devicePixelRatio||1}function a2(t,e){const n=C_(t);return Math.round(e*n)/n}function ry(t){const e=w.useRef(t);return hp(()=>{e.current=t}),e}function TB(t){t===void 0&&(t={});const{placement:e="bottom",strategy:n="absolute",middleware:r=[],platform:i,elements:{reference:a,floating:o}={},transform:c=!0,whileElementsMounted:u,open:f}=t,[h,m]=w.useState({x:0,y:0,strategy:n,placement:e,middlewareData:{},isPositioned:!1}),[g,y]=w.useState(r);Zp(g,r)||y(r);const[x,S]=w.useState(null),[k,T]=w.useState(null),C=w.useCallback(B=>{B!==P.current&&(P.current=B,S(B))},[]),E=w.useCallback(B=>{B!==_.current&&(_.current=B,T(B))},[]),R=a||x,$=o||k,P=w.useRef(null),_=w.useRef(null),M=w.useRef(h),V=u!=null,F=ry(u),W=ry(i),I=ry(f),ne=w.useCallback(()=>{if(!P.current||!_.current)return;const B={placement:e,strategy:n,middleware:g};W.current&&(B.platform=W.current),wB(P.current,_.current,B).then(ye=>{const X={...ye,isPositioned:I.current!==!1};ee.current&&!Zp(M.current,X)&&(M.current=X,tf.flushSync(()=>{m(X)}))})},[g,e,n,W,I]);hp(()=>{f===!1&&M.current.isPositioned&&(M.current.isPositioned=!1,m(B=>({...B,isPositioned:!1})))},[f]);const ee=w.useRef(!1);hp(()=>(ee.current=!0,()=>{ee.current=!1}),[]),hp(()=>{if(R&&(P.current=R),$&&(_.current=$),R&&$){if(F.current)return F.current(R,$,ne);ne()}},[R,$,ne,F,V]);const pe=w.useMemo(()=>({reference:P,floating:_,setReference:C,setFloating:E}),[C,E]),D=w.useMemo(()=>({reference:R,floating:$}),[R,$]),G=w.useMemo(()=>{const B={position:n,left:0,top:0};if(!D.floating)return B;const ye=a2(D.floating,h.x),X=a2(D.floating,h.y);return c?{...B,transform:"translate("+ye+"px, "+X+"px)",...C_(D.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:ye,top:X}},[n,c,D.floating,h.x,h.y]);return w.useMemo(()=>({...h,update:ne,refs:pe,elements:D,floatingStyles:G}),[h,ne,pe,D,G])}const EB=t=>{function e(n){return{}.hasOwnProperty.call(n,"current")}return{name:"arrow",options:t,fn(n){const{element:r,padding:i}=typeof t=="function"?t(n):t;return r&&e(r)?r.current!=null?i2({element:r.current,padding:i}).fn(n):{}:r?i2({element:r,padding:i}).fn(n):{}}}},QB=(t,e)=>({...OB(t),options:[t,e]}),AB=(t,e)=>({...vB(t),options:[t,e]}),RB=(t,e)=>({...SB(t),options:[t,e]}),_B=(t,e)=>({...yB(t),options:[t,e]}),$B=(t,e)=>({...bB(t),options:[t,e]}),PB=(t,e)=>({...xB(t),options:[t,e]}),jB=(t,e)=>({...EB(t),options:[t,e]});var MB="Arrow",T_=w.forwardRef((t,e)=>{const{children:n,width:r=10,height:i=5,...a}=t;return v.jsx(et.svg,{...a,ref:e,width:r,height:i,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:t.asChild?n:v.jsx("polygon",{points:"0,0 30,0 15,10"})})});T_.displayName=MB;var NB=T_;function Qx(t){const[e,n]=w.useState(void 0);return jn(()=>{if(t){n({width:t.offsetWidth,height:t.offsetHeight});const r=new ResizeObserver(i=>{if(!Array.isArray(i)||!i.length)return;const a=i[0];let o,c;if("borderBoxSize"in a){const u=a.borderBoxSize,f=Array.isArray(u)?u[0]:u;o=f.inlineSize,c=f.blockSize}else o=t.offsetWidth,c=t.offsetHeight;n({width:o,height:c})});return r.observe(t,{box:"border-box"}),()=>r.unobserve(t)}else n(void 0)},[t]),e}var Ax="Popper",[E_,Bm]=pa(Ax),[DB,Q_]=E_(Ax),A_=t=>{const{__scopePopper:e,children:n}=t,[r,i]=w.useState(null);return v.jsx(DB,{scope:e,anchor:r,onAnchorChange:i,children:n})};A_.displayName=Ax;var R_="PopperAnchor",__=w.forwardRef((t,e)=>{const{__scopePopper:n,virtualRef:r,...i}=t,a=Q_(R_,n),o=w.useRef(null),c=ft(e,o),u=w.useRef(null);return w.useEffect(()=>{const f=u.current;u.current=r?.current||o.current,f!==u.current&&a.onAnchorChange(u.current)}),r?null:v.jsx(et.div,{...i,ref:c})});__.displayName=R_;var Rx="PopperContent",[zB,LB]=E_(Rx),$_=w.forwardRef((t,e)=>{const{__scopePopper:n,side:r="bottom",sideOffset:i=0,align:a="center",alignOffset:o=0,arrowPadding:c=0,avoidCollisions:u=!0,collisionBoundary:f=[],collisionPadding:h=0,sticky:m="partial",hideWhenDetached:g=!1,updatePositionStrategy:y="optimized",onPlaced:x,...S}=t,k=Q_(Rx,n),[T,C]=w.useState(null),E=ft(e,H=>C(H)),[R,$]=w.useState(null),P=Qx(R),_=P?.width??0,M=P?.height??0,V=r+(a!=="center"?"-"+a:""),F=typeof h=="number"?h:{top:0,right:0,bottom:0,left:0,...h},W=Array.isArray(f)?f:[f],I=W.length>0,ne={padding:F,boundary:W.filter(VB),altBoundary:I},{refs:ee,floatingStyles:pe,placement:D,isPositioned:G,middlewareData:B}=TB({strategy:"fixed",placement:V,whileElementsMounted:(...H)=>gB(...H,{animationFrame:y==="always"}),elements:{reference:k.anchor},middleware:[QB({mainAxis:i+M,alignmentAxis:o}),u&&AB({mainAxis:!0,crossAxis:!1,limiter:m==="partial"?RB():void 0,...ne}),u&&_B({...ne}),$B({...ne,apply:({elements:H,rects:ge,availableWidth:xe,availableHeight:ke})=>{const{width:Ce,height:Re}=ge.reference,We=H.floating.style;We.setProperty("--radix-popper-available-width",`${xe}px`),We.setProperty("--radix-popper-available-height",`${ke}px`),We.setProperty("--radix-popper-anchor-width",`${Ce}px`),We.setProperty("--radix-popper-anchor-height",`${Re}px`)}}),R&&jB({element:R,padding:c}),XB({arrowWidth:_,arrowHeight:M}),g&&PB({strategy:"referenceHidden",...ne})]}),[ye,X]=M_(D),A=kr(x);jn(()=>{G&&A?.()},[G,A]);const N=B.arrow?.x,L=B.arrow?.y,q=B.arrow?.centerOffset!==0,[se,he]=w.useState();return jn(()=>{T&&he(window.getComputedStyle(T).zIndex)},[T]),v.jsx("div",{ref:ee.setFloating,"data-radix-popper-content-wrapper":"",style:{...pe,transform:G?pe.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:se,"--radix-popper-transform-origin":[B.transformOrigin?.x,B.transformOrigin?.y].join(" "),...B.hide?.referenceHidden&&{visibility:"hidden",pointerEvents:"none"}},dir:t.dir,children:v.jsx(zB,{scope:n,placedSide:ye,onArrowChange:$,arrowX:N,arrowY:L,shouldHideArrow:q,children:v.jsx(et.div,{"data-side":ye,"data-align":X,...S,ref:E,style:{...S.style,animation:G?void 0:"none"}})})})});$_.displayName=Rx;var P_="PopperArrow",ZB={top:"bottom",right:"left",bottom:"top",left:"right"},j_=w.forwardRef(function(e,n){const{__scopePopper:r,...i}=e,a=LB(P_,r),o=ZB[a.placedSide];return v.jsx("span",{ref:a.onArrowChange,style:{position:"absolute",left:a.arrowX,top:a.arrowY,[o]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[a.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[a.placedSide],visibility:a.shouldHideArrow?"hidden":void 0},children:v.jsx(NB,{...i,ref:n,style:{...i.style,display:"block"}})})});j_.displayName=P_;function VB(t){return t!==null}var XB=t=>({name:"transformOrigin",options:t,fn(e){const{placement:n,rects:r,middlewareData:i}=e,o=i.arrow?.centerOffset!==0,c=o?0:t.arrowWidth,u=o?0:t.arrowHeight,[f,h]=M_(n),m={start:"0%",center:"50%",end:"100%"}[h],g=(i.arrow?.x??0)+c/2,y=(i.arrow?.y??0)+u/2;let x="",S="";return f==="bottom"?(x=o?m:`${g}px`,S=`${-u}px`):f==="top"?(x=o?m:`${g}px`,S=`${r.floating.height+u}px`):f==="right"?(x=`${-u}px`,S=o?m:`${y}px`):f==="left"&&(x=`${r.floating.width+u}px`,S=o?m:`${y}px`),{data:{x,y:S}}}});function M_(t){const[e,n="center"]=t.split("-");return[e,n]}var N_=A_,_x=__,D_=$_,z_=j_,BB="Portal",Im=w.forwardRef((t,e)=>{const{container:n,...r}=t,[i,a]=w.useState(!1);jn(()=>a(!0),[]);const o=n||i&&globalThis?.document?.body;return o?u_.createPortal(v.jsx(et.div,{...r,ref:e}),o):null});Im.displayName=BB;var IB=rx[" useInsertionEffect ".trim().toString()]||jn;function Ga({prop:t,defaultProp:e,onChange:n=()=>{},caller:r}){const[i,a,o]=qB({defaultProp:e,onChange:n}),c=t!==void 0,u=c?t:i;{const h=w.useRef(t!==void 0);w.useEffect(()=>{const m=h.current;m!==c&&console.warn(`${r} is changing from ${m?"controlled":"uncontrolled"} to ${c?"controlled":"uncontrolled"}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`),h.current=c},[c,r])}const f=w.useCallback(h=>{if(c){const m=UB(h)?h(t):h;m!==t&&o.current?.(m)}else a(h)},[c,t,a,o]);return[u,f]}function qB({defaultProp:t,onChange:e}){const[n,r]=w.useState(t),i=w.useRef(n),a=w.useRef(e);return IB(()=>{a.current=e},[e]),w.useEffect(()=>{i.current!==n&&(a.current?.(n),i.current=n)},[n,i]),[n,r,a]}function UB(t){return typeof t=="function"}function $x(t){const e=w.useRef({value:t,previous:t});return w.useMemo(()=>(e.current.value!==t&&(e.current.previous=e.current.value,e.current.value=t),e.current.previous),[t])}var L_=Object.freeze({position:"absolute",border:0,width:1,height:1,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",wordWrap:"normal"}),YB="VisuallyHidden",FB=w.forwardRef((t,e)=>v.jsx(et.span,{...t,ref:e,style:{...L_,...t.style}}));FB.displayName=YB;var WB=function(t){if(typeof document>"u")return null;var e=Array.isArray(t)?t[0]:t;return e.ownerDocument.body},Bl=new WeakMap,Ph=new WeakMap,jh={},iy=0,Z_=function(t){return t&&(t.host||Z_(t.parentNode))},GB=function(t,e){return e.map(function(n){if(t.contains(n))return n;var r=Z_(n);return r&&t.contains(r)?r:(console.error("aria-hidden",n,"in not contained inside",t,". Doing nothing"),null)}).filter(function(n){return!!n})},HB=function(t,e,n,r){var i=GB(e,Array.isArray(t)?t:[t]);jh[n]||(jh[n]=new WeakMap);var a=jh[n],o=[],c=new Set,u=new Set(i),f=function(m){!m||c.has(m)||(c.add(m),f(m.parentNode))};i.forEach(f);var h=function(m){!m||u.has(m)||Array.prototype.forEach.call(m.children,function(g){if(c.has(g))h(g);else try{var y=g.getAttribute(r),x=y!==null&&y!=="false",S=(Bl.get(g)||0)+1,k=(a.get(g)||0)+1;Bl.set(g,S),a.set(g,k),o.push(g),S===1&&x&&Ph.set(g,!0),k===1&&g.setAttribute(n,"true"),x||g.setAttribute(r,"true")}catch(T){console.error("aria-hidden: cannot operate on ",g,T)}})};return h(e),c.clear(),iy++,function(){o.forEach(function(m){var g=Bl.get(m)-1,y=a.get(m)-1;Bl.set(m,g),a.set(m,y),g||(Ph.has(m)||m.removeAttribute(r),Ph.delete(m)),y||m.removeAttribute(n)}),iy--,iy||(Bl=new WeakMap,Bl=new WeakMap,Ph=new WeakMap,jh={})}},Px=function(t,e,n){n===void 0&&(n="data-aria-hidden");var r=Array.from(Array.isArray(t)?t:[t]),i=WB(t);return i?(r.push.apply(r,Array.from(i.querySelectorAll("[aria-live], script"))),HB(r,i,n,"aria-hidden")):function(){return null}},ea=function(){return ea=Object.assign||function(e){for(var n,r=1,i=arguments.length;r<i;r++){n=arguments[r];for(var a in n)Object.prototype.hasOwnProperty.call(n,a)&&(e[a]=n[a])}return e},ea.apply(this,arguments)};function V_(t,e){var n={};for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&e.indexOf(r)<0&&(n[r]=t[r]);if(t!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,r=Object.getOwnPropertySymbols(t);i<r.length;i++)e.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(t,r[i])&&(n[r[i]]=t[r[i]]);return n}function Ko(t,e,n,r){function i(a){return a instanceof n?a:new n(function(o){o(a)})}return new(n||(n=Promise))(function(a,o){function c(h){try{f(r.next(h))}catch(m){o(m)}}function u(h){try{f(r.throw(h))}catch(m){o(m)}}function f(h){h.done?a(h.value):i(h.value).then(c,u)}f((r=r.apply(t,e||[])).next())})}function KB(t,e,n){if(n||arguments.length===2)for(var r=0,i=e.length,a;r<i;r++)(a||!(r in e))&&(a||(a=Array.prototype.slice.call(e,0,r)),a[r]=e[r]);return t.concat(a||Array.prototype.slice.call(e))}var pp="right-scroll-bar-position",mp="width-before-scroll-bar",JB="with-scroll-bars-hidden",e7="--removed-body-scroll-bar-size";function ay(t,e){return typeof t=="function"?t(e):t&&(t.current=e),t}function t7(t,e){var n=w.useState(function(){return{value:t,callback:e,facade:{get current(){return n.value},set current(r){var i=n.value;i!==r&&(n.value=r,n.callback(r,i))}}}})[0];return n.callback=e,n.facade}var n7=typeof window<"u"?w.useLayoutEffect:w.useEffect,s2=new WeakMap;function r7(t,e){var n=t7(null,function(r){return t.forEach(function(i){return ay(i,r)})});return n7(function(){var r=s2.get(n);if(r){var i=new Set(r),a=new Set(t),o=n.current;i.forEach(function(c){a.has(c)||ay(c,null)}),a.forEach(function(c){i.has(c)||ay(c,o)})}s2.set(n,t)},[t]),n}function i7(t){return t}function a7(t,e){e===void 0&&(e=i7);var n=[],r=!1,i={read:function(){if(r)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return n.length?n[n.length-1]:t},useMedium:function(a){var o=e(a,r);return n.push(o),function(){n=n.filter(function(c){return c!==o})}},assignSyncMedium:function(a){for(r=!0;n.length;){var o=n;n=[],o.forEach(a)}n={push:function(c){return a(c)},filter:function(){return n}}},assignMedium:function(a){r=!0;var o=[];if(n.length){var c=n;n=[],c.forEach(a),o=n}var u=function(){var h=o;o=[],h.forEach(a)},f=function(){return Promise.resolve().then(u)};f(),n={push:function(h){o.push(h),f()},filter:function(h){return o=o.filter(h),n}}}};return i}function s7(t){t===void 0&&(t={});var e=a7(null);return e.options=ea({async:!0,ssr:!1},t),e}var X_=function(t){var e=t.sideCar,n=V_(t,["sideCar"]);if(!e)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var r=e.read();if(!r)throw new Error("Sidecar medium not found");return w.createElement(r,ea({},n))};X_.isSideCarExport=!0;function o7(t,e){return t.useMedium(e),X_}var B_=s7(),sy=function(){},qm=w.forwardRef(function(t,e){var n=w.useRef(null),r=w.useState({onScrollCapture:sy,onWheelCapture:sy,onTouchMoveCapture:sy}),i=r[0],a=r[1],o=t.forwardProps,c=t.children,u=t.className,f=t.removeScrollBar,h=t.enabled,m=t.shards,g=t.sideCar,y=t.noRelative,x=t.noIsolation,S=t.inert,k=t.allowPinchZoom,T=t.as,C=T===void 0?"div":T,E=t.gapMode,R=V_(t,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noRelative","noIsolation","inert","allowPinchZoom","as","gapMode"]),$=g,P=r7([n,e]),_=ea(ea({},R),i);return w.createElement(w.Fragment,null,h&&w.createElement($,{sideCar:B_,removeScrollBar:f,shards:m,noRelative:y,noIsolation:x,inert:S,setCallbacks:a,allowPinchZoom:!!k,lockRef:n,gapMode:E}),o?w.cloneElement(w.Children.only(c),ea(ea({},_),{ref:P})):w.createElement(C,ea({},_,{className:u,ref:P}),c))});qm.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1};qm.classNames={fullWidth:mp,zeroRight:pp};var l7=function(){if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function c7(){if(!document)return null;var t=document.createElement("style");t.type="text/css";var e=l7();return e&&t.setAttribute("nonce",e),t}function u7(t,e){t.styleSheet?t.styleSheet.cssText=e:t.appendChild(document.createTextNode(e))}function d7(t){var e=document.head||document.getElementsByTagName("head")[0];e.appendChild(t)}var f7=function(){var t=0,e=null;return{add:function(n){t==0&&(e=c7())&&(u7(e,n),d7(e)),t++},remove:function(){t--,!t&&e&&(e.parentNode&&e.parentNode.removeChild(e),e=null)}}},h7=function(){var t=f7();return function(e,n){w.useEffect(function(){return t.add(e),function(){t.remove()}},[e&&n])}},I_=function(){var t=h7(),e=function(n){var r=n.styles,i=n.dynamic;return t(r,i),null};return e},p7={left:0,top:0,right:0,gap:0},oy=function(t){return parseInt(t||"",10)||0},m7=function(t){var e=window.getComputedStyle(document.body),n=e[t==="padding"?"paddingLeft":"marginLeft"],r=e[t==="padding"?"paddingTop":"marginTop"],i=e[t==="padding"?"paddingRight":"marginRight"];return[oy(n),oy(r),oy(i)]},g7=function(t){if(t===void 0&&(t="margin"),typeof window>"u")return p7;var e=m7(t),n=document.documentElement.clientWidth,r=window.innerWidth;return{left:e[0],top:e[1],right:e[2],gap:Math.max(0,r-n+e[2]-e[0])}},O7=I_(),ac="data-scroll-locked",v7=function(t,e,n,r){var i=t.left,a=t.top,o=t.right,c=t.gap;return n===void 0&&(n="margin"),`
|
|
30
|
-
.`.concat(JB,` {
|
|
31
|
-
overflow: hidden `).concat(r,`;
|
|
32
|
-
padding-right: `).concat(c,"px ").concat(r,`;
|
|
33
|
-
}
|
|
34
|
-
body[`).concat(ac,`] {
|
|
35
|
-
overflow: hidden `).concat(r,`;
|
|
36
|
-
overscroll-behavior: contain;
|
|
37
|
-
`).concat([e&&"position: relative ".concat(r,";"),n==="margin"&&`
|
|
38
|
-
padding-left: `.concat(i,`px;
|
|
39
|
-
padding-top: `).concat(a,`px;
|
|
40
|
-
padding-right: `).concat(o,`px;
|
|
41
|
-
margin-left:0;
|
|
42
|
-
margin-top:0;
|
|
43
|
-
margin-right: `).concat(c,"px ").concat(r,`;
|
|
44
|
-
`),n==="padding"&&"padding-right: ".concat(c,"px ").concat(r,";")].filter(Boolean).join(""),`
|
|
45
|
-
}
|
|
46
|
-
|
|
47
|
-
.`).concat(pp,` {
|
|
48
|
-
right: `).concat(c,"px ").concat(r,`;
|
|
49
|
-
}
|
|
50
|
-
|
|
51
|
-
.`).concat(mp,` {
|
|
52
|
-
margin-right: `).concat(c,"px ").concat(r,`;
|
|
53
|
-
}
|
|
54
|
-
|
|
55
|
-
.`).concat(pp," .").concat(pp,` {
|
|
56
|
-
right: 0 `).concat(r,`;
|
|
57
|
-
}
|
|
58
|
-
|
|
59
|
-
.`).concat(mp," .").concat(mp,` {
|
|
60
|
-
margin-right: 0 `).concat(r,`;
|
|
61
|
-
}
|
|
62
|
-
|
|
63
|
-
body[`).concat(ac,`] {
|
|
64
|
-
`).concat(e7,": ").concat(c,`px;
|
|
65
|
-
}
|
|
66
|
-
`)},o2=function(){var t=parseInt(document.body.getAttribute(ac)||"0",10);return isFinite(t)?t:0},y7=function(){w.useEffect(function(){return document.body.setAttribute(ac,(o2()+1).toString()),function(){var t=o2()-1;t<=0?document.body.removeAttribute(ac):document.body.setAttribute(ac,t.toString())}},[])},b7=function(t){var e=t.noRelative,n=t.noImportant,r=t.gapMode,i=r===void 0?"margin":r;y7();var a=w.useMemo(function(){return g7(i)},[i]);return w.createElement(O7,{styles:v7(a,!e,i,n?"":"!important")})},C0=!1;if(typeof window<"u")try{var Mh=Object.defineProperty({},"passive",{get:function(){return C0=!0,!0}});window.addEventListener("test",Mh,Mh),window.removeEventListener("test",Mh,Mh)}catch{C0=!1}var Il=C0?{passive:!1}:!1,x7=function(t){return t.tagName==="TEXTAREA"},q_=function(t,e){if(!(t instanceof Element))return!1;var n=window.getComputedStyle(t);return n[e]!=="hidden"&&!(n.overflowY===n.overflowX&&!x7(t)&&n[e]==="visible")},S7=function(t){return q_(t,"overflowY")},w7=function(t){return q_(t,"overflowX")},l2=function(t,e){var n=e.ownerDocument,r=e;do{typeof ShadowRoot<"u"&&r instanceof ShadowRoot&&(r=r.host);var i=U_(t,r);if(i){var a=Y_(t,r),o=a[1],c=a[2];if(o>c)return!0}r=r.parentNode}while(r&&r!==n.body);return!1},k7=function(t){var e=t.scrollTop,n=t.scrollHeight,r=t.clientHeight;return[e,n,r]},C7=function(t){var e=t.scrollLeft,n=t.scrollWidth,r=t.clientWidth;return[e,n,r]},U_=function(t,e){return t==="v"?S7(e):w7(e)},Y_=function(t,e){return t==="v"?k7(e):C7(e)},T7=function(t,e){return t==="h"&&e==="rtl"?-1:1},E7=function(t,e,n,r,i){var a=T7(t,window.getComputedStyle(e).direction),o=a*r,c=n.target,u=e.contains(c),f=!1,h=o>0,m=0,g=0;do{if(!c)break;var y=Y_(t,c),x=y[0],S=y[1],k=y[2],T=S-k-a*x;(x||T)&&U_(t,c)&&(m+=T,g+=x);var C=c.parentNode;c=C&&C.nodeType===Node.DOCUMENT_FRAGMENT_NODE?C.host:C}while(!u&&c!==document.body||u&&(e.contains(c)||e===c));return(h&&Math.abs(m)<1||!h&&Math.abs(g)<1)&&(f=!0),f},Nh=function(t){return"changedTouches"in t?[t.changedTouches[0].clientX,t.changedTouches[0].clientY]:[0,0]},c2=function(t){return[t.deltaX,t.deltaY]},u2=function(t){return t&&"current"in t?t.current:t},Q7=function(t,e){return t[0]===e[0]&&t[1]===e[1]},A7=function(t){return`
|
|
67
|
-
.block-interactivity-`.concat(t,` {pointer-events: none;}
|
|
68
|
-
.allow-interactivity-`).concat(t,` {pointer-events: all;}
|
|
69
|
-
`)},R7=0,ql=[];function _7(t){var e=w.useRef([]),n=w.useRef([0,0]),r=w.useRef(),i=w.useState(R7++)[0],a=w.useState(I_)[0],o=w.useRef(t);w.useEffect(function(){o.current=t},[t]),w.useEffect(function(){if(t.inert){document.body.classList.add("block-interactivity-".concat(i));var S=KB([t.lockRef.current],(t.shards||[]).map(u2),!0).filter(Boolean);return S.forEach(function(k){return k.classList.add("allow-interactivity-".concat(i))}),function(){document.body.classList.remove("block-interactivity-".concat(i)),S.forEach(function(k){return k.classList.remove("allow-interactivity-".concat(i))})}}},[t.inert,t.lockRef.current,t.shards]);var c=w.useCallback(function(S,k){if("touches"in S&&S.touches.length===2||S.type==="wheel"&&S.ctrlKey)return!o.current.allowPinchZoom;var T=Nh(S),C=n.current,E="deltaX"in S?S.deltaX:C[0]-T[0],R="deltaY"in S?S.deltaY:C[1]-T[1],$,P=S.target,_=Math.abs(E)>Math.abs(R)?"h":"v";if("touches"in S&&_==="h"&&P.type==="range")return!1;var M=window.getSelection(),V=M&&M.anchorNode,F=V?V===P||V.contains(P):!1;if(F)return!1;var W=l2(_,P);if(!W)return!0;if(W?$=_:($=_==="v"?"h":"v",W=l2(_,P)),!W)return!1;if(!r.current&&"changedTouches"in S&&(E||R)&&(r.current=$),!$)return!0;var I=r.current||$;return E7(I,k,S,I==="h"?E:R)},[]),u=w.useCallback(function(S){var k=S;if(!(!ql.length||ql[ql.length-1]!==a)){var T="deltaY"in k?c2(k):Nh(k),C=e.current.filter(function($){return $.name===k.type&&($.target===k.target||k.target===$.shadowParent)&&Q7($.delta,T)})[0];if(C&&C.should){k.cancelable&&k.preventDefault();return}if(!C){var E=(o.current.shards||[]).map(u2).filter(Boolean).filter(function($){return $.contains(k.target)}),R=E.length>0?c(k,E[0]):!o.current.noIsolation;R&&k.cancelable&&k.preventDefault()}}},[]),f=w.useCallback(function(S,k,T,C){var E={name:S,delta:k,target:T,should:C,shadowParent:$7(T)};e.current.push(E),setTimeout(function(){e.current=e.current.filter(function(R){return R!==E})},1)},[]),h=w.useCallback(function(S){n.current=Nh(S),r.current=void 0},[]),m=w.useCallback(function(S){f(S.type,c2(S),S.target,c(S,t.lockRef.current))},[]),g=w.useCallback(function(S){f(S.type,Nh(S),S.target,c(S,t.lockRef.current))},[]);w.useEffect(function(){return ql.push(a),t.setCallbacks({onScrollCapture:m,onWheelCapture:m,onTouchMoveCapture:g}),document.addEventListener("wheel",u,Il),document.addEventListener("touchmove",u,Il),document.addEventListener("touchstart",h,Il),function(){ql=ql.filter(function(S){return S!==a}),document.removeEventListener("wheel",u,Il),document.removeEventListener("touchmove",u,Il),document.removeEventListener("touchstart",h,Il)}},[]);var y=t.removeScrollBar,x=t.inert;return w.createElement(w.Fragment,null,x?w.createElement(a,{styles:A7(i)}):null,y?w.createElement(b7,{noRelative:t.noRelative,gapMode:t.gapMode}):null)}function $7(t){for(var e=null;t!==null;)t instanceof ShadowRoot&&(e=t.host,t=t.host),t=t.parentNode;return e}const P7=o7(B_,_7);var Um=w.forwardRef(function(t,e){return w.createElement(qm,ea({},t,{ref:e,sideCar:P7}))});Um.classNames=qm.classNames;var j7=[" ","Enter","ArrowUp","ArrowDown"],M7=[" ","Enter"],Vo="Select",[Ym,Fm,N7]=bx(Vo),[qc]=pa(Vo,[N7,Bm]),Wm=Bm(),[D7,Hs]=qc(Vo),[z7,L7]=qc(Vo),F_=t=>{const{__scopeSelect:e,children:n,open:r,defaultOpen:i,onOpenChange:a,value:o,defaultValue:c,onValueChange:u,dir:f,name:h,autoComplete:m,disabled:g,required:y,form:x}=t,S=Wm(e),[k,T]=w.useState(null),[C,E]=w.useState(null),[R,$]=w.useState(!1),P=Nm(f),[_,M]=Ga({prop:r,defaultProp:i??!1,onChange:a,caller:Vo}),[V,F]=Ga({prop:o,defaultProp:c,onChange:u,caller:Vo}),W=w.useRef(null),I=k?x||!!k.closest("form"):!0,[ne,ee]=w.useState(new Set),pe=Array.from(ne).map(D=>D.props.value).join(";");return v.jsx(N_,{...S,children:v.jsxs(D7,{required:y,scope:e,trigger:k,onTriggerChange:T,valueNode:C,onValueNodeChange:E,valueNodeHasChildren:R,onValueNodeHasChildrenChange:$,contentId:Ba(),value:V,onValueChange:F,open:_,onOpenChange:M,dir:P,triggerPointerDownPosRef:W,disabled:g,children:[v.jsx(Ym.Provider,{scope:e,children:v.jsx(z7,{scope:t.__scopeSelect,onNativeOptionAdd:w.useCallback(D=>{ee(G=>new Set(G).add(D))},[]),onNativeOptionRemove:w.useCallback(D=>{ee(G=>{const B=new Set(G);return B.delete(D),B})},[]),children:n})}),I?v.jsxs(g$,{"aria-hidden":!0,required:y,tabIndex:-1,name:h,autoComplete:m,value:V,onChange:D=>F(D.target.value),disabled:g,form:x,children:[V===void 0?v.jsx("option",{value:""}):null,Array.from(ne)]},pe):null]})})};F_.displayName=Vo;var W_="SelectTrigger",G_=w.forwardRef((t,e)=>{const{__scopeSelect:n,disabled:r=!1,...i}=t,a=Wm(n),o=Hs(W_,n),c=o.disabled||r,u=ft(e,o.onTriggerChange),f=Fm(n),h=w.useRef("touch"),[m,g,y]=v$(S=>{const k=f().filter(E=>!E.disabled),T=k.find(E=>E.value===o.value),C=y$(k,S,T);C!==void 0&&o.onValueChange(C.value)}),x=S=>{c||(o.onOpenChange(!0),y()),S&&(o.triggerPointerDownPosRef.current={x:Math.round(S.pageX),y:Math.round(S.pageY)})};return v.jsx(_x,{asChild:!0,...a,children:v.jsx(et.button,{type:"button",role:"combobox","aria-controls":o.contentId,"aria-expanded":o.open,"aria-required":o.required,"aria-autocomplete":"none",dir:o.dir,"data-state":o.open?"open":"closed",disabled:c,"data-disabled":c?"":void 0,"data-placeholder":O$(o.value)?"":void 0,...i,ref:u,onClick:He(i.onClick,S=>{S.currentTarget.focus(),h.current!=="mouse"&&x(S)}),onPointerDown:He(i.onPointerDown,S=>{h.current=S.pointerType;const k=S.target;k.hasPointerCapture(S.pointerId)&&k.releasePointerCapture(S.pointerId),S.button===0&&S.ctrlKey===!1&&S.pointerType==="mouse"&&(x(S),S.preventDefault())}),onKeyDown:He(i.onKeyDown,S=>{const k=m.current!=="";!(S.ctrlKey||S.altKey||S.metaKey)&&S.key.length===1&&g(S.key),!(k&&S.key===" ")&&j7.includes(S.key)&&(x(),S.preventDefault())})})})});G_.displayName=W_;var H_="SelectValue",K_=w.forwardRef((t,e)=>{const{__scopeSelect:n,className:r,style:i,children:a,placeholder:o="",...c}=t,u=Hs(H_,n),{onValueNodeHasChildrenChange:f}=u,h=a!==void 0,m=ft(e,u.onValueNodeChange);return jn(()=>{f(h)},[f,h]),v.jsx(et.span,{...c,ref:m,style:{pointerEvents:"none"},children:O$(u.value)?v.jsx(v.Fragment,{children:o}):a})});K_.displayName=H_;var Z7="SelectIcon",J_=w.forwardRef((t,e)=>{const{__scopeSelect:n,children:r,...i}=t;return v.jsx(et.span,{"aria-hidden":!0,...i,ref:e,children:r||"▼"})});J_.displayName=Z7;var V7="SelectPortal",e$=t=>v.jsx(Im,{asChild:!0,...t});e$.displayName=V7;var Xo="SelectContent",t$=w.forwardRef((t,e)=>{const n=Hs(Xo,t.__scopeSelect),[r,i]=w.useState();if(jn(()=>{i(new DocumentFragment)},[]),!n.open){const a=r;return a?tf.createPortal(v.jsx(n$,{scope:t.__scopeSelect,children:v.jsx(Ym.Slot,{scope:t.__scopeSelect,children:v.jsx("div",{children:t.children})})}),a):null}return v.jsx(r$,{...t,ref:e})});t$.displayName=Xo;var xi=10,[n$,Ks]=qc(Xo),X7="SelectContentImpl",B7=pc("SelectContent.RemoveScroll"),r$=w.forwardRef((t,e)=>{const{__scopeSelect:n,position:r="item-aligned",onCloseAutoFocus:i,onEscapeKeyDown:a,onPointerDownOutside:o,side:c,sideOffset:u,align:f,alignOffset:h,arrowPadding:m,collisionBoundary:g,collisionPadding:y,sticky:x,hideWhenDetached:S,avoidCollisions:k,...T}=t,C=Hs(Xo,n),[E,R]=w.useState(null),[$,P]=w.useState(null),_=ft(e,H=>R(H)),[M,V]=w.useState(null),[F,W]=w.useState(null),I=Fm(n),[ne,ee]=w.useState(!1),pe=w.useRef(!1);w.useEffect(()=>{if(E)return Px(E)},[E]),xx();const D=w.useCallback(H=>{const[ge,...xe]=I().map(Re=>Re.ref.current),[ke]=xe.slice(-1),Ce=document.activeElement;for(const Re of H)if(Re===Ce||(Re?.scrollIntoView({block:"nearest"}),Re===ge&&$&&($.scrollTop=0),Re===ke&&$&&($.scrollTop=$.scrollHeight),Re?.focus(),document.activeElement!==Ce))return},[I,$]),G=w.useCallback(()=>D([M,E]),[D,M,E]);w.useEffect(()=>{ne&&G()},[ne,G]);const{onOpenChange:B,triggerPointerDownPosRef:ye}=C;w.useEffect(()=>{if(E){let H={x:0,y:0};const ge=ke=>{H={x:Math.abs(Math.round(ke.pageX)-(ye.current?.x??0)),y:Math.abs(Math.round(ke.pageY)-(ye.current?.y??0))}},xe=ke=>{H.x<=10&&H.y<=10?ke.preventDefault():E.contains(ke.target)||B(!1),document.removeEventListener("pointermove",ge),ye.current=null};return ye.current!==null&&(document.addEventListener("pointermove",ge),document.addEventListener("pointerup",xe,{capture:!0,once:!0})),()=>{document.removeEventListener("pointermove",ge),document.removeEventListener("pointerup",xe,{capture:!0})}}},[E,B,ye]),w.useEffect(()=>{const H=()=>B(!1);return window.addEventListener("blur",H),window.addEventListener("resize",H),()=>{window.removeEventListener("blur",H),window.removeEventListener("resize",H)}},[B]);const[X,A]=v$(H=>{const ge=I().filter(Ce=>!Ce.disabled),xe=ge.find(Ce=>Ce.ref.current===document.activeElement),ke=y$(ge,H,xe);ke&&setTimeout(()=>ke.ref.current.focus())}),N=w.useCallback((H,ge,xe)=>{const ke=!pe.current&&!xe;(C.value!==void 0&&C.value===ge||ke)&&(V(H),ke&&(pe.current=!0))},[C.value]),L=w.useCallback(()=>E?.focus(),[E]),q=w.useCallback((H,ge,xe)=>{const ke=!pe.current&&!xe;(C.value!==void 0&&C.value===ge||ke)&&W(H)},[C.value]),se=r==="popper"?T0:i$,he=se===T0?{side:c,sideOffset:u,align:f,alignOffset:h,arrowPadding:m,collisionBoundary:g,collisionPadding:y,sticky:x,hideWhenDetached:S,avoidCollisions:k}:{};return v.jsx(n$,{scope:n,content:E,viewport:$,onViewportChange:P,itemRefCallback:N,selectedItem:M,onItemLeave:L,itemTextRefCallback:q,focusSelectedItem:G,selectedItemText:F,position:r,isPositioned:ne,searchRef:X,children:v.jsx(Um,{as:B7,allowPinchZoom:!0,children:v.jsx(zm,{asChild:!0,trapped:C.open,onMountAutoFocus:H=>{H.preventDefault()},onUnmountAutoFocus:He(i,H=>{C.trigger?.focus({preventScroll:!0}),H.preventDefault()}),children:v.jsx(Dm,{asChild:!0,disableOutsidePointerEvents:!0,onEscapeKeyDown:a,onPointerDownOutside:o,onFocusOutside:H=>H.preventDefault(),onDismiss:()=>C.onOpenChange(!1),children:v.jsx(se,{role:"listbox",id:C.contentId,"data-state":C.open?"open":"closed",dir:C.dir,onContextMenu:H=>H.preventDefault(),...T,...he,onPlaced:()=>ee(!0),ref:_,style:{display:"flex",flexDirection:"column",outline:"none",...T.style},onKeyDown:He(T.onKeyDown,H=>{const ge=H.ctrlKey||H.altKey||H.metaKey;if(H.key==="Tab"&&H.preventDefault(),!ge&&H.key.length===1&&A(H.key),["ArrowUp","ArrowDown","Home","End"].includes(H.key)){let ke=I().filter(Ce=>!Ce.disabled).map(Ce=>Ce.ref.current);if(["ArrowUp","End"].includes(H.key)&&(ke=ke.slice().reverse()),["ArrowUp","ArrowDown"].includes(H.key)){const Ce=H.target,Re=ke.indexOf(Ce);ke=ke.slice(Re+1)}setTimeout(()=>D(ke)),H.preventDefault()}})})})})})})});r$.displayName=X7;var I7="SelectItemAlignedPosition",i$=w.forwardRef((t,e)=>{const{__scopeSelect:n,onPlaced:r,...i}=t,a=Hs(Xo,n),o=Ks(Xo,n),[c,u]=w.useState(null),[f,h]=w.useState(null),m=ft(e,_=>h(_)),g=Fm(n),y=w.useRef(!1),x=w.useRef(!0),{viewport:S,selectedItem:k,selectedItemText:T,focusSelectedItem:C}=o,E=w.useCallback(()=>{if(a.trigger&&a.valueNode&&c&&f&&S&&k&&T){const _=a.trigger.getBoundingClientRect(),M=f.getBoundingClientRect(),V=a.valueNode.getBoundingClientRect(),F=T.getBoundingClientRect();if(a.dir!=="rtl"){const Ce=F.left-M.left,Re=V.left-Ce,We=_.left-Re,Pe=_.width+We,ht=Math.max(Pe,M.width),Ke=window.innerWidth-xi,tt=yd(Re,[xi,Math.max(xi,Ke-ht)]);c.style.minWidth=Pe+"px",c.style.left=tt+"px"}else{const Ce=M.right-F.right,Re=window.innerWidth-V.right-Ce,We=window.innerWidth-_.right-Re,Pe=_.width+We,ht=Math.max(Pe,M.width),Ke=window.innerWidth-xi,tt=yd(Re,[xi,Math.max(xi,Ke-ht)]);c.style.minWidth=Pe+"px",c.style.right=tt+"px"}const W=g(),I=window.innerHeight-xi*2,ne=S.scrollHeight,ee=window.getComputedStyle(f),pe=parseInt(ee.borderTopWidth,10),D=parseInt(ee.paddingTop,10),G=parseInt(ee.borderBottomWidth,10),B=parseInt(ee.paddingBottom,10),ye=pe+D+ne+B+G,X=Math.min(k.offsetHeight*5,ye),A=window.getComputedStyle(S),N=parseInt(A.paddingTop,10),L=parseInt(A.paddingBottom,10),q=_.top+_.height/2-xi,se=I-q,he=k.offsetHeight/2,H=k.offsetTop+he,ge=pe+D+H,xe=ye-ge;if(ge<=q){const Ce=W.length>0&&k===W[W.length-1].ref.current;c.style.bottom="0px";const Re=f.clientHeight-S.offsetTop-S.offsetHeight,We=Math.max(se,he+(Ce?L:0)+Re+G),Pe=ge+We;c.style.height=Pe+"px"}else{const Ce=W.length>0&&k===W[0].ref.current;c.style.top="0px";const We=Math.max(q,pe+S.offsetTop+(Ce?N:0)+he)+xe;c.style.height=We+"px",S.scrollTop=ge-q+S.offsetTop}c.style.margin=`${xi}px 0`,c.style.minHeight=X+"px",c.style.maxHeight=I+"px",r?.(),requestAnimationFrame(()=>y.current=!0)}},[g,a.trigger,a.valueNode,c,f,S,k,T,a.dir,r]);jn(()=>E(),[E]);const[R,$]=w.useState();jn(()=>{f&&$(window.getComputedStyle(f).zIndex)},[f]);const P=w.useCallback(_=>{_&&x.current===!0&&(E(),C?.(),x.current=!1)},[E,C]);return v.jsx(U7,{scope:n,contentWrapper:c,shouldExpandOnScrollRef:y,onScrollButtonChange:P,children:v.jsx("div",{ref:u,style:{display:"flex",flexDirection:"column",position:"fixed",zIndex:R},children:v.jsx(et.div,{...i,ref:m,style:{boxSizing:"border-box",maxHeight:"100%",...i.style}})})})});i$.displayName=I7;var q7="SelectPopperPosition",T0=w.forwardRef((t,e)=>{const{__scopeSelect:n,align:r="start",collisionPadding:i=xi,...a}=t,o=Wm(n);return v.jsx(D_,{...o,...a,ref:e,align:r,collisionPadding:i,style:{boxSizing:"border-box",...a.style,"--radix-select-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-select-content-available-width":"var(--radix-popper-available-width)","--radix-select-content-available-height":"var(--radix-popper-available-height)","--radix-select-trigger-width":"var(--radix-popper-anchor-width)","--radix-select-trigger-height":"var(--radix-popper-anchor-height)"}})});T0.displayName=q7;var[U7,jx]=qc(Xo,{}),E0="SelectViewport",a$=w.forwardRef((t,e)=>{const{__scopeSelect:n,nonce:r,...i}=t,a=Ks(E0,n),o=jx(E0,n),c=ft(e,a.onViewportChange),u=w.useRef(0);return v.jsxs(v.Fragment,{children:[v.jsx("style",{dangerouslySetInnerHTML:{__html:"[data-radix-select-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-select-viewport]::-webkit-scrollbar{display:none}"},nonce:r}),v.jsx(Ym.Slot,{scope:n,children:v.jsx(et.div,{"data-radix-select-viewport":"",role:"presentation",...i,ref:c,style:{position:"relative",flex:1,overflow:"hidden auto",...i.style},onScroll:He(i.onScroll,f=>{const h=f.currentTarget,{contentWrapper:m,shouldExpandOnScrollRef:g}=o;if(g?.current&&m){const y=Math.abs(u.current-h.scrollTop);if(y>0){const x=window.innerHeight-xi*2,S=parseFloat(m.style.minHeight),k=parseFloat(m.style.height),T=Math.max(S,k);if(T<x){const C=T+y,E=Math.min(x,C),R=C-E;m.style.height=E+"px",m.style.bottom==="0px"&&(h.scrollTop=R>0?R:0,m.style.justifyContent="flex-end")}}}u.current=h.scrollTop})})})]})});a$.displayName=E0;var s$="SelectGroup",[Y7,F7]=qc(s$),W7=w.forwardRef((t,e)=>{const{__scopeSelect:n,...r}=t,i=Ba();return v.jsx(Y7,{scope:n,id:i,children:v.jsx(et.div,{role:"group","aria-labelledby":i,...r,ref:e})})});W7.displayName=s$;var o$="SelectLabel",G7=w.forwardRef((t,e)=>{const{__scopeSelect:n,...r}=t,i=F7(o$,n);return v.jsx(et.div,{id:i.id,...r,ref:e})});G7.displayName=o$;var Vp="SelectItem",[H7,l$]=qc(Vp),c$=w.forwardRef((t,e)=>{const{__scopeSelect:n,value:r,disabled:i=!1,textValue:a,...o}=t,c=Hs(Vp,n),u=Ks(Vp,n),f=c.value===r,[h,m]=w.useState(a??""),[g,y]=w.useState(!1),x=ft(e,C=>u.itemRefCallback?.(C,r,i)),S=Ba(),k=w.useRef("touch"),T=()=>{i||(c.onValueChange(r),c.onOpenChange(!1))};if(r==="")throw new Error("A <Select.Item /> must have a value prop that is not an empty string. This is because the Select value can be set to an empty string to clear the selection and show the placeholder.");return v.jsx(H7,{scope:n,value:r,disabled:i,textId:S,isSelected:f,onItemTextChange:w.useCallback(C=>{m(E=>E||(C?.textContent??"").trim())},[]),children:v.jsx(Ym.ItemSlot,{scope:n,value:r,disabled:i,textValue:h,children:v.jsx(et.div,{role:"option","aria-labelledby":S,"data-highlighted":g?"":void 0,"aria-selected":f&&g,"data-state":f?"checked":"unchecked","aria-disabled":i||void 0,"data-disabled":i?"":void 0,tabIndex:i?void 0:-1,...o,ref:x,onFocus:He(o.onFocus,()=>y(!0)),onBlur:He(o.onBlur,()=>y(!1)),onClick:He(o.onClick,()=>{k.current!=="mouse"&&T()}),onPointerUp:He(o.onPointerUp,()=>{k.current==="mouse"&&T()}),onPointerDown:He(o.onPointerDown,C=>{k.current=C.pointerType}),onPointerMove:He(o.onPointerMove,C=>{k.current=C.pointerType,i?u.onItemLeave?.():k.current==="mouse"&&C.currentTarget.focus({preventScroll:!0})}),onPointerLeave:He(o.onPointerLeave,C=>{C.currentTarget===document.activeElement&&u.onItemLeave?.()}),onKeyDown:He(o.onKeyDown,C=>{u.searchRef?.current!==""&&C.key===" "||(M7.includes(C.key)&&T(),C.key===" "&&C.preventDefault())})})})})});c$.displayName=Vp;var ed="SelectItemText",u$=w.forwardRef((t,e)=>{const{__scopeSelect:n,className:r,style:i,...a}=t,o=Hs(ed,n),c=Ks(ed,n),u=l$(ed,n),f=L7(ed,n),[h,m]=w.useState(null),g=ft(e,T=>m(T),u.onItemTextChange,T=>c.itemTextRefCallback?.(T,u.value,u.disabled)),y=h?.textContent,x=w.useMemo(()=>v.jsx("option",{value:u.value,disabled:u.disabled,children:y},u.value),[u.disabled,u.value,y]),{onNativeOptionAdd:S,onNativeOptionRemove:k}=f;return jn(()=>(S(x),()=>k(x)),[S,k,x]),v.jsxs(v.Fragment,{children:[v.jsx(et.span,{id:u.textId,...a,ref:g}),u.isSelected&&o.valueNode&&!o.valueNodeHasChildren?tf.createPortal(a.children,o.valueNode):null]})});u$.displayName=ed;var d$="SelectItemIndicator",f$=w.forwardRef((t,e)=>{const{__scopeSelect:n,...r}=t;return l$(d$,n).isSelected?v.jsx(et.span,{"aria-hidden":!0,...r,ref:e}):null});f$.displayName=d$;var Q0="SelectScrollUpButton",h$=w.forwardRef((t,e)=>{const n=Ks(Q0,t.__scopeSelect),r=jx(Q0,t.__scopeSelect),[i,a]=w.useState(!1),o=ft(e,r.onScrollButtonChange);return jn(()=>{if(n.viewport&&n.isPositioned){let c=function(){const f=u.scrollTop>0;a(f)};const u=n.viewport;return c(),u.addEventListener("scroll",c),()=>u.removeEventListener("scroll",c)}},[n.viewport,n.isPositioned]),i?v.jsx(m$,{...t,ref:o,onAutoScroll:()=>{const{viewport:c,selectedItem:u}=n;c&&u&&(c.scrollTop=c.scrollTop-u.offsetHeight)}}):null});h$.displayName=Q0;var A0="SelectScrollDownButton",p$=w.forwardRef((t,e)=>{const n=Ks(A0,t.__scopeSelect),r=jx(A0,t.__scopeSelect),[i,a]=w.useState(!1),o=ft(e,r.onScrollButtonChange);return jn(()=>{if(n.viewport&&n.isPositioned){let c=function(){const f=u.scrollHeight-u.clientHeight,h=Math.ceil(u.scrollTop)<f;a(h)};const u=n.viewport;return c(),u.addEventListener("scroll",c),()=>u.removeEventListener("scroll",c)}},[n.viewport,n.isPositioned]),i?v.jsx(m$,{...t,ref:o,onAutoScroll:()=>{const{viewport:c,selectedItem:u}=n;c&&u&&(c.scrollTop=c.scrollTop+u.offsetHeight)}}):null});p$.displayName=A0;var m$=w.forwardRef((t,e)=>{const{__scopeSelect:n,onAutoScroll:r,...i}=t,a=Ks("SelectScrollButton",n),o=w.useRef(null),c=Fm(n),u=w.useCallback(()=>{o.current!==null&&(window.clearInterval(o.current),o.current=null)},[]);return w.useEffect(()=>()=>u(),[u]),jn(()=>{c().find(h=>h.ref.current===document.activeElement)?.ref.current?.scrollIntoView({block:"nearest"})},[c]),v.jsx(et.div,{"aria-hidden":!0,...i,ref:e,style:{flexShrink:0,...i.style},onPointerDown:He(i.onPointerDown,()=>{o.current===null&&(o.current=window.setInterval(r,50))}),onPointerMove:He(i.onPointerMove,()=>{a.onItemLeave?.(),o.current===null&&(o.current=window.setInterval(r,50))}),onPointerLeave:He(i.onPointerLeave,()=>{u()})})}),K7="SelectSeparator",J7=w.forwardRef((t,e)=>{const{__scopeSelect:n,...r}=t;return v.jsx(et.div,{"aria-hidden":!0,...r,ref:e})});J7.displayName=K7;var R0="SelectArrow",eI=w.forwardRef((t,e)=>{const{__scopeSelect:n,...r}=t,i=Wm(n),a=Hs(R0,n),o=Ks(R0,n);return a.open&&o.position==="popper"?v.jsx(z_,{...i,...r,ref:e}):null});eI.displayName=R0;var tI="SelectBubbleInput",g$=w.forwardRef(({__scopeSelect:t,value:e,...n},r)=>{const i=w.useRef(null),a=ft(r,i),o=$x(e);return w.useEffect(()=>{const c=i.current;if(!c)return;const u=window.HTMLSelectElement.prototype,h=Object.getOwnPropertyDescriptor(u,"value").set;if(o!==e&&h){const m=new Event("change",{bubbles:!0});h.call(c,e),c.dispatchEvent(m)}},[o,e]),v.jsx(et.select,{...n,style:{...L_,...n.style},ref:a,defaultValue:e})});g$.displayName=tI;function O$(t){return t===""||t===void 0}function v$(t){const e=kr(t),n=w.useRef(""),r=w.useRef(0),i=w.useCallback(o=>{const c=n.current+o;e(c),(function u(f){n.current=f,window.clearTimeout(r.current),f!==""&&(r.current=window.setTimeout(()=>u(""),1e3))})(c)},[e]),a=w.useCallback(()=>{n.current="",window.clearTimeout(r.current)},[]);return w.useEffect(()=>()=>window.clearTimeout(r.current),[]),[n,i,a]}function y$(t,e,n){const i=e.length>1&&Array.from(e).every(f=>f===e[0])?e[0]:e,a=n?t.indexOf(n):-1;let o=nI(t,Math.max(a,0));i.length===1&&(o=o.filter(f=>f!==n));const u=o.find(f=>f.textValue.toLowerCase().startsWith(i.toLowerCase()));return u!==n?u:void 0}function nI(t,e){return t.map((n,r)=>t[(e+r)%t.length])}var rI=F_,iI=G_,aI=K_,sI=J_,oI=e$,lI=t$,cI=a$,uI=c$,dI=u$,fI=f$,hI=h$,pI=p$;function b$({...t}){return v.jsx(rI,{"data-slot":"select",...t})}function x$({...t}){return v.jsx(aI,{"data-slot":"select-value",...t})}function S$({className:t,size:e="default",children:n,...r}){return v.jsxs(iI,{"data-slot":"select-trigger","data-size":e,className:Be("border-input data-[placeholder]:text-muted-foreground [&_svg:not([class*='text-'])]:text-muted-foreground focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive dark:bg-input/30 dark:hover:bg-input/50 flex w-fit items-center justify-between gap-2 rounded-md border bg-transparent px-3 py-2 text-sm whitespace-nowrap shadow-xs transition-[color,box-shadow] outline-none focus-visible:ring-[3px] disabled:cursor-not-allowed disabled:opacity-50 data-[size=default]:h-9 data-[size=sm]:h-8 *:data-[slot=select-value]:line-clamp-1 *:data-[slot=select-value]:flex *:data-[slot=select-value]:items-center *:data-[slot=select-value]:gap-2 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",t),...r,children:[n,v.jsx(sI,{asChild:!0,children:v.jsx(Jd,{className:"size-4 opacity-50"})})]})}function w$({className:t,children:e,position:n="item-aligned",align:r="center",...i}){return v.jsx(oI,{children:v.jsxs(lI,{"data-slot":"select-content",className:Be("bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 relative z-50 max-h-(--radix-select-content-available-height) min-w-[8rem] origin-(--radix-select-content-transform-origin) overflow-x-hidden overflow-y-auto rounded-md border shadow-md",n==="popper"&&"data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1",t),position:n,align:r,...i,children:[v.jsx(mI,{}),v.jsx(cI,{className:Be("p-1",n==="popper"&&"h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)] scroll-my-1"),children:e}),v.jsx(gI,{})]})})}function _0({className:t,children:e,...n}){return v.jsxs(uI,{"data-slot":"select-item",className:Be("focus:bg-accent focus:text-accent-foreground [&_svg:not([class*='text-'])]:text-muted-foreground relative flex w-full cursor-default items-center gap-2 rounded-sm py-1.5 pr-8 pl-2 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 *:[span]:last:flex *:[span]:last:items-center *:[span]:last:gap-2",t),...n,children:[v.jsx("span",{"data-slot":"select-item-indicator",className:"absolute right-2 flex size-3.5 items-center justify-center",children:v.jsx(fI,{children:v.jsx(rc,{className:"size-4"})})}),v.jsx(dI,{children:e})]})}function mI({className:t,...e}){return v.jsx(hI,{"data-slot":"select-scroll-up-button",className:Be("flex cursor-default items-center justify-center py-1",t),...e,children:v.jsx(zV,{className:"size-4"})})}function gI({className:t,...e}){return v.jsx(pI,{"data-slot":"select-scroll-down-button",className:Be("flex cursor-default items-center justify-center py-1",t),...e,children:v.jsx(Jd,{className:"size-4"})})}function OI(t,e){return w.useReducer((n,r)=>e[n][r]??n,t)}var fi=t=>{const{present:e,children:n}=t,r=vI(e),i=typeof n=="function"?n({present:r.isPresent}):w.Children.only(n),a=ft(r.ref,yI(i));return typeof n=="function"||r.isPresent?w.cloneElement(i,{ref:a}):null};fi.displayName="Presence";function vI(t){const[e,n]=w.useState(),r=w.useRef(null),i=w.useRef(t),a=w.useRef("none"),o=t?"mounted":"unmounted",[c,u]=OI(o,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return w.useEffect(()=>{const f=Dh(r.current);a.current=c==="mounted"?f:"none"},[c]),jn(()=>{const f=r.current,h=i.current;if(h!==t){const g=a.current,y=Dh(f);t?u("MOUNT"):y==="none"||f?.display==="none"?u("UNMOUNT"):u(h&&g!==y?"ANIMATION_OUT":"UNMOUNT"),i.current=t}},[t,u]),jn(()=>{if(e){let f;const h=e.ownerDocument.defaultView??window,m=y=>{const S=Dh(r.current).includes(CSS.escape(y.animationName));if(y.target===e&&S&&(u("ANIMATION_END"),!i.current)){const k=e.style.animationFillMode;e.style.animationFillMode="forwards",f=h.setTimeout(()=>{e.style.animationFillMode==="forwards"&&(e.style.animationFillMode=k)})}},g=y=>{y.target===e&&(a.current=Dh(r.current))};return e.addEventListener("animationstart",g),e.addEventListener("animationcancel",m),e.addEventListener("animationend",m),()=>{h.clearTimeout(f),e.removeEventListener("animationstart",g),e.removeEventListener("animationcancel",m),e.removeEventListener("animationend",m)}}else u("ANIMATION_END")},[e,u]),{isPresent:["mounted","unmountSuspended"].includes(c),ref:w.useCallback(f=>{r.current=f?getComputedStyle(f):null,n(f)},[])}}function Dh(t){return t?.animationName||"none"}function yI(t){let e=Object.getOwnPropertyDescriptor(t.props,"ref")?.get,n=e&&"isReactWarning"in e&&e.isReactWarning;return n?t.ref:(e=Object.getOwnPropertyDescriptor(t,"ref")?.get,n=e&&"isReactWarning"in e&&e.isReactWarning,n?t.props.ref:t.props.ref||t.ref)}var Gm="Dialog",[k$]=pa(Gm),[bI,ji]=k$(Gm),C$=t=>{const{__scopeDialog:e,children:n,open:r,defaultOpen:i,onOpenChange:a,modal:o=!0}=t,c=w.useRef(null),u=w.useRef(null),[f,h]=Ga({prop:r,defaultProp:i??!1,onChange:a,caller:Gm});return v.jsx(bI,{scope:e,triggerRef:c,contentRef:u,contentId:Ba(),titleId:Ba(),descriptionId:Ba(),open:f,onOpenChange:h,onOpenToggle:w.useCallback(()=>h(m=>!m),[h]),modal:o,children:n})};C$.displayName=Gm;var T$="DialogTrigger",xI=w.forwardRef((t,e)=>{const{__scopeDialog:n,...r}=t,i=ji(T$,n),a=ft(e,i.triggerRef);return v.jsx(et.button,{type:"button","aria-haspopup":"dialog","aria-expanded":i.open,"aria-controls":i.contentId,"data-state":Dx(i.open),...r,ref:a,onClick:He(t.onClick,i.onOpenToggle)})});xI.displayName=T$;var Mx="DialogPortal",[SI,E$]=k$(Mx,{forceMount:void 0}),Q$=t=>{const{__scopeDialog:e,forceMount:n,children:r,container:i}=t,a=ji(Mx,e);return v.jsx(SI,{scope:e,forceMount:n,children:w.Children.map(r,o=>v.jsx(fi,{present:n||a.open,children:v.jsx(Im,{asChild:!0,container:i,children:o})}))})};Q$.displayName=Mx;var Xp="DialogOverlay",A$=w.forwardRef((t,e)=>{const n=E$(Xp,t.__scopeDialog),{forceMount:r=n.forceMount,...i}=t,a=ji(Xp,t.__scopeDialog);return a.modal?v.jsx(fi,{present:r||a.open,children:v.jsx(kI,{...i,ref:e})}):null});A$.displayName=Xp;var wI=pc("DialogOverlay.RemoveScroll"),kI=w.forwardRef((t,e)=>{const{__scopeDialog:n,...r}=t,i=ji(Xp,n);return v.jsx(Um,{as:wI,allowPinchZoom:!0,shards:[i.contentRef],children:v.jsx(et.div,{"data-state":Dx(i.open),...r,ref:e,style:{pointerEvents:"auto",...r.style}})})}),Bo="DialogContent",R$=w.forwardRef((t,e)=>{const n=E$(Bo,t.__scopeDialog),{forceMount:r=n.forceMount,...i}=t,a=ji(Bo,t.__scopeDialog);return v.jsx(fi,{present:r||a.open,children:a.modal?v.jsx(CI,{...i,ref:e}):v.jsx(TI,{...i,ref:e})})});R$.displayName=Bo;var CI=w.forwardRef((t,e)=>{const n=ji(Bo,t.__scopeDialog),r=w.useRef(null),i=ft(e,n.contentRef,r);return w.useEffect(()=>{const a=r.current;if(a)return Px(a)},[]),v.jsx(_$,{...t,ref:i,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:He(t.onCloseAutoFocus,a=>{a.preventDefault(),n.triggerRef.current?.focus()}),onPointerDownOutside:He(t.onPointerDownOutside,a=>{const o=a.detail.originalEvent,c=o.button===0&&o.ctrlKey===!0;(o.button===2||c)&&a.preventDefault()}),onFocusOutside:He(t.onFocusOutside,a=>a.preventDefault())})}),TI=w.forwardRef((t,e)=>{const n=ji(Bo,t.__scopeDialog),r=w.useRef(!1),i=w.useRef(!1);return v.jsx(_$,{...t,ref:e,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:a=>{t.onCloseAutoFocus?.(a),a.defaultPrevented||(r.current||n.triggerRef.current?.focus(),a.preventDefault()),r.current=!1,i.current=!1},onInteractOutside:a=>{t.onInteractOutside?.(a),a.defaultPrevented||(r.current=!0,a.detail.originalEvent.type==="pointerdown"&&(i.current=!0));const o=a.target;n.triggerRef.current?.contains(o)&&a.preventDefault(),a.detail.originalEvent.type==="focusin"&&i.current&&a.preventDefault()}})}),_$=w.forwardRef((t,e)=>{const{__scopeDialog:n,trapFocus:r,onOpenAutoFocus:i,onCloseAutoFocus:a,...o}=t,c=ji(Bo,n),u=w.useRef(null),f=ft(e,u);return xx(),v.jsxs(v.Fragment,{children:[v.jsx(zm,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:i,onUnmountAutoFocus:a,children:v.jsx(Dm,{role:"dialog",id:c.contentId,"aria-describedby":c.descriptionId,"aria-labelledby":c.titleId,"data-state":Dx(c.open),...o,ref:f,onDismiss:()=>c.onOpenChange(!1)})}),v.jsxs(v.Fragment,{children:[v.jsx(EI,{titleId:c.titleId}),v.jsx(AI,{contentRef:u,descriptionId:c.descriptionId})]})]})}),Nx="DialogTitle",$$=w.forwardRef((t,e)=>{const{__scopeDialog:n,...r}=t,i=ji(Nx,n);return v.jsx(et.h2,{id:i.titleId,...r,ref:e})});$$.displayName=Nx;var P$="DialogDescription",j$=w.forwardRef((t,e)=>{const{__scopeDialog:n,...r}=t,i=ji(P$,n);return v.jsx(et.p,{id:i.descriptionId,...r,ref:e})});j$.displayName=P$;var M$="DialogClose",N$=w.forwardRef((t,e)=>{const{__scopeDialog:n,...r}=t,i=ji(M$,n);return v.jsx(et.button,{type:"button",...r,ref:e,onClick:He(t.onClick,()=>i.onOpenChange(!1))})});N$.displayName=M$;function Dx(t){return t?"open":"closed"}var D$="DialogTitleWarning",[Vae,z$]=K8(D$,{contentName:Bo,titleName:Nx,docsSlug:"dialog"}),EI=({titleId:t})=>{const e=z$(D$),n=`\`${e.contentName}\` requires a \`${e.titleName}\` for the component to be accessible for screen reader users.
|
|
70
|
-
|
|
71
|
-
If you want to hide the \`${e.titleName}\`, you can wrap it with our VisuallyHidden component.
|
|
72
|
-
|
|
73
|
-
For more information, see https://radix-ui.com/primitives/docs/components/${e.docsSlug}`;return w.useEffect(()=>{t&&(document.getElementById(t)||console.error(n))},[n,t]),null},QI="DialogDescriptionWarning",AI=({contentRef:t,descriptionId:e})=>{const r=`Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${z$(QI).contentName}}.`;return w.useEffect(()=>{const i=t.current?.getAttribute("aria-describedby");e&&i&&(document.getElementById(e)||console.warn(r))},[r,t,e]),null},L$=C$,Z$=Q$,V$=A$,X$=R$,B$=$$,I$=j$,q$=N$;function RI({...t}){return v.jsx(L$,{"data-slot":"sheet",...t})}function _I({...t}){return v.jsx(Z$,{"data-slot":"sheet-portal",...t})}function $I({className:t,...e}){return v.jsx(V$,{"data-slot":"sheet-overlay",className:Be("data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 fixed inset-0 z-50 bg-black/50",t),...e})}function PI({className:t,children:e,side:n="right",...r}){return v.jsxs(_I,{children:[v.jsx($I,{}),v.jsxs(X$,{"data-slot":"sheet-content",className:Be("bg-background data-[state=open]:animate-in data-[state=closed]:animate-out fixed z-50 flex flex-col gap-4 shadow-lg transition ease-in-out data-[state=closed]:duration-300 data-[state=open]:duration-500",n==="right"&&"data-[state=closed]:slide-out-to-right data-[state=open]:slide-in-from-right inset-y-0 right-0 h-full w-3/4 border-l sm:max-w-sm",n==="left"&&"data-[state=closed]:slide-out-to-left data-[state=open]:slide-in-from-left inset-y-0 left-0 h-full w-3/4 border-r sm:max-w-sm",n==="top"&&"data-[state=closed]:slide-out-to-top data-[state=open]:slide-in-from-top inset-x-0 top-0 h-auto border-b",n==="bottom"&&"data-[state=closed]:slide-out-to-bottom data-[state=open]:slide-in-from-bottom inset-x-0 bottom-0 h-auto border-t",t),...r,children:[e,v.jsxs(q$,{className:"ring-offset-background focus:ring-ring data-[state=open]:bg-secondary absolute top-4 right-4 rounded-xs opacity-70 transition-opacity hover:opacity-100 focus:ring-2 focus:ring-offset-2 focus:outline-hidden disabled:pointer-events-none",children:[v.jsx(c_,{className:"size-4"}),v.jsx("span",{className:"sr-only",children:"Close"})]})]})]})}function jI({className:t,...e}){return v.jsx("div",{"data-slot":"sheet-header",className:Be("flex flex-col gap-1.5 p-4",t),...e})}function MI({className:t,...e}){return v.jsx("div",{"data-slot":"sheet-footer",className:Be("mt-auto flex flex-col gap-2 p-4",t),...e})}function NI({className:t,...e}){return v.jsx(B$,{"data-slot":"sheet-title",className:Be("text-foreground font-semibold",t),...e})}function DI({className:t,...e}){return v.jsx(I$,{"data-slot":"sheet-description",className:Be("text-muted-foreground text-sm",t),...e})}function zx({...t}){return v.jsx(L$,{"data-slot":"dialog",...t})}function zI({...t}){return v.jsx(Z$,{"data-slot":"dialog-portal",...t})}function LI({className:t,...e}){return v.jsx(V$,{"data-slot":"dialog-overlay",className:Be("data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 fixed inset-0 z-50 bg-black/50",t),...e})}function Lx({className:t,children:e,showCloseButton:n=!0,...r}){return v.jsxs(zI,{"data-slot":"dialog-portal",children:[v.jsx(LI,{}),v.jsxs(X$,{"data-slot":"dialog-content",className:Be("bg-background data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 fixed top-[50%] left-[50%] z-50 grid w-full max-w-[calc(100%-2rem)] translate-x-[-50%] translate-y-[-50%] gap-4 rounded-lg border p-6 shadow-lg duration-200 outline-none sm:max-w-lg",t),...r,children:[e,n&&v.jsxs(q$,{"data-slot":"dialog-close",className:"ring-offset-background focus:ring-ring data-[state=open]:bg-accent data-[state=open]:text-muted-foreground absolute top-4 right-4 rounded-xs opacity-70 transition-opacity hover:opacity-100 focus:ring-2 focus:ring-offset-2 focus:outline-hidden disabled:pointer-events-none [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",children:[v.jsx(c_,{}),v.jsx("span",{className:"sr-only",children:"Close"})]})]})]})}function Zx({className:t,...e}){return v.jsx("div",{"data-slot":"dialog-header",className:Be("flex flex-col gap-2 text-center sm:text-left",t),...e})}function ZI({className:t,...e}){return v.jsx("div",{"data-slot":"dialog-footer",className:Be("flex flex-col-reverse gap-2 sm:flex-row sm:justify-end",t),...e})}function Vx({className:t,...e}){return v.jsx(B$,{"data-slot":"dialog-title",className:Be("text-lg leading-none font-semibold",t),...e})}function Xx({className:t,...e}){return v.jsx(I$,{"data-slot":"dialog-description",className:Be("text-muted-foreground text-sm",t),...e})}function VI({className:t,...e}){return v.jsx("div",{"data-slot":"empty",className:Be("flex min-w-0 flex-1 flex-col items-center justify-center gap-6 rounded-lg border-dashed p-6 text-center text-balance md:p-12",t),...e})}function XI({className:t,...e}){return v.jsx("div",{"data-slot":"empty-header",className:Be("flex max-w-sm flex-col items-center gap-2 text-center",t),...e})}const BI=Mm("flex shrink-0 items-center justify-center mb-2 [&_svg]:pointer-events-none [&_svg]:shrink-0",{variants:{variant:{default:"bg-transparent",icon:"bg-muted text-foreground flex size-10 shrink-0 items-center justify-center rounded-lg [&_svg:not([class*='size-'])]:size-6"}},defaultVariants:{variant:"default"}});function II({className:t,variant:e="default",...n}){return v.jsx("div",{"data-slot":"empty-icon","data-variant":e,className:Be(BI({variant:e,className:t})),...n})}function qI({className:t,...e}){return v.jsx("div",{"data-slot":"empty-title",className:Be("text-lg font-medium tracking-tight",t),...e})}function UI({className:t,...e}){return v.jsx("div",{"data-slot":"empty-description",className:Be("text-muted-foreground [&>a:hover]:text-primary text-sm/relaxed [&>a]:underline [&>a]:underline-offset-4",t),...e})}function YI({className:t,...e}){return v.jsx("div",{"data-slot":"empty-content",className:Be("flex w-full max-w-sm min-w-0 flex-col items-center gap-4 text-sm text-balance",t),...e})}const FI=Mm("inline-flex items-center justify-center rounded-full border px-2 py-0.5 text-xs font-medium w-fit whitespace-nowrap shrink-0 [&>svg]:size-3 gap-1 [&>svg]:pointer-events-none focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive transition-[color,box-shadow] overflow-hidden",{variants:{variant:{default:"border-transparent bg-primary text-primary-foreground [a&]:hover:bg-primary/90",secondary:"border-transparent bg-secondary text-secondary-foreground [a&]:hover:bg-secondary/90",destructive:"border-transparent bg-destructive text-white [a&]:hover:bg-destructive/90 focus-visible:ring-destructive/20 dark:focus-visible:ring-destructive/40 dark:bg-destructive/60",outline:"text-foreground [a&]:hover:bg-accent [a&]:hover:text-accent-foreground"}},defaultVariants:{variant:"default"}});function La({className:t,variant:e,asChild:n=!1,...r}){const i=n?VR:"span";return v.jsx(i,{"data-slot":"badge",className:Be(FI({variant:e}),t),...r})}function WI(){const t=Ho(),{data:e,isPending:n,error:r}=T6(),i=E6(),[a,o]=w.useState(""),[c,u]=w.useState("grid"),[f,h]=w.useState(null),[m,g]=w.useState(!1),y=e?.icons||[],x=w.useMemo(()=>{if(!a.trim())return y;const S=a.toLowerCase();return y.filter(k=>{const T=k.iconKey.toLowerCase().includes(S),C=k.icon.name.toLowerCase().includes(S),E=k.icon.tags.some(R=>R.toLowerCase().includes(S));return T||C||E})},[y,a]);return n?v.jsx("div",{className:"flex h-[calc(100vh-4rem)] items-center justify-center",children:v.jsx("div",{className:"text-muted-foreground",children:"Loading icons..."})}):r?v.jsx("div",{className:"flex h-[calc(100vh-4rem)] items-center justify-center",children:v.jsx("div",{className:"text-destructive",children:"Failed to load icons"})}):y.length===0?v.jsx("div",{className:"flex h-[calc(100vh-4rem)] w-full items-center justify-center p-6",children:v.jsxs(VI,{className:"max-w-md border border-dotted",children:[v.jsxs(XI,{children:[v.jsx(II,{variant:"icon",children:v.jsx("img",{src:"/icon.png",alt:"Iconoma Logo",className:"w-8 h-8"})}),v.jsx(qI,{children:"No icons yet"}),v.jsx(UI,{className:"whitespace-nowrap",children:"Create your first icon to get started with Iconoma Studio"})]}),v.jsx(YI,{children:v.jsxs(Rt,{onClick:()=>t("/icons/create"),size:"lg",children:[v.jsx(ef,{}),"Create Icon"]})})]})}):v.jsxs("div",{className:"flex h-[calc(100vh-4rem)] flex-col gap-6 p-6",children:[v.jsxs("div",{className:"flex items-center gap-4",children:[v.jsx("div",{className:"flex-1",children:v.jsx(Ci,{placeholder:"Search icons by name, key, or tags...",value:a,onChange:S=>o(S.target.value),className:"max-w-md"})}),v.jsxs(b$,{value:c,onValueChange:S=>u(S),children:[v.jsx(S$,{className:"w-[120px]",children:v.jsx(x$,{})}),v.jsxs(w$,{children:[v.jsx(_0,{value:"grid",children:v.jsxs("div",{className:"flex items-center gap-2",children:[v.jsx(KV,{className:"size-4"}),v.jsx("span",{children:"Grid"})]})}),v.jsx(_0,{value:"list",children:v.jsxs("div",{className:"flex items-center gap-2",children:[v.jsx(n8,{className:"size-4"}),v.jsx("span",{children:"List"})]})})]})]})]}),x.length===0?v.jsx("div",{className:"flex flex-1 items-center justify-center",children:v.jsx("div",{className:"text-center",children:v.jsx("p",{className:"text-muted-foreground",children:"No icons found matching your search"})})}):c==="grid"?v.jsx("div",{className:"grid grid-cols-8 gap-4 overflow-y-auto",children:x.map(S=>v.jsxs("button",{onClick:()=>h(S),className:"group flex flex-col items-center gap-3 p-4 rounded-xl border hover:bg-accent cursor-pointer transition-all",children:[v.jsx("div",{className:"flex items-center justify-center w-full aspect-square p-4",children:v.jsx(nc,{content:S.svgContent,className:"w-full h-full max-w-[64px] max-h-[64px]"})}),v.jsxs("div",{className:"flex flex-col items-center gap-2 w-full min-w-0",children:[v.jsx("p",{className:"text-sm font-medium truncate w-full text-center",children:S.icon.name}),S.icon.tags.length>0&&v.jsxs("div",{className:"flex flex-wrap gap-1 justify-center max-w-full",children:[S.icon.tags.slice(0,2).map(k=>v.jsx(La,{variant:"outline",className:"text-xs px-1.5 py-0",children:k},k)),S.icon.tags.length>2&&v.jsxs(La,{variant:"outline",className:"text-xs px-1.5 py-0",children:["+",S.icon.tags.length-2]})]})]})]},S.iconKey))}):v.jsx("div",{className:"flex flex-col gap-2 overflow-y-auto",children:x.map(S=>v.jsxs("button",{onClick:()=>h(S),className:"group flex items-center gap-4 p-4 rounded-lg border bg-gradient-to-r from-card to-card/50 hover:from-card/90 hover:to-card/40 transition-all hover:shadow-md cursor-pointer text-left",children:[v.jsx("div",{className:"flex items-center justify-center w-16 h-16 shrink-0",children:v.jsx(nc,{content:S.svgContent,className:"w-full h-full max-w-[48px] max-h-[48px]"})}),v.jsxs("div",{className:"flex-1 min-w-0",children:[v.jsxs("div",{className:"flex items-center gap-2 mb-1",children:[v.jsx("p",{className:"text-sm font-medium truncate",children:S.icon.name}),S.icon.tags.length>0&&v.jsxs("div",{className:"flex gap-1 flex-wrap",children:[S.icon.tags.slice(0,3).map(k=>v.jsx(La,{variant:"outline",className:"text-xs px-1.5 py-0",children:k},k)),S.icon.tags.length>3&&v.jsxs(La,{variant:"outline",className:"text-xs px-1.5 py-0",children:["+",S.icon.tags.length-3]})]})]}),v.jsx("pre",{className:"text-xs text-muted-foreground font-mono truncate max-w-full overflow-hidden",children:v.jsxs("code",{children:[S.svgContent.substring(0,100),"..."]})})]})]},S.iconKey))}),f&&v.jsx(RI,{open:!!f,onOpenChange:S=>!S&&h(null),children:v.jsxs(PI,{side:"right",className:"w-full sm:max-w-2xl overflow-y-auto",children:[v.jsxs(jI,{children:[v.jsx(NI,{children:f.icon.name}),v.jsx(DI,{children:f.icon.tags.length>0&&v.jsx("div",{className:"flex flex-wrap gap-1 mt-2",children:f.icon.tags.map(S=>v.jsx(La,{variant:"secondary",className:"text-xs",children:S},S))})})]}),v.jsxs("div",{className:"flex flex-col gap-6 mt-6 px-6",children:[v.jsx("div",{className:"flex items-center justify-center p-8 rounded-xl border bg-gradient-to-br from-card to-card/50",children:v.jsx(nc,{content:f.svgContent,className:"w-full h-full max-w-[200px] max-h-[200px]"})}),v.jsx(d_,{iconKey:f.iconKey,pascalName:f.pascalName,svgContent:f.svgContent,colorVariableKeys:f.icon.colorVariableKeys})]}),v.jsxs(MI,{className:"flex-col gap-2 sm:flex-row",children:[v.jsxs(Rt,{onClick:()=>g(!0),variant:"destructive",className:"w-full sm:w-auto",children:[v.jsx(l_,{}),"Delete"]}),v.jsxs(Rt,{onClick:()=>{h(null),t(`/icons/${f.iconKey}/edit`)},className:"w-full sm:w-auto",children:[v.jsx(O8,{}),"Edit Icon"]})]})]})}),v.jsx(zx,{open:m,onOpenChange:g,children:v.jsxs(Lx,{children:[v.jsxs(Zx,{children:[v.jsx(Vx,{children:"Delete Icon"}),v.jsxs(Xx,{children:['Are you sure you want to delete "',f?.icon.name,'"? This action cannot be undone and will remove the icon from all targets.']})]}),v.jsxs(ZI,{children:[v.jsx(Rt,{variant:"outline",onClick:()=>g(!1),disabled:i.isPending,children:"Cancel"}),v.jsx(Rt,{variant:"destructive",onClick:async()=>{if(f)try{await i.mutateAsync(f.iconKey),bn.success("Icon deleted successfully"),g(!1),h(null)}catch{bn.error("Failed to delete icon")}},disabled:i.isPending,children:i.isPending?"Deleting...":"Delete"})]})]})})]})}var Zt="colors",rr="sizes",Me="space",GI={gap:Me,gridGap:Me,columnGap:Me,gridColumnGap:Me,rowGap:Me,gridRowGap:Me,inset:Me,insetBlock:Me,insetBlockEnd:Me,insetBlockStart:Me,insetInline:Me,insetInlineEnd:Me,insetInlineStart:Me,margin:Me,marginTop:Me,marginRight:Me,marginBottom:Me,marginLeft:Me,marginBlock:Me,marginBlockEnd:Me,marginBlockStart:Me,marginInline:Me,marginInlineEnd:Me,marginInlineStart:Me,padding:Me,paddingTop:Me,paddingRight:Me,paddingBottom:Me,paddingLeft:Me,paddingBlock:Me,paddingBlockEnd:Me,paddingBlockStart:Me,paddingInline:Me,paddingInlineEnd:Me,paddingInlineStart:Me,top:Me,right:Me,bottom:Me,left:Me,scrollMargin:Me,scrollMarginTop:Me,scrollMarginRight:Me,scrollMarginBottom:Me,scrollMarginLeft:Me,scrollMarginX:Me,scrollMarginY:Me,scrollMarginBlock:Me,scrollMarginBlockEnd:Me,scrollMarginBlockStart:Me,scrollMarginInline:Me,scrollMarginInlineEnd:Me,scrollMarginInlineStart:Me,scrollPadding:Me,scrollPaddingTop:Me,scrollPaddingRight:Me,scrollPaddingBottom:Me,scrollPaddingLeft:Me,scrollPaddingX:Me,scrollPaddingY:Me,scrollPaddingBlock:Me,scrollPaddingBlockEnd:Me,scrollPaddingBlockStart:Me,scrollPaddingInline:Me,scrollPaddingInlineEnd:Me,scrollPaddingInlineStart:Me,fontSize:"fontSizes",background:Zt,backgroundColor:Zt,backgroundImage:Zt,borderImage:Zt,border:Zt,borderBlock:Zt,borderBlockEnd:Zt,borderBlockStart:Zt,borderBottom:Zt,borderBottomColor:Zt,borderColor:Zt,borderInline:Zt,borderInlineEnd:Zt,borderInlineStart:Zt,borderLeft:Zt,borderLeftColor:Zt,borderRight:Zt,borderRightColor:Zt,borderTop:Zt,borderTopColor:Zt,caretColor:Zt,color:Zt,columnRuleColor:Zt,fill:Zt,outline:Zt,outlineColor:Zt,stroke:Zt,textDecorationColor:Zt,fontFamily:"fonts",fontWeight:"fontWeights",lineHeight:"lineHeights",letterSpacing:"letterSpacings",blockSize:rr,minBlockSize:rr,maxBlockSize:rr,inlineSize:rr,minInlineSize:rr,maxInlineSize:rr,width:rr,minWidth:rr,maxWidth:rr,height:rr,minHeight:rr,maxHeight:rr,flexBasis:rr,gridTemplateColumns:rr,gridTemplateRows:rr,borderWidth:"borderWidths",borderTopWidth:"borderWidths",borderRightWidth:"borderWidths",borderBottomWidth:"borderWidths",borderLeftWidth:"borderWidths",borderStyle:"borderStyles",borderTopStyle:"borderStyles",borderRightStyle:"borderStyles",borderBottomStyle:"borderStyles",borderLeftStyle:"borderStyles",borderRadius:"radii",borderTopLeftRadius:"radii",borderTopRightRadius:"radii",borderBottomRightRadius:"radii",borderBottomLeftRadius:"radii",boxShadow:"shadows",textShadow:"shadows",transition:"transitions",zIndex:"zIndices"},HI=(t,e)=>typeof e=="function"?{"()":Function.prototype.toString.call(e)}:e,rf=()=>{const t=Object.create(null);return(e,n,...r)=>{const i=(a=>JSON.stringify(a,HI))(e);return i in t?t[i]:t[i]=n(e,...r)}},gp=Symbol.for("sxs.internal"),Bx=(t,e)=>Object.defineProperties(t,Object.getOwnPropertyDescriptors(e)),d2=t=>{for(const e in t)return!0;return!1},{hasOwnProperty:KI}=Object.prototype,$0=t=>t.includes("-")?t:t.replace(/[A-Z]/g,(e=>"-"+e.toLowerCase())),JI=/\s+(?![^()]*\))/,Ul=t=>e=>t(...typeof e=="string"?String(e).split(JI):[e]),f2={appearance:t=>({WebkitAppearance:t,appearance:t}),backfaceVisibility:t=>({WebkitBackfaceVisibility:t,backfaceVisibility:t}),backdropFilter:t=>({WebkitBackdropFilter:t,backdropFilter:t}),backgroundClip:t=>({WebkitBackgroundClip:t,backgroundClip:t}),boxDecorationBreak:t=>({WebkitBoxDecorationBreak:t,boxDecorationBreak:t}),clipPath:t=>({WebkitClipPath:t,clipPath:t}),content:t=>({content:t.includes('"')||t.includes("'")||/^([A-Za-z]+\([^]*|[^]*-quote|inherit|initial|none|normal|revert|unset)$/.test(t)?t:`"${t}"`}),hyphens:t=>({WebkitHyphens:t,hyphens:t}),maskImage:t=>({WebkitMaskImage:t,maskImage:t}),maskSize:t=>({WebkitMaskSize:t,maskSize:t}),tabSize:t=>({MozTabSize:t,tabSize:t}),textSizeAdjust:t=>({WebkitTextSizeAdjust:t,textSizeAdjust:t}),userSelect:t=>({WebkitUserSelect:t,userSelect:t}),marginBlock:Ul(((t,e)=>({marginBlockStart:t,marginBlockEnd:e||t}))),marginInline:Ul(((t,e)=>({marginInlineStart:t,marginInlineEnd:e||t}))),maxSize:Ul(((t,e)=>({maxBlockSize:t,maxInlineSize:e||t}))),minSize:Ul(((t,e)=>({minBlockSize:t,minInlineSize:e||t}))),paddingBlock:Ul(((t,e)=>({paddingBlockStart:t,paddingBlockEnd:e||t}))),paddingInline:Ul(((t,e)=>({paddingInlineStart:t,paddingInlineEnd:e||t})))},ly=/([\d.]+)([^]*)/,e9=(t,e)=>t.length?t.reduce(((n,r)=>(n.push(...e.map((i=>i.includes("&")?i.replace(/&/g,/[ +>|~]/.test(r)&&/&.*&/.test(i)?`:is(${r})`:r):r+" "+i))),n)),[]):e,t9=(t,e)=>t in n9&&typeof e=="string"?e.replace(/^((?:[^]*[^\w-])?)(fit-content|stretch)((?:[^\w-][^]*)?)$/,((n,r,i,a)=>r+(i==="stretch"?`-moz-available${a};${$0(t)}:${r}-webkit-fill-available`:`-moz-fit-content${a};${$0(t)}:${r}fit-content`)+a)):String(e),n9={blockSize:1,height:1,inlineSize:1,maxBlockSize:1,maxHeight:1,maxInlineSize:1,maxWidth:1,minBlockSize:1,minHeight:1,minInlineSize:1,minWidth:1,width:1},Ha=t=>t?t+"-":"",U$=(t,e,n)=>t.replace(/([+-])?((?:\d+(?:\.\d*)?|\.\d+)(?:[Ee][+-]?\d+)?)?(\$|--)([$\w-]+)/g,((r,i,a,o,c)=>o=="$"==!!a?r:(i||o=="--"?"calc(":"")+"var(--"+(o==="$"?Ha(e)+(c.includes("$")?"":Ha(n))+c.replace(/\$/g,"-"):c)+")"+(i||o=="--"?"*"+(i||"")+(a||"1")+")":""))),r9=/\s*,\s*(?![^()]*\))/,i9=Object.prototype.toString,Hl=(t,e,n,r,i)=>{let a,o,c;const u=(f,h,m)=>{let g,y;const x=S=>{for(g in S){const C=g.charCodeAt(0)===64,E=C&&Array.isArray(S[g])?S[g]:[S[g]];for(y of E){const R=/[A-Z]/.test(T=g)?T:T.replace(/-[^]/g,(P=>P[1].toUpperCase())),$=typeof y=="object"&&y&&y.toString===i9&&(!r.utils[R]||!h.length);if(R in r.utils&&!$){const P=r.utils[R];if(P!==o){o=P,x(P(y)),o=null;continue}}else if(R in f2){const P=f2[R];if(P!==c){c=P,x(P(y)),c=null;continue}}if(C&&(k=g.slice(1)in r.media?"@media "+r.media[g.slice(1)]:g,g=k.replace(/\(\s*([\w-]+)\s*(=|<|<=|>|>=)\s*([\w-]+)\s*(?:(<|<=|>|>=)\s*([\w-]+)\s*)?\)/g,((P,_,M,V,F,W)=>{const I=ly.test(_),ne=.0625*(I?-1:1),[ee,pe]=I?[V,_]:[_,V];return"("+(M[0]==="="?"":M[0]===">"===I?"max-":"min-")+ee+":"+(M[0]!=="="&&M.length===1?pe.replace(ly,((D,G,B)=>Number(G)+ne*(M===">"?1:-1)+B)):pe)+(F?") and ("+(F[0]===">"?"min-":"max-")+ee+":"+(F.length===1?W.replace(ly,((D,G,B)=>Number(G)+ne*(F===">"?-1:1)+B)):W):"")+")"}))),$){const P=C?m.concat(g):[...m],_=C?[...h]:e9(h,g.split(r9));a!==void 0&&i(h2(...a)),a=void 0,u(y,_,P)}else a===void 0&&(a=[[],h,m]),g=C||g.charCodeAt(0)!==36?g:`--${Ha(r.prefix)}${g.slice(1).replace(/\$/g,"-")}`,y=$?y:typeof y=="number"?y&&R in a9?String(y)+"px":String(y):U$(t9(R,y??""),r.prefix,r.themeMap[R]),a[0].push(`${C?`${g} `:`${$0(g)}:`}${y}`)}}var k,T};x(f),a!==void 0&&i(h2(...a)),a=void 0};u(t,e,n)},h2=(t,e,n)=>`${n.map((r=>`${r}{`)).join("")}${e.length?`${e.join(",")}{`:""}${t.join(";")}${e.length?"}":""}${Array(n.length?n.length+1:0).join("}")}`,a9={animationDelay:1,animationDuration:1,backgroundSize:1,blockSize:1,border:1,borderBlock:1,borderBlockEnd:1,borderBlockEndWidth:1,borderBlockStart:1,borderBlockStartWidth:1,borderBlockWidth:1,borderBottom:1,borderBottomLeftRadius:1,borderBottomRightRadius:1,borderBottomWidth:1,borderEndEndRadius:1,borderEndStartRadius:1,borderInlineEnd:1,borderInlineEndWidth:1,borderInlineStart:1,borderInlineStartWidth:1,borderInlineWidth:1,borderLeft:1,borderLeftWidth:1,borderRadius:1,borderRight:1,borderRightWidth:1,borderSpacing:1,borderStartEndRadius:1,borderStartStartRadius:1,borderTop:1,borderTopLeftRadius:1,borderTopRightRadius:1,borderTopWidth:1,borderWidth:1,bottom:1,columnGap:1,columnRule:1,columnRuleWidth:1,columnWidth:1,containIntrinsicSize:1,flexBasis:1,fontSize:1,gap:1,gridAutoColumns:1,gridAutoRows:1,gridTemplateColumns:1,gridTemplateRows:1,height:1,inlineSize:1,inset:1,insetBlock:1,insetBlockEnd:1,insetBlockStart:1,insetInline:1,insetInlineEnd:1,insetInlineStart:1,left:1,letterSpacing:1,margin:1,marginBlock:1,marginBlockEnd:1,marginBlockStart:1,marginBottom:1,marginInline:1,marginInlineEnd:1,marginInlineStart:1,marginLeft:1,marginRight:1,marginTop:1,maxBlockSize:1,maxHeight:1,maxInlineSize:1,maxWidth:1,minBlockSize:1,minHeight:1,minInlineSize:1,minWidth:1,offsetDistance:1,offsetRotate:1,outline:1,outlineOffset:1,outlineWidth:1,overflowClipMargin:1,padding:1,paddingBlock:1,paddingBlockEnd:1,paddingBlockStart:1,paddingBottom:1,paddingInline:1,paddingInlineEnd:1,paddingInlineStart:1,paddingLeft:1,paddingRight:1,paddingTop:1,perspective:1,right:1,rowGap:1,scrollMargin:1,scrollMarginBlock:1,scrollMarginBlockEnd:1,scrollMarginBlockStart:1,scrollMarginBottom:1,scrollMarginInline:1,scrollMarginInlineEnd:1,scrollMarginInlineStart:1,scrollMarginLeft:1,scrollMarginRight:1,scrollMarginTop:1,scrollPadding:1,scrollPaddingBlock:1,scrollPaddingBlockEnd:1,scrollPaddingBlockStart:1,scrollPaddingBottom:1,scrollPaddingInline:1,scrollPaddingInlineEnd:1,scrollPaddingInlineStart:1,scrollPaddingLeft:1,scrollPaddingRight:1,scrollPaddingTop:1,shapeMargin:1,textDecoration:1,textDecorationThickness:1,textIndent:1,textUnderlineOffset:1,top:1,transitionDelay:1,transitionDuration:1,verticalAlign:1,width:1,wordSpacing:1},p2=t=>String.fromCharCode(t+(t>25?39:97)),jo=t=>(e=>{let n,r="";for(n=Math.abs(e);n>52;n=n/52|0)r=p2(n%52)+r;return p2(n%52)+r})(((e,n)=>{let r=n.length;for(;r;)e=33*e^n.charCodeAt(--r);return e})(5381,JSON.stringify(t))>>>0),td=["themed","global","styled","onevar","resonevar","allvar","inline"],s9=t=>{if(t.href&&!t.href.startsWith(location.origin))return!1;try{return!!t.cssRules}catch{return!1}},o9=t=>{let e;const n=()=>{const{cssRules:i}=e.sheet;return[].map.call(i,((a,o)=>{const{cssText:c}=a;let u="";if(c.startsWith("--sxs"))return"";if(i[o-1]&&(u=i[o-1].cssText).startsWith("--sxs")){if(!a.cssRules.length)return"";for(const f in e.rules)if(e.rules[f].group===a)return`--sxs{--sxs:${[...e.rules[f].cache].join(" ")}}${c}`;return a.cssRules.length?`${u}${c}`:""}return c})).join("")},r=()=>{if(e){const{rules:c,sheet:u}=e;if(!u.deleteRule){for(;Object(Object(u.cssRules)[0]).type===3;)u.cssRules.splice(0,1);u.cssRules=[]}for(const f in c)delete c[f]}const i=Object(t).styleSheets||[];for(const c of i)if(s9(c)){for(let u=0,f=c.cssRules;f[u];++u){const h=Object(f[u]);if(h.type!==1)continue;const m=Object(f[u+1]);if(m.type!==4)continue;++u;const{cssText:g}=h;if(!g.startsWith("--sxs"))continue;const y=g.slice(14,-3).trim().split(/\s+/),x=td[y[0]];x&&(e||(e={sheet:c,reset:r,rules:{},toString:n}),e.rules[x]={group:m,index:u,cache:new Set(y)})}if(e)break}if(!e){const c=(u,f)=>({type:f,cssRules:[],insertRule(h,m){this.cssRules.splice(m,0,c(h,{import:3,undefined:1}[(h.toLowerCase().match(/^@([a-z]+)/)||[])[1]]||4))},get cssText(){return u==="@media{}"?`@media{${[].map.call(this.cssRules,(h=>h.cssText)).join("")}}`:u}});e={sheet:t?(t.head||t).appendChild(document.createElement("style")).sheet:c("","text/css"),rules:{},reset:r,toString:n}}const{sheet:a,rules:o}=e;for(let c=td.length-1;c>=0;--c){const u=td[c];if(!o[u]){const f=td[c+1],h=o[f]?o[f].index:a.cssRules.length;a.insertRule("@media{}",h),a.insertRule(`--sxs{--sxs:${c}}`,h),o[u]={group:a.cssRules[h+1],index:h,cache:new Set([c])}}l9(o[u])}};return r(),e},l9=t=>{const e=t.group;let n=e.cssRules.length;t.apply=r=>{try{e.insertRule(r,n),++n}catch{}}},Bu=Symbol(),c9=rf(),u9=(t,e)=>c9(t,(()=>(...n)=>{let r={type:null,composers:new Set};for(const i of n)if(i!=null)if(i[gp]){r.type==null&&(r.type=i[gp].type);for(const a of i[gp].composers)r.composers.add(a)}else i.constructor!==Object||i.$$typeof?r.type==null&&(r.type=i):r.composers.add(d9(i,t));return r.type==null&&(r.type="span"),r.composers.size||r.composers.add(["PJLV",{},[],[],{},[]]),f9(t,r,e)})),d9=({variants:t,compoundVariants:e,defaultVariants:n,...r},i)=>{const a=`${Ha(i.prefix)}c-${jo(r)}`,o=[],c=[],u=Object.create(null),f=[];for(const g in n)u[g]=String(n[g]);if(typeof t=="object"&&t)for(const g in t){h=u,m=g,KI.call(h,m)||(u[g]="undefined");const y=t[g];for(const x in y){const S={[g]:String(x)};String(x)==="undefined"&&f.push(g);const k=y[x],T=[S,k,!d2(k)];o.push(T)}}var h,m;if(typeof e=="object"&&e)for(const g of e){let{css:y,...x}=g;y=typeof y=="object"&&y||{};for(const k in x)x[k]=String(x[k]);const S=[x,y,!d2(y)];c.push(S)}return[a,r,o,c,u,f]},f9=(t,e,n)=>{const[r,i,a,o]=h9(e.composers),c=typeof e.type=="function"||e.type.$$typeof?(m=>{function g(){for(let y=0;y<g[Bu].length;y++){const[x,S]=g[Bu][y];m.rules[x].apply(S)}return g[Bu]=[],null}return g[Bu]=[],g.rules={},td.forEach((y=>g.rules[y]={apply:x=>g[Bu].push([y,x])})),g})(n):null,u=(c||n).rules,f=`.${r}${i.length>1?`:where(.${i.slice(1).join(".")})`:""}`,h=m=>{m=typeof m=="object"&&m||p9;const{css:g,...y}=m,x={};for(const T in a)if(delete y[T],T in m){let C=m[T];typeof C=="object"&&C?x[T]={"@initial":a[T],...C}:(C=String(C),x[T]=C!=="undefined"||o.has(T)?C:a[T])}else x[T]=a[T];const S=new Set([...i]);for(const[T,C,E,R]of e.composers){n.rules.styled.cache.has(T)||(n.rules.styled.cache.add(T),Hl(C,[`.${T}`],[],t,(_=>{u.styled.apply(_)})));const $=m2(E,x,t.media),P=m2(R,x,t.media,!0);for(const _ of $)if(_!==void 0)for(const[M,V,F]of _){const W=`${T}-${jo(V)}-${M}`;S.add(W);const I=(F?n.rules.resonevar:n.rules.onevar).cache,ne=F?u.resonevar:u.onevar;I.has(W)||(I.add(W),Hl(V,[`.${W}`],[],t,(ee=>{ne.apply(ee)})))}for(const _ of P)if(_!==void 0)for(const[M,V]of _){const F=`${T}-${jo(V)}-${M}`;S.add(F),n.rules.allvar.cache.has(F)||(n.rules.allvar.cache.add(F),Hl(V,[`.${F}`],[],t,(W=>{u.allvar.apply(W)})))}}if(typeof g=="object"&&g){const T=`${r}-i${jo(g)}-css`;S.add(T),n.rules.inline.cache.has(T)||(n.rules.inline.cache.add(T),Hl(g,[`.${T}`],[],t,(C=>{u.inline.apply(C)})))}for(const T of String(m.className||"").trim().split(/\s+/))T&&S.add(T);const k=y.className=[...S].join(" ");return{type:e.type,className:k,selector:f,props:y,toString:()=>k,deferredInjector:c}};return Bx(h,{className:r,selector:f,[gp]:e,toString:()=>(n.rules.styled.cache.has(r)||h(),r)})},h9=t=>{let e="";const n=[],r={},i=[];for(const[a,,,,o,c]of t){e===""&&(e=a),n.push(a),i.push(...c);for(const u in o){const f=o[u];(r[u]===void 0||f!=="undefined"||c.includes(f))&&(r[u]=f)}}return[e,n,r,new Set(i)]},m2=(t,e,n,r)=>{const i=[];e:for(let[a,o,c]of t){if(c)continue;let u,f=0,h=!1;for(u in a){const m=a[u];let g=e[u];if(g!==m){if(typeof g!="object"||!g)continue e;{let y,x,S=0;for(const k in g){if(m===String(g[k])){if(k!=="@initial"){const T=k.slice(1);(x=x||[]).push(T in n?n[T]:k.replace(/^@media ?/,"")),h=!0}f+=S,y=!0}++S}if(x&&x.length&&(o={["@media "+x.join(", ")]:o}),!y)continue e}}}(i[f]=i[f]||[]).push([r?"cv":`${u}-${a[u]}`,o,h])}return i},p9={},m9=rf(),g9=(t,e)=>m9(t,(()=>(...n)=>{const r=()=>{for(let i of n){i=typeof i=="object"&&i||{};let a=jo(i);if(!e.rules.global.cache.has(a)){if(e.rules.global.cache.add(a),"@import"in i){let o=[].indexOf.call(e.sheet.cssRules,e.rules.themed.group)-1;for(let c of[].concat(i["@import"]))c=c.includes('"')||c.includes("'")?c:`"${c}"`,e.sheet.insertRule(`@import ${c};`,o++);delete i["@import"]}Hl(i,[],[],t,(o=>{e.rules.global.apply(o)}))}}return""};return Bx(r,{toString:r})})),O9=rf(),v9=(t,e)=>O9(t,(()=>n=>{const r=`${Ha(t.prefix)}k-${jo(n)}`,i=()=>{if(!e.rules.global.cache.has(r)){e.rules.global.cache.add(r);const a=[];Hl(n,[],[],t,(c=>a.push(c)));const o=`@keyframes ${r}{${a.join("")}}`;e.rules.global.apply(o)}return r};return Bx(i,{get name(){return i()},toString:i})})),y9=class{constructor(t,e,n,r){this.token=t==null?"":String(t),this.value=e==null?"":String(e),this.scale=n==null?"":String(n),this.prefix=r==null?"":String(r)}get computedValue(){return"var("+this.variable+")"}get variable(){return"--"+Ha(this.prefix)+Ha(this.scale)+this.token}toString(){return this.computedValue}},b9=rf(),x9=(t,e)=>b9(t,(()=>(n,r)=>{r=typeof n=="object"&&n||Object(r);const i=`.${n=(n=typeof n=="string"?n:"")||`${Ha(t.prefix)}t-${jo(r)}`}`,a={},o=[];for(const u in r){a[u]={};for(const f in r[u]){const h=`--${Ha(t.prefix)}${u}-${f}`,m=U$(String(r[u][f]),t.prefix,u);a[u][f]=new y9(f,m,u,t.prefix),o.push(`${h}:${m}`)}}const c=()=>{if(o.length&&!e.rules.themed.cache.has(n)){e.rules.themed.cache.add(n);const u=`${r===t.theme?":root,":""}.${n}{${o.join(";")}}`;e.rules.themed.apply(u)}return n};return{...a,get className(){return c()},selector:i,toString:c}})),S9=rf(),w9=t=>{let e=!1;const n=S9(t,(r=>{e=!0;const i="prefix"in(r=typeof r=="object"&&r||{})?String(r.prefix):"",a=typeof r.media=="object"&&r.media||{},o=typeof r.root=="object"?r.root||null:globalThis.document||null,c=typeof r.theme=="object"&&r.theme||{},u={prefix:i,media:a,theme:c,themeMap:typeof r.themeMap=="object"&&r.themeMap||{...GI},utils:typeof r.utils=="object"&&r.utils||{}},f=o9(o),h={css:u9(u,f),globalCss:g9(u,f),keyframes:v9(u,f),createTheme:x9(u,f),reset(){f.reset(),h.theme.toString()},theme:{},sheet:f,config:u,prefix:i,getCssText:f.toString,toString:f.toString};return String(h.theme=h.createTheme(c)),h}));return e||n.reset(),n},g2=Object.prototype.hasOwnProperty;function O2(t,e,n){for(n of t.keys())if(od(n,e))return n}function od(t,e){var n,r,i;if(t===e)return!0;if(t&&e&&(n=t.constructor)===e.constructor){if(n===Date)return t.getTime()===e.getTime();if(n===RegExp)return t.toString()===e.toString();if(n===Array){if((r=t.length)===e.length)for(;r--&&od(t[r],e[r]););return r===-1}if(n===Set){if(t.size!==e.size)return!1;for(r of t)if(i=r,i&&typeof i=="object"&&(i=O2(e,i),!i)||!e.has(i))return!1;return!0}if(n===Map){if(t.size!==e.size)return!1;for(r of t)if(i=r[0],i&&typeof i=="object"&&(i=O2(e,i),!i)||!od(r[1],e.get(i)))return!1;return!0}if(n===ArrayBuffer)t=new Uint8Array(t),e=new Uint8Array(e);else if(n===DataView){if((r=t.byteLength)===e.byteLength)for(;r--&&t.getInt8(r)===e.getInt8(r););return r===-1}if(ArrayBuffer.isView(t)){if((r=t.byteLength)===e.byteLength)for(;r--&&t[r]===e[r];);return r===-1}if(!n||typeof t=="object"){r=0;for(n in t)if(g2.call(t,n)&&++r&&!g2.call(e,n)||!(n in e)||!od(t[n],e[n]))return!1;return Object.keys(e).length===r}}return t!==t&&e!==e}const k9="modulepreload",C9=function(t){return"/"+t},v2={},cy=function(e,n,r){let i=Promise.resolve();if(n&&n.length>0){let u=function(f){return Promise.all(f.map(h=>Promise.resolve(h).then(m=>({status:"fulfilled",value:m}),m=>({status:"rejected",reason:m}))))};document.getElementsByTagName("link");const o=document.querySelector("meta[property=csp-nonce]"),c=o?.nonce||o?.getAttribute("nonce");i=u(n.map(f=>{if(f=C9(f),f in v2)return;v2[f]=!0;const h=f.endsWith(".css"),m=h?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${f}"]${m}`))return;const g=document.createElement("link");if(g.rel=h?"stylesheet":k9,h||(g.as="script"),g.crossOrigin="",g.href=f,c&&g.setAttribute("nonce",c),document.head.appendChild(g),h)return new Promise((y,x)=>{g.addEventListener("load",y),g.addEventListener("error",()=>x(new Error(`Unable to preload CSS for ${f}`)))})}))}function a(o){const c=new Event("vite:preloadError",{cancelable:!0});if(c.payload=o,window.dispatchEvent(c),!c.defaultPrevented)throw o}return i.then(o=>{for(const c of o||[])c.status==="rejected"&&a(c.reason);return e().catch(a)})};var T9=/(%?)(%([sdjo]))/g;function E9(t,e){switch(e){case"s":return t;case"d":case"i":return Number(t);case"j":return JSON.stringify(t);case"o":{if(typeof t=="string")return t;const n=JSON.stringify(t);return n==="{}"||n==="[]"||/^\[object .+?\]$/.test(n)?t:n}}}function P0(t,...e){if(e.length===0)return t;let n=0,r=t.replace(T9,(i,a,o,c)=>{const u=e[n],f=E9(u,c);return a?i:(n++,f)});return n<e.length&&(r+=` ${e.slice(n).join(" ")}`),r=r.replace(/%{2,2}/g,"%"),r}var Q9=2;function A9(t){if(!t.stack)return;const e=t.stack.split(`
|
|
74
|
-
`);e.splice(1,Q9),t.stack=e.join(`
|
|
75
|
-
`)}var R9=class extends Error{constructor(t,...e){super(t),this.message=t,this.name="Invariant Violation",this.message=P0(t,...e),A9(this)}},Y$=(t,e,...n)=>{if(!t)throw new R9(e,...n)};Y$.as=(t,e,n,...r)=>{if(!e)throw t.prototype.name!=null?new t(P0(n,r)):t(P0(n,r))};var j0=function(t,e){return j0=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,r){n.__proto__=r}||function(n,r){for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&(n[i]=r[i])},j0(t,e)};function Xae(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");j0(t,e);function n(){this.constructor=t}t.prototype=e===null?Object.create(e):(n.prototype=e.prototype,new n)}var Kl=function(){return Kl=Object.assign||function(e){for(var n,r=1,i=arguments.length;r<i;r++){n=arguments[r];for(var a in n)Object.prototype.hasOwnProperty.call(n,a)&&(e[a]=n[a])}return e},Kl.apply(this,arguments)};function _9(t,e,n,r){function i(a){return a instanceof n?a:new n(function(o){o(a)})}return new(n||(n=Promise))(function(a,o){function c(h){try{f(r.next(h))}catch(m){o(m)}}function u(h){try{f(r.throw(h))}catch(m){o(m)}}function f(h){h.done?a(h.value):i(h.value).then(c,u)}f((r=r.apply(t,[])).next())})}function $9(t,e){var n={label:0,sent:function(){if(a[0]&1)throw a[1];return a[1]},trys:[],ops:[]},r,i,a,o;return o={next:c(0),throw:c(1),return:c(2)},typeof Symbol=="function"&&(o[Symbol.iterator]=function(){return this}),o;function c(f){return function(h){return u([f,h])}}function u(f){if(r)throw new TypeError("Generator is already executing.");for(;n;)try{if(r=1,i&&(a=f[0]&2?i.return:f[0]?i.throw||((a=i.return)&&a.call(i),0):i.next)&&!(a=a.call(i,f[1])).done)return a;switch(i=0,a&&(f=[f[0]&2,a.value]),f[0]){case 0:case 1:a=f;break;case 4:return n.label++,{value:f[1],done:!1};case 5:n.label++,i=f[1],f=[0];continue;case 7:f=n.ops.pop(),n.trys.pop();continue;default:if(a=n.trys,!(a=a.length>0&&a[a.length-1])&&(f[0]===6||f[0]===2)){n=0;continue}if(f[0]===3&&(!a||f[1]>a[0]&&f[1]<a[3])){n.label=f[1];break}if(f[0]===6&&n.label<a[1]){n.label=a[1],a=f;break}if(a&&n.label<a[2]){n.label=a[2],n.ops.push(f);break}a[2]&&n.ops.pop(),n.trys.pop();continue}f=e.call(t,n)}catch(h){f=[6,h],i=0}finally{r=a=0}if(f[0]&5)throw f[1];return{value:f[0]?f[1]:void 0,done:!0}}}function Bae(t,e,n){if(n||arguments.length===2)for(var r=0,i=e.length,a;r<i;r++)(a||!(r in e))&&(a||(a=Array.prototype.slice.call(e,0,r)),a[r]=e[r]);return t.concat(a||Array.prototype.slice.call(e))}var y2;(function(t){t[t.None=0]="None",t[t.Error=10]="Error",t[t.Warning=20]="Warning",t[t.Info=30]="Info",t[t.Debug=40]="Debug"})(y2||(y2={}));var P9=function(t){return"[sandpack-client]: ".concat(t)};function uy(t,e){return e===void 0&&(e="Value is nullish"),Y$(t!=null,P9(e)),t}var j9='"dependencies" was not specified - provide either a package.json or a "dependencies" value',b2='"entry" was not specified - provide either a package.json with the "main" field or an "entry" value';function M9(t,e,n){return t===void 0&&(t={}),e===void 0&&(e={}),n===void 0&&(n="/index.js"),JSON.stringify({name:"sandpack-project",main:n,dependencies:t,devDependencies:e},null,2)}function N9(t,e,n,r){var i,a,o=Io(t),c=o["/package.json"];if(!c)return uy(e,j9),uy(r,b2),o["/package.json"]={code:M9(e,n,r)},o;if(c){var u=JSON.parse(c.code);uy(!(!e&&!u.dependencies),b2),e&&(u.dependencies=Kl(Kl({},(i=u.dependencies)!==null&&i!==void 0?i:{}),e??{})),n&&(u.devDependencies=Kl(Kl({},(a=u.devDependencies)!==null&&a!==void 0?a:{}),n??{})),r&&(u.main=r),o["/package.json"]={code:JSON.stringify(u,null,2)}}return o}function D9(t){var e;if(t.title==="SyntaxError"){var n=t.title,r=t.path,i=t.message,a=t.line,o=t.column;return{title:n,path:r,message:i,line:a,column:o}}var c=z9((e=t.payload)===null||e===void 0?void 0:e.frames);if(!c)return{message:t.message};var u=Z9(c),f=L9(c),h=V9(c._originalFileName,t.message,f,u);return{message:h,title:t.title,path:c._originalFileName,line:c._originalLineNumber,column:c._originalColumnNumber}}function z9(t){if(t)return t.find(function(e){return!!e._originalFileName})}function L9(t){return t?" (".concat(t._originalLineNumber,":").concat(t._originalColumnNumber,")"):""}function Z9(t){var e=t._originalScriptCode[t._originalScriptCode.length-1],n=e.lineNumber.toString().length,r=2,i=3,a=r+n+i+t._originalColumnNumber;return t._originalScriptCode.reduce(function(o,c){var u=c.highlight?">":" ",f=c.lineNumber.toString().length===n?"".concat(c.lineNumber):" ".concat(c.lineNumber),h=c.highlight?`
|
|
76
|
-
`+" ".repeat(a)+"^":"";return o+`
|
|
77
|
-
`+u+" "+f+" | "+c.content+h},"")}function V9(t,e,n,r){return"".concat(t,": ").concat(e).concat(n,`
|
|
78
|
-
`).concat(r)}var Io=function(t){return typeof t=="string"?t.startsWith("/")?t:"/".concat(t):Array.isArray(t)?t.map(function(e){return e.startsWith("/")?e:"/".concat(e)}):typeof t=="object"&&t!==null?Object.entries(t).reduce(function(e,n){var r=n[0],i=n[1],a=r.startsWith("/")?r:"/".concat(r);return e[a]=i,e},{}):null};function X9(t,e,n){var r;return n===void 0&&(n={}),_9(this,void 0,void 0,function(){var i,a,o;return $9(this,function(c){switch(c.label){case 0:switch(i=(r=e.template)!==null&&r!==void 0?r:"parcel",o=i,o){case"node":return[3,1];case"static":return[3,3]}return[3,5];case 1:return[4,cy(()=>import("./index-D98HewIt.js"),__vite__mapDeps([0,1,2])).then(function(u){return u.SandpackNode})];case 2:return a=c.sent(),[3,7];case 3:return[4,cy(()=>import("./index-599aeaf7-CQg58cdW.js"),__vite__mapDeps([3,2,1])).then(function(u){return u.SandpackStatic})];case 4:return a=c.sent(),[3,7];case 5:return[4,cy(()=>import("./index-CbKTZMip.js"),__vite__mapDeps([4,1])).then(function(u){return u.SandpackRuntime})];case 6:a=c.sent(),c.label=7;case 7:return[2,new a(t,e,n)]}})})}let M0=[],F$=[];(()=>{let t="lc,34,7n,7,7b,19,,,,2,,2,,,20,b,1c,l,g,,2t,7,2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,,w,a,14,6,2,4,8,,9,6,2,3,1a,d,,2,ba,7,,6,,,2a,m,2,7,,2,,2,3e,6,3,,,2,,7,,,20,2,3,,,,9n,2,f0b,5,1n,7,t4,,1r,4,29,,f5k,2,43q,,,3,4,5,8,8,2,7,u,4,44,3,1iz,1j,4,1e,8,,e,,m,5,,f,11s,7,,h,2,7,,2,,5,79,7,c5,4,15s,7,31,7,240,5,gx7k,2o,3k,6o".split(",").map(e=>e?parseInt(e,36):1);for(let e=0,n=0;e<t.length;e++)(e%2?F$:M0).push(n=n+t[e])})();function B9(t){if(t<768)return!1;for(let e=0,n=M0.length;;){let r=e+n>>1;if(t<M0[r])n=r;else if(t>=F$[r])e=r+1;else return!0;if(e==n)return!1}}function x2(t){return t>=127462&&t<=127487}const S2=8205;function I9(t,e,n=!0,r=!0){return(n?W$:q9)(t,e,r)}function W$(t,e,n){if(e==t.length)return e;e&&G$(t.charCodeAt(e))&&H$(t.charCodeAt(e-1))&&e--;let r=dy(t,e);for(e+=w2(r);e<t.length;){let i=dy(t,e);if(r==S2||i==S2||n&&B9(i))e+=w2(i),r=i;else if(x2(i)){let a=0,o=e-2;for(;o>=0&&x2(dy(t,o));)a++,o-=2;if(a%2==0)break;e+=2}else break}return e}function q9(t,e,n){for(;e>0;){let r=W$(t,e-2,n);if(r<e)return r;e--}return 0}function dy(t,e){let n=t.charCodeAt(e);if(!H$(n)||e+1==t.length)return n;let r=t.charCodeAt(e+1);return G$(r)?(n-55296<<10)+(r-56320)+65536:n}function G$(t){return t>=56320&&t<57344}function H$(t){return t>=55296&&t<56320}function w2(t){return t<65536?1:2}class St{lineAt(e){if(e<0||e>this.length)throw new RangeError(`Invalid position ${e} in document of length ${this.length}`);return this.lineInner(e,!1,1,0)}line(e){if(e<1||e>this.lines)throw new RangeError(`Invalid line number ${e} in ${this.lines}-line document`);return this.lineInner(e,!0,1,0)}replace(e,n,r){[e,n]=gc(this,e,n);let i=[];return this.decompose(0,e,i,2),r.length&&r.decompose(0,r.length,i,3),this.decompose(n,this.length,i,1),ta.from(i,this.length-(n-e)+r.length)}append(e){return this.replace(this.length,this.length,e)}slice(e,n=this.length){[e,n]=gc(this,e,n);let r=[];return this.decompose(e,n,r,0),ta.from(r,n-e)}eq(e){if(e==this)return!0;if(e.length!=this.length||e.lines!=this.lines)return!1;let n=this.scanIdentical(e,1),r=this.length-this.scanIdentical(e,-1),i=new ld(this),a=new ld(e);for(let o=n,c=n;;){if(i.next(o),a.next(o),o=0,i.lineBreak!=a.lineBreak||i.done!=a.done||i.value!=a.value)return!1;if(c+=i.value.length,i.done||c>=r)return!0}}iter(e=1){return new ld(this,e)}iterRange(e,n=this.length){return new K$(this,e,n)}iterLines(e,n){let r;if(e==null)r=this.iter();else{n==null&&(n=this.lines+1);let i=this.line(e).from;r=this.iterRange(i,Math.max(i,n==this.lines+1?this.length:n<=1?0:this.line(n-1).to))}return new J$(r)}toString(){return this.sliceString(0)}toJSON(){let e=[];return this.flatten(e),e}constructor(){}static of(e){if(e.length==0)throw new RangeError("A document must have at least one line");return e.length==1&&!e[0]?St.empty:e.length<=32?new un(e):ta.from(un.split(e,[]))}}class un extends St{constructor(e,n=U9(e)){super(),this.text=e,this.length=n}get lines(){return this.text.length}get children(){return null}lineInner(e,n,r,i){for(let a=0;;a++){let o=this.text[a],c=i+o.length;if((n?r:c)>=e)return new Y9(i,c,r,o);i=c+1,r++}}decompose(e,n,r,i){let a=e<=0&&n>=this.length?this:new un(k2(this.text,e,n),Math.min(n,this.length)-Math.max(0,e));if(i&1){let o=r.pop(),c=Op(a.text,o.text.slice(),0,a.length);if(c.length<=32)r.push(new un(c,o.length+a.length));else{let u=c.length>>1;r.push(new un(c.slice(0,u)),new un(c.slice(u)))}}else r.push(a)}replace(e,n,r){if(!(r instanceof un))return super.replace(e,n,r);[e,n]=gc(this,e,n);let i=Op(this.text,Op(r.text,k2(this.text,0,e)),n),a=this.length+r.length-(n-e);return i.length<=32?new un(i,a):ta.from(un.split(i,[]),a)}sliceString(e,n=this.length,r=`
|
|
79
|
-
`){[e,n]=gc(this,e,n);let i="";for(let a=0,o=0;a<=n&&o<this.text.length;o++){let c=this.text[o],u=a+c.length;a>e&&o&&(i+=r),e<u&&n>a&&(i+=c.slice(Math.max(0,e-a),n-a)),a=u+1}return i}flatten(e){for(let n of this.text)e.push(n)}scanIdentical(){return 0}static split(e,n){let r=[],i=-1;for(let a of e)r.push(a),i+=a.length+1,r.length==32&&(n.push(new un(r,i)),r=[],i=-1);return i>-1&&n.push(new un(r,i)),n}}class ta extends St{constructor(e,n){super(),this.children=e,this.length=n,this.lines=0;for(let r of e)this.lines+=r.lines}lineInner(e,n,r,i){for(let a=0;;a++){let o=this.children[a],c=i+o.length,u=r+o.lines-1;if((n?u:c)>=e)return o.lineInner(e,n,r,i);i=c+1,r=u+1}}decompose(e,n,r,i){for(let a=0,o=0;o<=n&&a<this.children.length;a++){let c=this.children[a],u=o+c.length;if(e<=u&&n>=o){let f=i&((o<=e?1:0)|(u>=n?2:0));o>=e&&u<=n&&!f?r.push(c):c.decompose(e-o,n-o,r,f)}o=u+1}}replace(e,n,r){if([e,n]=gc(this,e,n),r.lines<this.lines)for(let i=0,a=0;i<this.children.length;i++){let o=this.children[i],c=a+o.length;if(e>=a&&n<=c){let u=o.replace(e-a,n-a,r),f=this.lines-o.lines+u.lines;if(u.lines<f>>4&&u.lines>f>>6){let h=this.children.slice();return h[i]=u,new ta(h,this.length-(n-e)+r.length)}return super.replace(a,c,u)}a=c+1}return super.replace(e,n,r)}sliceString(e,n=this.length,r=`
|
|
80
|
-
`){[e,n]=gc(this,e,n);let i="";for(let a=0,o=0;a<this.children.length&&o<=n;a++){let c=this.children[a],u=o+c.length;o>e&&a&&(i+=r),e<u&&n>o&&(i+=c.sliceString(e-o,n-o,r)),o=u+1}return i}flatten(e){for(let n of this.children)n.flatten(e)}scanIdentical(e,n){if(!(e instanceof ta))return 0;let r=0,[i,a,o,c]=n>0?[0,0,this.children.length,e.children.length]:[this.children.length-1,e.children.length-1,-1,-1];for(;;i+=n,a+=n){if(i==o||a==c)return r;let u=this.children[i],f=e.children[a];if(u!=f)return r+u.scanIdentical(f,n);r+=u.length+1}}static from(e,n=e.reduce((r,i)=>r+i.length+1,-1)){let r=0;for(let y of e)r+=y.lines;if(r<32){let y=[];for(let x of e)x.flatten(y);return new un(y,n)}let i=Math.max(32,r>>5),a=i<<1,o=i>>1,c=[],u=0,f=-1,h=[];function m(y){let x;if(y.lines>a&&y instanceof ta)for(let S of y.children)m(S);else y.lines>o&&(u>o||!u)?(g(),c.push(y)):y instanceof un&&u&&(x=h[h.length-1])instanceof un&&y.lines+x.lines<=32?(u+=y.lines,f+=y.length+1,h[h.length-1]=new un(x.text.concat(y.text),x.length+1+y.length)):(u+y.lines>i&&g(),u+=y.lines,f+=y.length+1,h.push(y))}function g(){u!=0&&(c.push(h.length==1?h[0]:ta.from(h,f)),f=-1,u=h.length=0)}for(let y of e)m(y);return g(),c.length==1?c[0]:new ta(c,n)}}St.empty=new un([""],0);function U9(t){let e=-1;for(let n of t)e+=n.length+1;return e}function Op(t,e,n=0,r=1e9){for(let i=0,a=0,o=!0;a<t.length&&i<=r;a++){let c=t[a],u=i+c.length;u>=n&&(u>r&&(c=c.slice(0,r-i)),i<n&&(c=c.slice(n-i)),o?(e[e.length-1]+=c,o=!1):e.push(c)),i=u+1}return e}function k2(t,e,n){return Op(t,[""],e,n)}class ld{constructor(e,n=1){this.dir=n,this.done=!1,this.lineBreak=!1,this.value="",this.nodes=[e],this.offsets=[n>0?1:(e instanceof un?e.text.length:e.children.length)<<1]}nextInner(e,n){for(this.done=this.lineBreak=!1;;){let r=this.nodes.length-1,i=this.nodes[r],a=this.offsets[r],o=a>>1,c=i instanceof un?i.text.length:i.children.length;if(o==(n>0?c:0)){if(r==0)return this.done=!0,this.value="",this;n>0&&this.offsets[r-1]++,this.nodes.pop(),this.offsets.pop()}else if((a&1)==(n>0?0:1)){if(this.offsets[r]+=n,e==0)return this.lineBreak=!0,this.value=`
|
|
81
|
-
`,this;e--}else if(i instanceof un){let u=i.text[o+(n<0?-1:0)];if(this.offsets[r]+=n,u.length>Math.max(0,e))return this.value=e==0?u:n>0?u.slice(e):u.slice(0,u.length-e),this;e-=u.length}else{let u=i.children[o+(n<0?-1:0)];e>u.length?(e-=u.length,this.offsets[r]+=n):(n<0&&this.offsets[r]--,this.nodes.push(u),this.offsets.push(n>0?1:(u instanceof un?u.text.length:u.children.length)<<1))}}}next(e=0){return e<0&&(this.nextInner(-e,-this.dir),e=this.value.length),this.nextInner(e,this.dir)}}class K${constructor(e,n,r){this.value="",this.done=!1,this.cursor=new ld(e,n>r?-1:1),this.pos=n>r?e.length:0,this.from=Math.min(n,r),this.to=Math.max(n,r)}nextInner(e,n){if(n<0?this.pos<=this.from:this.pos>=this.to)return this.value="",this.done=!0,this;e+=Math.max(0,n<0?this.pos-this.to:this.from-this.pos);let r=n<0?this.pos-this.from:this.to-this.pos;e>r&&(e=r),r-=e;let{value:i}=this.cursor.next(e);return this.pos+=(i.length+e)*n,this.value=i.length<=r?i:n<0?i.slice(i.length-r):i.slice(0,r),this.done=!this.value,this}next(e=0){return e<0?e=Math.max(e,this.from-this.pos):e>0&&(e=Math.min(e,this.to-this.pos)),this.nextInner(e,this.cursor.dir)}get lineBreak(){return this.cursor.lineBreak&&this.value!=""}}class J${constructor(e){this.inner=e,this.afterBreak=!0,this.value="",this.done=!1}next(e=0){let{done:n,lineBreak:r,value:i}=this.inner.next(e);return n&&this.afterBreak?(this.value="",this.afterBreak=!1):n?(this.done=!0,this.value=""):r?this.afterBreak?this.value="":(this.afterBreak=!0,this.next()):(this.value=i,this.afterBreak=!1),this}get lineBreak(){return!1}}typeof Symbol<"u"&&(St.prototype[Symbol.iterator]=function(){return this.iter()},ld.prototype[Symbol.iterator]=K$.prototype[Symbol.iterator]=J$.prototype[Symbol.iterator]=function(){return this});class Y9{constructor(e,n,r,i){this.from=e,this.to=n,this.number=r,this.text=i}get length(){return this.to-this.from}}function gc(t,e,n){return e=Math.max(0,Math.min(t.length,e)),[e,Math.max(e,Math.min(t.length,n))]}function qn(t,e,n=!0,r=!0){return I9(t,e,n,r)}function F9(t){return t>=56320&&t<57344}function W9(t){return t>=55296&&t<56320}function Jo(t,e){let n=t.charCodeAt(e);if(!W9(n)||e+1==t.length)return n;let r=t.charCodeAt(e+1);return F9(r)?(n-55296<<10)+(r-56320)+65536:n}function G9(t){return t<=65535?String.fromCharCode(t):(t-=65536,String.fromCharCode((t>>10)+55296,(t&1023)+56320))}function Hm(t){return t<65536?1:2}const N0=/\r\n?|\n/;var Hn=(function(t){return t[t.Simple=0]="Simple",t[t.TrackDel=1]="TrackDel",t[t.TrackBefore=2]="TrackBefore",t[t.TrackAfter=3]="TrackAfter",t})(Hn||(Hn={}));class ua{constructor(e){this.sections=e}get length(){let e=0;for(let n=0;n<this.sections.length;n+=2)e+=this.sections[n];return e}get newLength(){let e=0;for(let n=0;n<this.sections.length;n+=2){let r=this.sections[n+1];e+=r<0?this.sections[n]:r}return e}get empty(){return this.sections.length==0||this.sections.length==2&&this.sections[1]<0}iterGaps(e){for(let n=0,r=0,i=0;n<this.sections.length;){let a=this.sections[n++],o=this.sections[n++];o<0?(e(r,i,a),i+=a):i+=o,r+=a}}iterChangedRanges(e,n=!1){D0(this,e,n)}get invertedDesc(){let e=[];for(let n=0;n<this.sections.length;){let r=this.sections[n++],i=this.sections[n++];i<0?e.push(r,i):e.push(i,r)}return new ua(e)}composeDesc(e){return this.empty?e:e.empty?this:eP(this,e)}mapDesc(e,n=!1){return e.empty?this:z0(this,e,n)}mapPos(e,n=-1,r=Hn.Simple){let i=0,a=0;for(let o=0;o<this.sections.length;){let c=this.sections[o++],u=this.sections[o++],f=i+c;if(u<0){if(f>e)return a+(e-i);a+=c}else{if(r!=Hn.Simple&&f>=e&&(r==Hn.TrackDel&&i<e&&f>e||r==Hn.TrackBefore&&i<e||r==Hn.TrackAfter&&f>e))return null;if(f>e||f==e&&n<0&&!c)return e==i||n<0?a:a+u;a+=u}i=f}if(e>i)throw new RangeError(`Position ${e} is out of range for changeset of length ${i}`);return a}touchesRange(e,n=e){for(let r=0,i=0;r<this.sections.length&&i<=n;){let a=this.sections[r++],o=this.sections[r++],c=i+a;if(o>=0&&i<=n&&c>=e)return i<e&&c>n?"cover":!0;i=c}return!1}toString(){let e="";for(let n=0;n<this.sections.length;){let r=this.sections[n++],i=this.sections[n++];e+=(e?" ":"")+r+(i>=0?":"+i:"")}return e}toJSON(){return this.sections}static fromJSON(e){if(!Array.isArray(e)||e.length%2||e.some(n=>typeof n!="number"))throw new RangeError("Invalid JSON representation of ChangeDesc");return new ua(e)}static create(e){return new ua(e)}}class Qn extends ua{constructor(e,n){super(e),this.inserted=n}apply(e){if(this.length!=e.length)throw new RangeError("Applying change set to a document with the wrong length");return D0(this,(n,r,i,a,o)=>e=e.replace(i,i+(r-n),o),!1),e}mapDesc(e,n=!1){return z0(this,e,n,!0)}invert(e){let n=this.sections.slice(),r=[];for(let i=0,a=0;i<n.length;i+=2){let o=n[i],c=n[i+1];if(c>=0){n[i]=c,n[i+1]=o;let u=i>>1;for(;r.length<u;)r.push(St.empty);r.push(o?e.slice(a,a+o):St.empty)}a+=o}return new Qn(n,r)}compose(e){return this.empty?e:e.empty?this:eP(this,e,!0)}map(e,n=!1){return e.empty?this:z0(this,e,n,!0)}iterChanges(e,n=!1){D0(this,e,n)}get desc(){return ua.create(this.sections)}filter(e){let n=[],r=[],i=[],a=new Sd(this);e:for(let o=0,c=0;;){let u=o==e.length?1e9:e[o++];for(;c<u||c==u&&a.len==0;){if(a.done)break e;let h=Math.min(a.len,u-c);Wn(i,h,-1);let m=a.ins==-1?-1:a.off==0?a.ins:0;Wn(n,h,m),m>0&&js(r,n,a.text),a.forward(h),c+=h}let f=e[o++];for(;c<f;){if(a.done)break e;let h=Math.min(a.len,f-c);Wn(n,h,-1),Wn(i,h,a.ins==-1?-1:a.off==0?a.ins:0),a.forward(h),c+=h}}return{changes:new Qn(n,r),filtered:ua.create(i)}}toJSON(){let e=[];for(let n=0;n<this.sections.length;n+=2){let r=this.sections[n],i=this.sections[n+1];i<0?e.push(r):i==0?e.push([r]):e.push([r].concat(this.inserted[n>>1].toJSON()))}return e}static of(e,n,r){let i=[],a=[],o=0,c=null;function u(h=!1){if(!h&&!i.length)return;o<n&&Wn(i,n-o,-1);let m=new Qn(i,a);c=c?c.compose(m.map(c)):m,i=[],a=[],o=0}function f(h){if(Array.isArray(h))for(let m of h)f(m);else if(h instanceof Qn){if(h.length!=n)throw new RangeError(`Mismatched change set length (got ${h.length}, expected ${n})`);u(),c=c?c.compose(h.map(c)):h}else{let{from:m,to:g=m,insert:y}=h;if(m>g||m<0||g>n)throw new RangeError(`Invalid change range ${m} to ${g} (in doc of length ${n})`);let x=y?typeof y=="string"?St.of(y.split(r||N0)):y:St.empty,S=x.length;if(m==g&&S==0)return;m<o&&u(),m>o&&Wn(i,m-o,-1),Wn(i,g-m,S),js(a,i,x),o=g}}return f(e),u(!c),c}static empty(e){return new Qn(e?[e,-1]:[],[])}static fromJSON(e){if(!Array.isArray(e))throw new RangeError("Invalid JSON representation of ChangeSet");let n=[],r=[];for(let i=0;i<e.length;i++){let a=e[i];if(typeof a=="number")n.push(a,-1);else{if(!Array.isArray(a)||typeof a[0]!="number"||a.some((o,c)=>c&&typeof o!="string"))throw new RangeError("Invalid JSON representation of ChangeSet");if(a.length==1)n.push(a[0],0);else{for(;r.length<i;)r.push(St.empty);r[i]=St.of(a.slice(1)),n.push(a[0],r[i].length)}}}return new Qn(n,r)}static createSet(e,n){return new Qn(e,n)}}function Wn(t,e,n,r=!1){if(e==0&&n<=0)return;let i=t.length-2;i>=0&&n<=0&&n==t[i+1]?t[i]+=e:i>=0&&e==0&&t[i]==0?t[i+1]+=n:r?(t[i]+=e,t[i+1]+=n):t.push(e,n)}function js(t,e,n){if(n.length==0)return;let r=e.length-2>>1;if(r<t.length)t[t.length-1]=t[t.length-1].append(n);else{for(;t.length<r;)t.push(St.empty);t.push(n)}}function D0(t,e,n){let r=t.inserted;for(let i=0,a=0,o=0;o<t.sections.length;){let c=t.sections[o++],u=t.sections[o++];if(u<0)i+=c,a+=c;else{let f=i,h=a,m=St.empty;for(;f+=c,h+=u,u&&r&&(m=m.append(r[o-2>>1])),!(n||o==t.sections.length||t.sections[o+1]<0);)c=t.sections[o++],u=t.sections[o++];e(i,f,a,h,m),i=f,a=h}}}function z0(t,e,n,r=!1){let i=[],a=r?[]:null,o=new Sd(t),c=new Sd(e);for(let u=-1;;){if(o.done&&c.len||c.done&&o.len)throw new Error("Mismatched change set lengths");if(o.ins==-1&&c.ins==-1){let f=Math.min(o.len,c.len);Wn(i,f,-1),o.forward(f),c.forward(f)}else if(c.ins>=0&&(o.ins<0||u==o.i||o.off==0&&(c.len<o.len||c.len==o.len&&!n))){let f=c.len;for(Wn(i,c.ins,-1);f;){let h=Math.min(o.len,f);o.ins>=0&&u<o.i&&o.len<=h&&(Wn(i,0,o.ins),a&&js(a,i,o.text),u=o.i),o.forward(h),f-=h}c.next()}else if(o.ins>=0){let f=0,h=o.len;for(;h;)if(c.ins==-1){let m=Math.min(h,c.len);f+=m,h-=m,c.forward(m)}else if(c.ins==0&&c.len<h)h-=c.len,c.next();else break;Wn(i,f,u<o.i?o.ins:0),a&&u<o.i&&js(a,i,o.text),u=o.i,o.forward(o.len-h)}else{if(o.done&&c.done)return a?Qn.createSet(i,a):ua.create(i);throw new Error("Mismatched change set lengths")}}}function eP(t,e,n=!1){let r=[],i=n?[]:null,a=new Sd(t),o=new Sd(e);for(let c=!1;;){if(a.done&&o.done)return i?Qn.createSet(r,i):ua.create(r);if(a.ins==0)Wn(r,a.len,0,c),a.next();else if(o.len==0&&!o.done)Wn(r,0,o.ins,c),i&&js(i,r,o.text),o.next();else{if(a.done||o.done)throw new Error("Mismatched change set lengths");{let u=Math.min(a.len2,o.len),f=r.length;if(a.ins==-1){let h=o.ins==-1?-1:o.off?0:o.ins;Wn(r,u,h,c),i&&h&&js(i,r,o.text)}else o.ins==-1?(Wn(r,a.off?0:a.len,u,c),i&&js(i,r,a.textBit(u))):(Wn(r,a.off?0:a.len,o.off?0:o.ins,c),i&&!o.off&&js(i,r,o.text));c=(a.ins>u||o.ins>=0&&o.len>u)&&(c||r.length>f),a.forward2(u),o.forward(u)}}}}class Sd{constructor(e){this.set=e,this.i=0,this.next()}next(){let{sections:e}=this.set;this.i<e.length?(this.len=e[this.i++],this.ins=e[this.i++]):(this.len=0,this.ins=-2),this.off=0}get done(){return this.ins==-2}get len2(){return this.ins<0?this.len:this.ins}get text(){let{inserted:e}=this.set,n=this.i-2>>1;return n>=e.length?St.empty:e[n]}textBit(e){let{inserted:n}=this.set,r=this.i-2>>1;return r>=n.length&&!e?St.empty:n[r].slice(this.off,e==null?void 0:this.off+e)}forward(e){e==this.len?this.next():(this.len-=e,this.off+=e)}forward2(e){this.ins==-1?this.forward(e):e==this.ins?this.next():(this.ins-=e,this.off+=e)}}class Ao{constructor(e,n,r){this.from=e,this.to=n,this.flags=r}get anchor(){return this.flags&32?this.to:this.from}get head(){return this.flags&32?this.from:this.to}get empty(){return this.from==this.to}get assoc(){return this.flags&8?-1:this.flags&16?1:0}get bidiLevel(){let e=this.flags&7;return e==7?null:e}get goalColumn(){let e=this.flags>>6;return e==16777215?void 0:e}map(e,n=-1){let r,i;return this.empty?r=i=e.mapPos(this.from,n):(r=e.mapPos(this.from,1),i=e.mapPos(this.to,-1)),r==this.from&&i==this.to?this:new Ao(r,i,this.flags)}extend(e,n=e){if(e<=this.anchor&&n>=this.anchor)return Se.range(e,n);let r=Math.abs(e-this.anchor)>Math.abs(n-this.anchor)?e:n;return Se.range(this.anchor,r)}eq(e,n=!1){return this.anchor==e.anchor&&this.head==e.head&&(!n||!this.empty||this.assoc==e.assoc)}toJSON(){return{anchor:this.anchor,head:this.head}}static fromJSON(e){if(!e||typeof e.anchor!="number"||typeof e.head!="number")throw new RangeError("Invalid JSON representation for SelectionRange");return Se.range(e.anchor,e.head)}static create(e,n,r){return new Ao(e,n,r)}}class Se{constructor(e,n){this.ranges=e,this.mainIndex=n}map(e,n=-1){return e.empty?this:Se.create(this.ranges.map(r=>r.map(e,n)),this.mainIndex)}eq(e,n=!1){if(this.ranges.length!=e.ranges.length||this.mainIndex!=e.mainIndex)return!1;for(let r=0;r<this.ranges.length;r++)if(!this.ranges[r].eq(e.ranges[r],n))return!1;return!0}get main(){return this.ranges[this.mainIndex]}asSingle(){return this.ranges.length==1?this:new Se([this.main],0)}addRange(e,n=!0){return Se.create([e].concat(this.ranges),n?0:this.mainIndex+1)}replaceRange(e,n=this.mainIndex){let r=this.ranges.slice();return r[n]=e,Se.create(r,this.mainIndex)}toJSON(){return{ranges:this.ranges.map(e=>e.toJSON()),main:this.mainIndex}}static fromJSON(e){if(!e||!Array.isArray(e.ranges)||typeof e.main!="number"||e.main>=e.ranges.length)throw new RangeError("Invalid JSON representation for EditorSelection");return new Se(e.ranges.map(n=>Ao.fromJSON(n)),e.main)}static single(e,n=e){return new Se([Se.range(e,n)],0)}static create(e,n=0){if(e.length==0)throw new RangeError("A selection needs at least one range");for(let r=0,i=0;i<e.length;i++){let a=e[i];if(a.empty?a.from<=r:a.from<r)return Se.normalized(e.slice(),n);r=a.to}return new Se(e,n)}static cursor(e,n=0,r,i){return Ao.create(e,e,(n==0?0:n<0?8:16)|(r==null?7:Math.min(6,r))|(i??16777215)<<6)}static range(e,n,r,i){let a=(r??16777215)<<6|(i==null?7:Math.min(6,i));return n<e?Ao.create(n,e,48|a):Ao.create(e,n,(n>e?8:0)|a)}static normalized(e,n=0){let r=e[n];e.sort((i,a)=>i.from-a.from),n=e.indexOf(r);for(let i=1;i<e.length;i++){let a=e[i],o=e[i-1];if(a.empty?a.from<=o.to:a.from<o.to){let c=o.from,u=Math.max(a.to,o.to);i<=n&&n--,e.splice(--i,2,a.anchor>a.head?Se.range(u,c):Se.range(c,u))}}return new Se(e,n)}}function tP(t,e){for(let n of t.ranges)if(n.to>e)throw new RangeError("Selection points outside of document")}let Ix=0;class Xe{constructor(e,n,r,i,a){this.combine=e,this.compareInput=n,this.compare=r,this.isStatic=i,this.id=Ix++,this.default=e([]),this.extensions=typeof a=="function"?a(this):a}get reader(){return this}static define(e={}){return new Xe(e.combine||(n=>n),e.compareInput||((n,r)=>n===r),e.compare||(e.combine?(n,r)=>n===r:qx),!!e.static,e.enables)}of(e){return new vp([],this,0,e)}compute(e,n){if(this.isStatic)throw new Error("Can't compute a static facet");return new vp(e,this,1,n)}computeN(e,n){if(this.isStatic)throw new Error("Can't compute a static facet");return new vp(e,this,2,n)}from(e,n){return n||(n=r=>r),this.compute([e],r=>n(r.field(e)))}}function qx(t,e){return t==e||t.length==e.length&&t.every((n,r)=>n===e[r])}class vp{constructor(e,n,r,i){this.dependencies=e,this.facet=n,this.type=r,this.value=i,this.id=Ix++}dynamicSlot(e){var n;let r=this.value,i=this.facet.compareInput,a=this.id,o=e[a]>>1,c=this.type==2,u=!1,f=!1,h=[];for(let m of this.dependencies)m=="doc"?u=!0:m=="selection"?f=!0:(((n=e[m.id])!==null&&n!==void 0?n:1)&1)==0&&h.push(e[m.id]);return{create(m){return m.values[o]=r(m),1},update(m,g){if(u&&g.docChanged||f&&(g.docChanged||g.selection)||L0(m,h)){let y=r(m);if(c?!C2(y,m.values[o],i):!i(y,m.values[o]))return m.values[o]=y,1}return 0},reconfigure:(m,g)=>{let y,x=g.config.address[a];if(x!=null){let S=Ip(g,x);if(this.dependencies.every(k=>k instanceof Xe?g.facet(k)===m.facet(k):k instanceof Mi?g.field(k,!1)==m.field(k,!1):!0)||(c?C2(y=r(m),S,i):i(y=r(m),S)))return m.values[o]=S,0}else y=r(m);return m.values[o]=y,1}}}}function C2(t,e,n){if(t.length!=e.length)return!1;for(let r=0;r<t.length;r++)if(!n(t[r],e[r]))return!1;return!0}function L0(t,e){let n=!1;for(let r of e)cd(t,r)&1&&(n=!0);return n}function H9(t,e,n){let r=n.map(u=>t[u.id]),i=n.map(u=>u.type),a=r.filter(u=>!(u&1)),o=t[e.id]>>1;function c(u){let f=[];for(let h=0;h<r.length;h++){let m=Ip(u,r[h]);if(i[h]==2)for(let g of m)f.push(g);else f.push(m)}return e.combine(f)}return{create(u){for(let f of r)cd(u,f);return u.values[o]=c(u),1},update(u,f){if(!L0(u,a))return 0;let h=c(u);return e.compare(h,u.values[o])?0:(u.values[o]=h,1)},reconfigure(u,f){let h=L0(u,r),m=f.config.facets[e.id],g=f.facet(e);if(m&&!h&&qx(n,m))return u.values[o]=g,0;let y=c(u);return e.compare(y,g)?(u.values[o]=g,0):(u.values[o]=y,1)}}}const zh=Xe.define({static:!0});class Mi{constructor(e,n,r,i,a){this.id=e,this.createF=n,this.updateF=r,this.compareF=i,this.spec=a,this.provides=void 0}static define(e){let n=new Mi(Ix++,e.create,e.update,e.compare||((r,i)=>r===i),e);return e.provide&&(n.provides=e.provide(n)),n}create(e){let n=e.facet(zh).find(r=>r.field==this);return(n?.create||this.createF)(e)}slot(e){let n=e[this.id]>>1;return{create:r=>(r.values[n]=this.create(r),1),update:(r,i)=>{let a=r.values[n],o=this.updateF(a,i);return this.compareF(a,o)?0:(r.values[n]=o,1)},reconfigure:(r,i)=>{let a=r.facet(zh),o=i.facet(zh),c;return(c=a.find(u=>u.field==this))&&c!=o.find(u=>u.field==this)?(r.values[n]=c.create(r),1):i.config.address[this.id]!=null?(r.values[n]=i.field(this),0):(r.values[n]=this.create(r),1)}}}init(e){return[this,zh.of({field:this,create:e})]}get extension(){return this}}const Co={lowest:4,low:3,default:2,high:1,highest:0};function Iu(t){return e=>new nP(e,t)}const Km={highest:Iu(Co.highest),high:Iu(Co.high),default:Iu(Co.default),low:Iu(Co.low),lowest:Iu(Co.lowest)};class nP{constructor(e,n){this.inner=e,this.prec=n}}class Jm{of(e){return new Z0(this,e)}reconfigure(e){return Jm.reconfigure.of({compartment:this,extension:e})}get(e){return e.config.compartments.get(this)}}class Z0{constructor(e,n){this.compartment=e,this.inner=n}}class Bp{constructor(e,n,r,i,a,o){for(this.base=e,this.compartments=n,this.dynamicSlots=r,this.address=i,this.staticValues=a,this.facets=o,this.statusTemplate=[];this.statusTemplate.length<r.length;)this.statusTemplate.push(0)}staticFacet(e){let n=this.address[e.id];return n==null?e.default:this.staticValues[n>>1]}static resolve(e,n,r){let i=[],a=Object.create(null),o=new Map;for(let g of K9(e,n,o))g instanceof Mi?i.push(g):(a[g.facet.id]||(a[g.facet.id]=[])).push(g);let c=Object.create(null),u=[],f=[];for(let g of i)c[g.id]=f.length<<1,f.push(y=>g.slot(y));let h=r?.config.facets;for(let g in a){let y=a[g],x=y[0].facet,S=h&&h[g]||[];if(y.every(k=>k.type==0))if(c[x.id]=u.length<<1|1,qx(S,y))u.push(r.facet(x));else{let k=x.combine(y.map(T=>T.value));u.push(r&&x.compare(k,r.facet(x))?r.facet(x):k)}else{for(let k of y)k.type==0?(c[k.id]=u.length<<1|1,u.push(k.value)):(c[k.id]=f.length<<1,f.push(T=>k.dynamicSlot(T)));c[x.id]=f.length<<1,f.push(k=>H9(k,x,y))}}let m=f.map(g=>g(c));return new Bp(e,o,m,c,u,a)}}function K9(t,e,n){let r=[[],[],[],[],[]],i=new Map;function a(o,c){let u=i.get(o);if(u!=null){if(u<=c)return;let f=r[u].indexOf(o);f>-1&&r[u].splice(f,1),o instanceof Z0&&n.delete(o.compartment)}if(i.set(o,c),Array.isArray(o))for(let f of o)a(f,c);else if(o instanceof Z0){if(n.has(o.compartment))throw new RangeError("Duplicate use of compartment in extensions");let f=e.get(o.compartment)||o.inner;n.set(o.compartment,f),a(f,c)}else if(o instanceof nP)a(o.inner,o.prec);else if(o instanceof Mi)r[c].push(o),o.provides&&a(o.provides,c);else if(o instanceof vp)r[c].push(o),o.facet.extensions&&a(o.facet.extensions,Co.default);else{let f=o.extension;if(!f)throw new Error(`Unrecognized extension value in extension set (${o}). This sometimes happens because multiple instances of @codemirror/state are loaded, breaking instanceof checks.`);a(f,c)}}return a(t,Co.default),r.reduce((o,c)=>o.concat(c))}function cd(t,e){if(e&1)return 2;let n=e>>1,r=t.status[n];if(r==4)throw new Error("Cyclic dependency between fields and/or facets");if(r&2)return r;t.status[n]=4;let i=t.computeSlot(t,t.config.dynamicSlots[n]);return t.status[n]=2|i}function Ip(t,e){return e&1?t.config.staticValues[e>>1]:t.values[e>>1]}const rP=Xe.define(),V0=Xe.define({combine:t=>t.some(e=>e),static:!0}),iP=Xe.define({combine:t=>t.length?t[0]:void 0,static:!0}),aP=Xe.define(),sP=Xe.define(),oP=Xe.define(),lP=Xe.define({combine:t=>t.length?t[0]:!1});class Ri{constructor(e,n){this.type=e,this.value=n}static define(){return new J9}}class J9{of(e){return new Ri(this,e)}}class eq{constructor(e){this.map=e}of(e){return new Vt(this,e)}}class Vt{constructor(e,n){this.type=e,this.value=n}map(e){let n=this.type.map(this.value,e);return n===void 0?void 0:n==this.value?this:new Vt(this.type,n)}is(e){return this.type==e}static define(e={}){return new eq(e.map||(n=>n))}static mapEffects(e,n){if(!e.length)return e;let r=[];for(let i of e){let a=i.map(n);a&&r.push(a)}return r}}Vt.reconfigure=Vt.define();Vt.appendConfig=Vt.define();class xn{constructor(e,n,r,i,a,o){this.startState=e,this.changes=n,this.selection=r,this.effects=i,this.annotations=a,this.scrollIntoView=o,this._doc=null,this._state=null,r&&tP(r,n.newLength),a.some(c=>c.type==xn.time)||(this.annotations=a.concat(xn.time.of(Date.now())))}static create(e,n,r,i,a,o){return new xn(e,n,r,i,a,o)}get newDoc(){return this._doc||(this._doc=this.changes.apply(this.startState.doc))}get newSelection(){return this.selection||this.startState.selection.map(this.changes)}get state(){return this._state||this.startState.applyTransaction(this),this._state}annotation(e){for(let n of this.annotations)if(n.type==e)return n.value}get docChanged(){return!this.changes.empty}get reconfigured(){return this.startState.config!=this.state.config}isUserEvent(e){let n=this.annotation(xn.userEvent);return!!(n&&(n==e||n.length>e.length&&n.slice(0,e.length)==e&&n[e.length]=="."))}}xn.time=Ri.define();xn.userEvent=Ri.define();xn.addToHistory=Ri.define();xn.remote=Ri.define();function tq(t,e){let n=[];for(let r=0,i=0;;){let a,o;if(r<t.length&&(i==e.length||e[i]>=t[r]))a=t[r++],o=t[r++];else if(i<e.length)a=e[i++],o=e[i++];else return n;!n.length||n[n.length-1]<a?n.push(a,o):n[n.length-1]<o&&(n[n.length-1]=o)}}function cP(t,e,n){var r;let i,a,o;return n?(i=e.changes,a=Qn.empty(e.changes.length),o=t.changes.compose(e.changes)):(i=e.changes.map(t.changes),a=t.changes.mapDesc(e.changes,!0),o=t.changes.compose(i)),{changes:o,selection:e.selection?e.selection.map(a):(r=t.selection)===null||r===void 0?void 0:r.map(i),effects:Vt.mapEffects(t.effects,i).concat(Vt.mapEffects(e.effects,a)),annotations:t.annotations.length?t.annotations.concat(e.annotations):e.annotations,scrollIntoView:t.scrollIntoView||e.scrollIntoView}}function X0(t,e,n){let r=e.selection,i=sc(e.annotations);return e.userEvent&&(i=i.concat(xn.userEvent.of(e.userEvent))),{changes:e.changes instanceof Qn?e.changes:Qn.of(e.changes||[],n,t.facet(iP)),selection:r&&(r instanceof Se?r:Se.single(r.anchor,r.head)),effects:sc(e.effects),annotations:i,scrollIntoView:!!e.scrollIntoView}}function uP(t,e,n){let r=X0(t,e.length?e[0]:{},t.doc.length);e.length&&e[0].filter===!1&&(n=!1);for(let a=1;a<e.length;a++){e[a].filter===!1&&(n=!1);let o=!!e[a].sequential;r=cP(r,X0(t,e[a],o?r.changes.newLength:t.doc.length),o)}let i=xn.create(t,r.changes,r.selection,r.effects,r.annotations,r.scrollIntoView);return rq(n?nq(i):i)}function nq(t){let e=t.startState,n=!0;for(let i of e.facet(aP)){let a=i(t);if(a===!1){n=!1;break}Array.isArray(a)&&(n=n===!0?a:tq(n,a))}if(n!==!0){let i,a;if(n===!1)a=t.changes.invertedDesc,i=Qn.empty(e.doc.length);else{let o=t.changes.filter(n);i=o.changes,a=o.filtered.mapDesc(o.changes).invertedDesc}t=xn.create(e,i,t.selection&&t.selection.map(a),Vt.mapEffects(t.effects,a),t.annotations,t.scrollIntoView)}let r=e.facet(sP);for(let i=r.length-1;i>=0;i--){let a=r[i](t);a instanceof xn?t=a:Array.isArray(a)&&a.length==1&&a[0]instanceof xn?t=a[0]:t=uP(e,sc(a),!1)}return t}function rq(t){let e=t.startState,n=e.facet(oP),r=t;for(let i=n.length-1;i>=0;i--){let a=n[i](t);a&&Object.keys(a).length&&(r=cP(r,X0(e,a,t.changes.newLength),!0))}return r==t?t:xn.create(e,t.changes,t.selection,r.effects,r.annotations,r.scrollIntoView)}const iq=[];function sc(t){return t==null?iq:Array.isArray(t)?t:[t]}var ii=(function(t){return t[t.Word=0]="Word",t[t.Space=1]="Space",t[t.Other=2]="Other",t})(ii||(ii={}));const aq=/[\u00df\u0587\u0590-\u05f4\u0600-\u06ff\u3040-\u309f\u30a0-\u30ff\u3400-\u4db5\u4e00-\u9fcc\uac00-\ud7af]/;let B0;try{B0=new RegExp("[\\p{Alphabetic}\\p{Number}_]","u")}catch{}function sq(t){if(B0)return B0.test(t);for(let e=0;e<t.length;e++){let n=t[e];if(/\w/.test(n)||n>""&&(n.toUpperCase()!=n.toLowerCase()||aq.test(n)))return!0}return!1}function oq(t){return e=>{if(!/\S/.test(e))return ii.Space;if(sq(e))return ii.Word;for(let n=0;n<t.length;n++)if(e.indexOf(t[n])>-1)return ii.Word;return ii.Other}}class At{constructor(e,n,r,i,a,o){this.config=e,this.doc=n,this.selection=r,this.values=i,this.status=e.statusTemplate.slice(),this.computeSlot=a,o&&(o._state=this);for(let c=0;c<this.config.dynamicSlots.length;c++)cd(this,c<<1);this.computeSlot=null}field(e,n=!0){let r=this.config.address[e.id];if(r==null){if(n)throw new RangeError("Field is not present in this state");return}return cd(this,r),Ip(this,r)}update(...e){return uP(this,e,!0)}applyTransaction(e){let n=this.config,{base:r,compartments:i}=n;for(let c of e.effects)c.is(Jm.reconfigure)?(n&&(i=new Map,n.compartments.forEach((u,f)=>i.set(f,u)),n=null),i.set(c.value.compartment,c.value.extension)):c.is(Vt.reconfigure)?(n=null,r=c.value):c.is(Vt.appendConfig)&&(n=null,r=sc(r).concat(c.value));let a;n?a=e.startState.values.slice():(n=Bp.resolve(r,i,this),a=new At(n,this.doc,this.selection,n.dynamicSlots.map(()=>null),(u,f)=>f.reconfigure(u,this),null).values);let o=e.startState.facet(V0)?e.newSelection:e.newSelection.asSingle();new At(n,e.newDoc,o,a,(c,u)=>u.update(c,e),e)}replaceSelection(e){return typeof e=="string"&&(e=this.toText(e)),this.changeByRange(n=>({changes:{from:n.from,to:n.to,insert:e},range:Se.cursor(n.from+e.length)}))}changeByRange(e){let n=this.selection,r=e(n.ranges[0]),i=this.changes(r.changes),a=[r.range],o=sc(r.effects);for(let c=1;c<n.ranges.length;c++){let u=e(n.ranges[c]),f=this.changes(u.changes),h=f.map(i);for(let g=0;g<c;g++)a[g]=a[g].map(h);let m=i.mapDesc(f,!0);a.push(u.range.map(m)),i=i.compose(h),o=Vt.mapEffects(o,h).concat(Vt.mapEffects(sc(u.effects),m))}return{changes:i,selection:Se.create(a,n.mainIndex),effects:o}}changes(e=[]){return e instanceof Qn?e:Qn.of(e,this.doc.length,this.facet(At.lineSeparator))}toText(e){return St.of(e.split(this.facet(At.lineSeparator)||N0))}sliceDoc(e=0,n=this.doc.length){return this.doc.sliceString(e,n,this.lineBreak)}facet(e){let n=this.config.address[e.id];return n==null?e.default:(cd(this,n),Ip(this,n))}toJSON(e){let n={doc:this.sliceDoc(),selection:this.selection.toJSON()};if(e)for(let r in e){let i=e[r];i instanceof Mi&&this.config.address[i.id]!=null&&(n[r]=i.spec.toJSON(this.field(e[r]),this))}return n}static fromJSON(e,n={},r){if(!e||typeof e.doc!="string")throw new RangeError("Invalid JSON representation for EditorState");let i=[];if(r){for(let a in r)if(Object.prototype.hasOwnProperty.call(e,a)){let o=r[a],c=e[a];i.push(o.init(u=>o.spec.fromJSON(c,u)))}}return At.create({doc:e.doc,selection:Se.fromJSON(e.selection),extensions:n.extensions?i.concat([n.extensions]):i})}static create(e={}){let n=Bp.resolve(e.extensions||[],new Map),r=e.doc instanceof St?e.doc:St.of((e.doc||"").split(n.staticFacet(At.lineSeparator)||N0)),i=e.selection?e.selection instanceof Se?e.selection:Se.single(e.selection.anchor,e.selection.head):Se.single(0);return tP(i,r.length),n.staticFacet(V0)||(i=i.asSingle()),new At(n,r,i,n.dynamicSlots.map(()=>null),(a,o)=>o.create(a),null)}get tabSize(){return this.facet(At.tabSize)}get lineBreak(){return this.facet(At.lineSeparator)||`
|
|
82
|
-
`}get readOnly(){return this.facet(lP)}phrase(e,...n){for(let r of this.facet(At.phrases))if(Object.prototype.hasOwnProperty.call(r,e)){e=r[e];break}return n.length&&(e=e.replace(/\$(\$|\d*)/g,(r,i)=>{if(i=="$")return"$";let a=+(i||1);return!a||a>n.length?r:n[a-1]})),e}languageDataAt(e,n,r=-1){let i=[];for(let a of this.facet(rP))for(let o of a(this,n,r))Object.prototype.hasOwnProperty.call(o,e)&&i.push(o[e]);return i}charCategorizer(e){return oq(this.languageDataAt("wordChars",e).join(""))}wordAt(e){let{text:n,from:r,length:i}=this.doc.lineAt(e),a=this.charCategorizer(e),o=e-r,c=e-r;for(;o>0;){let u=qn(n,o,!1);if(a(n.slice(u,o))!=ii.Word)break;o=u}for(;c<i;){let u=qn(n,c);if(a(n.slice(c,u))!=ii.Word)break;c=u}return o==c?null:Se.range(o+r,c+r)}}At.allowMultipleSelections=V0;At.tabSize=Xe.define({combine:t=>t.length?t[0]:4});At.lineSeparator=iP;At.readOnly=lP;At.phrases=Xe.define({compare(t,e){let n=Object.keys(t),r=Object.keys(e);return n.length==r.length&&n.every(i=>t[i]==e[i])}});At.languageData=rP;At.changeFilter=aP;At.transactionFilter=sP;At.transactionExtender=oP;Jm.reconfigure=Vt.define();function eg(t,e,n={}){let r={};for(let i of t)for(let a of Object.keys(i)){let o=i[a],c=r[a];if(c===void 0)r[a]=o;else if(!(c===o||o===void 0))if(Object.hasOwnProperty.call(n,a))r[a]=n[a](c,o);else throw new Error("Config merge conflict for field "+a)}for(let i in e)r[i]===void 0&&(r[i]=e[i]);return r}class Bs{eq(e){return this==e}range(e,n=e){return I0.create(e,n,this)}}Bs.prototype.startSide=Bs.prototype.endSide=0;Bs.prototype.point=!1;Bs.prototype.mapMode=Hn.TrackDel;let I0=class dP{constructor(e,n,r){this.from=e,this.to=n,this.value=r}static create(e,n,r){return new dP(e,n,r)}};function q0(t,e){return t.from-e.from||t.value.startSide-e.value.startSide}class Ux{constructor(e,n,r,i){this.from=e,this.to=n,this.value=r,this.maxPoint=i}get length(){return this.to[this.to.length-1]}findIndex(e,n,r,i=0){let a=r?this.to:this.from;for(let o=i,c=a.length;;){if(o==c)return o;let u=o+c>>1,f=a[u]-e||(r?this.value[u].endSide:this.value[u].startSide)-n;if(u==o)return f>=0?o:c;f>=0?c=u:o=u+1}}between(e,n,r,i){for(let a=this.findIndex(n,-1e9,!0),o=this.findIndex(r,1e9,!1,a);a<o;a++)if(i(this.from[a]+e,this.to[a]+e,this.value[a])===!1)return!1}map(e,n){let r=[],i=[],a=[],o=-1,c=-1;for(let u=0;u<this.value.length;u++){let f=this.value[u],h=this.from[u]+e,m=this.to[u]+e,g,y;if(h==m){let x=n.mapPos(h,f.startSide,f.mapMode);if(x==null||(g=y=x,f.startSide!=f.endSide&&(y=n.mapPos(h,f.endSide),y<g)))continue}else if(g=n.mapPos(h,f.startSide),y=n.mapPos(m,f.endSide),g>y||g==y&&f.startSide>0&&f.endSide<=0)continue;(y-g||f.endSide-f.startSide)<0||(o<0&&(o=g),f.point&&(c=Math.max(c,y-g)),r.push(f),i.push(g-o),a.push(y-o))}return{mapped:r.length?new Ux(i,a,r,c):null,pos:o}}}class xt{constructor(e,n,r,i){this.chunkPos=e,this.chunk=n,this.nextLayer=r,this.maxPoint=i}static create(e,n,r,i){return new xt(e,n,r,i)}get length(){let e=this.chunk.length-1;return e<0?0:Math.max(this.chunkEnd(e),this.nextLayer.length)}get size(){if(this.isEmpty)return 0;let e=this.nextLayer.size;for(let n of this.chunk)e+=n.value.length;return e}chunkEnd(e){return this.chunkPos[e]+this.chunk[e].length}update(e){let{add:n=[],sort:r=!1,filterFrom:i=0,filterTo:a=this.length}=e,o=e.filter;if(n.length==0&&!o)return this;if(r&&(n=n.slice().sort(q0)),this.isEmpty)return n.length?xt.of(n):this;let c=new fP(this,null,-1).goto(0),u=0,f=[],h=new Oc;for(;c.value||u<n.length;)if(u<n.length&&(c.from-n[u].from||c.startSide-n[u].value.startSide)>=0){let m=n[u++];h.addInner(m.from,m.to,m.value)||f.push(m)}else c.rangeIndex==1&&c.chunkIndex<this.chunk.length&&(u==n.length||this.chunkEnd(c.chunkIndex)<n[u].from)&&(!o||i>this.chunkEnd(c.chunkIndex)||a<this.chunkPos[c.chunkIndex])&&h.addChunk(this.chunkPos[c.chunkIndex],this.chunk[c.chunkIndex])?c.nextChunk():((!o||i>c.to||a<c.from||o(c.from,c.to,c.value))&&(h.addInner(c.from,c.to,c.value)||f.push(I0.create(c.from,c.to,c.value))),c.next());return h.finishInner(this.nextLayer.isEmpty&&!f.length?xt.empty:this.nextLayer.update({add:f,filter:o,filterFrom:i,filterTo:a}))}map(e){if(e.empty||this.isEmpty)return this;let n=[],r=[],i=-1;for(let o=0;o<this.chunk.length;o++){let c=this.chunkPos[o],u=this.chunk[o],f=e.touchesRange(c,c+u.length);if(f===!1)i=Math.max(i,u.maxPoint),n.push(u),r.push(e.mapPos(c));else if(f===!0){let{mapped:h,pos:m}=u.map(c,e);h&&(i=Math.max(i,h.maxPoint),n.push(h),r.push(m))}}let a=this.nextLayer.map(e);return n.length==0?a:new xt(r,n,a||xt.empty,i)}between(e,n,r){if(!this.isEmpty){for(let i=0;i<this.chunk.length;i++){let a=this.chunkPos[i],o=this.chunk[i];if(n>=a&&e<=a+o.length&&o.between(a,e-a,n-a,r)===!1)return}this.nextLayer.between(e,n,r)}}iter(e=0){return wd.from([this]).goto(e)}get isEmpty(){return this.nextLayer==this}static iter(e,n=0){return wd.from(e).goto(n)}static compare(e,n,r,i,a=-1){let o=e.filter(m=>m.maxPoint>0||!m.isEmpty&&m.maxPoint>=a),c=n.filter(m=>m.maxPoint>0||!m.isEmpty&&m.maxPoint>=a),u=T2(o,c,r),f=new qu(o,u,a),h=new qu(c,u,a);r.iterGaps((m,g,y)=>E2(f,m,h,g,y,i)),r.empty&&r.length==0&&E2(f,0,h,0,0,i)}static eq(e,n,r=0,i){i==null&&(i=999999999);let a=e.filter(h=>!h.isEmpty&&n.indexOf(h)<0),o=n.filter(h=>!h.isEmpty&&e.indexOf(h)<0);if(a.length!=o.length)return!1;if(!a.length)return!0;let c=T2(a,o),u=new qu(a,c,0).goto(r),f=new qu(o,c,0).goto(r);for(;;){if(u.to!=f.to||!U0(u.active,f.active)||u.point&&(!f.point||!u.point.eq(f.point)))return!1;if(u.to>i)return!0;u.next(),f.next()}}static spans(e,n,r,i,a=-1){let o=new qu(e,null,a).goto(n),c=n,u=o.openStart;for(;;){let f=Math.min(o.to,r);if(o.point){let h=o.activeForPoint(o.to),m=o.pointFrom<n?h.length+1:o.point.startSide<0?h.length:Math.min(h.length,u);i.point(c,f,o.point,h,m,o.pointRank),u=Math.min(o.openEnd(f),h.length)}else f>c&&(i.span(c,f,o.active,u),u=o.openEnd(f));if(o.to>r)return u+(o.point&&o.to>r?1:0);c=o.to,o.next()}}static of(e,n=!1){let r=new Oc;for(let i of e instanceof I0?[e]:n?lq(e):e)r.add(i.from,i.to,i.value);return r.finish()}static join(e){if(!e.length)return xt.empty;let n=e[e.length-1];for(let r=e.length-2;r>=0;r--)for(let i=e[r];i!=xt.empty;i=i.nextLayer)n=new xt(i.chunkPos,i.chunk,n,Math.max(i.maxPoint,n.maxPoint));return n}}xt.empty=new xt([],[],null,-1);function lq(t){if(t.length>1)for(let e=t[0],n=1;n<t.length;n++){let r=t[n];if(q0(e,r)>0)return t.slice().sort(q0);e=r}return t}xt.empty.nextLayer=xt.empty;class Oc{finishChunk(e){this.chunks.push(new Ux(this.from,this.to,this.value,this.maxPoint)),this.chunkPos.push(this.chunkStart),this.chunkStart=-1,this.setMaxPoint=Math.max(this.setMaxPoint,this.maxPoint),this.maxPoint=-1,e&&(this.from=[],this.to=[],this.value=[])}constructor(){this.chunks=[],this.chunkPos=[],this.chunkStart=-1,this.last=null,this.lastFrom=-1e9,this.lastTo=-1e9,this.from=[],this.to=[],this.value=[],this.maxPoint=-1,this.setMaxPoint=-1,this.nextLayer=null}add(e,n,r){this.addInner(e,n,r)||(this.nextLayer||(this.nextLayer=new Oc)).add(e,n,r)}addInner(e,n,r){let i=e-this.lastTo||r.startSide-this.last.endSide;if(i<=0&&(e-this.lastFrom||r.startSide-this.last.startSide)<0)throw new Error("Ranges must be added sorted by `from` position and `startSide`");return i<0?!1:(this.from.length==250&&this.finishChunk(!0),this.chunkStart<0&&(this.chunkStart=e),this.from.push(e-this.chunkStart),this.to.push(n-this.chunkStart),this.last=r,this.lastFrom=e,this.lastTo=n,this.value.push(r),r.point&&(this.maxPoint=Math.max(this.maxPoint,n-e)),!0)}addChunk(e,n){if((e-this.lastTo||n.value[0].startSide-this.last.endSide)<0)return!1;this.from.length&&this.finishChunk(!0),this.setMaxPoint=Math.max(this.setMaxPoint,n.maxPoint),this.chunks.push(n),this.chunkPos.push(e);let r=n.value.length-1;return this.last=n.value[r],this.lastFrom=n.from[r]+e,this.lastTo=n.to[r]+e,!0}finish(){return this.finishInner(xt.empty)}finishInner(e){if(this.from.length&&this.finishChunk(!1),this.chunks.length==0)return e;let n=xt.create(this.chunkPos,this.chunks,this.nextLayer?this.nextLayer.finishInner(e):e,this.setMaxPoint);return this.from=null,n}}function T2(t,e,n){let r=new Map;for(let a of t)for(let o=0;o<a.chunk.length;o++)a.chunk[o].maxPoint<=0&&r.set(a.chunk[o],a.chunkPos[o]);let i=new Set;for(let a of e)for(let o=0;o<a.chunk.length;o++){let c=r.get(a.chunk[o]);c!=null&&(n?n.mapPos(c):c)==a.chunkPos[o]&&!n?.touchesRange(c,c+a.chunk[o].length)&&i.add(a.chunk[o])}return i}class fP{constructor(e,n,r,i=0){this.layer=e,this.skip=n,this.minPoint=r,this.rank=i}get startSide(){return this.value?this.value.startSide:0}get endSide(){return this.value?this.value.endSide:0}goto(e,n=-1e9){return this.chunkIndex=this.rangeIndex=0,this.gotoInner(e,n,!1),this}gotoInner(e,n,r){for(;this.chunkIndex<this.layer.chunk.length;){let i=this.layer.chunk[this.chunkIndex];if(!(this.skip&&this.skip.has(i)||this.layer.chunkEnd(this.chunkIndex)<e||i.maxPoint<this.minPoint))break;this.chunkIndex++,r=!1}if(this.chunkIndex<this.layer.chunk.length){let i=this.layer.chunk[this.chunkIndex].findIndex(e-this.layer.chunkPos[this.chunkIndex],n,!0);(!r||this.rangeIndex<i)&&this.setRangeIndex(i)}this.next()}forward(e,n){(this.to-e||this.endSide-n)<0&&this.gotoInner(e,n,!0)}next(){for(;;)if(this.chunkIndex==this.layer.chunk.length){this.from=this.to=1e9,this.value=null;break}else{let e=this.layer.chunkPos[this.chunkIndex],n=this.layer.chunk[this.chunkIndex],r=e+n.from[this.rangeIndex];if(this.from=r,this.to=e+n.to[this.rangeIndex],this.value=n.value[this.rangeIndex],this.setRangeIndex(this.rangeIndex+1),this.minPoint<0||this.value.point&&this.to-this.from>=this.minPoint)break}}setRangeIndex(e){if(e==this.layer.chunk[this.chunkIndex].value.length){if(this.chunkIndex++,this.skip)for(;this.chunkIndex<this.layer.chunk.length&&this.skip.has(this.layer.chunk[this.chunkIndex]);)this.chunkIndex++;this.rangeIndex=0}else this.rangeIndex=e}nextChunk(){this.chunkIndex++,this.rangeIndex=0,this.next()}compare(e){return this.from-e.from||this.startSide-e.startSide||this.rank-e.rank||this.to-e.to||this.endSide-e.endSide}}class wd{constructor(e){this.heap=e}static from(e,n=null,r=-1){let i=[];for(let a=0;a<e.length;a++)for(let o=e[a];!o.isEmpty;o=o.nextLayer)o.maxPoint>=r&&i.push(new fP(o,n,r,a));return i.length==1?i[0]:new wd(i)}get startSide(){return this.value?this.value.startSide:0}goto(e,n=-1e9){for(let r of this.heap)r.goto(e,n);for(let r=this.heap.length>>1;r>=0;r--)fy(this.heap,r);return this.next(),this}forward(e,n){for(let r of this.heap)r.forward(e,n);for(let r=this.heap.length>>1;r>=0;r--)fy(this.heap,r);(this.to-e||this.value.endSide-n)<0&&this.next()}next(){if(this.heap.length==0)this.from=this.to=1e9,this.value=null,this.rank=-1;else{let e=this.heap[0];this.from=e.from,this.to=e.to,this.value=e.value,this.rank=e.rank,e.value&&e.next(),fy(this.heap,0)}}}function fy(t,e){for(let n=t[e];;){let r=(e<<1)+1;if(r>=t.length)break;let i=t[r];if(r+1<t.length&&i.compare(t[r+1])>=0&&(i=t[r+1],r++),n.compare(i)<0)break;t[r]=n,t[e]=i,e=r}}class qu{constructor(e,n,r){this.minPoint=r,this.active=[],this.activeTo=[],this.activeRank=[],this.minActive=-1,this.point=null,this.pointFrom=0,this.pointRank=0,this.to=-1e9,this.endSide=0,this.openStart=-1,this.cursor=wd.from(e,n,r)}goto(e,n=-1e9){return this.cursor.goto(e,n),this.active.length=this.activeTo.length=this.activeRank.length=0,this.minActive=-1,this.to=e,this.endSide=n,this.openStart=-1,this.next(),this}forward(e,n){for(;this.minActive>-1&&(this.activeTo[this.minActive]-e||this.active[this.minActive].endSide-n)<0;)this.removeActive(this.minActive);this.cursor.forward(e,n)}removeActive(e){Lh(this.active,e),Lh(this.activeTo,e),Lh(this.activeRank,e),this.minActive=Q2(this.active,this.activeTo)}addActive(e){let n=0,{value:r,to:i,rank:a}=this.cursor;for(;n<this.activeRank.length&&(a-this.activeRank[n]||i-this.activeTo[n])>0;)n++;Zh(this.active,n,r),Zh(this.activeTo,n,i),Zh(this.activeRank,n,a),e&&Zh(e,n,this.cursor.from),this.minActive=Q2(this.active,this.activeTo)}next(){let e=this.to,n=this.point;this.point=null;let r=this.openStart<0?[]:null;for(;;){let i=this.minActive;if(i>-1&&(this.activeTo[i]-this.cursor.from||this.active[i].endSide-this.cursor.startSide)<0){if(this.activeTo[i]>e){this.to=this.activeTo[i],this.endSide=this.active[i].endSide;break}this.removeActive(i),r&&Lh(r,i)}else if(this.cursor.value)if(this.cursor.from>e){this.to=this.cursor.from,this.endSide=this.cursor.startSide;break}else{let a=this.cursor.value;if(!a.point)this.addActive(r),this.cursor.next();else if(n&&this.cursor.to==this.to&&this.cursor.from<this.cursor.to)this.cursor.next();else{this.point=a,this.pointFrom=this.cursor.from,this.pointRank=this.cursor.rank,this.to=this.cursor.to,this.endSide=a.endSide,this.cursor.next(),this.forward(this.to,this.endSide);break}}else{this.to=this.endSide=1e9;break}}if(r){this.openStart=0;for(let i=r.length-1;i>=0&&r[i]<e;i--)this.openStart++}}activeForPoint(e){if(!this.active.length)return this.active;let n=[];for(let r=this.active.length-1;r>=0&&!(this.activeRank[r]<this.pointRank);r--)(this.activeTo[r]>e||this.activeTo[r]==e&&this.active[r].endSide>=this.point.endSide)&&n.push(this.active[r]);return n.reverse()}openEnd(e){let n=0;for(let r=this.activeTo.length-1;r>=0&&this.activeTo[r]>e;r--)n++;return n}}function E2(t,e,n,r,i,a){t.goto(e),n.goto(r);let o=r+i,c=r,u=r-e;for(;;){let f=t.to+u-n.to,h=f||t.endSide-n.endSide,m=h<0?t.to+u:n.to,g=Math.min(m,o);if(t.point||n.point?t.point&&n.point&&(t.point==n.point||t.point.eq(n.point))&&U0(t.activeForPoint(t.to),n.activeForPoint(n.to))||a.comparePoint(c,g,t.point,n.point):g>c&&!U0(t.active,n.active)&&a.compareRange(c,g,t.active,n.active),m>o)break;(f||t.openEnd!=n.openEnd)&&a.boundChange&&a.boundChange(m),c=m,h<=0&&t.next(),h>=0&&n.next()}}function U0(t,e){if(t.length!=e.length)return!1;for(let n=0;n<t.length;n++)if(t[n]!=e[n]&&!t[n].eq(e[n]))return!1;return!0}function Lh(t,e){for(let n=e,r=t.length-1;n<r;n++)t[n]=t[n+1];t.pop()}function Zh(t,e,n){for(let r=t.length-1;r>=e;r--)t[r+1]=t[r];t[e]=n}function Q2(t,e){let n=-1,r=1e9;for(let i=0;i<e.length;i++)(e[i]-r||t[i].endSide-t[n].endSide)<0&&(n=i,r=e[i]);return n}function af(t,e,n=t.length){let r=0;for(let i=0;i<n&&i<t.length;)t.charCodeAt(i)==9?(r+=e-r%e,i++):(r++,i=qn(t,i));return r}function cq(t,e,n,r){for(let i=0,a=0;;){if(a>=e)return i;if(i==t.length)break;a+=t.charCodeAt(i)==9?n-a%n:1,i=qn(t,i)}return t.length}const Y0="ͼ",A2=typeof Symbol>"u"?"__"+Y0:Symbol.for(Y0),F0=typeof Symbol>"u"?"__styleSet"+Math.floor(Math.random()*1e8):Symbol("styleSet"),R2=typeof globalThis<"u"?globalThis:typeof window<"u"?window:{};class Is{constructor(e,n){this.rules=[];let{finish:r}=n||{};function i(o){return/^@/.test(o)?[o]:o.split(/,\s*/)}function a(o,c,u,f){let h=[],m=/^@(\w+)\b/.exec(o[0]),g=m&&m[1]=="keyframes";if(m&&c==null)return u.push(o[0]+";");for(let y in c){let x=c[y];if(/&/.test(y))a(y.split(/,\s*/).map(S=>o.map(k=>S.replace(/&/,k))).reduce((S,k)=>S.concat(k)),x,u);else if(x&&typeof x=="object"){if(!m)throw new RangeError("The value of a property ("+y+") should be a primitive value.");a(i(y),x,h,g)}else x!=null&&h.push(y.replace(/_.*/,"").replace(/[A-Z]/g,S=>"-"+S.toLowerCase())+": "+x+";")}(h.length||g)&&u.push((r&&!m&&!f?o.map(r):o).join(", ")+" {"+h.join(" ")+"}")}for(let o in e)a(i(o),e[o],this.rules)}getRules(){return this.rules.join(`
|
|
83
|
-
`)}static newName(){let e=R2[A2]||1;return R2[A2]=e+1,Y0+e.toString(36)}static mount(e,n,r){let i=e[F0],a=r&&r.nonce;i?a&&i.setNonce(a):i=new uq(e,a),i.mount(Array.isArray(n)?n:[n],e)}}let _2=new Map;class uq{constructor(e,n){let r=e.ownerDocument||e,i=r.defaultView;if(!e.head&&e.adoptedStyleSheets&&i.CSSStyleSheet){let a=_2.get(r);if(a)return e[F0]=a;this.sheet=new i.CSSStyleSheet,_2.set(r,this)}else this.styleTag=r.createElement("style"),n&&this.styleTag.setAttribute("nonce",n);this.modules=[],e[F0]=this}mount(e,n){let r=this.sheet,i=0,a=0;for(let o=0;o<e.length;o++){let c=e[o],u=this.modules.indexOf(c);if(u<a&&u>-1&&(this.modules.splice(u,1),a--,u=-1),u==-1){if(this.modules.splice(a++,0,c),r)for(let f=0;f<c.rules.length;f++)r.insertRule(c.rules[f],i++)}else{for(;a<u;)i+=this.modules[a++].rules.length;i+=c.rules.length,a++}}if(r)n.adoptedStyleSheets.indexOf(this.sheet)<0&&(n.adoptedStyleSheets=[this.sheet,...n.adoptedStyleSheets]);else{let o="";for(let u=0;u<this.modules.length;u++)o+=this.modules[u].getRules()+`
|
|
84
|
-
`;this.styleTag.textContent=o;let c=n.head||n;this.styleTag.parentNode!=c&&c.insertBefore(this.styleTag,c.firstChild)}}setNonce(e){this.styleTag&&this.styleTag.getAttribute("nonce")!=e&&this.styleTag.setAttribute("nonce",e)}}var qs={8:"Backspace",9:"Tab",10:"Enter",12:"NumLock",13:"Enter",16:"Shift",17:"Control",18:"Alt",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",44:"PrintScreen",45:"Insert",46:"Delete",59:";",61:"=",91:"Meta",92:"Meta",106:"*",107:"+",108:",",109:"-",110:".",111:"/",144:"NumLock",145:"ScrollLock",160:"Shift",161:"Shift",162:"Control",163:"Control",164:"Alt",165:"Alt",173:"-",186:";",187:"=",188:",",189:"-",190:".",191:"/",192:"`",219:"[",220:"\\",221:"]",222:"'"},kd={48:")",49:"!",50:"@",51:"#",52:"$",53:"%",54:"^",55:"&",56:"*",57:"(",59:":",61:"+",173:"_",186:":",187:"+",188:"<",189:"_",190:">",191:"?",192:"~",219:"{",220:"|",221:"}",222:'"'},dq=typeof navigator<"u"&&/Mac/.test(navigator.platform),fq=typeof navigator<"u"&&/MSIE \d|Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(navigator.userAgent);for(var In=0;In<10;In++)qs[48+In]=qs[96+In]=String(In);for(var In=1;In<=24;In++)qs[In+111]="F"+In;for(var In=65;In<=90;In++)qs[In]=String.fromCharCode(In+32),kd[In]=String.fromCharCode(In);for(var hy in qs)kd.hasOwnProperty(hy)||(kd[hy]=qs[hy]);function hq(t){var e=dq&&t.metaKey&&t.shiftKey&&!t.ctrlKey&&!t.altKey||fq&&t.shiftKey&&t.key&&t.key.length==1||t.key=="Unidentified",n=!e&&t.key||(t.shiftKey?kd:qs)[t.keyCode]||t.key||"Unidentified";return n=="Esc"&&(n="Escape"),n=="Del"&&(n="Delete"),n=="Left"&&(n="ArrowLeft"),n=="Up"&&(n="ArrowUp"),n=="Right"&&(n="ArrowRight"),n=="Down"&&(n="ArrowDown"),n}let sr=typeof navigator<"u"?navigator:{userAgent:"",vendor:"",platform:""},W0=typeof document<"u"?document:{documentElement:{style:{}}};const G0=/Edge\/(\d+)/.exec(sr.userAgent),hP=/MSIE \d/.test(sr.userAgent),H0=/Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(sr.userAgent),tg=!!(hP||H0||G0),$2=!tg&&/gecko\/(\d+)/i.test(sr.userAgent),py=!tg&&/Chrome\/(\d+)/.exec(sr.userAgent),pq="webkitFontSmoothing"in W0.documentElement.style,K0=!tg&&/Apple Computer/.test(sr.vendor),P2=K0&&(/Mobile\/\w+/.test(sr.userAgent)||sr.maxTouchPoints>2);var $e={mac:P2||/Mac/.test(sr.platform),windows:/Win/.test(sr.platform),linux:/Linux|X11/.test(sr.platform),ie:tg,ie_version:hP?W0.documentMode||6:H0?+H0[1]:G0?+G0[1]:0,gecko:$2,gecko_version:$2?+(/Firefox\/(\d+)/.exec(sr.userAgent)||[0,0])[1]:0,chrome:!!py,chrome_version:py?+py[1]:0,ios:P2,android:/Android\b/.test(sr.userAgent),webkit_version:pq?+(/\bAppleWebKit\/(\d+)/.exec(sr.userAgent)||[0,0])[1]:0,safari:K0,safari_version:K0?+(/\bVersion\/(\d+(\.\d+)?)/.exec(sr.userAgent)||[0,0])[1]:0,tabSize:W0.documentElement.style.tabSize!=null?"tab-size":"-moz-tab-size"};function Yx(t,e){for(let n in t)n=="class"&&e.class?e.class+=" "+t.class:n=="style"&&e.style?e.style+=";"+t.style:e[n]=t[n];return e}const qp=Object.create(null);function Fx(t,e,n){if(t==e)return!0;t||(t=qp),e||(e=qp);let r=Object.keys(t),i=Object.keys(e);if(r.length-0!=i.length-0)return!1;for(let a of r)if(a!=n&&(i.indexOf(a)==-1||t[a]!==e[a]))return!1;return!0}function mq(t,e){for(let n=t.attributes.length-1;n>=0;n--){let r=t.attributes[n].name;e[r]==null&&t.removeAttribute(r)}for(let n in e){let r=e[n];n=="style"?t.style.cssText=r:t.getAttribute(n)!=r&&t.setAttribute(n,r)}}function j2(t,e,n){let r=!1;if(e)for(let i in e)n&&i in n||(r=!0,i=="style"?t.style.cssText="":t.removeAttribute(i));if(n)for(let i in n)e&&e[i]==n[i]||(r=!0,i=="style"?t.style.cssText=n[i]:t.setAttribute(i,n[i]));return r}function gq(t){let e=Object.create(null);for(let n=0;n<t.attributes.length;n++){let r=t.attributes[n];e[r.name]=r.value}return e}class el{eq(e){return!1}updateDOM(e,n){return!1}compare(e){return this==e||this.constructor==e.constructor&&this.eq(e)}get estimatedHeight(){return-1}get lineBreaks(){return 0}ignoreEvent(e){return!0}coordsAt(e,n,r){return null}get isHidden(){return!1}get editable(){return!1}destroy(e){}}var Ar=(function(t){return t[t.Text=0]="Text",t[t.WidgetBefore=1]="WidgetBefore",t[t.WidgetAfter=2]="WidgetAfter",t[t.WidgetRange=3]="WidgetRange",t})(Ar||(Ar={}));class dt extends Bs{constructor(e,n,r,i){super(),this.startSide=e,this.endSide=n,this.widget=r,this.spec=i}get heightRelevant(){return!1}static mark(e){return new sf(e)}static widget(e){let n=Math.max(-1e4,Math.min(1e4,e.side||0)),r=!!e.block;return n+=r&&!e.inlineOrder?n>0?3e8:-4e8:n>0?1e8:-1e8,new qo(e,n,n,r,e.widget||null,!1)}static replace(e){let n=!!e.block,r,i;if(e.isBlockGap)r=-5e8,i=4e8;else{let{start:a,end:o}=pP(e,n);r=(a?n?-3e8:-1:5e8)-1,i=(o?n?2e8:1:-6e8)+1}return new qo(e,r,i,n,e.widget||null,!0)}static line(e){return new of(e)}static set(e,n=!1){return xt.of(e,n)}hasHeight(){return this.widget?this.widget.estimatedHeight>-1:!1}}dt.none=xt.empty;class sf extends dt{constructor(e){let{start:n,end:r}=pP(e);super(n?-1:5e8,r?1:-6e8,null,e),this.tagName=e.tagName||"span",this.attrs=e.class&&e.attributes?Yx(e.attributes,{class:e.class}):e.class?{class:e.class}:e.attributes||qp}eq(e){return this==e||e instanceof sf&&this.tagName==e.tagName&&Fx(this.attrs,e.attrs)}range(e,n=e){if(e>=n)throw new RangeError("Mark decorations may not be empty");return super.range(e,n)}}sf.prototype.point=!1;class of extends dt{constructor(e){super(-2e8,-2e8,null,e)}eq(e){return e instanceof of&&this.spec.class==e.spec.class&&Fx(this.spec.attributes,e.spec.attributes)}range(e,n=e){if(n!=e)throw new RangeError("Line decoration ranges must be zero-length");return super.range(e,n)}}of.prototype.mapMode=Hn.TrackBefore;of.prototype.point=!0;class qo extends dt{constructor(e,n,r,i,a,o){super(n,r,a,e),this.block=i,this.isReplace=o,this.mapMode=i?n<=0?Hn.TrackBefore:Hn.TrackAfter:Hn.TrackDel}get type(){return this.startSide!=this.endSide?Ar.WidgetRange:this.startSide<=0?Ar.WidgetBefore:Ar.WidgetAfter}get heightRelevant(){return this.block||!!this.widget&&(this.widget.estimatedHeight>=5||this.widget.lineBreaks>0)}eq(e){return e instanceof qo&&Oq(this.widget,e.widget)&&this.block==e.block&&this.startSide==e.startSide&&this.endSide==e.endSide}range(e,n=e){if(this.isReplace&&(e>n||e==n&&this.startSide>0&&this.endSide<=0))throw new RangeError("Invalid range for replacement decoration");if(!this.isReplace&&n!=e)throw new RangeError("Widget decorations can only have zero-length ranges");return super.range(e,n)}}qo.prototype.point=!0;function pP(t,e=!1){let{inclusiveStart:n,inclusiveEnd:r}=t;return n==null&&(n=t.inclusive),r==null&&(r=t.inclusive),{start:n??e,end:r??e}}function Oq(t,e){return t==e||!!(t&&e&&t.compare(e))}function oc(t,e,n,r=0){let i=n.length-1;i>=0&&n[i]+r>=t?n[i]=Math.max(n[i],e):n.push(t,e)}class Cd extends Bs{constructor(e,n){super(),this.tagName=e,this.attributes=n}eq(e){return e==this||e instanceof Cd&&this.tagName==e.tagName&&Fx(this.attributes,e.attributes)}static create(e){return new Cd(e.tagName,e.attributes||qp)}static set(e,n=!1){return xt.of(e,n)}}Cd.prototype.startSide=Cd.prototype.endSide=-1;function Td(t){let e;return t.nodeType==11?e=t.getSelection?t:t.ownerDocument:e=t,e.getSelection()}function J0(t,e){return e?t==e||t.contains(e.nodeType!=1?e.parentNode:e):!1}function yp(t,e){if(!e.anchorNode)return!1;try{return J0(t,e.anchorNode)}catch{return!1}}function bp(t){return t.nodeType==3?Ed(t,0,t.nodeValue.length).getClientRects():t.nodeType==1?t.getClientRects():[]}function ud(t,e,n,r){return n?M2(t,e,n,r,-1)||M2(t,e,n,r,1):!1}function Us(t){for(var e=0;;e++)if(t=t.previousSibling,!t)return e}function Up(t){return t.nodeType==1&&/^(DIV|P|LI|UL|OL|BLOCKQUOTE|DD|DT|H\d|SECTION|PRE)$/.test(t.nodeName)}function M2(t,e,n,r,i){for(;;){if(t==n&&e==r)return!0;if(e==(i<0?0:Ka(t))){if(t.nodeName=="DIV")return!1;let a=t.parentNode;if(!a||a.nodeType!=1)return!1;e=Us(t)+(i<0?0:1),t=a}else if(t.nodeType==1){if(t=t.childNodes[e+(i<0?-1:0)],t.nodeType==1&&t.contentEditable=="false")return!1;e=i<0?Ka(t):0}else return!1}}function Ka(t){return t.nodeType==3?t.nodeValue.length:t.childNodes.length}function Yp(t,e){let n=e?t.left:t.right;return{left:n,right:n,top:t.top,bottom:t.bottom}}function vq(t){let e=t.visualViewport;return e?{left:0,right:e.width,top:0,bottom:e.height}:{left:0,right:t.innerWidth,top:0,bottom:t.innerHeight}}function mP(t,e){let n=e.width/t.offsetWidth,r=e.height/t.offsetHeight;return(n>.995&&n<1.005||!isFinite(n)||Math.abs(e.width-t.offsetWidth)<1)&&(n=1),(r>.995&&r<1.005||!isFinite(r)||Math.abs(e.height-t.offsetHeight)<1)&&(r=1),{scaleX:n,scaleY:r}}function yq(t,e,n,r,i,a,o,c){let u=t.ownerDocument,f=u.defaultView||window;for(let h=t,m=!1;h&&!m;)if(h.nodeType==1){let g,y=h==u.body,x=1,S=1;if(y)g=vq(f);else{if(/^(fixed|sticky)$/.test(getComputedStyle(h).position)&&(m=!0),h.scrollHeight<=h.clientHeight&&h.scrollWidth<=h.clientWidth){h=h.assignedSlot||h.parentNode;continue}let C=h.getBoundingClientRect();({scaleX:x,scaleY:S}=mP(h,C)),g={left:C.left,right:C.left+h.clientWidth*x,top:C.top,bottom:C.top+h.clientHeight*S}}let k=0,T=0;if(i=="nearest")e.top<g.top?(T=e.top-(g.top+o),n>0&&e.bottom>g.bottom+T&&(T=e.bottom-g.bottom+o)):e.bottom>g.bottom&&(T=e.bottom-g.bottom+o,n<0&&e.top-T<g.top&&(T=e.top-(g.top+o)));else{let C=e.bottom-e.top,E=g.bottom-g.top;T=(i=="center"&&C<=E?e.top+C/2-E/2:i=="start"||i=="center"&&n<0?e.top-o:e.bottom-E+o)-g.top}if(r=="nearest"?e.left<g.left?(k=e.left-(g.left+a),n>0&&e.right>g.right+k&&(k=e.right-g.right+a)):e.right>g.right&&(k=e.right-g.right+a,n<0&&e.left<g.left+k&&(k=e.left-(g.left+a))):k=(r=="center"?e.left+(e.right-e.left)/2-(g.right-g.left)/2:r=="start"==c?e.left-a:e.right-(g.right-g.left)+a)-g.left,k||T)if(y)f.scrollBy(k,T);else{let C=0,E=0;if(T){let R=h.scrollTop;h.scrollTop+=T/S,E=(h.scrollTop-R)*S}if(k){let R=h.scrollLeft;h.scrollLeft+=k/x,C=(h.scrollLeft-R)*x}e={left:e.left-C,top:e.top-E,right:e.right-C,bottom:e.bottom-E},C&&Math.abs(C-k)<1&&(r="nearest"),E&&Math.abs(E-T)<1&&(i="nearest")}if(y)break;(e.top<g.top||e.bottom>g.bottom||e.left<g.left||e.right>g.right)&&(e={left:Math.max(e.left,g.left),right:Math.min(e.right,g.right),top:Math.max(e.top,g.top),bottom:Math.min(e.bottom,g.bottom)}),h=h.assignedSlot||h.parentNode}else if(h.nodeType==11)h=h.host;else break}function bq(t){let e=t.ownerDocument,n,r;for(let i=t.parentNode;i&&!(i==e.body||n&&r);)if(i.nodeType==1)!r&&i.scrollHeight>i.clientHeight&&(r=i),!n&&i.scrollWidth>i.clientWidth&&(n=i),i=i.assignedSlot||i.parentNode;else if(i.nodeType==11)i=i.host;else break;return{x:n,y:r}}class xq{constructor(){this.anchorNode=null,this.anchorOffset=0,this.focusNode=null,this.focusOffset=0}eq(e){return this.anchorNode==e.anchorNode&&this.anchorOffset==e.anchorOffset&&this.focusNode==e.focusNode&&this.focusOffset==e.focusOffset}setRange(e){let{anchorNode:n,focusNode:r}=e;this.set(n,Math.min(e.anchorOffset,n?Ka(n):0),r,Math.min(e.focusOffset,r?Ka(r):0))}set(e,n,r,i){this.anchorNode=e,this.anchorOffset=n,this.focusNode=r,this.focusOffset=i}}let ko=null;$e.safari&&$e.safari_version>=26&&(ko=!1);function gP(t){if(t.setActive)return t.setActive();if(ko)return t.focus(ko);let e=[];for(let n=t;n&&(e.push(n,n.scrollTop,n.scrollLeft),n!=n.ownerDocument);n=n.parentNode);if(t.focus(ko==null?{get preventScroll(){return ko={preventScroll:!0},!0}}:void 0),!ko){ko=!1;for(let n=0;n<e.length;){let r=e[n++],i=e[n++],a=e[n++];r.scrollTop!=i&&(r.scrollTop=i),r.scrollLeft!=a&&(r.scrollLeft=a)}}}let N2;function Ed(t,e,n=e){let r=N2||(N2=document.createRange());return r.setEnd(t,n),r.setStart(t,e),r}function lc(t,e,n,r){let i={key:e,code:e,keyCode:n,which:n,cancelable:!0};r&&({altKey:i.altKey,ctrlKey:i.ctrlKey,shiftKey:i.shiftKey,metaKey:i.metaKey}=r);let a=new KeyboardEvent("keydown",i);a.synthetic=!0,t.dispatchEvent(a);let o=new KeyboardEvent("keyup",i);return o.synthetic=!0,t.dispatchEvent(o),a.defaultPrevented||o.defaultPrevented}function Sq(t){for(;t;){if(t&&(t.nodeType==9||t.nodeType==11&&t.host))return t;t=t.assignedSlot||t.parentNode}return null}function wq(t,e){let n=e.focusNode,r=e.focusOffset;if(!n||e.anchorNode!=n||e.anchorOffset!=r)return!1;for(r=Math.min(r,Ka(n));;)if(r){if(n.nodeType!=1)return!1;let i=n.childNodes[r-1];i.contentEditable=="false"?r--:(n=i,r=Ka(n))}else{if(n==t)return!0;r=Us(n),n=n.parentNode}}function OP(t){return t.scrollTop>Math.max(1,t.scrollHeight-t.clientHeight-4)}function vP(t,e){for(let n=t,r=e;;){if(n.nodeType==3&&r>0)return{node:n,offset:r};if(n.nodeType==1&&r>0){if(n.contentEditable=="false")return null;n=n.childNodes[r-1],r=Ka(n)}else if(n.parentNode&&!Up(n))r=Us(n),n=n.parentNode;else return null}}function yP(t,e){for(let n=t,r=e;;){if(n.nodeType==3&&r<n.nodeValue.length)return{node:n,offset:r};if(n.nodeType==1&&r<n.childNodes.length){if(n.contentEditable=="false")return null;n=n.childNodes[r],r=0}else if(n.parentNode&&!Up(n))r=Us(n)+1,n=n.parentNode;else return null}}class Ti{constructor(e,n,r=!0){this.node=e,this.offset=n,this.precise=r}static before(e,n){return new Ti(e.parentNode,Us(e),n)}static after(e,n){return new Ti(e.parentNode,Us(e)+1,n)}}var dn=(function(t){return t[t.LTR=0]="LTR",t[t.RTL=1]="RTL",t})(dn||(dn={}));const Uo=dn.LTR,Wx=dn.RTL;function bP(t){let e=[];for(let n=0;n<t.length;n++)e.push(1<<+t[n]);return e}const kq=bP("88888888888888888888888888888888888666888888787833333333337888888000000000000000000000000008888880000000000000000000000000088888888888888888888888888888888888887866668888088888663380888308888800000000000000000000000800000000000000000000000000000008"),Cq=bP("4444448826627288999999999992222222222222222222222222222222222222222222222229999999999999999999994444444444644222822222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222999999949999999229989999223333333333"),eb=Object.create(null),Fi=[];for(let t of["()","[]","{}"]){let e=t.charCodeAt(0),n=t.charCodeAt(1);eb[e]=n,eb[n]=-e}function xP(t){return t<=247?kq[t]:1424<=t&&t<=1524?2:1536<=t&&t<=1785?Cq[t-1536]:1774<=t&&t<=2220?4:8192<=t&&t<=8204?256:64336<=t&&t<=65023?4:1}const Tq=/[\u0590-\u05f4\u0600-\u06ff\u0700-\u08ac\ufb50-\ufdff]/;class Va{get dir(){return this.level%2?Wx:Uo}constructor(e,n,r){this.from=e,this.to=n,this.level=r}side(e,n){return this.dir==n==e?this.to:this.from}forward(e,n){return e==(this.dir==n)}static find(e,n,r,i){let a=-1;for(let o=0;o<e.length;o++){let c=e[o];if(c.from<=n&&c.to>=n){if(c.level==r)return o;(a<0||(i!=0?i<0?c.from<n:c.to>n:e[a].level>c.level))&&(a=o)}}if(a<0)throw new RangeError("Index out of range");return a}}function SP(t,e){if(t.length!=e.length)return!1;for(let n=0;n<t.length;n++){let r=t[n],i=e[n];if(r.from!=i.from||r.to!=i.to||r.direction!=i.direction||!SP(r.inner,i.inner))return!1}return!0}const It=[];function Eq(t,e,n,r,i){for(let a=0;a<=r.length;a++){let o=a?r[a-1].to:e,c=a<r.length?r[a].from:n,u=a?256:i;for(let f=o,h=u,m=u;f<c;f++){let g=xP(t.charCodeAt(f));g==512?g=h:g==8&&m==4&&(g=16),It[f]=g==4?2:g,g&7&&(m=g),h=g}for(let f=o,h=u,m=u;f<c;f++){let g=It[f];if(g==128)f<c-1&&h==It[f+1]&&h&24?g=It[f]=h:It[f]=256;else if(g==64){let y=f+1;for(;y<c&&It[y]==64;)y++;let x=f&&h==8||y<n&&It[y]==8?m==1?1:8:256;for(let S=f;S<y;S++)It[S]=x;f=y-1}else g==8&&m==1&&(It[f]=1);h=g,g&7&&(m=g)}}}function Qq(t,e,n,r,i){let a=i==1?2:1;for(let o=0,c=0,u=0;o<=r.length;o++){let f=o?r[o-1].to:e,h=o<r.length?r[o].from:n;for(let m=f,g,y,x;m<h;m++)if(y=eb[g=t.charCodeAt(m)])if(y<0){for(let S=c-3;S>=0;S-=3)if(Fi[S+1]==-y){let k=Fi[S+2],T=k&2?i:k&4?k&1?a:i:0;T&&(It[m]=It[Fi[S]]=T),c=S;break}}else{if(Fi.length==189)break;Fi[c++]=m,Fi[c++]=g,Fi[c++]=u}else if((x=It[m])==2||x==1){let S=x==i;u=S?0:1;for(let k=c-3;k>=0;k-=3){let T=Fi[k+2];if(T&2)break;if(S)Fi[k+2]|=2;else{if(T&4)break;Fi[k+2]|=4}}}}}function Aq(t,e,n,r){for(let i=0,a=r;i<=n.length;i++){let o=i?n[i-1].to:t,c=i<n.length?n[i].from:e;for(let u=o;u<c;){let f=It[u];if(f==256){let h=u+1;for(;;)if(h==c){if(i==n.length)break;h=n[i++].to,c=i<n.length?n[i].from:e}else if(It[h]==256)h++;else break;let m=a==1,g=(h<e?It[h]:r)==1,y=m==g?m?1:2:r;for(let x=h,S=i,k=S?n[S-1].to:t;x>u;)x==k&&(x=n[--S].from,k=S?n[S-1].to:t),It[--x]=y;u=h}else a=f,u++}}}function tb(t,e,n,r,i,a,o){let c=r%2?2:1;if(r%2==i%2)for(let u=e,f=0;u<n;){let h=!0,m=!1;if(f==a.length||u<a[f].from){let S=It[u];S!=c&&(h=!1,m=S==16)}let g=!h&&c==1?[]:null,y=h?r:r+1,x=u;e:for(;;)if(f<a.length&&x==a[f].from){if(m)break e;let S=a[f];if(!h)for(let k=S.to,T=f+1;;){if(k==n)break e;if(T<a.length&&a[T].from==k)k=a[T++].to;else{if(It[k]==c)break e;break}}if(f++,g)g.push(S);else{S.from>u&&o.push(new Va(u,S.from,y));let k=S.direction==Uo!=!(y%2);nb(t,k?r+1:r,i,S.inner,S.from,S.to,o),u=S.to}x=S.to}else{if(x==n||(h?It[x]!=c:It[x]==c))break;x++}g?tb(t,u,x,r+1,i,g,o):u<x&&o.push(new Va(u,x,y)),u=x}else for(let u=n,f=a.length;u>e;){let h=!0,m=!1;if(!f||u>a[f-1].to){let S=It[u-1];S!=c&&(h=!1,m=S==16)}let g=!h&&c==1?[]:null,y=h?r:r+1,x=u;e:for(;;)if(f&&x==a[f-1].to){if(m)break e;let S=a[--f];if(!h)for(let k=S.from,T=f;;){if(k==e)break e;if(T&&a[T-1].to==k)k=a[--T].from;else{if(It[k-1]==c)break e;break}}if(g)g.push(S);else{S.to<u&&o.push(new Va(S.to,u,y));let k=S.direction==Uo!=!(y%2);nb(t,k?r+1:r,i,S.inner,S.from,S.to,o),u=S.from}x=S.from}else{if(x==e||(h?It[x-1]!=c:It[x-1]==c))break;x--}g?tb(t,x,u,r+1,i,g,o):x<u&&o.push(new Va(x,u,y)),u=x}}function nb(t,e,n,r,i,a,o){let c=e%2?2:1;Eq(t,i,a,r,c),Qq(t,i,a,r,c),Aq(i,a,r,c),tb(t,i,a,e,n,r,o)}function Rq(t,e,n){if(!t)return[new Va(0,0,e==Wx?1:0)];if(e==Uo&&!n.length&&!Tq.test(t))return wP(t.length);if(n.length)for(;t.length>It.length;)It[It.length]=256;let r=[],i=e==Uo?0:1;return nb(t,i,i,n,0,t.length,r),r}function wP(t){return[new Va(0,t,0)]}let kP="";function _q(t,e,n,r,i){var a;let o=r.head-t.from,c=Va.find(e,o,(a=r.bidiLevel)!==null&&a!==void 0?a:-1,r.assoc),u=e[c],f=u.side(i,n);if(o==f){let g=c+=i?1:-1;if(g<0||g>=e.length)return null;u=e[c=g],o=u.side(!i,n),f=u.side(i,n)}let h=qn(t.text,o,u.forward(i,n));(h<u.from||h>u.to)&&(h=f),kP=t.text.slice(Math.min(o,h),Math.max(o,h));let m=c==(i?e.length-1:0)?null:e[c+(i?1:-1)];return m&&h==f&&m.level+(i?0:1)<u.level?Se.cursor(m.side(!i,n)+t.from,m.forward(i,n)?1:-1,m.level):Se.cursor(h+t.from,u.forward(i,n)?-1:1,u.level)}function $q(t,e,n){for(let r=e;r<n;r++){let i=xP(t.charCodeAt(r));if(i==1)return Uo;if(i==2||i==4)return Wx}return Uo}const CP=Xe.define(),TP=Xe.define(),EP=Xe.define(),QP=Xe.define(),rb=Xe.define(),AP=Xe.define(),RP=Xe.define(),Gx=Xe.define(),Hx=Xe.define(),_P=Xe.define({combine:t=>t.some(e=>e)}),Pq=Xe.define({combine:t=>t.some(e=>e)}),$P=Xe.define();class cc{constructor(e,n="nearest",r="nearest",i=5,a=5,o=!1){this.range=e,this.y=n,this.x=r,this.yMargin=i,this.xMargin=a,this.isSnapshot=o}map(e){return e.empty?this:new cc(this.range.map(e),this.y,this.x,this.yMargin,this.xMargin,this.isSnapshot)}clip(e){return this.range.to<=e.doc.length?this:new cc(Se.cursor(e.doc.length),this.y,this.x,this.yMargin,this.xMargin,this.isSnapshot)}}const Vh=Vt.define({map:(t,e)=>t.map(e)}),PP=Vt.define();function aa(t,e,n){let r=t.facet(QP);r.length?r[0](e):window.onerror&&window.onerror(String(e),n,void 0,void 0,e)||(n?console.error(n+":",e):console.error(e))}const Za=Xe.define({combine:t=>t.length?t[0]:!0});let jq=0;const Jl=Xe.define({combine(t){return t.filter((e,n)=>{for(let r=0;r<n;r++)if(t[r].plugin==e.plugin)return!1;return!0})}});class ci{constructor(e,n,r,i,a){this.id=e,this.create=n,this.domEventHandlers=r,this.domEventObservers=i,this.baseExtensions=a(this),this.extension=this.baseExtensions.concat(Jl.of({plugin:this,arg:void 0}))}of(e){return this.baseExtensions.concat(Jl.of({plugin:this,arg:e}))}static define(e,n){const{eventHandlers:r,eventObservers:i,provide:a,decorations:o}=n||{};return new ci(jq++,e,r,i,c=>{let u=[];return o&&u.push(Qd.of(f=>{let h=f.plugin(c);return h?o(h):dt.none})),a&&u.push(a(c)),u})}static fromClass(e,n){return ci.define((r,i)=>new e(r,i),n)}}class my{constructor(e){this.spec=e,this.mustUpdate=null,this.value=null}get plugin(){return this.spec&&this.spec.plugin}update(e){if(this.value){if(this.mustUpdate){let n=this.mustUpdate;if(this.mustUpdate=null,this.value.update)try{this.value.update(n)}catch(r){if(aa(n.state,r,"CodeMirror plugin crashed"),this.value.destroy)try{this.value.destroy()}catch{}this.deactivate()}}}else if(this.spec)try{this.value=this.spec.plugin.create(e,this.spec.arg)}catch(n){aa(e.state,n,"CodeMirror plugin crashed"),this.deactivate()}return this}destroy(e){var n;if(!((n=this.value)===null||n===void 0)&&n.destroy)try{this.value.destroy()}catch(r){aa(e.state,r,"CodeMirror plugin crashed")}}deactivate(){this.spec=this.value=null}}const jP=Xe.define(),Kx=Xe.define(),Qd=Xe.define(),MP=Xe.define(),NP=Xe.define(),lf=Xe.define(),DP=Xe.define();function D2(t,e){let n=t.state.facet(DP);if(!n.length)return n;let r=n.map(a=>a instanceof Function?a(t):a),i=[];return xt.spans(r,e.from,e.to,{point(){},span(a,o,c,u){let f=a-e.from,h=o-e.from,m=i;for(let g=c.length-1;g>=0;g--,u--){let y=c[g].spec.bidiIsolate,x;if(y==null&&(y=$q(e.text,f,h)),u>0&&m.length&&(x=m[m.length-1]).to==f&&x.direction==y)x.to=h,m=x.inner;else{let S={from:f,to:h,direction:y,inner:[]};m.push(S),m=S.inner}}}}),i}const zP=Xe.define();function LP(t){let e=0,n=0,r=0,i=0;for(let a of t.state.facet(zP)){let o=a(t);o&&(o.left!=null&&(e=Math.max(e,o.left)),o.right!=null&&(n=Math.max(n,o.right)),o.top!=null&&(r=Math.max(r,o.top)),o.bottom!=null&&(i=Math.max(i,o.bottom)))}return{left:e,right:n,top:r,bottom:i}}const nd=Xe.define();class ai{constructor(e,n,r,i){this.fromA=e,this.toA=n,this.fromB=r,this.toB=i}join(e){return new ai(Math.min(this.fromA,e.fromA),Math.max(this.toA,e.toA),Math.min(this.fromB,e.fromB),Math.max(this.toB,e.toB))}addToSet(e){let n=e.length,r=this;for(;n>0;n--){let i=e[n-1];if(!(i.fromA>r.toA)){if(i.toA<r.fromA)break;r=r.join(i),e.splice(n-1,1)}}return e.splice(n,0,r),e}static extendWithRanges(e,n){if(n.length==0)return e;let r=[];for(let i=0,a=0,o=0;;){let c=i<e.length?e[i].fromB:1e9,u=a<n.length?n[a]:1e9,f=Math.min(c,u);if(f==1e9)break;let h=f+o,m=f,g=h;for(;;)if(a<n.length&&n[a]<=m){let y=n[a+1];a+=2,m=Math.max(m,y);for(let x=i;x<e.length&&e[x].fromB<=m;x++)o=e[x].toA-e[x].toB;g=Math.max(g,y+o)}else if(i<e.length&&e[i].fromB<=m){let y=e[i++];m=Math.max(m,y.toB),g=Math.max(g,y.toA),o=y.toA-y.toB}else break;r.push(new ai(h,g,f,m))}return r}}class Fp{constructor(e,n,r){this.view=e,this.state=n,this.transactions=r,this.flags=0,this.startState=e.state,this.changes=Qn.empty(this.startState.doc.length);for(let a of r)this.changes=this.changes.compose(a.changes);let i=[];this.changes.iterChangedRanges((a,o,c,u)=>i.push(new ai(a,o,c,u))),this.changedRanges=i}static create(e,n,r){return new Fp(e,n,r)}get viewportChanged(){return(this.flags&4)>0}get viewportMoved(){return(this.flags&8)>0}get heightChanged(){return(this.flags&2)>0}get geometryChanged(){return this.docChanged||(this.flags&18)>0}get focusChanged(){return(this.flags&1)>0}get docChanged(){return!this.changes.empty}get selectionSet(){return this.transactions.some(e=>e.selection)}get empty(){return this.flags==0&&this.transactions.length==0}}const Mq=[];class Rn{constructor(e,n,r=0){this.dom=e,this.length=n,this.flags=r,this.parent=null,e.cmTile=this}get breakAfter(){return this.flags&1}get children(){return Mq}isWidget(){return!1}get isHidden(){return!1}isComposite(){return!1}isLine(){return!1}isText(){return!1}isBlock(){return!1}get domAttrs(){return null}sync(e){if(this.flags|=2,this.flags&4){this.flags&=-5;let n=this.domAttrs;n&&mq(this.dom,n)}}toString(){return this.constructor.name+(this.children.length?`(${this.children})`:"")+(this.breakAfter?"#":"")}destroy(){this.parent=null}setDOM(e){this.dom=e,e.cmTile=this}get posAtStart(){return this.parent?this.parent.posBefore(this):0}get posAtEnd(){return this.posAtStart+this.length}posBefore(e,n=this.posAtStart){let r=n;for(let i of this.children){if(i==e)return r;r+=i.length+i.breakAfter}throw new RangeError("Invalid child in posBefore")}posAfter(e){return this.posBefore(e)+e.length}covers(e){return!0}coordsIn(e,n){return null}domPosFor(e,n){let r=Us(this.dom),i=this.length?e>0:n>0;return new Ti(this.parent.dom,r+(i?1:0),e==0||e==this.length)}markDirty(e){this.flags&=-3,e&&(this.flags|=4),this.parent&&this.parent.flags&2&&this.parent.markDirty(!1)}get overrideDOMText(){return null}get root(){for(let e=this;e;e=e.parent)if(e instanceof rg)return e;return null}static get(e){return e.cmTile}}class ng extends Rn{constructor(e){super(e,0),this._children=[]}isComposite(){return!0}get children(){return this._children}get lastChild(){return this.children.length?this.children[this.children.length-1]:null}append(e){this.children.push(e),e.parent=this}sync(e){if(this.flags&2)return;super.sync(e);let n=this.dom,r=null,i,a=e?.node==n?e:null,o=0;for(let c of this.children){if(c.sync(e),o+=c.length+c.breakAfter,i=r?r.nextSibling:n.firstChild,a&&i!=c.dom&&(a.written=!0),c.dom.parentNode==n)for(;i&&i!=c.dom;)i=z2(i);else n.insertBefore(c.dom,i);r=c.dom}for(i=r?r.nextSibling:n.firstChild,a&&i&&(a.written=!0);i;)i=z2(i);this.length=o}}function z2(t){let e=t.nextSibling;return t.parentNode.removeChild(t),e}class rg extends ng{constructor(e,n){super(n),this.view=e}owns(e){for(;e;e=e.parent)if(e==this)return!0;return!1}isBlock(){return!0}nearest(e){for(;;){if(!e)return null;let n=Rn.get(e);if(n&&this.owns(n))return n;e=e.parentNode}}blockTiles(e){for(let n=[],r=this,i=0,a=0;;)if(i==r.children.length){if(!n.length)return;r=r.parent,r.breakAfter&&a++,i=n.pop()}else{let o=r.children[i++];if(o instanceof Ds)n.push(i),r=o,i=0;else{let c=a+o.length,u=e(o,a);if(u!==void 0)return u;a=c+o.breakAfter}}}resolveBlock(e,n){let r,i=-1,a,o=-1;if(this.blockTiles((c,u)=>{let f=u+c.length;if(e>=u&&e<=f){if(c.isWidget()&&n>=-1&&n<=1){if(c.flags&32)return!0;c.flags&16&&(r=void 0)}(u<e||e==f&&(n<-1?c.length:c.covers(1)))&&(!r||!c.isWidget()&&r.isWidget())&&(r=c,i=e-u),(f>e||e==u&&(n>1?c.length:c.covers(-1)))&&(!a||!c.isWidget()&&a.isWidget())&&(a=c,o=e-u)}}),!r&&!a)throw new Error("No tile at position "+e);return r&&n<0||!a?{tile:r,offset:i}:{tile:a,offset:o}}}class Ds extends ng{constructor(e,n){super(e),this.wrapper=n}isBlock(){return!0}covers(e){return this.children.length?e<0?this.children[0].covers(-1):this.lastChild.covers(1):!1}get domAttrs(){return this.wrapper.attributes}static of(e,n){let r=new Ds(n||document.createElement(e.tagName),e);return n||(r.flags|=4),r}}class vc extends ng{constructor(e,n){super(e),this.attrs=n}isLine(){return!0}static start(e,n,r){let i=new vc(n||document.createElement("div"),e);return(!n||!r)&&(i.flags|=4),i}get domAttrs(){return this.attrs}resolveInline(e,n,r){let i=null,a=-1,o=null,c=-1;function u(h,m){for(let g=0,y=0;g<h.children.length&&y<=m;g++){let x=h.children[g],S=y+x.length;S>=m&&(x.isComposite()?u(x,m-y):(!o||o.isHidden&&(n>0||r&&Dq(o,x)))&&(S>m||x.flags&32)?(o=x,c=m-y):(y<m||x.flags&16&&!x.isHidden)&&(i=x,a=m-y)),y=S}}u(this,e);let f=(n<0?i:o)||i||o;return f?{tile:f,offset:f==i?a:c}:null}coordsIn(e,n){let r=this.resolveInline(e,n,!0);return r?r.tile.coordsIn(Math.max(0,r.offset),n):Nq(this)}domIn(e,n){let r=this.resolveInline(e,n);if(r){let{tile:i,offset:a}=r;if(this.dom.contains(i.dom))return i.isText()?new Ti(i.dom,Math.min(i.dom.nodeValue.length,a)):i.domPosFor(a,i.flags&16?1:i.flags&32?-1:n);let o=r.tile.parent,c=!1;for(let u of o.children){if(c)return new Ti(u.dom,0);u==r.tile&&(c=!0)}}return new Ti(this.dom,0)}}function Nq(t){let e=t.dom.lastChild;if(!e)return t.dom.getBoundingClientRect();let n=bp(e);return n[n.length-1]||null}function Dq(t,e){let n=t.coordsIn(0,1),r=e.coordsIn(0,1);return n&&r&&r.top<n.bottom}class Cr extends ng{constructor(e,n){super(e),this.mark=n}get domAttrs(){return this.mark.attrs}static of(e,n){let r=new Cr(n||document.createElement(e.tagName),e);return n||(r.flags|=4),r}}class Ro extends Rn{constructor(e,n){super(e,n.length),this.text=n}sync(e){this.flags&2||(super.sync(e),this.dom.nodeValue!=this.text&&(e&&e.node==this.dom&&(e.written=!0),this.dom.nodeValue=this.text))}isText(){return!0}toString(){return JSON.stringify(this.text)}coordsIn(e,n){let r=this.dom.nodeValue.length;e>r&&(e=r);let i=e,a=e,o=0;e==0&&n<0||e==r&&n>=0?$e.chrome||$e.gecko||(e?(i--,o=1):a<r&&(a++,o=-1)):n<0?i--:a<r&&a++;let c=Ed(this.dom,i,a).getClientRects();if(!c.length)return null;let u=c[(o?o<0:n>=0)?0:c.length-1];return $e.safari&&!o&&u.width==0&&(u=Array.prototype.find.call(c,f=>f.width)||u),o?Yp(u,o<0):u||null}static of(e,n){let r=new Ro(n||document.createTextNode(e),e);return n||(r.flags|=2),r}}class yc extends Rn{constructor(e,n,r,i){super(e,n,i),this.widget=r}isWidget(){return!0}get isHidden(){return this.widget.isHidden}covers(e){return this.flags&48?!1:(this.flags&(e<0?64:128))>0}coordsIn(e,n){return this.coordsInWidget(e,n,!1)}coordsInWidget(e,n,r){let i=this.widget.coordsAt(this.dom,e,n);if(i)return i;if(r)return Yp(this.dom.getBoundingClientRect(),this.length?e==0:n<=0);{let a=this.dom.getClientRects(),o=null;if(!a.length)return null;let c=this.flags&16?!0:this.flags&32?!1:e>0;for(let u=c?a.length-1:0;o=a[u],!(e>0?u==0:u==a.length-1||o.top<o.bottom);u+=c?-1:1);return Yp(o,!c)}}get overrideDOMText(){if(!this.length)return St.empty;let{root:e}=this;if(!e)return St.empty;let n=this.posAtStart;return e.view.state.doc.slice(n,n+this.length)}destroy(){super.destroy(),this.widget.destroy(this.dom)}static of(e,n,r,i,a){return a||(a=e.toDOM(n),e.editable||(a.contentEditable="false")),new yc(a,r,e,i)}}class Wp extends Rn{constructor(e){let n=document.createElement("img");n.className="cm-widgetBuffer",n.setAttribute("aria-hidden","true"),super(n,0,e)}get isHidden(){return!1}get overrideDOMText(){return St.empty}coordsIn(e){return this.dom.getBoundingClientRect()}}class zq{constructor(e){this.index=0,this.beforeBreak=!1,this.parents=[],this.tile=e}advance(e,n,r){let{tile:i,index:a,beforeBreak:o,parents:c}=this;for(;e||n>0;)if(i.isComposite())if(o){if(!e)break;r&&r.break(),e--,o=!1}else if(a==i.children.length){if(!e&&!c.length)break;r&&r.leave(i),o=!!i.breakAfter,{tile:i,index:a}=c.pop(),a++}else{let u=i.children[a],f=u.breakAfter;(n>0?u.length<=e:u.length<e)&&(!r||r.skip(u,0,u.length)!==!1||!u.isComposite)?(o=!!f,a++,e-=u.length):(c.push({tile:i,index:a}),i=u,a=0,r&&u.isComposite()&&r.enter(u))}else if(a==i.length)o=!!i.breakAfter,{tile:i,index:a}=c.pop(),a++;else if(e){let u=Math.min(e,i.length-a);r&&r.skip(i,a,a+u),e-=u,a+=u}else break;return this.tile=i,this.index=a,this.beforeBreak=o,this}get root(){return this.parents.length?this.parents[0].tile:this.tile}}class Lq{constructor(e,n,r,i){this.from=e,this.to=n,this.wrapper=r,this.rank=i}}class Zq{constructor(e,n,r){this.cache=e,this.root=n,this.blockWrappers=r,this.curLine=null,this.lastBlock=null,this.afterWidget=null,this.pos=0,this.wrappers=[],this.wrapperPos=0}addText(e,n,r,i){var a;this.flushBuffer();let o=this.ensureMarks(n,r),c=o.lastChild;if(c&&c.isText()&&!(c.flags&8)){this.cache.reused.set(c,2);let u=o.children[o.children.length-1]=new Ro(c.dom,c.text+e);u.parent=o}else o.append(i||Ro.of(e,(a=this.cache.find(Ro))===null||a===void 0?void 0:a.dom));this.pos+=e.length,this.afterWidget=null}addComposition(e,n){let r=this.curLine;r.dom!=n.line.dom&&(r.setDOM(this.cache.reused.has(n.line)?gy(n.line.dom):n.line.dom),this.cache.reused.set(n.line,2));let i=r;for(let o=n.marks.length-1;o>=0;o--){let c=n.marks[o],u=i.lastChild;if(u instanceof Cr&&u.mark.eq(c.mark))u.dom!=c.dom&&u.setDOM(gy(c.dom)),i=u;else{if(this.cache.reused.get(c)){let h=Rn.get(c.dom);h&&h.setDOM(gy(c.dom))}let f=Cr.of(c.mark,c.dom);i.append(f),i=f}this.cache.reused.set(c,2)}let a=new Ro(e.text,e.text.nodeValue);a.flags|=8,i.append(a)}addInlineWidget(e,n,r){let i=this.afterWidget&&e.flags&48&&(this.afterWidget.flags&48)==(e.flags&48);i||this.flushBuffer();let a=this.ensureMarks(n,r);!i&&!(e.flags&16)&&a.append(this.getBuffer(1)),a.append(e),this.pos+=e.length,this.afterWidget=e}addMark(e,n,r){this.flushBuffer(),this.ensureMarks(n,r).append(e),this.pos+=e.length,this.afterWidget=null}addBlockWidget(e){this.getBlockPos().append(e),this.pos+=e.length,this.lastBlock=e,this.endLine()}continueWidget(e){let n=this.afterWidget||this.lastBlock;n.length+=e,this.pos+=e}addLineStart(e,n){var r;e||(e=ZP);let i=vc.start(e,n||((r=this.cache.find(vc))===null||r===void 0?void 0:r.dom),!!n);this.getBlockPos().append(this.lastBlock=this.curLine=i)}addLine(e){this.getBlockPos().append(e),this.pos+=e.length,this.lastBlock=e,this.endLine()}addBreak(){this.lastBlock.flags|=1,this.endLine(),this.pos++}addLineStartIfNotCovered(e){this.blockPosCovered()||this.addLineStart(e)}ensureLine(e){this.curLine||this.addLineStart(e)}ensureMarks(e,n){var r;let i=this.curLine;for(let a=e.length-1;a>=0;a--){let o=e[a],c;if(n>0&&(c=i.lastChild)&&c instanceof Cr&&c.mark.eq(o))i=c,n--;else{let u=Cr.of(o,(r=this.cache.find(Cr,f=>f.mark.eq(o)))===null||r===void 0?void 0:r.dom);i.append(u),i=u,n=0}}return i}endLine(){if(this.curLine){this.flushBuffer();let e=this.curLine.lastChild;(!e||!L2(this.curLine,!1)||e.dom.nodeName!="BR"&&e.isWidget()&&!($e.ios&&L2(this.curLine,!0)))&&this.curLine.append(this.cache.findWidget(Oy,0,32)||new yc(Oy.toDOM(),0,Oy,32)),this.curLine=this.afterWidget=null}}updateBlockWrappers(){this.wrapperPos>this.pos+1e4&&(this.blockWrappers.goto(this.pos),this.wrappers.length=0);for(let e=this.wrappers.length-1;e>=0;e--)this.wrappers[e].to<this.pos&&this.wrappers.splice(e,1);for(let e=this.blockWrappers;e.value&&e.from<=this.pos;e.next())if(e.to>=this.pos){let n=new Lq(e.from,e.to,e.value,e.rank),r=this.wrappers.length;for(;r>0&&(this.wrappers[r-1].rank-n.rank||this.wrappers[r-1].to-n.to)<0;)r--;this.wrappers.splice(r,0,n)}this.wrapperPos=this.pos}getBlockPos(){var e;this.updateBlockWrappers();let n=this.root;for(let r of this.wrappers){let i=n.lastChild;if(r.from<this.pos&&i instanceof Ds&&i.wrapper.eq(r.wrapper))n=i;else{let a=Ds.of(r.wrapper,(e=this.cache.find(Ds,o=>o.wrapper.eq(r.wrapper)))===null||e===void 0?void 0:e.dom);n.append(a),n=a}}return n}blockPosCovered(){let e=this.lastBlock;return e!=null&&!e.breakAfter&&(!e.isWidget()||(e.flags&160)>0)}getBuffer(e){let n=2|(e<0?16:32),r=this.cache.find(Wp,void 0,1);return r&&(r.flags=n),r||new Wp(n)}flushBuffer(){this.afterWidget&&!(this.afterWidget.flags&32)&&(this.afterWidget.parent.append(this.getBuffer(-1)),this.afterWidget=null)}}class Vq{constructor(e){this.skipCount=0,this.text="",this.textOff=0,this.cursor=e.iter()}skip(e){this.textOff+e<=this.text.length?this.textOff+=e:(this.skipCount+=e-(this.text.length-this.textOff),this.text="",this.textOff=0)}next(e){if(this.textOff==this.text.length){let{value:i,lineBreak:a,done:o}=this.cursor.next(this.skipCount);if(this.skipCount=0,o)throw new Error("Ran out of text content when drawing inline views");this.text=i;let c=this.textOff=Math.min(e,i.length);return a?null:i.slice(0,c)}let n=Math.min(this.text.length,this.textOff+e),r=this.text.slice(this.textOff,n);return this.textOff=n,r}}const Gp=[yc,vc,Ro,Cr,Wp,Ds,rg];for(let t=0;t<Gp.length;t++)Gp[t].bucket=t;class Xq{constructor(e){this.view=e,this.buckets=Gp.map(()=>[]),this.index=Gp.map(()=>0),this.reused=new Map}add(e){let n=e.constructor.bucket,r=this.buckets[n];r.length<6?r.push(e):r[this.index[n]=(this.index[n]+1)%6]=e}find(e,n,r=2){let i=e.bucket,a=this.buckets[i],o=this.index[i];for(let c=a.length-1;c>=0;c--){let u=(c+o)%a.length,f=a[u];if((!n||n(f))&&!this.reused.has(f))return a.splice(u,1),u<o&&this.index[i]--,this.reused.set(f,r),f}return null}findWidget(e,n,r){let i=this.buckets[0];if(i.length)for(let a=0,o=0;;a++){if(a==i.length){if(o)return null;o=1,a=0}let c=i[a];if(!this.reused.has(c)&&(o==0?c.widget.compare(e):c.widget.constructor==e.constructor&&e.updateDOM(c.dom,this.view)))return i.splice(a,1),a<this.index[0]&&this.index[0]--,this.reused.set(c,1),c.length=n,c.flags=c.flags&-498|r,c}}reuse(e){return this.reused.set(e,1),e}maybeReuse(e,n=2){if(!this.reused.has(e))return this.reused.set(e,n),e.dom}}class Bq{constructor(e,n,r,i,a){this.view=e,this.decorations=i,this.disallowBlockEffectsFor=a,this.openWidget=!1,this.openMarks=0,this.cache=new Xq(e),this.text=new Vq(e.state.doc),this.builder=new Zq(this.cache,new rg(e,e.contentDOM),xt.iter(r)),this.cache.reused.set(n,2),this.old=new zq(n)}run(e,n){let r=n&&this.getCompositionContext(n.text);for(let i=0,a=0,o=0;;){let c=o<e.length?e[o++]:null,u=c?c.fromA:this.old.root.length;if(u>i){let f=u-i;this.preserve(f,!o,!c),i=u,a+=f}if(!c)break;this.forward(c.fromA,c.toA),n&&c.fromA<=n.range.fromA&&c.toA>=n.range.toA?(this.emit(a,n.range.fromB),this.builder.addComposition(n,r),this.emit(n.range.toB,c.toB)):this.emit(a,c.toB),a=c.toB,i=c.toA}return this.builder.curLine&&this.builder.endLine(),this.builder.root}preserve(e,n,r){let i=Uq(this.old),a=this.openMarks;this.old.advance(e,r?1:-1,{skip:(o,c,u)=>{if(o.isWidget())if(this.openWidget)this.builder.continueWidget(u-c);else{let f=u>0||c<o.length?yc.of(o.widget,this.view,u-c,o.flags&496,this.cache.maybeReuse(o)):this.cache.reuse(o);f.flags&256?(f.flags&=-2,this.builder.addBlockWidget(f)):(this.builder.ensureLine(null),this.builder.addInlineWidget(f,i,a),a=i.length)}else if(o.isText())this.builder.ensureLine(null),!c&&u==o.length?this.builder.addText(o.text,i,a,this.cache.reuse(o)):(this.cache.add(o),this.builder.addText(o.text.slice(c,u),i,a)),a=i.length;else if(o.isLine())o.flags&=-2,this.cache.reused.set(o,1),this.builder.addLine(o);else if(o instanceof Wp)this.cache.add(o);else if(o instanceof Cr)this.builder.ensureLine(null),this.builder.addMark(o,i,a),this.cache.reused.set(o,1),a=i.length;else return!1;this.openWidget=!1},enter:o=>{o.isLine()?this.builder.addLineStart(o.attrs,this.cache.maybeReuse(o)):(this.cache.add(o),o instanceof Cr&&i.unshift(o.mark)),this.openWidget=!1},leave:o=>{o.isLine()?i.length&&(i.length=a=0):o instanceof Cr&&(i.shift(),a=Math.min(a,i.length))},break:()=>{this.builder.addBreak(),this.openWidget=!1}}),this.text.skip(e)}emit(e,n){let r=null,i=this.builder,a=0,o=xt.spans(this.decorations,e,n,{point:(c,u,f,h,m,g)=>{if(f instanceof qo){if(this.disallowBlockEffectsFor[g]){if(f.block)throw new RangeError("Block decorations may not be specified via plugins");if(u>this.view.state.doc.lineAt(c).to)throw new RangeError("Decorations that replace line breaks may not be specified via plugins")}if(a=h.length,m>h.length)i.continueWidget(u-c);else{let y=f.widget||(f.block?bc.block:bc.inline),x=Iq(f),S=this.cache.findWidget(y,u-c,x)||yc.of(y,this.view,u-c,x);f.block?(f.startSide>0&&i.addLineStartIfNotCovered(r),i.addBlockWidget(S)):(i.ensureLine(r),i.addInlineWidget(S,h,m))}r=null}else r=qq(r,f);u>c&&this.text.skip(u-c)},span:(c,u,f,h)=>{for(let m=c;m<u;){let g=this.text.next(Math.min(512,u-m));g==null?(i.addLineStartIfNotCovered(r),i.addBreak(),m++):(i.ensureLine(r),i.addText(g,f,h),m+=g.length),r=null}}});i.addLineStartIfNotCovered(r),this.openWidget=o>a,this.openMarks=o}forward(e,n){this.old.advance(n-e,1,{skip:(r,i,a)=>{(r.isText()||a==r.length)&&this.cache.add(r)},enter:r=>this.cache.add(r),leave:()=>{},break:()=>{}})}getCompositionContext(e){let n=[],r=null;for(let i=e.parentNode;;i=i.parentNode){let a=Rn.get(i);if(i==this.view.contentDOM)break;a instanceof Cr?n.push(a):a?.isLine()?r=a:i.nodeName=="DIV"&&!r&&i!=this.view.contentDOM?r=new vc(i,ZP):n.push(Cr.of(new sf({tagName:i.nodeName.toLowerCase(),attributes:gq(i)}),i))}return{line:r,marks:n}}}function L2(t,e){let n=r=>{for(let i of r.children)if((e?i.isText():i.length)||n(i))return!0;return!1};return n(t)}function Iq(t){let e=t.isReplace?(t.startSide<0?64:0)|(t.endSide>0?128:0):t.startSide>0?32:16;return t.block&&(e|=256),e}const ZP={class:"cm-line"};function qq(t,e){let n=e.spec.attributes,r=e.spec.class;return!n&&!r||(t||(t={class:"cm-line"}),n&&Yx(n,t),r&&(t.class+=" "+r)),t}function Uq(t){let e=[];for(let n=t.parents.length;n>1;n--){let r=n==t.parents.length?t.tile:t.parents[n].tile;r instanceof Cr&&e.push(r.mark)}return e}function gy(t){let e=Rn.get(t);return e&&e.setDOM(t.cloneNode()),t}class bc extends el{constructor(e){super(),this.tag=e}eq(e){return e.tag==this.tag}toDOM(){return document.createElement(this.tag)}updateDOM(e){return e.nodeName.toLowerCase()==this.tag}get isHidden(){return!0}}bc.inline=new bc("span");bc.block=new bc("div");const Oy=new class extends el{toDOM(){return document.createElement("br")}get isHidden(){return!0}get editable(){return!0}};class Z2{constructor(e){this.view=e,this.decorations=[],this.blockWrappers=[],this.dynamicDecorationMap=[!1],this.domChanged=null,this.hasComposition=null,this.editContextFormatting=dt.none,this.lastCompositionAfterCursor=!1,this.minWidth=0,this.minWidthFrom=0,this.minWidthTo=0,this.impreciseAnchor=null,this.impreciseHead=null,this.forceSelection=!1,this.lastUpdate=Date.now(),this.updateDeco(),this.tile=new rg(e,e.contentDOM),this.updateInner([new ai(0,0,0,e.state.doc.length)],null)}update(e){var n;let r=e.changedRanges;this.minWidth>0&&r.length&&(r.every(({fromA:h,toA:m})=>m<this.minWidthFrom||h>this.minWidthTo)?(this.minWidthFrom=e.changes.mapPos(this.minWidthFrom,1),this.minWidthTo=e.changes.mapPos(this.minWidthTo,1)):this.minWidth=this.minWidthFrom=this.minWidthTo=0),this.updateEditContextFormatting(e);let i=-1;this.view.inputState.composing>=0&&!this.view.observer.editContext&&(!((n=this.domChanged)===null||n===void 0)&&n.newSel?i=this.domChanged.newSel.head:!tU(e.changes,this.hasComposition)&&!e.selectionSet&&(i=e.state.selection.main.head));let a=i>-1?Fq(this.view,e.changes,i):null;if(this.domChanged=null,this.hasComposition){let{from:h,to:m}=this.hasComposition;r=new ai(h,m,e.changes.mapPos(h,-1),e.changes.mapPos(m,1)).addToSet(r.slice())}this.hasComposition=a?{from:a.range.fromB,to:a.range.toB}:null,($e.ie||$e.chrome)&&!a&&e&&e.state.doc.lines!=e.startState.doc.lines&&(this.forceSelection=!0);let o=this.decorations,c=this.blockWrappers;this.updateDeco();let u=Hq(o,this.decorations,e.changes);u.length&&(r=ai.extendWithRanges(r,u));let f=Jq(c,this.blockWrappers,e.changes);return f.length&&(r=ai.extendWithRanges(r,f)),a&&!r.some(h=>h.fromA<=a.range.fromA&&h.toA>=a.range.toA)&&(r=a.range.addToSet(r.slice())),this.tile.flags&2&&r.length==0?!1:(this.updateInner(r,a),e.transactions.length&&(this.lastUpdate=Date.now()),!0)}updateInner(e,n){this.view.viewState.mustMeasureContent=!0;let{observer:r}=this.view;r.ignore(()=>{if(n||e.length){let o=this.tile,c=new Bq(this.view,o,this.blockWrappers,this.decorations,this.dynamicDecorationMap);this.tile=c.run(e,n),ib(o,c.cache.reused)}this.tile.dom.style.height=this.view.viewState.contentHeight/this.view.scaleY+"px",this.tile.dom.style.flexBasis=this.minWidth?this.minWidth+"px":"";let a=$e.chrome||$e.ios?{node:r.selectionRange.focusNode,written:!1}:void 0;this.tile.sync(a),a&&(a.written||r.selectionRange.focusNode!=a.node||!this.tile.dom.contains(a.node))&&(this.forceSelection=!0),this.tile.dom.style.height=""});let i=[];if(this.view.viewport.from||this.view.viewport.to<this.view.state.doc.length)for(let a of this.tile.children)a.isWidget()&&a.widget instanceof vy&&i.push(a.dom);r.updateGaps(i)}updateEditContextFormatting(e){this.editContextFormatting=this.editContextFormatting.map(e.changes);for(let n of e.transactions)for(let r of n.effects)r.is(PP)&&(this.editContextFormatting=r.value)}updateSelection(e=!1,n=!1){(e||!this.view.observer.selectionRange.focusNode)&&this.view.observer.readSelectionRange();let{dom:r}=this.tile,i=this.view.root.activeElement,a=i==r,o=!a&&!(this.view.state.facet(Za)||r.tabIndex>-1)&&yp(r,this.view.observer.selectionRange)&&!(i&&r.contains(i));if(!(a||n||o))return;let c=this.forceSelection;this.forceSelection=!1;let u=this.view.state.selection.main,f,h;if(u.empty?h=f=this.inlineDOMNearPos(u.anchor,u.assoc||1):(h=this.inlineDOMNearPos(u.head,u.head==u.from?1:-1),f=this.inlineDOMNearPos(u.anchor,u.anchor==u.from?1:-1)),$e.gecko&&u.empty&&!this.hasComposition&&Yq(f)){let g=document.createTextNode("");this.view.observer.ignore(()=>f.node.insertBefore(g,f.node.childNodes[f.offset]||null)),f=h=new Ti(g,0),c=!0}let m=this.view.observer.selectionRange;(c||!m.focusNode||(!ud(f.node,f.offset,m.anchorNode,m.anchorOffset)||!ud(h.node,h.offset,m.focusNode,m.focusOffset))&&!this.suppressWidgetCursorChange(m,u))&&(this.view.observer.ignore(()=>{$e.android&&$e.chrome&&r.contains(m.focusNode)&&eU(m.focusNode,r)&&(r.blur(),r.focus({preventScroll:!0}));let g=Td(this.view.root);if(g)if(u.empty){if($e.gecko){let y=Wq(f.node,f.offset);if(y&&y!=3){let x=(y==1?vP:yP)(f.node,f.offset);x&&(f=new Ti(x.node,x.offset))}}g.collapse(f.node,f.offset),u.bidiLevel!=null&&g.caretBidiLevel!==void 0&&(g.caretBidiLevel=u.bidiLevel)}else if(g.extend){g.collapse(f.node,f.offset);try{g.extend(h.node,h.offset)}catch{}}else{let y=document.createRange();u.anchor>u.head&&([f,h]=[h,f]),y.setEnd(h.node,h.offset),y.setStart(f.node,f.offset),g.removeAllRanges(),g.addRange(y)}o&&this.view.root.activeElement==r&&(r.blur(),i&&i.focus())}),this.view.observer.setSelectionRange(f,h)),this.impreciseAnchor=f.precise?null:new Ti(m.anchorNode,m.anchorOffset),this.impreciseHead=h.precise?null:new Ti(m.focusNode,m.focusOffset)}suppressWidgetCursorChange(e,n){return this.hasComposition&&n.empty&&ud(e.focusNode,e.focusOffset,e.anchorNode,e.anchorOffset)&&this.posFromDOM(e.focusNode,e.focusOffset)==n.head}enforceCursorAssoc(){if(this.hasComposition)return;let{view:e}=this,n=e.state.selection.main,r=Td(e.root),{anchorNode:i,anchorOffset:a}=e.observer.selectionRange;if(!r||!n.empty||!n.assoc||!r.modify)return;let o=this.lineAt(n.head,n.assoc);if(!o)return;let c=o.posAtStart;if(n.head==c||n.head==c+o.length)return;let u=this.coordsAt(n.head,-1),f=this.coordsAt(n.head,1);if(!u||!f||u.bottom>f.top)return;let h=this.domAtPos(n.head+n.assoc,n.assoc);r.collapse(h.node,h.offset),r.modify("move",n.assoc<0?"forward":"backward","lineboundary"),e.observer.readSelectionRange();let m=e.observer.selectionRange;e.docView.posFromDOM(m.anchorNode,m.anchorOffset)!=n.from&&r.collapse(i,a)}posFromDOM(e,n){let r=this.tile.nearest(e);if(!r)return this.tile.dom.compareDocumentPosition(e)&2?0:this.view.state.doc.length;let i=r.posAtStart;if(r.isComposite()){let a;if(e==r.dom)a=r.dom.childNodes[n];else{let o=Ka(e)==0?0:n==0?-1:1;for(;;){let c=e.parentNode;if(c==r.dom)break;o==0&&c.firstChild!=c.lastChild&&(e==c.firstChild?o=-1:o=1),e=c}o<0?a=e:a=e.nextSibling}if(a==r.dom.firstChild)return i;for(;a&&!Rn.get(a);)a=a.nextSibling;if(!a)return i+r.length;for(let o=0,c=i;;o++){let u=r.children[o];if(u.dom==a)return c;c+=u.length+u.breakAfter}}else return r.isText()?e==r.dom?i+n:i+(n?r.length:0):i}domAtPos(e,n){let{tile:r,offset:i}=this.tile.resolveBlock(e,n);return r.isWidget()?r.domPosFor(e,n):r.domIn(i,n)}inlineDOMNearPos(e,n){let r,i=-1,a=!1,o,c=-1,u=!1;return this.tile.blockTiles((f,h)=>{if(f.isWidget()){if(f.flags&32&&h>=e)return!0;f.flags&16&&(a=!0)}else{let m=h+f.length;if(h<=e&&(r=f,i=e-h,a=m<e),m>=e&&!o&&(o=f,c=e-h,u=h>e),h>e&&o)return!0}}),!r&&!o?this.domAtPos(e,n):(a&&o?r=null:u&&r&&(o=null),r&&n<0||!o?r.domIn(i,n):o.domIn(c,n))}coordsAt(e,n){let{tile:r,offset:i}=this.tile.resolveBlock(e,n);return r.isWidget()?r.widget instanceof vy?null:r.coordsInWidget(i,n,!0):r.coordsIn(i,n)}lineAt(e,n){let{tile:r}=this.tile.resolveBlock(e,n);return r.isLine()?r:null}coordsForChar(e){let{tile:n,offset:r}=this.tile.resolveBlock(e,1);if(!n.isLine())return null;function i(a,o){if(a.isComposite())for(let c of a.children){if(c.length>=o){let u=i(c,o);if(u)return u}if(o-=c.length,o<0)break}else if(a.isText()&&o<a.length){let c=qn(a.text,o);if(c==o)return null;let u=Ed(a.dom,o,c).getClientRects();for(let f=0;f<u.length;f++){let h=u[f];if(f==u.length-1||h.top<h.bottom&&h.left<h.right)return h}}return null}return i(n,r)}measureVisibleLineHeights(e){let n=[],{from:r,to:i}=e,a=this.view.contentDOM.clientWidth,o=a>Math.max(this.view.scrollDOM.clientWidth,this.minWidth)+1,c=-1,u=this.view.textDirection==dn.LTR,f=0,h=(m,g,y)=>{for(let x=0;x<m.children.length&&!(g>i);x++){let S=m.children[x],k=g+S.length,T=S.dom.getBoundingClientRect(),{height:C}=T;if(y&&!x&&(f+=T.top-y.top),S instanceof Ds)k>r&&h(S,g,T);else if(g>=r&&(f>0&&n.push(-f),n.push(C+f),f=0,o)){let E=S.dom.lastChild,R=E?bp(E):[];if(R.length){let $=R[R.length-1],P=u?$.right-T.left:T.right-$.left;P>c&&(c=P,this.minWidth=a,this.minWidthFrom=g,this.minWidthTo=k)}}y&&x==m.children.length-1&&(f+=y.bottom-T.bottom),g=k+S.breakAfter}};return h(this.tile,0,null),n}textDirectionAt(e){let{tile:n}=this.tile.resolveBlock(e,1);return getComputedStyle(n.dom).direction=="rtl"?dn.RTL:dn.LTR}measureTextSize(){let e=this.tile.blockTiles(o=>{if(o.isLine()&&o.children.length&&o.length<=20){let c=0,u;for(let f of o.children){if(!f.isText()||/[^ -~]/.test(f.text))return;let h=bp(f.dom);if(h.length!=1)return;c+=h[0].width,u=h[0].height}if(c)return{lineHeight:o.dom.getBoundingClientRect().height,charWidth:c/o.length,textHeight:u}}});if(e)return e;let n=document.createElement("div"),r,i,a;return n.className="cm-line",n.style.width="99999px",n.style.position="absolute",n.textContent="abc def ghi jkl mno pqr stu",this.view.observer.ignore(()=>{this.tile.dom.appendChild(n);let o=bp(n.firstChild)[0];r=n.getBoundingClientRect().height,i=o&&o.width?o.width/27:7,a=o&&o.height?o.height:r,n.remove()}),{lineHeight:r,charWidth:i,textHeight:a}}computeBlockGapDeco(){let e=[],n=this.view.viewState;for(let r=0,i=0;;i++){let a=i==n.viewports.length?null:n.viewports[i],o=a?a.from-1:this.view.state.doc.length;if(o>r){let c=(n.lineBlockAt(o).bottom-n.lineBlockAt(r).top)/this.view.scaleY;e.push(dt.replace({widget:new vy(c),block:!0,inclusive:!0,isBlockGap:!0}).range(r,o))}if(!a)break;r=a.to+1}return dt.set(e)}updateDeco(){let e=1,n=this.view.state.facet(Qd).map(a=>(this.dynamicDecorationMap[e++]=typeof a=="function")?a(this.view):a),r=!1,i=this.view.state.facet(NP).map((a,o)=>{let c=typeof a=="function";return c&&(r=!0),c?a(this.view):a});for(i.length&&(this.dynamicDecorationMap[e++]=r,n.push(xt.join(i))),this.decorations=[this.editContextFormatting,...n,this.computeBlockGapDeco(),this.view.viewState.lineGapDeco];e<this.decorations.length;)this.dynamicDecorationMap[e++]=!1;this.blockWrappers=this.view.state.facet(MP).map(a=>typeof a=="function"?a(this.view):a)}scrollIntoView(e){if(e.isSnapshot){let f=this.view.viewState.lineBlockAt(e.range.head);this.view.scrollDOM.scrollTop=f.top-e.yMargin,this.view.scrollDOM.scrollLeft=e.xMargin;return}for(let f of this.view.state.facet($P))try{if(f(this.view,e.range,e))return!0}catch(h){aa(this.view.state,h,"scroll handler")}let{range:n}=e,r=this.coordsAt(n.head,n.empty?n.assoc:n.head>n.anchor?-1:1),i;if(!r)return;!n.empty&&(i=this.coordsAt(n.anchor,n.anchor>n.head?-1:1))&&(r={left:Math.min(r.left,i.left),top:Math.min(r.top,i.top),right:Math.max(r.right,i.right),bottom:Math.max(r.bottom,i.bottom)});let a=LP(this.view),o={left:r.left-a.left,top:r.top-a.top,right:r.right+a.right,bottom:r.bottom+a.bottom},{offsetWidth:c,offsetHeight:u}=this.view.scrollDOM;yq(this.view.scrollDOM,o,n.head<n.anchor?-1:1,e.x,e.y,Math.max(Math.min(e.xMargin,c),-c),Math.max(Math.min(e.yMargin,u),-u),this.view.textDirection==dn.LTR)}lineHasWidget(e){let n=r=>r.isWidget()||r.children.some(n);return n(this.tile.resolveBlock(e,1).tile)}destroy(){ib(this.tile)}}function ib(t,e){let n=e?.get(t);if(n!=1){n==null&&t.destroy();for(let r of t.children)ib(r,e)}}function Yq(t){return t.node.nodeType==1&&t.node.firstChild&&(t.offset==0||t.node.childNodes[t.offset-1].contentEditable=="false")&&(t.offset==t.node.childNodes.length||t.node.childNodes[t.offset].contentEditable=="false")}function VP(t,e){let n=t.observer.selectionRange;if(!n.focusNode)return null;let r=vP(n.focusNode,n.focusOffset),i=yP(n.focusNode,n.focusOffset),a=r||i;if(i&&r&&i.node!=r.node){let c=Rn.get(i.node);if(!c||c.isText()&&c.text!=i.node.nodeValue)a=i;else if(t.docView.lastCompositionAfterCursor){let u=Rn.get(r.node);!u||u.isText()&&u.text!=r.node.nodeValue||(a=i)}}if(t.docView.lastCompositionAfterCursor=a!=r,!a)return null;let o=e-a.offset;return{from:o,to:o+a.node.nodeValue.length,node:a.node}}function Fq(t,e,n){let r=VP(t,n);if(!r)return null;let{node:i,from:a,to:o}=r,c=i.nodeValue;if(/[\n\r]/.test(c)||t.state.doc.sliceString(r.from,r.to)!=c)return null;let u=e.invertedDesc;return{range:new ai(u.mapPos(a),u.mapPos(o),a,o),text:i}}function Wq(t,e){return t.nodeType!=1?0:(e&&t.childNodes[e-1].contentEditable=="false"?1:0)|(e<t.childNodes.length&&t.childNodes[e].contentEditable=="false"?2:0)}let Gq=class{constructor(){this.changes=[]}compareRange(e,n){oc(e,n,this.changes)}comparePoint(e,n){oc(e,n,this.changes)}boundChange(e){oc(e,e,this.changes)}};function Hq(t,e,n){let r=new Gq;return xt.compare(t,e,n,r),r.changes}class Kq{constructor(){this.changes=[]}compareRange(e,n){oc(e,n,this.changes)}comparePoint(){}boundChange(e){oc(e,e,this.changes)}}function Jq(t,e,n){let r=new Kq;return xt.compare(t,e,n,r),r.changes}function eU(t,e){for(let n=t;n&&n!=e;n=n.assignedSlot||n.parentNode)if(n.nodeType==1&&n.contentEditable=="false")return!0;return!1}function tU(t,e){let n=!1;return e&&t.iterChangedRanges((r,i)=>{r<e.to&&i>e.from&&(n=!0)}),n}class vy extends el{constructor(e){super(),this.height=e}toDOM(){let e=document.createElement("div");return e.className="cm-gap",this.updateDOM(e),e}eq(e){return e.height==this.height}updateDOM(e){return e.style.height=this.height+"px",!0}get editable(){return!0}get estimatedHeight(){return this.height}ignoreEvent(){return!1}}function nU(t,e,n=1){let r=t.charCategorizer(e),i=t.doc.lineAt(e),a=e-i.from;if(i.length==0)return Se.cursor(e);a==0?n=1:a==i.length&&(n=-1);let o=a,c=a;n<0?o=qn(i.text,a,!1):c=qn(i.text,a);let u=r(i.text.slice(o,c));for(;o>0;){let f=qn(i.text,o,!1);if(r(i.text.slice(f,o))!=u)break;o=f}for(;c<i.length;){let f=qn(i.text,c);if(r(i.text.slice(c,f))!=u)break;c=f}return Se.range(o+i.from,c+i.from)}function rU(t,e,n,r,i){let a=Math.round((r-e.left)*t.defaultCharacterWidth);if(t.lineWrapping&&n.height>t.defaultLineHeight*1.5){let c=t.viewState.heightOracle.textHeight,u=Math.floor((i-n.top-(t.defaultLineHeight-c)*.5)/c);a+=u*t.viewState.heightOracle.lineLength}let o=t.state.sliceDoc(n.from,n.to);return n.from+cq(o,a,t.state.tabSize)}function iU(t,e,n){let r=t.lineBlockAt(e);if(Array.isArray(r.type)){let i;for(let a of r.type){if(a.from>e)break;if(!(a.to<e)){if(a.from<e&&a.to>e)return a;(!i||a.type==Ar.Text&&(i.type!=a.type||(n<0?a.from<e:a.to>e)))&&(i=a)}}return i||r}return r}function aU(t,e,n,r){let i=iU(t,e.head,e.assoc||-1),a=!r||i.type!=Ar.Text||!(t.lineWrapping||i.widgetLineBreaks)?null:t.coordsAtPos(e.assoc<0&&e.head>i.from?e.head-1:e.head);if(a){let o=t.dom.getBoundingClientRect(),c=t.textDirectionAt(i.from),u=t.posAtCoords({x:n==(c==dn.LTR)?o.right-1:o.left+1,y:(a.top+a.bottom)/2});if(u!=null)return Se.cursor(u,n?-1:1)}return Se.cursor(n?i.to:i.from,n?-1:1)}function V2(t,e,n,r){let i=t.state.doc.lineAt(e.head),a=t.bidiSpans(i),o=t.textDirectionAt(i.from);for(let c=e,u=null;;){let f=_q(i,a,o,c,n),h=kP;if(!f){if(i.number==(n?t.state.doc.lines:1))return c;h=`
|
|
85
|
-
`,i=t.state.doc.line(i.number+(n?1:-1)),a=t.bidiSpans(i),f=t.visualLineSide(i,!n)}if(u){if(!u(h))return c}else{if(!r)return f;u=r(h)}c=f}}function sU(t,e,n){let r=t.state.charCategorizer(e),i=r(n);return a=>{let o=r(a);return i==ii.Space&&(i=o),i==o}}function oU(t,e,n,r){let i=e.head,a=n?1:-1;if(i==(n?t.state.doc.length:0))return Se.cursor(i,e.assoc);let o=e.goalColumn,c,u=t.contentDOM.getBoundingClientRect(),f=t.coordsAtPos(i,e.assoc||-1),h=t.documentTop;if(f)o==null&&(o=f.left-u.left),c=a<0?f.top:f.bottom;else{let y=t.viewState.lineBlockAt(i);o==null&&(o=Math.min(u.right-u.left,t.defaultCharacterWidth*(i-y.from))),c=(a<0?y.top:y.bottom)+h}let m=u.left+o,g=r??t.viewState.heightOracle.textHeight>>1;for(let y=0;;y+=10){let x=c+(g+y)*a,S=ab(t,{x:m,y:x},!1,a);return Se.cursor(S.pos,S.assoc,void 0,o)}}function dd(t,e,n){for(;;){let r=0;for(let i of t)i.between(e-1,e+1,(a,o,c)=>{if(e>a&&e<o){let u=r||n||(e-a<o-e?-1:1);e=u<0?a:o,r=u}});if(!r)return e}}function XP(t,e){let n=null;for(let r=0;r<e.ranges.length;r++){let i=e.ranges[r],a=null;if(i.empty){let o=dd(t,i.from,0);o!=i.from&&(a=Se.cursor(o,-1))}else{let o=dd(t,i.from,-1),c=dd(t,i.to,1);(o!=i.from||c!=i.to)&&(a=Se.range(i.from==i.anchor?o:c,i.from==i.head?o:c))}a&&(n||(n=e.ranges.slice()),n[r]=a)}return n?Se.create(n,e.mainIndex):e}function yy(t,e,n){let r=dd(t.state.facet(lf).map(i=>i(t)),n.from,e.head>n.from?-1:1);return r==n.from?n:Se.cursor(r,r<n.from?1:-1)}class na{constructor(e,n){this.pos=e,this.assoc=n}}function ab(t,e,n,r){let i=t.contentDOM.getBoundingClientRect(),a=i.top+t.viewState.paddingTop,{x:o,y:c}=e,u=c-a,f;for(;;){if(u<0)return new na(0,1);if(u>t.viewState.docHeight)return new na(t.state.doc.length,-1);if(f=t.elementAtHeight(u),r==null)break;if(f.type==Ar.Text){let g=t.docView.coordsAt(r<0?f.from:f.to,r);if(g&&(r<0?g.top<=u+a:g.bottom>=u+a))break}let m=t.viewState.heightOracle.textHeight/2;u=r>0?f.bottom+m:f.top-m}if(t.viewport.from>=f.to||t.viewport.to<=f.from){if(n)return null;if(f.type==Ar.Text){let m=rU(t,i,f,o,c);return new na(m,m==f.from?1:-1)}}if(f.type!=Ar.Text)return u<(f.top+f.bottom)/2?new na(f.from,1):new na(f.to,-1);let h=t.docView.lineAt(f.from,2);return(!h||h.length!=f.length)&&(h=t.docView.lineAt(f.from,-2)),BP(t,h,f.from,o,c)}function BP(t,e,n,r,i){let a=-1,o=null,c=1e9,u=1e9,f=i,h=i,m=(g,y)=>{for(let x=0;x<g.length;x++){let S=g[x];if(S.top==S.bottom)continue;let k=S.left>r?S.left-r:S.right<r?r-S.right:0,T=S.top>i?S.top-i:S.bottom<i?i-S.bottom:0;S.top<=h&&S.bottom>=f&&(f=Math.min(S.top,f),h=Math.max(S.bottom,h),T=0),(a<0||(T-u||k-c)<0)&&(a>=0&&u&&c<k&&o.top<=h-2&&o.bottom>=f+2?u=0:(a=y,c=k,u=T,o=S))}};if(e.isText()){for(let y=0;y<e.length;){let x=qn(e.text,y);if(m(Ed(e.dom,y,x).getClientRects(),y),!c&&!u)break;y=x}return r>(o.left+o.right)/2==(X2(t,a+n)==dn.LTR)?new na(n+qn(e.text,a),-1):new na(n+a,1)}else{if(!e.length)return new na(n,1);for(let S=0;S<e.children.length;S++){let k=e.children[S];if(k.flags&48)continue;let T=(k.dom.nodeType==1?k.dom:Ed(k.dom,0,k.length)).getClientRects();if(m(T,S),!c&&!u)break}let g=e.children[a],y=e.posBefore(g,n);return g.isComposite()||g.isText()?BP(t,g,y,Math.max(o.left,Math.min(o.right,r)),i):r>(o.left+o.right)/2==(X2(t,a+n)==dn.LTR)?new na(y+g.length,-1):new na(y,1)}}function X2(t,e){let n=t.state.doc.lineAt(e);return t.bidiSpans(n)[Va.find(t.bidiSpans(n),e-n.from,-1,1)].dir}const rd="";class lU{constructor(e,n){this.points=e,this.text="",this.lineSeparator=n.facet(At.lineSeparator)}append(e){this.text+=e}lineBreak(){this.text+=rd}readRange(e,n){if(!e)return this;let r=e.parentNode;for(let i=e;;){this.findPointBefore(r,i);let a=this.text.length;this.readNode(i);let o=Rn.get(i),c=i.nextSibling;if(c==n){o?.breakAfter&&!c&&this.lineBreak();break}let u=Rn.get(c);(o&&u?o.breakAfter:(o?o.breakAfter:Up(i))||Up(c)&&(i.nodeName!="BR"||o?.isWidget())&&this.text.length>a)&&!uU(c,n)&&this.lineBreak(),i=c}return this.findPointBefore(r,n),this}readTextNode(e){let n=e.nodeValue;for(let r of this.points)r.node==e&&(r.pos=this.text.length+Math.min(r.offset,n.length));for(let r=0,i=this.lineSeparator?null:/\r\n?|\n/g;;){let a=-1,o=1,c;if(this.lineSeparator?(a=n.indexOf(this.lineSeparator,r),o=this.lineSeparator.length):(c=i.exec(n))&&(a=c.index,o=c[0].length),this.append(n.slice(r,a<0?n.length:a)),a<0)break;if(this.lineBreak(),o>1)for(let u of this.points)u.node==e&&u.pos>this.text.length&&(u.pos-=o-1);r=a+o}}readNode(e){let n=Rn.get(e),r=n&&n.overrideDOMText;if(r!=null){this.findPointInside(e,r.length);for(let i=r.iter();!i.next().done;)i.lineBreak?this.lineBreak():this.append(i.value)}else e.nodeType==3?this.readTextNode(e):e.nodeName=="BR"?e.nextSibling&&this.lineBreak():e.nodeType==1&&this.readRange(e.firstChild,null)}findPointBefore(e,n){for(let r of this.points)r.node==e&&e.childNodes[r.offset]==n&&(r.pos=this.text.length)}findPointInside(e,n){for(let r of this.points)(e.nodeType==3?r.node==e:e.contains(r.node))&&(r.pos=this.text.length+(cU(e,r.node,r.offset)?n:0))}}function cU(t,e,n){for(;;){if(!e||n<Ka(e))return!1;if(e==t)return!0;n=Us(e)+1,e=e.parentNode}}function uU(t,e){let n;for(;!(t==e||!t);t=t.nextSibling){let r=Rn.get(t);if(!r?.isWidget())return!1;r&&(n||(n=[])).push(r)}if(n)for(let r of n){let i=r.overrideDOMText;if(i?.length)return!1}return!0}class B2{constructor(e,n){this.node=e,this.offset=n,this.pos=-1}}class dU{constructor(e,n,r,i){this.typeOver=i,this.bounds=null,this.text="",this.domChanged=n>-1;let{impreciseHead:a,impreciseAnchor:o}=e.docView;if(e.state.readOnly&&n>-1)this.newSel=null;else if(n>-1&&(this.bounds=IP(e.docView.tile,n,r,0))){let c=a||o?[]:hU(e),u=new lU(c,e.state);u.readRange(this.bounds.startDOM,this.bounds.endDOM),this.text=u.text,this.newSel=pU(c,this.bounds.from)}else{let c=e.observer.selectionRange,u=a&&a.node==c.focusNode&&a.offset==c.focusOffset||!J0(e.contentDOM,c.focusNode)?e.state.selection.main.head:e.docView.posFromDOM(c.focusNode,c.focusOffset),f=o&&o.node==c.anchorNode&&o.offset==c.anchorOffset||!J0(e.contentDOM,c.anchorNode)?e.state.selection.main.anchor:e.docView.posFromDOM(c.anchorNode,c.anchorOffset),h=e.viewport;if(($e.ios||$e.chrome)&&e.state.selection.main.empty&&u!=f&&(h.from>0||h.to<e.state.doc.length)){let m=Math.min(u,f),g=Math.max(u,f),y=h.from-m,x=h.to-g;(y==0||y==1||m==0)&&(x==0||x==-1||g==e.state.doc.length)&&(u=0,f=e.state.doc.length)}e.inputState.composing>-1&&e.state.selection.ranges.length>1?this.newSel=e.state.selection.replaceRange(Se.range(f,u)):this.newSel=Se.single(f,u)}}}function IP(t,e,n,r){if(t.isComposite()){let i=-1,a=-1,o=-1,c=-1;for(let u=0,f=r,h=r;u<t.children.length;u++){let m=t.children[u],g=f+m.length;if(f<e&&g>n)return IP(m,e,n,f);if(g>=e&&i==-1&&(i=u,a=f),f>n&&m.dom.parentNode==t.dom){o=u,c=h;break}h=g,f=g+m.breakAfter}return{from:a,to:c<0?r+t.length:c,startDOM:(i?t.children[i-1].dom.nextSibling:null)||t.dom.firstChild,endDOM:o<t.children.length&&o>=0?t.children[o].dom:null}}else return t.isText()?{from:r,to:r+t.length,startDOM:t.dom,endDOM:t.dom.nextSibling}:null}function qP(t,e){let n,{newSel:r}=e,i=t.state.selection.main,a=t.inputState.lastKeyTime>Date.now()-100?t.inputState.lastKeyCode:-1;if(e.bounds){let{from:o,to:c}=e.bounds,u=i.from,f=null;(a===8||$e.android&&e.text.length<c-o)&&(u=i.to,f="end");let h=UP(t.state.doc.sliceString(o,c,rd),e.text,u-o,f);h&&($e.chrome&&a==13&&h.toB==h.from+2&&e.text.slice(h.from,h.toB)==rd+rd&&h.toB--,n={from:o+h.from,to:o+h.toA,insert:St.of(e.text.slice(h.from,h.toB).split(rd))})}else r&&(!t.hasFocus&&t.state.facet(Za)||r.main.eq(i))&&(r=null);if(!n&&!r)return!1;if(!n&&e.typeOver&&!i.empty&&r&&r.main.empty?n={from:i.from,to:i.to,insert:t.state.doc.slice(i.from,i.to)}:($e.mac||$e.android)&&n&&n.from==n.to&&n.from==i.head-1&&/^\. ?$/.test(n.insert.toString())&&t.contentDOM.getAttribute("autocorrect")=="off"?(r&&n.insert.length==2&&(r=Se.single(r.main.anchor-1,r.main.head-1)),n={from:n.from,to:n.to,insert:St.of([n.insert.toString().replace("."," ")])}):n&&n.from>=i.from&&n.to<=i.to&&(n.from!=i.from||n.to!=i.to)&&i.to-i.from-(n.to-n.from)<=4?n={from:i.from,to:i.to,insert:t.state.doc.slice(i.from,n.from).append(n.insert).append(t.state.doc.slice(n.to,i.to))}:t.state.doc.lineAt(i.from).to<i.to&&t.docView.lineHasWidget(i.to)&&t.inputState.insertingTextAt>Date.now()-50?n={from:i.from,to:i.to,insert:t.state.toText(t.inputState.insertingText)}:$e.chrome&&n&&n.from==n.to&&n.from==i.head&&n.insert.toString()==`
|
|
86
|
-
`&&t.lineWrapping&&(r&&(r=Se.single(r.main.anchor-1,r.main.head-1)),n={from:i.from,to:i.to,insert:St.of([" "])}),n)return Jx(t,n,r,a);if(r&&!r.main.eq(i)){let o=!1,c="select";return t.inputState.lastSelectionTime>Date.now()-50&&(t.inputState.lastSelectionOrigin=="select"&&(o=!0),c=t.inputState.lastSelectionOrigin,c=="select.pointer"&&(r=XP(t.state.facet(lf).map(u=>u(t)),r))),t.dispatch({selection:r,scrollIntoView:o,userEvent:c}),!0}else return!1}function Jx(t,e,n,r=-1){if($e.ios&&t.inputState.flushIOSKey(e))return!0;let i=t.state.selection.main;if($e.android&&(e.to==i.to&&(e.from==i.from||e.from==i.from-1&&t.state.sliceDoc(e.from,i.from)==" ")&&e.insert.length==1&&e.insert.lines==2&&lc(t.contentDOM,"Enter",13)||(e.from==i.from-1&&e.to==i.to&&e.insert.length==0||r==8&&e.insert.length<e.to-e.from&&e.to>i.head)&&lc(t.contentDOM,"Backspace",8)||e.from==i.from&&e.to==i.to+1&&e.insert.length==0&&lc(t.contentDOM,"Delete",46)))return!0;let a=e.insert.toString();t.inputState.composing>=0&&t.inputState.composing++;let o,c=()=>o||(o=fU(t,e,n));return t.state.facet(AP).some(u=>u(t,e.from,e.to,a,c))||t.dispatch(c()),!0}function fU(t,e,n){let r,i=t.state,a=i.selection.main,o=-1;if(e.from==e.to&&e.from<a.from||e.from>a.to){let u=e.from<a.from?-1:1,f=u<0?a.from:a.to,h=dd(i.facet(lf).map(m=>m(t)),f,u);e.from==h&&(o=h)}if(o>-1)r={changes:e,selection:Se.cursor(e.from+e.insert.length,-1)};else if(e.from>=a.from&&e.to<=a.to&&e.to-e.from>=(a.to-a.from)/3&&(!n||n.main.empty&&n.main.from==e.from+e.insert.length)&&t.inputState.composing<0){let u=a.from<e.from?i.sliceDoc(a.from,e.from):"",f=a.to>e.to?i.sliceDoc(e.to,a.to):"";r=i.replaceSelection(t.state.toText(u+e.insert.sliceString(0,void 0,t.state.lineBreak)+f))}else{let u=i.changes(e),f=n&&n.main.to<=u.newLength?n.main:void 0;if(i.selection.ranges.length>1&&(t.inputState.composing>=0||t.inputState.compositionPendingChange)&&e.to<=a.to+10&&e.to>=a.to-10){let h=t.state.sliceDoc(e.from,e.to),m,g=n&&VP(t,n.main.head);if(g){let x=e.insert.length-(e.to-e.from);m={from:g.from,to:g.to-x}}else m=t.state.doc.lineAt(a.head);let y=a.to-e.to;r=i.changeByRange(x=>{if(x.from==a.from&&x.to==a.to)return{changes:u,range:f||x.map(u)};let S=x.to-y,k=S-h.length;if(t.state.sliceDoc(k,S)!=h||S>=m.from&&k<=m.to)return{range:x};let T=i.changes({from:k,to:S,insert:e.insert}),C=x.to-a.to;return{changes:T,range:f?Se.range(Math.max(0,f.anchor+C),Math.max(0,f.head+C)):x.map(T)}})}else r={changes:u,selection:f&&i.selection.replaceRange(f)}}let c="input.type";return(t.composing||t.inputState.compositionPendingChange&&t.inputState.compositionEndedAt>Date.now()-50)&&(t.inputState.compositionPendingChange=!1,c+=".compose",t.inputState.compositionFirstChange&&(c+=".start",t.inputState.compositionFirstChange=!1)),i.update(r,{userEvent:c,scrollIntoView:!0})}function UP(t,e,n,r){let i=Math.min(t.length,e.length),a=0;for(;a<i&&t.charCodeAt(a)==e.charCodeAt(a);)a++;if(a==i&&t.length==e.length)return null;let o=t.length,c=e.length;for(;o>0&&c>0&&t.charCodeAt(o-1)==e.charCodeAt(c-1);)o--,c--;if(r=="end"){let u=Math.max(0,a-Math.min(o,c));n-=o+u-a}if(o<a&&t.length<e.length){let u=n<=a&&n>=o?a-n:0;a-=u,c=a+(c-o),o=a}else if(c<a){let u=n<=a&&n>=c?a-n:0;a-=u,o=a+(o-c),c=a}return{from:a,toA:o,toB:c}}function hU(t){let e=[];if(t.root.activeElement!=t.contentDOM)return e;let{anchorNode:n,anchorOffset:r,focusNode:i,focusOffset:a}=t.observer.selectionRange;return n&&(e.push(new B2(n,r)),(i!=n||a!=r)&&e.push(new B2(i,a))),e}function pU(t,e){if(t.length==0)return null;let n=t[0].pos,r=t.length==2?t[1].pos:n;return n>-1&&r>-1?Se.single(n+e,r+e):null}class mU{setSelectionOrigin(e){this.lastSelectionOrigin=e,this.lastSelectionTime=Date.now()}constructor(e){this.view=e,this.lastKeyCode=0,this.lastKeyTime=0,this.lastTouchTime=0,this.lastFocusTime=0,this.lastScrollTop=0,this.lastScrollLeft=0,this.pendingIOSKey=void 0,this.tabFocusMode=-1,this.lastSelectionOrigin=null,this.lastSelectionTime=0,this.lastContextMenu=0,this.scrollHandlers=[],this.handlers=Object.create(null),this.composing=-1,this.compositionFirstChange=null,this.compositionEndedAt=0,this.compositionPendingKey=!1,this.compositionPendingChange=!1,this.insertingText="",this.insertingTextAt=0,this.mouseSelection=null,this.draggedContent=null,this.handleEvent=this.handleEvent.bind(this),this.notifiedFocused=e.hasFocus,$e.safari&&e.contentDOM.addEventListener("input",()=>null),$e.gecko&&RU(e.contentDOM.ownerDocument)}handleEvent(e){!wU(this.view,e)||this.ignoreDuringComposition(e)||e.type=="keydown"&&this.keydown(e)||(this.view.updateState!=0?Promise.resolve().then(()=>this.runHandlers(e.type,e)):this.runHandlers(e.type,e))}runHandlers(e,n){let r=this.handlers[e];if(r){for(let i of r.observers)i(this.view,n);for(let i of r.handlers){if(n.defaultPrevented)break;if(i(this.view,n)){n.preventDefault();break}}}}ensureHandlers(e){let n=gU(e),r=this.handlers,i=this.view.contentDOM;for(let a in n)if(a!="scroll"){let o=!n[a].handlers.length,c=r[a];c&&o!=!c.handlers.length&&(i.removeEventListener(a,this.handleEvent),c=null),c||i.addEventListener(a,this.handleEvent,{passive:o})}for(let a in r)a!="scroll"&&!n[a]&&i.removeEventListener(a,this.handleEvent);this.handlers=n}keydown(e){if(this.lastKeyCode=e.keyCode,this.lastKeyTime=Date.now(),e.keyCode==9&&this.tabFocusMode>-1&&(!this.tabFocusMode||Date.now()<=this.tabFocusMode))return!0;if(this.tabFocusMode>0&&e.keyCode!=27&&FP.indexOf(e.keyCode)<0&&(this.tabFocusMode=-1),$e.android&&$e.chrome&&!e.synthetic&&(e.keyCode==13||e.keyCode==8))return this.view.observer.delayAndroidKey(e.key,e.keyCode),!0;let n;return $e.ios&&!e.synthetic&&!e.altKey&&!e.metaKey&&((n=YP.find(r=>r.keyCode==e.keyCode))&&!e.ctrlKey||OU.indexOf(e.key)>-1&&e.ctrlKey&&!e.shiftKey)?(this.pendingIOSKey=n||e,setTimeout(()=>this.flushIOSKey(),250),!0):(e.keyCode!=229&&this.view.observer.forceFlush(),!1)}flushIOSKey(e){let n=this.pendingIOSKey;return!n||n.key=="Enter"&&e&&e.from<e.to&&/^\S+$/.test(e.insert.toString())?!1:(this.pendingIOSKey=void 0,lc(this.view.contentDOM,n.key,n.keyCode,n instanceof KeyboardEvent?n:void 0))}ignoreDuringComposition(e){return!/^key/.test(e.type)||e.synthetic?!1:this.composing>0?!0:$e.safari&&!$e.ios&&this.compositionPendingKey&&Date.now()-this.compositionEndedAt<100?(this.compositionPendingKey=!1,!0):!1}startMouseSelection(e){this.mouseSelection&&this.mouseSelection.destroy(),this.mouseSelection=e}update(e){this.view.observer.update(e),this.mouseSelection&&this.mouseSelection.update(e),this.draggedContent&&e.docChanged&&(this.draggedContent=this.draggedContent.map(e.changes)),e.transactions.length&&(this.lastKeyCode=this.lastSelectionTime=0)}destroy(){this.mouseSelection&&this.mouseSelection.destroy()}}function I2(t,e){return(n,r)=>{try{return e.call(t,r,n)}catch(i){aa(n.state,i)}}}function gU(t){let e=Object.create(null);function n(r){return e[r]||(e[r]={observers:[],handlers:[]})}for(let r of t){let i=r.spec,a=i&&i.plugin.domEventHandlers,o=i&&i.plugin.domEventObservers;if(a)for(let c in a){let u=a[c];u&&n(c).handlers.push(I2(r.value,u))}if(o)for(let c in o){let u=o[c];u&&n(c).observers.push(I2(r.value,u))}}for(let r in _i)n(r).handlers.push(_i[r]);for(let r in ui)n(r).observers.push(ui[r]);return e}const YP=[{key:"Backspace",keyCode:8,inputType:"deleteContentBackward"},{key:"Enter",keyCode:13,inputType:"insertParagraph"},{key:"Enter",keyCode:13,inputType:"insertLineBreak"},{key:"Delete",keyCode:46,inputType:"deleteContentForward"}],OU="dthko",FP=[16,17,18,20,91,92,224,225],Xh=6;function Bh(t){return Math.max(0,t)*.7+8}function vU(t,e){return Math.max(Math.abs(t.clientX-e.clientX),Math.abs(t.clientY-e.clientY))}class yU{constructor(e,n,r,i){this.view=e,this.startEvent=n,this.style=r,this.mustSelect=i,this.scrollSpeed={x:0,y:0},this.scrolling=-1,this.lastEvent=n,this.scrollParents=bq(e.contentDOM),this.atoms=e.state.facet(lf).map(o=>o(e));let a=e.contentDOM.ownerDocument;a.addEventListener("mousemove",this.move=this.move.bind(this)),a.addEventListener("mouseup",this.up=this.up.bind(this)),this.extend=n.shiftKey,this.multiple=e.state.facet(At.allowMultipleSelections)&&bU(e,n),this.dragging=SU(e,n)&&HP(n)==1?null:!1}start(e){this.dragging===!1&&this.select(e)}move(e){if(e.buttons==0)return this.destroy();if(this.dragging||this.dragging==null&&vU(this.startEvent,e)<10)return;this.select(this.lastEvent=e);let n=0,r=0,i=0,a=0,o=this.view.win.innerWidth,c=this.view.win.innerHeight;this.scrollParents.x&&({left:i,right:o}=this.scrollParents.x.getBoundingClientRect()),this.scrollParents.y&&({top:a,bottom:c}=this.scrollParents.y.getBoundingClientRect());let u=LP(this.view);e.clientX-u.left<=i+Xh?n=-Bh(i-e.clientX):e.clientX+u.right>=o-Xh&&(n=Bh(e.clientX-o)),e.clientY-u.top<=a+Xh?r=-Bh(a-e.clientY):e.clientY+u.bottom>=c-Xh&&(r=Bh(e.clientY-c)),this.setScrollSpeed(n,r)}up(e){this.dragging==null&&this.select(this.lastEvent),this.dragging||e.preventDefault(),this.destroy()}destroy(){this.setScrollSpeed(0,0);let e=this.view.contentDOM.ownerDocument;e.removeEventListener("mousemove",this.move),e.removeEventListener("mouseup",this.up),this.view.inputState.mouseSelection=this.view.inputState.draggedContent=null}setScrollSpeed(e,n){this.scrollSpeed={x:e,y:n},e||n?this.scrolling<0&&(this.scrolling=setInterval(()=>this.scroll(),50)):this.scrolling>-1&&(clearInterval(this.scrolling),this.scrolling=-1)}scroll(){let{x:e,y:n}=this.scrollSpeed;e&&this.scrollParents.x&&(this.scrollParents.x.scrollLeft+=e,e=0),n&&this.scrollParents.y&&(this.scrollParents.y.scrollTop+=n,n=0),(e||n)&&this.view.win.scrollBy(e,n),this.dragging===!1&&this.select(this.lastEvent)}select(e){let{view:n}=this,r=XP(this.atoms,this.style.get(e,this.extend,this.multiple));(this.mustSelect||!r.eq(n.state.selection,this.dragging===!1))&&this.view.dispatch({selection:r,userEvent:"select.pointer"}),this.mustSelect=!1}update(e){e.transactions.some(n=>n.isUserEvent("input.type"))?this.destroy():this.style.update(e)&&setTimeout(()=>this.select(this.lastEvent),20)}}function bU(t,e){let n=t.state.facet(CP);return n.length?n[0](e):$e.mac?e.metaKey:e.ctrlKey}function xU(t,e){let n=t.state.facet(TP);return n.length?n[0](e):$e.mac?!e.altKey:!e.ctrlKey}function SU(t,e){let{main:n}=t.state.selection;if(n.empty)return!1;let r=Td(t.root);if(!r||r.rangeCount==0)return!0;let i=r.getRangeAt(0).getClientRects();for(let a=0;a<i.length;a++){let o=i[a];if(o.left<=e.clientX&&o.right>=e.clientX&&o.top<=e.clientY&&o.bottom>=e.clientY)return!0}return!1}function wU(t,e){if(!e.bubbles)return!0;if(e.defaultPrevented)return!1;for(let n=e.target,r;n!=t.contentDOM;n=n.parentNode)if(!n||n.nodeType==11||(r=Rn.get(n))&&r.isWidget()&&!r.isHidden&&r.widget.ignoreEvent(e))return!1;return!0}const _i=Object.create(null),ui=Object.create(null),WP=$e.ie&&$e.ie_version<15||$e.ios&&$e.webkit_version<604;function kU(t){let e=t.dom.parentNode;if(!e)return;let n=e.appendChild(document.createElement("textarea"));n.style.cssText="position: fixed; left: -10000px; top: 10px",n.focus(),setTimeout(()=>{t.focus(),n.remove(),GP(t,n.value)},50)}function ig(t,e,n){for(let r of t.facet(e))n=r(n,t);return n}function GP(t,e){e=ig(t.state,Gx,e);let{state:n}=t,r,i=1,a=n.toText(e),o=a.lines==n.selection.ranges.length;if(sb!=null&&n.selection.ranges.every(u=>u.empty)&&sb==a.toString()){let u=-1;r=n.changeByRange(f=>{let h=n.doc.lineAt(f.from);if(h.from==u)return{range:f};u=h.from;let m=n.toText((o?a.line(i++).text:e)+n.lineBreak);return{changes:{from:h.from,insert:m},range:Se.cursor(f.from+m.length)}})}else o?r=n.changeByRange(u=>{let f=a.line(i++);return{changes:{from:u.from,to:u.to,insert:f.text},range:Se.cursor(u.from+f.length)}}):r=n.replaceSelection(a);t.dispatch(r,{userEvent:"input.paste",scrollIntoView:!0})}ui.scroll=t=>{t.inputState.lastScrollTop=t.scrollDOM.scrollTop,t.inputState.lastScrollLeft=t.scrollDOM.scrollLeft};_i.keydown=(t,e)=>(t.inputState.setSelectionOrigin("select"),e.keyCode==27&&t.inputState.tabFocusMode!=0&&(t.inputState.tabFocusMode=Date.now()+2e3),!1);ui.touchstart=(t,e)=>{t.inputState.lastTouchTime=Date.now(),t.inputState.setSelectionOrigin("select.pointer")};ui.touchmove=t=>{t.inputState.setSelectionOrigin("select.pointer")};_i.mousedown=(t,e)=>{if(t.observer.flush(),t.inputState.lastTouchTime>Date.now()-2e3)return!1;let n=null;for(let r of t.state.facet(EP))if(n=r(t,e),n)break;if(!n&&e.button==0&&(n=TU(t,e)),n){let r=!t.hasFocus;t.inputState.startMouseSelection(new yU(t,e,n,r)),r&&t.observer.ignore(()=>{gP(t.contentDOM);let a=t.root.activeElement;a&&!a.contains(t.contentDOM)&&a.blur()});let i=t.inputState.mouseSelection;if(i)return i.start(e),i.dragging===!1}else t.inputState.setSelectionOrigin("select.pointer");return!1};function q2(t,e,n,r){if(r==1)return Se.cursor(e,n);if(r==2)return nU(t.state,e,n);{let i=t.docView.lineAt(e,n),a=t.state.doc.lineAt(i?i.posAtEnd:e),o=i?i.posAtStart:a.from,c=i?i.posAtEnd:a.to;return c<t.state.doc.length&&c==a.to&&c++,Se.range(o,c)}}const CU=$e.ie&&$e.ie_version<=11;let U2=null,Y2=0,F2=0;function HP(t){if(!CU)return t.detail;let e=U2,n=F2;return U2=t,F2=Date.now(),Y2=!e||n>Date.now()-400&&Math.abs(e.clientX-t.clientX)<2&&Math.abs(e.clientY-t.clientY)<2?(Y2+1)%3:1}function TU(t,e){let n=t.posAndSideAtCoords({x:e.clientX,y:e.clientY},!1),r=HP(e),i=t.state.selection;return{update(a){a.docChanged&&(n.pos=a.changes.mapPos(n.pos),i=i.map(a.changes))},get(a,o,c){let u=t.posAndSideAtCoords({x:a.clientX,y:a.clientY},!1),f,h=q2(t,u.pos,u.assoc,r);if(n.pos!=u.pos&&!o){let m=q2(t,n.pos,n.assoc,r),g=Math.min(m.from,h.from),y=Math.max(m.to,h.to);h=g<h.from?Se.range(g,y):Se.range(y,g)}return o?i.replaceRange(i.main.extend(h.from,h.to)):c&&r==1&&i.ranges.length>1&&(f=EU(i,u.pos))?f:c?i.addRange(h):Se.create([h])}}}function EU(t,e){for(let n=0;n<t.ranges.length;n++){let{from:r,to:i}=t.ranges[n];if(r<=e&&i>=e)return Se.create(t.ranges.slice(0,n).concat(t.ranges.slice(n+1)),t.mainIndex==n?0:t.mainIndex-(t.mainIndex>n?1:0))}return null}_i.dragstart=(t,e)=>{let{selection:{main:n}}=t.state;if(e.target.draggable){let i=t.docView.tile.nearest(e.target);if(i&&i.isWidget()){let a=i.posAtStart,o=a+i.length;(a>=n.to||o<=n.from)&&(n=Se.range(a,o))}}let{inputState:r}=t;return r.mouseSelection&&(r.mouseSelection.dragging=!0),r.draggedContent=n,e.dataTransfer&&(e.dataTransfer.setData("Text",ig(t.state,Hx,t.state.sliceDoc(n.from,n.to))),e.dataTransfer.effectAllowed="copyMove"),!1};_i.dragend=t=>(t.inputState.draggedContent=null,!1);function W2(t,e,n,r){if(n=ig(t.state,Gx,n),!n)return;let i=t.posAtCoords({x:e.clientX,y:e.clientY},!1),{draggedContent:a}=t.inputState,o=r&&a&&xU(t,e)?{from:a.from,to:a.to}:null,c={from:i,insert:n},u=t.state.changes(o?[o,c]:c);t.focus(),t.dispatch({changes:u,selection:{anchor:u.mapPos(i,-1),head:u.mapPos(i,1)},userEvent:o?"move.drop":"input.drop"}),t.inputState.draggedContent=null}_i.drop=(t,e)=>{if(!e.dataTransfer)return!1;if(t.state.readOnly)return!0;let n=e.dataTransfer.files;if(n&&n.length){let r=Array(n.length),i=0,a=()=>{++i==n.length&&W2(t,e,r.filter(o=>o!=null).join(t.state.lineBreak),!1)};for(let o=0;o<n.length;o++){let c=new FileReader;c.onerror=a,c.onload=()=>{/[\x00-\x08\x0e-\x1f]{2}/.test(c.result)||(r[o]=c.result),a()},c.readAsText(n[o])}return!0}else{let r=e.dataTransfer.getData("Text");if(r)return W2(t,e,r,!0),!0}return!1};_i.paste=(t,e)=>{if(t.state.readOnly)return!0;t.observer.flush();let n=WP?null:e.clipboardData;return n?(GP(t,n.getData("text/plain")||n.getData("text/uri-list")),!0):(kU(t),!1)};function QU(t,e){let n=t.dom.parentNode;if(!n)return;let r=n.appendChild(document.createElement("textarea"));r.style.cssText="position: fixed; left: -10000px; top: 10px",r.value=e,r.focus(),r.selectionEnd=e.length,r.selectionStart=0,setTimeout(()=>{r.remove(),t.focus()},50)}function AU(t){let e=[],n=[],r=!1;for(let i of t.selection.ranges)i.empty||(e.push(t.sliceDoc(i.from,i.to)),n.push(i));if(!e.length){let i=-1;for(let{from:a}of t.selection.ranges){let o=t.doc.lineAt(a);o.number>i&&(e.push(o.text),n.push({from:o.from,to:Math.min(t.doc.length,o.to+1)})),i=o.number}r=!0}return{text:ig(t,Hx,e.join(t.lineBreak)),ranges:n,linewise:r}}let sb=null;_i.copy=_i.cut=(t,e)=>{let{text:n,ranges:r,linewise:i}=AU(t.state);if(!n&&!i)return!1;sb=i?n:null,e.type=="cut"&&!t.state.readOnly&&t.dispatch({changes:r,scrollIntoView:!0,userEvent:"delete.cut"});let a=WP?null:e.clipboardData;return a?(a.clearData(),a.setData("text/plain",n),!0):(QU(t,n),!1)};const KP=Ri.define();function JP(t,e){let n=[];for(let r of t.facet(RP)){let i=r(t,e);i&&n.push(i)}return n.length?t.update({effects:n,annotations:KP.of(!0)}):null}function ej(t){setTimeout(()=>{let e=t.hasFocus;if(e!=t.inputState.notifiedFocused){let n=JP(t.state,e);n?t.dispatch(n):t.update([])}},10)}ui.focus=t=>{t.inputState.lastFocusTime=Date.now(),!t.scrollDOM.scrollTop&&(t.inputState.lastScrollTop||t.inputState.lastScrollLeft)&&(t.scrollDOM.scrollTop=t.inputState.lastScrollTop,t.scrollDOM.scrollLeft=t.inputState.lastScrollLeft),ej(t)};ui.blur=t=>{t.observer.clearSelectionRange(),ej(t)};ui.compositionstart=ui.compositionupdate=t=>{t.observer.editContext||(t.inputState.compositionFirstChange==null&&(t.inputState.compositionFirstChange=!0),t.inputState.composing<0&&(t.inputState.composing=0))};ui.compositionend=t=>{t.observer.editContext||(t.inputState.composing=-1,t.inputState.compositionEndedAt=Date.now(),t.inputState.compositionPendingKey=!0,t.inputState.compositionPendingChange=t.observer.pendingRecords().length>0,t.inputState.compositionFirstChange=null,$e.chrome&&$e.android?t.observer.flushSoon():t.inputState.compositionPendingChange?Promise.resolve().then(()=>t.observer.flush()):setTimeout(()=>{t.inputState.composing<0&&t.docView.hasComposition&&t.update([])},50))};ui.contextmenu=t=>{t.inputState.lastContextMenu=Date.now()};_i.beforeinput=(t,e)=>{var n,r;if((e.inputType=="insertText"||e.inputType=="insertCompositionText")&&(t.inputState.insertingText=e.data,t.inputState.insertingTextAt=Date.now()),e.inputType=="insertReplacementText"&&t.observer.editContext){let a=(n=e.dataTransfer)===null||n===void 0?void 0:n.getData("text/plain"),o=e.getTargetRanges();if(a&&o.length){let c=o[0],u=t.posAtDOM(c.startContainer,c.startOffset),f=t.posAtDOM(c.endContainer,c.endOffset);return Jx(t,{from:u,to:f,insert:t.state.toText(a)},null),!0}}let i;if($e.chrome&&$e.android&&(i=YP.find(a=>a.inputType==e.inputType))&&(t.observer.delayAndroidKey(i.key,i.keyCode),i.key=="Backspace"||i.key=="Delete")){let a=((r=window.visualViewport)===null||r===void 0?void 0:r.height)||0;setTimeout(()=>{var o;(((o=window.visualViewport)===null||o===void 0?void 0:o.height)||0)>a+10&&t.hasFocus&&(t.contentDOM.blur(),t.focus())},100)}return $e.ios&&e.inputType=="deleteContentForward"&&t.observer.flushSoon(),$e.safari&&e.inputType=="insertText"&&t.inputState.composing>=0&&setTimeout(()=>ui.compositionend(t,e),20),!1};const G2=new Set;function RU(t){G2.has(t)||(G2.add(t),t.addEventListener("copy",()=>{}),t.addEventListener("cut",()=>{}))}const H2=["pre-wrap","normal","pre-line","break-spaces"];let xc=!1;function K2(){xc=!1}class _U{constructor(e){this.lineWrapping=e,this.doc=St.empty,this.heightSamples={},this.lineHeight=14,this.charWidth=7,this.textHeight=14,this.lineLength=30}heightForGap(e,n){let r=this.doc.lineAt(n).number-this.doc.lineAt(e).number+1;return this.lineWrapping&&(r+=Math.max(0,Math.ceil((n-e-r*this.lineLength*.5)/this.lineLength))),this.lineHeight*r}heightForLine(e){return this.lineWrapping?(1+Math.max(0,Math.ceil((e-this.lineLength)/Math.max(1,this.lineLength-5))))*this.lineHeight:this.lineHeight}setDoc(e){return this.doc=e,this}mustRefreshForWrapping(e){return H2.indexOf(e)>-1!=this.lineWrapping}mustRefreshForHeights(e){let n=!1;for(let r=0;r<e.length;r++){let i=e[r];i<0?r++:this.heightSamples[Math.floor(i*10)]||(n=!0,this.heightSamples[Math.floor(i*10)]=!0)}return n}refresh(e,n,r,i,a,o){let c=H2.indexOf(e)>-1,u=Math.round(n)!=Math.round(this.lineHeight)||this.lineWrapping!=c;if(this.lineWrapping=c,this.lineHeight=n,this.charWidth=r,this.textHeight=i,this.lineLength=a,u){this.heightSamples={};for(let f=0;f<o.length;f++){let h=o[f];h<0?f++:this.heightSamples[Math.floor(h*10)]=!0}}return u}}class $U{constructor(e,n){this.from=e,this.heights=n,this.index=0}get more(){return this.index<this.heights.length}}class Si{constructor(e,n,r,i,a){this.from=e,this.length=n,this.top=r,this.height=i,this._content=a}get type(){return typeof this._content=="number"?Ar.Text:Array.isArray(this._content)?this._content:this._content.type}get to(){return this.from+this.length}get bottom(){return this.top+this.height}get widget(){return this._content instanceof qo?this._content.widget:null}get widgetLineBreaks(){return typeof this._content=="number"?this._content:0}join(e){let n=(Array.isArray(this._content)?this._content:[this]).concat(Array.isArray(e._content)?e._content:[e]);return new Si(this.from,this.length+e.length,this.top,this.height+e.height,n)}}var qt=(function(t){return t[t.ByPos=0]="ByPos",t[t.ByHeight=1]="ByHeight",t[t.ByPosNoHeight=2]="ByPosNoHeight",t})(qt||(qt={}));const xp=.001;class lr{constructor(e,n,r=2){this.length=e,this.height=n,this.flags=r}get outdated(){return(this.flags&2)>0}set outdated(e){this.flags=(e?2:0)|this.flags&-3}setHeight(e){this.height!=e&&(Math.abs(this.height-e)>xp&&(xc=!0),this.height=e)}replace(e,n,r){return lr.of(r)}decomposeLeft(e,n){n.push(this)}decomposeRight(e,n){n.push(this)}applyChanges(e,n,r,i){let a=this,o=r.doc;for(let c=i.length-1;c>=0;c--){let{fromA:u,toA:f,fromB:h,toB:m}=i[c],g=a.lineAt(u,qt.ByPosNoHeight,r.setDoc(n),0,0),y=g.to>=f?g:a.lineAt(f,qt.ByPosNoHeight,r,0,0);for(m+=y.to-f,f=y.to;c>0&&g.from<=i[c-1].toA;)u=i[c-1].fromA,h=i[c-1].fromB,c--,u<g.from&&(g=a.lineAt(u,qt.ByPosNoHeight,r,0,0));h+=g.from-u,u=g.from;let x=e1.build(r.setDoc(o),e,h,m);a=Hp(a,a.replace(u,f,x))}return a.updateHeight(r,0)}static empty(){return new Lr(0,0,0)}static of(e){if(e.length==1)return e[0];let n=0,r=e.length,i=0,a=0;for(;;)if(n==r)if(i>a*2){let c=e[n-1];c.break?e.splice(--n,1,c.left,null,c.right):e.splice(--n,1,c.left,c.right),r+=1+c.break,i-=c.size}else if(a>i*2){let c=e[r];c.break?e.splice(r,1,c.left,null,c.right):e.splice(r,1,c.left,c.right),r+=2+c.break,a-=c.size}else break;else if(i<a){let c=e[n++];c&&(i+=c.size)}else{let c=e[--r];c&&(a+=c.size)}let o=0;return e[n-1]==null?(o=1,n--):e[n]==null&&(o=1,r++),new jU(lr.of(e.slice(0,n)),o,lr.of(e.slice(r)))}}function Hp(t,e){return t==e?t:(t.constructor!=e.constructor&&(xc=!0),e)}lr.prototype.size=1;const PU=dt.replace({});class tj extends lr{constructor(e,n,r){super(e,n),this.deco=r,this.spaceAbove=0}mainBlock(e,n){return new Si(n,this.length,e+this.spaceAbove,this.height-this.spaceAbove,this.deco||0)}blockAt(e,n,r,i){return this.spaceAbove&&e<r+this.spaceAbove?new Si(i,0,r,this.spaceAbove,PU):this.mainBlock(r,i)}lineAt(e,n,r,i,a){let o=this.mainBlock(i,a);return this.spaceAbove?this.blockAt(0,r,i,a).join(o):o}forEachLine(e,n,r,i,a,o){e<=a+this.length&&n>=a&&o(this.lineAt(0,qt.ByPos,r,i,a))}setMeasuredHeight(e){let n=e.heights[e.index++];n<0?(this.spaceAbove=-n,n=e.heights[e.index++]):this.spaceAbove=0,this.setHeight(n)}updateHeight(e,n=0,r=!1,i){return i&&i.from<=n&&i.more&&this.setMeasuredHeight(i),this.outdated=!1,this}toString(){return`block(${this.length})`}}class Lr extends tj{constructor(e,n,r){super(e,n,null),this.collapsed=0,this.widgetHeight=0,this.breaks=0,this.spaceAbove=r}mainBlock(e,n){return new Si(n,this.length,e+this.spaceAbove,this.height-this.spaceAbove,this.breaks)}replace(e,n,r){let i=r[0];return r.length==1&&(i instanceof Lr||i instanceof Bn&&i.flags&4)&&Math.abs(this.length-i.length)<10?(i instanceof Bn?i=new Lr(i.length,this.height,this.spaceAbove):i.height=this.height,this.outdated||(i.outdated=!1),i):lr.of(r)}updateHeight(e,n=0,r=!1,i){return i&&i.from<=n&&i.more?this.setMeasuredHeight(i):(r||this.outdated)&&(this.spaceAbove=0,this.setHeight(Math.max(this.widgetHeight,e.heightForLine(this.length-this.collapsed))+this.breaks*e.lineHeight)),this.outdated=!1,this}toString(){return`line(${this.length}${this.collapsed?-this.collapsed:""}${this.widgetHeight?":"+this.widgetHeight:""})`}}class Bn extends lr{constructor(e){super(e,0)}heightMetrics(e,n){let r=e.doc.lineAt(n).number,i=e.doc.lineAt(n+this.length).number,a=i-r+1,o,c=0;if(e.lineWrapping){let u=Math.min(this.height,e.lineHeight*a);o=u/a,this.length>a+1&&(c=(this.height-u)/(this.length-a-1))}else o=this.height/a;return{firstLine:r,lastLine:i,perLine:o,perChar:c}}blockAt(e,n,r,i){let{firstLine:a,lastLine:o,perLine:c,perChar:u}=this.heightMetrics(n,i);if(n.lineWrapping){let f=i+(e<n.lineHeight?0:Math.round(Math.max(0,Math.min(1,(e-r)/this.height))*this.length)),h=n.doc.lineAt(f),m=c+h.length*u,g=Math.max(r,e-m/2);return new Si(h.from,h.length,g,m,0)}else{let f=Math.max(0,Math.min(o-a,Math.floor((e-r)/c))),{from:h,length:m}=n.doc.line(a+f);return new Si(h,m,r+c*f,c,0)}}lineAt(e,n,r,i,a){if(n==qt.ByHeight)return this.blockAt(e,r,i,a);if(n==qt.ByPosNoHeight){let{from:y,to:x}=r.doc.lineAt(e);return new Si(y,x-y,0,0,0)}let{firstLine:o,perLine:c,perChar:u}=this.heightMetrics(r,a),f=r.doc.lineAt(e),h=c+f.length*u,m=f.number-o,g=i+c*m+u*(f.from-a-m);return new Si(f.from,f.length,Math.max(i,Math.min(g,i+this.height-h)),h,0)}forEachLine(e,n,r,i,a,o){e=Math.max(e,a),n=Math.min(n,a+this.length);let{firstLine:c,perLine:u,perChar:f}=this.heightMetrics(r,a);for(let h=e,m=i;h<=n;){let g=r.doc.lineAt(h);if(h==e){let x=g.number-c;m+=u*x+f*(e-a-x)}let y=u+f*g.length;o(new Si(g.from,g.length,m,y,0)),m+=y,h=g.to+1}}replace(e,n,r){let i=this.length-n;if(i>0){let a=r[r.length-1];a instanceof Bn?r[r.length-1]=new Bn(a.length+i):r.push(null,new Bn(i-1))}if(e>0){let a=r[0];a instanceof Bn?r[0]=new Bn(e+a.length):r.unshift(new Bn(e-1),null)}return lr.of(r)}decomposeLeft(e,n){n.push(new Bn(e-1),null)}decomposeRight(e,n){n.push(null,new Bn(this.length-e-1))}updateHeight(e,n=0,r=!1,i){let a=n+this.length;if(i&&i.from<=n+this.length&&i.more){let o=[],c=Math.max(n,i.from),u=-1;for(i.from>n&&o.push(new Bn(i.from-n-1).updateHeight(e,n));c<=a&&i.more;){let h=e.doc.lineAt(c).length;o.length&&o.push(null);let m=i.heights[i.index++],g=0;m<0&&(g=-m,m=i.heights[i.index++]),u==-1?u=m:Math.abs(m-u)>=xp&&(u=-2);let y=new Lr(h,m,g);y.outdated=!1,o.push(y),c+=h+1}c<=a&&o.push(null,new Bn(a-c).updateHeight(e,c));let f=lr.of(o);return(u<0||Math.abs(f.height-this.height)>=xp||Math.abs(u-this.heightMetrics(e,n).perLine)>=xp)&&(xc=!0),Hp(this,f)}else(r||this.outdated)&&(this.setHeight(e.heightForGap(n,n+this.length)),this.outdated=!1);return this}toString(){return`gap(${this.length})`}}class jU extends lr{constructor(e,n,r){super(e.length+n+r.length,e.height+r.height,n|(e.outdated||r.outdated?2:0)),this.left=e,this.right=r,this.size=e.size+r.size}get break(){return this.flags&1}blockAt(e,n,r,i){let a=r+this.left.height;return e<a?this.left.blockAt(e,n,r,i):this.right.blockAt(e,n,a,i+this.left.length+this.break)}lineAt(e,n,r,i,a){let o=i+this.left.height,c=a+this.left.length+this.break,u=n==qt.ByHeight?e<o:e<c,f=u?this.left.lineAt(e,n,r,i,a):this.right.lineAt(e,n,r,o,c);if(this.break||(u?f.to<c:f.from>c))return f;let h=n==qt.ByPosNoHeight?qt.ByPosNoHeight:qt.ByPos;return u?f.join(this.right.lineAt(c,h,r,o,c)):this.left.lineAt(c,h,r,i,a).join(f)}forEachLine(e,n,r,i,a,o){let c=i+this.left.height,u=a+this.left.length+this.break;if(this.break)e<u&&this.left.forEachLine(e,n,r,i,a,o),n>=u&&this.right.forEachLine(e,n,r,c,u,o);else{let f=this.lineAt(u,qt.ByPos,r,i,a);e<f.from&&this.left.forEachLine(e,f.from-1,r,i,a,o),f.to>=e&&f.from<=n&&o(f),n>f.to&&this.right.forEachLine(f.to+1,n,r,c,u,o)}}replace(e,n,r){let i=this.left.length+this.break;if(n<i)return this.balanced(this.left.replace(e,n,r),this.right);if(e>this.left.length)return this.balanced(this.left,this.right.replace(e-i,n-i,r));let a=[];e>0&&this.decomposeLeft(e,a);let o=a.length;for(let c of r)a.push(c);if(e>0&&J2(a,o-1),n<this.length){let c=a.length;this.decomposeRight(n,a),J2(a,c)}return lr.of(a)}decomposeLeft(e,n){let r=this.left.length;if(e<=r)return this.left.decomposeLeft(e,n);n.push(this.left),this.break&&(r++,e>=r&&n.push(null)),e>r&&this.right.decomposeLeft(e-r,n)}decomposeRight(e,n){let r=this.left.length,i=r+this.break;if(e>=i)return this.right.decomposeRight(e-i,n);e<r&&this.left.decomposeRight(e,n),this.break&&e<i&&n.push(null),n.push(this.right)}balanced(e,n){return e.size>2*n.size||n.size>2*e.size?lr.of(this.break?[e,null,n]:[e,n]):(this.left=Hp(this.left,e),this.right=Hp(this.right,n),this.setHeight(e.height+n.height),this.outdated=e.outdated||n.outdated,this.size=e.size+n.size,this.length=e.length+this.break+n.length,this)}updateHeight(e,n=0,r=!1,i){let{left:a,right:o}=this,c=n+a.length+this.break,u=null;return i&&i.from<=n+a.length&&i.more?u=a=a.updateHeight(e,n,r,i):a.updateHeight(e,n,r),i&&i.from<=c+o.length&&i.more?u=o=o.updateHeight(e,c,r,i):o.updateHeight(e,c,r),u?this.balanced(a,o):(this.height=this.left.height+this.right.height,this.outdated=!1,this)}toString(){return this.left+(this.break?" ":"-")+this.right}}function J2(t,e){let n,r;t[e]==null&&(n=t[e-1])instanceof Bn&&(r=t[e+1])instanceof Bn&&t.splice(e-1,3,new Bn(n.length+1+r.length))}const MU=5;class e1{constructor(e,n){this.pos=e,this.oracle=n,this.nodes=[],this.lineStart=-1,this.lineEnd=-1,this.covering=null,this.writtenTo=e}get isCovered(){return this.covering&&this.nodes[this.nodes.length-1]==this.covering}span(e,n){if(this.lineStart>-1){let r=Math.min(n,this.lineEnd),i=this.nodes[this.nodes.length-1];i instanceof Lr?i.length+=r-this.pos:(r>this.pos||!this.isCovered)&&this.nodes.push(new Lr(r-this.pos,-1,0)),this.writtenTo=r,n>r&&(this.nodes.push(null),this.writtenTo++,this.lineStart=-1)}this.pos=n}point(e,n,r){if(e<n||r.heightRelevant){let i=r.widget?r.widget.estimatedHeight:0,a=r.widget?r.widget.lineBreaks:0;i<0&&(i=this.oracle.lineHeight);let o=n-e;r.block?this.addBlock(new tj(o,i,r)):(o||a||i>=MU)&&this.addLineDeco(i,a,o)}else n>e&&this.span(e,n);this.lineEnd>-1&&this.lineEnd<this.pos&&(this.lineEnd=this.oracle.doc.lineAt(this.pos).to)}enterLine(){if(this.lineStart>-1)return;let{from:e,to:n}=this.oracle.doc.lineAt(this.pos);this.lineStart=e,this.lineEnd=n,this.writtenTo<e&&((this.writtenTo<e-1||this.nodes[this.nodes.length-1]==null)&&this.nodes.push(this.blankContent(this.writtenTo,e-1)),this.nodes.push(null)),this.pos>e&&this.nodes.push(new Lr(this.pos-e,-1,0)),this.writtenTo=this.pos}blankContent(e,n){let r=new Bn(n-e);return this.oracle.doc.lineAt(e).to==n&&(r.flags|=4),r}ensureLine(){this.enterLine();let e=this.nodes.length?this.nodes[this.nodes.length-1]:null;if(e instanceof Lr)return e;let n=new Lr(0,-1,0);return this.nodes.push(n),n}addBlock(e){this.enterLine();let n=e.deco;n&&n.startSide>0&&!this.isCovered&&this.ensureLine(),this.nodes.push(e),this.writtenTo=this.pos=this.pos+e.length,n&&n.endSide>0&&(this.covering=e)}addLineDeco(e,n,r){let i=this.ensureLine();i.length+=r,i.collapsed+=r,i.widgetHeight=Math.max(i.widgetHeight,e),i.breaks+=n,this.writtenTo=this.pos=this.pos+r}finish(e){let n=this.nodes.length==0?null:this.nodes[this.nodes.length-1];this.lineStart>-1&&!(n instanceof Lr)&&!this.isCovered?this.nodes.push(new Lr(0,-1,0)):(this.writtenTo<this.pos||n==null)&&this.nodes.push(this.blankContent(this.writtenTo,this.pos));let r=e;for(let i of this.nodes)i instanceof Lr&&i.updateHeight(this.oracle,r),r+=i?i.length:1;return this.nodes}static build(e,n,r,i){let a=new e1(r,e);return xt.spans(n,r,i,a,0),a.finish(r)}}function NU(t,e,n){let r=new DU;return xt.compare(t,e,n,r,0),r.changes}class DU{constructor(){this.changes=[]}compareRange(){}comparePoint(e,n,r,i){(e<n||r&&r.heightRelevant||i&&i.heightRelevant)&&oc(e,n,this.changes,5)}}function zU(t,e){let n=t.getBoundingClientRect(),r=t.ownerDocument,i=r.defaultView||window,a=Math.max(0,n.left),o=Math.min(i.innerWidth,n.right),c=Math.max(0,n.top),u=Math.min(i.innerHeight,n.bottom);for(let f=t.parentNode;f&&f!=r.body;)if(f.nodeType==1){let h=f,m=window.getComputedStyle(h);if((h.scrollHeight>h.clientHeight||h.scrollWidth>h.clientWidth)&&m.overflow!="visible"){let g=h.getBoundingClientRect();a=Math.max(a,g.left),o=Math.min(o,g.right),c=Math.max(c,g.top),u=Math.min(f==t.parentNode?i.innerHeight:u,g.bottom)}f=m.position=="absolute"||m.position=="fixed"?h.offsetParent:h.parentNode}else if(f.nodeType==11)f=f.host;else break;return{left:a-n.left,right:Math.max(a,o)-n.left,top:c-(n.top+e),bottom:Math.max(c,u)-(n.top+e)}}function LU(t){let e=t.getBoundingClientRect(),n=t.ownerDocument.defaultView||window;return e.left<n.innerWidth&&e.right>0&&e.top<n.innerHeight&&e.bottom>0}function ZU(t,e){let n=t.getBoundingClientRect();return{left:0,right:n.right-n.left,top:e,bottom:n.bottom-(n.top+e)}}class by{constructor(e,n,r,i){this.from=e,this.to=n,this.size=r,this.displaySize=i}static same(e,n){if(e.length!=n.length)return!1;for(let r=0;r<e.length;r++){let i=e[r],a=n[r];if(i.from!=a.from||i.to!=a.to||i.size!=a.size)return!1}return!0}draw(e,n){return dt.replace({widget:new VU(this.displaySize*(n?e.scaleY:e.scaleX),n)}).range(this.from,this.to)}}class VU extends el{constructor(e,n){super(),this.size=e,this.vertical=n}eq(e){return e.size==this.size&&e.vertical==this.vertical}toDOM(){let e=document.createElement("div");return this.vertical?e.style.height=this.size+"px":(e.style.width=this.size+"px",e.style.height="2px",e.style.display="inline-block"),e}get estimatedHeight(){return this.vertical?this.size:-1}}class eE{constructor(e){this.state=e,this.pixelViewport={left:0,right:window.innerWidth,top:0,bottom:0},this.inView=!0,this.paddingTop=0,this.paddingBottom=0,this.contentDOMWidth=0,this.contentDOMHeight=0,this.editorHeight=0,this.editorWidth=0,this.scrollTop=0,this.scrolledToBottom=!1,this.scaleX=1,this.scaleY=1,this.scrollAnchorPos=0,this.scrollAnchorHeight=-1,this.scaler=tE,this.scrollTarget=null,this.printing=!1,this.mustMeasureContent=!0,this.defaultTextDirection=dn.LTR,this.visibleRanges=[],this.mustEnforceCursorAssoc=!1;let n=e.facet(Kx).some(r=>typeof r!="function"&&r.class=="cm-lineWrapping");this.heightOracle=new _U(n),this.stateDeco=e.facet(Qd).filter(r=>typeof r!="function"),this.heightMap=lr.empty().applyChanges(this.stateDeco,St.empty,this.heightOracle.setDoc(e.doc),[new ai(0,0,0,e.doc.length)]);for(let r=0;r<2&&(this.viewport=this.getViewport(0,null),!!this.updateForViewport());r++);this.updateViewportLines(),this.lineGaps=this.ensureLineGaps([]),this.lineGapDeco=dt.set(this.lineGaps.map(r=>r.draw(this,!1))),this.computeVisibleRanges()}updateForViewport(){let e=[this.viewport],{main:n}=this.state.selection;for(let r=0;r<=1;r++){let i=r?n.head:n.anchor;if(!e.some(({from:a,to:o})=>i>=a&&i<=o)){let{from:a,to:o}=this.lineBlockAt(i);e.push(new Ih(a,o))}}return this.viewports=e.sort((r,i)=>r.from-i.from),this.updateScaler()}updateScaler(){let e=this.scaler;return this.scaler=this.heightMap.height<=7e6?tE:new t1(this.heightOracle,this.heightMap,this.viewports),e.eq(this.scaler)?0:2}updateViewportLines(){this.viewportLines=[],this.heightMap.forEachLine(this.viewport.from,this.viewport.to,this.heightOracle.setDoc(this.state.doc),0,0,e=>{this.viewportLines.push(id(e,this.scaler))})}update(e,n=null){this.state=e.state;let r=this.stateDeco;this.stateDeco=this.state.facet(Qd).filter(h=>typeof h!="function");let i=e.changedRanges,a=ai.extendWithRanges(i,NU(r,this.stateDeco,e?e.changes:Qn.empty(this.state.doc.length))),o=this.heightMap.height,c=this.scrolledToBottom?null:this.scrollAnchorAt(this.scrollTop);K2(),this.heightMap=this.heightMap.applyChanges(this.stateDeco,e.startState.doc,this.heightOracle.setDoc(this.state.doc),a),(this.heightMap.height!=o||xc)&&(e.flags|=2),c?(this.scrollAnchorPos=e.changes.mapPos(c.from,-1),this.scrollAnchorHeight=c.top):(this.scrollAnchorPos=-1,this.scrollAnchorHeight=o);let u=a.length?this.mapViewport(this.viewport,e.changes):this.viewport;(n&&(n.range.head<u.from||n.range.head>u.to)||!this.viewportIsAppropriate(u))&&(u=this.getViewport(0,n));let f=u.from!=this.viewport.from||u.to!=this.viewport.to;this.viewport=u,e.flags|=this.updateForViewport(),(f||!e.changes.empty||e.flags&2)&&this.updateViewportLines(),(this.lineGaps.length||this.viewport.to-this.viewport.from>4e3)&&this.updateLineGaps(this.ensureLineGaps(this.mapLineGaps(this.lineGaps,e.changes))),e.flags|=this.computeVisibleRanges(e.changes),n&&(this.scrollTarget=n),!this.mustEnforceCursorAssoc&&e.selectionSet&&e.view.lineWrapping&&e.state.selection.main.empty&&e.state.selection.main.assoc&&!e.state.facet(Pq)&&(this.mustEnforceCursorAssoc=!0)}measure(e){let n=e.contentDOM,r=window.getComputedStyle(n),i=this.heightOracle,a=r.whiteSpace;this.defaultTextDirection=r.direction=="rtl"?dn.RTL:dn.LTR;let o=this.heightOracle.mustRefreshForWrapping(a),c=n.getBoundingClientRect(),u=o||this.mustMeasureContent||this.contentDOMHeight!=c.height;this.contentDOMHeight=c.height,this.mustMeasureContent=!1;let f=0,h=0;if(c.width&&c.height){let{scaleX:R,scaleY:$}=mP(n,c);(R>.005&&Math.abs(this.scaleX-R)>.005||$>.005&&Math.abs(this.scaleY-$)>.005)&&(this.scaleX=R,this.scaleY=$,f|=16,o=u=!0)}let m=(parseInt(r.paddingTop)||0)*this.scaleY,g=(parseInt(r.paddingBottom)||0)*this.scaleY;(this.paddingTop!=m||this.paddingBottom!=g)&&(this.paddingTop=m,this.paddingBottom=g,f|=18),this.editorWidth!=e.scrollDOM.clientWidth&&(i.lineWrapping&&(u=!0),this.editorWidth=e.scrollDOM.clientWidth,f|=16);let y=e.scrollDOM.scrollTop*this.scaleY;this.scrollTop!=y&&(this.scrollAnchorHeight=-1,this.scrollTop=y),this.scrolledToBottom=OP(e.scrollDOM);let x=(this.printing?ZU:zU)(n,this.paddingTop),S=x.top-this.pixelViewport.top,k=x.bottom-this.pixelViewport.bottom;this.pixelViewport=x;let T=this.pixelViewport.bottom>this.pixelViewport.top&&this.pixelViewport.right>this.pixelViewport.left;if(T!=this.inView&&(this.inView=T,T&&(u=!0)),!this.inView&&!this.scrollTarget&&!LU(e.dom))return 0;let C=c.width;if((this.contentDOMWidth!=C||this.editorHeight!=e.scrollDOM.clientHeight)&&(this.contentDOMWidth=c.width,this.editorHeight=e.scrollDOM.clientHeight,f|=16),u){let R=e.docView.measureVisibleLineHeights(this.viewport);if(i.mustRefreshForHeights(R)&&(o=!0),o||i.lineWrapping&&Math.abs(C-this.contentDOMWidth)>i.charWidth){let{lineHeight:$,charWidth:P,textHeight:_}=e.docView.measureTextSize();o=$>0&&i.refresh(a,$,P,_,Math.max(5,C/P),R),o&&(e.docView.minWidth=0,f|=16)}S>0&&k>0?h=Math.max(S,k):S<0&&k<0&&(h=Math.min(S,k)),K2();for(let $ of this.viewports){let P=$.from==this.viewport.from?R:e.docView.measureVisibleLineHeights($);this.heightMap=(o?lr.empty().applyChanges(this.stateDeco,St.empty,this.heightOracle,[new ai(0,0,0,e.state.doc.length)]):this.heightMap).updateHeight(i,0,o,new $U($.from,P))}xc&&(f|=2)}let E=!this.viewportIsAppropriate(this.viewport,h)||this.scrollTarget&&(this.scrollTarget.range.head<this.viewport.from||this.scrollTarget.range.head>this.viewport.to);return E&&(f&2&&(f|=this.updateScaler()),this.viewport=this.getViewport(h,this.scrollTarget),f|=this.updateForViewport()),(f&2||E)&&this.updateViewportLines(),(this.lineGaps.length||this.viewport.to-this.viewport.from>4e3)&&this.updateLineGaps(this.ensureLineGaps(o?[]:this.lineGaps,e)),f|=this.computeVisibleRanges(),this.mustEnforceCursorAssoc&&(this.mustEnforceCursorAssoc=!1,e.docView.enforceCursorAssoc()),f}get visibleTop(){return this.scaler.fromDOM(this.pixelViewport.top)}get visibleBottom(){return this.scaler.fromDOM(this.pixelViewport.bottom)}getViewport(e,n){let r=.5-Math.max(-.5,Math.min(.5,e/1e3/2)),i=this.heightMap,a=this.heightOracle,{visibleTop:o,visibleBottom:c}=this,u=new Ih(i.lineAt(o-r*1e3,qt.ByHeight,a,0,0).from,i.lineAt(c+(1-r)*1e3,qt.ByHeight,a,0,0).to);if(n){let{head:f}=n.range;if(f<u.from||f>u.to){let h=Math.min(this.editorHeight,this.pixelViewport.bottom-this.pixelViewport.top),m=i.lineAt(f,qt.ByPos,a,0,0),g;n.y=="center"?g=(m.top+m.bottom)/2-h/2:n.y=="start"||n.y=="nearest"&&f<u.from?g=m.top:g=m.bottom-h,u=new Ih(i.lineAt(g-1e3/2,qt.ByHeight,a,0,0).from,i.lineAt(g+h+1e3/2,qt.ByHeight,a,0,0).to)}}return u}mapViewport(e,n){let r=n.mapPos(e.from,-1),i=n.mapPos(e.to,1);return new Ih(this.heightMap.lineAt(r,qt.ByPos,this.heightOracle,0,0).from,this.heightMap.lineAt(i,qt.ByPos,this.heightOracle,0,0).to)}viewportIsAppropriate({from:e,to:n},r=0){if(!this.inView)return!0;let{top:i}=this.heightMap.lineAt(e,qt.ByPos,this.heightOracle,0,0),{bottom:a}=this.heightMap.lineAt(n,qt.ByPos,this.heightOracle,0,0),{visibleTop:o,visibleBottom:c}=this;return(e==0||i<=o-Math.max(10,Math.min(-r,250)))&&(n==this.state.doc.length||a>=c+Math.max(10,Math.min(r,250)))&&i>o-2*1e3&&a<c+2*1e3}mapLineGaps(e,n){if(!e.length||n.empty)return e;let r=[];for(let i of e)n.touchesRange(i.from,i.to)||r.push(new by(n.mapPos(i.from),n.mapPos(i.to),i.size,i.displaySize));return r}ensureLineGaps(e,n){let r=this.heightOracle.lineWrapping,i=r?1e4:2e3,a=i>>1,o=i<<1;if(this.defaultTextDirection!=dn.LTR&&!r)return[];let c=[],u=(h,m,g,y)=>{if(m-h<a)return;let x=this.state.selection.main,S=[x.from];x.empty||S.push(x.to);for(let T of S)if(T>h&&T<m){u(h,T-10,g,y),u(T+10,m,g,y);return}let k=BU(e,T=>T.from>=g.from&&T.to<=g.to&&Math.abs(T.from-h)<a&&Math.abs(T.to-m)<a&&!S.some(C=>T.from<C&&T.to>C));if(!k){if(m<g.to&&n&&r&&n.visibleRanges.some(E=>E.from<=m&&E.to>=m)){let E=n.moveToLineBoundary(Se.cursor(m),!1,!0).head;E>h&&(m=E)}let T=this.gapSize(g,h,m,y),C=r||T<2e6?T:2e6;k=new by(h,m,T,C)}c.push(k)},f=h=>{if(h.length<o||h.type!=Ar.Text)return;let m=XU(h.from,h.to,this.stateDeco);if(m.total<o)return;let g=this.scrollTarget?this.scrollTarget.range.head:null,y,x;if(r){let S=i/this.heightOracle.lineLength*this.heightOracle.lineHeight,k,T;if(g!=null){let C=Uh(m,g),E=((this.visibleBottom-this.visibleTop)/2+S)/h.height;k=C-E,T=C+E}else k=(this.visibleTop-h.top-S)/h.height,T=(this.visibleBottom-h.top+S)/h.height;y=qh(m,k),x=qh(m,T)}else{let S=m.total*this.heightOracle.charWidth,k=i*this.heightOracle.charWidth,T=0;if(S>2e6)for(let P of e)P.from>=h.from&&P.from<h.to&&P.size!=P.displaySize&&P.from*this.heightOracle.charWidth+T<this.pixelViewport.left&&(T=P.size-P.displaySize);let C=this.pixelViewport.left+T,E=this.pixelViewport.right+T,R,$;if(g!=null){let P=Uh(m,g),_=((E-C)/2+k)/S;R=P-_,$=P+_}else R=(C-k)/S,$=(E+k)/S;y=qh(m,R),x=qh(m,$)}y>h.from&&u(h.from,y,h,m),x<h.to&&u(x,h.to,h,m)};for(let h of this.viewportLines)Array.isArray(h.type)?h.type.forEach(f):f(h);return c}gapSize(e,n,r,i){let a=Uh(i,r)-Uh(i,n);return this.heightOracle.lineWrapping?e.height*a:i.total*this.heightOracle.charWidth*a}updateLineGaps(e){by.same(e,this.lineGaps)||(this.lineGaps=e,this.lineGapDeco=dt.set(e.map(n=>n.draw(this,this.heightOracle.lineWrapping))))}computeVisibleRanges(e){let n=this.stateDeco;this.lineGaps.length&&(n=n.concat(this.lineGapDeco));let r=[];xt.spans(n,this.viewport.from,this.viewport.to,{span(a,o){r.push({from:a,to:o})},point(){}},20);let i=0;if(r.length!=this.visibleRanges.length)i=12;else for(let a=0;a<r.length&&!(i&8);a++){let o=this.visibleRanges[a],c=r[a];(o.from!=c.from||o.to!=c.to)&&(i|=4,e&&e.mapPos(o.from,-1)==c.from&&e.mapPos(o.to,1)==c.to||(i|=8))}return this.visibleRanges=r,i}lineBlockAt(e){return e>=this.viewport.from&&e<=this.viewport.to&&this.viewportLines.find(n=>n.from<=e&&n.to>=e)||id(this.heightMap.lineAt(e,qt.ByPos,this.heightOracle,0,0),this.scaler)}lineBlockAtHeight(e){return e>=this.viewportLines[0].top&&e<=this.viewportLines[this.viewportLines.length-1].bottom&&this.viewportLines.find(n=>n.top<=e&&n.bottom>=e)||id(this.heightMap.lineAt(this.scaler.fromDOM(e),qt.ByHeight,this.heightOracle,0,0),this.scaler)}scrollAnchorAt(e){let n=this.lineBlockAtHeight(e+8);return n.from>=this.viewport.from||this.viewportLines[0].top-e>200?n:this.viewportLines[0]}elementAtHeight(e){return id(this.heightMap.blockAt(this.scaler.fromDOM(e),this.heightOracle,0,0),this.scaler)}get docHeight(){return this.scaler.toDOM(this.heightMap.height)}get contentHeight(){return this.docHeight+this.paddingTop+this.paddingBottom}}let Ih=class{constructor(e,n){this.from=e,this.to=n}};function XU(t,e,n){let r=[],i=t,a=0;return xt.spans(n,t,e,{span(){},point(o,c){o>i&&(r.push({from:i,to:o}),a+=o-i),i=c}},20),i<e&&(r.push({from:i,to:e}),a+=e-i),{total:a,ranges:r}}function qh({total:t,ranges:e},n){if(n<=0)return e[0].from;if(n>=1)return e[e.length-1].to;let r=Math.floor(t*n);for(let i=0;;i++){let{from:a,to:o}=e[i],c=o-a;if(r<=c)return a+r;r-=c}}function Uh(t,e){let n=0;for(let{from:r,to:i}of t.ranges){if(e<=i){n+=e-r;break}n+=i-r}return n/t.total}function BU(t,e){for(let n of t)if(e(n))return n}const tE={toDOM(t){return t},fromDOM(t){return t},scale:1,eq(t){return t==this}};class t1{constructor(e,n,r){let i=0,a=0,o=0;this.viewports=r.map(({from:c,to:u})=>{let f=n.lineAt(c,qt.ByPos,e,0,0).top,h=n.lineAt(u,qt.ByPos,e,0,0).bottom;return i+=h-f,{from:c,to:u,top:f,bottom:h,domTop:0,domBottom:0}}),this.scale=(7e6-i)/(n.height-i);for(let c of this.viewports)c.domTop=o+(c.top-a)*this.scale,o=c.domBottom=c.domTop+(c.bottom-c.top),a=c.bottom}toDOM(e){for(let n=0,r=0,i=0;;n++){let a=n<this.viewports.length?this.viewports[n]:null;if(!a||e<a.top)return i+(e-r)*this.scale;if(e<=a.bottom)return a.domTop+(e-a.top);r=a.bottom,i=a.domBottom}}fromDOM(e){for(let n=0,r=0,i=0;;n++){let a=n<this.viewports.length?this.viewports[n]:null;if(!a||e<a.domTop)return r+(e-i)/this.scale;if(e<=a.domBottom)return a.top+(e-a.domTop);r=a.bottom,i=a.domBottom}}eq(e){return e instanceof t1?this.scale==e.scale&&this.viewports.length==e.viewports.length&&this.viewports.every((n,r)=>n.from==e.viewports[r].from&&n.to==e.viewports[r].to):!1}}function id(t,e){if(e.scale==1)return t;let n=e.toDOM(t.top),r=e.toDOM(t.bottom);return new Si(t.from,t.length,n,r-n,Array.isArray(t._content)?t._content.map(i=>id(i,e)):t._content)}const Yh=Xe.define({combine:t=>t.join(" ")}),ob=Xe.define({combine:t=>t.indexOf(!0)>-1}),lb=Is.newName(),nj=Is.newName(),rj=Is.newName(),ij={"&light":"."+nj,"&dark":"."+rj};function cb(t,e,n){return new Is(e,{finish(r){return/&/.test(r)?r.replace(/&\w*/,i=>{if(i=="&")return t;if(!n||!n[i])throw new RangeError(`Unsupported selector: ${i}`);return n[i]}):t+" "+r}})}const IU=cb("."+lb,{"&":{position:"relative !important",boxSizing:"border-box","&.cm-focused":{outline:"1px dotted #212121"},display:"flex !important",flexDirection:"column"},".cm-scroller":{display:"flex !important",alignItems:"flex-start !important",fontFamily:"monospace",lineHeight:1.4,height:"100%",overflowX:"auto",position:"relative",zIndex:0,overflowAnchor:"none"},".cm-content":{margin:0,flexGrow:2,flexShrink:0,display:"block",whiteSpace:"pre",wordWrap:"normal",boxSizing:"border-box",minHeight:"100%",padding:"4px 0",outline:"none","&[contenteditable=true]":{WebkitUserModify:"read-write-plaintext-only"}},".cm-lineWrapping":{whiteSpace_fallback:"pre-wrap",whiteSpace:"break-spaces",wordBreak:"break-word",overflowWrap:"anywhere",flexShrink:1},"&light .cm-content":{caretColor:"black"},"&dark .cm-content":{caretColor:"white"},".cm-line":{display:"block",padding:"0 2px 0 6px"},".cm-layer":{position:"absolute",left:0,top:0,contain:"size style","& > *":{position:"absolute"}},"&light .cm-selectionBackground":{background:"#d9d9d9"},"&dark .cm-selectionBackground":{background:"#222"},"&light.cm-focused > .cm-scroller > .cm-selectionLayer .cm-selectionBackground":{background:"#d7d4f0"},"&dark.cm-focused > .cm-scroller > .cm-selectionLayer .cm-selectionBackground":{background:"#233"},".cm-cursorLayer":{pointerEvents:"none"},"&.cm-focused > .cm-scroller > .cm-cursorLayer":{animation:"steps(1) cm-blink 1.2s infinite"},"@keyframes cm-blink":{"0%":{},"50%":{opacity:0},"100%":{}},"@keyframes cm-blink2":{"0%":{},"50%":{opacity:0},"100%":{}},".cm-cursor, .cm-dropCursor":{borderLeft:"1.2px solid black",marginLeft:"-0.6px",pointerEvents:"none"},".cm-cursor":{display:"none"},"&dark .cm-cursor":{borderLeftColor:"#ddd"},".cm-dropCursor":{position:"absolute"},"&.cm-focused > .cm-scroller > .cm-cursorLayer .cm-cursor":{display:"block"},".cm-iso":{unicodeBidi:"isolate"},".cm-announced":{position:"fixed",top:"-10000px"},"@media print":{".cm-announced":{display:"none"}},"&light .cm-activeLine":{backgroundColor:"#cceeff44"},"&dark .cm-activeLine":{backgroundColor:"#99eeff33"},"&light .cm-specialChar":{color:"red"},"&dark .cm-specialChar":{color:"#f78"},".cm-gutters":{flexShrink:0,display:"flex",height:"100%",boxSizing:"border-box",zIndex:200},".cm-gutters-before":{insetInlineStart:0},".cm-gutters-after":{insetInlineEnd:0},"&light .cm-gutters":{backgroundColor:"#f5f5f5",color:"#6c6c6c",border:"0px solid #ddd","&.cm-gutters-before":{borderRightWidth:"1px"},"&.cm-gutters-after":{borderLeftWidth:"1px"}},"&dark .cm-gutters":{backgroundColor:"#333338",color:"#ccc"},".cm-gutter":{display:"flex !important",flexDirection:"column",flexShrink:0,boxSizing:"border-box",minHeight:"100%",overflow:"hidden"},".cm-gutterElement":{boxSizing:"border-box"},".cm-lineNumbers .cm-gutterElement":{padding:"0 3px 0 5px",minWidth:"20px",textAlign:"right",whiteSpace:"nowrap"},"&light .cm-activeLineGutter":{backgroundColor:"#e2f2ff"},"&dark .cm-activeLineGutter":{backgroundColor:"#222227"},".cm-panels":{boxSizing:"border-box",position:"sticky",left:0,right:0,zIndex:300},"&light .cm-panels":{backgroundColor:"#f5f5f5",color:"black"},"&light .cm-panels-top":{borderBottom:"1px solid #ddd"},"&light .cm-panels-bottom":{borderTop:"1px solid #ddd"},"&dark .cm-panels":{backgroundColor:"#333338",color:"white"},".cm-dialog":{padding:"2px 19px 4px 6px",position:"relative","& label":{fontSize:"80%"}},".cm-dialog-close":{position:"absolute",top:"3px",right:"4px",backgroundColor:"inherit",border:"none",font:"inherit",fontSize:"14px",padding:"0"},".cm-tab":{display:"inline-block",overflow:"hidden",verticalAlign:"bottom"},".cm-widgetBuffer":{verticalAlign:"text-top",height:"1em",width:0,display:"inline"},".cm-placeholder":{color:"#888",display:"inline-block",verticalAlign:"top",userSelect:"none"},".cm-highlightSpace":{backgroundImage:"radial-gradient(circle at 50% 55%, #aaa 20%, transparent 5%)",backgroundPosition:"center"},".cm-highlightTab":{backgroundImage:`url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" width="200" height="20"><path stroke="%23888" stroke-width="1" fill="none" d="M1 10H196L190 5M190 15L196 10M197 4L197 16"/></svg>')`,backgroundSize:"auto 100%",backgroundPosition:"right 90%",backgroundRepeat:"no-repeat"},".cm-trailingSpace":{backgroundColor:"#ff332255"},".cm-button":{verticalAlign:"middle",color:"inherit",fontSize:"70%",padding:".2em 1em",borderRadius:"1px"},"&light .cm-button":{backgroundImage:"linear-gradient(#eff1f5, #d9d9df)",border:"1px solid #888","&:active":{backgroundImage:"linear-gradient(#b4b4b4, #d0d3d6)"}},"&dark .cm-button":{backgroundImage:"linear-gradient(#393939, #111)",border:"1px solid #888","&:active":{backgroundImage:"linear-gradient(#111, #333)"}},".cm-textfield":{verticalAlign:"middle",color:"inherit",fontSize:"70%",border:"1px solid silver",padding:".2em .5em"},"&light .cm-textfield":{backgroundColor:"white"},"&dark .cm-textfield":{border:"1px solid #555",backgroundColor:"inherit"}},ij),qU={childList:!0,characterData:!0,subtree:!0,attributes:!0,characterDataOldValue:!0},xy=$e.ie&&$e.ie_version<=11;class UU{constructor(e){this.view=e,this.active=!1,this.editContext=null,this.selectionRange=new xq,this.selectionChanged=!1,this.delayedFlush=-1,this.resizeTimeout=-1,this.queue=[],this.delayedAndroidKey=null,this.flushingAndroidKey=-1,this.lastChange=0,this.scrollTargets=[],this.intersection=null,this.resizeScroll=null,this.intersecting=!1,this.gapIntersection=null,this.gaps=[],this.printQuery=null,this.parentCheck=-1,this.dom=e.contentDOM,this.observer=new MutationObserver(n=>{for(let r of n)this.queue.push(r);($e.ie&&$e.ie_version<=11||$e.ios&&e.composing)&&n.some(r=>r.type=="childList"&&r.removedNodes.length||r.type=="characterData"&&r.oldValue.length>r.target.nodeValue.length)?this.flushSoon():this.flush()}),window.EditContext&&$e.android&&e.constructor.EDIT_CONTEXT!==!1&&!($e.chrome&&$e.chrome_version<126)&&(this.editContext=new FU(e),e.state.facet(Za)&&(e.contentDOM.editContext=this.editContext.editContext)),xy&&(this.onCharData=n=>{this.queue.push({target:n.target,type:"characterData",oldValue:n.prevValue}),this.flushSoon()}),this.onSelectionChange=this.onSelectionChange.bind(this),this.onResize=this.onResize.bind(this),this.onPrint=this.onPrint.bind(this),this.onScroll=this.onScroll.bind(this),window.matchMedia&&(this.printQuery=window.matchMedia("print")),typeof ResizeObserver=="function"&&(this.resizeScroll=new ResizeObserver(()=>{var n;((n=this.view.docView)===null||n===void 0?void 0:n.lastUpdate)<Date.now()-75&&this.onResize()}),this.resizeScroll.observe(e.scrollDOM)),this.addWindowListeners(this.win=e.win),this.start(),typeof IntersectionObserver=="function"&&(this.intersection=new IntersectionObserver(n=>{this.parentCheck<0&&(this.parentCheck=setTimeout(this.listenForScroll.bind(this),1e3)),n.length>0&&n[n.length-1].intersectionRatio>0!=this.intersecting&&(this.intersecting=!this.intersecting,this.intersecting!=this.view.inView&&this.onScrollChanged(document.createEvent("Event")))},{threshold:[0,.001]}),this.intersection.observe(this.dom),this.gapIntersection=new IntersectionObserver(n=>{n.length>0&&n[n.length-1].intersectionRatio>0&&this.onScrollChanged(document.createEvent("Event"))},{})),this.listenForScroll(),this.readSelectionRange()}onScrollChanged(e){this.view.inputState.runHandlers("scroll",e),this.intersecting&&this.view.measure()}onScroll(e){this.intersecting&&this.flush(!1),this.editContext&&this.view.requestMeasure(this.editContext.measureReq),this.onScrollChanged(e)}onResize(){this.resizeTimeout<0&&(this.resizeTimeout=setTimeout(()=>{this.resizeTimeout=-1,this.view.requestMeasure()},50))}onPrint(e){(e.type=="change"||!e.type)&&!e.matches||(this.view.viewState.printing=!0,this.view.measure(),setTimeout(()=>{this.view.viewState.printing=!1,this.view.requestMeasure()},500))}updateGaps(e){if(this.gapIntersection&&(e.length!=this.gaps.length||this.gaps.some((n,r)=>n!=e[r]))){this.gapIntersection.disconnect();for(let n of e)this.gapIntersection.observe(n);this.gaps=e}}onSelectionChange(e){let n=this.selectionChanged;if(!this.readSelectionRange()||this.delayedAndroidKey)return;let{view:r}=this,i=this.selectionRange;if(r.state.facet(Za)?r.root.activeElement!=this.dom:!yp(this.dom,i))return;let a=i.anchorNode&&r.docView.tile.nearest(i.anchorNode);if(a&&a.isWidget()&&a.widget.ignoreEvent(e)){n||(this.selectionChanged=!1);return}($e.ie&&$e.ie_version<=11||$e.android&&$e.chrome)&&!r.state.selection.main.empty&&i.focusNode&&ud(i.focusNode,i.focusOffset,i.anchorNode,i.anchorOffset)?this.flushSoon():this.flush(!1)}readSelectionRange(){let{view:e}=this,n=Td(e.root);if(!n)return!1;let r=$e.safari&&e.root.nodeType==11&&e.root.activeElement==this.dom&&YU(this.view,n)||n;if(!r||this.selectionRange.eq(r))return!1;let i=yp(this.dom,r);return i&&!this.selectionChanged&&e.inputState.lastFocusTime>Date.now()-200&&e.inputState.lastTouchTime<Date.now()-300&&wq(this.dom,r)?(this.view.inputState.lastFocusTime=0,e.docView.updateSelection(),!1):(this.selectionRange.setRange(r),i&&(this.selectionChanged=!0),!0)}setSelectionRange(e,n){this.selectionRange.set(e.node,e.offset,n.node,n.offset),this.selectionChanged=!1}clearSelectionRange(){this.selectionRange.set(null,0,null,0)}listenForScroll(){this.parentCheck=-1;let e=0,n=null;for(let r=this.dom;r;)if(r.nodeType==1)!n&&e<this.scrollTargets.length&&this.scrollTargets[e]==r?e++:n||(n=this.scrollTargets.slice(0,e)),n&&n.push(r),r=r.assignedSlot||r.parentNode;else if(r.nodeType==11)r=r.host;else break;if(e<this.scrollTargets.length&&!n&&(n=this.scrollTargets.slice(0,e)),n){for(let r of this.scrollTargets)r.removeEventListener("scroll",this.onScroll);for(let r of this.scrollTargets=n)r.addEventListener("scroll",this.onScroll)}}ignore(e){if(!this.active)return e();try{return this.stop(),e()}finally{this.start(),this.clear()}}start(){this.active||(this.observer.observe(this.dom,qU),xy&&this.dom.addEventListener("DOMCharacterDataModified",this.onCharData),this.active=!0)}stop(){this.active&&(this.active=!1,this.observer.disconnect(),xy&&this.dom.removeEventListener("DOMCharacterDataModified",this.onCharData))}clear(){this.processRecords(),this.queue.length=0,this.selectionChanged=!1}delayAndroidKey(e,n){var r;if(!this.delayedAndroidKey){let i=()=>{let a=this.delayedAndroidKey;a&&(this.clearDelayedAndroidKey(),this.view.inputState.lastKeyCode=a.keyCode,this.view.inputState.lastKeyTime=Date.now(),!this.flush()&&a.force&&lc(this.dom,a.key,a.keyCode))};this.flushingAndroidKey=this.view.win.requestAnimationFrame(i)}(!this.delayedAndroidKey||e=="Enter")&&(this.delayedAndroidKey={key:e,keyCode:n,force:this.lastChange<Date.now()-50||!!(!((r=this.delayedAndroidKey)===null||r===void 0)&&r.force)})}clearDelayedAndroidKey(){this.win.cancelAnimationFrame(this.flushingAndroidKey),this.delayedAndroidKey=null,this.flushingAndroidKey=-1}flushSoon(){this.delayedFlush<0&&(this.delayedFlush=this.view.win.requestAnimationFrame(()=>{this.delayedFlush=-1,this.flush()}))}forceFlush(){this.delayedFlush>=0&&(this.view.win.cancelAnimationFrame(this.delayedFlush),this.delayedFlush=-1),this.flush()}pendingRecords(){for(let e of this.observer.takeRecords())this.queue.push(e);return this.queue}processRecords(){let e=this.pendingRecords();e.length&&(this.queue=[]);let n=-1,r=-1,i=!1;for(let a of e){let o=this.readMutation(a);o&&(o.typeOver&&(i=!0),n==-1?{from:n,to:r}=o:(n=Math.min(o.from,n),r=Math.max(o.to,r)))}return{from:n,to:r,typeOver:i}}readChange(){let{from:e,to:n,typeOver:r}=this.processRecords(),i=this.selectionChanged&&yp(this.dom,this.selectionRange);if(e<0&&!i)return null;e>-1&&(this.lastChange=Date.now()),this.view.inputState.lastFocusTime=0,this.selectionChanged=!1;let a=new dU(this.view,e,n,r);return this.view.docView.domChanged={newSel:a.newSel?a.newSel.main:null},a}flush(e=!0){if(this.delayedFlush>=0||this.delayedAndroidKey)return!1;e&&this.readSelectionRange();let n=this.readChange();if(!n)return this.view.requestMeasure(),!1;let r=this.view.state,i=qP(this.view,n);return this.view.state==r&&(n.domChanged||n.newSel&&!n.newSel.main.eq(this.view.state.selection.main))&&this.view.update([]),i}readMutation(e){let n=this.view.docView.tile.nearest(e.target);if(!n||n.isWidget())return null;if(n.markDirty(e.type=="attributes"),e.type=="childList"){let r=nE(n,e.previousSibling||e.target.previousSibling,-1),i=nE(n,e.nextSibling||e.target.nextSibling,1);return{from:r?n.posAfter(r):n.posAtStart,to:i?n.posBefore(i):n.posAtEnd,typeOver:!1}}else return e.type=="characterData"?{from:n.posAtStart,to:n.posAtEnd,typeOver:e.target.nodeValue==e.oldValue}:null}setWindow(e){e!=this.win&&(this.removeWindowListeners(this.win),this.win=e,this.addWindowListeners(this.win))}addWindowListeners(e){e.addEventListener("resize",this.onResize),this.printQuery?this.printQuery.addEventListener?this.printQuery.addEventListener("change",this.onPrint):this.printQuery.addListener(this.onPrint):e.addEventListener("beforeprint",this.onPrint),e.addEventListener("scroll",this.onScroll),e.document.addEventListener("selectionchange",this.onSelectionChange)}removeWindowListeners(e){e.removeEventListener("scroll",this.onScroll),e.removeEventListener("resize",this.onResize),this.printQuery?this.printQuery.removeEventListener?this.printQuery.removeEventListener("change",this.onPrint):this.printQuery.removeListener(this.onPrint):e.removeEventListener("beforeprint",this.onPrint),e.document.removeEventListener("selectionchange",this.onSelectionChange)}update(e){this.editContext&&(this.editContext.update(e),e.startState.facet(Za)!=e.state.facet(Za)&&(e.view.contentDOM.editContext=e.state.facet(Za)?this.editContext.editContext:null))}destroy(){var e,n,r;this.stop(),(e=this.intersection)===null||e===void 0||e.disconnect(),(n=this.gapIntersection)===null||n===void 0||n.disconnect(),(r=this.resizeScroll)===null||r===void 0||r.disconnect();for(let i of this.scrollTargets)i.removeEventListener("scroll",this.onScroll);this.removeWindowListeners(this.win),clearTimeout(this.parentCheck),clearTimeout(this.resizeTimeout),this.win.cancelAnimationFrame(this.delayedFlush),this.win.cancelAnimationFrame(this.flushingAndroidKey),this.editContext&&(this.view.contentDOM.editContext=null,this.editContext.destroy())}}function nE(t,e,n){for(;e;){let r=Rn.get(e);if(r&&r.parent==t)return r;let i=e.parentNode;e=i!=t.dom?i:n>0?e.nextSibling:e.previousSibling}return null}function rE(t,e){let n=e.startContainer,r=e.startOffset,i=e.endContainer,a=e.endOffset,o=t.docView.domAtPos(t.state.selection.main.anchor,1);return ud(o.node,o.offset,i,a)&&([n,r,i,a]=[i,a,n,r]),{anchorNode:n,anchorOffset:r,focusNode:i,focusOffset:a}}function YU(t,e){if(e.getComposedRanges){let i=e.getComposedRanges(t.root)[0];if(i)return rE(t,i)}let n=null;function r(i){i.preventDefault(),i.stopImmediatePropagation(),n=i.getTargetRanges()[0]}return t.contentDOM.addEventListener("beforeinput",r,!0),t.dom.ownerDocument.execCommand("indent"),t.contentDOM.removeEventListener("beforeinput",r,!0),n?rE(t,n):null}class FU{constructor(e){this.from=0,this.to=0,this.pendingContextChange=null,this.handlers=Object.create(null),this.composing=null,this.resetRange(e.state);let n=this.editContext=new window.EditContext({text:e.state.doc.sliceString(this.from,this.to),selectionStart:this.toContextPos(Math.max(this.from,Math.min(this.to,e.state.selection.main.anchor))),selectionEnd:this.toContextPos(e.state.selection.main.head)});this.handlers.textupdate=r=>{let i=e.state.selection.main,{anchor:a,head:o}=i,c=this.toEditorPos(r.updateRangeStart),u=this.toEditorPos(r.updateRangeEnd);e.inputState.composing>=0&&!this.composing&&(this.composing={contextBase:r.updateRangeStart,editorBase:c,drifted:!1});let f=u-c>r.text.length;c==this.from&&a<this.from?c=a:u==this.to&&a>this.to&&(u=a);let h=UP(e.state.sliceDoc(c,u),r.text,(f?i.from:i.to)-c,f?"end":null);if(!h){let g=Se.single(this.toEditorPos(r.selectionStart),this.toEditorPos(r.selectionEnd));g.main.eq(i)||e.dispatch({selection:g,userEvent:"select"});return}let m={from:h.from+c,to:h.toA+c,insert:St.of(r.text.slice(h.from,h.toB).split(`
|
|
87
|
-
`))};if(($e.mac||$e.android)&&m.from==o-1&&/^\. ?$/.test(r.text)&&e.contentDOM.getAttribute("autocorrect")=="off"&&(m={from:c,to:u,insert:St.of([r.text.replace("."," ")])}),this.pendingContextChange=m,!e.state.readOnly){let g=this.to-this.from+(m.to-m.from+m.insert.length);Jx(e,m,Se.single(this.toEditorPos(r.selectionStart,g),this.toEditorPos(r.selectionEnd,g)))}this.pendingContextChange&&(this.revertPending(e.state),this.setSelection(e.state)),m.from<m.to&&!m.insert.length&&e.inputState.composing>=0&&!/[\\p{Alphabetic}\\p{Number}_]/.test(n.text.slice(Math.max(0,r.updateRangeStart-1),Math.min(n.text.length,r.updateRangeStart+1)))&&this.handlers.compositionend(r)},this.handlers.characterboundsupdate=r=>{let i=[],a=null;for(let o=this.toEditorPos(r.rangeStart),c=this.toEditorPos(r.rangeEnd);o<c;o++){let u=e.coordsForChar(o);a=u&&new DOMRect(u.left,u.top,u.right-u.left,u.bottom-u.top)||a||new DOMRect,i.push(a)}n.updateCharacterBounds(r.rangeStart,i)},this.handlers.textformatupdate=r=>{let i=[];for(let a of r.getTextFormats()){let o=a.underlineStyle,c=a.underlineThickness;if(!/none/i.test(o)&&!/none/i.test(c)){let u=this.toEditorPos(a.rangeStart),f=this.toEditorPos(a.rangeEnd);if(u<f){let h=`text-decoration: underline ${/^[a-z]/.test(o)?o+" ":o=="Dashed"?"dashed ":o=="Squiggle"?"wavy ":""}${/thin/i.test(c)?1:2}px`;i.push(dt.mark({attributes:{style:h}}).range(u,f))}}}e.dispatch({effects:PP.of(dt.set(i))})},this.handlers.compositionstart=()=>{e.inputState.composing<0&&(e.inputState.composing=0,e.inputState.compositionFirstChange=!0)},this.handlers.compositionend=()=>{if(e.inputState.composing=-1,e.inputState.compositionFirstChange=null,this.composing){let{drifted:r}=this.composing;this.composing=null,r&&this.reset(e.state)}};for(let r in this.handlers)n.addEventListener(r,this.handlers[r]);this.measureReq={read:r=>{this.editContext.updateControlBounds(r.contentDOM.getBoundingClientRect());let i=Td(r.root);i&&i.rangeCount&&this.editContext.updateSelectionBounds(i.getRangeAt(0).getBoundingClientRect())}}}applyEdits(e){let n=0,r=!1,i=this.pendingContextChange;return e.changes.iterChanges((a,o,c,u,f)=>{if(r)return;let h=f.length-(o-a);if(i&&o>=i.to)if(i.from==a&&i.to==o&&i.insert.eq(f)){i=this.pendingContextChange=null,n+=h,this.to+=h;return}else i=null,this.revertPending(e.state);if(a+=n,o+=n,o<=this.from)this.from+=h,this.to+=h;else if(a<this.to){if(a<this.from||o>this.to||this.to-this.from+f.length>3e4){r=!0;return}this.editContext.updateText(this.toContextPos(a),this.toContextPos(o),f.toString()),this.to+=h}n+=h}),i&&!r&&this.revertPending(e.state),!r}update(e){let n=this.pendingContextChange,r=e.startState.selection.main;this.composing&&(this.composing.drifted||!e.changes.touchesRange(r.from,r.to)&&e.transactions.some(i=>!i.isUserEvent("input.type")&&i.changes.touchesRange(this.from,this.to)))?(this.composing.drifted=!0,this.composing.editorBase=e.changes.mapPos(this.composing.editorBase)):!this.applyEdits(e)||!this.rangeIsValid(e.state)?(this.pendingContextChange=null,this.reset(e.state)):(e.docChanged||e.selectionSet||n)&&this.setSelection(e.state),(e.geometryChanged||e.docChanged||e.selectionSet)&&e.view.requestMeasure(this.measureReq)}resetRange(e){let{head:n}=e.selection.main;this.from=Math.max(0,n-1e4),this.to=Math.min(e.doc.length,n+1e4)}reset(e){this.resetRange(e),this.editContext.updateText(0,this.editContext.text.length,e.doc.sliceString(this.from,this.to)),this.setSelection(e)}revertPending(e){let n=this.pendingContextChange;this.pendingContextChange=null,this.editContext.updateText(this.toContextPos(n.from),this.toContextPos(n.from+n.insert.length),e.doc.sliceString(n.from,n.to))}setSelection(e){let{main:n}=e.selection,r=this.toContextPos(Math.max(this.from,Math.min(this.to,n.anchor))),i=this.toContextPos(n.head);(this.editContext.selectionStart!=r||this.editContext.selectionEnd!=i)&&this.editContext.updateSelection(r,i)}rangeIsValid(e){let{head:n}=e.selection.main;return!(this.from>0&&n-this.from<500||this.to<e.doc.length&&this.to-n<500||this.to-this.from>1e4*3)}toEditorPos(e,n=this.to-this.from){e=Math.min(e,n);let r=this.composing;return r&&r.drifted?r.editorBase+(e-r.contextBase):e+this.from}toContextPos(e){let n=this.composing;return n&&n.drifted?n.contextBase+(e-n.editorBase):e-this.from}destroy(){for(let e in this.handlers)this.editContext.removeEventListener(e,this.handlers[e])}}class qe{get state(){return this.viewState.state}get viewport(){return this.viewState.viewport}get visibleRanges(){return this.viewState.visibleRanges}get inView(){return this.viewState.inView}get composing(){return!!this.inputState&&this.inputState.composing>0}get compositionStarted(){return!!this.inputState&&this.inputState.composing>=0}get root(){return this._root}get win(){return this.dom.ownerDocument.defaultView||window}constructor(e={}){var n;this.plugins=[],this.pluginMap=new Map,this.editorAttrs={},this.contentAttrs={},this.bidiCache=[],this.destroyed=!1,this.updateState=2,this.measureScheduled=-1,this.measureRequests=[],this.contentDOM=document.createElement("div"),this.scrollDOM=document.createElement("div"),this.scrollDOM.tabIndex=-1,this.scrollDOM.className="cm-scroller",this.scrollDOM.appendChild(this.contentDOM),this.announceDOM=document.createElement("div"),this.announceDOM.className="cm-announced",this.announceDOM.setAttribute("aria-live","polite"),this.dom=document.createElement("div"),this.dom.appendChild(this.announceDOM),this.dom.appendChild(this.scrollDOM),e.parent&&e.parent.appendChild(this.dom);let{dispatch:r}=e;this.dispatchTransactions=e.dispatchTransactions||r&&(i=>i.forEach(a=>r(a,this)))||(i=>this.update(i)),this.dispatch=this.dispatch.bind(this),this._root=e.root||Sq(e.parent)||document,this.viewState=new eE(e.state||At.create(e)),e.scrollTo&&e.scrollTo.is(Vh)&&(this.viewState.scrollTarget=e.scrollTo.value.clip(this.viewState.state)),this.plugins=this.state.facet(Jl).map(i=>new my(i));for(let i of this.plugins)i.update(this);this.observer=new UU(this),this.inputState=new mU(this),this.inputState.ensureHandlers(this.plugins),this.docView=new Z2(this),this.mountStyles(),this.updateAttrs(),this.updateState=0,this.requestMeasure(),!((n=document.fonts)===null||n===void 0)&&n.ready&&document.fonts.ready.then(()=>this.requestMeasure())}dispatch(...e){let n=e.length==1&&e[0]instanceof xn?e:e.length==1&&Array.isArray(e[0])?e[0]:[this.state.update(...e)];this.dispatchTransactions(n,this)}update(e){if(this.updateState!=0)throw new Error("Calls to EditorView.update are not allowed while an update is in progress");let n=!1,r=!1,i,a=this.state;for(let g of e){if(g.startState!=a)throw new RangeError("Trying to update state with a transaction that doesn't start from the previous state.");a=g.state}if(this.destroyed){this.viewState.state=a;return}let o=this.hasFocus,c=0,u=null;e.some(g=>g.annotation(KP))?(this.inputState.notifiedFocused=o,c=1):o!=this.inputState.notifiedFocused&&(this.inputState.notifiedFocused=o,u=JP(a,o),u||(c=1));let f=this.observer.delayedAndroidKey,h=null;if(f?(this.observer.clearDelayedAndroidKey(),h=this.observer.readChange(),(h&&!this.state.doc.eq(a.doc)||!this.state.selection.eq(a.selection))&&(h=null)):this.observer.clear(),a.facet(At.phrases)!=this.state.facet(At.phrases))return this.setState(a);i=Fp.create(this,a,e),i.flags|=c;let m=this.viewState.scrollTarget;try{this.updateState=2;for(let g of e){if(m&&(m=m.map(g.changes)),g.scrollIntoView){let{main:y}=g.state.selection;m=new cc(y.empty?y:Se.cursor(y.head,y.head>y.anchor?-1:1))}for(let y of g.effects)y.is(Vh)&&(m=y.value.clip(this.state))}this.viewState.update(i,m),this.bidiCache=Kp.update(this.bidiCache,i.changes),i.empty||(this.updatePlugins(i),this.inputState.update(i)),n=this.docView.update(i),this.state.facet(nd)!=this.styleModules&&this.mountStyles(),r=this.updateAttrs(),this.showAnnouncements(e),this.docView.updateSelection(n,e.some(g=>g.isUserEvent("select.pointer")))}finally{this.updateState=0}if(i.startState.facet(Yh)!=i.state.facet(Yh)&&(this.viewState.mustMeasureContent=!0),(n||r||m||this.viewState.mustEnforceCursorAssoc||this.viewState.mustMeasureContent)&&this.requestMeasure(),n&&this.docViewUpdate(),!i.empty)for(let g of this.state.facet(rb))try{g(i)}catch(y){aa(this.state,y,"update listener")}(u||h)&&Promise.resolve().then(()=>{u&&this.state==u.startState&&this.dispatch(u),h&&!qP(this,h)&&f.force&&lc(this.contentDOM,f.key,f.keyCode)})}setState(e){if(this.updateState!=0)throw new Error("Calls to EditorView.setState are not allowed while an update is in progress");if(this.destroyed){this.viewState.state=e;return}this.updateState=2;let n=this.hasFocus;try{for(let r of this.plugins)r.destroy(this);this.viewState=new eE(e),this.plugins=e.facet(Jl).map(r=>new my(r)),this.pluginMap.clear();for(let r of this.plugins)r.update(this);this.docView.destroy(),this.docView=new Z2(this),this.inputState.ensureHandlers(this.plugins),this.mountStyles(),this.updateAttrs(),this.bidiCache=[]}finally{this.updateState=0}n&&this.focus(),this.requestMeasure()}updatePlugins(e){let n=e.startState.facet(Jl),r=e.state.facet(Jl);if(n!=r){let i=[];for(let a of r){let o=n.indexOf(a);if(o<0)i.push(new my(a));else{let c=this.plugins[o];c.mustUpdate=e,i.push(c)}}for(let a of this.plugins)a.mustUpdate!=e&&a.destroy(this);this.plugins=i,this.pluginMap.clear()}else for(let i of this.plugins)i.mustUpdate=e;for(let i=0;i<this.plugins.length;i++)this.plugins[i].update(this);n!=r&&this.inputState.ensureHandlers(this.plugins)}docViewUpdate(){for(let e of this.plugins){let n=e.value;if(n&&n.docViewUpdate)try{n.docViewUpdate(this)}catch(r){aa(this.state,r,"doc view update listener")}}}measure(e=!0){if(this.destroyed)return;if(this.measureScheduled>-1&&this.win.cancelAnimationFrame(this.measureScheduled),this.observer.delayedAndroidKey){this.measureScheduled=-1,this.requestMeasure();return}this.measureScheduled=0,e&&this.observer.forceFlush();let n=null,r=this.scrollDOM,i=r.scrollTop*this.scaleY,{scrollAnchorPos:a,scrollAnchorHeight:o}=this.viewState;Math.abs(i-this.viewState.scrollTop)>1&&(o=-1),this.viewState.scrollAnchorHeight=-1;try{for(let c=0;;c++){if(o<0)if(OP(r))a=-1,o=this.viewState.heightMap.height;else{let y=this.viewState.scrollAnchorAt(i);a=y.from,o=y.top}this.updateState=1;let u=this.viewState.measure(this);if(!u&&!this.measureRequests.length&&this.viewState.scrollTarget==null)break;if(c>5){console.warn(this.measureRequests.length?"Measure loop restarted more than 5 times":"Viewport failed to stabilize");break}let f=[];u&4||([this.measureRequests,f]=[f,this.measureRequests]);let h=f.map(y=>{try{return y.read(this)}catch(x){return aa(this.state,x),iE}}),m=Fp.create(this,this.state,[]),g=!1;m.flags|=u,n?n.flags|=u:n=m,this.updateState=2,m.empty||(this.updatePlugins(m),this.inputState.update(m),this.updateAttrs(),g=this.docView.update(m),g&&this.docViewUpdate());for(let y=0;y<f.length;y++)if(h[y]!=iE)try{let x=f[y];x.write&&x.write(h[y],this)}catch(x){aa(this.state,x)}if(g&&this.docView.updateSelection(!0),!m.viewportChanged&&this.measureRequests.length==0){if(this.viewState.editorHeight)if(this.viewState.scrollTarget){this.docView.scrollIntoView(this.viewState.scrollTarget),this.viewState.scrollTarget=null,o=-1;continue}else{let x=(a<0?this.viewState.heightMap.height:this.viewState.lineBlockAt(a).top)-o;if(x>1||x<-1){i=i+x,r.scrollTop=i/this.scaleY,o=-1;continue}}break}}}finally{this.updateState=0,this.measureScheduled=-1}if(n&&!n.empty)for(let c of this.state.facet(rb))c(n)}get themeClasses(){return lb+" "+(this.state.facet(ob)?rj:nj)+" "+this.state.facet(Yh)}updateAttrs(){let e=aE(this,jP,{class:"cm-editor"+(this.hasFocus?" cm-focused ":" ")+this.themeClasses}),n={spellcheck:"false",autocorrect:"off",autocapitalize:"off",writingsuggestions:"false",translate:"no",contenteditable:this.state.facet(Za)?"true":"false",class:"cm-content",style:`${$e.tabSize}: ${this.state.tabSize}`,role:"textbox","aria-multiline":"true"};this.state.readOnly&&(n["aria-readonly"]="true"),aE(this,Kx,n);let r=this.observer.ignore(()=>{let i=j2(this.contentDOM,this.contentAttrs,n),a=j2(this.dom,this.editorAttrs,e);return i||a});return this.editorAttrs=e,this.contentAttrs=n,r}showAnnouncements(e){let n=!0;for(let r of e)for(let i of r.effects)if(i.is(qe.announce)){n&&(this.announceDOM.textContent=""),n=!1;let a=this.announceDOM.appendChild(document.createElement("div"));a.textContent=i.value}}mountStyles(){this.styleModules=this.state.facet(nd);let e=this.state.facet(qe.cspNonce);Is.mount(this.root,this.styleModules.concat(IU).reverse(),e?{nonce:e}:void 0)}readMeasured(){if(this.updateState==2)throw new Error("Reading the editor layout isn't allowed during an update");this.updateState==0&&this.measureScheduled>-1&&this.measure(!1)}requestMeasure(e){if(this.measureScheduled<0&&(this.measureScheduled=this.win.requestAnimationFrame(()=>this.measure())),e){if(this.measureRequests.indexOf(e)>-1)return;if(e.key!=null){for(let n=0;n<this.measureRequests.length;n++)if(this.measureRequests[n].key===e.key){this.measureRequests[n]=e;return}}this.measureRequests.push(e)}}plugin(e){let n=this.pluginMap.get(e);return(n===void 0||n&&n.plugin!=e)&&this.pluginMap.set(e,n=this.plugins.find(r=>r.plugin==e)||null),n&&n.update(this).value}get documentTop(){return this.contentDOM.getBoundingClientRect().top+this.viewState.paddingTop}get documentPadding(){return{top:this.viewState.paddingTop,bottom:this.viewState.paddingBottom}}get scaleX(){return this.viewState.scaleX}get scaleY(){return this.viewState.scaleY}elementAtHeight(e){return this.readMeasured(),this.viewState.elementAtHeight(e)}lineBlockAtHeight(e){return this.readMeasured(),this.viewState.lineBlockAtHeight(e)}get viewportLineBlocks(){return this.viewState.viewportLines}lineBlockAt(e){return this.viewState.lineBlockAt(e)}get contentHeight(){return this.viewState.contentHeight}moveByChar(e,n,r){return yy(this,e,V2(this,e,n,r))}moveByGroup(e,n){return yy(this,e,V2(this,e,n,r=>sU(this,e.head,r)))}visualLineSide(e,n){let r=this.bidiSpans(e),i=this.textDirectionAt(e.from),a=r[n?r.length-1:0];return Se.cursor(a.side(n,i)+e.from,a.forward(!n,i)?1:-1)}moveToLineBoundary(e,n,r=!0){return aU(this,e,n,r)}moveVertically(e,n,r){return yy(this,e,oU(this,e,n,r))}domAtPos(e,n=1){return this.docView.domAtPos(e,n)}posAtDOM(e,n=0){return this.docView.posFromDOM(e,n)}posAtCoords(e,n=!0){this.readMeasured();let r=ab(this,e,n);return r&&r.pos}posAndSideAtCoords(e,n=!0){return this.readMeasured(),ab(this,e,n)}coordsAtPos(e,n=1){this.readMeasured();let r=this.docView.coordsAt(e,n);if(!r||r.left==r.right)return r;let i=this.state.doc.lineAt(e),a=this.bidiSpans(i),o=a[Va.find(a,e-i.from,-1,n)];return Yp(r,o.dir==dn.LTR==n>0)}coordsForChar(e){return this.readMeasured(),this.docView.coordsForChar(e)}get defaultCharacterWidth(){return this.viewState.heightOracle.charWidth}get defaultLineHeight(){return this.viewState.heightOracle.lineHeight}get textDirection(){return this.viewState.defaultTextDirection}textDirectionAt(e){return!this.state.facet(_P)||e<this.viewport.from||e>this.viewport.to?this.textDirection:(this.readMeasured(),this.docView.textDirectionAt(e))}get lineWrapping(){return this.viewState.heightOracle.lineWrapping}bidiSpans(e){if(e.length>WU)return wP(e.length);let n=this.textDirectionAt(e.from),r;for(let a of this.bidiCache)if(a.from==e.from&&a.dir==n&&(a.fresh||SP(a.isolates,r=D2(this,e))))return a.order;r||(r=D2(this,e));let i=Rq(e.text,n,r);return this.bidiCache.push(new Kp(e.from,e.to,n,r,!0,i)),i}get hasFocus(){var e;return(this.dom.ownerDocument.hasFocus()||$e.safari&&((e=this.inputState)===null||e===void 0?void 0:e.lastContextMenu)>Date.now()-3e4)&&this.root.activeElement==this.contentDOM}focus(){this.observer.ignore(()=>{gP(this.contentDOM),this.docView.updateSelection()})}setRoot(e){this._root!=e&&(this._root=e,this.observer.setWindow((e.nodeType==9?e:e.ownerDocument).defaultView||window),this.mountStyles())}destroy(){this.root.activeElement==this.contentDOM&&this.contentDOM.blur();for(let e of this.plugins)e.destroy(this);this.plugins=[],this.inputState.destroy(),this.docView.destroy(),this.dom.remove(),this.observer.destroy(),this.measureScheduled>-1&&this.win.cancelAnimationFrame(this.measureScheduled),this.destroyed=!0}static scrollIntoView(e,n={}){return Vh.of(new cc(typeof e=="number"?Se.cursor(e):e,n.y,n.x,n.yMargin,n.xMargin))}scrollSnapshot(){let{scrollTop:e,scrollLeft:n}=this.scrollDOM,r=this.viewState.scrollAnchorAt(e);return Vh.of(new cc(Se.cursor(r.from),"start","start",r.top-e,n,!0))}setTabFocusMode(e){e==null?this.inputState.tabFocusMode=this.inputState.tabFocusMode<0?0:-1:typeof e=="boolean"?this.inputState.tabFocusMode=e?0:-1:this.inputState.tabFocusMode!=0&&(this.inputState.tabFocusMode=Date.now()+e)}static domEventHandlers(e){return ci.define(()=>({}),{eventHandlers:e})}static domEventObservers(e){return ci.define(()=>({}),{eventObservers:e})}static theme(e,n){let r=Is.newName(),i=[Yh.of(r),nd.of(cb(`.${r}`,e))];return n&&n.dark&&i.push(ob.of(!0)),i}static baseTheme(e){return Km.lowest(nd.of(cb("."+lb,e,ij)))}static findFromDOM(e){var n;let r=e.querySelector(".cm-content"),i=r&&Rn.get(r)||Rn.get(e);return((n=i?.root)===null||n===void 0?void 0:n.view)||null}}qe.styleModule=nd;qe.inputHandler=AP;qe.clipboardInputFilter=Gx;qe.clipboardOutputFilter=Hx;qe.scrollHandler=$P;qe.focusChangeEffect=RP;qe.perLineTextDirection=_P;qe.exceptionSink=QP;qe.updateListener=rb;qe.editable=Za;qe.mouseSelectionStyle=EP;qe.dragMovesSelection=TP;qe.clickAddsSelectionRange=CP;qe.decorations=Qd;qe.blockWrappers=MP;qe.outerDecorations=NP;qe.atomicRanges=lf;qe.bidiIsolatedRanges=DP;qe.scrollMargins=zP;qe.darkTheme=ob;qe.cspNonce=Xe.define({combine:t=>t.length?t[0]:""});qe.contentAttributes=Kx;qe.editorAttributes=jP;qe.lineWrapping=qe.contentAttributes.of({class:"cm-lineWrapping"});qe.announce=Vt.define();const WU=4096,iE={};class Kp{constructor(e,n,r,i,a,o){this.from=e,this.to=n,this.dir=r,this.isolates=i,this.fresh=a,this.order=o}static update(e,n){if(n.empty&&!e.some(a=>a.fresh))return e;let r=[],i=e.length?e[e.length-1].dir:dn.LTR;for(let a=Math.max(0,e.length-10);a<e.length;a++){let o=e[a];o.dir==i&&!n.touchesRange(o.from,o.to)&&r.push(new Kp(n.mapPos(o.from,1),n.mapPos(o.to,-1),o.dir,o.isolates,!1,o.order))}return r}}function aE(t,e,n){for(let r=t.state.facet(e),i=r.length-1;i>=0;i--){let a=r[i],o=typeof a=="function"?a(t):a;o&&Yx(o,n)}return n}const GU=$e.mac?"mac":$e.windows?"win":$e.linux?"linux":"key";function HU(t,e){const n=t.split(/-(?!$)/);let r=n[n.length-1];r=="Space"&&(r=" ");let i,a,o,c;for(let u=0;u<n.length-1;++u){const f=n[u];if(/^(cmd|meta|m)$/i.test(f))c=!0;else if(/^a(lt)?$/i.test(f))i=!0;else if(/^(c|ctrl|control)$/i.test(f))a=!0;else if(/^s(hift)?$/i.test(f))o=!0;else if(/^mod$/i.test(f))e=="mac"?c=!0:a=!0;else throw new Error("Unrecognized modifier name: "+f)}return i&&(r="Alt-"+r),a&&(r="Ctrl-"+r),c&&(r="Meta-"+r),o&&(r="Shift-"+r),r}function Fh(t,e,n){return e.altKey&&(t="Alt-"+t),e.ctrlKey&&(t="Ctrl-"+t),e.metaKey&&(t="Meta-"+t),n!==!1&&e.shiftKey&&(t="Shift-"+t),t}const KU=Km.default(qe.domEventHandlers({keydown(t,e){return nY(JU(e.state),t,e,"editor")}})),Ad=Xe.define({enables:KU}),sE=new WeakMap;function JU(t){let e=t.facet(Ad),n=sE.get(e);return n||sE.set(e,n=tY(e.reduce((r,i)=>r.concat(i),[]))),n}let Rs=null;const eY=4e3;function tY(t,e=GU){let n=Object.create(null),r=Object.create(null),i=(o,c)=>{let u=r[o];if(u==null)r[o]=c;else if(u!=c)throw new Error("Key binding "+o+" is used both as a regular binding and as a multi-stroke prefix")},a=(o,c,u,f,h)=>{var m,g;let y=n[o]||(n[o]=Object.create(null)),x=c.split(/ (?!$)/).map(T=>HU(T,e));for(let T=1;T<x.length;T++){let C=x.slice(0,T).join(" ");i(C,!0),y[C]||(y[C]={preventDefault:!0,stopPropagation:!1,run:[E=>{let R=Rs={view:E,prefix:C,scope:o};return setTimeout(()=>{Rs==R&&(Rs=null)},eY),!0}]})}let S=x.join(" ");i(S,!1);let k=y[S]||(y[S]={preventDefault:!1,stopPropagation:!1,run:((g=(m=y._any)===null||m===void 0?void 0:m.run)===null||g===void 0?void 0:g.slice())||[]});u&&k.run.push(u),f&&(k.preventDefault=!0),h&&(k.stopPropagation=!0)};for(let o of t){let c=o.scope?o.scope.split(" "):["editor"];if(o.any)for(let f of c){let h=n[f]||(n[f]=Object.create(null));h._any||(h._any={preventDefault:!1,stopPropagation:!1,run:[]});let{any:m}=o;for(let g in h)h[g].run.push(y=>m(y,ub))}let u=o[e]||o.key;if(u)for(let f of c)a(f,u,o.run,o.preventDefault,o.stopPropagation),o.shift&&a(f,"Shift-"+u,o.shift,o.preventDefault,o.stopPropagation)}return n}let ub=null;function nY(t,e,n,r){ub=e;let i=hq(e),a=Jo(i,0),o=Hm(a)==i.length&&i!=" ",c="",u=!1,f=!1,h=!1;Rs&&Rs.view==n&&Rs.scope==r&&(c=Rs.prefix+" ",FP.indexOf(e.keyCode)<0&&(f=!0,Rs=null));let m=new Set,g=k=>{if(k){for(let T of k.run)if(!m.has(T)&&(m.add(T),T(n)))return k.stopPropagation&&(h=!0),!0;k.preventDefault&&(k.stopPropagation&&(h=!0),f=!0)}return!1},y=t[r],x,S;return y&&(g(y[c+Fh(i,e,!o)])?u=!0:o&&(e.altKey||e.metaKey||e.ctrlKey)&&!($e.windows&&e.ctrlKey&&e.altKey)&&!($e.mac&&e.altKey&&!(e.ctrlKey||e.metaKey))&&(x=qs[e.keyCode])&&x!=i?(g(y[c+Fh(x,e,!0)])||e.shiftKey&&(S=kd[e.keyCode])!=i&&S!=x&&g(y[c+Fh(S,e,!1)]))&&(u=!0):o&&e.shiftKey&&g(y[c+Fh(i,e,!0)])&&(u=!0),!u&&g(y._any)&&(u=!0)),f&&(u=!0),u&&h&&e.stopPropagation(),ub=null,u}function oE(t,e,n,r,i){e.lastIndex=0;for(let a=t.iterRange(n,r),o=n,c;!a.next().done;o+=a.value.length)if(!a.lineBreak)for(;c=e.exec(a.value);)i(o+c.index,c)}function rY(t,e){let n=t.visibleRanges;if(n.length==1&&n[0].from==t.viewport.from&&n[0].to==t.viewport.to)return n;let r=[];for(let{from:i,to:a}of n)i=Math.max(t.state.doc.lineAt(i).from,i-e),a=Math.min(t.state.doc.lineAt(a).to,a+e),r.length&&r[r.length-1].to>=i?r[r.length-1].to=a:r.push({from:i,to:a});return r}class iY{constructor(e){const{regexp:n,decoration:r,decorate:i,boundary:a,maxLength:o=1e3}=e;if(!n.global)throw new RangeError("The regular expression given to MatchDecorator should have its 'g' flag set");if(this.regexp=n,i)this.addMatch=(c,u,f,h)=>i(h,f,f+c[0].length,c,u);else if(typeof r=="function")this.addMatch=(c,u,f,h)=>{let m=r(c,u,f);m&&h(f,f+c[0].length,m)};else if(r)this.addMatch=(c,u,f,h)=>h(f,f+c[0].length,r);else throw new RangeError("Either 'decorate' or 'decoration' should be provided to MatchDecorator");this.boundary=a,this.maxLength=o}createDeco(e){let n=new Oc,r=n.add.bind(n);for(let{from:i,to:a}of rY(e,this.maxLength))oE(e.state.doc,this.regexp,i,a,(o,c)=>this.addMatch(c,e,o,r));return n.finish()}updateDeco(e,n){let r=1e9,i=-1;return e.docChanged&&e.changes.iterChanges((a,o,c,u)=>{u>=e.view.viewport.from&&c<=e.view.viewport.to&&(r=Math.min(c,r),i=Math.max(u,i))}),e.viewportMoved||i-r>1e3?this.createDeco(e.view):i>-1?this.updateRange(e.view,n.map(e.changes),r,i):n}updateRange(e,n,r,i){for(let a of e.visibleRanges){let o=Math.max(a.from,r),c=Math.min(a.to,i);if(c>=o){let u=e.state.doc.lineAt(o),f=u.to<c?e.state.doc.lineAt(c):u,h=Math.max(a.from,u.from),m=Math.min(a.to,f.to);if(this.boundary){for(;o>u.from;o--)if(this.boundary.test(u.text[o-1-u.from])){h=o;break}for(;c<f.to;c++)if(this.boundary.test(f.text[c-f.from])){m=c;break}}let g=[],y,x=(S,k,T)=>g.push(T.range(S,k));if(u==f)for(this.regexp.lastIndex=h-u.from;(y=this.regexp.exec(u.text))&&y.index<m-u.from;)this.addMatch(y,e,y.index+u.from,x);else oE(e.state.doc,this.regexp,h,m,(S,k)=>this.addMatch(k,e,S,x));n=n.update({filterFrom:h,filterTo:m,filter:(S,k)=>S<h||k>m,add:g})}}return n}}const db=/x/.unicode!=null?"gu":"g",aY=new RegExp(`[\0-\b
|
|
88
|
-
--\u2028\u2029\uFEFF-]`,db),sY={0:"null",7:"bell",8:"backspace",10:"newline",11:"vertical tab",13:"carriage return",27:"escape",8203:"zero width space",8204:"zero width non-joiner",8205:"zero width joiner",8206:"left-to-right mark",8207:"right-to-left mark",8232:"line separator",8237:"left-to-right override",8238:"right-to-left override",8294:"left-to-right isolate",8295:"right-to-left isolate",8297:"pop directional isolate",8233:"paragraph separator",65279:"zero width no-break space",65532:"object replacement"};let Sy=null;function oY(){var t;if(Sy==null&&typeof document<"u"&&document.body){let e=document.body.style;Sy=((t=e.tabSize)!==null&&t!==void 0?t:e.MozTabSize)!=null}return Sy||!1}const Sp=Xe.define({combine(t){let e=eg(t,{render:null,specialChars:aY,addSpecialChars:null});return(e.replaceTabs=!oY())&&(e.specialChars=new RegExp(" |"+e.specialChars.source,db)),e.addSpecialChars&&(e.specialChars=new RegExp(e.specialChars.source+"|"+e.addSpecialChars.source,db)),e}});function lY(t={}){return[Sp.of(t),cY()]}let lE=null;function cY(){return lE||(lE=ci.fromClass(class{constructor(t){this.view=t,this.decorations=dt.none,this.decorationCache=Object.create(null),this.decorator=this.makeDecorator(t.state.facet(Sp)),this.decorations=this.decorator.createDeco(t)}makeDecorator(t){return new iY({regexp:t.specialChars,decoration:(e,n,r)=>{let{doc:i}=n.state,a=Jo(e[0],0);if(a==9){let o=i.lineAt(r),c=n.state.tabSize,u=af(o.text,c,r-o.from);return dt.replace({widget:new hY((c-u%c)*this.view.defaultCharacterWidth/this.view.scaleX)})}return this.decorationCache[a]||(this.decorationCache[a]=dt.replace({widget:new fY(t,a)}))},boundary:t.replaceTabs?void 0:/[^]/})}update(t){let e=t.state.facet(Sp);t.startState.facet(Sp)!=e?(this.decorator=this.makeDecorator(e),this.decorations=this.decorator.createDeco(t.view)):this.decorations=this.decorator.updateDeco(t,this.decorations)}},{decorations:t=>t.decorations}))}const uY="•";function dY(t){return t>=32?uY:t==10?"":String.fromCharCode(9216+t)}class fY extends el{constructor(e,n){super(),this.options=e,this.code=n}eq(e){return e.code==this.code}toDOM(e){let n=dY(this.code),r=e.state.phrase("Control character")+" "+(sY[this.code]||"0x"+this.code.toString(16)),i=this.options.render&&this.options.render(this.code,r,n);if(i)return i;let a=document.createElement("span");return a.textContent=n,a.title=r,a.setAttribute("aria-label",r),a.className="cm-specialChar",a}ignoreEvent(){return!1}}class hY extends el{constructor(e){super(),this.width=e}eq(e){return e.width==this.width}toDOM(){let e=document.createElement("span");return e.textContent=" ",e.className="cm-tab",e.style.width=this.width+"px",e}ignoreEvent(){return!1}}function pY(){return gY}const mY=dt.line({class:"cm-activeLine"}),gY=ci.fromClass(class{constructor(t){this.decorations=this.getDeco(t)}update(t){(t.docChanged||t.selectionSet)&&(this.decorations=this.getDeco(t.view))}getDeco(t){let e=-1,n=[];for(let r of t.state.selection.ranges){let i=t.lineBlockAt(r.head);i.from>e&&(n.push(mY.range(i.from)),e=i.from)}return dt.set(n)}},{decorations:t=>t.decorations});class Yo extends Bs{compare(e){return this==e||this.constructor==e.constructor&&this.eq(e)}eq(e){return!1}destroy(e){}}Yo.prototype.elementClass="";Yo.prototype.toDOM=void 0;Yo.prototype.mapMode=Hn.TrackBefore;Yo.prototype.startSide=Yo.prototype.endSide=-1;Yo.prototype.point=!0;const wy=Xe.define(),OY=Xe.define(),wp=Xe.define(),cE=Xe.define({combine:t=>t.some(e=>e)});function vY(t){return[yY]}const yY=ci.fromClass(class{constructor(t){this.view=t,this.domAfter=null,this.prevViewport=t.viewport,this.dom=document.createElement("div"),this.dom.className="cm-gutters cm-gutters-before",this.dom.setAttribute("aria-hidden","true"),this.dom.style.minHeight=this.view.contentHeight/this.view.scaleY+"px",this.gutters=t.state.facet(wp).map(e=>new dE(t,e)),this.fixed=!t.state.facet(cE);for(let e of this.gutters)e.config.side=="after"?this.getDOMAfter().appendChild(e.dom):this.dom.appendChild(e.dom);this.fixed&&(this.dom.style.position="sticky"),this.syncGutters(!1),t.scrollDOM.insertBefore(this.dom,t.contentDOM)}getDOMAfter(){return this.domAfter||(this.domAfter=document.createElement("div"),this.domAfter.className="cm-gutters cm-gutters-after",this.domAfter.setAttribute("aria-hidden","true"),this.domAfter.style.minHeight=this.view.contentHeight/this.view.scaleY+"px",this.domAfter.style.position=this.fixed?"sticky":"",this.view.scrollDOM.appendChild(this.domAfter)),this.domAfter}update(t){if(this.updateGutters(t)){let e=this.prevViewport,n=t.view.viewport,r=Math.min(e.to,n.to)-Math.max(e.from,n.from);this.syncGutters(r<(n.to-n.from)*.8)}if(t.geometryChanged){let e=this.view.contentHeight/this.view.scaleY+"px";this.dom.style.minHeight=e,this.domAfter&&(this.domAfter.style.minHeight=e)}this.view.state.facet(cE)!=!this.fixed&&(this.fixed=!this.fixed,this.dom.style.position=this.fixed?"sticky":"",this.domAfter&&(this.domAfter.style.position=this.fixed?"sticky":"")),this.prevViewport=t.view.viewport}syncGutters(t){let e=this.dom.nextSibling;t&&(this.dom.remove(),this.domAfter&&this.domAfter.remove());let n=xt.iter(this.view.state.facet(wy),this.view.viewport.from),r=[],i=this.gutters.map(a=>new bY(a,this.view.viewport,-this.view.documentPadding.top));for(let a of this.view.viewportLineBlocks)if(r.length&&(r=[]),Array.isArray(a.type)){let o=!0;for(let c of a.type)if(c.type==Ar.Text&&o){fb(n,r,c.from);for(let u of i)u.line(this.view,c,r);o=!1}else if(c.widget)for(let u of i)u.widget(this.view,c)}else if(a.type==Ar.Text){fb(n,r,a.from);for(let o of i)o.line(this.view,a,r)}else if(a.widget)for(let o of i)o.widget(this.view,a);for(let a of i)a.finish();t&&(this.view.scrollDOM.insertBefore(this.dom,e),this.domAfter&&this.view.scrollDOM.appendChild(this.domAfter))}updateGutters(t){let e=t.startState.facet(wp),n=t.state.facet(wp),r=t.docChanged||t.heightChanged||t.viewportChanged||!xt.eq(t.startState.facet(wy),t.state.facet(wy),t.view.viewport.from,t.view.viewport.to);if(e==n)for(let i of this.gutters)i.update(t)&&(r=!0);else{r=!0;let i=[];for(let a of n){let o=e.indexOf(a);o<0?i.push(new dE(this.view,a)):(this.gutters[o].update(t),i.push(this.gutters[o]))}for(let a of this.gutters)a.dom.remove(),i.indexOf(a)<0&&a.destroy();for(let a of i)a.config.side=="after"?this.getDOMAfter().appendChild(a.dom):this.dom.appendChild(a.dom);this.gutters=i}return r}destroy(){for(let t of this.gutters)t.destroy();this.dom.remove(),this.domAfter&&this.domAfter.remove()}},{provide:t=>qe.scrollMargins.of(e=>{let n=e.plugin(t);if(!n||n.gutters.length==0||!n.fixed)return null;let r=n.dom.offsetWidth*e.scaleX,i=n.domAfter?n.domAfter.offsetWidth*e.scaleX:0;return e.textDirection==dn.LTR?{left:r,right:i}:{right:r,left:i}})});function uE(t){return Array.isArray(t)?t:[t]}function fb(t,e,n){for(;t.value&&t.from<=n;)t.from==n&&e.push(t.value),t.next()}class bY{constructor(e,n,r){this.gutter=e,this.height=r,this.i=0,this.cursor=xt.iter(e.markers,n.from)}addElement(e,n,r){let{gutter:i}=this,a=(n.top-this.height)/e.scaleY,o=n.height/e.scaleY;if(this.i==i.elements.length){let c=new aj(e,o,a,r);i.elements.push(c),i.dom.appendChild(c.dom)}else i.elements[this.i].update(e,o,a,r);this.height=n.bottom,this.i++}line(e,n,r){let i=[];fb(this.cursor,i,n.from),r.length&&(i=i.concat(r));let a=this.gutter.config.lineMarker(e,n,i);a&&i.unshift(a);let o=this.gutter;i.length==0&&!o.config.renderEmptyElements||this.addElement(e,n,i)}widget(e,n){let r=this.gutter.config.widgetMarker(e,n.widget,n),i=r?[r]:null;for(let a of e.state.facet(OY)){let o=a(e,n.widget,n);o&&(i||(i=[])).push(o)}i&&this.addElement(e,n,i)}finish(){let e=this.gutter;for(;e.elements.length>this.i;){let n=e.elements.pop();e.dom.removeChild(n.dom),n.destroy()}}}class dE{constructor(e,n){this.view=e,this.config=n,this.elements=[],this.spacer=null,this.dom=document.createElement("div"),this.dom.className="cm-gutter"+(this.config.class?" "+this.config.class:"");for(let r in n.domEventHandlers)this.dom.addEventListener(r,i=>{let a=i.target,o;if(a!=this.dom&&this.dom.contains(a)){for(;a.parentNode!=this.dom;)a=a.parentNode;let u=a.getBoundingClientRect();o=(u.top+u.bottom)/2}else o=i.clientY;let c=e.lineBlockAtHeight(o-e.documentTop);n.domEventHandlers[r](e,c,i)&&i.preventDefault()});this.markers=uE(n.markers(e)),n.initialSpacer&&(this.spacer=new aj(e,0,0,[n.initialSpacer(e)]),this.dom.appendChild(this.spacer.dom),this.spacer.dom.style.cssText+="visibility: hidden; pointer-events: none")}update(e){let n=this.markers;if(this.markers=uE(this.config.markers(e.view)),this.spacer&&this.config.updateSpacer){let i=this.config.updateSpacer(this.spacer.markers[0],e);i!=this.spacer.markers[0]&&this.spacer.update(e.view,0,0,[i])}let r=e.view.viewport;return!xt.eq(this.markers,n,r.from,r.to)||(this.config.lineMarkerChange?this.config.lineMarkerChange(e):!1)}destroy(){for(let e of this.elements)e.destroy()}}class aj{constructor(e,n,r,i){this.height=-1,this.above=0,this.markers=[],this.dom=document.createElement("div"),this.dom.className="cm-gutterElement",this.update(e,n,r,i)}update(e,n,r,i){this.height!=n&&(this.height=n,this.dom.style.height=n+"px"),this.above!=r&&(this.dom.style.marginTop=(this.above=r)?r+"px":""),xY(this.markers,i)||this.setMarkers(e,i)}setMarkers(e,n){let r="cm-gutterElement",i=this.dom.firstChild;for(let a=0,o=0;;){let c=o,u=a<n.length?n[a++]:null,f=!1;if(u){let h=u.elementClass;h&&(r+=" "+h);for(let m=o;m<this.markers.length;m++)if(this.markers[m].compare(u)){c=m,f=!0;break}}else c=this.markers.length;for(;o<c;){let h=this.markers[o++];if(h.toDOM){h.destroy(i);let m=i.nextSibling;i.remove(),i=m}}if(!u)break;u.toDOM&&(f?i=i.nextSibling:this.dom.insertBefore(u.toDOM(e),i)),f&&o++}this.dom.className=r,this.markers=n}destroy(){this.setMarkers(null,[])}}function xY(t,e){if(t.length!=e.length)return!1;for(let n=0;n<t.length;n++)if(!t[n].compare(e[n]))return!1;return!0}const SY=Xe.define(),wY=Xe.define(),ec=Xe.define({combine(t){return eg(t,{formatNumber:String,domEventHandlers:{}},{domEventHandlers(e,n){let r=Object.assign({},e);for(let i in n){let a=r[i],o=n[i];r[i]=a?(c,u,f)=>a(c,u,f)||o(c,u,f):o}return r}})}});class ky extends Yo{constructor(e){super(),this.number=e}eq(e){return this.number==e.number}toDOM(){return document.createTextNode(this.number)}}function Cy(t,e){return t.state.facet(ec).formatNumber(e,t.state)}const kY=wp.compute([ec],t=>({class:"cm-lineNumbers",renderEmptyElements:!1,markers(e){return e.state.facet(SY)},lineMarker(e,n,r){return r.some(i=>i.toDOM)?null:new ky(Cy(e,e.state.doc.lineAt(n.from).number))},widgetMarker:(e,n,r)=>{for(let i of e.state.facet(wY)){let a=i(e,n,r);if(a)return a}return null},lineMarkerChange:e=>e.startState.facet(ec)!=e.state.facet(ec),initialSpacer(e){return new ky(Cy(e,fE(e.state.doc.lines)))},updateSpacer(e,n){let r=Cy(n.view,fE(n.view.state.doc.lines));return r==e.number?e:new ky(r)},domEventHandlers:t.facet(ec).domEventHandlers,side:"before"}));function CY(t={}){return[ec.of(t),vY(),kY]}function fE(t){let e=9;for(;e<t;)e=e*10+9;return e}const sj=1024;let TY=0,si=class{constructor(e,n){this.from=e,this.to=n}};class ct{constructor(e={}){this.id=TY++,this.perNode=!!e.perNode,this.deserialize=e.deserialize||(()=>{throw new Error("This node type doesn't define a deserialize function")}),this.combine=e.combine||null}add(e){if(this.perNode)throw new RangeError("Can't add per-node props to node types");return typeof e!="function"&&(e=ur.match(e)),n=>{let r=e(n);return r===void 0?null:[this,r]}}}ct.closedBy=new ct({deserialize:t=>t.split(" ")});ct.openedBy=new ct({deserialize:t=>t.split(" ")});ct.group=new ct({deserialize:t=>t.split(" ")});ct.isolate=new ct({deserialize:t=>{if(t&&t!="rtl"&&t!="ltr"&&t!="auto")throw new RangeError("Invalid value for isolate: "+t);return t||"auto"}});ct.contextHash=new ct({perNode:!0});ct.lookAhead=new ct({perNode:!0});ct.mounted=new ct({perNode:!0});class Rd{constructor(e,n,r){this.tree=e,this.overlay=n,this.parser=r}static get(e){return e&&e.props&&e.props[ct.mounted.id]}}const EY=Object.create(null);class ur{constructor(e,n,r,i=0){this.name=e,this.props=n,this.id=r,this.flags=i}static define(e){let n=e.props&&e.props.length?Object.create(null):EY,r=(e.top?1:0)|(e.skipped?2:0)|(e.error?4:0)|(e.name==null?8:0),i=new ur(e.name||"",n,e.id,r);if(e.props){for(let a of e.props)if(Array.isArray(a)||(a=a(i)),a){if(a[0].perNode)throw new RangeError("Can't store a per-node prop on a node type");n[a[0].id]=a[1]}}return i}prop(e){return this.props[e.id]}get isTop(){return(this.flags&1)>0}get isSkipped(){return(this.flags&2)>0}get isError(){return(this.flags&4)>0}get isAnonymous(){return(this.flags&8)>0}is(e){if(typeof e=="string"){if(this.name==e)return!0;let n=this.prop(ct.group);return n?n.indexOf(e)>-1:!1}return this.id==e}static match(e){let n=Object.create(null);for(let r in e)for(let i of r.split(" "))n[i]=e[r];return r=>{for(let i=r.prop(ct.group),a=-1;a<(i?i.length:0);a++){let o=n[a<0?r.name:i[a]];if(o)return o}}}}ur.none=new ur("",Object.create(null),0,8);class n1{constructor(e){this.types=e;for(let n=0;n<e.length;n++)if(e[n].id!=n)throw new RangeError("Node type ids should correspond to array positions when creating a node set")}extend(...e){let n=[];for(let r of this.types){let i=null;for(let a of e){let o=a(r);if(o){i||(i=Object.assign({},r.props));let c=o[1],u=o[0];u.combine&&u.id in i&&(c=u.combine(i[u.id],c)),i[u.id]=c}}n.push(i?new ur(r.name,i,r.id,r.flags):r)}return new n1(n)}}const Wh=new WeakMap,hE=new WeakMap;var Ut;(function(t){t[t.ExcludeBuffers=1]="ExcludeBuffers",t[t.IncludeAnonymous=2]="IncludeAnonymous",t[t.IgnoreMounts=4]="IgnoreMounts",t[t.IgnoreOverlays=8]="IgnoreOverlays"})(Ut||(Ut={}));class tn{constructor(e,n,r,i,a){if(this.type=e,this.children=n,this.positions=r,this.length=i,this.props=null,a&&a.length){this.props=Object.create(null);for(let[o,c]of a)this.props[typeof o=="number"?o:o.id]=c}}toString(){let e=Rd.get(this);if(e&&!e.overlay)return e.tree.toString();let n="";for(let r of this.children){let i=r.toString();i&&(n&&(n+=","),n+=i)}return this.type.name?(/\W/.test(this.type.name)&&!this.type.isError?JSON.stringify(this.type.name):this.type.name)+(n.length?"("+n+")":""):n}cursor(e=0){return new Jp(this.topNode,e)}cursorAt(e,n=0,r=0){let i=Wh.get(this)||this.topNode,a=new Jp(i);return a.moveTo(e,n),Wh.set(this,a._tree),a}get topNode(){return new Kn(this,0,0,null)}resolve(e,n=0){let r=_d(Wh.get(this)||this.topNode,e,n,!1);return Wh.set(this,r),r}resolveInner(e,n=0){let r=_d(hE.get(this)||this.topNode,e,n,!0);return hE.set(this,r),r}resolveStack(e,n=0){return RY(this,e,n)}iterate(e){let{enter:n,leave:r,from:i=0,to:a=this.length}=e,o=e.mode||0,c=(o&Ut.IncludeAnonymous)>0;for(let u=this.cursor(o|Ut.IncludeAnonymous);;){let f=!1;if(u.from<=a&&u.to>=i&&(!c&&u.type.isAnonymous||n(u)!==!1)){if(u.firstChild())continue;f=!0}for(;f&&r&&(c||!u.type.isAnonymous)&&r(u),!u.nextSibling();){if(!u.parent())return;f=!0}}}prop(e){return e.perNode?this.props?this.props[e.id]:void 0:this.type.prop(e)}get propValues(){let e=[];if(this.props)for(let n in this.props)e.push([+n,this.props[n]]);return e}balance(e={}){return this.children.length<=8?this:a1(ur.none,this.children,this.positions,0,this.children.length,0,this.length,(n,r,i)=>new tn(this.type,n,r,i,this.propValues),e.makeTree||((n,r,i)=>new tn(ur.none,n,r,i)))}static build(e){return _Y(e)}}tn.empty=new tn(ur.none,[],[],0);class r1{constructor(e,n){this.buffer=e,this.index=n}get id(){return this.buffer[this.index-4]}get start(){return this.buffer[this.index-3]}get end(){return this.buffer[this.index-2]}get size(){return this.buffer[this.index-1]}get pos(){return this.index}next(){this.index-=4}fork(){return new r1(this.buffer,this.index)}}class Ys{constructor(e,n,r){this.buffer=e,this.length=n,this.set=r}get type(){return ur.none}toString(){let e=[];for(let n=0;n<this.buffer.length;)e.push(this.childString(n)),n=this.buffer[n+3];return e.join(",")}childString(e){let n=this.buffer[e],r=this.buffer[e+3],i=this.set.types[n],a=i.name;if(/\W/.test(a)&&!i.isError&&(a=JSON.stringify(a)),e+=4,r==e)return a;let o=[];for(;e<r;)o.push(this.childString(e)),e=this.buffer[e+3];return a+"("+o.join(",")+")"}findChild(e,n,r,i,a){let{buffer:o}=this,c=-1;for(let u=e;u!=n&&!(oj(a,i,o[u+1],o[u+2])&&(c=u,r>0));u=o[u+3]);return c}slice(e,n,r){let i=this.buffer,a=new Uint16Array(n-e),o=0;for(let c=e,u=0;c<n;){a[u++]=i[c++],a[u++]=i[c++]-r;let f=a[u++]=i[c++]-r;a[u++]=i[c++]-e,o=Math.max(o,f)}return new Ys(a,o,this.set)}}function oj(t,e,n,r){switch(t){case-2:return n<e;case-1:return r>=e&&n<e;case 0:return n<e&&r>e;case 1:return n<=e&&r>e;case 2:return r>e;case 4:return!0}}function _d(t,e,n,r){for(var i;t.from==t.to||(n<1?t.from>=e:t.from>e)||(n>-1?t.to<=e:t.to<e);){let o=!r&&t instanceof Kn&&t.index<0?null:t.parent;if(!o)return t;t=o}let a=r?0:Ut.IgnoreOverlays;if(r)for(let o=t,c=o.parent;c;o=c,c=o.parent)o instanceof Kn&&o.index<0&&((i=c.enter(e,n,a))===null||i===void 0?void 0:i.from)!=o.from&&(t=c);for(;;){let o=t.enter(e,n,a);if(!o)return t;t=o}}class lj{cursor(e=0){return new Jp(this,e)}getChild(e,n=null,r=null){let i=pE(this,e,n,r);return i.length?i[0]:null}getChildren(e,n=null,r=null){return pE(this,e,n,r)}resolve(e,n=0){return _d(this,e,n,!1)}resolveInner(e,n=0){return _d(this,e,n,!0)}matchContext(e){return hb(this.parent,e)}enterUnfinishedNodesBefore(e){let n=this.childBefore(e),r=this;for(;n;){let i=n.lastChild;if(!i||i.to!=n.to)break;i.type.isError&&i.from==i.to?(r=n,n=i.prevSibling):n=i}return r}get node(){return this}get next(){return this.parent}}class Kn extends lj{constructor(e,n,r,i){super(),this._tree=e,this.from=n,this.index=r,this._parent=i}get type(){return this._tree.type}get name(){return this._tree.type.name}get to(){return this.from+this._tree.length}nextChild(e,n,r,i,a=0){for(let o=this;;){for(let{children:c,positions:u}=o._tree,f=n>0?c.length:-1;e!=f;e+=n){let h=c[e],m=u[e]+o.from;if(oj(i,r,m,m+h.length)){if(h instanceof Ys){if(a&Ut.ExcludeBuffers)continue;let g=h.findChild(0,h.buffer.length,n,r-m,i);if(g>-1)return new sa(new QY(o,h,e,m),null,g)}else if(a&Ut.IncludeAnonymous||!h.type.isAnonymous||i1(h)){let g;if(!(a&Ut.IgnoreMounts)&&(g=Rd.get(h))&&!g.overlay)return new Kn(g.tree,m,e,o);let y=new Kn(h,m,e,o);return a&Ut.IncludeAnonymous||!y.type.isAnonymous?y:y.nextChild(n<0?h.children.length-1:0,n,r,i)}}}if(a&Ut.IncludeAnonymous||!o.type.isAnonymous||(o.index>=0?e=o.index+n:e=n<0?-1:o._parent._tree.children.length,o=o._parent,!o))return null}}get firstChild(){return this.nextChild(0,1,0,4)}get lastChild(){return this.nextChild(this._tree.children.length-1,-1,0,4)}childAfter(e){return this.nextChild(0,1,e,2)}childBefore(e){return this.nextChild(this._tree.children.length-1,-1,e,-2)}prop(e){return this._tree.prop(e)}enter(e,n,r=0){let i;if(!(r&Ut.IgnoreOverlays)&&(i=Rd.get(this._tree))&&i.overlay){let a=e-this.from;for(let{from:o,to:c}of i.overlay)if((n>0?o<=a:o<a)&&(n<0?c>=a:c>a))return new Kn(i.tree,i.overlay[0].from+this.from,-1,this)}return this.nextChild(0,1,e,n,r)}nextSignificantParent(){let e=this;for(;e.type.isAnonymous&&e._parent;)e=e._parent;return e}get parent(){return this._parent?this._parent.nextSignificantParent():null}get nextSibling(){return this._parent&&this.index>=0?this._parent.nextChild(this.index+1,1,0,4):null}get prevSibling(){return this._parent&&this.index>=0?this._parent.nextChild(this.index-1,-1,0,4):null}get tree(){return this._tree}toTree(){return this._tree}toString(){return this._tree.toString()}}function pE(t,e,n,r){let i=t.cursor(),a=[];if(!i.firstChild())return a;if(n!=null){for(let o=!1;!o;)if(o=i.type.is(n),!i.nextSibling())return a}for(;;){if(r!=null&&i.type.is(r))return a;if(i.type.is(e)&&a.push(i.node),!i.nextSibling())return r==null?a:[]}}function hb(t,e,n=e.length-1){for(let r=t;n>=0;r=r.parent){if(!r)return!1;if(!r.type.isAnonymous){if(e[n]&&e[n]!=r.name)return!1;n--}}return!0}class QY{constructor(e,n,r,i){this.parent=e,this.buffer=n,this.index=r,this.start=i}}class sa extends lj{get name(){return this.type.name}get from(){return this.context.start+this.context.buffer.buffer[this.index+1]}get to(){return this.context.start+this.context.buffer.buffer[this.index+2]}constructor(e,n,r){super(),this.context=e,this._parent=n,this.index=r,this.type=e.buffer.set.types[e.buffer.buffer[r]]}child(e,n,r){let{buffer:i}=this.context,a=i.findChild(this.index+4,i.buffer[this.index+3],e,n-this.context.start,r);return a<0?null:new sa(this.context,this,a)}get firstChild(){return this.child(1,0,4)}get lastChild(){return this.child(-1,0,4)}childAfter(e){return this.child(1,e,2)}childBefore(e){return this.child(-1,e,-2)}prop(e){return this.type.prop(e)}enter(e,n,r=0){if(r&Ut.ExcludeBuffers)return null;let{buffer:i}=this.context,a=i.findChild(this.index+4,i.buffer[this.index+3],n>0?1:-1,e-this.context.start,n);return a<0?null:new sa(this.context,this,a)}get parent(){return this._parent||this.context.parent.nextSignificantParent()}externalSibling(e){return this._parent?null:this.context.parent.nextChild(this.context.index+e,e,0,4)}get nextSibling(){let{buffer:e}=this.context,n=e.buffer[this.index+3];return n<(this._parent?e.buffer[this._parent.index+3]:e.buffer.length)?new sa(this.context,this._parent,n):this.externalSibling(1)}get prevSibling(){let{buffer:e}=this.context,n=this._parent?this._parent.index+4:0;return this.index==n?this.externalSibling(-1):new sa(this.context,this._parent,e.findChild(n,this.index,-1,0,4))}get tree(){return null}toTree(){let e=[],n=[],{buffer:r}=this.context,i=this.index+4,a=r.buffer[this.index+3];if(a>i){let o=r.buffer[this.index+1];e.push(r.slice(i,a,o)),n.push(0)}return new tn(this.type,e,n,this.to-this.from)}toString(){return this.context.buffer.childString(this.index)}}function cj(t){if(!t.length)return null;let e=0,n=t[0];for(let a=1;a<t.length;a++){let o=t[a];(o.from>n.from||o.to<n.to)&&(n=o,e=a)}let r=n instanceof Kn&&n.index<0?null:n.parent,i=t.slice();return r?i[e]=r:i.splice(e,1),new AY(i,n)}class AY{constructor(e,n){this.heads=e,this.node=n}get next(){return cj(this.heads)}}function RY(t,e,n){let r=t.resolveInner(e,n),i=null;for(let a=r instanceof Kn?r:r.context.parent;a;a=a.parent)if(a.index<0){let o=a.parent;(i||(i=[r])).push(o.resolve(e,n)),a=o}else{let o=Rd.get(a.tree);if(o&&o.overlay&&o.overlay[0].from<=e&&o.overlay[o.overlay.length-1].to>=e){let c=new Kn(o.tree,o.overlay[0].from+a.from,-1,a);(i||(i=[r])).push(_d(c,e,n,!1))}}return i?cj(i):r}class Jp{get name(){return this.type.name}constructor(e,n=0){if(this.mode=n,this.buffer=null,this.stack=[],this.index=0,this.bufferNode=null,e instanceof Kn)this.yieldNode(e);else{this._tree=e.context.parent,this.buffer=e.context;for(let r=e._parent;r;r=r._parent)this.stack.unshift(r.index);this.bufferNode=e,this.yieldBuf(e.index)}}yieldNode(e){return e?(this._tree=e,this.type=e.type,this.from=e.from,this.to=e.to,!0):!1}yieldBuf(e,n){this.index=e;let{start:r,buffer:i}=this.buffer;return this.type=n||i.set.types[i.buffer[e]],this.from=r+i.buffer[e+1],this.to=r+i.buffer[e+2],!0}yield(e){return e?e instanceof Kn?(this.buffer=null,this.yieldNode(e)):(this.buffer=e.context,this.yieldBuf(e.index,e.type)):!1}toString(){return this.buffer?this.buffer.buffer.childString(this.index):this._tree.toString()}enterChild(e,n,r){if(!this.buffer)return this.yield(this._tree.nextChild(e<0?this._tree._tree.children.length-1:0,e,n,r,this.mode));let{buffer:i}=this.buffer,a=i.findChild(this.index+4,i.buffer[this.index+3],e,n-this.buffer.start,r);return a<0?!1:(this.stack.push(this.index),this.yieldBuf(a))}firstChild(){return this.enterChild(1,0,4)}lastChild(){return this.enterChild(-1,0,4)}childAfter(e){return this.enterChild(1,e,2)}childBefore(e){return this.enterChild(-1,e,-2)}enter(e,n,r=this.mode){return this.buffer?r&Ut.ExcludeBuffers?!1:this.enterChild(1,e,n):this.yield(this._tree.enter(e,n,r))}parent(){if(!this.buffer)return this.yieldNode(this.mode&Ut.IncludeAnonymous?this._tree._parent:this._tree.parent);if(this.stack.length)return this.yieldBuf(this.stack.pop());let e=this.mode&Ut.IncludeAnonymous?this.buffer.parent:this.buffer.parent.nextSignificantParent();return this.buffer=null,this.yieldNode(e)}sibling(e){if(!this.buffer)return this._tree._parent?this.yield(this._tree.index<0?null:this._tree._parent.nextChild(this._tree.index+e,e,0,4,this.mode)):!1;let{buffer:n}=this.buffer,r=this.stack.length-1;if(e<0){let i=r<0?0:this.stack[r]+4;if(this.index!=i)return this.yieldBuf(n.findChild(i,this.index,-1,0,4))}else{let i=n.buffer[this.index+3];if(i<(r<0?n.buffer.length:n.buffer[this.stack[r]+3]))return this.yieldBuf(i)}return r<0?this.yield(this.buffer.parent.nextChild(this.buffer.index+e,e,0,4,this.mode)):!1}nextSibling(){return this.sibling(1)}prevSibling(){return this.sibling(-1)}atLastNode(e){let n,r,{buffer:i}=this;if(i){if(e>0){if(this.index<i.buffer.buffer.length)return!1}else for(let a=0;a<this.index;a++)if(i.buffer.buffer[a+3]<this.index)return!1;({index:n,parent:r}=i)}else({index:n,_parent:r}=this._tree);for(;r;{index:n,_parent:r}=r)if(n>-1)for(let a=n+e,o=e<0?-1:r._tree.children.length;a!=o;a+=e){let c=r._tree.children[a];if(this.mode&Ut.IncludeAnonymous||c instanceof Ys||!c.type.isAnonymous||i1(c))return!1}return!0}move(e,n){if(n&&this.enterChild(e,0,4))return!0;for(;;){if(this.sibling(e))return!0;if(this.atLastNode(e)||!this.parent())return!1}}next(e=!0){return this.move(1,e)}prev(e=!0){return this.move(-1,e)}moveTo(e,n=0){for(;(this.from==this.to||(n<1?this.from>=e:this.from>e)||(n>-1?this.to<=e:this.to<e))&&this.parent(););for(;this.enterChild(1,e,n););return this}get node(){if(!this.buffer)return this._tree;let e=this.bufferNode,n=null,r=0;if(e&&e.context==this.buffer)e:for(let i=this.index,a=this.stack.length;a>=0;){for(let o=e;o;o=o._parent)if(o.index==i){if(i==this.index)return o;n=o,r=a+1;break e}i=this.stack[--a]}for(let i=r;i<this.stack.length;i++)n=new sa(this.buffer,n,this.stack[i]);return this.bufferNode=new sa(this.buffer,n,this.index)}get tree(){return this.buffer?null:this._tree._tree}iterate(e,n){for(let r=0;;){let i=!1;if(this.type.isAnonymous||e(this)!==!1){if(this.firstChild()){r++;continue}this.type.isAnonymous||(i=!0)}for(;;){if(i&&n&&n(this),i=this.type.isAnonymous,!r)return;if(this.nextSibling())break;this.parent(),r--,i=!0}}}matchContext(e){if(!this.buffer)return hb(this.node.parent,e);let{buffer:n}=this.buffer,{types:r}=n.set;for(let i=e.length-1,a=this.stack.length-1;i>=0;a--){if(a<0)return hb(this._tree,e,i);let o=r[n.buffer[this.stack[a]]];if(!o.isAnonymous){if(e[i]&&e[i]!=o.name)return!1;i--}}return!0}}function i1(t){return t.children.some(e=>e instanceof Ys||!e.type.isAnonymous||i1(e))}function _Y(t){var e;let{buffer:n,nodeSet:r,maxBufferLength:i=sj,reused:a=[],minRepeatType:o=r.types.length}=t,c=Array.isArray(n)?new r1(n,n.length):n,u=r.types,f=0,h=0;function m($,P,_,M,V,F){let{id:W,start:I,end:ne,size:ee}=c,pe=h,D=f;if(ee<0)if(c.next(),ee==-1){let A=a[W];_.push(A),M.push(I-$);return}else if(ee==-3){f=W;return}else if(ee==-4){h=W;return}else throw new RangeError(`Unrecognized record size: ${ee}`);let G=u[W],B,ye,X=I-$;if(ne-I<=i&&(ye=k(c.pos-P,V))){let A=new Uint16Array(ye.size-ye.skip),N=c.pos-ye.size,L=A.length;for(;c.pos>N;)L=T(ye.start,A,L);B=new Ys(A,ne-ye.start,r),X=ye.start-$}else{let A=c.pos-ee;c.next();let N=[],L=[],q=W>=o?W:-1,se=0,he=ne;for(;c.pos>A;)q>=0&&c.id==q&&c.size>=0?(c.end<=he-i&&(x(N,L,I,se,c.end,he,q,pe,D),se=N.length,he=c.end),c.next()):F>2500?g(I,A,N,L):m(I,A,N,L,q,F+1);if(q>=0&&se>0&&se<N.length&&x(N,L,I,se,I,he,q,pe,D),N.reverse(),L.reverse(),q>-1&&se>0){let H=y(G,D);B=a1(G,N,L,0,N.length,0,ne-I,H,H)}else B=S(G,N,L,ne-I,pe-ne,D)}_.push(B),M.push(X)}function g($,P,_,M){let V=[],F=0,W=-1;for(;c.pos>P;){let{id:I,start:ne,end:ee,size:pe}=c;if(pe>4)c.next();else{if(W>-1&&ne<W)break;W<0&&(W=ee-i),V.push(I,ne,ee),F++,c.next()}}if(F){let I=new Uint16Array(F*4),ne=V[V.length-2];for(let ee=V.length-3,pe=0;ee>=0;ee-=3)I[pe++]=V[ee],I[pe++]=V[ee+1]-ne,I[pe++]=V[ee+2]-ne,I[pe++]=pe;_.push(new Ys(I,V[2]-ne,r)),M.push(ne-$)}}function y($,P){return(_,M,V)=>{let F=0,W=_.length-1,I,ne;if(W>=0&&(I=_[W])instanceof tn){if(!W&&I.type==$&&I.length==V)return I;(ne=I.prop(ct.lookAhead))&&(F=M[W]+I.length+ne)}return S($,_,M,V,F,P)}}function x($,P,_,M,V,F,W,I,ne){let ee=[],pe=[];for(;$.length>M;)ee.push($.pop()),pe.push(P.pop()+_-V);$.push(S(r.types[W],ee,pe,F-V,I-F,ne)),P.push(V-_)}function S($,P,_,M,V,F,W){if(F){let I=[ct.contextHash,F];W=W?[I].concat(W):[I]}if(V>25){let I=[ct.lookAhead,V];W=W?[I].concat(W):[I]}return new tn($,P,_,M,W)}function k($,P){let _=c.fork(),M=0,V=0,F=0,W=_.end-i,I={size:0,start:0,skip:0};e:for(let ne=_.pos-$;_.pos>ne;){let ee=_.size;if(_.id==P&&ee>=0){I.size=M,I.start=V,I.skip=F,F+=4,M+=4,_.next();continue}let pe=_.pos-ee;if(ee<0||pe<ne||_.start<W)break;let D=_.id>=o?4:0,G=_.start;for(_.next();_.pos>pe;){if(_.size<0)if(_.size==-3||_.size==-4)D+=4;else break e;else _.id>=o&&(D+=4);_.next()}V=G,M+=ee,F+=D}return(P<0||M==$)&&(I.size=M,I.start=V,I.skip=F),I.size>4?I:void 0}function T($,P,_){let{id:M,start:V,end:F,size:W}=c;if(c.next(),W>=0&&M<o){let I=_;if(W>4){let ne=c.pos-(W-4);for(;c.pos>ne;)_=T($,P,_)}P[--_]=I,P[--_]=F-$,P[--_]=V-$,P[--_]=M}else W==-3?f=M:W==-4&&(h=M);return _}let C=[],E=[];for(;c.pos>0;)m(t.start||0,t.bufferStart||0,C,E,-1,0);let R=(e=t.length)!==null&&e!==void 0?e:C.length?E[0]+C[0].length:0;return new tn(u[t.topID],C.reverse(),E.reverse(),R)}const mE=new WeakMap;function kp(t,e){if(!t.isAnonymous||e instanceof Ys||e.type!=t)return 1;let n=mE.get(e);if(n==null){n=1;for(let r of e.children){if(r.type!=t||!(r instanceof tn)){n=1;break}n+=kp(t,r)}mE.set(e,n)}return n}function a1(t,e,n,r,i,a,o,c,u){let f=0;for(let x=r;x<i;x++)f+=kp(t,e[x]);let h=Math.ceil(f*1.5/8),m=[],g=[];function y(x,S,k,T,C){for(let E=k;E<T;){let R=E,$=S[E],P=kp(t,x[E]);for(E++;E<T;E++){let _=kp(t,x[E]);if(P+_>=h)break;P+=_}if(E==R+1){if(P>h){let _=x[R];y(_.children,_.positions,0,_.children.length,S[R]+C);continue}m.push(x[R])}else{let _=S[E-1]+x[E-1].length-$;m.push(a1(t,x,S,R,E,$,_,null,u))}g.push($+C-a)}}return y(e,n,r,i,0),(c||u)(m,g,o)}class uj{constructor(){this.map=new WeakMap}setBuffer(e,n,r){let i=this.map.get(e);i||this.map.set(e,i=new Map),i.set(n,r)}getBuffer(e,n){let r=this.map.get(e);return r&&r.get(n)}set(e,n){e instanceof sa?this.setBuffer(e.context.buffer,e.index,n):e instanceof Kn&&this.map.set(e.tree,n)}get(e){return e instanceof sa?this.getBuffer(e.context.buffer,e.index):e instanceof Kn?this.map.get(e.tree):void 0}cursorSet(e,n){e.buffer?this.setBuffer(e.buffer.buffer,e.index,n):this.map.set(e.tree,n)}cursorGet(e){return e.buffer?this.getBuffer(e.buffer.buffer,e.index):this.map.get(e.tree)}}class Ia{constructor(e,n,r,i,a=!1,o=!1){this.from=e,this.to=n,this.tree=r,this.offset=i,this.open=(a?1:0)|(o?2:0)}get openStart(){return(this.open&1)>0}get openEnd(){return(this.open&2)>0}static addTree(e,n=[],r=!1){let i=[new Ia(0,e.length,e,0,!1,r)];for(let a of n)a.to>e.length&&i.push(a);return i}static applyChanges(e,n,r=128){if(!n.length)return e;let i=[],a=1,o=e.length?e[0]:null;for(let c=0,u=0,f=0;;c++){let h=c<n.length?n[c]:null,m=h?h.fromA:1e9;if(m-u>=r)for(;o&&o.from<m;){let g=o;if(u>=g.from||m<=g.to||f){let y=Math.max(g.from,u)-f,x=Math.min(g.to,m)-f;g=y>=x?null:new Ia(y,x,g.tree,g.offset+f,c>0,!!h)}if(g&&i.push(g),o.to>m)break;o=a<e.length?e[a++]:null}if(!h)break;u=h.toA,f=h.toA-h.toB}return i}}class dj{startParse(e,n,r){return typeof e=="string"&&(e=new $Y(e)),r=r?r.length?r.map(i=>new si(i.from,i.to)):[new si(0,0)]:[new si(0,e.length)],this.createParse(e,n||[],r)}parse(e,n,r){let i=this.startParse(e,n,r);for(;;){let a=i.advance();if(a)return a}}}class $Y{constructor(e){this.string=e}get length(){return this.string.length}chunk(e){return this.string.slice(e)}get lineChunks(){return!1}read(e,n){return this.string.slice(e,n)}}function PY(t){return(e,n,r,i)=>new MY(e,t,n,r,i)}class gE{constructor(e,n,r,i,a){this.parser=e,this.parse=n,this.overlay=r,this.target=i,this.from=a}}function OE(t){if(!t.length||t.some(e=>e.from>=e.to))throw new RangeError("Invalid inner parse ranges given: "+JSON.stringify(t))}class jY{constructor(e,n,r,i,a,o,c){this.parser=e,this.predicate=n,this.mounts=r,this.index=i,this.start=a,this.target=o,this.prev=c,this.depth=0,this.ranges=[]}}const pb=new ct({perNode:!0});class MY{constructor(e,n,r,i,a){this.nest=n,this.input=r,this.fragments=i,this.ranges=a,this.inner=[],this.innerDone=0,this.baseTree=null,this.stoppedAt=null,this.baseParse=e}advance(){if(this.baseParse){let r=this.baseParse.advance();if(!r)return null;if(this.baseParse=null,this.baseTree=r,this.startInner(),this.stoppedAt!=null)for(let i of this.inner)i.parse.stopAt(this.stoppedAt)}if(this.innerDone==this.inner.length){let r=this.baseTree;return this.stoppedAt!=null&&(r=new tn(r.type,r.children,r.positions,r.length,r.propValues.concat([[pb,this.stoppedAt]]))),r}let e=this.inner[this.innerDone],n=e.parse.advance();if(n){this.innerDone++;let r=Object.assign(Object.create(null),e.target.props);r[ct.mounted.id]=new Rd(n,e.overlay,e.parser),e.target.props=r}return null}get parsedPos(){if(this.baseParse)return 0;let e=this.input.length;for(let n=this.innerDone;n<this.inner.length;n++)this.inner[n].from<e&&(e=Math.min(e,this.inner[n].parse.parsedPos));return e}stopAt(e){if(this.stoppedAt=e,this.baseParse)this.baseParse.stopAt(e);else for(let n=this.innerDone;n<this.inner.length;n++)this.inner[n].parse.stopAt(e)}startInner(){let e=new zY(this.fragments),n=null,r=null,i=new Jp(new Kn(this.baseTree,this.ranges[0].from,0,null),Ut.IncludeAnonymous|Ut.IgnoreMounts);e:for(let a,o;;){let c=!0,u;if(this.stoppedAt!=null&&i.from>=this.stoppedAt)c=!1;else if(e.hasNode(i)){if(n){let f=n.mounts.find(h=>h.frag.from<=i.from&&h.frag.to>=i.to&&h.mount.overlay);if(f)for(let h of f.mount.overlay){let m=h.from+f.pos,g=h.to+f.pos;m>=i.from&&g<=i.to&&!n.ranges.some(y=>y.from<g&&y.to>m)&&n.ranges.push({from:m,to:g})}}c=!1}else if(r&&(o=NY(r.ranges,i.from,i.to)))c=o!=2;else if(!i.type.isAnonymous&&(a=this.nest(i,this.input))&&(i.from<i.to||!a.overlay)){i.tree||(DY(i),n&&n.depth++,r&&r.depth++);let f=e.findMounts(i.from,a.parser);if(typeof a.overlay=="function")n=new jY(a.parser,a.overlay,f,this.inner.length,i.from,i.tree,n);else{let h=bE(this.ranges,a.overlay||(i.from<i.to?[new si(i.from,i.to)]:[]));h.length&&OE(h),(h.length||!a.overlay)&&this.inner.push(new gE(a.parser,h.length?a.parser.startParse(this.input,xE(f,h),h):a.parser.startParse(""),a.overlay?a.overlay.map(m=>new si(m.from-i.from,m.to-i.from)):null,i.tree,h.length?h[0].from:i.from)),a.overlay?h.length&&(r={ranges:h,depth:0,prev:r}):c=!1}}else if(n&&(u=n.predicate(i))&&(u===!0&&(u=new si(i.from,i.to)),u.from<u.to)){let f=n.ranges.length-1;f>=0&&n.ranges[f].to==u.from?n.ranges[f]={from:n.ranges[f].from,to:u.to}:n.ranges.push(u)}if(c&&i.firstChild())n&&n.depth++,r&&r.depth++;else for(;!i.nextSibling();){if(!i.parent())break e;if(n&&!--n.depth){let f=bE(this.ranges,n.ranges);f.length&&(OE(f),this.inner.splice(n.index,0,new gE(n.parser,n.parser.startParse(this.input,xE(n.mounts,f),f),n.ranges.map(h=>new si(h.from-n.start,h.to-n.start)),n.target,f[0].from))),n=n.prev}r&&!--r.depth&&(r=r.prev)}}}}function NY(t,e,n){for(let r of t){if(r.from>=n)break;if(r.to>e)return r.from<=e&&r.to>=n?2:1}return 0}function vE(t,e,n,r,i,a){if(e<n){let o=t.buffer[e+1];r.push(t.slice(e,n,o)),i.push(o-a)}}function DY(t){let{node:e}=t,n=[],r=e.context.buffer;do n.push(t.index),t.parent();while(!t.tree);let i=t.tree,a=i.children.indexOf(r),o=i.children[a],c=o.buffer,u=[a];function f(h,m,g,y,x,S){let k=n[S],T=[],C=[];vE(o,h,k,T,C,y);let E=c[k+1],R=c[k+2];u.push(T.length);let $=S?f(k+4,c[k+3],o.set.types[c[k]],E,R-E,S-1):e.toTree();return T.push($),C.push(E-y),vE(o,c[k+3],m,T,C,y),new tn(g,T,C,x)}i.children[a]=f(0,c.length,ur.none,0,o.length,n.length-1);for(let h of u){let m=t.tree.children[h],g=t.tree.positions[h];t.yield(new Kn(m,g+t.from,h,t._tree))}}class yE{constructor(e,n){this.offset=n,this.done=!1,this.cursor=e.cursor(Ut.IncludeAnonymous|Ut.IgnoreMounts)}moveTo(e){let{cursor:n}=this,r=e-this.offset;for(;!this.done&&n.from<r;)n.to>=e&&n.enter(r,1,Ut.IgnoreOverlays|Ut.ExcludeBuffers)||n.next(!1)||(this.done=!0)}hasNode(e){if(this.moveTo(e.from),!this.done&&this.cursor.from+this.offset==e.from&&this.cursor.tree)for(let n=this.cursor.tree;;){if(n==e.tree)return!0;if(n.children.length&&n.positions[0]==0&&n.children[0]instanceof tn)n=n.children[0];else break}return!1}}let zY=class{constructor(e){var n;if(this.fragments=e,this.curTo=0,this.fragI=0,e.length){let r=this.curFrag=e[0];this.curTo=(n=r.tree.prop(pb))!==null&&n!==void 0?n:r.to,this.inner=new yE(r.tree,-r.offset)}else this.curFrag=this.inner=null}hasNode(e){for(;this.curFrag&&e.from>=this.curTo;)this.nextFrag();return this.curFrag&&this.curFrag.from<=e.from&&this.curTo>=e.to&&this.inner.hasNode(e)}nextFrag(){var e;if(this.fragI++,this.fragI==this.fragments.length)this.curFrag=this.inner=null;else{let n=this.curFrag=this.fragments[this.fragI];this.curTo=(e=n.tree.prop(pb))!==null&&e!==void 0?e:n.to,this.inner=new yE(n.tree,-n.offset)}}findMounts(e,n){var r;let i=[];if(this.inner){this.inner.cursor.moveTo(e,1);for(let a=this.inner.cursor.node;a;a=a.parent){let o=(r=a.tree)===null||r===void 0?void 0:r.prop(ct.mounted);if(o&&o.parser==n)for(let c=this.fragI;c<this.fragments.length;c++){let u=this.fragments[c];if(u.from>=a.to)break;u.tree==this.curFrag.tree&&i.push({frag:u,pos:a.from-u.offset,mount:o})}}}return i}};function bE(t,e){let n=null,r=e;for(let i=1,a=0;i<t.length;i++){let o=t[i-1].to,c=t[i].from;for(;a<r.length;a++){let u=r[a];if(u.from>=c)break;u.to<=o||(n||(r=n=e.slice()),u.from<o?(n[a]=new si(u.from,o),u.to>c&&n.splice(a+1,0,new si(c,u.to))):u.to>c?n[a--]=new si(c,u.to):n.splice(a--,1))}}return r}function LY(t,e,n,r){let i=0,a=0,o=!1,c=!1,u=-1e9,f=[];for(;;){let h=i==t.length?1e9:o?t[i].to:t[i].from,m=a==e.length?1e9:c?e[a].to:e[a].from;if(o!=c){let g=Math.max(u,n),y=Math.min(h,m,r);g<y&&f.push(new si(g,y))}if(u=Math.min(h,m),u==1e9)break;h==u&&(o?(o=!1,i++):o=!0),m==u&&(c?(c=!1,a++):c=!0)}return f}function xE(t,e){let n=[];for(let{pos:r,mount:i,frag:a}of t){let o=r+(i.overlay?i.overlay[0].from:0),c=o+i.tree.length,u=Math.max(a.from,o),f=Math.min(a.to,c);if(i.overlay){let h=i.overlay.map(g=>new si(g.from+r,g.to+r)),m=LY(e,h,u,f);for(let g=0,y=u;;g++){let x=g==m.length,S=x?f:m[g].from;if(S>y&&n.push(new Ia(y,S,i.tree,-o,a.from>=y||a.openStart,a.to<=S||a.openEnd)),x)break;y=m[g].to}}else n.push(new Ia(u,f,i.tree,-o,a.from>=o||a.openStart,a.to<=c||a.openEnd))}return n}let ZY=0;class ri{constructor(e,n,r,i){this.name=e,this.set=n,this.base=r,this.modified=i,this.id=ZY++}toString(){let{name:e}=this;for(let n of this.modified)n.name&&(e=`${n.name}(${e})`);return e}static define(e,n){let r=typeof e=="string"?e:"?";if(e instanceof ri&&(n=e),n?.base)throw new Error("Can not derive from a modified tag");let i=new ri(r,[],null,[]);if(i.set.push(i),n)for(let a of n.set)i.set.push(a);return i}static defineModifier(e){let n=new em(e);return r=>r.modified.indexOf(n)>-1?r:em.get(r.base||r,r.modified.concat(n).sort((i,a)=>i.id-a.id))}}let VY=0;class em{constructor(e){this.name=e,this.instances=[],this.id=VY++}static get(e,n){if(!n.length)return e;let r=n[0].instances.find(c=>c.base==e&&XY(n,c.modified));if(r)return r;let i=[],a=new ri(e.name,i,e,n);for(let c of n)c.instances.push(a);let o=BY(n);for(let c of e.set)if(!c.modified.length)for(let u of o)i.push(em.get(c,u));return a}}function XY(t,e){return t.length==e.length&&t.every((n,r)=>n==e[r])}function BY(t){let e=[[]];for(let n=0;n<t.length;n++)for(let r=0,i=e.length;r<i;r++)e.push(e[r].concat(t[n]));return e.sort((n,r)=>r.length-n.length)}function ag(t){let e=Object.create(null);for(let n in t){let r=t[n];Array.isArray(r)||(r=[r]);for(let i of n.split(" "))if(i){let a=[],o=2,c=i;for(let m=0;;){if(c=="..."&&m>0&&m+3==i.length){o=1;break}let g=/^"(?:[^"\\]|\\.)*?"|[^\/!]+/.exec(c);if(!g)throw new RangeError("Invalid path: "+i);if(a.push(g[0]=="*"?"":g[0][0]=='"'?JSON.parse(g[0]):g[0]),m+=g[0].length,m==i.length)break;let y=i[m++];if(m==i.length&&y=="!"){o=0;break}if(y!="/")throw new RangeError("Invalid path: "+i);c=i.slice(m)}let u=a.length-1,f=a[u];if(!f)throw new RangeError("Invalid path: "+i);let h=new $d(r,o,u>0?a.slice(0,u):null);e[f]=h.sort(e[f])}}return fj.add(e)}const fj=new ct({combine(t,e){let n,r,i;for(;t||e;){if(!t||e&&t.depth>=e.depth?(i=e,e=e.next):(i=t,t=t.next),n&&n.mode==i.mode&&!i.context&&!n.context)continue;let a=new $d(i.tags,i.mode,i.context);n?n.next=a:r=a,n=a}return r}});class $d{constructor(e,n,r,i){this.tags=e,this.mode=n,this.context=r,this.next=i}get opaque(){return this.mode==0}get inherit(){return this.mode==1}sort(e){return!e||e.depth<this.depth?(this.next=e,this):(e.next=this.sort(e.next),e)}get depth(){return this.context?this.context.length:0}}$d.empty=new $d([],2,null);function hj(t,e){let n=Object.create(null);for(let a of t)if(!Array.isArray(a.tag))n[a.tag.id]=a.class;else for(let o of a.tag)n[o.id]=a.class;let{scope:r,all:i=null}=e||{};return{style:a=>{let o=i;for(let c of a)for(let u of c.set){let f=n[u.id];if(f){o=o?o+" "+f:f;break}}return o},scope:r}}function IY(t,e){let n=null;for(let r of t){let i=r.style(e);i&&(n=n?n+" "+i:i)}return n}function pj(t,e,n,r=0,i=t.length){let a=new qY(r,Array.isArray(e)?e:[e],n);a.highlightRange(t.cursor(),r,i,"",a.highlighters),a.flush(i)}class qY{constructor(e,n,r){this.at=e,this.highlighters=n,this.span=r,this.class=""}startSpan(e,n){n!=this.class&&(this.flush(e),e>this.at&&(this.at=e),this.class=n)}flush(e){e>this.at&&this.class&&this.span(this.at,e,this.class)}highlightRange(e,n,r,i,a){let{type:o,from:c,to:u}=e;if(c>=r||u<=n)return;o.isTop&&(a=this.highlighters.filter(y=>!y.scope||y.scope(o)));let f=i,h=UY(e)||$d.empty,m=IY(a,h.tags);if(m&&(f&&(f+=" "),f+=m,h.mode==1&&(i+=(i?" ":"")+m)),this.startSpan(Math.max(n,c),f),h.opaque)return;let g=e.tree&&e.tree.prop(ct.mounted);if(g&&g.overlay){let y=e.node.enter(g.overlay[0].from+c,1),x=this.highlighters.filter(k=>!k.scope||k.scope(g.tree.type)),S=e.firstChild();for(let k=0,T=c;;k++){let C=k<g.overlay.length?g.overlay[k]:null,E=C?C.from+c:u,R=Math.max(n,T),$=Math.min(r,E);if(R<$&&S)for(;e.from<$&&(this.highlightRange(e,R,$,i,a),this.startSpan(Math.min($,e.to),f),!(e.to>=E||!e.nextSibling())););if(!C||E>r)break;T=C.to+c,T>n&&(this.highlightRange(y.cursor(),Math.max(n,C.from+c),Math.min(r,T),"",x),this.startSpan(Math.min(r,T),f))}S&&e.parent()}else if(e.firstChild()){g&&(i="");do if(!(e.to<=n)){if(e.from>=r)break;this.highlightRange(e,n,r,i,a),this.startSpan(Math.min(r,e.to),f)}while(e.nextSibling());e.parent()}}}function UY(t){let e=t.type.prop(fj);for(;e&&e.context&&!t.matchContext(e.context);)e=e.next;return e||null}const Qe=ri.define,Gh=Qe(),Es=Qe(),SE=Qe(Es),wE=Qe(Es),Qs=Qe(),Hh=Qe(Qs),Ty=Qe(Qs),Ki=Qe(),So=Qe(Ki),Wi=Qe(),Gi=Qe(),mb=Qe(),Uu=Qe(mb),Kh=Qe(),J={comment:Gh,lineComment:Qe(Gh),blockComment:Qe(Gh),docComment:Qe(Gh),name:Es,variableName:Qe(Es),typeName:SE,tagName:Qe(SE),propertyName:wE,attributeName:Qe(wE),className:Qe(Es),labelName:Qe(Es),namespace:Qe(Es),macroName:Qe(Es),literal:Qs,string:Hh,docString:Qe(Hh),character:Qe(Hh),attributeValue:Qe(Hh),number:Ty,integer:Qe(Ty),float:Qe(Ty),bool:Qe(Qs),regexp:Qe(Qs),escape:Qe(Qs),color:Qe(Qs),url:Qe(Qs),keyword:Wi,self:Qe(Wi),null:Qe(Wi),atom:Qe(Wi),unit:Qe(Wi),modifier:Qe(Wi),operatorKeyword:Qe(Wi),controlKeyword:Qe(Wi),definitionKeyword:Qe(Wi),moduleKeyword:Qe(Wi),operator:Gi,derefOperator:Qe(Gi),arithmeticOperator:Qe(Gi),logicOperator:Qe(Gi),bitwiseOperator:Qe(Gi),compareOperator:Qe(Gi),updateOperator:Qe(Gi),definitionOperator:Qe(Gi),typeOperator:Qe(Gi),controlOperator:Qe(Gi),punctuation:mb,separator:Qe(mb),bracket:Uu,angleBracket:Qe(Uu),squareBracket:Qe(Uu),paren:Qe(Uu),brace:Qe(Uu),content:Ki,heading:So,heading1:Qe(So),heading2:Qe(So),heading3:Qe(So),heading4:Qe(So),heading5:Qe(So),heading6:Qe(So),contentSeparator:Qe(Ki),list:Qe(Ki),quote:Qe(Ki),emphasis:Qe(Ki),strong:Qe(Ki),link:Qe(Ki),monospace:Qe(Ki),strikethrough:Qe(Ki),inserted:Qe(),deleted:Qe(),changed:Qe(),invalid:Qe(),meta:Kh,documentMeta:Qe(Kh),annotation:Qe(Kh),processingInstruction:Qe(Kh),definition:ri.defineModifier("definition"),constant:ri.defineModifier("constant"),function:ri.defineModifier("function"),standard:ri.defineModifier("standard"),local:ri.defineModifier("local"),special:ri.defineModifier("special")};for(let t in J){let e=J[t];e instanceof ri&&(e.name=t)}hj([{tag:J.link,class:"tok-link"},{tag:J.heading,class:"tok-heading"},{tag:J.emphasis,class:"tok-emphasis"},{tag:J.strong,class:"tok-strong"},{tag:J.keyword,class:"tok-keyword"},{tag:J.atom,class:"tok-atom"},{tag:J.bool,class:"tok-bool"},{tag:J.url,class:"tok-url"},{tag:J.labelName,class:"tok-labelName"},{tag:J.inserted,class:"tok-inserted"},{tag:J.deleted,class:"tok-deleted"},{tag:J.literal,class:"tok-literal"},{tag:J.string,class:"tok-string"},{tag:J.number,class:"tok-number"},{tag:[J.regexp,J.escape,J.special(J.string)],class:"tok-string2"},{tag:J.variableName,class:"tok-variableName"},{tag:J.local(J.variableName),class:"tok-variableName tok-local"},{tag:J.definition(J.variableName),class:"tok-variableName tok-definition"},{tag:J.special(J.variableName),class:"tok-variableName2"},{tag:J.definition(J.propertyName),class:"tok-propertyName tok-definition"},{tag:J.typeName,class:"tok-typeName"},{tag:J.namespace,class:"tok-namespace"},{tag:J.className,class:"tok-className"},{tag:J.macroName,class:"tok-macroName"},{tag:J.propertyName,class:"tok-propertyName"},{tag:J.operator,class:"tok-operator"},{tag:J.comment,class:"tok-comment"},{tag:J.meta,class:"tok-meta"},{tag:J.invalid,class:"tok-invalid"},{tag:J.punctuation,class:"tok-punctuation"}]);var Ey;const tc=new ct;function mj(t){return Xe.define({combine:t?e=>e.concat(t):void 0})}const s1=new ct;class Ei{constructor(e,n,r=[],i=""){this.data=e,this.name=i,At.prototype.hasOwnProperty("tree")||Object.defineProperty(At.prototype,"tree",{get(){return Mn(this)}}),this.parser=n,this.extension=[kc.of(this),At.languageData.of((a,o,c)=>{let u=kE(a,o,c),f=u.type.prop(tc);if(!f)return[];let h=a.facet(f),m=u.type.prop(s1);if(m){let g=u.resolve(o-u.from,c);for(let y of m)if(y.test(g,a)){let x=a.facet(y.facet);return y.type=="replace"?x:x.concat(h)}}return h})].concat(r)}isActiveAt(e,n,r=-1){return kE(e,n,r).type.prop(tc)==this.data}findRegions(e){let n=e.facet(kc);if(n?.data==this.data)return[{from:0,to:e.doc.length}];if(!n||!n.allowsNesting)return[];let r=[],i=(a,o)=>{if(a.prop(tc)==this.data){r.push({from:o,to:o+a.length});return}let c=a.prop(ct.mounted);if(c){if(c.tree.prop(tc)==this.data){if(c.overlay)for(let u of c.overlay)r.push({from:u.from+o,to:u.to+o});else r.push({from:o,to:o+a.length});return}else if(c.overlay){let u=r.length;if(i(c.tree,c.overlay[0].from+o),r.length>u)return}}for(let u=0;u<a.children.length;u++){let f=a.children[u];f instanceof tn&&i(f,a.positions[u]+o)}};return i(Mn(e),0),r}get allowsNesting(){return!0}}Ei.setState=Vt.define();function kE(t,e,n){let r=t.facet(kc),i=Mn(t).topNode;if(!r||r.allowsNesting)for(let a=i;a;a=a.enter(e,n,Ut.ExcludeBuffers))a.type.isTop&&(i=a);return i}class Sc extends Ei{constructor(e,n,r){super(e,n,[],r),this.parser=n}static define(e){let n=mj(e.languageData);return new Sc(n,e.parser.configure({props:[tc.add(r=>r.isTop?n:void 0)]}),e.name)}configure(e,n){return new Sc(this.data,this.parser.configure(e),n||this.name)}get allowsNesting(){return this.parser.hasWrappers()}}function Mn(t){let e=t.field(Ei.state,!1);return e?e.tree:tn.empty}class YY{constructor(e){this.doc=e,this.cursorPos=0,this.string="",this.cursor=e.iter()}get length(){return this.doc.length}syncTo(e){return this.string=this.cursor.next(e-this.cursorPos).value,this.cursorPos=e+this.string.length,this.cursorPos-this.string.length}chunk(e){return this.syncTo(e),this.string}get lineChunks(){return!0}read(e,n){let r=this.cursorPos-this.string.length;return e<r||n>=this.cursorPos?this.doc.sliceString(e,n):this.string.slice(e-r,n-r)}}let Yu=null;class tm{constructor(e,n,r=[],i,a,o,c,u){this.parser=e,this.state=n,this.fragments=r,this.tree=i,this.treeLen=a,this.viewport=o,this.skipped=c,this.scheduleOn=u,this.parse=null,this.tempSkipped=[]}static create(e,n,r){return new tm(e,n,[],tn.empty,0,r,[],null)}startParse(){return this.parser.startParse(new YY(this.state.doc),this.fragments)}work(e,n){return n!=null&&n>=this.state.doc.length&&(n=void 0),this.tree!=tn.empty&&this.isDone(n??this.state.doc.length)?(this.takeTree(),!0):this.withContext(()=>{var r;if(typeof e=="number"){let i=Date.now()+e;e=()=>Date.now()>i}for(this.parse||(this.parse=this.startParse()),n!=null&&(this.parse.stoppedAt==null||this.parse.stoppedAt>n)&&n<this.state.doc.length&&this.parse.stopAt(n);;){let i=this.parse.advance();if(i)if(this.fragments=this.withoutTempSkipped(Ia.addTree(i,this.fragments,this.parse.stoppedAt!=null)),this.treeLen=(r=this.parse.stoppedAt)!==null&&r!==void 0?r:this.state.doc.length,this.tree=i,this.parse=null,this.treeLen<(n??this.state.doc.length))this.parse=this.startParse();else return!0;if(e())return!1}})}takeTree(){let e,n;this.parse&&(e=this.parse.parsedPos)>=this.treeLen&&((this.parse.stoppedAt==null||this.parse.stoppedAt>e)&&this.parse.stopAt(e),this.withContext(()=>{for(;!(n=this.parse.advance()););}),this.treeLen=e,this.tree=n,this.fragments=this.withoutTempSkipped(Ia.addTree(this.tree,this.fragments,!0)),this.parse=null)}withContext(e){let n=Yu;Yu=this;try{return e()}finally{Yu=n}}withoutTempSkipped(e){for(let n;n=this.tempSkipped.pop();)e=CE(e,n.from,n.to);return e}changes(e,n){let{fragments:r,tree:i,treeLen:a,viewport:o,skipped:c}=this;if(this.takeTree(),!e.empty){let u=[];if(e.iterChangedRanges((f,h,m,g)=>u.push({fromA:f,toA:h,fromB:m,toB:g})),r=Ia.applyChanges(r,u),i=tn.empty,a=0,o={from:e.mapPos(o.from,-1),to:e.mapPos(o.to,1)},this.skipped.length){c=[];for(let f of this.skipped){let h=e.mapPos(f.from,1),m=e.mapPos(f.to,-1);h<m&&c.push({from:h,to:m})}}}return new tm(this.parser,n,r,i,a,o,c,this.scheduleOn)}updateViewport(e){if(this.viewport.from==e.from&&this.viewport.to==e.to)return!1;this.viewport=e;let n=this.skipped.length;for(let r=0;r<this.skipped.length;r++){let{from:i,to:a}=this.skipped[r];i<e.to&&a>e.from&&(this.fragments=CE(this.fragments,i,a),this.skipped.splice(r--,1))}return this.skipped.length>=n?!1:(this.reset(),!0)}reset(){this.parse&&(this.takeTree(),this.parse=null)}skipUntilInView(e,n){this.skipped.push({from:e,to:n})}static getSkippingParser(e){return new class extends dj{createParse(n,r,i){let a=i[0].from,o=i[i.length-1].to;return{parsedPos:a,advance(){let u=Yu;if(u){for(let f of i)u.tempSkipped.push(f);e&&(u.scheduleOn=u.scheduleOn?Promise.all([u.scheduleOn,e]):e)}return this.parsedPos=o,new tn(ur.none,[],[],o-a)},stoppedAt:null,stopAt(){}}}}}isDone(e){e=Math.min(e,this.state.doc.length);let n=this.fragments;return this.treeLen>=e&&n.length&&n[0].from==0&&n[0].to>=e}static get(){return Yu}}function CE(t,e,n){return Ia.applyChanges(t,[{fromA:e,toA:n,fromB:e,toB:n}])}class wc{constructor(e){this.context=e,this.tree=e.tree}apply(e){if(!e.docChanged&&this.tree==this.context.tree)return this;let n=this.context.changes(e.changes,e.state),r=this.context.treeLen==e.startState.doc.length?void 0:Math.max(e.changes.mapPos(this.context.treeLen),n.viewport.to);return n.work(20,r)||n.takeTree(),new wc(n)}static init(e){let n=Math.min(3e3,e.doc.length),r=tm.create(e.facet(kc).parser,e,{from:0,to:n});return r.work(20,n)||r.takeTree(),new wc(r)}}Ei.state=Mi.define({create:wc.init,update(t,e){for(let n of e.effects)if(n.is(Ei.setState))return n.value;return e.startState.facet(kc)!=e.state.facet(kc)?wc.init(e.state):t.apply(e)}});let gj=t=>{let e=setTimeout(()=>t(),500);return()=>clearTimeout(e)};typeof requestIdleCallback<"u"&&(gj=t=>{let e=-1,n=setTimeout(()=>{e=requestIdleCallback(t,{timeout:400})},100);return()=>e<0?clearTimeout(n):cancelIdleCallback(e)});const Qy=typeof navigator<"u"&&(!((Ey=navigator.scheduling)===null||Ey===void 0)&&Ey.isInputPending)?()=>navigator.scheduling.isInputPending():null,FY=ci.fromClass(class{constructor(e){this.view=e,this.working=null,this.workScheduled=0,this.chunkEnd=-1,this.chunkBudget=-1,this.work=this.work.bind(this),this.scheduleWork()}update(e){let n=this.view.state.field(Ei.state).context;(n.updateViewport(e.view.viewport)||this.view.viewport.to>n.treeLen)&&this.scheduleWork(),(e.docChanged||e.selectionSet)&&(this.view.hasFocus&&(this.chunkBudget+=50),this.scheduleWork()),this.checkAsyncSchedule(n)}scheduleWork(){if(this.working)return;let{state:e}=this.view,n=e.field(Ei.state);(n.tree!=n.context.tree||!n.context.isDone(e.doc.length))&&(this.working=gj(this.work))}work(e){this.working=null;let n=Date.now();if(this.chunkEnd<n&&(this.chunkEnd<0||this.view.hasFocus)&&(this.chunkEnd=n+3e4,this.chunkBudget=3e3),this.chunkBudget<=0)return;let{state:r,viewport:{to:i}}=this.view,a=r.field(Ei.state);if(a.tree==a.context.tree&&a.context.isDone(i+1e5))return;let o=Date.now()+Math.min(this.chunkBudget,100,e&&!Qy?Math.max(25,e.timeRemaining()-5):1e9),c=a.context.treeLen<i&&r.doc.length>i+1e3,u=a.context.work(()=>Qy&&Qy()||Date.now()>o,i+(c?0:1e5));this.chunkBudget-=Date.now()-n,(u||this.chunkBudget<=0)&&(a.context.takeTree(),this.view.dispatch({effects:Ei.setState.of(new wc(a.context))})),this.chunkBudget>0&&!(u&&!c)&&this.scheduleWork(),this.checkAsyncSchedule(a.context)}checkAsyncSchedule(e){e.scheduleOn&&(this.workScheduled++,e.scheduleOn.then(()=>this.scheduleWork()).catch(n=>aa(this.view.state,n)).then(()=>this.workScheduled--),e.scheduleOn=null)}destroy(){this.working&&this.working()}isWorking(){return!!(this.working||this.workScheduled>0)}},{eventHandlers:{focus(){this.scheduleWork()}}}),kc=Xe.define({combine(t){return t.length?t[0]:null},enables:t=>[Ei.state,FY,qe.contentAttributes.compute([t],e=>{let n=e.facet(t);return n&&n.name?{"data-language":n.name}:{}})]});class o1{constructor(e,n=[]){this.language=e,this.support=n,this.extension=[e,n]}}const WY=Xe.define(),sg=Xe.define({combine:t=>{if(!t.length)return" ";let e=t[0];if(!e||/\S/.test(e)||Array.from(e).some(n=>n!=e[0]))throw new Error("Invalid indent unit: "+JSON.stringify(t[0]));return e}});function nm(t){let e=t.facet(sg);return e.charCodeAt(0)==9?t.tabSize*e.length:e.length}function rm(t,e){let n="",r=t.tabSize,i=t.facet(sg)[0];if(i==" "){for(;e>=r;)n+=" ",e-=r;i=" "}for(let a=0;a<e;a++)n+=i;return n}function Oj(t,e){t instanceof At&&(t=new og(t));for(let r of t.state.facet(WY)){let i=r(t,e);if(i!==void 0)return i}let n=Mn(t.state);return n.length>=e?GY(t,n,e):null}class og{constructor(e,n={}){this.state=e,this.options=n,this.unit=nm(e)}lineAt(e,n=1){let r=this.state.doc.lineAt(e),{simulateBreak:i,simulateDoubleBreak:a}=this.options;return i!=null&&i>=r.from&&i<=r.to?a&&i==e?{text:"",from:e}:(n<0?i<e:i<=e)?{text:r.text.slice(i-r.from),from:i}:{text:r.text.slice(0,i-r.from),from:r.from}:r}textAfterPos(e,n=1){if(this.options.simulateDoubleBreak&&e==this.options.simulateBreak)return"";let{text:r,from:i}=this.lineAt(e,n);return r.slice(e-i,Math.min(r.length,e+100-i))}column(e,n=1){let{text:r,from:i}=this.lineAt(e,n),a=this.countColumn(r,e-i),o=this.options.overrideIndentation?this.options.overrideIndentation(i):-1;return o>-1&&(a+=o-this.countColumn(r,r.search(/\S|$/))),a}countColumn(e,n=e.length){return af(e,this.state.tabSize,n)}lineIndent(e,n=1){let{text:r,from:i}=this.lineAt(e,n),a=this.options.overrideIndentation;if(a){let o=a(i);if(o>-1)return o}return this.countColumn(r,r.search(/\S|$/))}get simulatedBreak(){return this.options.simulateBreak||null}}const lg=new ct;function GY(t,e,n){let r=e.resolveStack(n),i=e.resolveInner(n,-1).resolve(n,0).enterUnfinishedNodesBefore(n);if(i!=r.node){let a=[];for(let o=i;o&&!(o.from<r.node.from||o.to>r.node.to||o.from==r.node.from&&o.type==r.node.type);o=o.parent)a.push(o);for(let o=a.length-1;o>=0;o--)r={node:a[o],next:r}}return vj(r,t,n)}function vj(t,e,n){for(let r=t;r;r=r.next){let i=KY(r.node);if(i)return i(l1.create(e,n,r))}return 0}function HY(t){return t.pos==t.options.simulateBreak&&t.options.simulateDoubleBreak}function KY(t){let e=t.type.prop(lg);if(e)return e;let n=t.firstChild,r;if(n&&(r=n.type.prop(ct.closedBy))){let i=t.lastChild,a=i&&r.indexOf(i.name)>-1;return o=>yj(o,!0,1,void 0,a&&!HY(o)?i.from:void 0)}return t.parent==null?JY:null}function JY(){return 0}class l1 extends og{constructor(e,n,r){super(e.state,e.options),this.base=e,this.pos=n,this.context=r}get node(){return this.context.node}static create(e,n,r){return new l1(e,n,r)}get textAfter(){return this.textAfterPos(this.pos)}get baseIndent(){return this.baseIndentFor(this.node)}baseIndentFor(e){let n=this.state.doc.lineAt(e.from);for(;;){let r=e.resolve(n.from);for(;r.parent&&r.parent.from==r.from;)r=r.parent;if(eF(r,e))break;n=this.state.doc.lineAt(r.from)}return this.lineIndent(n.from)}continue(){return vj(this.context.next,this.base,this.pos)}}function eF(t,e){for(let n=e;n;n=n.parent)if(t==n)return!0;return!1}function tF(t){let e=t.node,n=e.childAfter(e.from),r=e.lastChild;if(!n)return null;let i=t.options.simulateBreak,a=t.state.doc.lineAt(n.from),o=i==null||i<=a.from?a.to:Math.min(a.to,i);for(let c=n.to;;){let u=e.childAfter(c);if(!u||u==r)return null;if(!u.type.isSkipped){if(u.from>=o)return null;let f=/^ */.exec(a.text.slice(n.to-a.from))[0].length;return{from:n.from,to:n.to+f}}c=u.to}}function nF({closing:t,align:e=!0,units:n=1}){return r=>yj(r,e,n,t)}function yj(t,e,n,r,i){let a=t.textAfter,o=a.match(/^\s*/)[0].length,c=r&&a.slice(o,o+r.length)==r||i==t.pos+o,u=e?tF(t):null;return u?c?t.column(u.from):t.column(u.to):t.baseIndent+(c?0:t.unit*n)}const rF=t=>t.baseIndent;function Cp({except:t,units:e=1}={}){return n=>{let r=t&&t.test(n.textAfter);return n.baseIndent+(r?0:e*n.unit)}}const c1=new ct;function bj(t){let e=t.firstChild,n=t.lastChild;return e&&e.to<n.from?{from:e.to,to:n.type.isError?t.to:n.from}:null}class cg{constructor(e,n){this.specs=e;let r;function i(c){let u=Is.newName();return(r||(r=Object.create(null)))["."+u]=c,u}const a=typeof n.all=="string"?n.all:n.all?i(n.all):void 0,o=n.scope;this.scope=o instanceof Ei?c=>c.prop(tc)==o.data:o?c=>c==o:void 0,this.style=hj(e.map(c=>({tag:c.tag,class:c.class||i(Object.assign({},c,{tag:null}))})),{all:a}).style,this.module=r?new Is(r):null,this.themeType=n.themeType}static define(e,n){return new cg(e,n||{})}}const gb=Xe.define(),iF=Xe.define({combine(t){return t.length?[t[0]]:null}});function Ay(t){let e=t.facet(gb);return e.length?e:t.facet(iF)}function aF(t,e){let n=[oF],r;return t instanceof cg&&(t.module&&n.push(qe.styleModule.of(t.module)),r=t.themeType),r?n.push(gb.computeN([qe.darkTheme],i=>i.facet(qe.darkTheme)==(r=="dark")?[t]:[])):n.push(gb.of(t)),n}class sF{constructor(e){this.markCache=Object.create(null),this.tree=Mn(e.state),this.decorations=this.buildDeco(e,Ay(e.state)),this.decoratedTo=e.viewport.to}update(e){let n=Mn(e.state),r=Ay(e.state),i=r!=Ay(e.startState),{viewport:a}=e.view,o=e.changes.mapPos(this.decoratedTo,1);n.length<a.to&&!i&&n.type==this.tree.type&&o>=a.to?(this.decorations=this.decorations.map(e.changes),this.decoratedTo=o):(n!=this.tree||e.viewportChanged||i)&&(this.tree=n,this.decorations=this.buildDeco(e.view,r),this.decoratedTo=a.to)}buildDeco(e,n){if(!n||!this.tree.length)return dt.none;let r=new Oc;for(let{from:i,to:a}of e.visibleRanges)pj(this.tree,n,(o,c,u)=>{r.add(o,c,this.markCache[u]||(this.markCache[u]=dt.mark({class:u})))},i,a);return r.finish()}}const oF=Km.high(ci.fromClass(sF,{decorations:t=>t.decorations})),lF=qe.baseTheme({"&.cm-focused .cm-matchingBracket":{backgroundColor:"#328c8252"},"&.cm-focused .cm-nonmatchingBracket":{backgroundColor:"#bb555544"}}),xj=1e4,Sj="()[]{}",wj=Xe.define({combine(t){return eg(t,{afterCursor:!0,brackets:Sj,maxScanDistance:xj,renderMatch:dF})}}),cF=dt.mark({class:"cm-matchingBracket"}),uF=dt.mark({class:"cm-nonmatchingBracket"});function dF(t){let e=[],n=t.matched?cF:uF;return e.push(n.range(t.start.from,t.start.to)),t.end&&e.push(n.range(t.end.from,t.end.to)),e}const fF=Mi.define({create(){return dt.none},update(t,e){if(!e.docChanged&&!e.selection)return t;let n=[],r=e.state.facet(wj);for(let i of e.state.selection.ranges){if(!i.empty)continue;let a=oa(e.state,i.head,-1,r)||i.head>0&&oa(e.state,i.head-1,1,r)||r.afterCursor&&(oa(e.state,i.head,1,r)||i.head<e.state.doc.length&&oa(e.state,i.head+1,-1,r));a&&(n=n.concat(r.renderMatch(a,e.state)))}return dt.set(n,!0)},provide:t=>qe.decorations.from(t)}),hF=[fF,lF];function pF(t={}){return[wj.of(t),hF]}const kj=new ct;function Ob(t,e,n){let r=t.prop(e<0?ct.openedBy:ct.closedBy);if(r)return r;if(t.name.length==1){let i=n.indexOf(t.name);if(i>-1&&i%2==(e<0?1:0))return[n[i+e]]}return null}function vb(t){let e=t.type.prop(kj);return e?e(t.node):t}function oa(t,e,n,r={}){let i=r.maxScanDistance||xj,a=r.brackets||Sj,o=Mn(t),c=o.resolveInner(e,n);for(let u=c;u;u=u.parent){let f=Ob(u.type,n,a);if(f&&u.from<u.to){let h=vb(u);if(h&&(n>0?e>=h.from&&e<h.to:e>h.from&&e<=h.to))return mF(t,e,n,u,h,f,a)}}return gF(t,e,n,o,c.type,i,a)}function mF(t,e,n,r,i,a,o){let c=r.parent,u={from:i.from,to:i.to},f=0,h=c?.cursor();if(h&&(n<0?h.childBefore(r.from):h.childAfter(r.to)))do if(n<0?h.to<=r.from:h.from>=r.to){if(f==0&&a.indexOf(h.type.name)>-1&&h.from<h.to){let m=vb(h);return{start:u,end:m?{from:m.from,to:m.to}:void 0,matched:!0}}else if(Ob(h.type,n,o))f++;else if(Ob(h.type,-n,o)){if(f==0){let m=vb(h);return{start:u,end:m&&m.from<m.to?{from:m.from,to:m.to}:void 0,matched:!1}}f--}}while(n<0?h.prevSibling():h.nextSibling());return{start:u,matched:!1}}function gF(t,e,n,r,i,a,o){let c=n<0?t.sliceDoc(e-1,e):t.sliceDoc(e,e+1),u=o.indexOf(c);if(u<0||u%2==0!=n>0)return null;let f={from:n<0?e-1:e,to:n>0?e+1:e},h=t.doc.iterRange(e,n>0?t.doc.length:0),m=0;for(let g=0;!h.next().done&&g<=a;){let y=h.value;n<0&&(g+=y.length);let x=e+g*n;for(let S=n>0?0:y.length-1,k=n>0?y.length:-1;S!=k;S+=n){let T=o.indexOf(y[S]);if(!(T<0||r.resolveInner(x+S,1).type!=i))if(T%2==0==n>0)m++;else{if(m==1)return{start:f,end:{from:x+S,to:x+S+1},matched:T>>1==u>>1};m--}}n>0&&(g+=y.length)}return h.done?{start:f,matched:!1}:null}const OF=Object.create(null),TE=[ur.none],EE=[],QE=Object.create(null),vF=Object.create(null);for(let[t,e]of[["variable","variableName"],["variable-2","variableName.special"],["string-2","string.special"],["def","variableName.definition"],["tag","tagName"],["attribute","attributeName"],["type","typeName"],["builtin","variableName.standard"],["qualifier","modifier"],["error","invalid"],["header","heading"],["property","propertyName"]])vF[t]=yF(OF,e);function Ry(t,e){EE.indexOf(t)>-1||(EE.push(t),console.warn(e))}function yF(t,e){let n=[];for(let c of e.split(" ")){let u=[];for(let f of c.split(".")){let h=t[f]||J[f];h?typeof h=="function"?u.length?u=u.map(h):Ry(f,`Modifier ${f} used at start of tag`):u.length?Ry(f,`Tag ${f} used as modifier`):u=Array.isArray(h)?h:[h]:Ry(f,`Unknown highlighting tag ${f}`)}for(let f of u)n.push(f)}if(!n.length)return 0;let r=e.replace(/ /g,"_"),i=r+" "+n.map(c=>c.id),a=QE[i];if(a)return a.id;let o=QE[i]=ur.define({id:TE.length,name:r,props:[ag({[r]:n})]});return TE.push(o),o.id}dn.RTL,dn.LTR;function AE(t){let e=Object.keys(t).join(""),n=/\w/.test(e);return n&&(e=e.replace(/\w/g,"")),`[${n?"\\w":""}${e.replace(/[^\w\s]/g,"\\$&")}]`}function bF(t){let e=Object.create(null),n=Object.create(null);for(let{label:i}of t){e[i[0]]=!0;for(let a=1;a<i.length;a++)n[i[a]]=!0}let r=AE(e)+AE(n)+"*$";return[new RegExp("^"+r),new RegExp(r)]}function xF(t){let e=t.map(i=>typeof i=="string"?{label:i}:i),[n,r]=e.every(i=>/^\w+$/.test(i.label))?[/\w*$/,/\w+$/]:bF(e);return i=>{let a=i.matchBefore(r);return a||i.explicit?{from:a?a.from:i.pos,options:e,validFor:n}:null}}function SF(t,e){return n=>{for(let r=Mn(n.state).resolveInner(n.pos,-1);r;r=r.parent){if(t.indexOf(r.name)>-1)return null;if(r.type.isTop)break}return e(n)}}const wF=Ri.define(),kF=qe.baseTheme({".cm-tooltip.cm-tooltip-autocomplete":{"& > ul":{fontFamily:"monospace",whiteSpace:"nowrap",overflow:"hidden auto",maxWidth_fallback:"700px",maxWidth:"min(700px, 95vw)",minWidth:"250px",maxHeight:"10em",height:"100%",listStyle:"none",margin:0,padding:0,"& > li, & > completion-section":{padding:"1px 3px",lineHeight:1.2},"& > li":{overflowX:"hidden",textOverflow:"ellipsis",cursor:"pointer"},"& > completion-section":{display:"list-item",borderBottom:"1px solid silver",paddingLeft:"0.5em",opacity:.7}}},"&light .cm-tooltip-autocomplete ul li[aria-selected]":{background:"#17c",color:"white"},"&light .cm-tooltip-autocomplete-disabled ul li[aria-selected]":{background:"#777"},"&dark .cm-tooltip-autocomplete ul li[aria-selected]":{background:"#347",color:"white"},"&dark .cm-tooltip-autocomplete-disabled ul li[aria-selected]":{background:"#444"},".cm-completionListIncompleteTop:before, .cm-completionListIncompleteBottom:after":{content:'"···"',opacity:.5,display:"block",textAlign:"center"},".cm-tooltip.cm-completionInfo":{position:"absolute",padding:"3px 9px",width:"max-content",maxWidth:"400px",boxSizing:"border-box",whiteSpace:"pre-line"},".cm-completionInfo.cm-completionInfo-left":{right:"100%"},".cm-completionInfo.cm-completionInfo-right":{left:"100%"},".cm-completionInfo.cm-completionInfo-left-narrow":{right:"30px"},".cm-completionInfo.cm-completionInfo-right-narrow":{left:"30px"},"&light .cm-snippetField":{backgroundColor:"#00000022"},"&dark .cm-snippetField":{backgroundColor:"#ffffff22"},".cm-snippetFieldPosition":{verticalAlign:"text-top",width:0,height:"1.15em",display:"inline-block",margin:"0 -0.7px -.7em",borderLeft:"1.4px dotted #888"},".cm-completionMatchedText":{textDecoration:"underline"},".cm-completionDetail":{marginLeft:"0.5em",fontStyle:"italic"},".cm-completionIcon":{fontSize:"90%",width:".8em",display:"inline-block",textAlign:"center",paddingRight:".6em",opacity:"0.6",boxSizing:"content-box"},".cm-completionIcon-function, .cm-completionIcon-method":{"&:after":{content:"'ƒ'"}},".cm-completionIcon-class":{"&:after":{content:"'○'"}},".cm-completionIcon-interface":{"&:after":{content:"'◌'"}},".cm-completionIcon-variable":{"&:after":{content:"'𝑥'"}},".cm-completionIcon-constant":{"&:after":{content:"'𝐶'"}},".cm-completionIcon-type":{"&:after":{content:"'𝑡'"}},".cm-completionIcon-enum":{"&:after":{content:"'∪'"}},".cm-completionIcon-property":{"&:after":{content:"'□'"}},".cm-completionIcon-keyword":{"&:after":{content:"'🔑︎'"}},".cm-completionIcon-namespace":{"&:after":{content:"'▢'"}},".cm-completionIcon-text":{"&:after":{content:"'abc'",fontSize:"50%",verticalAlign:"middle"}}});class CF{constructor(e,n,r,i){this.field=e,this.line=n,this.from=r,this.to=i}}class u1{constructor(e,n,r){this.field=e,this.from=n,this.to=r}map(e){let n=e.mapPos(this.from,-1,Hn.TrackDel),r=e.mapPos(this.to,1,Hn.TrackDel);return n==null||r==null?null:new u1(this.field,n,r)}}class d1{constructor(e,n){this.lines=e,this.fieldPositions=n}instantiate(e,n){let r=[],i=[n],a=e.doc.lineAt(n),o=/^\s*/.exec(a.text)[0];for(let u of this.lines){if(r.length){let f=o,h=/^\t*/.exec(u)[0].length;for(let m=0;m<h;m++)f+=e.facet(sg);i.push(n+f.length-h),u=f+u.slice(h)}r.push(u),n+=u.length+1}let c=this.fieldPositions.map(u=>new u1(u.field,i[u.line]+u.from,i[u.line]+u.to));return{text:r,ranges:c}}static parse(e){let n=[],r=[],i=[],a;for(let o of e.split(/\r\n?|\n/)){for(;a=/[#$]\{(?:(\d+)(?::([^{}]*))?|((?:\\[{}]|[^{}])*))\}/.exec(o);){let c=a[1]?+a[1]:null,u=a[2]||a[3]||"",f=-1,h=u.replace(/\\[{}]/g,m=>m[1]);for(let m=0;m<n.length;m++)(c!=null?n[m].seq==c:h&&n[m].name==h)&&(f=m);if(f<0){let m=0;for(;m<n.length&&(c==null||n[m].seq!=null&&n[m].seq<c);)m++;n.splice(m,0,{seq:c,name:h}),f=m;for(let g of i)g.field>=f&&g.field++}for(let m of i)if(m.line==r.length&&m.from>a.index){let g=a[2]?3+(a[1]||"").length:2;m.from-=g,m.to-=g}i.push(new CF(f,r.length,a.index,a.index+h.length)),o=o.slice(0,a.index)+u+o.slice(a.index+a[0].length)}o=o.replace(/\\([{}])/g,(c,u,f)=>{for(let h of i)h.line==r.length&&h.from>f&&(h.from--,h.to--);return u}),r.push(o)}return new d1(r,i)}}let TF=dt.widget({widget:new class extends el{toDOM(){let t=document.createElement("span");return t.className="cm-snippetFieldPosition",t}ignoreEvent(){return!1}}}),EF=dt.mark({class:"cm-snippetField"});class Uc{constructor(e,n){this.ranges=e,this.active=n,this.deco=dt.set(e.map(r=>(r.from==r.to?TF:EF).range(r.from,r.to)),!0)}map(e){let n=[];for(let r of this.ranges){let i=r.map(e);if(!i)return null;n.push(i)}return new Uc(n,this.active)}selectionInsideField(e){return e.ranges.every(n=>this.ranges.some(r=>r.field==this.active&&r.from<=n.from&&r.to>=n.to))}}const cf=Vt.define({map(t,e){return t&&t.map(e)}}),QF=Vt.define(),Pd=Mi.define({create(){return null},update(t,e){for(let n of e.effects){if(n.is(cf))return n.value;if(n.is(QF)&&t)return new Uc(t.ranges,n.value)}return t&&e.docChanged&&(t=t.map(e.changes)),t&&e.selection&&!t.selectionInsideField(e.selection)&&(t=null),t},provide:t=>qe.decorations.from(t,e=>e?e.deco:dt.none)});function f1(t,e){return Se.create(t.filter(n=>n.field==e).map(n=>Se.range(n.from,n.to)))}function AF(t){let e=d1.parse(t);return(n,r,i,a)=>{let{text:o,ranges:c}=e.instantiate(n.state,i),{main:u}=n.state.selection,f={changes:{from:i,to:a==u.from?u.to:a,insert:St.of(o)},scrollIntoView:!0,annotations:r?[wF.of(r),xn.userEvent.of("input.complete")]:void 0};if(c.length&&(f.selection=f1(c,0)),c.some(h=>h.field>0)){let h=new Uc(c,0),m=f.effects=[cf.of(h)];n.state.field(Pd,!1)===void 0&&m.push(Vt.appendConfig.of([Pd,jF,MF,kF]))}n.dispatch(n.state.update(f))}}function Cj(t){return({state:e,dispatch:n})=>{let r=e.field(Pd,!1);if(!r||t<0&&r.active==0)return!1;let i=r.active+t,a=t>0&&!r.ranges.some(o=>o.field==i+t);return n(e.update({selection:f1(r.ranges,i),effects:cf.of(a?null:new Uc(r.ranges,i)),scrollIntoView:!0})),!0}}const RF=({state:t,dispatch:e})=>t.field(Pd,!1)?(e(t.update({effects:cf.of(null)})),!0):!1,_F=Cj(1),$F=Cj(-1),PF=[{key:"Tab",run:_F,shift:$F},{key:"Escape",run:RF}],RE=Xe.define({combine(t){return t.length?t[0]:PF}}),jF=Km.highest(Ad.compute([RE],t=>t.facet(RE)));function xr(t,e){return{...e,apply:AF(t)}}const MF=qe.domEventHandlers({mousedown(t,e){let n=e.state.field(Pd,!1),r;if(!n||(r=e.posAtCoords({x:t.clientX,y:t.clientY}))==null)return!1;let i=n.ranges.find(a=>a.from<=r&&a.to>=r);return!i||i.field==n.active?!1:(e.dispatch({selection:f1(n.ranges,i.field),effects:cf.of(n.ranges.some(a=>a.field>i.field)?new Uc(n.ranges,i.field):null),scrollIntoView:!0}),!0)}}),jd={brackets:["(","[","{","'",'"'],before:")]}:;>",stringPrefixes:[]},_o=Vt.define({map(t,e){let n=e.mapPos(t,-1,Hn.TrackAfter);return n??void 0}}),h1=new class extends Bs{};h1.startSide=1;h1.endSide=-1;const Tj=Mi.define({create(){return xt.empty},update(t,e){if(t=t.map(e.changes),e.selection){let n=e.state.doc.lineAt(e.selection.main.head);t=t.update({filter:r=>r>=n.from&&r<=n.to})}for(let n of e.effects)n.is(_o)&&(t=t.update({add:[h1.range(n.value,n.value+1)]}));return t}});function NF(){return[zF,Tj]}const _y="()[]{}<>«»»«[]{}";function Ej(t){for(let e=0;e<_y.length;e+=2)if(_y.charCodeAt(e)==t)return _y.charAt(e+1);return G9(t<128?t:t+1)}function Qj(t,e){return t.languageDataAt("closeBrackets",e)[0]||jd}const DF=typeof navigator=="object"&&/Android\b/.test(navigator.userAgent),zF=qe.inputHandler.of((t,e,n,r)=>{if((DF?t.composing:t.compositionStarted)||t.state.readOnly)return!1;let i=t.state.selection.main;if(r.length>2||r.length==2&&Hm(Jo(r,0))==1||e!=i.from||n!=i.to)return!1;let a=VF(t.state,r);return a?(t.dispatch(a),!0):!1}),LF=({state:t,dispatch:e})=>{if(t.readOnly)return!1;let r=Qj(t,t.selection.main.head).brackets||jd.brackets,i=null,a=t.changeByRange(o=>{if(o.empty){let c=XF(t.doc,o.head);for(let u of r)if(u==c&&ug(t.doc,o.head)==Ej(Jo(u,0)))return{changes:{from:o.head-u.length,to:o.head+u.length},range:Se.cursor(o.head-u.length)}}return{range:i=o}});return i||e(t.update(a,{scrollIntoView:!0,userEvent:"delete.backward"})),!i},ZF=[{key:"Backspace",run:LF}];function VF(t,e){let n=Qj(t,t.selection.main.head),r=n.brackets||jd.brackets;for(let i of r){let a=Ej(Jo(i,0));if(e==i)return a==i?qF(t,i,r.indexOf(i+i+i)>-1,n):BF(t,i,a,n.before||jd.before);if(e==a&&Aj(t,t.selection.main.from))return IF(t,i,a)}return null}function Aj(t,e){let n=!1;return t.field(Tj).between(0,t.doc.length,r=>{r==e&&(n=!0)}),n}function ug(t,e){let n=t.sliceString(e,e+2);return n.slice(0,Hm(Jo(n,0)))}function XF(t,e){let n=t.sliceString(e-2,e);return Hm(Jo(n,0))==n.length?n:n.slice(1)}function BF(t,e,n,r){let i=null,a=t.changeByRange(o=>{if(!o.empty)return{changes:[{insert:e,from:o.from},{insert:n,from:o.to}],effects:_o.of(o.to+e.length),range:Se.range(o.anchor+e.length,o.head+e.length)};let c=ug(t.doc,o.head);return!c||/\s/.test(c)||r.indexOf(c)>-1?{changes:{insert:e+n,from:o.head},effects:_o.of(o.head+e.length),range:Se.cursor(o.head+e.length)}:{range:i=o}});return i?null:t.update(a,{scrollIntoView:!0,userEvent:"input.type"})}function IF(t,e,n){let r=null,i=t.changeByRange(a=>a.empty&&ug(t.doc,a.head)==n?{changes:{from:a.head,to:a.head+n.length,insert:n},range:Se.cursor(a.head+n.length)}:r={range:a});return r?null:t.update(i,{scrollIntoView:!0,userEvent:"input.type"})}function qF(t,e,n,r){let i=r.stringPrefixes||jd.stringPrefixes,a=null,o=t.changeByRange(c=>{if(!c.empty)return{changes:[{insert:e,from:c.from},{insert:e,from:c.to}],effects:_o.of(c.to+e.length),range:Se.range(c.anchor+e.length,c.head+e.length)};let u=c.head,f=ug(t.doc,u),h;if(f==e){if(_E(t,u))return{changes:{insert:e+e,from:u},effects:_o.of(u+e.length),range:Se.cursor(u+e.length)};if(Aj(t,u)){let g=n&&t.sliceDoc(u,u+e.length*3)==e+e+e?e+e+e:e;return{changes:{from:u,to:u+g.length,insert:g},range:Se.cursor(u+g.length)}}}else{if(n&&t.sliceDoc(u-2*e.length,u)==e+e&&(h=$E(t,u-2*e.length,i))>-1&&_E(t,h))return{changes:{insert:e+e+e+e,from:u},effects:_o.of(u+e.length),range:Se.cursor(u+e.length)};if(t.charCategorizer(u)(f)!=ii.Word&&$E(t,u,i)>-1&&!UF(t,u,e,i))return{changes:{insert:e+e,from:u},effects:_o.of(u+e.length),range:Se.cursor(u+e.length)}}return{range:a=c}});return a?null:t.update(o,{scrollIntoView:!0,userEvent:"input.type"})}function _E(t,e){let n=Mn(t).resolveInner(e+1);return n.parent&&n.from==e}function UF(t,e,n,r){let i=Mn(t).resolveInner(e,-1),a=r.reduce((o,c)=>Math.max(o,c.length),0);for(let o=0;o<5;o++){let c=t.sliceDoc(i.from,Math.min(i.to,i.from+n.length+a)),u=c.indexOf(n);if(!u||u>-1&&r.indexOf(c.slice(0,u))>-1){let h=i.firstChild;for(;h&&h.from==i.from&&h.to-h.from>n.length+u;){if(t.sliceDoc(h.to-n.length,h.to)==n)return!1;h=h.firstChild}return!0}let f=i.to==e&&i.parent;if(!f)break;i=f}return!1}function $E(t,e,n){let r=t.charCategorizer(e);if(r(t.sliceDoc(e-1,e))!=ii.Word)return e;for(let i of n){let a=e-i.length;if(t.sliceDoc(a,e)==i&&r(t.sliceDoc(a-1,a))!=ii.Word)return a}return-1}const YF=t=>{let{state:e}=t,n=e.doc.lineAt(e.selection.main.from),r=m1(t.state,n.from);return r.line?FF(t):r.block?GF(t):!1};function p1(t,e){return({state:n,dispatch:r})=>{if(n.readOnly)return!1;let i=t(e,n);return i?(r(n.update(i)),!0):!1}}const FF=p1(JF,0),WF=p1(Rj,0),GF=p1((t,e)=>Rj(t,e,KF(e)),0);function m1(t,e){let n=t.languageDataAt("commentTokens",e,1);return n.length?n[0]:{}}const Fu=50;function HF(t,{open:e,close:n},r,i){let a=t.sliceDoc(r-Fu,r),o=t.sliceDoc(i,i+Fu),c=/\s*$/.exec(a)[0].length,u=/^\s*/.exec(o)[0].length,f=a.length-c;if(a.slice(f-e.length,f)==e&&o.slice(u,u+n.length)==n)return{open:{pos:r-c,margin:c&&1},close:{pos:i+u,margin:u&&1}};let h,m;i-r<=2*Fu?h=m=t.sliceDoc(r,i):(h=t.sliceDoc(r,r+Fu),m=t.sliceDoc(i-Fu,i));let g=/^\s*/.exec(h)[0].length,y=/\s*$/.exec(m)[0].length,x=m.length-y-n.length;return h.slice(g,g+e.length)==e&&m.slice(x,x+n.length)==n?{open:{pos:r+g+e.length,margin:/\s/.test(h.charAt(g+e.length))?1:0},close:{pos:i-y-n.length,margin:/\s/.test(m.charAt(x-1))?1:0}}:null}function KF(t){let e=[];for(let n of t.selection.ranges){let r=t.doc.lineAt(n.from),i=n.to<=r.to?r:t.doc.lineAt(n.to);i.from>r.from&&i.from==n.to&&(i=n.to==r.to+1?r:t.doc.lineAt(n.to-1));let a=e.length-1;a>=0&&e[a].to>r.from?e[a].to=i.to:e.push({from:r.from+/^\s*/.exec(r.text)[0].length,to:i.to})}return e}function Rj(t,e,n=e.selection.ranges){let r=n.map(a=>m1(e,a.from).block);if(!r.every(a=>a))return null;let i=n.map((a,o)=>HF(e,r[o],a.from,a.to));if(t!=2&&!i.every(a=>a))return{changes:e.changes(n.map((a,o)=>i[o]?[]:[{from:a.from,insert:r[o].open+" "},{from:a.to,insert:" "+r[o].close}]))};if(t!=1&&i.some(a=>a)){let a=[];for(let o=0,c;o<i.length;o++)if(c=i[o]){let u=r[o],{open:f,close:h}=c;a.push({from:f.pos-u.open.length,to:f.pos+f.margin},{from:h.pos-h.margin,to:h.pos+u.close.length})}return{changes:a}}return null}function JF(t,e,n=e.selection.ranges){let r=[],i=-1;for(let{from:a,to:o}of n){let c=r.length,u=1e9,f=m1(e,a).line;if(f){for(let h=a;h<=o;){let m=e.doc.lineAt(h);if(m.from>i&&(a==o||o>m.from)){i=m.from;let g=/^\s*/.exec(m.text)[0].length,y=g==m.length,x=m.text.slice(g,g+f.length)==f?g:-1;g<m.text.length&&g<u&&(u=g),r.push({line:m,comment:x,token:f,indent:g,empty:y,single:!1})}h=m.to+1}if(u<1e9)for(let h=c;h<r.length;h++)r[h].indent<r[h].line.text.length&&(r[h].indent=u);r.length==c+1&&(r[c].single=!0)}}if(t!=2&&r.some(a=>a.comment<0&&(!a.empty||a.single))){let a=[];for(let{line:c,token:u,indent:f,empty:h,single:m}of r)(m||!h)&&a.push({from:c.from+f,insert:u+" "});let o=e.changes(a);return{changes:o,selection:e.selection.map(o,1)}}else if(t!=1&&r.some(a=>a.comment>=0)){let a=[];for(let{line:o,comment:c,token:u}of r)if(c>=0){let f=o.from+c,h=f+u.length;o.text[h-o.from]==" "&&h++,a.push({from:f,to:h})}return{changes:a}}return null}const yb=Ri.define(),eW=Ri.define(),tW=Xe.define(),_j=Xe.define({combine(t){return eg(t,{minDepth:100,newGroupDelay:500,joinToEvent:(e,n)=>n},{minDepth:Math.max,newGroupDelay:Math.min,joinToEvent:(e,n)=>(r,i)=>e(r,i)||n(r,i)})}}),$j=Mi.define({create(){return la.empty},update(t,e){let n=e.state.facet(_j),r=e.annotation(yb);if(r){let u=Tr.fromTransaction(e,r.selection),f=r.side,h=f==0?t.undone:t.done;return u?h=im(h,h.length,n.minDepth,u):h=Mj(h,e.startState.selection),new la(f==0?r.rest:h,f==0?h:r.rest)}let i=e.annotation(eW);if((i=="full"||i=="before")&&(t=t.isolate()),e.annotation(xn.addToHistory)===!1)return e.changes.empty?t:t.addMapping(e.changes.desc);let a=Tr.fromTransaction(e),o=e.annotation(xn.time),c=e.annotation(xn.userEvent);return a?t=t.addChanges(a,o,c,n,e):e.selection&&(t=t.addSelection(e.startState.selection,o,c,n.newGroupDelay)),(i=="full"||i=="after")&&(t=t.isolate()),t},toJSON(t){return{done:t.done.map(e=>e.toJSON()),undone:t.undone.map(e=>e.toJSON())}},fromJSON(t){return new la(t.done.map(Tr.fromJSON),t.undone.map(Tr.fromJSON))}});function nW(t={}){return[$j,_j.of(t),qe.domEventHandlers({beforeinput(e,n){let r=e.inputType=="historyUndo"?Pj:e.inputType=="historyRedo"?bb:null;return r?(e.preventDefault(),r(n)):!1}})]}function dg(t,e){return function({state:n,dispatch:r}){if(!e&&n.readOnly)return!1;let i=n.field($j,!1);if(!i)return!1;let a=i.pop(t,n,e);return a?(r(a),!0):!1}}const Pj=dg(0,!1),bb=dg(1,!1),rW=dg(0,!0),iW=dg(1,!0);class Tr{constructor(e,n,r,i,a){this.changes=e,this.effects=n,this.mapped=r,this.startSelection=i,this.selectionsAfter=a}setSelAfter(e){return new Tr(this.changes,this.effects,this.mapped,this.startSelection,e)}toJSON(){var e,n,r;return{changes:(e=this.changes)===null||e===void 0?void 0:e.toJSON(),mapped:(n=this.mapped)===null||n===void 0?void 0:n.toJSON(),startSelection:(r=this.startSelection)===null||r===void 0?void 0:r.toJSON(),selectionsAfter:this.selectionsAfter.map(i=>i.toJSON())}}static fromJSON(e){return new Tr(e.changes&&Qn.fromJSON(e.changes),[],e.mapped&&ua.fromJSON(e.mapped),e.startSelection&&Se.fromJSON(e.startSelection),e.selectionsAfter.map(Se.fromJSON))}static fromTransaction(e,n){let r=oi;for(let i of e.startState.facet(tW)){let a=i(e);a.length&&(r=r.concat(a))}return!r.length&&e.changes.empty?null:new Tr(e.changes.invert(e.startState.doc),r,void 0,n||e.startState.selection,oi)}static selection(e){return new Tr(void 0,oi,void 0,void 0,e)}}function im(t,e,n,r){let i=e+1>n+20?e-n-1:0,a=t.slice(i,e);return a.push(r),a}function aW(t,e){let n=[],r=!1;return t.iterChangedRanges((i,a)=>n.push(i,a)),e.iterChangedRanges((i,a,o,c)=>{for(let u=0;u<n.length;){let f=n[u++],h=n[u++];c>=f&&o<=h&&(r=!0)}}),r}function sW(t,e){return t.ranges.length==e.ranges.length&&t.ranges.filter((n,r)=>n.empty!=e.ranges[r].empty).length===0}function jj(t,e){return t.length?e.length?t.concat(e):t:e}const oi=[],oW=200;function Mj(t,e){if(t.length){let n=t[t.length-1],r=n.selectionsAfter.slice(Math.max(0,n.selectionsAfter.length-oW));return r.length&&r[r.length-1].eq(e)?t:(r.push(e),im(t,t.length-1,1e9,n.setSelAfter(r)))}else return[Tr.selection([e])]}function lW(t){let e=t[t.length-1],n=t.slice();return n[t.length-1]=e.setSelAfter(e.selectionsAfter.slice(0,e.selectionsAfter.length-1)),n}function $y(t,e){if(!t.length)return t;let n=t.length,r=oi;for(;n;){let i=cW(t[n-1],e,r);if(i.changes&&!i.changes.empty||i.effects.length){let a=t.slice(0,n);return a[n-1]=i,a}else e=i.mapped,n--,r=i.selectionsAfter}return r.length?[Tr.selection(r)]:oi}function cW(t,e,n){let r=jj(t.selectionsAfter.length?t.selectionsAfter.map(c=>c.map(e)):oi,n);if(!t.changes)return Tr.selection(r);let i=t.changes.map(e),a=e.mapDesc(t.changes,!0),o=t.mapped?t.mapped.composeDesc(a):a;return new Tr(i,Vt.mapEffects(t.effects,e),o,t.startSelection.map(a),r)}const uW=/^(input\.type|delete)($|\.)/;class la{constructor(e,n,r=0,i=void 0){this.done=e,this.undone=n,this.prevTime=r,this.prevUserEvent=i}isolate(){return this.prevTime?new la(this.done,this.undone):this}addChanges(e,n,r,i,a){let o=this.done,c=o[o.length-1];return c&&c.changes&&!c.changes.empty&&e.changes&&(!r||uW.test(r))&&(!c.selectionsAfter.length&&n-this.prevTime<i.newGroupDelay&&i.joinToEvent(a,aW(c.changes,e.changes))||r=="input.type.compose")?o=im(o,o.length-1,i.minDepth,new Tr(e.changes.compose(c.changes),jj(Vt.mapEffects(e.effects,c.changes),c.effects),c.mapped,c.startSelection,oi)):o=im(o,o.length,i.minDepth,e),new la(o,oi,n,r)}addSelection(e,n,r,i){let a=this.done.length?this.done[this.done.length-1].selectionsAfter:oi;return a.length>0&&n-this.prevTime<i&&r==this.prevUserEvent&&r&&/^select($|\.)/.test(r)&&sW(a[a.length-1],e)?this:new la(Mj(this.done,e),this.undone,n,r)}addMapping(e){return new la($y(this.done,e),$y(this.undone,e),this.prevTime,this.prevUserEvent)}pop(e,n,r){let i=e==0?this.done:this.undone;if(i.length==0)return null;let a=i[i.length-1],o=a.selectionsAfter[0]||n.selection;if(r&&a.selectionsAfter.length)return n.update({selection:a.selectionsAfter[a.selectionsAfter.length-1],annotations:yb.of({side:e,rest:lW(i),selection:o}),userEvent:e==0?"select.undo":"select.redo",scrollIntoView:!0});if(a.changes){let c=i.length==1?oi:i.slice(0,i.length-1);return a.mapped&&(c=$y(c,a.mapped)),n.update({changes:a.changes,selection:a.startSelection,effects:a.effects,annotations:yb.of({side:e,rest:c,selection:o}),filter:!1,userEvent:e==0?"undo":"redo",scrollIntoView:!0})}else return null}}la.empty=new la(oi,oi);const dW=[{key:"Mod-z",run:Pj,preventDefault:!0},{key:"Mod-y",mac:"Mod-Shift-z",run:bb,preventDefault:!0},{linux:"Ctrl-Shift-z",run:bb,preventDefault:!0},{key:"Mod-u",run:rW,preventDefault:!0},{key:"Alt-u",mac:"Mod-Shift-u",run:iW,preventDefault:!0}];function Yc(t,e){return Se.create(t.ranges.map(e),t.mainIndex)}function Ni(t,e){return t.update({selection:e,scrollIntoView:!0,userEvent:"select"})}function Di({state:t,dispatch:e},n){let r=Yc(t.selection,n);return r.eq(t.selection,!0)?!1:(e(Ni(t,r)),!0)}function fg(t,e){return Se.cursor(e?t.to:t.from)}function Nj(t,e){return Di(t,n=>n.empty?t.moveByChar(n,e):fg(n,e))}function Jn(t){return t.textDirectionAt(t.state.selection.main.head)==dn.LTR}const Dj=t=>Nj(t,!Jn(t)),zj=t=>Nj(t,Jn(t));function Lj(t,e){return Di(t,n=>n.empty?t.moveByGroup(n,e):fg(n,e))}const fW=t=>Lj(t,!Jn(t)),hW=t=>Lj(t,Jn(t));function pW(t,e,n){if(e.type.prop(n))return!0;let r=e.to-e.from;return r&&(r>2||/[^\s,.;:]/.test(t.sliceDoc(e.from,e.to)))||e.firstChild}function hg(t,e,n){let r=Mn(t).resolveInner(e.head),i=n?ct.closedBy:ct.openedBy;for(let u=e.head;;){let f=n?r.childAfter(u):r.childBefore(u);if(!f)break;pW(t,f,i)?r=f:u=n?f.to:f.from}let a=r.type.prop(i),o,c;return a&&(o=n?oa(t,r.from,1):oa(t,r.to,-1))&&o.matched?c=n?o.end.to:o.end.from:c=n?r.to:r.from,Se.cursor(c,n?-1:1)}const mW=t=>Di(t,e=>hg(t.state,e,!Jn(t))),gW=t=>Di(t,e=>hg(t.state,e,Jn(t)));function Zj(t,e){return Di(t,n=>{if(!n.empty)return fg(n,e);let r=t.moveVertically(n,e);return r.head!=n.head?r:t.moveToLineBoundary(n,e)})}const Vj=t=>Zj(t,!1),Xj=t=>Zj(t,!0);function Bj(t){let e=t.scrollDOM.clientHeight<t.scrollDOM.scrollHeight-2,n=0,r=0,i;if(e){for(let a of t.state.facet(qe.scrollMargins)){let o=a(t);o?.top&&(n=Math.max(o?.top,n)),o?.bottom&&(r=Math.max(o?.bottom,r))}i=t.scrollDOM.clientHeight-n-r}else i=(t.dom.ownerDocument.defaultView||window).innerHeight;return{marginTop:n,marginBottom:r,selfScroll:e,height:Math.max(t.defaultLineHeight,i-5)}}function Ij(t,e){let n=Bj(t),{state:r}=t,i=Yc(r.selection,o=>o.empty?t.moveVertically(o,e,n.height):fg(o,e));if(i.eq(r.selection))return!1;let a;if(n.selfScroll){let o=t.coordsAtPos(r.selection.main.head),c=t.scrollDOM.getBoundingClientRect(),u=c.top+n.marginTop,f=c.bottom-n.marginBottom;o&&o.top>u&&o.bottom<f&&(a=qe.scrollIntoView(i.main.head,{y:"start",yMargin:o.top-u}))}return t.dispatch(Ni(r,i),{effects:a}),!0}const PE=t=>Ij(t,!1),xb=t=>Ij(t,!0);function Js(t,e,n){let r=t.lineBlockAt(e.head),i=t.moveToLineBoundary(e,n);if(i.head==e.head&&i.head!=(n?r.to:r.from)&&(i=t.moveToLineBoundary(e,n,!1)),!n&&i.head==r.from&&r.length){let a=/^\s*/.exec(t.state.sliceDoc(r.from,Math.min(r.from+100,r.to)))[0].length;a&&e.head!=r.from+a&&(i=Se.cursor(r.from+a))}return i}const OW=t=>Di(t,e=>Js(t,e,!0)),vW=t=>Di(t,e=>Js(t,e,!1)),yW=t=>Di(t,e=>Js(t,e,!Jn(t))),bW=t=>Di(t,e=>Js(t,e,Jn(t))),xW=t=>Di(t,e=>Se.cursor(t.lineBlockAt(e.head).from,1)),SW=t=>Di(t,e=>Se.cursor(t.lineBlockAt(e.head).to,-1));function wW(t,e,n){let r=!1,i=Yc(t.selection,a=>{let o=oa(t,a.head,-1)||oa(t,a.head,1)||a.head>0&&oa(t,a.head-1,1)||a.head<t.doc.length&&oa(t,a.head+1,-1);if(!o||!o.end)return a;r=!0;let c=o.start.from==a.head?o.end.to:o.end.from;return Se.cursor(c)});return r?(e(Ni(t,i)),!0):!1}const kW=({state:t,dispatch:e})=>wW(t,e);function hi(t,e){let n=Yc(t.state.selection,r=>{let i=e(r);return Se.range(r.anchor,i.head,i.goalColumn,i.bidiLevel||void 0)});return n.eq(t.state.selection)?!1:(t.dispatch(Ni(t.state,n)),!0)}function qj(t,e){return hi(t,n=>t.moveByChar(n,e))}const Uj=t=>qj(t,!Jn(t)),Yj=t=>qj(t,Jn(t));function Fj(t,e){return hi(t,n=>t.moveByGroup(n,e))}const CW=t=>Fj(t,!Jn(t)),TW=t=>Fj(t,Jn(t)),EW=t=>hi(t,e=>hg(t.state,e,!Jn(t))),QW=t=>hi(t,e=>hg(t.state,e,Jn(t)));function Wj(t,e){return hi(t,n=>t.moveVertically(n,e))}const Gj=t=>Wj(t,!1),Hj=t=>Wj(t,!0);function Kj(t,e){return hi(t,n=>t.moveVertically(n,e,Bj(t).height))}const jE=t=>Kj(t,!1),ME=t=>Kj(t,!0),AW=t=>hi(t,e=>Js(t,e,!0)),RW=t=>hi(t,e=>Js(t,e,!1)),_W=t=>hi(t,e=>Js(t,e,!Jn(t))),$W=t=>hi(t,e=>Js(t,e,Jn(t))),PW=t=>hi(t,e=>Se.cursor(t.lineBlockAt(e.head).from)),jW=t=>hi(t,e=>Se.cursor(t.lineBlockAt(e.head).to)),NE=({state:t,dispatch:e})=>(e(Ni(t,{anchor:0})),!0),DE=({state:t,dispatch:e})=>(e(Ni(t,{anchor:t.doc.length})),!0),zE=({state:t,dispatch:e})=>(e(Ni(t,{anchor:t.selection.main.anchor,head:0})),!0),LE=({state:t,dispatch:e})=>(e(Ni(t,{anchor:t.selection.main.anchor,head:t.doc.length})),!0),MW=({state:t,dispatch:e})=>(e(t.update({selection:{anchor:0,head:t.doc.length},userEvent:"select"})),!0),NW=({state:t,dispatch:e})=>{let n=pg(t).map(({from:r,to:i})=>Se.range(r,Math.min(i+1,t.doc.length)));return e(t.update({selection:Se.create(n),userEvent:"select"})),!0},DW=({state:t,dispatch:e})=>{let n=Yc(t.selection,r=>{let i=Mn(t),a=i.resolveStack(r.from,1);if(r.empty){let o=i.resolveStack(r.from,-1);o.node.from>=a.node.from&&o.node.to<=a.node.to&&(a=o)}for(let o=a;o;o=o.next){let{node:c}=o;if((c.from<r.from&&c.to>=r.to||c.to>r.to&&c.from<=r.from)&&o.next)return Se.range(c.to,c.from)}return r});return n.eq(t.selection)?!1:(e(Ni(t,n)),!0)};function Jj(t,e){let{state:n}=t,r=n.selection,i=n.selection.ranges.slice();for(let a of n.selection.ranges){let o=n.doc.lineAt(a.head);if(e?o.to<t.state.doc.length:o.from>0)for(let c=a;;){let u=t.moveVertically(c,e);if(u.head<o.from||u.head>o.to){i.some(f=>f.head==u.head)||i.push(u);break}else{if(u.head==c.head)break;c=u}}}return i.length==r.ranges.length?!1:(t.dispatch(Ni(n,Se.create(i,i.length-1))),!0)}const zW=t=>Jj(t,!1),LW=t=>Jj(t,!0),ZW=({state:t,dispatch:e})=>{let n=t.selection,r=null;return n.ranges.length>1?r=Se.create([n.main]):n.main.empty||(r=Se.create([Se.cursor(n.main.head)])),r?(e(Ni(t,r)),!0):!1};function uf(t,e){if(t.state.readOnly)return!1;let n="delete.selection",{state:r}=t,i=r.changeByRange(a=>{let{from:o,to:c}=a;if(o==c){let u=e(a);u<o?(n="delete.backward",u=Jh(t,u,!1)):u>o&&(n="delete.forward",u=Jh(t,u,!0)),o=Math.min(o,u),c=Math.max(c,u)}else o=Jh(t,o,!1),c=Jh(t,c,!0);return o==c?{range:a}:{changes:{from:o,to:c},range:Se.cursor(o,o<a.head?-1:1)}});return i.changes.empty?!1:(t.dispatch(r.update(i,{scrollIntoView:!0,userEvent:n,effects:n=="delete.selection"?qe.announce.of(r.phrase("Selection deleted")):void 0})),!0)}function Jh(t,e,n){if(t instanceof qe)for(let r of t.state.facet(qe.atomicRanges).map(i=>i(t)))r.between(e,e,(i,a)=>{i<e&&a>e&&(e=n?a:i)});return e}const e5=(t,e,n)=>uf(t,r=>{let i=r.from,{state:a}=t,o=a.doc.lineAt(i),c,u;if(n&&!e&&i>o.from&&i<o.from+200&&!/[^ \t]/.test(c=o.text.slice(0,i-o.from))){if(c[c.length-1]==" ")return i-1;let f=af(c,a.tabSize),h=f%nm(a)||nm(a);for(let m=0;m<h&&c[c.length-1-m]==" ";m++)i--;u=i}else u=qn(o.text,i-o.from,e,e)+o.from,u==i&&o.number!=(e?a.doc.lines:1)?u+=e?1:-1:!e&&/[\ufe00-\ufe0f]/.test(o.text.slice(u-o.from,i-o.from))&&(u=qn(o.text,u-o.from,!1,!1)+o.from);return u}),Sb=t=>e5(t,!1,!0),t5=t=>e5(t,!0,!1),n5=(t,e)=>uf(t,n=>{let r=n.head,{state:i}=t,a=i.doc.lineAt(r),o=i.charCategorizer(r);for(let c=null;;){if(r==(e?a.to:a.from)){r==n.head&&a.number!=(e?i.doc.lines:1)&&(r+=e?1:-1);break}let u=qn(a.text,r-a.from,e)+a.from,f=a.text.slice(Math.min(r,u)-a.from,Math.max(r,u)-a.from),h=o(f);if(c!=null&&h!=c)break;(f!=" "||r!=n.head)&&(c=h),r=u}return r}),g1=t=>n5(t,!1),VW=t=>n5(t,!0),XW=t=>uf(t,e=>{let n=t.lineBlockAt(e.head).to;return e.head<n?n:Math.min(t.state.doc.length,e.head+1)}),BW=t=>uf(t,e=>{let n=t.moveToLineBoundary(e,!1).head;return e.head>n?n:Math.max(0,e.head-1)}),IW=t=>uf(t,e=>{let n=t.moveToLineBoundary(e,!0).head;return e.head<n?n:Math.min(t.state.doc.length,e.head+1)}),qW=({state:t,dispatch:e})=>{if(t.readOnly)return!1;let n=t.changeByRange(r=>({changes:{from:r.from,to:r.to,insert:St.of(["",""])},range:Se.cursor(r.from)}));return e(t.update(n,{scrollIntoView:!0,userEvent:"input"})),!0},UW=({state:t,dispatch:e})=>{if(t.readOnly)return!1;let n=t.changeByRange(r=>{if(!r.empty||r.from==0||r.from==t.doc.length)return{range:r};let i=r.from,a=t.doc.lineAt(i),o=i==a.from?i-1:qn(a.text,i-a.from,!1)+a.from,c=i==a.to?i+1:qn(a.text,i-a.from,!0)+a.from;return{changes:{from:o,to:c,insert:t.doc.slice(i,c).append(t.doc.slice(o,i))},range:Se.cursor(c)}});return n.changes.empty?!1:(e(t.update(n,{scrollIntoView:!0,userEvent:"move.character"})),!0)};function pg(t){let e=[],n=-1;for(let r of t.selection.ranges){let i=t.doc.lineAt(r.from),a=t.doc.lineAt(r.to);if(!r.empty&&r.to==a.from&&(a=t.doc.lineAt(r.to-1)),n>=i.number){let o=e[e.length-1];o.to=a.to,o.ranges.push(r)}else e.push({from:i.from,to:a.to,ranges:[r]});n=a.number+1}return e}function r5(t,e,n){if(t.readOnly)return!1;let r=[],i=[];for(let a of pg(t)){if(n?a.to==t.doc.length:a.from==0)continue;let o=t.doc.lineAt(n?a.to+1:a.from-1),c=o.length+1;if(n){r.push({from:a.to,to:o.to},{from:a.from,insert:o.text+t.lineBreak});for(let u of a.ranges)i.push(Se.range(Math.min(t.doc.length,u.anchor+c),Math.min(t.doc.length,u.head+c)))}else{r.push({from:o.from,to:a.from},{from:a.to,insert:t.lineBreak+o.text});for(let u of a.ranges)i.push(Se.range(u.anchor-c,u.head-c))}}return r.length?(e(t.update({changes:r,scrollIntoView:!0,selection:Se.create(i,t.selection.mainIndex),userEvent:"move.line"})),!0):!1}const YW=({state:t,dispatch:e})=>r5(t,e,!1),FW=({state:t,dispatch:e})=>r5(t,e,!0);function i5(t,e,n){if(t.readOnly)return!1;let r=[];for(let a of pg(t))n?r.push({from:a.from,insert:t.doc.slice(a.from,a.to)+t.lineBreak}):r.push({from:a.to,insert:t.lineBreak+t.doc.slice(a.from,a.to)});let i=t.changes(r);return e(t.update({changes:i,selection:t.selection.map(i,n?1:-1),scrollIntoView:!0,userEvent:"input.copyline"})),!0}const WW=({state:t,dispatch:e})=>i5(t,e,!1),GW=({state:t,dispatch:e})=>i5(t,e,!0),HW=t=>{if(t.state.readOnly)return!1;let{state:e}=t,n=e.changes(pg(e).map(({from:i,to:a})=>(i>0?i--:a<e.doc.length&&a++,{from:i,to:a}))),r=Yc(e.selection,i=>{let a;if(t.lineWrapping){let o=t.lineBlockAt(i.head),c=t.coordsAtPos(i.head,i.assoc||1);c&&(a=o.bottom+t.documentTop-c.bottom+t.defaultLineHeight/2)}return t.moveVertically(i,!0,a)}).map(n);return t.dispatch({changes:n,selection:r,scrollIntoView:!0,userEvent:"delete.line"}),!0};function KW(t,e){if(/\(\)|\[\]|\{\}/.test(t.sliceDoc(e-1,e+1)))return{from:e,to:e};let n=Mn(t).resolveInner(e),r=n.childBefore(e),i=n.childAfter(e),a;return r&&i&&r.to<=e&&i.from>=e&&(a=r.type.prop(ct.closedBy))&&a.indexOf(i.name)>-1&&t.doc.lineAt(r.to).from==t.doc.lineAt(i.from).from&&!/\S/.test(t.sliceDoc(r.to,i.from))?{from:r.to,to:i.from}:null}const ZE=a5(!1),JW=a5(!0);function a5(t){return({state:e,dispatch:n})=>{if(e.readOnly)return!1;let r=e.changeByRange(i=>{let{from:a,to:o}=i,c=e.doc.lineAt(a),u=!t&&a==o&&KW(e,a);t&&(a=o=(o<=c.to?c:e.doc.lineAt(o)).to);let f=new og(e,{simulateBreak:a,simulateDoubleBreak:!!u}),h=Oj(f,a);for(h==null&&(h=af(/^\s*/.exec(e.doc.lineAt(a).text)[0],e.tabSize));o<c.to&&/\s/.test(c.text[o-c.from]);)o++;u?{from:a,to:o}=u:a>c.from&&a<c.from+100&&!/\S/.test(c.text.slice(0,a))&&(a=c.from);let m=["",rm(e,h)];return u&&m.push(rm(e,f.lineIndent(c.from,-1))),{changes:{from:a,to:o,insert:St.of(m)},range:Se.cursor(a+1+m[1].length)}});return n(e.update(r,{scrollIntoView:!0,userEvent:"input"})),!0}}function O1(t,e){let n=-1;return t.changeByRange(r=>{let i=[];for(let o=r.from;o<=r.to;){let c=t.doc.lineAt(o);c.number>n&&(r.empty||r.to>c.from)&&(e(c,i,r),n=c.number),o=c.to+1}let a=t.changes(i);return{changes:i,range:Se.range(a.mapPos(r.anchor,1),a.mapPos(r.head,1))}})}const eG=({state:t,dispatch:e})=>{if(t.readOnly)return!1;let n=Object.create(null),r=new og(t,{overrideIndentation:a=>{let o=n[a];return o??-1}}),i=O1(t,(a,o,c)=>{let u=Oj(r,a.from);if(u==null)return;/\S/.test(a.text)||(u=0);let f=/^\s*/.exec(a.text)[0],h=rm(t,u);(f!=h||c.from<a.from+f.length)&&(n[a.from]=u,o.push({from:a.from,to:a.from+f.length,insert:h}))});return i.changes.empty||e(t.update(i,{userEvent:"indent"})),!0},s5=({state:t,dispatch:e})=>t.readOnly?!1:(e(t.update(O1(t,(n,r)=>{r.push({from:n.from,insert:t.facet(sg)})}),{userEvent:"input.indent"})),!0),o5=({state:t,dispatch:e})=>t.readOnly?!1:(e(t.update(O1(t,(n,r)=>{let i=/^\s*/.exec(n.text)[0];if(!i)return;let a=af(i,t.tabSize),o=0,c=rm(t,Math.max(0,a-nm(t)));for(;o<i.length&&o<c.length&&i.charCodeAt(o)==c.charCodeAt(o);)o++;r.push({from:n.from+o,to:n.from+i.length,insert:c.slice(o)})}),{userEvent:"delete.dedent"})),!0),tG=t=>(t.setTabFocusMode(),!0),nG=[{key:"Ctrl-b",run:Dj,shift:Uj,preventDefault:!0},{key:"Ctrl-f",run:zj,shift:Yj},{key:"Ctrl-p",run:Vj,shift:Gj},{key:"Ctrl-n",run:Xj,shift:Hj},{key:"Ctrl-a",run:xW,shift:PW},{key:"Ctrl-e",run:SW,shift:jW},{key:"Ctrl-d",run:t5},{key:"Ctrl-h",run:Sb},{key:"Ctrl-k",run:XW},{key:"Ctrl-Alt-h",run:g1},{key:"Ctrl-o",run:qW},{key:"Ctrl-t",run:UW},{key:"Ctrl-v",run:xb}],rG=[{key:"ArrowLeft",run:Dj,shift:Uj,preventDefault:!0},{key:"Mod-ArrowLeft",mac:"Alt-ArrowLeft",run:fW,shift:CW,preventDefault:!0},{mac:"Cmd-ArrowLeft",run:yW,shift:_W,preventDefault:!0},{key:"ArrowRight",run:zj,shift:Yj,preventDefault:!0},{key:"Mod-ArrowRight",mac:"Alt-ArrowRight",run:hW,shift:TW,preventDefault:!0},{mac:"Cmd-ArrowRight",run:bW,shift:$W,preventDefault:!0},{key:"ArrowUp",run:Vj,shift:Gj,preventDefault:!0},{mac:"Cmd-ArrowUp",run:NE,shift:zE},{mac:"Ctrl-ArrowUp",run:PE,shift:jE},{key:"ArrowDown",run:Xj,shift:Hj,preventDefault:!0},{mac:"Cmd-ArrowDown",run:DE,shift:LE},{mac:"Ctrl-ArrowDown",run:xb,shift:ME},{key:"PageUp",run:PE,shift:jE},{key:"PageDown",run:xb,shift:ME},{key:"Home",run:vW,shift:RW,preventDefault:!0},{key:"Mod-Home",run:NE,shift:zE},{key:"End",run:OW,shift:AW,preventDefault:!0},{key:"Mod-End",run:DE,shift:LE},{key:"Enter",run:ZE,shift:ZE},{key:"Mod-a",run:MW},{key:"Backspace",run:Sb,shift:Sb,preventDefault:!0},{key:"Delete",run:t5,preventDefault:!0},{key:"Mod-Backspace",mac:"Alt-Backspace",run:g1,preventDefault:!0},{key:"Mod-Delete",mac:"Alt-Delete",run:VW,preventDefault:!0},{mac:"Mod-Backspace",run:BW,preventDefault:!0},{mac:"Mod-Delete",run:IW,preventDefault:!0}].concat(nG.map(t=>({mac:t.key,run:t.run,shift:t.shift}))),iG=[{key:"Alt-ArrowLeft",mac:"Ctrl-ArrowLeft",run:mW,shift:EW},{key:"Alt-ArrowRight",mac:"Ctrl-ArrowRight",run:gW,shift:QW},{key:"Alt-ArrowUp",run:YW},{key:"Shift-Alt-ArrowUp",run:WW},{key:"Alt-ArrowDown",run:FW},{key:"Shift-Alt-ArrowDown",run:GW},{key:"Mod-Alt-ArrowUp",run:zW},{key:"Mod-Alt-ArrowDown",run:LW},{key:"Escape",run:ZW},{key:"Mod-Enter",run:JW},{key:"Alt-l",mac:"Ctrl-l",run:NW},{key:"Mod-i",run:DW,preventDefault:!0},{key:"Mod-[",run:o5},{key:"Mod-]",run:s5},{key:"Mod-Alt-\\",run:eG},{key:"Shift-Mod-k",run:HW},{key:"Shift-Mod-\\",run:kW},{key:"Mod-/",run:YF},{key:"Alt-A",run:WF},{key:"Ctrl-m",mac:"Shift-Alt-m",run:tG}].concat(rG);var VE={},XE;function aG(){return XE||(XE=1,(function(){if(typeof window!="object")return;if("IntersectionObserver"in window&&"IntersectionObserverEntry"in window&&"intersectionRatio"in window.IntersectionObserverEntry.prototype){"isIntersecting"in window.IntersectionObserverEntry.prototype||Object.defineProperty(window.IntersectionObserverEntry.prototype,"isIntersecting",{get:function(){return this.intersectionRatio>0}});return}var t=window.document,e=[],n=null,r=null;function i(C){this.time=C.time,this.target=C.target,this.rootBounds=y(C.rootBounds),this.boundingClientRect=y(C.boundingClientRect),this.intersectionRect=y(C.intersectionRect||g()),this.isIntersecting=!!C.intersectionRect;var E=this.boundingClientRect,R=E.width*E.height,$=this.intersectionRect,P=$.width*$.height;R?this.intersectionRatio=Number((P/R).toFixed(4)):this.intersectionRatio=this.isIntersecting?1:0}function a(C,E){var R=E||{};if(typeof C!="function")throw new Error("callback must be a function");if(R.root&&R.root.nodeType!=1)throw new Error("root must be an Element");this._checkForIntersections=c(this._checkForIntersections.bind(this),this.THROTTLE_TIMEOUT),this._callback=C,this._observationTargets=[],this._queuedEntries=[],this._rootMarginValues=this._parseRootMargin(R.rootMargin),this.thresholds=this._initThresholds(R.threshold),this.root=R.root||null,this.rootMargin=this._rootMarginValues.map(function($){return $.value+$.unit}).join(" "),this._monitoringDocuments=[],this._monitoringUnsubscribes=[]}a.prototype.THROTTLE_TIMEOUT=100,a.prototype.POLL_INTERVAL=null,a.prototype.USE_MUTATION_OBSERVER=!0,a._setupCrossOriginUpdater=function(){return n||(n=function(C,E){!C||!E?r=g():r=x(C,E),e.forEach(function(R){R._checkForIntersections()})}),n},a._resetCrossOriginUpdater=function(){n=null,r=null},a.prototype.observe=function(C){var E=this._observationTargets.some(function(R){return R.element==C});if(!E){if(!(C&&C.nodeType==1))throw new Error("target must be an Element");this._registerInstance(),this._observationTargets.push({element:C,entry:null}),this._monitorIntersections(C.ownerDocument),this._checkForIntersections()}},a.prototype.unobserve=function(C){this._observationTargets=this._observationTargets.filter(function(E){return E.element!=C}),this._unmonitorIntersections(C.ownerDocument),this._observationTargets.length==0&&this._unregisterInstance()},a.prototype.disconnect=function(){this._observationTargets=[],this._unmonitorAllIntersections(),this._unregisterInstance()},a.prototype.takeRecords=function(){var C=this._queuedEntries.slice();return this._queuedEntries=[],C},a.prototype._initThresholds=function(C){var E=C||[0];return Array.isArray(E)||(E=[E]),E.sort().filter(function(R,$,P){if(typeof R!="number"||isNaN(R)||R<0||R>1)throw new Error("threshold must be a number between 0 and 1 inclusively");return R!==P[$-1]})},a.prototype._parseRootMargin=function(C){var E=C||"0px",R=E.split(/\s+/).map(function($){var P=/^(-?\d*\.?\d+)(px|%)$/.exec($);if(!P)throw new Error("rootMargin must be specified in pixels or percent");return{value:parseFloat(P[1]),unit:P[2]}});return R[1]=R[1]||R[0],R[2]=R[2]||R[0],R[3]=R[3]||R[1],R},a.prototype._monitorIntersections=function(C){var E=C.defaultView;if(E&&this._monitoringDocuments.indexOf(C)==-1){var R=this._checkForIntersections,$=null,P=null;if(this.POLL_INTERVAL?$=E.setInterval(R,this.POLL_INTERVAL):(u(E,"resize",R,!0),u(C,"scroll",R,!0),this.USE_MUTATION_OBSERVER&&"MutationObserver"in E&&(P=new E.MutationObserver(R),P.observe(C,{attributes:!0,childList:!0,characterData:!0,subtree:!0}))),this._monitoringDocuments.push(C),this._monitoringUnsubscribes.push(function(){var M=C.defaultView;M&&($&&M.clearInterval($),f(M,"resize",R,!0)),f(C,"scroll",R,!0),P&&P.disconnect()}),C!=(this.root&&this.root.ownerDocument||t)){var _=T(C);_&&this._monitorIntersections(_.ownerDocument)}}},a.prototype._unmonitorIntersections=function(C){var E=this._monitoringDocuments.indexOf(C);if(E!=-1){var R=this.root&&this.root.ownerDocument||t,$=this._observationTargets.some(function(M){var V=M.element.ownerDocument;if(V==C)return!0;for(;V&&V!=R;){var F=T(V);if(V=F&&F.ownerDocument,V==C)return!0}return!1});if(!$){var P=this._monitoringUnsubscribes[E];if(this._monitoringDocuments.splice(E,1),this._monitoringUnsubscribes.splice(E,1),P(),C!=R){var _=T(C);_&&this._unmonitorIntersections(_.ownerDocument)}}}},a.prototype._unmonitorAllIntersections=function(){var C=this._monitoringUnsubscribes.slice(0);this._monitoringDocuments.length=0,this._monitoringUnsubscribes.length=0;for(var E=0;E<C.length;E++)C[E]()},a.prototype._checkForIntersections=function(){if(!(!this.root&&n&&!r)){var C=this._rootIsInDom(),E=C?this._getRootRect():g();this._observationTargets.forEach(function(R){var $=R.element,P=m($),_=this._rootContainsTarget($),M=R.entry,V=C&&_&&this._computeTargetAndRootIntersection($,P,E),F=R.entry=new i({time:o(),target:$,boundingClientRect:P,rootBounds:n&&!this.root?null:E,intersectionRect:V});M?C&&_?this._hasCrossedThreshold(M,F)&&this._queuedEntries.push(F):M&&M.isIntersecting&&this._queuedEntries.push(F):this._queuedEntries.push(F)},this),this._queuedEntries.length&&this._callback(this.takeRecords(),this)}},a.prototype._computeTargetAndRootIntersection=function(C,E,R){if(window.getComputedStyle(C).display!="none"){for(var $=E,P=k(C),_=!1;!_&&P;){var M=null,V=P.nodeType==1?window.getComputedStyle(P):{};if(V.display=="none")return null;if(P==this.root||P.nodeType==9)if(_=!0,P==this.root||P==t)n&&!this.root?!r||r.width==0&&r.height==0?(P=null,M=null,$=null):M=r:M=R;else{var F=k(P),W=F&&m(F),I=F&&this._computeTargetAndRootIntersection(F,W,R);W&&I?(P=F,M=x(W,I)):(P=null,$=null)}else{var ne=P.ownerDocument;P!=ne.body&&P!=ne.documentElement&&V.overflow!="visible"&&(M=m(P))}if(M&&($=h(M,$)),!$)break;P=P&&k(P)}return $}},a.prototype._getRootRect=function(){var C;if(this.root)C=m(this.root);else{var E=t.documentElement,R=t.body;C={top:0,left:0,right:E.clientWidth||R.clientWidth,width:E.clientWidth||R.clientWidth,bottom:E.clientHeight||R.clientHeight,height:E.clientHeight||R.clientHeight}}return this._expandRectByRootMargin(C)},a.prototype._expandRectByRootMargin=function(C){var E=this._rootMarginValues.map(function($,P){return $.unit=="px"?$.value:$.value*(P%2?C.width:C.height)/100}),R={top:C.top-E[0],right:C.right+E[1],bottom:C.bottom+E[2],left:C.left-E[3]};return R.width=R.right-R.left,R.height=R.bottom-R.top,R},a.prototype._hasCrossedThreshold=function(C,E){var R=C&&C.isIntersecting?C.intersectionRatio||0:-1,$=E.isIntersecting?E.intersectionRatio||0:-1;if(R!==$)for(var P=0;P<this.thresholds.length;P++){var _=this.thresholds[P];if(_==R||_==$||_<R!=_<$)return!0}},a.prototype._rootIsInDom=function(){return!this.root||S(t,this.root)},a.prototype._rootContainsTarget=function(C){return S(this.root||t,C)&&(!this.root||this.root.ownerDocument==C.ownerDocument)},a.prototype._registerInstance=function(){e.indexOf(this)<0&&e.push(this)},a.prototype._unregisterInstance=function(){var C=e.indexOf(this);C!=-1&&e.splice(C,1)};function o(){return window.performance&&performance.now&&performance.now()}function c(C,E){var R=null;return function(){R||(R=setTimeout(function(){C(),R=null},E))}}function u(C,E,R,$){typeof C.addEventListener=="function"?C.addEventListener(E,R,$):typeof C.attachEvent=="function"&&C.attachEvent("on"+E,R)}function f(C,E,R,$){typeof C.removeEventListener=="function"?C.removeEventListener(E,R,$):typeof C.detatchEvent=="function"&&C.detatchEvent("on"+E,R)}function h(C,E){var R=Math.max(C.top,E.top),$=Math.min(C.bottom,E.bottom),P=Math.max(C.left,E.left),_=Math.min(C.right,E.right),M=_-P,V=$-R;return M>=0&&V>=0&&{top:R,bottom:$,left:P,right:_,width:M,height:V}||null}function m(C){var E;try{E=C.getBoundingClientRect()}catch{}return E?(E.width&&E.height||(E={top:E.top,right:E.right,bottom:E.bottom,left:E.left,width:E.right-E.left,height:E.bottom-E.top}),E):g()}function g(){return{top:0,bottom:0,left:0,right:0,width:0,height:0}}function y(C){return!C||"x"in C?C:{top:C.top,y:C.top,bottom:C.bottom,left:C.left,x:C.left,right:C.right,width:C.width,height:C.height}}function x(C,E){var R=E.top-C.top,$=E.left-C.left;return{top:R,left:$,height:E.height,width:E.width,bottom:R+E.height,right:$+E.width}}function S(C,E){for(var R=E;R;){if(R==C)return!0;R=k(R)}return!1}function k(C){var E=C.parentNode;return C.nodeType==9&&C!=t?T(C):E&&E.nodeType==11&&E.host?E.host:E&&E.assignedSlot?E.assignedSlot.parentNode:E}function T(C){try{return C.defaultView&&C.defaultView.frameElement||null}catch{return null}}window.IntersectionObserver=a,window.IntersectionObserverEntry=i})()),VE}aG();const sG=le[typeof document<"u"&&document.createElement!==void 0?"useLayoutEffect":"useEffect"];function oG(t,e={}){const{root:n=null,pollInterval:r=null,useMutationObserver:i=!1,rootMargin:a="0px 0px 0px 0px",threshold:o=0,initialIsIntersecting:c=!1}=e,[u,f]=w.useState(()=>({boundingClientRect:null,intersectionRatio:0,intersectionRect:null,isIntersecting:c,rootBounds:null,target:null,time:0})),[h,m]=w.useState(()=>IE({root:n,pollInterval:r,useMutationObserver:i,rootMargin:a,threshold:o}));return w.useEffect(()=>{const g=IE({root:n,pollInterval:r,useMutationObserver:i,rootMargin:a,threshold:o});m(g)},[n,a,r,i,JSON.stringify(o)]),sG(()=>{const g=t&&"current"in t?t.current:t;if(!h||!g)return;let y=!1;h.observer.observe(g);const x=S=>{if(!y)for(let k=0;k<S.length;k++){const T=S[k];T.target===g&&f(T)}};return h.subscribe(x),()=>{y=!0,h.observer.unobserve(g),h.unsubscribe(x)}},[t,h]),u}function lG({root:t=null,pollInterval:e=null,useMutationObserver:n=!1,rootMargin:r="0px 0px 0px 0px",threshold:i=0}){const a=new Set;if(typeof IntersectionObserver>"u")return null;const o=new IntersectionObserver(c=>{for(const u of a)u(c,o)},{root:t,rootMargin:r,threshold:i});return o.POLL_INTERVAL=e,o.USE_MUTATION_OBSERVER=n,{observer:o,getListeners(){return a},subscribe:c=>a.add(c),unsubscribe:c=>a.delete(c)}}const BE=new Map;function IE(t){const{root:e,...n}=t,r=JSON.stringify(n);let i=BE.get(e);return i||(i={},BE.set(e,i)),i[r]?i[r]:i[r]=lG(t)}var qE={};class am{constructor(e,n,r,i,a,o,c,u,f,h=0,m){this.p=e,this.stack=n,this.state=r,this.reducePos=i,this.pos=a,this.score=o,this.buffer=c,this.bufferBase=u,this.curContext=f,this.lookAhead=h,this.parent=m}toString(){return`[${this.stack.filter((e,n)=>n%3==0).concat(this.state)}]@${this.pos}${this.score?"!"+this.score:""}`}static start(e,n,r=0){let i=e.parser.context;return new am(e,[],n,r,r,0,[],0,i?new UE(i,i.start):null,0,null)}get context(){return this.curContext?this.curContext.context:null}pushState(e,n){this.stack.push(this.state,n,this.bufferBase+this.buffer.length),this.state=e}reduce(e){var n;let r=e>>19,i=e&65535,{parser:a}=this.p,o=this.reducePos<this.pos-25&&this.setLookAhead(this.pos),c=a.dynamicPrecedence(i);if(c&&(this.score+=c),r==0){this.pushState(a.getGoto(this.state,i,!0),this.reducePos),i<a.minRepeatTerm&&this.storeNode(i,this.reducePos,this.reducePos,o?8:4,!0),this.reduceContext(i,this.reducePos);return}let u=this.stack.length-(r-1)*3-(e&262144?6:0),f=u?this.stack[u-2]:this.p.ranges[0].from,h=this.reducePos-f;h>=2e3&&!(!((n=this.p.parser.nodeSet.types[i])===null||n===void 0)&&n.isAnonymous)&&(f==this.p.lastBigReductionStart?(this.p.bigReductionCount++,this.p.lastBigReductionSize=h):this.p.lastBigReductionSize<h&&(this.p.bigReductionCount=1,this.p.lastBigReductionStart=f,this.p.lastBigReductionSize=h));let m=u?this.stack[u-1]:0,g=this.bufferBase+this.buffer.length-m;if(i<a.minRepeatTerm||e&131072){let y=a.stateFlag(this.state,1)?this.pos:this.reducePos;this.storeNode(i,f,y,g+4,!0)}if(e&262144)this.state=this.stack[u];else{let y=this.stack[u-3];this.state=a.getGoto(y,i,!0)}for(;this.stack.length>u;)this.stack.pop();this.reduceContext(i,f)}storeNode(e,n,r,i=4,a=!1){if(e==0&&(!this.stack.length||this.stack[this.stack.length-1]<this.buffer.length+this.bufferBase)){let o=this,c=this.buffer.length;if(c==0&&o.parent&&(c=o.bufferBase-o.parent.bufferBase,o=o.parent),c>0&&o.buffer[c-4]==0&&o.buffer[c-1]>-1){if(n==r)return;if(o.buffer[c-2]>=n){o.buffer[c-2]=r;return}}}if(!a||this.pos==r)this.buffer.push(e,n,r,i);else{let o=this.buffer.length;if(o>0&&(this.buffer[o-4]!=0||this.buffer[o-1]<0)){let c=!1;for(let u=o;u>0&&this.buffer[u-2]>r;u-=4)if(this.buffer[u-1]>=0){c=!0;break}if(c)for(;o>0&&this.buffer[o-2]>r;)this.buffer[o]=this.buffer[o-4],this.buffer[o+1]=this.buffer[o-3],this.buffer[o+2]=this.buffer[o-2],this.buffer[o+3]=this.buffer[o-1],o-=4,i>4&&(i-=4)}this.buffer[o]=e,this.buffer[o+1]=n,this.buffer[o+2]=r,this.buffer[o+3]=i}}shift(e,n,r,i){if(e&131072)this.pushState(e&65535,this.pos);else if((e&262144)==0){let a=e,{parser:o}=this.p;(i>this.pos||n<=o.maxNode)&&(this.pos=i,o.stateFlag(a,1)||(this.reducePos=i)),this.pushState(a,r),this.shiftContext(n,r),n<=o.maxNode&&this.buffer.push(n,r,i,4)}else this.pos=i,this.shiftContext(n,r),n<=this.p.parser.maxNode&&this.buffer.push(n,r,i,4)}apply(e,n,r,i){e&65536?this.reduce(e):this.shift(e,n,r,i)}useNode(e,n){let r=this.p.reused.length-1;(r<0||this.p.reused[r]!=e)&&(this.p.reused.push(e),r++);let i=this.pos;this.reducePos=this.pos=i+e.length,this.pushState(n,i),this.buffer.push(r,i,this.reducePos,-1),this.curContext&&this.updateContext(this.curContext.tracker.reuse(this.curContext.context,e,this,this.p.stream.reset(this.pos-e.length)))}split(){let e=this,n=e.buffer.length;for(;n>0&&e.buffer[n-2]>e.reducePos;)n-=4;let r=e.buffer.slice(n),i=e.bufferBase+n;for(;e&&i==e.bufferBase;)e=e.parent;return new am(this.p,this.stack.slice(),this.state,this.reducePos,this.pos,this.score,r,i,this.curContext,this.lookAhead,e)}recoverByDelete(e,n){let r=e<=this.p.parser.maxNode;r&&this.storeNode(e,this.pos,n,4),this.storeNode(0,this.pos,n,r?8:4),this.pos=this.reducePos=n,this.score-=190}canShift(e){for(let n=new cG(this);;){let r=this.p.parser.stateSlot(n.state,4)||this.p.parser.hasAction(n.state,e);if(r==0)return!1;if((r&65536)==0)return!0;n.reduce(r)}}recoverByInsert(e){if(this.stack.length>=300)return[];let n=this.p.parser.nextStates(this.state);if(n.length>8||this.stack.length>=120){let i=[];for(let a=0,o;a<n.length;a+=2)(o=n[a+1])!=this.state&&this.p.parser.hasAction(o,e)&&i.push(n[a],o);if(this.stack.length<120)for(let a=0;i.length<8&&a<n.length;a+=2){let o=n[a+1];i.some((c,u)=>u&1&&c==o)||i.push(n[a],o)}n=i}let r=[];for(let i=0;i<n.length&&r.length<4;i+=2){let a=n[i+1];if(a==this.state)continue;let o=this.split();o.pushState(a,this.pos),o.storeNode(0,o.pos,o.pos,4,!0),o.shiftContext(n[i],this.pos),o.reducePos=this.pos,o.score-=200,r.push(o)}return r}forceReduce(){let{parser:e}=this.p,n=e.stateSlot(this.state,5);if((n&65536)==0)return!1;if(!e.validAction(this.state,n)){let r=n>>19,i=n&65535,a=this.stack.length-r*3;if(a<0||e.getGoto(this.stack[a],i,!1)<0){let o=this.findForcedReduction();if(o==null)return!1;n=o}this.storeNode(0,this.pos,this.pos,4,!0),this.score-=100}return this.reducePos=this.pos,this.reduce(n),!0}findForcedReduction(){let{parser:e}=this.p,n=[],r=(i,a)=>{if(!n.includes(i))return n.push(i),e.allActions(i,o=>{if(!(o&393216))if(o&65536){let c=(o>>19)-a;if(c>1){let u=o&65535,f=this.stack.length-c*3;if(f>=0&&e.getGoto(this.stack[f],u,!1)>=0)return c<<19|65536|u}}else{let c=r(o,a+1);if(c!=null)return c}})};return r(this.state,0)}forceAll(){for(;!this.p.parser.stateFlag(this.state,2);)if(!this.forceReduce()){this.storeNode(0,this.pos,this.pos,4,!0);break}return this}get deadEnd(){if(this.stack.length!=3)return!1;let{parser:e}=this.p;return e.data[e.stateSlot(this.state,1)]==65535&&!e.stateSlot(this.state,4)}restart(){this.storeNode(0,this.pos,this.pos,4,!0),this.state=this.stack[0],this.stack.length=0}sameState(e){if(this.state!=e.state||this.stack.length!=e.stack.length)return!1;for(let n=0;n<this.stack.length;n+=3)if(this.stack[n]!=e.stack[n])return!1;return!0}get parser(){return this.p.parser}dialectEnabled(e){return this.p.parser.dialect.flags[e]}shiftContext(e,n){this.curContext&&this.updateContext(this.curContext.tracker.shift(this.curContext.context,e,this,this.p.stream.reset(n)))}reduceContext(e,n){this.curContext&&this.updateContext(this.curContext.tracker.reduce(this.curContext.context,e,this,this.p.stream.reset(n)))}emitContext(){let e=this.buffer.length-1;(e<0||this.buffer[e]!=-3)&&this.buffer.push(this.curContext.hash,this.pos,this.pos,-3)}emitLookAhead(){let e=this.buffer.length-1;(e<0||this.buffer[e]!=-4)&&this.buffer.push(this.lookAhead,this.pos,this.pos,-4)}updateContext(e){if(e!=this.curContext.context){let n=new UE(this.curContext.tracker,e);n.hash!=this.curContext.hash&&this.emitContext(),this.curContext=n}}setLookAhead(e){return e<=this.lookAhead?!1:(this.emitLookAhead(),this.lookAhead=e,!0)}close(){this.curContext&&this.curContext.tracker.strict&&this.emitContext(),this.lookAhead>0&&this.emitLookAhead()}}class UE{constructor(e,n){this.tracker=e,this.context=n,this.hash=e.strict?e.hash(n):0}}class cG{constructor(e){this.start=e,this.state=e.state,this.stack=e.stack,this.base=this.stack.length}reduce(e){let n=e&65535,r=e>>19;r==0?(this.stack==this.start.stack&&(this.stack=this.stack.slice()),this.stack.push(this.state,0,0),this.base+=3):this.base-=(r-1)*3;let i=this.start.p.parser.getGoto(this.stack[this.base-3],n,!0);this.state=i}}class sm{constructor(e,n,r){this.stack=e,this.pos=n,this.index=r,this.buffer=e.buffer,this.index==0&&this.maybeNext()}static create(e,n=e.bufferBase+e.buffer.length){return new sm(e,n,n-e.bufferBase)}maybeNext(){let e=this.stack.parent;e!=null&&(this.index=this.stack.bufferBase-e.bufferBase,this.stack=e,this.buffer=e.buffer)}get id(){return this.buffer[this.index-4]}get start(){return this.buffer[this.index-3]}get end(){return this.buffer[this.index-2]}get size(){return this.buffer[this.index-1]}next(){this.index-=4,this.pos-=4,this.index==0&&this.maybeNext()}fork(){return new sm(this.stack,this.pos,this.index)}}function ad(t,e=Uint16Array){if(typeof t!="string")return t;let n=null;for(let r=0,i=0;r<t.length;){let a=0;for(;;){let o=t.charCodeAt(r++),c=!1;if(o==126){a=65535;break}o>=92&&o--,o>=34&&o--;let u=o-32;if(u>=46&&(u-=46,c=!0),a+=u,c)break;a*=46}n?n[i++]=a:n=new e(a)}return n}class Tp{constructor(){this.start=-1,this.value=-1,this.end=-1,this.extended=-1,this.lookAhead=0,this.mask=0,this.context=0}}const YE=new Tp;class uG{constructor(e,n){this.input=e,this.ranges=n,this.chunk="",this.chunkOff=0,this.chunk2="",this.chunk2Pos=0,this.next=-1,this.token=YE,this.rangeIndex=0,this.pos=this.chunkPos=n[0].from,this.range=n[0],this.end=n[n.length-1].to,this.readNext()}resolveOffset(e,n){let r=this.range,i=this.rangeIndex,a=this.pos+e;for(;a<r.from;){if(!i)return null;let o=this.ranges[--i];a-=r.from-o.to,r=o}for(;n<0?a>r.to:a>=r.to;){if(i==this.ranges.length-1)return null;let o=this.ranges[++i];a+=o.from-r.to,r=o}return a}clipPos(e){if(e>=this.range.from&&e<this.range.to)return e;for(let n of this.ranges)if(n.to>e)return Math.max(e,n.from);return this.end}peek(e){let n=this.chunkOff+e,r,i;if(n>=0&&n<this.chunk.length)r=this.pos+e,i=this.chunk.charCodeAt(n);else{let a=this.resolveOffset(e,1);if(a==null)return-1;if(r=a,r>=this.chunk2Pos&&r<this.chunk2Pos+this.chunk2.length)i=this.chunk2.charCodeAt(r-this.chunk2Pos);else{let o=this.rangeIndex,c=this.range;for(;c.to<=r;)c=this.ranges[++o];this.chunk2=this.input.chunk(this.chunk2Pos=r),r+this.chunk2.length>c.to&&(this.chunk2=this.chunk2.slice(0,c.to-r)),i=this.chunk2.charCodeAt(0)}}return r>=this.token.lookAhead&&(this.token.lookAhead=r+1),i}acceptToken(e,n=0){let r=n?this.resolveOffset(n,-1):this.pos;if(r==null||r<this.token.start)throw new RangeError("Token end out of bounds");this.token.value=e,this.token.end=r}acceptTokenTo(e,n){this.token.value=e,this.token.end=n}getChunk(){if(this.pos>=this.chunk2Pos&&this.pos<this.chunk2Pos+this.chunk2.length){let{chunk:e,chunkPos:n}=this;this.chunk=this.chunk2,this.chunkPos=this.chunk2Pos,this.chunk2=e,this.chunk2Pos=n,this.chunkOff=this.pos-this.chunkPos}else{this.chunk2=this.chunk,this.chunk2Pos=this.chunkPos;let e=this.input.chunk(this.pos),n=this.pos+e.length;this.chunk=n>this.range.to?e.slice(0,this.range.to-this.pos):e,this.chunkPos=this.pos,this.chunkOff=0}}readNext(){return this.chunkOff>=this.chunk.length&&(this.getChunk(),this.chunkOff==this.chunk.length)?this.next=-1:this.next=this.chunk.charCodeAt(this.chunkOff)}advance(e=1){for(this.chunkOff+=e;this.pos+e>=this.range.to;){if(this.rangeIndex==this.ranges.length-1)return this.setDone();e-=this.range.to-this.pos,this.range=this.ranges[++this.rangeIndex],this.pos=this.range.from}return this.pos+=e,this.pos>=this.token.lookAhead&&(this.token.lookAhead=this.pos+1),this.readNext()}setDone(){return this.pos=this.chunkPos=this.end,this.range=this.ranges[this.rangeIndex=this.ranges.length-1],this.chunk="",this.next=-1}reset(e,n){if(n?(this.token=n,n.start=e,n.lookAhead=e+1,n.value=n.extended=-1):this.token=YE,this.pos!=e){if(this.pos=e,e==this.end)return this.setDone(),this;for(;e<this.range.from;)this.range=this.ranges[--this.rangeIndex];for(;e>=this.range.to;)this.range=this.ranges[++this.rangeIndex];e>=this.chunkPos&&e<this.chunkPos+this.chunk.length?this.chunkOff=e-this.chunkPos:(this.chunk="",this.chunkOff=0),this.readNext()}return this}read(e,n){if(e>=this.chunkPos&&n<=this.chunkPos+this.chunk.length)return this.chunk.slice(e-this.chunkPos,n-this.chunkPos);if(e>=this.chunk2Pos&&n<=this.chunk2Pos+this.chunk2.length)return this.chunk2.slice(e-this.chunk2Pos,n-this.chunk2Pos);if(e>=this.range.from&&n<=this.range.to)return this.input.read(e,n);let r="";for(let i of this.ranges){if(i.from>=n)break;i.to>e&&(r+=this.input.read(Math.max(i.from,e),Math.min(i.to,n)))}return r}}class uc{constructor(e,n){this.data=e,this.id=n}token(e,n){let{parser:r}=n.p;l5(this.data,e,n,this.id,r.data,r.tokenPrecTable)}}uc.prototype.contextual=uc.prototype.fallback=uc.prototype.extend=!1;class om{constructor(e,n,r){this.precTable=n,this.elseToken=r,this.data=typeof e=="string"?ad(e):e}token(e,n){let r=e.pos,i=0;for(;;){let a=e.next<0,o=e.resolveOffset(1,1);if(l5(this.data,e,n,0,this.data,this.precTable),e.token.value>-1)break;if(this.elseToken==null)return;if(a||i++,o==null)break;e.reset(o,e.token)}i&&(e.reset(r,e.token),e.acceptToken(this.elseToken,i))}}om.prototype.contextual=uc.prototype.fallback=uc.prototype.extend=!1;class qr{constructor(e,n={}){this.token=e,this.contextual=!!n.contextual,this.fallback=!!n.fallback,this.extend=!!n.extend}}function l5(t,e,n,r,i,a){let o=0,c=1<<r,{dialect:u}=n.p.parser;e:for(;(c&t[o])!=0;){let f=t[o+1];for(let y=o+3;y<f;y+=2)if((t[y+1]&c)>0){let x=t[y];if(u.allows(x)&&(e.token.value==-1||e.token.value==x||dG(x,e.token.value,i,a))){e.acceptToken(x);break}}let h=e.next,m=0,g=t[o+2];if(e.next<0&&g>m&&t[f+g*3-3]==65535){o=t[f+g*3-1];continue e}for(;m<g;){let y=m+g>>1,x=f+y+(y<<1),S=t[x],k=t[x+1]||65536;if(h<S)g=y;else if(h>=k)m=y+1;else{o=t[x+2],e.advance();continue e}}break}}function FE(t,e,n){for(let r=e,i;(i=t[r])!=65535;r++)if(i==n)return r-e;return-1}function dG(t,e,n,r){let i=FE(n,r,e);return i<0||FE(n,r,t)<i}const Dr=typeof process<"u"&&qE&&/\bparse\b/.test(qE.LOG);let Py=null;function WE(t,e,n){let r=t.cursor(Ut.IncludeAnonymous);for(r.moveTo(e);;)if(!(n<0?r.childBefore(e):r.childAfter(e)))for(;;){if((n<0?r.to<e:r.from>e)&&!r.type.isError)return n<0?Math.max(0,Math.min(r.to-1,e-25)):Math.min(t.length,Math.max(r.from+1,e+25));if(n<0?r.prevSibling():r.nextSibling())break;if(!r.parent())return n<0?0:t.length}}class fG{constructor(e,n){this.fragments=e,this.nodeSet=n,this.i=0,this.fragment=null,this.safeFrom=-1,this.safeTo=-1,this.trees=[],this.start=[],this.index=[],this.nextFragment()}nextFragment(){let e=this.fragment=this.i==this.fragments.length?null:this.fragments[this.i++];if(e){for(this.safeFrom=e.openStart?WE(e.tree,e.from+e.offset,1)-e.offset:e.from,this.safeTo=e.openEnd?WE(e.tree,e.to+e.offset,-1)-e.offset:e.to;this.trees.length;)this.trees.pop(),this.start.pop(),this.index.pop();this.trees.push(e.tree),this.start.push(-e.offset),this.index.push(0),this.nextStart=this.safeFrom}else this.nextStart=1e9}nodeAt(e){if(e<this.nextStart)return null;for(;this.fragment&&this.safeTo<=e;)this.nextFragment();if(!this.fragment)return null;for(;;){let n=this.trees.length-1;if(n<0)return this.nextFragment(),null;let r=this.trees[n],i=this.index[n];if(i==r.children.length){this.trees.pop(),this.start.pop(),this.index.pop();continue}let a=r.children[i],o=this.start[n]+r.positions[i];if(o>e)return this.nextStart=o,null;if(a instanceof tn){if(o==e){if(o<this.safeFrom)return null;let c=o+a.length;if(c<=this.safeTo){let u=a.prop(ct.lookAhead);if(!u||c+u<this.fragment.to)return a}}this.index[n]++,o+a.length>=Math.max(this.safeFrom,e)&&(this.trees.push(a),this.start.push(o),this.index.push(0))}else this.index[n]++,this.nextStart=o+a.length}}}class hG{constructor(e,n){this.stream=n,this.tokens=[],this.mainToken=null,this.actions=[],this.tokens=e.tokenizers.map(r=>new Tp)}getActions(e){let n=0,r=null,{parser:i}=e.p,{tokenizers:a}=i,o=i.stateSlot(e.state,3),c=e.curContext?e.curContext.hash:0,u=0;for(let f=0;f<a.length;f++){if((1<<f&o)==0)continue;let h=a[f],m=this.tokens[f];if(!(r&&!h.fallback)&&((h.contextual||m.start!=e.pos||m.mask!=o||m.context!=c)&&(this.updateCachedToken(m,h,e),m.mask=o,m.context=c),m.lookAhead>m.end+25&&(u=Math.max(m.lookAhead,u)),m.value!=0)){let g=n;if(m.extended>-1&&(n=this.addActions(e,m.extended,m.end,n)),n=this.addActions(e,m.value,m.end,n),!h.extend&&(r=m,n>g))break}}for(;this.actions.length>n;)this.actions.pop();return u&&e.setLookAhead(u),!r&&e.pos==this.stream.end&&(r=new Tp,r.value=e.p.parser.eofTerm,r.start=r.end=e.pos,n=this.addActions(e,r.value,r.end,n)),this.mainToken=r,this.actions}getMainToken(e){if(this.mainToken)return this.mainToken;let n=new Tp,{pos:r,p:i}=e;return n.start=r,n.end=Math.min(r+1,i.stream.end),n.value=r==i.stream.end?i.parser.eofTerm:0,n}updateCachedToken(e,n,r){let i=this.stream.clipPos(r.pos);if(n.token(this.stream.reset(i,e),r),e.value>-1){let{parser:a}=r.p;for(let o=0;o<a.specialized.length;o++)if(a.specialized[o]==e.value){let c=a.specializers[o](this.stream.read(e.start,e.end),r);if(c>=0&&r.p.parser.dialect.allows(c>>1)){(c&1)==0?e.value=c>>1:e.extended=c>>1;break}}}else e.value=0,e.end=this.stream.clipPos(i+1)}putAction(e,n,r,i){for(let a=0;a<i;a+=3)if(this.actions[a]==e)return i;return this.actions[i++]=e,this.actions[i++]=n,this.actions[i++]=r,i}addActions(e,n,r,i){let{state:a}=e,{parser:o}=e.p,{data:c}=o;for(let u=0;u<2;u++)for(let f=o.stateSlot(a,u?2:1);;f+=3){if(c[f]==65535)if(c[f+1]==1)f=za(c,f+2);else{i==0&&c[f+1]==2&&(i=this.putAction(za(c,f+2),n,r,i));break}c[f]==n&&(i=this.putAction(za(c,f+1),n,r,i))}return i}}class pG{constructor(e,n,r,i){this.parser=e,this.input=n,this.ranges=i,this.recovering=0,this.nextStackID=9812,this.minStackPos=0,this.reused=[],this.stoppedAt=null,this.lastBigReductionStart=-1,this.lastBigReductionSize=0,this.bigReductionCount=0,this.stream=new uG(n,i),this.tokens=new hG(e,this.stream),this.topTerm=e.top[1];let{from:a}=i[0];this.stacks=[am.start(this,e.top[0],a)],this.fragments=r.length&&this.stream.end-a>e.bufferLength*4?new fG(r,e.nodeSet):null}get parsedPos(){return this.minStackPos}advance(){let e=this.stacks,n=this.minStackPos,r=this.stacks=[],i,a;if(this.bigReductionCount>300&&e.length==1){let[o]=e;for(;o.forceReduce()&&o.stack.length&&o.stack[o.stack.length-2]>=this.lastBigReductionStart;);this.bigReductionCount=this.lastBigReductionSize=0}for(let o=0;o<e.length;o++){let c=e[o];for(;;){if(this.tokens.mainToken=null,c.pos>n)r.push(c);else{if(this.advanceStack(c,r,e))continue;{i||(i=[],a=[]),i.push(c);let u=this.tokens.getMainToken(c);a.push(u.value,u.end)}}break}}if(!r.length){let o=i&&gG(i);if(o)return Dr&&console.log("Finish with "+this.stackID(o)),this.stackToTree(o);if(this.parser.strict)throw Dr&&i&&console.log("Stuck with token "+(this.tokens.mainToken?this.parser.getName(this.tokens.mainToken.value):"none")),new SyntaxError("No parse at "+n);this.recovering||(this.recovering=5)}if(this.recovering&&i){let o=this.stoppedAt!=null&&i[0].pos>this.stoppedAt?i[0]:this.runRecovery(i,a,r);if(o)return Dr&&console.log("Force-finish "+this.stackID(o)),this.stackToTree(o.forceAll())}if(this.recovering){let o=this.recovering==1?1:this.recovering*3;if(r.length>o)for(r.sort((c,u)=>u.score-c.score);r.length>o;)r.pop();r.some(c=>c.reducePos>n)&&this.recovering--}else if(r.length>1){e:for(let o=0;o<r.length-1;o++){let c=r[o];for(let u=o+1;u<r.length;u++){let f=r[u];if(c.sameState(f)||c.buffer.length>500&&f.buffer.length>500)if((c.score-f.score||c.buffer.length-f.buffer.length)>0)r.splice(u--,1);else{r.splice(o--,1);continue e}}}r.length>12&&(r.sort((o,c)=>c.score-o.score),r.splice(12,r.length-12))}this.minStackPos=r[0].pos;for(let o=1;o<r.length;o++)r[o].pos<this.minStackPos&&(this.minStackPos=r[o].pos);return null}stopAt(e){if(this.stoppedAt!=null&&this.stoppedAt<e)throw new RangeError("Can't move stoppedAt forward");this.stoppedAt=e}advanceStack(e,n,r){let i=e.pos,{parser:a}=this,o=Dr?this.stackID(e)+" -> ":"";if(this.stoppedAt!=null&&i>this.stoppedAt)return e.forceReduce()?e:null;if(this.fragments){let f=e.curContext&&e.curContext.tracker.strict,h=f?e.curContext.hash:0;for(let m=this.fragments.nodeAt(i);m;){let g=this.parser.nodeSet.types[m.type.id]==m.type?a.getGoto(e.state,m.type.id):-1;if(g>-1&&m.length&&(!f||(m.prop(ct.contextHash)||0)==h))return e.useNode(m,g),Dr&&console.log(o+this.stackID(e)+` (via reuse of ${a.getName(m.type.id)})`),!0;if(!(m instanceof tn)||m.children.length==0||m.positions[0]>0)break;let y=m.children[0];if(y instanceof tn&&m.positions[0]==0)m=y;else break}}let c=a.stateSlot(e.state,4);if(c>0)return e.reduce(c),Dr&&console.log(o+this.stackID(e)+` (via always-reduce ${a.getName(c&65535)})`),!0;if(e.stack.length>=8400)for(;e.stack.length>6e3&&e.forceReduce(););let u=this.tokens.getActions(e);for(let f=0;f<u.length;){let h=u[f++],m=u[f++],g=u[f++],y=f==u.length||!r,x=y?e:e.split(),S=this.tokens.mainToken;if(x.apply(h,m,S?S.start:x.pos,g),Dr&&console.log(o+this.stackID(x)+` (via ${(h&65536)==0?"shift":`reduce of ${a.getName(h&65535)}`} for ${a.getName(m)} @ ${i}${x==e?"":", split"})`),y)return!0;x.pos>i?n.push(x):r.push(x)}return!1}advanceFully(e,n){let r=e.pos;for(;;){if(!this.advanceStack(e,null,null))return!1;if(e.pos>r)return GE(e,n),!0}}runRecovery(e,n,r){let i=null,a=!1;for(let o=0;o<e.length;o++){let c=e[o],u=n[o<<1],f=n[(o<<1)+1],h=Dr?this.stackID(c)+" -> ":"";if(c.deadEnd&&(a||(a=!0,c.restart(),Dr&&console.log(h+this.stackID(c)+" (restarted)"),this.advanceFully(c,r))))continue;let m=c.split(),g=h;for(let y=0;y<10&&m.forceReduce()&&(Dr&&console.log(g+this.stackID(m)+" (via force-reduce)"),!this.advanceFully(m,r));y++)Dr&&(g=this.stackID(m)+" -> ");for(let y of c.recoverByInsert(u))Dr&&console.log(h+this.stackID(y)+" (via recover-insert)"),this.advanceFully(y,r);this.stream.end>c.pos?(f==c.pos&&(f++,u=0),c.recoverByDelete(u,f),Dr&&console.log(h+this.stackID(c)+` (via recover-delete ${this.parser.getName(u)})`),GE(c,r)):(!i||i.score<c.score)&&(i=c)}return i}stackToTree(e){return e.close(),tn.build({buffer:sm.create(e),nodeSet:this.parser.nodeSet,topID:this.topTerm,maxBufferLength:this.parser.bufferLength,reused:this.reused,start:this.ranges[0].from,length:e.pos-this.ranges[0].from,minRepeatType:this.parser.minRepeatTerm})}stackID(e){let n=(Py||(Py=new WeakMap)).get(e);return n||Py.set(e,n=String.fromCodePoint(this.nextStackID++)),n+e}}function GE(t,e){for(let n=0;n<e.length;n++){let r=e[n];if(r.pos==t.pos&&r.sameState(t)){e[n].score<t.score&&(e[n]=t);return}}e.push(t)}class mG{constructor(e,n,r){this.source=e,this.flags=n,this.disabled=r}allows(e){return!this.disabled||this.disabled[e]==0}}const jy=t=>t;class c5{constructor(e){this.start=e.start,this.shift=e.shift||jy,this.reduce=e.reduce||jy,this.reuse=e.reuse||jy,this.hash=e.hash||(()=>0),this.strict=e.strict!==!1}}class Cc extends dj{constructor(e){if(super(),this.wrappers=[],e.version!=14)throw new RangeError(`Parser version (${e.version}) doesn't match runtime version (14)`);let n=e.nodeNames.split(" ");this.minRepeatTerm=n.length;for(let c=0;c<e.repeatNodeCount;c++)n.push("");let r=Object.keys(e.topRules).map(c=>e.topRules[c][1]),i=[];for(let c=0;c<n.length;c++)i.push([]);function a(c,u,f){i[c].push([u,u.deserialize(String(f))])}if(e.nodeProps)for(let c of e.nodeProps){let u=c[0];typeof u=="string"&&(u=ct[u]);for(let f=1;f<c.length;){let h=c[f++];if(h>=0)a(h,u,c[f++]);else{let m=c[f+-h];for(let g=-h;g>0;g--)a(c[f++],u,m);f++}}}this.nodeSet=new n1(n.map((c,u)=>ur.define({name:u>=this.minRepeatTerm?void 0:c,id:u,props:i[u],top:r.indexOf(u)>-1,error:u==0,skipped:e.skippedNodes&&e.skippedNodes.indexOf(u)>-1}))),e.propSources&&(this.nodeSet=this.nodeSet.extend(...e.propSources)),this.strict=!1,this.bufferLength=sj;let o=ad(e.tokenData);this.context=e.context,this.specializerSpecs=e.specialized||[],this.specialized=new Uint16Array(this.specializerSpecs.length);for(let c=0;c<this.specializerSpecs.length;c++)this.specialized[c]=this.specializerSpecs[c].term;this.specializers=this.specializerSpecs.map(HE),this.states=ad(e.states,Uint32Array),this.data=ad(e.stateData),this.goto=ad(e.goto),this.maxTerm=e.maxTerm,this.tokenizers=e.tokenizers.map(c=>typeof c=="number"?new uc(o,c):c),this.topRules=e.topRules,this.dialects=e.dialects||{},this.dynamicPrecedences=e.dynamicPrecedences||null,this.tokenPrecTable=e.tokenPrec,this.termNames=e.termNames||null,this.maxNode=this.nodeSet.types.length-1,this.dialect=this.parseDialect(),this.top=this.topRules[Object.keys(this.topRules)[0]]}createParse(e,n,r){let i=new pG(this,e,n,r);for(let a of this.wrappers)i=a(i,e,n,r);return i}getGoto(e,n,r=!1){let i=this.goto;if(n>=i[0])return-1;for(let a=i[n+1];;){let o=i[a++],c=o&1,u=i[a++];if(c&&r)return u;for(let f=a+(o>>1);a<f;a++)if(i[a]==e)return u;if(c)return-1}}hasAction(e,n){let r=this.data;for(let i=0;i<2;i++)for(let a=this.stateSlot(e,i?2:1),o;;a+=3){if((o=r[a])==65535)if(r[a+1]==1)o=r[a=za(r,a+2)];else{if(r[a+1]==2)return za(r,a+2);break}if(o==n||o==0)return za(r,a+1)}return 0}stateSlot(e,n){return this.states[e*6+n]}stateFlag(e,n){return(this.stateSlot(e,0)&n)>0}validAction(e,n){return!!this.allActions(e,r=>r==n?!0:null)}allActions(e,n){let r=this.stateSlot(e,4),i=r?n(r):void 0;for(let a=this.stateSlot(e,1);i==null;a+=3){if(this.data[a]==65535)if(this.data[a+1]==1)a=za(this.data,a+2);else break;i=n(za(this.data,a+1))}return i}nextStates(e){let n=[];for(let r=this.stateSlot(e,1);;r+=3){if(this.data[r]==65535)if(this.data[r+1]==1)r=za(this.data,r+2);else break;if((this.data[r+2]&1)==0){let i=this.data[r+1];n.some((a,o)=>o&1&&a==i)||n.push(this.data[r],i)}}return n}configure(e){let n=Object.assign(Object.create(Cc.prototype),this);if(e.props&&(n.nodeSet=this.nodeSet.extend(...e.props)),e.top){let r=this.topRules[e.top];if(!r)throw new RangeError(`Invalid top rule name ${e.top}`);n.top=r}return e.tokenizers&&(n.tokenizers=this.tokenizers.map(r=>{let i=e.tokenizers.find(a=>a.from==r);return i?i.to:r})),e.specializers&&(n.specializers=this.specializers.slice(),n.specializerSpecs=this.specializerSpecs.map((r,i)=>{let a=e.specializers.find(c=>c.from==r.external);if(!a)return r;let o=Object.assign(Object.assign({},r),{external:a.to});return n.specializers[i]=HE(o),o})),e.contextTracker&&(n.context=e.contextTracker),e.dialect&&(n.dialect=this.parseDialect(e.dialect)),e.strict!=null&&(n.strict=e.strict),e.wrap&&(n.wrappers=n.wrappers.concat(e.wrap)),e.bufferLength!=null&&(n.bufferLength=e.bufferLength),n}hasWrappers(){return this.wrappers.length>0}getName(e){return this.termNames?this.termNames[e]:String(e<=this.maxNode&&this.nodeSet.types[e].name||e)}get eofTerm(){return this.maxNode+1}get topNode(){return this.nodeSet.types[this.top[1]]}dynamicPrecedence(e){let n=this.dynamicPrecedences;return n==null?0:n[e]||0}parseDialect(e){let n=Object.keys(this.dialects),r=n.map(()=>!1);if(e)for(let a of e.split(" ")){let o=n.indexOf(a);o>=0&&(r[o]=!0)}let i=null;for(let a=0;a<n.length;a++)if(!r[a])for(let o=this.dialects[n[a]],c;(c=this.data[o++])!=65535;)(i||(i=new Uint8Array(this.maxTerm+1)))[c]=1;return new mG(e,r,i)}static deserialize(e){return new Cc(e)}}function za(t,e){return t[e]|t[e+1]<<16}function gG(t){let e=null;for(let n of t){let r=n.p.stoppedAt;(n.pos==n.p.stream.end||r!=null&&n.pos>r)&&n.p.parser.stateFlag(n.state,2)&&(!e||e.score<n.score)&&(e=n)}return e}function HE(t){if(t.external){let e=t.extend?1:0;return(n,r)=>t.external(n,r)<<1|e}return t.get}const OG=122,KE=1,vG=123,yG=124,u5=2,bG=125,xG=3,SG=4,d5=[9,10,11,12,13,32,133,160,5760,8192,8193,8194,8195,8196,8197,8198,8199,8200,8201,8202,8232,8233,8239,8287,12288],wG=58,kG=40,f5=95,CG=91,Ep=45,TG=46,EG=35,QG=37,AG=38,RG=92,_G=10,$G=42;function Md(t){return t>=65&&t<=90||t>=97&&t<=122||t>=161}function v1(t){return t>=48&&t<=57}function JE(t){return v1(t)||t>=97&&t<=102||t>=65&&t<=70}const h5=(t,e,n)=>(r,i)=>{for(let a=!1,o=0,c=0;;c++){let{next:u}=r;if(Md(u)||u==Ep||u==f5||a&&v1(u))!a&&(u!=Ep||c>0)&&(a=!0),o===c&&u==Ep&&o++,r.advance();else if(u==RG&&r.peek(1)!=_G){if(r.advance(),JE(r.next)){do r.advance();while(JE(r.next));r.next==32&&r.advance()}else r.next>-1&&r.advance();a=!0}else{a&&r.acceptToken(o==2&&i.canShift(u5)?e:u==kG?n:t);break}}},PG=new qr(h5(vG,u5,yG)),jG=new qr(h5(bG,xG,SG)),MG=new qr(t=>{if(d5.includes(t.peek(-1))){let{next:e}=t;(Md(e)||e==f5||e==EG||e==TG||e==$G||e==CG||e==wG&&Md(t.peek(1))||e==Ep||e==AG)&&t.acceptToken(OG)}}),NG=new qr(t=>{if(!d5.includes(t.peek(-1))){let{next:e}=t;if(e==QG&&(t.advance(),t.acceptToken(KE)),Md(e)){do t.advance();while(Md(t.next)||v1(t.next));t.acceptToken(KE)}}}),DG=ag({"AtKeyword import charset namespace keyframes media supports":J.definitionKeyword,"from to selector":J.keyword,NamespaceName:J.namespace,KeyframeName:J.labelName,KeyframeRangeName:J.operatorKeyword,TagName:J.tagName,ClassName:J.className,PseudoClassName:J.constant(J.className),IdName:J.labelName,"FeatureName PropertyName":J.propertyName,AttributeName:J.attributeName,NumberLiteral:J.number,KeywordQuery:J.keyword,UnaryQueryOp:J.operatorKeyword,"CallTag ValueName":J.atom,VariableName:J.variableName,Callee:J.operatorKeyword,Unit:J.unit,"UniversalSelector NestingSelector":J.definitionOperator,"MatchOp CompareOp":J.compareOperator,"ChildOp SiblingOp, LogicOp":J.logicOperator,BinOp:J.arithmeticOperator,Important:J.modifier,Comment:J.blockComment,ColorLiteral:J.color,"ParenthesizedContent StringLiteral":J.string,":":J.punctuation,"PseudoOp #":J.derefOperator,"; ,":J.separator,"( )":J.paren,"[ ]":J.squareBracket,"{ }":J.brace}),zG={__proto__:null,lang:38,"nth-child":38,"nth-last-child":38,"nth-of-type":38,"nth-last-of-type":38,dir:38,"host-context":38,if:84,url:124,"url-prefix":124,domain:124,regexp:124},LG={__proto__:null,or:98,and:98,not:106,only:106,layer:170},ZG={__proto__:null,selector:112,layer:166},VG={__proto__:null,"@import":162,"@media":174,"@charset":178,"@namespace":182,"@keyframes":188,"@supports":200,"@scope":204},XG={__proto__:null,to:207},BG=Cc.deserialize({version:14,states:"EbQYQdOOO#qQdOOP#xO`OOOOQP'#Cf'#CfOOQP'#Ce'#CeO#}QdO'#ChO$nQaO'#CcO$xQdO'#CkO%TQdO'#DpO%YQdO'#DrO%_QdO'#DuO%_QdO'#DxOOQP'#FV'#FVO&eQhO'#EhOOQS'#FU'#FUOOQS'#Ek'#EkQYQdOOO&lQdO'#EOO&PQhO'#EUO&lQdO'#EWO'aQdO'#EYO'lQdO'#E]O'tQhO'#EcO(VQdO'#EeO(bQaO'#CfO)VQ`O'#D{O)[Q`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a#c#t#v#x#{$a$k$p$s%h%i%q%u%z&P&d&l&x'QQ!qdR$X!rQ!PVR#TrQ#S!PR$i#TQ!SWR#VsQ!UXR#WtQ{UQ!wgQ#^yQ#o!_Q$U!nQ$[!uQ$_!yQ%e$^Q&Y%aQ&]%fR&v&XSjPzQ!}kQ$c!{R%k$dZiPkz!{$dR$P!gQ%}%SR&z&mR!rdR!teR$Z!tS%a$Y%bR&t&WV%_$Y%b&WQ#PmR$g#PQ`OSkPzU!a`k$dR$d!{Q$p#aY%p$p%u&d&l'QQ%u$sQ&d%qQ&l%zR'Q&xQ#t!cQ#v!dQ#x!eV$}#t#v#xQ%X$RR&T%XQ%y$zS&k%y&yR&y&lQ%r$pR&e%rQ%n$mR&c%nQyUR#]yQ%i$aR&_%iQ!|jS$e!|$fR$f!}Q&n%}R&{&nQ#k!ZR$x#kQ%b$YR&Z%bQ&X%aR&u&X__OP`kz!{$d^UOP`kz!{$dQ!VYQ!WZQ#XuQ#YvQ#ZwQ#[xQ$]!vQ$m#`R&b%mR$q#aQ!gaQ!oc[#q!c!d!e#t#v#xQ$a!zd$o#a$p$s%q%u%z&d&l&x'QQ$r#cQ%R#{S%g$a%iQ%l$kQ&^%hR&p&P]#s!c!d!e#t#v#xW!Z]b!g$PQ!ufQ#f!YQ#l![Q$v#iQ$w#jQ$z#mS%V$R%XR&i%xQ#h!YQ%w$tR&w&hR$|#mR$n#`QlPR#_zQ!_]Q!nbQ$O!gR%U$P",nodeNames:"⚠ Unit VariableName VariableName QueryCallee Comment StyleSheet RuleSet UniversalSelector TagSelector TagName NestingSelector ClassSelector . ClassName PseudoClassSelector : :: PseudoClassName PseudoClassName ) ( ArgList ValueName ParenthesizedValue AtKeyword # ; ] [ BracketedValue } { BracedValue ColorLiteral NumberLiteral StringLiteral BinaryExpression BinOp CallExpression Callee IfExpression if ArgList IfBranch KeywordQuery FeatureQuery FeatureName BinaryQuery LogicOp ComparisonQuery CompareOp UnaryQuery UnaryQueryOp ParenthesizedQuery SelectorQuery selector ParenthesizedSelector CallQuery ArgList , CallLiteral CallTag ParenthesizedContent PseudoClassName ArgList IdSelector IdName AttributeSelector AttributeName MatchOp ChildSelector ChildOp DescendantSelector SiblingSelector SiblingOp Block Declaration PropertyName Important ImportStatement import Layer layer LayerName layer MediaStatement media CharsetStatement charset NamespaceStatement namespace NamespaceName KeyframesStatement keyframes KeyframeName KeyframeList KeyframeSelector KeyframeRangeName SupportsStatement supports ScopeStatement scope to AtRule Styles",maxTerm:143,nodeProps:[["isolate",-2,5,36,""],["openedBy",20,"(",28,"[",31,"{"],["closedBy",21,")",29,"]",32,"}"]],propSources:[DG],skippedNodes:[0,5,106],repeatNodeCount:15,tokenData:"JQ~R!YOX$qX^%i^p$qpq%iqr({rs-ust/itu6Wuv$qvw7Qwx7cxy9Qyz9cz{9h{|:R|}>t}!O?V!O!P?t!P!Q@]!Q![AU![!]BP!]!^B{!^!_C^!_!`DY!`!aDm!a!b$q!b!cEn!c!}$q!}#OG{#O#P$q#P#QH^#Q#R6W#R#o$q#o#pHo#p#q6W#q#rIQ#r#sIc#s#y$q#y#z%i#z$f$q$f$g%i$g#BY$q#BY#BZ%i#BZ$IS$q$IS$I_%i$I_$I|$q$I|$JO%i$JO$JT$q$JT$JU%i$JU$KV$q$KV$KW%i$KW&FU$q&FU&FV%i&FV;'S$q;'S;=`Iz<%lO$q`$tSOy%Qz;'S%Q;'S;=`%c<%lO%Q`%VS!a`Oy%Qz;'S%Q;'S;=`%c<%lO%Q`%fP;=`<%l%Q~%nh#s~OX%QX^'Y^p%Qpq'Yqy%Qz#y%Q#y#z'Y#z$f%Q$f$g'Y$g#BY%Q#BY#BZ'Y#BZ$IS%Q$IS$I_'Y$I_$I|%Q$I|$JO'Y$JO$JT%Q$JT$JU'Y$JU$KV%Q$KV$KW'Y$KW&FU%Q&FU&FV'Y&FV;'S%Q;'S;=`%c<%lO%Q~'ah#s~!a`OX%QX^'Y^p%Qpq'Yqy%Qz#y%Q#y#z'Y#z$f%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QnHcSl^Oy%Qz;'S%Q;'S;=`%c<%lO%QjHtSpYOy%Qz;'S%Q;'S;=`%c<%lO%QjIVSoYOy%Qz;'S%Q;'S;=`%c<%lO%QfIhU!mQOy%Qz!_%Q!_!`6m!`;'S%Q;'S;=`%c<%lO%Q`I}P;=`<%l$q",tokenizers:[MG,NG,PG,jG,1,2,3,4,new om("m~RRYZ[z{a~~g~aO#v~~dP!P!Qg~lO#w~~",28,129)],topRules:{StyleSheet:[0,6],Styles:[1,105]},specialized:[{term:124,get:t=>zG[t]||-1},{term:125,get:t=>LG[t]||-1},{term:4,get:t=>ZG[t]||-1},{term:25,get:t=>VG[t]||-1},{term:123,get:t=>XG[t]||-1}],tokenPrec:1963});let My=null;function Ny(){if(!My&&typeof document=="object"&&document.body){let{style:t}=document.body,e=[],n=new Set;for(let r in t)r!="cssText"&&r!="cssFloat"&&typeof t[r]=="string"&&(/[A-Z]/.test(r)&&(r=r.replace(/[A-Z]/g,i=>"-"+i.toLowerCase())),n.has(r)||(e.push(r),n.add(r)));My=e.sort().map(r=>({type:"property",label:r,apply:r+": "}))}return My||[]}const eQ=["active","after","any-link","autofill","backdrop","before","checked","cue","default","defined","disabled","empty","enabled","file-selector-button","first","first-child","first-letter","first-line","first-of-type","focus","focus-visible","focus-within","fullscreen","has","host","host-context","hover","in-range","indeterminate","invalid","is","lang","last-child","last-of-type","left","link","marker","modal","not","nth-child","nth-last-child","nth-last-of-type","nth-of-type","only-child","only-of-type","optional","out-of-range","part","placeholder","placeholder-shown","read-only","read-write","required","right","root","scope","selection","slotted","target","target-text","valid","visited","where"].map(t=>({type:"class",label:t})),tQ=["above","absolute","activeborder","additive","activecaption","after-white-space","ahead","alias","all","all-scroll","alphabetic","alternate","always","antialiased","appworkspace","asterisks","attr","auto","auto-flow","avoid","avoid-column","avoid-page","avoid-region","axis-pan","background","backwards","baseline","below","bidi-override","blink","block","block-axis","bold","bolder","border","border-box","both","bottom","break","break-all","break-word","bullets","button","button-bevel","buttonface","buttonhighlight","buttonshadow","buttontext","calc","capitalize","caps-lock-indicator","caption","captiontext","caret","cell","center","checkbox","circle","cjk-decimal","clear","clip","close-quote","col-resize","collapse","color","color-burn","color-dodge","column","column-reverse","compact","condensed","contain","content","contents","content-box","context-menu","continuous","copy","counter","counters","cover","crop","cross","crosshair","currentcolor","cursive","cyclic","darken","dashed","decimal","decimal-leading-zero","default","default-button","dense","destination-atop","destination-in","destination-out","destination-over","difference","disc","discard","disclosure-closed","disclosure-open","document","dot-dash","dot-dot-dash","dotted","double","down","e-resize","ease","ease-in","ease-in-out","ease-out","element","ellipse","ellipsis","embed","end","ethiopic-abegede-gez","ethiopic-halehame-aa-er","ethiopic-halehame-gez","ew-resize","exclusion","expanded","extends","extra-condensed","extra-expanded","fantasy","fast","fill","fill-box","fixed","flat","flex","flex-end","flex-start","footnotes","forwards","from","geometricPrecision","graytext","grid","groove","hand","hard-light","help","hidden","hide","higher","highlight","highlighttext","horizontal","hsl","hsla","hue","icon","ignore","inactiveborder","inactivecaption","inactivecaptiontext","infinite","infobackground","infotext","inherit","initial","inline","inline-axis","inline-block","inline-flex","inline-grid","inline-table","inset","inside","intrinsic","invert","italic","justify","keep-all","landscape","large","larger","left","level","lighter","lighten","line-through","linear","linear-gradient","lines","list-item","listbox","listitem","local","logical","loud","lower","lower-hexadecimal","lower-latin","lower-norwegian","lowercase","ltr","luminosity","manipulation","match","matrix","matrix3d","medium","menu","menutext","message-box","middle","min-intrinsic","mix","monospace","move","multiple","multiple_mask_images","multiply","n-resize","narrower","ne-resize","nesw-resize","no-close-quote","no-drop","no-open-quote","no-repeat","none","normal","not-allowed","nowrap","ns-resize","numbers","numeric","nw-resize","nwse-resize","oblique","opacity","open-quote","optimizeLegibility","optimizeSpeed","outset","outside","outside-shape","overlay","overline","padding","padding-box","painted","page","paused","perspective","pinch-zoom","plus-darker","plus-lighter","pointer","polygon","portrait","pre","pre-line","pre-wrap","preserve-3d","progress","push-button","radial-gradient","radio","read-only","read-write","read-write-plaintext-only","rectangle","region","relative","repeat","repeating-linear-gradient","repeating-radial-gradient","repeat-x","repeat-y","reset","reverse","rgb","rgba","ridge","right","rotate","rotate3d","rotateX","rotateY","rotateZ","round","row","row-resize","row-reverse","rtl","run-in","running","s-resize","sans-serif","saturation","scale","scale3d","scaleX","scaleY","scaleZ","screen","scroll","scrollbar","scroll-position","se-resize","self-start","self-end","semi-condensed","semi-expanded","separate","serif","show","single","skew","skewX","skewY","skip-white-space","slide","slider-horizontal","slider-vertical","sliderthumb-horizontal","sliderthumb-vertical","slow","small","small-caps","small-caption","smaller","soft-light","solid","source-atop","source-in","source-out","source-over","space","space-around","space-between","space-evenly","spell-out","square","start","static","status-bar","stretch","stroke","stroke-box","sub","subpixel-antialiased","svg_masks","super","sw-resize","symbolic","symbols","system-ui","table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row","table-row-group","text","text-bottom","text-top","textarea","textfield","thick","thin","threeddarkshadow","threedface","threedhighlight","threedlightshadow","threedshadow","to","top","transform","translate","translate3d","translateX","translateY","translateZ","transparent","ultra-condensed","ultra-expanded","underline","unidirectional-pan","unset","up","upper-latin","uppercase","url","var","vertical","vertical-text","view-box","visible","visibleFill","visiblePainted","visibleStroke","visual","w-resize","wait","wave","wider","window","windowframe","windowtext","words","wrap","wrap-reverse","x-large","x-small","xor","xx-large","xx-small"].map(t=>({type:"keyword",label:t})).concat(["aliceblue","antiquewhite","aqua","aquamarine","azure","beige","bisque","black","blanchedalmond","blue","blueviolet","brown","burlywood","cadetblue","chartreuse","chocolate","coral","cornflowerblue","cornsilk","crimson","cyan","darkblue","darkcyan","darkgoldenrod","darkgray","darkgreen","darkkhaki","darkmagenta","darkolivegreen","darkorange","darkorchid","darkred","darksalmon","darkseagreen","darkslateblue","darkslategray","darkturquoise","darkviolet","deeppink","deepskyblue","dimgray","dodgerblue","firebrick","floralwhite","forestgreen","fuchsia","gainsboro","ghostwhite","gold","goldenrod","gray","grey","green","greenyellow","honeydew","hotpink","indianred","indigo","ivory","khaki","lavender","lavenderblush","lawngreen","lemonchiffon","lightblue","lightcoral","lightcyan","lightgoldenrodyellow","lightgray","lightgreen","lightpink","lightsalmon","lightseagreen","lightskyblue","lightslategray","lightsteelblue","lightyellow","lime","limegreen","linen","magenta","maroon","mediumaquamarine","mediumblue","mediumorchid","mediumpurple","mediumseagreen","mediumslateblue","mediumspringgreen","mediumturquoise","mediumvioletred","midnightblue","mintcream","mistyrose","moccasin","navajowhite","navy","oldlace","olive","olivedrab","orange","orangered","orchid","palegoldenrod","palegreen","paleturquoise","palevioletred","papayawhip","peachpuff","peru","pink","plum","powderblue","purple","rebeccapurple","red","rosybrown","royalblue","saddlebrown","salmon","sandybrown","seagreen","seashell","sienna","silver","skyblue","slateblue","slategray","snow","springgreen","steelblue","tan","teal","thistle","tomato","turquoise","violet","wheat","white","whitesmoke","yellow","yellowgreen"].map(t=>({type:"constant",label:t}))),IG=["a","abbr","address","article","aside","b","bdi","bdo","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","dd","del","details","dfn","dialog","div","dl","dt","em","figcaption","figure","footer","form","header","hgroup","h1","h2","h3","h4","h5","h6","hr","html","i","iframe","img","input","ins","kbd","label","legend","li","main","meter","nav","ol","output","p","pre","ruby","section","select","small","source","span","strong","sub","summary","sup","table","tbody","td","template","textarea","tfoot","th","thead","tr","u","ul"].map(t=>({type:"type",label:t})),qG=["@charset","@color-profile","@container","@counter-style","@font-face","@font-feature-values","@font-palette-values","@import","@keyframes","@layer","@media","@namespace","@page","@position-try","@property","@scope","@starting-style","@supports","@view-transition"].map(t=>({type:"keyword",label:t})),Na=/^(\w[\w-]*|-\w[\w-]*|)$/,UG=/^-(-[\w-]*)?$/;function YG(t,e){var n;if((t.name=="("||t.type.isError)&&(t=t.parent||t),t.name!="ArgList")return!1;let r=(n=t.parent)===null||n===void 0?void 0:n.firstChild;return r?.name!="Callee"?!1:e.sliceString(r.from,r.to)=="var"}const nQ=new uj,FG=["Declaration"];function WG(t){for(let e=t;;){if(e.type.isTop)return e;if(!(e=e.parent))return t}}function p5(t,e,n){if(e.to-e.from>4096){let r=nQ.get(e);if(r)return r;let i=[],a=new Set,o=e.cursor(Ut.IncludeAnonymous);if(o.firstChild())do for(let c of p5(t,o.node,n))a.has(c.label)||(a.add(c.label),i.push(c));while(o.nextSibling());return nQ.set(e,i),i}else{let r=[],i=new Set;return e.cursor().iterate(a=>{var o;if(n(a)&&a.matchContext(FG)&&((o=a.node.nextSibling)===null||o===void 0?void 0:o.name)==":"){let c=t.sliceString(a.from,a.to);i.has(c)||(i.add(c),r.push({label:c,type:"variable"}))}}),r}}const GG=t=>e=>{let{state:n,pos:r}=e,i=Mn(n).resolveInner(r,-1),a=i.type.isError&&i.from==i.to-1&&n.doc.sliceString(i.from,i.to)=="-";if(i.name=="PropertyName"||(a||i.name=="TagName")&&/^(Block|Styles)$/.test(i.resolve(i.to).name))return{from:i.from,options:Ny(),validFor:Na};if(i.name=="ValueName")return{from:i.from,options:tQ,validFor:Na};if(i.name=="PseudoClassName")return{from:i.from,options:eQ,validFor:Na};if(t(i)||(e.explicit||a)&&YG(i,n.doc))return{from:t(i)||a?i.from:r,options:p5(n.doc,WG(i),t),validFor:UG};if(i.name=="TagName"){for(let{parent:u}=i;u;u=u.parent)if(u.name=="Block")return{from:i.from,options:Ny(),validFor:Na};return{from:i.from,options:IG,validFor:Na}}if(i.name=="AtKeyword")return{from:i.from,options:qG,validFor:Na};if(!e.explicit)return null;let o=i.resolve(r),c=o.childBefore(r);return c&&c.name==":"&&o.name=="PseudoClassSelector"?{from:r,options:eQ,validFor:Na}:c&&c.name==":"&&o.name=="Declaration"||o.name=="ArgList"?{from:r,options:tQ,validFor:Na}:o.name=="Block"||o.name=="Styles"?{from:r,options:Ny(),validFor:Na}:null},HG=GG(t=>t.name=="VariableName"),lm=Sc.define({name:"css",parser:BG.configure({props:[lg.add({Declaration:Cp()}),c1.add({"Block KeyframeList":bj})]}),languageData:{commentTokens:{block:{open:"/*",close:"*/"}},indentOnInput:/^\s*\}$/,wordChars:"-"}});function m5(){return new o1(lm,lm.data.of({autocomplete:HG}))}const KG=55,JG=1,eH=56,tH=2,nH=57,rH=3,rQ=4,iH=5,y1=6,g5=7,O5=8,v5=9,y5=10,aH=11,sH=12,oH=13,Dy=58,lH=14,cH=15,iQ=59,b5=21,uH=23,x5=24,dH=25,wb=27,S5=28,fH=29,hH=32,pH=35,mH=37,gH=38,OH=0,vH=1,yH={area:!0,base:!0,br:!0,col:!0,command:!0,embed:!0,frame:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0,menuitem:!0},bH={dd:!0,li:!0,optgroup:!0,option:!0,p:!0,rp:!0,rt:!0,tbody:!0,td:!0,tfoot:!0,th:!0,tr:!0},aQ={dd:{dd:!0,dt:!0},dt:{dd:!0,dt:!0},li:{li:!0},option:{option:!0,optgroup:!0},optgroup:{optgroup:!0},p:{address:!0,article:!0,aside:!0,blockquote:!0,dir:!0,div:!0,dl:!0,fieldset:!0,footer:!0,form:!0,h1:!0,h2:!0,h3:!0,h4:!0,h5:!0,h6:!0,header:!0,hgroup:!0,hr:!0,menu:!0,nav:!0,ol:!0,p:!0,pre:!0,section:!0,table:!0,ul:!0},rp:{rp:!0,rt:!0},rt:{rp:!0,rt:!0},tbody:{tbody:!0,tfoot:!0},td:{td:!0,th:!0},tfoot:{tbody:!0},th:{td:!0,th:!0},thead:{tbody:!0,tfoot:!0},tr:{tr:!0}};function xH(t){return t==45||t==46||t==58||t>=65&&t<=90||t==95||t>=97&&t<=122||t>=161}let sQ=null,oQ=null,lQ=0;function kb(t,e){let n=t.pos+e;if(lQ==n&&oQ==t)return sQ;let r=t.peek(e),i="";for(;xH(r);)i+=String.fromCharCode(r),r=t.peek(++e);return oQ=t,lQ=n,sQ=i?i.toLowerCase():r==SH||r==wH?void 0:null}const w5=60,cm=62,b1=47,SH=63,wH=33,kH=45;function cQ(t,e){this.name=t,this.parent=e}const CH=[y1,y5,g5,O5,v5],TH=new c5({start:null,shift(t,e,n,r){return CH.indexOf(e)>-1?new cQ(kb(r,1)||"",t):t},reduce(t,e){return e==b5&&t?t.parent:t},reuse(t,e,n,r){let i=e.type.id;return i==y1||i==mH?new cQ(kb(r,1)||"",t):t},strict:!1}),EH=new qr((t,e)=>{if(t.next!=w5){t.next<0&&e.context&&t.acceptToken(Dy);return}t.advance();let n=t.next==b1;n&&t.advance();let r=kb(t,0);if(r===void 0)return;if(!r)return t.acceptToken(n?cH:lH);let i=e.context?e.context.name:null;if(n){if(r==i)return t.acceptToken(aH);if(i&&bH[i])return t.acceptToken(Dy,-2);if(e.dialectEnabled(OH))return t.acceptToken(sH);for(let a=e.context;a;a=a.parent)if(a.name==r)return;t.acceptToken(oH)}else{if(r=="script")return t.acceptToken(g5);if(r=="style")return t.acceptToken(O5);if(r=="textarea")return t.acceptToken(v5);if(yH.hasOwnProperty(r))return t.acceptToken(y5);i&&aQ[i]&&aQ[i][r]?t.acceptToken(Dy,-1):t.acceptToken(y1)}},{contextual:!0}),QH=new qr(t=>{for(let e=0,n=0;;n++){if(t.next<0){n&&t.acceptToken(iQ);break}if(t.next==kH)e++;else if(t.next==cm&&e>=2){n>=3&&t.acceptToken(iQ,-2);break}else e=0;t.advance()}});function AH(t){for(;t;t=t.parent)if(t.name=="svg"||t.name=="math")return!0;return!1}const RH=new qr((t,e)=>{if(t.next==b1&&t.peek(1)==cm){let n=e.dialectEnabled(vH)||AH(e.context);t.acceptToken(n?iH:rQ,2)}else t.next==cm&&t.acceptToken(rQ,1)});function x1(t,e,n){let r=2+t.length;return new qr(i=>{for(let a=0,o=0,c=0;;c++){if(i.next<0){c&&i.acceptToken(e);break}if(a==0&&i.next==w5||a==1&&i.next==b1||a>=2&&a<r&&i.next==t.charCodeAt(a-2))a++,o++;else if(a==r&&i.next==cm){c>o?i.acceptToken(e,-o):i.acceptToken(n,-(o-2));break}else if((i.next==10||i.next==13)&&c){i.acceptToken(e,1);break}else a=o=0;i.advance()}})}const _H=x1("script",KG,JG),$H=x1("style",eH,tH),PH=x1("textarea",nH,rH),jH=ag({"Text RawText IncompleteTag IncompleteCloseTag":J.content,"StartTag StartCloseTag SelfClosingEndTag EndTag":J.angleBracket,TagName:J.tagName,"MismatchedCloseTag/TagName":[J.tagName,J.invalid],AttributeName:J.attributeName,"AttributeValue UnquotedAttributeValue":J.attributeValue,Is:J.definitionOperator,"EntityReference CharacterReference":J.character,Comment:J.blockComment,ProcessingInst:J.processingInstruction,DoctypeDecl:J.documentMeta}),MH=Cc.deserialize({version:14,states:",xOVO!rOOO!ZQ#tO'#CrO!`Q#tO'#C{O!eQ#tO'#DOO!jQ#tO'#DRO!oQ#tO'#DTO!tOaO'#CqO#PObO'#CqO#[OdO'#CqO$kO!rO'#CqOOO`'#Cq'#CqO$rO$fO'#DUO$zQ#tO'#DWO%PQ#tO'#DXOOO`'#Dl'#DlOOO`'#DZ'#DZQVO!rOOO%UQ&rO,59^O%aQ&rO,59gO%lQ&rO,59jO%wQ&rO,59mO&SQ&rO,59oOOOa'#D_'#D_O&_OaO'#CyO&jOaO,59]OOOb'#D`'#D`O&rObO'#C|O&}ObO,59]OOOd'#Da'#DaO'VOdO'#DPO'bOdO,59]OOO`'#Db'#DbO'jO!rO,59]O'qQ#tO'#DSOOO`,59],59]OOOp'#Dc'#DcO'vO$fO,59pOOO`,59p,59pO(OQ#|O,59rO(TQ#|O,59sOOO`-E7X-E7XO(YQ&rO'#CtOOQW'#D['#D[O(hQ&rO1G.xOOOa1G.x1G.xOOO`1G/Z1G/ZO(sQ&rO1G/ROOOb1G/R1G/RO)OQ&rO1G/UOOOd1G/U1G/UO)ZQ&rO1G/XOOO`1G/X1G/XO)fQ&rO1G/ZOOOa-E7]-E7]O)qQ#tO'#CzOOO`1G.w1G.wOOOb-E7^-E7^O)vQ#tO'#C}OOOd-E7_-E7_O){Q#tO'#DQOOO`-E7`-E7`O*QQ#|O,59nOOOp-E7a-E7aOOO`1G/[1G/[OOO`1G/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PPPPPPPP%iX^OX`pXUOX`pezabcde{!O!Q!S!UR!q!dRhUR!XhXVOX`pRkVR!XkXWOX`pRnWR!XnXXOX`pQrXR!XpXYOX`pQ`ORx`Q{aQ!ObQ!QcQ!SdQ!UeZ!e{!O!Q!S!UQ!v!oR!z!vQ!y!pR!|!yQgUR!VgQjVR!YjQmWR![mQpXR!^pQtZR!`tS_O`ToXp",nodeNames:"⚠ StartCloseTag StartCloseTag StartCloseTag EndTag SelfClosingEndTag StartTag StartTag StartTag StartTag StartTag StartCloseTag StartCloseTag StartCloseTag IncompleteTag IncompleteCloseTag Document Text EntityReference CharacterReference InvalidEntity Element OpenTag TagName Attribute AttributeName Is AttributeValue UnquotedAttributeValue ScriptText CloseTag OpenTag StyleText CloseTag OpenTag TextareaText CloseTag OpenTag CloseTag SelfClosingTag Comment ProcessingInst MismatchedCloseTag CloseTag DoctypeDecl",maxTerm:68,context:TH,nodeProps:[["closedBy",-10,1,2,3,7,8,9,10,11,12,13,"EndTag",6,"EndTag SelfClosingEndTag",-4,22,31,34,37,"CloseTag"],["openedBy",4,"StartTag StartCloseTag",5,"StartTag",-4,30,33,36,38,"OpenTag"],["group",-10,14,15,18,19,20,21,40,41,42,43,"Entity",17,"Entity TextContent",-3,29,32,35,"TextContent Entity"],["isolate",-11,22,30,31,33,34,36,37,38,39,42,43,"ltr",-3,27,28,40,""]],propSources:[jH],skippedNodes:[0],repeatNodeCount:9,tokenData:"!<p!aR!YOX$qXY,QYZ,QZ[$q[]&X]^,Q^p$qpq,Qqr-_rs3_sv-_vw3}wxHYx}-_}!OH{!O!P-_!P!Q$q!Q![-_![!]Mz!]!^-_!^!_!$S!_!`!;x!`!a&X!a!c-_!c!}Mz!}#R-_#R#SMz#S#T1k#T#oMz#o#s-_#s$f$q$f%W-_%W%oMz%o%p-_%p&aMz&a&b-_&b1pMz1p4U-_4U4dMz4d4e-_4e$ISMz$IS$I`-_$I`$IbMz$Ib$Kh-_$Kh%#tMz%#t&/x-_&/x&Et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SaP!b`!dpOr&Xrs&}sv&Xwx(tx!^&X!^!_*V!_;'S&X;'S;=`*y<%lO&X",tokenizers:[_H,$H,PH,RH,EH,QH,0,1,2,3,4,5],topRules:{Document:[0,16]},dialects:{noMatch:0,selfClosing:515},tokenPrec:517});function k5(t,e){let n=Object.create(null);for(let r of t.getChildren(x5)){let i=r.getChild(dH),a=r.getChild(wb)||r.getChild(S5);i&&(n[e.read(i.from,i.to)]=a?a.type.id==wb?e.read(a.from+1,a.to-1):e.read(a.from,a.to):"")}return n}function uQ(t,e){let n=t.getChild(uH);return n?e.read(n.from,n.to):" "}function zy(t,e,n){let r;for(let i of n)if(!i.attrs||i.attrs(r||(r=k5(t.node.parent.firstChild,e))))return{parser:i.parser};return null}function C5(t=[],e=[]){let n=[],r=[],i=[],a=[];for(let c of t)(c.tag=="script"?n:c.tag=="style"?r:c.tag=="textarea"?i:a).push(c);let o=e.length?Object.create(null):null;for(let c of e)(o[c.name]||(o[c.name]=[])).push(c);return PY((c,u)=>{let f=c.type.id;if(f==fH)return zy(c,u,n);if(f==hH)return zy(c,u,r);if(f==pH)return zy(c,u,i);if(f==b5&&a.length){let h=c.node,m=h.firstChild,g=m&&uQ(m,u),y;if(g){for(let x of a)if(x.tag==g&&(!x.attrs||x.attrs(y||(y=k5(m,u))))){let S=h.lastChild,k=S.type.id==gH?S.from:h.to;if(k>m.to)return{parser:x.parser,overlay:[{from:m.to,to:k}]}}}}if(o&&f==x5){let h=c.node,m;if(m=h.firstChild){let g=o[u.read(m.from,m.to)];if(g)for(let y of g){if(y.tagName&&y.tagName!=uQ(h.parent,u))continue;let x=h.lastChild;if(x.type.id==wb){let S=x.from+1,k=x.lastChild,T=x.to-(k&&k.isError?0:1);if(T>S)return{parser:y.parser,overlay:[{from:S,to:T}]}}else if(x.type.id==S5)return{parser:y.parser,overlay:[{from:x.from,to:x.to}]}}}}return null})}const NH=316,DH=317,dQ=1,zH=2,LH=3,ZH=4,VH=318,XH=320,BH=321,IH=5,qH=6,UH=0,Cb=[9,10,11,12,13,32,133,160,5760,8192,8193,8194,8195,8196,8197,8198,8199,8200,8201,8202,8232,8233,8239,8287,12288],T5=125,YH=59,Tb=47,FH=42,WH=43,GH=45,HH=60,KH=44,JH=63,eK=46,tK=91,nK=new c5({start:!1,shift(t,e){return e==IH||e==qH||e==XH?t:e==BH},strict:!1}),rK=new qr((t,e)=>{let{next:n}=t;(n==T5||n==-1||e.context)&&t.acceptToken(VH)},{contextual:!0,fallback:!0}),iK=new qr((t,e)=>{let{next:n}=t,r;Cb.indexOf(n)>-1||n==Tb&&((r=t.peek(1))==Tb||r==FH)||n!=T5&&n!=YH&&n!=-1&&!e.context&&t.acceptToken(NH)},{contextual:!0}),aK=new qr((t,e)=>{t.next==tK&&!e.context&&t.acceptToken(DH)},{contextual:!0}),sK=new qr((t,e)=>{let{next:n}=t;if(n==WH||n==GH){if(t.advance(),n==t.next){t.advance();let r=!e.context&&e.canShift(dQ);t.acceptToken(r?dQ:zH)}}else n==JH&&t.peek(1)==eK&&(t.advance(),t.advance(),(t.next<48||t.next>57)&&t.acceptToken(LH))},{contextual:!0});function Ly(t,e){return t>=65&&t<=90||t>=97&&t<=122||t==95||t>=192||!e&&t>=48&&t<=57}const oK=new qr((t,e)=>{if(t.next!=HH||!e.dialectEnabled(UH)||(t.advance(),t.next==Tb))return;let n=0;for(;Cb.indexOf(t.next)>-1;)t.advance(),n++;if(Ly(t.next,!0)){for(t.advance(),n++;Ly(t.next,!1);)t.advance(),n++;for(;Cb.indexOf(t.next)>-1;)t.advance(),n++;if(t.next==KH)return;for(let r=0;;r++){if(r==7){if(!Ly(t.next,!0))return;break}if(t.next!="extends".charCodeAt(r))break;t.advance(),n++}}t.acceptToken(ZH,-n)}),lK=ag({"get set async static":J.modifier,"for while do if else switch try catch finally return throw break continue default case defer":J.controlKeyword,"in of await yield void typeof delete instanceof as satisfies":J.operatorKeyword,"let var const using function class extends":J.definitionKeyword,"import export from":J.moduleKeyword,"with debugger new":J.keyword,TemplateString:J.special(J.string),super:J.atom,BooleanLiteral:J.bool,this:J.self,null:J.null,Star:J.modifier,VariableName:J.variableName,"CallExpression/VariableName TaggedTemplateExpression/VariableName":J.function(J.variableName),VariableDefinition:J.definition(J.variableName),Label:J.labelName,PropertyName:J.propertyName,PrivatePropertyName:J.special(J.propertyName),"CallExpression/MemberExpression/PropertyName":J.function(J.propertyName),"FunctionDeclaration/VariableDefinition":J.function(J.definition(J.variableName)),"ClassDeclaration/VariableDefinition":J.definition(J.className),"NewExpression/VariableName":J.className,PropertyDefinition:J.definition(J.propertyName),PrivatePropertyDefinition:J.definition(J.special(J.propertyName)),UpdateOp:J.updateOperator,"LineComment Hashbang":J.lineComment,BlockComment:J.blockComment,Number:J.number,String:J.string,Escape:J.escape,ArithOp:J.arithmeticOperator,LogicOp:J.logicOperator,BitOp:J.bitwiseOperator,CompareOp:J.compareOperator,RegExp:J.regexp,Equals:J.definitionOperator,Arrow:J.function(J.punctuation),": Spread":J.punctuation,"( )":J.paren,"[ ]":J.squareBracket,"{ }":J.brace,"InterpolationStart InterpolationEnd":J.special(J.brace),".":J.derefOperator,", ;":J.separator,"@":J.meta,TypeName:J.typeName,TypeDefinition:J.definition(J.typeName),"type enum interface implements namespace module declare":J.definitionKeyword,"abstract global Privacy readonly override":J.modifier,"is keyof unique infer asserts":J.operatorKeyword,JSXAttributeValue:J.attributeValue,JSXText:J.content,"JSXStartTag JSXStartCloseTag JSXSelfCloseEndTag JSXEndTag":J.angleBracket,"JSXIdentifier JSXNameSpacedName":J.tagName,"JSXAttribute/JSXIdentifier JSXAttribute/JSXNameSpacedName":J.attributeName,"JSXBuiltin/JSXIdentifier":J.standard(J.tagName)}),cK={__proto__:null,export:20,as:25,from:33,default:36,async:41,function:42,in:52,out:55,const:56,extends:60,this:64,true:72,false:72,null:84,void:88,typeof:92,super:108,new:142,delete:154,yield:163,await:167,class:172,public:235,private:235,protected:235,readonly:237,instanceof:256,satisfies:259,import:292,keyof:349,unique:353,infer:359,asserts:395,is:397,abstract:417,implements:419,type:421,let:424,var:426,using:429,interface:435,enum:439,namespace:445,module:447,declare:451,global:455,defer:471,for:476,of:485,while:488,with:492,do:496,if:500,else:502,switch:506,case:512,try:518,catch:522,finally:526,return:530,throw:534,break:538,continue:542,debugger:546},uK={__proto__:null,async:129,get:131,set:133,declare:195,public:197,private:197,protected:197,static:199,abstract:201,override:203,readonly:209,accessor:211,new:401},dK={__proto__:null,"<":193},fK=Cc.deserialize({version:14,states:"$F|Q%TQlOOO%[QlOOO'_QpOOP(lO`OOO*zQ!0MxO'#CiO+RO#tO'#CjO+aO&jO'#CjO+oO#@ItO'#DaO.QQlO'#DgO.bQlO'#DrO%[QlO'#DzO0fQlO'#ESOOQ!0Lf'#E['#E[O1PQ`O'#EXOOQO'#Ep'#EpOOQO'#Il'#IlO1XQ`O'#GsO1dQ`O'#EoO1iQ`O'#EoO3hQ!0MxO'#JrO6[Q!0MxO'#JsO6uQ`O'#F]O6zQ,UO'#FtOOQ!0Lf'#Ff'#FfO7VO7dO'#FfO9XQMhO'#F|O9`Q`O'#F{OOQ!0Lf'#Js'#JsOOQ!0Lb'#Jr'#JrO9eQ`O'#GwOOQ['#K_'#K_O9pQ`O'#IYO9uQ!0LrO'#IZOOQ['#J`'#J`OOQ['#I_'#I_Q`QlOOQ`QlOOO9}Q!L^O'#DvO:UQlO'#EOO:]QlO'#EQO9kQ`O'#GsO:dQMhO'#CoO:rQ`O'#EnO:}Q`O'#EyO;hQMhO'#FeO;xQ`O'#GsOOQO'#K`'#K`O;}Q`O'#K`O<]Q`O'#G{O<]Q`O'#G|O<]Q`O'#HOO9kQ`O'#HRO=SQ`O'#HUO>kQ`O'#CeO>{Q`O'#HcO?TQ`O'#HiO?TQ`O'#HkO`QlO'#HmO?TQ`O'#HoO?TQ`O'#HrO?YQ`O'#HxO?_Q!0LsO'#IOO%[QlO'#IQO?jQ!0LsO'#ISO?uQ!0LsO'#IUO9uQ!0LrO'#IWO@QQ!0MxO'#CiOASQ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9c7WQ:^8qQ:p9bQ;Z:`Q;c:rQ;n;[R;q;dnqOXst!Z#d%m&r&t&u&w,s,x2[2_Q&l!VR,h&itmOXst!U!V!Z#d%m&i&r&t&u&w,s,x2[2_R,o&oT%lm,oR1k,XR,g&gQ&U|S+}&V&WR1^,OR+s&PT&p!W&sT&q!W&sT2^,x2_",nodeNames:"⚠ ArithOp ArithOp ?. JSXStartTag LineComment BlockComment Script Hashbang ExportDeclaration export Star as VariableName String Escape from ; default FunctionDeclaration async function VariableDefinition > < TypeParamList in out const TypeDefinition extends ThisType this LiteralType ArithOp Number BooleanLiteral TemplateType InterpolationEnd Interpolation InterpolationStart NullType null VoidType void TypeofType typeof MemberExpression . PropertyName [ TemplateString Escape Interpolation super RegExp ] ArrayExpression Spread , } { ObjectExpression Property async get set PropertyDefinition Block : NewTarget new NewExpression ) ( ArgList UnaryExpression delete LogicOp BitOp YieldExpression yield AwaitExpression await ParenthesizedExpression ClassExpression class ClassBody MethodDeclaration Decorator @ MemberExpression PrivatePropertyName CallExpression TypeArgList CompareOp < declare Privacy static abstract override PrivatePropertyDefinition PropertyDeclaration readonly accessor Optional TypeAnnotation Equals StaticBlock FunctionExpression ArrowFunction ParamList ParamList ArrayPattern ObjectPattern PatternProperty Privacy readonly Arrow MemberExpression BinaryExpression ArithOp ArithOp ArithOp ArithOp BitOp CompareOp instanceof satisfies CompareOp BitOp BitOp BitOp LogicOp LogicOp ConditionalExpression LogicOp LogicOp AssignmentExpression UpdateOp PostfixExpression CallExpression InstantiationExpression TaggedTemplateExpression DynamicImport import ImportMeta JSXElement JSXSelfCloseEndTag JSXSelfClosingTag JSXIdentifier JSXBuiltin JSXIdentifier JSXNamespacedName JSXMemberExpression JSXSpreadAttribute JSXAttribute JSXAttributeValue JSXEscape JSXEndTag JSXOpenTag JSXFragmentTag JSXText JSXEscape JSXStartCloseTag JSXCloseTag PrefixCast < ArrowFunction TypeParamList SequenceExpression InstantiationExpression KeyofType keyof UniqueType unique ImportType InferredType infer TypeName ParenthesizedType FunctionSignature ParamList NewSignature IndexedType TupleType Label ArrayType ReadonlyType ObjectType MethodType PropertyType IndexSignature PropertyDefinition CallSignature TypePredicate asserts is NewSignature new UnionType LogicOp IntersectionType LogicOp ConditionalType ParameterizedType ClassDeclaration abstract implements type VariableDeclaration let var using TypeAliasDeclaration InterfaceDeclaration interface EnumDeclaration enum EnumBody NamespaceDeclaration namespace module AmbientDeclaration declare GlobalDeclaration global ClassDeclaration ClassBody AmbientFunctionDeclaration ExportGroup VariableName VariableName ImportDeclaration defer ImportGroup ForStatement for ForSpec ForInSpec ForOfSpec of WhileStatement while WithStatement with DoStatement do IfStatement if else SwitchStatement switch SwitchBody CaseLabel case DefaultLabel TryStatement try CatchClause catch FinallyClause finally ReturnStatement return ThrowStatement throw BreakStatement break ContinueStatement continue DebuggerStatement debugger LabeledStatement ExpressionStatement SingleExpression SingleClassItem",maxTerm:380,context:nK,nodeProps:[["isolate",-8,5,6,14,37,39,51,53,55,""],["group",-26,9,17,19,68,207,211,215,216,218,221,224,234,237,243,245,247,249,252,258,264,266,268,270,272,274,275,"Statement",-34,13,14,32,35,36,42,51,54,55,57,62,70,72,76,80,82,84,85,110,111,120,121,136,139,141,142,143,144,145,147,148,167,169,171,"Expression",-23,31,33,37,41,43,45,173,175,177,178,180,181,182,184,185,186,188,189,190,201,203,205,206,"Type",-3,88,103,109,"ClassItem"],["openedBy",23,"<",38,"InterpolationStart",56,"[",60,"{",73,"(",160,"JSXStartCloseTag"],["closedBy",-2,24,168,">",40,"InterpolationEnd",50,"]",61,"}",74,")",165,"JSXEndTag"]],propSources:[lK],skippedNodes:[0,5,6,278],repeatNodeCount:37,tokenData:"$Fq07[R!bOX%ZXY+gYZ-yZ[+g[]%Z]^.c^p%Zpq+gqr/mrs3cst:_tuEruvJSvwLkwx! Yxy!'iyz!(sz{!)}{|!,q|}!.O}!O!,q!O!P!/Y!P!Q!9j!Q!R#:O!R![#<_![!]#I_!]!^#Jk!^!_#Ku!_!`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("function ${name}(${params}) {\n ${}\n}",{label:"function",detail:"definition",type:"keyword"}),xr("for (let ${index} = 0; ${index} < ${bound}; ${index}++) {\n ${}\n}",{label:"for",detail:"loop",type:"keyword"}),xr("for (let ${name} of ${collection}) {\n ${}\n}",{label:"for",detail:"of loop",type:"keyword"}),xr("do {\n ${}\n} while (${})",{label:"do",detail:"loop",type:"keyword"}),xr("while (${}) {\n ${}\n}",{label:"while",detail:"loop",type:"keyword"}),xr(`try {
|
|
89
|
-
\${}
|
|
90
|
-
} catch (\${error}) {
|
|
91
|
-
\${}
|
|
92
|
-
}`,{label:"try",detail:"/ catch block",type:"keyword"}),xr("if (${}) {\n ${}\n}",{label:"if",detail:"block",type:"keyword"}),xr(`if (\${}) {
|
|
93
|
-
\${}
|
|
94
|
-
} else {
|
|
95
|
-
\${}
|
|
96
|
-
}`,{label:"if",detail:"/ else block",type:"keyword"}),xr(`class \${name} {
|
|
97
|
-
constructor(\${params}) {
|
|
98
|
-
\${}
|
|
99
|
-
}
|
|
100
|
-
}`,{label:"class",detail:"definition",type:"keyword"}),xr('import {${names}} from "${module}"\n${}',{label:"import",detail:"named",type:"keyword"}),xr('import ${name} from "${module}"\n${}',{label:"import",detail:"default",type:"keyword"})],hK=E5.concat([xr("interface ${name} {\n ${}\n}",{label:"interface",detail:"definition",type:"keyword"}),xr("type ${name} = ${type}",{label:"type",detail:"definition",type:"keyword"}),xr("enum ${name} {\n ${}\n}",{label:"enum",detail:"definition",type:"keyword"})]),fQ=new uj,Q5=new Set(["Script","Block","FunctionExpression","FunctionDeclaration","ArrowFunction","MethodDeclaration","ForStatement"]);function Wu(t){return(e,n)=>{let r=e.node.getChild("VariableDefinition");return r&&n(r,t),!0}}const pK=["FunctionDeclaration"],mK={FunctionDeclaration:Wu("function"),ClassDeclaration:Wu("class"),ClassExpression:()=>!0,EnumDeclaration:Wu("constant"),TypeAliasDeclaration:Wu("type"),NamespaceDeclaration:Wu("namespace"),VariableDefinition(t,e){t.matchContext(pK)||e(t,"variable")},TypeDefinition(t,e){e(t,"type")},__proto__:null};function A5(t,e){let n=fQ.get(e);if(n)return n;let r=[],i=!0;function a(o,c){let u=t.sliceString(o.from,o.to);r.push({label:u,type:c})}return e.cursor(Ut.IncludeAnonymous).iterate(o=>{if(i)i=!1;else if(o.name){let c=mK[o.name];if(c&&c(o,a)||Q5.has(o.name))return!1}else if(o.to-o.from>8192){for(let c of A5(t,o.node))r.push(c);return!1}}),fQ.set(e,r),r}const hQ=/^[\w$\xa1-\uffff][\w$\d\xa1-\uffff]*$/,R5=["TemplateString","String","RegExp","LineComment","BlockComment","VariableDefinition","TypeDefinition","Label","PropertyDefinition","PropertyName","PrivatePropertyDefinition","PrivatePropertyName","JSXText","JSXAttributeValue","JSXOpenTag","JSXCloseTag","JSXSelfClosingTag",".","?."];function gK(t){let e=Mn(t.state).resolveInner(t.pos,-1);if(R5.indexOf(e.name)>-1)return null;let n=e.name=="VariableName"||e.to-e.from<20&&hQ.test(t.state.sliceDoc(e.from,e.to));if(!n&&!t.explicit)return null;let r=[];for(let i=e;i;i=i.parent)Q5.has(i.name)&&(r=r.concat(A5(t.state.doc,i)));return{options:r,from:n?e.from:t.pos,validFor:hQ}}const da=Sc.define({name:"javascript",parser:fK.configure({props:[lg.add({IfStatement:Cp({except:/^\s*({|else\b)/}),TryStatement:Cp({except:/^\s*({|catch\b|finally\b)/}),LabeledStatement:rF,SwitchBody:t=>{let e=t.textAfter,n=/^\s*\}/.test(e),r=/^\s*(case|default)\b/.test(e);return t.baseIndent+(n?0:r?1:2)*t.unit},Block:nF({closing:"}"}),ArrowFunction:t=>t.baseIndent+t.unit,"TemplateString BlockComment":()=>null,"Statement Property":Cp({except:/^\s*{/}),JSXElement(t){let e=/^\s*<\//.test(t.textAfter);return t.lineIndent(t.node.from)+(e?0:t.unit)},JSXEscape(t){let e=/\s*\}/.test(t.textAfter);return t.lineIndent(t.node.from)+(e?0:t.unit)},"JSXOpenTag JSXSelfClosingTag"(t){return t.column(t.node.from)+t.unit}}),c1.add({"Block ClassBody SwitchBody EnumBody ObjectExpression ArrayExpression ObjectType":bj,BlockComment(t){return{from:t.from+2,to:t.to-2}}})]}),languageData:{closeBrackets:{brackets:["(","[","{","'",'"',"`"]},commentTokens:{line:"//",block:{open:"/*",close:"*/"}},indentOnInput:/^\s*(?:case |default:|\{|\}|<\/)$/,wordChars:"$"}}),_5={test:t=>/^JSX/.test(t.name),facet:mj({commentTokens:{block:{open:"{/*",close:"*/}"}}})},$5=da.configure({dialect:"ts"},"typescript"),P5=da.configure({dialect:"jsx",props:[s1.add(t=>t.isTop?[_5]:void 0)]}),j5=da.configure({dialect:"jsx ts",props:[s1.add(t=>t.isTop?[_5]:void 0)]},"typescript");let M5=t=>({label:t,type:"keyword"});const N5="break case const continue default delete export extends false finally in instanceof let new return static super switch this throw true typeof var yield".split(" ").map(M5),OK=N5.concat(["declare","implements","private","protected","public"].map(M5));function Eb(t={}){let e=t.jsx?t.typescript?j5:P5:t.typescript?$5:da,n=t.typescript?hK.concat(OK):E5.concat(N5);return new o1(e,[da.data.of({autocomplete:SF(R5,xF(n))}),da.data.of({autocomplete:gK}),t.jsx?bK:[]])}function vK(t){for(;;){if(t.name=="JSXOpenTag"||t.name=="JSXSelfClosingTag"||t.name=="JSXFragmentTag")return t;if(t.name=="JSXEscape"||!t.parent)return null;t=t.parent}}function pQ(t,e,n=t.length){for(let r=e?.firstChild;r;r=r.nextSibling)if(r.name=="JSXIdentifier"||r.name=="JSXBuiltin"||r.name=="JSXNamespacedName"||r.name=="JSXMemberExpression")return t.sliceString(r.from,Math.min(r.to,n));return""}const yK=typeof navigator=="object"&&/Android\b/.test(navigator.userAgent),bK=qe.inputHandler.of((t,e,n,r,i)=>{if((yK?t.composing:t.compositionStarted)||t.state.readOnly||e!=n||r!=">"&&r!="/"||!da.isActiveAt(t.state,e,-1))return!1;let a=i(),{state:o}=a,c=o.changeByRange(u=>{var f;let{head:h}=u,m=Mn(o).resolveInner(h-1,-1),g;if(m.name=="JSXStartTag"&&(m=m.parent),!(o.doc.sliceString(h-1,h)!=r||m.name=="JSXAttributeValue"&&m.to>h)){if(r==">"&&m.name=="JSXFragmentTag")return{range:u,changes:{from:h,insert:"</>"}};if(r=="/"&&m.name=="JSXStartCloseTag"){let y=m.parent,x=y.parent;if(x&&y.from==h-2&&((g=pQ(o.doc,x.firstChild,h))||((f=x.firstChild)===null||f===void 0?void 0:f.name)=="JSXFragmentTag")){let S=`${g}>`;return{range:Se.cursor(h+S.length,-1),changes:{from:h,insert:S}}}}else if(r==">"){let y=vK(m);if(y&&y.name=="JSXOpenTag"&&!/^\/?>|^<\//.test(o.doc.sliceString(h,h+2))&&(g=pQ(o.doc,y,h)))return{range:u,changes:{from:h,insert:`</${g}>`}}}}return{range:u}});return c.changes.empty?!1:(t.dispatch([a,o.update(c,{userEvent:"input.complete",scrollIntoView:!0})]),!0)}),Gu=["_blank","_self","_top","_parent"],Zy=["ascii","utf-8","utf-16","latin1","latin1"],Vy=["get","post","put","delete"],Xy=["application/x-www-form-urlencoded","multipart/form-data","text/plain"],zr=["true","false"],Ve={},xK={a:{attrs:{href:null,ping:null,type:null,media:null,target:Gu,hreflang:null}},abbr:Ve,address:Ve,area:{attrs:{alt:null,coords:null,href:null,target:null,ping:null,media:null,hreflang:null,type:null,shape:["default","rect","circle","poly"]}},article:Ve,aside:Ve,audio:{attrs:{src:null,mediagroup:null,crossorigin:["anonymous","use-credentials"],preload:["none","metadata","auto"],autoplay:["autoplay"],loop:["loop"],controls:["controls"]}},b:Ve,base:{attrs:{href:null,target:Gu}},bdi:Ve,bdo:Ve,blockquote:{attrs:{cite:null}},body:Ve,br:Ve,button:{attrs:{form:null,formaction:null,name:null,value:null,autofocus:["autofocus"],disabled:["autofocus"],formenctype:Xy,formmethod:Vy,formnovalidate:["novalidate"],formtarget:Gu,type:["submit","reset","button"]}},canvas:{attrs:{width:null,height:null}},caption:Ve,center:Ve,cite:Ve,code:Ve,col:{attrs:{span:null}},colgroup:{attrs:{span:null}},command:{attrs:{type:["command","checkbox","radio"],label:null,icon:null,radiogroup:null,command:null,title:null,disabled:["disabled"],checked:["checked"]}},data:{attrs:{value:null}},datagrid:{attrs:{disabled:["disabled"],multiple:["multiple"]}},datalist:{attrs:{data:null}},dd:Ve,del:{attrs:{cite:null,datetime:null}},details:{attrs:{open:["open"]}},dfn:Ve,div:Ve,dl:Ve,dt:Ve,em:Ve,embed:{attrs:{src:null,type:null,width:null,height:null}},eventsource:{attrs:{src:null}},fieldset:{attrs:{disabled:["disabled"],form:null,name:null}},figcaption:Ve,figure:Ve,footer:Ve,form:{attrs:{action:null,name:null,"accept-charset":Zy,autocomplete:["on","off"],enctype:Xy,method:Vy,novalidate:["novalidate"],target:Gu}},h1:Ve,h2:Ve,h3:Ve,h4:Ve,h5:Ve,h6:Ve,head:{children:["title","base","link","style","meta","script","noscript","command"]},header:Ve,hgroup:Ve,hr:Ve,html:{attrs:{manifest:null}},i:Ve,iframe:{attrs:{src:null,srcdoc:null,name:null,width:null,height:null,sandbox:["allow-top-navigation","allow-same-origin","allow-forms","allow-scripts"],seamless:["seamless"]}},img:{attrs:{alt:null,src:null,ismap:null,usemap:null,width:null,height:null,crossorigin:["anonymous","use-credentials"]}},input:{attrs:{alt:null,dirname:null,form:null,formaction:null,height:null,list:null,max:null,maxlength:null,min:null,name:null,pattern:null,placeholder:null,size:null,src:null,step:null,value:null,width:null,accept:["audio/*","video/*","image/*"],autocomplete:["on","off"],autofocus:["autofocus"],checked:["checked"],disabled:["disabled"],formenctype:Xy,formmethod:Vy,formnovalidate:["novalidate"],formtarget:Gu,multiple:["multiple"],readonly:["readonly"],required:["required"],type:["hidden","text","search","tel","url","email","password","datetime","date","month","week","time","datetime-local","number","range","color","checkbox","radio","file","submit","image","reset","button"]}},ins:{attrs:{cite:null,datetime:null}},kbd:Ve,keygen:{attrs:{challenge:null,form:null,name:null,autofocus:["autofocus"],disabled:["disabled"],keytype:["RSA"]}},label:{attrs:{for:null,form:null}},legend:Ve,li:{attrs:{value:null}},link:{attrs:{href:null,type:null,hreflang:null,media:null,sizes:["all","16x16","16x16 32x32","16x16 32x32 64x64"]}},map:{attrs:{name:null}},mark:Ve,menu:{attrs:{label:null,type:["list","context","toolbar"]}},meta:{attrs:{content:null,charset:Zy,name:["viewport","application-name","author","description","generator","keywords"],"http-equiv":["content-language","content-type","default-style","refresh"]}},meter:{attrs:{value:null,min:null,low:null,high:null,max:null,optimum:null}},nav:Ve,noscript:Ve,object:{attrs:{data:null,type:null,name:null,usemap:null,form:null,width:null,height:null,typemustmatch:["typemustmatch"]}},ol:{attrs:{reversed:["reversed"],start:null,type:["1","a","A","i","I"]},children:["li","script","template","ul","ol"]},optgroup:{attrs:{disabled:["disabled"],label:null}},option:{attrs:{disabled:["disabled"],label:null,selected:["selected"],value:null}},output:{attrs:{for:null,form:null,name:null}},p:Ve,param:{attrs:{name:null,value:null}},pre:Ve,progress:{attrs:{value:null,max:null}},q:{attrs:{cite:null}},rp:Ve,rt:Ve,ruby:Ve,samp:Ve,script:{attrs:{type:["text/javascript"],src:null,async:["async"],defer:["defer"],charset:Zy}},section:Ve,select:{attrs:{form:null,name:null,size:null,autofocus:["autofocus"],disabled:["disabled"],multiple:["multiple"]}},slot:{attrs:{name:null}},small:Ve,source:{attrs:{src:null,type:null,media:null}},span:Ve,strong:Ve,style:{attrs:{type:["text/css"],media:null,scoped:null}},sub:Ve,summary:Ve,sup:Ve,table:Ve,tbody:Ve,td:{attrs:{colspan:null,rowspan:null,headers:null}},template:Ve,textarea:{attrs:{dirname:null,form:null,maxlength:null,name:null,placeholder:null,rows:null,cols:null,autofocus:["autofocus"],disabled:["disabled"],readonly:["readonly"],required:["required"],wrap:["soft","hard"]}},tfoot:Ve,th:{attrs:{colspan:null,rowspan:null,headers:null,scope:["row","col","rowgroup","colgroup"]}},thead:Ve,time:{attrs:{datetime:null}},title:Ve,tr:Ve,track:{attrs:{src:null,label:null,default:null,kind:["subtitles","captions","descriptions","chapters","metadata"],srclang:null}},ul:{children:["li","script","template","ul","ol"]},var:Ve,video:{attrs:{src:null,poster:null,width:null,height:null,crossorigin:["anonymous","use-credentials"],preload:["auto","metadata","none"],autoplay:["autoplay"],mediagroup:["movie"],muted:["muted"],controls:["controls"]}},wbr:Ve},D5={accesskey:null,class:null,contenteditable:zr,contextmenu:null,dir:["ltr","rtl","auto"],draggable:["true","false","auto"],dropzone:["copy","move","link","string:","file:"],hidden:["hidden"],id:null,inert:["inert"],itemid:null,itemprop:null,itemref:null,itemscope:["itemscope"],itemtype:null,lang:["ar","bn","de","en-GB","en-US","es","fr","hi","id","ja","pa","pt","ru","tr","zh"],spellcheck:zr,autocorrect:zr,autocapitalize:zr,style:null,tabindex:null,title:null,translate:["yes","no"],rel:["stylesheet","alternate","author","bookmark","help","license","next","nofollow","noreferrer","prefetch","prev","search","tag"],role:"alert application article banner button cell checkbox complementary contentinfo dialog document feed figure form grid gridcell heading img list listbox listitem main navigation region row rowgroup search switch tab table tabpanel textbox timer".split(" "),"aria-activedescendant":null,"aria-atomic":zr,"aria-autocomplete":["inline","list","both","none"],"aria-busy":zr,"aria-checked":["true","false","mixed","undefined"],"aria-controls":null,"aria-describedby":null,"aria-disabled":zr,"aria-dropeffect":null,"aria-expanded":["true","false","undefined"],"aria-flowto":null,"aria-grabbed":["true","false","undefined"],"aria-haspopup":zr,"aria-hidden":zr,"aria-invalid":["true","false","grammar","spelling"],"aria-label":null,"aria-labelledby":null,"aria-level":null,"aria-live":["off","polite","assertive"],"aria-multiline":zr,"aria-multiselectable":zr,"aria-owns":null,"aria-posinset":null,"aria-pressed":["true","false","mixed","undefined"],"aria-readonly":zr,"aria-relevant":null,"aria-required":zr,"aria-selected":["true","false","undefined"],"aria-setsize":null,"aria-sort":["ascending","descending","none","other"],"aria-valuemax":null,"aria-valuemin":null,"aria-valuenow":null,"aria-valuetext":null},z5="beforeunload copy cut dragstart dragover dragleave dragenter dragend drag paste focus blur change click load mousedown mouseenter mouseleave mouseup keydown keyup resize scroll unload".split(" ").map(t=>"on"+t);for(let t of z5)D5[t]=null;class um{constructor(e,n){this.tags={...xK,...e},this.globalAttrs={...D5,...n},this.allTags=Object.keys(this.tags),this.globalAttrNames=Object.keys(this.globalAttrs)}}um.default=new um;function Tc(t,e,n=t.length){if(!e)return"";let r=e.firstChild,i=r&&r.getChild("TagName");return i?t.sliceString(i.from,Math.min(i.to,n)):""}function Ec(t,e=!1){for(;t;t=t.parent)if(t.name=="Element")if(e)e=!1;else return t;return null}function L5(t,e,n){let r=n.tags[Tc(t,Ec(e))];return r?.children||n.allTags}function S1(t,e){let n=[];for(let r=Ec(e);r&&!r.type.isTop;r=Ec(r.parent)){let i=Tc(t,r);if(i&&r.lastChild.name=="CloseTag")break;i&&n.indexOf(i)<0&&(e.name=="EndTag"||e.from>=r.firstChild.to)&&n.push(i)}return n}const Z5=/^[:\-\.\w\u00b7-\uffff]*$/;function mQ(t,e,n,r,i){let a=/\s*>/.test(t.sliceDoc(i,i+5))?"":">",o=Ec(n,n.name=="StartTag"||n.name=="TagName");return{from:r,to:i,options:L5(t.doc,o,e).map(c=>({label:c,type:"type"})).concat(S1(t.doc,n).map((c,u)=>({label:"/"+c,apply:"/"+c+a,type:"type",boost:99-u}))),validFor:/^\/?[:\-\.\w\u00b7-\uffff]*$/}}function gQ(t,e,n,r){let i=/\s*>/.test(t.sliceDoc(r,r+5))?"":">";return{from:n,to:r,options:S1(t.doc,e).map((a,o)=>({label:a,apply:a+i,type:"type",boost:99-o})),validFor:Z5}}function SK(t,e,n,r){let i=[],a=0;for(let o of L5(t.doc,n,e))i.push({label:"<"+o,type:"type"});for(let o of S1(t.doc,n))i.push({label:"</"+o+">",type:"type",boost:99-a++});return{from:r,to:r,options:i,validFor:/^<\/?[:\-\.\w\u00b7-\uffff]*$/}}function wK(t,e,n,r,i){let a=Ec(n),o=a?e.tags[Tc(t.doc,a)]:null,c=o&&o.attrs?Object.keys(o.attrs):[],u=o&&o.globalAttrs===!1?c:c.length?c.concat(e.globalAttrNames):e.globalAttrNames;return{from:r,to:i,options:u.map(f=>({label:f,type:"property"})),validFor:Z5}}function kK(t,e,n,r,i){var a;let o=(a=n.parent)===null||a===void 0?void 0:a.getChild("AttributeName"),c=[],u;if(o){let f=t.sliceDoc(o.from,o.to),h=e.globalAttrs[f];if(!h){let m=Ec(n),g=m?e.tags[Tc(t.doc,m)]:null;h=g?.attrs&&g.attrs[f]}if(h){let m=t.sliceDoc(r,i).toLowerCase(),g='"',y='"';/^['"]/.test(m)?(u=m[0]=='"'?/^[^"]*$/:/^[^']*$/,g="",y=t.sliceDoc(i,i+1)==m[0]?"":m[0],m=m.slice(1),r++):u=/^[^\s<>='"]*$/;for(let x of h)c.push({label:x,apply:g+x+y,type:"constant"})}}return{from:r,to:i,options:c,validFor:u}}function CK(t,e){let{state:n,pos:r}=e,i=Mn(n).resolveInner(r,-1),a=i.resolve(r);for(let o=r,c;a==i&&(c=i.childBefore(o));){let u=c.lastChild;if(!u||!u.type.isError||u.from<u.to)break;a=i=c,o=u.from}return i.name=="TagName"?i.parent&&/CloseTag$/.test(i.parent.name)?gQ(n,i,i.from,r):mQ(n,t,i,i.from,r):i.name=="StartTag"||i.name=="IncompleteTag"?mQ(n,t,i,r,r):i.name=="StartCloseTag"||i.name=="IncompleteCloseTag"?gQ(n,i,r,r):i.name=="OpenTag"||i.name=="SelfClosingTag"||i.name=="AttributeName"?wK(n,t,i,i.name=="AttributeName"?i.from:r,r):i.name=="Is"||i.name=="AttributeValue"||i.name=="UnquotedAttributeValue"?kK(n,t,i,i.name=="Is"?r:i.from,r):e.explicit&&(a.name=="Element"||a.name=="Text"||a.name=="Document")?SK(n,t,i,r):null}function TK(t){let{extraTags:e,extraGlobalAttributes:n}=t,r=n||e?new um(e,n):um.default;return i=>CK(r,i)}const EK=da.parser.configure({top:"SingleExpression"}),V5=[{tag:"script",attrs:t=>t.type=="text/typescript"||t.lang=="ts",parser:$5.parser},{tag:"script",attrs:t=>t.type=="text/babel"||t.type=="text/jsx",parser:P5.parser},{tag:"script",attrs:t=>t.type=="text/typescript-jsx",parser:j5.parser},{tag:"script",attrs(t){return/^(importmap|speculationrules|application\/(.+\+)?json)$/i.test(t.type)},parser:EK},{tag:"script",attrs(t){return!t.type||/^(?:text|application)\/(?:x-)?(?:java|ecma)script$|^module$|^$/i.test(t.type)},parser:da.parser},{tag:"style",attrs(t){return(!t.lang||t.lang=="css")&&(!t.type||/^(text\/)?(x-)?(stylesheet|css)$/i.test(t.type))},parser:lm.parser}],X5=[{name:"style",parser:lm.parser.configure({top:"Styles"})}].concat(z5.map(t=>({name:t,parser:da.parser}))),B5=Sc.define({name:"html",parser:MH.configure({props:[lg.add({Element(t){let e=/^(\s*)(<\/)?/.exec(t.textAfter);return t.node.to<=t.pos+e[0].length?t.continue():t.lineIndent(t.node.from)+(e[2]?0:t.unit)},"OpenTag CloseTag SelfClosingTag"(t){return t.column(t.node.from)+t.unit},Document(t){if(t.pos+/\s*/.exec(t.textAfter)[0].length<t.node.to)return t.continue();let e=null,n;for(let r=t.node;;){let i=r.lastChild;if(!i||i.name!="Element"||i.to!=r.to)break;e=r=i}return e&&!((n=e.lastChild)&&(n.name=="CloseTag"||n.name=="SelfClosingTag"))?t.lineIndent(e.from)+t.unit:null}}),c1.add({Element(t){let e=t.firstChild,n=t.lastChild;return!e||e.name!="OpenTag"?null:{from:e.to,to:n.name=="CloseTag"?n.from:t.to}}}),kj.add({"OpenTag CloseTag":t=>t.getChild("TagName")})]}),languageData:{commentTokens:{block:{open:"<!--",close:"-->"}},indentOnInput:/^\s*<\/\w+\W$/,wordChars:"-_"}}),Qp=B5.configure({wrap:C5(V5,X5)});function QK(t={}){let e="",n;t.matchClosingTags===!1&&(e="noMatch"),t.selfClosingTags===!0&&(e=(e?e+" ":"")+"selfClosing"),(t.nestedLanguages&&t.nestedLanguages.length||t.nestedAttributes&&t.nestedAttributes.length)&&(n=C5((t.nestedLanguages||[]).concat(V5),(t.nestedAttributes||[]).concat(X5)));let r=n?B5.configure({wrap:n,dialect:e}):e?Qp.configure({dialect:e}):Qp;return new o1(r,[Qp.data.of({autocomplete:TK(t)}),t.autoCloseTags!==!1?AK:[],Eb().support,m5().support])}const OQ=new Set("area base br col command embed frame hr img input keygen link meta param source track wbr menuitem".split(" ")),AK=qe.inputHandler.of((t,e,n,r,i)=>{if(t.composing||t.state.readOnly||e!=n||r!=">"&&r!="/"||!Qp.isActiveAt(t.state,e,-1))return!1;let a=i(),{state:o}=a,c=o.changeByRange(u=>{var f,h,m;let g=o.doc.sliceString(u.from-1,u.to)==r,{head:y}=u,x=Mn(o).resolveInner(y,-1),S;if(g&&r==">"&&x.name=="EndTag"){let k=x.parent;if(((h=(f=k.parent)===null||f===void 0?void 0:f.lastChild)===null||h===void 0?void 0:h.name)!="CloseTag"&&(S=Tc(o.doc,k.parent,y))&&!OQ.has(S)){let T=y+(o.doc.sliceString(y,y+1)===">"?1:0),C=`</${S}>`;return{range:u,changes:{from:y,to:T,insert:C}}}}else if(g&&r=="/"&&x.name=="IncompleteCloseTag"){let k=x.parent;if(x.from==y-2&&((m=k.lastChild)===null||m===void 0?void 0:m.name)!="CloseTag"&&(S=Tc(o.doc,k,y))&&!OQ.has(S)){let T=y+(o.doc.sliceString(y,y+1)===">"?1:0),C=`${S}>`;return{range:Se.cursor(y+C.length,-1),changes:{from:y,to:T,insert:C}}}}return{range:u}});return c.changes.empty?!1:(t.dispatch([a,o.update(c,{userEvent:"input.complete",scrollIntoView:!0})]),!0)});var By,vQ;function RK(){if(vQ)return By;vQ=1;const t=[[{color:"0, 0, 0",class:"ansi-black"},{color:"187, 0, 0",class:"ansi-red"},{color:"0, 187, 0",class:"ansi-green"},{color:"187, 187, 0",class:"ansi-yellow"},{color:"0, 0, 187",class:"ansi-blue"},{color:"187, 0, 187",class:"ansi-magenta"},{color:"0, 187, 187",class:"ansi-cyan"},{color:"255,255,255",class:"ansi-white"}],[{color:"85, 85, 85",class:"ansi-bright-black"},{color:"255, 85, 85",class:"ansi-bright-red"},{color:"0, 255, 0",class:"ansi-bright-green"},{color:"255, 255, 85",class:"ansi-bright-yellow"},{color:"85, 85, 255",class:"ansi-bright-blue"},{color:"255, 85, 255",class:"ansi-bright-magenta"},{color:"85, 255, 255",class:"ansi-bright-cyan"},{color:"255, 255, 255",class:"ansi-bright-white"}]],e=/(https?:\/\/(?:[A-Za-z0-9#;/?:@=+$',_.!~*()[\]-]|&|%[A-Fa-f0-9]{2})+)/gm;class n{static escapeForHtml(i){return new n().escapeForHtml(i)}static linkify(i){return new n().linkify(i)}static ansiToHtml(i,a){return new n().ansiToHtml(i,a)}static ansiToJson(i,a){return new n().ansiToJson(i,a)}static ansiToText(i){return new n().ansiToText(i)}constructor(){this.fg=this.bg=this.fg_truecolor=this.bg_truecolor=null,this.bright=0,this.decorations=[]}setupPalette(){this.PALETTE_COLORS=[];for(let c=0;c<2;++c)for(let u=0;u<8;++u)this.PALETTE_COLORS.push(t[c][u].color);let i=[0,95,135,175,215,255],a=(c,u,f)=>i[c]+", "+i[u]+", "+i[f];for(let c=0;c<6;++c)for(let u=0;u<6;++u)for(let f=0;f<6;++f)this.PALETTE_COLORS.push(a(c,u,f));let o=8;for(let c=0;c<24;++c,o+=10)this.PALETTE_COLORS.push(o+", "+o+", "+o)}escapeForHtml(i){return i.replace(/[&<>\"]/gm,a=>a=="&"?"&":a=='"'?""":a=="<"?"<":a==">"?">":"")}linkify(i){return i.replace(e,a=>`<a href="${a}">${a}</a>`)}ansiToHtml(i,a){return this.process(i,a,!0)}ansiToJson(i,a){return a=a||{},a.json=!0,a.clearLine=!1,this.process(i,a,!0)}ansiToText(i){return this.process(i,{},!1)}process(i,a,o){let c=this,u=i.split(/\033\[/),f=u.shift();a==null&&(a={}),a.clearLine=/\r/.test(i);let h=u.map(m=>this.processChunk(m,a,o));if(a&&a.json){let m=c.processChunkJson("");return m.content=f,m.clearLine=a.clearLine,h.unshift(m),a.remove_empty&&(h=h.filter(g=>!g.isEmpty())),h}else h.unshift(f);return h.join("")}processChunkJson(i,a,o){a=typeof a>"u"?{}:a;let c=a.use_classes=typeof a.use_classes<"u"&&a.use_classes,u=a.key=c?"class":"color",f={content:i,fg:null,bg:null,fg_truecolor:null,bg_truecolor:null,isInverted:!1,clearLine:a.clearLine,decoration:null,decorations:[],was_processed:!1,isEmpty:()=>!f.content},h=i.match(/^([!\x3c-\x3f]*)([\d;]*)([\x20-\x2c]*[\x40-\x7e])([\s\S]*)/m);if(!h)return f;f.content=h[4];let m=h[2].split(";");if(h[1]!==""||h[3]!=="m"||!o)return f;let g=this;for(;m.length>0;){let y=m.shift(),x=parseInt(y);if(isNaN(x)||x===0)g.fg=g.bg=null,g.decorations=[];else if(x===1)g.decorations.push("bold");else if(x===2)g.decorations.push("dim");else if(x===3)g.decorations.push("italic");else if(x===4)g.decorations.push("underline");else if(x===5)g.decorations.push("blink");else if(x===7)g.decorations.push("reverse");else if(x===8)g.decorations.push("hidden");else if(x===9)g.decorations.push("strikethrough");else if(x===21)g.removeDecoration("bold");else if(x===22)g.removeDecoration("bold"),g.removeDecoration("dim");else if(x===23)g.removeDecoration("italic");else if(x===24)g.removeDecoration("underline");else if(x===25)g.removeDecoration("blink");else if(x===27)g.removeDecoration("reverse");else if(x===28)g.removeDecoration("hidden");else if(x===29)g.removeDecoration("strikethrough");else if(x===39)g.fg=null;else if(x===49)g.bg=null;else if(x>=30&&x<38)g.fg=t[0][x%10][u];else if(x>=90&&x<98)g.fg=t[1][x%10][u];else if(x>=40&&x<48)g.bg=t[0][x%10][u];else if(x>=100&&x<108)g.bg=t[1][x%10][u];else if(x===38||x===48){let S=x===38;if(m.length>=1){let k=m.shift();if(k==="5"&&m.length>=1){let T=parseInt(m.shift());if(T>=0&&T<=255)if(!c)this.PALETTE_COLORS||g.setupPalette(),S?g.fg=this.PALETTE_COLORS[T]:g.bg=this.PALETTE_COLORS[T];else{let C=T>=16?"ansi-palette-"+T:t[T>7?1:0][T%8].class;S?g.fg=C:g.bg=C}}else if(k==="2"&&m.length>=3){let T=parseInt(m.shift()),C=parseInt(m.shift()),E=parseInt(m.shift());if(T>=0&&T<=255&&C>=0&&C<=255&&E>=0&&E<=255){let R=T+", "+C+", "+E;c?S?(g.fg="ansi-truecolor",g.fg_truecolor=R):(g.bg="ansi-truecolor",g.bg_truecolor=R):S?g.fg=R:g.bg=R}}}}}return g.fg===null&&g.bg===null&&g.decorations.length===0||(f.fg=g.fg,f.bg=g.bg,f.fg_truecolor=g.fg_truecolor,f.bg_truecolor=g.bg_truecolor,f.decorations=g.decorations,f.decoration=g.decorations.slice(-1).pop()||null,f.was_processed=!0),f}processChunk(i,a,o){a=a||{};let c=this.processChunkJson(i,a,o),u=a.use_classes;if(c.decorations=c.decorations.filter(x=>{if(x==="reverse"){c.fg||(c.fg=t[0][7][u?"class":"color"]),c.bg||(c.bg=t[0][0][u?"class":"color"]);let S=c.fg;c.fg=c.bg,c.bg=S;let k=c.fg_truecolor;return c.fg_truecolor=c.bg_truecolor,c.bg_truecolor=k,c.isInverted=!0,!1}return!0}),a.json)return c;if(c.isEmpty())return"";if(!c.was_processed)return c.content;let f=[],h=[],m=[],g={},y=x=>{let S=[],k;for(k in x)x.hasOwnProperty(k)&&S.push("data-"+k+'="'+this.escapeForHtml(x[k])+'"');return S.length>0?" "+S.join(" "):""};return c.isInverted&&(g["ansi-is-inverted"]="true"),c.fg&&(u?(f.push(c.fg+"-fg"),c.fg_truecolor!==null&&(g["ansi-truecolor-fg"]=c.fg_truecolor,c.fg_truecolor=null)):f.push("color:rgb("+c.fg+")")),c.bg&&(u?(f.push(c.bg+"-bg"),c.bg_truecolor!==null&&(g["ansi-truecolor-bg"]=c.bg_truecolor,c.bg_truecolor=null)):f.push("background-color:rgb("+c.bg+")")),c.decorations.forEach(x=>{if(u){h.push("ansi-"+x);return}x==="bold"?h.push("font-weight:bold"):x==="dim"?h.push("opacity:0.5"):x==="italic"?h.push("font-style:italic"):x==="hidden"?h.push("visibility:hidden"):x==="strikethrough"?m.push("line-through"):m.push(x)}),m.length&&h.push("text-decoration:"+m.join(" ")),u?'<span class="'+f.concat(h).join(" ")+'"'+y(g)+">"+c.content+"</span>":'<span style="'+f.concat(h).join(";")+'"'+y(g)+">"+c.content+"</span>"}removeDecoration(i){const a=this.decorations.indexOf(i);a>=0&&this.decorations.splice(a,1)}}return By=n,By}var _K=RK();const $K=Nc(_K);var Hu={exports:{}},yQ;function PK(){if(yQ)return Hu.exports;yQ=1;function t(i){if(!i)return"";if(!/\r/.test(i))return i;for(i=i.replace(/\r+\n/gm,`
|
|
101
|
-
`);/\r./.test(i);)i=i.replace(/^([^\r\n]*)\r+([^\r\n]+)/gm,function(a,o,c){return c+o.slice(c.length)});return i}function e(i){for(var a=0,o=0;o<i.length;o++)i[a].length<=i[o].length&&(a=o);return a}function n(i){if(!/\r/.test(i))return i;for(var a=i.split("\r"),o=[];a.length>0;){var c=e(a);o.push(a[c]),a=a.slice(c+1)}return o.join("\r")}function r(i){if(!i)return"";if(!/\r/.test(i))return i;if(!/\n/.test(i))return n(i);i=i.replace(/\r+\n/gm,`
|
|
102
|
-
`);var a=i.lastIndexOf(`
|
|
103
|
-
`);return t(i.slice(0,a))+`
|
|
104
|
-
`+n(i.slice(a+1))}return Hu.exports=t,Hu.exports.escapeCarriageReturn=t,Hu.exports.escapeCarriageReturnSafe=r,Hu.exports}var jK=PK(),Iy={exports:{}},bQ;function MK(){return bQ||(bQ=1,(function(t){var e=(function(){var n=String.fromCharCode,r="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",i="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+-$",a={};function o(u,f){if(!a[u]){a[u]={};for(var h=0;h<u.length;h++)a[u][u.charAt(h)]=h}return a[u][f]}var c={compressToBase64:function(u){if(u==null)return"";var f=c._compress(u,6,function(h){return r.charAt(h)});switch(f.length%4){default:case 0:return f;case 1:return f+"===";case 2:return f+"==";case 3:return f+"="}},decompressFromBase64:function(u){return u==null?"":u==""?null:c._decompress(u.length,32,function(f){return o(r,u.charAt(f))})},compressToUTF16:function(u){return u==null?"":c._compress(u,15,function(f){return n(f+32)})+" "},decompressFromUTF16:function(u){return u==null?"":u==""?null:c._decompress(u.length,16384,function(f){return u.charCodeAt(f)-32})},compressToUint8Array:function(u){for(var f=c.compress(u),h=new Uint8Array(f.length*2),m=0,g=f.length;m<g;m++){var y=f.charCodeAt(m);h[m*2]=y>>>8,h[m*2+1]=y%256}return h},decompressFromUint8Array:function(u){if(u==null)return c.decompress(u);for(var f=new Array(u.length/2),h=0,m=f.length;h<m;h++)f[h]=u[h*2]*256+u[h*2+1];var g=[];return f.forEach(function(y){g.push(n(y))}),c.decompress(g.join(""))},compressToEncodedURIComponent:function(u){return u==null?"":c._compress(u,6,function(f){return i.charAt(f)})},decompressFromEncodedURIComponent:function(u){return u==null?"":u==""?null:(u=u.replace(/ /g,"+"),c._decompress(u.length,32,function(f){return o(i,u.charAt(f))}))},compress:function(u){return c._compress(u,16,function(f){return n(f)})},_compress:function(u,f,h){if(u==null)return"";var m,g,y={},x={},S="",k="",T="",C=2,E=3,R=2,$=[],P=0,_=0,M;for(M=0;M<u.length;M+=1)if(S=u.charAt(M),Object.prototype.hasOwnProperty.call(y,S)||(y[S]=E++,x[S]=!0),k=T+S,Object.prototype.hasOwnProperty.call(y,k))T=k;else{if(Object.prototype.hasOwnProperty.call(x,T)){if(T.charCodeAt(0)<256){for(m=0;m<R;m++)P=P<<1,_==f-1?(_=0,$.push(h(P)),P=0):_++;for(g=T.charCodeAt(0),m=0;m<8;m++)P=P<<1|g&1,_==f-1?(_=0,$.push(h(P)),P=0):_++,g=g>>1}else{for(g=1,m=0;m<R;m++)P=P<<1|g,_==f-1?(_=0,$.push(h(P)),P=0):_++,g=0;for(g=T.charCodeAt(0),m=0;m<16;m++)P=P<<1|g&1,_==f-1?(_=0,$.push(h(P)),P=0):_++,g=g>>1}C--,C==0&&(C=Math.pow(2,R),R++),delete x[T]}else for(g=y[T],m=0;m<R;m++)P=P<<1|g&1,_==f-1?(_=0,$.push(h(P)),P=0):_++,g=g>>1;C--,C==0&&(C=Math.pow(2,R),R++),y[k]=E++,T=String(S)}if(T!==""){if(Object.prototype.hasOwnProperty.call(x,T)){if(T.charCodeAt(0)<256){for(m=0;m<R;m++)P=P<<1,_==f-1?(_=0,$.push(h(P)),P=0):_++;for(g=T.charCodeAt(0),m=0;m<8;m++)P=P<<1|g&1,_==f-1?(_=0,$.push(h(P)),P=0):_++,g=g>>1}else{for(g=1,m=0;m<R;m++)P=P<<1|g,_==f-1?(_=0,$.push(h(P)),P=0):_++,g=0;for(g=T.charCodeAt(0),m=0;m<16;m++)P=P<<1|g&1,_==f-1?(_=0,$.push(h(P)),P=0):_++,g=g>>1}C--,C==0&&(C=Math.pow(2,R),R++),delete x[T]}else for(g=y[T],m=0;m<R;m++)P=P<<1|g&1,_==f-1?(_=0,$.push(h(P)),P=0):_++,g=g>>1;C--,C==0&&(C=Math.pow(2,R),R++)}for(g=2,m=0;m<R;m++)P=P<<1|g&1,_==f-1?(_=0,$.push(h(P)),P=0):_++,g=g>>1;for(;;)if(P=P<<1,_==f-1){$.push(h(P));break}else _++;return $.join("")},decompress:function(u){return u==null?"":u==""?null:c._decompress(u.length,32768,function(f){return u.charCodeAt(f)})},_decompress:function(u,f,h){var m=[],g=4,y=4,x=3,S="",k=[],T,C,E,R,$,P,_,M={val:h(0),position:f,index:1};for(T=0;T<3;T+=1)m[T]=T;for(E=0,$=Math.pow(2,2),P=1;P!=$;)R=M.val&M.position,M.position>>=1,M.position==0&&(M.position=f,M.val=h(M.index++)),E|=(R>0?1:0)*P,P<<=1;switch(E){case 0:for(E=0,$=Math.pow(2,8),P=1;P!=$;)R=M.val&M.position,M.position>>=1,M.position==0&&(M.position=f,M.val=h(M.index++)),E|=(R>0?1:0)*P,P<<=1;_=n(E);break;case 1:for(E=0,$=Math.pow(2,16),P=1;P!=$;)R=M.val&M.position,M.position>>=1,M.position==0&&(M.position=f,M.val=h(M.index++)),E|=(R>0?1:0)*P,P<<=1;_=n(E);break;case 2:return""}for(m[3]=_,C=_,k.push(_);;){if(M.index>u)return"";for(E=0,$=Math.pow(2,x),P=1;P!=$;)R=M.val&M.position,M.position>>=1,M.position==0&&(M.position=f,M.val=h(M.index++)),E|=(R>0?1:0)*P,P<<=1;switch(_=E){case 0:for(E=0,$=Math.pow(2,8),P=1;P!=$;)R=M.val&M.position,M.position>>=1,M.position==0&&(M.position=f,M.val=h(M.index++)),E|=(R>0?1:0)*P,P<<=1;m[y++]=n(E),_=y-1,g--;break;case 1:for(E=0,$=Math.pow(2,16),P=1;P!=$;)R=M.val&M.position,M.position>>=1,M.position==0&&(M.position=f,M.val=h(M.index++)),E|=(R>0?1:0)*P,P<<=1;m[y++]=n(E),_=y-1,g--;break;case 2:return k.join("")}if(g==0&&(g=Math.pow(2,x),x++),m[_])S=m[_];else if(_===y)S=C+C.charAt(0);else return null;k.push(S),m[y++]=C+S.charAt(0),g--,C=S,g==0&&(g=Math.pow(2,x),x++)}}};return c})();t!=null?t.exports=e:typeof angular<"u"&&angular!=null&&angular.module("LZString",[]).factory("LZString",function(){return e})})(Iy)),Iy.exports}var NK=MK();const DK=Nc(NK);var ue=function(){return ue=Object.assign||function(e){for(var n,r=1,i=arguments.length;r<i;r++){n=arguments[r];for(var a in n)Object.prototype.hasOwnProperty.call(n,a)&&(e[a]=n[a])}return e},ue.apply(this,arguments)};function Sn(t,e){var n={};for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&e.indexOf(r)<0&&(n[r]=t[r]);if(t!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,r=Object.getOwnPropertySymbols(t);i<r.length;i++)e.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(t,r[i])&&(n[r[i]]=t[r[i]]);return n}function _s(t,e,n,r){function i(a){return a instanceof n?a:new n(function(o){o(a)})}return new(n||(n=Promise))(function(a,o){function c(h){try{f(r.next(h))}catch(m){o(m)}}function u(h){try{f(r.throw(h))}catch(m){o(m)}}function f(h){h.done?a(h.value):i(h.value).then(c,u)}f((r=r.apply(t,[])).next())})}function $s(t,e){var n={label:0,sent:function(){if(a[0]&1)throw a[1];return a[1]},trys:[],ops:[]},r,i,a,o;return o={next:c(0),throw:c(1),return:c(2)},typeof Symbol=="function"&&(o[Symbol.iterator]=function(){return this}),o;function c(f){return function(h){return u([f,h])}}function u(f){if(r)throw new TypeError("Generator is already executing.");for(;n;)try{if(r=1,i&&(a=f[0]&2?i.return:f[0]?i.throw||((a=i.return)&&a.call(i),0):i.next)&&!(a=a.call(i,f[1])).done)return a;switch(i=0,a&&(f=[f[0]&2,a.value]),f[0]){case 0:case 1:a=f;break;case 4:return n.label++,{value:f[1],done:!1};case 5:n.label++,i=f[1],f=[0];continue;case 7:f=n.ops.pop(),n.trys.pop();continue;default:if(a=n.trys,!(a=a.length>0&&a[a.length-1])&&(f[0]===6||f[0]===2)){n=0;continue}if(f[0]===3&&(!a||f[1]>a[0]&&f[1]<a[3])){n.label=f[1];break}if(f[0]===6&&n.label<a[1]){n.label=a[1],a=f;break}if(a&&n.label<a[2]){n.label=a[2],n.ops.push(f);break}a[2]&&n.ops.pop(),n.trys.pop();continue}f=e.call(t,n)}catch(h){f=[6,h],i=0}finally{r=a=0}if(f[0]&5)throw f[1];return{value:f[0]?f[1]:void 0,done:!0}}}function Fn(t,e,n){if(n||arguments.length===2)for(var r=0,i=e.length,a;r<i;r++)(a||!(r in e))&&(a||(a=Array.prototype.slice.call(e,0,r)),a[r]=e[r]);return t.concat(a||Array.prototype.slice.call(e))}var zi=function(t){return v.jsx("svg",ue({fill:"currentColor",height:"16",viewBox:"0 0 16 16",width:"16",xmlns:"http://www.w3.org/2000/svg"},t))},zK=function(){return v.jsxs(zi,{viewBox:"0 0 48 48",children:[v.jsx("title",{children:"Sign in"}),v.jsx("path",{d:"M9 42q-1.2 0-2.1-.9Q6 40.2 6 39V9q0-1.2.9-2.1Q7.8 6 9 6h14.55v3H9v30h14.55v3Zm24.3-9.25-2.15-2.15 5.1-5.1h-17.5v-3h17.4l-5.1-5.1 2.15-2.15 8.8 8.8Z"})]})},LK=function(){return v.jsxs(zi,{viewBox:"0 0 48 48",children:[v.jsx("title",{children:"Sign out"}),v.jsx("path",{d:"M9 42q-1.2 0-2.1-.9Q6 40.2 6 39V9q0-1.2.9-2.1Q7.8 6 9 6h14.55v3H9v30h14.55v3Zm24.3-9.25-2.15-2.15 5.1-5.1h-17.5v-3h17.4l-5.1-5.1 2.15-2.15 8.8 8.8Z"})]})},mg=function(){return v.jsxs(zi,{fill:"none",stroke:"currentColor",children:[v.jsx("title",{children:"Restart script"}),v.jsx("path",{d:"M8 2C4.68629 2 2 4.68629 2 8C2 10.0946 3.07333 11.9385 4.7 13.0118",strokeLinecap:"round"}),v.jsx("path",{d:"M14.0005 7.9998C14.0005 5.82095 12.8391 3.91335 11.1016 2.8623",strokeLinecap:"round"}),v.jsx("path",{d:"M14.0003 2.3335H11.167C10.8908 2.3335 10.667 2.55735 10.667 2.8335V5.66683",strokeLinecap:"round"}),v.jsx("path",{d:"M1.99967 13.6665L4.83301 13.6665C5.10915 13.6665 5.33301 13.4426 5.33301 13.1665L5.33301 10.3332",strokeLinecap:"round"}),v.jsx("path",{d:"M10 10L12 12L10 14",strokeLinecap:"round",strokeLinejoin:"round"}),v.jsx("path",{d:"M14.667 14L12.667 14",strokeLinecap:"round",strokeLinejoin:"round"})]})},ZK=function(){return v.jsxs(zi,{children:[v.jsx("title",{children:"Run sandbox"}),v.jsx("path",{d:"M11.0792 8.1078C11.2793 8.25007 11.27 8.55012 11.0616 8.67981L6.02535 11.8135C5.79638 11.956 5.5 11.7913 5.5 11.5216L5.5 8.40703L5.5 4.80661C5.5 4.52735 5.81537 4.36463 6.04296 4.52647L11.0792 8.1078Z"})]})},VK=function(){return v.jsxs(zi,{children:[v.jsx("title",{children:"Click to go back"}),v.jsx("path",{d:"M9.64645 12.3536C9.84171 12.5488 10.1583 12.5488 10.3536 12.3536C10.5488 12.1583 10.5488 11.8417 10.3536 11.6464L9.64645 12.3536ZM10.3536 4.35355C10.5488 4.15829 10.5488 3.84171 10.3536 3.64644C10.1583 3.45118 9.84171 3.45118 9.64645 3.64644L10.3536 4.35355ZM6.07072 7.92929L5.71716 7.57573L6.07072 7.92929ZM10.3536 11.6464L6.42427 7.71716L5.71716 8.42426L9.64645 12.3536L10.3536 11.6464ZM6.42427 8.28284L10.3536 4.35355L9.64645 3.64644L5.71716 7.57573L6.42427 8.28284ZM6.42427 7.71716C6.58048 7.87337 6.58048 8.12663 6.42427 8.28284L5.71716 7.57573C5.48285 7.81005 5.48285 8.18995 5.71716 8.42426L6.42427 7.71716Z"})]})},XK=function(){return v.jsxs(zi,{children:[v.jsx("title",{children:"Click to go forward"}),v.jsx("path",{d:"M6.35355 3.64645C6.15829 3.45118 5.84171 3.45118 5.64645 3.64645C5.45118 3.84171 5.45118 4.15829 5.64645 4.35355L6.35355 3.64645ZM5.64645 11.6464C5.45118 11.8417 5.45118 12.1583 5.64645 12.3536C5.84171 12.5488 6.15829 12.5488 6.35355 12.3536L5.64645 11.6464ZM9.92929 8.07071L10.2828 8.42426L9.92929 8.07071ZM5.64645 4.35355L9.57574 8.28284L10.2828 7.57574L6.35355 3.64645L5.64645 4.35355ZM9.57574 7.71716L5.64645 11.6464L6.35355 12.3536L10.2828 8.42426L9.57574 7.71716ZM9.57574 8.28284C9.41952 8.12663 9.41953 7.87337 9.57574 7.71716L10.2828 8.42426C10.5172 8.18995 10.5172 7.81005 10.2828 7.57574L9.57574 8.28284Z"})]})},I5=function(){return v.jsxs(zi,{children:[v.jsx("title",{children:"Refresh preview"}),v.jsx("path",{clipRule:"evenodd",d:"M3.83325 7.99992C3.83325 5.69867 5.69853 3.83325 7.99934 3.83325C9.81246 3.83325 11.3563 4.99195 11.9285 6.61097C11.9396 6.6425 11.9536 6.67221 11.97 6.69992H8.80005C8.52391 6.69992 8.30005 6.92378 8.30005 7.19992C8.30005 7.47606 8.52391 7.69992 8.80005 7.69992H12.5667C12.8981 7.69992 13.1667 7.43129 13.1667 7.09992V3.33325C13.1667 3.05711 12.9429 2.83325 12.6667 2.83325C12.3906 2.83325 12.1667 3.05711 12.1667 3.33325V4.94608C11.2268 3.66522 9.7106 2.83325 7.99934 2.83325C5.14613 2.83325 2.83325 5.14651 2.83325 7.99992C2.83325 10.8533 5.14613 13.1666 7.99934 13.1666C9.91218 13.1666 11.5815 12.1266 12.474 10.5836C12.6123 10.3446 12.5306 10.0387 12.2915 9.90044C12.0525 9.76218 11.7466 9.84387 11.6084 10.0829C10.8873 11.3296 9.54072 12.1666 7.99934 12.1666C5.69853 12.1666 3.83325 10.3012 3.83325 7.99992Z",fillRule:"evenodd"})]})},BK=function(){return v.jsxs(zi,{fill:"none",stroke:"currentColor",children:[v.jsx("title",{children:"Clean"}),v.jsx("circle",{cx:"7.99998",cy:"8.00004",r:"4.66667",strokeLinecap:"round"}),v.jsx("path",{d:"M4.66669 4.66663L11.3334 11.3333"})]})},IK=function(){return v.jsxs(zi,{fill:"none",stroke:"currentColor",children:[v.jsx("title",{children:"Open on CodeSandbox"}),v.jsx("path",{d:"M6.66665 3.33337H4.33331C3.78103 3.33337 3.33331 3.78109 3.33331 4.33337V11.6667C3.33331 12.219 3.78103 12.6667 4.33331 12.6667H11.6666C12.2189 12.6667 12.6666 12.219 12.6666 11.6667V9.33337",strokeLinecap:"round"}),v.jsx("path",{d:"M10 3.33337H12.5667C12.6219 3.33337 12.6667 3.37815 12.6667 3.43337V6.00004",strokeLinecap:"round"}),v.jsx("path",{d:"M7.33331 8.66668L12.5333 3.46667",strokeLinecap:"round"})]})},qK=function(){return v.jsxs(zi,{stroke:"currentColor",children:[v.jsx("title",{children:"Close file"}),v.jsx("path",{d:"M12 4L4 12",strokeLinecap:"round"}),v.jsx("path",{d:"M4 4L12 12",strokeLinecap:"round"})]})},UK=function(){return v.jsxs(zi,{children:[v.jsx("title",{children:"Open browser console"}),v.jsx("path",{d:"M5.65871 3.62037C5.44905 3.44066 5.1334 3.46494 4.95368 3.6746C4.77397 3.88427 4.79825 4.19992 5.00792 4.37963L5.65871 3.62037ZM5.00792 11.6204C4.79825 11.8001 4.77397 12.1157 4.95368 12.3254C5.1334 12.5351 5.44905 12.5593 5.65871 12.3796L5.00792 11.6204ZM9.9114 7.92407L10.2368 7.54445L9.9114 7.92407ZM5.00792 4.37963L9.586 8.3037L10.2368 7.54445L5.65871 3.62037L5.00792 4.37963ZM9.586 7.6963L5.00792 11.6204L5.65871 12.3796L10.2368 8.45555L9.586 7.6963ZM9.586 8.3037C9.39976 8.14407 9.39976 7.85594 9.586 7.6963L10.2368 8.45555C10.5162 8.2161 10.5162 7.7839 10.2368 7.54445L9.586 8.3037Z"}),v.jsx("path",{d:"M10 11.5C9.72386 11.5 9.5 11.7239 9.5 12C9.5 12.2761 9.72386 12.5 10 12.5V11.5ZM14.6667 12.5C14.9428 12.5 15.1667 12.2761 15.1667 12C15.1667 11.7239 14.9428 11.5 14.6667 11.5V12.5ZM10 12.5H14.6667V11.5H10V12.5Z"})]})},qy,dc={colors:{surface1:"#ffffff",surface2:"#EFEFEF",surface3:"#F3F3F3",disabled:"#C5C5C5",base:"#323232",clickable:"#808080",hover:"#4D4D4D",accent:"#3973E0",error:"#EA3323",errorSurface:"#FCF1F0",warning:"#6A4516",warningSurface:"#FEF2C0"},syntax:{plain:"#151515",comment:{color:"#999",fontStyle:"italic"},keyword:"#7C5AE3",tag:"#0971F1",punctuation:"#3B3B3B",definition:"#85A600",property:"#3B3B3B",static:"#3B3B3B",string:"#2E6BD0"},font:{body:'-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol"',mono:'"Fira Mono", "DejaVu Sans Mono", Menlo, Consolas, "Liberation Mono", Monaco, "Lucida Console", monospace',size:"13px",lineHeight:"20px"}},Qb={colors:{surface1:"#151515",surface2:"#252525",surface3:"#2F2F2F",disabled:"#4D4D4D",base:"#808080",clickable:"#999999",hover:"#C5C5C5",accent:"#E5E5E5",error:"#FFB4A6",errorSurface:"#690000",warning:"#E7C400",warningSurface:"#3A3000"},syntax:{plain:"#FFFFFF",comment:{color:"#757575",fontStyle:"italic"},keyword:"#77B7D7",tag:"#DFAB5C",punctuation:"#ffffff",definition:"#86D9CA",property:"#77B7D7",static:"#C64640",string:"#977CDC"},font:{body:'-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol"',mono:'"Fira Mono", "DejaVu Sans Mono", Menlo, Consolas, "Liberation Mono", Monaco, "Lucida Console", monospace',size:"13px",lineHeight:"20px"}},YK={light:dc,dark:Qb,auto:typeof window<"u"&&!((qy=window?.matchMedia)===null||qy===void 0)&&qy.call(window,"(prefers-color-scheme: dark)").matches?Qb:dc},dm=function(t){var e=t.lastIndexOf("/");return t.slice(e+1)},FK=function(t,e){var n=(t[0]==="/"?t.slice(1):t).split("/"),r=[];if(n.length===1)r.unshift(n[0]);else for(var i=0;i<e.length;i++)for(var a=e[i].split("/"),o=1;o<=n.length;o++){var c=n[n.length-o],u=a[a.length-o];if(r.length<o&&r.unshift(c),c!==u)break}return r.length<n.length&&r.unshift(".."),r.join("/")},xQ=function(t){var e=0,n=0,r=0;if(t.startsWith("#")){if(t.length<7)return!0;e=parseInt(t.substr(1,2),16),n=parseInt(t.substr(3,2),16),r=parseInt(t.substr(5,2),16)}else{var i=t.replace("rgb(","").replace("rgba(","").replace(")","").split(",");if(i.length<3)return!0;e=parseInt(i[0],10),n=parseInt(i[1],10),r=parseInt(i[2],10)}var a=(e*299+n*587+r*114)/1e3;return a<128},WK=0,Qc=function(){var t=+(Date.now().toString(10).substr(0,4)+WK++);return t.toString(16)},Nd,jt="sp",GK=(Nd=w9({prefix:jt}),Nd.createTheme),Ee=Nd.css;Nd.getCssText;var q5=Nd.keyframes,HK={space:new Array(11).fill(" ").reduce(function(t,e,n){var r;return ue(ue({},t),(r={},r[n+1]="".concat((n+1)*4,"px"),r))},{}),border:{radius:"4px"},layout:{height:"300px",headerHeight:"40px"},transitions:{default:"150ms ease"},zIndices:{base:"1",overlay:"2",top:"3"}},KK=function(t){var e=Object.entries(t.syntax),n=e.reduce(function(r,i){var a,o=i[0],c=i[1],u=(a={},a["color-".concat(o)]=c,a);return typeof c=="object"&&(u=Object.entries(c).reduce(function(f,h){var m,g=h[0],y=h[1];return ue(ue({},f),(m={},m["".concat(g,"-").concat(o)]=y,m))},{})),ue(ue({},r),u)},{});return ue(ue({},HK),{colors:t.colors,font:t.font,syntax:n})},JK=function(t){var e,n,r,i,a;t===void 0&&(t="light");var o="default";if(typeof t=="string"){var c=YK[t];if(!c)throw new Error("[sandpack-react]: invalid theme '".concat(t,"' provided."));return{theme:c,id:t,mode:xQ(c.colors.surface1)?"dark":"light"}}var u=xQ((n=(e=t?.colors)===null||e===void 0?void 0:e.surface1)!==null&&n!==void 0?n:dc.colors.surface1)?"dark":"light",f=u==="dark"?Qb:dc,h=ue(ue({},f.colors),(r=t?.colors)!==null&&r!==void 0?r:{}),m=ue(ue({},f.syntax),(i=t?.syntax)!==null&&i!==void 0?i:{}),g=ue(ue({},f.font),(a=t?.font)!==null&&a!==void 0?a:{}),y={colors:h,syntax:m,font:g},x=t?eJ(JSON.stringify(y)):o;return{theme:y,id:"sp-".concat(x),mode:u}},eJ=function(t){for(var e=0,n=0;n<t.length;e&=e)e=31*e+t.charCodeAt(n++);return Math.abs(e)},SQ=function(){return""};SQ.toString=SQ;var U5=w.createContext({}),tJ=function(t){var e=t.children,n=t.classes;return v.jsx(U5.Provider,{value:n||{},children:e})},Nn=function(){var t=w.useContext(U5);return function(n,r){r===void 0&&(r=[]);var i="".concat(jt,"-").concat(n);return nJ.apply(void 0,Fn(Fn([],r,!1),[i,t[i]],!1))}},nJ=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];return t.filter(Boolean).join(" ")},rJ=Ee({all:"initial",fontSize:"$font$size",fontFamily:"$font$body",display:"block",boxSizing:"border-box",textRendering:"optimizeLegibility",WebkitTapHighlightColor:"transparent",WebkitFontSmoothing:"subpixel-antialiased",variants:{variant:{dark:{colorScheme:"dark"},light:{colorScheme:"light"}}},"@media screen and (min-resolution: 2dppx)":{WebkitFontSmoothing:"antialiased",MozOsxFontSmoothing:"grayscale"},"*":{boxSizing:"border-box"},".sp-wrapper:focus":{outline:"0"}}),w1=w.createContext({theme:dc,id:"light",mode:"light"}),iJ=function(t){var e=t.theme,n=t.children,r=t.className,i=Sn(t,["theme","children","className"]),a=w.useState(e),o=a[0],c=a[1],u=JK(o),f=u.theme,h=u.id,m=u.mode,g=Nn(),y=w.useMemo(function(){return GK(h,KK(f))},[f,h]);return w.useEffect(function(){if(e!=="auto"){c(e);return}var x=function(S){var k=S.matches;c(k?"dark":"light")};return window.matchMedia("(prefers-color-scheme: dark)").addEventListener("change",x),function(){window.matchMedia("(prefers-color-scheme: dark)").removeEventListener("change",x)}},[e]),v.jsx(w1.Provider,{value:{theme:f,id:h,mode:m},children:v.jsx("div",ue({className:g("wrapper",[y,rJ({variant:m}),r])},i,{children:n}))})};w1.Consumer;var hn={"/styles.css":{code:`body {
|
|
105
|
-
font-family: sans-serif;
|
|
106
|
-
-webkit-font-smoothing: auto;
|
|
107
|
-
-moz-font-smoothing: auto;
|
|
108
|
-
-moz-osx-font-smoothing: grayscale;
|
|
109
|
-
font-smoothing: auto;
|
|
110
|
-
text-rendering: optimizeLegibility;
|
|
111
|
-
font-smooth: always;
|
|
112
|
-
-webkit-tap-highlight-color: transparent;
|
|
113
|
-
-webkit-touch-callout: none;
|
|
114
|
-
}
|
|
115
|
-
|
|
116
|
-
h1 {
|
|
117
|
-
font-size: 1.5rem;
|
|
118
|
-
}`}},aJ={files:{"/src/styles.css":hn["/styles.css"],"/src/pages/index.astro":{code:`---
|
|
119
|
-
import "../styles.css";
|
|
120
|
-
const data = "world";
|
|
121
|
-
---
|
|
122
|
-
|
|
123
|
-
<h1>Hello {data}</h1>
|
|
124
|
-
|
|
125
|
-
<style>
|
|
126
|
-
h1 {
|
|
127
|
-
font-size: 1.5rem;
|
|
128
|
-
}
|
|
129
|
-
</style>`},".env":{code:'ASTRO_TELEMETRY_DISABLED="1"'},"/package.json":{code:JSON.stringify({dependencies:{astro:"^1.6.12","esbuild-wasm":"^0.15.16"},scripts:{dev:"astro dev",start:"astro dev",build:"astro build",preview:"astro preview",astro:"astro"}})}},main:"/src/pages/index.astro",environment:"node"},sJ={files:ue(ue({},hn),{"/pages/_app.js":{code:`import '../styles.css'
|
|
130
|
-
|
|
131
|
-
export default function MyApp({ Component, pageProps }) {
|
|
132
|
-
return <Component {...pageProps} />
|
|
133
|
-
}`},"/pages/index.js":{code:`export default function Home({ data }) {
|
|
134
|
-
return (
|
|
135
|
-
<div>
|
|
136
|
-
<h1>Hello {data}</h1>
|
|
137
|
-
</div>
|
|
138
|
-
);
|
|
139
|
-
}
|
|
140
|
-
|
|
141
|
-
export function getServerSideProps() {
|
|
142
|
-
return {
|
|
143
|
-
props: { data: "world" },
|
|
144
|
-
}
|
|
145
|
-
}
|
|
146
|
-
`},"/next.config.js":{code:`/** @type {import('next').NextConfig} */
|
|
147
|
-
const nextConfig = {
|
|
148
|
-
reactStrictMode: true,
|
|
149
|
-
swcMinify: true,
|
|
150
|
-
}
|
|
151
|
-
|
|
152
|
-
module.exports = nextConfig
|
|
153
|
-
`},"/package.json":{code:JSON.stringify({name:"my-app",version:"0.1.0",private:!0,scripts:{dev:"NEXT_TELEMETRY_DISABLED=1 next dev",build:"next build",start:"next start",lint:"next lint"},dependencies:{next:"12.1.6",react:"18.2.0","react-dom":"18.2.0","@next/swc-wasm-nodejs":"12.1.6"}})}}),main:"/pages/index.js",environment:"node"},oJ={files:{"/index.js":{code:`const http = require('http');
|
|
154
|
-
|
|
155
|
-
const hostname = '127.0.0.1';
|
|
156
|
-
const port = 3000;
|
|
157
|
-
|
|
158
|
-
const server = http.createServer((req, res) => {
|
|
159
|
-
res.statusCode = 200;
|
|
160
|
-
res.setHeader('Content-Type', 'text/html');
|
|
161
|
-
res.end('Hello world');
|
|
162
|
-
});
|
|
163
|
-
|
|
164
|
-
server.listen(port, hostname, () => {
|
|
165
|
-
console.log(\`Server running at http://\${hostname}:\${port}/\`);
|
|
166
|
-
});`},"/package.json":{code:JSON.stringify({dependencies:{},scripts:{start:"node index.js"},main:"index.js"})}},main:"/index.js",environment:"node"},lJ={files:ue(ue({},hn),{"/index.js":{code:`import "./styles.css";
|
|
167
|
-
|
|
168
|
-
document.getElementById("app").innerHTML = \`
|
|
169
|
-
<h1>Hello world</h1>
|
|
170
|
-
\`;
|
|
171
|
-
`},"/index.html":{code:`<!DOCTYPE html>
|
|
172
|
-
<html lang="en">
|
|
173
|
-
<head>
|
|
174
|
-
<meta charset="UTF-8" />
|
|
175
|
-
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
176
|
-
<title>Vite App</title>
|
|
177
|
-
</head>
|
|
178
|
-
<body>
|
|
179
|
-
<div id="app"></div>
|
|
180
|
-
<script type="module" src="/index.js"><\/script>
|
|
181
|
-
</body>
|
|
182
|
-
</html>
|
|
183
|
-
`},"/package.json":{code:JSON.stringify({scripts:{dev:"vite",build:"vite build",preview:"vite preview"},devDependencies:{vite:"4.1.4","esbuild-wasm":"0.17.12"}})}}),main:"/index.js",environment:"node"},cJ={files:ue(ue({},hn),{"/App.jsx":{code:`export default function App() {
|
|
184
|
-
const data = "world"
|
|
185
|
-
|
|
186
|
-
return <h1>Hello {data}</h1>
|
|
187
|
-
}
|
|
188
|
-
`},"/index.jsx":{code:`import { render } from "preact";
|
|
189
|
-
import "./styles.css";
|
|
190
|
-
|
|
191
|
-
import App from "./App";
|
|
192
|
-
|
|
193
|
-
const root = document.getElementById("root");
|
|
194
|
-
render(<App />, root);
|
|
195
|
-
`},"/index.html":{code:`<!DOCTYPE html>
|
|
196
|
-
<html lang="en">
|
|
197
|
-
<head>
|
|
198
|
-
<meta charset="UTF-8" />
|
|
199
|
-
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
200
|
-
<title>Vite App</title>
|
|
201
|
-
</head>
|
|
202
|
-
<body>
|
|
203
|
-
<div id="root"></div>
|
|
204
|
-
<script type="module" src="/index.jsx"><\/script>
|
|
205
|
-
</body>
|
|
206
|
-
</html>
|
|
207
|
-
`},"/package.json":{code:JSON.stringify({scripts:{dev:"vite",build:"vite build",preview:"vite preview"},dependencies:{preact:"^10.16.0"},devDependencies:{"@preact/preset-vite":"^2.5.0",vite:"4.1.4","esbuild-wasm":"0.17.12"}})},"/vite.config.js":{code:`import { defineConfig } from "vite";
|
|
208
|
-
import preact from '@preact/preset-vite'
|
|
209
|
-
|
|
210
|
-
// https://vitejs.dev/config/
|
|
211
|
-
export default defineConfig({
|
|
212
|
-
plugins: [preact()],
|
|
213
|
-
});
|
|
214
|
-
`}}),main:"/App.jsx",environment:"node"},uJ={files:ue(ue({},hn),{"/App.tsx":{code:`export default function App() {
|
|
215
|
-
const data: string = "world"
|
|
216
|
-
|
|
217
|
-
return <h1>Hello {data}</h1>
|
|
218
|
-
}
|
|
219
|
-
`},"/index.tsx":{code:`import { render } from "preact";
|
|
220
|
-
import "./styles.css";
|
|
221
|
-
|
|
222
|
-
import App from "./App";
|
|
223
|
-
|
|
224
|
-
const root = document.getElementById("root") as HTMLElement;
|
|
225
|
-
render(<App />, root);
|
|
226
|
-
`},"/index.html":{code:`<!DOCTYPE html>
|
|
227
|
-
<html lang="en">
|
|
228
|
-
<head>
|
|
229
|
-
<meta charset="UTF-8" />
|
|
230
|
-
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
231
|
-
<title>Vite App</title>
|
|
232
|
-
</head>
|
|
233
|
-
<body>
|
|
234
|
-
<div id="root"></div>
|
|
235
|
-
<script type="module" src="/index.tsx"><\/script>
|
|
236
|
-
</body>
|
|
237
|
-
</html>
|
|
238
|
-
`},"/tsconfig.json":{code:JSON.stringify({compilerOptions:{target:"ESNext",useDefineForClassFields:!0,lib:["DOM","DOM.Iterable","ESNext"],allowJs:!1,skipLibCheck:!0,esModuleInterop:!1,allowSyntheticDefaultImports:!0,strict:!0,forceConsistentCasingInFileNames:!0,module:"ESNext",moduleResolution:"Node",resolveJsonModule:!0,isolatedModules:!0,noEmit:!0,jsx:"react-jsx",jsxImportSource:"preact"},include:["src"],references:[{path:"./tsconfig.node.json"}]},null,2)},"/tsconfig.node.json":{code:JSON.stringify({compilerOptions:{composite:!0,module:"ESNext",moduleResolution:"Node",allowSyntheticDefaultImports:!0},include:["vite.config.ts"]},null,2)},"/package.json":{code:JSON.stringify({scripts:{dev:"vite",build:"tsc && vite build",preview:"vite preview"},dependencies:{preact:"^10.16.0"},devDependencies:{"@preact/preset-vite":"^2.5.0",typescript:"^4.9.5",vite:"4.1.4","esbuild-wasm":"^0.17.12"}},null,2)},"/vite-env.d.ts":{code:'/// <reference types="vite/client" />'},"/vite.config.ts":{code:`import { defineConfig } from 'vite'
|
|
239
|
-
import preact from '@preact/preset-vite'
|
|
240
|
-
|
|
241
|
-
// https://vitejs.dev/config/
|
|
242
|
-
export default defineConfig({
|
|
243
|
-
plugins: [preact()],
|
|
244
|
-
})
|
|
245
|
-
`}}),main:"/App.tsx",environment:"node"},dJ={files:ue(ue({},hn),{"/App.jsx":{code:`export default function App() {
|
|
246
|
-
const data = "world"
|
|
247
|
-
|
|
248
|
-
return <h1>Hello {data}</h1>
|
|
249
|
-
}
|
|
250
|
-
`},"/index.jsx":{code:`import { StrictMode } from "react";
|
|
251
|
-
import { createRoot } from "react-dom/client";
|
|
252
|
-
import "./styles.css";
|
|
253
|
-
|
|
254
|
-
import App from "./App";
|
|
255
|
-
|
|
256
|
-
const root = createRoot(document.getElementById("root"));
|
|
257
|
-
root.render(
|
|
258
|
-
<StrictMode>
|
|
259
|
-
<App />
|
|
260
|
-
</StrictMode>
|
|
261
|
-
);`},"/index.html":{code:`<!DOCTYPE html>
|
|
262
|
-
<html lang="en">
|
|
263
|
-
<head>
|
|
264
|
-
<meta charset="UTF-8" />
|
|
265
|
-
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
266
|
-
<title>Vite App</title>
|
|
267
|
-
</head>
|
|
268
|
-
<body>
|
|
269
|
-
<div id="root"></div>
|
|
270
|
-
<script type="module" src="/index.jsx"><\/script>
|
|
271
|
-
</body>
|
|
272
|
-
</html>
|
|
273
|
-
`},"/package.json":{code:JSON.stringify({scripts:{dev:"vite",build:"vite build",preview:"vite preview"},dependencies:{react:"^18.2.0","react-dom":"^18.2.0"},devDependencies:{"@vitejs/plugin-react":"3.1.0",vite:"4.1.4","esbuild-wasm":"0.17.12"}})},"/vite.config.js":{code:`import { defineConfig } from "vite";
|
|
274
|
-
import react from "@vitejs/plugin-react";
|
|
275
|
-
|
|
276
|
-
// https://vitejs.dev/config/
|
|
277
|
-
export default defineConfig({
|
|
278
|
-
plugins: [react()],
|
|
279
|
-
});
|
|
280
|
-
`}}),main:"/App.jsx",environment:"node"},fJ={files:ue(ue({},hn),{"/App.tsx":{code:`export default function App() {
|
|
281
|
-
const data: string = "world"
|
|
282
|
-
|
|
283
|
-
return <h1>Hello {data}</h1>
|
|
284
|
-
}
|
|
285
|
-
`},"/index.tsx":{code:`import { StrictMode } from "react";
|
|
286
|
-
import { createRoot } from "react-dom/client";
|
|
287
|
-
import "./styles.css";
|
|
288
|
-
|
|
289
|
-
import App from "./App";
|
|
290
|
-
import React from "react";
|
|
291
|
-
|
|
292
|
-
const root = createRoot(document.getElementById("root") as HTMLElement);
|
|
293
|
-
root.render(
|
|
294
|
-
<StrictMode>
|
|
295
|
-
<App />
|
|
296
|
-
</StrictMode>
|
|
297
|
-
);
|
|
298
|
-
`},"/index.html":{code:`<!DOCTYPE html>
|
|
299
|
-
<html lang="en">
|
|
300
|
-
<head>
|
|
301
|
-
<meta charset="UTF-8" />
|
|
302
|
-
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
303
|
-
<title>Vite App</title>
|
|
304
|
-
</head>
|
|
305
|
-
<body>
|
|
306
|
-
<div id="root"></div>
|
|
307
|
-
<script type="module" src="/index.tsx"><\/script>
|
|
308
|
-
</body>
|
|
309
|
-
</html>
|
|
310
|
-
`},"/tsconfig.json":{code:JSON.stringify({compilerOptions:{target:"ESNext",useDefineForClassFields:!0,lib:["DOM","DOM.Iterable","ESNext"],allowJs:!1,skipLibCheck:!0,esModuleInterop:!1,allowSyntheticDefaultImports:!0,strict:!0,forceConsistentCasingInFileNames:!0,module:"ESNext",moduleResolution:"Node",resolveJsonModule:!0,isolatedModules:!0,noEmit:!0,jsx:"react-jsx"},include:["src"],references:[{path:"./tsconfig.node.json"}]},null,2)},"/tsconfig.node.json":{code:JSON.stringify({compilerOptions:{composite:!0,module:"ESNext",moduleResolution:"Node",allowSyntheticDefaultImports:!0},include:["vite.config.ts"]},null,2)},"/package.json":{code:JSON.stringify({scripts:{dev:"vite",build:"tsc && vite build",preview:"vite preview"},dependencies:{react:"^19.0.0","react-dom":"^19.0.0"},devDependencies:{"@types/react":"^19.0.8","@types/react-dom":"^19.0.3","@vitejs/plugin-react":"^4.3.4",typescript:"^4.9.5",vite:"4.2.0","esbuild-wasm":"^0.17.12"}},null,2)},"/vite-env.d.ts":{code:'/// <reference types="vite/client" />'},"/vite.config.ts":{code:`import { defineConfig } from 'vite'
|
|
311
|
-
import react from '@vitejs/plugin-react'
|
|
312
|
-
|
|
313
|
-
// https://vitejs.dev/config/
|
|
314
|
-
export default defineConfig({
|
|
315
|
-
plugins: [react()],
|
|
316
|
-
})
|
|
317
|
-
`}}),main:"/App.tsx",environment:"node"},hJ={files:{"/src/styles.css":hn["/styles.css"],"/src/App.svelte":{code:`<script>
|
|
318
|
-
const data = "world";
|
|
319
|
-
<\/script>
|
|
320
|
-
|
|
321
|
-
<h1>Hello {data}</h1>
|
|
322
|
-
|
|
323
|
-
<style>
|
|
324
|
-
h1 {
|
|
325
|
-
font-size: 1.5rem;
|
|
326
|
-
}
|
|
327
|
-
</style>`},"/src/main.js":{code:`import App from './App.svelte'
|
|
328
|
-
import "./styles.css"
|
|
329
|
-
|
|
330
|
-
const app = new App({
|
|
331
|
-
target: document.getElementById('app'),
|
|
332
|
-
})
|
|
333
|
-
|
|
334
|
-
export default app`},"/index.html":{code:`<!DOCTYPE html>
|
|
335
|
-
<html lang="en">
|
|
336
|
-
<head>
|
|
337
|
-
<meta charset="UTF-8" />
|
|
338
|
-
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
339
|
-
<title>Vite App</title>
|
|
340
|
-
</head>
|
|
341
|
-
<body>
|
|
342
|
-
<div id="app"></div>
|
|
343
|
-
<script type="module" src="/src/main.js"><\/script>
|
|
344
|
-
</body>
|
|
345
|
-
</html>
|
|
346
|
-
`},"/vite.config.js":{code:`import { defineConfig } from 'vite'
|
|
347
|
-
import { svelte } from '@sveltejs/vite-plugin-svelte'
|
|
348
|
-
|
|
349
|
-
// https://vitejs.dev/config/
|
|
350
|
-
export default defineConfig({
|
|
351
|
-
plugins: [svelte()],
|
|
352
|
-
})`},"/package.json":{code:JSON.stringify({type:"module",scripts:{dev:"vite"},devDependencies:{"@sveltejs/vite-plugin-svelte":"^2.0.2",svelte:"^3.55.1",vite:"4.0.4","esbuild-wasm":"^0.17.12"}})}},main:"/src/App.svelte",environment:"node"},pJ={files:{"/src/styles.css":hn["/styles.css"],"/src/App.svelte":{code:`<script lang="ts">
|
|
353
|
-
const data: string = "world";
|
|
354
|
-
<\/script>
|
|
355
|
-
|
|
356
|
-
<h1>Hello {data}</h1>
|
|
357
|
-
|
|
358
|
-
<style>
|
|
359
|
-
h1 {
|
|
360
|
-
font-size: 1.5rem;
|
|
361
|
-
}
|
|
362
|
-
</style>`},"/src/main.ts":{code:`import App from './App.svelte'
|
|
363
|
-
import "./styles.css"
|
|
364
|
-
|
|
365
|
-
const app = new App({
|
|
366
|
-
target: document.getElementById('app'),
|
|
367
|
-
})
|
|
368
|
-
|
|
369
|
-
export default app`},"/index.html":{code:`<!DOCTYPE html>
|
|
370
|
-
<html lang="en">
|
|
371
|
-
<head>
|
|
372
|
-
<meta charset="UTF-8" />
|
|
373
|
-
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
374
|
-
<title>Vite App</title>
|
|
375
|
-
</head>
|
|
376
|
-
<body>
|
|
377
|
-
<div id="app"></div>
|
|
378
|
-
<script type="module" src="/src/main.ts"><\/script>
|
|
379
|
-
</body>
|
|
380
|
-
</html>
|
|
381
|
-
`},"/vite-env.d.ts":{code:`/// <reference types="svelte" />
|
|
382
|
-
/// <reference types="vite/client" />`},"svelte.config.js":{code:`import { vitePreprocess } from '@sveltejs/vite-plugin-svelte'
|
|
383
|
-
|
|
384
|
-
export default {
|
|
385
|
-
// Consult https://svelte.dev/docs#compile-time-svelte-preprocess
|
|
386
|
-
// for more information about preprocessors
|
|
387
|
-
preprocess: vitePreprocess(),
|
|
388
|
-
}
|
|
389
|
-
`},"/vite.config.ts":{code:`import { defineConfig } from 'vite'
|
|
390
|
-
import { svelte } from '@sveltejs/vite-plugin-svelte'
|
|
391
|
-
|
|
392
|
-
// https://vitejs.dev/config/
|
|
393
|
-
export default defineConfig({
|
|
394
|
-
plugins: [svelte()],
|
|
395
|
-
})`},"tsconfig.json":{code:JSON.stringify({extends:"@tsconfig/svelte/tsconfig.json",compilerOptions:{target:"ESNext",useDefineForClassFields:!0,module:"ESNext",resolveJsonModule:!0,allowJs:!0,checkJs:!0,isolatedModules:!0},include:["src/**/*.d.ts","src/**/*.ts","src/**/*.js","src/**/*.svelte"],references:[{path:"./tsconfig.node.json"}]},null,2)},"tsconfig.node.json":{code:JSON.stringify({compilerOptions:{composite:!0,module:"ESNext",moduleResolution:"Node"},include:["vite.config.ts"]},null,2)},"/package.json":{code:JSON.stringify({type:"module",scripts:{dev:"vite"},devDependencies:{"@sveltejs/vite-plugin-svelte":"^2.0.2","@tsconfig/svelte":"^3.0.0",svelte:"^3.55.1","svelte-check":"^2.10.3",tslib:"^2.5.0",vite:"4.1.4","esbuild-wasm":"^0.17.12"}},null,2)}},main:"/src/App.svelte",environment:"node"},mJ={files:{"/src/styles.css":hn["/styles.css"],"/src/App.vue":{code:`<script setup>
|
|
396
|
-
import { ref } from "vue";
|
|
397
|
-
|
|
398
|
-
const data = ref("world");
|
|
399
|
-
<\/script>
|
|
400
|
-
|
|
401
|
-
<template>
|
|
402
|
-
<h1>Hello {{ data }}</h1>
|
|
403
|
-
</template>
|
|
404
|
-
|
|
405
|
-
<style>
|
|
406
|
-
h1 {
|
|
407
|
-
font-size: 1.5rem;
|
|
408
|
-
}
|
|
409
|
-
</style>`},"/src/main.js":{code:`import { createApp } from 'vue'
|
|
410
|
-
import App from './App.vue'
|
|
411
|
-
import "./styles.css"
|
|
412
|
-
|
|
413
|
-
createApp(App).mount('#app')
|
|
414
|
-
`},"/index.html":{code:`<!DOCTYPE html>
|
|
415
|
-
<html lang="en">
|
|
416
|
-
<head>
|
|
417
|
-
<meta charset="UTF-8" />
|
|
418
|
-
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
419
|
-
<title>Vite App</title>
|
|
420
|
-
</head>
|
|
421
|
-
<body>
|
|
422
|
-
<div id="app"></div>
|
|
423
|
-
<script type="module" src="/src/main.js"><\/script>
|
|
424
|
-
</body>
|
|
425
|
-
</html>
|
|
426
|
-
`},"/vite.config.js":{code:`import { defineConfig } from 'vite'
|
|
427
|
-
import vue from '@vitejs/plugin-vue'
|
|
428
|
-
|
|
429
|
-
// https://vitejs.dev/config/
|
|
430
|
-
export default defineConfig({
|
|
431
|
-
plugins: [vue()]
|
|
432
|
-
})
|
|
433
|
-
`},"/package.json":{code:JSON.stringify({scripts:{dev:"vite",build:"vite build",preview:"vite preview"},dependencies:{vue:"^3.2.45"},devDependencies:{"@vitejs/plugin-vue":"3.2.0",vite:"4.1.4","esbuild-wasm":"0.17.12"}})}},main:"/src/App.vue",environment:"node"},gJ={files:{"/src/styles.css":hn["/styles.css"],"/src/App.vue":{code:`<script setup lang="ts">
|
|
434
|
-
import { ref } from "vue";
|
|
435
|
-
|
|
436
|
-
const data = ref<string>("world");
|
|
437
|
-
<\/script>
|
|
438
|
-
|
|
439
|
-
<template>
|
|
440
|
-
<h1>Hello {{ data }}</h1>
|
|
441
|
-
</template>
|
|
442
|
-
|
|
443
|
-
<style>
|
|
444
|
-
h1 {
|
|
445
|
-
font-size: 1.5rem;
|
|
446
|
-
}
|
|
447
|
-
</style>`},"/src/main.ts":{code:`import { createApp } from 'vue'
|
|
448
|
-
import App from './App.vue'
|
|
449
|
-
import "./styles.css"
|
|
450
|
-
|
|
451
|
-
createApp(App).mount('#app')
|
|
452
|
-
`},"/index.html":{code:`<!DOCTYPE html>
|
|
453
|
-
<html lang="en">
|
|
454
|
-
<head>
|
|
455
|
-
<meta charset="UTF-8" />
|
|
456
|
-
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
457
|
-
<title>Vite App</title>
|
|
458
|
-
</head>
|
|
459
|
-
<body>
|
|
460
|
-
<div id="app"></div>
|
|
461
|
-
<script type="module" src="/src/main.ts"><\/script>
|
|
462
|
-
</body>
|
|
463
|
-
</html>
|
|
464
|
-
`},"/vite-env.d.ts":{code:'/// <reference types="vite/client" />'},"/vite.config.ts":{code:`import { defineConfig } from 'vite'
|
|
465
|
-
import vue from '@vitejs/plugin-vue'
|
|
466
|
-
|
|
467
|
-
// https://vitejs.dev/config/
|
|
468
|
-
export default defineConfig({
|
|
469
|
-
plugins: [vue()]
|
|
470
|
-
})
|
|
471
|
-
`},"tsconfig.json":{code:JSON.stringify({compilerOptions:{target:"ESNext",useDefineForClassFields:!0,module:"ESNext",moduleResolution:"Node",strict:!0,jsx:"preserve",resolveJsonModule:!0,isolatedModules:!0,esModuleInterop:!0,lib:["ESNext","DOM"],skipLibCheck:!0,noEmit:!0},include:["src/**/*.ts","src/**/*.d.ts","src/**/*.tsx","src/**/*.vue"],references:[{path:"./tsconfig.node.json"}]},null,2)},"tsconfig.node.json":{code:JSON.stringify({compilerOptions:{composite:!0,module:"ESNext",moduleResolution:"Node",allowSyntheticDefaultImports:!0},include:["vite.config.ts"]},null,2)},"/package.json":{code:JSON.stringify({scripts:{dev:"vite",build:"tsc && vite build",preview:"vite preview"},dependencies:{vue:"^3.2.47"},devDependencies:{"@vitejs/plugin-vue":"^4.0.0",vite:"4.1.4","vue-tsc":"^1.2.0",typescript:"^4.9.5","esbuild-wasm":"^0.17.12"}},null,2)}},main:"/src/App.vue",environment:"node"},OJ={files:{"/src/app/app.component.css":hn["/styles.css"],"/src/app/app.component.html":{code:`<div>
|
|
472
|
-
<h1>{{ helloWorld }}</h1>
|
|
473
|
-
</div>
|
|
474
|
-
`},"/src/app/app.component.ts":{code:`import { Component } from "@angular/core";
|
|
475
|
-
|
|
476
|
-
@Component({
|
|
477
|
-
selector: "app-root",
|
|
478
|
-
templateUrl: "./app.component.html",
|
|
479
|
-
styleUrls: ["./app.component.css"]
|
|
480
|
-
})
|
|
481
|
-
export class AppComponent {
|
|
482
|
-
helloWorld = "Hello world";
|
|
483
|
-
}
|
|
484
|
-
`},"/src/app/app.module.ts":{code:`import { BrowserModule } from "@angular/platform-browser";
|
|
485
|
-
import { NgModule } from "@angular/core";
|
|
486
|
-
|
|
487
|
-
import { AppComponent } from "./app.component";
|
|
488
|
-
|
|
489
|
-
@NgModule({
|
|
490
|
-
declarations: [AppComponent],
|
|
491
|
-
imports: [BrowserModule],
|
|
492
|
-
providers: [],
|
|
493
|
-
bootstrap: [AppComponent]
|
|
494
|
-
})
|
|
495
|
-
export class AppModule {}
|
|
496
|
-
`},"/src/index.html":{code:`<!doctype html>
|
|
497
|
-
<html lang="en">
|
|
498
|
-
|
|
499
|
-
<head>
|
|
500
|
-
<meta charset="utf-8">
|
|
501
|
-
<title>Angular</title>
|
|
502
|
-
<base href="/">
|
|
503
|
-
|
|
504
|
-
<meta name="viewport" content="width=device-width, initial-scale=1">
|
|
505
|
-
<link rel="icon" type="image/x-icon" href="favicon.ico">
|
|
506
|
-
</head>
|
|
507
|
-
|
|
508
|
-
<body>
|
|
509
|
-
<app-root></app-root>
|
|
510
|
-
</body>
|
|
511
|
-
|
|
512
|
-
</html>
|
|
513
|
-
`},"/src/main.ts":{code:`import { enableProdMode } from "@angular/core";
|
|
514
|
-
import { platformBrowserDynamic } from "@angular/platform-browser-dynamic";
|
|
515
|
-
|
|
516
|
-
import { AppModule } from "./app/app.module";
|
|
517
|
-
|
|
518
|
-
platformBrowserDynamic()
|
|
519
|
-
.bootstrapModule(AppModule)
|
|
520
|
-
.catch(err => console.log(err));
|
|
521
|
-
|
|
522
|
-
`},"/src/polyfills.ts":{code:`import "core-js/proposals/reflect-metadata";
|
|
523
|
-
import "zone.js/dist/zone";
|
|
524
|
-
`},"/package.json":{code:JSON.stringify({dependencies:{"@angular/core":"^11.2.0","@angular/platform-browser":"^11.2.0","@angular/platform-browser-dynamic":"^11.2.0","@angular/common":"^11.2.0","@angular/compiler":"^11.2.0","zone.js":"0.11.3","core-js":"3.8.3",rxjs:"6.6.3"},main:"/src/main.ts"})}},main:"/src/app/app.component.ts",environment:"angular-cli"},vJ={files:ue(ue({},hn),{"/App.js":{code:`export default function App() {
|
|
525
|
-
return <h1>Hello world</h1>
|
|
526
|
-
}
|
|
527
|
-
`},"/index.js":{code:`import React, { StrictMode } from "react";
|
|
528
|
-
import { createRoot } from "react-dom/client";
|
|
529
|
-
import "./styles.css";
|
|
530
|
-
|
|
531
|
-
import App from "./App";
|
|
532
|
-
|
|
533
|
-
const root = createRoot(document.getElementById("root"));
|
|
534
|
-
root.render(
|
|
535
|
-
<StrictMode>
|
|
536
|
-
<App />
|
|
537
|
-
</StrictMode>
|
|
538
|
-
);`},"/public/index.html":{code:`<!DOCTYPE html>
|
|
539
|
-
<html lang="en">
|
|
540
|
-
<head>
|
|
541
|
-
<meta charset="UTF-8">
|
|
542
|
-
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
543
|
-
<title>Document</title>
|
|
544
|
-
</head>
|
|
545
|
-
<body>
|
|
546
|
-
<div id="root"></div>
|
|
547
|
-
</body>
|
|
548
|
-
</html>`},"/package.json":{code:JSON.stringify({dependencies:{react:"^19.0.0","react-dom":"^19.0.0","react-scripts":"^5.0.0"},main:"/index.js"})}}),main:"/App.js",environment:"create-react-app"},yJ={files:ue(ue({},hn),{"tsconfig.json":{code:`{
|
|
549
|
-
"include": [
|
|
550
|
-
"./**/*"
|
|
551
|
-
],
|
|
552
|
-
"compilerOptions": {
|
|
553
|
-
"strict": true,
|
|
554
|
-
"esModuleInterop": true,
|
|
555
|
-
"lib": [ "dom", "es2015" ],
|
|
556
|
-
"jsx": "react-jsx"
|
|
557
|
-
}
|
|
558
|
-
}`},"/App.tsx":{code:`export default function App(): JSX.Element {
|
|
559
|
-
return <h1>Hello world</h1>
|
|
560
|
-
}
|
|
561
|
-
`},"/index.tsx":{code:`import React, { StrictMode } from "react";
|
|
562
|
-
import { createRoot } from "react-dom/client";
|
|
563
|
-
import "./styles.css";
|
|
564
|
-
|
|
565
|
-
import App from "./App";
|
|
566
|
-
|
|
567
|
-
const root = createRoot(document.getElementById("root"));
|
|
568
|
-
root.render(
|
|
569
|
-
<StrictMode>
|
|
570
|
-
<App />
|
|
571
|
-
</StrictMode>
|
|
572
|
-
);`},"/public/index.html":{code:`<!DOCTYPE html>
|
|
573
|
-
<html lang="en">
|
|
574
|
-
<head>
|
|
575
|
-
<meta charset="UTF-8">
|
|
576
|
-
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
577
|
-
<title>Document</title>
|
|
578
|
-
</head>
|
|
579
|
-
<body>
|
|
580
|
-
<div id="root"></div>
|
|
581
|
-
</body>
|
|
582
|
-
</html>`},"/package.json":{code:JSON.stringify({dependencies:{react:"^19.0.0","react-dom":"^19.0.0","react-scripts":"^4.0.0"},devDependencies:{"@types/react":"^19.0.0","@types/react-dom":"^19.0.0",typescript:"^4.0.0"},main:"/index.tsx"})}}),main:"/App.tsx",environment:"create-react-app"},bJ={files:ue(ue({},hn),{"/App.tsx":{code:`import { Component } from "solid-js";
|
|
583
|
-
|
|
584
|
-
const App: Component = () => {
|
|
585
|
-
return <h1>Hello world</h1>
|
|
586
|
-
};
|
|
587
|
-
|
|
588
|
-
export default App;`},"/index.tsx":{code:`import { render } from "solid-js/web";
|
|
589
|
-
import App from "./App";
|
|
590
|
-
|
|
591
|
-
import "./styles.css";
|
|
592
|
-
|
|
593
|
-
render(() => <App />, document.getElementById("app"));`},"/index.html":{code:`<html>
|
|
594
|
-
<head>
|
|
595
|
-
<title>Parcel Sandbox</title>
|
|
596
|
-
<meta charset="UTF-8" />
|
|
597
|
-
</head>
|
|
598
|
-
<body>
|
|
599
|
-
<div id="app"></div>
|
|
600
|
-
<script src="src/index.tsx"><\/script>
|
|
601
|
-
</body>
|
|
602
|
-
</html>`},"/package.json":{code:JSON.stringify({dependencies:{"solid-js":"1.3.15"},main:"/index.tsx"})}}),main:"/App.tsx",environment:"solid"},xJ={files:ue(ue({},hn),{"/App.svelte":{code:`<style>
|
|
603
|
-
h1 {
|
|
604
|
-
font-size: 1.5rem;
|
|
605
|
-
}
|
|
606
|
-
</style>
|
|
607
|
-
|
|
608
|
-
<script>
|
|
609
|
-
let name = 'world';
|
|
610
|
-
<\/script>
|
|
611
|
-
|
|
612
|
-
<main>
|
|
613
|
-
<h1>Hello {name}</h1>
|
|
614
|
-
</main>`},"/index.js":{code:`import App from "./App.svelte";
|
|
615
|
-
import "./styles.css";
|
|
616
|
-
|
|
617
|
-
const app = new App({
|
|
618
|
-
target: document.body
|
|
619
|
-
});
|
|
620
|
-
|
|
621
|
-
export default app;
|
|
622
|
-
`},"/public/index.html":{code:`<!DOCTYPE html>
|
|
623
|
-
<html>
|
|
624
|
-
<head>
|
|
625
|
-
<meta charset="utf8" />
|
|
626
|
-
<meta name="viewport" content="width=device-width" />
|
|
627
|
-
|
|
628
|
-
<title>Svelte app</title>
|
|
629
|
-
|
|
630
|
-
<link rel="stylesheet" href="public/bundle.css" />
|
|
631
|
-
</head>
|
|
632
|
-
|
|
633
|
-
<body>
|
|
634
|
-
<script src="bundle.js"><\/script>
|
|
635
|
-
</body>
|
|
636
|
-
</html>`},"/package.json":{code:JSON.stringify({dependencies:{svelte:"^3.0.0"},main:"/index.js"})}}),main:"/App.svelte",environment:"svelte"},SJ={files:{"tsconfig.json":{code:`{
|
|
637
|
-
"include": [
|
|
638
|
-
"./**/*"
|
|
639
|
-
],
|
|
640
|
-
"compilerOptions": {
|
|
641
|
-
"strict": true,
|
|
642
|
-
"esModuleInterop": true,
|
|
643
|
-
"lib": [ "dom", "es2015" ],
|
|
644
|
-
"jsx": "react-jsx"
|
|
645
|
-
}
|
|
646
|
-
}`},"/add.ts":{code:"export const add = (a: number, b: number): number => a + b;"},"/add.test.ts":{code:`import { add } from './add';
|
|
647
|
-
|
|
648
|
-
describe('add', () => {
|
|
649
|
-
test('Commutative Law of Addition', () => {
|
|
650
|
-
expect(add(1, 2)).toBe(add(2, 1));
|
|
651
|
-
});
|
|
652
|
-
});`},"package.json":{code:JSON.stringify({dependencies:{},devDependencies:{typescript:"^4.0.0"},main:"/add.ts"})}},main:"/add.test.ts",environment:"parcel",mode:"tests"},wJ={files:ue(ue({},hn),{"/index.js":{code:`import "./styles.css";
|
|
653
|
-
|
|
654
|
-
document.getElementById("app").innerHTML = \`
|
|
655
|
-
<h1>Hello world</h1>
|
|
656
|
-
\`;
|
|
657
|
-
`},"/index.html":{code:`<!DOCTYPE html>
|
|
658
|
-
<html>
|
|
659
|
-
|
|
660
|
-
<head>
|
|
661
|
-
<title>Parcel Sandbox</title>
|
|
662
|
-
<meta charset="UTF-8" />
|
|
663
|
-
</head>
|
|
664
|
-
|
|
665
|
-
<body>
|
|
666
|
-
<div id="app"></div>
|
|
667
|
-
|
|
668
|
-
<script src="index.js">
|
|
669
|
-
<\/script>
|
|
670
|
-
</body>
|
|
671
|
-
|
|
672
|
-
</html>`},"/package.json":{code:JSON.stringify({dependencies:{},main:"/index.js"})}}),main:"/index.js",environment:"parcel"},kJ={files:ue(ue({},hn),{"tsconfig.json":{code:`{
|
|
673
|
-
"compilerOptions": {
|
|
674
|
-
"strict": true,
|
|
675
|
-
"module": "commonjs",
|
|
676
|
-
"jsx": "preserve",
|
|
677
|
-
"esModuleInterop": true,
|
|
678
|
-
"sourceMap": true,
|
|
679
|
-
"allowJs": true,
|
|
680
|
-
"lib": [
|
|
681
|
-
"es6",
|
|
682
|
-
"dom"
|
|
683
|
-
],
|
|
684
|
-
"rootDir": "src",
|
|
685
|
-
"moduleResolution": "node"
|
|
686
|
-
}
|
|
687
|
-
}`},"/index.ts":{code:`import "./styles.css";
|
|
688
|
-
|
|
689
|
-
document.getElementById("app").innerHTML = \`
|
|
690
|
-
<h1>Hello world</h1>
|
|
691
|
-
\`;
|
|
692
|
-
`},"/index.html":{code:`<!DOCTYPE html>
|
|
693
|
-
<html>
|
|
694
|
-
|
|
695
|
-
<head>
|
|
696
|
-
<title>Parcel Sandbox</title>
|
|
697
|
-
<meta charset="UTF-8" />
|
|
698
|
-
</head>
|
|
699
|
-
|
|
700
|
-
<body>
|
|
701
|
-
<div id="app"></div>
|
|
702
|
-
|
|
703
|
-
<script src="index.ts">
|
|
704
|
-
<\/script>
|
|
705
|
-
</body>
|
|
706
|
-
|
|
707
|
-
</html>`},"/package.json":{code:JSON.stringify({dependencies:{},devDependencies:{typescript:"^4.0.0"},main:"/index.ts"})}}),main:"/index.ts",environment:"parcel"},CJ={files:{"/src/styles.css":hn["/styles.css"],"/src/App.vue":{code:`<template>
|
|
708
|
-
<h1>Hello {{ msg }}</h1>
|
|
709
|
-
</template>
|
|
710
|
-
|
|
711
|
-
<script setup>
|
|
712
|
-
import { ref } from 'vue';
|
|
713
|
-
const msg = ref('world');
|
|
714
|
-
<\/script>`},"/src/main.js":{code:`import { createApp } from 'vue'
|
|
715
|
-
import App from './App.vue'
|
|
716
|
-
import "./styles.css";
|
|
717
|
-
|
|
718
|
-
createApp(App).mount('#app')
|
|
719
|
-
`},"/public/index.html":{code:`<!DOCTYPE html>
|
|
720
|
-
<html lang="en">
|
|
721
|
-
<head>
|
|
722
|
-
<meta charset="utf-8" />
|
|
723
|
-
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
|
|
724
|
-
<meta name="viewport" content="width=device-width,initial-scale=1.0" />
|
|
725
|
-
<title>codesandbox</title>
|
|
726
|
-
</head>
|
|
727
|
-
<body>
|
|
728
|
-
<noscript>
|
|
729
|
-
<strong
|
|
730
|
-
>We're sorry but codesandbox doesn't work properly without JavaScript
|
|
731
|
-
enabled. Please enable it to continue.</strong
|
|
732
|
-
>
|
|
733
|
-
</noscript>
|
|
734
|
-
<div id="app"></div>
|
|
735
|
-
<!-- built files will be auto injected -->
|
|
736
|
-
</body>
|
|
737
|
-
</html>
|
|
738
|
-
`},"/package.json":{code:JSON.stringify({name:"vue3",version:"0.1.0",private:!0,main:"/src/main.js",scripts:{serve:"vue-cli-service serve",build:"vue-cli-service build"},dependencies:{"core-js":"^3.26.1",vue:"^3.2.45"},devDependencies:{"@vue/cli-plugin-babel":"^5.0.8","@vue/cli-service":"^5.0.8"}})}},main:"/src/App.vue",environment:"vue-cli"},TJ={files:{"/src/styles.css":hn["/styles.css"],"/src/App.vue":{code:`<template>
|
|
739
|
-
<h1>Hello {{ msg }}</h1>
|
|
740
|
-
</template>
|
|
741
|
-
|
|
742
|
-
<script setup lang="ts">
|
|
743
|
-
import { ref } from 'vue';
|
|
744
|
-
const msg = ref<string>('world');
|
|
745
|
-
<\/script>`},"/src/main.ts":{code:`import { createApp } from 'vue'
|
|
746
|
-
import App from './App.vue'
|
|
747
|
-
import "./styles.css";
|
|
748
|
-
|
|
749
|
-
createApp(App).mount('#app')
|
|
750
|
-
`},"/src/shims-vue.d.ts":`/* eslint-disable */
|
|
751
|
-
declare module "*.vue" {
|
|
752
|
-
import type { DefineComponent } from "vue";
|
|
753
|
-
const component: DefineComponent<{}, {}, any>;
|
|
754
|
-
export default component;
|
|
755
|
-
}`,"/public/index.html":{code:`<!DOCTYPE html>
|
|
756
|
-
<html lang="en">
|
|
757
|
-
<head>
|
|
758
|
-
<meta charset="utf-8" />
|
|
759
|
-
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
|
|
760
|
-
<meta name="viewport" content="width=device-width,initial-scale=1.0" />
|
|
761
|
-
<title>codesandbox</title>
|
|
762
|
-
</head>
|
|
763
|
-
<body>
|
|
764
|
-
<noscript>
|
|
765
|
-
<strong
|
|
766
|
-
>We're sorry but codesandbox doesn't work properly without JavaScript
|
|
767
|
-
enabled. Please enable it to continue.</strong
|
|
768
|
-
>
|
|
769
|
-
</noscript>
|
|
770
|
-
<div id="app"></div>
|
|
771
|
-
<!-- built files will be auto injected -->
|
|
772
|
-
</body>
|
|
773
|
-
</html>
|
|
774
|
-
`},"/package.json":{code:JSON.stringify({name:"vue3-ts",version:"0.1.0",private:!0,main:"/src/main.ts",scripts:{serve:"vue-cli-service serve",build:"vue-cli-service build"},dependencies:{"core-js":"^3.26.1",vue:"^3.2.45"},devDependencies:{"@vue/cli-plugin-babel":"^5.0.8","@vue/cli-plugin-typescript":"^5.0.8","@vue/cli-service":"^5.0.8",typescript:"^4.9.3"}})},"/tsconfig.json":{code:JSON.stringify({compilerOptions:{target:"esnext",module:"esnext",strict:!0,jsx:"preserve",moduleResolution:"node",experimentalDecorators:!0,skipLibCheck:!0,esModuleInterop:!0,allowSyntheticDefaultImports:!0,forceConsistentCasingInFileNames:!0,useDefineForClassFields:!0,sourceMap:!1,baseUrl:".",types:["webpack-env"],paths:{"@/*":["src/*"]},lib:["esnext","dom","dom.iterable","scripthost"]},include:["src/**/*.ts","src/**/*.tsx","src/**/*.vue","tests/**/*.ts","tests/**/*.tsx"],exclude:["node_modules"]})}},main:"/src/App.vue",environment:"vue-cli"},EJ={files:ue(ue({},hn),{"/index.html":{code:`<!DOCTYPE html>
|
|
775
|
-
<html>
|
|
776
|
-
|
|
777
|
-
<head>
|
|
778
|
-
<title>Parcel Sandbox</title>
|
|
779
|
-
<meta charset="UTF-8" />
|
|
780
|
-
<link rel="stylesheet" href="/styles.css" />
|
|
781
|
-
</head>
|
|
782
|
-
|
|
783
|
-
<body>
|
|
784
|
-
<h1>Hello world</h1>
|
|
785
|
-
</body>
|
|
786
|
-
|
|
787
|
-
</html>`},"/package.json":{code:JSON.stringify({dependencies:{},main:"/index.html"})}}),main:"/index.html",environment:"static"},wQ={static:EJ,angular:OJ,react:vJ,"react-ts":yJ,solid:bJ,svelte:xJ,"test-ts":SJ,"vanilla-ts":kJ,vanilla:wJ,vue:CJ,"vue-ts":TJ,node:oJ,nextjs:sJ,vite:lJ,"vite-react":dJ,"vite-react-ts":fJ,"vite-preact":cJ,"vite-preact-ts":uJ,"vite-vue":mJ,"vite-vue-ts":gJ,"vite-svelte":hJ,"vite-svelte-ts":pJ,astro:aJ},Ab=function(t){var e,n,r,i,a,o,c=Io(t.files),u=QJ({template:t.template,customSetup:t.customSetup,files:c}),f=Io((n=(e=t.options)===null||e===void 0?void 0:e.visibleFiles)!==null&&n!==void 0?n:[]),h=!((r=t.options)===null||r===void 0)&&r.activeFile?kQ((i=t.options)===null||i===void 0?void 0:i.activeFile,u.files):void 0;f.length===0&&c&&Object.keys(c).forEach(function(y){var x=c[y];if(typeof x=="string"){f.push(y);return}!h&&x.active&&(h=y,x.hidden===!0&&f.push(y)),x.hidden||f.push(y)}),f.length===0&&(f=[u.main]),u.entry&&!u.files[u.entry]&&(u.entry=kQ(u.entry,u.files)),!h&&u.main&&(h=u.main),(!h||!u.files[h])&&(h=f[0]),f.includes(h)||f.push(h);var m=N9(u.files,(a=u.dependencies)!==null&&a!==void 0?a:{},(o=u.devDependencies)!==null&&o!==void 0?o:{},u.entry),g=f.filter(function(y){return m[y]});return{visibleFiles:g,activeFile:h,files:m,environment:u.environment,shouldUpdatePreview:!0}},kQ=function(t,e){var n=Io(e),r=Io(t);if(r in n)return r;if(!t)return null;for(var i=null,a=0,o=[".js",".jsx",".ts",".tsx"];!i&&a<o.length;){var c=r.split(".")[0],u="".concat(c).concat(o[a]);n[u]!==void 0&&(i=u),a++}return i},QJ=function(t){var e=t.files,n=t.template,r=t.customSetup;if(!n){if(!r){var i=wQ.vanilla;return ue(ue({},i),{files:ue(ue({},i.files),Ap(e))})}if(!e||Object.keys(e).length===0)throw new Error("[sandpack-react]: without a template, you must pass at least one file");return ue(ue({},r),{files:Ap(e)})}var a=wQ[n];if(!a)throw new Error('[sandpack-react]: invalid template "'.concat(n,'" provided'));return!r&&!e?a:{files:Ap(ue(ue({},a.files),e)),dependencies:ue(ue({},a.dependencies),r?.dependencies),devDependencies:ue(ue({},a.devDependencies),r?.devDependencies),entry:Io(r?.entry),main:a.main,environment:r?.environment||a.environment}},Ap=function(t){return t?Object.keys(t).reduce(function(e,n){return typeof t[n]=="string"?e[n]={code:t[n]}:e[n]=t[n],e},{}):{}},AJ=function(t,e){var n=w.useState({editorState:"pristine"}),r=n[0],i=n[1],a=Ab(t),o=od(a.files,e)?"pristine":"dirty";return o!==r.editorState&&i(function(c){return ue(ue({},c),{editorState:o})}),r},Y5=function(){return typeof w.useId=="function"?w.useId():Qc()},CQ=9,RJ="2.19.8",_J=function(t){if(typeof w.useId=="function"){var e=w.useId();return function(){return _s(void 0,void 0,void 0,function(){var n,r;return $s(this,function(i){switch(i.label){case 0:return n=Object.entries(t).map(function(a,o){return a+"|"+o}).join("|||"),[4,$J(n+e+RJ)];case 1:return r=i.sent(),[2,TQ(r.replace(/:/g,"sp").replace(/[^a-zA-Z]/g,""),CQ)]}})})}}else return function(){return TQ(Qc(),CQ)}};function TQ(t,e){return t.length>e?t.slice(0,e):t.padEnd(e,"s")}function $J(t){return _s(this,void 0,void 0,function(){var e,n,r,i;return $s(this,function(a){switch(a.label){case 0:return e=new TextEncoder,n=e.encode(t),[4,crypto.subtle.digest("SHA-256",n)];case 1:return r=a.sent(),i=Array.from(new Uint8Array(r)),[2,btoa(String.fromCharCode.apply(String,i))]}})})}var PJ=4e4,jJ=function(t,e){var n,r,i,a=t.options,o=t.customSetup,c=t.teamId,u=t.sandboxId;a??(a={}),o??(o={});var f=a?.initMode||"lazy",h=w.useState({startRoute:a?.startRoute,bundlerState:void 0,error:null,initMode:f,reactDevTools:void 0,status:!((n=a?.autorun)!==null&&n!==void 0)||n?"initial":"idle"}),m=h[0],g=h[1],y=w.useRef(),x=w.useRef(null),S=w.useRef(null),k=w.useRef({}),T=w.useRef({}),C=w.useRef(null),E=w.useRef({}),R=w.useRef(),$=w.useRef({global:{}}),P=w.useRef(),_=w.useRef(e.environment),M=_J(e.files),V=w.useCallback(function(A,N,L){return _s(void 0,void 0,void 0,function(){var q,se,he,H,ge,xe,ke,Ce,Re,We,Pe;return $s(this,function(ht){switch(ht.label){case 0:return T.current[N]&&T.current[N].destroy(),a??(a={}),o??(o={}),q=(Re=a?.bundlerTimeOut)!==null&&Re!==void 0?Re:PJ,C.current&&clearTimeout(C.current),se=typeof R.current!="function",se&&(C.current=setTimeout(function(){F(),g(function(Ke){return ue(ue({},Ke),{status:"timeout"})})},q)),he=function(){return _s(void 0,void 0,void 0,function(){var Ke,tt;return $s(this,function(bt){switch(bt.label){case 0:return a?.experimental_enableStableServiceWorkerId?(Ke="SANDPACK_INTERNAL:URL-CONSISTENT-ID",tt=localStorage.getItem(Ke),tt?[3,2]:[4,M()]):[3,3];case 1:tt=bt.sent(),localStorage.setItem(Ke,tt),bt.label=2;case 2:return[2,tt];case 3:return[4,M()];case 4:return[2,bt.sent()]}})})},ge=X9,xe=[A,{files:e.files,template:e.environment}],Ce={externalResources:a.externalResources,bundlerURL:a.bundlerURL,startRoute:(We=L?.startRoute)!==null&&We!==void 0?We:a.startRoute,fileResolver:a.fileResolver,skipEval:(Pe=a.skipEval)!==null&&Pe!==void 0?Pe:!1,logLevel:a.logLevel,showOpenInCodeSandbox:!1,showErrorScreen:!0,showLoadingScreen:!1,reactDevTools:m.reactDevTools,customNpmRegistries:o?.npmRegistries,teamId:c,experimental_enableServiceWorker:!!a?.experimental_enableServiceWorker},[4,he()];case 1:return[4,ge.apply(void 0,xe.concat([(Ce.experimental_stableServiceWorkerId=ht.sent(),Ce.sandboxId=u,Ce)]))];case 2:return H=ht.sent(),typeof R.current!="function"&&(R.current=H.listen(pe)),E.current[N]=E.current[N]||{},$.current[N]&&(Object.keys($.current[N]).forEach(function(Ke){var tt=$.current[N][Ke],bt=H.listen(tt);E.current[N][Ke]=bt}),$.current[N]={}),ke=Object.entries($.current.global),ke.forEach(function(Ke){var tt=Ke[0],bt=Ke[1],Ue=H.listen(bt);E.current[N][tt]=Ue}),T.current[N]=H,[2]}})})},[e.environment,e.files,m.reactDevTools]),F=w.useCallback(function(){Object.keys(T.current).map(ee),typeof R.current=="function"&&(R.current(),R.current=void 0)},[]),W=w.useCallback(function(){return _s(void 0,void 0,void 0,function(){return $s(this,function(A){switch(A.label){case 0:return[4,Promise.all(Object.entries(k.current).map(function(N){var L=N[0],q=N[1],se=q.iframe,he=q.clientPropsOverride,H=he===void 0?{}:he;return _s(void 0,void 0,void 0,function(){return $s(this,function(ge){switch(ge.label){case 0:return[4,V(se,L,H)];case 1:return ge.sent(),[2]}})})}))];case 1:return A.sent(),g(function(N){return ue(ue({},N),{error:null,status:"running"})}),[2]}})})},[V]);y.current=function(A){A.some(function(N){return N.isIntersecting})?W():F()};var I=w.useCallback(function(){var A,N,L,q=(A=a?.autorun)!==null&&A!==void 0?A:!0;if(q){var se=(N=a?.initModeObserverOptions)!==null&&N!==void 0?N:{rootMargin:"1000px 0px"};x.current&&S.current&&((L=x.current)===null||L===void 0||L.unobserve(S.current)),S.current&&m.initMode==="lazy"?(x.current=new IntersectionObserver(function(he){var H,ge;he.some(function(xe){return xe.isIntersecting})&&he.some(function(xe){return xe.isIntersecting})&&S.current&&((H=y.current)===null||H===void 0||H.call(y,he),(ge=x.current)===null||ge===void 0||ge.unobserve(S.current))},se),x.current.observe(S.current)):S.current&&m.initMode==="user-visible"?(x.current=new IntersectionObserver(function(he){var H;(H=y.current)===null||H===void 0||H.call(y,he)},se),x.current.observe(S.current)):W()}},[a?.autorun,a?.initModeObserverOptions,W,m.initMode,F]),ne=w.useCallback(function(A,N,L){return _s(void 0,void 0,void 0,function(){return $s(this,function(q){switch(q.label){case 0:return k.current[N]={iframe:A,clientPropsOverride:L},m.status!=="running"?[3,2]:[4,V(A,N,L)];case 1:q.sent(),q.label=2;case 2:return[2]}})})},[V,m.status]),ee=function(A){var N,L,q=T.current[A];q?(q.destroy(),(N=q.iframe.contentWindow)===null||N===void 0||N.location.replace("about:blank"),q.iframe.removeAttribute("src"),delete T.current[A]):delete k.current[A],C.current&&clearTimeout(C.current);var se=Object.values((L=E.current[A])!==null&&L!==void 0?L:{});se.forEach(function(H){var ge=Object.values(H);ge.forEach(function(xe){return xe()})});var he=Object.keys(T.current).length>0?"running":"idle";g(function(H){return ue(ue({},H),{status:he})})},pe=function(A){A.type==="start"?g(function(N){return ue(ue({},N),{error:null})}):A.type==="state"?g(function(N){return ue(ue({},N),{bundlerState:A.state})}):A.type==="done"&&!A.compilatonError||A.type==="connected"?(C.current&&clearTimeout(C.current),g(function(N){return ue(ue({},N),{error:null})})):A.type==="action"&&A.action==="show-error"?(C.current&&clearTimeout(C.current),g(function(N){return ue(ue({},N),{error:D9(A)})})):A.type==="action"&&A.action==="notification"&&A.notificationType==="error"&&g(function(N){return ue(ue({},N),{error:{message:A.title}})})},D=function(A){g(function(N){return ue(ue({},N),{reactDevTools:A})})},G=(r=a?.recompileMode)!==null&&r!==void 0?r:"delayed",B=(i=a?.recompileDelay)!==null&&i!==void 0?i:200,ye=function(A,N){if(m.status!=="running"){console.warn("[sandpack-react]: dispatch cannot be called while in idle mode");return}N?T.current[N].dispatch(A):Object.values(T.current).forEach(function(L){L.dispatch(A)})},X=function(A,N){if(N)if(T.current[N]){var L=T.current[N].listen(A);return L}else{var q=Qc();$.current[N]=$.current[N]||{},E.current[N]=E.current[N]||{},$.current[N][q]=A;var L=function(){$.current[N][q]?delete $.current[N][q]:E.current[N][q]&&(E.current[N][q](),delete E.current[N][q])};return L}else{var se=Qc();$.current.global[se]=A;var he=Object.values(T.current),H=he.map(function(xe){return xe.listen(A)}),L=function(){H.forEach(function(xe){return xe()}),delete $.current.global[se],Object.values(E.current).forEach(function(xe){var ke;(ke=xe?.[se])===null||ke===void 0||ke.call(xe)})};return L}};return w.useEffect(function(){if(!(m.status!=="running"||!e.shouldUpdatePreview)){if(_.current!==e.environment&&(_.current=e.environment,Object.entries(T.current).forEach(function(N){var L=N[0],q=N[1];ne(q.iframe,L)})),G==="immediate"&&Object.values(T.current).forEach(function(N){N.status==="done"&&N.updateSandbox({files:e.files,template:e.environment})}),G==="delayed"){if(typeof window>"u")return;window.clearTimeout(P.current),P.current=window.setTimeout(function(){Object.values(T.current).forEach(function(N){N.status==="done"&&N.updateSandbox({files:e.files,template:e.environment})})},B)}return function(){window.clearTimeout(P.current)}}},[e.files,e.environment,e.shouldUpdatePreview,B,G,ne,m.status]),w.useEffect(function(){f!==m.initMode&&(g(function(N){return ue(ue({},N),{initMode:f})}),I())},[f,I,m.initMode]),w.useEffect(function(){return function(){typeof R.current=="function"&&R.current(),C.current&&clearTimeout(C.current),P.current&&clearTimeout(P.current),x.current&&x.current.disconnect()}},[]),[m,{clients:T.current,initializeSandpackIframe:I,runSandpack:W,registerBundler:ne,unregisterBundler:ee,registerReactDevTools:D,addListener:X,dispatchMessage:ye,lazyAnchorRef:S,unsubscribeClientListenersRef:E,queuedListenersRef:$}]},MJ=function(t){var e=Ab(t),n=w.useState(e),r=n[0],i=n[1],a=w.useRef(!1);w.useEffect(function(){a.current?i(Ab(t)):a.current=!0},[t.files,t.customSetup,t.template]);var o=function(u,f,h){h===void 0&&(h=!0),i(function(m){var g,y=m.files;return typeof u=="string"&&typeof f=="string"?y=ue(ue({},y),(g={},g[u]=ue(ue({},y[u]),{code:f}),g)):typeof u=="object"&&(y=ue(ue({},y),Ap(u))),ue(ue({},m),{files:Io(y),shouldUpdatePreview:h})})},c={openFile:function(u){i(function(f){var h=f.visibleFiles,m=Sn(f,["visibleFiles"]),g=h.includes(u)?h:Fn(Fn([],h,!0),[u],!1);return ue(ue({},m),{activeFile:u,visibleFiles:g})})},resetFile:function(u){i(function(f){var h;return ue(ue({},f),{files:ue(ue({},f.files),(h={},h[u]=e.files[u],h))})})},resetAllFiles:function(){i(function(u){return ue(ue({},u),{files:e.files})})},setActiveFile:function(u){r.files[u]&&i(function(f){return ue(ue({},f),{activeFile:u})})},updateCurrentFile:function(u,f){f===void 0&&(f=!0),o(r.activeFile,u,f)},updateFile:o,addFile:o,closeFile:function(u){r.visibleFiles.length!==1&&i(function(f){var h=f.visibleFiles,m=f.activeFile,g=Sn(f,["visibleFiles","activeFile"]),y=h.indexOf(u),x=h.filter(function(S){return S!==u});return ue(ue({},g),{activeFile:u===m?y===0?h[1]:h[y-1]:m,visibleFiles:x})})},deleteFile:function(u,f){f===void 0&&(f=!0),i(function(h){var m=h.visibleFiles,g=h.files,y=h.activeFile,x=Sn(h,["visibleFiles","files","activeFile"]),S=ue({},g);delete S[u];var k=m.filter(function(E){return E!==u}),T=k.length===0;if(T){var C=Object.keys(g)[Object.keys(g).length-1];return ue(ue({},x),{visibleFiles:[C],activeFile:C,files:S,shouldUpdatePreview:f})}return ue(ue({},x),{visibleFiles:k,activeFile:u===y?k[k.length-1]:y,files:S,shouldUpdatePreview:f})})}};return[ue(ue({},r),{visibleFilesFromProps:e.visibleFiles}),c]},k1=w.createContext(null),F5=function(t){var e,n,r,i=t.children,a=t.options,o=t.style,c=t.className,u=t.theme,f=MJ(t),h=f[0],m=f[1],g=jJ(t,h),y=g[0],x=g[1],S=x.dispatchMessage,k=x.addListener,T=Sn(x,["dispatchMessage","addListener"]),C=AJ(t,h.files);return w.useEffect(function(){T.initializeSandpackIframe()},[]),v.jsx(k1.Provider,{value:ue(ue(ue(ue(ue(ue({},h),y),C),m),T),{autoReload:(n=(e=t.options)===null||e===void 0?void 0:e.autoReload)!==null&&n!==void 0?n:!0,teamId:t?.teamId,exportOptions:(r=t?.customSetup)===null||r===void 0?void 0:r.exportOptions,listen:k,dispatch:S}),children:v.jsx(tJ,{classes:a?.classes,children:v.jsx(iJ,{className:c,style:o,theme:u,children:i})})})};k1.Consumer;function fn(){var t=w.useContext(k1);if(t===null)throw new Error('[sandpack-react]: "useSandpack" must be wrapped by a "SandpackProvider"');var e=t.dispatch,n=t.listen,r=Sn(t,["dispatch","listen"]);return{sandpack:ue({},r),dispatch:e,listen:n}}var gg=function(){var t,e,n,r=fn().sandpack;return{code:(t=r.files[r.activeFile])===null||t===void 0?void 0:t.code,readOnly:(n=(e=r.files[r.activeFile])===null||e===void 0?void 0:e.readOnly)!==null&&n!==void 0?n:!1,updateCode:r.updateCurrentFile}},Ku,ep,Uy,qa=Ee({svg:{margin:"auto"}}),cr=Ee((Ku={appearance:"none",outline:"none",display:"flex",alignItems:"center",fontSize:"inherit",fontFamily:"inherit",backgroundColor:"transparent",transition:"color $default, background $default",cursor:"pointer",color:"$colors$clickable",border:0,textDecoration:"none","&:disabled":{color:"$colors$disabled"},"&:hover:not(:disabled,[data-active='true'])":{color:"$colors$hover"},'&[data-active="true"]':{color:"$colors$accent"},svg:{minWidth:"$space$4",width:"$space$4",height:"$space$4"}},Ku["&.".concat(qa)]={padding:"$space$1",height:"$space$7",display:"flex"},Ku["&.".concat(qa,"&:not(:has(span))")]={width:"$space$7"},Ku["&.".concat(qa,"&:has(svg + span)")]={paddingRight:"$space$3",paddingLeft:"$space$2",gap:"$space$1"},Ku)),Fo=Ee({backgroundColor:"$colors$surface2",borderRadius:"99999px",border:"1px solid $colors$surface3",'&[data-active="true"]':{color:"$colors$surface1",background:"$colors$accent"},"&:hover:not(:disabled,[data-active='true'])":{backgroundColor:"$colors$surface3"}}),NJ=Ee({padding:0}),C1=q5({"0%":{opacity:0},"100%":{opacity:1}}),fd=Ee({position:"absolute",bottom:"0",left:"0",right:"0",top:"0",margin:"0",overflow:"auto",height:"100%",zIndex:"$top"}),W5=Ee((ep={whiteSpace:"pre-wrap",padding:"$space$10",backgroundColor:"$colors$surface1",display:"flex",gap:"$space$2",flexDirection:"column"},ep[".".concat(cr)]={width:"auto",gap:"$space$2",padding:"0 $space$3 0 $space$2",marginTop:"$space$1"},ep.variants={solidBg:{true:{backgroundColor:"$colors$errorSurface"}}},ep)),Rb=Ee((Uy={padding:"$space$10",backgroundColor:"$colors$surface1"},Uy[".".concat(cr)]={marginTop:"$space$6",width:"auto",gap:"$space$2",padding:"0 $space$3 0 $space$2"},Uy)),Ps=Ee({animation:"".concat(C1," 150ms ease"),color:"$colors$error",display:"flex",flexDirection:"column",gap:"$space$3",variants:{errorCode:{true:{fontFamily:"$font$mono"}}},a:{color:"inherit"},p:{margin:0}}),Yy,DJ=Ee({borderBottom:"1px solid $colors$surface2",background:"$colors$surface1"}),zJ=Ee({padding:"0 $space$2",overflow:"auto",display:"flex",flexWrap:"nowrap",alignItems:"stretch",minHeight:"40px",marginBottom:"-1px"}),LJ=Ee({display:"flex",alignItems:"center",outline:"none",position:"relative",paddingRight:"20px",margin:"1px 0","&:has(button:focus)":{outline:"$colors$accent auto 1px"}}),G5=Ee({padding:"0 $space$1 0 $space$1",borderRadius:"$border$radius",marginLeft:"$space$1",width:"$space$5",visibility:"hidden",cursor:"pointer",position:"absolute",right:"0px",svg:{width:"$space$3",height:"$space$3",display:"block",position:"relative",top:1}}),ZJ=Ee((Yy={padding:"0 $space$2",height:"$layout$headerHeight",whiteSpace:"nowrap","&:focus":{outline:"none"}},Yy["&:hover ~ .".concat(G5)]={visibility:"visible"},Yy)),H5=function(t){var e=t.closableTabs,n=t.className,r=t.activeFileUniqueId,i=Sn(t,["closableTabs","className","activeFileUniqueId"]),a=fn().sandpack,o=Nn(),c=a.activeFile,u=a.visibleFiles,f=a.setActiveFile,h=w.useState(null),m=h[0],g=h[1],y=function(S){var k=dm(S),T=u.reduce(function(C,E){if(E===S)return C;var R=dm(E);return R===k&&C.push(E),C},[]);return T.length===0?k:FK(S,T)},x=function(S){var k,T,C,E,R=S.e,$=S.index,P=R.currentTarget;switch(R.key){case"ArrowLeft":{var _=P.previousElementSibling;_&&((k=_.querySelector("button"))===null||k===void 0||k.focus(),f(u[$-1]))}break;case"ArrowRight":{var M=P.nextElementSibling;M&&((T=M.querySelector("button"))===null||T===void 0||T.focus(),f(u[$+1]))}break;case"Home":{var V=P.parentElement,F=V.firstElementChild;(C=F.querySelector("button"))===null||C===void 0||C.focus(),f(u[0]);break}case"End":{var W=P.parentElement,I=W.lastElementChild;(E=I.querySelector("button"))===null||E===void 0||E.focus(),f(u[-1]);break}}};return v.jsx("div",ue({className:o("tabs",[DJ,n]),translate:"no"},i,{children:v.jsx("div",{"aria-label":"Select active file",className:o("tabs-scrollable-container",[zJ]),role:"tablist",children:u.map(function(S,k){return v.jsxs("div",{"aria-controls":"".concat(S,"-").concat(r,"-tab-panel"),"aria-selected":S===c,className:o("tab-container",[LJ]),onKeyDown:function(T){return x({e:T,index:k})},onMouseEnter:function(){return g(k)},onMouseLeave:function(){return g(null)},role:"tab",children:[v.jsx("button",{className:o("tab-button",[cr,ZJ]),"data-active":S===c,id:"".concat(S,"-").concat(r,"-tab"),onClick:function(){return f(S)},tabIndex:S===c?0:-1,title:S,type:"button",children:y(S)}),e&&u.length>1&&v.jsx("span",{className:o("close-button",[G5]),onClick:function(T){T.stopPropagation(),a.closeFile(S)},style:{visibility:S===c||m===k?"visible":"hidden"},tabIndex:S===c?0:-1,children:v.jsx(qK,{})})]},S)})})}))},Dd=function(t){var e=t.onClick,n=t.className,r=t.children,i=Nn();return v.jsx("button",{className:i("button",[i("icon-standalone"),cr,qa,Fo,n]),onClick:e,type:"button",children:r})},VJ=Ee({position:"absolute",bottom:"$space$2",right:"$space$2",paddingRight:"$space$3"}),K5=function(t){t.className;var e=t.onClick,n=Sn(t,["className","onClick"]),r=fn().sandpack;return v.jsxs(Dd,ue({className:VJ.toString(),onClick:function(i){r.runSandpack(),e?.(i)}},n,{children:[v.jsx(ZK,{}),v.jsx("span",{children:"Run"})]}))},Fy,J5=Ee((Fy={display:"flex",flexDirection:"column",width:"100%",position:"relative",backgroundColor:"$colors$surface1",gap:1},Fy["&:has(.".concat(jt,"-stack)")]={backgroundColor:"$colors$surface2"},Fy)),Og=function(t){var e=t.className,n=Sn(t,["className"]),r=Nn();return v.jsx("div",ue({className:r("stack",[J5,e])},n))},XJ=function(){var t=w.useContext(w1),e=t.theme,n=t.id,r=t.mode;return{theme:e,themeId:n,themeMode:r}},EQ=function(t,e){if(t.length!==e.length)return!1;for(var n=!0,r=0;r<t.length;r++)if(t[r]!==e[r]){n=!1;break}return n},_b=function(t,e){var n=e.line,r=e.column;return t.line(n).from+(r??0)-1},BJ=function(){return qe.theme({"&":{backgroundColor:"var(--".concat(jt,"-colors-surface1)"),color:"var(--".concat(jt,"-syntax-color-plain)"),height:"100%"},".cm-matchingBracket, .cm-nonmatchingBracket, &.cm-focused .cm-matchingBracket, &.cm-focused .cm-nonmatchingBracket":{color:"inherit",backgroundColor:"rgba(128,128,128,.25)",backgroundBlendMode:"difference"},"&.cm-editor.cm-focused":{outline:"none"},"& .cm-activeLine":{backgroundColor:"transparent"},"&.cm-editor.cm-focused .cm-activeLine":{backgroundColor:"var(--".concat(jt,"-colors-surface3)"),borderRadius:"var(--".concat(jt,"-border-radius)")},".cm-errorLine":{backgroundColor:"var(--".concat(jt,"-colors-errorSurface)"),borderRadius:"var(--".concat(jt,"-border-radius)")},".cm-content":{caretColor:"var(--".concat(jt,"-colors-accent)"),padding:"0 var(--".concat(jt,"-space-4)")},".cm-scroller":{fontFamily:"var(--".concat(jt,"-font-mono)"),lineHeight:"var(--".concat(jt,"-font-lineHeight)")},".cm-gutters":{backgroundColor:"var(--".concat(jt,"-colors-surface1)"),color:"var(--".concat(jt,"-colors-disabled)"),border:"none",paddingLeft:"var(--".concat(jt,"-space-1)")},".cm-gutter.cm-lineNumbers":{fontSize:".6em"},".cm-lineNumbers .cm-gutterElement":{lineHeight:"var(--".concat(jt,"-font-lineHeight)"),minWidth:"var(--".concat(jt,"-space-5)")},".cm-content .cm-line":{paddingLeft:"var(--".concat(jt,"-space-1)")},".cm-content.cm-readonly .cm-line":{paddingLeft:0}})},Ji=function(t){return"".concat(jt,"-syntax-").concat(t)},IJ=function(){var t=["string","plain","comment","keyword","definition","punctuation","property","tag","static"];return t.reduce(function(e,n){var r;return ue(ue({},e),(r={},r[".".concat(Ji(n))]={color:"$syntax$color$".concat(n),fontStyle:"$syntax$fontStyle$".concat(n)},r))},{})},qJ=function(t){return cg.define([{tag:J.link,textDecoration:"underline"},{tag:J.emphasis,fontStyle:"italic"},{tag:J.strong,fontWeight:"bold"},{tag:J.keyword,class:Ji("keyword")},{tag:[J.atom,J.number,J.bool],class:Ji("static")},{tag:J.variableName,class:Ji("plain")},{tag:J.standard(J.tagName),class:Ji("tag")},{tag:[J.function(J.variableName),J.definition(J.function(J.variableName)),J.tagName],class:Ji("definition")},{tag:J.propertyName,class:Ji("property")},{tag:[J.literal,J.inserted],class:Ji(t.syntax.string?"string":"static")},{tag:J.punctuation,class:Ji("punctuation")},{tag:[J.comment,J.quote],class:Ji("comment")}])},UJ=function(t,e,n){if(!t&&!e)return"javascript";var r=e;if(!r&&t){var i=t.lastIndexOf(".");r=t.slice(i+1)}for(var a=0,o=n;a<o.length;a++){var c=o[a];if(r===c.name||c.extensions.includes(r||""))return c.name}switch(r){case"ts":case"tsx":return"typescript";case"html":case"svelte":case"vue":case"astro":return"html";case"css":case"less":case"scss":return"css";default:return"javascript"}},YJ=function(t,e){for(var n={javascript:Eb({jsx:!0,typescript:!1}),typescript:Eb({jsx:!0,typescript:!0}),html:QK(),css:m5()},r=0,i=e;r<i.length;r++){var a=i[r];if(t===a.name)return a.language}return n[t]},eM=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];return w.useCallback(function(n){return t.forEach(function(r){if(r){if(typeof r=="function")return r(n);r.current=n}})},t)};function FJ(t){return ci.fromClass((function(){function e(n){this.decorations=this.getDecoration(n)}return e.prototype.update=function(n){},e.prototype.getDecoration=function(n){if(!t)return dt.none;var r=t.map(function(i){var a,o,c,u=dt.line({attributes:{class:(a=i.className)!==null&&a!==void 0?a:""}}),f=dt.mark({class:(o=i.className)!==null&&o!==void 0?o:"",attributes:(c=i.elementAttributes)!==null&&c!==void 0?c:void 0}),h=_b(n.state.doc,{line:i.line,column:i.startColumn})+1;if(i.startColumn&&i.endColumn){var m=_b(n.state.doc,{line:i.line,column:i.endColumn})+1;return f.range(h,m)}return u.range(h)});return dt.set(r)},e})(),{decorations:function(e){return e.decorations}})}function WJ(){return HJ}var GJ=dt.line({attributes:{class:"cm-errorLine"}}),HJ=ci.fromClass((function(){function t(){this.decorations=dt.none}return t.prototype.update=function(e){var n=this;e.transactions.forEach(function(r){var i=r.annotation("show-error");if(i!==void 0){var a=_b(e.view.state.doc,{line:i})+1;n.decorations=dt.set([GJ.range(a)])}else r.annotation("remove-errors")&&(n.decorations=dt.none)})},t})(),{decorations:function(t){return t.decorations}}),tp,Wy,$b=Ee({margin:"0",display:"block",fontFamily:"$font$mono",fontSize:"$font$size",color:"$syntax$color$plain",lineHeight:"$font$lineHeight"}),QQ=Ee(IJ()),tM=Ee((tp={flex:1,position:"relative",overflow:"auto",background:"$colors$surface1",".cm-scroller":{padding:"$space$4 0"}},tp[".".concat($b)]={padding:"$space$4 0"},tp["@media screen and (max-width: 768px)"]={"@supports (-webkit-overflow-scrolling: touch)":{".cm-content":{fontSize:"16px"}}},tp)),AQ=Ee({margin:"0",outline:"none",height:"100%"}),KJ=Ee((Wy={fontFamily:"$font$mono",fontSize:"0.8em",position:"absolute",right:"$space$2",bottom:"$space$2",zIndex:"$top",color:"$colors$clickable",backgroundColor:"$colors$surface2",borderRadius:"99999px",padding:"calc($space$1 / 2) $space$2"},Wy["& + .".concat(cr)]={right:"calc($space$11 * 2)"},Wy)),JJ=function(t){var e=t.langSupport,n=t.highlightTheme,r=t.code,i=r===void 0?"":r,a=e.language.parser.parse(i),o=0,c=[],u=function(f,h){if(f>o){var m=i.slice(o,f);c.push(h?w.createElement("span",{children:m,className:h,key:"".concat(f).concat(o)}):m),o=f}};return pj(a,n,function(f,h,m){u(f,""),u(h,m)}),o<i.length&&i?.includes(`
|
|
788
|
-
`)&&c.push(`
|
|
789
|
-
|
|
790
|
-
`),c},T1=w.forwardRef(function(t,e){var n=t.code,r=n===void 0?"":n,i=t.filePath,a=t.fileType,o=t.onCodeUpdate,c=t.showLineNumbers,u=c===void 0?!1:c,f=t.showInlineErrors,h=f===void 0?!1:f,m=t.wrapContent,g=m===void 0?!1:m,y=t.editorState,x=y===void 0?"pristine":y,S=t.readOnly,k=S===void 0?!1:S,T=t.showReadOnly,C=T===void 0?!0:T,E=t.decorators,R=t.initMode,$=R===void 0?"lazy":R,P=t.extensions,_=P===void 0?[]:P,M=t.extensionsKeymap,V=M===void 0?[]:M,F=t.additionalLanguages,W=F===void 0?[]:F,I=w.useRef(null),ne=eM(I,e),ee=w.useRef(),pe=XJ(),D=pe.theme,G=pe.themeId,B=w.useState(r),ye=B[0],X=B[1],A=w.useState($==="immediate"),N=A[0],L=A[1],q=Nn(),se=fn(),he=se.listen,H=se.sandpack.autoReload,ge=w.useRef([]),xe=w.useRef([]),ke=oG(I,{rootMargin:"600px 0px",threshold:.2}).isIntersecting;w.useImperativeHandle(e,function(){return{getCodemirror:function(){return ee.current}}}),w.useEffect(function(){var Ue=$==="lazy"||$==="user-visible";Ue&&ke&&L(!0)},[$,ke]);var Ce=UJ(i,a,W),Re=YJ(Ce,W),We=qJ(D),Pe=JJ({langSupport:Re,highlightTheme:We,code:r}),ht=w.useMemo(function(){return E&&E.sort(function(Ue,Ge){return Ue.line-Ge.line})},[E]),Ke=k&&(E?.length===0||E===void 0);w.useEffect(function(){if(!(!I.current||!N||Ke)){var Ue=I.current,Ge=Ue.querySelector(".sp-pre-placeholder");Ge&&Ue.removeChild(Ge);var z=new qe({doc:r,extensions:[],parent:Ue});return z.contentDOM.setAttribute("data-gramm","false"),z.contentDOM.setAttribute("data-lt-active","false"),z.contentDOM.setAttribute("aria-label",i?"Code Editor for ".concat(dm(i)):"Code Editor"),z.contentDOM.setAttribute("tabIndex","-1"),ee.current=z,function(){var Y;(Y=ee.current)===null||Y===void 0||Y.destroy()}}},[N,k,Ke]),w.useEffect(function(){if(!Ke&&ee.current){var Ue=[{key:"Tab",run:function(z){var Y,oe;s5(z);var te=V.find(function(fe){var Oe=fe.key;return Oe==="Tab"});return(oe=(Y=te?.run)===null||Y===void 0?void 0:Y.call(te,z))!==null&&oe!==void 0?oe:!0}},{key:"Shift-Tab",run:function(z){var Y,oe;o5({state:z.state,dispatch:z.dispatch});var te=V.find(function(fe){var Oe=fe.key;return Oe==="Shift-Tab"});return(oe=(Y=te?.run)===null||Y===void 0?void 0:Y.call(te,z))!==null&&oe!==void 0?oe:!0}},{key:"Escape",run:function(){return k||I.current&&I.current.focus(),!0}},{key:"mod-Backspace",run:g1}],Ge=Fn(Fn([lY(),nW(),NF()],_,!0),[Ad.of(Fn(Fn(Fn(Fn(Fn([],ZF,!0),iG,!0),dW,!0),Ue,!0),V,!0)),Re,BJ(),aF(We),qe.updateListener.of(function(z){if(z.docChanged){var Y=z.state.doc.toString();X(Y),o?.(Y)}})],!1);k?(Ge.push(At.readOnly.of(!0)),Ge.push(qe.editable.of(!1))):(Ge.push(pF()),Ge.push(pY())),ht&&Ge.push(FJ(ht)),g&&Ge.push(qe.lineWrapping),u&&Ge.push(CY()),h&&Ge.push(WJ()),ee.current.dispatch({effects:Vt.reconfigure.of(Ge)})}},[N,ht,u,g,G,k,Ke,H]),w.useEffect(function(){var Ge=ee.current,z=!EQ(_,ge.current)||!EQ(V,xe.current);Ge&&z&&(Ge.dispatch({effects:Vt.appendConfig.of(_)}),Ge.dispatch({effects:Vt.appendConfig.of(Ad.of(Fn([],V,!0)))}),ge.current=_,xe.current=V)},[_,V]),w.useEffect(function(){ee.current&&x==="dirty"&&window.matchMedia("(min-width: 768px)").matches&&ee.current.contentDOM.focus()},[]),w.useEffect(function(){if(ee.current&&typeof r=="string"&&r!==ye){var Ue=ee.current,Ge=Ue.state.selection.ranges.some(function(Y){var oe=Y.to,te=Y.from;return oe>r.length||te>r.length})?Se.cursor(r.length):Ue.state.selection,z={from:0,to:Ue.state.doc.length,insert:r};Ue.dispatch({changes:z,selection:Ge})}},[r]),w.useEffect(function(){if(h){var Ge=he(function(z){var Y=ee.current;z.type==="success"?Y?.dispatch({annotations:[new Ri("remove-errors",!0)]}):z.type==="action"&&z.action==="show-error"&&z.path===i&&z.line&&Y?.dispatch({annotations:[new Ri("show-error",z.line)]})});return function(){return Ge()}}},[he,h]);var tt=function(Ue){Ue.key==="Enter"&&ee.current&&(Ue.preventDefault(),ee.current.contentDOM.focus())},bt=function(){var Ue=4;return u&&(Ue+=6),k||(Ue+=1),"var(--".concat(jt,"-space-").concat(Ue,")")};return Ke?v.jsxs(v.Fragment,{children:[v.jsx("pre",{ref:ne,className:q("cm",[q(x),q(Ce),AQ,QQ]),translate:"no",children:v.jsx("code",{className:q("pre-placeholder",[$b]),style:{marginLeft:bt()},children:Pe})}),k&&C&&v.jsx("span",ue({className:q("read-only",[KJ])},{},{children:"Read-only"}))]}):v.jsx("div",{ref:ne,"aria-autocomplete":"list","aria-label":i?"Code Editor for ".concat(dm(i)):"Code Editor","aria-multiline":"true",className:q("cm",[q(x),q(Ce),AQ,QQ]),onKeyDown:tt,role:"textbox",tabIndex:0,translate:"no",suppressHydrationWarning:!0,children:v.jsx("pre",{className:q("pre-placeholder",[$b]),style:{marginLeft:bt()},children:Pe})})}),nM=w.forwardRef(function(t,e){var n=t.showTabs,r=t.showLineNumbers,i=r===void 0?!1:r,a=t.showInlineErrors,o=a===void 0?!1:a,c=t.showRunButton,u=c===void 0?!0:c,f=t.wrapContent,h=f===void 0?!1:f,m=t.closableTabs,g=m===void 0?!1:m,y=t.initMode,x=t.extensions,S=t.extensionsKeymap,k=t.readOnly,T=t.showReadOnly,C=t.additionalLanguages,E=t.className,R=Sn(t,["showTabs","showLineNumbers","showInlineErrors","showRunButton","wrapContent","closableTabs","initMode","extensions","extensionsKeymap","readOnly","showReadOnly","additionalLanguages","className"]),$=fn().sandpack,P=gg(),_=P.code,M=P.updateCode,V=P.readOnly,F=$.activeFile,W=$.status,I=$.editorState,ne=n??$.visibleFiles.length>1,ee=Nn(),pe=function(G,B){B===void 0&&(B=!0),M(G,B)},D=Y5();return v.jsxs(Og,ue({className:ee("editor",[E])},R,{children:[ne&&v.jsx(H5,{activeFileUniqueId:D,closableTabs:g}),v.jsxs("div",{"aria-labelledby":"".concat(F,"-").concat(D,"-tab"),className:ee("code-editor",[tM]),id:"".concat(F,"-").concat(D,"-tab-panel"),role:"tabpanel",children:[v.jsx(T1,{ref:e,additionalLanguages:C,code:_,editorState:I,extensions:x,extensionsKeymap:S,filePath:F,initMode:y||$.initMode,onCodeUpdate:function(G){var B;return pe(G,(B=$.autoReload)!==null&&B!==void 0?B:!0)},readOnly:k||V,showInlineErrors:o,showLineNumbers:i,showReadOnly:T,wrapContent:h},F),u&&(!$.autoReload||W==="idle")?v.jsx(K5,{}):null]})]}))});w.forwardRef(function(t,e){var n=t.showTabs,r=t.showLineNumbers,i=t.decorators,a=t.code,o=t.initMode,c=t.wrapContent,u=t.additionalLanguages,f=Sn(t,["showTabs","showLineNumbers","decorators","code","initMode","wrapContent","additionalLanguages"]),h=fn().sandpack,m=gg().code,g=Nn(),y=n??h.visibleFiles.length>1,x=Y5();return v.jsxs(Og,ue({className:g("editor-viewer")},f,{children:[y?v.jsx(H5,{activeFileUniqueId:x}):null,v.jsx("div",{"aria-labelledby":"".concat(h.activeFile,"-").concat(x,"-tab"),className:g("code-editor",[tM]),id:"".concat(h.activeFile,"-").concat(x,"-tab-panel"),role:"tabpanel",children:v.jsx(T1,{ref:e,additionalLanguages:u,code:a??m,decorators:i,filePath:h.activeFile,initMode:o||h.initMode,showLineNumbers:r,showReadOnly:!1,wrapContent:c,readOnly:!0})}),h.status==="idle"?v.jsx(K5,{}):null]}))});var np,rp,eee=Ee((np={border:"1px solid $colors$surface2",display:"flex",flexWrap:"wrap",alignItems:"stretch",borderRadius:"$border$radius",overflow:"hidden",position:"relative",backgroundColor:"$colors$surface2",gap:1},np["> .".concat(J5)]={flexGrow:1,flexShrink:1,flexBasis:"0",height:"$layout$height",overflow:"hidden","@media print":{height:"auto",display:"block"},"@media screen and (max-width: 768px)":(rp={},rp["&:not(.".concat(jt,"-preview, .").concat(jt,"-editor, .").concat(jt,"-preset-column)")]={height:"calc($layout$height / 2)"},rp.minWidth="100%;",rp)},np["> .".concat(jt,"-file-explorer")]={flex:.2,minWidth:200,"@media screen and (max-width: 768px)":{flex:1}},np)),tee=w.forwardRef(function(t,e){var n=t.children,r=t.className,i=Sn(t,["children","className"]),a=fn().sandpack,o=Nn(),c=eM(a.lazyAnchorRef,e);return v.jsx("div",ue({ref:c,className:o("layout",[eee,r])},i,{children:n}))}),nee=function(){var t,e=fn().sandpack,n=e.error;return(t=n?.message)!==null&&t!==void 0?t:null},rM=200,ree=function(t,e){var n=fn(),r=n.sandpack,i=n.listen,a=w.useState("LOADING"),o=a[0],c=a[1];return w.useEffect(function(){var u=i(function(f){f.type==="start"&&f.firstLoad===!0&&c("LOADING"),f.type==="done"&&c(function(h){return h==="LOADING"?"PRE_FADING":"HIDDEN"})},t);return function(){u()}},[t,r.status==="idle"]),w.useEffect(function(){var u;return o==="PRE_FADING"&&!e?c("FADING"):o==="FADING"&&(u=setTimeout(function(){return c("HIDDEN")},rM)),function(){clearTimeout(u)}},[o,e]),r.status==="timeout"?"TIMEOUT":r.status!=="running"?"HIDDEN":o},iee=function(t){var e=fn().dispatch;return{refresh:function(){return e({type:"refresh"},t)},back:function(){return e({type:"urlback"},t)},forward:function(){return e({type:"urlforward"},t)}}},iM=function(t){var e=fn(),n=e.sandpack,r=e.listen,i=e.dispatch,a=w.useRef(null),o=w.useRef(Qc());w.useEffect(function(){var u=a.current,f=o.current;return u!==null&&n.registerBundler(u,f,t),function(){return n.unregisterBundler(f)}},[]);var c=function(){return n.clients[o.current]||null};return{sandpack:n,getClient:c,clientId:o.current,iframe:a,listen:function(u){return r(u,o.current)},dispatch:function(u){return i(u,o.current)}}},E1=function(t){var e=fn().dispatch;return{restart:function(){return e({type:"shell/restart"},t)},openPreview:function(){return e({type:"shell/openPreview"},t)}}},aee=function(t,e){var n;switch(t.state){case"downloading_manifest":return"[1/3] Downloading manifest";case"downloaded_module":return"[2/3] Downloaded ".concat(t.name," (").concat(e-t.totalPending,"/").concat(e,")");case"starting_command":return"[3/3] Starting command";case"command_running":return'[3/3] Running "'.concat((n=t.command)===null||n===void 0?void 0:n.trim(),'"')}},aM=function(t){var e=w.useState(!1),n=e[0],r=e[1],i=w.useState(),a=i[0],o=i[1],c=w.useState(null),u=c[0],f=c[1],h=t?.timeout,m=t?.clientId,g=fn().listen;return w.useEffect(function(){var y,x=g(function(S){S.type==="start"&&S.firstLoad&&r(!1),h&&(y=setTimeout(function(){f(null)},h)),S.type==="dependencies"?f(function(){switch(S.data.state){case"downloading_manifest":return"[1/3] Downloading manifest";case"downloaded_module":return"[2/3] Downloaded ".concat(S.data.name," (").concat(S.data.progress,"/").concat(S.data.total,")");case"starting":return"[3/3] Starting"}return null}):S.type==="shell/progress"&&!n&&(!a&&S.data.state==="downloaded_module"&&o(S.data.totalPending),a!==void 0&&f(aee(S.data,a))),S.type==="done"&&S.compilatonError===!1&&(f(null),r(!0),clearTimeout(y))},m);return function(){y&&clearTimeout(y),x()}},[m,n,a,h]),u},see=400*2,sM=function(t){var e=t.clientId,n=t.maxMessageCount,r=n===void 0?see:n;t.resetOnPreviewRestart;var i=w.useState([]),a=i[0],o=i[1],c=fn().listen;return w.useEffect(function(){var u=c(function(f){f.type==="start"?o([]):f.type==="stdout"&&f.payload.data&&f.payload.data.trim()&&o(function(h){for(var m=Fn(Fn([],h,!0),[{data:f.payload.data,id:Qc()}],!1);m.length>r;)m.shift();return m})},e);return u},[r,e]),{logs:a,reset:function(){return o([])}}},oee=function(t){var e=t.replace("[sandpack-client]: ","");if(/process.exit/.test(e)){var n=e.match(/process.exit\((\d+)\)/);return n?Number(n[1])===0?"Server is not running, would you like to start it again?":"Server has crashed with status code ".concat(n[1],", would you like to restart the server?"):e}return e},lee=function(t){var e=t.children,n=t.className,r=Sn(t,["children","className"]),i=nee(),a=E1().restart,o=Nn(),c=fn().sandpack,u=c.runSandpack,f=c.teamId,h=fn().dispatch;if(!i&&!e)return null;var m=i?.startsWith("[sandpack-client]"),g=i?.includes("NPM_REGISTRY_UNAUTHENTICATED_REQUEST"),y=function(){f&&h({type:"sign-in",teamId:f})};return g?v.jsxs("div",ue({className:o("overlay",[o("error"),fd,Rb,n])},t,{children:[v.jsx("p",{className:o("error-message",[Ps]),children:v.jsx("strong",{children:"Unable to fetch required dependency."})}),v.jsx("div",{className:o("error-message",[Ps]),children:v.jsxs("p",{children:["Authentication required. Please sign in to your account (make sure to allow pop-ups to this page) and try again. If the issue persists, contact"," ",v.jsx("a",{href:"mailto:hello@codesandbox.io?subject=Sandpack Timeout Error",children:"support"})," ","for further assistance."]})}),v.jsx("div",{children:v.jsxs("button",{className:o("button",[cr,qa,Fo]),onClick:y,children:[v.jsx(zK,{}),v.jsx("span",{children:"Sign in"})]})})]})):m&&i?v.jsx("div",ue({className:o("overlay",[o("error"),fd,Rb,n])},r,{children:v.jsxs("div",{className:o("error-message",[Ps]),children:[v.jsx("p",{className:o("error-title",[Ee({fontWeight:"bold"})]),children:"Couldn't connect to server"}),v.jsx("p",{children:oee(i)}),v.jsx("div",{children:v.jsxs("button",{className:o("button",[o("icon-standalone"),cr,qa,Fo]),onClick:function(){a(),u()},title:"Restart script",type:"button",children:[v.jsx(mg,{})," ",v.jsx("span",{children:"Restart"})]})})]})})):v.jsxs("div",ue({className:o("overlay",[o("error"),fd,W5({solidBg:!0}),n]),translate:"no"},r,{children:[v.jsx("p",{className:o("error-message",[Ps]),children:v.jsx("strong",{children:"Something went wrong"})}),v.jsx("p",{className:o("error-message",[Ps({errorCode:!0})]),children:i||e})]}))};function cee(t,e){return e===void 0&&(e=!1),t=jK.escapeCarriageReturn(pee(t)),$K.ansiToJson(t,{json:!0,remove_empty:!0,use_classes:e})}function uee(t){var e="";return t.bg&&(e+="".concat(t.bg,"-bg ")),t.fg&&(e+="".concat(t.fg,"-fg ")),t.decoration&&(e+="ansi-".concat(t.decoration," ")),e===""?null:(e=e.substring(0,e.length-1),e)}function dee(t){var e={};switch(t.bg&&(e.backgroundColor="rgb(".concat(t.bg,")")),t.fg&&(e.color="rgb(".concat(t.fg,")")),t.decoration){case"bold":e.fontWeight="bold";break;case"dim":e.opacity="0.5";break;case"italic":e.fontStyle="italic";break;case"hidden":e.visibility="hidden";break;case"strikethrough":e.textDecoration="line-through";break;case"underline":e.textDecoration="underline";break;case"blink":e.textDecoration="blink";break}return e}function fee(t,e,n,r){var i=e?null:dee(n),a=e?uee(n):null;if(!t)return w.createElement("span",{style:i,key:r,className:a},n.content);for(var o=[],c=/(\s|^)(https?:\/\/(?:www\.|(?!www))[^\s.]+\.[^\s]{2,}|www\.[^\s]+\.[^\s]{2,})/g,u=0,f;(f=c.exec(n.content))!==null;){var h=f[1],m=f[2],g=f.index+h.length;g>u&&o.push(n.content.substring(u,g));var y=m.startsWith("www.")?"http://".concat(m):m;o.push(w.createElement("a",{key:u,href:y,target:"_blank"},"".concat(m))),u=c.lastIndex}return u<n.content.length&&o.push(n.content.substring(u)),w.createElement("span",{style:i,key:r,className:a},o)}function hee(t){var e=t.className,n=t.useClasses,r=t.children,i=t.linkify;return w.createElement("code",{className:e},cee(r??"",n??!1).map(fee.bind(null,i??!1,n??!1)))}function pee(t){var e=t;do t=e,e=t.replace(/[^\n]\x08/gm,"");while(e.length<t.length);return t}var oM=function(t){var e=t.data,n=Nn();return v.jsx(v.Fragment,{children:e.map(function(r){var i=r.data,a=r.id;return v.jsx("div",{className:n("console-item",[mee]),children:v.jsx(hee,{children:i})},a)})})},mee=Ee({width:"100%",padding:"$space$3 $space$2",fontSize:".85em",position:"relative",whiteSpace:"pre","&:not(:first-child):after":{content:"",position:"absolute",top:0,left:0,right:0,height:1,background:"$colors$surface3"}}),gee=function(t){return DK.compressToBase64(JSON.stringify(t)).replace(/\+/g,"-").replace(/\//g,"_").replace(/=+$/,"")},RQ="https://codesandbox.io/api/v1/sandboxes/define",Oee=function(t,e){var n=Object.keys(t).reduce(function(r,i){var a,o=i.replace("/",""),c={content:t[i].code,isBinary:!1};return ue(ue({},r),(a={},a[o]=c,a))},{});return gee(ue({files:n},e?{template:e}:null))},vee=function(t){var e=fn().sandpack;return e.exportOptions?v.jsx(yee,ue({state:e},t)):v.jsx(bee,ue({state:e},t))},yee=function(t){var e=t.children,n=t.state,r=Sn(t,["children","state"]),i=function(){return _s(void 0,void 0,void 0,function(){var a,o,c,u;return $s(this,function(f){switch(f.label){case 0:if(!(!((u=n.exportOptions)===null||u===void 0)&&u.apiToken))throw new Error("Missing `apiToken` property");return a=Object.keys(n.files).reduce(function(h,m){var g,y=m.replace("/","");return ue(ue({},h),(g={},g[y]=n.files[m],g))},{}),[4,fetch("https://api.codesandbox.io/sandbox",{method:"POST",body:JSON.stringify({template:n.environment,files:a,privacy:n.exportOptions.privacy==="public"?0:2}),headers:{Authorization:"Bearer ".concat(n.exportOptions.apiToken),"Content-Type":"application/json","X-CSB-API-Version":"2023-07-01"}})];case 1:return o=f.sent(),[4,o.json()];case 2:return c=f.sent(),window.open("https://codesandbox.io/p/sandbox/".concat(c.data.alias,"?file=/").concat(n.activeFile,"&utm-source=storybook-addon"),"_blank"),[2]}})})};return v.jsx("button",ue({onClick:i,title:"Export to workspace in CodeSandbox",type:"button"},r,{children:e}))},bee=function(t){var e,n,r,i=t.children,a=t.state,o=Sn(t,["children","state"]),c=w.useRef(null),u=w.useState(),f=u[0],h=u[1];return w.useEffect(function(){var g=setTimeout(function(){var y=Oee(a.files,a.environment),x=new URLSearchParams({parameters:y,query:new URLSearchParams({file:a.activeFile,utm_medium:"sandpack"}).toString()});h(x)},600);return function(){clearTimeout(g)}},[a.activeFile,a.environment,a.files]),((r=(n=(e=f?.get)===null||e===void 0?void 0:e.call(f,"parameters"))===null||n===void 0?void 0:n.length)!==null&&r!==void 0?r:0)>1500?v.jsxs("button",ue({onClick:function(){var m;return(m=c.current)===null||m===void 0?void 0:m.submit()},title:"Open in CodeSandbox",type:"button"},o,{children:[v.jsxs("form",{ref:c,action:RQ,method:"POST",style:{visibility:"hidden"},target:"_blank",children:[v.jsx("input",{name:"environment",type:"hidden",value:a.environment==="node"?"server":a.environment}),Array.from(f,function(m){var g=m[0],y=m[1];return v.jsx("input",{name:g,type:"hidden",value:y},g)})]}),i]})):v.jsx("a",ue({href:"".concat(RQ,"?").concat(f?.toString(),"&environment=").concat(a.environment==="node"?"server":a.environment),rel:"noreferrer noopener",target:"_blank",title:"Open in CodeSandbox"},o,{children:i}))},lM=function(){var t=Nn();return v.jsxs(vee,{className:t("button",[t("icon-standalone"),cr,qa,Fo]),children:[v.jsx(IK,{}),v.jsx("span",{children:"Open Sandbox"})]})},wo,Pb=Ee({transform:"translate(-4px, 9px) scale(0.13, 0.13)","*":{position:"absolute",width:"96px",height:"96px"}}),xee=Ee((wo={position:"absolute",right:"$space$2",bottom:"$space$2",zIndex:"$top",width:"32px",height:"32px",borderRadius:"$border$radius"},wo[".".concat(Pb)]={display:"flex"},wo[".sp-button.".concat(cr)]={display:"none"},wo["&:hover .sp-button.".concat(cr)]={display:"flex"},wo["&:hover .sp-button.".concat(cr," > span")]={display:"none"},wo["&:hover .".concat(Pb)]={display:"none"},wo)),See=q5({"0%":{transform:"rotateX(-25.5deg) rotateY(45deg)"},"100%":{transform:"rotateX(-25.5deg) rotateY(405deg)"}}),wee=Ee({animation:"".concat(See," 1s linear infinite"),animationFillMode:"forwards",transformStyle:"preserve-3d",transform:"rotateX(-25.5deg) rotateY(45deg)","*":{border:"10px solid $colors$clickable",borderRadius:"8px",background:"$colors$surface1"},".top":{transform:"rotateX(90deg) translateZ(44px)",transformOrigin:"50% 50%"},".bottom":{transform:"rotateX(-90deg) translateZ(44px)",transformOrigin:"50% 50%"},".front":{transform:"rotateY(0deg) translateZ(44px)",transformOrigin:"50% 50%"},".back":{transform:"rotateY(-180deg) translateZ(44px)",transformOrigin:"50% 50%"},".left":{transform:"rotateY(-90deg) translateZ(44px)",transformOrigin:"50% 50%"},".right":{transform:"rotateY(90deg) translateZ(44px)",transformOrigin:"50% 50%"}}),kee=function(t){var e=t.className,n=t.showOpenInCodeSandbox,r=Sn(t,["className","showOpenInCodeSandbox"]),i=Nn();return v.jsxs("div",ue({className:i("cube-wrapper",[xee,e]),title:"Open in CodeSandbox"},r,{children:[n&&v.jsx(lM,{}),v.jsx("div",{className:i("cube",[Pb]),children:v.jsxs("div",{className:i("sides",[wee]),children:[v.jsx("div",{className:"top"}),v.jsx("div",{className:"right"}),v.jsx("div",{className:"bottom"}),v.jsx("div",{className:"left"}),v.jsx("div",{className:"front"}),v.jsx("div",{className:"back"})]})})]}))},Cee=Ee({backgroundColor:"$colors$surface1"}),Tee=function(t){var e=t.clientId,n=t.loading,r=t.className,i=t.style,a=t.showOpenInCodeSandbox,o=Sn(t,["clientId","loading","className","style","showOpenInCodeSandbox"]),c=Nn(),u=fn().sandpack,f=u.runSandpack,h=u.environment,m=w.useState(!1),g=m[0],y=m[1],x=ree(e,n),S=aM({clientId:e}),k=sM({clientId:e}).logs;if(w.useEffect(function(){var C;return S?.includes("Running")&&(C=setTimeout(function(){y(!0)},3e3)),function(){C&&clearTimeout(C)}},[S]),x==="HIDDEN")return null;if(x==="TIMEOUT")return v.jsx("div",ue({className:c("overlay",[c("error"),fd,W5,Rb,r])},o,{children:v.jsxs("div",{className:c("error-message",[Ps]),children:[v.jsx("p",{className:c("error-title",[Ee({fontWeight:"bold"})]),children:"Couldn't connect to server"}),v.jsx("div",{className:c("error-message",[Ps]),children:v.jsxs("p",{children:["This means sandpack cannot connect to the runtime or your network is having some issues. Please check the network tab in your browser and try again. If the problem persists, report it via"," ",v.jsx("a",{href:"mailto:hello@codesandbox.io?subject=Sandpack Timeout Error",children:"email"})," ","or submit an issue on"," ",v.jsx("a",{href:"https://github.com/codesandbox/sandpack/issues",rel:"noreferrer noopener",target:"_blank",children:"GitHub."})]})}),v.jsxs("p",{className:c("error-message",[Ps({errorCode:!0})]),children:["ENV: ",h,v.jsx("br",{}),"ERROR: TIME_OUT"]}),v.jsx("div",{children:v.jsxs("button",{className:c("button",[c("icon-standalone"),cr,qa,Fo]),onClick:f,title:"Restart script",type:"button",children:[v.jsx(mg,{})," ",v.jsx("span",{children:"Try again"})]})})]})}));var T=x==="LOADING"||x==="PRE_FADING";return v.jsxs(v.Fragment,{children:[v.jsxs("div",ue({className:c("overlay",[c("loading"),fd,Cee,r]),style:ue(ue({},i),{opacity:T?1:0,transition:"opacity ".concat(rM,"ms ease-out")})},o,{children:[g&&v.jsx("div",{className:Eee.toString(),children:v.jsx(oM,{data:k})}),v.jsx(kee,{showOpenInCodeSandbox:a})]})),S&&v.jsx("div",{className:Qee.toString(),children:v.jsx("p",{children:S})})]})},Eee=Ee({position:"absolute",left:0,right:0,bottom:"$space$8",overflow:"auto",opacity:.5,overflowX:"hidden"}),Qee=Ee({position:"absolute",left:"$space$5",bottom:"$space$4",zIndex:"$top",color:"$colors$clickable",animation:"".concat(C1," 150ms ease"),fontFamily:"$font$mono",fontSize:".8em",width:"75%",p:{whiteSpace:"nowrap",margin:0,textOverflow:"ellipsis",overflow:"hidden"}}),Aee=function(t){var e=t.clientId,n=aM({timeout:3e3,clientId:e});return n?v.jsx("div",{className:Ree.toString(),children:v.jsx("p",{children:n})}):null},Ree=Ee({position:"absolute",left:"$space$5",bottom:"$space$4",zIndex:"$top",color:"$colors$clickable",animation:"".concat(C1," 150ms ease"),fontFamily:"$font$mono",fontSize:".8em",width:"75%",p:{whiteSpace:"nowrap",margin:0,textOverflow:"ellipsis",overflow:"hidden"}});Ee({borderRadius:"0",width:"100%",padding:0,marginBottom:"$space$2",span:{textOverflow:"ellipsis",whiteSpace:"nowrap",overflow:"hidden"},svg:{marginRight:"$space$1"}});Ee({padding:"$space$3",overflow:"auto",height:"100%"});var _ee=function(t){var e=t.match(/(https?:\/\/.*?)\//);return e&&e[1]?[e[1],t.replace(e[1],"")]:[t,"/"]},$ee=Ee({display:"flex",alignItems:"center",height:"$layout$headerHeight",borderBottom:"1px solid $colors$surface2",padding:"$space$3 $space$2",background:"$colors$surface1"}),Pee=Ee({backgroundColor:"$colors$surface2",color:"$colors$clickable",padding:"$space$1 $space$3",borderRadius:"99999px",border:"1px solid $colors$surface2",height:"24px",lineHeight:"24px",fontSize:"inherit",outline:"none",flex:1,marginLeft:"$space$4",width:"0",transition:"background $transitions$default","&:hover":{backgroundColor:"$colors$surface3"},"&:focus":{backgroundColor:"$surface1",border:"1px solid $colors$accent",color:"$colors$base"}}),jee=function(t){var e,n=t.clientId,r=t.onURLChange,i=t.className,a=t.startRoute,o=Sn(t,["clientId","onURLChange","className","startRoute"]),c=w.useState(""),u=c[0],f=c[1],h=fn(),m=h.sandpack,g=h.dispatch,y=h.listen,x=w.useState((e=a??m.startRoute)!==null&&e!==void 0?e:"/"),S=x[0],k=x[1],T=w.useState(!1),C=T[0],E=T[1],R=w.useState(!1),$=R[0],P=R[1],_=Nn();w.useEffect(function(){var ee=y(function(pe){if(pe.type==="urlchange"){var D=pe.url,G=pe.back,B=pe.forward,ye=_ee(D),X=ye[0],A=ye[1];f(X),k(A),E(G),P(B)}},n);return function(){return ee()}},[]);var M=function(ee){var pe=ee.target.value.startsWith("/")?ee.target.value:"/".concat(ee.target.value);k(pe)},V=function(ee){ee.code==="Enter"&&(ee.preventDefault(),ee.stopPropagation(),typeof r=="function"&&r(u+ee.currentTarget.value))},F=function(){g({type:"refresh"})},W=function(){g({type:"urlback"})},I=function(){g({type:"urlforward"})},ne=_("button",[_("icon"),cr,NJ,Ee({minWidth:"$space$6",justifyContent:"center"})]);return v.jsxs("div",ue({className:_("navigator",[$ee,i])},o,{children:[v.jsx("button",{"aria-label":"Go back one page",className:ne,disabled:!C,onClick:W,type:"button",children:v.jsx(VK,{})}),v.jsx("button",{"aria-label":"Go forward one page",className:ne,disabled:!$,onClick:I,type:"button",children:v.jsx(XK,{})}),v.jsx("button",{"aria-label":"Refresh page",className:ne,onClick:F,type:"button",children:v.jsx(I5,{})}),v.jsx("input",{"aria-label":"Current Sandpack URL",className:_("input",[Pee]),name:"Current Sandpack URL",onChange:M,onKeyDown:V,type:"text",value:S})]}))},Gy,Mee=Ee((Gy={flex:1,display:"flex",flexDirection:"column",background:"white",overflow:"auto",position:"relative"},Gy[".".concat(jt,"-bridge-frame")]={border:0,position:"absolute",left:"$space$2",bottom:"$space$2",zIndex:"$top",height:12,width:"30%",mixBlendMode:"multiply",pointerEvents:"none"},Gy)),Nee=Ee({border:"0",outline:"0",width:"100%",height:"100%",minHeight:"160px",maxHeight:"2000px",flex:1}),Dee=Ee({display:"flex",position:"absolute",bottom:"$space$2",right:"$space$2",zIndex:"$overlay",gap:"$space$2"});w.forwardRef(function(t,e){var n=t.showNavigator,r=n===void 0?!1:n,i=t.showRefreshButton,a=i===void 0?!0:i,o=t.showOpenInCodeSandbox,c=o===void 0?!0:o,u=t.showSandpackErrorOverlay,f=u===void 0?!0:u;t.showOpenNewtab;var h=t.showRestartButton,m=h===void 0?!0:h,g=t.actionsChildren,y=g===void 0?v.jsx(v.Fragment,{}):g,x=t.children,S=t.className,k=t.startRoute,T=k===void 0?"/":k,C=Sn(t,["showNavigator","showRefreshButton","showOpenInCodeSandbox","showSandpackErrorOverlay","showOpenNewtab","showRestartButton","actionsChildren","children","className","startRoute"]),E=iM({startRoute:T}),R=E.sandpack,$=E.listen,P=E.iframe,_=E.getClient,M=E.clientId,V=E.dispatch,F=w.useState(null),W=F[0],I=F[1],ne=R.status,ee=iee(M).refresh,pe=E1(M).restart,D=Nn();w.useEffect(function(){var B=$(function(ye){ye.type==="resize"&&I(ye.height)});return B},[]),w.useImperativeHandle(e,function(){return{clientId:M,getClient:_}},[_,M]);var G=function(B){P.current&&(P.current.src=B)};return v.jsxs(Og,ue({className:D("preview",[S])},C,{children:[r&&v.jsx(jee,{clientId:M,onURLChange:G,startRoute:T}),v.jsxs("div",{className:D("preview-container",[Mee]),children:[v.jsx("iframe",{ref:P,className:D("preview-iframe",[Nee]),style:{height:W||void 0},title:"Sandpack Preview"}),v.jsxs("div",{className:D("preview-actions",[Dee]),children:[y,m&&R.environment==="node"&&v.jsx(Dd,{onClick:pe,children:v.jsx(mg,{})}),!r&&a&&ne==="running"&&v.jsx(Dd,{onClick:ee,children:v.jsx(I5,{})}),R.teamId&&v.jsx("button",{className:D("button",[D("icon-standalone"),cr,qa,Fo]),onClick:function(){return V({type:"sign-out"})},title:"Sign out",type:"button",children:v.jsx(LK,{})}),c&&v.jsx(lM,{})]}),v.jsx(Tee,{clientId:M,showOpenInCodeSandbox:c}),f&&v.jsx(lee,{}),x]})]}))});var Hy;Ee((Hy={display:"flex",flexDirection:"column",width:"100%",position:"relative",overflow:"auto",minHeight:"160px",flex:1},Hy[".".concat(jt,"-stack")]={height:"100%"},Hy));Ee({justifyContent:"space-between",borderBottom:"1px solid $colors$surface2",padding:"0 $space$2",fontFamily:"$font$mono",height:"$layout$headerHeight",minHeight:"$layout$headerHeight",overflowX:"auto",whiteSpace:"nowrap"});Ee({display:"flex",flexDirection:"row",alignItems:"center",gap:"$space$2"});var vg=Ee({variants:{status:{pass:{color:"var(--test-pass)"},fail:{color:"var(--test-fail)"},skip:{color:"var(--test-skip)"},title:{color:"var(--test-title)"}}}});vg({status:"pass"});vg({status:"fail"});vg({status:"skip"});vg({status:"title"});var Q1=Ee({variants:{status:{pass:{background:"var(--test-pass)",color:"$colors$surface1"},fail:{background:"var(--test-fail)",color:"$colors$surface1"},run:{background:"var(--test-run)",color:"$colors$surface1"}}}});Q1({status:"run"});Q1({status:"pass"});Q1({status:"fail"});Ee({marginLeft:"$space$4"});Ee({marginBottom:"$space$2",color:"$colors$clickable"});Ee({marginBottom:"$space$2",color:"$colors$hover"});Ee({marginLeft:"$space$2"});Ee({marginRight:"$space$2"});Ee({color:"$colors$hover",marginBottom:"$space$2"});Ee({marginLeft:"$space$4"});Ee({color:"$colors$hover",fontSize:"$font$size",padding:"$space$2",whiteSpace:"pre-wrap"});Ee({display:"flex",flexDirection:"row",alignItems:"center",marginBottom:"$space$2"});Ee({marginBottom:"$space$2"});Ee({fontWeight:"bold"});Ee({borderRadius:"calc($border$radius / 2)"});Ee({padding:"$space$1 $space$2",fontFamily:"$font$mono",textTransform:"uppercase",marginRight:"$space$2"});Ee({fontFamily:"$font$mono",cursor:"pointer",display:"inline-block"});Ee({color:"$colors$clickable",textDecorationStyle:"dotted",textDecorationLine:"underline"});Ee({color:"$colors$hover",fontWeight:"bold",textDecorationStyle:"dotted",textDecorationLine:"underline"});Ee({marginBottom:"$space$2"});Ee({fontWeight:"bold",color:"$colors$hover",whiteSpace:"pre-wrap"});Ee({fontWeight:"bold",color:"$colors$clickable"});Ee({display:"flex",position:"absolute",bottom:"$space$2",right:"$space$2",zIndex:"$overlay","> *":{marginLeft:"$space$2"}});Ee({padding:"$space$4",height:"100%",overflow:"auto",display:"flex",flexDirection:"column",position:"relative",fontFamily:"$font$mono"});Ee({fontWeight:"bold",color:"$colors$base"});var zee=["SyntaxError: ","Error in sandbox:"],Lee={id:"random",method:"clear",data:["Console was cleared"]},_Q="@t",$Q="#@t",PQ="@r",jQ=1e4,cM=2,jb=400,Zee=jb*2,Ky=(function(){if(typeof globalThis<"u")return globalThis;if(typeof window<"u")return window;if(typeof global<"u")return global;if(typeof self<"u")return self;throw Error("Unable to locate global object")})(),Vee=typeof ArrayBuffer=="function",Xee=typeof Map=="function",Bee=typeof Set=="function",hd;(function(t){t[t.infinity=0]="infinity",t[t.minusInfinity=1]="minusInfinity",t[t.minusZero=2]="minusZero"})(hd||(hd={}));var MQ={Arithmetic:function(t){return t===hd.infinity?1/0:t===hd.minusInfinity?-1/0:t===hd.minusZero?-0:t},HTMLElement:function(t){var e=document.implementation.createHTMLDocument("sandbox");try{var n=e.createElement(t.tagName);n.innerHTML=t.innerHTML;for(var r=0,i=Object.keys(t.attributes);r<i.length;r++){var a=i[r];try{n.setAttribute(a,t.attributes[a])}catch{}}return n}catch{return t}},Function:function(t){var e=function(){};return Object.defineProperty(e,"toString",{value:function(){return"function ".concat(t.name,"() {").concat(t.body,"}")}}),e},"[[NaN]]":function(){return NaN},"[[undefined]]":function(){},"[[Date]]":function(t){var e=new Date;return e.setTime(t),e},"[[RegExp]]":function(t){return new RegExp(t.src,t.flags)},"[[Error]]":function(t){var e=Ky[t.name]||Error,n=new e(t.message);return n.stack=t.stack,n},"[[ArrayBuffer]]":function(t){if(Vee){var e=new ArrayBuffer(t.length),n=new Int8Array(e);return n.set(t),e}return t},"[[TypedArray]]":function(t){return typeof Ky[t.ctorName]=="function"?new Ky[t.ctorName](t.arr):t.arr},"[[Map]]":function(t){if(Xee){for(var e=new Map,n=0;n<t.length;n+=2)e.set(t[n],t[n+1]);return e}for(var r=[],i=0;i<t.length;i+=2)r.push([t[n],t[n+1]]);return r},"[[Set]]":function(t){if(Bee){for(var e=new Set,n=0;n<t.length;n++)e.add(t[n]);return e}return t}},Mb=function(t){var e;if(typeof t=="string"||typeof t=="number"||t===null)return t;if(Array.isArray(t))return t.map(Mb);if(typeof t=="object"&&_Q in t){var n=t[_Q],r=MQ[n];return r(t.data)}else if(typeof t=="object"&&$Q in t){var n=t[$Q],r=MQ[n];return r(t.data)}else if(typeof t=="object"&&((e=t.constructor)===null||e===void 0?void 0:e.name)==="NodeList"){var i={};return Object.entries(t).forEach(function(a){var o=a[0],c=a[1];i[o]=Mb(c)}),i}return t},Iee=function(t,e,n){var r=t.reduce(function(i,a,o){return"".concat(i).concat(o?", ":"").concat(zd(a,e,n))},"");return"[".concat(r,"]")},qee=function(t,e,n){var r=t.constructor.name!=="Object"?"".concat(t.constructor.name," "):"";if(n>cM)return r;var i=Object.entries(t),a=Object.entries(t).reduce(function(o,c,u){var f=c[0],h=c[1],m=u===0?"":", ",g=i.length>10?`
|
|
791
|
-
`:"",y=zd(h,e,n);return u===jb?o+g+"...":u>jb?o:o+"".concat(m).concat(g).concat(f,": ")+y},"");return"".concat(r,"{ ").concat(a).concat(i.length>10?`
|
|
792
|
-
`:" ","}")},zd=function(t,e,n){var r;n===void 0&&(n=0);try{var i=Mb(t);if(Array.isArray(i))return Iee(i,e,n+1);switch(typeof i){case"string":return'"'.concat(i,'"').slice(0,jQ);case"number":case"function":case"symbol":return i.toString();case"boolean":return String(i);case"undefined":return"undefined";default:if(i instanceof RegExp||i instanceof Error||i instanceof Date)return i.toString();if(i===null)return String(null);if(i instanceof HTMLElement)return i.outerHTML.slice(0,jQ);if(Object.entries(i).length===0)return"{}";if(PQ in i){if(n>cM)return"Unable to print information";var a=e[i[PQ]];return zd(a,e,n+1)}if(((r=i.constructor)===null||r===void 0?void 0:r.name)==="NodeList"){var o=i.length,c=new Array(o).fill(null).map(function(u,f){return zd(i[f],e)});return"NodeList(".concat(i.length,")[").concat(c,"]")}return qee(i,e,n+1)}}catch{return"Unable to print information"}},Uee=function(t){switch(t){case"warn":return"warning";case"clear":return"clear";case"error":return"error";default:return"info"}},ip,Yee=function(t){var e=t.data,n=Nn();return v.jsx(v.Fragment,{children:e.map(function(r,i,a){var o=r.data,c=r.id,u=r.method;return o&&Array.isArray(o)?v.jsx(w.Fragment,{children:o.map(function(f,h){var m=a.slice(i,a.length);return v.jsx("div",{className:n("console-item",[Fee({variant:Uee(u)})]),children:v.jsx(T1,{code:u==="clear"?f:zd(f,m),fileType:"js",initMode:"user-visible",showReadOnly:!1,readOnly:!0,wrapContent:!0})},"".concat(c,"-").concat(h))})},c):null})})},Fee=Ee((ip={width:"100%",padding:"$space$3 $space$2",fontSize:".8em",position:"relative","&:not(:first-child):after":{content:"",position:"absolute",top:0,left:0,right:0,height:1,background:"$colors$surface3"},".sp-cm":{padding:0},".cm-editor":{background:"none"},".cm-content":{padding:0}},ip[".".concat(jt,"-pre-placeholder")]={margin:"0 !important",fontSize:"1em"},ip.variants={variant:{error:{color:"$colors$error",background:"$colors$errorSurface","&:not(:first-child):after":{background:"$colors$error",opacity:.07}},warning:{color:"$colors$warning",background:"$colors$warningSurface","&:not(:first-child):after":{background:"$colors$warning",opacity:.07}},clear:{fontStyle:"italic"},info:{}}},ip)),Wee=Ee({justifyContent:"space-between",borderBottom:"1px solid $colors$surface2",padding:"0 $space$2",fontFamily:"$font$mono",height:"$layout$headerHeight",minHeight:"$layout$headerHeight",overflowX:"auto",whiteSpace:"nowrap"}),NQ=Ee({display:"flex",flexDirection:"row",alignItems:"center",gap:"$space$2"}),Gee=function(t){var e=t.currentTab,n=t.setCurrentTab,r=t.node,i=Nn(),a=i("console-header-button",[cr,Fo,Ee({padding:"$space$1 $space$3"})]);return v.jsxs("div",{className:i("console-header",[Wee,NQ]),children:[v.jsxs("p",{className:i("console-header-title",[Ee({lineHeight:1,margin:0,color:"$colors$base",fontSize:"$font$size",display:"flex",alignItems:"center",gap:"$space$2"})]),children:[v.jsx(UK,{}),v.jsx("span",{children:"Terminal"})]}),r&&v.jsxs("div",{className:i("console-header-actions",[NQ]),children:[v.jsx("button",{className:a,"data-active":e==="server",onClick:function(){return n("server")},type:"button",children:"Server"}),v.jsx("button",{className:a,"data-active":e==="client",onClick:function(){return n("client")},type:"button",children:"Client"})]})]})},Hee=function(t){var e=t.clientId,n=t.maxMessageCount,r=n===void 0?Zee:n,i=t.showSyntaxError,a=i===void 0?!1:i,o=t.resetOnPreviewRestart,c=o===void 0?!1:o,u=w.useState([]),f=u[0],h=u[1],m=fn().listen;return w.useEffect(function(){var g=m(function(y){if(c&&y.type==="start")h([]);else if(y.type==="console"&&y.codesandbox){var x=Array.isArray(y.log)?y.log:[y.log];if(x.find(function(k){var T=k.method;return T==="clear"}))return h([Lee]);var S=a?x:x.filter(function(k){var T,C,E,R=(E=(C=(T=k?.data)===null||T===void 0?void 0:T.filter)===null||C===void 0?void 0:C.call(T,function($){if(typeof $!="string")return!0;var P=zee.filter(function(_){return $.startsWith(_)});return P.length===0}))!==null&&E!==void 0?E:[];return R.length>0});if(!S)return;h(function(k){for(var T=Fn(Fn([],k,!0),S,!0).filter(function(C,E,R){return E===R.findIndex(function($){return $.id===C.id})});T.length>r;)T.shift();return T})}},e);return g},[a,r,e,c]),{logs:f,reset:function(){return h([])}}};w.forwardRef(function(t,e){var n,r=t.showHeader,i=r===void 0?!0:r,a=t.showSyntaxError,o=a===void 0?!1:a,c=t.maxMessageCount,u=t.onLogsChange,f=t.className;t.showSetupProgress;var h=t.showResetConsoleButton,m=h===void 0?!0:h,g=t.showRestartButton,y=g===void 0?!0:g,x=t.resetOnPreviewRestart,S=x===void 0?!1:x,k=t.actionsChildren,T=k===void 0?v.jsx(v.Fragment,{}):k,C=t.standalone,E=C===void 0?!1:C,R=Sn(t,["showHeader","showSyntaxError","maxMessageCount","onLogsChange","className","showSetupProgress","showResetConsoleButton","showRestartButton","resetOnPreviewRestart","actionsChildren","standalone"]),$=fn().sandpack.environment,P=iM(),_=P.iframe,M=P.clientId,V=E1().restart,F=w.useState($==="node"?"server":"client"),W=F[0],I=F[1],ne=E?M:void 0,ee=Hee({maxMessageCount:c,showSyntaxError:o,resetOnPreviewRestart:S,clientId:ne}),pe=ee.logs,D=ee.reset,G=sM({maxMessageCount:c,resetOnPreviewRestart:S,clientId:ne}),B=G.logs,ye=G.reset,X=w.useRef(null);w.useEffect(function(){u?.(pe),X.current&&(X.current.scrollTop=X.current.scrollHeight)},[u,pe,B,W]);var A=W==="server",N=$==="node";w.useImperativeHandle(e,function(){return{reset:function(){D(),ye()}}});var L=Nn();return v.jsxs(Og,ue({className:L("console",[Ee((n={height:"100%",background:"$surface1",iframe:{display:"none"}},n[".".concat(jt,"-bridge-frame")]={display:"block",border:0,position:"absolute",left:"$space$2",bottom:"$space$2",zIndex:"$top",height:12,width:"30%",mixBlendMode:"multiply",pointerEvents:"none"},n)),f])},R,{children:[i&&N&&v.jsx(Gee,{currentTab:W,node:N,setCurrentTab:I}),v.jsx("div",{ref:X,className:L("console-list",[Ee({overflow:"auto",scrollBehavior:"smooth"})]),children:A?v.jsx(oM,{data:B}):v.jsx(Yee,{data:pe})}),v.jsxs("div",{className:L("console-actions",[Ee({position:"absolute",bottom:"$space$2",right:"$space$2",display:"flex",gap:"$space$2"})]),children:[T,y&&A&&v.jsx(Dd,{onClick:function(){V(),D(),ye()},children:v.jsx(mg,{})}),m&&v.jsx(Dd,{onClick:function(){W==="client"?D():ye()},children:v.jsx(BK,{})})]}),E&&v.jsxs(v.Fragment,{children:[v.jsx(Aee,{clientId:ne}),v.jsx("iframe",{ref:_})]})]}))});Ee({position:"absolute",zIndex:"$top",variants:{direction:{vertical:{right:0,left:0,height:10,cursor:"ns-resize"},horizontal:{top:0,bottom:0,width:10,cursor:"ew-resize"}}},"@media screen and (max-width: 768px)":{display:"none"}});Ee({position:"relative",strong:{background:"$colors$clickable",color:"$colors$surface1",minWidth:12,height:12,padding:"0 2px",borderRadius:12,fontSize:8,lineHeight:"12px",position:"absolute",top:0,right:0,fontWeight:"normal"}});Ee({width:"100%",overflow:"hidden"});Ee({flexDirection:"row-reverse","@media screen and (max-width: 768px)":{flexFlow:"wrap-reverse !important",flexDirection:"initial"}});function Kee({onChange:t,initialValue:e}){const{code:n}=gg(),r=w.useRef(null),i=w.useRef(e);return w.useEffect(()=>{e.length>0&&(i.current=e)},[e]),w.useEffect(()=>{const a=i.current.length>0,o=n.length===0&&a,c=n===r.current;!o&&!c&&(r.current=n,t(n))},[n,t]),v.jsx(nM,{showInlineErrors:!0,style:{height:"100%"}})}function uM({value:t,onChange:e}){const{theme:n}=PA(),r=w.useRef(!1);t.length>0&&!r.current&&(r.current=!0);const i=r.current?"initialized":"empty";return v.jsx("div",{className:"h-full w-full overflow-hidden",children:v.jsx(F5,{theme:n==="system"?"auto":n,files:{"icon.svg":{code:t}},options:{activeFile:"icon.svg"},className:"!h-full !w-full",children:v.jsx(Kee,{onChange:e,initialValue:t})},i)})}var df=t=>t.type==="checkbox",$o=t=>t instanceof Date,wr=t=>t==null;const dM=t=>typeof t=="object";var wn=t=>!wr(t)&&!Array.isArray(t)&&dM(t)&&!$o(t),fM=t=>wn(t)&&t.target?df(t.target)?t.target.checked:t.target.value:t,Jee=t=>t.substring(0,t.search(/\.\d+(\.|$)/))||t,hM=(t,e)=>t.has(Jee(e)),ete=t=>{const e=t.constructor&&t.constructor.prototype;return wn(e)&&e.hasOwnProperty("isPrototypeOf")},A1=typeof window<"u"&&typeof window.HTMLElement<"u"&&typeof document<"u";function En(t){if(t instanceof Date)return new Date(t);const e=typeof FileList<"u"&&t instanceof FileList;if(A1&&(t instanceof Blob||e))return t;const n=Array.isArray(t);if(!n&&!(wn(t)&&ete(t)))return t;const r=n?[]:Object.create(Object.getPrototypeOf(t));for(const i in t)Object.prototype.hasOwnProperty.call(t,i)&&(r[i]=En(t[i]));return r}var yg=t=>/^\w*$/.test(t),on=t=>t===void 0,R1=t=>Array.isArray(t)?t.filter(Boolean):[],_1=t=>R1(t.replace(/["|']|\]/g,"").split(/\.|\[/)),Ae=(t,e,n)=>{if(!e||!wn(t))return n;const r=(yg(e)?[e]:_1(e)).reduce((i,a)=>wr(i)?i:i[a],t);return on(r)||r===t?on(t[e])?n:t[e]:r},Zr=t=>typeof t=="boolean",or=t=>typeof t=="function",Pt=(t,e,n)=>{let r=-1;const i=yg(e)?[e]:_1(e),a=i.length,o=a-1;for(;++r<a;){const c=i[r];let u=n;if(r!==o){const f=t[c];u=wn(f)||Array.isArray(f)?f:isNaN(+i[r+1])?{}:[]}if(c==="__proto__"||c==="constructor"||c==="prototype")return;t[c]=u,t=t[c]}};const fm={BLUR:"blur",FOCUS_OUT:"focusout",CHANGE:"change"},wi={onBlur:"onBlur",onChange:"onChange",onSubmit:"onSubmit",onTouched:"onTouched",all:"all"},Da={max:"max",min:"min",maxLength:"maxLength",minLength:"minLength",pattern:"pattern",required:"required",validate:"validate"},pM=le.createContext(null);pM.displayName="HookFormContext";const $1=()=>le.useContext(pM);var mM=(t,e,n,r=!0)=>{const i={defaultValues:e._defaultValues};for(const a in t)Object.defineProperty(i,a,{get:()=>{const o=a;return e._proxyFormState[o]!==wi.all&&(e._proxyFormState[o]=!r||wi.all),n&&(n[o]=!0),t[o]}});return i};const P1=typeof window<"u"?le.useLayoutEffect:le.useEffect;function tte(t){const e=$1(),{control:n=e.control,disabled:r,name:i,exact:a}=t||{},[o,c]=le.useState(n._formState),u=le.useRef({isDirty:!1,isLoading:!1,dirtyFields:!1,touchedFields:!1,validatingFields:!1,isValidating:!1,isValid:!1,errors:!1});return P1(()=>n._subscribe({name:i,formState:u.current,exact:a,callback:f=>{!r&&c({...n._formState,...f})}}),[i,r,a]),le.useEffect(()=>{u.current.isValid&&n._setValid(!0)},[n]),le.useMemo(()=>mM(o,n,u.current,!1),[o,n])}var Xr=t=>typeof t=="string",Nb=(t,e,n,r,i)=>Xr(t)?(r&&e.watch.add(t),Ae(n,t,i)):Array.isArray(t)?t.map(a=>(r&&e.watch.add(a),Ae(n,a))):(r&&(e.watchAll=!0),n),Db=t=>wr(t)||!dM(t);function ki(t,e,n=new WeakSet){if(Db(t)||Db(e))return Object.is(t,e);if($o(t)&&$o(e))return t.getTime()===e.getTime();const r=Object.keys(t),i=Object.keys(e);if(r.length!==i.length)return!1;if(n.has(t)||n.has(e))return!0;n.add(t),n.add(e);for(const a of r){const o=t[a];if(!i.includes(a))return!1;if(a!=="ref"){const c=e[a];if($o(o)&&$o(c)||wn(o)&&wn(c)||Array.isArray(o)&&Array.isArray(c)?!ki(o,c,n):!Object.is(o,c))return!1}}return!0}function nte(t){const e=$1(),{control:n=e.control,name:r,defaultValue:i,disabled:a,exact:o,compute:c}=t||{},u=le.useRef(i),f=le.useRef(c),h=le.useRef(void 0),m=le.useRef(n),g=le.useRef(r);f.current=c;const[y,x]=le.useState(()=>{const R=n._getWatch(r,u.current);return f.current?f.current(R):R}),S=le.useCallback(R=>{const $=Nb(r,n._names,R||n._formValues,!1,u.current);return f.current?f.current($):$},[n._formValues,n._names,r]),k=le.useCallback(R=>{if(!a){const $=Nb(r,n._names,R||n._formValues,!1,u.current);if(f.current){const P=f.current($);ki(P,h.current)||(x(P),h.current=P)}else x($)}},[n._formValues,n._names,a,r]);P1(()=>((m.current!==n||!ki(g.current,r))&&(m.current=n,g.current=r,k()),n._subscribe({name:r,formState:{values:!0},exact:o,callback:R=>{k(R.values)}})),[n,o,r,k]),le.useEffect(()=>n._removeUnmounted());const T=m.current!==n,C=g.current,E=le.useMemo(()=>{if(a)return null;const R=!T&&!ki(C,r);return T||R?S():null},[a,T,r,C,S]);return E!==null?E:y}function rte(t){const e=$1(),{name:n,disabled:r,control:i=e.control,shouldUnregister:a,defaultValue:o,exact:c=!0}=t,u=hM(i._names.array,n),f=le.useMemo(()=>Ae(i._formValues,n,Ae(i._defaultValues,n,o)),[i,n,o]),h=nte({control:i,name:n,defaultValue:f,exact:c}),m=tte({control:i,name:n,exact:c}),g=le.useRef(t),y=le.useRef(void 0),x=le.useRef(i.register(n,{...t.rules,value:h,...Zr(t.disabled)?{disabled:t.disabled}:{}}));g.current=t;const S=le.useMemo(()=>Object.defineProperties({},{invalid:{enumerable:!0,get:()=>!!Ae(m.errors,n)},isDirty:{enumerable:!0,get:()=>!!Ae(m.dirtyFields,n)},isTouched:{enumerable:!0,get:()=>!!Ae(m.touchedFields,n)},isValidating:{enumerable:!0,get:()=>!!Ae(m.validatingFields,n)},error:{enumerable:!0,get:()=>Ae(m.errors,n)}}),[m,n]),k=le.useCallback(R=>x.current.onChange({target:{value:fM(R),name:n},type:fm.CHANGE}),[n]),T=le.useCallback(()=>x.current.onBlur({target:{value:Ae(i._formValues,n),name:n},type:fm.BLUR}),[n,i._formValues]),C=le.useCallback(R=>{const $=Ae(i._fields,n);$&&$._f&&R&&($._f.ref={focus:()=>or(R.focus)&&R.focus(),select:()=>or(R.select)&&R.select(),setCustomValidity:P=>or(R.setCustomValidity)&&R.setCustomValidity(P),reportValidity:()=>or(R.reportValidity)&&R.reportValidity()})},[i._fields,n]),E=le.useMemo(()=>({name:n,value:h,...Zr(r)||m.disabled?{disabled:m.disabled||r}:{},onChange:k,onBlur:T,ref:C}),[n,r,m.disabled,k,T,C,h]);return le.useEffect(()=>{const R=i._options.shouldUnregister||a,$=y.current;$&&$!==n&&!u&&i.unregister($),i.register(n,{...g.current.rules,...Zr(g.current.disabled)?{disabled:g.current.disabled}:{}});const P=(_,M)=>{const V=Ae(i._fields,_);V&&V._f&&(V._f.mount=M)};if(P(n,!0),R){const _=En(Ae(i._options.defaultValues,n,g.current.defaultValue));Pt(i._defaultValues,n,_),on(Ae(i._formValues,n))&&Pt(i._formValues,n,_)}return!u&&i.register(n),y.current=n,()=>{(u?R&&!i._state.action:R)?i.unregister(n):P(n,!1)}},[n,i,u,a]),le.useEffect(()=>{i._setDisabledField({disabled:r,name:n})},[r,n,i]),le.useMemo(()=>({field:E,formState:m,fieldState:S}),[E,m,S])}const pd=t=>t.render(rte(t));var j1=(t,e,n,r,i)=>e?{...n[t],types:{...n[t]&&n[t].types?n[t].types:{},[r]:i||!0}}:{},md=t=>Array.isArray(t)?t:[t],DQ=()=>{let t=[];return{get observers(){return t},next:i=>{for(const a of t)a.next&&a.next(i)},subscribe:i=>(t.push(i),{unsubscribe:()=>{t=t.filter(a=>a!==i)}}),unsubscribe:()=>{t=[]}}};function gM(t,e){const n={};for(const r in t)if(t.hasOwnProperty(r)){const i=t[r],a=e[r];if(i&&wn(i)&&a){const o=gM(i,a);wn(o)&&(n[r]=o)}else t[r]&&(n[r]=a)}return n}var ir=t=>wn(t)&&!Object.keys(t).length,M1=t=>t.type==="file",hm=t=>{if(!A1)return!1;const e=t?t.ownerDocument:0;return t instanceof(e&&e.defaultView?e.defaultView.HTMLElement:HTMLElement)},OM=t=>t.type==="select-multiple",N1=t=>t.type==="radio",ite=t=>N1(t)||df(t),Jy=t=>hm(t)&&t.isConnected;function ate(t,e){const n=e.slice(0,-1).length;let r=0;for(;r<n;)t=on(t)?r++:t[e[r++]];return t}function ste(t){for(const e in t)if(t.hasOwnProperty(e)&&!on(t[e]))return!1;return!0}function vn(t,e){const n=Array.isArray(e)?e:yg(e)?[e]:_1(e),r=n.length===1?t:ate(t,n),i=n.length-1,a=n[i];return r&&delete r[a],i!==0&&(wn(r)&&ir(r)||Array.isArray(r)&&ste(r))&&vn(t,n.slice(0,-1)),t}var ote=t=>{for(const e in t)if(or(t[e]))return!0;return!1};function vM(t){return Array.isArray(t)||wn(t)&&!ote(t)}function zb(t,e={}){for(const n in t){const r=t[n];vM(r)?(e[n]=Array.isArray(r)?[]:{},zb(r,e[n])):on(r)||(e[n]=!0)}return e}function Wl(t,e,n){n||(n=zb(e));for(const r in t){const i=t[r];if(vM(i))on(e)||Db(n[r])?n[r]=zb(i,Array.isArray(i)?[]:{}):Wl(i,wr(e)?{}:e[r],n[r]);else{const a=e[r];n[r]=!ki(i,a)}}return n}const zQ={value:!1,isValid:!1},LQ={value:!0,isValid:!0};var yM=t=>{if(Array.isArray(t)){if(t.length>1){const e=t.filter(n=>n&&n.checked&&!n.disabled).map(n=>n.value);return{value:e,isValid:!!e.length}}return t[0].checked&&!t[0].disabled?t[0].attributes&&!on(t[0].attributes.value)?on(t[0].value)||t[0].value===""?LQ:{value:t[0].value,isValid:!0}:LQ:zQ}return zQ},bM=(t,{valueAsNumber:e,valueAsDate:n,setValueAs:r})=>on(t)?t:e?t===""?NaN:t&&+t:n&&Xr(t)?new Date(t):r?r(t):t;const ZQ={isValid:!1,value:null};var xM=t=>Array.isArray(t)?t.reduce((e,n)=>n&&n.checked&&!n.disabled?{isValid:!0,value:n.value}:e,ZQ):ZQ;function VQ(t){const e=t.ref;return M1(e)?e.files:N1(e)?xM(t.refs).value:OM(e)?[...e.selectedOptions].map(({value:n})=>n):df(e)?yM(t.refs).value:bM(on(e.value)?t.ref.value:e.value,t)}var lte=(t,e,n,r)=>{const i={};for(const a of t){const o=Ae(e,a);o&&Pt(i,a,o._f)}return{criteriaMode:n,names:[...t],fields:i,shouldUseNativeValidation:r}},pm=t=>t instanceof RegExp,Ju=t=>on(t)?t:pm(t)?t.source:wn(t)?pm(t.value)?t.value.source:t.value:t,XQ=t=>({isOnSubmit:!t||t===wi.onSubmit,isOnBlur:t===wi.onBlur,isOnChange:t===wi.onChange,isOnAll:t===wi.all,isOnTouch:t===wi.onTouched});const BQ="AsyncFunction";var cte=t=>!!t&&!!t.validate&&!!(or(t.validate)&&t.validate.constructor.name===BQ||wn(t.validate)&&Object.values(t.validate).find(e=>e.constructor.name===BQ)),ute=t=>t.mount&&(t.required||t.min||t.max||t.maxLength||t.minLength||t.pattern||t.validate),IQ=(t,e,n)=>!n&&(e.watchAll||e.watch.has(t)||[...e.watch].some(r=>t.startsWith(r)&&/^\.\w+/.test(t.slice(r.length))));const gd=(t,e,n,r)=>{for(const i of n||Object.keys(t)){const a=Ae(t,i);if(a){const{_f:o,...c}=a;if(o){if(o.refs&&o.refs[0]&&e(o.refs[0],i)&&!r)return!0;if(o.ref&&e(o.ref,o.name)&&!r)return!0;if(gd(c,e))break}else if(wn(c)&&gd(c,e))break}}};function qQ(t,e,n){const r=Ae(t,n);if(r||yg(n))return{error:r,name:n};const i=n.split(".");for(;i.length;){const a=i.join("."),o=Ae(e,a),c=Ae(t,a);if(o&&!Array.isArray(o)&&n!==a)return{name:n};if(c&&c.type)return{name:a,error:c};if(c&&c.root&&c.root.type)return{name:`${a}.root`,error:c.root};i.pop()}return{name:n}}var dte=(t,e,n,r)=>{n(t);const{name:i,...a}=t;return ir(a)||Object.keys(a).length>=Object.keys(e).length||Object.keys(a).find(o=>e[o]===(!r||wi.all))},fte=(t,e,n)=>!t||!e||t===e||md(t).some(r=>r&&(n?r===e:r.startsWith(e)||e.startsWith(r))),hte=(t,e,n,r,i)=>i.isOnAll?!1:!n&&i.isOnTouch?!(e||t):(n?r.isOnBlur:i.isOnBlur)?!t:(n?r.isOnChange:i.isOnChange)?t:!0,pte=(t,e)=>!R1(Ae(t,e)).length&&vn(t,e),mte=(t,e,n)=>{const r=md(Ae(t,n));return Pt(r,"root",e[n]),Pt(t,n,r),t};function UQ(t,e,n="validate"){if(Xr(t)||Array.isArray(t)&&t.every(Xr)||Zr(t)&&!t)return{type:n,message:Xr(t)?t:"",ref:e}}var Yl=t=>wn(t)&&!pm(t)?t:{value:t,message:""},YQ=async(t,e,n,r,i,a)=>{const{ref:o,refs:c,required:u,maxLength:f,minLength:h,min:m,max:g,pattern:y,validate:x,name:S,valueAsNumber:k,mount:T}=t._f,C=Ae(n,S);if(!T||e.has(S))return{};const E=c?c[0]:o,R=I=>{i&&E.reportValidity&&(E.setCustomValidity(Zr(I)?"":I||""),E.reportValidity())},$={},P=N1(o),_=df(o),M=P||_,V=(k||M1(o))&&on(o.value)&&on(C)||hm(o)&&o.value===""||C===""||Array.isArray(C)&&!C.length,F=j1.bind(null,S,r,$),W=(I,ne,ee,pe=Da.maxLength,D=Da.minLength)=>{const G=I?ne:ee;$[S]={type:I?pe:D,message:G,ref:o,...F(I?pe:D,G)}};if(a?!Array.isArray(C)||!C.length:u&&(!M&&(V||wr(C))||Zr(C)&&!C||_&&!yM(c).isValid||P&&!xM(c).isValid)){const{value:I,message:ne}=Xr(u)?{value:!!u,message:u}:Yl(u);if(I&&($[S]={type:Da.required,message:ne,ref:E,...F(Da.required,ne)},!r))return R(ne),$}if(!V&&(!wr(m)||!wr(g))){let I,ne;const ee=Yl(g),pe=Yl(m);if(!wr(C)&&!isNaN(C)){const D=o.valueAsNumber||C&&+C;wr(ee.value)||(I=D>ee.value),wr(pe.value)||(ne=D<pe.value)}else{const D=o.valueAsDate||new Date(C),G=X=>new Date(new Date().toDateString()+" "+X),B=o.type=="time",ye=o.type=="week";Xr(ee.value)&&C&&(I=B?G(C)>G(ee.value):ye?C>ee.value:D>new Date(ee.value)),Xr(pe.value)&&C&&(ne=B?G(C)<G(pe.value):ye?C<pe.value:D<new Date(pe.value))}if((I||ne)&&(W(!!I,ee.message,pe.message,Da.max,Da.min),!r))return R($[S].message),$}if((f||h)&&!V&&(Xr(C)||a&&Array.isArray(C))){const I=Yl(f),ne=Yl(h),ee=!wr(I.value)&&C.length>+I.value,pe=!wr(ne.value)&&C.length<+ne.value;if((ee||pe)&&(W(ee,I.message,ne.message),!r))return R($[S].message),$}if(y&&!V&&Xr(C)){const{value:I,message:ne}=Yl(y);if(pm(I)&&!C.match(I)&&($[S]={type:Da.pattern,message:ne,ref:o,...F(Da.pattern,ne)},!r))return R(ne),$}if(x){if(or(x)){const I=await x(C,n),ne=UQ(I,E);if(ne&&($[S]={...ne,...F(Da.validate,ne.message)},!r))return R(ne.message),$}else if(wn(x)){let I={};for(const ne in x){if(!ir(I)&&!r)break;const ee=UQ(await x[ne](C,n),E,ne);ee&&(I={...ee,...F(ne,ee.message)},R(ee.message),r&&($[S]=I))}if(!ir(I)&&($[S]={ref:E,...I},!r))return $}}return R(!0),$};const gte={mode:wi.onSubmit,reValidateMode:wi.onChange,shouldFocusError:!0};function Ote(t={}){let e={...gte,...t},n={submitCount:0,isDirty:!1,isReady:!1,isLoading:or(e.defaultValues),isValidating:!1,isSubmitted:!1,isSubmitting:!1,isSubmitSuccessful:!1,isValid:!1,touchedFields:{},dirtyFields:{},validatingFields:{},errors:e.errors||{},disabled:e.disabled||!1},r={},i=wn(e.defaultValues)||wn(e.values)?En(e.defaultValues||e.values)||{}:{},a=e.shouldUnregister?{}:En(i),o={action:!1,mount:!1,watch:!1,keepIsValid:!1},c={mount:new Set,disabled:new Set,unMount:new Set,array:new Set,watch:new Set},u,f=0;const h={isDirty:!1,dirtyFields:!1,validatingFields:!1,touchedFields:!1,isValidating:!1,isValid:!1,errors:!1},m={...h};let g={...m};const y={array:DQ(),state:DQ()},x=e.criteriaMode===wi.all,S=z=>Y=>{clearTimeout(f),f=setTimeout(z,Y)},k=async z=>{if(!o.keepIsValid&&!e.disabled&&(m.isValid||g.isValid||z)){let Y;e.resolver?(Y=ir((await M()).errors),T()):Y=await F(r,!0),Y!==n.isValid&&y.state.next({isValid:Y})}},T=(z,Y)=>{!e.disabled&&(m.isValidating||m.validatingFields||g.isValidating||g.validatingFields)&&((z||Array.from(c.mount)).forEach(oe=>{oe&&(Y?Pt(n.validatingFields,oe,Y):vn(n.validatingFields,oe))}),y.state.next({validatingFields:n.validatingFields,isValidating:!ir(n.validatingFields)}))},C=(z,Y=[],oe,te,fe=!0,Oe=!0)=>{if(te&&oe&&!e.disabled){if(o.action=!0,Oe&&Array.isArray(Ae(r,z))){const Te=oe(Ae(r,z),te.argA,te.argB);fe&&Pt(r,z,Te)}if(Oe&&Array.isArray(Ae(n.errors,z))){const Te=oe(Ae(n.errors,z),te.argA,te.argB);fe&&Pt(n.errors,z,Te),pte(n.errors,z)}if((m.touchedFields||g.touchedFields)&&Oe&&Array.isArray(Ae(n.touchedFields,z))){const Te=oe(Ae(n.touchedFields,z),te.argA,te.argB);fe&&Pt(n.touchedFields,z,Te)}(m.dirtyFields||g.dirtyFields)&&(n.dirtyFields=Wl(i,a)),y.state.next({name:z,isDirty:I(z,Y),dirtyFields:n.dirtyFields,errors:n.errors,isValid:n.isValid})}else Pt(a,z,Y)},E=(z,Y)=>{Pt(n.errors,z,Y),y.state.next({errors:n.errors})},R=z=>{n.errors=z,y.state.next({errors:n.errors,isValid:!1})},$=(z,Y,oe,te)=>{const fe=Ae(r,z);if(fe){const Oe=Ae(a,z,on(oe)?Ae(i,z):oe);on(Oe)||te&&te.defaultChecked||Y?Pt(a,z,Y?Oe:VQ(fe._f)):pe(z,Oe),o.mount&&!o.action&&k()}},P=(z,Y,oe,te,fe)=>{let Oe=!1,Te=!1;const Ye={name:z};if(!e.disabled){if(!oe||te){(m.isDirty||g.isDirty)&&(Te=n.isDirty,n.isDirty=Ye.isDirty=I(),Oe=Te!==Ye.isDirty);const ot=ki(Ae(i,z),Y);Te=!!Ae(n.dirtyFields,z),ot?vn(n.dirtyFields,z):Pt(n.dirtyFields,z,!0),Ye.dirtyFields=n.dirtyFields,Oe=Oe||(m.dirtyFields||g.dirtyFields)&&Te!==!ot}if(oe){const ot=Ae(n.touchedFields,z);ot||(Pt(n.touchedFields,z,oe),Ye.touchedFields=n.touchedFields,Oe=Oe||(m.touchedFields||g.touchedFields)&&ot!==oe)}Oe&&fe&&y.state.next(Ye)}return Oe?Ye:{}},_=(z,Y,oe,te)=>{const fe=Ae(n.errors,z),Oe=(m.isValid||g.isValid)&&Zr(Y)&&n.isValid!==Y;if(e.delayError&&oe?(u=S(()=>E(z,oe)),u(e.delayError)):(clearTimeout(f),u=null,oe?Pt(n.errors,z,oe):vn(n.errors,z)),(oe?!ki(fe,oe):fe)||!ir(te)||Oe){const Te={...te,...Oe&&Zr(Y)?{isValid:Y}:{},errors:n.errors,name:z};n={...n,...Te},y.state.next(Te)}},M=async z=>(T(z,!0),await e.resolver(a,e.context,lte(z||c.mount,r,e.criteriaMode,e.shouldUseNativeValidation))),V=async z=>{const{errors:Y}=await M(z);if(T(z),z)for(const oe of z){const te=Ae(Y,oe);te?Pt(n.errors,oe,te):vn(n.errors,oe)}else n.errors=Y;return Y},F=async(z,Y,oe={valid:!0})=>{for(const te in z){const fe=z[te];if(fe){const{_f:Oe,...Te}=fe;if(Oe){const Ye=c.array.has(Oe.name),ot=fe._f&&cte(fe._f);ot&&m.validatingFields&&T([Oe.name],!0);const kt=await YQ(fe,c.disabled,a,x,e.shouldUseNativeValidation&&!Y,Ye);if(ot&&m.validatingFields&&T([Oe.name]),kt[Oe.name]&&(oe.valid=!1,Y))break;!Y&&(Ae(kt,Oe.name)?Ye?mte(n.errors,kt,Oe.name):Pt(n.errors,Oe.name,kt[Oe.name]):vn(n.errors,Oe.name))}!ir(Te)&&await F(Te,Y,oe)}}return oe.valid},W=()=>{for(const z of c.unMount){const Y=Ae(r,z);Y&&(Y._f.refs?Y._f.refs.every(oe=>!Jy(oe)):!Jy(Y._f.ref))&&ge(z)}c.unMount=new Set},I=(z,Y)=>!e.disabled&&(z&&Y&&Pt(a,z,Y),!ki(A(),i)),ne=(z,Y,oe)=>Nb(z,c,{...o.mount?a:on(Y)?i:Xr(z)?{[z]:Y}:Y},oe,Y),ee=z=>R1(Ae(o.mount?a:i,z,e.shouldUnregister?Ae(i,z,[]):[])),pe=(z,Y,oe={})=>{const te=Ae(r,z);let fe=Y;if(te){const Oe=te._f;Oe&&(!Oe.disabled&&Pt(a,z,bM(Y,Oe)),fe=hm(Oe.ref)&&wr(Y)?"":Y,OM(Oe.ref)?[...Oe.ref.options].forEach(Te=>Te.selected=fe.includes(Te.value)):Oe.refs?df(Oe.ref)?Oe.refs.forEach(Te=>{(!Te.defaultChecked||!Te.disabled)&&(Array.isArray(fe)?Te.checked=!!fe.find(Ye=>Ye===Te.value):Te.checked=fe===Te.value||!!fe)}):Oe.refs.forEach(Te=>Te.checked=Te.value===fe):M1(Oe.ref)?Oe.ref.value="":(Oe.ref.value=fe,Oe.ref.type||y.state.next({name:z,values:En(a)})))}(oe.shouldDirty||oe.shouldTouch)&&P(z,fe,oe.shouldTouch,oe.shouldDirty,!0),oe.shouldValidate&&X(z)},D=(z,Y,oe)=>{for(const te in Y){if(!Y.hasOwnProperty(te))return;const fe=Y[te],Oe=z+"."+te,Te=Ae(r,Oe);(c.array.has(z)||wn(fe)||Te&&!Te._f)&&!$o(fe)?D(Oe,fe,oe):pe(Oe,fe,oe)}},G=(z,Y,oe={})=>{const te=Ae(r,z),fe=c.array.has(z),Oe=En(Y);Pt(a,z,Oe),fe?(y.array.next({name:z,values:En(a)}),(m.isDirty||m.dirtyFields||g.isDirty||g.dirtyFields)&&oe.shouldDirty&&y.state.next({name:z,dirtyFields:Wl(i,a),isDirty:I(z,Oe)})):te&&!te._f&&!wr(Oe)?D(z,Oe,oe):pe(z,Oe,oe),IQ(z,c)&&y.state.next({...n,name:z}),y.state.next({name:o.mount?z:void 0,values:En(a)})},B=async z=>{o.mount=!0;const Y=z.target;let oe=Y.name,te=!0;const fe=Ae(r,oe),Oe=ot=>{te=Number.isNaN(ot)||$o(ot)&&isNaN(ot.getTime())||ki(ot,Ae(a,oe,ot))},Te=XQ(e.mode),Ye=XQ(e.reValidateMode);if(fe){let ot,kt;const Dn=Y.type?VQ(fe._f):fM(z),Kt=z.type===fm.BLUR||z.type===fm.FOCUS_OUT,er=!ute(fe._f)&&!e.resolver&&!Ae(n.errors,oe)&&!fe._f.deps||hte(Kt,Ae(n.touchedFields,oe),n.isSubmitted,Ye,Te),Wt=IQ(oe,c,Kt);Pt(a,oe,Dn),Kt?(!Y||!Y.readOnly)&&(fe._f.onBlur&&fe._f.onBlur(z),u&&u(0)):fe._f.onChange&&fe._f.onChange(z);const kn=P(oe,Dn,Kt),rn=!ir(kn)||Wt;if(!Kt&&y.state.next({name:oe,type:z.type,values:En(a)}),er)return(m.isValid||g.isValid)&&(e.mode==="onBlur"?Kt&&k():Kt||k()),rn&&y.state.next({name:oe,...Wt?{}:kn});if(!Kt&&Wt&&y.state.next({...n}),e.resolver){const{errors:Zi}=await M([oe]);if(T([oe]),Oe(Dn),te){const gi=qQ(n.errors,r,oe),tr=qQ(Zi,r,gi.name||oe);ot=tr.error,oe=tr.name,kt=ir(Zi)}}else T([oe],!0),ot=(await YQ(fe,c.disabled,a,x,e.shouldUseNativeValidation))[oe],T([oe]),Oe(Dn),te&&(ot?kt=!1:(m.isValid||g.isValid)&&(kt=await F(r,!0)));te&&(fe._f.deps&&(!Array.isArray(fe._f.deps)||fe._f.deps.length>0)&&X(fe._f.deps),_(oe,kt,ot,kn))}},ye=(z,Y)=>{if(Ae(n.errors,Y)&&z.focus)return z.focus(),1},X=async(z,Y={})=>{let oe,te;const fe=md(z);if(e.resolver){const Oe=await V(on(z)?z:fe);oe=ir(Oe),te=z?!fe.some(Te=>Ae(Oe,Te)):oe}else z?(te=(await Promise.all(fe.map(async Oe=>{const Te=Ae(r,Oe);return await F(Te&&Te._f?{[Oe]:Te}:Te)}))).every(Boolean),!(!te&&!n.isValid)&&k()):te=oe=await F(r);return y.state.next({...!Xr(z)||(m.isValid||g.isValid)&&oe!==n.isValid?{}:{name:z},...e.resolver||!z?{isValid:oe}:{},errors:n.errors}),Y.shouldFocus&&!te&&gd(r,ye,z?fe:c.mount),te},A=(z,Y)=>{let oe={...o.mount?a:i};return Y&&(oe=gM(Y.dirtyFields?n.dirtyFields:n.touchedFields,oe)),on(z)?oe:Xr(z)?Ae(oe,z):z.map(te=>Ae(oe,te))},N=(z,Y)=>({invalid:!!Ae((Y||n).errors,z),isDirty:!!Ae((Y||n).dirtyFields,z),error:Ae((Y||n).errors,z),isValidating:!!Ae(n.validatingFields,z),isTouched:!!Ae((Y||n).touchedFields,z)}),L=z=>{z&&md(z).forEach(Y=>vn(n.errors,Y)),y.state.next({errors:z?n.errors:{}})},q=(z,Y,oe)=>{const te=(Ae(r,z,{_f:{}})._f||{}).ref,fe=Ae(n.errors,z)||{},{ref:Oe,message:Te,type:Ye,...ot}=fe;Pt(n.errors,z,{...ot,...Y,ref:te}),y.state.next({name:z,errors:n.errors,isValid:!1}),oe&&oe.shouldFocus&&te&&te.focus&&te.focus()},se=(z,Y)=>or(z)?y.state.subscribe({next:oe=>"values"in oe&&z(ne(void 0,Y),oe)}):ne(z,Y,!0),he=z=>y.state.subscribe({next:Y=>{fte(z.name,Y.name,z.exact)&&dte(Y,z.formState||m,bt,z.reRenderRoot)&&z.callback({values:{...a},...n,...Y,defaultValues:i})}}).unsubscribe,H=z=>(o.mount=!0,g={...g,...z.formState},he({...z,formState:{...h,...z.formState}})),ge=(z,Y={})=>{for(const oe of z?md(z):c.mount)c.mount.delete(oe),c.array.delete(oe),Y.keepValue||(vn(r,oe),vn(a,oe)),!Y.keepError&&vn(n.errors,oe),!Y.keepDirty&&vn(n.dirtyFields,oe),!Y.keepTouched&&vn(n.touchedFields,oe),!Y.keepIsValidating&&vn(n.validatingFields,oe),!e.shouldUnregister&&!Y.keepDefaultValue&&vn(i,oe);y.state.next({values:En(a)}),y.state.next({...n,...Y.keepDirty?{isDirty:I()}:{}}),!Y.keepIsValid&&k()},xe=({disabled:z,name:Y})=>{(Zr(z)&&o.mount||z||c.disabled.has(Y))&&(z?c.disabled.add(Y):c.disabled.delete(Y))},ke=(z,Y={})=>{let oe=Ae(r,z);const te=Zr(Y.disabled)||Zr(e.disabled);return Pt(r,z,{...oe||{},_f:{...oe&&oe._f?oe._f:{ref:{name:z}},name:z,mount:!0,...Y}}),c.mount.add(z),oe?xe({disabled:Zr(Y.disabled)?Y.disabled:e.disabled,name:z}):$(z,!0,Y.value),{...te?{disabled:Y.disabled||e.disabled}:{},...e.progressive?{required:!!Y.required,min:Ju(Y.min),max:Ju(Y.max),minLength:Ju(Y.minLength),maxLength:Ju(Y.maxLength),pattern:Ju(Y.pattern)}:{},name:z,onChange:B,onBlur:B,ref:fe=>{if(fe){ke(z,Y),oe=Ae(r,z);const Oe=on(fe.value)&&fe.querySelectorAll&&fe.querySelectorAll("input,select,textarea")[0]||fe,Te=ite(Oe),Ye=oe._f.refs||[];if(Te?Ye.find(ot=>ot===Oe):Oe===oe._f.ref)return;Pt(r,z,{_f:{...oe._f,...Te?{refs:[...Ye.filter(Jy),Oe,...Array.isArray(Ae(i,z))?[{}]:[]],ref:{type:Oe.type,name:z}}:{ref:Oe}}}),$(z,!1,void 0,Oe)}else oe=Ae(r,z,{}),oe._f&&(oe._f.mount=!1),(e.shouldUnregister||Y.shouldUnregister)&&!(hM(c.array,z)&&o.action)&&c.unMount.add(z)}}},Ce=()=>e.shouldFocusError&&gd(r,ye,c.mount),Re=z=>{Zr(z)&&(y.state.next({disabled:z}),gd(r,(Y,oe)=>{const te=Ae(r,oe);te&&(Y.disabled=te._f.disabled||z,Array.isArray(te._f.refs)&&te._f.refs.forEach(fe=>{fe.disabled=te._f.disabled||z}))},0,!1))},We=(z,Y)=>async oe=>{let te;oe&&(oe.preventDefault&&oe.preventDefault(),oe.persist&&oe.persist());let fe=En(a);if(y.state.next({isSubmitting:!0}),e.resolver){const{errors:Oe,values:Te}=await M();T(),n.errors=Oe,fe=En(Te)}else await F(r);if(c.disabled.size)for(const Oe of c.disabled)vn(fe,Oe);if(vn(n.errors,"root"),ir(n.errors)){y.state.next({errors:{}});try{await z(fe,oe)}catch(Oe){te=Oe}}else Y&&await Y({...n.errors},oe),Ce(),setTimeout(Ce);if(y.state.next({isSubmitted:!0,isSubmitting:!1,isSubmitSuccessful:ir(n.errors)&&!te,submitCount:n.submitCount+1,errors:n.errors}),te)throw te},Pe=(z,Y={})=>{Ae(r,z)&&(on(Y.defaultValue)?G(z,En(Ae(i,z))):(G(z,Y.defaultValue),Pt(i,z,En(Y.defaultValue))),Y.keepTouched||vn(n.touchedFields,z),Y.keepDirty||(vn(n.dirtyFields,z),n.isDirty=Y.defaultValue?I(z,En(Ae(i,z))):I()),Y.keepError||(vn(n.errors,z),m.isValid&&k()),y.state.next({...n}))},ht=(z,Y={})=>{const oe=z?En(z):i,te=En(oe),fe=ir(z),Oe=fe?i:te;if(Y.keepDefaultValues||(i=oe),!Y.keepValues){if(Y.keepDirtyValues){const Te=new Set([...c.mount,...Object.keys(Wl(i,a))]);for(const Ye of Array.from(Te))Ae(n.dirtyFields,Ye)?Pt(Oe,Ye,Ae(a,Ye)):G(Ye,Ae(Oe,Ye))}else{if(A1&&on(z))for(const Te of c.mount){const Ye=Ae(r,Te);if(Ye&&Ye._f){const ot=Array.isArray(Ye._f.refs)?Ye._f.refs[0]:Ye._f.ref;if(hm(ot)){const kt=ot.closest("form");if(kt){kt.reset();break}}}}if(Y.keepFieldsRef)for(const Te of c.mount)G(Te,Ae(Oe,Te));else r={}}a=e.shouldUnregister?Y.keepDefaultValues?En(i):{}:En(Oe),y.array.next({values:{...Oe}}),y.state.next({values:{...Oe}})}c={mount:Y.keepDirtyValues?c.mount:new Set,unMount:new Set,array:new Set,disabled:new Set,watch:new Set,watchAll:!1,focus:""},o.mount=!m.isValid||!!Y.keepIsValid||!!Y.keepDirtyValues||!e.shouldUnregister&&!ir(Oe),o.watch=!!e.shouldUnregister,o.keepIsValid=!!Y.keepIsValid,o.action=!1,Y.keepErrors||(n.errors={}),y.state.next({submitCount:Y.keepSubmitCount?n.submitCount:0,isDirty:fe?!1:Y.keepDirty?n.isDirty:!!(Y.keepDefaultValues&&!ki(z,i)),isSubmitted:Y.keepIsSubmitted?n.isSubmitted:!1,dirtyFields:fe?{}:Y.keepDirtyValues?Y.keepDefaultValues&&a?Wl(i,a):n.dirtyFields:Y.keepDefaultValues&&z?Wl(i,z):Y.keepDirty?n.dirtyFields:{},touchedFields:Y.keepTouched?n.touchedFields:{},errors:Y.keepErrors?n.errors:{},isSubmitSuccessful:Y.keepIsSubmitSuccessful?n.isSubmitSuccessful:!1,isSubmitting:!1,defaultValues:i})},Ke=(z,Y)=>ht(or(z)?z(a):z,{...e.resetOptions,...Y}),tt=(z,Y={})=>{const oe=Ae(r,z),te=oe&&oe._f;if(te){const fe=te.refs?te.refs[0]:te.ref;fe.focus&&setTimeout(()=>{fe.focus(),Y.shouldSelect&&or(fe.select)&&fe.select()})}},bt=z=>{n={...n,...z}},Ge={control:{register:ke,unregister:ge,getFieldState:N,handleSubmit:We,setError:q,_subscribe:he,_runSchema:M,_updateIsValidating:T,_focusError:Ce,_getWatch:ne,_getDirty:I,_setValid:k,_setFieldArray:C,_setDisabledField:xe,_setErrors:R,_getFieldArray:ee,_reset:ht,_resetDefaultValues:()=>or(e.defaultValues)&&e.defaultValues().then(z=>{Ke(z,e.resetOptions),y.state.next({isLoading:!1})}),_removeUnmounted:W,_disableForm:Re,_subjects:y,_proxyFormState:m,get _fields(){return r},get _formValues(){return a},get _state(){return o},set _state(z){o=z},get _defaultValues(){return i},get _names(){return c},set _names(z){c=z},get _formState(){return n},get _options(){return e},set _options(z){e={...e,...z}}},subscribe:H,trigger:X,register:ke,handleSubmit:We,watch:se,setValue:G,getValues:A,reset:Ke,resetField:Pe,clearErrors:L,unregister:ge,setError:q,setFocus:tt,getFieldState:N};return{...Ge,formControl:Ge}}function SM(t={}){const e=le.useRef(void 0),n=le.useRef(void 0),[r,i]=le.useState({isDirty:!1,isValidating:!1,isLoading:or(t.defaultValues),isSubmitted:!1,isSubmitting:!1,isSubmitSuccessful:!1,isValid:!1,submitCount:0,dirtyFields:{},touchedFields:{},validatingFields:{},errors:t.errors||{},disabled:t.disabled||!1,isReady:!1,defaultValues:or(t.defaultValues)?void 0:t.defaultValues});if(!e.current)if(t.formControl)e.current={...t.formControl,formState:r},t.defaultValues&&!or(t.defaultValues)&&t.formControl.reset(t.defaultValues,t.resetOptions);else{const{formControl:o,...c}=Ote(t);e.current={...c,formState:r}}const a=e.current.control;return a._options=t,P1(()=>{const o=a._subscribe({formState:a._proxyFormState,callback:()=>i({...a._formState}),reRenderRoot:!0});return i(c=>({...c,isReady:!0})),a._formState.isReady=!0,o},[a]),le.useEffect(()=>a._disableForm(t.disabled),[a,t.disabled]),le.useEffect(()=>{t.mode&&(a._options.mode=t.mode),t.reValidateMode&&(a._options.reValidateMode=t.reValidateMode)},[a,t.mode,t.reValidateMode]),le.useEffect(()=>{t.errors&&(a._setErrors(t.errors),a._focusError())},[a,t.errors]),le.useEffect(()=>{t.shouldUnregister&&a._subjects.state.next({values:a._getWatch()})},[a,t.shouldUnregister]),le.useEffect(()=>{if(a._proxyFormState.isDirty){const o=a._getDirty();o!==r.isDirty&&a._subjects.state.next({isDirty:o})}},[a,r.isDirty]),le.useEffect(()=>{var o;t.values&&!ki(t.values,n.current)?(a._reset(t.values,{keepFieldsRef:!0,...a._options.resetOptions}),!((o=a._options.resetOptions)===null||o===void 0)&&o.keepIsValid||a._setValid(),n.current=t.values,i(c=>({...c}))):a._resetDefaultValues()},[a,t.values]),le.useEffect(()=>{a._state.mount||(a._setValid(),a._state.mount=!0),a._state.watch&&(a._state.watch=!1,a._subjects.state.next({...a._formState})),a._removeUnmounted()}),e.current.formState=mM(r,a),e.current}const FQ=(t,e,n)=>{if(t&&"reportValidity"in t){const r=Ae(n,e);t.setCustomValidity(r&&r.message||""),t.reportValidity()}},Lb=(t,e)=>{for(const n in e.fields){const r=e.fields[n];r&&r.ref&&"reportValidity"in r.ref?FQ(r.ref,n,t):r&&r.refs&&r.refs.forEach(i=>FQ(i,n,t))}},WQ=(t,e)=>{e.shouldUseNativeValidation&&Lb(t,e);const n={};for(const r in t){const i=Ae(e.fields,r),a=Object.assign(t[r]||{},{ref:i&&i.ref});if(vte(e.names||Object.keys(t),r)){const o=Object.assign({},Ae(n,r));Pt(o,"root",a),Pt(n,r,o)}else Pt(n,r,a)}return n},vte=(t,e)=>{const n=GQ(e);return t.some(r=>GQ(r).match(`^${n}\\.\\d+`))};function GQ(t){return t.replace(/\]|\[/g,"")}function wM(t,e,n){function r(c,u){var f;Object.defineProperty(c,"_zod",{value:c._zod??{},enumerable:!1}),(f=c._zod).traits??(f.traits=new Set),c._zod.traits.add(t),e(c,u);for(const h in o.prototype)h in c||Object.defineProperty(c,h,{value:o.prototype[h].bind(c)});c._zod.constr=o,c._zod.def=u}const i=n?.Parent??Object;class a extends i{}Object.defineProperty(a,"name",{value:t});function o(c){var u;const f=n?.Parent?new a:this;r(f,c),(u=f._zod).deferred??(u.deferred=[]);for(const h of f._zod.deferred)h();return f}return Object.defineProperty(o,"init",{value:r}),Object.defineProperty(o,Symbol.hasInstance,{value:c=>n?.Parent&&c instanceof n.Parent?!0:c?._zod?.traits?.has(t)}),Object.defineProperty(o,"name",{value:t}),o}class yte extends Error{constructor(){super("Encountered Promise during synchronous parse. Use .parseAsync() instead.")}}const bte={};function kM(t){return bte}function xte(t,e){return typeof e=="bigint"?e.toString():e}const CM=Error.captureStackTrace?Error.captureStackTrace:(...t)=>{};function ap(t){return typeof t=="string"?t:t?.message}function TM(t,e,n){const r={...t,path:t.path??[]};if(!t.message){const i=ap(t.inst?._zod.def?.error?.(t))??ap(e?.error?.(t))??ap(n.customError?.(t))??ap(n.localeError?.(t))??"Invalid input";r.message=i}return delete r.inst,delete r.continue,e?.reportInput||delete r.input,r}const EM=(t,e)=>{t.name="$ZodError",Object.defineProperty(t,"_zod",{value:t._zod,enumerable:!1}),Object.defineProperty(t,"issues",{value:e,enumerable:!1}),Object.defineProperty(t,"message",{get(){return JSON.stringify(e,xte,2)},enumerable:!0}),Object.defineProperty(t,"toString",{value:()=>t.message,enumerable:!1})},Ste=wM("$ZodError",EM),QM=wM("$ZodError",EM,{Parent:Error}),wte=t=>(e,n,r,i)=>{const a=r?Object.assign(r,{async:!1}):{async:!1},o=e._zod.run({value:n,issues:[]},a);if(o instanceof Promise)throw new yte;if(o.issues.length){const c=new(i?.Err??t)(o.issues.map(u=>TM(u,a,kM())));throw CM(c,i?.callee),c}return o.value},kte=wte(QM),Cte=t=>async(e,n,r,i)=>{const a=r?Object.assign(r,{async:!0}):{async:!0};let o=e._zod.run({value:n,issues:[]},a);if(o instanceof Promise&&(o=await o),o.issues.length){const c=new(i?.Err??t)(o.issues.map(u=>TM(u,a,kM())));throw CM(c,i?.callee),c}return o.value},Tte=Cte(QM);function HQ(t,e){try{var n=t()}catch(r){return e(r)}return n&&n.then?n.then(void 0,e):n}function Ete(t,e){for(var n={};t.length;){var r=t[0],i=r.code,a=r.message,o=r.path.join(".");if(!n[o])if("unionErrors"in r){var c=r.unionErrors[0].errors[0];n[o]={message:c.message,type:c.code}}else n[o]={message:a,type:i};if("unionErrors"in r&&r.unionErrors.forEach(function(h){return h.errors.forEach(function(m){return t.push(m)})}),e){var u=n[o].types,f=u&&u[r.code];n[o]=j1(o,e,n,i,f?[].concat(f,r.message):r.message)}t.shift()}return n}function Qte(t,e){for(var n={};t.length;){var r=t[0],i=r.code,a=r.message,o=r.path.join(".");if(!n[o])if(r.code==="invalid_union"&&r.errors.length>0){var c=r.errors[0][0];n[o]={message:c.message,type:c.code}}else n[o]={message:a,type:i};if(r.code==="invalid_union"&&r.errors.forEach(function(h){return h.forEach(function(m){return t.push(m)})}),e){var u=n[o].types,f=u&&u[r.code];n[o]=j1(o,e,n,i,f?[].concat(f,r.message):r.message)}t.shift()}return n}function AM(t,e,n){if(n===void 0&&(n={}),(function(r){return"_def"in r&&typeof r._def=="object"&&"typeName"in r._def})(t))return function(r,i,a){try{return Promise.resolve(HQ(function(){return Promise.resolve(t[n.mode==="sync"?"parse":"parseAsync"](r,e)).then(function(o){return a.shouldUseNativeValidation&&Lb({},a),{errors:{},values:n.raw?Object.assign({},r):o}})},function(o){if((function(c){return Array.isArray(c?.issues)})(o))return{values:{},errors:WQ(Ete(o.errors,!a.shouldUseNativeValidation&&a.criteriaMode==="all"),a)};throw o}))}catch(o){return Promise.reject(o)}};if((function(r){return"_zod"in r&&typeof r._zod=="object"})(t))return function(r,i,a){try{return Promise.resolve(HQ(function(){return Promise.resolve((n.mode==="sync"?kte:Tte)(t,r,e)).then(function(o){return a.shouldUseNativeValidation&&Lb({},a),{errors:{},values:n.raw?Object.assign({},r):o}})},function(o){if((function(c){return c instanceof Ste})(o))return{values:{},errors:WQ(Qte(o.issues,!a.shouldUseNativeValidation&&a.criteriaMode==="all"),a)};throw o}))}catch(o){return Promise.reject(o)}};throw new Error("Invalid input: not a Zod schema")}var Et;(function(t){t.assertEqual=i=>{};function e(i){}t.assertIs=e;function n(i){throw new Error}t.assertNever=n,t.arrayToEnum=i=>{const a={};for(const o of i)a[o]=o;return a},t.getValidEnumValues=i=>{const a=t.objectKeys(i).filter(c=>typeof i[i[c]]!="number"),o={};for(const c of a)o[c]=i[c];return t.objectValues(o)},t.objectValues=i=>t.objectKeys(i).map(function(a){return i[a]}),t.objectKeys=typeof Object.keys=="function"?i=>Object.keys(i):i=>{const a=[];for(const o in i)Object.prototype.hasOwnProperty.call(i,o)&&a.push(o);return a},t.find=(i,a)=>{for(const o of i)if(a(o))return o},t.isInteger=typeof Number.isInteger=="function"?i=>Number.isInteger(i):i=>typeof i=="number"&&Number.isFinite(i)&&Math.floor(i)===i;function r(i,a=" | "){return i.map(o=>typeof o=="string"?`'${o}'`:o).join(a)}t.joinValues=r,t.jsonStringifyReplacer=(i,a)=>typeof a=="bigint"?a.toString():a})(Et||(Et={}));var KQ;(function(t){t.mergeShapes=(e,n)=>({...e,...n})})(KQ||(KQ={}));const ze=Et.arrayToEnum(["string","nan","number","integer","float","boolean","date","bigint","symbol","function","undefined","null","array","object","unknown","promise","void","never","map","set"]),As=t=>{switch(typeof t){case"undefined":return ze.undefined;case"string":return ze.string;case"number":return Number.isNaN(t)?ze.nan:ze.number;case"boolean":return ze.boolean;case"function":return ze.function;case"bigint":return ze.bigint;case"symbol":return ze.symbol;case"object":return Array.isArray(t)?ze.array:t===null?ze.null:t.then&&typeof t.then=="function"&&t.catch&&typeof t.catch=="function"?ze.promise:typeof Map<"u"&&t instanceof Map?ze.map:typeof Set<"u"&&t instanceof Set?ze.set:typeof Date<"u"&&t instanceof Date?ze.date:ze.object;default:return ze.unknown}},we=Et.arrayToEnum(["invalid_type","invalid_literal","custom","invalid_union","invalid_union_discriminator","invalid_enum_value","unrecognized_keys","invalid_arguments","invalid_return_type","invalid_date","invalid_string","too_small","too_big","invalid_intersection_types","not_multiple_of","not_finite"]);class Ja extends Error{get errors(){return this.issues}constructor(e){super(),this.issues=[],this.addIssue=r=>{this.issues=[...this.issues,r]},this.addIssues=(r=[])=>{this.issues=[...this.issues,...r]};const n=new.target.prototype;Object.setPrototypeOf?Object.setPrototypeOf(this,n):this.__proto__=n,this.name="ZodError",this.issues=e}format(e){const n=e||function(a){return a.message},r={_errors:[]},i=a=>{for(const o of a.issues)if(o.code==="invalid_union")o.unionErrors.map(i);else if(o.code==="invalid_return_type")i(o.returnTypeError);else if(o.code==="invalid_arguments")i(o.argumentsError);else if(o.path.length===0)r._errors.push(n(o));else{let c=r,u=0;for(;u<o.path.length;){const f=o.path[u];u===o.path.length-1?(c[f]=c[f]||{_errors:[]},c[f]._errors.push(n(o))):c[f]=c[f]||{_errors:[]},c=c[f],u++}}};return i(this),r}static assert(e){if(!(e instanceof Ja))throw new Error(`Not a ZodError: ${e}`)}toString(){return this.message}get message(){return JSON.stringify(this.issues,Et.jsonStringifyReplacer,2)}get isEmpty(){return this.issues.length===0}flatten(e=n=>n.message){const n={},r=[];for(const i of this.issues)if(i.path.length>0){const a=i.path[0];n[a]=n[a]||[],n[a].push(e(i))}else r.push(e(i));return{formErrors:r,fieldErrors:n}}get formErrors(){return this.flatten()}}Ja.create=t=>new Ja(t);const Zb=(t,e)=>{let n;switch(t.code){case we.invalid_type:t.received===ze.undefined?n="Required":n=`Expected ${t.expected}, received ${t.received}`;break;case we.invalid_literal:n=`Invalid literal value, expected ${JSON.stringify(t.expected,Et.jsonStringifyReplacer)}`;break;case we.unrecognized_keys:n=`Unrecognized key(s) in object: ${Et.joinValues(t.keys,", ")}`;break;case we.invalid_union:n="Invalid input";break;case we.invalid_union_discriminator:n=`Invalid discriminator value. Expected ${Et.joinValues(t.options)}`;break;case we.invalid_enum_value:n=`Invalid enum value. Expected ${Et.joinValues(t.options)}, received '${t.received}'`;break;case we.invalid_arguments:n="Invalid function arguments";break;case we.invalid_return_type:n="Invalid function return type";break;case we.invalid_date:n="Invalid date";break;case we.invalid_string:typeof t.validation=="object"?"includes"in t.validation?(n=`Invalid input: must include "${t.validation.includes}"`,typeof t.validation.position=="number"&&(n=`${n} at one or more positions greater than or equal to ${t.validation.position}`)):"startsWith"in t.validation?n=`Invalid input: must start with "${t.validation.startsWith}"`:"endsWith"in t.validation?n=`Invalid input: must end with "${t.validation.endsWith}"`:Et.assertNever(t.validation):t.validation!=="regex"?n=`Invalid ${t.validation}`:n="Invalid";break;case we.too_small:t.type==="array"?n=`Array must contain ${t.exact?"exactly":t.inclusive?"at least":"more than"} ${t.minimum} element(s)`:t.type==="string"?n=`String must contain ${t.exact?"exactly":t.inclusive?"at least":"over"} ${t.minimum} character(s)`:t.type==="number"?n=`Number must be ${t.exact?"exactly equal to ":t.inclusive?"greater than or equal to ":"greater than "}${t.minimum}`:t.type==="bigint"?n=`Number must be ${t.exact?"exactly equal to ":t.inclusive?"greater than or equal to ":"greater than "}${t.minimum}`:t.type==="date"?n=`Date must be ${t.exact?"exactly equal to ":t.inclusive?"greater than or equal to ":"greater than "}${new Date(Number(t.minimum))}`:n="Invalid input";break;case we.too_big:t.type==="array"?n=`Array must contain ${t.exact?"exactly":t.inclusive?"at most":"less than"} ${t.maximum} element(s)`:t.type==="string"?n=`String must contain ${t.exact?"exactly":t.inclusive?"at most":"under"} ${t.maximum} character(s)`:t.type==="number"?n=`Number must be ${t.exact?"exactly":t.inclusive?"less than or equal to":"less than"} ${t.maximum}`:t.type==="bigint"?n=`BigInt must be ${t.exact?"exactly":t.inclusive?"less than or equal to":"less than"} ${t.maximum}`:t.type==="date"?n=`Date must be ${t.exact?"exactly":t.inclusive?"smaller than or equal to":"smaller than"} ${new Date(Number(t.maximum))}`:n="Invalid input";break;case we.custom:n="Invalid input";break;case we.invalid_intersection_types:n="Intersection results could not be merged";break;case we.not_multiple_of:n=`Number must be a multiple of ${t.multipleOf}`;break;case we.not_finite:n="Number must be finite";break;default:n=e.defaultError,Et.assertNever(t)}return{message:n}};let Ate=Zb;function Rte(){return Ate}const _te=t=>{const{data:e,path:n,errorMaps:r,issueData:i}=t,a=[...n,...i.path||[]],o={...i,path:a};if(i.message!==void 0)return{...i,path:a,message:i.message};let c="";const u=r.filter(f=>!!f).slice().reverse();for(const f of u)c=f(o,{data:e,defaultError:c}).message;return{...i,path:a,message:c}};function _e(t,e){const n=Rte(),r=_te({issueData:e,data:t.data,path:t.path,errorMaps:[t.common.contextualErrorMap,t.schemaErrorMap,n,n===Zb?void 0:Zb].filter(i=>!!i)});t.common.issues.push(r)}class Ir{constructor(){this.value="valid"}dirty(){this.value==="valid"&&(this.value="dirty")}abort(){this.value!=="aborted"&&(this.value="aborted")}static mergeArray(e,n){const r=[];for(const i of n){if(i.status==="aborted")return rt;i.status==="dirty"&&e.dirty(),r.push(i.value)}return{status:e.value,value:r}}static async mergeObjectAsync(e,n){const r=[];for(const i of n){const a=await i.key,o=await i.value;r.push({key:a,value:o})}return Ir.mergeObjectSync(e,r)}static mergeObjectSync(e,n){const r={};for(const i of n){const{key:a,value:o}=i;if(a.status==="aborted"||o.status==="aborted")return rt;a.status==="dirty"&&e.dirty(),o.status==="dirty"&&e.dirty(),a.value!=="__proto__"&&(typeof o.value<"u"||i.alwaysSet)&&(r[a.value]=o.value)}return{status:e.value,value:r}}}const rt=Object.freeze({status:"aborted"}),sd=t=>({status:"dirty",value:t}),pi=t=>({status:"valid",value:t}),JQ=t=>t.status==="aborted",eA=t=>t.status==="dirty",Ac=t=>t.status==="valid",mm=t=>typeof Promise<"u"&&t instanceof Promise;var Ze;(function(t){t.errToObj=e=>typeof e=="string"?{message:e}:e||{},t.toString=e=>typeof e=="string"?e:e?.message})(Ze||(Ze={}));class Fs{constructor(e,n,r,i){this._cachedPath=[],this.parent=e,this.data=n,this._path=r,this._key=i}get path(){return this._cachedPath.length||(Array.isArray(this._key)?this._cachedPath.push(...this._path,...this._key):this._cachedPath.push(...this._path,this._key)),this._cachedPath}}const tA=(t,e)=>{if(Ac(e))return{success:!0,data:e.value};if(!t.common.issues.length)throw new Error("Validation failed but no issues detected.");return{success:!1,get error(){if(this._error)return this._error;const n=new Ja(t.common.issues);return this._error=n,this._error}}};function pt(t){if(!t)return{};const{errorMap:e,invalid_type_error:n,required_error:r,description:i}=t;if(e&&(n||r))throw new Error(`Can't use "invalid_type_error" or "required_error" in conjunction with custom error map.`);return e?{errorMap:e,description:i}:{errorMap:(o,c)=>{const{message:u}=t;return o.code==="invalid_enum_value"?{message:u??c.defaultError}:typeof c.data>"u"?{message:u??r??c.defaultError}:o.code!=="invalid_type"?{message:c.defaultError}:{message:u??n??c.defaultError}},description:i}}class wt{get description(){return this._def.description}_getType(e){return As(e.data)}_getOrReturnCtx(e,n){return n||{common:e.parent.common,data:e.data,parsedType:As(e.data),schemaErrorMap:this._def.errorMap,path:e.path,parent:e.parent}}_processInputParams(e){return{status:new Ir,ctx:{common:e.parent.common,data:e.data,parsedType:As(e.data),schemaErrorMap:this._def.errorMap,path:e.path,parent:e.parent}}}_parseSync(e){const n=this._parse(e);if(mm(n))throw new Error("Synchronous parse encountered promise.");return n}_parseAsync(e){const n=this._parse(e);return Promise.resolve(n)}parse(e,n){const r=this.safeParse(e,n);if(r.success)return r.data;throw r.error}safeParse(e,n){const r={common:{issues:[],async:n?.async??!1,contextualErrorMap:n?.errorMap},path:n?.path||[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:As(e)},i=this._parseSync({data:e,path:r.path,parent:r});return tA(r,i)}"~validate"(e){const n={common:{issues:[],async:!!this["~standard"].async},path:[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:As(e)};if(!this["~standard"].async)try{const r=this._parseSync({data:e,path:[],parent:n});return Ac(r)?{value:r.value}:{issues:n.common.issues}}catch(r){r?.message?.toLowerCase()?.includes("encountered")&&(this["~standard"].async=!0),n.common={issues:[],async:!0}}return this._parseAsync({data:e,path:[],parent:n}).then(r=>Ac(r)?{value:r.value}:{issues:n.common.issues})}async parseAsync(e,n){const r=await this.safeParseAsync(e,n);if(r.success)return r.data;throw r.error}async safeParseAsync(e,n){const r={common:{issues:[],contextualErrorMap:n?.errorMap,async:!0},path:n?.path||[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:As(e)},i=this._parse({data:e,path:r.path,parent:r}),a=await(mm(i)?i:Promise.resolve(i));return tA(r,a)}refine(e,n){const r=i=>typeof n=="string"||typeof n>"u"?{message:n}:typeof n=="function"?n(i):n;return this._refinement((i,a)=>{const o=e(i),c=()=>a.addIssue({code:we.custom,...r(i)});return typeof Promise<"u"&&o instanceof Promise?o.then(u=>u?!0:(c(),!1)):o?!0:(c(),!1)})}refinement(e,n){return this._refinement((r,i)=>e(r)?!0:(i.addIssue(typeof n=="function"?n(r,i):n),!1))}_refinement(e){return new _c({schema:this,typeName:it.ZodEffects,effect:{type:"refinement",refinement:e}})}superRefine(e){return this._refinement(e)}constructor(e){this.spa=this.safeParseAsync,this._def=e,this.parse=this.parse.bind(this),this.safeParse=this.safeParse.bind(this),this.parseAsync=this.parseAsync.bind(this),this.safeParseAsync=this.safeParseAsync.bind(this),this.spa=this.spa.bind(this),this.refine=this.refine.bind(this),this.refinement=this.refinement.bind(this),this.superRefine=this.superRefine.bind(this),this.optional=this.optional.bind(this),this.nullable=this.nullable.bind(this),this.nullish=this.nullish.bind(this),this.array=this.array.bind(this),this.promise=this.promise.bind(this),this.or=this.or.bind(this),this.and=this.and.bind(this),this.transform=this.transform.bind(this),this.brand=this.brand.bind(this),this.default=this.default.bind(this),this.catch=this.catch.bind(this),this.describe=this.describe.bind(this),this.pipe=this.pipe.bind(this),this.readonly=this.readonly.bind(this),this.isNullable=this.isNullable.bind(this),this.isOptional=this.isOptional.bind(this),this["~standard"]={version:1,vendor:"zod",validate:n=>this["~validate"](n)}}optional(){return zs.create(this,this._def)}nullable(){return $c.create(this,this._def)}nullish(){return this.nullable().optional()}array(){return fa.create(this)}promise(){return ym.create(this,this._def)}or(e){return Om.create([this,e],this._def)}and(e){return vm.create(this,e,this._def)}transform(e){return new _c({...pt(this._def),schema:this,typeName:it.ZodEffects,effect:{type:"transform",transform:e}})}default(e){const n=typeof e=="function"?e:()=>e;return new Bb({...pt(this._def),innerType:this,defaultValue:n,typeName:it.ZodDefault})}brand(){return new ene({typeName:it.ZodBranded,type:this,...pt(this._def)})}catch(e){const n=typeof e=="function"?e:()=>e;return new Ib({...pt(this._def),innerType:this,catchValue:n,typeName:it.ZodCatch})}describe(e){const n=this.constructor;return new n({...this._def,description:e})}pipe(e){return D1.create(this,e)}readonly(){return qb.create(this)}isOptional(){return this.safeParse(void 0).success}isNullable(){return this.safeParse(null).success}}const $te=/^c[^\s-]{8,}$/i,Pte=/^[0-9a-z]+$/,jte=/^[0-9A-HJKMNP-TV-Z]{26}$/i,Mte=/^[0-9a-fA-F]{8}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{12}$/i,Nte=/^[a-z0-9_-]{21}$/i,Dte=/^[A-Za-z0-9-_]+\.[A-Za-z0-9-_]+\.[A-Za-z0-9-_]*$/,zte=/^[-+]?P(?!$)(?:(?:[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]{3}(=)?))?$/,RM="((\\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])))",Yte=new RegExp(`^${RM}$`);function _M(t){let e="[0-5]\\d";t.precision?e=`${e}\\.\\d{${t.precision}}`:t.precision==null&&(e=`${e}(\\.\\d+)?`);const n=t.precision?"+":"?";return`([01]\\d|2[0-3]):[0-5]\\d(:${e})${n}`}function Fte(t){return new RegExp(`^${_M(t)}$`)}function Wte(t){let e=`${RM}T${_M(t)}`;const n=[];return n.push(t.local?"Z?":"Z"),t.offset&&n.push("([+-]\\d{2}:?\\d{2})"),e=`${e}(${n.join("|")})`,new RegExp(`^${e}$`)}function Gte(t,e){return!!((e==="v4"||!e)&&Vte.test(t)||(e==="v6"||!e)&&Bte.test(t))}function Hte(t,e){if(!Dte.test(t))return!1;try{const[n]=t.split(".");if(!n)return!1;const r=n.replace(/-/g,"+").replace(/_/g,"/").padEnd(n.length+(4-n.length%4)%4,"="),i=JSON.parse(atob(r));return!(typeof i!="object"||i===null||"typ"in i&&i?.typ!=="JWT"||!i.alg||e&&i.alg!==e)}catch{return!1}}function Kte(t,e){return!!((e==="v4"||!e)&&Xte.test(t)||(e==="v6"||!e)&&Ite.test(t))}class Ms extends wt{_parse(e){if(this._def.coerce&&(e.data=String(e.data)),this._getType(e)!==ze.string){const a=this._getOrReturnCtx(e);return _e(a,{code:we.invalid_type,expected:ze.string,received:a.parsedType}),rt}const r=new Ir;let i;for(const a of this._def.checks)if(a.kind==="min")e.data.length<a.value&&(i=this._getOrReturnCtx(e,i),_e(i,{code:we.too_small,minimum:a.value,type:"string",inclusive:!0,exact:!1,message:a.message}),r.dirty());else if(a.kind==="max")e.data.length>a.value&&(i=this._getOrReturnCtx(e,i),_e(i,{code:we.too_big,maximum:a.value,type:"string",inclusive:!0,exact:!1,message:a.message}),r.dirty());else if(a.kind==="length"){const o=e.data.length>a.value,c=e.data.length<a.value;(o||c)&&(i=this._getOrReturnCtx(e,i),o?_e(i,{code:we.too_big,maximum:a.value,type:"string",inclusive:!0,exact:!0,message:a.message}):c&&_e(i,{code:we.too_small,minimum:a.value,type:"string",inclusive:!0,exact:!0,message:a.message}),r.dirty())}else if(a.kind==="email")Lte.test(e.data)||(i=this._getOrReturnCtx(e,i),_e(i,{validation:"email",code:we.invalid_string,message:a.message}),r.dirty());else if(a.kind==="emoji")e0||(e0=new RegExp(Zte,"u")),e0.test(e.data)||(i=this._getOrReturnCtx(e,i),_e(i,{validation:"emoji",code:we.invalid_string,message:a.message}),r.dirty());else if(a.kind==="uuid")Mte.test(e.data)||(i=this._getOrReturnCtx(e,i),_e(i,{validation:"uuid",code:we.invalid_string,message:a.message}),r.dirty());else if(a.kind==="nanoid")Nte.test(e.data)||(i=this._getOrReturnCtx(e,i),_e(i,{validation:"nanoid",code:we.invalid_string,message:a.message}),r.dirty());else if(a.kind==="cuid")$te.test(e.data)||(i=this._getOrReturnCtx(e,i),_e(i,{validation:"cuid",code:we.invalid_string,message:a.message}),r.dirty());else if(a.kind==="cuid2")Pte.test(e.data)||(i=this._getOrReturnCtx(e,i),_e(i,{validation:"cuid2",code:we.invalid_string,message:a.message}),r.dirty());else if(a.kind==="ulid")jte.test(e.data)||(i=this._getOrReturnCtx(e,i),_e(i,{validation:"ulid",code:we.invalid_string,message:a.message}),r.dirty());else if(a.kind==="url")try{new URL(e.data)}catch{i=this._getOrReturnCtx(e,i),_e(i,{validation:"url",code:we.invalid_string,message:a.message}),r.dirty()}else a.kind==="regex"?(a.regex.lastIndex=0,a.regex.test(e.data)||(i=this._getOrReturnCtx(e,i),_e(i,{validation:"regex",code:we.invalid_string,message:a.message}),r.dirty())):a.kind==="trim"?e.data=e.data.trim():a.kind==="includes"?e.data.includes(a.value,a.position)||(i=this._getOrReturnCtx(e,i),_e(i,{code:we.invalid_string,validation:{includes:a.value,position:a.position},message:a.message}),r.dirty()):a.kind==="toLowerCase"?e.data=e.data.toLowerCase():a.kind==="toUpperCase"?e.data=e.data.toUpperCase():a.kind==="startsWith"?e.data.startsWith(a.value)||(i=this._getOrReturnCtx(e,i),_e(i,{code:we.invalid_string,validation:{startsWith:a.value},message:a.message}),r.dirty()):a.kind==="endsWith"?e.data.endsWith(a.value)||(i=this._getOrReturnCtx(e,i),_e(i,{code:we.invalid_string,validation:{endsWith:a.value},message:a.message}),r.dirty()):a.kind==="datetime"?Wte(a).test(e.data)||(i=this._getOrReturnCtx(e,i),_e(i,{code:we.invalid_string,validation:"datetime",message:a.message}),r.dirty()):a.kind==="date"?Yte.test(e.data)||(i=this._getOrReturnCtx(e,i),_e(i,{code:we.invalid_string,validation:"date",message:a.message}),r.dirty()):a.kind==="time"?Fte(a).test(e.data)||(i=this._getOrReturnCtx(e,i),_e(i,{code:we.invalid_string,validation:"time",message:a.message}),r.dirty()):a.kind==="duration"?zte.test(e.data)||(i=this._getOrReturnCtx(e,i),_e(i,{validation:"duration",code:we.invalid_string,message:a.message}),r.dirty()):a.kind==="ip"?Gte(e.data,a.version)||(i=this._getOrReturnCtx(e,i),_e(i,{validation:"ip",code:we.invalid_string,message:a.message}),r.dirty()):a.kind==="jwt"?Hte(e.data,a.alg)||(i=this._getOrReturnCtx(e,i),_e(i,{validation:"jwt",code:we.invalid_string,message:a.message}),r.dirty()):a.kind==="cidr"?Kte(e.data,a.version)||(i=this._getOrReturnCtx(e,i),_e(i,{validation:"cidr",code:we.invalid_string,message:a.message}),r.dirty()):a.kind==="base64"?qte.test(e.data)||(i=this._getOrReturnCtx(e,i),_e(i,{validation:"base64",code:we.invalid_string,message:a.message}),r.dirty()):a.kind==="base64url"?Ute.test(e.data)||(i=this._getOrReturnCtx(e,i),_e(i,{validation:"base64url",code:we.invalid_string,message:a.message}),r.dirty()):Et.assertNever(a);return{status:r.value,value:e.data}}_regex(e,n,r){return this.refinement(i=>e.test(i),{validation:n,code:we.invalid_string,...Ze.errToObj(r)})}_addCheck(e){return new Ms({...this._def,checks:[...this._def.checks,e]})}email(e){return this._addCheck({kind:"email",...Ze.errToObj(e)})}url(e){return this._addCheck({kind:"url",...Ze.errToObj(e)})}emoji(e){return this._addCheck({kind:"emoji",...Ze.errToObj(e)})}uuid(e){return this._addCheck({kind:"uuid",...Ze.errToObj(e)})}nanoid(e){return this._addCheck({kind:"nanoid",...Ze.errToObj(e)})}cuid(e){return this._addCheck({kind:"cuid",...Ze.errToObj(e)})}cuid2(e){return this._addCheck({kind:"cuid2",...Ze.errToObj(e)})}ulid(e){return this._addCheck({kind:"ulid",...Ze.errToObj(e)})}base64(e){return this._addCheck({kind:"base64",...Ze.errToObj(e)})}base64url(e){return this._addCheck({kind:"base64url",...Ze.errToObj(e)})}jwt(e){return this._addCheck({kind:"jwt",...Ze.errToObj(e)})}ip(e){return this._addCheck({kind:"ip",...Ze.errToObj(e)})}cidr(e){return this._addCheck({kind:"cidr",...Ze.errToObj(e)})}datetime(e){return typeof e=="string"?this._addCheck({kind:"datetime",precision:null,offset:!1,local:!1,message:e}):this._addCheck({kind:"datetime",precision:typeof e?.precision>"u"?null:e?.precision,offset:e?.offset??!1,local:e?.local??!1,...Ze.errToObj(e?.message)})}date(e){return this._addCheck({kind:"date",message:e})}time(e){return typeof e=="string"?this._addCheck({kind:"time",precision:null,message:e}):this._addCheck({kind:"time",precision:typeof e?.precision>"u"?null:e?.precision,...Ze.errToObj(e?.message)})}duration(e){return this._addCheck({kind:"duration",...Ze.errToObj(e)})}regex(e,n){return this._addCheck({kind:"regex",regex:e,...Ze.errToObj(n)})}includes(e,n){return this._addCheck({kind:"includes",value:e,position:n?.position,...Ze.errToObj(n?.message)})}startsWith(e,n){return this._addCheck({kind:"startsWith",value:e,...Ze.errToObj(n)})}endsWith(e,n){return this._addCheck({kind:"endsWith",value:e,...Ze.errToObj(n)})}min(e,n){return this._addCheck({kind:"min",value:e,...Ze.errToObj(n)})}max(e,n){return this._addCheck({kind:"max",value:e,...Ze.errToObj(n)})}length(e,n){return this._addCheck({kind:"length",value:e,...Ze.errToObj(n)})}nonempty(e){return this.min(1,Ze.errToObj(e))}trim(){return new Ms({...this._def,checks:[...this._def.checks,{kind:"trim"}]})}toLowerCase(){return new Ms({...this._def,checks:[...this._def.checks,{kind:"toLowerCase"}]})}toUpperCase(){return new Ms({...this._def,checks:[...this._def.checks,{kind:"toUpperCase"}]})}get isDatetime(){return!!this._def.checks.find(e=>e.kind==="datetime")}get isDate(){return!!this._def.checks.find(e=>e.kind==="date")}get isTime(){return!!this._def.checks.find(e=>e.kind==="time")}get isDuration(){return!!this._def.checks.find(e=>e.kind==="duration")}get isEmail(){return!!this._def.checks.find(e=>e.kind==="email")}get isURL(){return!!this._def.checks.find(e=>e.kind==="url")}get isEmoji(){return!!this._def.checks.find(e=>e.kind==="emoji")}get isUUID(){return!!this._def.checks.find(e=>e.kind==="uuid")}get isNANOID(){return!!this._def.checks.find(e=>e.kind==="nanoid")}get isCUID(){return!!this._def.checks.find(e=>e.kind==="cuid")}get isCUID2(){return!!this._def.checks.find(e=>e.kind==="cuid2")}get isULID(){return!!this._def.checks.find(e=>e.kind==="ulid")}get isIP(){return!!this._def.checks.find(e=>e.kind==="ip")}get isCIDR(){return!!this._def.checks.find(e=>e.kind==="cidr")}get isBase64(){return!!this._def.checks.find(e=>e.kind==="base64")}get isBase64url(){return!!this._def.checks.find(e=>e.kind==="base64url")}get minLength(){let e=null;for(const n of this._def.checks)n.kind==="min"&&(e===null||n.value>e)&&(e=n.value);return e}get maxLength(){let e=null;for(const n of this._def.checks)n.kind==="max"&&(e===null||n.value<e)&&(e=n.value);return e}}Ms.create=t=>new Ms({checks:[],typeName:it.ZodString,coerce:t?.coerce??!1,...pt(t)});function Jte(t,e){const n=(t.toString().split(".")[1]||"").length,r=(e.toString().split(".")[1]||"").length,i=n>r?n:r,a=Number.parseInt(t.toFixed(i).replace(".","")),o=Number.parseInt(e.toFixed(i).replace(".",""));return a%o/10**i}class Ld extends wt{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte,this.step=this.multipleOf}_parse(e){if(this._def.coerce&&(e.data=Number(e.data)),this._getType(e)!==ze.number){const a=this._getOrReturnCtx(e);return _e(a,{code:we.invalid_type,expected:ze.number,received:a.parsedType}),rt}let r;const i=new Ir;for(const a of this._def.checks)a.kind==="int"?Et.isInteger(e.data)||(r=this._getOrReturnCtx(e,r),_e(r,{code:we.invalid_type,expected:"integer",received:"float",message:a.message}),i.dirty()):a.kind==="min"?(a.inclusive?e.data<a.value:e.data<=a.value)&&(r=this._getOrReturnCtx(e,r),_e(r,{code:we.too_small,minimum:a.value,type:"number",inclusive:a.inclusive,exact:!1,message:a.message}),i.dirty()):a.kind==="max"?(a.inclusive?e.data>a.value:e.data>=a.value)&&(r=this._getOrReturnCtx(e,r),_e(r,{code:we.too_big,maximum:a.value,type:"number",inclusive:a.inclusive,exact:!1,message:a.message}),i.dirty()):a.kind==="multipleOf"?Jte(e.data,a.value)!==0&&(r=this._getOrReturnCtx(e,r),_e(r,{code:we.not_multiple_of,multipleOf:a.value,message:a.message}),i.dirty()):a.kind==="finite"?Number.isFinite(e.data)||(r=this._getOrReturnCtx(e,r),_e(r,{code:we.not_finite,message:a.message}),i.dirty()):Et.assertNever(a);return{status:i.value,value:e.data}}gte(e,n){return this.setLimit("min",e,!0,Ze.toString(n))}gt(e,n){return this.setLimit("min",e,!1,Ze.toString(n))}lte(e,n){return this.setLimit("max",e,!0,Ze.toString(n))}lt(e,n){return this.setLimit("max",e,!1,Ze.toString(n))}setLimit(e,n,r,i){return new Ld({...this._def,checks:[...this._def.checks,{kind:e,value:n,inclusive:r,message:Ze.toString(i)}]})}_addCheck(e){return new Ld({...this._def,checks:[...this._def.checks,e]})}int(e){return this._addCheck({kind:"int",message:Ze.toString(e)})}positive(e){return this._addCheck({kind:"min",value:0,inclusive:!1,message:Ze.toString(e)})}negative(e){return this._addCheck({kind:"max",value:0,inclusive:!1,message:Ze.toString(e)})}nonpositive(e){return this._addCheck({kind:"max",value:0,inclusive:!0,message:Ze.toString(e)})}nonnegative(e){return this._addCheck({kind:"min",value:0,inclusive:!0,message:Ze.toString(e)})}multipleOf(e,n){return this._addCheck({kind:"multipleOf",value:e,message:Ze.toString(n)})}finite(e){return this._addCheck({kind:"finite",message:Ze.toString(e)})}safe(e){return this._addCheck({kind:"min",inclusive:!0,value:Number.MIN_SAFE_INTEGER,message:Ze.toString(e)})._addCheck({kind:"max",inclusive:!0,value:Number.MAX_SAFE_INTEGER,message:Ze.toString(e)})}get minValue(){let e=null;for(const n of this._def.checks)n.kind==="min"&&(e===null||n.value>e)&&(e=n.value);return e}get maxValue(){let e=null;for(const n of this._def.checks)n.kind==="max"&&(e===null||n.value<e)&&(e=n.value);return e}get isInt(){return!!this._def.checks.find(e=>e.kind==="int"||e.kind==="multipleOf"&&Et.isInteger(e.value))}get isFinite(){let e=null,n=null;for(const r of this._def.checks){if(r.kind==="finite"||r.kind==="int"||r.kind==="multipleOf")return!0;r.kind==="min"?(n===null||r.value>n)&&(n=r.value):r.kind==="max"&&(e===null||r.value<e)&&(e=r.value)}return Number.isFinite(n)&&Number.isFinite(e)}}Ld.create=t=>new Ld({checks:[],typeName:it.ZodNumber,coerce:t?.coerce||!1,...pt(t)});class Zd extends wt{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte}_parse(e){if(this._def.coerce)try{e.data=BigInt(e.data)}catch{return this._getInvalidInput(e)}if(this._getType(e)!==ze.bigint)return this._getInvalidInput(e);let r;const i=new Ir;for(const a of this._def.checks)a.kind==="min"?(a.inclusive?e.data<a.value:e.data<=a.value)&&(r=this._getOrReturnCtx(e,r),_e(r,{code:we.too_small,type:"bigint",minimum:a.value,inclusive:a.inclusive,message:a.message}),i.dirty()):a.kind==="max"?(a.inclusive?e.data>a.value:e.data>=a.value)&&(r=this._getOrReturnCtx(e,r),_e(r,{code:we.too_big,type:"bigint",maximum:a.value,inclusive:a.inclusive,message:a.message}),i.dirty()):a.kind==="multipleOf"?e.data%a.value!==BigInt(0)&&(r=this._getOrReturnCtx(e,r),_e(r,{code:we.not_multiple_of,multipleOf:a.value,message:a.message}),i.dirty()):Et.assertNever(a);return{status:i.value,value:e.data}}_getInvalidInput(e){const n=this._getOrReturnCtx(e);return _e(n,{code:we.invalid_type,expected:ze.bigint,received:n.parsedType}),rt}gte(e,n){return this.setLimit("min",e,!0,Ze.toString(n))}gt(e,n){return this.setLimit("min",e,!1,Ze.toString(n))}lte(e,n){return this.setLimit("max",e,!0,Ze.toString(n))}lt(e,n){return this.setLimit("max",e,!1,Ze.toString(n))}setLimit(e,n,r,i){return new Zd({...this._def,checks:[...this._def.checks,{kind:e,value:n,inclusive:r,message:Ze.toString(i)}]})}_addCheck(e){return new Zd({...this._def,checks:[...this._def.checks,e]})}positive(e){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!1,message:Ze.toString(e)})}negative(e){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!1,message:Ze.toString(e)})}nonpositive(e){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!0,message:Ze.toString(e)})}nonnegative(e){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!0,message:Ze.toString(e)})}multipleOf(e,n){return this._addCheck({kind:"multipleOf",value:e,message:Ze.toString(n)})}get minValue(){let e=null;for(const n of this._def.checks)n.kind==="min"&&(e===null||n.value>e)&&(e=n.value);return e}get maxValue(){let e=null;for(const n of this._def.checks)n.kind==="max"&&(e===null||n.value<e)&&(e=n.value);return e}}Zd.create=t=>new Zd({checks:[],typeName:it.ZodBigInt,coerce:t?.coerce??!1,...pt(t)});class Vb extends wt{_parse(e){if(this._def.coerce&&(e.data=!!e.data),this._getType(e)!==ze.boolean){const r=this._getOrReturnCtx(e);return _e(r,{code:we.invalid_type,expected:ze.boolean,received:r.parsedType}),rt}return pi(e.data)}}Vb.create=t=>new Vb({typeName:it.ZodBoolean,coerce:t?.coerce||!1,...pt(t)});class gm extends wt{_parse(e){if(this._def.coerce&&(e.data=new Date(e.data)),this._getType(e)!==ze.date){const a=this._getOrReturnCtx(e);return _e(a,{code:we.invalid_type,expected:ze.date,received:a.parsedType}),rt}if(Number.isNaN(e.data.getTime())){const a=this._getOrReturnCtx(e);return _e(a,{code:we.invalid_date}),rt}const r=new Ir;let i;for(const a of this._def.checks)a.kind==="min"?e.data.getTime()<a.value&&(i=this._getOrReturnCtx(e,i),_e(i,{code:we.too_small,message:a.message,inclusive:!0,exact:!1,minimum:a.value,type:"date"}),r.dirty()):a.kind==="max"?e.data.getTime()>a.value&&(i=this._getOrReturnCtx(e,i),_e(i,{code:we.too_big,message:a.message,inclusive:!0,exact:!1,maximum:a.value,type:"date"}),r.dirty()):Et.assertNever(a);return{status:r.value,value:new Date(e.data.getTime())}}_addCheck(e){return new gm({...this._def,checks:[...this._def.checks,e]})}min(e,n){return this._addCheck({kind:"min",value:e.getTime(),message:Ze.toString(n)})}max(e,n){return this._addCheck({kind:"max",value:e.getTime(),message:Ze.toString(n)})}get minDate(){let e=null;for(const n of this._def.checks)n.kind==="min"&&(e===null||n.value>e)&&(e=n.value);return e!=null?new Date(e):null}get maxDate(){let e=null;for(const n of this._def.checks)n.kind==="max"&&(e===null||n.value<e)&&(e=n.value);return e!=null?new Date(e):null}}gm.create=t=>new gm({checks:[],coerce:t?.coerce||!1,typeName:it.ZodDate,...pt(t)});class nA extends wt{_parse(e){if(this._getType(e)!==ze.symbol){const r=this._getOrReturnCtx(e);return _e(r,{code:we.invalid_type,expected:ze.symbol,received:r.parsedType}),rt}return pi(e.data)}}nA.create=t=>new nA({typeName:it.ZodSymbol,...pt(t)});class rA extends wt{_parse(e){if(this._getType(e)!==ze.undefined){const r=this._getOrReturnCtx(e);return _e(r,{code:we.invalid_type,expected:ze.undefined,received:r.parsedType}),rt}return pi(e.data)}}rA.create=t=>new rA({typeName:it.ZodUndefined,...pt(t)});class iA extends wt{_parse(e){if(this._getType(e)!==ze.null){const r=this._getOrReturnCtx(e);return _e(r,{code:we.invalid_type,expected:ze.null,received:r.parsedType}),rt}return pi(e.data)}}iA.create=t=>new iA({typeName:it.ZodNull,...pt(t)});class aA extends wt{constructor(){super(...arguments),this._any=!0}_parse(e){return pi(e.data)}}aA.create=t=>new aA({typeName:it.ZodAny,...pt(t)});class sA extends wt{constructor(){super(...arguments),this._unknown=!0}_parse(e){return pi(e.data)}}sA.create=t=>new sA({typeName:it.ZodUnknown,...pt(t)});class Ws extends wt{_parse(e){const n=this._getOrReturnCtx(e);return _e(n,{code:we.invalid_type,expected:ze.never,received:n.parsedType}),rt}}Ws.create=t=>new Ws({typeName:it.ZodNever,...pt(t)});class oA extends wt{_parse(e){if(this._getType(e)!==ze.undefined){const r=this._getOrReturnCtx(e);return _e(r,{code:we.invalid_type,expected:ze.void,received:r.parsedType}),rt}return pi(e.data)}}oA.create=t=>new oA({typeName:it.ZodVoid,...pt(t)});class fa extends wt{_parse(e){const{ctx:n,status:r}=this._processInputParams(e),i=this._def;if(n.parsedType!==ze.array)return _e(n,{code:we.invalid_type,expected:ze.array,received:n.parsedType}),rt;if(i.exactLength!==null){const o=n.data.length>i.exactLength.value,c=n.data.length<i.exactLength.value;(o||c)&&(_e(n,{code:o?we.too_big:we.too_small,minimum:c?i.exactLength.value:void 0,maximum:o?i.exactLength.value:void 0,type:"array",inclusive:!0,exact:!0,message:i.exactLength.message}),r.dirty())}if(i.minLength!==null&&n.data.length<i.minLength.value&&(_e(n,{code:we.too_small,minimum:i.minLength.value,type:"array",inclusive:!0,exact:!1,message:i.minLength.message}),r.dirty()),i.maxLength!==null&&n.data.length>i.maxLength.value&&(_e(n,{code:we.too_big,maximum:i.maxLength.value,type:"array",inclusive:!0,exact:!1,message:i.maxLength.message}),r.dirty()),n.common.async)return Promise.all([...n.data].map((o,c)=>i.type._parseAsync(new Fs(n,o,n.path,c)))).then(o=>Ir.mergeArray(r,o));const a=[...n.data].map((o,c)=>i.type._parseSync(new Fs(n,o,n.path,c)));return Ir.mergeArray(r,a)}get element(){return this._def.type}min(e,n){return new fa({...this._def,minLength:{value:e,message:Ze.toString(n)}})}max(e,n){return new fa({...this._def,maxLength:{value:e,message:Ze.toString(n)}})}length(e,n){return new fa({...this._def,exactLength:{value:e,message:Ze.toString(n)}})}nonempty(e){return this.min(1,e)}}fa.create=(t,e)=>new fa({type:t,minLength:null,maxLength:null,exactLength:null,typeName:it.ZodArray,...pt(e)});function Gl(t){if(t instanceof yn){const e={};for(const n in t.shape){const r=t.shape[n];e[n]=zs.create(Gl(r))}return new yn({...t._def,shape:()=>e})}else return t instanceof fa?new fa({...t._def,type:Gl(t.element)}):t instanceof zs?zs.create(Gl(t.unwrap())):t instanceof $c?$c.create(Gl(t.unwrap())):t instanceof Wo?Wo.create(t.items.map(e=>Gl(e))):t}class yn extends wt{constructor(){super(...arguments),this._cached=null,this.nonstrict=this.passthrough,this.augment=this.extend}_getCached(){if(this._cached!==null)return this._cached;const e=this._def.shape(),n=Et.objectKeys(e);return this._cached={shape:e,keys:n},this._cached}_parse(e){if(this._getType(e)!==ze.object){const f=this._getOrReturnCtx(e);return _e(f,{code:we.invalid_type,expected:ze.object,received:f.parsedType}),rt}const{status:r,ctx:i}=this._processInputParams(e),{shape:a,keys:o}=this._getCached(),c=[];if(!(this._def.catchall instanceof Ws&&this._def.unknownKeys==="strip"))for(const f in i.data)o.includes(f)||c.push(f);const u=[];for(const f of o){const h=a[f],m=i.data[f];u.push({key:{status:"valid",value:f},value:h._parse(new Fs(i,m,i.path,f)),alwaysSet:f in i.data})}if(this._def.catchall instanceof Ws){const f=this._def.unknownKeys;if(f==="passthrough")for(const h of c)u.push({key:{status:"valid",value:h},value:{status:"valid",value:i.data[h]}});else if(f==="strict")c.length>0&&(_e(i,{code:we.unrecognized_keys,keys:c}),r.dirty());else if(f!=="strip")throw new Error("Internal ZodObject error: invalid unknownKeys value.")}else{const f=this._def.catchall;for(const h of c){const m=i.data[h];u.push({key:{status:"valid",value:h},value:f._parse(new Fs(i,m,i.path,h)),alwaysSet:h in i.data})}}return i.common.async?Promise.resolve().then(async()=>{const f=[];for(const h of u){const m=await h.key,g=await h.value;f.push({key:m,value:g,alwaysSet:h.alwaysSet})}return f}).then(f=>Ir.mergeObjectSync(r,f)):Ir.mergeObjectSync(r,u)}get shape(){return this._def.shape()}strict(e){return Ze.errToObj,new yn({...this._def,unknownKeys:"strict",...e!==void 0?{errorMap:(n,r)=>{const i=this._def.errorMap?.(n,r).message??r.defaultError;return n.code==="unrecognized_keys"?{message:Ze.errToObj(e).message??i}:{message:i}}}:{}})}strip(){return new yn({...this._def,unknownKeys:"strip"})}passthrough(){return new yn({...this._def,unknownKeys:"passthrough"})}extend(e){return new yn({...this._def,shape:()=>({...this._def.shape(),...e})})}merge(e){return new yn({unknownKeys:e._def.unknownKeys,catchall:e._def.catchall,shape:()=>({...this._def.shape(),...e._def.shape()}),typeName:it.ZodObject})}setKey(e,n){return this.augment({[e]:n})}catchall(e){return new yn({...this._def,catchall:e})}pick(e){const n={};for(const r of Et.objectKeys(e))e[r]&&this.shape[r]&&(n[r]=this.shape[r]);return new yn({...this._def,shape:()=>n})}omit(e){const n={};for(const r of Et.objectKeys(this.shape))e[r]||(n[r]=this.shape[r]);return new yn({...this._def,shape:()=>n})}deepPartial(){return Gl(this)}partial(e){const n={};for(const r of Et.objectKeys(this.shape)){const i=this.shape[r];e&&!e[r]?n[r]=i:n[r]=i.optional()}return new yn({...this._def,shape:()=>n})}required(e){const n={};for(const r of Et.objectKeys(this.shape))if(e&&!e[r])n[r]=this.shape[r];else{let a=this.shape[r];for(;a instanceof zs;)a=a._def.innerType;n[r]=a}return new yn({...this._def,shape:()=>n})}keyof(){return $M(Et.objectKeys(this.shape))}}yn.create=(t,e)=>new yn({shape:()=>t,unknownKeys:"strip",catchall:Ws.create(),typeName:it.ZodObject,...pt(e)});yn.strictCreate=(t,e)=>new yn({shape:()=>t,unknownKeys:"strict",catchall:Ws.create(),typeName:it.ZodObject,...pt(e)});yn.lazycreate=(t,e)=>new yn({shape:t,unknownKeys:"strip",catchall:Ws.create(),typeName:it.ZodObject,...pt(e)});class Om extends wt{_parse(e){const{ctx:n}=this._processInputParams(e),r=this._def.options;function i(a){for(const c of a)if(c.result.status==="valid")return c.result;for(const c of a)if(c.result.status==="dirty")return n.common.issues.push(...c.ctx.common.issues),c.result;const o=a.map(c=>new Ja(c.ctx.common.issues));return _e(n,{code:we.invalid_union,unionErrors:o}),rt}if(n.common.async)return Promise.all(r.map(async a=>{const o={...n,common:{...n.common,issues:[]},parent:null};return{result:await a._parseAsync({data:n.data,path:n.path,parent:o}),ctx:o}})).then(i);{let a;const o=[];for(const u of r){const f={...n,common:{...n.common,issues:[]},parent:null},h=u._parseSync({data:n.data,path:n.path,parent:f});if(h.status==="valid")return h;h.status==="dirty"&&!a&&(a={result:h,ctx:f}),f.common.issues.length&&o.push(f.common.issues)}if(a)return n.common.issues.push(...a.ctx.common.issues),a.result;const c=o.map(u=>new Ja(u));return _e(n,{code:we.invalid_union,unionErrors:c}),rt}}get options(){return this._def.options}}Om.create=(t,e)=>new Om({options:t,typeName:it.ZodUnion,...pt(e)});function Xb(t,e){const n=As(t),r=As(e);if(t===e)return{valid:!0,data:t};if(n===ze.object&&r===ze.object){const i=Et.objectKeys(e),a=Et.objectKeys(t).filter(c=>i.indexOf(c)!==-1),o={...t,...e};for(const c of a){const u=Xb(t[c],e[c]);if(!u.valid)return{valid:!1};o[c]=u.data}return{valid:!0,data:o}}else if(n===ze.array&&r===ze.array){if(t.length!==e.length)return{valid:!1};const i=[];for(let a=0;a<t.length;a++){const o=t[a],c=e[a],u=Xb(o,c);if(!u.valid)return{valid:!1};i.push(u.data)}return{valid:!0,data:i}}else return n===ze.date&&r===ze.date&&+t==+e?{valid:!0,data:t}:{valid:!1}}class vm extends wt{_parse(e){const{status:n,ctx:r}=this._processInputParams(e),i=(a,o)=>{if(JQ(a)||JQ(o))return rt;const c=Xb(a.value,o.value);return c.valid?((eA(a)||eA(o))&&n.dirty(),{status:n.value,value:c.data}):(_e(r,{code:we.invalid_intersection_types}),rt)};return r.common.async?Promise.all([this._def.left._parseAsync({data:r.data,path:r.path,parent:r}),this._def.right._parseAsync({data:r.data,path:r.path,parent:r})]).then(([a,o])=>i(a,o)):i(this._def.left._parseSync({data:r.data,path:r.path,parent:r}),this._def.right._parseSync({data:r.data,path:r.path,parent:r}))}}vm.create=(t,e,n)=>new vm({left:t,right:e,typeName:it.ZodIntersection,...pt(n)});class Wo extends wt{_parse(e){const{status:n,ctx:r}=this._processInputParams(e);if(r.parsedType!==ze.array)return _e(r,{code:we.invalid_type,expected:ze.array,received:r.parsedType}),rt;if(r.data.length<this._def.items.length)return _e(r,{code:we.too_small,minimum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),rt;!this._def.rest&&r.data.length>this._def.items.length&&(_e(r,{code:we.too_big,maximum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),n.dirty());const a=[...r.data].map((o,c)=>{const u=this._def.items[c]||this._def.rest;return u?u._parse(new Fs(r,o,r.path,c)):null}).filter(o=>!!o);return r.common.async?Promise.all(a).then(o=>Ir.mergeArray(n,o)):Ir.mergeArray(n,a)}get items(){return this._def.items}rest(e){return new Wo({...this._def,rest:e})}}Wo.create=(t,e)=>{if(!Array.isArray(t))throw new Error("You must pass an array of schemas to z.tuple([ ... ])");return new Wo({items:t,typeName:it.ZodTuple,rest:null,...pt(e)})};class lA extends wt{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(e){const{status:n,ctx:r}=this._processInputParams(e);if(r.parsedType!==ze.map)return _e(r,{code:we.invalid_type,expected:ze.map,received:r.parsedType}),rt;const i=this._def.keyType,a=this._def.valueType,o=[...r.data.entries()].map(([c,u],f)=>({key:i._parse(new Fs(r,c,r.path,[f,"key"])),value:a._parse(new Fs(r,u,r.path,[f,"value"]))}));if(r.common.async){const c=new Map;return Promise.resolve().then(async()=>{for(const u of o){const f=await u.key,h=await u.value;if(f.status==="aborted"||h.status==="aborted")return rt;(f.status==="dirty"||h.status==="dirty")&&n.dirty(),c.set(f.value,h.value)}return{status:n.value,value:c}})}else{const c=new Map;for(const u of o){const f=u.key,h=u.value;if(f.status==="aborted"||h.status==="aborted")return rt;(f.status==="dirty"||h.status==="dirty")&&n.dirty(),c.set(f.value,h.value)}return{status:n.value,value:c}}}}lA.create=(t,e,n)=>new lA({valueType:e,keyType:t,typeName:it.ZodMap,...pt(n)});class Vd extends wt{_parse(e){const{status:n,ctx:r}=this._processInputParams(e);if(r.parsedType!==ze.set)return _e(r,{code:we.invalid_type,expected:ze.set,received:r.parsedType}),rt;const i=this._def;i.minSize!==null&&r.data.size<i.minSize.value&&(_e(r,{code:we.too_small,minimum:i.minSize.value,type:"set",inclusive:!0,exact:!1,message:i.minSize.message}),n.dirty()),i.maxSize!==null&&r.data.size>i.maxSize.value&&(_e(r,{code:we.too_big,maximum:i.maxSize.value,type:"set",inclusive:!0,exact:!1,message:i.maxSize.message}),n.dirty());const a=this._def.valueType;function o(u){const f=new Set;for(const h of u){if(h.status==="aborted")return rt;h.status==="dirty"&&n.dirty(),f.add(h.value)}return{status:n.value,value:f}}const c=[...r.data.values()].map((u,f)=>a._parse(new Fs(r,u,r.path,f)));return r.common.async?Promise.all(c).then(u=>o(u)):o(c)}min(e,n){return new Vd({...this._def,minSize:{value:e,message:Ze.toString(n)}})}max(e,n){return new Vd({...this._def,maxSize:{value:e,message:Ze.toString(n)}})}size(e,n){return this.min(e,n).max(e,n)}nonempty(e){return this.min(1,e)}}Vd.create=(t,e)=>new Vd({valueType:t,minSize:null,maxSize:null,typeName:it.ZodSet,...pt(e)});class cA extends wt{get schema(){return this._def.getter()}_parse(e){const{ctx:n}=this._processInputParams(e);return this._def.getter()._parse({data:n.data,path:n.path,parent:n})}}cA.create=(t,e)=>new cA({getter:t,typeName:it.ZodLazy,...pt(e)});class uA extends wt{_parse(e){if(e.data!==this._def.value){const n=this._getOrReturnCtx(e);return _e(n,{received:n.data,code:we.invalid_literal,expected:this._def.value}),rt}return{status:"valid",value:e.data}}get value(){return this._def.value}}uA.create=(t,e)=>new uA({value:t,typeName:it.ZodLiteral,...pt(e)});function $M(t,e){return new Rc({values:t,typeName:it.ZodEnum,...pt(e)})}class Rc extends wt{_parse(e){if(typeof e.data!="string"){const n=this._getOrReturnCtx(e),r=this._def.values;return _e(n,{expected:Et.joinValues(r),received:n.parsedType,code:we.invalid_type}),rt}if(this._cache||(this._cache=new Set(this._def.values)),!this._cache.has(e.data)){const n=this._getOrReturnCtx(e),r=this._def.values;return _e(n,{received:n.data,code:we.invalid_enum_value,options:r}),rt}return pi(e.data)}get options(){return this._def.values}get enum(){const e={};for(const n of this._def.values)e[n]=n;return e}get Values(){const e={};for(const n of this._def.values)e[n]=n;return e}get Enum(){const e={};for(const n of this._def.values)e[n]=n;return e}extract(e,n=this._def){return Rc.create(e,{...this._def,...n})}exclude(e,n=this._def){return Rc.create(this.options.filter(r=>!e.includes(r)),{...this._def,...n})}}Rc.create=$M;class dA extends wt{_parse(e){const n=Et.getValidEnumValues(this._def.values),r=this._getOrReturnCtx(e);if(r.parsedType!==ze.string&&r.parsedType!==ze.number){const i=Et.objectValues(n);return _e(r,{expected:Et.joinValues(i),received:r.parsedType,code:we.invalid_type}),rt}if(this._cache||(this._cache=new Set(Et.getValidEnumValues(this._def.values))),!this._cache.has(e.data)){const i=Et.objectValues(n);return _e(r,{received:r.data,code:we.invalid_enum_value,options:i}),rt}return pi(e.data)}get enum(){return this._def.values}}dA.create=(t,e)=>new dA({values:t,typeName:it.ZodNativeEnum,...pt(e)});class ym extends wt{unwrap(){return this._def.type}_parse(e){const{ctx:n}=this._processInputParams(e);if(n.parsedType!==ze.promise&&n.common.async===!1)return _e(n,{code:we.invalid_type,expected:ze.promise,received:n.parsedType}),rt;const r=n.parsedType===ze.promise?n.data:Promise.resolve(n.data);return pi(r.then(i=>this._def.type.parseAsync(i,{path:n.path,errorMap:n.common.contextualErrorMap})))}}ym.create=(t,e)=>new ym({type:t,typeName:it.ZodPromise,...pt(e)});class _c extends wt{innerType(){return this._def.schema}sourceType(){return this._def.schema._def.typeName===it.ZodEffects?this._def.schema.sourceType():this._def.schema}_parse(e){const{status:n,ctx:r}=this._processInputParams(e),i=this._def.effect||null,a={addIssue:o=>{_e(r,o),o.fatal?n.abort():n.dirty()},get path(){return r.path}};if(a.addIssue=a.addIssue.bind(a),i.type==="preprocess"){const o=i.transform(r.data,a);if(r.common.async)return Promise.resolve(o).then(async c=>{if(n.value==="aborted")return rt;const u=await this._def.schema._parseAsync({data:c,path:r.path,parent:r});return u.status==="aborted"?rt:u.status==="dirty"||n.value==="dirty"?sd(u.value):u});{if(n.value==="aborted")return rt;const c=this._def.schema._parseSync({data:o,path:r.path,parent:r});return c.status==="aborted"?rt:c.status==="dirty"||n.value==="dirty"?sd(c.value):c}}if(i.type==="refinement"){const o=c=>{const u=i.refinement(c,a);if(r.common.async)return Promise.resolve(u);if(u instanceof Promise)throw new Error("Async refinement encountered during synchronous parse operation. Use .parseAsync instead.");return c};if(r.common.async===!1){const c=this._def.schema._parseSync({data:r.data,path:r.path,parent:r});return c.status==="aborted"?rt:(c.status==="dirty"&&n.dirty(),o(c.value),{status:n.value,value:c.value})}else return this._def.schema._parseAsync({data:r.data,path:r.path,parent:r}).then(c=>c.status==="aborted"?rt:(c.status==="dirty"&&n.dirty(),o(c.value).then(()=>({status:n.value,value:c.value}))))}if(i.type==="transform")if(r.common.async===!1){const o=this._def.schema._parseSync({data:r.data,path:r.path,parent:r});if(!Ac(o))return rt;const c=i.transform(o.value,a);if(c instanceof Promise)throw new Error("Asynchronous transform encountered during synchronous parse operation. Use .parseAsync instead.");return{status:n.value,value:c}}else return this._def.schema._parseAsync({data:r.data,path:r.path,parent:r}).then(o=>Ac(o)?Promise.resolve(i.transform(o.value,a)).then(c=>({status:n.value,value:c})):rt);Et.assertNever(i)}}_c.create=(t,e,n)=>new _c({schema:t,typeName:it.ZodEffects,effect:e,...pt(n)});_c.createWithPreprocess=(t,e,n)=>new _c({schema:e,effect:{type:"preprocess",transform:t},typeName:it.ZodEffects,...pt(n)});class zs extends wt{_parse(e){return this._getType(e)===ze.undefined?pi(void 0):this._def.innerType._parse(e)}unwrap(){return this._def.innerType}}zs.create=(t,e)=>new zs({innerType:t,typeName:it.ZodOptional,...pt(e)});class $c extends wt{_parse(e){return this._getType(e)===ze.null?pi(null):this._def.innerType._parse(e)}unwrap(){return this._def.innerType}}$c.create=(t,e)=>new $c({innerType:t,typeName:it.ZodNullable,...pt(e)});class Bb extends wt{_parse(e){const{ctx:n}=this._processInputParams(e);let r=n.data;return n.parsedType===ze.undefined&&(r=this._def.defaultValue()),this._def.innerType._parse({data:r,path:n.path,parent:n})}removeDefault(){return this._def.innerType}}Bb.create=(t,e)=>new Bb({innerType:t,typeName:it.ZodDefault,defaultValue:typeof e.default=="function"?e.default:()=>e.default,...pt(e)});class Ib extends wt{_parse(e){const{ctx:n}=this._processInputParams(e),r={...n,common:{...n.common,issues:[]}},i=this._def.innerType._parse({data:r.data,path:r.path,parent:{...r}});return mm(i)?i.then(a=>({status:"valid",value:a.status==="valid"?a.value:this._def.catchValue({get error(){return new Ja(r.common.issues)},input:r.data})})):{status:"valid",value:i.status==="valid"?i.value:this._def.catchValue({get error(){return new Ja(r.common.issues)},input:r.data})}}removeCatch(){return this._def.innerType}}Ib.create=(t,e)=>new Ib({innerType:t,typeName:it.ZodCatch,catchValue:typeof e.catch=="function"?e.catch:()=>e.catch,...pt(e)});class fA extends wt{_parse(e){if(this._getType(e)!==ze.nan){const r=this._getOrReturnCtx(e);return _e(r,{code:we.invalid_type,expected:ze.nan,received:r.parsedType}),rt}return{status:"valid",value:e.data}}}fA.create=t=>new fA({typeName:it.ZodNaN,...pt(t)});class ene extends wt{_parse(e){const{ctx:n}=this._processInputParams(e),r=n.data;return this._def.type._parse({data:r,path:n.path,parent:n})}unwrap(){return this._def.type}}class D1 extends wt{_parse(e){const{status:n,ctx:r}=this._processInputParams(e);if(r.common.async)return(async()=>{const a=await this._def.in._parseAsync({data:r.data,path:r.path,parent:r});return a.status==="aborted"?rt:a.status==="dirty"?(n.dirty(),sd(a.value)):this._def.out._parseAsync({data:a.value,path:r.path,parent:r})})();{const i=this._def.in._parseSync({data:r.data,path:r.path,parent:r});return i.status==="aborted"?rt:i.status==="dirty"?(n.dirty(),{status:"dirty",value:i.value}):this._def.out._parseSync({data:i.value,path:r.path,parent:r})}}static create(e,n){return new D1({in:e,out:n,typeName:it.ZodPipeline})}}class qb extends wt{_parse(e){const n=this._def.innerType._parse(e),r=i=>(Ac(i)&&(i.value=Object.freeze(i.value)),i);return mm(n)?n.then(i=>r(i)):r(n)}unwrap(){return this._def.innerType}}qb.create=(t,e)=>new qb({innerType:t,typeName:it.ZodReadonly,...pt(e)});var it;(function(t){t.ZodString="ZodString",t.ZodNumber="ZodNumber",t.ZodNaN="ZodNaN",t.ZodBigInt="ZodBigInt",t.ZodBoolean="ZodBoolean",t.ZodDate="ZodDate",t.ZodSymbol="ZodSymbol",t.ZodUndefined="ZodUndefined",t.ZodNull="ZodNull",t.ZodAny="ZodAny",t.ZodUnknown="ZodUnknown",t.ZodNever="ZodNever",t.ZodVoid="ZodVoid",t.ZodArray="ZodArray",t.ZodObject="ZodObject",t.ZodUnion="ZodUnion",t.ZodDiscriminatedUnion="ZodDiscriminatedUnion",t.ZodIntersection="ZodIntersection",t.ZodTuple="ZodTuple",t.ZodRecord="ZodRecord",t.ZodMap="ZodMap",t.ZodSet="ZodSet",t.ZodFunction="ZodFunction",t.ZodLazy="ZodLazy",t.ZodLiteral="ZodLiteral",t.ZodEnum="ZodEnum",t.ZodEffects="ZodEffects",t.ZodNativeEnum="ZodNativeEnum",t.ZodOptional="ZodOptional",t.ZodNullable="ZodNullable",t.ZodDefault="ZodDefault",t.ZodCatch="ZodCatch",t.ZodPromise="ZodPromise",t.ZodBranded="ZodBranded",t.ZodPipeline="ZodPipeline",t.ZodReadonly="ZodReadonly"})(it||(it={}));const ra=Ms.create,tne=Vb.create;Ws.create;const Ub=fa.create,Rp=yn.create;Om.create;vm.create;Wo.create;Rc.create;ym.create;zs.create;$c.create;var nne=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],PM=nne.reduce((t,e)=>{const n=ZR(`Primitive.${e}`),r=w.forwardRef((i,a)=>{const{asChild:o,...c}=i,u=o?n:e;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),v.jsx(u,{...c,ref:a})});return r.displayName=`Primitive.${e}`,{...t,[e]:r}},{}),rne="Label",jM=w.forwardRef((t,e)=>v.jsx(PM.label,{...t,ref:e,onMouseDown:n=>{n.target.closest("button, input, select, textarea")||(t.onMouseDown?.(n),!n.defaultPrevented&&n.detail>1&&n.preventDefault())}}));jM.displayName=rne;var ine=jM;function MM({className:t,...e}){return v.jsx(ine,{"data-slot":"label",className:Be("flex items-center gap-2 text-sm leading-none font-medium select-none group-data-[disabled=true]:pointer-events-none group-data-[disabled=true]:opacity-50 peer-disabled:cursor-not-allowed peer-disabled:opacity-50",t),...e})}var ane="Separator",hA="horizontal",sne=["horizontal","vertical"],NM=w.forwardRef((t,e)=>{const{decorative:n,orientation:r=hA,...i}=t,a=one(r)?r:hA,c=n?{role:"none"}:{"aria-orientation":a==="vertical"?a:void 0,role:"separator"};return v.jsx(PM.div,{"data-orientation":a,...c,...i,ref:e})});NM.displayName=ane;function one(t){return sne.includes(t)}var lne=NM;function cne({className:t,orientation:e="horizontal",decorative:n=!0,...r}){return v.jsx(lne,{"data-slot":"separator",decorative:n,orientation:e,className:Be("bg-border shrink-0 data-[orientation=horizontal]:h-px data-[orientation=horizontal]:w-full data-[orientation=vertical]:h-full data-[orientation=vertical]:w-px",t),...r})}const une=Mm("group/field flex w-full gap-3 data-[invalid=true]:text-destructive",{variants:{orientation:{vertical:["flex-col [&>*]:w-full [&>.sr-only]:w-auto"],horizontal:["flex-row items-center","[&>[data-slot=field-label]]:flex-auto","has-[>[data-slot=field-content]]:items-start has-[>[data-slot=field-content]]:[&>[role=checkbox],[role=radio]]:mt-px"],responsive:["flex-col [&>*]:w-full [&>.sr-only]:w-auto @md/field-group:flex-row @md/field-group:items-center @md/field-group:[&>*]:w-auto","@md/field-group:[&>[data-slot=field-label]]:flex-auto","@md/field-group:has-[>[data-slot=field-content]]:items-start @md/field-group:has-[>[data-slot=field-content]]:[&>[role=checkbox],[role=radio]]:mt-px"]}},defaultVariants:{orientation:"vertical"}});function Ls({className:t,orientation:e="vertical",...n}){return v.jsx("div",{role:"group","data-slot":"field","data-orientation":e,className:Be(une({orientation:e}),t),...n})}function fc({className:t,...e}){return v.jsx(MM,{"data-slot":"field-label",className:Be("group/field-label peer/field-label flex w-fit gap-2 leading-snug group-data-[disabled=true]/field:opacity-50","has-[>[data-slot=field]]:w-full has-[>[data-slot=field]]:flex-col has-[>[data-slot=field]]:rounded-md has-[>[data-slot=field]]:border [&>*]:data-[slot=field]:p-4","has-data-[state=checked]:bg-primary/5 has-data-[state=checked]:border-primary dark:has-data-[state=checked]:bg-primary/10",t),...e})}function DM({className:t,...e}){return v.jsx("p",{"data-slot":"field-description",className:Be("text-muted-foreground text-sm leading-normal font-normal group-has-[[data-orientation=horizontal]]/field:text-balance","last:mt-0 nth-last-2:-mt-1 [[data-variant=legend]+&]:-mt-1.5","[&>a:hover]:text-primary [&>a]:underline [&>a]:underline-offset-4",t),...e})}function Ua({className:t,children:e,errors:n,...r}){const i=w.useMemo(()=>{if(e)return e;if(!n?.length)return null;const a=[...new Map(n.map(o=>[o?.message,o])).values()];return a?.length==1?a[0]?.message:v.jsx("ul",{className:"ml-4 flex list-disc flex-col gap-1",children:a.map((o,c)=>o?.message&&v.jsx("li",{children:o.message},c))})},[e,n]);return i?v.jsx("div",{role:"alert","data-slot":"field-error",className:Be("text-destructive text-sm font-normal",t),...r,children:i}):null}function pA(t){if(!t||typeof t!="string")return[];const e=new Set,n=new Set(["none","transparent","currentcolor","currentColor","inherit","initial","unset"]),r=/^#([0-9a-fA-F]{3}|[0-9a-fA-F]{6}|[0-9a-fA-F]{8})$/,i=/^rgba?\(\s*\d+(?:\.\d+)?%?\s*,\s*\d+(?:\.\d+)?%?\s*,\s*\d+(?:\.\d+)?%?(?:\s*,\s*[\d.]+)?\s*\)$/,a=/^hsla?\(\s*\d+(?:\.\d+)?\s*,\s*\d+(?:\.\d+)?%\s*,\s*\d+(?:\.\d+)?%(?:\s*,\s*[\d.]+)?\s*\)$/,o=/^[a-zA-Z]+$/;function c(C){const E=C.trim();if(!E||E.length===0)return;const R=E.toLowerCase();E.startsWith("--")||n.has(R)||(r.test(E)||i.test(E)||a.test(E)||o.test(E)&&!E.startsWith("--"))&&e.add(E)}const u=/style\s*=\s*["']([^"']+)["']/gi;let f;for(;(f=u.exec(t))!==null;){const C=f[1];if(!C)continue;const E=/(?:^|;)\s*(?:fill|stroke|color|stop-color|flood-color|lighting-color)\s*:\s*([^;]+)/gi;let R;for(;(R=E.exec(C))!==null;){const $=R[1];$&&c($)}}const h=/\b(fill|stroke|color|stop-color|flood-color|lighting-color)\s*=\s*["']([^"']+)["']/gi;let m;for(;(m=h.exec(t))!==null;){const C=m[2];C&&c(C)}const g=/#([0-9a-fA-F]{3}|[0-9a-fA-F]{6}|[0-9a-fA-F]{8})\b/g;let y;for(;(y=g.exec(t))!==null;)t.substring(Math.max(0,y.index-2),y.index).endsWith("--")||c(y[0]);const x=/rgba?\(\s*\d+(?:\.\d+)?%?\s*,\s*\d+(?:\.\d+)?%?\s*,\s*\d+(?:\.\d+)?%?(?:\s*,\s*[\d.]+)?\s*\)/g;let S;for(;(S=x.exec(t))!==null;)t.substring(Math.max(0,S.index-2),S.index).endsWith("--")||c(S[0]);const k=/hsla?\(\s*\d+(?:\.\d+)?\s*,\s*\d+(?:\.\d+)?%\s*,\s*\d+(?:\.\d+)?%(?:\s*,\s*[\d.]+)?\s*\)/g;let T;for(;(T=k.exec(t))!==null;)t.substring(Math.max(0,T.index-2),T.index).endsWith("--")||c(T[0]);return Array.from(e)}function dne(t,e){return w.useReducer((n,r)=>e[n][r]??n,t)}var z1="ScrollArea",[zM]=pa(z1),[fne,mi]=zM(z1),LM=w.forwardRef((t,e)=>{const{__scopeScrollArea:n,type:r="hover",dir:i,scrollHideDelay:a=600,...o}=t,[c,u]=w.useState(null),[f,h]=w.useState(null),[m,g]=w.useState(null),[y,x]=w.useState(null),[S,k]=w.useState(null),[T,C]=w.useState(0),[E,R]=w.useState(0),[$,P]=w.useState(!1),[_,M]=w.useState(!1),V=ft(e,W=>u(W)),F=Nm(i);return v.jsx(fne,{scope:n,type:r,dir:F,scrollHideDelay:a,scrollArea:c,viewport:f,onViewportChange:h,content:m,onContentChange:g,scrollbarX:y,onScrollbarXChange:x,scrollbarXEnabled:$,onScrollbarXEnabledChange:P,scrollbarY:S,onScrollbarYChange:k,scrollbarYEnabled:_,onScrollbarYEnabledChange:M,onCornerWidthChange:C,onCornerHeightChange:R,children:v.jsx(et.div,{dir:F,...o,ref:V,style:{position:"relative","--radix-scroll-area-corner-width":T+"px","--radix-scroll-area-corner-height":E+"px",...t.style}})})});LM.displayName=z1;var ZM="ScrollAreaViewport",VM=w.forwardRef((t,e)=>{const{__scopeScrollArea:n,children:r,nonce:i,...a}=t,o=mi(ZM,n),c=w.useRef(null),u=ft(e,c,o.onViewportChange);return v.jsxs(v.Fragment,{children:[v.jsx("style",{dangerouslySetInnerHTML:{__html:"[data-radix-scroll-area-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-scroll-area-viewport]::-webkit-scrollbar{display:none}"},nonce:i}),v.jsx(et.div,{"data-radix-scroll-area-viewport":"",...a,ref:u,style:{overflowX:o.scrollbarXEnabled?"scroll":"hidden",overflowY:o.scrollbarYEnabled?"scroll":"hidden",...t.style},children:v.jsx("div",{ref:o.onContentChange,style:{minWidth:"100%",display:"table"},children:r})})]})});VM.displayName=ZM;var ga="ScrollAreaScrollbar",XM=w.forwardRef((t,e)=>{const{forceMount:n,...r}=t,i=mi(ga,t.__scopeScrollArea),{onScrollbarXEnabledChange:a,onScrollbarYEnabledChange:o}=i,c=t.orientation==="horizontal";return w.useEffect(()=>(c?a(!0):o(!0),()=>{c?a(!1):o(!1)}),[c,a,o]),i.type==="hover"?v.jsx(hne,{...r,ref:e,forceMount:n}):i.type==="scroll"?v.jsx(pne,{...r,ref:e,forceMount:n}):i.type==="auto"?v.jsx(BM,{...r,ref:e,forceMount:n}):i.type==="always"?v.jsx(L1,{...r,ref:e}):null});XM.displayName=ga;var hne=w.forwardRef((t,e)=>{const{forceMount:n,...r}=t,i=mi(ga,t.__scopeScrollArea),[a,o]=w.useState(!1);return w.useEffect(()=>{const c=i.scrollArea;let u=0;if(c){const f=()=>{window.clearTimeout(u),o(!0)},h=()=>{u=window.setTimeout(()=>o(!1),i.scrollHideDelay)};return c.addEventListener("pointerenter",f),c.addEventListener("pointerleave",h),()=>{window.clearTimeout(u),c.removeEventListener("pointerenter",f),c.removeEventListener("pointerleave",h)}}},[i.scrollArea,i.scrollHideDelay]),v.jsx(fi,{present:n||a,children:v.jsx(BM,{"data-state":a?"visible":"hidden",...r,ref:e})})}),pne=w.forwardRef((t,e)=>{const{forceMount:n,...r}=t,i=mi(ga,t.__scopeScrollArea),a=t.orientation==="horizontal",o=xg(()=>u("SCROLL_END"),100),[c,u]=dne("hidden",{hidden:{SCROLL:"scrolling"},scrolling:{SCROLL_END:"idle",POINTER_ENTER:"interacting"},interacting:{SCROLL:"interacting",POINTER_LEAVE:"idle"},idle:{HIDE:"hidden",SCROLL:"scrolling",POINTER_ENTER:"interacting"}});return w.useEffect(()=>{if(c==="idle"){const f=window.setTimeout(()=>u("HIDE"),i.scrollHideDelay);return()=>window.clearTimeout(f)}},[c,i.scrollHideDelay,u]),w.useEffect(()=>{const f=i.viewport,h=a?"scrollLeft":"scrollTop";if(f){let m=f[h];const g=()=>{const y=f[h];m!==y&&(u("SCROLL"),o()),m=y};return f.addEventListener("scroll",g),()=>f.removeEventListener("scroll",g)}},[i.viewport,a,u,o]),v.jsx(fi,{present:n||c!=="hidden",children:v.jsx(L1,{"data-state":c==="hidden"?"hidden":"visible",...r,ref:e,onPointerEnter:He(t.onPointerEnter,()=>u("POINTER_ENTER")),onPointerLeave:He(t.onPointerLeave,()=>u("POINTER_LEAVE"))})})}),BM=w.forwardRef((t,e)=>{const n=mi(ga,t.__scopeScrollArea),{forceMount:r,...i}=t,[a,o]=w.useState(!1),c=t.orientation==="horizontal",u=xg(()=>{if(n.viewport){const f=n.viewport.offsetWidth<n.viewport.scrollWidth,h=n.viewport.offsetHeight<n.viewport.scrollHeight;o(c?f:h)}},10);return Pc(n.viewport,u),Pc(n.content,u),v.jsx(fi,{present:r||a,children:v.jsx(L1,{"data-state":a?"visible":"hidden",...i,ref:e})})}),L1=w.forwardRef((t,e)=>{const{orientation:n="vertical",...r}=t,i=mi(ga,t.__scopeScrollArea),a=w.useRef(null),o=w.useRef(0),[c,u]=w.useState({content:0,viewport:0,scrollbar:{size:0,paddingStart:0,paddingEnd:0}}),f=FM(c.viewport,c.content),h={...r,sizes:c,onSizesChange:u,hasThumb:f>0&&f<1,onThumbChange:g=>a.current=g,onThumbPointerUp:()=>o.current=0,onThumbPointerDown:g=>o.current=g};function m(g,y){return bne(g,o.current,c,y)}return n==="horizontal"?v.jsx(mne,{...h,ref:e,onThumbPositionChange:()=>{if(i.viewport&&a.current){const g=i.viewport.scrollLeft,y=mA(g,c,i.dir);a.current.style.transform=`translate3d(${y}px, 0, 0)`}},onWheelScroll:g=>{i.viewport&&(i.viewport.scrollLeft=g)},onDragScroll:g=>{i.viewport&&(i.viewport.scrollLeft=m(g,i.dir))}}):n==="vertical"?v.jsx(gne,{...h,ref:e,onThumbPositionChange:()=>{if(i.viewport&&a.current){const g=i.viewport.scrollTop,y=mA(g,c);a.current.style.transform=`translate3d(0, ${y}px, 0)`}},onWheelScroll:g=>{i.viewport&&(i.viewport.scrollTop=g)},onDragScroll:g=>{i.viewport&&(i.viewport.scrollTop=m(g))}}):null}),mne=w.forwardRef((t,e)=>{const{sizes:n,onSizesChange:r,...i}=t,a=mi(ga,t.__scopeScrollArea),[o,c]=w.useState(),u=w.useRef(null),f=ft(e,u,a.onScrollbarXChange);return w.useEffect(()=>{u.current&&c(getComputedStyle(u.current))},[u]),v.jsx(qM,{"data-orientation":"horizontal",...i,ref:f,sizes:n,style:{bottom:0,left:a.dir==="rtl"?"var(--radix-scroll-area-corner-width)":0,right:a.dir==="ltr"?"var(--radix-scroll-area-corner-width)":0,"--radix-scroll-area-thumb-width":bg(n)+"px",...t.style},onThumbPointerDown:h=>t.onThumbPointerDown(h.x),onDragScroll:h=>t.onDragScroll(h.x),onWheelScroll:(h,m)=>{if(a.viewport){const g=a.viewport.scrollLeft+h.deltaX;t.onWheelScroll(g),GM(g,m)&&h.preventDefault()}},onResize:()=>{u.current&&a.viewport&&o&&r({content:a.viewport.scrollWidth,viewport:a.viewport.offsetWidth,scrollbar:{size:u.current.clientWidth,paddingStart:xm(o.paddingLeft),paddingEnd:xm(o.paddingRight)}})}})}),gne=w.forwardRef((t,e)=>{const{sizes:n,onSizesChange:r,...i}=t,a=mi(ga,t.__scopeScrollArea),[o,c]=w.useState(),u=w.useRef(null),f=ft(e,u,a.onScrollbarYChange);return w.useEffect(()=>{u.current&&c(getComputedStyle(u.current))},[u]),v.jsx(qM,{"data-orientation":"vertical",...i,ref:f,sizes:n,style:{top:0,right:a.dir==="ltr"?0:void 0,left:a.dir==="rtl"?0:void 0,bottom:"var(--radix-scroll-area-corner-height)","--radix-scroll-area-thumb-height":bg(n)+"px",...t.style},onThumbPointerDown:h=>t.onThumbPointerDown(h.y),onDragScroll:h=>t.onDragScroll(h.y),onWheelScroll:(h,m)=>{if(a.viewport){const g=a.viewport.scrollTop+h.deltaY;t.onWheelScroll(g),GM(g,m)&&h.preventDefault()}},onResize:()=>{u.current&&a.viewport&&o&&r({content:a.viewport.scrollHeight,viewport:a.viewport.offsetHeight,scrollbar:{size:u.current.clientHeight,paddingStart:xm(o.paddingTop),paddingEnd:xm(o.paddingBottom)}})}})}),[One,IM]=zM(ga),qM=w.forwardRef((t,e)=>{const{__scopeScrollArea:n,sizes:r,hasThumb:i,onThumbChange:a,onThumbPointerUp:o,onThumbPointerDown:c,onThumbPositionChange:u,onDragScroll:f,onWheelScroll:h,onResize:m,...g}=t,y=mi(ga,n),[x,S]=w.useState(null),k=ft(e,V=>S(V)),T=w.useRef(null),C=w.useRef(""),E=y.viewport,R=r.content-r.viewport,$=kr(h),P=kr(u),_=xg(m,10);function M(V){if(T.current){const F=V.clientX-T.current.left,W=V.clientY-T.current.top;f({x:F,y:W})}}return w.useEffect(()=>{const V=F=>{const W=F.target;x?.contains(W)&&$(F,R)};return document.addEventListener("wheel",V,{passive:!1}),()=>document.removeEventListener("wheel",V,{passive:!1})},[E,x,R,$]),w.useEffect(P,[r,P]),Pc(x,_),Pc(y.content,_),v.jsx(One,{scope:n,scrollbar:x,hasThumb:i,onThumbChange:kr(a),onThumbPointerUp:kr(o),onThumbPositionChange:P,onThumbPointerDown:kr(c),children:v.jsx(et.div,{...g,ref:k,style:{position:"absolute",...g.style},onPointerDown:He(t.onPointerDown,V=>{V.button===0&&(V.target.setPointerCapture(V.pointerId),T.current=x.getBoundingClientRect(),C.current=document.body.style.webkitUserSelect,document.body.style.webkitUserSelect="none",y.viewport&&(y.viewport.style.scrollBehavior="auto"),M(V))}),onPointerMove:He(t.onPointerMove,M),onPointerUp:He(t.onPointerUp,V=>{const F=V.target;F.hasPointerCapture(V.pointerId)&&F.releasePointerCapture(V.pointerId),document.body.style.webkitUserSelect=C.current,y.viewport&&(y.viewport.style.scrollBehavior=""),T.current=null})})})}),bm="ScrollAreaThumb",UM=w.forwardRef((t,e)=>{const{forceMount:n,...r}=t,i=IM(bm,t.__scopeScrollArea);return v.jsx(fi,{present:n||i.hasThumb,children:v.jsx(vne,{ref:e,...r})})}),vne=w.forwardRef((t,e)=>{const{__scopeScrollArea:n,style:r,...i}=t,a=mi(bm,n),o=IM(bm,n),{onThumbPositionChange:c}=o,u=ft(e,m=>o.onThumbChange(m)),f=w.useRef(void 0),h=xg(()=>{f.current&&(f.current(),f.current=void 0)},100);return w.useEffect(()=>{const m=a.viewport;if(m){const g=()=>{if(h(),!f.current){const y=xne(m,c);f.current=y,c()}};return c(),m.addEventListener("scroll",g),()=>m.removeEventListener("scroll",g)}},[a.viewport,h,c]),v.jsx(et.div,{"data-state":o.hasThumb?"visible":"hidden",...i,ref:u,style:{width:"var(--radix-scroll-area-thumb-width)",height:"var(--radix-scroll-area-thumb-height)",...r},onPointerDownCapture:He(t.onPointerDownCapture,m=>{const y=m.target.getBoundingClientRect(),x=m.clientX-y.left,S=m.clientY-y.top;o.onThumbPointerDown({x,y:S})}),onPointerUp:He(t.onPointerUp,o.onThumbPointerUp)})});UM.displayName=bm;var Z1="ScrollAreaCorner",YM=w.forwardRef((t,e)=>{const n=mi(Z1,t.__scopeScrollArea),r=!!(n.scrollbarX&&n.scrollbarY);return n.type!=="scroll"&&r?v.jsx(yne,{...t,ref:e}):null});YM.displayName=Z1;var yne=w.forwardRef((t,e)=>{const{__scopeScrollArea:n,...r}=t,i=mi(Z1,n),[a,o]=w.useState(0),[c,u]=w.useState(0),f=!!(a&&c);return Pc(i.scrollbarX,()=>{const h=i.scrollbarX?.offsetHeight||0;i.onCornerHeightChange(h),u(h)}),Pc(i.scrollbarY,()=>{const h=i.scrollbarY?.offsetWidth||0;i.onCornerWidthChange(h),o(h)}),f?v.jsx(et.div,{...r,ref:e,style:{width:a,height:c,position:"absolute",right:i.dir==="ltr"?0:void 0,left:i.dir==="rtl"?0:void 0,bottom:0,...t.style}}):null});function xm(t){return t?parseInt(t,10):0}function FM(t,e){const n=t/e;return isNaN(n)?0:n}function bg(t){const e=FM(t.viewport,t.content),n=t.scrollbar.paddingStart+t.scrollbar.paddingEnd,r=(t.scrollbar.size-n)*e;return Math.max(r,18)}function bne(t,e,n,r="ltr"){const i=bg(n),a=i/2,o=e||a,c=i-o,u=n.scrollbar.paddingStart+o,f=n.scrollbar.size-n.scrollbar.paddingEnd-c,h=n.content-n.viewport,m=r==="ltr"?[0,h]:[h*-1,0];return WM([u,f],m)(t)}function mA(t,e,n="ltr"){const r=bg(e),i=e.scrollbar.paddingStart+e.scrollbar.paddingEnd,a=e.scrollbar.size-i,o=e.content-e.viewport,c=a-r,u=n==="ltr"?[0,o]:[o*-1,0],f=yd(t,u);return WM([0,o],[0,c])(f)}function WM(t,e){return n=>{if(t[0]===t[1]||e[0]===e[1])return e[0];const r=(e[1]-e[0])/(t[1]-t[0]);return e[0]+r*(n-t[0])}}function GM(t,e){return t>0&&t<e}var xne=(t,e=()=>{})=>{let n={left:t.scrollLeft,top:t.scrollTop},r=0;return(function i(){const a={left:t.scrollLeft,top:t.scrollTop},o=n.left!==a.left,c=n.top!==a.top;(o||c)&&e(),n=a,r=window.requestAnimationFrame(i)})(),()=>window.cancelAnimationFrame(r)};function xg(t,e){const n=kr(t),r=w.useRef(0);return w.useEffect(()=>()=>window.clearTimeout(r.current),[]),w.useCallback(()=>{window.clearTimeout(r.current),r.current=window.setTimeout(n,e)},[n,e])}function Pc(t,e){const n=kr(e);jn(()=>{let r=0;if(t){const i=new ResizeObserver(()=>{cancelAnimationFrame(r),r=window.requestAnimationFrame(n)});return i.observe(t),()=>{window.cancelAnimationFrame(r),i.unobserve(t)}}},[t,n])}var Sne=LM,wne=VM,kne=YM;function ff({className:t,children:e,...n}){return v.jsxs(Sne,{"data-slot":"scroll-area",className:Be("relative",t),...n,children:[v.jsx(wne,{"data-slot":"scroll-area-viewport",className:"focus-visible:ring-ring/50 size-full rounded-[inherit] transition-[color,box-shadow] outline-none focus-visible:ring-[3px] focus-visible:outline-1 p-2.5 -mx-2.5",children:e}),v.jsx(Cne,{}),v.jsx(kne,{})]})}function Cne({className:t,orientation:e="vertical",...n}){return v.jsx(XM,{"data-slot":"scroll-area-scrollbar",orientation:e,className:Be("flex touch-none p-px transition-colors select-none",e==="vertical"&&"h-full w-2.5 border-l border-l-transparent",e==="horizontal"&&"h-2.5 flex-col border-t border-t-transparent",t),...n,children:v.jsx(UM,{"data-slot":"scroll-area-thumb",className:"bg-border relative flex-1 rounded-full"})})}const Tne=Rp({name:ra().min(1,"Name is required"),tags:ra().optional().default(""),content:ra().min(1,"SVG content is required")});function HM({open:t,onOpenChange:e,svgContent:n,onSuccess:r,mode:i,initialData:a,initialName:o}){const c=C6(),{data:u}=Kd(),f=Ox(),h=w.useMemo(()=>pA(n),[n]),m=w.useMemo(()=>h.length===1&&h[0]?{[h[0]]:"currentColor"}:null,[h]),[g,y]=w.useState({}),[x,S]=w.useState({}),[k,T]=w.useState(null),[C,E]=w.useState("");w.useEffect(()=>{if(t&&i==="edit"&&a?.colorVariableKeys){const V=pA(n),F={};V.forEach((W,I)=>{const ne=a.colorVariableKeys?.[I];if(ne)if(ne==="currentColor")F[W]="currentColor";else if(ne.startsWith("var(--"))F[W]=ne;else{const ee=ne.replace("--","");u?.colorVariables.includes(`--${ee}`)&&(F[W]=`var(--${ee})`)}}),y(F),S({}),T(null),E("")}else if(t&&h.length>1&&i==="create"){const V={};h.forEach((F,W)=>{W===0&&(V[F]="currentColor")}),y(V),S({}),T(null),E("")}},[t,i,a,n,h,u]);const R=SM({resolver:AM(Tne),defaultValues:{name:"",tags:"",content:n}});w.useEffect(()=>{t&&(R.setValue("content",n),i==="edit"&&a?(R.setValue("name",a.name),R.setValue("tags",a.tags.join(", "))):o&&R.setValue("name",o))},[t,n,R,i,a,o]);const $=R.handleSubmit(async V=>{const F=(V.tags||"").split(",").map(I=>I.trim()).filter(I=>I.length>0);if(h.length>1){const I={};let ne=!1;if(h.forEach(ee=>{(!g[ee]||g[ee].trim()==="")&&(I[ee]="Please select a mapping for this color",ne=!0)}),ne){S(I),bn.error(`Please map all colors before ${i==="edit"?"updating":"creating"} the icon`);return}S({})}const W=m||g;try{const I=await c.mutateAsync({name:V.name,tags:F,content:V.content,colorMap:Object.keys(W).length>0?W:void 0});bn.success(`Icon ${i==="edit"?"updated":"created"} successfully!`),e(!1),R.reset(),r(I.icon.name)}catch(I){bn.error(`Failed to ${i==="edit"?"update":"create"} icon. Please try again.`),console.error(`Error ${i==="edit"?"updating":"creating"} icon:`,I)}}),P=u?.colorVariables||[],_=[{value:"currentColor",label:"currentColor"},...P.map(V=>({value:`var(${V})`,label:V})),{value:"__CREATE_NEW__",label:"+ Create new variable..."}],M=async(V,F)=>{if(!F.trim()){bn.error("Variable name cannot be empty");return}if(!F.startsWith("--")){bn.error("Variable name must start with -- (e.g., --icons-secondary)");return}if(P.includes(F)){bn.error("This variable already exists");return}if(!u){bn.error("Config not loaded");return}try{const W={...u,colorVariables:[...P,F]};await f.mutateAsync({config:W,changes:[]}),y(I=>({...I,[V]:`var(${F})`})),T(null),E(""),bn.success(`Variable ${F} created and mapped`)}catch(W){bn.error("Failed to create variable"),console.error("Error creating variable:",W)}};return v.jsx(zx,{open:t,onOpenChange:e,children:v.jsxs(Lx,{className:"max-w-4xl max-h-[90vh]",children:[v.jsxs(Zx,{children:[v.jsx(Vx,{children:i==="edit"?"Edit Icon":"Create Icon"}),v.jsxs(Xx,{children:[i==="edit"?"Update the icon properties below.":"Enter the icon name and tags to create your icon.",h.length>1&&" Map colors to variables below."]})]}),v.jsxs("form",{onSubmit:$,className:"flex flex-col gap-4",children:[v.jsx(ff,{className:"max-h-[60vh]",children:v.jsxs("div",{className:"flex flex-col gap-4 pr-4",children:[v.jsxs(Ls,{children:[v.jsx(fc,{children:"Name"}),v.jsx(pd,{name:"name",control:R.control,render:({field:V})=>v.jsx(Ci,{...V,placeholder:"e.g. home, search, user",disabled:i==="edit",className:R.formState.errors.name?"border-destructive":""})}),R.formState.errors.name&&v.jsx(Ua,{errors:[R.formState.errors.name]})]}),v.jsxs(Ls,{children:[v.jsx(fc,{children:"Tags (comma-separated)"}),v.jsx(pd,{name:"tags",control:R.control,render:({field:V})=>v.jsx(Ci,{...V,placeholder:"e.g. navigation, ui, icon",className:R.formState.errors.tags?"border-destructive":""})}),R.formState.errors.tags&&v.jsx(Ua,{errors:[R.formState.errors.tags]})]}),h.length>1&&v.jsxs(Ls,{children:[v.jsx(fc,{children:"Color Mapping"}),v.jsx("div",{className:"flex flex-col gap-3 mt-3 rounded-lg border p-4 bg-muted/30",children:h.map(V=>{const F=!!x[V];return v.jsxs("div",{className:"flex flex-col gap-1.5",children:[v.jsxs("div",{className:`flex items-center gap-4 p-3 rounded-lg border bg-background ${F?"border-destructive":""}`,children:[v.jsx("div",{className:"size-10 rounded border shrink-0",style:{backgroundColor:V}}),v.jsx("div",{className:"flex-1 min-w-0",children:v.jsx("p",{className:"text-sm font-mono truncate",children:V})}),v.jsxs("div",{className:"flex items-center gap-2 shrink-0",children:[v.jsx("span",{className:"text-sm text-muted-foreground",children:"→"}),k===V?v.jsxs("div",{className:"flex items-center gap-2 w-[200px]",children:[v.jsx(Ci,{value:C,onChange:W=>E(W.target.value),placeholder:"e.g. --icons-secondary",className:"flex-1 font-mono text-sm",onKeyDown:W=>{W.key==="Enter"?(W.preventDefault(),M(V,C)):W.key==="Escape"&&(T(null),E(""))},autoFocus:!0}),v.jsx(Rt,{type:"button",size:"sm",onClick:()=>M(V,C),disabled:f.isPending,children:"Add"}),v.jsx(Rt,{type:"button",size:"sm",variant:"outline",onClick:()=>{T(null),E("")},children:"Cancel"})]}):v.jsxs(b$,{value:g[V]||"",onValueChange:W=>{W==="__CREATE_NEW__"?(T(V),E("")):(y(I=>({...I,[V]:W})),x[V]&&S(I=>{const ne={...I};return delete ne[V],ne}))},children:[v.jsx(S$,{className:`w-[200px] ${F?"border-destructive":""}`,children:v.jsx(x$,{placeholder:"Select mapping..."})}),v.jsx(w$,{children:_.map(W=>v.jsx(_0,{value:W.value,children:W.label},W.value))})]})]})]}),F&&v.jsx("p",{className:"text-sm text-destructive px-3",children:x[V]})]},V)})})]})]})}),v.jsxs("div",{className:"flex justify-end gap-2 pt-2",children:[v.jsx(Rt,{type:"button",variant:"outline",onClick:()=>e(!1),disabled:c.isPending,children:"Cancel"}),v.jsx(Rt,{type:"submit",disabled:c.isPending,children:c.isPending?i==="edit"?"Updating...":"Creating...":i==="edit"?"Update Icon":"Create Icon"})]})]})]})})}function Ene(){const t=Ho(),[e,n]=iL(),[r,i]=w.useState(`<svg width="700" height="700" viewBox="0 0 700 700" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
793
|
-
<path d="M150 250H155H350H550H685C642.5 105 507.5 0 350 0C192.5 0 57.5 105 15 250H150Z" fill="#E5E5E5"/>
|
|
794
|
-
<path d="M575 300V350C575 392.5 542.5 425 500 425H435C402.5 425 375 405 365 372.5L350 340L335 375C325 405 297.5 425 265 425H200C157.5 425 125 392.5 125 350V300H5C2.5 317.5 0 332.5 0 350C0 542.5 157.5 700 350 700C542.5 700 700 542.5 700 350C700 332.5 697.5 317.5 695 300H575ZM497.5 495C457.5 530 405 550 350 550C335 550 325 540 325 525C325 510 335 500 350 500C392.5 500 432.5 485 465 455C475 445 490 447.5 500 457.5C510 470 510 485 497.5 495Z" fill="#E5E5E5"/>
|
|
795
|
-
</svg>`),[a,o]=w.useState(!1),[c,u]=w.useState(void 0);w.useEffect(()=>{const m=e.get("content"),g=e.get("name");if(m)try{const y=decodeURIComponent(m);i(y)}catch(y){console.error("Failed to decode SVG content from URL:",y)}if(g)try{const y=decodeURIComponent(g);u(y),o(!0)}catch(y){console.error("Failed to decode name from URL:",y)}(m||g)&&n({},{replace:!0})},[e,n]);const f=w.useMemo(()=>{if(!r||r.trim().length===0)return!1;try{return!new DOMParser().parseFromString(r,"image/svg+xml").querySelector("parsererror")}catch{return!1}},[r]),h=m=>{t(`/icons/${m}/preview`)};return v.jsxs("div",{className:"flex h-[calc(100vh-4rem)] flex-col gap-4 p-4",children:[v.jsxs("div",{className:"flex flex-1 gap-4 overflow-hidden",children:[v.jsx("div",{className:"flex-1 overflow-hidden rounded-lg border",children:v.jsx(uM,{value:r,onChange:i})}),v.jsx("div",{className:"flex-1 overflow-hidden rounded-lg border",children:v.jsxs("div",{className:"flex h-full w-full items-center justify-center bg-muted/30 p-8 relative",children:[v.jsxs("div",{className:"absolute top-4 left-4 max-w-xs flex flex-col gap-2",children:[v.jsx("p",{className:"text-sm font-medium text-foreground",children:"Your original SVG preview"}),v.jsx("p",{className:"text-sm text-muted-foreground",children:`I know this icon looks rough, no worries. I'll take care of everything for you. Hit "Create Icon" and watch the magic.`})]}),v.jsx(nc,{content:r,className:"h-[50%] w-[50%] flex flex-col items-center justify-center"})]})})]}),v.jsx("div",{className:"flex justify-end",children:v.jsx(Rt,{onClick:()=>o(!0),disabled:!f,size:"lg",children:"Create Icon"})}),v.jsx(HM,{open:a,onOpenChange:o,svgContent:r,onSuccess:h,mode:"create",initialName:c})]})}var KM=["PageUp","PageDown"],JM=["ArrowUp","ArrowDown","ArrowLeft","ArrowRight"],eN={"from-left":["Home","PageDown","ArrowDown","ArrowLeft"],"from-right":["Home","PageDown","ArrowDown","ArrowRight"],"from-bottom":["Home","PageDown","ArrowDown","ArrowLeft"],"from-top":["Home","PageDown","ArrowUp","ArrowLeft"]},Fc="Slider",[Yb,Qne,Ane]=bx(Fc),[tN]=pa(Fc,[Ane]),[Rne,Sg]=tN(Fc),nN=w.forwardRef((t,e)=>{const{name:n,min:r=0,max:i=100,step:a=1,orientation:o="horizontal",disabled:c=!1,minStepsBetweenThumbs:u=0,defaultValue:f=[r],value:h,onValueChange:m=()=>{},onValueCommit:g=()=>{},inverted:y=!1,form:x,...S}=t,k=w.useRef(new Set),T=w.useRef(0),E=o==="horizontal"?_ne:$ne,[R=[],$]=Ga({prop:h,defaultProp:f,onChange:W=>{[...k.current][T.current]?.focus(),m(W)}}),P=w.useRef(R);function _(W){const I=Dne(R,W);F(W,I)}function M(W){F(W,T.current)}function V(){const W=P.current[T.current];R[T.current]!==W&&g(R)}function F(W,I,{commit:ne}={commit:!1}){const ee=Vne(a),pe=Xne(Math.round((W-r)/a)*a+r,ee),D=yd(pe,[r,i]);$((G=[])=>{const B=Mne(G,D,I);if(Zne(B,u*a)){T.current=B.indexOf(D);const ye=String(B)!==String(G);return ye&&ne&&g(B),ye?B:G}else return G})}return v.jsx(Rne,{scope:t.__scopeSlider,name:n,disabled:c,min:r,max:i,valueIndexToChangeRef:T,thumbs:k.current,values:R,orientation:o,form:x,children:v.jsx(Yb.Provider,{scope:t.__scopeSlider,children:v.jsx(Yb.Slot,{scope:t.__scopeSlider,children:v.jsx(E,{"aria-disabled":c,"data-disabled":c?"":void 0,...S,ref:e,onPointerDown:He(S.onPointerDown,()=>{c||(P.current=R)}),min:r,max:i,inverted:y,onSlideStart:c?void 0:_,onSlideMove:c?void 0:M,onSlideEnd:c?void 0:V,onHomeKeyDown:()=>!c&&F(r,0,{commit:!0}),onEndKeyDown:()=>!c&&F(i,R.length-1,{commit:!0}),onStepKeyDown:({event:W,direction:I})=>{if(!c){const pe=KM.includes(W.key)||W.shiftKey&&JM.includes(W.key)?10:1,D=T.current,G=R[D],B=a*pe*I;F(G+B,D,{commit:!0})}}})})})})});nN.displayName=Fc;var[rN,iN]=tN(Fc,{startEdge:"left",endEdge:"right",size:"width",direction:1}),_ne=w.forwardRef((t,e)=>{const{min:n,max:r,dir:i,inverted:a,onSlideStart:o,onSlideMove:c,onSlideEnd:u,onStepKeyDown:f,...h}=t,[m,g]=w.useState(null),y=ft(e,E=>g(E)),x=w.useRef(void 0),S=Nm(i),k=S==="ltr",T=k&&!a||!k&&a;function C(E){const R=x.current||m.getBoundingClientRect(),$=[0,R.width],_=V1($,T?[n,r]:[r,n]);return x.current=R,_(E-R.left)}return v.jsx(rN,{scope:t.__scopeSlider,startEdge:T?"left":"right",endEdge:T?"right":"left",direction:T?1:-1,size:"width",children:v.jsx(aN,{dir:S,"data-orientation":"horizontal",...h,ref:y,style:{...h.style,"--radix-slider-thumb-transform":"translateX(-50%)"},onSlideStart:E=>{const R=C(E.clientX);o?.(R)},onSlideMove:E=>{const R=C(E.clientX);c?.(R)},onSlideEnd:()=>{x.current=void 0,u?.()},onStepKeyDown:E=>{const $=eN[T?"from-left":"from-right"].includes(E.key);f?.({event:E,direction:$?-1:1})}})})}),$ne=w.forwardRef((t,e)=>{const{min:n,max:r,inverted:i,onSlideStart:a,onSlideMove:o,onSlideEnd:c,onStepKeyDown:u,...f}=t,h=w.useRef(null),m=ft(e,h),g=w.useRef(void 0),y=!i;function x(S){const k=g.current||h.current.getBoundingClientRect(),T=[0,k.height],E=V1(T,y?[r,n]:[n,r]);return g.current=k,E(S-k.top)}return v.jsx(rN,{scope:t.__scopeSlider,startEdge:y?"bottom":"top",endEdge:y?"top":"bottom",size:"height",direction:y?1:-1,children:v.jsx(aN,{"data-orientation":"vertical",...f,ref:m,style:{...f.style,"--radix-slider-thumb-transform":"translateY(50%)"},onSlideStart:S=>{const k=x(S.clientY);a?.(k)},onSlideMove:S=>{const k=x(S.clientY);o?.(k)},onSlideEnd:()=>{g.current=void 0,c?.()},onStepKeyDown:S=>{const T=eN[y?"from-bottom":"from-top"].includes(S.key);u?.({event:S,direction:T?-1:1})}})})}),aN=w.forwardRef((t,e)=>{const{__scopeSlider:n,onSlideStart:r,onSlideMove:i,onSlideEnd:a,onHomeKeyDown:o,onEndKeyDown:c,onStepKeyDown:u,...f}=t,h=Sg(Fc,n);return v.jsx(et.span,{...f,ref:e,onKeyDown:He(t.onKeyDown,m=>{m.key==="Home"?(o(m),m.preventDefault()):m.key==="End"?(c(m),m.preventDefault()):KM.concat(JM).includes(m.key)&&(u(m),m.preventDefault())}),onPointerDown:He(t.onPointerDown,m=>{const g=m.target;g.setPointerCapture(m.pointerId),m.preventDefault(),h.thumbs.has(g)?g.focus():r(m)}),onPointerMove:He(t.onPointerMove,m=>{m.target.hasPointerCapture(m.pointerId)&&i(m)}),onPointerUp:He(t.onPointerUp,m=>{const g=m.target;g.hasPointerCapture(m.pointerId)&&(g.releasePointerCapture(m.pointerId),a(m))})})}),sN="SliderTrack",oN=w.forwardRef((t,e)=>{const{__scopeSlider:n,...r}=t,i=Sg(sN,n);return v.jsx(et.span,{"data-disabled":i.disabled?"":void 0,"data-orientation":i.orientation,...r,ref:e})});oN.displayName=sN;var Fb="SliderRange",lN=w.forwardRef((t,e)=>{const{__scopeSlider:n,...r}=t,i=Sg(Fb,n),a=iN(Fb,n),o=w.useRef(null),c=ft(e,o),u=i.values.length,f=i.values.map(g=>dN(g,i.min,i.max)),h=u>1?Math.min(...f):0,m=100-Math.max(...f);return v.jsx(et.span,{"data-orientation":i.orientation,"data-disabled":i.disabled?"":void 0,...r,ref:c,style:{...t.style,[a.startEdge]:h+"%",[a.endEdge]:m+"%"}})});lN.displayName=Fb;var Wb="SliderThumb",cN=w.forwardRef((t,e)=>{const n=Qne(t.__scopeSlider),[r,i]=w.useState(null),a=ft(e,c=>i(c)),o=w.useMemo(()=>r?n().findIndex(c=>c.ref.current===r):-1,[n,r]);return v.jsx(Pne,{...t,ref:a,index:o})}),Pne=w.forwardRef((t,e)=>{const{__scopeSlider:n,index:r,name:i,...a}=t,o=Sg(Wb,n),c=iN(Wb,n),[u,f]=w.useState(null),h=ft(e,C=>f(C)),m=u?o.form||!!u.closest("form"):!0,g=Qx(u),y=o.values[r],x=y===void 0?0:dN(y,o.min,o.max),S=Nne(r,o.values.length),k=g?.[c.size],T=k?zne(k,x,c.direction):0;return w.useEffect(()=>{if(u)return o.thumbs.add(u),()=>{o.thumbs.delete(u)}},[u,o.thumbs]),v.jsxs("span",{style:{transform:"var(--radix-slider-thumb-transform)",position:"absolute",[c.startEdge]:`calc(${x}% + ${T}px)`},children:[v.jsx(Yb.ItemSlot,{scope:t.__scopeSlider,children:v.jsx(et.span,{role:"slider","aria-label":t["aria-label"]||S,"aria-valuemin":o.min,"aria-valuenow":y,"aria-valuemax":o.max,"aria-orientation":o.orientation,"data-orientation":o.orientation,"data-disabled":o.disabled?"":void 0,tabIndex:o.disabled?void 0:0,...a,ref:h,style:y===void 0?{display:"none"}:t.style,onFocus:He(t.onFocus,()=>{o.valueIndexToChangeRef.current=r})})}),m&&v.jsx(uN,{name:i??(o.name?o.name+(o.values.length>1?"[]":""):void 0),form:o.form,value:y},r)]})});cN.displayName=Wb;var jne="RadioBubbleInput",uN=w.forwardRef(({__scopeSlider:t,value:e,...n},r)=>{const i=w.useRef(null),a=ft(i,r),o=$x(e);return w.useEffect(()=>{const c=i.current;if(!c)return;const u=window.HTMLInputElement.prototype,h=Object.getOwnPropertyDescriptor(u,"value").set;if(o!==e&&h){const m=new Event("input",{bubbles:!0});h.call(c,e),c.dispatchEvent(m)}},[o,e]),v.jsx(et.input,{style:{display:"none"},...n,ref:a,defaultValue:e})});uN.displayName=jne;function Mne(t=[],e,n){const r=[...t];return r[n]=e,r.sort((i,a)=>i-a)}function dN(t,e,n){const a=100/(n-e)*(t-e);return yd(a,[0,100])}function Nne(t,e){return e>2?`Value ${t+1} of ${e}`:e===2?["Minimum","Maximum"][t]:void 0}function Dne(t,e){if(t.length===1)return 0;const n=t.map(i=>Math.abs(i-e)),r=Math.min(...n);return n.indexOf(r)}function zne(t,e,n){const r=t/2,a=V1([0,50],[0,r]);return(r-a(e)*n)*n}function Lne(t){return t.slice(0,-1).map((e,n)=>t[n+1]-e)}function Zne(t,e){if(e>0){const n=Lne(t);return Math.min(...n)>=e}return!0}function V1(t,e){return n=>{if(t[0]===t[1]||e[0]===e[1])return e[0];const r=(e[1]-e[0])/(t[1]-t[0]);return e[0]+r*(n-t[0])}}function Vne(t){return(String(t).split(".")[1]||"").length}function Xne(t,e){const n=Math.pow(10,e);return Math.round(t*n)/n}var Bne=nN,Ine=oN,qne=lN,Une=cN;function Yne({className:t,defaultValue:e,value:n,min:r=0,max:i=100,...a}){const o=w.useMemo(()=>Array.isArray(n)?n:Array.isArray(e)?e:[r,i],[n,e,r,i]);return v.jsxs(Bne,{"data-slot":"slider",defaultValue:e,value:n,min:r,max:i,className:Be("relative flex w-full touch-none items-center select-none data-[disabled]:opacity-50 data-[orientation=vertical]:h-full data-[orientation=vertical]:min-h-44 data-[orientation=vertical]:w-auto data-[orientation=vertical]:flex-col",t),...a,children:[v.jsx(Ine,{"data-slot":"slider-track",className:Be("bg-muted relative grow overflow-hidden rounded-full data-[orientation=horizontal]:h-1.5 data-[orientation=horizontal]:w-full data-[orientation=vertical]:h-full data-[orientation=vertical]:w-1.5"),children:v.jsx(qne,{"data-slot":"slider-range",className:Be("bg-primary absolute data-[orientation=horizontal]:h-full data-[orientation=vertical]:w-full")})}),Array.from({length:o.length},(c,u)=>v.jsx(Une,{"data-slot":"slider-thumb",className:"border-primary ring-ring/50 block size-4 shrink-0 rounded-full border bg-white shadow-sm transition-[color,box-shadow] hover:ring-4 focus-visible:ring-4 focus-visible:outline-hidden disabled:pointer-events-none disabled:opacity-50"},u))]})}var X1={};(function t(e,n,r,i){var a=!!(e.Worker&&e.Blob&&e.Promise&&e.OffscreenCanvas&&e.OffscreenCanvasRenderingContext2D&&e.HTMLCanvasElement&&e.HTMLCanvasElement.prototype.transferControlToOffscreen&&e.URL&&e.URL.createObjectURL),o=typeof Path2D=="function"&&typeof DOMMatrix=="function",c=(function(){if(!e.OffscreenCanvas)return!1;try{var X=new OffscreenCanvas(1,1),A=X.getContext("2d");A.fillRect(0,0,1,1);var N=X.transferToImageBitmap();A.createPattern(N,"no-repeat")}catch{return!1}return!0})();function u(){}function f(X){var A=n.exports.Promise,N=A!==void 0?A:e.Promise;return typeof N=="function"?new N(X):(X(u,u),null)}var h=(function(X,A){return{transform:function(N){if(X)return N;if(A.has(N))return A.get(N);var L=new OffscreenCanvas(N.width,N.height),q=L.getContext("2d");return q.drawImage(N,0,0),A.set(N,L),L},clear:function(){A.clear()}}})(c,new Map),m=(function(){var X=Math.floor(16.666666666666668),A,N,L={},q=0;return typeof requestAnimationFrame=="function"&&typeof cancelAnimationFrame=="function"?(A=function(se){var he=Math.random();return L[he]=requestAnimationFrame(function H(ge){q===ge||q+X-1<ge?(q=ge,delete L[he],se()):L[he]=requestAnimationFrame(H)}),he},N=function(se){L[se]&&cancelAnimationFrame(L[se])}):(A=function(se){return setTimeout(se,X)},N=function(se){return clearTimeout(se)}),{frame:A,cancel:N}})(),g=(function(){var X,A,N={};function L(q){function se(he,H){q.postMessage({options:he||{},callback:H})}q.init=function(H){var ge=H.transferControlToOffscreen();q.postMessage({canvas:ge},[ge])},q.fire=function(H,ge,xe){if(A)return se(H,null),A;var ke=Math.random().toString(36).slice(2);return A=f(function(Ce){function Re(We){We.data.callback===ke&&(delete N[ke],q.removeEventListener("message",Re),A=null,h.clear(),xe(),Ce())}q.addEventListener("message",Re),se(H,ke),N[ke]=Re.bind(null,{data:{callback:ke}})}),A},q.reset=function(){q.postMessage({reset:!0});for(var H in N)N[H](),delete N[H]}}return function(){if(X)return X;if(!r&&a){var q=["var CONFETTI, SIZE = {}, module = {};","("+t.toString()+")(this, module, true, SIZE);","onmessage = function(msg) {"," if (msg.data.options) {"," CONFETTI(msg.data.options).then(function () {"," if (msg.data.callback) {"," postMessage({ callback: msg.data.callback });"," }"," });"," } else if (msg.data.reset) {"," CONFETTI && CONFETTI.reset();"," } else if (msg.data.resize) {"," SIZE.width = msg.data.resize.width;"," SIZE.height = msg.data.resize.height;"," } else if (msg.data.canvas) {"," SIZE.width = msg.data.canvas.width;"," SIZE.height = msg.data.canvas.height;"," CONFETTI = module.exports.create(msg.data.canvas);"," }","}"].join(`
|
|
796
|
-
`);try{X=new Worker(URL.createObjectURL(new Blob([q])))}catch(se){return typeof console<"u"&&typeof console.warn=="function"&&console.warn("🎊 Could not load worker",se),null}L(X)}return X}})(),y={particleCount:50,angle:90,spread:45,startVelocity:45,decay:.9,gravity:1,drift:0,ticks:200,x:.5,y:.5,shapes:["square","circle"],zIndex:100,colors:["#26ccff","#a25afd","#ff5e7e","#88ff5a","#fcff42","#ffa62d","#ff36ff"],disableForReducedMotion:!1,scalar:1};function x(X,A){return A?A(X):X}function S(X){return X!=null}function k(X,A,N){return x(X&&S(X[A])?X[A]:y[A],N)}function T(X){return X<0?0:Math.floor(X)}function C(X,A){return Math.floor(Math.random()*(A-X))+X}function E(X){return parseInt(X,16)}function R(X){return X.map($)}function $(X){var A=String(X).replace(/[^0-9a-f]/gi,"");return A.length<6&&(A=A[0]+A[0]+A[1]+A[1]+A[2]+A[2]),{r:E(A.substring(0,2)),g:E(A.substring(2,4)),b:E(A.substring(4,6))}}function P(X){var A=k(X,"origin",Object);return A.x=k(A,"x",Number),A.y=k(A,"y",Number),A}function _(X){X.width=document.documentElement.clientWidth,X.height=document.documentElement.clientHeight}function M(X){var A=X.getBoundingClientRect();X.width=A.width,X.height=A.height}function V(X){var A=document.createElement("canvas");return A.style.position="fixed",A.style.top="0px",A.style.left="0px",A.style.pointerEvents="none",A.style.zIndex=X,A}function F(X,A,N,L,q,se,he,H,ge){X.save(),X.translate(A,N),X.rotate(se),X.scale(L,q),X.arc(0,0,1,he,H,ge),X.restore()}function W(X){var A=X.angle*(Math.PI/180),N=X.spread*(Math.PI/180);return{x:X.x,y:X.y,wobble:Math.random()*10,wobbleSpeed:Math.min(.11,Math.random()*.1+.05),velocity:X.startVelocity*.5+Math.random()*X.startVelocity,angle2D:-A+(.5*N-Math.random()*N),tiltAngle:(Math.random()*(.75-.25)+.25)*Math.PI,color:X.color,shape:X.shape,tick:0,totalTicks:X.ticks,decay:X.decay,drift:X.drift,random:Math.random()+2,tiltSin:0,tiltCos:0,wobbleX:0,wobbleY:0,gravity:X.gravity*3,ovalScalar:.6,scalar:X.scalar,flat:X.flat}}function I(X,A){A.x+=Math.cos(A.angle2D)*A.velocity+A.drift,A.y+=Math.sin(A.angle2D)*A.velocity+A.gravity,A.velocity*=A.decay,A.flat?(A.wobble=0,A.wobbleX=A.x+10*A.scalar,A.wobbleY=A.y+10*A.scalar,A.tiltSin=0,A.tiltCos=0,A.random=1):(A.wobble+=A.wobbleSpeed,A.wobbleX=A.x+10*A.scalar*Math.cos(A.wobble),A.wobbleY=A.y+10*A.scalar*Math.sin(A.wobble),A.tiltAngle+=.1,A.tiltSin=Math.sin(A.tiltAngle),A.tiltCos=Math.cos(A.tiltAngle),A.random=Math.random()+2);var N=A.tick++/A.totalTicks,L=A.x+A.random*A.tiltCos,q=A.y+A.random*A.tiltSin,se=A.wobbleX+A.random*A.tiltCos,he=A.wobbleY+A.random*A.tiltSin;if(X.fillStyle="rgba("+A.color.r+", "+A.color.g+", "+A.color.b+", "+(1-N)+")",X.beginPath(),o&&A.shape.type==="path"&&typeof A.shape.path=="string"&&Array.isArray(A.shape.matrix))X.fill(G(A.shape.path,A.shape.matrix,A.x,A.y,Math.abs(se-L)*.1,Math.abs(he-q)*.1,Math.PI/10*A.wobble));else if(A.shape.type==="bitmap"){var H=Math.PI/10*A.wobble,ge=Math.abs(se-L)*.1,xe=Math.abs(he-q)*.1,ke=A.shape.bitmap.width*A.scalar,Ce=A.shape.bitmap.height*A.scalar,Re=new DOMMatrix([Math.cos(H)*ge,Math.sin(H)*ge,-Math.sin(H)*xe,Math.cos(H)*xe,A.x,A.y]);Re.multiplySelf(new DOMMatrix(A.shape.matrix));var We=X.createPattern(h.transform(A.shape.bitmap),"no-repeat");We.setTransform(Re),X.globalAlpha=1-N,X.fillStyle=We,X.fillRect(A.x-ke/2,A.y-Ce/2,ke,Ce),X.globalAlpha=1}else if(A.shape==="circle")X.ellipse?X.ellipse(A.x,A.y,Math.abs(se-L)*A.ovalScalar,Math.abs(he-q)*A.ovalScalar,Math.PI/10*A.wobble,0,2*Math.PI):F(X,A.x,A.y,Math.abs(se-L)*A.ovalScalar,Math.abs(he-q)*A.ovalScalar,Math.PI/10*A.wobble,0,2*Math.PI);else if(A.shape==="star")for(var Pe=Math.PI/2*3,ht=4*A.scalar,Ke=8*A.scalar,tt=A.x,bt=A.y,Ue=5,Ge=Math.PI/Ue;Ue--;)tt=A.x+Math.cos(Pe)*Ke,bt=A.y+Math.sin(Pe)*Ke,X.lineTo(tt,bt),Pe+=Ge,tt=A.x+Math.cos(Pe)*ht,bt=A.y+Math.sin(Pe)*ht,X.lineTo(tt,bt),Pe+=Ge;else X.moveTo(Math.floor(A.x),Math.floor(A.y)),X.lineTo(Math.floor(A.wobbleX),Math.floor(q)),X.lineTo(Math.floor(se),Math.floor(he)),X.lineTo(Math.floor(L),Math.floor(A.wobbleY));return X.closePath(),X.fill(),A.tick<A.totalTicks}function ne(X,A,N,L,q){var se=A.slice(),he=X.getContext("2d"),H,ge,xe=f(function(ke){function Ce(){H=ge=null,he.clearRect(0,0,L.width,L.height),h.clear(),q(),ke()}function Re(){r&&!(L.width===i.width&&L.height===i.height)&&(L.width=X.width=i.width,L.height=X.height=i.height),!L.width&&!L.height&&(N(X),L.width=X.width,L.height=X.height),he.clearRect(0,0,L.width,L.height),se=se.filter(function(We){return I(he,We)}),se.length?H=m.frame(Re):Ce()}H=m.frame(Re),ge=Ce});return{addFettis:function(ke){return se=se.concat(ke),xe},canvas:X,promise:xe,reset:function(){H&&m.cancel(H),ge&&ge()}}}function ee(X,A){var N=!X,L=!!k(A||{},"resize"),q=!1,se=k(A,"disableForReducedMotion",Boolean),he=a&&!!k(A||{},"useWorker"),H=he?g():null,ge=N?_:M,xe=X&&H?!!X.__confetti_initialized:!1,ke=typeof matchMedia=="function"&&matchMedia("(prefers-reduced-motion)").matches,Ce;function Re(Pe,ht,Ke){for(var tt=k(Pe,"particleCount",T),bt=k(Pe,"angle",Number),Ue=k(Pe,"spread",Number),Ge=k(Pe,"startVelocity",Number),z=k(Pe,"decay",Number),Y=k(Pe,"gravity",Number),oe=k(Pe,"drift",Number),te=k(Pe,"colors",R),fe=k(Pe,"ticks",Number),Oe=k(Pe,"shapes"),Te=k(Pe,"scalar"),Ye=!!k(Pe,"flat"),ot=P(Pe),kt=tt,Dn=[],Kt=X.width*ot.x,er=X.height*ot.y;kt--;)Dn.push(W({x:Kt,y:er,angle:bt,spread:Ue,startVelocity:Ge,color:te[kt%te.length],shape:Oe[C(0,Oe.length)],ticks:fe,decay:z,gravity:Y,drift:oe,scalar:Te,flat:Ye}));return Ce?Ce.addFettis(Dn):(Ce=ne(X,Dn,ge,ht,Ke),Ce.promise)}function We(Pe){var ht=se||k(Pe,"disableForReducedMotion",Boolean),Ke=k(Pe,"zIndex",Number);if(ht&&ke)return f(function(Ge){Ge()});N&&Ce?X=Ce.canvas:N&&!X&&(X=V(Ke),document.body.appendChild(X)),L&&!xe&&ge(X);var tt={width:X.width,height:X.height};H&&!xe&&H.init(X),xe=!0,H&&(X.__confetti_initialized=!0);function bt(){if(H){var Ge={getBoundingClientRect:function(){if(!N)return X.getBoundingClientRect()}};ge(Ge),H.postMessage({resize:{width:Ge.width,height:Ge.height}});return}tt.width=tt.height=null}function Ue(){Ce=null,L&&(q=!1,e.removeEventListener("resize",bt)),N&&X&&(document.body.contains(X)&&document.body.removeChild(X),X=null,xe=!1)}return L&&!q&&(q=!0,e.addEventListener("resize",bt,!1)),H?H.fire(Pe,tt,Ue):Re(Pe,tt,Ue)}return We.reset=function(){H&&H.reset(),Ce&&Ce.reset()},We}var pe;function D(){return pe||(pe=ee(null,{useWorker:!0,resize:!0})),pe}function G(X,A,N,L,q,se,he){var H=new Path2D(X),ge=new Path2D;ge.addPath(H,new DOMMatrix(A));var xe=new Path2D;return xe.addPath(ge,new DOMMatrix([Math.cos(he)*q,Math.sin(he)*q,-Math.sin(he)*se,Math.cos(he)*se,N,L])),xe}function B(X){if(!o)throw new Error("path confetti are not supported in this browser");var A,N;typeof X=="string"?A=X:(A=X.path,N=X.matrix);var L=new Path2D(A),q=document.createElement("canvas"),se=q.getContext("2d");if(!N){for(var he=1e3,H=he,ge=he,xe=0,ke=0,Ce,Re,We=0;We<he;We+=2)for(var Pe=0;Pe<he;Pe+=2)se.isPointInPath(L,We,Pe,"nonzero")&&(H=Math.min(H,We),ge=Math.min(ge,Pe),xe=Math.max(xe,We),ke=Math.max(ke,Pe));Ce=xe-H,Re=ke-ge;var ht=10,Ke=Math.min(ht/Ce,ht/Re);N=[Ke,0,0,Ke,-Math.round(Ce/2+H)*Ke,-Math.round(Re/2+ge)*Ke]}return{type:"path",path:A,matrix:N}}function ye(X){var A,N=1,L="#000000",q='"Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji", "EmojiOne Color", "Android Emoji", "Twemoji Mozilla", "system emoji", sans-serif';typeof X=="string"?A=X:(A=X.text,N="scalar"in X?X.scalar:N,q="fontFamily"in X?X.fontFamily:q,L="color"in X?X.color:L);var se=10*N,he=""+se+"px "+q,H=new OffscreenCanvas(se,se),ge=H.getContext("2d");ge.font=he;var xe=ge.measureText(A),ke=Math.ceil(xe.actualBoundingBoxRight+xe.actualBoundingBoxLeft),Ce=Math.ceil(xe.actualBoundingBoxAscent+xe.actualBoundingBoxDescent),Re=2,We=xe.actualBoundingBoxLeft+Re,Pe=xe.actualBoundingBoxAscent+Re;ke+=Re+Re,Ce+=Re+Re,H=new OffscreenCanvas(ke,Ce),ge=H.getContext("2d"),ge.font=he,ge.fillStyle=L,ge.fillText(A,We,Pe);var ht=1/N;return{type:"bitmap",bitmap:H.transferToImageBitmap(),matrix:[ht,0,0,ht,-ke*ht/2,-Ce*ht/2]}}n.exports=function(){return D().apply(this,arguments)},n.exports.reset=function(){D().reset()},n.exports.create=ee,n.exports.shapeFromPath=B,n.exports.shapeFromText=ye})((function(){return typeof window<"u"?window:typeof self<"u"?self:this||{}})(),X1,!1);const Fne=X1.exports;X1.exports.create;function Wne(){const{iconKey:t}=YA(),e=Ho(),{data:n,isPending:r,error:i}=DR(t||""),{setColorPickerHint:a}=jm(),[o,c]=w.useState([50]),u=w.useRef(!1),f=w.useRef(null);if(w.useEffect(()=>{if(!u.current&&f.current&&n){const y=f.current.getBoundingClientRect(),x=(y.left+y.right)/2/window.innerWidth,S=(y.top+y.bottom)/2/window.innerHeight;Fne({particleCount:100,spread:70,origin:{x,y:S}}),u.current=!0}return a("Look how this icon perfectly responds when you change the text color"),()=>{a(null)}},[a,n]),r)return v.jsx("div",{className:"flex h-[calc(100vh-4rem)] items-center justify-center",children:v.jsx("div",{className:"text-muted-foreground",children:"Loading icon..."})});if(i||!n)return v.jsx("div",{className:"flex h-[calc(100vh-4rem)] items-center justify-center",children:v.jsxs("div",{className:"flex flex-col items-center gap-4",children:[v.jsx("div",{className:"text-destructive",children:"Icon not found"}),v.jsx(Rt,{onClick:()=>e("/"),variant:"outline",children:"Go Home"})]})});const{pascalName:h,svgContent:m,icon:g}=n;return v.jsxs("div",{className:"flex h-[calc(100vh-4rem)] flex-col gap-6 p-6",children:[v.jsxs("div",{className:"grid grid-cols-[1fr_450px] h-full gap-6",children:[v.jsx("div",{className:"flex-1 overflow-hidden rounded-xl border bg-gradient-to-br from-card to-card/50 p-12 shadow-sm",children:v.jsxs("div",{className:"flex h-full flex-col items-center justify-center gap-6 relative",children:[v.jsxs("div",{className:"absolute top-0 left-0 w-full h-full flex flex-col items-center gap-4 text-center",children:[v.jsxs("div",{className:"flex items-center gap-2 text-sm font-medium text-muted-foreground",children:[v.jsx("span",{children:"Look how it respects the font size perfectly here"}),v.jsx(RV,{className:"size-4"})]}),v.jsxs("div",{className:"flex w-full max-w-lg flex-col gap-3",children:[v.jsx(Yne,{value:o,onValueChange:c,min:5,max:300,step:1,className:"w-full"}),v.jsxs("div",{className:"text-center text-sm font-medium text-foreground",children:[o[0],"px"]})]})]}),v.jsx("div",{className:"flex items-center justify-center transition-all duration-300 ease-out",ref:f,children:v.jsx(nc,{content:m,className:"h-full w-full",style:{width:`${o[0]}px`,height:`${o[0]}px`,maxWidth:"500px",maxHeight:"500px"}})})]})}),v.jsx(d_,{iconKey:t||"",pascalName:h,svgContent:m,colorVariableKeys:g.colorVariableKeys})]}),v.jsx("div",{className:"flex justify-end",children:v.jsx(Rt,{onClick:()=>e("/"),size:"lg",className:"min-w-24",children:"Back to home"})})]})}function Gne(){const{iconKey:t}=YA(),e=Ho(),{data:n,isPending:r,error:i}=DR(t||""),[a,o]=w.useState(""),[c,u]=w.useState(!1);w.useEffect(()=>{n&&o(n.svgContent)},[n]);const f=w.useMemo(()=>{if(n)return{name:n.icon.name,tags:n.icon.tags,svgContent:n.svgContent,colorVariableKeys:n.icon.colorVariableKeys||[]}},[n]),h=w.useMemo(()=>{if(!a||a.trim().length===0)return!1;try{return!new DOMParser().parseFromString(a,"image/svg+xml").querySelector("parsererror")}catch{return!1}},[a]),m=g=>{e(`/icons/${g}/preview`)};return r?v.jsx("div",{className:"flex h-[calc(100vh-4rem)] items-center justify-center",children:v.jsx("div",{className:"text-muted-foreground",children:"Loading icon..."})}):i||!n?v.jsx("div",{className:"flex h-[calc(100vh-4rem)] items-center justify-center",children:v.jsxs("div",{className:"flex flex-col items-center gap-4",children:[v.jsx("div",{className:"text-destructive",children:"Icon not found"}),v.jsx(Rt,{onClick:()=>e("/"),variant:"outline",children:"Go Home"})]})}):v.jsxs("div",{className:"flex h-[calc(100vh-4rem)] flex-col gap-4 p-4",children:[v.jsxs("div",{className:"flex flex-1 gap-4 overflow-hidden",children:[v.jsx("div",{className:"flex-1 overflow-hidden rounded-lg border",children:v.jsx(uM,{value:a,onChange:o})}),v.jsx("div",{className:"flex-1 overflow-hidden rounded-lg border",children:v.jsxs("div",{className:"flex h-full w-full items-center justify-center bg-muted/30 p-8 relative",children:[v.jsxs("div",{className:"absolute top-4 left-4 max-w-xs flex flex-col gap-2",children:[v.jsx("p",{className:"text-sm font-medium text-foreground",children:"Your SVG preview"}),v.jsx("p",{className:"text-sm text-muted-foreground",children:"Edit the SVG content and update the icon properties. The name cannot be changed."})]}),v.jsx(nc,{content:a,className:"h-[50%] w-[50%] flex flex-col items-center justify-center"})]})})]}),v.jsx("div",{className:"flex justify-end",children:v.jsx(Rt,{onClick:()=>u(!0),disabled:!h,size:"lg",children:"Update Icon"})}),v.jsx(HM,{open:c,onOpenChange:u,svgContent:a,onSuccess:m,mode:"edit",initialData:f})]})}function Hne(){return Yd({queryKey:["pwd"],queryFn:()=>Mt.get("/api/pwd").then(t=>t.data)})}function Kne(){const{data:t}=Hne();return v.jsxs("footer",{className:"flex items-center justify-center flex-col gap-2 py-4 w-full border-t",children:[v.jsxs("p",{className:"text-sm text-muted-foreground",children:["Iconoma Studio is working on ",t?.pwd]}),v.jsxs("div",{className:"flex items-center justify-center gap-4",children:[v.jsx(No,{to:"https://iconoma.org",target:"_blank",rel:"noopener noreferrer",className:"hover:opacity-80 transition-opacity",children:v.jsx("img",{src:"/icon.png",alt:"Iconoma Logo",className:"w-6 h-6"})}),v.jsx(No,{to:"https://github.com/theryston/iconoma",target:"_blank",rel:"noopener noreferrer",className:"hover:opacity-80 transition-opacity w-6 h-6 p-1 bg-primary rounded-full text-primary-foreground",children:v.jsx(GV,{className:"w-full h-full"})})]})]})}const Od=[{id:"react",name:"React",icon:qV,extension:[".tsx",".jsx"]},{id:"react-native",name:"React Native",icon:m8,extension:[".tsx",".jsx"]}],fN=Rp({svg:Rp({folder:ra().nullable(),inLock:tne()}).transform(t=>({folder:t.inLock?null:t.folder??null,inLock:t.inLock})).superRefine((t,e)=>{!t.inLock&&!t.folder&&e.addIssue({code:we.custom,message:"When SVG in lock is disabled, a SVG folder must be provided",path:["folder"]})}),svgo:ra().min(1),extraTargets:Ub(Rp({targetId:ra(),outputPath:ra().min(1)})).default([]),colorVariables:Ub(ra()).default([])}),Jne=fN.extend({svgo:ra().min(1).transform(t=>{try{return JSON.parse(t)}catch{return}}).superRefine((t,e)=>{if(t===void 0){e.addIssue({code:we.custom,message:"SVGO config must be valid JSON",path:e.path});return}if(typeof t!="object"||t===null){e.addIssue({code:we.custom,message:"SVGO config must be an object",path:e.path});return}const n=t.plugins;if(!n.every(i=>typeof i=="string"||typeof i=="object"&&i!==null&&typeof i.name=="string"&&"params"in i)){e.addIssue({code:we.custom,message:'SVGO "plugins" must be an array of strings or objects {name: string, params: any}',path:e.path});return}if(Array.isArray(n)){const i=n.find(a=>typeof a=="object"&&a!==null&&a.name==="convertColors"&&a.params&&typeof a.params=="object");i&&i.params.currentColor===!0&&e.addIssue({code:we.custom,message:"Please set convertColors.params.currentColor to false, as Iconoma will convert colors using the configured color variables.",path:e.path})}}),colorVariables:Ub(ra()).default([]).transform(t=>t.filter(e=>e.trim().length>0))}).superRefine((t,e)=>{t.svg.inLock&&t.extraTargets.length===0&&e.addIssue({code:we.custom,message:"At least one extra target is required when SVG in Lock is enabled",path:["extraTargets"]}),t.extraTargets.forEach((n,r)=>{const i=Od.find(a=>a.id===n.targetId);if(!i){e.addIssue({code:we.custom,message:`Invalid target ID: ${n.targetId}`,path:["extraTargets",r,"targetId"]});return}if(!qre(n.outputPath,i.extension)){const a=i.extension.join(", ");e.addIssue({code:we.custom,message:`Output path must end with one of: ${a} for ${i.name}`,path:["extraTargets",r,"outputPath"]})}})});var wg="Collapsible",[ere,hN]=pa(wg),[tre,B1]=ere(wg),pN=w.forwardRef((t,e)=>{const{__scopeCollapsible:n,open:r,defaultOpen:i,disabled:a,onOpenChange:o,...c}=t,[u,f]=Ga({prop:r,defaultProp:i??!1,onChange:o,caller:wg});return v.jsx(tre,{scope:n,disabled:a,contentId:Ba(),open:u,onOpenToggle:w.useCallback(()=>f(h=>!h),[f]),children:v.jsx(et.div,{"data-state":q1(u),"data-disabled":a?"":void 0,...c,ref:e})})});pN.displayName=wg;var mN="CollapsibleTrigger",gN=w.forwardRef((t,e)=>{const{__scopeCollapsible:n,...r}=t,i=B1(mN,n);return v.jsx(et.button,{type:"button","aria-controls":i.contentId,"aria-expanded":i.open||!1,"data-state":q1(i.open),"data-disabled":i.disabled?"":void 0,disabled:i.disabled,...r,ref:e,onClick:He(t.onClick,i.onOpenToggle)})});gN.displayName=mN;var I1="CollapsibleContent",ON=w.forwardRef((t,e)=>{const{forceMount:n,...r}=t,i=B1(I1,t.__scopeCollapsible);return v.jsx(fi,{present:n||i.open,children:({present:a})=>v.jsx(nre,{...r,ref:e,present:a})})});ON.displayName=I1;var nre=w.forwardRef((t,e)=>{const{__scopeCollapsible:n,present:r,children:i,...a}=t,o=B1(I1,n),[c,u]=w.useState(r),f=w.useRef(null),h=ft(e,f),m=w.useRef(0),g=m.current,y=w.useRef(0),x=y.current,S=o.open||c,k=w.useRef(S),T=w.useRef(void 0);return w.useEffect(()=>{const C=requestAnimationFrame(()=>k.current=!1);return()=>cancelAnimationFrame(C)},[]),jn(()=>{const C=f.current;if(C){T.current=T.current||{transitionDuration:C.style.transitionDuration,animationName:C.style.animationName},C.style.transitionDuration="0s",C.style.animationName="none";const E=C.getBoundingClientRect();m.current=E.height,y.current=E.width,k.current||(C.style.transitionDuration=T.current.transitionDuration,C.style.animationName=T.current.animationName),u(r)}},[o.open,r]),v.jsx(et.div,{"data-state":q1(o.open),"data-disabled":o.disabled?"":void 0,id:o.contentId,hidden:!S,...a,ref:h,style:{"--radix-collapsible-content-height":g?`${g}px`:void 0,"--radix-collapsible-content-width":x?`${x}px`:void 0,...t.style},children:S&&i})});function q1(t){return t?"open":"closed"}var rre=pN,ire=gN,are=ON,Li="Accordion",sre=["Home","End","ArrowDown","ArrowUp","ArrowLeft","ArrowRight"],[U1,ore,lre]=bx(Li),[kg]=pa(Li,[lre,hN]),Y1=hN(),vN=le.forwardRef((t,e)=>{const{type:n,...r}=t,i=r,a=r;return v.jsx(U1.Provider,{scope:t.__scopeAccordion,children:n==="multiple"?v.jsx(fre,{...a,ref:e}):v.jsx(dre,{...i,ref:e})})});vN.displayName=Li;var[yN,cre]=kg(Li),[bN,ure]=kg(Li,{collapsible:!1}),dre=le.forwardRef((t,e)=>{const{value:n,defaultValue:r,onValueChange:i=()=>{},collapsible:a=!1,...o}=t,[c,u]=Ga({prop:n,defaultProp:r??"",onChange:i,caller:Li});return v.jsx(yN,{scope:t.__scopeAccordion,value:le.useMemo(()=>c?[c]:[],[c]),onItemOpen:u,onItemClose:le.useCallback(()=>a&&u(""),[a,u]),children:v.jsx(bN,{scope:t.__scopeAccordion,collapsible:a,children:v.jsx(xN,{...o,ref:e})})})}),fre=le.forwardRef((t,e)=>{const{value:n,defaultValue:r,onValueChange:i=()=>{},...a}=t,[o,c]=Ga({prop:n,defaultProp:r??[],onChange:i,caller:Li}),u=le.useCallback(h=>c((m=[])=>[...m,h]),[c]),f=le.useCallback(h=>c((m=[])=>m.filter(g=>g!==h)),[c]);return v.jsx(yN,{scope:t.__scopeAccordion,value:o,onItemOpen:u,onItemClose:f,children:v.jsx(bN,{scope:t.__scopeAccordion,collapsible:!0,children:v.jsx(xN,{...a,ref:e})})})}),[hre,Cg]=kg(Li),xN=le.forwardRef((t,e)=>{const{__scopeAccordion:n,disabled:r,dir:i,orientation:a="vertical",...o}=t,c=le.useRef(null),u=ft(c,e),f=ore(n),m=Nm(i)==="ltr",g=He(t.onKeyDown,y=>{if(!sre.includes(y.key))return;const x=y.target,S=f().filter(M=>!M.ref.current?.disabled),k=S.findIndex(M=>M.ref.current===x),T=S.length;if(k===-1)return;y.preventDefault();let C=k;const E=0,R=T-1,$=()=>{C=k+1,C>R&&(C=E)},P=()=>{C=k-1,C<E&&(C=R)};switch(y.key){case"Home":C=E;break;case"End":C=R;break;case"ArrowRight":a==="horizontal"&&(m?$():P());break;case"ArrowDown":a==="vertical"&&$();break;case"ArrowLeft":a==="horizontal"&&(m?P():$());break;case"ArrowUp":a==="vertical"&&P();break}const _=C%T;S[_].ref.current?.focus()});return v.jsx(hre,{scope:n,disabled:r,direction:i,orientation:a,children:v.jsx(U1.Slot,{scope:n,children:v.jsx(et.div,{...o,"data-orientation":a,ref:u,onKeyDown:r?void 0:g})})})}),Sm="AccordionItem",[pre,F1]=kg(Sm),SN=le.forwardRef((t,e)=>{const{__scopeAccordion:n,value:r,...i}=t,a=Cg(Sm,n),o=cre(Sm,n),c=Y1(n),u=Ba(),f=r&&o.value.includes(r)||!1,h=a.disabled||t.disabled;return v.jsx(pre,{scope:n,open:f,disabled:h,triggerId:u,children:v.jsx(rre,{"data-orientation":a.orientation,"data-state":QN(f),...c,...i,ref:e,disabled:h,open:f,onOpenChange:m=>{m?o.onItemOpen(r):o.onItemClose(r)}})})});SN.displayName=Sm;var wN="AccordionHeader",kN=le.forwardRef((t,e)=>{const{__scopeAccordion:n,...r}=t,i=Cg(Li,n),a=F1(wN,n);return v.jsx(et.h3,{"data-orientation":i.orientation,"data-state":QN(a.open),"data-disabled":a.disabled?"":void 0,...r,ref:e})});kN.displayName=wN;var Gb="AccordionTrigger",CN=le.forwardRef((t,e)=>{const{__scopeAccordion:n,...r}=t,i=Cg(Li,n),a=F1(Gb,n),o=ure(Gb,n),c=Y1(n);return v.jsx(U1.ItemSlot,{scope:n,children:v.jsx(ire,{"aria-disabled":a.open&&!o.collapsible||void 0,"data-orientation":i.orientation,id:a.triggerId,...c,...r,ref:e})})});CN.displayName=Gb;var TN="AccordionContent",EN=le.forwardRef((t,e)=>{const{__scopeAccordion:n,...r}=t,i=Cg(Li,n),a=F1(TN,n),o=Y1(n);return v.jsx(are,{role:"region","aria-labelledby":a.triggerId,"data-orientation":i.orientation,...o,...r,ref:e,style:{"--radix-accordion-content-height":"var(--radix-collapsible-content-height)","--radix-accordion-content-width":"var(--radix-collapsible-content-width)",...t.style}})});EN.displayName=TN;function QN(t){return t?"open":"closed"}var mre=vN,gre=SN,Ore=kN,vre=CN,yre=EN;function bre({...t}){return v.jsx(mre,{"data-slot":"accordion",...t})}function xre({className:t,...e}){return v.jsx(gre,{"data-slot":"accordion-item",className:Be("border-b last:border-b-0",t),...e})}function Sre({className:t,children:e,...n}){return v.jsx(Ore,{className:"flex",children:v.jsxs(vre,{"data-slot":"accordion-trigger",className:Be("focus-visible:border-ring focus-visible:ring-ring/50 flex flex-1 items-start justify-between gap-4 rounded-md py-4 text-left text-sm font-medium transition-all outline-none hover:underline focus-visible:ring-[3px] disabled:pointer-events-none disabled:opacity-50 [&[data-state=open]>svg]:rotate-180",t),...n,children:[e,v.jsx(Jd,{className:"text-muted-foreground pointer-events-none size-4 shrink-0 translate-y-0.5 transition-transform duration-200"})]})})}function wre({className:t,children:e,...n}){return v.jsx(yre,{"data-slot":"accordion-content",className:"data-[state=closed]:animate-accordion-up data-[state=open]:animate-accordion-down overflow-hidden text-sm",...n,children:v.jsx("div",{className:Be("pt-0 pb-4",t),children:e})})}var Tg="Checkbox",[kre]=pa(Tg),[Cre,W1]=kre(Tg);function Tre(t){const{__scopeCheckbox:e,checked:n,children:r,defaultChecked:i,disabled:a,form:o,name:c,onCheckedChange:u,required:f,value:h="on",internal_do_not_use_render:m}=t,[g,y]=Ga({prop:n,defaultProp:i??!1,onChange:u,caller:Tg}),[x,S]=w.useState(null),[k,T]=w.useState(null),C=w.useRef(!1),E=x?!!o||!!x.closest("form"):!0,R={checked:g,disabled:a,setChecked:y,control:x,setControl:S,name:c,form:o,value:h,hasConsumerStoppedPropagationRef:C,required:f,defaultChecked:Zs(i)?!1:i,isFormControl:E,bubbleInput:k,setBubbleInput:T};return v.jsx(Cre,{scope:e,...R,children:Ere(m)?m(R):r})}var AN="CheckboxTrigger",RN=w.forwardRef(({__scopeCheckbox:t,onKeyDown:e,onClick:n,...r},i)=>{const{control:a,value:o,disabled:c,checked:u,required:f,setControl:h,setChecked:m,hasConsumerStoppedPropagationRef:g,isFormControl:y,bubbleInput:x}=W1(AN,t),S=ft(i,h),k=w.useRef(u);return w.useEffect(()=>{const T=a?.form;if(T){const C=()=>m(k.current);return T.addEventListener("reset",C),()=>T.removeEventListener("reset",C)}},[a,m]),v.jsx(et.button,{type:"button",role:"checkbox","aria-checked":Zs(u)?"mixed":u,"aria-required":f,"data-state":NN(u),"data-disabled":c?"":void 0,disabled:c,value:o,...r,ref:S,onKeyDown:He(e,T=>{T.key==="Enter"&&T.preventDefault()}),onClick:He(n,T=>{m(C=>Zs(C)?!0:!C),x&&y&&(g.current=T.isPropagationStopped(),g.current||T.stopPropagation())})})});RN.displayName=AN;var _N=w.forwardRef((t,e)=>{const{__scopeCheckbox:n,name:r,checked:i,defaultChecked:a,required:o,disabled:c,value:u,onCheckedChange:f,form:h,...m}=t;return v.jsx(Tre,{__scopeCheckbox:n,checked:i,defaultChecked:a,disabled:c,required:o,onCheckedChange:f,name:r,form:h,value:u,internal_do_not_use_render:({isFormControl:g})=>v.jsxs(v.Fragment,{children:[v.jsx(RN,{...m,ref:e,__scopeCheckbox:n}),g&&v.jsx(MN,{__scopeCheckbox:n})]})})});_N.displayName=Tg;var $N="CheckboxIndicator",PN=w.forwardRef((t,e)=>{const{__scopeCheckbox:n,forceMount:r,...i}=t,a=W1($N,n);return v.jsx(fi,{present:r||Zs(a.checked)||a.checked===!0,children:v.jsx(et.span,{"data-state":NN(a.checked),"data-disabled":a.disabled?"":void 0,...i,ref:e,style:{pointerEvents:"none",...t.style}})})});PN.displayName=$N;var jN="CheckboxBubbleInput",MN=w.forwardRef(({__scopeCheckbox:t,...e},n)=>{const{control:r,hasConsumerStoppedPropagationRef:i,checked:a,defaultChecked:o,required:c,disabled:u,name:f,value:h,form:m,bubbleInput:g,setBubbleInput:y}=W1(jN,t),x=ft(n,y),S=$x(a),k=Qx(r);w.useEffect(()=>{const C=g;if(!C)return;const E=window.HTMLInputElement.prototype,$=Object.getOwnPropertyDescriptor(E,"checked").set,P=!i.current;if(S!==a&&$){const _=new Event("click",{bubbles:P});C.indeterminate=Zs(a),$.call(C,Zs(a)?!1:a),C.dispatchEvent(_)}},[g,S,a,i]);const T=w.useRef(Zs(a)?!1:a);return v.jsx(et.input,{type:"checkbox","aria-hidden":!0,defaultChecked:o??T.current,required:c,disabled:u,name:f,value:h,form:m,...e,tabIndex:-1,ref:x,style:{...e.style,...k,position:"absolute",pointerEvents:"none",opacity:0,margin:0,transform:"translateX(-100%)"}})});MN.displayName=jN;function Ere(t){return typeof t=="function"}function Zs(t){return t==="indeterminate"}function NN(t){return Zs(t)?"indeterminate":t?"checked":"unchecked"}function Qre({className:t,...e}){return v.jsx(_N,{"data-slot":"checkbox",className:Be("peer border-input dark:bg-input/30 data-[state=checked]:bg-primary data-[state=checked]:text-primary-foreground dark:data-[state=checked]:bg-primary data-[state=checked]:border-primary focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive size-4 shrink-0 rounded-[4px] border shadow-xs transition-shadow outline-none focus-visible:ring-[3px] disabled:cursor-not-allowed disabled:opacity-50",t),...e,children:v.jsx(PN,{"data-slot":"checkbox-indicator",className:"grid place-content-center text-current transition-none",children:v.jsx(rc,{className:"size-3.5"})})})}function Are({form:t,onNextStep:e,onComplete:n}){const[r,i]=w.useState([]),a=w.useRef(null),o=A6(),c=Ox(),u=t.handleSubmit(async f=>{const h=Jne.safeParse(f);if(!h.success){h.error.errors.forEach(g=>{const y=g.path[0];t.setError(y,{message:g.message})});return}const m=h.data;try{const y=(await o.mutateAsync(m))?.changes||[];y.length===0?(await c.mutateAsync({config:m,changes:[]}),bn.success("Configuration saved successfully"),n()):e(y,m)}catch{}});return v.jsxs("form",{ref:a,onSubmit:u,className:"flex flex-col gap-4",children:[v.jsx(ff,{className:"max-h-[60vh]",children:v.jsxs("div",{className:"flex flex-col gap-4",children:[!t.watch("svg.inLock")&&v.jsx(pd,{name:"svg.folder",control:t.control,render:({field:f,fieldState:h})=>v.jsxs(Ls,{children:[v.jsx(fc,{children:"SVG Folder"}),v.jsx(Ci,{placeholder:"e.g. ./icons",value:f.value??"",onChange:f.onChange}),h.invalid&&v.jsx(Ua,{errors:[h.error]})]})}),v.jsx(pd,{name:"svg.inLock",control:t.control,render:({field:f,fieldState:h})=>v.jsxs(Ls,{children:[v.jsxs(MM,{className:"flex items-start gap-3 rounded-lg border p-3",children:[v.jsx(Qre,{checked:f.value,onCheckedChange:m=>{f.onChange(m),t.setValue("svg.folder",null,{shouldValidate:!0}),t.clearErrors("extraTargets")}}),v.jsxs("div",{className:"grid gap-1.5 font-normal",children:[v.jsx("p",{className:"text-sm leading-none",children:"SVG in Lock (NOT RECOMMENDED)"}),v.jsx("p",{className:"text-muted-foreground text-xs",children:"When enabled, the SVG will not be exported to a folder, it will be included in the iconoma.lock.json file"})]})]}),h.invalid&&v.jsx(Ua,{errors:[h.error]})]})}),v.jsx($re,{form:t}),v.jsx(Pre,{form:t}),v.jsx(bre,{type:"multiple",value:r,onValueChange:i,children:v.jsx(pd,{name:"svgo",control:t.control,render:({field:f,fieldState:h})=>v.jsxs(xre,{value:"svgo",children:[v.jsx(Sre,{className:Be(h.error&&"text-destructive"),children:"SVGO Config"}),v.jsx(wre,{children:v.jsxs(Ls,{children:[v.jsx(Rre,{onConfigChange:f.onChange,value:f.value,onSubmit:u}),h.invalid&&v.jsx(Ua,{errors:[h.error]})]})})]})})})]})}),v.jsxs("div",{className:"flex justify-end gap-2 pt-2",children:[v.jsx(Rt,{type:"button",variant:"outline",onClick:()=>n(),children:"Cancel"}),v.jsx(Rt,{type:"submit",disabled:t.formState.isSubmitting||o.isPending,children:o.isPending?"Checking changes...":t.formState.isSubmitting?"Saving...":"Continue"})]})]})}function Rre({onConfigChange:t,value:e,onSubmit:n}){const{theme:r}=PA();return v.jsx("div",{className:"h-full w-full overflow-hidden",children:v.jsx(F5,{theme:r==="system"?"auto":r,files:{"index.json":{code:e}},options:{activeFile:"index.json"},children:v.jsx(tee,{children:v.jsx(_re,{onConfigChange:t,onSubmit:n})})})})}function _re({onConfigChange:t,onSubmit:e}){const{code:n}=gg();w.useEffect(()=>{t(n)},[n,t]);const r=w.useMemo(()=>Ad.of([{key:"Mod-Enter",run:()=>(e(),!0)}]),[e]);return v.jsx(nM,{showInlineErrors:!0,extensions:[r]})}function $re({form:t}){const e=t.watch("extraTargets"),n=t.formState.errors.extraTargets,r=c=>{const u=t.getValues("extraTargets"),f=u?.findIndex(h=>h.targetId===c);if(f!==-1){const h=u?.filter((m,g)=>g!==f);t.setValue("extraTargets",h,{shouldValidate:!0})}else{const h=Od.find(m=>m.id===c);if(h){const m=[...u??[],{targetId:c,outputPath:`./${h.id}/icons/{name}${h.extension[0]}`}];t.setValue("extraTargets",m,{shouldValidate:!0})}}},i=(c,u)=>{const h=[...t.getValues("extraTargets")??[]],m=h[c];m&&(h[c]={...m,outputPath:u},t.setValue("extraTargets",h,{shouldValidate:!0}))},a=c=>e?.some(u=>u.targetId===c),o=c=>n&&typeof n=="object"&&!("message"in n)&&n[c]?n[c]:null;return v.jsxs(Ls,{children:[v.jsx(fc,{children:"Extra Targets"}),v.jsx(DM,{children:"Select additional targets to generate icon components for."}),v.jsxs("div",{className:"flex flex-col gap-3 mt-3",children:[v.jsx("div",{className:"flex flex-wrap gap-2",children:Od.map(c=>{const u=a(c.id),f=c.icon;return v.jsxs(Rt,{type:"button",variant:"selectable",size:"default",selected:u,onClick:()=>r(c.id),className:"rounded-lg px-4 py-2.5",children:[v.jsx(f,{className:"size-4 shrink-0"}),v.jsx("span",{children:c.name}),u&&v.jsx("div",{className:"ml-1 flex items-center justify-center rounded-full bg-primary p-0.5",children:v.jsx(rc,{className:"size-3 text-primary-foreground"})})]},c.id)})}),(e??[]).length>0&&v.jsx("div",{className:"flex flex-col gap-3 rounded-lg border p-4 bg-muted/30",children:(e??[]).map((c,u)=>{const f=Od.find(g=>g.id===c.targetId);if(!f)return null;const h=f.icon,m=o(u);return v.jsxs("div",{className:"flex flex-col gap-2",children:[v.jsxs("div",{className:"flex items-center gap-2",children:[v.jsx(h,{className:"size-4 text-muted-foreground"}),v.jsxs("span",{className:"text-sm font-medium",children:[f.name," Output Path"]})]}),v.jsxs("div",{className:"flex flex-col gap-1.5",children:[v.jsx(Ci,{placeholder:`e.g. ./components/icons${f.extension[0]} or ./components/icons/{name}${f.extension[0]}`,value:c.outputPath,onChange:g=>i(u,g.target.value),className:Be(m?.outputPath&&"border-destructive")}),m?.outputPath&&v.jsx(Ua,{errors:[m.outputPath]})]})]},`${c.targetId}-${u}`)})})]}),n&&typeof n=="object"&&"message"in n&&!Array.isArray(n)&&v.jsx(Ua,{errors:[n]})]})}function Pre({form:t}){const e=t.watch("colorVariables"),n=t.formState.errors.colorVariables,r=()=>{const u=[...t.getValues("colorVariables")??[],""];t.setValue("colorVariables",u,{shouldValidate:!0})},i=c=>{const f=t.getValues("colorVariables")?.filter((h,m)=>m!==c)??[];t.setValue("colorVariables",f,{shouldValidate:!0})},a=(c,u)=>{const h=[...t.getValues("colorVariables")??[]];h[c]=u,t.setValue("colorVariables",h,{shouldValidate:!0})},o=c=>n&&typeof n=="object"&&!("message"in n)&&Array.isArray(n)&&n[c]?n[c]:null;return v.jsxs(Ls,{children:[v.jsx(fc,{children:"Color Variables"}),v.jsx(DM,{children:"Define color variable names that can be used in your icons."}),v.jsxs("div",{className:"flex flex-col gap-3 mt-3",children:[(e??[]).length>0&&v.jsx("div",{className:"flex flex-col gap-2 rounded-lg border p-4 bg-muted/30",children:(e??[]).map((c,u)=>{const f=o(u);return v.jsxs("div",{className:"flex flex-col gap-1.5",children:[v.jsxs("div",{className:"flex items-center gap-2",children:[v.jsx(Ci,{placeholder:"e.g. --icons-secondary",value:c,onChange:h=>a(u,h.target.value),className:Be(f&&"border-destructive")}),v.jsx(Rt,{type:"button",variant:"outline",size:"icon",onClick:()=>i(u),className:"shrink-0",children:v.jsx(l_,{className:"size-4"})})]}),f&&v.jsx(Ua,{errors:[f]})]},u)})}),v.jsxs(Rt,{type:"button",variant:"outline",size:"sm",onClick:r,children:[v.jsx(ef,{className:"size-4 mr-2"}),"Add Variable"]})]}),n&&typeof n=="object"&&"message"in n&&!Array.isArray(n)&&v.jsx(Ua,{errors:[n]})]})}function jre({className:t,...e}){return v.jsx("div",{"data-slot":"card",className:Be("bg-card text-card-foreground flex flex-col gap-6 rounded-xl border py-6 shadow-sm",t),...e})}function Mre({className:t,...e}){return v.jsx("div",{"data-slot":"card-header",className:Be("@container/card-header grid auto-rows-min grid-rows-[auto_auto] items-start gap-2 px-6 has-data-[slot=card-action]:grid-cols-[1fr_auto] [.border-b]:pb-6",t),...e})}function Nre({className:t,...e}){return v.jsx("div",{"data-slot":"card-title",className:Be("leading-none font-semibold",t),...e})}function Dre({className:t,...e}){return v.jsx("div",{"data-slot":"card-content",className:Be("px-6",t),...e})}const zre={MIGRATE_SVG_TO_LOCK:{type:"MIGRATE_SVG_TO_LOCK",label:"SVG to Lock",description:"These SVG files will be migrated to the lock file",icon:a_,variant:"default",colorClass:"text-green-600 dark:text-green-400"},MIGRATE_SVG_TO_FILE:{type:"MIGRATE_SVG_TO_FILE",label:"SVG to File",description:"These SVG files will be migrated to the file system",icon:i_,variant:"default",colorClass:"text-green-600 dark:text-green-400"},ADD_EXTRA_TARGET:{type:"ADD_EXTRA_TARGET",label:"Targets to Add",description:"New target files will be generated",icon:ef,variant:"default",colorClass:"text-primary"},REMOVE_EXTRA_TARGET:{type:"REMOVE_EXTRA_TARGET",label:"Targets to Remove",description:"These target files will be deleted",icon:o_,variant:"secondary",colorClass:"text-orange-600 dark:text-orange-400"},REGENERATE_ALL:{type:"REGENERATE_ALL",label:"Regenerate all",description:"All SVG and target files will be regenerated",icon:d8,variant:"outline",colorClass:"text-cyan-600 dark:text-cyan-400"}};function Lre(t){const e=new Map;for(const n of t)e.has(n.type)||e.set(n.type,[]),e.get(n.type).push(n);return Array.from(e.entries()).map(([n,r])=>({...zre[n],changes:r})).sort((n,r)=>n.changes.length-r.changes.length)}function Zre(t){return Od.find(n=>n.id===t)?.name||t}function Vre({group:t}){const[e,n]=w.useState(10),r=t.changes.length,i=t.changes.slice(0,e),a=e<r,o=()=>{n(c=>Math.min(c+10,r))};return v.jsxs("div",{className:"flex flex-col gap-2",children:[t.type==="MIGRATE_SVG_TO_LOCK"&&i.map((c,u)=>v.jsxs("div",{className:"flex items-center gap-2 rounded-md bg-muted/50 px-3 py-2 text-sm font-mono",children:[v.jsx(a_,{className:"size-3.5 text-green-600 dark:text-green-400 shrink-0"}),v.jsx("span",{className:"truncate",children:c.filePath})]},u)),t.type==="MIGRATE_SVG_TO_FILE"&&i.map((c,u)=>v.jsxs("div",{className:"flex items-center gap-2 rounded-md bg-muted/50 px-3 py-2 text-sm font-mono",children:[v.jsx(i_,{className:"size-3.5 text-green-600 dark:text-green-400 shrink-0"}),v.jsx("span",{className:"truncate",children:c.filePath}),c.iconKey&&v.jsx(La,{variant:"outline",className:"ml-auto shrink-0",children:c.iconKey})]},u)),(t.type==="ADD_EXTRA_TARGET"||t.type==="REMOVE_EXTRA_TARGET")&&i.map((c,u)=>v.jsxs("div",{className:"flex items-center gap-2 rounded-md bg-muted/50 px-3 py-2",children:[t.type==="ADD_EXTRA_TARGET"&&v.jsx(ef,{className:"size-3.5 text-primary shrink-0"}),t.type==="REMOVE_EXTRA_TARGET"&&v.jsx(o_,{className:"size-3.5 text-orange-600 dark:text-orange-400 shrink-0"}),v.jsxs("div",{className:"flex flex-col gap-0.5 flex-1 min-w-0",children:[v.jsx("span",{className:"text-sm font-medium",children:c.targetId&&Zre(c.targetId)}),v.jsx("span",{className:"text-xs font-mono text-muted-foreground truncate",children:c.filePath})]}),c.iconKey&&v.jsx(La,{variant:"outline",className:"shrink-0",children:c.iconKey})]},u)),t.type==="REGENERATE_ALL"&&v.jsxs("div",{className:"flex items-center gap-2 rounded-md bg-muted/50 px-3 py-2 text-sm",children:[v.jsx(t.icon,{className:Be("size-4 shrink-0",t.colorClass)}),v.jsx("span",{children:t.description})]}),a&&v.jsxs(Rt,{variant:"ghost",size:"sm",onClick:o,className:"w-full mt-1",children:[v.jsx(Jd,{className:"size-4 mr-2"}),"Show more (",r-e," remaining)"]})]})}function Xre({changes:t,config:e,onConfirm:n,onBack:r}){const i=Ox(),a=Lre(t),o=async()=>{try{await i.mutateAsync({config:e,changes:t}),bn.success("Configuration saved successfully"),n()}catch(c){bn.error("Failed to save configuration. Please try again."),console.error("Error saving config:",c)}};return v.jsxs("div",{className:"flex flex-col gap-4",children:[v.jsx(ff,{className:"max-h-[60vh]",children:v.jsx("div",{className:"flex flex-col gap-3 ",children:a.map(c=>{const u=c.icon,f=c.changes.length;return v.jsxs(jre,{className:Be("border-l-4",c.type==="MIGRATE_SVG_TO_LOCK"&&"border-l-green-600 dark:border-l-green-400",c.type==="MIGRATE_SVG_TO_FILE"&&"border-l-green-600 dark:border-l-green-400",c.type==="ADD_EXTRA_TARGET"&&"border-l-primary",c.type==="REMOVE_EXTRA_TARGET"&&"border-l-orange-600 dark:border-l-orange-400",c.type==="REGENERATE_ALL"&&"border-l-cyan-600 dark:border-l-cyan-400"),children:[v.jsx(Mre,{className:"pb-3",children:v.jsxs("div",{className:"flex items-center justify-between",children:[v.jsxs("div",{className:"flex items-center gap-3",children:[v.jsx("div",{className:Be("flex items-center justify-center rounded-lg p-2",c.colorClass,c.variant==="destructive"?"bg-destructive/10":c.variant==="default"?"bg-primary/10":"bg-muted"),children:v.jsx(u,{className:"size-5"})}),v.jsxs("div",{className:"flex flex-col gap-0.5",children:[v.jsx(Nre,{className:"text-base",children:c.label}),v.jsx("p",{className:"text-xs text-muted-foreground",children:c.description})]})]}),v.jsx(La,{variant:c.variant,className:c.type==="MIGRATE_SVG_TO_FILE"?"bg-green-600 text-white border-green-600":c.type==="REMOVE_EXTRA_TARGET"?"bg-orange-600 text-white border-orange-600":c.type==="REGENERATE_ALL"?"bg-cyan-600 text-white border-cyan-600":void 0,children:f})]})}),v.jsx(Dre,{className:"pt-0",children:v.jsx(Vre,{group:c})})]},c.type)})})}),v.jsxs("div",{className:"flex justify-between gap-2 pt-2 border-t",children:[v.jsxs(Rt,{variant:"outline",onClick:r,disabled:i.isPending,children:[v.jsx($V,{className:"size-4 mr-2"}),"Back"]}),v.jsx(Rt,{onClick:o,disabled:i.isPending,children:i.isPending?"Applying changes...":"Confirm Changes"})]})]})}function Bre(t){return t.includes("{name}")}function Ire(t){if(Bre(t)){const n=t.match(/\{name\}(.+)$/);return n?.[1]?n[1]:""}const e=t.lastIndexOf(".");return e!==-1?t.slice(e):""}function qre(t,e){if(!t)return!1;const n=Ire(t);return e.includes(n)}function Ure({open:t,onOpenChange:e}){const{data:n,isPending:r}=Kd(),[i,a]=w.useState(1),[o,c]=w.useState(null),[u,f]=w.useState(null),h=SM({resolver:AM(fN),defaultValues:{svg:{folder:void 0,inLock:!1},svgo:JSON.stringify({plugins:["removeDimensions","removeHiddenElems","removeTitle",{name:"convertColors",params:{currentColor:!1,names2hex:!0}}]},null,2),extraTargets:[],colorVariables:[]}}),m=w.useMemo(()=>!n&&!r,[n,r]),g=w.useCallback((C,E)=>{c(C),f(E),a(2)},[]),y=w.useCallback(()=>{a(1),c(null),f(null)},[]),x=w.useCallback(C=>{const E=C??n;a(1),c(null),f(null),h.reset({...E,svgo:JSON.stringify(E.svgo,null,2)})},[h,n]),S=w.useCallback(C=>{if(!r){if(m&&!C){bn.error("OMG! Why are you trying to close the onboarding?",{icon:"😒"});return}C||x(),e(C)}},[m,r,e]);w.useEffect(()=>{r||(m?S(!0):x(n))},[m,n,h,r,S]);const k=i===1?m?"Onboarding":"Config":"Review Changes",T=i===1?m?"Let's get you started with Iconoma.":"Configure the Iconoma project.":"Review the changes that will be applied to your project. If you confirm, these changes will be executed.";return v.jsx(zx,{open:t,onOpenChange:S,children:v.jsxs(Lx,{children:[v.jsxs(Zx,{children:[v.jsx(Vx,{children:k}),v.jsx(Xx,{children:T})]}),i===1?v.jsx(Are,{form:h,onNextStep:g,onComplete:()=>{e(!1),x()}}):o&&u&&v.jsx(Xre,{changes:o,config:u,onConfirm:()=>{e(!1)},onBack:y})]})})}function Yre(){const[t,e]=w.useState(!1);return v.jsxs(v.Fragment,{children:[v.jsx(Rt,{size:"icon",onClick:()=>e(!0),children:v.jsx(h8,{})}),v.jsx(Ure,{open:t,onOpenChange:e})]})}var Eg="Popover",[DN]=pa(Eg,[Bm]),hf=Bm(),[Fre,eo]=DN(Eg),zN=t=>{const{__scopePopover:e,children:n,open:r,defaultOpen:i,onOpenChange:a,modal:o=!1}=t,c=hf(e),u=w.useRef(null),[f,h]=w.useState(!1),[m,g]=Ga({prop:r,defaultProp:i??!1,onChange:a,caller:Eg});return v.jsx(N_,{...c,children:v.jsx(Fre,{scope:e,contentId:Ba(),triggerRef:u,open:m,onOpenChange:g,onOpenToggle:w.useCallback(()=>g(y=>!y),[g]),hasCustomAnchor:f,onCustomAnchorAdd:w.useCallback(()=>h(!0),[]),onCustomAnchorRemove:w.useCallback(()=>h(!1),[]),modal:o,children:n})})};zN.displayName=Eg;var LN="PopoverAnchor",Wre=w.forwardRef((t,e)=>{const{__scopePopover:n,...r}=t,i=eo(LN,n),a=hf(n),{onCustomAnchorAdd:o,onCustomAnchorRemove:c}=i;return w.useEffect(()=>(o(),()=>c()),[o,c]),v.jsx(_x,{...a,...r,ref:e})});Wre.displayName=LN;var ZN="PopoverTrigger",VN=w.forwardRef((t,e)=>{const{__scopePopover:n,...r}=t,i=eo(ZN,n),a=hf(n),o=ft(e,i.triggerRef),c=v.jsx(et.button,{type:"button","aria-haspopup":"dialog","aria-expanded":i.open,"aria-controls":i.contentId,"data-state":UN(i.open),...r,ref:o,onClick:He(t.onClick,i.onOpenToggle)});return i.hasCustomAnchor?c:v.jsx(_x,{asChild:!0,...a,children:c})});VN.displayName=ZN;var G1="PopoverPortal",[Gre,Hre]=DN(G1,{forceMount:void 0}),XN=t=>{const{__scopePopover:e,forceMount:n,children:r,container:i}=t,a=eo(G1,e);return v.jsx(Gre,{scope:e,forceMount:n,children:v.jsx(fi,{present:n||a.open,children:v.jsx(Im,{asChild:!0,container:i,children:r})})})};XN.displayName=G1;var jc="PopoverContent",BN=w.forwardRef((t,e)=>{const n=Hre(jc,t.__scopePopover),{forceMount:r=n.forceMount,...i}=t,a=eo(jc,t.__scopePopover);return v.jsx(fi,{present:r||a.open,children:a.modal?v.jsx(Jre,{...i,ref:e}):v.jsx(eie,{...i,ref:e})})});BN.displayName=jc;var Kre=pc("PopoverContent.RemoveScroll"),Jre=w.forwardRef((t,e)=>{const n=eo(jc,t.__scopePopover),r=w.useRef(null),i=ft(e,r),a=w.useRef(!1);return w.useEffect(()=>{const o=r.current;if(o)return Px(o)},[]),v.jsx(Um,{as:Kre,allowPinchZoom:!0,children:v.jsx(IN,{...t,ref:i,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:He(t.onCloseAutoFocus,o=>{o.preventDefault(),a.current||n.triggerRef.current?.focus()}),onPointerDownOutside:He(t.onPointerDownOutside,o=>{const c=o.detail.originalEvent,u=c.button===0&&c.ctrlKey===!0,f=c.button===2||u;a.current=f},{checkForDefaultPrevented:!1}),onFocusOutside:He(t.onFocusOutside,o=>o.preventDefault(),{checkForDefaultPrevented:!1})})})}),eie=w.forwardRef((t,e)=>{const n=eo(jc,t.__scopePopover),r=w.useRef(!1),i=w.useRef(!1);return v.jsx(IN,{...t,ref:e,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:a=>{t.onCloseAutoFocus?.(a),a.defaultPrevented||(r.current||n.triggerRef.current?.focus(),a.preventDefault()),r.current=!1,i.current=!1},onInteractOutside:a=>{t.onInteractOutside?.(a),a.defaultPrevented||(r.current=!0,a.detail.originalEvent.type==="pointerdown"&&(i.current=!0));const o=a.target;n.triggerRef.current?.contains(o)&&a.preventDefault(),a.detail.originalEvent.type==="focusin"&&i.current&&a.preventDefault()}})}),IN=w.forwardRef((t,e)=>{const{__scopePopover:n,trapFocus:r,onOpenAutoFocus:i,onCloseAutoFocus:a,disableOutsidePointerEvents:o,onEscapeKeyDown:c,onPointerDownOutside:u,onFocusOutside:f,onInteractOutside:h,...m}=t,g=eo(jc,n),y=hf(n);return xx(),v.jsx(zm,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:i,onUnmountAutoFocus:a,children:v.jsx(Dm,{asChild:!0,disableOutsidePointerEvents:o,onInteractOutside:h,onEscapeKeyDown:c,onPointerDownOutside:u,onFocusOutside:f,onDismiss:()=>g.onOpenChange(!1),children:v.jsx(D_,{"data-state":UN(g.open),role:"dialog",id:g.contentId,...y,...m,ref:e,style:{...m.style,"--radix-popover-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-popover-content-available-width":"var(--radix-popper-available-width)","--radix-popover-content-available-height":"var(--radix-popper-available-height)","--radix-popover-trigger-width":"var(--radix-popper-anchor-width)","--radix-popover-trigger-height":"var(--radix-popper-anchor-height)"}})})})}),qN="PopoverClose",tie=w.forwardRef((t,e)=>{const{__scopePopover:n,...r}=t,i=eo(qN,n);return v.jsx(et.button,{type:"button",...r,ref:e,onClick:He(t.onClick,()=>i.onOpenChange(!1))})});tie.displayName=qN;var nie="PopoverArrow",rie=w.forwardRef((t,e)=>{const{__scopePopover:n,...r}=t,i=hf(n);return v.jsx(z_,{...i,...r,ref:e})});rie.displayName=nie;function UN(t){return t?"open":"closed"}var iie=zN,aie=VN,sie=XN,oie=BN;function YN({...t}){return v.jsx(iie,{"data-slot":"popover",...t})}function FN({...t}){return v.jsx(aie,{"data-slot":"popover-trigger",...t})}function WN({className:t,align:e="center",sideOffset:n=4,...r}){return v.jsx(sie,{children:v.jsx(oie,{"data-slot":"popover-content",align:e,sideOffset:n,className:Be("bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 z-50 w-72 origin-(--radix-popover-content-transform-origin) rounded-md border p-4 shadow-md outline-hidden",t),...r})})}function lie(){const{previewColor:t,setPreviewColor:e,colorPickerHint:n,colorVariableValues:r,setColorVariableValue:i}=jm(),{data:a}=Kd(),o=a?.colorVariables||[],c=f=>r[f]||"#e5e5e5",u=f=>{let h=f.replace("#","");if(h.length===3&&(h=h.split("").map(S=>S+S).join("")),h.length!==6)return"#000000";const m=parseInt(h.substring(0,2),16),g=parseInt(h.substring(2,4),16),y=parseInt(h.substring(4,6),16);return(m*299+g*587+y*114)/1e3>=128?"#000000":"#e5e5e5"};return v.jsxs("div",{className:"flex items-center gap-2 w-fit whitespace-nowrap",children:[n&&v.jsxs("div",{className:"flex items-center gap-1.5 text-sm text-muted-foreground",children:[v.jsx("span",{children:n}),v.jsx(jV,{className:"size-4"})]}),v.jsxs(YN,{children:[v.jsx(FN,{asChild:!0,children:v.jsxs(Rt,{size:"icon",variant:"outline",className:"relative overflow-hidden","aria-label":"Select preview color",children:[v.jsx("div",{className:"absolute inset-0 -z-10",style:{backgroundColor:t}}),v.jsx(l8,{style:{color:u(t)}})]})}),v.jsx(WN,{className:"w-auto p-3",align:"end",children:v.jsx(ff,{className:"max-h-[60vh]",children:v.jsxs("div",{className:"flex flex-col gap-4 pr-4",children:[v.jsxs("div",{className:"flex flex-col gap-3",children:[v.jsx("label",{className:"text-sm font-medium",children:"currentColor"}),v.jsxs("div",{className:"flex items-center gap-2",children:[v.jsx("div",{className:"relative",children:v.jsx(Ci,{type:"color",value:t,onChange:f=>e(f.target.value),className:"h-10 w-30 cursor-pointer border-none p-0","aria-label":"Color picker"})}),v.jsx(Ci,{type:"text",value:t,onChange:f=>{const h=f.target.value;/^#[0-9A-Fa-f]{0,6}$/.test(h)&&e(h)},placeholder:"#000000",className:"w-20 font-mono text-sm","aria-label":"Color hex value"})]})]}),o.length>0&&v.jsxs(v.Fragment,{children:[v.jsx(cne,{}),v.jsxs("div",{className:"flex flex-col gap-3",children:[v.jsx("label",{className:"text-sm font-medium",children:"Color Variables"}),v.jsx("div",{className:"flex flex-col gap-3",children:o.map(f=>{const h=c(f);return v.jsxs("div",{className:"flex flex-col gap-2",children:[v.jsx("label",{className:"text-xs text-muted-foreground font-mono",children:f}),v.jsxs("div",{className:"flex items-center gap-2",children:[v.jsx("div",{className:"relative",children:v.jsx(Ci,{type:"color",value:h,onChange:m=>i(f,m.target.value),className:"h-10 w-30 cursor-pointer border-none p-0","aria-label":`Color picker for ${f}`})}),v.jsx(Ci,{type:"text",value:h,onChange:m=>{const g=m.target.value;/^#[0-9A-Fa-f]{0,6}$/.test(g)&&i(f,g)},placeholder:"#000000",className:"w-20 font-mono text-sm","aria-label":`Color hex value for ${f}`})]})]},f)})})]})]})]})})})]})]})}function cie(){return v.jsxs(v.Fragment,{children:[v.jsx("div",{className:"h-16"}),v.jsxs("header",{className:"flex items-center justify-between p-4 w-full border-b fixed top-0 left-0 right-0 z-50 h-16 bg-background shadow-sm",children:[v.jsxs(No,{to:"/",className:"hover:opacity-80 transition-opacity flex items-center gap-2 w-full",children:[v.jsx("img",{src:"/icon.png",alt:"Iconoma Logo",className:"w-6 h-6"}),v.jsx("span",{className:"text-sm font-medium",children:"Iconoma Studio"})]}),v.jsxs("div",{className:"flex items-center gap-2",children:[v.jsx(lie,{}),v.jsx(Yre,{}),v.jsx(Rt,{size:"sm",asChild:!0,children:v.jsxs(No,{to:"/icons/create",children:[v.jsx(ef,{}),v.jsx("span",{className:"text-sm font-medium",children:"Create icon"})]})})]})]})]})}function uie(){const[t,e]=w.useState(typeof window<"u"?window.innerWidth:0);return w.useEffect(()=>{const n=()=>{e(window.innerWidth)};return window.addEventListener("resize",n),n(),()=>{window.removeEventListener("resize",n)}},[]),t}function die(){return uie()<768?v.jsxs("div",{className:"flex justify-center items-center flex-col gap-4 h-screen w-screen p-4",children:[v.jsx("img",{src:"/icon.png",alt:"Iconoma Logo",className:"w-10 h-10"}),v.jsxs("div",{className:"flex flex-col items-center justify-center gap-2",children:[v.jsx("h1",{className:"text-2xl font-bold",children:"Mobile version coming soon"}),v.jsxs("p",{className:"text-sm text-muted-foreground text-center max-w-md",children:["I know that I'm is an amazing tool, but can you believe the developers haven't made a mobile version yet??😤😤😤",v.jsx("br",{}),"You can complain to them"," ",v.jsx(No,{to:"https://github.com/theryston/iconoma/issues",target:"_blank",rel:"noopener noreferrer",className:"text-primary hover:text-primary/80",children:"here"})]})]})]}):v.jsxs("div",{children:[v.jsx(cie,{}),v.jsx("main",{className:"h-screen",children:v.jsx(E4,{})}),v.jsx(Kne,{})]})}function fie(){return Yd({queryKey:["actions"],queryFn:()=>Mt.get("/api/actions").then(t=>t.data),refetchInterval:1e3})}function hie(t){switch(t.type){case"MIGRATE_SVG_TO_LOCK":return`Migrate SVG to lock for ${t.metadata&&"iconKey"in t.metadata?t.metadata.iconKey:"icon"}`;case"MIGRATE_SVG_TO_FILE":return`Create SVG file for ${t.iconKey||"icon"}`;case"ADD_EXTRA_TARGET":return`Add target ${t.targetId||""} for ${t.iconKey||"icon"}`;case"REMOVE_EXTRA_TARGET":return`Remove target ${t.targetId||""} for ${t.iconKey||"icon"}`;case"CREATE_ICON":return`Create icon ${t.iconKey||"icon"}`;case"REMOVE_ICON":return`Remove icon ${t.iconKey||"icon"}`;case"REGENERATE_ICON":return`Regenerate icon ${t.iconKey||"icon"}`;case"REGENERATE_ALL":return"Regenerate all icons";default:return"Unknown action"}}function pie(t){switch(t){case"pending":return BV;case"processing":return s_;case"completed":return r_;case"failed":return VV}}function mie(t){switch(t){case"pending":return"outline";case"processing":return"default";case"completed":return"secondary";case"failed":return"destructive"}}function gie(t){switch(t){case"pending":return"Pending";case"processing":return"Processing";case"completed":return"Completed";case"failed":return"Failed"}}function Oie({action:t}){const e=pie(t.status),n=hie(t),r=mie(t.status),i=gie(t.status);return v.jsxs("div",{className:Be("flex flex-col gap-2 p-3 rounded-lg border transition-colors w-full min-w-0","hover:bg-accent/50",t.status==="failed"&&"border-destructive/50 bg-destructive/5"),children:[v.jsxs("div",{className:"flex items-start justify-between gap-2",children:[v.jsx("p",{className:"text-sm font-medium flex-1",children:n}),v.jsxs(La,{variant:r,className:"shrink-0",children:[v.jsx(e,{className:Be("size-3",t.status==="processing"&&"animate-spin")}),i]})]}),t.percentage>0&&t.status==="processing"&&v.jsxs("div",{className:"space-y-1",children:[v.jsxs("div",{className:"flex items-center justify-between text-xs text-muted-foreground",children:[v.jsx("span",{children:"Progress"}),v.jsxs("span",{children:[t.percentage,"%"]})]}),v.jsx("div",{className:"h-2 w-full rounded-full bg-secondary overflow-hidden",children:v.jsx("div",{className:"h-full bg-primary transition-all duration-300 rounded-full",style:{width:`${t.percentage}%`}})})]}),t.status==="failed"&&t.error&&v.jsx("div",{className:"mt-1 min-w-0 w-full",children:v.jsx("p",{className:"text-xs text-destructive break-words whitespace-pre-wrap",style:{overflowWrap:"anywhere",wordBreak:"break-word"},children:t.error})})]})}function vie(){const{data:t,isLoading:e}=fie(),[n,r]=w.useState(10),i=w.useMemo(()=>{if(!t?.actions||!Array.isArray(t.actions))return[];const m=t.actions,g=m.filter(k=>k.status==="completed"||k.status==="failed"),y=m.filter(k=>k.status==="pending"||k.status==="processing"),x=g.sort((k,T)=>T.id-k.id);return[...y.sort((k,T)=>T.id-k.id),...x]},[t]),a=w.useMemo(()=>!t?.actions||!Array.isArray(t.actions)?0:t.actions.filter(m=>m.status==="pending"||m.status==="processing").length,[t]);w.useEffect(()=>{r(10)},[i.length]);const o=i.slice(0,n),c=n<i.length,u=i.length-n,f=()=>{r(m=>Math.min(m+10,i.length))};if(e||!i||i.length===0)return null;const h=a>0;return v.jsx("div",{className:"fixed bottom-6 left-6 z-50",children:v.jsxs(YN,{children:[v.jsx(FN,{asChild:!0,children:v.jsxs(Rt,{size:"sm",variant:"secondary",className:Be("rounded-full",h&&"animate-pulse"),children:[v.jsx("img",{src:"/icon.png",alt:"Iconoma Logo",className:"size-5"}),v.jsx("span",{className:"text-xs",children:h?"Something happening (don't stop the studio)":"Actions history"})]})}),v.jsxs(WN,{align:"end",side:"top",className:"w-[400px] p-0",sideOffset:12,children:[v.jsxs("div",{className:"p-4 border-b",children:[v.jsx("h3",{className:"font-semibold text-sm",children:"Actions"}),v.jsx("p",{className:"text-xs text-muted-foreground mt-1",children:a>0?`${a} active action${a!==1?"s":""}`:"No active actions"})]}),v.jsx(ff,{className:"h-[60vh] w-full",children:v.jsxs("div",{className:"p-4 space-y-2 w-full min-w-0",children:[o.map(m=>v.jsx(Oie,{action:m},m.id)),i.length===0&&v.jsx("p",{className:"text-sm text-muted-foreground text-center py-4",children:"No actions to display"}),c&&v.jsxs(Rt,{variant:"ghost",size:"sm",onClick:f,className:"w-full mt-1",children:[v.jsx(Jd,{className:"size-4 mr-2"}),"Show more (",u," remaining)"]})]})})]})]})})}var t0={exports:{}},n0,gA;function yie(){if(gA)return n0;gA=1;var t="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";return n0=t,n0}var r0,OA;function bie(){if(OA)return r0;OA=1;var t=yie();function e(){}function n(){}return n.resetWarningCache=e,r0=function(){function r(o,c,u,f,h,m){if(m!==t){var g=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw g.name="Invariant Violation",g}}r.isRequired=r;function i(){return r}var a={array:r,bigint:r,bool:r,func:r,number:r,object:r,string:r,symbol:r,any:r,arrayOf:i,element:r,elementType:r,instanceOf:i,node:r,objectOf:i,oneOf:i,oneOfType:i,shape:i,exact:i,checkPropTypes:n,resetWarningCache:e};return a.PropTypes=a,a},r0}var vA;function xie(){return vA||(vA=1,t0.exports=bie()()),t0.exports}var Sie=xie();const Bt=Nc(Sie),wie=new Map([["1km","application/vnd.1000minds.decision-model+xml"],["3dml","text/vnd.in3d.3dml"],["3ds","image/x-3ds"],["3g2","video/3gpp2"],["3gp","video/3gp"],["3gpp","video/3gpp"],["3mf","model/3mf"],["7z","application/x-7z-compressed"],["7zip","application/x-7z-compressed"],["123","application/vnd.lotus-1-2-3"],["aab","application/x-authorware-bin"],["aac","audio/x-acc"],["aam","application/x-authorware-map"],["aas","application/x-authorware-seg"],["abw","application/x-abiword"],["ac","application/vnd.nokia.n-gage.ac+xml"],["ac3","audio/ac3"],["acc","application/vnd.americandynamics.acc"],["ace","application/x-ace-compressed"],["acu","application/vnd.acucobol"],["acutc","application/vnd.acucorp"],["adp","audio/adpcm"],["aep","application/vnd.audiograph"],["afm","application/x-font-type1"],["afp","application/vnd.ibm.modcap"],["ahead","application/vnd.ahead.space"],["ai","application/pdf"],["aif","audio/x-aiff"],["aifc","audio/x-aiff"],["aiff","audio/x-aiff"],["air","application/vnd.adobe.air-application-installer-package+zip"],["ait","application/vnd.dvb.ait"],["ami","application/vnd.amiga.ami"],["amr","audio/amr"],["apk","application/vnd.android.package-archive"],["apng","image/apng"],["appcache","text/cache-manifest"],["application","application/x-ms-application"],["apr","application/vnd.lotus-approach"],["arc","application/x-freearc"],["arj","application/x-arj"],["asc","application/pgp-signature"],["asf","video/x-ms-asf"],["asm","text/x-asm"],["aso","application/vnd.accpac.simply.aso"],["asx","video/x-ms-asf"],["atc","application/vnd.acucorp"],["atom","application/atom+xml"],["atomcat","application/atomcat+xml"],["atomdeleted","application/atomdeleted+xml"],["atomsvc","application/atomsvc+xml"],["atx","application/vnd.antix.game-component"],["au","audio/x-au"],["avi","video/x-msvideo"],["avif","image/avif"],["aw","application/applixware"],["azf","application/vnd.airzip.filesecure.azf"],["azs","application/vnd.airzip.filesecure.azs"],["azv","image/vnd.airzip.accelerator.azv"],["azw","application/vnd.amazon.ebook"],["b16","image/vnd.pco.b16"],["bat","application/x-msdownload"],["bcpio","application/x-bcpio"],["bdf","application/x-font-bdf"],["bdm","application/vnd.syncml.dm+wbxml"],["bdoc","application/x-bdoc"],["bed","application/vnd.realvnc.bed"],["bh2","application/vnd.fujitsu.oasysprs"],["bin","application/octet-stream"],["blb","application/x-blorb"],["blorb","application/x-blorb"],["bmi","application/vnd.bmi"],["bmml","application/vnd.balsamiq.bmml+xml"],["bmp","image/bmp"],["book","application/vnd.framemaker"],["box","application/vnd.previewsystems.box"],["boz","application/x-bzip2"],["bpk","application/octet-stream"],["bpmn","application/octet-stream"],["bsp","model/vnd.valve.source.compiled-map"],["btif","image/prs.btif"],["buffer","application/octet-stream"],["bz","application/x-bzip"],["bz2","application/x-bzip2"],["c","text/x-c"],["c4d","application/vnd.clonk.c4group"],["c4f","application/vnd.clonk.c4group"],["c4g","application/vnd.clonk.c4group"],["c4p","application/vnd.clonk.c4group"],["c4u","application/vnd.clonk.c4group"],["c11amc","application/vnd.cluetrust.cartomobile-config"],["c11amz","application/vnd.cluetrust.cartomobile-config-pkg"],["cab","application/vnd.ms-cab-compressed"],["caf","audio/x-caf"],["cap","application/vnd.tcpdump.pcap"],["car","application/vnd.curl.car"],["cat","application/vnd.ms-pki.seccat"],["cb7","application/x-cbr"],["cba","application/x-cbr"],["cbr","application/x-cbr"],["cbt","application/x-cbr"],["cbz","application/x-cbr"],["cc","text/x-c"],["cco","application/x-cocoa"],["cct","application/x-director"],["ccxml","application/ccxml+xml"],["cdbcmsg","application/vnd.contact.cmsg"],["cda","application/x-cdf"],["cdf","application/x-netcdf"],["cdfx","application/cdfx+xml"],["cdkey","application/vnd.mediastation.cdkey"],["cdmia","application/cdmi-capability"],["cdmic","application/cdmi-container"],["cdmid","application/cdmi-domain"],["cdmio","application/cdmi-object"],["cdmiq","application/cdmi-queue"],["cdr","application/cdr"],["cdx","chemical/x-cdx"],["cdxml","application/vnd.chemdraw+xml"],["cdy","application/vnd.cinderella"],["cer","application/pkix-cert"],["cfs","application/x-cfs-compressed"],["cgm","image/cgm"],["chat","application/x-chat"],["chm","application/vnd.ms-htmlhelp"],["chrt","application/vnd.kde.kchart"],["cif","chemical/x-cif"],["cii","application/vnd.anser-web-certificate-issue-initiation"],["cil","application/vnd.ms-artgalry"],["cjs","application/node"],["cla","application/vnd.claymore"],["class","application/octet-stream"],["clkk","application/vnd.crick.clicker.keyboard"],["clkp","application/vnd.crick.clicker.palette"],["clkt","application/vnd.crick.clicker.template"],["clkw","application/vnd.crick.clicker.wordbank"],["clkx","application/vnd.crick.clicker"],["clp","application/x-msclip"],["cmc","application/vnd.cosmocaller"],["cmdf","chemical/x-cmdf"],["cml","chemical/x-cml"],["cmp","application/vnd.yellowriver-custom-menu"],["cmx","image/x-cmx"],["cod","application/vnd.rim.cod"],["coffee","text/coffeescript"],["com","application/x-msdownload"],["conf","text/plain"],["cpio","application/x-cpio"],["cpp","text/x-c"],["cpt","application/mac-compactpro"],["crd","application/x-mscardfile"],["crl","application/pkix-crl"],["crt","application/x-x509-ca-cert"],["crx","application/x-chrome-extension"],["cryptonote","application/vnd.rig.cryptonote"],["csh","application/x-csh"],["csl","application/vnd.citationstyles.style+xml"],["csml","chemical/x-csml"],["csp","application/vnd.commonspace"],["csr","application/octet-stream"],["css","text/css"],["cst","application/x-director"],["csv","text/csv"],["cu","application/cu-seeme"],["curl","text/vnd.curl"],["cww","application/prs.cww"],["cxt","application/x-director"],["cxx","text/x-c"],["dae","model/vnd.collada+xml"],["daf","application/vnd.mobius.daf"],["dart","application/vnd.dart"],["dataless","application/vnd.fdsn.seed"],["davmount","application/davmount+xml"],["dbf","application/vnd.dbf"],["dbk","application/docbook+xml"],["dcr","application/x-director"],["dcurl","text/vnd.curl.dcurl"],["dd2","application/vnd.oma.dd2+xml"],["ddd","application/vnd.fujixerox.ddd"],["ddf","application/vnd.syncml.dmddf+xml"],["dds","image/vnd.ms-dds"],["deb","application/x-debian-package"],["def","text/plain"],["deploy","application/octet-stream"],["der","application/x-x509-ca-cert"],["dfac","application/vnd.dreamfactory"],["dgc","application/x-dgc-compressed"],["dic","text/x-c"],["dir","application/x-director"],["dis","application/vnd.mobius.dis"],["disposition-notification","message/disposition-notification"],["dist","application/octet-stream"],["distz","application/octet-stream"],["djv","image/vnd.djvu"],["djvu","image/vnd.djvu"],["dll","application/octet-stream"],["dmg","application/x-apple-diskimage"],["dmn","application/octet-stream"],["dmp","application/vnd.tcpdump.pcap"],["dms","application/octet-stream"],["dna","application/vnd.dna"],["doc","application/msword"],["docm","application/vnd.ms-word.template.macroEnabled.12"],["docx","application/vnd.openxmlformats-officedocument.wordprocessingml.document"],["dot","application/msword"],["dotm","application/vnd.ms-word.template.macroEnabled.12"],["dotx","application/vnd.openxmlformats-officedocument.wordprocessingml.template"],["dp","application/vnd.osgi.dp"],["dpg","application/vnd.dpgraph"],["dra","audio/vnd.dra"],["drle","image/dicom-rle"],["dsc","text/prs.lines.tag"],["dssc","application/dssc+der"],["dtb","application/x-dtbook+xml"],["dtd","application/xml-dtd"],["dts","audio/vnd.dts"],["dtshd","audio/vnd.dts.hd"],["dump","application/octet-stream"],["dvb","video/vnd.dvb.file"],["dvi","application/x-dvi"],["dwd","application/atsc-dwd+xml"],["dwf","model/vnd.dwf"],["dwg","image/vnd.dwg"],["dxf","image/vnd.dxf"],["dxp","application/vnd.spotfire.dxp"],["dxr","application/x-director"],["ear","application/java-archive"],["ecelp4800","audio/vnd.nuera.ecelp4800"],["ecelp7470","audio/vnd.nuera.ecelp7470"],["ecelp9600","audio/vnd.nuera.ecelp9600"],["ecma","application/ecmascript"],["edm","application/vnd.novadigm.edm"],["edx","application/vnd.novadigm.edx"],["efif","application/vnd.picsel"],["ei6","application/vnd.pg.osasli"],["elc","application/octet-stream"],["emf","image/emf"],["eml","message/rfc822"],["emma","application/emma+xml"],["emotionml","application/emotionml+xml"],["emz","application/x-msmetafile"],["eol","audio/vnd.digital-winds"],["eot","application/vnd.ms-fontobject"],["eps","application/postscript"],["epub","application/epub+zip"],["es","application/ecmascript"],["es3","application/vnd.eszigno3+xml"],["esa","application/vnd.osgi.subsystem"],["esf","application/vnd.epson.esf"],["et3","application/vnd.eszigno3+xml"],["etx","text/x-setext"],["eva","application/x-eva"],["evy","application/x-envoy"],["exe","application/octet-stream"],["exi","application/exi"],["exp","application/express"],["exr","image/aces"],["ext","application/vnd.novadigm.ext"],["ez","application/andrew-inset"],["ez2","application/vnd.ezpix-album"],["ez3","application/vnd.ezpix-package"],["f","text/x-fortran"],["f4v","video/mp4"],["f77","text/x-fortran"],["f90","text/x-fortran"],["fbs","image/vnd.fastbidsheet"],["fcdt","application/vnd.adobe.formscentral.fcdt"],["fcs","application/vnd.isac.fcs"],["fdf","application/vnd.fdf"],["fdt","application/fdt+xml"],["fe_launch","application/vnd.denovo.fcselayout-link"],["fg5","application/vnd.fujitsu.oasysgp"],["fgd","application/x-director"],["fh","image/x-freehand"],["fh4","image/x-freehand"],["fh5","image/x-freehand"],["fh7","image/x-freehand"],["fhc","image/x-freehand"],["fig","application/x-xfig"],["fits","image/fits"],["flac","audio/x-flac"],["fli","video/x-fli"],["flo","application/vnd.micrografx.flo"],["flv","video/x-flv"],["flw","application/vnd.kde.kivio"],["flx","text/vnd.fmi.flexstor"],["fly","text/vnd.fly"],["fm","application/vnd.framemaker"],["fnc","application/vnd.frogans.fnc"],["fo","application/vnd.software602.filler.form+xml"],["for","text/x-fortran"],["fpx","image/vnd.fpx"],["frame","application/vnd.framemaker"],["fsc","application/vnd.fsc.weblaunch"],["fst","image/vnd.fst"],["ftc","application/vnd.fluxtime.clip"],["fti","application/vnd.anser-web-funds-transfer-initiation"],["fvt","video/vnd.fvt"],["fxp","application/vnd.adobe.fxp"],["fxpl","application/vnd.adobe.fxp"],["fzs","application/vnd.fuzzysheet"],["g2w","application/vnd.geoplan"],["g3","image/g3fax"],["g3w","application/vnd.geospace"],["gac","application/vnd.groove-account"],["gam","application/x-tads"],["gbr","application/rpki-ghostbusters"],["gca","application/x-gca-compressed"],["gdl","model/vnd.gdl"],["gdoc","application/vnd.google-apps.document"],["geo","application/vnd.dynageo"],["geojson","application/geo+json"],["gex","application/vnd.geometry-explorer"],["ggb","application/vnd.geogebra.file"],["ggt","application/vnd.geogebra.tool"],["ghf","application/vnd.groove-help"],["gif","image/gif"],["gim","application/vnd.groove-identity-message"],["glb","model/gltf-binary"],["gltf","model/gltf+json"],["gml","application/gml+xml"],["gmx","application/vnd.gmx"],["gnumeric","application/x-gnumeric"],["gpg","application/gpg-keys"],["gph","application/vnd.flographit"],["gpx","application/gpx+xml"],["gqf","application/vnd.grafeq"],["gqs","application/vnd.grafeq"],["gram","application/srgs"],["gramps","application/x-gramps-xml"],["gre","application/vnd.geometry-explorer"],["grv","application/vnd.groove-injector"],["grxml","application/srgs+xml"],["gsf","application/x-font-ghostscript"],["gsheet","application/vnd.google-apps.spreadsheet"],["gslides","application/vnd.google-apps.presentation"],["gtar","application/x-gtar"],["gtm","application/vnd.groove-tool-message"],["gtw","model/vnd.gtw"],["gv","text/vnd.graphviz"],["gxf","application/gxf"],["gxt","application/vnd.geonext"],["gz","application/gzip"],["gzip","application/gzip"],["h","text/x-c"],["h261","video/h261"],["h263","video/h263"],["h264","video/h264"],["hal","application/vnd.hal+xml"],["hbci","application/vnd.hbci"],["hbs","text/x-handlebars-template"],["hdd","application/x-virtualbox-hdd"],["hdf","application/x-hdf"],["heic","image/heic"],["heics","image/heic-sequence"],["heif","image/heif"],["heifs","image/heif-sequence"],["hej2","image/hej2k"],["held","application/atsc-held+xml"],["hh","text/x-c"],["hjson","application/hjson"],["hlp","application/winhlp"],["hpgl","application/vnd.hp-hpgl"],["hpid","application/vnd.hp-hpid"],["hps","application/vnd.hp-hps"],["hqx","application/mac-binhex40"],["hsj2","image/hsj2"],["htc","text/x-component"],["htke","application/vnd.kenameaapp"],["htm","text/html"],["html","text/html"],["hvd","application/vnd.yamaha.hv-dic"],["hvp","application/vnd.yamaha.hv-voice"],["hvs","application/vnd.yamaha.hv-script"],["i2g","application/vnd.intergeo"],["icc","application/vnd.iccprofile"],["ice","x-conference/x-cooltalk"],["icm","application/vnd.iccprofile"],["ico","image/x-icon"],["ics","text/calendar"],["ief","image/ief"],["ifb","text/calendar"],["ifm","application/vnd.shana.informed.formdata"],["iges","model/iges"],["igl","application/vnd.igloader"],["igm","application/vnd.insors.igm"],["igs","model/iges"],["igx","application/vnd.micrografx.igx"],["iif","application/vnd.shana.informed.interchange"],["img","application/octet-stream"],["imp","application/vnd.accpac.simply.imp"],["ims","application/vnd.ms-ims"],["in","text/plain"],["ini","text/plain"],["ink","application/inkml+xml"],["inkml","application/inkml+xml"],["install","application/x-install-instructions"],["iota","application/vnd.astraea-software.iota"],["ipfix","application/ipfix"],["ipk","application/vnd.shana.informed.package"],["irm","application/vnd.ibm.rights-management"],["irp","application/vnd.irepository.package+xml"],["iso","application/x-iso9660-image"],["itp","application/vnd.shana.informed.formtemplate"],["its","application/its+xml"],["ivp","application/vnd.immervision-ivp"],["ivu","application/vnd.immervision-ivu"],["jad","text/vnd.sun.j2me.app-descriptor"],["jade","text/jade"],["jam","application/vnd.jam"],["jar","application/java-archive"],["jardiff","application/x-java-archive-diff"],["java","text/x-java-source"],["jhc","image/jphc"],["jisp","application/vnd.jisp"],["jls","image/jls"],["jlt","application/vnd.hp-jlyt"],["jng","image/x-jng"],["jnlp","application/x-java-jnlp-file"],["joda","application/vnd.joost.joda-archive"],["jp2","image/jp2"],["jpe","image/jpeg"],["jpeg","image/jpeg"],["jpf","image/jpx"],["jpg","image/jpeg"],["jpg2","image/jp2"],["jpgm","video/jpm"],["jpgv","video/jpeg"],["jph","image/jph"],["jpm","video/jpm"],["jpx","image/jpx"],["js","application/javascript"],["json","application/json"],["json5","application/json5"],["jsonld","application/ld+json"],["jsonl","application/jsonl"],["jsonml","application/jsonml+json"],["jsx","text/jsx"],["jxr","image/jxr"],["jxra","image/jxra"],["jxrs","image/jxrs"],["jxs","image/jxs"],["jxsc","image/jxsc"],["jxsi","image/jxsi"],["jxss","image/jxss"],["kar","audio/midi"],["karbon","application/vnd.kde.karbon"],["kdb","application/octet-stream"],["kdbx","application/x-keepass2"],["key","application/x-iwork-keynote-sffkey"],["kfo","application/vnd.kde.kformula"],["kia","application/vnd.kidspiration"],["kml","application/vnd.google-earth.kml+xml"],["kmz","application/vnd.google-earth.kmz"],["kne","application/vnd.kinar"],["knp","application/vnd.kinar"],["kon","application/vnd.kde.kontour"],["kpr","application/vnd.kde.kpresenter"],["kpt","application/vnd.kde.kpresenter"],["kpxx","application/vnd.ds-keypoint"],["ksp","application/vnd.kde.kspread"],["ktr","application/vnd.kahootz"],["ktx","image/ktx"],["ktx2","image/ktx2"],["ktz","application/vnd.kahootz"],["kwd","application/vnd.kde.kword"],["kwt","application/vnd.kde.kword"],["lasxml","application/vnd.las.las+xml"],["latex","application/x-latex"],["lbd","application/vnd.llamagraphics.life-balance.desktop"],["lbe","application/vnd.llamagraphics.life-balance.exchange+xml"],["les","application/vnd.hhe.lesson-player"],["less","text/less"],["lgr","application/lgr+xml"],["lha","application/octet-stream"],["link66","application/vnd.route66.link66+xml"],["list","text/plain"],["list3820","application/vnd.ibm.modcap"],["listafp","application/vnd.ibm.modcap"],["litcoffee","text/coffeescript"],["lnk","application/x-ms-shortcut"],["log","text/plain"],["lostxml","application/lost+xml"],["lrf","application/octet-stream"],["lrm","application/vnd.ms-lrm"],["ltf","application/vnd.frogans.ltf"],["lua","text/x-lua"],["luac","application/x-lua-bytecode"],["lvp","audio/vnd.lucent.voice"],["lwp","application/vnd.lotus-wordpro"],["lzh","application/octet-stream"],["m1v","video/mpeg"],["m2a","audio/mpeg"],["m2v","video/mpeg"],["m3a","audio/mpeg"],["m3u","text/plain"],["m3u8","application/vnd.apple.mpegurl"],["m4a","audio/x-m4a"],["m4p","application/mp4"],["m4s","video/iso.segment"],["m4u","application/vnd.mpegurl"],["m4v","video/x-m4v"],["m13","application/x-msmediaview"],["m14","application/x-msmediaview"],["m21","application/mp21"],["ma","application/mathematica"],["mads","application/mads+xml"],["maei","application/mmt-aei+xml"],["mag","application/vnd.ecowin.chart"],["maker","application/vnd.framemaker"],["man","text/troff"],["manifest","text/cache-manifest"],["map","application/json"],["mar","application/octet-stream"],["markdown","text/markdown"],["mathml","application/mathml+xml"],["mb","application/mathematica"],["mbk","application/vnd.mobius.mbk"],["mbox","application/mbox"],["mc1","application/vnd.medcalcdata"],["mcd","application/vnd.mcd"],["mcurl","text/vnd.curl.mcurl"],["md","text/markdown"],["mdb","application/x-msaccess"],["mdi","image/vnd.ms-modi"],["mdx","text/mdx"],["me","text/troff"],["mesh","model/mesh"],["meta4","application/metalink4+xml"],["metalink","application/metalink+xml"],["mets","application/mets+xml"],["mfm","application/vnd.mfmp"],["mft","application/rpki-manifest"],["mgp","application/vnd.osgeo.mapguide.package"],["mgz","application/vnd.proteus.magazine"],["mid","audio/midi"],["midi","audio/midi"],["mie","application/x-mie"],["mif","application/vnd.mif"],["mime","message/rfc822"],["mj2","video/mj2"],["mjp2","video/mj2"],["mjs","application/javascript"],["mk3d","video/x-matroska"],["mka","audio/x-matroska"],["mkd","text/x-markdown"],["mks","video/x-matroska"],["mkv","video/x-matroska"],["mlp","application/vnd.dolby.mlp"],["mmd","application/vnd.chipnuts.karaoke-mmd"],["mmf","application/vnd.smaf"],["mml","text/mathml"],["mmr","image/vnd.fujixerox.edmics-mmr"],["mng","video/x-mng"],["mny","application/x-msmoney"],["mobi","application/x-mobipocket-ebook"],["mods","application/mods+xml"],["mov","video/quicktime"],["movie","video/x-sgi-movie"],["mp2","audio/mpeg"],["mp2a","audio/mpeg"],["mp3","audio/mpeg"],["mp4","video/mp4"],["mp4a","audio/mp4"],["mp4s","application/mp4"],["mp4v","video/mp4"],["mp21","application/mp21"],["mpc","application/vnd.mophun.certificate"],["mpd","application/dash+xml"],["mpe","video/mpeg"],["mpeg","video/mpeg"],["mpg","video/mpeg"],["mpg4","video/mp4"],["mpga","audio/mpeg"],["mpkg","application/vnd.apple.installer+xml"],["mpm","application/vnd.blueice.multipass"],["mpn","application/vnd.mophun.application"],["mpp","application/vnd.ms-project"],["mpt","application/vnd.ms-project"],["mpy","application/vnd.ibm.minipay"],["mqy","application/vnd.mobius.mqy"],["mrc","application/marc"],["mrcx","application/marcxml+xml"],["ms","text/troff"],["mscml","application/mediaservercontrol+xml"],["mseed","application/vnd.fdsn.mseed"],["mseq","application/vnd.mseq"],["msf","application/vnd.epson.msf"],["msg","application/vnd.ms-outlook"],["msh","model/mesh"],["msi","application/x-msdownload"],["msl","application/vnd.mobius.msl"],["msm","application/octet-stream"],["msp","application/octet-stream"],["msty","application/vnd.muvee.style"],["mtl","model/mtl"],["mts","model/vnd.mts"],["mus","application/vnd.musician"],["musd","application/mmt-usd+xml"],["musicxml","application/vnd.recordare.musicxml+xml"],["mvb","application/x-msmediaview"],["mvt","application/vnd.mapbox-vector-tile"],["mwf","application/vnd.mfer"],["mxf","application/mxf"],["mxl","application/vnd.recordare.musicxml"],["mxmf","audio/mobile-xmf"],["mxml","application/xv+xml"],["mxs","application/vnd.triscape.mxs"],["mxu","video/vnd.mpegurl"],["n-gage","application/vnd.nokia.n-gage.symbian.install"],["n3","text/n3"],["nb","application/mathematica"],["nbp","application/vnd.wolfram.player"],["nc","application/x-netcdf"],["ncx","application/x-dtbncx+xml"],["nfo","text/x-nfo"],["ngdat","application/vnd.nokia.n-gage.data"],["nitf","application/vnd.nitf"],["nlu","application/vnd.neurolanguage.nlu"],["nml","application/vnd.enliven"],["nnd","application/vnd.noblenet-directory"],["nns","application/vnd.noblenet-sealer"],["nnw","application/vnd.noblenet-web"],["npx","image/vnd.net-fpx"],["nq","application/n-quads"],["nsc","application/x-conference"],["nsf","application/vnd.lotus-notes"],["nt","application/n-triples"],["ntf","application/vnd.nitf"],["numbers","application/x-iwork-numbers-sffnumbers"],["nzb","application/x-nzb"],["oa2","application/vnd.fujitsu.oasys2"],["oa3","application/vnd.fujitsu.oasys3"],["oas","application/vnd.fujitsu.oasys"],["obd","application/x-msbinder"],["obgx","application/vnd.openblox.game+xml"],["obj","model/obj"],["oda","application/oda"],["odb","application/vnd.oasis.opendocument.database"],["odc","application/vnd.oasis.opendocument.chart"],["odf","application/vnd.oasis.opendocument.formula"],["odft","application/vnd.oasis.opendocument.formula-template"],["odg","application/vnd.oasis.opendocument.graphics"],["odi","application/vnd.oasis.opendocument.image"],["odm","application/vnd.oasis.opendocument.text-master"],["odp","application/vnd.oasis.opendocument.presentation"],["ods","application/vnd.oasis.opendocument.spreadsheet"],["odt","application/vnd.oasis.opendocument.text"],["oga","audio/ogg"],["ogex","model/vnd.opengex"],["ogg","audio/ogg"],["ogv","video/ogg"],["ogx","application/ogg"],["omdoc","application/omdoc+xml"],["onepkg","application/onenote"],["onetmp","application/onenote"],["onetoc","application/onenote"],["onetoc2","application/onenote"],["opf","application/oebps-package+xml"],["opml","text/x-opml"],["oprc","application/vnd.palm"],["opus","audio/ogg"],["org","text/x-org"],["osf","application/vnd.yamaha.openscoreformat"],["osfpvg","application/vnd.yamaha.openscoreformat.osfpvg+xml"],["osm","application/vnd.openstreetmap.data+xml"],["otc","application/vnd.oasis.opendocument.chart-template"],["otf","font/otf"],["otg","application/vnd.oasis.opendocument.graphics-template"],["oth","application/vnd.oasis.opendocument.text-web"],["oti","application/vnd.oasis.opendocument.image-template"],["otp","application/vnd.oasis.opendocument.presentation-template"],["ots","application/vnd.oasis.opendocument.spreadsheet-template"],["ott","application/vnd.oasis.opendocument.text-template"],["ova","application/x-virtualbox-ova"],["ovf","application/x-virtualbox-ovf"],["owl","application/rdf+xml"],["oxps","application/oxps"],["oxt","application/vnd.openofficeorg.extension"],["p","text/x-pascal"],["p7a","application/x-pkcs7-signature"],["p7b","application/x-pkcs7-certificates"],["p7c","application/pkcs7-mime"],["p7m","application/pkcs7-mime"],["p7r","application/x-pkcs7-certreqresp"],["p7s","application/pkcs7-signature"],["p8","application/pkcs8"],["p10","application/x-pkcs10"],["p12","application/x-pkcs12"],["pac","application/x-ns-proxy-autoconfig"],["pages","application/x-iwork-pages-sffpages"],["pas","text/x-pascal"],["paw","application/vnd.pawaafile"],["pbd","application/vnd.powerbuilder6"],["pbm","image/x-portable-bitmap"],["pcap","application/vnd.tcpdump.pcap"],["pcf","application/x-font-pcf"],["pcl","application/vnd.hp-pcl"],["pclxl","application/vnd.hp-pclxl"],["pct","image/x-pict"],["pcurl","application/vnd.curl.pcurl"],["pcx","image/x-pcx"],["pdb","application/x-pilot"],["pde","text/x-processing"],["pdf","application/pdf"],["pem","application/x-x509-user-cert"],["pfa","application/x-font-type1"],["pfb","application/x-font-type1"],["pfm","application/x-font-type1"],["pfr","application/font-tdpfr"],["pfx","application/x-pkcs12"],["pgm","image/x-portable-graymap"],["pgn","application/x-chess-pgn"],["pgp","application/pgp"],["php","application/x-httpd-php"],["php3","application/x-httpd-php"],["php4","application/x-httpd-php"],["phps","application/x-httpd-php-source"],["phtml","application/x-httpd-php"],["pic","image/x-pict"],["pkg","application/octet-stream"],["pki","application/pkixcmp"],["pkipath","application/pkix-pkipath"],["pkpass","application/vnd.apple.pkpass"],["pl","application/x-perl"],["plb","application/vnd.3gpp.pic-bw-large"],["plc","application/vnd.mobius.plc"],["plf","application/vnd.pocketlearn"],["pls","application/pls+xml"],["pm","application/x-perl"],["pml","application/vnd.ctc-posml"],["png","image/png"],["pnm","image/x-portable-anymap"],["portpkg","application/vnd.macports.portpkg"],["pot","application/vnd.ms-powerpoint"],["potm","application/vnd.ms-powerpoint.presentation.macroEnabled.12"],["potx","application/vnd.openxmlformats-officedocument.presentationml.template"],["ppa","application/vnd.ms-powerpoint"],["ppam","application/vnd.ms-powerpoint.addin.macroEnabled.12"],["ppd","application/vnd.cups-ppd"],["ppm","image/x-portable-pixmap"],["pps","application/vnd.ms-powerpoint"],["ppsm","application/vnd.ms-powerpoint.slideshow.macroEnabled.12"],["ppsx","application/vnd.openxmlformats-officedocument.presentationml.slideshow"],["ppt","application/powerpoint"],["pptm","application/vnd.ms-powerpoint.presentation.macroEnabled.12"],["pptx","application/vnd.openxmlformats-officedocument.presentationml.presentation"],["pqa","application/vnd.palm"],["prc","application/x-pilot"],["pre","application/vnd.lotus-freelance"],["prf","application/pics-rules"],["provx","application/provenance+xml"],["ps","application/postscript"],["psb","application/vnd.3gpp.pic-bw-small"],["psd","application/x-photoshop"],["psf","application/x-font-linux-psf"],["pskcxml","application/pskc+xml"],["pti","image/prs.pti"],["ptid","application/vnd.pvi.ptid1"],["pub","application/x-mspublisher"],["pvb","application/vnd.3gpp.pic-bw-var"],["pwn","application/vnd.3m.post-it-notes"],["pya","audio/vnd.ms-playready.media.pya"],["pyv","video/vnd.ms-playready.media.pyv"],["qam","application/vnd.epson.quickanime"],["qbo","application/vnd.intu.qbo"],["qfx","application/vnd.intu.qfx"],["qps","application/vnd.publishare-delta-tree"],["qt","video/quicktime"],["qwd","application/vnd.quark.quarkxpress"],["qwt","application/vnd.quark.quarkxpress"],["qxb","application/vnd.quark.quarkxpress"],["qxd","application/vnd.quark.quarkxpress"],["qxl","application/vnd.quark.quarkxpress"],["qxt","application/vnd.quark.quarkxpress"],["ra","audio/x-realaudio"],["ram","audio/x-pn-realaudio"],["raml","application/raml+yaml"],["rapd","application/route-apd+xml"],["rar","application/x-rar"],["ras","image/x-cmu-raster"],["rcprofile","application/vnd.ipunplugged.rcprofile"],["rdf","application/rdf+xml"],["rdz","application/vnd.data-vision.rdz"],["relo","application/p2p-overlay+xml"],["rep","application/vnd.businessobjects"],["res","application/x-dtbresource+xml"],["rgb","image/x-rgb"],["rif","application/reginfo+xml"],["rip","audio/vnd.rip"],["ris","application/x-research-info-systems"],["rl","application/resource-lists+xml"],["rlc","image/vnd.fujixerox.edmics-rlc"],["rld","application/resource-lists-diff+xml"],["rm","audio/x-pn-realaudio"],["rmi","audio/midi"],["rmp","audio/x-pn-realaudio-plugin"],["rms","application/vnd.jcp.javame.midlet-rms"],["rmvb","application/vnd.rn-realmedia-vbr"],["rnc","application/relax-ng-compact-syntax"],["rng","application/xml"],["roa","application/rpki-roa"],["roff","text/troff"],["rp9","application/vnd.cloanto.rp9"],["rpm","audio/x-pn-realaudio-plugin"],["rpss","application/vnd.nokia.radio-presets"],["rpst","application/vnd.nokia.radio-preset"],["rq","application/sparql-query"],["rs","application/rls-services+xml"],["rsa","application/x-pkcs7"],["rsat","application/atsc-rsat+xml"],["rsd","application/rsd+xml"],["rsheet","application/urc-ressheet+xml"],["rss","application/rss+xml"],["rtf","text/rtf"],["rtx","text/richtext"],["run","application/x-makeself"],["rusd","application/route-usd+xml"],["rv","video/vnd.rn-realvideo"],["s","text/x-asm"],["s3m","audio/s3m"],["saf","application/vnd.yamaha.smaf-audio"],["sass","text/x-sass"],["sbml","application/sbml+xml"],["sc","application/vnd.ibm.secure-container"],["scd","application/x-msschedule"],["scm","application/vnd.lotus-screencam"],["scq","application/scvp-cv-request"],["scs","application/scvp-cv-response"],["scss","text/x-scss"],["scurl","text/vnd.curl.scurl"],["sda","application/vnd.stardivision.draw"],["sdc","application/vnd.stardivision.calc"],["sdd","application/vnd.stardivision.impress"],["sdkd","application/vnd.solent.sdkm+xml"],["sdkm","application/vnd.solent.sdkm+xml"],["sdp","application/sdp"],["sdw","application/vnd.stardivision.writer"],["sea","application/octet-stream"],["see","application/vnd.seemail"],["seed","application/vnd.fdsn.seed"],["sema","application/vnd.sema"],["semd","application/vnd.semd"],["semf","application/vnd.semf"],["senmlx","application/senml+xml"],["sensmlx","application/sensml+xml"],["ser","application/java-serialized-object"],["setpay","application/set-payment-initiation"],["setreg","application/set-registration-initiation"],["sfd-hdstx","application/vnd.hydrostatix.sof-data"],["sfs","application/vnd.spotfire.sfs"],["sfv","text/x-sfv"],["sgi","image/sgi"],["sgl","application/vnd.stardivision.writer-global"],["sgm","text/sgml"],["sgml","text/sgml"],["sh","application/x-sh"],["shar","application/x-shar"],["shex","text/shex"],["shf","application/shf+xml"],["shtml","text/html"],["sid","image/x-mrsid-image"],["sieve","application/sieve"],["sig","application/pgp-signature"],["sil","audio/silk"],["silo","model/mesh"],["sis","application/vnd.symbian.install"],["sisx","application/vnd.symbian.install"],["sit","application/x-stuffit"],["sitx","application/x-stuffitx"],["siv","application/sieve"],["skd","application/vnd.koan"],["skm","application/vnd.koan"],["skp","application/vnd.koan"],["skt","application/vnd.koan"],["sldm","application/vnd.ms-powerpoint.slide.macroenabled.12"],["sldx","application/vnd.openxmlformats-officedocument.presentationml.slide"],["slim","text/slim"],["slm","text/slim"],["sls","application/route-s-tsid+xml"],["slt","application/vnd.epson.salt"],["sm","application/vnd.stepmania.stepchart"],["smf","application/vnd.stardivision.math"],["smi","application/smil"],["smil","application/smil"],["smv","video/x-smv"],["smzip","application/vnd.stepmania.package"],["snd","audio/basic"],["snf","application/x-font-snf"],["so","application/octet-stream"],["spc","application/x-pkcs7-certificates"],["spdx","text/spdx"],["spf","application/vnd.yamaha.smaf-phrase"],["spl","application/x-futuresplash"],["spot","text/vnd.in3d.spot"],["spp","application/scvp-vp-response"],["spq","application/scvp-vp-request"],["spx","audio/ogg"],["sql","application/x-sql"],["src","application/x-wais-source"],["srt","application/x-subrip"],["sru","application/sru+xml"],["srx","application/sparql-results+xml"],["ssdl","application/ssdl+xml"],["sse","application/vnd.kodak-descriptor"],["ssf","application/vnd.epson.ssf"],["ssml","application/ssml+xml"],["sst","application/octet-stream"],["st","application/vnd.sailingtracker.track"],["stc","application/vnd.sun.xml.calc.template"],["std","application/vnd.sun.xml.draw.template"],["stf","application/vnd.wt.stf"],["sti","application/vnd.sun.xml.impress.template"],["stk","application/hyperstudio"],["stl","model/stl"],["stpx","model/step+xml"],["stpxz","model/step-xml+zip"],["stpz","model/step+zip"],["str","application/vnd.pg.format"],["stw","application/vnd.sun.xml.writer.template"],["styl","text/stylus"],["stylus","text/stylus"],["sub","text/vnd.dvb.subtitle"],["sus","application/vnd.sus-calendar"],["susp","application/vnd.sus-calendar"],["sv4cpio","application/x-sv4cpio"],["sv4crc","application/x-sv4crc"],["svc","application/vnd.dvb.service"],["svd","application/vnd.svd"],["svg","image/svg+xml"],["svgz","image/svg+xml"],["swa","application/x-director"],["swf","application/x-shockwave-flash"],["swi","application/vnd.aristanetworks.swi"],["swidtag","application/swid+xml"],["sxc","application/vnd.sun.xml.calc"],["sxd","application/vnd.sun.xml.draw"],["sxg","application/vnd.sun.xml.writer.global"],["sxi","application/vnd.sun.xml.impress"],["sxm","application/vnd.sun.xml.math"],["sxw","application/vnd.sun.xml.writer"],["t","text/troff"],["t3","application/x-t3vm-image"],["t38","image/t38"],["taglet","application/vnd.mynfc"],["tao","application/vnd.tao.intent-module-archive"],["tap","image/vnd.tencent.tap"],["tar","application/x-tar"],["tcap","application/vnd.3gpp2.tcap"],["tcl","application/x-tcl"],["td","application/urc-targetdesc+xml"],["teacher","application/vnd.smart.teacher"],["tei","application/tei+xml"],["teicorpus","application/tei+xml"],["tex","application/x-tex"],["texi","application/x-texinfo"],["texinfo","application/x-texinfo"],["text","text/plain"],["tfi","application/thraud+xml"],["tfm","application/x-tex-tfm"],["tfx","image/tiff-fx"],["tga","image/x-tga"],["tgz","application/x-tar"],["thmx","application/vnd.ms-officetheme"],["tif","image/tiff"],["tiff","image/tiff"],["tk","application/x-tcl"],["tmo","application/vnd.tmobile-livetv"],["toml","application/toml"],["torrent","application/x-bittorrent"],["tpl","application/vnd.groove-tool-template"],["tpt","application/vnd.trid.tpt"],["tr","text/troff"],["tra","application/vnd.trueapp"],["trig","application/trig"],["trm","application/x-msterminal"],["ts","video/mp2t"],["tsd","application/timestamped-data"],["tsv","text/tab-separated-values"],["ttc","font/collection"],["ttf","font/ttf"],["ttl","text/turtle"],["ttml","application/ttml+xml"],["twd","application/vnd.simtech-mindmapper"],["twds","application/vnd.simtech-mindmapper"],["txd","application/vnd.genomatix.tuxedo"],["txf","application/vnd.mobius.txf"],["txt","text/plain"],["u8dsn","message/global-delivery-status"],["u8hdr","message/global-headers"],["u8mdn","message/global-disposition-notification"],["u8msg","message/global"],["u32","application/x-authorware-bin"],["ubj","application/ubjson"],["udeb","application/x-debian-package"],["ufd","application/vnd.ufdl"],["ufdl","application/vnd.ufdl"],["ulx","application/x-glulx"],["umj","application/vnd.umajin"],["unityweb","application/vnd.unity"],["uoml","application/vnd.uoml+xml"],["uri","text/uri-list"],["uris","text/uri-list"],["urls","text/uri-list"],["usdz","model/vnd.usdz+zip"],["ustar","application/x-ustar"],["utz","application/vnd.uiq.theme"],["uu","text/x-uuencode"],["uva","audio/vnd.dece.audio"],["uvd","application/vnd.dece.data"],["uvf","application/vnd.dece.data"],["uvg","image/vnd.dece.graphic"],["uvh","video/vnd.dece.hd"],["uvi","image/vnd.dece.graphic"],["uvm","video/vnd.dece.mobile"],["uvp","video/vnd.dece.pd"],["uvs","video/vnd.dece.sd"],["uvt","application/vnd.dece.ttml+xml"],["uvu","video/vnd.uvvu.mp4"],["uvv","video/vnd.dece.video"],["uvva","audio/vnd.dece.audio"],["uvvd","application/vnd.dece.data"],["uvvf","application/vnd.dece.data"],["uvvg","image/vnd.dece.graphic"],["uvvh","video/vnd.dece.hd"],["uvvi","image/vnd.dece.graphic"],["uvvm","video/vnd.dece.mobile"],["uvvp","video/vnd.dece.pd"],["uvvs","video/vnd.dece.sd"],["uvvt","application/vnd.dece.ttml+xml"],["uvvu","video/vnd.uvvu.mp4"],["uvvv","video/vnd.dece.video"],["uvvx","application/vnd.dece.unspecified"],["uvvz","application/vnd.dece.zip"],["uvx","application/vnd.dece.unspecified"],["uvz","application/vnd.dece.zip"],["vbox","application/x-virtualbox-vbox"],["vbox-extpack","application/x-virtualbox-vbox-extpack"],["vcard","text/vcard"],["vcd","application/x-cdlink"],["vcf","text/x-vcard"],["vcg","application/vnd.groove-vcard"],["vcs","text/x-vcalendar"],["vcx","application/vnd.vcx"],["vdi","application/x-virtualbox-vdi"],["vds","model/vnd.sap.vds"],["vhd","application/x-virtualbox-vhd"],["vis","application/vnd.visionary"],["viv","video/vnd.vivo"],["vlc","application/videolan"],["vmdk","application/x-virtualbox-vmdk"],["vob","video/x-ms-vob"],["vor","application/vnd.stardivision.writer"],["vox","application/x-authorware-bin"],["vrml","model/vrml"],["vsd","application/vnd.visio"],["vsf","application/vnd.vsf"],["vss","application/vnd.visio"],["vst","application/vnd.visio"],["vsw","application/vnd.visio"],["vtf","image/vnd.valve.source.texture"],["vtt","text/vtt"],["vtu","model/vnd.vtu"],["vxml","application/voicexml+xml"],["w3d","application/x-director"],["wad","application/x-doom"],["wadl","application/vnd.sun.wadl+xml"],["war","application/java-archive"],["wasm","application/wasm"],["wav","audio/x-wav"],["wax","audio/x-ms-wax"],["wbmp","image/vnd.wap.wbmp"],["wbs","application/vnd.criticaltools.wbs+xml"],["wbxml","application/wbxml"],["wcm","application/vnd.ms-works"],["wdb","application/vnd.ms-works"],["wdp","image/vnd.ms-photo"],["weba","audio/webm"],["webapp","application/x-web-app-manifest+json"],["webm","video/webm"],["webmanifest","application/manifest+json"],["webp","image/webp"],["wg","application/vnd.pmi.widget"],["wgt","application/widget"],["wks","application/vnd.ms-works"],["wm","video/x-ms-wm"],["wma","audio/x-ms-wma"],["wmd","application/x-ms-wmd"],["wmf","image/wmf"],["wml","text/vnd.wap.wml"],["wmlc","application/wmlc"],["wmls","text/vnd.wap.wmlscript"],["wmlsc","application/vnd.wap.wmlscriptc"],["wmv","video/x-ms-wmv"],["wmx","video/x-ms-wmx"],["wmz","application/x-msmetafile"],["woff","font/woff"],["woff2","font/woff2"],["word","application/msword"],["wpd","application/vnd.wordperfect"],["wpl","application/vnd.ms-wpl"],["wps","application/vnd.ms-works"],["wqd","application/vnd.wqd"],["wri","application/x-mswrite"],["wrl","model/vrml"],["wsc","message/vnd.wfa.wsc"],["wsdl","application/wsdl+xml"],["wspolicy","application/wspolicy+xml"],["wtb","application/vnd.webturbo"],["wvx","video/x-ms-wvx"],["x3d","model/x3d+xml"],["x3db","model/x3d+fastinfoset"],["x3dbz","model/x3d+binary"],["x3dv","model/x3d-vrml"],["x3dvz","model/x3d+vrml"],["x3dz","model/x3d+xml"],["x32","application/x-authorware-bin"],["x_b","model/vnd.parasolid.transmit.binary"],["x_t","model/vnd.parasolid.transmit.text"],["xaml","application/xaml+xml"],["xap","application/x-silverlight-app"],["xar","application/vnd.xara"],["xav","application/xcap-att+xml"],["xbap","application/x-ms-xbap"],["xbd","application/vnd.fujixerox.docuworks.binder"],["xbm","image/x-xbitmap"],["xca","application/xcap-caps+xml"],["xcs","application/calendar+xml"],["xdf","application/xcap-diff+xml"],["xdm","application/vnd.syncml.dm+xml"],["xdp","application/vnd.adobe.xdp+xml"],["xdssc","application/dssc+xml"],["xdw","application/vnd.fujixerox.docuworks"],["xel","application/xcap-el+xml"],["xenc","application/xenc+xml"],["xer","application/patch-ops-error+xml"],["xfdf","application/vnd.adobe.xfdf"],["xfdl","application/vnd.xfdl"],["xht","application/xhtml+xml"],["xhtml","application/xhtml+xml"],["xhvml","application/xv+xml"],["xif","image/vnd.xiff"],["xl","application/excel"],["xla","application/vnd.ms-excel"],["xlam","application/vnd.ms-excel.addin.macroEnabled.12"],["xlc","application/vnd.ms-excel"],["xlf","application/xliff+xml"],["xlm","application/vnd.ms-excel"],["xls","application/vnd.ms-excel"],["xlsb","application/vnd.ms-excel.sheet.binary.macroEnabled.12"],["xlsm","application/vnd.ms-excel.sheet.macroEnabled.12"],["xlsx","application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"],["xlt","application/vnd.ms-excel"],["xltm","application/vnd.ms-excel.template.macroEnabled.12"],["xltx","application/vnd.openxmlformats-officedocument.spreadsheetml.template"],["xlw","application/vnd.ms-excel"],["xm","audio/xm"],["xml","application/xml"],["xns","application/xcap-ns+xml"],["xo","application/vnd.olpc-sugar"],["xop","application/xop+xml"],["xpi","application/x-xpinstall"],["xpl","application/xproc+xml"],["xpm","image/x-xpixmap"],["xpr","application/vnd.is-xpr"],["xps","application/vnd.ms-xpsdocument"],["xpw","application/vnd.intercon.formnet"],["xpx","application/vnd.intercon.formnet"],["xsd","application/xml"],["xsl","application/xml"],["xslt","application/xslt+xml"],["xsm","application/vnd.syncml+xml"],["xspf","application/xspf+xml"],["xul","application/vnd.mozilla.xul+xml"],["xvm","application/xv+xml"],["xvml","application/xv+xml"],["xwd","image/x-xwindowdump"],["xyz","chemical/x-xyz"],["xz","application/x-xz"],["yaml","text/yaml"],["yang","application/yang"],["yin","application/yin+xml"],["yml","text/yaml"],["ymp","text/x-suse-ymp"],["z","application/x-compress"],["z1","application/x-zmachine"],["z2","application/x-zmachine"],["z3","application/x-zmachine"],["z4","application/x-zmachine"],["z5","application/x-zmachine"],["z6","application/x-zmachine"],["z7","application/x-zmachine"],["z8","application/x-zmachine"],["zaz","application/vnd.zzazz.deck+xml"],["zip","application/zip"],["zir","application/vnd.zul"],["zirz","application/vnd.zul"],["zmm","application/vnd.handheld-entertainment+xml"],["zsh","text/x-scriptzsh"]]);function Mc(t,e,n){const r=kie(t),{webkitRelativePath:i}=t,a=typeof e=="string"?e:typeof i=="string"&&i.length>0?i:`./${t.name}`;return typeof r.path!="string"&&yA(r,"path",a),yA(r,"relativePath",a),r}function kie(t){const{name:e}=t;if(e&&e.lastIndexOf(".")!==-1&&!t.type){const r=e.split(".").pop().toLowerCase(),i=wie.get(r);i&&Object.defineProperty(t,"type",{value:i,writable:!1,configurable:!1,enumerable:!0})}return t}function yA(t,e,n){Object.defineProperty(t,e,{value:n,writable:!1,configurable:!1,enumerable:!0})}const Cie=[".DS_Store","Thumbs.db"];function Tie(t){return Ko(this,void 0,void 0,function*(){return wm(t)&&Eie(t.dataTransfer)?_ie(t.dataTransfer,t.type):Qie(t)?Aie(t):Array.isArray(t)&&t.every(e=>"getFile"in e&&typeof e.getFile=="function")?Rie(t):[]})}function Eie(t){return wm(t)}function Qie(t){return wm(t)&&wm(t.target)}function wm(t){return typeof t=="object"&&t!==null}function Aie(t){return Hb(t.target.files).map(e=>Mc(e))}function Rie(t){return Ko(this,void 0,void 0,function*(){return(yield Promise.all(t.map(n=>n.getFile()))).map(n=>Mc(n))})}function _ie(t,e){return Ko(this,void 0,void 0,function*(){if(t.items){const n=Hb(t.items).filter(i=>i.kind==="file");if(e!=="drop")return n;const r=yield Promise.all(n.map($ie));return bA(GN(r))}return bA(Hb(t.files).map(n=>Mc(n)))})}function bA(t){return t.filter(e=>Cie.indexOf(e.name)===-1)}function Hb(t){if(t===null)return[];const e=[];for(let n=0;n<t.length;n++){const r=t[n];e.push(r)}return e}function $ie(t){if(typeof t.webkitGetAsEntry!="function")return xA(t);const e=t.webkitGetAsEntry();return e&&e.isDirectory?HN(e):xA(t,e)}function GN(t){return t.reduce((e,n)=>[...e,...Array.isArray(n)?GN(n):[n]],[])}function xA(t,e){return Ko(this,void 0,void 0,function*(){var n;if(globalThis.isSecureContext&&typeof t.getAsFileSystemHandle=="function"){const a=yield t.getAsFileSystemHandle();if(a===null)throw new Error(`${t} is not a File`);if(a!==void 0){const o=yield a.getFile();return o.handle=a,Mc(o)}}const r=t.getAsFile();if(!r)throw new Error(`${t} is not a File`);return Mc(r,(n=e?.fullPath)!==null&&n!==void 0?n:void 0)})}function Pie(t){return Ko(this,void 0,void 0,function*(){return t.isDirectory?HN(t):jie(t)})}function HN(t){const e=t.createReader();return new Promise((n,r)=>{const i=[];function a(){e.readEntries(o=>Ko(this,void 0,void 0,function*(){if(o.length){const c=Promise.all(o.map(Pie));i.push(c),a()}else try{const c=yield Promise.all(i);n(c)}catch(c){r(c)}}),o=>{r(o)})}a()})}function jie(t){return Ko(this,void 0,void 0,function*(){return new Promise((e,n)=>{t.file(r=>{const i=Mc(r,t.fullPath);e(i)},r=>{n(r)})})})}var sp={},SA;function Mie(){return SA||(SA=1,sp.__esModule=!0,sp.default=function(t,e){if(t&&e){var n=Array.isArray(e)?e:e.split(",");if(n.length===0)return!0;var r=t.name||"",i=(t.type||"").toLowerCase(),a=i.replace(/\/.*$/,"");return n.some(function(o){var c=o.trim().toLowerCase();return c.charAt(0)==="."?r.toLowerCase().endsWith(c):c.endsWith("/*")?a===c.replace(/\/.*$/,""):i===c})}return!0}),sp}var Nie=Mie();const i0=Nc(Nie);function wA(t){return Lie(t)||zie(t)||JN(t)||Die()}function Die(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
797
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function zie(t){if(typeof Symbol<"u"&&t[Symbol.iterator]!=null||t["@@iterator"]!=null)return Array.from(t)}function Lie(t){if(Array.isArray(t))return Kb(t)}function kA(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function CA(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?kA(Object(n),!0).forEach(function(r){KN(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):kA(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function KN(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Xd(t,e){return Xie(t)||Vie(t,e)||JN(t,e)||Zie()}function Zie(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
798
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function JN(t,e){if(t){if(typeof t=="string")return Kb(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);if(n==="Object"&&t.constructor&&(n=t.constructor.name),n==="Map"||n==="Set")return Array.from(t);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Kb(t,e)}}function Kb(t,e){(e==null||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}function Vie(t,e){var n=t==null?null:typeof Symbol<"u"&&t[Symbol.iterator]||t["@@iterator"];if(n!=null){var r=[],i=!0,a=!1,o,c;try{for(n=n.call(t);!(i=(o=n.next()).done)&&(r.push(o.value),!(e&&r.length===e));i=!0);}catch(u){a=!0,c=u}finally{try{!i&&n.return!=null&&n.return()}finally{if(a)throw c}}return r}}function Xie(t){if(Array.isArray(t))return t}var Bie=typeof i0=="function"?i0:i0.default,Iie="file-invalid-type",qie="file-too-large",Uie="file-too-small",Yie="too-many-files",Fie=function(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"",n=e.split(","),r=n.length>1?"one of ".concat(n.join(", ")):n[0];return{code:Iie,message:"File type must be ".concat(r)}},TA=function(e){return{code:qie,message:"File is larger than ".concat(e," ").concat(e===1?"byte":"bytes")}},EA=function(e){return{code:Uie,message:"File is smaller than ".concat(e," ").concat(e===1?"byte":"bytes")}},Wie={code:Yie,message:"Too many files"};function e3(t,e){var n=t.type==="application/x-moz-file"||Bie(t,e);return[n,n?null:Fie(e)]}function t3(t,e,n){if(To(t.size))if(To(e)&&To(n)){if(t.size>n)return[!1,TA(n)];if(t.size<e)return[!1,EA(e)]}else{if(To(e)&&t.size<e)return[!1,EA(e)];if(To(n)&&t.size>n)return[!1,TA(n)]}return[!0,null]}function To(t){return t!=null}function Gie(t){var e=t.files,n=t.accept,r=t.minSize,i=t.maxSize,a=t.multiple,o=t.maxFiles,c=t.validator;return!a&&e.length>1||a&&o>=1&&e.length>o?!1:e.every(function(u){var f=e3(u,n),h=Xd(f,1),m=h[0],g=t3(u,r,i),y=Xd(g,1),x=y[0],S=c?c(u):null;return m&&x&&!S})}function km(t){return typeof t.isPropagationStopped=="function"?t.isPropagationStopped():typeof t.cancelBubble<"u"?t.cancelBubble:!1}function op(t){return t.dataTransfer?Array.prototype.some.call(t.dataTransfer.types,function(e){return e==="Files"||e==="application/x-moz-file"}):!!t.target&&!!t.target.files}function QA(t){t.preventDefault()}function Hie(t){return t.indexOf("MSIE")!==-1||t.indexOf("Trident/")!==-1}function Kie(t){return t.indexOf("Edge/")!==-1}function Jie(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:window.navigator.userAgent;return Hie(t)||Kie(t)}function Hi(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return function(r){for(var i=arguments.length,a=new Array(i>1?i-1:0),o=1;o<i;o++)a[o-1]=arguments[o];return e.some(function(c){return!km(r)&&c&&c.apply(void 0,[r].concat(a)),km(r)})}}function eae(){return"showOpenFilePicker"in window}function tae(t){if(To(t)){var e=Object.entries(t).filter(function(n){var r=Xd(n,2),i=r[0],a=r[1],o=!0;return n3(i)||(console.warn('Skipped "'.concat(i,'" because it is not a valid MIME type. Check https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/MIME_types/Common_types for a list of valid MIME types.')),o=!1),(!Array.isArray(a)||!a.every(r3))&&(console.warn('Skipped "'.concat(i,'" because an invalid file extension was provided.')),o=!1),o}).reduce(function(n,r){var i=Xd(r,2),a=i[0],o=i[1];return CA(CA({},n),{},KN({},a,o))},{});return[{description:"Files",accept:e}]}return t}function nae(t){if(To(t))return Object.entries(t).reduce(function(e,n){var r=Xd(n,2),i=r[0],a=r[1];return[].concat(wA(e),[i],wA(a))},[]).filter(function(e){return n3(e)||r3(e)}).join(",")}function rae(t){return t instanceof DOMException&&(t.name==="AbortError"||t.code===t.ABORT_ERR)}function iae(t){return t instanceof DOMException&&(t.name==="SecurityError"||t.code===t.SECURITY_ERR)}function n3(t){return t==="audio/*"||t==="video/*"||t==="image/*"||t==="text/*"||t==="application/*"||/\w+\/[-+.\w]+/g.test(t)}function r3(t){return/^.*\.[\w]+$/.test(t)}var aae=["children"],sae=["open"],oae=["refKey","role","onKeyDown","onFocus","onBlur","onClick","onDragEnter","onDragOver","onDragLeave","onDrop"],lae=["refKey","onChange","onClick"];function cae(t){return fae(t)||dae(t)||i3(t)||uae()}function uae(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
799
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function dae(t){if(typeof Symbol<"u"&&t[Symbol.iterator]!=null||t["@@iterator"]!=null)return Array.from(t)}function fae(t){if(Array.isArray(t))return Jb(t)}function a0(t,e){return mae(t)||pae(t,e)||i3(t,e)||hae()}function hae(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
800
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function i3(t,e){if(t){if(typeof t=="string")return Jb(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);if(n==="Object"&&t.constructor&&(n=t.constructor.name),n==="Map"||n==="Set")return Array.from(t);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Jb(t,e)}}function Jb(t,e){(e==null||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}function pae(t,e){var n=t==null?null:typeof Symbol<"u"&&t[Symbol.iterator]||t["@@iterator"];if(n!=null){var r=[],i=!0,a=!1,o,c;try{for(n=n.call(t);!(i=(o=n.next()).done)&&(r.push(o.value),!(e&&r.length===e));i=!0);}catch(u){a=!0,c=u}finally{try{!i&&n.return!=null&&n.return()}finally{if(a)throw c}}return r}}function mae(t){if(Array.isArray(t))return t}function AA(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function en(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?AA(Object(n),!0).forEach(function(r){ex(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):AA(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function ex(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Cm(t,e){if(t==null)return{};var n=gae(t,e),r,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);for(i=0;i<a.length;i++)r=a[i],!(e.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(t,r)&&(n[r]=t[r])}return n}function gae(t,e){if(t==null)return{};var n={},r=Object.keys(t),i,a;for(a=0;a<r.length;a++)i=r[a],!(e.indexOf(i)>=0)&&(n[i]=t[i]);return n}var H1=w.forwardRef(function(t,e){var n=t.children,r=Cm(t,aae),i=s3(r),a=i.open,o=Cm(i,sae);return w.useImperativeHandle(e,function(){return{open:a}},[a]),le.createElement(w.Fragment,null,n(en(en({},o),{},{open:a})))});H1.displayName="Dropzone";var a3={disabled:!1,getFilesFromEvent:Tie,maxSize:1/0,minSize:0,multiple:!0,maxFiles:0,preventDropOnDocument:!0,noClick:!1,noKeyboard:!1,noDrag:!1,noDragEventsBubbling:!1,validator:null,useFsAccessApi:!1,autoFocus:!1};H1.defaultProps=a3;H1.propTypes={children:Bt.func,accept:Bt.objectOf(Bt.arrayOf(Bt.string)),multiple:Bt.bool,preventDropOnDocument:Bt.bool,noClick:Bt.bool,noKeyboard:Bt.bool,noDrag:Bt.bool,noDragEventsBubbling:Bt.bool,minSize:Bt.number,maxSize:Bt.number,maxFiles:Bt.number,disabled:Bt.bool,getFilesFromEvent:Bt.func,onFileDialogCancel:Bt.func,onFileDialogOpen:Bt.func,useFsAccessApi:Bt.bool,autoFocus:Bt.bool,onDragEnter:Bt.func,onDragLeave:Bt.func,onDragOver:Bt.func,onDrop:Bt.func,onDropAccepted:Bt.func,onDropRejected:Bt.func,onError:Bt.func,validator:Bt.func};var tx={isFocused:!1,isFileDialogActive:!1,isDragActive:!1,isDragAccept:!1,isDragReject:!1,acceptedFiles:[],fileRejections:[]};function s3(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},e=en(en({},a3),t),n=e.accept,r=e.disabled,i=e.getFilesFromEvent,a=e.maxSize,o=e.minSize,c=e.multiple,u=e.maxFiles,f=e.onDragEnter,h=e.onDragLeave,m=e.onDragOver,g=e.onDrop,y=e.onDropAccepted,x=e.onDropRejected,S=e.onFileDialogCancel,k=e.onFileDialogOpen,T=e.useFsAccessApi,C=e.autoFocus,E=e.preventDropOnDocument,R=e.noClick,$=e.noKeyboard,P=e.noDrag,_=e.noDragEventsBubbling,M=e.onError,V=e.validator,F=w.useMemo(function(){return nae(n)},[n]),W=w.useMemo(function(){return tae(n)},[n]),I=w.useMemo(function(){return typeof k=="function"?k:RA},[k]),ne=w.useMemo(function(){return typeof S=="function"?S:RA},[S]),ee=w.useRef(null),pe=w.useRef(null),D=w.useReducer(Oae,tx),G=a0(D,2),B=G[0],ye=G[1],X=B.isFocused,A=B.isFileDialogActive,N=w.useRef(typeof window<"u"&&window.isSecureContext&&T&&eae()),L=function(){!N.current&&A&&setTimeout(function(){if(pe.current){var fe=pe.current.files;fe.length||(ye({type:"closeDialog"}),ne())}},300)};w.useEffect(function(){return window.addEventListener("focus",L,!1),function(){window.removeEventListener("focus",L,!1)}},[pe,A,ne,N]);var q=w.useRef([]),se=function(fe){ee.current&&ee.current.contains(fe.target)||(fe.preventDefault(),q.current=[])};w.useEffect(function(){return E&&(document.addEventListener("dragover",QA,!1),document.addEventListener("drop",se,!1)),function(){E&&(document.removeEventListener("dragover",QA),document.removeEventListener("drop",se))}},[ee,E]),w.useEffect(function(){return!r&&C&&ee.current&&ee.current.focus(),function(){}},[ee,C,r]);var he=w.useCallback(function(te){M?M(te):console.error(te)},[M]),H=w.useCallback(function(te){te.preventDefault(),te.persist(),Ge(te),q.current=[].concat(cae(q.current),[te.target]),op(te)&&Promise.resolve(i(te)).then(function(fe){if(!(km(te)&&!_)){var Oe=fe.length,Te=Oe>0&&Gie({files:fe,accept:F,minSize:o,maxSize:a,multiple:c,maxFiles:u,validator:V}),Ye=Oe>0&&!Te;ye({isDragAccept:Te,isDragReject:Ye,isDragActive:!0,type:"setDraggedFiles"}),f&&f(te)}}).catch(function(fe){return he(fe)})},[i,f,he,_,F,o,a,c,u,V]),ge=w.useCallback(function(te){te.preventDefault(),te.persist(),Ge(te);var fe=op(te);if(fe&&te.dataTransfer)try{te.dataTransfer.dropEffect="copy"}catch{}return fe&&m&&m(te),!1},[m,_]),xe=w.useCallback(function(te){te.preventDefault(),te.persist(),Ge(te);var fe=q.current.filter(function(Te){return ee.current&&ee.current.contains(Te)}),Oe=fe.indexOf(te.target);Oe!==-1&&fe.splice(Oe,1),q.current=fe,!(fe.length>0)&&(ye({type:"setDraggedFiles",isDragActive:!1,isDragAccept:!1,isDragReject:!1}),op(te)&&h&&h(te))},[ee,h,_]),ke=w.useCallback(function(te,fe){var Oe=[],Te=[];te.forEach(function(Ye){var ot=e3(Ye,F),kt=a0(ot,2),Dn=kt[0],Kt=kt[1],er=t3(Ye,o,a),Wt=a0(er,2),kn=Wt[0],rn=Wt[1],Zi=V?V(Ye):null;if(Dn&&kn&&!Zi)Oe.push(Ye);else{var gi=[Kt,rn];Zi&&(gi=gi.concat(Zi)),Te.push({file:Ye,errors:gi.filter(function(tr){return tr})})}}),(!c&&Oe.length>1||c&&u>=1&&Oe.length>u)&&(Oe.forEach(function(Ye){Te.push({file:Ye,errors:[Wie]})}),Oe.splice(0)),ye({acceptedFiles:Oe,fileRejections:Te,isDragReject:Te.length>0,type:"setFiles"}),g&&g(Oe,Te,fe),Te.length>0&&x&&x(Te,fe),Oe.length>0&&y&&y(Oe,fe)},[ye,c,F,o,a,u,g,y,x,V]),Ce=w.useCallback(function(te){te.preventDefault(),te.persist(),Ge(te),q.current=[],op(te)&&Promise.resolve(i(te)).then(function(fe){km(te)&&!_||ke(fe,te)}).catch(function(fe){return he(fe)}),ye({type:"reset"})},[i,ke,he,_]),Re=w.useCallback(function(){if(N.current){ye({type:"openDialog"}),I();var te={multiple:c,types:W};window.showOpenFilePicker(te).then(function(fe){return i(fe)}).then(function(fe){ke(fe,null),ye({type:"closeDialog"})}).catch(function(fe){rae(fe)?(ne(fe),ye({type:"closeDialog"})):iae(fe)?(N.current=!1,pe.current?(pe.current.value=null,pe.current.click()):he(new Error("Cannot open the file picker because the https://developer.mozilla.org/en-US/docs/Web/API/File_System_Access_API is not supported and no <input> was provided."))):he(fe)});return}pe.current&&(ye({type:"openDialog"}),I(),pe.current.value=null,pe.current.click())},[ye,I,ne,T,ke,he,W,c]),We=w.useCallback(function(te){!ee.current||!ee.current.isEqualNode(te.target)||(te.key===" "||te.key==="Enter"||te.keyCode===32||te.keyCode===13)&&(te.preventDefault(),Re())},[ee,Re]),Pe=w.useCallback(function(){ye({type:"focus"})},[]),ht=w.useCallback(function(){ye({type:"blur"})},[]),Ke=w.useCallback(function(){R||(Jie()?setTimeout(Re,0):Re())},[R,Re]),tt=function(fe){return r?null:fe},bt=function(fe){return $?null:tt(fe)},Ue=function(fe){return P?null:tt(fe)},Ge=function(fe){_&&fe.stopPropagation()},z=w.useMemo(function(){return function(){var te=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},fe=te.refKey,Oe=fe===void 0?"ref":fe,Te=te.role,Ye=te.onKeyDown,ot=te.onFocus,kt=te.onBlur,Dn=te.onClick,Kt=te.onDragEnter,er=te.onDragOver,Wt=te.onDragLeave,kn=te.onDrop,rn=Cm(te,oae);return en(en(ex({onKeyDown:bt(Hi(Ye,We)),onFocus:bt(Hi(ot,Pe)),onBlur:bt(Hi(kt,ht)),onClick:tt(Hi(Dn,Ke)),onDragEnter:Ue(Hi(Kt,H)),onDragOver:Ue(Hi(er,ge)),onDragLeave:Ue(Hi(Wt,xe)),onDrop:Ue(Hi(kn,Ce)),role:typeof Te=="string"&&Te!==""?Te:"presentation"},Oe,ee),!r&&!$?{tabIndex:0}:{}),rn)}},[ee,We,Pe,ht,Ke,H,ge,xe,Ce,$,P,r]),Y=w.useCallback(function(te){te.stopPropagation()},[]),oe=w.useMemo(function(){return function(){var te=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},fe=te.refKey,Oe=fe===void 0?"ref":fe,Te=te.onChange,Ye=te.onClick,ot=Cm(te,lae),kt=ex({accept:F,multiple:c,type:"file",style:{border:0,clip:"rect(0, 0, 0, 0)",clipPath:"inset(50%)",height:"1px",margin:"0 -1px -1px 0",overflow:"hidden",padding:0,position:"absolute",width:"1px",whiteSpace:"nowrap"},onChange:tt(Hi(Te,Ce)),onClick:tt(Hi(Ye,Y)),tabIndex:-1},Oe,pe);return en(en({},kt),ot)}},[pe,n,c,Ce,r]);return en(en({},B),{},{isFocused:X&&!r,getRootProps:z,getInputProps:oe,rootRef:ee,inputRef:pe,open:tt(Re)})}function Oae(t,e){switch(e.type){case"focus":return en(en({},t),{},{isFocused:!0});case"blur":return en(en({},t),{},{isFocused:!1});case"openDialog":return en(en({},tx),{},{isFileDialogActive:!0});case"closeDialog":return en(en({},t),{},{isFileDialogActive:!1});case"setDraggedFiles":return en(en({},t),{},{isDragActive:e.isDragActive,isDragAccept:e.isDragAccept,isDragReject:e.isDragReject});case"setFiles":return en(en({},t),{},{acceptedFiles:e.acceptedFiles,fileRejections:e.fileRejections,isDragReject:e.isDragReject});case"reset":return en({},tx);default:return t}}function RA(){}function vae({children:t}){const e=Ho(),n=w.useCallback(async a=>{const o=a[0];if(o)try{const c=o.name.split(".").pop();if(c!=="svg"){bn.error(`Are you trying to create an icon using a ${c?.toUpperCase()||"unknown"} file?`,{description:"OMG, use an SVG file instead.",icon:"🤦♂️"});return}const u=await o.text(),f=o.name.replace(/\.svg$/i,"");if(!u.trim().startsWith("<svg")&&!u.includes("<svg")){bn.error("Man, what are you doing? That's not an SVG file.",{description:"OMG, use an SVG file instead.",icon:"🤦♂️"});return}const h=encodeURIComponent(u);e(`/icons/create?content=${h}&name=${encodeURIComponent(f)}`)}catch(c){bn.error("Failed to read SVG file. Please try again."),console.error("Error reading file:",c)}},[e]),{getRootProps:r,isDragActive:i}=s3({onDrop:n,noClick:!0,noKeyboard:!0,multiple:!1});return v.jsxs("div",{...r(),className:"relative",style:{minHeight:"100vh"},children:[t,i&&v.jsx("div",{className:"fixed inset-0 z-50 flex items-center justify-center bg-background/80 backdrop-blur-sm border-4 border-dashed border-primary",children:v.jsxs("div",{className:"text-center space-y-4",children:[v.jsx("div",{className:"text-4xl font-bold text-primary",children:"Drop SVG file here"}),v.jsx("div",{className:"text-muted-foreground",children:"Release to load the file and create a new icon"})]})})]})}const yae=new DL;function bae({url:t}={}){return v.jsx(Az,{defaultTheme:"dark",storageKey:"iconoma-studio-theme",children:v.jsx(zL,{client:yae,children:v.jsxs(Q6,{children:[v.jsx(xae,{url:t,children:v.jsx(vae,{children:v.jsx(Q4,{children:v.jsxs(Fl,{element:v.jsx(die,{}),children:[v.jsx(Fl,{path:"/",element:v.jsx(WI,{})}),v.jsx(Fl,{path:"/icons/create",element:v.jsx(Ene,{})}),v.jsx(Fl,{path:"/icons/:iconKey/preview",element:v.jsx(Wne,{})}),v.jsx(Fl,{path:"/icons/:iconKey/edit",element:v.jsx(Gne,{})})]})})})}),v.jsx(vie,{}),typeof window<"u"&&v.jsx(H8,{})]})})})}function xae({url:t,children:e}){return typeof window>"u"?v.jsx(uL,{location:t||"/",children:e}):v.jsx(J4,{children:e})}Ez.hydrateRoot(document.getElementById("root"),v.jsx(w.StrictMode,{children:v.jsx(bae,{})}));export{y2 as S,Xae as _,_9 as a,$9 as b,Kl as c,P9 as d,od as e,M9 as f,Nc as g,N9 as h,Y$ as i,Bae as j,D9 as k,uy as n};
|