better-auth-studio 1.0.14-beta.1 → 1.0.15

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,341 +0,0 @@
1
- function wp(e,t){for(var r=0;r<t.length;r++){const s=t[r];if(typeof s!="string"&&!Array.isArray(s)){for(const a in s)if(a!=="default"&&!(a in e)){const i=Object.getOwnPropertyDescriptor(s,a);i&&Object.defineProperty(e,a,i.get?i:{enumerable:!0,get:()=>s[a]})}}}return Object.freeze(Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}))}(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const a of document.querySelectorAll('link[rel="modulepreload"]'))s(a);new MutationObserver(a=>{for(const i of a)if(i.type==="childList")for(const l of i.addedNodes)l.tagName==="LINK"&&l.rel==="modulepreload"&&s(l)}).observe(document,{childList:!0,subtree:!0});function r(a){const i={};return a.integrity&&(i.integrity=a.integrity),a.referrerPolicy&&(i.referrerPolicy=a.referrerPolicy),a.crossOrigin==="use-credentials"?i.credentials="include":a.crossOrigin==="anonymous"?i.credentials="omit":i.credentials="same-origin",i}function s(a){if(a.ep)return;a.ep=!0;const i=r(a);fetch(a.href,i)}})();function Qu(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Yu={exports:{}},_i={},Gu={exports:{}},le={};/**
2
- * @license React
3
- * react.production.min.js
4
- *
5
- * Copyright (c) Facebook, Inc. and its affiliates.
6
- *
7
- * This source code is licensed under the MIT license found in the
8
- * LICENSE file in the root directory of this source tree.
9
- */var ma=Symbol.for("react.element"),bp=Symbol.for("react.portal"),jp=Symbol.for("react.fragment"),Np=Symbol.for("react.strict_mode"),kp=Symbol.for("react.profiler"),Sp=Symbol.for("react.provider"),Cp=Symbol.for("react.context"),Ep=Symbol.for("react.forward_ref"),Tp=Symbol.for("react.suspense"),Pp=Symbol.for("react.memo"),zp=Symbol.for("react.lazy"),sd=Symbol.iterator;function Dp(e){return e===null||typeof e!="object"?null:(e=sd&&e[sd]||e["@@iterator"],typeof e=="function"?e:null)}var Xu={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},Ju=Object.assign,Zu={};function hs(e,t,r){this.props=e,this.context=t,this.refs=Zu,this.updater=r||Xu}hs.prototype.isReactComponent={};hs.prototype.setState=function(e,t){if(typeof e!="object"&&typeof e!="function"&&e!=null)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,e,t,"setState")};hs.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function qu(){}qu.prototype=hs.prototype;function Go(e,t,r){this.props=e,this.context=t,this.refs=Zu,this.updater=r||Xu}var Xo=Go.prototype=new qu;Xo.constructor=Go;Ju(Xo,hs.prototype);Xo.isPureReactComponent=!0;var ad=Array.isArray,eh=Object.prototype.hasOwnProperty,Jo={current:null},th={key:!0,ref:!0,__self:!0,__source:!0};function rh(e,t,r){var s,a={},i=null,l=null;if(t!=null)for(s in t.ref!==void 0&&(l=t.ref),t.key!==void 0&&(i=""+t.key),t)eh.call(t,s)&&!th.hasOwnProperty(s)&&(a[s]=t[s]);var o=arguments.length-2;if(o===1)a.children=r;else if(1<o){for(var c=Array(o),d=0;d<o;d++)c[d]=arguments[d+2];a.children=c}if(e&&e.defaultProps)for(s in o=e.defaultProps,o)a[s]===void 0&&(a[s]=o[s]);return{$$typeof:ma,type:e,key:i,ref:l,props:a,_owner:Jo.current}}function Mp(e,t){return{$$typeof:ma,type:e.type,key:t,ref:e.ref,props:e.props,_owner:e._owner}}function Zo(e){return typeof e=="object"&&e!==null&&e.$$typeof===ma}function Rp(e){var t={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,function(r){return t[r]})}var id=/\/+/g;function il(e,t){return typeof e=="object"&&e!==null&&e.key!=null?Rp(""+e.key):t.toString(36)}function Ya(e,t,r,s,a){var i=typeof e;(i==="undefined"||i==="boolean")&&(e=null);var l=!1;if(e===null)l=!0;else switch(i){case"string":case"number":l=!0;break;case"object":switch(e.$$typeof){case ma:case bp:l=!0}}if(l)return l=e,a=a(l),e=s===""?"."+il(l,0):s,ad(a)?(r="",e!=null&&(r=e.replace(id,"$&/")+"/"),Ya(a,t,r,"",function(d){return d})):a!=null&&(Zo(a)&&(a=Mp(a,r+(!a.key||l&&l.key===a.key?"":(""+a.key).replace(id,"$&/")+"/")+e)),t.push(a)),1;if(l=0,s=s===""?".":s+":",ad(e))for(var o=0;o<e.length;o++){i=e[o];var c=s+il(i,o);l+=Ya(i,t,r,c,a)}else if(c=Dp(e),typeof c=="function")for(e=c.call(e),o=0;!(i=e.next()).done;)i=i.value,c=s+il(i,o++),l+=Ya(i,t,r,c,a);else if(i==="object")throw t=String(e),Error("Objects are not valid as a React child (found: "+(t==="[object Object]"?"object with keys {"+Object.keys(e).join(", ")+"}":t)+"). If you meant to render a collection of children, use an array instead.");return l}function Sa(e,t,r){if(e==null)return e;var s=[],a=0;return Ya(e,s,"","",function(i){return t.call(r,i,a++)}),s}function Ip(e){if(e._status===-1){var t=e._result;t=t(),t.then(function(r){(e._status===0||e._status===-1)&&(e._status=1,e._result=r)},function(r){(e._status===0||e._status===-1)&&(e._status=2,e._result=r)}),e._status===-1&&(e._status=0,e._result=t)}if(e._status===1)return e._result.default;throw e._result}var at={current:null},Ga={transition:null},Lp={ReactCurrentDispatcher:at,ReactCurrentBatchConfig:Ga,ReactCurrentOwner:Jo};function nh(){throw Error("act(...) is not supported in production builds of React.")}le.Children={map:Sa,forEach:function(e,t,r){Sa(e,function(){t.apply(this,arguments)},r)},count:function(e){var t=0;return Sa(e,function(){t++}),t},toArray:function(e){return Sa(e,function(t){return t})||[]},only:function(e){if(!Zo(e))throw Error("React.Children.only expected to receive a single React element child.");return e}};le.Component=hs;le.Fragment=jp;le.Profiler=kp;le.PureComponent=Go;le.StrictMode=Np;le.Suspense=Tp;le.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=Lp;le.act=nh;le.cloneElement=function(e,t,r){if(e==null)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+e+".");var s=Ju({},e.props),a=e.key,i=e.ref,l=e._owner;if(t!=null){if(t.ref!==void 0&&(i=t.ref,l=Jo.current),t.key!==void 0&&(a=""+t.key),e.type&&e.type.defaultProps)var o=e.type.defaultProps;for(c in t)eh.call(t,c)&&!th.hasOwnProperty(c)&&(s[c]=t[c]===void 0&&o!==void 0?o[c]:t[c])}var c=arguments.length-2;if(c===1)s.children=r;else if(1<c){o=Array(c);for(var d=0;d<c;d++)o[d]=arguments[d+2];s.children=o}return{$$typeof:ma,type:e.type,key:a,ref:i,props:s,_owner:l}};le.createContext=function(e){return e={$$typeof:Cp,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null},e.Provider={$$typeof:Sp,_context:e},e.Consumer=e};le.createElement=rh;le.createFactory=function(e){var t=rh.bind(null,e);return t.type=e,t};le.createRef=function(){return{current:null}};le.forwardRef=function(e){return{$$typeof:Ep,render:e}};le.isValidElement=Zo;le.lazy=function(e){return{$$typeof:zp,_payload:{_status:-1,_result:e},_init:Ip}};le.memo=function(e,t){return{$$typeof:Pp,type:e,compare:t===void 0?null:t}};le.startTransition=function(e){var t=Ga.transition;Ga.transition={};try{e()}finally{Ga.transition=t}};le.unstable_act=nh;le.useCallback=function(e,t){return at.current.useCallback(e,t)};le.useContext=function(e){return at.current.useContext(e)};le.useDebugValue=function(){};le.useDeferredValue=function(e){return at.current.useDeferredValue(e)};le.useEffect=function(e,t){return at.current.useEffect(e,t)};le.useId=function(){return at.current.useId()};le.useImperativeHandle=function(e,t,r){return at.current.useImperativeHandle(e,t,r)};le.useInsertionEffect=function(e,t){return at.current.useInsertionEffect(e,t)};le.useLayoutEffect=function(e,t){return at.current.useLayoutEffect(e,t)};le.useMemo=function(e,t){return at.current.useMemo(e,t)};le.useReducer=function(e,t,r){return at.current.useReducer(e,t,r)};le.useRef=function(e){return at.current.useRef(e)};le.useState=function(e){return at.current.useState(e)};le.useSyncExternalStore=function(e,t,r){return at.current.useSyncExternalStore(e,t,r)};le.useTransition=function(){return at.current.useTransition()};le.version="18.3.1";Gu.exports=le;var h=Gu.exports;const U=Qu(h),qo=wp({__proto__:null,default:U},[h]);/**
10
- * @license React
11
- * react-jsx-runtime.production.min.js
12
- *
13
- * Copyright (c) Facebook, Inc. and its affiliates.
14
- *
15
- * This source code is licensed under the MIT license found in the
16
- * LICENSE file in the root directory of this source tree.
17
- */var _p=h,Op=Symbol.for("react.element"),Ap=Symbol.for("react.fragment"),$p=Object.prototype.hasOwnProperty,Fp=_p.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,Up={key:!0,ref:!0,__self:!0,__source:!0};function sh(e,t,r){var s,a={},i=null,l=null;r!==void 0&&(i=""+r),t.key!==void 0&&(i=""+t.key),t.ref!==void 0&&(l=t.ref);for(s in t)$p.call(t,s)&&!Up.hasOwnProperty(s)&&(a[s]=t[s]);if(e&&e.defaultProps)for(s in t=e.defaultProps,t)a[s]===void 0&&(a[s]=t[s]);return{$$typeof:Op,type:e,key:i,ref:l,props:a,_owner:Fp.current}}_i.Fragment=Ap;_i.jsx=sh;_i.jsxs=sh;Yu.exports=_i;var n=Yu.exports,Hl={},ah={exports:{}},wt={},ih={exports:{}},lh={};/**
18
- * @license React
19
- * scheduler.production.min.js
20
- *
21
- * Copyright (c) Facebook, Inc. and its affiliates.
22
- *
23
- * This source code is licensed under the MIT license found in the
24
- * LICENSE file in the root directory of this source tree.
25
- */(function(e){function t(k,A){var _=k.length;k.push(A);e:for(;0<_;){var W=_-1>>>1,E=k[W];if(0<a(E,A))k[W]=A,k[_]=E,_=W;else break e}}function r(k){return k.length===0?null:k[0]}function s(k){if(k.length===0)return null;var A=k[0],_=k.pop();if(_!==A){k[0]=_;e:for(var W=0,E=k.length,z=E>>>1;W<z;){var M=2*(W+1)-1,L=k[M],R=M+1,X=k[R];if(0>a(L,_))R<E&&0>a(X,L)?(k[W]=X,k[R]=_,W=R):(k[W]=L,k[M]=_,W=M);else if(R<E&&0>a(X,_))k[W]=X,k[R]=_,W=R;else break e}}return A}function a(k,A){var _=k.sortIndex-A.sortIndex;return _!==0?_:k.id-A.id}if(typeof performance=="object"&&typeof performance.now=="function"){var i=performance;e.unstable_now=function(){return i.now()}}else{var l=Date,o=l.now();e.unstable_now=function(){return l.now()-o}}var c=[],d=[],f=1,u=null,x=3,y=!1,w=!1,v=!1,b=typeof setTimeout=="function"?setTimeout:null,m=typeof clearTimeout=="function"?clearTimeout:null,p=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function g(k){for(var A=r(d);A!==null;){if(A.callback===null)s(d);else if(A.startTime<=k)s(d),A.sortIndex=A.expirationTime,t(c,A);else break;A=r(d)}}function j(k){if(v=!1,g(k),!w)if(r(c)!==null)w=!0,D(S);else{var A=r(d);A!==null&&H(j,A.startTime-k)}}function S(k,A){w=!1,v&&(v=!1,m(O),O=-1),y=!0;var _=x;try{for(g(A),u=r(c);u!==null&&(!(u.expirationTime>A)||k&&!J());){var W=u.callback;if(typeof W=="function"){u.callback=null,x=u.priorityLevel;var E=W(u.expirationTime<=A);A=e.unstable_now(),typeof E=="function"?u.callback=E:u===r(c)&&s(c),g(A)}else s(c);u=r(c)}if(u!==null)var z=!0;else{var M=r(d);M!==null&&H(j,M.startTime-A),z=!1}return z}finally{u=null,x=_,y=!1}}var N=!1,C=null,O=-1,G=5,V=-1;function J(){return!(e.unstable_now()-V<G)}function B(){if(C!==null){var k=e.unstable_now();V=k;var A=!0;try{A=C(!0,k)}finally{A?se():(N=!1,C=null)}}else N=!1}var se;if(typeof p=="function")se=function(){p(B)};else if(typeof MessageChannel<"u"){var ee=new MessageChannel,ie=ee.port2;ee.port1.onmessage=B,se=function(){ie.postMessage(null)}}else se=function(){b(B,0)};function D(k){C=k,N||(N=!0,se())}function H(k,A){O=b(function(){k(e.unstable_now())},A)}e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(k){k.callback=null},e.unstable_continueExecution=function(){w||y||(w=!0,D(S))},e.unstable_forceFrameRate=function(k){0>k||125<k?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):G=0<k?Math.floor(1e3/k):5},e.unstable_getCurrentPriorityLevel=function(){return x},e.unstable_getFirstCallbackNode=function(){return r(c)},e.unstable_next=function(k){switch(x){case 1:case 2:case 3:var A=3;break;default:A=x}var _=x;x=A;try{return k()}finally{x=_}},e.unstable_pauseExecution=function(){},e.unstable_requestPaint=function(){},e.unstable_runWithPriority=function(k,A){switch(k){case 1:case 2:case 3:case 4:case 5:break;default:k=3}var _=x;x=k;try{return A()}finally{x=_}},e.unstable_scheduleCallback=function(k,A,_){var W=e.unstable_now();switch(typeof _=="object"&&_!==null?(_=_.delay,_=typeof _=="number"&&0<_?W+_:W):_=W,k){case 1:var E=-1;break;case 2:E=250;break;case 5:E=1073741823;break;case 4:E=1e4;break;default:E=5e3}return E=_+E,k={id:f++,callback:A,priorityLevel:k,startTime:_,expirationTime:E,sortIndex:-1},_>W?(k.sortIndex=_,t(d,k),r(c)===null&&k===r(d)&&(v?(m(O),O=-1):v=!0,H(j,_-W))):(k.sortIndex=E,t(c,k),w||y||(w=!0,D(S))),k},e.unstable_shouldYield=J,e.unstable_wrapCallback=function(k){var A=x;return function(){var _=x;x=A;try{return k.apply(this,arguments)}finally{x=_}}}})(lh);ih.exports=lh;var Bp=ih.exports;/**
26
- * @license React
27
- * react-dom.production.min.js
28
- *
29
- * Copyright (c) Facebook, Inc. and its affiliates.
30
- *
31
- * This source code is licensed under the MIT license found in the
32
- * LICENSE file in the root directory of this source tree.
33
- */var Vp=h,yt=Bp;function $(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,r=1;r<arguments.length;r++)t+="&args[]="+encodeURIComponent(arguments[r]);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."}var oh=new Set,Ks={};function yn(e,t){es(e,t),es(e+"Capture",t)}function es(e,t){for(Ks[e]=t,e=0;e<t.length;e++)oh.add(t[e])}var mr=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),Kl=Object.prototype.hasOwnProperty,Wp=/^[: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]*$/,ld={},od={};function Hp(e){return Kl.call(od,e)?!0:Kl.call(ld,e)?!1:Wp.test(e)?od[e]=!0:(ld[e]=!0,!1)}function Kp(e,t,r,s){if(r!==null&&r.type===0)return!1;switch(typeof t){case"function":case"symbol":return!0;case"boolean":return s?!1:r!==null?!r.acceptsBooleans:(e=e.toLowerCase().slice(0,5),e!=="data-"&&e!=="aria-");default:return!1}}function Qp(e,t,r,s){if(t===null||typeof t>"u"||Kp(e,t,r,s))return!0;if(s)return!1;if(r!==null)switch(r.type){case 3:return!t;case 4:return t===!1;case 5:return isNaN(t);case 6:return isNaN(t)||1>t}return!1}function it(e,t,r,s,a,i,l){this.acceptsBooleans=t===2||t===3||t===4,this.attributeName=s,this.attributeNamespace=a,this.mustUseProperty=r,this.propertyName=e,this.type=t,this.sanitizeURL=i,this.removeEmptyString=l}var Ke={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){Ke[e]=new it(e,0,!1,e,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];Ke[t]=new it(t,1,!1,e[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(e){Ke[e]=new it(e,2,!1,e.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){Ke[e]=new it(e,2,!1,e,null,!1,!1)});"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(e){Ke[e]=new it(e,3,!1,e.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(e){Ke[e]=new it(e,3,!0,e,null,!1,!1)});["capture","download"].forEach(function(e){Ke[e]=new it(e,4,!1,e,null,!1,!1)});["cols","rows","size","span"].forEach(function(e){Ke[e]=new it(e,6,!1,e,null,!1,!1)});["rowSpan","start"].forEach(function(e){Ke[e]=new it(e,5,!1,e.toLowerCase(),null,!1,!1)});var ec=/[\-:]([a-z])/g;function tc(e){return e[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(e){var t=e.replace(ec,tc);Ke[t]=new it(t,1,!1,e,null,!1,!1)});"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(e){var t=e.replace(ec,tc);Ke[t]=new it(t,1,!1,e,"http://www.w3.org/1999/xlink",!1,!1)});["xml:base","xml:lang","xml:space"].forEach(function(e){var t=e.replace(ec,tc);Ke[t]=new it(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(e){Ke[e]=new it(e,1,!1,e.toLowerCase(),null,!1,!1)});Ke.xlinkHref=new it("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(e){Ke[e]=new it(e,1,!1,e.toLowerCase(),null,!0,!0)});function rc(e,t,r,s){var a=Ke.hasOwnProperty(t)?Ke[t]:null;(a!==null?a.type!==0:s||!(2<t.length)||t[0]!=="o"&&t[0]!=="O"||t[1]!=="n"&&t[1]!=="N")&&(Qp(t,r,a,s)&&(r=null),s||a===null?Hp(t)&&(r===null?e.removeAttribute(t):e.setAttribute(t,""+r)):a.mustUseProperty?e[a.propertyName]=r===null?a.type===3?!1:"":r:(t=a.attributeName,s=a.attributeNamespace,r===null?e.removeAttribute(t):(a=a.type,r=a===3||a===4&&r===!0?"":""+r,s?e.setAttributeNS(s,t,r):e.setAttribute(t,r))))}var vr=Vp.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,Ca=Symbol.for("react.element"),Dn=Symbol.for("react.portal"),Mn=Symbol.for("react.fragment"),nc=Symbol.for("react.strict_mode"),Ql=Symbol.for("react.profiler"),ch=Symbol.for("react.provider"),dh=Symbol.for("react.context"),sc=Symbol.for("react.forward_ref"),Yl=Symbol.for("react.suspense"),Gl=Symbol.for("react.suspense_list"),ac=Symbol.for("react.memo"),Cr=Symbol.for("react.lazy"),uh=Symbol.for("react.offscreen"),cd=Symbol.iterator;function ys(e){return e===null||typeof e!="object"?null:(e=cd&&e[cd]||e["@@iterator"],typeof e=="function"?e:null)}var Ee=Object.assign,ll;function Ms(e){if(ll===void 0)try{throw Error()}catch(r){var t=r.stack.trim().match(/\n( *(at )?)/);ll=t&&t[1]||""}return`
34
- `+ll+e}var ol=!1;function cl(e,t){if(!e||ol)return"";ol=!0;var r=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{if(t)if(t=function(){throw Error()},Object.defineProperty(t.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(t,[])}catch(d){var s=d}Reflect.construct(e,[],t)}else{try{t.call()}catch(d){s=d}e.call(t.prototype)}else{try{throw Error()}catch(d){s=d}e()}}catch(d){if(d&&s&&typeof d.stack=="string"){for(var a=d.stack.split(`
35
- `),i=s.stack.split(`
36
- `),l=a.length-1,o=i.length-1;1<=l&&0<=o&&a[l]!==i[o];)o--;for(;1<=l&&0<=o;l--,o--)if(a[l]!==i[o]){if(l!==1||o!==1)do if(l--,o--,0>o||a[l]!==i[o]){var c=`
37
- `+a[l].replace(" at new "," at ");return e.displayName&&c.includes("<anonymous>")&&(c=c.replace("<anonymous>",e.displayName)),c}while(1<=l&&0<=o);break}}}finally{ol=!1,Error.prepareStackTrace=r}return(e=e?e.displayName||e.name:"")?Ms(e):""}function Yp(e){switch(e.tag){case 5:return Ms(e.type);case 16:return Ms("Lazy");case 13:return Ms("Suspense");case 19:return Ms("SuspenseList");case 0:case 2:case 15:return e=cl(e.type,!1),e;case 11:return e=cl(e.type.render,!1),e;case 1:return e=cl(e.type,!0),e;default:return""}}function Xl(e){if(e==null)return null;if(typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case Mn:return"Fragment";case Dn:return"Portal";case Ql:return"Profiler";case nc:return"StrictMode";case Yl:return"Suspense";case Gl:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case dh:return(e.displayName||"Context")+".Consumer";case ch:return(e._context.displayName||"Context")+".Provider";case sc:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case ac:return t=e.displayName||null,t!==null?t:Xl(e.type)||"Memo";case Cr:t=e._payload,e=e._init;try{return Xl(e(t))}catch{}}return null}function Gp(e){var t=e.type;switch(e.tag){case 24:return"Cache";case 9:return(t.displayName||"Context")+".Consumer";case 10:return(t._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return e=t.render,e=e.displayName||e.name||"",t.displayName||(e!==""?"ForwardRef("+e+")":"ForwardRef");case 7:return"Fragment";case 5:return t;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return Xl(t);case 8:return t===nc?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof t=="function")return t.displayName||t.name||null;if(typeof t=="string")return t}return null}function Wr(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function hh(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function Xp(e){var t=hh(e)?"checked":"value",r=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),s=""+e[t];if(!e.hasOwnProperty(t)&&typeof r<"u"&&typeof r.get=="function"&&typeof r.set=="function"){var a=r.get,i=r.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return a.call(this)},set:function(l){s=""+l,i.call(this,l)}}),Object.defineProperty(e,t,{enumerable:r.enumerable}),{getValue:function(){return s},setValue:function(l){s=""+l},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function Ea(e){e._valueTracker||(e._valueTracker=Xp(e))}function fh(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var r=t.getValue(),s="";return e&&(s=hh(e)?e.checked?"true":"false":e.value),e=s,e!==r?(t.setValue(e),!0):!1}function ci(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}}function Jl(e,t){var r=t.checked;return Ee({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:r??e._wrapperState.initialChecked})}function dd(e,t){var r=t.defaultValue==null?"":t.defaultValue,s=t.checked!=null?t.checked:t.defaultChecked;r=Wr(t.value!=null?t.value:r),e._wrapperState={initialChecked:s,initialValue:r,controlled:t.type==="checkbox"||t.type==="radio"?t.checked!=null:t.value!=null}}function mh(e,t){t=t.checked,t!=null&&rc(e,"checked",t,!1)}function Zl(e,t){mh(e,t);var r=Wr(t.value),s=t.type;if(r!=null)s==="number"?(r===0&&e.value===""||e.value!=r)&&(e.value=""+r):e.value!==""+r&&(e.value=""+r);else if(s==="submit"||s==="reset"){e.removeAttribute("value");return}t.hasOwnProperty("value")?ql(e,t.type,r):t.hasOwnProperty("defaultValue")&&ql(e,t.type,Wr(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function ud(e,t,r){if(t.hasOwnProperty("value")||t.hasOwnProperty("defaultValue")){var s=t.type;if(!(s!=="submit"&&s!=="reset"||t.value!==void 0&&t.value!==null))return;t=""+e._wrapperState.initialValue,r||t===e.value||(e.value=t),e.defaultValue=t}r=e.name,r!==""&&(e.name=""),e.defaultChecked=!!e._wrapperState.initialChecked,r!==""&&(e.name=r)}function ql(e,t,r){(t!=="number"||ci(e.ownerDocument)!==e)&&(r==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+r&&(e.defaultValue=""+r))}var Rs=Array.isArray;function Wn(e,t,r,s){if(e=e.options,t){t={};for(var a=0;a<r.length;a++)t["$"+r[a]]=!0;for(r=0;r<e.length;r++)a=t.hasOwnProperty("$"+e[r].value),e[r].selected!==a&&(e[r].selected=a),a&&s&&(e[r].defaultSelected=!0)}else{for(r=""+Wr(r),t=null,a=0;a<e.length;a++){if(e[a].value===r){e[a].selected=!0,s&&(e[a].defaultSelected=!0);return}t!==null||e[a].disabled||(t=e[a])}t!==null&&(t.selected=!0)}}function eo(e,t){if(t.dangerouslySetInnerHTML!=null)throw Error($(91));return Ee({},t,{value:void 0,defaultValue:void 0,children:""+e._wrapperState.initialValue})}function hd(e,t){var r=t.value;if(r==null){if(r=t.children,t=t.defaultValue,r!=null){if(t!=null)throw Error($(92));if(Rs(r)){if(1<r.length)throw Error($(93));r=r[0]}t=r}t==null&&(t=""),r=t}e._wrapperState={initialValue:Wr(r)}}function ph(e,t){var r=Wr(t.value),s=Wr(t.defaultValue);r!=null&&(r=""+r,r!==e.value&&(e.value=r),t.defaultValue==null&&e.defaultValue!==r&&(e.defaultValue=r)),s!=null&&(e.defaultValue=""+s)}function fd(e){var t=e.textContent;t===e._wrapperState.initialValue&&t!==""&&t!==null&&(e.value=t)}function xh(e){switch(e){case"svg":return"http://www.w3.org/2000/svg";case"math":return"http://www.w3.org/1998/Math/MathML";default:return"http://www.w3.org/1999/xhtml"}}function to(e,t){return e==null||e==="http://www.w3.org/1999/xhtml"?xh(t):e==="http://www.w3.org/2000/svg"&&t==="foreignObject"?"http://www.w3.org/1999/xhtml":e}var Ta,gh=function(e){return typeof MSApp<"u"&&MSApp.execUnsafeLocalFunction?function(t,r,s,a){MSApp.execUnsafeLocalFunction(function(){return e(t,r,s,a)})}:e}(function(e,t){if(e.namespaceURI!=="http://www.w3.org/2000/svg"||"innerHTML"in e)e.innerHTML=t;else{for(Ta=Ta||document.createElement("div"),Ta.innerHTML="<svg>"+t.valueOf().toString()+"</svg>",t=Ta.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function Qs(e,t){if(t){var r=e.firstChild;if(r&&r===e.lastChild&&r.nodeType===3){r.nodeValue=t;return}}e.textContent=t}var Os={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},Jp=["Webkit","ms","Moz","O"];Object.keys(Os).forEach(function(e){Jp.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),Os[t]=Os[e]})});function vh(e,t,r){return t==null||typeof t=="boolean"||t===""?"":r||typeof t!="number"||t===0||Os.hasOwnProperty(e)&&Os[e]?(""+t).trim():t+"px"}function yh(e,t){e=e.style;for(var r in t)if(t.hasOwnProperty(r)){var s=r.indexOf("--")===0,a=vh(r,t[r],s);r==="float"&&(r="cssFloat"),s?e.setProperty(r,a):e[r]=a}}var Zp=Ee({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function ro(e,t){if(t){if(Zp[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error($(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error($(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error($(61))}if(t.style!=null&&typeof t.style!="object")throw Error($(62))}}function no(e,t){if(e.indexOf("-")===-1)return typeof t.is=="string";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 so=null;function ic(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var ao=null,Hn=null,Kn=null;function md(e){if(e=ga(e)){if(typeof ao!="function")throw Error($(280));var t=e.stateNode;t&&(t=Ui(t),ao(e.stateNode,e.type,t))}}function wh(e){Hn?Kn?Kn.push(e):Kn=[e]:Hn=e}function bh(){if(Hn){var e=Hn,t=Kn;if(Kn=Hn=null,md(e),t)for(e=0;e<t.length;e++)md(t[e])}}function jh(e,t){return e(t)}function Nh(){}var dl=!1;function kh(e,t,r){if(dl)return e(t,r);dl=!0;try{return jh(e,t,r)}finally{dl=!1,(Hn!==null||Kn!==null)&&(Nh(),bh())}}function Ys(e,t){var r=e.stateNode;if(r===null)return null;var s=Ui(r);if(s===null)return null;r=s[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":(s=!s.disabled)||(e=e.type,s=!(e==="button"||e==="input"||e==="select"||e==="textarea")),e=!s;break e;default:e=!1}if(e)return null;if(r&&typeof r!="function")throw Error($(231,t,typeof r));return r}var io=!1;if(mr)try{var ws={};Object.defineProperty(ws,"passive",{get:function(){io=!0}}),window.addEventListener("test",ws,ws),window.removeEventListener("test",ws,ws)}catch{io=!1}function qp(e,t,r,s,a,i,l,o,c){var d=Array.prototype.slice.call(arguments,3);try{t.apply(r,d)}catch(f){this.onError(f)}}var As=!1,di=null,ui=!1,lo=null,ex={onError:function(e){As=!0,di=e}};function tx(e,t,r,s,a,i,l,o,c){As=!1,di=null,qp.apply(ex,arguments)}function rx(e,t,r,s,a,i,l,o,c){if(tx.apply(this,arguments),As){if(As){var d=di;As=!1,di=null}else throw Error($(198));ui||(ui=!0,lo=d)}}function wn(e){var t=e,r=e;if(e.alternate)for(;t.return;)t=t.return;else{e=t;do t=e,t.flags&4098&&(r=t.return),e=t.return;while(e)}return t.tag===3?r:null}function Sh(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 pd(e){if(wn(e)!==e)throw Error($(188))}function nx(e){var t=e.alternate;if(!t){if(t=wn(e),t===null)throw Error($(188));return t!==e?null:e}for(var r=e,s=t;;){var a=r.return;if(a===null)break;var i=a.alternate;if(i===null){if(s=a.return,s!==null){r=s;continue}break}if(a.child===i.child){for(i=a.child;i;){if(i===r)return pd(a),e;if(i===s)return pd(a),t;i=i.sibling}throw Error($(188))}if(r.return!==s.return)r=a,s=i;else{for(var l=!1,o=a.child;o;){if(o===r){l=!0,r=a,s=i;break}if(o===s){l=!0,s=a,r=i;break}o=o.sibling}if(!l){for(o=i.child;o;){if(o===r){l=!0,r=i,s=a;break}if(o===s){l=!0,s=i,r=a;break}o=o.sibling}if(!l)throw Error($(189))}}if(r.alternate!==s)throw Error($(190))}if(r.tag!==3)throw Error($(188));return r.stateNode.current===r?e:t}function Ch(e){return e=nx(e),e!==null?Eh(e):null}function Eh(e){if(e.tag===5||e.tag===6)return e;for(e=e.child;e!==null;){var t=Eh(e);if(t!==null)return t;e=e.sibling}return null}var Th=yt.unstable_scheduleCallback,xd=yt.unstable_cancelCallback,sx=yt.unstable_shouldYield,ax=yt.unstable_requestPaint,De=yt.unstable_now,ix=yt.unstable_getCurrentPriorityLevel,lc=yt.unstable_ImmediatePriority,Ph=yt.unstable_UserBlockingPriority,hi=yt.unstable_NormalPriority,lx=yt.unstable_LowPriority,zh=yt.unstable_IdlePriority,Oi=null,er=null;function ox(e){if(er&&typeof er.onCommitFiberRoot=="function")try{er.onCommitFiberRoot(Oi,e,void 0,(e.current.flags&128)===128)}catch{}}var At=Math.clz32?Math.clz32:ux,cx=Math.log,dx=Math.LN2;function ux(e){return e>>>=0,e===0?32:31-(cx(e)/dx|0)|0}var Pa=64,za=4194304;function Is(e){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: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 e&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return e&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return e}}function fi(e,t){var r=e.pendingLanes;if(r===0)return 0;var s=0,a=e.suspendedLanes,i=e.pingedLanes,l=r&268435455;if(l!==0){var o=l&~a;o!==0?s=Is(o):(i&=l,i!==0&&(s=Is(i)))}else l=r&~a,l!==0?s=Is(l):i!==0&&(s=Is(i));if(s===0)return 0;if(t!==0&&t!==s&&!(t&a)&&(a=s&-s,i=t&-t,a>=i||a===16&&(i&4194240)!==0))return t;if(s&4&&(s|=r&16),t=e.entangledLanes,t!==0)for(e=e.entanglements,t&=s;0<t;)r=31-At(t),a=1<<r,s|=e[r],t&=~a;return s}function hx(e,t){switch(e){case 1:case 2:case 4:return t+250;case 8:case 16:case 32:case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t+5e3;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return-1;case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function fx(e,t){for(var r=e.suspendedLanes,s=e.pingedLanes,a=e.expirationTimes,i=e.pendingLanes;0<i;){var l=31-At(i),o=1<<l,c=a[l];c===-1?(!(o&r)||o&s)&&(a[l]=hx(o,t)):c<=t&&(e.expiredLanes|=o),i&=~o}}function oo(e){return e=e.pendingLanes&-1073741825,e!==0?e:e&1073741824?1073741824:0}function Dh(){var e=Pa;return Pa<<=1,!(Pa&4194240)&&(Pa=64),e}function ul(e){for(var t=[],r=0;31>r;r++)t.push(e);return t}function pa(e,t,r){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-At(t),e[t]=r}function mx(e,t){var r=e.pendingLanes&~t;e.pendingLanes=t,e.suspendedLanes=0,e.pingedLanes=0,e.expiredLanes&=t,e.mutableReadLanes&=t,e.entangledLanes&=t,t=e.entanglements;var s=e.eventTimes;for(e=e.expirationTimes;0<r;){var a=31-At(r),i=1<<a;t[a]=0,s[a]=-1,e[a]=-1,r&=~i}}function oc(e,t){var r=e.entangledLanes|=t;for(e=e.entanglements;r;){var s=31-At(r),a=1<<s;a&t|e[s]&t&&(e[s]|=t),r&=~a}}var fe=0;function Mh(e){return e&=-e,1<e?4<e?e&268435455?16:536870912:4:1}var Rh,cc,Ih,Lh,_h,co=!1,Da=[],Rr=null,Ir=null,Lr=null,Gs=new Map,Xs=new Map,Tr=[],px="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset submit".split(" ");function gd(e,t){switch(e){case"focusin":case"focusout":Rr=null;break;case"dragenter":case"dragleave":Ir=null;break;case"mouseover":case"mouseout":Lr=null;break;case"pointerover":case"pointerout":Gs.delete(t.pointerId);break;case"gotpointercapture":case"lostpointercapture":Xs.delete(t.pointerId)}}function bs(e,t,r,s,a,i){return e===null||e.nativeEvent!==i?(e={blockedOn:t,domEventName:r,eventSystemFlags:s,nativeEvent:i,targetContainers:[a]},t!==null&&(t=ga(t),t!==null&&cc(t)),e):(e.eventSystemFlags|=s,t=e.targetContainers,a!==null&&t.indexOf(a)===-1&&t.push(a),e)}function xx(e,t,r,s,a){switch(t){case"focusin":return Rr=bs(Rr,e,t,r,s,a),!0;case"dragenter":return Ir=bs(Ir,e,t,r,s,a),!0;case"mouseover":return Lr=bs(Lr,e,t,r,s,a),!0;case"pointerover":var i=a.pointerId;return Gs.set(i,bs(Gs.get(i)||null,e,t,r,s,a)),!0;case"gotpointercapture":return i=a.pointerId,Xs.set(i,bs(Xs.get(i)||null,e,t,r,s,a)),!0}return!1}function Oh(e){var t=nn(e.target);if(t!==null){var r=wn(t);if(r!==null){if(t=r.tag,t===13){if(t=Sh(r),t!==null){e.blockedOn=t,_h(e.priority,function(){Ih(r)});return}}else if(t===3&&r.stateNode.current.memoizedState.isDehydrated){e.blockedOn=r.tag===3?r.stateNode.containerInfo:null;return}}}e.blockedOn=null}function Xa(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var r=uo(e.domEventName,e.eventSystemFlags,t[0],e.nativeEvent);if(r===null){r=e.nativeEvent;var s=new r.constructor(r.type,r);so=s,r.target.dispatchEvent(s),so=null}else return t=ga(r),t!==null&&cc(t),e.blockedOn=r,!1;t.shift()}return!0}function vd(e,t,r){Xa(e)&&r.delete(t)}function gx(){co=!1,Rr!==null&&Xa(Rr)&&(Rr=null),Ir!==null&&Xa(Ir)&&(Ir=null),Lr!==null&&Xa(Lr)&&(Lr=null),Gs.forEach(vd),Xs.forEach(vd)}function js(e,t){e.blockedOn===t&&(e.blockedOn=null,co||(co=!0,yt.unstable_scheduleCallback(yt.unstable_NormalPriority,gx)))}function Js(e){function t(a){return js(a,e)}if(0<Da.length){js(Da[0],e);for(var r=1;r<Da.length;r++){var s=Da[r];s.blockedOn===e&&(s.blockedOn=null)}}for(Rr!==null&&js(Rr,e),Ir!==null&&js(Ir,e),Lr!==null&&js(Lr,e),Gs.forEach(t),Xs.forEach(t),r=0;r<Tr.length;r++)s=Tr[r],s.blockedOn===e&&(s.blockedOn=null);for(;0<Tr.length&&(r=Tr[0],r.blockedOn===null);)Oh(r),r.blockedOn===null&&Tr.shift()}var Qn=vr.ReactCurrentBatchConfig,mi=!0;function vx(e,t,r,s){var a=fe,i=Qn.transition;Qn.transition=null;try{fe=1,dc(e,t,r,s)}finally{fe=a,Qn.transition=i}}function yx(e,t,r,s){var a=fe,i=Qn.transition;Qn.transition=null;try{fe=4,dc(e,t,r,s)}finally{fe=a,Qn.transition=i}}function dc(e,t,r,s){if(mi){var a=uo(e,t,r,s);if(a===null)bl(e,t,s,pi,r),gd(e,s);else if(xx(a,e,t,r,s))s.stopPropagation();else if(gd(e,s),t&4&&-1<px.indexOf(e)){for(;a!==null;){var i=ga(a);if(i!==null&&Rh(i),i=uo(e,t,r,s),i===null&&bl(e,t,s,pi,r),i===a)break;a=i}a!==null&&s.stopPropagation()}else bl(e,t,s,null,r)}}var pi=null;function uo(e,t,r,s){if(pi=null,e=ic(s),e=nn(e),e!==null)if(t=wn(e),t===null)e=null;else if(r=t.tag,r===13){if(e=Sh(t),e!==null)return e;e=null}else if(r===3){if(t.stateNode.current.memoizedState.isDehydrated)return t.tag===3?t.stateNode.containerInfo:null;e=null}else t!==e&&(e=null);return pi=e,null}function Ah(e){switch(e){case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"resize":case"seeked":case"submit":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 1;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"toggle":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 4;case"message":switch(ix()){case lc:return 1;case Ph:return 4;case hi:case lx:return 16;case zh:return 536870912;default:return 16}default:return 16}}var zr=null,uc=null,Ja=null;function $h(){if(Ja)return Ja;var e,t=uc,r=t.length,s,a="value"in zr?zr.value:zr.textContent,i=a.length;for(e=0;e<r&&t[e]===a[e];e++);var l=r-e;for(s=1;s<=l&&t[r-s]===a[i-s];s++);return Ja=a.slice(e,1<s?1-s:void 0)}function Za(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 Ma(){return!0}function yd(){return!1}function bt(e){function t(r,s,a,i,l){this._reactName=r,this._targetInst=a,this.type=s,this.nativeEvent=i,this.target=l,this.currentTarget=null;for(var o in e)e.hasOwnProperty(o)&&(r=e[o],this[o]=r?r(i):i[o]);return this.isDefaultPrevented=(i.defaultPrevented!=null?i.defaultPrevented:i.returnValue===!1)?Ma:yd,this.isPropagationStopped=yd,this}return Ee(t.prototype,{preventDefault:function(){this.defaultPrevented=!0;var r=this.nativeEvent;r&&(r.preventDefault?r.preventDefault():typeof r.returnValue!="unknown"&&(r.returnValue=!1),this.isDefaultPrevented=Ma)},stopPropagation:function(){var r=this.nativeEvent;r&&(r.stopPropagation?r.stopPropagation():typeof r.cancelBubble!="unknown"&&(r.cancelBubble=!0),this.isPropagationStopped=Ma)},persist:function(){},isPersistent:Ma}),t}var fs={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},hc=bt(fs),xa=Ee({},fs,{view:0,detail:0}),wx=bt(xa),hl,fl,Ns,Ai=Ee({},xa,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:fc,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!==Ns&&(Ns&&e.type==="mousemove"?(hl=e.screenX-Ns.screenX,fl=e.screenY-Ns.screenY):fl=hl=0,Ns=e),hl)},movementY:function(e){return"movementY"in e?e.movementY:fl}}),wd=bt(Ai),bx=Ee({},Ai,{dataTransfer:0}),jx=bt(bx),Nx=Ee({},xa,{relatedTarget:0}),ml=bt(Nx),kx=Ee({},fs,{animationName:0,elapsedTime:0,pseudoElement:0}),Sx=bt(kx),Cx=Ee({},fs,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),Ex=bt(Cx),Tx=Ee({},fs,{data:0}),bd=bt(Tx),Px={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},zx={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"},Dx={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function Mx(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=Dx[e])?!!t[e]:!1}function fc(){return Mx}var Rx=Ee({},xa,{key:function(e){if(e.key){var t=Px[e.key]||e.key;if(t!=="Unidentified")return t}return e.type==="keypress"?(e=Za(e),e===13?"Enter":String.fromCharCode(e)):e.type==="keydown"||e.type==="keyup"?zx[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:fc,charCode:function(e){return e.type==="keypress"?Za(e):0},keyCode:function(e){return e.type==="keydown"||e.type==="keyup"?e.keyCode:0},which:function(e){return e.type==="keypress"?Za(e):e.type==="keydown"||e.type==="keyup"?e.keyCode:0}}),Ix=bt(Rx),Lx=Ee({},Ai,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),jd=bt(Lx),_x=Ee({},xa,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:fc}),Ox=bt(_x),Ax=Ee({},fs,{propertyName:0,elapsedTime:0,pseudoElement:0}),$x=bt(Ax),Fx=Ee({},Ai,{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}),Ux=bt(Fx),Bx=[9,13,27,32],mc=mr&&"CompositionEvent"in window,$s=null;mr&&"documentMode"in document&&($s=document.documentMode);var Vx=mr&&"TextEvent"in window&&!$s,Fh=mr&&(!mc||$s&&8<$s&&11>=$s),Nd=" ",kd=!1;function Uh(e,t){switch(e){case"keyup":return Bx.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function Bh(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var Rn=!1;function Wx(e,t){switch(e){case"compositionend":return Bh(t);case"keypress":return t.which!==32?null:(kd=!0,Nd);case"textInput":return e=t.data,e===Nd&&kd?null:e;default:return null}}function Hx(e,t){if(Rn)return e==="compositionend"||!mc&&Uh(e,t)?(e=$h(),Ja=uc=zr=null,Rn=!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 Fh&&t.locale!=="ko"?null:t.data;default:return null}}var Kx={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 Sd(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t==="input"?!!Kx[e.type]:t==="textarea"}function Vh(e,t,r,s){wh(s),t=xi(t,"onChange"),0<t.length&&(r=new hc("onChange","change",null,r,s),e.push({event:r,listeners:t}))}var Fs=null,Zs=null;function Qx(e){ef(e,0)}function $i(e){var t=_n(e);if(fh(t))return e}function Yx(e,t){if(e==="change")return t}var Wh=!1;if(mr){var pl;if(mr){var xl="oninput"in document;if(!xl){var Cd=document.createElement("div");Cd.setAttribute("oninput","return;"),xl=typeof Cd.oninput=="function"}pl=xl}else pl=!1;Wh=pl&&(!document.documentMode||9<document.documentMode)}function Ed(){Fs&&(Fs.detachEvent("onpropertychange",Hh),Zs=Fs=null)}function Hh(e){if(e.propertyName==="value"&&$i(Zs)){var t=[];Vh(t,Zs,e,ic(e)),kh(Qx,t)}}function Gx(e,t,r){e==="focusin"?(Ed(),Fs=t,Zs=r,Fs.attachEvent("onpropertychange",Hh)):e==="focusout"&&Ed()}function Xx(e){if(e==="selectionchange"||e==="keyup"||e==="keydown")return $i(Zs)}function Jx(e,t){if(e==="click")return $i(t)}function Zx(e,t){if(e==="input"||e==="change")return $i(t)}function qx(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var Ft=typeof Object.is=="function"?Object.is:qx;function qs(e,t){if(Ft(e,t))return!0;if(typeof e!="object"||e===null||typeof t!="object"||t===null)return!1;var r=Object.keys(e),s=Object.keys(t);if(r.length!==s.length)return!1;for(s=0;s<r.length;s++){var a=r[s];if(!Kl.call(t,a)||!Ft(e[a],t[a]))return!1}return!0}function Td(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function Pd(e,t){var r=Td(e);e=0;for(var s;r;){if(r.nodeType===3){if(s=e+r.textContent.length,e<=t&&s>=t)return{node:r,offset:t-e};e=s}e:{for(;r;){if(r.nextSibling){r=r.nextSibling;break e}r=r.parentNode}r=void 0}r=Td(r)}}function Kh(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?Kh(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function Qh(){for(var e=window,t=ci();t instanceof e.HTMLIFrameElement;){try{var r=typeof t.contentWindow.location.href=="string"}catch{r=!1}if(r)e=t.contentWindow;else break;t=ci(e.document)}return t}function pc(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")}function eg(e){var t=Qh(),r=e.focusedElem,s=e.selectionRange;if(t!==r&&r&&r.ownerDocument&&Kh(r.ownerDocument.documentElement,r)){if(s!==null&&pc(r)){if(t=s.start,e=s.end,e===void 0&&(e=t),"selectionStart"in r)r.selectionStart=t,r.selectionEnd=Math.min(e,r.value.length);else if(e=(t=r.ownerDocument||document)&&t.defaultView||window,e.getSelection){e=e.getSelection();var a=r.textContent.length,i=Math.min(s.start,a);s=s.end===void 0?i:Math.min(s.end,a),!e.extend&&i>s&&(a=s,s=i,i=a),a=Pd(r,i);var l=Pd(r,s);a&&l&&(e.rangeCount!==1||e.anchorNode!==a.node||e.anchorOffset!==a.offset||e.focusNode!==l.node||e.focusOffset!==l.offset)&&(t=t.createRange(),t.setStart(a.node,a.offset),e.removeAllRanges(),i>s?(e.addRange(t),e.extend(l.node,l.offset)):(t.setEnd(l.node,l.offset),e.addRange(t)))}}for(t=[],e=r;e=e.parentNode;)e.nodeType===1&&t.push({element:e,left:e.scrollLeft,top:e.scrollTop});for(typeof r.focus=="function"&&r.focus(),r=0;r<t.length;r++)e=t[r],e.element.scrollLeft=e.left,e.element.scrollTop=e.top}}var tg=mr&&"documentMode"in document&&11>=document.documentMode,In=null,ho=null,Us=null,fo=!1;function zd(e,t,r){var s=r.window===r?r.document:r.nodeType===9?r:r.ownerDocument;fo||In==null||In!==ci(s)||(s=In,"selectionStart"in s&&pc(s)?s={start:s.selectionStart,end:s.selectionEnd}:(s=(s.ownerDocument&&s.ownerDocument.defaultView||window).getSelection(),s={anchorNode:s.anchorNode,anchorOffset:s.anchorOffset,focusNode:s.focusNode,focusOffset:s.focusOffset}),Us&&qs(Us,s)||(Us=s,s=xi(ho,"onSelect"),0<s.length&&(t=new hc("onSelect","select",null,t,r),e.push({event:t,listeners:s}),t.target=In)))}function Ra(e,t){var r={};return r[e.toLowerCase()]=t.toLowerCase(),r["Webkit"+e]="webkit"+t,r["Moz"+e]="moz"+t,r}var Ln={animationend:Ra("Animation","AnimationEnd"),animationiteration:Ra("Animation","AnimationIteration"),animationstart:Ra("Animation","AnimationStart"),transitionend:Ra("Transition","TransitionEnd")},gl={},Yh={};mr&&(Yh=document.createElement("div").style,"AnimationEvent"in window||(delete Ln.animationend.animation,delete Ln.animationiteration.animation,delete Ln.animationstart.animation),"TransitionEvent"in window||delete Ln.transitionend.transition);function Fi(e){if(gl[e])return gl[e];if(!Ln[e])return e;var t=Ln[e],r;for(r in t)if(t.hasOwnProperty(r)&&r in Yh)return gl[e]=t[r];return e}var Gh=Fi("animationend"),Xh=Fi("animationiteration"),Jh=Fi("animationstart"),Zh=Fi("transitionend"),qh=new Map,Dd="abort auxClick cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel".split(" ");function Qr(e,t){qh.set(e,t),yn(t,[e])}for(var vl=0;vl<Dd.length;vl++){var yl=Dd[vl],rg=yl.toLowerCase(),ng=yl[0].toUpperCase()+yl.slice(1);Qr(rg,"on"+ng)}Qr(Gh,"onAnimationEnd");Qr(Xh,"onAnimationIteration");Qr(Jh,"onAnimationStart");Qr("dblclick","onDoubleClick");Qr("focusin","onFocus");Qr("focusout","onBlur");Qr(Zh,"onTransitionEnd");es("onMouseEnter",["mouseout","mouseover"]);es("onMouseLeave",["mouseout","mouseover"]);es("onPointerEnter",["pointerout","pointerover"]);es("onPointerLeave",["pointerout","pointerover"]);yn("onChange","change click focusin focusout input keydown keyup selectionchange".split(" "));yn("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" "));yn("onBeforeInput",["compositionend","keypress","textInput","paste"]);yn("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" "));yn("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" "));yn("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Ls="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(" "),sg=new Set("cancel close invalid load scroll toggle".split(" ").concat(Ls));function Md(e,t,r){var s=e.type||"unknown-event";e.currentTarget=r,rx(s,t,void 0,e),e.currentTarget=null}function ef(e,t){t=(t&4)!==0;for(var r=0;r<e.length;r++){var s=e[r],a=s.event;s=s.listeners;e:{var i=void 0;if(t)for(var l=s.length-1;0<=l;l--){var o=s[l],c=o.instance,d=o.currentTarget;if(o=o.listener,c!==i&&a.isPropagationStopped())break e;Md(a,o,d),i=c}else for(l=0;l<s.length;l++){if(o=s[l],c=o.instance,d=o.currentTarget,o=o.listener,c!==i&&a.isPropagationStopped())break e;Md(a,o,d),i=c}}}if(ui)throw e=lo,ui=!1,lo=null,e}function ye(e,t){var r=t[vo];r===void 0&&(r=t[vo]=new Set);var s=e+"__bubble";r.has(s)||(tf(t,e,2,!1),r.add(s))}function wl(e,t,r){var s=0;t&&(s|=4),tf(r,e,s,t)}var Ia="_reactListening"+Math.random().toString(36).slice(2);function ea(e){if(!e[Ia]){e[Ia]=!0,oh.forEach(function(r){r!=="selectionchange"&&(sg.has(r)||wl(r,!1,e),wl(r,!0,e))});var t=e.nodeType===9?e:e.ownerDocument;t===null||t[Ia]||(t[Ia]=!0,wl("selectionchange",!1,t))}}function tf(e,t,r,s){switch(Ah(t)){case 1:var a=vx;break;case 4:a=yx;break;default:a=dc}r=a.bind(null,t,r,e),a=void 0,!io||t!=="touchstart"&&t!=="touchmove"&&t!=="wheel"||(a=!0),s?a!==void 0?e.addEventListener(t,r,{capture:!0,passive:a}):e.addEventListener(t,r,!0):a!==void 0?e.addEventListener(t,r,{passive:a}):e.addEventListener(t,r,!1)}function bl(e,t,r,s,a){var i=s;if(!(t&1)&&!(t&2)&&s!==null)e:for(;;){if(s===null)return;var l=s.tag;if(l===3||l===4){var o=s.stateNode.containerInfo;if(o===a||o.nodeType===8&&o.parentNode===a)break;if(l===4)for(l=s.return;l!==null;){var c=l.tag;if((c===3||c===4)&&(c=l.stateNode.containerInfo,c===a||c.nodeType===8&&c.parentNode===a))return;l=l.return}for(;o!==null;){if(l=nn(o),l===null)return;if(c=l.tag,c===5||c===6){s=i=l;continue e}o=o.parentNode}}s=s.return}kh(function(){var d=i,f=ic(r),u=[];e:{var x=qh.get(e);if(x!==void 0){var y=hc,w=e;switch(e){case"keypress":if(Za(r)===0)break e;case"keydown":case"keyup":y=Ix;break;case"focusin":w="focus",y=ml;break;case"focusout":w="blur",y=ml;break;case"beforeblur":case"afterblur":y=ml;break;case"click":if(r.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":y=wd;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":y=jx;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":y=Ox;break;case Gh:case Xh:case Jh:y=Sx;break;case Zh:y=$x;break;case"scroll":y=wx;break;case"wheel":y=Ux;break;case"copy":case"cut":case"paste":y=Ex;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":y=jd}var v=(t&4)!==0,b=!v&&e==="scroll",m=v?x!==null?x+"Capture":null:x;v=[];for(var p=d,g;p!==null;){g=p;var j=g.stateNode;if(g.tag===5&&j!==null&&(g=j,m!==null&&(j=Ys(p,m),j!=null&&v.push(ta(p,j,g)))),b)break;p=p.return}0<v.length&&(x=new y(x,w,null,r,f),u.push({event:x,listeners:v}))}}if(!(t&7)){e:{if(x=e==="mouseover"||e==="pointerover",y=e==="mouseout"||e==="pointerout",x&&r!==so&&(w=r.relatedTarget||r.fromElement)&&(nn(w)||w[pr]))break e;if((y||x)&&(x=f.window===f?f:(x=f.ownerDocument)?x.defaultView||x.parentWindow:window,y?(w=r.relatedTarget||r.toElement,y=d,w=w?nn(w):null,w!==null&&(b=wn(w),w!==b||w.tag!==5&&w.tag!==6)&&(w=null)):(y=null,w=d),y!==w)){if(v=wd,j="onMouseLeave",m="onMouseEnter",p="mouse",(e==="pointerout"||e==="pointerover")&&(v=jd,j="onPointerLeave",m="onPointerEnter",p="pointer"),b=y==null?x:_n(y),g=w==null?x:_n(w),x=new v(j,p+"leave",y,r,f),x.target=b,x.relatedTarget=g,j=null,nn(f)===d&&(v=new v(m,p+"enter",w,r,f),v.target=g,v.relatedTarget=b,j=v),b=j,y&&w)t:{for(v=y,m=w,p=0,g=v;g;g=kn(g))p++;for(g=0,j=m;j;j=kn(j))g++;for(;0<p-g;)v=kn(v),p--;for(;0<g-p;)m=kn(m),g--;for(;p--;){if(v===m||m!==null&&v===m.alternate)break t;v=kn(v),m=kn(m)}v=null}else v=null;y!==null&&Rd(u,x,y,v,!1),w!==null&&b!==null&&Rd(u,b,w,v,!0)}}e:{if(x=d?_n(d):window,y=x.nodeName&&x.nodeName.toLowerCase(),y==="select"||y==="input"&&x.type==="file")var S=Yx;else if(Sd(x))if(Wh)S=Zx;else{S=Xx;var N=Gx}else(y=x.nodeName)&&y.toLowerCase()==="input"&&(x.type==="checkbox"||x.type==="radio")&&(S=Jx);if(S&&(S=S(e,d))){Vh(u,S,r,f);break e}N&&N(e,x,d),e==="focusout"&&(N=x._wrapperState)&&N.controlled&&x.type==="number"&&ql(x,"number",x.value)}switch(N=d?_n(d):window,e){case"focusin":(Sd(N)||N.contentEditable==="true")&&(In=N,ho=d,Us=null);break;case"focusout":Us=ho=In=null;break;case"mousedown":fo=!0;break;case"contextmenu":case"mouseup":case"dragend":fo=!1,zd(u,r,f);break;case"selectionchange":if(tg)break;case"keydown":case"keyup":zd(u,r,f)}var C;if(mc)e:{switch(e){case"compositionstart":var O="onCompositionStart";break e;case"compositionend":O="onCompositionEnd";break e;case"compositionupdate":O="onCompositionUpdate";break e}O=void 0}else Rn?Uh(e,r)&&(O="onCompositionEnd"):e==="keydown"&&r.keyCode===229&&(O="onCompositionStart");O&&(Fh&&r.locale!=="ko"&&(Rn||O!=="onCompositionStart"?O==="onCompositionEnd"&&Rn&&(C=$h()):(zr=f,uc="value"in zr?zr.value:zr.textContent,Rn=!0)),N=xi(d,O),0<N.length&&(O=new bd(O,e,null,r,f),u.push({event:O,listeners:N}),C?O.data=C:(C=Bh(r),C!==null&&(O.data=C)))),(C=Vx?Wx(e,r):Hx(e,r))&&(d=xi(d,"onBeforeInput"),0<d.length&&(f=new bd("onBeforeInput","beforeinput",null,r,f),u.push({event:f,listeners:d}),f.data=C))}ef(u,t)})}function ta(e,t,r){return{instance:e,listener:t,currentTarget:r}}function xi(e,t){for(var r=t+"Capture",s=[];e!==null;){var a=e,i=a.stateNode;a.tag===5&&i!==null&&(a=i,i=Ys(e,r),i!=null&&s.unshift(ta(e,i,a)),i=Ys(e,t),i!=null&&s.push(ta(e,i,a))),e=e.return}return s}function kn(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5);return e||null}function Rd(e,t,r,s,a){for(var i=t._reactName,l=[];r!==null&&r!==s;){var o=r,c=o.alternate,d=o.stateNode;if(c!==null&&c===s)break;o.tag===5&&d!==null&&(o=d,a?(c=Ys(r,i),c!=null&&l.unshift(ta(r,c,o))):a||(c=Ys(r,i),c!=null&&l.push(ta(r,c,o)))),r=r.return}l.length!==0&&e.push({event:t,listeners:l})}var ag=/\r\n?/g,ig=/\u0000|\uFFFD/g;function Id(e){return(typeof e=="string"?e:""+e).replace(ag,`
38
- `).replace(ig,"")}function La(e,t,r){if(t=Id(t),Id(e)!==t&&r)throw Error($(425))}function gi(){}var mo=null,po=null;function xo(e,t){return e==="textarea"||e==="noscript"||typeof t.children=="string"||typeof t.children=="number"||typeof t.dangerouslySetInnerHTML=="object"&&t.dangerouslySetInnerHTML!==null&&t.dangerouslySetInnerHTML.__html!=null}var go=typeof setTimeout=="function"?setTimeout:void 0,lg=typeof clearTimeout=="function"?clearTimeout:void 0,Ld=typeof Promise=="function"?Promise:void 0,og=typeof queueMicrotask=="function"?queueMicrotask:typeof Ld<"u"?function(e){return Ld.resolve(null).then(e).catch(cg)}:go;function cg(e){setTimeout(function(){throw e})}function jl(e,t){var r=t,s=0;do{var a=r.nextSibling;if(e.removeChild(r),a&&a.nodeType===8)if(r=a.data,r==="/$"){if(s===0){e.removeChild(a),Js(t);return}s--}else r!=="$"&&r!=="$?"&&r!=="$!"||s++;r=a}while(r);Js(t)}function _r(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==="$?")break;if(t==="/$")return null}}return e}function _d(e){e=e.previousSibling;for(var t=0;e;){if(e.nodeType===8){var r=e.data;if(r==="$"||r==="$!"||r==="$?"){if(t===0)return e;t--}else r==="/$"&&t++}e=e.previousSibling}return null}var ms=Math.random().toString(36).slice(2),Zt="__reactFiber$"+ms,ra="__reactProps$"+ms,pr="__reactContainer$"+ms,vo="__reactEvents$"+ms,dg="__reactListeners$"+ms,ug="__reactHandles$"+ms;function nn(e){var t=e[Zt];if(t)return t;for(var r=e.parentNode;r;){if(t=r[pr]||r[Zt]){if(r=t.alternate,t.child!==null||r!==null&&r.child!==null)for(e=_d(e);e!==null;){if(r=e[Zt])return r;e=_d(e)}return t}e=r,r=e.parentNode}return null}function ga(e){return e=e[Zt]||e[pr],!e||e.tag!==5&&e.tag!==6&&e.tag!==13&&e.tag!==3?null:e}function _n(e){if(e.tag===5||e.tag===6)return e.stateNode;throw Error($(33))}function Ui(e){return e[ra]||null}var yo=[],On=-1;function Yr(e){return{current:e}}function be(e){0>On||(e.current=yo[On],yo[On]=null,On--)}function ge(e,t){On++,yo[On]=e.current,e.current=t}var Hr={},tt=Yr(Hr),ht=Yr(!1),dn=Hr;function ts(e,t){var r=e.type.contextTypes;if(!r)return Hr;var s=e.stateNode;if(s&&s.__reactInternalMemoizedUnmaskedChildContext===t)return s.__reactInternalMemoizedMaskedChildContext;var a={},i;for(i in r)a[i]=t[i];return s&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=a),a}function ft(e){return e=e.childContextTypes,e!=null}function vi(){be(ht),be(tt)}function Od(e,t,r){if(tt.current!==Hr)throw Error($(168));ge(tt,t),ge(ht,r)}function rf(e,t,r){var s=e.stateNode;if(t=t.childContextTypes,typeof s.getChildContext!="function")return r;s=s.getChildContext();for(var a in s)if(!(a in t))throw Error($(108,Gp(e)||"Unknown",a));return Ee({},r,s)}function yi(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||Hr,dn=tt.current,ge(tt,e),ge(ht,ht.current),!0}function Ad(e,t,r){var s=e.stateNode;if(!s)throw Error($(169));r?(e=rf(e,t,dn),s.__reactInternalMemoizedMergedChildContext=e,be(ht),be(tt),ge(tt,e)):be(ht),ge(ht,r)}var cr=null,Bi=!1,Nl=!1;function nf(e){cr===null?cr=[e]:cr.push(e)}function hg(e){Bi=!0,nf(e)}function Gr(){if(!Nl&&cr!==null){Nl=!0;var e=0,t=fe;try{var r=cr;for(fe=1;e<r.length;e++){var s=r[e];do s=s(!0);while(s!==null)}cr=null,Bi=!1}catch(a){throw cr!==null&&(cr=cr.slice(e+1)),Th(lc,Gr),a}finally{fe=t,Nl=!1}}return null}var An=[],$n=0,wi=null,bi=0,kt=[],St=0,un=null,dr=1,ur="";function qr(e,t){An[$n++]=bi,An[$n++]=wi,wi=e,bi=t}function sf(e,t,r){kt[St++]=dr,kt[St++]=ur,kt[St++]=un,un=e;var s=dr;e=ur;var a=32-At(s)-1;s&=~(1<<a),r+=1;var i=32-At(t)+a;if(30<i){var l=a-a%5;i=(s&(1<<l)-1).toString(32),s>>=l,a-=l,dr=1<<32-At(t)+a|r<<a|s,ur=i+e}else dr=1<<i|r<<a|s,ur=e}function xc(e){e.return!==null&&(qr(e,1),sf(e,1,0))}function gc(e){for(;e===wi;)wi=An[--$n],An[$n]=null,bi=An[--$n],An[$n]=null;for(;e===un;)un=kt[--St],kt[St]=null,ur=kt[--St],kt[St]=null,dr=kt[--St],kt[St]=null}var vt=null,gt=null,je=!1,Ot=null;function af(e,t){var r=Ct(5,null,null,0);r.elementType="DELETED",r.stateNode=t,r.return=e,t=e.deletions,t===null?(e.deletions=[r],e.flags|=16):t.push(r)}function $d(e,t){switch(e.tag){case 5:var r=e.type;return t=t.nodeType!==1||r.toLowerCase()!==t.nodeName.toLowerCase()?null:t,t!==null?(e.stateNode=t,vt=e,gt=_r(t.firstChild),!0):!1;case 6:return t=e.pendingProps===""||t.nodeType!==3?null:t,t!==null?(e.stateNode=t,vt=e,gt=null,!0):!1;case 13:return t=t.nodeType!==8?null:t,t!==null?(r=un!==null?{id:dr,overflow:ur}:null,e.memoizedState={dehydrated:t,treeContext:r,retryLane:1073741824},r=Ct(18,null,null,0),r.stateNode=t,r.return=e,e.child=r,vt=e,gt=null,!0):!1;default:return!1}}function wo(e){return(e.mode&1)!==0&&(e.flags&128)===0}function bo(e){if(je){var t=gt;if(t){var r=t;if(!$d(e,t)){if(wo(e))throw Error($(418));t=_r(r.nextSibling);var s=vt;t&&$d(e,t)?af(s,r):(e.flags=e.flags&-4097|2,je=!1,vt=e)}}else{if(wo(e))throw Error($(418));e.flags=e.flags&-4097|2,je=!1,vt=e}}}function Fd(e){for(e=e.return;e!==null&&e.tag!==5&&e.tag!==3&&e.tag!==13;)e=e.return;vt=e}function _a(e){if(e!==vt)return!1;if(!je)return Fd(e),je=!0,!1;var t;if((t=e.tag!==3)&&!(t=e.tag!==5)&&(t=e.type,t=t!=="head"&&t!=="body"&&!xo(e.type,e.memoizedProps)),t&&(t=gt)){if(wo(e))throw lf(),Error($(418));for(;t;)af(e,t),t=_r(t.nextSibling)}if(Fd(e),e.tag===13){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error($(317));e:{for(e=e.nextSibling,t=0;e;){if(e.nodeType===8){var r=e.data;if(r==="/$"){if(t===0){gt=_r(e.nextSibling);break e}t--}else r!=="$"&&r!=="$!"&&r!=="$?"||t++}e=e.nextSibling}gt=null}}else gt=vt?_r(e.stateNode.nextSibling):null;return!0}function lf(){for(var e=gt;e;)e=_r(e.nextSibling)}function rs(){gt=vt=null,je=!1}function vc(e){Ot===null?Ot=[e]:Ot.push(e)}var fg=vr.ReactCurrentBatchConfig;function ks(e,t,r){if(e=r.ref,e!==null&&typeof e!="function"&&typeof e!="object"){if(r._owner){if(r=r._owner,r){if(r.tag!==1)throw Error($(309));var s=r.stateNode}if(!s)throw Error($(147,e));var a=s,i=""+e;return t!==null&&t.ref!==null&&typeof t.ref=="function"&&t.ref._stringRef===i?t.ref:(t=function(l){var o=a.refs;l===null?delete o[i]:o[i]=l},t._stringRef=i,t)}if(typeof e!="string")throw Error($(284));if(!r._owner)throw Error($(290,e))}return e}function Oa(e,t){throw e=Object.prototype.toString.call(t),Error($(31,e==="[object Object]"?"object with keys {"+Object.keys(t).join(", ")+"}":e))}function Ud(e){var t=e._init;return t(e._payload)}function of(e){function t(m,p){if(e){var g=m.deletions;g===null?(m.deletions=[p],m.flags|=16):g.push(p)}}function r(m,p){if(!e)return null;for(;p!==null;)t(m,p),p=p.sibling;return null}function s(m,p){for(m=new Map;p!==null;)p.key!==null?m.set(p.key,p):m.set(p.index,p),p=p.sibling;return m}function a(m,p){return m=Fr(m,p),m.index=0,m.sibling=null,m}function i(m,p,g){return m.index=g,e?(g=m.alternate,g!==null?(g=g.index,g<p?(m.flags|=2,p):g):(m.flags|=2,p)):(m.flags|=1048576,p)}function l(m){return e&&m.alternate===null&&(m.flags|=2),m}function o(m,p,g,j){return p===null||p.tag!==6?(p=zl(g,m.mode,j),p.return=m,p):(p=a(p,g),p.return=m,p)}function c(m,p,g,j){var S=g.type;return S===Mn?f(m,p,g.props.children,j,g.key):p!==null&&(p.elementType===S||typeof S=="object"&&S!==null&&S.$$typeof===Cr&&Ud(S)===p.type)?(j=a(p,g.props),j.ref=ks(m,p,g),j.return=m,j):(j=ai(g.type,g.key,g.props,null,m.mode,j),j.ref=ks(m,p,g),j.return=m,j)}function d(m,p,g,j){return p===null||p.tag!==4||p.stateNode.containerInfo!==g.containerInfo||p.stateNode.implementation!==g.implementation?(p=Dl(g,m.mode,j),p.return=m,p):(p=a(p,g.children||[]),p.return=m,p)}function f(m,p,g,j,S){return p===null||p.tag!==7?(p=on(g,m.mode,j,S),p.return=m,p):(p=a(p,g),p.return=m,p)}function u(m,p,g){if(typeof p=="string"&&p!==""||typeof p=="number")return p=zl(""+p,m.mode,g),p.return=m,p;if(typeof p=="object"&&p!==null){switch(p.$$typeof){case Ca:return g=ai(p.type,p.key,p.props,null,m.mode,g),g.ref=ks(m,null,p),g.return=m,g;case Dn:return p=Dl(p,m.mode,g),p.return=m,p;case Cr:var j=p._init;return u(m,j(p._payload),g)}if(Rs(p)||ys(p))return p=on(p,m.mode,g,null),p.return=m,p;Oa(m,p)}return null}function x(m,p,g,j){var S=p!==null?p.key:null;if(typeof g=="string"&&g!==""||typeof g=="number")return S!==null?null:o(m,p,""+g,j);if(typeof g=="object"&&g!==null){switch(g.$$typeof){case Ca:return g.key===S?c(m,p,g,j):null;case Dn:return g.key===S?d(m,p,g,j):null;case Cr:return S=g._init,x(m,p,S(g._payload),j)}if(Rs(g)||ys(g))return S!==null?null:f(m,p,g,j,null);Oa(m,g)}return null}function y(m,p,g,j,S){if(typeof j=="string"&&j!==""||typeof j=="number")return m=m.get(g)||null,o(p,m,""+j,S);if(typeof j=="object"&&j!==null){switch(j.$$typeof){case Ca:return m=m.get(j.key===null?g:j.key)||null,c(p,m,j,S);case Dn:return m=m.get(j.key===null?g:j.key)||null,d(p,m,j,S);case Cr:var N=j._init;return y(m,p,g,N(j._payload),S)}if(Rs(j)||ys(j))return m=m.get(g)||null,f(p,m,j,S,null);Oa(p,j)}return null}function w(m,p,g,j){for(var S=null,N=null,C=p,O=p=0,G=null;C!==null&&O<g.length;O++){C.index>O?(G=C,C=null):G=C.sibling;var V=x(m,C,g[O],j);if(V===null){C===null&&(C=G);break}e&&C&&V.alternate===null&&t(m,C),p=i(V,p,O),N===null?S=V:N.sibling=V,N=V,C=G}if(O===g.length)return r(m,C),je&&qr(m,O),S;if(C===null){for(;O<g.length;O++)C=u(m,g[O],j),C!==null&&(p=i(C,p,O),N===null?S=C:N.sibling=C,N=C);return je&&qr(m,O),S}for(C=s(m,C);O<g.length;O++)G=y(C,m,O,g[O],j),G!==null&&(e&&G.alternate!==null&&C.delete(G.key===null?O:G.key),p=i(G,p,O),N===null?S=G:N.sibling=G,N=G);return e&&C.forEach(function(J){return t(m,J)}),je&&qr(m,O),S}function v(m,p,g,j){var S=ys(g);if(typeof S!="function")throw Error($(150));if(g=S.call(g),g==null)throw Error($(151));for(var N=S=null,C=p,O=p=0,G=null,V=g.next();C!==null&&!V.done;O++,V=g.next()){C.index>O?(G=C,C=null):G=C.sibling;var J=x(m,C,V.value,j);if(J===null){C===null&&(C=G);break}e&&C&&J.alternate===null&&t(m,C),p=i(J,p,O),N===null?S=J:N.sibling=J,N=J,C=G}if(V.done)return r(m,C),je&&qr(m,O),S;if(C===null){for(;!V.done;O++,V=g.next())V=u(m,V.value,j),V!==null&&(p=i(V,p,O),N===null?S=V:N.sibling=V,N=V);return je&&qr(m,O),S}for(C=s(m,C);!V.done;O++,V=g.next())V=y(C,m,O,V.value,j),V!==null&&(e&&V.alternate!==null&&C.delete(V.key===null?O:V.key),p=i(V,p,O),N===null?S=V:N.sibling=V,N=V);return e&&C.forEach(function(B){return t(m,B)}),je&&qr(m,O),S}function b(m,p,g,j){if(typeof g=="object"&&g!==null&&g.type===Mn&&g.key===null&&(g=g.props.children),typeof g=="object"&&g!==null){switch(g.$$typeof){case Ca:e:{for(var S=g.key,N=p;N!==null;){if(N.key===S){if(S=g.type,S===Mn){if(N.tag===7){r(m,N.sibling),p=a(N,g.props.children),p.return=m,m=p;break e}}else if(N.elementType===S||typeof S=="object"&&S!==null&&S.$$typeof===Cr&&Ud(S)===N.type){r(m,N.sibling),p=a(N,g.props),p.ref=ks(m,N,g),p.return=m,m=p;break e}r(m,N);break}else t(m,N);N=N.sibling}g.type===Mn?(p=on(g.props.children,m.mode,j,g.key),p.return=m,m=p):(j=ai(g.type,g.key,g.props,null,m.mode,j),j.ref=ks(m,p,g),j.return=m,m=j)}return l(m);case Dn:e:{for(N=g.key;p!==null;){if(p.key===N)if(p.tag===4&&p.stateNode.containerInfo===g.containerInfo&&p.stateNode.implementation===g.implementation){r(m,p.sibling),p=a(p,g.children||[]),p.return=m,m=p;break e}else{r(m,p);break}else t(m,p);p=p.sibling}p=Dl(g,m.mode,j),p.return=m,m=p}return l(m);case Cr:return N=g._init,b(m,p,N(g._payload),j)}if(Rs(g))return w(m,p,g,j);if(ys(g))return v(m,p,g,j);Oa(m,g)}return typeof g=="string"&&g!==""||typeof g=="number"?(g=""+g,p!==null&&p.tag===6?(r(m,p.sibling),p=a(p,g),p.return=m,m=p):(r(m,p),p=zl(g,m.mode,j),p.return=m,m=p),l(m)):r(m,p)}return b}var ns=of(!0),cf=of(!1),ji=Yr(null),Ni=null,Fn=null,yc=null;function wc(){yc=Fn=Ni=null}function bc(e){var t=ji.current;be(ji),e._currentValue=t}function jo(e,t,r){for(;e!==null;){var s=e.alternate;if((e.childLanes&t)!==t?(e.childLanes|=t,s!==null&&(s.childLanes|=t)):s!==null&&(s.childLanes&t)!==t&&(s.childLanes|=t),e===r)break;e=e.return}}function Yn(e,t){Ni=e,yc=Fn=null,e=e.dependencies,e!==null&&e.firstContext!==null&&(e.lanes&t&&(dt=!0),e.firstContext=null)}function Pt(e){var t=e._currentValue;if(yc!==e)if(e={context:e,memoizedValue:t,next:null},Fn===null){if(Ni===null)throw Error($(308));Fn=e,Ni.dependencies={lanes:0,firstContext:e}}else Fn=Fn.next=e;return t}var sn=null;function jc(e){sn===null?sn=[e]:sn.push(e)}function df(e,t,r,s){var a=t.interleaved;return a===null?(r.next=r,jc(t)):(r.next=a.next,a.next=r),t.interleaved=r,xr(e,s)}function xr(e,t){e.lanes|=t;var r=e.alternate;for(r!==null&&(r.lanes|=t),r=e,e=e.return;e!==null;)e.childLanes|=t,r=e.alternate,r!==null&&(r.childLanes|=t),r=e,e=e.return;return r.tag===3?r.stateNode:null}var Er=!1;function Nc(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function uf(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,effects:e.effects})}function hr(e,t){return{eventTime:e,lane:t,tag:0,payload:null,callback:null,next:null}}function Or(e,t,r){var s=e.updateQueue;if(s===null)return null;if(s=s.shared,ce&2){var a=s.pending;return a===null?t.next=t:(t.next=a.next,a.next=t),s.pending=t,xr(e,r)}return a=s.interleaved,a===null?(t.next=t,jc(s)):(t.next=a.next,a.next=t),s.interleaved=t,xr(e,r)}function qa(e,t,r){if(t=t.updateQueue,t!==null&&(t=t.shared,(r&4194240)!==0)){var s=t.lanes;s&=e.pendingLanes,r|=s,t.lanes=r,oc(e,r)}}function Bd(e,t){var r=e.updateQueue,s=e.alternate;if(s!==null&&(s=s.updateQueue,r===s)){var a=null,i=null;if(r=r.firstBaseUpdate,r!==null){do{var l={eventTime:r.eventTime,lane:r.lane,tag:r.tag,payload:r.payload,callback:r.callback,next:null};i===null?a=i=l:i=i.next=l,r=r.next}while(r!==null);i===null?a=i=t:i=i.next=t}else a=i=t;r={baseState:s.baseState,firstBaseUpdate:a,lastBaseUpdate:i,shared:s.shared,effects:s.effects},e.updateQueue=r;return}e=r.lastBaseUpdate,e===null?r.firstBaseUpdate=t:e.next=t,r.lastBaseUpdate=t}function ki(e,t,r,s){var a=e.updateQueue;Er=!1;var i=a.firstBaseUpdate,l=a.lastBaseUpdate,o=a.shared.pending;if(o!==null){a.shared.pending=null;var c=o,d=c.next;c.next=null,l===null?i=d:l.next=d,l=c;var f=e.alternate;f!==null&&(f=f.updateQueue,o=f.lastBaseUpdate,o!==l&&(o===null?f.firstBaseUpdate=d:o.next=d,f.lastBaseUpdate=c))}if(i!==null){var u=a.baseState;l=0,f=d=c=null,o=i;do{var x=o.lane,y=o.eventTime;if((s&x)===x){f!==null&&(f=f.next={eventTime:y,lane:0,tag:o.tag,payload:o.payload,callback:o.callback,next:null});e:{var w=e,v=o;switch(x=t,y=r,v.tag){case 1:if(w=v.payload,typeof w=="function"){u=w.call(y,u,x);break e}u=w;break e;case 3:w.flags=w.flags&-65537|128;case 0:if(w=v.payload,x=typeof w=="function"?w.call(y,u,x):w,x==null)break e;u=Ee({},u,x);break e;case 2:Er=!0}}o.callback!==null&&o.lane!==0&&(e.flags|=64,x=a.effects,x===null?a.effects=[o]:x.push(o))}else y={eventTime:y,lane:x,tag:o.tag,payload:o.payload,callback:o.callback,next:null},f===null?(d=f=y,c=u):f=f.next=y,l|=x;if(o=o.next,o===null){if(o=a.shared.pending,o===null)break;x=o,o=x.next,x.next=null,a.lastBaseUpdate=x,a.shared.pending=null}}while(!0);if(f===null&&(c=u),a.baseState=c,a.firstBaseUpdate=d,a.lastBaseUpdate=f,t=a.shared.interleaved,t!==null){a=t;do l|=a.lane,a=a.next;while(a!==t)}else i===null&&(a.shared.lanes=0);fn|=l,e.lanes=l,e.memoizedState=u}}function Vd(e,t,r){if(e=t.effects,t.effects=null,e!==null)for(t=0;t<e.length;t++){var s=e[t],a=s.callback;if(a!==null){if(s.callback=null,s=r,typeof a!="function")throw Error($(191,a));a.call(s)}}}var va={},tr=Yr(va),na=Yr(va),sa=Yr(va);function an(e){if(e===va)throw Error($(174));return e}function kc(e,t){switch(ge(sa,t),ge(na,e),ge(tr,va),e=t.nodeType,e){case 9:case 11:t=(t=t.documentElement)?t.namespaceURI:to(null,"");break;default:e=e===8?t.parentNode:t,t=e.namespaceURI||null,e=e.tagName,t=to(t,e)}be(tr),ge(tr,t)}function ss(){be(tr),be(na),be(sa)}function hf(e){an(sa.current);var t=an(tr.current),r=to(t,e.type);t!==r&&(ge(na,e),ge(tr,r))}function Sc(e){na.current===e&&(be(tr),be(na))}var Se=Yr(0);function Si(e){for(var t=e;t!==null;){if(t.tag===13){var r=t.memoizedState;if(r!==null&&(r=r.dehydrated,r===null||r.data==="$?"||r.data==="$!"))return t}else if(t.tag===19&&t.memoizedProps.revealOrder!==void 0){if(t.flags&128)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 kl=[];function Cc(){for(var e=0;e<kl.length;e++)kl[e]._workInProgressVersionPrimary=null;kl.length=0}var ei=vr.ReactCurrentDispatcher,Sl=vr.ReactCurrentBatchConfig,hn=0,Ce=null,Le=null,Fe=null,Ci=!1,Bs=!1,aa=0,mg=0;function Xe(){throw Error($(321))}function Ec(e,t){if(t===null)return!1;for(var r=0;r<t.length&&r<e.length;r++)if(!Ft(e[r],t[r]))return!1;return!0}function Tc(e,t,r,s,a,i){if(hn=i,Ce=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,ei.current=e===null||e.memoizedState===null?vg:yg,e=r(s,a),Bs){i=0;do{if(Bs=!1,aa=0,25<=i)throw Error($(301));i+=1,Fe=Le=null,t.updateQueue=null,ei.current=wg,e=r(s,a)}while(Bs)}if(ei.current=Ei,t=Le!==null&&Le.next!==null,hn=0,Fe=Le=Ce=null,Ci=!1,t)throw Error($(300));return e}function Pc(){var e=aa!==0;return aa=0,e}function Jt(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return Fe===null?Ce.memoizedState=Fe=e:Fe=Fe.next=e,Fe}function zt(){if(Le===null){var e=Ce.alternate;e=e!==null?e.memoizedState:null}else e=Le.next;var t=Fe===null?Ce.memoizedState:Fe.next;if(t!==null)Fe=t,Le=e;else{if(e===null)throw Error($(310));Le=e,e={memoizedState:Le.memoizedState,baseState:Le.baseState,baseQueue:Le.baseQueue,queue:Le.queue,next:null},Fe===null?Ce.memoizedState=Fe=e:Fe=Fe.next=e}return Fe}function ia(e,t){return typeof t=="function"?t(e):t}function Cl(e){var t=zt(),r=t.queue;if(r===null)throw Error($(311));r.lastRenderedReducer=e;var s=Le,a=s.baseQueue,i=r.pending;if(i!==null){if(a!==null){var l=a.next;a.next=i.next,i.next=l}s.baseQueue=a=i,r.pending=null}if(a!==null){i=a.next,s=s.baseState;var o=l=null,c=null,d=i;do{var f=d.lane;if((hn&f)===f)c!==null&&(c=c.next={lane:0,action:d.action,hasEagerState:d.hasEagerState,eagerState:d.eagerState,next:null}),s=d.hasEagerState?d.eagerState:e(s,d.action);else{var u={lane:f,action:d.action,hasEagerState:d.hasEagerState,eagerState:d.eagerState,next:null};c===null?(o=c=u,l=s):c=c.next=u,Ce.lanes|=f,fn|=f}d=d.next}while(d!==null&&d!==i);c===null?l=s:c.next=o,Ft(s,t.memoizedState)||(dt=!0),t.memoizedState=s,t.baseState=l,t.baseQueue=c,r.lastRenderedState=s}if(e=r.interleaved,e!==null){a=e;do i=a.lane,Ce.lanes|=i,fn|=i,a=a.next;while(a!==e)}else a===null&&(r.lanes=0);return[t.memoizedState,r.dispatch]}function El(e){var t=zt(),r=t.queue;if(r===null)throw Error($(311));r.lastRenderedReducer=e;var s=r.dispatch,a=r.pending,i=t.memoizedState;if(a!==null){r.pending=null;var l=a=a.next;do i=e(i,l.action),l=l.next;while(l!==a);Ft(i,t.memoizedState)||(dt=!0),t.memoizedState=i,t.baseQueue===null&&(t.baseState=i),r.lastRenderedState=i}return[i,s]}function ff(){}function mf(e,t){var r=Ce,s=zt(),a=t(),i=!Ft(s.memoizedState,a);if(i&&(s.memoizedState=a,dt=!0),s=s.queue,zc(gf.bind(null,r,s,e),[e]),s.getSnapshot!==t||i||Fe!==null&&Fe.memoizedState.tag&1){if(r.flags|=2048,la(9,xf.bind(null,r,s,a,t),void 0,null),Ue===null)throw Error($(349));hn&30||pf(r,t,a)}return a}function pf(e,t,r){e.flags|=16384,e={getSnapshot:t,value:r},t=Ce.updateQueue,t===null?(t={lastEffect:null,stores:null},Ce.updateQueue=t,t.stores=[e]):(r=t.stores,r===null?t.stores=[e]:r.push(e))}function xf(e,t,r,s){t.value=r,t.getSnapshot=s,vf(t)&&yf(e)}function gf(e,t,r){return r(function(){vf(t)&&yf(e)})}function vf(e){var t=e.getSnapshot;e=e.value;try{var r=t();return!Ft(e,r)}catch{return!0}}function yf(e){var t=xr(e,1);t!==null&&$t(t,e,1,-1)}function Wd(e){var t=Jt();return typeof e=="function"&&(e=e()),t.memoizedState=t.baseState=e,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:ia,lastRenderedState:e},t.queue=e,e=e.dispatch=gg.bind(null,Ce,e),[t.memoizedState,e]}function la(e,t,r,s){return e={tag:e,create:t,destroy:r,deps:s,next:null},t=Ce.updateQueue,t===null?(t={lastEffect:null,stores:null},Ce.updateQueue=t,t.lastEffect=e.next=e):(r=t.lastEffect,r===null?t.lastEffect=e.next=e:(s=r.next,r.next=e,e.next=s,t.lastEffect=e)),e}function wf(){return zt().memoizedState}function ti(e,t,r,s){var a=Jt();Ce.flags|=e,a.memoizedState=la(1|t,r,void 0,s===void 0?null:s)}function Vi(e,t,r,s){var a=zt();s=s===void 0?null:s;var i=void 0;if(Le!==null){var l=Le.memoizedState;if(i=l.destroy,s!==null&&Ec(s,l.deps)){a.memoizedState=la(t,r,i,s);return}}Ce.flags|=e,a.memoizedState=la(1|t,r,i,s)}function Hd(e,t){return ti(8390656,8,e,t)}function zc(e,t){return Vi(2048,8,e,t)}function bf(e,t){return Vi(4,2,e,t)}function jf(e,t){return Vi(4,4,e,t)}function Nf(e,t){if(typeof t=="function")return e=e(),t(e),function(){t(null)};if(t!=null)return e=e(),t.current=e,function(){t.current=null}}function kf(e,t,r){return r=r!=null?r.concat([e]):null,Vi(4,4,Nf.bind(null,t,e),r)}function Dc(){}function Sf(e,t){var r=zt();t=t===void 0?null:t;var s=r.memoizedState;return s!==null&&t!==null&&Ec(t,s[1])?s[0]:(r.memoizedState=[e,t],e)}function Cf(e,t){var r=zt();t=t===void 0?null:t;var s=r.memoizedState;return s!==null&&t!==null&&Ec(t,s[1])?s[0]:(e=e(),r.memoizedState=[e,t],e)}function Ef(e,t,r){return hn&21?(Ft(r,t)||(r=Dh(),Ce.lanes|=r,fn|=r,e.baseState=!0),t):(e.baseState&&(e.baseState=!1,dt=!0),e.memoizedState=r)}function pg(e,t){var r=fe;fe=r!==0&&4>r?r:4,e(!0);var s=Sl.transition;Sl.transition={};try{e(!1),t()}finally{fe=r,Sl.transition=s}}function Tf(){return zt().memoizedState}function xg(e,t,r){var s=$r(e);if(r={lane:s,action:r,hasEagerState:!1,eagerState:null,next:null},Pf(e))zf(t,r);else if(r=df(e,t,r,s),r!==null){var a=st();$t(r,e,s,a),Df(r,t,s)}}function gg(e,t,r){var s=$r(e),a={lane:s,action:r,hasEagerState:!1,eagerState:null,next:null};if(Pf(e))zf(t,a);else{var i=e.alternate;if(e.lanes===0&&(i===null||i.lanes===0)&&(i=t.lastRenderedReducer,i!==null))try{var l=t.lastRenderedState,o=i(l,r);if(a.hasEagerState=!0,a.eagerState=o,Ft(o,l)){var c=t.interleaved;c===null?(a.next=a,jc(t)):(a.next=c.next,c.next=a),t.interleaved=a;return}}catch{}finally{}r=df(e,t,a,s),r!==null&&(a=st(),$t(r,e,s,a),Df(r,t,s))}}function Pf(e){var t=e.alternate;return e===Ce||t!==null&&t===Ce}function zf(e,t){Bs=Ci=!0;var r=e.pending;r===null?t.next=t:(t.next=r.next,r.next=t),e.pending=t}function Df(e,t,r){if(r&4194240){var s=t.lanes;s&=e.pendingLanes,r|=s,t.lanes=r,oc(e,r)}}var Ei={readContext:Pt,useCallback:Xe,useContext:Xe,useEffect:Xe,useImperativeHandle:Xe,useInsertionEffect:Xe,useLayoutEffect:Xe,useMemo:Xe,useReducer:Xe,useRef:Xe,useState:Xe,useDebugValue:Xe,useDeferredValue:Xe,useTransition:Xe,useMutableSource:Xe,useSyncExternalStore:Xe,useId:Xe,unstable_isNewReconciler:!1},vg={readContext:Pt,useCallback:function(e,t){return Jt().memoizedState=[e,t===void 0?null:t],e},useContext:Pt,useEffect:Hd,useImperativeHandle:function(e,t,r){return r=r!=null?r.concat([e]):null,ti(4194308,4,Nf.bind(null,t,e),r)},useLayoutEffect:function(e,t){return ti(4194308,4,e,t)},useInsertionEffect:function(e,t){return ti(4,2,e,t)},useMemo:function(e,t){var r=Jt();return t=t===void 0?null:t,e=e(),r.memoizedState=[e,t],e},useReducer:function(e,t,r){var s=Jt();return t=r!==void 0?r(t):t,s.memoizedState=s.baseState=t,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:t},s.queue=e,e=e.dispatch=xg.bind(null,Ce,e),[s.memoizedState,e]},useRef:function(e){var t=Jt();return e={current:e},t.memoizedState=e},useState:Wd,useDebugValue:Dc,useDeferredValue:function(e){return Jt().memoizedState=e},useTransition:function(){var e=Wd(!1),t=e[0];return e=pg.bind(null,e[1]),Jt().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,r){var s=Ce,a=Jt();if(je){if(r===void 0)throw Error($(407));r=r()}else{if(r=t(),Ue===null)throw Error($(349));hn&30||pf(s,t,r)}a.memoizedState=r;var i={value:r,getSnapshot:t};return a.queue=i,Hd(gf.bind(null,s,i,e),[e]),s.flags|=2048,la(9,xf.bind(null,s,i,r,t),void 0,null),r},useId:function(){var e=Jt(),t=Ue.identifierPrefix;if(je){var r=ur,s=dr;r=(s&~(1<<32-At(s)-1)).toString(32)+r,t=":"+t+"R"+r,r=aa++,0<r&&(t+="H"+r.toString(32)),t+=":"}else r=mg++,t=":"+t+"r"+r.toString(32)+":";return e.memoizedState=t},unstable_isNewReconciler:!1},yg={readContext:Pt,useCallback:Sf,useContext:Pt,useEffect:zc,useImperativeHandle:kf,useInsertionEffect:bf,useLayoutEffect:jf,useMemo:Cf,useReducer:Cl,useRef:wf,useState:function(){return Cl(ia)},useDebugValue:Dc,useDeferredValue:function(e){var t=zt();return Ef(t,Le.memoizedState,e)},useTransition:function(){var e=Cl(ia)[0],t=zt().memoizedState;return[e,t]},useMutableSource:ff,useSyncExternalStore:mf,useId:Tf,unstable_isNewReconciler:!1},wg={readContext:Pt,useCallback:Sf,useContext:Pt,useEffect:zc,useImperativeHandle:kf,useInsertionEffect:bf,useLayoutEffect:jf,useMemo:Cf,useReducer:El,useRef:wf,useState:function(){return El(ia)},useDebugValue:Dc,useDeferredValue:function(e){var t=zt();return Le===null?t.memoizedState=e:Ef(t,Le.memoizedState,e)},useTransition:function(){var e=El(ia)[0],t=zt().memoizedState;return[e,t]},useMutableSource:ff,useSyncExternalStore:mf,useId:Tf,unstable_isNewReconciler:!1};function It(e,t){if(e&&e.defaultProps){t=Ee({},t),e=e.defaultProps;for(var r in e)t[r]===void 0&&(t[r]=e[r]);return t}return t}function No(e,t,r,s){t=e.memoizedState,r=r(s,t),r=r==null?t:Ee({},t,r),e.memoizedState=r,e.lanes===0&&(e.updateQueue.baseState=r)}var Wi={isMounted:function(e){return(e=e._reactInternals)?wn(e)===e:!1},enqueueSetState:function(e,t,r){e=e._reactInternals;var s=st(),a=$r(e),i=hr(s,a);i.payload=t,r!=null&&(i.callback=r),t=Or(e,i,a),t!==null&&($t(t,e,a,s),qa(t,e,a))},enqueueReplaceState:function(e,t,r){e=e._reactInternals;var s=st(),a=$r(e),i=hr(s,a);i.tag=1,i.payload=t,r!=null&&(i.callback=r),t=Or(e,i,a),t!==null&&($t(t,e,a,s),qa(t,e,a))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var r=st(),s=$r(e),a=hr(r,s);a.tag=2,t!=null&&(a.callback=t),t=Or(e,a,s),t!==null&&($t(t,e,s,r),qa(t,e,s))}};function Kd(e,t,r,s,a,i,l){return e=e.stateNode,typeof e.shouldComponentUpdate=="function"?e.shouldComponentUpdate(s,i,l):t.prototype&&t.prototype.isPureReactComponent?!qs(r,s)||!qs(a,i):!0}function Mf(e,t,r){var s=!1,a=Hr,i=t.contextType;return typeof i=="object"&&i!==null?i=Pt(i):(a=ft(t)?dn:tt.current,s=t.contextTypes,i=(s=s!=null)?ts(e,a):Hr),t=new t(r,i),e.memoizedState=t.state!==null&&t.state!==void 0?t.state:null,t.updater=Wi,e.stateNode=t,t._reactInternals=e,s&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=a,e.__reactInternalMemoizedMaskedChildContext=i),t}function Qd(e,t,r,s){e=t.state,typeof t.componentWillReceiveProps=="function"&&t.componentWillReceiveProps(r,s),typeof t.UNSAFE_componentWillReceiveProps=="function"&&t.UNSAFE_componentWillReceiveProps(r,s),t.state!==e&&Wi.enqueueReplaceState(t,t.state,null)}function ko(e,t,r,s){var a=e.stateNode;a.props=r,a.state=e.memoizedState,a.refs={},Nc(e);var i=t.contextType;typeof i=="object"&&i!==null?a.context=Pt(i):(i=ft(t)?dn:tt.current,a.context=ts(e,i)),a.state=e.memoizedState,i=t.getDerivedStateFromProps,typeof i=="function"&&(No(e,t,i,r),a.state=e.memoizedState),typeof t.getDerivedStateFromProps=="function"||typeof a.getSnapshotBeforeUpdate=="function"||typeof a.UNSAFE_componentWillMount!="function"&&typeof a.componentWillMount!="function"||(t=a.state,typeof a.componentWillMount=="function"&&a.componentWillMount(),typeof a.UNSAFE_componentWillMount=="function"&&a.UNSAFE_componentWillMount(),t!==a.state&&Wi.enqueueReplaceState(a,a.state,null),ki(e,r,a,s),a.state=e.memoizedState),typeof a.componentDidMount=="function"&&(e.flags|=4194308)}function as(e,t){try{var r="",s=t;do r+=Yp(s),s=s.return;while(s);var a=r}catch(i){a=`
39
- Error generating stack: `+i.message+`
40
- `+i.stack}return{value:e,source:t,stack:a,digest:null}}function Tl(e,t,r){return{value:e,source:null,stack:r??null,digest:t??null}}function So(e,t){try{console.error(t.value)}catch(r){setTimeout(function(){throw r})}}var bg=typeof WeakMap=="function"?WeakMap:Map;function Rf(e,t,r){r=hr(-1,r),r.tag=3,r.payload={element:null};var s=t.value;return r.callback=function(){Pi||(Pi=!0,Lo=s),So(e,t)},r}function If(e,t,r){r=hr(-1,r),r.tag=3;var s=e.type.getDerivedStateFromError;if(typeof s=="function"){var a=t.value;r.payload=function(){return s(a)},r.callback=function(){So(e,t)}}var i=e.stateNode;return i!==null&&typeof i.componentDidCatch=="function"&&(r.callback=function(){So(e,t),typeof s!="function"&&(Ar===null?Ar=new Set([this]):Ar.add(this));var l=t.stack;this.componentDidCatch(t.value,{componentStack:l!==null?l:""})}),r}function Yd(e,t,r){var s=e.pingCache;if(s===null){s=e.pingCache=new bg;var a=new Set;s.set(t,a)}else a=s.get(t),a===void 0&&(a=new Set,s.set(t,a));a.has(r)||(a.add(r),e=Lg.bind(null,e,t,r),t.then(e,e))}function Gd(e){do{var t;if((t=e.tag===13)&&(t=e.memoizedState,t=t!==null?t.dehydrated!==null:!0),t)return e;e=e.return}while(e!==null);return null}function Xd(e,t,r,s,a){return e.mode&1?(e.flags|=65536,e.lanes=a,e):(e===t?e.flags|=65536:(e.flags|=128,r.flags|=131072,r.flags&=-52805,r.tag===1&&(r.alternate===null?r.tag=17:(t=hr(-1,1),t.tag=2,Or(r,t,1))),r.lanes|=1),e)}var jg=vr.ReactCurrentOwner,dt=!1;function nt(e,t,r,s){t.child=e===null?cf(t,null,r,s):ns(t,e.child,r,s)}function Jd(e,t,r,s,a){r=r.render;var i=t.ref;return Yn(t,a),s=Tc(e,t,r,s,i,a),r=Pc(),e!==null&&!dt?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~a,gr(e,t,a)):(je&&r&&xc(t),t.flags|=1,nt(e,t,s,a),t.child)}function Zd(e,t,r,s,a){if(e===null){var i=r.type;return typeof i=="function"&&!$c(i)&&i.defaultProps===void 0&&r.compare===null&&r.defaultProps===void 0?(t.tag=15,t.type=i,Lf(e,t,i,s,a)):(e=ai(r.type,null,s,t,t.mode,a),e.ref=t.ref,e.return=t,t.child=e)}if(i=e.child,!(e.lanes&a)){var l=i.memoizedProps;if(r=r.compare,r=r!==null?r:qs,r(l,s)&&e.ref===t.ref)return gr(e,t,a)}return t.flags|=1,e=Fr(i,s),e.ref=t.ref,e.return=t,t.child=e}function Lf(e,t,r,s,a){if(e!==null){var i=e.memoizedProps;if(qs(i,s)&&e.ref===t.ref)if(dt=!1,t.pendingProps=s=i,(e.lanes&a)!==0)e.flags&131072&&(dt=!0);else return t.lanes=e.lanes,gr(e,t,a)}return Co(e,t,r,s,a)}function _f(e,t,r){var s=t.pendingProps,a=s.children,i=e!==null?e.memoizedState:null;if(s.mode==="hidden")if(!(t.mode&1))t.memoizedState={baseLanes:0,cachePool:null,transitions:null},ge(Bn,xt),xt|=r;else{if(!(r&1073741824))return e=i!==null?i.baseLanes|r:r,t.lanes=t.childLanes=1073741824,t.memoizedState={baseLanes:e,cachePool:null,transitions:null},t.updateQueue=null,ge(Bn,xt),xt|=e,null;t.memoizedState={baseLanes:0,cachePool:null,transitions:null},s=i!==null?i.baseLanes:r,ge(Bn,xt),xt|=s}else i!==null?(s=i.baseLanes|r,t.memoizedState=null):s=r,ge(Bn,xt),xt|=s;return nt(e,t,a,r),t.child}function Of(e,t){var r=t.ref;(e===null&&r!==null||e!==null&&e.ref!==r)&&(t.flags|=512,t.flags|=2097152)}function Co(e,t,r,s,a){var i=ft(r)?dn:tt.current;return i=ts(t,i),Yn(t,a),r=Tc(e,t,r,s,i,a),s=Pc(),e!==null&&!dt?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~a,gr(e,t,a)):(je&&s&&xc(t),t.flags|=1,nt(e,t,r,a),t.child)}function qd(e,t,r,s,a){if(ft(r)){var i=!0;yi(t)}else i=!1;if(Yn(t,a),t.stateNode===null)ri(e,t),Mf(t,r,s),ko(t,r,s,a),s=!0;else if(e===null){var l=t.stateNode,o=t.memoizedProps;l.props=o;var c=l.context,d=r.contextType;typeof d=="object"&&d!==null?d=Pt(d):(d=ft(r)?dn:tt.current,d=ts(t,d));var f=r.getDerivedStateFromProps,u=typeof f=="function"||typeof l.getSnapshotBeforeUpdate=="function";u||typeof l.UNSAFE_componentWillReceiveProps!="function"&&typeof l.componentWillReceiveProps!="function"||(o!==s||c!==d)&&Qd(t,l,s,d),Er=!1;var x=t.memoizedState;l.state=x,ki(t,s,l,a),c=t.memoizedState,o!==s||x!==c||ht.current||Er?(typeof f=="function"&&(No(t,r,f,s),c=t.memoizedState),(o=Er||Kd(t,r,o,s,x,c,d))?(u||typeof l.UNSAFE_componentWillMount!="function"&&typeof l.componentWillMount!="function"||(typeof l.componentWillMount=="function"&&l.componentWillMount(),typeof l.UNSAFE_componentWillMount=="function"&&l.UNSAFE_componentWillMount()),typeof l.componentDidMount=="function"&&(t.flags|=4194308)):(typeof l.componentDidMount=="function"&&(t.flags|=4194308),t.memoizedProps=s,t.memoizedState=c),l.props=s,l.state=c,l.context=d,s=o):(typeof l.componentDidMount=="function"&&(t.flags|=4194308),s=!1)}else{l=t.stateNode,uf(e,t),o=t.memoizedProps,d=t.type===t.elementType?o:It(t.type,o),l.props=d,u=t.pendingProps,x=l.context,c=r.contextType,typeof c=="object"&&c!==null?c=Pt(c):(c=ft(r)?dn:tt.current,c=ts(t,c));var y=r.getDerivedStateFromProps;(f=typeof y=="function"||typeof l.getSnapshotBeforeUpdate=="function")||typeof l.UNSAFE_componentWillReceiveProps!="function"&&typeof l.componentWillReceiveProps!="function"||(o!==u||x!==c)&&Qd(t,l,s,c),Er=!1,x=t.memoizedState,l.state=x,ki(t,s,l,a);var w=t.memoizedState;o!==u||x!==w||ht.current||Er?(typeof y=="function"&&(No(t,r,y,s),w=t.memoizedState),(d=Er||Kd(t,r,d,s,x,w,c)||!1)?(f||typeof l.UNSAFE_componentWillUpdate!="function"&&typeof l.componentWillUpdate!="function"||(typeof l.componentWillUpdate=="function"&&l.componentWillUpdate(s,w,c),typeof l.UNSAFE_componentWillUpdate=="function"&&l.UNSAFE_componentWillUpdate(s,w,c)),typeof l.componentDidUpdate=="function"&&(t.flags|=4),typeof l.getSnapshotBeforeUpdate=="function"&&(t.flags|=1024)):(typeof l.componentDidUpdate!="function"||o===e.memoizedProps&&x===e.memoizedState||(t.flags|=4),typeof l.getSnapshotBeforeUpdate!="function"||o===e.memoizedProps&&x===e.memoizedState||(t.flags|=1024),t.memoizedProps=s,t.memoizedState=w),l.props=s,l.state=w,l.context=c,s=d):(typeof l.componentDidUpdate!="function"||o===e.memoizedProps&&x===e.memoizedState||(t.flags|=4),typeof l.getSnapshotBeforeUpdate!="function"||o===e.memoizedProps&&x===e.memoizedState||(t.flags|=1024),s=!1)}return Eo(e,t,r,s,i,a)}function Eo(e,t,r,s,a,i){Of(e,t);var l=(t.flags&128)!==0;if(!s&&!l)return a&&Ad(t,r,!1),gr(e,t,i);s=t.stateNode,jg.current=t;var o=l&&typeof r.getDerivedStateFromError!="function"?null:s.render();return t.flags|=1,e!==null&&l?(t.child=ns(t,e.child,null,i),t.child=ns(t,null,o,i)):nt(e,t,o,i),t.memoizedState=s.state,a&&Ad(t,r,!0),t.child}function Af(e){var t=e.stateNode;t.pendingContext?Od(e,t.pendingContext,t.pendingContext!==t.context):t.context&&Od(e,t.context,!1),kc(e,t.containerInfo)}function eu(e,t,r,s,a){return rs(),vc(a),t.flags|=256,nt(e,t,r,s),t.child}var To={dehydrated:null,treeContext:null,retryLane:0};function Po(e){return{baseLanes:e,cachePool:null,transitions:null}}function $f(e,t,r){var s=t.pendingProps,a=Se.current,i=!1,l=(t.flags&128)!==0,o;if((o=l)||(o=e!==null&&e.memoizedState===null?!1:(a&2)!==0),o?(i=!0,t.flags&=-129):(e===null||e.memoizedState!==null)&&(a|=1),ge(Se,a&1),e===null)return bo(t),e=t.memoizedState,e!==null&&(e=e.dehydrated,e!==null)?(t.mode&1?e.data==="$!"?t.lanes=8:t.lanes=1073741824:t.lanes=1,null):(l=s.children,e=s.fallback,i?(s=t.mode,i=t.child,l={mode:"hidden",children:l},!(s&1)&&i!==null?(i.childLanes=0,i.pendingProps=l):i=Qi(l,s,0,null),e=on(e,s,r,null),i.return=t,e.return=t,i.sibling=e,t.child=i,t.child.memoizedState=Po(r),t.memoizedState=To,e):Mc(t,l));if(a=e.memoizedState,a!==null&&(o=a.dehydrated,o!==null))return Ng(e,t,l,s,o,a,r);if(i){i=s.fallback,l=t.mode,a=e.child,o=a.sibling;var c={mode:"hidden",children:s.children};return!(l&1)&&t.child!==a?(s=t.child,s.childLanes=0,s.pendingProps=c,t.deletions=null):(s=Fr(a,c),s.subtreeFlags=a.subtreeFlags&14680064),o!==null?i=Fr(o,i):(i=on(i,l,r,null),i.flags|=2),i.return=t,s.return=t,s.sibling=i,t.child=s,s=i,i=t.child,l=e.child.memoizedState,l=l===null?Po(r):{baseLanes:l.baseLanes|r,cachePool:null,transitions:l.transitions},i.memoizedState=l,i.childLanes=e.childLanes&~r,t.memoizedState=To,s}return i=e.child,e=i.sibling,s=Fr(i,{mode:"visible",children:s.children}),!(t.mode&1)&&(s.lanes=r),s.return=t,s.sibling=null,e!==null&&(r=t.deletions,r===null?(t.deletions=[e],t.flags|=16):r.push(e)),t.child=s,t.memoizedState=null,s}function Mc(e,t){return t=Qi({mode:"visible",children:t},e.mode,0,null),t.return=e,e.child=t}function Aa(e,t,r,s){return s!==null&&vc(s),ns(t,e.child,null,r),e=Mc(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function Ng(e,t,r,s,a,i,l){if(r)return t.flags&256?(t.flags&=-257,s=Tl(Error($(422))),Aa(e,t,l,s)):t.memoizedState!==null?(t.child=e.child,t.flags|=128,null):(i=s.fallback,a=t.mode,s=Qi({mode:"visible",children:s.children},a,0,null),i=on(i,a,l,null),i.flags|=2,s.return=t,i.return=t,s.sibling=i,t.child=s,t.mode&1&&ns(t,e.child,null,l),t.child.memoizedState=Po(l),t.memoizedState=To,i);if(!(t.mode&1))return Aa(e,t,l,null);if(a.data==="$!"){if(s=a.nextSibling&&a.nextSibling.dataset,s)var o=s.dgst;return s=o,i=Error($(419)),s=Tl(i,s,void 0),Aa(e,t,l,s)}if(o=(l&e.childLanes)!==0,dt||o){if(s=Ue,s!==null){switch(l&-l){case 4:a=2;break;case 16:a=8;break;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:a=32;break;case 536870912:a=268435456;break;default:a=0}a=a&(s.suspendedLanes|l)?0:a,a!==0&&a!==i.retryLane&&(i.retryLane=a,xr(e,a),$t(s,e,a,-1))}return Ac(),s=Tl(Error($(421))),Aa(e,t,l,s)}return a.data==="$?"?(t.flags|=128,t.child=e.child,t=_g.bind(null,e),a._reactRetry=t,null):(e=i.treeContext,gt=_r(a.nextSibling),vt=t,je=!0,Ot=null,e!==null&&(kt[St++]=dr,kt[St++]=ur,kt[St++]=un,dr=e.id,ur=e.overflow,un=t),t=Mc(t,s.children),t.flags|=4096,t)}function tu(e,t,r){e.lanes|=t;var s=e.alternate;s!==null&&(s.lanes|=t),jo(e.return,t,r)}function Pl(e,t,r,s,a){var i=e.memoizedState;i===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:s,tail:r,tailMode:a}:(i.isBackwards=t,i.rendering=null,i.renderingStartTime=0,i.last=s,i.tail=r,i.tailMode=a)}function Ff(e,t,r){var s=t.pendingProps,a=s.revealOrder,i=s.tail;if(nt(e,t,s.children,r),s=Se.current,s&2)s=s&1|2,t.flags|=128;else{if(e!==null&&e.flags&128)e:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&tu(e,r,t);else if(e.tag===19)tu(e,r,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}s&=1}if(ge(Se,s),!(t.mode&1))t.memoizedState=null;else switch(a){case"forwards":for(r=t.child,a=null;r!==null;)e=r.alternate,e!==null&&Si(e)===null&&(a=r),r=r.sibling;r=a,r===null?(a=t.child,t.child=null):(a=r.sibling,r.sibling=null),Pl(t,!1,a,r,i);break;case"backwards":for(r=null,a=t.child,t.child=null;a!==null;){if(e=a.alternate,e!==null&&Si(e)===null){t.child=a;break}e=a.sibling,a.sibling=r,r=a,a=e}Pl(t,!0,r,null,i);break;case"together":Pl(t,!1,null,null,void 0);break;default:t.memoizedState=null}return t.child}function ri(e,t){!(t.mode&1)&&e!==null&&(e.alternate=null,t.alternate=null,t.flags|=2)}function gr(e,t,r){if(e!==null&&(t.dependencies=e.dependencies),fn|=t.lanes,!(r&t.childLanes))return null;if(e!==null&&t.child!==e.child)throw Error($(153));if(t.child!==null){for(e=t.child,r=Fr(e,e.pendingProps),t.child=r,r.return=t;e.sibling!==null;)e=e.sibling,r=r.sibling=Fr(e,e.pendingProps),r.return=t;r.sibling=null}return t.child}function kg(e,t,r){switch(t.tag){case 3:Af(t),rs();break;case 5:hf(t);break;case 1:ft(t.type)&&yi(t);break;case 4:kc(t,t.stateNode.containerInfo);break;case 10:var s=t.type._context,a=t.memoizedProps.value;ge(ji,s._currentValue),s._currentValue=a;break;case 13:if(s=t.memoizedState,s!==null)return s.dehydrated!==null?(ge(Se,Se.current&1),t.flags|=128,null):r&t.child.childLanes?$f(e,t,r):(ge(Se,Se.current&1),e=gr(e,t,r),e!==null?e.sibling:null);ge(Se,Se.current&1);break;case 19:if(s=(r&t.childLanes)!==0,e.flags&128){if(s)return Ff(e,t,r);t.flags|=128}if(a=t.memoizedState,a!==null&&(a.rendering=null,a.tail=null,a.lastEffect=null),ge(Se,Se.current),s)break;return null;case 22:case 23:return t.lanes=0,_f(e,t,r)}return gr(e,t,r)}var Uf,zo,Bf,Vf;Uf=function(e,t){for(var r=t.child;r!==null;){if(r.tag===5||r.tag===6)e.appendChild(r.stateNode);else if(r.tag!==4&&r.child!==null){r.child.return=r,r=r.child;continue}if(r===t)break;for(;r.sibling===null;){if(r.return===null||r.return===t)return;r=r.return}r.sibling.return=r.return,r=r.sibling}};zo=function(){};Bf=function(e,t,r,s){var a=e.memoizedProps;if(a!==s){e=t.stateNode,an(tr.current);var i=null;switch(r){case"input":a=Jl(e,a),s=Jl(e,s),i=[];break;case"select":a=Ee({},a,{value:void 0}),s=Ee({},s,{value:void 0}),i=[];break;case"textarea":a=eo(e,a),s=eo(e,s),i=[];break;default:typeof a.onClick!="function"&&typeof s.onClick=="function"&&(e.onclick=gi)}ro(r,s);var l;r=null;for(d in a)if(!s.hasOwnProperty(d)&&a.hasOwnProperty(d)&&a[d]!=null)if(d==="style"){var o=a[d];for(l in o)o.hasOwnProperty(l)&&(r||(r={}),r[l]="")}else d!=="dangerouslySetInnerHTML"&&d!=="children"&&d!=="suppressContentEditableWarning"&&d!=="suppressHydrationWarning"&&d!=="autoFocus"&&(Ks.hasOwnProperty(d)?i||(i=[]):(i=i||[]).push(d,null));for(d in s){var c=s[d];if(o=a!=null?a[d]:void 0,s.hasOwnProperty(d)&&c!==o&&(c!=null||o!=null))if(d==="style")if(o){for(l in o)!o.hasOwnProperty(l)||c&&c.hasOwnProperty(l)||(r||(r={}),r[l]="");for(l in c)c.hasOwnProperty(l)&&o[l]!==c[l]&&(r||(r={}),r[l]=c[l])}else r||(i||(i=[]),i.push(d,r)),r=c;else d==="dangerouslySetInnerHTML"?(c=c?c.__html:void 0,o=o?o.__html:void 0,c!=null&&o!==c&&(i=i||[]).push(d,c)):d==="children"?typeof c!="string"&&typeof c!="number"||(i=i||[]).push(d,""+c):d!=="suppressContentEditableWarning"&&d!=="suppressHydrationWarning"&&(Ks.hasOwnProperty(d)?(c!=null&&d==="onScroll"&&ye("scroll",e),i||o===c||(i=[])):(i=i||[]).push(d,c))}r&&(i=i||[]).push("style",r);var d=i;(t.updateQueue=d)&&(t.flags|=4)}};Vf=function(e,t,r,s){r!==s&&(t.flags|=4)};function Ss(e,t){if(!je)switch(e.tailMode){case"hidden":t=e.tail;for(var r=null;t!==null;)t.alternate!==null&&(r=t),t=t.sibling;r===null?e.tail=null:r.sibling=null;break;case"collapsed":r=e.tail;for(var s=null;r!==null;)r.alternate!==null&&(s=r),r=r.sibling;s===null?t||e.tail===null?e.tail=null:e.tail.sibling=null:s.sibling=null}}function Je(e){var t=e.alternate!==null&&e.alternate.child===e.child,r=0,s=0;if(t)for(var a=e.child;a!==null;)r|=a.lanes|a.childLanes,s|=a.subtreeFlags&14680064,s|=a.flags&14680064,a.return=e,a=a.sibling;else for(a=e.child;a!==null;)r|=a.lanes|a.childLanes,s|=a.subtreeFlags,s|=a.flags,a.return=e,a=a.sibling;return e.subtreeFlags|=s,e.childLanes=r,t}function Sg(e,t,r){var s=t.pendingProps;switch(gc(t),t.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return Je(t),null;case 1:return ft(t.type)&&vi(),Je(t),null;case 3:return s=t.stateNode,ss(),be(ht),be(tt),Cc(),s.pendingContext&&(s.context=s.pendingContext,s.pendingContext=null),(e===null||e.child===null)&&(_a(t)?t.flags|=4:e===null||e.memoizedState.isDehydrated&&!(t.flags&256)||(t.flags|=1024,Ot!==null&&(Ao(Ot),Ot=null))),zo(e,t),Je(t),null;case 5:Sc(t);var a=an(sa.current);if(r=t.type,e!==null&&t.stateNode!=null)Bf(e,t,r,s,a),e.ref!==t.ref&&(t.flags|=512,t.flags|=2097152);else{if(!s){if(t.stateNode===null)throw Error($(166));return Je(t),null}if(e=an(tr.current),_a(t)){s=t.stateNode,r=t.type;var i=t.memoizedProps;switch(s[Zt]=t,s[ra]=i,e=(t.mode&1)!==0,r){case"dialog":ye("cancel",s),ye("close",s);break;case"iframe":case"object":case"embed":ye("load",s);break;case"video":case"audio":for(a=0;a<Ls.length;a++)ye(Ls[a],s);break;case"source":ye("error",s);break;case"img":case"image":case"link":ye("error",s),ye("load",s);break;case"details":ye("toggle",s);break;case"input":dd(s,i),ye("invalid",s);break;case"select":s._wrapperState={wasMultiple:!!i.multiple},ye("invalid",s);break;case"textarea":hd(s,i),ye("invalid",s)}ro(r,i),a=null;for(var l in i)if(i.hasOwnProperty(l)){var o=i[l];l==="children"?typeof o=="string"?s.textContent!==o&&(i.suppressHydrationWarning!==!0&&La(s.textContent,o,e),a=["children",o]):typeof o=="number"&&s.textContent!==""+o&&(i.suppressHydrationWarning!==!0&&La(s.textContent,o,e),a=["children",""+o]):Ks.hasOwnProperty(l)&&o!=null&&l==="onScroll"&&ye("scroll",s)}switch(r){case"input":Ea(s),ud(s,i,!0);break;case"textarea":Ea(s),fd(s);break;case"select":case"option":break;default:typeof i.onClick=="function"&&(s.onclick=gi)}s=a,t.updateQueue=s,s!==null&&(t.flags|=4)}else{l=a.nodeType===9?a:a.ownerDocument,e==="http://www.w3.org/1999/xhtml"&&(e=xh(r)),e==="http://www.w3.org/1999/xhtml"?r==="script"?(e=l.createElement("div"),e.innerHTML="<script><\/script>",e=e.removeChild(e.firstChild)):typeof s.is=="string"?e=l.createElement(r,{is:s.is}):(e=l.createElement(r),r==="select"&&(l=e,s.multiple?l.multiple=!0:s.size&&(l.size=s.size))):e=l.createElementNS(e,r),e[Zt]=t,e[ra]=s,Uf(e,t,!1,!1),t.stateNode=e;e:{switch(l=no(r,s),r){case"dialog":ye("cancel",e),ye("close",e),a=s;break;case"iframe":case"object":case"embed":ye("load",e),a=s;break;case"video":case"audio":for(a=0;a<Ls.length;a++)ye(Ls[a],e);a=s;break;case"source":ye("error",e),a=s;break;case"img":case"image":case"link":ye("error",e),ye("load",e),a=s;break;case"details":ye("toggle",e),a=s;break;case"input":dd(e,s),a=Jl(e,s),ye("invalid",e);break;case"option":a=s;break;case"select":e._wrapperState={wasMultiple:!!s.multiple},a=Ee({},s,{value:void 0}),ye("invalid",e);break;case"textarea":hd(e,s),a=eo(e,s),ye("invalid",e);break;default:a=s}ro(r,a),o=a;for(i in o)if(o.hasOwnProperty(i)){var c=o[i];i==="style"?yh(e,c):i==="dangerouslySetInnerHTML"?(c=c?c.__html:void 0,c!=null&&gh(e,c)):i==="children"?typeof c=="string"?(r!=="textarea"||c!=="")&&Qs(e,c):typeof c=="number"&&Qs(e,""+c):i!=="suppressContentEditableWarning"&&i!=="suppressHydrationWarning"&&i!=="autoFocus"&&(Ks.hasOwnProperty(i)?c!=null&&i==="onScroll"&&ye("scroll",e):c!=null&&rc(e,i,c,l))}switch(r){case"input":Ea(e),ud(e,s,!1);break;case"textarea":Ea(e),fd(e);break;case"option":s.value!=null&&e.setAttribute("value",""+Wr(s.value));break;case"select":e.multiple=!!s.multiple,i=s.value,i!=null?Wn(e,!!s.multiple,i,!1):s.defaultValue!=null&&Wn(e,!!s.multiple,s.defaultValue,!0);break;default:typeof a.onClick=="function"&&(e.onclick=gi)}switch(r){case"button":case"input":case"select":case"textarea":s=!!s.autoFocus;break e;case"img":s=!0;break e;default:s=!1}}s&&(t.flags|=4)}t.ref!==null&&(t.flags|=512,t.flags|=2097152)}return Je(t),null;case 6:if(e&&t.stateNode!=null)Vf(e,t,e.memoizedProps,s);else{if(typeof s!="string"&&t.stateNode===null)throw Error($(166));if(r=an(sa.current),an(tr.current),_a(t)){if(s=t.stateNode,r=t.memoizedProps,s[Zt]=t,(i=s.nodeValue!==r)&&(e=vt,e!==null))switch(e.tag){case 3:La(s.nodeValue,r,(e.mode&1)!==0);break;case 5:e.memoizedProps.suppressHydrationWarning!==!0&&La(s.nodeValue,r,(e.mode&1)!==0)}i&&(t.flags|=4)}else s=(r.nodeType===9?r:r.ownerDocument).createTextNode(s),s[Zt]=t,t.stateNode=s}return Je(t),null;case 13:if(be(Se),s=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(je&&gt!==null&&t.mode&1&&!(t.flags&128))lf(),rs(),t.flags|=98560,i=!1;else if(i=_a(t),s!==null&&s.dehydrated!==null){if(e===null){if(!i)throw Error($(318));if(i=t.memoizedState,i=i!==null?i.dehydrated:null,!i)throw Error($(317));i[Zt]=t}else rs(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;Je(t),i=!1}else Ot!==null&&(Ao(Ot),Ot=null),i=!0;if(!i)return t.flags&65536?t:null}return t.flags&128?(t.lanes=r,t):(s=s!==null,s!==(e!==null&&e.memoizedState!==null)&&s&&(t.child.flags|=8192,t.mode&1&&(e===null||Se.current&1?_e===0&&(_e=3):Ac())),t.updateQueue!==null&&(t.flags|=4),Je(t),null);case 4:return ss(),zo(e,t),e===null&&ea(t.stateNode.containerInfo),Je(t),null;case 10:return bc(t.type._context),Je(t),null;case 17:return ft(t.type)&&vi(),Je(t),null;case 19:if(be(Se),i=t.memoizedState,i===null)return Je(t),null;if(s=(t.flags&128)!==0,l=i.rendering,l===null)if(s)Ss(i,!1);else{if(_e!==0||e!==null&&e.flags&128)for(e=t.child;e!==null;){if(l=Si(e),l!==null){for(t.flags|=128,Ss(i,!1),s=l.updateQueue,s!==null&&(t.updateQueue=s,t.flags|=4),t.subtreeFlags=0,s=r,r=t.child;r!==null;)i=r,e=s,i.flags&=14680066,l=i.alternate,l===null?(i.childLanes=0,i.lanes=e,i.child=null,i.subtreeFlags=0,i.memoizedProps=null,i.memoizedState=null,i.updateQueue=null,i.dependencies=null,i.stateNode=null):(i.childLanes=l.childLanes,i.lanes=l.lanes,i.child=l.child,i.subtreeFlags=0,i.deletions=null,i.memoizedProps=l.memoizedProps,i.memoizedState=l.memoizedState,i.updateQueue=l.updateQueue,i.type=l.type,e=l.dependencies,i.dependencies=e===null?null:{lanes:e.lanes,firstContext:e.firstContext}),r=r.sibling;return ge(Se,Se.current&1|2),t.child}e=e.sibling}i.tail!==null&&De()>is&&(t.flags|=128,s=!0,Ss(i,!1),t.lanes=4194304)}else{if(!s)if(e=Si(l),e!==null){if(t.flags|=128,s=!0,r=e.updateQueue,r!==null&&(t.updateQueue=r,t.flags|=4),Ss(i,!0),i.tail===null&&i.tailMode==="hidden"&&!l.alternate&&!je)return Je(t),null}else 2*De()-i.renderingStartTime>is&&r!==1073741824&&(t.flags|=128,s=!0,Ss(i,!1),t.lanes=4194304);i.isBackwards?(l.sibling=t.child,t.child=l):(r=i.last,r!==null?r.sibling=l:t.child=l,i.last=l)}return i.tail!==null?(t=i.tail,i.rendering=t,i.tail=t.sibling,i.renderingStartTime=De(),t.sibling=null,r=Se.current,ge(Se,s?r&1|2:r&1),t):(Je(t),null);case 22:case 23:return Oc(),s=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==s&&(t.flags|=8192),s&&t.mode&1?xt&1073741824&&(Je(t),t.subtreeFlags&6&&(t.flags|=8192)):Je(t),null;case 24:return null;case 25:return null}throw Error($(156,t.tag))}function Cg(e,t){switch(gc(t),t.tag){case 1:return ft(t.type)&&vi(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return ss(),be(ht),be(tt),Cc(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 5:return Sc(t),null;case 13:if(be(Se),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error($(340));rs()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return be(Se),null;case 4:return ss(),null;case 10:return bc(t.type._context),null;case 22:case 23:return Oc(),null;case 24:return null;default:return null}}var $a=!1,et=!1,Eg=typeof WeakSet=="function"?WeakSet:Set,K=null;function Un(e,t){var r=e.ref;if(r!==null)if(typeof r=="function")try{r(null)}catch(s){Te(e,t,s)}else r.current=null}function Do(e,t,r){try{r()}catch(s){Te(e,t,s)}}var ru=!1;function Tg(e,t){if(mo=mi,e=Qh(),pc(e)){if("selectionStart"in e)var r={start:e.selectionStart,end:e.selectionEnd};else e:{r=(r=e.ownerDocument)&&r.defaultView||window;var s=r.getSelection&&r.getSelection();if(s&&s.rangeCount!==0){r=s.anchorNode;var a=s.anchorOffset,i=s.focusNode;s=s.focusOffset;try{r.nodeType,i.nodeType}catch{r=null;break e}var l=0,o=-1,c=-1,d=0,f=0,u=e,x=null;t:for(;;){for(var y;u!==r||a!==0&&u.nodeType!==3||(o=l+a),u!==i||s!==0&&u.nodeType!==3||(c=l+s),u.nodeType===3&&(l+=u.nodeValue.length),(y=u.firstChild)!==null;)x=u,u=y;for(;;){if(u===e)break t;if(x===r&&++d===a&&(o=l),x===i&&++f===s&&(c=l),(y=u.nextSibling)!==null)break;u=x,x=u.parentNode}u=y}r=o===-1||c===-1?null:{start:o,end:c}}else r=null}r=r||{start:0,end:0}}else r=null;for(po={focusedElem:e,selectionRange:r},mi=!1,K=t;K!==null;)if(t=K,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,K=e;else for(;K!==null;){t=K;try{var w=t.alternate;if(t.flags&1024)switch(t.tag){case 0:case 11:case 15:break;case 1:if(w!==null){var v=w.memoizedProps,b=w.memoizedState,m=t.stateNode,p=m.getSnapshotBeforeUpdate(t.elementType===t.type?v:It(t.type,v),b);m.__reactInternalSnapshotBeforeUpdate=p}break;case 3:var g=t.stateNode.containerInfo;g.nodeType===1?g.textContent="":g.nodeType===9&&g.documentElement&&g.removeChild(g.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error($(163))}}catch(j){Te(t,t.return,j)}if(e=t.sibling,e!==null){e.return=t.return,K=e;break}K=t.return}return w=ru,ru=!1,w}function Vs(e,t,r){var s=t.updateQueue;if(s=s!==null?s.lastEffect:null,s!==null){var a=s=s.next;do{if((a.tag&e)===e){var i=a.destroy;a.destroy=void 0,i!==void 0&&Do(t,r,i)}a=a.next}while(a!==s)}}function Hi(e,t){if(t=t.updateQueue,t=t!==null?t.lastEffect:null,t!==null){var r=t=t.next;do{if((r.tag&e)===e){var s=r.create;r.destroy=s()}r=r.next}while(r!==t)}}function Mo(e){var t=e.ref;if(t!==null){var r=e.stateNode;switch(e.tag){case 5:e=r;break;default:e=r}typeof t=="function"?t(e):t.current=e}}function Wf(e){var t=e.alternate;t!==null&&(e.alternate=null,Wf(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[Zt],delete t[ra],delete t[vo],delete t[dg],delete t[ug])),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}function Hf(e){return e.tag===5||e.tag===3||e.tag===4}function nu(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||Hf(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.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 Ro(e,t,r){var s=e.tag;if(s===5||s===6)e=e.stateNode,t?r.nodeType===8?r.parentNode.insertBefore(e,t):r.insertBefore(e,t):(r.nodeType===8?(t=r.parentNode,t.insertBefore(e,r)):(t=r,t.appendChild(e)),r=r._reactRootContainer,r!=null||t.onclick!==null||(t.onclick=gi));else if(s!==4&&(e=e.child,e!==null))for(Ro(e,t,r),e=e.sibling;e!==null;)Ro(e,t,r),e=e.sibling}function Io(e,t,r){var s=e.tag;if(s===5||s===6)e=e.stateNode,t?r.insertBefore(e,t):r.appendChild(e);else if(s!==4&&(e=e.child,e!==null))for(Io(e,t,r),e=e.sibling;e!==null;)Io(e,t,r),e=e.sibling}var Ve=null,Lt=!1;function br(e,t,r){for(r=r.child;r!==null;)Kf(e,t,r),r=r.sibling}function Kf(e,t,r){if(er&&typeof er.onCommitFiberUnmount=="function")try{er.onCommitFiberUnmount(Oi,r)}catch{}switch(r.tag){case 5:et||Un(r,t);case 6:var s=Ve,a=Lt;Ve=null,br(e,t,r),Ve=s,Lt=a,Ve!==null&&(Lt?(e=Ve,r=r.stateNode,e.nodeType===8?e.parentNode.removeChild(r):e.removeChild(r)):Ve.removeChild(r.stateNode));break;case 18:Ve!==null&&(Lt?(e=Ve,r=r.stateNode,e.nodeType===8?jl(e.parentNode,r):e.nodeType===1&&jl(e,r),Js(e)):jl(Ve,r.stateNode));break;case 4:s=Ve,a=Lt,Ve=r.stateNode.containerInfo,Lt=!0,br(e,t,r),Ve=s,Lt=a;break;case 0:case 11:case 14:case 15:if(!et&&(s=r.updateQueue,s!==null&&(s=s.lastEffect,s!==null))){a=s=s.next;do{var i=a,l=i.destroy;i=i.tag,l!==void 0&&(i&2||i&4)&&Do(r,t,l),a=a.next}while(a!==s)}br(e,t,r);break;case 1:if(!et&&(Un(r,t),s=r.stateNode,typeof s.componentWillUnmount=="function"))try{s.props=r.memoizedProps,s.state=r.memoizedState,s.componentWillUnmount()}catch(o){Te(r,t,o)}br(e,t,r);break;case 21:br(e,t,r);break;case 22:r.mode&1?(et=(s=et)||r.memoizedState!==null,br(e,t,r),et=s):br(e,t,r);break;default:br(e,t,r)}}function su(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var r=e.stateNode;r===null&&(r=e.stateNode=new Eg),t.forEach(function(s){var a=Og.bind(null,e,s);r.has(s)||(r.add(s),s.then(a,a))})}}function Rt(e,t){var r=t.deletions;if(r!==null)for(var s=0;s<r.length;s++){var a=r[s];try{var i=e,l=t,o=l;e:for(;o!==null;){switch(o.tag){case 5:Ve=o.stateNode,Lt=!1;break e;case 3:Ve=o.stateNode.containerInfo,Lt=!0;break e;case 4:Ve=o.stateNode.containerInfo,Lt=!0;break e}o=o.return}if(Ve===null)throw Error($(160));Kf(i,l,a),Ve=null,Lt=!1;var c=a.alternate;c!==null&&(c.return=null),a.return=null}catch(d){Te(a,t,d)}}if(t.subtreeFlags&12854)for(t=t.child;t!==null;)Qf(t,e),t=t.sibling}function Qf(e,t){var r=e.alternate,s=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:if(Rt(t,e),Kt(e),s&4){try{Vs(3,e,e.return),Hi(3,e)}catch(v){Te(e,e.return,v)}try{Vs(5,e,e.return)}catch(v){Te(e,e.return,v)}}break;case 1:Rt(t,e),Kt(e),s&512&&r!==null&&Un(r,r.return);break;case 5:if(Rt(t,e),Kt(e),s&512&&r!==null&&Un(r,r.return),e.flags&32){var a=e.stateNode;try{Qs(a,"")}catch(v){Te(e,e.return,v)}}if(s&4&&(a=e.stateNode,a!=null)){var i=e.memoizedProps,l=r!==null?r.memoizedProps:i,o=e.type,c=e.updateQueue;if(e.updateQueue=null,c!==null)try{o==="input"&&i.type==="radio"&&i.name!=null&&mh(a,i),no(o,l);var d=no(o,i);for(l=0;l<c.length;l+=2){var f=c[l],u=c[l+1];f==="style"?yh(a,u):f==="dangerouslySetInnerHTML"?gh(a,u):f==="children"?Qs(a,u):rc(a,f,u,d)}switch(o){case"input":Zl(a,i);break;case"textarea":ph(a,i);break;case"select":var x=a._wrapperState.wasMultiple;a._wrapperState.wasMultiple=!!i.multiple;var y=i.value;y!=null?Wn(a,!!i.multiple,y,!1):x!==!!i.multiple&&(i.defaultValue!=null?Wn(a,!!i.multiple,i.defaultValue,!0):Wn(a,!!i.multiple,i.multiple?[]:"",!1))}a[ra]=i}catch(v){Te(e,e.return,v)}}break;case 6:if(Rt(t,e),Kt(e),s&4){if(e.stateNode===null)throw Error($(162));a=e.stateNode,i=e.memoizedProps;try{a.nodeValue=i}catch(v){Te(e,e.return,v)}}break;case 3:if(Rt(t,e),Kt(e),s&4&&r!==null&&r.memoizedState.isDehydrated)try{Js(t.containerInfo)}catch(v){Te(e,e.return,v)}break;case 4:Rt(t,e),Kt(e);break;case 13:Rt(t,e),Kt(e),a=e.child,a.flags&8192&&(i=a.memoizedState!==null,a.stateNode.isHidden=i,!i||a.alternate!==null&&a.alternate.memoizedState!==null||(Lc=De())),s&4&&su(e);break;case 22:if(f=r!==null&&r.memoizedState!==null,e.mode&1?(et=(d=et)||f,Rt(t,e),et=d):Rt(t,e),Kt(e),s&8192){if(d=e.memoizedState!==null,(e.stateNode.isHidden=d)&&!f&&e.mode&1)for(K=e,f=e.child;f!==null;){for(u=K=f;K!==null;){switch(x=K,y=x.child,x.tag){case 0:case 11:case 14:case 15:Vs(4,x,x.return);break;case 1:Un(x,x.return);var w=x.stateNode;if(typeof w.componentWillUnmount=="function"){s=x,r=x.return;try{t=s,w.props=t.memoizedProps,w.state=t.memoizedState,w.componentWillUnmount()}catch(v){Te(s,r,v)}}break;case 5:Un(x,x.return);break;case 22:if(x.memoizedState!==null){iu(u);continue}}y!==null?(y.return=x,K=y):iu(u)}f=f.sibling}e:for(f=null,u=e;;){if(u.tag===5){if(f===null){f=u;try{a=u.stateNode,d?(i=a.style,typeof i.setProperty=="function"?i.setProperty("display","none","important"):i.display="none"):(o=u.stateNode,c=u.memoizedProps.style,l=c!=null&&c.hasOwnProperty("display")?c.display:null,o.style.display=vh("display",l))}catch(v){Te(e,e.return,v)}}}else if(u.tag===6){if(f===null)try{u.stateNode.nodeValue=d?"":u.memoizedProps}catch(v){Te(e,e.return,v)}}else if((u.tag!==22&&u.tag!==23||u.memoizedState===null||u===e)&&u.child!==null){u.child.return=u,u=u.child;continue}if(u===e)break e;for(;u.sibling===null;){if(u.return===null||u.return===e)break e;f===u&&(f=null),u=u.return}f===u&&(f=null),u.sibling.return=u.return,u=u.sibling}}break;case 19:Rt(t,e),Kt(e),s&4&&su(e);break;case 21:break;default:Rt(t,e),Kt(e)}}function Kt(e){var t=e.flags;if(t&2){try{e:{for(var r=e.return;r!==null;){if(Hf(r)){var s=r;break e}r=r.return}throw Error($(160))}switch(s.tag){case 5:var a=s.stateNode;s.flags&32&&(Qs(a,""),s.flags&=-33);var i=nu(e);Io(e,i,a);break;case 3:case 4:var l=s.stateNode.containerInfo,o=nu(e);Ro(e,o,l);break;default:throw Error($(161))}}catch(c){Te(e,e.return,c)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function Pg(e,t,r){K=e,Yf(e)}function Yf(e,t,r){for(var s=(e.mode&1)!==0;K!==null;){var a=K,i=a.child;if(a.tag===22&&s){var l=a.memoizedState!==null||$a;if(!l){var o=a.alternate,c=o!==null&&o.memoizedState!==null||et;o=$a;var d=et;if($a=l,(et=c)&&!d)for(K=a;K!==null;)l=K,c=l.child,l.tag===22&&l.memoizedState!==null?lu(a):c!==null?(c.return=l,K=c):lu(a);for(;i!==null;)K=i,Yf(i),i=i.sibling;K=a,$a=o,et=d}au(e)}else a.subtreeFlags&8772&&i!==null?(i.return=a,K=i):au(e)}}function au(e){for(;K!==null;){var t=K;if(t.flags&8772){var r=t.alternate;try{if(t.flags&8772)switch(t.tag){case 0:case 11:case 15:et||Hi(5,t);break;case 1:var s=t.stateNode;if(t.flags&4&&!et)if(r===null)s.componentDidMount();else{var a=t.elementType===t.type?r.memoizedProps:It(t.type,r.memoizedProps);s.componentDidUpdate(a,r.memoizedState,s.__reactInternalSnapshotBeforeUpdate)}var i=t.updateQueue;i!==null&&Vd(t,i,s);break;case 3:var l=t.updateQueue;if(l!==null){if(r=null,t.child!==null)switch(t.child.tag){case 5:r=t.child.stateNode;break;case 1:r=t.child.stateNode}Vd(t,l,r)}break;case 5:var o=t.stateNode;if(r===null&&t.flags&4){r=o;var c=t.memoizedProps;switch(t.type){case"button":case"input":case"select":case"textarea":c.autoFocus&&r.focus();break;case"img":c.src&&(r.src=c.src)}}break;case 6:break;case 4:break;case 12:break;case 13:if(t.memoizedState===null){var d=t.alternate;if(d!==null){var f=d.memoizedState;if(f!==null){var u=f.dehydrated;u!==null&&Js(u)}}}break;case 19:case 17:case 21:case 22:case 23:case 25:break;default:throw Error($(163))}et||t.flags&512&&Mo(t)}catch(x){Te(t,t.return,x)}}if(t===e){K=null;break}if(r=t.sibling,r!==null){r.return=t.return,K=r;break}K=t.return}}function iu(e){for(;K!==null;){var t=K;if(t===e){K=null;break}var r=t.sibling;if(r!==null){r.return=t.return,K=r;break}K=t.return}}function lu(e){for(;K!==null;){var t=K;try{switch(t.tag){case 0:case 11:case 15:var r=t.return;try{Hi(4,t)}catch(c){Te(t,r,c)}break;case 1:var s=t.stateNode;if(typeof s.componentDidMount=="function"){var a=t.return;try{s.componentDidMount()}catch(c){Te(t,a,c)}}var i=t.return;try{Mo(t)}catch(c){Te(t,i,c)}break;case 5:var l=t.return;try{Mo(t)}catch(c){Te(t,l,c)}}}catch(c){Te(t,t.return,c)}if(t===e){K=null;break}var o=t.sibling;if(o!==null){o.return=t.return,K=o;break}K=t.return}}var zg=Math.ceil,Ti=vr.ReactCurrentDispatcher,Rc=vr.ReactCurrentOwner,Tt=vr.ReactCurrentBatchConfig,ce=0,Ue=null,Me=null,He=0,xt=0,Bn=Yr(0),_e=0,oa=null,fn=0,Ki=0,Ic=0,Ws=null,ct=null,Lc=0,is=1/0,or=null,Pi=!1,Lo=null,Ar=null,Fa=!1,Dr=null,zi=0,Hs=0,_o=null,ni=-1,si=0;function st(){return ce&6?De():ni!==-1?ni:ni=De()}function $r(e){return e.mode&1?ce&2&&He!==0?He&-He:fg.transition!==null?(si===0&&(si=Dh()),si):(e=fe,e!==0||(e=window.event,e=e===void 0?16:Ah(e.type)),e):1}function $t(e,t,r,s){if(50<Hs)throw Hs=0,_o=null,Error($(185));pa(e,r,s),(!(ce&2)||e!==Ue)&&(e===Ue&&(!(ce&2)&&(Ki|=r),_e===4&&Pr(e,He)),mt(e,s),r===1&&ce===0&&!(t.mode&1)&&(is=De()+500,Bi&&Gr()))}function mt(e,t){var r=e.callbackNode;fx(e,t);var s=fi(e,e===Ue?He:0);if(s===0)r!==null&&xd(r),e.callbackNode=null,e.callbackPriority=0;else if(t=s&-s,e.callbackPriority!==t){if(r!=null&&xd(r),t===1)e.tag===0?hg(ou.bind(null,e)):nf(ou.bind(null,e)),og(function(){!(ce&6)&&Gr()}),r=null;else{switch(Mh(s)){case 1:r=lc;break;case 4:r=Ph;break;case 16:r=hi;break;case 536870912:r=zh;break;default:r=hi}r=rm(r,Gf.bind(null,e))}e.callbackPriority=t,e.callbackNode=r}}function Gf(e,t){if(ni=-1,si=0,ce&6)throw Error($(327));var r=e.callbackNode;if(Gn()&&e.callbackNode!==r)return null;var s=fi(e,e===Ue?He:0);if(s===0)return null;if(s&30||s&e.expiredLanes||t)t=Di(e,s);else{t=s;var a=ce;ce|=2;var i=Jf();(Ue!==e||He!==t)&&(or=null,is=De()+500,ln(e,t));do try{Rg();break}catch(o){Xf(e,o)}while(!0);wc(),Ti.current=i,ce=a,Me!==null?t=0:(Ue=null,He=0,t=_e)}if(t!==0){if(t===2&&(a=oo(e),a!==0&&(s=a,t=Oo(e,a))),t===1)throw r=oa,ln(e,0),Pr(e,s),mt(e,De()),r;if(t===6)Pr(e,s);else{if(a=e.current.alternate,!(s&30)&&!Dg(a)&&(t=Di(e,s),t===2&&(i=oo(e),i!==0&&(s=i,t=Oo(e,i))),t===1))throw r=oa,ln(e,0),Pr(e,s),mt(e,De()),r;switch(e.finishedWork=a,e.finishedLanes=s,t){case 0:case 1:throw Error($(345));case 2:en(e,ct,or);break;case 3:if(Pr(e,s),(s&130023424)===s&&(t=Lc+500-De(),10<t)){if(fi(e,0)!==0)break;if(a=e.suspendedLanes,(a&s)!==s){st(),e.pingedLanes|=e.suspendedLanes&a;break}e.timeoutHandle=go(en.bind(null,e,ct,or),t);break}en(e,ct,or);break;case 4:if(Pr(e,s),(s&4194240)===s)break;for(t=e.eventTimes,a=-1;0<s;){var l=31-At(s);i=1<<l,l=t[l],l>a&&(a=l),s&=~i}if(s=a,s=De()-s,s=(120>s?120:480>s?480:1080>s?1080:1920>s?1920:3e3>s?3e3:4320>s?4320:1960*zg(s/1960))-s,10<s){e.timeoutHandle=go(en.bind(null,e,ct,or),s);break}en(e,ct,or);break;case 5:en(e,ct,or);break;default:throw Error($(329))}}}return mt(e,De()),e.callbackNode===r?Gf.bind(null,e):null}function Oo(e,t){var r=Ws;return e.current.memoizedState.isDehydrated&&(ln(e,t).flags|=256),e=Di(e,t),e!==2&&(t=ct,ct=r,t!==null&&Ao(t)),e}function Ao(e){ct===null?ct=e:ct.push.apply(ct,e)}function Dg(e){for(var t=e;;){if(t.flags&16384){var r=t.updateQueue;if(r!==null&&(r=r.stores,r!==null))for(var s=0;s<r.length;s++){var a=r[s],i=a.getSnapshot;a=a.value;try{if(!Ft(i(),a))return!1}catch{return!1}}}if(r=t.child,t.subtreeFlags&16384&&r!==null)r.return=t,t=r;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 Pr(e,t){for(t&=~Ic,t&=~Ki,e.suspendedLanes|=t,e.pingedLanes&=~t,e=e.expirationTimes;0<t;){var r=31-At(t),s=1<<r;e[r]=-1,t&=~s}}function ou(e){if(ce&6)throw Error($(327));Gn();var t=fi(e,0);if(!(t&1))return mt(e,De()),null;var r=Di(e,t);if(e.tag!==0&&r===2){var s=oo(e);s!==0&&(t=s,r=Oo(e,s))}if(r===1)throw r=oa,ln(e,0),Pr(e,t),mt(e,De()),r;if(r===6)throw Error($(345));return e.finishedWork=e.current.alternate,e.finishedLanes=t,en(e,ct,or),mt(e,De()),null}function _c(e,t){var r=ce;ce|=1;try{return e(t)}finally{ce=r,ce===0&&(is=De()+500,Bi&&Gr())}}function mn(e){Dr!==null&&Dr.tag===0&&!(ce&6)&&Gn();var t=ce;ce|=1;var r=Tt.transition,s=fe;try{if(Tt.transition=null,fe=1,e)return e()}finally{fe=s,Tt.transition=r,ce=t,!(ce&6)&&Gr()}}function Oc(){xt=Bn.current,be(Bn)}function ln(e,t){e.finishedWork=null,e.finishedLanes=0;var r=e.timeoutHandle;if(r!==-1&&(e.timeoutHandle=-1,lg(r)),Me!==null)for(r=Me.return;r!==null;){var s=r;switch(gc(s),s.tag){case 1:s=s.type.childContextTypes,s!=null&&vi();break;case 3:ss(),be(ht),be(tt),Cc();break;case 5:Sc(s);break;case 4:ss();break;case 13:be(Se);break;case 19:be(Se);break;case 10:bc(s.type._context);break;case 22:case 23:Oc()}r=r.return}if(Ue=e,Me=e=Fr(e.current,null),He=xt=t,_e=0,oa=null,Ic=Ki=fn=0,ct=Ws=null,sn!==null){for(t=0;t<sn.length;t++)if(r=sn[t],s=r.interleaved,s!==null){r.interleaved=null;var a=s.next,i=r.pending;if(i!==null){var l=i.next;i.next=a,s.next=l}r.pending=s}sn=null}return e}function Xf(e,t){do{var r=Me;try{if(wc(),ei.current=Ei,Ci){for(var s=Ce.memoizedState;s!==null;){var a=s.queue;a!==null&&(a.pending=null),s=s.next}Ci=!1}if(hn=0,Fe=Le=Ce=null,Bs=!1,aa=0,Rc.current=null,r===null||r.return===null){_e=1,oa=t,Me=null;break}e:{var i=e,l=r.return,o=r,c=t;if(t=He,o.flags|=32768,c!==null&&typeof c=="object"&&typeof c.then=="function"){var d=c,f=o,u=f.tag;if(!(f.mode&1)&&(u===0||u===11||u===15)){var x=f.alternate;x?(f.updateQueue=x.updateQueue,f.memoizedState=x.memoizedState,f.lanes=x.lanes):(f.updateQueue=null,f.memoizedState=null)}var y=Gd(l);if(y!==null){y.flags&=-257,Xd(y,l,o,i,t),y.mode&1&&Yd(i,d,t),t=y,c=d;var w=t.updateQueue;if(w===null){var v=new Set;v.add(c),t.updateQueue=v}else w.add(c);break e}else{if(!(t&1)){Yd(i,d,t),Ac();break e}c=Error($(426))}}else if(je&&o.mode&1){var b=Gd(l);if(b!==null){!(b.flags&65536)&&(b.flags|=256),Xd(b,l,o,i,t),vc(as(c,o));break e}}i=c=as(c,o),_e!==4&&(_e=2),Ws===null?Ws=[i]:Ws.push(i),i=l;do{switch(i.tag){case 3:i.flags|=65536,t&=-t,i.lanes|=t;var m=Rf(i,c,t);Bd(i,m);break e;case 1:o=c;var p=i.type,g=i.stateNode;if(!(i.flags&128)&&(typeof p.getDerivedStateFromError=="function"||g!==null&&typeof g.componentDidCatch=="function"&&(Ar===null||!Ar.has(g)))){i.flags|=65536,t&=-t,i.lanes|=t;var j=If(i,o,t);Bd(i,j);break e}}i=i.return}while(i!==null)}qf(r)}catch(S){t=S,Me===r&&r!==null&&(Me=r=r.return);continue}break}while(!0)}function Jf(){var e=Ti.current;return Ti.current=Ei,e===null?Ei:e}function Ac(){(_e===0||_e===3||_e===2)&&(_e=4),Ue===null||!(fn&268435455)&&!(Ki&268435455)||Pr(Ue,He)}function Di(e,t){var r=ce;ce|=2;var s=Jf();(Ue!==e||He!==t)&&(or=null,ln(e,t));do try{Mg();break}catch(a){Xf(e,a)}while(!0);if(wc(),ce=r,Ti.current=s,Me!==null)throw Error($(261));return Ue=null,He=0,_e}function Mg(){for(;Me!==null;)Zf(Me)}function Rg(){for(;Me!==null&&!sx();)Zf(Me)}function Zf(e){var t=tm(e.alternate,e,xt);e.memoizedProps=e.pendingProps,t===null?qf(e):Me=t,Rc.current=null}function qf(e){var t=e;do{var r=t.alternate;if(e=t.return,t.flags&32768){if(r=Cg(r,t),r!==null){r.flags&=32767,Me=r;return}if(e!==null)e.flags|=32768,e.subtreeFlags=0,e.deletions=null;else{_e=6,Me=null;return}}else if(r=Sg(r,t,xt),r!==null){Me=r;return}if(t=t.sibling,t!==null){Me=t;return}Me=t=e}while(t!==null);_e===0&&(_e=5)}function en(e,t,r){var s=fe,a=Tt.transition;try{Tt.transition=null,fe=1,Ig(e,t,r,s)}finally{Tt.transition=a,fe=s}return null}function Ig(e,t,r,s){do Gn();while(Dr!==null);if(ce&6)throw Error($(327));r=e.finishedWork;var a=e.finishedLanes;if(r===null)return null;if(e.finishedWork=null,e.finishedLanes=0,r===e.current)throw Error($(177));e.callbackNode=null,e.callbackPriority=0;var i=r.lanes|r.childLanes;if(mx(e,i),e===Ue&&(Me=Ue=null,He=0),!(r.subtreeFlags&2064)&&!(r.flags&2064)||Fa||(Fa=!0,rm(hi,function(){return Gn(),null})),i=(r.flags&15990)!==0,r.subtreeFlags&15990||i){i=Tt.transition,Tt.transition=null;var l=fe;fe=1;var o=ce;ce|=4,Rc.current=null,Tg(e,r),Qf(r,e),eg(po),mi=!!mo,po=mo=null,e.current=r,Pg(r),ax(),ce=o,fe=l,Tt.transition=i}else e.current=r;if(Fa&&(Fa=!1,Dr=e,zi=a),i=e.pendingLanes,i===0&&(Ar=null),ox(r.stateNode),mt(e,De()),t!==null)for(s=e.onRecoverableError,r=0;r<t.length;r++)a=t[r],s(a.value,{componentStack:a.stack,digest:a.digest});if(Pi)throw Pi=!1,e=Lo,Lo=null,e;return zi&1&&e.tag!==0&&Gn(),i=e.pendingLanes,i&1?e===_o?Hs++:(Hs=0,_o=e):Hs=0,Gr(),null}function Gn(){if(Dr!==null){var e=Mh(zi),t=Tt.transition,r=fe;try{if(Tt.transition=null,fe=16>e?16:e,Dr===null)var s=!1;else{if(e=Dr,Dr=null,zi=0,ce&6)throw Error($(331));var a=ce;for(ce|=4,K=e.current;K!==null;){var i=K,l=i.child;if(K.flags&16){var o=i.deletions;if(o!==null){for(var c=0;c<o.length;c++){var d=o[c];for(K=d;K!==null;){var f=K;switch(f.tag){case 0:case 11:case 15:Vs(8,f,i)}var u=f.child;if(u!==null)u.return=f,K=u;else for(;K!==null;){f=K;var x=f.sibling,y=f.return;if(Wf(f),f===d){K=null;break}if(x!==null){x.return=y,K=x;break}K=y}}}var w=i.alternate;if(w!==null){var v=w.child;if(v!==null){w.child=null;do{var b=v.sibling;v.sibling=null,v=b}while(v!==null)}}K=i}}if(i.subtreeFlags&2064&&l!==null)l.return=i,K=l;else e:for(;K!==null;){if(i=K,i.flags&2048)switch(i.tag){case 0:case 11:case 15:Vs(9,i,i.return)}var m=i.sibling;if(m!==null){m.return=i.return,K=m;break e}K=i.return}}var p=e.current;for(K=p;K!==null;){l=K;var g=l.child;if(l.subtreeFlags&2064&&g!==null)g.return=l,K=g;else e:for(l=p;K!==null;){if(o=K,o.flags&2048)try{switch(o.tag){case 0:case 11:case 15:Hi(9,o)}}catch(S){Te(o,o.return,S)}if(o===l){K=null;break e}var j=o.sibling;if(j!==null){j.return=o.return,K=j;break e}K=o.return}}if(ce=a,Gr(),er&&typeof er.onPostCommitFiberRoot=="function")try{er.onPostCommitFiberRoot(Oi,e)}catch{}s=!0}return s}finally{fe=r,Tt.transition=t}}return!1}function cu(e,t,r){t=as(r,t),t=Rf(e,t,1),e=Or(e,t,1),t=st(),e!==null&&(pa(e,1,t),mt(e,t))}function Te(e,t,r){if(e.tag===3)cu(e,e,r);else for(;t!==null;){if(t.tag===3){cu(t,e,r);break}else if(t.tag===1){var s=t.stateNode;if(typeof t.type.getDerivedStateFromError=="function"||typeof s.componentDidCatch=="function"&&(Ar===null||!Ar.has(s))){e=as(r,e),e=If(t,e,1),t=Or(t,e,1),e=st(),t!==null&&(pa(t,1,e),mt(t,e));break}}t=t.return}}function Lg(e,t,r){var s=e.pingCache;s!==null&&s.delete(t),t=st(),e.pingedLanes|=e.suspendedLanes&r,Ue===e&&(He&r)===r&&(_e===4||_e===3&&(He&130023424)===He&&500>De()-Lc?ln(e,0):Ic|=r),mt(e,t)}function em(e,t){t===0&&(e.mode&1?(t=za,za<<=1,!(za&130023424)&&(za=4194304)):t=1);var r=st();e=xr(e,t),e!==null&&(pa(e,t,r),mt(e,r))}function _g(e){var t=e.memoizedState,r=0;t!==null&&(r=t.retryLane),em(e,r)}function Og(e,t){var r=0;switch(e.tag){case 13:var s=e.stateNode,a=e.memoizedState;a!==null&&(r=a.retryLane);break;case 19:s=e.stateNode;break;default:throw Error($(314))}s!==null&&s.delete(t),em(e,r)}var tm;tm=function(e,t,r){if(e!==null)if(e.memoizedProps!==t.pendingProps||ht.current)dt=!0;else{if(!(e.lanes&r)&&!(t.flags&128))return dt=!1,kg(e,t,r);dt=!!(e.flags&131072)}else dt=!1,je&&t.flags&1048576&&sf(t,bi,t.index);switch(t.lanes=0,t.tag){case 2:var s=t.type;ri(e,t),e=t.pendingProps;var a=ts(t,tt.current);Yn(t,r),a=Tc(null,t,s,e,a,r);var i=Pc();return t.flags|=1,typeof a=="object"&&a!==null&&typeof a.render=="function"&&a.$$typeof===void 0?(t.tag=1,t.memoizedState=null,t.updateQueue=null,ft(s)?(i=!0,yi(t)):i=!1,t.memoizedState=a.state!==null&&a.state!==void 0?a.state:null,Nc(t),a.updater=Wi,t.stateNode=a,a._reactInternals=t,ko(t,s,e,r),t=Eo(null,t,s,!0,i,r)):(t.tag=0,je&&i&&xc(t),nt(null,t,a,r),t=t.child),t;case 16:s=t.elementType;e:{switch(ri(e,t),e=t.pendingProps,a=s._init,s=a(s._payload),t.type=s,a=t.tag=$g(s),e=It(s,e),a){case 0:t=Co(null,t,s,e,r);break e;case 1:t=qd(null,t,s,e,r);break e;case 11:t=Jd(null,t,s,e,r);break e;case 14:t=Zd(null,t,s,It(s.type,e),r);break e}throw Error($(306,s,""))}return t;case 0:return s=t.type,a=t.pendingProps,a=t.elementType===s?a:It(s,a),Co(e,t,s,a,r);case 1:return s=t.type,a=t.pendingProps,a=t.elementType===s?a:It(s,a),qd(e,t,s,a,r);case 3:e:{if(Af(t),e===null)throw Error($(387));s=t.pendingProps,i=t.memoizedState,a=i.element,uf(e,t),ki(t,s,null,r);var l=t.memoizedState;if(s=l.element,i.isDehydrated)if(i={element:s,isDehydrated:!1,cache:l.cache,pendingSuspenseBoundaries:l.pendingSuspenseBoundaries,transitions:l.transitions},t.updateQueue.baseState=i,t.memoizedState=i,t.flags&256){a=as(Error($(423)),t),t=eu(e,t,s,r,a);break e}else if(s!==a){a=as(Error($(424)),t),t=eu(e,t,s,r,a);break e}else for(gt=_r(t.stateNode.containerInfo.firstChild),vt=t,je=!0,Ot=null,r=cf(t,null,s,r),t.child=r;r;)r.flags=r.flags&-3|4096,r=r.sibling;else{if(rs(),s===a){t=gr(e,t,r);break e}nt(e,t,s,r)}t=t.child}return t;case 5:return hf(t),e===null&&bo(t),s=t.type,a=t.pendingProps,i=e!==null?e.memoizedProps:null,l=a.children,xo(s,a)?l=null:i!==null&&xo(s,i)&&(t.flags|=32),Of(e,t),nt(e,t,l,r),t.child;case 6:return e===null&&bo(t),null;case 13:return $f(e,t,r);case 4:return kc(t,t.stateNode.containerInfo),s=t.pendingProps,e===null?t.child=ns(t,null,s,r):nt(e,t,s,r),t.child;case 11:return s=t.type,a=t.pendingProps,a=t.elementType===s?a:It(s,a),Jd(e,t,s,a,r);case 7:return nt(e,t,t.pendingProps,r),t.child;case 8:return nt(e,t,t.pendingProps.children,r),t.child;case 12:return nt(e,t,t.pendingProps.children,r),t.child;case 10:e:{if(s=t.type._context,a=t.pendingProps,i=t.memoizedProps,l=a.value,ge(ji,s._currentValue),s._currentValue=l,i!==null)if(Ft(i.value,l)){if(i.children===a.children&&!ht.current){t=gr(e,t,r);break e}}else for(i=t.child,i!==null&&(i.return=t);i!==null;){var o=i.dependencies;if(o!==null){l=i.child;for(var c=o.firstContext;c!==null;){if(c.context===s){if(i.tag===1){c=hr(-1,r&-r),c.tag=2;var d=i.updateQueue;if(d!==null){d=d.shared;var f=d.pending;f===null?c.next=c:(c.next=f.next,f.next=c),d.pending=c}}i.lanes|=r,c=i.alternate,c!==null&&(c.lanes|=r),jo(i.return,r,t),o.lanes|=r;break}c=c.next}}else if(i.tag===10)l=i.type===t.type?null:i.child;else if(i.tag===18){if(l=i.return,l===null)throw Error($(341));l.lanes|=r,o=l.alternate,o!==null&&(o.lanes|=r),jo(l,r,t),l=i.sibling}else l=i.child;if(l!==null)l.return=i;else for(l=i;l!==null;){if(l===t){l=null;break}if(i=l.sibling,i!==null){i.return=l.return,l=i;break}l=l.return}i=l}nt(e,t,a.children,r),t=t.child}return t;case 9:return a=t.type,s=t.pendingProps.children,Yn(t,r),a=Pt(a),s=s(a),t.flags|=1,nt(e,t,s,r),t.child;case 14:return s=t.type,a=It(s,t.pendingProps),a=It(s.type,a),Zd(e,t,s,a,r);case 15:return Lf(e,t,t.type,t.pendingProps,r);case 17:return s=t.type,a=t.pendingProps,a=t.elementType===s?a:It(s,a),ri(e,t),t.tag=1,ft(s)?(e=!0,yi(t)):e=!1,Yn(t,r),Mf(t,s,a),ko(t,s,a,r),Eo(null,t,s,!0,e,r);case 19:return Ff(e,t,r);case 22:return _f(e,t,r)}throw Error($(156,t.tag))};function rm(e,t){return Th(e,t)}function Ag(e,t,r,s){this.tag=e,this.key=r,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=s,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Ct(e,t,r,s){return new Ag(e,t,r,s)}function $c(e){return e=e.prototype,!(!e||!e.isReactComponent)}function $g(e){if(typeof e=="function")return $c(e)?1:0;if(e!=null){if(e=e.$$typeof,e===sc)return 11;if(e===ac)return 14}return 2}function Fr(e,t){var r=e.alternate;return r===null?(r=Ct(e.tag,t,e.key,e.mode),r.elementType=e.elementType,r.type=e.type,r.stateNode=e.stateNode,r.alternate=e,e.alternate=r):(r.pendingProps=t,r.type=e.type,r.flags=0,r.subtreeFlags=0,r.deletions=null),r.flags=e.flags&14680064,r.childLanes=e.childLanes,r.lanes=e.lanes,r.child=e.child,r.memoizedProps=e.memoizedProps,r.memoizedState=e.memoizedState,r.updateQueue=e.updateQueue,t=e.dependencies,r.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},r.sibling=e.sibling,r.index=e.index,r.ref=e.ref,r}function ai(e,t,r,s,a,i){var l=2;if(s=e,typeof e=="function")$c(e)&&(l=1);else if(typeof e=="string")l=5;else e:switch(e){case Mn:return on(r.children,a,i,t);case nc:l=8,a|=8;break;case Ql:return e=Ct(12,r,t,a|2),e.elementType=Ql,e.lanes=i,e;case Yl:return e=Ct(13,r,t,a),e.elementType=Yl,e.lanes=i,e;case Gl:return e=Ct(19,r,t,a),e.elementType=Gl,e.lanes=i,e;case uh:return Qi(r,a,i,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case ch:l=10;break e;case dh:l=9;break e;case sc:l=11;break e;case ac:l=14;break e;case Cr:l=16,s=null;break e}throw Error($(130,e==null?e:typeof e,""))}return t=Ct(l,r,t,a),t.elementType=e,t.type=s,t.lanes=i,t}function on(e,t,r,s){return e=Ct(7,e,s,t),e.lanes=r,e}function Qi(e,t,r,s){return e=Ct(22,e,s,t),e.elementType=uh,e.lanes=r,e.stateNode={isHidden:!1},e}function zl(e,t,r){return e=Ct(6,e,null,t),e.lanes=r,e}function Dl(e,t,r){return t=Ct(4,e.children!==null?e.children:[],e.key,t),t.lanes=r,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function Fg(e,t,r,s,a){this.tag=t,this.containerInfo=e,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=ul(0),this.expirationTimes=ul(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=ul(0),this.identifierPrefix=s,this.onRecoverableError=a,this.mutableSourceEagerHydrationData=null}function Fc(e,t,r,s,a,i,l,o,c){return e=new Fg(e,t,r,o,c),t===1?(t=1,i===!0&&(t|=8)):t=0,i=Ct(3,null,null,t),e.current=i,i.stateNode=e,i.memoizedState={element:s,isDehydrated:r,cache:null,transitions:null,pendingSuspenseBoundaries:null},Nc(i),e}function Ug(e,t,r){var s=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:Dn,key:s==null?null:""+s,children:e,containerInfo:t,implementation:r}}function nm(e){if(!e)return Hr;e=e._reactInternals;e:{if(wn(e)!==e||e.tag!==1)throw Error($(170));var t=e;do{switch(t.tag){case 3:t=t.stateNode.context;break e;case 1:if(ft(t.type)){t=t.stateNode.__reactInternalMemoizedMergedChildContext;break e}}t=t.return}while(t!==null);throw Error($(171))}if(e.tag===1){var r=e.type;if(ft(r))return rf(e,r,t)}return t}function sm(e,t,r,s,a,i,l,o,c){return e=Fc(r,s,!0,e,a,i,l,o,c),e.context=nm(null),r=e.current,s=st(),a=$r(r),i=hr(s,a),i.callback=t??null,Or(r,i,a),e.current.lanes=a,pa(e,a,s),mt(e,s),e}function Yi(e,t,r,s){var a=t.current,i=st(),l=$r(a);return r=nm(r),t.context===null?t.context=r:t.pendingContext=r,t=hr(i,l),t.payload={element:e},s=s===void 0?null:s,s!==null&&(t.callback=s),e=Or(a,t,l),e!==null&&($t(e,a,l,i),qa(e,a,l)),l}function Mi(e){if(e=e.current,!e.child)return null;switch(e.child.tag){case 5:return e.child.stateNode;default:return e.child.stateNode}}function du(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var r=e.retryLane;e.retryLane=r!==0&&r<t?r:t}}function Uc(e,t){du(e,t),(e=e.alternate)&&du(e,t)}function Bg(){return null}var am=typeof reportError=="function"?reportError:function(e){console.error(e)};function Bc(e){this._internalRoot=e}Gi.prototype.render=Bc.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error($(409));Yi(e,t,null,null)};Gi.prototype.unmount=Bc.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;mn(function(){Yi(null,e,null,null)}),t[pr]=null}};function Gi(e){this._internalRoot=e}Gi.prototype.unstable_scheduleHydration=function(e){if(e){var t=Lh();e={blockedOn:null,target:e,priority:t};for(var r=0;r<Tr.length&&t!==0&&t<Tr[r].priority;r++);Tr.splice(r,0,e),r===0&&Oh(e)}};function Vc(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function Xi(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11&&(e.nodeType!==8||e.nodeValue!==" react-mount-point-unstable "))}function uu(){}function Vg(e,t,r,s,a){if(a){if(typeof s=="function"){var i=s;s=function(){var d=Mi(l);i.call(d)}}var l=sm(t,s,e,0,null,!1,!1,"",uu);return e._reactRootContainer=l,e[pr]=l.current,ea(e.nodeType===8?e.parentNode:e),mn(),l}for(;a=e.lastChild;)e.removeChild(a);if(typeof s=="function"){var o=s;s=function(){var d=Mi(c);o.call(d)}}var c=Fc(e,0,!1,null,null,!1,!1,"",uu);return e._reactRootContainer=c,e[pr]=c.current,ea(e.nodeType===8?e.parentNode:e),mn(function(){Yi(t,c,r,s)}),c}function Ji(e,t,r,s,a){var i=r._reactRootContainer;if(i){var l=i;if(typeof a=="function"){var o=a;a=function(){var c=Mi(l);o.call(c)}}Yi(t,l,e,a)}else l=Vg(r,t,e,a,s);return Mi(l)}Rh=function(e){switch(e.tag){case 3:var t=e.stateNode;if(t.current.memoizedState.isDehydrated){var r=Is(t.pendingLanes);r!==0&&(oc(t,r|1),mt(t,De()),!(ce&6)&&(is=De()+500,Gr()))}break;case 13:mn(function(){var s=xr(e,1);if(s!==null){var a=st();$t(s,e,1,a)}}),Uc(e,1)}};cc=function(e){if(e.tag===13){var t=xr(e,134217728);if(t!==null){var r=st();$t(t,e,134217728,r)}Uc(e,134217728)}};Ih=function(e){if(e.tag===13){var t=$r(e),r=xr(e,t);if(r!==null){var s=st();$t(r,e,t,s)}Uc(e,t)}};Lh=function(){return fe};_h=function(e,t){var r=fe;try{return fe=e,t()}finally{fe=r}};ao=function(e,t,r){switch(t){case"input":if(Zl(e,r),t=r.name,r.type==="radio"&&t!=null){for(r=e;r.parentNode;)r=r.parentNode;for(r=r.querySelectorAll("input[name="+JSON.stringify(""+t)+'][type="radio"]'),t=0;t<r.length;t++){var s=r[t];if(s!==e&&s.form===e.form){var a=Ui(s);if(!a)throw Error($(90));fh(s),Zl(s,a)}}}break;case"textarea":ph(e,r);break;case"select":t=r.value,t!=null&&Wn(e,!!r.multiple,t,!1)}};jh=_c;Nh=mn;var Wg={usingClientEntryPoint:!1,Events:[ga,_n,Ui,wh,bh,_c]},Cs={findFiberByHostInstance:nn,bundleType:0,version:"18.3.1",rendererPackageName:"react-dom"},Hg={bundleType:Cs.bundleType,version:Cs.version,rendererPackageName:Cs.rendererPackageName,rendererConfig:Cs.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setErrorHandler:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:vr.ReactCurrentDispatcher,findHostInstanceByFiber:function(e){return e=Ch(e),e===null?null:e.stateNode},findFiberByHostInstance:Cs.findFiberByHostInstance||Bg,findHostInstancesForRefresh:null,scheduleRefresh:null,scheduleRoot:null,setRefreshHandler:null,getCurrentFiber:null,reconcilerVersion:"18.3.1-next-f1338f8080-20240426"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var Ua=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Ua.isDisabled&&Ua.supportsFiber)try{Oi=Ua.inject(Hg),er=Ua}catch{}}wt.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=Wg;wt.createPortal=function(e,t){var r=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!Vc(t))throw Error($(200));return Ug(e,t,null,r)};wt.createRoot=function(e,t){if(!Vc(e))throw Error($(299));var r=!1,s="",a=am;return t!=null&&(t.unstable_strictMode===!0&&(r=!0),t.identifierPrefix!==void 0&&(s=t.identifierPrefix),t.onRecoverableError!==void 0&&(a=t.onRecoverableError)),t=Fc(e,1,!1,null,null,r,!1,s,a),e[pr]=t.current,ea(e.nodeType===8?e.parentNode:e),new Bc(t)};wt.findDOMNode=function(e){if(e==null)return null;if(e.nodeType===1)return e;var t=e._reactInternals;if(t===void 0)throw typeof e.render=="function"?Error($(188)):(e=Object.keys(e).join(","),Error($(268,e)));return e=Ch(t),e=e===null?null:e.stateNode,e};wt.flushSync=function(e){return mn(e)};wt.hydrate=function(e,t,r){if(!Xi(t))throw Error($(200));return Ji(null,e,t,!0,r)};wt.hydrateRoot=function(e,t,r){if(!Vc(e))throw Error($(405));var s=r!=null&&r.hydratedSources||null,a=!1,i="",l=am;if(r!=null&&(r.unstable_strictMode===!0&&(a=!0),r.identifierPrefix!==void 0&&(i=r.identifierPrefix),r.onRecoverableError!==void 0&&(l=r.onRecoverableError)),t=sm(t,null,e,1,r??null,a,!1,i,l),e[pr]=t.current,ea(e),s)for(e=0;e<s.length;e++)r=s[e],a=r._getVersion,a=a(r._source),t.mutableSourceEagerHydrationData==null?t.mutableSourceEagerHydrationData=[r,a]:t.mutableSourceEagerHydrationData.push(r,a);return new Gi(t)};wt.render=function(e,t,r){if(!Xi(t))throw Error($(200));return Ji(null,e,t,!1,r)};wt.unmountComponentAtNode=function(e){if(!Xi(e))throw Error($(40));return e._reactRootContainer?(mn(function(){Ji(null,null,e,!1,function(){e._reactRootContainer=null,e[pr]=null})}),!0):!1};wt.unstable_batchedUpdates=_c;wt.unstable_renderSubtreeIntoContainer=function(e,t,r,s){if(!Xi(r))throw Error($(200));if(e==null||e._reactInternals===void 0)throw Error($(38));return Ji(e,t,r,!1,s)};wt.version="18.3.1-next-f1338f8080-20240426";function im(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(im)}catch(e){console.error(e)}}im(),ah.exports=wt;var Wc=ah.exports;const lm=Qu(Wc);var hu=Wc;Hl.createRoot=hu.createRoot,Hl.hydrateRoot=hu.hydrateRoot;/**
41
- * @remix-run/router v1.23.0
42
- *
43
- * Copyright (c) Remix Software Inc.
44
- *
45
- * This source code is licensed under the MIT license found in the
46
- * LICENSE.md file in the root directory of this source tree.
47
- *
48
- * @license MIT
49
- */function ca(){return ca=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var s in r)Object.prototype.hasOwnProperty.call(r,s)&&(e[s]=r[s])}return e},ca.apply(this,arguments)}var Mr;(function(e){e.Pop="POP",e.Push="PUSH",e.Replace="REPLACE"})(Mr||(Mr={}));const fu="popstate";function Kg(e){e===void 0&&(e={});function t(s,a){let{pathname:i,search:l,hash:o}=s.location;return $o("",{pathname:i,search:l,hash:o},a.state&&a.state.usr||null,a.state&&a.state.key||"default")}function r(s,a){return typeof a=="string"?a:Ri(a)}return Yg(t,r,null,e)}function Re(e,t){if(e===!1||e===null||typeof e>"u")throw new Error(t)}function om(e,t){if(!e){typeof console<"u"&&console.warn(t);try{throw new Error(t)}catch{}}}function Qg(){return Math.random().toString(36).substr(2,8)}function mu(e,t){return{usr:e.state,key:e.key,idx:t}}function $o(e,t,r,s){return r===void 0&&(r=null),ca({pathname:typeof e=="string"?e:e.pathname,search:"",hash:""},typeof t=="string"?ps(t):t,{state:r,key:t&&t.key||s||Qg()})}function Ri(e){let{pathname:t="/",search:r="",hash:s=""}=e;return r&&r!=="?"&&(t+=r.charAt(0)==="?"?r:"?"+r),s&&s!=="#"&&(t+=s.charAt(0)==="#"?s:"#"+s),t}function ps(e){let t={};if(e){let r=e.indexOf("#");r>=0&&(t.hash=e.substr(r),e=e.substr(0,r));let s=e.indexOf("?");s>=0&&(t.search=e.substr(s),e=e.substr(0,s)),e&&(t.pathname=e)}return t}function Yg(e,t,r,s){s===void 0&&(s={});let{window:a=document.defaultView,v5Compat:i=!1}=s,l=a.history,o=Mr.Pop,c=null,d=f();d==null&&(d=0,l.replaceState(ca({},l.state,{idx:d}),""));function f(){return(l.state||{idx:null}).idx}function u(){o=Mr.Pop;let b=f(),m=b==null?null:b-d;d=b,c&&c({action:o,location:v.location,delta:m})}function x(b,m){o=Mr.Push;let p=$o(v.location,b,m);d=f()+1;let g=mu(p,d),j=v.createHref(p);try{l.pushState(g,"",j)}catch(S){if(S instanceof DOMException&&S.name==="DataCloneError")throw S;a.location.assign(j)}i&&c&&c({action:o,location:v.location,delta:1})}function y(b,m){o=Mr.Replace;let p=$o(v.location,b,m);d=f();let g=mu(p,d),j=v.createHref(p);l.replaceState(g,"",j),i&&c&&c({action:o,location:v.location,delta:0})}function w(b){let m=a.location.origin!=="null"?a.location.origin:a.location.href,p=typeof b=="string"?b:Ri(b);return p=p.replace(/ $/,"%20"),Re(m,"No window.location.(origin|href) available to create URL for href: "+p),new URL(p,m)}let v={get action(){return o},get location(){return e(a,l)},listen(b){if(c)throw new Error("A history only accepts one active listener");return a.addEventListener(fu,u),c=b,()=>{a.removeEventListener(fu,u),c=null}},createHref(b){return t(a,b)},createURL:w,encodeLocation(b){let m=w(b);return{pathname:m.pathname,search:m.search,hash:m.hash}},push:x,replace:y,go(b){return l.go(b)}};return v}var pu;(function(e){e.data="data",e.deferred="deferred",e.redirect="redirect",e.error="error"})(pu||(pu={}));function Gg(e,t,r){return r===void 0&&(r="/"),Xg(e,t,r)}function Xg(e,t,r,s){let a=typeof t=="string"?ps(t):t,i=Hc(a.pathname||"/",r);if(i==null)return null;let l=cm(e);Jg(l);let o=null;for(let c=0;o==null&&c<l.length;++c){let d=cv(i);o=iv(l[c],d)}return o}function cm(e,t,r,s){t===void 0&&(t=[]),r===void 0&&(r=[]),s===void 0&&(s="");let a=(i,l,o)=>{let c={relativePath:o===void 0?i.path||"":o,caseSensitive:i.caseSensitive===!0,childrenIndex:l,route:i};c.relativePath.startsWith("/")&&(Re(c.relativePath.startsWith(s),'Absolute route path "'+c.relativePath+'" nested under path '+('"'+s+'" is not valid. An absolute child route path ')+"must start with the combined path of all its parent routes."),c.relativePath=c.relativePath.slice(s.length));let d=Ur([s,c.relativePath]),f=r.concat(c);i.children&&i.children.length>0&&(Re(i.index!==!0,"Index routes must not have child routes. Please remove "+('all child routes from route path "'+d+'".')),cm(i.children,t,f,d)),!(i.path==null&&!i.index)&&t.push({path:d,score:sv(d,i.index),routesMeta:f})};return e.forEach((i,l)=>{var o;if(i.path===""||!((o=i.path)!=null&&o.includes("?")))a(i,l);else for(let c of dm(i.path))a(i,l,c)}),t}function dm(e){let t=e.split("/");if(t.length===0)return[];let[r,...s]=t,a=r.endsWith("?"),i=r.replace(/\?$/,"");if(s.length===0)return a?[i,""]:[i];let l=dm(s.join("/")),o=[];return o.push(...l.map(c=>c===""?i:[i,c].join("/"))),a&&o.push(...l),o.map(c=>e.startsWith("/")&&c===""?"/":c)}function Jg(e){e.sort((t,r)=>t.score!==r.score?r.score-t.score:av(t.routesMeta.map(s=>s.childrenIndex),r.routesMeta.map(s=>s.childrenIndex)))}const Zg=/^:[\w-]+$/,qg=3,ev=2,tv=1,rv=10,nv=-2,xu=e=>e==="*";function sv(e,t){let r=e.split("/"),s=r.length;return r.some(xu)&&(s+=nv),t&&(s+=ev),r.filter(a=>!xu(a)).reduce((a,i)=>a+(Zg.test(i)?qg:i===""?tv:rv),s)}function av(e,t){return e.length===t.length&&e.slice(0,-1).every((s,a)=>s===t[a])?e[e.length-1]-t[t.length-1]:0}function iv(e,t,r){let{routesMeta:s}=e,a={},i="/",l=[];for(let o=0;o<s.length;++o){let c=s[o],d=o===s.length-1,f=i==="/"?t:t.slice(i.length)||"/",u=lv({path:c.relativePath,caseSensitive:c.caseSensitive,end:d},f),x=c.route;if(!u)return null;Object.assign(a,u.params),l.push({params:a,pathname:Ur([i,u.pathname]),pathnameBase:fv(Ur([i,u.pathnameBase])),route:x}),u.pathnameBase!=="/"&&(i=Ur([i,u.pathnameBase]))}return l}function lv(e,t){typeof e=="string"&&(e={path:e,caseSensitive:!1,end:!0});let[r,s]=ov(e.path,e.caseSensitive,e.end),a=t.match(r);if(!a)return null;let i=a[0],l=i.replace(/(.)\/+$/,"$1"),o=a.slice(1);return{params:s.reduce((d,f,u)=>{let{paramName:x,isOptional:y}=f;if(x==="*"){let v=o[u]||"";l=i.slice(0,i.length-v.length).replace(/(.)\/+$/,"$1")}const w=o[u];return y&&!w?d[x]=void 0:d[x]=(w||"").replace(/%2F/g,"/"),d},{}),pathname:i,pathnameBase:l,pattern:e}}function ov(e,t,r){t===void 0&&(t=!1),r===void 0&&(r=!0),om(e==="*"||!e.endsWith("*")||e.endsWith("/*"),'Route path "'+e+'" will be treated as if it were '+('"'+e.replace(/\*$/,"/*")+'" because the `*` character must ')+"always follow a `/` in the pattern. To get rid of this warning, "+('please change the route path to "'+e.replace(/\*$/,"/*")+'".'));let s=[],a="^"+e.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(l,o,c)=>(s.push({paramName:o,isOptional:c!=null}),c?"/?([^\\/]+)?":"/([^\\/]+)"));return e.endsWith("*")?(s.push({paramName:"*"}),a+=e==="*"||e==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):r?a+="\\/*$":e!==""&&e!=="/"&&(a+="(?:(?=\\/|$))"),[new RegExp(a,t?void 0:"i"),s]}function cv(e){try{return e.split("/").map(t=>decodeURIComponent(t).replace(/\//g,"%2F")).join("/")}catch(t){return om(!1,'The URL path "'+e+'" could not be decoded because it is is a malformed URL segment. This is probably due to a bad percent '+("encoding ("+t+").")),e}}function Hc(e,t){if(t==="/")return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let r=t.endsWith("/")?t.length-1:t.length,s=e.charAt(r);return s&&s!=="/"?null:e.slice(r)||"/"}function dv(e,t){t===void 0&&(t="/");let{pathname:r,search:s="",hash:a=""}=typeof e=="string"?ps(e):e;return{pathname:r?r.startsWith("/")?r:uv(r,t):t,search:mv(s),hash:pv(a)}}function uv(e,t){let r=t.replace(/\/+$/,"").split("/");return e.split("/").forEach(a=>{a===".."?r.length>1&&r.pop():a!=="."&&r.push(a)}),r.length>1?r.join("/"):"/"}function Ml(e,t,r,s){return"Cannot include a '"+e+"' character in a manually specified "+("`to."+t+"` field ["+JSON.stringify(s)+"]. Please separate it out to the ")+("`to."+r+"` field. Alternatively you may provide the full path as ")+'a string in <Link to="..."> and the router will parse it for you.'}function hv(e){return e.filter((t,r)=>r===0||t.route.path&&t.route.path.length>0)}function um(e,t){let r=hv(e);return t?r.map((s,a)=>a===r.length-1?s.pathname:s.pathnameBase):r.map(s=>s.pathnameBase)}function hm(e,t,r,s){s===void 0&&(s=!1);let a;typeof e=="string"?a=ps(e):(a=ca({},e),Re(!a.pathname||!a.pathname.includes("?"),Ml("?","pathname","search",a)),Re(!a.pathname||!a.pathname.includes("#"),Ml("#","pathname","hash",a)),Re(!a.search||!a.search.includes("#"),Ml("#","search","hash",a)));let i=e===""||a.pathname==="",l=i?"/":a.pathname,o;if(l==null)o=r;else{let u=t.length-1;if(!s&&l.startsWith("..")){let x=l.split("/");for(;x[0]==="..";)x.shift(),u-=1;a.pathname=x.join("/")}o=u>=0?t[u]:"/"}let c=dv(a,o),d=l&&l!=="/"&&l.endsWith("/"),f=(i||l===".")&&r.endsWith("/");return!c.pathname.endsWith("/")&&(d||f)&&(c.pathname+="/"),c}const Ur=e=>e.join("/").replace(/\/\/+/g,"/"),fv=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),mv=e=>!e||e==="?"?"":e.startsWith("?")?e:"?"+e,pv=e=>!e||e==="#"?"":e.startsWith("#")?e:"#"+e;function xv(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.internal=="boolean"&&"data"in e}const fm=["post","put","patch","delete"];new Set(fm);const gv=["get",...fm];new Set(gv);/**
50
- * React Router v6.30.1
51
- *
52
- * Copyright (c) Remix Software Inc.
53
- *
54
- * This source code is licensed under the MIT license found in the
55
- * LICENSE.md file in the root directory of this source tree.
56
- *
57
- * @license MIT
58
- */function da(){return da=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var s in r)Object.prototype.hasOwnProperty.call(r,s)&&(e[s]=r[s])}return e},da.apply(this,arguments)}const Kc=h.createContext(null),vv=h.createContext(null),bn=h.createContext(null),Zi=h.createContext(null),Xr=h.createContext({outlet:null,matches:[],isDataRoute:!1}),mm=h.createContext(null);function yv(e,t){let{relative:r}=t===void 0?{}:t;ya()||Re(!1);let{basename:s,navigator:a}=h.useContext(bn),{hash:i,pathname:l,search:o}=gm(e,{relative:r}),c=l;return s!=="/"&&(c=l==="/"?s:Ur([s,l])),a.createHref({pathname:c,search:o,hash:i})}function ya(){return h.useContext(Zi)!=null}function wa(){return ya()||Re(!1),h.useContext(Zi).location}function pm(e){h.useContext(bn).static||h.useLayoutEffect(e)}function qi(){let{isDataRoute:e}=h.useContext(Xr);return e?Mv():wv()}function wv(){ya()||Re(!1);let e=h.useContext(Kc),{basename:t,future:r,navigator:s}=h.useContext(bn),{matches:a}=h.useContext(Xr),{pathname:i}=wa(),l=JSON.stringify(um(a,r.v7_relativeSplatPath)),o=h.useRef(!1);return pm(()=>{o.current=!0}),h.useCallback(function(d,f){if(f===void 0&&(f={}),!o.current)return;if(typeof d=="number"){s.go(d);return}let u=hm(d,JSON.parse(l),i,f.relative==="path");e==null&&t!=="/"&&(u.pathname=u.pathname==="/"?t:Ur([t,u.pathname])),(f.replace?s.replace:s.push)(u,f.state,f)},[t,s,l,i,e])}function xm(){let{matches:e}=h.useContext(Xr),t=e[e.length-1];return t?t.params:{}}function gm(e,t){let{relative:r}=t===void 0?{}:t,{future:s}=h.useContext(bn),{matches:a}=h.useContext(Xr),{pathname:i}=wa(),l=JSON.stringify(um(a,s.v7_relativeSplatPath));return h.useMemo(()=>hm(e,JSON.parse(l),i,r==="path"),[e,l,i,r])}function bv(e,t){return jv(e,t)}function jv(e,t,r,s){ya()||Re(!1);let{navigator:a}=h.useContext(bn),{matches:i}=h.useContext(Xr),l=i[i.length-1],o=l?l.params:{};l&&l.pathname;let c=l?l.pathnameBase:"/";l&&l.route;let d=wa(),f;if(t){var u;let b=typeof t=="string"?ps(t):t;c==="/"||(u=b.pathname)!=null&&u.startsWith(c)||Re(!1),f=b}else f=d;let x=f.pathname||"/",y=x;if(c!=="/"){let b=c.replace(/^\//,"").split("/");y="/"+x.replace(/^\//,"").split("/").slice(b.length).join("/")}let w=Gg(e,{pathname:y}),v=Ev(w&&w.map(b=>Object.assign({},b,{params:Object.assign({},o,b.params),pathname:Ur([c,a.encodeLocation?a.encodeLocation(b.pathname).pathname:b.pathname]),pathnameBase:b.pathnameBase==="/"?c:Ur([c,a.encodeLocation?a.encodeLocation(b.pathnameBase).pathname:b.pathnameBase])})),i,r,s);return t&&v?h.createElement(Zi.Provider,{value:{location:da({pathname:"/",search:"",hash:"",state:null,key:"default"},f),navigationType:Mr.Pop}},v):v}function Nv(){let e=Dv(),t=xv(e)?e.status+" "+e.statusText:e instanceof Error?e.message:JSON.stringify(e),r=e instanceof Error?e.stack:null,a={padding:"0.5rem",backgroundColor:"rgba(200,200,200, 0.5)"};return h.createElement(h.Fragment,null,h.createElement("h2",null,"Unexpected Application Error!"),h.createElement("h3",{style:{fontStyle:"italic"}},t),r?h.createElement("pre",{style:a},r):null,null)}const kv=h.createElement(Nv,null);class Sv extends h.Component{constructor(t){super(t),this.state={location:t.location,revalidation:t.revalidation,error:t.error}}static getDerivedStateFromError(t){return{error:t}}static getDerivedStateFromProps(t,r){return r.location!==t.location||r.revalidation!=="idle"&&t.revalidation==="idle"?{error:t.error,location:t.location,revalidation:t.revalidation}:{error:t.error!==void 0?t.error:r.error,location:r.location,revalidation:t.revalidation||r.revalidation}}componentDidCatch(t,r){console.error("React Router caught the following error during render",t,r)}render(){return this.state.error!==void 0?h.createElement(Xr.Provider,{value:this.props.routeContext},h.createElement(mm.Provider,{value:this.state.error,children:this.props.component})):this.props.children}}function Cv(e){let{routeContext:t,match:r,children:s}=e,a=h.useContext(Kc);return a&&a.static&&a.staticContext&&(r.route.errorElement||r.route.ErrorBoundary)&&(a.staticContext._deepestRenderedBoundaryId=r.route.id),h.createElement(Xr.Provider,{value:t},s)}function Ev(e,t,r,s){var a;if(t===void 0&&(t=[]),r===void 0&&(r=null),s===void 0&&(s=null),e==null){var i;if(!r)return null;if(r.errors)e=r.matches;else if((i=s)!=null&&i.v7_partialHydration&&t.length===0&&!r.initialized&&r.matches.length>0)e=r.matches;else return null}let l=e,o=(a=r)==null?void 0:a.errors;if(o!=null){let f=l.findIndex(u=>u.route.id&&(o==null?void 0:o[u.route.id])!==void 0);f>=0||Re(!1),l=l.slice(0,Math.min(l.length,f+1))}let c=!1,d=-1;if(r&&s&&s.v7_partialHydration)for(let f=0;f<l.length;f++){let u=l[f];if((u.route.HydrateFallback||u.route.hydrateFallbackElement)&&(d=f),u.route.id){let{loaderData:x,errors:y}=r,w=u.route.loader&&x[u.route.id]===void 0&&(!y||y[u.route.id]===void 0);if(u.route.lazy||w){c=!0,d>=0?l=l.slice(0,d+1):l=[l[0]];break}}}return l.reduceRight((f,u,x)=>{let y,w=!1,v=null,b=null;r&&(y=o&&u.route.id?o[u.route.id]:void 0,v=u.route.errorElement||kv,c&&(d<0&&x===0?(Rv("route-fallback"),w=!0,b=null):d===x&&(w=!0,b=u.route.hydrateFallbackElement||null)));let m=t.concat(l.slice(0,x+1)),p=()=>{let g;return y?g=v:w?g=b:u.route.Component?g=h.createElement(u.route.Component,null):u.route.element?g=u.route.element:g=f,h.createElement(Cv,{match:u,routeContext:{outlet:f,matches:m,isDataRoute:r!=null},children:g})};return r&&(u.route.ErrorBoundary||u.route.errorElement||x===0)?h.createElement(Sv,{location:r.location,revalidation:r.revalidation,component:v,error:y,children:p(),routeContext:{outlet:null,matches:m,isDataRoute:!0}}):p()},null)}var vm=function(e){return e.UseBlocker="useBlocker",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e}(vm||{}),ym=function(e){return e.UseBlocker="useBlocker",e.UseLoaderData="useLoaderData",e.UseActionData="useActionData",e.UseRouteError="useRouteError",e.UseNavigation="useNavigation",e.UseRouteLoaderData="useRouteLoaderData",e.UseMatches="useMatches",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e.UseRouteId="useRouteId",e}(ym||{});function Tv(e){let t=h.useContext(Kc);return t||Re(!1),t}function Pv(e){let t=h.useContext(vv);return t||Re(!1),t}function zv(e){let t=h.useContext(Xr);return t||Re(!1),t}function wm(e){let t=zv(),r=t.matches[t.matches.length-1];return r.route.id||Re(!1),r.route.id}function Dv(){var e;let t=h.useContext(mm),r=Pv(),s=wm();return t!==void 0?t:(e=r.errors)==null?void 0:e[s]}function Mv(){let{router:e}=Tv(vm.UseNavigateStable),t=wm(ym.UseNavigateStable),r=h.useRef(!1);return pm(()=>{r.current=!0}),h.useCallback(function(a,i){i===void 0&&(i={}),r.current&&(typeof a=="number"?e.navigate(a):e.navigate(a,da({fromRouteId:t},i)))},[e,t])}const gu={};function Rv(e,t,r){gu[e]||(gu[e]=!0)}function Iv(e,t){e==null||e.v7_startTransition,e==null||e.v7_relativeSplatPath}function kr(e){Re(!1)}function Lv(e){let{basename:t="/",children:r=null,location:s,navigationType:a=Mr.Pop,navigator:i,static:l=!1,future:o}=e;ya()&&Re(!1);let c=t.replace(/^\/*/,"/"),d=h.useMemo(()=>({basename:c,navigator:i,static:l,future:da({v7_relativeSplatPath:!1},o)}),[c,o,i,l]);typeof s=="string"&&(s=ps(s));let{pathname:f="/",search:u="",hash:x="",state:y=null,key:w="default"}=s,v=h.useMemo(()=>{let b=Hc(f,c);return b==null?null:{location:{pathname:b,search:u,hash:x,state:y,key:w},navigationType:a}},[c,f,u,x,y,w,a]);return v==null?null:h.createElement(bn.Provider,{value:d},h.createElement(Zi.Provider,{children:r,value:v}))}function _v(e){let{children:t,location:r}=e;return bv(Fo(t),r)}new Promise(()=>{});function Fo(e,t){t===void 0&&(t=[]);let r=[];return h.Children.forEach(e,(s,a)=>{if(!h.isValidElement(s))return;let i=[...t,a];if(s.type===h.Fragment){r.push.apply(r,Fo(s.props.children,i));return}s.type!==kr&&Re(!1),!s.props.index||!s.props.children||Re(!1);let l={id:s.props.id||i.join("-"),caseSensitive:s.props.caseSensitive,element:s.props.element,Component:s.props.Component,index:s.props.index,path:s.props.path,loader:s.props.loader,action:s.props.action,errorElement:s.props.errorElement,ErrorBoundary:s.props.ErrorBoundary,hasErrorBoundary:s.props.ErrorBoundary!=null||s.props.errorElement!=null,shouldRevalidate:s.props.shouldRevalidate,handle:s.props.handle,lazy:s.props.lazy};s.props.children&&(l.children=Fo(s.props.children,i)),r.push(l)}),r}/**
59
- * React Router DOM v6.30.1
60
- *
61
- * Copyright (c) Remix Software Inc.
62
- *
63
- * This source code is licensed under the MIT license found in the
64
- * LICENSE.md file in the root directory of this source tree.
65
- *
66
- * @license MIT
67
- */function Uo(){return Uo=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var s in r)Object.prototype.hasOwnProperty.call(r,s)&&(e[s]=r[s])}return e},Uo.apply(this,arguments)}function Ov(e,t){if(e==null)return{};var r={},s=Object.keys(e),a,i;for(i=0;i<s.length;i++)a=s[i],!(t.indexOf(a)>=0)&&(r[a]=e[a]);return r}function Av(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}function $v(e,t){return e.button===0&&(!t||t==="_self")&&!Av(e)}const Fv=["onClick","relative","reloadDocument","replace","state","target","to","preventScrollReset","viewTransition"],Uv="6";try{window.__reactRouterVersion=Uv}catch{}const Bv="startTransition",vu=qo[Bv];function Vv(e){let{basename:t,children:r,future:s,window:a}=e,i=h.useRef();i.current==null&&(i.current=Kg({window:a,v5Compat:!0}));let l=i.current,[o,c]=h.useState({action:l.action,location:l.location}),{v7_startTransition:d}=s||{},f=h.useCallback(u=>{d&&vu?vu(()=>c(u)):c(u)},[c,d]);return h.useLayoutEffect(()=>l.listen(f),[l,f]),h.useEffect(()=>Iv(s),[s]),h.createElement(Lv,{basename:t,children:r,location:o.location,navigationType:o.action,navigator:l,future:s})}const Wv=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u",Hv=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,Xn=h.forwardRef(function(t,r){let{onClick:s,relative:a,reloadDocument:i,replace:l,state:o,target:c,to:d,preventScrollReset:f,viewTransition:u}=t,x=Ov(t,Fv),{basename:y}=h.useContext(bn),w,v=!1;if(typeof d=="string"&&Hv.test(d)&&(w=d,Wv))try{let g=new URL(window.location.href),j=d.startsWith("//")?new URL(g.protocol+d):new URL(d),S=Hc(j.pathname,y);j.origin===g.origin&&S!=null?d=S+j.search+j.hash:v=!0}catch{}let b=yv(d,{relative:a}),m=Kv(d,{replace:l,state:o,target:c,preventScrollReset:f,relative:a,viewTransition:u});function p(g){s&&s(g),g.defaultPrevented||m(g)}return h.createElement("a",Uo({},x,{href:w||b,onClick:v||i?s:p,ref:r,target:c}))});var yu;(function(e){e.UseScrollRestoration="useScrollRestoration",e.UseSubmit="useSubmit",e.UseSubmitFetcher="useSubmitFetcher",e.UseFetcher="useFetcher",e.useViewTransitionState="useViewTransitionState"})(yu||(yu={}));var wu;(function(e){e.UseFetcher="useFetcher",e.UseFetchers="useFetchers",e.UseScrollRestoration="useScrollRestoration"})(wu||(wu={}));function Kv(e,t){let{target:r,replace:s,state:a,preventScrollReset:i,relative:l,viewTransition:o}=t===void 0?{}:t,c=qi(),d=wa(),f=gm(e,{relative:l});return h.useCallback(u=>{if($v(u,r)){u.preventDefault();let x=s!==void 0?s:Ri(d)===Ri(f);c(e,{replace:x,state:a,preventScrollReset:i,relative:l,viewTransition:o})}},[d,c,f,s,a,r,e,i,l,o])}function Qv(e){if(typeof document>"u")return;let t=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css",t.appendChild(r),r.styleSheet?r.styleSheet.cssText=e:r.appendChild(document.createTextNode(e))}const Yv=e=>{switch(e){case"success":return Jv;case"info":return qv;case"warning":return Zv;case"error":return e0;default:return null}},Gv=Array(12).fill(0),Xv=({visible:e,className:t})=>U.createElement("div",{className:["sonner-loading-wrapper",t].filter(Boolean).join(" "),"data-visible":e},U.createElement("div",{className:"sonner-spinner"},Gv.map((r,s)=>U.createElement("div",{className:"sonner-loading-bar",key:`spinner-bar-${s}`})))),Jv=U.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},U.createElement("path",{fillRule:"evenodd",d:"M10 18a8 8 0 100-16 8 8 0 000 16zm3.857-9.809a.75.75 0 00-1.214-.882l-3.483 4.79-1.88-1.88a.75.75 0 10-1.06 1.061l2.5 2.5a.75.75 0 001.137-.089l4-5.5z",clipRule:"evenodd"})),Zv=U.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",height:"20",width:"20"},U.createElement("path",{fillRule:"evenodd",d:"M9.401 3.003c1.155-2 4.043-2 5.197 0l7.355 12.748c1.154 2-.29 4.5-2.599 4.5H4.645c-2.309 0-3.752-2.5-2.598-4.5L9.4 3.003zM12 8.25a.75.75 0 01.75.75v3.75a.75.75 0 01-1.5 0V9a.75.75 0 01.75-.75zm0 8.25a.75.75 0 100-1.5.75.75 0 000 1.5z",clipRule:"evenodd"})),qv=U.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},U.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7-4a1 1 0 11-2 0 1 1 0 012 0zM9 9a.75.75 0 000 1.5h.253a.25.25 0 01.244.304l-.459 2.066A1.75 1.75 0 0010.747 15H11a.75.75 0 000-1.5h-.253a.25.25 0 01-.244-.304l.459-2.066A1.75 1.75 0 009.253 9H9z",clipRule:"evenodd"})),e0=U.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},U.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-8-5a.75.75 0 01.75.75v4.5a.75.75 0 01-1.5 0v-4.5A.75.75 0 0110 5zm0 10a1 1 0 100-2 1 1 0 000 2z",clipRule:"evenodd"})),t0=U.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"12",height:"12",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"},U.createElement("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),U.createElement("line",{x1:"6",y1:"6",x2:"18",y2:"18"})),r0=()=>{const[e,t]=U.useState(document.hidden);return U.useEffect(()=>{const r=()=>{t(document.hidden)};return document.addEventListener("visibilitychange",r),()=>window.removeEventListener("visibilitychange",r)},[]),e};let Bo=1;class n0{constructor(){this.subscribe=t=>(this.subscribers.push(t),()=>{const r=this.subscribers.indexOf(t);this.subscribers.splice(r,1)}),this.publish=t=>{this.subscribers.forEach(r=>r(t))},this.addToast=t=>{this.publish(t),this.toasts=[...this.toasts,t]},this.create=t=>{var r;const{message:s,...a}=t,i=typeof(t==null?void 0:t.id)=="number"||((r=t.id)==null?void 0:r.length)>0?t.id:Bo++,l=this.toasts.find(c=>c.id===i),o=t.dismissible===void 0?!0:t.dismissible;return this.dismissedToasts.has(i)&&this.dismissedToasts.delete(i),l?this.toasts=this.toasts.map(c=>c.id===i?(this.publish({...c,...t,id:i,title:s}),{...c,...t,id:i,dismissible:o,title:s}):c):this.addToast({title:s,...a,dismissible:o,id:i}),i},this.dismiss=t=>(t?(this.dismissedToasts.add(t),requestAnimationFrame(()=>this.subscribers.forEach(r=>r({id:t,dismiss:!0})))):this.toasts.forEach(r=>{this.subscribers.forEach(s=>s({id:r.id,dismiss:!0}))}),t),this.message=(t,r)=>this.create({...r,message:t}),this.error=(t,r)=>this.create({...r,message:t,type:"error"}),this.success=(t,r)=>this.create({...r,type:"success",message:t}),this.info=(t,r)=>this.create({...r,type:"info",message:t}),this.warning=(t,r)=>this.create({...r,type:"warning",message:t}),this.loading=(t,r)=>this.create({...r,type:"loading",message:t}),this.promise=(t,r)=>{if(!r)return;let s;r.loading!==void 0&&(s=this.create({...r,promise:t,type:"loading",message:r.loading,description:typeof r.description!="function"?r.description:void 0}));const a=Promise.resolve(t instanceof Function?t():t);let i=s!==void 0,l;const o=a.then(async d=>{if(l=["resolve",d],U.isValidElement(d))i=!1,this.create({id:s,type:"default",message:d});else if(a0(d)&&!d.ok){i=!1;const u=typeof r.error=="function"?await r.error(`HTTP error! status: ${d.status}`):r.error,x=typeof r.description=="function"?await r.description(`HTTP error! status: ${d.status}`):r.description,w=typeof u=="object"&&!U.isValidElement(u)?u:{message:u};this.create({id:s,type:"error",description:x,...w})}else if(d instanceof Error){i=!1;const u=typeof r.error=="function"?await r.error(d):r.error,x=typeof r.description=="function"?await r.description(d):r.description,w=typeof u=="object"&&!U.isValidElement(u)?u:{message:u};this.create({id:s,type:"error",description:x,...w})}else if(r.success!==void 0){i=!1;const u=typeof r.success=="function"?await r.success(d):r.success,x=typeof r.description=="function"?await r.description(d):r.description,w=typeof u=="object"&&!U.isValidElement(u)?u:{message:u};this.create({id:s,type:"success",description:x,...w})}}).catch(async d=>{if(l=["reject",d],r.error!==void 0){i=!1;const f=typeof r.error=="function"?await r.error(d):r.error,u=typeof r.description=="function"?await r.description(d):r.description,y=typeof f=="object"&&!U.isValidElement(f)?f:{message:f};this.create({id:s,type:"error",description:u,...y})}}).finally(()=>{i&&(this.dismiss(s),s=void 0),r.finally==null||r.finally.call(r)}),c=()=>new Promise((d,f)=>o.then(()=>l[0]==="reject"?f(l[1]):d(l[1])).catch(f));return typeof s!="string"&&typeof s!="number"?{unwrap:c}:Object.assign(s,{unwrap:c})},this.custom=(t,r)=>{const s=(r==null?void 0:r.id)||Bo++;return this.create({jsx:t(s),id:s,...r}),s},this.getActiveToasts=()=>this.toasts.filter(t=>!this.dismissedToasts.has(t.id)),this.subscribers=[],this.toasts=[],this.dismissedToasts=new Set}}const ot=new n0,s0=(e,t)=>{const r=(t==null?void 0:t.id)||Bo++;return ot.addToast({title:e,...t,id:r}),r},a0=e=>e&&typeof e=="object"&&"ok"in e&&typeof e.ok=="boolean"&&"status"in e&&typeof e.status=="number",i0=s0,l0=()=>ot.toasts,o0=()=>ot.getActiveToasts(),I=Object.assign(i0,{success:ot.success,info:ot.info,warning:ot.warning,error:ot.error,custom:ot.custom,message:ot.message,promise:ot.promise,dismiss:ot.dismiss,loading:ot.loading},{getHistory:l0,getToasts:o0});Qv("[data-sonner-toaster][dir=ltr],html[dir=ltr]{--toast-icon-margin-start:-3px;--toast-icon-margin-end:4px;--toast-svg-margin-start:-1px;--toast-svg-margin-end:0px;--toast-button-margin-start:auto;--toast-button-margin-end:0;--toast-close-button-start:0;--toast-close-button-end:unset;--toast-close-button-transform:translate(-35%, -35%)}[data-sonner-toaster][dir=rtl],html[dir=rtl]{--toast-icon-margin-start:4px;--toast-icon-margin-end:-3px;--toast-svg-margin-start:0px;--toast-svg-margin-end:-1px;--toast-button-margin-start:0;--toast-button-margin-end:auto;--toast-close-button-start:unset;--toast-close-button-end:0;--toast-close-button-transform:translate(35%, -35%)}[data-sonner-toaster]{position:fixed;width:var(--width);font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;--gray1:hsl(0, 0%, 99%);--gray2:hsl(0, 0%, 97.3%);--gray3:hsl(0, 0%, 95.1%);--gray4:hsl(0, 0%, 93%);--gray5:hsl(0, 0%, 90.9%);--gray6:hsl(0, 0%, 88.7%);--gray7:hsl(0, 0%, 85.8%);--gray8:hsl(0, 0%, 78%);--gray9:hsl(0, 0%, 56.1%);--gray10:hsl(0, 0%, 52.3%);--gray11:hsl(0, 0%, 43.5%);--gray12:hsl(0, 0%, 9%);--border-radius:8px;box-sizing:border-box;padding:0;margin:0;list-style:none;outline:0;z-index:999999999;transition:transform .4s ease}@media (hover:none) and (pointer:coarse){[data-sonner-toaster][data-lifted=true]{transform:none}}[data-sonner-toaster][data-x-position=right]{right:var(--offset-right)}[data-sonner-toaster][data-x-position=left]{left:var(--offset-left)}[data-sonner-toaster][data-x-position=center]{left:50%;transform:translateX(-50%)}[data-sonner-toaster][data-y-position=top]{top:var(--offset-top)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--offset-bottom)}[data-sonner-toast]{--y:translateY(100%);--lift-amount:calc(var(--lift) * var(--gap));z-index:var(--z-index);position:absolute;opacity:0;transform:var(--y);touch-action:none;transition:transform .4s,opacity .4s,height .4s,box-shadow .2s;box-sizing:border-box;outline:0;overflow-wrap:anywhere}[data-sonner-toast][data-styled=true]{padding:16px;background:var(--normal-bg);border:1px solid var(--normal-border);color:var(--normal-text);border-radius:var(--border-radius);box-shadow:0 4px 12px rgba(0,0,0,.1);width:var(--width);font-size:13px;display:flex;align-items:center;gap:6px}[data-sonner-toast]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-y-position=top]{top:0;--y:translateY(-100%);--lift:1;--lift-amount:calc(1 * var(--gap))}[data-sonner-toast][data-y-position=bottom]{bottom:0;--y:translateY(100%);--lift:-1;--lift-amount:calc(var(--lift) * var(--gap))}[data-sonner-toast][data-styled=true] [data-description]{font-weight:400;line-height:1.4;color:#3f3f3f}[data-rich-colors=true][data-sonner-toast][data-styled=true] [data-description]{color:inherit}[data-sonner-toaster][data-sonner-theme=dark] [data-description]{color:#e8e8e8}[data-sonner-toast][data-styled=true] [data-title]{font-weight:500;line-height:1.5;color:inherit}[data-sonner-toast][data-styled=true] [data-icon]{display:flex;height:16px;width:16px;position:relative;justify-content:flex-start;align-items:center;flex-shrink:0;margin-left:var(--toast-icon-margin-start);margin-right:var(--toast-icon-margin-end)}[data-sonner-toast][data-promise=true] [data-icon]>svg{opacity:0;transform:scale(.8);transform-origin:center;animation:sonner-fade-in .3s ease forwards}[data-sonner-toast][data-styled=true] [data-icon]>*{flex-shrink:0}[data-sonner-toast][data-styled=true] [data-icon] svg{margin-left:var(--toast-svg-margin-start);margin-right:var(--toast-svg-margin-end)}[data-sonner-toast][data-styled=true] [data-content]{display:flex;flex-direction:column;gap:2px}[data-sonner-toast][data-styled=true] [data-button]{border-radius:4px;padding-left:8px;padding-right:8px;height:24px;font-size:12px;color:var(--normal-bg);background:var(--normal-text);margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end);border:none;font-weight:500;cursor:pointer;outline:0;display:flex;align-items:center;flex-shrink:0;transition:opacity .4s,box-shadow .2s}[data-sonner-toast][data-styled=true] [data-button]:focus-visible{box-shadow:0 0 0 2px rgba(0,0,0,.4)}[data-sonner-toast][data-styled=true] [data-button]:first-of-type{margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end)}[data-sonner-toast][data-styled=true] [data-cancel]{color:var(--normal-text);background:rgba(0,0,0,.08)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-styled=true] [data-cancel]{background:rgba(255,255,255,.3)}[data-sonner-toast][data-styled=true] [data-close-button]{position:absolute;left:var(--toast-close-button-start);right:var(--toast-close-button-end);top:0;height:20px;width:20px;display:flex;justify-content:center;align-items:center;padding:0;color:var(--gray12);background:var(--normal-bg);border:1px solid var(--gray4);transform:var(--toast-close-button-transform);border-radius:50%;cursor:pointer;z-index:1;transition:opacity .1s,background .2s,border-color .2s}[data-sonner-toast][data-styled=true] [data-close-button]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-styled=true] [data-disabled=true]{cursor:not-allowed}[data-sonner-toast][data-styled=true]:hover [data-close-button]:hover{background:var(--gray2);border-color:var(--gray5)}[data-sonner-toast][data-swiping=true]::before{content:'';position:absolute;left:-100%;right:-100%;height:100%;z-index:-1}[data-sonner-toast][data-y-position=top][data-swiping=true]::before{bottom:50%;transform:scaleY(3) translateY(50%)}[data-sonner-toast][data-y-position=bottom][data-swiping=true]::before{top:50%;transform:scaleY(3) translateY(-50%)}[data-sonner-toast][data-swiping=false][data-removed=true]::before{content:'';position:absolute;inset:0;transform:scaleY(2)}[data-sonner-toast][data-expanded=true]::after{content:'';position:absolute;left:0;height:calc(var(--gap) + 1px);bottom:100%;width:100%}[data-sonner-toast][data-mounted=true]{--y:translateY(0);opacity:1}[data-sonner-toast][data-expanded=false][data-front=false]{--scale:var(--toasts-before) * 0.05 + 1;--y:translateY(calc(var(--lift-amount) * var(--toasts-before))) scale(calc(-1 * var(--scale)));height:var(--front-toast-height)}[data-sonner-toast]>*{transition:opacity .4s}[data-sonner-toast][data-x-position=right]{right:0}[data-sonner-toast][data-x-position=left]{left:0}[data-sonner-toast][data-expanded=false][data-front=false][data-styled=true]>*{opacity:0}[data-sonner-toast][data-visible=false]{opacity:0;pointer-events:none}[data-sonner-toast][data-mounted=true][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset)));height:var(--initial-height)}[data-sonner-toast][data-removed=true][data-front=true][data-swipe-out=false]{--y:translateY(calc(var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset) + var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=false]{--y:translateY(40%);opacity:0;transition:transform .5s,opacity .2s}[data-sonner-toast][data-removed=true][data-front=false]::before{height:calc(var(--initial-height) + 20%)}[data-sonner-toast][data-swiping=true]{transform:var(--y) translateY(var(--swipe-amount-y,0)) translateX(var(--swipe-amount-x,0));transition:none}[data-sonner-toast][data-swiped=true]{user-select:none}[data-sonner-toast][data-swipe-out=true][data-y-position=bottom],[data-sonner-toast][data-swipe-out=true][data-y-position=top]{animation-duration:.2s;animation-timing-function:ease-out;animation-fill-mode:forwards}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=left]{animation-name:swipe-out-left}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=right]{animation-name:swipe-out-right}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=up]{animation-name:swipe-out-up}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=down]{animation-name:swipe-out-down}@keyframes swipe-out-left{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) - 100%));opacity:0}}@keyframes swipe-out-right{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) + 100%));opacity:0}}@keyframes swipe-out-up{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) - 100%));opacity:0}}@keyframes swipe-out-down{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) + 100%));opacity:0}}@media (max-width:600px){[data-sonner-toaster]{position:fixed;right:var(--mobile-offset-right);left:var(--mobile-offset-left);width:100%}[data-sonner-toaster][dir=rtl]{left:calc(var(--mobile-offset-left) * -1)}[data-sonner-toaster] [data-sonner-toast]{left:0;right:0;width:calc(100% - var(--mobile-offset-left) * 2)}[data-sonner-toaster][data-x-position=left]{left:var(--mobile-offset-left)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--mobile-offset-bottom)}[data-sonner-toaster][data-y-position=top]{top:var(--mobile-offset-top)}[data-sonner-toaster][data-x-position=center]{left:var(--mobile-offset-left);right:var(--mobile-offset-right);transform:none}}[data-sonner-toaster][data-sonner-theme=light]{--normal-bg:#fff;--normal-border:var(--gray4);--normal-text:var(--gray12);--success-bg:hsl(143, 85%, 96%);--success-border:hsl(145, 92%, 87%);--success-text:hsl(140, 100%, 27%);--info-bg:hsl(208, 100%, 97%);--info-border:hsl(221, 91%, 93%);--info-text:hsl(210, 92%, 45%);--warning-bg:hsl(49, 100%, 97%);--warning-border:hsl(49, 91%, 84%);--warning-text:hsl(31, 92%, 45%);--error-bg:hsl(359, 100%, 97%);--error-border:hsl(359, 100%, 94%);--error-text:hsl(360, 100%, 45%)}[data-sonner-toaster][data-sonner-theme=light] [data-sonner-toast][data-invert=true]{--normal-bg:#000;--normal-border:hsl(0, 0%, 20%);--normal-text:var(--gray1)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-invert=true]{--normal-bg:#fff;--normal-border:var(--gray3);--normal-text:var(--gray12)}[data-sonner-toaster][data-sonner-theme=dark]{--normal-bg:#000;--normal-bg-hover:hsl(0, 0%, 12%);--normal-border:hsl(0, 0%, 20%);--normal-border-hover:hsl(0, 0%, 25%);--normal-text:var(--gray1);--success-bg:hsl(150, 100%, 6%);--success-border:hsl(147, 100%, 12%);--success-text:hsl(150, 86%, 65%);--info-bg:hsl(215, 100%, 6%);--info-border:hsl(223, 43%, 17%);--info-text:hsl(216, 87%, 65%);--warning-bg:hsl(64, 100%, 6%);--warning-border:hsl(60, 100%, 9%);--warning-text:hsl(46, 87%, 65%);--error-bg:hsl(358, 76%, 10%);--error-border:hsl(357, 89%, 16%);--error-text:hsl(358, 100%, 81%)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]{background:var(--normal-bg);border-color:var(--normal-border);color:var(--normal-text)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]:hover{background:var(--normal-bg-hover);border-color:var(--normal-border-hover)}[data-rich-colors=true][data-sonner-toast][data-type=success]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=success] [data-close-button]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=info]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=info] [data-close-button]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning] [data-close-button]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=error]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}[data-rich-colors=true][data-sonner-toast][data-type=error] [data-close-button]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}.sonner-loading-wrapper{--size:16px;height:var(--size);width:var(--size);position:absolute;inset:0;z-index:10}.sonner-loading-wrapper[data-visible=false]{transform-origin:center;animation:sonner-fade-out .2s ease forwards}.sonner-spinner{position:relative;top:50%;left:50%;height:var(--size);width:var(--size)}.sonner-loading-bar{animation:sonner-spin 1.2s linear infinite;background:var(--gray11);border-radius:6px;height:8%;left:-10%;position:absolute;top:-3.9%;width:24%}.sonner-loading-bar:first-child{animation-delay:-1.2s;transform:rotate(.0001deg) translate(146%)}.sonner-loading-bar:nth-child(2){animation-delay:-1.1s;transform:rotate(30deg) translate(146%)}.sonner-loading-bar:nth-child(3){animation-delay:-1s;transform:rotate(60deg) translate(146%)}.sonner-loading-bar:nth-child(4){animation-delay:-.9s;transform:rotate(90deg) translate(146%)}.sonner-loading-bar:nth-child(5){animation-delay:-.8s;transform:rotate(120deg) translate(146%)}.sonner-loading-bar:nth-child(6){animation-delay:-.7s;transform:rotate(150deg) translate(146%)}.sonner-loading-bar:nth-child(7){animation-delay:-.6s;transform:rotate(180deg) translate(146%)}.sonner-loading-bar:nth-child(8){animation-delay:-.5s;transform:rotate(210deg) translate(146%)}.sonner-loading-bar:nth-child(9){animation-delay:-.4s;transform:rotate(240deg) translate(146%)}.sonner-loading-bar:nth-child(10){animation-delay:-.3s;transform:rotate(270deg) translate(146%)}.sonner-loading-bar:nth-child(11){animation-delay:-.2s;transform:rotate(300deg) translate(146%)}.sonner-loading-bar:nth-child(12){animation-delay:-.1s;transform:rotate(330deg) translate(146%)}@keyframes sonner-fade-in{0%{opacity:0;transform:scale(.8)}100%{opacity:1;transform:scale(1)}}@keyframes sonner-fade-out{0%{opacity:1;transform:scale(1)}100%{opacity:0;transform:scale(.8)}}@keyframes sonner-spin{0%{opacity:1}100%{opacity:.15}}@media (prefers-reduced-motion){.sonner-loading-bar,[data-sonner-toast],[data-sonner-toast]>*{transition:none!important;animation:none!important}}.sonner-loader{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);transform-origin:center;transition:opacity .2s,transform .2s}.sonner-loader[data-visible=false]{opacity:0;transform:scale(.8) translate(-50%,-50%)}");function Ba(e){return e.label!==void 0}const c0=3,d0="24px",u0="16px",bu=4e3,h0=356,f0=14,m0=45,p0=200;function Qt(...e){return e.filter(Boolean).join(" ")}function x0(e){const[t,r]=e.split("-"),s=[];return t&&s.push(t),r&&s.push(r),s}const g0=e=>{var t,r,s,a,i,l,o,c,d;const{invert:f,toast:u,unstyled:x,interacting:y,setHeights:w,visibleToasts:v,heights:b,index:m,toasts:p,expanded:g,removeToast:j,defaultRichColors:S,closeButton:N,style:C,cancelButtonStyle:O,actionButtonStyle:G,className:V="",descriptionClassName:J="",duration:B,position:se,gap:ee,expandByDefault:ie,classNames:D,icons:H,closeButtonAriaLabel:k="Close toast"}=e,[A,_]=U.useState(null),[W,E]=U.useState(null),[z,M]=U.useState(!1),[L,R]=U.useState(!1),[X,Q]=U.useState(!1),[q,Ne]=U.useState(!1),[pe,Pe]=U.useState(!1),[yr,Bt]=U.useState(0),[Vt,Wt]=U.useState(0),jt=U.useRef(u.duration||B||bu),Nn=U.useRef(null),Ye=U.useRef(null),gs=m===0,rr=m+1<=v,Oe=u.type,Ht=u.dismissible!==!1,vs=u.className||"",F=u.descriptionClassName||"",Z=U.useMemo(()=>b.findIndex(te=>te.toastId===u.id)||0,[b,u.id]),de=U.useMemo(()=>{var te;return(te=u.closeButton)!=null?te:N},[u.closeButton,N]),rt=U.useMemo(()=>u.duration||B||bu,[u.duration,B]),nr=U.useRef(0),he=U.useRef(0),P=U.useRef(0),Y=U.useRef(null),[ae,Ae]=se.split("-"),lt=U.useMemo(()=>b.reduce((te,$e,Ge)=>Ge>=Z?te:te+$e.height,0),[b,Z]),ke=r0(),sr=u.invert||f,al=Oe==="loading";he.current=U.useMemo(()=>Z*ee+lt,[Z,lt]),U.useEffect(()=>{jt.current=rt},[rt]),U.useEffect(()=>{M(!0)},[]),U.useEffect(()=>{const te=Ye.current;if(te){const $e=te.getBoundingClientRect().height;return Wt($e),w(Ge=>[{toastId:u.id,height:$e,position:u.position},...Ge]),()=>w(Ge=>Ge.filter(pt=>pt.toastId!==u.id))}},[w,u.id]),U.useLayoutEffect(()=>{if(!z)return;const te=Ye.current,$e=te.style.height;te.style.height="auto";const Ge=te.getBoundingClientRect().height;te.style.height=$e,Wt(Ge),w(pt=>pt.find(Be=>Be.toastId===u.id)?pt.map(Be=>Be.toastId===u.id?{...Be,height:Ge}:Be):[{toastId:u.id,height:Ge,position:u.position},...pt])},[z,u.title,u.description,w,u.id,u.jsx,u.action,u.cancel]);const wr=U.useCallback(()=>{R(!0),Bt(he.current),w(te=>te.filter($e=>$e.toastId!==u.id)),setTimeout(()=>{j(u)},p0)},[u,j,w,he]);U.useEffect(()=>{if(u.promise&&Oe==="loading"||u.duration===1/0||u.type==="loading")return;let te;return g||y||ke?(()=>{if(P.current<nr.current){const pt=new Date().getTime()-nr.current;jt.current=jt.current-pt}P.current=new Date().getTime()})():(()=>{jt.current!==1/0&&(nr.current=new Date().getTime(),te=setTimeout(()=>{u.onAutoClose==null||u.onAutoClose.call(u,u),wr()},jt.current))})(),()=>clearTimeout(te)},[g,y,u,Oe,ke,wr]),U.useEffect(()=>{u.delete&&(wr(),u.onDismiss==null||u.onDismiss.call(u,u))},[wr,u.delete]);function vp(){var te;if(H!=null&&H.loading){var $e;return U.createElement("div",{className:Qt(D==null?void 0:D.loader,u==null||($e=u.classNames)==null?void 0:$e.loader,"sonner-loader"),"data-visible":Oe==="loading"},H.loading)}return U.createElement(Xv,{className:Qt(D==null?void 0:D.loader,u==null||(te=u.classNames)==null?void 0:te.loader),visible:Oe==="loading"})}const yp=u.icon||(H==null?void 0:H[Oe])||Yv(Oe);var td,rd;return U.createElement("li",{tabIndex:0,ref:Ye,className:Qt(V,vs,D==null?void 0:D.toast,u==null||(t=u.classNames)==null?void 0:t.toast,D==null?void 0:D.default,D==null?void 0:D[Oe],u==null||(r=u.classNames)==null?void 0:r[Oe]),"data-sonner-toast":"","data-rich-colors":(td=u.richColors)!=null?td:S,"data-styled":!(u.jsx||u.unstyled||x),"data-mounted":z,"data-promise":!!u.promise,"data-swiped":pe,"data-removed":L,"data-visible":rr,"data-y-position":ae,"data-x-position":Ae,"data-index":m,"data-front":gs,"data-swiping":X,"data-dismissible":Ht,"data-type":Oe,"data-invert":sr,"data-swipe-out":q,"data-swipe-direction":W,"data-expanded":!!(g||ie&&z),"data-testid":u.testId,style:{"--index":m,"--toasts-before":m,"--z-index":p.length-m,"--offset":`${L?yr:he.current}px`,"--initial-height":ie?"auto":`${Vt}px`,...C,...u.style},onDragEnd:()=>{Q(!1),_(null),Y.current=null},onPointerDown:te=>{te.button!==2&&(al||!Ht||(Nn.current=new Date,Bt(he.current),te.target.setPointerCapture(te.pointerId),te.target.tagName!=="BUTTON"&&(Q(!0),Y.current={x:te.clientX,y:te.clientY})))},onPointerUp:()=>{var te,$e,Ge;if(q||!Ht)return;Y.current=null;const pt=Number(((te=Ye.current)==null?void 0:te.style.getPropertyValue("--swipe-amount-x").replace("px",""))||0),Na=Number((($e=Ye.current)==null?void 0:$e.style.getPropertyValue("--swipe-amount-y").replace("px",""))||0),Be=new Date().getTime()-((Ge=Nn.current)==null?void 0:Ge.getTime()),Nt=A==="x"?pt:Na,ka=Math.abs(Nt)/Be;if(Math.abs(Nt)>=m0||ka>.11){Bt(he.current),u.onDismiss==null||u.onDismiss.call(u,u),E(A==="x"?pt>0?"right":"left":Na>0?"down":"up"),wr(),Ne(!0);return}else{var Dt,Mt;(Dt=Ye.current)==null||Dt.style.setProperty("--swipe-amount-x","0px"),(Mt=Ye.current)==null||Mt.style.setProperty("--swipe-amount-y","0px")}Pe(!1),Q(!1),_(null)},onPointerMove:te=>{var $e,Ge,pt;if(!Y.current||!Ht||(($e=window.getSelection())==null?void 0:$e.toString().length)>0)return;const Be=te.clientY-Y.current.y,Nt=te.clientX-Y.current.x;var ka;const Dt=(ka=e.swipeDirections)!=null?ka:x0(se);!A&&(Math.abs(Nt)>1||Math.abs(Be)>1)&&_(Math.abs(Nt)>Math.abs(Be)?"x":"y");let Mt={x:0,y:0};const nd=Zr=>1/(1.5+Math.abs(Zr)/20);if(A==="y"){if(Dt.includes("top")||Dt.includes("bottom"))if(Dt.includes("top")&&Be<0||Dt.includes("bottom")&&Be>0)Mt.y=Be;else{const Zr=Be*nd(Be);Mt.y=Math.abs(Zr)<Math.abs(Be)?Zr:Be}}else if(A==="x"&&(Dt.includes("left")||Dt.includes("right")))if(Dt.includes("left")&&Nt<0||Dt.includes("right")&&Nt>0)Mt.x=Nt;else{const Zr=Nt*nd(Nt);Mt.x=Math.abs(Zr)<Math.abs(Nt)?Zr:Nt}(Math.abs(Mt.x)>0||Math.abs(Mt.y)>0)&&Pe(!0),(Ge=Ye.current)==null||Ge.style.setProperty("--swipe-amount-x",`${Mt.x}px`),(pt=Ye.current)==null||pt.style.setProperty("--swipe-amount-y",`${Mt.y}px`)}},de&&!u.jsx&&Oe!=="loading"?U.createElement("button",{"aria-label":k,"data-disabled":al,"data-close-button":!0,onClick:al||!Ht?()=>{}:()=>{wr(),u.onDismiss==null||u.onDismiss.call(u,u)},className:Qt(D==null?void 0:D.closeButton,u==null||(s=u.classNames)==null?void 0:s.closeButton)},(rd=H==null?void 0:H.close)!=null?rd:t0):null,(Oe||u.icon||u.promise)&&u.icon!==null&&((H==null?void 0:H[Oe])!==null||u.icon)?U.createElement("div",{"data-icon":"",className:Qt(D==null?void 0:D.icon,u==null||(a=u.classNames)==null?void 0:a.icon)},u.promise||u.type==="loading"&&!u.icon?u.icon||vp():null,u.type!=="loading"?yp:null):null,U.createElement("div",{"data-content":"",className:Qt(D==null?void 0:D.content,u==null||(i=u.classNames)==null?void 0:i.content)},U.createElement("div",{"data-title":"",className:Qt(D==null?void 0:D.title,u==null||(l=u.classNames)==null?void 0:l.title)},u.jsx?u.jsx:typeof u.title=="function"?u.title():u.title),u.description?U.createElement("div",{"data-description":"",className:Qt(J,F,D==null?void 0:D.description,u==null||(o=u.classNames)==null?void 0:o.description)},typeof u.description=="function"?u.description():u.description):null),U.isValidElement(u.cancel)?u.cancel:u.cancel&&Ba(u.cancel)?U.createElement("button",{"data-button":!0,"data-cancel":!0,style:u.cancelButtonStyle||O,onClick:te=>{Ba(u.cancel)&&Ht&&(u.cancel.onClick==null||u.cancel.onClick.call(u.cancel,te),wr())},className:Qt(D==null?void 0:D.cancelButton,u==null||(c=u.classNames)==null?void 0:c.cancelButton)},u.cancel.label):null,U.isValidElement(u.action)?u.action:u.action&&Ba(u.action)?U.createElement("button",{"data-button":!0,"data-action":!0,style:u.actionButtonStyle||G,onClick:te=>{Ba(u.action)&&(u.action.onClick==null||u.action.onClick.call(u.action,te),!te.defaultPrevented&&wr())},className:Qt(D==null?void 0:D.actionButton,u==null||(d=u.classNames)==null?void 0:d.actionButton)},u.action.label):null)};function ju(){if(typeof window>"u"||typeof document>"u")return"ltr";const e=document.documentElement.getAttribute("dir");return e==="auto"||!e?window.getComputedStyle(document.documentElement).direction:e}function v0(e,t){const r={};return[e,t].forEach((s,a)=>{const i=a===1,l=i?"--mobile-offset":"--offset",o=i?u0:d0;function c(d){["top","right","bottom","left"].forEach(f=>{r[`${l}-${f}`]=typeof d=="number"?`${d}px`:d})}typeof s=="number"||typeof s=="string"?c(s):typeof s=="object"?["top","right","bottom","left"].forEach(d=>{s[d]===void 0?r[`${l}-${d}`]=o:r[`${l}-${d}`]=typeof s[d]=="number"?`${s[d]}px`:s[d]}):c(o)}),r}const y0=U.forwardRef(function(t,r){const{id:s,invert:a,position:i="bottom-right",hotkey:l=["altKey","KeyT"],expand:o,closeButton:c,className:d,offset:f,mobileOffset:u,theme:x="light",richColors:y,duration:w,style:v,visibleToasts:b=c0,toastOptions:m,dir:p=ju(),gap:g=f0,icons:j,containerAriaLabel:S="Notifications"}=t,[N,C]=U.useState([]),O=U.useMemo(()=>s?N.filter(z=>z.toasterId===s):N.filter(z=>!z.toasterId),[N,s]),G=U.useMemo(()=>Array.from(new Set([i].concat(O.filter(z=>z.position).map(z=>z.position)))),[O,i]),[V,J]=U.useState([]),[B,se]=U.useState(!1),[ee,ie]=U.useState(!1),[D,H]=U.useState(x!=="system"?x:typeof window<"u"&&window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"),k=U.useRef(null),A=l.join("+").replace(/Key/g,"").replace(/Digit/g,""),_=U.useRef(null),W=U.useRef(!1),E=U.useCallback(z=>{C(M=>{var L;return(L=M.find(R=>R.id===z.id))!=null&&L.delete||ot.dismiss(z.id),M.filter(({id:R})=>R!==z.id)})},[]);return U.useEffect(()=>ot.subscribe(z=>{if(z.dismiss){requestAnimationFrame(()=>{C(M=>M.map(L=>L.id===z.id?{...L,delete:!0}:L))});return}setTimeout(()=>{lm.flushSync(()=>{C(M=>{const L=M.findIndex(R=>R.id===z.id);return L!==-1?[...M.slice(0,L),{...M[L],...z},...M.slice(L+1)]:[z,...M]})})})}),[N]),U.useEffect(()=>{if(x!=="system"){H(x);return}if(x==="system"&&(window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?H("dark"):H("light")),typeof window>"u")return;const z=window.matchMedia("(prefers-color-scheme: dark)");try{z.addEventListener("change",({matches:M})=>{H(M?"dark":"light")})}catch{z.addListener(({matches:L})=>{try{H(L?"dark":"light")}catch(R){console.error(R)}})}},[x]),U.useEffect(()=>{N.length<=1&&se(!1)},[N]),U.useEffect(()=>{const z=M=>{var L;if(l.every(Q=>M[Q]||M.code===Q)){var X;se(!0),(X=k.current)==null||X.focus()}M.code==="Escape"&&(document.activeElement===k.current||(L=k.current)!=null&&L.contains(document.activeElement))&&se(!1)};return document.addEventListener("keydown",z),()=>document.removeEventListener("keydown",z)},[l]),U.useEffect(()=>{if(k.current)return()=>{_.current&&(_.current.focus({preventScroll:!0}),_.current=null,W.current=!1)}},[k.current]),U.createElement("section",{ref:r,"aria-label":`${S} ${A}`,tabIndex:-1,"aria-live":"polite","aria-relevant":"additions text","aria-atomic":"false",suppressHydrationWarning:!0},G.map((z,M)=>{var L;const[R,X]=z.split("-");return O.length?U.createElement("ol",{key:z,dir:p==="auto"?ju():p,tabIndex:-1,ref:k,className:d,"data-sonner-toaster":!0,"data-sonner-theme":D,"data-y-position":R,"data-x-position":X,style:{"--front-toast-height":`${((L=V[0])==null?void 0:L.height)||0}px`,"--width":`${h0}px`,"--gap":`${g}px`,...v,...v0(f,u)},onBlur:Q=>{W.current&&!Q.currentTarget.contains(Q.relatedTarget)&&(W.current=!1,_.current&&(_.current.focus({preventScroll:!0}),_.current=null))},onFocus:Q=>{Q.target instanceof HTMLElement&&Q.target.dataset.dismissible==="false"||W.current||(W.current=!0,_.current=Q.relatedTarget)},onMouseEnter:()=>se(!0),onMouseMove:()=>se(!0),onMouseLeave:()=>{ee||se(!1)},onDragEnd:()=>se(!1),onPointerDown:Q=>{Q.target instanceof HTMLElement&&Q.target.dataset.dismissible==="false"||ie(!0)},onPointerUp:()=>ie(!1)},O.filter(Q=>!Q.position&&M===0||Q.position===z).map((Q,q)=>{var Ne,pe;return U.createElement(g0,{key:Q.id,icons:j,index:q,toast:Q,defaultRichColors:y,duration:(Ne=m==null?void 0:m.duration)!=null?Ne:w,className:m==null?void 0:m.className,descriptionClassName:m==null?void 0:m.descriptionClassName,invert:a,visibleToasts:b,closeButton:(pe=m==null?void 0:m.closeButton)!=null?pe:c,interacting:ee,position:z,style:m==null?void 0:m.style,unstyled:m==null?void 0:m.unstyled,classNames:m==null?void 0:m.classNames,cancelButtonStyle:m==null?void 0:m.cancelButtonStyle,actionButtonStyle:m==null?void 0:m.actionButtonStyle,closeButtonAriaLabel:m==null?void 0:m.closeButtonAriaLabel,removeToast:E,toasts:O.filter(Pe=>Pe.position==Q.position),heights:V.filter(Pe=>Pe.position==Q.position),setHeights:J,expandByDefault:o,gap:g,expanded:B,swipeDirections:t.swipeDirections})})):null}))});/**
68
- * @license lucide-react v0.294.0 - ISC
69
- *
70
- * This source code is licensed under the ISC license.
71
- * See the LICENSE file in the root directory of this source tree.
72
- */var w0={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};/**
73
- * @license lucide-react v0.294.0 - ISC
74
- *
75
- * This source code is licensed under the ISC license.
76
- * See the LICENSE file in the root directory of this source tree.
77
- */const b0=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase().trim(),ne=(e,t)=>{const r=h.forwardRef(({color:s="currentColor",size:a=24,strokeWidth:i=2,absoluteStrokeWidth:l,className:o="",children:c,...d},f)=>h.createElement("svg",{ref:f,...w0,width:a,height:a,stroke:s,strokeWidth:l?Number(i)*24/Number(a):i,className:["lucide",`lucide-${b0(e)}`,o].join(" "),...d},[...t.map(([u,x])=>h.createElement(u,x)),...Array.isArray(c)?c:[c]]));return r.displayName=`${e}`,r};/**
78
- * @license lucide-react v0.294.0 - ISC
79
- *
80
- * This source code is licensed under the ISC license.
81
- * See the LICENSE file in the root directory of this source tree.
82
- */const ar=ne("AlertTriangle",[["path",{d:"m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3Z",key:"c3ski4"}],["path",{d:"M12 9v4",key:"juzpu7"}],["path",{d:"M12 17h.01",key:"p32p05"}]]);/**
83
- * @license lucide-react v0.294.0 - ISC
84
- *
85
- * This source code is licensed under the ISC license.
86
- * See the LICENSE file in the root directory of this source tree.
87
- */const Ii=ne("ArrowLeft",[["path",{d:"m12 19-7-7 7-7",key:"1l729n"}],["path",{d:"M19 12H5",key:"x3x0zl"}]]);/**
88
- * @license lucide-react v0.294.0 - ISC
89
- *
90
- * This source code is licensed under the ISC license.
91
- * See the LICENSE file in the root directory of this source tree.
92
- */const tn=ne("ArrowRight",[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"m12 5 7 7-7 7",key:"xquz4c"}]]);/**
93
- * @license lucide-react v0.294.0 - ISC
94
- *
95
- * This source code is licensed under the ISC license.
96
- * See the LICENSE file in the root directory of this source tree.
97
- */const Vo=ne("BarChart3",[["path",{d:"M3 3v18h18",key:"1s2lah"}],["path",{d:"M18 17V9",key:"2bz60n"}],["path",{d:"M13 17V5",key:"1frdt8"}],["path",{d:"M8 17v-3",key:"17ska0"}]]);/**
98
- * @license lucide-react v0.294.0 - ISC
99
- *
100
- * This source code is licensed under the ISC license.
101
- * See the LICENSE file in the root directory of this source tree.
102
- */const j0=ne("Bell",[["path",{d:"M6 8a6 6 0 0 1 12 0c0 7 3 9 3 9H3s3-2 3-9",key:"1qo2s2"}],["path",{d:"M10.3 21a1.94 1.94 0 0 0 3.4 0",key:"qgo35s"}]]);/**
103
- * @license lucide-react v0.294.0 - ISC
104
- *
105
- * This source code is licensed under the ISC license.
106
- * See the LICENSE file in the root directory of this source tree.
107
- */const We=ne("Building2",[["path",{d:"M6 22V4a2 2 0 0 1 2-2h8a2 2 0 0 1 2 2v18Z",key:"1b4qmf"}],["path",{d:"M6 12H4a2 2 0 0 0-2 2v6a2 2 0 0 0 2 2h2",key:"i71pzd"}],["path",{d:"M18 9h2a2 2 0 0 1 2 2v9a2 2 0 0 1-2 2h-2",key:"10jefs"}],["path",{d:"M10 6h4",key:"1itunk"}],["path",{d:"M10 10h4",key:"tcdvrf"}],["path",{d:"M10 14h4",key:"kelpxr"}],["path",{d:"M10 18h4",key:"1ulq68"}]]);/**
108
- * @license lucide-react v0.294.0 - ISC
109
- *
110
- * This source code is licensed under the ISC license.
111
- * See the LICENSE file in the root directory of this source tree.
112
- */const bm=ne("Calendar",[["rect",{width:"18",height:"18",x:"3",y:"4",rx:"2",ry:"2",key:"eu3xkr"}],["line",{x1:"16",x2:"16",y1:"2",y2:"6",key:"m3sa8f"}],["line",{x1:"8",x2:"8",y1:"2",y2:"6",key:"18kwsl"}],["line",{x1:"3",x2:"21",y1:"10",y2:"10",key:"xt86sb"}]]);/**
113
- * @license lucide-react v0.294.0 - ISC
114
- *
115
- * This source code is licensed under the ISC license.
116
- * See the LICENSE file in the root directory of this source tree.
117
- */const Ie=ne("CheckCircle",[["path",{d:"M22 11.08V12a10 10 0 1 1-5.93-9.14",key:"g774vq"}],["path",{d:"m9 11 3 3L22 4",key:"1pflzl"}]]);/**
118
- * @license lucide-react v0.294.0 - ISC
119
- *
120
- * This source code is licensed under the ISC license.
121
- * See the LICENSE file in the root directory of this source tree.
122
- */const N0=ne("Check",[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]]);/**
123
- * @license lucide-react v0.294.0 - ISC
124
- *
125
- * This source code is licensed under the ISC license.
126
- * See the LICENSE file in the root directory of this source tree.
127
- */const jm=ne("ChevronDown",[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]]);/**
128
- * @license lucide-react v0.294.0 - ISC
129
- *
130
- * This source code is licensed under the ISC license.
131
- * See the LICENSE file in the root directory of this source tree.
132
- */const k0=ne("ChevronLeft",[["path",{d:"m15 18-6-6 6-6",key:"1wnfg3"}]]);/**
133
- * @license lucide-react v0.294.0 - ISC
134
- *
135
- * This source code is licensed under the ISC license.
136
- * See the LICENSE file in the root directory of this source tree.
137
- */const S0=ne("ChevronRight",[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]]);/**
138
- * @license lucide-react v0.294.0 - ISC
139
- *
140
- * This source code is licensed under the ISC license.
141
- * See the LICENSE file in the root directory of this source tree.
142
- */const C0=ne("ChevronUp",[["path",{d:"m18 15-6-6-6 6",key:"153udz"}]]);/**
143
- * @license lucide-react v0.294.0 - ISC
144
- *
145
- * This source code is licensed under the ISC license.
146
- * See the LICENSE file in the root directory of this source tree.
147
- */const _s=ne("Clock",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["polyline",{points:"12 6 12 12 16 14",key:"68esgv"}]]);/**
148
- * @license lucide-react v0.294.0 - ISC
149
- *
150
- * This source code is licensed under the ISC license.
151
- * See the LICENSE file in the root directory of this source tree.
152
- */const ze=ne("Database",[["ellipse",{cx:"12",cy:"5",rx:"9",ry:"3",key:"msslwz"}],["path",{d:"M3 5V19A9 3 0 0 0 21 19V5",key:"1wlel7"}],["path",{d:"M3 12A9 3 0 0 0 21 12",key:"mv7ke4"}]]);/**
153
- * @license lucide-react v0.294.0 - ISC
154
- *
155
- * This source code is licensed under the ISC license.
156
- * See the LICENSE file in the root directory of this source tree.
157
- */const el=ne("Eye",[["path",{d:"M2 12s3-7 10-7 10 7 10 7-3 7-10 7-10-7-10-7Z",key:"rwhkz3"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]]);/**
158
- * @license lucide-react v0.294.0 - ISC
159
- *
160
- * This source code is licensed under the ISC license.
161
- * See the LICENSE file in the root directory of this source tree.
162
- */const Qc=ne("Filter",[["polygon",{points:"22 3 2 3 10 12.46 10 19 14 21 14 12.46 22 3",key:"1yg77f"}]]);/**
163
- * @license lucide-react v0.294.0 - ISC
164
- *
165
- * This source code is licensed under the ISC license.
166
- * See the LICENSE file in the root directory of this source tree.
167
- */const Sn=ne("Globe",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 2a14.5 14.5 0 0 0 0 20 14.5 14.5 0 0 0 0-20",key:"13o1zl"}],["path",{d:"M2 12h20",key:"9i4pu4"}]]);/**
168
- * @license lucide-react v0.294.0 - ISC
169
- *
170
- * This source code is licensed under the ISC license.
171
- * See the LICENSE file in the root directory of this source tree.
172
- */const Es=ne("Info",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 16v-4",key:"1dtifu"}],["path",{d:"M12 8h.01",key:"e9boi3"}]]);/**
173
- * @license lucide-react v0.294.0 - ISC
174
- *
175
- * This source code is licensed under the ISC license.
176
- * See the LICENSE file in the root directory of this source tree.
177
- */const E0=ne("Key",[["circle",{cx:"7.5",cy:"15.5",r:"5.5",key:"yqb3hr"}],["path",{d:"m21 2-9.6 9.6",key:"1j0ho8"}],["path",{d:"m15.5 7.5 3 3L22 7l-3-3",key:"1rn1fs"}]]);/**
178
- * @license lucide-react v0.294.0 - ISC
179
- *
180
- * This source code is licensed under the ISC license.
181
- * See the LICENSE file in the root directory of this source tree.
182
- */const T0=ne("LayoutDashboard",[["rect",{width:"7",height:"9",x:"3",y:"3",rx:"1",key:"10lvy0"}],["rect",{width:"7",height:"5",x:"14",y:"3",rx:"1",key:"16une8"}],["rect",{width:"7",height:"9",x:"14",y:"12",rx:"1",key:"1hutg5"}],["rect",{width:"7",height:"5",x:"3",y:"16",rx:"1",key:"ldoo1y"}]]);/**
183
- * @license lucide-react v0.294.0 - ISC
184
- *
185
- * This source code is licensed under the ISC license.
186
- * See the LICENSE file in the root directory of this source tree.
187
- */const ut=ne("Loader",[["line",{x1:"12",x2:"12",y1:"2",y2:"6",key:"gza1u7"}],["line",{x1:"12",x2:"12",y1:"18",y2:"22",key:"1qhbu9"}],["line",{x1:"4.93",x2:"7.76",y1:"4.93",y2:"7.76",key:"xae44r"}],["line",{x1:"16.24",x2:"19.07",y1:"16.24",y2:"19.07",key:"bxnmvf"}],["line",{x1:"2",x2:"6",y1:"12",y2:"12",key:"89khin"}],["line",{x1:"18",x2:"22",y1:"12",y2:"12",key:"pb8tfm"}],["line",{x1:"4.93",x2:"7.76",y1:"19.07",y2:"16.24",key:"1uxjnu"}],["line",{x1:"16.24",x2:"19.07",y1:"7.76",y2:"4.93",key:"6duxfx"}]]);/**
188
- * @license lucide-react v0.294.0 - ISC
189
- *
190
- * This source code is licensed under the ISC license.
191
- * See the LICENSE file in the root directory of this source tree.
192
- */const Rl=ne("Lock",[["rect",{width:"18",height:"11",x:"3",y:"11",rx:"2",ry:"2",key:"1w4ew1"}],["path",{d:"M7 11V7a5 5 0 0 1 10 0v4",key:"fwvmzm"}]]);/**
193
- * @license lucide-react v0.294.0 - ISC
194
- *
195
- * This source code is licensed under the ISC license.
196
- * See the LICENSE file in the root directory of this source tree.
197
- */const _t=ne("Mail",[["rect",{width:"20",height:"16",x:"2",y:"4",rx:"2",key:"18n3k1"}],["path",{d:"m22 7-8.97 5.7a1.94 1.94 0 0 1-2.06 0L2 7",key:"1ocrg3"}]]);/**
198
- * @license lucide-react v0.294.0 - ISC
199
- *
200
- * This source code is licensed under the ISC license.
201
- * See the LICENSE file in the root directory of this source tree.
202
- */const P0=ne("MoreHorizontal",[["circle",{cx:"12",cy:"12",r:"1",key:"41hilf"}],["circle",{cx:"19",cy:"12",r:"1",key:"1wjl8i"}],["circle",{cx:"5",cy:"12",r:"1",key:"1pcz8c"}]]);/**
203
- * @license lucide-react v0.294.0 - ISC
204
- *
205
- * This source code is licensed under the ISC license.
206
- * See the LICENSE file in the root directory of this source tree.
207
- */const ls=ne("PenSquare",[["path",{d:"M11 4H4a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2v-7",key:"1qinfi"}],["path",{d:"M18.5 2.5a2.12 2.12 0 0 1 3 3L12 15l-4 1 1-4Z",key:"w2jsv5"}]]);/**
208
- * @license lucide-react v0.294.0 - ISC
209
- *
210
- * This source code is licensed under the ISC license.
211
- * See the LICENSE file in the root directory of this source tree.
212
- */const Vn=ne("Plus",[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]]);/**
213
- * @license lucide-react v0.294.0 - ISC
214
- *
215
- * This source code is licensed under the ISC license.
216
- * See the LICENSE file in the root directory of this source tree.
217
- */const Nu=ne("Puzzle",[["path",{d:"M19.439 7.85c-.049.322.059.648.289.878l1.568 1.568c.47.47.706 1.087.706 1.704s-.235 1.233-.706 1.704l-1.611 1.611a.98.98 0 0 1-.837.276c-.47-.07-.802-.48-.968-.925a2.501 2.501 0 1 0-3.214 3.214c.446.166.855.497.925.968a.979.979 0 0 1-.276.837l-1.61 1.61a2.404 2.404 0 0 1-1.705.707 2.402 2.402 0 0 1-1.704-.706l-1.568-1.568a1.026 1.026 0 0 0-.877-.29c-.493.074-.84.504-1.02.968a2.5 2.5 0 1 1-3.237-3.237c.464-.18.894-.527.967-1.02a1.026 1.026 0 0 0-.289-.877l-1.568-1.568A2.402 2.402 0 0 1 1.998 12c0-.617.236-1.234.706-1.704L4.23 8.77c.24-.24.581-.353.917-.303.515.077.877.528 1.073 1.01a2.5 2.5 0 1 0 3.259-3.259c-.482-.196-.933-.558-1.01-1.073-.05-.336.062-.676.303-.917l1.525-1.525A2.402 2.402 0 0 1 12 1.998c.617 0 1.234.236 1.704.706l1.568 1.568c.23.23.556.338.877.29.493-.074.84-.504 1.02-.968a2.5 2.5 0 1 1 3.237 3.237c-.464.18-.894.527-.967 1.02Z",key:"i0oyt7"}]]);/**
218
- * @license lucide-react v0.294.0 - ISC
219
- *
220
- * This source code is licensed under the ISC license.
221
- * See the LICENSE file in the root directory of this source tree.
222
- */const ku=ne("RefreshCw",[["path",{d:"M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8",key:"v9h5vc"}],["path",{d:"M21 3v5h-5",key:"1q7to0"}],["path",{d:"M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16",key:"3uifl3"}],["path",{d:"M8 16H3v5",key:"1cv678"}]]);/**
223
- * @license lucide-react v0.294.0 - ISC
224
- *
225
- * This source code is licensed under the ISC license.
226
- * See the LICENSE file in the root directory of this source tree.
227
- */const pn=ne("Search",[["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}],["path",{d:"m21 21-4.3-4.3",key:"1qie3q"}]]);/**
228
- * @license lucide-react v0.294.0 - ISC
229
- *
230
- * This source code is licensed under the ISC license.
231
- * See the LICENSE file in the root directory of this source tree.
232
- */const Su=ne("Send",[["path",{d:"m22 2-7 20-4-9-9-4Z",key:"1q3vgg"}],["path",{d:"M22 2 11 13",key:"nzbqef"}]]);/**
233
- * @license lucide-react v0.294.0 - ISC
234
- *
235
- * This source code is licensed under the ISC license.
236
- * See the LICENSE file in the root directory of this source tree.
237
- */const Jn=ne("Settings",[["path",{d:"M12.22 2h-.44a2 2 0 0 0-2 2v.18a2 2 0 0 1-1 1.73l-.43.25a2 2 0 0 1-2 0l-.15-.08a2 2 0 0 0-2.73.73l-.22.38a2 2 0 0 0 .73 2.73l.15.1a2 2 0 0 1 1 1.72v.51a2 2 0 0 1-1 1.74l-.15.09a2 2 0 0 0-.73 2.73l.22.38a2 2 0 0 0 2.73.73l.15-.08a2 2 0 0 1 2 0l.43.25a2 2 0 0 1 1 1.73V20a2 2 0 0 0 2 2h.44a2 2 0 0 0 2-2v-.18a2 2 0 0 1 1-1.73l.43-.25a2 2 0 0 1 2 0l.15.08a2 2 0 0 0 2.73-.73l.22-.39a2 2 0 0 0-.73-2.73l-.15-.08a2 2 0 0 1-1-1.74v-.5a2 2 0 0 1 1-1.74l.15-.09a2 2 0 0 0 .73-2.73l-.22-.38a2 2 0 0 0-2.73-.73l-.15.08a2 2 0 0 1-2 0l-.43-.25a2 2 0 0 1-1-1.73V4a2 2 0 0 0-2-2z",key:"1qme2f"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]]);/**
238
- * @license lucide-react v0.294.0 - ISC
239
- *
240
- * This source code is licensed under the ISC license.
241
- * See the LICENSE file in the root directory of this source tree.
242
- */const ir=ne("Shield",[["path",{d:"M12 22s8-4 8-10V5l-8-3-8 3v7c0 6 8 10 8 10",key:"1irkt0"}]]);/**
243
- * @license lucide-react v0.294.0 - ISC
244
- *
245
- * This source code is licensed under the ISC license.
246
- * See the LICENSE file in the root directory of this source tree.
247
- */const z0=ne("Terminal",[["polyline",{points:"4 17 10 11 4 5",key:"akl6gq"}],["line",{x1:"12",x2:"20",y1:"19",y2:"19",key:"q2wloq"}]]);/**
248
- * @license lucide-react v0.294.0 - ISC
249
- *
250
- * This source code is licensed under the ISC license.
251
- * See the LICENSE file in the root directory of this source tree.
252
- */const cn=ne("Trash2",[["path",{d:"M3 6h18",key:"d0wm0j"}],["path",{d:"M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6",key:"4alrt4"}],["path",{d:"M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2",key:"v07s0e"}],["line",{x1:"10",x2:"10",y1:"11",y2:"17",key:"1uufr5"}],["line",{x1:"14",x2:"14",y1:"11",y2:"17",key:"xtxkd"}]]);/**
253
- * @license lucide-react v0.294.0 - ISC
254
- *
255
- * This source code is licensed under the ISC license.
256
- * See the LICENSE file in the root directory of this source tree.
257
- */const Br=ne("UserPlus",[["path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2",key:"1yyitq"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}],["line",{x1:"19",x2:"19",y1:"8",y2:"14",key:"1bvyxn"}],["line",{x1:"22",x2:"16",y1:"11",y2:"11",key:"1shjgl"}]]);/**
258
- * @license lucide-react v0.294.0 - ISC
259
- *
260
- * This source code is licensed under the ISC license.
261
- * See the LICENSE file in the root directory of this source tree.
262
- */const Cu=ne("User",[["path",{d:"M19 21v-2a4 4 0 0 0-4-4H9a4 4 0 0 0-4 4v2",key:"975kel"}],["circle",{cx:"12",cy:"7",r:"4",key:"17ys0d"}]]);/**
263
- * @license lucide-react v0.294.0 - ISC
264
- *
265
- * This source code is licensed under the ISC license.
266
- * See the LICENSE file in the root directory of this source tree.
267
- */const xe=ne("Users",[["path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2",key:"1yyitq"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}],["path",{d:"M22 21v-2a4 4 0 0 0-3-3.87",key:"kshegd"}],["path",{d:"M16 3.13a4 4 0 0 1 0 7.75",key:"1da9ce"}]]);/**
268
- * @license lucide-react v0.294.0 - ISC
269
- *
270
- * This source code is licensed under the ISC license.
271
- * See the LICENSE file in the root directory of this source tree.
272
- */const rn=ne("XCircle",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m15 9-6 6",key:"1uzhvr"}],["path",{d:"m9 9 6 6",key:"z0biqf"}]]);/**
273
- * @license lucide-react v0.294.0 - ISC
274
- *
275
- * This source code is licensed under the ISC license.
276
- * See the LICENSE file in the root directory of this source tree.
277
- */const we=ne("X",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]]);/**
278
- * @license lucide-react v0.294.0 - ISC
279
- *
280
- * This source code is licensed under the ISC license.
281
- * See the LICENSE file in the root directory of this source tree.
282
- */const ii=ne("Zap",[["polygon",{points:"13 2 3 14 12 14 11 22 21 10 12 10 13 2",key:"45s27k"}]]);function Eu(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function xn(...e){return t=>{let r=!1;const s=e.map(a=>{const i=Eu(a,t);return!r&&typeof i=="function"&&(r=!0),i});if(r)return()=>{for(let a=0;a<s.length;a++){const i=s[a];typeof i=="function"?i():Eu(e[a],null)}}}}function jn(...e){return h.useCallback(xn(...e),e)}function Yc(e){const t=M0(e),r=h.forwardRef((s,a)=>{const{children:i,...l}=s,o=h.Children.toArray(i),c=o.find(I0);if(c){const d=c.props.children,f=o.map(u=>u===c?h.Children.count(d)>1?h.Children.only(null):h.isValidElement(d)?d.props.children:null:u);return n.jsx(t,{...l,ref:a,children:h.isValidElement(d)?h.cloneElement(d,void 0,f):null})}return n.jsx(t,{...l,ref:a,children:i})});return r.displayName=`${e}.Slot`,r}var D0=Yc("Slot");function M0(e){const t=h.forwardRef((r,s)=>{const{children:a,...i}=r;if(h.isValidElement(a)){const l=_0(a),o=L0(i,a.props);return a.type!==h.Fragment&&(o.ref=s?xn(s,l):l),h.cloneElement(a,o)}return h.Children.count(a)>1?h.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var R0=Symbol("radix.slottable");function I0(e){return h.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===R0}function L0(e,t){const r={...t};for(const s in t){const a=e[s],i=t[s];/^on[A-Z]/.test(s)?a&&i?r[s]=(...o)=>{const c=i(...o);return a(...o),c}:a&&(r[s]=a):s==="style"?r[s]={...a,...i}:s==="className"&&(r[s]=[a,i].filter(Boolean).join(" "))}return{...e,...r}}function _0(e){var s,a;let t=(s=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:s.get,r=t&&"isReactWarning"in t&&t.isReactWarning;return r?e.ref:(t=(a=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:a.get,r=t&&"isReactWarning"in t&&t.isReactWarning,r?e.props.ref:e.props.ref||e.ref)}function Nm(e){var t,r,s="";if(typeof e=="string"||typeof e=="number")s+=e;else if(typeof e=="object")if(Array.isArray(e)){var a=e.length;for(t=0;t<a;t++)e[t]&&(r=Nm(e[t]))&&(s&&(s+=" "),s+=r)}else for(r in e)e[r]&&(s&&(s+=" "),s+=r);return s}function km(){for(var e,t,r=0,s="",a=arguments.length;r<a;r++)(e=arguments[r])&&(t=Nm(e))&&(s&&(s+=" "),s+=t);return s}const Tu=e=>typeof e=="boolean"?`${e}`:e===0?"0":e,Pu=km,Sm=(e,t)=>r=>{var s;if((t==null?void 0:t.variants)==null)return Pu(e,r==null?void 0:r.class,r==null?void 0:r.className);const{variants:a,defaultVariants:i}=t,l=Object.keys(a).map(d=>{const f=r==null?void 0:r[d],u=i==null?void 0:i[d];if(f===null)return null;const x=Tu(f)||Tu(u);return a[d][x]}),o=r&&Object.entries(r).reduce((d,f)=>{let[u,x]=f;return x===void 0||(d[u]=x),d},{}),c=t==null||(s=t.compoundVariants)===null||s===void 0?void 0:s.reduce((d,f)=>{let{class:u,className:x,...y}=f;return Object.entries(y).every(w=>{let[v,b]=w;return Array.isArray(b)?b.includes({...i,...o}[v]):{...i,...o}[v]===b})?[...d,u,x]:d},[]);return Pu(e,l,c,r==null?void 0:r.class,r==null?void 0:r.className)},Gc="-",O0=e=>{const t=$0(e),{conflictingClassGroups:r,conflictingClassGroupModifiers:s}=e;return{getClassGroupId:l=>{const o=l.split(Gc);return o[0]===""&&o.length!==1&&o.shift(),Cm(o,t)||A0(l)},getConflictingClassGroupIds:(l,o)=>{const c=r[l]||[];return o&&s[l]?[...c,...s[l]]:c}}},Cm=(e,t)=>{var l;if(e.length===0)return t.classGroupId;const r=e[0],s=t.nextPart.get(r),a=s?Cm(e.slice(1),s):void 0;if(a)return a;if(t.validators.length===0)return;const i=e.join(Gc);return(l=t.validators.find(({validator:o})=>o(i)))==null?void 0:l.classGroupId},zu=/^\[(.+)\]$/,A0=e=>{if(zu.test(e)){const t=zu.exec(e)[1],r=t==null?void 0:t.substring(0,t.indexOf(":"));if(r)return"arbitrary.."+r}},$0=e=>{const{theme:t,prefix:r}=e,s={nextPart:new Map,validators:[]};return U0(Object.entries(e.classGroups),r).forEach(([i,l])=>{Wo(l,s,i,t)}),s},Wo=(e,t,r,s)=>{e.forEach(a=>{if(typeof a=="string"){const i=a===""?t:Du(t,a);i.classGroupId=r;return}if(typeof a=="function"){if(F0(a)){Wo(a(s),t,r,s);return}t.validators.push({validator:a,classGroupId:r});return}Object.entries(a).forEach(([i,l])=>{Wo(l,Du(t,i),r,s)})})},Du=(e,t)=>{let r=e;return t.split(Gc).forEach(s=>{r.nextPart.has(s)||r.nextPart.set(s,{nextPart:new Map,validators:[]}),r=r.nextPart.get(s)}),r},F0=e=>e.isThemeGetter,U0=(e,t)=>t?e.map(([r,s])=>{const a=s.map(i=>typeof i=="string"?t+i:typeof i=="object"?Object.fromEntries(Object.entries(i).map(([l,o])=>[t+l,o])):i);return[r,a]}):e,B0=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,r=new Map,s=new Map;const a=(i,l)=>{r.set(i,l),t++,t>e&&(t=0,s=r,r=new Map)};return{get(i){let l=r.get(i);if(l!==void 0)return l;if((l=s.get(i))!==void 0)return a(i,l),l},set(i,l){r.has(i)?r.set(i,l):a(i,l)}}},Em="!",V0=e=>{const{separator:t,experimentalParseClassName:r}=e,s=t.length===1,a=t[0],i=t.length,l=o=>{const c=[];let d=0,f=0,u;for(let b=0;b<o.length;b++){let m=o[b];if(d===0){if(m===a&&(s||o.slice(b,b+i)===t)){c.push(o.slice(f,b)),f=b+i;continue}if(m==="/"){u=b;continue}}m==="["?d++:m==="]"&&d--}const x=c.length===0?o:o.substring(f),y=x.startsWith(Em),w=y?x.substring(1):x,v=u&&u>f?u-f:void 0;return{modifiers:c,hasImportantModifier:y,baseClassName:w,maybePostfixModifierPosition:v}};return r?o=>r({className:o,parseClassName:l}):l},W0=e=>{if(e.length<=1)return e;const t=[];let r=[];return e.forEach(s=>{s[0]==="["?(t.push(...r.sort(),s),r=[]):r.push(s)}),t.push(...r.sort()),t},H0=e=>({cache:B0(e.cacheSize),parseClassName:V0(e),...O0(e)}),K0=/\s+/,Q0=(e,t)=>{const{parseClassName:r,getClassGroupId:s,getConflictingClassGroupIds:a}=t,i=[],l=e.trim().split(K0);let o="";for(let c=l.length-1;c>=0;c-=1){const d=l[c],{modifiers:f,hasImportantModifier:u,baseClassName:x,maybePostfixModifierPosition:y}=r(d);let w=!!y,v=s(w?x.substring(0,y):x);if(!v){if(!w){o=d+(o.length>0?" "+o:o);continue}if(v=s(x),!v){o=d+(o.length>0?" "+o:o);continue}w=!1}const b=W0(f).join(":"),m=u?b+Em:b,p=m+v;if(i.includes(p))continue;i.push(p);const g=a(v,w);for(let j=0;j<g.length;++j){const S=g[j];i.push(m+S)}o=d+(o.length>0?" "+o:o)}return o};function Y0(){let e=0,t,r,s="";for(;e<arguments.length;)(t=arguments[e++])&&(r=Tm(t))&&(s&&(s+=" "),s+=r);return s}const Tm=e=>{if(typeof e=="string")return e;let t,r="";for(let s=0;s<e.length;s++)e[s]&&(t=Tm(e[s]))&&(r&&(r+=" "),r+=t);return r};function G0(e,...t){let r,s,a,i=l;function l(c){const d=t.reduce((f,u)=>u(f),e());return r=H0(d),s=r.cache.get,a=r.cache.set,i=o,o(c)}function o(c){const d=s(c);if(d)return d;const f=Q0(c,r);return a(c,f),f}return function(){return i(Y0.apply(null,arguments))}}const ve=e=>{const t=r=>r[e]||[];return t.isThemeGetter=!0,t},Pm=/^\[(?:([a-z-]+):)?(.+)\]$/i,X0=/^\d+\/\d+$/,J0=new Set(["px","full","screen"]),Z0=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,q0=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,ey=/^(rgba?|hsla?|hwb|(ok)?(lab|lch))\(.+\)$/,ty=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,ry=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,lr=e=>Zn(e)||J0.has(e)||X0.test(e),jr=e=>xs(e,"length",dy),Zn=e=>!!e&&!Number.isNaN(Number(e)),Il=e=>xs(e,"number",Zn),Ts=e=>!!e&&Number.isInteger(Number(e)),ny=e=>e.endsWith("%")&&Zn(e.slice(0,-1)),re=e=>Pm.test(e),Nr=e=>Z0.test(e),sy=new Set(["length","size","percentage"]),ay=e=>xs(e,sy,zm),iy=e=>xs(e,"position",zm),ly=new Set(["image","url"]),oy=e=>xs(e,ly,hy),cy=e=>xs(e,"",uy),Ps=()=>!0,xs=(e,t,r)=>{const s=Pm.exec(e);return s?s[1]?typeof t=="string"?s[1]===t:t.has(s[1]):r(s[2]):!1},dy=e=>q0.test(e)&&!ey.test(e),zm=()=>!1,uy=e=>ty.test(e),hy=e=>ry.test(e),fy=()=>{const e=ve("colors"),t=ve("spacing"),r=ve("blur"),s=ve("brightness"),a=ve("borderColor"),i=ve("borderRadius"),l=ve("borderSpacing"),o=ve("borderWidth"),c=ve("contrast"),d=ve("grayscale"),f=ve("hueRotate"),u=ve("invert"),x=ve("gap"),y=ve("gradientColorStops"),w=ve("gradientColorStopPositions"),v=ve("inset"),b=ve("margin"),m=ve("opacity"),p=ve("padding"),g=ve("saturate"),j=ve("scale"),S=ve("sepia"),N=ve("skew"),C=ve("space"),O=ve("translate"),G=()=>["auto","contain","none"],V=()=>["auto","hidden","clip","visible","scroll"],J=()=>["auto",re,t],B=()=>[re,t],se=()=>["",lr,jr],ee=()=>["auto",Zn,re],ie=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],D=()=>["solid","dashed","dotted","double","none"],H=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],k=()=>["start","end","center","between","around","evenly","stretch"],A=()=>["","0",re],_=()=>["auto","avoid","all","avoid-page","page","left","right","column"],W=()=>[Zn,re];return{cacheSize:500,separator:":",theme:{colors:[Ps],spacing:[lr,jr],blur:["none","",Nr,re],brightness:W(),borderColor:[e],borderRadius:["none","","full",Nr,re],borderSpacing:B(),borderWidth:se(),contrast:W(),grayscale:A(),hueRotate:W(),invert:A(),gap:B(),gradientColorStops:[e],gradientColorStopPositions:[ny,jr],inset:J(),margin:J(),opacity:W(),padding:B(),saturate:W(),scale:W(),sepia:A(),skew:W(),space:B(),translate:B()},classGroups:{aspect:[{aspect:["auto","square","video",re]}],container:["container"],columns:[{columns:[Nr]}],"break-after":[{"break-after":_()}],"break-before":[{"break-before":_()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:[...ie(),re]}],overflow:[{overflow:V()}],"overflow-x":[{"overflow-x":V()}],"overflow-y":[{"overflow-y":V()}],overscroll:[{overscroll:G()}],"overscroll-x":[{"overscroll-x":G()}],"overscroll-y":[{"overscroll-y":G()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[v]}],"inset-x":[{"inset-x":[v]}],"inset-y":[{"inset-y":[v]}],start:[{start:[v]}],end:[{end:[v]}],top:[{top:[v]}],right:[{right:[v]}],bottom:[{bottom:[v]}],left:[{left:[v]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",Ts,re]}],basis:[{basis:J()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",re]}],grow:[{grow:A()}],shrink:[{shrink:A()}],order:[{order:["first","last","none",Ts,re]}],"grid-cols":[{"grid-cols":[Ps]}],"col-start-end":[{col:["auto",{span:["full",Ts,re]},re]}],"col-start":[{"col-start":ee()}],"col-end":[{"col-end":ee()}],"grid-rows":[{"grid-rows":[Ps]}],"row-start-end":[{row:["auto",{span:[Ts,re]},re]}],"row-start":[{"row-start":ee()}],"row-end":[{"row-end":ee()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",re]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",re]}],gap:[{gap:[x]}],"gap-x":[{"gap-x":[x]}],"gap-y":[{"gap-y":[x]}],"justify-content":[{justify:["normal",...k()]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal",...k(),"baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":[...k(),"baseline"]}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[p]}],px:[{px:[p]}],py:[{py:[p]}],ps:[{ps:[p]}],pe:[{pe:[p]}],pt:[{pt:[p]}],pr:[{pr:[p]}],pb:[{pb:[p]}],pl:[{pl:[p]}],m:[{m:[b]}],mx:[{mx:[b]}],my:[{my:[b]}],ms:[{ms:[b]}],me:[{me:[b]}],mt:[{mt:[b]}],mr:[{mr:[b]}],mb:[{mb:[b]}],ml:[{ml:[b]}],"space-x":[{"space-x":[C]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[C]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",re,t]}],"min-w":[{"min-w":[re,t,"min","max","fit"]}],"max-w":[{"max-w":[re,t,"none","full","min","max","fit","prose",{screen:[Nr]},Nr]}],h:[{h:[re,t,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[re,t,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[re,t,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[re,t,"auto","min","max","fit"]}],"font-size":[{text:["base",Nr,jr]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",Il]}],"font-family":[{font:[Ps]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractions"],tracking:[{tracking:["tighter","tight","normal","wide","wider","widest",re]}],"line-clamp":[{"line-clamp":["none",Zn,Il]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",lr,re]}],"list-image":[{"list-image":["none",re]}],"list-style-type":[{list:["none","disc","decimal",re]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[e]}],"placeholder-opacity":[{"placeholder-opacity":[m]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[e]}],"text-opacity":[{"text-opacity":[m]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...D(),"wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",lr,jr]}],"underline-offset":[{"underline-offset":["auto",lr,re]}],"text-decoration-color":[{decoration:[e]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:B()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",re]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",re]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[m]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[...ie(),iy]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",ay]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},oy]}],"bg-color":[{bg:[e]}],"gradient-from-pos":[{from:[w]}],"gradient-via-pos":[{via:[w]}],"gradient-to-pos":[{to:[w]}],"gradient-from":[{from:[y]}],"gradient-via":[{via:[y]}],"gradient-to":[{to:[y]}],rounded:[{rounded:[i]}],"rounded-s":[{"rounded-s":[i]}],"rounded-e":[{"rounded-e":[i]}],"rounded-t":[{"rounded-t":[i]}],"rounded-r":[{"rounded-r":[i]}],"rounded-b":[{"rounded-b":[i]}],"rounded-l":[{"rounded-l":[i]}],"rounded-ss":[{"rounded-ss":[i]}],"rounded-se":[{"rounded-se":[i]}],"rounded-ee":[{"rounded-ee":[i]}],"rounded-es":[{"rounded-es":[i]}],"rounded-tl":[{"rounded-tl":[i]}],"rounded-tr":[{"rounded-tr":[i]}],"rounded-br":[{"rounded-br":[i]}],"rounded-bl":[{"rounded-bl":[i]}],"border-w":[{border:[o]}],"border-w-x":[{"border-x":[o]}],"border-w-y":[{"border-y":[o]}],"border-w-s":[{"border-s":[o]}],"border-w-e":[{"border-e":[o]}],"border-w-t":[{"border-t":[o]}],"border-w-r":[{"border-r":[o]}],"border-w-b":[{"border-b":[o]}],"border-w-l":[{"border-l":[o]}],"border-opacity":[{"border-opacity":[m]}],"border-style":[{border:[...D(),"hidden"]}],"divide-x":[{"divide-x":[o]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[o]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[m]}],"divide-style":[{divide:D()}],"border-color":[{border:[a]}],"border-color-x":[{"border-x":[a]}],"border-color-y":[{"border-y":[a]}],"border-color-s":[{"border-s":[a]}],"border-color-e":[{"border-e":[a]}],"border-color-t":[{"border-t":[a]}],"border-color-r":[{"border-r":[a]}],"border-color-b":[{"border-b":[a]}],"border-color-l":[{"border-l":[a]}],"divide-color":[{divide:[a]}],"outline-style":[{outline:["",...D()]}],"outline-offset":[{"outline-offset":[lr,re]}],"outline-w":[{outline:[lr,jr]}],"outline-color":[{outline:[e]}],"ring-w":[{ring:se()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[e]}],"ring-opacity":[{"ring-opacity":[m]}],"ring-offset-w":[{"ring-offset":[lr,jr]}],"ring-offset-color":[{"ring-offset":[e]}],shadow:[{shadow:["","inner","none",Nr,cy]}],"shadow-color":[{shadow:[Ps]}],opacity:[{opacity:[m]}],"mix-blend":[{"mix-blend":[...H(),"plus-lighter","plus-darker"]}],"bg-blend":[{"bg-blend":H()}],filter:[{filter:["","none"]}],blur:[{blur:[r]}],brightness:[{brightness:[s]}],contrast:[{contrast:[c]}],"drop-shadow":[{"drop-shadow":["","none",Nr,re]}],grayscale:[{grayscale:[d]}],"hue-rotate":[{"hue-rotate":[f]}],invert:[{invert:[u]}],saturate:[{saturate:[g]}],sepia:[{sepia:[S]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[r]}],"backdrop-brightness":[{"backdrop-brightness":[s]}],"backdrop-contrast":[{"backdrop-contrast":[c]}],"backdrop-grayscale":[{"backdrop-grayscale":[d]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[f]}],"backdrop-invert":[{"backdrop-invert":[u]}],"backdrop-opacity":[{"backdrop-opacity":[m]}],"backdrop-saturate":[{"backdrop-saturate":[g]}],"backdrop-sepia":[{"backdrop-sepia":[S]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[l]}],"border-spacing-x":[{"border-spacing-x":[l]}],"border-spacing-y":[{"border-spacing-y":[l]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",re]}],duration:[{duration:W()}],ease:[{ease:["linear","in","out","in-out",re]}],delay:[{delay:W()}],animate:[{animate:["none","spin","ping","pulse","bounce",re]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[j]}],"scale-x":[{"scale-x":[j]}],"scale-y":[{"scale-y":[j]}],rotate:[{rotate:[Ts,re]}],"translate-x":[{"translate-x":[O]}],"translate-y":[{"translate-y":[O]}],"skew-x":[{"skew-x":[N]}],"skew-y":[{"skew-y":[N]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",re]}],accent:[{accent:["auto",e]}],appearance:[{appearance:["none","auto"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",re]}],"caret-color":[{caret:[e]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":B()}],"scroll-mx":[{"scroll-mx":B()}],"scroll-my":[{"scroll-my":B()}],"scroll-ms":[{"scroll-ms":B()}],"scroll-me":[{"scroll-me":B()}],"scroll-mt":[{"scroll-mt":B()}],"scroll-mr":[{"scroll-mr":B()}],"scroll-mb":[{"scroll-mb":B()}],"scroll-ml":[{"scroll-ml":B()}],"scroll-p":[{"scroll-p":B()}],"scroll-px":[{"scroll-px":B()}],"scroll-py":[{"scroll-py":B()}],"scroll-ps":[{"scroll-ps":B()}],"scroll-pe":[{"scroll-pe":B()}],"scroll-pt":[{"scroll-pt":B()}],"scroll-pr":[{"scroll-pr":B()}],"scroll-pb":[{"scroll-pb":B()}],"scroll-pl":[{"scroll-pl":B()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",re]}],fill:[{fill:[e,"none"]}],"stroke-w":[{stroke:[lr,jr,Il]}],stroke:[{stroke:[e,"none"]}],sr:["sr-only","not-sr-only"],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-s","border-color-e","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]}}},my=G0(fy);function Jr(...e){return my(km(e))}const py=Sm("inline-flex items-center justify-center whitespace-nowrap rounded-lg text-sm font-medium transition-colors focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:pointer-events-none disabled:opacity-50",{variants:{variant:{default:"bg-white text-black hover:bg-white shadow",destructive:"bg-red-500 text-white hover:bg-red-600 shadow",outline:"border border-white bg-black hover:bg-black hover:text-white",secondary:"bg-black text-white hover:bg-black shadow border border-white",ghost:"hover:bg-black text-white hover:text-white",link:"text-white underline-offset-4 hover:underline"},size:{default:"h-9 px-4 py-2",sm:"h-8 rounded-md px-3 text-xs",lg:"h-10 rounded-md px-8",icon:"h-9 w-9"}},defaultVariants:{variant:"default",size:"default"}}),T=h.forwardRef(({className:e,variant:t,size:r,asChild:s=!1,...a},i)=>{const l=s?D0:"button";return n.jsx(l,{className:Jr(py({variant:t,size:r,className:e})),ref:i,...a})});T.displayName="Button";const xy=Sm("inline-flex items-center rounded-full border px-2.5 py-0.5 text-xs font-semibold transition-colors focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2",{variants:{variant:{default:"border-transparent bg-white text-black hover:bg-white",secondary:"border-transparent bg-gray-800 text-white hover:bg-gray-800 border border-gray-600",destructive:"border-transparent bg-red-500 text-white hover:bg-red-600",outline:"text-gray-300 border-gray-600",success:"border-transparent bg-green-900 text-green-300",warning:"border-transparent bg-yellow-900 text-yellow-300",error:"border-transparent bg-red-900 text-red-300",info:"border-transparent bg-gray-800 text-white border border-gray-600"}},defaultVariants:{variant:"default"}});function oe({className:e,variant:t,...r}){return n.jsx("div",{className:Jr(xy({variant:t}),e),...r})}var Mu=1,gy=.9,vy=.8,yy=.17,Ll=.1,_l=.999,wy=.9999,by=.99,jy=/[\\\/_+.#"@\[\(\{&]/,Ny=/[\\\/_+.#"@\[\(\{&]/g,ky=/[\s-]/,Dm=/[\s-]/g;function Ho(e,t,r,s,a,i,l){if(i===t.length)return a===e.length?Mu:by;var o=`${a},${i}`;if(l[o]!==void 0)return l[o];for(var c=s.charAt(i),d=r.indexOf(c,a),f=0,u,x,y,w;d>=0;)u=Ho(e,t,r,s,d+1,i+1,l),u>f&&(d===a?u*=Mu:jy.test(e.charAt(d-1))?(u*=vy,y=e.slice(a,d-1).match(Ny),y&&a>0&&(u*=Math.pow(_l,y.length))):ky.test(e.charAt(d-1))?(u*=gy,w=e.slice(a,d-1).match(Dm),w&&a>0&&(u*=Math.pow(_l,w.length))):(u*=yy,a>0&&(u*=Math.pow(_l,d-a))),e.charAt(d)!==t.charAt(i)&&(u*=wy)),(u<Ll&&r.charAt(d-1)===s.charAt(i+1)||s.charAt(i+1)===s.charAt(i)&&r.charAt(d-1)!==s.charAt(i))&&(x=Ho(e,t,r,s,d+1,i+2,l),x*Ll>u&&(u=x*Ll)),u>f&&(f=u),d=r.indexOf(c,d+1);return l[o]=f,f}function Ru(e){return e.toLowerCase().replace(Dm," ")}function Sy(e,t,r){return e=r&&r.length>0?`${e+" "+r.join(" ")}`:e,Ho(e,t,Ru(e),Ru(t),0,0,{})}function Vr(e,t,{checkForDefaultPrevented:r=!0}={}){return function(a){if(e==null||e(a),r===!1||!a.defaultPrevented)return t==null?void 0:t(a)}}function Cy(e,t){const r=h.createContext(t),s=i=>{const{children:l,...o}=i,c=h.useMemo(()=>o,Object.values(o));return n.jsx(r.Provider,{value:c,children:l})};s.displayName=e+"Provider";function a(i){const l=h.useContext(r);if(l)return l;if(t!==void 0)return t;throw new Error(`\`${i}\` must be used within \`${e}\``)}return[s,a]}function Ey(e,t=[]){let r=[];function s(i,l){const o=h.createContext(l),c=r.length;r=[...r,l];const d=u=>{var m;const{scope:x,children:y,...w}=u,v=((m=x==null?void 0:x[e])==null?void 0:m[c])||o,b=h.useMemo(()=>w,Object.values(w));return n.jsx(v.Provider,{value:b,children:y})};d.displayName=i+"Provider";function f(u,x){var v;const y=((v=x==null?void 0:x[e])==null?void 0:v[c])||o,w=h.useContext(y);if(w)return w;if(l!==void 0)return l;throw new Error(`\`${u}\` must be used within \`${i}\``)}return[d,f]}const a=()=>{const i=r.map(l=>h.createContext(l));return function(o){const c=(o==null?void 0:o[e])||i;return h.useMemo(()=>({[`__scope${e}`]:{...o,[e]:c}}),[o,c])}};return a.scopeName=e,[s,Ty(a,...t)]}function Ty(...e){const t=e[0];if(e.length===1)return t;const r=()=>{const s=e.map(a=>({useScope:a(),scopeName:a.scopeName}));return function(i){const l=s.reduce((o,{useScope:c,scopeName:d})=>{const u=c(i)[`__scope${d}`];return{...o,...u}},{});return h.useMemo(()=>({[`__scope${t.scopeName}`]:l}),[l])}};return r.scopeName=t.scopeName,r}var ua=globalThis!=null&&globalThis.document?h.useLayoutEffect:()=>{},Py=qo[" useId ".trim().toString()]||(()=>{}),zy=0;function fr(e){const[t,r]=h.useState(Py());return ua(()=>{r(s=>s??String(zy++))},[e]),t?`radix-${t}`:""}var Dy=qo[" useInsertionEffect ".trim().toString()]||ua;function My({prop:e,defaultProp:t,onChange:r=()=>{},caller:s}){const[a,i,l]=Ry({defaultProp:t,onChange:r}),o=e!==void 0,c=o?e:a;{const f=h.useRef(e!==void 0);h.useEffect(()=>{const u=f.current;u!==o&&console.warn(`${s} is changing from ${u?"controlled":"uncontrolled"} to ${o?"controlled":"uncontrolled"}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`),f.current=o},[o,s])}const d=h.useCallback(f=>{var u;if(o){const x=Iy(f)?f(e):f;x!==e&&((u=l.current)==null||u.call(l,x))}else i(f)},[o,e,i,l]);return[c,d]}function Ry({defaultProp:e,onChange:t}){const[r,s]=h.useState(e),a=h.useRef(r),i=h.useRef(t);return Dy(()=>{i.current=t},[t]),h.useEffect(()=>{var l;a.current!==r&&((l=i.current)==null||l.call(i,r),a.current=r)},[r,a]),[r,s,i]}function Iy(e){return typeof e=="function"}var Ly=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],Qe=Ly.reduce((e,t)=>{const r=Yc(`Primitive.${t}`),s=h.forwardRef((a,i)=>{const{asChild:l,...o}=a,c=l?r:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),n.jsx(c,{...o,ref:i})});return s.displayName=`Primitive.${t}`,{...e,[t]:s}},{});function _y(e,t){e&&Wc.flushSync(()=>e.dispatchEvent(t))}function ha(e){const t=h.useRef(e);return h.useEffect(()=>{t.current=e}),h.useMemo(()=>(...r)=>{var s;return(s=t.current)==null?void 0:s.call(t,...r)},[])}function Oy(e,t=globalThis==null?void 0:globalThis.document){const r=ha(e);h.useEffect(()=>{const s=a=>{a.key==="Escape"&&r(a)};return t.addEventListener("keydown",s,{capture:!0}),()=>t.removeEventListener("keydown",s,{capture:!0})},[r,t])}var Ay="DismissableLayer",Ko="dismissableLayer.update",$y="dismissableLayer.pointerDownOutside",Fy="dismissableLayer.focusOutside",Iu,Mm=h.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),Rm=h.forwardRef((e,t)=>{const{disableOutsidePointerEvents:r=!1,onEscapeKeyDown:s,onPointerDownOutside:a,onFocusOutside:i,onInteractOutside:l,onDismiss:o,...c}=e,d=h.useContext(Mm),[f,u]=h.useState(null),x=(f==null?void 0:f.ownerDocument)??(globalThis==null?void 0:globalThis.document),[,y]=h.useState({}),w=jn(t,C=>u(C)),v=Array.from(d.layers),[b]=[...d.layersWithOutsidePointerEventsDisabled].slice(-1),m=v.indexOf(b),p=f?v.indexOf(f):-1,g=d.layersWithOutsidePointerEventsDisabled.size>0,j=p>=m,S=Vy(C=>{const O=C.target,G=[...d.branches].some(V=>V.contains(O));!j||G||(a==null||a(C),l==null||l(C),C.defaultPrevented||o==null||o())},x),N=Wy(C=>{const O=C.target;[...d.branches].some(V=>V.contains(O))||(i==null||i(C),l==null||l(C),C.defaultPrevented||o==null||o())},x);return Oy(C=>{p===d.layers.size-1&&(s==null||s(C),!C.defaultPrevented&&o&&(C.preventDefault(),o()))},x),h.useEffect(()=>{if(f)return r&&(d.layersWithOutsidePointerEventsDisabled.size===0&&(Iu=x.body.style.pointerEvents,x.body.style.pointerEvents="none"),d.layersWithOutsidePointerEventsDisabled.add(f)),d.layers.add(f),Lu(),()=>{r&&d.layersWithOutsidePointerEventsDisabled.size===1&&(x.body.style.pointerEvents=Iu)}},[f,x,r,d]),h.useEffect(()=>()=>{f&&(d.layers.delete(f),d.layersWithOutsidePointerEventsDisabled.delete(f),Lu())},[f,d]),h.useEffect(()=>{const C=()=>y({});return document.addEventListener(Ko,C),()=>document.removeEventListener(Ko,C)},[]),n.jsx(Qe.div,{...c,ref:w,style:{pointerEvents:g?j?"auto":"none":void 0,...e.style},onFocusCapture:Vr(e.onFocusCapture,N.onFocusCapture),onBlurCapture:Vr(e.onBlurCapture,N.onBlurCapture),onPointerDownCapture:Vr(e.onPointerDownCapture,S.onPointerDownCapture)})});Rm.displayName=Ay;var Uy="DismissableLayerBranch",By=h.forwardRef((e,t)=>{const r=h.useContext(Mm),s=h.useRef(null),a=jn(t,s);return h.useEffect(()=>{const i=s.current;if(i)return r.branches.add(i),()=>{r.branches.delete(i)}},[r.branches]),n.jsx(Qe.div,{...e,ref:a})});By.displayName=Uy;function Vy(e,t=globalThis==null?void 0:globalThis.document){const r=ha(e),s=h.useRef(!1),a=h.useRef(()=>{});return h.useEffect(()=>{const i=o=>{if(o.target&&!s.current){let c=function(){Im($y,r,d,{discrete:!0})};const d={originalEvent:o};o.pointerType==="touch"?(t.removeEventListener("click",a.current),a.current=c,t.addEventListener("click",a.current,{once:!0})):c()}else t.removeEventListener("click",a.current);s.current=!1},l=window.setTimeout(()=>{t.addEventListener("pointerdown",i)},0);return()=>{window.clearTimeout(l),t.removeEventListener("pointerdown",i),t.removeEventListener("click",a.current)}},[t,r]),{onPointerDownCapture:()=>s.current=!0}}function Wy(e,t=globalThis==null?void 0:globalThis.document){const r=ha(e),s=h.useRef(!1);return h.useEffect(()=>{const a=i=>{i.target&&!s.current&&Im(Fy,r,{originalEvent:i},{discrete:!1})};return t.addEventListener("focusin",a),()=>t.removeEventListener("focusin",a)},[t,r]),{onFocusCapture:()=>s.current=!0,onBlurCapture:()=>s.current=!1}}function Lu(){const e=new CustomEvent(Ko);document.dispatchEvent(e)}function Im(e,t,r,{discrete:s}){const a=r.originalEvent.target,i=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:r});t&&a.addEventListener(e,t,{once:!0}),s?_y(a,i):a.dispatchEvent(i)}var Ol="focusScope.autoFocusOnMount",Al="focusScope.autoFocusOnUnmount",_u={bubbles:!1,cancelable:!0},Hy="FocusScope",Lm=h.forwardRef((e,t)=>{const{loop:r=!1,trapped:s=!1,onMountAutoFocus:a,onUnmountAutoFocus:i,...l}=e,[o,c]=h.useState(null),d=ha(a),f=ha(i),u=h.useRef(null),x=jn(t,v=>c(v)),y=h.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;h.useEffect(()=>{if(s){let v=function(g){if(y.paused||!o)return;const j=g.target;o.contains(j)?u.current=j:Sr(u.current,{select:!0})},b=function(g){if(y.paused||!o)return;const j=g.relatedTarget;j!==null&&(o.contains(j)||Sr(u.current,{select:!0}))},m=function(g){if(document.activeElement===document.body)for(const S of g)S.removedNodes.length>0&&Sr(o)};document.addEventListener("focusin",v),document.addEventListener("focusout",b);const p=new MutationObserver(m);return o&&p.observe(o,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",v),document.removeEventListener("focusout",b),p.disconnect()}}},[s,o,y.paused]),h.useEffect(()=>{if(o){Au.add(y);const v=document.activeElement;if(!o.contains(v)){const m=new CustomEvent(Ol,_u);o.addEventListener(Ol,d),o.dispatchEvent(m),m.defaultPrevented||(Ky(Jy(_m(o)),{select:!0}),document.activeElement===v&&Sr(o))}return()=>{o.removeEventListener(Ol,d),setTimeout(()=>{const m=new CustomEvent(Al,_u);o.addEventListener(Al,f),o.dispatchEvent(m),m.defaultPrevented||Sr(v??document.body,{select:!0}),o.removeEventListener(Al,f),Au.remove(y)},0)}}},[o,d,f,y]);const w=h.useCallback(v=>{if(!r&&!s||y.paused)return;const b=v.key==="Tab"&&!v.altKey&&!v.ctrlKey&&!v.metaKey,m=document.activeElement;if(b&&m){const p=v.currentTarget,[g,j]=Qy(p);g&&j?!v.shiftKey&&m===j?(v.preventDefault(),r&&Sr(g,{select:!0})):v.shiftKey&&m===g&&(v.preventDefault(),r&&Sr(j,{select:!0})):m===p&&v.preventDefault()}},[r,s,y.paused]);return n.jsx(Qe.div,{tabIndex:-1,...l,ref:x,onKeyDown:w})});Lm.displayName=Hy;function Ky(e,{select:t=!1}={}){const r=document.activeElement;for(const s of e)if(Sr(s,{select:t}),document.activeElement!==r)return}function Qy(e){const t=_m(e),r=Ou(t,e),s=Ou(t.reverse(),e);return[r,s]}function _m(e){const t=[],r=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:s=>{const a=s.tagName==="INPUT"&&s.type==="hidden";return s.disabled||s.hidden||a?NodeFilter.FILTER_SKIP:s.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;r.nextNode();)t.push(r.currentNode);return t}function Ou(e,t){for(const r of e)if(!Yy(r,{upTo:t}))return r}function Yy(e,{upTo:t}){if(getComputedStyle(e).visibility==="hidden")return!0;for(;e;){if(t!==void 0&&e===t)return!1;if(getComputedStyle(e).display==="none")return!0;e=e.parentElement}return!1}function Gy(e){return e instanceof HTMLInputElement&&"select"in e}function Sr(e,{select:t=!1}={}){if(e&&e.focus){const r=document.activeElement;e.focus({preventScroll:!0}),e!==r&&Gy(e)&&t&&e.select()}}var Au=Xy();function Xy(){let e=[];return{add(t){const r=e[0];t!==r&&(r==null||r.pause()),e=$u(e,t),e.unshift(t)},remove(t){var r;e=$u(e,t),(r=e[0])==null||r.resume()}}}function $u(e,t){const r=[...e],s=r.indexOf(t);return s!==-1&&r.splice(s,1),r}function Jy(e){return e.filter(t=>t.tagName!=="A")}var Zy="Portal",Om=h.forwardRef((e,t)=>{var o;const{container:r,...s}=e,[a,i]=h.useState(!1);ua(()=>i(!0),[]);const l=r||a&&((o=globalThis==null?void 0:globalThis.document)==null?void 0:o.body);return l?lm.createPortal(n.jsx(Qe.div,{...s,ref:t}),l):null});Om.displayName=Zy;function qy(e,t){return h.useReducer((r,s)=>t[r][s]??r,e)}var tl=e=>{const{present:t,children:r}=e,s=ew(t),a=typeof r=="function"?r({present:s.isPresent}):h.Children.only(r),i=jn(s.ref,tw(a));return typeof r=="function"||s.isPresent?h.cloneElement(a,{ref:i}):null};tl.displayName="Presence";function ew(e){const[t,r]=h.useState(),s=h.useRef(null),a=h.useRef(e),i=h.useRef("none"),l=e?"mounted":"unmounted",[o,c]=qy(l,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return h.useEffect(()=>{const d=Va(s.current);i.current=o==="mounted"?d:"none"},[o]),ua(()=>{const d=s.current,f=a.current;if(f!==e){const x=i.current,y=Va(d);e?c("MOUNT"):y==="none"||(d==null?void 0:d.display)==="none"?c("UNMOUNT"):c(f&&x!==y?"ANIMATION_OUT":"UNMOUNT"),a.current=e}},[e,c]),ua(()=>{if(t){let d;const f=t.ownerDocument.defaultView??window,u=y=>{const v=Va(s.current).includes(CSS.escape(y.animationName));if(y.target===t&&v&&(c("ANIMATION_END"),!a.current)){const b=t.style.animationFillMode;t.style.animationFillMode="forwards",d=f.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=b)})}},x=y=>{y.target===t&&(i.current=Va(s.current))};return t.addEventListener("animationstart",x),t.addEventListener("animationcancel",u),t.addEventListener("animationend",u),()=>{f.clearTimeout(d),t.removeEventListener("animationstart",x),t.removeEventListener("animationcancel",u),t.removeEventListener("animationend",u)}}else c("ANIMATION_END")},[t,c]),{isPresent:["mounted","unmountSuspended"].includes(o),ref:h.useCallback(d=>{s.current=d?getComputedStyle(d):null,r(d)},[])}}function Va(e){return(e==null?void 0:e.animationName)||"none"}function tw(e){var s,a;let t=(s=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:s.get,r=t&&"isReactWarning"in t&&t.isReactWarning;return r?e.ref:(t=(a=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:a.get,r=t&&"isReactWarning"in t&&t.isReactWarning,r?e.props.ref:e.props.ref||e.ref)}var $l=0;function rw(){h.useEffect(()=>{const e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",e[0]??Fu()),document.body.insertAdjacentElement("beforeend",e[1]??Fu()),$l++,()=>{$l===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(t=>t.remove()),$l--}},[])}function Fu(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.outline="none",e.style.opacity="0",e.style.position="fixed",e.style.pointerEvents="none",e}var qt=function(){return qt=Object.assign||function(t){for(var r,s=1,a=arguments.length;s<a;s++){r=arguments[s];for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&(t[i]=r[i])}return t},qt.apply(this,arguments)};function Am(e,t){var r={};for(var s in e)Object.prototype.hasOwnProperty.call(e,s)&&t.indexOf(s)<0&&(r[s]=e[s]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var a=0,s=Object.getOwnPropertySymbols(e);a<s.length;a++)t.indexOf(s[a])<0&&Object.prototype.propertyIsEnumerable.call(e,s[a])&&(r[s[a]]=e[s[a]]);return r}function nw(e,t,r){if(r||arguments.length===2)for(var s=0,a=t.length,i;s<a;s++)(i||!(s in t))&&(i||(i=Array.prototype.slice.call(t,0,s)),i[s]=t[s]);return e.concat(i||Array.prototype.slice.call(t))}var li="right-scroll-bar-position",oi="width-before-scroll-bar",sw="with-scroll-bars-hidden",aw="--removed-body-scroll-bar-size";function Fl(e,t){return typeof e=="function"?e(t):e&&(e.current=t),e}function iw(e,t){var r=h.useState(function(){return{value:e,callback:t,facade:{get current(){return r.value},set current(s){var a=r.value;a!==s&&(r.value=s,r.callback(s,a))}}}})[0];return r.callback=t,r.facade}var lw=typeof window<"u"?h.useLayoutEffect:h.useEffect,Uu=new WeakMap;function ow(e,t){var r=iw(null,function(s){return e.forEach(function(a){return Fl(a,s)})});return lw(function(){var s=Uu.get(r);if(s){var a=new Set(s),i=new Set(e),l=r.current;a.forEach(function(o){i.has(o)||Fl(o,null)}),i.forEach(function(o){a.has(o)||Fl(o,l)})}Uu.set(r,e)},[e]),r}function cw(e){return e}function dw(e,t){t===void 0&&(t=cw);var r=[],s=!1,a={read:function(){if(s)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return r.length?r[r.length-1]:e},useMedium:function(i){var l=t(i,s);return r.push(l),function(){r=r.filter(function(o){return o!==l})}},assignSyncMedium:function(i){for(s=!0;r.length;){var l=r;r=[],l.forEach(i)}r={push:function(o){return i(o)},filter:function(){return r}}},assignMedium:function(i){s=!0;var l=[];if(r.length){var o=r;r=[],o.forEach(i),l=r}var c=function(){var f=l;l=[],f.forEach(i)},d=function(){return Promise.resolve().then(c)};d(),r={push:function(f){l.push(f),d()},filter:function(f){return l=l.filter(f),r}}}};return a}function uw(e){e===void 0&&(e={});var t=dw(null);return t.options=qt({async:!0,ssr:!1},e),t}var $m=function(e){var t=e.sideCar,r=Am(e,["sideCar"]);if(!t)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var s=t.read();if(!s)throw new Error("Sidecar medium not found");return h.createElement(s,qt({},r))};$m.isSideCarExport=!0;function hw(e,t){return e.useMedium(t),$m}var Fm=uw(),Ul=function(){},rl=h.forwardRef(function(e,t){var r=h.useRef(null),s=h.useState({onScrollCapture:Ul,onWheelCapture:Ul,onTouchMoveCapture:Ul}),a=s[0],i=s[1],l=e.forwardProps,o=e.children,c=e.className,d=e.removeScrollBar,f=e.enabled,u=e.shards,x=e.sideCar,y=e.noRelative,w=e.noIsolation,v=e.inert,b=e.allowPinchZoom,m=e.as,p=m===void 0?"div":m,g=e.gapMode,j=Am(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noRelative","noIsolation","inert","allowPinchZoom","as","gapMode"]),S=x,N=ow([r,t]),C=qt(qt({},j),a);return h.createElement(h.Fragment,null,f&&h.createElement(S,{sideCar:Fm,removeScrollBar:d,shards:u,noRelative:y,noIsolation:w,inert:v,setCallbacks:i,allowPinchZoom:!!b,lockRef:r,gapMode:g}),l?h.cloneElement(h.Children.only(o),qt(qt({},C),{ref:N})):h.createElement(p,qt({},C,{className:c,ref:N}),o))});rl.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1};rl.classNames={fullWidth:oi,zeroRight:li};var fw=function(){if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function mw(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=fw();return t&&e.setAttribute("nonce",t),e}function pw(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function xw(e){var t=document.head||document.getElementsByTagName("head")[0];t.appendChild(e)}var gw=function(){var e=0,t=null;return{add:function(r){e==0&&(t=mw())&&(pw(t,r),xw(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},vw=function(){var e=gw();return function(t,r){h.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&r])}},Um=function(){var e=vw(),t=function(r){var s=r.styles,a=r.dynamic;return e(s,a),null};return t},yw={left:0,top:0,right:0,gap:0},Bl=function(e){return parseInt(e||"",10)||0},ww=function(e){var t=window.getComputedStyle(document.body),r=t[e==="padding"?"paddingLeft":"marginLeft"],s=t[e==="padding"?"paddingTop":"marginTop"],a=t[e==="padding"?"paddingRight":"marginRight"];return[Bl(r),Bl(s),Bl(a)]},bw=function(e){if(e===void 0&&(e="margin"),typeof window>"u")return yw;var t=ww(e),r=document.documentElement.clientWidth,s=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,s-r+t[2]-t[0])}},jw=Um(),qn="data-scroll-locked",Nw=function(e,t,r,s){var a=e.left,i=e.top,l=e.right,o=e.gap;return r===void 0&&(r="margin"),`
283
- .`.concat(sw,` {
284
- overflow: hidden `).concat(s,`;
285
- padding-right: `).concat(o,"px ").concat(s,`;
286
- }
287
- body[`).concat(qn,`] {
288
- overflow: hidden `).concat(s,`;
289
- overscroll-behavior: contain;
290
- `).concat([t&&"position: relative ".concat(s,";"),r==="margin"&&`
291
- padding-left: `.concat(a,`px;
292
- padding-top: `).concat(i,`px;
293
- padding-right: `).concat(l,`px;
294
- margin-left:0;
295
- margin-top:0;
296
- margin-right: `).concat(o,"px ").concat(s,`;
297
- `),r==="padding"&&"padding-right: ".concat(o,"px ").concat(s,";")].filter(Boolean).join(""),`
298
- }
299
-
300
- .`).concat(li,` {
301
- right: `).concat(o,"px ").concat(s,`;
302
- }
303
-
304
- .`).concat(oi,` {
305
- margin-right: `).concat(o,"px ").concat(s,`;
306
- }
307
-
308
- .`).concat(li," .").concat(li,` {
309
- right: 0 `).concat(s,`;
310
- }
311
-
312
- .`).concat(oi," .").concat(oi,` {
313
- margin-right: 0 `).concat(s,`;
314
- }
315
-
316
- body[`).concat(qn,`] {
317
- `).concat(aw,": ").concat(o,`px;
318
- }
319
- `)},Bu=function(){var e=parseInt(document.body.getAttribute(qn)||"0",10);return isFinite(e)?e:0},kw=function(){h.useEffect(function(){return document.body.setAttribute(qn,(Bu()+1).toString()),function(){var e=Bu()-1;e<=0?document.body.removeAttribute(qn):document.body.setAttribute(qn,e.toString())}},[])},Sw=function(e){var t=e.noRelative,r=e.noImportant,s=e.gapMode,a=s===void 0?"margin":s;kw();var i=h.useMemo(function(){return bw(a)},[a]);return h.createElement(jw,{styles:Nw(i,!t,a,r?"":"!important")})},Qo=!1;if(typeof window<"u")try{var Wa=Object.defineProperty({},"passive",{get:function(){return Qo=!0,!0}});window.addEventListener("test",Wa,Wa),window.removeEventListener("test",Wa,Wa)}catch{Qo=!1}var Cn=Qo?{passive:!1}:!1,Cw=function(e){return e.tagName==="TEXTAREA"},Bm=function(e,t){if(!(e instanceof Element))return!1;var r=window.getComputedStyle(e);return r[t]!=="hidden"&&!(r.overflowY===r.overflowX&&!Cw(e)&&r[t]==="visible")},Ew=function(e){return Bm(e,"overflowY")},Tw=function(e){return Bm(e,"overflowX")},Vu=function(e,t){var r=t.ownerDocument,s=t;do{typeof ShadowRoot<"u"&&s instanceof ShadowRoot&&(s=s.host);var a=Vm(e,s);if(a){var i=Wm(e,s),l=i[1],o=i[2];if(l>o)return!0}s=s.parentNode}while(s&&s!==r.body);return!1},Pw=function(e){var t=e.scrollTop,r=e.scrollHeight,s=e.clientHeight;return[t,r,s]},zw=function(e){var t=e.scrollLeft,r=e.scrollWidth,s=e.clientWidth;return[t,r,s]},Vm=function(e,t){return e==="v"?Ew(t):Tw(t)},Wm=function(e,t){return e==="v"?Pw(t):zw(t)},Dw=function(e,t){return e==="h"&&t==="rtl"?-1:1},Mw=function(e,t,r,s,a){var i=Dw(e,window.getComputedStyle(t).direction),l=i*s,o=r.target,c=t.contains(o),d=!1,f=l>0,u=0,x=0;do{if(!o)break;var y=Wm(e,o),w=y[0],v=y[1],b=y[2],m=v-b-i*w;(w||m)&&Vm(e,o)&&(u+=m,x+=w);var p=o.parentNode;o=p&&p.nodeType===Node.DOCUMENT_FRAGMENT_NODE?p.host:p}while(!c&&o!==document.body||c&&(t.contains(o)||t===o));return(f&&Math.abs(u)<1||!f&&Math.abs(x)<1)&&(d=!0),d},Ha=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},Wu=function(e){return[e.deltaX,e.deltaY]},Hu=function(e){return e&&"current"in e?e.current:e},Rw=function(e,t){return e[0]===t[0]&&e[1]===t[1]},Iw=function(e){return`
320
- .block-interactivity-`.concat(e,` {pointer-events: none;}
321
- .allow-interactivity-`).concat(e,` {pointer-events: all;}
322
- `)},Lw=0,En=[];function _w(e){var t=h.useRef([]),r=h.useRef([0,0]),s=h.useRef(),a=h.useState(Lw++)[0],i=h.useState(Um)[0],l=h.useRef(e);h.useEffect(function(){l.current=e},[e]),h.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(a));var v=nw([e.lockRef.current],(e.shards||[]).map(Hu),!0).filter(Boolean);return v.forEach(function(b){return b.classList.add("allow-interactivity-".concat(a))}),function(){document.body.classList.remove("block-interactivity-".concat(a)),v.forEach(function(b){return b.classList.remove("allow-interactivity-".concat(a))})}}},[e.inert,e.lockRef.current,e.shards]);var o=h.useCallback(function(v,b){if("touches"in v&&v.touches.length===2||v.type==="wheel"&&v.ctrlKey)return!l.current.allowPinchZoom;var m=Ha(v),p=r.current,g="deltaX"in v?v.deltaX:p[0]-m[0],j="deltaY"in v?v.deltaY:p[1]-m[1],S,N=v.target,C=Math.abs(g)>Math.abs(j)?"h":"v";if("touches"in v&&C==="h"&&N.type==="range")return!1;var O=Vu(C,N);if(!O)return!0;if(O?S=C:(S=C==="v"?"h":"v",O=Vu(C,N)),!O)return!1;if(!s.current&&"changedTouches"in v&&(g||j)&&(s.current=S),!S)return!0;var G=s.current||S;return Mw(G,b,v,G==="h"?g:j)},[]),c=h.useCallback(function(v){var b=v;if(!(!En.length||En[En.length-1]!==i)){var m="deltaY"in b?Wu(b):Ha(b),p=t.current.filter(function(S){return S.name===b.type&&(S.target===b.target||b.target===S.shadowParent)&&Rw(S.delta,m)})[0];if(p&&p.should){b.cancelable&&b.preventDefault();return}if(!p){var g=(l.current.shards||[]).map(Hu).filter(Boolean).filter(function(S){return S.contains(b.target)}),j=g.length>0?o(b,g[0]):!l.current.noIsolation;j&&b.cancelable&&b.preventDefault()}}},[]),d=h.useCallback(function(v,b,m,p){var g={name:v,delta:b,target:m,should:p,shadowParent:Ow(m)};t.current.push(g),setTimeout(function(){t.current=t.current.filter(function(j){return j!==g})},1)},[]),f=h.useCallback(function(v){r.current=Ha(v),s.current=void 0},[]),u=h.useCallback(function(v){d(v.type,Wu(v),v.target,o(v,e.lockRef.current))},[]),x=h.useCallback(function(v){d(v.type,Ha(v),v.target,o(v,e.lockRef.current))},[]);h.useEffect(function(){return En.push(i),e.setCallbacks({onScrollCapture:u,onWheelCapture:u,onTouchMoveCapture:x}),document.addEventListener("wheel",c,Cn),document.addEventListener("touchmove",c,Cn),document.addEventListener("touchstart",f,Cn),function(){En=En.filter(function(v){return v!==i}),document.removeEventListener("wheel",c,Cn),document.removeEventListener("touchmove",c,Cn),document.removeEventListener("touchstart",f,Cn)}},[]);var y=e.removeScrollBar,w=e.inert;return h.createElement(h.Fragment,null,w?h.createElement(i,{styles:Iw(a)}):null,y?h.createElement(Sw,{noRelative:e.noRelative,gapMode:e.gapMode}):null)}function Ow(e){for(var t=null;e!==null;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}const Aw=hw(Fm,_w);var Hm=h.forwardRef(function(e,t){return h.createElement(rl,qt({},e,{ref:t,sideCar:Aw}))});Hm.classNames=rl.classNames;var $w=function(e){if(typeof document>"u")return null;var t=Array.isArray(e)?e[0]:e;return t.ownerDocument.body},Tn=new WeakMap,Ka=new WeakMap,Qa={},Vl=0,Km=function(e){return e&&(e.host||Km(e.parentNode))},Fw=function(e,t){return t.map(function(r){if(e.contains(r))return r;var s=Km(r);return s&&e.contains(s)?s:(console.error("aria-hidden",r,"in not contained inside",e,". Doing nothing"),null)}).filter(function(r){return!!r})},Uw=function(e,t,r,s){var a=Fw(t,Array.isArray(e)?e:[e]);Qa[r]||(Qa[r]=new WeakMap);var i=Qa[r],l=[],o=new Set,c=new Set(a),d=function(u){!u||o.has(u)||(o.add(u),d(u.parentNode))};a.forEach(d);var f=function(u){!u||c.has(u)||Array.prototype.forEach.call(u.children,function(x){if(o.has(x))f(x);else try{var y=x.getAttribute(s),w=y!==null&&y!=="false",v=(Tn.get(x)||0)+1,b=(i.get(x)||0)+1;Tn.set(x,v),i.set(x,b),l.push(x),v===1&&w&&Ka.set(x,!0),b===1&&x.setAttribute(r,"true"),w||x.setAttribute(s,"true")}catch(m){console.error("aria-hidden: cannot operate on ",x,m)}})};return f(t),o.clear(),Vl++,function(){l.forEach(function(u){var x=Tn.get(u)-1,y=i.get(u)-1;Tn.set(u,x),i.set(u,y),x||(Ka.has(u)||u.removeAttribute(s),Ka.delete(u)),y||u.removeAttribute(r)}),Vl--,Vl||(Tn=new WeakMap,Tn=new WeakMap,Ka=new WeakMap,Qa={})}},Bw=function(e,t,r){r===void 0&&(r="data-aria-hidden");var s=Array.from(Array.isArray(e)?e:[e]),a=$w(e);return a?(s.push.apply(s,Array.from(a.querySelectorAll("[aria-live], script"))),Uw(s,a,r,"aria-hidden")):function(){return null}},nl="Dialog",[Qm,Db]=Ey(nl),[Vw,Ut]=Qm(nl),Ym=e=>{const{__scopeDialog:t,children:r,open:s,defaultOpen:a,onOpenChange:i,modal:l=!0}=e,o=h.useRef(null),c=h.useRef(null),[d,f]=My({prop:s,defaultProp:a??!1,onChange:i,caller:nl});return n.jsx(Vw,{scope:t,triggerRef:o,contentRef:c,contentId:fr(),titleId:fr(),descriptionId:fr(),open:d,onOpenChange:f,onOpenToggle:h.useCallback(()=>f(u=>!u),[f]),modal:l,children:r})};Ym.displayName=nl;var Gm="DialogTrigger",Ww=h.forwardRef((e,t)=>{const{__scopeDialog:r,...s}=e,a=Ut(Gm,r),i=jn(t,a.triggerRef);return n.jsx(Qe.button,{type:"button","aria-haspopup":"dialog","aria-expanded":a.open,"aria-controls":a.contentId,"data-state":Zc(a.open),...s,ref:i,onClick:Vr(e.onClick,a.onOpenToggle)})});Ww.displayName=Gm;var Xc="DialogPortal",[Hw,Xm]=Qm(Xc,{forceMount:void 0}),Jm=e=>{const{__scopeDialog:t,forceMount:r,children:s,container:a}=e,i=Ut(Xc,t);return n.jsx(Hw,{scope:t,forceMount:r,children:h.Children.map(s,l=>n.jsx(tl,{present:r||i.open,children:n.jsx(Om,{asChild:!0,container:a,children:l})}))})};Jm.displayName=Xc;var Li="DialogOverlay",Zm=h.forwardRef((e,t)=>{const r=Xm(Li,e.__scopeDialog),{forceMount:s=r.forceMount,...a}=e,i=Ut(Li,e.__scopeDialog);return i.modal?n.jsx(tl,{present:s||i.open,children:n.jsx(Qw,{...a,ref:t})}):null});Zm.displayName=Li;var Kw=Yc("DialogOverlay.RemoveScroll"),Qw=h.forwardRef((e,t)=>{const{__scopeDialog:r,...s}=e,a=Ut(Li,r);return n.jsx(Hm,{as:Kw,allowPinchZoom:!0,shards:[a.contentRef],children:n.jsx(Qe.div,{"data-state":Zc(a.open),...s,ref:t,style:{pointerEvents:"auto",...s.style}})})}),gn="DialogContent",qm=h.forwardRef((e,t)=>{const r=Xm(gn,e.__scopeDialog),{forceMount:s=r.forceMount,...a}=e,i=Ut(gn,e.__scopeDialog);return n.jsx(tl,{present:s||i.open,children:i.modal?n.jsx(Yw,{...a,ref:t}):n.jsx(Gw,{...a,ref:t})})});qm.displayName=gn;var Yw=h.forwardRef((e,t)=>{const r=Ut(gn,e.__scopeDialog),s=h.useRef(null),a=jn(t,r.contentRef,s);return h.useEffect(()=>{const i=s.current;if(i)return Bw(i)},[]),n.jsx(ep,{...e,ref:a,trapFocus:r.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:Vr(e.onCloseAutoFocus,i=>{var l;i.preventDefault(),(l=r.triggerRef.current)==null||l.focus()}),onPointerDownOutside:Vr(e.onPointerDownOutside,i=>{const l=i.detail.originalEvent,o=l.button===0&&l.ctrlKey===!0;(l.button===2||o)&&i.preventDefault()}),onFocusOutside:Vr(e.onFocusOutside,i=>i.preventDefault())})}),Gw=h.forwardRef((e,t)=>{const r=Ut(gn,e.__scopeDialog),s=h.useRef(!1),a=h.useRef(!1);return n.jsx(ep,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:i=>{var l,o;(l=e.onCloseAutoFocus)==null||l.call(e,i),i.defaultPrevented||(s.current||(o=r.triggerRef.current)==null||o.focus(),i.preventDefault()),s.current=!1,a.current=!1},onInteractOutside:i=>{var c,d;(c=e.onInteractOutside)==null||c.call(e,i),i.defaultPrevented||(s.current=!0,i.detail.originalEvent.type==="pointerdown"&&(a.current=!0));const l=i.target;((d=r.triggerRef.current)==null?void 0:d.contains(l))&&i.preventDefault(),i.detail.originalEvent.type==="focusin"&&a.current&&i.preventDefault()}})}),ep=h.forwardRef((e,t)=>{const{__scopeDialog:r,trapFocus:s,onOpenAutoFocus:a,onCloseAutoFocus:i,...l}=e,o=Ut(gn,r),c=h.useRef(null),d=jn(t,c);return rw(),n.jsxs(n.Fragment,{children:[n.jsx(Lm,{asChild:!0,loop:!0,trapped:s,onMountAutoFocus:a,onUnmountAutoFocus:i,children:n.jsx(Rm,{role:"dialog",id:o.contentId,"aria-describedby":o.descriptionId,"aria-labelledby":o.titleId,"data-state":Zc(o.open),...l,ref:d,onDismiss:()=>o.onOpenChange(!1)})}),n.jsxs(n.Fragment,{children:[n.jsx(qw,{titleId:o.titleId}),n.jsx(tb,{contentRef:c,descriptionId:o.descriptionId})]})]})}),Jc="DialogTitle",Xw=h.forwardRef((e,t)=>{const{__scopeDialog:r,...s}=e,a=Ut(Jc,r);return n.jsx(Qe.h2,{id:a.titleId,...s,ref:t})});Xw.displayName=Jc;var tp="DialogDescription",Jw=h.forwardRef((e,t)=>{const{__scopeDialog:r,...s}=e,a=Ut(tp,r);return n.jsx(Qe.p,{id:a.descriptionId,...s,ref:t})});Jw.displayName=tp;var rp="DialogClose",Zw=h.forwardRef((e,t)=>{const{__scopeDialog:r,...s}=e,a=Ut(rp,r);return n.jsx(Qe.button,{type:"button",...s,ref:t,onClick:Vr(e.onClick,()=>a.onOpenChange(!1))})});Zw.displayName=rp;function Zc(e){return e?"open":"closed"}var np="DialogTitleWarning",[Mb,sp]=Cy(np,{contentName:gn,titleName:Jc,docsSlug:"dialog"}),qw=({titleId:e})=>{const t=sp(np),r=`\`${t.contentName}\` requires a \`${t.titleName}\` for the component to be accessible for screen reader users.
323
-
324
- If you want to hide the \`${t.titleName}\`, you can wrap it with our VisuallyHidden component.
325
-
326
- For more information, see https://radix-ui.com/primitives/docs/components/${t.docsSlug}`;return h.useEffect(()=>{e&&(document.getElementById(e)||console.error(r))},[r,e]),null},eb="DialogDescriptionWarning",tb=({contentRef:e,descriptionId:t})=>{const s=`Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${sp(eb).contentName}}.`;return h.useEffect(()=>{var i;const a=(i=e.current)==null?void 0:i.getAttribute("aria-describedby");t&&a&&(document.getElementById(t)||console.warn(s))},[s,e,t]),null},rb=Ym,nb=Jm,sb=Zm,ab=qm,zs='[cmdk-group=""]',Wl='[cmdk-group-items=""]',ib='[cmdk-group-heading=""]',ap='[cmdk-item=""]',Ku=`${ap}:not([aria-disabled="true"])`,Yo="cmdk-item-select",Pn="data-value",lb=(e,t,r)=>Sy(e,t,r),ip=h.createContext(void 0),ba=()=>h.useContext(ip),lp=h.createContext(void 0),qc=()=>h.useContext(lp),op=h.createContext(void 0),cp=h.forwardRef((e,t)=>{let r=zn(()=>{var E,z;return{search:"",value:(z=(E=e.value)!=null?E:e.defaultValue)!=null?z:"",selectedItemId:void 0,filtered:{count:0,items:new Map,groups:new Set}}}),s=zn(()=>new Set),a=zn(()=>new Map),i=zn(()=>new Map),l=zn(()=>new Set),o=dp(e),{label:c,children:d,value:f,onValueChange:u,filter:x,shouldFilter:y,loop:w,disablePointerSelection:v=!1,vimBindings:b=!0,...m}=e,p=fr(),g=fr(),j=fr(),S=h.useRef(null),N=vb();vn(()=>{if(f!==void 0){let E=f.trim();r.current.value=E,C.emit()}},[f]),vn(()=>{N(6,se)},[]);let C=h.useMemo(()=>({subscribe:E=>(l.current.add(E),()=>l.current.delete(E)),snapshot:()=>r.current,setState:(E,z,M)=>{var L,R,X,Q;if(!Object.is(r.current[E],z)){if(r.current[E]=z,E==="search")B(),V(),N(1,J);else if(E==="value"){if(document.activeElement.hasAttribute("cmdk-input")||document.activeElement.hasAttribute("cmdk-root")){let q=document.getElementById(j);q?q.focus():(L=document.getElementById(p))==null||L.focus()}if(N(7,()=>{var q;r.current.selectedItemId=(q=ee())==null?void 0:q.id,C.emit()}),M||N(5,se),((R=o.current)==null?void 0:R.value)!==void 0){let q=z??"";(Q=(X=o.current).onValueChange)==null||Q.call(X,q);return}}C.emit()}},emit:()=>{l.current.forEach(E=>E())}}),[]),O=h.useMemo(()=>({value:(E,z,M)=>{var L;z!==((L=i.current.get(E))==null?void 0:L.value)&&(i.current.set(E,{value:z,keywords:M}),r.current.filtered.items.set(E,G(z,M)),N(2,()=>{V(),C.emit()}))},item:(E,z)=>(s.current.add(E),z&&(a.current.has(z)?a.current.get(z).add(E):a.current.set(z,new Set([E]))),N(3,()=>{B(),V(),r.current.value||J(),C.emit()}),()=>{i.current.delete(E),s.current.delete(E),r.current.filtered.items.delete(E);let M=ee();N(4,()=>{B(),(M==null?void 0:M.getAttribute("id"))===E&&J(),C.emit()})}),group:E=>(a.current.has(E)||a.current.set(E,new Set),()=>{i.current.delete(E),a.current.delete(E)}),filter:()=>o.current.shouldFilter,label:c||e["aria-label"],getDisablePointerSelection:()=>o.current.disablePointerSelection,listId:p,inputId:j,labelId:g,listInnerRef:S}),[]);function G(E,z){var M,L;let R=(L=(M=o.current)==null?void 0:M.filter)!=null?L:lb;return E?R(E,r.current.search,z):0}function V(){if(!r.current.search||o.current.shouldFilter===!1)return;let E=r.current.filtered.items,z=[];r.current.filtered.groups.forEach(L=>{let R=a.current.get(L),X=0;R.forEach(Q=>{let q=E.get(Q);X=Math.max(q,X)}),z.push([L,X])});let M=S.current;ie().sort((L,R)=>{var X,Q;let q=L.getAttribute("id"),Ne=R.getAttribute("id");return((X=E.get(Ne))!=null?X:0)-((Q=E.get(q))!=null?Q:0)}).forEach(L=>{let R=L.closest(Wl);R?R.appendChild(L.parentElement===R?L:L.closest(`${Wl} > *`)):M.appendChild(L.parentElement===M?L:L.closest(`${Wl} > *`))}),z.sort((L,R)=>R[1]-L[1]).forEach(L=>{var R;let X=(R=S.current)==null?void 0:R.querySelector(`${zs}[${Pn}="${encodeURIComponent(L[0])}"]`);X==null||X.parentElement.appendChild(X)})}function J(){let E=ie().find(M=>M.getAttribute("aria-disabled")!=="true"),z=E==null?void 0:E.getAttribute(Pn);C.setState("value",z||void 0)}function B(){var E,z,M,L;if(!r.current.search||o.current.shouldFilter===!1){r.current.filtered.count=s.current.size;return}r.current.filtered.groups=new Set;let R=0;for(let X of s.current){let Q=(z=(E=i.current.get(X))==null?void 0:E.value)!=null?z:"",q=(L=(M=i.current.get(X))==null?void 0:M.keywords)!=null?L:[],Ne=G(Q,q);r.current.filtered.items.set(X,Ne),Ne>0&&R++}for(let[X,Q]of a.current)for(let q of Q)if(r.current.filtered.items.get(q)>0){r.current.filtered.groups.add(X);break}r.current.filtered.count=R}function se(){var E,z,M;let L=ee();L&&(((E=L.parentElement)==null?void 0:E.firstChild)===L&&((M=(z=L.closest(zs))==null?void 0:z.querySelector(ib))==null||M.scrollIntoView({block:"nearest"})),L.scrollIntoView({block:"nearest"}))}function ee(){var E;return(E=S.current)==null?void 0:E.querySelector(`${ap}[aria-selected="true"]`)}function ie(){var E;return Array.from(((E=S.current)==null?void 0:E.querySelectorAll(Ku))||[])}function D(E){let z=ie()[E];z&&C.setState("value",z.getAttribute(Pn))}function H(E){var z;let M=ee(),L=ie(),R=L.findIndex(Q=>Q===M),X=L[R+E];(z=o.current)!=null&&z.loop&&(X=R+E<0?L[L.length-1]:R+E===L.length?L[0]:L[R+E]),X&&C.setState("value",X.getAttribute(Pn))}function k(E){let z=ee(),M=z==null?void 0:z.closest(zs),L;for(;M&&!L;)M=E>0?xb(M,zs):gb(M,zs),L=M==null?void 0:M.querySelector(Ku);L?C.setState("value",L.getAttribute(Pn)):H(E)}let A=()=>D(ie().length-1),_=E=>{E.preventDefault(),E.metaKey?A():E.altKey?k(1):H(1)},W=E=>{E.preventDefault(),E.metaKey?D(0):E.altKey?k(-1):H(-1)};return h.createElement(Qe.div,{ref:t,tabIndex:-1,...m,"cmdk-root":"",onKeyDown:E=>{var z;(z=m.onKeyDown)==null||z.call(m,E);let M=E.nativeEvent.isComposing||E.keyCode===229;if(!(E.defaultPrevented||M))switch(E.key){case"n":case"j":{b&&E.ctrlKey&&_(E);break}case"ArrowDown":{_(E);break}case"p":case"k":{b&&E.ctrlKey&&W(E);break}case"ArrowUp":{W(E);break}case"Home":{E.preventDefault(),D(0);break}case"End":{E.preventDefault(),A();break}case"Enter":{E.preventDefault();let L=ee();if(L){let R=new Event(Yo);L.dispatchEvent(R)}}}}},h.createElement("label",{"cmdk-label":"",htmlFor:O.inputId,id:O.labelId,style:wb},c),sl(e,E=>h.createElement(lp.Provider,{value:C},h.createElement(ip.Provider,{value:O},E))))}),ob=h.forwardRef((e,t)=>{var r,s;let a=fr(),i=h.useRef(null),l=h.useContext(op),o=ba(),c=dp(e),d=(s=(r=c.current)==null?void 0:r.forceMount)!=null?s:l==null?void 0:l.forceMount;vn(()=>{if(!d)return o.item(a,l==null?void 0:l.id)},[d]);let f=up(a,i,[e.value,e.children,i],e.keywords),u=qc(),x=Kr(N=>N.value&&N.value===f.current),y=Kr(N=>d||o.filter()===!1?!0:N.search?N.filtered.items.get(a)>0:!0);h.useEffect(()=>{let N=i.current;if(!(!N||e.disabled))return N.addEventListener(Yo,w),()=>N.removeEventListener(Yo,w)},[y,e.onSelect,e.disabled]);function w(){var N,C;v(),(C=(N=c.current).onSelect)==null||C.call(N,f.current)}function v(){u.setState("value",f.current,!0)}if(!y)return null;let{disabled:b,value:m,onSelect:p,forceMount:g,keywords:j,...S}=e;return h.createElement(Qe.div,{ref:xn(i,t),...S,id:a,"cmdk-item":"",role:"option","aria-disabled":!!b,"aria-selected":!!x,"data-disabled":!!b,"data-selected":!!x,onPointerMove:b||o.getDisablePointerSelection()?void 0:v,onClick:b?void 0:w},e.children)}),cb=h.forwardRef((e,t)=>{let{heading:r,children:s,forceMount:a,...i}=e,l=fr(),o=h.useRef(null),c=h.useRef(null),d=fr(),f=ba(),u=Kr(y=>a||f.filter()===!1?!0:y.search?y.filtered.groups.has(l):!0);vn(()=>f.group(l),[]),up(l,o,[e.value,e.heading,c]);let x=h.useMemo(()=>({id:l,forceMount:a}),[a]);return h.createElement(Qe.div,{ref:xn(o,t),...i,"cmdk-group":"",role:"presentation",hidden:u?void 0:!0},r&&h.createElement("div",{ref:c,"cmdk-group-heading":"","aria-hidden":!0,id:d},r),sl(e,y=>h.createElement("div",{"cmdk-group-items":"",role:"group","aria-labelledby":r?d:void 0},h.createElement(op.Provider,{value:x},y))))}),db=h.forwardRef((e,t)=>{let{alwaysRender:r,...s}=e,a=h.useRef(null),i=Kr(l=>!l.search);return!r&&!i?null:h.createElement(Qe.div,{ref:xn(a,t),...s,"cmdk-separator":"",role:"separator"})}),ub=h.forwardRef((e,t)=>{let{onValueChange:r,...s}=e,a=e.value!=null,i=qc(),l=Kr(d=>d.search),o=Kr(d=>d.selectedItemId),c=ba();return h.useEffect(()=>{e.value!=null&&i.setState("search",e.value)},[e.value]),h.createElement(Qe.input,{ref:t,...s,"cmdk-input":"",autoComplete:"off",autoCorrect:"off",spellCheck:!1,"aria-autocomplete":"list",role:"combobox","aria-expanded":!0,"aria-controls":c.listId,"aria-labelledby":c.labelId,"aria-activedescendant":o,id:c.inputId,type:"text",value:a?e.value:l,onChange:d=>{a||i.setState("search",d.target.value),r==null||r(d.target.value)}})}),hb=h.forwardRef((e,t)=>{let{children:r,label:s="Suggestions",...a}=e,i=h.useRef(null),l=h.useRef(null),o=Kr(d=>d.selectedItemId),c=ba();return h.useEffect(()=>{if(l.current&&i.current){let d=l.current,f=i.current,u,x=new ResizeObserver(()=>{u=requestAnimationFrame(()=>{let y=d.offsetHeight;f.style.setProperty("--cmdk-list-height",y.toFixed(1)+"px")})});return x.observe(d),()=>{cancelAnimationFrame(u),x.unobserve(d)}}},[]),h.createElement(Qe.div,{ref:xn(i,t),...a,"cmdk-list":"",role:"listbox",tabIndex:-1,"aria-activedescendant":o,"aria-label":s,id:c.listId},sl(e,d=>h.createElement("div",{ref:xn(l,c.listInnerRef),"cmdk-list-sizer":""},d)))}),fb=h.forwardRef((e,t)=>{let{open:r,onOpenChange:s,overlayClassName:a,contentClassName:i,container:l,...o}=e;return h.createElement(rb,{open:r,onOpenChange:s},h.createElement(nb,{container:l},h.createElement(sb,{"cmdk-overlay":"",className:a}),h.createElement(ab,{"aria-label":e.label,"cmdk-dialog":"",className:i},h.createElement(cp,{ref:t,...o}))))}),mb=h.forwardRef((e,t)=>Kr(r=>r.filtered.count===0)?h.createElement(Qe.div,{ref:t,...e,"cmdk-empty":"",role:"presentation"}):null),pb=h.forwardRef((e,t)=>{let{progress:r,children:s,label:a="Loading...",...i}=e;return h.createElement(Qe.div,{ref:t,...i,"cmdk-loading":"",role:"progressbar","aria-valuenow":r,"aria-valuemin":0,"aria-valuemax":100,"aria-label":a},sl(e,l=>h.createElement("div",{"aria-hidden":!0},l)))}),Ds=Object.assign(cp,{List:hb,Item:ob,Input:ub,Group:cb,Separator:db,Dialog:fb,Empty:mb,Loading:pb});function xb(e,t){let r=e.nextElementSibling;for(;r;){if(r.matches(t))return r;r=r.nextElementSibling}}function gb(e,t){let r=e.previousElementSibling;for(;r;){if(r.matches(t))return r;r=r.previousElementSibling}}function dp(e){let t=h.useRef(e);return vn(()=>{t.current=e}),t}var vn=typeof window>"u"?h.useEffect:h.useLayoutEffect;function zn(e){let t=h.useRef();return t.current===void 0&&(t.current=e()),t}function Kr(e){let t=qc(),r=()=>e(t.snapshot());return h.useSyncExternalStore(t.subscribe,r,r)}function up(e,t,r,s=[]){let a=h.useRef(),i=ba();return vn(()=>{var l;let o=(()=>{var d;for(let f of r){if(typeof f=="string")return f.trim();if(typeof f=="object"&&"current"in f)return f.current?(d=f.current.textContent)==null?void 0:d.trim():a.current}})(),c=s.map(d=>d.trim());i.value(e,o,c),(l=t.current)==null||l.setAttribute(Pn,o),a.current=o}),a}var vb=()=>{let[e,t]=h.useState(),r=zn(()=>new Map);return vn(()=>{r.current.forEach(s=>s()),r.current=new Map},[e]),(s,a)=>{r.current.set(s,a),t({})}};function yb(e){let t=e.type;return typeof t=="function"?t(e.props):"render"in t?t.render(e.props):e}function sl({asChild:e,children:t},r){return e&&h.isValidElement(t)?h.cloneElement(yb(t),{ref:t.ref},r(t.props.children)):r(t)}var wb={position:"absolute",width:"1px",height:"1px",padding:"0",margin:"-1px",overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",borderWidth:"0"};function bb({isOpen:e,onClose:t}){const r=qi(),[s,a]=h.useState(""),o=[{id:"users",title:"Users",description:"Manage users and their accounts",icon:xe,action:()=>r("/users"),category:"Navigation",keywords:["user","account","profile"]},{id:"organizations",title:"Organizations",description:"Manage organizations and teams",icon:We,action:()=>r("/organizations"),category:"Navigation",keywords:["org","company","team"]},{id:"sessions",title:"Sessions",description:"View active user sessions",icon:Vo,action:()=>r("/sessions"),category:"Navigation",keywords:["session","login","active"]},{id:"settings",title:"Settings",description:"Configure Better Auth Studio",icon:Jn,action:()=>r("/settings"),category:"Navigation",keywords:["config","setup","preferences"]},{id:"dashboard",title:"Dashboard",description:"View overview and statistics",icon:Vo,action:()=>r("/"),category:"Navigation",keywords:["overview","stats","home"]},{id:"create-user",title:"Create User",description:"Add a new user to the system",icon:Br,action:()=>r("/users"),category:"Actions",keywords:["add","new","register"]},{id:"create-organization",title:"Create Organization",description:"Create a new organization",icon:Vn,action:()=>r("/organizations"),category:"Actions",keywords:["add","new","org"]},{id:"invite-user",title:"Invite User",description:"Send invitation to join organization",icon:_t,action:()=>r("/organizations"),category:"Actions",keywords:["invite","email","send"]}].filter(c=>{var f;const d=s.toLowerCase();return c.title.toLowerCase().includes(d)||c.description.toLowerCase().includes(d)||((f=c.keywords)==null?void 0:f.some(u=>u.toLowerCase().includes(d)))}).reduce((c,d)=>(c[d.category]||(c[d.category]=[]),c[d.category].push(d),c),{});return h.useEffect(()=>{const c=d=>{(d.metaKey||d.ctrlKey)&&d.key==="k"&&d.preventDefault()};return document.addEventListener("keydown",c),()=>document.removeEventListener("keydown",c)},[]),h.useEffect(()=>{const c=d=>{d.key==="Escape"&&t()};if(e)return document.addEventListener("keydown",c),()=>document.removeEventListener("keydown",c)},[e,t]),e?n.jsx("div",{className:"fixed inset-0 bg-black/50 flex items-start justify-center pt-[20vh] z-50",children:n.jsx("div",{className:"bg-black/90 border border-dashed border-white/20 rounded-none w-full max-w-2xl mx-4",children:n.jsxs(Ds,{className:"p-2",children:[n.jsxs("div",{className:"flex items-center border-b border-dashed border-white/10 px-3 pb-3",children:[n.jsx(pn,{className:"w-4 h-4 text-gray-400 mr-3"}),n.jsx(Ds.Input,{value:s,onValueChange:a,placeholder:"Search for actions, pages, or commands...",className:"flex-1 bg-transparent text-white placeholder-gray-400 outline-none",autoFocus:!0}),n.jsx("kbd",{className:"hidden sm:inline-flex items-center px-2 py-1 text-xs text-gray-400 border border-dashed border-white/20 rounded-sm",children:"ESC"})]}),n.jsx(Ds.List,{className:"max-h-96 overflow-y-auto p-2",children:Object.keys(o).length===0?n.jsxs("div",{className:"text-center py-8 text-gray-400",children:[n.jsx(pn,{className:"w-8 h-8 mx-auto mb-2 opacity-50"}),n.jsx("p",{children:"No results found"}),n.jsx("p",{className:"text-sm",children:"Try a different search term"})]}):Object.entries(o).map(([c,d])=>n.jsx("div",{className:"mb-4",children:n.jsx(Ds.Group,{heading:c,className:"text-xs text-gray-400 font-medium mb-2 px-2",children:d.map(f=>{const u=f.icon;return n.jsxs(Ds.Item,{value:f.id,onSelect:()=>{f.action(),t()},className:"flex items-center space-x-3 px-3 py-2 rounded-none hover:bg-white/5 cursor-pointer transition-colors",children:[n.jsx(u,{className:"w-4 h-4 text-white"}),n.jsxs("div",{className:"flex-1",children:[n.jsx("div",{className:"text-white font-light",children:f.title}),n.jsx("div",{className:"text-sm text-gray-400",children:f.description})]}),n.jsx(tn,{className:"w-4 h-4 text-gray-400"})]},f.id)})})},c))}),n.jsx("div",{className:"border-t border-dashed border-white/10 px-3 py-2 text-xs text-gray-400",children:n.jsxs("div",{className:"flex items-center justify-between",children:[n.jsxs("span",{children:["Press ",n.jsx("kbd",{className:"px-1 py-0.5 border border-dashed border-white/20 rounded-sm",children:"↑↓"})," to navigate"]}),n.jsxs("span",{children:["Press ",n.jsx("kbd",{className:"px-1 py-0.5 border border-dashed border-white/20 rounded-sm",children:"Enter"})," to select"]})]})})]})})}):null}const hp=h.createContext(void 0);function jb({children:e}){const[t,r]=h.useState({users:0,organizations:0,sessions:0}),[s,a]=h.useState(!0),i=async()=>{try{const c=await(await fetch("/api/counts")).json();r(c)}catch(o){console.error("Failed to fetch counts:",o)}finally{a(!1)}},l=async()=>{a(!0),await i()};return h.useEffect(()=>{i()},[]),n.jsx(hp.Provider,{value:{counts:t,loading:s,refetchCounts:l},children:e})}function ed(){const e=h.useContext(hp);if(e===void 0)throw new Error("useCounts must be used within a CountsProvider");return e}function Nb({children:e}){const t=wa(),{counts:r,loading:s}=ed(),[a,i]=h.useState(!1);h.useEffect(()=>{const c=d=>{(d.metaKey||d.ctrlKey)&&d.key==="k"&&(d.preventDefault(),i(!0))};return document.addEventListener("keydown",c),()=>document.removeEventListener("keydown",c)},[]);const l=c=>c>=1e3?(c/1e3).toFixed(1).replace(/\.0$/,"")+"k":c.toString(),o=[{name:"Dashboard",href:"/",icon:T0},{name:"Users",href:"/users",icon:xe,badge:s?"...":l(r.users)},{name:"Organizations",href:"/organizations",icon:We,badge:s?"...":l(r.organizations)},{name:"Settings",href:"/settings",icon:Jn}];return n.jsxs("div",{className:"min-h-screen bg-black",children:[n.jsx("div",{className:"bg-black/70 border-b border-white/15",children:n.jsxs("div",{className:"flex items-center justify-between px-6 py-4",children:[n.jsx("div",{className:"flex items-center space-x-4",children:n.jsxs("div",{className:"flex items-center space-x-2",children:[n.jsx("div",{className:"w-8 h-8 bg-white rounded-lg flex items-center justify-center",children:n.jsx("span",{className:"text-black font-bold text-lg",children:"⚡"})}),n.jsxs("div",{children:[n.jsx("h1",{className:"text-xl font-bold text-white",children:"Better Auth Studio"}),n.jsx("p",{className:"text-xs text-gray-300",children:"v1.0.0"})]})]})}),n.jsxs("div",{className:"flex items-center space-x-4",children:[n.jsxs("div",{className:"relative",children:[n.jsx(pn,{className:"absolute left-3 top-1/2 transform -translate-y-1/2 text-gray-400 w-4 h-4"}),n.jsx("input",{type:"text",placeholder:"Search...",onClick:()=>i(!0),className:"pl-10 pr-4 py-2 bg-black border rounded-none border-gray-600 text-white border-dashed focus:ring-2 focus:ring-white focus:border-transparent transition-colors placeholder-gray-400 cursor-pointer",readOnly:!0}),n.jsx("kbd",{className:"absolute right-3 top-1/2 transform -translate-y-1/2 text-xs text-gray-400 border border-dashed border-white/20 rounded-sm px-1.5 py-0.5",children:"⌘K"})]}),n.jsx("a",{href:"https://better-auth.com/docs",target:"_blank",children:n.jsx(T,{variant:"ghost",className:"text-gray-300 bg-transparent hover:bg-transparent hover:bg-gray-900 border-dashed",children:"Docs"})}),n.jsx("a",{href:"https://better-auth.com/support",target:"_blank",children:n.jsx(T,{variant:"ghost",className:"text-gray-300 bg-transparent hover:bg-transparent hover:bg-gray-900 border-dashed",children:"Support"})})]})]})}),n.jsx("div",{className:"bg-black/50 border-b border-white/10",children:n.jsx("div",{className:"px-6",children:n.jsx("nav",{className:"flex space-x-8",children:o.map(c=>{const d=t.pathname===c.href;return n.jsxs(Xn,{to:c.href,className:`flex items-center space-x-2 px-3 py-4 text-sm font-medium border-b-2 transition-all duration-200 ${d?"border-white text-white":"border-transparent text-gray-400 hover:text-white hover:border-gray-300"}`,children:[n.jsx(c.icon,{className:"w-4 h-4"}),n.jsx("span",{children:c.name}),c.badge&&n.jsx(oe,{variant:"secondary",className:"text-xs bg-white/10 border border-white/20 rounded-sm",children:c.badge})]},c.name)})})})}),n.jsx("div",{className:"flex-1 p-0",children:e}),n.jsx(bb,{isOpen:a,onClose:()=>i(!1)})]})}const Ze=h.forwardRef(({className:e,...t},r)=>n.jsx("div",{ref:r,className:Jr("rounded-lg border border-gray-700 bg-gray-900 text-white shadow-sm",e),...t}));Ze.displayName="Card";const Yt=h.forwardRef(({className:e,...t},r)=>n.jsx("div",{ref:r,className:Jr("flex flex-col space-y-1.5 p-6",e),...t}));Yt.displayName="CardHeader";const Gt=h.forwardRef(({className:e,...t},r)=>n.jsx("h3",{ref:r,className:Jr("text-2xl font-semibold leading-none tracking-tight text-white",e),...t}));Gt.displayName="CardTitle";const Xt=h.forwardRef(({className:e,...t},r)=>n.jsx("p",{ref:r,className:Jr("text-sm text-gray-300",e),...t}));Xt.displayName="CardDescription";const qe=h.forwardRef(({className:e,...t},r)=>n.jsx("div",{ref:r,className:Jr("p-6 pt-0",e),...t}));qe.displayName="CardContent";const kb=h.forwardRef(({className:e,...t},r)=>n.jsx("div",{ref:r,className:Jr("flex items-center p-6 pt-0",e),...t}));kb.displayName="CardFooter";const ue=h.forwardRef(({className:e,type:t,...r},s)=>n.jsx("input",{type:t,className:`flex h-10 w-full border border-dashed border-white/20 bg-black/30 px-3 py-2 text-sm text-white placeholder:text-gray-400 focus:outline-none focus:ring-1 focus:ring-white focus:border-white/40 disabled:cursor-not-allowed disabled:opacity-50 rounded-none ${e}`,ref:s,...r}));ue.displayName="Input";const me=h.forwardRef(({className:e,...t},r)=>n.jsx("label",{className:`text-sm font-light text-white ${e}`,ref:r,...t}));me.displayName="Label";const ja=h.createContext({isOpen:!1,setIsOpen:()=>{}}),os=h.forwardRef(({className:e,value:t,onValueChange:r,children:s,...a},i)=>{const[l,o]=h.useState(!1);return n.jsx(ja.Provider,{value:{value:t,onValueChange:r,isOpen:l,setIsOpen:o},children:n.jsx("div",{ref:i,className:`relative ${e}`,...a,children:s})})});os.displayName="Select";const cs=h.forwardRef(({className:e,children:t,...r},s)=>{const{isOpen:a,setIsOpen:i}=h.useContext(ja);return n.jsxs("button",{ref:s,type:"button",className:`flex h-10 w-full items-center justify-between border border-dashed border-white/20 bg-black/30 px-3 py-2 text-sm text-white focus:outline-none focus:ring-1 focus:ring-white focus:border-white/40 disabled:cursor-not-allowed disabled:opacity-50 rounded-none ${e}`,onClick:()=>i(!a),...r,children:[t,n.jsx(jm,{className:`h-4 w-4 text-gray-400 transition-transform ${a?"rotate-180":""}`})]})});cs.displayName="SelectTrigger";const ds=h.forwardRef(({className:e,placeholder:t,...r},s)=>{const{value:a}=h.useContext(ja);return n.jsx("span",{ref:s,className:`text-sm text-white ${e}`,...r,children:a||t})});ds.displayName="SelectValue";const us=h.forwardRef(({className:e,children:t,...r},s)=>{const{isOpen:a}=h.useContext(ja);return a?n.jsx("div",{ref:s,className:`absolute top-full left-0 right-0 z-50 mt-1 border border-dashed border-white/20 bg-black/90 rounded-none shadow-lg ${e}`,...r,children:t}):null});us.displayName="SelectContent";const Et=h.forwardRef(({className:e,children:t,value:r,...s},a)=>{const{onValueChange:i,setIsOpen:l}=h.useContext(ja);return n.jsx("div",{ref:a,className:`px-3 py-2 text-sm text-white hover:bg-white/10 cursor-pointer ${e}`,onClick:()=>{i==null||i(r),l(!1)},...s,children:t})});Et.displayName="SelectItem";function fa({title:e="Seeding Terminal",lines:t,isRunning:r=!1,className:s="",defaultCollapsed:a=!1}){const[i,l]=h.useState(a),o=f=>{switch(f.type){case"success":return n.jsx(Ie,{className:"w-3 h-3 text-green-400"});case"error":return n.jsx(rn,{className:"w-3 h-3 text-red-400"});case"progress":return f.status==="running"?n.jsx(ut,{className:"w-3 h-3 text-blue-400 animate-spin"}):f.status==="completed"?n.jsx(Ie,{className:"w-3 h-3 text-green-400"}):f.status==="failed"?n.jsx(rn,{className:"w-3 h-3 text-red-400"}):n.jsx("div",{className:"w-3 h-3 border border-gray-500 rounded-full"});default:return n.jsx("div",{className:"w-3 h-3 border border-gray-500 rounded-full"})}},c=f=>{switch(f.type){case"success":return"text-green-400";case"error":return"text-red-400";case"progress":return f.status==="running"?"text-blue-400":f.status==="completed"?"text-green-400":f.status==="failed"?"text-red-400":"text-gray-400";default:return"text-gray-300"}},d=f=>f.toLocaleTimeString("en-US",{hour12:!1,hour:"2-digit",minute:"2-digit",second:"2-digit"})+"."+f.getMilliseconds().toString().padStart(3,"0");return n.jsxs("div",{className:`bg-black/90 border border-dashed border-white/20 rounded-none font-mono text-xs ${s}`,children:[n.jsxs("div",{className:"flex items-center justify-between px-3 py-2 border-b border-dashed border-white/10",children:[n.jsxs("div",{className:"flex items-center space-x-2",children:[n.jsx(z0,{className:"w-3 h-3 text-green-400"}),n.jsx("span",{className:"text-green-400 font-medium text-xs",children:e})]}),n.jsxs("div",{className:"flex items-center space-x-2",children:[r&&n.jsxs("div",{className:"flex items-center space-x-1",children:[n.jsx("div",{className:"w-1.5 h-1.5 bg-green-400 rounded-full animate-pulse"}),n.jsx("span",{className:"text-green-400 text-xs",children:"RUNNING"})]}),n.jsxs("div",{className:"text-gray-400 text-xs",children:[t.length," / ",t.length]}),n.jsx("button",{onClick:()=>l(!i),className:"text-gray-400 hover:text-white transition-colors",children:i?n.jsx(jm,{className:"w-3 h-3"}):n.jsx(C0,{className:"w-3 h-3"})})]})]}),!i&&n.jsxs("div",{className:"p-3 space-y-0.5 h-56 overflow-y-auto",children:[t.length===0?n.jsxs("div",{className:"text-gray-500 italic text-xs",children:[n.jsx("span",{className:"text-green-400",children:"$"})," Waiting for operations..."]}):t.map(f=>n.jsxs("div",{className:`flex items-start space-x-3 py-1 ${c(f)} text-xs`,children:[n.jsx("span",{className:"text-gray-500 text-xs w-20 flex-shrink-0",children:d(f.timestamp)}),n.jsx("span",{className:"text-green-400 flex-shrink-0",children:"$"}),n.jsx("div",{className:"flex-shrink-0 mt-0.5",children:o(f)}),n.jsx("span",{className:"flex-1 min-w-0 break-words",children:f.message})]},f.id)),r&&n.jsxs("div",{className:"flex items-start space-x-3 py-1 text-green-400 text-xs",children:[n.jsx("span",{className:"text-gray-500 text-xs w-20 flex-shrink-0",children:d(new Date)}),n.jsx("span",{className:"text-green-400 flex-shrink-0",children:"$"}),n.jsx("div",{className:"w-3 h-3 flex-shrink-0 mt-0.5"}),n.jsx("span",{className:"flex-1 flex items-center",children:n.jsx("span",{className:"animate-pulse",children:"█"})})]})]}),!i&&n.jsx("div",{className:"px-3 py-1.5 border-t border-dashed border-white/10 bg-black/50",children:n.jsxs("div",{className:"flex items-center justify-between text-xs text-gray-400",children:[n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsxs("span",{children:["Status: ",r?"Active":"Idle"]}),n.jsxs("span",{children:["Lines: ",t.length]})]}),n.jsxs("div",{className:"flex items-center space-x-1",children:[n.jsx("div",{className:"w-1.5 h-1.5 bg-green-400 rounded-full"}),n.jsx("span",{children:"Better Auth Studio"})]})]})})]})}const fp=document.createElement("style");fp.textContent=`
327
- @keyframes fadeIn {
328
- from {
329
- opacity: 0;
330
- transform: translateX(-10px);
331
- }
332
- to {
333
- opacity: 1;
334
- transform: translateX(0);
335
- }
336
- }
337
-
338
- .animate-fadeIn {
339
- animation: fadeIn 0.3s ease-out forwards;
340
- }
341
- `;document.head.appendChild(fp);function mp({currentPage:e,totalPages:t,onPageChange:r,totalItems:s,startIndex:a,endIndex:i}){const l=()=>{const d=[],f=[];for(let u=Math.max(2,e-2);u<=Math.min(t-1,e+2);u++)d.push(u);return e-2>2?f.push(1,"..."):f.push(1),f.push(...d),e+2<t-1?f.push("...",t):t>1&&f.push(t),f};if(t<=1)return null;const o=l();return n.jsxs("div",{className:"flex items-center justify-between mt-6",children:[n.jsxs("div",{className:"text-sm text-gray-400",children:["Showing ",a+1," to ",Math.min(i,s)," of ",s," items"]}),n.jsxs("div",{className:"flex items-center space-x-1",children:[n.jsxs(T,{variant:"outline",size:"sm",onClick:()=>r(e-1),disabled:e===1,className:"border border-dashed border-white/20 text-white hover:bg-white/10 rounded-none",children:[n.jsx(k0,{className:"w-4 h-4"}),"Previous"]}),o.map((c,d)=>{if(c==="...")return n.jsx(T,{variant:"outline",size:"sm",disabled:!0,className:"border border-dashed border-white/20 text-white rounded-none",children:n.jsx(P0,{className:"w-4 h-4"})},`dots-${d}`);const f=c,u=e===f;return n.jsx(T,{variant:u?"default":"outline",size:"sm",onClick:()=>r(f),className:u?"bg-white text-black rounded-none":"border border-dashed border-white/20 text-white hover:bg-white/10 rounded-none",children:f},f)}),n.jsxs(T,{variant:"outline",size:"sm",onClick:()=>r(e+1),disabled:e===t,className:"border border-dashed border-white/20 text-white hover:bg-white/10 rounded-none",children:["Next",n.jsx(S0,{className:"w-4 h-4"})]})]})]})}function pp(){const{refetchCounts:e}=ed(),[t,r]=h.useState([]),[s,a]=h.useState(!0),[i,l]=h.useState(""),[o,c]=h.useState("all"),[d,f]=h.useState(1),[u]=h.useState(20),[x,y]=h.useState(!1),[w,v]=h.useState(!1),[b,m]=h.useState(!1),[p,g]=h.useState(!1),[j,S]=h.useState(!1),[N,C]=h.useState(null),[O,G]=h.useState([]),[V,J]=h.useState(!1);h.useEffect(()=>{B()},[]);const B=async()=>{try{const X=await(await fetch("/api/users?limit=10000")).json();r(X.users||[])}catch(R){console.error("Failed to fetch users:",R)}finally{a(!1)}},se=async R=>{G([]),J(!0),G([{id:"start",type:"info",message:`Starting user seeding process for ${R} users...`,timestamp:new Date}]);try{const Q=await(await fetch("/api/seed/users",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({count:R})})).json();if(Q.success){const q=Q.results.map((pe,Pe)=>pe.success?{id:`user-${Pe}`,type:"progress",message:`Creating user: ${pe.user.name} (${pe.user.email})`,timestamp:new Date,status:"completed"}:{id:`user-${Pe}`,type:"error",message:`Failed to create user ${Pe+1}: ${pe.error}`,timestamp:new Date});G(pe=>[...pe,...q]);const Ne=Q.results.filter(pe=>pe.success).length;G(pe=>[...pe,{id:"complete",type:"success",message:`✅ Seeding completed! Created ${Ne}/${R} users successfully`,timestamp:new Date}]),await B(),await e()}else G(q=>[...q,{id:"error",type:"error",message:`❌ Seeding failed: ${Q.error||"Unknown error"}`,timestamp:new Date}])}catch(X){G(Q=>[...Q,{id:"error",type:"error",message:`❌ Network error: ${X}`,timestamp:new Date}])}finally{J(!1)}},ee=R=>{C(R),g(!0)},ie=R=>{C(R),v(!0)},D=R=>{C(R),m(!0)},H=async()=>{var Ne,pe,Pe;const R=(Ne=document.getElementById("create-name"))==null?void 0:Ne.value,X=(pe=document.getElementById("create-email"))==null?void 0:pe.value,Q=(Pe=document.getElementById("create-password"))==null?void 0:Pe.value;if(!R||!X||!Q){I.error("Please fill in all fields");return}const q=I.loading("Creating user...");try{const Bt=await(await fetch("/api/users",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({name:R,email:X,password:Q})})).json();Bt.success?(await B(),y(!1),document.getElementById("create-name").value="",document.getElementById("create-email").value="",document.getElementById("create-password").value="",I.success("User created successfully!",{id:q})):I.error(`Error creating user: ${Bt.error||"Unknown error"}`,{id:q})}catch(yr){console.error("Error creating user:",yr),I.error("Error creating user",{id:q})}},k=async()=>{var q,Ne;if(!N){I.error("No user selected");return}const R=(q=document.getElementById("edit-name"))==null?void 0:q.value,X=(Ne=document.getElementById("edit-email"))==null?void 0:Ne.value;if(!R||!X){I.error("Please fill in all fields");return}const Q=I.loading("Updating user...");try{const Pe=await(await fetch(`/api/users/${N.id}`,{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({name:R,email:X})})).json();Pe.success?(await B(),v(!1),C(null),I.success("User updated successfully!",{id:Q})):I.error(`Error updating user: ${Pe.error||"Unknown error"}`,{id:Q})}catch(pe){console.error("Error updating user:",pe),I.error("Error updating user",{id:Q})}},A=async()=>{if(!N){I.error("No user selected");return}const R=I.loading("Deleting user...");try{const Q=await(await fetch(`/api/users/${N.id}`,{method:"DELETE",headers:{"Content-Type":"application/json"}})).json();Q.success?(await B(),await e(),m(!1),C(null),I.success("User deleted successfully!",{id:R})):I.error(`Error deleting user: ${Q.error||"Unknown error"}`,{id:R})}catch(X){console.error("Error deleting user:",X),I.error("Error deleting user",{id:R})}},_=t.filter(R=>(R.name.toLowerCase().includes(i.toLowerCase())||R.email.toLowerCase().includes(i.toLowerCase()))&&o==="all"),W=Math.ceil(_.length/u),E=(d-1)*u,z=E+u,M=_.slice(E,z),L=R=>{f(R)};return s?n.jsx("div",{className:"flex items-center justify-center h-32",children:n.jsxs("div",{className:"flex flex-col items-center space-y-3",children:[n.jsx(ut,{className:"w-6 h-6 text-white animate-spin"}),n.jsx("div",{className:"text-white text-sm",children:"Loading users..."})]})}):n.jsxs("div",{className:"space-y-6 p-6",children:[n.jsxs("div",{className:"flex items-center justify-between",children:[n.jsxs("div",{children:[n.jsxs("h1",{className:"text-2xl text-white font-light",children:["Users (",t.length,")"]}),n.jsx("p",{className:"text-gray-400 mt-1",children:"Manage your application users"})]}),n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsxs(T,{className:"border border-dashed border-white/20 text-white hover:bg-white/10 bg-transparent rounded-none",onClick:()=>S(!0),children:[n.jsx(ze,{className:"w-4 h-4 mr-2"}),"Seed"]}),n.jsxs(T,{className:"bg-white hover:bg-white/90 text-black border border-white/20 rounded-none",onClick:()=>y(!0),children:[n.jsx(Br,{className:"w-4 h-4 mr-2"}),"Add User"]})]})]}),n.jsxs("div",{className:"flex items-center space-x-4",children:[n.jsxs("div",{className:"flex-1 relative",children:[n.jsx(pn,{className:"absolute left-3 top-1/2 transform -translate-y-1/2 text-gray-400 w-4 h-4"}),n.jsx(ue,{placeholder:"Search users...",value:i,onChange:R=>l(R.target.value),className:"pl-10 border border-dashed border-white/20 bg-black/30 text-white rounded-none"})]}),n.jsxs("div",{className:"flex items-center space-x-2",children:[n.jsx(Qc,{className:"w-4 h-4 text-gray-400"}),n.jsxs(os,{value:o,onValueChange:c,children:[n.jsx(cs,{children:n.jsx(ds,{})}),n.jsxs(us,{children:[n.jsx(Et,{value:"all",children:"All"}),n.jsx(Et,{value:"active",children:"Active"}),n.jsx(Et,{value:"inactive",children:"Inactive"})]})]})]})]}),n.jsxs("div",{className:"bg-black/30 border border-dashed border-white/20 rounded-none",children:[n.jsx("div",{className:"overflow-x-auto",children:n.jsxs("table",{className:"w-full",children:[n.jsx("thead",{children:n.jsxs("tr",{className:"border-b border-dashed border-white/10",children:[n.jsx("th",{className:"text-left py-4 px-4 text-white font-light",children:"User"}),n.jsx("th",{className:"text-left py-4 px-4 text-white font-light",children:"Email"}),n.jsx("th",{className:"text-left py-4 px-4 text-white font-light",children:"Email Verified"}),n.jsx("th",{className:"text-left py-4 px-4 text-white font-light",children:"Created"}),n.jsx("th",{className:"text-right py-4 px-4 text-white font-light",children:"Actions"})]})}),n.jsx("tbody",{children:M.length===0?n.jsx("tr",{children:n.jsx("td",{colSpan:5,className:"py-12 px-4 text-center",children:n.jsxs("div",{className:"flex flex-col items-center space-y-4",children:[n.jsx("div",{className:"w-16 h-16 rounded-none border border-dashed border-white/20 bg-white/10 flex items-center justify-center",children:n.jsx(xe,{className:"w-8 h-8 text-white/50"})}),n.jsxs("div",{children:[n.jsx("h3",{className:"text-white font-medium text-lg",children:"No users found"}),n.jsx("p",{className:"text-gray-400 text-sm mt-1",children:i||o!=="all"?"Try adjusting your search or filter criteria":"Get started by creating your first user or seeding some data"})]}),!i&&o==="all"&&n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsxs(T,{onClick:()=>y(!0),className:"bg-white text-black hover:bg-gray-200 rounded-none",children:[n.jsx(Br,{className:"w-4 h-4 mr-2"}),"Create User"]}),n.jsxs(T,{onClick:()=>S(!0),className:"border border-dashed border-white/20 text-white hover:bg-white/10 bg-transparent rounded-none",children:[n.jsx(ze,{className:"w-4 h-4 mr-2"}),"Seed Data"]})]})]})})}):M.map(R=>n.jsxs("tr",{className:"border-b border-dashed border-white/5 hover:bg-white/5",children:[n.jsx("td",{className:"py-4 px-4",children:n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx("img",{src:R.image||`https://api.dicebear.com/7.x/avataaars/svg?seed=${R.id}`,alt:R.name,className:"w-10 h-10 rounded-none border border-dashed border-white/20"}),n.jsxs("div",{children:[n.jsx("div",{className:"text-white font-light",children:R.name}),n.jsxs("div",{className:"text-sm text-gray-400",children:["ID: ",R.id]})]})]})}),n.jsx("td",{className:"py-4 px-4 text-white",children:R.email}),n.jsx("td",{className:"py-4 px-4",children:n.jsxs("div",{className:"flex items-center space-x-2",children:[R.emailVerified?n.jsx(N0,{className:"w-4 h-4 text-green-400"}):n.jsx(_t,{className:"w-4 h-4 text-yellow-400"}),n.jsx("span",{className:"text-sm text-gray-400",children:R.emailVerified?"Verified":"Not Verified"})]})}),n.jsx("td",{className:"py-4 px-4 text-sm text-gray-400",children:n.jsxs("div",{className:"flex flex-col",children:[new Date(R.createdAt).toLocaleDateString(),n.jsx("p",{className:"text-xs",children:new Date(R.createdAt).toLocaleDateString("en-US",{month:"short",day:"numeric",year:"numeric"})})]})}),n.jsx("td",{className:"py-4 px-4 text-right",children:n.jsxs("div",{className:"flex items-center justify-end space-x-2",children:[n.jsx(T,{variant:"ghost",size:"sm",className:"text-gray-400 hover:text-white rounded-none",onClick:()=>ee(R),children:n.jsx(el,{className:"w-4 h-4"})}),n.jsx(T,{variant:"ghost",size:"sm",className:"text-gray-400 hover:text-white rounded-none",onClick:()=>ie(R),children:n.jsx(ls,{className:"w-4 h-4"})}),n.jsx(T,{variant:"ghost",size:"sm",className:"text-red-400 hover:text-red-300 rounded-none",onClick:()=>D(R),children:n.jsx(cn,{className:"w-4 h-4"})})]})})]},R.id))})]})}),n.jsx(mp,{currentPage:d,totalPages:W,onPageChange:L,totalItems:_.length,startIndex:E,endIndex:z})]}),j&&n.jsx("div",{className:"fixed inset-0 bg-black/50 flex items-center justify-center z-50",children:n.jsxs("div",{className:"bg-black/90 border border-dashed border-white/20 p-6 w-full max-w-2xl rounded-none",children:[n.jsxs("div",{className:"flex items-center justify-between mb-6",children:[n.jsx("h3",{className:"text-lg text-white font-light",children:"Seed Data"}),n.jsx(T,{variant:"ghost",size:"sm",onClick:()=>S(!1),className:"text-gray-400 hover:text-white rounded-none",children:n.jsx(we,{className:"w-4 h-4"})})]}),n.jsxs("div",{className:"space-y-6",children:[n.jsxs("div",{className:"space-y-4",children:[n.jsxs("div",{className:"flex items-center space-x-2",children:[n.jsx(xe,{className:"w-5 h-5 text-white"}),n.jsx("h4",{className:"text-white font-light",children:"Seed Users"})]}),n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsxs("div",{className:"flex-1",children:[n.jsx(me,{htmlFor:"user-count",className:"text-sm text-gray-400 font-light",children:"Number of users"}),n.jsx(ue,{id:"user-count",type:"number",min:"1",max:"100",defaultValue:"5",className:"mt-1 border border-dashed border-white/20 bg-black/30 text-white rounded-none"})]}),n.jsx(T,{onClick:()=>{var X;const R=parseInt(((X=document.getElementById("user-count"))==null?void 0:X.value)||"5");se(R)},disabled:V,className:"bg-transparent hover:bg-white/90 bg-white text-black border border-white/20 rounded-none mt-6 disabled:opacity-50",children:V?n.jsxs(n.Fragment,{children:[n.jsx(ut,{className:"w-3 h-3 mr-2 animate-spin"}),"Seeding..."]}):n.jsxs(n.Fragment,{children:[n.jsx(ze,{className:"w-3 h-3 mr-2"}),"Seed Users"]})})]})]}),O.length>0&&n.jsx("div",{className:"mt-6",children:n.jsx(fa,{title:"User Seeding Terminal",lines:O,isRunning:V,className:"w-full",defaultCollapsed:!0})})]}),n.jsx("div",{className:"flex justify-end mt-6 pt-6 border-t border-dashed border-white/10",children:n.jsx(T,{variant:"outline",onClick:()=>S(!1),className:"border border-dashed border-white/20 text-white hover:bg-white/10 rounded-none",children:"Close"})})]})}),x&&n.jsx("div",{className:"fixed inset-0 bg-black/50 flex items-center justify-center z-50",children:n.jsxs("div",{className:"bg-black/90 border border-dashed border-white/20 p-6 w-full max-w-md rounded-none",children:[n.jsxs("div",{className:"flex items-center justify-between mb-4",children:[n.jsx("h3",{className:"text-lg text-white font-light",children:"Create User"}),n.jsx(T,{variant:"ghost",size:"sm",onClick:()=>y(!1),className:"text-gray-400 hover:text-white rounded-none",children:n.jsx(we,{className:"w-4 h-4"})})]}),n.jsxs("div",{className:"space-y-4",children:[n.jsxs("div",{children:[n.jsx(me,{htmlFor:"create-name",className:"text-sm text-gray-400 font-light",children:"Name"}),n.jsx(ue,{id:"create-name",className:"mt-1 border border-dashed border-white/20 bg-black/30 text-white rounded-none"})]}),n.jsxs("div",{children:[n.jsx(me,{htmlFor:"create-email",className:"text-sm text-gray-400 font-light",children:"Email"}),n.jsx(ue,{id:"create-email",type:"email",className:"mt-1 border border-dashed border-white/20 bg-black/30 text-white rounded-none"})]}),n.jsxs("div",{children:[n.jsx(me,{htmlFor:"create-password",className:"text-sm text-gray-400 font-light",children:"Password"}),n.jsx(ue,{id:"create-password",type:"password",className:"mt-1 border border-dashed border-white/20 bg-black/30 text-white rounded-none"})]})]}),n.jsxs("div",{className:"flex justify-end space-x-3 mt-6",children:[n.jsx(T,{variant:"outline",onClick:()=>y(!1),className:"border border-dashed border-white/20 text-white hover:bg-white/10 rounded-none",children:"Cancel"}),n.jsx(T,{onClick:H,className:"bg-white hover:bg-white/90 text-black border border-white/20 rounded-none",children:"Create"})]})]})}),w&&N&&n.jsx("div",{className:"fixed inset-0 bg-black/50 flex items-center justify-center z-50",children:n.jsxs("div",{className:"bg-black/90 border border-dashed border-white/20 p-6 w-full max-w-md rounded-none",children:[n.jsxs("div",{className:"flex items-center justify-between mb-4",children:[n.jsx("h3",{className:"text-lg text-white font-light",children:"Edit User"}),n.jsx(T,{variant:"ghost",size:"sm",onClick:()=>v(!1),className:"text-gray-400 hover:text-white rounded-none",children:n.jsx(we,{className:"w-4 h-4"})})]}),n.jsxs("div",{className:"space-y-4",children:[n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx("img",{src:N.image||`https://api.dicebear.com/7.x/avataaars/svg?seed=${N.id}`,alt:N.name,className:"w-16 h-16 rounded-none border border-dashed border-white/20"}),n.jsxs("div",{children:[n.jsx("div",{className:"text-white font-light",children:N.name}),n.jsx("div",{className:"text-sm text-gray-400",children:N.email})]})]}),n.jsxs("div",{children:[n.jsx(me,{htmlFor:"edit-name",className:"text-sm text-gray-400 font-light",children:"Name"}),n.jsx(ue,{id:"edit-name",defaultValue:N.name,className:"mt-1 border border-dashed border-white/20 bg-black/30 text-white rounded-none"})]}),n.jsxs("div",{children:[n.jsx(me,{htmlFor:"edit-email",className:"text-sm text-gray-400 font-light",children:"Email"}),n.jsx(ue,{id:"edit-email",type:"email",defaultValue:N.email,className:"mt-1 border border-dashed border-white/20 bg-black/30 text-white rounded-none"})]})]}),n.jsxs("div",{className:"flex justify-end space-x-3 mt-6",children:[n.jsx(T,{variant:"outline",onClick:()=>v(!1),className:"border border-dashed border-white/20 text-white hover:bg-white/10 rounded-none",children:"Cancel"}),n.jsx(T,{onClick:k,className:"bg-white hover:bg-white/90 text-black border border-white/20 rounded-none",children:"Update"})]})]})}),b&&N&&n.jsx("div",{className:"fixed inset-0 bg-black/50 flex items-center justify-center z-50",children:n.jsxs("div",{className:"bg-black/90 border border-dashed border-white/20 p-6 w-full max-w-md rounded-none",children:[n.jsxs("div",{className:"flex items-center justify-between mb-4",children:[n.jsx("h3",{className:"text-lg text-white font-light",children:"Delete User"}),n.jsx(T,{variant:"ghost",size:"sm",onClick:()=>m(!1),className:"text-gray-400 hover:text-white rounded-none",children:n.jsx(we,{className:"w-4 h-4"})})]}),n.jsxs("div",{className:"space-y-4",children:[n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx("img",{src:N.image||`https://api.dicebear.com/7.x/avataaars/svg?seed=${N.id}`,alt:N.name,className:"w-16 h-16 rounded-none border border-dashed border-white/20"}),n.jsxs("div",{children:[n.jsx("div",{className:"text-white font-light",children:N.name}),n.jsx("div",{className:"text-sm text-gray-400",children:N.email})]})]}),n.jsx("p",{className:"text-gray-400",children:"Are you sure you want to delete this user? This action cannot be undone."})]}),n.jsxs("div",{className:"flex justify-end space-x-3 mt-6",children:[n.jsx(T,{variant:"outline",onClick:()=>m(!1),className:"border border-dashed border-white/20 text-white hover:bg-white/10 rounded-none",children:"Cancel"}),n.jsx(T,{onClick:A,className:"bg-red-600 hover:bg-red-700 text-white border border-red-600 rounded-none",children:"Delete"})]})]})}),p&&N&&n.jsx("div",{className:"fixed inset-0 bg-black/50 flex items-center justify-center z-50",children:n.jsxs("div",{className:"bg-black/90 border border-dashed border-white/20 p-6 w-full max-w-md rounded-none",children:[n.jsxs("div",{className:"flex items-center justify-between mb-4",children:[n.jsx("h3",{className:"text-lg text-white font-light",children:"User Details"}),n.jsx(T,{variant:"ghost",size:"sm",onClick:()=>g(!1),className:"text-gray-400 hover:text-white rounded-none",children:n.jsx(we,{className:"w-4 h-4"})})]}),n.jsxs("div",{className:"space-y-4",children:[n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx("img",{src:N.image||`https://api.dicebear.com/7.x/avataaars/svg?seed=${N.id}`,alt:N.name,className:"w-16 h-16 rounded-none border border-dashed border-white/20"}),n.jsxs("div",{children:[n.jsx("div",{className:"text-white font-light",children:N.name}),n.jsx("div",{className:"text-sm text-gray-400",children:N.email})]})]}),n.jsxs("div",{className:"space-y-2",children:[n.jsxs("div",{className:"flex justify-between",children:[n.jsx("span",{className:"text-gray-400",children:"ID:"}),n.jsx("span",{className:"text-white text-sm",children:N.id})]}),n.jsxs("div",{className:"flex justify-between",children:[n.jsx("span",{className:"text-gray-400",children:"Email Verified:"}),n.jsx("span",{className:"text-white text-sm",children:N.emailVerified?"Yes":"No"})]}),n.jsxs("div",{className:"flex justify-between",children:[n.jsx("span",{className:"text-gray-400",children:"Created:"}),n.jsx("span",{className:"text-white text-sm",children:new Date(N.createdAt).toLocaleString()})]}),n.jsxs("div",{className:"flex justify-between",children:[n.jsx("span",{className:"text-gray-400",children:"Updated:"}),n.jsx("span",{className:"text-white text-sm",children:new Date(N.updatedAt).toLocaleString()})]})]})]}),n.jsx("div",{className:"flex justify-end mt-6",children:n.jsx(T,{onClick:()=>g(!1),className:"bg-white hover:bg-white/90 text-black border border-white/20 rounded-none",children:"Close"})})]})})]})}function xp(){const e=qi(),{refetchCounts:t}=ed(),[r,s]=h.useState([]),[a,i]=h.useState(!0),[l,o]=h.useState(null),[c,d]=h.useState(""),[f,u]=h.useState("all"),[x,y]=h.useState(1),[w]=h.useState(20),[v,b]=h.useState(!1),[m,p]=h.useState(!1),[g,j]=h.useState(!1),[S,N]=h.useState(!1),[C,O]=h.useState(!1),[G,V]=h.useState(!1),[J,B]=h.useState(null),[se,ee]=h.useState([]),[ie,D]=h.useState(!1),[H,k]=h.useState({name:"",slug:""}),[A,_]=h.useState({name:"",organizationId:""}),[W,E]=h.useState({name:"",slug:""});h.useEffect(()=>{Q()},[]);const z=F=>F.toLowerCase().replace(/\s+/g,"-").replace(/[^a-z0-9-]/g,"").replace(/-+/g,"-").replace(/^-|-$/g,""),M=F=>{const Z=z(F);k({name:F,slug:Z})},L=F=>{k(Z=>({...Z,slug:z(F)}))},R=F=>{const Z=z(F);E({name:F,slug:Z})},X=F=>{E(Z=>({...Z,slug:z(F)}))},Q=async()=>{try{const Z=await(await fetch("/api/plugins/organization/status")).json();o(Z),Z.enabled?await q():i(!1)}catch(F){console.error("Failed to check plugin status:",F),o({enabled:!1,error:"Failed to check plugin status"}),i(!1)}},q=async()=>{try{const Z=await(await fetch("/api/organizations?limit=10000")).json();s(Z.organizations||[])}catch(F){console.error("Failed to fetch organizations:",F),I.error("Failed to fetch organizations")}finally{i(!1)}},Ne=async F=>{ee([]),D(!0),ee([{id:"start",type:"info",message:`Starting organization seeding process for ${F} organizations...`,timestamp:new Date}]);try{const de=await(await fetch("/api/seed/organizations",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({count:F})})).json();if(de.success){const rt=de.results.map((he,P)=>he.success?{id:`org-${P}`,type:"progress",message:`Creating organization: ${he.organization.name} (${he.organization.slug})`,timestamp:new Date,status:"completed"}:{id:`org-${P}`,type:"error",message:`Failed to create organization ${P+1}: ${he.error}`,timestamp:new Date});ee(he=>[...he,...rt]);const nr=de.results.filter(he=>he.success).length;ee(he=>[...he,{id:"complete",type:"success",message:`✅ Seeding completed! Created ${nr}/${F} organizations successfully`,timestamp:new Date}]),await q(),await t()}else ee(rt=>[...rt,{id:"error",type:"error",message:`❌ Seeding failed: ${de.error||"Unknown error"}`,timestamp:new Date}])}catch(Z){ee(de=>[...de,{id:"error",type:"error",message:`❌ Network error: ${Z}`,timestamp:new Date}])}finally{D(!1)}},pe=async F=>{ee([]),D(!0),ee([{id:"start",type:"info",message:`Starting team seeding process for ${F} teams...`,timestamp:new Date}]);try{const de=await(await fetch("/api/seed/teams",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({count:F})})).json();if(de.success){const rt=de.results.map((he,P)=>he.success?{id:`team-${P}`,type:"progress",message:`Creating team: ${he.team.name}`,timestamp:new Date,status:"completed"}:{id:`team-${P}`,type:"error",message:`Failed to create team ${P+1}: ${he.error}`,timestamp:new Date});ee(he=>[...he,...rt]);const nr=de.results.filter(he=>he.success).length;ee(he=>[...he,{id:"complete",type:"success",message:`✅ Seeding completed! Created ${nr}/${F} teams successfully`,timestamp:new Date}]),await q(),await t()}else ee(rt=>[...rt,{id:"error",type:"error",message:`❌ Seeding failed: ${de.error||"Unknown error"}`,timestamp:new Date}])}catch(Z){ee(de=>[...de,{id:"error",type:"error",message:`❌ Network error: ${Z}`,timestamp:new Date}])}finally{D(!1)}},Pe=F=>{B(F),O(!0)},yr=F=>{B(F),E({name:F.name,slug:F.slug}),j(!0)},Bt=F=>{B(F),N(!0)},Vt=async()=>{if(!H.name){I.error("Please fill in the organization name");return}const F=I.loading("Creating organization...");try{const de=await(await fetch("/api/organizations",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({name:H.name,slug:H.slug})})).json();de.success?(await q(),b(!1),k({name:"",slug:""}),I.success("Organization created successfully!",{id:F})):I.error(`Error creating organization: ${de.error||"Unknown error"}`,{id:F})}catch(Z){console.error("Error creating organization:",Z),I.error("Error creating organization",{id:F})}},Wt=async()=>{if(!A.name){I.error("Please fill in the team name");return}if(!A.organizationId){I.error("Please select an organization");return}const F=I.loading("Creating team...");try{const de=await(await fetch("/api/teams",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({name:A.name,organizationId:A.organizationId})})).json();de.success?(p(!1),_({name:"",organizationId:""}),I.success("Team created successfully!",{id:F})):I.error(`Error creating team: ${de.error||"Unknown error"}`,{id:F})}catch(Z){console.error("Error creating team:",Z),I.error("Error creating team",{id:F})}},jt=async()=>{if(!J){I.error("No organization selected");return}if(!W.name){I.error("Please fill in the organization name");return}const F=I.loading("Updating organization...");try{const de=await(await fetch(`/api/organizations/${J.id}`,{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({name:W.name,slug:W.slug})})).json();de.success?(await q(),j(!1),B(null),E({name:"",slug:""}),I.success("Organization updated successfully!",{id:F})):I.error(`Error updating organization: ${de.error||"Unknown error"}`,{id:F})}catch(Z){console.error("Error updating organization:",Z),I.error("Error updating organization",{id:F})}},Nn=async()=>{if(!J){I.error("No organization selected");return}const F=I.loading("Deleting organization...");try{const de=await(await fetch(`/api/organizations/${J.id}`,{method:"DELETE",headers:{"Content-Type":"application/json"}})).json();de.success?(await q(),await t(),N(!1),B(null),I.success("Organization deleted successfully!",{id:F})):I.error(`Error deleting organization: ${de.error||"Unknown error"}`,{id:F})}catch(Z){console.error("Error deleting organization:",Z),I.error("Error deleting organization",{id:F})}},Ye=r.filter(F=>{var rt;const Z=F.name.toLowerCase().includes(c.toLowerCase())||F.slug.toLowerCase().includes(c.toLowerCase()),de=f==="all"||((rt=F.metadata)==null?void 0:rt.status)===f;return Z&&de}),gs=Math.ceil(Ye.length/w),rr=(x-1)*w,Oe=rr+w,Ht=Ye.slice(rr,Oe),vs=F=>{y(F)};return a?n.jsx("div",{className:"flex items-center justify-center h-32",children:n.jsxs("div",{className:"flex flex-col items-center space-y-3",children:[n.jsx(ut,{className:"w-6 h-6 text-white animate-spin"}),n.jsx("div",{className:"text-white text-sm",children:"Loading organizations..."})]})}):l&&!l.enabled?n.jsxs("div",{className:"space-y-6 p-6",children:[n.jsx("div",{className:"flex items-center justify-between",children:n.jsxs("div",{children:[n.jsx("h1",{className:"text-2xl text-white font-light",children:"Organizations"}),n.jsx("p",{className:"text-gray-400 mt-1",children:"Manage your application organizations"})]})}),n.jsx("div",{className:"bg-black/30 border border-dashed border-white/20 rounded-none p-8",children:n.jsxs("div",{className:"flex items-start space-x-4",children:[n.jsx("div",{className:"flex-shrink-0",children:n.jsx(We,{className:"w-12 h-12 text-white"})}),n.jsxs("div",{className:"flex-1",children:[n.jsx("h3",{className:"text-xl text-white font-light mb-2",children:"Organization Plugin Required"}),n.jsx("p",{className:"text-gray-300 mb-6",children:"To use Organizations in Better Auth Studio, you need to enable the organization plugin in your Better Auth configuration."}),n.jsxs("div",{className:"bg-black/50 border border-dashed border-white/20 rounded-none p-4 mb-6",children:[n.jsx("h4",{className:"text-white font-light mb-3",children:"Follow these steps:"}),n.jsx("ol",{className:"text-gray-300 space-y-2 text-sm list-decimal list-inside",children:n.jsxs("li",{children:["Import the plugin in your auth configuration file",l.configPath&&n.jsxs("span",{className:"text-gray-400",children:[" (",l.configPath,")"]}),":"]})}),n.jsx("div",{className:"mt-4 bg-black/70 border border-dashed border-white/10 rounded-none p-3 overflow-x-auto",children:n.jsxs("pre",{className:"text-sm text-gray-300",children:[n.jsx("span",{className:"text-blue-400",children:"import"})," ","{ betterAuth }"," ",n.jsx("span",{className:"text-blue-400",children:"from"})," ",n.jsx("span",{className:"text-green-400",children:'"better-auth"'})," ",n.jsx("br",{}),n.jsx("span",{className:"text-blue-400",children:"import"})," ","{ organization }"," ",n.jsx("span",{className:"text-blue-400",children:"from"})," ",n.jsx("span",{className:"text-green-400",children:'"better-auth/plugins/organization"'})," ",n.jsx("br",{}),n.jsx("span",{className:"text-blue-400",children:"export const"})," ",n.jsx("span",{className:"text-yellow-300",children:"auth"})," = ",n.jsx("span",{className:"text-yellow-300",children:"betterAuth"}),"(","{"," ",n.jsx("br",{}),n.jsx("span",{className:"text-gray-500 pl-10",children:"// ... your existing configuration"})," ",n.jsx("br",{}),n.jsx("span",{className:"text-red-300 pl-10",children:"plugins"}),": [ ",n.jsx("br",{}),n.jsxs("span",{className:"text-yellow-300 pl-12",children:["organization(",")"]}),n.jsx("br",{}),n.jsx("span",{className:"pl-10",children:"]"})," ",n.jsx("br",{}),"}",") ",n.jsx("br",{})]})}),n.jsx("div",{className:"mt-4",children:n.jsx("p",{className:"text-gray-400 text-sm",children:"2. Do migrations to create the organizations table"})}),n.jsx("div",{className:"mt-2",children:n.jsx("p",{className:"text-gray-400 text-sm",children:"3. Restart your application to apply the changes"})})]}),l.availablePlugins&&l.availablePlugins.length>0&&n.jsx("div",{className:"mb-4",children:n.jsxs("p",{className:"text-gray-400 text-sm",children:["Currently enabled plugins: ",l.availablePlugins.join(", ")]})}),n.jsx(T,{onClick:()=>window.location.reload(),className:"bg-white hover:bg-white/90 text-black border border-white/20 rounded-none",children:"Check Again"}),n.jsxs("div",{className:"mt-4 text-xs text-gray-500",children:["Need help? Check the"," ",n.jsx("a",{href:"https://better-auth.com/docs/plugins/organization",target:"_blank",rel:"noopener noreferrer",className:"text-white hover:underline",children:"Better Auth Organization Plugin Documentation"})]})]})]})})]}):n.jsxs("div",{className:"space-y-6 p-6",children:[n.jsxs("div",{className:"flex items-center justify-between",children:[n.jsxs("div",{children:[n.jsxs("h1",{className:"text-2xl text-white font-light",children:["Organizations (",r.length,")"]}),n.jsx("p",{className:"text-gray-400 mt-1",children:"Manage your organizations and teams"})]}),n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsxs(T,{className:"border border-dashed border-white/20 text-white hover:bg-white/10 bg-transparent rounded-none",onClick:()=>V(!0),children:[n.jsx(ze,{className:"w-4 h-4 mr-2"}),"Seed"]}),n.jsxs(T,{className:"border border-dashed border-white/20 text-white hover:bg-white/10 bg-transparent rounded-none",onClick:()=>p(!0),children:[n.jsx(Vn,{className:"w-4 h-4 mr-2"}),"Create Team"]}),n.jsxs(T,{className:"bg-white hover:bg-white/90 text-black border border-white/20 rounded-none",onClick:()=>b(!0),children:[n.jsx(Vn,{className:"w-4 h-4 mr-2"}),"Add Organization"]})]})]}),n.jsxs("div",{className:"flex items-center space-x-4",children:[n.jsxs("div",{className:"flex-1 relative",children:[n.jsx(pn,{className:"absolute left-3 top-1/2 transform -translate-y-1/2 text-gray-400 w-4 h-4"}),n.jsx(ue,{placeholder:"Search organizations...",value:c,onChange:F=>d(F.target.value),className:"pl-10 border border-dashed border-white/20 bg-black/30 text-white rounded-none"})]}),n.jsxs("div",{className:"flex items-center space-x-2",children:[n.jsx(Qc,{className:"w-4 h-4 text-gray-400"}),n.jsxs(os,{value:f,onValueChange:u,children:[n.jsx(cs,{children:n.jsx(ds,{})}),n.jsxs(us,{children:[n.jsx(Et,{value:"all",children:"All"}),n.jsx(Et,{value:"active",children:"Active"}),n.jsx(Et,{value:"inactive",children:"Inactive"})]})]})]})]}),n.jsxs("div",{className:"bg-black/30 border border-dashed border-white/20 rounded-none",children:[n.jsx("div",{className:"overflow-x-auto",children:n.jsxs("table",{className:"w-full",children:[n.jsx("thead",{children:n.jsxs("tr",{className:"border-b border-dashed border-white/10",children:[n.jsx("th",{className:"text-left py-4 px-4 text-white font-light",children:"Organization"}),n.jsx("th",{className:"text-left py-4 px-4 text-white font-light",children:"Slug"}),n.jsx("th",{className:"text-left py-4 px-4 text-white font-light",children:"Created"}),n.jsx("th",{className:"text-right py-4 px-4 text-white font-light",children:"Actions"})]})}),n.jsx("tbody",{children:Ye.length===0?n.jsx("tr",{children:n.jsx("td",{colSpan:4,className:"py-12 px-4 text-center",children:n.jsxs("div",{className:"flex flex-col items-center space-y-4",children:[n.jsx("div",{className:"w-16 h-16 rounded-none border border-dashed border-white/20 bg-white/10 flex items-center justify-center",children:n.jsx(We,{className:"w-8 h-8 text-white/50"})}),n.jsxs("div",{children:[n.jsx("h3",{className:"text-white font-medium text-lg",children:"No organizations found"}),n.jsx("p",{className:"text-gray-400 text-sm mt-1",children:c||f!=="all"?"Try adjusting your search or filter criteria":"Get started by creating your first organization"})]}),!c&&f==="all"&&n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsxs(T,{onClick:()=>b(!0),className:"bg-white text-black hover:bg-gray-200 rounded-none",children:[n.jsx(Vn,{className:"w-4 h-4 mr-2"}),"Create Organization"]}),n.jsxs(T,{onClick:()=>V(!0),className:"border border-dashed border-white/20 text-white hover:bg-white/10 bg-transparent rounded-none",children:[n.jsx(ze,{className:"w-4 h-4 mr-2"}),"Seed Data"]})]})]})})}):Ht.map(F=>n.jsxs("tr",{className:"border-b border-dashed border-white/5 hover:bg-white/5 cursor-pointer",onClick:()=>e(`/organizations/${F.id}`),children:[n.jsx("td",{className:"py-4 px-4",children:n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx("div",{className:"w-10 h-10 rounded-none border border-dashed border-white/20 bg-white/10 flex items-center justify-center",children:n.jsx(We,{className:"w-5 h-5 text-white"})}),n.jsxs("div",{children:[n.jsx("div",{className:"text-white font-light",children:F.name}),n.jsxs("div",{className:"text-sm text-gray-400",children:["ID: ",F.id]})]})]})}),n.jsx("td",{className:"py-4 px-4 text-white",children:F.slug}),n.jsx("td",{className:"py-4 px-4 text-sm text-gray-400",children:n.jsxs("div",{className:"flex flex-col",children:[new Date(F.createdAt).toLocaleDateString(),n.jsx("p",{className:"text-xs",children:new Date(F.createdAt).toLocaleDateString("en-US",{month:"short",day:"numeric",year:"numeric"})})]})}),n.jsx("td",{className:"py-4 px-4 text-right",children:n.jsxs("div",{className:"flex items-center justify-end space-x-2",children:[n.jsx(T,{variant:"ghost",size:"sm",className:"text-gray-400 hover:text-white rounded-none",onClick:Z=>{Z.stopPropagation(),Pe(F)},children:n.jsx(el,{className:"w-4 h-4"})}),n.jsx(T,{variant:"ghost",size:"sm",className:"text-gray-400 hover:text-white rounded-none",onClick:Z=>{Z.stopPropagation(),yr(F)},children:n.jsx(ls,{className:"w-4 h-4"})}),n.jsx(T,{variant:"ghost",size:"sm",className:"text-red-400 hover:text-red-300 rounded-none",onClick:Z=>{Z.stopPropagation(),Bt(F)},children:n.jsx(cn,{className:"w-4 h-4"})})]})})]},F.id))})]})}),n.jsx(mp,{currentPage:x,totalPages:gs,onPageChange:vs,totalItems:Ye.length,startIndex:rr,endIndex:Oe})]}),G&&n.jsx("div",{className:"fixed inset-0 bg-black/50 flex items-center justify-center z-50",children:n.jsxs("div",{className:"bg-black/90 border border-dashed border-white/20 p-6 w-full max-w-2xl rounded-none",children:[n.jsxs("div",{className:"flex items-center justify-between mb-6",children:[n.jsx("h3",{className:"text-lg text-white font-light",children:"Seed Data"}),n.jsx(T,{variant:"ghost",size:"sm",onClick:()=>V(!1),className:"text-gray-400 hover:text-white rounded-none",children:n.jsx(we,{className:"w-4 h-4"})})]}),n.jsxs("div",{className:"space-y-6",children:[n.jsxs("div",{className:"space-y-4",children:[n.jsxs("div",{className:"flex items-center space-x-2",children:[n.jsx(We,{className:"w-5 h-5 text-white"}),n.jsx("h4",{className:"text-white font-light",children:"Seed Organizations"})]}),n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsxs("div",{className:"flex-1",children:[n.jsx(me,{htmlFor:"organization-count",className:"text-sm text-gray-400 font-light",children:"Number of organizations"}),n.jsx(ue,{id:"organization-count",type:"number",min:"1",max:"100",defaultValue:"5",className:"mt-1 border border-dashed border-white/20 bg-black/30 text-white rounded-none"})]}),n.jsx(T,{onClick:()=>{var Z;const F=parseInt(((Z=document.getElementById("organization-count"))==null?void 0:Z.value)||"5");Ne(F)},disabled:ie,className:"bg-white hover:bg-white/90 text-black border border-white/20 rounded-none mt-6 disabled:opacity-50",children:ie?n.jsxs(n.Fragment,{children:[n.jsx(ut,{className:"w-3 h-3 mr-2 animate-spin"}),"Seeding..."]}):n.jsxs(n.Fragment,{children:[n.jsx(ze,{className:"w-3 h-3 mr-2"}),"Seed Organizations"]})})]})]}),n.jsxs("div",{className:"space-y-4",children:[n.jsxs("div",{className:"flex items-center space-x-2",children:[n.jsx(Vn,{className:"w-5 h-5 text-white"}),n.jsx("h4",{className:"text-white font-light",children:"Seed Teams"})]}),n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsxs("div",{className:"flex-1",children:[n.jsx(me,{htmlFor:"team-count",className:"text-sm text-gray-400 font-light",children:"Number of teams"}),n.jsx(ue,{id:"team-count",type:"number",min:"1",max:"100",defaultValue:"5",className:"mt-1 border border-dashed border-white/20 bg-black/30 text-white rounded-none"})]}),n.jsx(T,{onClick:()=>{var Z;const F=parseInt(((Z=document.getElementById("team-count"))==null?void 0:Z.value)||"5");pe(F)},disabled:ie,className:"bg-white hover:bg-white/90 text-black border border-white/20 rounded-none mt-6 disabled:opacity-50",children:ie?n.jsxs(n.Fragment,{children:[n.jsx(ut,{className:"w-3 h-3 mr-2 animate-spin"}),"Seeding..."]}):n.jsxs(n.Fragment,{children:[n.jsx(ze,{className:"w-3 h-3 mr-2"}),"Seed Teams"]})})]})]}),se.length>0&&n.jsx("div",{className:"mt-6",children:n.jsx(fa,{title:"Organization Seeding Terminal",lines:se,isRunning:ie,className:"w-full",defaultCollapsed:!0})})]}),n.jsx("div",{className:"flex justify-end mt-6 pt-6 border-t border-dashed border-white/10",children:n.jsx(T,{variant:"outline",onClick:()=>V(!1),className:"border border-dashed border-white/20 text-white hover:bg-white/10 rounded-none",children:"Close"})})]})}),m&&n.jsx("div",{className:"fixed inset-0 bg-black/50 flex items-center justify-center z-50",children:n.jsxs("div",{className:"bg-black/90 border border-dashed border-white/20 p-6 w-full max-w-md rounded-none",children:[n.jsxs("div",{className:"flex items-center justify-between mb-4",children:[n.jsx("h3",{className:"text-lg text-white font-light",children:"Create Team"}),n.jsx(T,{variant:"ghost",size:"sm",onClick:()=>p(!1),className:"text-gray-400 hover:text-white rounded-none",children:n.jsx(we,{className:"w-4 h-4"})})]}),n.jsxs("div",{className:"space-y-4",children:[n.jsxs("div",{children:[n.jsx(me,{htmlFor:"team-name",className:"text-sm text-gray-400 font-light",children:"Team Name"}),n.jsx(ue,{id:"team-name",value:A.name,onChange:F=>_(Z=>({...Z,name:F.target.value})),placeholder:"Enter team name",className:"mt-1 border border-dashed border-white/20 bg-black/30 text-white rounded-none"})]}),n.jsxs("div",{children:[n.jsx(me,{htmlFor:"team-organization",className:"text-sm text-gray-400 font-light",children:"Organization"}),n.jsxs(os,{value:A.organizationId,onValueChange:F=>_(Z=>({...Z,organizationId:F})),children:[n.jsx(cs,{className:"mt-1 border border-dashed border-white/20 bg-black/30 text-white rounded-none",children:n.jsx(ds,{placeholder:"Select organization"})}),n.jsx(us,{children:r.map(F=>n.jsx(Et,{value:F.id,children:F.name},F.id))})]})]})]}),n.jsxs("div",{className:"flex justify-end space-x-3 mt-6",children:[n.jsx(T,{variant:"outline",onClick:()=>{p(!1),_({name:"",organizationId:""})},className:"border border-dashed border-white/20 text-white hover:bg-white/10 rounded-none",children:"Cancel"}),n.jsx(T,{onClick:Wt,className:"bg-white hover:bg-white/90 text-black border border-white/20 rounded-none",children:"Create"})]})]})}),v&&n.jsx("div",{className:"fixed inset-0 bg-black/50 flex items-center justify-center z-50",children:n.jsxs("div",{className:"bg-black/90 border border-dashed border-white/20 p-6 w-full max-w-md rounded-none",children:[n.jsxs("div",{className:"flex items-center justify-between mb-4",children:[n.jsx("h3",{className:"text-lg text-white font-light",children:"Create Organization"}),n.jsx(T,{variant:"ghost",size:"sm",onClick:()=>b(!1),className:"text-gray-400 hover:text-white rounded-none",children:n.jsx(we,{className:"w-4 h-4"})})]}),n.jsxs("div",{className:"space-y-4",children:[n.jsxs("div",{children:[n.jsx(me,{htmlFor:"create-name",className:"text-sm text-gray-400 font-light",children:"Name"}),n.jsx(ue,{id:"create-name",value:H.name,onChange:F=>M(F.target.value),placeholder:"e.g. Acme Corp",className:"mt-1 border border-dashed border-white/20 bg-black/30 text-white rounded-none"})]}),n.jsxs("div",{children:[n.jsx(me,{htmlFor:"create-slug",className:"text-sm text-gray-400 font-light",children:"Slug"}),n.jsx(ue,{id:"create-slug",value:H.slug,onChange:F=>L(F.target.value),placeholder:"e.g. acme-corp",className:"mt-1 border border-dashed border-white/20 bg-black/30 text-white rounded-none"}),n.jsx("p",{className:"text-xs text-gray-500 mt-1",children:"Auto-generated from name. You can edit it manually."})]})]}),n.jsxs("div",{className:"flex justify-end space-x-3 mt-6",children:[n.jsx(T,{variant:"outline",onClick:()=>{b(!1),k({name:"",slug:""})},className:"border border-dashed border-white/20 text-white hover:bg-white/10 rounded-none",children:"Cancel"}),n.jsx(T,{onClick:Vt,className:"bg-white hover:bg-white/90 text-black border border-white/20 rounded-none",children:"Create"})]})]})}),g&&J&&n.jsx("div",{className:"fixed inset-0 bg-black/50 flex items-center justify-center z-50",children:n.jsxs("div",{className:"bg-black/90 border border-dashed border-white/20 p-6 w-full max-w-md rounded-none",children:[n.jsxs("div",{className:"flex items-center justify-between mb-4",children:[n.jsx("h3",{className:"text-lg text-white font-light",children:"Edit Organization"}),n.jsx(T,{variant:"ghost",size:"sm",onClick:()=>j(!1),className:"text-gray-400 hover:text-white rounded-none",children:n.jsx(we,{className:"w-4 h-4"})})]}),n.jsxs("div",{className:"space-y-4",children:[n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx("div",{className:"w-16 h-16 rounded-none border border-dashed border-white/20 bg-white/10 flex items-center justify-center",children:n.jsx(We,{className:"w-8 h-8 text-white"})}),n.jsxs("div",{children:[n.jsx("div",{className:"text-white font-light",children:J.name}),n.jsx("div",{className:"text-sm text-gray-400",children:J.slug})]})]}),n.jsxs("div",{children:[n.jsx(me,{htmlFor:"edit-name",className:"text-sm text-gray-400 font-light",children:"Name"}),n.jsx(ue,{id:"edit-name",value:W.name,onChange:F=>R(F.target.value),placeholder:"e.g. Acme Corp",className:"mt-1 border border-dashed border-white/20 bg-black/30 text-white rounded-none"})]}),n.jsxs("div",{children:[n.jsx(me,{htmlFor:"edit-slug",className:"text-sm text-gray-400 font-light",children:"Slug"}),n.jsx(ue,{id:"edit-slug",value:W.slug,onChange:F=>X(F.target.value),placeholder:"e.g. acme-corp",className:"mt-1 border border-dashed border-white/20 bg-black/30 text-white rounded-none"}),n.jsx("p",{className:"text-xs text-gray-500 mt-1",children:"Auto-generated from name. You can edit it manually."})]})]}),n.jsxs("div",{className:"flex justify-end space-x-3 mt-6",children:[n.jsx(T,{variant:"outline",onClick:()=>{j(!1),E({name:"",slug:""})},className:"border border-dashed border-white/20 text-white hover:bg-white/10 rounded-none",children:"Cancel"}),n.jsx(T,{onClick:jt,className:"bg-white hover:bg-white/90 text-black border border-white/20 rounded-none",children:"Update"})]})]})}),S&&J&&n.jsx("div",{className:"fixed inset-0 bg-black/50 flex items-center justify-center z-50",children:n.jsxs("div",{className:"bg-black/90 border border-dashed border-white/20 p-6 w-full max-w-md rounded-none",children:[n.jsxs("div",{className:"flex items-center justify-between mb-4",children:[n.jsx("h3",{className:"text-lg text-white font-light",children:"Delete Organization"}),n.jsx(T,{variant:"ghost",size:"sm",onClick:()=>N(!1),className:"text-gray-400 hover:text-white rounded-none",children:n.jsx(we,{className:"w-4 h-4"})})]}),n.jsxs("div",{className:"space-y-4",children:[n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx("div",{className:"w-16 h-16 rounded-none border border-dashed border-white/20 bg-white/10 flex items-center justify-center",children:n.jsx(We,{className:"w-8 h-8 text-white"})}),n.jsxs("div",{children:[n.jsx("div",{className:"text-white font-light",children:J.name}),n.jsx("div",{className:"text-sm text-gray-400",children:J.slug})]})]}),n.jsx("p",{className:"text-gray-400",children:"Are you sure you want to delete this organization? This action cannot be undone."})]}),n.jsxs("div",{className:"flex justify-end space-x-3 mt-6",children:[n.jsx(T,{variant:"outline",onClick:()=>N(!1),className:"border border-dashed border-white/20 text-white hover:bg-white/10 rounded-none",children:"Cancel"}),n.jsx(T,{onClick:Nn,className:"bg-red-600 hover:bg-red-700 text-white border border-red-600 rounded-none",children:"Delete"})]})]})}),C&&J&&n.jsx("div",{className:"fixed inset-0 bg-black/50 flex items-center justify-center z-50",children:n.jsxs("div",{className:"bg-black/90 border border-dashed border-white/20 p-6 w-full max-w-md rounded-none",children:[n.jsxs("div",{className:"flex items-center justify-between mb-4",children:[n.jsx("h3",{className:"text-lg text-white font-light",children:"Organization Details"}),n.jsx(T,{variant:"ghost",size:"sm",onClick:()=>O(!1),className:"text-gray-400 hover:text-white rounded-none",children:n.jsx(we,{className:"w-4 h-4"})})]}),n.jsxs("div",{className:"space-y-4",children:[n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx("div",{className:"w-16 h-16 rounded-none border border-dashed border-white/20 bg-white/10 flex items-center justify-center",children:n.jsx(We,{className:"w-8 h-8 text-white"})}),n.jsxs("div",{children:[n.jsx("div",{className:"text-white font-light",children:J.name}),n.jsx("div",{className:"text-sm text-gray-400",children:J.slug})]})]}),n.jsxs("div",{className:"space-y-2",children:[n.jsxs("div",{className:"flex justify-between",children:[n.jsx("span",{className:"text-gray-400",children:"ID:"}),n.jsx("span",{className:"text-white text-sm",children:J.id})]}),n.jsxs("div",{className:"flex justify-between",children:[n.jsx("span",{className:"text-gray-400",children:"Created:"}),n.jsx("span",{className:"text-white text-sm",children:new Date(J.createdAt).toLocaleString()})]}),n.jsxs("div",{className:"flex justify-between",children:[n.jsx("span",{className:"text-gray-400",children:"Updated:"}),n.jsx("span",{className:"text-white text-sm",children:new Date(J.updatedAt).toLocaleString()})]})]})]}),n.jsx("div",{className:"flex justify-end mt-6",children:n.jsx(T,{onClick:()=>O(!1),className:"bg-white hover:bg-white/90 text-black border border-white/20 rounded-none",children:"Close"})})]})})]})}function gp(){const[e,t]=h.useState([]),[r,s]=h.useState(!0),[a,i]=h.useState(""),[l,o]=h.useState("all"),[c,d]=h.useState(!1),[f,u]=h.useState(!1),[x,y]=h.useState(!1),[w,v]=h.useState(!1),[b,m]=h.useState(!1),[p,g]=h.useState(null),[j,S]=h.useState([]),[N,C]=h.useState(!1);h.useEffect(()=>{O()},[]);const O=async()=>{try{const A=await(await fetch("/api/sessions")).json();t(A.sessions||[])}catch(k){console.error("Failed to fetch sessions:",k)}finally{s(!1)}},G=async k=>{S([]),C(!0),S([{id:"start",type:"info",message:`Starting session seeding process for ${k} sessions...`,timestamp:new Date}]);try{const _=await(await fetch("/api/seed/sessions",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({count:k})})).json();if(_.success){const W=_.results.map((z,M)=>z.success?{id:`session-${M}`,type:"progress",message:`Creating session: ${z.session.id}`,timestamp:new Date,status:"completed"}:{id:`session-${M}`,type:"error",message:`Failed to create session ${M+1}: ${z.error}`,timestamp:new Date});S(z=>[...z,...W]);const E=_.results.filter(z=>z.success).length;S(z=>[...z,{id:"complete",type:"success",message:`✅ Seeding completed! Created ${E}/${k} sessions successfully`,timestamp:new Date}]),await O()}else S(W=>[...W,{id:"error",type:"error",message:`❌ Seeding failed: ${_.error||"Unknown error"}`,timestamp:new Date}])}catch(A){S(_=>[..._,{id:"error",type:"error",message:`❌ Network error: ${A}`,timestamp:new Date}])}finally{C(!1)}},V=async k=>{S([]),C(!0),S([{id:"start",type:"info",message:`Starting account seeding process for ${k} accounts...`,timestamp:new Date}]);try{const _=await(await fetch("/api/seed/accounts",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({count:k})})).json();if(_.success){const W=_.results.map((z,M)=>z.success?{id:`account-${M}`,type:"progress",message:`Creating account: ${z.account.provider}`,timestamp:new Date,status:"completed"}:{id:`account-${M}`,type:"error",message:`Failed to create account ${M+1}: ${z.error}`,timestamp:new Date});S(z=>[...z,...W]);const E=_.results.filter(z=>z.success).length;S(z=>[...z,{id:"complete",type:"success",message:`✅ Seeding completed! Created ${E}/${k} accounts successfully`,timestamp:new Date}]),await O()}else S(W=>[...W,{id:"error",type:"error",message:`❌ Seeding failed: ${_.error||"Unknown error"}`,timestamp:new Date}])}catch(A){S(_=>[..._,{id:"error",type:"error",message:`❌ Network error: ${A}`,timestamp:new Date}])}finally{C(!1)}},J=k=>{g(k),v(!0)},B=k=>{g(k),u(!0)},se=k=>{g(k),y(!0)},ee=async k=>{console.log("Creating session:",k),d(!1)},ie=async k=>{console.log("Updating session:",k),u(!1)},D=async()=>{console.log("Deleting session:",p==null?void 0:p.id),y(!1)},H=e.filter(k=>{const A=k.id.toLowerCase().includes(a.toLowerCase())||k.userId.toLowerCase().includes(a.toLowerCase()),_=l==="all"||l==="active"&&new Date(k.expiresAt)>new Date||l==="expired"&&new Date(k.expiresAt)<=new Date;return A&&_});return r?n.jsx("div",{className:"flex items-center justify-center h-32",children:n.jsxs("div",{className:"flex flex-col items-center space-y-3",children:[n.jsx(ut,{className:"w-6 h-6 text-white animate-spin"}),n.jsx("div",{className:"text-white text-sm",children:"Loading sessions..."})]})}):n.jsxs("div",{className:"space-y-6",children:[n.jsxs("div",{className:"flex items-center justify-between",children:[n.jsxs("div",{children:[n.jsxs("h1",{className:"text-2xl text-white font-light",children:["Sessions (",e.length,")"]}),n.jsx("p",{className:"text-gray-400 mt-1",children:"Manage user sessions and accounts"})]}),n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsxs(T,{className:"border border-dashed border-white/20 text-white hover:bg-white/10 rounded-none",onClick:()=>m(!0),children:[n.jsx(ze,{className:"w-4 h-4 mr-2"}),"Seed"]}),n.jsxs(T,{className:"bg-white hover:bg-white/90 text-black border border-white/20 rounded-none",onClick:()=>d(!0),children:[n.jsx(Vn,{className:"w-4 h-4 mr-2"}),"Add Session"]})]})]}),n.jsxs("div",{className:"flex items-center space-x-4",children:[n.jsxs("div",{className:"flex-1 relative",children:[n.jsx(pn,{className:"absolute left-3 top-1/2 transform -translate-y-1/2 text-gray-400 w-4 h-4"}),n.jsx(ue,{placeholder:"Search sessions...",value:a,onChange:k=>i(k.target.value),className:"pl-10 border border-dashed border-white/20 bg-black/30 text-white rounded-none"})]}),n.jsxs("div",{className:"flex items-center space-x-2",children:[n.jsx(Qc,{className:"w-4 h-4 text-gray-400"}),n.jsxs(os,{value:l,onValueChange:o,children:[n.jsx(cs,{children:n.jsx(ds,{})}),n.jsxs(us,{children:[n.jsx(Et,{value:"all",children:"All"}),n.jsx(Et,{value:"active",children:"Active"}),n.jsx(Et,{value:"expired",children:"Expired"})]})]})]})]}),n.jsx("div",{className:"bg-black/30 border border-dashed border-white/20 rounded-none",children:n.jsx("div",{className:"overflow-x-auto",children:n.jsxs("table",{className:"w-full",children:[n.jsx("thead",{children:n.jsxs("tr",{className:"border-b border-dashed border-white/10",children:[n.jsx("th",{className:"text-left py-4 px-4 text-white font-light",children:"Session"}),n.jsx("th",{className:"text-left py-4 px-4 text-white font-light",children:"User ID"}),n.jsx("th",{className:"text-left py-4 px-4 text-white font-light",children:"Status"}),n.jsx("th",{className:"text-left py-4 px-4 text-white font-light",children:"Expires"}),n.jsx("th",{className:"text-right py-4 px-4 text-white font-light",children:"Actions"})]})}),n.jsx("tbody",{children:H.map(k=>n.jsxs("tr",{className:"border-b border-dashed border-white/5 hover:bg-white/5",children:[n.jsx("td",{className:"py-4 px-4",children:n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx("div",{className:"w-10 h-10 rounded-none border border-dashed border-white/20 bg-white/10 flex items-center justify-center",children:n.jsx(ze,{className:"w-5 h-5 text-white"})}),n.jsxs("div",{children:[n.jsxs("div",{className:"text-white font-light",children:["Session ",k.id.slice(0,8),"..."]}),n.jsxs("div",{className:"text-sm text-gray-400",children:["ID: ",k.id]})]})]})}),n.jsx("td",{className:"py-4 px-4 text-white",children:k.userId}),n.jsx("td",{className:"py-4 px-4",children:n.jsxs("div",{className:"flex items-center space-x-2",children:[new Date(k.expiresAt)>new Date?n.jsx("div",{className:"w-2 h-2 bg-green-400 rounded-full"}):n.jsx("div",{className:"w-2 h-2 bg-red-400 rounded-full"}),n.jsx("span",{className:"text-sm text-gray-400",children:new Date(k.expiresAt)>new Date?"Active":"Expired"})]})}),n.jsx("td",{className:"py-4 px-4 text-sm text-gray-400",children:new Date(k.expiresAt).toLocaleDateString()}),n.jsx("td",{className:"py-4 px-4 text-right",children:n.jsxs("div",{className:"flex items-center justify-end space-x-2",children:[n.jsx(T,{variant:"ghost",size:"sm",className:"text-gray-400 hover:text-white rounded-none",onClick:()=>J(k),children:n.jsx(el,{className:"w-4 h-4"})}),n.jsx(T,{variant:"ghost",size:"sm",className:"text-gray-400 hover:text-white rounded-none",onClick:()=>B(k),children:n.jsx(ls,{className:"w-4 h-4"})}),n.jsx(T,{variant:"ghost",size:"sm",className:"text-red-400 hover:text-red-300 rounded-none",onClick:()=>se(k),children:n.jsx(cn,{className:"w-4 h-4"})})]})})]},k.id))})]})})}),b&&n.jsx("div",{className:"fixed inset-0 bg-black/50 flex items-center justify-center z-50",children:n.jsxs("div",{className:"bg-black/90 border border-dashed border-white/20 p-6 w-full max-w-2xl rounded-none",children:[n.jsxs("div",{className:"flex items-center justify-between mb-6",children:[n.jsx("h3",{className:"text-lg text-white font-light",children:"Seed Data"}),n.jsx(T,{variant:"ghost",size:"sm",onClick:()=>m(!1),className:"text-gray-400 hover:text-white rounded-none",children:n.jsx(we,{className:"w-4 h-4"})})]}),n.jsxs("div",{className:"space-y-6",children:[n.jsxs("div",{className:"space-y-4",children:[n.jsxs("div",{className:"flex items-center space-x-2",children:[n.jsx(ze,{className:"w-5 h-5 text-white"}),n.jsx("h4",{className:"text-white font-light",children:"Seed Sessions"})]}),n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsxs("div",{className:"flex-1",children:[n.jsx(me,{htmlFor:"session-count",className:"text-sm text-gray-400 font-light",children:"Number of sessions"}),n.jsx(ue,{id:"session-count",type:"number",min:"1",max:"100",defaultValue:"5",className:"mt-1 border border-dashed border-white/20 bg-black/30 text-white rounded-none"})]}),n.jsx(T,{onClick:()=>{var A;const k=parseInt(((A=document.getElementById("session-count"))==null?void 0:A.value)||"5");G(k)},disabled:N,className:"bg-white hover:bg-white/90 text-black border border-white/20 rounded-none mt-6 disabled:opacity-50",children:N?n.jsxs(n.Fragment,{children:[n.jsx(ut,{className:"w-3 h-3 mr-2 animate-spin"}),"Seeding..."]}):n.jsxs(n.Fragment,{children:[n.jsx(ze,{className:"w-3 h-3 mr-2"}),"Seed Sessions"]})})]})]}),n.jsxs("div",{className:"space-y-4",children:[n.jsxs("div",{className:"flex items-center space-x-2",children:[n.jsx(Cu,{className:"w-5 h-5 text-white"}),n.jsx("h4",{className:"text-white font-light",children:"Seed Accounts"})]}),n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsxs("div",{className:"flex-1",children:[n.jsx(me,{htmlFor:"account-count",className:"text-sm text-gray-400 font-light",children:"Number of accounts"}),n.jsx(ue,{id:"account-count",type:"number",min:"1",max:"100",defaultValue:"5",className:"mt-1 border border-dashed border-white/20 bg-black/30 text-white rounded-none"})]}),n.jsx(T,{onClick:()=>{var A;const k=parseInt(((A=document.getElementById("account-count"))==null?void 0:A.value)||"5");V(k)},disabled:N,className:"bg-white hover:bg-white/90 text-black border border-white/20 rounded-none mt-6 disabled:opacity-50",children:N?n.jsxs(n.Fragment,{children:[n.jsx(ut,{className:"w-3 h-3 mr-2 animate-spin"}),"Seeding..."]}):n.jsxs(n.Fragment,{children:[n.jsx(Cu,{className:"w-3 h-3 mr-2"}),"Seed Accounts"]})})]})]}),j.length>0&&n.jsx("div",{className:"mt-6",children:n.jsx(fa,{title:"Session Seeding Terminal",lines:j,isRunning:N,className:"w-full",defaultCollapsed:!0})})]}),n.jsx("div",{className:"flex justify-end mt-6 pt-6 border-t border-dashed border-white/10",children:n.jsx(T,{variant:"outline",onClick:()=>m(!1),className:"border border-dashed border-white/20 text-white hover:bg-white/10 rounded-none",children:"Close"})})]})}),c&&n.jsx("div",{className:"fixed inset-0 bg-black/50 flex items-center justify-center z-50",children:n.jsxs("div",{className:"bg-black/90 border border-dashed border-white/20 p-6 w-full max-w-md rounded-none",children:[n.jsxs("div",{className:"flex items-center justify-between mb-4",children:[n.jsx("h3",{className:"text-lg text-white font-light",children:"Create Session"}),n.jsx(T,{variant:"ghost",size:"sm",onClick:()=>d(!1),className:"text-gray-400 hover:text-white rounded-none",children:n.jsx(we,{className:"w-4 h-4"})})]}),n.jsxs("div",{className:"space-y-4",children:[n.jsxs("div",{children:[n.jsx(me,{htmlFor:"create-user-id",className:"text-sm text-gray-400 font-light",children:"User ID"}),n.jsx(ue,{id:"create-user-id",className:"mt-1 border border-dashed border-white/20 bg-black/30 text-white rounded-none"})]}),n.jsxs("div",{children:[n.jsx(me,{htmlFor:"create-expires",className:"text-sm text-gray-400 font-light",children:"Expires At"}),n.jsx(ue,{id:"create-expires",type:"datetime-local",className:"mt-1 border border-dashed border-white/20 bg-black/30 text-white rounded-none"})]})]}),n.jsxs("div",{className:"flex justify-end space-x-3 mt-6",children:[n.jsx(T,{variant:"outline",onClick:()=>d(!1),className:"border border-dashed border-white/20 text-white hover:bg-white/10 rounded-none",children:"Cancel"}),n.jsx(T,{onClick:()=>ee({}),className:"bg-white hover:bg-white/90 text-black border border-white/20 rounded-none",children:"Create"})]})]})}),f&&p&&n.jsx("div",{className:"fixed inset-0 bg-black/50 flex items-center justify-center z-50",children:n.jsxs("div",{className:"bg-black/90 border border-dashed border-white/20 p-6 w-full max-w-md rounded-none",children:[n.jsxs("div",{className:"flex items-center justify-between mb-4",children:[n.jsx("h3",{className:"text-lg text-white font-light",children:"Edit Session"}),n.jsx(T,{variant:"ghost",size:"sm",onClick:()=>u(!1),className:"text-gray-400 hover:text-white rounded-none",children:n.jsx(we,{className:"w-4 h-4"})})]}),n.jsxs("div",{className:"space-y-4",children:[n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx("div",{className:"w-16 h-16 rounded-none border border-dashed border-white/20 bg-white/10 flex items-center justify-center",children:n.jsx(ze,{className:"w-8 h-8 text-white"})}),n.jsxs("div",{children:[n.jsxs("div",{className:"text-white font-light",children:["Session ",p.id.slice(0,8),"..."]}),n.jsx("div",{className:"text-sm text-gray-400",children:p.userId})]})]}),n.jsxs("div",{children:[n.jsx(me,{htmlFor:"edit-user-id",className:"text-sm text-gray-400 font-light",children:"User ID"}),n.jsx(ue,{id:"edit-user-id",defaultValue:p.userId,className:"mt-1 border border-dashed border-white/20 bg-black/30 text-white rounded-none"})]}),n.jsxs("div",{children:[n.jsx(me,{htmlFor:"edit-expires",className:"text-sm text-gray-400 font-light",children:"Expires At"}),n.jsx(ue,{id:"edit-expires",type:"datetime-local",defaultValue:new Date(p.expiresAt).toISOString().slice(0,16),className:"mt-1 border border-dashed border-white/20 bg-black/30 text-white rounded-none"})]})]}),n.jsxs("div",{className:"flex justify-end space-x-3 mt-6",children:[n.jsx(T,{variant:"outline",onClick:()=>u(!1),className:"border border-dashed border-white/20 text-white hover:bg-white/10 rounded-none",children:"Cancel"}),n.jsx(T,{onClick:()=>ie({}),className:"bg-white hover:bg-white/90 text-black border border-white/20 rounded-none",children:"Update"})]})]})}),x&&p&&n.jsx("div",{className:"fixed inset-0 bg-black/50 flex items-center justify-center z-50",children:n.jsxs("div",{className:"bg-black/90 border border-dashed border-white/20 p-6 w-full max-w-md rounded-none",children:[n.jsxs("div",{className:"flex items-center justify-between mb-4",children:[n.jsx("h3",{className:"text-lg text-white font-light",children:"Delete Session"}),n.jsx(T,{variant:"ghost",size:"sm",onClick:()=>y(!1),className:"text-gray-400 hover:text-white rounded-none",children:n.jsx(we,{className:"w-4 h-4"})})]}),n.jsxs("div",{className:"space-y-4",children:[n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx("div",{className:"w-16 h-16 rounded-none border border-dashed border-white/20 bg-white/10 flex items-center justify-center",children:n.jsx(ze,{className:"w-8 h-8 text-white"})}),n.jsxs("div",{children:[n.jsxs("div",{className:"text-white font-light",children:["Session ",p.id.slice(0,8),"..."]}),n.jsx("div",{className:"text-sm text-gray-400",children:p.userId})]})]}),n.jsx("p",{className:"text-gray-400",children:"Are you sure you want to delete this session? This action cannot be undone."})]}),n.jsxs("div",{className:"flex justify-end space-x-3 mt-6",children:[n.jsx(T,{variant:"outline",onClick:()=>y(!1),className:"border border-dashed border-white/20 text-white hover:bg-white/10 rounded-none",children:"Cancel"}),n.jsx(T,{onClick:D,className:"bg-red-600 hover:bg-red-700 text-white border border-red-600 rounded-none",children:"Delete"})]})]})}),w&&p&&n.jsx("div",{className:"fixed inset-0 bg-black/50 flex items-center justify-center z-50",children:n.jsxs("div",{className:"bg-black/90 border border-dashed border-white/20 p-6 w-full max-w-md rounded-none",children:[n.jsxs("div",{className:"flex items-center justify-between mb-4",children:[n.jsx("h3",{className:"text-lg text-white font-light",children:"Session Details"}),n.jsx(T,{variant:"ghost",size:"sm",onClick:()=>v(!1),className:"text-gray-400 hover:text-white rounded-none",children:n.jsx(we,{className:"w-4 h-4"})})]}),n.jsxs("div",{className:"space-y-4",children:[n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx("div",{className:"w-16 h-16 rounded-none border border-dashed border-white/20 bg-white/10 flex items-center justify-center",children:n.jsx(ze,{className:"w-8 h-8 text-white"})}),n.jsxs("div",{children:[n.jsxs("div",{className:"text-white font-light",children:["Session ",p.id.slice(0,8),"..."]}),n.jsx("div",{className:"text-sm text-gray-400",children:p.userId})]})]}),n.jsxs("div",{className:"space-y-2",children:[n.jsxs("div",{className:"flex justify-between",children:[n.jsx("span",{className:"text-gray-400",children:"ID:"}),n.jsx("span",{className:"text-white text-sm",children:p.id})]}),n.jsxs("div",{className:"flex justify-between",children:[n.jsx("span",{className:"text-gray-400",children:"User ID:"}),n.jsx("span",{className:"text-white text-sm",children:p.userId})]}),n.jsxs("div",{className:"flex justify-between",children:[n.jsx("span",{className:"text-gray-400",children:"Status:"}),n.jsx("span",{className:"text-white text-sm",children:new Date(p.expiresAt)>new Date?"Active":"Expired"})]}),n.jsxs("div",{className:"flex justify-between",children:[n.jsx("span",{className:"text-gray-400",children:"Expires:"}),n.jsx("span",{className:"text-white text-sm",children:new Date(p.expiresAt).toLocaleString()})]}),n.jsxs("div",{className:"flex justify-between",children:[n.jsx("span",{className:"text-gray-400",children:"Created:"}),n.jsx("span",{className:"text-white text-sm",children:new Date(p.createdAt).toLocaleString()})]}),n.jsxs("div",{className:"flex justify-between",children:[n.jsx("span",{className:"text-gray-400",children:"Updated:"}),n.jsx("span",{className:"text-white text-sm",children:new Date(p.updatedAt).toLocaleString()})]})]})]}),n.jsx("div",{className:"flex justify-end mt-6",children:n.jsx(T,{onClick:()=>v(!1),className:"bg-white hover:bg-white/90 text-black border border-white/20 rounded-none",children:"Close"})})]})})]})}function Sb(){const[e,t]=h.useState("overview"),r=()=>n.jsxs("div",{className:"space-y-8 animate-fade-in px-6 py-8",children:[n.jsxs("div",{children:[n.jsx("h1",{className:"text-2xl text-white font-normal",children:"Better Auth Studio"}),n.jsx("p",{className:"text-gray-400 mt-1 font-light",children:"Manage your authentication system"})]}),n.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-6",children:[n.jsx(Ze,{className:"border border-dashed border-white/20 bg-black/30 rounded-none hover:bg-black/50 transition-colors",children:n.jsxs(qe,{className:"p-6",children:[n.jsxs("div",{className:"flex items-center justify-between mb-4",children:[n.jsx("div",{className:"p-3 bg-white/10 rounded-none",children:n.jsx(xe,{className:"w-6 h-6 text-white"})}),n.jsx(oe,{className:"bg-white/10 text-white border border-dashed border-white/20 rounded-none",children:"Active"})]}),n.jsx("h3",{className:"text-lg text-white font-light mb-2",children:"User Management"}),n.jsx("p",{className:"text-gray-400 font-light mb-4",children:"Manage user accounts, profiles, and permissions"}),n.jsxs(T,{onClick:()=>t("users"),className:"w-full bg-white hover:bg-white/90 text-black border border-white/20 rounded-none",children:["Manage Users",n.jsx(tn,{className:"w-4 h-4 ml-2"})]})]})}),n.jsx(Ze,{className:"border border-dashed border-white/20 bg-black/30 rounded-none hover:bg-black/50 transition-colors",children:n.jsxs(qe,{className:"p-6",children:[n.jsxs("div",{className:"flex items-center justify-between mb-4",children:[n.jsx("div",{className:"p-3 bg-white/10 rounded-none",children:n.jsx(We,{className:"w-6 h-6 text-white"})}),n.jsx(oe,{className:"bg-white/10 text-white border border-dashed border-white/20 rounded-none",children:"Active"})]}),n.jsx("h3",{className:"text-lg text-white font-light mb-2",children:"Organizations"}),n.jsx("p",{className:"text-gray-400 font-light mb-4",children:"Manage organizations, teams, and memberships"}),n.jsxs(T,{onClick:()=>t("organizations"),className:"w-full bg-white hover:bg-white/90 text-black border border-white/20 rounded-none",children:["Manage Organizations",n.jsx(tn,{className:"w-4 h-4 ml-2"})]})]})}),n.jsx(Ze,{className:"border border-dashed border-white/20 bg-black/30 rounded-none hover:bg-black/50 transition-colors",children:n.jsxs(qe,{className:"p-6",children:[n.jsxs("div",{className:"flex items-center justify-between mb-4",children:[n.jsx("div",{className:"p-3 bg-white/10 rounded-none",children:n.jsx(ze,{className:"w-6 h-6 text-white"})}),n.jsx(oe,{className:"bg-white/10 text-white border border-dashed border-white/20 rounded-none",children:"Active"})]}),n.jsx("h3",{className:"text-lg text-white font-light mb-2",children:"Session Management"}),n.jsx("p",{className:"text-gray-400 font-light mb-4",children:"Monitor and manage user sessions"}),n.jsxs(T,{onClick:()=>t("sessions"),className:"w-full bg-white hover:bg-white/90 text-black border border-white/20 rounded-none",children:["Manage Sessions",n.jsx(tn,{className:"w-4 h-4 ml-2"})]})]})}),n.jsx(Ze,{className:"border border-dashed border-white/20 bg-black/30 rounded-none hover:bg-black/50 transition-colors",children:n.jsxs(qe,{className:"p-6",children:[n.jsxs("div",{className:"flex items-center justify-between mb-4",children:[n.jsx("div",{className:"p-3 bg-white/10 rounded-none",children:n.jsx(Jn,{className:"w-6 h-6 text-white"})}),n.jsx(oe,{className:"bg-white/10 text-white border border-dashed border-white/20 rounded-none",children:"Configured"})]}),n.jsx("h3",{className:"text-lg text-white font-light mb-2",children:"Configuration"}),n.jsx("p",{className:"text-gray-400 font-light mb-4",children:"View and manage auth configuration"}),n.jsxs(T,{variant:"outline",className:"w-full border border-dashed border-white/20 text-white hover:bg-white/10 rounded-none",children:["View Config",n.jsx(tn,{className:"w-4 h-4 ml-2"})]})]})}),n.jsx(Ze,{className:"border border-dashed border-white/20 bg-black/30 rounded-none hover:bg-black/50 transition-colors",children:n.jsxs(qe,{className:"p-6",children:[n.jsxs("div",{className:"flex items-center justify-between mb-4",children:[n.jsx("div",{className:"p-3 bg-white/10 rounded-none",children:n.jsx(Vo,{className:"w-6 h-6 text-white"})}),n.jsx(oe,{className:"bg-white/10 text-white border border-dashed border-white/20 rounded-none",children:"Coming Soon"})]}),n.jsx("h3",{className:"text-lg text-white font-light mb-2",children:"Analytics"}),n.jsx("p",{className:"text-gray-400 font-light mb-4",children:"View authentication analytics and insights"}),n.jsxs(T,{variant:"outline",disabled:!0,className:"w-full border border-dashed border-white/20 text-gray-400 rounded-none",children:["View Analytics",n.jsx(tn,{className:"w-4 h-4 ml-2"})]})]})}),n.jsx(Ze,{className:"border border-dashed border-white/20 bg-black/30 rounded-none hover:bg-black/50 transition-colors",children:n.jsxs(qe,{className:"p-6",children:[n.jsxs("div",{className:"flex items-center justify-between mb-4",children:[n.jsx("div",{className:"p-3 bg-white/10 rounded-none",children:n.jsx(ii,{className:"w-6 h-6 text-white"})}),n.jsx(oe,{className:"bg-white/10 text-white border border-dashed border-white/20 rounded-none",children:"Available"})]}),n.jsx("h3",{className:"text-lg text-white font-light mb-2",children:"Quick Actions"}),n.jsx("p",{className:"text-gray-400 font-light mb-4",children:"Common tasks and shortcuts"}),n.jsxs(T,{variant:"outline",className:"w-full border border-dashed border-white/20 text-white hover:bg-white/10 rounded-none",children:["View Actions",n.jsx(tn,{className:"w-4 h-4 ml-2"})]})]})})]})]});return n.jsx("div",{className:"min-h-screen bg-black text-white",children:e==="overview"?r():e==="users"?n.jsx(pp,{}):e==="organizations"?n.jsx(xp,{}):e==="sessions"?n.jsx(gp,{}):r()})}function Cb(){const{orgId:e}=xm(),t=qi(),[r,s]=h.useState(null),[a,i]=h.useState([]),[l,o]=h.useState([]),[c,d]=h.useState([]),[f,u]=h.useState(!0),[x,y]=h.useState("details"),[w,v]=h.useState(!1),[b,m]=h.useState(!1),[p,g]=h.useState(!1),[j,S]=h.useState(!1),[N,C]=h.useState(!1),[O,G]=h.useState(!1),[V,J]=h.useState(!1),[B,se]=h.useState(null),[ee,ie]=h.useState(""),[D,H]=h.useState(""),[k,A]=h.useState([]),[_,W]=h.useState({name:""}),[E,z]=h.useState(!1),[M,L]=h.useState([]),[R,X]=h.useState(!1),[Q,q]=h.useState([]),[Ne,pe]=h.useState(!1);h.useEffect(()=>{e&&(yr(),Bt(),Wt(),jt(),Vt())},[e]),h.useEffect(()=>{w&&e&&Vt()},[]),h.useEffect(()=>{x==="members"&&e&&jt()},[x,e]),h.useEffect(()=>{x==="invitations"&&e&&Wt()},[x,e]);const Pe=P=>{W({name:P})},yr=async()=>{try{const Y=await(await fetch(`/api/organizations/${e}`)).json();Y.success?s(Y.organization):I.error("Organization not found")}catch(P){console.error("Failed to fetch organization:",P),I.error("Failed to load organization")}finally{u(!1)}},Bt=async()=>{try{const Y=await(await fetch("/api/plugins/teams/status")).json();v(Y.enabled)}catch(P){console.error("Failed to check teams status:",P),v(!1)}},Vt=async()=>{try{const Y=await(await fetch(`/api/organizations/${e}/teams`)).json();Y.success&&i(Y.teams||[])}catch(P){console.error("Failed to fetch teams:",P),I.error("Failed to load teams")}},Wt=async()=>{try{const Y=await(await fetch(`/api/organizations/${e}/invitations`)).json();Y.success&&o(Y.invitations||[])}catch(P){console.error("Failed to fetch invitations:",P),I.error("Failed to load invitations")}},jt=async()=>{try{const Y=await(await fetch(`/api/organizations/${e}/members`)).json();Y.success&&d(Y.members||[])}catch(P){console.error("Failed to fetch members:",P),I.error("Failed to load members")}},Nn=async P=>{L([]),X(!0),L([{id:"start",type:"info",message:`Starting member seeding process for ${P} members...`,timestamp:new Date}]);try{const ae=await(await fetch(`/api/organizations/${e}/seed-members`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({count:P})})).json();if(ae.success){const Ae=ae.results.map((ke,sr)=>ke.success?{id:`member-${sr}`,type:"progress",message:`Adding member: ${ke.member.user.name} (${ke.member.user.email})`,timestamp:new Date,status:"completed"}:{id:`member-${sr}`,type:"error",message:`Failed to add member ${sr+1}: ${ke.error}`,timestamp:new Date});L(ke=>[...ke,...Ae]);const lt=ae.results.filter(ke=>ke.success).length;L(ke=>[...ke,{id:"complete",type:"success",message:`✅ Seeding completed! Added ${lt}/${P} members successfully`,timestamp:new Date}]),await jt(),I.success(`Successfully added ${lt} members!`)}else L(Ae=>[...Ae,{id:"error",type:"error",message:`❌ Seeding failed: ${ae.error||"Unknown error"}`,timestamp:new Date}]),I.error(ae.error||"Failed to seed members")}catch(Y){L(ae=>[...ae,{id:"error",type:"error",message:`❌ Network error: ${Y}`,timestamp:new Date}]),I.error("Failed to seed members")}finally{X(!1)}},Ye=async P=>{q([]),pe(!0),q([{id:"start",type:"info",message:`Starting team seeding process for ${P} teams...`,timestamp:new Date}]);try{const ae=await(await fetch(`/api/organizations/${e}/seed-teams`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({count:P})})).json();if(ae.success){const Ae=ae.results.map((ke,sr)=>ke.success?{id:`team-${sr}`,type:"progress",message:`Creating team: ${ke.team.name}`,timestamp:new Date,status:"completed"}:{id:`team-${sr}`,type:"error",message:`Failed to create team ${sr+1}: ${ke.error}`,timestamp:new Date});q(ke=>[...ke,...Ae]);const lt=ae.results.filter(ke=>ke.success).length;q(ke=>[...ke,{id:"complete",type:"success",message:`✅ Seeding completed! Created ${lt}/${P} teams successfully`,timestamp:new Date}]),await Vt(),I.success(`Successfully created ${lt} teams!`)}else q(Ae=>[...Ae,{id:"error",type:"error",message:`❌ Seeding failed: ${ae.error||"Unknown error"}`,timestamp:new Date}]),I.error(ae.error||"Failed to seed teams")}catch(Y){q(ae=>[...ae,{id:"error",type:"error",message:`❌ Network error: ${Y}`,timestamp:new Date}]),I.error("Failed to seed teams")}finally{pe(!1)}},gs=async()=>{try{const Y=await(await fetch("/api/users/all")).json();Y.success&&A(Y.users||[])}catch(P){console.error("Failed to fetch users:",P)}},rr=()=>{gs(),m(!0)},Oe=async()=>{if(!ee){I.error("Please enter an email address");return}if(!D){I.error("Please select an inviter");return}z(!0);const P=I.loading("Sending invitation...");try{const ae=await(await fetch(`/api/organizations/${e}/invitations`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({email:ee,role:"member",inviterId:D})})).json();ae.success?(await Wt(),m(!1),ie(""),H(""),I.success("Invitation sent successfully!",{id:P})):I.error(`Error sending invitation: ${ae.error||"Unknown error"}`,{id:P})}catch(Y){console.error("Error sending invitation:",Y),I.error("Error sending invitation",{id:P})}finally{z(!1)}},Ht=async P=>{const Y=I.loading("Cancelling invitation...");try{const Ae=await(await fetch(`/api/invitations/${P}`,{method:"DELETE",headers:{"Content-Type":"application/json"}})).json();Ae.success?(await Wt(),I.success("Invitation cancelled successfully!",{id:Y})):I.error(`Error cancelling invitation: ${Ae.error||"Unknown error"}`,{id:Y})}catch(ae){console.error("Error cancelling invitation:",ae),I.error("Error cancelling invitation",{id:Y})}},vs=async(P,Y)=>{const ae=I.loading("Resending invitation...");try{const lt=await(await fetch(`/api/invitations/${P}/resend`,{method:"POST",headers:{"Content-Type":"application/json"}})).json();lt.success?(await Wt(),I.success(`Invitation resent to ${Y}!`,{id:ae})):I.error(`Error resending invitation: ${lt.error||"Unknown error"}`,{id:ae})}catch(Ae){console.error("Error resending invitation:",Ae),I.error("Error resending invitation",{id:ae})}},F=async(P,Y)=>{const ae=I.loading(`Removing ${Y}...`);try{const lt=await(await fetch(`/api/members/${P}`,{method:"DELETE",headers:{"Content-Type":"application/json"}})).json();lt.success?(await jt(),I.success(`${Y} removed from organization!`,{id:ae})):I.error(`Error removing member: ${lt.error||"Unknown error"}`,{id:ae})}catch(Ae){console.error("Error removing member:",Ae),I.error("Error removing member",{id:ae})}},Z=async()=>{if(!_.name){I.error("Please enter a team name");return}const P=I.loading("Creating team...");try{const ae=await(await fetch(`/api/organizations/${e}/teams`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({name:_.name,organizationId:e})})).json();ae.success?(await Vt(),C(!1),W({name:""}),I.success("Team created successfully!",{id:P})):I.error(`Error creating team: ${ae.error||"Unknown error"}`,{id:P})}catch(Y){console.error("Error creating team:",Y),I.error("Error creating team",{id:P})}},de=async()=>{if(!B||!_.name){I.error("Please enter a team name");return}const P=I.loading("Updating team...");try{const ae=await(await fetch(`/api/teams/${B.id}`,{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({name:_.name})})).json();ae.success?(await Vt(),G(!1),se(null),W({name:""}),I.success("Team updated successfully!",{id:P})):I.error(`Error updating team: ${ae.error||"Unknown error"}`,{id:P})}catch(Y){console.error("Error updating team:",Y),I.error("Error updating team",{id:P})}},rt=async()=>{if(!B){I.error("No team selected");return}const P=I.loading("Deleting team...");try{const ae=await(await fetch(`/api/teams/${B.id}`,{method:"DELETE",headers:{"Content-Type":"application/json"}})).json();ae.success?(await Vt(),J(!1),se(null),I.success("Team deleted successfully!",{id:P})):I.error(`Error deleting team: ${ae.error||"Unknown error"}`,{id:P})}catch(Y){console.error("Error deleting team:",Y),I.error("Error deleting team",{id:P})}},nr=P=>{se(P),W({name:P.name}),G(!0)},he=P=>{se(P),J(!0)};return f?n.jsx("div",{className:"flex items-center justify-center h-32",children:n.jsxs("div",{className:"flex flex-col items-center space-y-3",children:[n.jsx(ut,{className:"w-6 h-6 text-white animate-spin"}),n.jsx("div",{className:"text-white text-sm",children:"Loading organization details..."})]})}):r?n.jsxs("div",{className:"space-y-6 p-6",children:[n.jsxs("div",{className:"flex items-center justify-between",children:[n.jsx("div",{className:"flex items-center space-x-4",children:n.jsx(Xn,{to:"/organizations",children:n.jsxs(T,{variant:"ghost",className:"text-gray-400 hover:text-white rounded-none",children:[n.jsx(Ii,{className:"w-4 h-4 mr-2"}),"Back to Organizations"]})})}),n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsxs(T,{onClick:()=>g(!0),className:"border border-dashed border-white/20 text-white bg-transparent hover:bg-white/10 rounded-none",children:[n.jsx(xe,{className:"w-4 h-4 mr-2"}),"Seed Members"]}),n.jsxs(T,{onClick:rr,className:"border border-dashed border-white/20 text-white bg-transparent hover:bg-white/10 rounded-none",children:[n.jsx(_t,{className:"w-4 h-4 mr-2"}),"Invite User"]}),n.jsxs(T,{className:"bg-white hover:bg-white/90 text-black border border-white/20 rounded-none",children:[n.jsx(ls,{className:"w-4 h-4 mr-2"}),"Edit Organization"]})]})]}),n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx("div",{className:"w-12 h-12 bg-white/10 border border-dashed border-white/20 rounded-none flex items-center justify-center",children:n.jsx(We,{className:"w-6 h-6 text-white"})}),n.jsxs("div",{children:[n.jsx("h1",{className:"text-2xl text-white font-light",children:r.name}),n.jsx("p",{className:"text-gray-400",children:r.slug})]})]}),n.jsx("div",{className:"border-b border-white/10",children:n.jsxs("nav",{className:"flex space-x-8",children:[n.jsxs("button",{onClick:()=>y("details"),className:`flex items-center space-x-2 px-3 py-4 text-sm font-medium border-b-2 transition-all duration-200 ${x==="details"?"border-white text-white":"border-transparent text-gray-400 hover:text-white hover:border-gray-300"}`,children:[n.jsx(We,{className:"w-4 h-4"}),n.jsx("span",{children:"Details"}),n.jsx(oe,{variant:"secondary",className:"text-xs bg-white/10 border border-white/20 rounded-sm",children:c.length+l.length+a.length})]}),n.jsxs("button",{onClick:()=>y("members"),className:`flex items-center space-x-2 px-3 py-4 text-sm font-medium border-b-2 transition-all duration-200 ${x==="members"?"border-white text-white":"border-transparent text-gray-400 hover:text-white hover:border-gray-300"}`,children:[n.jsx(xe,{className:"w-4 h-4"}),n.jsx("span",{children:"Members"}),c.length>0&&n.jsx(oe,{variant:"secondary",className:"text-xs bg-white/10 border border-white/20 rounded-sm",children:c.length})]}),n.jsxs("button",{onClick:()=>y("invitations"),className:`flex items-center space-x-2 px-3 py-4 text-sm font-medium border-b-2 transition-all duration-200 ${x==="invitations"?"border-white text-white":"border-transparent text-gray-400 hover:text-white hover:border-gray-300"}`,children:[n.jsx(_t,{className:"w-4 h-4"}),n.jsx("span",{children:"Invitations"}),l.length>0&&n.jsx(oe,{variant:"secondary",className:"text-xs bg-white/10 border border-white/20 rounded-sm",children:l.length})]}),n.jsxs("button",{onClick:()=>y("teams"),className:`flex items-center space-x-2 px-3 py-4 text-sm font-medium border-b-2 transition-all duration-200 ${x==="teams"?"border-white text-white":"border-transparent text-gray-400 hover:text-white hover:border-gray-300"}`,children:[n.jsx(xe,{className:"w-4 h-4"}),n.jsx("span",{children:"Teams"}),a.length>0&&n.jsx(oe,{variant:"secondary",className:"text-xs bg-white/10 border border-white/20 rounded-sm",children:a.length})]})]})}),x==="details"&&n.jsxs("div",{className:"space-y-6",children:[n.jsxs("div",{className:"bg-black/30 border border-dashed border-white/20 rounded-none p-6",children:[n.jsx("h3",{className:"text-lg text-white font-light mb-4",children:"Organization Information"}),n.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-6",children:[n.jsxs("div",{children:[n.jsx("label",{className:"text-sm text-gray-400 font-light",children:"Name"}),n.jsx("p",{className:"text-white mt-1",children:r.name})]}),n.jsxs("div",{children:[n.jsx("label",{className:"text-sm text-gray-400 font-light",children:"Slug"}),n.jsx("p",{className:"text-white mt-1",children:r.slug})]}),n.jsxs("div",{children:[n.jsx("label",{className:"text-sm text-gray-400 font-light",children:"Created"}),n.jsx("p",{className:"text-white mt-1",children:new Date(r.createdAt).toLocaleDateString("en-US",{year:"numeric",month:"long",day:"numeric"})})]}),n.jsxs("div",{children:[n.jsx("label",{className:"text-sm text-gray-400 font-light",children:"Last Updated"}),n.jsx("p",{className:"text-white mt-1",children:new Date(r.updatedAt).toLocaleDateString("en-US",{year:"numeric",month:"long",day:"numeric"})})]})]})]}),n.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-4 gap-6",children:[n.jsx("div",{className:"bg-black/30 border border-dashed border-white/20 rounded-none p-6",children:n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx(xe,{className:"w-8 h-8 text-white"}),n.jsxs("div",{children:[n.jsx("p",{className:"text-2xl text-white font-light",children:c.length}),n.jsx("p",{className:"text-sm text-gray-400",children:"Members"})]})]})}),n.jsx("div",{className:"bg-black/30 border border-dashed border-white/20 rounded-none p-6",children:n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx(xe,{className:"w-8 h-8 text-white"}),n.jsxs("div",{children:[n.jsx("p",{className:"text-2xl text-white font-light",children:a.length}),n.jsx("p",{className:"text-sm text-gray-400",children:"Teams"})]})]})}),n.jsx("div",{className:"bg-black/30 border border-dashed border-white/20 rounded-none p-6",children:n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx(_t,{className:"w-8 h-8 text-white"}),n.jsxs("div",{children:[n.jsx("p",{className:"text-2xl text-white font-light",children:l.length}),n.jsx("p",{className:"text-sm text-gray-400",children:"Invitations"})]})]})}),n.jsx("div",{className:"bg-black/30 border border-dashed border-white/20 rounded-none p-6",children:n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx(bm,{className:"w-8 h-8 text-white"}),n.jsxs("div",{children:[n.jsx("p",{className:"text-2xl text-white font-light",children:Math.ceil((new Date().getTime()-new Date(r.createdAt).getTime())/(1e3*60*60*24))}),n.jsx("p",{className:"text-sm text-gray-400",children:"Days Active"})]})]})})]})]}),x==="teams"&&n.jsxs("div",{className:"space-y-6",children:[n.jsxs("div",{className:"flex items-center justify-between",children:[n.jsxs("div",{children:[n.jsxs("h3",{className:"text-lg text-white font-light",children:["Teams (",a.length,")"]}),n.jsx("p",{className:"text-gray-400 mt-1",children:"Manage teams within this organization"})]}),n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsxs(T,{onClick:()=>S(!0),className:"border border-dashed border-white/20 text-white hover:bg-white/10 bg-transparent rounded-none",children:[n.jsx(ze,{className:"w-4 h-4 mr-2"}),"Seed Teams"]}),n.jsxs(T,{onClick:()=>C(!0),className:"bg-white hover:bg-white/90 text-black border border-white/20 rounded-none",children:[n.jsx(Br,{className:"w-4 h-4 mr-2"}),"Create Team"]})]})]}),a.length>0?n.jsx("div",{className:"bg-black/30 border border-dashed border-white/20 rounded-none",children:n.jsx("div",{className:"overflow-x-auto",children:n.jsxs("table",{className:"w-full",children:[n.jsx("thead",{children:n.jsxs("tr",{className:"border-b border-dashed border-white/10",children:[n.jsx("th",{className:"text-left py-4 px-4 text-white font-light",children:"Team"}),n.jsx("th",{className:"text-left py-4 px-4 text-white font-light",children:"Members"}),n.jsx("th",{className:"text-left py-4 px-4 text-white font-light",children:"Created"}),n.jsx("th",{className:"text-right py-4 px-4 text-white font-light",children:"Actions"})]})}),n.jsx("tbody",{children:a.map(P=>n.jsxs("tr",{className:"border-b border-dashed border-white/5 hover:bg-white/5 cursor-pointer",onClick:()=>t(`/teams/${P.id}`),children:[n.jsx("td",{className:"py-4 px-4",children:n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx("div",{className:"w-10 h-10 bg-white/10 border border-dashed border-white/20 rounded-none flex items-center justify-center",children:n.jsx(xe,{className:"w-5 h-5 text-white"})}),n.jsxs("div",{children:[n.jsx("div",{className:"text-white font-light",children:P.name}),n.jsxs("div",{className:"text-sm text-gray-400",children:["Team ID: ",P.id]})]})]})}),n.jsx("td",{className:"py-4 px-4 text-white",children:P.memberCount||0}),n.jsx("td",{className:"py-4 px-4 text-sm text-gray-400",children:new Date(P.createdAt).toLocaleDateString()}),n.jsx("td",{className:"py-4 px-4 text-right",children:n.jsxs("div",{className:"flex items-center justify-end space-x-2",children:[n.jsxs(T,{variant:"outline",size:"sm",className:"border border-dashed border-white/20 text-white hover:bg-white/10 rounded-none",onClick:Y=>{Y.stopPropagation(),nr(P)},children:[n.jsx(ls,{className:"w-4 h-4 mr-1"}),"Edit"]}),n.jsxs(T,{variant:"outline",size:"sm",className:"border border-dashed border-red-400/50 text-red-400 hover:bg-red-400/10 rounded-none",onClick:Y=>{Y.stopPropagation(),he(P)},children:[n.jsx(cn,{className:"w-4 h-4 mr-1"}),"Delete"]})]})})]},P.id))})]})})}):n.jsx("div",{className:"bg-black/30 border border-dashed border-white/20 rounded-none p-12",children:n.jsxs("div",{className:"text-center",children:[n.jsx(xe,{className:"w-16 h-16 text-gray-400 mx-auto mb-4"}),n.jsx("h3",{className:"text-xl text-white font-light mb-2",children:"No Teams Yet"}),n.jsx("p",{className:"text-gray-400 mb-6",children:"Create your first team to start organizing members within this organization."}),n.jsxs(T,{onClick:()=>C(!0),className:"bg-white hover:bg-white/90 text-black border border-white/20 rounded-none",children:[n.jsx(Br,{className:"w-4 h-4 mr-2"}),"Create First Team"]})]})})]}),x==="members"&&n.jsxs("div",{className:"space-y-6",children:[n.jsx("div",{className:"flex items-center justify-between",children:n.jsxs("div",{children:[n.jsxs("h3",{className:"text-lg text-white font-light",children:["Members (",c.length,")"]}),n.jsx("p",{className:"text-gray-400 mt-1",children:"Manage organization members and their roles"})]})}),c.length>0?n.jsx("div",{className:"bg-black/30 border border-dashed border-white/20 rounded-none",children:n.jsx("div",{className:"overflow-x-auto",children:n.jsxs("table",{className:"w-full",children:[n.jsx("thead",{children:n.jsxs("tr",{className:"border-b border-dashed border-white/10",children:[n.jsx("th",{className:"text-left py-4 px-4 text-white font-light",children:"User"}),n.jsx("th",{className:"text-left py-4 px-4 text-white font-light",children:"Email"}),n.jsx("th",{className:"text-left py-4 px-4 text-white font-light",children:"Role"}),n.jsx("th",{className:"text-left py-4 px-4 text-white font-light",children:"Joined"}),n.jsx("th",{className:"text-right py-4 px-4 text-white font-light",children:"Actions"})]})}),n.jsx("tbody",{children:c.map(P=>n.jsxs("tr",{className:"border-b border-dashed border-white/5 hover:bg-white/5",children:[n.jsx("td",{className:"py-4 px-4",children:n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx("img",{src:P.user.image||`https://api.dicebear.com/7.x/avataaars/svg?seed=${P.user.id}`,alt:P.user.name,className:"w-10 h-10 rounded-none border border-dashed border-white/20"}),n.jsxs("div",{children:[n.jsx("div",{className:"text-white font-light",children:P.user.name}),n.jsxs("div",{className:"text-sm text-gray-400",children:["ID: ",P.user.id]})]})]})}),n.jsx("td",{className:"py-4 px-4 text-white",children:P.user.email}),n.jsx("td",{className:"py-4 px-4",children:n.jsx(oe,{variant:"secondary",className:"text-xs bg-blue-900/10 border border-dashed rounded-none border-blue-500/30 text-blue-400/70 capitalize",children:P.role})}),n.jsx("td",{className:"py-4 px-4 text-sm text-gray-400",children:new Date(P.joinedAt).toLocaleDateString()}),n.jsx("td",{className:"py-4 px-4 text-right",children:n.jsx("div",{className:"flex items-center justify-end space-x-2",children:n.jsxs(T,{variant:"outline",size:"sm",className:"border border-dashed border-red-400/50 text-red-400 hover:bg-red-400/10 rounded-none",onClick:()=>F(P.id,P.user.name),children:[n.jsx(cn,{className:"w-4 h-4 mr-1"}),"Remove"]})})})]},P.id))})]})})}):n.jsx("div",{className:"bg-black/30 border border-dashed border-white/20 rounded-none p-12",children:n.jsxs("div",{className:"text-center",children:[n.jsx(xe,{className:"w-16 h-16 text-gray-400 mx-auto mb-4"}),n.jsx("h3",{className:"text-xl text-white font-light mb-2",children:"No Members Yet"}),n.jsx("p",{className:"text-gray-400 mb-6",children:"Invite users or seed members from existing users to get started."}),n.jsxs("div",{className:"flex items-center justify-center space-x-3",children:[n.jsxs(T,{onClick:()=>g(!0),className:"border border-dashed border-white/20 text-white hover:bg-white/10 bg-transparent rounded-none",children:[n.jsx(xe,{className:"w-4 h-4 mr-2"}),"Seed Members"]}),n.jsxs(T,{onClick:rr,className:"bg-white text-white hover:bg-white/90 bg-transparent border border-white/20 rounded-none",children:[n.jsx(_t,{className:"w-4 h-4 mr-2"}),"Invite User"]})]})]})})]}),x==="invitations"&&n.jsxs("div",{className:"space-y-6",children:[n.jsx("div",{className:"flex items-center justify-between",children:n.jsxs("div",{children:[n.jsxs("h3",{className:"text-lg text-white font-light",children:["Invitations (",l.length,")"]}),n.jsx("p",{className:"text-gray-400 mt-1",children:"Manage pending invitations to this organization"})]})}),l.length>0?n.jsx("div",{className:"bg-black/30 border border-dashed border-white/20 rounded-none",children:n.jsx("div",{className:"overflow-x-auto",children:n.jsxs("table",{className:"w-full",children:[n.jsx("thead",{children:n.jsxs("tr",{className:"border-b border-dashed border-white/10",children:[n.jsx("th",{className:"text-left py-4 px-4 text-white font-light",children:"Email"}),n.jsx("th",{className:"text-left py-4 px-4 text-white font-light",children:"Role"}),n.jsx("th",{className:"text-left py-4 px-4 text-white font-light",children:"Status"}),n.jsx("th",{className:"text-left py-4 px-4 text-white font-light",children:"Expires"}),n.jsx("th",{className:"text-right py-4 px-4 text-white font-light",children:"Actions"})]})}),n.jsx("tbody",{children:l.map(P=>n.jsxs("tr",{className:"border-b border-dashed border-white/5 hover:bg-white/5",children:[n.jsx("td",{className:"py-4 px-4",children:n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx("div",{className:"w-10 h-10 bg-white/10 border border-dashed border-white/20 rounded-none flex items-center justify-center",children:n.jsx(_t,{className:"w-5 h-5 text-white"})}),n.jsxs("div",{children:[n.jsx("div",{className:"text-white font-light",children:P.email}),n.jsxs("div",{className:"text-sm text-gray-400",children:["Invited ",new Date(P.createdAt).toLocaleDateString()]})]})]})}),n.jsx("td",{className:"py-4 px-4 text-white capitalize",children:P.role}),n.jsx("td",{className:"py-4 px-4",children:n.jsxs(oe,{variant:"secondary",className:`text-xs font-normal rounded-none border-dashed flex items-center gap-1 w-fit ${P.status==="pending"?"bg-yellow-900/10 border border-yellow-500/30 text-yellow-400/70":P.status==="accepted"?"bg-green-900/10 border border-green-500/30 text-green-400/70":"bg-red-900/10 border border-red-500/30 text-red-400/70"}`,children:[P.status==="pending"&&n.jsx(_s,{className:"w-3 h-3"}),P.status==="accepted"&&n.jsx(Ie,{className:"w-3 h-3"}),P.status==="expired"&&n.jsx(we,{className:"w-3 h-3"}),P.status]})}),n.jsx("td",{className:"py-4 px-4 text-sm text-gray-400",children:new Date(P.expiresAt).toLocaleDateString()}),n.jsx("td",{className:"py-4 px-4 text-right",children:n.jsxs("div",{className:"flex items-center justify-end space-x-2",children:[n.jsxs(T,{variant:"outline",size:"sm",className:"border border-dashed border-white/20 text-white hover:bg-white/10 rounded-none",onClick:()=>vs(P.id,P.email),children:[n.jsx(Su,{className:"w-4 h-4 mr-1"}),"Resend"]}),n.jsxs(T,{variant:"outline",size:"sm",className:"border border-dashed border-red-400/50 text-red-400 hover:bg-red-400/10 rounded-none",onClick:()=>Ht(P.id),children:[n.jsx(cn,{className:"w-4 h-4 mr-1"}),"Cancel"]})]})})]},P.id))})]})})}):n.jsx("div",{className:"bg-black/30 border border-dashed border-white/20 rounded-none p-12",children:n.jsxs("div",{className:"text-center",children:[n.jsx(_t,{className:"w-16 h-16 text-gray-400 mx-auto mb-4"}),n.jsx("h3",{className:"text-xl text-white font-light mb-2",children:"No Invitations"}),n.jsx("p",{className:"text-gray-400 mb-6",children:"Start inviting users to join this organization."}),n.jsxs(T,{onClick:rr,className:"bg-white hover:bg-white/90 text-black border border-white/20 rounded-none",children:[n.jsx(_t,{className:"w-4 h-4 mr-2"}),"Send First Invitation"]})]})})]}),b&&n.jsx("div",{className:"fixed inset-0 bg-black/50 flex items-center justify-center z-50",children:n.jsxs("div",{className:"bg-black/90 border border-dashed border-white/20 p-6 w-full max-w-md rounded-none",children:[n.jsxs("div",{className:"flex items-center justify-between mb-4",children:[n.jsx("h3",{className:"text-lg text-white font-light",children:"Invite User"}),n.jsx(T,{variant:"ghost",size:"sm",onClick:()=>{m(!1),ie(""),H("")},className:"text-gray-400 hover:text-white rounded-none",children:n.jsx(we,{className:"w-4 h-4"})})]}),n.jsxs("div",{className:"space-y-4",children:[n.jsxs("div",{children:[n.jsx(me,{htmlFor:"invite-email",className:"text-sm text-gray-400 font-light",children:"Email Address"}),n.jsx(ue,{id:"invite-email",type:"email",value:ee,onChange:P=>ie(P.target.value),placeholder:"user@example.com",className:"mt-1 border border-dashed border-white/20 bg-black/30 text-white rounded-none"})]}),n.jsxs("div",{children:[n.jsx(me,{htmlFor:"inviter-select",className:"text-sm text-gray-400 font-light",children:"Inviter"}),n.jsxs(os,{value:D,onValueChange:H,children:[n.jsx(cs,{children:n.jsx(ds,{placeholder:"Select an inviter..."})}),n.jsx(us,{children:k.map(P=>n.jsx(Et,{value:P.id,children:n.jsxs("div",{className:"flex items-center space-x-2",children:[n.jsx("img",{src:P.image||`https://api.dicebear.com/7.x/avataaars/svg?seed=${P.id}`,alt:P.name,className:"w-6 h-6 rounded-none border border-dashed border-white/20"}),n.jsxs("span",{children:[P.name," (",P.email,")"]})]})},P.id))})]})]})]}),n.jsxs("div",{className:"flex justify-end space-x-3 mt-6",children:[n.jsx(T,{variant:"outline",onClick:()=>{m(!1),ie(""),H("")},className:"border border-dashed border-white/20 text-white hover:bg-white/10 rounded-none",children:"Cancel"}),n.jsxs(T,{onClick:Oe,disabled:E,className:"bg-white hover:bg-white/90 text-black border border-white/20 rounded-none disabled:opacity-50",children:[E?n.jsx(ut,{className:"w-3 h-3 mr-2 animate-spin"}):n.jsx(Su,{className:"w-4 h-4 mr-2"}),E?"Sending...":"Send Invitation"]})]})]})}),N&&n.jsx("div",{className:"fixed inset-0 bg-black/50 flex items-center justify-center z-50",children:n.jsxs("div",{className:"bg-black/90 border border-dashed border-white/20 p-6 w-full max-w-md rounded-none",children:[n.jsxs("div",{className:"flex items-center justify-between mb-4",children:[n.jsx("h3",{className:"text-lg text-white font-light",children:"Create Team"}),n.jsx(T,{variant:"ghost",size:"sm",onClick:()=>{C(!1),W({name:""})},className:"text-gray-400 hover:text-white rounded-none",children:n.jsx(we,{className:"w-4 h-4"})})]}),n.jsx("div",{className:"space-y-4",children:n.jsxs("div",{children:[n.jsx(me,{htmlFor:"team-name",className:"text-sm text-gray-400 font-light",children:"Team Name"}),n.jsx(ue,{id:"team-name",value:_.name,onChange:P=>Pe(P.target.value),placeholder:"e.g. Development Team",className:"mt-1 border border-dashed border-white/20 bg-black/30 text-white rounded-none"})]})}),n.jsxs("div",{className:"flex justify-end space-x-3 mt-6",children:[n.jsx(T,{variant:"outline",onClick:()=>{C(!1),W({name:""})},className:"border border-dashed border-white/20 text-white hover:bg-white/10 rounded-none",children:"Cancel"}),n.jsx(T,{onClick:Z,className:"bg-white hover:bg-white/90 text-black border border-white/20 rounded-none",children:"Create Team"})]})]})}),O&&B&&n.jsx("div",{className:"fixed inset-0 bg-black/50 flex items-center justify-center z-50",children:n.jsxs("div",{className:"bg-black/90 border border-dashed border-white/20 p-6 w-full max-w-md rounded-none",children:[n.jsxs("div",{className:"flex items-center justify-between mb-4",children:[n.jsx("h3",{className:"text-lg text-white font-light",children:"Edit Team"}),n.jsx(T,{variant:"ghost",size:"sm",onClick:()=>{G(!1),W({name:""})},className:"text-gray-400 hover:text-white rounded-none",children:n.jsx(we,{className:"w-4 h-4"})})]}),n.jsxs("div",{className:"space-y-4",children:[n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx("div",{className:"w-16 h-16 bg-white/10 border border-dashed border-white/20 rounded-none flex items-center justify-center",children:n.jsx(xe,{className:"w-8 h-8 text-white"})}),n.jsxs("div",{children:[n.jsx("div",{className:"text-white font-light",children:B.name}),n.jsxs("div",{className:"text-sm text-gray-400",children:["Team ID: ",B.id]})]})]}),n.jsxs("div",{children:[n.jsx(me,{htmlFor:"edit-team-name",className:"text-sm text-gray-400 font-light",children:"Team Name"}),n.jsx(ue,{id:"edit-team-name",value:_.name,onChange:P=>Pe(P.target.value),placeholder:"e.g. Development Team",className:"mt-1 border border-dashed border-white/20 bg-black/30 text-white rounded-none"})]})]}),n.jsxs("div",{className:"flex justify-end space-x-3 mt-6",children:[n.jsx(T,{variant:"outline",onClick:()=>{G(!1),W({name:""})},className:"border border-dashed border-white/20 text-white hover:bg-white/10 rounded-none",children:"Cancel"}),n.jsx(T,{onClick:de,className:"bg-white hover:bg-white/90 text-black border border-white/20 rounded-none",children:"Update Team"})]})]})}),V&&B&&n.jsx("div",{className:"fixed inset-0 bg-black/50 flex items-center justify-center z-50",children:n.jsxs("div",{className:"bg-black/90 border border-dashed border-white/20 p-6 w-full max-w-md rounded-none",children:[n.jsxs("div",{className:"flex items-center justify-between mb-4",children:[n.jsx("h3",{className:"text-lg text-white font-light",children:"Delete Team"}),n.jsx(T,{variant:"ghost",size:"sm",onClick:()=>J(!1),className:"text-gray-400 hover:text-white rounded-none",children:n.jsx(we,{className:"w-4 h-4"})})]}),n.jsxs("div",{className:"space-y-4",children:[n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx("div",{className:"w-16 h-16 bg-white/10 border border-dashed border-white/20 rounded-none flex items-center justify-center",children:n.jsx(xe,{className:"w-8 h-8 text-white"})}),n.jsxs("div",{children:[n.jsx("div",{className:"text-white font-light",children:B.name}),n.jsxs("div",{className:"text-sm text-gray-400",children:["Team ID: ",B.id]})]})]}),n.jsx("p",{className:"text-gray-400",children:"Are you sure you want to delete this team? This action cannot be undone."})]}),n.jsxs("div",{className:"flex justify-end space-x-3 mt-6",children:[n.jsx(T,{variant:"outline",onClick:()=>J(!1),className:"border border-dashed border-white/20 text-white hover:bg-white/10 rounded-none",children:"Cancel"}),n.jsx(T,{onClick:rt,className:"bg-red-600 hover:bg-red-700 text-white border border-red-600 rounded-none",children:"Delete Team"})]})]})}),p&&n.jsx("div",{className:"fixed inset-0 bg-black/50 flex items-center justify-center z-50",children:n.jsxs("div",{className:"bg-black/90 border border-dashed border-white/20 p-6 w-full max-w-2xl rounded-none",children:[n.jsxs("div",{className:"flex items-center justify-between mb-6",children:[n.jsx("h3",{className:"text-lg text-white font-light",children:"Seed Members"}),n.jsx(T,{variant:"ghost",size:"sm",onClick:()=>g(!1),className:"text-gray-400 hover:text-white rounded-none",children:n.jsx(we,{className:"w-4 h-4"})})]}),n.jsxs("div",{className:"space-y-6",children:[n.jsxs("div",{className:"space-y-4",children:[n.jsxs("div",{className:"flex items-center space-x-2",children:[n.jsx(xe,{className:"w-5 h-5 text-white"}),n.jsx("h4",{className:"text-white font-light",children:"Add Members from Existing Users"})]}),n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsxs("div",{className:"flex-1",children:[n.jsx(me,{htmlFor:"member-count",className:"text-sm text-gray-400 font-light",children:"Number of members to add"}),n.jsx(ue,{id:"member-count",type:"number",min:"1",max:"50",defaultValue:"5",className:"mt-1 border border-dashed border-white/20 bg-black/30 text-white rounded-none"})]}),n.jsx(T,{onClick:()=>{var Y;const P=parseInt(((Y=document.getElementById("member-count"))==null?void 0:Y.value)||"5");Nn(P)},disabled:R,className:"bg-white hover:bg-white/90 text-black border border-white/20 rounded-none mt-6 disabled:opacity-50",children:R?n.jsxs(n.Fragment,{children:[n.jsx(ut,{className:"w-3 h-3 mr-2 animate-spin"}),"Seeding..."]}):n.jsxs(n.Fragment,{children:[n.jsx(xe,{className:"w-3 h-3 mr-2"}),"Seed Members"]})})]})]}),M.length>0&&n.jsx("div",{className:"mt-6",children:n.jsx(fa,{title:"Member Seeding Terminal",lines:M,isRunning:R,className:"w-full",defaultCollapsed:!0})})]}),n.jsx("div",{className:"flex justify-end mt-6 pt-6 border-t border-dashed border-white/10",children:n.jsx(T,{variant:"outline",onClick:()=>g(!1),className:"border border-dashed border-white/20 text-white hover:bg-white/10 rounded-none",children:"Close"})})]})}),j&&n.jsx("div",{className:"fixed inset-0 bg-black/50 flex items-center justify-center z-50",children:n.jsxs("div",{className:"bg-black/90 border border-dashed border-white/20 p-6 w-full max-w-2xl rounded-none",children:[n.jsxs("div",{className:"flex items-center justify-between mb-6",children:[n.jsx("h3",{className:"text-lg text-white font-light",children:"Seed Teams"}),n.jsx(T,{variant:"ghost",size:"sm",onClick:()=>S(!1),className:"text-gray-400 hover:text-white rounded-none",children:n.jsx(we,{className:"w-4 h-4"})})]}),n.jsxs("div",{className:"space-y-6",children:[n.jsxs("div",{className:"space-y-4",children:[n.jsxs("div",{className:"flex items-center space-x-2",children:[n.jsx(We,{className:"w-5 h-5 text-white"}),n.jsx("h4",{className:"text-white font-light",children:"Create Teams"})]}),n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsxs("div",{className:"flex-1",children:[n.jsx(me,{htmlFor:"team-count",className:"text-sm text-gray-400 font-light",children:"Number of teams to create"}),n.jsx(ue,{id:"team-count",type:"number",min:"1",max:"20",defaultValue:"3",className:"mt-1 border border-dashed border-white/20 bg-black/30 text-white rounded-none"})]}),n.jsx(T,{onClick:()=>{var Y;const P=parseInt(((Y=document.getElementById("team-count"))==null?void 0:Y.value)||"3");Ye(P)},disabled:Ne,className:"bg-white hover:bg-white/90 text-black border border-white/20 rounded-none mt-6 disabled:opacity-50",children:Ne?n.jsxs(n.Fragment,{children:[n.jsx(ut,{className:"w-3 h-3 mr-2 animate-spin"}),"Seeding..."]}):n.jsxs(n.Fragment,{children:[n.jsx(We,{className:"w-3 h-3 mr-2"}),"Seed Teams"]})})]})]}),Q.length>0&&n.jsx("div",{className:"mt-6",children:n.jsx(fa,{title:"Team Seeding Terminal",lines:Q,isRunning:Ne,className:"w-full",defaultCollapsed:!0})})]}),n.jsx("div",{className:"flex justify-end mt-6 pt-6 border-t border-dashed border-white/10",children:n.jsx(T,{variant:"outline",onClick:()=>S(!1),className:"border border-dashed border-white/20 text-white hover:bg-white/10 rounded-none",children:"Close"})})]})})]}):n.jsxs("div",{className:"space-y-6 p-6",children:[n.jsx("div",{className:"flex items-center space-x-4",children:n.jsx(Xn,{to:"/organizations",children:n.jsxs(T,{variant:"ghost",className:"text-gray-400 hover:text-white rounded-none",children:[n.jsx(Ii,{className:"w-4 h-4 mr-2"}),"Back to Organizations"]})})}),n.jsx("br",{}),n.jsxs("div",{className:"text-center py-12",children:[n.jsx(We,{className:"w-16 h-16 text-gray-400 mx-auto mb-4"}),n.jsx("h2",{className:"text-xl text-white font-light mb-2",children:"Organization Not Found"}),n.jsx("p",{className:"text-gray-400",children:"The organization you're looking for doesn't exist."})]})]})}function Eb(){var ee,ie;const{teamId:e}=xm(),[t,r]=h.useState(null),[s,a]=h.useState([]),[i,l]=h.useState(!0),[o,c]=h.useState("details"),[d,f]=h.useState(!1),[u,x]=h.useState(!1),[y,w]=h.useState(""),[v,b]=h.useState([]),[m,p]=h.useState([]),[g,j]=h.useState({name:""});h.useEffect(()=>{e&&(S(),N())},[e]);const S=async()=>{try{const H=await(await fetch(`/api/teams/${e}`)).json();H.success?(r(H.team),j({name:H.team.name})):I.error("Team not found")}catch(D){console.error("Failed to fetch team:",D),I.error("Failed to load team")}finally{l(!1)}},N=async()=>{try{const H=await(await fetch(`/api/teams/${e}/members`)).json();H.success&&a(H.members||[])}catch(D){console.error("Failed to fetch team members:",D),I.error("Failed to load team members")}},C=async()=>{try{const H=await(await fetch("/api/users?limit=10000")).json(),k=s.map(_=>_.userId),A=(H.users||[]).filter(_=>!k.includes(_.id));b(A)}catch(D){console.error("Failed to fetch available users:",D),I.error("Failed to load users")}},O=async()=>{if(!g.name){I.error("Please enter a team name");return}const D=I.loading("Updating team...");try{const k=await(await fetch(`/api/teams/${e}`,{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({name:g.name})})).json();k.success?(await S(),x(!1),I.success("Team updated successfully!",{id:D})):I.error(`Error updating team: ${k.error||"Unknown error"}`,{id:D})}catch(H){console.error("Error updating team:",H),I.error("Error updating team",{id:D})}},G=async()=>{if(m.length===0){I.error("Please select at least one user");return}const D=I.loading(`Adding ${m.length} members...`);try{const k=await(await fetch(`/api/teams/${e}/members`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({userIds:m})})).json();k.success?(await N(),f(!1),p([]),w(""),I.success(`Successfully added ${m.length} members!`,{id:D})):I.error(`Error adding members: ${k.error||"Unknown error"}`,{id:D})}catch(H){console.error("Error adding members:",H),I.error("Error adding members",{id:D})}},V=async(D,H)=>{const k=I.loading(`Removing ${H}...`);try{const _=await(await fetch(`/api/team-members/${D}`,{method:"DELETE",headers:{"Content-Type":"application/json"}})).json();_.success?(await N(),I.success(`${H} removed from team!`,{id:k})):I.error(`Error removing member: ${_.error||"Unknown error"}`,{id:k})}catch(A){console.error("Error removing team member:",A),I.error("Error removing team member",{id:k})}},J=()=>{C(),f(!0)},B=D=>{p(H=>H.includes(D)?H.filter(k=>k!==D):[...H,D])},se=v.filter(D=>D.name.toLowerCase().includes(y.toLowerCase())||D.email.toLowerCase().includes(y.toLowerCase()));return i?n.jsx("div",{className:"flex items-center justify-center h-32",children:n.jsxs("div",{className:"flex flex-col items-center space-y-3",children:[n.jsx(ut,{className:"w-6 h-6 text-white animate-spin"}),n.jsx("div",{className:"text-white text-sm",children:"Loading team details..."})]})}):t?n.jsxs("div",{className:"space-y-6 p-6",children:[n.jsxs("div",{className:"flex items-center justify-between",children:[n.jsx("div",{className:"flex items-center space-x-4",children:n.jsx(Xn,{to:`/organizations/${t.organizationId}`,children:n.jsxs(T,{variant:"ghost",className:"text-gray-400 hover:text-white rounded-none",children:[n.jsx(Ii,{className:"w-4 h-4 mr-2"}),"Back to Organization"]})})}),n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsxs(T,{onClick:J,className:"border border-dashed border-white/20 text-white hover:bg-white/10 bg-transparent rounded-none",children:[n.jsx(Br,{className:"w-4 h-4 mr-2"}),"Add Members"]}),n.jsxs(T,{onClick:()=>x(!0),className:"bg-white hover:bg-white/90 text-black border border-white/20 rounded-none",children:[n.jsx(ls,{className:"w-4 h-4 mr-2"}),"Edit Team"]})]})]}),n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx("div",{className:"w-12 h-12 bg-white/10 border border-dashed border-white/20 rounded-none flex items-center justify-center",children:n.jsx(xe,{className:"w-6 h-6 text-white"})}),n.jsxs("div",{children:[n.jsx("h1",{className:"text-2xl text-white font-light",children:t.name}),n.jsx("div",{className:"flex items-center space-x-2",children:t.organization&&n.jsxs(Xn,{to:`/organizations/${t.organizationId}`,className:"text-gray-400 hover:text-white text-sm",children:[n.jsx(We,{className:"w-4 h-4 inline mr-1"}),t.organization.name]})})]})]}),n.jsx("div",{className:"border-b border-white/10",children:n.jsxs("nav",{className:"flex space-x-8",children:[n.jsxs("button",{onClick:()=>c("details"),className:`flex items-center space-x-2 px-3 py-4 text-sm font-medium border-b-2 transition-all duration-200 ${o==="details"?"border-white text-white":"border-transparent text-gray-400 hover:text-white hover:border-gray-300"}`,children:[n.jsx(xe,{className:"w-4 h-4"}),n.jsx("span",{children:"Details"})]}),n.jsxs("button",{onClick:()=>c("members"),className:`flex items-center space-x-2 px-3 py-4 text-sm font-medium border-b-2 transition-all duration-200 ${o==="members"?"border-white text-white":"border-transparent text-gray-400 hover:text-white hover:border-gray-300"}`,children:[n.jsx(xe,{className:"w-4 h-4"}),n.jsx("span",{children:"Members"}),s.length>0&&n.jsx(oe,{variant:"secondary",className:"text-xs bg-white/10 border border-white/20 rounded-sm",children:s.length})]})]})}),o==="details"&&n.jsxs("div",{className:"space-y-6",children:[n.jsxs("div",{className:"bg-black/30 border border-dashed border-white/20 rounded-none p-6",children:[n.jsx("h3",{className:"text-lg text-white font-light mb-4",children:"Team Information"}),n.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-6",children:[n.jsxs("div",{children:[n.jsx("label",{className:"text-sm text-gray-400 font-light",children:"Name"}),n.jsx("p",{className:"text-white mt-1",children:t.name})]}),n.jsxs("div",{children:[n.jsx("label",{className:"text-sm text-gray-400 font-light",children:"Organization"}),n.jsx("p",{className:"text-white mt-1",children:((ee=t.organization)==null?void 0:ee.name)||"Unknown"})]}),n.jsxs("div",{children:[n.jsx("label",{className:"text-sm text-gray-400 font-light",children:"Created"}),n.jsx("p",{className:"text-white mt-1",children:new Date(t.createdAt).toLocaleDateString("en-US",{year:"numeric",month:"long",day:"numeric"})})]}),n.jsxs("div",{children:[n.jsx("label",{className:"text-sm text-gray-400 font-light",children:"Last Updated"}),n.jsx("p",{className:"text-white mt-1",children:new Date(t.updatedAt).toLocaleDateString("en-US",{year:"numeric",month:"long",day:"numeric"})})]})]})]}),n.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-3 gap-6",children:[n.jsx("div",{className:"bg-black/30 border border-dashed border-white/20 rounded-none p-6",children:n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx(xe,{className:"w-8 h-8 text-white"}),n.jsxs("div",{children:[n.jsx("p",{className:"text-2xl text-white font-light",children:s.length}),n.jsx("p",{className:"text-sm text-gray-400",children:"Members"})]})]})}),n.jsx("div",{className:"bg-black/30 border border-dashed border-white/20 rounded-none p-6",children:n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx(bm,{className:"w-8 h-8 text-white"}),n.jsxs("div",{children:[n.jsx("p",{className:"text-2xl text-white font-light",children:Math.ceil((new Date().getTime()-new Date(t.createdAt).getTime())/(1e3*60*60*24))}),n.jsx("p",{className:"text-sm text-gray-400",children:"Days Active"})]})]})}),n.jsx("div",{className:"bg-black/30 border border-dashed border-white/20 rounded-none p-6",children:n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx(We,{className:"w-8 h-8 text-white"}),n.jsxs("div",{children:[n.jsx("p",{className:"text-2xl text-white font-light",children:"1"}),n.jsx("p",{className:"text-sm text-gray-400",children:"Organization"})]})]})})]})]}),o==="members"&&n.jsxs("div",{className:"space-y-6",children:[n.jsx("div",{className:"flex items-center justify-between",children:n.jsxs("div",{children:[n.jsxs("h3",{className:"text-lg text-white font-light",children:["Team Members (",s.length,")"]}),n.jsx("p",{className:"text-gray-400 mt-1",children:"Manage members of this team"})]})}),s.length>0?n.jsx("div",{className:"bg-black/30 border border-dashed border-white/20 rounded-none",children:n.jsx("div",{className:"overflow-x-auto",children:n.jsxs("table",{className:"w-full",children:[n.jsx("thead",{children:n.jsxs("tr",{className:"border-b border-dashed border-white/10",children:[n.jsx("th",{className:"text-left py-4 px-4 text-white font-light",children:"User"}),n.jsx("th",{className:"text-left py-4 px-4 text-white font-light",children:"Email"}),n.jsx("th",{className:"text-left py-4 px-4 text-white font-light",children:"Role"}),n.jsx("th",{className:"text-left py-4 px-4 text-white font-light",children:"Joined"}),n.jsx("th",{className:"text-right py-4 px-4 text-white font-light",children:"Actions"})]})}),n.jsx("tbody",{children:s.map(D=>n.jsxs("tr",{className:"border-b border-dashed border-white/5 hover:bg-white/5",children:[n.jsx("td",{className:"py-4 px-4",children:n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx("img",{src:D.user.image||`https://api.dicebear.com/7.x/avataaars/svg?seed=${D.user.id}`,alt:D.user.name,className:"w-10 h-10 rounded-none border border-dashed border-white/20"}),n.jsxs("div",{children:[n.jsx("div",{className:"text-white font-light",children:D.user.name}),n.jsxs("div",{className:"text-sm text-gray-400",children:["ID: ",D.user.id]})]})]})}),n.jsx("td",{className:"py-4 px-4 text-white",children:D.user.email}),n.jsx("td",{className:"py-4 px-4",children:n.jsx(oe,{variant:"secondary",className:"text-xs bg-blue-900/10 border border-dashed border-blue-500/30 text-blue-400/70 rounded-none capitalize",children:D.role})}),n.jsx("td",{className:"py-4 px-4 text-sm text-gray-400",children:new Date(D.joinedAt).toLocaleDateString()}),n.jsx("td",{className:"py-4 px-4 text-right",children:n.jsx("div",{className:"flex items-center justify-end space-x-2",children:n.jsxs(T,{variant:"outline",size:"sm",className:"border border-dashed border-red-400/50 text-red-400 hover:bg-red-400/10 rounded-none",onClick:()=>V(D.id,D.user.name),children:[n.jsx(cn,{className:"w-4 h-4 mr-1"}),"Remove"]})})})]},D.id))})]})})}):n.jsx("div",{className:"bg-black/30 border border-dashed border-white/20 rounded-none p-12",children:n.jsxs("div",{className:"text-center",children:[n.jsx(xe,{className:"w-16 h-16 text-gray-400 mx-auto mb-4"}),n.jsx("h3",{className:"text-xl text-white font-light mb-2",children:"No Members Yet"}),n.jsx("p",{className:"text-gray-400 mb-6",children:"Add members to this team to get started."}),n.jsxs(T,{onClick:J,className:"bg-white hover:bg-white/90 text-black border border-white/20 rounded-none",children:[n.jsx(Br,{className:"w-4 h-4 mr-2"}),"Add First Members"]})]})})]}),d&&n.jsx("div",{className:"fixed inset-0 bg-black/50 flex items-center justify-center z-50",children:n.jsxs("div",{className:"bg-black/90 border border-dashed border-white/20 p-6 w-full max-w-2xl rounded-none",children:[n.jsxs("div",{className:"flex items-center justify-between mb-6",children:[n.jsx("h3",{className:"text-lg text-white font-light",children:"Add Team Members"}),n.jsx(T,{variant:"ghost",size:"sm",onClick:()=>{f(!1),p([]),w("")},className:"text-gray-400 hover:text-white rounded-none",children:n.jsx(we,{className:"w-4 h-4"})})]}),n.jsxs("div",{className:"space-y-4",children:[n.jsxs("div",{className:"relative",children:[n.jsx(pn,{className:"absolute left-3 top-1/2 transform -translate-y-1/2 text-gray-400 w-4 h-4"}),n.jsx(ue,{placeholder:"Search users by name or email...",value:y,onChange:D=>w(D.target.value),className:"pl-10 border border-dashed border-white/20 bg-black/30 text-white rounded-none"})]}),m.length>0&&n.jsx("div",{className:"bg-blue-900/20 border border-blue-500/30 rounded-none p-3",children:n.jsxs("p",{className:"text-blue-400 text-sm",children:[m.length," user",m.length!==1?"s":""," selected"]})}),n.jsx("div",{className:"bg-black/30 border border-dashed border-white/20 rounded-none max-h-96 overflow-y-auto",children:se.length>0?n.jsx("div",{className:"divide-y divide-white/5",children:se.map(D=>n.jsxs("div",{className:`flex items-center space-x-3 p-4 cursor-pointer hover:bg-white/5 ${m.includes(D.id)?"bg-blue-900/20":""}`,onClick:()=>B(D.id),children:[n.jsx("input",{type:"checkbox",checked:m.includes(D.id),onChange:()=>B(D.id),className:"rounded border-gray-300"}),n.jsx("img",{src:D.image||`https://api.dicebear.com/7.x/avataaars/svg?seed=${D.id}`,alt:D.name,className:"w-10 h-10 rounded-none border border-dashed border-white/20"}),n.jsxs("div",{className:"flex-1",children:[n.jsx("div",{className:"text-white font-light",children:D.name}),n.jsx("div",{className:"text-sm text-gray-400",children:D.email})]})]},D.id))}):n.jsx("div",{className:"p-8 text-center",children:n.jsx("p",{className:"text-gray-400",children:"No users found matching your search."})})})]}),n.jsxs("div",{className:"flex justify-end space-x-3 mt-6",children:[n.jsx(T,{variant:"outline",onClick:()=>{f(!1),p([]),w("")},className:"border border-dashed border-white/20 text-white hover:bg-white/10 rounded-none",children:"Cancel"}),n.jsxs(T,{onClick:G,disabled:m.length===0,className:"bg-white hover:bg-white/90 text-black border border-white/20 rounded-none disabled:opacity-50",children:[n.jsx(Br,{className:"w-4 h-4 mr-2"}),"Add ",m.length," Member",m.length!==1?"s":""]})]})]})}),u&&n.jsx("div",{className:"fixed inset-0 bg-black/50 flex items-center justify-center z-50",children:n.jsxs("div",{className:"bg-black/90 border border-dashed border-white/20 p-6 w-full max-w-md rounded-none",children:[n.jsxs("div",{className:"flex items-center justify-between mb-4",children:[n.jsx("h3",{className:"text-lg text-white font-light",children:"Edit Team"}),n.jsx(T,{variant:"ghost",size:"sm",onClick:()=>x(!1),className:"text-gray-400 hover:text-white rounded-none",children:n.jsx(we,{className:"w-4 h-4"})})]}),n.jsxs("div",{className:"space-y-4",children:[n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx("div",{className:"w-16 h-16 bg-white/10 border border-dashed border-white/20 rounded-none flex items-center justify-center",children:n.jsx(xe,{className:"w-8 h-8 text-white"})}),n.jsxs("div",{children:[n.jsx("div",{className:"text-white font-light",children:t.name}),n.jsx("div",{className:"text-sm text-gray-400",children:(ie=t.organization)==null?void 0:ie.name})]})]}),n.jsxs("div",{children:[n.jsx(me,{htmlFor:"edit-team-name",className:"text-sm text-gray-400 font-light",children:"Team Name"}),n.jsx(ue,{id:"edit-team-name",value:g.name,onChange:D=>j({name:D.target.value}),placeholder:"e.g. Development Team",className:"mt-1 border border-dashed border-white/20 bg-black/30 text-white rounded-none"})]})]}),n.jsxs("div",{className:"flex justify-end space-x-3 mt-6",children:[n.jsx(T,{variant:"outline",onClick:()=>x(!1),className:"border border-dashed border-white/20 text-white hover:bg-white/10 rounded-none",children:"Cancel"}),n.jsx(T,{onClick:O,className:"bg-white hover:bg-white/90 text-black border border-white/20 rounded-none",children:"Update Team"})]})]})})]}):n.jsxs("div",{className:"space-y-6 p-6",children:[n.jsx("div",{className:"flex items-center space-x-4",children:n.jsx(Xn,{to:"/organizations",children:n.jsxs(T,{variant:"ghost",className:"text-gray-400 hover:text-white rounded-none",children:[n.jsx(Ii,{className:"w-4 h-4 mr-2"}),"Back to Organizations"]})})}),n.jsxs("div",{className:"text-center py-12",children:[n.jsx(xe,{className:"w-16 h-16 text-gray-400 mx-auto mb-4"}),n.jsx("h2",{className:"text-xl text-white font-light mb-2",children:"Team Not Found"}),n.jsx("p",{className:"text-gray-400",children:"The team you're looking for doesn't exist."})]})]})}function Tb(){var y,w,v,b,m,p,g,j,S,N,C,O,G,V,J,B,se,ee,ie,D,H,k,A,_,W,E,z;const[e,t]=h.useState(null),[r,s]=h.useState(null),[a,i]=h.useState(null),[l,o]=h.useState(!0);h.useEffect(()=>{c(),d(),f()},[]);const c=async()=>{try{const L=await(await fetch("/api/config")).json();console.log("Config data:",L),t(L)}catch(M){console.error("Failed to fetch config:",M)}finally{o(!1)}},d=async()=>{try{const L=await(await fetch("/api/health")).json();s(L.system||{studioVersion:"v1.0.0",nodeVersion:process.version,platform:navigator.platform,uptime:"2h 15m"})}catch(M){console.error("Failed to fetch system info:",M),s({studioVersion:"v1.0.0",nodeVersion:"v18.0.0",platform:"macOS",uptime:"2h 15m"})}},f=async()=>{try{const L=await(await fetch("/api/plugins")).json();i(L)}catch(M){console.error("Failed to fetch plugins:",M),i({plugins:[],configPath:null,totalPlugins:0,error:"Failed to fetch plugins"})}},u=M=>{switch(M==null?void 0:M.toLowerCase()){case"postgresql":case"postgres":return n.jsxs(oe,{variant:"secondary",className:"text-xs group-hover:bg-white group-hover:border-black group-hover:text-black bg-black/70 border border-white/15 rounded-none border-dashed flex items-center gap-1",children:[n.jsx(Ie,{className:"w-3 h-3"}),"Connected"]});case"mysql":return n.jsxs(oe,{variant:"secondary",className:"text-xs group-hover:bg-white group-hover:border-black group-hover:text-black bg-black/70 border border-white/15 rounded-none border-dashed flex items-center gap-1",children:[n.jsx(Ie,{className:"w-3 h-3"}),"Connected"]});case"sqlite":return n.jsxs(oe,{variant:"secondary",className:"text-xs group-hover:bg-white group-hover:border-black group-hover:text-black bg-black/70 border border-white/15 rounded-none border-dashed flex items-center gap-1",children:[n.jsx(Es,{className:"w-3 h-3"}),"Local"]});default:return n.jsxs(oe,{variant:"secondary",className:"text-xs group-hover:bg-white group-hover:border-black group-hover:text-black bg-black/70 border border-white/15 rounded-none border-dashed flex items-center gap-1",children:[n.jsx(ar,{className:"w-3 h-3"}),"Unknown"]})}},x=M=>{switch(M.toLowerCase()){case"google":return n.jsx(Sn,{className:"w-5 h-5 text-white"});case"github":return n.jsx(ir,{className:"w-5 h-5 text-white"});case"discord":return n.jsx(Sn,{className:"w-5 h-5 text-white"});case"twitter":return n.jsx(Sn,{className:"w-5 h-5 text-white"});default:return n.jsx(Sn,{className:"w-5 h-5 text-white"})}};return l?n.jsx("div",{className:"flex items-center justify-center h-64",children:n.jsx("div",{className:"animate-spin rounded-full h-8 w-8 border-b-2 border-white"})}):n.jsxs("div",{className:"space-y-8 animate-fade-in",children:[n.jsx("div",{className:"flex items-center justify-between p-5 pt-7",children:n.jsxs("div",{children:[n.jsx("h1",{className:"text-3xl font-normal text-white tracking-tight",children:"Settings"}),n.jsx("p",{className:"text-gray-300 mt-2",children:"Configure your Better Auth application"})]})}),n.jsx("hr",{className:"w-full border-white/15 h-px"}),n.jsx("hr",{className:"w-full border-white/15 h-px"}),n.jsxs("div",{className:"grid grid-cols-1 lg:grid-cols-2 gap-8 p-5",children:[n.jsxs(Ze,{className:"border-white/15 bg-black/70 px-0 sm:px-0 md:px-0 lg:px-0 xl:px-0 rounded-none",children:[n.jsxs(Yt,{children:[n.jsxs(Gt,{className:"text-white flex items-center space-x-2",children:[n.jsx(Jn,{className:"w-5 h-5 text-white"}),n.jsx("span",{children:"Application"})]}),n.jsx(Xt,{children:"Basic application configuration"})]}),n.jsx("hr",{className:"w-full border-white/15 h-px -mt-3 mb-1"}),n.jsxs(qe,{className:"space-y-0 px-0 pb-0 border-b-none",children:[n.jsxs("div",{className:"flex items-center justify-between p-4 px-5 border-b border-white/15",children:[n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx(Sn,{className:"w-5 h-5 text-white"}),n.jsxs("div",{children:[n.jsx("p",{className:"text-sm font-medium text-white",children:"App Name"}),n.jsx("p",{className:"text-xs text-gray-400",children:"Application display name"})]})]}),n.jsx("div",{className:"text-right",children:n.jsx("p",{className:"text-sm font-medium text-white",children:(e==null?void 0:e.appName)||"Better Auth"})})]}),n.jsxs("div",{className:"flex items-center justify-between p-4 px-5 border-b border-white/15",children:[n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx(E0,{className:"w-5 h-5 text-white"}),n.jsxs("div",{children:[n.jsx("p",{className:"text-sm font-medium text-white",children:"Base URL"}),n.jsx("p",{className:"text-xs text-gray-400",children:"Application base URL"})]})]}),n.jsx("div",{className:"text-right",children:n.jsx("p",{className:"text-sm font-mono font-medium text-white",children:(e==null?void 0:e.baseURL)||"http://localhost:3000"})})]}),n.jsxs("div",{className:"flex items-center justify-between p-4 px-5 border-b border-white/15",children:[n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx(Rl,{className:"w-5 h-5 text-white"}),n.jsxs("div",{children:[n.jsx("p",{className:"text-sm font-medium text-white",children:"Base Path"}),n.jsx("p",{className:"text-xs text-gray-400",children:"Auth API base path"})]})]}),n.jsx("div",{className:"text-right",children:n.jsx("p",{className:"text-sm font-mono font-medium text-white",children:(e==null?void 0:e.basePath)||"/api/auth"})})]}),n.jsxs("div",{className:"flex items-center justify-between p-4 px-5 border-b border-white/15",children:[n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx(ir,{className:"w-5 h-5 text-white"}),n.jsxs("div",{children:[n.jsx("p",{className:"text-sm font-medium text-white",children:"Secret"}),n.jsx("p",{className:"text-xs text-gray-400",children:"Encryption secret"})]})]}),n.jsx("div",{className:"text-right",children:n.jsx("p",{className:"text-sm font-medium text-white",children:e!=null&&e.secret?"Configured":"Not set"})})]})]})]}),n.jsxs(Ze,{className:"border-white/15 bg-black/70 px-0 sm:px-0 md:px-0 lg:px-0 xl:px-0 rounded-none",children:[n.jsxs(Yt,{children:[n.jsxs(Gt,{className:"text-white flex items-center space-x-2",children:[n.jsx(ze,{className:"w-5 h-5 text-white"}),n.jsx("span",{children:"Database"})]}),n.jsx(Xt,{children:"Database connection and configuration"})]}),n.jsx("hr",{className:"w-full border-white/15 h-px -mt-3 mb-1"}),n.jsxs(qe,{className:"space-y-0 px-0 pb-0 border-b-none",children:[n.jsxs("div",{className:"flex items-center justify-between p-4 px-5 border-b border-white/15",children:[n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx(ze,{className:"w-5 h-5 text-white"}),n.jsxs("div",{children:[n.jsx("p",{className:"text-sm font-medium text-white",children:((y=e==null?void 0:e.database)==null?void 0:y.type)&&((w=e==null?void 0:e.database)==null?void 0:w.type.charAt(0).toUpperCase())+((v=e==null?void 0:e.database)==null?void 0:v.type.slice(1))||"Unknown"}),n.jsx("p",{className:"text-xs text-gray-400",children:"Database Type"})]})]}),((b=e==null?void 0:e.database)==null?void 0:b.type)&&u(e.database.type)]}),((m=e==null?void 0:e.database)==null?void 0:m.dialect)&&n.jsxs("div",{className:"flex items-center justify-between p-4 px-5 border-b border-white/15",children:[n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx(ze,{className:"w-5 h-5 text-white"}),n.jsxs("div",{children:[n.jsx("p",{className:"text-sm font-medium text-white",children:"Dialect"}),n.jsx("p",{className:"text-xs text-gray-400",children:"Database dialect"})]})]}),n.jsx("div",{className:"text-right",children:n.jsx("p",{className:"text-sm font-medium text-white",children:e.database.dialect})})]}),((p=e==null?void 0:e.database)==null?void 0:p.casing)&&n.jsxs("div",{className:"flex items-center justify-between p-4 px-5 border-b border-white/15",children:[n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx(Jn,{className:"w-5 h-5 text-white"}),n.jsxs("div",{children:[n.jsx("p",{className:"text-sm font-medium text-white",children:"Casing"}),n.jsx("p",{className:"text-xs text-gray-400",children:"Table name casing"})]})]}),n.jsx("div",{className:"text-right",children:n.jsx("p",{className:"text-sm font-medium text-white capitalize",children:e.database.casing})})]}),n.jsxs("div",{className:"flex items-center justify-between p-4 px-5 border-b border-white/15",children:[n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx(ku,{className:"w-5 h-5 text-white"}),n.jsxs("div",{children:[n.jsx("p",{className:"text-sm font-medium text-white",children:"Debug Logs"}),n.jsx("p",{className:"text-xs text-gray-400",children:"Database debug logging"})]})]}),n.jsx(oe,{variant:"secondary",className:"text-xs group-hover:bg-white group-hover:border-black group-hover:text-black bg-black/70 border border-white/15 rounded-none border-dashed flex items-center gap-1",children:(g=e==null?void 0:e.database)!=null&&g.debugLogs?n.jsxs(n.Fragment,{children:[n.jsx(ar,{className:"w-3 h-3"}),"Enabled"]}):n.jsxs(n.Fragment,{children:[n.jsx(Ie,{className:"w-3 h-3"}),"Disabled"]})})]})]})]}),n.jsxs(Ze,{className:"border-white/15 bg-black rounded-none",children:[n.jsxs(Yt,{className:"border-b border-white/15",children:[n.jsxs(Gt,{className:"text-white flex items-center space-x-2",children:[n.jsx(ir,{className:"w-5 h-5 text-white"}),n.jsx("span",{children:"Providers"})]}),n.jsx(Xt,{children:"Configured authentication providers"})]}),n.jsx(qe,{className:"p-0",children:e!=null&&e.socialProviders&&e.socialProviders.length>0?e.socialProviders.map((M,L)=>n.jsxs("div",{className:"flex items-center justify-between p-4 px-5 border-b border-white/15 last:border-b-0",children:[n.jsxs("div",{className:"flex items-center space-x-3",children:[x(M.type),n.jsxs("div",{children:[n.jsx("p",{className:"text-sm font-medium text-white capitalize",children:M.type}),n.jsx("p",{className:"text-xs text-gray-400",children:M.clientId?"Configured":"Not configured"})]})]}),n.jsx(oe,{variant:"secondary",className:"text-xs group-hover:bg-white group-hover:border-black group-hover:text-black bg-black/70 border border-white/15 rounded-none border-dashed flex items-center gap-1",children:M.clientId?n.jsxs(n.Fragment,{children:[n.jsx(Ie,{className:"w-3 h-3"}),"Active"]}):n.jsxs(n.Fragment,{children:[n.jsx(ar,{className:"w-3 h-3"}),"Setup Required"]})})]},L)):n.jsxs("div",{className:"text-center py-8",children:[n.jsx(ir,{className:"w-8 h-8 text-white mx-auto mb-2"}),n.jsx("p",{className:"text-sm text-gray-400",children:"No providers configured"})]})})]}),n.jsxs(Ze,{className:"border-white/15 bg-black rounded-none",children:[n.jsxs(Yt,{className:"border-b border-white/15",children:[n.jsxs(Gt,{className:"text-white flex items-center space-x-2",children:[n.jsx(_t,{className:"w-5 h-5 text-white"}),n.jsx("span",{children:"Email & Password"})]}),n.jsx(Xt,{children:"Email authentication settings"})]}),n.jsxs(qe,{className:"p-0",children:[n.jsxs("div",{className:"flex items-center justify-between p-4 px-5 border-b border-white/15",children:[n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx(_t,{className:"w-5 h-5 text-white"}),n.jsxs("div",{children:[n.jsx("p",{className:"text-sm font-medium text-white",children:"Email Authentication"}),n.jsx("p",{className:"text-xs text-gray-400",children:"Allow users to sign up with email"})]})]}),n.jsx(oe,{variant:"secondary",className:"text-xs group-hover:bg-white group-hover:border-black group-hover:text-black bg-black/70 border border-white/15 rounded-none border-dashed flex items-center gap-1",children:(j=e==null?void 0:e.emailAndPassword)!=null&&j.enabled?n.jsxs(n.Fragment,{children:[n.jsx(Ie,{className:"w-3 h-3"}),"Enabled"]}):n.jsxs(n.Fragment,{children:[n.jsx(rn,{className:"w-3 h-3"}),"Disabled"]})})]}),((S=e==null?void 0:e.emailAndPassword)==null?void 0:S.enabled)&&n.jsxs(n.Fragment,{children:[n.jsxs("div",{className:"flex items-center justify-between p-4 px-5 border-b border-white/15",children:[n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx(xe,{className:"w-5 h-5 text-white"}),n.jsxs("div",{children:[n.jsx("p",{className:"text-sm font-medium text-white",children:"Sign Up"}),n.jsx("p",{className:"text-xs text-gray-400",children:"Allow new user registration"})]})]}),n.jsx(oe,{variant:"secondary",className:"text-xs group-hover:bg-white group-hover:border-black group-hover:text-black bg-black/70 border border-white/15 rounded-none border-dashed flex items-center gap-1",children:(N=e==null?void 0:e.emailAndPassword)!=null&&N.disableSignUp?n.jsxs(n.Fragment,{children:[n.jsx(rn,{className:"w-3 h-3"}),"Disabled"]}):n.jsxs(n.Fragment,{children:[n.jsx(Ie,{className:"w-3 h-3"}),"Enabled"]})})]}),n.jsxs("div",{className:"flex items-center justify-between p-4 px-5 border-b border-white/15",children:[n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx(ir,{className:"w-5 h-5 text-white"}),n.jsxs("div",{children:[n.jsx("p",{className:"text-sm font-medium text-white",children:"Email Verification"}),n.jsx("p",{className:"text-xs text-gray-400",children:"Require email verification"})]})]}),n.jsx(oe,{variant:"secondary",className:"text-xs group-hover:bg-white group-hover:border-black group-hover:text-black bg-black/70 border border-white/15 rounded-none border-dashed flex items-center gap-1",children:(C=e==null?void 0:e.emailAndPassword)!=null&&C.requireEmailVerification?n.jsxs(n.Fragment,{children:[n.jsx(Ie,{className:"w-3 h-3"}),"Required"]}):n.jsxs(n.Fragment,{children:[n.jsx(ar,{className:"w-3 h-3"}),"Optional"]})})]}),n.jsxs("div",{className:"flex items-center justify-between p-4 px-5 border-b border-white/15",children:[n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx(Rl,{className:"w-5 h-5 text-white"}),n.jsxs("div",{children:[n.jsx("p",{className:"text-sm font-medium text-white",children:"Password Length"}),n.jsx("p",{className:"text-xs text-gray-400",children:"Min/Max password length"})]})]}),n.jsx("div",{className:"text-right",children:n.jsxs("p",{className:"text-sm font-medium text-white",children:[((O=e==null?void 0:e.emailAndPassword)==null?void 0:O.minPasswordLength)||8," -"," ",((G=e==null?void 0:e.emailAndPassword)==null?void 0:G.maxPasswordLength)||128]})})]}),n.jsxs("div",{className:"flex items-center justify-between p-4 px-5 border-b border-white/15 last:border-b-0",children:[n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx(ii,{className:"w-5 h-5 text-white"}),n.jsxs("div",{children:[n.jsx("p",{className:"text-sm font-medium text-white",children:"Auto Sign In"}),n.jsx("p",{className:"text-xs text-gray-400",children:"Auto sign in after registration"})]})]}),n.jsx(oe,{variant:"secondary",className:"text-xs group-hover:bg-white group-hover:border-black group-hover:text-black bg-black/70 border border-white/15 rounded-none border-dashed flex items-center gap-1",children:(V=e==null?void 0:e.emailAndPassword)!=null&&V.autoSignIn?n.jsxs(n.Fragment,{children:[n.jsx(Ie,{className:"w-3 h-3"}),"Enabled"]}):n.jsxs(n.Fragment,{children:[n.jsx(ar,{className:"w-3 h-3"}),"Disabled"]})})]})]})]})]}),n.jsxs(Ze,{className:"border-white/15 bg-black rounded-none",children:[n.jsxs(Yt,{className:"border-b border-white/15",children:[n.jsxs(Gt,{className:"text-white flex items-center space-x-2",children:[n.jsx(_s,{className:"w-5 h-5 text-white"}),n.jsx("span",{children:"Session"})]}),n.jsx(Xt,{children:"Session management settings"})]}),n.jsxs(qe,{className:"p-0",children:[n.jsxs("div",{className:"flex items-center justify-between p-4 px-5 border-b border-white/15",children:[n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx(_s,{className:"w-5 h-5 text-white"}),n.jsxs("div",{children:[n.jsx("p",{className:"text-sm font-medium text-white",children:"Session Duration"}),n.jsx("p",{className:"text-xs text-gray-400",children:"How long sessions last"})]})]}),n.jsxs("div",{className:"text-right",children:[n.jsx("p",{className:"text-sm font-medium text-white",children:(J=e==null?void 0:e.session)!=null&&J.expiresIn?`${Math.floor(e.session.expiresIn/(60*60*24))} days`:"7 days"}),n.jsx("p",{className:"text-xs text-gray-400",children:"Default"})]})]}),n.jsxs("div",{className:"flex items-center justify-between p-4 px-5 border-b border-white/15",children:[n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx(ku,{className:"w-5 h-5 text-white"}),n.jsxs("div",{children:[n.jsx("p",{className:"text-sm font-medium text-white",children:"Update Age"}),n.jsx("p",{className:"text-xs text-gray-400",children:"Session refresh interval"})]})]}),n.jsx("div",{className:"text-right",children:n.jsx("p",{className:"text-sm font-medium text-white",children:(B=e==null?void 0:e.session)!=null&&B.updateAge?`${Math.floor(e.session.updateAge/(60*60))} hours`:"24 hours"})})]}),n.jsxs("div",{className:"flex items-center justify-between p-4 px-5 border-b border-white/15",children:[n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx(ii,{className:"w-5 h-5 text-white"}),n.jsxs("div",{children:[n.jsx("p",{className:"text-sm font-medium text-white",children:"Session Refresh"}),n.jsx("p",{className:"text-xs text-gray-400",children:"Auto refresh sessions"})]})]}),n.jsx(oe,{variant:"secondary",className:"text-xs group-hover:bg-white group-hover:border-black group-hover:text-black bg-black/70 border border-white/15 rounded-none border-dashed flex items-center gap-1",children:(se=e==null?void 0:e.session)!=null&&se.disableSessionRefresh?n.jsxs(n.Fragment,{children:[n.jsx(rn,{className:"w-3 h-3"}),"Disabled"]}):n.jsxs(n.Fragment,{children:[n.jsx(Ie,{className:"w-3 h-3"}),"Enabled"]})})]}),n.jsxs("div",{className:"flex items-center justify-between p-4 px-5 border-b border-white/15 last:border-b-0",children:[n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx(ze,{className:"w-5 h-5 text-white"}),n.jsxs("div",{children:[n.jsx("p",{className:"text-sm font-medium text-white",children:"Store in Database"}),n.jsx("p",{className:"text-xs text-gray-400",children:"Store sessions in database"})]})]}),n.jsx(oe,{variant:"secondary",className:"text-xs group-hover:bg-white group-hover:border-black group-hover:text-black bg-black/70 border border-white/15 rounded-none border-dashed flex items-center gap-1",children:(ee=e==null?void 0:e.session)!=null&&ee.storeSessionInDatabase?n.jsxs(n.Fragment,{children:[n.jsx(Ie,{className:"w-3 h-3"}),"Enabled"]}):n.jsxs(n.Fragment,{children:[n.jsx(Es,{className:"w-3 h-3"}),"Secondary Storage"]})})]})]})]}),n.jsxs(Ze,{className:"border-white/15 bg-black rounded-none",children:[n.jsxs(Yt,{className:"border-b border-white/15",children:[n.jsxs(Gt,{className:"text-white flex items-center space-x-2",children:[n.jsx(ir,{className:"w-5 h-5 text-white"}),n.jsx("span",{children:"Rate Limiting"})]}),n.jsx(Xt,{children:"API rate limiting configuration"})]}),n.jsxs(qe,{className:"p-0",children:[n.jsxs("div",{className:"flex items-center justify-between p-4 px-5 border-b border-white/15",children:[n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx(ir,{className:"w-5 h-5 text-white"}),n.jsxs("div",{children:[n.jsx("p",{className:"text-sm font-medium text-white",children:"Rate Limiting"}),n.jsx("p",{className:"text-xs text-gray-400",children:"Enable rate limiting"})]})]}),n.jsx(oe,{variant:"secondary",className:"text-xs group-hover:bg-white group-hover:border-black group-hover:text-black bg-black/70 border border-white/15 rounded-none border-dashed flex items-center gap-1",children:(ie=e==null?void 0:e.rateLimit)!=null&&ie.enabled?n.jsxs(n.Fragment,{children:[n.jsx(Ie,{className:"w-3 h-3"}),"Enabled"]}):n.jsxs(n.Fragment,{children:[n.jsx(ar,{className:"w-3 h-3"}),"Disabled"]})})]}),n.jsxs("div",{className:"flex items-center justify-between p-4 px-5 border-b border-white/15",children:[n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx(_s,{className:"w-5 h-5 text-red-400"}),n.jsxs("div",{children:[n.jsx("p",{className:"text-sm font-medium text-white",children:"Rate Limit Window"}),n.jsx("p",{className:"text-xs text-gray-400",children:"Time window for rate limiting"})]})]}),n.jsxs("div",{className:"text-right",children:[n.jsx("p",{className:"text-sm font-medium text-white",children:(D=e==null?void 0:e.rateLimit)!=null&&D.window?`${e.rateLimit.window} seconds`:"10 seconds"}),n.jsx("p",{className:"text-xs text-gray-400",children:"Window"})]})]}),n.jsxs("div",{className:"flex items-center justify-between p-4 px-5 border-b border-white/15",children:[n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx(ir,{className:"w-5 h-5 text-white"}),n.jsxs("div",{children:[n.jsx("p",{className:"text-sm font-medium text-white",children:"Max Requests"}),n.jsx("p",{className:"text-xs text-gray-400",children:"Maximum requests per window"})]})]}),n.jsxs("div",{className:"text-right",children:[n.jsx("p",{className:"text-sm font-medium text-white",children:((H=e==null?void 0:e.rateLimit)==null?void 0:H.max)||100}),n.jsx("p",{className:"text-xs text-gray-400",children:"Requests"})]})]}),n.jsxs("div",{className:"flex items-center justify-between p-4 px-5 border-b border-white/15 last:border-b-0",children:[n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx(ze,{className:"w-5 h-5 text-white"}),n.jsxs("div",{children:[n.jsx("p",{className:"text-sm font-medium text-white",children:"Storage"}),n.jsx("p",{className:"text-xs text-gray-400",children:"Rate limit storage type"})]})]}),n.jsx("div",{className:"text-right",children:n.jsx("p",{className:"text-sm font-medium text-white capitalize",children:((k=e==null?void 0:e.rateLimit)==null?void 0:k.storage)||"memory"})})]})]})]}),n.jsxs(Ze,{className:"border-white/15 bg-black rounded-none",children:[n.jsxs(Yt,{className:"border-b border-white/15",children:[n.jsxs(Gt,{className:"text-white flex items-center space-x-2",children:[n.jsx(Jn,{className:"w-5 h-5 text-white"}),n.jsx("span",{children:"Advanced"})]}),n.jsx(Xt,{children:"Advanced configuration options"})]}),n.jsxs(qe,{className:"p-0",children:[n.jsxs("div",{className:"flex items-center justify-between p-4 px-5 border-b border-white/15",children:[n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx(Rl,{className:"w-5 h-5 text-white"}),n.jsxs("div",{children:[n.jsx("p",{className:"text-sm font-medium text-white",children:"Secure Cookies"}),n.jsx("p",{className:"text-xs text-gray-400",children:"Use secure cookies"})]})]}),n.jsx(oe,{variant:"secondary",className:"text-xs group-hover:bg-white group-hover:border-black group-hover:text-black bg-black/70 border border-white/15 rounded-none border-dashed flex items-center gap-1",children:(A=e==null?void 0:e.advanced)!=null&&A.useSecureCookies?n.jsxs(n.Fragment,{children:[n.jsx(Ie,{className:"w-3 h-3"}),"Enabled"]}):n.jsxs(n.Fragment,{children:[n.jsx(ar,{className:"w-3 h-3"}),"Disabled"]})})]}),n.jsxs("div",{className:"flex items-center justify-between p-4 px-5 border-b border-white/15",children:[n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx(ir,{className:"w-5 h-5 text-white"}),n.jsxs("div",{children:[n.jsx("p",{className:"text-sm font-medium text-white",children:"CSRF Check"}),n.jsx("p",{className:"text-xs text-gray-400",children:"CSRF protection"})]})]}),n.jsx(oe,{variant:"secondary",className:"text-xs group-hover:bg-white group-hover:border-black group-hover:text-black bg-black/70 border border-white/15 rounded-none border-dashed flex items-center gap-1",children:(_=e==null?void 0:e.advanced)!=null&&_.disableCSRFCheck?n.jsxs(n.Fragment,{children:[n.jsx(rn,{className:"w-3 h-3"}),"Disabled"]}):n.jsxs(n.Fragment,{children:[n.jsx(Ie,{className:"w-3 h-3"}),"Enabled"]})})]}),n.jsxs("div",{className:"flex items-center justify-between p-4 px-5 border-b border-white/15",children:[n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx(el,{className:"w-5 h-5 text-white"}),n.jsxs("div",{children:[n.jsx("p",{className:"text-sm font-medium text-white",children:"IP Tracking"}),n.jsx("p",{className:"text-xs text-gray-400",children:"Track IP addresses"})]})]}),n.jsx(oe,{variant:"secondary",className:"text-xs group-hover:bg-white group-hover:border-black group-hover:text-black bg-black/70 border border-white/15 rounded-none border-dashed flex items-center gap-1",children:(E=(W=e==null?void 0:e.advanced)==null?void 0:W.ipAddress)!=null&&E.disableIpTracking?n.jsxs(n.Fragment,{children:[n.jsx(rn,{className:"w-3 h-3"}),"Disabled"]}):n.jsxs(n.Fragment,{children:[n.jsx(Ie,{className:"w-3 h-3"}),"Enabled"]})})]}),n.jsxs("div",{className:"flex items-center justify-between p-4 px-5 border-b border-white/15 last:border-b-0",children:[n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx(j0,{className:"w-5 h-5 text-white"}),n.jsxs("div",{children:[n.jsx("p",{className:"text-sm font-medium text-white",children:"Telemetry"}),n.jsx("p",{className:"text-xs text-gray-400",children:"Usage analytics"})]})]}),n.jsx(oe,{variant:"secondary",className:"text-xs group-hover:bg-white group-hover:border-black group-hover:text-black bg-black/70 border border-white/15 rounded-none border-dashed flex items-center gap-1",children:(z=e==null?void 0:e.telemetry)!=null&&z.enabled?n.jsxs(n.Fragment,{children:[n.jsx(ar,{className:"w-3 h-3"}),"Enabled"]}):n.jsxs(n.Fragment,{children:[n.jsx(Ie,{className:"w-3 h-3"}),"Disabled"]})})]})]})]}),n.jsxs(Ze,{className:"border-white/15 bg-black rounded-none",children:[n.jsxs(Yt,{className:"border-b border-white/15",children:[n.jsxs(Gt,{className:"text-white flex items-center space-x-2",children:[n.jsx(Es,{className:"w-5 h-5 text-white"}),n.jsx("span",{children:"System Info"})]}),n.jsx(Xt,{children:"Better Auth Studio system information"})]}),n.jsxs(qe,{className:"p-0",children:[n.jsxs("div",{className:"flex items-center justify-between p-4 px-5 border-b border-white/15",children:[n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx(ii,{className:"w-5 h-5 text-white"}),n.jsxs("div",{children:[n.jsx("p",{className:"text-sm font-medium text-white",children:"Studio Version"}),n.jsx("p",{className:"text-xs text-gray-400",children:"Better Auth Studio"})]})]}),n.jsxs("div",{className:"text-right",children:[n.jsx("p",{className:"text-sm font-medium text-white",children:(r==null?void 0:r.studioVersion)||"v1.0.0"}),n.jsx("p",{className:"text-xs text-gray-400",children:"Latest"})]})]}),n.jsxs("div",{className:"flex items-center justify-between p-4 px-5 border-b border-white/15",children:[n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx(Es,{className:"w-5 h-5 text-white"}),n.jsxs("div",{children:[n.jsx("p",{className:"text-sm font-medium text-white",children:"Node.js Version"}),n.jsx("p",{className:"text-xs text-gray-400",children:"Runtime environment"})]})]}),n.jsxs("div",{className:"text-right",children:[n.jsx("p",{className:"text-sm font-medium text-white",children:(r==null?void 0:r.nodeVersion)||"v18.0.0"}),n.jsx("p",{className:"text-xs text-gray-400",children:"Current"})]})]}),n.jsxs("div",{className:"flex items-center justify-between p-4 px-5 border-b border-white/15",children:[n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx(Sn,{className:"w-5 h-5 text-white"}),n.jsxs("div",{children:[n.jsx("p",{className:"text-sm font-medium text-white",children:"Platform"}),n.jsx("p",{className:"text-xs text-gray-400",children:"Operating system"})]})]}),n.jsxs("div",{className:"text-right",children:[n.jsx("p",{className:"text-sm font-medium text-white",children:(r==null?void 0:r.platform)||"macOS"}),n.jsx("p",{className:"text-xs text-gray-400",children:"System"})]})]}),n.jsxs("div",{className:"flex items-center justify-between p-4 px-5 border-b border-white/15 last:border-b-0",children:[n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx(_s,{className:"w-5 h-5 text-white"}),n.jsxs("div",{children:[n.jsx("p",{className:"text-sm font-medium text-white",children:"Uptime"}),n.jsx("p",{className:"text-xs text-gray-400",children:"Service uptime"})]})]}),n.jsxs("div",{className:"text-right",children:[n.jsx("p",{className:"text-sm font-medium text-white",children:(r==null?void 0:r.uptime)||"2h 15m"}),n.jsx("p",{className:"text-xs text-gray-400",children:"Running"})]})]})]})]}),n.jsxs(Ze,{className:"border-white/15 bg-black/70 px-0 sm:px-0 md:px-0 lg:px-0 xl:px-0 rounded-none lg:col-span-2",children:[n.jsxs(Yt,{children:[n.jsxs(Gt,{className:"text-white flex items-center space-x-2",children:[n.jsx(Nu,{className:"w-5 h-5 text-white"}),n.jsx("span",{children:"Plugins"})]}),n.jsx(Xt,{children:"Better Auth plugins enabled in your configuration"})]}),n.jsx("hr",{className:"w-full border-white/15 h-px -mt-3 mb-1"}),n.jsx(qe,{className:"space-y-0 px-0 pb-0 border-b-none",children:a!=null&&a.plugins&&a.plugins.length>0?n.jsxs(n.Fragment,{children:[n.jsxs("div",{className:"flex items-center justify-between p-4 px-5 border-b border-white/15",children:[n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx(Es,{className:"w-5 h-5 text-white"}),n.jsxs("div",{children:[n.jsx("p",{className:"text-sm font-medium text-white",children:"Total Plugins"}),n.jsx("p",{className:"text-xs text-gray-400",children:"Currently enabled plugins"})]})]}),n.jsxs("div",{className:"text-right",children:[n.jsx("p",{className:"text-sm font-medium text-white",children:a.totalPlugins}),n.jsx("p",{className:"text-xs text-gray-400",children:"Active"})]})]}),a.plugins.map((M,L)=>n.jsxs("div",{className:`flex items-center justify-between p-4 px-5 ${L<a.plugins.length-1?"border-b border-white/15":""}`,children:[n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx(Nu,{className:"w-5 h-5 text-white"}),n.jsxs("div",{children:[n.jsx("p",{className:"text-sm font-medium text-white",children:M.name}),n.jsx("p",{className:"text-xs text-gray-400",children:M.description})]})]}),n.jsx("div",{className:"text-right flex items-center space-x-2",children:n.jsxs(oe,{variant:"secondary",className:"text-xs bg-green-900/50 border border-dashed rounded-none border-green-500/30 text-green-400 flex items-center gap-1",children:[n.jsx(Ie,{className:"w-3 h-3"}),"Enabled"]})})]},M.id)),a.configPath&&n.jsx("div",{className:"p-4 px-5 bg-black/30 border-t border-white/10",children:n.jsxs("p",{className:"text-xs text-gray-400",children:["Config file:"," ",n.jsx("span",{className:"text-white font-mono",children:a.configPath})]})})]}):n.jsxs("div",{className:"flex items-center justify-between p-4 px-5",children:[n.jsxs("div",{className:"flex items-center space-x-3",children:[n.jsx(ar,{className:"w-5 h-5 text-yellow-400"}),n.jsxs("div",{children:[n.jsx("p",{className:"text-sm font-medium text-white",children:"No Plugins Enabled"}),n.jsx("p",{className:"text-xs text-gray-400",children:(a==null?void 0:a.error)||"No plugins are currently configured in your Better Auth setup"})]})]}),n.jsx(oe,{variant:"secondary",className:"text-xs bg-yellow-900/50 border border-yellow-500/30 text-yellow-400 rounded-sm",children:"None"})]})})]})]})]})}function Pb(){return n.jsx(jb,{children:n.jsxs(Vv,{children:[n.jsx(Nb,{children:n.jsxs(_v,{children:[n.jsx(kr,{path:"/",element:n.jsx(Sb,{})}),n.jsx(kr,{path:"/users",element:n.jsx(pp,{})}),n.jsx(kr,{path:"/organizations",element:n.jsx(xp,{})}),n.jsx(kr,{path:"/organizations/:orgId",element:n.jsx(Cb,{})}),n.jsx(kr,{path:"/teams/:teamId",element:n.jsx(Eb,{})}),n.jsx(kr,{path:"/sessions",element:n.jsx(gp,{})}),n.jsx(kr,{path:"/settings",element:n.jsx(Tb,{})})]})}),n.jsx(y0,{theme:"dark",position:"top-right",richColors:!0,closeButton:!0})]})})}Hl.createRoot(document.getElementById("root")).render(n.jsx(U.StrictMode,{children:n.jsx(Pb,{})}));