diff --git "a/static/assets/index-66e7a223.js" "b/static/assets/index-66e7a223.js" new file mode 100644--- /dev/null +++ "b/static/assets/index-66e7a223.js" @@ -0,0 +1,291 @@ +function Bf(e,t){for(var n=0;nr[l]})}}}return Object.freeze(Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}))}(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const l of document.querySelectorAll('link[rel="modulepreload"]'))r(l);new MutationObserver(l=>{for(const s of l)if(s.type==="childList")for(const o of s.addedNodes)o.tagName==="LINK"&&o.rel==="modulepreload"&&r(o)}).observe(document,{childList:!0,subtree:!0});function n(l){const s={};return l.integrity&&(s.integrity=l.integrity),l.referrerPolicy&&(s.referrerPolicy=l.referrerPolicy),l.crossOrigin==="use-credentials"?s.credentials="include":l.crossOrigin==="anonymous"?s.credentials="omit":s.credentials="same-origin",s}function r(l){if(l.ep)return;l.ep=!0;const s=n(l);fetch(l.href,s)}})();function Vf(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Pu={exports:{}},ts={},Tu={exports:{}},I={};/** + * @license React + * react.production.min.js + * + * Copyright (c) Facebook, Inc. and its affiliates. + * + * This source code is licensed under the MIT license found in the + * LICENSE file in the root directory of this source tree. + */var zr=Symbol.for("react.element"),Wf=Symbol.for("react.portal"),Hf=Symbol.for("react.fragment"),Qf=Symbol.for("react.strict_mode"),Gf=Symbol.for("react.profiler"),Kf=Symbol.for("react.provider"),Yf=Symbol.for("react.context"),Jf=Symbol.for("react.forward_ref"),Xf=Symbol.for("react.suspense"),Zf=Symbol.for("react.memo"),qf=Symbol.for("react.lazy"),na=Symbol.iterator;function ep(e){return e===null||typeof e!="object"?null:(e=na&&e[na]||e["@@iterator"],typeof e=="function"?e:null)}var bu={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},Mu=Object.assign,Ru={};function Dn(e,t,n){this.props=e,this.context=t,this.refs=Ru,this.updater=n||bu}Dn.prototype.isReactComponent={};Dn.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")};Dn.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function Iu(){}Iu.prototype=Dn.prototype;function Zo(e,t,n){this.props=e,this.context=t,this.refs=Ru,this.updater=n||bu}var qo=Zo.prototype=new Iu;qo.constructor=Zo;Mu(qo,Dn.prototype);qo.isPureReactComponent=!0;var ra=Array.isArray,zu=Object.prototype.hasOwnProperty,ei={current:null},Lu={key:!0,ref:!0,__self:!0,__source:!0};function Au(e,t,n){var r,l={},s=null,o=null;if(t!=null)for(r in t.ref!==void 0&&(o=t.ref),t.key!==void 0&&(s=""+t.key),t)zu.call(t,r)&&!Lu.hasOwnProperty(r)&&(l[r]=t[r]);var a=arguments.length-2;if(a===1)l.children=n;else if(1>>1,Y=P[V];if(0>>1;Vl(ys,R))Vtl(Br,ys)?(P[V]=Br,P[Vt]=R,V=Vt):(P[V]=ys,P[Bt]=R,V=Bt);else if(Vtl(Br,R))P[V]=Br,P[Vt]=R,V=Vt;else break e}}return b}function l(P,b){var R=P.sortIndex-b.sortIndex;return R!==0?R:P.id-b.id}if(typeof performance=="object"&&typeof performance.now=="function"){var s=performance;e.unstable_now=function(){return s.now()}}else{var o=Date,a=o.now();e.unstable_now=function(){return o.now()-a}}var u=[],c=[],d=1,f=null,p=3,y=!1,w=!1,x=!1,j=typeof setTimeout=="function"?setTimeout:null,h=typeof clearTimeout=="function"?clearTimeout:null,m=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function g(P){for(var b=n(c);b!==null;){if(b.callback===null)r(c);else if(b.startTime<=P)r(c),b.sortIndex=b.expirationTime,t(u,b);else break;b=n(c)}}function N(P){if(x=!1,g(P),!w)if(n(u)!==null)w=!0,fe(S);else{var b=n(c);b!==null&&dn(N,b.startTime-P)}}function S(P,b){w=!1,x&&(x=!1,h(C),C=-1),y=!0;var R=p;try{for(g(b),f=n(u);f!==null&&(!(f.expirationTime>b)||P&&!re());){var V=f.callback;if(typeof V=="function"){f.callback=null,p=f.priorityLevel;var Y=V(f.expirationTime<=b);b=e.unstable_now(),typeof Y=="function"?f.callback=Y:f===n(u)&&r(u),g(b)}else r(u);f=n(u)}if(f!==null)var oe=!0;else{var Bt=n(c);Bt!==null&&dn(N,Bt.startTime-b),oe=!1}return oe}finally{f=null,p=R,y=!1}}var E=!1,_=null,C=-1,B=5,M=-1;function re(){return!(e.unstable_now()-MP||125V?(P.sortIndex=R,t(c,P),n(u)===null&&P===n(c)&&(x?(h(C),C=-1):x=!0,dn(N,R-V))):(P.sortIndex=Y,t(u,P),w||y||(w=!0,fe(S))),P},e.unstable_shouldYield=re,e.unstable_wrapCallback=function(P){var b=p;return function(){var R=p;p=b;try{return P.apply(this,arguments)}finally{p=R}}}})(Uu);Du.exports=Uu;var dp=Du.exports;/** + * @license React + * react-dom.production.min.js + * + * Copyright (c) Facebook, Inc. and its affiliates. + * + * This source code is licensed under the MIT license found in the + * LICENSE file in the root directory of this source tree. + */var fp=v,Re=dp;function k(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,n=1;n"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),Js=Object.prototype.hasOwnProperty,pp=/^[: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]*$/,sa={},oa={};function mp(e){return Js.call(oa,e)?!0:Js.call(sa,e)?!1:pp.test(e)?oa[e]=!0:(sa[e]=!0,!1)}function hp(e,t,n,r){if(n!==null&&n.type===0)return!1;switch(typeof t){case"function":case"symbol":return!0;case"boolean":return r?!1:n!==null?!n.acceptsBooleans:(e=e.toLowerCase().slice(0,5),e!=="data-"&&e!=="aria-");default:return!1}}function gp(e,t,n,r){if(t===null||typeof t>"u"||hp(e,t,n,r))return!0;if(r)return!1;if(n!==null)switch(n.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 we(e,t,n,r,l,s,o){this.acceptsBooleans=t===2||t===3||t===4,this.attributeName=r,this.attributeNamespace=l,this.mustUseProperty=n,this.propertyName=e,this.type=t,this.sanitizeURL=s,this.removeEmptyString=o}var de={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){de[e]=new we(e,0,!1,e,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];de[t]=new we(t,1,!1,e[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(e){de[e]=new we(e,2,!1,e.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){de[e]=new we(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){de[e]=new we(e,3,!1,e.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(e){de[e]=new we(e,3,!0,e,null,!1,!1)});["capture","download"].forEach(function(e){de[e]=new we(e,4,!1,e,null,!1,!1)});["cols","rows","size","span"].forEach(function(e){de[e]=new we(e,6,!1,e,null,!1,!1)});["rowSpan","start"].forEach(function(e){de[e]=new we(e,5,!1,e.toLowerCase(),null,!1,!1)});var ri=/[\-:]([a-z])/g;function li(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(ri,li);de[t]=new we(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(ri,li);de[t]=new we(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(ri,li);de[t]=new we(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(e){de[e]=new we(e,1,!1,e.toLowerCase(),null,!1,!1)});de.xlinkHref=new we("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(e){de[e]=new we(e,1,!1,e.toLowerCase(),null,!0,!0)});function si(e,t,n,r){var l=de.hasOwnProperty(t)?de[t]:null;(l!==null?l.type!==0:r||!(2a||l[o]!==s[a]){var u=` +`+l[o].replace(" at new "," at ");return e.displayName&&u.includes("")&&(u=u.replace("",e.displayName)),u}while(1<=o&&0<=a);break}}}finally{js=!1,Error.prepareStackTrace=n}return(e=e?e.displayName||e.name:"")?er(e):""}function vp(e){switch(e.tag){case 5:return er(e.type);case 16:return er("Lazy");case 13:return er("Suspense");case 19:return er("SuspenseList");case 0:case 2:case 15:return e=ks(e.type,!1),e;case 11:return e=ks(e.type.render,!1),e;case 1:return e=ks(e.type,!0),e;default:return""}}function eo(e){if(e==null)return null;if(typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case mn:return"Fragment";case pn:return"Portal";case Xs:return"Profiler";case oi:return"StrictMode";case Zs:return"Suspense";case qs:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case Wu:return(e.displayName||"Context")+".Consumer";case Vu:return(e._context.displayName||"Context")+".Provider";case ii:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case ai:return t=e.displayName||null,t!==null?t:eo(e.type)||"Memo";case wt:t=e._payload,e=e._init;try{return eo(e(t))}catch{}}return null}function xp(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 eo(t);case 8:return t===oi?"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 At(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function Qu(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function yp(e){var t=Qu(e)?"checked":"value",n=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),r=""+e[t];if(!e.hasOwnProperty(t)&&typeof n<"u"&&typeof n.get=="function"&&typeof n.set=="function"){var l=n.get,s=n.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return l.call(this)},set:function(o){r=""+o,s.call(this,o)}}),Object.defineProperty(e,t,{enumerable:n.enumerable}),{getValue:function(){return r},setValue:function(o){r=""+o},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function Hr(e){e._valueTracker||(e._valueTracker=yp(e))}function Gu(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r="";return e&&(r=Qu(e)?e.checked?"true":"false":e.value),e=r,e!==n?(t.setValue(e),!0):!1}function kl(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 to(e,t){var n=t.checked;return Z({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:n??e._wrapperState.initialChecked})}function aa(e,t){var n=t.defaultValue==null?"":t.defaultValue,r=t.checked!=null?t.checked:t.defaultChecked;n=At(t.value!=null?t.value:n),e._wrapperState={initialChecked:r,initialValue:n,controlled:t.type==="checkbox"||t.type==="radio"?t.checked!=null:t.value!=null}}function Ku(e,t){t=t.checked,t!=null&&si(e,"checked",t,!1)}function no(e,t){Ku(e,t);var n=At(t.value),r=t.type;if(n!=null)r==="number"?(n===0&&e.value===""||e.value!=n)&&(e.value=""+n):e.value!==""+n&&(e.value=""+n);else if(r==="submit"||r==="reset"){e.removeAttribute("value");return}t.hasOwnProperty("value")?ro(e,t.type,n):t.hasOwnProperty("defaultValue")&&ro(e,t.type,At(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function ua(e,t,n){if(t.hasOwnProperty("value")||t.hasOwnProperty("defaultValue")){var r=t.type;if(!(r!=="submit"&&r!=="reset"||t.value!==void 0&&t.value!==null))return;t=""+e._wrapperState.initialValue,n||t===e.value||(e.value=t),e.defaultValue=t}n=e.name,n!==""&&(e.name=""),e.defaultChecked=!!e._wrapperState.initialChecked,n!==""&&(e.name=n)}function ro(e,t,n){(t!=="number"||kl(e.ownerDocument)!==e)&&(n==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+n&&(e.defaultValue=""+n))}var tr=Array.isArray;function En(e,t,n,r){if(e=e.options,t){t={};for(var l=0;l"+t.valueOf().toString()+"",t=Qr.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function hr(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var sr={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},wp=["Webkit","ms","Moz","O"];Object.keys(sr).forEach(function(e){wp.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),sr[t]=sr[e]})});function Zu(e,t,n){return t==null||typeof t=="boolean"||t===""?"":n||typeof t!="number"||t===0||sr.hasOwnProperty(e)&&sr[e]?(""+t).trim():t+"px"}function qu(e,t){e=e.style;for(var n in t)if(t.hasOwnProperty(n)){var r=n.indexOf("--")===0,l=Zu(n,t[n],r);n==="float"&&(n="cssFloat"),r?e.setProperty(n,l):e[n]=l}}var Np=Z({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 oo(e,t){if(t){if(Np[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(k(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(k(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(k(61))}if(t.style!=null&&typeof t.style!="object")throw Error(k(62))}}function io(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 ao=null;function ui(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var uo=null,_n=null,Pn=null;function fa(e){if(e=Or(e)){if(typeof uo!="function")throw Error(k(280));var t=e.stateNode;t&&(t=os(t),uo(e.stateNode,e.type,t))}}function ec(e){_n?Pn?Pn.push(e):Pn=[e]:_n=e}function tc(){if(_n){var e=_n,t=Pn;if(Pn=_n=null,fa(e),t)for(e=0;e>>=0,e===0?32:31-(Rp(e)/Ip|0)|0}var Gr=64,Kr=4194304;function nr(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 _l(e,t){var n=e.pendingLanes;if(n===0)return 0;var r=0,l=e.suspendedLanes,s=e.pingedLanes,o=n&268435455;if(o!==0){var a=o&~l;a!==0?r=nr(a):(s&=o,s!==0&&(r=nr(s)))}else o=n&~l,o!==0?r=nr(o):s!==0&&(r=nr(s));if(r===0)return 0;if(t!==0&&t!==r&&!(t&l)&&(l=r&-r,s=t&-t,l>=s||l===16&&(s&4194240)!==0))return t;if(r&4&&(r|=n&16),t=e.entangledLanes,t!==0)for(e=e.entanglements,t&=r;0n;n++)t.push(e);return t}function Lr(e,t,n){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-Qe(t),e[t]=n}function Op(e,t){var n=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 r=e.eventTimes;for(e=e.expirationTimes;0=ir),Na=String.fromCharCode(32),ja=!1;function Nc(e,t){switch(e){case"keyup":return dm.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function jc(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var hn=!1;function pm(e,t){switch(e){case"compositionend":return jc(t);case"keypress":return t.which!==32?null:(ja=!0,Na);case"textInput":return e=t.data,e===Na&&ja?null:e;default:return null}}function mm(e,t){if(hn)return e==="compositionend"||!vi&&Nc(e,t)?(e=yc(),dl=mi=St=null,hn=!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)return{node:n,offset:t-e};e=r}e:{for(;n;){if(n.nextSibling){n=n.nextSibling;break e}n=n.parentNode}n=void 0}n=Ea(n)}}function Ec(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?Ec(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function _c(){for(var e=window,t=kl();t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href=="string"}catch{n=!1}if(n)e=t.contentWindow;else break;t=kl(e.document)}return t}function xi(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 km(e){var t=_c(),n=e.focusedElem,r=e.selectionRange;if(t!==n&&n&&n.ownerDocument&&Ec(n.ownerDocument.documentElement,n)){if(r!==null&&xi(n)){if(t=r.start,e=r.end,e===void 0&&(e=t),"selectionStart"in n)n.selectionStart=t,n.selectionEnd=Math.min(e,n.value.length);else if(e=(t=n.ownerDocument||document)&&t.defaultView||window,e.getSelection){e=e.getSelection();var l=n.textContent.length,s=Math.min(r.start,l);r=r.end===void 0?s:Math.min(r.end,l),!e.extend&&s>r&&(l=r,r=s,s=l),l=_a(n,s);var o=_a(n,r);l&&o&&(e.rangeCount!==1||e.anchorNode!==l.node||e.anchorOffset!==l.offset||e.focusNode!==o.node||e.focusOffset!==o.offset)&&(t=t.createRange(),t.setStart(l.node,l.offset),e.removeAllRanges(),s>r?(e.addRange(t),e.extend(o.node,o.offset)):(t.setEnd(o.node,o.offset),e.addRange(t)))}}for(t=[],e=n;e=e.parentNode;)e.nodeType===1&&t.push({element:e,left:e.scrollLeft,top:e.scrollTop});for(typeof n.focus=="function"&&n.focus(),n=0;n=document.documentMode,gn=null,go=null,ur=null,vo=!1;function Pa(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;vo||gn==null||gn!==kl(r)||(r=gn,"selectionStart"in r&&xi(r)?r={start:r.selectionStart,end:r.selectionEnd}:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection(),r={anchorNode:r.anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset}),ur&&Nr(ur,r)||(ur=r,r=bl(go,"onSelect"),0yn||(e.current=ko[yn],ko[yn]=null,yn--)}function W(e,t){yn++,ko[yn]=e.current,e.current=t}var Ot={},ge=$t(Ot),Ce=$t(!1),qt=Ot;function In(e,t){var n=e.type.contextTypes;if(!n)return Ot;var r=e.stateNode;if(r&&r.__reactInternalMemoizedUnmaskedChildContext===t)return r.__reactInternalMemoizedMaskedChildContext;var l={},s;for(s in n)l[s]=t[s];return r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=l),l}function Ee(e){return e=e.childContextTypes,e!=null}function Rl(){G(Ce),G(ge)}function La(e,t,n){if(ge.current!==Ot)throw Error(k(168));W(ge,t),W(Ce,n)}function Ac(e,t,n){var r=e.stateNode;if(t=t.childContextTypes,typeof r.getChildContext!="function")return n;r=r.getChildContext();for(var l in r)if(!(l in t))throw Error(k(108,xp(e)||"Unknown",l));return Z({},n,r)}function Il(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||Ot,qt=ge.current,W(ge,e),W(Ce,Ce.current),!0}function Aa(e,t,n){var r=e.stateNode;if(!r)throw Error(k(169));n?(e=Ac(e,t,qt),r.__reactInternalMemoizedMergedChildContext=e,G(Ce),G(ge),W(ge,e)):G(Ce),W(Ce,n)}var ot=null,is=!1,Os=!1;function Oc(e){ot===null?ot=[e]:ot.push(e)}function Lm(e){is=!0,Oc(e)}function Dt(){if(!Os&&ot!==null){Os=!0;var e=0,t=D;try{var n=ot;for(D=1;e>=o,l-=o,it=1<<32-Qe(t)+l|n<C?(B=_,_=null):B=_.sibling;var M=p(h,_,g[C],N);if(M===null){_===null&&(_=B);break}e&&_&&M.alternate===null&&t(h,_),m=s(M,m,C),E===null?S=M:E.sibling=M,E=M,_=B}if(C===g.length)return n(h,_),K&&Wt(h,C),S;if(_===null){for(;CC?(B=_,_=null):B=_.sibling;var re=p(h,_,M.value,N);if(re===null){_===null&&(_=B);break}e&&_&&re.alternate===null&&t(h,_),m=s(re,m,C),E===null?S=re:E.sibling=re,E=re,_=B}if(M.done)return n(h,_),K&&Wt(h,C),S;if(_===null){for(;!M.done;C++,M=g.next())M=f(h,M.value,N),M!==null&&(m=s(M,m,C),E===null?S=M:E.sibling=M,E=M);return K&&Wt(h,C),S}for(_=r(h,_);!M.done;C++,M=g.next())M=y(_,h,C,M.value,N),M!==null&&(e&&M.alternate!==null&&_.delete(M.key===null?C:M.key),m=s(M,m,C),E===null?S=M:E.sibling=M,E=M);return e&&_.forEach(function(A){return t(h,A)}),K&&Wt(h,C),S}function j(h,m,g,N){if(typeof g=="object"&&g!==null&&g.type===mn&&g.key===null&&(g=g.props.children),typeof g=="object"&&g!==null){switch(g.$$typeof){case Wr:e:{for(var S=g.key,E=m;E!==null;){if(E.key===S){if(S=g.type,S===mn){if(E.tag===7){n(h,E.sibling),m=l(E,g.props.children),m.return=h,h=m;break e}}else if(E.elementType===S||typeof S=="object"&&S!==null&&S.$$typeof===wt&&$a(S)===E.type){n(h,E.sibling),m=l(E,g.props),m.ref=Yn(h,E,g),m.return=h,h=m;break e}n(h,E);break}else t(h,E);E=E.sibling}g.type===mn?(m=Zt(g.props.children,h.mode,N,g.key),m.return=h,h=m):(N=yl(g.type,g.key,g.props,null,h.mode,N),N.ref=Yn(h,m,g),N.return=h,h=N)}return o(h);case pn:e:{for(E=g.key;m!==null;){if(m.key===E)if(m.tag===4&&m.stateNode.containerInfo===g.containerInfo&&m.stateNode.implementation===g.implementation){n(h,m.sibling),m=l(m,g.children||[]),m.return=h,h=m;break e}else{n(h,m);break}else t(h,m);m=m.sibling}m=Hs(g,h.mode,N),m.return=h,h=m}return o(h);case wt:return E=g._init,j(h,m,E(g._payload),N)}if(tr(g))return w(h,m,g,N);if(Wn(g))return x(h,m,g,N);tl(h,g)}return typeof g=="string"&&g!==""||typeof g=="number"?(g=""+g,m!==null&&m.tag===6?(n(h,m.sibling),m=l(m,g),m.return=h,h=m):(n(h,m),m=Ws(g,h.mode,N),m.return=h,h=m),o(h)):n(h,m)}return j}var Ln=Uc(!0),Bc=Uc(!1),Al=$t(null),Ol=null,jn=null,ji=null;function ki(){ji=jn=Ol=null}function Si(e){var t=Al.current;G(Al),e._currentValue=t}function Eo(e,t,n){for(;e!==null;){var r=e.alternate;if((e.childLanes&t)!==t?(e.childLanes|=t,r!==null&&(r.childLanes|=t)):r!==null&&(r.childLanes&t)!==t&&(r.childLanes|=t),e===n)break;e=e.return}}function bn(e,t){Ol=e,ji=jn=null,e=e.dependencies,e!==null&&e.firstContext!==null&&(e.lanes&t&&(ke=!0),e.firstContext=null)}function $e(e){var t=e._currentValue;if(ji!==e)if(e={context:e,memoizedValue:t,next:null},jn===null){if(Ol===null)throw Error(k(308));jn=e,Ol.dependencies={lanes:0,firstContext:e}}else jn=jn.next=e;return t}var Kt=null;function Ci(e){Kt===null?Kt=[e]:Kt.push(e)}function Vc(e,t,n,r){var l=t.interleaved;return l===null?(n.next=n,Ci(t)):(n.next=l.next,l.next=n),t.interleaved=n,mt(e,r)}function mt(e,t){e.lanes|=t;var n=e.alternate;for(n!==null&&(n.lanes|=t),n=e,e=e.return;e!==null;)e.childLanes|=t,n=e.alternate,n!==null&&(n.childLanes|=t),n=e,e=e.return;return n.tag===3?n.stateNode:null}var Nt=!1;function Ei(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function Wc(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 ut(e,t){return{eventTime:e,lane:t,tag:0,payload:null,callback:null,next:null}}function Mt(e,t,n){var r=e.updateQueue;if(r===null)return null;if(r=r.shared,L&2){var l=r.pending;return l===null?t.next=t:(t.next=l.next,l.next=t),r.pending=t,mt(e,n)}return l=r.interleaved,l===null?(t.next=t,Ci(r)):(t.next=l.next,l.next=t),r.interleaved=t,mt(e,n)}function pl(e,t,n){if(t=t.updateQueue,t!==null&&(t=t.shared,(n&4194240)!==0)){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,di(e,n)}}function Da(e,t){var n=e.updateQueue,r=e.alternate;if(r!==null&&(r=r.updateQueue,n===r)){var l=null,s=null;if(n=n.firstBaseUpdate,n!==null){do{var o={eventTime:n.eventTime,lane:n.lane,tag:n.tag,payload:n.payload,callback:n.callback,next:null};s===null?l=s=o:s=s.next=o,n=n.next}while(n!==null);s===null?l=s=t:s=s.next=t}else l=s=t;n={baseState:r.baseState,firstBaseUpdate:l,lastBaseUpdate:s,shared:r.shared,effects:r.effects},e.updateQueue=n;return}e=n.lastBaseUpdate,e===null?n.firstBaseUpdate=t:e.next=t,n.lastBaseUpdate=t}function Fl(e,t,n,r){var l=e.updateQueue;Nt=!1;var s=l.firstBaseUpdate,o=l.lastBaseUpdate,a=l.shared.pending;if(a!==null){l.shared.pending=null;var u=a,c=u.next;u.next=null,o===null?s=c:o.next=c,o=u;var d=e.alternate;d!==null&&(d=d.updateQueue,a=d.lastBaseUpdate,a!==o&&(a===null?d.firstBaseUpdate=c:a.next=c,d.lastBaseUpdate=u))}if(s!==null){var f=l.baseState;o=0,d=c=u=null,a=s;do{var p=a.lane,y=a.eventTime;if((r&p)===p){d!==null&&(d=d.next={eventTime:y,lane:0,tag:a.tag,payload:a.payload,callback:a.callback,next:null});e:{var w=e,x=a;switch(p=t,y=n,x.tag){case 1:if(w=x.payload,typeof w=="function"){f=w.call(y,f,p);break e}f=w;break e;case 3:w.flags=w.flags&-65537|128;case 0:if(w=x.payload,p=typeof w=="function"?w.call(y,f,p):w,p==null)break e;f=Z({},f,p);break e;case 2:Nt=!0}}a.callback!==null&&a.lane!==0&&(e.flags|=64,p=l.effects,p===null?l.effects=[a]:p.push(a))}else y={eventTime:y,lane:p,tag:a.tag,payload:a.payload,callback:a.callback,next:null},d===null?(c=d=y,u=f):d=d.next=y,o|=p;if(a=a.next,a===null){if(a=l.shared.pending,a===null)break;p=a,a=p.next,p.next=null,l.lastBaseUpdate=p,l.shared.pending=null}}while(1);if(d===null&&(u=f),l.baseState=u,l.firstBaseUpdate=c,l.lastBaseUpdate=d,t=l.shared.interleaved,t!==null){l=t;do o|=l.lane,l=l.next;while(l!==t)}else s===null&&(l.shared.lanes=0);nn|=o,e.lanes=o,e.memoizedState=f}}function Ua(e,t,n){if(e=t.effects,t.effects=null,e!==null)for(t=0;tn?n:4,e(!0);var r=$s.transition;$s.transition={};try{e(!1),t()}finally{D=n,$s.transition=r}}function id(){return De().memoizedState}function $m(e,t,n){var r=It(e);if(n={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null},ad(e))ud(t,n);else if(n=Vc(e,t,n,r),n!==null){var l=xe();Ge(n,e,r,l),cd(n,t,r)}}function Dm(e,t,n){var r=It(e),l={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null};if(ad(e))ud(t,l);else{var s=e.alternate;if(e.lanes===0&&(s===null||s.lanes===0)&&(s=t.lastRenderedReducer,s!==null))try{var o=t.lastRenderedState,a=s(o,n);if(l.hasEagerState=!0,l.eagerState=a,Ke(a,o)){var u=t.interleaved;u===null?(l.next=l,Ci(t)):(l.next=u.next,u.next=l),t.interleaved=l;return}}catch{}finally{}n=Vc(e,t,l,r),n!==null&&(l=xe(),Ge(n,e,r,l),cd(n,t,r))}}function ad(e){var t=e.alternate;return e===X||t!==null&&t===X}function ud(e,t){cr=Dl=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function cd(e,t,n){if(n&4194240){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,di(e,n)}}var Ul={readContext:$e,useCallback:pe,useContext:pe,useEffect:pe,useImperativeHandle:pe,useInsertionEffect:pe,useLayoutEffect:pe,useMemo:pe,useReducer:pe,useRef:pe,useState:pe,useDebugValue:pe,useDeferredValue:pe,useTransition:pe,useMutableSource:pe,useSyncExternalStore:pe,useId:pe,unstable_isNewReconciler:!1},Um={readContext:$e,useCallback:function(e,t){return Ze().memoizedState=[e,t===void 0?null:t],e},useContext:$e,useEffect:Va,useImperativeHandle:function(e,t,n){return n=n!=null?n.concat([e]):null,hl(4194308,4,nd.bind(null,t,e),n)},useLayoutEffect:function(e,t){return hl(4194308,4,e,t)},useInsertionEffect:function(e,t){return hl(4,2,e,t)},useMemo:function(e,t){var n=Ze();return t=t===void 0?null:t,e=e(),n.memoizedState=[e,t],e},useReducer:function(e,t,n){var r=Ze();return t=n!==void 0?n(t):t,r.memoizedState=r.baseState=t,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:t},r.queue=e,e=e.dispatch=$m.bind(null,X,e),[r.memoizedState,e]},useRef:function(e){var t=Ze();return e={current:e},t.memoizedState=e},useState:Ba,useDebugValue:zi,useDeferredValue:function(e){return Ze().memoizedState=e},useTransition:function(){var e=Ba(!1),t=e[0];return e=Fm.bind(null,e[1]),Ze().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,n){var r=X,l=Ze();if(K){if(n===void 0)throw Error(k(407));n=n()}else{if(n=t(),ae===null)throw Error(k(349));tn&30||Kc(r,t,n)}l.memoizedState=n;var s={value:n,getSnapshot:t};return l.queue=s,Va(Jc.bind(null,r,s,e),[e]),r.flags|=2048,Tr(9,Yc.bind(null,r,s,n,t),void 0,null),n},useId:function(){var e=Ze(),t=ae.identifierPrefix;if(K){var n=at,r=it;n=(r&~(1<<32-Qe(r)-1)).toString(32)+n,t=":"+t+"R"+n,n=_r++,0<\/script>",e=e.removeChild(e.firstChild)):typeof r.is=="string"?e=o.createElement(n,{is:r.is}):(e=o.createElement(n),n==="select"&&(o=e,r.multiple?o.multiple=!0:r.size&&(o.size=r.size))):e=o.createElementNS(e,n),e[qe]=t,e[Sr]=r,wd(e,t,!1,!1),t.stateNode=e;e:{switch(o=io(n,r),n){case"dialog":Q("cancel",e),Q("close",e),l=r;break;case"iframe":case"object":case"embed":Q("load",e),l=r;break;case"video":case"audio":for(l=0;lFn&&(t.flags|=128,r=!0,Jn(s,!1),t.lanes=4194304)}else{if(!r)if(e=$l(o),e!==null){if(t.flags|=128,r=!0,n=e.updateQueue,n!==null&&(t.updateQueue=n,t.flags|=4),Jn(s,!0),s.tail===null&&s.tailMode==="hidden"&&!o.alternate&&!K)return me(t),null}else 2*ee()-s.renderingStartTime>Fn&&n!==1073741824&&(t.flags|=128,r=!0,Jn(s,!1),t.lanes=4194304);s.isBackwards?(o.sibling=t.child,t.child=o):(n=s.last,n!==null?n.sibling=o:t.child=o,s.last=o)}return s.tail!==null?(t=s.tail,s.rendering=t,s.tail=t.sibling,s.renderingStartTime=ee(),t.sibling=null,n=J.current,W(J,r?n&1|2:n&1),t):(me(t),null);case 22:case 23:return Di(),r=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==r&&(t.flags|=8192),r&&t.mode&1?Pe&1073741824&&(me(t),t.subtreeFlags&6&&(t.flags|=8192)):me(t),null;case 24:return null;case 25:return null}throw Error(k(156,t.tag))}function Ym(e,t){switch(wi(t),t.tag){case 1:return Ee(t.type)&&Rl(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return An(),G(Ce),G(ge),Ti(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 5:return Pi(t),null;case 13:if(G(J),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(k(340));zn()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return G(J),null;case 4:return An(),null;case 10:return Si(t.type._context),null;case 22:case 23:return Di(),null;case 24:return null;default:return null}}var rl=!1,he=!1,Jm=typeof WeakSet=="function"?WeakSet:Set,T=null;function kn(e,t){var n=e.ref;if(n!==null)if(typeof n=="function")try{n(null)}catch(r){q(e,t,r)}else n.current=null}function Lo(e,t,n){try{n()}catch(r){q(e,t,r)}}var eu=!1;function Xm(e,t){if(xo=Pl,e=_c(),xi(e)){if("selectionStart"in e)var n={start:e.selectionStart,end:e.selectionEnd};else e:{n=(n=e.ownerDocument)&&n.defaultView||window;var r=n.getSelection&&n.getSelection();if(r&&r.rangeCount!==0){n=r.anchorNode;var l=r.anchorOffset,s=r.focusNode;r=r.focusOffset;try{n.nodeType,s.nodeType}catch{n=null;break e}var o=0,a=-1,u=-1,c=0,d=0,f=e,p=null;t:for(;;){for(var y;f!==n||l!==0&&f.nodeType!==3||(a=o+l),f!==s||r!==0&&f.nodeType!==3||(u=o+r),f.nodeType===3&&(o+=f.nodeValue.length),(y=f.firstChild)!==null;)p=f,f=y;for(;;){if(f===e)break t;if(p===n&&++c===l&&(a=o),p===s&&++d===r&&(u=o),(y=f.nextSibling)!==null)break;f=p,p=f.parentNode}f=y}n=a===-1||u===-1?null:{start:a,end:u}}else n=null}n=n||{start:0,end:0}}else n=null;for(yo={focusedElem:e,selectionRange:n},Pl=!1,T=t;T!==null;)if(t=T,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,T=e;else for(;T!==null;){t=T;try{var w=t.alternate;if(t.flags&1024)switch(t.tag){case 0:case 11:case 15:break;case 1:if(w!==null){var x=w.memoizedProps,j=w.memoizedState,h=t.stateNode,m=h.getSnapshotBeforeUpdate(t.elementType===t.type?x:Ve(t.type,x),j);h.__reactInternalSnapshotBeforeUpdate=m}break;case 3:var g=t.stateNode.containerInfo;g.nodeType===1?g.textContent="":g.nodeType===9&&g.documentElement&&g.removeChild(g.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(k(163))}}catch(N){q(t,t.return,N)}if(e=t.sibling,e!==null){e.return=t.return,T=e;break}T=t.return}return w=eu,eu=!1,w}function dr(e,t,n){var r=t.updateQueue;if(r=r!==null?r.lastEffect:null,r!==null){var l=r=r.next;do{if((l.tag&e)===e){var s=l.destroy;l.destroy=void 0,s!==void 0&&Lo(t,n,s)}l=l.next}while(l!==r)}}function cs(e,t){if(t=t.updateQueue,t=t!==null?t.lastEffect:null,t!==null){var n=t=t.next;do{if((n.tag&e)===e){var r=n.create;n.destroy=r()}n=n.next}while(n!==t)}}function Ao(e){var t=e.ref;if(t!==null){var n=e.stateNode;switch(e.tag){case 5:e=n;break;default:e=n}typeof t=="function"?t(e):t.current=e}}function kd(e){var t=e.alternate;t!==null&&(e.alternate=null,kd(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[qe],delete t[Sr],delete t[jo],delete t[Im],delete t[zm])),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 Sd(e){return e.tag===5||e.tag===3||e.tag===4}function tu(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||Sd(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 Oo(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.nodeType===8?n.parentNode.insertBefore(e,t):n.insertBefore(e,t):(n.nodeType===8?(t=n.parentNode,t.insertBefore(e,n)):(t=n,t.appendChild(e)),n=n._reactRootContainer,n!=null||t.onclick!==null||(t.onclick=Ml));else if(r!==4&&(e=e.child,e!==null))for(Oo(e,t,n),e=e.sibling;e!==null;)Oo(e,t,n),e=e.sibling}function Fo(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.insertBefore(e,t):n.appendChild(e);else if(r!==4&&(e=e.child,e!==null))for(Fo(e,t,n),e=e.sibling;e!==null;)Fo(e,t,n),e=e.sibling}var ue=null,We=!1;function xt(e,t,n){for(n=n.child;n!==null;)Cd(e,t,n),n=n.sibling}function Cd(e,t,n){if(et&&typeof et.onCommitFiberUnmount=="function")try{et.onCommitFiberUnmount(ns,n)}catch{}switch(n.tag){case 5:he||kn(n,t);case 6:var r=ue,l=We;ue=null,xt(e,t,n),ue=r,We=l,ue!==null&&(We?(e=ue,n=n.stateNode,e.nodeType===8?e.parentNode.removeChild(n):e.removeChild(n)):ue.removeChild(n.stateNode));break;case 18:ue!==null&&(We?(e=ue,n=n.stateNode,e.nodeType===8?As(e.parentNode,n):e.nodeType===1&&As(e,n),yr(e)):As(ue,n.stateNode));break;case 4:r=ue,l=We,ue=n.stateNode.containerInfo,We=!0,xt(e,t,n),ue=r,We=l;break;case 0:case 11:case 14:case 15:if(!he&&(r=n.updateQueue,r!==null&&(r=r.lastEffect,r!==null))){l=r=r.next;do{var s=l,o=s.destroy;s=s.tag,o!==void 0&&(s&2||s&4)&&Lo(n,t,o),l=l.next}while(l!==r)}xt(e,t,n);break;case 1:if(!he&&(kn(n,t),r=n.stateNode,typeof r.componentWillUnmount=="function"))try{r.props=n.memoizedProps,r.state=n.memoizedState,r.componentWillUnmount()}catch(a){q(n,t,a)}xt(e,t,n);break;case 21:xt(e,t,n);break;case 22:n.mode&1?(he=(r=he)||n.memoizedState!==null,xt(e,t,n),he=r):xt(e,t,n);break;default:xt(e,t,n)}}function nu(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var n=e.stateNode;n===null&&(n=e.stateNode=new Jm),t.forEach(function(r){var l=oh.bind(null,e,r);n.has(r)||(n.add(r),r.then(l,l))})}}function Ue(e,t){var n=t.deletions;if(n!==null)for(var r=0;rl&&(l=o),r&=~s}if(r=l,r=ee()-r,r=(120>r?120:480>r?480:1080>r?1080:1920>r?1920:3e3>r?3e3:4320>r?4320:1960*qm(r/1960))-r,10e?16:e,Ct===null)var r=!1;else{if(e=Ct,Ct=null,Wl=0,L&6)throw Error(k(331));var l=L;for(L|=4,T=e.current;T!==null;){var s=T,o=s.child;if(T.flags&16){var a=s.deletions;if(a!==null){for(var u=0;uee()-Fi?Xt(e,0):Oi|=n),_e(e,t)}function Id(e,t){t===0&&(e.mode&1?(t=Kr,Kr<<=1,!(Kr&130023424)&&(Kr=4194304)):t=1);var n=xe();e=mt(e,t),e!==null&&(Lr(e,t,n),_e(e,n))}function sh(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),Id(e,n)}function oh(e,t){var n=0;switch(e.tag){case 13:var r=e.stateNode,l=e.memoizedState;l!==null&&(n=l.retryLane);break;case 19:r=e.stateNode;break;default:throw Error(k(314))}r!==null&&r.delete(t),Id(e,n)}var zd;zd=function(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps||Ce.current)ke=!0;else{if(!(e.lanes&n)&&!(t.flags&128))return ke=!1,Gm(e,t,n);ke=!!(e.flags&131072)}else ke=!1,K&&t.flags&1048576&&Fc(t,Ll,t.index);switch(t.lanes=0,t.tag){case 2:var r=t.type;gl(e,t),e=t.pendingProps;var l=In(t,ge.current);bn(t,n),l=Mi(null,t,r,e,l,n);var s=Ri();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,Ee(r)?(s=!0,Il(t)):s=!1,t.memoizedState=l.state!==null&&l.state!==void 0?l.state:null,Ei(t),l.updater=us,t.stateNode=l,l._reactInternals=t,Po(t,r,e,n),t=Mo(null,t,r,!0,s,n)):(t.tag=0,K&&s&&yi(t),ve(null,t,l,n),t=t.child),t;case 16:r=t.elementType;e:{switch(gl(e,t),e=t.pendingProps,l=r._init,r=l(r._payload),t.type=r,l=t.tag=ah(r),e=Ve(r,e),l){case 0:t=bo(null,t,r,e,n);break e;case 1:t=Xa(null,t,r,e,n);break e;case 11:t=Ya(null,t,r,e,n);break e;case 14:t=Ja(null,t,r,Ve(r.type,e),n);break e}throw Error(k(306,r,""))}return t;case 0:return r=t.type,l=t.pendingProps,l=t.elementType===r?l:Ve(r,l),bo(e,t,r,l,n);case 1:return r=t.type,l=t.pendingProps,l=t.elementType===r?l:Ve(r,l),Xa(e,t,r,l,n);case 3:e:{if(vd(t),e===null)throw Error(k(387));r=t.pendingProps,s=t.memoizedState,l=s.element,Wc(e,t),Fl(t,r,null,n);var o=t.memoizedState;if(r=o.element,s.isDehydrated)if(s={element:r,isDehydrated:!1,cache:o.cache,pendingSuspenseBoundaries:o.pendingSuspenseBoundaries,transitions:o.transitions},t.updateQueue.baseState=s,t.memoizedState=s,t.flags&256){l=On(Error(k(423)),t),t=Za(e,t,r,n,l);break e}else if(r!==l){l=On(Error(k(424)),t),t=Za(e,t,r,n,l);break e}else for(Te=bt(t.stateNode.containerInfo.firstChild),be=t,K=!0,He=null,n=Bc(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if(zn(),r===l){t=ht(e,t,n);break e}ve(e,t,r,n)}t=t.child}return t;case 5:return Hc(t),e===null&&Co(t),r=t.type,l=t.pendingProps,s=e!==null?e.memoizedProps:null,o=l.children,wo(r,l)?o=null:s!==null&&wo(r,s)&&(t.flags|=32),gd(e,t),ve(e,t,o,n),t.child;case 6:return e===null&&Co(t),null;case 13:return xd(e,t,n);case 4:return _i(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=Ln(t,null,r,n):ve(e,t,r,n),t.child;case 11:return r=t.type,l=t.pendingProps,l=t.elementType===r?l:Ve(r,l),Ya(e,t,r,l,n);case 7:return ve(e,t,t.pendingProps,n),t.child;case 8:return ve(e,t,t.pendingProps.children,n),t.child;case 12:return ve(e,t,t.pendingProps.children,n),t.child;case 10:e:{if(r=t.type._context,l=t.pendingProps,s=t.memoizedProps,o=l.value,W(Al,r._currentValue),r._currentValue=o,s!==null)if(Ke(s.value,o)){if(s.children===l.children&&!Ce.current){t=ht(e,t,n);break e}}else for(s=t.child,s!==null&&(s.return=t);s!==null;){var a=s.dependencies;if(a!==null){o=s.child;for(var u=a.firstContext;u!==null;){if(u.context===r){if(s.tag===1){u=ut(-1,n&-n),u.tag=2;var c=s.updateQueue;if(c!==null){c=c.shared;var d=c.pending;d===null?u.next=u:(u.next=d.next,d.next=u),c.pending=u}}s.lanes|=n,u=s.alternate,u!==null&&(u.lanes|=n),Eo(s.return,n,t),a.lanes|=n;break}u=u.next}}else if(s.tag===10)o=s.type===t.type?null:s.child;else if(s.tag===18){if(o=s.return,o===null)throw Error(k(341));o.lanes|=n,a=o.alternate,a!==null&&(a.lanes|=n),Eo(o,n,t),o=s.sibling}else o=s.child;if(o!==null)o.return=s;else for(o=s;o!==null;){if(o===t){o=null;break}if(s=o.sibling,s!==null){s.return=o.return,o=s;break}o=o.return}s=o}ve(e,t,l.children,n),t=t.child}return t;case 9:return l=t.type,r=t.pendingProps.children,bn(t,n),l=$e(l),r=r(l),t.flags|=1,ve(e,t,r,n),t.child;case 14:return r=t.type,l=Ve(r,t.pendingProps),l=Ve(r.type,l),Ja(e,t,r,l,n);case 15:return md(e,t,t.type,t.pendingProps,n);case 17:return r=t.type,l=t.pendingProps,l=t.elementType===r?l:Ve(r,l),gl(e,t),t.tag=1,Ee(r)?(e=!0,Il(t)):e=!1,bn(t,n),dd(t,r,l),Po(t,r,l,n),Mo(null,t,r,!0,e,n);case 19:return yd(e,t,n);case 22:return hd(e,t,n)}throw Error(k(156,t.tag))};function Ld(e,t){return ac(e,t)}function ih(e,t,n,r){this.tag=e,this.key=n,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=r,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Oe(e,t,n,r){return new ih(e,t,n,r)}function Bi(e){return e=e.prototype,!(!e||!e.isReactComponent)}function ah(e){if(typeof e=="function")return Bi(e)?1:0;if(e!=null){if(e=e.$$typeof,e===ii)return 11;if(e===ai)return 14}return 2}function zt(e,t){var n=e.alternate;return n===null?(n=Oe(e.tag,t,e.key,e.mode),n.elementType=e.elementType,n.type=e.type,n.stateNode=e.stateNode,n.alternate=e,e.alternate=n):(n.pendingProps=t,n.type=e.type,n.flags=0,n.subtreeFlags=0,n.deletions=null),n.flags=e.flags&14680064,n.childLanes=e.childLanes,n.lanes=e.lanes,n.child=e.child,n.memoizedProps=e.memoizedProps,n.memoizedState=e.memoizedState,n.updateQueue=e.updateQueue,t=e.dependencies,n.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},n.sibling=e.sibling,n.index=e.index,n.ref=e.ref,n}function yl(e,t,n,r,l,s){var o=2;if(r=e,typeof e=="function")Bi(e)&&(o=1);else if(typeof e=="string")o=5;else e:switch(e){case mn:return Zt(n.children,l,s,t);case oi:o=8,l|=8;break;case Xs:return e=Oe(12,n,t,l|2),e.elementType=Xs,e.lanes=s,e;case Zs:return e=Oe(13,n,t,l),e.elementType=Zs,e.lanes=s,e;case qs:return e=Oe(19,n,t,l),e.elementType=qs,e.lanes=s,e;case Hu:return fs(n,l,s,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case Vu:o=10;break e;case Wu:o=9;break e;case ii:o=11;break e;case ai:o=14;break e;case wt:o=16,r=null;break e}throw Error(k(130,e==null?e:typeof e,""))}return t=Oe(o,n,t,l),t.elementType=e,t.type=r,t.lanes=s,t}function Zt(e,t,n,r){return e=Oe(7,e,r,t),e.lanes=n,e}function fs(e,t,n,r){return e=Oe(22,e,r,t),e.elementType=Hu,e.lanes=n,e.stateNode={isHidden:!1},e}function Ws(e,t,n){return e=Oe(6,e,null,t),e.lanes=n,e}function Hs(e,t,n){return t=Oe(4,e.children!==null?e.children:[],e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function uh(e,t,n,r,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=Cs(0),this.expirationTimes=Cs(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Cs(0),this.identifierPrefix=r,this.onRecoverableError=l,this.mutableSourceEagerHydrationData=null}function Vi(e,t,n,r,l,s,o,a,u){return e=new uh(e,t,n,a,u),t===1?(t=1,s===!0&&(t|=8)):t=0,s=Oe(3,null,null,t),e.current=s,s.stateNode=e,s.memoizedState={element:r,isDehydrated:n,cache:null,transitions:null,pendingSuspenseBoundaries:null},Ei(s),e}function ch(e,t,n){var r=3"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE($d)}catch(e){console.error(e)}}$d(),$u.exports=Ie;var hh=$u.exports,cu=hh;Ys.createRoot=cu.createRoot,Ys.hydrateRoot=cu.hydrateRoot;/** + * @remix-run/router v1.23.0 + * + * Copyright (c) Remix Software Inc. + * + * This source code is licensed under the MIT license found in the + * LICENSE.md file in the root directory of this source tree. + * + * @license MIT + */function Mr(){return Mr=Object.assign?Object.assign.bind():function(e){for(var t=1;t"u")throw new Error(t)}function Dd(e,t){if(!e){typeof console<"u"&&console.warn(t);try{throw new Error(t)}catch{}}}function vh(){return Math.random().toString(36).substr(2,8)}function fu(e,t){return{usr:e.state,key:e.key,idx:t}}function Vo(e,t,n,r){return n===void 0&&(n=null),Mr({pathname:typeof e=="string"?e:e.pathname,search:"",hash:""},typeof t=="string"?Vn(t):t,{state:n,key:t&&t.key||r||vh()})}function Gl(e){let{pathname:t="/",search:n="",hash:r=""}=e;return n&&n!=="?"&&(t+=n.charAt(0)==="?"?n:"?"+n),r&&r!=="#"&&(t+=r.charAt(0)==="#"?r:"#"+r),t}function Vn(e){let t={};if(e){let n=e.indexOf("#");n>=0&&(t.hash=e.substr(n),e=e.substr(0,n));let r=e.indexOf("?");r>=0&&(t.search=e.substr(r),e=e.substr(0,r)),e&&(t.pathname=e)}return t}function xh(e,t,n,r){r===void 0&&(r={});let{window:l=document.defaultView,v5Compat:s=!1}=r,o=l.history,a=Et.Pop,u=null,c=d();c==null&&(c=0,o.replaceState(Mr({},o.state,{idx:c}),""));function d(){return(o.state||{idx:null}).idx}function f(){a=Et.Pop;let j=d(),h=j==null?null:j-c;c=j,u&&u({action:a,location:x.location,delta:h})}function p(j,h){a=Et.Push;let m=Vo(x.location,j,h);n&&n(m,j),c=d()+1;let g=fu(m,c),N=x.createHref(m);try{o.pushState(g,"",N)}catch(S){if(S instanceof DOMException&&S.name==="DataCloneError")throw S;l.location.assign(N)}s&&u&&u({action:a,location:x.location,delta:1})}function y(j,h){a=Et.Replace;let m=Vo(x.location,j,h);n&&n(m,j),c=d();let g=fu(m,c),N=x.createHref(m);o.replaceState(g,"",N),s&&u&&u({action:a,location:x.location,delta:0})}function w(j){let h=l.location.origin!=="null"?l.location.origin:l.location.href,m=typeof j=="string"?j:Gl(j);return m=m.replace(/ $/,"%20"),ne(h,"No window.location.(origin|href) available to create URL for href: "+m),new URL(m,h)}let x={get action(){return a},get location(){return e(l,o)},listen(j){if(u)throw new Error("A history only accepts one active listener");return l.addEventListener(du,f),u=j,()=>{l.removeEventListener(du,f),u=null}},createHref(j){return t(l,j)},createURL:w,encodeLocation(j){let h=w(j);return{pathname:h.pathname,search:h.search,hash:h.hash}},push:p,replace:y,go(j){return o.go(j)}};return x}var pu;(function(e){e.data="data",e.deferred="deferred",e.redirect="redirect",e.error="error"})(pu||(pu={}));function yh(e,t,n){return n===void 0&&(n="/"),wh(e,t,n,!1)}function wh(e,t,n,r){let l=typeof t=="string"?Vn(t):t,s=Gi(l.pathname||"/",n);if(s==null)return null;let o=Ud(e);Nh(o);let a=null;for(let u=0;a==null&&u{let u={relativePath:a===void 0?s.path||"":a,caseSensitive:s.caseSensitive===!0,childrenIndex:o,route:s};u.relativePath.startsWith("/")&&(ne(u.relativePath.startsWith(r),'Absolute route path "'+u.relativePath+'" nested under path '+('"'+r+'" is not valid. An absolute child route path ')+"must start with the combined path of all its parent routes."),u.relativePath=u.relativePath.slice(r.length));let c=Lt([r,u.relativePath]),d=n.concat(u);s.children&&s.children.length>0&&(ne(s.index!==!0,"Index routes must not have child routes. Please remove "+('all child routes from route path "'+c+'".')),Ud(s.children,t,d,c)),!(s.path==null&&!s.index)&&t.push({path:c,score:Ph(c,s.index),routesMeta:d})};return e.forEach((s,o)=>{var a;if(s.path===""||!((a=s.path)!=null&&a.includes("?")))l(s,o);else for(let u of Bd(s.path))l(s,o,u)}),t}function Bd(e){let t=e.split("/");if(t.length===0)return[];let[n,...r]=t,l=n.endsWith("?"),s=n.replace(/\?$/,"");if(r.length===0)return l?[s,""]:[s];let o=Bd(r.join("/")),a=[];return a.push(...o.map(u=>u===""?s:[s,u].join("/"))),l&&a.push(...o),a.map(u=>e.startsWith("/")&&u===""?"/":u)}function Nh(e){e.sort((t,n)=>t.score!==n.score?n.score-t.score:Th(t.routesMeta.map(r=>r.childrenIndex),n.routesMeta.map(r=>r.childrenIndex)))}const jh=/^:[\w-]+$/,kh=3,Sh=2,Ch=1,Eh=10,_h=-2,mu=e=>e==="*";function Ph(e,t){let n=e.split("/"),r=n.length;return n.some(mu)&&(r+=_h),t&&(r+=Sh),n.filter(l=>!mu(l)).reduce((l,s)=>l+(jh.test(s)?kh:s===""?Ch:Eh),r)}function Th(e,t){return e.length===t.length&&e.slice(0,-1).every((r,l)=>r===t[l])?e[e.length-1]-t[t.length-1]:0}function bh(e,t,n){n===void 0&&(n=!1);let{routesMeta:r}=e,l={},s="/",o=[];for(let a=0;a{let{paramName:p,isOptional:y}=d;if(p==="*"){let x=a[f]||"";o=s.slice(0,s.length-x.length).replace(/(.)\/+$/,"$1")}const w=a[f];return y&&!w?c[p]=void 0:c[p]=(w||"").replace(/%2F/g,"/"),c},{}),pathname:s,pathnameBase:o,pattern:e}}function Mh(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!0),Dd(e==="*"||!e.endsWith("*")||e.endsWith("/*"),'Route path "'+e+'" will be treated as if it were '+('"'+e.replace(/\*$/,"/*")+'" because the `*` character must ')+"always follow a `/` in the pattern. To get rid of this warning, "+('please change the route path to "'+e.replace(/\*$/,"/*")+'".'));let r=[],l="^"+e.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(o,a,u)=>(r.push({paramName:a,isOptional:u!=null}),u?"/?([^\\/]+)?":"/([^\\/]+)"));return e.endsWith("*")?(r.push({paramName:"*"}),l+=e==="*"||e==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):n?l+="\\/*$":e!==""&&e!=="/"&&(l+="(?:(?=\\/|$))"),[new RegExp(l,t?void 0:"i"),r]}function Rh(e){try{return e.split("/").map(t=>decodeURIComponent(t).replace(/\//g,"%2F")).join("/")}catch(t){return Dd(!1,'The URL path "'+e+'" could not be decoded because it is is a malformed URL segment. This is probably due to a bad percent '+("encoding ("+t+").")),e}}function Gi(e,t){if(t==="/")return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let n=t.endsWith("/")?t.length-1:t.length,r=e.charAt(n);return r&&r!=="/"?null:e.slice(n)||"/"}function Ih(e,t){t===void 0&&(t="/");let{pathname:n,search:r="",hash:l=""}=typeof e=="string"?Vn(e):e;return{pathname:n?n.startsWith("/")?n:zh(n,t):t,search:Oh(r),hash:Fh(l)}}function zh(e,t){let n=t.replace(/\/+$/,"").split("/");return e.split("/").forEach(l=>{l===".."?n.length>1&&n.pop():l!=="."&&n.push(l)}),n.length>1?n.join("/"):"/"}function Qs(e,t,n,r){return"Cannot include a '"+e+"' character in a manually specified "+("`to."+t+"` field ["+JSON.stringify(r)+"]. Please separate it out to the ")+("`to."+n+"` field. Alternatively you may provide the full path as ")+'a string in and the router will parse it for you.'}function Lh(e){return e.filter((t,n)=>n===0||t.route.path&&t.route.path.length>0)}function Vd(e,t){let n=Lh(e);return t?n.map((r,l)=>l===n.length-1?r.pathname:r.pathnameBase):n.map(r=>r.pathnameBase)}function Wd(e,t,n,r){r===void 0&&(r=!1);let l;typeof e=="string"?l=Vn(e):(l=Mr({},e),ne(!l.pathname||!l.pathname.includes("?"),Qs("?","pathname","search",l)),ne(!l.pathname||!l.pathname.includes("#"),Qs("#","pathname","hash",l)),ne(!l.search||!l.search.includes("#"),Qs("#","search","hash",l)));let s=e===""||l.pathname==="",o=s?"/":l.pathname,a;if(o==null)a=n;else{let f=t.length-1;if(!r&&o.startsWith("..")){let p=o.split("/");for(;p[0]==="..";)p.shift(),f-=1;l.pathname=p.join("/")}a=f>=0?t[f]:"/"}let u=Ih(l,a),c=o&&o!=="/"&&o.endsWith("/"),d=(s||o===".")&&n.endsWith("/");return!u.pathname.endsWith("/")&&(c||d)&&(u.pathname+="/"),u}const Lt=e=>e.join("/").replace(/\/\/+/g,"/"),Ah=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),Oh=e=>!e||e==="?"?"":e.startsWith("?")?e:"?"+e,Fh=e=>!e||e==="#"?"":e.startsWith("#")?e:"#"+e;function $h(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.internal=="boolean"&&"data"in e}const Hd=["post","put","patch","delete"];new Set(Hd);const Dh=["get",...Hd];new Set(Dh);/** + * React Router v6.30.1 + * + * Copyright (c) Remix Software Inc. + * + * This source code is licensed under the MIT license found in the + * LICENSE.md file in the root directory of this source tree. + * + * @license MIT + */function Rr(){return Rr=Object.assign?Object.assign.bind():function(e){for(var t=1;t{a.current=!0}),v.useCallback(function(c,d){if(d===void 0&&(d={}),!a.current)return;if(typeof c=="number"){r.go(c);return}let f=Wd(c,JSON.parse(o),s,d.relative==="path");e==null&&t!=="/"&&(f.pathname=f.pathname==="/"?t:Lt([t,f.pathname])),(d.replace?r.replace:r.push)(f,d.state,d)},[t,r,o,s,e])}const Hh=v.createContext(null);function Qh(e){let t=v.useContext(Ut).outlet;return t&&v.createElement(Hh.Provider,{value:e},t)}function Kd(e,t){let{relative:n}=t===void 0?{}:t,{future:r}=v.useContext(on),{matches:l}=v.useContext(Ut),{pathname:s}=Dr(),o=JSON.stringify(Vd(l,r.v7_relativeSplatPath));return v.useMemo(()=>Wd(e,JSON.parse(o),s,n==="path"),[e,o,s,n])}function Gh(e,t){return Kh(e,t)}function Kh(e,t,n,r){$r()||ne(!1);let{navigator:l}=v.useContext(on),{matches:s}=v.useContext(Ut),o=s[s.length-1],a=o?o.params:{};o&&o.pathname;let u=o?o.pathnameBase:"/";o&&o.route;let c=Dr(),d;if(t){var f;let j=typeof t=="string"?Vn(t):t;u==="/"||(f=j.pathname)!=null&&f.startsWith(u)||ne(!1),d=j}else d=c;let p=d.pathname||"/",y=p;if(u!=="/"){let j=u.replace(/^\//,"").split("/");y="/"+p.replace(/^\//,"").split("/").slice(j.length).join("/")}let w=yh(e,{pathname:y}),x=qh(w&&w.map(j=>Object.assign({},j,{params:Object.assign({},a,j.params),pathname:Lt([u,l.encodeLocation?l.encodeLocation(j.pathname).pathname:j.pathname]),pathnameBase:j.pathnameBase==="/"?u:Lt([u,l.encodeLocation?l.encodeLocation(j.pathnameBase).pathname:j.pathnameBase])})),s,n,r);return t&&x?v.createElement(vs.Provider,{value:{location:Rr({pathname:"/",search:"",hash:"",state:null,key:"default"},d),navigationType:Et.Pop}},x):x}function Yh(){let e=rg(),t=$h(e)?e.status+" "+e.statusText:e instanceof Error?e.message:JSON.stringify(e),n=e instanceof Error?e.stack:null,l={padding:"0.5rem",backgroundColor:"rgba(200,200,200, 0.5)"},s=null;return v.createElement(v.Fragment,null,v.createElement("h2",null,"Unexpected Application Error!"),v.createElement("h3",{style:{fontStyle:"italic"}},t),n?v.createElement("pre",{style:l},n):null,s)}const Jh=v.createElement(Yh,null);class Xh extends v.Component{constructor(t){super(t),this.state={location:t.location,revalidation:t.revalidation,error:t.error}}static getDerivedStateFromError(t){return{error:t}}static getDerivedStateFromProps(t,n){return n.location!==t.location||n.revalidation!=="idle"&&t.revalidation==="idle"?{error:t.error,location:t.location,revalidation:t.revalidation}:{error:t.error!==void 0?t.error:n.error,location:n.location,revalidation:t.revalidation||n.revalidation}}componentDidCatch(t,n){console.error("React Router caught the following error during render",t,n)}render(){return this.state.error!==void 0?v.createElement(Ut.Provider,{value:this.props.routeContext},v.createElement(Qd.Provider,{value:this.state.error,children:this.props.component})):this.props.children}}function Zh(e){let{routeContext:t,match:n,children:r}=e,l=v.useContext(Ki);return l&&l.static&&l.staticContext&&(n.route.errorElement||n.route.ErrorBoundary)&&(l.staticContext._deepestRenderedBoundaryId=n.route.id),v.createElement(Ut.Provider,{value:t},r)}function qh(e,t,n,r){var l;if(t===void 0&&(t=[]),n===void 0&&(n=null),r===void 0&&(r=null),e==null){var s;if(!n)return null;if(n.errors)e=n.matches;else if((s=r)!=null&&s.v7_partialHydration&&t.length===0&&!n.initialized&&n.matches.length>0)e=n.matches;else return null}let o=e,a=(l=n)==null?void 0:l.errors;if(a!=null){let d=o.findIndex(f=>f.route.id&&(a==null?void 0:a[f.route.id])!==void 0);d>=0||ne(!1),o=o.slice(0,Math.min(o.length,d+1))}let u=!1,c=-1;if(n&&r&&r.v7_partialHydration)for(let d=0;d=0?o=o.slice(0,c+1):o=[o[0]];break}}}return o.reduceRight((d,f,p)=>{let y,w=!1,x=null,j=null;n&&(y=a&&f.route.id?a[f.route.id]:void 0,x=f.route.errorElement||Jh,u&&(c<0&&p===0?(sg("route-fallback",!1),w=!0,j=null):c===p&&(w=!0,j=f.route.hydrateFallbackElement||null)));let h=t.concat(o.slice(0,p+1)),m=()=>{let g;return y?g=x:w?g=j:f.route.Component?g=v.createElement(f.route.Component,null):f.route.element?g=f.route.element:g=d,v.createElement(Zh,{match:f,routeContext:{outlet:d,matches:h,isDataRoute:n!=null},children:g})};return n&&(f.route.ErrorBoundary||f.route.errorElement||p===0)?v.createElement(Xh,{location:n.location,revalidation:n.revalidation,component:x,error:y,children:m(),routeContext:{outlet:null,matches:h,isDataRoute:!0}}):m()},null)}var Yd=function(e){return e.UseBlocker="useBlocker",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e}(Yd||{}),Kl=function(e){return e.UseBlocker="useBlocker",e.UseLoaderData="useLoaderData",e.UseActionData="useActionData",e.UseRouteError="useRouteError",e.UseNavigation="useNavigation",e.UseRouteLoaderData="useRouteLoaderData",e.UseMatches="useMatches",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e.UseRouteId="useRouteId",e}(Kl||{});function eg(e){let t=v.useContext(Ki);return t||ne(!1),t}function tg(e){let t=v.useContext(Uh);return t||ne(!1),t}function ng(e){let t=v.useContext(Ut);return t||ne(!1),t}function Jd(e){let t=ng(),n=t.matches[t.matches.length-1];return n.route.id||ne(!1),n.route.id}function rg(){var e;let t=v.useContext(Qd),n=tg(Kl.UseRouteError),r=Jd(Kl.UseRouteError);return t!==void 0?t:(e=n.errors)==null?void 0:e[r]}function lg(){let{router:e}=eg(Yd.UseNavigateStable),t=Jd(Kl.UseNavigateStable),n=v.useRef(!1);return Gd(()=>{n.current=!0}),v.useCallback(function(l,s){s===void 0&&(s={}),n.current&&(typeof l=="number"?e.navigate(l):e.navigate(l,Rr({fromRouteId:t},s)))},[e,t])}const gu={};function sg(e,t,n){!t&&!gu[e]&&(gu[e]=!0)}function og(e,t){e==null||e.v7_startTransition,(e==null?void 0:e.v7_relativeSplatPath)===void 0&&(!t||t.v7_relativeSplatPath),t&&(t.v7_fetcherPersist,t.v7_normalizeFormMethod,t.v7_partialHydration,t.v7_skipActionErrorRevalidation)}function ig(e){return Qh(e.context)}function Xe(e){ne(!1)}function ag(e){let{basename:t="/",children:n=null,location:r,navigationType:l=Et.Pop,navigator:s,static:o=!1,future:a}=e;$r()&&ne(!1);let u=t.replace(/^\/*/,"/"),c=v.useMemo(()=>({basename:u,navigator:s,static:o,future:Rr({v7_relativeSplatPath:!1},a)}),[u,a,s,o]);typeof r=="string"&&(r=Vn(r));let{pathname:d="/",search:f="",hash:p="",state:y=null,key:w="default"}=r,x=v.useMemo(()=>{let j=Gi(d,u);return j==null?null:{location:{pathname:j,search:f,hash:p,state:y,key:w},navigationType:l}},[u,d,f,p,y,w,l]);return x==null?null:v.createElement(on.Provider,{value:c},v.createElement(vs.Provider,{children:n,value:x}))}function ug(e){let{children:t,location:n}=e;return Gh(Wo(t),n)}new Promise(()=>{});function Wo(e,t){t===void 0&&(t=[]);let n=[];return v.Children.forEach(e,(r,l)=>{if(!v.isValidElement(r))return;let s=[...t,l];if(r.type===v.Fragment){n.push.apply(n,Wo(r.props.children,s));return}r.type!==Xe&&ne(!1),!r.props.index||!r.props.children||ne(!1);let o={id:r.props.id||s.join("-"),caseSensitive:r.props.caseSensitive,element:r.props.element,Component:r.props.Component,index:r.props.index,path:r.props.path,loader:r.props.loader,action:r.props.action,errorElement:r.props.errorElement,ErrorBoundary:r.props.ErrorBoundary,hasErrorBoundary:r.props.ErrorBoundary!=null||r.props.errorElement!=null,shouldRevalidate:r.props.shouldRevalidate,handle:r.props.handle,lazy:r.props.lazy};r.props.children&&(o.children=Wo(r.props.children,s)),n.push(o)}),n}/** + * React Router DOM v6.30.1 + * + * Copyright (c) Remix Software Inc. + * + * This source code is licensed under the MIT license found in the + * LICENSE.md file in the root directory of this source tree. + * + * @license MIT + */function Ho(){return Ho=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0)&&(n[l]=e[l]);return n}function dg(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}function fg(e,t){return e.button===0&&(!t||t==="_self")&&!dg(e)}const pg=["onClick","relative","reloadDocument","replace","state","target","to","preventScrollReset","viewTransition"],mg="6";try{window.__reactRouterVersion=mg}catch{}const hg="startTransition",vu=ni[hg];function gg(e){let{basename:t,children:n,future:r,window:l}=e,s=v.useRef();s.current==null&&(s.current=gh({window:l,v5Compat:!0}));let o=s.current,[a,u]=v.useState({action:o.action,location:o.location}),{v7_startTransition:c}=r||{},d=v.useCallback(f=>{c&&vu?vu(()=>u(f)):u(f)},[u,c]);return v.useLayoutEffect(()=>o.listen(d),[o,d]),v.useEffect(()=>og(r),[r]),v.createElement(ag,{basename:t,children:n,location:a.location,navigationType:a.action,navigator:o,future:r})}const vg=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u",xg=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,yg=v.forwardRef(function(t,n){let{onClick:r,relative:l,reloadDocument:s,replace:o,state:a,target:u,to:c,preventScrollReset:d,viewTransition:f}=t,p=cg(t,pg),{basename:y}=v.useContext(on),w,x=!1;if(typeof c=="string"&&xg.test(c)&&(w=c,vg))try{let g=new URL(window.location.href),N=c.startsWith("//")?new URL(g.protocol+c):new URL(c),S=Gi(N.pathname,y);N.origin===g.origin&&S!=null?c=S+N.search+N.hash:x=!0}catch{}let j=Bh(c,{relative:l}),h=wg(c,{replace:o,state:a,target:u,preventScrollReset:d,relative:l,viewTransition:f});function m(g){r&&r(g),g.defaultPrevented||h(g)}return v.createElement("a",Ho({},p,{href:w||j,onClick:x||s?r:m,ref:n,target:u}))});var xu;(function(e){e.UseScrollRestoration="useScrollRestoration",e.UseSubmit="useSubmit",e.UseSubmitFetcher="useSubmitFetcher",e.UseFetcher="useFetcher",e.useViewTransitionState="useViewTransitionState"})(xu||(xu={}));var yu;(function(e){e.UseFetcher="useFetcher",e.UseFetchers="useFetchers",e.UseScrollRestoration="useScrollRestoration"})(yu||(yu={}));function wg(e,t){let{target:n,replace:r,state:l,preventScrollReset:s,relative:o,viewTransition:a}=t===void 0?{}:t,u=Vh(),c=Dr(),d=Kd(e,{relative:o});return v.useCallback(f=>{if(fg(f,n)){f.preventDefault();let p=r!==void 0?r:Gl(c)===Gl(d);u(e,{replace:p,state:l,preventScrollReset:s,relative:o,viewTransition:a})}},[c,u,d,r,l,n,e,s,o,a])}function Xd(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e)){var l=e.length;for(t=0;te&&(t=0,r=n,n=new Map)}return{get:function(o){var a=n.get(o);if(a!==void 0)return a;if((a=r.get(o))!==void 0)return l(o,a),a},set:function(o,a){n.has(o)?n.set(o,a):l(o,a)}}}var tf="!";function Pg(e){var t=e.separator||":",n=t.length===1,r=t[0],l=t.length;return function(o){for(var a=[],u=0,c=0,d,f=0;fc?d-c:void 0;return{modifiers:a,hasImportantModifier:w,baseClassName:x,maybePostfixModifierPosition:j}}}function Tg(e){if(e.length<=1)return e;var t=[],n=[];return e.forEach(function(r){var l=r[0]==="[";l?(t.push.apply(t,n.sort().concat([r])),n=[]):n.push(r)}),t.push.apply(t,n.sort()),t}function bg(e){return{cache:_g(e.cacheSize),splitModifiers:Pg(e),...jg(e)}}var Mg=/\s+/;function Rg(e,t){var n=t.splitModifiers,r=t.getClassGroupId,l=t.getConflictingClassGroupIds,s=new Set;return e.trim().split(Mg).map(function(o){var a=n(o),u=a.modifiers,c=a.hasImportantModifier,d=a.baseClassName,f=a.maybePostfixModifierPosition,p=r(f?d.substring(0,f):d),y=!!f;if(!p){if(!f)return{isTailwindClass:!1,originalClassName:o};if(p=r(d),!p)return{isTailwindClass:!1,originalClassName:o};y=!1}var w=Tg(u).join(":"),x=c?w+tf:w;return{isTailwindClass:!0,modifierId:x,classGroupId:p,originalClassName:o,hasPostfixModifier:y}}).reverse().filter(function(o){if(!o.isTailwindClass)return!0;var a=o.modifierId,u=o.classGroupId,c=o.hasPostfixModifier,d=a+u;return s.has(d)?!1:(s.add(d),l(u,c).forEach(function(f){return s.add(a+f)}),!0)}).reverse().map(function(o){return o.originalClassName}).join(" ")}function Ig(){for(var e=arguments.length,t=new Array(e),n=0;ne.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),Jg=e=>e.replace(/^([A-Z])|[\s-_]+(\w)/g,(t,n,r)=>r?r.toUpperCase():n.toLowerCase()),ku=e=>{const t=Jg(e);return t.charAt(0).toUpperCase()+t.slice(1)},lf=(...e)=>e.filter((t,n,r)=>!!t&&t.trim()!==""&&r.indexOf(t)===n).join(" ").trim(),Xg=e=>{for(const t in e)if(t.startsWith("aria-")||t==="role"||t==="title")return!0};/** + * @license lucide-react v0.542.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */var Zg={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"};/** + * @license lucide-react v0.542.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const qg=v.forwardRef(({color:e="currentColor",size:t=24,strokeWidth:n=2,absoluteStrokeWidth:r,className:l="",children:s,iconNode:o,...a},u)=>v.createElement("svg",{ref:u,...Zg,width:t,height:t,stroke:e,strokeWidth:r?Number(n)*24/Number(t):n,className:lf("lucide",l),...!s&&!Xg(a)&&{"aria-hidden":"true"},...a},[...o.map(([c,d])=>v.createElement(c,d)),...Array.isArray(s)?s:[s]]));/** + * @license lucide-react v0.542.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const F=(e,t)=>{const n=v.forwardRef(({className:r,...l},s)=>v.createElement(qg,{ref:s,iconNode:t,className:lf(`lucide-${Yg(ku(e))}`,`lucide-${e}`,r),...l}));return n.displayName=ku(e),n};/** + * @license lucide-react v0.542.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const ev=[["path",{d:"m12 19-7-7 7-7",key:"1l729n"}],["path",{d:"M19 12H5",key:"x3x0zl"}]],tv=F("arrow-left",ev);/** + * @license lucide-react v0.542.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const nv=[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"m12 5 7 7-7 7",key:"xquz4c"}]],wl=F("arrow-right",nv);/** + * @license lucide-react v0.542.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const rv=[["path",{d:"m15.477 12.89 1.515 8.526a.5.5 0 0 1-.81.47l-3.58-2.687a1 1 0 0 0-1.197 0l-3.586 2.686a.5.5 0 0 1-.81-.469l1.514-8.526",key:"1yiouv"}],["circle",{cx:"12",cy:"8",r:"6",key:"1vp47v"}]],sf=F("award",rv);/** + * @license lucide-react v0.542.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const lv=[["path",{d:"M12 7v14",key:"1akyts"}],["path",{d:"M3 18a1 1 0 0 1-1-1V4a1 1 0 0 1 1-1h5a4 4 0 0 1 4 4 4 4 0 0 1 4-4h5a1 1 0 0 1 1 1v13a1 1 0 0 1-1 1h-6a3 3 0 0 0-3 3 3 3 0 0 0-3-3z",key:"ruj8y"}]],Yl=F("book-open",lv);/** + * @license lucide-react v0.542.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const sv=[["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"}]],Me=F("bot",sv);/** + * @license lucide-react v0.542.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const ov=[["path",{d:"M12 18V5",key:"adv99a"}],["path",{d:"M15 13a4.17 4.17 0 0 1-3-4 4.17 4.17 0 0 1-3 4",key:"1e3is1"}],["path",{d:"M17.598 6.5A3 3 0 1 0 12 5a3 3 0 1 0-5.598 1.5",key:"1gqd8o"}],["path",{d:"M17.997 5.125a4 4 0 0 1 2.526 5.77",key:"iwvgf7"}],["path",{d:"M18 18a4 4 0 0 0 2-7.464",key:"efp6ie"}],["path",{d:"M19.967 17.483A4 4 0 1 1 12 18a4 4 0 1 1-7.967-.517",key:"1gq6am"}],["path",{d:"M6 18a4 4 0 0 1-2-7.464",key:"k1g0md"}],["path",{d:"M6.003 5.125a4 4 0 0 0-2.526 5.77",key:"q97ue3"}]],$n=F("brain",ov);/** + * @license lucide-react v0.542.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const iv=[["path",{d:"M21.801 10A10 10 0 1 1 17 3.335",key:"yps3ct"}],["path",{d:"m9 11 3 3L22 4",key:"1pflzl"}]],av=F("circle-check-big",iv);/** + * @license lucide-react v0.542.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const uv=[["path",{d:"M17.5 19H9a7 7 0 1 1 6.71-9h1.79a4.5 4.5 0 1 1 0 9Z",key:"p7xjir"}]],of=F("cloud",uv);/** + * @license lucide-react v0.542.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const cv=[["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"}]],af=F("copy",cv);/** + * @license lucide-react v0.542.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const dv=[["path",{d:"M12 20v2",key:"1lh1kg"}],["path",{d:"M12 2v2",key:"tus03m"}],["path",{d:"M17 20v2",key:"1rnc9c"}],["path",{d:"M17 2v2",key:"11trls"}],["path",{d:"M2 12h2",key:"1t8f8n"}],["path",{d:"M2 17h2",key:"7oei6x"}],["path",{d:"M2 7h2",key:"asdhe0"}],["path",{d:"M20 12h2",key:"1q8mjw"}],["path",{d:"M20 17h2",key:"1fpfkl"}],["path",{d:"M20 7h2",key:"1o8tra"}],["path",{d:"M7 20v2",key:"4gnj0m"}],["path",{d:"M7 2v2",key:"1i4yhu"}],["rect",{x:"4",y:"4",width:"16",height:"16",rx:"2",key:"1vbyd7"}],["rect",{x:"8",y:"8",width:"8",height:"8",rx:"1",key:"z9xiuo"}]],fv=F("cpu",dv);/** + * @license lucide-react v0.542.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const pv=[["path",{d:"M12 15V3",key:"m9g1x1"}],["path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4",key:"ih7n3h"}],["path",{d:"m7 10 5 5 5-5",key:"brsn70"}]],Ji=F("download",pv);/** + * @license lucide-react v0.542.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const mv=[["line",{x1:"22",x2:"2",y1:"12",y2:"12",key:"1y58io"}],["path",{d:"M5.45 5.11 2 12v6a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2v-6l-3.45-6.89A2 2 0 0 0 16.76 4H7.24a2 2 0 0 0-1.79 1.11z",key:"oot6mr"}],["line",{x1:"6",x2:"6.01",y1:"16",y2:"16",key:"sgf278"}],["line",{x1:"10",x2:"10.01",y1:"16",y2:"16",key:"1l4acy"}]],uf=F("hard-drive",mv);/** + * @license lucide-react v0.542.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const hv=[["path",{d:"M2 9.5a5.5 5.5 0 0 1 9.591-3.676.56.56 0 0 0 .818 0A5.49 5.49 0 0 1 22 9.5c0 2.29-1.5 4-3 5.5l-5.492 5.313a2 2 0 0 1-3 .019L5 15c-1.5-1.5-3-3.2-3-5.5",key:"mvr1a0"}]],Cn=F("heart",hv);/** + * @license lucide-react v0.542.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const gv=[["path",{d:"M15 21v-8a1 1 0 0 0-1-1h-4a1 1 0 0 0-1 1v8",key:"5wwlr5"}],["path",{d:"M3 10a2 2 0 0 1 .709-1.528l7-5.999a2 2 0 0 1 2.582 0l7 5.999A2 2 0 0 1 21 10v9a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2z",key:"1d0kgt"}]],vv=F("house",gv);/** + * @license lucide-react v0.542.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const xv=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 16v-4",key:"1dtifu"}],["path",{d:"M12 8h.01",key:"e9boi3"}]],cf=F("info",xv);/** + * @license lucide-react v0.542.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const yv=[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]],Ko=F("loader-circle",yv);/** + * @license lucide-react v0.542.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const wv=[["path",{d:"M22 17a2 2 0 0 1-2 2H6.828a2 2 0 0 0-1.414.586l-2.202 2.202A.71.71 0 0 1 2 21.286V5a2 2 0 0 1 2-2h16a2 2 0 0 1 2 2z",key:"18887p"}]],ct=F("message-square",wv);/** + * @license lucide-react v0.542.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const Nv=[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]],Yo=F("plus",Nv);/** + * @license lucide-react v0.542.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const jv=[["path",{d:"M15.2 3a2 2 0 0 1 1.4.6l3.8 3.8a2 2 0 0 1 .6 1.4V19a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2z",key:"1c8476"}],["path",{d:"M17 21v-7a1 1 0 0 0-1-1H8a1 1 0 0 0-1 1v7",key:"1ydtos"}],["path",{d:"M7 3v4a1 1 0 0 0 1 1h7",key:"t51u73"}]],kv=F("save",jv);/** + * @license lucide-react v0.542.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const Sv=[["path",{d:"M14.536 21.686a.5.5 0 0 0 .937-.024l6.5-19a.496.496 0 0 0-.635-.635l-19 6.5a.5.5 0 0 0-.024.937l7.93 3.18a2 2 0 0 1 1.112 1.11z",key:"1ffxy3"}],["path",{d:"m21.854 2.147-10.94 10.939",key:"12cjpa"}]],df=F("send",Sv);/** + * @license lucide-react v0.542.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const Cv=[["rect",{width:"20",height:"8",x:"2",y:"2",rx:"2",ry:"2",key:"ngkwjq"}],["rect",{width:"20",height:"8",x:"2",y:"14",rx:"2",ry:"2",key:"iecqi9"}],["line",{x1:"6",x2:"6.01",y1:"6",y2:"6",key:"16zg32"}],["line",{x1:"6",x2:"6.01",y1:"18",y2:"18",key:"nzw8ys"}]],Ev=F("server",Cv);/** + * @license lucide-react v0.542.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const _v=[["path",{d:"M9.671 4.136a2.34 2.34 0 0 1 4.659 0 2.34 2.34 0 0 0 3.319 1.915 2.34 2.34 0 0 1 2.33 4.033 2.34 2.34 0 0 0 0 3.831 2.34 2.34 0 0 1-2.33 4.033 2.34 2.34 0 0 0-3.319 1.915 2.34 2.34 0 0 1-4.659 0 2.34 2.34 0 0 0-3.32-1.915 2.34 2.34 0 0 1-2.33-4.033 2.34 2.34 0 0 0 0-3.831A2.34 2.34 0 0 1 6.35 6.051a2.34 2.34 0 0 0 3.319-1.915",key:"1i5ecw"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]],Xi=F("settings",_v);/** + * @license lucide-react v0.542.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const Pv=[["path",{d:"M12 2v13",key:"1km8f5"}],["path",{d:"m16 6-4-4-4 4",key:"13yo43"}],["path",{d:"M4 12v8a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2v-8",key:"1b2hhj"}]],Tv=F("share",Pv);/** + * @license lucide-react v0.542.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const bv=[["path",{d:"M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z",key:"oel41y"}]],Jo=F("shield",bv);/** + * @license lucide-react v0.542.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const Mv=[["path",{d:"M11.017 2.814a1 1 0 0 1 1.966 0l1.051 5.558a2 2 0 0 0 1.594 1.594l5.558 1.051a1 1 0 0 1 0 1.966l-5.558 1.051a2 2 0 0 0-1.594 1.594l-1.051 5.558a1 1 0 0 1-1.966 0l-1.051-5.558a2 2 0 0 0-1.594-1.594l-5.558-1.051a1 1 0 0 1 0-1.966l5.558-1.051a2 2 0 0 0 1.594-1.594z",key:"1s2grr"}],["path",{d:"M20 2v4",key:"1rf3ol"}],["path",{d:"M22 4h-4",key:"gwowj6"}],["circle",{cx:"4",cy:"20",r:"2",key:"6kqj1y"}]],Jl=F("sparkles",Mv);/** + * @license lucide-react v0.542.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const Rv=[["path",{d:"M11.525 2.295a.53.53 0 0 1 .95 0l2.31 4.679a2.123 2.123 0 0 0 1.595 1.16l5.166.756a.53.53 0 0 1 .294.904l-3.736 3.638a2.123 2.123 0 0 0-.611 1.878l.882 5.14a.53.53 0 0 1-.771.56l-4.618-2.428a2.122 2.122 0 0 0-1.973 0L6.396 21.01a.53.53 0 0 1-.77-.56l.881-5.139a2.122 2.122 0 0 0-.611-1.879L2.16 9.795a.53.53 0 0 1 .294-.906l5.165-.755a2.122 2.122 0 0 0 1.597-1.16z",key:"r04s7s"}]],ff=F("star",Rv);/** + * @license lucide-react v0.542.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const Iv=[["path",{d:"M10 11v6",key:"nco0om"}],["path",{d:"M14 11v6",key:"outv1u"}],["path",{d:"M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6",key:"miytrc"}],["path",{d:"M3 6h18",key:"d0wm0j"}],["path",{d:"M8 6V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2",key:"e791ji"}]],pf=F("trash-2",Iv);/** + * @license lucide-react v0.542.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const zv=[["path",{d:"M16 7h6v6",key:"box55l"}],["path",{d:"m22 7-8.5 8.5-5-5L2 17",key:"1t1m79"}]],Lv=F("trending-up",zv);/** + * @license lucide-react v0.542.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const Av=[["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"}]],mf=F("user",Av);/** + * @license lucide-react v0.542.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const Ov=[["path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2",key:"1yyitq"}],["path",{d:"M16 3.128a4 4 0 0 1 0 7.744",key:"16gr8j"}],["path",{d:"M22 21v-2a4 4 0 0 0-3-3.87",key:"kshegd"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}]],Ir=F("users",Ov);/** + * @license lucide-react v0.542.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const Fv=[["path",{d:"M4 14a1 1 0 0 1-.78-1.63l9.9-10.2a.5.5 0 0 1 .86.46l-1.92 6.02A1 1 0 0 0 13 10h7a1 1 0 0 1 .78 1.63l-9.9 10.2a.5.5 0 0 1-.86-.46l1.92-6.02A1 1 0 0 0 11 14z",key:"1xq2db"}]],Xl=F("zap",Fv),$v=[{name:"Home",href:"/",icon:vv,description:"Overview and getting started"},{name:"Quick Chat",href:"/chat",icon:ct,description:"Simple AI conversations"},{name:"Assistant Builder",href:"/assistant-builder",icon:Me,description:"Create custom AI assistants"},{name:"My Assistants",href:"/assistants",icon:Ir,description:"Manage your saved assistants"},{name:"Community",href:"/community",icon:Yl,description:"Discover assistant templates"},{name:"Models",href:"/models",icon:$n,description:"Manage AI models"},{name:"Settings",href:"/settings",icon:Xi,description:"Application settings"}];function Dv(){const e=Dr();return i.jsxs("div",{className:"flex h-full flex-col bg-background border-r",children:[i.jsx("div",{className:"p-6 border-b",children:i.jsxs("div",{className:"flex items-center gap-2",children:[i.jsx("div",{className:"w-8 h-8 bg-primary rounded-lg flex items-center justify-center",children:i.jsx($n,{className:"h-5 w-5 text-primary-foreground"})}),i.jsxs("div",{children:[i.jsx("h1",{className:"font-semibold text-lg",children:"Edge LLM"}),i.jsx("p",{className:"text-xs text-muted-foreground",children:"Local AI Platform"})]})]})}),i.jsx("div",{className:"flex-1 px-3 py-4 space-y-8",children:i.jsxs("div",{children:[i.jsx("h2",{className:"mb-2 px-3 text-xs font-semibold text-muted-foreground uppercase tracking-wide",children:"Features"}),i.jsx("nav",{className:"space-y-1",children:$v.map(t=>{const n=e.pathname===t.href;return i.jsxs(yg,{to:t.href,className:Ne("flex items-center gap-3 rounded-lg px-3 py-2 text-sm transition-all hover:bg-accent",n?"bg-accent text-accent-foreground font-medium":"text-muted-foreground hover:text-foreground"),children:[i.jsx(t.icon,{className:"h-4 w-4"}),i.jsx("div",{className:"flex-1",children:t.name})]},t.name)})})]})})]})}function Uv(){return i.jsxs("div",{className:"flex h-screen bg-background",children:[i.jsx("div",{className:"w-64 border-r",children:i.jsx(Dv,{})}),i.jsx("div",{className:"flex-1 overflow-hidden",children:i.jsx(ig,{})})]})}const O=v.forwardRef(({className:e,...t},n)=>i.jsx("div",{ref:n,className:Ne("rounded-lg border bg-card text-card-foreground shadow-sm",e),...t}));O.displayName="Card";const nt=v.forwardRef(({className:e,...t},n)=>i.jsx("div",{ref:n,className:Ne("flex flex-col space-y-1.5 p-6",e),...t}));nt.displayName="CardHeader";const rt=v.forwardRef(({className:e,...t},n)=>i.jsx("h3",{ref:n,className:Ne("text-2xl font-semibold leading-none tracking-tight",e),...t}));rt.displayName="CardTitle";const Bv=v.forwardRef(({className:e,...t},n)=>i.jsx("p",{ref:n,className:Ne("text-sm text-muted-foreground",e),...t}));Bv.displayName="CardDescription";const $=v.forwardRef(({className:e,...t},n)=>i.jsx("div",{ref:n,className:Ne("p-6 pt-0",e),...t}));$.displayName="CardContent";const Vv=v.forwardRef(({className:e,...t},n)=>i.jsx("div",{ref:n,className:Ne("flex items-center p-6 pt-0",e),...t}));Vv.displayName="CardFooter";function Su(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function hf(...e){return t=>{let n=!1;const r=e.map(l=>{const s=Su(l,t);return!n&&typeof s=="function"&&(n=!0),s});if(n)return()=>{for(let l=0;l{const{children:s,...o}=r,a=v.Children.toArray(s),u=a.find(Gv);if(u){const c=u.props.children,d=a.map(f=>f===u?v.Children.count(c)>1?v.Children.only(null):v.isValidElement(c)?c.props.children:null:f);return i.jsx(t,{...o,ref:l,children:v.isValidElement(c)?v.cloneElement(c,void 0,d):null})}return i.jsx(t,{...o,ref:l,children:s})});return n.displayName=`${e}.Slot`,n}var Wv=ql("Slot");function Hv(e){const t=v.forwardRef((n,r)=>{const{children:l,...s}=n;if(v.isValidElement(l)){const o=Yv(l),a=Kv(s,l.props);return l.type!==v.Fragment&&(a.ref=r?hf(r,o):o),v.cloneElement(l,a)}return v.Children.count(l)>1?v.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var Qv=Symbol("radix.slottable");function Gv(e){return v.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===Qv}function Kv(e,t){const n={...t};for(const r in t){const l=e[r],s=t[r];/^on[A-Z]/.test(r)?l&&s?n[r]=(...a)=>{const u=s(...a);return l(...a),u}:l&&(n[r]=l):r==="style"?n[r]={...l,...s}:r==="className"&&(n[r]=[l,s].filter(Boolean).join(" "))}return{...e,...n}}function Yv(e){var r,l;let t=(r=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(l=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:l.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}const Cu=e=>typeof e=="boolean"?`${e}`:e===0?"0":e,Eu=Zd,Zi=(e,t)=>n=>{var r;if((t==null?void 0:t.variants)==null)return Eu(e,n==null?void 0:n.class,n==null?void 0:n.className);const{variants:l,defaultVariants:s}=t,o=Object.keys(l).map(c=>{const d=n==null?void 0:n[c],f=s==null?void 0:s[c];if(d===null)return null;const p=Cu(d)||Cu(f);return l[c][p]}),a=n&&Object.entries(n).reduce((c,d)=>{let[f,p]=d;return p===void 0||(c[f]=p),c},{}),u=t==null||(r=t.compoundVariants)===null||r===void 0?void 0:r.reduce((c,d)=>{let{class:f,className:p,...y}=d;return Object.entries(y).every(w=>{let[x,j]=w;return Array.isArray(j)?j.includes({...s,...a}[x]):{...s,...a}[x]===j})?[...c,f,p]:c},[]);return Eu(e,o,u,n==null?void 0:n.class,n==null?void 0:n.className)},Jv=Zi("inline-flex items-center justify-center whitespace-nowrap rounded-md text-sm font-medium ring-offset-background transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50",{variants:{variant:{default:"bg-primary text-primary-foreground hover:bg-primary/90",destructive:"bg-destructive text-destructive-foreground hover:bg-destructive/90",outline:"border border-input bg-background hover:bg-accent hover:text-accent-foreground",secondary:"bg-secondary text-secondary-foreground hover:bg-secondary/80",ghost:"hover:bg-accent hover:text-accent-foreground",link:"text-primary underline-offset-4 hover:underline"},size:{default:"h-10 px-4 py-2",sm:"h-9 rounded-md px-3",lg:"h-11 rounded-md px-8",icon:"h-10 w-10"}},defaultVariants:{variant:"default",size:"default"}}),U=v.forwardRef(({className:e,variant:t,size:n,asChild:r=!1,...l},s)=>{const o=r?Wv:"button";return i.jsx(o,{className:Ne(Jv({variant:t,size:n,className:e})),ref:s,...l})});U.displayName="Button";const Xv=Zi("inline-flex items-center rounded-full border px-2.5 py-0.5 text-xs font-semibold transition-colors focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2",{variants:{variant:{default:"border-transparent bg-primary text-primary-foreground hover:bg-primary/80",secondary:"border-transparent bg-secondary text-secondary-foreground hover:bg-secondary/80",destructive:"border-transparent bg-destructive text-destructive-foreground hover:bg-destructive/80",outline:"text-foreground"}},defaultVariants:{variant:"default"}});function Se({className:e,variant:t,...n}){return i.jsx("div",{className:Ne(Xv({variant:t}),e),...n})}function Zv(){const[e,t]=v.useState({models:0,assistants:0,isOnline:!1});v.useEffect(()=>{n(),r()},[]);const n=()=>{try{const o=JSON.parse(localStorage.getItem("savedAssistants")||"[]");t(a=>({...a,assistants:o.length}))}catch(o){console.error("Failed to load stats:",o)}},r=async()=>{try{const o=`${window.location.protocol}//${window.location.host}`,a=await fetch(`${o}/models`);if(a.ok){const u=await a.json();t(c=>{var d;return{...c,models:((d=u.models)==null?void 0:d.length)||0,isOnline:!0}})}}catch(o){console.error("System check failed:",o),t(a=>({...a,isOnline:!1}))}},l=[{title:"Quick Chat",description:"Start chatting immediately - no setup required",icon:ct,href:"/chat",color:"bg-blue-600",primary:!0,badge:"Instant"},{title:"Build Assistant",description:"Create your custom AI assistant with specialized skills",icon:Me,href:"/assistant-builder",color:"bg-purple-600",primary:!0,badge:"Advanced"},{title:"Use Template",description:"Start with pre-built assistant templates from the community",icon:Ir,href:"/community",color:"bg-green-600",primary:!0,badge:"Popular"},{title:"Manage Models",description:"Configure and load AI models",icon:Yl,href:"/models",color:"bg-gray-600",primary:!1,badge:null}],s=[{icon:Jo,title:"Privacy First",description:"Local processing with complete data control"},{icon:Xl,title:"High Performance",description:"Optimized for speed and efficiency"},{icon:fv,title:"Local & Cloud",description:"Run models locally or access cloud APIs"},{icon:$n,title:"Advanced Models",description:"Support for latest AI capabilities"}];return i.jsxs("div",{className:"min-h-screen bg-background",children:[i.jsx("div",{className:"bg-gradient-to-br from-blue-50 to-indigo-100 border-b",children:i.jsx("div",{className:"max-w-6xl mx-auto px-6 py-16",children:i.jsxs("div",{className:"text-center space-y-6",children:[i.jsxs("div",{className:"flex items-center justify-center gap-2 mb-4",children:[i.jsx("div",{className:"w-12 h-12 bg-blue-600 rounded-xl flex items-center justify-center",children:i.jsx($n,{className:"h-7 w-7 text-white"})}),i.jsxs("div",{className:"flex items-center gap-2",children:[i.jsx("h1",{className:"text-4xl font-bold text-gray-900",children:"Edge LLM"}),i.jsx(Se,{variant:e.isOnline?"default":"secondary",className:"text-xs",children:e.isOnline?"Online":"Offline"})]})]}),i.jsx("p",{className:"text-xl text-gray-600 max-w-3xl mx-auto",children:"Professional AI platform for local and cloud language models. Complete privacy, advanced features, industrial-grade performance."}),i.jsxs("div",{className:"flex items-center justify-center gap-4 pt-4",children:[i.jsxs(U,{size:"lg",onClick:()=>window.location.href="/playground",className:"flex items-center gap-2",children:[i.jsx(ct,{className:"h-5 w-5"}),"Start Chatting",i.jsx(wl,{className:"h-4 w-4"})]}),i.jsxs(U,{size:"lg",variant:"outline",onClick:()=>window.location.href="/models",children:[i.jsx(Yl,{className:"h-5 w-5 mr-2"}),"Browse Models"]})]})]})})}),i.jsxs("div",{className:"max-w-6xl mx-auto px-6 py-12 space-y-12",children:[i.jsxs("section",{children:[i.jsxs("div",{className:"text-center mb-8",children:[i.jsx("h2",{className:"text-2xl font-semibold mb-3",children:"Choose Your Path"}),i.jsx("p",{className:"text-gray-600 max-w-2xl mx-auto",children:"Select the best way to get started based on your needs and experience level"})]}),i.jsx("div",{className:"grid grid-cols-1 md:grid-cols-3 gap-6 mb-8",children:l.filter(o=>o.primary).map(o=>i.jsx(O,{className:"hover:shadow-xl transition-all duration-300 cursor-pointer hover:-translate-y-2 border-2 border-transparent hover:border-blue-200",onClick:()=>window.location.href=o.href,children:i.jsxs($,{className:"p-8 text-center space-y-6",children:[i.jsxs("div",{className:"relative",children:[i.jsx("div",{className:`w-16 h-16 ${o.color} rounded-2xl flex items-center justify-center mx-auto`,children:i.jsx(o.icon,{className:"h-8 w-8 text-white"})}),o.badge&&i.jsx(Se,{className:"absolute -top-2 -right-2 bg-white text-gray-700 border border-gray-200",children:o.badge})]}),i.jsxs("div",{children:[i.jsx("h3",{className:"font-bold text-xl mb-2",children:o.title}),i.jsx("p",{className:"text-gray-600 text-sm leading-relaxed",children:o.description})]}),i.jsxs(U,{className:"w-full",size:"lg",children:["Get Started",i.jsx(wl,{className:"h-4 w-4 ml-2"})]})]})},o.title))}),i.jsx("div",{className:"grid grid-cols-1 md:grid-cols-1 gap-4",children:l.filter(o=>!o.primary).map(o=>i.jsx(O,{className:"hover:shadow-md transition-all duration-200 cursor-pointer hover:-translate-y-1",onClick:()=>window.location.href=o.href,children:i.jsxs($,{className:"p-4 flex items-center gap-4",children:[i.jsx("div",{className:`w-12 h-12 ${o.color} rounded-lg flex items-center justify-center`,children:i.jsx(o.icon,{className:"h-6 w-6 text-white"})}),i.jsxs("div",{className:"flex-1",children:[i.jsx("h3",{className:"font-semibold text-base",children:o.title}),i.jsx("p",{className:"text-sm text-gray-600",children:o.description})]}),i.jsx(wl,{className:"h-5 w-5 text-gray-400"})]})},o.title))})]}),i.jsxs("section",{className:"grid grid-cols-1 md:grid-cols-3 gap-6",children:[i.jsx(O,{children:i.jsxs($,{className:"p-6 text-center",children:[i.jsx("div",{className:"text-3xl font-bold text-blue-600 mb-2",children:e.models}),i.jsx("div",{className:"text-sm text-gray-600",children:"Available Models"})]})}),i.jsx(O,{children:i.jsxs($,{className:"p-6 text-center",children:[i.jsx("div",{className:"text-3xl font-bold text-purple-600 mb-2",children:e.assistants}),i.jsx("div",{className:"text-sm text-gray-600",children:"My Assistants"})]})}),i.jsx(O,{children:i.jsxs($,{className:"p-6 text-center",children:[i.jsx("div",{className:"text-3xl font-bold text-green-600 mb-2",children:"5"}),i.jsx("div",{className:"text-sm text-gray-600",children:"Community Templates"})]})})]}),i.jsxs("section",{children:[i.jsx("h2",{className:"text-2xl font-semibold mb-6 text-center",children:"Core Features"}),i.jsx("div",{className:"grid grid-cols-1 md:grid-cols-2 lg:grid-cols-4 gap-6",children:s.map(o=>i.jsx(O,{className:"text-center",children:i.jsxs($,{className:"p-6 space-y-4",children:[i.jsx("div",{className:"w-12 h-12 bg-gray-100 rounded-lg flex items-center justify-center mx-auto",children:i.jsx(o.icon,{className:"h-6 w-6 text-gray-700"})}),i.jsxs("div",{children:[i.jsx("h3",{className:"font-semibold",children:o.title}),i.jsx("p",{className:"text-sm text-gray-600 mt-1",children:o.description})]})]})},o.title))})]}),i.jsx("section",{className:"bg-gradient-to-r from-blue-50 to-purple-50 rounded-2xl p-8 border border-blue-200",children:i.jsxs("div",{className:"text-center",children:[i.jsx("div",{className:"w-12 h-12 bg-blue-600 rounded-xl flex items-center justify-center mx-auto mb-4",children:i.jsx(Xl,{className:"h-6 w-6 text-white"})}),i.jsx("h2",{className:"text-2xl font-semibold mb-4",children:"New to AI Assistants?"}),i.jsxs("p",{className:"text-gray-600 mb-6 max-w-2xl mx-auto",children:["We recommend starting with ",i.jsx("strong",{children:"Quick Chat"})," to get familiar with AI conversations, then try our ",i.jsx("strong",{children:"Community Templates"})," to see what's possible."]}),i.jsxs("div",{className:"flex items-center justify-center gap-4",children:[i.jsxs(U,{size:"lg",onClick:()=>window.location.href="/chat",children:[i.jsx(ct,{className:"h-4 w-4 mr-2"}),"Try Quick Chat"]}),i.jsxs(U,{size:"lg",variant:"outline",onClick:()=>window.location.href="/community",children:[i.jsx(Ir,{className:"h-4 w-4 mr-2"}),"Browse Templates"]})]})]})})]})]})}function qv(){v.useEffect(()=>{const t=setTimeout(()=>{window.location.href="/chat"},5e3);return()=>clearTimeout(t)},[]);const e=[{title:"Quick Chat",description:"Simple AI conversations with no configuration needed",href:"/chat",icon:ct,color:"bg-blue-600",recommended:!0},{title:"Build Assistant",description:"Create a custom AI assistant with specialized skills",href:"/assistant-builder",icon:Me,color:"bg-purple-600",recommended:!1}];return i.jsx("div",{className:"min-h-screen bg-background flex items-center justify-center p-6",children:i.jsxs("div",{className:"max-w-4xl w-full",children:[i.jsxs("div",{className:"text-center mb-12",children:[i.jsx("div",{className:"w-16 h-16 bg-blue-600 rounded-2xl flex items-center justify-center mx-auto mb-6",children:i.jsx(Xl,{className:"h-8 w-8 text-white"})}),i.jsx("h1",{className:"text-3xl font-bold mb-4",children:"Choose Your Experience"}),i.jsx("p",{className:"text-xl text-gray-600 max-w-2xl mx-auto",children:"The Playground has been redesigned! Choose the experience that best fits your needs."})]}),i.jsx("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-8 mb-8",children:e.map(t=>i.jsx(O,{className:`cursor-pointer hover:shadow-xl transition-all duration-300 hover:-translate-y-2 ${t.recommended?"ring-2 ring-blue-200 bg-blue-50":""}`,onClick:()=>window.location.href=t.href,children:i.jsxs($,{className:"p-8 text-center space-y-6",children:[t.recommended&&i.jsx("div",{className:"bg-blue-600 text-white text-xs px-3 py-1 rounded-full inline-block mb-4",children:"Recommended for most users"}),i.jsx("div",{className:`w-16 h-16 ${t.color} rounded-2xl flex items-center justify-center mx-auto`,children:i.jsx(t.icon,{className:"h-8 w-8 text-white"})}),i.jsxs("div",{children:[i.jsx("h3",{className:"font-bold text-2xl mb-3",children:t.title}),i.jsx("p",{className:"text-gray-600 leading-relaxed",children:t.description})]}),i.jsxs(U,{size:"lg",className:"w-full",children:["Continue",i.jsx(wl,{className:"h-4 w-4 ml-2"})]})]})},t.title))}),i.jsxs("div",{className:"text-center",children:[i.jsx("p",{className:"text-sm text-gray-500 mb-4",children:"This page will automatically redirect to Quick Chat in a few seconds"}),i.jsxs("div",{className:"flex items-center justify-center gap-4",children:[i.jsx(U,{variant:"outline",onClick:()=>window.location.href="/",children:"Back to Home"}),i.jsx(U,{onClick:()=>window.location.href="/chat",children:"Go to Quick Chat"})]})]})]})})}const qi=v.forwardRef(({className:e,...t},n)=>i.jsx("textarea",{className:Ne("flex min-h-[80px] w-full rounded-md border border-input bg-background px-3 py-2 text-sm ring-offset-background placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50",e),ref:n,...t}));qi.displayName="Textarea";function e0(){const[e,t]=v.useState([]),[n,r]=v.useState(""),[l,s]=v.useState(!1),[o]=v.useState("Qwen/Qwen3-30B-A3B"),a=v.useRef(null);v.useEffect(()=>{u()},[]);const u=()=>{try{const x=localStorage.getItem("simpleChatHistory");if(x){const j=JSON.parse(x);t(j.map(h=>({...h,timestamp:new Date(h.timestamp)})))}}catch(x){console.error("Failed to load chat history:",x)}},c=x=>{try{localStorage.setItem("simpleChatHistory",JSON.stringify(x))}catch(j){console.error("Failed to save chat history:",j)}},d=async()=>{var h,m;if(!n.trim())return;const x={id:`user_${Date.now()}`,role:"user",content:n.trim(),timestamp:new Date},j=[...e,x];t(j),r(""),s(!0);try{const g=`${window.location.protocol}//${window.location.host}`,N=await fetch(`${g}/chat/completions`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({messages:j.map(S=>({role:S.role,content:S.content})),temperature:.7,max_tokens:2e3})});if(N.ok){const S=await N.json(),E={id:`assistant_${Date.now()}`,role:"assistant",content:((m=(h=S.choices[0])==null?void 0:h.message)==null?void 0:m.content)||"No response received",timestamp:new Date},_=[...j,E];t(_),c(_)}else throw new Error(`HTTP ${N.status}`)}catch(g){console.error("Chat error:",g);const N={id:`error_${Date.now()}`,role:"assistant",content:"Sorry, I encountered an error. Please try again.",timestamp:new Date},S=[...j,N];t(S),c(S)}finally{s(!1)}},f=x=>{x.key==="Enter"&&!x.shiftKey&&(x.preventDefault(),d())},p=()=>{t([]),localStorage.removeItem("simpleChatHistory")},y=()=>{const x=e.slice(-10);localStorage.setItem("assistantBuilderContext",JSON.stringify({messages:x,model:o})),window.location.href="/assistant-builder"},w=["Help me write a professional email","Explain quantum computing simply","Create a workout plan","Review my code for bugs"];return i.jsxs("div",{className:"min-h-screen bg-background",children:[i.jsx("div",{className:"border-b bg-background/95 backdrop-blur",children:i.jsx("div",{className:"max-w-4xl mx-auto px-6 py-4",children:i.jsxs("div",{className:"flex items-center justify-between",children:[i.jsxs("div",{className:"flex items-center gap-3",children:[i.jsx("div",{className:"w-8 h-8 bg-blue-600 rounded-lg flex items-center justify-center",children:i.jsx(ct,{className:"h-5 w-5 text-white"})}),i.jsxs("div",{children:[i.jsx("h1",{className:"text-xl font-semibold",children:"Quick Chat"}),i.jsx("p",{className:"text-sm text-muted-foreground",children:"Simple AI conversations - no setup required"})]})]}),i.jsxs("div",{className:"flex items-center gap-2",children:[i.jsx(Se,{variant:"outline",className:"text-xs",children:o.split("/").pop()}),i.jsxs(U,{variant:"outline",size:"sm",onClick:p,children:[i.jsx(Yo,{className:"h-4 w-4 mr-1"}),"New Chat"]}),e.length>0&&i.jsxs(U,{size:"sm",onClick:y,children:[i.jsx(Jl,{className:"h-4 w-4 mr-1"}),"Create Assistant"]})]})]})})}),i.jsx("div",{className:"max-w-4xl mx-auto px-6 py-6",children:i.jsxs("div",{className:"flex flex-col h-[calc(100vh-200px)]",children:[i.jsx("div",{className:"flex-1 mb-6 overflow-hidden",children:i.jsx(O,{className:"h-full",children:i.jsx($,{className:"h-full p-0",children:i.jsx("div",{className:"h-full p-6 overflow-y-auto",children:e.length===0?i.jsxs("div",{className:"flex flex-col items-center justify-center h-full text-center",children:[i.jsx("div",{className:"w-16 h-16 bg-blue-100 rounded-full flex items-center justify-center mb-4",children:i.jsx(Me,{className:"h-8 w-8 text-blue-600"})}),i.jsx("h3",{className:"text-lg font-medium mb-2",children:"Start a conversation"}),i.jsx("p",{className:"text-muted-foreground mb-6 max-w-md",children:"Ask me anything or try one of these suggestions to get started"}),i.jsx("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-3 max-w-2xl",children:w.map((x,j)=>i.jsx(U,{variant:"outline",className:"text-left h-auto py-3 px-4",onClick:()=>r(x),children:i.jsx("div",{className:"text-sm",children:x})},j))})]}):i.jsxs("div",{className:"space-y-6",children:[e.map(x=>i.jsxs("div",{className:`flex gap-4 ${x.role==="user"?"justify-end":"justify-start"}`,children:[x.role==="assistant"&&i.jsx("div",{className:"w-8 h-8 bg-blue-600 rounded-full flex items-center justify-center",children:i.jsx(Me,{className:"h-4 w-4 text-white"})}),i.jsx("div",{className:`max-w-[80%] p-4 rounded-lg ${x.role==="user"?"bg-blue-600 text-white":"bg-gray-100 text-gray-900"}`,children:i.jsx("div",{className:"prose prose-sm max-w-none",children:i.jsx("p",{className:"whitespace-pre-wrap",children:x.content})})}),x.role==="user"&&i.jsx("div",{className:"w-8 h-8 bg-gray-600 rounded-full flex items-center justify-center",children:i.jsx(mf,{className:"h-4 w-4 text-white"})})]},x.id)),l&&i.jsxs("div",{className:"flex gap-4 justify-start",children:[i.jsx("div",{className:"w-8 h-8 bg-blue-600 rounded-full flex items-center justify-center",children:i.jsx(Me,{className:"h-4 w-4 text-white"})}),i.jsx("div",{className:"bg-gray-100 rounded-lg p-4",children:i.jsxs("div",{className:"flex space-x-1",children:[i.jsx("div",{className:"w-2 h-2 bg-gray-400 rounded-full animate-pulse"}),i.jsx("div",{className:"w-2 h-2 bg-gray-400 rounded-full animate-pulse",style:{animationDelay:"0.2s"}}),i.jsx("div",{className:"w-2 h-2 bg-gray-400 rounded-full animate-pulse",style:{animationDelay:"0.4s"}})]})})]})]})})})})}),i.jsxs("div",{className:"space-y-4",children:[i.jsx(O,{children:i.jsx($,{className:"p-4",children:i.jsxs("div",{className:"flex gap-3",children:[i.jsx(qi,{ref:a,placeholder:"Type your message...",value:n,onChange:x=>r(x.target.value),onKeyPress:f,className:"flex-1 min-h-[60px] resize-none",disabled:l}),i.jsx(U,{onClick:d,disabled:l||!n.trim(),size:"lg",className:"shrink-0",children:l?i.jsx("div",{className:"w-4 h-4 border-2 border-white border-t-transparent rounded-full animate-spin"}):i.jsx(df,{className:"h-4 w-4"})})]})})}),i.jsx("div",{className:"text-center",children:i.jsx("p",{className:"text-xs text-muted-foreground",children:"Press Enter to send, Shift+Enter for new line"})})]})]})})]})}const Qt=v.forwardRef(({className:e,type:t,...n},r)=>i.jsx("input",{type:t,className:Ne("flex h-10 w-full rounded-md border border-input bg-background px-3 py-2 text-sm ring-offset-background file:border-0 file:bg-transparent file:text-sm file:font-medium placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50",e),ref:r,...n}));Qt.displayName="Input";function t0(){const[e,t]=v.useState({name:"",description:"",instructions:"",model:"Qwen/Qwen3-30B-A3B",temperature:.7,maxTokens:2e3,conversation_starters:["","","",""]}),[n,r]=v.useState([]),[l,s]=v.useState(""),[o,a]=v.useState(!1),u=(p,y)=>{t(w=>({...w,[p]:y}))},c=(p,y)=>{const w=[...e.conversation_starters];w[p]=y,u("conversation_starters",w)},d=async()=>{var y,w;if(!l.trim())return;const p={role:"user",content:l};r(x=>[...x,p]),s(""),a(!0);try{const x=`${window.location.protocol}//${window.location.host}`,j=[...n,p],h=await fetch(`${x}/chat/completions`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({messages:[{role:"system",content:e.instructions},...j],temperature:e.temperature,max_tokens:e.maxTokens})});if(h.ok){const g={role:"assistant",content:((w=(y=(await h.json()).choices[0])==null?void 0:y.message)==null?void 0:w.content)||"No response"};r(N=>[...N,g])}}catch(x){console.error("Test failed:",x)}finally{a(!1)}},f=()=>{const p={id:`assistant_${Date.now()}`,...e,createdAt:new Date().toISOString(),systemPrompt:e.instructions};try{const y=JSON.parse(localStorage.getItem("savedAssistants")||"[]");y.push(p),localStorage.setItem("savedAssistants",JSON.stringify(y)),alert("Assistant saved successfully!"),window.location.href="/assistants"}catch(y){console.error("Failed to save assistant:",y)}};return i.jsxs("div",{className:"min-h-screen bg-gray-50",children:[i.jsx("div",{className:"bg-white border-b border-gray-200",children:i.jsx("div",{className:"max-w-7xl mx-auto px-6 py-4",children:i.jsxs("div",{className:"flex items-center justify-between",children:[i.jsxs("div",{className:"flex items-center gap-4",children:[i.jsxs(U,{variant:"ghost",size:"sm",onClick:()=>window.location.href="/assistants",className:"flex items-center gap-2",children:[i.jsx(tv,{className:"h-4 w-4"}),"Back"]}),i.jsxs("div",{className:"flex items-center gap-3",children:[i.jsx("div",{className:"w-8 h-8 bg-purple-600 rounded-lg flex items-center justify-center",children:i.jsx(Me,{className:"h-5 w-5 text-white"})}),i.jsxs("div",{children:[i.jsx("h1",{className:"text-xl font-semibold",children:"Assistant Builder"}),i.jsx("p",{className:"text-sm text-gray-500",children:"Create your custom AI assistant"})]})]})]}),i.jsxs("div",{className:"flex items-center gap-3",children:[i.jsx(U,{variant:"outline",onClick:()=>r([]),children:"Clear Test"}),i.jsxs(U,{onClick:f,className:"flex items-center gap-2",children:[i.jsx(kv,{className:"h-4 w-4"}),"Save Assistant"]})]})]})})}),i.jsx("div",{className:"max-w-7xl mx-auto p-6",children:i.jsxs("div",{className:"grid grid-cols-1 lg:grid-cols-2 gap-8 h-[calc(100vh-160px)]",children:[i.jsx("div",{className:"space-y-6",children:i.jsxs(O,{children:[i.jsx(nt,{children:i.jsxs(rt,{className:"flex items-center gap-2",children:[i.jsx(Xi,{className:"h-5 w-5"}),"Configure Assistant"]})}),i.jsxs($,{className:"space-y-6",children:[i.jsxs("div",{className:"space-y-4",children:[i.jsxs("div",{children:[i.jsx("label",{className:"text-sm font-medium mb-2 block",children:"Name"}),i.jsx(Qt,{placeholder:"e.g., Marketing Expert",value:e.name,onChange:p=>u("name",p.target.value)})]}),i.jsxs("div",{children:[i.jsx("label",{className:"text-sm font-medium mb-2 block",children:"Description"}),i.jsx(Qt,{placeholder:"What does this assistant do?",value:e.description,onChange:p=>u("description",p.target.value)})]})]}),i.jsxs("div",{children:[i.jsx("label",{className:"text-sm font-medium mb-2 block",children:"Instructions"}),i.jsx("p",{className:"text-xs text-gray-500 mb-2",children:"Define your assistant's behavior, expertise, and communication style"}),i.jsx(qi,{className:"min-h-[200px] font-mono text-sm",placeholder:`You are a helpful marketing expert assistant. You should: + +1. Provide actionable marketing advice +2. Use data-driven insights when possible +3. Explain complex concepts simply +4. Ask clarifying questions to give better recommendations +5. Stay up-to-date with current marketing trends + +Your responses should be professional yet approachable, and always include specific examples when helpful.`,value:e.instructions,onChange:p=>u("instructions",p.target.value)})]}),i.jsxs("div",{className:"grid grid-cols-2 gap-4",children:[i.jsxs("div",{children:[i.jsx("label",{className:"text-sm font-medium mb-2 block",children:"Temperature"}),i.jsx(Qt,{type:"number",min:"0",max:"2",step:"0.1",value:e.temperature,onChange:p=>u("temperature",parseFloat(p.target.value))})]}),i.jsxs("div",{children:[i.jsx("label",{className:"text-sm font-medium mb-2 block",children:"Max Tokens"}),i.jsx(Qt,{type:"number",min:"100",max:"4000",step:"100",value:e.maxTokens,onChange:p=>u("maxTokens",parseInt(p.target.value))})]})]}),i.jsxs("div",{children:[i.jsx("label",{className:"text-sm font-medium mb-2 block",children:"Conversation Starters"}),i.jsx("p",{className:"text-xs text-gray-500 mb-2",children:"Suggested prompts to help users get started"}),i.jsx("div",{className:"space-y-2",children:e.conversation_starters.map((p,y)=>i.jsx(Qt,{placeholder:`Conversation starter ${y+1}`,value:p,onChange:w=>c(y,w.target.value)},y))})]})]})]})}),i.jsx("div",{className:"flex flex-col",children:i.jsxs(O,{className:"flex-1 flex flex-col",children:[i.jsx(nt,{className:"pb-3",children:i.jsxs(rt,{className:"flex items-center gap-2",children:[i.jsx(ct,{className:"h-5 w-5"}),"Test Your Assistant",e.name&&i.jsx(Se,{variant:"outline",className:"ml-auto",children:e.name})]})}),i.jsxs($,{className:"flex-1 flex flex-col",children:[i.jsx("div",{className:"flex-1 bg-gray-50 rounded-lg p-4 mb-4 overflow-y-auto space-y-4 min-h-[300px]",children:n.length===0?i.jsxs("div",{className:"flex flex-col items-center justify-center h-full text-center text-gray-500",children:[i.jsx(Me,{className:"h-12 w-12 mb-4 text-gray-300"}),i.jsx("p",{className:"text-sm",children:"Start testing your assistant"}),i.jsx("p",{className:"text-xs text-gray-400 mt-1",children:"Messages will appear here"})]}):n.map((p,y)=>i.jsxs("div",{className:`flex gap-3 ${p.role==="assistant"?"justify-start":"justify-end"}`,children:[p.role==="assistant"&&i.jsx("div",{className:"w-8 h-8 bg-purple-600 rounded-full flex items-center justify-center",children:i.jsx(Me,{className:"h-4 w-4 text-white"})}),i.jsx("div",{className:`max-w-[80%] p-3 rounded-lg ${p.role==="assistant"?"bg-white border border-gray-200":"bg-blue-600 text-white"}`,children:i.jsx("p",{className:"text-sm whitespace-pre-wrap",children:p.content})}),p.role==="user"&&i.jsx("div",{className:"w-8 h-8 bg-blue-600 rounded-full flex items-center justify-center",children:i.jsx(mf,{className:"h-4 w-4 text-white"})})]},y))}),i.jsxs("div",{className:"flex gap-2",children:[i.jsx(Qt,{placeholder:"Test your assistant...",value:l,onChange:p=>s(p.target.value),onKeyPress:p=>p.key==="Enter"&&!p.shiftKey&&d(),disabled:o}),i.jsx(U,{onClick:d,disabled:o||!l.trim(),size:"sm",children:o?i.jsx("div",{className:"w-4 h-4 border-2 border-white border-t-transparent rounded-full animate-spin"}):i.jsx(df,{className:"h-4 w-4"})})]}),e.conversation_starters.some(p=>p.trim())&&i.jsxs("div",{className:"mt-3 pt-3 border-t border-gray-200",children:[i.jsx("p",{className:"text-xs text-gray-500 mb-2",children:"Try these:"}),i.jsx("div",{className:"flex flex-wrap gap-2",children:e.conversation_starters.filter(p=>p.trim()).map((p,y)=>i.jsx(U,{variant:"outline",size:"sm",className:"text-xs h-auto py-1 px-2",onClick:()=>s(p),children:p},y))})]})]})]})})]})})]})}function n0(){const[e,t]=v.useState([]),[n,r]=v.useState(!0),[l,s]=v.useState(null);v.useEffect(()=>{o()},[]);const o=async()=>{try{const c=`${window.location.protocol}//${window.location.host}`,d=await fetch(`${c}/models`);if(!d.ok)throw new Error(`Failed to fetch models: ${d.status}`);const f=await d.json();t(f.models)}catch(c){console.error("Error fetching models:",c)}finally{r(!1)}},a=async c=>{s(c);try{const d=`${window.location.protocol}//${window.location.host}`,f=await fetch(`${d}/load-model`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({model_name:c})});if(!f.ok)throw new Error(`Failed to load model: ${f.status}`);o()}catch(d){console.error("Error loading model:",d)}finally{s(null)}},u=async c=>{s(c);try{const d=`${window.location.protocol}//${window.location.host}`,f=await fetch(`${d}/unload-model`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({model_name:c})});if(!f.ok)throw new Error(`Failed to unload model: ${f.status}`);o()}catch(d){console.error("Error unloading model:",d)}finally{s(null)}};return n?i.jsx("div",{className:"min-h-screen bg-background flex items-center justify-center",children:i.jsx(Ko,{className:"h-8 w-8 animate-spin"})}):i.jsxs("div",{className:"min-h-screen bg-background",children:[i.jsx("div",{className:"border-b bg-background/95 backdrop-blur supports-[backdrop-filter]:bg-background/60",children:i.jsx("div",{className:"max-w-6xl mx-auto p-6",children:i.jsxs("div",{className:"flex items-center justify-between",children:[i.jsxs("div",{className:"flex items-center gap-3",children:[i.jsx("div",{className:"w-8 h-8 bg-blue-600 rounded-lg flex items-center justify-center",children:i.jsx(Yl,{className:"h-5 w-5 text-white"})}),i.jsxs("div",{children:[i.jsx("h1",{className:"text-2xl font-bold",children:"Model Catalog"}),i.jsx("p",{className:"text-sm text-muted-foreground",children:"Browse and manage AI models for your conversations"})]})]}),i.jsxs(U,{onClick:()=>window.location.href="/playground",className:"flex items-center gap-2",children:[i.jsx(Xl,{className:"h-4 w-4"}),"Go to Playground"]})]})})}),i.jsx("div",{className:"flex-1 p-6",children:i.jsxs("div",{className:"max-w-6xl mx-auto space-y-6",children:[i.jsx(O,{className:"bg-blue-50 border-blue-200",children:i.jsx($,{className:"pt-6",children:i.jsxs("div",{className:"flex items-start gap-3",children:[i.jsx(cf,{className:"h-5 w-5 text-blue-600 mt-0.5"}),i.jsxs("div",{children:[i.jsx("h3",{className:"font-medium text-blue-900",children:"Model Management"}),i.jsx("p",{className:"text-sm text-blue-700 mt-1",children:"Load models to use them in the playground. Models are cached locally for faster access. Each model requires significant storage space and initial download time."})]})]})})}),i.jsxs("div",{children:[i.jsxs("h2",{className:"text-xl font-semibold mb-4 flex items-center gap-2",children:[i.jsx(of,{className:"h-5 w-5"}),"API Models",i.jsx(Se,{variant:"outline",className:"text-xs",children:"Cloud-Powered"})]}),i.jsx("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-6 mb-8",children:e.filter(c=>c.type==="api").map(c=>i.jsx(_u,{model:c,modelLoading:l,onLoad:a,onUnload:u},c.model_name))})]}),i.jsxs("div",{children:[i.jsxs("h2",{className:"text-xl font-semibold mb-4 flex items-center gap-2",children:[i.jsx(uf,{className:"h-5 w-5"}),"Local Models",i.jsx(Se,{variant:"outline",className:"text-xs",children:"Self-Hosted"})]}),i.jsx("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-6",children:e.filter(c=>c.type==="local").map(c=>i.jsx(_u,{model:c,modelLoading:l,onLoad:a,onUnload:u},c.model_name))})]}),i.jsxs(O,{children:[i.jsx(nt,{children:i.jsxs(rt,{className:"flex items-center gap-2",children:[i.jsx($n,{className:"h-5 w-5"}),"Model Statistics"]})}),i.jsx($,{children:i.jsxs("div",{className:"grid grid-cols-2 md:grid-cols-4 gap-6",children:[i.jsxs("div",{className:"text-center",children:[i.jsx("div",{className:"text-2xl font-bold text-blue-600",children:e.filter(c=>c.type==="api").length}),i.jsx("div",{className:"text-sm text-muted-foreground",children:"API Models"})]}),i.jsxs("div",{className:"text-center",children:[i.jsx("div",{className:"text-2xl font-bold text-green-600",children:e.filter(c=>c.type==="local").length}),i.jsx("div",{className:"text-sm text-muted-foreground",children:"Local Models"})]}),i.jsxs("div",{className:"text-center",children:[i.jsx("div",{className:"text-2xl font-bold text-orange-600",children:e.filter(c=>c.is_loaded).length}),i.jsx("div",{className:"text-sm text-muted-foreground",children:"Loaded Models"})]}),i.jsxs("div",{className:"text-center",children:[i.jsx("div",{className:"text-2xl font-bold text-purple-600",children:e.filter(c=>c.supports_thinking).length}),i.jsx("div",{className:"text-sm text-muted-foreground",children:"Thinking Models"})]})]})})]})]})})]})}function _u({model:e,modelLoading:t,onLoad:n,onUnload:r}){const l=e.type==="api",s=t===e.model_name,o=e.is_loaded;return i.jsxs(O,{className:"hover:shadow-md transition-shadow",children:[i.jsx(nt,{className:"pb-3",children:i.jsxs("div",{className:"flex items-start justify-between",children:[i.jsxs("div",{className:"flex-1",children:[i.jsxs(rt,{className:"text-base flex items-center gap-2",children:[l?i.jsx(of,{className:"h-4 w-4 text-blue-600"}):i.jsx(uf,{className:"h-4 w-4 text-green-600"}),e.name]}),i.jsx("p",{className:"text-xs text-muted-foreground mt-1",children:e.model_name})]}),o&&i.jsx(av,{className:"h-5 w-5 text-green-600"})]})}),i.jsxs($,{className:"space-y-3",children:[i.jsxs("div",{className:"space-y-2 text-sm",children:[!l&&i.jsxs(i.Fragment,{children:[i.jsxs("div",{className:"flex justify-between",children:[i.jsx("span",{className:"text-muted-foreground",children:"Size:"}),i.jsx(Se,{variant:"outline",className:"text-xs",children:e.size_gb})]}),i.jsxs("div",{className:"flex justify-between",children:[i.jsx("span",{className:"text-muted-foreground",children:"RAM Required:"}),i.jsx(Se,{variant:"outline",className:"text-xs",children:e.ram_required_gb})]})]}),i.jsxs("div",{className:"flex justify-between",children:[i.jsx("span",{className:"text-muted-foreground",children:"Type:"}),i.jsx(Se,{variant:l?"default":"secondary",className:"text-xs",children:l?"API":"Local"})]}),e.supports_thinking&&i.jsxs("div",{className:"flex justify-between",children:[i.jsx("span",{className:"text-muted-foreground",children:"Features:"}),i.jsxs(Se,{variant:"outline",className:"text-xs",children:[i.jsx($n,{className:"h-3 w-3 mr-1"}),"Thinking"]})]})]}),i.jsx("div",{className:"pt-2",children:o?i.jsxs(U,{size:"sm",variant:"outline",onClick:()=>r(e.model_name),disabled:s,className:"w-full",children:[s?i.jsx(Ko,{className:"h-4 w-4 mr-2 animate-spin"}):i.jsx(pf,{className:"h-4 w-4 mr-2"}),s?"Unloading...":"Unload Model"]}):i.jsxs(U,{size:"sm",onClick:()=>n(e.model_name),disabled:s,className:"w-full",children:[s?i.jsx(Ko,{className:"h-4 w-4 mr-2 animate-spin"}):i.jsx(Ji,{className:"h-4 w-4 mr-2"}),s?"Loading...":"Load Model"]})})]})]})}function r0(){const[e,t]=v.useState([]);v.useEffect(()=>{n()},[]);const n=()=>{try{const a=JSON.parse(localStorage.getItem("savedAssistants")||"[]");t(a)}catch(a){console.error("Failed to load assistants:",a)}},r=a=>{localStorage.setItem("loadAssistantConfig",JSON.stringify(a)),window.location.href="/playground"},l=a=>{const u=e.filter(c=>c.id!==a);t(u),localStorage.setItem("savedAssistants",JSON.stringify(u))},s=a=>{alert(`"${a.name}" has been shared to the community! (This is a demo - in production, it would be submitted for review.)`)},o=()=>{window.location.href="/playground"};return i.jsxs("div",{className:"min-h-screen bg-background",children:[i.jsx("div",{className:"border-b bg-background/95 backdrop-blur supports-[backdrop-filter]:bg-background/60",children:i.jsx("div",{className:"max-w-6xl mx-auto p-6",children:i.jsxs("div",{className:"flex items-center justify-between",children:[i.jsxs("div",{className:"flex items-center gap-3",children:[i.jsx("div",{className:"w-8 h-8 bg-purple-600 rounded-lg flex items-center justify-center",children:i.jsx(Me,{className:"h-5 w-5 text-white"})}),i.jsxs("div",{children:[i.jsx("h1",{className:"text-2xl font-bold",children:"My Assistants"}),i.jsx("p",{className:"text-sm text-muted-foreground",children:"Manage your custom AI assistants and configurations"})]})]}),i.jsxs(U,{onClick:o,className:"flex items-center gap-2",children:[i.jsx(Yo,{className:"h-4 w-4"}),"Create New Assistant"]})]})})}),i.jsx("div",{className:"flex-1 p-6",children:i.jsxs("div",{className:"max-w-6xl mx-auto space-y-6",children:[i.jsx(O,{className:"bg-purple-50 border-purple-200",children:i.jsx($,{className:"pt-6",children:i.jsxs("div",{className:"flex items-start gap-3",children:[i.jsx(Jl,{className:"h-5 w-5 text-purple-600 mt-0.5"}),i.jsxs("div",{children:[i.jsx("h3",{className:"font-medium text-purple-900",children:"Custom AI Assistants"}),i.jsx("p",{className:"text-sm text-purple-700 mt-1",children:"Create specialized AI assistants by configuring models, prompts, and parameters in the Playground. Save different configurations for various tasks and workflows."})]})]})})}),e.length>0?i.jsx("div",{className:"grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-4",children:e.map(a=>i.jsx(l0,{assistant:a,onUse:()=>r(a),onDelete:()=>l(a.id),onShare:()=>s(a)},a.id))}):i.jsxs(O,{className:"text-center py-16",children:[i.jsx(Me,{className:"h-16 w-16 mx-auto text-muted-foreground mb-6"}),i.jsx("h3",{className:"text-xl font-medium mb-3",children:"No assistants yet"}),i.jsx("p",{className:"text-muted-foreground mb-6 max-w-md mx-auto",children:"Create your first AI assistant by configuring parameters and prompts in the Playground, then saving your configuration for future use."}),i.jsxs(U,{onClick:o,size:"lg",className:"flex items-center gap-2 mx-auto",children:[i.jsx(Yo,{className:"h-5 w-5"}),"Create Your First Assistant"]})]}),e.length>0&&i.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-3 gap-6",children:[i.jsx(O,{children:i.jsx($,{className:"pt-6",children:i.jsxs("div",{className:"flex items-center justify-between",children:[i.jsxs("div",{children:[i.jsx("div",{className:"text-2xl font-bold text-purple-600",children:e.length}),i.jsx("div",{className:"text-sm text-muted-foreground",children:"Total Assistants"})]}),i.jsx(Me,{className:"h-8 w-8 text-purple-600"})]})})}),i.jsx(O,{children:i.jsx($,{className:"pt-6",children:i.jsxs("div",{className:"flex items-center justify-between",children:[i.jsxs("div",{children:[i.jsx("div",{className:"text-2xl font-bold text-blue-600",children:new Set(e.map(a=>a.model)).size}),i.jsx("div",{className:"text-sm text-muted-foreground",children:"Models Used"})]}),i.jsx(ct,{className:"h-8 w-8 text-blue-600"})]})})}),i.jsx(O,{children:i.jsx($,{className:"pt-6",children:i.jsxs("div",{className:"flex items-center justify-between",children:[i.jsxs("div",{children:[i.jsx("div",{className:"text-2xl font-bold text-green-600",children:e.filter(a=>a.createdAt&&new Date(a.createdAt)>new Date(Date.now()-7*24*60*60*1e3)).length}),i.jsx("div",{className:"text-sm text-muted-foreground",children:"Created This Week"})]}),i.jsx(Jl,{className:"h-8 w-8 text-green-600"})]})})})]})]})})]})}function l0({assistant:e,onUse:t,onDelete:n,onShare:r}){return i.jsxs(O,{className:"hover:shadow-lg transition-all duration-200 hover:-translate-y-1",children:[i.jsx(nt,{className:"pb-3",children:i.jsxs("div",{className:"flex items-start justify-between",children:[i.jsxs("div",{className:"flex-1",children:[i.jsxs(rt,{className:"text-base flex items-center gap-2",children:[i.jsx(Me,{className:"h-4 w-4 text-purple-600"}),e.name]}),i.jsx("p",{className:"text-sm text-muted-foreground mt-1",children:e.description||"No description provided"})]}),i.jsxs("div",{className:"flex gap-1",children:[i.jsx(U,{variant:"ghost",size:"sm",onClick:r,className:"text-blue-600 hover:text-blue-700 hover:bg-blue-50",title:"Share to community",children:i.jsx(Tv,{className:"h-4 w-4"})}),i.jsx(U,{variant:"ghost",size:"sm",onClick:n,className:"text-red-500 hover:text-red-600 hover:bg-red-50",title:"Delete assistant",children:i.jsx(pf,{className:"h-4 w-4"})})]})]})}),i.jsxs($,{className:"space-y-4",children:[i.jsxs("div",{className:"grid grid-cols-2 gap-3 text-xs",children:[i.jsxs("div",{className:"bg-gray-50 rounded p-2",children:[i.jsx("span",{className:"font-medium text-gray-600",children:"Model:"}),i.jsx("p",{className:"text-gray-800 truncate",children:e.model})]}),i.jsxs("div",{className:"bg-gray-50 rounded p-2",children:[i.jsx("span",{className:"font-medium text-gray-600",children:"Temperature:"}),i.jsx("p",{className:"text-gray-800",children:e.temperature})]}),i.jsxs("div",{className:"bg-gray-50 rounded p-2",children:[i.jsx("span",{className:"font-medium text-gray-600",children:"Max Tokens:"}),i.jsx("p",{className:"text-gray-800",children:e.maxTokens})]}),i.jsxs("div",{className:"bg-gray-50 rounded p-2",children:[i.jsx("span",{className:"font-medium text-gray-600",children:"Created:"}),i.jsx("p",{className:"text-gray-800",children:new Date(e.createdAt).toLocaleDateString()})]})]}),e.systemPrompt&&i.jsxs("div",{className:"bg-blue-50 rounded p-2",children:[i.jsx("span",{className:"text-xs font-medium text-blue-700",children:"System Prompt:"}),i.jsx("p",{className:"text-xs text-blue-600 mt-1 line-clamp-2",children:e.systemPrompt})]}),i.jsxs(U,{onClick:t,className:"w-full flex items-center gap-2",children:[i.jsx(ct,{className:"h-4 w-4"}),"Use Assistant"]})]})]})}function dt(e,t,{checkForDefaultPrevented:n=!0}={}){return function(l){if(e==null||e(l),n===!1||!l.defaultPrevented)return t==null?void 0:t(l)}}function ea(e,t=[]){let n=[];function r(s,o){const a=v.createContext(o),u=n.length;n=[...n,o];const c=f=>{var h;const{scope:p,children:y,...w}=f,x=((h=p==null?void 0:p[e])==null?void 0:h[u])||a,j=v.useMemo(()=>w,Object.values(w));return i.jsx(x.Provider,{value:j,children:y})};c.displayName=s+"Provider";function d(f,p){var x;const y=((x=p==null?void 0:p[e])==null?void 0:x[u])||a,w=v.useContext(y);if(w)return w;if(o!==void 0)return o;throw new Error(`\`${f}\` must be used within \`${s}\``)}return[c,d]}const l=()=>{const s=n.map(o=>v.createContext(o));return function(a){const u=(a==null?void 0:a[e])||s;return v.useMemo(()=>({[`__scope${e}`]:{...a,[e]:u}}),[a,u])}};return l.scopeName=e,[r,s0(l,...t)]}function s0(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const r=e.map(l=>({useScope:l(),scopeName:l.scopeName}));return function(s){const o=r.reduce((a,{useScope:u,scopeName:c})=>{const f=u(s)[`__scope${c}`];return{...a,...f}},{});return v.useMemo(()=>({[`__scope${t.scopeName}`]:o}),[o])}};return n.scopeName=t.scopeName,n}function o0(e){const t=e+"CollectionProvider",[n,r]=ea(t),[l,s]=n(t,{collectionRef:{current:null},itemMap:new Map}),o=x=>{const{scope:j,children:h}=x,m=lt.useRef(null),g=lt.useRef(new Map).current;return i.jsx(l,{scope:j,itemMap:g,collectionRef:m,children:h})};o.displayName=t;const a=e+"CollectionSlot",u=ql(a),c=lt.forwardRef((x,j)=>{const{scope:h,children:m}=x,g=s(a,h),N=Zl(j,g.collectionRef);return i.jsx(u,{ref:N,children:m})});c.displayName=a;const d=e+"CollectionItemSlot",f="data-radix-collection-item",p=ql(d),y=lt.forwardRef((x,j)=>{const{scope:h,children:m,...g}=x,N=lt.useRef(null),S=Zl(j,N),E=s(d,h);return lt.useEffect(()=>(E.itemMap.set(N,{ref:N,...g}),()=>void E.itemMap.delete(N))),i.jsx(p,{[f]:"",ref:S,children:m})});y.displayName=d;function w(x){const j=s(e+"CollectionConsumer",x);return lt.useCallback(()=>{const m=j.collectionRef.current;if(!m)return[];const g=Array.from(m.querySelectorAll(`[${f}]`));return Array.from(j.itemMap.values()).sort((E,_)=>g.indexOf(E.ref.current)-g.indexOf(_.ref.current))},[j.collectionRef,j.itemMap])}return[{Provider:o,Slot:c,ItemSlot:y},w,r]}var es=globalThis!=null&&globalThis.document?v.useLayoutEffect:()=>{},i0=ni[" useId ".trim().toString()]||(()=>{}),a0=0;function gf(e){const[t,n]=v.useState(i0());return es(()=>{e||n(r=>r??String(a0++))},[e]),e||(t?`radix-${t}`:"")}var u0=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],un=u0.reduce((e,t)=>{const n=ql(`Primitive.${t}`),r=v.forwardRef((l,s)=>{const{asChild:o,...a}=l,u=o?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),i.jsx(u,{...a,ref:s})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{});function c0(e){const t=v.useRef(e);return v.useEffect(()=>{t.current=e}),v.useMemo(()=>(...n)=>{var r;return(r=t.current)==null?void 0:r.call(t,...n)},[])}var d0=ni[" useInsertionEffect ".trim().toString()]||es;function vf({prop:e,defaultProp:t,onChange:n=()=>{},caller:r}){const[l,s,o]=f0({defaultProp:t,onChange:n}),a=e!==void 0,u=a?e:l;{const d=v.useRef(e!==void 0);v.useEffect(()=>{const f=d.current;f!==a&&console.warn(`${r} is changing from ${f?"controlled":"uncontrolled"} to ${a?"controlled":"uncontrolled"}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`),d.current=a},[a,r])}const c=v.useCallback(d=>{var f;if(a){const p=p0(d)?d(e):d;p!==e&&((f=o.current)==null||f.call(o,p))}else s(d)},[a,e,s,o]);return[u,c]}function f0({defaultProp:e,onChange:t}){const[n,r]=v.useState(e),l=v.useRef(n),s=v.useRef(t);return d0(()=>{s.current=t},[t]),v.useEffect(()=>{var o;l.current!==n&&((o=s.current)==null||o.call(s,n),l.current=n)},[n,l]),[n,r,s]}function p0(e){return typeof e=="function"}var m0=v.createContext(void 0);function xf(e){const t=v.useContext(m0);return e||t||"ltr"}var Gs="rovingFocusGroup.onEntryFocus",h0={bubbles:!1,cancelable:!0},Ur="RovingFocusGroup",[Xo,yf,g0]=o0(Ur),[v0,wf]=ea(Ur,[g0]),[x0,y0]=v0(Ur),Nf=v.forwardRef((e,t)=>i.jsx(Xo.Provider,{scope:e.__scopeRovingFocusGroup,children:i.jsx(Xo.Slot,{scope:e.__scopeRovingFocusGroup,children:i.jsx(w0,{...e,ref:t})})}));Nf.displayName=Ur;var w0=v.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,orientation:r,loop:l=!1,dir:s,currentTabStopId:o,defaultCurrentTabStopId:a,onCurrentTabStopIdChange:u,onEntryFocus:c,preventScrollOnEntryFocus:d=!1,...f}=e,p=v.useRef(null),y=Zl(t,p),w=xf(s),[x,j]=vf({prop:o,defaultProp:a??null,onChange:u,caller:Ur}),[h,m]=v.useState(!1),g=c0(c),N=yf(n),S=v.useRef(!1),[E,_]=v.useState(0);return v.useEffect(()=>{const C=p.current;if(C)return C.addEventListener(Gs,g),()=>C.removeEventListener(Gs,g)},[g]),i.jsx(x0,{scope:n,orientation:r,dir:w,loop:l,currentTabStopId:x,onItemFocus:v.useCallback(C=>j(C),[j]),onItemShiftTab:v.useCallback(()=>m(!0),[]),onFocusableItemAdd:v.useCallback(()=>_(C=>C+1),[]),onFocusableItemRemove:v.useCallback(()=>_(C=>C-1),[]),children:i.jsx(un.div,{tabIndex:h||E===0?-1:0,"data-orientation":r,...f,ref:y,style:{outline:"none",...e.style},onMouseDown:dt(e.onMouseDown,()=>{S.current=!0}),onFocus:dt(e.onFocus,C=>{const B=!S.current;if(C.target===C.currentTarget&&B&&!h){const M=new CustomEvent(Gs,h0);if(C.currentTarget.dispatchEvent(M),!M.defaultPrevented){const re=N().filter(fe=>fe.focusable),A=re.find(fe=>fe.active),Ye=re.find(fe=>fe.id===x),cn=[A,Ye,...re].filter(Boolean).map(fe=>fe.ref.current);Sf(cn,d)}}S.current=!1}),onBlur:dt(e.onBlur,()=>m(!1))})})}),jf="RovingFocusGroupItem",kf=v.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,focusable:r=!0,active:l=!1,tabStopId:s,children:o,...a}=e,u=gf(),c=s||u,d=y0(jf,n),f=d.currentTabStopId===c,p=yf(n),{onFocusableItemAdd:y,onFocusableItemRemove:w,currentTabStopId:x}=d;return v.useEffect(()=>{if(r)return y(),()=>w()},[r,y,w]),i.jsx(Xo.ItemSlot,{scope:n,id:c,focusable:r,active:l,children:i.jsx(un.span,{tabIndex:f?0:-1,"data-orientation":d.orientation,...a,ref:t,onMouseDown:dt(e.onMouseDown,j=>{r?d.onItemFocus(c):j.preventDefault()}),onFocus:dt(e.onFocus,()=>d.onItemFocus(c)),onKeyDown:dt(e.onKeyDown,j=>{if(j.key==="Tab"&&j.shiftKey){d.onItemShiftTab();return}if(j.target!==j.currentTarget)return;const h=k0(j,d.orientation,d.dir);if(h!==void 0){if(j.metaKey||j.ctrlKey||j.altKey||j.shiftKey)return;j.preventDefault();let g=p().filter(N=>N.focusable).map(N=>N.ref.current);if(h==="last")g.reverse();else if(h==="prev"||h==="next"){h==="prev"&&g.reverse();const N=g.indexOf(j.currentTarget);g=d.loop?S0(g,N+1):g.slice(N+1)}setTimeout(()=>Sf(g))}}),children:typeof o=="function"?o({isCurrentTabStop:f,hasTabStop:x!=null}):o})})});kf.displayName=jf;var N0={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function j0(e,t){return t!=="rtl"?e:e==="ArrowLeft"?"ArrowRight":e==="ArrowRight"?"ArrowLeft":e}function k0(e,t,n){const r=j0(e.key,n);if(!(t==="vertical"&&["ArrowLeft","ArrowRight"].includes(r))&&!(t==="horizontal"&&["ArrowUp","ArrowDown"].includes(r)))return N0[r]}function Sf(e,t=!1){const n=document.activeElement;for(const r of e)if(r===n||(r.focus({preventScroll:t}),document.activeElement!==n))return}function S0(e,t){return e.map((n,r)=>e[(t+r)%e.length])}var C0=Nf,E0=kf;function _0(e,t){return v.useReducer((n,r)=>t[n][r]??n,e)}var Cf=e=>{const{present:t,children:n}=e,r=P0(t),l=typeof n=="function"?n({present:r.isPresent}):v.Children.only(n),s=Zl(r.ref,T0(l));return typeof n=="function"||r.isPresent?v.cloneElement(l,{ref:s}):null};Cf.displayName="Presence";function P0(e){const[t,n]=v.useState(),r=v.useRef(null),l=v.useRef(e),s=v.useRef("none"),o=e?"mounted":"unmounted",[a,u]=_0(o,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return v.useEffect(()=>{const c=il(r.current);s.current=a==="mounted"?c:"none"},[a]),es(()=>{const c=r.current,d=l.current;if(d!==e){const p=s.current,y=il(c);e?u("MOUNT"):y==="none"||(c==null?void 0:c.display)==="none"?u("UNMOUNT"):u(d&&p!==y?"ANIMATION_OUT":"UNMOUNT"),l.current=e}},[e,u]),es(()=>{if(t){let c;const d=t.ownerDocument.defaultView??window,f=y=>{const x=il(r.current).includes(CSS.escape(y.animationName));if(y.target===t&&x&&(u("ANIMATION_END"),!l.current)){const j=t.style.animationFillMode;t.style.animationFillMode="forwards",c=d.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=j)})}},p=y=>{y.target===t&&(s.current=il(r.current))};return t.addEventListener("animationstart",p),t.addEventListener("animationcancel",f),t.addEventListener("animationend",f),()=>{d.clearTimeout(c),t.removeEventListener("animationstart",p),t.removeEventListener("animationcancel",f),t.removeEventListener("animationend",f)}}else u("ANIMATION_END")},[t,u]),{isPresent:["mounted","unmountSuspended"].includes(a),ref:v.useCallback(c=>{r.current=c?getComputedStyle(c):null,n(c)},[])}}function il(e){return(e==null?void 0:e.animationName)||"none"}function T0(e){var r,l;let t=(r=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(l=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:l.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var xs="Tabs",[b0,D0]=ea(xs,[wf]),Ef=wf(),[M0,ta]=b0(xs),_f=v.forwardRef((e,t)=>{const{__scopeTabs:n,value:r,onValueChange:l,defaultValue:s,orientation:o="horizontal",dir:a,activationMode:u="automatic",...c}=e,d=xf(a),[f,p]=vf({prop:r,onChange:l,defaultProp:s??"",caller:xs});return i.jsx(M0,{scope:n,baseId:gf(),value:f,onValueChange:p,orientation:o,dir:d,activationMode:u,children:i.jsx(un.div,{dir:d,"data-orientation":o,...c,ref:t})})});_f.displayName=xs;var Pf="TabsList",Tf=v.forwardRef((e,t)=>{const{__scopeTabs:n,loop:r=!0,...l}=e,s=ta(Pf,n),o=Ef(n);return i.jsx(C0,{asChild:!0,...o,orientation:s.orientation,dir:s.dir,loop:r,children:i.jsx(un.div,{role:"tablist","aria-orientation":s.orientation,...l,ref:t})})});Tf.displayName=Pf;var bf="TabsTrigger",Mf=v.forwardRef((e,t)=>{const{__scopeTabs:n,value:r,disabled:l=!1,...s}=e,o=ta(bf,n),a=Ef(n),u=zf(o.baseId,r),c=Lf(o.baseId,r),d=r===o.value;return i.jsx(E0,{asChild:!0,...a,focusable:!l,active:d,children:i.jsx(un.button,{type:"button",role:"tab","aria-selected":d,"aria-controls":c,"data-state":d?"active":"inactive","data-disabled":l?"":void 0,disabled:l,id:u,...s,ref:t,onMouseDown:dt(e.onMouseDown,f=>{!l&&f.button===0&&f.ctrlKey===!1?o.onValueChange(r):f.preventDefault()}),onKeyDown:dt(e.onKeyDown,f=>{[" ","Enter"].includes(f.key)&&o.onValueChange(r)}),onFocus:dt(e.onFocus,()=>{const f=o.activationMode!=="manual";!d&&!l&&f&&o.onValueChange(r)})})})});Mf.displayName=bf;var Rf="TabsContent",If=v.forwardRef((e,t)=>{const{__scopeTabs:n,value:r,forceMount:l,children:s,...o}=e,a=ta(Rf,n),u=zf(a.baseId,r),c=Lf(a.baseId,r),d=r===a.value,f=v.useRef(d);return v.useEffect(()=>{const p=requestAnimationFrame(()=>f.current=!1);return()=>cancelAnimationFrame(p)},[]),i.jsx(Cf,{present:l||d,children:({present:p})=>i.jsx(un.div,{"data-state":d?"active":"inactive","data-orientation":a.orientation,role:"tabpanel","aria-labelledby":u,hidden:!p,id:c,tabIndex:0,...o,ref:t,style:{...e.style,animationDuration:f.current?"0s":void 0},children:p&&s})})});If.displayName=Rf;function zf(e,t){return`${e}-trigger-${t}`}function Lf(e,t){return`${e}-content-${t}`}var R0=_f,Af=Tf,Of=Mf,Ff=If;const I0=R0,$f=v.forwardRef(({className:e,...t},n)=>i.jsx(Af,{ref:n,className:Ne("inline-flex h-10 items-center justify-center rounded-md bg-muted p-1 text-muted-foreground",e),...t}));$f.displayName=Af.displayName;const Nl=v.forwardRef(({className:e,...t},n)=>i.jsx(Of,{ref:n,className:Ne("inline-flex items-center justify-center whitespace-nowrap rounded-sm px-3 py-1.5 text-sm font-medium ring-offset-background transition-all focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 data-[state=active]:bg-background data-[state=active]:text-foreground data-[state=active]:shadow-sm",e),...t}));Nl.displayName=Of.displayName;const jl=v.forwardRef(({className:e,...t},n)=>i.jsx(Ff,{ref:n,className:Ne("mt-2 ring-offset-background focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2",e),...t}));jl.displayName=Ff.displayName;function z0(){return[{id:"code-reviewer",name:"Code Review Expert",description:"Professional code reviewer that provides detailed analysis, suggests improvements, and identifies potential issues.",author:"EdgeLLM Team",category:"coding",tags:["code review","programming","best practices"],model:"Qwen/Qwen3-30B-A3B",systemPrompt:`You are a senior software engineer specializing in code review. Analyze the provided code for: + +1. **Code Quality**: Structure, readability, maintainability +2. **Best Practices**: Following language conventions and patterns +3. **Performance**: Potential optimizations and bottlenecks +4. **Security**: Common vulnerabilities and security issues +5. **Testing**: Testability and edge cases + +Provide constructive feedback with specific examples and actionable suggestions.`,temperature:.3,maxTokens:1500,likes:245,downloads:1200,isOfficial:!0,createdAt:"2024-01-15"},{id:"writing-tutor",name:"Academic Writing Tutor",description:"Helps improve academic writing with structure suggestions, grammar corrections, and clarity enhancements.",author:"Academic Guild",category:"writing",tags:["academic writing","essay","research"],model:"Qwen/Qwen3-30B-A3B",systemPrompt:`You are an experienced academic writing tutor. Help users improve their writing by: + +1. **Structure & Organization**: Clear thesis, logical flow, proper transitions +2. **Clarity & Precision**: Eliminate ambiguity, improve word choice +3. **Academic Style**: Formal tone, appropriate citations, scholarly voice +4. **Grammar & Mechanics**: Correct errors, improve sentence variety +5. **Argument Development**: Strengthen evidence, address counterarguments + +Provide specific feedback with examples and rewrite suggestions where helpful.`,temperature:.4,maxTokens:1200,likes:189,downloads:856,isOfficial:!1,createdAt:"2024-01-20"},{id:"data-analyst",name:"Data Analysis Assistant",description:"Helps analyze data, create visualizations, and explain statistical concepts in simple terms.",author:"DataPro",category:"analysis",tags:["data science","statistics","visualization"],model:"Qwen/Qwen3-30B-A3B",systemPrompt:`You are a data analysis expert. Help users understand and analyze data by: + +1. **Data Exploration**: Identify patterns, outliers, relationships +2. **Statistical Analysis**: Apply appropriate tests, interpret results +3. **Visualization**: Suggest effective charts and graphs +4. **Insights**: Draw meaningful conclusions from data +5. **Communication**: Explain complex concepts simply + +Provide step-by-step analysis and practical recommendations.`,temperature:.2,maxTokens:1e3,likes:156,downloads:643,isOfficial:!1,createdAt:"2024-01-25"},{id:"creative-writer",name:"Creative Writing Coach",description:"Inspires creativity and helps develop compelling stories, characters, and narrative techniques.",author:"StoryMaster",category:"creative",tags:["creative writing","storytelling","fiction"],model:"Qwen/Qwen3-30B-A3B",systemPrompt:`You are a creative writing coach with expertise in storytelling. Help writers by: + +1. **Story Development**: Plot structure, pacing, conflict resolution +2. **Character Creation**: Compelling personalities, realistic dialogue, character arcs +3. **World Building**: Consistent settings, atmosphere, details +4. **Writing Techniques**: Show vs tell, point of view, voice +5. **Inspiration**: Creative prompts, overcoming writer's block + +Provide encouraging feedback and concrete suggestions to enhance creativity.`,temperature:.8,maxTokens:1200,likes:312,downloads:987,isOfficial:!1,createdAt:"2024-01-30"},{id:"interview-prep",name:"Interview Preparation Coach",description:"Helps prepare for job interviews with practice questions, answer strategies, and confidence building.",author:"CareerBoost",category:"career",tags:["interview","job search","career"],model:"Qwen/Qwen3-30B-A3B",systemPrompt:`You are a professional career coach specializing in interview preparation. Help candidates by: + +1. **Question Practice**: Common and behavioral interview questions +2. **Answer Framework**: STAR method, structured responses +3. **Company Research**: Industry insights, company-specific preparation +4. **Confidence Building**: Reducing anxiety, improving presentation +5. **Follow-up**: Thank you notes, next steps + +Provide personalized advice and realistic practice scenarios.`,temperature:.5,maxTokens:1e3,likes:278,downloads:1456,isOfficial:!0,createdAt:"2024-02-05"}]}function L0(){const[e]=v.useState(z0()),[t,n]=v.useState([]);v.useEffect(()=>{r()},[]);const r=()=>{try{const c=JSON.parse(localStorage.getItem("likedTemplates")||"[]");n(c)}catch(c){console.error("Failed to load liked templates:",c)}},l=c=>{const d=t.includes(c)?t.filter(f=>f!==c):[...t,c];n(d),localStorage.setItem("likedTemplates",JSON.stringify(d))},s=c=>{const d={name:c.name,description:c.description,model:c.model,systemPrompt:c.systemPrompt,temperature:c.temperature,maxTokens:c.maxTokens};localStorage.setItem("loadAssistantConfig",JSON.stringify(d)),window.location.href="/playground"},o=e.filter(c=>c.isOfficial||c.likes>200),a=e.reduce((c,d)=>c+d.likes,0),u=e.reduce((c,d)=>c+d.downloads,0);return i.jsxs("div",{className:"min-h-screen bg-background",children:[i.jsx("div",{className:"border-b bg-background/95 backdrop-blur supports-[backdrop-filter]:bg-background/60",children:i.jsx("div",{className:"max-w-6xl mx-auto p-6",children:i.jsxs("div",{className:"flex items-center justify-between",children:[i.jsxs("div",{className:"flex items-center gap-3",children:[i.jsx("div",{className:"w-8 h-8 bg-blue-600 rounded-lg flex items-center justify-center",children:i.jsx(Ir,{className:"h-5 w-5 text-white"})}),i.jsxs("div",{children:[i.jsx("h1",{className:"text-2xl font-bold",children:"Community Templates"}),i.jsx("p",{className:"text-sm text-muted-foreground",children:"Discover and share AI assistant templates created by the community"})]})]}),i.jsxs("div",{className:"flex items-center gap-4 text-sm text-muted-foreground",children:[i.jsxs("div",{className:"flex items-center gap-1",children:[i.jsx(Cn,{className:"h-4 w-4"}),i.jsxs("span",{children:[a.toLocaleString()," likes"]})]}),i.jsxs("div",{className:"flex items-center gap-1",children:[i.jsx(Ji,{className:"h-4 w-4"}),i.jsxs("span",{children:[u.toLocaleString()," downloads"]})]})]})]})})}),i.jsx("div",{className:"flex-1 p-6",children:i.jsxs("div",{className:"max-w-6xl mx-auto space-y-6",children:[i.jsx(O,{className:"bg-blue-50 border-blue-200",children:i.jsx($,{className:"pt-6",children:i.jsxs("div",{className:"flex items-start gap-3",children:[i.jsx(Jl,{className:"h-5 w-5 text-blue-600 mt-0.5"}),i.jsxs("div",{children:[i.jsx("h3",{className:"font-medium text-blue-900",children:"Community-Powered AI"}),i.jsx("p",{className:"text-sm text-blue-700 mt-1",children:'Explore specialized AI assistant templates created by experts and the community. Click "Use Template" to load any configuration directly into your Playground.'})]})]})})}),i.jsxs(I0,{defaultValue:"all",className:"space-y-6",children:[i.jsxs($f,{className:"grid w-full grid-cols-3",children:[i.jsxs(Nl,{value:"all",className:"flex items-center gap-2",children:[i.jsx(Ir,{className:"h-4 w-4"}),"All Templates"]}),i.jsxs(Nl,{value:"featured",className:"flex items-center gap-2",children:[i.jsx(ff,{className:"h-4 w-4"}),"Featured"]}),i.jsxs(Nl,{value:"liked",className:"flex items-center gap-2",children:[i.jsx(Cn,{className:"h-4 w-4"}),"My Likes"]})]}),i.jsx(jl,{value:"all",className:"space-y-6",children:i.jsx("div",{className:"grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-4",children:e.map(c=>i.jsx(Ks,{template:c,isLiked:t.includes(c.id),onLike:()=>l(c.id),onUse:()=>s(c)},c.id))})}),i.jsx(jl,{value:"featured",className:"space-y-6",children:i.jsx("div",{className:"grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-4",children:o.map(c=>i.jsx(Ks,{template:c,isLiked:t.includes(c.id),onLike:()=>l(c.id),onUse:()=>s(c),featured:!0},c.id))})}),i.jsx(jl,{value:"liked",className:"space-y-6",children:t.length>0?i.jsx("div",{className:"grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-4",children:e.filter(c=>t.includes(c.id)).map(c=>i.jsx(Ks,{template:c,isLiked:!0,onLike:()=>l(c.id),onUse:()=>s(c)},c.id))}):i.jsxs(O,{className:"text-center py-16",children:[i.jsx(Cn,{className:"h-16 w-16 mx-auto text-muted-foreground mb-6"}),i.jsx("h3",{className:"text-xl font-medium mb-3",children:"No liked templates yet"}),i.jsx("p",{className:"text-muted-foreground mb-6 max-w-md mx-auto",children:"Explore the community templates and click the heart icon to save your favorites for easy access."})]})})]}),i.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-4 gap-6",children:[i.jsx(O,{children:i.jsx($,{className:"pt-6",children:i.jsxs("div",{className:"flex items-center justify-between",children:[i.jsxs("div",{children:[i.jsx("div",{className:"text-2xl font-bold text-blue-600",children:e.length}),i.jsx("div",{className:"text-sm text-muted-foreground",children:"Templates"})]}),i.jsx(af,{className:"h-8 w-8 text-blue-600"})]})})}),i.jsx(O,{children:i.jsx($,{className:"pt-6",children:i.jsxs("div",{className:"flex items-center justify-between",children:[i.jsxs("div",{children:[i.jsx("div",{className:"text-2xl font-bold text-green-600",children:e.filter(c=>c.isOfficial).length}),i.jsx("div",{className:"text-sm text-muted-foreground",children:"Official"})]}),i.jsx(sf,{className:"h-8 w-8 text-green-600"})]})})}),i.jsx(O,{children:i.jsx($,{className:"pt-6",children:i.jsxs("div",{className:"flex items-center justify-between",children:[i.jsxs("div",{children:[i.jsx("div",{className:"text-2xl font-bold text-red-500",children:a.toLocaleString()}),i.jsx("div",{className:"text-sm text-muted-foreground",children:"Total Likes"})]}),i.jsx(Cn,{className:"h-8 w-8 text-red-500"})]})})}),i.jsx(O,{children:i.jsx($,{className:"pt-6",children:i.jsxs("div",{className:"flex items-center justify-between",children:[i.jsxs("div",{children:[i.jsx("div",{className:"text-2xl font-bold text-purple-600",children:u.toLocaleString()}),i.jsx("div",{className:"text-sm text-muted-foreground",children:"Downloads"})]}),i.jsx(Lv,{className:"h-8 w-8 text-purple-600"})]})})})]})]})})]})}function Ks({template:e,isLiked:t,onLike:n,onUse:r,featured:l=!1}){return i.jsxs(O,{className:`hover:shadow-lg transition-all duration-200 hover:-translate-y-1 ${l?"ring-2 ring-yellow-200 shadow-md":""}`,children:[i.jsx(nt,{className:"pb-3",children:i.jsxs("div",{className:"flex items-start justify-between",children:[i.jsxs("div",{className:"flex-1",children:[i.jsxs("div",{className:"flex items-center gap-2 mb-1",children:[i.jsx(rt,{className:"text-base",children:e.name}),e.isOfficial&&i.jsxs(Se,{variant:"default",className:"text-xs px-2 py-0 bg-green-600",children:[i.jsx(sf,{className:"h-3 w-3 mr-1"}),"Official"]}),l&&i.jsx(ff,{className:"h-4 w-4 text-yellow-500 fill-current"})]}),i.jsxs("p",{className:"text-xs text-blue-600 font-medium",children:["by ",e.author]}),i.jsx("p",{className:"text-sm text-muted-foreground mt-2 line-clamp-2",children:e.description})]}),i.jsx(U,{variant:"ghost",size:"sm",onClick:n,className:t?"text-red-500":"text-muted-foreground hover:text-red-500",title:t?"Unlike":"Like",children:i.jsx(Cn,{className:`h-4 w-4 ${t?"fill-current":""}`})})]})}),i.jsxs($,{className:"space-y-4",children:[i.jsx("div",{className:"flex flex-wrap gap-1",children:e.tags.slice(0,3).map(s=>i.jsx(Se,{variant:"secondary",className:"text-xs",children:s},s))}),i.jsxs("div",{className:"grid grid-cols-2 gap-2 text-xs",children:[i.jsxs("div",{className:"bg-gray-50 rounded p-2",children:[i.jsx("span",{className:"font-medium text-gray-600",children:"Temperature:"}),i.jsx("p",{className:"text-gray-800",children:e.temperature})]}),i.jsxs("div",{className:"bg-gray-50 rounded p-2",children:[i.jsx("span",{className:"font-medium text-gray-600",children:"Max Tokens:"}),i.jsx("p",{className:"text-gray-800",children:e.maxTokens})]})]}),i.jsxs("div",{className:"flex items-center justify-between",children:[i.jsxs("div",{className:"flex items-center gap-4 text-xs text-muted-foreground",children:[i.jsxs("div",{className:"flex items-center gap-1",children:[i.jsx(Cn,{className:"h-3 w-3"}),i.jsx("span",{children:e.likes})]}),i.jsxs("div",{className:"flex items-center gap-1",children:[i.jsx(Ji,{className:"h-3 w-3"}),i.jsx("span",{children:e.downloads})]})]}),i.jsxs(U,{size:"sm",onClick:r,className:"flex items-center gap-1",children:[i.jsx(af,{className:"h-3 w-3"}),"Use"]})]})]})]})}var A0="Label",Df=v.forwardRef((e,t)=>i.jsx(un.label,{...e,ref:t,onMouseDown:n=>{var l;n.target.closest("button, input, select, textarea")||((l=e.onMouseDown)==null||l.call(e,n),!n.defaultPrevented&&n.detail>1&&n.preventDefault())}}));Df.displayName=A0;var Uf=Df;const O0=Zi("text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"),lr=v.forwardRef(({className:e,...t},n)=>i.jsx(Uf,{ref:n,className:Ne(O0(),e),...t}));lr.displayName=Uf.displayName;function F0(){return i.jsxs("div",{className:"min-h-screen bg-background",children:[i.jsx("div",{className:"border-b",children:i.jsx("div",{className:"flex h-14 items-center px-6",children:i.jsxs("div",{className:"flex items-center gap-2",children:[i.jsx(Xi,{className:"h-5 w-5"}),i.jsx("h1",{className:"text-lg font-semibold",children:"Settings"})]})})}),i.jsx("div",{className:"flex-1 p-6",children:i.jsxs("div",{className:"max-w-4xl mx-auto space-y-6",children:[i.jsxs(O,{children:[i.jsx(nt,{children:i.jsxs(rt,{className:"flex items-center gap-2",children:[i.jsx(Ev,{className:"h-5 w-5"}),"Server Configuration"]})}),i.jsx($,{className:"space-y-4",children:i.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-4",children:[i.jsxs("div",{children:[i.jsx(lr,{className:"text-sm font-medium",children:"Backend URL"}),i.jsx("div",{className:"mt-1 p-2 bg-muted rounded-md text-sm font-mono",children:window.location.origin})]}),i.jsxs("div",{children:[i.jsx(lr,{className:"text-sm font-medium",children:"Frontend URL"}),i.jsx("div",{className:"mt-1 p-2 bg-muted rounded-md text-sm font-mono",children:window.location.origin})]})]})})]}),i.jsxs(O,{children:[i.jsx(nt,{children:i.jsxs(rt,{className:"flex items-center gap-2",children:[i.jsx(Jo,{className:"h-5 w-5"}),"Privacy & Security"]})}),i.jsx($,{className:"space-y-4",children:i.jsxs("div",{className:"p-3 bg-green-50 border border-green-200 rounded-md",children:[i.jsxs("div",{className:"flex items-center gap-2 mb-2",children:[i.jsx(Jo,{className:"h-4 w-4 text-green-600"}),i.jsx("span",{className:"text-sm font-medium text-green-800",children:"Local Processing"})]}),i.jsx("p",{className:"text-xs text-green-700",children:"All AI processing happens locally on your machine. No data is sent to external servers."})]})})]}),i.jsxs(O,{children:[i.jsx(nt,{children:i.jsxs(rt,{className:"flex items-center gap-2",children:[i.jsx(cf,{className:"h-5 w-5"}),"System Information"]})}),i.jsx($,{className:"space-y-4",children:i.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-4",children:[i.jsxs("div",{children:[i.jsx(lr,{className:"text-sm font-medium",children:"Platform"}),i.jsxs("div",{className:"mt-1 flex items-center gap-2",children:[i.jsx(Se,{variant:"outline",children:"Local"}),i.jsx("span",{className:"text-sm text-muted-foreground",children:"Privacy-focused AI"})]})]}),i.jsxs("div",{children:[i.jsx(lr,{className:"text-sm font-medium",children:"Status"}),i.jsx("div",{className:"mt-1",children:i.jsx(Se,{variant:"outline",children:"Running"})})]})]})})]})]})})]})}function $0(){return i.jsx(gg,{children:i.jsx(ug,{children:i.jsxs(Xe,{path:"/",element:i.jsx(Uv,{}),children:[i.jsx(Xe,{index:!0,element:i.jsx(Zv,{})}),i.jsx(Xe,{path:"playground",element:i.jsx(qv,{})}),i.jsx(Xe,{path:"chat",element:i.jsx(e0,{})}),i.jsx(Xe,{path:"assistant-builder",element:i.jsx(t0,{})}),i.jsx(Xe,{path:"models",element:i.jsx(n0,{})}),i.jsx(Xe,{path:"assistants",element:i.jsx(r0,{})}),i.jsx(Xe,{path:"community",element:i.jsx(L0,{})}),i.jsx(Xe,{path:"settings",element:i.jsx(F0,{})})]})})})}Ys.createRoot(document.getElementById("root")).render(i.jsx(lt.StrictMode,{children:i.jsx($0,{})})); +//# sourceMappingURL=index-66e7a223.js.map