@gallop.software/studio 2.2.10 → 2.2.12
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
function Nm(o,s){for(var h=0;h<s.length;h++){const u=s[h];if(typeof u!="string"&&!Array.isArray(u)){for(const g in u)if(g!=="default"&&!(g in o)){const p=Object.getOwnPropertyDescriptor(u,g);p&&Object.defineProperty(o,g,p.get?p:{enumerable:!0,get:()=>u[g]})}}}return Object.freeze(Object.defineProperty(o,Symbol.toStringTag,{value:"Module"}))}(function(){const s=document.createElement("link").relList;if(s&&s.supports&&s.supports("modulepreload"))return;for(const g of document.querySelectorAll('link[rel="modulepreload"]'))u(g);new MutationObserver(g=>{for(const p of g)if(p.type==="childList")for(const k of p.addedNodes)k.tagName==="LINK"&&k.rel==="modulepreload"&&u(k)}).observe(document,{childList:!0,subtree:!0});function h(g){const p={};return g.integrity&&(p.integrity=g.integrity),g.referrerPolicy&&(p.referrerPolicy=g.referrerPolicy),g.crossOrigin==="use-credentials"?p.credentials="include":g.crossOrigin==="anonymous"?p.credentials="omit":p.credentials="same-origin",p}function u(g){if(g.ep)return;g.ep=!0;const p=h(g);fetch(g.href,p)}})();function Bm(o){return o&&o.__esModule&&Object.prototype.hasOwnProperty.call(o,"default")?o.default:o}var As={exports:{}},ki={};var q0;function jm(){if(q0)return ki;q0=1;var o=Symbol.for("react.transitional.element"),s=Symbol.for("react.fragment");function h(u,g,p){var k=null;if(p!==void 0&&(k=""+p),g.key!==void 0&&(k=""+g.key),"key"in g){p={};for(var U in g)U!=="key"&&(p[U]=g[U])}else p=g;return g=p.ref,{$$typeof:o,type:u,key:k,ref:g!==void 0?g:null,props:p}}return ki.Fragment=s,ki.jsx=h,ki.jsxs=h,ki}var Y0;function qm(){return Y0||(Y0=1,As.exports=jm()),As.exports}var Li=qm(),Es={exports:{}},we={};var G0;function Ym(){if(G0)return we;G0=1;var o=Symbol.for("react.transitional.element"),s=Symbol.for("react.portal"),h=Symbol.for("react.fragment"),u=Symbol.for("react.strict_mode"),g=Symbol.for("react.profiler"),p=Symbol.for("react.consumer"),k=Symbol.for("react.context"),U=Symbol.for("react.forward_ref"),D=Symbol.for("react.suspense"),S=Symbol.for("react.memo"),Y=Symbol.for("react.lazy"),B=Symbol.for("react.activity"),W=Symbol.iterator;function $(y){return y===null||typeof y!="object"?null:(y=W&&y[W]||y["@@iterator"],typeof y=="function"?y:null)}var V={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},q=Object.assign,de={};function I(y,L,O){this.props=y,this.context=L,this.refs=de,this.updater=O||V}I.prototype.isReactComponent={},I.prototype.setState=function(y,L){if(typeof y!="object"&&typeof y!="function"&&y!=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,y,L,"setState")},I.prototype.forceUpdate=function(y){this.updater.enqueueForceUpdate(this,y,"forceUpdate")};function ue(){}ue.prototype=I.prototype;function le(y,L,O){this.props=y,this.context=L,this.refs=de,this.updater=O||V}var re=le.prototype=new ue;re.constructor=le,q(re,I.prototype),re.isPureReactComponent=!0;var _=Array.isArray;function X(){}var j={H:null,A:null,T:null,S:null},ge=Object.prototype.hasOwnProperty;function He(y,L,O){var Z=O.ref;return{$$typeof:o,type:y,key:L,ref:Z!==void 0?Z:null,props:O}}function _e(y,L){return He(y.type,L,y.props)}function Ne(y){return typeof y=="object"&&y!==null&&y.$$typeof===o}function Le(y){var L={"=":"=0",":":"=2"};return"$"+y.replace(/[=:]/g,function(O){return L[O]})}var We=/\/+/g;function Ie(y,L){return typeof y=="object"&&y!==null&&y.key!=null?Le(""+y.key):L.toString(36)}function ze(y){switch(y.status){case"fulfilled":return y.value;case"rejected":throw y.reason;default:switch(typeof y.status=="string"?y.then(X,X):(y.status="pending",y.then(function(L){y.status==="pending"&&(y.status="fulfilled",y.value=L)},function(L){y.status==="pending"&&(y.status="rejected",y.reason=L)})),y.status){case"fulfilled":return y.value;case"rejected":throw y.reason}}throw y}function A(y,L,O,Z,ee){var Ce=typeof y;(Ce==="undefined"||Ce==="boolean")&&(y=null);var Ue=!1;if(y===null)Ue=!0;else switch(Ce){case"bigint":case"string":case"number":Ue=!0;break;case"object":switch(y.$$typeof){case o:case s:Ue=!0;break;case Y:return Ue=y._init,A(Ue(y._payload),L,O,Z,ee)}}if(Ue)return ee=ee(y),Ue=Z===""?"."+Ie(y,0):Z,_(ee)?(O="",Ue!=null&&(O=Ue.replace(We,"$&/")+"/"),A(ee,L,O,"",function(nl){return nl})):ee!=null&&(Ne(ee)&&(ee=_e(ee,O+(ee.key==null||y&&y.key===ee.key?"":(""+ee.key).replace(We,"$&/")+"/")+Ue)),L.push(ee)),1;Ue=0;var ht=Z===""?".":Z+":";if(_(y))for(var Ke=0;Ke<y.length;Ke++)Z=y[Ke],Ce=ht+Ie(Z,Ke),Ue+=A(Z,L,O,Ce,ee);else if(Ke=$(y),typeof Ke=="function")for(y=Ke.call(y),Ke=0;!(Z=y.next()).done;)Z=Z.value,Ce=ht+Ie(Z,Ke++),Ue+=A(Z,L,O,Ce,ee);else if(Ce==="object"){if(typeof y.then=="function")return A(ze(y),L,O,Z,ee);throw L=String(y),Error("Objects are not valid as a React child (found: "+(L==="[object Object]"?"object with keys {"+Object.keys(y).join(", ")+"}":L)+"). If you meant to render a collection of children, use an array instead.")}return Ue}function G(y,L,O){if(y==null)return y;var Z=[],ee=0;return A(y,Z,"","",function(Ce){return L.call(O,Ce,ee++)}),Z}function P(y){if(y._status===-1){var L=y._result;L=L(),L.then(function(O){(y._status===0||y._status===-1)&&(y._status=1,y._result=O)},function(O){(y._status===0||y._status===-1)&&(y._status=2,y._result=O)}),y._status===-1&&(y._status=0,y._result=L)}if(y._status===1)return y._result.default;throw y._result}var pe=typeof reportError=="function"?reportError:function(y){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var L=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof y=="object"&&y!==null&&typeof y.message=="string"?String(y.message):String(y),error:y});if(!window.dispatchEvent(L))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",y);return}console.error(y)},ke={map:G,forEach:function(y,L,O){G(y,function(){L.apply(this,arguments)},O)},count:function(y){var L=0;return G(y,function(){L++}),L},toArray:function(y){return G(y,function(L){return L})||[]},only:function(y){if(!Ne(y))throw Error("React.Children.only expected to receive a single React element child.");return y}};return we.Activity=B,we.Children=ke,we.Component=I,we.Fragment=h,we.Profiler=g,we.PureComponent=le,we.StrictMode=u,we.Suspense=D,we.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=j,we.__COMPILER_RUNTIME={__proto__:null,c:function(y){return j.H.useMemoCache(y)}},we.cache=function(y){return function(){return y.apply(null,arguments)}},we.cacheSignal=function(){return null},we.cloneElement=function(y,L,O){if(y==null)throw Error("The argument must be a React element, but you passed "+y+".");var Z=q({},y.props),ee=y.key;if(L!=null)for(Ce in L.key!==void 0&&(ee=""+L.key),L)!ge.call(L,Ce)||Ce==="key"||Ce==="__self"||Ce==="__source"||Ce==="ref"&&L.ref===void 0||(Z[Ce]=L[Ce]);var Ce=arguments.length-2;if(Ce===1)Z.children=O;else if(1<Ce){for(var Ue=Array(Ce),ht=0;ht<Ce;ht++)Ue[ht]=arguments[ht+2];Z.children=Ue}return He(y.type,ee,Z)},we.createContext=function(y){return y={$$typeof:k,_currentValue:y,_currentValue2:y,_threadCount:0,Provider:null,Consumer:null},y.Provider=y,y.Consumer={$$typeof:p,_context:y},y},we.createElement=function(y,L,O){var Z,ee={},Ce=null;if(L!=null)for(Z in L.key!==void 0&&(Ce=""+L.key),L)ge.call(L,Z)&&Z!=="key"&&Z!=="__self"&&Z!=="__source"&&(ee[Z]=L[Z]);var Ue=arguments.length-2;if(Ue===1)ee.children=O;else if(1<Ue){for(var ht=Array(Ue),Ke=0;Ke<Ue;Ke++)ht[Ke]=arguments[Ke+2];ee.children=ht}if(y&&y.defaultProps)for(Z in Ue=y.defaultProps,Ue)ee[Z]===void 0&&(ee[Z]=Ue[Z]);return He(y,Ce,ee)},we.createRef=function(){return{current:null}},we.forwardRef=function(y){return{$$typeof:U,render:y}},we.isValidElement=Ne,we.lazy=function(y){return{$$typeof:Y,_payload:{_status:-1,_result:y},_init:P}},we.memo=function(y,L){return{$$typeof:S,type:y,compare:L===void 0?null:L}},we.startTransition=function(y){var L=j.T,O={};j.T=O;try{var Z=y(),ee=j.S;ee!==null&&ee(O,Z),typeof Z=="object"&&Z!==null&&typeof Z.then=="function"&&Z.then(X,pe)}catch(Ce){pe(Ce)}finally{L!==null&&O.types!==null&&(L.types=O.types),j.T=L}},we.unstable_useCacheRefresh=function(){return j.H.useCacheRefresh()},we.use=function(y){return j.H.use(y)},we.useActionState=function(y,L,O){return j.H.useActionState(y,L,O)},we.useCallback=function(y,L){return j.H.useCallback(y,L)},we.useContext=function(y){return j.H.useContext(y)},we.useDebugValue=function(){},we.useDeferredValue=function(y,L){return j.H.useDeferredValue(y,L)},we.useEffect=function(y,L){return j.H.useEffect(y,L)},we.useEffectEvent=function(y){return j.H.useEffectEvent(y)},we.useId=function(){return j.H.useId()},we.useImperativeHandle=function(y,L,O){return j.H.useImperativeHandle(y,L,O)},we.useInsertionEffect=function(y,L){return j.H.useInsertionEffect(y,L)},we.useLayoutEffect=function(y,L){return j.H.useLayoutEffect(y,L)},we.useMemo=function(y,L){return j.H.useMemo(y,L)},we.useOptimistic=function(y,L){return j.H.useOptimistic(y,L)},we.useReducer=function(y,L,O){return j.H.useReducer(y,L,O)},we.useRef=function(y){return j.H.useRef(y)},we.useState=function(y){return j.H.useState(y)},we.useSyncExternalStore=function(y,L,O){return j.H.useSyncExternalStore(y,L,O)},we.useTransition=function(){return j.H.useTransition()},we.version="19.2.4",we}var V0;function Gs(){return V0||(V0=1,Es.exports=Ym()),Es.exports}var M=Gs();const uh=Bm(M),X0=Nm({__proto__:null,default:uh},[M]);function Gm(o){if(o.sheet)return o.sheet;for(var s=0;s<document.styleSheets.length;s++)if(document.styleSheets[s].ownerNode===o)return document.styleSheets[s]}function Vm(o){var s=document.createElement("style");return s.setAttribute("data-emotion",o.key),o.nonce!==void 0&&s.setAttribute("nonce",o.nonce),s.appendChild(document.createTextNode("")),s.setAttribute("data-s",""),s}var Xm=(function(){function o(h){var u=this;this._insertTag=function(g){var p;u.tags.length===0?u.insertionPoint?p=u.insertionPoint.nextSibling:u.prepend?p=u.container.firstChild:p=u.before:p=u.tags[u.tags.length-1].nextSibling,u.container.insertBefore(g,p),u.tags.push(g)},this.isSpeedy=h.speedy===void 0?!0:h.speedy,this.tags=[],this.ctr=0,this.nonce=h.nonce,this.key=h.key,this.container=h.container,this.prepend=h.prepend,this.insertionPoint=h.insertionPoint,this.before=null}var s=o.prototype;return s.hydrate=function(u){u.forEach(this._insertTag)},s.insert=function(u){this.ctr%(this.isSpeedy?65e3:1)===0&&this._insertTag(Vm(this));var g=this.tags[this.tags.length-1];if(this.isSpeedy){var p=Gm(g);try{p.insertRule(u,p.cssRules.length)}catch{}}else g.appendChild(document.createTextNode(u));this.ctr++},s.flush=function(){this.tags.forEach(function(u){var g;return(g=u.parentNode)==null?void 0:g.removeChild(u)}),this.tags=[],this.ctr=0},o})(),Ut="-ms-",cr="-moz-",Fe="-webkit-",fh="comm",Vs="rule",Xs="decl",Qm="@import",dh="@keyframes",Zm="@layer",Km=Math.abs,sr=String.fromCharCode,Jm=Object.assign;function Fm(o,s){return Rt(o,0)^45?(((s<<2^Rt(o,0))<<2^Rt(o,1))<<2^Rt(o,2))<<2^Rt(o,3):0}function hh(o){return o.trim()}function $m(o,s){return(o=s.exec(o))?o[0]:o}function $e(o,s,h){return o.replace(s,h)}function Bs(o,s){return o.indexOf(s)}function Rt(o,s){return o.charCodeAt(s)|0}function Ui(o,s,h){return o.slice(s,h)}function Tl(o){return o.length}function Qs(o){return o.length}function ar(o,s){return s.push(o),o}function Wm(o,s){return o.map(s).join("")}var ur=1,Ba=1,ph=0,Zt=0,xt=0,qa="";function fr(o,s,h,u,g,p,k){return{value:o,root:s,parent:h,type:u,props:g,children:p,line:ur,column:Ba,length:k,return:""}}function Di(o,s){return Jm(fr("",null,null,"",null,null,0),o,{length:-o.length},s)}function Im(){return xt}function Pm(){return xt=Zt>0?Rt(qa,--Zt):0,Ba--,xt===10&&(Ba=1,ur--),xt}function ll(){return xt=Zt<ph?Rt(qa,Zt++):0,Ba++,xt===10&&(Ba=1,ur++),xt}function El(){return Rt(qa,Zt)}function ir(){return Zt}function Bi(o,s){return Ui(qa,o,s)}function Hi(o){switch(o){case 0:case 9:case 10:case 13:case 32:return 5;case 33:case 43:case 44:case 47:case 62:case 64:case 126:case 59:case 123:case 125:return 4;case 58:return 3;case 34:case 39:case 40:case 91:return 2;case 41:case 93:return 1}return 0}function mh(o){return ur=Ba=1,ph=Tl(qa=o),Zt=0,[]}function gh(o){return qa="",o}function or(o){return hh(Bi(Zt-1,js(o===91?o+2:o===40?o+1:o)))}function e1(o){for(;(xt=El())&&xt<33;)ll();return Hi(o)>2||Hi(xt)>3?"":" "}function t1(o,s){for(;--s&&ll()&&!(xt<48||xt>102||xt>57&&xt<65||xt>70&&xt<97););return Bi(o,ir()+(s<6&&El()==32&&ll()==32))}function js(o){for(;ll();)switch(xt){case o:return Zt;case 34:case 39:o!==34&&o!==39&&js(xt);break;case 40:o===41&&js(o);break;case 92:ll();break}return Zt}function l1(o,s){for(;ll()&&o+xt!==57;)if(o+xt===84&&El()===47)break;return"/*"+Bi(s,Zt-1)+"*"+sr(o===47?o:ll())}function n1(o){for(;!Hi(El());)ll();return Bi(o,Zt)}function a1(o){return gh(rr("",null,null,null,[""],o=mh(o),0,[0],o))}function rr(o,s,h,u,g,p,k,U,D){for(var S=0,Y=0,B=k,W=0,$=0,V=0,q=1,de=1,I=1,ue=0,le="",re=g,_=p,X=u,j=le;de;)switch(V=ue,ue=ll()){case 40:if(V!=108&&Rt(j,B-1)==58){Bs(j+=$e(or(ue),"&","&\f"),"&\f")!=-1&&(I=-1);break}case 34:case 39:case 91:j+=or(ue);break;case 9:case 10:case 13:case 32:j+=e1(V);break;case 92:j+=t1(ir()-1,7);continue;case 47:switch(El()){case 42:case 47:ar(i1(l1(ll(),ir()),s,h),D);break;default:j+="/"}break;case 123*q:U[S++]=Tl(j)*I;case 125*q:case 59:case 0:switch(ue){case 0:case 125:de=0;case 59+Y:I==-1&&(j=$e(j,/\f/g,"")),$>0&&Tl(j)-B&&ar($>32?Z0(j+";",u,h,B-1):Z0($e(j," ","")+";",u,h,B-2),D);break;case 59:j+=";";default:if(ar(X=Q0(j,s,h,S,Y,g,U,le,re=[],_=[],B),p),ue===123)if(Y===0)rr(j,s,X,X,re,p,B,U,_);else switch(W===99&&Rt(j,3)===110?100:W){case 100:case 108:case 109:case 115:rr(o,X,X,u&&ar(Q0(o,X,X,0,0,g,U,le,g,re=[],B),_),g,_,B,U,u?re:_);break;default:rr(j,X,X,X,[""],_,0,U,_)}}S=Y=$=0,q=I=1,le=j="",B=k;break;case 58:B=1+Tl(j),$=V;default:if(q<1){if(ue==123)--q;else if(ue==125&&q++==0&&Pm()==125)continue}switch(j+=sr(ue),ue*q){case 38:I=Y>0?1:(j+="\f",-1);break;case 44:U[S++]=(Tl(j)-1)*I,I=1;break;case 64:El()===45&&(j+=or(ll())),W=El(),Y=B=Tl(le=j+=n1(ir())),ue++;break;case 45:V===45&&Tl(j)==2&&(q=0)}}return p}function Q0(o,s,h,u,g,p,k,U,D,S,Y){for(var B=g-1,W=g===0?p:[""],$=Qs(W),V=0,q=0,de=0;V<u;++V)for(var I=0,ue=Ui(o,B+1,B=Km(q=k[V])),le=o;I<$;++I)(le=hh(q>0?W[I]+" "+ue:$e(ue,/&\f/g,W[I])))&&(D[de++]=le);return fr(o,s,h,g===0?Vs:U,D,S,Y)}function i1(o,s,h){return fr(o,s,h,fh,sr(Im()),Ui(o,2,-2),0)}function Z0(o,s,h,u){return fr(o,s,h,Xs,Ui(o,0,u),Ui(o,u+1,-1),u)}function Na(o,s){for(var h="",u=Qs(o),g=0;g<u;g++)h+=s(o[g],g,o,s)||"";return h}function o1(o,s,h,u){switch(o.type){case Zm:if(o.children.length)break;case Qm:case Xs:return o.return=o.return||o.value;case fh:return"";case dh:return o.return=o.value+"{"+Na(o.children,u)+"}";case Vs:o.value=o.props.join(",")}return Tl(h=Na(o.children,u))?o.return=o.value+"{"+h+"}":""}function r1(o){var s=Qs(o);return function(h,u,g,p){for(var k="",U=0;U<s;U++)k+=o[U](h,u,g,p)||"";return k}}function c1(o){return function(s){s.root||(s=s.return)&&o(s)}}function s1(o){var s=Object.create(null);return function(h){return s[h]===void 0&&(s[h]=o(h)),s[h]}}var u1=function(s,h,u){for(var g=0,p=0;g=p,p=El(),g===38&&p===12&&(h[u]=1),!Hi(p);)ll();return Bi(s,Zt)},f1=function(s,h){var u=-1,g=44;do switch(Hi(g)){case 0:g===38&&El()===12&&(h[u]=1),s[u]+=u1(Zt-1,h,u);break;case 2:s[u]+=or(g);break;case 4:if(g===44){s[++u]=El()===58?"&\f":"",h[u]=s[u].length;break}default:s[u]+=sr(g)}while(g=ll());return s},d1=function(s,h){return gh(f1(mh(s),h))},K0=new WeakMap,h1=function(s){if(!(s.type!=="rule"||!s.parent||s.length<1)){for(var h=s.value,u=s.parent,g=s.column===u.column&&s.line===u.line;u.type!=="rule";)if(u=u.parent,!u)return;if(!(s.props.length===1&&h.charCodeAt(0)!==58&&!K0.get(u))&&!g){K0.set(s,!0);for(var p=[],k=d1(h,p),U=u.props,D=0,S=0;D<k.length;D++)for(var Y=0;Y<U.length;Y++,S++)s.props[S]=p[D]?k[D].replace(/&\f/g,U[Y]):U[Y]+" "+k[D]}}},p1=function(s){if(s.type==="decl"){var h=s.value;h.charCodeAt(0)===108&&h.charCodeAt(2)===98&&(s.return="",s.value="")}};function yh(o,s){switch(Fm(o,s)){case 5103:return Fe+"print-"+o+o;case 5737:case 4201:case 3177:case 3433:case 1641:case 4457:case 2921:case 5572:case 6356:case 5844:case 3191:case 6645:case 3005:case 6391:case 5879:case 5623:case 6135:case 4599:case 4855:case 4215:case 6389:case 5109:case 5365:case 5621:case 3829:return Fe+o+o;case 5349:case 4246:case 4810:case 6968:case 2756:return Fe+o+cr+o+Ut+o+o;case 6828:case 4268:return Fe+o+Ut+o+o;case 6165:return Fe+o+Ut+"flex-"+o+o;case 5187:return Fe+o+$e(o,/(\w+).+(:[^]+)/,Fe+"box-$1$2"+Ut+"flex-$1$2")+o;case 5443:return Fe+o+Ut+"flex-item-"+$e(o,/flex-|-self/,"")+o;case 4675:return Fe+o+Ut+"flex-line-pack"+$e(o,/align-content|flex-|-self/,"")+o;case 5548:return Fe+o+Ut+$e(o,"shrink","negative")+o;case 5292:return Fe+o+Ut+$e(o,"basis","preferred-size")+o;case 6060:return Fe+"box-"+$e(o,"-grow","")+Fe+o+Ut+$e(o,"grow","positive")+o;case 4554:return Fe+$e(o,/([^-])(transform)/g,"$1"+Fe+"$2")+o;case 6187:return $e($e($e(o,/(zoom-|grab)/,Fe+"$1"),/(image-set)/,Fe+"$1"),o,"")+o;case 5495:case 3959:return $e(o,/(image-set\([^]*)/,Fe+"$1$`$1");case 4968:return $e($e(o,/(.+:)(flex-)?(.*)/,Fe+"box-pack:$3"+Ut+"flex-pack:$3"),/s.+-b[^;]+/,"justify")+Fe+o+o;case 4095:case 3583:case 4068:case 2532:return $e(o,/(.+)-inline(.+)/,Fe+"$1$2")+o;case 8116:case 7059:case 5753:case 5535:case 5445:case 5701:case 4933:case 4677:case 5533:case 5789:case 5021:case 4765:if(Tl(o)-1-s>6)switch(Rt(o,s+1)){case 109:if(Rt(o,s+4)!==45)break;case 102:return $e(o,/(.+:)(.+)-([^]+)/,"$1"+Fe+"$2-$3$1"+cr+(Rt(o,s+3)==108?"$3":"$2-$3"))+o;case 115:return~Bs(o,"stretch")?yh($e(o,"stretch","fill-available"),s)+o:o}break;case 4949:if(Rt(o,s+1)!==115)break;case 6444:switch(Rt(o,Tl(o)-3-(~Bs(o,"!important")&&10))){case 107:return $e(o,":",":"+Fe)+o;case 101:return $e(o,/(.+:)([^;!]+)(;|!.+)?/,"$1"+Fe+(Rt(o,14)===45?"inline-":"")+"box$3$1"+Fe+"$2$3$1"+Ut+"$2box$3")+o}break;case 5936:switch(Rt(o,s+11)){case 114:return Fe+o+Ut+$e(o,/[svh]\w+-[tblr]{2}/,"tb")+o;case 108:return Fe+o+Ut+$e(o,/[svh]\w+-[tblr]{2}/,"tb-rl")+o;case 45:return Fe+o+Ut+$e(o,/[svh]\w+-[tblr]{2}/,"lr")+o}return Fe+o+Ut+o+o}return o}var m1=function(s,h,u,g){if(s.length>-1&&!s.return)switch(s.type){case Xs:s.return=yh(s.value,s.length);break;case dh:return Na([Di(s,{value:$e(s.value,"@","@"+Fe)})],g);case Vs:if(s.length)return Wm(s.props,function(p){switch($m(p,/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":return Na([Di(s,{props:[$e(p,/:(read-\w+)/,":"+cr+"$1")]})],g);case"::placeholder":return Na([Di(s,{props:[$e(p,/:(plac\w+)/,":"+Fe+"input-$1")]}),Di(s,{props:[$e(p,/:(plac\w+)/,":"+cr+"$1")]}),Di(s,{props:[$e(p,/:(plac\w+)/,Ut+"input-$1")]})],g)}return""})}},g1=[m1],y1=function(s){var h=s.key;if(h==="css"){var u=document.querySelectorAll("style[data-emotion]:not([data-s])");Array.prototype.forEach.call(u,function(q){var de=q.getAttribute("data-emotion");de.indexOf(" ")!==-1&&(document.head.appendChild(q),q.setAttribute("data-s",""))})}var g=s.stylisPlugins||g1,p={},k,U=[];k=s.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+h+' "]'),function(q){for(var de=q.getAttribute("data-emotion").split(" "),I=1;I<de.length;I++)p[de[I]]=!0;U.push(q)});var D,S=[h1,p1];{var Y,B=[o1,c1(function(q){Y.insert(q)})],W=r1(S.concat(g,B)),$=function(de){return Na(a1(de),W)};D=function(de,I,ue,le){Y=ue,$(de?de+"{"+I.styles+"}":I.styles),le&&(V.inserted[I.name]=!0)}}var V={key:h,sheet:new Xm({key:h,container:k,nonce:s.nonce,speedy:s.speedy,prepend:s.prepend,insertionPoint:s.insertionPoint}),nonce:s.nonce,inserted:p,registered:{},insert:D};return V.sheet.hydrate(U),V},_s={exports:{}},Pe={};var J0;function v1(){if(J0)return Pe;J0=1;var o=typeof Symbol=="function"&&Symbol.for,s=o?Symbol.for("react.element"):60103,h=o?Symbol.for("react.portal"):60106,u=o?Symbol.for("react.fragment"):60107,g=o?Symbol.for("react.strict_mode"):60108,p=o?Symbol.for("react.profiler"):60114,k=o?Symbol.for("react.provider"):60109,U=o?Symbol.for("react.context"):60110,D=o?Symbol.for("react.async_mode"):60111,S=o?Symbol.for("react.concurrent_mode"):60111,Y=o?Symbol.for("react.forward_ref"):60112,B=o?Symbol.for("react.suspense"):60113,W=o?Symbol.for("react.suspense_list"):60120,$=o?Symbol.for("react.memo"):60115,V=o?Symbol.for("react.lazy"):60116,q=o?Symbol.for("react.block"):60121,de=o?Symbol.for("react.fundamental"):60117,I=o?Symbol.for("react.responder"):60118,ue=o?Symbol.for("react.scope"):60119;function le(_){if(typeof _=="object"&&_!==null){var X=_.$$typeof;switch(X){case s:switch(_=_.type,_){case D:case S:case u:case p:case g:case B:return _;default:switch(_=_&&_.$$typeof,_){case U:case Y:case V:case $:case k:return _;default:return X}}case h:return X}}}function re(_){return le(_)===S}return Pe.AsyncMode=D,Pe.ConcurrentMode=S,Pe.ContextConsumer=U,Pe.ContextProvider=k,Pe.Element=s,Pe.ForwardRef=Y,Pe.Fragment=u,Pe.Lazy=V,Pe.Memo=$,Pe.Portal=h,Pe.Profiler=p,Pe.StrictMode=g,Pe.Suspense=B,Pe.isAsyncMode=function(_){return re(_)||le(_)===D},Pe.isConcurrentMode=re,Pe.isContextConsumer=function(_){return le(_)===U},Pe.isContextProvider=function(_){return le(_)===k},Pe.isElement=function(_){return typeof _=="object"&&_!==null&&_.$$typeof===s},Pe.isForwardRef=function(_){return le(_)===Y},Pe.isFragment=function(_){return le(_)===u},Pe.isLazy=function(_){return le(_)===V},Pe.isMemo=function(_){return le(_)===$},Pe.isPortal=function(_){return le(_)===h},Pe.isProfiler=function(_){return le(_)===p},Pe.isStrictMode=function(_){return le(_)===g},Pe.isSuspense=function(_){return le(_)===B},Pe.isValidElementType=function(_){return typeof _=="string"||typeof _=="function"||_===u||_===S||_===p||_===g||_===B||_===W||typeof _=="object"&&_!==null&&(_.$$typeof===V||_.$$typeof===$||_.$$typeof===k||_.$$typeof===U||_.$$typeof===Y||_.$$typeof===de||_.$$typeof===I||_.$$typeof===ue||_.$$typeof===q)},Pe.typeOf=le,Pe}var F0;function b1(){return F0||(F0=1,_s.exports=v1()),_s.exports}var ks,$0;function x1(){if($0)return ks;$0=1;var o=b1(),s={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},h={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},u={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},g={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},p={};p[o.ForwardRef]=u,p[o.Memo]=g;function k(V){return o.isMemo(V)?g:p[V.$$typeof]||s}var U=Object.defineProperty,D=Object.getOwnPropertyNames,S=Object.getOwnPropertySymbols,Y=Object.getOwnPropertyDescriptor,B=Object.getPrototypeOf,W=Object.prototype;function $(V,q,de){if(typeof q!="string"){if(W){var I=B(q);I&&I!==W&&$(V,I,de)}var ue=D(q);S&&(ue=ue.concat(S(q)));for(var le=k(V),re=k(q),_=0;_<ue.length;++_){var X=ue[_];if(!h[X]&&!(de&&de[X])&&!(re&&re[X])&&!(le&&le[X])){var j=Y(q,X);try{U(V,X,j)}catch{}}}}return V}return ks=$,ks}x1();var S1=!0;function C1(o,s,h){var u="";return h.split(" ").forEach(function(g){o[g]!==void 0?s.push(o[g]+";"):g&&(u+=g+" ")}),u}var vh=function(s,h,u){var g=s.key+"-"+h.name;(u===!1||S1===!1)&&s.registered[g]===void 0&&(s.registered[g]=h.styles)},z1=function(s,h,u){vh(s,h,u);var g=s.key+"-"+h.name;if(s.inserted[h.name]===void 0){var p=h;do s.insert(h===p?"."+g:"",p,s.sheet,!0),p=p.next;while(p!==void 0)}};function w1(o){for(var s=0,h,u=0,g=o.length;g>=4;++u,g-=4)h=o.charCodeAt(u)&255|(o.charCodeAt(++u)&255)<<8|(o.charCodeAt(++u)&255)<<16|(o.charCodeAt(++u)&255)<<24,h=(h&65535)*1540483477+((h>>>16)*59797<<16),h^=h>>>24,s=(h&65535)*1540483477+((h>>>16)*59797<<16)^(s&65535)*1540483477+((s>>>16)*59797<<16);switch(g){case 3:s^=(o.charCodeAt(u+2)&255)<<16;case 2:s^=(o.charCodeAt(u+1)&255)<<8;case 1:s^=o.charCodeAt(u)&255,s=(s&65535)*1540483477+((s>>>16)*59797<<16)}return s^=s>>>13,s=(s&65535)*1540483477+((s>>>16)*59797<<16),((s^s>>>15)>>>0).toString(36)}var M1={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,scale:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1},T1=/[A-Z]|^ms/g,A1=/_EMO_([^_]+?)_([^]*?)_EMO_/g,bh=function(s){return s.charCodeAt(1)===45},W0=function(s){return s!=null&&typeof s!="boolean"},Ds=s1(function(o){return bh(o)?o:o.replace(T1,"-$&").toLowerCase()}),I0=function(s,h){switch(s){case"animation":case"animationName":if(typeof h=="string")return h.replace(A1,function(u,g,p){return Al={name:g,styles:p,next:Al},g})}return M1[s]!==1&&!bh(s)&&typeof h=="number"&&h!==0?h+"px":h};function Ni(o,s,h){if(h==null)return"";var u=h;if(u.__emotion_styles!==void 0)return u;switch(typeof h){case"boolean":return"";case"object":{var g=h;if(g.anim===1)return Al={name:g.name,styles:g.styles,next:Al},g.name;var p=h;if(p.styles!==void 0){var k=p.next;if(k!==void 0)for(;k!==void 0;)Al={name:k.name,styles:k.styles,next:Al},k=k.next;var U=p.styles+";";return U}return E1(o,s,h)}case"function":{if(o!==void 0){var D=Al,S=h(o);return Al=D,Ni(o,s,S)}break}}var Y=h;return Y}function E1(o,s,h){var u="";if(Array.isArray(h))for(var g=0;g<h.length;g++)u+=Ni(o,s,h[g])+";";else for(var p in h){var k=h[p];if(typeof k!="object"){var U=k;W0(U)&&(u+=Ds(p)+":"+I0(p,U)+";")}else if(Array.isArray(k)&&typeof k[0]=="string"&&s==null)for(var D=0;D<k.length;D++)W0(k[D])&&(u+=Ds(p)+":"+I0(p,k[D])+";");else{var S=Ni(o,s,k);switch(p){case"animation":case"animationName":{u+=Ds(p)+":"+S+";";break}default:u+=p+"{"+S+"}"}}}return u}var P0=/label:\s*([^\s;{]+)\s*(;|$)/g,Al;function xh(o,s,h){if(o.length===1&&typeof o[0]=="object"&&o[0]!==null&&o[0].styles!==void 0)return o[0];var u=!0,g="";Al=void 0;var p=o[0];if(p==null||p.raw===void 0)u=!1,g+=Ni(h,s,p);else{var k=p;g+=k[0]}for(var U=1;U<o.length;U++)if(g+=Ni(h,s,o[U]),u){var D=p;g+=D[U]}P0.lastIndex=0;for(var S="",Y;(Y=P0.exec(g))!==null;)S+="-"+Y[1];var B=w1(g)+S;return{name:B,styles:g,next:Al}}var _1=function(s){return s()},k1=X0.useInsertionEffect?X0.useInsertionEffect:!1,D1=k1||_1,Sh=M.createContext(typeof HTMLElement<"u"?y1({key:"css"}):null);Sh.Provider;var O1=function(s){return M.forwardRef(function(h,u){var g=M.useContext(Sh);return s(h,g,u)})},R1=M.createContext({}),ji={}.hasOwnProperty,qs="__EMOTION_TYPE_PLEASE_DO_NOT_USE__",Zs=function(s,h){var u={};for(var g in h)ji.call(h,g)&&(u[g]=h[g]);return u[qs]=s,u},L1=function(s){var h=s.cache,u=s.serialized,g=s.isStringTag;return vh(h,u,g),D1(function(){return z1(h,u,g)}),null},U1=O1(function(o,s,h){var u=o.css;typeof u=="string"&&s.registered[u]!==void 0&&(u=s.registered[u]);var g=o[qs],p=[u],k="";typeof o.className=="string"?k=C1(s.registered,p,o.className):o.className!=null&&(k=o.className+" ");var U=xh(p,void 0,M.useContext(R1));k+=s.key+"-"+U.name;var D={};for(var S in o)ji.call(o,S)&&S!=="css"&&S!==qs&&(D[S]=o[S]);return D.className=k,h&&(D.ref=h),M.createElement(M.Fragment,null,M.createElement(L1,{cache:s,serialized:U,isStringTag:typeof g=="string"}),M.createElement(g,D))}),Ks=U1,Tt=Li.Fragment,c=function(s,h,u){return ji.call(h,"css")?Li.jsx(Ks,Zs(s,h),u):Li.jsx(s,h,u)},x=function(s,h,u){return ji.call(h,"css")?Li.jsxs(Ks,Zs(s,h),u):Li.jsxs(s,h,u)},Os={exports:{}},Oi={},Rs={exports:{}},Ls={};var eh;function H1(){return eh||(eh=1,(function(o){function s(A,G){var P=A.length;A.push(G);e:for(;0<P;){var pe=P-1>>>1,ke=A[pe];if(0<g(ke,G))A[pe]=G,A[P]=ke,P=pe;else break e}}function h(A){return A.length===0?null:A[0]}function u(A){if(A.length===0)return null;var G=A[0],P=A.pop();if(P!==G){A[0]=P;e:for(var pe=0,ke=A.length,y=ke>>>1;pe<y;){var L=2*(pe+1)-1,O=A[L],Z=L+1,ee=A[Z];if(0>g(O,P))Z<ke&&0>g(ee,O)?(A[pe]=ee,A[Z]=P,pe=Z):(A[pe]=O,A[L]=P,pe=L);else if(Z<ke&&0>g(ee,P))A[pe]=ee,A[Z]=P,pe=Z;else break e}}return G}function g(A,G){var P=A.sortIndex-G.sortIndex;return P!==0?P:A.id-G.id}if(o.unstable_now=void 0,typeof performance=="object"&&typeof performance.now=="function"){var p=performance;o.unstable_now=function(){return p.now()}}else{var k=Date,U=k.now();o.unstable_now=function(){return k.now()-U}}var D=[],S=[],Y=1,B=null,W=3,$=!1,V=!1,q=!1,de=!1,I=typeof setTimeout=="function"?setTimeout:null,ue=typeof clearTimeout=="function"?clearTimeout:null,le=typeof setImmediate<"u"?setImmediate:null;function re(A){for(var G=h(S);G!==null;){if(G.callback===null)u(S);else if(G.startTime<=A)u(S),G.sortIndex=G.expirationTime,s(D,G);else break;G=h(S)}}function _(A){if(q=!1,re(A),!V)if(h(D)!==null)V=!0,X||(X=!0,Le());else{var G=h(S);G!==null&&ze(_,G.startTime-A)}}var X=!1,j=-1,ge=5,He=-1;function _e(){return de?!0:!(o.unstable_now()-He<ge)}function Ne(){if(de=!1,X){var A=o.unstable_now();He=A;var G=!0;try{e:{V=!1,q&&(q=!1,ue(j),j=-1),$=!0;var P=W;try{t:{for(re(A),B=h(D);B!==null&&!(B.expirationTime>A&&_e());){var pe=B.callback;if(typeof pe=="function"){B.callback=null,W=B.priorityLevel;var ke=pe(B.expirationTime<=A);if(A=o.unstable_now(),typeof ke=="function"){B.callback=ke,re(A),G=!0;break t}B===h(D)&&u(D),re(A)}else u(D);B=h(D)}if(B!==null)G=!0;else{var y=h(S);y!==null&&ze(_,y.startTime-A),G=!1}}break e}finally{B=null,W=P,$=!1}G=void 0}}finally{G?Le():X=!1}}}var Le;if(typeof le=="function")Le=function(){le(Ne)};else if(typeof MessageChannel<"u"){var We=new MessageChannel,Ie=We.port2;We.port1.onmessage=Ne,Le=function(){Ie.postMessage(null)}}else Le=function(){I(Ne,0)};function ze(A,G){j=I(function(){A(o.unstable_now())},G)}o.unstable_IdlePriority=5,o.unstable_ImmediatePriority=1,o.unstable_LowPriority=4,o.unstable_NormalPriority=3,o.unstable_Profiling=null,o.unstable_UserBlockingPriority=2,o.unstable_cancelCallback=function(A){A.callback=null},o.unstable_forceFrameRate=function(A){0>A||125<A?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):ge=0<A?Math.floor(1e3/A):5},o.unstable_getCurrentPriorityLevel=function(){return W},o.unstable_next=function(A){switch(W){case 1:case 2:case 3:var G=3;break;default:G=W}var P=W;W=G;try{return A()}finally{W=P}},o.unstable_requestPaint=function(){de=!0},o.unstable_runWithPriority=function(A,G){switch(A){case 1:case 2:case 3:case 4:case 5:break;default:A=3}var P=W;W=A;try{return G()}finally{W=P}},o.unstable_scheduleCallback=function(A,G,P){var pe=o.unstable_now();switch(typeof P=="object"&&P!==null?(P=P.delay,P=typeof P=="number"&&0<P?pe+P:pe):P=pe,A){case 1:var ke=-1;break;case 2:ke=250;break;case 5:ke=1073741823;break;case 4:ke=1e4;break;default:ke=5e3}return ke=P+ke,A={id:Y++,callback:G,priorityLevel:A,startTime:P,expirationTime:ke,sortIndex:-1},P>pe?(A.sortIndex=P,s(S,A),h(D)===null&&A===h(S)&&(q?(ue(j),j=-1):q=!0,ze(_,P-pe))):(A.sortIndex=ke,s(D,A),V||$||(V=!0,X||(X=!0,Le()))),A},o.unstable_shouldYield=_e,o.unstable_wrapCallback=function(A){var G=W;return function(){var P=W;W=G;try{return A.apply(this,arguments)}finally{W=P}}}})(Ls)),Ls}var th;function N1(){return th||(th=1,Rs.exports=H1()),Rs.exports}var Us={exports:{}},Lt={};var lh;function B1(){if(lh)return Lt;lh=1;var o=Gs();function s(D){var S="https://react.dev/errors/"+D;if(1<arguments.length){S+="?args[]="+encodeURIComponent(arguments[1]);for(var Y=2;Y<arguments.length;Y++)S+="&args[]="+encodeURIComponent(arguments[Y])}return"Minified React error #"+D+"; visit "+S+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function h(){}var u={d:{f:h,r:function(){throw Error(s(522))},D:h,C:h,L:h,m:h,X:h,S:h,M:h},p:0,findDOMNode:null},g=Symbol.for("react.portal");function p(D,S,Y){var B=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:g,key:B==null?null:""+B,children:D,containerInfo:S,implementation:Y}}var k=o.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function U(D,S){if(D==="font")return"";if(typeof S=="string")return S==="use-credentials"?S:""}return Lt.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=u,Lt.createPortal=function(D,S){var Y=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!S||S.nodeType!==1&&S.nodeType!==9&&S.nodeType!==11)throw Error(s(299));return p(D,S,null,Y)},Lt.flushSync=function(D){var S=k.T,Y=u.p;try{if(k.T=null,u.p=2,D)return D()}finally{k.T=S,u.p=Y,u.d.f()}},Lt.preconnect=function(D,S){typeof D=="string"&&(S?(S=S.crossOrigin,S=typeof S=="string"?S==="use-credentials"?S:"":void 0):S=null,u.d.C(D,S))},Lt.prefetchDNS=function(D){typeof D=="string"&&u.d.D(D)},Lt.preinit=function(D,S){if(typeof D=="string"&&S&&typeof S.as=="string"){var Y=S.as,B=U(Y,S.crossOrigin),W=typeof S.integrity=="string"?S.integrity:void 0,$=typeof S.fetchPriority=="string"?S.fetchPriority:void 0;Y==="style"?u.d.S(D,typeof S.precedence=="string"?S.precedence:void 0,{crossOrigin:B,integrity:W,fetchPriority:$}):Y==="script"&&u.d.X(D,{crossOrigin:B,integrity:W,fetchPriority:$,nonce:typeof S.nonce=="string"?S.nonce:void 0})}},Lt.preinitModule=function(D,S){if(typeof D=="string")if(typeof S=="object"&&S!==null){if(S.as==null||S.as==="script"){var Y=U(S.as,S.crossOrigin);u.d.M(D,{crossOrigin:Y,integrity:typeof S.integrity=="string"?S.integrity:void 0,nonce:typeof S.nonce=="string"?S.nonce:void 0})}}else S==null&&u.d.M(D)},Lt.preload=function(D,S){if(typeof D=="string"&&typeof S=="object"&&S!==null&&typeof S.as=="string"){var Y=S.as,B=U(Y,S.crossOrigin);u.d.L(D,Y,{crossOrigin:B,integrity:typeof S.integrity=="string"?S.integrity:void 0,nonce:typeof S.nonce=="string"?S.nonce:void 0,type:typeof S.type=="string"?S.type:void 0,fetchPriority:typeof S.fetchPriority=="string"?S.fetchPriority:void 0,referrerPolicy:typeof S.referrerPolicy=="string"?S.referrerPolicy:void 0,imageSrcSet:typeof S.imageSrcSet=="string"?S.imageSrcSet:void 0,imageSizes:typeof S.imageSizes=="string"?S.imageSizes:void 0,media:typeof S.media=="string"?S.media:void 0})}},Lt.preloadModule=function(D,S){if(typeof D=="string")if(S){var Y=U(S.as,S.crossOrigin);u.d.m(D,{as:typeof S.as=="string"&&S.as!=="script"?S.as:void 0,crossOrigin:Y,integrity:typeof S.integrity=="string"?S.integrity:void 0})}else u.d.m(D)},Lt.requestFormReset=function(D){u.d.r(D)},Lt.unstable_batchedUpdates=function(D,S){return D(S)},Lt.useFormState=function(D,S,Y){return k.H.useFormState(D,S,Y)},Lt.useFormStatus=function(){return k.H.useHostTransitionStatus()},Lt.version="19.2.4",Lt}var nh;function j1(){if(nh)return Us.exports;nh=1;function o(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(o)}catch(s){console.error(s)}}return o(),Us.exports=B1(),Us.exports}var ah;function q1(){if(ah)return Oi;ah=1;var o=N1(),s=Gs(),h=j1();function u(e){var t="https://react.dev/errors/"+e;if(1<arguments.length){t+="?args[]="+encodeURIComponent(arguments[1]);for(var l=2;l<arguments.length;l++)t+="&args[]="+encodeURIComponent(arguments[l])}return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function g(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function p(e){var t=e,l=e;if(e.alternate)for(;t.return;)t=t.return;else{e=t;do t=e,(t.flags&4098)!==0&&(l=t.return),e=t.return;while(e)}return t.tag===3?l:null}function k(e){if(e.tag===13){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function U(e){if(e.tag===31){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function D(e){if(p(e)!==e)throw Error(u(188))}function S(e){var t=e.alternate;if(!t){if(t=p(e),t===null)throw Error(u(188));return t!==e?null:e}for(var l=e,n=t;;){var a=l.return;if(a===null)break;var i=a.alternate;if(i===null){if(n=a.return,n!==null){l=n;continue}break}if(a.child===i.child){for(i=a.child;i;){if(i===l)return D(a),e;if(i===n)return D(a),t;i=i.sibling}throw Error(u(188))}if(l.return!==n.return)l=a,n=i;else{for(var r=!1,d=a.child;d;){if(d===l){r=!0,l=a,n=i;break}if(d===n){r=!0,n=a,l=i;break}d=d.sibling}if(!r){for(d=i.child;d;){if(d===l){r=!0,l=i,n=a;break}if(d===n){r=!0,n=i,l=a;break}d=d.sibling}if(!r)throw Error(u(189))}}if(l.alternate!==n)throw Error(u(190))}if(l.tag!==3)throw Error(u(188));return l.stateNode.current===l?e:t}function Y(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e;for(e=e.child;e!==null;){if(t=Y(e),t!==null)return t;e=e.sibling}return null}var B=Object.assign,W=Symbol.for("react.element"),$=Symbol.for("react.transitional.element"),V=Symbol.for("react.portal"),q=Symbol.for("react.fragment"),de=Symbol.for("react.strict_mode"),I=Symbol.for("react.profiler"),ue=Symbol.for("react.consumer"),le=Symbol.for("react.context"),re=Symbol.for("react.forward_ref"),_=Symbol.for("react.suspense"),X=Symbol.for("react.suspense_list"),j=Symbol.for("react.memo"),ge=Symbol.for("react.lazy"),He=Symbol.for("react.activity"),_e=Symbol.for("react.memo_cache_sentinel"),Ne=Symbol.iterator;function Le(e){return e===null||typeof e!="object"?null:(e=Ne&&e[Ne]||e["@@iterator"],typeof e=="function"?e:null)}var We=Symbol.for("react.client.reference");function Ie(e){if(e==null)return null;if(typeof e=="function")return e.$$typeof===We?null:e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case q:return"Fragment";case I:return"Profiler";case de:return"StrictMode";case _:return"Suspense";case X:return"SuspenseList";case He:return"Activity"}if(typeof e=="object")switch(e.$$typeof){case V:return"Portal";case le:return e.displayName||"Context";case ue:return(e._context.displayName||"Context")+".Consumer";case re:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case j:return t=e.displayName||null,t!==null?t:Ie(e.type)||"Memo";case ge:t=e._payload,e=e._init;try{return Ie(e(t))}catch{}}return null}var ze=Array.isArray,A=s.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,G=h.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,P={pending:!1,data:null,method:null,action:null},pe=[],ke=-1;function y(e){return{current:e}}function L(e){0>ke||(e.current=pe[ke],pe[ke]=null,ke--)}function O(e,t){ke++,pe[ke]=e.current,e.current=t}var Z=y(null),ee=y(null),Ce=y(null),Ue=y(null);function ht(e,t){switch(O(Ce,t),O(ee,e),O(Z,null),t.nodeType){case 9:case 11:e=(e=t.documentElement)&&(e=e.namespaceURI)?s0(e):0;break;default:if(e=t.tagName,t=t.namespaceURI)t=s0(t),e=u0(t,e);else switch(e){case"svg":e=1;break;case"math":e=2;break;default:e=0}}L(Z),O(Z,e)}function Ke(){L(Z),L(ee),L(Ce)}function nl(e){e.memoizedState!==null&&O(Ue,e);var t=Z.current,l=u0(t,e.type);t!==l&&(O(ee,e),O(Z,l))}function te(e){ee.current===e&&(L(Z),L(ee)),Ue.current===e&&(L(Ue),Ti._currentValue=P)}var Kt,wn;function Me(e){if(Kt===void 0)try{throw Error()}catch(l){var t=l.stack.trim().match(/\n( *(at )?)/);Kt=t&&t[1]||"",wn=-1<l.stack.indexOf(`
|
|
2
|
+
at`)?" (<anonymous>)":-1<l.stack.indexOf("@")?"@unknown:0:0":""}return`
|
|
3
|
+
`+Kt+e+wn}var St=!1;function At(e,t){if(!e||St)return"";St=!0;var l=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var n={DetermineComponentFrameRoot:function(){try{if(t){var N=function(){throw Error()};if(Object.defineProperty(N.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(N,[])}catch(E){var T=E}Reflect.construct(e,[],N)}else{try{N.call()}catch(E){T=E}e.call(N.prototype)}}else{try{throw Error()}catch(E){T=E}(N=e())&&typeof N.catch=="function"&&N.catch(function(){})}}catch(E){if(E&&T&&typeof E.stack=="string")return[E.stack,T.stack]}return[null,null]}};n.DetermineComponentFrameRoot.displayName="DetermineComponentFrameRoot";var a=Object.getOwnPropertyDescriptor(n.DetermineComponentFrameRoot,"name");a&&a.configurable&&Object.defineProperty(n.DetermineComponentFrameRoot,"name",{value:"DetermineComponentFrameRoot"});var i=n.DetermineComponentFrameRoot(),r=i[0],d=i[1];if(r&&d){var m=r.split(`
|
|
4
|
+
`),w=d.split(`
|
|
5
|
+
`);for(a=n=0;n<m.length&&!m[n].includes("DetermineComponentFrameRoot");)n++;for(;a<w.length&&!w[a].includes("DetermineComponentFrameRoot");)a++;if(n===m.length||a===w.length)for(n=m.length-1,a=w.length-1;1<=n&&0<=a&&m[n]!==w[a];)a--;for(;1<=n&&0<=a;n--,a--)if(m[n]!==w[a]){if(n!==1||a!==1)do if(n--,a--,0>a||m[n]!==w[a]){var R=`
|
|
6
|
+
`+m[n].replace(" at new "," at ");return e.displayName&&R.includes("<anonymous>")&&(R=R.replace("<anonymous>",e.displayName)),R}while(1<=n&&0<=a);break}}}finally{St=!1,Error.prepareStackTrace=l}return(l=e?e.displayName||e.name:"")?Me(l):""}function Et(e,t){switch(e.tag){case 26:case 27:case 5:return Me(e.type);case 16:return Me("Lazy");case 13:return e.child!==t&&t!==null?Me("Suspense Fallback"):Me("Suspense");case 19:return Me("SuspenseList");case 0:case 15:return At(e.type,!1);case 11:return At(e.type.render,!1);case 1:return At(e.type,!0);case 31:return Me("Activity");default:return""}}function al(e){try{var t="",l=null;do t+=Et(e,l),l=e,e=e.return;while(e);return t}catch(n){return`
|
|
7
|
+
Error generating stack: `+n.message+`
|
|
8
|
+
`+n.stack}}var ml=Object.prototype.hasOwnProperty,_l=o.unstable_scheduleCallback,gl=o.unstable_cancelCallback,Jn=o.unstable_shouldYield,Mn=o.unstable_requestPaint,Ht=o.unstable_now,hr=o.unstable_getCurrentPriorityLevel,Yi=o.unstable_ImmediatePriority,Gi=o.unstable_UserBlockingPriority,Fn=o.unstable_NormalPriority,pr=o.unstable_LowPriority,Vi=o.unstable_IdlePriority,mr=o.log,gr=o.unstable_setDisableYieldValue,Tn=null,Nt=null;function xl(e){if(typeof mr=="function"&&gr(e),Nt&&typeof Nt.setStrictMode=="function")try{Nt.setStrictMode(Tn,e)}catch{}}var Bt=Math.clz32?Math.clz32:yr,Xi=Math.log,An=Math.LN2;function yr(e){return e>>>=0,e===0?32:31-(Xi(e)/An|0)|0}var $n=256,Jt=262144,Wn=4194304;function kl(e){var t=e&42;if(t!==0)return t;switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:return e&261888;case 262144:case 524288:case 1048576:case 2097152:return e&3932160;case 4194304:case 8388608:case 16777216:case 33554432:return e&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return e}}function In(e,t,l){var n=e.pendingLanes;if(n===0)return 0;var a=0,i=e.suspendedLanes,r=e.pingedLanes;e=e.warmLanes;var d=n&134217727;return d!==0?(n=d&~i,n!==0?a=kl(n):(r&=d,r!==0?a=kl(r):l||(l=d&~e,l!==0&&(a=kl(l))))):(d=n&~i,d!==0?a=kl(d):r!==0?a=kl(r):l||(l=n&~e,l!==0&&(a=kl(l)))),a===0?0:t!==0&&t!==a&&(t&i)===0&&(i=a&-a,l=t&-t,i>=l||i===32&&(l&4194048)!==0)?t:a}function Dl(e,t){return(e.pendingLanes&~(e.suspendedLanes&~e.pingedLanes)&t)===0}function Il(e,t){switch(e){case 1:case 2:case 4:case 8:case 64:return t+250;case 16:case 32:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t+5e3;case 4194304:case 8388608:case 16777216:case 33554432:return-1;case 67108864:case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function Ol(){var e=Wn;return Wn<<=1,(Wn&62914560)===0&&(Wn=4194304),e}function Pn(e){for(var t=[],l=0;31>l;l++)t.push(e);return t}function En(e,t){e.pendingLanes|=t,t!==268435456&&(e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0)}function ve(e,t,l,n,a,i){var r=e.pendingLanes;e.pendingLanes=l,e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0,e.expiredLanes&=l,e.entangledLanes&=l,e.errorRecoveryDisabledLanes&=l,e.shellSuspendCounter=0;var d=e.entanglements,m=e.expirationTimes,w=e.hiddenUpdates;for(l=r&~l;0<l;){var R=31-Bt(l),N=1<<R;d[R]=0,m[R]=-1;var T=w[R];if(T!==null)for(w[R]=null,R=0;R<T.length;R++){var E=T[R];E!==null&&(E.lane&=-536870913)}l&=~N}n!==0&&F(e,n,0),i!==0&&a===0&&e.tag!==0&&(e.suspendedLanes|=i&~(r&~t))}function F(e,t,l){e.pendingLanes|=t,e.suspendedLanes&=~t;var n=31-Bt(t);e.entangledLanes|=t,e.entanglements[n]=e.entanglements[n]|1073741824|l&261930}function J(e,t){var l=e.entangledLanes|=t;for(e=e.entanglements;l;){var n=31-Bt(l),a=1<<n;a&t|e[n]&t&&(e[n]|=t),l&=~a}}function ce(e,t){var l=t&-t;return l=(l&42)!==0?1:Re(l),(l&(e.suspendedLanes|t))!==0?0:l}function Re(e){switch(e){case 2:e=1;break;case 8:e=4;break;case 32:e=16;break;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:e=128;break;case 268435456:e=134217728;break;default:e=0}return e}function Te(e){return e&=-e,2<e?8<e?(e&134217727)!==0?32:268435456:8:2}function Ve(){var e=G.p;return e!==0?e:(e=window.event,e===void 0?32:R0(e.type))}function De(e,t){var l=G.p;try{return G.p=e,t()}finally{G.p=l}}var se=Math.random().toString(36).slice(2),Ae="__reactFiber$"+se,me="__reactProps$"+se,Xe="__reactContainer$"+se,_n="__reactEvents$"+se,Sl="__reactListeners$"+se,vr="__reactHandles$"+se,Fs="__reactResources$"+se,Ya="__reactMarker$"+se;function br(e){delete e[Ae],delete e[me],delete e[_n],delete e[Sl],delete e[vr]}function ea(e){var t=e[Ae];if(t)return t;for(var l=e.parentNode;l;){if(t=l[Xe]||l[Ae]){if(l=t.alternate,t.child!==null||l!==null&&l.child!==null)for(e=y0(e);e!==null;){if(l=e[Ae])return l;e=y0(e)}return t}e=l,l=e.parentNode}return null}function ta(e){if(e=e[Ae]||e[Xe]){var t=e.tag;if(t===5||t===6||t===13||t===31||t===26||t===27||t===3)return e}return null}function Ga(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e.stateNode;throw Error(u(33))}function la(e){var t=e[Fs];return t||(t=e[Fs]={hoistableStyles:new Map,hoistableScripts:new Map}),t}function zt(e){e[Ya]=!0}var $s=new Set,Ws={};function kn(e,t){na(e,t),na(e+"Capture",t)}function na(e,t){for(Ws[e]=t,e=0;e<t.length;e++)$s.add(t[e])}var Eh=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]*$"),Is={},Ps={};function _h(e){return ml.call(Ps,e)?!0:ml.call(Is,e)?!1:Eh.test(e)?Ps[e]=!0:(Is[e]=!0,!1)}function Qi(e,t,l){if(_h(t))if(l===null)e.removeAttribute(t);else{switch(typeof l){case"undefined":case"function":case"symbol":e.removeAttribute(t);return;case"boolean":var n=t.toLowerCase().slice(0,5);if(n!=="data-"&&n!=="aria-"){e.removeAttribute(t);return}}e.setAttribute(t,""+l)}}function Zi(e,t,l){if(l===null)e.removeAttribute(t);else{switch(typeof l){case"undefined":case"function":case"symbol":case"boolean":e.removeAttribute(t);return}e.setAttribute(t,""+l)}}function Rl(e,t,l,n){if(n===null)e.removeAttribute(l);else{switch(typeof n){case"undefined":case"function":case"symbol":case"boolean":e.removeAttribute(l);return}e.setAttributeNS(t,l,""+n)}}function il(e){switch(typeof e){case"bigint":case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function eu(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function kh(e,t,l){var n=Object.getOwnPropertyDescriptor(e.constructor.prototype,t);if(!e.hasOwnProperty(t)&&typeof n<"u"&&typeof n.get=="function"&&typeof n.set=="function"){var a=n.get,i=n.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return a.call(this)},set:function(r){l=""+r,i.call(this,r)}}),Object.defineProperty(e,t,{enumerable:n.enumerable}),{getValue:function(){return l},setValue:function(r){l=""+r},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function xr(e){if(!e._valueTracker){var t=eu(e)?"checked":"value";e._valueTracker=kh(e,t,""+e[t])}}function tu(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var l=t.getValue(),n="";return e&&(n=eu(e)?e.checked?"true":"false":e.value),e=n,e!==l?(t.setValue(e),!0):!1}function Ki(e){if(e=e||(typeof document<"u"?document:void 0),typeof e>"u")return null;try{return e.activeElement||e.body}catch{return e.body}}var Dh=/[\n"\\]/g;function ol(e){return e.replace(Dh,function(t){return"\\"+t.charCodeAt(0).toString(16)+" "})}function Sr(e,t,l,n,a,i,r,d){e.name="",r!=null&&typeof r!="function"&&typeof r!="symbol"&&typeof r!="boolean"?e.type=r:e.removeAttribute("type"),t!=null?r==="number"?(t===0&&e.value===""||e.value!=t)&&(e.value=""+il(t)):e.value!==""+il(t)&&(e.value=""+il(t)):r!=="submit"&&r!=="reset"||e.removeAttribute("value"),t!=null?Cr(e,r,il(t)):l!=null?Cr(e,r,il(l)):n!=null&&e.removeAttribute("value"),a==null&&i!=null&&(e.defaultChecked=!!i),a!=null&&(e.checked=a&&typeof a!="function"&&typeof a!="symbol"),d!=null&&typeof d!="function"&&typeof d!="symbol"&&typeof d!="boolean"?e.name=""+il(d):e.removeAttribute("name")}function lu(e,t,l,n,a,i,r,d){if(i!=null&&typeof i!="function"&&typeof i!="symbol"&&typeof i!="boolean"&&(e.type=i),t!=null||l!=null){if(!(i!=="submit"&&i!=="reset"||t!=null)){xr(e);return}l=l!=null?""+il(l):"",t=t!=null?""+il(t):l,d||t===e.value||(e.value=t),e.defaultValue=t}n=n??a,n=typeof n!="function"&&typeof n!="symbol"&&!!n,e.checked=d?e.checked:!!n,e.defaultChecked=!!n,r!=null&&typeof r!="function"&&typeof r!="symbol"&&typeof r!="boolean"&&(e.name=r),xr(e)}function Cr(e,t,l){t==="number"&&Ki(e.ownerDocument)===e||e.defaultValue===""+l||(e.defaultValue=""+l)}function aa(e,t,l,n){if(e=e.options,t){t={};for(var a=0;a<l.length;a++)t["$"+l[a]]=!0;for(l=0;l<e.length;l++)a=t.hasOwnProperty("$"+e[l].value),e[l].selected!==a&&(e[l].selected=a),a&&n&&(e[l].defaultSelected=!0)}else{for(l=""+il(l),t=null,a=0;a<e.length;a++){if(e[a].value===l){e[a].selected=!0,n&&(e[a].defaultSelected=!0);return}t!==null||e[a].disabled||(t=e[a])}t!==null&&(t.selected=!0)}}function nu(e,t,l){if(t!=null&&(t=""+il(t),t!==e.value&&(e.value=t),l==null)){e.defaultValue!==t&&(e.defaultValue=t);return}e.defaultValue=l!=null?""+il(l):""}function au(e,t,l,n){if(t==null){if(n!=null){if(l!=null)throw Error(u(92));if(ze(n)){if(1<n.length)throw Error(u(93));n=n[0]}l=n}l==null&&(l=""),t=l}l=il(t),e.defaultValue=l,n=e.textContent,n===l&&n!==""&&n!==null&&(e.value=n),xr(e)}function ia(e,t){if(t){var l=e.firstChild;if(l&&l===e.lastChild&&l.nodeType===3){l.nodeValue=t;return}}e.textContent=t}var Oh=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 iu(e,t,l){var n=t.indexOf("--")===0;l==null||typeof l=="boolean"||l===""?n?e.setProperty(t,""):t==="float"?e.cssFloat="":e[t]="":n?e.setProperty(t,l):typeof l!="number"||l===0||Oh.has(t)?t==="float"?e.cssFloat=l:e[t]=(""+l).trim():e[t]=l+"px"}function ou(e,t,l){if(t!=null&&typeof t!="object")throw Error(u(62));if(e=e.style,l!=null){for(var n in l)!l.hasOwnProperty(n)||t!=null&&t.hasOwnProperty(n)||(n.indexOf("--")===0?e.setProperty(n,""):n==="float"?e.cssFloat="":e[n]="");for(var a in t)n=t[a],t.hasOwnProperty(a)&&l[a]!==n&&iu(e,a,n)}else for(var i in t)t.hasOwnProperty(i)&&iu(e,i,t[i])}function zr(e){if(e.indexOf("-")===-1)return!1;switch(e){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var Rh=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"]]),Lh=/^[\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 Ji(e){return Lh.test(""+e)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":e}function Ll(){}var wr=null;function Mr(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var oa=null,ra=null;function ru(e){var t=ta(e);if(t&&(e=t.stateNode)){var l=e[me]||null;e:switch(e=t.stateNode,t.type){case"input":if(Sr(e,l.value,l.defaultValue,l.defaultValue,l.checked,l.defaultChecked,l.type,l.name),t=l.name,l.type==="radio"&&t!=null){for(l=e;l.parentNode;)l=l.parentNode;for(l=l.querySelectorAll('input[name="'+ol(""+t)+'"][type="radio"]'),t=0;t<l.length;t++){var n=l[t];if(n!==e&&n.form===e.form){var a=n[me]||null;if(!a)throw Error(u(90));Sr(n,a.value,a.defaultValue,a.defaultValue,a.checked,a.defaultChecked,a.type,a.name)}}for(t=0;t<l.length;t++)n=l[t],n.form===e.form&&tu(n)}break e;case"textarea":nu(e,l.value,l.defaultValue);break e;case"select":t=l.value,t!=null&&aa(e,!!l.multiple,t,!1)}}}var Tr=!1;function cu(e,t,l){if(Tr)return e(t,l);Tr=!0;try{var n=e(t);return n}finally{if(Tr=!1,(oa!==null||ra!==null)&&(Ho(),oa&&(t=oa,e=ra,ra=oa=null,ru(t),e)))for(t=0;t<e.length;t++)ru(e[t])}}function Va(e,t){var l=e.stateNode;if(l===null)return null;var n=l[me]||null;if(n===null)return null;l=n[t];e:switch(t){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(n=!n.disabled)||(e=e.type,n=!(e==="button"||e==="input"||e==="select"||e==="textarea")),e=!n;break e;default:e=!1}if(e)return null;if(l&&typeof l!="function")throw Error(u(231,t,typeof l));return l}var Ul=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),Ar=!1;if(Ul)try{var Xa={};Object.defineProperty(Xa,"passive",{get:function(){Ar=!0}}),window.addEventListener("test",Xa,Xa),window.removeEventListener("test",Xa,Xa)}catch{Ar=!1}var Pl=null,Er=null,Fi=null;function su(){if(Fi)return Fi;var e,t=Er,l=t.length,n,a="value"in Pl?Pl.value:Pl.textContent,i=a.length;for(e=0;e<l&&t[e]===a[e];e++);var r=l-e;for(n=1;n<=r&&t[l-n]===a[i-n];n++);return Fi=a.slice(e,1<n?1-n:void 0)}function $i(e){var t=e.keyCode;return"charCode"in e?(e=e.charCode,e===0&&t===13&&(e=13)):e=t,e===10&&(e=13),32<=e||e===13?e:0}function Wi(){return!0}function uu(){return!1}function qt(e){function t(l,n,a,i,r){this._reactName=l,this._targetInst=a,this.type=n,this.nativeEvent=i,this.target=r,this.currentTarget=null;for(var d in e)e.hasOwnProperty(d)&&(l=e[d],this[d]=l?l(i):i[d]);return this.isDefaultPrevented=(i.defaultPrevented!=null?i.defaultPrevented:i.returnValue===!1)?Wi:uu,this.isPropagationStopped=uu,this}return B(t.prototype,{preventDefault:function(){this.defaultPrevented=!0;var l=this.nativeEvent;l&&(l.preventDefault?l.preventDefault():typeof l.returnValue!="unknown"&&(l.returnValue=!1),this.isDefaultPrevented=Wi)},stopPropagation:function(){var l=this.nativeEvent;l&&(l.stopPropagation?l.stopPropagation():typeof l.cancelBubble!="unknown"&&(l.cancelBubble=!0),this.isPropagationStopped=Wi)},persist:function(){},isPersistent:Wi}),t}var Dn={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},Ii=qt(Dn),Qa=B({},Dn,{view:0,detail:0}),Uh=qt(Qa),_r,kr,Za,Pi=B({},Qa,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:Or,button:0,buttons:0,relatedTarget:function(e){return e.relatedTarget===void 0?e.fromElement===e.srcElement?e.toElement:e.fromElement:e.relatedTarget},movementX:function(e){return"movementX"in e?e.movementX:(e!==Za&&(Za&&e.type==="mousemove"?(_r=e.screenX-Za.screenX,kr=e.screenY-Za.screenY):kr=_r=0,Za=e),_r)},movementY:function(e){return"movementY"in e?e.movementY:kr}}),fu=qt(Pi),Hh=B({},Pi,{dataTransfer:0}),Nh=qt(Hh),Bh=B({},Qa,{relatedTarget:0}),Dr=qt(Bh),jh=B({},Dn,{animationName:0,elapsedTime:0,pseudoElement:0}),qh=qt(jh),Yh=B({},Dn,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),Gh=qt(Yh),Vh=B({},Dn,{data:0}),du=qt(Vh),Xh={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},Qh={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"},Zh={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function Kh(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=Zh[e])?!!t[e]:!1}function Or(){return Kh}var Jh=B({},Qa,{key:function(e){if(e.key){var t=Xh[e.key]||e.key;if(t!=="Unidentified")return t}return e.type==="keypress"?(e=$i(e),e===13?"Enter":String.fromCharCode(e)):e.type==="keydown"||e.type==="keyup"?Qh[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:Or,charCode:function(e){return e.type==="keypress"?$i(e):0},keyCode:function(e){return e.type==="keydown"||e.type==="keyup"?e.keyCode:0},which:function(e){return e.type==="keypress"?$i(e):e.type==="keydown"||e.type==="keyup"?e.keyCode:0}}),Fh=qt(Jh),$h=B({},Pi,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),hu=qt($h),Wh=B({},Qa,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:Or}),Ih=qt(Wh),Ph=B({},Dn,{propertyName:0,elapsedTime:0,pseudoElement:0}),ep=qt(Ph),tp=B({},Pi,{deltaX:function(e){return"deltaX"in e?e.deltaX:"wheelDeltaX"in e?-e.wheelDeltaX:0},deltaY:function(e){return"deltaY"in e?e.deltaY:"wheelDeltaY"in e?-e.wheelDeltaY:"wheelDelta"in e?-e.wheelDelta:0},deltaZ:0,deltaMode:0}),lp=qt(tp),np=B({},Dn,{newState:0,oldState:0}),ap=qt(np),ip=[9,13,27,32],Rr=Ul&&"CompositionEvent"in window,Ka=null;Ul&&"documentMode"in document&&(Ka=document.documentMode);var op=Ul&&"TextEvent"in window&&!Ka,pu=Ul&&(!Rr||Ka&&8<Ka&&11>=Ka),mu=" ",gu=!1;function yu(e,t){switch(e){case"keyup":return ip.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function vu(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var ca=!1;function rp(e,t){switch(e){case"compositionend":return vu(t);case"keypress":return t.which!==32?null:(gu=!0,mu);case"textInput":return e=t.data,e===mu&&gu?null:e;default:return null}}function cp(e,t){if(ca)return e==="compositionend"||!Rr&&yu(e,t)?(e=su(),Fi=Er=Pl=null,ca=!1,e):null;switch(e){case"paste":return null;case"keypress":if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1<t.char.length)return t.char;if(t.which)return String.fromCharCode(t.which)}return null;case"compositionend":return pu&&t.locale!=="ko"?null:t.data;default:return null}}var sp={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 bu(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t==="input"?!!sp[e.type]:t==="textarea"}function xu(e,t,l,n){oa?ra?ra.push(n):ra=[n]:oa=n,t=Vo(t,"onChange"),0<t.length&&(l=new Ii("onChange","change",null,l,n),e.push({event:l,listeners:t}))}var Ja=null,Fa=null;function up(e){n0(e,0)}function eo(e){var t=Ga(e);if(tu(t))return e}function Su(e,t){if(e==="change")return t}var Cu=!1;if(Ul){var Lr;if(Ul){var Ur="oninput"in document;if(!Ur){var zu=document.createElement("div");zu.setAttribute("oninput","return;"),Ur=typeof zu.oninput=="function"}Lr=Ur}else Lr=!1;Cu=Lr&&(!document.documentMode||9<document.documentMode)}function wu(){Ja&&(Ja.detachEvent("onpropertychange",Mu),Fa=Ja=null)}function Mu(e){if(e.propertyName==="value"&&eo(Fa)){var t=[];xu(t,Fa,e,Mr(e)),cu(up,t)}}function fp(e,t,l){e==="focusin"?(wu(),Ja=t,Fa=l,Ja.attachEvent("onpropertychange",Mu)):e==="focusout"&&wu()}function dp(e){if(e==="selectionchange"||e==="keyup"||e==="keydown")return eo(Fa)}function hp(e,t){if(e==="click")return eo(t)}function pp(e,t){if(e==="input"||e==="change")return eo(t)}function mp(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var Ft=typeof Object.is=="function"?Object.is:mp;function $a(e,t){if(Ft(e,t))return!0;if(typeof e!="object"||e===null||typeof t!="object"||t===null)return!1;var l=Object.keys(e),n=Object.keys(t);if(l.length!==n.length)return!1;for(n=0;n<l.length;n++){var a=l[n];if(!ml.call(t,a)||!Ft(e[a],t[a]))return!1}return!0}function Tu(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function Au(e,t){var l=Tu(e);e=0;for(var n;l;){if(l.nodeType===3){if(n=e+l.textContent.length,e<=t&&n>=t)return{node:l,offset:t-e};e=n}e:{for(;l;){if(l.nextSibling){l=l.nextSibling;break e}l=l.parentNode}l=void 0}l=Tu(l)}}function Eu(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?Eu(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function _u(e){e=e!=null&&e.ownerDocument!=null&&e.ownerDocument.defaultView!=null?e.ownerDocument.defaultView:window;for(var t=Ki(e.document);t instanceof e.HTMLIFrameElement;){try{var l=typeof t.contentWindow.location.href=="string"}catch{l=!1}if(l)e=t.contentWindow;else break;t=Ki(e.document)}return t}function Hr(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t==="input"&&(e.type==="text"||e.type==="search"||e.type==="tel"||e.type==="url"||e.type==="password")||t==="textarea"||e.contentEditable==="true")}var gp=Ul&&"documentMode"in document&&11>=document.documentMode,sa=null,Nr=null,Wa=null,Br=!1;function ku(e,t,l){var n=l.window===l?l.document:l.nodeType===9?l:l.ownerDocument;Br||sa==null||sa!==Ki(n)||(n=sa,"selectionStart"in n&&Hr(n)?n={start:n.selectionStart,end:n.selectionEnd}:(n=(n.ownerDocument&&n.ownerDocument.defaultView||window).getSelection(),n={anchorNode:n.anchorNode,anchorOffset:n.anchorOffset,focusNode:n.focusNode,focusOffset:n.focusOffset}),Wa&&$a(Wa,n)||(Wa=n,n=Vo(Nr,"onSelect"),0<n.length&&(t=new Ii("onSelect","select",null,t,l),e.push({event:t,listeners:n}),t.target=sa)))}function On(e,t){var l={};return l[e.toLowerCase()]=t.toLowerCase(),l["Webkit"+e]="webkit"+t,l["Moz"+e]="moz"+t,l}var ua={animationend:On("Animation","AnimationEnd"),animationiteration:On("Animation","AnimationIteration"),animationstart:On("Animation","AnimationStart"),transitionrun:On("Transition","TransitionRun"),transitionstart:On("Transition","TransitionStart"),transitioncancel:On("Transition","TransitionCancel"),transitionend:On("Transition","TransitionEnd")},jr={},Du={};Ul&&(Du=document.createElement("div").style,"AnimationEvent"in window||(delete ua.animationend.animation,delete ua.animationiteration.animation,delete ua.animationstart.animation),"TransitionEvent"in window||delete ua.transitionend.transition);function Rn(e){if(jr[e])return jr[e];if(!ua[e])return e;var t=ua[e],l;for(l in t)if(t.hasOwnProperty(l)&&l in Du)return jr[e]=t[l];return e}var Ou=Rn("animationend"),Ru=Rn("animationiteration"),Lu=Rn("animationstart"),yp=Rn("transitionrun"),vp=Rn("transitionstart"),bp=Rn("transitioncancel"),Uu=Rn("transitionend"),Hu=new Map,qr="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(" ");qr.push("scrollEnd");function yl(e,t){Hu.set(e,t),kn(t,[e])}var to=typeof reportError=="function"?reportError:function(e){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var t=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof e=="object"&&e!==null&&typeof e.message=="string"?String(e.message):String(e),error:e});if(!window.dispatchEvent(t))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",e);return}console.error(e)},rl=[],fa=0,Yr=0;function lo(){for(var e=fa,t=Yr=fa=0;t<e;){var l=rl[t];rl[t++]=null;var n=rl[t];rl[t++]=null;var a=rl[t];rl[t++]=null;var i=rl[t];if(rl[t++]=null,n!==null&&a!==null){var r=n.pending;r===null?a.next=a:(a.next=r.next,r.next=a),n.pending=a}i!==0&&Nu(l,a,i)}}function no(e,t,l,n){rl[fa++]=e,rl[fa++]=t,rl[fa++]=l,rl[fa++]=n,Yr|=n,e.lanes|=n,e=e.alternate,e!==null&&(e.lanes|=n)}function Gr(e,t,l,n){return no(e,t,l,n),ao(e)}function Ln(e,t){return no(e,null,null,t),ao(e)}function Nu(e,t,l){e.lanes|=l;var n=e.alternate;n!==null&&(n.lanes|=l);for(var a=!1,i=e.return;i!==null;)i.childLanes|=l,n=i.alternate,n!==null&&(n.childLanes|=l),i.tag===22&&(e=i.stateNode,e===null||e._visibility&1||(a=!0)),e=i,i=i.return;return e.tag===3?(i=e.stateNode,a&&t!==null&&(a=31-Bt(l),e=i.hiddenUpdates,n=e[a],n===null?e[a]=[t]:n.push(t),t.lane=l|536870912),i):null}function ao(e){if(50<bi)throw bi=0,Wc=null,Error(u(185));for(var t=e.return;t!==null;)e=t,t=e.return;return e.tag===3?e.stateNode:null}var da={};function xp(e,t,l,n){this.tag=e,this.key=l,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=n,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function $t(e,t,l,n){return new xp(e,t,l,n)}function Vr(e){return e=e.prototype,!(!e||!e.isReactComponent)}function Hl(e,t){var l=e.alternate;return l===null?(l=$t(e.tag,t,e.key,e.mode),l.elementType=e.elementType,l.type=e.type,l.stateNode=e.stateNode,l.alternate=e,e.alternate=l):(l.pendingProps=t,l.type=e.type,l.flags=0,l.subtreeFlags=0,l.deletions=null),l.flags=e.flags&65011712,l.childLanes=e.childLanes,l.lanes=e.lanes,l.child=e.child,l.memoizedProps=e.memoizedProps,l.memoizedState=e.memoizedState,l.updateQueue=e.updateQueue,t=e.dependencies,l.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},l.sibling=e.sibling,l.index=e.index,l.ref=e.ref,l.refCleanup=e.refCleanup,l}function Bu(e,t){e.flags&=65011714;var l=e.alternate;return l===null?(e.childLanes=0,e.lanes=t,e.child=null,e.subtreeFlags=0,e.memoizedProps=null,e.memoizedState=null,e.updateQueue=null,e.dependencies=null,e.stateNode=null):(e.childLanes=l.childLanes,e.lanes=l.lanes,e.child=l.child,e.subtreeFlags=0,e.deletions=null,e.memoizedProps=l.memoizedProps,e.memoizedState=l.memoizedState,e.updateQueue=l.updateQueue,e.type=l.type,t=l.dependencies,e.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext}),e}function io(e,t,l,n,a,i){var r=0;if(n=e,typeof e=="function")Vr(e)&&(r=1);else if(typeof e=="string")r=Mm(e,l,Z.current)?26:e==="html"||e==="head"||e==="body"?27:5;else e:switch(e){case He:return e=$t(31,l,t,a),e.elementType=He,e.lanes=i,e;case q:return Un(l.children,a,i,t);case de:r=8,a|=24;break;case I:return e=$t(12,l,t,a|2),e.elementType=I,e.lanes=i,e;case _:return e=$t(13,l,t,a),e.elementType=_,e.lanes=i,e;case X:return e=$t(19,l,t,a),e.elementType=X,e.lanes=i,e;default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case le:r=10;break e;case ue:r=9;break e;case re:r=11;break e;case j:r=14;break e;case ge:r=16,n=null;break e}r=29,l=Error(u(130,e===null?"null":typeof e,"")),n=null}return t=$t(r,l,t,a),t.elementType=e,t.type=n,t.lanes=i,t}function Un(e,t,l,n){return e=$t(7,e,n,t),e.lanes=l,e}function Xr(e,t,l){return e=$t(6,e,null,t),e.lanes=l,e}function ju(e){var t=$t(18,null,null,0);return t.stateNode=e,t}function Qr(e,t,l){return t=$t(4,e.children!==null?e.children:[],e.key,t),t.lanes=l,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}var qu=new WeakMap;function cl(e,t){if(typeof e=="object"&&e!==null){var l=qu.get(e);return l!==void 0?l:(t={value:e,source:t,stack:al(t)},qu.set(e,t),t)}return{value:e,source:t,stack:al(t)}}var ha=[],pa=0,oo=null,Ia=0,sl=[],ul=0,en=null,Cl=1,zl="";function Nl(e,t){ha[pa++]=Ia,ha[pa++]=oo,oo=e,Ia=t}function Yu(e,t,l){sl[ul++]=Cl,sl[ul++]=zl,sl[ul++]=en,en=e;var n=Cl;e=zl;var a=32-Bt(n)-1;n&=~(1<<a),l+=1;var i=32-Bt(t)+a;if(30<i){var r=a-a%5;i=(n&(1<<r)-1).toString(32),n>>=r,a-=r,Cl=1<<32-Bt(t)+a|l<<a|n,zl=i+e}else Cl=1<<i|l<<a|n,zl=e}function Zr(e){e.return!==null&&(Nl(e,1),Yu(e,1,0))}function Kr(e){for(;e===oo;)oo=ha[--pa],ha[pa]=null,Ia=ha[--pa],ha[pa]=null;for(;e===en;)en=sl[--ul],sl[ul]=null,zl=sl[--ul],sl[ul]=null,Cl=sl[--ul],sl[ul]=null}function Gu(e,t){sl[ul++]=Cl,sl[ul++]=zl,sl[ul++]=en,Cl=t.id,zl=t.overflow,en=e}var _t=null,rt=null,Ge=!1,tn=null,fl=!1,Jr=Error(u(519));function ln(e){var t=Error(u(418,1<arguments.length&&arguments[1]!==void 0&&arguments[1]?"text":"HTML",""));throw Pa(cl(t,e)),Jr}function Vu(e){var t=e.stateNode,l=e.type,n=e.memoizedProps;switch(t[Ae]=e,t[me]=n,l){case"dialog":je("cancel",t),je("close",t);break;case"iframe":case"object":case"embed":je("load",t);break;case"video":case"audio":for(l=0;l<Si.length;l++)je(Si[l],t);break;case"source":je("error",t);break;case"img":case"image":case"link":je("error",t),je("load",t);break;case"details":je("toggle",t);break;case"input":je("invalid",t),lu(t,n.value,n.defaultValue,n.checked,n.defaultChecked,n.type,n.name,!0);break;case"select":je("invalid",t);break;case"textarea":je("invalid",t),au(t,n.value,n.defaultValue,n.children)}l=n.children,typeof l!="string"&&typeof l!="number"&&typeof l!="bigint"||t.textContent===""+l||n.suppressHydrationWarning===!0||r0(t.textContent,l)?(n.popover!=null&&(je("beforetoggle",t),je("toggle",t)),n.onScroll!=null&&je("scroll",t),n.onScrollEnd!=null&&je("scrollend",t),n.onClick!=null&&(t.onclick=Ll),t=!0):t=!1,t||ln(e,!0)}function Xu(e){for(_t=e.return;_t;)switch(_t.tag){case 5:case 31:case 13:fl=!1;return;case 27:case 3:fl=!0;return;default:_t=_t.return}}function ma(e){if(e!==_t)return!1;if(!Ge)return Xu(e),Ge=!0,!1;var t=e.tag,l;if((l=t!==3&&t!==27)&&((l=t===5)&&(l=e.type,l=!(l!=="form"&&l!=="button")||ds(e.type,e.memoizedProps)),l=!l),l&&rt&&ln(e),Xu(e),t===13){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(u(317));rt=g0(e)}else if(t===31){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(u(317));rt=g0(e)}else t===27?(t=rt,yn(e.type)?(e=ys,ys=null,rt=e):rt=t):rt=_t?hl(e.stateNode.nextSibling):null;return!0}function Hn(){rt=_t=null,Ge=!1}function Fr(){var e=tn;return e!==null&&(Xt===null?Xt=e:Xt.push.apply(Xt,e),tn=null),e}function Pa(e){tn===null?tn=[e]:tn.push(e)}var $r=y(null),Nn=null,Bl=null;function nn(e,t,l){O($r,t._currentValue),t._currentValue=l}function jl(e){e._currentValue=$r.current,L($r)}function Wr(e,t,l){for(;e!==null;){var n=e.alternate;if((e.childLanes&t)!==t?(e.childLanes|=t,n!==null&&(n.childLanes|=t)):n!==null&&(n.childLanes&t)!==t&&(n.childLanes|=t),e===l)break;e=e.return}}function Ir(e,t,l,n){var a=e.child;for(a!==null&&(a.return=e);a!==null;){var i=a.dependencies;if(i!==null){var r=a.child;i=i.firstContext;e:for(;i!==null;){var d=i;i=a;for(var m=0;m<t.length;m++)if(d.context===t[m]){i.lanes|=l,d=i.alternate,d!==null&&(d.lanes|=l),Wr(i.return,l,e),n||(r=null);break e}i=d.next}}else if(a.tag===18){if(r=a.return,r===null)throw Error(u(341));r.lanes|=l,i=r.alternate,i!==null&&(i.lanes|=l),Wr(r,l,e),r=null}else r=a.child;if(r!==null)r.return=a;else for(r=a;r!==null;){if(r===e){r=null;break}if(a=r.sibling,a!==null){a.return=r.return,r=a;break}r=r.return}a=r}}function ga(e,t,l,n){e=null;for(var a=t,i=!1;a!==null;){if(!i){if((a.flags&524288)!==0)i=!0;else if((a.flags&262144)!==0)break}if(a.tag===10){var r=a.alternate;if(r===null)throw Error(u(387));if(r=r.memoizedProps,r!==null){var d=a.type;Ft(a.pendingProps.value,r.value)||(e!==null?e.push(d):e=[d])}}else if(a===Ue.current){if(r=a.alternate,r===null)throw Error(u(387));r.memoizedState.memoizedState!==a.memoizedState.memoizedState&&(e!==null?e.push(Ti):e=[Ti])}a=a.return}e!==null&&Ir(t,e,l,n),t.flags|=262144}function ro(e){for(e=e.firstContext;e!==null;){if(!Ft(e.context._currentValue,e.memoizedValue))return!0;e=e.next}return!1}function Bn(e){Nn=e,Bl=null,e=e.dependencies,e!==null&&(e.firstContext=null)}function kt(e){return Qu(Nn,e)}function co(e,t){return Nn===null&&Bn(e),Qu(e,t)}function Qu(e,t){var l=t._currentValue;if(t={context:t,memoizedValue:l,next:null},Bl===null){if(e===null)throw Error(u(308));Bl=t,e.dependencies={lanes:0,firstContext:t},e.flags|=524288}else Bl=Bl.next=t;return l}var Sp=typeof AbortController<"u"?AbortController:function(){var e=[],t=this.signal={aborted:!1,addEventListener:function(l,n){e.push(n)}};this.abort=function(){t.aborted=!0,e.forEach(function(l){return l()})}},Cp=o.unstable_scheduleCallback,zp=o.unstable_NormalPriority,gt={$$typeof:le,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function Pr(){return{controller:new Sp,data:new Map,refCount:0}}function ei(e){e.refCount--,e.refCount===0&&Cp(zp,function(){e.controller.abort()})}var ti=null,ec=0,ya=0,va=null;function wp(e,t){if(ti===null){var l=ti=[];ec=0,ya=ns(),va={status:"pending",value:void 0,then:function(n){l.push(n)}}}return ec++,t.then(Zu,Zu),t}function Zu(){if(--ec===0&&ti!==null){va!==null&&(va.status="fulfilled");var e=ti;ti=null,ya=0,va=null;for(var t=0;t<e.length;t++)(0,e[t])()}}function Mp(e,t){var l=[],n={status:"pending",value:null,reason:null,then:function(a){l.push(a)}};return e.then(function(){n.status="fulfilled",n.value=t;for(var a=0;a<l.length;a++)(0,l[a])(t)},function(a){for(n.status="rejected",n.reason=a,a=0;a<l.length;a++)(0,l[a])(void 0)}),n}var Ku=A.S;A.S=function(e,t){Dd=Ht(),typeof t=="object"&&t!==null&&typeof t.then=="function"&&wp(e,t),Ku!==null&&Ku(e,t)};var jn=y(null);function tc(){var e=jn.current;return e!==null?e:it.pooledCache}function so(e,t){t===null?O(jn,jn.current):O(jn,t.pool)}function Ju(){var e=tc();return e===null?null:{parent:gt._currentValue,pool:e}}var ba=Error(u(460)),lc=Error(u(474)),uo=Error(u(542)),fo={then:function(){}};function Fu(e){return e=e.status,e==="fulfilled"||e==="rejected"}function $u(e,t,l){switch(l=e[l],l===void 0?e.push(t):l!==t&&(t.then(Ll,Ll),t=l),t.status){case"fulfilled":return t.value;case"rejected":throw e=t.reason,Iu(e),e;default:if(typeof t.status=="string")t.then(Ll,Ll);else{if(e=it,e!==null&&100<e.shellSuspendCounter)throw Error(u(482));e=t,e.status="pending",e.then(function(n){if(t.status==="pending"){var a=t;a.status="fulfilled",a.value=n}},function(n){if(t.status==="pending"){var a=t;a.status="rejected",a.reason=n}})}switch(t.status){case"fulfilled":return t.value;case"rejected":throw e=t.reason,Iu(e),e}throw Yn=t,ba}}function qn(e){try{var t=e._init;return t(e._payload)}catch(l){throw l!==null&&typeof l=="object"&&typeof l.then=="function"?(Yn=l,ba):l}}var Yn=null;function Wu(){if(Yn===null)throw Error(u(459));var e=Yn;return Yn=null,e}function Iu(e){if(e===ba||e===uo)throw Error(u(483))}var xa=null,li=0;function ho(e){var t=li;return li+=1,xa===null&&(xa=[]),$u(xa,e,t)}function ni(e,t){t=t.props.ref,e.ref=t!==void 0?t:null}function po(e,t){throw t.$$typeof===W?Error(u(525)):(e=Object.prototype.toString.call(t),Error(u(31,e==="[object Object]"?"object with keys {"+Object.keys(t).join(", ")+"}":e)))}function Pu(e){function t(C,v){if(e){var z=C.deletions;z===null?(C.deletions=[v],C.flags|=16):z.push(v)}}function l(C,v){if(!e)return null;for(;v!==null;)t(C,v),v=v.sibling;return null}function n(C){for(var v=new Map;C!==null;)C.key!==null?v.set(C.key,C):v.set(C.index,C),C=C.sibling;return v}function a(C,v){return C=Hl(C,v),C.index=0,C.sibling=null,C}function i(C,v,z){return C.index=z,e?(z=C.alternate,z!==null?(z=z.index,z<v?(C.flags|=67108866,v):z):(C.flags|=67108866,v)):(C.flags|=1048576,v)}function r(C){return e&&C.alternate===null&&(C.flags|=67108866),C}function d(C,v,z,H){return v===null||v.tag!==6?(v=Xr(z,C.mode,H),v.return=C,v):(v=a(v,z),v.return=C,v)}function m(C,v,z,H){var he=z.type;return he===q?R(C,v,z.props.children,H,z.key):v!==null&&(v.elementType===he||typeof he=="object"&&he!==null&&he.$$typeof===ge&&qn(he)===v.type)?(v=a(v,z.props),ni(v,z),v.return=C,v):(v=io(z.type,z.key,z.props,null,C.mode,H),ni(v,z),v.return=C,v)}function w(C,v,z,H){return v===null||v.tag!==4||v.stateNode.containerInfo!==z.containerInfo||v.stateNode.implementation!==z.implementation?(v=Qr(z,C.mode,H),v.return=C,v):(v=a(v,z.children||[]),v.return=C,v)}function R(C,v,z,H,he){return v===null||v.tag!==7?(v=Un(z,C.mode,H,he),v.return=C,v):(v=a(v,z),v.return=C,v)}function N(C,v,z){if(typeof v=="string"&&v!==""||typeof v=="number"||typeof v=="bigint")return v=Xr(""+v,C.mode,z),v.return=C,v;if(typeof v=="object"&&v!==null){switch(v.$$typeof){case $:return z=io(v.type,v.key,v.props,null,C.mode,z),ni(z,v),z.return=C,z;case V:return v=Qr(v,C.mode,z),v.return=C,v;case ge:return v=qn(v),N(C,v,z)}if(ze(v)||Le(v))return v=Un(v,C.mode,z,null),v.return=C,v;if(typeof v.then=="function")return N(C,ho(v),z);if(v.$$typeof===le)return N(C,co(C,v),z);po(C,v)}return null}function T(C,v,z,H){var he=v!==null?v.key:null;if(typeof z=="string"&&z!==""||typeof z=="number"||typeof z=="bigint")return he!==null?null:d(C,v,""+z,H);if(typeof z=="object"&&z!==null){switch(z.$$typeof){case $:return z.key===he?m(C,v,z,H):null;case V:return z.key===he?w(C,v,z,H):null;case ge:return z=qn(z),T(C,v,z,H)}if(ze(z)||Le(z))return he!==null?null:R(C,v,z,H,null);if(typeof z.then=="function")return T(C,v,ho(z),H);if(z.$$typeof===le)return T(C,v,co(C,z),H);po(C,z)}return null}function E(C,v,z,H,he){if(typeof H=="string"&&H!==""||typeof H=="number"||typeof H=="bigint")return C=C.get(z)||null,d(v,C,""+H,he);if(typeof H=="object"&&H!==null){switch(H.$$typeof){case $:return C=C.get(H.key===null?z:H.key)||null,m(v,C,H,he);case V:return C=C.get(H.key===null?z:H.key)||null,w(v,C,H,he);case ge:return H=qn(H),E(C,v,z,H,he)}if(ze(H)||Le(H))return C=C.get(z)||null,R(v,C,H,he,null);if(typeof H.then=="function")return E(C,v,z,ho(H),he);if(H.$$typeof===le)return E(C,v,z,co(v,H),he);po(v,H)}return null}function ne(C,v,z,H){for(var he=null,Qe=null,oe=v,Oe=v=0,Ye=null;oe!==null&&Oe<z.length;Oe++){oe.index>Oe?(Ye=oe,oe=null):Ye=oe.sibling;var Ze=T(C,oe,z[Oe],H);if(Ze===null){oe===null&&(oe=Ye);break}e&&oe&&Ze.alternate===null&&t(C,oe),v=i(Ze,v,Oe),Qe===null?he=Ze:Qe.sibling=Ze,Qe=Ze,oe=Ye}if(Oe===z.length)return l(C,oe),Ge&&Nl(C,Oe),he;if(oe===null){for(;Oe<z.length;Oe++)oe=N(C,z[Oe],H),oe!==null&&(v=i(oe,v,Oe),Qe===null?he=oe:Qe.sibling=oe,Qe=oe);return Ge&&Nl(C,Oe),he}for(oe=n(oe);Oe<z.length;Oe++)Ye=E(oe,C,Oe,z[Oe],H),Ye!==null&&(e&&Ye.alternate!==null&&oe.delete(Ye.key===null?Oe:Ye.key),v=i(Ye,v,Oe),Qe===null?he=Ye:Qe.sibling=Ye,Qe=Ye);return e&&oe.forEach(function(Cn){return t(C,Cn)}),Ge&&Nl(C,Oe),he}function ye(C,v,z,H){if(z==null)throw Error(u(151));for(var he=null,Qe=null,oe=v,Oe=v=0,Ye=null,Ze=z.next();oe!==null&&!Ze.done;Oe++,Ze=z.next()){oe.index>Oe?(Ye=oe,oe=null):Ye=oe.sibling;var Cn=T(C,oe,Ze.value,H);if(Cn===null){oe===null&&(oe=Ye);break}e&&oe&&Cn.alternate===null&&t(C,oe),v=i(Cn,v,Oe),Qe===null?he=Cn:Qe.sibling=Cn,Qe=Cn,oe=Ye}if(Ze.done)return l(C,oe),Ge&&Nl(C,Oe),he;if(oe===null){for(;!Ze.done;Oe++,Ze=z.next())Ze=N(C,Ze.value,H),Ze!==null&&(v=i(Ze,v,Oe),Qe===null?he=Ze:Qe.sibling=Ze,Qe=Ze);return Ge&&Nl(C,Oe),he}for(oe=n(oe);!Ze.done;Oe++,Ze=z.next())Ze=E(oe,C,Oe,Ze.value,H),Ze!==null&&(e&&Ze.alternate!==null&&oe.delete(Ze.key===null?Oe:Ze.key),v=i(Ze,v,Oe),Qe===null?he=Ze:Qe.sibling=Ze,Qe=Ze);return e&&oe.forEach(function(Hm){return t(C,Hm)}),Ge&&Nl(C,Oe),he}function at(C,v,z,H){if(typeof z=="object"&&z!==null&&z.type===q&&z.key===null&&(z=z.props.children),typeof z=="object"&&z!==null){switch(z.$$typeof){case $:e:{for(var he=z.key;v!==null;){if(v.key===he){if(he=z.type,he===q){if(v.tag===7){l(C,v.sibling),H=a(v,z.props.children),H.return=C,C=H;break e}}else if(v.elementType===he||typeof he=="object"&&he!==null&&he.$$typeof===ge&&qn(he)===v.type){l(C,v.sibling),H=a(v,z.props),ni(H,z),H.return=C,C=H;break e}l(C,v);break}else t(C,v);v=v.sibling}z.type===q?(H=Un(z.props.children,C.mode,H,z.key),H.return=C,C=H):(H=io(z.type,z.key,z.props,null,C.mode,H),ni(H,z),H.return=C,C=H)}return r(C);case V:e:{for(he=z.key;v!==null;){if(v.key===he)if(v.tag===4&&v.stateNode.containerInfo===z.containerInfo&&v.stateNode.implementation===z.implementation){l(C,v.sibling),H=a(v,z.children||[]),H.return=C,C=H;break e}else{l(C,v);break}else t(C,v);v=v.sibling}H=Qr(z,C.mode,H),H.return=C,C=H}return r(C);case ge:return z=qn(z),at(C,v,z,H)}if(ze(z))return ne(C,v,z,H);if(Le(z)){if(he=Le(z),typeof he!="function")throw Error(u(150));return z=he.call(z),ye(C,v,z,H)}if(typeof z.then=="function")return at(C,v,ho(z),H);if(z.$$typeof===le)return at(C,v,co(C,z),H);po(C,z)}return typeof z=="string"&&z!==""||typeof z=="number"||typeof z=="bigint"?(z=""+z,v!==null&&v.tag===6?(l(C,v.sibling),H=a(v,z),H.return=C,C=H):(l(C,v),H=Xr(z,C.mode,H),H.return=C,C=H),r(C)):l(C,v)}return function(C,v,z,H){try{li=0;var he=at(C,v,z,H);return xa=null,he}catch(oe){if(oe===ba||oe===uo)throw oe;var Qe=$t(29,oe,null,C.mode);return Qe.lanes=H,Qe.return=C,Qe}}}var Gn=Pu(!0),ef=Pu(!1),an=!1;function nc(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function ac(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,callbacks:null})}function on(e){return{lane:e,tag:0,payload:null,callback:null,next:null}}function rn(e,t,l){var n=e.updateQueue;if(n===null)return null;if(n=n.shared,(Je&2)!==0){var a=n.pending;return a===null?t.next=t:(t.next=a.next,a.next=t),n.pending=t,t=ao(e),Nu(e,null,l),t}return no(e,n,t,l),ao(e)}function ai(e,t,l){if(t=t.updateQueue,t!==null&&(t=t.shared,(l&4194048)!==0)){var n=t.lanes;n&=e.pendingLanes,l|=n,t.lanes=l,J(e,l)}}function ic(e,t){var l=e.updateQueue,n=e.alternate;if(n!==null&&(n=n.updateQueue,l===n)){var a=null,i=null;if(l=l.firstBaseUpdate,l!==null){do{var r={lane:l.lane,tag:l.tag,payload:l.payload,callback:null,next:null};i===null?a=i=r:i=i.next=r,l=l.next}while(l!==null);i===null?a=i=t:i=i.next=t}else a=i=t;l={baseState:n.baseState,firstBaseUpdate:a,lastBaseUpdate:i,shared:n.shared,callbacks:n.callbacks},e.updateQueue=l;return}e=l.lastBaseUpdate,e===null?l.firstBaseUpdate=t:e.next=t,l.lastBaseUpdate=t}var oc=!1;function ii(){if(oc){var e=va;if(e!==null)throw e}}function oi(e,t,l,n){oc=!1;var a=e.updateQueue;an=!1;var i=a.firstBaseUpdate,r=a.lastBaseUpdate,d=a.shared.pending;if(d!==null){a.shared.pending=null;var m=d,w=m.next;m.next=null,r===null?i=w:r.next=w,r=m;var R=e.alternate;R!==null&&(R=R.updateQueue,d=R.lastBaseUpdate,d!==r&&(d===null?R.firstBaseUpdate=w:d.next=w,R.lastBaseUpdate=m))}if(i!==null){var N=a.baseState;r=0,R=w=m=null,d=i;do{var T=d.lane&-536870913,E=T!==d.lane;if(E?(qe&T)===T:(n&T)===T){T!==0&&T===ya&&(oc=!0),R!==null&&(R=R.next={lane:0,tag:d.tag,payload:d.payload,callback:null,next:null});e:{var ne=e,ye=d;T=t;var at=l;switch(ye.tag){case 1:if(ne=ye.payload,typeof ne=="function"){N=ne.call(at,N,T);break e}N=ne;break e;case 3:ne.flags=ne.flags&-65537|128;case 0:if(ne=ye.payload,T=typeof ne=="function"?ne.call(at,N,T):ne,T==null)break e;N=B({},N,T);break e;case 2:an=!0}}T=d.callback,T!==null&&(e.flags|=64,E&&(e.flags|=8192),E=a.callbacks,E===null?a.callbacks=[T]:E.push(T))}else E={lane:T,tag:d.tag,payload:d.payload,callback:d.callback,next:null},R===null?(w=R=E,m=N):R=R.next=E,r|=T;if(d=d.next,d===null){if(d=a.shared.pending,d===null)break;E=d,d=E.next,E.next=null,a.lastBaseUpdate=E,a.shared.pending=null}}while(!0);R===null&&(m=N),a.baseState=m,a.firstBaseUpdate=w,a.lastBaseUpdate=R,i===null&&(a.shared.lanes=0),dn|=r,e.lanes=r,e.memoizedState=N}}function tf(e,t){if(typeof e!="function")throw Error(u(191,e));e.call(t)}function lf(e,t){var l=e.callbacks;if(l!==null)for(e.callbacks=null,e=0;e<l.length;e++)tf(l[e],t)}var Sa=y(null),mo=y(0);function nf(e,t){e=Jl,O(mo,e),O(Sa,t),Jl=e|t.baseLanes}function rc(){O(mo,Jl),O(Sa,Sa.current)}function cc(){Jl=mo.current,L(Sa),L(mo)}var Wt=y(null),dl=null;function cn(e){var t=e.alternate;O(pt,pt.current&1),O(Wt,e),dl===null&&(t===null||Sa.current!==null||t.memoizedState!==null)&&(dl=e)}function sc(e){O(pt,pt.current),O(Wt,e),dl===null&&(dl=e)}function af(e){e.tag===22?(O(pt,pt.current),O(Wt,e),dl===null&&(dl=e)):sn()}function sn(){O(pt,pt.current),O(Wt,Wt.current)}function It(e){L(Wt),dl===e&&(dl=null),L(pt)}var pt=y(0);function go(e){for(var t=e;t!==null;){if(t.tag===13){var l=t.memoizedState;if(l!==null&&(l=l.dehydrated,l===null||ms(l)||gs(l)))return t}else if(t.tag===19&&(t.memoizedProps.revealOrder==="forwards"||t.memoizedProps.revealOrder==="backwards"||t.memoizedProps.revealOrder==="unstable_legacy-backwards"||t.memoizedProps.revealOrder==="together")){if((t.flags&128)!==0)return t}else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}var ql=0,Ee=null,lt=null,yt=null,yo=!1,Ca=!1,Vn=!1,vo=0,ri=0,za=null,Tp=0;function ut(){throw Error(u(321))}function uc(e,t){if(t===null)return!1;for(var l=0;l<t.length&&l<e.length;l++)if(!Ft(e[l],t[l]))return!1;return!0}function fc(e,t,l,n,a,i){return ql=i,Ee=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,A.H=e===null||e.memoizedState===null?Gf:Tc,Vn=!1,i=l(n,a),Vn=!1,Ca&&(i=rf(t,l,n,a)),of(e),i}function of(e){A.H=ui;var t=lt!==null&<.next!==null;if(ql=0,yt=lt=Ee=null,yo=!1,ri=0,za=null,t)throw Error(u(300));e===null||vt||(e=e.dependencies,e!==null&&ro(e)&&(vt=!0))}function rf(e,t,l,n){Ee=e;var a=0;do{if(Ca&&(za=null),ri=0,Ca=!1,25<=a)throw Error(u(301));if(a+=1,yt=lt=null,e.updateQueue!=null){var i=e.updateQueue;i.lastEffect=null,i.events=null,i.stores=null,i.memoCache!=null&&(i.memoCache.index=0)}A.H=Vf,i=t(l,n)}while(Ca);return i}function Ap(){var e=A.H,t=e.useState()[0];return t=typeof t.then=="function"?ci(t):t,e=e.useState()[0],(lt!==null?lt.memoizedState:null)!==e&&(Ee.flags|=1024),t}function dc(){var e=vo!==0;return vo=0,e}function hc(e,t,l){t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~l}function pc(e){if(yo){for(e=e.memoizedState;e!==null;){var t=e.queue;t!==null&&(t.pending=null),e=e.next}yo=!1}ql=0,yt=lt=Ee=null,Ca=!1,ri=vo=0,za=null}function jt(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return yt===null?Ee.memoizedState=yt=e:yt=yt.next=e,yt}function mt(){if(lt===null){var e=Ee.alternate;e=e!==null?e.memoizedState:null}else e=lt.next;var t=yt===null?Ee.memoizedState:yt.next;if(t!==null)yt=t,lt=e;else{if(e===null)throw Ee.alternate===null?Error(u(467)):Error(u(310));lt=e,e={memoizedState:lt.memoizedState,baseState:lt.baseState,baseQueue:lt.baseQueue,queue:lt.queue,next:null},yt===null?Ee.memoizedState=yt=e:yt=yt.next=e}return yt}function bo(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function ci(e){var t=ri;return ri+=1,za===null&&(za=[]),e=$u(za,e,t),t=Ee,(yt===null?t.memoizedState:yt.next)===null&&(t=t.alternate,A.H=t===null||t.memoizedState===null?Gf:Tc),e}function xo(e){if(e!==null&&typeof e=="object"){if(typeof e.then=="function")return ci(e);if(e.$$typeof===le)return kt(e)}throw Error(u(438,String(e)))}function mc(e){var t=null,l=Ee.updateQueue;if(l!==null&&(t=l.memoCache),t==null){var n=Ee.alternate;n!==null&&(n=n.updateQueue,n!==null&&(n=n.memoCache,n!=null&&(t={data:n.data.map(function(a){return a.slice()}),index:0})))}if(t==null&&(t={data:[],index:0}),l===null&&(l=bo(),Ee.updateQueue=l),l.memoCache=t,l=t.data[t.index],l===void 0)for(l=t.data[t.index]=Array(e),n=0;n<e;n++)l[n]=_e;return t.index++,l}function Yl(e,t){return typeof t=="function"?t(e):t}function So(e){var t=mt();return gc(t,lt,e)}function gc(e,t,l){var n=e.queue;if(n===null)throw Error(u(311));n.lastRenderedReducer=l;var a=e.baseQueue,i=n.pending;if(i!==null){if(a!==null){var r=a.next;a.next=i.next,i.next=r}t.baseQueue=a=i,n.pending=null}if(i=e.baseState,a===null)e.memoizedState=i;else{t=a.next;var d=r=null,m=null,w=t,R=!1;do{var N=w.lane&-536870913;if(N!==w.lane?(qe&N)===N:(ql&N)===N){var T=w.revertLane;if(T===0)m!==null&&(m=m.next={lane:0,revertLane:0,gesture:null,action:w.action,hasEagerState:w.hasEagerState,eagerState:w.eagerState,next:null}),N===ya&&(R=!0);else if((ql&T)===T){w=w.next,T===ya&&(R=!0);continue}else N={lane:0,revertLane:w.revertLane,gesture:null,action:w.action,hasEagerState:w.hasEagerState,eagerState:w.eagerState,next:null},m===null?(d=m=N,r=i):m=m.next=N,Ee.lanes|=T,dn|=T;N=w.action,Vn&&l(i,N),i=w.hasEagerState?w.eagerState:l(i,N)}else T={lane:N,revertLane:w.revertLane,gesture:w.gesture,action:w.action,hasEagerState:w.hasEagerState,eagerState:w.eagerState,next:null},m===null?(d=m=T,r=i):m=m.next=T,Ee.lanes|=N,dn|=N;w=w.next}while(w!==null&&w!==t);if(m===null?r=i:m.next=d,!Ft(i,e.memoizedState)&&(vt=!0,R&&(l=va,l!==null)))throw l;e.memoizedState=i,e.baseState=r,e.baseQueue=m,n.lastRenderedState=i}return a===null&&(n.lanes=0),[e.memoizedState,n.dispatch]}function yc(e){var t=mt(),l=t.queue;if(l===null)throw Error(u(311));l.lastRenderedReducer=e;var n=l.dispatch,a=l.pending,i=t.memoizedState;if(a!==null){l.pending=null;var r=a=a.next;do i=e(i,r.action),r=r.next;while(r!==a);Ft(i,t.memoizedState)||(vt=!0),t.memoizedState=i,t.baseQueue===null&&(t.baseState=i),l.lastRenderedState=i}return[i,n]}function cf(e,t,l){var n=Ee,a=mt(),i=Ge;if(i){if(l===void 0)throw Error(u(407));l=l()}else l=t();var r=!Ft((lt||a).memoizedState,l);if(r&&(a.memoizedState=l,vt=!0),a=a.queue,xc(ff.bind(null,n,a,e),[e]),a.getSnapshot!==t||r||yt!==null&&yt.memoizedState.tag&1){if(n.flags|=2048,wa(9,{destroy:void 0},uf.bind(null,n,a,l,t),null),it===null)throw Error(u(349));i||(ql&127)!==0||sf(n,t,l)}return l}function sf(e,t,l){e.flags|=16384,e={getSnapshot:t,value:l},t=Ee.updateQueue,t===null?(t=bo(),Ee.updateQueue=t,t.stores=[e]):(l=t.stores,l===null?t.stores=[e]:l.push(e))}function uf(e,t,l,n){t.value=l,t.getSnapshot=n,df(t)&&hf(e)}function ff(e,t,l){return l(function(){df(t)&&hf(e)})}function df(e){var t=e.getSnapshot;e=e.value;try{var l=t();return!Ft(e,l)}catch{return!0}}function hf(e){var t=Ln(e,2);t!==null&&Qt(t,e,2)}function vc(e){var t=jt();if(typeof e=="function"){var l=e;if(e=l(),Vn){xl(!0);try{l()}finally{xl(!1)}}}return t.memoizedState=t.baseState=e,t.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Yl,lastRenderedState:e},t}function pf(e,t,l,n){return e.baseState=l,gc(e,lt,typeof n=="function"?n:Yl)}function Ep(e,t,l,n,a){if(wo(e))throw Error(u(485));if(e=t.action,e!==null){var i={payload:a,action:e,next:null,isTransition:!0,status:"pending",value:null,reason:null,listeners:[],then:function(r){i.listeners.push(r)}};A.T!==null?l(!0):i.isTransition=!1,n(i),l=t.pending,l===null?(i.next=t.pending=i,mf(t,i)):(i.next=l.next,t.pending=l.next=i)}}function mf(e,t){var l=t.action,n=t.payload,a=e.state;if(t.isTransition){var i=A.T,r={};A.T=r;try{var d=l(a,n),m=A.S;m!==null&&m(r,d),gf(e,t,d)}catch(w){bc(e,t,w)}finally{i!==null&&r.types!==null&&(i.types=r.types),A.T=i}}else try{i=l(a,n),gf(e,t,i)}catch(w){bc(e,t,w)}}function gf(e,t,l){l!==null&&typeof l=="object"&&typeof l.then=="function"?l.then(function(n){yf(e,t,n)},function(n){return bc(e,t,n)}):yf(e,t,l)}function yf(e,t,l){t.status="fulfilled",t.value=l,vf(t),e.state=l,t=e.pending,t!==null&&(l=t.next,l===t?e.pending=null:(l=l.next,t.next=l,mf(e,l)))}function bc(e,t,l){var n=e.pending;if(e.pending=null,n!==null){n=n.next;do t.status="rejected",t.reason=l,vf(t),t=t.next;while(t!==n)}e.action=null}function vf(e){e=e.listeners;for(var t=0;t<e.length;t++)(0,e[t])()}function bf(e,t){return t}function xf(e,t){if(Ge){var l=it.formState;if(l!==null){e:{var n=Ee;if(Ge){if(rt){t:{for(var a=rt,i=fl;a.nodeType!==8;){if(!i){a=null;break t}if(a=hl(a.nextSibling),a===null){a=null;break t}}i=a.data,a=i==="F!"||i==="F"?a:null}if(a){rt=hl(a.nextSibling),n=a.data==="F!";break e}}ln(n)}n=!1}n&&(t=l[0])}}return l=jt(),l.memoizedState=l.baseState=t,n={pending:null,lanes:0,dispatch:null,lastRenderedReducer:bf,lastRenderedState:t},l.queue=n,l=jf.bind(null,Ee,n),n.dispatch=l,n=vc(!1),i=Mc.bind(null,Ee,!1,n.queue),n=jt(),a={state:t,dispatch:null,action:e,pending:null},n.queue=a,l=Ep.bind(null,Ee,a,i,l),a.dispatch=l,n.memoizedState=e,[t,l,!1]}function Sf(e){var t=mt();return Cf(t,lt,e)}function Cf(e,t,l){if(t=gc(e,t,bf)[0],e=So(Yl)[0],typeof t=="object"&&t!==null&&typeof t.then=="function")try{var n=ci(t)}catch(r){throw r===ba?uo:r}else n=t;t=mt();var a=t.queue,i=a.dispatch;return l!==t.memoizedState&&(Ee.flags|=2048,wa(9,{destroy:void 0},_p.bind(null,a,l),null)),[n,i,e]}function _p(e,t){e.action=t}function zf(e){var t=mt(),l=lt;if(l!==null)return Cf(t,l,e);mt(),t=t.memoizedState,l=mt();var n=l.queue.dispatch;return l.memoizedState=e,[t,n,!1]}function wa(e,t,l,n){return e={tag:e,create:l,deps:n,inst:t,next:null},t=Ee.updateQueue,t===null&&(t=bo(),Ee.updateQueue=t),l=t.lastEffect,l===null?t.lastEffect=e.next=e:(n=l.next,l.next=e,e.next=n,t.lastEffect=e),e}function wf(){return mt().memoizedState}function Co(e,t,l,n){var a=jt();Ee.flags|=e,a.memoizedState=wa(1|t,{destroy:void 0},l,n===void 0?null:n)}function zo(e,t,l,n){var a=mt();n=n===void 0?null:n;var i=a.memoizedState.inst;lt!==null&&n!==null&&uc(n,lt.memoizedState.deps)?a.memoizedState=wa(t,i,l,n):(Ee.flags|=e,a.memoizedState=wa(1|t,i,l,n))}function Mf(e,t){Co(8390656,8,e,t)}function xc(e,t){zo(2048,8,e,t)}function kp(e){Ee.flags|=4;var t=Ee.updateQueue;if(t===null)t=bo(),Ee.updateQueue=t,t.events=[e];else{var l=t.events;l===null?t.events=[e]:l.push(e)}}function Tf(e){var t=mt().memoizedState;return kp({ref:t,nextImpl:e}),function(){if((Je&2)!==0)throw Error(u(440));return t.impl.apply(void 0,arguments)}}function Af(e,t){return zo(4,2,e,t)}function Ef(e,t){return zo(4,4,e,t)}function _f(e,t){if(typeof t=="function"){e=e();var l=t(e);return function(){typeof l=="function"?l():t(null)}}if(t!=null)return e=e(),t.current=e,function(){t.current=null}}function kf(e,t,l){l=l!=null?l.concat([e]):null,zo(4,4,_f.bind(null,t,e),l)}function Sc(){}function Df(e,t){var l=mt();t=t===void 0?null:t;var n=l.memoizedState;return t!==null&&uc(t,n[1])?n[0]:(l.memoizedState=[e,t],e)}function Of(e,t){var l=mt();t=t===void 0?null:t;var n=l.memoizedState;if(t!==null&&uc(t,n[1]))return n[0];if(n=e(),Vn){xl(!0);try{e()}finally{xl(!1)}}return l.memoizedState=[n,t],n}function Cc(e,t,l){return l===void 0||(ql&1073741824)!==0&&(qe&261930)===0?e.memoizedState=t:(e.memoizedState=l,e=Rd(),Ee.lanes|=e,dn|=e,l)}function Rf(e,t,l,n){return Ft(l,t)?l:Sa.current!==null?(e=Cc(e,l,n),Ft(e,t)||(vt=!0),e):(ql&42)===0||(ql&1073741824)!==0&&(qe&261930)===0?(vt=!0,e.memoizedState=l):(e=Rd(),Ee.lanes|=e,dn|=e,t)}function Lf(e,t,l,n,a){var i=G.p;G.p=i!==0&&8>i?i:8;var r=A.T,d={};A.T=d,Mc(e,!1,t,l);try{var m=a(),w=A.S;if(w!==null&&w(d,m),m!==null&&typeof m=="object"&&typeof m.then=="function"){var R=Mp(m,n);si(e,t,R,tl(e))}else si(e,t,n,tl(e))}catch(N){si(e,t,{then:function(){},status:"rejected",reason:N},tl())}finally{G.p=i,r!==null&&d.types!==null&&(r.types=d.types),A.T=r}}function Dp(){}function zc(e,t,l,n){if(e.tag!==5)throw Error(u(476));var a=Uf(e).queue;Lf(e,a,t,P,l===null?Dp:function(){return Hf(e),l(n)})}function Uf(e){var t=e.memoizedState;if(t!==null)return t;t={memoizedState:P,baseState:P,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Yl,lastRenderedState:P},next:null};var l={};return t.next={memoizedState:l,baseState:l,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Yl,lastRenderedState:l},next:null},e.memoizedState=t,e=e.alternate,e!==null&&(e.memoizedState=t),t}function Hf(e){var t=Uf(e);t.next===null&&(t=e.alternate.memoizedState),si(e,t.next.queue,{},tl())}function wc(){return kt(Ti)}function Nf(){return mt().memoizedState}function Bf(){return mt().memoizedState}function Op(e){for(var t=e.return;t!==null;){switch(t.tag){case 24:case 3:var l=tl();e=on(l);var n=rn(t,e,l);n!==null&&(Qt(n,t,l),ai(n,t,l)),t={cache:Pr()},e.payload=t;return}t=t.return}}function Rp(e,t,l){var n=tl();l={lane:n,revertLane:0,gesture:null,action:l,hasEagerState:!1,eagerState:null,next:null},wo(e)?qf(t,l):(l=Gr(e,t,l,n),l!==null&&(Qt(l,e,n),Yf(l,t,n)))}function jf(e,t,l){var n=tl();si(e,t,l,n)}function si(e,t,l,n){var a={lane:n,revertLane:0,gesture:null,action:l,hasEagerState:!1,eagerState:null,next:null};if(wo(e))qf(t,a);else{var i=e.alternate;if(e.lanes===0&&(i===null||i.lanes===0)&&(i=t.lastRenderedReducer,i!==null))try{var r=t.lastRenderedState,d=i(r,l);if(a.hasEagerState=!0,a.eagerState=d,Ft(d,r))return no(e,t,a,0),it===null&&lo(),!1}catch{}if(l=Gr(e,t,a,n),l!==null)return Qt(l,e,n),Yf(l,t,n),!0}return!1}function Mc(e,t,l,n){if(n={lane:2,revertLane:ns(),gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null},wo(e)){if(t)throw Error(u(479))}else t=Gr(e,l,n,2),t!==null&&Qt(t,e,2)}function wo(e){var t=e.alternate;return e===Ee||t!==null&&t===Ee}function qf(e,t){Ca=yo=!0;var l=e.pending;l===null?t.next=t:(t.next=l.next,l.next=t),e.pending=t}function Yf(e,t,l){if((l&4194048)!==0){var n=t.lanes;n&=e.pendingLanes,l|=n,t.lanes=l,J(e,l)}}var ui={readContext:kt,use:xo,useCallback:ut,useContext:ut,useEffect:ut,useImperativeHandle:ut,useLayoutEffect:ut,useInsertionEffect:ut,useMemo:ut,useReducer:ut,useRef:ut,useState:ut,useDebugValue:ut,useDeferredValue:ut,useTransition:ut,useSyncExternalStore:ut,useId:ut,useHostTransitionStatus:ut,useFormState:ut,useActionState:ut,useOptimistic:ut,useMemoCache:ut,useCacheRefresh:ut};ui.useEffectEvent=ut;var Gf={readContext:kt,use:xo,useCallback:function(e,t){return jt().memoizedState=[e,t===void 0?null:t],e},useContext:kt,useEffect:Mf,useImperativeHandle:function(e,t,l){l=l!=null?l.concat([e]):null,Co(4194308,4,_f.bind(null,t,e),l)},useLayoutEffect:function(e,t){return Co(4194308,4,e,t)},useInsertionEffect:function(e,t){Co(4,2,e,t)},useMemo:function(e,t){var l=jt();t=t===void 0?null:t;var n=e();if(Vn){xl(!0);try{e()}finally{xl(!1)}}return l.memoizedState=[n,t],n},useReducer:function(e,t,l){var n=jt();if(l!==void 0){var a=l(t);if(Vn){xl(!0);try{l(t)}finally{xl(!1)}}}else a=t;return n.memoizedState=n.baseState=a,e={pending:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:a},n.queue=e,e=e.dispatch=Rp.bind(null,Ee,e),[n.memoizedState,e]},useRef:function(e){var t=jt();return e={current:e},t.memoizedState=e},useState:function(e){e=vc(e);var t=e.queue,l=jf.bind(null,Ee,t);return t.dispatch=l,[e.memoizedState,l]},useDebugValue:Sc,useDeferredValue:function(e,t){var l=jt();return Cc(l,e,t)},useTransition:function(){var e=vc(!1);return e=Lf.bind(null,Ee,e.queue,!0,!1),jt().memoizedState=e,[!1,e]},useSyncExternalStore:function(e,t,l){var n=Ee,a=jt();if(Ge){if(l===void 0)throw Error(u(407));l=l()}else{if(l=t(),it===null)throw Error(u(349));(qe&127)!==0||sf(n,t,l)}a.memoizedState=l;var i={value:l,getSnapshot:t};return a.queue=i,Mf(ff.bind(null,n,i,e),[e]),n.flags|=2048,wa(9,{destroy:void 0},uf.bind(null,n,i,l,t),null),l},useId:function(){var e=jt(),t=it.identifierPrefix;if(Ge){var l=zl,n=Cl;l=(n&~(1<<32-Bt(n)-1)).toString(32)+l,t="_"+t+"R_"+l,l=vo++,0<l&&(t+="H"+l.toString(32)),t+="_"}else l=Tp++,t="_"+t+"r_"+l.toString(32)+"_";return e.memoizedState=t},useHostTransitionStatus:wc,useFormState:xf,useActionState:xf,useOptimistic:function(e){var t=jt();t.memoizedState=t.baseState=e;var l={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return t.queue=l,t=Mc.bind(null,Ee,!0,l),l.dispatch=t,[e,t]},useMemoCache:mc,useCacheRefresh:function(){return jt().memoizedState=Op.bind(null,Ee)},useEffectEvent:function(e){var t=jt(),l={impl:e};return t.memoizedState=l,function(){if((Je&2)!==0)throw Error(u(440));return l.impl.apply(void 0,arguments)}}},Tc={readContext:kt,use:xo,useCallback:Df,useContext:kt,useEffect:xc,useImperativeHandle:kf,useInsertionEffect:Af,useLayoutEffect:Ef,useMemo:Of,useReducer:So,useRef:wf,useState:function(){return So(Yl)},useDebugValue:Sc,useDeferredValue:function(e,t){var l=mt();return Rf(l,lt.memoizedState,e,t)},useTransition:function(){var e=So(Yl)[0],t=mt().memoizedState;return[typeof e=="boolean"?e:ci(e),t]},useSyncExternalStore:cf,useId:Nf,useHostTransitionStatus:wc,useFormState:Sf,useActionState:Sf,useOptimistic:function(e,t){var l=mt();return pf(l,lt,e,t)},useMemoCache:mc,useCacheRefresh:Bf};Tc.useEffectEvent=Tf;var Vf={readContext:kt,use:xo,useCallback:Df,useContext:kt,useEffect:xc,useImperativeHandle:kf,useInsertionEffect:Af,useLayoutEffect:Ef,useMemo:Of,useReducer:yc,useRef:wf,useState:function(){return yc(Yl)},useDebugValue:Sc,useDeferredValue:function(e,t){var l=mt();return lt===null?Cc(l,e,t):Rf(l,lt.memoizedState,e,t)},useTransition:function(){var e=yc(Yl)[0],t=mt().memoizedState;return[typeof e=="boolean"?e:ci(e),t]},useSyncExternalStore:cf,useId:Nf,useHostTransitionStatus:wc,useFormState:zf,useActionState:zf,useOptimistic:function(e,t){var l=mt();return lt!==null?pf(l,lt,e,t):(l.baseState=e,[e,l.queue.dispatch])},useMemoCache:mc,useCacheRefresh:Bf};Vf.useEffectEvent=Tf;function Ac(e,t,l,n){t=e.memoizedState,l=l(n,t),l=l==null?t:B({},t,l),e.memoizedState=l,e.lanes===0&&(e.updateQueue.baseState=l)}var Ec={enqueueSetState:function(e,t,l){e=e._reactInternals;var n=tl(),a=on(n);a.payload=t,l!=null&&(a.callback=l),t=rn(e,a,n),t!==null&&(Qt(t,e,n),ai(t,e,n))},enqueueReplaceState:function(e,t,l){e=e._reactInternals;var n=tl(),a=on(n);a.tag=1,a.payload=t,l!=null&&(a.callback=l),t=rn(e,a,n),t!==null&&(Qt(t,e,n),ai(t,e,n))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var l=tl(),n=on(l);n.tag=2,t!=null&&(n.callback=t),t=rn(e,n,l),t!==null&&(Qt(t,e,l),ai(t,e,l))}};function Xf(e,t,l,n,a,i,r){return e=e.stateNode,typeof e.shouldComponentUpdate=="function"?e.shouldComponentUpdate(n,i,r):t.prototype&&t.prototype.isPureReactComponent?!$a(l,n)||!$a(a,i):!0}function Qf(e,t,l,n){e=t.state,typeof t.componentWillReceiveProps=="function"&&t.componentWillReceiveProps(l,n),typeof t.UNSAFE_componentWillReceiveProps=="function"&&t.UNSAFE_componentWillReceiveProps(l,n),t.state!==e&&Ec.enqueueReplaceState(t,t.state,null)}function Xn(e,t){var l=t;if("ref"in t){l={};for(var n in t)n!=="ref"&&(l[n]=t[n])}if(e=e.defaultProps){l===t&&(l=B({},l));for(var a in e)l[a]===void 0&&(l[a]=e[a])}return l}function Zf(e){to(e)}function Kf(e){console.error(e)}function Jf(e){to(e)}function Mo(e,t){try{var l=e.onUncaughtError;l(t.value,{componentStack:t.stack})}catch(n){setTimeout(function(){throw n})}}function Ff(e,t,l){try{var n=e.onCaughtError;n(l.value,{componentStack:l.stack,errorBoundary:t.tag===1?t.stateNode:null})}catch(a){setTimeout(function(){throw a})}}function _c(e,t,l){return l=on(l),l.tag=3,l.payload={element:null},l.callback=function(){Mo(e,t)},l}function $f(e){return e=on(e),e.tag=3,e}function Wf(e,t,l,n){var a=l.type.getDerivedStateFromError;if(typeof a=="function"){var i=n.value;e.payload=function(){return a(i)},e.callback=function(){Ff(t,l,n)}}var r=l.stateNode;r!==null&&typeof r.componentDidCatch=="function"&&(e.callback=function(){Ff(t,l,n),typeof a!="function"&&(hn===null?hn=new Set([this]):hn.add(this));var d=n.stack;this.componentDidCatch(n.value,{componentStack:d!==null?d:""})})}function Lp(e,t,l,n,a){if(l.flags|=32768,n!==null&&typeof n=="object"&&typeof n.then=="function"){if(t=l.alternate,t!==null&&ga(t,l,a,!0),l=Wt.current,l!==null){switch(l.tag){case 31:case 13:return dl===null?No():l.alternate===null&&ft===0&&(ft=3),l.flags&=-257,l.flags|=65536,l.lanes=a,n===fo?l.flags|=16384:(t=l.updateQueue,t===null?l.updateQueue=new Set([n]):t.add(n),es(e,n,a)),!1;case 22:return l.flags|=65536,n===fo?l.flags|=16384:(t=l.updateQueue,t===null?(t={transitions:null,markerInstances:null,retryQueue:new Set([n])},l.updateQueue=t):(l=t.retryQueue,l===null?t.retryQueue=new Set([n]):l.add(n)),es(e,n,a)),!1}throw Error(u(435,l.tag))}return es(e,n,a),No(),!1}if(Ge)return t=Wt.current,t!==null?((t.flags&65536)===0&&(t.flags|=256),t.flags|=65536,t.lanes=a,n!==Jr&&(e=Error(u(422),{cause:n}),Pa(cl(e,l)))):(n!==Jr&&(t=Error(u(423),{cause:n}),Pa(cl(t,l))),e=e.current.alternate,e.flags|=65536,a&=-a,e.lanes|=a,n=cl(n,l),a=_c(e.stateNode,n,a),ic(e,a),ft!==4&&(ft=2)),!1;var i=Error(u(520),{cause:n});if(i=cl(i,l),vi===null?vi=[i]:vi.push(i),ft!==4&&(ft=2),t===null)return!0;n=cl(n,l),l=t;do{switch(l.tag){case 3:return l.flags|=65536,e=a&-a,l.lanes|=e,e=_c(l.stateNode,n,e),ic(l,e),!1;case 1:if(t=l.type,i=l.stateNode,(l.flags&128)===0&&(typeof t.getDerivedStateFromError=="function"||i!==null&&typeof i.componentDidCatch=="function"&&(hn===null||!hn.has(i))))return l.flags|=65536,a&=-a,l.lanes|=a,a=$f(a),Wf(a,e,l,n),ic(l,a),!1}l=l.return}while(l!==null);return!1}var kc=Error(u(461)),vt=!1;function Dt(e,t,l,n){t.child=e===null?ef(t,null,l,n):Gn(t,e.child,l,n)}function If(e,t,l,n,a){l=l.render;var i=t.ref;if("ref"in n){var r={};for(var d in n)d!=="ref"&&(r[d]=n[d])}else r=n;return Bn(t),n=fc(e,t,l,r,i,a),d=dc(),e!==null&&!vt?(hc(e,t,a),Gl(e,t,a)):(Ge&&d&&Zr(t),t.flags|=1,Dt(e,t,n,a),t.child)}function Pf(e,t,l,n,a){if(e===null){var i=l.type;return typeof i=="function"&&!Vr(i)&&i.defaultProps===void 0&&l.compare===null?(t.tag=15,t.type=i,ed(e,t,i,n,a)):(e=io(l.type,null,n,t,t.mode,a),e.ref=t.ref,e.return=t,t.child=e)}if(i=e.child,!Bc(e,a)){var r=i.memoizedProps;if(l=l.compare,l=l!==null?l:$a,l(r,n)&&e.ref===t.ref)return Gl(e,t,a)}return t.flags|=1,e=Hl(i,n),e.ref=t.ref,e.return=t,t.child=e}function ed(e,t,l,n,a){if(e!==null){var i=e.memoizedProps;if($a(i,n)&&e.ref===t.ref)if(vt=!1,t.pendingProps=n=i,Bc(e,a))(e.flags&131072)!==0&&(vt=!0);else return t.lanes=e.lanes,Gl(e,t,a)}return Dc(e,t,l,n,a)}function td(e,t,l,n){var a=n.children,i=e!==null?e.memoizedState:null;if(e===null&&t.stateNode===null&&(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),n.mode==="hidden"){if((t.flags&128)!==0){if(i=i!==null?i.baseLanes|l:l,e!==null){for(n=t.child=e.child,a=0;n!==null;)a=a|n.lanes|n.childLanes,n=n.sibling;n=a&~i}else n=0,t.child=null;return ld(e,t,i,l,n)}if((l&536870912)!==0)t.memoizedState={baseLanes:0,cachePool:null},e!==null&&so(t,i!==null?i.cachePool:null),i!==null?nf(t,i):rc(),af(t);else return n=t.lanes=536870912,ld(e,t,i!==null?i.baseLanes|l:l,l,n)}else i!==null?(so(t,i.cachePool),nf(t,i),sn(),t.memoizedState=null):(e!==null&&so(t,null),rc(),sn());return Dt(e,t,a,l),t.child}function fi(e,t){return e!==null&&e.tag===22||t.stateNode!==null||(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),t.sibling}function ld(e,t,l,n,a){var i=tc();return i=i===null?null:{parent:gt._currentValue,pool:i},t.memoizedState={baseLanes:l,cachePool:i},e!==null&&so(t,null),rc(),af(t),e!==null&&ga(e,t,n,!0),t.childLanes=a,null}function To(e,t){return t=Eo({mode:t.mode,children:t.children},e.mode),t.ref=e.ref,e.child=t,t.return=e,t}function nd(e,t,l){return Gn(t,e.child,null,l),e=To(t,t.pendingProps),e.flags|=2,It(t),t.memoizedState=null,e}function Up(e,t,l){var n=t.pendingProps,a=(t.flags&128)!==0;if(t.flags&=-129,e===null){if(Ge){if(n.mode==="hidden")return e=To(t,n),t.lanes=536870912,fi(null,e);if(sc(t),(e=rt)?(e=m0(e,fl),e=e!==null&&e.data==="&"?e:null,e!==null&&(t.memoizedState={dehydrated:e,treeContext:en!==null?{id:Cl,overflow:zl}:null,retryLane:536870912,hydrationErrors:null},l=ju(e),l.return=t,t.child=l,_t=t,rt=null)):e=null,e===null)throw ln(t);return t.lanes=536870912,null}return To(t,n)}var i=e.memoizedState;if(i!==null){var r=i.dehydrated;if(sc(t),a)if(t.flags&256)t.flags&=-257,t=nd(e,t,l);else if(t.memoizedState!==null)t.child=e.child,t.flags|=128,t=null;else throw Error(u(558));else if(vt||ga(e,t,l,!1),a=(l&e.childLanes)!==0,vt||a){if(n=it,n!==null&&(r=ce(n,l),r!==0&&r!==i.retryLane))throw i.retryLane=r,Ln(e,r),Qt(n,e,r),kc;No(),t=nd(e,t,l)}else e=i.treeContext,rt=hl(r.nextSibling),_t=t,Ge=!0,tn=null,fl=!1,e!==null&&Gu(t,e),t=To(t,n),t.flags|=4096;return t}return e=Hl(e.child,{mode:n.mode,children:n.children}),e.ref=t.ref,t.child=e,e.return=t,e}function Ao(e,t){var l=t.ref;if(l===null)e!==null&&e.ref!==null&&(t.flags|=4194816);else{if(typeof l!="function"&&typeof l!="object")throw Error(u(284));(e===null||e.ref!==l)&&(t.flags|=4194816)}}function Dc(e,t,l,n,a){return Bn(t),l=fc(e,t,l,n,void 0,a),n=dc(),e!==null&&!vt?(hc(e,t,a),Gl(e,t,a)):(Ge&&n&&Zr(t),t.flags|=1,Dt(e,t,l,a),t.child)}function ad(e,t,l,n,a,i){return Bn(t),t.updateQueue=null,l=rf(t,n,l,a),of(e),n=dc(),e!==null&&!vt?(hc(e,t,i),Gl(e,t,i)):(Ge&&n&&Zr(t),t.flags|=1,Dt(e,t,l,i),t.child)}function id(e,t,l,n,a){if(Bn(t),t.stateNode===null){var i=da,r=l.contextType;typeof r=="object"&&r!==null&&(i=kt(r)),i=new l(n,i),t.memoizedState=i.state!==null&&i.state!==void 0?i.state:null,i.updater=Ec,t.stateNode=i,i._reactInternals=t,i=t.stateNode,i.props=n,i.state=t.memoizedState,i.refs={},nc(t),r=l.contextType,i.context=typeof r=="object"&&r!==null?kt(r):da,i.state=t.memoizedState,r=l.getDerivedStateFromProps,typeof r=="function"&&(Ac(t,l,r,n),i.state=t.memoizedState),typeof l.getDerivedStateFromProps=="function"||typeof i.getSnapshotBeforeUpdate=="function"||typeof i.UNSAFE_componentWillMount!="function"&&typeof i.componentWillMount!="function"||(r=i.state,typeof i.componentWillMount=="function"&&i.componentWillMount(),typeof i.UNSAFE_componentWillMount=="function"&&i.UNSAFE_componentWillMount(),r!==i.state&&Ec.enqueueReplaceState(i,i.state,null),oi(t,n,i,a),ii(),i.state=t.memoizedState),typeof i.componentDidMount=="function"&&(t.flags|=4194308),n=!0}else if(e===null){i=t.stateNode;var d=t.memoizedProps,m=Xn(l,d);i.props=m;var w=i.context,R=l.contextType;r=da,typeof R=="object"&&R!==null&&(r=kt(R));var N=l.getDerivedStateFromProps;R=typeof N=="function"||typeof i.getSnapshotBeforeUpdate=="function",d=t.pendingProps!==d,R||typeof i.UNSAFE_componentWillReceiveProps!="function"&&typeof i.componentWillReceiveProps!="function"||(d||w!==r)&&Qf(t,i,n,r),an=!1;var T=t.memoizedState;i.state=T,oi(t,n,i,a),ii(),w=t.memoizedState,d||T!==w||an?(typeof N=="function"&&(Ac(t,l,N,n),w=t.memoizedState),(m=an||Xf(t,l,m,n,T,w,r))?(R||typeof i.UNSAFE_componentWillMount!="function"&&typeof i.componentWillMount!="function"||(typeof i.componentWillMount=="function"&&i.componentWillMount(),typeof i.UNSAFE_componentWillMount=="function"&&i.UNSAFE_componentWillMount()),typeof i.componentDidMount=="function"&&(t.flags|=4194308)):(typeof i.componentDidMount=="function"&&(t.flags|=4194308),t.memoizedProps=n,t.memoizedState=w),i.props=n,i.state=w,i.context=r,n=m):(typeof i.componentDidMount=="function"&&(t.flags|=4194308),n=!1)}else{i=t.stateNode,ac(e,t),r=t.memoizedProps,R=Xn(l,r),i.props=R,N=t.pendingProps,T=i.context,w=l.contextType,m=da,typeof w=="object"&&w!==null&&(m=kt(w)),d=l.getDerivedStateFromProps,(w=typeof d=="function"||typeof i.getSnapshotBeforeUpdate=="function")||typeof i.UNSAFE_componentWillReceiveProps!="function"&&typeof i.componentWillReceiveProps!="function"||(r!==N||T!==m)&&Qf(t,i,n,m),an=!1,T=t.memoizedState,i.state=T,oi(t,n,i,a),ii();var E=t.memoizedState;r!==N||T!==E||an||e!==null&&e.dependencies!==null&&ro(e.dependencies)?(typeof d=="function"&&(Ac(t,l,d,n),E=t.memoizedState),(R=an||Xf(t,l,R,n,T,E,m)||e!==null&&e.dependencies!==null&&ro(e.dependencies))?(w||typeof i.UNSAFE_componentWillUpdate!="function"&&typeof i.componentWillUpdate!="function"||(typeof i.componentWillUpdate=="function"&&i.componentWillUpdate(n,E,m),typeof i.UNSAFE_componentWillUpdate=="function"&&i.UNSAFE_componentWillUpdate(n,E,m)),typeof i.componentDidUpdate=="function"&&(t.flags|=4),typeof i.getSnapshotBeforeUpdate=="function"&&(t.flags|=1024)):(typeof i.componentDidUpdate!="function"||r===e.memoizedProps&&T===e.memoizedState||(t.flags|=4),typeof i.getSnapshotBeforeUpdate!="function"||r===e.memoizedProps&&T===e.memoizedState||(t.flags|=1024),t.memoizedProps=n,t.memoizedState=E),i.props=n,i.state=E,i.context=m,n=R):(typeof i.componentDidUpdate!="function"||r===e.memoizedProps&&T===e.memoizedState||(t.flags|=4),typeof i.getSnapshotBeforeUpdate!="function"||r===e.memoizedProps&&T===e.memoizedState||(t.flags|=1024),n=!1)}return i=n,Ao(e,t),n=(t.flags&128)!==0,i||n?(i=t.stateNode,l=n&&typeof l.getDerivedStateFromError!="function"?null:i.render(),t.flags|=1,e!==null&&n?(t.child=Gn(t,e.child,null,a),t.child=Gn(t,null,l,a)):Dt(e,t,l,a),t.memoizedState=i.state,e=t.child):e=Gl(e,t,a),e}function od(e,t,l,n){return Hn(),t.flags|=256,Dt(e,t,l,n),t.child}var Oc={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function Rc(e){return{baseLanes:e,cachePool:Ju()}}function Lc(e,t,l){return e=e!==null?e.childLanes&~l:0,t&&(e|=el),e}function rd(e,t,l){var n=t.pendingProps,a=!1,i=(t.flags&128)!==0,r;if((r=i)||(r=e!==null&&e.memoizedState===null?!1:(pt.current&2)!==0),r&&(a=!0,t.flags&=-129),r=(t.flags&32)!==0,t.flags&=-33,e===null){if(Ge){if(a?cn(t):sn(),(e=rt)?(e=m0(e,fl),e=e!==null&&e.data!=="&"?e:null,e!==null&&(t.memoizedState={dehydrated:e,treeContext:en!==null?{id:Cl,overflow:zl}:null,retryLane:536870912,hydrationErrors:null},l=ju(e),l.return=t,t.child=l,_t=t,rt=null)):e=null,e===null)throw ln(t);return gs(e)?t.lanes=32:t.lanes=536870912,null}var d=n.children;return n=n.fallback,a?(sn(),a=t.mode,d=Eo({mode:"hidden",children:d},a),n=Un(n,a,l,null),d.return=t,n.return=t,d.sibling=n,t.child=d,n=t.child,n.memoizedState=Rc(l),n.childLanes=Lc(e,r,l),t.memoizedState=Oc,fi(null,n)):(cn(t),Uc(t,d))}var m=e.memoizedState;if(m!==null&&(d=m.dehydrated,d!==null)){if(i)t.flags&256?(cn(t),t.flags&=-257,t=Hc(e,t,l)):t.memoizedState!==null?(sn(),t.child=e.child,t.flags|=128,t=null):(sn(),d=n.fallback,a=t.mode,n=Eo({mode:"visible",children:n.children},a),d=Un(d,a,l,null),d.flags|=2,n.return=t,d.return=t,n.sibling=d,t.child=n,Gn(t,e.child,null,l),n=t.child,n.memoizedState=Rc(l),n.childLanes=Lc(e,r,l),t.memoizedState=Oc,t=fi(null,n));else if(cn(t),gs(d)){if(r=d.nextSibling&&d.nextSibling.dataset,r)var w=r.dgst;r=w,n=Error(u(419)),n.stack="",n.digest=r,Pa({value:n,source:null,stack:null}),t=Hc(e,t,l)}else if(vt||ga(e,t,l,!1),r=(l&e.childLanes)!==0,vt||r){if(r=it,r!==null&&(n=ce(r,l),n!==0&&n!==m.retryLane))throw m.retryLane=n,Ln(e,n),Qt(r,e,n),kc;ms(d)||No(),t=Hc(e,t,l)}else ms(d)?(t.flags|=192,t.child=e.child,t=null):(e=m.treeContext,rt=hl(d.nextSibling),_t=t,Ge=!0,tn=null,fl=!1,e!==null&&Gu(t,e),t=Uc(t,n.children),t.flags|=4096);return t}return a?(sn(),d=n.fallback,a=t.mode,m=e.child,w=m.sibling,n=Hl(m,{mode:"hidden",children:n.children}),n.subtreeFlags=m.subtreeFlags&65011712,w!==null?d=Hl(w,d):(d=Un(d,a,l,null),d.flags|=2),d.return=t,n.return=t,n.sibling=d,t.child=n,fi(null,n),n=t.child,d=e.child.memoizedState,d===null?d=Rc(l):(a=d.cachePool,a!==null?(m=gt._currentValue,a=a.parent!==m?{parent:m,pool:m}:a):a=Ju(),d={baseLanes:d.baseLanes|l,cachePool:a}),n.memoizedState=d,n.childLanes=Lc(e,r,l),t.memoizedState=Oc,fi(e.child,n)):(cn(t),l=e.child,e=l.sibling,l=Hl(l,{mode:"visible",children:n.children}),l.return=t,l.sibling=null,e!==null&&(r=t.deletions,r===null?(t.deletions=[e],t.flags|=16):r.push(e)),t.child=l,t.memoizedState=null,l)}function Uc(e,t){return t=Eo({mode:"visible",children:t},e.mode),t.return=e,e.child=t}function Eo(e,t){return e=$t(22,e,null,t),e.lanes=0,e}function Hc(e,t,l){return Gn(t,e.child,null,l),e=Uc(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function cd(e,t,l){e.lanes|=t;var n=e.alternate;n!==null&&(n.lanes|=t),Wr(e.return,t,l)}function Nc(e,t,l,n,a,i){var r=e.memoizedState;r===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:n,tail:l,tailMode:a,treeForkCount:i}:(r.isBackwards=t,r.rendering=null,r.renderingStartTime=0,r.last=n,r.tail=l,r.tailMode=a,r.treeForkCount=i)}function sd(e,t,l){var n=t.pendingProps,a=n.revealOrder,i=n.tail;n=n.children;var r=pt.current,d=(r&2)!==0;if(d?(r=r&1|2,t.flags|=128):r&=1,O(pt,r),Dt(e,t,n,l),n=Ge?Ia:0,!d&&e!==null&&(e.flags&128)!==0)e:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&cd(e,l,t);else if(e.tag===19)cd(e,l,t);else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break e;for(;e.sibling===null;){if(e.return===null||e.return===t)break e;e=e.return}e.sibling.return=e.return,e=e.sibling}switch(a){case"forwards":for(l=t.child,a=null;l!==null;)e=l.alternate,e!==null&&go(e)===null&&(a=l),l=l.sibling;l=a,l===null?(a=t.child,t.child=null):(a=l.sibling,l.sibling=null),Nc(t,!1,a,l,i,n);break;case"backwards":case"unstable_legacy-backwards":for(l=null,a=t.child,t.child=null;a!==null;){if(e=a.alternate,e!==null&&go(e)===null){t.child=a;break}e=a.sibling,a.sibling=l,l=a,a=e}Nc(t,!0,l,null,i,n);break;case"together":Nc(t,!1,null,null,void 0,n);break;default:t.memoizedState=null}return t.child}function Gl(e,t,l){if(e!==null&&(t.dependencies=e.dependencies),dn|=t.lanes,(l&t.childLanes)===0)if(e!==null){if(ga(e,t,l,!1),(l&t.childLanes)===0)return null}else return null;if(e!==null&&t.child!==e.child)throw Error(u(153));if(t.child!==null){for(e=t.child,l=Hl(e,e.pendingProps),t.child=l,l.return=t;e.sibling!==null;)e=e.sibling,l=l.sibling=Hl(e,e.pendingProps),l.return=t;l.sibling=null}return t.child}function Bc(e,t){return(e.lanes&t)!==0?!0:(e=e.dependencies,!!(e!==null&&ro(e)))}function Hp(e,t,l){switch(t.tag){case 3:ht(t,t.stateNode.containerInfo),nn(t,gt,e.memoizedState.cache),Hn();break;case 27:case 5:nl(t);break;case 4:ht(t,t.stateNode.containerInfo);break;case 10:nn(t,t.type,t.memoizedProps.value);break;case 31:if(t.memoizedState!==null)return t.flags|=128,sc(t),null;break;case 13:var n=t.memoizedState;if(n!==null)return n.dehydrated!==null?(cn(t),t.flags|=128,null):(l&t.child.childLanes)!==0?rd(e,t,l):(cn(t),e=Gl(e,t,l),e!==null?e.sibling:null);cn(t);break;case 19:var a=(e.flags&128)!==0;if(n=(l&t.childLanes)!==0,n||(ga(e,t,l,!1),n=(l&t.childLanes)!==0),a){if(n)return sd(e,t,l);t.flags|=128}if(a=t.memoizedState,a!==null&&(a.rendering=null,a.tail=null,a.lastEffect=null),O(pt,pt.current),n)break;return null;case 22:return t.lanes=0,td(e,t,l,t.pendingProps);case 24:nn(t,gt,e.memoizedState.cache)}return Gl(e,t,l)}function ud(e,t,l){if(e!==null)if(e.memoizedProps!==t.pendingProps)vt=!0;else{if(!Bc(e,l)&&(t.flags&128)===0)return vt=!1,Hp(e,t,l);vt=(e.flags&131072)!==0}else vt=!1,Ge&&(t.flags&1048576)!==0&&Yu(t,Ia,t.index);switch(t.lanes=0,t.tag){case 16:e:{var n=t.pendingProps;if(e=qn(t.elementType),t.type=e,typeof e=="function")Vr(e)?(n=Xn(e,n),t.tag=1,t=id(null,t,e,n,l)):(t.tag=0,t=Dc(null,t,e,n,l));else{if(e!=null){var a=e.$$typeof;if(a===re){t.tag=11,t=If(null,t,e,n,l);break e}else if(a===j){t.tag=14,t=Pf(null,t,e,n,l);break e}}throw t=Ie(e)||e,Error(u(306,t,""))}}return t;case 0:return Dc(e,t,t.type,t.pendingProps,l);case 1:return n=t.type,a=Xn(n,t.pendingProps),id(e,t,n,a,l);case 3:e:{if(ht(t,t.stateNode.containerInfo),e===null)throw Error(u(387));n=t.pendingProps;var i=t.memoizedState;a=i.element,ac(e,t),oi(t,n,null,l);var r=t.memoizedState;if(n=r.cache,nn(t,gt,n),n!==i.cache&&Ir(t,[gt],l,!0),ii(),n=r.element,i.isDehydrated)if(i={element:n,isDehydrated:!1,cache:r.cache},t.updateQueue.baseState=i,t.memoizedState=i,t.flags&256){t=od(e,t,n,l);break e}else if(n!==a){a=cl(Error(u(424)),t),Pa(a),t=od(e,t,n,l);break e}else for(e=t.stateNode.containerInfo,e.nodeType===9?e=e.body:e=e.nodeName==="HTML"?e.ownerDocument.body:e,rt=hl(e.firstChild),_t=t,Ge=!0,tn=null,fl=!0,l=ef(t,null,n,l),t.child=l;l;)l.flags=l.flags&-3|4096,l=l.sibling;else{if(Hn(),n===a){t=Gl(e,t,l);break e}Dt(e,t,n,l)}t=t.child}return t;case 26:return Ao(e,t),e===null?(l=S0(t.type,null,t.pendingProps,null))?t.memoizedState=l:Ge||(l=t.type,e=t.pendingProps,n=Xo(Ce.current).createElement(l),n[Ae]=t,n[me]=e,Ot(n,l,e),zt(n),t.stateNode=n):t.memoizedState=S0(t.type,e.memoizedProps,t.pendingProps,e.memoizedState),null;case 27:return nl(t),e===null&&Ge&&(n=t.stateNode=v0(t.type,t.pendingProps,Ce.current),_t=t,fl=!0,a=rt,yn(t.type)?(ys=a,rt=hl(n.firstChild)):rt=a),Dt(e,t,t.pendingProps.children,l),Ao(e,t),e===null&&(t.flags|=4194304),t.child;case 5:return e===null&&Ge&&((a=n=rt)&&(n=dm(n,t.type,t.pendingProps,fl),n!==null?(t.stateNode=n,_t=t,rt=hl(n.firstChild),fl=!1,a=!0):a=!1),a||ln(t)),nl(t),a=t.type,i=t.pendingProps,r=e!==null?e.memoizedProps:null,n=i.children,ds(a,i)?n=null:r!==null&&ds(a,r)&&(t.flags|=32),t.memoizedState!==null&&(a=fc(e,t,Ap,null,null,l),Ti._currentValue=a),Ao(e,t),Dt(e,t,n,l),t.child;case 6:return e===null&&Ge&&((e=l=rt)&&(l=hm(l,t.pendingProps,fl),l!==null?(t.stateNode=l,_t=t,rt=null,e=!0):e=!1),e||ln(t)),null;case 13:return rd(e,t,l);case 4:return ht(t,t.stateNode.containerInfo),n=t.pendingProps,e===null?t.child=Gn(t,null,n,l):Dt(e,t,n,l),t.child;case 11:return If(e,t,t.type,t.pendingProps,l);case 7:return Dt(e,t,t.pendingProps,l),t.child;case 8:return Dt(e,t,t.pendingProps.children,l),t.child;case 12:return Dt(e,t,t.pendingProps.children,l),t.child;case 10:return n=t.pendingProps,nn(t,t.type,n.value),Dt(e,t,n.children,l),t.child;case 9:return a=t.type._context,n=t.pendingProps.children,Bn(t),a=kt(a),n=n(a),t.flags|=1,Dt(e,t,n,l),t.child;case 14:return Pf(e,t,t.type,t.pendingProps,l);case 15:return ed(e,t,t.type,t.pendingProps,l);case 19:return sd(e,t,l);case 31:return Up(e,t,l);case 22:return td(e,t,l,t.pendingProps);case 24:return Bn(t),n=kt(gt),e===null?(a=tc(),a===null&&(a=it,i=Pr(),a.pooledCache=i,i.refCount++,i!==null&&(a.pooledCacheLanes|=l),a=i),t.memoizedState={parent:n,cache:a},nc(t),nn(t,gt,a)):((e.lanes&l)!==0&&(ac(e,t),oi(t,null,null,l),ii()),a=e.memoizedState,i=t.memoizedState,a.parent!==n?(a={parent:n,cache:n},t.memoizedState=a,t.lanes===0&&(t.memoizedState=t.updateQueue.baseState=a),nn(t,gt,n)):(n=i.cache,nn(t,gt,n),n!==a.cache&&Ir(t,[gt],l,!0))),Dt(e,t,t.pendingProps.children,l),t.child;case 29:throw t.pendingProps}throw Error(u(156,t.tag))}function Vl(e){e.flags|=4}function jc(e,t,l,n,a){if((t=(e.mode&32)!==0)&&(t=!1),t){if(e.flags|=16777216,(a&335544128)===a)if(e.stateNode.complete)e.flags|=8192;else if(Nd())e.flags|=8192;else throw Yn=fo,lc}else e.flags&=-16777217}function fd(e,t){if(t.type!=="stylesheet"||(t.state.loading&4)!==0)e.flags&=-16777217;else if(e.flags|=16777216,!T0(t))if(Nd())e.flags|=8192;else throw Yn=fo,lc}function _o(e,t){t!==null&&(e.flags|=4),e.flags&16384&&(t=e.tag!==22?Ol():536870912,e.lanes|=t,Ea|=t)}function di(e,t){if(!Ge)switch(e.tailMode){case"hidden":t=e.tail;for(var l=null;t!==null;)t.alternate!==null&&(l=t),t=t.sibling;l===null?e.tail=null:l.sibling=null;break;case"collapsed":l=e.tail;for(var n=null;l!==null;)l.alternate!==null&&(n=l),l=l.sibling;n===null?t||e.tail===null?e.tail=null:e.tail.sibling=null:n.sibling=null}}function ct(e){var t=e.alternate!==null&&e.alternate.child===e.child,l=0,n=0;if(t)for(var a=e.child;a!==null;)l|=a.lanes|a.childLanes,n|=a.subtreeFlags&65011712,n|=a.flags&65011712,a.return=e,a=a.sibling;else for(a=e.child;a!==null;)l|=a.lanes|a.childLanes,n|=a.subtreeFlags,n|=a.flags,a.return=e,a=a.sibling;return e.subtreeFlags|=n,e.childLanes=l,t}function Np(e,t,l){var n=t.pendingProps;switch(Kr(t),t.tag){case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return ct(t),null;case 1:return ct(t),null;case 3:return l=t.stateNode,n=null,e!==null&&(n=e.memoizedState.cache),t.memoizedState.cache!==n&&(t.flags|=2048),jl(gt),Ke(),l.pendingContext&&(l.context=l.pendingContext,l.pendingContext=null),(e===null||e.child===null)&&(ma(t)?Vl(t):e===null||e.memoizedState.isDehydrated&&(t.flags&256)===0||(t.flags|=1024,Fr())),ct(t),null;case 26:var a=t.type,i=t.memoizedState;return e===null?(Vl(t),i!==null?(ct(t),fd(t,i)):(ct(t),jc(t,a,null,n,l))):i?i!==e.memoizedState?(Vl(t),ct(t),fd(t,i)):(ct(t),t.flags&=-16777217):(e=e.memoizedProps,e!==n&&Vl(t),ct(t),jc(t,a,e,n,l)),null;case 27:if(te(t),l=Ce.current,a=t.type,e!==null&&t.stateNode!=null)e.memoizedProps!==n&&Vl(t);else{if(!n){if(t.stateNode===null)throw Error(u(166));return ct(t),null}e=Z.current,ma(t)?Vu(t):(e=v0(a,n,l),t.stateNode=e,Vl(t))}return ct(t),null;case 5:if(te(t),a=t.type,e!==null&&t.stateNode!=null)e.memoizedProps!==n&&Vl(t);else{if(!n){if(t.stateNode===null)throw Error(u(166));return ct(t),null}if(i=Z.current,ma(t))Vu(t);else{var r=Xo(Ce.current);switch(i){case 1:i=r.createElementNS("http://www.w3.org/2000/svg",a);break;case 2:i=r.createElementNS("http://www.w3.org/1998/Math/MathML",a);break;default:switch(a){case"svg":i=r.createElementNS("http://www.w3.org/2000/svg",a);break;case"math":i=r.createElementNS("http://www.w3.org/1998/Math/MathML",a);break;case"script":i=r.createElement("div"),i.innerHTML="<script><\/script>",i=i.removeChild(i.firstChild);break;case"select":i=typeof n.is=="string"?r.createElement("select",{is:n.is}):r.createElement("select"),n.multiple?i.multiple=!0:n.size&&(i.size=n.size);break;default:i=typeof n.is=="string"?r.createElement(a,{is:n.is}):r.createElement(a)}}i[Ae]=t,i[me]=n;e:for(r=t.child;r!==null;){if(r.tag===5||r.tag===6)i.appendChild(r.stateNode);else if(r.tag!==4&&r.tag!==27&&r.child!==null){r.child.return=r,r=r.child;continue}if(r===t)break e;for(;r.sibling===null;){if(r.return===null||r.return===t)break e;r=r.return}r.sibling.return=r.return,r=r.sibling}t.stateNode=i;e:switch(Ot(i,a,n),a){case"button":case"input":case"select":case"textarea":n=!!n.autoFocus;break e;case"img":n=!0;break e;default:n=!1}n&&Vl(t)}}return ct(t),jc(t,t.type,e===null?null:e.memoizedProps,t.pendingProps,l),null;case 6:if(e&&t.stateNode!=null)e.memoizedProps!==n&&Vl(t);else{if(typeof n!="string"&&t.stateNode===null)throw Error(u(166));if(e=Ce.current,ma(t)){if(e=t.stateNode,l=t.memoizedProps,n=null,a=_t,a!==null)switch(a.tag){case 27:case 5:n=a.memoizedProps}e[Ae]=t,e=!!(e.nodeValue===l||n!==null&&n.suppressHydrationWarning===!0||r0(e.nodeValue,l)),e||ln(t,!0)}else e=Xo(e).createTextNode(n),e[Ae]=t,t.stateNode=e}return ct(t),null;case 31:if(l=t.memoizedState,e===null||e.memoizedState!==null){if(n=ma(t),l!==null){if(e===null){if(!n)throw Error(u(318));if(e=t.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(u(557));e[Ae]=t}else Hn(),(t.flags&128)===0&&(t.memoizedState=null),t.flags|=4;ct(t),e=!1}else l=Fr(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=l),e=!0;if(!e)return t.flags&256?(It(t),t):(It(t),null);if((t.flags&128)!==0)throw Error(u(558))}return ct(t),null;case 13:if(n=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(a=ma(t),n!==null&&n.dehydrated!==null){if(e===null){if(!a)throw Error(u(318));if(a=t.memoizedState,a=a!==null?a.dehydrated:null,!a)throw Error(u(317));a[Ae]=t}else Hn(),(t.flags&128)===0&&(t.memoizedState=null),t.flags|=4;ct(t),a=!1}else a=Fr(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=a),a=!0;if(!a)return t.flags&256?(It(t),t):(It(t),null)}return It(t),(t.flags&128)!==0?(t.lanes=l,t):(l=n!==null,e=e!==null&&e.memoizedState!==null,l&&(n=t.child,a=null,n.alternate!==null&&n.alternate.memoizedState!==null&&n.alternate.memoizedState.cachePool!==null&&(a=n.alternate.memoizedState.cachePool.pool),i=null,n.memoizedState!==null&&n.memoizedState.cachePool!==null&&(i=n.memoizedState.cachePool.pool),i!==a&&(n.flags|=2048)),l!==e&&l&&(t.child.flags|=8192),_o(t,t.updateQueue),ct(t),null);case 4:return Ke(),e===null&&rs(t.stateNode.containerInfo),ct(t),null;case 10:return jl(t.type),ct(t),null;case 19:if(L(pt),n=t.memoizedState,n===null)return ct(t),null;if(a=(t.flags&128)!==0,i=n.rendering,i===null)if(a)di(n,!1);else{if(ft!==0||e!==null&&(e.flags&128)!==0)for(e=t.child;e!==null;){if(i=go(e),i!==null){for(t.flags|=128,di(n,!1),e=i.updateQueue,t.updateQueue=e,_o(t,e),t.subtreeFlags=0,e=l,l=t.child;l!==null;)Bu(l,e),l=l.sibling;return O(pt,pt.current&1|2),Ge&&Nl(t,n.treeForkCount),t.child}e=e.sibling}n.tail!==null&&Ht()>Lo&&(t.flags|=128,a=!0,di(n,!1),t.lanes=4194304)}else{if(!a)if(e=go(i),e!==null){if(t.flags|=128,a=!0,e=e.updateQueue,t.updateQueue=e,_o(t,e),di(n,!0),n.tail===null&&n.tailMode==="hidden"&&!i.alternate&&!Ge)return ct(t),null}else 2*Ht()-n.renderingStartTime>Lo&&l!==536870912&&(t.flags|=128,a=!0,di(n,!1),t.lanes=4194304);n.isBackwards?(i.sibling=t.child,t.child=i):(e=n.last,e!==null?e.sibling=i:t.child=i,n.last=i)}return n.tail!==null?(e=n.tail,n.rendering=e,n.tail=e.sibling,n.renderingStartTime=Ht(),e.sibling=null,l=pt.current,O(pt,a?l&1|2:l&1),Ge&&Nl(t,n.treeForkCount),e):(ct(t),null);case 22:case 23:return It(t),cc(),n=t.memoizedState!==null,e!==null?e.memoizedState!==null!==n&&(t.flags|=8192):n&&(t.flags|=8192),n?(l&536870912)!==0&&(t.flags&128)===0&&(ct(t),t.subtreeFlags&6&&(t.flags|=8192)):ct(t),l=t.updateQueue,l!==null&&_o(t,l.retryQueue),l=null,e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(l=e.memoizedState.cachePool.pool),n=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(n=t.memoizedState.cachePool.pool),n!==l&&(t.flags|=2048),e!==null&&L(jn),null;case 24:return l=null,e!==null&&(l=e.memoizedState.cache),t.memoizedState.cache!==l&&(t.flags|=2048),jl(gt),ct(t),null;case 25:return null;case 30:return null}throw Error(u(156,t.tag))}function Bp(e,t){switch(Kr(t),t.tag){case 1:return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return jl(gt),Ke(),e=t.flags,(e&65536)!==0&&(e&128)===0?(t.flags=e&-65537|128,t):null;case 26:case 27:case 5:return te(t),null;case 31:if(t.memoizedState!==null){if(It(t),t.alternate===null)throw Error(u(340));Hn()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 13:if(It(t),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(u(340));Hn()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return L(pt),null;case 4:return Ke(),null;case 10:return jl(t.type),null;case 22:case 23:return It(t),cc(),e!==null&&L(jn),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 24:return jl(gt),null;case 25:return null;default:return null}}function dd(e,t){switch(Kr(t),t.tag){case 3:jl(gt),Ke();break;case 26:case 27:case 5:te(t);break;case 4:Ke();break;case 31:t.memoizedState!==null&&It(t);break;case 13:It(t);break;case 19:L(pt);break;case 10:jl(t.type);break;case 22:case 23:It(t),cc(),e!==null&&L(jn);break;case 24:jl(gt)}}function hi(e,t){try{var l=t.updateQueue,n=l!==null?l.lastEffect:null;if(n!==null){var a=n.next;l=a;do{if((l.tag&e)===e){n=void 0;var i=l.create,r=l.inst;n=i(),r.destroy=n}l=l.next}while(l!==a)}}catch(d){tt(t,t.return,d)}}function un(e,t,l){try{var n=t.updateQueue,a=n!==null?n.lastEffect:null;if(a!==null){var i=a.next;n=i;do{if((n.tag&e)===e){var r=n.inst,d=r.destroy;if(d!==void 0){r.destroy=void 0,a=t;var m=l,w=d;try{w()}catch(R){tt(a,m,R)}}}n=n.next}while(n!==i)}}catch(R){tt(t,t.return,R)}}function hd(e){var t=e.updateQueue;if(t!==null){var l=e.stateNode;try{lf(t,l)}catch(n){tt(e,e.return,n)}}}function pd(e,t,l){l.props=Xn(e.type,e.memoizedProps),l.state=e.memoizedState;try{l.componentWillUnmount()}catch(n){tt(e,t,n)}}function pi(e,t){try{var l=e.ref;if(l!==null){switch(e.tag){case 26:case 27:case 5:var n=e.stateNode;break;case 30:n=e.stateNode;break;default:n=e.stateNode}typeof l=="function"?e.refCleanup=l(n):l.current=n}}catch(a){tt(e,t,a)}}function wl(e,t){var l=e.ref,n=e.refCleanup;if(l!==null)if(typeof n=="function")try{n()}catch(a){tt(e,t,a)}finally{e.refCleanup=null,e=e.alternate,e!=null&&(e.refCleanup=null)}else if(typeof l=="function")try{l(null)}catch(a){tt(e,t,a)}else l.current=null}function md(e){var t=e.type,l=e.memoizedProps,n=e.stateNode;try{e:switch(t){case"button":case"input":case"select":case"textarea":l.autoFocus&&n.focus();break e;case"img":l.src?n.src=l.src:l.srcSet&&(n.srcset=l.srcSet)}}catch(a){tt(e,e.return,a)}}function qc(e,t,l){try{var n=e.stateNode;om(n,e.type,l,t),n[me]=t}catch(a){tt(e,e.return,a)}}function gd(e){return e.tag===5||e.tag===3||e.tag===26||e.tag===27&&yn(e.type)||e.tag===4}function Yc(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||gd(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.tag===27&&yn(e.type)||e.flags&2||e.child===null||e.tag===4)continue e;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function Gc(e,t,l){var n=e.tag;if(n===5||n===6)e=e.stateNode,t?(l.nodeType===9?l.body:l.nodeName==="HTML"?l.ownerDocument.body:l).insertBefore(e,t):(t=l.nodeType===9?l.body:l.nodeName==="HTML"?l.ownerDocument.body:l,t.appendChild(e),l=l._reactRootContainer,l!=null||t.onclick!==null||(t.onclick=Ll));else if(n!==4&&(n===27&&yn(e.type)&&(l=e.stateNode,t=null),e=e.child,e!==null))for(Gc(e,t,l),e=e.sibling;e!==null;)Gc(e,t,l),e=e.sibling}function ko(e,t,l){var n=e.tag;if(n===5||n===6)e=e.stateNode,t?l.insertBefore(e,t):l.appendChild(e);else if(n!==4&&(n===27&&yn(e.type)&&(l=e.stateNode),e=e.child,e!==null))for(ko(e,t,l),e=e.sibling;e!==null;)ko(e,t,l),e=e.sibling}function yd(e){var t=e.stateNode,l=e.memoizedProps;try{for(var n=e.type,a=t.attributes;a.length;)t.removeAttributeNode(a[0]);Ot(t,n,l),t[Ae]=e,t[me]=l}catch(i){tt(e,e.return,i)}}var Xl=!1,bt=!1,Vc=!1,vd=typeof WeakSet=="function"?WeakSet:Set,wt=null;function jp(e,t){if(e=e.containerInfo,us=Wo,e=_u(e),Hr(e)){if("selectionStart"in e)var l={start:e.selectionStart,end:e.selectionEnd};else e:{l=(l=e.ownerDocument)&&l.defaultView||window;var n=l.getSelection&&l.getSelection();if(n&&n.rangeCount!==0){l=n.anchorNode;var a=n.anchorOffset,i=n.focusNode;n=n.focusOffset;try{l.nodeType,i.nodeType}catch{l=null;break e}var r=0,d=-1,m=-1,w=0,R=0,N=e,T=null;t:for(;;){for(var E;N!==l||a!==0&&N.nodeType!==3||(d=r+a),N!==i||n!==0&&N.nodeType!==3||(m=r+n),N.nodeType===3&&(r+=N.nodeValue.length),(E=N.firstChild)!==null;)T=N,N=E;for(;;){if(N===e)break t;if(T===l&&++w===a&&(d=r),T===i&&++R===n&&(m=r),(E=N.nextSibling)!==null)break;N=T,T=N.parentNode}N=E}l=d===-1||m===-1?null:{start:d,end:m}}else l=null}l=l||{start:0,end:0}}else l=null;for(fs={focusedElem:e,selectionRange:l},Wo=!1,wt=t;wt!==null;)if(t=wt,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,wt=e;else for(;wt!==null;){switch(t=wt,i=t.alternate,e=t.flags,t.tag){case 0:if((e&4)!==0&&(e=t.updateQueue,e=e!==null?e.events:null,e!==null))for(l=0;l<e.length;l++)a=e[l],a.ref.impl=a.nextImpl;break;case 11:case 15:break;case 1:if((e&1024)!==0&&i!==null){e=void 0,l=t,a=i.memoizedProps,i=i.memoizedState,n=l.stateNode;try{var ne=Xn(l.type,a);e=n.getSnapshotBeforeUpdate(ne,i),n.__reactInternalSnapshotBeforeUpdate=e}catch(ye){tt(l,l.return,ye)}}break;case 3:if((e&1024)!==0){if(e=t.stateNode.containerInfo,l=e.nodeType,l===9)ps(e);else if(l===1)switch(e.nodeName){case"HEAD":case"HTML":case"BODY":ps(e);break;default:e.textContent=""}}break;case 5:case 26:case 27:case 6:case 4:case 17:break;default:if((e&1024)!==0)throw Error(u(163))}if(e=t.sibling,e!==null){e.return=t.return,wt=e;break}wt=t.return}}function bd(e,t,l){var n=l.flags;switch(l.tag){case 0:case 11:case 15:Zl(e,l),n&4&&hi(5,l);break;case 1:if(Zl(e,l),n&4)if(e=l.stateNode,t===null)try{e.componentDidMount()}catch(r){tt(l,l.return,r)}else{var a=Xn(l.type,t.memoizedProps);t=t.memoizedState;try{e.componentDidUpdate(a,t,e.__reactInternalSnapshotBeforeUpdate)}catch(r){tt(l,l.return,r)}}n&64&&hd(l),n&512&&pi(l,l.return);break;case 3:if(Zl(e,l),n&64&&(e=l.updateQueue,e!==null)){if(t=null,l.child!==null)switch(l.child.tag){case 27:case 5:t=l.child.stateNode;break;case 1:t=l.child.stateNode}try{lf(e,t)}catch(r){tt(l,l.return,r)}}break;case 27:t===null&&n&4&&yd(l);case 26:case 5:Zl(e,l),t===null&&n&4&&md(l),n&512&&pi(l,l.return);break;case 12:Zl(e,l);break;case 31:Zl(e,l),n&4&&Cd(e,l);break;case 13:Zl(e,l),n&4&&zd(e,l),n&64&&(e=l.memoizedState,e!==null&&(e=e.dehydrated,e!==null&&(l=Jp.bind(null,l),pm(e,l))));break;case 22:if(n=l.memoizedState!==null||Xl,!n){t=t!==null&&t.memoizedState!==null||bt,a=Xl;var i=bt;Xl=n,(bt=t)&&!i?Kl(e,l,(l.subtreeFlags&8772)!==0):Zl(e,l),Xl=a,bt=i}break;case 30:break;default:Zl(e,l)}}function xd(e){var t=e.alternate;t!==null&&(e.alternate=null,xd(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&br(t)),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}var st=null,Yt=!1;function Ql(e,t,l){for(l=l.child;l!==null;)Sd(e,t,l),l=l.sibling}function Sd(e,t,l){if(Nt&&typeof Nt.onCommitFiberUnmount=="function")try{Nt.onCommitFiberUnmount(Tn,l)}catch{}switch(l.tag){case 26:bt||wl(l,t),Ql(e,t,l),l.memoizedState?l.memoizedState.count--:l.stateNode&&(l=l.stateNode,l.parentNode.removeChild(l));break;case 27:bt||wl(l,t);var n=st,a=Yt;yn(l.type)&&(st=l.stateNode,Yt=!1),Ql(e,t,l),zi(l.stateNode),st=n,Yt=a;break;case 5:bt||wl(l,t);case 6:if(n=st,a=Yt,st=null,Ql(e,t,l),st=n,Yt=a,st!==null)if(Yt)try{(st.nodeType===9?st.body:st.nodeName==="HTML"?st.ownerDocument.body:st).removeChild(l.stateNode)}catch(i){tt(l,t,i)}else try{st.removeChild(l.stateNode)}catch(i){tt(l,t,i)}break;case 18:st!==null&&(Yt?(e=st,h0(e.nodeType===9?e.body:e.nodeName==="HTML"?e.ownerDocument.body:e,l.stateNode),Ha(e)):h0(st,l.stateNode));break;case 4:n=st,a=Yt,st=l.stateNode.containerInfo,Yt=!0,Ql(e,t,l),st=n,Yt=a;break;case 0:case 11:case 14:case 15:un(2,l,t),bt||un(4,l,t),Ql(e,t,l);break;case 1:bt||(wl(l,t),n=l.stateNode,typeof n.componentWillUnmount=="function"&&pd(l,t,n)),Ql(e,t,l);break;case 21:Ql(e,t,l);break;case 22:bt=(n=bt)||l.memoizedState!==null,Ql(e,t,l),bt=n;break;default:Ql(e,t,l)}}function Cd(e,t){if(t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null))){e=e.dehydrated;try{Ha(e)}catch(l){tt(t,t.return,l)}}}function zd(e,t){if(t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null&&(e=e.dehydrated,e!==null))))try{Ha(e)}catch(l){tt(t,t.return,l)}}function qp(e){switch(e.tag){case 31:case 13:case 19:var t=e.stateNode;return t===null&&(t=e.stateNode=new vd),t;case 22:return e=e.stateNode,t=e._retryCache,t===null&&(t=e._retryCache=new vd),t;default:throw Error(u(435,e.tag))}}function Do(e,t){var l=qp(e);t.forEach(function(n){if(!l.has(n)){l.add(n);var a=Fp.bind(null,e,n);n.then(a,a)}})}function Gt(e,t){var l=t.deletions;if(l!==null)for(var n=0;n<l.length;n++){var a=l[n],i=e,r=t,d=r;e:for(;d!==null;){switch(d.tag){case 27:if(yn(d.type)){st=d.stateNode,Yt=!1;break e}break;case 5:st=d.stateNode,Yt=!1;break e;case 3:case 4:st=d.stateNode.containerInfo,Yt=!0;break e}d=d.return}if(st===null)throw Error(u(160));Sd(i,r,a),st=null,Yt=!1,i=a.alternate,i!==null&&(i.return=null),a.return=null}if(t.subtreeFlags&13886)for(t=t.child;t!==null;)wd(t,e),t=t.sibling}var vl=null;function wd(e,t){var l=e.alternate,n=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:Gt(t,e),Vt(e),n&4&&(un(3,e,e.return),hi(3,e),un(5,e,e.return));break;case 1:Gt(t,e),Vt(e),n&512&&(bt||l===null||wl(l,l.return)),n&64&&Xl&&(e=e.updateQueue,e!==null&&(n=e.callbacks,n!==null&&(l=e.shared.hiddenCallbacks,e.shared.hiddenCallbacks=l===null?n:l.concat(n))));break;case 26:var a=vl;if(Gt(t,e),Vt(e),n&512&&(bt||l===null||wl(l,l.return)),n&4){var i=l!==null?l.memoizedState:null;if(n=e.memoizedState,l===null)if(n===null)if(e.stateNode===null){e:{n=e.type,l=e.memoizedProps,a=a.ownerDocument||a;t:switch(n){case"title":i=a.getElementsByTagName("title")[0],(!i||i[Ya]||i[Ae]||i.namespaceURI==="http://www.w3.org/2000/svg"||i.hasAttribute("itemprop"))&&(i=a.createElement(n),a.head.insertBefore(i,a.querySelector("head > title"))),Ot(i,n,l),i[Ae]=e,zt(i),n=i;break e;case"link":var r=w0("link","href",a).get(n+(l.href||""));if(r){for(var d=0;d<r.length;d++)if(i=r[d],i.getAttribute("href")===(l.href==null||l.href===""?null:l.href)&&i.getAttribute("rel")===(l.rel==null?null:l.rel)&&i.getAttribute("title")===(l.title==null?null:l.title)&&i.getAttribute("crossorigin")===(l.crossOrigin==null?null:l.crossOrigin)){r.splice(d,1);break t}}i=a.createElement(n),Ot(i,n,l),a.head.appendChild(i);break;case"meta":if(r=w0("meta","content",a).get(n+(l.content||""))){for(d=0;d<r.length;d++)if(i=r[d],i.getAttribute("content")===(l.content==null?null:""+l.content)&&i.getAttribute("name")===(l.name==null?null:l.name)&&i.getAttribute("property")===(l.property==null?null:l.property)&&i.getAttribute("http-equiv")===(l.httpEquiv==null?null:l.httpEquiv)&&i.getAttribute("charset")===(l.charSet==null?null:l.charSet)){r.splice(d,1);break t}}i=a.createElement(n),Ot(i,n,l),a.head.appendChild(i);break;default:throw Error(u(468,n))}i[Ae]=e,zt(i),n=i}e.stateNode=n}else M0(a,e.type,e.stateNode);else e.stateNode=z0(a,n,e.memoizedProps);else i!==n?(i===null?l.stateNode!==null&&(l=l.stateNode,l.parentNode.removeChild(l)):i.count--,n===null?M0(a,e.type,e.stateNode):z0(a,n,e.memoizedProps)):n===null&&e.stateNode!==null&&qc(e,e.memoizedProps,l.memoizedProps)}break;case 27:Gt(t,e),Vt(e),n&512&&(bt||l===null||wl(l,l.return)),l!==null&&n&4&&qc(e,e.memoizedProps,l.memoizedProps);break;case 5:if(Gt(t,e),Vt(e),n&512&&(bt||l===null||wl(l,l.return)),e.flags&32){a=e.stateNode;try{ia(a,"")}catch(ne){tt(e,e.return,ne)}}n&4&&e.stateNode!=null&&(a=e.memoizedProps,qc(e,a,l!==null?l.memoizedProps:a)),n&1024&&(Vc=!0);break;case 6:if(Gt(t,e),Vt(e),n&4){if(e.stateNode===null)throw Error(u(162));n=e.memoizedProps,l=e.stateNode;try{l.nodeValue=n}catch(ne){tt(e,e.return,ne)}}break;case 3:if(Ko=null,a=vl,vl=Qo(t.containerInfo),Gt(t,e),vl=a,Vt(e),n&4&&l!==null&&l.memoizedState.isDehydrated)try{Ha(t.containerInfo)}catch(ne){tt(e,e.return,ne)}Vc&&(Vc=!1,Md(e));break;case 4:n=vl,vl=Qo(e.stateNode.containerInfo),Gt(t,e),Vt(e),vl=n;break;case 12:Gt(t,e),Vt(e);break;case 31:Gt(t,e),Vt(e),n&4&&(n=e.updateQueue,n!==null&&(e.updateQueue=null,Do(e,n)));break;case 13:Gt(t,e),Vt(e),e.child.flags&8192&&e.memoizedState!==null!=(l!==null&&l.memoizedState!==null)&&(Ro=Ht()),n&4&&(n=e.updateQueue,n!==null&&(e.updateQueue=null,Do(e,n)));break;case 22:a=e.memoizedState!==null;var m=l!==null&&l.memoizedState!==null,w=Xl,R=bt;if(Xl=w||a,bt=R||m,Gt(t,e),bt=R,Xl=w,Vt(e),n&8192)e:for(t=e.stateNode,t._visibility=a?t._visibility&-2:t._visibility|1,a&&(l===null||m||Xl||bt||Qn(e)),l=null,t=e;;){if(t.tag===5||t.tag===26){if(l===null){m=l=t;try{if(i=m.stateNode,a)r=i.style,typeof r.setProperty=="function"?r.setProperty("display","none","important"):r.display="none";else{d=m.stateNode;var N=m.memoizedProps.style,T=N!=null&&N.hasOwnProperty("display")?N.display:null;d.style.display=T==null||typeof T=="boolean"?"":(""+T).trim()}}catch(ne){tt(m,m.return,ne)}}}else if(t.tag===6){if(l===null){m=t;try{m.stateNode.nodeValue=a?"":m.memoizedProps}catch(ne){tt(m,m.return,ne)}}}else if(t.tag===18){if(l===null){m=t;try{var E=m.stateNode;a?p0(E,!0):p0(m.stateNode,!1)}catch(ne){tt(m,m.return,ne)}}}else if((t.tag!==22&&t.tag!==23||t.memoizedState===null||t===e)&&t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break e;for(;t.sibling===null;){if(t.return===null||t.return===e)break e;l===t&&(l=null),t=t.return}l===t&&(l=null),t.sibling.return=t.return,t=t.sibling}n&4&&(n=e.updateQueue,n!==null&&(l=n.retryQueue,l!==null&&(n.retryQueue=null,Do(e,l))));break;case 19:Gt(t,e),Vt(e),n&4&&(n=e.updateQueue,n!==null&&(e.updateQueue=null,Do(e,n)));break;case 30:break;case 21:break;default:Gt(t,e),Vt(e)}}function Vt(e){var t=e.flags;if(t&2){try{for(var l,n=e.return;n!==null;){if(gd(n)){l=n;break}n=n.return}if(l==null)throw Error(u(160));switch(l.tag){case 27:var a=l.stateNode,i=Yc(e);ko(e,i,a);break;case 5:var r=l.stateNode;l.flags&32&&(ia(r,""),l.flags&=-33);var d=Yc(e);ko(e,d,r);break;case 3:case 4:var m=l.stateNode.containerInfo,w=Yc(e);Gc(e,w,m);break;default:throw Error(u(161))}}catch(R){tt(e,e.return,R)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function Md(e){if(e.subtreeFlags&1024)for(e=e.child;e!==null;){var t=e;Md(t),t.tag===5&&t.flags&1024&&t.stateNode.reset(),e=e.sibling}}function Zl(e,t){if(t.subtreeFlags&8772)for(t=t.child;t!==null;)bd(e,t.alternate,t),t=t.sibling}function Qn(e){for(e=e.child;e!==null;){var t=e;switch(t.tag){case 0:case 11:case 14:case 15:un(4,t,t.return),Qn(t);break;case 1:wl(t,t.return);var l=t.stateNode;typeof l.componentWillUnmount=="function"&&pd(t,t.return,l),Qn(t);break;case 27:zi(t.stateNode);case 26:case 5:wl(t,t.return),Qn(t);break;case 22:t.memoizedState===null&&Qn(t);break;case 30:Qn(t);break;default:Qn(t)}e=e.sibling}}function Kl(e,t,l){for(l=l&&(t.subtreeFlags&8772)!==0,t=t.child;t!==null;){var n=t.alternate,a=e,i=t,r=i.flags;switch(i.tag){case 0:case 11:case 15:Kl(a,i,l),hi(4,i);break;case 1:if(Kl(a,i,l),n=i,a=n.stateNode,typeof a.componentDidMount=="function")try{a.componentDidMount()}catch(w){tt(n,n.return,w)}if(n=i,a=n.updateQueue,a!==null){var d=n.stateNode;try{var m=a.shared.hiddenCallbacks;if(m!==null)for(a.shared.hiddenCallbacks=null,a=0;a<m.length;a++)tf(m[a],d)}catch(w){tt(n,n.return,w)}}l&&r&64&&hd(i),pi(i,i.return);break;case 27:yd(i);case 26:case 5:Kl(a,i,l),l&&n===null&&r&4&&md(i),pi(i,i.return);break;case 12:Kl(a,i,l);break;case 31:Kl(a,i,l),l&&r&4&&Cd(a,i);break;case 13:Kl(a,i,l),l&&r&4&&zd(a,i);break;case 22:i.memoizedState===null&&Kl(a,i,l),pi(i,i.return);break;case 30:break;default:Kl(a,i,l)}t=t.sibling}}function Xc(e,t){var l=null;e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(l=e.memoizedState.cachePool.pool),e=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(e=t.memoizedState.cachePool.pool),e!==l&&(e!=null&&e.refCount++,l!=null&&ei(l))}function Qc(e,t){e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&ei(e))}function bl(e,t,l,n){if(t.subtreeFlags&10256)for(t=t.child;t!==null;)Td(e,t,l,n),t=t.sibling}function Td(e,t,l,n){var a=t.flags;switch(t.tag){case 0:case 11:case 15:bl(e,t,l,n),a&2048&&hi(9,t);break;case 1:bl(e,t,l,n);break;case 3:bl(e,t,l,n),a&2048&&(e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&ei(e)));break;case 12:if(a&2048){bl(e,t,l,n),e=t.stateNode;try{var i=t.memoizedProps,r=i.id,d=i.onPostCommit;typeof d=="function"&&d(r,t.alternate===null?"mount":"update",e.passiveEffectDuration,-0)}catch(m){tt(t,t.return,m)}}else bl(e,t,l,n);break;case 31:bl(e,t,l,n);break;case 13:bl(e,t,l,n);break;case 23:break;case 22:i=t.stateNode,r=t.alternate,t.memoizedState!==null?i._visibility&2?bl(e,t,l,n):mi(e,t):i._visibility&2?bl(e,t,l,n):(i._visibility|=2,Ma(e,t,l,n,(t.subtreeFlags&10256)!==0||!1)),a&2048&&Xc(r,t);break;case 24:bl(e,t,l,n),a&2048&&Qc(t.alternate,t);break;default:bl(e,t,l,n)}}function Ma(e,t,l,n,a){for(a=a&&((t.subtreeFlags&10256)!==0||!1),t=t.child;t!==null;){var i=e,r=t,d=l,m=n,w=r.flags;switch(r.tag){case 0:case 11:case 15:Ma(i,r,d,m,a),hi(8,r);break;case 23:break;case 22:var R=r.stateNode;r.memoizedState!==null?R._visibility&2?Ma(i,r,d,m,a):mi(i,r):(R._visibility|=2,Ma(i,r,d,m,a)),a&&w&2048&&Xc(r.alternate,r);break;case 24:Ma(i,r,d,m,a),a&&w&2048&&Qc(r.alternate,r);break;default:Ma(i,r,d,m,a)}t=t.sibling}}function mi(e,t){if(t.subtreeFlags&10256)for(t=t.child;t!==null;){var l=e,n=t,a=n.flags;switch(n.tag){case 22:mi(l,n),a&2048&&Xc(n.alternate,n);break;case 24:mi(l,n),a&2048&&Qc(n.alternate,n);break;default:mi(l,n)}t=t.sibling}}var gi=8192;function Ta(e,t,l){if(e.subtreeFlags&gi)for(e=e.child;e!==null;)Ad(e,t,l),e=e.sibling}function Ad(e,t,l){switch(e.tag){case 26:Ta(e,t,l),e.flags&gi&&e.memoizedState!==null&&Tm(l,vl,e.memoizedState,e.memoizedProps);break;case 5:Ta(e,t,l);break;case 3:case 4:var n=vl;vl=Qo(e.stateNode.containerInfo),Ta(e,t,l),vl=n;break;case 22:e.memoizedState===null&&(n=e.alternate,n!==null&&n.memoizedState!==null?(n=gi,gi=16777216,Ta(e,t,l),gi=n):Ta(e,t,l));break;default:Ta(e,t,l)}}function Ed(e){var t=e.alternate;if(t!==null&&(e=t.child,e!==null)){t.child=null;do t=e.sibling,e.sibling=null,e=t;while(e!==null)}}function yi(e){var t=e.deletions;if((e.flags&16)!==0){if(t!==null)for(var l=0;l<t.length;l++){var n=t[l];wt=n,kd(n,e)}Ed(e)}if(e.subtreeFlags&10256)for(e=e.child;e!==null;)_d(e),e=e.sibling}function _d(e){switch(e.tag){case 0:case 11:case 15:yi(e),e.flags&2048&&un(9,e,e.return);break;case 3:yi(e);break;case 12:yi(e);break;case 22:var t=e.stateNode;e.memoizedState!==null&&t._visibility&2&&(e.return===null||e.return.tag!==13)?(t._visibility&=-3,Oo(e)):yi(e);break;default:yi(e)}}function Oo(e){var t=e.deletions;if((e.flags&16)!==0){if(t!==null)for(var l=0;l<t.length;l++){var n=t[l];wt=n,kd(n,e)}Ed(e)}for(e=e.child;e!==null;){switch(t=e,t.tag){case 0:case 11:case 15:un(8,t,t.return),Oo(t);break;case 22:l=t.stateNode,l._visibility&2&&(l._visibility&=-3,Oo(t));break;default:Oo(t)}e=e.sibling}}function kd(e,t){for(;wt!==null;){var l=wt;switch(l.tag){case 0:case 11:case 15:un(8,l,t);break;case 23:case 22:if(l.memoizedState!==null&&l.memoizedState.cachePool!==null){var n=l.memoizedState.cachePool.pool;n!=null&&n.refCount++}break;case 24:ei(l.memoizedState.cache)}if(n=l.child,n!==null)n.return=l,wt=n;else e:for(l=e;wt!==null;){n=wt;var a=n.sibling,i=n.return;if(xd(n),n===l){wt=null;break e}if(a!==null){a.return=i,wt=a;break e}wt=i}}}var Yp={getCacheForType:function(e){var t=kt(gt),l=t.data.get(e);return l===void 0&&(l=e(),t.data.set(e,l)),l},cacheSignal:function(){return kt(gt).controller.signal}},Gp=typeof WeakMap=="function"?WeakMap:Map,Je=0,it=null,Be=null,qe=0,et=0,Pt=null,fn=!1,Aa=!1,Zc=!1,Jl=0,ft=0,dn=0,Zn=0,Kc=0,el=0,Ea=0,vi=null,Xt=null,Jc=!1,Ro=0,Dd=0,Lo=1/0,Uo=null,hn=null,Ct=0,pn=null,_a=null,Fl=0,Fc=0,$c=null,Od=null,bi=0,Wc=null;function tl(){return(Je&2)!==0&&qe!==0?qe&-qe:A.T!==null?ns():Ve()}function Rd(){if(el===0)if((qe&536870912)===0||Ge){var e=Jt;Jt<<=1,(Jt&3932160)===0&&(Jt=262144),el=e}else el=536870912;return e=Wt.current,e!==null&&(e.flags|=32),el}function Qt(e,t,l){(e===it&&(et===2||et===9)||e.cancelPendingCommit!==null)&&(ka(e,0),mn(e,qe,el,!1)),En(e,l),((Je&2)===0||e!==it)&&(e===it&&((Je&2)===0&&(Zn|=l),ft===4&&mn(e,qe,el,!1)),Ml(e))}function Ld(e,t,l){if((Je&6)!==0)throw Error(u(327));var n=!l&&(t&127)===0&&(t&e.expiredLanes)===0||Dl(e,t),a=n?Qp(e,t):Pc(e,t,!0),i=n;do{if(a===0){Aa&&!n&&mn(e,t,0,!1);break}else{if(l=e.current.alternate,i&&!Vp(l)){a=Pc(e,t,!1),i=!1;continue}if(a===2){if(i=t,e.errorRecoveryDisabledLanes&i)var r=0;else r=e.pendingLanes&-536870913,r=r!==0?r:r&536870912?536870912:0;if(r!==0){t=r;e:{var d=e;a=vi;var m=d.current.memoizedState.isDehydrated;if(m&&(ka(d,r).flags|=256),r=Pc(d,r,!1),r!==2){if(Zc&&!m){d.errorRecoveryDisabledLanes|=i,Zn|=i,a=4;break e}i=Xt,Xt=a,i!==null&&(Xt===null?Xt=i:Xt.push.apply(Xt,i))}a=r}if(i=!1,a!==2)continue}}if(a===1){ka(e,0),mn(e,t,0,!0);break}e:{switch(n=e,i=a,i){case 0:case 1:throw Error(u(345));case 4:if((t&4194048)!==t)break;case 6:mn(n,t,el,!fn);break e;case 2:Xt=null;break;case 3:case 5:break;default:throw Error(u(329))}if((t&62914560)===t&&(a=Ro+300-Ht(),10<a)){if(mn(n,t,el,!fn),In(n,0,!0)!==0)break e;Fl=t,n.timeoutHandle=f0(Ud.bind(null,n,l,Xt,Uo,Jc,t,el,Zn,Ea,fn,i,"Throttled",-0,0),a);break e}Ud(n,l,Xt,Uo,Jc,t,el,Zn,Ea,fn,i,null,-0,0)}}break}while(!0);Ml(e)}function Ud(e,t,l,n,a,i,r,d,m,w,R,N,T,E){if(e.timeoutHandle=-1,N=t.subtreeFlags,N&8192||(N&16785408)===16785408){N={stylesheets:null,count:0,imgCount:0,imgBytes:0,suspenseyImages:[],waitingForImages:!0,waitingForViewTransition:!1,unsuspend:Ll},Ad(t,i,N);var ne=(i&62914560)===i?Ro-Ht():(i&4194048)===i?Dd-Ht():0;if(ne=Am(N,ne),ne!==null){Fl=i,e.cancelPendingCommit=ne(Vd.bind(null,e,t,i,l,n,a,r,d,m,R,N,null,T,E)),mn(e,i,r,!w);return}}Vd(e,t,i,l,n,a,r,d,m)}function Vp(e){for(var t=e;;){var l=t.tag;if((l===0||l===11||l===15)&&t.flags&16384&&(l=t.updateQueue,l!==null&&(l=l.stores,l!==null)))for(var n=0;n<l.length;n++){var a=l[n],i=a.getSnapshot;a=a.value;try{if(!Ft(i(),a))return!1}catch{return!1}}if(l=t.child,t.subtreeFlags&16384&&l!==null)l.return=t,t=l;else{if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return!0;t=t.return}t.sibling.return=t.return,t=t.sibling}}return!0}function mn(e,t,l,n){t&=~Kc,t&=~Zn,e.suspendedLanes|=t,e.pingedLanes&=~t,n&&(e.warmLanes|=t),n=e.expirationTimes;for(var a=t;0<a;){var i=31-Bt(a),r=1<<i;n[i]=-1,a&=~r}l!==0&&F(e,l,t)}function Ho(){return(Je&6)===0?(xi(0),!1):!0}function Ic(){if(Be!==null){if(et===0)var e=Be.return;else e=Be,Bl=Nn=null,pc(e),xa=null,li=0,e=Be;for(;e!==null;)dd(e.alternate,e),e=e.return;Be=null}}function ka(e,t){var l=e.timeoutHandle;l!==-1&&(e.timeoutHandle=-1,sm(l)),l=e.cancelPendingCommit,l!==null&&(e.cancelPendingCommit=null,l()),Fl=0,Ic(),it=e,Be=l=Hl(e.current,null),qe=t,et=0,Pt=null,fn=!1,Aa=Dl(e,t),Zc=!1,Ea=el=Kc=Zn=dn=ft=0,Xt=vi=null,Jc=!1,(t&8)!==0&&(t|=t&32);var n=e.entangledLanes;if(n!==0)for(e=e.entanglements,n&=t;0<n;){var a=31-Bt(n),i=1<<a;t|=e[a],n&=~i}return Jl=t,lo(),l}function Hd(e,t){Ee=null,A.H=ui,t===ba||t===uo?(t=Wu(),et=3):t===lc?(t=Wu(),et=4):et=t===kc?8:t!==null&&typeof t=="object"&&typeof t.then=="function"?6:1,Pt=t,Be===null&&(ft=1,Mo(e,cl(t,e.current)))}function Nd(){var e=Wt.current;return e===null?!0:(qe&4194048)===qe?dl===null:(qe&62914560)===qe||(qe&536870912)!==0?e===dl:!1}function Bd(){var e=A.H;return A.H=ui,e===null?ui:e}function jd(){var e=A.A;return A.A=Yp,e}function No(){ft=4,fn||(qe&4194048)!==qe&&Wt.current!==null||(Aa=!0),(dn&134217727)===0&&(Zn&134217727)===0||it===null||mn(it,qe,el,!1)}function Pc(e,t,l){var n=Je;Je|=2;var a=Bd(),i=jd();(it!==e||qe!==t)&&(Uo=null,ka(e,t)),t=!1;var r=ft;e:do try{if(et!==0&&Be!==null){var d=Be,m=Pt;switch(et){case 8:Ic(),r=6;break e;case 3:case 2:case 9:case 6:Wt.current===null&&(t=!0);var w=et;if(et=0,Pt=null,Da(e,d,m,w),l&&Aa){r=0;break e}break;default:w=et,et=0,Pt=null,Da(e,d,m,w)}}Xp(),r=ft;break}catch(R){Hd(e,R)}while(!0);return t&&e.shellSuspendCounter++,Bl=Nn=null,Je=n,A.H=a,A.A=i,Be===null&&(it=null,qe=0,lo()),r}function Xp(){for(;Be!==null;)qd(Be)}function Qp(e,t){var l=Je;Je|=2;var n=Bd(),a=jd();it!==e||qe!==t?(Uo=null,Lo=Ht()+500,ka(e,t)):Aa=Dl(e,t);e:do try{if(et!==0&&Be!==null){t=Be;var i=Pt;t:switch(et){case 1:et=0,Pt=null,Da(e,t,i,1);break;case 2:case 9:if(Fu(i)){et=0,Pt=null,Yd(t);break}t=function(){et!==2&&et!==9||it!==e||(et=7),Ml(e)},i.then(t,t);break e;case 3:et=7;break e;case 4:et=5;break e;case 7:Fu(i)?(et=0,Pt=null,Yd(t)):(et=0,Pt=null,Da(e,t,i,7));break;case 5:var r=null;switch(Be.tag){case 26:r=Be.memoizedState;case 5:case 27:var d=Be;if(r?T0(r):d.stateNode.complete){et=0,Pt=null;var m=d.sibling;if(m!==null)Be=m;else{var w=d.return;w!==null?(Be=w,Bo(w)):Be=null}break t}}et=0,Pt=null,Da(e,t,i,5);break;case 6:et=0,Pt=null,Da(e,t,i,6);break;case 8:Ic(),ft=6;break e;default:throw Error(u(462))}}Zp();break}catch(R){Hd(e,R)}while(!0);return Bl=Nn=null,A.H=n,A.A=a,Je=l,Be!==null?0:(it=null,qe=0,lo(),ft)}function Zp(){for(;Be!==null&&!Jn();)qd(Be)}function qd(e){var t=ud(e.alternate,e,Jl);e.memoizedProps=e.pendingProps,t===null?Bo(e):Be=t}function Yd(e){var t=e,l=t.alternate;switch(t.tag){case 15:case 0:t=ad(l,t,t.pendingProps,t.type,void 0,qe);break;case 11:t=ad(l,t,t.pendingProps,t.type.render,t.ref,qe);break;case 5:pc(t);default:dd(l,t),t=Be=Bu(t,Jl),t=ud(l,t,Jl)}e.memoizedProps=e.pendingProps,t===null?Bo(e):Be=t}function Da(e,t,l,n){Bl=Nn=null,pc(t),xa=null,li=0;var a=t.return;try{if(Lp(e,a,t,l,qe)){ft=1,Mo(e,cl(l,e.current)),Be=null;return}}catch(i){if(a!==null)throw Be=a,i;ft=1,Mo(e,cl(l,e.current)),Be=null;return}t.flags&32768?(Ge||n===1?e=!0:Aa||(qe&536870912)!==0?e=!1:(fn=e=!0,(n===2||n===9||n===3||n===6)&&(n=Wt.current,n!==null&&n.tag===13&&(n.flags|=16384))),Gd(t,e)):Bo(t)}function Bo(e){var t=e;do{if((t.flags&32768)!==0){Gd(t,fn);return}e=t.return;var l=Np(t.alternate,t,Jl);if(l!==null){Be=l;return}if(t=t.sibling,t!==null){Be=t;return}Be=t=e}while(t!==null);ft===0&&(ft=5)}function Gd(e,t){do{var l=Bp(e.alternate,e);if(l!==null){l.flags&=32767,Be=l;return}if(l=e.return,l!==null&&(l.flags|=32768,l.subtreeFlags=0,l.deletions=null),!t&&(e=e.sibling,e!==null)){Be=e;return}Be=e=l}while(e!==null);ft=6,Be=null}function Vd(e,t,l,n,a,i,r,d,m){e.cancelPendingCommit=null;do jo();while(Ct!==0);if((Je&6)!==0)throw Error(u(327));if(t!==null){if(t===e.current)throw Error(u(177));if(i=t.lanes|t.childLanes,i|=Yr,ve(e,l,i,r,d,m),e===it&&(Be=it=null,qe=0),_a=t,pn=e,Fl=l,Fc=i,$c=a,Od=n,(t.subtreeFlags&10256)!==0||(t.flags&10256)!==0?(e.callbackNode=null,e.callbackPriority=0,$p(Fn,function(){return Jd(),null})):(e.callbackNode=null,e.callbackPriority=0),n=(t.flags&13878)!==0,(t.subtreeFlags&13878)!==0||n){n=A.T,A.T=null,a=G.p,G.p=2,r=Je,Je|=4;try{jp(e,t,l)}finally{Je=r,G.p=a,A.T=n}}Ct=1,Xd(),Qd(),Zd()}}function Xd(){if(Ct===1){Ct=0;var e=pn,t=_a,l=(t.flags&13878)!==0;if((t.subtreeFlags&13878)!==0||l){l=A.T,A.T=null;var n=G.p;G.p=2;var a=Je;Je|=4;try{wd(t,e);var i=fs,r=_u(e.containerInfo),d=i.focusedElem,m=i.selectionRange;if(r!==d&&d&&d.ownerDocument&&Eu(d.ownerDocument.documentElement,d)){if(m!==null&&Hr(d)){var w=m.start,R=m.end;if(R===void 0&&(R=w),"selectionStart"in d)d.selectionStart=w,d.selectionEnd=Math.min(R,d.value.length);else{var N=d.ownerDocument||document,T=N&&N.defaultView||window;if(T.getSelection){var E=T.getSelection(),ne=d.textContent.length,ye=Math.min(m.start,ne),at=m.end===void 0?ye:Math.min(m.end,ne);!E.extend&&ye>at&&(r=at,at=ye,ye=r);var C=Au(d,ye),v=Au(d,at);if(C&&v&&(E.rangeCount!==1||E.anchorNode!==C.node||E.anchorOffset!==C.offset||E.focusNode!==v.node||E.focusOffset!==v.offset)){var z=N.createRange();z.setStart(C.node,C.offset),E.removeAllRanges(),ye>at?(E.addRange(z),E.extend(v.node,v.offset)):(z.setEnd(v.node,v.offset),E.addRange(z))}}}}for(N=[],E=d;E=E.parentNode;)E.nodeType===1&&N.push({element:E,left:E.scrollLeft,top:E.scrollTop});for(typeof d.focus=="function"&&d.focus(),d=0;d<N.length;d++){var H=N[d];H.element.scrollLeft=H.left,H.element.scrollTop=H.top}}Wo=!!us,fs=us=null}finally{Je=a,G.p=n,A.T=l}}e.current=t,Ct=2}}function Qd(){if(Ct===2){Ct=0;var e=pn,t=_a,l=(t.flags&8772)!==0;if((t.subtreeFlags&8772)!==0||l){l=A.T,A.T=null;var n=G.p;G.p=2;var a=Je;Je|=4;try{bd(e,t.alternate,t)}finally{Je=a,G.p=n,A.T=l}}Ct=3}}function Zd(){if(Ct===4||Ct===3){Ct=0,Mn();var e=pn,t=_a,l=Fl,n=Od;(t.subtreeFlags&10256)!==0||(t.flags&10256)!==0?Ct=5:(Ct=0,_a=pn=null,Kd(e,e.pendingLanes));var a=e.pendingLanes;if(a===0&&(hn=null),Te(l),t=t.stateNode,Nt&&typeof Nt.onCommitFiberRoot=="function")try{Nt.onCommitFiberRoot(Tn,t,void 0,(t.current.flags&128)===128)}catch{}if(n!==null){t=A.T,a=G.p,G.p=2,A.T=null;try{for(var i=e.onRecoverableError,r=0;r<n.length;r++){var d=n[r];i(d.value,{componentStack:d.stack})}}finally{A.T=t,G.p=a}}(Fl&3)!==0&&jo(),Ml(e),a=e.pendingLanes,(l&261930)!==0&&(a&42)!==0?e===Wc?bi++:(bi=0,Wc=e):bi=0,xi(0)}}function Kd(e,t){(e.pooledCacheLanes&=t)===0&&(t=e.pooledCache,t!=null&&(e.pooledCache=null,ei(t)))}function jo(){return Xd(),Qd(),Zd(),Jd()}function Jd(){if(Ct!==5)return!1;var e=pn,t=Fc;Fc=0;var l=Te(Fl),n=A.T,a=G.p;try{G.p=32>l?32:l,A.T=null,l=$c,$c=null;var i=pn,r=Fl;if(Ct=0,_a=pn=null,Fl=0,(Je&6)!==0)throw Error(u(331));var d=Je;if(Je|=4,_d(i.current),Td(i,i.current,r,l),Je=d,xi(0,!1),Nt&&typeof Nt.onPostCommitFiberRoot=="function")try{Nt.onPostCommitFiberRoot(Tn,i)}catch{}return!0}finally{G.p=a,A.T=n,Kd(e,t)}}function Fd(e,t,l){t=cl(l,t),t=_c(e.stateNode,t,2),e=rn(e,t,2),e!==null&&(En(e,2),Ml(e))}function tt(e,t,l){if(e.tag===3)Fd(e,e,l);else for(;t!==null;){if(t.tag===3){Fd(t,e,l);break}else if(t.tag===1){var n=t.stateNode;if(typeof t.type.getDerivedStateFromError=="function"||typeof n.componentDidCatch=="function"&&(hn===null||!hn.has(n))){e=cl(l,e),l=$f(2),n=rn(t,l,2),n!==null&&(Wf(l,n,t,e),En(n,2),Ml(n));break}}t=t.return}}function es(e,t,l){var n=e.pingCache;if(n===null){n=e.pingCache=new Gp;var a=new Set;n.set(t,a)}else a=n.get(t),a===void 0&&(a=new Set,n.set(t,a));a.has(l)||(Zc=!0,a.add(l),e=Kp.bind(null,e,t,l),t.then(e,e))}function Kp(e,t,l){var n=e.pingCache;n!==null&&n.delete(t),e.pingedLanes|=e.suspendedLanes&l,e.warmLanes&=~l,it===e&&(qe&l)===l&&(ft===4||ft===3&&(qe&62914560)===qe&&300>Ht()-Ro?(Je&2)===0&&ka(e,0):Kc|=l,Ea===qe&&(Ea=0)),Ml(e)}function $d(e,t){t===0&&(t=Ol()),e=Ln(e,t),e!==null&&(En(e,t),Ml(e))}function Jp(e){var t=e.memoizedState,l=0;t!==null&&(l=t.retryLane),$d(e,l)}function Fp(e,t){var l=0;switch(e.tag){case 31:case 13:var n=e.stateNode,a=e.memoizedState;a!==null&&(l=a.retryLane);break;case 19:n=e.stateNode;break;case 22:n=e.stateNode._retryCache;break;default:throw Error(u(314))}n!==null&&n.delete(t),$d(e,l)}function $p(e,t){return _l(e,t)}var qo=null,Oa=null,ts=!1,Yo=!1,ls=!1,gn=0;function Ml(e){e!==Oa&&e.next===null&&(Oa===null?qo=Oa=e:Oa=Oa.next=e),Yo=!0,ts||(ts=!0,Ip())}function xi(e,t){if(!ls&&Yo){ls=!0;do for(var l=!1,n=qo;n!==null;){if(e!==0){var a=n.pendingLanes;if(a===0)var i=0;else{var r=n.suspendedLanes,d=n.pingedLanes;i=(1<<31-Bt(42|e)+1)-1,i&=a&~(r&~d),i=i&201326741?i&201326741|1:i?i|2:0}i!==0&&(l=!0,e0(n,i))}else i=qe,i=In(n,n===it?i:0,n.cancelPendingCommit!==null||n.timeoutHandle!==-1),(i&3)===0||Dl(n,i)||(l=!0,e0(n,i));n=n.next}while(l);ls=!1}}function Wp(){Wd()}function Wd(){Yo=ts=!1;var e=0;gn!==0&&cm()&&(e=gn);for(var t=Ht(),l=null,n=qo;n!==null;){var a=n.next,i=Id(n,t);i===0?(n.next=null,l===null?qo=a:l.next=a,a===null&&(Oa=l)):(l=n,(e!==0||(i&3)!==0)&&(Yo=!0)),n=a}Ct!==0&&Ct!==5||xi(e),gn!==0&&(gn=0)}function Id(e,t){for(var l=e.suspendedLanes,n=e.pingedLanes,a=e.expirationTimes,i=e.pendingLanes&-62914561;0<i;){var r=31-Bt(i),d=1<<r,m=a[r];m===-1?((d&l)===0||(d&n)!==0)&&(a[r]=Il(d,t)):m<=t&&(e.expiredLanes|=d),i&=~d}if(t=it,l=qe,l=In(e,e===t?l:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),n=e.callbackNode,l===0||e===t&&(et===2||et===9)||e.cancelPendingCommit!==null)return n!==null&&n!==null&&gl(n),e.callbackNode=null,e.callbackPriority=0;if((l&3)===0||Dl(e,l)){if(t=l&-l,t===e.callbackPriority)return t;switch(n!==null&&gl(n),Te(l)){case 2:case 8:l=Gi;break;case 32:l=Fn;break;case 268435456:l=Vi;break;default:l=Fn}return n=Pd.bind(null,e),l=_l(l,n),e.callbackPriority=t,e.callbackNode=l,t}return n!==null&&n!==null&&gl(n),e.callbackPriority=2,e.callbackNode=null,2}function Pd(e,t){if(Ct!==0&&Ct!==5)return e.callbackNode=null,e.callbackPriority=0,null;var l=e.callbackNode;if(jo()&&e.callbackNode!==l)return null;var n=qe;return n=In(e,e===it?n:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),n===0?null:(Ld(e,n,t),Id(e,Ht()),e.callbackNode!=null&&e.callbackNode===l?Pd.bind(null,e):null)}function e0(e,t){if(jo())return null;Ld(e,t,!0)}function Ip(){um(function(){(Je&6)!==0?_l(Yi,Wp):Wd()})}function ns(){if(gn===0){var e=ya;e===0&&(e=$n,$n<<=1,($n&261888)===0&&($n=256)),gn=e}return gn}function t0(e){return e==null||typeof e=="symbol"||typeof e=="boolean"?null:typeof e=="function"?e:Ji(""+e)}function l0(e,t){var l=t.ownerDocument.createElement("input");return l.name=t.name,l.value=t.value,e.id&&l.setAttribute("form",e.id),t.parentNode.insertBefore(l,t),e=new FormData(e),l.parentNode.removeChild(l),e}function Pp(e,t,l,n,a){if(t==="submit"&&l&&l.stateNode===a){var i=t0((a[me]||null).action),r=n.submitter;r&&(t=(t=r[me]||null)?t0(t.formAction):r.getAttribute("formAction"),t!==null&&(i=t,r=null));var d=new Ii("action","action",null,n,a);e.push({event:d,listeners:[{instance:null,listener:function(){if(n.defaultPrevented){if(gn!==0){var m=r?l0(a,r):new FormData(a);zc(l,{pending:!0,data:m,method:a.method,action:i},null,m)}}else typeof i=="function"&&(d.preventDefault(),m=r?l0(a,r):new FormData(a),zc(l,{pending:!0,data:m,method:a.method,action:i},i,m))},currentTarget:a}]})}}for(var as=0;as<qr.length;as++){var is=qr[as],em=is.toLowerCase(),tm=is[0].toUpperCase()+is.slice(1);yl(em,"on"+tm)}yl(Ou,"onAnimationEnd"),yl(Ru,"onAnimationIteration"),yl(Lu,"onAnimationStart"),yl("dblclick","onDoubleClick"),yl("focusin","onFocus"),yl("focusout","onBlur"),yl(yp,"onTransitionRun"),yl(vp,"onTransitionStart"),yl(bp,"onTransitionCancel"),yl(Uu,"onTransitionEnd"),na("onMouseEnter",["mouseout","mouseover"]),na("onMouseLeave",["mouseout","mouseover"]),na("onPointerEnter",["pointerout","pointerover"]),na("onPointerLeave",["pointerout","pointerover"]),kn("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),kn("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),kn("onBeforeInput",["compositionend","keypress","textInput","paste"]),kn("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),kn("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),kn("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Si="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(" "),lm=new Set("beforetoggle cancel close invalid load scroll scrollend toggle".split(" ").concat(Si));function n0(e,t){t=(t&4)!==0;for(var l=0;l<e.length;l++){var n=e[l],a=n.event;n=n.listeners;e:{var i=void 0;if(t)for(var r=n.length-1;0<=r;r--){var d=n[r],m=d.instance,w=d.currentTarget;if(d=d.listener,m!==i&&a.isPropagationStopped())break e;i=d,a.currentTarget=w;try{i(a)}catch(R){to(R)}a.currentTarget=null,i=m}else for(r=0;r<n.length;r++){if(d=n[r],m=d.instance,w=d.currentTarget,d=d.listener,m!==i&&a.isPropagationStopped())break e;i=d,a.currentTarget=w;try{i(a)}catch(R){to(R)}a.currentTarget=null,i=m}}}}function je(e,t){var l=t[_n];l===void 0&&(l=t[_n]=new Set);var n=e+"__bubble";l.has(n)||(a0(t,e,2,!1),l.add(n))}function os(e,t,l){var n=0;t&&(n|=4),a0(l,e,n,t)}var Go="_reactListening"+Math.random().toString(36).slice(2);function rs(e){if(!e[Go]){e[Go]=!0,$s.forEach(function(l){l!=="selectionchange"&&(lm.has(l)||os(l,!1,e),os(l,!0,e))});var t=e.nodeType===9?e:e.ownerDocument;t===null||t[Go]||(t[Go]=!0,os("selectionchange",!1,t))}}function a0(e,t,l,n){switch(R0(t)){case 2:var a=km;break;case 8:a=Dm;break;default:a=Cs}l=a.bind(null,t,l,e),a=void 0,!Ar||t!=="touchstart"&&t!=="touchmove"&&t!=="wheel"||(a=!0),n?a!==void 0?e.addEventListener(t,l,{capture:!0,passive:a}):e.addEventListener(t,l,!0):a!==void 0?e.addEventListener(t,l,{passive:a}):e.addEventListener(t,l,!1)}function cs(e,t,l,n,a){var i=n;if((t&1)===0&&(t&2)===0&&n!==null)e:for(;;){if(n===null)return;var r=n.tag;if(r===3||r===4){var d=n.stateNode.containerInfo;if(d===a)break;if(r===4)for(r=n.return;r!==null;){var m=r.tag;if((m===3||m===4)&&r.stateNode.containerInfo===a)return;r=r.return}for(;d!==null;){if(r=ea(d),r===null)return;if(m=r.tag,m===5||m===6||m===26||m===27){n=i=r;continue e}d=d.parentNode}}n=n.return}cu(function(){var w=i,R=Mr(l),N=[];e:{var T=Hu.get(e);if(T!==void 0){var E=Ii,ne=e;switch(e){case"keypress":if($i(l)===0)break e;case"keydown":case"keyup":E=Fh;break;case"focusin":ne="focus",E=Dr;break;case"focusout":ne="blur",E=Dr;break;case"beforeblur":case"afterblur":E=Dr;break;case"click":if(l.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":E=fu;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":E=Nh;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":E=Ih;break;case Ou:case Ru:case Lu:E=qh;break;case Uu:E=ep;break;case"scroll":case"scrollend":E=Uh;break;case"wheel":E=lp;break;case"copy":case"cut":case"paste":E=Gh;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":E=hu;break;case"toggle":case"beforetoggle":E=ap}var ye=(t&4)!==0,at=!ye&&(e==="scroll"||e==="scrollend"),C=ye?T!==null?T+"Capture":null:T;ye=[];for(var v=w,z;v!==null;){var H=v;if(z=H.stateNode,H=H.tag,H!==5&&H!==26&&H!==27||z===null||C===null||(H=Va(v,C),H!=null&&ye.push(Ci(v,H,z))),at)break;v=v.return}0<ye.length&&(T=new E(T,ne,null,l,R),N.push({event:T,listeners:ye}))}}if((t&7)===0){e:{if(T=e==="mouseover"||e==="pointerover",E=e==="mouseout"||e==="pointerout",T&&l!==wr&&(ne=l.relatedTarget||l.fromElement)&&(ea(ne)||ne[Xe]))break e;if((E||T)&&(T=R.window===R?R:(T=R.ownerDocument)?T.defaultView||T.parentWindow:window,E?(ne=l.relatedTarget||l.toElement,E=w,ne=ne?ea(ne):null,ne!==null&&(at=p(ne),ye=ne.tag,ne!==at||ye!==5&&ye!==27&&ye!==6)&&(ne=null)):(E=null,ne=w),E!==ne)){if(ye=fu,H="onMouseLeave",C="onMouseEnter",v="mouse",(e==="pointerout"||e==="pointerover")&&(ye=hu,H="onPointerLeave",C="onPointerEnter",v="pointer"),at=E==null?T:Ga(E),z=ne==null?T:Ga(ne),T=new ye(H,v+"leave",E,l,R),T.target=at,T.relatedTarget=z,H=null,ea(R)===w&&(ye=new ye(C,v+"enter",ne,l,R),ye.target=z,ye.relatedTarget=at,H=ye),at=H,E&&ne)t:{for(ye=nm,C=E,v=ne,z=0,H=C;H;H=ye(H))z++;H=0;for(var he=v;he;he=ye(he))H++;for(;0<z-H;)C=ye(C),z--;for(;0<H-z;)v=ye(v),H--;for(;z--;){if(C===v||v!==null&&C===v.alternate){ye=C;break t}C=ye(C),v=ye(v)}ye=null}else ye=null;E!==null&&i0(N,T,E,ye,!1),ne!==null&&at!==null&&i0(N,at,ne,ye,!0)}}e:{if(T=w?Ga(w):window,E=T.nodeName&&T.nodeName.toLowerCase(),E==="select"||E==="input"&&T.type==="file")var Qe=Su;else if(bu(T))if(Cu)Qe=pp;else{Qe=dp;var oe=fp}else E=T.nodeName,!E||E.toLowerCase()!=="input"||T.type!=="checkbox"&&T.type!=="radio"?w&&zr(w.elementType)&&(Qe=Su):Qe=hp;if(Qe&&(Qe=Qe(e,w))){xu(N,Qe,l,R);break e}oe&&oe(e,T,w),e==="focusout"&&w&&T.type==="number"&&w.memoizedProps.value!=null&&Cr(T,"number",T.value)}switch(oe=w?Ga(w):window,e){case"focusin":(bu(oe)||oe.contentEditable==="true")&&(sa=oe,Nr=w,Wa=null);break;case"focusout":Wa=Nr=sa=null;break;case"mousedown":Br=!0;break;case"contextmenu":case"mouseup":case"dragend":Br=!1,ku(N,l,R);break;case"selectionchange":if(gp)break;case"keydown":case"keyup":ku(N,l,R)}var Oe;if(Rr)e:{switch(e){case"compositionstart":var Ye="onCompositionStart";break e;case"compositionend":Ye="onCompositionEnd";break e;case"compositionupdate":Ye="onCompositionUpdate";break e}Ye=void 0}else ca?yu(e,l)&&(Ye="onCompositionEnd"):e==="keydown"&&l.keyCode===229&&(Ye="onCompositionStart");Ye&&(pu&&l.locale!=="ko"&&(ca||Ye!=="onCompositionStart"?Ye==="onCompositionEnd"&&ca&&(Oe=su()):(Pl=R,Er="value"in Pl?Pl.value:Pl.textContent,ca=!0)),oe=Vo(w,Ye),0<oe.length&&(Ye=new du(Ye,e,null,l,R),N.push({event:Ye,listeners:oe}),Oe?Ye.data=Oe:(Oe=vu(l),Oe!==null&&(Ye.data=Oe)))),(Oe=op?rp(e,l):cp(e,l))&&(Ye=Vo(w,"onBeforeInput"),0<Ye.length&&(oe=new du("onBeforeInput","beforeinput",null,l,R),N.push({event:oe,listeners:Ye}),oe.data=Oe)),Pp(N,e,w,l,R)}n0(N,t)})}function Ci(e,t,l){return{instance:e,listener:t,currentTarget:l}}function Vo(e,t){for(var l=t+"Capture",n=[];e!==null;){var a=e,i=a.stateNode;if(a=a.tag,a!==5&&a!==26&&a!==27||i===null||(a=Va(e,l),a!=null&&n.unshift(Ci(e,a,i)),a=Va(e,t),a!=null&&n.push(Ci(e,a,i))),e.tag===3)return n;e=e.return}return[]}function nm(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5&&e.tag!==27);return e||null}function i0(e,t,l,n,a){for(var i=t._reactName,r=[];l!==null&&l!==n;){var d=l,m=d.alternate,w=d.stateNode;if(d=d.tag,m!==null&&m===n)break;d!==5&&d!==26&&d!==27||w===null||(m=w,a?(w=Va(l,i),w!=null&&r.unshift(Ci(l,w,m))):a||(w=Va(l,i),w!=null&&r.push(Ci(l,w,m)))),l=l.return}r.length!==0&&e.push({event:t,listeners:r})}var am=/\r\n?/g,im=/\u0000|\uFFFD/g;function o0(e){return(typeof e=="string"?e:""+e).replace(am,`
|
|
9
|
+
`).replace(im,"")}function r0(e,t){return t=o0(t),o0(e)===t}function nt(e,t,l,n,a,i){switch(l){case"children":typeof n=="string"?t==="body"||t==="textarea"&&n===""||ia(e,n):(typeof n=="number"||typeof n=="bigint")&&t!=="body"&&ia(e,""+n);break;case"className":Zi(e,"class",n);break;case"tabIndex":Zi(e,"tabindex",n);break;case"dir":case"role":case"viewBox":case"width":case"height":Zi(e,l,n);break;case"style":ou(e,n,i);break;case"data":if(t!=="object"){Zi(e,"data",n);break}case"src":case"href":if(n===""&&(t!=="a"||l!=="href")){e.removeAttribute(l);break}if(n==null||typeof n=="function"||typeof n=="symbol"||typeof n=="boolean"){e.removeAttribute(l);break}n=Ji(""+n),e.setAttribute(l,n);break;case"action":case"formAction":if(typeof n=="function"){e.setAttribute(l,"javascript:throw new Error('A React form was unexpectedly submitted. If you called form.submit() manually, consider using form.requestSubmit() instead. If you\\'re trying to use event.stopPropagation() in a submit event handler, consider also calling event.preventDefault().')");break}else typeof i=="function"&&(l==="formAction"?(t!=="input"&&nt(e,t,"name",a.name,a,null),nt(e,t,"formEncType",a.formEncType,a,null),nt(e,t,"formMethod",a.formMethod,a,null),nt(e,t,"formTarget",a.formTarget,a,null)):(nt(e,t,"encType",a.encType,a,null),nt(e,t,"method",a.method,a,null),nt(e,t,"target",a.target,a,null)));if(n==null||typeof n=="symbol"||typeof n=="boolean"){e.removeAttribute(l);break}n=Ji(""+n),e.setAttribute(l,n);break;case"onClick":n!=null&&(e.onclick=Ll);break;case"onScroll":n!=null&&je("scroll",e);break;case"onScrollEnd":n!=null&&je("scrollend",e);break;case"dangerouslySetInnerHTML":if(n!=null){if(typeof n!="object"||!("__html"in n))throw Error(u(61));if(l=n.__html,l!=null){if(a.children!=null)throw Error(u(60));e.innerHTML=l}}break;case"multiple":e.multiple=n&&typeof n!="function"&&typeof n!="symbol";break;case"muted":e.muted=n&&typeof n!="function"&&typeof n!="symbol";break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":break;case"autoFocus":break;case"xlinkHref":if(n==null||typeof n=="function"||typeof n=="boolean"||typeof n=="symbol"){e.removeAttribute("xlink:href");break}l=Ji(""+n),e.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",l);break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":n!=null&&typeof n!="function"&&typeof n!="symbol"?e.setAttribute(l,""+n):e.removeAttribute(l);break;case"inert":case"allowFullScreen":case"async":case"autoPlay":case"controls":case"default":case"defer":case"disabled":case"disablePictureInPicture":case"disableRemotePlayback":case"formNoValidate":case"hidden":case"loop":case"noModule":case"noValidate":case"open":case"playsInline":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"itemScope":n&&typeof n!="function"&&typeof n!="symbol"?e.setAttribute(l,""):e.removeAttribute(l);break;case"capture":case"download":n===!0?e.setAttribute(l,""):n!==!1&&n!=null&&typeof n!="function"&&typeof n!="symbol"?e.setAttribute(l,n):e.removeAttribute(l);break;case"cols":case"rows":case"size":case"span":n!=null&&typeof n!="function"&&typeof n!="symbol"&&!isNaN(n)&&1<=n?e.setAttribute(l,n):e.removeAttribute(l);break;case"rowSpan":case"start":n==null||typeof n=="function"||typeof n=="symbol"||isNaN(n)?e.removeAttribute(l):e.setAttribute(l,n);break;case"popover":je("beforetoggle",e),je("toggle",e),Qi(e,"popover",n);break;case"xlinkActuate":Rl(e,"http://www.w3.org/1999/xlink","xlink:actuate",n);break;case"xlinkArcrole":Rl(e,"http://www.w3.org/1999/xlink","xlink:arcrole",n);break;case"xlinkRole":Rl(e,"http://www.w3.org/1999/xlink","xlink:role",n);break;case"xlinkShow":Rl(e,"http://www.w3.org/1999/xlink","xlink:show",n);break;case"xlinkTitle":Rl(e,"http://www.w3.org/1999/xlink","xlink:title",n);break;case"xlinkType":Rl(e,"http://www.w3.org/1999/xlink","xlink:type",n);break;case"xmlBase":Rl(e,"http://www.w3.org/XML/1998/namespace","xml:base",n);break;case"xmlLang":Rl(e,"http://www.w3.org/XML/1998/namespace","xml:lang",n);break;case"xmlSpace":Rl(e,"http://www.w3.org/XML/1998/namespace","xml:space",n);break;case"is":Qi(e,"is",n);break;case"innerText":case"textContent":break;default:(!(2<l.length)||l[0]!=="o"&&l[0]!=="O"||l[1]!=="n"&&l[1]!=="N")&&(l=Rh.get(l)||l,Qi(e,l,n))}}function ss(e,t,l,n,a,i){switch(l){case"style":ou(e,n,i);break;case"dangerouslySetInnerHTML":if(n!=null){if(typeof n!="object"||!("__html"in n))throw Error(u(61));if(l=n.__html,l!=null){if(a.children!=null)throw Error(u(60));e.innerHTML=l}}break;case"children":typeof n=="string"?ia(e,n):(typeof n=="number"||typeof n=="bigint")&&ia(e,""+n);break;case"onScroll":n!=null&&je("scroll",e);break;case"onScrollEnd":n!=null&&je("scrollend",e);break;case"onClick":n!=null&&(e.onclick=Ll);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"innerHTML":case"ref":break;case"innerText":case"textContent":break;default:if(!Ws.hasOwnProperty(l))e:{if(l[0]==="o"&&l[1]==="n"&&(a=l.endsWith("Capture"),t=l.slice(2,a?l.length-7:void 0),i=e[me]||null,i=i!=null?i[l]:null,typeof i=="function"&&e.removeEventListener(t,i,a),typeof n=="function")){typeof i!="function"&&i!==null&&(l in e?e[l]=null:e.hasAttribute(l)&&e.removeAttribute(l)),e.addEventListener(t,n,a);break e}l in e?e[l]=n:n===!0?e.setAttribute(l,""):Qi(e,l,n)}}}function Ot(e,t,l){switch(t){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"img":je("error",e),je("load",e);var n=!1,a=!1,i;for(i in l)if(l.hasOwnProperty(i)){var r=l[i];if(r!=null)switch(i){case"src":n=!0;break;case"srcSet":a=!0;break;case"children":case"dangerouslySetInnerHTML":throw Error(u(137,t));default:nt(e,t,i,r,l,null)}}a&&nt(e,t,"srcSet",l.srcSet,l,null),n&&nt(e,t,"src",l.src,l,null);return;case"input":je("invalid",e);var d=i=r=a=null,m=null,w=null;for(n in l)if(l.hasOwnProperty(n)){var R=l[n];if(R!=null)switch(n){case"name":a=R;break;case"type":r=R;break;case"checked":m=R;break;case"defaultChecked":w=R;break;case"value":i=R;break;case"defaultValue":d=R;break;case"children":case"dangerouslySetInnerHTML":if(R!=null)throw Error(u(137,t));break;default:nt(e,t,n,R,l,null)}}lu(e,i,d,m,w,r,a,!1);return;case"select":je("invalid",e),n=r=i=null;for(a in l)if(l.hasOwnProperty(a)&&(d=l[a],d!=null))switch(a){case"value":i=d;break;case"defaultValue":r=d;break;case"multiple":n=d;default:nt(e,t,a,d,l,null)}t=i,l=r,e.multiple=!!n,t!=null?aa(e,!!n,t,!1):l!=null&&aa(e,!!n,l,!0);return;case"textarea":je("invalid",e),i=a=n=null;for(r in l)if(l.hasOwnProperty(r)&&(d=l[r],d!=null))switch(r){case"value":n=d;break;case"defaultValue":a=d;break;case"children":i=d;break;case"dangerouslySetInnerHTML":if(d!=null)throw Error(u(91));break;default:nt(e,t,r,d,l,null)}au(e,n,a,i);return;case"option":for(m in l)l.hasOwnProperty(m)&&(n=l[m],n!=null)&&(m==="selected"?e.selected=n&&typeof n!="function"&&typeof n!="symbol":nt(e,t,m,n,l,null));return;case"dialog":je("beforetoggle",e),je("toggle",e),je("cancel",e),je("close",e);break;case"iframe":case"object":je("load",e);break;case"video":case"audio":for(n=0;n<Si.length;n++)je(Si[n],e);break;case"image":je("error",e),je("load",e);break;case"details":je("toggle",e);break;case"embed":case"source":case"link":je("error",e),je("load",e);case"area":case"base":case"br":case"col":case"hr":case"keygen":case"meta":case"param":case"track":case"wbr":case"menuitem":for(w in l)if(l.hasOwnProperty(w)&&(n=l[w],n!=null))switch(w){case"children":case"dangerouslySetInnerHTML":throw Error(u(137,t));default:nt(e,t,w,n,l,null)}return;default:if(zr(t)){for(R in l)l.hasOwnProperty(R)&&(n=l[R],n!==void 0&&ss(e,t,R,n,l,void 0));return}}for(d in l)l.hasOwnProperty(d)&&(n=l[d],n!=null&&nt(e,t,d,n,l,null))}function om(e,t,l,n){switch(t){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"input":var a=null,i=null,r=null,d=null,m=null,w=null,R=null;for(E in l){var N=l[E];if(l.hasOwnProperty(E)&&N!=null)switch(E){case"checked":break;case"value":break;case"defaultValue":m=N;default:n.hasOwnProperty(E)||nt(e,t,E,null,n,N)}}for(var T in n){var E=n[T];if(N=l[T],n.hasOwnProperty(T)&&(E!=null||N!=null))switch(T){case"type":i=E;break;case"name":a=E;break;case"checked":w=E;break;case"defaultChecked":R=E;break;case"value":r=E;break;case"defaultValue":d=E;break;case"children":case"dangerouslySetInnerHTML":if(E!=null)throw Error(u(137,t));break;default:E!==N&&nt(e,t,T,E,n,N)}}Sr(e,r,d,m,w,R,i,a);return;case"select":E=r=d=T=null;for(i in l)if(m=l[i],l.hasOwnProperty(i)&&m!=null)switch(i){case"value":break;case"multiple":E=m;default:n.hasOwnProperty(i)||nt(e,t,i,null,n,m)}for(a in n)if(i=n[a],m=l[a],n.hasOwnProperty(a)&&(i!=null||m!=null))switch(a){case"value":T=i;break;case"defaultValue":d=i;break;case"multiple":r=i;default:i!==m&&nt(e,t,a,i,n,m)}t=d,l=r,n=E,T!=null?aa(e,!!l,T,!1):!!n!=!!l&&(t!=null?aa(e,!!l,t,!0):aa(e,!!l,l?[]:"",!1));return;case"textarea":E=T=null;for(d in l)if(a=l[d],l.hasOwnProperty(d)&&a!=null&&!n.hasOwnProperty(d))switch(d){case"value":break;case"children":break;default:nt(e,t,d,null,n,a)}for(r in n)if(a=n[r],i=l[r],n.hasOwnProperty(r)&&(a!=null||i!=null))switch(r){case"value":T=a;break;case"defaultValue":E=a;break;case"children":break;case"dangerouslySetInnerHTML":if(a!=null)throw Error(u(91));break;default:a!==i&&nt(e,t,r,a,n,i)}nu(e,T,E);return;case"option":for(var ne in l)T=l[ne],l.hasOwnProperty(ne)&&T!=null&&!n.hasOwnProperty(ne)&&(ne==="selected"?e.selected=!1:nt(e,t,ne,null,n,T));for(m in n)T=n[m],E=l[m],n.hasOwnProperty(m)&&T!==E&&(T!=null||E!=null)&&(m==="selected"?e.selected=T&&typeof T!="function"&&typeof T!="symbol":nt(e,t,m,T,n,E));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 ye in l)T=l[ye],l.hasOwnProperty(ye)&&T!=null&&!n.hasOwnProperty(ye)&&nt(e,t,ye,null,n,T);for(w in n)if(T=n[w],E=l[w],n.hasOwnProperty(w)&&T!==E&&(T!=null||E!=null))switch(w){case"children":case"dangerouslySetInnerHTML":if(T!=null)throw Error(u(137,t));break;default:nt(e,t,w,T,n,E)}return;default:if(zr(t)){for(var at in l)T=l[at],l.hasOwnProperty(at)&&T!==void 0&&!n.hasOwnProperty(at)&&ss(e,t,at,void 0,n,T);for(R in n)T=n[R],E=l[R],!n.hasOwnProperty(R)||T===E||T===void 0&&E===void 0||ss(e,t,R,T,n,E);return}}for(var C in l)T=l[C],l.hasOwnProperty(C)&&T!=null&&!n.hasOwnProperty(C)&&nt(e,t,C,null,n,T);for(N in n)T=n[N],E=l[N],!n.hasOwnProperty(N)||T===E||T==null&&E==null||nt(e,t,N,T,n,E)}function c0(e){switch(e){case"css":case"script":case"font":case"img":case"image":case"input":case"link":return!0;default:return!1}}function rm(){if(typeof performance.getEntriesByType=="function"){for(var e=0,t=0,l=performance.getEntriesByType("resource"),n=0;n<l.length;n++){var a=l[n],i=a.transferSize,r=a.initiatorType,d=a.duration;if(i&&d&&c0(r)){for(r=0,d=a.responseEnd,n+=1;n<l.length;n++){var m=l[n],w=m.startTime;if(w>d)break;var R=m.transferSize,N=m.initiatorType;R&&c0(N)&&(m=m.responseEnd,r+=R*(m<d?1:(d-w)/(m-w)))}if(--n,t+=8*(i+r)/(a.duration/1e3),e++,10<e)break}}if(0<e)return t/e/1e6}return navigator.connection&&(e=navigator.connection.downlink,typeof e=="number")?e:5}var us=null,fs=null;function Xo(e){return e.nodeType===9?e:e.ownerDocument}function s0(e){switch(e){case"http://www.w3.org/2000/svg":return 1;case"http://www.w3.org/1998/Math/MathML":return 2;default:return 0}}function u0(e,t){if(e===0)switch(t){case"svg":return 1;case"math":return 2;default:return 0}return e===1&&t==="foreignObject"?0:e}function ds(e,t){return e==="textarea"||e==="noscript"||typeof t.children=="string"||typeof t.children=="number"||typeof t.children=="bigint"||typeof t.dangerouslySetInnerHTML=="object"&&t.dangerouslySetInnerHTML!==null&&t.dangerouslySetInnerHTML.__html!=null}var hs=null;function cm(){var e=window.event;return e&&e.type==="popstate"?e===hs?!1:(hs=e,!0):(hs=null,!1)}var f0=typeof setTimeout=="function"?setTimeout:void 0,sm=typeof clearTimeout=="function"?clearTimeout:void 0,d0=typeof Promise=="function"?Promise:void 0,um=typeof queueMicrotask=="function"?queueMicrotask:typeof d0<"u"?function(e){return d0.resolve(null).then(e).catch(fm)}:f0;function fm(e){setTimeout(function(){throw e})}function yn(e){return e==="head"}function h0(e,t){var l=t,n=0;do{var a=l.nextSibling;if(e.removeChild(l),a&&a.nodeType===8)if(l=a.data,l==="/$"||l==="/&"){if(n===0){e.removeChild(a),Ha(t);return}n--}else if(l==="$"||l==="$?"||l==="$~"||l==="$!"||l==="&")n++;else if(l==="html")zi(e.ownerDocument.documentElement);else if(l==="head"){l=e.ownerDocument.head,zi(l);for(var i=l.firstChild;i;){var r=i.nextSibling,d=i.nodeName;i[Ya]||d==="SCRIPT"||d==="STYLE"||d==="LINK"&&i.rel.toLowerCase()==="stylesheet"||l.removeChild(i),i=r}}else l==="body"&&zi(e.ownerDocument.body);l=a}while(l);Ha(t)}function p0(e,t){var l=e;e=0;do{var n=l.nextSibling;if(l.nodeType===1?t?(l._stashedDisplay=l.style.display,l.style.display="none"):(l.style.display=l._stashedDisplay||"",l.getAttribute("style")===""&&l.removeAttribute("style")):l.nodeType===3&&(t?(l._stashedText=l.nodeValue,l.nodeValue=""):l.nodeValue=l._stashedText||""),n&&n.nodeType===8)if(l=n.data,l==="/$"){if(e===0)break;e--}else l!=="$"&&l!=="$?"&&l!=="$~"&&l!=="$!"||e++;l=n}while(l)}function ps(e){var t=e.firstChild;for(t&&t.nodeType===10&&(t=t.nextSibling);t;){var l=t;switch(t=t.nextSibling,l.nodeName){case"HTML":case"HEAD":case"BODY":ps(l),br(l);continue;case"SCRIPT":case"STYLE":continue;case"LINK":if(l.rel.toLowerCase()==="stylesheet")continue}e.removeChild(l)}}function dm(e,t,l,n){for(;e.nodeType===1;){var a=l;if(e.nodeName.toLowerCase()!==t.toLowerCase()){if(!n&&(e.nodeName!=="INPUT"||e.type!=="hidden"))break}else if(n){if(!e[Ya])switch(t){case"meta":if(!e.hasAttribute("itemprop"))break;return e;case"link":if(i=e.getAttribute("rel"),i==="stylesheet"&&e.hasAttribute("data-precedence"))break;if(i!==a.rel||e.getAttribute("href")!==(a.href==null||a.href===""?null:a.href)||e.getAttribute("crossorigin")!==(a.crossOrigin==null?null:a.crossOrigin)||e.getAttribute("title")!==(a.title==null?null:a.title))break;return e;case"style":if(e.hasAttribute("data-precedence"))break;return e;case"script":if(i=e.getAttribute("src"),(i!==(a.src==null?null:a.src)||e.getAttribute("type")!==(a.type==null?null:a.type)||e.getAttribute("crossorigin")!==(a.crossOrigin==null?null:a.crossOrigin))&&i&&e.hasAttribute("async")&&!e.hasAttribute("itemprop"))break;return e;default:return e}}else if(t==="input"&&e.type==="hidden"){var i=a.name==null?null:""+a.name;if(a.type==="hidden"&&e.getAttribute("name")===i)return e}else return e;if(e=hl(e.nextSibling),e===null)break}return null}function hm(e,t,l){if(t==="")return null;for(;e.nodeType!==3;)if((e.nodeType!==1||e.nodeName!=="INPUT"||e.type!=="hidden")&&!l||(e=hl(e.nextSibling),e===null))return null;return e}function m0(e,t){for(;e.nodeType!==8;)if((e.nodeType!==1||e.nodeName!=="INPUT"||e.type!=="hidden")&&!t||(e=hl(e.nextSibling),e===null))return null;return e}function ms(e){return e.data==="$?"||e.data==="$~"}function gs(e){return e.data==="$!"||e.data==="$?"&&e.ownerDocument.readyState!=="loading"}function pm(e,t){var l=e.ownerDocument;if(e.data==="$~")e._reactRetry=t;else if(e.data!=="$?"||l.readyState!=="loading")t();else{var n=function(){t(),l.removeEventListener("DOMContentLoaded",n)};l.addEventListener("DOMContentLoaded",n),e._reactRetry=n}}function hl(e){for(;e!=null;e=e.nextSibling){var t=e.nodeType;if(t===1||t===3)break;if(t===8){if(t=e.data,t==="$"||t==="$!"||t==="$?"||t==="$~"||t==="&"||t==="F!"||t==="F")break;if(t==="/$"||t==="/&")return null}}return e}var ys=null;function g0(e){e=e.nextSibling;for(var t=0;e;){if(e.nodeType===8){var l=e.data;if(l==="/$"||l==="/&"){if(t===0)return hl(e.nextSibling);t--}else l!=="$"&&l!=="$!"&&l!=="$?"&&l!=="$~"&&l!=="&"||t++}e=e.nextSibling}return null}function y0(e){e=e.previousSibling;for(var t=0;e;){if(e.nodeType===8){var l=e.data;if(l==="$"||l==="$!"||l==="$?"||l==="$~"||l==="&"){if(t===0)return e;t--}else l!=="/$"&&l!=="/&"||t++}e=e.previousSibling}return null}function v0(e,t,l){switch(t=Xo(l),e){case"html":if(e=t.documentElement,!e)throw Error(u(452));return e;case"head":if(e=t.head,!e)throw Error(u(453));return e;case"body":if(e=t.body,!e)throw Error(u(454));return e;default:throw Error(u(451))}}function zi(e){for(var t=e.attributes;t.length;)e.removeAttributeNode(t[0]);br(e)}var pl=new Map,b0=new Set;function Qo(e){return typeof e.getRootNode=="function"?e.getRootNode():e.nodeType===9?e:e.ownerDocument}var $l=G.d;G.d={f:mm,r:gm,D:ym,C:vm,L:bm,m:xm,X:Cm,S:Sm,M:zm};function mm(){var e=$l.f(),t=Ho();return e||t}function gm(e){var t=ta(e);t!==null&&t.tag===5&&t.type==="form"?Hf(t):$l.r(e)}var Ra=typeof document>"u"?null:document;function x0(e,t,l){var n=Ra;if(n&&typeof t=="string"&&t){var a=ol(t);a='link[rel="'+e+'"][href="'+a+'"]',typeof l=="string"&&(a+='[crossorigin="'+l+'"]'),b0.has(a)||(b0.add(a),e={rel:e,crossOrigin:l,href:t},n.querySelector(a)===null&&(t=n.createElement("link"),Ot(t,"link",e),zt(t),n.head.appendChild(t)))}}function ym(e){$l.D(e),x0("dns-prefetch",e,null)}function vm(e,t){$l.C(e,t),x0("preconnect",e,t)}function bm(e,t,l){$l.L(e,t,l);var n=Ra;if(n&&e&&t){var a='link[rel="preload"][as="'+ol(t)+'"]';t==="image"&&l&&l.imageSrcSet?(a+='[imagesrcset="'+ol(l.imageSrcSet)+'"]',typeof l.imageSizes=="string"&&(a+='[imagesizes="'+ol(l.imageSizes)+'"]')):a+='[href="'+ol(e)+'"]';var i=a;switch(t){case"style":i=La(e);break;case"script":i=Ua(e)}pl.has(i)||(e=B({rel:"preload",href:t==="image"&&l&&l.imageSrcSet?void 0:e,as:t},l),pl.set(i,e),n.querySelector(a)!==null||t==="style"&&n.querySelector(wi(i))||t==="script"&&n.querySelector(Mi(i))||(t=n.createElement("link"),Ot(t,"link",e),zt(t),n.head.appendChild(t)))}}function xm(e,t){$l.m(e,t);var l=Ra;if(l&&e){var n=t&&typeof t.as=="string"?t.as:"script",a='link[rel="modulepreload"][as="'+ol(n)+'"][href="'+ol(e)+'"]',i=a;switch(n){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":i=Ua(e)}if(!pl.has(i)&&(e=B({rel:"modulepreload",href:e},t),pl.set(i,e),l.querySelector(a)===null)){switch(n){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(l.querySelector(Mi(i)))return}n=l.createElement("link"),Ot(n,"link",e),zt(n),l.head.appendChild(n)}}}function Sm(e,t,l){$l.S(e,t,l);var n=Ra;if(n&&e){var a=la(n).hoistableStyles,i=La(e);t=t||"default";var r=a.get(i);if(!r){var d={loading:0,preload:null};if(r=n.querySelector(wi(i)))d.loading=5;else{e=B({rel:"stylesheet",href:e,"data-precedence":t},l),(l=pl.get(i))&&vs(e,l);var m=r=n.createElement("link");zt(m),Ot(m,"link",e),m._p=new Promise(function(w,R){m.onload=w,m.onerror=R}),m.addEventListener("load",function(){d.loading|=1}),m.addEventListener("error",function(){d.loading|=2}),d.loading|=4,Zo(r,t,n)}r={type:"stylesheet",instance:r,count:1,state:d},a.set(i,r)}}}function Cm(e,t){$l.X(e,t);var l=Ra;if(l&&e){var n=la(l).hoistableScripts,a=Ua(e),i=n.get(a);i||(i=l.querySelector(Mi(a)),i||(e=B({src:e,async:!0},t),(t=pl.get(a))&&bs(e,t),i=l.createElement("script"),zt(i),Ot(i,"link",e),l.head.appendChild(i)),i={type:"script",instance:i,count:1,state:null},n.set(a,i))}}function zm(e,t){$l.M(e,t);var l=Ra;if(l&&e){var n=la(l).hoistableScripts,a=Ua(e),i=n.get(a);i||(i=l.querySelector(Mi(a)),i||(e=B({src:e,async:!0,type:"module"},t),(t=pl.get(a))&&bs(e,t),i=l.createElement("script"),zt(i),Ot(i,"link",e),l.head.appendChild(i)),i={type:"script",instance:i,count:1,state:null},n.set(a,i))}}function S0(e,t,l,n){var a=(a=Ce.current)?Qo(a):null;if(!a)throw Error(u(446));switch(e){case"meta":case"title":return null;case"style":return typeof l.precedence=="string"&&typeof l.href=="string"?(t=La(l.href),l=la(a).hoistableStyles,n=l.get(t),n||(n={type:"style",instance:null,count:0,state:null},l.set(t,n)),n):{type:"void",instance:null,count:0,state:null};case"link":if(l.rel==="stylesheet"&&typeof l.href=="string"&&typeof l.precedence=="string"){e=La(l.href);var i=la(a).hoistableStyles,r=i.get(e);if(r||(a=a.ownerDocument||a,r={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},i.set(e,r),(i=a.querySelector(wi(e)))&&!i._p&&(r.instance=i,r.state.loading=5),pl.has(e)||(l={rel:"preload",as:"style",href:l.href,crossOrigin:l.crossOrigin,integrity:l.integrity,media:l.media,hrefLang:l.hrefLang,referrerPolicy:l.referrerPolicy},pl.set(e,l),i||wm(a,e,l,r.state))),t&&n===null)throw Error(u(528,""));return r}if(t&&n!==null)throw Error(u(529,""));return null;case"script":return t=l.async,l=l.src,typeof l=="string"&&t&&typeof t!="function"&&typeof t!="symbol"?(t=Ua(l),l=la(a).hoistableScripts,n=l.get(t),n||(n={type:"script",instance:null,count:0,state:null},l.set(t,n)),n):{type:"void",instance:null,count:0,state:null};default:throw Error(u(444,e))}}function La(e){return'href="'+ol(e)+'"'}function wi(e){return'link[rel="stylesheet"]['+e+"]"}function C0(e){return B({},e,{"data-precedence":e.precedence,precedence:null})}function wm(e,t,l,n){e.querySelector('link[rel="preload"][as="style"]['+t+"]")?n.loading=1:(t=e.createElement("link"),n.preload=t,t.addEventListener("load",function(){return n.loading|=1}),t.addEventListener("error",function(){return n.loading|=2}),Ot(t,"link",l),zt(t),e.head.appendChild(t))}function Ua(e){return'[src="'+ol(e)+'"]'}function Mi(e){return"script[async]"+e}function z0(e,t,l){if(t.count++,t.instance===null)switch(t.type){case"style":var n=e.querySelector('style[data-href~="'+ol(l.href)+'"]');if(n)return t.instance=n,zt(n),n;var a=B({},l,{"data-href":l.href,"data-precedence":l.precedence,href:null,precedence:null});return n=(e.ownerDocument||e).createElement("style"),zt(n),Ot(n,"style",a),Zo(n,l.precedence,e),t.instance=n;case"stylesheet":a=La(l.href);var i=e.querySelector(wi(a));if(i)return t.state.loading|=4,t.instance=i,zt(i),i;n=C0(l),(a=pl.get(a))&&vs(n,a),i=(e.ownerDocument||e).createElement("link"),zt(i);var r=i;return r._p=new Promise(function(d,m){r.onload=d,r.onerror=m}),Ot(i,"link",n),t.state.loading|=4,Zo(i,l.precedence,e),t.instance=i;case"script":return i=Ua(l.src),(a=e.querySelector(Mi(i)))?(t.instance=a,zt(a),a):(n=l,(a=pl.get(i))&&(n=B({},l),bs(n,a)),e=e.ownerDocument||e,a=e.createElement("script"),zt(a),Ot(a,"link",n),e.head.appendChild(a),t.instance=a);case"void":return null;default:throw Error(u(443,t.type))}else t.type==="stylesheet"&&(t.state.loading&4)===0&&(n=t.instance,t.state.loading|=4,Zo(n,l.precedence,e));return t.instance}function Zo(e,t,l){for(var n=l.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),a=n.length?n[n.length-1]:null,i=a,r=0;r<n.length;r++){var d=n[r];if(d.dataset.precedence===t)i=d;else if(i!==a)break}i?i.parentNode.insertBefore(e,i.nextSibling):(t=l.nodeType===9?l.head:l,t.insertBefore(e,t.firstChild))}function vs(e,t){e.crossOrigin==null&&(e.crossOrigin=t.crossOrigin),e.referrerPolicy==null&&(e.referrerPolicy=t.referrerPolicy),e.title==null&&(e.title=t.title)}function bs(e,t){e.crossOrigin==null&&(e.crossOrigin=t.crossOrigin),e.referrerPolicy==null&&(e.referrerPolicy=t.referrerPolicy),e.integrity==null&&(e.integrity=t.integrity)}var Ko=null;function w0(e,t,l){if(Ko===null){var n=new Map,a=Ko=new Map;a.set(l,n)}else a=Ko,n=a.get(l),n||(n=new Map,a.set(l,n));if(n.has(e))return n;for(n.set(e,null),l=l.getElementsByTagName(e),a=0;a<l.length;a++){var i=l[a];if(!(i[Ya]||i[Ae]||e==="link"&&i.getAttribute("rel")==="stylesheet")&&i.namespaceURI!=="http://www.w3.org/2000/svg"){var r=i.getAttribute(t)||"";r=e+r;var d=n.get(r);d?d.push(i):n.set(r,[i])}}return n}function M0(e,t,l){e=e.ownerDocument||e,e.head.insertBefore(l,t==="title"?e.querySelector("head > title"):null)}function Mm(e,t,l){if(l===1||t.itemProp!=null)return!1;switch(e){case"meta":case"title":return!0;case"style":if(typeof t.precedence!="string"||typeof t.href!="string"||t.href==="")break;return!0;case"link":if(typeof t.rel!="string"||typeof t.href!="string"||t.href===""||t.onLoad||t.onError)break;return t.rel==="stylesheet"?(e=t.disabled,typeof t.precedence=="string"&&e==null):!0;case"script":if(t.async&&typeof t.async!="function"&&typeof t.async!="symbol"&&!t.onLoad&&!t.onError&&t.src&&typeof t.src=="string")return!0}return!1}function T0(e){return!(e.type==="stylesheet"&&(e.state.loading&3)===0)}function Tm(e,t,l,n){if(l.type==="stylesheet"&&(typeof n.media!="string"||matchMedia(n.media).matches!==!1)&&(l.state.loading&4)===0){if(l.instance===null){var a=La(n.href),i=t.querySelector(wi(a));if(i){t=i._p,t!==null&&typeof t=="object"&&typeof t.then=="function"&&(e.count++,e=Jo.bind(e),t.then(e,e)),l.state.loading|=4,l.instance=i,zt(i);return}i=t.ownerDocument||t,n=C0(n),(a=pl.get(a))&&vs(n,a),i=i.createElement("link"),zt(i);var r=i;r._p=new Promise(function(d,m){r.onload=d,r.onerror=m}),Ot(i,"link",n),l.instance=i}e.stylesheets===null&&(e.stylesheets=new Map),e.stylesheets.set(l,t),(t=l.state.preload)&&(l.state.loading&3)===0&&(e.count++,l=Jo.bind(e),t.addEventListener("load",l),t.addEventListener("error",l))}}var xs=0;function Am(e,t){return e.stylesheets&&e.count===0&&$o(e,e.stylesheets),0<e.count||0<e.imgCount?function(l){var n=setTimeout(function(){if(e.stylesheets&&$o(e,e.stylesheets),e.unsuspend){var i=e.unsuspend;e.unsuspend=null,i()}},6e4+t);0<e.imgBytes&&xs===0&&(xs=62500*rm());var a=setTimeout(function(){if(e.waitingForImages=!1,e.count===0&&(e.stylesheets&&$o(e,e.stylesheets),e.unsuspend)){var i=e.unsuspend;e.unsuspend=null,i()}},(e.imgBytes>xs?50:800)+t);return e.unsuspend=l,function(){e.unsuspend=null,clearTimeout(n),clearTimeout(a)}}:null}function Jo(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)$o(this,this.stylesheets);else if(this.unsuspend){var e=this.unsuspend;this.unsuspend=null,e()}}}var Fo=null;function $o(e,t){e.stylesheets=null,e.unsuspend!==null&&(e.count++,Fo=new Map,t.forEach(Em,e),Fo=null,Jo.call(e))}function Em(e,t){if(!(t.state.loading&4)){var l=Fo.get(e);if(l)var n=l.get(null);else{l=new Map,Fo.set(e,l);for(var a=e.querySelectorAll("link[data-precedence],style[data-precedence]"),i=0;i<a.length;i++){var r=a[i];(r.nodeName==="LINK"||r.getAttribute("media")!=="not all")&&(l.set(r.dataset.precedence,r),n=r)}n&&l.set(null,n)}a=t.instance,r=a.getAttribute("data-precedence"),i=l.get(r)||n,i===n&&l.set(null,a),l.set(r,a),this.count++,n=Jo.bind(this),a.addEventListener("load",n),a.addEventListener("error",n),i?i.parentNode.insertBefore(a,i.nextSibling):(e=e.nodeType===9?e.head:e,e.insertBefore(a,e.firstChild)),t.state.loading|=4}}var Ti={$$typeof:le,Provider:null,Consumer:null,_currentValue:P,_currentValue2:P,_threadCount:0};function _m(e,t,l,n,a,i,r,d,m){this.tag=1,this.containerInfo=e,this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.next=this.pendingContext=this.context=this.cancelPendingCommit=null,this.callbackPriority=0,this.expirationTimes=Pn(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Pn(0),this.hiddenUpdates=Pn(null),this.identifierPrefix=n,this.onUncaughtError=a,this.onCaughtError=i,this.onRecoverableError=r,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=m,this.incompleteTransitions=new Map}function A0(e,t,l,n,a,i,r,d,m,w,R,N){return e=new _m(e,t,l,r,m,w,R,N,d),t=1,i===!0&&(t|=24),i=$t(3,null,null,t),e.current=i,i.stateNode=e,t=Pr(),t.refCount++,e.pooledCache=t,t.refCount++,i.memoizedState={element:n,isDehydrated:l,cache:t},nc(i),e}function E0(e){return e?(e=da,e):da}function _0(e,t,l,n,a,i){a=E0(a),n.context===null?n.context=a:n.pendingContext=a,n=on(t),n.payload={element:l},i=i===void 0?null:i,i!==null&&(n.callback=i),l=rn(e,n,t),l!==null&&(Qt(l,e,t),ai(l,e,t))}function k0(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var l=e.retryLane;e.retryLane=l!==0&&l<t?l:t}}function Ss(e,t){k0(e,t),(e=e.alternate)&&k0(e,t)}function D0(e){if(e.tag===13||e.tag===31){var t=Ln(e,67108864);t!==null&&Qt(t,e,67108864),Ss(e,67108864)}}function O0(e){if(e.tag===13||e.tag===31){var t=tl();t=Re(t);var l=Ln(e,t);l!==null&&Qt(l,e,t),Ss(e,t)}}var Wo=!0;function km(e,t,l,n){var a=A.T;A.T=null;var i=G.p;try{G.p=2,Cs(e,t,l,n)}finally{G.p=i,A.T=a}}function Dm(e,t,l,n){var a=A.T;A.T=null;var i=G.p;try{G.p=8,Cs(e,t,l,n)}finally{G.p=i,A.T=a}}function Cs(e,t,l,n){if(Wo){var a=zs(n);if(a===null)cs(e,t,n,Io,l),L0(e,n);else if(Rm(a,e,t,l,n))n.stopPropagation();else if(L0(e,n),t&4&&-1<Om.indexOf(e)){for(;a!==null;){var i=ta(a);if(i!==null)switch(i.tag){case 3:if(i=i.stateNode,i.current.memoizedState.isDehydrated){var r=kl(i.pendingLanes);if(r!==0){var d=i;for(d.pendingLanes|=2,d.entangledLanes|=2;r;){var m=1<<31-Bt(r);d.entanglements[1]|=m,r&=~m}Ml(i),(Je&6)===0&&(Lo=Ht()+500,xi(0))}}break;case 31:case 13:d=Ln(i,2),d!==null&&Qt(d,i,2),Ho(),Ss(i,2)}if(i=zs(n),i===null&&cs(e,t,n,Io,l),i===a)break;a=i}a!==null&&n.stopPropagation()}else cs(e,t,n,null,l)}}function zs(e){return e=Mr(e),ws(e)}var Io=null;function ws(e){if(Io=null,e=ea(e),e!==null){var t=p(e);if(t===null)e=null;else{var l=t.tag;if(l===13){if(e=k(t),e!==null)return e;e=null}else if(l===31){if(e=U(t),e!==null)return e;e=null}else if(l===3){if(t.stateNode.current.memoizedState.isDehydrated)return t.tag===3?t.stateNode.containerInfo:null;e=null}else t!==e&&(e=null)}}return Io=e,null}function R0(e){switch(e){case"beforetoggle":case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"resize":case"seeked":case"submit":case"toggle":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 2;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 8;case"message":switch(hr()){case Yi:return 2;case Gi:return 8;case Fn:case pr:return 32;case Vi:return 268435456;default:return 32}default:return 32}}var Ms=!1,vn=null,bn=null,xn=null,Ai=new Map,Ei=new Map,Sn=[],Om="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 L0(e,t){switch(e){case"focusin":case"focusout":vn=null;break;case"dragenter":case"dragleave":bn=null;break;case"mouseover":case"mouseout":xn=null;break;case"pointerover":case"pointerout":Ai.delete(t.pointerId);break;case"gotpointercapture":case"lostpointercapture":Ei.delete(t.pointerId)}}function _i(e,t,l,n,a,i){return e===null||e.nativeEvent!==i?(e={blockedOn:t,domEventName:l,eventSystemFlags:n,nativeEvent:i,targetContainers:[a]},t!==null&&(t=ta(t),t!==null&&D0(t)),e):(e.eventSystemFlags|=n,t=e.targetContainers,a!==null&&t.indexOf(a)===-1&&t.push(a),e)}function Rm(e,t,l,n,a){switch(t){case"focusin":return vn=_i(vn,e,t,l,n,a),!0;case"dragenter":return bn=_i(bn,e,t,l,n,a),!0;case"mouseover":return xn=_i(xn,e,t,l,n,a),!0;case"pointerover":var i=a.pointerId;return Ai.set(i,_i(Ai.get(i)||null,e,t,l,n,a)),!0;case"gotpointercapture":return i=a.pointerId,Ei.set(i,_i(Ei.get(i)||null,e,t,l,n,a)),!0}return!1}function U0(e){var t=ea(e.target);if(t!==null){var l=p(t);if(l!==null){if(t=l.tag,t===13){if(t=k(l),t!==null){e.blockedOn=t,De(e.priority,function(){O0(l)});return}}else if(t===31){if(t=U(l),t!==null){e.blockedOn=t,De(e.priority,function(){O0(l)});return}}else if(t===3&&l.stateNode.current.memoizedState.isDehydrated){e.blockedOn=l.tag===3?l.stateNode.containerInfo:null;return}}}e.blockedOn=null}function Po(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var l=zs(e.nativeEvent);if(l===null){l=e.nativeEvent;var n=new l.constructor(l.type,l);wr=n,l.target.dispatchEvent(n),wr=null}else return t=ta(l),t!==null&&D0(t),e.blockedOn=l,!1;t.shift()}return!0}function H0(e,t,l){Po(e)&&l.delete(t)}function Lm(){Ms=!1,vn!==null&&Po(vn)&&(vn=null),bn!==null&&Po(bn)&&(bn=null),xn!==null&&Po(xn)&&(xn=null),Ai.forEach(H0),Ei.forEach(H0)}function er(e,t){e.blockedOn===t&&(e.blockedOn=null,Ms||(Ms=!0,o.unstable_scheduleCallback(o.unstable_NormalPriority,Lm)))}var tr=null;function N0(e){tr!==e&&(tr=e,o.unstable_scheduleCallback(o.unstable_NormalPriority,function(){tr===e&&(tr=null);for(var t=0;t<e.length;t+=3){var l=e[t],n=e[t+1],a=e[t+2];if(typeof n!="function"){if(ws(n||l)===null)continue;break}var i=ta(l);i!==null&&(e.splice(t,3),t-=3,zc(i,{pending:!0,data:a,method:l.method,action:n},n,a))}}))}function Ha(e){function t(m){return er(m,e)}vn!==null&&er(vn,e),bn!==null&&er(bn,e),xn!==null&&er(xn,e),Ai.forEach(t),Ei.forEach(t);for(var l=0;l<Sn.length;l++){var n=Sn[l];n.blockedOn===e&&(n.blockedOn=null)}for(;0<Sn.length&&(l=Sn[0],l.blockedOn===null);)U0(l),l.blockedOn===null&&Sn.shift();if(l=(e.ownerDocument||e).$$reactFormReplay,l!=null)for(n=0;n<l.length;n+=3){var a=l[n],i=l[n+1],r=a[me]||null;if(typeof i=="function")r||N0(l);else if(r){var d=null;if(i&&i.hasAttribute("formAction")){if(a=i,r=i[me]||null)d=r.formAction;else if(ws(a)!==null)continue}else d=r.action;typeof d=="function"?l[n+1]=d:(l.splice(n,3),n-=3),N0(l)}}}function B0(){function e(i){i.canIntercept&&i.info==="react-transition"&&i.intercept({handler:function(){return new Promise(function(r){return a=r})},focusReset:"manual",scroll:"manual"})}function t(){a!==null&&(a(),a=null),n||setTimeout(l,20)}function l(){if(!n&&!navigation.transition){var i=navigation.currentEntry;i&&i.url!=null&&navigation.navigate(i.url,{state:i.getState(),info:"react-transition",history:"replace"})}}if(typeof navigation=="object"){var n=!1,a=null;return navigation.addEventListener("navigate",e),navigation.addEventListener("navigatesuccess",t),navigation.addEventListener("navigateerror",t),setTimeout(l,100),function(){n=!0,navigation.removeEventListener("navigate",e),navigation.removeEventListener("navigatesuccess",t),navigation.removeEventListener("navigateerror",t),a!==null&&(a(),a=null)}}}function Ts(e){this._internalRoot=e}lr.prototype.render=Ts.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(u(409));var l=t.current,n=tl();_0(l,n,e,t,null,null)},lr.prototype.unmount=Ts.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;_0(e.current,2,null,e,null,null),Ho(),t[Xe]=null}};function lr(e){this._internalRoot=e}lr.prototype.unstable_scheduleHydration=function(e){if(e){var t=Ve();e={blockedOn:null,target:e,priority:t};for(var l=0;l<Sn.length&&t!==0&&t<Sn[l].priority;l++);Sn.splice(l,0,e),l===0&&U0(e)}};var j0=s.version;if(j0!=="19.2.4")throw Error(u(527,j0,"19.2.4"));G.findDOMNode=function(e){var t=e._reactInternals;if(t===void 0)throw typeof e.render=="function"?Error(u(188)):(e=Object.keys(e).join(","),Error(u(268,e)));return e=S(t),e=e!==null?Y(e):null,e=e===null?null:e.stateNode,e};var Um={bundleType:0,version:"19.2.4",rendererPackageName:"react-dom",currentDispatcherRef:A,reconcilerVersion:"19.2.4"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var nr=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!nr.isDisabled&&nr.supportsFiber)try{Tn=nr.inject(Um),Nt=nr}catch{}}return Oi.createRoot=function(e,t){if(!g(e))throw Error(u(299));var l=!1,n="",a=Zf,i=Kf,r=Jf;return t!=null&&(t.unstable_strictMode===!0&&(l=!0),t.identifierPrefix!==void 0&&(n=t.identifierPrefix),t.onUncaughtError!==void 0&&(a=t.onUncaughtError),t.onCaughtError!==void 0&&(i=t.onCaughtError),t.onRecoverableError!==void 0&&(r=t.onRecoverableError)),t=A0(e,1,!1,null,null,l,n,null,a,i,r,B0),e[Xe]=t.current,rs(e),new Ts(t)},Oi.hydrateRoot=function(e,t,l){if(!g(e))throw Error(u(299));var n=!1,a="",i=Zf,r=Kf,d=Jf,m=null;return l!=null&&(l.unstable_strictMode===!0&&(n=!0),l.identifierPrefix!==void 0&&(a=l.identifierPrefix),l.onUncaughtError!==void 0&&(i=l.onUncaughtError),l.onCaughtError!==void 0&&(r=l.onCaughtError),l.onRecoverableError!==void 0&&(d=l.onRecoverableError),l.formState!==void 0&&(m=l.formState)),t=A0(e,1,!0,t,l??null,n,a,m,i,r,d,B0),t.context=E0(null),l=t.current,n=tl(),n=Re(n),a=on(n),a.callback=null,rn(l,a,n),l=n,t.current.lanes=l,En(t,l),Ml(t),e[Xe]=t.current,rs(e),new lr(t)},Oi.version="19.2.4",Oi}var ih;function Y1(){if(ih)return Os.exports;ih=1;function o(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(o)}catch(s){console.error(s)}}return o(),Os.exports=q1(),Os.exports}var G1=Y1(),oh=function(s,h){var u=arguments;if(h==null||!ji.call(h,"css"))return M.createElement.apply(void 0,u);var g=u.length,p=new Array(g);p[0]=Ks,p[1]=Zs(s,h);for(var k=2;k<g;k++)p[k]=u[k];return M.createElement.apply(null,p)};(function(o){var s;s||(s=o.JSX||(o.JSX={}))})(oh||(oh={}));function b(){for(var o=arguments.length,s=new Array(o),h=0;h<o;h++)s[h]=arguments[h];return xh(s)}function Wl(){var o=b.apply(void 0,arguments),s="animation-"+o.name;return{name:s,styles:"@keyframes "+s+"{"+o.styles+"}",anim:1,toString:function(){return"_EMO_"+this.name+"_"+this.styles+"_EMO_"}}}const V1={showProgress:!1,progressTitle:"",progressState:{current:0,total:0,percent:0,status:"processing"},showDeleteConfirm:!1,showMoveModal:!1,showSyncConfirm:!1,showProcessConfirm:!1,actionPaths:[],syncImageCount:0,syncHasRemote:!1,syncHasLocal:!1,processMode:"generate"},X1={isOpen:!1,openStudio:()=>{},closeStudio:()=>{},toggleStudio:()=>{},currentPath:"public",setCurrentPath:()=>{},navigateUp:()=>{},selectedItems:new Set,toggleSelection:()=>{},selectRange:()=>{},selectAll:()=>{},clearSelection:()=>{},lastSelectedPath:null,viewMode:"grid",setViewMode:()=>{},focusedItem:null,setFocusedItem:()=>{},meta:null,setMeta:()=>{},isLoading:!1,setIsLoading:()=>{},refreshKey:0,triggerRefresh:()=>{},scanRequested:!1,triggerScan:()=>{},clearScanRequest:()=>{},searchQuery:"",setSearchQuery:()=>{},error:null,showError:()=>{},clearError:()=>{},fileItems:[],setFileItems:()=>{},actionState:V1,requestDelete:()=>{},requestMove:()=>{},requestSync:()=>{},requestProcess:()=>{},setProcessMode:()=>{},confirmDelete:async()=>{},confirmMove:async()=>{},confirmSync:async()=>{},confirmProcess:async()=>{},cancelAction:()=>{},closeProgress:()=>{},stopProcessing:()=>{},abortController:null,deleteOrphans:async()=>{}},Ch=M.createContext(X1);function ja(){return M.useContext(Ch)}const dr="-apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Ubuntu, sans-serif",f={primary:"#635bff",primaryHover:"#5851e5",primaryLight:"#f0f0ff",background:"#f6f9fc",surface:"#ffffff",surfaceHover:"#f6f9fc",border:"#d8dee4",borderLight:"#e3e8ee",borderHover:"#c1c9d2",text:"#1a1f36",textSecondary:"#697386",textMuted:"#8792a2",success:"#0d7d4d",danger:"#df1b41",dangerHover:"#c41535",dangerLight:"#fff5f7",imagesFolder:"#8b5cf6"},K={xs:"13px",sm:"14px",base:"16px",lg:"19px",xl:"22px"},qi=b("font-family:",dr,";font-size:",K.base,";line-height:1.5;color:",f.text,";-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;box-sizing:border-box;*,*::before,*::after{box-sizing:border-box;}button,input,select,textarea{font-family:inherit;font-size:inherit;}",""),Q1=Wl`
|
|
10
|
+
from { opacity: 0; }
|
|
11
|
+
to { opacity: 1; }
|
|
12
|
+
`,Z1=Wl`
|
|
13
|
+
from {
|
|
14
|
+
opacity: 0;
|
|
15
|
+
transform: translateY(-8px) scale(0.98);
|
|
16
|
+
}
|
|
17
|
+
to {
|
|
18
|
+
opacity: 1;
|
|
19
|
+
transform: translateY(0) scale(1);
|
|
20
|
+
}
|
|
21
|
+
`,Se={overlay:b("position:fixed;inset:0;background-color:rgba(26, 31, 54, 0.4);backdrop-filter:blur(4px);display:flex;align-items:center;justify-content:center;z-index:10000;animation:",Q1," 0.15s ease-out;font-family:",dr,";",""),modal:b(qi," background-color:",f.surface,";border-radius:12px;box-shadow:0 30px 60px -12px rgba(50, 50, 93, 0.25),0 18px 36px -18px rgba(0, 0, 0, 0.3);max-width:420px;width:90%;animation:",Z1," 0.2s ease-out;overflow:hidden;",""),header:{name:"nsgk6m",styles:"padding:24px 24px 0"},title:b("font-size:",K.lg,";font-weight:600;color:",f.text,";margin:0;letter-spacing:-0.02em;",""),body:{name:"5e7rpo",styles:"padding:12px 24px 24px"},message:b("font-size:",K.base,";color:",f.textSecondary,";margin:0;line-height:1.6;",""),footer:b("display:flex;justify-content:flex-end;gap:12px;padding:16px 24px;border-top:1px solid ",f.border,";background-color:",f.background,";",""),btn:b("padding:10px 18px;font-size:",K.base,";font-weight:500;border-radius:6px;cursor:pointer;transition:all 0.15s ease;letter-spacing:-0.01em;",""),btnCancel:b("background-color:",f.surface,";border:1px solid ",f.border,";color:",f.text,";&:hover{background-color:",f.surfaceHover,";border-color:",f.borderHover,";}",""),btnConfirm:b("background-color:",f.primary,";border:1px solid ",f.primary,";color:white;&:hover{background-color:",f.primaryHover,";border-color:",f.primaryHover,";}",""),btnDanger:b("background-color:",f.danger,";border:1px solid ",f.danger,";color:white;&:hover{background-color:",f.dangerHover,";border-color:",f.dangerHover,";}","")};function Ri({title:o,message:s,confirmLabel:h="Confirm",cancelLabel:u="Cancel",variant:g="default",onConfirm:p,onCancel:k}){return c("div",{css:Se.overlay,onClick:k,children:x("div",{css:Se.modal,onClick:U=>U.stopPropagation(),children:[c("div",{css:Se.header,children:c("h3",{css:Se.title,children:o})}),c("div",{css:Se.body,children:c("p",{css:Se.message,children:s})}),x("div",{css:Se.footer,children:[c("button",{css:[Se.btn,Se.btnCancel,"",""],onClick:k,children:u}),c("button",{css:[Se.btn,g==="danger"?Se.btnDanger:Se.btnConfirm,"",""],onClick:p,children:h})]})]})})}const K1={input:b("width:100%;padding:10px 12px;font-size:",K.base,";border:1px solid ",f.border,";border-radius:6px;background:",f.surface,";color:",f.text,";margin-top:12px;transition:all 0.15s ease;&:focus{outline:none;border-color:",f.primary,";box-shadow:0 0 0 2px ",f.primaryLight,";}&::placeholder{color:",f.textMuted,";}","")};function Ys({title:o,message:s,inputLabel:h,defaultValue:u="",placeholder:g,confirmLabel:p="Confirm",cancelLabel:k="Cancel",onConfirm:U,onCancel:D}){const[S,Y]=uh.useState(u),B=W=>{W.preventDefault(),S.trim()&&U(S.trim())};return c("div",{css:Se.overlay,onClick:D,children:c("div",{css:Se.modal,onClick:W=>W.stopPropagation(),children:x("form",{onSubmit:B,children:[c("div",{css:Se.header,children:c("h3",{css:Se.title,children:o})}),x("div",{css:Se.body,children:[s&&c("p",{css:Se.message,children:s}),h&&c("label",{css:Se.message,children:h}),c("input",{css:K1.input,type:"text",value:S,onChange:W=>Y(W.target.value),placeholder:g,autoFocus:!0})]}),x("div",{css:Se.footer,children:[c("button",{type:"button",css:[Se.btn,Se.btnCancel,"",""],onClick:D,children:k}),c("button",{type:"submit",css:[Se.btn,Se.btnConfirm,"",""],disabled:!S.trim(),children:p})]})]})})})}function zh({title:o,message:s,buttonLabel:h="OK",onClose:u}){return c("div",{css:Se.overlay,onClick:u,children:x("div",{css:Se.modal,onClick:g=>g.stopPropagation(),children:[c("div",{css:Se.header,children:c("h3",{css:Se.title,children:o})}),c("div",{css:Se.body,children:c("p",{css:Se.message,children:s})}),c("div",{css:Se.footer,children:c("button",{css:[Se.btn,Se.btnConfirm,"",""],onClick:u,children:h})})]})})}const zn={progressContainer:{name:"yz1nei",styles:"margin-top:16px"},progressBar:b("width:100%;height:8px;background-color:",f.background,";border-radius:4px;overflow:hidden;margin-bottom:12px;",""),progressFill:b("height:100%;background:linear-gradient(90deg, ",f.primary,", ",f.primaryHover,");border-radius:4px;transition:width 0.3s ease;",""),progressText:b("font-size:",K.sm,";color:",f.textSecondary,";margin:0;display:flex;justify-content:space-between;align-items:center;",""),currentFile:b("font-size:",K.xs,";color:",f.textMuted,";margin:8px 0 0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;",""),errorList:{name:"1lw22n1",styles:"margin-top:12px;padding:12px;background:#fef2f2;border:1px solid #fecaca;border-radius:6px;max-height:200px;overflow-y:auto"},errorItem:b("font-size:",K.xs,";color:#991b1b;margin:0 0 4px;&:last-child{margin-bottom:0;}","")};function Js({title:o,progress:s,onClose:h,onDeleteOrphans:u,onStop:g}){const p=s.status==="complete",k=s.status==="error",U=s.status==="stopped",D=p||k||U,S=!D;return c("div",{css:Se.overlay,children:x("div",{css:Se.modal,onClick:Y=>Y.stopPropagation(),children:[c("div",{css:Se.header,children:c("h3",{css:Se.title,children:o})}),c("div",{css:Se.body,children:k?c("p",{css:Se.message,children:s.message||"An error occurred"}):U?x("p",{css:Se.message,children:["Processing stopped. Processed ",s.processed??s.current," image",(s.processed??s.current)!==1?"s":""," before stopping."]}):p?x(Tt,{children:[x("p",{css:Se.message,children:[s.message?s.message:s.isMove?x(Tt,{children:["Moved ",s.processed," file",s.processed!==1?"s":"",".",s.errors!==void 0&&s.errors>0?x(Tt,{children:[" ",s.errors," error",s.errors!==1?"s":""," occurred."]}):null]}):s.isScan?x(Tt,{children:[s.alreadyProcessed!==void 0&&s.alreadyProcessed>0?x(Tt,{children:[s.alreadyProcessed," image",s.alreadyProcessed!==1?"s":""," already exist. "]}):null,"Scanned ",s.processed," new image",s.processed!==1?"s":"",".",s.orphanedEntries!==void 0&&s.orphanedEntries>0?x(Tt,{children:[" Removed ",s.orphanedEntries," orphaned entr",s.orphanedEntries!==1?"ies":"y","."]}):null,s.pendingUpdates!==void 0&&s.pendingUpdates>0?x(Tt,{children:[" ",s.pendingUpdates," file",s.pendingUpdates!==1?"s have":" has"," local updates pending."]}):null]}):x(Tt,{children:["Processed ",s.processed," new image",s.processed!==1?"s":"",".",s.alreadyProcessed!==void 0&&s.alreadyProcessed>0?x(Tt,{children:[" ",s.alreadyProcessed," already processed."]}):null]}),s.orphansRemoved!==void 0&&s.orphansRemoved>0?x(Tt,{children:[" Removed ",s.orphansRemoved," orphaned thumbnail",s.orphansRemoved!==1?"s":"","."]}):null]}),s.errorMessages&&s.errorMessages.length>0&&x("div",{css:zn.errorList,children:[s.errorMessages.slice(0,10).map((Y,B)=>c("p",{css:zn.errorItem,children:Y},B)),s.errorMessages.length>10&&x("p",{css:zn.errorItem,children:["...and ",s.errorMessages.length-10," more"]})]})]}):x(Tt,{children:[c("p",{css:Se.message,children:s.status==="cleanup"?s.message||"Cleaning up...":s.message||"Processing..."}),x("div",{css:zn.progressContainer,children:[c("div",{css:zn.progressBar,children:c("div",{css:zn.progressFill,style:{width:`${s.percent}%`}})}),x("div",{css:zn.progressText,children:[x("span",{children:[s.current," of ",s.total]}),x("span",{children:[s.percent,"%"]})]}),s.currentFile&&c("p",{css:zn.currentFile,title:s.currentFile,children:s.currentFile})]})]})}),x("div",{css:Se.footer,children:[S&&g&&c("button",{css:[Se.btn,Se.btnDanger,"",""],onClick:g,children:"Stop"}),D&&s.orphanedFiles&&s.orphanedFiles.length>0&&u&&x("button",{css:[Se.btn,Se.btnDanger,"",""],onClick:u,children:["Delete ",s.orphanedFiles.length," Orphan",s.orphanedFiles.length!==1?"s":""]}),D&&c("button",{css:[Se.btn,Se.btnConfirm,"",""],onClick:h,children:"Done"})]})]})})}const J1=Wl`
|
|
22
|
+
from { opacity: 0; }
|
|
23
|
+
to { opacity: 1; }
|
|
24
|
+
`,F1=Wl`
|
|
25
|
+
from {
|
|
26
|
+
opacity: 0;
|
|
27
|
+
transform: translateY(-8px) scale(0.98);
|
|
28
|
+
}
|
|
29
|
+
to {
|
|
30
|
+
opacity: 1;
|
|
31
|
+
transform: translateY(0) scale(1);
|
|
32
|
+
}
|
|
33
|
+
`,dt={overlay:b("position:fixed;inset:0;background-color:rgba(26, 31, 54, 0.4);backdrop-filter:blur(4px);display:flex;align-items:center;justify-content:center;z-index:10000;animation:",J1," 0.15s ease-out;font-family:",dr,";",""),modal:b(qi," background-color:",f.surface,";border-radius:12px;box-shadow:0 30px 60px -12px rgba(50, 50, 93, 0.25),0 18px 36px -18px rgba(0, 0, 0, 0.3);max-width:480px;width:90%;max-height:80vh;display:flex;flex-direction:column;animation:",F1," 0.2s ease-out;overflow:hidden;",""),header:{name:"nsgk6m",styles:"padding:24px 24px 0"},title:b("font-size:",K.lg,";font-weight:600;color:",f.text,";margin:0;letter-spacing:-0.02em;",""),body:{name:"zizupt",styles:"padding:12px 24px 24px;flex:1;overflow-y:auto;min-height:200px;max-height:400px"},message:b("font-size:",K.base,";color:",f.textSecondary,";margin:0 0 16px;line-height:1.6;",""),folderList:{name:"1axgfg3",styles:"display:flex;flex-direction:column;gap:0"},folderItem:b("display:flex;align-items:center;gap:8px;padding:8px 12px;border-radius:6px;cursor:pointer;transition:all 0.15s ease;border:1px solid transparent;position:relative;&:hover{background-color:",f.surfaceHover,";}",""),treeIndent:{name:"197dxto",styles:"display:flex;align-items:center;height:100%"},treeLine:b("width:16px;height:100%;position:relative;flex-shrink:0;&::before{content:'';position:absolute;left:8px;top:0;bottom:50%;width:0;border-left:1px dashed ",f.textSecondary,";}&::after{content:'';position:absolute;left:8px;top:50%;width:8px;height:0;border-top:1px dashed ",f.textSecondary,";}",""),folderItemSelected:b("background-color:",f.primaryLight,";border-color:",f.primary,";&:hover{background-color:",f.primaryLight,";}",""),folderItemDisabled:{name:"181lhkw",styles:"opacity:0.5;cursor:not-allowed;&:hover{background-color:transparent;}"},folderIcon:{name:"17bs1oo",styles:"width:20px;height:20px;color:#f9935e;flex-shrink:0"},folderName:b("font-size:",K.base,";color:",f.text,";flex:1;",""),footer:b("display:flex;justify-content:flex-end;gap:12px;padding:16px 24px;border-top:1px solid ",f.border,";background-color:",f.background,";",""),btn:b("padding:10px 18px;font-size:",K.base,";font-weight:500;border-radius:6px;cursor:pointer;transition:all 0.15s ease;letter-spacing:-0.01em;",""),btnCancel:b("background-color:",f.surface,";border:1px solid ",f.border,";color:",f.text,";&:hover{background-color:",f.surfaceHover,";border-color:",f.borderHover,";}",""),btnConfirm:b("background-color:",f.primary,";border:1px solid ",f.primary,";color:white;&:hover:not(:disabled){background-color:",f.primaryHover,";border-color:",f.primaryHover,";}&:disabled{opacity:0.5;cursor:not-allowed;}",""),loading:b("display:flex;align-items:center;justify-content:center;padding:40px;color:",f.textSecondary,";",""),spinner:b("width:24px;height:24px;border-radius:50%;border:3px solid ",f.border,";border-top-color:",f.primary,";animation:spin 0.8s linear infinite;@keyframes spin{to{transform:rotate(360deg);}}","")};function wh({selectedItems:o,currentPath:s,onMove:h,onCancel:u}){const[g,p]=M.useState([]),[k,U]=M.useState(!0),[D,S]=M.useState(null);M.useEffect(()=>{async function V(){try{const q=await fetch("/api/studio/list-folders");if(q.ok){const de=await q.json();console.log("Loaded folders:",de),p(de.folders||[])}else console.error("Failed to load folders:",q.status,await q.text())}catch(q){console.error("Failed to load folders:",q)}finally{U(!1)}}V()},[]);const Y=Array.from(o),B=g.filter(V=>!Y.some(q=>V.path===q||V.path.startsWith(q+"/"))),W=V=>V===s,$=()=>{D&&h(D)};return c("div",{css:dt.overlay,onClick:u,children:x("div",{css:dt.modal,onClick:V=>V.stopPropagation(),children:[c("div",{css:dt.header,children:c("h3",{css:dt.title,children:"Move Items"})}),x("div",{css:dt.body,children:[x("p",{css:dt.message,children:["Select a destination folder for ",o.size," item",o.size!==1?"s":"",":"]}),k?c("div",{css:dt.loading,children:c("div",{css:dt.spinner})}):B.length===0?c("div",{css:dt.loading,children:"No available folders to move to."}):c("div",{css:dt.folderList,children:B.map(V=>{const q=W(V.path);return x("div",{css:[dt.folderItem,D===V.path&&dt.folderItemSelected,q&&dt.folderItemDisabled,"",""],style:{paddingLeft:12},onClick:()=>!q&&S(V.path),children:[V.depth>0&&c("div",{css:dt.treeIndent,children:Array.from({length:V.depth}).map((de,I)=>c("div",{css:dt.treeLine},I))}),c("svg",{css:dt.folderIcon,fill:"currentColor",viewBox:"0 0 24 24",children:c("path",{d:"M10 4H4a2 2 0 00-2 2v12a2 2 0 002 2h16a2 2 0 002-2V8a2 2 0 00-2-2h-8l-2-2z"})}),x("span",{css:dt.folderName,children:[V.name,q&&" (current)"]})]},V.path)})})]}),x("div",{css:dt.footer,children:[c("button",{css:[dt.btn,dt.btnCancel,"",""],onClick:u,children:"Cancel"}),c("button",{css:[dt.btn,dt.btnConfirm,"",""],onClick:$,disabled:!D,children:"Move Here"})]})]})})}const $1=`CLOUDFLARE_R2_ACCOUNT_ID=your_account_id
|
|
34
|
+
CLOUDFLARE_R2_ACCESS_KEY_ID=your_access_key
|
|
35
|
+
CLOUDFLARE_R2_SECRET_ACCESS_KEY=your_secret_key
|
|
36
|
+
CLOUDFLARE_R2_BUCKET_NAME=your_bucket_name
|
|
37
|
+
CLOUDFLARE_R2_PUBLIC_URL=https://pub-xxx.r2.dev
|
|
38
|
+
NEXT_PUBLIC_CLOUDFLARE_R2_PUBLIC_URL=https://pub-xxx.r2.dev`,ae={overlay:{name:"8ivopw",styles:"position:fixed;inset:0;background:rgba(0, 0, 0, 0.6);display:flex;align-items:center;justify-content:center;z-index:1100;padding:20px"},modal:b("background:",f.surface,";border-radius:12px;max-width:560px;width:100%;max-height:90vh;overflow-y:auto;box-shadow:0 20px 40px rgba(0, 0, 0, 0.3);",""),header:b("display:flex;align-items:center;gap:12px;padding:20px 24px;border-bottom:1px solid ",f.border,";",""),icon:b("width:32px;height:32px;color:",f.primary,";flex-shrink:0;",""),title:b("font-size:",K.xl,";font-weight:600;color:",f.text,";margin:0;",""),closeBtn:b("margin-left:auto;background:none;border:none;padding:4px;cursor:pointer;color:",f.textMuted,";border-radius:4px;&:hover{color:",f.text,";background:",f.surfaceHover,";}",""),closeIcon:{name:"1aynuae",styles:"width:20px;height:20px"},content:{name:"vxuddk",styles:"padding:24px"},intro:b("font-size:",K.base,";color:",f.textSecondary,";margin:0 0 20px 0;line-height:1.6;",""),steps:{name:"1fs2p21",styles:"list-style:none;padding:0;margin:0;display:flex;flex-direction:column;gap:16px"},step:{name:"1wesxqa",styles:"display:flex;gap:12px"},stepNumber:b("width:28px;height:28px;border-radius:50%;background:",f.primaryLight,";color:",f.primary,";font-size:",K.sm,";font-weight:600;display:flex;align-items:center;justify-content:center;flex-shrink:0;",""),stepContent:{name:"pkc2k3",styles:"flex:1;padding-top:3px"},stepTitle:b("font-size:",K.base,";font-weight:500;color:",f.text,";margin:0 0 4px 0;",""),stepDesc:b("font-size:",K.sm,";color:",f.textSecondary,";margin:0;line-height:1.5;",""),link:b("color:",f.primary,";text-decoration:none;font-weight:500;&:hover{text-decoration:underline;}",""),envVarsWrapper:{name:"1ksolcl",styles:"position:relative;margin-top:20px"},envVars:b("background:",f.background,";border:1px solid ",f.border,";border-radius:8px;padding:16px;padding-right:48px;font-family:'SF Mono',Monaco,'Cascadia Code',monospace;font-size:13px;line-height:1.8;color:",f.text,";overflow-x:auto;",""),envVar:{name:"4zleql",styles:"display:block"},envKey:b("color:",f.primary,";",""),envValue:b("color:",f.textSecondary,";",""),copyBtn:b("position:absolute;top:8px;right:8px;width:32px;height:32px;display:flex;align-items:center;justify-content:center;background:",f.surface,";border:1px solid ",f.border,";border-radius:6px;cursor:pointer;color:",f.textMuted,";transition:all 0.15s ease;&:hover{background:",f.surfaceHover,";color:",f.text,";border-color:#d0d5dd;}",""),copyIcon:{name:"157xhr7",styles:"width:16px;height:16px"},copiedTooltip:{name:"9a5yd1",styles:"position:absolute;top:50%;right:100%;transform:translateY(-50%);background:#1a1f36;color:white;padding:4px 8px;border-radius:4px;font-size:12px;white-space:nowrap;margin-right:6px;pointer-events:none;&::before{content:'';position:absolute;right:-4px;top:50%;transform:translateY(-50%);border-left:4px solid #1a1f36;border-top:4px solid transparent;border-bottom:4px solid transparent;}"},footer:b("padding:16px 24px;border-top:1px solid ",f.border,";display:flex;justify-content:flex-end;gap:12px;",""),docsBtn:b("padding:10px 16px;border-radius:6px;font-size:",K.base,";font-weight:500;border:1px solid ",f.border,";background:",f.surface,";color:",f.text,";cursor:pointer;text-decoration:none;display:inline-flex;align-items:center;gap:6px;transition:all 0.15s ease;&:hover{background:",f.surfaceHover,";border-color:#d0d5dd;}",""),doneBtn:b("padding:10px 20px;border-radius:6px;font-size:",K.base,";font-weight:500;border:none;background:",f.primary,";color:white;cursor:pointer;transition:background 0.15s ease;&:hover{background:",f.primaryHover,";}",""),externalIcon:{name:"1djxupe",styles:"width:14px;height:14px"}};function Mh({isOpen:o,onClose:s}){const[h,u]=M.useState(!1),g=async()=>{try{await navigator.clipboard.writeText($1),u(!0),setTimeout(()=>u(!1),2e3)}catch(p){console.error("Failed to copy:",p)}};return o?c("div",{css:ae.overlay,onClick:s,children:x("div",{css:ae.modal,onClick:p=>p.stopPropagation(),children:[x("div",{css:ae.header,children:[c("svg",{css:ae.icon,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:1.5,d:"M3 15a4 4 0 004 4h9a5 5 0 10-.1-9.999 5.002 5.002 0 10-9.78 2.096A4.001 4.001 0 003 15z"})}),c("h2",{css:ae.title,children:"Set Up CDN Storage"}),c("button",{css:ae.closeBtn,onClick:s,children:c("svg",{css:ae.closeIcon,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M6 18L18 6M6 6l12 12"})})})]}),x("div",{css:ae.content,children:[c("p",{css:ae.intro,children:"Sync your images to Cloudflare R2 for faster global delivery. R2 offers generous free tier with no egress fees."}),x("ol",{css:ae.steps,children:[x("li",{css:ae.step,children:[c("span",{css:ae.stepNumber,children:"1"}),x("div",{css:ae.stepContent,children:[c("h4",{css:ae.stepTitle,children:"Create a Cloudflare account"}),x("p",{css:ae.stepDesc,children:["Sign up at"," ",c("a",{css:ae.link,href:"https://dash.cloudflare.com/sign-up",target:"_blank",rel:"noopener noreferrer",children:"dash.cloudflare.com"})," ","if you don't have one already."]})]})]}),x("li",{css:ae.step,children:[c("span",{css:ae.stepNumber,children:"2"}),x("div",{css:ae.stepContent,children:[c("h4",{css:ae.stepTitle,children:"Create an R2 bucket"}),x("p",{css:ae.stepDesc,children:["Go to R2 in your Cloudflare dashboard and create a new bucket. Choose a name like ",c("code",{children:"my-images"}),"."]})]})]}),x("li",{css:ae.step,children:[c("span",{css:ae.stepNumber,children:"3"}),x("div",{css:ae.stepContent,children:[c("h4",{css:ae.stepTitle,children:"Enable public access"}),x("p",{css:ae.stepDesc,children:['In bucket settings, enable "Public Access" and copy the public URL (e.g., ',c("code",{children:"https://pub-xxx.r2.dev"}),")."]})]})]}),x("li",{css:ae.step,children:[c("span",{css:ae.stepNumber,children:"4"}),x("div",{css:ae.stepContent,children:[c("h4",{css:ae.stepTitle,children:"Create API token"}),c("p",{css:ae.stepDesc,children:'Go to R2 → Manage R2 API Tokens → Create API Token. Select "Object Read & Write" permissions for your bucket.'})]})]}),x("li",{css:ae.step,children:[c("span",{css:ae.stepNumber,children:"5"}),x("div",{css:ae.stepContent,children:[c("h4",{css:ae.stepTitle,children:"Add environment variables"}),x("p",{css:ae.stepDesc,children:["Add these to your ",c("code",{children:".env.local"})," file:"]})]})]})]}),x("div",{css:ae.envVarsWrapper,children:[x("div",{css:ae.envVars,children:[x("span",{css:ae.envVar,children:[c("span",{css:ae.envKey,children:"CLOUDFLARE_R2_ACCOUNT_ID"}),"=",c("span",{css:ae.envValue,children:"your_account_id"})]}),x("span",{css:ae.envVar,children:[c("span",{css:ae.envKey,children:"CLOUDFLARE_R2_ACCESS_KEY_ID"}),"=",c("span",{css:ae.envValue,children:"your_access_key"})]}),x("span",{css:ae.envVar,children:[c("span",{css:ae.envKey,children:"CLOUDFLARE_R2_SECRET_ACCESS_KEY"}),"=",c("span",{css:ae.envValue,children:"your_secret_key"})]}),x("span",{css:ae.envVar,children:[c("span",{css:ae.envKey,children:"CLOUDFLARE_R2_BUCKET_NAME"}),"=",c("span",{css:ae.envValue,children:"your_bucket_name"})]}),x("span",{css:ae.envVar,children:[c("span",{css:ae.envKey,children:"CLOUDFLARE_R2_PUBLIC_URL"}),"=",c("span",{css:ae.envValue,children:"https://pub-xxx.r2.dev"})]}),x("span",{css:ae.envVar,children:[c("span",{css:ae.envKey,children:"NEXT_PUBLIC_CLOUDFLARE_R2_PUBLIC_URL"}),"=",c("span",{css:ae.envValue,children:"https://pub-xxx.r2.dev"})]})]}),x("button",{css:ae.copyBtn,onClick:g,title:"Copy to clipboard",children:[h&&c("span",{css:ae.copiedTooltip,children:"Copied!"}),c("svg",{css:ae.copyIcon,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M8 16H6a2 2 0 01-2-2V6a2 2 0 012-2h8a2 2 0 012 2v2m-6 12h8a2 2 0 002-2v-8a2 2 0 00-2-2h-8a2 2 0 00-2 2v8a2 2 0 002 2z"})})]})]})]}),x("div",{css:ae.footer,children:[x("a",{css:ae.docsBtn,href:"https://developers.cloudflare.com/r2/get-started/",target:"_blank",rel:"noopener noreferrer",children:["R2 Documentation",c("svg",{css:ae.externalIcon,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M10 6H6a2 2 0 00-2 2v10a2 2 0 002 2h10a2 2 0 002-2v-4M14 4h6m0 0v6m0-6L10 14"})})]}),c("button",{css:ae.doneBtn,onClick:s,children:"Got it"})]})]})}):null}const W1=Wl`
|
|
39
|
+
from { opacity: 0; }
|
|
40
|
+
to { opacity: 1; }
|
|
41
|
+
`,I1=Wl`
|
|
42
|
+
from {
|
|
43
|
+
opacity: 0;
|
|
44
|
+
transform: translateY(-8px) scale(0.98);
|
|
45
|
+
}
|
|
46
|
+
to {
|
|
47
|
+
opacity: 1;
|
|
48
|
+
transform: translateY(0) scale(1);
|
|
49
|
+
}
|
|
50
|
+
`,ot={overlay:b("position:fixed;inset:0;background-color:rgba(26, 31, 54, 0.4);backdrop-filter:blur(4px);display:flex;align-items:center;justify-content:center;z-index:10000;animation:",W1," 0.15s ease-out;font-family:",dr,";",""),modal:b(qi," background-color:",f.surface,";border-radius:12px;box-shadow:0 30px 60px -12px rgba(50, 50, 93, 0.25),0 18px 36px -18px rgba(0, 0, 0, 0.3);max-width:520px;width:90%;animation:",I1," 0.2s ease-out;overflow:hidden;",""),header:{name:"nsgk6m",styles:"padding:24px 24px 0"},title:b("font-size:",K.lg,";font-weight:600;color:",f.text,";margin:0;letter-spacing:-0.02em;",""),tabs:b("display:flex;gap:0;margin-top:16px;border-bottom:1px solid ",f.border,";",""),tab:b("padding:12px 20px;font-size:",K.base,";font-weight:500;color:",f.textSecondary,";background:none;border:none;cursor:pointer;position:relative;transition:color 0.15s;&:hover{color:",f.text,";}",""),tabActive:b("color:",f.primary,";&::after{content:'';position:absolute;bottom:-1px;left:0;right:0;height:2px;background-color:",f.primary,";}",""),body:{name:"1po9b7e",styles:"padding:24px;min-height:200px"},dropzone:b("border:2px dashed ",f.border,";border-radius:8px;padding:40px 24px;text-align:center;cursor:pointer;transition:all 0.15s;&:hover{border-color:",f.primary,";background-color:",f.primaryLight,";}",""),dropzoneActive:b("border-color:",f.primary,";background-color:",f.primaryLight,";",""),dropzoneIcon:b("width:48px;height:48px;margin:0 auto 16px;color:",f.textMuted,";",""),dropzoneText:b("font-size:",K.base,";color:",f.text,";margin:0 0 4px;",""),dropzoneHint:b("font-size:",K.sm,";color:",f.textSecondary,";margin:0;",""),textarea:b("width:100%;min-height:150px;padding:12px;font-size:",K.sm,";font-family:ui-monospace,SFMono-Regular,'SF Mono',Menlo,Consolas,monospace;border:1px solid ",f.border,";border-radius:8px;resize:vertical;&:focus{outline:none;border-color:",f.primary,";box-shadow:0 0 0 3px ",f.primaryLight,";}&::placeholder{color:",f.textMuted,";}",""),textareaLabel:b("font-size:",K.sm,";color:",f.textSecondary,";margin:0 0 8px;",""),footer:b("display:flex;justify-content:flex-end;gap:12px;padding:16px 24px;border-top:1px solid ",f.border,";background-color:",f.background,";",""),btn:b("padding:10px 18px;font-size:",K.base,";font-weight:500;border-radius:6px;cursor:pointer;transition:all 0.15s ease;letter-spacing:-0.01em;",""),btnCancel:b("background-color:",f.surface,";border:1px solid ",f.border,";color:",f.text,";&:hover{background-color:",f.surfaceHover,";border-color:",f.borderHover,";}",""),btnConfirm:b("background-color:",f.primary,";border:1px solid ",f.primary,";color:white;&:hover:not(:disabled){background-color:",f.primaryHover,";border-color:",f.primaryHover,";}&:disabled{opacity:0.6;cursor:not-allowed;}",""),fileInput:{name:"eivff4",styles:"display:none"},selectedFiles:b("margin-top:16px;padding:12px;background-color:",f.background,";border-radius:6px;font-size:",K.sm,";color:",f.text,";","")};function P1({currentPath:o,onClose:s,onUploadComplete:h}){const[u,g]=M.useState("upload"),[p,k]=M.useState([]),[U,D]=M.useState(""),[S,Y]=M.useState(!1),[B,W]=M.useState(!1),[$,V]=M.useState(!1),q=M.useRef(null),de=M.useCallback(re=>{re&&k(Array.from(re))},[]),I=M.useCallback(re=>{re.preventDefault(),Y(!1),de(re.dataTransfer.files)},[de]),ue=M.useCallback(async()=>{if(p.length!==0){W(!0);try{for(const re of p){const _=new FormData;_.append("file",re),_.append("path",o),await fetch("/api/studio/upload",{method:"POST",body:_})}h(),s()}catch(re){console.error("Upload failed:",re)}finally{W(!1)}}},[p,o,h,s]),le=M.useCallback(async()=>{const re=U.split(`
|
|
51
|
+
`).map(_=>_.trim()).filter(_=>_.length>0);if(re.length!==0){V(!0);try{const X=(await fetch("/api/studio/import",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({urls:re})})).body?.getReader();if(!X)throw new Error("No reader");const j=new TextDecoder;for(;;){const{done:ge,value:He}=await X.read();if(ge)break;const Ne=j.decode(He).split(`
|
|
52
|
+
|
|
53
|
+
`).filter(Le=>Le.startsWith("data: "));for(const Le of Ne)JSON.parse(Le.replace("data: ","")).type==="complete"&&(h(),s())}}catch(_){console.error("Import failed:",_)}finally{V(!1)}}},[U,h,s]);return c("div",{css:ot.overlay,onClick:s,children:x("div",{css:ot.modal,onClick:re=>re.stopPropagation(),children:[x("div",{css:ot.header,children:[c("h3",{css:ot.title,children:"Add New"}),x("div",{css:ot.tabs,children:[c("button",{css:[ot.tab,u==="upload"&&ot.tabActive,"",""],onClick:()=>g("upload"),children:"Upload Files"}),c("button",{css:[ot.tab,u==="import"&&ot.tabActive,"",""],onClick:()=>g("import"),children:"Import URLs"})]})]}),c("div",{css:ot.body,children:u==="upload"?x(Tt,{children:[x("div",{css:[ot.dropzone,S&&ot.dropzoneActive,"",""],onClick:()=>q.current?.click(),onDragOver:re=>{re.preventDefault(),Y(!0)},onDragLeave:()=>Y(!1),onDrop:I,children:[c("svg",{css:ot.dropzoneIcon,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:1.5,d:"M7 16a4 4 0 01-.88-7.903A5 5 0 1115.9 6L16 6a5 5 0 011 9.9M15 13l-3-3m0 0l-3 3m3-3v12"})}),c("p",{css:ot.dropzoneText,children:"Drop files here or click to browse"}),c("p",{css:ot.dropzoneHint,children:"Supports images and other media files"})]}),c("input",{ref:q,type:"file",multiple:!0,css:ot.fileInput,onChange:re=>de(re.target.files)}),p.length>0&&x("div",{css:ot.selectedFiles,children:[p.length," file",p.length!==1?"s":""," selected"]})]}):x(Tt,{children:[c("p",{css:ot.textareaLabel,children:"Paste image URLs (one per line)"}),c("textarea",{css:ot.textarea,value:U,onChange:re=>D(re.target.value),placeholder:`https://cdn.example.com/photos/image1.jpg
|
|
54
|
+
https://cdn.example.com/photos/image2.jpg`})]})}),x("div",{css:ot.footer,children:[c("button",{css:[ot.btn,ot.btnCancel,"",""],onClick:s,children:"Cancel"}),u==="upload"?c("button",{css:[ot.btn,ot.btnConfirm,"",""],onClick:ue,disabled:p.length===0||B,children:B?"Uploading...":"Upload"}):c("button",{css:[ot.btn,ot.btnConfirm,"",""],onClick:le,disabled:!U.trim()||$,children:$?"Importing...":"Import"})]})]})})}const Hs="36px",eg=Wl`
|
|
55
|
+
to { transform: rotate(360deg); }
|
|
56
|
+
`,xe={toolbar:b("display:flex;flex-wrap:nowrap;align-items:center;justify-content:space-between;gap:8px;padding:12px 16px;background-color:",f.surface,";border-bottom:1px solid ",f.border,";overflow:visible;min-width:0;@media (min-width: 768px){padding:12px 24px;}",""),left:{name:"17nohj2",styles:"display:flex;flex-wrap:nowrap;flex-shrink:0;align-items:center;gap:8px"},right:{name:"17nohj2",styles:"display:flex;flex-wrap:nowrap;flex-shrink:0;align-items:center;gap:8px"},btn:b("display:inline-flex;align-items:center;justify-content:center;gap:6px;height:",Hs,";padding:0 14px;border-radius:6px;font-size:",K.base,";font-weight:500;background:",f.surface,";border:1px solid ",f.border,";cursor:pointer;transition:all 0.15s ease;color:",f.text,";letter-spacing:-0.01em;&:hover:not(:disabled){background-color:",f.surfaceHover,";border-color:",f.borderHover,";}&:disabled{cursor:not-allowed;opacity:0.5;}",""),btnPrimary:b("background:",f.primary,";border-color:",f.primary,";color:white;&:hover:not(:disabled){background:",f.primaryHover,";border-color:",f.primaryHover,";}",""),btnDanger:b("color:",f.danger,";&:hover:not(:disabled){background-color:",f.dangerLight,";border-color:",f.danger,";}",""),btnCloud:{name:"1lzbs29",styles:"color:#f59e0b;&:hover:not(:disabled){background-color:rgba(245, 158, 11, 0.1);border-color:#f59e0b;}"},cloudDropdownWrapper:{name:"bjn8wh",styles:"position:relative"},dropdownArrow:{name:"1j1hlpy",styles:"width:12px;height:12px;margin-left:4px"},cloudDropdown:b("position:absolute;top:100%;left:0;z-index:1000;min-width:160px;margin-top:4px;background:white;border:1px solid ",f.border,";border-radius:6px;box-shadow:0 4px 12px rgba(0, 0, 0, 0.15);overflow:hidden;",""),cloudDropdownItem:b("display:flex;align-items:center;gap:8px;width:100%;padding:10px 14px;border:none;background:none;font-size:",K.sm,";color:",f.text,";cursor:pointer;text-align:left;white-space:nowrap;&:hover{background-color:",f.hover,";}svg{width:16px;height:16px;flex-shrink:0;color:#f59e0b;}",""),cloudDropdownItemDanger:b("color:",f.danger,";svg{color:",f.danger,";}",""),cloudDropdownDivider:b("height:1px;background-color:",f.border,";margin:4px 0;",""),icon:{name:"157xhr7",styles:"width:16px;height:16px"},iconSpin:b("animation:",eg," 1s linear infinite;",""),selectionCount:b("font-size:",K.base,";color:",f.textSecondary,";display:flex;align-items:center;gap:8px;margin-right:8px;",""),clearBtn:b("color:",f.primary,";background:none;border:none;cursor:pointer;font-size:",K.base,";font-weight:500;padding:0;&:hover{text-decoration:underline;}",""),divider:b("width:1px;height:24px;background:",f.border,";margin:0 4px;",""),viewToggle:b("display:flex;align-items:center;height:",Hs,";background-color:",f.surface,";border:1px solid ",f.border,";border-radius:6px;overflow:hidden;",""),searchWrapper:{name:"9iujih",styles:"position:relative;display:flex;align-items:center"},searchInput:b("height:",Hs,";padding:0 32px 0 12px;border:1px solid ",f.border,";border-radius:6px;font-size:",K.base,";background:",f.surface,";color:",f.text,";width:180px;transition:all 0.15s ease;&:focus{outline:none;border-color:",f.primary,";box-shadow:0 0 0 2px ",f.primaryLight,";}&::placeholder{color:",f.textMuted,";}",""),searchClearBtn:b("position:absolute;right:5px;top:5px;bottom:5px;background:",f.primary,";border:none;padding:0 6px;cursor:pointer;color:white;display:flex;align-items:center;justify-content:center;border-radius:4px;transition:all 0.15s ease;&:hover{background:",f.primaryHover,";}",""),viewBtn:b("height:100%;padding:0 10px;background:transparent;border:none;cursor:pointer;color:",f.textSecondary,";transition:all 0.15s ease;display:flex;align-items:center;justify-content:center;&:hover{color:",f.text,";background-color:",f.surfaceHover,";}",""),viewBtnActive:b("background-color:",f.primaryLight,";color:",f.primary,";&:hover{background-color:",f.primaryLight,";color:",f.primary,";}","")};function tg(){const{selectedItems:o,viewMode:s,setViewMode:h,clearSelection:u,currentPath:g,triggerRefresh:p,focusedItem:k,scanRequested:U,clearScanRequest:D,fileItems:S,requestProcess:Y,actionState:B}=ja(),W=M.useRef(null),$=M.useRef(null),[V,q]=M.useState(!1),[de,I]=M.useState(!1),[ue,le]=M.useState(!1),[re,_]=M.useState(!1),[X,j]=M.useState(!1),[ge,He]=M.useState(0),[_e,Ne]=M.useState(!1),[Le,We]=M.useState(!1),[Ie,ze]=M.useState(!1),[A,G]=M.useState(0),[P,pe]=M.useState(!1),[ke,y]=M.useState("Processing Images"),[L,O]=M.useState({current:0,total:0,percent:0,status:"processing"}),[Z,ee]=M.useState(null),[Ce,Ue]=M.useState(!1),[ht,Ke]=M.useState(!1),[nl,te]=M.useState(!1),[Kt,wn]=M.useState(!1),[Me,St]=M.useState(!1),[At,Et]=M.useState(!1),al=M.useRef(null),ml=g==="public/images"||g.startsWith("public/images/");M.useCallback(()=>{W.current?.click()},[]);const _l=M.useCallback(async()=>{le(!0),y("Scanning Files"),pe(!0),O({current:0,total:0,percent:0,status:"processing",message:"Scanning for files..."});try{const F=(await fetch("/api/studio/scan",{method:"POST"})).body?.getReader();if(!F)throw new Error("No reader");const J=new TextDecoder;let ce="";for(;;){const{done:Re,value:Te}=await F.read();if(Re)break;ce+=J.decode(Te,{stream:!0});const Ve=ce.split(`
|
|
57
|
+
|
|
58
|
+
`);ce=Ve.pop()||"";for(const De of Ve){if(!De.startsWith("data: "))continue;const se=JSON.parse(De.slice(6));if(se.type==="start")O({current:0,total:se.total,percent:0,status:"processing",message:`Scanning ${se.total} files...`});else if(se.type==="progress")O({current:se.current,total:se.total,percent:se.percent,status:"processing",currentFile:se.currentFile});else if(se.type==="cleanup")O(Ae=>({...Ae,message:se.message}));else if(se.type==="complete"){let Ae=se.renamed>0?`${se.renamed} file(s) renamed due to conflicts. `:"";se.orphanedFiles&&se.orphanedFiles.length>0&&(Ae+=`Found ${se.orphanedFiles.length} orphaned thumbnail(s) in images folder.`),O({current:se.total||0,total:se.total||0,percent:100,status:"complete",processed:se.added,alreadyProcessed:se.existingCount,errors:se.errors,orphanedFiles:se.orphanedFiles,pendingUpdates:se.pendingUpdates,orphanedEntries:se.orphanedEntries,message:Ae||void 0,isScan:!0}),p()}else se.type==="error"&&O({current:0,total:0,percent:0,status:"error",message:se.message||"Scan failed"})}}}catch(ve){console.error("Scan error:",ve),O({current:0,total:0,percent:0,status:"error",message:"Scan failed"})}finally{le(!1)}},[p]);M.useEffect(()=>{const ve=F=>{al.current&&!al.current.contains(F.target)&&Et(!1)};return document.addEventListener("mousedown",ve),()=>document.removeEventListener("mousedown",ve)},[]),M.useEffect(()=>{U&&!ue&&(D(),_l())},[U,ue,D,_l]);const gl=M.useCallback(async ve=>{const F=ve.target.files;if(!F||F.length===0)return;const J=Array.from(F);J.length>1?(O({current:0,total:J.length,percent:0,status:"processing",message:"Uploading files..."}),pe(!0)):I(!0);let ce=0,Re=0;try{for(let Te=0;Te<J.length;Te++){const Ve=J[Te];J.length>1&&O({current:Te+1,total:J.length,percent:Math.round((Te+1)/J.length*100),status:"processing",currentFile:Ve.name});const De=new FormData;De.append("file",Ve),De.append("path",g);try{const se=await fetch("/api/studio/upload",{method:"POST",body:De});if(se.ok)ce++;else{const Ae=await se.json();Re++,J.length===1&&(se.status>=500?(console.error("Upload error:",Ae),ee({title:"Upload Failed",message:`Failed to upload ${Ve.name}: ${Ae.error||"Unknown error"}`})):ee({title:"Cannot Upload Here",message:Ae.error||"Upload not allowed in this location."}))}}catch{Re++}}J.length>1&&O({current:J.length,total:J.length,percent:100,status:"complete",processed:ce,errors:Re}),p()}catch(Te){console.error("Upload error:",Te),J.length>1?O({current:0,total:0,percent:0,status:"error",message:"Upload failed."}):ee({title:"Upload Failed",message:"Upload failed. Check console for details."})}finally{I(!1),W.current&&(W.current.value="")}},[g,p]),Jn=M.useCallback(async()=>{if(o.size>0){const F=Array.from(o),J=F.filter(Re=>(Re.split("/").pop()||"").includes(".")&&!Re.endsWith("/")),ce=F.filter(Re=>!(Re.split("/").pop()||"").includes(".")||Re.endsWith("/"));if(ce.length>0)try{const Te=await(await fetch(`/api/studio/folder-images?folders=${encodeURIComponent(ce.join(","))}`)).json();if(Te.images)for(const Ve of Te.images){const De=`public/${Ve}`;J.includes(De)||J.push(De)}}catch(Re){console.error("Failed to get folder files:",Re)}if(J.length===0){ee({title:"No Files Found",message:"No files found in the selected items."});return}Y(J)}else try{const J=await(await fetch("/api/studio/count-images")).json();if(!J.images||J.images.length===0){ee({title:"No Images Found",message:"No images found in the public folder to process."});return}const ce=J.images.map(Re=>`public/${Re}`);Y(ce)}catch(F){console.error("Failed to get images:",F),ee({title:"Error",message:"Failed to get images."})}},[o,Y]),Mn=M.useCallback(()=>{$.current&&$.current.abort()},[]),Ht=M.useCallback(async()=>{const ve=L.orphanedFiles;if(!(!ve||ve.length===0))try{const F=await fetch("/api/studio/delete-orphans",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({paths:ve})}),J=await F.json();F.ok?(O(ce=>({...ce,orphanedFiles:void 0,orphansRemoved:J.deleted,message:`Deleted ${J.deleted} orphaned thumbnail${J.deleted!==1?"s":""}.`})),p()):ee({title:"Delete Failed",message:J.error||"Failed to delete orphaned files."})}catch(F){console.error("Delete orphans error:",F),ee({title:"Delete Failed",message:"Failed to delete orphaned files. Check console for details."})}},[L.orphanedFiles,p]),hr=M.useCallback(()=>{o.size!==0&&_(!0)},[o]),Yi=M.useCallback(async()=>{_(!1);try{const ve=await fetch("/api/studio/delete",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({paths:Array.from(o)})});if(ve.ok)u(),p();else{const F=await ve.json();ee({title:"Delete Failed",message:F.error||"Unknown error"})}}catch(ve){console.error("Delete error:",ve),ee({title:"Delete Failed",message:"Delete failed. Check console for details."})}},[o,u,p]),Gi=M.useCallback(async()=>{if(o.size===0)return;const ve=Array.from(o),F=ve.filter(Te=>(Te.split("/").pop()||"").includes(".")&&!Te.endsWith("/")),J=ve.filter(Te=>!(Te.split("/").pop()||"").includes(".")||Te.endsWith("/"));if(J.length>0)try{const Ve=await(await fetch(`/api/studio/folder-images?folders=${encodeURIComponent(J.join(","))}`)).json();if(Ve.images)for(const De of Ve.images){const se=`public/${De}`;F.includes(se)||F.push(se)}}catch(Te){console.error("Failed to get folder files:",Te)}if(F.length===0){ee({title:"No Files Found",message:"No files found in the selected items."});return}let ce=!1,Re=!1;for(const Te of F){const Ve=S.find(De=>De.path===Te);Ve&&(Ve.isRemote?ce=!0:Ve.cdnPushed||(Re=!0))}He(F.length),Ne(ce),We(Re),j(!0)},[o,S]),Fn=M.useCallback(async()=>{j(!1);const ve=Array.from(o),F=ve.filter(De=>(De.split("/").pop()||"").includes(".")&&!De.endsWith("/")),J=ve.filter(De=>!(De.split("/").pop()||"").includes(".")||De.endsWith("/"));if(J.length>0)try{const se=await(await fetch(`/api/studio/folder-images?folders=${encodeURIComponent(J.join(","))}`)).json();if(se.images)for(const Ae of se.images){const me=`public/${Ae}`;F.includes(me)||F.push(me)}}catch(De){console.error("Failed to get folder files:",De)}const ce=F.map(De=>"/"+De.replace(/^public\//,""));y("Pushing to CDN"),O({current:0,total:ce.length,percent:0,status:"processing",message:"Pushing to CDN..."}),pe(!0);let Re=0,Te=0;const Ve=[];try{for(let De=0;De<ce.length;De++){const se=ce[De];O({current:De+1,total:ce.length,percent:Math.round((De+1)/ce.length*100),status:"processing",currentFile:se.replace(/^\//,"")});let Ae=!1,me;for(let Xe=0;Xe<3&&!Ae;Xe++)try{const _n=await fetch("/api/studio/sync",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({imageKeys:[se]})}),Sl=await _n.json();if(_n.ok)if(Sl.pushed?.length>0)Re++,Ae=!0;else if(Sl.errors?.length>0)for(const vr of Sl.errors)me=vr;else Ae=!0;else{if(Sl.error?.includes("R2 not configured")||Sl.error?.includes("CLOUDFLARE_R2")){pe(!1),wn(!0);return}me=Sl.error||`Failed: ${se}`}}catch{me=`Network error: ${se}`,Xe<2&&await new Promise(Sl=>setTimeout(Sl,500*(Xe+1)))}!Ae&&me&&(Te++,Ve.push(me))}O({current:ce.length,total:ce.length,percent:100,status:"complete",processed:Re,errors:Te,errorMessages:Ve.length>0?Ve:void 0}),u(),p()}catch(De){console.error("Push error:",De),O({current:0,total:0,percent:0,status:"error",message:"Failed to push to CDN."})}},[o,u,p]),pr=M.useCallback(async()=>{if(o.size===0)return;const F=Array.from(o).filter(J=>(J.split("/").pop()||"").includes(".")&&!J.endsWith("/"));if(F.length===0){ee({title:"No Files Found",message:"No files found in the selected items."});return}G(F.length),ze(!0)},[o]),Vi=M.useCallback(async()=>{ze(!1);const J=Array.from(o).filter(ce=>(ce.split("/").pop()||"").includes(".")&&!ce.endsWith("/")).map(ce=>"/"+ce.replace(/^public\//,""));y("Downloading from CDN"),pe(!0),O({current:0,total:J.length,percent:0,status:"processing"});try{const ce=await fetch("/api/studio/download-stream",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({imageKeys:J})});if(!ce.ok||!ce.body)throw new Error("Download request failed");const Re=ce.body.getReader(),Te=new TextDecoder;let Ve="";for(;;){const{done:De,value:se}=await Re.read();if(De)break;Ve+=Te.decode(se,{stream:!0});const Ae=Ve.split(`
|
|
59
|
+
`);Ve=Ae.pop()||"";for(const me of Ae)if(me.startsWith("data: "))try{const Xe=JSON.parse(me.slice(6));Xe.type==="progress"?O({current:Xe.current,total:Xe.total,percent:Math.round(Xe.current/Xe.total*100),status:"processing",message:Xe.message}):Xe.type==="complete"?O({current:Xe.total||J.length,total:Xe.total||J.length,percent:100,status:"complete",message:Xe.message}):Xe.type==="error"&&O({current:0,total:0,percent:0,status:"error",message:Xe.message})}catch{}}u(),p()}catch(ce){console.error("Download error:",ce),O({current:0,total:0,percent:0,status:"error",message:"Failed to download from CDN."})}},[o,u,p]),mr=M.useCallback(async()=>{if(o.size===0)return;const F=Array.from(o).filter(J=>{const ce=S.find(Re=>Re.path===J);return ce&&ce.hasUpdate});if(F.length===0){ee({title:"No Updates",message:"No files with pending updates in selection."});return}y("Pushing Updates"),pe(!0),O({current:0,total:F.length,percent:0,status:"processing"});try{const ce=(await fetch("/api/studio/push-updates-stream",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({paths:F})})).body?.getReader();if(!ce)throw new Error("No response body");const Re=new TextDecoder;let Te="";for(;;){const{done:Ve,value:De}=await ce.read();if(Ve)break;Te+=Re.decode(De,{stream:!0});const se=Te.split(`
|
|
60
|
+
`);Te=se.pop()||"";for(const Ae of se)if(Ae.startsWith("data: "))try{const me=JSON.parse(Ae.slice(6));me.type==="progress"?O({current:me.current,total:me.total,percent:me.percent,status:"processing",currentFile:me.currentFile}):me.type==="cleanup"?O(Xe=>({...Xe,message:me.message})):me.type==="complete"?O({current:me.total||F.length,total:me.total||F.length,percent:100,status:"complete",message:me.message}):me.type==="error"&&O({current:0,total:0,percent:0,status:"error",message:me.message})}catch{}}u(),p()}catch(J){console.error("Push updates error:",J),O({current:0,total:0,percent:0,status:"error",message:"Failed to push updates."})}},[o,S,u,p]),gr=M.useCallback(async()=>{if(o.size===0)return;const F=Array.from(o).filter(J=>{const ce=S.find(Re=>Re.path===J);return ce&&ce.hasUpdate});if(F.length!==0)try{const J=await fetch("/api/studio/cancel-updates",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({paths:F})});if(J.ok)u(),p();else{const ce=await J.json();ee({title:"Cancel Failed",message:ce.error||"Unknown error"})}}catch(J){console.error("Cancel updates error:",J),ee({title:"Cancel Failed",message:"Failed to cancel updates. Check console for details."})}},[o,S,u,p]),Tn=M.useCallback(async()=>{if(o.size===0)return;Et(!1);const F=Array.from(o).filter(J=>{const ce=S.find(Re=>Re.path===J);return ce&&ce.cdnPushed});if(F.length===0){ee({title:"No CDN Files",message:"No selected files are on CDN."});return}y("Clearing Cache"),pe(!0),O({current:0,total:F.length,percent:0,status:"processing",message:"Clearing CDN cache..."});try{const J=await fetch("/api/studio/clear-cache",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({paths:F})}),ce=await J.json();J.ok?O({current:F.length,total:F.length,percent:100,status:"complete",message:ce.message||"Cache cleared."}):O({current:0,total:0,percent:0,status:"error",message:ce.error||"Failed to clear cache."})}catch(J){console.error("Clear cache error:",J),O({current:0,total:0,percent:0,status:"error",message:"Failed to clear cache. Check console for details."})}},[o,S]),Nt=M.useCallback(async ve=>{Ue(!1);try{const F=await fetch("/api/studio/create-folder",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({parentPath:g,name:ve})});if(F.ok)p();else{const J=await F.json();ee({title:"Create Folder Failed",message:J.error||"Unknown error"})}}catch(F){console.error("Create folder error:",F),ee({title:"Create Folder Failed",message:"Failed to create folder. Check console for details."})}},[g,p]),xl=M.useCallback(()=>{o.size!==0&&te(!0)},[o]),Bt=M.useCallback(async ve=>{const F=Array.from(o);y("Moving Files"),pe(!0),O({current:0,total:F.length,percent:0,status:"processing"});try{const J=await fetch("/api/studio/move",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({paths:F,destination:ve})});if(!J.body)throw new Error("No response body");const ce=J.body.getReader(),Re=new TextDecoder;let Te="";for(;;){const{done:Ve,value:De}=await ce.read();if(Ve)break;Te+=Re.decode(De,{stream:!0});const se=Te.split(`
|
|
61
|
+
|
|
62
|
+
`);Te=se.pop()||"";for(const Ae of se)if(Ae.startsWith("data: "))try{const me=JSON.parse(Ae.slice(6));me.type==="start"?O(Xe=>({...Xe,total:me.total})):me.type==="progress"?O({current:me.current,total:me.total,percent:me.percent,currentFile:me.currentFile,status:"processing"}):me.type==="complete"?(O(Xe=>({...Xe,status:"complete",processed:me.moved,errors:me.errors,errorMessages:me.errorMessages,isMove:!0})),u(),p()):me.type==="error"&&O(Xe=>({...Xe,status:"error",errorMessage:me.message}))}catch{}}}catch(J){console.error("Move error:",J),O(ce=>({...ce,status:"error",errorMessage:"Failed to move items. Check console for details."}))}},[o,u,p]),{searchQuery:Xi,setSearchQuery:An}=ja(),yr=M.useCallback(ve=>{An(ve.target.value)},[An]),$n=M.useCallback(ve=>{ve.key==="Escape"&&(ve.stopPropagation(),An(""),ve.target.blur())},[An]),Jt=o.size>0,Wn=Jt&&Array.from(o).some(ve=>{const F=S.find(J=>J.path===ve);return F&&F.cdnPushed&&!F.isRemote}),kl=Jt&&Array.from(o).every(ve=>{const F=S.find(J=>J.path===ve);return F&&F.type==="file"&&F.cdnPushed&&!F.isRemote}),In=Jt&&Array.from(o).some(ve=>{const F=S.find(J=>J.path===ve);return F&&F.hasUpdate}),Dl=Array.from(o),Il=Dl.length===1&&!Dl[0].includes("."),Ol=Il?Dl[0]:null,Pn=Ol&&Ol.split("/").pop()||"",En=M.useCallback(async ve=>{if(Ol){Ke(!1);try{(await fetch("/api/studio/rename",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({oldPath:Ol,newName:ve})})).ok&&(u(),p())}catch(F){console.error("Failed to rename folder:",F)}}},[Ol,u,p]);return k?null:x(Tt,{children:[re&&c(Ri,{title:"Delete Items",message:`Are you sure you want to delete ${o.size} item(s)? This action cannot be undone.`,confirmLabel:"Delete",variant:"danger",onConfirm:Yi,onCancel:()=>_(!1)}),X&&c(Ri,{title:"Push to CDN",message:`Push ${ge} image${ge!==1?"s":""} to Cloudflare R2?${_e?" Remote images will be downloaded first.":""}${Le?" After pushing, local files will be deleted.":""}`,confirmLabel:"Push",onConfirm:Fn,onCancel:()=>j(!1)}),Ie&&c(Ri,{title:"Download from CDN",message:`Download ${A} image${A!==1?"s":""} from Cloudflare R2 to local storage? Images will be removed from the CDN.`,confirmLabel:"Download",onConfirm:Vi,onCancel:()=>ze(!1)}),P&&c(Js,{title:ke,progress:L,onStop:Mn,onDeleteOrphans:Ht,onClose:()=>{pe(!1),O({current:0,total:0,percent:0,status:"processing"})}}),Ce&&c(Ys,{title:"New Folder",message:"Enter a name for the new folder:",placeholder:"Folder name",confirmLabel:"Create",onConfirm:Nt,onCancel:()=>Ue(!1)}),nl&&c(wh,{selectedItems:o,currentPath:g,onMove:ve=>{te(!1),Bt(ve)},onCancel:()=>te(!1)}),ht&&Ol&&c(Ys,{title:"Rename Folder",message:"Enter a new name for the folder:",placeholder:Pn,defaultValue:Pn,confirmLabel:"Rename",onConfirm:En,onCancel:()=>Ke(!1)}),Z&&c(zh,{title:Z.title,message:Z.message,onClose:()=>ee(null)}),c(Mh,{isOpen:Kt,onClose:()=>wn(!1)}),V&&c(P1,{currentPath:g,onClose:()=>q(!1),onUploadComplete:()=>{q(!1),p()}}),x("div",{css:xe.toolbar,children:[c("input",{ref:W,type:"file",multiple:!0,accept:"image/*,video/*,audio/*,.pdf",onChange:gl,style:{display:"none"}}),x("div",{css:xe.left,children:[x("button",{css:[xe.btn,xe.btnPrimary,"",""],onClick:()=>q(!0),disabled:de||ml,children:[c(lg,{}),"Add New"]}),x("button",{css:xe.btn,onClick:()=>Il?Ke(!0):Ue(!0),disabled:ml&&!Il,title:ml&&!Il?"Cannot create folders in protected images folder":void 0,children:[Il?c(og,{}):c(ig,{}),Il?"Rename Folder":"New Folder"]}),c("div",{css:xe.divider}),x("button",{css:xe.btn,onClick:Jn,disabled:B.showProgress||ml,title:ml?"Cannot process images folder":void 0,children:[c(pg,{}),"Process Images"]}),x("button",{css:[xe.btn,xe.btnDanger,"",""],onClick:hr,disabled:!Jt,children:[c(ag,{}),"Delete"]}),x("button",{css:xe.btn,onClick:xl,disabled:!Jt,children:[c(rg,{}),"Move"]}),x("div",{css:xe.cloudDropdownWrapper,ref:al,children:[x("button",{css:[xe.btn,xe.btnCloud,"",""],onClick:()=>Et(!At),disabled:!Jt,children:[c(rh,{}),"Cloud",c("svg",{css:xe.dropdownArrow,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M19 9l-7 7-7-7"})})]}),At&&Jt&&x("div",{css:xe.cloudDropdown,children:[In&&x(Tt,{children:[x("button",{css:xe.cloudDropdownItem,onClick:()=>{Et(!1),mr()},children:[c(cg,{}),"Push Update"]}),x("button",{css:[xe.cloudDropdownItem,xe.cloudDropdownItemDanger,"",""],onClick:()=>{Et(!1),gr()},children:[c(sg,{}),"Cancel Update"]}),c("div",{css:xe.cloudDropdownDivider})]}),!Wn&&x("button",{css:xe.cloudDropdownItem,onClick:()=>{Et(!1),Gi()},children:[c(rh,{}),"Push CDN"]}),kl&&x("button",{css:xe.cloudDropdownItem,onClick:()=>{Et(!1),pr()},children:[c(fg,{}),"Download"]}),x("button",{css:xe.cloudDropdownItem,onClick:Tn,children:[c(ug,{}),"Clear Cache"]})]})]}),x("div",{css:xe.searchWrapper,children:[c("input",{css:xe.searchInput,type:"text",placeholder:"Search images...",value:Xi,onChange:yr,onKeyDown:$n}),Xi&&c("button",{css:xe.searchClearBtn,onClick:()=>An(""),title:"Clear search",children:c("svg",{width:"14",height:"14",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M6 18L18 6M6 6l12 12"})})})]})]}),x("div",{css:xe.right,children:[Jt&&x("span",{css:xe.selectionCount,children:[o.size," selected",c("button",{css:xe.clearBtn,onClick:u,children:"Clear"})]}),x("button",{css:xe.btn,onClick:_l,disabled:ue,children:[c(ng,{spinning:ue}),"Scan"]}),x("div",{css:xe.viewToggle,children:[c("button",{css:[xe.viewBtn,s==="grid"&&xe.viewBtnActive,"",""],onClick:()=>h("grid"),"aria-label":"Grid view",children:c(dg,{})}),c("button",{css:[xe.viewBtn,s==="list"&&xe.viewBtnActive,"",""],onClick:()=>h("list"),"aria-label":"List view",children:c(hg,{})})]})]})]})]})}function lg(){return c("svg",{css:xe.icon,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M4 16v1a3 3 0 003 3h10a3 3 0 003-3v-1m-4-8l-4-4m0 0L8 8m4-4v12"})})}function ng({spinning:o}){return c("svg",{css:[xe.icon,o&&xe.iconSpin,"",""],fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M21 21l-6-6m2-5a7 7 0 11-14 0 7 7 0 0114 0z"})})}function ag(){return c("svg",{css:xe.icon,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M19 7l-.867 12.142A2 2 0 0116.138 21H7.862a2 2 0 01-1.995-1.858L5 7m5 4v6m4-6v6m1-10V4a1 1 0 00-1-1h-4a1 1 0 00-1 1v3M4 7h16"})})}function ig(){return c("svg",{css:xe.icon,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M9 13h6m-3-3v6m-9 1V7a2 2 0 012-2h6l2 2h6a2 2 0 012 2v8a2 2 0 01-2 2H5a2 2 0 01-2-2z"})})}function og(){return c("svg",{css:xe.icon,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M11 5H6a2 2 0 00-2 2v11a2 2 0 002 2h11a2 2 0 002-2v-5m-1.414-9.414a2 2 0 112.828 2.828L11.828 15H9v-2.828l8.586-8.586z"})})}function rg(){return c("svg",{css:xe.icon,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M8 7h12m0 0l-4-4m4 4l-4 4m0 6H4m0 0l4 4m-4-4l4-4"})})}function rh(){return c("svg",{css:xe.icon,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M7 16a4 4 0 01-.88-7.903A5 5 0 1115.9 6L16 6a5 5 0 011 9.9M15 13l-3-3m0 0l-3 3m3-3v12"})})}function cg(){return c("svg",{css:xe.icon,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M4 4v5h.582m15.356 2A8.001 8.001 0 004.582 9m0 0H9m11 11v-5h-.581m0 0a8.003 8.003 0 01-15.357-2m15.357 2H15"})})}function sg(){return c("svg",{css:xe.icon,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M6 18L18 6M6 6l12 12"})})}function ug(){return c("svg",{css:xe.icon,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M4 4v5h.582m15.356 2A8.001 8.001 0 004.582 9m0 0H9m11 11v-5h-.581m0 0a8.003 8.003 0 01-15.357-2m15.357 2H15"})})}function fg(){return c("svg",{css:xe.icon,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M7 16a4 4 0 01-.88-7.903A5 5 0 1115.9 6L16 6a5 5 0 011 9.9M9 19l3 3m0 0l3-3m-3 3V10"})})}function dg(){return c("svg",{css:xe.icon,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M4 6a2 2 0 012-2h2a2 2 0 012 2v2a2 2 0 01-2 2H6a2 2 0 01-2-2V6zM14 6a2 2 0 012-2h2a2 2 0 012 2v2a2 2 0 01-2 2h-2a2 2 0 01-2-2V6zM4 16a2 2 0 012-2h2a2 2 0 012 2v2a2 2 0 01-2 2H6a2 2 0 01-2-2v-2zM14 16a2 2 0 012-2h2a2 2 0 012 2v2a2 2 0 01-2 2h-2a2 2 0 01-2-2v-2z"})})}function hg(){return c("svg",{css:xe.icon,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M4 6h16M4 10h16M4 14h16M4 18h16"})})}function pg(){return c("svg",{css:xe.icon,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M4 16l4.586-4.586a2 2 0 012.828 0L16 16m-2-2l1.586-1.586a2 2 0 012.828 0L20 14m-6-6h.01M6 20h12a2 2 0 002-2V6a2 2 0 00-2-2H6a2 2 0 00-2 2v12a2 2 0 002 2z"})})}class mg{async get(s){const h=await fetch(s,{cache:"no-store",headers:{"Cache-Control":"no-cache"}});if(!h.ok){const u=await h.json().catch(()=>({}));throw new Error(u.error||`Request failed: ${h.status}`)}return h.json()}async post(s,h){const u=await fetch(s,{method:"POST",headers:h?{"Content-Type":"application/json"}:void 0,body:h?JSON.stringify(h):void 0});if(!u.ok){const g=await u.json().catch(()=>({}));throw new Error(g.error||`Request failed: ${u.status}`)}return u.json()}async list(s="public"){return this.get(`/api/studio/list?path=${encodeURIComponent(s)}`)}async search(s){return this.get(`/api/studio/search?q=${encodeURIComponent(s)}`)}async listFolders(){return this.get("/api/studio/list-folders")}async countImages(){return this.get("/api/studio/count-images")}async folderImages(s){return this.get(`/api/studio/folder-images?folders=${encodeURIComponent(s.join(","))}`)}async upload(s,h="public"){const u=new FormData;u.append("file",s),u.append("path",h);const g=await fetch("/api/studio/upload",{method:"POST",body:u});if(!g.ok){const p=await g.json().catch(()=>({}));throw new Error(p.error||`Upload failed: ${g.status}`)}return g.json()}async delete(s){return this.post("/api/studio/delete",{paths:s})}async createFolder(s,h){return this.post("/api/studio/create-folder",{parentPath:s,name:h})}async rename(s,h){return this.post("/api/studio/rename",{oldPath:s,newName:h})}async move(s,h){return this.post("/api/studio/move",{paths:s,destination:h})}async push(s){return this.post("/api/studio/sync",{imageKeys:s})}async reprocess(s){return this.post("/api/studio/reprocess",{imageKeys:s})}processAllStream(){return new EventSource("/api/studio/process-all")}}const Ns=new mg;function Th(){const{currentPath:o,setCurrentPath:s,navigateUp:h,selectedItems:u,toggleSelection:g,selectRange:p,lastSelectedPath:k,selectAll:U,clearSelection:D,refreshKey:S,setFocusedItem:Y,triggerRefresh:B,triggerScan:W,searchQuery:$,showError:V,setFileItems:q}=ja(),[de,I]=M.useState([]),[ue,le]=M.useState(!0),[re,_]=M.useState(!1),X=M.useRef(!0),j=M.useRef(o);M.useEffect(()=>{async function G(){const P=j.current!==o;(X.current||P)&&le(!0),j.current=o;try{const pe=$&&$.length>=2?await Ns.search($):await Ns.list(o),ke=pe.items||[];I(ke),q(ke),_(pe.isEmpty===!0)}catch(pe){const ke=pe instanceof Error?pe.message:"Failed to load items";V("Load Error",ke),I([]),q([]),_(!1)}le(!1),X.current=!1}G()},[o,S,$,V,q]);const ge=o==="public",He=$&&$.length>=2,_e=[...de].sort((G,P)=>G.type==="folder"&&P.type!=="folder"?-1:G.type!=="folder"&&P.type==="folder"?1:G.name.localeCompare(P.name)),Ne=_e.length>0&&_e.every(G=>u.has(G.path)),Le=_e.some(G=>u.has(G.path)),We=M.useCallback((G,P)=>{P.shiftKey&&k?p(k,G.path,_e):g(G.path)},[k,p,_e,g]),Ie=M.useCallback(G=>{G.type==="folder"?s(G.path):Y(G)},[s,Y]),ze=M.useCallback(async G=>{try{const P="/"+G.path.replace(/^public\//,"");await Ns.reprocess([P]),B()}catch(P){const pe=P instanceof Error?P.message:"Failed to generate thumbnail";V("Processing Error",pe)}},[B,V]),A=M.useCallback(()=>{Ne?D():U(_e)},[Ne,D,U,_e]);return{items:de,loading:ue,sortedItems:_e,metaEmpty:re,isAtRoot:ge,isSearching:He,allItemsSelected:Ne,someItemsSelected:Le,currentPath:o,selectedItems:u,navigateUp:h,handleItemClick:We,handleOpen:Ie,handleGenerateThumbnail:ze,handleSelectAll:A,triggerScan:W,refreshKey:S}}const gg=Wl`
|
|
63
|
+
to { transform: rotate(360deg); }
|
|
64
|
+
`,ie={loading:{name:"1d2ui9i",styles:"display:flex;align-items:center;justify-content:center;flex:1;min-height:300px"},spinner:b("width:32px;height:32px;border-radius:50%;border:3px solid ",f.border,";border-top-color:",f.primary,";animation:",gg," 0.8s linear infinite;",""),empty:b("display:flex;flex-direction:column;align-items:center;justify-content:center;flex:1;min-height:300px;color:",f.textSecondary,";",""),emptyIcon:{name:"1o3cbsn",styles:"width:48px;height:48px;margin-bottom:16px;opacity:0.5"},emptyText:b("font-size:",K.base,";margin:0 0 4px 0;&:last-child{color:",f.textMuted,";font-size:",K.sm,";}",""),scanButton:b("margin-top:16px;padding:10px 24px;font-size:",K.base,";font-weight:500;background:",f.primary,";color:white;border:none;border-radius:8px;cursor:pointer;transition:background 0.15s ease;&:hover:not(:disabled){background:",f.primaryHover,";}&:disabled{opacity:0.6;cursor:not-allowed;}",""),grid:{name:"el23hk",styles:"display:grid;grid-template-columns:1fr;gap:12px;@media (min-width: 480px){grid-template-columns:repeat(2, 1fr);}@media (min-width: 768px){grid-template-columns:repeat(3, 1fr);}@media (min-width: 1024px){grid-template-columns:repeat(4, 1fr);}@media (min-width: 1280px){grid-template-columns:repeat(5, 1fr);}"},item:b("position:relative;border-radius:8px;border:1px solid ",f.border,";overflow:hidden;cursor:pointer;transition:all 0.15s ease;background-color:",f.surface,";user-select:none;box-shadow:0 1px 2px rgba(0, 0, 0, 0.04);&:hover{border-color:#d0d5dd;box-shadow:0 2px 4px rgba(0, 0, 0, 0.06);}",""),itemSelected:b("border-color:",f.primary,";box-shadow:0 0 0 1px ",f.primary,";&:hover{border-color:",f.primary,";box-shadow:0 0 0 1px ",f.primary,";}",""),parentItem:b("cursor:pointer;&:hover{border-color:",f.primary,";}",""),checkboxWrapper:{name:"v3lnpt",styles:"position:absolute;top:0;left:0;z-index:10;padding:8px;cursor:pointer"},checkbox:b("width:18px;height:18px;accent-color:",f.primary,";cursor:pointer;",""),content:b("position:relative;aspect-ratio:1;display:flex;align-items:center;justify-content:center;padding:16px;background:",f.background,";",""),folderIcon:{name:"k1w47f",styles:"width:56px;height:56px;color:#f9935e"},imagesFolderIcon:b("width:56px;height:56px;color:",f.imagesFolder,";",""),imagesFolderWrapper:{name:"bjn8wh",styles:"position:relative"},lockIcon:b("position:absolute;bottom:4px;right:4px;width:16px;height:16px;color:",f.imagesFolder,";background:white;border-radius:50%;padding:2px;",""),parentIcon:b("width:56px;height:56px;color:",f.textMuted,";",""),fileIcon:b("width:40px;height:40px;color:",f.textMuted,";",""),image:{name:"rm1wug",styles:"max-width:100%;max-height:100%;object-fit:contain;border-radius:4px"},label:b("padding:10px 12px;background-color:",f.surface,";border-top:1px solid ",f.borderLight,";",""),labelRow:{name:"1gkgtms",styles:"display:flex;flex-direction:column;gap:2px"},labelText:{name:"fxp7t8",styles:"flex:1;min-width:0"},copyBtn:b("position:absolute;top:4px;right:4px;z-index:10;height:28px;width:28px;color:",f.textMuted,";background:transparent;border:none;padding:0;cursor:pointer;border-radius:4px;transition:all 0.15s ease;display:flex;align-items:center;justify-content:center;&:hover{color:",f.text,";}",""),copyIcon:{name:"1eg0rk6",styles:"width:18px;height:18px"},folderStats:{name:"905wvx",styles:"display:flex;align-items:center;gap:8px;margin:2px 0 0 0"},folderStat:b("display:flex;align-items:center;gap:3px;font-size:",K.xs,";",""),folderStatLocal:b("color:",f.textMuted,";",""),folderStatCloud:{name:"1t8qh25",styles:"color:#f59e0b"},folderStatRemote:{name:"1lukubv",styles:"color:#ef4444"},folderStatUpdate:{name:"1t8qh25",styles:"color:#f59e0b"},folderStatIconCloud:{name:"1pgx8p4",styles:"width:14px;height:14px;color:#f59e0b"},folderStatIconLocal:b("width:14px;height:14px;color:",f.textSecondary,";",""),folderStatIconRemote:{name:"efr29r",styles:"width:14px;height:14px;color:#ef4444"},folderStatIconUpdate:{name:"1pgx8p4",styles:"width:14px;height:14px;color:#f59e0b"},updateLabel:b("display:flex;align-items:center;gap:4px;color:#f59e0b;font-size:",K.xs,";margin:0;",""),updateCloudIcon:{name:"1pgx8p4",styles:"width:14px;height:14px;color:#f59e0b"},updateSyncIcon:{name:"1pgx8p4",styles:"width:14px;height:14px;color:#f59e0b"},storedLabel:{name:"1jcbxef",styles:"display:flex;align-items:center;margin:2px 0 0 0"},storedIconCloud:{name:"1e09qmx",styles:"width:16px;height:16px;color:#f59e0b"},storedIconRemote:{name:"1mrh6ju",styles:"width:16px;height:16px;color:#ef4444"},tooltip:{name:"qoyfdh",styles:"position:absolute;top:50%;right:100%;transform:translateY(-50%);background:#1a1f36;color:white;padding:4px 8px;border-radius:4px;font-size:12px;white-space:nowrap;margin-right:6px;pointer-events:none;z-index:100;&::before{content:'';position:absolute;left:100%;top:50%;transform:translateY(-50%);border:4px solid transparent;border-left-color:#1a1f36;}"},openBtn:b("position:absolute;bottom:8px;right:8px;z-index:10;height:28px;font-size:",K.sm,";font-weight:500;color:",f.primary,";background:",f.surface,";border:1px solid ",f.border,";padding:0 8px;cursor:pointer;border-radius:4px;transition:all 0.15s ease;display:flex;align-items:center;box-shadow:0 1px 2px rgba(0, 0, 0, 0.08);&:hover{background-color:",f.primaryLight,";border-color:",f.primary,";}",""),name:b("font-size:",K.sm,";font-weight:500;color:",f.text,";white-space:nowrap;overflow:hidden;text-overflow:ellipsis;margin:0;letter-spacing:-0.01em;direction:rtl;text-align:left;",""),size:b("font-size:",K.xs,";color:",f.textMuted,";margin:2px 0 0 0;",""),selectAllRow:b("display:flex;align-items:center;margin-bottom:16px;padding:12px 16px;background:",f.surface,";border-radius:8px;border:1px solid ",f.border,";",""),selectAllLabel:b("display:flex;align-items:center;gap:10px;font-size:",K.base,";font-weight:500;color:",f.textSecondary,";cursor:pointer;&:hover{color:",f.text,";}",""),selectAllCheckbox:b("width:16px;height:16px;accent-color:",f.primary,";","")};function yg(){const{loading:o,sortedItems:s,metaEmpty:h,isAtRoot:u,isSearching:g,allItemsSelected:p,someItemsSelected:k,selectedItems:U,navigateUp:D,handleItemClick:S,handleOpen:Y,handleGenerateThumbnail:B,handleSelectAll:W,triggerScan:$,refreshKey:V}=Th();return o?c("div",{css:ie.loading,children:c("div",{css:ie.spinner})}):h&&u?x("div",{css:ie.empty,children:[c("svg",{css:ie.emptyIcon,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:1.5,d:"M21 21l-6-6m2-5a7 7 0 11-14 0 7 7 0 0114 0z"})}),c("p",{css:ie.emptyText,children:"No files tracked yet"}),c("p",{css:ie.emptyText,children:"Click Scan to discover files in your public folder"}),c("button",{css:ie.scanButton,onClick:$,children:"Scan for Files"})]}):s.length===0&&u?x("div",{css:ie.empty,children:[c("svg",{css:ie.emptyIcon,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:1.5,d:"M4 16l4.586-4.586a2 2 0 012.828 0L16 16m-2-2l1.586-1.586a2 2 0 012.828 0L20 14m-6-6h.01M6 20h12a2 2 0 002-2V6a2 2 0 00-2-2H6a2 2 0 00-2 2v12a2 2 0 002 2z"})}),c("p",{css:ie.emptyText,children:"No files in this folder"}),c("p",{css:ie.emptyText,children:"Upload images or click Scan in the toolbar"})]}):x("div",{children:[s.length>0&&c("div",{css:ie.selectAllRow,children:x("label",{css:ie.selectAllLabel,children:[c("input",{type:"checkbox",css:ie.selectAllCheckbox,checked:p,ref:q=>{q&&(q.indeterminate=k&&!p)},onChange:W}),"Select all (",s.length,")"]})}),x("div",{css:ie.grid,children:[!u&&!g&&x("div",{css:[ie.item,ie.parentItem,"",""],onClick:D,children:[c("div",{css:ie.content,children:c("svg",{css:ie.parentIcon,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:1.5,d:"M3 10h10a8 8 0 018 8v2M3 10l6 6m-6-6l6-6"})})}),x("div",{css:ie.label,children:[c("p",{css:ie.name,children:".."}),c("p",{css:ie.size,children:"Parent folder"})]})]}),s.map(q=>c(vg,{item:q,isSelected:U.has(q.path),onClick:de=>S(q,de),onOpen:()=>Y(q),cacheKey:V,onGenerateThumbnail:()=>B(q)},q.path))]})]})}function vg({item:o,isSelected:s,onClick:h,onOpen:u,onGenerateThumbnail:g,cacheKey:p}){const[k,U]=M.useState(!1),D=o.type==="folder",S=!D&&o.thumbnail!==void 0,Y=o.isProtected||D&&o.name==="images"&&o.path==="public/images",B=$=>{$.stopPropagation();const V="/"+o.path.replace(/^public\//,"");navigator.clipboard.writeText(V),U(!0),setTimeout(()=>U(!1),1500)},W=$=>{if(Y){$.stopPropagation(),u();return}h($)};return x("div",{css:[ie.item,s&&!Y&&ie.itemSelected,"",""],onClick:W,children:[!Y&&c("div",{css:ie.checkboxWrapper,onClick:$=>$.stopPropagation(),children:c("input",{type:"checkbox",css:ie.checkbox,checked:s,onChange:()=>h({})})}),x("div",{css:ie.content,children:[x("button",{css:ie.copyBtn,onClick:B,title:"Copy file path",children:[k&&c("span",{css:ie.tooltip,children:"Copied!"}),c("svg",{css:ie.copyIcon,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"})})]}),c("button",{css:ie.openBtn,onClick:$=>{$.stopPropagation(),u()},children:"Open"}),D?Y?x("div",{css:ie.imagesFolderWrapper,children:[c("svg",{css:ie.imagesFolderIcon,fill:"currentColor",viewBox:"0 0 24 24",children:c("path",{d:"M10 4H4a2 2 0 00-2 2v12a2 2 0 002 2h16a2 2 0 002-2V8a2 2 0 00-2-2h-8l-2-2z"})}),c("svg",{css:ie.lockIcon,fill:"currentColor",viewBox:"0 0 20 20",children:c("path",{fillRule:"evenodd",d:"M5 9V7a5 5 0 0110 0v2a2 2 0 012 2v5a2 2 0 01-2 2H5a2 2 0 01-2-2v-5a2 2 0 012-2zm8-2v2H7V7a3 3 0 016 0z",clipRule:"evenodd"})})]}):c("svg",{css:ie.folderIcon,fill:"currentColor",viewBox:"0 0 24 24",children:c("path",{d:"M10 4H4a2 2 0 00-2 2v12a2 2 0 002 2h16a2 2 0 002-2V8a2 2 0 00-2-2h-8l-2-2z"})}):S&&o.thumbnail?c("img",{css:ie.image,src:`${o.thumbnail}${o.thumbnail.includes("?")?"&":"?"}v=${p}`,alt:o.name,loading:"lazy"}):c("svg",{css:ie.fileIcon,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:1.5,d:"M7 21h10a2 2 0 002-2V9.414a1 1 0 00-.293-.707l-5.414-5.414A1 1 0 0012.586 3H7a2 2 0 00-2 2v14a2 2 0 002 2z"})})]}),c("div",{css:ie.label,children:c("div",{css:ie.labelRow,children:x("div",{css:ie.labelText,children:[c("p",{css:ie.name,title:o.name,children:o.name}),D?x("div",{css:ie.folderStats,children:[o.localCount!==void 0&&o.localCount>0&&x("span",{css:[ie.folderStat,ie.folderStatLocal,"",""],title:`${o.localCount} local`,children:[c("svg",{css:ie.folderStatIconLocal,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M4 16l4.586-4.586a2 2 0 012.828 0L16 16m-2-2l1.586-1.586a2 2 0 012.828 0L20 14m-6-6h.01M6 20h12a2 2 0 002-2V6a2 2 0 00-2-2H6a2 2 0 00-2 2v12a2 2 0 002 2z"})}),o.localCount]}),o.cloudCount!==void 0&&o.cloudCount>0&&x("span",{css:[ie.folderStat,ie.folderStatCloud,"",""],title:`${o.cloudCount} in cloud`,children:[c("svg",{css:ie.folderStatIconCloud,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M3 15a4 4 0 004 4h9a5 5 0 10-.1-9.999 5.002 5.002 0 10-9.78 2.096A4.001 4.001 0 003 15z"})}),o.cloudCount]}),o.remoteCount!==void 0&&o.remoteCount>0&&x("span",{css:[ie.folderStat,ie.folderStatRemote,"",""],title:`${o.remoteCount} remote`,children:[c("svg",{css:ie.folderStatIconRemote,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M21 12a9 9 0 01-9 9m9-9a9 9 0 00-9-9m9 9H3m9 9a9 9 0 01-9-9m9 9c1.657 0 3-4.03 3-9s-1.343-9-3-9m0 18c-1.657 0-3-4.03-3-9s1.343-9 3-9m-9 9a9 9 0 019-9"})}),o.remoteCount]}),o.updateCount!==void 0&&o.updateCount>0&&x("span",{css:[ie.folderStat,ie.folderStatUpdate,"",""],title:`${o.updateCount} pending update${o.updateCount!==1?"s":""}`,children:[c("svg",{css:ie.folderStatIconUpdate,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M4 4v5h.582m15.356 2A8.001 8.001 0 004.582 9m0 0H9m11 11v-5h-.581m0 0a8.003 8.003 0 01-15.357-2m15.357 2H15"})}),o.updateCount]}),!o.localCount&&!o.cloudCount&&!o.remoteCount&&!o.updateCount&&o.fileCount!==void 0&&x("span",{css:ie.size,children:[o.fileCount," files"]})]}):o.hasUpdate?x("p",{css:ie.updateLabel,children:[c("svg",{css:ie.updateCloudIcon,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M3 15a4 4 0 004 4h9a5 5 0 10-.1-9.999 5.002 5.002 0 10-9.78 2.096A4.001 4.001 0 003 15z"})}),c("svg",{css:ie.updateSyncIcon,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M4 4v5h.582m15.356 2A8.001 8.001 0 004.582 9m0 0H9m11 11v-5h-.581m0 0a8.003 8.003 0 01-15.357-2m15.357 2H15"})}),c("span",{children:"update"})]}):o.cdnPushed?c("p",{css:ie.storedLabel,children:c("svg",{css:o.isRemote?ie.storedIconRemote:ie.storedIconCloud,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:o.isRemote?c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M21 12a9 9 0 01-9 9m9-9a9 9 0 00-9-9m9 9H3m9 9a9 9 0 01-9-9m9 9c1.657 0 3-4.03 3-9s-1.343-9-3-9m0 18c-1.657 0-3-4.03-3-9s1.343-9 3-9m-9 9a9 9 0 019-9"}):c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M3 15a4 4 0 004 4h9a5 5 0 10-.1-9.999 5.002 5.002 0 10-9.78 2.096A4.001 4.001 0 003 15z"})})}):o.size!==void 0&&c("p",{css:ie.size,children:bg(o.size)})]})})})]})}function bg(o){return o<1024?`${o} B`:o<1024*1024?`${(o/1024).toFixed(1)} KB`:`${(o/(1024*1024)).toFixed(1)} MB`}const xg=Wl`
|
|
65
|
+
to { transform: rotate(360deg); }
|
|
66
|
+
`,Q={loading:{name:"1d2ui9i",styles:"display:flex;align-items:center;justify-content:center;flex:1;min-height:300px"},spinner:b("width:32px;height:32px;border-radius:50%;border:3px solid ",f.border,";border-top-color:",f.primary,";animation:",xg," 0.8s linear infinite;",""),empty:b("display:flex;flex-direction:column;align-items:center;justify-content:center;flex:1;min-height:300px;color:",f.textSecondary,";",""),emptyHint:b("font-size:",K.sm,";color:",f.textMuted,";margin-top:4px;",""),scanButton:b("margin-top:16px;padding:10px 24px;font-size:",K.base,";font-weight:500;background:",f.primary,";color:white;border:none;border-radius:8px;cursor:pointer;transition:background 0.15s ease;&:hover:not(:disabled){background:",f.primaryHover,";}&:disabled{opacity:0.6;cursor:not-allowed;}",""),tableWrapper:b("background:",f.surface,";border-radius:8px;border:1px solid ",f.border,";overflow-x:auto;",""),table:{name:"nufjao",styles:"width:100%;min-width:600px;border-collapse:collapse;white-space:nowrap"},th:b("text-align:left;font-size:11px;color:",f.textMuted,";text-transform:uppercase;letter-spacing:0.05em;padding:12px 16px;font-weight:600;background:",f.background,";border-bottom:1px solid ",f.border,";",""),thCheckbox:{name:"5iz1wr",styles:"width:48px"},thSize:{name:"yct5co",styles:"width:96px"},thDimensions:{name:"gu2s0e",styles:"width:128px"},thCdn:{name:"yct5co",styles:"width:96px"},tbody:b("",""),row:b("cursor:pointer;transition:background-color 0.15s ease;user-select:none;&:hover{background-color:",f.surfaceHover,";}&:not(:last-child) td{border-bottom:1px solid ",f.borderLight,";}",""),rowSelected:b("background-color:",f.primaryLight,";&:hover{background-color:",f.primaryLight,";}",""),parentRow:b("cursor:pointer;border-bottom:1px solid ",f.border,";&:hover{background-color:",f.surfaceHover,";}",""),td:{name:"i563hg",styles:"padding:12px 16px"},checkboxCell:{name:"sahq4q",styles:"padding:12px 16px;cursor:pointer;vertical-align:middle"},checkbox:b("width:18px;height:18px;accent-color:",f.primary,";cursor:pointer;display:block;",""),actionsCell:{name:"1w56d5c",styles:"display:flex;align-items:center;justify-content:flex-end;gap:8px;margin-left:auto;flex-shrink:0"},copyBtn:b("position:relative;flex-shrink:0;height:32px;width:32px;font-size:",K.xs,";color:",f.textSecondary,";background:",f.surface,";border:1px solid ",f.border,";padding:0;cursor:pointer;border-radius:4px;transition:all 0.15s ease;display:inline-flex;align-items:center;justify-content:center;&:hover{background:",f.surfaceHover,";border-color:",f.borderHover,";color:",f.text,";}",""),copyIcon:{name:"157xhr7",styles:"width:16px;height:16px"},folderStats:{name:"1yydxi7",styles:"display:flex;align-items:center;gap:8px"},folderStat:b("display:flex;align-items:center;gap:3px;font-size:",K.xs,";",""),folderStatLocal:b("color:",f.textMuted,";",""),folderStatCloud:{name:"1t8qh25",styles:"color:#f59e0b"},folderStatRemote:{name:"1lukubv",styles:"color:#ef4444"},folderStatUpdate:{name:"1t8qh25",styles:"color:#f59e0b"},folderStatIconCloud:{name:"1pgx8p4",styles:"width:14px;height:14px;color:#f59e0b"},folderStatIconLocal:b("width:14px;height:14px;color:",f.textSecondary,";",""),folderStatIconRemote:{name:"efr29r",styles:"width:14px;height:14px;color:#ef4444"},folderStatIconUpdate:{name:"1pgx8p4",styles:"width:14px;height:14px;color:#f59e0b"},updateLabel:b("display:flex;align-items:center;gap:4px;color:#f59e0b;font-size:",K.xs,";",""),updateCloudIcon:{name:"1pgx8p4",styles:"width:14px;height:14px;color:#f59e0b"},updateSyncIcon:{name:"1pgx8p4",styles:"width:14px;height:14px;color:#f59e0b"},storedLabel:{name:"s5xdrg",styles:"display:flex;align-items:center"},storedIconCloud:{name:"1e09qmx",styles:"width:16px;height:16px;color:#f59e0b"},storedIconRemote:{name:"1mrh6ju",styles:"width:16px;height:16px;color:#ef4444"},tooltip:{name:"1bu1odp",styles:"position:absolute;top:50%;right:100%;transform:translateY(-50%);background:#1a1f36;color:white;padding:4px 8px;border-radius:4px;font-size:12px;white-space:nowrap;margin-right:6px;pointer-events:none;z-index:100;&::after{content:'';position:absolute;left:100%;top:50%;transform:translateY(-50%);border:4px solid transparent;border-left-color:#1a1f36;}"},nameCell:{name:"9s3nhy",styles:"display:flex;align-items:center;gap:12px;flex:1"},thumbnailWrapper:{name:"xfecxx",styles:"width:48px;height:36px;display:flex;align-items:center;justify-content:center;flex-shrink:0"},folderIconWrapper:{name:"xfecxx",styles:"width:48px;height:36px;display:flex;align-items:center;justify-content:center;flex-shrink:0"},folderIcon:{name:"a45yt2",styles:"width:24px;height:24px;color:#f9935e"},imagesFolderWrapper:{name:"iqqile",styles:"width:48px;height:36px;display:flex;align-items:center;justify-content:center;flex-shrink:0;position:relative;align-items:center"},imagesFolderIcon:b("width:24px;height:24px;color:",f.imagesFolder,";",""),lockIcon:b("width:10px;height:10px;color:",f.imagesFolder,";margin-left:-6px;margin-top:8px;",""),parentIcon:b("width:20px;height:20px;color:",f.textMuted,";flex-shrink:0;",""),fileIcon:b("width:20px;height:20px;color:",f.textMuted,";flex-shrink:0;",""),thumbnail:b("max-width:100%;max-height:100%;width:auto;height:auto;object-fit:contain;border-radius:4px;border:1px solid ",f.borderLight,";",""),name:b("font-size:",K.base,";font-weight:500;color:",f.text,";letter-spacing:-0.01em;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;max-width:300px;",""),meta:b("font-size:",K.sm,";color:",f.textSecondary,";",""),cdnBadge:b("display:inline-flex;align-items:center;gap:4px;font-size:",K.xs,";font-weight:500;color:",f.success,";",""),cdnBadgeRemote:b("display:inline-flex;align-items:center;font-size:",K.xs,";font-weight:500;color:#ef4444;",""),cdnIcon:{name:"1suksrg",styles:"width:12px;height:12px"},cdnEmpty:b("font-size:",K.sm,";color:",f.textMuted,";",""),openBtn:b("height:32px;font-size:",K.sm,";font-weight:500;color:",f.primary,";background:",f.surface,";border:1px solid ",f.border,";padding:0 14px;cursor:pointer;border-radius:4px;transition:all 0.15s ease;display:inline-flex;align-items:center;&:hover{background-color:",f.primaryLight,";border-color:",f.primary,";}","")};function Sg(){const{loading:o,sortedItems:s,metaEmpty:h,isAtRoot:u,isSearching:g,allItemsSelected:p,someItemsSelected:k,selectedItems:U,navigateUp:D,handleItemClick:S,handleOpen:Y,handleGenerateThumbnail:B,handleSelectAll:W,triggerScan:$,refreshKey:V}=Th();return o?c("div",{css:Q.loading,children:c("div",{css:Q.spinner})}):h&&u?x("div",{css:Q.empty,children:[c("p",{children:"No files tracked yet"}),c("p",{css:Q.emptyHint,children:"Click Scan to discover files in your public folder"}),c("button",{css:Q.scanButton,onClick:$,children:"Scan for Files"})]}):s.length===0&&u?x("div",{css:Q.empty,children:[c("p",{children:"No files in this folder"}),c("p",{css:Q.emptyHint,children:"Upload images or click Scan in the toolbar"})]}):c("div",{css:Q.tableWrapper,children:x("table",{css:Q.table,children:[c("thead",{children:x("tr",{children:[c("th",{css:[Q.th,Q.thCheckbox,"",""],children:s.length>0&&c("input",{type:"checkbox",css:Q.checkbox,checked:p,ref:q=>{q&&(q.indeterminate=k&&!p)},onChange:W})}),c("th",{css:Q.th,children:"Name"}),c("th",{css:[Q.th,Q.thSize,"",""],children:"Size"}),c("th",{css:[Q.th,Q.thDimensions,"",""],children:"Dimensions"}),c("th",{css:[Q.th,Q.thCdn,"",""],children:"CDN"})]})}),x("tbody",{css:Q.tbody,children:[!u&&!g&&x("tr",{css:Q.parentRow,onClick:D,children:[c("td",{css:Q.td}),c("td",{css:Q.td,children:x("div",{css:Q.nameCell,children:[c("svg",{css:Q.parentIcon,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:1.5,d:"M3 10h10a8 8 0 018 8v2M3 10l6 6m-6-6l6-6"})}),c("span",{css:Q.name,children:".."})]})}),c("td",{css:[Q.td,Q.meta,"",""],children:"--"}),c("td",{css:[Q.td,Q.meta,"",""],children:"Parent folder"}),c("td",{css:Q.td,children:"--"})]}),s.map(q=>c(Cg,{item:q,isSelected:U.has(q.path),onClick:de=>S(q,de),onOpen:()=>Y(q),onGenerateThumbnail:()=>B(q),cacheKey:V},q.path))]})]})})}function Cg({item:o,isSelected:s,onClick:h,onOpen:u,onGenerateThumbnail:g,cacheKey:p}){const[k,U]=M.useState(!1),D=o.type==="folder",S=!D&&o.thumbnail!==void 0,Y=o.isProtected||D&&o.name==="images"&&o.path==="public/images",B=$=>{$.stopPropagation();const V="/"+o.path.replace(/^public\//,"");navigator.clipboard.writeText(V),U(!0),setTimeout(()=>U(!1),1500)},W=$=>{if(Y){$.stopPropagation(),u();return}h($)};return x("tr",{css:[Q.row,s&&!Y&&Q.rowSelected,"",""],onClick:W,children:[c("td",{css:[Q.td,Q.checkboxCell,"",""],onClick:$=>$.stopPropagation(),children:!Y&&c("input",{type:"checkbox",css:Q.checkbox,checked:s,onChange:()=>h({})})}),c("td",{css:Q.td,children:x("div",{css:Q.nameCell,children:[D?Y?x("div",{css:Q.imagesFolderWrapper,children:[c("svg",{css:Q.imagesFolderIcon,fill:"currentColor",viewBox:"0 0 24 24",children:c("path",{d:"M10 4H4a2 2 0 00-2 2v12a2 2 0 002 2h16a2 2 0 002-2V8a2 2 0 00-2-2h-8l-2-2z"})}),c("svg",{css:Q.lockIcon,fill:"currentColor",viewBox:"0 0 20 20",children:c("path",{fillRule:"evenodd",d:"M5 9V7a5 5 0 0110 0v2a2 2 0 012 2v5a2 2 0 01-2 2H5a2 2 0 01-2-2v-5a2 2 0 012-2zm8-2v2H7V7a3 3 0 016 0z",clipRule:"evenodd"})})]}):c("div",{css:Q.folderIconWrapper,children:c("svg",{css:Q.folderIcon,fill:"currentColor",viewBox:"0 0 24 24",children:c("path",{d:"M10 4H4a2 2 0 00-2 2v12a2 2 0 002 2h16a2 2 0 002-2V8a2 2 0 00-2-2h-8l-2-2z"})})}):S&&o.thumbnail?c("div",{css:Q.thumbnailWrapper,children:c("img",{css:Q.thumbnail,src:`${o.thumbnail}${o.thumbnail.includes("?")?"&":"?"}v=${p}`,alt:o.name,loading:"lazy"})}):c("div",{css:Q.thumbnailWrapper,children:c("svg",{css:Q.fileIcon,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:1.5,d:"M7 21h10a2 2 0 002-2V9.414a1 1 0 00-.293-.707l-5.414-5.414A1 1 0 0012.586 3H7a2 2 0 00-2 2v14a2 2 0 002 2z"})})}),c("span",{css:Q.name,title:o.name,children:zg(o.name)}),x("div",{css:Q.actionsCell,children:[x("button",{css:Q.copyBtn,onClick:B,title:"Copy file path",children:[k&&c("span",{css:Q.tooltip,children:"Copied!"}),c("svg",{css:Q.copyIcon,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"})})]}),c("button",{css:Q.openBtn,onClick:$=>{$.stopPropagation(),u()},children:"Open"})]})]})}),c("td",{css:[Q.td,Q.meta,"",""],children:D?x("div",{css:Q.folderStats,children:[o.localCount!==void 0&&o.localCount>0&&x("span",{css:[Q.folderStat,Q.folderStatLocal,"",""],title:`${o.localCount} local`,children:[c("svg",{css:Q.folderStatIconLocal,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M4 16l4.586-4.586a2 2 0 012.828 0L16 16m-2-2l1.586-1.586a2 2 0 012.828 0L20 14m-6-6h.01M6 20h12a2 2 0 002-2V6a2 2 0 00-2-2H6a2 2 0 00-2 2v12a2 2 0 002 2z"})}),o.localCount]}),o.cloudCount!==void 0&&o.cloudCount>0&&x("span",{css:[Q.folderStat,Q.folderStatCloud,"",""],title:`${o.cloudCount} in cloud`,children:[c("svg",{css:Q.folderStatIconCloud,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M3 15a4 4 0 004 4h9a5 5 0 10-.1-9.999 5.002 5.002 0 10-9.78 2.096A4.001 4.001 0 003 15z"})}),o.cloudCount]}),o.remoteCount!==void 0&&o.remoteCount>0&&x("span",{css:[Q.folderStat,Q.folderStatRemote,"",""],title:`${o.remoteCount} remote`,children:[c("svg",{css:Q.folderStatIconRemote,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M21 12a9 9 0 01-9 9m9-9a9 9 0 00-9-9m9 9H3m9 9a9 9 0 01-9-9m9 9c1.657 0 3-4.03 3-9s-1.343-9-3-9m0 18c-1.657 0-3-4.03-3-9s1.343-9 3-9m-9 9a9 9 0 019-9"})}),o.remoteCount]}),o.updateCount!==void 0&&o.updateCount>0&&x("span",{css:[Q.folderStat,Q.folderStatUpdate,"",""],title:`${o.updateCount} pending update${o.updateCount!==1?"s":""}`,children:[c("svg",{css:Q.folderStatIconUpdate,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M4 4v5h.582m15.356 2A8.001 8.001 0 004.582 9m0 0H9m11 11v-5h-.581m0 0a8.003 8.003 0 01-15.357-2m15.357 2H15"})}),o.updateCount]}),!o.localCount&&!o.cloudCount&&!o.remoteCount&&!o.updateCount&&o.fileCount!==void 0&&x("span",{children:[o.fileCount," files"]}),!o.localCount&&!o.cloudCount&&!o.remoteCount&&!o.updateCount&&o.fileCount===void 0&&"--"]}):o.hasUpdate?x("span",{css:Q.updateLabel,children:[c("svg",{css:Q.updateCloudIcon,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M3 15a4 4 0 004 4h9a5 5 0 10-.1-9.999 5.002 5.002 0 10-9.78 2.096A4.001 4.001 0 003 15z"})}),c("svg",{css:Q.updateSyncIcon,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M4 4v5h.582m15.356 2A8.001 8.001 0 004.582 9m0 0H9m11 11v-5h-.581m0 0a8.003 8.003 0 01-15.357-2m15.357 2H15"})}),"update"]}):o.cdnPushed?c("span",{css:Q.storedLabel,children:c("svg",{css:o.isRemote?Q.storedIconRemote:Q.storedIconCloud,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:o.isRemote?c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M21 12a9 9 0 01-9 9m9-9a9 9 0 00-9-9m9 9H3m9 9a9 9 0 01-9-9m9 9c1.657 0 3-4.03 3-9s-1.343-9-3-9m0 18c-1.657 0-3-4.03-3-9s1.343-9 3-9m-9 9a9 9 0 019-9"}):c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M3 15a4 4 0 004 4h9a5 5 0 10-.1-9.999 5.002 5.002 0 10-9.78 2.096A4.001 4.001 0 003 15z"})})}):o.size!==void 0?ch(o.size):"--"}),c("td",{css:[Q.td,Q.meta,"",""],children:D?o.totalSize!==void 0?ch(o.totalSize):"--":o.dimensions?`${o.dimensions.width}x${o.dimensions.height}`:"--"}),c("td",{css:Q.td,children:o.cdnPushed?o.isRemote?c("span",{css:Q.cdnBadgeRemote,children:"Remote"}):x("span",{css:Q.cdnBadge,children:[c("svg",{css:Q.cdnIcon,fill:"currentColor",viewBox:"0 0 20 20",children:c("path",{fillRule:"evenodd",d:"M16.707 5.293a1 1 0 010 1.414l-8 8a1 1 0 01-1.414 0l-4-4a1 1 0 011.414-1.414L8 12.586l7.293-7.293a1 1 0 011.414 0z",clipRule:"evenodd"})}),"Pushed"]}):c("span",{css:Q.cdnEmpty,children:"--"})})]})}function ch(o){return o<1024?`${o} B`:o<1024*1024?`${(o/1024).toFixed(1)} KB`:`${(o/(1024*1024)).toFixed(1)} MB`}function zg(o,s=32){if(o.length<=s)return o;const h=o.lastIndexOf("."),u=h>0?o.substring(h):"",g=h>0?o.substring(0,h):o,p=s-u.length-3;if(p<6)return o.substring(0,s-3)+"...";const k=Math.ceil(p/2),U=Math.floor(p/2);return g.substring(0,k)+"..."+g.substring(g.length-U)+u}const wg=[".jpg",".jpeg",".png",".gif",".webp",".svg",".ico",".bmp",".tiff",".tif"],Mg=[".mp4",".webm",".mov",".avi",".mkv",".m4v"];function Tg(o){const s=o.toLowerCase().substring(o.lastIndexOf("."));return wg.includes(s)}function Ag(o){const s=o.toLowerCase().substring(o.lastIndexOf("."));return Mg.includes(s)}const fe={overlay:{name:"1crgpqk",styles:"position:absolute;top:0;left:0;right:0;bottom:0;z-index:100;display:flex;background:transparent"},container:b("display:flex;flex:1;margin:24px;background:",f.surface,";border:1px solid ",f.border,";border-radius:12px;overflow:hidden;box-shadow:0 20px 40px rgba(0, 0, 0, 0.2);",""),main:b("position:relative;flex:1;display:flex;flex-direction:column;align-items:center;justify-content:center;padding:24px;background:",f.background,";overflow:auto;",""),headerButtons:{name:"8wfhwn",styles:"position:absolute;top:16px;right:16px;display:flex;gap:8px;z-index:10"},copyBtn:b("position:relative;padding:8px;background:",f.surface,";border:1px solid ",f.border,";border-radius:8px;cursor:pointer;transition:all 0.15s ease;display:flex;align-items:center;justify-content:center;box-shadow:0 2px 4px rgba(0, 0, 0, 0.08);&:hover{background-color:",f.surfaceHover,";border-color:",f.borderHover,";}",""),copyIcon:b("width:20px;height:20px;color:",f.textSecondary,";",""),statusIcon:b("display:flex;align-items:center;justify-content:center;padding:8px;background:",f.surface,";border:1px solid ",f.border,";border-radius:8px;box-shadow:0 2px 4px rgba(0, 0, 0, 0.08);",""),cloudIcon:{name:"1byef48",styles:"width:22px;height:22px;color:#f59e0b;transform:translateY(1px)"},globeIcon:{name:"jso3j5",styles:"width:20px;height:20px;color:#ef4444"},tooltip:{name:"1w9prgf",styles:"position:absolute;right:100%;top:50%;transform:translateY(-50%);background:#1a1f36;color:white;padding:4px 8px;border-radius:4px;font-size:12px;white-space:nowrap;margin-right:8px;pointer-events:none;z-index:100;&::after{content:'';position:absolute;left:100%;top:50%;transform:translateY(-50%);border:4px solid transparent;border-left-color:#1a1f36;}"},mainCloseBtn:b("padding:8px;background:",f.surface,";border:1px solid ",f.border,";border-radius:8px;cursor:pointer;transition:all 0.15s ease;display:flex;align-items:center;justify-content:center;box-shadow:0 2px 4px rgba(0, 0, 0, 0.08);&:hover{background-color:",f.surfaceHover,";border-color:",f.borderHover,";}",""),mainCloseIcon:b("width:20px;height:20px;color:",f.textSecondary,";",""),mediaWrapper:{name:"zr0bjt",styles:"max-width:100%;max-height:100%;display:flex;align-items:center;justify-content:center"},image:{name:"4gte4n",styles:"max-width:100%;max-height:calc(100vh - 200px);object-fit:contain;border-radius:8px;box-shadow:0 4px 12px rgba(0, 0, 0, 0.1)"},video:{name:"1talud7",styles:"max-width:100%;max-height:calc(100vh - 200px);border-radius:8px;box-shadow:0 4px 12px rgba(0, 0, 0, 0.1)"},filePlaceholder:b("display:flex;flex-direction:column;align-items:center;justify-content:center;padding:48px;background:",f.surface,";border-radius:12px;border:1px solid ",f.border,";",""),fileIcon:b("width:80px;height:80px;color:",f.textMuted,";margin-bottom:16px;",""),fileName:b("font-size:",K.lg,";font-weight:600;color:",f.text,";margin:0;",""),sidebar:b("width:280px;background:",f.surface,";border-left:1px solid ",f.border,";display:flex;flex-direction:column;overflow:hidden;",""),sidebarHeader:b("padding:16px 20px;border-bottom:1px solid ",f.border,";",""),sidebarTitle:b("font-size:",K.base,";font-weight:600;color:",f.text,";margin:0;",""),sidebarContent:{name:"esl95u",styles:"flex:1;padding:20px;overflow:auto"},info:{name:"bh1r16",styles:"display:flex;flex-direction:column;gap:12px;margin-bottom:24px"},infoRow:b("display:flex;justify-content:space-between;font-size:",K.sm,";",""),infoLabel:b("color:",f.textSecondary,";",""),infoValue:b("color:",f.text,";font-weight:500;text-align:right;max-width:160px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;",""),infoValueWrap:b("color:",f.text,";font-weight:500;text-align:right;max-width:160px;word-break:break-all;white-space:normal;",""),infoLink:b("color:",f.primary,";font-weight:500;text-align:right;max-width:160px;word-break:break-all;white-space:normal;text-decoration:none;&:hover{text-decoration:underline;}",""),actions:{name:"3w0yoi",styles:"display:flex;flex-direction:column;gap:8px"},actionBtn:b("display:flex;align-items:center;gap:10px;width:100%;padding:12px 14px;font-size:",K.base,";font-weight:500;background:",f.surface,";border:1px solid ",f.border,";border-radius:6px;cursor:pointer;transition:all 0.15s ease;color:",f.text,";text-align:left;&:hover:not(:disabled){background-color:",f.surfaceHover,";border-color:",f.borderHover,";}&:disabled{opacity:0.5;cursor:not-allowed;}",""),actionBtnDanger:b("color:",f.danger,";&:hover:not(:disabled){background-color:",f.dangerLight,";border-color:",f.danger,";}",""),actionIcon:{name:"a4lfw4",styles:"width:16px;height:16px;flex-shrink:0"}};function Eg(){const{focusedItem:o,setFocusedItem:s,triggerRefresh:h,refreshKey:u,fileItems:g,requestDelete:p,requestMove:k,requestSync:U,requestProcess:D,actionState:S}=ja(),[Y,B]=M.useState(!1),[W,$]=M.useState(!1),[V,q]=M.useState(null),[de,I]=M.useState(!1),[ue,le]=M.useState(!1),[re,_]=M.useState(!1),[X,j]=M.useState({current:0,total:3,percent:0,status:"processing",message:"Generating favicons..."}),ge=S.showProgress,He=o?o.name.toLowerCase()==="favicon.png"||o.name.toLowerCase()==="favicon.jpg":!1;if(!o)return null;const _e=Tg(o.name),Ne=Ag(o.name),Le="/"+o.path.replace(/^public\//,""),We=o.cdnPushed&&o.cdnBaseUrl?`${o.cdnBaseUrl}${Le}`:Le,Ie=`${We}${We.includes("?")?"&":"?"}v=${u}`,ze=typeof window<"u"?window.location.origin:"",A=o.cdnPushed&&o.cdnBaseUrl?`${o.cdnBaseUrl}${Le}`:`${ze}${Le}`,G=()=>{s(null)},P=()=>{navigator.clipboard.writeText(A),le(!0),setTimeout(()=>le(!1),1500)},pe=async O=>{if(B(!1),O&&O!==o.name)try{const Z=await fetch("/api/studio/rename",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({oldPath:o.path,newName:O})});if(Z.ok)h(),s(null);else{const ee=await Z.json();q({title:"Rename Failed",message:ee.error||"Failed to rename file"})}}catch(Z){console.error("Rename error:",Z),q({title:"Rename Failed",message:"An error occurred while renaming the file"})}},ke=async()=>{if(!(!o||!o.cdnPushed)){I(!0);try{const O=await fetch("/api/studio/clear-cache",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({paths:[o.path]})}),Z=await O.json();O.ok?(h(),q({title:"Cache Cleared",message:Z.message||"CDN cache cleared successfully."})):q({title:"Clear Cache Failed",message:Z.error||"Failed to clear cache."})}catch(O){console.error("Clear cache error:",O),q({title:"Clear Cache Failed",message:"An error occurred. Check console for details."})}finally{I(!1)}}},y=async()=>{if(o){_(!0),j({current:0,total:3,percent:0,status:"processing",message:"Generating favicons..."});try{const O=await fetch("/api/studio/generate-favicon",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({imagePath:"/"+o.path.replace(/^public\//,"")})});if(!O.ok){const Ce=await O.json();j({current:0,total:3,percent:0,status:"error",message:Ce.error||"Failed to generate favicons"});return}const Z=O.body?.getReader(),ee=new TextDecoder;if(Z){let Ce="";for(;;){const{done:Ue,value:ht}=await Z.read();if(Ue)break;Ce+=ee.decode(ht,{stream:!0});const Ke=Ce.split(`
|
|
67
|
+
`);Ce=Ke.pop()||"";for(const nl of Ke)if(nl.startsWith("data: "))try{const te=JSON.parse(nl.slice(6));te.type==="start"?j(Kt=>({...Kt,total:te.total})):te.type==="progress"?j({current:te.current,total:te.total,percent:te.percent,status:"processing",message:te.message}):te.type==="complete"?j({current:te.processed,total:te.processed,percent:100,status:te.errors>0?"error":"complete",message:te.message}):te.type==="error"&&j(Kt=>({...Kt,status:"error",message:te.message}))}catch{}}}}catch(O){console.error("Favicon generation error:",O),j({current:0,total:3,percent:0,status:"error",message:"An error occurred while generating favicons"})}}},L=()=>_e?c("img",{css:fe.image,src:Ie,alt:o.name}):Ne?c("video",{css:fe.video,src:Ie,controls:!0}):x("div",{css:fe.filePlaceholder,children:[c("svg",{css:fe.fileIcon,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:1.5,d:"M7 21h10a2 2 0 002-2V9.414a1 1 0 00-.293-.707l-5.414-5.414A1 1 0 0012.586 3H7a2 2 0 00-2 2v14a2 2 0 002 2z"})}),c("p",{css:fe.fileName,children:o.name})]});return x(Tt,{children:[V&&c(zh,{title:V.title,message:V.message,onClose:()=>q(null)}),c(Mh,{isOpen:W,onClose:()=>$(!1)}),Y&&c(Ys,{title:"Rename File",message:"Enter a new name for the file:",defaultValue:o.name,placeholder:"Enter new filename",confirmLabel:"Rename",onConfirm:pe,onCancel:()=>B(!1)}),re&&c(Js,{title:"Generating Favicons",progress:X,onClose:()=>_(!1)}),c("div",{css:fe.overlay,onClick:G,children:x("div",{css:fe.container,onClick:O=>O.stopPropagation(),children:[x("div",{css:fe.main,children:[x("div",{css:fe.headerButtons,children:[o.cdnPushed&&!o.isRemote&&c("span",{css:fe.statusIcon,title:"Pushed to CDN",children:c("svg",{css:fe.cloudIcon,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M3 15a4 4 0 004 4h9a5 5 0 10-.1-9.999 5.002 5.002 0 10-9.78 2.096A4.001 4.001 0 003 15z"})})}),o.isRemote&&c("span",{css:fe.statusIcon,title:"Remote image",children:c("svg",{css:fe.globeIcon,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M21 12a9 9 0 01-9 9m9-9a9 9 0 00-9-9m9 9H3m9 9a9 9 0 01-9-9m9 9c1.657 0 3-4.03 3-9s-1.343-9-3-9m0 18c-1.657 0-3-4.03-3-9s1.343-9 3-9m-9 9a9 9 0 019-9"})})}),x("button",{css:fe.copyBtn,onClick:P,title:"Copy file path",children:[ue&&c("span",{css:fe.tooltip,children:"Copied!"}),c("svg",{css:fe.copyIcon,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"})})]}),c("button",{css:fe.mainCloseBtn,onClick:G,"aria-label":"Close",children:c("svg",{css:fe.mainCloseIcon,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M6 18L18 6M6 6l12 12"})})})]}),c("div",{css:fe.mediaWrapper,children:L()})]}),x("div",{css:fe.sidebar,children:[c("div",{css:fe.sidebarHeader,children:c("h3",{css:fe.sidebarTitle,children:"Details"})}),x("div",{css:fe.sidebarContent,children:[x("div",{css:fe.info,children:[x("div",{css:fe.infoRow,children:[c("span",{css:fe.infoLabel,children:"Name"}),c("span",{css:fe.infoValueWrap,children:o.name})]}),x("div",{css:fe.infoRow,children:[c("span",{css:fe.infoLabel,children:"Path"}),c("span",{css:fe.infoValueWrap,children:o.path.replace(/^public\//,"")})]}),o.size!==void 0&&x("div",{css:fe.infoRow,children:[c("span",{css:fe.infoLabel,children:"Size"}),c("span",{css:fe.infoValue,children:_g(o.size)})]}),o.dimensions&&x("div",{css:fe.infoRow,children:[c("span",{css:fe.infoLabel,children:"Dimensions"}),x("span",{css:fe.infoValue,children:[o.dimensions.width," × ",o.dimensions.height]})]}),x("div",{css:fe.infoRow,children:[c("span",{css:fe.infoLabel,children:"CDN Status"}),c("span",{css:fe.infoValue,children:o.cdnPushed?o.isRemote?"Remote":"Pushed":"Local"})]}),x("div",{css:fe.infoRow,children:[c("span",{css:fe.infoLabel,children:"URL"}),c("a",{href:A,target:"_blank",rel:"noopener noreferrer",css:fe.infoLink,title:A,children:A})]})]}),x("div",{css:fe.actions,children:[x("button",{css:fe.actionBtn,onClick:()=>B(!0),disabled:o.isProtected,children:[c("svg",{css:fe.actionIcon,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M11 5H6a2 2 0 00-2 2v11a2 2 0 002 2h11a2 2 0 002-2v-5m-1.414-9.414a2 2 0 112.828 2.828L11.828 15H9v-2.828l8.586-8.586z"})}),"Rename"]}),x("button",{css:fe.actionBtn,onClick:()=>k([o.path]),disabled:ge||o.isProtected,children:[c("svg",{css:fe.actionIcon,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M8 7h12m0 0l-4-4m4 4l-4 4m0 6H4m0 0l4 4m-4-4l4-4"})}),"Move"]}),x("button",{css:fe.actionBtn,onClick:()=>U([o.path],g),disabled:ge||o.isProtected||o.cdnPushed&&!o.isRemote,title:o.cdnPushed&&!o.isRemote?"Already in R2":void 0,children:[c("svg",{css:fe.actionIcon,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M7 16a4 4 0 01-.88-7.903A5 5 0 1115.9 6L16 6a5 5 0 011 9.9M15 13l-3-3m0 0l-3 3m3-3v12"})}),"Push to CDN"]}),o.cdnPushed&&x("button",{css:fe.actionBtn,onClick:ke,disabled:de||o.isProtected,children:[c("svg",{css:fe.actionIcon,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M4 4v5h.582m15.356 2A8.001 8.001 0 004.582 9m0 0H9m11 11v-5h-.581m0 0a8.003 8.003 0 01-15.357-2m15.357 2H15"})}),de?"Clearing...":"Clear Cache"]}),x("button",{css:fe.actionBtn,onClick:()=>D([o.path]),disabled:ge||o.isProtected,children:[c("svg",{css:fe.actionIcon,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M4 16l4.586-4.586a2 2 0 012.828 0L16 16m-2-2l1.586-1.586a2 2 0 012.828 0L20 14m-6-6h.01M6 20h12a2 2 0 002-2V6a2 2 0 00-2-2H6a2 2 0 00-2 2v12a2 2 0 002 2z"})}),"Process Image"]}),He&&x("button",{css:fe.actionBtn,onClick:y,disabled:re||o.isProtected,children:[c("svg",{css:fe.actionIcon,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M5 3v4M3 5h4M6 17v4m-2-2h4m5-16l2.286 6.857L21 12l-5.714 2.143L13 21l-2.286-6.857L5 12l5.714-2.143L13 3z"})}),"Generate Favicons"]}),x("button",{css:[fe.actionBtn,fe.actionBtnDanger,"",""],onClick:()=>p([o.path]),disabled:ge||o.isProtected,children:[c("svg",{css:fe.actionIcon,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M19 7l-.867 12.142A2 2 0 0116.138 21H7.862a2 2 0 01-1.995-1.858L5 7m5 4v6m4-6v6m1-10V4a1 1 0 00-1-1h-4a1 1 0 00-1 1v3M4 7h16"})}),"Delete"]})]})]})]})]})})]})}function _g(o){return o<1024?`${o} B`:o<1024*1024?`${(o/1024).toFixed(1)} KB`:`${(o/(1024*1024)).toFixed(1)} MB`}const kg="36px",be={btn:b("height:",kg,";padding:0 12px;background:",f.surface,";border:1px solid ",f.border,";border-radius:6px;cursor:pointer;transition:all 0.15s ease;display:flex;align-items:center;justify-content:center;&:hover{background-color:",f.surfaceHover,";border-color:",f.borderHover,";}",""),icon:b("width:16px;height:16px;color:",f.textSecondary,";",""),overlay:{name:"v3r9wg",styles:"position:fixed;top:0;right:0;bottom:0;left:0;z-index:10000;display:flex;align-items:center;justify-content:center;background-color:rgba(26, 31, 54, 0.4);backdrop-filter:blur(4px)"},panel:b(qi," position:relative;background-color:",f.surface,";border-radius:12px;box-shadow:0 30px 60px -12px rgba(50, 50, 93, 0.25),0 18px 36px -18px rgba(0, 0, 0, 0.3);width:100%;max-width:512px;padding:24px;",""),header:{name:"1o4fids",styles:"display:flex;align-items:center;justify-content:space-between;margin-bottom:24px"},title:b("font-size:",K.xl,";font-weight:600;color:",f.text,";margin:0;letter-spacing:-0.02em;",""),closeBtn:b("padding:6px;background:",f.surface,";border:1px solid ",f.border,";border-radius:6px;cursor:pointer;transition:all 0.15s ease;display:flex;align-items:center;justify-content:center;&:hover{background-color:",f.surfaceHover,";border-color:",f.borderHover,";}",""),sections:{name:"klisov",styles:"display:flex;flex-direction:column;gap:24px"},sectionTitle:b("font-size:",K.base,";font-weight:600;color:",f.text,";margin:0 0 12px 0;",""),description:b("font-size:",K.sm,";color:",f.textSecondary,";margin:0 0 12px 0;",""),codeWrapper:{name:"bjn8wh",styles:"position:relative"},code:b("background-color:",f.background,";border-radius:8px;padding:12px;padding-right:40px;font-family:'SF Mono',Monaco,Consolas,monospace;font-size:",K.xs,";color:",f.textSecondary,";border:1px solid ",f.border,";overflow-x:auto;white-space:nowrap;",""),copyBtn:b("position:absolute;top:8px;right:8px;padding:4px;background:",f.surface,";border:1px solid ",f.border,";border-radius:4px;cursor:pointer;transition:all 0.15s ease;display:flex;align-items:center;justify-content:center;&:hover{background-color:",f.surfaceHover,";border-color:",f.borderHover,";}",""),tooltip:{name:"6eskey",styles:"position:absolute;bottom:100%;left:50%;transform:translateX(-50%);background:#1a1f36;color:white;padding:4px 8px;border-radius:4px;font-size:12px;white-space:nowrap;margin-bottom:6px;pointer-events:none;z-index:100;&::after{content:'';position:absolute;top:100%;left:50%;transform:translateX(-50%);border:4px solid transparent;border-top-color:#1a1f36;}"},copyIcon:b("width:14px;height:14px;color:",f.textSecondary,";",""),codeLine:{name:"1bbvuqp",styles:"margin:0 0 4px 0;&:last-child{margin:0;}"},input:b("width:100%;padding:10px 14px;border:1px solid ",f.border,";border-radius:6px;font-size:",K.base,";color:",f.text,";background:",f.surface,";transition:all 0.15s ease;&:focus{outline:none;border-color:",f.primary,";box-shadow:0 0 0 3px ",f.primaryLight,";}&::placeholder{color:",f.textMuted,";}",""),grid:{name:"xtlr5l",styles:"display:grid;grid-template-columns:repeat(3, 1fr);gap:12px"},label:b("font-size:",K.xs,";font-weight:500;color:",f.textSecondary,";display:block;margin-bottom:6px;",""),footer:b("margin-top:24px;padding-top:20px;border-top:1px solid ",f.border,";display:flex;justify-content:flex-end;gap:12px;",""),cancelBtn:b("padding:10px 18px;font-size:",K.base,";font-weight:500;color:",f.text,";background:",f.surface,";border:1px solid ",f.border,";border-radius:6px;cursor:pointer;transition:all 0.15s ease;&:hover{background-color:",f.surfaceHover,";border-color:",f.borderHover,";}",""),saveBtn:b("padding:10px 18px;font-size:",K.base,";font-weight:500;color:white;background-color:",f.primary,";border:1px solid ",f.primary,";border-radius:6px;cursor:pointer;transition:all 0.15s ease;&:hover{background-color:",f.primaryHover,";border-color:",f.primaryHover,";}&:disabled{opacity:0.6;cursor:not-allowed;}",""),cdnList:{name:"3w0yoi",styles:"display:flex;flex-direction:column;gap:8px"},cdnRow:{name:"197tvr9",styles:"display:flex;gap:8px;align-items:center"},cdnInput:b("flex:1;padding:8px 12px;border:1px solid ",f.border,";border-radius:6px;font-size:",K.sm,";color:",f.text,";background:",f.surface,";transition:all 0.15s ease;&:focus{outline:none;border-color:",f.primary,";box-shadow:0 0 0 3px ",f.primaryLight,";}",""),cdnIndex:b("font-size:",K.xs,";color:",f.textMuted,";width:24px;text-align:center;flex-shrink:0;",""),cdnDeleteBtn:b("padding:6px;background:none;border:none;cursor:pointer;color:",f.textMuted,";transition:color 0.15s;flex-shrink:0;&:hover{color:",f.danger,";}",""),cdnAddBtn:b("padding:8px 12px;font-size:",K.sm,";font-weight:500;color:",f.primary,";background:",f.primaryLight,";border:1px dashed ",f.primary,";border-radius:6px;cursor:pointer;transition:all 0.15s ease;display:flex;align-items:center;justify-content:center;gap:6px;margin-top:8px;&:hover{background:",f.surface,";}",""),warning:b("font-size:",K.xs,";color:",f.danger,";margin-top:8px;padding:8px 12px;background:",f.dangerLight,";border-radius:6px;","")};function Dg(){const[o,s]=M.useState(!1);return x(Tt,{children:[c("button",{css:be.btn,onClick:()=>s(!0),"aria-label":"Settings",children:x("svg",{css:be.icon,xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round",children:[c("circle",{cx:"12",cy:"12",r:"3"}),c("path",{d:"M19.4 15a1.65 1.65 0 00.33 1.82l.06.06a2 2 0 010 2.83 2 2 0 01-2.83 0l-.06-.06a1.65 1.65 0 00-1.82-.33 1.65 1.65 0 00-1 1.51V21a2 2 0 01-2 2 2 2 0 01-2-2v-.09A1.65 1.65 0 009 19.4a1.65 1.65 0 00-1.82.33l-.06.06a2 2 0 01-2.83 0 2 2 0 010-2.83l.06-.06a1.65 1.65 0 00.33-1.82 1.65 1.65 0 00-1.51-1H3a2 2 0 01-2-2 2 2 0 012-2h.09A1.65 1.65 0 004.6 9a1.65 1.65 0 00-.33-1.82l-.06-.06a2 2 0 010-2.83 2 2 0 012.83 0l.06.06a1.65 1.65 0 001.82.33H9a1.65 1.65 0 001-1.51V3a2 2 0 012-2 2 2 0 012 2v.09a1.65 1.65 0 001 1.51 1.65 1.65 0 001.82-.33l.06-.06a2 2 0 012.83 0 2 2 0 010 2.83l-.06.06a1.65 1.65 0 00-.33 1.82V9a1.65 1.65 0 001.51 1H21a2 2 0 012 2 2 2 0 01-2 2h-.09a1.65 1.65 0 00-1.51 1z"})]})}),o&&c(Rg,{onClose:()=>s(!1)})]})}const Og=`# Dev site link (opens from Studio header)
|
|
68
|
+
STUDIO_DEV_SITE_URL=http://localhost:3000
|
|
69
|
+
|
|
70
|
+
# Cloudflare R2 Storage
|
|
71
|
+
CLOUDFLARE_R2_ACCOUNT_ID=your_account_id
|
|
72
|
+
CLOUDFLARE_R2_ACCESS_KEY_ID=your_access_key_id
|
|
73
|
+
CLOUDFLARE_R2_SECRET_ACCESS_KEY=your_secret_access_key
|
|
74
|
+
CLOUDFLARE_R2_BUCKET_NAME=your_bucket_name
|
|
75
|
+
CLOUDFLARE_R2_PUBLIC_URL=https://your-cdn.example.com
|
|
76
|
+
|
|
77
|
+
# Cloudflare Cache Purge
|
|
78
|
+
CLOUDFLARE_ZONE_ID=your_zone_id
|
|
79
|
+
CLOUDFLARE_API_TOKEN=your_api_token`;function Rg({onClose:o}){const{triggerRefresh:s}=ja(),[h,u]=M.useState(!1),[g,p]=M.useState([]),[k,U]=M.useState(!0),[D,S]=M.useState(!1),[Y,B]=M.useState(!1);M.useEffect(()=>{async function I(){try{const le=await(await fetch("/api/studio/cdns")).json();p(le.cdns||[])}catch(ue){console.error("Failed to load CDN URLs:",ue)}finally{U(!1)}}I()},[]);const W=()=>{navigator.clipboard.writeText(Og),u(!0),setTimeout(()=>u(!1),2e3)},$=M.useCallback((I,ue)=>{p(le=>{const re=[...le];return re[I]=ue,re}),B(!0)},[]),V=M.useCallback(()=>{p(I=>[...I,""]),B(!0)},[]),q=M.useCallback(I=>{p(ue=>ue.filter((le,re)=>re!==I)),B(!0)},[]),de=M.useCallback(async()=>{S(!0);try{(await fetch("/api/studio/cdns",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({cdns:g})})).ok&&(B(!1),s(),o())}catch(I){console.error("Failed to save CDN URLs:",I)}finally{S(!1)}},[g,s,o]);return c("div",{css:be.overlay,onClick:o,children:x("div",{css:be.panel,onClick:I=>I.stopPropagation(),children:[x("div",{css:be.header,children:[c("h2",{css:be.title,children:"Settings"}),c("button",{css:be.closeBtn,onClick:o,children:c("svg",{css:be.icon,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M6 18L18 6M6 6l12 12"})})})]}),x("div",{css:be.sections,children:[x("section",{children:[c("h3",{css:be.sectionTitle,children:"CDN URLs"}),c("p",{css:be.description,children:"Manage CDN base URLs used by your images:"}),k?c("p",{css:be.description,children:"Loading..."}):x(Tt,{children:[c("div",{css:be.cdnList,children:g.map((I,ue)=>x("div",{css:be.cdnRow,children:[c("span",{css:be.cdnIndex,children:ue}),c("input",{css:be.cdnInput,type:"text",value:I,onChange:le=>$(ue,le.target.value),placeholder:"https://cdn.example.com"}),c("button",{css:be.cdnDeleteBtn,onClick:()=>q(ue),title:"Delete CDN URL",children:c("svg",{width:"16",height:"16",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M19 7l-.867 12.142A2 2 0 0116.138 21H7.862a2 2 0 01-1.995-1.858L5 7m5 4v6m4-6v6m1-10V4a1 1 0 00-1-1h-4a1 1 0 00-1 1v3M4 7h16"})})})]},ue))}),x("button",{css:be.cdnAddBtn,onClick:V,children:[c("svg",{width:"14",height:"14",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M12 4v16m8-8H4"})}),"Add CDN URL"]}),g.length>0&&c("p",{css:be.warning,children:"Warning: Changing CDN URLs may break image references. The index numbers correspond to image `c` values."})]})]}),x("section",{children:[c("h3",{css:be.sectionTitle,children:"Environment Variables"}),x("p",{css:be.description,children:["Configure in ",c("code",{children:".env.studio"})," file:"]}),x("div",{css:be.codeWrapper,children:[x("button",{css:be.copyBtn,onClick:W,title:"Copy to clipboard",children:[h&&c("span",{css:be.tooltip,children:"Copied!"}),c("svg",{css:be.copyIcon,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"})})]}),x("div",{css:be.code,children:[c("p",{css:be.codeLine,children:"STUDIO_DEV_SITE_URL=http://localhost:3000"}),c("p",{css:be.codeLine,children:" "}),c("p",{css:be.codeLine,children:"# Cloudflare R2 Storage"}),c("p",{css:be.codeLine,children:"CLOUDFLARE_R2_ACCOUNT_ID=your_account_id"}),c("p",{css:be.codeLine,children:"CLOUDFLARE_R2_ACCESS_KEY_ID=your_access_key_id"}),c("p",{css:be.codeLine,children:"CLOUDFLARE_R2_SECRET_ACCESS_KEY=your_secret_access_key"}),c("p",{css:be.codeLine,children:"CLOUDFLARE_R2_BUCKET_NAME=your_bucket_name"}),c("p",{css:be.codeLine,children:"CLOUDFLARE_R2_PUBLIC_URL=https://your-cdn.example.com"}),c("p",{css:be.codeLine,children:" "}),c("p",{css:be.codeLine,children:"# Cloudflare Cache Purge"}),c("p",{css:be.codeLine,children:"CLOUDFLARE_ZONE_ID=your_zone_id"}),c("p",{css:be.codeLine,children:"CLOUDFLARE_API_TOKEN=your_api_token"})]})]})]}),x("section",{children:[c("h3",{css:be.sectionTitle,children:"Thumbnail Sizes"}),x("div",{css:be.grid,children:[x("div",{children:[c("label",{css:be.label,children:"Small"}),c("input",{css:be.input,type:"number",defaultValue:300})]}),x("div",{children:[c("label",{css:be.label,children:"Medium"}),c("input",{css:be.input,type:"number",defaultValue:700})]}),x("div",{children:[c("label",{css:be.label,children:"Large"}),c("input",{css:be.input,type:"number",defaultValue:1400})]})]})]})]}),x("div",{css:be.footer,children:[c("button",{css:be.cancelBtn,onClick:o,children:"Cancel"}),c("button",{css:be.saveBtn,onClick:de,disabled:D||!Y,children:D?"Saving...":"Save Changes"})]})]})})}const Kn={overlay:{name:"1u8n9cx",styles:"position:fixed;inset:0;background:rgba(0, 0, 0, 0.5);display:flex;align-items:center;justify-content:center;z-index:1100"},modal:b("background:",f.surface,";border-radius:12px;padding:24px;max-width:400px;width:90%;box-shadow:0 20px 40px rgba(0, 0, 0, 0.2);",""),header:{name:"c6eghz",styles:"display:flex;align-items:center;gap:12px;margin-bottom:12px"},icon:b("width:24px;height:24px;color:",f.danger,";flex-shrink:0;",""),title:b("font-size:",K.lg,";font-weight:600;color:",f.text,";margin:0;",""),message:b("font-size:",K.base,";color:",f.textSecondary,";margin:0 0 20px 0;line-height:1.5;",""),button:b("width:100%;padding:10px 16px;border-radius:6px;font-size:",K.base,";font-weight:500;border:none;background:",f.primary,";color:white;cursor:pointer;transition:background 0.15s ease;&:hover{background:",f.primaryHover,";}","")};function Lg(){const{error:o,clearError:s}=ja();return o?c("div",{css:Kn.overlay,onClick:s,children:x("div",{css:Kn.modal,onClick:h=>h.stopPropagation(),children:[x("div",{css:Kn.header,children:[c("svg",{css:Kn.icon,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M12 9v2m0 4h.01m-6.938 4h13.856c1.54 0 2.502-1.667 1.732-3L13.732 4c-.77-1.333-2.694-1.333-3.464 0L3.34 16c-.77 1.333.192 3 1.732 3z"})}),c("h3",{css:Kn.title,children:o.title})]}),c("p",{css:Kn.message,children:o.message}),c("button",{css:Kn.button,onClick:s,children:"OK"})]})}):null}const sh={showProgress:!1,progressTitle:"",progressState:{current:0,total:0,percent:0,status:"processing"},showDeleteConfirm:!1,showMoveModal:!1,showSyncConfirm:!1,showProcessConfirm:!1,actionPaths:[],syncImageCount:0,syncHasRemote:!1,syncHasLocal:!1,processMode:"generate"};function Ug({triggerRefresh:o,clearSelection:s,setFocusedItem:h,showError:u}){const[g,p]=M.useState(sh),k=M.useRef(null),U=M.useCallback(_=>{p(X=>({...X,progressState:typeof _=="function"?_(X.progressState):{...X.progressState,..._}}))},[]),D=M.useCallback(_=>{p(X=>({...X,actionPaths:_,showDeleteConfirm:!0}))},[]),S=M.useCallback(_=>{p(X=>({...X,actionPaths:_,showMoveModal:!0}))},[]),Y=M.useCallback((_,X)=>{const j=_.map(_e=>"/"+_e.replace(/^public\//,""));let ge=!1,He=!1;for(const _e of _){const Ne=X.find(Le=>Le.path===_e);Ne&&(Ne.isRemote?ge=!0:Ne.cdnPushed||(He=!0))}p(_e=>({..._e,actionPaths:_,syncImageCount:j.length,syncHasRemote:ge,syncHasLocal:He,showSyncConfirm:!0}))},[]),B=M.useCallback(_=>{p(X=>({...X,actionPaths:_,showProcessConfirm:!0,processMode:"generate"}))},[]),W=M.useCallback(_=>{p(X=>({...X,processMode:_}))},[]),$=M.useCallback(()=>{p(_=>({..._,showDeleteConfirm:!1,showMoveModal:!1,showSyncConfirm:!1,showProcessConfirm:!1}))},[]),V=M.useCallback(()=>{p(sh)},[]),q=M.useCallback(()=>{k.current&&k.current.abort()},[]),de=M.useCallback(async()=>{const _=g.actionPaths;p(X=>({...X,showDeleteConfirm:!1}));try{const X=await fetch("/api/studio/delete",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({paths:_})});if(X.ok)s(),h(null),o();else{const j=await X.json();u("Delete Failed",j.error||"Unknown error")}}catch(X){console.error("Delete error:",X),u("Delete Failed","Delete failed. Check console for details.")}},[g.actionPaths,s,h,o,u]),I=M.useCallback(async _=>{const X=g.actionPaths;p(j=>({...j,showMoveModal:!1,showProgress:!0,progressTitle:"Moving Files",progressState:{current:0,total:X.length,percent:0,status:"processing",message:"Moving files..."}}));try{const j=await fetch("/api/studio/move",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({paths:X,destination:_})});if(!j.ok){const _e=await j.json();U({status:"error",message:_e.error||"Move failed"});return}const ge=j.body?.getReader(),He=new TextDecoder;if(ge){let _e="";for(;;){const{done:Ne,value:Le}=await ge.read();if(Ne)break;_e+=He.decode(Le,{stream:!0});const We=_e.split(`
|
|
80
|
+
`);_e=We.pop()||"";for(const Ie of We)if(Ie.startsWith("data: "))try{const ze=JSON.parse(Ie.slice(6));ze.type==="start"?U(A=>({...A,total:ze.total})):ze.type==="progress"?U({current:ze.current,total:ze.total,percent:Math.round(ze.current/ze.total*100),status:"processing",message:ze.message}):ze.type==="complete"?(U(A=>({...A,status:"complete",message:`Moved ${ze.moved} file${ze.moved!==1?"s":""}${ze.errors>0?`, ${ze.errors} error${ze.errors!==1?"s":""}`:""}`})),ze.errors>0&&ze.errorMessages?.length>0&&u("Move Failed",ze.errorMessages.join(`
|
|
81
|
+
`)),s(),h(null),o()):ze.type==="error"&&U(A=>({...A,status:"error",message:ze.message||"Unknown error"}))}catch{}}}}catch(j){console.error("Move error:",j),U(ge=>({...ge,status:"error",message:"Failed to move files. Check console for details."}))}},[g.actionPaths,s,h,o,u,U]),ue=M.useCallback(async()=>{const X=g.actionPaths.map(He=>"/"+He.replace(/^public\//,""));p(He=>({...He,showSyncConfirm:!1,showProgress:!0,progressTitle:"Pushing to CDN",progressState:{current:0,total:X.length,percent:0,status:"processing",message:"Pushing to CDN..."}}));let j=0;const ge=[];for(let He=0;He<X.length;He++){const _e=X[He];U({current:He+1,total:X.length,percent:Math.round((He+1)/X.length*100),status:"processing",message:`Pushing ${_e}...`});try{const Ne=await fetch("/api/studio/sync",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({imageKeys:[_e]})});if(Ne.ok)j++;else{const Le=await Ne.json();ge.push(`${_e}: ${Le.error||"Unknown error"}`)}}catch(Ne){ge.push(`${_e}: ${Ne instanceof Error?Ne.message:"Unknown error"}`)}}U({current:X.length,total:X.length,percent:100,status:ge.length>0?"error":"complete",message:`Pushed ${j} file${j!==1?"s":""}${ge.length>0?`, ${ge.length} error${ge.length!==1?"s":""}`:""}`}),ge.length>0&&u("Push Errors",ge.join(`
|
|
82
|
+
`)),s(),o()},[g.actionPaths,s,o,u,U]),le=M.useCallback(async()=>{const _=g.actionPaths,X=g.processMode,j=_.map(We=>{const Ie=We.replace(/^public\//,"");return Ie.startsWith("/")?Ie:`/${Ie}`}),ge=X==="remove",He=ge?"/api/studio/unprocess-stream":"/api/studio/reprocess-stream",_e=ge?"Removing Thumbnails":"Generating Thumbnails",Ne=ge?"Removing thumbnails...":"Generating thumbnails...";p(We=>({...We,showProcessConfirm:!1,showProgress:!0,progressTitle:_e,progressState:{current:0,total:j.length,percent:0,status:"processing",message:Ne}})),k.current=new AbortController;const Le=k.current.signal;try{const We=await fetch(He,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({imageKeys:j}),signal:Le});if(!We.ok){const A=await We.json();U({current:0,total:j.length,percent:0,status:"error",message:A.error||(ge?"Failed to remove thumbnails":"Processing failed")});return}const Ie=We.body?.getReader(),ze=new TextDecoder;if(Ie){let A="";for(;;){const{done:G,value:P}=await Ie.read();if(G)break;A+=ze.decode(P,{stream:!0});const pe=A.split(`
|
|
83
|
+
`);A=pe.pop()||"";for(const ke of pe)if(ke.startsWith("data: "))try{const y=JSON.parse(ke.slice(6));y.type==="start"?U(L=>({...L,total:y.total})):y.type==="progress"?U({current:y.current,total:y.total,percent:y.percent,status:"processing",message:y.message}):y.type==="cleanup"?U(L=>({...L,status:"cleanup",message:y.message})):y.type==="complete"?(U({current:y.processed,total:y.processed,percent:100,status:y.errors>0?"error":"complete",message:y.message}),o()):y.type==="error"&&U(L=>({...L,status:"error",message:y.message}))}catch{}}}}catch(We){Le.aborted?U(Ie=>({...Ie,status:"stopped",message:ge?"Removal stopped by user":"Processing stopped by user"})):(console.error("Processing error:",We),U({current:0,total:j.length,percent:0,status:"error",message:ge?"Failed to remove thumbnails. Check console for details.":"Processing failed. Check console for details."}))}finally{k.current=null}},[g.actionPaths,g.processMode,o,U]),re=M.useCallback(async()=>{const _=g.progressState.orphanedFiles;if(!(!_||_.length===0))try{const X=await fetch("/api/studio/delete-orphans",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({files:_})});if(X.ok)U(j=>({...j,orphanedFiles:void 0,message:j.message?.replace(/Found \d+ orphaned thumbnail\(s\).*/,"Orphaned thumbnails deleted.")})),o();else{const j=await X.json();u("Delete Failed",j.error||"Failed to delete orphaned files")}}catch(X){console.error("Delete orphans error:",X),u("Delete Failed","Failed to delete orphaned files. Check console for details.")}},[g.progressState.orphanedFiles,o,u,U]);return{actionState:g,setActionState:p,abortController:k.current,requestDelete:D,requestMove:S,requestSync:Y,requestProcess:B,setProcessMode:W,cancelAction:$,closeProgress:V,stopProcessing:q,confirmDelete:de,confirmMove:I,confirmSync:ue,confirmProcess:le,deleteOrphans:re}}const Hg="36px",Mt={container:b(qi," display:flex;flex-direction:column;height:100%;background:",f.background,";",""),header:b("display:flex;align-items:center;justify-content:space-between;padding:12px 24px;background:",f.surface,";border-bottom:1px solid ",f.border,";position:relative;",""),title:b("font-size:",K.lg,";font-weight:600;color:",f.text,";margin:0;letter-spacing:-0.02em;flex-shrink:0;",""),headerLeft:{name:"16ur2v6",styles:"display:flex;align-items:center;gap:12px;flex:1;min-width:0"},headerCenter:{name:"1fsejhz",styles:"position:absolute;left:50%;transform:translateX(-50%);display:flex;align-items:center;max-width:50%"},breadcrumbs:b("display:flex;align-items:center;gap:6px;font-size:",K.base,";color:",f.textSecondary,";overflow:hidden;",""),breadcrumbSeparator:b("color:",f.border,";flex-shrink:0;",""),breadcrumbItem:b("color:",f.textSecondary,";text-decoration:none;cursor:pointer;transition:color 0.15s ease;white-space:nowrap;&:hover{color:",f.primary,";}",""),breadcrumbCurrent:b("color:",f.text,";font-weight:500;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;",""),headerIconBtn:b("display:flex;align-items:center;justify-content:center;width:32px;height:32px;color:",f.textMuted,";background:transparent;border:none;border-radius:6px;cursor:pointer;transition:all 0.15s ease;&:hover{color:",f.text,";background:",f.surface,";}",""),headerActions:{name:"1yydxi7",styles:"display:flex;align-items:center;gap:8px"},headerBtn:b("height:",Hg,";padding:0 12px;background:",f.surface,";border:1px solid ",f.border,";border-radius:6px;cursor:pointer;transition:all 0.15s ease;display:flex;align-items:center;justify-content:center;&:hover{background-color:",f.surfaceHover,";border-color:",f.borderHover,";}",""),headerIcon:b("width:16px;height:16px;color:",f.textSecondary,";",""),content:{name:"1rtaly3",styles:"flex:1;display:flex;overflow:hidden"},fileBrowser:{name:"upomw9",styles:"flex:1;min-width:0;overflow:auto;padding:20px 24px;display:flex;flex-direction:column"},dropOverlay:b("position:absolute;top:0;left:0;right:0;bottom:0;background:rgba(99, 91, 255, 0.1);border:3px dashed ",f.primary,";border-radius:8px;display:flex;align-items:center;justify-content:center;z-index:50;pointer-events:none;",""),dropMessage:b("display:flex;flex-direction:column;align-items:center;gap:12px;color:",f.primary,";font-size:",K.lg,";font-weight:600;",""),dropIcon:{name:"18jhpep",styles:"width:48px;height:48px"}};function Ng({onClose:o,isVisible:s=!0,standaloneMode:h=!1,workspacePath:u,siteUrl:g}){const p=o||(()=>{}),[k,U]=M.useState("public"),[D,S]=M.useState(new Set),[Y,B]=M.useState(null),[W,$]=M.useState("grid"),[V,q]=M.useState(null),[de,I]=M.useState(null),[ue,le]=M.useState(!1),[re,_]=M.useState(0),[X,j]=M.useState(!1),[ge,He]=M.useState(""),[_e,Ne]=M.useState(null),[Le,We]=M.useState([]),[Ie,ze]=M.useState(!1),A=M.useCallback(()=>{_(Me=>Me+1)},[]),G=M.useCallback(()=>{j(!0)},[]),P=M.useCallback(()=>{j(!1)},[]),pe=M.useCallback((Me,St)=>{Ne({title:Me,message:St})},[]),ke=M.useCallback(()=>{Ne(null)},[]),y=M.useCallback(Me=>{Me.preventDefault(),Me.stopPropagation(),ze(!0)},[]),L=M.useCallback(Me=>{Me.preventDefault(),Me.stopPropagation(),ze(!1)},[]),O=M.useCallback(async Me=>{Me.preventDefault(),Me.stopPropagation(),ze(!1);const St=Array.from(Me.dataTransfer.files);if(St.length!==0&&!(k==="public/images"||k.startsWith("public/images/"))){for(const At of St){const Et=new FormData;Et.append("file",At),Et.append("path",k);try{await fetch("/api/studio/upload",{method:"POST",body:Et})}catch(al){console.error("Upload error:",al)}}A()}},[k,A]),Z=M.useCallback(()=>{if(k==="public")return;const Me=k.split("/");Me.pop(),U(Me.join("/")||"public"),S(new Set)},[k]),ee=M.useCallback(Me=>{U(Me),S(new Set),q(null)},[]),Ce=M.useCallback(Me=>{S(St=>{const At=new Set(St);return At.has(Me)?At.delete(Me):At.add(Me),At}),B(Me)},[]),Ue=M.useCallback((Me,St,At)=>{const Et=At.findIndex(gl=>gl.path===Me),al=At.findIndex(gl=>gl.path===St);if(Et===-1||al===-1)return;const ml=Math.min(Et,al),_l=Math.max(Et,al);S(gl=>{const Jn=new Set(gl);for(let Mn=ml;Mn<=_l;Mn++)Jn.add(At[Mn].path);return Jn}),B(St)},[]),ht=M.useCallback(Me=>{S(new Set(Me.map(St=>St.path)))},[]),Ke=M.useCallback(()=>{S(new Set)},[]),nl=M.useCallback(Me=>{q(Me)},[]),te=Ug({triggerRefresh:A,clearSelection:Ke,setFocusedItem:nl,showError:pe}),Kt=M.useCallback(Me=>{if(Me.key==="Escape"){const St=Me.target;if(St.tagName==="INPUT"||St.tagName==="TEXTAREA")return;V?q(null):h||p()}},[p,V,h]);M.useEffect(()=>(s&&(document.addEventListener("keydown",Kt),document.body.style.overflow="hidden"),()=>{document.removeEventListener("keydown",Kt),document.body.style.overflow=""}),[Kt,s]);const wn={isOpen:!0,openStudio:()=>{},closeStudio:p,toggleStudio:p,currentPath:k,setCurrentPath:ee,navigateUp:Z,selectedItems:D,toggleSelection:Ce,selectRange:Ue,selectAll:ht,clearSelection:Ke,lastSelectedPath:Y,viewMode:W,setViewMode:$,focusedItem:V,setFocusedItem:q,meta:de,setMeta:I,isLoading:ue,setIsLoading:le,refreshKey:re,triggerRefresh:A,scanRequested:X,triggerScan:G,clearScanRequest:P,searchQuery:ge,setSearchQuery:He,error:_e,showError:pe,clearError:ke,fileItems:Le,setFileItems:We,actionState:te.actionState,requestDelete:te.requestDelete,requestMove:te.requestMove,requestSync:te.requestSync,requestProcess:te.requestProcess,setProcessMode:te.setProcessMode,confirmDelete:te.confirmDelete,confirmMove:te.confirmMove,confirmSync:te.confirmSync,confirmProcess:te.confirmProcess,cancelAction:te.cancelAction,closeProgress:te.closeProgress,stopProcessing:te.stopProcessing,abortController:te.abortController,deleteOrphans:te.deleteOrphans};return c(Ch.Provider,{value:wn,children:x("div",{css:Mt.container,children:[x("div",{css:Mt.header,children:[c("div",{css:Mt.headerLeft,children:c("h1",{css:Mt.title,children:"Studio"})}),c("div",{css:Mt.headerCenter,children:c(Gg,{currentPath:k,onNavigate:ee,projectName:u?u.split("/").pop():void 0})}),x("div",{css:Mt.headerActions,children:[g&&c("a",{href:g,target:"_blank",rel:"noopener noreferrer",css:Mt.headerIconBtn,title:`Open ${g}`,children:c(Vg,{})}),c(Dg,{}),!h&&c("button",{css:Mt.headerBtn,onClick:p,"aria-label":"Close Studio",children:c(Xg,{})})]})]}),c(tg,{}),x("div",{css:Mt.content,onDragOver:y,onDragLeave:L,onDrop:O,children:[Ie&&c("div",{css:Mt.dropOverlay,children:x("div",{css:Mt.dropMessage,children:[c("svg",{css:Mt.dropIcon,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:c("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M4 16v1a3 3 0 003 3h10a3 3 0 003-3v-1m-4-8l-4-4m0 0L8 8m4-4v12"})}),c("span",{children:"Drop files to upload"})]})}),c("div",{css:Mt.fileBrowser,children:W==="grid"?c(yg,{}):c(Sg,{})})]}),V&&c(Eg,{}),c(Lg,{}),te.actionState.showDeleteConfirm&&c(Ri,{title:"Delete Files",message:`Are you sure you want to delete ${te.actionState.actionPaths.length} item${te.actionState.actionPaths.length!==1?"s":""}? This action cannot be undone.`,confirmLabel:"Delete",variant:"danger",onConfirm:te.confirmDelete,onCancel:te.cancelAction}),te.actionState.showSyncConfirm&&c(Ri,{title:"Push to CDN",message:`Push ${te.actionState.syncImageCount} image${te.actionState.syncImageCount!==1?"s":""} to Cloudflare R2?${te.actionState.syncHasRemote?" Remote images will be downloaded first.":""}${te.actionState.syncHasLocal?" After pushing, local files will be deleted.":""}`,confirmLabel:"Push",onConfirm:te.confirmSync,onCancel:te.cancelAction}),te.actionState.showProcessConfirm&&c(Yg,{imageCount:te.actionState.actionPaths.length,mode:te.actionState.processMode,onModeChange:te.setProcessMode,onConfirm:te.confirmProcess,onCancel:te.cancelAction}),te.actionState.showMoveModal&&c(wh,{selectedItems:new Set(te.actionState.actionPaths),currentPath:k,onMove:Me=>te.confirmMove(Me),onCancel:te.cancelAction}),te.actionState.showProgress&&c(Js,{title:te.actionState.progressTitle,progress:te.actionState.progressState,onStop:te.stopProcessing,onDeleteOrphans:te.deleteOrphans,onClose:te.closeProgress})]})})}var Bg={name:"1cm5yut",styles:"display:flex;gap:12px;justify-content:flex-end"},jg={name:"yr7p8l",styles:"display:flex;gap:8px;margin-bottom:16px"},qg={name:"1ca3l8d",styles:"position:fixed;inset:0;background:rgba(0, 0, 0, 0.5);display:flex;align-items:center;justify-content:center;z-index:10000"};function Yg({imageCount:o,mode:s,onModeChange:h,onConfirm:u,onCancel:g}){const p={overlay:qg,container:b("background:",f.surface,";border-radius:12px;padding:24px;max-width:420px;width:90%;box-shadow:0 20px 25px -5px rgba(0, 0, 0, 0.1),0 10px 10px -5px rgba(0, 0, 0, 0.04);",""),title:b("font-size:",K.lg,";font-weight:600;color:",f.text,";margin:0 0 16px;",""),modeToggle:jg,modeBtn:b("flex:1;padding:10px 16px;border:2px solid ",f.border,";border-radius:8px;background:",f.background,";color:",f.textSecondary,";font-size:",K.base,";font-weight:500;cursor:pointer;transition:all 0.15s ease;&:hover{border-color:",f.borderHover,";}",""),modeBtnActive:b("border-color:",f.primary,";background:rgba(99, 91, 255, 0.1);color:",f.primary,";",""),modeBtnDanger:b("border-color:",f.danger,";background:rgba(239, 68, 68, 0.1);color:",f.danger,";",""),message:b("font-size:",K.base,";color:",f.textSecondary,";margin:0 0 20px;line-height:1.5;",""),actions:Bg,cancelBtn:b("padding:10px 20px;border:1px solid ",f.border,";border-radius:8px;background:",f.background,";color:",f.text,";font-size:",K.base,";font-weight:500;cursor:pointer;transition:all 0.15s ease;&:hover{background:",f.surfaceHover,";border-color:",f.borderHover,";}",""),confirmBtn:b("padding:10px 20px;border:none;border-radius:8px;background:",f.primary,";color:white;font-size:",K.base,";font-weight:500;cursor:pointer;transition:all 0.15s ease;&:hover{background:",f.primaryHover,";}",""),confirmBtnDanger:b("background:",f.danger,";&:hover{background:#dc2626;}","")},k=s==="remove",U="Process Images",D=k?`Remove generated thumbnails for ${o} image${o!==1?"s":""}? Original images will be kept.`:`Generate thumbnails for ${o} image${o!==1?"s":""}?`,S=k?"Remove":"Process";return c("div",{css:p.overlay,onClick:g,children:x("div",{css:p.container,onClick:Y=>Y.stopPropagation(),children:[c("h2",{css:p.title,children:U}),x("div",{css:p.modeToggle,children:[c("button",{css:[p.modeBtn,s==="generate"&&p.modeBtnActive,"",""],onClick:()=>h("generate"),children:"Generate Thumbnails"}),c("button",{css:[p.modeBtn,s==="remove"&&p.modeBtnDanger,"",""],onClick:()=>h("remove"),children:"Remove Thumbnails"})]}),c("p",{css:p.message,children:D}),x("div",{css:p.actions,children:[c("button",{css:p.cancelBtn,onClick:g,children:"Cancel"}),c("button",{css:[p.confirmBtn,k&&p.confirmBtnDanger,"",""],onClick:u,children:S})]})]})})}function Gg({currentPath:o,onNavigate:s,projectName:h}){const u=o.split("/").filter(Boolean),g=u.map((p,k)=>({name:k===0&&p==="public"&&h?h:p,path:u.slice(0,k+1).join("/")}));return c("div",{css:Mt.breadcrumbs,children:g.map((p,k)=>x("span",{style:{display:"flex",alignItems:"center",gap:6},children:[k>0&&c("span",{css:Mt.breadcrumbSeparator,children:"/"}),k===g.length-1?c("span",{css:Mt.breadcrumbCurrent,children:p.name}):c("span",{css:Mt.breadcrumbItem,onClick:()=>s(p.path),children:p.name})]},p.path))})}function Vg(){return x("svg",{width:"18",height:"18",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round",children:[c("circle",{cx:"12",cy:"12",r:"10"}),c("line",{x1:"2",y1:"12",x2:"22",y2:"12"}),c("path",{d:"M12 2a15.3 15.3 0 0 1 4 10 15.3 15.3 0 0 1-4 10 15.3 15.3 0 0 1-4-10 15.3 15.3 0 0 1 4-10z"})]})}function Xg(){return x("svg",{css:Mt.headerIcon,xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round",children:[c("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),c("line",{x1:"6",y1:"6",x2:"18",y2:"18"})]})}const Ah=document.getElementById("root");if(!Ah)throw new Error("Root element not found");const Qg=window.__STUDIO_WORKSPACE__||"Unknown",Zg=window.__STUDIO_SITE_URL__||"";G1.createRoot(Ah).render(c(M.StrictMode,{children:c("div",{style:{position:"fixed",top:0,left:0,right:0,bottom:0,background:"#0a0a0a"},children:c(Ng,{isVisible:!0,standaloneMode:!0,workspacePath:Qg,siteUrl:Zg})})}));
|