roadmap-kit 1.0.0 → 1.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/INSTALL.md +1 -1
- package/cli.js +611 -26
- package/dashboard/index.html +7 -5
- package/dashboard/server.js +35 -10
- package/dashboard/src/App.jsx +571 -175
- package/dashboard/src/index.css +555 -304
- package/dashboard/src/main.jsx +2 -2
- package/dashboard/src/themes.js +50 -0
- package/dashboard/tailwind.config.js +7 -1
- package/dashboard/vite.config.js +3 -0
- package/package.json +2 -2
- package/dashboard/dist/assets/index-BzYzLB7u.css +0 -1
- package/dashboard/dist/assets/index-DIonhzlK.js +0 -506
- package/dashboard/dist/index.html +0 -18
- package/dashboard/dist/roadmap.json +0 -268
|
@@ -1,506 +0,0 @@
|
|
|
1
|
-
(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const l of document.querySelectorAll('link[rel="modulepreload"]'))s(l);new MutationObserver(l=>{for(const a of l)if(a.type==="childList")for(const i of a.addedNodes)i.tagName==="LINK"&&i.rel==="modulepreload"&&s(i)}).observe(document,{childList:!0,subtree:!0});function r(l){const a={};return l.integrity&&(a.integrity=l.integrity),l.referrerPolicy&&(a.referrerPolicy=l.referrerPolicy),l.crossOrigin==="use-credentials"?a.credentials="include":l.crossOrigin==="anonymous"?a.credentials="omit":a.credentials="same-origin",a}function s(l){if(l.ep)return;l.ep=!0;const a=r(l);fetch(l.href,a)}})();function Mu(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var gc={exports:{}},fl={},yc={exports:{}},q={};/**
|
|
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 is=Symbol.for("react.element"),Uu=Symbol.for("react.portal"),Fu=Symbol.for("react.fragment"),zu=Symbol.for("react.strict_mode"),$u=Symbol.for("react.profiler"),Vu=Symbol.for("react.provider"),Hu=Symbol.for("react.context"),Gu=Symbol.for("react.forward_ref"),Bu=Symbol.for("react.suspense"),Wu=Symbol.for("react.memo"),Ku=Symbol.for("react.lazy"),eo=Symbol.iterator;function Yu(e){return e===null||typeof e!="object"?null:(e=eo&&e[eo]||e["@@iterator"],typeof e=="function"?e:null)}var vc={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},Nc=Object.assign,jc={};function mn(e,t,r){this.props=e,this.context=t,this.refs=jc,this.updater=r||vc}mn.prototype.isReactComponent={};mn.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")};mn.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function wc(){}wc.prototype=mn.prototype;function si(e,t,r){this.props=e,this.context=t,this.refs=jc,this.updater=r||vc}var li=si.prototype=new wc;li.constructor=si;Nc(li,mn.prototype);li.isPureReactComponent=!0;var to=Array.isArray,Ec=Object.prototype.hasOwnProperty,ai={current:null},bc={key:!0,ref:!0,__self:!0,__source:!0};function Sc(e,t,r){var s,l={},a=null,i=null;if(t!=null)for(s in t.ref!==void 0&&(i=t.ref),t.key!==void 0&&(a=""+t.key),t)Ec.call(t,s)&&!bc.hasOwnProperty(s)&&(l[s]=t[s]);var o=arguments.length-2;if(o===1)l.children=r;else if(1<o){for(var c=Array(o),d=0;d<o;d++)c[d]=arguments[d+2];l.children=c}if(e&&e.defaultProps)for(s in o=e.defaultProps,o)l[s]===void 0&&(l[s]=o[s]);return{$$typeof:is,type:e,key:a,ref:i,props:l,_owner:ai.current}}function Ju(e,t){return{$$typeof:is,type:e.type,key:t,ref:e.ref,props:e.props,_owner:e._owner}}function ii(e){return typeof e=="object"&&e!==null&&e.$$typeof===is}function Qu(e){var t={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,function(r){return t[r]})}var ro=/\/+/g;function Il(e,t){return typeof e=="object"&&e!==null&&e.key!=null?Qu(""+e.key):t.toString(36)}function Rs(e,t,r,s,l){var a=typeof e;(a==="undefined"||a==="boolean")&&(e=null);var i=!1;if(e===null)i=!0;else switch(a){case"string":case"number":i=!0;break;case"object":switch(e.$$typeof){case is:case Uu:i=!0}}if(i)return i=e,l=l(i),e=s===""?"."+Il(i,0):s,to(l)?(r="",e!=null&&(r=e.replace(ro,"$&/")+"/"),Rs(l,t,r,"",function(d){return d})):l!=null&&(ii(l)&&(l=Ju(l,r+(!l.key||i&&i.key===l.key?"":(""+l.key).replace(ro,"$&/")+"/")+e)),t.push(l)),1;if(i=0,s=s===""?".":s+":",to(e))for(var o=0;o<e.length;o++){a=e[o];var c=s+Il(a,o);i+=Rs(a,t,r,c,l)}else if(c=Yu(e),typeof c=="function")for(e=c.call(e),o=0;!(a=e.next()).done;)a=a.value,c=s+Il(a,o++),i+=Rs(a,t,r,c,l);else if(a==="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 i}function ms(e,t,r){if(e==null)return e;var s=[],l=0;return Rs(e,s,"","",function(a){return t.call(r,a,l++)}),s}function qu(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 Ge={current:null},Is={transition:null},Xu={ReactCurrentDispatcher:Ge,ReactCurrentBatchConfig:Is,ReactCurrentOwner:ai};function kc(){throw Error("act(...) is not supported in production builds of React.")}q.Children={map:ms,forEach:function(e,t,r){ms(e,function(){t.apply(this,arguments)},r)},count:function(e){var t=0;return ms(e,function(){t++}),t},toArray:function(e){return ms(e,function(t){return t})||[]},only:function(e){if(!ii(e))throw Error("React.Children.only expected to receive a single React element child.");return e}};q.Component=mn;q.Fragment=Fu;q.Profiler=$u;q.PureComponent=si;q.StrictMode=zu;q.Suspense=Bu;q.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=Xu;q.act=kc;q.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=Nc({},e.props),l=e.key,a=e.ref,i=e._owner;if(t!=null){if(t.ref!==void 0&&(a=t.ref,i=ai.current),t.key!==void 0&&(l=""+t.key),e.type&&e.type.defaultProps)var o=e.type.defaultProps;for(c in t)Ec.call(t,c)&&!bc.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:is,type:e.type,key:l,ref:a,props:s,_owner:i}};q.createContext=function(e){return e={$$typeof:Hu,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null},e.Provider={$$typeof:Vu,_context:e},e.Consumer=e};q.createElement=Sc;q.createFactory=function(e){var t=Sc.bind(null,e);return t.type=e,t};q.createRef=function(){return{current:null}};q.forwardRef=function(e){return{$$typeof:Gu,render:e}};q.isValidElement=ii;q.lazy=function(e){return{$$typeof:Ku,_payload:{_status:-1,_result:e},_init:qu}};q.memo=function(e,t){return{$$typeof:Wu,type:e,compare:t===void 0?null:t}};q.startTransition=function(e){var t=Is.transition;Is.transition={};try{e()}finally{Is.transition=t}};q.unstable_act=kc;q.useCallback=function(e,t){return Ge.current.useCallback(e,t)};q.useContext=function(e){return Ge.current.useContext(e)};q.useDebugValue=function(){};q.useDeferredValue=function(e){return Ge.current.useDeferredValue(e)};q.useEffect=function(e,t){return Ge.current.useEffect(e,t)};q.useId=function(){return Ge.current.useId()};q.useImperativeHandle=function(e,t,r){return Ge.current.useImperativeHandle(e,t,r)};q.useInsertionEffect=function(e,t){return Ge.current.useInsertionEffect(e,t)};q.useLayoutEffect=function(e,t){return Ge.current.useLayoutEffect(e,t)};q.useMemo=function(e,t){return Ge.current.useMemo(e,t)};q.useReducer=function(e,t,r){return Ge.current.useReducer(e,t,r)};q.useRef=function(e){return Ge.current.useRef(e)};q.useState=function(e){return Ge.current.useState(e)};q.useSyncExternalStore=function(e,t,r){return Ge.current.useSyncExternalStore(e,t,r)};q.useTransition=function(){return Ge.current.useTransition()};q.version="18.3.1";yc.exports=q;var v=yc.exports;const oi=Mu(v);/**
|
|
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 Zu=v,em=Symbol.for("react.element"),tm=Symbol.for("react.fragment"),rm=Object.prototype.hasOwnProperty,nm=Zu.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,sm={key:!0,ref:!0,__self:!0,__source:!0};function Cc(e,t,r){var s,l={},a=null,i=null;r!==void 0&&(a=""+r),t.key!==void 0&&(a=""+t.key),t.ref!==void 0&&(i=t.ref);for(s in t)rm.call(t,s)&&!sm.hasOwnProperty(s)&&(l[s]=t[s]);if(e&&e.defaultProps)for(s in t=e.defaultProps,t)l[s]===void 0&&(l[s]=t[s]);return{$$typeof:em,type:e,key:a,ref:i,props:l,_owner:nm.current}}fl.Fragment=tm;fl.jsx=Cc;fl.jsxs=Cc;gc.exports=fl;var n=gc.exports,aa={},Ac={exports:{}},st={},Tc={exports:{}},Rc={};/**
|
|
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,V){var H=k.length;k.push(V);e:for(;0<H;){var Z=H-1>>>1,G=k[Z];if(0<l(G,V))k[Z]=V,k[H]=G,H=Z;else break e}}function r(k){return k.length===0?null:k[0]}function s(k){if(k.length===0)return null;var V=k[0],H=k.pop();if(H!==V){k[0]=H;e:for(var Z=0,G=k.length,gt=G>>>1;Z<gt;){var $e=2*(Z+1)-1,J=k[$e],me=$e+1,Te=k[me];if(0>l(J,H))me<G&&0>l(Te,J)?(k[Z]=Te,k[me]=H,Z=me):(k[Z]=J,k[$e]=H,Z=$e);else if(me<G&&0>l(Te,H))k[Z]=Te,k[me]=H,Z=me;else break e}}return V}function l(k,V){var H=k.sortIndex-V.sortIndex;return H!==0?H:k.id-V.id}if(typeof performance=="object"&&typeof performance.now=="function"){var a=performance;e.unstable_now=function(){return a.now()}}else{var i=Date,o=i.now();e.unstable_now=function(){return i.now()-o}}var c=[],d=[],f=1,g=null,h=3,x=!1,N=!1,E=!1,b=typeof setTimeout=="function"?setTimeout:null,m=typeof clearTimeout=="function"?clearTimeout:null,u=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function p(k){for(var V=r(d);V!==null;){if(V.callback===null)s(d);else if(V.startTime<=k)s(d),V.sortIndex=V.expirationTime,t(c,V);else break;V=r(d)}}function j(k){if(E=!1,p(k),!N)if(r(c)!==null)N=!0,Ne(S);else{var V=r(d);V!==null&&xe(j,V.startTime-k)}}function S(k,V){N=!1,E&&(E=!1,m(T),T=-1),x=!0;var H=h;try{for(p(V),g=r(c);g!==null&&(!(g.expirationTime>V)||k&&!L());){var Z=g.callback;if(typeof Z=="function"){g.callback=null,h=g.priorityLevel;var G=Z(g.expirationTime<=V);V=e.unstable_now(),typeof G=="function"?g.callback=G:g===r(c)&&s(c),p(V)}else s(c);g=r(c)}if(g!==null)var gt=!0;else{var $e=r(d);$e!==null&&xe(j,$e.startTime-V),gt=!1}return gt}finally{g=null,h=H,x=!1}}var R=!1,y=null,T=-1,P=5,C=-1;function L(){return!(e.unstable_now()-C<P)}function D(){if(y!==null){var k=e.unstable_now();C=k;var V=!0;try{V=y(!0,k)}finally{V?_():(R=!1,y=null)}}else R=!1}var _;if(typeof u=="function")_=function(){u(D)};else if(typeof MessageChannel<"u"){var Y=new MessageChannel,F=Y.port2;Y.port1.onmessage=D,_=function(){F.postMessage(null)}}else _=function(){b(D,0)};function Ne(k){y=k,R||(R=!0,_())}function xe(k,V){T=b(function(){k(e.unstable_now())},V)}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(){N||x||(N=!0,Ne(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"):P=0<k?Math.floor(1e3/k):5},e.unstable_getCurrentPriorityLevel=function(){return h},e.unstable_getFirstCallbackNode=function(){return r(c)},e.unstable_next=function(k){switch(h){case 1:case 2:case 3:var V=3;break;default:V=h}var H=h;h=V;try{return k()}finally{h=H}},e.unstable_pauseExecution=function(){},e.unstable_requestPaint=function(){},e.unstable_runWithPriority=function(k,V){switch(k){case 1:case 2:case 3:case 4:case 5:break;default:k=3}var H=h;h=k;try{return V()}finally{h=H}},e.unstable_scheduleCallback=function(k,V,H){var Z=e.unstable_now();switch(typeof H=="object"&&H!==null?(H=H.delay,H=typeof H=="number"&&0<H?Z+H:Z):H=Z,k){case 1:var G=-1;break;case 2:G=250;break;case 5:G=1073741823;break;case 4:G=1e4;break;default:G=5e3}return G=H+G,k={id:f++,callback:V,priorityLevel:k,startTime:H,expirationTime:G,sortIndex:-1},H>Z?(k.sortIndex=H,t(d,k),r(c)===null&&k===r(d)&&(E?(m(T),T=-1):E=!0,xe(j,H-Z))):(k.sortIndex=G,t(c,k),N||x||(N=!0,Ne(S))),k},e.unstable_shouldYield=L,e.unstable_wrapCallback=function(k){var V=h;return function(){var H=h;h=V;try{return k.apply(this,arguments)}finally{h=H}}}})(Rc);Tc.exports=Rc;var lm=Tc.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 am=v,nt=lm;function I(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 Ic=new Set,zn={};function Ir(e,t){rn(e,t),rn(e+"Capture",t)}function rn(e,t){for(zn[e]=t,e=0;e<t.length;e++)Ic.add(t[e])}var zt=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),ia=Object.prototype.hasOwnProperty,im=/^[: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]*$/,no={},so={};function om(e){return ia.call(so,e)?!0:ia.call(no,e)?!1:im.test(e)?so[e]=!0:(no[e]=!0,!1)}function cm(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 dm(e,t,r,s){if(t===null||typeof t>"u"||cm(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 Be(e,t,r,s,l,a,i){this.acceptsBooleans=t===2||t===3||t===4,this.attributeName=s,this.attributeNamespace=l,this.mustUseProperty=r,this.propertyName=e,this.type=t,this.sanitizeURL=a,this.removeEmptyString=i}var Pe={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){Pe[e]=new Be(e,0,!1,e,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];Pe[t]=new Be(t,1,!1,e[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(e){Pe[e]=new Be(e,2,!1,e.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){Pe[e]=new Be(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){Pe[e]=new Be(e,3,!1,e.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(e){Pe[e]=new Be(e,3,!0,e,null,!1,!1)});["capture","download"].forEach(function(e){Pe[e]=new Be(e,4,!1,e,null,!1,!1)});["cols","rows","size","span"].forEach(function(e){Pe[e]=new Be(e,6,!1,e,null,!1,!1)});["rowSpan","start"].forEach(function(e){Pe[e]=new Be(e,5,!1,e.toLowerCase(),null,!1,!1)});var ci=/[\-:]([a-z])/g;function di(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(ci,di);Pe[t]=new Be(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(ci,di);Pe[t]=new Be(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(ci,di);Pe[t]=new Be(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(e){Pe[e]=new Be(e,1,!1,e.toLowerCase(),null,!1,!1)});Pe.xlinkHref=new Be("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(e){Pe[e]=new Be(e,1,!1,e.toLowerCase(),null,!0,!0)});function ui(e,t,r,s){var l=Pe.hasOwnProperty(t)?Pe[t]:null;(l!==null?l.type!==0:s||!(2<t.length)||t[0]!=="o"&&t[0]!=="O"||t[1]!=="n"&&t[1]!=="N")&&(dm(t,r,l,s)&&(r=null),s||l===null?om(t)&&(r===null?e.removeAttribute(t):e.setAttribute(t,""+r)):l.mustUseProperty?e[l.propertyName]=r===null?l.type===3?!1:"":r:(t=l.attributeName,s=l.attributeNamespace,r===null?e.removeAttribute(t):(l=l.type,r=l===3||l===4&&r===!0?"":""+r,s?e.setAttributeNS(s,t,r):e.setAttribute(t,r))))}var Gt=am.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,ps=Symbol.for("react.element"),Ur=Symbol.for("react.portal"),Fr=Symbol.for("react.fragment"),mi=Symbol.for("react.strict_mode"),oa=Symbol.for("react.profiler"),Oc=Symbol.for("react.provider"),Dc=Symbol.for("react.context"),pi=Symbol.for("react.forward_ref"),ca=Symbol.for("react.suspense"),da=Symbol.for("react.suspense_list"),fi=Symbol.for("react.memo"),Qt=Symbol.for("react.lazy"),Pc=Symbol.for("react.offscreen"),lo=Symbol.iterator;function vn(e){return e===null||typeof e!="object"?null:(e=lo&&e[lo]||e["@@iterator"],typeof e=="function"?e:null)}var ve=Object.assign,Ol;function Cn(e){if(Ol===void 0)try{throw Error()}catch(r){var t=r.stack.trim().match(/\n( *(at )?)/);Ol=t&&t[1]||""}return`
|
|
34
|
-
`+Ol+e}var Dl=!1;function Pl(e,t){if(!e||Dl)return"";Dl=!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 l=d.stack.split(`
|
|
35
|
-
`),a=s.stack.split(`
|
|
36
|
-
`),i=l.length-1,o=a.length-1;1<=i&&0<=o&&l[i]!==a[o];)o--;for(;1<=i&&0<=o;i--,o--)if(l[i]!==a[o]){if(i!==1||o!==1)do if(i--,o--,0>o||l[i]!==a[o]){var c=`
|
|
37
|
-
`+l[i].replace(" at new "," at ");return e.displayName&&c.includes("<anonymous>")&&(c=c.replace("<anonymous>",e.displayName)),c}while(1<=i&&0<=o);break}}}finally{Dl=!1,Error.prepareStackTrace=r}return(e=e?e.displayName||e.name:"")?Cn(e):""}function um(e){switch(e.tag){case 5:return Cn(e.type);case 16:return Cn("Lazy");case 13:return Cn("Suspense");case 19:return Cn("SuspenseList");case 0:case 2:case 15:return e=Pl(e.type,!1),e;case 11:return e=Pl(e.type.render,!1),e;case 1:return e=Pl(e.type,!0),e;default:return""}}function ua(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 Fr:return"Fragment";case Ur:return"Portal";case oa:return"Profiler";case mi:return"StrictMode";case ca:return"Suspense";case da:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case Dc:return(e.displayName||"Context")+".Consumer";case Oc:return(e._context.displayName||"Context")+".Provider";case pi:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case fi:return t=e.displayName||null,t!==null?t:ua(e.type)||"Memo";case Qt:t=e._payload,e=e._init;try{return ua(e(t))}catch{}}return null}function mm(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 ua(t);case 8:return t===mi?"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 ur(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function Lc(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function pm(e){var t=Lc(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 l=r.get,a=r.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return l.call(this)},set:function(i){s=""+i,a.call(this,i)}}),Object.defineProperty(e,t,{enumerable:r.enumerable}),{getValue:function(){return s},setValue:function(i){s=""+i},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function fs(e){e._valueTracker||(e._valueTracker=pm(e))}function _c(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var r=t.getValue(),s="";return e&&(s=Lc(e)?e.checked?"true":"false":e.value),e=s,e!==r?(t.setValue(e),!0):!1}function Vs(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 ma(e,t){var r=t.checked;return ve({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:r??e._wrapperState.initialChecked})}function ao(e,t){var r=t.defaultValue==null?"":t.defaultValue,s=t.checked!=null?t.checked:t.defaultChecked;r=ur(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 Mc(e,t){t=t.checked,t!=null&&ui(e,"checked",t,!1)}function pa(e,t){Mc(e,t);var r=ur(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")?fa(e,t.type,r):t.hasOwnProperty("defaultValue")&&fa(e,t.type,ur(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function io(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 fa(e,t,r){(t!=="number"||Vs(e.ownerDocument)!==e)&&(r==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+r&&(e.defaultValue=""+r))}var An=Array.isArray;function Qr(e,t,r,s){if(e=e.options,t){t={};for(var l=0;l<r.length;l++)t["$"+r[l]]=!0;for(r=0;r<e.length;r++)l=t.hasOwnProperty("$"+e[r].value),e[r].selected!==l&&(e[r].selected=l),l&&s&&(e[r].defaultSelected=!0)}else{for(r=""+ur(r),t=null,l=0;l<e.length;l++){if(e[l].value===r){e[l].selected=!0,s&&(e[l].defaultSelected=!0);return}t!==null||e[l].disabled||(t=e[l])}t!==null&&(t.selected=!0)}}function xa(e,t){if(t.dangerouslySetInnerHTML!=null)throw Error(I(91));return ve({},t,{value:void 0,defaultValue:void 0,children:""+e._wrapperState.initialValue})}function oo(e,t){var r=t.value;if(r==null){if(r=t.children,t=t.defaultValue,r!=null){if(t!=null)throw Error(I(92));if(An(r)){if(1<r.length)throw Error(I(93));r=r[0]}t=r}t==null&&(t=""),r=t}e._wrapperState={initialValue:ur(r)}}function Uc(e,t){var r=ur(t.value),s=ur(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 co(e){var t=e.textContent;t===e._wrapperState.initialValue&&t!==""&&t!==null&&(e.value=t)}function Fc(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 ha(e,t){return e==null||e==="http://www.w3.org/1999/xhtml"?Fc(t):e==="http://www.w3.org/2000/svg"&&t==="foreignObject"?"http://www.w3.org/1999/xhtml":e}var xs,zc=function(e){return typeof MSApp<"u"&&MSApp.execUnsafeLocalFunction?function(t,r,s,l){MSApp.execUnsafeLocalFunction(function(){return e(t,r,s,l)})}:e}(function(e,t){if(e.namespaceURI!=="http://www.w3.org/2000/svg"||"innerHTML"in e)e.innerHTML=t;else{for(xs=xs||document.createElement("div"),xs.innerHTML="<svg>"+t.valueOf().toString()+"</svg>",t=xs.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function $n(e,t){if(t){var r=e.firstChild;if(r&&r===e.lastChild&&r.nodeType===3){r.nodeValue=t;return}}e.textContent=t}var In={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},fm=["Webkit","ms","Moz","O"];Object.keys(In).forEach(function(e){fm.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),In[t]=In[e]})});function $c(e,t,r){return t==null||typeof t=="boolean"||t===""?"":r||typeof t!="number"||t===0||In.hasOwnProperty(e)&&In[e]?(""+t).trim():t+"px"}function Vc(e,t){e=e.style;for(var r in t)if(t.hasOwnProperty(r)){var s=r.indexOf("--")===0,l=$c(r,t[r],s);r==="float"&&(r="cssFloat"),s?e.setProperty(r,l):e[r]=l}}var xm=ve({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 ga(e,t){if(t){if(xm[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(I(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(I(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(I(61))}if(t.style!=null&&typeof t.style!="object")throw Error(I(62))}}function ya(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 va=null;function xi(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var Na=null,qr=null,Xr=null;function uo(e){if(e=ds(e)){if(typeof Na!="function")throw Error(I(280));var t=e.stateNode;t&&(t=vl(t),Na(e.stateNode,e.type,t))}}function Hc(e){qr?Xr?Xr.push(e):Xr=[e]:qr=e}function Gc(){if(qr){var e=qr,t=Xr;if(Xr=qr=null,uo(e),t)for(e=0;e<t.length;e++)uo(t[e])}}function Bc(e,t){return e(t)}function Wc(){}var Ll=!1;function Kc(e,t,r){if(Ll)return e(t,r);Ll=!0;try{return Bc(e,t,r)}finally{Ll=!1,(qr!==null||Xr!==null)&&(Wc(),Gc())}}function Vn(e,t){var r=e.stateNode;if(r===null)return null;var s=vl(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(I(231,t,typeof r));return r}var ja=!1;if(zt)try{var Nn={};Object.defineProperty(Nn,"passive",{get:function(){ja=!0}}),window.addEventListener("test",Nn,Nn),window.removeEventListener("test",Nn,Nn)}catch{ja=!1}function hm(e,t,r,s,l,a,i,o,c){var d=Array.prototype.slice.call(arguments,3);try{t.apply(r,d)}catch(f){this.onError(f)}}var On=!1,Hs=null,Gs=!1,wa=null,gm={onError:function(e){On=!0,Hs=e}};function ym(e,t,r,s,l,a,i,o,c){On=!1,Hs=null,hm.apply(gm,arguments)}function vm(e,t,r,s,l,a,i,o,c){if(ym.apply(this,arguments),On){if(On){var d=Hs;On=!1,Hs=null}else throw Error(I(198));Gs||(Gs=!0,wa=d)}}function Or(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 Yc(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 mo(e){if(Or(e)!==e)throw Error(I(188))}function Nm(e){var t=e.alternate;if(!t){if(t=Or(e),t===null)throw Error(I(188));return t!==e?null:e}for(var r=e,s=t;;){var l=r.return;if(l===null)break;var a=l.alternate;if(a===null){if(s=l.return,s!==null){r=s;continue}break}if(l.child===a.child){for(a=l.child;a;){if(a===r)return mo(l),e;if(a===s)return mo(l),t;a=a.sibling}throw Error(I(188))}if(r.return!==s.return)r=l,s=a;else{for(var i=!1,o=l.child;o;){if(o===r){i=!0,r=l,s=a;break}if(o===s){i=!0,s=l,r=a;break}o=o.sibling}if(!i){for(o=a.child;o;){if(o===r){i=!0,r=a,s=l;break}if(o===s){i=!0,s=a,r=l;break}o=o.sibling}if(!i)throw Error(I(189))}}if(r.alternate!==s)throw Error(I(190))}if(r.tag!==3)throw Error(I(188));return r.stateNode.current===r?e:t}function Jc(e){return e=Nm(e),e!==null?Qc(e):null}function Qc(e){if(e.tag===5||e.tag===6)return e;for(e=e.child;e!==null;){var t=Qc(e);if(t!==null)return t;e=e.sibling}return null}var qc=nt.unstable_scheduleCallback,po=nt.unstable_cancelCallback,jm=nt.unstable_shouldYield,wm=nt.unstable_requestPaint,Ee=nt.unstable_now,Em=nt.unstable_getCurrentPriorityLevel,hi=nt.unstable_ImmediatePriority,Xc=nt.unstable_UserBlockingPriority,Bs=nt.unstable_NormalPriority,bm=nt.unstable_LowPriority,Zc=nt.unstable_IdlePriority,xl=null,Rt=null;function Sm(e){if(Rt&&typeof Rt.onCommitFiberRoot=="function")try{Rt.onCommitFiberRoot(xl,e,void 0,(e.current.flags&128)===128)}catch{}}var Et=Math.clz32?Math.clz32:Am,km=Math.log,Cm=Math.LN2;function Am(e){return e>>>=0,e===0?32:31-(km(e)/Cm|0)|0}var hs=64,gs=4194304;function Tn(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 Ws(e,t){var r=e.pendingLanes;if(r===0)return 0;var s=0,l=e.suspendedLanes,a=e.pingedLanes,i=r&268435455;if(i!==0){var o=i&~l;o!==0?s=Tn(o):(a&=i,a!==0&&(s=Tn(a)))}else i=r&~l,i!==0?s=Tn(i):a!==0&&(s=Tn(a));if(s===0)return 0;if(t!==0&&t!==s&&!(t&l)&&(l=s&-s,a=t&-t,l>=a||l===16&&(a&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-Et(t),l=1<<r,s|=e[r],t&=~l;return s}function Tm(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 Rm(e,t){for(var r=e.suspendedLanes,s=e.pingedLanes,l=e.expirationTimes,a=e.pendingLanes;0<a;){var i=31-Et(a),o=1<<i,c=l[i];c===-1?(!(o&r)||o&s)&&(l[i]=Tm(o,t)):c<=t&&(e.expiredLanes|=o),a&=~o}}function Ea(e){return e=e.pendingLanes&-1073741825,e!==0?e:e&1073741824?1073741824:0}function ed(){var e=hs;return hs<<=1,!(hs&4194240)&&(hs=64),e}function _l(e){for(var t=[],r=0;31>r;r++)t.push(e);return t}function os(e,t,r){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-Et(t),e[t]=r}function Im(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 l=31-Et(r),a=1<<l;t[l]=0,s[l]=-1,e[l]=-1,r&=~a}}function gi(e,t){var r=e.entangledLanes|=t;for(e=e.entanglements;r;){var s=31-Et(r),l=1<<s;l&t|e[s]&t&&(e[s]|=t),r&=~l}}var re=0;function td(e){return e&=-e,1<e?4<e?e&268435455?16:536870912:4:1}var rd,yi,nd,sd,ld,ba=!1,ys=[],rr=null,nr=null,sr=null,Hn=new Map,Gn=new Map,Xt=[],Om="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset submit".split(" ");function fo(e,t){switch(e){case"focusin":case"focusout":rr=null;break;case"dragenter":case"dragleave":nr=null;break;case"mouseover":case"mouseout":sr=null;break;case"pointerover":case"pointerout":Hn.delete(t.pointerId);break;case"gotpointercapture":case"lostpointercapture":Gn.delete(t.pointerId)}}function jn(e,t,r,s,l,a){return e===null||e.nativeEvent!==a?(e={blockedOn:t,domEventName:r,eventSystemFlags:s,nativeEvent:a,targetContainers:[l]},t!==null&&(t=ds(t),t!==null&&yi(t)),e):(e.eventSystemFlags|=s,t=e.targetContainers,l!==null&&t.indexOf(l)===-1&&t.push(l),e)}function Dm(e,t,r,s,l){switch(t){case"focusin":return rr=jn(rr,e,t,r,s,l),!0;case"dragenter":return nr=jn(nr,e,t,r,s,l),!0;case"mouseover":return sr=jn(sr,e,t,r,s,l),!0;case"pointerover":var a=l.pointerId;return Hn.set(a,jn(Hn.get(a)||null,e,t,r,s,l)),!0;case"gotpointercapture":return a=l.pointerId,Gn.set(a,jn(Gn.get(a)||null,e,t,r,s,l)),!0}return!1}function ad(e){var t=jr(e.target);if(t!==null){var r=Or(t);if(r!==null){if(t=r.tag,t===13){if(t=Yc(r),t!==null){e.blockedOn=t,ld(e.priority,function(){nd(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 Os(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var r=Sa(e.domEventName,e.eventSystemFlags,t[0],e.nativeEvent);if(r===null){r=e.nativeEvent;var s=new r.constructor(r.type,r);va=s,r.target.dispatchEvent(s),va=null}else return t=ds(r),t!==null&&yi(t),e.blockedOn=r,!1;t.shift()}return!0}function xo(e,t,r){Os(e)&&r.delete(t)}function Pm(){ba=!1,rr!==null&&Os(rr)&&(rr=null),nr!==null&&Os(nr)&&(nr=null),sr!==null&&Os(sr)&&(sr=null),Hn.forEach(xo),Gn.forEach(xo)}function wn(e,t){e.blockedOn===t&&(e.blockedOn=null,ba||(ba=!0,nt.unstable_scheduleCallback(nt.unstable_NormalPriority,Pm)))}function Bn(e){function t(l){return wn(l,e)}if(0<ys.length){wn(ys[0],e);for(var r=1;r<ys.length;r++){var s=ys[r];s.blockedOn===e&&(s.blockedOn=null)}}for(rr!==null&&wn(rr,e),nr!==null&&wn(nr,e),sr!==null&&wn(sr,e),Hn.forEach(t),Gn.forEach(t),r=0;r<Xt.length;r++)s=Xt[r],s.blockedOn===e&&(s.blockedOn=null);for(;0<Xt.length&&(r=Xt[0],r.blockedOn===null);)ad(r),r.blockedOn===null&&Xt.shift()}var Zr=Gt.ReactCurrentBatchConfig,Ks=!0;function Lm(e,t,r,s){var l=re,a=Zr.transition;Zr.transition=null;try{re=1,vi(e,t,r,s)}finally{re=l,Zr.transition=a}}function _m(e,t,r,s){var l=re,a=Zr.transition;Zr.transition=null;try{re=4,vi(e,t,r,s)}finally{re=l,Zr.transition=a}}function vi(e,t,r,s){if(Ks){var l=Sa(e,t,r,s);if(l===null)Wl(e,t,s,Ys,r),fo(e,s);else if(Dm(l,e,t,r,s))s.stopPropagation();else if(fo(e,s),t&4&&-1<Om.indexOf(e)){for(;l!==null;){var a=ds(l);if(a!==null&&rd(a),a=Sa(e,t,r,s),a===null&&Wl(e,t,s,Ys,r),a===l)break;l=a}l!==null&&s.stopPropagation()}else Wl(e,t,s,null,r)}}var Ys=null;function Sa(e,t,r,s){if(Ys=null,e=xi(s),e=jr(e),e!==null)if(t=Or(e),t===null)e=null;else if(r=t.tag,r===13){if(e=Yc(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 Ys=e,null}function id(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(Em()){case hi:return 1;case Xc:return 4;case Bs:case bm:return 16;case Zc:return 536870912;default:return 16}default:return 16}}var er=null,Ni=null,Ds=null;function od(){if(Ds)return Ds;var e,t=Ni,r=t.length,s,l="value"in er?er.value:er.textContent,a=l.length;for(e=0;e<r&&t[e]===l[e];e++);var i=r-e;for(s=1;s<=i&&t[r-s]===l[a-s];s++);return Ds=l.slice(e,1<s?1-s:void 0)}function Ps(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 vs(){return!0}function ho(){return!1}function lt(e){function t(r,s,l,a,i){this._reactName=r,this._targetInst=l,this.type=s,this.nativeEvent=a,this.target=i,this.currentTarget=null;for(var o in e)e.hasOwnProperty(o)&&(r=e[o],this[o]=r?r(a):a[o]);return this.isDefaultPrevented=(a.defaultPrevented!=null?a.defaultPrevented:a.returnValue===!1)?vs:ho,this.isPropagationStopped=ho,this}return ve(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=vs)},stopPropagation:function(){var r=this.nativeEvent;r&&(r.stopPropagation?r.stopPropagation():typeof r.cancelBubble!="unknown"&&(r.cancelBubble=!0),this.isPropagationStopped=vs)},persist:function(){},isPersistent:vs}),t}var pn={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},ji=lt(pn),cs=ve({},pn,{view:0,detail:0}),Mm=lt(cs),Ml,Ul,En,hl=ve({},cs,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:wi,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!==En&&(En&&e.type==="mousemove"?(Ml=e.screenX-En.screenX,Ul=e.screenY-En.screenY):Ul=Ml=0,En=e),Ml)},movementY:function(e){return"movementY"in e?e.movementY:Ul}}),go=lt(hl),Um=ve({},hl,{dataTransfer:0}),Fm=lt(Um),zm=ve({},cs,{relatedTarget:0}),Fl=lt(zm),$m=ve({},pn,{animationName:0,elapsedTime:0,pseudoElement:0}),Vm=lt($m),Hm=ve({},pn,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),Gm=lt(Hm),Bm=ve({},pn,{data:0}),yo=lt(Bm),Wm={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},Km={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"},Ym={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function Jm(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=Ym[e])?!!t[e]:!1}function wi(){return Jm}var Qm=ve({},cs,{key:function(e){if(e.key){var t=Wm[e.key]||e.key;if(t!=="Unidentified")return t}return e.type==="keypress"?(e=Ps(e),e===13?"Enter":String.fromCharCode(e)):e.type==="keydown"||e.type==="keyup"?Km[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:wi,charCode:function(e){return e.type==="keypress"?Ps(e):0},keyCode:function(e){return e.type==="keydown"||e.type==="keyup"?e.keyCode:0},which:function(e){return e.type==="keypress"?Ps(e):e.type==="keydown"||e.type==="keyup"?e.keyCode:0}}),qm=lt(Qm),Xm=ve({},hl,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),vo=lt(Xm),Zm=ve({},cs,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:wi}),ep=lt(Zm),tp=ve({},pn,{propertyName:0,elapsedTime:0,pseudoElement:0}),rp=lt(tp),np=ve({},hl,{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}),sp=lt(np),lp=[9,13,27,32],Ei=zt&&"CompositionEvent"in window,Dn=null;zt&&"documentMode"in document&&(Dn=document.documentMode);var ap=zt&&"TextEvent"in window&&!Dn,cd=zt&&(!Ei||Dn&&8<Dn&&11>=Dn),No=" ",jo=!1;function dd(e,t){switch(e){case"keyup":return lp.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function ud(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var zr=!1;function ip(e,t){switch(e){case"compositionend":return ud(t);case"keypress":return t.which!==32?null:(jo=!0,No);case"textInput":return e=t.data,e===No&&jo?null:e;default:return null}}function op(e,t){if(zr)return e==="compositionend"||!Ei&&dd(e,t)?(e=od(),Ds=Ni=er=null,zr=!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 cd&&t.locale!=="ko"?null:t.data;default:return null}}var cp={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 wo(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t==="input"?!!cp[e.type]:t==="textarea"}function md(e,t,r,s){Hc(s),t=Js(t,"onChange"),0<t.length&&(r=new ji("onChange","change",null,r,s),e.push({event:r,listeners:t}))}var Pn=null,Wn=null;function dp(e){Ed(e,0)}function gl(e){var t=Hr(e);if(_c(t))return e}function up(e,t){if(e==="change")return t}var pd=!1;if(zt){var zl;if(zt){var $l="oninput"in document;if(!$l){var Eo=document.createElement("div");Eo.setAttribute("oninput","return;"),$l=typeof Eo.oninput=="function"}zl=$l}else zl=!1;pd=zl&&(!document.documentMode||9<document.documentMode)}function bo(){Pn&&(Pn.detachEvent("onpropertychange",fd),Wn=Pn=null)}function fd(e){if(e.propertyName==="value"&&gl(Wn)){var t=[];md(t,Wn,e,xi(e)),Kc(dp,t)}}function mp(e,t,r){e==="focusin"?(bo(),Pn=t,Wn=r,Pn.attachEvent("onpropertychange",fd)):e==="focusout"&&bo()}function pp(e){if(e==="selectionchange"||e==="keyup"||e==="keydown")return gl(Wn)}function fp(e,t){if(e==="click")return gl(t)}function xp(e,t){if(e==="input"||e==="change")return gl(t)}function hp(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var St=typeof Object.is=="function"?Object.is:hp;function Kn(e,t){if(St(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 l=r[s];if(!ia.call(t,l)||!St(e[l],t[l]))return!1}return!0}function So(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function ko(e,t){var r=So(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=So(r)}}function xd(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?xd(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function hd(){for(var e=window,t=Vs();t instanceof e.HTMLIFrameElement;){try{var r=typeof t.contentWindow.location.href=="string"}catch{r=!1}if(r)e=t.contentWindow;else break;t=Vs(e.document)}return t}function bi(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 gp(e){var t=hd(),r=e.focusedElem,s=e.selectionRange;if(t!==r&&r&&r.ownerDocument&&xd(r.ownerDocument.documentElement,r)){if(s!==null&&bi(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 l=r.textContent.length,a=Math.min(s.start,l);s=s.end===void 0?a:Math.min(s.end,l),!e.extend&&a>s&&(l=s,s=a,a=l),l=ko(r,a);var i=ko(r,s);l&&i&&(e.rangeCount!==1||e.anchorNode!==l.node||e.anchorOffset!==l.offset||e.focusNode!==i.node||e.focusOffset!==i.offset)&&(t=t.createRange(),t.setStart(l.node,l.offset),e.removeAllRanges(),a>s?(e.addRange(t),e.extend(i.node,i.offset)):(t.setEnd(i.node,i.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 yp=zt&&"documentMode"in document&&11>=document.documentMode,$r=null,ka=null,Ln=null,Ca=!1;function Co(e,t,r){var s=r.window===r?r.document:r.nodeType===9?r:r.ownerDocument;Ca||$r==null||$r!==Vs(s)||(s=$r,"selectionStart"in s&&bi(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}),Ln&&Kn(Ln,s)||(Ln=s,s=Js(ka,"onSelect"),0<s.length&&(t=new ji("onSelect","select",null,t,r),e.push({event:t,listeners:s}),t.target=$r)))}function Ns(e,t){var r={};return r[e.toLowerCase()]=t.toLowerCase(),r["Webkit"+e]="webkit"+t,r["Moz"+e]="moz"+t,r}var Vr={animationend:Ns("Animation","AnimationEnd"),animationiteration:Ns("Animation","AnimationIteration"),animationstart:Ns("Animation","AnimationStart"),transitionend:Ns("Transition","TransitionEnd")},Vl={},gd={};zt&&(gd=document.createElement("div").style,"AnimationEvent"in window||(delete Vr.animationend.animation,delete Vr.animationiteration.animation,delete Vr.animationstart.animation),"TransitionEvent"in window||delete Vr.transitionend.transition);function yl(e){if(Vl[e])return Vl[e];if(!Vr[e])return e;var t=Vr[e],r;for(r in t)if(t.hasOwnProperty(r)&&r in gd)return Vl[e]=t[r];return e}var yd=yl("animationend"),vd=yl("animationiteration"),Nd=yl("animationstart"),jd=yl("transitionend"),wd=new Map,Ao="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 pr(e,t){wd.set(e,t),Ir(t,[e])}for(var Hl=0;Hl<Ao.length;Hl++){var Gl=Ao[Hl],vp=Gl.toLowerCase(),Np=Gl[0].toUpperCase()+Gl.slice(1);pr(vp,"on"+Np)}pr(yd,"onAnimationEnd");pr(vd,"onAnimationIteration");pr(Nd,"onAnimationStart");pr("dblclick","onDoubleClick");pr("focusin","onFocus");pr("focusout","onBlur");pr(jd,"onTransitionEnd");rn("onMouseEnter",["mouseout","mouseover"]);rn("onMouseLeave",["mouseout","mouseover"]);rn("onPointerEnter",["pointerout","pointerover"]);rn("onPointerLeave",["pointerout","pointerover"]);Ir("onChange","change click focusin focusout input keydown keyup selectionchange".split(" "));Ir("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" "));Ir("onBeforeInput",["compositionend","keypress","textInput","paste"]);Ir("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" "));Ir("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" "));Ir("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Rn="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(" "),jp=new Set("cancel close invalid load scroll toggle".split(" ").concat(Rn));function To(e,t,r){var s=e.type||"unknown-event";e.currentTarget=r,vm(s,t,void 0,e),e.currentTarget=null}function Ed(e,t){t=(t&4)!==0;for(var r=0;r<e.length;r++){var s=e[r],l=s.event;s=s.listeners;e:{var a=void 0;if(t)for(var i=s.length-1;0<=i;i--){var o=s[i],c=o.instance,d=o.currentTarget;if(o=o.listener,c!==a&&l.isPropagationStopped())break e;To(l,o,d),a=c}else for(i=0;i<s.length;i++){if(o=s[i],c=o.instance,d=o.currentTarget,o=o.listener,c!==a&&l.isPropagationStopped())break e;To(l,o,d),a=c}}}if(Gs)throw e=wa,Gs=!1,wa=null,e}function de(e,t){var r=t[Oa];r===void 0&&(r=t[Oa]=new Set);var s=e+"__bubble";r.has(s)||(bd(t,e,2,!1),r.add(s))}function Bl(e,t,r){var s=0;t&&(s|=4),bd(r,e,s,t)}var js="_reactListening"+Math.random().toString(36).slice(2);function Yn(e){if(!e[js]){e[js]=!0,Ic.forEach(function(r){r!=="selectionchange"&&(jp.has(r)||Bl(r,!1,e),Bl(r,!0,e))});var t=e.nodeType===9?e:e.ownerDocument;t===null||t[js]||(t[js]=!0,Bl("selectionchange",!1,t))}}function bd(e,t,r,s){switch(id(t)){case 1:var l=Lm;break;case 4:l=_m;break;default:l=vi}r=l.bind(null,t,r,e),l=void 0,!ja||t!=="touchstart"&&t!=="touchmove"&&t!=="wheel"||(l=!0),s?l!==void 0?e.addEventListener(t,r,{capture:!0,passive:l}):e.addEventListener(t,r,!0):l!==void 0?e.addEventListener(t,r,{passive:l}):e.addEventListener(t,r,!1)}function Wl(e,t,r,s,l){var a=s;if(!(t&1)&&!(t&2)&&s!==null)e:for(;;){if(s===null)return;var i=s.tag;if(i===3||i===4){var o=s.stateNode.containerInfo;if(o===l||o.nodeType===8&&o.parentNode===l)break;if(i===4)for(i=s.return;i!==null;){var c=i.tag;if((c===3||c===4)&&(c=i.stateNode.containerInfo,c===l||c.nodeType===8&&c.parentNode===l))return;i=i.return}for(;o!==null;){if(i=jr(o),i===null)return;if(c=i.tag,c===5||c===6){s=a=i;continue e}o=o.parentNode}}s=s.return}Kc(function(){var d=a,f=xi(r),g=[];e:{var h=wd.get(e);if(h!==void 0){var x=ji,N=e;switch(e){case"keypress":if(Ps(r)===0)break e;case"keydown":case"keyup":x=qm;break;case"focusin":N="focus",x=Fl;break;case"focusout":N="blur",x=Fl;break;case"beforeblur":case"afterblur":x=Fl;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":x=go;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":x=Fm;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":x=ep;break;case yd:case vd:case Nd:x=Vm;break;case jd:x=rp;break;case"scroll":x=Mm;break;case"wheel":x=sp;break;case"copy":case"cut":case"paste":x=Gm;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":x=vo}var E=(t&4)!==0,b=!E&&e==="scroll",m=E?h!==null?h+"Capture":null:h;E=[];for(var u=d,p;u!==null;){p=u;var j=p.stateNode;if(p.tag===5&&j!==null&&(p=j,m!==null&&(j=Vn(u,m),j!=null&&E.push(Jn(u,j,p)))),b)break;u=u.return}0<E.length&&(h=new x(h,N,null,r,f),g.push({event:h,listeners:E}))}}if(!(t&7)){e:{if(h=e==="mouseover"||e==="pointerover",x=e==="mouseout"||e==="pointerout",h&&r!==va&&(N=r.relatedTarget||r.fromElement)&&(jr(N)||N[$t]))break e;if((x||h)&&(h=f.window===f?f:(h=f.ownerDocument)?h.defaultView||h.parentWindow:window,x?(N=r.relatedTarget||r.toElement,x=d,N=N?jr(N):null,N!==null&&(b=Or(N),N!==b||N.tag!==5&&N.tag!==6)&&(N=null)):(x=null,N=d),x!==N)){if(E=go,j="onMouseLeave",m="onMouseEnter",u="mouse",(e==="pointerout"||e==="pointerover")&&(E=vo,j="onPointerLeave",m="onPointerEnter",u="pointer"),b=x==null?h:Hr(x),p=N==null?h:Hr(N),h=new E(j,u+"leave",x,r,f),h.target=b,h.relatedTarget=p,j=null,jr(f)===d&&(E=new E(m,u+"enter",N,r,f),E.target=p,E.relatedTarget=b,j=E),b=j,x&&N)t:{for(E=x,m=N,u=0,p=E;p;p=Mr(p))u++;for(p=0,j=m;j;j=Mr(j))p++;for(;0<u-p;)E=Mr(E),u--;for(;0<p-u;)m=Mr(m),p--;for(;u--;){if(E===m||m!==null&&E===m.alternate)break t;E=Mr(E),m=Mr(m)}E=null}else E=null;x!==null&&Ro(g,h,x,E,!1),N!==null&&b!==null&&Ro(g,b,N,E,!0)}}e:{if(h=d?Hr(d):window,x=h.nodeName&&h.nodeName.toLowerCase(),x==="select"||x==="input"&&h.type==="file")var S=up;else if(wo(h))if(pd)S=xp;else{S=pp;var R=mp}else(x=h.nodeName)&&x.toLowerCase()==="input"&&(h.type==="checkbox"||h.type==="radio")&&(S=fp);if(S&&(S=S(e,d))){md(g,S,r,f);break e}R&&R(e,h,d),e==="focusout"&&(R=h._wrapperState)&&R.controlled&&h.type==="number"&&fa(h,"number",h.value)}switch(R=d?Hr(d):window,e){case"focusin":(wo(R)||R.contentEditable==="true")&&($r=R,ka=d,Ln=null);break;case"focusout":Ln=ka=$r=null;break;case"mousedown":Ca=!0;break;case"contextmenu":case"mouseup":case"dragend":Ca=!1,Co(g,r,f);break;case"selectionchange":if(yp)break;case"keydown":case"keyup":Co(g,r,f)}var y;if(Ei)e:{switch(e){case"compositionstart":var T="onCompositionStart";break e;case"compositionend":T="onCompositionEnd";break e;case"compositionupdate":T="onCompositionUpdate";break e}T=void 0}else zr?dd(e,r)&&(T="onCompositionEnd"):e==="keydown"&&r.keyCode===229&&(T="onCompositionStart");T&&(cd&&r.locale!=="ko"&&(zr||T!=="onCompositionStart"?T==="onCompositionEnd"&&zr&&(y=od()):(er=f,Ni="value"in er?er.value:er.textContent,zr=!0)),R=Js(d,T),0<R.length&&(T=new yo(T,e,null,r,f),g.push({event:T,listeners:R}),y?T.data=y:(y=ud(r),y!==null&&(T.data=y)))),(y=ap?ip(e,r):op(e,r))&&(d=Js(d,"onBeforeInput"),0<d.length&&(f=new yo("onBeforeInput","beforeinput",null,r,f),g.push({event:f,listeners:d}),f.data=y))}Ed(g,t)})}function Jn(e,t,r){return{instance:e,listener:t,currentTarget:r}}function Js(e,t){for(var r=t+"Capture",s=[];e!==null;){var l=e,a=l.stateNode;l.tag===5&&a!==null&&(l=a,a=Vn(e,r),a!=null&&s.unshift(Jn(e,a,l)),a=Vn(e,t),a!=null&&s.push(Jn(e,a,l))),e=e.return}return s}function Mr(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5);return e||null}function Ro(e,t,r,s,l){for(var a=t._reactName,i=[];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,l?(c=Vn(r,a),c!=null&&i.unshift(Jn(r,c,o))):l||(c=Vn(r,a),c!=null&&i.push(Jn(r,c,o)))),r=r.return}i.length!==0&&e.push({event:t,listeners:i})}var wp=/\r\n?/g,Ep=/\u0000|\uFFFD/g;function Io(e){return(typeof e=="string"?e:""+e).replace(wp,`
|
|
38
|
-
`).replace(Ep,"")}function ws(e,t,r){if(t=Io(t),Io(e)!==t&&r)throw Error(I(425))}function Qs(){}var Aa=null,Ta=null;function Ra(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 Ia=typeof setTimeout=="function"?setTimeout:void 0,bp=typeof clearTimeout=="function"?clearTimeout:void 0,Oo=typeof Promise=="function"?Promise:void 0,Sp=typeof queueMicrotask=="function"?queueMicrotask:typeof Oo<"u"?function(e){return Oo.resolve(null).then(e).catch(kp)}:Ia;function kp(e){setTimeout(function(){throw e})}function Kl(e,t){var r=t,s=0;do{var l=r.nextSibling;if(e.removeChild(r),l&&l.nodeType===8)if(r=l.data,r==="/$"){if(s===0){e.removeChild(l),Bn(t);return}s--}else r!=="$"&&r!=="$?"&&r!=="$!"||s++;r=l}while(r);Bn(t)}function lr(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 Do(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 fn=Math.random().toString(36).slice(2),Tt="__reactFiber$"+fn,Qn="__reactProps$"+fn,$t="__reactContainer$"+fn,Oa="__reactEvents$"+fn,Cp="__reactListeners$"+fn,Ap="__reactHandles$"+fn;function jr(e){var t=e[Tt];if(t)return t;for(var r=e.parentNode;r;){if(t=r[$t]||r[Tt]){if(r=t.alternate,t.child!==null||r!==null&&r.child!==null)for(e=Do(e);e!==null;){if(r=e[Tt])return r;e=Do(e)}return t}e=r,r=e.parentNode}return null}function ds(e){return e=e[Tt]||e[$t],!e||e.tag!==5&&e.tag!==6&&e.tag!==13&&e.tag!==3?null:e}function Hr(e){if(e.tag===5||e.tag===6)return e.stateNode;throw Error(I(33))}function vl(e){return e[Qn]||null}var Da=[],Gr=-1;function fr(e){return{current:e}}function ue(e){0>Gr||(e.current=Da[Gr],Da[Gr]=null,Gr--)}function le(e,t){Gr++,Da[Gr]=e.current,e.current=t}var mr={},ze=fr(mr),Ye=fr(!1),kr=mr;function nn(e,t){var r=e.type.contextTypes;if(!r)return mr;var s=e.stateNode;if(s&&s.__reactInternalMemoizedUnmaskedChildContext===t)return s.__reactInternalMemoizedMaskedChildContext;var l={},a;for(a in r)l[a]=t[a];return s&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=l),l}function Je(e){return e=e.childContextTypes,e!=null}function qs(){ue(Ye),ue(ze)}function Po(e,t,r){if(ze.current!==mr)throw Error(I(168));le(ze,t),le(Ye,r)}function Sd(e,t,r){var s=e.stateNode;if(t=t.childContextTypes,typeof s.getChildContext!="function")return r;s=s.getChildContext();for(var l in s)if(!(l in t))throw Error(I(108,mm(e)||"Unknown",l));return ve({},r,s)}function Xs(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||mr,kr=ze.current,le(ze,e),le(Ye,Ye.current),!0}function Lo(e,t,r){var s=e.stateNode;if(!s)throw Error(I(169));r?(e=Sd(e,t,kr),s.__reactInternalMemoizedMergedChildContext=e,ue(Ye),ue(ze),le(ze,e)):ue(Ye),le(Ye,r)}var _t=null,Nl=!1,Yl=!1;function kd(e){_t===null?_t=[e]:_t.push(e)}function Tp(e){Nl=!0,kd(e)}function xr(){if(!Yl&&_t!==null){Yl=!0;var e=0,t=re;try{var r=_t;for(re=1;e<r.length;e++){var s=r[e];do s=s(!0);while(s!==null)}_t=null,Nl=!1}catch(l){throw _t!==null&&(_t=_t.slice(e+1)),qc(hi,xr),l}finally{re=t,Yl=!1}}return null}var Br=[],Wr=0,Zs=null,el=0,dt=[],ut=0,Cr=null,Mt=1,Ut="";function vr(e,t){Br[Wr++]=el,Br[Wr++]=Zs,Zs=e,el=t}function Cd(e,t,r){dt[ut++]=Mt,dt[ut++]=Ut,dt[ut++]=Cr,Cr=e;var s=Mt;e=Ut;var l=32-Et(s)-1;s&=~(1<<l),r+=1;var a=32-Et(t)+l;if(30<a){var i=l-l%5;a=(s&(1<<i)-1).toString(32),s>>=i,l-=i,Mt=1<<32-Et(t)+l|r<<l|s,Ut=a+e}else Mt=1<<a|r<<l|s,Ut=e}function Si(e){e.return!==null&&(vr(e,1),Cd(e,1,0))}function ki(e){for(;e===Zs;)Zs=Br[--Wr],Br[Wr]=null,el=Br[--Wr],Br[Wr]=null;for(;e===Cr;)Cr=dt[--ut],dt[ut]=null,Ut=dt[--ut],dt[ut]=null,Mt=dt[--ut],dt[ut]=null}var rt=null,tt=null,fe=!1,wt=null;function Ad(e,t){var r=mt(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 _o(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,rt=e,tt=lr(t.firstChild),!0):!1;case 6:return t=e.pendingProps===""||t.nodeType!==3?null:t,t!==null?(e.stateNode=t,rt=e,tt=null,!0):!1;case 13:return t=t.nodeType!==8?null:t,t!==null?(r=Cr!==null?{id:Mt,overflow:Ut}:null,e.memoizedState={dehydrated:t,treeContext:r,retryLane:1073741824},r=mt(18,null,null,0),r.stateNode=t,r.return=e,e.child=r,rt=e,tt=null,!0):!1;default:return!1}}function Pa(e){return(e.mode&1)!==0&&(e.flags&128)===0}function La(e){if(fe){var t=tt;if(t){var r=t;if(!_o(e,t)){if(Pa(e))throw Error(I(418));t=lr(r.nextSibling);var s=rt;t&&_o(e,t)?Ad(s,r):(e.flags=e.flags&-4097|2,fe=!1,rt=e)}}else{if(Pa(e))throw Error(I(418));e.flags=e.flags&-4097|2,fe=!1,rt=e}}}function Mo(e){for(e=e.return;e!==null&&e.tag!==5&&e.tag!==3&&e.tag!==13;)e=e.return;rt=e}function Es(e){if(e!==rt)return!1;if(!fe)return Mo(e),fe=!0,!1;var t;if((t=e.tag!==3)&&!(t=e.tag!==5)&&(t=e.type,t=t!=="head"&&t!=="body"&&!Ra(e.type,e.memoizedProps)),t&&(t=tt)){if(Pa(e))throw Td(),Error(I(418));for(;t;)Ad(e,t),t=lr(t.nextSibling)}if(Mo(e),e.tag===13){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(I(317));e:{for(e=e.nextSibling,t=0;e;){if(e.nodeType===8){var r=e.data;if(r==="/$"){if(t===0){tt=lr(e.nextSibling);break e}t--}else r!=="$"&&r!=="$!"&&r!=="$?"||t++}e=e.nextSibling}tt=null}}else tt=rt?lr(e.stateNode.nextSibling):null;return!0}function Td(){for(var e=tt;e;)e=lr(e.nextSibling)}function sn(){tt=rt=null,fe=!1}function Ci(e){wt===null?wt=[e]:wt.push(e)}var Rp=Gt.ReactCurrentBatchConfig;function bn(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(I(309));var s=r.stateNode}if(!s)throw Error(I(147,e));var l=s,a=""+e;return t!==null&&t.ref!==null&&typeof t.ref=="function"&&t.ref._stringRef===a?t.ref:(t=function(i){var o=l.refs;i===null?delete o[a]:o[a]=i},t._stringRef=a,t)}if(typeof e!="string")throw Error(I(284));if(!r._owner)throw Error(I(290,e))}return e}function bs(e,t){throw e=Object.prototype.toString.call(t),Error(I(31,e==="[object Object]"?"object with keys {"+Object.keys(t).join(", ")+"}":e))}function Uo(e){var t=e._init;return t(e._payload)}function Rd(e){function t(m,u){if(e){var p=m.deletions;p===null?(m.deletions=[u],m.flags|=16):p.push(u)}}function r(m,u){if(!e)return null;for(;u!==null;)t(m,u),u=u.sibling;return null}function s(m,u){for(m=new Map;u!==null;)u.key!==null?m.set(u.key,u):m.set(u.index,u),u=u.sibling;return m}function l(m,u){return m=cr(m,u),m.index=0,m.sibling=null,m}function a(m,u,p){return m.index=p,e?(p=m.alternate,p!==null?(p=p.index,p<u?(m.flags|=2,u):p):(m.flags|=2,u)):(m.flags|=1048576,u)}function i(m){return e&&m.alternate===null&&(m.flags|=2),m}function o(m,u,p,j){return u===null||u.tag!==6?(u=ta(p,m.mode,j),u.return=m,u):(u=l(u,p),u.return=m,u)}function c(m,u,p,j){var S=p.type;return S===Fr?f(m,u,p.props.children,j,p.key):u!==null&&(u.elementType===S||typeof S=="object"&&S!==null&&S.$$typeof===Qt&&Uo(S)===u.type)?(j=l(u,p.props),j.ref=bn(m,u,p),j.return=m,j):(j=$s(p.type,p.key,p.props,null,m.mode,j),j.ref=bn(m,u,p),j.return=m,j)}function d(m,u,p,j){return u===null||u.tag!==4||u.stateNode.containerInfo!==p.containerInfo||u.stateNode.implementation!==p.implementation?(u=ra(p,m.mode,j),u.return=m,u):(u=l(u,p.children||[]),u.return=m,u)}function f(m,u,p,j,S){return u===null||u.tag!==7?(u=Sr(p,m.mode,j,S),u.return=m,u):(u=l(u,p),u.return=m,u)}function g(m,u,p){if(typeof u=="string"&&u!==""||typeof u=="number")return u=ta(""+u,m.mode,p),u.return=m,u;if(typeof u=="object"&&u!==null){switch(u.$$typeof){case ps:return p=$s(u.type,u.key,u.props,null,m.mode,p),p.ref=bn(m,null,u),p.return=m,p;case Ur:return u=ra(u,m.mode,p),u.return=m,u;case Qt:var j=u._init;return g(m,j(u._payload),p)}if(An(u)||vn(u))return u=Sr(u,m.mode,p,null),u.return=m,u;bs(m,u)}return null}function h(m,u,p,j){var S=u!==null?u.key:null;if(typeof p=="string"&&p!==""||typeof p=="number")return S!==null?null:o(m,u,""+p,j);if(typeof p=="object"&&p!==null){switch(p.$$typeof){case ps:return p.key===S?c(m,u,p,j):null;case Ur:return p.key===S?d(m,u,p,j):null;case Qt:return S=p._init,h(m,u,S(p._payload),j)}if(An(p)||vn(p))return S!==null?null:f(m,u,p,j,null);bs(m,p)}return null}function x(m,u,p,j,S){if(typeof j=="string"&&j!==""||typeof j=="number")return m=m.get(p)||null,o(u,m,""+j,S);if(typeof j=="object"&&j!==null){switch(j.$$typeof){case ps:return m=m.get(j.key===null?p:j.key)||null,c(u,m,j,S);case Ur:return m=m.get(j.key===null?p:j.key)||null,d(u,m,j,S);case Qt:var R=j._init;return x(m,u,p,R(j._payload),S)}if(An(j)||vn(j))return m=m.get(p)||null,f(u,m,j,S,null);bs(u,j)}return null}function N(m,u,p,j){for(var S=null,R=null,y=u,T=u=0,P=null;y!==null&&T<p.length;T++){y.index>T?(P=y,y=null):P=y.sibling;var C=h(m,y,p[T],j);if(C===null){y===null&&(y=P);break}e&&y&&C.alternate===null&&t(m,y),u=a(C,u,T),R===null?S=C:R.sibling=C,R=C,y=P}if(T===p.length)return r(m,y),fe&&vr(m,T),S;if(y===null){for(;T<p.length;T++)y=g(m,p[T],j),y!==null&&(u=a(y,u,T),R===null?S=y:R.sibling=y,R=y);return fe&&vr(m,T),S}for(y=s(m,y);T<p.length;T++)P=x(y,m,T,p[T],j),P!==null&&(e&&P.alternate!==null&&y.delete(P.key===null?T:P.key),u=a(P,u,T),R===null?S=P:R.sibling=P,R=P);return e&&y.forEach(function(L){return t(m,L)}),fe&&vr(m,T),S}function E(m,u,p,j){var S=vn(p);if(typeof S!="function")throw Error(I(150));if(p=S.call(p),p==null)throw Error(I(151));for(var R=S=null,y=u,T=u=0,P=null,C=p.next();y!==null&&!C.done;T++,C=p.next()){y.index>T?(P=y,y=null):P=y.sibling;var L=h(m,y,C.value,j);if(L===null){y===null&&(y=P);break}e&&y&&L.alternate===null&&t(m,y),u=a(L,u,T),R===null?S=L:R.sibling=L,R=L,y=P}if(C.done)return r(m,y),fe&&vr(m,T),S;if(y===null){for(;!C.done;T++,C=p.next())C=g(m,C.value,j),C!==null&&(u=a(C,u,T),R===null?S=C:R.sibling=C,R=C);return fe&&vr(m,T),S}for(y=s(m,y);!C.done;T++,C=p.next())C=x(y,m,T,C.value,j),C!==null&&(e&&C.alternate!==null&&y.delete(C.key===null?T:C.key),u=a(C,u,T),R===null?S=C:R.sibling=C,R=C);return e&&y.forEach(function(D){return t(m,D)}),fe&&vr(m,T),S}function b(m,u,p,j){if(typeof p=="object"&&p!==null&&p.type===Fr&&p.key===null&&(p=p.props.children),typeof p=="object"&&p!==null){switch(p.$$typeof){case ps:e:{for(var S=p.key,R=u;R!==null;){if(R.key===S){if(S=p.type,S===Fr){if(R.tag===7){r(m,R.sibling),u=l(R,p.props.children),u.return=m,m=u;break e}}else if(R.elementType===S||typeof S=="object"&&S!==null&&S.$$typeof===Qt&&Uo(S)===R.type){r(m,R.sibling),u=l(R,p.props),u.ref=bn(m,R,p),u.return=m,m=u;break e}r(m,R);break}else t(m,R);R=R.sibling}p.type===Fr?(u=Sr(p.props.children,m.mode,j,p.key),u.return=m,m=u):(j=$s(p.type,p.key,p.props,null,m.mode,j),j.ref=bn(m,u,p),j.return=m,m=j)}return i(m);case Ur:e:{for(R=p.key;u!==null;){if(u.key===R)if(u.tag===4&&u.stateNode.containerInfo===p.containerInfo&&u.stateNode.implementation===p.implementation){r(m,u.sibling),u=l(u,p.children||[]),u.return=m,m=u;break e}else{r(m,u);break}else t(m,u);u=u.sibling}u=ra(p,m.mode,j),u.return=m,m=u}return i(m);case Qt:return R=p._init,b(m,u,R(p._payload),j)}if(An(p))return N(m,u,p,j);if(vn(p))return E(m,u,p,j);bs(m,p)}return typeof p=="string"&&p!==""||typeof p=="number"?(p=""+p,u!==null&&u.tag===6?(r(m,u.sibling),u=l(u,p),u.return=m,m=u):(r(m,u),u=ta(p,m.mode,j),u.return=m,m=u),i(m)):r(m,u)}return b}var ln=Rd(!0),Id=Rd(!1),tl=fr(null),rl=null,Kr=null,Ai=null;function Ti(){Ai=Kr=rl=null}function Ri(e){var t=tl.current;ue(tl),e._currentValue=t}function _a(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 en(e,t){rl=e,Ai=Kr=null,e=e.dependencies,e!==null&&e.firstContext!==null&&(e.lanes&t&&(Ke=!0),e.firstContext=null)}function xt(e){var t=e._currentValue;if(Ai!==e)if(e={context:e,memoizedValue:t,next:null},Kr===null){if(rl===null)throw Error(I(308));Kr=e,rl.dependencies={lanes:0,firstContext:e}}else Kr=Kr.next=e;return t}var wr=null;function Ii(e){wr===null?wr=[e]:wr.push(e)}function Od(e,t,r,s){var l=t.interleaved;return l===null?(r.next=r,Ii(t)):(r.next=l.next,l.next=r),t.interleaved=r,Vt(e,s)}function Vt(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 qt=!1;function Oi(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function Dd(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 Ft(e,t){return{eventTime:e,lane:t,tag:0,payload:null,callback:null,next:null}}function ar(e,t,r){var s=e.updateQueue;if(s===null)return null;if(s=s.shared,X&2){var l=s.pending;return l===null?t.next=t:(t.next=l.next,l.next=t),s.pending=t,Vt(e,r)}return l=s.interleaved,l===null?(t.next=t,Ii(s)):(t.next=l.next,l.next=t),s.interleaved=t,Vt(e,r)}function Ls(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,gi(e,r)}}function Fo(e,t){var r=e.updateQueue,s=e.alternate;if(s!==null&&(s=s.updateQueue,r===s)){var l=null,a=null;if(r=r.firstBaseUpdate,r!==null){do{var i={eventTime:r.eventTime,lane:r.lane,tag:r.tag,payload:r.payload,callback:r.callback,next:null};a===null?l=a=i:a=a.next=i,r=r.next}while(r!==null);a===null?l=a=t:a=a.next=t}else l=a=t;r={baseState:s.baseState,firstBaseUpdate:l,lastBaseUpdate:a,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 nl(e,t,r,s){var l=e.updateQueue;qt=!1;var a=l.firstBaseUpdate,i=l.lastBaseUpdate,o=l.shared.pending;if(o!==null){l.shared.pending=null;var c=o,d=c.next;c.next=null,i===null?a=d:i.next=d,i=c;var f=e.alternate;f!==null&&(f=f.updateQueue,o=f.lastBaseUpdate,o!==i&&(o===null?f.firstBaseUpdate=d:o.next=d,f.lastBaseUpdate=c))}if(a!==null){var g=l.baseState;i=0,f=d=c=null,o=a;do{var h=o.lane,x=o.eventTime;if((s&h)===h){f!==null&&(f=f.next={eventTime:x,lane:0,tag:o.tag,payload:o.payload,callback:o.callback,next:null});e:{var N=e,E=o;switch(h=t,x=r,E.tag){case 1:if(N=E.payload,typeof N=="function"){g=N.call(x,g,h);break e}g=N;break e;case 3:N.flags=N.flags&-65537|128;case 0:if(N=E.payload,h=typeof N=="function"?N.call(x,g,h):N,h==null)break e;g=ve({},g,h);break e;case 2:qt=!0}}o.callback!==null&&o.lane!==0&&(e.flags|=64,h=l.effects,h===null?l.effects=[o]:h.push(o))}else x={eventTime:x,lane:h,tag:o.tag,payload:o.payload,callback:o.callback,next:null},f===null?(d=f=x,c=g):f=f.next=x,i|=h;if(o=o.next,o===null){if(o=l.shared.pending,o===null)break;h=o,o=h.next,h.next=null,l.lastBaseUpdate=h,l.shared.pending=null}}while(!0);if(f===null&&(c=g),l.baseState=c,l.firstBaseUpdate=d,l.lastBaseUpdate=f,t=l.shared.interleaved,t!==null){l=t;do i|=l.lane,l=l.next;while(l!==t)}else a===null&&(l.shared.lanes=0);Tr|=i,e.lanes=i,e.memoizedState=g}}function zo(e,t,r){if(e=t.effects,t.effects=null,e!==null)for(t=0;t<e.length;t++){var s=e[t],l=s.callback;if(l!==null){if(s.callback=null,s=r,typeof l!="function")throw Error(I(191,l));l.call(s)}}}var us={},It=fr(us),qn=fr(us),Xn=fr(us);function Er(e){if(e===us)throw Error(I(174));return e}function Di(e,t){switch(le(Xn,t),le(qn,e),le(It,us),e=t.nodeType,e){case 9:case 11:t=(t=t.documentElement)?t.namespaceURI:ha(null,"");break;default:e=e===8?t.parentNode:t,t=e.namespaceURI||null,e=e.tagName,t=ha(t,e)}ue(It),le(It,t)}function an(){ue(It),ue(qn),ue(Xn)}function Pd(e){Er(Xn.current);var t=Er(It.current),r=ha(t,e.type);t!==r&&(le(qn,e),le(It,r))}function Pi(e){qn.current===e&&(ue(It),ue(qn))}var ge=fr(0);function sl(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 Jl=[];function Li(){for(var e=0;e<Jl.length;e++)Jl[e]._workInProgressVersionPrimary=null;Jl.length=0}var _s=Gt.ReactCurrentDispatcher,Ql=Gt.ReactCurrentBatchConfig,Ar=0,ye=null,Se=null,Ce=null,ll=!1,_n=!1,Zn=0,Ip=0;function Me(){throw Error(I(321))}function _i(e,t){if(t===null)return!1;for(var r=0;r<t.length&&r<e.length;r++)if(!St(e[r],t[r]))return!1;return!0}function Mi(e,t,r,s,l,a){if(Ar=a,ye=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,_s.current=e===null||e.memoizedState===null?Lp:_p,e=r(s,l),_n){a=0;do{if(_n=!1,Zn=0,25<=a)throw Error(I(301));a+=1,Ce=Se=null,t.updateQueue=null,_s.current=Mp,e=r(s,l)}while(_n)}if(_s.current=al,t=Se!==null&&Se.next!==null,Ar=0,Ce=Se=ye=null,ll=!1,t)throw Error(I(300));return e}function Ui(){var e=Zn!==0;return Zn=0,e}function At(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return Ce===null?ye.memoizedState=Ce=e:Ce=Ce.next=e,Ce}function ht(){if(Se===null){var e=ye.alternate;e=e!==null?e.memoizedState:null}else e=Se.next;var t=Ce===null?ye.memoizedState:Ce.next;if(t!==null)Ce=t,Se=e;else{if(e===null)throw Error(I(310));Se=e,e={memoizedState:Se.memoizedState,baseState:Se.baseState,baseQueue:Se.baseQueue,queue:Se.queue,next:null},Ce===null?ye.memoizedState=Ce=e:Ce=Ce.next=e}return Ce}function es(e,t){return typeof t=="function"?t(e):t}function ql(e){var t=ht(),r=t.queue;if(r===null)throw Error(I(311));r.lastRenderedReducer=e;var s=Se,l=s.baseQueue,a=r.pending;if(a!==null){if(l!==null){var i=l.next;l.next=a.next,a.next=i}s.baseQueue=l=a,r.pending=null}if(l!==null){a=l.next,s=s.baseState;var o=i=null,c=null,d=a;do{var f=d.lane;if((Ar&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 g={lane:f,action:d.action,hasEagerState:d.hasEagerState,eagerState:d.eagerState,next:null};c===null?(o=c=g,i=s):c=c.next=g,ye.lanes|=f,Tr|=f}d=d.next}while(d!==null&&d!==a);c===null?i=s:c.next=o,St(s,t.memoizedState)||(Ke=!0),t.memoizedState=s,t.baseState=i,t.baseQueue=c,r.lastRenderedState=s}if(e=r.interleaved,e!==null){l=e;do a=l.lane,ye.lanes|=a,Tr|=a,l=l.next;while(l!==e)}else l===null&&(r.lanes=0);return[t.memoizedState,r.dispatch]}function Xl(e){var t=ht(),r=t.queue;if(r===null)throw Error(I(311));r.lastRenderedReducer=e;var s=r.dispatch,l=r.pending,a=t.memoizedState;if(l!==null){r.pending=null;var i=l=l.next;do a=e(a,i.action),i=i.next;while(i!==l);St(a,t.memoizedState)||(Ke=!0),t.memoizedState=a,t.baseQueue===null&&(t.baseState=a),r.lastRenderedState=a}return[a,s]}function Ld(){}function _d(e,t){var r=ye,s=ht(),l=t(),a=!St(s.memoizedState,l);if(a&&(s.memoizedState=l,Ke=!0),s=s.queue,Fi(Fd.bind(null,r,s,e),[e]),s.getSnapshot!==t||a||Ce!==null&&Ce.memoizedState.tag&1){if(r.flags|=2048,ts(9,Ud.bind(null,r,s,l,t),void 0,null),Ae===null)throw Error(I(349));Ar&30||Md(r,t,l)}return l}function Md(e,t,r){e.flags|=16384,e={getSnapshot:t,value:r},t=ye.updateQueue,t===null?(t={lastEffect:null,stores:null},ye.updateQueue=t,t.stores=[e]):(r=t.stores,r===null?t.stores=[e]:r.push(e))}function Ud(e,t,r,s){t.value=r,t.getSnapshot=s,zd(t)&&$d(e)}function Fd(e,t,r){return r(function(){zd(t)&&$d(e)})}function zd(e){var t=e.getSnapshot;e=e.value;try{var r=t();return!St(e,r)}catch{return!0}}function $d(e){var t=Vt(e,1);t!==null&&bt(t,e,1,-1)}function $o(e){var t=At();return typeof e=="function"&&(e=e()),t.memoizedState=t.baseState=e,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:es,lastRenderedState:e},t.queue=e,e=e.dispatch=Pp.bind(null,ye,e),[t.memoizedState,e]}function ts(e,t,r,s){return e={tag:e,create:t,destroy:r,deps:s,next:null},t=ye.updateQueue,t===null?(t={lastEffect:null,stores:null},ye.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 Vd(){return ht().memoizedState}function Ms(e,t,r,s){var l=At();ye.flags|=e,l.memoizedState=ts(1|t,r,void 0,s===void 0?null:s)}function jl(e,t,r,s){var l=ht();s=s===void 0?null:s;var a=void 0;if(Se!==null){var i=Se.memoizedState;if(a=i.destroy,s!==null&&_i(s,i.deps)){l.memoizedState=ts(t,r,a,s);return}}ye.flags|=e,l.memoizedState=ts(1|t,r,a,s)}function Vo(e,t){return Ms(8390656,8,e,t)}function Fi(e,t){return jl(2048,8,e,t)}function Hd(e,t){return jl(4,2,e,t)}function Gd(e,t){return jl(4,4,e,t)}function Bd(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 Wd(e,t,r){return r=r!=null?r.concat([e]):null,jl(4,4,Bd.bind(null,t,e),r)}function zi(){}function Kd(e,t){var r=ht();t=t===void 0?null:t;var s=r.memoizedState;return s!==null&&t!==null&&_i(t,s[1])?s[0]:(r.memoizedState=[e,t],e)}function Yd(e,t){var r=ht();t=t===void 0?null:t;var s=r.memoizedState;return s!==null&&t!==null&&_i(t,s[1])?s[0]:(e=e(),r.memoizedState=[e,t],e)}function Jd(e,t,r){return Ar&21?(St(r,t)||(r=ed(),ye.lanes|=r,Tr|=r,e.baseState=!0),t):(e.baseState&&(e.baseState=!1,Ke=!0),e.memoizedState=r)}function Op(e,t){var r=re;re=r!==0&&4>r?r:4,e(!0);var s=Ql.transition;Ql.transition={};try{e(!1),t()}finally{re=r,Ql.transition=s}}function Qd(){return ht().memoizedState}function Dp(e,t,r){var s=or(e);if(r={lane:s,action:r,hasEagerState:!1,eagerState:null,next:null},qd(e))Xd(t,r);else if(r=Od(e,t,r,s),r!==null){var l=He();bt(r,e,s,l),Zd(r,t,s)}}function Pp(e,t,r){var s=or(e),l={lane:s,action:r,hasEagerState:!1,eagerState:null,next:null};if(qd(e))Xd(t,l);else{var a=e.alternate;if(e.lanes===0&&(a===null||a.lanes===0)&&(a=t.lastRenderedReducer,a!==null))try{var i=t.lastRenderedState,o=a(i,r);if(l.hasEagerState=!0,l.eagerState=o,St(o,i)){var c=t.interleaved;c===null?(l.next=l,Ii(t)):(l.next=c.next,c.next=l),t.interleaved=l;return}}catch{}finally{}r=Od(e,t,l,s),r!==null&&(l=He(),bt(r,e,s,l),Zd(r,t,s))}}function qd(e){var t=e.alternate;return e===ye||t!==null&&t===ye}function Xd(e,t){_n=ll=!0;var r=e.pending;r===null?t.next=t:(t.next=r.next,r.next=t),e.pending=t}function Zd(e,t,r){if(r&4194240){var s=t.lanes;s&=e.pendingLanes,r|=s,t.lanes=r,gi(e,r)}}var al={readContext:xt,useCallback:Me,useContext:Me,useEffect:Me,useImperativeHandle:Me,useInsertionEffect:Me,useLayoutEffect:Me,useMemo:Me,useReducer:Me,useRef:Me,useState:Me,useDebugValue:Me,useDeferredValue:Me,useTransition:Me,useMutableSource:Me,useSyncExternalStore:Me,useId:Me,unstable_isNewReconciler:!1},Lp={readContext:xt,useCallback:function(e,t){return At().memoizedState=[e,t===void 0?null:t],e},useContext:xt,useEffect:Vo,useImperativeHandle:function(e,t,r){return r=r!=null?r.concat([e]):null,Ms(4194308,4,Bd.bind(null,t,e),r)},useLayoutEffect:function(e,t){return Ms(4194308,4,e,t)},useInsertionEffect:function(e,t){return Ms(4,2,e,t)},useMemo:function(e,t){var r=At();return t=t===void 0?null:t,e=e(),r.memoizedState=[e,t],e},useReducer:function(e,t,r){var s=At();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=Dp.bind(null,ye,e),[s.memoizedState,e]},useRef:function(e){var t=At();return e={current:e},t.memoizedState=e},useState:$o,useDebugValue:zi,useDeferredValue:function(e){return At().memoizedState=e},useTransition:function(){var e=$o(!1),t=e[0];return e=Op.bind(null,e[1]),At().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,r){var s=ye,l=At();if(fe){if(r===void 0)throw Error(I(407));r=r()}else{if(r=t(),Ae===null)throw Error(I(349));Ar&30||Md(s,t,r)}l.memoizedState=r;var a={value:r,getSnapshot:t};return l.queue=a,Vo(Fd.bind(null,s,a,e),[e]),s.flags|=2048,ts(9,Ud.bind(null,s,a,r,t),void 0,null),r},useId:function(){var e=At(),t=Ae.identifierPrefix;if(fe){var r=Ut,s=Mt;r=(s&~(1<<32-Et(s)-1)).toString(32)+r,t=":"+t+"R"+r,r=Zn++,0<r&&(t+="H"+r.toString(32)),t+=":"}else r=Ip++,t=":"+t+"r"+r.toString(32)+":";return e.memoizedState=t},unstable_isNewReconciler:!1},_p={readContext:xt,useCallback:Kd,useContext:xt,useEffect:Fi,useImperativeHandle:Wd,useInsertionEffect:Hd,useLayoutEffect:Gd,useMemo:Yd,useReducer:ql,useRef:Vd,useState:function(){return ql(es)},useDebugValue:zi,useDeferredValue:function(e){var t=ht();return Jd(t,Se.memoizedState,e)},useTransition:function(){var e=ql(es)[0],t=ht().memoizedState;return[e,t]},useMutableSource:Ld,useSyncExternalStore:_d,useId:Qd,unstable_isNewReconciler:!1},Mp={readContext:xt,useCallback:Kd,useContext:xt,useEffect:Fi,useImperativeHandle:Wd,useInsertionEffect:Hd,useLayoutEffect:Gd,useMemo:Yd,useReducer:Xl,useRef:Vd,useState:function(){return Xl(es)},useDebugValue:zi,useDeferredValue:function(e){var t=ht();return Se===null?t.memoizedState=e:Jd(t,Se.memoizedState,e)},useTransition:function(){var e=Xl(es)[0],t=ht().memoizedState;return[e,t]},useMutableSource:Ld,useSyncExternalStore:_d,useId:Qd,unstable_isNewReconciler:!1};function Nt(e,t){if(e&&e.defaultProps){t=ve({},t),e=e.defaultProps;for(var r in e)t[r]===void 0&&(t[r]=e[r]);return t}return t}function Ma(e,t,r,s){t=e.memoizedState,r=r(s,t),r=r==null?t:ve({},t,r),e.memoizedState=r,e.lanes===0&&(e.updateQueue.baseState=r)}var wl={isMounted:function(e){return(e=e._reactInternals)?Or(e)===e:!1},enqueueSetState:function(e,t,r){e=e._reactInternals;var s=He(),l=or(e),a=Ft(s,l);a.payload=t,r!=null&&(a.callback=r),t=ar(e,a,l),t!==null&&(bt(t,e,l,s),Ls(t,e,l))},enqueueReplaceState:function(e,t,r){e=e._reactInternals;var s=He(),l=or(e),a=Ft(s,l);a.tag=1,a.payload=t,r!=null&&(a.callback=r),t=ar(e,a,l),t!==null&&(bt(t,e,l,s),Ls(t,e,l))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var r=He(),s=or(e),l=Ft(r,s);l.tag=2,t!=null&&(l.callback=t),t=ar(e,l,s),t!==null&&(bt(t,e,s,r),Ls(t,e,s))}};function Ho(e,t,r,s,l,a,i){return e=e.stateNode,typeof e.shouldComponentUpdate=="function"?e.shouldComponentUpdate(s,a,i):t.prototype&&t.prototype.isPureReactComponent?!Kn(r,s)||!Kn(l,a):!0}function eu(e,t,r){var s=!1,l=mr,a=t.contextType;return typeof a=="object"&&a!==null?a=xt(a):(l=Je(t)?kr:ze.current,s=t.contextTypes,a=(s=s!=null)?nn(e,l):mr),t=new t(r,a),e.memoizedState=t.state!==null&&t.state!==void 0?t.state:null,t.updater=wl,e.stateNode=t,t._reactInternals=e,s&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=l,e.__reactInternalMemoizedMaskedChildContext=a),t}function Go(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&&wl.enqueueReplaceState(t,t.state,null)}function Ua(e,t,r,s){var l=e.stateNode;l.props=r,l.state=e.memoizedState,l.refs={},Oi(e);var a=t.contextType;typeof a=="object"&&a!==null?l.context=xt(a):(a=Je(t)?kr:ze.current,l.context=nn(e,a)),l.state=e.memoizedState,a=t.getDerivedStateFromProps,typeof a=="function"&&(Ma(e,t,a,r),l.state=e.memoizedState),typeof t.getDerivedStateFromProps=="function"||typeof l.getSnapshotBeforeUpdate=="function"||typeof l.UNSAFE_componentWillMount!="function"&&typeof l.componentWillMount!="function"||(t=l.state,typeof l.componentWillMount=="function"&&l.componentWillMount(),typeof l.UNSAFE_componentWillMount=="function"&&l.UNSAFE_componentWillMount(),t!==l.state&&wl.enqueueReplaceState(l,l.state,null),nl(e,r,l,s),l.state=e.memoizedState),typeof l.componentDidMount=="function"&&(e.flags|=4194308)}function on(e,t){try{var r="",s=t;do r+=um(s),s=s.return;while(s);var l=r}catch(a){l=`
|
|
39
|
-
Error generating stack: `+a.message+`
|
|
40
|
-
`+a.stack}return{value:e,source:t,stack:l,digest:null}}function Zl(e,t,r){return{value:e,source:null,stack:r??null,digest:t??null}}function Fa(e,t){try{console.error(t.value)}catch(r){setTimeout(function(){throw r})}}var Up=typeof WeakMap=="function"?WeakMap:Map;function tu(e,t,r){r=Ft(-1,r),r.tag=3,r.payload={element:null};var s=t.value;return r.callback=function(){ol||(ol=!0,Ja=s),Fa(e,t)},r}function ru(e,t,r){r=Ft(-1,r),r.tag=3;var s=e.type.getDerivedStateFromError;if(typeof s=="function"){var l=t.value;r.payload=function(){return s(l)},r.callback=function(){Fa(e,t)}}var a=e.stateNode;return a!==null&&typeof a.componentDidCatch=="function"&&(r.callback=function(){Fa(e,t),typeof s!="function"&&(ir===null?ir=new Set([this]):ir.add(this));var i=t.stack;this.componentDidCatch(t.value,{componentStack:i!==null?i:""})}),r}function Bo(e,t,r){var s=e.pingCache;if(s===null){s=e.pingCache=new Up;var l=new Set;s.set(t,l)}else l=s.get(t),l===void 0&&(l=new Set,s.set(t,l));l.has(r)||(l.add(r),e=Xp.bind(null,e,t,r),t.then(e,e))}function Wo(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 Ko(e,t,r,s,l){return e.mode&1?(e.flags|=65536,e.lanes=l,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=Ft(-1,1),t.tag=2,ar(r,t,1))),r.lanes|=1),e)}var Fp=Gt.ReactCurrentOwner,Ke=!1;function Ve(e,t,r,s){t.child=e===null?Id(t,null,r,s):ln(t,e.child,r,s)}function Yo(e,t,r,s,l){r=r.render;var a=t.ref;return en(t,l),s=Mi(e,t,r,s,a,l),r=Ui(),e!==null&&!Ke?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~l,Ht(e,t,l)):(fe&&r&&Si(t),t.flags|=1,Ve(e,t,s,l),t.child)}function Jo(e,t,r,s,l){if(e===null){var a=r.type;return typeof a=="function"&&!Yi(a)&&a.defaultProps===void 0&&r.compare===null&&r.defaultProps===void 0?(t.tag=15,t.type=a,nu(e,t,a,s,l)):(e=$s(r.type,null,s,t,t.mode,l),e.ref=t.ref,e.return=t,t.child=e)}if(a=e.child,!(e.lanes&l)){var i=a.memoizedProps;if(r=r.compare,r=r!==null?r:Kn,r(i,s)&&e.ref===t.ref)return Ht(e,t,l)}return t.flags|=1,e=cr(a,s),e.ref=t.ref,e.return=t,t.child=e}function nu(e,t,r,s,l){if(e!==null){var a=e.memoizedProps;if(Kn(a,s)&&e.ref===t.ref)if(Ke=!1,t.pendingProps=s=a,(e.lanes&l)!==0)e.flags&131072&&(Ke=!0);else return t.lanes=e.lanes,Ht(e,t,l)}return za(e,t,r,s,l)}function su(e,t,r){var s=t.pendingProps,l=s.children,a=e!==null?e.memoizedState:null;if(s.mode==="hidden")if(!(t.mode&1))t.memoizedState={baseLanes:0,cachePool:null,transitions:null},le(Jr,Ze),Ze|=r;else{if(!(r&1073741824))return e=a!==null?a.baseLanes|r:r,t.lanes=t.childLanes=1073741824,t.memoizedState={baseLanes:e,cachePool:null,transitions:null},t.updateQueue=null,le(Jr,Ze),Ze|=e,null;t.memoizedState={baseLanes:0,cachePool:null,transitions:null},s=a!==null?a.baseLanes:r,le(Jr,Ze),Ze|=s}else a!==null?(s=a.baseLanes|r,t.memoizedState=null):s=r,le(Jr,Ze),Ze|=s;return Ve(e,t,l,r),t.child}function lu(e,t){var r=t.ref;(e===null&&r!==null||e!==null&&e.ref!==r)&&(t.flags|=512,t.flags|=2097152)}function za(e,t,r,s,l){var a=Je(r)?kr:ze.current;return a=nn(t,a),en(t,l),r=Mi(e,t,r,s,a,l),s=Ui(),e!==null&&!Ke?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~l,Ht(e,t,l)):(fe&&s&&Si(t),t.flags|=1,Ve(e,t,r,l),t.child)}function Qo(e,t,r,s,l){if(Je(r)){var a=!0;Xs(t)}else a=!1;if(en(t,l),t.stateNode===null)Us(e,t),eu(t,r,s),Ua(t,r,s,l),s=!0;else if(e===null){var i=t.stateNode,o=t.memoizedProps;i.props=o;var c=i.context,d=r.contextType;typeof d=="object"&&d!==null?d=xt(d):(d=Je(r)?kr:ze.current,d=nn(t,d));var f=r.getDerivedStateFromProps,g=typeof f=="function"||typeof i.getSnapshotBeforeUpdate=="function";g||typeof i.UNSAFE_componentWillReceiveProps!="function"&&typeof i.componentWillReceiveProps!="function"||(o!==s||c!==d)&&Go(t,i,s,d),qt=!1;var h=t.memoizedState;i.state=h,nl(t,s,i,l),c=t.memoizedState,o!==s||h!==c||Ye.current||qt?(typeof f=="function"&&(Ma(t,r,f,s),c=t.memoizedState),(o=qt||Ho(t,r,o,s,h,c,d))?(g||typeof i.UNSAFE_componentWillMount!="function"&&typeof i.componentWillMount!="function"||(typeof i.componentWillMount=="function"&&i.componentWillMount(),typeof i.UNSAFE_componentWillMount=="function"&&i.UNSAFE_componentWillMount()),typeof i.componentDidMount=="function"&&(t.flags|=4194308)):(typeof i.componentDidMount=="function"&&(t.flags|=4194308),t.memoizedProps=s,t.memoizedState=c),i.props=s,i.state=c,i.context=d,s=o):(typeof i.componentDidMount=="function"&&(t.flags|=4194308),s=!1)}else{i=t.stateNode,Dd(e,t),o=t.memoizedProps,d=t.type===t.elementType?o:Nt(t.type,o),i.props=d,g=t.pendingProps,h=i.context,c=r.contextType,typeof c=="object"&&c!==null?c=xt(c):(c=Je(r)?kr:ze.current,c=nn(t,c));var x=r.getDerivedStateFromProps;(f=typeof x=="function"||typeof i.getSnapshotBeforeUpdate=="function")||typeof i.UNSAFE_componentWillReceiveProps!="function"&&typeof i.componentWillReceiveProps!="function"||(o!==g||h!==c)&&Go(t,i,s,c),qt=!1,h=t.memoizedState,i.state=h,nl(t,s,i,l);var N=t.memoizedState;o!==g||h!==N||Ye.current||qt?(typeof x=="function"&&(Ma(t,r,x,s),N=t.memoizedState),(d=qt||Ho(t,r,d,s,h,N,c)||!1)?(f||typeof i.UNSAFE_componentWillUpdate!="function"&&typeof i.componentWillUpdate!="function"||(typeof i.componentWillUpdate=="function"&&i.componentWillUpdate(s,N,c),typeof i.UNSAFE_componentWillUpdate=="function"&&i.UNSAFE_componentWillUpdate(s,N,c)),typeof i.componentDidUpdate=="function"&&(t.flags|=4),typeof i.getSnapshotBeforeUpdate=="function"&&(t.flags|=1024)):(typeof i.componentDidUpdate!="function"||o===e.memoizedProps&&h===e.memoizedState||(t.flags|=4),typeof i.getSnapshotBeforeUpdate!="function"||o===e.memoizedProps&&h===e.memoizedState||(t.flags|=1024),t.memoizedProps=s,t.memoizedState=N),i.props=s,i.state=N,i.context=c,s=d):(typeof i.componentDidUpdate!="function"||o===e.memoizedProps&&h===e.memoizedState||(t.flags|=4),typeof i.getSnapshotBeforeUpdate!="function"||o===e.memoizedProps&&h===e.memoizedState||(t.flags|=1024),s=!1)}return $a(e,t,r,s,a,l)}function $a(e,t,r,s,l,a){lu(e,t);var i=(t.flags&128)!==0;if(!s&&!i)return l&&Lo(t,r,!1),Ht(e,t,a);s=t.stateNode,Fp.current=t;var o=i&&typeof r.getDerivedStateFromError!="function"?null:s.render();return t.flags|=1,e!==null&&i?(t.child=ln(t,e.child,null,a),t.child=ln(t,null,o,a)):Ve(e,t,o,a),t.memoizedState=s.state,l&&Lo(t,r,!0),t.child}function au(e){var t=e.stateNode;t.pendingContext?Po(e,t.pendingContext,t.pendingContext!==t.context):t.context&&Po(e,t.context,!1),Di(e,t.containerInfo)}function qo(e,t,r,s,l){return sn(),Ci(l),t.flags|=256,Ve(e,t,r,s),t.child}var Va={dehydrated:null,treeContext:null,retryLane:0};function Ha(e){return{baseLanes:e,cachePool:null,transitions:null}}function iu(e,t,r){var s=t.pendingProps,l=ge.current,a=!1,i=(t.flags&128)!==0,o;if((o=i)||(o=e!==null&&e.memoizedState===null?!1:(l&2)!==0),o?(a=!0,t.flags&=-129):(e===null||e.memoizedState!==null)&&(l|=1),le(ge,l&1),e===null)return La(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):(i=s.children,e=s.fallback,a?(s=t.mode,a=t.child,i={mode:"hidden",children:i},!(s&1)&&a!==null?(a.childLanes=0,a.pendingProps=i):a=Sl(i,s,0,null),e=Sr(e,s,r,null),a.return=t,e.return=t,a.sibling=e,t.child=a,t.child.memoizedState=Ha(r),t.memoizedState=Va,e):$i(t,i));if(l=e.memoizedState,l!==null&&(o=l.dehydrated,o!==null))return zp(e,t,i,s,o,l,r);if(a){a=s.fallback,i=t.mode,l=e.child,o=l.sibling;var c={mode:"hidden",children:s.children};return!(i&1)&&t.child!==l?(s=t.child,s.childLanes=0,s.pendingProps=c,t.deletions=null):(s=cr(l,c),s.subtreeFlags=l.subtreeFlags&14680064),o!==null?a=cr(o,a):(a=Sr(a,i,r,null),a.flags|=2),a.return=t,s.return=t,s.sibling=a,t.child=s,s=a,a=t.child,i=e.child.memoizedState,i=i===null?Ha(r):{baseLanes:i.baseLanes|r,cachePool:null,transitions:i.transitions},a.memoizedState=i,a.childLanes=e.childLanes&~r,t.memoizedState=Va,s}return a=e.child,e=a.sibling,s=cr(a,{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 $i(e,t){return t=Sl({mode:"visible",children:t},e.mode,0,null),t.return=e,e.child=t}function Ss(e,t,r,s){return s!==null&&Ci(s),ln(t,e.child,null,r),e=$i(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function zp(e,t,r,s,l,a,i){if(r)return t.flags&256?(t.flags&=-257,s=Zl(Error(I(422))),Ss(e,t,i,s)):t.memoizedState!==null?(t.child=e.child,t.flags|=128,null):(a=s.fallback,l=t.mode,s=Sl({mode:"visible",children:s.children},l,0,null),a=Sr(a,l,i,null),a.flags|=2,s.return=t,a.return=t,s.sibling=a,t.child=s,t.mode&1&&ln(t,e.child,null,i),t.child.memoizedState=Ha(i),t.memoizedState=Va,a);if(!(t.mode&1))return Ss(e,t,i,null);if(l.data==="$!"){if(s=l.nextSibling&&l.nextSibling.dataset,s)var o=s.dgst;return s=o,a=Error(I(419)),s=Zl(a,s,void 0),Ss(e,t,i,s)}if(o=(i&e.childLanes)!==0,Ke||o){if(s=Ae,s!==null){switch(i&-i){case 4:l=2;break;case 16:l=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:l=32;break;case 536870912:l=268435456;break;default:l=0}l=l&(s.suspendedLanes|i)?0:l,l!==0&&l!==a.retryLane&&(a.retryLane=l,Vt(e,l),bt(s,e,l,-1))}return Ki(),s=Zl(Error(I(421))),Ss(e,t,i,s)}return l.data==="$?"?(t.flags|=128,t.child=e.child,t=Zp.bind(null,e),l._reactRetry=t,null):(e=a.treeContext,tt=lr(l.nextSibling),rt=t,fe=!0,wt=null,e!==null&&(dt[ut++]=Mt,dt[ut++]=Ut,dt[ut++]=Cr,Mt=e.id,Ut=e.overflow,Cr=t),t=$i(t,s.children),t.flags|=4096,t)}function Xo(e,t,r){e.lanes|=t;var s=e.alternate;s!==null&&(s.lanes|=t),_a(e.return,t,r)}function ea(e,t,r,s,l){var a=e.memoizedState;a===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:s,tail:r,tailMode:l}:(a.isBackwards=t,a.rendering=null,a.renderingStartTime=0,a.last=s,a.tail=r,a.tailMode=l)}function ou(e,t,r){var s=t.pendingProps,l=s.revealOrder,a=s.tail;if(Ve(e,t,s.children,r),s=ge.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&&Xo(e,r,t);else if(e.tag===19)Xo(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(le(ge,s),!(t.mode&1))t.memoizedState=null;else switch(l){case"forwards":for(r=t.child,l=null;r!==null;)e=r.alternate,e!==null&&sl(e)===null&&(l=r),r=r.sibling;r=l,r===null?(l=t.child,t.child=null):(l=r.sibling,r.sibling=null),ea(t,!1,l,r,a);break;case"backwards":for(r=null,l=t.child,t.child=null;l!==null;){if(e=l.alternate,e!==null&&sl(e)===null){t.child=l;break}e=l.sibling,l.sibling=r,r=l,l=e}ea(t,!0,r,null,a);break;case"together":ea(t,!1,null,null,void 0);break;default:t.memoizedState=null}return t.child}function Us(e,t){!(t.mode&1)&&e!==null&&(e.alternate=null,t.alternate=null,t.flags|=2)}function Ht(e,t,r){if(e!==null&&(t.dependencies=e.dependencies),Tr|=t.lanes,!(r&t.childLanes))return null;if(e!==null&&t.child!==e.child)throw Error(I(153));if(t.child!==null){for(e=t.child,r=cr(e,e.pendingProps),t.child=r,r.return=t;e.sibling!==null;)e=e.sibling,r=r.sibling=cr(e,e.pendingProps),r.return=t;r.sibling=null}return t.child}function $p(e,t,r){switch(t.tag){case 3:au(t),sn();break;case 5:Pd(t);break;case 1:Je(t.type)&&Xs(t);break;case 4:Di(t,t.stateNode.containerInfo);break;case 10:var s=t.type._context,l=t.memoizedProps.value;le(tl,s._currentValue),s._currentValue=l;break;case 13:if(s=t.memoizedState,s!==null)return s.dehydrated!==null?(le(ge,ge.current&1),t.flags|=128,null):r&t.child.childLanes?iu(e,t,r):(le(ge,ge.current&1),e=Ht(e,t,r),e!==null?e.sibling:null);le(ge,ge.current&1);break;case 19:if(s=(r&t.childLanes)!==0,e.flags&128){if(s)return ou(e,t,r);t.flags|=128}if(l=t.memoizedState,l!==null&&(l.rendering=null,l.tail=null,l.lastEffect=null),le(ge,ge.current),s)break;return null;case 22:case 23:return t.lanes=0,su(e,t,r)}return Ht(e,t,r)}var cu,Ga,du,uu;cu=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}};Ga=function(){};du=function(e,t,r,s){var l=e.memoizedProps;if(l!==s){e=t.stateNode,Er(It.current);var a=null;switch(r){case"input":l=ma(e,l),s=ma(e,s),a=[];break;case"select":l=ve({},l,{value:void 0}),s=ve({},s,{value:void 0}),a=[];break;case"textarea":l=xa(e,l),s=xa(e,s),a=[];break;default:typeof l.onClick!="function"&&typeof s.onClick=="function"&&(e.onclick=Qs)}ga(r,s);var i;r=null;for(d in l)if(!s.hasOwnProperty(d)&&l.hasOwnProperty(d)&&l[d]!=null)if(d==="style"){var o=l[d];for(i in o)o.hasOwnProperty(i)&&(r||(r={}),r[i]="")}else d!=="dangerouslySetInnerHTML"&&d!=="children"&&d!=="suppressContentEditableWarning"&&d!=="suppressHydrationWarning"&&d!=="autoFocus"&&(zn.hasOwnProperty(d)?a||(a=[]):(a=a||[]).push(d,null));for(d in s){var c=s[d];if(o=l!=null?l[d]:void 0,s.hasOwnProperty(d)&&c!==o&&(c!=null||o!=null))if(d==="style")if(o){for(i in o)!o.hasOwnProperty(i)||c&&c.hasOwnProperty(i)||(r||(r={}),r[i]="");for(i in c)c.hasOwnProperty(i)&&o[i]!==c[i]&&(r||(r={}),r[i]=c[i])}else r||(a||(a=[]),a.push(d,r)),r=c;else d==="dangerouslySetInnerHTML"?(c=c?c.__html:void 0,o=o?o.__html:void 0,c!=null&&o!==c&&(a=a||[]).push(d,c)):d==="children"?typeof c!="string"&&typeof c!="number"||(a=a||[]).push(d,""+c):d!=="suppressContentEditableWarning"&&d!=="suppressHydrationWarning"&&(zn.hasOwnProperty(d)?(c!=null&&d==="onScroll"&&de("scroll",e),a||o===c||(a=[])):(a=a||[]).push(d,c))}r&&(a=a||[]).push("style",r);var d=a;(t.updateQueue=d)&&(t.flags|=4)}};uu=function(e,t,r,s){r!==s&&(t.flags|=4)};function Sn(e,t){if(!fe)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 Ue(e){var t=e.alternate!==null&&e.alternate.child===e.child,r=0,s=0;if(t)for(var l=e.child;l!==null;)r|=l.lanes|l.childLanes,s|=l.subtreeFlags&14680064,s|=l.flags&14680064,l.return=e,l=l.sibling;else for(l=e.child;l!==null;)r|=l.lanes|l.childLanes,s|=l.subtreeFlags,s|=l.flags,l.return=e,l=l.sibling;return e.subtreeFlags|=s,e.childLanes=r,t}function Vp(e,t,r){var s=t.pendingProps;switch(ki(t),t.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return Ue(t),null;case 1:return Je(t.type)&&qs(),Ue(t),null;case 3:return s=t.stateNode,an(),ue(Ye),ue(ze),Li(),s.pendingContext&&(s.context=s.pendingContext,s.pendingContext=null),(e===null||e.child===null)&&(Es(t)?t.flags|=4:e===null||e.memoizedState.isDehydrated&&!(t.flags&256)||(t.flags|=1024,wt!==null&&(Xa(wt),wt=null))),Ga(e,t),Ue(t),null;case 5:Pi(t);var l=Er(Xn.current);if(r=t.type,e!==null&&t.stateNode!=null)du(e,t,r,s,l),e.ref!==t.ref&&(t.flags|=512,t.flags|=2097152);else{if(!s){if(t.stateNode===null)throw Error(I(166));return Ue(t),null}if(e=Er(It.current),Es(t)){s=t.stateNode,r=t.type;var a=t.memoizedProps;switch(s[Tt]=t,s[Qn]=a,e=(t.mode&1)!==0,r){case"dialog":de("cancel",s),de("close",s);break;case"iframe":case"object":case"embed":de("load",s);break;case"video":case"audio":for(l=0;l<Rn.length;l++)de(Rn[l],s);break;case"source":de("error",s);break;case"img":case"image":case"link":de("error",s),de("load",s);break;case"details":de("toggle",s);break;case"input":ao(s,a),de("invalid",s);break;case"select":s._wrapperState={wasMultiple:!!a.multiple},de("invalid",s);break;case"textarea":oo(s,a),de("invalid",s)}ga(r,a),l=null;for(var i in a)if(a.hasOwnProperty(i)){var o=a[i];i==="children"?typeof o=="string"?s.textContent!==o&&(a.suppressHydrationWarning!==!0&&ws(s.textContent,o,e),l=["children",o]):typeof o=="number"&&s.textContent!==""+o&&(a.suppressHydrationWarning!==!0&&ws(s.textContent,o,e),l=["children",""+o]):zn.hasOwnProperty(i)&&o!=null&&i==="onScroll"&&de("scroll",s)}switch(r){case"input":fs(s),io(s,a,!0);break;case"textarea":fs(s),co(s);break;case"select":case"option":break;default:typeof a.onClick=="function"&&(s.onclick=Qs)}s=l,t.updateQueue=s,s!==null&&(t.flags|=4)}else{i=l.nodeType===9?l:l.ownerDocument,e==="http://www.w3.org/1999/xhtml"&&(e=Fc(r)),e==="http://www.w3.org/1999/xhtml"?r==="script"?(e=i.createElement("div"),e.innerHTML="<script><\/script>",e=e.removeChild(e.firstChild)):typeof s.is=="string"?e=i.createElement(r,{is:s.is}):(e=i.createElement(r),r==="select"&&(i=e,s.multiple?i.multiple=!0:s.size&&(i.size=s.size))):e=i.createElementNS(e,r),e[Tt]=t,e[Qn]=s,cu(e,t,!1,!1),t.stateNode=e;e:{switch(i=ya(r,s),r){case"dialog":de("cancel",e),de("close",e),l=s;break;case"iframe":case"object":case"embed":de("load",e),l=s;break;case"video":case"audio":for(l=0;l<Rn.length;l++)de(Rn[l],e);l=s;break;case"source":de("error",e),l=s;break;case"img":case"image":case"link":de("error",e),de("load",e),l=s;break;case"details":de("toggle",e),l=s;break;case"input":ao(e,s),l=ma(e,s),de("invalid",e);break;case"option":l=s;break;case"select":e._wrapperState={wasMultiple:!!s.multiple},l=ve({},s,{value:void 0}),de("invalid",e);break;case"textarea":oo(e,s),l=xa(e,s),de("invalid",e);break;default:l=s}ga(r,l),o=l;for(a in o)if(o.hasOwnProperty(a)){var c=o[a];a==="style"?Vc(e,c):a==="dangerouslySetInnerHTML"?(c=c?c.__html:void 0,c!=null&&zc(e,c)):a==="children"?typeof c=="string"?(r!=="textarea"||c!=="")&&$n(e,c):typeof c=="number"&&$n(e,""+c):a!=="suppressContentEditableWarning"&&a!=="suppressHydrationWarning"&&a!=="autoFocus"&&(zn.hasOwnProperty(a)?c!=null&&a==="onScroll"&&de("scroll",e):c!=null&&ui(e,a,c,i))}switch(r){case"input":fs(e),io(e,s,!1);break;case"textarea":fs(e),co(e);break;case"option":s.value!=null&&e.setAttribute("value",""+ur(s.value));break;case"select":e.multiple=!!s.multiple,a=s.value,a!=null?Qr(e,!!s.multiple,a,!1):s.defaultValue!=null&&Qr(e,!!s.multiple,s.defaultValue,!0);break;default:typeof l.onClick=="function"&&(e.onclick=Qs)}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 Ue(t),null;case 6:if(e&&t.stateNode!=null)uu(e,t,e.memoizedProps,s);else{if(typeof s!="string"&&t.stateNode===null)throw Error(I(166));if(r=Er(Xn.current),Er(It.current),Es(t)){if(s=t.stateNode,r=t.memoizedProps,s[Tt]=t,(a=s.nodeValue!==r)&&(e=rt,e!==null))switch(e.tag){case 3:ws(s.nodeValue,r,(e.mode&1)!==0);break;case 5:e.memoizedProps.suppressHydrationWarning!==!0&&ws(s.nodeValue,r,(e.mode&1)!==0)}a&&(t.flags|=4)}else s=(r.nodeType===9?r:r.ownerDocument).createTextNode(s),s[Tt]=t,t.stateNode=s}return Ue(t),null;case 13:if(ue(ge),s=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(fe&&tt!==null&&t.mode&1&&!(t.flags&128))Td(),sn(),t.flags|=98560,a=!1;else if(a=Es(t),s!==null&&s.dehydrated!==null){if(e===null){if(!a)throw Error(I(318));if(a=t.memoizedState,a=a!==null?a.dehydrated:null,!a)throw Error(I(317));a[Tt]=t}else sn(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;Ue(t),a=!1}else wt!==null&&(Xa(wt),wt=null),a=!0;if(!a)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||ge.current&1?ke===0&&(ke=3):Ki())),t.updateQueue!==null&&(t.flags|=4),Ue(t),null);case 4:return an(),Ga(e,t),e===null&&Yn(t.stateNode.containerInfo),Ue(t),null;case 10:return Ri(t.type._context),Ue(t),null;case 17:return Je(t.type)&&qs(),Ue(t),null;case 19:if(ue(ge),a=t.memoizedState,a===null)return Ue(t),null;if(s=(t.flags&128)!==0,i=a.rendering,i===null)if(s)Sn(a,!1);else{if(ke!==0||e!==null&&e.flags&128)for(e=t.child;e!==null;){if(i=sl(e),i!==null){for(t.flags|=128,Sn(a,!1),s=i.updateQueue,s!==null&&(t.updateQueue=s,t.flags|=4),t.subtreeFlags=0,s=r,r=t.child;r!==null;)a=r,e=s,a.flags&=14680066,i=a.alternate,i===null?(a.childLanes=0,a.lanes=e,a.child=null,a.subtreeFlags=0,a.memoizedProps=null,a.memoizedState=null,a.updateQueue=null,a.dependencies=null,a.stateNode=null):(a.childLanes=i.childLanes,a.lanes=i.lanes,a.child=i.child,a.subtreeFlags=0,a.deletions=null,a.memoizedProps=i.memoizedProps,a.memoizedState=i.memoizedState,a.updateQueue=i.updateQueue,a.type=i.type,e=i.dependencies,a.dependencies=e===null?null:{lanes:e.lanes,firstContext:e.firstContext}),r=r.sibling;return le(ge,ge.current&1|2),t.child}e=e.sibling}a.tail!==null&&Ee()>cn&&(t.flags|=128,s=!0,Sn(a,!1),t.lanes=4194304)}else{if(!s)if(e=sl(i),e!==null){if(t.flags|=128,s=!0,r=e.updateQueue,r!==null&&(t.updateQueue=r,t.flags|=4),Sn(a,!0),a.tail===null&&a.tailMode==="hidden"&&!i.alternate&&!fe)return Ue(t),null}else 2*Ee()-a.renderingStartTime>cn&&r!==1073741824&&(t.flags|=128,s=!0,Sn(a,!1),t.lanes=4194304);a.isBackwards?(i.sibling=t.child,t.child=i):(r=a.last,r!==null?r.sibling=i:t.child=i,a.last=i)}return a.tail!==null?(t=a.tail,a.rendering=t,a.tail=t.sibling,a.renderingStartTime=Ee(),t.sibling=null,r=ge.current,le(ge,s?r&1|2:r&1),t):(Ue(t),null);case 22:case 23:return Wi(),s=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==s&&(t.flags|=8192),s&&t.mode&1?Ze&1073741824&&(Ue(t),t.subtreeFlags&6&&(t.flags|=8192)):Ue(t),null;case 24:return null;case 25:return null}throw Error(I(156,t.tag))}function Hp(e,t){switch(ki(t),t.tag){case 1:return Je(t.type)&&qs(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return an(),ue(Ye),ue(ze),Li(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 5:return Pi(t),null;case 13:if(ue(ge),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(I(340));sn()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return ue(ge),null;case 4:return an(),null;case 10:return Ri(t.type._context),null;case 22:case 23:return Wi(),null;case 24:return null;default:return null}}var ks=!1,Fe=!1,Gp=typeof WeakSet=="function"?WeakSet:Set,M=null;function Yr(e,t){var r=e.ref;if(r!==null)if(typeof r=="function")try{r(null)}catch(s){we(e,t,s)}else r.current=null}function Ba(e,t,r){try{r()}catch(s){we(e,t,s)}}var Zo=!1;function Bp(e,t){if(Aa=Ks,e=hd(),bi(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 l=s.anchorOffset,a=s.focusNode;s=s.focusOffset;try{r.nodeType,a.nodeType}catch{r=null;break e}var i=0,o=-1,c=-1,d=0,f=0,g=e,h=null;t:for(;;){for(var x;g!==r||l!==0&&g.nodeType!==3||(o=i+l),g!==a||s!==0&&g.nodeType!==3||(c=i+s),g.nodeType===3&&(i+=g.nodeValue.length),(x=g.firstChild)!==null;)h=g,g=x;for(;;){if(g===e)break t;if(h===r&&++d===l&&(o=i),h===a&&++f===s&&(c=i),(x=g.nextSibling)!==null)break;g=h,h=g.parentNode}g=x}r=o===-1||c===-1?null:{start:o,end:c}}else r=null}r=r||{start:0,end:0}}else r=null;for(Ta={focusedElem:e,selectionRange:r},Ks=!1,M=t;M!==null;)if(t=M,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,M=e;else for(;M!==null;){t=M;try{var N=t.alternate;if(t.flags&1024)switch(t.tag){case 0:case 11:case 15:break;case 1:if(N!==null){var E=N.memoizedProps,b=N.memoizedState,m=t.stateNode,u=m.getSnapshotBeforeUpdate(t.elementType===t.type?E:Nt(t.type,E),b);m.__reactInternalSnapshotBeforeUpdate=u}break;case 3:var p=t.stateNode.containerInfo;p.nodeType===1?p.textContent="":p.nodeType===9&&p.documentElement&&p.removeChild(p.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(I(163))}}catch(j){we(t,t.return,j)}if(e=t.sibling,e!==null){e.return=t.return,M=e;break}M=t.return}return N=Zo,Zo=!1,N}function Mn(e,t,r){var s=t.updateQueue;if(s=s!==null?s.lastEffect:null,s!==null){var l=s=s.next;do{if((l.tag&e)===e){var a=l.destroy;l.destroy=void 0,a!==void 0&&Ba(t,r,a)}l=l.next}while(l!==s)}}function El(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 Wa(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 mu(e){var t=e.alternate;t!==null&&(e.alternate=null,mu(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[Tt],delete t[Qn],delete t[Oa],delete t[Cp],delete t[Ap])),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 pu(e){return e.tag===5||e.tag===3||e.tag===4}function ec(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||pu(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 Ka(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=Qs));else if(s!==4&&(e=e.child,e!==null))for(Ka(e,t,r),e=e.sibling;e!==null;)Ka(e,t,r),e=e.sibling}function Ya(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(Ya(e,t,r),e=e.sibling;e!==null;)Ya(e,t,r),e=e.sibling}var Re=null,jt=!1;function Jt(e,t,r){for(r=r.child;r!==null;)fu(e,t,r),r=r.sibling}function fu(e,t,r){if(Rt&&typeof Rt.onCommitFiberUnmount=="function")try{Rt.onCommitFiberUnmount(xl,r)}catch{}switch(r.tag){case 5:Fe||Yr(r,t);case 6:var s=Re,l=jt;Re=null,Jt(e,t,r),Re=s,jt=l,Re!==null&&(jt?(e=Re,r=r.stateNode,e.nodeType===8?e.parentNode.removeChild(r):e.removeChild(r)):Re.removeChild(r.stateNode));break;case 18:Re!==null&&(jt?(e=Re,r=r.stateNode,e.nodeType===8?Kl(e.parentNode,r):e.nodeType===1&&Kl(e,r),Bn(e)):Kl(Re,r.stateNode));break;case 4:s=Re,l=jt,Re=r.stateNode.containerInfo,jt=!0,Jt(e,t,r),Re=s,jt=l;break;case 0:case 11:case 14:case 15:if(!Fe&&(s=r.updateQueue,s!==null&&(s=s.lastEffect,s!==null))){l=s=s.next;do{var a=l,i=a.destroy;a=a.tag,i!==void 0&&(a&2||a&4)&&Ba(r,t,i),l=l.next}while(l!==s)}Jt(e,t,r);break;case 1:if(!Fe&&(Yr(r,t),s=r.stateNode,typeof s.componentWillUnmount=="function"))try{s.props=r.memoizedProps,s.state=r.memoizedState,s.componentWillUnmount()}catch(o){we(r,t,o)}Jt(e,t,r);break;case 21:Jt(e,t,r);break;case 22:r.mode&1?(Fe=(s=Fe)||r.memoizedState!==null,Jt(e,t,r),Fe=s):Jt(e,t,r);break;default:Jt(e,t,r)}}function tc(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var r=e.stateNode;r===null&&(r=e.stateNode=new Gp),t.forEach(function(s){var l=ef.bind(null,e,s);r.has(s)||(r.add(s),s.then(l,l))})}}function vt(e,t){var r=t.deletions;if(r!==null)for(var s=0;s<r.length;s++){var l=r[s];try{var a=e,i=t,o=i;e:for(;o!==null;){switch(o.tag){case 5:Re=o.stateNode,jt=!1;break e;case 3:Re=o.stateNode.containerInfo,jt=!0;break e;case 4:Re=o.stateNode.containerInfo,jt=!0;break e}o=o.return}if(Re===null)throw Error(I(160));fu(a,i,l),Re=null,jt=!1;var c=l.alternate;c!==null&&(c.return=null),l.return=null}catch(d){we(l,t,d)}}if(t.subtreeFlags&12854)for(t=t.child;t!==null;)xu(t,e),t=t.sibling}function xu(e,t){var r=e.alternate,s=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:if(vt(t,e),Ct(e),s&4){try{Mn(3,e,e.return),El(3,e)}catch(E){we(e,e.return,E)}try{Mn(5,e,e.return)}catch(E){we(e,e.return,E)}}break;case 1:vt(t,e),Ct(e),s&512&&r!==null&&Yr(r,r.return);break;case 5:if(vt(t,e),Ct(e),s&512&&r!==null&&Yr(r,r.return),e.flags&32){var l=e.stateNode;try{$n(l,"")}catch(E){we(e,e.return,E)}}if(s&4&&(l=e.stateNode,l!=null)){var a=e.memoizedProps,i=r!==null?r.memoizedProps:a,o=e.type,c=e.updateQueue;if(e.updateQueue=null,c!==null)try{o==="input"&&a.type==="radio"&&a.name!=null&&Mc(l,a),ya(o,i);var d=ya(o,a);for(i=0;i<c.length;i+=2){var f=c[i],g=c[i+1];f==="style"?Vc(l,g):f==="dangerouslySetInnerHTML"?zc(l,g):f==="children"?$n(l,g):ui(l,f,g,d)}switch(o){case"input":pa(l,a);break;case"textarea":Uc(l,a);break;case"select":var h=l._wrapperState.wasMultiple;l._wrapperState.wasMultiple=!!a.multiple;var x=a.value;x!=null?Qr(l,!!a.multiple,x,!1):h!==!!a.multiple&&(a.defaultValue!=null?Qr(l,!!a.multiple,a.defaultValue,!0):Qr(l,!!a.multiple,a.multiple?[]:"",!1))}l[Qn]=a}catch(E){we(e,e.return,E)}}break;case 6:if(vt(t,e),Ct(e),s&4){if(e.stateNode===null)throw Error(I(162));l=e.stateNode,a=e.memoizedProps;try{l.nodeValue=a}catch(E){we(e,e.return,E)}}break;case 3:if(vt(t,e),Ct(e),s&4&&r!==null&&r.memoizedState.isDehydrated)try{Bn(t.containerInfo)}catch(E){we(e,e.return,E)}break;case 4:vt(t,e),Ct(e);break;case 13:vt(t,e),Ct(e),l=e.child,l.flags&8192&&(a=l.memoizedState!==null,l.stateNode.isHidden=a,!a||l.alternate!==null&&l.alternate.memoizedState!==null||(Gi=Ee())),s&4&&tc(e);break;case 22:if(f=r!==null&&r.memoizedState!==null,e.mode&1?(Fe=(d=Fe)||f,vt(t,e),Fe=d):vt(t,e),Ct(e),s&8192){if(d=e.memoizedState!==null,(e.stateNode.isHidden=d)&&!f&&e.mode&1)for(M=e,f=e.child;f!==null;){for(g=M=f;M!==null;){switch(h=M,x=h.child,h.tag){case 0:case 11:case 14:case 15:Mn(4,h,h.return);break;case 1:Yr(h,h.return);var N=h.stateNode;if(typeof N.componentWillUnmount=="function"){s=h,r=h.return;try{t=s,N.props=t.memoizedProps,N.state=t.memoizedState,N.componentWillUnmount()}catch(E){we(s,r,E)}}break;case 5:Yr(h,h.return);break;case 22:if(h.memoizedState!==null){nc(g);continue}}x!==null?(x.return=h,M=x):nc(g)}f=f.sibling}e:for(f=null,g=e;;){if(g.tag===5){if(f===null){f=g;try{l=g.stateNode,d?(a=l.style,typeof a.setProperty=="function"?a.setProperty("display","none","important"):a.display="none"):(o=g.stateNode,c=g.memoizedProps.style,i=c!=null&&c.hasOwnProperty("display")?c.display:null,o.style.display=$c("display",i))}catch(E){we(e,e.return,E)}}}else if(g.tag===6){if(f===null)try{g.stateNode.nodeValue=d?"":g.memoizedProps}catch(E){we(e,e.return,E)}}else if((g.tag!==22&&g.tag!==23||g.memoizedState===null||g===e)&&g.child!==null){g.child.return=g,g=g.child;continue}if(g===e)break e;for(;g.sibling===null;){if(g.return===null||g.return===e)break e;f===g&&(f=null),g=g.return}f===g&&(f=null),g.sibling.return=g.return,g=g.sibling}}break;case 19:vt(t,e),Ct(e),s&4&&tc(e);break;case 21:break;default:vt(t,e),Ct(e)}}function Ct(e){var t=e.flags;if(t&2){try{e:{for(var r=e.return;r!==null;){if(pu(r)){var s=r;break e}r=r.return}throw Error(I(160))}switch(s.tag){case 5:var l=s.stateNode;s.flags&32&&($n(l,""),s.flags&=-33);var a=ec(e);Ya(e,a,l);break;case 3:case 4:var i=s.stateNode.containerInfo,o=ec(e);Ka(e,o,i);break;default:throw Error(I(161))}}catch(c){we(e,e.return,c)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function Wp(e,t,r){M=e,hu(e)}function hu(e,t,r){for(var s=(e.mode&1)!==0;M!==null;){var l=M,a=l.child;if(l.tag===22&&s){var i=l.memoizedState!==null||ks;if(!i){var o=l.alternate,c=o!==null&&o.memoizedState!==null||Fe;o=ks;var d=Fe;if(ks=i,(Fe=c)&&!d)for(M=l;M!==null;)i=M,c=i.child,i.tag===22&&i.memoizedState!==null?sc(l):c!==null?(c.return=i,M=c):sc(l);for(;a!==null;)M=a,hu(a),a=a.sibling;M=l,ks=o,Fe=d}rc(e)}else l.subtreeFlags&8772&&a!==null?(a.return=l,M=a):rc(e)}}function rc(e){for(;M!==null;){var t=M;if(t.flags&8772){var r=t.alternate;try{if(t.flags&8772)switch(t.tag){case 0:case 11:case 15:Fe||El(5,t);break;case 1:var s=t.stateNode;if(t.flags&4&&!Fe)if(r===null)s.componentDidMount();else{var l=t.elementType===t.type?r.memoizedProps:Nt(t.type,r.memoizedProps);s.componentDidUpdate(l,r.memoizedState,s.__reactInternalSnapshotBeforeUpdate)}var a=t.updateQueue;a!==null&&zo(t,a,s);break;case 3:var i=t.updateQueue;if(i!==null){if(r=null,t.child!==null)switch(t.child.tag){case 5:r=t.child.stateNode;break;case 1:r=t.child.stateNode}zo(t,i,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 g=f.dehydrated;g!==null&&Bn(g)}}}break;case 19:case 17:case 21:case 22:case 23:case 25:break;default:throw Error(I(163))}Fe||t.flags&512&&Wa(t)}catch(h){we(t,t.return,h)}}if(t===e){M=null;break}if(r=t.sibling,r!==null){r.return=t.return,M=r;break}M=t.return}}function nc(e){for(;M!==null;){var t=M;if(t===e){M=null;break}var r=t.sibling;if(r!==null){r.return=t.return,M=r;break}M=t.return}}function sc(e){for(;M!==null;){var t=M;try{switch(t.tag){case 0:case 11:case 15:var r=t.return;try{El(4,t)}catch(c){we(t,r,c)}break;case 1:var s=t.stateNode;if(typeof s.componentDidMount=="function"){var l=t.return;try{s.componentDidMount()}catch(c){we(t,l,c)}}var a=t.return;try{Wa(t)}catch(c){we(t,a,c)}break;case 5:var i=t.return;try{Wa(t)}catch(c){we(t,i,c)}}}catch(c){we(t,t.return,c)}if(t===e){M=null;break}var o=t.sibling;if(o!==null){o.return=t.return,M=o;break}M=t.return}}var Kp=Math.ceil,il=Gt.ReactCurrentDispatcher,Vi=Gt.ReactCurrentOwner,pt=Gt.ReactCurrentBatchConfig,X=0,Ae=null,be=null,De=0,Ze=0,Jr=fr(0),ke=0,rs=null,Tr=0,bl=0,Hi=0,Un=null,We=null,Gi=0,cn=1/0,Lt=null,ol=!1,Ja=null,ir=null,Cs=!1,tr=null,cl=0,Fn=0,Qa=null,Fs=-1,zs=0;function He(){return X&6?Ee():Fs!==-1?Fs:Fs=Ee()}function or(e){return e.mode&1?X&2&&De!==0?De&-De:Rp.transition!==null?(zs===0&&(zs=ed()),zs):(e=re,e!==0||(e=window.event,e=e===void 0?16:id(e.type)),e):1}function bt(e,t,r,s){if(50<Fn)throw Fn=0,Qa=null,Error(I(185));os(e,r,s),(!(X&2)||e!==Ae)&&(e===Ae&&(!(X&2)&&(bl|=r),ke===4&&Zt(e,De)),Qe(e,s),r===1&&X===0&&!(t.mode&1)&&(cn=Ee()+500,Nl&&xr()))}function Qe(e,t){var r=e.callbackNode;Rm(e,t);var s=Ws(e,e===Ae?De:0);if(s===0)r!==null&&po(r),e.callbackNode=null,e.callbackPriority=0;else if(t=s&-s,e.callbackPriority!==t){if(r!=null&&po(r),t===1)e.tag===0?Tp(lc.bind(null,e)):kd(lc.bind(null,e)),Sp(function(){!(X&6)&&xr()}),r=null;else{switch(td(s)){case 1:r=hi;break;case 4:r=Xc;break;case 16:r=Bs;break;case 536870912:r=Zc;break;default:r=Bs}r=bu(r,gu.bind(null,e))}e.callbackPriority=t,e.callbackNode=r}}function gu(e,t){if(Fs=-1,zs=0,X&6)throw Error(I(327));var r=e.callbackNode;if(tn()&&e.callbackNode!==r)return null;var s=Ws(e,e===Ae?De:0);if(s===0)return null;if(s&30||s&e.expiredLanes||t)t=dl(e,s);else{t=s;var l=X;X|=2;var a=vu();(Ae!==e||De!==t)&&(Lt=null,cn=Ee()+500,br(e,t));do try{Qp();break}catch(o){yu(e,o)}while(!0);Ti(),il.current=a,X=l,be!==null?t=0:(Ae=null,De=0,t=ke)}if(t!==0){if(t===2&&(l=Ea(e),l!==0&&(s=l,t=qa(e,l))),t===1)throw r=rs,br(e,0),Zt(e,s),Qe(e,Ee()),r;if(t===6)Zt(e,s);else{if(l=e.current.alternate,!(s&30)&&!Yp(l)&&(t=dl(e,s),t===2&&(a=Ea(e),a!==0&&(s=a,t=qa(e,a))),t===1))throw r=rs,br(e,0),Zt(e,s),Qe(e,Ee()),r;switch(e.finishedWork=l,e.finishedLanes=s,t){case 0:case 1:throw Error(I(345));case 2:Nr(e,We,Lt);break;case 3:if(Zt(e,s),(s&130023424)===s&&(t=Gi+500-Ee(),10<t)){if(Ws(e,0)!==0)break;if(l=e.suspendedLanes,(l&s)!==s){He(),e.pingedLanes|=e.suspendedLanes&l;break}e.timeoutHandle=Ia(Nr.bind(null,e,We,Lt),t);break}Nr(e,We,Lt);break;case 4:if(Zt(e,s),(s&4194240)===s)break;for(t=e.eventTimes,l=-1;0<s;){var i=31-Et(s);a=1<<i,i=t[i],i>l&&(l=i),s&=~a}if(s=l,s=Ee()-s,s=(120>s?120:480>s?480:1080>s?1080:1920>s?1920:3e3>s?3e3:4320>s?4320:1960*Kp(s/1960))-s,10<s){e.timeoutHandle=Ia(Nr.bind(null,e,We,Lt),s);break}Nr(e,We,Lt);break;case 5:Nr(e,We,Lt);break;default:throw Error(I(329))}}}return Qe(e,Ee()),e.callbackNode===r?gu.bind(null,e):null}function qa(e,t){var r=Un;return e.current.memoizedState.isDehydrated&&(br(e,t).flags|=256),e=dl(e,t),e!==2&&(t=We,We=r,t!==null&&Xa(t)),e}function Xa(e){We===null?We=e:We.push.apply(We,e)}function Yp(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 l=r[s],a=l.getSnapshot;l=l.value;try{if(!St(a(),l))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 Zt(e,t){for(t&=~Hi,t&=~bl,e.suspendedLanes|=t,e.pingedLanes&=~t,e=e.expirationTimes;0<t;){var r=31-Et(t),s=1<<r;e[r]=-1,t&=~s}}function lc(e){if(X&6)throw Error(I(327));tn();var t=Ws(e,0);if(!(t&1))return Qe(e,Ee()),null;var r=dl(e,t);if(e.tag!==0&&r===2){var s=Ea(e);s!==0&&(t=s,r=qa(e,s))}if(r===1)throw r=rs,br(e,0),Zt(e,t),Qe(e,Ee()),r;if(r===6)throw Error(I(345));return e.finishedWork=e.current.alternate,e.finishedLanes=t,Nr(e,We,Lt),Qe(e,Ee()),null}function Bi(e,t){var r=X;X|=1;try{return e(t)}finally{X=r,X===0&&(cn=Ee()+500,Nl&&xr())}}function Rr(e){tr!==null&&tr.tag===0&&!(X&6)&&tn();var t=X;X|=1;var r=pt.transition,s=re;try{if(pt.transition=null,re=1,e)return e()}finally{re=s,pt.transition=r,X=t,!(X&6)&&xr()}}function Wi(){Ze=Jr.current,ue(Jr)}function br(e,t){e.finishedWork=null,e.finishedLanes=0;var r=e.timeoutHandle;if(r!==-1&&(e.timeoutHandle=-1,bp(r)),be!==null)for(r=be.return;r!==null;){var s=r;switch(ki(s),s.tag){case 1:s=s.type.childContextTypes,s!=null&&qs();break;case 3:an(),ue(Ye),ue(ze),Li();break;case 5:Pi(s);break;case 4:an();break;case 13:ue(ge);break;case 19:ue(ge);break;case 10:Ri(s.type._context);break;case 22:case 23:Wi()}r=r.return}if(Ae=e,be=e=cr(e.current,null),De=Ze=t,ke=0,rs=null,Hi=bl=Tr=0,We=Un=null,wr!==null){for(t=0;t<wr.length;t++)if(r=wr[t],s=r.interleaved,s!==null){r.interleaved=null;var l=s.next,a=r.pending;if(a!==null){var i=a.next;a.next=l,s.next=i}r.pending=s}wr=null}return e}function yu(e,t){do{var r=be;try{if(Ti(),_s.current=al,ll){for(var s=ye.memoizedState;s!==null;){var l=s.queue;l!==null&&(l.pending=null),s=s.next}ll=!1}if(Ar=0,Ce=Se=ye=null,_n=!1,Zn=0,Vi.current=null,r===null||r.return===null){ke=1,rs=t,be=null;break}e:{var a=e,i=r.return,o=r,c=t;if(t=De,o.flags|=32768,c!==null&&typeof c=="object"&&typeof c.then=="function"){var d=c,f=o,g=f.tag;if(!(f.mode&1)&&(g===0||g===11||g===15)){var h=f.alternate;h?(f.updateQueue=h.updateQueue,f.memoizedState=h.memoizedState,f.lanes=h.lanes):(f.updateQueue=null,f.memoizedState=null)}var x=Wo(i);if(x!==null){x.flags&=-257,Ko(x,i,o,a,t),x.mode&1&&Bo(a,d,t),t=x,c=d;var N=t.updateQueue;if(N===null){var E=new Set;E.add(c),t.updateQueue=E}else N.add(c);break e}else{if(!(t&1)){Bo(a,d,t),Ki();break e}c=Error(I(426))}}else if(fe&&o.mode&1){var b=Wo(i);if(b!==null){!(b.flags&65536)&&(b.flags|=256),Ko(b,i,o,a,t),Ci(on(c,o));break e}}a=c=on(c,o),ke!==4&&(ke=2),Un===null?Un=[a]:Un.push(a),a=i;do{switch(a.tag){case 3:a.flags|=65536,t&=-t,a.lanes|=t;var m=tu(a,c,t);Fo(a,m);break e;case 1:o=c;var u=a.type,p=a.stateNode;if(!(a.flags&128)&&(typeof u.getDerivedStateFromError=="function"||p!==null&&typeof p.componentDidCatch=="function"&&(ir===null||!ir.has(p)))){a.flags|=65536,t&=-t,a.lanes|=t;var j=ru(a,o,t);Fo(a,j);break e}}a=a.return}while(a!==null)}ju(r)}catch(S){t=S,be===r&&r!==null&&(be=r=r.return);continue}break}while(!0)}function vu(){var e=il.current;return il.current=al,e===null?al:e}function Ki(){(ke===0||ke===3||ke===2)&&(ke=4),Ae===null||!(Tr&268435455)&&!(bl&268435455)||Zt(Ae,De)}function dl(e,t){var r=X;X|=2;var s=vu();(Ae!==e||De!==t)&&(Lt=null,br(e,t));do try{Jp();break}catch(l){yu(e,l)}while(!0);if(Ti(),X=r,il.current=s,be!==null)throw Error(I(261));return Ae=null,De=0,ke}function Jp(){for(;be!==null;)Nu(be)}function Qp(){for(;be!==null&&!jm();)Nu(be)}function Nu(e){var t=Eu(e.alternate,e,Ze);e.memoizedProps=e.pendingProps,t===null?ju(e):be=t,Vi.current=null}function ju(e){var t=e;do{var r=t.alternate;if(e=t.return,t.flags&32768){if(r=Hp(r,t),r!==null){r.flags&=32767,be=r;return}if(e!==null)e.flags|=32768,e.subtreeFlags=0,e.deletions=null;else{ke=6,be=null;return}}else if(r=Vp(r,t,Ze),r!==null){be=r;return}if(t=t.sibling,t!==null){be=t;return}be=t=e}while(t!==null);ke===0&&(ke=5)}function Nr(e,t,r){var s=re,l=pt.transition;try{pt.transition=null,re=1,qp(e,t,r,s)}finally{pt.transition=l,re=s}return null}function qp(e,t,r,s){do tn();while(tr!==null);if(X&6)throw Error(I(327));r=e.finishedWork;var l=e.finishedLanes;if(r===null)return null;if(e.finishedWork=null,e.finishedLanes=0,r===e.current)throw Error(I(177));e.callbackNode=null,e.callbackPriority=0;var a=r.lanes|r.childLanes;if(Im(e,a),e===Ae&&(be=Ae=null,De=0),!(r.subtreeFlags&2064)&&!(r.flags&2064)||Cs||(Cs=!0,bu(Bs,function(){return tn(),null})),a=(r.flags&15990)!==0,r.subtreeFlags&15990||a){a=pt.transition,pt.transition=null;var i=re;re=1;var o=X;X|=4,Vi.current=null,Bp(e,r),xu(r,e),gp(Ta),Ks=!!Aa,Ta=Aa=null,e.current=r,Wp(r),wm(),X=o,re=i,pt.transition=a}else e.current=r;if(Cs&&(Cs=!1,tr=e,cl=l),a=e.pendingLanes,a===0&&(ir=null),Sm(r.stateNode),Qe(e,Ee()),t!==null)for(s=e.onRecoverableError,r=0;r<t.length;r++)l=t[r],s(l.value,{componentStack:l.stack,digest:l.digest});if(ol)throw ol=!1,e=Ja,Ja=null,e;return cl&1&&e.tag!==0&&tn(),a=e.pendingLanes,a&1?e===Qa?Fn++:(Fn=0,Qa=e):Fn=0,xr(),null}function tn(){if(tr!==null){var e=td(cl),t=pt.transition,r=re;try{if(pt.transition=null,re=16>e?16:e,tr===null)var s=!1;else{if(e=tr,tr=null,cl=0,X&6)throw Error(I(331));var l=X;for(X|=4,M=e.current;M!==null;){var a=M,i=a.child;if(M.flags&16){var o=a.deletions;if(o!==null){for(var c=0;c<o.length;c++){var d=o[c];for(M=d;M!==null;){var f=M;switch(f.tag){case 0:case 11:case 15:Mn(8,f,a)}var g=f.child;if(g!==null)g.return=f,M=g;else for(;M!==null;){f=M;var h=f.sibling,x=f.return;if(mu(f),f===d){M=null;break}if(h!==null){h.return=x,M=h;break}M=x}}}var N=a.alternate;if(N!==null){var E=N.child;if(E!==null){N.child=null;do{var b=E.sibling;E.sibling=null,E=b}while(E!==null)}}M=a}}if(a.subtreeFlags&2064&&i!==null)i.return=a,M=i;else e:for(;M!==null;){if(a=M,a.flags&2048)switch(a.tag){case 0:case 11:case 15:Mn(9,a,a.return)}var m=a.sibling;if(m!==null){m.return=a.return,M=m;break e}M=a.return}}var u=e.current;for(M=u;M!==null;){i=M;var p=i.child;if(i.subtreeFlags&2064&&p!==null)p.return=i,M=p;else e:for(i=u;M!==null;){if(o=M,o.flags&2048)try{switch(o.tag){case 0:case 11:case 15:El(9,o)}}catch(S){we(o,o.return,S)}if(o===i){M=null;break e}var j=o.sibling;if(j!==null){j.return=o.return,M=j;break e}M=o.return}}if(X=l,xr(),Rt&&typeof Rt.onPostCommitFiberRoot=="function")try{Rt.onPostCommitFiberRoot(xl,e)}catch{}s=!0}return s}finally{re=r,pt.transition=t}}return!1}function ac(e,t,r){t=on(r,t),t=tu(e,t,1),e=ar(e,t,1),t=He(),e!==null&&(os(e,1,t),Qe(e,t))}function we(e,t,r){if(e.tag===3)ac(e,e,r);else for(;t!==null;){if(t.tag===3){ac(t,e,r);break}else if(t.tag===1){var s=t.stateNode;if(typeof t.type.getDerivedStateFromError=="function"||typeof s.componentDidCatch=="function"&&(ir===null||!ir.has(s))){e=on(r,e),e=ru(t,e,1),t=ar(t,e,1),e=He(),t!==null&&(os(t,1,e),Qe(t,e));break}}t=t.return}}function Xp(e,t,r){var s=e.pingCache;s!==null&&s.delete(t),t=He(),e.pingedLanes|=e.suspendedLanes&r,Ae===e&&(De&r)===r&&(ke===4||ke===3&&(De&130023424)===De&&500>Ee()-Gi?br(e,0):Hi|=r),Qe(e,t)}function wu(e,t){t===0&&(e.mode&1?(t=gs,gs<<=1,!(gs&130023424)&&(gs=4194304)):t=1);var r=He();e=Vt(e,t),e!==null&&(os(e,t,r),Qe(e,r))}function Zp(e){var t=e.memoizedState,r=0;t!==null&&(r=t.retryLane),wu(e,r)}function ef(e,t){var r=0;switch(e.tag){case 13:var s=e.stateNode,l=e.memoizedState;l!==null&&(r=l.retryLane);break;case 19:s=e.stateNode;break;default:throw Error(I(314))}s!==null&&s.delete(t),wu(e,r)}var Eu;Eu=function(e,t,r){if(e!==null)if(e.memoizedProps!==t.pendingProps||Ye.current)Ke=!0;else{if(!(e.lanes&r)&&!(t.flags&128))return Ke=!1,$p(e,t,r);Ke=!!(e.flags&131072)}else Ke=!1,fe&&t.flags&1048576&&Cd(t,el,t.index);switch(t.lanes=0,t.tag){case 2:var s=t.type;Us(e,t),e=t.pendingProps;var l=nn(t,ze.current);en(t,r),l=Mi(null,t,s,e,l,r);var a=Ui();return t.flags|=1,typeof l=="object"&&l!==null&&typeof l.render=="function"&&l.$$typeof===void 0?(t.tag=1,t.memoizedState=null,t.updateQueue=null,Je(s)?(a=!0,Xs(t)):a=!1,t.memoizedState=l.state!==null&&l.state!==void 0?l.state:null,Oi(t),l.updater=wl,t.stateNode=l,l._reactInternals=t,Ua(t,s,e,r),t=$a(null,t,s,!0,a,r)):(t.tag=0,fe&&a&&Si(t),Ve(null,t,l,r),t=t.child),t;case 16:s=t.elementType;e:{switch(Us(e,t),e=t.pendingProps,l=s._init,s=l(s._payload),t.type=s,l=t.tag=rf(s),e=Nt(s,e),l){case 0:t=za(null,t,s,e,r);break e;case 1:t=Qo(null,t,s,e,r);break e;case 11:t=Yo(null,t,s,e,r);break e;case 14:t=Jo(null,t,s,Nt(s.type,e),r);break e}throw Error(I(306,s,""))}return t;case 0:return s=t.type,l=t.pendingProps,l=t.elementType===s?l:Nt(s,l),za(e,t,s,l,r);case 1:return s=t.type,l=t.pendingProps,l=t.elementType===s?l:Nt(s,l),Qo(e,t,s,l,r);case 3:e:{if(au(t),e===null)throw Error(I(387));s=t.pendingProps,a=t.memoizedState,l=a.element,Dd(e,t),nl(t,s,null,r);var i=t.memoizedState;if(s=i.element,a.isDehydrated)if(a={element:s,isDehydrated:!1,cache:i.cache,pendingSuspenseBoundaries:i.pendingSuspenseBoundaries,transitions:i.transitions},t.updateQueue.baseState=a,t.memoizedState=a,t.flags&256){l=on(Error(I(423)),t),t=qo(e,t,s,r,l);break e}else if(s!==l){l=on(Error(I(424)),t),t=qo(e,t,s,r,l);break e}else for(tt=lr(t.stateNode.containerInfo.firstChild),rt=t,fe=!0,wt=null,r=Id(t,null,s,r),t.child=r;r;)r.flags=r.flags&-3|4096,r=r.sibling;else{if(sn(),s===l){t=Ht(e,t,r);break e}Ve(e,t,s,r)}t=t.child}return t;case 5:return Pd(t),e===null&&La(t),s=t.type,l=t.pendingProps,a=e!==null?e.memoizedProps:null,i=l.children,Ra(s,l)?i=null:a!==null&&Ra(s,a)&&(t.flags|=32),lu(e,t),Ve(e,t,i,r),t.child;case 6:return e===null&&La(t),null;case 13:return iu(e,t,r);case 4:return Di(t,t.stateNode.containerInfo),s=t.pendingProps,e===null?t.child=ln(t,null,s,r):Ve(e,t,s,r),t.child;case 11:return s=t.type,l=t.pendingProps,l=t.elementType===s?l:Nt(s,l),Yo(e,t,s,l,r);case 7:return Ve(e,t,t.pendingProps,r),t.child;case 8:return Ve(e,t,t.pendingProps.children,r),t.child;case 12:return Ve(e,t,t.pendingProps.children,r),t.child;case 10:e:{if(s=t.type._context,l=t.pendingProps,a=t.memoizedProps,i=l.value,le(tl,s._currentValue),s._currentValue=i,a!==null)if(St(a.value,i)){if(a.children===l.children&&!Ye.current){t=Ht(e,t,r);break e}}else for(a=t.child,a!==null&&(a.return=t);a!==null;){var o=a.dependencies;if(o!==null){i=a.child;for(var c=o.firstContext;c!==null;){if(c.context===s){if(a.tag===1){c=Ft(-1,r&-r),c.tag=2;var d=a.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}}a.lanes|=r,c=a.alternate,c!==null&&(c.lanes|=r),_a(a.return,r,t),o.lanes|=r;break}c=c.next}}else if(a.tag===10)i=a.type===t.type?null:a.child;else if(a.tag===18){if(i=a.return,i===null)throw Error(I(341));i.lanes|=r,o=i.alternate,o!==null&&(o.lanes|=r),_a(i,r,t),i=a.sibling}else i=a.child;if(i!==null)i.return=a;else for(i=a;i!==null;){if(i===t){i=null;break}if(a=i.sibling,a!==null){a.return=i.return,i=a;break}i=i.return}a=i}Ve(e,t,l.children,r),t=t.child}return t;case 9:return l=t.type,s=t.pendingProps.children,en(t,r),l=xt(l),s=s(l),t.flags|=1,Ve(e,t,s,r),t.child;case 14:return s=t.type,l=Nt(s,t.pendingProps),l=Nt(s.type,l),Jo(e,t,s,l,r);case 15:return nu(e,t,t.type,t.pendingProps,r);case 17:return s=t.type,l=t.pendingProps,l=t.elementType===s?l:Nt(s,l),Us(e,t),t.tag=1,Je(s)?(e=!0,Xs(t)):e=!1,en(t,r),eu(t,s,l),Ua(t,s,l,r),$a(null,t,s,!0,e,r);case 19:return ou(e,t,r);case 22:return su(e,t,r)}throw Error(I(156,t.tag))};function bu(e,t){return qc(e,t)}function tf(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 mt(e,t,r,s){return new tf(e,t,r,s)}function Yi(e){return e=e.prototype,!(!e||!e.isReactComponent)}function rf(e){if(typeof e=="function")return Yi(e)?1:0;if(e!=null){if(e=e.$$typeof,e===pi)return 11;if(e===fi)return 14}return 2}function cr(e,t){var r=e.alternate;return r===null?(r=mt(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 $s(e,t,r,s,l,a){var i=2;if(s=e,typeof e=="function")Yi(e)&&(i=1);else if(typeof e=="string")i=5;else e:switch(e){case Fr:return Sr(r.children,l,a,t);case mi:i=8,l|=8;break;case oa:return e=mt(12,r,t,l|2),e.elementType=oa,e.lanes=a,e;case ca:return e=mt(13,r,t,l),e.elementType=ca,e.lanes=a,e;case da:return e=mt(19,r,t,l),e.elementType=da,e.lanes=a,e;case Pc:return Sl(r,l,a,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case Oc:i=10;break e;case Dc:i=9;break e;case pi:i=11;break e;case fi:i=14;break e;case Qt:i=16,s=null;break e}throw Error(I(130,e==null?e:typeof e,""))}return t=mt(i,r,t,l),t.elementType=e,t.type=s,t.lanes=a,t}function Sr(e,t,r,s){return e=mt(7,e,s,t),e.lanes=r,e}function Sl(e,t,r,s){return e=mt(22,e,s,t),e.elementType=Pc,e.lanes=r,e.stateNode={isHidden:!1},e}function ta(e,t,r){return e=mt(6,e,null,t),e.lanes=r,e}function ra(e,t,r){return t=mt(4,e.children!==null?e.children:[],e.key,t),t.lanes=r,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function nf(e,t,r,s,l){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=_l(0),this.expirationTimes=_l(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=_l(0),this.identifierPrefix=s,this.onRecoverableError=l,this.mutableSourceEagerHydrationData=null}function Ji(e,t,r,s,l,a,i,o,c){return e=new nf(e,t,r,o,c),t===1?(t=1,a===!0&&(t|=8)):t=0,a=mt(3,null,null,t),e.current=a,a.stateNode=e,a.memoizedState={element:s,isDehydrated:r,cache:null,transitions:null,pendingSuspenseBoundaries:null},Oi(a),e}function sf(e,t,r){var s=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:Ur,key:s==null?null:""+s,children:e,containerInfo:t,implementation:r}}function Su(e){if(!e)return mr;e=e._reactInternals;e:{if(Or(e)!==e||e.tag!==1)throw Error(I(170));var t=e;do{switch(t.tag){case 3:t=t.stateNode.context;break e;case 1:if(Je(t.type)){t=t.stateNode.__reactInternalMemoizedMergedChildContext;break e}}t=t.return}while(t!==null);throw Error(I(171))}if(e.tag===1){var r=e.type;if(Je(r))return Sd(e,r,t)}return t}function ku(e,t,r,s,l,a,i,o,c){return e=Ji(r,s,!0,e,l,a,i,o,c),e.context=Su(null),r=e.current,s=He(),l=or(r),a=Ft(s,l),a.callback=t??null,ar(r,a,l),e.current.lanes=l,os(e,l,s),Qe(e,s),e}function kl(e,t,r,s){var l=t.current,a=He(),i=or(l);return r=Su(r),t.context===null?t.context=r:t.pendingContext=r,t=Ft(a,i),t.payload={element:e},s=s===void 0?null:s,s!==null&&(t.callback=s),e=ar(l,t,i),e!==null&&(bt(e,l,i,a),Ls(e,l,i)),i}function ul(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 ic(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var r=e.retryLane;e.retryLane=r!==0&&r<t?r:t}}function Qi(e,t){ic(e,t),(e=e.alternate)&&ic(e,t)}function lf(){return null}var Cu=typeof reportError=="function"?reportError:function(e){console.error(e)};function qi(e){this._internalRoot=e}Cl.prototype.render=qi.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(I(409));kl(e,t,null,null)};Cl.prototype.unmount=qi.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;Rr(function(){kl(null,e,null,null)}),t[$t]=null}};function Cl(e){this._internalRoot=e}Cl.prototype.unstable_scheduleHydration=function(e){if(e){var t=sd();e={blockedOn:null,target:e,priority:t};for(var r=0;r<Xt.length&&t!==0&&t<Xt[r].priority;r++);Xt.splice(r,0,e),r===0&&ad(e)}};function Xi(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function Al(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11&&(e.nodeType!==8||e.nodeValue!==" react-mount-point-unstable "))}function oc(){}function af(e,t,r,s,l){if(l){if(typeof s=="function"){var a=s;s=function(){var d=ul(i);a.call(d)}}var i=ku(t,s,e,0,null,!1,!1,"",oc);return e._reactRootContainer=i,e[$t]=i.current,Yn(e.nodeType===8?e.parentNode:e),Rr(),i}for(;l=e.lastChild;)e.removeChild(l);if(typeof s=="function"){var o=s;s=function(){var d=ul(c);o.call(d)}}var c=Ji(e,0,!1,null,null,!1,!1,"",oc);return e._reactRootContainer=c,e[$t]=c.current,Yn(e.nodeType===8?e.parentNode:e),Rr(function(){kl(t,c,r,s)}),c}function Tl(e,t,r,s,l){var a=r._reactRootContainer;if(a){var i=a;if(typeof l=="function"){var o=l;l=function(){var c=ul(i);o.call(c)}}kl(t,i,e,l)}else i=af(r,t,e,l,s);return ul(i)}rd=function(e){switch(e.tag){case 3:var t=e.stateNode;if(t.current.memoizedState.isDehydrated){var r=Tn(t.pendingLanes);r!==0&&(gi(t,r|1),Qe(t,Ee()),!(X&6)&&(cn=Ee()+500,xr()))}break;case 13:Rr(function(){var s=Vt(e,1);if(s!==null){var l=He();bt(s,e,1,l)}}),Qi(e,1)}};yi=function(e){if(e.tag===13){var t=Vt(e,134217728);if(t!==null){var r=He();bt(t,e,134217728,r)}Qi(e,134217728)}};nd=function(e){if(e.tag===13){var t=or(e),r=Vt(e,t);if(r!==null){var s=He();bt(r,e,t,s)}Qi(e,t)}};sd=function(){return re};ld=function(e,t){var r=re;try{return re=e,t()}finally{re=r}};Na=function(e,t,r){switch(t){case"input":if(pa(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 l=vl(s);if(!l)throw Error(I(90));_c(s),pa(s,l)}}}break;case"textarea":Uc(e,r);break;case"select":t=r.value,t!=null&&Qr(e,!!r.multiple,t,!1)}};Bc=Bi;Wc=Rr;var of={usingClientEntryPoint:!1,Events:[ds,Hr,vl,Hc,Gc,Bi]},kn={findFiberByHostInstance:jr,bundleType:0,version:"18.3.1",rendererPackageName:"react-dom"},cf={bundleType:kn.bundleType,version:kn.version,rendererPackageName:kn.rendererPackageName,rendererConfig:kn.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setErrorHandler:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:Gt.ReactCurrentDispatcher,findHostInstanceByFiber:function(e){return e=Jc(e),e===null?null:e.stateNode},findFiberByHostInstance:kn.findFiberByHostInstance||lf,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 As=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!As.isDisabled&&As.supportsFiber)try{xl=As.inject(cf),Rt=As}catch{}}st.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=of;st.createPortal=function(e,t){var r=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!Xi(t))throw Error(I(200));return sf(e,t,null,r)};st.createRoot=function(e,t){if(!Xi(e))throw Error(I(299));var r=!1,s="",l=Cu;return t!=null&&(t.unstable_strictMode===!0&&(r=!0),t.identifierPrefix!==void 0&&(s=t.identifierPrefix),t.onRecoverableError!==void 0&&(l=t.onRecoverableError)),t=Ji(e,1,!1,null,null,r,!1,s,l),e[$t]=t.current,Yn(e.nodeType===8?e.parentNode:e),new qi(t)};st.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(I(188)):(e=Object.keys(e).join(","),Error(I(268,e)));return e=Jc(t),e=e===null?null:e.stateNode,e};st.flushSync=function(e){return Rr(e)};st.hydrate=function(e,t,r){if(!Al(t))throw Error(I(200));return Tl(null,e,t,!0,r)};st.hydrateRoot=function(e,t,r){if(!Xi(e))throw Error(I(405));var s=r!=null&&r.hydratedSources||null,l=!1,a="",i=Cu;if(r!=null&&(r.unstable_strictMode===!0&&(l=!0),r.identifierPrefix!==void 0&&(a=r.identifierPrefix),r.onRecoverableError!==void 0&&(i=r.onRecoverableError)),t=ku(t,null,e,1,r??null,l,!1,a,i),e[$t]=t.current,Yn(e),s)for(e=0;e<s.length;e++)r=s[e],l=r._getVersion,l=l(r._source),t.mutableSourceEagerHydrationData==null?t.mutableSourceEagerHydrationData=[r,l]:t.mutableSourceEagerHydrationData.push(r,l);return new Cl(t)};st.render=function(e,t,r){if(!Al(t))throw Error(I(200));return Tl(null,e,t,!1,r)};st.unmountComponentAtNode=function(e){if(!Al(e))throw Error(I(40));return e._reactRootContainer?(Rr(function(){Tl(null,null,e,!1,function(){e._reactRootContainer=null,e[$t]=null})}),!0):!1};st.unstable_batchedUpdates=Bi;st.unstable_renderSubtreeIntoContainer=function(e,t,r,s){if(!Al(r))throw Error(I(200));if(e==null||e._reactInternals===void 0)throw Error(I(38));return Tl(e,t,r,!1,s)};st.version="18.3.1-next-f1338f8080-20240426";function Au(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(Au)}catch(e){console.error(e)}}Au(),Ac.exports=st;var df=Ac.exports,cc=df;aa.createRoot=cc.createRoot,aa.hydrateRoot=cc.hydrateRoot;/**
|
|
41
|
-
* @license lucide-react v0.298.0 - ISC
|
|
42
|
-
*
|
|
43
|
-
* This source code is licensed under the ISC license.
|
|
44
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
45
|
-
*/var uf={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"};/**
|
|
46
|
-
* @license lucide-react v0.298.0 - ISC
|
|
47
|
-
*
|
|
48
|
-
* This source code is licensed under the ISC license.
|
|
49
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
50
|
-
*/const mf=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase().trim(),$=(e,t)=>{const r=v.forwardRef(({color:s="currentColor",size:l=24,strokeWidth:a=2,absoluteStrokeWidth:i,className:o="",children:c,...d},f)=>v.createElement("svg",{ref:f,...uf,width:l,height:l,stroke:s,strokeWidth:i?Number(a)*24/Number(l):a,className:["lucide",`lucide-${mf(e)}`,o].join(" "),...d},[...t.map(([g,h])=>v.createElement(g,h)),...Array.isArray(c)?c:[c]]));return r.displayName=`${e}`,r};/**
|
|
51
|
-
* @license lucide-react v0.298.0 - ISC
|
|
52
|
-
*
|
|
53
|
-
* This source code is licensed under the ISC license.
|
|
54
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
55
|
-
*/const pf=$("Activity",[["path",{d:"M22 12h-4l-3 9L9 3l-3 9H2",key:"d5dnw9"}]]);/**
|
|
56
|
-
* @license lucide-react v0.298.0 - ISC
|
|
57
|
-
*
|
|
58
|
-
* This source code is licensed under the ISC license.
|
|
59
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
60
|
-
*/const Oe=$("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"}]]);/**
|
|
61
|
-
* @license lucide-react v0.298.0 - ISC
|
|
62
|
-
*
|
|
63
|
-
* This source code is licensed under the ISC license.
|
|
64
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
65
|
-
*/const na=$("ArrowRight",[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"m12 5 7 7-7 7",key:"xquz4c"}]]);/**
|
|
66
|
-
* @license lucide-react v0.298.0 - ISC
|
|
67
|
-
*
|
|
68
|
-
* This source code is licensed under the ISC license.
|
|
69
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
70
|
-
*/const ff=$("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"}]]);/**
|
|
71
|
-
* @license lucide-react v0.298.0 - ISC
|
|
72
|
-
*
|
|
73
|
-
* This source code is licensed under the ISC license.
|
|
74
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
75
|
-
*/const ml=$("Bot",[["path",{d:"M12 8V4H8",key:"hb8ula"}],["rect",{width:"16",height:"12",x:"4",y:"8",rx:"2",key:"enze0r"}],["path",{d:"M2 14h2",key:"vft8re"}],["path",{d:"M20 14h2",key:"4cs60a"}],["path",{d:"M15 13v2",key:"1xurst"}],["path",{d:"M9 13v2",key:"rq6x2g"}]]);/**
|
|
76
|
-
* @license lucide-react v0.298.0 - ISC
|
|
77
|
-
*
|
|
78
|
-
* This source code is licensed under the ISC license.
|
|
79
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
80
|
-
*/const Ie=$("CheckCircle2",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]]);/**
|
|
81
|
-
* @license lucide-react v0.298.0 - ISC
|
|
82
|
-
*
|
|
83
|
-
* This source code is licensed under the ISC license.
|
|
84
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
85
|
-
*/const dr=$("Check",[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]]);/**
|
|
86
|
-
* @license lucide-react v0.298.0 - ISC
|
|
87
|
-
*
|
|
88
|
-
* This source code is licensed under the ISC license.
|
|
89
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
90
|
-
*/const ns=$("ChevronDown",[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]]);/**
|
|
91
|
-
* @license lucide-react v0.298.0 - ISC
|
|
92
|
-
*
|
|
93
|
-
* This source code is licensed under the ISC license.
|
|
94
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
95
|
-
*/const xf=$("ChevronRight",[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]]);/**
|
|
96
|
-
* @license lucide-react v0.298.0 - ISC
|
|
97
|
-
*
|
|
98
|
-
* This source code is licensed under the ISC license.
|
|
99
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
100
|
-
*/const Za=$("Circle",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]]);/**
|
|
101
|
-
* @license lucide-react v0.298.0 - ISC
|
|
102
|
-
*
|
|
103
|
-
* This source code is licensed under the ISC license.
|
|
104
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
105
|
-
*/const dc=$("Clock",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["polyline",{points:"12 6 12 12 16 14",key:"68esgv"}]]);/**
|
|
106
|
-
* @license lucide-react v0.298.0 - ISC
|
|
107
|
-
*
|
|
108
|
-
* This source code is licensed under the ISC license.
|
|
109
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
110
|
-
*/const Tu=$("Code",[["polyline",{points:"16 18 22 12 16 6",key:"z7tu5w"}],["polyline",{points:"8 6 2 12 8 18",key:"1eg1df"}]]);/**
|
|
111
|
-
* @license lucide-react v0.298.0 - ISC
|
|
112
|
-
*
|
|
113
|
-
* This source code is licensed under the ISC license.
|
|
114
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
115
|
-
*/const Ru=$("Columns",[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",ry:"2",key:"1m3agn"}],["line",{x1:"12",x2:"12",y1:"3",y2:"21",key:"1efggb"}]]);/**
|
|
116
|
-
* @license lucide-react v0.298.0 - ISC
|
|
117
|
-
*
|
|
118
|
-
* This source code is licensed under the ISC license.
|
|
119
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
120
|
-
*/const hf=$("Command",[["path",{d:"M15 6v12a3 3 0 1 0 3-3H6a3 3 0 1 0 3 3V6a3 3 0 1 0-3 3h12a3 3 0 1 0-3-3",key:"11bfej"}]]);/**
|
|
121
|
-
* @license lucide-react v0.298.0 - ISC
|
|
122
|
-
*
|
|
123
|
-
* This source code is licensed under the ISC license.
|
|
124
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
125
|
-
*/const dn=$("Copy",[["rect",{width:"14",height:"14",x:"8",y:"8",rx:"2",ry:"2",key:"17jyea"}],["path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2",key:"zix9uf"}]]);/**
|
|
126
|
-
* @license lucide-react v0.298.0 - ISC
|
|
127
|
-
*
|
|
128
|
-
* This source code is licensed under the ISC license.
|
|
129
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
130
|
-
*/const gf=$("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"}]]);/**
|
|
131
|
-
* @license lucide-react v0.298.0 - ISC
|
|
132
|
-
*
|
|
133
|
-
* This source code is licensed under the ISC license.
|
|
134
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
135
|
-
*/const uc=$("Download",[["path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4",key:"ih7n3h"}],["polyline",{points:"7 10 12 15 17 10",key:"2ggqvy"}],["line",{x1:"12",x2:"12",y1:"15",y2:"3",key:"1vk2je"}]]);/**
|
|
136
|
-
* @license lucide-react v0.298.0 - ISC
|
|
137
|
-
*
|
|
138
|
-
* This source code is licensed under the ISC license.
|
|
139
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
140
|
-
*/const yf=$("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"}]]);/**
|
|
141
|
-
* @license lucide-react v0.298.0 - ISC
|
|
142
|
-
*
|
|
143
|
-
* This source code is licensed under the ISC license.
|
|
144
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
145
|
-
*/const ei=$("FileCode",[["path",{d:"M14.5 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7.5L14.5 2z",key:"1nnpy2"}],["polyline",{points:"14 2 14 8 20 8",key:"1ew0cm"}],["path",{d:"m10 13-2 2 2 2",key:"17smn8"}],["path",{d:"m14 17 2-2-2-2",key:"14mezr"}]]);/**
|
|
146
|
-
* @license lucide-react v0.298.0 - ISC
|
|
147
|
-
*
|
|
148
|
-
* This source code is licensed under the ISC license.
|
|
149
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
150
|
-
*/const mc=$("FileDown",[["path",{d:"M14.5 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7.5L14.5 2z",key:"1nnpy2"}],["polyline",{points:"14 2 14 8 20 8",key:"1ew0cm"}],["path",{d:"M12 18v-6",key:"17g6i2"}],["path",{d:"m9 15 3 3 3-3",key:"1npd3o"}]]);/**
|
|
151
|
-
* @license lucide-react v0.298.0 - ISC
|
|
152
|
-
*
|
|
153
|
-
* This source code is licensed under the ISC license.
|
|
154
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
155
|
-
*/const vf=$("Filter",[["polygon",{points:"22 3 2 3 10 12.46 10 19 14 21 14 12.46 22 3",key:"1yg77f"}]]);/**
|
|
156
|
-
* @license lucide-react v0.298.0 - ISC
|
|
157
|
-
*
|
|
158
|
-
* This source code is licensed under the ISC license.
|
|
159
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
160
|
-
*/const Nf=$("FolderOpen",[["path",{d:"m6 14 1.5-2.9A2 2 0 0 1 9.24 10H20a2 2 0 0 1 1.94 2.5l-1.54 6a2 2 0 0 1-1.95 1.5H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H18a2 2 0 0 1 2 2v2",key:"usdka0"}]]);/**
|
|
161
|
-
* @license lucide-react v0.298.0 - ISC
|
|
162
|
-
*
|
|
163
|
-
* This source code is licensed under the ISC license.
|
|
164
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
165
|
-
*/const jf=$("GitBranch",[["line",{x1:"6",x2:"6",y1:"3",y2:"15",key:"17qcm7"}],["circle",{cx:"18",cy:"6",r:"3",key:"1h7g24"}],["circle",{cx:"6",cy:"18",r:"3",key:"fqmcym"}],["path",{d:"M18 9a9 9 0 0 1-9 9",key:"n2h4wq"}]]);/**
|
|
166
|
-
* @license lucide-react v0.298.0 - ISC
|
|
167
|
-
*
|
|
168
|
-
* This source code is licensed under the ISC license.
|
|
169
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
170
|
-
*/const Iu=$("GitCommitHorizontal",[["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}],["line",{x1:"3",x2:"9",y1:"12",y2:"12",key:"1dyftd"}],["line",{x1:"15",x2:"21",y1:"12",y2:"12",key:"oup4p8"}]]);/**
|
|
171
|
-
* @license lucide-react v0.298.0 - ISC
|
|
172
|
-
*
|
|
173
|
-
* This source code is licensed under the ISC license.
|
|
174
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
175
|
-
*/const wf=$("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"}]]);/**
|
|
176
|
-
* @license lucide-react v0.298.0 - ISC
|
|
177
|
-
*
|
|
178
|
-
* This source code is licensed under the ISC license.
|
|
179
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
180
|
-
*/const Ef=$("HelpCircle",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M9.09 9a3 3 0 0 1 5.83 1c0 2-3 3-3 3",key:"1u773s"}],["path",{d:"M12 17h.01",key:"p32p05"}]]);/**
|
|
181
|
-
* @license lucide-react v0.298.0 - ISC
|
|
182
|
-
*
|
|
183
|
-
* This source code is licensed under the ISC license.
|
|
184
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
185
|
-
*/const bf=$("History",[["path",{d:"M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8",key:"1357e3"}],["path",{d:"M3 3v5h5",key:"1xhq8a"}],["path",{d:"M12 7v5l4 2",key:"1fdv2h"}]]);/**
|
|
186
|
-
* @license lucide-react v0.298.0 - ISC
|
|
187
|
-
*
|
|
188
|
-
* This source code is licensed under the ISC license.
|
|
189
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
190
|
-
*/const ss=$("Info",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 16v-4",key:"1dtifu"}],["path",{d:"M12 8h.01",key:"e9boi3"}]]);/**
|
|
191
|
-
* @license lucide-react v0.298.0 - ISC
|
|
192
|
-
*
|
|
193
|
-
* This source code is licensed under the ISC license.
|
|
194
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
195
|
-
*/const pc=$("Keyboard",[["rect",{width:"20",height:"16",x:"2",y:"4",rx:"2",ry:"2",key:"15u882"}],["path",{d:"M6 8h.001",key:"1ej0i3"}],["path",{d:"M10 8h.001",key:"1x2st2"}],["path",{d:"M14 8h.001",key:"1vkmyp"}],["path",{d:"M18 8h.001",key:"kfsenl"}],["path",{d:"M8 12h.001",key:"1sjpby"}],["path",{d:"M12 12h.001",key:"al75ts"}],["path",{d:"M16 12h.001",key:"931bgk"}],["path",{d:"M7 16h10",key:"wp8him"}]]);/**
|
|
196
|
-
* @license lucide-react v0.298.0 - ISC
|
|
197
|
-
*
|
|
198
|
-
* This source code is licensed under the ISC license.
|
|
199
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
200
|
-
*/const Ou=$("List",[["line",{x1:"8",x2:"21",y1:"6",y2:"6",key:"7ey8pc"}],["line",{x1:"8",x2:"21",y1:"12",y2:"12",key:"rjfblc"}],["line",{x1:"8",x2:"21",y1:"18",y2:"18",key:"c3b1m8"}],["line",{x1:"3",x2:"3.01",y1:"6",y2:"6",key:"1g7gq3"}],["line",{x1:"3",x2:"3.01",y1:"12",y2:"12",key:"1pjlvk"}],["line",{x1:"3",x2:"3.01",y1:"18",y2:"18",key:"28t2mc"}]]);/**
|
|
201
|
-
* @license lucide-react v0.298.0 - ISC
|
|
202
|
-
*
|
|
203
|
-
* This source code is licensed under the ISC license.
|
|
204
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
205
|
-
*/const et=$("Loader2",[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]]);/**
|
|
206
|
-
* @license lucide-react v0.298.0 - ISC
|
|
207
|
-
*
|
|
208
|
-
* This source code is licensed under the ISC license.
|
|
209
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
210
|
-
*/const Du=$("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"}]]);/**
|
|
211
|
-
* @license lucide-react v0.298.0 - ISC
|
|
212
|
-
*
|
|
213
|
-
* This source code is licensed under the ISC license.
|
|
214
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
215
|
-
*/const Sf=$("LogOut",[["path",{d:"M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4",key:"1uf3rs"}],["polyline",{points:"16 17 21 12 16 7",key:"1gabdz"}],["line",{x1:"21",x2:"9",y1:"12",y2:"12",key:"1uyos4"}]]);/**
|
|
216
|
-
* @license lucide-react v0.298.0 - ISC
|
|
217
|
-
*
|
|
218
|
-
* This source code is licensed under the ISC license.
|
|
219
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
220
|
-
*/const kf=$("Menu",[["line",{x1:"4",x2:"20",y1:"12",y2:"12",key:"1e0a9i"}],["line",{x1:"4",x2:"20",y1:"6",y2:"6",key:"1owob3"}],["line",{x1:"4",x2:"20",y1:"18",y2:"18",key:"yk5zj1"}]]);/**
|
|
221
|
-
* @license lucide-react v0.298.0 - ISC
|
|
222
|
-
*
|
|
223
|
-
* This source code is licensed under the ISC license.
|
|
224
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
225
|
-
*/const sa=$("MinusCircle",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M8 12h8",key:"1wcyev"}]]);/**
|
|
226
|
-
* @license lucide-react v0.298.0 - ISC
|
|
227
|
-
*
|
|
228
|
-
* This source code is licensed under the ISC license.
|
|
229
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
230
|
-
*/const Pu=$("Package",[["path",{d:"m7.5 4.27 9 5.15",key:"1c824w"}],["path",{d:"M21 8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.73l7 4a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16Z",key:"hh9hay"}],["path",{d:"m3.3 7 8.7 5 8.7-5",key:"g66t2b"}],["path",{d:"M12 22V12",key:"d0xqtd"}]]);/**
|
|
231
|
-
* @license lucide-react v0.298.0 - ISC
|
|
232
|
-
*
|
|
233
|
-
* This source code is licensed under the ISC license.
|
|
234
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
235
|
-
*/const ti=$("PenLine",[["path",{d:"M12 20h9",key:"t2du7b"}],["path",{d:"M16.5 3.5a2.12 2.12 0 0 1 3 3L7 19l-4 1 1-4Z",key:"ymcmye"}]]);/**
|
|
236
|
-
* @license lucide-react v0.298.0 - ISC
|
|
237
|
-
*
|
|
238
|
-
* This source code is licensed under the ISC license.
|
|
239
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
240
|
-
*/const Cf=$("Play",[["polygon",{points:"5 3 19 12 5 21 5 3",key:"191637"}]]);/**
|
|
241
|
-
* @license lucide-react v0.298.0 - ISC
|
|
242
|
-
*
|
|
243
|
-
* This source code is licensed under the ISC license.
|
|
244
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
245
|
-
*/const la=$("PlusCircle",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M8 12h8",key:"1wcyev"}],["path",{d:"M12 8v8",key:"napkw2"}]]);/**
|
|
246
|
-
* @license lucide-react v0.298.0 - ISC
|
|
247
|
-
*
|
|
248
|
-
* This source code is licensed under the ISC license.
|
|
249
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
250
|
-
*/const un=$("Plus",[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]]);/**
|
|
251
|
-
* @license lucide-react v0.298.0 - ISC
|
|
252
|
-
*
|
|
253
|
-
* This source code is licensed under the ISC license.
|
|
254
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
255
|
-
*/const pl=$("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"}]]);/**
|
|
256
|
-
* @license lucide-react v0.298.0 - ISC
|
|
257
|
-
*
|
|
258
|
-
* This source code is licensed under the ISC license.
|
|
259
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
260
|
-
*/const Af=$("Rocket",[["path",{d:"M4.5 16.5c-1.5 1.26-2 5-2 5s3.74-.5 5-2c.71-.84.7-2.13-.09-2.91a2.18 2.18 0 0 0-2.91-.09z",key:"m3kijz"}],["path",{d:"m12 15-3-3a22 22 0 0 1 2-3.95A12.88 12.88 0 0 1 22 2c0 2.72-.78 7.5-6 11a22.35 22.35 0 0 1-4 2z",key:"1fmvmk"}],["path",{d:"M9 12H4s.55-3.03 2-4c1.62-1.08 5 0 5 0",key:"1f8sc4"}],["path",{d:"M12 15v5s3.03-.55 4-2c1.08-1.62 0-5 0-5",key:"qeys4"}]]);/**
|
|
261
|
-
* @license lucide-react v0.298.0 - ISC
|
|
262
|
-
*
|
|
263
|
-
* This source code is licensed under the ISC license.
|
|
264
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
265
|
-
*/const Lu=$("Save",[["path",{d:"M19 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h11l5 5v11a2 2 0 0 1-2 2z",key:"1owoqh"}],["polyline",{points:"17 21 17 13 7 13 7 21",key:"1md35c"}],["polyline",{points:"7 3 7 8 15 8",key:"8nz8an"}]]);/**
|
|
266
|
-
* @license lucide-react v0.298.0 - ISC
|
|
267
|
-
*
|
|
268
|
-
* This source code is licensed under the ISC license.
|
|
269
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
270
|
-
*/const ls=$("Search",[["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}],["path",{d:"m21 21-4.3-4.3",key:"1qie3q"}]]);/**
|
|
271
|
-
* @license lucide-react v0.298.0 - ISC
|
|
272
|
-
*
|
|
273
|
-
* This source code is licensed under the ISC license.
|
|
274
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
275
|
-
*/const Tf=$("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"}]]);/**
|
|
276
|
-
* @license lucide-react v0.298.0 - ISC
|
|
277
|
-
*
|
|
278
|
-
* This source code is licensed under the ISC license.
|
|
279
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
280
|
-
*/const as=$("Sparkles",[["path",{d:"m12 3-1.912 5.813a2 2 0 0 1-1.275 1.275L3 12l5.813 1.912a2 2 0 0 1 1.275 1.275L12 21l1.912-5.813a2 2 0 0 1 1.275-1.275L21 12l-5.813-1.912a2 2 0 0 1-1.275-1.275L12 3Z",key:"17u4zn"}],["path",{d:"M5 3v4",key:"bklmnn"}],["path",{d:"M19 17v4",key:"iiml17"}],["path",{d:"M3 5h4",key:"nem4j1"}],["path",{d:"M17 19h4",key:"lbex7p"}]]);/**
|
|
281
|
-
* @license lucide-react v0.298.0 - ISC
|
|
282
|
-
*
|
|
283
|
-
* This source code is licensed under the ISC license.
|
|
284
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
285
|
-
*/const ri=$("Terminal",[["polyline",{points:"4 17 10 11 4 5",key:"akl6gq"}],["line",{x1:"12",x2:"20",y1:"19",y2:"19",key:"q2wloq"}]]);/**
|
|
286
|
-
* @license lucide-react v0.298.0 - ISC
|
|
287
|
-
*
|
|
288
|
-
* This source code is licensed under the ISC license.
|
|
289
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
290
|
-
*/const ni=$("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"}]]);/**
|
|
291
|
-
* @license lucide-react v0.298.0 - ISC
|
|
292
|
-
*
|
|
293
|
-
* This source code is licensed under the ISC license.
|
|
294
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
295
|
-
*/const _u=$("Wrench",[["path",{d:"M14.7 6.3a1 1 0 0 0 0 1.4l1.6 1.6a1 1 0 0 0 1.4 0l3.77-3.77a6 6 0 0 1-7.94 7.94l-6.91 6.91a2.12 2.12 0 0 1-3-3l6.91-6.91a6 6 0 0 1 7.94-7.94l-3.76 3.76z",key:"cbrjhi"}]]);/**
|
|
296
|
-
* @license lucide-react v0.298.0 - ISC
|
|
297
|
-
*
|
|
298
|
-
* This source code is licensed under the ISC license.
|
|
299
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
300
|
-
*/const ft=$("X",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]]);/**
|
|
301
|
-
* @license lucide-react v0.298.0 - ISC
|
|
302
|
-
*
|
|
303
|
-
* This source code is licensed under the ISC license.
|
|
304
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
305
|
-
*/const Zi=$("Zap",[["polygon",{points:"13 2 3 14 12 14 11 22 21 10 12 10 13 2",key:"45s27k"}]]),Rf=v.createContext();function If({children:e}){const[t,r]=v.useState([]),s=v.useCallback((i,o="info",c=3e3)=>{const d=Date.now();return r(f=>[...f,{id:d,message:i,type:o}]),c>0&&setTimeout(()=>{r(f=>f.filter(g=>g.id!==d))},c),d},[]),l=v.useCallback(i=>{r(o=>o.filter(c=>c.id!==i))},[]),a=v.useMemo(()=>({success:(i,o)=>s(i,"success",o),error:(i,o)=>s(i,"error",o),warning:(i,o)=>s(i,"warning",o),info:(i,o)=>s(i,"info",o)}),[s]);return n.jsxs(Rf.Provider,{value:{toast:a,removeToast:l},children:[e,n.jsx("div",{className:"fixed bottom-4 right-4 z-[200] space-y-2 pointer-events-none",children:t.map(i=>n.jsxs("div",{className:`pointer-events-auto flex items-center gap-3 px-4 py-3 border backdrop-blur-sm animate-slide-up ${i.type==="success"?"border-matrix/50 bg-matrix/10 text-matrix":i.type==="error"?"border-alert/50 bg-alert/10 text-alert":i.type==="warning"?"border-signal/50 bg-signal/10 text-signal":"border-cyber/50 bg-cyber/10 text-cyber"}`,children:[i.type==="success"&&n.jsx(Ie,{className:"w-4 h-4"}),i.type==="error"&&n.jsx(ft,{className:"w-4 h-4"}),i.type==="warning"&&n.jsx(Oe,{className:"w-4 h-4"}),i.type==="info"&&n.jsx(ss,{className:"w-4 h-4"}),n.jsx("span",{className:"font-mono text-sm",children:i.message}),n.jsx("button",{onClick:()=>l(i.id),className:"ml-2 opacity-60 hover:opacity-100",children:n.jsx(ft,{className:"w-3 h-3"})})]},i.id))})]})}function Of({isOpen:e,onClose:t,roadmap:r,onNavigate:s,t:l}){const[a,i]=v.useState(""),o=v.useRef(null);v.useEffect(()=>{e&&o.current&&o.current.focus()},[e]),v.useEffect(()=>{e||i("")},[e]);const c=v.useMemo(()=>{var h,x,N,E;if(!a.trim()||!r)return[];const d=a.toLowerCase(),f=[];(h=r.features)==null||h.forEach(b=>{var m,u,p;((m=b.name)!=null&&m.toLowerCase().includes(d)||(u=b.description)!=null&&u.toLowerCase().includes(d))&&f.push({type:"feature",id:b.id,name:b.name,description:b.description}),(p=b.tasks)==null||p.forEach(j=>{var S,R;((S=j.name)!=null&&S.toLowerCase().includes(d)||(R=j.description)!=null&&R.toLowerCase().includes(d))&&f.push({type:"task",id:j.id,name:j.name,featureName:b.name,status:j.status})})});const g=((x=r.project_info)==null?void 0:x.shared_resources)||{};return(N=g.ui_components)==null||N.forEach(b=>{var m,u;((m=b.path)!=null&&m.toLowerCase().includes(d)||(u=b.description)!=null&&u.toLowerCase().includes(d))&&f.push({type:"component",name:b.path,description:b.description})}),(E=g.utilities)==null||E.forEach(b=>{var m,u;((m=b.path)!=null&&m.toLowerCase().includes(d)||(u=b.description)!=null&&u.toLowerCase().includes(d))&&f.push({type:"utility",name:b.path,description:b.description})}),f.slice(0,10)},[a,r]);return e?n.jsx("div",{className:"fixed inset-0 bg-black/80 backdrop-blur-sm flex items-start justify-center pt-[15vh] z-[150]",onClick:t,children:n.jsx("div",{className:"w-full max-w-2xl mx-4 animate-slide-up",onClick:d=>d.stopPropagation(),children:n.jsxs("div",{className:"bg-void-200 border border-white/10",children:[n.jsxs("div",{className:"flex items-center gap-3 p-4 border-b border-white/10",children:[n.jsx(ls,{className:"w-5 h-5 text-gray-500"}),n.jsx("input",{ref:o,type:"text",value:a,onChange:d=>i(d.target.value),placeholder:l?l("common.search"):"Search features, tasks, resources...",className:"flex-1 bg-transparent font-mono text-sm text-white placeholder-gray-600 outline-none"}),n.jsx("kbd",{className:"px-2 py-1 bg-void-100 border border-white/10 text-gray-600 font-mono text-[10px]",children:"ESC"})]}),n.jsx("div",{className:"max-h-80 overflow-y-auto",children:a.trim()===""?n.jsxs("div",{className:"p-8 text-center",children:[n.jsx(hf,{className:"w-10 h-10 mx-auto mb-3 text-gray-700"}),n.jsx("p",{className:"font-mono text-xs text-gray-600",children:l?l("common.search")+"...":"Type to search..."})]}):c.length===0?n.jsxs("div",{className:"p-8 text-center",children:[n.jsx(ls,{className:"w-10 h-10 mx-auto mb-3 text-gray-700"}),n.jsx("p",{className:"font-mono text-xs text-gray-600",children:"No results found"})]}):n.jsx("div",{className:"p-2",children:c.map((d,f)=>{var g;return n.jsxs("button",{onClick:()=>{d.type==="feature"||d.type==="task"?s("features"):(d.type==="component"||d.type==="utility")&&s("resources"),t()},className:"w-full flex items-center gap-3 p-3 hover:bg-white/5 transition-all text-left",children:[n.jsxs("div",{className:`w-8 h-8 border flex items-center justify-center ${d.type==="feature"?"border-matrix/50 bg-matrix/10":d.type==="task"?"border-signal/50 bg-signal/10":"border-cyber/50 bg-cyber/10"}`,children:[d.type==="feature"&&n.jsx(Zi,{className:"w-4 h-4 text-matrix"}),d.type==="task"&&n.jsx(Ie,{className:"w-4 h-4 text-signal"}),d.type==="component"&&n.jsx(Pu,{className:"w-4 h-4 text-cyber"}),d.type==="utility"&&n.jsx(Tu,{className:"w-4 h-4 text-cyber"})]}),n.jsxs("div",{className:"flex-1 min-w-0",children:[n.jsx("div",{className:"font-mono text-sm text-white truncate",children:d.name}),n.jsxs("div",{className:"font-mono text-[10px] text-gray-500 truncate",children:[d.type==="task"&&d.featureName?`${d.featureName} • `:"",((g=d.description)==null?void 0:g.slice(0,60))||d.type]})]}),d.status&&n.jsx("span",{className:`px-2 py-0.5 text-[9px] font-mono ${d.status==="completed"?"bg-matrix/20 text-matrix":d.status==="in_progress"?"bg-signal/20 text-signal":"bg-gray-700 text-gray-400"}`,children:d.status})]},`${d.type}-${d.id||d.name}-${f}`)})})}),n.jsx("div",{className:"p-3 border-t border-white/10 flex items-center justify-between",children:n.jsxs("div",{className:"flex items-center gap-4 text-gray-600 font-mono text-[10px]",children:[n.jsxs("span",{children:[n.jsx("kbd",{className:"px-1 bg-void-100 border border-white/10",children:"↑↓"})," Navigate"]}),n.jsxs("span",{children:[n.jsx("kbd",{className:"px-1 bg-void-100 border border-white/10",children:"↵"})," Select"]})]})})]})})}):null}function Df(e){v.useEffect(()=>{const t=r=>{var s,l,a,i,o;if(r.target.tagName==="INPUT"||r.target.tagName==="TEXTAREA"){r.key==="Escape"&&e.onEscape&&e.onEscape();return}if((r.ctrlKey||r.metaKey)&&r.key==="k"){r.preventDefault(),(s=e.onSearch)==null||s.call(e);return}if((r.ctrlKey||r.metaKey)&&r.key==="s"){r.preventDefault(),(l=e.onSave)==null||l.call(e);return}if(!r.ctrlKey&&!r.metaKey&&!r.altKey&&r.key>="1"&&r.key<="7"){r.preventDefault(),(a=e.onTabChange)==null||a.call(e,parseInt(r.key)-1);return}if(r.key==="Escape"){(i=e.onEscape)==null||i.call(e);return}if(r.key==="?"&&!r.shiftKey){(o=e.onHelp)==null||o.call(e);return}};return window.addEventListener("keydown",t),()=>window.removeEventListener("keydown",t)},[e])}const Pf=v.createContext();function Lf({children:e}){const[t,r]=v.useState(()=>{try{const a=localStorage.getItem("roadmap-kit-activities");return a?JSON.parse(a):[]}catch{return[]}}),s=v.useCallback((a,i={})=>{const o={id:Date.now(),action:a,details:i,timestamp:new Date().toISOString(),user:i.user||"System"};r(c=>{const d=[o,...c].slice(0,100);return localStorage.setItem("roadmap-kit-activities",JSON.stringify(d)),d})},[]),l=v.useCallback(()=>{r([]),localStorage.removeItem("roadmap-kit-activities")},[]);return n.jsx(Pf.Provider,{value:{activities:t,logActivity:s,clearActivities:l},children:e})}const fc={en:{nav:{setup:"SETUP",features:"FEATURES",resources:"RESOURCES",debt:"DEBT",info:"INFO",settings:"SETTINGS",help:"HELP"},common:{save:"SAVE",cancel:"CANCEL",confirm:"CONFIRM",delete:"DELETE",edit:"EDIT",add:"ADD",close:"CLOSE",loading:"Loading...",error:"Error",success:"Success",search:"Search...",all:"All",pending:"Pending",inProgress:"In Progress",completed:"Completed",high:"High",medium:"Medium",low:"Low",copy:"Copy",copied:"Copied",download:"Download",deploy:"Deploy",refresh:"Refresh",retry:"Retry",ok:"OK",yes:"Yes",no:"No"},auth:{login:"LOGIN",logout:"LOGOUT",email:"Email",password:"Password",loginTitle:"ACCESS REQUIRED",loginSubtitle:"Enter your credentials",loginButton:"AUTHENTICATE",loginError:"Invalid credentials",verifyingAccess:"> VERIFYING ACCESS...",loadingRoadmap:"> LOADING ROADMAP..."},sidebar:{projectRoadmap:"PROJECT ROADMAP",saveChanges:"SAVE CHANGES",saving:"SAVING...",saved:"SAVED",unsavedChanges:"Unsaved changes",addFeature:"ADD FEATURE",aiGenerate:"AI GENERATE",collapse:"Collapse"},stats:{total:"TOTAL",completed:"DONE",inProgress:"ACTIVE",pending:"TODO",debts:"DEBTS"},features:{title:"FEATURES",noFeatures:"NO FEATURES",addFirst:"Add your first feature to start tracking progress",addFeature:"ADD FEATURE",tasks:"tasks",addTask:"ADD TASK",taskName:"Task name",taskDescription:"Task description",priority:"Priority",assignTo:"Assign to",unassigned:"Unassigned",markComplete:"Mark complete",markPending:"Mark pending",deleteTask:"Delete task",aiNotes:"AI Notes",technicalDebt:"Technical Debt",affectedFiles:"Affected Files",featureName:"Feature name",featureDescription:"Feature description"},resources:{title:"SHARED RESOURCES",subtitle:"Components and utilities that AI should reuse",uiComponents:"UI COMPONENTS",utilities:"UTILITIES",dbTables:"DATABASE TABLES",noComponents:"No components registered",noUtilities:"No utilities registered",noTables:"No tables registered",usage:"Usage",exports:"Exports",fields:"Fields",warning:"Warning"},debt:{title:"TECHNICAL DEBT",subtitle:"Issues to address in future iterations",noDebt:"NO TECHNICAL DEBT",noDebtDesc:"Great! No pending technical debt registered",severity:"Severity",effort:"Effort",source:"Source",bySeverity:"BY SEVERITY",items:"items"},info:{title:"PROJECT INFO",version:"Version",lastSync:"Last Sync",stack:"Tech Stack",architecture:"Architecture",purpose:"Purpose",conventions:"Conventions",naming:"Naming",fileStructure:"File Structure",database:"Database",styling:"Styling",errorHandling:"Error Handling"},settings:{title:"SETTINGS",profile:"PROFILE",users:"USERS",history:"HISTORY",files:"FILES",language:"LANGUAGE",yourProfile:"YOUR PROFILE",name:"Name",currentPassword:"Current Password",newPassword:"New Password",updateProfile:"UPDATE PROFILE",authRequired:"Authentication Required",authRequiredDesc:"Disable to allow anonymous access",addUser:"ADD USER",role:"Role",admin:"Admin",member:"Member",createdAt:"Created",lastLogin:"Last Login",never:"Never",deleteUser:"Delete user",editUser:"Edit user",createUser:"CREATE USER",updateUser:"UPDATE USER",versionHistory:"VERSION HISTORY",lastChanges:"Last {count} changes",clickToPreview:"Click to preview & restore",noVersions:"NO VERSIONS YET",versionsAutoSaved:"Versions are saved automatically when you save changes",loadHistory:"LOAD HISTORY",versionDiff:"VERSION DIFF",restoreVersion:"RESTORE THIS VERSION",restoreTitle:"RESTORE VERSION",restoreMessage:"This will restore the selected version. A backup of the current state will be saved first.",restore:"RESTORE",restored:"VERSION RESTORED",restoredMessage:"The roadmap has been restored successfully. A backup was saved.",restoreFailed:"RESTORE FAILED",added:"ADDED",removed:"REMOVED",modified:"MODIFIED",noChanges:"NO CHANGES",matchesVersion:"Current roadmap matches this version",viewRawJson:"View raw JSON",closePreview:"CLOSE PREVIEW",feature:"FEATURE",projectFiles:"PROJECT FILES",clinerules:".clinerules",clinerulesDesc:"AI rules file",roadmapJson:"roadmap.json",roadmapJsonDesc:"Project roadmap data",editJson:"EDIT JSON",viewJson:"VIEW JSON",applyChanges:"APPLY",invalidJson:"Invalid JSON",deployFiles:"DEPLOY FILES",deployBoth:"Deploy both .clinerules and .cursorrules",deploying:"DEPLOYING...",downloadFiles:"DOWNLOAD FILES"},help:{title:"HELP",templates:"TEMPLATES",commits:"COMMITS",aiWorkflow:"AI WORKFLOW",debug:"DEBUG",referenceFiles:"# REFERENCE FILES FOR AI",sharePaths:"Share these paths with your AI assistant:",clinerulesTpl:"CLINERULES TEMPLATE",roadmapTpl:"ROADMAP TEMPLATE",exampleEcommerce:"EXAMPLE: E-COMMERCE",exampleApi:"EXAMPLE: API REST",debtGuide:"DEBT GUIDE",aiInstructions:"# AI INSTRUCTIONS",quickPrompt:"QUICK PROMPT",copyPrompt:"COPY PROMPT",commitFormat:"# COMMIT FORMAT",commitFormatDesc:"Use this format for auto-updating roadmap:",availableTags:"AVAILABLE TAGS:",tag:"TAG",values:"VALUES",example:"EXAMPLE",examples:"EXAMPLES:",completeTask:"# Complete a task",taskInProgress:"# Task in progress",withDebt:"# With technical debt",syncWithGit:"SYNC WITH GIT",afterCommits:"After commits, run:",updatesInfo:"This updates: task status, metrics, debt, and progress.",recommendedWorkflow:"# RECOMMENDED WORKFLOW",step01:"AI reads .clinerules and roadmap.json",step02:"AI checks shared_resources before creating code",step03:"AI updates roadmap and commits with tags",aiMustDo:"AI MUST DO",aiMustNot:"AI MUST NOT",mustDoList:["Read task description before starting","Check shared resources before creating code","Reuse existing components and utilities","Follow project conventions","Register technical debt if incomplete","Use correct commit format"],mustNotList:["Create duplicate components","Ignore project conventions","Forget to register technical debt","Commit without required tags","Modify shared resources without reason"],troubleshooting:"# TROUBLESHOOTING",fileSummary:"FILE SUMMARY:",file:"FILE",location:"LOCATION",purposeCol:"PURPOSE",projectState:"Project state",aiRules:"AI rules",cursorRules:"Cursor rules",config:"Configuration"},setup:{title:"AI SETUP WIZARD",subtitle:"Describe your project and Claude will generate the configuration",requirements:"REQUIREMENTS",requirementsPlaceholder:"Describe the features, functionality or improvements you want to add to your project...",projectScan:"PROJECT SCAN",scanning:"Scanning project...",scanComplete:"Scan complete",files:"files",techStack:"Tech Stack",analyze:"ANALYZE WITH AI",analyzing:"Analyzing...",claudeCode:"Claude Code CLI",available:"Available",notAvailable:"Not available",usingSubscription:"Using your Claude subscription",setupComplete:"SETUP COMPLETE",setupCompleteDesc:"Your roadmap is configured and ready to use",roadmapStatus:"ROADMAP STATUS",goToDashboard:"GO TO DASHBOARD",reconfigure:"RECONFIGURE",stepConnect:"CONNECT",stepDescribe:"DESCRIBE",stepReview:"REVIEW",stepDone:"DONE",chooseConnection:"CHOOSE CONNECTION MODE",chooseConnectionDesc:"Choose how to connect with Claude to generate your project configuration.",recommended:"RECOMMENDED",apiKeyMode:"API KEY",apiKeyDesc:"Use an Anthropic API key. Pay per use (~$0.05-0.15 per generation).",apiKeyConfigured:"API Key configured",noApiKey:"No API Key configured",installClaudeCode:"INSTALL CLAUDE CODE",installClaudeCodeDesc:"To use your subscription, you need Claude Code installed and authenticated.",verifyAgain:"VERIFY AGAIN",continueWith:"CONTINUE WITH CLAUDE CODE",roadmapComplete:"ROADMAP COMPLETE",roadmapIncomplete:"ROADMAP INCOMPLETE",roadmapNeedsReview:"ROADMAP NEEDS REVIEW",issuesToFix:"ISSUES TO FIX",warnings:"WARNINGS",continueToDashboard:"CONTINUE TO DASHBOARD",regenerateAnyway:"REGENERATE ANYWAY",aiFixIssues:"AI FIX ISSUES",skipAnyway:"SKIP ANYWAY",projectAnalysis:"PROJECT ANALYSIS",keyFiles:"KEY FILES",allFiles:"ALL FILES",requirementsDesc:"Describe the features, functionality or improvements you want to implement. Claude will analyze your project and generate a structured roadmap.",analyzeGenerate:"ANALYZE & GENERATE ROADMAP",analyzingProject:"ANALYZING PROJECT...",analysisSummary:"ANALYSIS SUMMARY",suggestions:"SUGGESTIONS",generatedRoadmap:"GENERATED ROADMAP",featuresPreview:"FEATURES PREVIEW",applyConfig:"APPLY CONFIGURATION",setupDone:"SETUP COMPLETE",setupDoneDesc:"Your roadmap.json and .clinerules have been generated and saved.",startOver:"START OVER",viewDashboard:"VIEW DASHBOARD"},modals:{addFeature:"ADD FEATURE",editFeature:"EDIT FEATURE",addTask:"ADD TASK",deleteConfirm:"Are you sure you want to delete this?",unsavedWarning:"You have unsaved changes. Are you sure you want to leave?"}},es:{nav:{setup:"ASISTENTE",features:"ESTADO",resources:"RECURSOS",debt:"DEUDA",info:"INFO",settings:"CONFIG",help:"AYUDA"},common:{save:"GUARDAR",cancel:"CANCELAR",confirm:"CONFIRMAR",delete:"ELIMINAR",edit:"EDITAR",add:"AÑADIR",close:"CERRAR",loading:"Cargando...",error:"Error",success:"Éxito",search:"Buscar...",all:"Todos",pending:"Pendiente",inProgress:"En Progreso",completed:"Completado",high:"Alta",medium:"Media",low:"Baja",copy:"Copiar",copied:"Copiado",download:"Descargar",deploy:"Desplegar",refresh:"Actualizar",retry:"Reintentar",ok:"OK",yes:"Sí",no:"No"},auth:{login:"INICIAR SESIÓN",logout:"CERRAR SESIÓN",email:"Email",password:"Contraseña",loginTitle:"ACCESO REQUERIDO",loginSubtitle:"Introduce tus credenciales",loginButton:"AUTENTICAR",loginError:"Credenciales inválidas",verifyingAccess:"> VERIFICANDO ACCESO...",loadingRoadmap:"> CARGANDO ROADMAP..."},sidebar:{projectRoadmap:"ROADMAP DEL PROYECTO",saveChanges:"GUARDAR CAMBIOS",saving:"GUARDANDO...",saved:"GUARDADO",unsavedChanges:"Cambios sin guardar",addFeature:"AÑADIR FEATURE",aiGenerate:"GENERAR CON IA",collapse:"Colapsar"},stats:{total:"TOTAL",completed:"LISTO",inProgress:"ACTIVO",pending:"PEND.",debts:"DEUDAS"},features:{title:"FEATURES",noFeatures:"SIN FEATURES",addFirst:"Añade tu primera feature para empezar a trackear el progreso",addFeature:"AÑADIR FEATURE",tasks:"tareas",addTask:"AÑADIR TAREA",taskName:"Nombre de la tarea",taskDescription:"Descripción de la tarea",priority:"Prioridad",assignTo:"Asignar a",unassigned:"Sin asignar",markComplete:"Marcar completada",markPending:"Marcar pendiente",deleteTask:"Eliminar tarea",aiNotes:"Notas de IA",technicalDebt:"Deuda Técnica",affectedFiles:"Archivos Afectados",featureName:"Nombre de la feature",featureDescription:"Descripción de la feature"},resources:{title:"RECURSOS COMPARTIDOS",subtitle:"Componentes y utilidades que la IA debe reutilizar",uiComponents:"COMPONENTES UI",utilities:"UTILIDADES",dbTables:"TABLAS DE BD",noComponents:"Sin componentes registrados",noUtilities:"Sin utilidades registradas",noTables:"Sin tablas registradas",usage:"Uso",exports:"Exporta",fields:"Campos",warning:"Advertencia"},debt:{title:"DEUDA TÉCNICA",subtitle:"Problemas a resolver en futuras iteraciones",noDebt:"SIN DEUDA TÉCNICA",noDebtDesc:"¡Genial! No hay deuda técnica pendiente registrada",severity:"Severidad",effort:"Esfuerzo",source:"Origen",bySeverity:"POR SEVERIDAD",items:"elementos"},info:{title:"INFO DEL PROYECTO",version:"Versión",lastSync:"Última Sync",stack:"Stack Técnico",architecture:"Arquitectura",purpose:"Propósito",conventions:"Convenciones",naming:"Nomenclatura",fileStructure:"Estructura de Archivos",database:"Base de Datos",styling:"Estilos",errorHandling:"Manejo de Errores"},settings:{title:"CONFIGURACIÓN",profile:"PERFIL",users:"USUARIOS",history:"HISTORIAL",files:"ARCHIVOS",language:"IDIOMA",yourProfile:"TU PERFIL",name:"Nombre",currentPassword:"Contraseña Actual",newPassword:"Nueva Contraseña",updateProfile:"ACTUALIZAR PERFIL",authRequired:"Autenticación Requerida",authRequiredDesc:"Desactiva para permitir acceso anónimo",addUser:"AÑADIR USUARIO",role:"Rol",admin:"Admin",member:"Miembro",createdAt:"Creado",lastLogin:"Último Login",never:"Nunca",deleteUser:"Eliminar usuario",editUser:"Editar usuario",createUser:"CREAR USUARIO",updateUser:"ACTUALIZAR USUARIO",versionHistory:"HISTORIAL DE VERSIONES",lastChanges:"Últimos {count} cambios",clickToPreview:"Click para previsualizar y restaurar",noVersions:"SIN VERSIONES AÚN",versionsAutoSaved:"Las versiones se guardan automáticamente al guardar cambios",loadHistory:"CARGAR HISTORIAL",versionDiff:"DIFF DE VERSIÓN",restoreVersion:"RESTAURAR ESTA VERSIÓN",restoreTitle:"RESTAURAR VERSIÓN",restoreMessage:"Esto restaurará la versión seleccionada. Se guardará una copia del estado actual primero.",restore:"RESTAURAR",restored:"VERSIÓN RESTAURADA",restoredMessage:"El roadmap ha sido restaurado correctamente. Se guardó una copia de respaldo.",restoreFailed:"ERROR AL RESTAURAR",added:"AÑADIDO",removed:"ELIMINADO",modified:"MODIFICADO",noChanges:"SIN CAMBIOS",matchesVersion:"El roadmap actual coincide con esta versión",viewRawJson:"Ver JSON raw",closePreview:"CERRAR PREVIEW",feature:"FEATURE",projectFiles:"ARCHIVOS DEL PROYECTO",clinerules:".clinerules",clinerulesDesc:"Archivo de reglas para IA",roadmapJson:"roadmap.json",roadmapJsonDesc:"Datos del roadmap",editJson:"EDITAR JSON",viewJson:"VER JSON",applyChanges:"APLICAR",invalidJson:"JSON inválido",deployFiles:"DESPLEGAR ARCHIVOS",deployBoth:"Desplegar ambos .clinerules y .cursorrules",deploying:"DESPLEGANDO...",downloadFiles:"DESCARGAR ARCHIVOS"},help:{title:"AYUDA",templates:"PLANTILLAS",commits:"COMMITS",aiWorkflow:"FLUJO IA",debug:"DEBUG",referenceFiles:"# ARCHIVOS DE REFERENCIA PARA IA",sharePaths:"Comparte estas rutas con tu asistente IA:",clinerulesTpl:"PLANTILLA CLINERULES",roadmapTpl:"PLANTILLA ROADMAP",exampleEcommerce:"EJEMPLO: E-COMMERCE",exampleApi:"EJEMPLO: API REST",debtGuide:"GUÍA DE DEUDA",aiInstructions:"# INSTRUCCIONES PARA IA",quickPrompt:"PROMPT RÁPIDO",copyPrompt:"COPIAR PROMPT",commitFormat:"# FORMATO DE COMMITS",commitFormatDesc:"Usa este formato para actualizar el roadmap automáticamente:",availableTags:"TAGS DISPONIBLES:",tag:"TAG",values:"VALORES",example:"EJEMPLO",examples:"EJEMPLOS:",completeTask:"# Completar una tarea",taskInProgress:"# Tarea en progreso",withDebt:"# Con deuda técnica",syncWithGit:"SINCRONIZAR CON GIT",afterCommits:"Después de los commits, ejecuta:",updatesInfo:"Esto actualiza: estado de tareas, métricas, deuda y progreso.",recommendedWorkflow:"# FLUJO DE TRABAJO RECOMENDADO",step01:"La IA lee .clinerules y roadmap.json",step02:"La IA verifica shared_resources antes de crear código",step03:"La IA actualiza el roadmap y hace commits con tags",aiMustDo:"LA IA DEBE",aiMustNot:"LA IA NO DEBE",mustDoList:["Leer la descripción de la tarea antes de empezar","Verificar recursos compartidos antes de crear código","Reutilizar componentes y utilidades existentes","Seguir las convenciones del proyecto","Registrar deuda técnica si queda incompleto","Usar el formato de commit correcto"],mustNotList:["Crear componentes duplicados","Ignorar las convenciones del proyecto","Olvidar registrar deuda técnica","Hacer commits sin los tags requeridos","Modificar recursos compartidos sin razón"],troubleshooting:"# SOLUCIÓN DE PROBLEMAS",fileSummary:"RESUMEN DE ARCHIVOS:",file:"ARCHIVO",location:"UBICACIÓN",purposeCol:"PROPÓSITO",projectState:"Estado del proyecto",aiRules:"Reglas de IA",cursorRules:"Reglas de Cursor",config:"Configuración"},setup:{title:"ASISTENTE DE CONFIGURACIÓN IA",subtitle:"Describe tu proyecto y Claude generará la configuración",requirements:"REQUISITOS",requirementsPlaceholder:"Describe las features, funcionalidades o mejoras que quieres añadir a tu proyecto...",projectScan:"ESCANEO DEL PROYECTO",scanning:"Escaneando proyecto...",scanComplete:"Escaneo completo",files:"archivos",techStack:"Stack Tecnológico",analyze:"ANALIZAR CON IA",analyzing:"Analizando...",claudeCode:"Claude Code CLI",available:"Disponible",notAvailable:"No disponible",usingSubscription:"Usando tu suscripción de Claude",setupComplete:"CONFIGURACIÓN COMPLETA",setupCompleteDesc:"Tu roadmap está configurado y listo para usar",roadmapStatus:"ESTADO DEL ROADMAP",goToDashboard:"IR AL DASHBOARD",reconfigure:"RECONFIGURAR",stepConnect:"CONECTAR",stepDescribe:"DESCRIBIR",stepReview:"REVISAR",stepDone:"LISTO",chooseConnection:"ELEGIR MODO DE CONEXIÓN",chooseConnectionDesc:"Elige cómo conectar con Claude para generar la configuración de tu proyecto.",recommended:"RECOMENDADO",apiKeyMode:"API KEY",apiKeyDesc:"Usa una API key de Anthropic. Pago por uso (~$0.05-0.15 por generación).",apiKeyConfigured:"API Key configurada",noApiKey:"Sin API Key configurada",installClaudeCode:"INSTALAR CLAUDE CODE",installClaudeCodeDesc:"Para usar tu suscripción, necesitas tener Claude Code instalado y autenticado.",verifyAgain:"VERIFICAR DE NUEVO",continueWith:"CONTINUAR CON CLAUDE CODE",roadmapComplete:"ROADMAP COMPLETO",roadmapIncomplete:"ROADMAP INCOMPLETO",roadmapNeedsReview:"ROADMAP NECESITA REVISIÓN",issuesToFix:"PROBLEMAS A CORREGIR",warnings:"ADVERTENCIAS",continueToDashboard:"CONTINUAR AL DASHBOARD",regenerateAnyway:"REGENERAR DE TODOS MODOS",aiFixIssues:"IA CORREGIR PROBLEMAS",skipAnyway:"SALTAR DE TODOS MODOS",projectAnalysis:"ANÁLISIS DEL PROYECTO",keyFiles:"ARCHIVOS CLAVE",allFiles:"TODOS LOS ARCHIVOS",requirementsDesc:"Describe las características, funcionalidades o mejoras que quieres implementar. Claude analizará tu proyecto y generará un roadmap estructurado.",analyzeGenerate:"ANALIZAR Y GENERAR ROADMAP",analyzingProject:"ANALIZANDO PROYECTO...",analysisSummary:"RESUMEN DEL ANÁLISIS",suggestions:"SUGERENCIAS",generatedRoadmap:"ROADMAP GENERADO",featuresPreview:"PREVIEW DE FEATURES",applyConfig:"APLICAR CONFIGURACIÓN",setupDone:"CONFIGURACIÓN COMPLETA",setupDoneDesc:"Tu roadmap.json y .clinerules han sido generados y guardados.",startOver:"EMPEZAR DE NUEVO",viewDashboard:"VER DASHBOARD"},modals:{addFeature:"AÑADIR FEATURE",editFeature:"EDITAR FEATURE",addTask:"AÑADIR TAREA",deleteConfirm:"¿Estás seguro de que quieres eliminar esto?",unsavedWarning:"Tienes cambios sin guardar. ¿Estás seguro de que quieres salir?"}}};v.createContext();function _f(e,t){const r={features:{added:[],removed:[],modified:[]},tasks:{added:[],removed:[],statusChanged:[]},projectInfo:{changed:[]},summary:{added:0,removed:0,modified:0}};if(!e||!t)return r;const s=e.features||[],l=t.features||[],a=new Map(s.map(d=>[d.id,d])),i=new Map(l.map(d=>[d.id,d]));s.forEach(d=>{i.has(d.id)||(r.features.added.push(d),r.summary.added++,(d.tasks||[]).forEach(f=>{r.tasks.added.push({...f,featureName:d.name}),r.summary.added++}))}),l.forEach(d=>{a.has(d.id)||(r.features.removed.push(d),r.summary.removed++,(d.tasks||[]).forEach(f=>{r.tasks.removed.push({...f,featureName:d.name}),r.summary.removed++}))}),s.forEach(d=>{const f=i.get(d.id);if(f){const g=d.tasks||[],h=f.tasks||[],x=new Map(g.map(b=>[b.id,b])),N=new Map(h.map(b=>[b.id,b]));let E=!1;g.forEach(b=>{if(!N.has(b.id))r.tasks.added.push({...b,featureName:d.name}),r.summary.added++,E=!0;else{const m=N.get(b.id);m.status!==b.status&&(r.tasks.statusChanged.push({task:b,featureName:d.name,oldStatus:m.status,newStatus:b.status}),r.summary.modified++,E=!0)}}),h.forEach(b=>{x.has(b.id)||(r.tasks.removed.push({...b,featureName:f.name}),r.summary.removed++,E=!0)}),(E||d.progress!==f.progress)&&r.features.modified.push({current:d,version:f})}});const o=e.project_info||{},c=t.project_info||{};return o.name!==c.name&&r.projectInfo.changed.push({field:"name",old:c.name,new:o.name}),o.description!==c.description&&r.projectInfo.changed.push({field:"description",old:c.description,new:o.description}),r}function Mf(){var oe,it,yt,Xe,gn,ot,Lr,yn;const[e,t]=v.useState(null),[r,s]=v.useState(!0),[l,a]=v.useState(!1),[i,o]=v.useState(null),[c,d]=v.useState("features"),[f,g]=v.useState(""),[h,x]=v.useState("all"),[N,E]=v.useState(!1),[b,m]=v.useState(null),[u,p]=v.useState(!1),[j,S]=v.useState(!1),[R,y]=v.useState(!1),[T,P]=v.useState(!1),[C,L]=v.useState(!1),[D,_]=v.useState(!1),[Y,F]=v.useState(!1),[Ne,xe]=v.useState("list"),[k,V]=v.useState("all"),[H,Z]=v.useState("all"),[G,gt]=v.useState(()=>typeof window<"u"&&localStorage.getItem("roadmap-kit-language")||"es"),$e=O=>{gt(O),localStorage.setItem("roadmap-kit-language",O)},J=v.useCallback((O,B={})=>{const K=(te,ne)=>ne.split(".").reduce((je,ct)=>je==null?void 0:je[ct],te);let Q=K(fc[G],O);return Q===void 0&&(Q=K(fc.en,O)),Q===void 0?O:(typeof Q=="string"&&Object.entries(B).forEach(([te,ne])=>{Q=Q.replace(`{${te}}`,ne)}),Q)},[G]),[me,Te]=v.useState({checking:!0,authenticated:!1,authEnabled:!1}),[Ot,hr]=v.useState(null),[Dr,Bt]=v.useState([]),[ee,Le]=v.useState({show:!1,title:"",message:"",type:"warning",confirmText:"CONFIRM",cancelText:"CANCEL",onConfirm:null,onCancel:null}),xn=O=>new Promise(B=>{Le({show:!0,title:O.title||"Confirm",message:O.message||"Are you sure?",type:O.type||"warning",confirmText:O.confirmText||"CONFIRM",cancelText:O.cancelText||"CANCEL",onConfirm:()=>{Le(K=>({...K,show:!1})),B(!0)},onCancel:()=>{Le(K=>({...K,show:!1})),B(!1)}})}),hn=O=>{Le({show:!0,title:O.title||(O.type==="success"?"Success":O.type==="error"?"Error":"Info"),message:O.message,type:O.type||"info",confirmText:"OK",cancelText:null,onConfirm:()=>Le(B=>({...B,show:!1})),onCancel:null})};v.useEffect(()=>{at()},[]);const he=async()=>{try{const O=await fetch("/api/team-members");if(O.ok){const B=await O.json();Bt(B.members||[])}}catch(O){console.error("Error loading team members:",O)}},at=async()=>{try{const B=await(await fetch("/api/auth/status")).json();Te({checking:!1,authenticated:B.authenticated,authEnabled:B.authEnabled,user:B.user||null}),(B.authenticated||!B.authEnabled)&&(z(),he())}catch{Te({checking:!1,authenticated:!0,authEnabled:!1,user:null}),z(),he()}},gr=async(O,B)=>{hr(null);try{const K=await fetch("/api/auth/login",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({email:O,password:B})}),Q=await K.json();K.ok?(Te({checking:!1,authenticated:!0,authEnabled:!0,user:Q.user}),z()):hr(Q.error||"Error de autenticacion")}catch{hr("Error de conexion")}},A=async()=>{try{await fetch("/api/auth/logout",{method:"POST"}),Te({checking:!1,authenticated:!1,authEnabled:!0,user:null}),t(null)}catch(O){console.error("Logout error:",O)}},z=async()=>{try{s(!0),o(null);const O=await fetch("/roadmap.json");if(O.status===401&&(await O.json().catch(()=>({}))).requiresAuth){Te({checking:!1,authenticated:!1,authEnabled:!0}),s(!1);return}if(!O.ok)throw new Error("No se pudo cargar roadmap.json");const B=await O.json();t(B),E(!1)}catch(O){o(O.message)}finally{s(!1)}},[ae,pe]=v.useState(null);v.useEffect(()=>{var je;if(!(e!=null&&e.project_info))return;const O=((je=e.project_info.theme)==null?void 0:je.color)||"#00ff88",B=e.project_info.name||"Roadmap";document.title=`${B} | Roadmap`;const K=document.createElement("canvas");K.width=32,K.height=32;const Q=K.getContext("2d");Q.fillStyle=O,Q.beginPath(),Q.roundRect(2,2,28,28,6),Q.fill(),Q.strokeStyle="rgba(255,255,255,0.3)",Q.lineWidth=2,Q.beginPath(),Q.roundRect(4,4,24,24,4),Q.stroke();const te=K.toDataURL("image/png");let ne=document.querySelector('link[rel="icon"]');ne||(ne=document.createElement("link"),ne.rel="icon",document.head.appendChild(ne)),ne.href=te},[(it=(oe=e==null?void 0:e.project_info)==null?void 0:oe.theme)==null?void 0:it.color,(yt=e==null?void 0:e.project_info)==null?void 0:yt.name]);const qe=async()=>{try{a(!0),pe(null);const O=await fetch("/api/save-roadmap",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(e)});if(O.status===401&&(await O.json()).requiresAuth){Te({checking:!1,authenticated:!1,authEnabled:!0});return}if(!O.ok){const B=await O.json().catch(()=>({}));throw new Error(B.error||"Error al guardar")}E(!1),pe({type:"success",text:"SYNC OK"}),setTimeout(()=>pe(null),3e3)}catch(O){pe({type:"error",text:`ERR: ${O.message}`}),setTimeout(()=>pe(null),5e3)}finally{a(!1)}},Wt=v.useCallback((O,B,K)=>{t(Q=>{const te=JSON.parse(JSON.stringify(Q)),ne=te.features.find(ce=>ce.id===O);if(ne){const ce=ne.tasks.find(_r=>_r.id===B);if(ce){if(ce.status=K,K==="completed"&&!ce.completed_at){if(ce.completed_at=new Date().toISOString(),ce.assigned_name)ce.completed_by=ce.assigned_name;else if(ce.assigned_to){const w=(te.project_info.team||[]).find(U=>U.id===ce.assigned_to);ce.completed_by=(w==null?void 0:w.name)||"Unknown"}}K==="in_progress"&&!ce.started_at&&(ce.started_at=new Date().toISOString()),K!=="completed"&&(ce.completed_by=null,ce.completed_at=null);const _r=ne.tasks.filter(w=>w.status==="completed").length;ne.progress=Math.round(_r/ne.tasks.length*100)}}const je=te.features.flatMap(ce=>ce.tasks),ct=je.filter(ce=>ce.status==="completed").length;return te.project_info.total_progress=Math.round(ct/je.length*100),te}),E(!0)},[]),Dt=v.useCallback((O,B)=>{t(K=>{const Q=JSON.parse(JSON.stringify(K)),te=Q.features.find(ne=>ne.id===O);if(te){te.tasks.push({id:`${O}-${Date.now()}`,name:B.name,description:B.description||"",status:"pending",priority:B.priority||"medium",ai_notes:"",affected_files:[],reused_resources:[],git:{branch:null,pr_number:null,pr_url:null,last_commit:null,commits:[]},metrics:{lines_added:0,lines_removed:0,files_created:0,files_modified:0,complexity_score:0},technical_debt:[],started_at:null,completed_at:null});const ne=te.tasks.filter(je=>je.status==="completed").length;te.progress=Math.round(ne/te.tasks.length*100)}return Q}),E(!0),m(null)},[]),Kt=v.useCallback(O=>{t(B=>{const K=JSON.parse(JSON.stringify(B));return K.features.push({id:O.id||`feature-${Date.now()}`,name:O.name,description:O.description||"",status:"pending",progress:0,priority:O.priority||"medium",tasks:[]}),K}),E(!0),p(!1)},[]),Yt=()=>e!=null&&e.features?e.features.map(O=>{const B=O.tasks.filter(K=>{var Q;if(h!=="all"&&K.status!==h)return!1;if(f){const te=f.toLowerCase();return K.name.toLowerCase().includes(te)||((Q=K.description)==null?void 0:Q.toLowerCase().includes(te))||K.id.toLowerCase().includes(te)}return!0});return{...O,tasks:B}}).filter(O=>O.tasks.length>0||!f):[],Pr=()=>{if(!(e!=null&&e.features))return{total:0,completed:0,inProgress:0,pending:0,debts:0};let O=0,B=0,K=0,Q=0,te=0;return e.features.forEach(ne=>{ne.tasks.forEach(je=>{O++,je.status==="completed"?B++:je.status==="in_progress"?K++:Q++,je.technical_debt&&(te+=je.technical_debt.length)})}),{total:O,completed:B,inProgress:K,pending:Q,debts:te}},Pt=[{id:"setup",label:J("nav.setup"),icon:as,key:"1"},{id:"features",label:J("nav.features"),icon:Zi,key:"2"},{id:"metrics",label:G==="es"?"MÉTRICAS":"METRICS",icon:ff,key:"3"},{id:"resources",label:J("nav.resources"),icon:Pu,key:"4"},{id:"debt",label:J("nav.debt"),icon:Oe,key:"5"},{id:"info",label:J("nav.info"),icon:ss,key:"6"},{id:"settings",label:J("nav.settings"),icon:Tf,key:"7"},{id:"help",label:J("nav.help"),icon:Ef,key:"8"}];if(Df({onSearch:()=>L(!0),onSave:()=>N&&qe(),onTabChange:O=>{Pt[O]&&d(Pt[O].id)},onEscape:()=>{L(!1),_(!1),F(!1),Le(O=>({...O,show:!1}))},onHelp:()=>_(!0)}),me.authEnabled&&!me.authenticated&&!me.checking)return n.jsx(Zf,{onLogin:gr,error:Ot});if(me.checking||r)return n.jsx("div",{className:"min-h-screen flex items-center justify-center bg-black",children:n.jsxs("div",{className:"text-center",children:[n.jsxs("div",{className:"relative mb-8",children:[n.jsx("div",{className:"w-20 h-20 border-2 border-matrix/30 flex items-center justify-center",children:n.jsx(ri,{className:"w-8 h-8 text-matrix animate-pulse"})}),n.jsx("div",{className:"absolute -top-1 -left-1 w-3 h-3 border-l-2 border-t-2 border-matrix"}),n.jsx("div",{className:"absolute -top-1 -right-1 w-3 h-3 border-r-2 border-t-2 border-matrix"}),n.jsx("div",{className:"absolute -bottom-1 -left-1 w-3 h-3 border-l-2 border-b-2 border-matrix"}),n.jsx("div",{className:"absolute -bottom-1 -right-1 w-3 h-3 border-r-2 border-b-2 border-matrix"})]}),n.jsxs("p",{className:"font-mono text-matrix text-sm tracking-widest",children:[me.checking?"> VERIFYING ACCESS...":"> LOADING ROADMAP...",n.jsx("span",{className:"animate-blink",children:"_"})]})]})});if(i)return n.jsx("div",{className:"min-h-screen flex items-center justify-center bg-black p-4",children:n.jsxs("div",{className:"terminal-card p-8 max-w-md w-full",children:[n.jsxs("div",{className:"flex items-center gap-3 mb-6",children:[n.jsx("div",{className:"led led-red"}),n.jsx("span",{className:"font-mono text-alert text-sm tracking-wider",children:"ERROR"})]}),n.jsx("p",{className:"font-mono text-gray-400 text-sm mb-6",children:i}),n.jsx("button",{onClick:z,className:"btn-terminal w-full",children:"RETRY"})]})});const kt=Pr(),ie=Yt(),se=(e==null?void 0:e.project_info)||{};return n.jsxs("div",{className:"min-h-screen bg-black text-gray-100 flex",children:[n.jsx("aside",{className:`fixed left-0 top-0 h-full sidebar-terminal z-50 transition-all duration-300 ${R?"w-16":"w-64"}`,children:n.jsxs("div",{className:"flex flex-col h-full",children:[n.jsx("div",{className:"p-4 border-b border-matrix/10",children:n.jsxs("div",{className:"flex items-center gap-3",children:[n.jsx("div",{className:"w-10 h-10 border border-matrix/50 flex items-center justify-center glow-matrix",children:n.jsx(ri,{className:"w-5 h-5 text-matrix"})}),!R&&n.jsxs("div",{children:[n.jsx("h1",{className:"font-display text-matrix text-lg tracking-wider crt-glow",children:"ROADMAP"}),n.jsx("p",{className:"font-mono text-[10px] text-gray-600 tracking-widest",children:se.name||"PROJECT"})]})]})}),!R&&n.jsxs("div",{className:"p-4 border-b border-matrix/10",children:[n.jsxs("div",{className:"mb-3",children:[n.jsxs("div",{className:"flex items-center justify-between mb-2",children:[n.jsx("span",{className:"font-mono text-[10px] text-gray-500 tracking-widest",children:G==="es"?"PROGRESO":"PROGRESS"}),n.jsxs("span",{className:"font-display text-2xl text-matrix",children:[se.total_progress||0,"%"]})]}),n.jsx("div",{className:"progress-brutal",children:n.jsx("div",{className:"progress-brutal-fill",style:{width:`${se.total_progress||0}%`}})})]}),n.jsxs("div",{className:"grid grid-cols-3 gap-2 text-center",children:[n.jsxs("div",{children:[n.jsx("div",{className:"font-display text-lg text-matrix",children:kt.completed}),n.jsx("div",{className:"font-mono text-[9px] text-gray-600 tracking-wider",children:J("stats.completed")})]}),n.jsxs("div",{children:[n.jsx("div",{className:"font-display text-lg text-signal",children:kt.inProgress}),n.jsx("div",{className:"font-mono text-[9px] text-gray-600 tracking-wider",children:J("stats.inProgress")})]}),n.jsxs("div",{children:[n.jsx("div",{className:"font-display text-lg text-gray-500",children:kt.pending}),n.jsx("div",{className:"font-mono text-[9px] text-gray-600 tracking-wider",children:J("stats.pending")})]})]})]}),n.jsx("nav",{className:"flex-1 p-2 space-y-1 overflow-y-auto",children:Pt.map(O=>{const B=O.icon,K=c===O.id;return n.jsxs("button",{onClick:()=>d(O.id),className:`nav-terminal w-full flex items-center gap-3 px-4 py-3 transition-all ${K?"active":"text-gray-500 hover:text-gray-300 hover:bg-white/[0.02]"} ${R?"justify-center px-2":"pl-8"}`,children:[n.jsx(B,{className:"w-4 h-4"}),!R&&n.jsx("span",{className:"flex-1 text-left text-xs",children:O.label})]},O.id)})}),n.jsxs("div",{className:"p-3 border-t border-matrix/10 space-y-2",children:[ae&&!R&&n.jsx("div",{className:`px-3 py-2 text-xs font-mono text-center border ${ae.type==="success"?"border-matrix/30 text-matrix bg-matrix/5":"border-alert/30 text-alert bg-alert/5"}`,children:ae.text}),N&&!R&&n.jsxs("button",{onClick:qe,disabled:l,className:"btn-terminal w-full flex items-center justify-center gap-2",children:[l?n.jsx(et,{className:"w-4 h-4 animate-spin"}):n.jsx(Lu,{className:"w-4 h-4"}),J("common.save")]}),n.jsxs("button",{onClick:()=>y(!R),className:"w-full flex items-center justify-center gap-2 px-3 py-2 text-gray-600 hover:text-gray-400 transition-all font-mono text-xs",children:[n.jsx(kf,{className:"w-4 h-4"}),!R&&J("sidebar.collapse")]})]})]})}),n.jsxs("main",{className:`flex-1 transition-all duration-300 ${R?"ml-16":"ml-64"}`,children:[n.jsx("header",{className:"sticky top-0 z-40 bg-black/95 backdrop-blur-sm border-b border-white/5",children:n.jsxs("div",{className:"px-6 py-4",children:[n.jsxs("div",{className:"flex items-center justify-between mb-3",children:[n.jsxs("div",{children:[n.jsxs("div",{className:"flex items-center gap-3",children:[n.jsx("h1",{className:"font-display text-xl text-white tracking-wide",children:se.name||"UNNAMED"}),n.jsxs("span",{className:"font-mono text-[10px] px-2 py-1 border border-matrix/30 text-matrix",children:["v",se.version||"0.0.0"]})]}),n.jsx("p",{className:"font-mono text-xs text-gray-600 mt-1 max-w-xl truncate",children:se.description||"No description"})]}),n.jsxs("div",{className:"flex items-center gap-3",children:[n.jsx("div",{className:"w-8 h-8 rounded-lg shadow-lg cursor-pointer transition-transform hover:scale-110 ring-2 ring-white/10 hover:ring-white/30",style:{backgroundColor:((Xe=se.theme)==null?void 0:Xe.color)||"#00ff88",boxShadow:`0 0 20px ${((gn=se.theme)==null?void 0:gn.color)||"#00ff88"}40`},title:`Theme: ${((ot=se.theme)==null?void 0:ot.name)||"Matrix Green"}
|
|
306
|
-
Click to change`,onClick:()=>P(!0)}),n.jsx("button",{onClick:z,className:"p-2 border border-white/10 text-gray-500 hover:text-matrix hover:border-matrix/30 transition-all",children:n.jsx(pl,{className:"w-4 h-4"})}),me.authEnabled&&n.jsxs("button",{onClick:A,className:"flex items-center gap-2 px-3 py-2 border border-white/10 text-gray-500 hover:text-alert hover:border-alert/30 transition-all font-mono text-xs",children:[n.jsx(Sf,{className:"w-4 h-4"}),n.jsx("span",{className:"hidden sm:inline",children:J("auth.logout")})]})]})]}),n.jsxs("div",{className:"flex items-center gap-3",children:[n.jsx("span",{className:"font-mono text-xs text-matrix",children:">"}),n.jsx("h2",{className:"font-mono text-sm text-gray-400",children:(Lr=Pt.find(O=>O.id===c))==null?void 0:Lr.label}),n.jsxs("span",{className:"font-mono text-xs text-gray-700",children:[c==="features"&&`// ${kt.total} tasks in ${((yn=e==null?void 0:e.features)==null?void 0:yn.length)||0} features`,c==="resources"&&"// shared components & utilities",c==="debt"&&`// ${kt.debts} items registered`,c==="info"&&"// stack & conventions",c==="settings"&&"// deploy configuration",c==="help"&&"// documentation"]})]})]})}),n.jsxs("div",{className:"p-6 pb-24 grid-bg min-h-[calc(100vh-120px)]",children:[c==="features"&&n.jsx(zf,{features:ie,searchTerm:f,setSearchTerm:g,statusFilter:h,setStatusFilter:x,priorityFilter:k,setPriorityFilter:V,assigneeFilter:H,setAssigneeFilter:Z,viewMode:Ne,setViewMode:xe,onUpdateTaskStatus:Wt,onAddTask:Dt,showAddTask:b,setShowAddTask:m,setShowAddFeature:p,setShowAIGenerator:S,team:Dr,t:J,language:G,onAssignTask:(O,B,K,Q)=>{t(te=>{const ne=JSON.parse(JSON.stringify(te)),je=ne.features.find(ct=>ct.id===O);if(je){const ct=je.tasks.find(ce=>ce.id===B);ct&&(ct.assigned_to=K,ct.assigned_name=Q)}return ne}),E(!0)}}),c==="metrics"&&n.jsx(Hf,{roadmap:e,language:G}),c==="resources"&&n.jsx(Gf,{resources:se.shared_resources||{}}),c==="debt"&&n.jsx(Bf,{roadmap:e,setRoadmap:t,setHasChanges:E}),c==="info"&&n.jsx(Wf,{projectInfo:se}),c==="settings"&&n.jsx(Kf,{roadmap:e,setRoadmap:t,setHasChanges:E,authState:me,showConfirm:xn,showAlert:hn,t:J,language:G,changeLanguage:$e}),c==="help"&&n.jsx(Yf,{t:J,language:G}),c==="setup"&&n.jsx(Jf,{roadmap:e,setRoadmap:t,setHasChanges:E,loadRoadmap:z,t:J,language:G})]})]}),T&&n.jsx(Xf,{roadmap:e,setRoadmap:t,setHasChanges:E,onClose:()=>P(!1)}),u&&n.jsx(hc,{onClose:()=>p(!1),children:n.jsx(qf,{onAdd:Kt,onClose:()=>p(!1),team:Dr,t:J,language:G})}),j&&n.jsx(hc,{onClose:()=>S(!1),children:n.jsx(Uf,{roadmap:e,setRoadmap:t,setHasChanges:E,onClose:()=>S(!1)})}),ee.show&&n.jsx("div",{className:"fixed inset-0 bg-black/80 backdrop-blur-sm flex items-center justify-center z-[100] animate-fade-in",children:n.jsxs("div",{className:"bg-void-200 border border-white/10 w-full max-w-md mx-4 animate-slide-up",children:[n.jsxs("div",{className:`p-4 border-b flex items-center gap-3 ${ee.type==="success"?"border-matrix/30 bg-matrix/5":ee.type==="error"?"border-alert/30 bg-alert/5":ee.type==="warning"?"border-signal/30 bg-signal/5":"border-cyber/30 bg-cyber/5"}`,children:[n.jsxs("div",{className:`w-10 h-10 border flex items-center justify-center ${ee.type==="success"?"border-matrix/50 bg-matrix/10":ee.type==="error"?"border-alert/50 bg-alert/10":ee.type==="warning"?"border-signal/50 bg-signal/10":"border-cyber/50 bg-cyber/10"}`,children:[ee.type==="success"&&n.jsx(Ie,{className:"w-5 h-5 text-matrix"}),ee.type==="error"&&n.jsx(ft,{className:"w-5 h-5 text-alert"}),ee.type==="warning"&&n.jsx(Oe,{className:"w-5 h-5 text-signal"}),ee.type==="info"&&n.jsx(ss,{className:"w-5 h-5 text-cyber"})]}),n.jsx("h3",{className:`font-mono text-sm tracking-wider ${ee.type==="success"?"text-matrix":ee.type==="error"?"text-alert":ee.type==="warning"?"text-signal":"text-cyber"}`,children:ee.title})]}),n.jsx("div",{className:"p-5",children:n.jsx("p",{className:"font-mono text-sm text-gray-300 leading-relaxed",children:ee.message})}),n.jsxs("div",{className:"p-4 border-t border-white/5 flex gap-3 justify-end",children:[ee.cancelText&&ee.onCancel&&n.jsx("button",{onClick:ee.onCancel,className:"px-5 py-2.5 border border-white/10 text-gray-400 hover:text-white hover:border-white/30 transition-all font-mono text-xs tracking-wider",children:ee.cancelText}),n.jsx("button",{onClick:ee.onConfirm,className:`px-5 py-2.5 border font-mono text-xs tracking-wider transition-all ${ee.type==="success"?"border-matrix/50 bg-matrix/10 text-matrix hover:bg-matrix/20":ee.type==="error"?"border-alert/50 bg-alert/10 text-alert hover:bg-alert/20":ee.type==="warning"?"border-signal/50 bg-signal/10 text-signal hover:bg-signal/20":"border-cyber/50 bg-cyber/10 text-cyber hover:bg-cyber/20"}`,children:ee.confirmText})]})]})}),n.jsx(Of,{isOpen:C,onClose:()=>L(!1),roadmap:e,onNavigate:d,t:J}),D&&n.jsx("div",{className:"fixed inset-0 bg-black/80 backdrop-blur-sm flex items-center justify-center z-[150]",onClick:()=>_(!1),children:n.jsxs("div",{className:"bg-void-200 border border-white/10 w-full max-w-md mx-4 animate-slide-up",onClick:O=>O.stopPropagation(),children:[n.jsxs("div",{className:"p-4 border-b border-white/10 flex items-center justify-between",children:[n.jsxs("div",{className:"flex items-center gap-3",children:[n.jsx(pc,{className:"w-5 h-5 text-cyber"}),n.jsx("h3",{className:"font-mono text-sm text-white",children:G==="es"?"ATAJOS DE TECLADO":"KEYBOARD SHORTCUTS"})]}),n.jsx("button",{onClick:()=>_(!1),className:"text-gray-500 hover:text-white",children:n.jsx(ft,{className:"w-4 h-4"})})]}),n.jsx("div",{className:"p-4 space-y-3",children:[{keys:["Ctrl","K"],desc:G==="es"?"Búsqueda global":"Global search"},{keys:["Ctrl","S"],desc:G==="es"?"Guardar cambios":"Save changes"},{keys:["1-7"],desc:G==="es"?"Cambiar pestaña":"Switch tab"},{keys:["?"],desc:G==="es"?"Mostrar atajos":"Show shortcuts"},{keys:["Esc"],desc:G==="es"?"Cerrar modal":"Close modal"}].map((O,B)=>n.jsxs("div",{className:"flex items-center justify-between py-2 border-b border-white/5",children:[n.jsx("span",{className:"font-mono text-sm text-gray-400",children:O.desc}),n.jsx("div",{className:"flex items-center gap-1",children:O.keys.map((K,Q)=>n.jsxs(oi.Fragment,{children:[n.jsx("kbd",{className:"px-2 py-1 bg-void-100 border border-white/10 text-gray-300 font-mono text-xs",children:K}),Q<O.keys.length-1&&n.jsx("span",{className:"text-gray-600",children:"+"})]},Q))})]},B))})]})}),Y&&n.jsx("div",{className:"fixed inset-0 z-[100]",onClick:()=>F(!1),children:n.jsxs("div",{className:"absolute right-0 top-0 h-full w-80 bg-void-200 border-l border-white/10 animate-slide-left",onClick:O=>O.stopPropagation(),children:[n.jsxs("div",{className:"p-4 border-b border-white/10 flex items-center justify-between",children:[n.jsxs("div",{className:"flex items-center gap-3",children:[n.jsx(bf,{className:"w-5 h-5 text-signal"}),n.jsx("h3",{className:"font-mono text-sm text-white",children:G==="es"?"ACTIVIDAD RECIENTE":"RECENT ACTIVITY"})]}),n.jsx("button",{onClick:()=>F(!1),className:"text-gray-500 hover:text-white",children:n.jsx(ft,{className:"w-4 h-4"})})]}),n.jsx("div",{className:"p-4 overflow-y-auto h-[calc(100%-60px)]",children:n.jsx("p",{className:"font-mono text-xs text-gray-600 text-center py-8",children:G==="es"?"El registro de actividad se mostrará aquí":"Activity log will appear here"})})]})}),n.jsxs("div",{className:"fixed bottom-4 left-1/2 -translate-x-1/2 z-50 hidden md:flex items-center gap-2 px-4 py-2 bg-void-200/90 backdrop-blur-sm border border-white/10",children:[n.jsxs("button",{onClick:()=>L(!0),className:"flex items-center gap-2 px-3 py-1.5 text-gray-500 hover:text-white transition-all font-mono text-xs",children:[n.jsx(ls,{className:"w-3 h-3"}),n.jsx("span",{children:G==="es"?"Buscar":"Search"}),n.jsx("kbd",{className:"px-1.5 py-0.5 bg-void-100 border border-white/10 text-[9px] text-gray-600",children:"⌘K"})]}),n.jsx("div",{className:"w-px h-4 bg-white/10"}),n.jsxs("button",{onClick:()=>{d("features"),xe("kanban")},className:`flex items-center gap-2 px-3 py-1.5 transition-all font-mono text-xs ${Ne==="kanban"&&c==="features"?"text-matrix":"text-gray-500 hover:text-white"}`,children:[n.jsx(Ru,{className:"w-3 h-3"}),n.jsx("span",{children:"Kanban"})]}),n.jsxs("button",{onClick:()=>{d("features"),xe("list")},className:`flex items-center gap-2 px-3 py-1.5 transition-all font-mono text-xs ${Ne==="list"&&c==="features"?"text-matrix":"text-gray-500 hover:text-white"}`,children:[n.jsx(Ou,{className:"w-3 h-3"}),n.jsx("span",{children:G==="es"?"Lista":"List"})]}),n.jsx("div",{className:"w-px h-4 bg-white/10"}),n.jsx("button",{onClick:()=>_(!0),className:"flex items-center gap-2 px-3 py-1.5 text-gray-500 hover:text-white transition-all font-mono text-xs",children:n.jsx(pc,{className:"w-3 h-3"})})]})]})}function Uf({roadmap:e,setRoadmap:t,setHasChanges:r,onClose:s}){var u;const[l,a]=v.useState(""),[i,o]=v.useState(!1),[c,d]=v.useState(null),[f,g]=v.useState(null),[h,x]=v.useState({checking:!0,available:!1}),[N,E]=v.useState("input");v.useEffect(()=>{fetch("/api/claude-code-status").then(p=>p.json()).then(p=>x({checking:!1,available:p.available,version:p.version})).catch(()=>x({checking:!1,available:!1}))},[]);const b=async()=>{if(!l.trim()){g("Escribe los requisitos o funcionalidades que deseas implementar");return}o(!0),g(null),E("analyzing");try{const j=await(await fetch("/api/scan-project")).json(),S=await fetch("/api/analyze-project",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({requirements:l,projectScan:j,existingRoadmap:e,useClaudeCode:h.available})}),R=await S.json();if(!S.ok)throw new Error(R.error||"Error analyzing project");d(R),E("result")}catch(p){g(p.message),E("input")}finally{o(!1)}},m=()=>{var p;if(!((p=c==null?void 0:c.analysis)!=null&&p.features)){g("No hay features para añadir");return}t(j=>{const S=JSON.parse(JSON.stringify(j));if(c.analysis.features.forEach(P=>{const C=S.features.findIndex(L=>L.id===P.id||L.name.toLowerCase()===P.name.toLowerCase());if(C>=0){const L=S.features[C];(P.tasks||[]).forEach(Y=>{var Ne;((Ne=L.tasks)==null?void 0:Ne.some(xe=>xe.id===Y.id||xe.name.toLowerCase()===Y.name.toLowerCase()))||(L.tasks||(L.tasks=[]),L.tasks.push({...Y,id:Y.id||`task-${Date.now()}-${Math.random().toString(36).substr(2,9)}`,status:Y.status||"pending",ai_generated:!0,created_at:new Date().toISOString()}))});const _=L.tasks.filter(Y=>Y.status==="completed").length;L.progress=L.tasks.length>0?Math.round(_/L.tasks.length*100):0}else S.features.push({...P,id:P.id||`feature-${Date.now()}`,status:P.status||"pending",progress:0,ai_generated:!0,created_at:new Date().toISOString(),tasks:(P.tasks||[]).map(L=>({...L,id:L.id||`task-${Date.now()}-${Math.random().toString(36).substr(2,9)}`,status:L.status||"pending"}))})}),c.analysis.shared_resources){S.project_info.shared_resources||(S.project_info.shared_resources={ui_components:[],utilities:[],database_tables:[]});const P=c.analysis.shared_resources;P.ui_components&&P.ui_components.forEach(C=>{S.project_info.shared_resources.ui_components.some(L=>L.path===C.path)||S.project_info.shared_resources.ui_components.push(C)}),P.utilities&&P.utilities.forEach(C=>{S.project_info.shared_resources.utilities.some(L=>L.path===C.path)||S.project_info.shared_resources.utilities.push(C)}),P.database_tables&&P.database_tables.forEach(C=>{S.project_info.shared_resources.database_tables.some(L=>L.name===C.name)||S.project_info.shared_resources.database_tables.push(C)})}const y=S.features.reduce((P,C)=>{var L;return P+(((L=C.tasks)==null?void 0:L.length)||0)},0),T=S.features.reduce((P,C)=>{var L;return P+(((L=C.tasks)==null?void 0:L.filter(D=>D.status==="completed").length)||0)},0);return S.project_info.total_progress=y>0?Math.round(T/y*100):0,S}),r(!0),s()};return n.jsxs("div",{className:"w-full max-w-3xl",children:[n.jsxs("div",{className:"flex items-center gap-3 mb-6",children:[n.jsx("div",{className:"w-10 h-10 border border-cyber/30 bg-cyber/10 flex items-center justify-center",children:n.jsx(as,{className:"w-5 h-5 text-cyber"})}),n.jsxs("div",{children:[n.jsx("h2",{className:"font-display text-xl text-white tracking-wide",children:"AI FEATURE GENERATOR"}),n.jsx("p",{className:"font-mono text-[11px] text-gray-500",children:"Describe lo que necesitas y Claude generará features estructuradas"})]})]}),n.jsx("div",{className:`mb-4 p-3 border font-mono text-[11px] flex items-center gap-2 ${h.checking?"border-gray-700 text-gray-500":h.available?"border-matrix/30 text-matrix bg-matrix/5":"border-alert/30 text-alert bg-alert/5"}`,children:h.checking?n.jsxs(n.Fragment,{children:[n.jsx(et,{className:"w-4 h-4 animate-spin"}),"Verificando Claude Code CLI..."]}):h.available?n.jsxs(n.Fragment,{children:[n.jsx(Ie,{className:"w-4 h-4"}),"Claude Code CLI disponible ",h.version&&`(${h.version})`]}):n.jsxs(n.Fragment,{children:[n.jsx(Oe,{className:"w-4 h-4"}),"Claude Code CLI no disponible - Se requiere API key"]})}),f&&n.jsxs("div",{className:"mb-4 p-3 border border-alert/30 bg-alert/5 font-mono text-xs text-alert flex items-center gap-2",children:[n.jsx(Oe,{className:"w-4 h-4"}),f]}),N==="input"&&n.jsxs("div",{className:"space-y-4",children:[n.jsxs("div",{children:[n.jsx("label",{className:"font-mono text-[10px] text-gray-500 tracking-wider block mb-2",children:"DESCRIBE TUS REQUISITOS Y FUNCIONALIDADES"}),n.jsx("textarea",{value:l,onChange:p=>a(p.target.value),placeholder:`Ejemplo:
|
|
307
|
-
- Sistema de autenticación con login/registro
|
|
308
|
-
- Dashboard con estadísticas de usuarios
|
|
309
|
-
- CRUD de productos con imágenes
|
|
310
|
-
- Notificaciones por email
|
|
311
|
-
- Integración con Stripe para pagos
|
|
312
|
-
- API REST documentada con Swagger`,className:"w-full h-64 input-terminal p-4 text-sm resize-none",spellCheck:!1}),n.jsx("p",{className:"mt-2 font-mono text-[10px] text-gray-600",children:"Escribe todo lo que necesitas. Claude analizará el proyecto actual y generará features estructuradas."})]}),n.jsxs("div",{className:"flex gap-3",children:[n.jsxs("button",{onClick:b,disabled:i||!l.trim()||!h.available&&!h.checking,className:"btn-terminal flex-1 py-3 disabled:opacity-50 flex items-center justify-center gap-2",children:[n.jsx(as,{className:"w-4 h-4"}),"GENERAR CON IA"]}),n.jsx("button",{onClick:s,className:"px-6 py-3 border border-white/10 text-gray-500 hover:text-white hover:border-white/30 transition-all font-mono text-xs",children:"CANCELAR"})]})]}),N==="analyzing"&&n.jsxs("div",{className:"py-12 text-center",children:[n.jsx(et,{className:"w-12 h-12 mx-auto mb-4 animate-spin text-cyber"}),n.jsx("h3",{className:"font-mono text-sm text-white mb-2",children:"ANALIZANDO CON CLAUDE..."}),n.jsx("p",{className:"font-mono text-[11px] text-gray-500",children:"Escaneando proyecto y generando features estructuradas"}),n.jsxs("div",{className:"mt-6 space-y-2 max-w-md mx-auto",children:[n.jsxs("div",{className:"flex items-center gap-2 font-mono text-[10px] text-gray-600",children:[n.jsx(Ie,{className:"w-3 h-3 text-matrix"})," Escaneando archivos del proyecto..."]}),n.jsxs("div",{className:"flex items-center gap-2 font-mono text-[10px] text-gray-600",children:[n.jsx(et,{className:"w-3 h-3 animate-spin text-cyber"})," Analizando requisitos con Claude..."]})]})]}),N==="result"&&c&&n.jsxs("div",{className:"space-y-4",children:[n.jsxs("div",{className:"p-4 border border-matrix/30 bg-matrix/5",children:[n.jsxs("div",{className:"flex items-center gap-2 mb-3",children:[n.jsx(Ie,{className:"w-5 h-5 text-matrix"}),n.jsx("span",{className:"font-mono text-sm text-matrix",children:"ANÁLISIS COMPLETADO"})]}),((u=c.analysis)==null?void 0:u.features)&&n.jsxs("div",{className:"space-y-3",children:[n.jsxs("p",{className:"font-mono text-[11px] text-gray-400",children:["Se generaron ",c.analysis.features.length," features:"]}),c.analysis.features.map((p,j)=>{var S;return n.jsxs("div",{className:"p-3 bg-void-100 border border-white/5",children:[n.jsxs("div",{className:"flex items-center gap-2 mb-1",children:[n.jsx("span",{className:`w-2 h-2 rounded-full ${p.priority==="high"?"bg-alert":p.priority==="medium"?"bg-signal":"bg-cyber"}`}),n.jsx("span",{className:"font-sans text-sm text-white",children:p.name}),n.jsxs("span",{className:"font-mono text-[9px] text-gray-600 bg-white/5 px-1.5 py-0.5",children:[((S=p.tasks)==null?void 0:S.length)||0," tasks"]})]}),n.jsx("p",{className:"font-mono text-[10px] text-gray-500 line-clamp-2",children:p.description})]},j)})]})]}),n.jsxs("details",{className:"group",children:[n.jsx("summary",{className:"font-mono text-[10px] text-gray-600 cursor-pointer hover:text-gray-400",children:"Ver JSON completo"}),n.jsx("div",{className:"mt-2 p-3 bg-void-100 border border-white/5 max-h-48 overflow-auto",children:n.jsx("pre",{className:"font-mono text-[10px] text-gray-500 whitespace-pre-wrap",children:JSON.stringify(c.analysis,null,2)})})]}),n.jsxs("div",{className:"flex gap-3",children:[n.jsxs("button",{onClick:m,className:"btn-terminal flex-1 py-3 flex items-center justify-center gap-2",children:[n.jsx(un,{className:"w-4 h-4"}),"AÑADIR AL ROADMAP"]}),n.jsx("button",{onClick:()=>{E("input"),d(null)},className:"px-6 py-3 border border-white/10 text-gray-500 hover:text-white hover:border-white/30 transition-all font-mono text-xs",children:"REGENERAR"}),n.jsx("button",{onClick:s,className:"px-6 py-3 border border-white/10 text-gray-500 hover:text-white hover:border-white/30 transition-all font-mono text-xs",children:"CANCELAR"})]})]})]})}function Ff({kanbanColumns:e,filteredTasks:t,onUpdateTaskStatus:r,language:s}){const[l,a]=v.useState(null),[i,o]=v.useState(null),c=(x,N)=>{a(N),x.dataTransfer.effectAllowed="move",x.dataTransfer.setData("text/plain",N.id),x.target.style.opacity="0.5"},d=x=>{x.target.style.opacity="1",a(null),o(null)},f=(x,N)=>{x.preventDefault(),x.dataTransfer.dropEffect="move",o(N)},g=x=>{x.currentTarget.contains(x.relatedTarget)||o(null)},h=(x,N)=>{x.preventDefault(),o(null),l&&l.status!==N&&r(l.featureId,l.id,N),a(null)};return n.jsx("div",{className:"grid grid-cols-3 gap-4 min-h-[500px]",children:e.map(x=>{const N=t.filter(b=>b.status===x.id),E=i===x.id&&(l==null?void 0:l.status)!==x.id;return n.jsxs("div",{className:`bg-void-100 border transition-all duration-200 ${E?`border-${x.color} shadow-${x.color}`:"border-white/5"}`,onDragOver:b=>f(b,x.id),onDragLeave:g,onDrop:b=>h(b,x.id),children:[n.jsx("div",{className:`p-3 border-b border-${x.color}/20 bg-${x.color}/5`,children:n.jsxs("div",{className:"flex items-center justify-between",children:[n.jsx("span",{className:`font-mono text-xs text-${x.color} tracking-wider`,children:x.label}),n.jsx("span",{className:"font-display text-lg text-gray-500",children:N.length})]})}),n.jsxs("div",{className:`p-2 space-y-2 max-h-[500px] overflow-y-auto min-h-[100px] transition-all ${E?`bg-${x.color}/5`:""}`,children:[N.map(b=>{var m;return n.jsxs("div",{draggable:!0,onDragStart:u=>c(u,b),onDragEnd:d,className:`p-3 bg-void-200 border border-white/5 hover:border-white/20 transition-all cursor-grab active:cursor-grabbing select-none ${(l==null?void 0:l.id)===b.id?"opacity-50":""}`,children:[n.jsx("div",{className:"font-mono text-xs text-white mb-1",children:b.name}),n.jsx("div",{className:"font-mono text-[10px] text-gray-600 mb-2",children:b.featureName}),n.jsxs("div",{className:"flex items-center justify-between",children:[n.jsx("span",{className:`px-1.5 py-0.5 text-[9px] font-mono ${b.priority==="high"?"bg-alert/20 text-alert":b.priority==="medium"?"bg-signal/20 text-signal":"bg-cyber/20 text-cyber"}`,children:(m=b.priority)==null?void 0:m.toUpperCase()}),b.assigned_name&&n.jsx("span",{className:"font-mono text-[9px] text-gray-500",children:b.assigned_name})]})]},b.id)}),N.length===0&&n.jsx("div",{className:`py-8 text-center border-2 border-dashed transition-all ${E?`border-${x.color}/50`:"border-transparent"}`,children:n.jsx("p",{className:"font-mono text-[10px] text-gray-700",children:E?s==="es"?"Soltar aquí":"Drop here":s==="es"?"Sin tareas":"No tasks"})})]})]},x.id)})})}function zf({features:e,searchTerm:t,setSearchTerm:r,statusFilter:s,setStatusFilter:l,priorityFilter:a,setPriorityFilter:i,assigneeFilter:o,setAssigneeFilter:c,viewMode:d,setViewMode:f,onUpdateTaskStatus:g,onAddTask:h,showAddTask:x,setShowAddTask:N,setShowAddFeature:E,setShowAIGenerator:b,team:m,onAssignTask:u,t:p,language:j}){const[S,R]=v.useState(!1),y=v.useMemo(()=>{const C=[];return e.forEach(L=>{(L.tasks||[]).forEach(D=>{C.push({...D,featureId:L.id,featureName:L.name})})}),C},[e]),T=v.useMemo(()=>y.filter(C=>!(a!=="all"&&C.priority!==a||o!=="all"&&C.assigned_to!==o)),[y,a,o]),P=[{id:"pending",label:j==="es"?"PENDIENTE":"PENDING",color:"gray"},{id:"in_progress",label:j==="es"?"EN PROGRESO":"IN PROGRESS",color:"signal"},{id:"completed",label:j==="es"?"COMPLETADO":"COMPLETED",color:"matrix"}];return n.jsxs("div",{className:"space-y-6 animate-fade-in",children:[n.jsxs("div",{className:"flex flex-col sm:flex-row gap-3",children:[n.jsxs("div",{className:"flex-1 relative",children:[n.jsx(ls,{className:"w-4 h-4 text-gray-600 absolute left-3 top-1/2 -translate-y-1/2"}),n.jsx("input",{type:"text",placeholder:p?p("common.search"):"search tasks...",value:t,onChange:C=>r(C.target.value),className:"input-terminal w-full pl-10 pr-4 py-2.5 text-sm"})]}),n.jsxs("select",{value:s,onChange:C=>l(C.target.value),className:"input-terminal px-4 py-2.5 text-sm cursor-pointer",children:[n.jsx("option",{value:"all",children:j==="es"?"TODOS":"ALL STATUS"}),n.jsx("option",{value:"pending",children:j==="es"?"PENDIENTE":"PENDING"}),n.jsx("option",{value:"in_progress",children:j==="es"?"EN PROGRESO":"IN PROGRESS"}),n.jsx("option",{value:"completed",children:j==="es"?"COMPLETADO":"COMPLETED"})]}),n.jsxs("div",{className:"flex border border-white/10",children:[n.jsx("button",{onClick:()=>f("list"),className:`px-3 py-2 transition-all ${d==="list"?"bg-white/10 text-white":"text-gray-500 hover:text-white"}`,title:"List view",children:n.jsx(Ou,{className:"w-4 h-4"})}),n.jsx("button",{onClick:()=>f("kanban"),className:`px-3 py-2 transition-all ${d==="kanban"?"bg-white/10 text-white":"text-gray-500 hover:text-white"}`,title:"Kanban view",children:n.jsx(Ru,{className:"w-4 h-4"})})]}),n.jsxs("button",{onClick:()=>R(!S),className:`btn-terminal flex items-center gap-2 ${S?"border-cyber/50 text-cyber":""}`,children:[n.jsx(vf,{className:"w-4 h-4"}),j==="es"?"FILTROS":"FILTERS"]}),n.jsxs("button",{onClick:()=>E(!0),className:"btn-terminal flex items-center gap-2",children:[n.jsx(un,{className:"w-4 h-4"}),j==="es"?"NUEVA FEATURE":"NEW FEATURE"]}),n.jsxs("button",{onClick:()=>b(!0),className:"btn-terminal flex items-center gap-2 bg-gradient-to-r from-cyber/20 to-matrix/20 border-cyber/50 hover:border-cyber",children:[n.jsx(as,{className:"w-4 h-4 text-cyber"}),"AI"]})]}),S&&n.jsxs("div",{className:"flex gap-3 p-4 bg-void-100 border border-white/5 animate-fade-in",children:[n.jsxs("div",{children:[n.jsx("label",{className:"font-mono text-[10px] text-gray-500 block mb-1",children:j==="es"?"PRIORIDAD":"PRIORITY"}),n.jsxs("select",{value:a,onChange:C=>i(C.target.value),className:"input-terminal px-3 py-1.5 text-xs cursor-pointer",children:[n.jsx("option",{value:"all",children:j==="es"?"TODAS":"ALL"}),n.jsx("option",{value:"high",children:j==="es"?"ALTA":"HIGH"}),n.jsx("option",{value:"medium",children:j==="es"?"MEDIA":"MEDIUM"}),n.jsx("option",{value:"low",children:j==="es"?"BAJA":"LOW"})]})]}),n.jsxs("div",{children:[n.jsx("label",{className:"font-mono text-[10px] text-gray-500 block mb-1",children:j==="es"?"ASIGNADO A":"ASSIGNEE"}),n.jsxs("select",{value:o,onChange:C=>c(C.target.value),className:"input-terminal px-3 py-1.5 text-xs cursor-pointer",children:[n.jsx("option",{value:"all",children:j==="es"?"TODOS":"ALL"}),n.jsx("option",{value:"",children:j==="es"?"SIN ASIGNAR":"UNASSIGNED"}),m.map(C=>n.jsx("option",{value:C.id,children:C.name},C.id))]})]}),n.jsx("button",{onClick:()=>{i("all"),c("all")},className:"self-end px-3 py-1.5 text-xs text-gray-500 hover:text-white transition-all",children:j==="es"?"LIMPIAR":"CLEAR"})]}),d==="list"&&n.jsx("div",{className:"space-y-4 stagger",children:e.map(C=>n.jsx($f,{feature:C,onUpdateTaskStatus:g,onAddTask:h,showAddTask:x,setShowAddTask:N,team:m,onAssignTask:u,language:j,t:p},C.id))}),d==="kanban"&&n.jsx(Ff,{kanbanColumns:P,filteredTasks:T,onUpdateTaskStatus:g,language:j}),e.length===0&&d==="list"&&n.jsxs("div",{className:"terminal-card p-12 text-center",children:[n.jsx(ls,{className:"w-10 h-10 mx-auto mb-4 text-gray-700"}),n.jsx("p",{className:"font-mono text-gray-600 text-sm",children:j==="es"?"NO HAY TAREAS":"NO TASKS FOUND"})]})]})}function $f({feature:e,onUpdateTaskStatus:t,onAddTask:r,showAddTask:s,setShowAddTask:l,team:a,onAssignTask:i,language:o,t:c}){const[d,f]=v.useState(!0),g={high:{color:"text-alert",border:"border-alert/30",bg:"bg-alert/5"},medium:{color:"text-signal",border:"border-signal/30",bg:"bg-signal/5"},low:{color:"text-cyber",border:"border-cyber/30",bg:"bg-cyber/5"}},h=g[e.priority]||g.medium;return n.jsxs("div",{className:"feature-card",children:[n.jsxs("button",{onClick:()=>f(!d),className:"w-full px-5 py-4 flex items-center gap-4 hover:bg-white/[0.01] transition-colors",children:[n.jsxs("div",{className:"relative w-14 h-14 flex-shrink-0",children:[n.jsxs("svg",{className:"w-full h-full -rotate-90",viewBox:"0 0 36 36",children:[n.jsx("circle",{cx:"18",cy:"18",r:"15",fill:"none",stroke:"#1a1a1a",strokeWidth:"3"}),n.jsx("circle",{cx:"18",cy:"18",r:"15",fill:"none",stroke:"url(#progressGradient)",strokeWidth:"3",strokeLinecap:"round",strokeDasharray:`${e.progress||0}, 100`,className:"transition-all duration-700"}),n.jsx("defs",{children:n.jsxs("linearGradient",{id:"progressGradient",x1:"0%",y1:"0%",x2:"100%",y2:"0%",children:[n.jsx("stop",{offset:"0%",stopColor:"#00ff88"}),n.jsx("stop",{offset:"100%",stopColor:"#00d4ff"})]})})]}),n.jsx("div",{className:"absolute inset-0 flex items-center justify-center",children:n.jsxs("span",{className:"font-display text-sm text-matrix",children:[e.progress||0,"%"]})})]}),n.jsxs("div",{className:"flex-1 text-left",children:[n.jsxs("div",{className:"flex items-center gap-3 mb-1",children:[n.jsx("h3",{className:"font-sans font-semibold text-white",children:e.name}),n.jsx("span",{className:`status-badge ${h.color} ${h.border} ${h.bg}`,children:e.priority||"medium"})]}),n.jsx("p",{className:"font-mono text-xs text-gray-600 line-clamp-1",children:e.description})]}),n.jsx(xf,{className:`w-5 h-5 text-gray-600 transition-transform ${d?"rotate-90":""}`})]}),d&&n.jsxs("div",{className:"px-5 pb-5 border-t border-white/5",children:[n.jsxs("div",{className:"py-4",children:[n.jsxs("div",{className:"flex justify-between font-mono text-[10px] text-gray-600 mb-2",children:[n.jsxs("span",{children:[e.tasks.filter(x=>x.status==="completed").length," / ",e.tasks.length," TASKS"]}),n.jsxs("span",{children:[e.progress,"%"]})]}),n.jsx("div",{className:"progress-brutal",children:n.jsx("div",{className:"progress-brutal-fill",style:{width:`${e.progress}%`}})})]}),n.jsx(Vf,{tasks:e.tasks,featureId:e.id,onUpdateStatus:t,team:a,onAssignTask:i}),s===e.id?n.jsx(Qf,{onAdd:x=>r(e.id,x),onCancel:()=>l(null),team:a,t:c,language:o}):n.jsxs("button",{onClick:()=>l(e.id),className:"mt-4 w-full py-3 border border-dashed border-matrix/30 text-matrix font-mono text-xs tracking-wider hover:bg-matrix/5 hover:border-matrix/50 transition-all flex items-center justify-center gap-2",children:[n.jsx(un,{className:"w-4 h-4"}),c?c("features.addTask"):"ADD TASK"]})]})]})}function Vf({tasks:e=[],featureId:t="",onUpdateStatus:r,team:s=[],onAssignTask:l}){const[a,i]=v.useState(null),[o,c]=v.useState(null),d=(x,N)=>{navigator.clipboard.writeText(x),c(N),setTimeout(()=>c(null),2e3)},f={completed:{led:"led-green",label:"DONE",color:"text-matrix"},in_progress:{led:"led-amber",label:"ACTIVE",color:"text-signal"},pending:{led:"led-gray",label:"QUEUE",color:"text-gray-500"}},g={high:{label:"HIGH",color:"text-alert"},medium:{label:"MED",color:"text-signal"},low:{label:"LOW",color:"text-cyber"}},h=x=>{const N=["pending","in_progress","completed"];return N[(N.indexOf(x)+1)%N.length]};return e!=null&&e.length?n.jsx("div",{className:"space-y-2",children:e.map(x=>{var u,p,j,S,R,y,T,P,C,L;const N=f[x.status]||f.pending,E=g[x.priority]||g.medium,b=a===x.id,m=s.find(D=>D.id===x.assigned_to);return n.jsxs("div",{className:"task-row",children:[n.jsxs("div",{className:"flex items-center gap-3 p-3",children:[n.jsx("button",{onClick:D=>{D.stopPropagation(),r==null||r(t,x.id,h(x.status))},className:"flex-shrink-0 p-2 hover:bg-white/5 transition-all",title:`Click to change status (Current: ${N.label})`,children:n.jsx("div",{className:`led ${N.led}`})}),n.jsxs("div",{className:"flex-1 min-w-0",children:[n.jsxs("div",{className:"flex items-center gap-2 flex-wrap",children:[n.jsx("h4",{className:`font-sans text-sm ${x.status==="completed"?"text-gray-600 line-through":"text-gray-200"}`,children:x.name}),n.jsxs("span",{className:`font-mono text-[9px] ${E.color}`,children:["[",E.label,"]"]}),(m||x.assigned_name)&&n.jsxs("span",{className:"font-mono text-[9px] px-2 py-0.5 bg-signal/10 border border-signal/30 text-signal",children:["@",(m==null?void 0:m.name)||x.assigned_name]}),x.completed_by&&n.jsxs("span",{className:"font-mono text-[9px] px-2 py-0.5 bg-matrix/10 border border-matrix/30 text-matrix",children:["✓ ",x.completed_by]})]}),n.jsx("p",{className:"font-mono text-[11px] text-gray-600 line-clamp-1 mt-0.5",children:x.description})]}),n.jsxs("div",{className:"hidden sm:flex items-center gap-3 font-mono text-[10px] text-gray-600",children:[((u=x.metrics)==null?void 0:u.lines_added)>0&&n.jsxs("span",{children:[n.jsxs("span",{className:"text-matrix",children:["+",x.metrics.lines_added]}),n.jsx("span",{className:"text-gray-700",children:"/"}),n.jsxs("span",{className:"text-alert",children:["-",x.metrics.lines_removed]})]}),((p=x.technical_debt)==null?void 0:p.length)>0&&n.jsxs("span",{className:"flex items-center gap-1 text-signal",children:[n.jsx(Oe,{className:"w-3 h-3"}),x.technical_debt.length]})]}),n.jsx("button",{onClick:()=>i(b?null:x.id),className:"p-2 hover:bg-white/5 transition-all",children:n.jsx(ns,{className:`w-4 h-4 text-gray-600 transition-transform ${b?"rotate-180":""}`})})]}),b&&n.jsxs("div",{className:"px-4 pb-4 pt-2 border-t border-white/5 space-y-4 animate-fade-in",children:[n.jsx("p",{className:"font-mono text-xs text-gray-400",children:x.description}),((j=x.metrics)==null?void 0:j.lines_added)>0&&n.jsxs("div",{className:"grid grid-cols-2 sm:grid-cols-4 gap-2",children:[n.jsx(Ts,{label:"LINES",value:n.jsxs(n.Fragment,{children:[n.jsxs("span",{className:"text-matrix",children:["+",x.metrics.lines_added]}),"/",n.jsxs("span",{className:"text-alert",children:["-",x.metrics.lines_removed]})]})}),n.jsx(Ts,{label:"FILES",value:x.metrics.files_created+x.metrics.files_modified,color:"text-cyber"}),n.jsx(Ts,{label:"COMPLEXITY",value:`${x.metrics.complexity_score}/10`,color:"text-signal"}),n.jsx(Ts,{label:"COMMITS",value:((R=(S=x.git)==null?void 0:S.commits)==null?void 0:R.length)||0,color:"text-matrix"})]}),((y=x.affected_files)==null?void 0:y.length)>0&&n.jsxs("div",{children:[n.jsx("h5",{className:"font-mono text-[10px] text-gray-600 tracking-wider mb-2",children:"# AFFECTED FILES"}),n.jsx("div",{className:"flex flex-wrap gap-2",children:x.affected_files.map((D,_)=>n.jsxs("button",{onClick:()=>d(D,`file-${x.id}-${_}`),className:"group flex items-center gap-2 font-mono text-[11px] bg-void-100 px-3 py-1.5 border border-white/10 hover:border-matrix/30 transition-all",children:[n.jsx("code",{className:"text-cyber",children:D}),o===`file-${x.id}-${_}`?n.jsx(dr,{className:"w-3 h-3 text-matrix"}):n.jsx(dn,{className:"w-3 h-3 text-gray-600 group-hover:text-matrix"})]},_))})]}),((T=x.reused_resources)==null?void 0:T.length)>0&&n.jsxs("div",{children:[n.jsx("h5",{className:"font-mono text-[10px] text-gray-600 tracking-wider mb-2",children:"# REUSED RESOURCES"}),n.jsx("div",{className:"flex flex-wrap gap-2",children:x.reused_resources.map((D,_)=>n.jsx("span",{className:"font-mono text-[11px] px-3 py-1.5 border border-cyber/30 text-cyber bg-cyber/5",children:D},_))})]}),((P=x.ai_notes)==null?void 0:P.trim())&&n.jsxs("div",{className:"border border-matrix/20 bg-matrix/5 p-4",children:[n.jsxs("h5",{className:"font-mono text-[10px] text-matrix tracking-wider mb-2 flex items-center gap-2",children:[n.jsx(ml,{className:"w-3 h-3"})," AI NOTES"]}),n.jsx("p",{className:"font-mono text-xs text-gray-400",children:x.ai_notes})]}),((C=x.technical_debt)==null?void 0:C.length)>0&&n.jsxs("div",{className:"border border-signal/20 bg-signal/5 p-4",children:[n.jsxs("h5",{className:"font-mono text-[10px] text-signal tracking-wider mb-3 flex items-center gap-2",children:[n.jsx(Oe,{className:"w-3 h-3"})," TECHNICAL DEBT (",x.technical_debt.length,")"]}),n.jsx("div",{className:"space-y-2",children:x.technical_debt.map((D,_)=>{var Y;return n.jsxs("div",{className:"flex items-start gap-3",children:[n.jsx("span",{className:`font-mono text-[9px] px-2 py-0.5 tracking-wider ${D.severity==="high"?"bg-alert text-black":D.severity==="medium"?"bg-signal text-black":"bg-cyber text-black"}`,children:(Y=D.severity)==null?void 0:Y.toUpperCase()}),n.jsxs("div",{children:[n.jsx("p",{className:"font-mono text-xs text-gray-400",children:D.description}),n.jsx("p",{className:"font-mono text-[10px] text-gray-600 mt-1",children:D.estimated_effort})]})]},_)})})]}),((L=x.git)==null?void 0:L.last_commit)&&n.jsxs("div",{className:"flex items-center gap-4 pt-3 border-t border-white/5",children:[n.jsxs("div",{className:"flex items-center gap-2 font-mono text-[10px] text-gray-600",children:[n.jsx(Iu,{className:"w-3 h-3"}),n.jsx("code",{className:"text-matrix",children:x.git.last_commit.substring(0,7)})]}),x.git.pr_url&&n.jsxs("a",{href:x.git.pr_url,target:"_blank",rel:"noopener noreferrer",className:"font-mono text-[10px] text-cyber hover:text-cyber-bright",children:["PR #",x.git.pr_number," →"]})]}),s.length>0&&n.jsxs("div",{className:"flex items-center gap-2 pt-3 border-t border-white/5",children:[n.jsx("span",{className:"font-mono text-[10px] text-gray-600",children:"ASSIGN:"}),n.jsxs("select",{value:x.assigned_to||"",onChange:D=>{const _=s.find(Y=>Y.id===D.target.value);l==null||l(t,x.id,D.target.value,(_==null?void 0:_.name)||"")},className:"input-terminal px-3 py-1.5 text-[11px]",children:[n.jsx("option",{value:"",children:"Sin asignar"}),s.map(D=>n.jsxs("option",{value:D.id,children:[D.name," (",D.role,")"]},D.id))]}),x.assigned_name&&n.jsxs("span",{className:"font-mono text-[10px] text-signal",children:["→ ",x.assigned_name]})]}),n.jsxs("div",{className:"flex items-center gap-2 pt-3 border-t border-white/5",children:[n.jsx("span",{className:"font-mono text-[10px] text-gray-600",children:"STATUS:"}),n.jsx("div",{className:"flex gap-1",children:["pending","in_progress","completed"].map(D=>{const _=f[D],Y=x.status===D;return n.jsxs("button",{onClick:()=>r==null?void 0:r(t,x.id,D),className:`flex items-center gap-1.5 px-3 py-1.5 font-mono text-[10px] border transition-all ${Y?`${_.color} border-current bg-current/10`:"border-white/10 text-gray-600 hover:border-white/20"}`,children:[n.jsx("div",{className:`led ${_.led}`,style:{width:"6px",height:"6px"}}),_.label]},D)})})]})]})]},x.id)})}):n.jsxs("div",{className:"py-8 text-center",children:[n.jsx(Za,{className:"w-8 h-8 mx-auto mb-3 text-gray-800"}),n.jsx("p",{className:"font-mono text-xs text-gray-700",children:"NO TASKS DEFINED"})]})}function Ts({label:e,value:t,color:r="text-white"}){return n.jsxs("div",{className:"bg-void-100 border border-white/5 p-3",children:[n.jsx("div",{className:"font-mono text-[9px] text-gray-600 tracking-wider mb-1",children:e}),n.jsx("div",{className:`metric-display text-lg ${r}`,children:t})]})}function Hf({roadmap:e,language:t}){const r=v.useMemo(()=>{if(!(e!=null&&e.features))return{total:0,completed:0,inProgress:0,pending:0,byPriority:{},byFeature:[]};let l=0,a=0,i=0,o=0;const c={high:0,medium:0,low:0},d=[];return e.features.forEach(f=>{let g=0,h=0;(f.tasks||[]).forEach(x=>{l++,h++,x.status==="completed"?(a++,g++):x.status==="in_progress"?i++:o++,x.priority&&(c[x.priority]=(c[x.priority]||0)+1)}),d.push({name:f.name,completed:g,total:h,progress:h>0?Math.round(g/h*100):0})}),{total:l,completed:a,inProgress:i,pending:o,byPriority:c,byFeature:d}},[e]),s=r.total>0?Math.round(r.completed/r.total*100):0;return n.jsxs("div",{className:"space-y-6 animate-fade-in",children:[n.jsxs("div",{className:"grid grid-cols-2 md:grid-cols-4 gap-4",children:[n.jsxs("div",{className:"terminal-card p-5",children:[n.jsx("div",{className:"font-mono text-[10px] text-gray-500 mb-2",children:t==="es"?"TOTAL TAREAS":"TOTAL TASKS"}),n.jsx("div",{className:"font-display text-3xl text-white",children:r.total})]}),n.jsxs("div",{className:"terminal-card p-5 border-matrix/20",children:[n.jsx("div",{className:"font-mono text-[10px] text-gray-500 mb-2",children:t==="es"?"COMPLETADAS":"COMPLETED"}),n.jsx("div",{className:"font-display text-3xl text-matrix",children:r.completed}),n.jsxs("div",{className:"font-mono text-[10px] text-matrix/60 mt-1",children:[s,"%"]})]}),n.jsxs("div",{className:"terminal-card p-5 border-signal/20",children:[n.jsx("div",{className:"font-mono text-[10px] text-gray-500 mb-2",children:t==="es"?"EN PROGRESO":"IN PROGRESS"}),n.jsx("div",{className:"font-display text-3xl text-signal",children:r.inProgress})]}),n.jsxs("div",{className:"terminal-card p-5",children:[n.jsx("div",{className:"font-mono text-[10px] text-gray-500 mb-2",children:t==="es"?"PENDIENTES":"PENDING"}),n.jsx("div",{className:"font-display text-3xl text-gray-500",children:r.pending})]})]}),n.jsxs("div",{className:"terminal-card p-5",children:[n.jsx("h3",{className:"font-mono text-sm text-white mb-4",children:t==="es"?"PROGRESO GENERAL":"OVERALL PROGRESS"}),n.jsxs("div",{className:"relative h-8 bg-void-100 border border-white/5 overflow-hidden",children:[n.jsx("div",{className:"absolute left-0 top-0 h-full bg-matrix/30 transition-all duration-500",style:{width:`${s}%`}}),n.jsx("div",{className:"absolute left-0 top-0 h-full bg-matrix transition-all duration-500 flex items-center justify-end pr-2",style:{width:`${s}%`},children:n.jsxs("span",{className:"font-mono text-xs text-black font-bold",children:[s,"%"]})})]}),n.jsxs("div",{className:"flex justify-between mt-2 font-mono text-[10px] text-gray-600",children:[n.jsxs("span",{children:[r.completed," / ",r.total," ",t==="es"?"tareas":"tasks"]}),n.jsx("span",{children:t==="es"?"Meta: 100%":"Goal: 100%"})]})]}),n.jsxs("div",{className:"terminal-card p-5",children:[n.jsx("h3",{className:"font-mono text-sm text-white mb-4",children:t==="es"?"POR PRIORIDAD":"BY PRIORITY"}),n.jsxs("div",{className:"grid grid-cols-3 gap-4",children:[n.jsxs("div",{className:"p-4 bg-alert/5 border border-alert/20",children:[n.jsxs("div",{className:"flex items-center gap-2 mb-2",children:[n.jsx("div",{className:"w-3 h-3 bg-alert"}),n.jsx("span",{className:"font-mono text-xs text-alert",children:t==="es"?"ALTA":"HIGH"})]}),n.jsx("div",{className:"font-display text-2xl text-alert",children:r.byPriority.high||0})]}),n.jsxs("div",{className:"p-4 bg-signal/5 border border-signal/20",children:[n.jsxs("div",{className:"flex items-center gap-2 mb-2",children:[n.jsx("div",{className:"w-3 h-3 bg-signal"}),n.jsx("span",{className:"font-mono text-xs text-signal",children:t==="es"?"MEDIA":"MEDIUM"})]}),n.jsx("div",{className:"font-display text-2xl text-signal",children:r.byPriority.medium||0})]}),n.jsxs("div",{className:"p-4 bg-cyber/5 border border-cyber/20",children:[n.jsxs("div",{className:"flex items-center gap-2 mb-2",children:[n.jsx("div",{className:"w-3 h-3 bg-cyber"}),n.jsx("span",{className:"font-mono text-xs text-cyber",children:t==="es"?"BAJA":"LOW"})]}),n.jsx("div",{className:"font-display text-2xl text-cyber",children:r.byPriority.low||0})]})]})]}),n.jsxs("div",{className:"terminal-card p-5",children:[n.jsx("h3",{className:"font-mono text-sm text-white mb-4",children:t==="es"?"POR FEATURE":"BY FEATURE"}),n.jsx("div",{className:"space-y-3",children:r.byFeature.map((l,a)=>n.jsxs("div",{className:"p-3 bg-void-100 border border-white/5",children:[n.jsxs("div",{className:"flex items-center justify-between mb-2",children:[n.jsx("span",{className:"font-mono text-xs text-white",children:l.name}),n.jsxs("span",{className:"font-mono text-xs text-gray-500",children:[l.completed,"/",l.total]})]}),n.jsx("div",{className:"h-2 bg-void-200 overflow-hidden",children:n.jsx("div",{className:`h-full transition-all duration-500 ${l.progress===100?"bg-matrix":l.progress>50?"bg-signal":"bg-gray-600"}`,style:{width:`${l.progress}%`}})}),n.jsxs("div",{className:"mt-1 font-mono text-[10px] text-gray-600 text-right",children:[l.progress,"%"]})]},a))})]}),n.jsxs("div",{className:"terminal-card p-5",children:[n.jsx("h3",{className:"font-mono text-sm text-white mb-4",children:t==="es"?"EXPORTAR DATOS":"EXPORT DATA"}),n.jsxs("div",{className:"flex gap-3",children:[n.jsxs("button",{onClick:()=>{const l=[["Feature","Task","Status","Priority","Assignee"].join(","),...e.features.flatMap(c=>(c.tasks||[]).map(d=>[c.name,d.name,d.status,d.priority||"medium",d.assigned_name||""].join(",")))].join(`
|
|
313
|
-
`),a=new Blob([l],{type:"text/csv"}),i=URL.createObjectURL(a),o=document.createElement("a");o.href=i,o.download="roadmap-export.csv",o.click()},className:"btn-terminal flex items-center gap-2",children:[n.jsx(mc,{className:"w-4 h-4"}),"CSV"]}),n.jsxs("button",{onClick:()=>{const l=new Blob([JSON.stringify(e,null,2)],{type:"application/json"}),a=URL.createObjectURL(l),i=document.createElement("a");i.href=a,i.download="roadmap-backup.json",i.click()},className:"btn-terminal flex items-center gap-2",children:[n.jsx(mc,{className:"w-4 h-4"}),"JSON"]})]})]})]})}function Gf({resources:e}){const{ui_components:t=[],utilities:r=[],database_tables:s=[]}=e,[l,a]=v.useState(null),i=(o,c)=>{navigator.clipboard.writeText(o),a(c),setTimeout(()=>a(null),2e3)};return n.jsxs("div",{className:"space-y-6 animate-fade-in",children:[n.jsxs("div",{className:"grid grid-cols-3 gap-4",children:[n.jsxs("div",{className:"terminal-card p-5",children:[n.jsxs("div",{className:"flex items-center gap-3 mb-3",children:[n.jsx("div",{className:"led led-green"}),n.jsx("span",{className:"font-mono text-[10px] text-gray-500 tracking-wider",children:"UI COMPONENTS"})]}),n.jsx("div",{className:"metric-display text-3xl text-matrix",children:t.length})]}),n.jsxs("div",{className:"terminal-card p-5",children:[n.jsxs("div",{className:"flex items-center gap-3 mb-3",children:[n.jsx("div",{className:"led led-amber"}),n.jsx("span",{className:"font-mono text-[10px] text-gray-500 tracking-wider",children:"UTILITIES"})]}),n.jsx("div",{className:"metric-display text-3xl text-signal",children:r.length})]}),n.jsxs("div",{className:"terminal-card p-5",children:[n.jsxs("div",{className:"flex items-center gap-3 mb-3",children:[n.jsx("div",{className:"led led-green"}),n.jsx("span",{className:"font-mono text-[10px] text-gray-500 tracking-wider",children:"DB TABLES"})]}),n.jsx("div",{className:"metric-display text-3xl text-cyber",children:s.length})]})]}),t.length>0&&n.jsxs("div",{className:"terminal-card p-5",children:[n.jsx("h3",{className:"font-mono text-sm text-matrix tracking-wider mb-4",children:"# UI_COMPONENTS"}),n.jsx("div",{className:"space-y-3",children:t.map((o,c)=>n.jsxs("div",{className:"bg-void-100 border border-white/5 p-4",children:[n.jsxs("div",{className:"flex items-center justify-between mb-2",children:[n.jsx("code",{className:"font-mono text-sm text-cyber",children:o.path}),n.jsx("button",{onClick:()=>i(o.usage,`comp-${c}`),className:"p-1.5 hover:bg-white/5 transition-all",children:l===`comp-${c}`?n.jsx(dr,{className:"w-3 h-3 text-matrix"}):n.jsx(dn,{className:"w-3 h-3 text-gray-600"})})]}),n.jsx("p",{className:"font-mono text-xs text-gray-500 mb-2",children:o.description}),n.jsx("code",{className:"font-mono text-[11px] text-signal block bg-black/50 p-2 border border-white/5",children:o.usage})]},c))})]}),r.length>0&&n.jsxs("div",{className:"terminal-card p-5",children:[n.jsx("h3",{className:"font-mono text-sm text-signal tracking-wider mb-4",children:"# UTILITIES"}),n.jsx("div",{className:"space-y-3",children:r.map((o,c)=>n.jsxs("div",{className:"bg-void-100 border border-white/5 p-4",children:[n.jsxs("div",{className:"flex items-center justify-between mb-2",children:[n.jsx("code",{className:"font-mono text-sm text-cyber",children:o.path}),n.jsx("button",{onClick:()=>i(o.usage,`util-${c}`),className:"p-1.5 hover:bg-white/5 transition-all",children:l===`util-${c}`?n.jsx(dr,{className:"w-3 h-3 text-matrix"}):n.jsx(dn,{className:"w-3 h-3 text-gray-600"})})]}),n.jsx("p",{className:"font-mono text-xs text-gray-500 mb-2",children:o.description}),o.exports&&n.jsx("div",{className:"flex flex-wrap gap-1 mb-2",children:o.exports.map((d,f)=>n.jsx("span",{className:"font-mono text-[10px] px-2 py-0.5 bg-matrix/10 text-matrix border border-matrix/20",children:d},f))}),n.jsx("code",{className:"font-mono text-[11px] text-signal block bg-black/50 p-2 border border-white/5",children:o.usage}),o.warning&&n.jsxs("div",{className:"flex items-center gap-2 mt-2 text-alert font-mono text-[10px]",children:[n.jsx(Oe,{className:"w-3 h-3"}),o.warning]})]},c))})]}),s.length>0&&n.jsxs("div",{className:"terminal-card p-5",children:[n.jsx("h3",{className:"font-mono text-sm text-cyber tracking-wider mb-4",children:"# DATABASE_TABLES"}),n.jsx("div",{className:"space-y-3",children:s.map((o,c)=>{var d;return n.jsxs("div",{className:"bg-void-100 border border-white/5 p-4",children:[n.jsx("code",{className:"font-mono text-sm text-matrix",children:o.name}),n.jsx("p",{className:"font-mono text-xs text-gray-500 mt-2 mb-3",children:o.description}),n.jsx("div",{className:"flex flex-wrap gap-1",children:(d=o.fields)==null?void 0:d.map((f,g)=>n.jsx("span",{className:"font-mono text-[10px] px-2 py-0.5 bg-cyber/10 text-cyber border border-cyber/20",children:f},g))})]},c)})})]})]})}function Bf({roadmap:e,setRoadmap:t,setHasChanges:r}){var R;const[s,l]=v.useState(null),[a,i]=v.useState("all"),[o,c]=v.useState("all"),[d,f]=v.useState(!1),[g,h]=v.useState(null),x=((e==null?void 0:e.features)||[]).map(y=>({id:y.id,name:y.name,tasks:y.tasks||[]})),N=[];(R=e==null?void 0:e.features)==null||R.forEach(y=>{var T;(T=y.tasks)==null||T.forEach(P=>{var C;(C=P.technical_debt)==null||C.forEach((L,D)=>{N.push({...L,id:`${y.id}-${P.id}-${D}`,debtIndex:D,featureId:y.id,featureName:y.name,taskId:P.id,taskName:P.name})})})});const E={high:N.filter(y=>y.severity==="high"),medium:N.filter(y=>y.severity==="medium"),low:N.filter(y=>y.severity==="low")},b=N.filter(y=>!(a!=="all"&&y.severity!==a||o!=="all"&&(y.status||"pending")!==o)),m={pending:{led:"led-gray",label:"PENDING",color:"text-gray-500"},in_progress:{led:"led-amber",label:"IN PROGRESS",color:"text-signal"},resolved:{led:"led-green",label:"RESOLVED",color:"text-matrix"}},u=(y,T,P,C)=>{t(L=>{var Y;const D=JSON.parse(JSON.stringify(L)),_=D.features.find(F=>F.id===y);if(_){const F=_.tasks.find(Ne=>Ne.id===T);F&&((Y=F.technical_debt)!=null&&Y[P])&&(F.technical_debt[P].status=C,C==="resolved"&&(F.technical_debt[P].resolved_at=new Date().toISOString()))}return D}),r(!0)},p=(y,T,P)=>{t(C=>{const L=JSON.parse(JSON.stringify(C)),D=L.features.find(_=>_.id===y);if(D){const _=D.tasks.find(Y=>Y.id===T);_&&(_.technical_debt||(_.technical_debt=[]),_.technical_debt.push({...P,created_at:new Date().toISOString(),status:"pending"}))}return L}),r(!0),f(!1)},j=(y,T,P,C)=>{t(L=>{var Y;const D=JSON.parse(JSON.stringify(L)),_=D.features.find(F=>F.id===y);if(_){const F=_.tasks.find(Ne=>Ne.id===T);F&&((Y=F.technical_debt)!=null&&Y[P])&&(F.technical_debt[P]={...F.technical_debt[P],...C})}return D}),r(!0),h(null)},S=(y,T,P)=>{confirm("¿Eliminar esta deuda técnica?")&&(t(C=>{const L=JSON.parse(JSON.stringify(C)),D=L.features.find(_=>_.id===y);if(D){const _=D.tasks.find(Y=>Y.id===T);_&&_.technical_debt&&_.technical_debt.splice(P,1)}return L}),r(!0),l(null))};return n.jsxs("div",{className:"space-y-6 animate-fade-in",children:[n.jsxs("div",{className:"grid grid-cols-3 gap-4",children:[n.jsxs("button",{onClick:()=>i(a==="high"?"all":"high"),className:`terminal-card p-5 transition-all ${a==="high"?"border-alert glow-alert":"border-alert/30 hover:border-alert/50"}`,children:[n.jsxs("div",{className:"flex items-center gap-3 mb-3",children:[n.jsx("div",{className:"led led-red"}),n.jsx("span",{className:"font-mono text-[10px] text-gray-500 tracking-wider",children:"HIGH"})]}),n.jsx("div",{className:"metric-display text-3xl text-alert",children:E.high.length})]}),n.jsxs("button",{onClick:()=>i(a==="medium"?"all":"medium"),className:`terminal-card p-5 transition-all ${a==="medium"?"border-signal glow-signal":"border-signal/30 hover:border-signal/50"}`,children:[n.jsxs("div",{className:"flex items-center gap-3 mb-3",children:[n.jsx("div",{className:"led led-amber"}),n.jsx("span",{className:"font-mono text-[10px] text-gray-500 tracking-wider",children:"MEDIUM"})]}),n.jsx("div",{className:"metric-display text-3xl text-signal",children:E.medium.length})]}),n.jsxs("button",{onClick:()=>i(a==="low"?"all":"low"),className:`terminal-card p-5 transition-all ${a==="low"?"border-cyber glow-cyber":"border-cyber/30 hover:border-cyber/50"}`,children:[n.jsxs("div",{className:"flex items-center gap-3 mb-3",children:[n.jsx("div",{className:"led led-green"}),n.jsx("span",{className:"font-mono text-[10px] text-gray-500 tracking-wider",children:"LOW"})]}),n.jsx("div",{className:"metric-display text-3xl text-cyber",children:E.low.length})]})]}),n.jsxs("div",{className:"flex items-center gap-3 flex-wrap",children:[n.jsx("span",{className:"font-mono text-[10px] text-gray-600",children:"FILTER:"}),n.jsxs("select",{value:o,onChange:y=>c(y.target.value),className:"input-terminal px-3 py-2 text-xs",children:[n.jsx("option",{value:"all",children:"ALL STATUS"}),n.jsx("option",{value:"pending",children:"PENDING"}),n.jsx("option",{value:"in_progress",children:"IN PROGRESS"}),n.jsx("option",{value:"resolved",children:"RESOLVED"})]}),(a!=="all"||o!=="all")&&n.jsx("button",{onClick:()=>{i("all"),c("all")},className:"font-mono text-[10px] text-gray-500 hover:text-white transition-all",children:"CLEAR"}),n.jsxs("span",{className:"font-mono text-[10px] text-gray-600",children:[b.length," / ",N.length," items"]}),n.jsxs("button",{onClick:()=>f(!0),className:"ml-auto btn-terminal flex items-center gap-2",children:[n.jsx(un,{className:"w-4 h-4"}),"ADD DEBT"]})]}),d&&n.jsx(xc,{features:x,team:teamMembers,onSave:p,onCancel:()=>f(!1)}),b.length>0?n.jsxs("div",{className:"terminal-card p-5",children:[n.jsx("h3",{className:"font-mono text-sm text-signal tracking-wider mb-4",children:"# TECHNICAL_DEBT"}),n.jsx("div",{className:"space-y-2",children:b.map(y=>{var L;const T=s===y.id,P=g===y.id,C=m[y.status||"pending"];return n.jsxs("div",{className:`bg-void-100 border transition-all ${y.status==="resolved"?"border-matrix/20 opacity-60":y.severity==="high"?"border-alert/30":y.severity==="medium"?"border-signal/30":"border-cyber/30"}`,children:[n.jsxs("button",{onClick:()=>l(T?null:y.id),className:"w-full p-4 flex items-start gap-3 text-left hover:bg-white/[0.02] transition-all",children:[n.jsx("span",{className:`font-mono text-[9px] px-2 py-0.5 tracking-wider flex-shrink-0 ${y.severity==="high"?"bg-alert text-black":y.severity==="medium"?"bg-signal text-black":"bg-cyber text-black"}`,children:(L=y.severity)==null?void 0:L.toUpperCase()}),n.jsxs("div",{className:"flex-1 min-w-0",children:[n.jsx("p",{className:`font-mono text-xs line-clamp-1 ${y.status==="resolved"?"text-gray-600 line-through":"text-gray-300"}`,children:y.description}),n.jsxs("div",{className:"flex items-center gap-3 mt-1.5 font-mono text-[10px] text-gray-600",children:[n.jsx("span",{className:"truncate max-w-[120px]",children:y.featureName}),n.jsx("span",{children:"•"}),n.jsx("span",{children:y.estimated_effort||"TBD"}),y.assigned_to&&n.jsxs(n.Fragment,{children:[n.jsx("span",{children:"•"}),n.jsxs("span",{className:"text-signal",children:["@",y.assigned_to]})]})]})]}),n.jsx("div",{className:`led ${C.led}`,title:C.label}),n.jsx(ns,{className:`w-4 h-4 text-gray-600 transition-transform flex-shrink-0 ${T?"rotate-180":""}`})]}),T&&!P&&n.jsxs("div",{className:"px-4 pb-4 pt-2 border-t border-white/5 space-y-4 animate-fade-in",children:[n.jsxs("div",{className:"flex items-center gap-2 p-3 bg-black/30 border border-white/5",children:[n.jsx("span",{className:"font-mono text-[10px] text-gray-600",children:"STATUS:"}),n.jsx("div",{className:"flex gap-1",children:["pending","in_progress","resolved"].map(D=>{const _=m[D],Y=(y.status||"pending")===D;return n.jsxs("button",{onClick:()=>u(y.featureId,y.taskId,y.debtIndex,D),className:`flex items-center gap-1.5 px-3 py-1.5 font-mono text-[10px] border transition-all ${Y?`${_.color} border-current bg-current/10`:"border-white/10 text-gray-600 hover:border-white/20"}`,children:[n.jsx("div",{className:`led ${_.led}`,style:{width:"6px",height:"6px"}}),_.label]},D)})}),n.jsxs("div",{className:"ml-auto flex gap-2",children:[n.jsx("button",{onClick:()=>h(y.id),className:"p-1.5 text-gray-600 hover:text-cyber transition-all",title:"Edit",children:n.jsx(ti,{className:"w-4 h-4"})}),n.jsx("button",{onClick:()=>S(y.featureId,y.taskId,y.debtIndex),className:"p-1.5 text-gray-600 hover:text-alert transition-all",title:"Delete",children:n.jsx(ft,{className:"w-4 h-4"})})]})]}),n.jsxs("div",{children:[n.jsx("h5",{className:"font-mono text-[10px] text-gray-600 tracking-wider mb-2",children:"# DESCRIPTION"}),n.jsx("p",{className:"font-mono text-xs text-gray-400",children:y.description})]}),y.impact&&n.jsxs("div",{className:"p-3 border border-alert/20 bg-alert/5",children:[n.jsxs("h5",{className:"font-mono text-[10px] text-alert tracking-wider mb-2 flex items-center gap-2",children:[n.jsx(Oe,{className:"w-3 h-3"})," IMPACT"]}),n.jsx("p",{className:"font-mono text-xs text-gray-400",children:y.impact})]}),y.solution&&n.jsxs("div",{className:"p-3 border border-matrix/20 bg-matrix/5",children:[n.jsxs("h5",{className:"font-mono text-[10px] text-matrix tracking-wider mb-2 flex items-center gap-2",children:[n.jsx(_u,{className:"w-3 h-3"})," PROPOSED SOLUTION"]}),n.jsx("p",{className:"font-mono text-xs text-gray-400",children:y.solution})]}),y.affected_files&&y.affected_files.length>0&&n.jsxs("div",{children:[n.jsx("h5",{className:"font-mono text-[10px] text-gray-600 tracking-wider mb-2",children:"# AFFECTED FILES"}),n.jsx("div",{className:"flex flex-wrap gap-2",children:y.affected_files.map((D,_)=>n.jsx("code",{className:"font-mono text-[11px] px-2 py-1 bg-black/50 border border-white/10 text-cyber",children:D},_))})]}),n.jsxs("div",{className:"grid grid-cols-2 sm:grid-cols-4 gap-3",children:[n.jsxs("div",{className:"bg-black/30 p-3 border border-white/5",children:[n.jsx("div",{className:"font-mono text-[9px] text-gray-600 tracking-wider mb-1",children:"FEATURE"}),n.jsx("div",{className:"font-mono text-xs text-white truncate",children:y.featureName})]}),n.jsxs("div",{className:"bg-black/30 p-3 border border-white/5",children:[n.jsx("div",{className:"font-mono text-[9px] text-gray-600 tracking-wider mb-1",children:"TASK"}),n.jsx("div",{className:"font-mono text-xs text-white truncate",children:y.taskName})]}),n.jsxs("div",{className:"bg-black/30 p-3 border border-white/5",children:[n.jsx("div",{className:"font-mono text-[9px] text-gray-600 tracking-wider mb-1",children:"EFFORT"}),n.jsx("div",{className:"font-mono text-xs text-signal",children:y.estimated_effort||"Not estimated"})]}),n.jsxs("div",{className:"bg-black/30 p-3 border border-white/5",children:[n.jsx("div",{className:"font-mono text-[9px] text-gray-600 tracking-wider mb-1",children:"PRIORITY"}),n.jsx("div",{className:`font-mono text-xs ${y.priority==="critical"?"text-alert":y.priority==="high"?"text-signal":"text-cyber"}`,children:y.priority||y.severity||"Medium"})]})]}),n.jsxs("div",{className:"flex items-center gap-4 pt-3 border-t border-white/5 font-mono text-[10px] text-gray-600 flex-wrap",children:[y.created_at&&n.jsxs("span",{children:["Created: ",new Date(y.created_at).toLocaleDateString()]}),y.resolved_at&&n.jsxs("span",{className:"text-matrix",children:["Resolved: ",new Date(y.resolved_at).toLocaleDateString()]}),y.assigned_to&&n.jsxs("span",{className:"text-signal",children:["Assigned: @",y.assigned_to]}),y.due_date&&n.jsxs("span",{className:"text-alert",children:["Due: ",new Date(y.due_date).toLocaleDateString()]})]}),y.tags&&y.tags.length>0&&n.jsx("div",{className:"flex flex-wrap gap-1",children:y.tags.map((D,_)=>n.jsxs("span",{className:"font-mono text-[9px] px-2 py-0.5 bg-white/5 border border-white/10 text-gray-500",children:["#",D]},_))})]}),T&&P&&n.jsx("div",{className:"px-4 pb-4 pt-2 border-t border-white/5",children:n.jsx(xc,{features:x,team:teamMembers,initialData:y,onSave:(D,_,Y)=>j(y.featureId,y.taskId,y.debtIndex,Y),onCancel:()=>h(null),isEdit:!0})})]},y.id)})})]}):n.jsxs("div",{className:"terminal-card p-12 text-center",children:[n.jsx(Ie,{className:"w-10 h-10 mx-auto mb-4 text-matrix"}),n.jsx("p",{className:"font-mono text-sm text-gray-600",children:N.length===0?"NO TECHNICAL DEBT REGISTERED":"NO ITEMS MATCH FILTERS"}),N.length===0&&n.jsxs("button",{onClick:()=>f(!0),className:"btn-terminal mt-4 inline-flex items-center gap-2",children:[n.jsx(un,{className:"w-4 h-4"}),"ADD FIRST DEBT"]})]}),n.jsx("div",{className:"terminal-card p-4",children:n.jsxs("details",{children:[n.jsx("summary",{className:"font-mono text-[10px] text-gray-600 cursor-pointer hover:text-white",children:"JSON SCHEMA FOR TECHNICAL DEBT"}),n.jsx("pre",{className:"mt-4 p-4 bg-void-100 border border-white/5 font-mono text-[10px] text-gray-500 overflow-x-auto",children:`{
|
|
314
|
-
"technical_debt": [
|
|
315
|
-
{
|
|
316
|
-
"description": "Main description of the debt",
|
|
317
|
-
"severity": "high | medium | low",
|
|
318
|
-
"estimated_effort": "2h | 1d | 1w",
|
|
319
|
-
"impact": "What happens if not fixed",
|
|
320
|
-
"solution": "Proposed solution approach",
|
|
321
|
-
"affected_files": ["src/file1.js", "src/file2.js"],
|
|
322
|
-
"status": "pending | in_progress | resolved",
|
|
323
|
-
"priority": "critical | high | medium | low",
|
|
324
|
-
"assigned_to": "developer_name",
|
|
325
|
-
"created_at": "2024-01-15T10:00:00Z",
|
|
326
|
-
"due_date": "2024-02-01T00:00:00Z",
|
|
327
|
-
"tags": ["security", "performance", "refactor"]
|
|
328
|
-
}
|
|
329
|
-
]
|
|
330
|
-
}`})]})})]})}function xc({features:e,team:t,initialData:r,onSave:s,onCancel:l,isEdit:a}){var F,Ne,xe;const[i,o]=v.useState((r==null?void 0:r.featureId)||((F=e[0])==null?void 0:F.id)||""),[c,d]=v.useState((r==null?void 0:r.taskId)||""),[f,g]=v.useState((r==null?void 0:r.description)||""),[h,x]=v.useState((r==null?void 0:r.severity)||"medium"),[N,E]=v.useState((r==null?void 0:r.priority)||"medium"),[b,m]=v.useState((r==null?void 0:r.estimated_effort)||""),[u,p]=v.useState((r==null?void 0:r.impact)||""),[j,S]=v.useState((r==null?void 0:r.solution)||""),[R,y]=v.useState((r==null?void 0:r.assigned_to)||""),[T,P]=v.useState(((Ne=r==null?void 0:r.affected_files)==null?void 0:Ne.join(", "))||""),[C,L]=v.useState(((xe=r==null?void 0:r.tags)==null?void 0:xe.join(", "))||""),D=e.find(k=>k.id===i),_=(D==null?void 0:D.tasks)||[];v.useEffect(()=>{!a&&_.length>0&&!c&&d(_[0].id)},[i,_,a,c]);const Y=k=>{if(k.preventDefault(),!f.trim()||!a&&(!i||!c))return;const V={description:f,severity:h,priority:N,estimated_effort:b||null,impact:u||null,solution:j||null,assigned_to:R||null,affected_files:T?T.split(",").map(H=>H.trim()).filter(Boolean):[],tags:C?C.split(",").map(H=>H.trim()).filter(Boolean):[]};s(i,c,V)};return n.jsxs("form",{onSubmit:Y,className:"terminal-card p-5 space-y-4",children:[n.jsx("h3",{className:"font-mono text-sm text-signal tracking-wider",children:a?"# EDIT DEBT":"# NEW TECHNICAL DEBT"}),!a&&n.jsxs("div",{className:"grid grid-cols-2 gap-3",children:[n.jsxs("div",{children:[n.jsx("label",{className:"font-mono text-[10px] text-gray-500 tracking-wider mb-2 block",children:"FEATURE *"}),n.jsxs("select",{value:i,onChange:k=>{o(k.target.value),d("")},className:"input-terminal w-full px-3 py-2 text-sm",required:!0,children:[n.jsx("option",{value:"",children:"Select feature..."}),e.map(k=>n.jsx("option",{value:k.id,children:k.name},k.id))]})]}),n.jsxs("div",{children:[n.jsx("label",{className:"font-mono text-[10px] text-gray-500 tracking-wider mb-2 block",children:"TASK *"}),n.jsxs("select",{value:c,onChange:k=>d(k.target.value),className:"input-terminal w-full px-3 py-2 text-sm",required:!0,disabled:!i,children:[n.jsx("option",{value:"",children:"Select task..."}),_.map(k=>n.jsx("option",{value:k.id,children:k.name},k.id))]})]})]}),n.jsxs("div",{children:[n.jsx("label",{className:"font-mono text-[10px] text-gray-500 tracking-wider mb-2 block",children:"DESCRIPTION *"}),n.jsx("textarea",{value:f,onChange:k=>g(k.target.value),placeholder:"Describe the technical debt...",rows:2,className:"input-terminal w-full px-3 py-2 text-sm resize-none",required:!0})]}),n.jsxs("div",{className:"grid grid-cols-2 sm:grid-cols-4 gap-3",children:[n.jsxs("div",{children:[n.jsx("label",{className:"font-mono text-[10px] text-gray-500 tracking-wider mb-2 block",children:"SEVERITY"}),n.jsxs("select",{value:h,onChange:k=>x(k.target.value),className:"input-terminal w-full px-3 py-2 text-sm",children:[n.jsx("option",{value:"high",children:"HIGH"}),n.jsx("option",{value:"medium",children:"MEDIUM"}),n.jsx("option",{value:"low",children:"LOW"})]})]}),n.jsxs("div",{children:[n.jsx("label",{className:"font-mono text-[10px] text-gray-500 tracking-wider mb-2 block",children:"PRIORITY"}),n.jsxs("select",{value:N,onChange:k=>E(k.target.value),className:"input-terminal w-full px-3 py-2 text-sm",children:[n.jsx("option",{value:"critical",children:"CRITICAL"}),n.jsx("option",{value:"high",children:"HIGH"}),n.jsx("option",{value:"medium",children:"MEDIUM"}),n.jsx("option",{value:"low",children:"LOW"})]})]}),n.jsxs("div",{children:[n.jsx("label",{className:"font-mono text-[10px] text-gray-500 tracking-wider mb-2 block",children:"EFFORT"}),n.jsx("input",{type:"text",value:b,onChange:k=>m(k.target.value),placeholder:"e.g. 2h, 1d",className:"input-terminal w-full px-3 py-2 text-sm"})]}),n.jsxs("div",{children:[n.jsx("label",{className:"font-mono text-[10px] text-gray-500 tracking-wider mb-2 block",children:"ASSIGNED"}),n.jsxs("select",{value:R,onChange:k=>y(k.target.value),className:"input-terminal w-full px-3 py-2 text-sm",children:[n.jsx("option",{value:"",children:"Unassigned"}),t.map(k=>n.jsx("option",{value:k.name,children:k.name},k.id))]})]})]}),n.jsxs("div",{children:[n.jsx("label",{className:"font-mono text-[10px] text-gray-500 tracking-wider mb-2 block",children:"IMPACT"}),n.jsx("textarea",{value:u,onChange:k=>p(k.target.value),placeholder:"What happens if not fixed?",rows:2,className:"input-terminal w-full px-3 py-2 text-sm resize-none"})]}),n.jsxs("div",{children:[n.jsx("label",{className:"font-mono text-[10px] text-gray-500 tracking-wider mb-2 block",children:"PROPOSED SOLUTION"}),n.jsx("textarea",{value:j,onChange:k=>S(k.target.value),placeholder:"How to fix this?",rows:2,className:"input-terminal w-full px-3 py-2 text-sm resize-none"})]}),n.jsxs("div",{className:"grid grid-cols-2 gap-3",children:[n.jsxs("div",{children:[n.jsx("label",{className:"font-mono text-[10px] text-gray-500 tracking-wider mb-2 block",children:"AFFECTED FILES"}),n.jsx("input",{type:"text",value:T,onChange:k=>P(k.target.value),placeholder:"src/file1.js, src/file2.js",className:"input-terminal w-full px-3 py-2 text-sm"})]}),n.jsxs("div",{children:[n.jsx("label",{className:"font-mono text-[10px] text-gray-500 tracking-wider mb-2 block",children:"TAGS"}),n.jsx("input",{type:"text",value:C,onChange:k=>L(k.target.value),placeholder:"security, performance",className:"input-terminal w-full px-3 py-2 text-sm"})]})]}),n.jsxs("div",{className:"flex gap-3 pt-2",children:[n.jsx("button",{type:"button",onClick:l,className:"px-4 py-2 border border-white/10 text-gray-500 font-mono text-xs hover:text-white transition-all",children:"CANCEL"}),n.jsx("button",{type:"submit",className:"btn-terminal flex-1 py-2",children:a?"UPDATE":"ADD DEBT"})]})]})}function Wf({projectInfo:e}){const t=e.conventions||{};return n.jsxs("div",{className:"space-y-6 animate-fade-in",children:[n.jsxs("div",{className:"terminal-card p-5",children:[n.jsx("h3",{className:"font-mono text-sm text-matrix tracking-wider mb-4",children:"# STACK"}),n.jsxs("div",{className:"flex flex-wrap gap-2",children:[(e.stack||[]).map((r,s)=>n.jsx("span",{className:"font-mono text-xs px-3 py-1.5 border border-matrix/30 text-matrix bg-matrix/5",children:r},s)),(!e.stack||e.stack.length===0)&&n.jsx("p",{className:"font-mono text-xs text-gray-600",children:"NO STACK DEFINED"})]})]}),e.architecture&&n.jsxs("div",{className:"terminal-card p-5",children:[n.jsx("h3",{className:"font-mono text-sm text-cyber tracking-wider mb-4",children:"# ARCHITECTURE"}),n.jsx("p",{className:"font-mono text-xs text-gray-400 leading-relaxed",children:e.architecture})]}),Object.keys(t).length>0&&n.jsxs("div",{className:"terminal-card p-5",children:[n.jsx("h3",{className:"font-mono text-sm text-signal tracking-wider mb-4",children:"# CONVENTIONS"}),n.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-4",children:[t.naming&&n.jsxs("div",{className:"bg-void-100 border border-white/5 p-4",children:[n.jsx("h4",{className:"font-mono text-[10px] text-matrix tracking-wider mb-3",children:"NAMING"}),typeof t.naming=="object"?n.jsx("div",{className:"space-y-1",children:Object.entries(t.naming).map(([r,s])=>n.jsxs("div",{className:"flex justify-between font-mono text-[11px]",children:[n.jsxs("span",{className:"text-gray-600",children:[r,":"]}),n.jsx("span",{className:"text-gray-400",children:s})]},r))}):n.jsx("p",{className:"font-mono text-xs text-gray-400",children:t.naming})]}),t.file_structure&&n.jsxs("div",{className:"bg-void-100 border border-white/5 p-4",children:[n.jsx("h4",{className:"font-mono text-[10px] text-cyber tracking-wider mb-3",children:"FILE STRUCTURE"}),n.jsx("p",{className:"font-mono text-xs text-gray-400",children:t.file_structure})]}),t.database&&n.jsxs("div",{className:"bg-void-100 border border-white/5 p-4",children:[n.jsx("h4",{className:"font-mono text-[10px] text-signal tracking-wider mb-3",children:"DATABASE"}),n.jsx("p",{className:"font-mono text-xs text-gray-400",children:t.database})]}),t.styling&&n.jsxs("div",{className:"bg-void-100 border border-white/5 p-4",children:[n.jsx("h4",{className:"font-mono text-[10px] text-alert tracking-wider mb-3",children:"STYLING"}),n.jsx("p",{className:"font-mono text-xs text-gray-400",children:t.styling})]}),t.error_handling&&n.jsxs("div",{className:"bg-void-100 border border-white/5 p-4 md:col-span-2",children:[n.jsx("h4",{className:"font-mono text-[10px] text-matrix tracking-wider mb-3",children:"ERROR HANDLING"}),n.jsx("p",{className:"font-mono text-xs text-gray-400",children:t.error_handling})]})]})]}),e.purpose&&n.jsxs("div",{className:"terminal-card p-5",children:[n.jsx("h3",{className:"font-mono text-sm text-matrix tracking-wider mb-4",children:"# PURPOSE"}),n.jsx("p",{className:"font-mono text-xs text-gray-400 leading-relaxed",children:e.purpose})]}),e.last_sync&&n.jsxs("div",{className:"flex items-center gap-2 font-mono text-[10px] text-gray-600",children:[n.jsx(pf,{className:"w-3 h-3"}),"LAST SYNC: ",new Date(e.last_sync).toLocaleString("es-ES")]})]})}function Kf({roadmap:e,setRoadmap:t,setHasChanges:r,authState:s,showConfirm:l,showAlert:a,t:i,language:o,changeLanguage:c}){var ne,je,ct,ce,_r;const[d,f]=v.useState(null),[g,h]=v.useState(""),[x,N]=v.useState(!1),[E,b]=v.useState(!1),[m,u]=v.useState(null),[p,j]=v.useState(null),[S,R]=v.useState(!1),[y,T]=v.useState(!1),[P,C]=v.useState(""),[L,D]=v.useState(null),[_,Y]=v.useState(!1),[F,Ne]=v.useState(!1),[xe,k]=v.useState("profile"),[V,H]=v.useState(!1),[Z,G]=v.useState([]),[gt,$e]=v.useState(!1),[J,me]=v.useState({name:"",email:"",password:"",role:"member"}),[Te,Ot]=v.useState(null),[hr,Dr]=v.useState(null),[Bt,ee]=v.useState({requireAuth:!0}),Le=((ne=s==null?void 0:s.user)==null?void 0:ne.role)==="admin",[xn,hn]=v.useState(!1),[he,at]=v.useState({name:((je=s==null?void 0:s.user)==null?void 0:je.name)||"",email:((ct=s==null?void 0:s.user)==null?void 0:ct.email)||"",currentPassword:"",newPassword:"",confirmPassword:""}),[gr,A]=v.useState(null),[z,ae]=v.useState(null),[pe,qe]=v.useState(!1);v.useEffect(()=>{s!=null&&s.user&&at(w=>({...w,name:s.user.name||"",email:s.user.email||""}))},[s==null?void 0:s.user]);const Wt=async()=>{if(A(null),ae(null),he.newPassword&&he.newPassword!==he.confirmPassword){A("New passwords do not match");return}if(he.newPassword&&!he.currentPassword){A("Current password required to set new password");return}if(he.newPassword&&he.newPassword.length<6){A("New password must be at least 6 characters");return}qe(!0);try{const w={name:he.name,email:he.email};he.newPassword&&(w.currentPassword=he.currentPassword,w.newPassword=he.newPassword);const U=await fetch("/api/auth/profile",{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify(w)}),W=await U.json();U.ok?(ae("Profile updated successfully"),at(_e=>({..._e,currentPassword:"",newPassword:"",confirmPassword:""})),W.user&&window.location&&setTimeout(()=>window.location.reload(),1500)):A(W.error||"Failed to update profile")}catch{A("Error updating profile")}qe(!1)},Dt=async()=>{if(Le){$e(!0);try{const[w,U]=await Promise.all([fetch("/api/users"),fetch("/api/auth/settings")]);if(w.ok){const W=await w.json();G(W.users||[])}if(U.ok){const W=await U.json();ee(W.settings||{})}}catch(w){console.error("Error loading users:",w)}$e(!1)}};v.useEffect(()=>{V&&Le&&Z.length===0&&Dt()},[V,Le]);const Kt=async()=>{if(!J.name.trim()||!J.email.trim()||!J.password.trim()){Ot(o==="es"?"Todos los campos son requeridos":"All fields are required");return}Ot(null);try{const w=await fetch("/api/users",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(J)}),U=await w.json();w.ok?(G(W=>[...W,U.user]),me({name:"",email:"",password:"",role:"member"})):Ot(U.error)}catch{Ot(o==="es"?"Error al crear usuario":"Error creating user")}},Yt=async w=>{l(i("settings.deleteUser"),o==="es"?"¿Estás seguro de que quieres eliminar este usuario?":"Are you sure you want to delete this user?",async()=>{try{const U=await fetch(`/api/users/${w}`,{method:"DELETE"});if(U.ok)G(W=>W.filter(_e=>_e.id!==w));else{const W=await U.json();a(i("common.error"),W.error||(o==="es"?"Error al eliminar usuario":"Error deleting user"))}}catch{a(i("common.error"),o==="es"?"Error al eliminar usuario":"Error deleting user")}})},Pr=async w=>{try{const U=await fetch("/api/auth/settings",{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify(w)});if(U.ok){const W=await U.json();ee(W.settings)}}catch(U){console.error("Error updating settings:",U)}};v.useEffect(()=>{h(ex()),C(JSON.stringify(e,null,2)),fetch("/api/project-info").then(w=>w.json()).then(w=>j(w)).catch(()=>{})},[e]);const Pt=()=>{try{const w=JSON.parse(P);if(!w.project_info||!w.features)throw new Error("JSON must have project_info and features");t(w),r(!0),D(null),T(!1)}catch(w){D(w.message)}},kt=()=>{try{const w=JSON.parse(P);C(JSON.stringify(w,null,2)),D(null)}catch(w){D("INVALID JSON: "+w.message)}},ie=(w,U)=>{navigator.clipboard.writeText(w),f(U),setTimeout(()=>f(null),2e3)},se=(w,U)=>{const W=new Blob([w],{type:"text/plain"}),_e=URL.createObjectURL(W),yr=document.createElement("a");yr.href=_e,yr.download=U,yr.click(),URL.revokeObjectURL(_e)},oe=async()=>{b(!0),u(null);try{const w={clinerules:g,roadmap:e};S&&(w.cursorrules=g);const U=await fetch("/api/deploy",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(w)});if(U.ok){const W=await U.json();u({type:"success",text:`DEPLOYED: ${W.projectRoot}`,files:W.files})}else throw new Error("API unavailable")}catch{se(g,".clinerules"),S&&se(g,".cursorrules"),se(JSON.stringify(e,null,2),"roadmap.json"),u({type:"info",text:"FILES DOWNLOADED. Copy manually to project root."})}finally{b(!1)}},[it,yt]=v.useState([]),[Xe,gn]=v.useState(!1),[ot,Lr]=v.useState(null),[yn,O]=v.useState(!1),B=async()=>{gn(!0);try{const w=await fetch("/api/versions");if(w.ok){const U=await w.json();yt(U.versions||[])}}catch(w){console.error("Error loading versions:",w)}gn(!1)},K=async w=>{try{const U=await fetch(`/api/versions/${w}`);if(U.ok){const W=await U.json();Lr(W.version)}}catch(U){console.error("Error loading version:",U)}},Q=async w=>{if(await l({title:"RESTORE VERSION",message:"This will restore the selected version. A backup of the current state will be saved first.",type:"warning",confirmText:"RESTORE",cancelText:"CANCEL"})){O(!0);try{const W=await fetch(`/api/versions/${w}/restore`,{method:"POST"});if(W.ok){const _e=await W.json();t(_e.roadmap),Lr(null),B(),a({title:"VERSION RESTORED",message:"The roadmap has been restored successfully. A backup was saved.",type:"success"})}}catch(W){a({title:"RESTORE FAILED",message:W.message,type:"error"})}O(!1)}},te=[{id:"profile",label:i("settings.profile"),icon:ni,show:!!(s!=null&&s.user)},{id:"users",label:i("settings.users"),icon:Du,show:Le},{id:"history",label:i("settings.history"),icon:dc,show:!0},{id:"files",label:i("settings.files"),icon:ei,show:!0},{id:"language",label:i("settings.language"),icon:wf,show:!0}].filter(w=>w.show);return v.useEffect(()=>{var w;te.find(U=>U.id===xe)||k(((w=te[0])==null?void 0:w.id)||"profile")},[Le,s==null?void 0:s.user]),n.jsxs("div",{className:"space-y-6 animate-fade-in",children:[n.jsx("div",{className:"flex gap-2 flex-wrap border-b border-white/10 pb-4",children:te.map(w=>{const U=w.icon;return n.jsxs("button",{onClick:()=>k(w.id),className:`flex items-center gap-2 px-4 py-2.5 font-mono text-xs tracking-wider border transition-all ${xe===w.id?"border-signal text-signal bg-signal/10":"border-white/10 text-gray-500 hover:text-gray-300 hover:border-white/20"}`,children:[n.jsx(U,{className:"w-4 h-4"}),w.label]},w.id)})}),xe==="profile"&&(s==null?void 0:s.user)&&n.jsxs("div",{className:"terminal-card p-5 space-y-5",children:[n.jsxs("div",{className:"flex items-center gap-3 mb-2",children:[n.jsx("div",{className:"w-12 h-12 border border-cyber/30 bg-cyber/10 flex items-center justify-center font-display text-cyber text-xl",children:((ce=s.user.name)==null?void 0:ce.charAt(0).toUpperCase())||"U"}),n.jsxs("div",{children:[n.jsx("h3",{className:"font-mono text-sm text-white",children:s.user.name}),n.jsx("p",{className:"font-mono text-[11px] text-gray-500",children:s.user.email}),n.jsx("span",{className:`font-mono text-[9px] px-1.5 py-0.5 mt-1 inline-block ${s.user.role==="admin"?"bg-alert/20 text-alert":"bg-cyber/20 text-cyber"}`,children:(_r=s.user.role)==null?void 0:_r.toUpperCase()})]})]}),gr&&n.jsxs("div",{className:"p-3 border border-alert/30 bg-alert/5 font-mono text-xs text-alert flex items-center gap-2",children:[n.jsx(Oe,{className:"w-4 h-4"}),gr]}),z&&n.jsxs("div",{className:"p-3 border border-matrix/30 bg-matrix/5 font-mono text-xs text-matrix flex items-center gap-2",children:[n.jsx(dr,{className:"w-4 h-4"}),z]}),n.jsxs("div",{className:"grid grid-cols-1 sm:grid-cols-2 gap-4",children:[n.jsxs("div",{children:[n.jsx("label",{className:"font-mono text-[10px] text-gray-500 tracking-wider block mb-2",children:"NAME"}),n.jsx("input",{type:"text",value:he.name,onChange:w=>at(U=>({...U,name:w.target.value})),className:"w-full input-terminal px-3 py-2 text-sm",placeholder:"Your name"})]}),n.jsxs("div",{children:[n.jsx("label",{className:"font-mono text-[10px] text-gray-500 tracking-wider block mb-2",children:"EMAIL"}),n.jsx("input",{type:"email",value:he.email,onChange:w=>at(U=>({...U,email:w.target.value})),className:"w-full input-terminal px-3 py-2 text-sm",placeholder:"your@email.com"})]})]}),n.jsxs("div",{className:"border-t border-white/5 pt-5",children:[n.jsx("h4",{className:"font-mono text-[10px] text-gray-500 tracking-wider mb-4",children:"CHANGE PASSWORD"}),n.jsxs("div",{className:"grid grid-cols-1 sm:grid-cols-3 gap-4",children:[n.jsxs("div",{children:[n.jsx("label",{className:"font-mono text-[10px] text-gray-600 block mb-2",children:"Current Password"}),n.jsx("input",{type:"password",value:he.currentPassword,onChange:w=>at(U=>({...U,currentPassword:w.target.value})),className:"w-full input-terminal px-3 py-2 text-sm",placeholder:"Required"})]}),n.jsxs("div",{children:[n.jsx("label",{className:"font-mono text-[10px] text-gray-600 block mb-2",children:"New Password"}),n.jsx("input",{type:"password",value:he.newPassword,onChange:w=>at(U=>({...U,newPassword:w.target.value})),className:"w-full input-terminal px-3 py-2 text-sm",placeholder:"Min 6 chars"})]}),n.jsxs("div",{children:[n.jsx("label",{className:"font-mono text-[10px] text-gray-600 block mb-2",children:"Confirm Password"}),n.jsx("input",{type:"password",value:he.confirmPassword,onChange:w=>at(U=>({...U,confirmPassword:w.target.value})),className:"w-full input-terminal px-3 py-2 text-sm",placeholder:"Repeat"})]})]})]}),n.jsxs("button",{onClick:Wt,disabled:pe,className:"btn-terminal py-2 px-6 disabled:opacity-50 flex items-center gap-2",children:[pe?n.jsx(et,{className:"w-4 h-4 animate-spin"}):n.jsx(Lu,{className:"w-4 h-4"}),"SAVE CHANGES"]})]}),xe==="history"&&n.jsxs("div",{className:"terminal-card p-5",children:[n.jsxs("div",{className:"flex items-center justify-between mb-4",children:[n.jsxs("div",{children:[n.jsx("h3",{className:"font-mono text-sm text-white",children:"VERSION HISTORY"}),n.jsxs("p",{className:"font-mono text-[10px] text-gray-600",children:["Last ",it.length," changes • Click to preview & restore"]})]}),n.jsx("button",{onClick:B,disabled:Xe,className:"btn-terminal py-2 px-4 text-xs",children:Xe?n.jsx(et,{className:"w-4 h-4 animate-spin"}):n.jsx(pl,{className:"w-4 h-4"})})]}),it.length===0&&!Xe&&n.jsxs("div",{className:"py-10 text-center border border-dashed border-white/10",children:[n.jsx(dc,{className:"w-10 h-10 mx-auto mb-3 text-gray-800"}),n.jsx("p",{className:"font-mono text-xs text-gray-600",children:"NO VERSIONS YET"}),n.jsx("p",{className:"font-mono text-[10px] text-gray-700 mt-1",children:"Versions are saved automatically when you save changes"}),n.jsx("button",{onClick:B,className:"mt-4 btn-terminal py-2 px-4 text-xs",children:"LOAD HISTORY"})]}),Xe&&n.jsx("div",{className:"py-10 text-center",children:n.jsx(et,{className:"w-8 h-8 mx-auto animate-spin text-gray-600"})}),it.length>0&&n.jsx("div",{className:"space-y-2",children:it.map((w,U)=>n.jsx("div",{className:`p-4 border transition-all cursor-pointer ${(ot==null?void 0:ot.id)===w.id?"border-cyber/50 bg-cyber/5":"border-white/5 bg-void-100 hover:border-white/20"}`,onClick:()=>K(w.id),children:n.jsxs("div",{className:"flex items-center justify-between",children:[n.jsxs("div",{className:"flex items-center gap-3",children:[n.jsx("div",{className:`w-8 h-8 border flex items-center justify-center font-display text-xs ${U===0?"border-matrix/30 bg-matrix/10 text-matrix":"border-gray-700 bg-gray-800 text-gray-500"}`,children:U===0?"NOW":`-${U}`}),n.jsxs("div",{children:[n.jsx("div",{className:"font-mono text-xs text-white",children:new Date(w.timestamp).toLocaleString()}),n.jsxs("div",{className:"font-mono text-[10px] text-gray-500",children:[w.userName," • ",w.description]})]})]}),n.jsxs("div",{className:"font-mono text-[10px] text-gray-600",children:[w.featuresCount," features • ",w.tasksCount," tasks"]})]})},w.id))}),ot&&(()=>{const w=_f(e,ot.snapshot),U=w.summary.added>0||w.summary.removed>0||w.summary.modified>0;return n.jsxs("div",{className:"mt-5 p-4 border border-cyber/30 bg-cyber/5",children:[n.jsxs("div",{className:"flex items-center justify-between mb-3",children:[n.jsxs("div",{className:"font-mono text-sm text-cyber flex items-center gap-2",children:[n.jsx(jf,{className:"w-4 h-4"}),"VERSION DIFF"]}),n.jsxs("button",{onClick:()=>Q(ot.id),disabled:yn,className:"btn-terminal py-2 px-4 text-xs flex items-center gap-2",children:[yn?n.jsx(et,{className:"w-4 h-4 animate-spin"}):n.jsx(pl,{className:"w-4 h-4"}),"RESTORE THIS VERSION"]})]}),n.jsxs("div",{className:"text-xs font-mono text-gray-400 mb-4",children:[new Date(ot.timestamp).toLocaleString()," by ",ot.userName]}),n.jsxs("div",{className:"grid grid-cols-3 gap-3 mb-4",children:[n.jsxs("div",{className:"p-3 bg-matrix/10 border border-matrix/30",children:[n.jsxs("div",{className:"flex items-center gap-2",children:[n.jsx(la,{className:"w-4 h-4 text-matrix"}),n.jsx("div",{className:"font-mono text-[10px] text-matrix",children:"ADDED"})]}),n.jsx("div",{className:"font-display text-lg text-matrix",children:w.summary.added})]}),n.jsxs("div",{className:"p-3 bg-alert/10 border border-alert/30",children:[n.jsxs("div",{className:"flex items-center gap-2",children:[n.jsx(sa,{className:"w-4 h-4 text-alert"}),n.jsx("div",{className:"font-mono text-[10px] text-alert",children:"REMOVED"})]}),n.jsx("div",{className:"font-display text-lg text-alert",children:w.summary.removed})]}),n.jsxs("div",{className:"p-3 bg-signal/10 border border-signal/30",children:[n.jsxs("div",{className:"flex items-center gap-2",children:[n.jsx(na,{className:"w-4 h-4 text-signal"}),n.jsx("div",{className:"font-mono text-[10px] text-signal",children:"MODIFIED"})]}),n.jsx("div",{className:"font-display text-lg text-signal",children:w.summary.modified})]})]}),U?n.jsxs("div",{className:"space-y-3 max-h-80 overflow-auto",children:[w.features.added.map(W=>{var _e;return n.jsxs("div",{className:"p-3 bg-matrix/5 border-l-2 border-matrix",children:[n.jsxs("div",{className:"flex items-center gap-2 mb-1",children:[n.jsx(la,{className:"w-3 h-3 text-matrix"}),n.jsxs("span",{className:"font-mono text-xs text-matrix",children:["+ FEATURE: ",W.name]})]}),n.jsxs("p",{className:"font-mono text-[10px] text-gray-500 ml-5",children:[((_e=W.tasks)==null?void 0:_e.length)||0," tasks"]})]},W.id)}),w.features.removed.map(W=>{var _e;return n.jsxs("div",{className:"p-3 bg-alert/5 border-l-2 border-alert",children:[n.jsxs("div",{className:"flex items-center gap-2 mb-1",children:[n.jsx(sa,{className:"w-3 h-3 text-alert"}),n.jsxs("span",{className:"font-mono text-xs text-alert",children:["- FEATURE: ",W.name]})]}),n.jsxs("p",{className:"font-mono text-[10px] text-gray-500 ml-5",children:[((_e=W.tasks)==null?void 0:_e.length)||0," tasks"]})]},W.id)}),w.tasks.added.map(W=>n.jsx("div",{className:"p-2 bg-matrix/5 border-l-2 border-matrix ml-4",children:n.jsxs("div",{className:"flex items-center gap-2",children:[n.jsx(la,{className:"w-3 h-3 text-matrix"}),n.jsxs("span",{className:"font-mono text-[11px] text-matrix",children:["+ ",W.name]}),n.jsxs("span",{className:"font-mono text-[9px] text-gray-600",children:["(",W.featureName,")"]})]})},W.id)),w.tasks.removed.map(W=>n.jsx("div",{className:"p-2 bg-alert/5 border-l-2 border-alert ml-4",children:n.jsxs("div",{className:"flex items-center gap-2",children:[n.jsx(sa,{className:"w-3 h-3 text-alert"}),n.jsxs("span",{className:"font-mono text-[11px] text-alert line-through",children:["- ",W.name]}),n.jsxs("span",{className:"font-mono text-[9px] text-gray-600",children:["(",W.featureName,")"]})]})},W.id)),w.tasks.statusChanged.map(({task:W,featureName:_e,oldStatus:yr,newStatus:Rl})=>n.jsxs("div",{className:"p-2 bg-signal/5 border-l-2 border-signal ml-4",children:[n.jsxs("div",{className:"flex items-center gap-2 flex-wrap",children:[n.jsx(na,{className:"w-3 h-3 text-signal"}),n.jsx("span",{className:"font-mono text-[11px] text-white",children:W.name}),n.jsxs("span",{className:"font-mono text-[9px] text-gray-600",children:["(",_e,")"]})]}),n.jsxs("div",{className:"flex items-center gap-2 ml-5 mt-1",children:[n.jsx("span",{className:`px-2 py-0.5 text-[9px] font-mono ${yr==="completed"?"bg-matrix/20 text-matrix":yr==="in_progress"?"bg-signal/20 text-signal":"bg-gray-700 text-gray-400"}`,children:yr}),n.jsx(na,{className:"w-3 h-3 text-gray-500"}),n.jsx("span",{className:`px-2 py-0.5 text-[9px] font-mono ${Rl==="completed"?"bg-matrix/20 text-matrix":Rl==="in_progress"?"bg-signal/20 text-signal":"bg-gray-700 text-gray-400"}`,children:Rl})]})]},W.id))]}):n.jsxs("div",{className:"py-6 text-center border border-dashed border-white/10",children:[n.jsx(Ie,{className:"w-8 h-8 mx-auto mb-2 text-gray-700"}),n.jsx("p",{className:"font-mono text-xs text-gray-600",children:"NO CHANGES"}),n.jsx("p",{className:"font-mono text-[10px] text-gray-700 mt-1",children:"Current roadmap matches this version"})]}),n.jsxs("details",{className:"group mt-4",children:[n.jsx("summary",{className:"font-mono text-[10px] text-gray-600 cursor-pointer hover:text-gray-400",children:"View raw JSON"}),n.jsx("div",{className:"mt-2 p-3 bg-void-100 border border-white/5 max-h-48 overflow-auto",children:n.jsx("pre",{className:"font-mono text-[10px] text-gray-500 whitespace-pre-wrap",children:JSON.stringify(ot.snapshot,null,2)})})]}),n.jsx("button",{onClick:()=>Lr(null),className:"mt-3 w-full py-2 border border-white/10 text-gray-500 hover:text-white hover:border-white/30 transition-all font-mono text-xs",children:"CLOSE PREVIEW"})]})})()]}),xe==="users"&&Le&&n.jsxs("div",{className:"space-y-5",children:[n.jsx("div",{className:"terminal-card p-5",children:n.jsxs("div",{className:"flex items-center justify-between",children:[n.jsxs("div",{children:[n.jsx("h3",{className:"font-mono text-sm text-white",children:"Authentication Required"}),n.jsx("p",{className:"font-mono text-[10px] text-gray-600",children:"Disable to allow anonymous access"})]}),n.jsx("button",{onClick:()=>Pr({requireAuth:!Bt.requireAuth}),className:`w-14 h-7 rounded-full transition-all relative ${Bt.requireAuth?"bg-matrix":"bg-gray-700"}`,children:n.jsx("div",{className:`absolute top-1 w-5 h-5 bg-white rounded-full transition-transform ${Bt.requireAuth?"left-8":"left-1"}`})})]})}),n.jsxs("div",{className:"terminal-card p-5",children:[n.jsx("h3",{className:"font-mono text-sm text-white mb-4",children:"ADD NEW USER"}),n.jsxs("div",{className:"grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-4 gap-3 mb-3",children:[n.jsx("input",{type:"text",placeholder:"Name *",value:J.name,onChange:w=>me(U=>({...U,name:w.target.value})),className:"input-terminal px-3 py-2 text-sm"}),n.jsx("input",{type:"email",placeholder:"Email *",value:J.email,onChange:w=>me(U=>({...U,email:w.target.value})),className:"input-terminal px-3 py-2 text-sm"}),n.jsx("input",{type:"password",placeholder:"Password *",value:J.password,onChange:w=>me(U=>({...U,password:w.target.value})),className:"input-terminal px-3 py-2 text-sm"}),n.jsxs("select",{value:J.role,onChange:w=>me(U=>({...U,role:w.target.value})),className:"input-terminal px-3 py-2 text-sm",children:[n.jsx("option",{value:"member",children:"Member"}),n.jsx("option",{value:"admin",children:"Admin"})]})]}),Te&&n.jsx("div",{className:"mb-3 p-2 border border-alert/30 bg-alert/5 font-mono text-xs text-alert",children:Te}),n.jsxs("button",{onClick:Kt,disabled:!J.name.trim()||!J.email.trim()||!J.password.trim(),className:"btn-terminal py-2 px-4 disabled:opacity-50",children:[n.jsx(un,{className:"w-4 h-4 inline mr-1"})," CREATE USER"]})]}),n.jsxs("div",{className:"terminal-card p-5",children:[n.jsxs("h3",{className:"font-mono text-sm text-white mb-4",children:["REGISTERED USERS (",Z.length,")"]}),gt?n.jsx("div",{className:"py-8 text-center",children:n.jsx(et,{className:"w-6 h-6 mx-auto animate-spin text-gray-600"})}):Z.length>0?n.jsx("div",{className:"space-y-2",children:Z.map(w=>n.jsxs("div",{className:"flex items-center gap-3 p-3 bg-void-100 border border-white/5",children:[n.jsx("div",{className:`w-10 h-10 border flex items-center justify-center font-display text-sm ${w.role==="admin"?"border-alert/30 bg-alert/10 text-alert":"border-cyber/30 bg-cyber/10 text-cyber"}`,children:w.name.charAt(0).toUpperCase()}),n.jsxs("div",{className:"flex-1",children:[n.jsxs("div",{className:"font-sans text-sm text-white flex items-center gap-2",children:[w.name,n.jsx("span",{className:`font-mono text-[9px] px-1.5 py-0.5 ${w.role==="admin"?"bg-alert/20 text-alert":"bg-cyber/20 text-cyber"}`,children:w.role.toUpperCase()})]}),n.jsx("div",{className:"font-mono text-[10px] text-gray-500",children:w.email})]}),n.jsx("div",{className:"font-mono text-[9px] text-gray-700 hidden sm:block",children:w.lastLogin?`Last: ${new Date(w.lastLogin).toLocaleDateString()}`:"Never logged in"}),n.jsx("button",{onClick:()=>Yt(w.id),className:"p-2 text-gray-600 hover:text-alert transition-all",title:"Delete user",children:n.jsx(ft,{className:"w-4 h-4"})})]},w.id))}):n.jsxs("div",{className:"py-10 text-center border border-dashed border-white/10",children:[n.jsx(ni,{className:"w-10 h-10 mx-auto mb-3 text-gray-800"}),n.jsx("p",{className:"font-mono text-xs text-gray-600",children:"NO USERS FOUND"})]})]})]}),xe==="files"&&n.jsxs("div",{className:"space-y-5",children:[n.jsxs("div",{className:"terminal-card p-5",children:[n.jsxs("div",{className:"flex items-center gap-3 mb-4",children:[n.jsx("div",{className:"led led-green"}),n.jsxs("div",{children:[n.jsx("h3",{className:"font-mono text-sm text-matrix tracking-wider",children:"DEPLOY CONFIG"}),n.jsx("p",{className:"font-mono text-[10px] text-gray-600",children:"Copy files to project root"})]})]}),p&&n.jsxs("div",{className:"mb-4 p-3 border border-matrix/20 bg-matrix/5 font-mono text-[11px]",children:[n.jsx("span",{className:"text-gray-500",children:"PROJECT:"})," ",n.jsx("span",{className:"text-matrix",children:p.projectRoot})]}),n.jsxs("label",{className:"flex items-center gap-2 font-mono text-[11px] text-gray-500 cursor-pointer mb-4",children:[n.jsx("input",{type:"checkbox",checked:S,onChange:w=>R(w.target.checked),className:"w-4 h-4 bg-void-100 border border-white/20 accent-matrix"}),"Also create .cursorrules (for Cursor IDE)"]}),n.jsxs("button",{onClick:oe,disabled:E,className:"btn-terminal flex items-center gap-2",children:[E?n.jsx(et,{className:"w-4 h-4 animate-spin"}):n.jsx(Af,{className:"w-4 h-4"}),"DEPLOY FILES"]}),m&&n.jsxs("div",{className:`mt-4 p-3 border font-mono text-[11px] ${m.type==="success"?"border-matrix/30 text-matrix bg-matrix/5":m.type==="error"?"border-alert/30 text-alert bg-alert/5":"border-cyber/30 text-cyber bg-cyber/5"}`,children:[n.jsx("p",{children:m.text}),m.files&&n.jsx("ul",{className:"mt-2 space-y-1 text-gray-500",children:m.files.map((w,U)=>n.jsxs("li",{children:["✓ ",w]},U))})]})]}),n.jsxs("div",{className:"terminal-card",children:[n.jsxs("button",{onClick:()=>Y(!_),className:"w-full p-4 flex items-center justify-between hover:bg-white/[0.01] transition-colors",children:[n.jsxs("div",{className:"flex items-center gap-3",children:[n.jsx(ei,{className:"w-4 h-4 text-cyber"}),n.jsxs("div",{className:"text-left",children:[n.jsx("h3",{className:"font-mono text-sm text-white",children:".clinerules"}),n.jsx("p",{className:"font-mono text-[10px] text-gray-600",children:"Rules for Claude, Cursor, Cline"})]})]}),n.jsx(ns,{className:`w-4 h-4 text-gray-600 transition-transform ${_?"rotate-180":""}`})]}),_&&n.jsxs("div",{className:"px-4 pb-4 border-t border-white/5",children:[n.jsxs("div",{className:"flex justify-end gap-2 py-3",children:[n.jsx("button",{onClick:()=>se(g,".clinerules"),className:"p-2 border border-white/10 text-gray-500 hover:text-matrix hover:border-matrix/30 transition-all",children:n.jsx(uc,{className:"w-4 h-4"})}),n.jsx("button",{onClick:()=>N(!x),className:`p-2 border transition-all ${x?"border-matrix/30 text-matrix bg-matrix/10":"border-white/10 text-gray-500 hover:text-matrix hover:border-matrix/30"}`,children:x?n.jsx(yf,{className:"w-4 h-4"}):n.jsx(ti,{className:"w-4 h-4"})}),n.jsx("button",{onClick:()=>ie(g,"clinerules"),className:"p-2 border border-white/10 text-gray-500 hover:text-matrix hover:border-matrix/30 transition-all",children:d==="clinerules"?n.jsx(dr,{className:"w-4 h-4 text-matrix"}):n.jsx(dn,{className:"w-4 h-4"})})]}),x?n.jsx("textarea",{value:g,onChange:w=>h(w.target.value),className:"w-full h-[400px] input-terminal p-4 text-xs resize-none",spellCheck:!1}):n.jsx("div",{className:"bg-void-100 border border-white/5 p-4 max-h-[400px] overflow-y-auto",children:n.jsx("pre",{className:"font-mono text-[11px] text-gray-400 whitespace-pre-wrap",children:g})})]})]}),n.jsxs("div",{className:"terminal-card",children:[n.jsxs("button",{onClick:()=>Ne(!F),className:"w-full p-4 flex items-center justify-between hover:bg-white/[0.01] transition-colors",children:[n.jsxs("div",{className:"flex items-center gap-3",children:[n.jsx(gf,{className:"w-4 h-4 text-signal"}),n.jsxs("div",{className:"text-left",children:[n.jsx("h3",{className:"font-mono text-sm text-white",children:"roadmap.json"}),n.jsx("p",{className:"font-mono text-[10px] text-gray-600",children:"Project structure & state"})]})]}),n.jsx(ns,{className:`w-4 h-4 text-gray-600 transition-transform ${F?"rotate-180":""}`})]}),F&&n.jsxs("div",{className:"px-4 pb-4 border-t border-white/5",children:[n.jsxs("div",{className:"flex justify-end gap-2 py-3",children:[n.jsx("button",{onClick:()=>se(JSON.stringify(e,null,2),"roadmap.json"),className:"p-2 border border-white/10 text-gray-500 hover:text-signal hover:border-signal/30 transition-all",children:n.jsx(uc,{className:"w-4 h-4"})}),y&&n.jsxs(n.Fragment,{children:[n.jsx("button",{onClick:kt,className:"p-2 border border-white/10 text-gray-500 hover:text-signal hover:border-signal/30 transition-all",children:n.jsx(Tu,{className:"w-4 h-4"})}),n.jsx("button",{onClick:Pt,className:"px-3 py-2 border border-matrix/30 text-matrix bg-matrix/10 hover:bg-matrix/20 transition-all font-mono text-[10px]",children:"APPLY"})]}),n.jsx("button",{onClick:()=>{y&&(C(JSON.stringify(e,null,2)),D(null)),T(!y)},className:`p-2 border transition-all ${y?"border-alert/30 text-alert":"border-white/10 text-gray-500 hover:text-signal hover:border-signal/30"}`,children:y?n.jsx(ft,{className:"w-4 h-4"}):n.jsx(ti,{className:"w-4 h-4"})}),n.jsx("button",{onClick:()=>ie(JSON.stringify(e,null,2),"json"),className:"p-2 border border-white/10 text-gray-500 hover:text-signal hover:border-signal/30 transition-all",children:d==="json"?n.jsx(dr,{className:"w-4 h-4 text-matrix"}):n.jsx(dn,{className:"w-4 h-4"})})]}),L&&n.jsxs("div",{className:"mb-3 p-3 border border-alert/30 bg-alert/5 text-alert font-mono text-[11px] flex items-center gap-2",children:[n.jsx(Oe,{className:"w-4 h-4"}),L]}),y?n.jsxs(n.Fragment,{children:[n.jsx("textarea",{value:P,onChange:w=>{C(w.target.value),D(null)},className:"w-full h-[400px] input-terminal p-4 text-xs resize-none",spellCheck:!1}),n.jsx("p",{className:"mt-2 font-mono text-[10px] text-gray-600",children:'Edit JSON → "APPLY" → "SAVE" in sidebar'})]}):n.jsx("div",{className:"bg-void-100 border border-white/5 p-4 max-h-[400px] overflow-auto",children:n.jsx("pre",{className:"font-mono text-[11px] text-gray-400 whitespace-pre",children:JSON.stringify(e,null,2)})})]})]})]}),xe==="language"&&n.jsxs("div",{className:"terminal-card p-5",children:[n.jsx("h3",{className:"font-mono text-sm text-white mb-2",children:i("settings.language")}),n.jsx("p",{className:"font-mono text-[10px] text-gray-600 mb-6",children:o==="es"?"Selecciona el idioma de la interfaz":"Select interface language"}),n.jsxs("div",{className:"grid grid-cols-2 gap-4",children:[n.jsxs("button",{onClick:()=>c("es"),className:`p-5 border transition-all text-left ${o==="es"?"border-matrix/50 bg-matrix/10":"border-white/10 hover:border-white/30"}`,children:[n.jsxs("div",{className:"flex items-center gap-3 mb-3",children:[n.jsx("div",{className:`w-10 h-10 border flex items-center justify-center font-display text-lg ${o==="es"?"border-matrix/50 bg-matrix/10 text-matrix":"border-gray-700 text-gray-500"}`,children:"ES"}),n.jsxs("div",{children:[n.jsx("div",{className:`font-mono text-sm ${o==="es"?"text-matrix":"text-white"}`,children:"Español"}),n.jsx("div",{className:"font-mono text-[10px] text-gray-500",children:"Spanish"})]})]}),o==="es"&&n.jsxs("div",{className:"flex items-center gap-2 text-matrix",children:[n.jsx(Ie,{className:"w-4 h-4"}),n.jsx("span",{className:"font-mono text-[10px]",children:"ACTIVO"})]})]}),n.jsxs("button",{onClick:()=>c("en"),className:`p-5 border transition-all text-left ${o==="en"?"border-cyber/50 bg-cyber/10":"border-white/10 hover:border-white/30"}`,children:[n.jsxs("div",{className:"flex items-center gap-3 mb-3",children:[n.jsx("div",{className:`w-10 h-10 border flex items-center justify-center font-display text-lg ${o==="en"?"border-cyber/50 bg-cyber/10 text-cyber":"border-gray-700 text-gray-500"}`,children:"EN"}),n.jsxs("div",{children:[n.jsx("div",{className:`font-mono text-sm ${o==="en"?"text-cyber":"text-white"}`,children:"English"}),n.jsx("div",{className:"font-mono text-[10px] text-gray-500",children:"Inglés"})]})]}),o==="en"&&n.jsxs("div",{className:"flex items-center gap-2 text-cyber",children:[n.jsx(Ie,{className:"w-4 h-4"}),n.jsx("span",{className:"font-mono text-[10px]",children:"ACTIVE"})]})]})]})]})]})}function Yf({t:e,language:t}){const[r,s]=v.useState("templates"),[l,a]=v.useState(null),i=[{id:"templates",label:e("help.templates"),icon:ei},{id:"commits",label:e("help.commits"),icon:Iu},{id:"ai",label:e("help.aiWorkflow"),icon:ml},{id:"troubleshooting",label:e("help.debug"),icon:_u}],o=c=>{navigator.clipboard.writeText(c),a(c),setTimeout(()=>a(null),2e3)};return n.jsxs("div",{className:"space-y-6 animate-fade-in",children:[n.jsx("div",{className:"flex gap-2 flex-wrap",children:i.map(c=>{const d=c.icon;return n.jsxs("button",{onClick:()=>s(c.id),className:`flex items-center gap-2 px-4 py-2.5 font-mono text-xs tracking-wider border transition-all ${r===c.id?"border-matrix text-matrix bg-matrix/10":"border-white/10 text-gray-500 hover:text-gray-300 hover:border-white/20"}`,children:[n.jsx(d,{className:"w-4 h-4"}),c.label]},c.id)})}),r==="templates"&&n.jsxs("div",{className:"space-y-6",children:[n.jsxs("div",{className:"terminal-card p-5",children:[n.jsx("h3",{className:"font-mono text-sm text-matrix tracking-wider mb-4",children:e("help.referenceFiles")}),n.jsx("p",{className:"font-mono text-[11px] text-gray-500 mb-4",children:e("help.sharePaths")}),n.jsx("div",{className:"space-y-2",children:[{path:"roadmap-kit/templates/clinerules.template",label:e("help.clinerulesTpl"),color:"text-cyber"},{path:"roadmap-kit/templates/roadmap.template.json",label:e("help.roadmapTpl"),color:"text-signal"},{path:"roadmap-kit/examples/roadmap-ecommerce.json",label:e("help.exampleEcommerce"),color:"text-matrix"},{path:"roadmap-kit/examples/roadmap-api-rest.json",label:e("help.exampleApi"),color:"text-cyber"},{path:"roadmap-kit/docs/TECHNICAL_DEBT_GUIDE.md",label:e("help.debtGuide"),color:"text-alert"}].map(c=>n.jsxs("div",{className:"flex items-center justify-between p-3 bg-void-100 border border-white/5",children:[n.jsxs("div",{children:[n.jsx("p",{className:`font-mono text-[10px] ${c.color} tracking-wider`,children:c.label}),n.jsx("code",{className:"font-mono text-[11px] text-gray-500",children:c.path})]}),n.jsx("button",{onClick:()=>o(c.path),className:"p-2 hover:bg-white/5 transition-all",children:l===c.path?n.jsx(dr,{className:"w-4 h-4 text-matrix"}):n.jsx(dn,{className:"w-4 h-4 text-gray-600"})})]},c.path))})]}),n.jsxs("div",{className:"terminal-card p-5",children:[n.jsx("h3",{className:"font-mono text-sm text-cyber tracking-wider mb-4",children:e("help.aiInstructions")}),n.jsx("div",{className:"bg-void-100 border border-white/5 p-4 font-mono text-[11px] text-gray-400 overflow-x-auto",children:n.jsx("pre",{className:"whitespace-pre-wrap",children:`Read the example files in:
|
|
331
|
-
- roadmap-kit/examples/roadmap-ecommerce.json
|
|
332
|
-
- roadmap-kit/examples/roadmap-api-rest.json
|
|
333
|
-
|
|
334
|
-
Then generate a roadmap.json for my project following this structure:
|
|
335
|
-
|
|
336
|
-
{
|
|
337
|
-
"project_info": {
|
|
338
|
-
"name": "Project Name",
|
|
339
|
-
"version": "1.0.0",
|
|
340
|
-
"description": "Brief description",
|
|
341
|
-
"purpose": "Main objective",
|
|
342
|
-
"stack": ["Tech1", "Tech2"],
|
|
343
|
-
"architecture": "Architecture description",
|
|
344
|
-
"conventions": { ... },
|
|
345
|
-
"shared_resources": { ... }
|
|
346
|
-
},
|
|
347
|
-
"features": [
|
|
348
|
-
{
|
|
349
|
-
"id": "feature-id",
|
|
350
|
-
"name": "Name",
|
|
351
|
-
"description": "Description",
|
|
352
|
-
"status": "pending",
|
|
353
|
-
"progress": 0,
|
|
354
|
-
"priority": "high|medium|low",
|
|
355
|
-
"tasks": [ ... ]
|
|
356
|
-
}
|
|
357
|
-
]
|
|
358
|
-
}`})})]}),n.jsxs("div",{className:"terminal-card p-5 border-matrix/20",children:[n.jsxs("div",{className:"flex items-center justify-between mb-3",children:[n.jsx("h4",{className:"font-mono text-sm text-matrix",children:e("help.quickPrompt")}),n.jsx("button",{onClick:()=>o(`Read the files:
|
|
359
|
-
- roadmap-kit/templates/clinerules.template
|
|
360
|
-
- roadmap-kit/examples/roadmap-ecommerce.json
|
|
361
|
-
- roadmap-kit/docs/TECHNICAL_DEBT_GUIDE.md
|
|
362
|
-
|
|
363
|
-
Then help me create/improve the roadmap.json for my project following that format.`),className:"px-3 py-1.5 border border-matrix/30 text-matrix font-mono text-[10px] hover:bg-matrix/10 transition-all",children:l!=null&&l.includes("Read the files")?e("common.copied").toUpperCase():e("help.copyPrompt")})]}),n.jsxs("div",{className:"bg-void-100 border border-white/5 p-3 font-mono text-[11px] text-gray-500",children:[n.jsx("p",{children:"Read the files:"}),n.jsx("p",{className:"text-cyber",children:"- roadmap-kit/templates/clinerules.template"}),n.jsx("p",{className:"text-matrix",children:"- roadmap-kit/examples/roadmap-ecommerce.json"}),n.jsx("p",{className:"text-alert",children:"- roadmap-kit/docs/TECHNICAL_DEBT_GUIDE.md"}),n.jsx("p",{className:"mt-2",children:"Then help me create/improve the roadmap.json..."})]})]})]}),r==="commits"&&n.jsxs("div",{className:"space-y-6",children:[n.jsxs("div",{className:"terminal-card p-5",children:[n.jsx("h3",{className:"font-mono text-sm text-matrix tracking-wider mb-4",children:e("help.commitFormat")}),n.jsx("p",{className:"font-mono text-[11px] text-gray-500 mb-4",children:e("help.commitFormatDesc")}),n.jsx("div",{className:"bg-void-100 border border-white/5 p-4 mb-6",children:n.jsx("code",{className:"font-mono text-sm text-cyber",children:'git commit -m "[task:ID] [status:STATUS] Description"'})}),n.jsx("h4",{className:"font-mono text-xs text-gray-400 mb-3",children:e("help.availableTags")}),n.jsx("div",{className:"overflow-x-auto",children:n.jsxs("table",{className:"w-full font-mono text-[11px]",children:[n.jsx("thead",{children:n.jsxs("tr",{className:"border-b border-white/10",children:[n.jsx("th",{className:"text-left py-2 text-gray-500",children:e("help.tag")}),n.jsx("th",{className:"text-left py-2 text-gray-500",children:e("help.values")}),n.jsx("th",{className:"text-left py-2 text-gray-500",children:e("help.example")})]})}),n.jsxs("tbody",{className:"text-gray-400",children:[n.jsxs("tr",{className:"border-b border-white/5",children:[n.jsx("td",{className:"py-2",children:n.jsx("code",{className:"text-cyber",children:"[task:id]"})}),n.jsx("td",{className:"py-2",children:"Task ID"}),n.jsx("td",{className:"py-2",children:n.jsx("code",{className:"text-matrix",children:"[task:auth-login]"})})]}),n.jsxs("tr",{className:"border-b border-white/5",children:[n.jsx("td",{className:"py-2",children:n.jsx("code",{className:"text-cyber",children:"[status:x]"})}),n.jsx("td",{className:"py-2",children:"pending, in_progress, completed"}),n.jsx("td",{className:"py-2",children:n.jsx("code",{className:"text-matrix",children:"[status:completed]"})})]}),n.jsxs("tr",{children:[n.jsx("td",{className:"py-2",children:n.jsx("code",{className:"text-cyber",children:"[debt:...]"})}),n.jsx("td",{className:"py-2",children:"desc|severity|effort"}),n.jsx("td",{className:"py-2",children:n.jsx("code",{className:"text-matrix",children:"[debt:No validation|high|1h]"})})]})]})]})})]}),n.jsxs("div",{className:"terminal-card p-5",children:[n.jsx("h4",{className:"font-mono text-xs text-gray-400 mb-4",children:e("help.examples")}),n.jsx("div",{className:"space-y-3",children:[{comment:e("help.completeTask"),cmd:'git commit -m "[task:auth-login] [status:completed] Implement JWT login"'},{comment:e("help.taskInProgress"),cmd:'git commit -m "[task:user-list] [status:in_progress] Add basic listing"'},{comment:e("help.withDebt"),cmd:'git commit -m "[task:api-users] [status:completed] [debt:No tests|medium|2h] CRUD users"'}].map((c,d)=>n.jsxs("div",{className:"bg-void-100 border border-white/5 p-3",children:[n.jsx("p",{className:"font-mono text-[10px] text-gray-600 mb-1",children:c.comment}),n.jsx("code",{className:"font-mono text-[11px] text-cyber",children:c.cmd})]},d))})]}),n.jsxs("div",{className:"terminal-card p-5 border-cyber/20",children:[n.jsx("h4",{className:"font-mono text-sm text-cyber tracking-wider mb-3",children:e("help.syncWithGit")}),n.jsx("p",{className:"font-mono text-[11px] text-gray-500 mb-3",children:e("help.afterCommits")}),n.jsx("div",{className:"bg-void-100 border border-white/5 p-3",children:n.jsx("code",{className:"font-mono text-sm text-matrix",children:"node roadmap-kit/scanner.js"})}),n.jsx("p",{className:"font-mono text-[10px] text-gray-600 mt-3",children:e("help.updatesInfo")})]})]}),r==="ai"&&n.jsxs("div",{className:"space-y-6",children:[n.jsxs("div",{className:"terminal-card p-5",children:[n.jsx("h3",{className:"font-mono text-sm text-matrix tracking-wider mb-4",children:e("help.recommendedWorkflow")}),n.jsx("div",{className:"space-y-2",children:[{step:"01",text:e("help.step01")},{step:"02",text:e("help.step02")},{step:"03",text:e("help.step03")}].map(c=>n.jsxs("div",{className:"flex items-center gap-3 p-3 bg-void-100 border border-white/5",children:[n.jsx("span",{className:"font-display text-lg text-matrix",children:c.step}),n.jsx("span",{className:"font-mono text-xs text-gray-400",children:c.text})]},c.step))})]}),n.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-4",children:[n.jsxs("div",{className:"terminal-card p-5 border-matrix/20",children:[n.jsxs("h4",{className:"font-mono text-xs text-matrix tracking-wider mb-4 flex items-center gap-2",children:[n.jsx(Ie,{className:"w-4 h-4"})," ",e("help.aiMustDo")]}),n.jsx("ul",{className:"space-y-2 font-mono text-[11px] text-gray-400",children:e("help.mustDoList").map((c,d)=>n.jsxs("li",{className:"flex items-start gap-2",children:[n.jsx("span",{className:"text-matrix",children:"✓"}),c]},d))})]}),n.jsxs("div",{className:"terminal-card p-5 border-alert/20",children:[n.jsxs("h4",{className:"font-mono text-xs text-alert tracking-wider mb-4 flex items-center gap-2",children:[n.jsx(ft,{className:"w-4 h-4"})," ",e("help.aiMustNot")]}),n.jsx("ul",{className:"space-y-2 font-mono text-[11px] text-gray-400",children:e("help.mustNotList").map((c,d)=>n.jsxs("li",{className:"flex items-start gap-2",children:[n.jsx("span",{className:"text-alert",children:"✗"}),c]},d))})]})]})]}),r==="troubleshooting"&&n.jsxs("div",{className:"space-y-4",children:[n.jsxs("div",{className:"terminal-card p-5",children:[n.jsx("h3",{className:"font-mono text-sm text-signal tracking-wider mb-4",children:e("help.troubleshooting")}),n.jsx("div",{className:"space-y-4",children:[{title:'"Cannot load roadmap.json"',solutions:["Verify roadmap-kit/roadmap.json exists","Check server is running on correct port","Restart: npm run dev"]},{title:"Changes not saving",solutions:['Click "SAVE" in sidebar',"Check server has write permissions","Check browser console for errors"]},{title:"Deploy not working",solutions:["Check project path in Settings",'Use "Download" and copy manually',"Verify write permissions"]},{title:"AI not following rules",solutions:["Verify .clinerules in project root","Regenerate from Settings","Restart AI session"]},{title:"Port in use error",solutions:["Run: lsof -ti:3001 | xargs kill -9"]}].map((c,d)=>n.jsxs("div",{className:"bg-void-100 border border-white/5 p-4",children:[n.jsx("h4",{className:"font-mono text-xs text-white mb-2",children:c.title}),n.jsx("ul",{className:"font-mono text-[11px] text-gray-500 space-y-1",children:c.solutions.map((f,g)=>n.jsxs("li",{children:["• ",f]},g))})]},d))})]}),n.jsxs("div",{className:"terminal-card p-5",children:[n.jsx("h4",{className:"font-mono text-xs text-gray-400 mb-4",children:e("help.fileSummary")}),n.jsx("div",{className:"overflow-x-auto",children:n.jsxs("table",{className:"w-full font-mono text-[11px]",children:[n.jsx("thead",{children:n.jsxs("tr",{className:"border-b border-white/10",children:[n.jsx("th",{className:"text-left py-2 text-gray-500",children:e("help.file")}),n.jsx("th",{className:"text-left py-2 text-gray-500",children:e("help.location")}),n.jsx("th",{className:"text-left py-2 text-gray-500",children:e("help.purposeCol")})]})}),n.jsxs("tbody",{className:"text-gray-400",children:[n.jsxs("tr",{className:"border-b border-white/5",children:[n.jsx("td",{className:"py-2",children:n.jsx("code",{className:"text-cyber",children:"roadmap.json"})}),n.jsx("td",{className:"py-2",children:"roadmap-kit/"}),n.jsx("td",{className:"py-2",children:"Project state"})]}),n.jsxs("tr",{className:"border-b border-white/5",children:[n.jsx("td",{className:"py-2",children:n.jsx("code",{className:"text-cyber",children:".clinerules"})}),n.jsx("td",{className:"py-2",children:"Project root"}),n.jsx("td",{className:"py-2",children:"AI rules"})]}),n.jsxs("tr",{className:"border-b border-white/5",children:[n.jsx("td",{className:"py-2",children:n.jsx("code",{className:"text-cyber",children:".cursorrules"})}),n.jsx("td",{className:"py-2",children:"Project root"}),n.jsx("td",{className:"py-2",children:"Cursor rules"})]}),n.jsxs("tr",{children:[n.jsx("td",{className:"py-2",children:n.jsx("code",{className:"text-cyber",children:".env"})}),n.jsx("td",{className:"py-2",children:"roadmap-kit/"}),n.jsx("td",{className:"py-2",children:"Auth credentials"})]})]})]})})]})]})]})}function Jf({roadmap:e,setRoadmap:t,setHasChanges:r,loadRoadmap:s,t:l,language:a}){var Z,G,gt,$e,J,me,Te,Ot,hr,Dr,Bt,ee,Le,xn,hn,he,at,gr;const[i,o]=v.useState(""),[c,d]=v.useState({hasKey:!1,maskedKey:null}),[f,g]=v.useState({available:!1,version:null,checking:!0}),[h,x]=v.useState("claude-code"),[N,E]=v.useState(""),[b,m]=v.useState(!1),[u,p]=v.useState(null),[j,S]=v.useState(null),[R,y]=v.useState(1),[T,P]=v.useState(null),[C,L]=v.useState(!1),[D,_]=v.useState(!1),Y=((Z=e==null?void 0:e.features)==null?void 0:Z.length)>0&&e.features.some(A=>{var z;return((z=A.tasks)==null?void 0:z.length)>0}),F=v.useMemo(()=>{var Wt,Dt,Kt,Yt,Pr,Pt,kt;const A=a==="es";if(!e)return{valid:!1,issues:[A?"No se encontró roadmap":"No roadmap found"],score:0};const z=[],ae=[];let pe=0;const qe=100;if(!e.project_info)z.push(A?"Falta la sección project_info":"Missing project_info section");else{const ie=e.project_info;if(ie.name?pe+=10:z.push(A?"El nombre del proyecto es requerido":"Project name is required"),ie.description?pe+=5:ae.push(A?"Se recomienda añadir descripción del proyecto":"Project description is recommended"),!ie.stack||ie.stack.length===0?ae.push(A?"Stack tecnológico no definido":"Tech stack not defined"):pe+=10,ie.architecture?pe+=5:ae.push(A?"Arquitectura no documentada":"Architecture not documented"),!ie.conventions||Object.keys(ie.conventions).length===0?ae.push(A?"Convenciones de código no definidas":"Coding conventions not defined"):pe+=10,!ie.shared_resources)ae.push(A?"Falta sección de recursos compartidos":"Shared resources section missing");else{const oe=ie.shared_resources;!oe.ui_components||oe.ui_components.length===0?ae.push(A?"Sin componentes UI documentados":"No UI components documented"):pe+=5,!oe.utilities||oe.utilities.length===0?ae.push(A?"Sin utilidades documentadas":"No utilities documented"):pe+=5,!oe.database_tables||oe.database_tables.length===0?ae.push(A?"Sin tablas de BD documentadas":"No database tables documented"):pe+=5}((Wt=ie.stack)==null?void 0:Wt.some(oe=>["postgresql","mysql","mongodb","sqlite","prisma","supabase","firebase"].some(it=>oe.toLowerCase().includes(it))))&&(!((Dt=ie.shared_resources)!=null&&Dt.database_tables)||ie.shared_resources.database_tables.length===0)&&z.push(A?"El proyecto usa BD pero no tiene tablas documentadas":"Project uses database but no tables are documented")}if(!e.features||e.features.length===0)z.push(A?"No hay features definidas":"No features defined");else{pe+=15;const ie=e.features.filter(oe=>!oe.name||!oe.description);ie.length>0&&ae.push(A?`${ie.length} feature(s) sin nombre o descripción`:`${ie.length} feature(s) missing name or description`);const se=e.features.reduce((oe,it)=>{var yt;return oe+(((yt=it.tasks)==null?void 0:yt.length)||0)},0);if(se===0)z.push(A?"No hay tareas definidas en ninguna feature":"No tasks defined in any feature");else{pe+=20;const oe=e.features.flatMap(yt=>(yt.tasks||[]).filter(Xe=>!Xe.name||!Xe.description));oe.length>0&&ae.push(A?`${oe.length} tarea(s) sin nombre o descripción`:`${oe.length} task(s) missing name or description`),e.features.flatMap(yt=>(yt.tasks||[]).filter(Xe=>Xe.affected_files&&Xe.affected_files.length>0)).length>se*.5?pe+=10:ae.push(A?"La mayoría de tareas no tienen affected_files":"Most tasks are missing affected_files")}}return{valid:z.length===0,issues:z,warnings:ae,score:Math.min(pe,qe),hasProject:!!((Kt=e.project_info)!=null&&Kt.name),hasFeatures:(((Yt=e.features)==null?void 0:Yt.length)||0)>0,hasTasks:(Pr=e.features)==null?void 0:Pr.some(ie=>{var se;return((se=ie.tasks)==null?void 0:se.length)>0}),totalFeatures:((Pt=e.features)==null?void 0:Pt.length)||0,totalTasks:((kt=e.features)==null?void 0:kt.reduce((ie,se)=>{var oe;return ie+(((oe=se.tasks)==null?void 0:oe.length)||0)},0))||0}},[e,a]);v.useEffect(()=>{fetch("/api/api-key-status").then(A=>A.json()).then(A=>d(A)).catch(()=>{}),fetch("/api/claude-code-status").then(A=>A.json()).then(A=>{g({...A,checking:!1}),A.available&&(x("claude-code"),y(2))}).catch(()=>g({available:!1,checking:!1})),Ne()},[]);const Ne=async()=>{L(!0);try{const A=await fetch("/api/scan-project");if(A.ok){const z=await A.json();P(z)}}catch(A){console.error("Scan error:",A)}L(!1)},xe=async()=>{if(i.trim())try{if((await fetch("/api/save-api-key",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({apiKey:i})})).ok)d({hasKey:!0,maskedKey:`${i.substring(0,10)}...${i.substring(i.length-4)}`}),o(""),y(2);else throw new Error("Error saving API key")}catch(A){S(A.message)}},k=async()=>{if(!N.trim()){S(a==="es"?"Por favor describe los requerimientos o características que quieres implementar":"Please describe the requirements or features you want to implement");return}m(!0),S(null);try{const A=await fetch("/api/analyze-project",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({requirements:N,projectScan:T,existingRoadmap:e,useClaudeCode:h==="claude-code"})}),z=await A.json();if(!A.ok)throw new Error(z.error||"Error analyzing project");p(z),y(3)}catch(A){S(A.message)}finally{m(!1)}},V=async()=>{if(u)try{t(u.roadmap),r(!0),await fetch("/api/deploy",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({clinerules:u.clinerules,roadmap:u.roadmap})}),y(4)}catch(A){S(A.message)}};return F.valid&&F.score>=60&&R!==2&&!u?n.jsxs("div",{className:"space-y-6 animate-fade-in",children:[n.jsxs("div",{className:"terminal-card p-8 border-matrix/50 text-center",children:[n.jsx("div",{className:"w-20 h-20 mx-auto border-2 border-matrix/50 flex items-center justify-center mb-6 glow-matrix",children:n.jsx(Ie,{className:"w-10 h-10 text-matrix"})}),n.jsx("h2",{className:"font-display text-2xl text-matrix tracking-wider mb-2",children:l?l("setup.setupComplete"):"SETUP COMPLETE"}),n.jsx("p",{className:"font-mono text-xs text-gray-500",children:l?l("setup.setupCompleteDesc"):"Your roadmap is configured and ready to use"})]}),n.jsxs("div",{className:"terminal-card p-5",children:[n.jsx("h3",{className:"font-mono text-sm text-white tracking-wider mb-4",children:l?l("setup.roadmapStatus"):"ROADMAP STATUS"}),n.jsxs("div",{className:"grid grid-cols-2 md:grid-cols-4 gap-4 mb-6",children:[n.jsxs("div",{className:"p-4 bg-void-100 border border-matrix/20",children:[n.jsx("div",{className:"font-mono text-[9px] text-gray-600",children:l?l("stats.total").toUpperCase():"FEATURES"}),n.jsx("div",{className:"font-display text-2xl text-matrix",children:F.totalFeatures})]}),n.jsxs("div",{className:"p-4 bg-void-100 border border-cyber/20",children:[n.jsx("div",{className:"font-mono text-[9px] text-gray-600",children:"TASKS"}),n.jsx("div",{className:"font-display text-2xl text-cyber",children:F.totalTasks})]}),n.jsxs("div",{className:"p-4 bg-void-100 border border-signal/20",children:[n.jsx("div",{className:"font-mono text-[9px] text-gray-600",children:a==="es"?"PROGRESO":"PROGRESS"}),n.jsxs("div",{className:"font-display text-2xl text-signal",children:[((G=e==null?void 0:e.project_info)==null?void 0:G.total_progress)||0,"%"]})]}),n.jsxs("div",{className:"p-4 bg-void-100 border border-white/10",children:[n.jsx("div",{className:"font-mono text-[9px] text-gray-600",children:a==="es"?"PUNTUACIÓN":"SCORE"}),n.jsxs("div",{className:"font-display text-2xl text-white",children:[F.score,"%"]})]})]}),F.warnings.length>0&&n.jsxs("details",{className:"mb-4 p-3 bg-signal/5 border border-signal/20",children:[n.jsxs("summary",{className:"font-mono text-[10px] text-signal cursor-pointer",children:[F.warnings.length," ",l?l("setup.warnings").toLowerCase():"warnings"," (",a==="es"?"click para ver":"click to view",")"]}),n.jsx("ul",{className:"mt-2 space-y-1",children:F.warnings.map((A,z)=>n.jsxs("li",{className:"font-mono text-[10px] text-signal/70 flex items-start gap-2",children:[n.jsx(Oe,{className:"w-3 h-3 mt-0.5 flex-shrink-0"}),A]},z))})]}),n.jsxs("div",{className:"flex gap-3",children:[n.jsxs("button",{onClick:()=>window.location.hash="#features",className:"btn-terminal flex-1 py-3 flex items-center justify-center gap-2",children:[n.jsx(Zi,{className:"w-4 h-4"}),l?l("setup.goToDashboard"):"GO TO DASHBOARD"]}),n.jsx("button",{onClick:()=>y(2),className:"px-6 py-3 border border-white/10 text-gray-500 font-mono text-xs hover:text-white hover:border-white/30 transition-all",children:l?l("setup.reconfigure"):"RECONFIGURE"})]})]}),(e==null?void 0:e.project_info)&&n.jsxs("div",{className:"terminal-card p-5",children:[n.jsxs("h3",{className:"font-mono text-sm text-cyber tracking-wider mb-4",children:["# ",e.project_info.name||"PROJECT"]}),e.project_info.description&&n.jsx("p",{className:"font-mono text-xs text-gray-400 mb-4",children:e.project_info.description}),((gt=e.project_info.stack)==null?void 0:gt.length)>0&&n.jsx("div",{className:"flex flex-wrap gap-2",children:e.project_info.stack.map((A,z)=>n.jsx("span",{className:"font-mono text-[10px] px-2 py-1 bg-matrix/10 text-matrix border border-matrix/30",children:A},z))})]})]}):n.jsxs("div",{className:"space-y-6 animate-fade-in",children:[n.jsx("div",{className:"terminal-card p-5 border-matrix/30",children:n.jsxs("div",{className:"flex items-center gap-4",children:[n.jsx("div",{className:"w-14 h-14 border border-matrix/50 flex items-center justify-center glow-matrix",children:n.jsx(as,{className:"w-7 h-7 text-matrix"})}),n.jsxs("div",{children:[n.jsx("h2",{className:"font-display text-xl text-matrix tracking-wider",children:l?l("setup.title"):"AI SETUP WIZARD"}),n.jsx("p",{className:"font-mono text-xs text-gray-500 mt-1",children:l?l("setup.subtitle"):"Describe your project and Claude will generate the configuration"})]})]})}),n.jsx("div",{className:"flex items-center gap-2",children:[{num:1,label:l?l("setup.stepConnect"):"CONNECT"},{num:2,label:l?l("setup.stepDescribe"):"DESCRIBE"},{num:3,label:l?l("setup.stepReview"):"REVIEW"},{num:4,label:l?l("setup.stepDone"):"DONE"}].map((A,z)=>n.jsxs(oi.Fragment,{children:[n.jsxs("button",{onClick:()=>A.num<=R&&y(A.num),className:`flex items-center gap-2 px-4 py-2 border transition-all ${R===A.num?"border-matrix text-matrix bg-matrix/10":R>A.num?"border-matrix/30 text-matrix/60":"border-white/10 text-gray-600"}`,children:[n.jsx("span",{className:"font-display text-lg",children:A.num}),n.jsx("span",{className:"font-mono text-[10px] tracking-wider hidden sm:block",children:A.label})]}),z<3&&n.jsx("div",{className:`flex-1 h-px ${R>A.num?"bg-matrix/50":"bg-white/10"}`})]},A.num))}),j&&n.jsxs("div",{className:"p-4 border border-alert/30 bg-alert/5 text-alert font-mono text-xs flex items-center gap-2",children:[n.jsx(Oe,{className:"w-4 h-4"}),j,n.jsx("button",{onClick:()=>S(null),className:"ml-auto text-gray-500 hover:text-white",children:n.jsx(ft,{className:"w-4 h-4"})})]}),R===1&&n.jsxs("div",{className:"space-y-4",children:[n.jsxs("div",{className:"terminal-card p-6",children:[n.jsxs("h3",{className:"font-mono text-sm text-matrix tracking-wider mb-4",children:["# ",l?l("setup.chooseConnection"):"CHOOSE CONNECTION MODE"]}),n.jsx("p",{className:"font-mono text-xs text-gray-500 mb-6",children:l?l("setup.chooseConnectionDesc"):"Choose how to connect with Claude to generate your project configuration."}),n.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-4",children:[n.jsxs("button",{onClick:()=>{x("claude-code"),f.available&&y(2)},className:`p-5 border text-left transition-all ${h==="claude-code"?"border-matrix bg-matrix/10":"border-white/10 hover:border-white/30"}`,children:[n.jsxs("div",{className:"flex items-center gap-3 mb-3",children:[n.jsx("div",{className:`led ${f.available?"led-green":f.checking?"led-amber":"led-red"}`}),n.jsx("span",{className:"font-mono text-sm text-white",children:"CLAUDE CODE"}),n.jsx("span",{className:"font-mono text-[9px] px-2 py-0.5 bg-matrix/20 text-matrix border border-matrix/30",children:l?l("setup.recommended"):"RECOMMENDED"})]}),n.jsx("p",{className:"font-mono text-[11px] text-gray-500 mb-3",children:a==="es"?"Usa tu suscripción de Claude (Max/Pro) a través de Claude Code CLI. Sin coste adicional.":"Use your Claude subscription (Max/Pro) via Claude Code CLI. No additional cost."}),f.checking?n.jsxs("div",{className:"flex items-center gap-2 font-mono text-[10px] text-signal",children:[n.jsx(et,{className:"w-3 h-3 animate-spin"}),a==="es"?"Verificando Claude Code...":"Verifying Claude Code..."]}):f.available?n.jsxs("div",{className:"flex items-center gap-2 font-mono text-[10px] text-matrix",children:[n.jsx(Ie,{className:"w-3 h-3"}),"Claude Code ",l?l("setup.available").toLowerCase():"available"," ",f.version&&`(${f.version})`]}):n.jsxs("div",{className:"flex items-center gap-2 font-mono text-[10px] text-alert",children:[n.jsx(Oe,{className:"w-3 h-3"}),"Claude Code ",l?l("setup.notAvailable").toLowerCase():"not detected"]})]}),n.jsxs("button",{onClick:()=>x("api"),className:`p-5 border text-left transition-all ${h==="api"?"border-cyber bg-cyber/10":"border-white/10 hover:border-white/30"}`,children:[n.jsxs("div",{className:"flex items-center gap-3 mb-3",children:[n.jsx("div",{className:`led ${c.hasKey?"led-green":"led-gray"}`}),n.jsx("span",{className:"font-mono text-sm text-white",children:"API KEY"})]}),n.jsx("p",{className:"font-mono text-[11px] text-gray-500 mb-3",children:"Usa una API key de Anthropic. Pago por uso (~$0.05-0.15 por generación)."}),c.hasKey?n.jsxs("div",{className:"flex items-center gap-2 font-mono text-[10px] text-matrix",children:[n.jsx(Ie,{className:"w-3 h-3"}),"API Key configurada"]}):n.jsxs("div",{className:"flex items-center gap-2 font-mono text-[10px] text-gray-500",children:[n.jsx(Za,{className:"w-3 h-3"}),"Sin API Key configurada"]})]})]})]}),h==="claude-code"&&!f.checking&&!f.available&&n.jsxs("div",{className:"terminal-card p-5 border-signal/30",children:[n.jsx("h4",{className:"font-mono text-xs text-signal tracking-wider mb-3",children:"INSTALAR CLAUDE CODE"}),n.jsx("p",{className:"font-mono text-[11px] text-gray-500 mb-4",children:"Para usar tu suscripción, necesitas tener Claude Code instalado y autenticado."}),n.jsxs("div",{className:"space-y-2 font-mono text-[11px]",children:[n.jsx("div",{className:"p-2 bg-black/50 border border-white/10",children:n.jsx("code",{className:"text-cyber",children:"npm install -g @anthropic-ai/claude-code"})}),n.jsx("div",{className:"p-2 bg-black/50 border border-white/10",children:n.jsx("code",{className:"text-cyber",children:"claude auth login"})})]}),n.jsx("button",{onClick:()=>fetch("/api/claude-code-status").then(A=>A.json()).then(A=>g({...A,checking:!1})),className:"mt-4 px-4 py-2 border border-signal/30 text-signal font-mono text-[10px] hover:bg-signal/10 transition-all",children:"VERIFICAR DE NUEVO"})]}),h==="api"&&n.jsxs("div",{className:"terminal-card p-5",children:[n.jsx("h4",{className:"font-mono text-xs text-cyber tracking-wider mb-3",children:"CONFIGURAR API KEY"}),n.jsxs("p",{className:"font-mono text-[11px] text-gray-500 mb-4",children:["Obtén una API key en"," ",n.jsx("a",{href:"https://platform.claude.com",target:"_blank",rel:"noopener noreferrer",className:"text-cyber hover:underline",children:"platform.claude.com"})]}),c.hasKey?n.jsxs("div",{className:"space-y-3",children:[n.jsxs("div",{className:"p-3 border border-matrix/30 bg-matrix/5 font-mono text-xs",children:[n.jsx("span",{className:"text-gray-500",children:"CURRENT KEY:"})," ",n.jsx("span",{className:"text-matrix",children:c.maskedKey})]}),n.jsxs("div",{className:"flex gap-3",children:[n.jsx("button",{onClick:()=>y(2),className:"btn-terminal flex-1",children:"CONTINUE →"}),n.jsx("button",{onClick:()=>d({hasKey:!1,maskedKey:null}),className:"px-4 py-2 border border-white/10 text-gray-500 font-mono text-xs hover:text-white transition-all",children:"CHANGE"})]})]}):n.jsxs("div",{className:"space-y-3",children:[n.jsx("input",{type:"password",placeholder:"sk-ant-api03-...",value:i,onChange:A=>o(A.target.value),className:"input-terminal w-full px-4 py-3 text-sm"}),n.jsx("button",{onClick:xe,disabled:!i.trim(),className:"btn-terminal w-full py-3 disabled:opacity-50",children:"SAVE API KEY"})]})]}),h==="claude-code"&&f.available&&n.jsx("button",{onClick:()=>y(2),className:"btn-terminal w-full py-4",children:"CONTINUE WITH CLAUDE CODE →"})]}),R===2&&n.jsxs("div",{className:"space-y-4",children:[Y&&n.jsx("div",{className:`terminal-card p-5 ${F.valid?"border-matrix/50":F.issues.length>0?"border-alert/30":"border-signal/30"}`,children:n.jsxs("div",{className:"flex items-start gap-4",children:[n.jsx("div",{className:`w-12 h-12 border flex items-center justify-center ${F.valid?"border-matrix/50 bg-matrix/10":F.issues.length>0?"border-alert/50 bg-alert/10":"border-signal/50 bg-signal/10"}`,children:F.valid?n.jsx(Ie,{className:"w-6 h-6 text-matrix"}):F.issues.length>0?n.jsx(Oe,{className:"w-6 h-6 text-alert"}):n.jsx(ss,{className:"w-6 h-6 text-signal"})}),n.jsxs("div",{className:"flex-1",children:[n.jsxs("div",{className:"flex items-center gap-3 mb-2",children:[n.jsx("h4",{className:`font-mono text-sm ${F.valid?"text-matrix":F.issues.length>0?"text-alert":"text-signal"}`,children:F.valid?"ROADMAP COMPLETE":F.issues.length>0?"ROADMAP INCOMPLETE":"ROADMAP NEEDS REVIEW"}),n.jsxs("div",{className:"flex items-center gap-2",children:[n.jsx("div",{className:"w-20 h-2 bg-void-200 overflow-hidden",children:n.jsx("div",{className:`h-full transition-all ${F.score>=80?"bg-matrix":F.score>=50?"bg-signal":"bg-alert"}`,style:{width:`${F.score}%`}})}),n.jsxs("span",{className:"font-mono text-[10px] text-gray-500",children:[F.score,"%"]})]})]}),n.jsxs("p",{className:"font-mono text-[10px] text-gray-500 mb-3",children:[F.totalFeatures," features • ",F.totalTasks," tasks • ",(($e=e.project_info)==null?void 0:$e.total_progress)||0,"% progress"]}),F.issues.length>0&&n.jsxs("div",{className:"mb-3",children:[n.jsx("div",{className:"font-mono text-[9px] text-alert tracking-wider mb-1",children:"ISSUES TO FIX:"}),n.jsx("ul",{className:"space-y-1",children:F.issues.map((A,z)=>n.jsxs("li",{className:"font-mono text-[10px] text-alert/80 flex items-start gap-2",children:[n.jsx(ft,{className:"w-3 h-3 mt-0.5 flex-shrink-0"}),A]},z))})]}),F.warnings.length>0&&n.jsxs("details",{className:"mb-3",children:[n.jsxs("summary",{className:"font-mono text-[9px] text-signal tracking-wider cursor-pointer hover:text-signal/80",children:[F.warnings.length," WARNINGS (click to expand)"]}),n.jsx("ul",{className:"mt-2 space-y-1",children:F.warnings.map((A,z)=>n.jsxs("li",{className:"font-mono text-[10px] text-signal/70 flex items-start gap-2",children:[n.jsx(Oe,{className:"w-3 h-3 mt-0.5 flex-shrink-0"}),A]},z))})]}),F.valid?n.jsxs("div",{className:"flex gap-3",children:[n.jsxs("button",{onClick:()=>y(4),className:"btn-terminal px-6 py-2 flex items-center gap-2",children:[n.jsx(Ie,{className:"w-4 h-4"}),"CONTINUE TO DASHBOARD"]}),n.jsx("button",{onClick:()=>{},className:"px-4 py-2 border border-white/10 text-gray-500 font-mono text-xs hover:text-white transition-all",children:"REGENERATE ANYWAY"})]}):n.jsxs("div",{className:"flex gap-3",children:[n.jsxs("button",{onClick:()=>{const A=`Fix the following issues in my roadmap:
|
|
364
|
-
${F.issues.map(z=>`- ${z}`).join(`
|
|
365
|
-
`)}${F.warnings.length>0?`
|
|
366
|
-
|
|
367
|
-
Also consider these improvements:
|
|
368
|
-
${F.warnings.slice(0,5).map(z=>`- ${z}`).join(`
|
|
369
|
-
`)}`:""}`;E(A)},className:"px-4 py-2 border border-signal/30 text-signal font-mono text-xs hover:bg-signal/10 transition-all flex items-center gap-2",children:[n.jsx(ml,{className:"w-4 h-4"}),"AI FIX ISSUES"]}),F.issues.length<=2&&n.jsx("button",{onClick:()=>y(4),className:"px-4 py-2 border border-white/10 text-gray-500 font-mono text-xs hover:text-white transition-all",children:"SKIP ANYWAY →"})]})]})]})}),n.jsxs("div",{className:"terminal-card",children:[n.jsxs("button",{onClick:()=>_(!D),className:"w-full p-4 flex items-center justify-between hover:bg-white/[0.01] transition-colors",children:[n.jsxs("div",{className:"flex items-center gap-3",children:[n.jsx(Nf,{className:"w-4 h-4 text-cyber"}),n.jsxs("div",{className:"text-left",children:[n.jsx("h3",{className:"font-mono text-sm text-white",children:"PROJECT ANALYSIS"}),n.jsx("p",{className:"font-mono text-[10px] text-gray-600",children:C?"Scanning...":T?`${T.totalFiles} files • ${((J=T.techStack)==null?void 0:J.join(", "))||"Unknown stack"}`:"Not scanned"})]})]}),n.jsxs("div",{className:"flex items-center gap-2",children:[n.jsx("button",{onClick:A=>{A.stopPropagation(),Ne()},className:"p-1.5 text-gray-600 hover:text-matrix transition-all",title:"Re-scan project",children:n.jsx(pl,{className:`w-4 h-4 ${C?"animate-spin":""}`})}),n.jsx(ns,{className:`w-4 h-4 text-gray-600 transition-transform ${D?"rotate-180":""}`})]})]}),D&&T&&n.jsxs("div",{className:"px-4 pb-4 border-t border-white/5",children:[n.jsxs("div",{className:"grid grid-cols-2 sm:grid-cols-4 gap-3 py-4",children:[n.jsxs("div",{className:"p-3 bg-void-100 border border-white/5",children:[n.jsx("div",{className:"font-mono text-[9px] text-gray-600",children:"FILES"}),n.jsx("div",{className:"font-display text-lg text-matrix",children:T.totalFiles})]}),n.jsxs("div",{className:"p-3 bg-void-100 border border-white/5",children:[n.jsx("div",{className:"font-mono text-[9px] text-gray-600",children:"SIZE"}),n.jsxs("div",{className:"font-display text-lg text-cyber",children:[(T.totalSize/1024).toFixed(0)," KB"]})]}),n.jsxs("div",{className:"col-span-2 p-3 bg-void-100 border border-white/5",children:[n.jsx("div",{className:"font-mono text-[9px] text-gray-600 mb-1",children:"TECH STACK"}),n.jsx("div",{className:"flex flex-wrap gap-1",children:(me=T.techStack)==null?void 0:me.map((A,z)=>n.jsx("span",{className:"font-mono text-[10px] px-2 py-0.5 bg-matrix/20 text-matrix",children:A},z))})]})]}),((Te=T.keyFiles)==null?void 0:Te.length)>0&&n.jsxs("details",{className:"mt-2",children:[n.jsxs("summary",{className:"font-mono text-[10px] text-gray-500 cursor-pointer hover:text-white",children:["KEY FILES (",T.keyFiles.length,")"]}),n.jsx("div",{className:"mt-2 space-y-1 max-h-40 overflow-y-auto",children:T.keyFiles.map((A,z)=>n.jsx("div",{className:"p-2 bg-black/30 border border-white/5",children:n.jsx("code",{className:"font-mono text-[10px] text-cyber",children:A.path})},z))})]}),n.jsxs("details",{className:"mt-2",children:[n.jsxs("summary",{className:"font-mono text-[10px] text-gray-500 cursor-pointer hover:text-white",children:["ALL FILES (",((Ot=T.files)==null?void 0:Ot.length)||0,")"]}),n.jsx("div",{className:"mt-2 max-h-60 overflow-y-auto",children:n.jsxs("div",{className:"font-mono text-[10px] text-gray-600 space-y-0.5",children:[(hr=T.files)==null?void 0:hr.slice(0,100).map((A,z)=>n.jsx("div",{className:"truncate hover:text-white",children:A.path},z)),((Dr=T.files)==null?void 0:Dr.length)>100&&n.jsxs("div",{className:"text-gray-700",children:["... and ",T.files.length-100," more"]})]})})]})]})]}),n.jsxs("div",{className:"terminal-card p-6",children:[n.jsx("h3",{className:"font-mono text-sm text-matrix tracking-wider mb-2",children:"# REQUIREMENTS"}),n.jsx("p",{className:"font-mono text-[10px] text-gray-500 mb-4",children:"Describe las características, funcionalidades o mejoras que quieres implementar. Claude analizará tu proyecto y generará un roadmap estructurado."}),n.jsx("textarea",{placeholder:`Ejemplo:
|
|
370
|
-
- Sistema de autenticación con login/registro
|
|
371
|
-
- Dashboard de administración con estadísticas
|
|
372
|
-
- API REST para gestión de usuarios
|
|
373
|
-
- Notificaciones por email
|
|
374
|
-
- Integración con pasarela de pago
|
|
375
|
-
- Tests unitarios y e2e
|
|
376
|
-
...`,value:N,onChange:A=>E(A.target.value),rows:10,className:"input-terminal w-full px-4 py-3 text-sm resize-none mb-4"}),n.jsx("button",{onClick:k,disabled:b||!N.trim(),className:"btn-terminal w-full py-3 flex items-center justify-center gap-2 disabled:opacity-50",children:b?n.jsxs(n.Fragment,{children:[n.jsx(et,{className:"w-4 h-4 animate-spin"}),"ANALYZING PROJECT..."]}):n.jsxs(n.Fragment,{children:[n.jsx(ml,{className:"w-4 h-4"}),"ANALYZE & GENERATE ROADMAP"]})}),n.jsx("p",{className:"font-mono text-[9px] text-gray-700 mt-3 text-center",children:"Claude will analyze your project structure and create detailed tasks with affected files"})]})]}),R===3&&u&&n.jsxs("div",{className:"space-y-4",children:[u.analysis&&n.jsxs("div",{className:"terminal-card p-4 border-cyber/30",children:[n.jsxs("h4",{className:"font-mono text-xs text-cyber tracking-wider mb-3 flex items-center gap-2",children:[n.jsx(ss,{className:"w-4 h-4"})," ANALYSIS SUMMARY"]}),n.jsx("p",{className:"font-mono text-xs text-gray-400 mb-3",children:u.analysis.summary}),((Bt=u.analysis.suggestions)==null?void 0:Bt.length)>0&&n.jsxs("div",{className:"mb-3",children:[n.jsx("div",{className:"font-mono text-[9px] text-gray-600 mb-1",children:"SUGGESTIONS:"}),n.jsx("ul",{className:"space-y-1",children:u.analysis.suggestions.map((A,z)=>n.jsxs("li",{className:"font-mono text-[10px] text-gray-500 flex items-start gap-2",children:[n.jsx("span",{className:"text-cyber",children:"→"})," ",A]},z))})]}),((ee=u.analysis.warnings)==null?void 0:ee.length)>0&&n.jsxs("div",{className:"p-2 border border-signal/30 bg-signal/5",children:[n.jsx("div",{className:"font-mono text-[9px] text-signal mb-1",children:"WARNINGS:"}),n.jsx("ul",{className:"space-y-1",children:u.analysis.warnings.map((A,z)=>n.jsx("li",{className:"font-mono text-[10px] text-signal/80",children:A},z))})]})]}),n.jsxs("div",{className:"terminal-card p-6",children:[n.jsx("h3",{className:"font-mono text-sm text-matrix tracking-wider mb-4",children:"# GENERATED ROADMAP"}),n.jsxs("div",{className:"grid grid-cols-2 gap-4 mb-6",children:[n.jsxs("div",{className:"p-4 border border-matrix/20 bg-matrix/5",children:[n.jsx("div",{className:"font-mono text-[10px] text-gray-500 tracking-wider mb-1",children:"FEATURES"}),n.jsx("div",{className:"metric-display text-2xl text-matrix",children:((xn=(Le=u.roadmap)==null?void 0:Le.features)==null?void 0:xn.length)||0})]}),n.jsxs("div",{className:"p-4 border border-cyber/20 bg-cyber/5",children:[n.jsx("div",{className:"font-mono text-[10px] text-gray-500 tracking-wider mb-1",children:"TASKS"}),n.jsx("div",{className:"metric-display text-2xl text-cyber",children:((he=(hn=u.roadmap)==null?void 0:hn.features)==null?void 0:he.reduce((A,z)=>{var ae;return A+(((ae=z.tasks)==null?void 0:ae.length)||0)},0))||0})]})]}),n.jsxs("div",{className:"space-y-2 mb-6",children:[n.jsx("h4",{className:"font-mono text-[10px] text-gray-500 tracking-wider",children:"FEATURES PREVIEW:"}),(gr=(at=u.roadmap)==null?void 0:at.features)==null?void 0:gr.map(A=>{var z,ae,pe;return n.jsxs("details",{className:"bg-void-100 border border-white/5",children:[n.jsx("summary",{className:"p-3 cursor-pointer hover:bg-white/[0.02]",children:n.jsxs("div",{className:"flex items-center gap-2 inline",children:[n.jsx("span",{className:`font-mono text-[9px] px-2 py-0.5 ${A.priority==="high"?"bg-alert text-black":A.priority==="medium"?"bg-signal text-black":"bg-cyber text-black"}`,children:(z=A.priority)==null?void 0:z.toUpperCase()}),n.jsx("span",{className:"font-sans text-sm text-white",children:A.name}),n.jsxs("span",{className:"font-mono text-[10px] text-gray-600 ml-auto",children:[((ae=A.tasks)==null?void 0:ae.length)||0," tasks"]})]})}),n.jsxs("div",{className:"px-3 pb-3 border-t border-white/5 space-y-2",children:[n.jsx("p",{className:"font-mono text-[10px] text-gray-500 pt-2",children:A.description}),(pe=A.tasks)==null?void 0:pe.map((qe,Wt)=>{var Dt;return n.jsxs("div",{className:"p-2 bg-black/30 border border-white/5",children:[n.jsxs("div",{className:"flex items-center gap-2 mb-1",children:[n.jsx(Za,{className:"w-3 h-3 text-gray-600"}),n.jsx("span",{className:"font-mono text-[11px] text-white",children:qe.name})]}),((Dt=qe.affected_files)==null?void 0:Dt.length)>0&&n.jsxs("div",{className:"flex flex-wrap gap-1 mt-1",children:[qe.affected_files.slice(0,3).map((Kt,Yt)=>n.jsx("code",{className:"font-mono text-[9px] px-1 py-0.5 bg-black/50 text-cyber",children:Kt},Yt)),qe.affected_files.length>3&&n.jsxs("span",{className:"font-mono text-[9px] text-gray-600",children:["+",qe.affected_files.length-3]})]})]},Wt)})]})]},A.id)})]}),n.jsxs("div",{className:"flex gap-3",children:[n.jsx("button",{onClick:()=>y(2),className:"px-4 py-2 border border-white/10 text-gray-500 font-mono text-xs hover:text-white transition-all",children:"← BACK"}),n.jsx("button",{onClick:V,className:"btn-terminal flex-1 py-3",children:"APPLY & DEPLOY"})]})]}),n.jsx("div",{className:"terminal-card p-4",children:n.jsxs("details",{children:[n.jsx("summary",{className:"font-mono text-xs text-gray-500 cursor-pointer hover:text-white",children:"VIEW GENERATED JSON"}),n.jsx("pre",{className:"mt-4 p-4 bg-void-100 border border-white/5 font-mono text-[10px] text-gray-400 max-h-64 overflow-auto",children:JSON.stringify(u.roadmap,null,2)})]})})]}),R===4&&n.jsxs("div",{className:"terminal-card p-8 text-center",children:[n.jsx("div",{className:"w-20 h-20 mx-auto mb-6 border-2 border-matrix flex items-center justify-center glow-matrix",children:n.jsx(Ie,{className:"w-10 h-10 text-matrix"})}),n.jsx("h3",{className:"font-display text-2xl text-matrix tracking-wider mb-3",children:"SETUP COMPLETE"}),n.jsx("p",{className:"font-mono text-xs text-gray-500 mb-6",children:"Tu roadmap.json y .clinerules han sido generados y guardados."}),n.jsxs("div",{className:"flex gap-3 justify-center",children:[n.jsx("button",{onClick:()=>{y(1),p(null)},className:"px-4 py-2 border border-white/10 text-gray-500 font-mono text-xs hover:text-white transition-all",children:"START OVER"}),n.jsx("button",{onClick:()=>window.location.reload(),className:"btn-terminal px-6 py-2",children:"VIEW DASHBOARD"})]})]})]})}function Qf({onAdd:e,onCancel:t,team:r=[],t:s,language:l}){const[a,i]=v.useState(""),[o,c]=v.useState(""),[d,f]=v.useState("medium"),[g,h]=v.useState(""),x=N=>{if(N.preventDefault(),!a.trim())return;const E={name:a,description:o,priority:d};if(g){const b=r.find(m=>m.id===g);E.assigned_to=g,E.assigned_name=(b==null?void 0:b.name)||""}e(E)};return n.jsx("form",{onSubmit:x,className:"mt-4 p-4 border border-matrix/30 bg-matrix/5",children:n.jsxs("div",{className:"space-y-3",children:[n.jsx("input",{type:"text",placeholder:s?s("features.taskName"):"Task name",value:a,onChange:N=>i(N.target.value),className:"input-terminal w-full px-3 py-2 text-sm",autoFocus:!0}),n.jsx("textarea",{placeholder:s?s("features.taskDescription"):"Description (optional)",value:o,onChange:N=>c(N.target.value),rows:2,className:"input-terminal w-full px-3 py-2 text-sm resize-none"}),n.jsxs("div",{className:"flex items-center gap-3 flex-wrap",children:[n.jsxs("select",{value:d,onChange:N=>f(N.target.value),className:"input-terminal px-3 py-2 text-sm",children:[n.jsx("option",{value:"high",children:s?s("common.high").toUpperCase():"HIGH"}),n.jsx("option",{value:"medium",children:s?s("common.medium").toUpperCase():"MEDIUM"}),n.jsx("option",{value:"low",children:s?s("common.low").toUpperCase():"LOW"})]}),r.length>0&&n.jsxs("select",{value:g,onChange:N=>h(N.target.value),className:"input-terminal px-3 py-2 text-sm",children:[n.jsx("option",{value:"",children:s?s("features.unassigned"):"Unassigned"}),r.map(N=>n.jsx("option",{value:N.id,children:N.name},N.id))]}),n.jsx("div",{className:"flex-1"}),n.jsx("button",{type:"button",onClick:t,className:"px-4 py-2 font-mono text-xs text-gray-500 hover:text-white transition-all",children:s?s("common.cancel").toUpperCase():"CANCEL"}),n.jsx("button",{type:"submit",disabled:!a.trim(),className:"btn-terminal px-4 py-2 disabled:opacity-50",children:s?s("common.add").toUpperCase():"ADD"})]})]})})}function qf({onAdd:e,onClose:t,team:r=[],t:s,language:l}){const[a,i]=v.useState(""),[o,c]=v.useState(""),[d,f]=v.useState("medium"),[g,h]=v.useState(""),[x,N]=v.useState(""),E=b=>{if(b.preventDefault(),!a.trim())return;const m={id:g||void 0,name:a,description:o,priority:d};if(x){const u=r.find(p=>p.id===x);m.assigned_to=x,m.assigned_name=(u==null?void 0:u.name)||""}e(m)};return n.jsxs("div",{className:"w-full max-w-md",children:[n.jsx("h3",{className:"font-display text-xl text-matrix tracking-wider mb-6",children:s?s("features.addFeature"):"NEW FEATURE"}),n.jsxs("form",{onSubmit:E,className:"space-y-4",children:[n.jsxs("div",{children:[n.jsxs("label",{className:"font-mono text-[10px] text-gray-500 tracking-wider",children:["ID (",l==="es"?"opcional":"optional",")"]}),n.jsx("input",{type:"text",placeholder:"e.g. user-auth",value:g,onChange:b=>h(b.target.value),className:"input-terminal w-full px-4 py-2.5 mt-2 text-sm"})]}),n.jsxs("div",{children:[n.jsxs("label",{className:"font-mono text-[10px] text-gray-500 tracking-wider",children:[s?s("settings.name").toUpperCase():"NAME"," *"]}),n.jsx("input",{type:"text",placeholder:s?s("features.featureName"):"Feature name",value:a,onChange:b=>i(b.target.value),className:"input-terminal w-full px-4 py-2.5 mt-2 text-sm",autoFocus:!0})]}),n.jsxs("div",{children:[n.jsx("label",{className:"font-mono text-[10px] text-gray-500 tracking-wider",children:l==="es"?"DESCRIPCIÓN":"DESCRIPTION"}),n.jsx("textarea",{placeholder:s?s("features.featureDescription"):"Feature description",value:o,onChange:b=>c(b.target.value),rows:3,className:"input-terminal w-full px-4 py-2.5 mt-2 text-sm resize-none"})]}),n.jsxs("div",{children:[n.jsx("label",{className:"font-mono text-[10px] text-gray-500 tracking-wider",children:s?s("features.priority").toUpperCase():"PRIORITY"}),n.jsxs("select",{value:d,onChange:b=>f(b.target.value),className:"input-terminal w-full px-4 py-2.5 mt-2 text-sm",children:[n.jsx("option",{value:"high",children:s?s("common.high").toUpperCase():"HIGH"}),n.jsx("option",{value:"medium",children:s?s("common.medium").toUpperCase():"MEDIUM"}),n.jsx("option",{value:"low",children:s?s("common.low").toUpperCase():"LOW"})]})]}),r.length>0&&n.jsxs("div",{children:[n.jsx("label",{className:"font-mono text-[10px] text-gray-500 tracking-wider",children:s?s("features.assignTo").toUpperCase():"ASSIGN TO"}),n.jsxs("select",{value:x,onChange:b=>N(b.target.value),className:"input-terminal w-full px-4 py-2.5 mt-2 text-sm",children:[n.jsx("option",{value:"",children:s?s("features.unassigned"):"Unassigned"}),r.map(b=>n.jsx("option",{value:b.id,children:b.name},b.id))]})]}),n.jsxs("div",{className:"flex gap-3 pt-2",children:[n.jsx("button",{type:"button",onClick:t,className:"flex-1 py-2.5 border border-white/20 text-gray-500 font-mono text-xs hover:bg-white/5 transition-all",children:s?s("common.cancel").toUpperCase():"CANCEL"}),n.jsx("button",{type:"submit",disabled:!a.trim(),className:"btn-terminal flex-1 py-2.5 disabled:opacity-50",children:l==="es"?"CREAR":"CREATE"})]})]})]})}function hc({children:e,onClose:t}){return n.jsx("div",{className:"fixed inset-0 z-50 flex items-center justify-center p-4 modal-overlay animate-fade-in",onClick:t,children:n.jsx("div",{className:"terminal-card p-6 max-w-md w-full",onClick:r=>r.stopPropagation(),children:e})})}function Xf({roadmap:e,setRoadmap:t,setHasChanges:r,onClose:s}){var o,c,d;const l=[{name:"Matrix Green",color:"#00ff88"},{name:"Cyber Blue",color:"#00d4ff"},{name:"Signal Orange",color:"#ff9500"},{name:"Alert Red",color:"#ff3366"},{name:"Purple Haze",color:"#a855f7"},{name:"Gold",color:"#fbbf24"},{name:"Teal",color:"#14b8a6"},{name:"Pink",color:"#ec4899"},{name:"Lime",color:"#84cc16"},{name:"Sky",color:"#0ea5e9"},{name:"Indigo",color:"#6366f1"},{name:"Rose",color:"#f43f5e"}],a=((o=e==null?void 0:e.project_info)==null?void 0:o.theme)||{name:"Matrix Green",color:"#00ff88"},i=f=>{t(g=>{const h=JSON.parse(JSON.stringify(g));return h.project_info.theme=f,h}),r(!0)};return n.jsx("div",{className:"fixed inset-0 z-50 flex items-center justify-center p-4 modal-overlay animate-fade-in",onClick:s,children:n.jsxs("div",{className:"terminal-card p-6 max-w-lg w-full",onClick:f=>f.stopPropagation(),children:[n.jsxs("div",{className:"flex items-center justify-between mb-6",children:[n.jsxs("div",{className:"flex items-center gap-3",children:[n.jsx("div",{className:"w-8 h-8 rounded-lg",style:{backgroundColor:a.color,boxShadow:`0 0 20px ${a.color}50`}}),n.jsxs("div",{children:[n.jsx("h3",{className:"font-mono text-sm text-white tracking-wider",children:"PROJECT THEME"}),n.jsx("p",{className:"font-mono text-[10px] text-gray-600",children:a.name})]})]}),n.jsx("button",{onClick:s,className:"p-2 text-gray-600 hover:text-white transition-colors",children:n.jsx(ft,{className:"w-5 h-5"})})]}),n.jsxs("div",{className:"mb-6",children:[n.jsx("h4",{className:"font-mono text-[10px] text-gray-500 tracking-wider mb-3",children:"PRESETS"}),n.jsx("div",{className:"grid grid-cols-6 gap-3",children:l.map(f=>n.jsx("button",{onClick:()=>i(f),className:`w-full aspect-square rounded-lg transition-all hover:scale-110 relative group ${a.color===f.color?"ring-2 ring-white ring-offset-2 ring-offset-black scale-110":""}`,style:{backgroundColor:f.color,boxShadow:a.color===f.color?`0 0 20px ${f.color}`:"none"},title:f.name,children:a.color===f.color&&n.jsx(dr,{className:"w-4 h-4 text-black absolute top-1/2 left-1/2 -translate-x-1/2 -translate-y-1/2"})},f.name))})]}),n.jsxs("div",{className:"border-t border-white/10 pt-4",children:[n.jsx("h4",{className:"font-mono text-[10px] text-gray-500 tracking-wider mb-3",children:"CUSTOM"}),n.jsxs("div",{className:"flex items-center gap-3",children:[n.jsx("input",{type:"color",value:a.color,onChange:f=>i({name:"Custom",color:f.target.value}),className:"w-12 h-12 cursor-pointer bg-transparent border border-white/20 rounded"}),n.jsx("input",{type:"text",value:a.color,onChange:f=>{/^#[0-9A-Fa-f]{6}$/.test(f.target.value)&&i({name:"Custom",color:f.target.value})},placeholder:"#00ff88",className:"input-terminal px-3 py-2 text-sm w-32 font-mono"}),n.jsx("input",{type:"text",value:a.name,onChange:f=>i({...a,name:f.target.value}),placeholder:"Theme name",className:"input-terminal px-3 py-2 text-sm flex-1 font-mono"})]})]}),n.jsx("div",{className:"mt-6 p-4 border border-white/10 bg-black/50 rounded",children:n.jsxs("div",{className:"flex items-center gap-4",children:[n.jsxs("div",{className:"flex items-center gap-2",children:[n.jsx("span",{className:"font-mono text-[10px] text-gray-600",children:"FAVICON:"}),n.jsx("div",{className:"w-8 h-8 rounded",style:{backgroundColor:a.color}})]}),n.jsxs("div",{className:"flex-1",children:[n.jsx("div",{className:"font-mono text-xs text-white",children:((c=e==null?void 0:e.project_info)==null?void 0:c.name)||"Project"}),n.jsx("div",{className:"progress-brutal mt-2 h-2",children:n.jsx("div",{className:"h-full transition-all",style:{width:`${((d=e==null?void 0:e.project_info)==null?void 0:d.total_progress)||0}%`,backgroundColor:a.color}})})]})]})}),n.jsx("p",{className:"font-mono text-[10px] text-gray-600 mt-4 text-center",children:"Theme color appears in browser tab favicon and UI accents"})]})})}function Zf({onLogin:e,error:t}){const[r,s]=v.useState(""),[l,a]=v.useState(""),[i,o]=v.useState(!1),c=async d=>{d.preventDefault(),!(!r.trim()||!l.trim())&&(o(!0),await e(r,l),o(!1))};return n.jsx("div",{className:"min-h-screen flex items-center justify-center bg-black p-4",children:n.jsxs("div",{className:"w-full max-w-sm",children:[n.jsxs("div",{className:"text-center mb-10",children:[n.jsxs("div",{className:"relative inline-block",children:[n.jsx("div",{className:"w-24 h-24 border-2 border-matrix/50 flex items-center justify-center glow-matrix",children:n.jsx(ri,{className:"w-10 h-10 text-matrix"})}),n.jsx("div",{className:"absolute -top-1 -left-1 w-4 h-4 border-l-2 border-t-2 border-matrix"}),n.jsx("div",{className:"absolute -top-1 -right-1 w-4 h-4 border-r-2 border-t-2 border-matrix"}),n.jsx("div",{className:"absolute -bottom-1 -left-1 w-4 h-4 border-l-2 border-b-2 border-matrix"}),n.jsx("div",{className:"absolute -bottom-1 -right-1 w-4 h-4 border-r-2 border-b-2 border-matrix"})]}),n.jsx("h1",{className:"font-display text-3xl text-matrix tracking-wider mt-6 crt-glow",children:"ROADMAP"}),n.jsx("p",{className:"font-mono text-xs text-gray-600 tracking-widest mt-2",children:"TERMINAL ACCESS"})]}),n.jsxs("div",{className:"terminal-card p-6",children:[n.jsxs("div",{className:"flex items-center gap-3 mb-6",children:[n.jsx("div",{className:"led led-amber"}),n.jsx("span",{className:"font-mono text-xs text-signal tracking-wider",children:"AUTHENTICATION REQUIRED"})]}),n.jsxs("form",{onSubmit:c,className:"space-y-4",children:[n.jsxs("div",{children:[n.jsx("label",{className:"font-mono text-[10px] text-gray-500 tracking-wider",children:"EMAIL"}),n.jsxs("div",{className:"relative mt-2",children:[n.jsx(ni,{className:"w-4 h-4 text-gray-600 absolute left-3 top-1/2 -translate-y-1/2"}),n.jsx("input",{type:"email",value:r,onChange:d=>s(d.target.value),placeholder:"admin@localhost",className:"input-terminal w-full pl-10 pr-4 py-3 text-sm",autoComplete:"email",autoFocus:!0})]})]}),n.jsxs("div",{children:[n.jsx("label",{className:"font-mono text-[10px] text-gray-500 tracking-wider",children:"PASSWORD"}),n.jsxs("div",{className:"relative mt-2",children:[n.jsx(Du,{className:"w-4 h-4 text-gray-600 absolute left-3 top-1/2 -translate-y-1/2"}),n.jsx("input",{type:"password",value:l,onChange:d=>a(d.target.value),placeholder:"••••••••",className:"input-terminal w-full pl-10 pr-4 py-3 text-sm",autoComplete:"current-password"})]})]}),t&&n.jsxs("div",{className:"p-3 border border-alert/30 bg-alert/5 text-alert font-mono text-xs flex items-center gap-2",children:[n.jsx(Oe,{className:"w-4 h-4"}),t]}),n.jsx("button",{type:"submit",disabled:i||!r.trim()||!l.trim(),className:"btn-terminal w-full py-3 flex items-center justify-center gap-2 disabled:opacity-50",children:i?n.jsxs(n.Fragment,{children:[n.jsx(et,{className:"w-4 h-4 animate-spin"}),"VERIFYING..."]}):n.jsxs(n.Fragment,{children:[n.jsx(Cf,{className:"w-4 h-4"}),"ACCESS"]})})]}),n.jsx("p",{className:"font-mono text-[10px] text-gray-700 text-center mt-6",children:"Credentials configured in .env file"})]})]})})}function ex(){return`# AI Development Rules
|
|
377
|
-
|
|
378
|
-
## 📖 FIRST STEP - READ THE ROADMAP
|
|
379
|
-
|
|
380
|
-
**BEFORE writing any code, you MUST read:**
|
|
381
|
-
\`\`\`
|
|
382
|
-
roadmap-kit/roadmap.json
|
|
383
|
-
\`\`\`
|
|
384
|
-
|
|
385
|
-
This file contains:
|
|
386
|
-
- Project context, stack, and architecture
|
|
387
|
-
- Shared resources (components, utilities, DB tables) - **DO NOT DUPLICATE**
|
|
388
|
-
- Coding conventions specific to this project
|
|
389
|
-
- Current features and tasks with detailed descriptions
|
|
390
|
-
|
|
391
|
-
---
|
|
392
|
-
|
|
393
|
-
## 📝 Code Conventions
|
|
394
|
-
|
|
395
|
-
### Naming
|
|
396
|
-
- **Variables & Functions**: \`camelCase\`
|
|
397
|
-
- **Components/Classes**: \`PascalCase\`
|
|
398
|
-
- **Constants**: \`UPPER_SNAKE_CASE\`
|
|
399
|
-
- **Files**: \`kebab-case\` for utils, \`PascalCase\` for components
|
|
400
|
-
- **CSS/Tailwind classes**: \`kebab-case\`
|
|
401
|
-
|
|
402
|
-
### Best Practices
|
|
403
|
-
- Keep functions small and focused (single responsibility)
|
|
404
|
-
- Use descriptive names over comments
|
|
405
|
-
- DRY - Don't Repeat Yourself (check shared_resources first)
|
|
406
|
-
- Prefer composition over inheritance
|
|
407
|
-
- Handle errors explicitly, never swallow them
|
|
408
|
-
- Validate inputs at system boundaries
|
|
409
|
-
|
|
410
|
-
### Code Quality
|
|
411
|
-
- No magic numbers - use named constants
|
|
412
|
-
- Avoid deep nesting (max 3 levels)
|
|
413
|
-
- Early returns over nested conditionals
|
|
414
|
-
- Explicit is better than implicit
|
|
415
|
-
|
|
416
|
-
---
|
|
417
|
-
|
|
418
|
-
## ♻️ SHARED RESOURCES - MANDATORY
|
|
419
|
-
|
|
420
|
-
**Check \`roadmap.json > project_info > shared_resources\` BEFORE creating:**
|
|
421
|
-
|
|
422
|
-
1. **UI Components** - Reuse existing buttons, inputs, modals, etc.
|
|
423
|
-
2. **Utilities** - Use existing helpers, formatters, validators
|
|
424
|
-
3. **Database Tables** - Don't create duplicate tables
|
|
425
|
-
|
|
426
|
-
**RULE:** If it exists in shared_resources, you MUST use it.
|
|
427
|
-
|
|
428
|
-
---
|
|
429
|
-
|
|
430
|
-
## 🔖 Commit Format
|
|
431
|
-
|
|
432
|
-
Use this format for automatic roadmap updates:
|
|
433
|
-
|
|
434
|
-
\`\`\`
|
|
435
|
-
[task:TASK-ID] [status:STATUS] Description
|
|
436
|
-
\`\`\`
|
|
437
|
-
|
|
438
|
-
**Examples:**
|
|
439
|
-
\`\`\`bash
|
|
440
|
-
git commit -m "[task:auth-login] [status:completed] Implement JWT authentication"
|
|
441
|
-
git commit -m "[task:user-api] [status:in_progress] Add user CRUD endpoints"
|
|
442
|
-
git commit -m "[task:payment] [status:completed] [debt:Missing validation|high] Add payment processing"
|
|
443
|
-
\`\`\`
|
|
444
|
-
|
|
445
|
-
**Available tags:**
|
|
446
|
-
- \`[task:id]\` - Task ID from roadmap.json
|
|
447
|
-
- \`[status:pending|in_progress|completed]\` - Task status
|
|
448
|
-
- \`[debt:description|severity|effort]\` - Technical debt (severity: low/medium/high)
|
|
449
|
-
|
|
450
|
-
---
|
|
451
|
-
|
|
452
|
-
## ⚠️ Technical Debt Capture
|
|
453
|
-
|
|
454
|
-
**You MUST register technical debt when:**
|
|
455
|
-
- Skipping validation or error handling
|
|
456
|
-
- Using workarounds or hacks
|
|
457
|
-
- Leaving TODO comments
|
|
458
|
-
- Not writing tests
|
|
459
|
-
- Hardcoding values
|
|
460
|
-
- Any "temporary" solutions
|
|
461
|
-
|
|
462
|
-
**Severity Guide:**
|
|
463
|
-
| Severity | When | Action Required |
|
|
464
|
-
|----------|------|-----------------|
|
|
465
|
-
| high | Security, data integrity | Fix ASAP |
|
|
466
|
-
| medium | Functionality degraded | Fix soon |
|
|
467
|
-
| low | Improvements, optimizations | When time allows |
|
|
468
|
-
|
|
469
|
-
---
|
|
470
|
-
|
|
471
|
-
## 📋 After Completing a Task
|
|
472
|
-
|
|
473
|
-
Update \`roadmap.json\` with:
|
|
474
|
-
|
|
475
|
-
1. **status**: "completed" or "in_progress"
|
|
476
|
-
2. **ai_notes**: Your implementation decisions and reasoning
|
|
477
|
-
3. **affected_files**: All files created or modified
|
|
478
|
-
4. **reused_resources**: Components/utilities you reused
|
|
479
|
-
5. **technical_debt**: Any debt you introduced
|
|
480
|
-
|
|
481
|
-
---
|
|
482
|
-
|
|
483
|
-
## ✅ Pre-Commit Checklist
|
|
484
|
-
|
|
485
|
-
- [ ] Read the task description from roadmap.json?
|
|
486
|
-
- [ ] Checked shared_resources for existing code?
|
|
487
|
-
- [ ] Followed project conventions?
|
|
488
|
-
- [ ] Updated roadmap.json with results?
|
|
489
|
-
- [ ] Registered technical debt if any?
|
|
490
|
-
- [ ] Used correct commit format?
|
|
491
|
-
|
|
492
|
-
---
|
|
493
|
-
|
|
494
|
-
## 🚫 DO NOT
|
|
495
|
-
|
|
496
|
-
- Create duplicate components/utilities
|
|
497
|
-
- Ignore project conventions
|
|
498
|
-
- Commit without task tags
|
|
499
|
-
- Leave undocumented technical debt
|
|
500
|
-
- Refactor unrelated code
|
|
501
|
-
- Skip reading the roadmap
|
|
502
|
-
|
|
503
|
-
---
|
|
504
|
-
|
|
505
|
-
**🗺️ ROADMAP-KIT** - AI needs context too.
|
|
506
|
-
`}function tx(){return n.jsx(If,{children:n.jsx(Lf,{children:n.jsx(Mf,{})})})}aa.createRoot(document.getElementById("root")).render(n.jsx(oi.StrictMode,{children:n.jsx(tx,{})}));
|