xiaozuoassistant 0.1.41
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +90 -0
- package/bin/cli.js +429 -0
- package/config.json +36 -0
- package/dist/client/assets/browser-ponyfill-DNlTAU2D.js +2 -0
- package/dist/client/assets/index-BPATxdcV.js +153 -0
- package/dist/client/assets/index-CgL5gMVL.css +1 -0
- package/dist/client/favicon.svg +4 -0
- package/dist/client/index.html +354 -0
- package/dist/client/locales/en/translation.json +77 -0
- package/dist/client/locales/zh/translation.json +77 -0
- package/dist/server/agents/office.js +23 -0
- package/dist/server/app.js +50 -0
- package/dist/server/channels/base-channel.js +13 -0
- package/dist/server/channels/create-channels.js +18 -0
- package/dist/server/channels/dingtalk.js +83 -0
- package/dist/server/channels/feishu.js +95 -0
- package/dist/server/channels/telegram.js +53 -0
- package/dist/server/channels/terminal.js +49 -0
- package/dist/server/channels/web.js +45 -0
- package/dist/server/channels/wechat.js +107 -0
- package/dist/server/config/loader.js +73 -0
- package/dist/server/config/prompts.js +12 -0
- package/dist/server/core/agents/manager.js +22 -0
- package/dist/server/core/agents/runtime.js +85 -0
- package/dist/server/core/brain.js +131 -0
- package/dist/server/core/event-bus.js +24 -0
- package/dist/server/core/logger.js +71 -0
- package/dist/server/core/memories/manager.js +115 -0
- package/dist/server/core/memories/short-term.js +128 -0
- package/dist/server/core/memories/structured.js +109 -0
- package/dist/server/core/memories/vector.js +138 -0
- package/dist/server/core/memory.js +2 -0
- package/dist/server/core/plugin-manager.js +112 -0
- package/dist/server/core/plugin.js +1 -0
- package/dist/server/core/scheduler.js +24 -0
- package/dist/server/core/types.js +1 -0
- package/dist/server/index.js +318 -0
- package/dist/server/llm/openai.js +23 -0
- package/dist/server/routes/auth.js +28 -0
- package/dist/server/server/create-http.js +17 -0
- package/dist/server/server.js +29 -0
- package/dist/server/skills/base-skill.js +16 -0
- package/dist/server/skills/create-agent.js +58 -0
- package/dist/server/skills/delegate.js +39 -0
- package/dist/server/skills/file-system.js +137 -0
- package/dist/server/skills/list-agents.js +24 -0
- package/dist/server/skills/office-excel.js +84 -0
- package/dist/server/skills/office-ppt.js +58 -0
- package/dist/server/skills/office-word.js +90 -0
- package/dist/server/skills/registry.js +27 -0
- package/dist/server/skills/search.js +31 -0
- package/dist/server/skills/system-time.js +27 -0
- package/package.json +116 -0
- package/public/favicon.svg +4 -0
- package/public/locales/en/translation.json +77 -0
- package/public/locales/zh/translation.json +77 -0
|
@@ -0,0 +1,153 @@
|
|
|
1
|
+
(function(){const r=document.createElement("link").relList;if(r&&r.supports&&r.supports("modulepreload"))return;for(const u of document.querySelectorAll('link[rel="modulepreload"]'))o(u);new MutationObserver(u=>{for(const f of u)if(f.type==="childList")for(const d of f.addedNodes)d.tagName==="LINK"&&d.rel==="modulepreload"&&o(d)}).observe(document,{childList:!0,subtree:!0});function s(u){const f={};return u.integrity&&(f.integrity=u.integrity),u.referrerPolicy&&(f.referrerPolicy=u.referrerPolicy),u.crossOrigin==="use-credentials"?f.credentials="include":u.crossOrigin==="anonymous"?f.credentials="omit":f.credentials="same-origin",f}function o(u){if(u.ep)return;u.ep=!0;const f=s(u);fetch(u.href,f)}})();var mg=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function ih(a){return a&&a.__esModule&&Object.prototype.hasOwnProperty.call(a,"default")?a.default:a}var ha={exports:{}},Br={},ma={exports:{}},re={};/**
|
|
2
|
+
* @license React
|
|
3
|
+
* react.production.min.js
|
|
4
|
+
*
|
|
5
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
6
|
+
*
|
|
7
|
+
* This source code is licensed under the MIT license found in the
|
|
8
|
+
* LICENSE file in the root directory of this source tree.
|
|
9
|
+
*/var Uc;function oh(){if(Uc)return re;Uc=1;var a=Symbol.for("react.element"),r=Symbol.for("react.portal"),s=Symbol.for("react.fragment"),o=Symbol.for("react.strict_mode"),u=Symbol.for("react.profiler"),f=Symbol.for("react.provider"),d=Symbol.for("react.context"),h=Symbol.for("react.forward_ref"),m=Symbol.for("react.suspense"),y=Symbol.for("react.memo"),F=Symbol.for("react.lazy"),v=Symbol.iterator;function D(S){return S===null||typeof S!="object"?null:(S=v&&S[v]||S["@@iterator"],typeof S=="function"?S:null)}var z={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},L=Object.assign,M={};function V(S,E,R){this.props=S,this.context=E,this.refs=M,this.updater=R||z}V.prototype.isReactComponent={},V.prototype.setState=function(S,E){if(typeof S!="object"&&typeof S!="function"&&S!=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,S,E,"setState")},V.prototype.forceUpdate=function(S){this.updater.enqueueForceUpdate(this,S,"forceUpdate")};function we(){}we.prototype=V.prototype;function me(S,E,R){this.props=S,this.context=E,this.refs=M,this.updater=R||z}var ge=me.prototype=new we;ge.constructor=me,L(ge,V.prototype),ge.isPureReactComponent=!0;var G=Array.isArray,ae=Object.prototype.hasOwnProperty,Se={current:null},le={key:!0,ref:!0,__self:!0,__source:!0};function Ne(S,E,R){var $,Q={},ie=null,ve=null;if(E!=null)for($ in E.ref!==void 0&&(ve=E.ref),E.key!==void 0&&(ie=""+E.key),E)ae.call(E,$)&&!le.hasOwnProperty($)&&(Q[$]=E[$]);var ce=arguments.length-2;if(ce===1)Q.children=R;else if(1<ce){for(var Ee=Array(ce),rt=0;rt<ce;rt++)Ee[rt]=arguments[rt+2];Q.children=Ee}if(S&&S.defaultProps)for($ in ce=S.defaultProps,ce)Q[$]===void 0&&(Q[$]=ce[$]);return{$$typeof:a,type:S,key:ie,ref:ve,props:Q,_owner:Se.current}}function ye(S,E){return{$$typeof:a,type:S.type,key:E,ref:S.ref,props:S.props,_owner:S._owner}}function pe(S){return typeof S=="object"&&S!==null&&S.$$typeof===a}function Qe(S){var E={"=":"=0",":":"=2"};return"$"+S.replace(/[=:]/g,function(R){return E[R]})}var te=/\/+/g;function W(S,E){return typeof S=="object"&&S!==null&&S.key!=null?Qe(""+S.key):E.toString(36)}function Y(S,E,R,$,Q){var ie=typeof S;(ie==="undefined"||ie==="boolean")&&(S=null);var ve=!1;if(S===null)ve=!0;else switch(ie){case"string":case"number":ve=!0;break;case"object":switch(S.$$typeof){case a:case r:ve=!0}}if(ve)return ve=S,Q=Q(ve),S=$===""?"."+W(ve,0):$,G(Q)?(R="",S!=null&&(R=S.replace(te,"$&/")+"/"),Y(Q,E,R,"",function(rt){return rt})):Q!=null&&(pe(Q)&&(Q=ye(Q,R+(!Q.key||ve&&ve.key===Q.key?"":(""+Q.key).replace(te,"$&/")+"/")+S)),E.push(Q)),1;if(ve=0,$=$===""?".":$+":",G(S))for(var ce=0;ce<S.length;ce++){ie=S[ce];var Ee=$+W(ie,ce);ve+=Y(ie,E,R,Ee,Q)}else if(Ee=D(S),typeof Ee=="function")for(S=Ee.call(S),ce=0;!(ie=S.next()).done;)ie=ie.value,Ee=$+W(ie,ce++),ve+=Y(ie,E,R,Ee,Q);else if(ie==="object")throw E=String(S),Error("Objects are not valid as a React child (found: "+(E==="[object Object]"?"object with keys {"+Object.keys(S).join(", ")+"}":E)+"). If you meant to render a collection of children, use an array instead.");return ve}function ue(S,E,R){if(S==null)return S;var $=[],Q=0;return Y(S,$,"","",function(ie){return E.call(R,ie,Q++)}),$}function de(S){if(S._status===-1){var E=S._result;E=E(),E.then(function(R){(S._status===0||S._status===-1)&&(S._status=1,S._result=R)},function(R){(S._status===0||S._status===-1)&&(S._status=2,S._result=R)}),S._status===-1&&(S._status=0,S._result=E)}if(S._status===1)return S._result.default;throw S._result}var se={current:null},T={transition:null},Z={ReactCurrentDispatcher:se,ReactCurrentBatchConfig:T,ReactCurrentOwner:Se};function B(){throw Error("act(...) is not supported in production builds of React.")}return re.Children={map:ue,forEach:function(S,E,R){ue(S,function(){E.apply(this,arguments)},R)},count:function(S){var E=0;return ue(S,function(){E++}),E},toArray:function(S){return ue(S,function(E){return E})||[]},only:function(S){if(!pe(S))throw Error("React.Children.only expected to receive a single React element child.");return S}},re.Component=V,re.Fragment=s,re.Profiler=u,re.PureComponent=me,re.StrictMode=o,re.Suspense=m,re.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=Z,re.act=B,re.cloneElement=function(S,E,R){if(S==null)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+S+".");var $=L({},S.props),Q=S.key,ie=S.ref,ve=S._owner;if(E!=null){if(E.ref!==void 0&&(ie=E.ref,ve=Se.current),E.key!==void 0&&(Q=""+E.key),S.type&&S.type.defaultProps)var ce=S.type.defaultProps;for(Ee in E)ae.call(E,Ee)&&!le.hasOwnProperty(Ee)&&($[Ee]=E[Ee]===void 0&&ce!==void 0?ce[Ee]:E[Ee])}var Ee=arguments.length-2;if(Ee===1)$.children=R;else if(1<Ee){ce=Array(Ee);for(var rt=0;rt<Ee;rt++)ce[rt]=arguments[rt+2];$.children=ce}return{$$typeof:a,type:S.type,key:Q,ref:ie,props:$,_owner:ve}},re.createContext=function(S){return S={$$typeof:d,_currentValue:S,_currentValue2:S,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null},S.Provider={$$typeof:f,_context:S},S.Consumer=S},re.createElement=Ne,re.createFactory=function(S){var E=Ne.bind(null,S);return E.type=S,E},re.createRef=function(){return{current:null}},re.forwardRef=function(S){return{$$typeof:h,render:S}},re.isValidElement=pe,re.lazy=function(S){return{$$typeof:F,_payload:{_status:-1,_result:S},_init:de}},re.memo=function(S,E){return{$$typeof:y,type:S,compare:E===void 0?null:E}},re.startTransition=function(S){var E=T.transition;T.transition={};try{S()}finally{T.transition=E}},re.unstable_act=B,re.useCallback=function(S,E){return se.current.useCallback(S,E)},re.useContext=function(S){return se.current.useContext(S)},re.useDebugValue=function(){},re.useDeferredValue=function(S){return se.current.useDeferredValue(S)},re.useEffect=function(S,E){return se.current.useEffect(S,E)},re.useId=function(){return se.current.useId()},re.useImperativeHandle=function(S,E,R){return se.current.useImperativeHandle(S,E,R)},re.useInsertionEffect=function(S,E){return se.current.useInsertionEffect(S,E)},re.useLayoutEffect=function(S,E){return se.current.useLayoutEffect(S,E)},re.useMemo=function(S,E){return se.current.useMemo(S,E)},re.useReducer=function(S,E,R){return se.current.useReducer(S,E,R)},re.useRef=function(S){return se.current.useRef(S)},re.useState=function(S){return se.current.useState(S)},re.useSyncExternalStore=function(S,E,R){return se.current.useSyncExternalStore(S,E,R)},re.useTransition=function(){return se.current.useTransition()},re.version="18.3.1",re}var Ic;function gi(){return Ic||(Ic=1,ma.exports=oh()),ma.exports}/**
|
|
10
|
+
* @license React
|
|
11
|
+
* react-jsx-runtime.production.min.js
|
|
12
|
+
*
|
|
13
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
14
|
+
*
|
|
15
|
+
* This source code is licensed under the MIT license found in the
|
|
16
|
+
* LICENSE file in the root directory of this source tree.
|
|
17
|
+
*/var bc;function ah(){if(bc)return Br;bc=1;var a=gi(),r=Symbol.for("react.element"),s=Symbol.for("react.fragment"),o=Object.prototype.hasOwnProperty,u=a.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,f={key:!0,ref:!0,__self:!0,__source:!0};function d(h,m,y){var F,v={},D=null,z=null;y!==void 0&&(D=""+y),m.key!==void 0&&(D=""+m.key),m.ref!==void 0&&(z=m.ref);for(F in m)o.call(m,F)&&!f.hasOwnProperty(F)&&(v[F]=m[F]);if(h&&h.defaultProps)for(F in m=h.defaultProps,m)v[F]===void 0&&(v[F]=m[F]);return{$$typeof:r,type:h,key:D,ref:z,props:v,_owner:u.current}}return Br.Fragment=s,Br.jsx=d,Br.jsxs=d,Br}var $c;function lh(){return $c||($c=1,ha.exports=ah()),ha.exports}var C=lh(),ne=gi();const ri=ih(ne);var si={},ga={exports:{}},nt={},ya={exports:{}},va={};/**
|
|
18
|
+
* @license React
|
|
19
|
+
* scheduler.production.min.js
|
|
20
|
+
*
|
|
21
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
22
|
+
*
|
|
23
|
+
* This source code is licensed under the MIT license found in the
|
|
24
|
+
* LICENSE file in the root directory of this source tree.
|
|
25
|
+
*/var Xc;function uh(){return Xc||(Xc=1,(function(a){function r(T,Z){var B=T.length;T.push(Z);e:for(;0<B;){var S=B-1>>>1,E=T[S];if(0<u(E,Z))T[S]=Z,T[B]=E,B=S;else break e}}function s(T){return T.length===0?null:T[0]}function o(T){if(T.length===0)return null;var Z=T[0],B=T.pop();if(B!==Z){T[0]=B;e:for(var S=0,E=T.length,R=E>>>1;S<R;){var $=2*(S+1)-1,Q=T[$],ie=$+1,ve=T[ie];if(0>u(Q,B))ie<E&&0>u(ve,Q)?(T[S]=ve,T[ie]=B,S=ie):(T[S]=Q,T[$]=B,S=$);else if(ie<E&&0>u(ve,B))T[S]=ve,T[ie]=B,S=ie;else break e}}return Z}function u(T,Z){var B=T.sortIndex-Z.sortIndex;return B!==0?B:T.id-Z.id}if(typeof performance=="object"&&typeof performance.now=="function"){var f=performance;a.unstable_now=function(){return f.now()}}else{var d=Date,h=d.now();a.unstable_now=function(){return d.now()-h}}var m=[],y=[],F=1,v=null,D=3,z=!1,L=!1,M=!1,V=typeof setTimeout=="function"?setTimeout:null,we=typeof clearTimeout=="function"?clearTimeout:null,me=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function ge(T){for(var Z=s(y);Z!==null;){if(Z.callback===null)o(y);else if(Z.startTime<=T)o(y),Z.sortIndex=Z.expirationTime,r(m,Z);else break;Z=s(y)}}function G(T){if(M=!1,ge(T),!L)if(s(m)!==null)L=!0,de(ae);else{var Z=s(y);Z!==null&&se(G,Z.startTime-T)}}function ae(T,Z){L=!1,M&&(M=!1,we(Ne),Ne=-1),z=!0;var B=D;try{for(ge(Z),v=s(m);v!==null&&(!(v.expirationTime>Z)||T&&!Qe());){var S=v.callback;if(typeof S=="function"){v.callback=null,D=v.priorityLevel;var E=S(v.expirationTime<=Z);Z=a.unstable_now(),typeof E=="function"?v.callback=E:v===s(m)&&o(m),ge(Z)}else o(m);v=s(m)}if(v!==null)var R=!0;else{var $=s(y);$!==null&&se(G,$.startTime-Z),R=!1}return R}finally{v=null,D=B,z=!1}}var Se=!1,le=null,Ne=-1,ye=5,pe=-1;function Qe(){return!(a.unstable_now()-pe<ye)}function te(){if(le!==null){var T=a.unstable_now();pe=T;var Z=!0;try{Z=le(!0,T)}finally{Z?W():(Se=!1,le=null)}}else Se=!1}var W;if(typeof me=="function")W=function(){me(te)};else if(typeof MessageChannel<"u"){var Y=new MessageChannel,ue=Y.port2;Y.port1.onmessage=te,W=function(){ue.postMessage(null)}}else W=function(){V(te,0)};function de(T){le=T,Se||(Se=!0,W())}function se(T,Z){Ne=V(function(){T(a.unstable_now())},Z)}a.unstable_IdlePriority=5,a.unstable_ImmediatePriority=1,a.unstable_LowPriority=4,a.unstable_NormalPriority=3,a.unstable_Profiling=null,a.unstable_UserBlockingPriority=2,a.unstable_cancelCallback=function(T){T.callback=null},a.unstable_continueExecution=function(){L||z||(L=!0,de(ae))},a.unstable_forceFrameRate=function(T){0>T||125<T?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):ye=0<T?Math.floor(1e3/T):5},a.unstable_getCurrentPriorityLevel=function(){return D},a.unstable_getFirstCallbackNode=function(){return s(m)},a.unstable_next=function(T){switch(D){case 1:case 2:case 3:var Z=3;break;default:Z=D}var B=D;D=Z;try{return T()}finally{D=B}},a.unstable_pauseExecution=function(){},a.unstable_requestPaint=function(){},a.unstable_runWithPriority=function(T,Z){switch(T){case 1:case 2:case 3:case 4:case 5:break;default:T=3}var B=D;D=T;try{return Z()}finally{D=B}},a.unstable_scheduleCallback=function(T,Z,B){var S=a.unstable_now();switch(typeof B=="object"&&B!==null?(B=B.delay,B=typeof B=="number"&&0<B?S+B:S):B=S,T){case 1:var E=-1;break;case 2:E=250;break;case 5:E=1073741823;break;case 4:E=1e4;break;default:E=5e3}return E=B+E,T={id:F++,callback:Z,priorityLevel:T,startTime:B,expirationTime:E,sortIndex:-1},B>S?(T.sortIndex=B,r(y,T),s(m)===null&&T===s(y)&&(M?(we(Ne),Ne=-1):M=!0,se(G,B-S))):(T.sortIndex=E,r(m,T),L||z||(L=!0,de(ae))),T},a.unstable_shouldYield=Qe,a.unstable_wrapCallback=function(T){var Z=D;return function(){var B=D;D=Z;try{return T.apply(this,arguments)}finally{D=B}}}})(va)),va}var Vc;function ch(){return Vc||(Vc=1,ya.exports=uh()),ya.exports}/**
|
|
26
|
+
* @license React
|
|
27
|
+
* react-dom.production.min.js
|
|
28
|
+
*
|
|
29
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
30
|
+
*
|
|
31
|
+
* This source code is licensed under the MIT license found in the
|
|
32
|
+
* LICENSE file in the root directory of this source tree.
|
|
33
|
+
*/var Hc;function fh(){if(Hc)return nt;Hc=1;var a=gi(),r=ch();function s(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,n=1;n<arguments.length;n++)t+="&args[]="+encodeURIComponent(arguments[n]);return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var o=new Set,u={};function f(e,t){d(e,t),d(e+"Capture",t)}function d(e,t){for(u[e]=t,e=0;e<t.length;e++)o.add(t[e])}var h=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),m=Object.prototype.hasOwnProperty,y=/^[: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]*$/,F={},v={};function D(e){return m.call(v,e)?!0:m.call(F,e)?!1:y.test(e)?v[e]=!0:(F[e]=!0,!1)}function z(e,t,n,i){if(n!==null&&n.type===0)return!1;switch(typeof t){case"function":case"symbol":return!0;case"boolean":return i?!1:n!==null?!n.acceptsBooleans:(e=e.toLowerCase().slice(0,5),e!=="data-"&&e!=="aria-");default:return!1}}function L(e,t,n,i){if(t===null||typeof t>"u"||z(e,t,n,i))return!0;if(i)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 M(e,t,n,i,l,c,p){this.acceptsBooleans=t===2||t===3||t===4,this.attributeName=i,this.attributeNamespace=l,this.mustUseProperty=n,this.propertyName=e,this.type=t,this.sanitizeURL=c,this.removeEmptyString=p}var V={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){V[e]=new M(e,0,!1,e,null,!1,!1)}),[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];V[t]=new M(t,1,!1,e[1],null,!1,!1)}),["contentEditable","draggable","spellCheck","value"].forEach(function(e){V[e]=new M(e,2,!1,e.toLowerCase(),null,!1,!1)}),["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){V[e]=new M(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){V[e]=new M(e,3,!1,e.toLowerCase(),null,!1,!1)}),["checked","multiple","muted","selected"].forEach(function(e){V[e]=new M(e,3,!0,e,null,!1,!1)}),["capture","download"].forEach(function(e){V[e]=new M(e,4,!1,e,null,!1,!1)}),["cols","rows","size","span"].forEach(function(e){V[e]=new M(e,6,!1,e,null,!1,!1)}),["rowSpan","start"].forEach(function(e){V[e]=new M(e,5,!1,e.toLowerCase(),null,!1,!1)});var we=/[\-:]([a-z])/g;function me(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(we,me);V[t]=new M(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(we,me);V[t]=new M(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(we,me);V[t]=new M(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)}),["tabIndex","crossOrigin"].forEach(function(e){V[e]=new M(e,1,!1,e.toLowerCase(),null,!1,!1)}),V.xlinkHref=new M("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1),["src","href","action","formAction"].forEach(function(e){V[e]=new M(e,1,!1,e.toLowerCase(),null,!0,!0)});function ge(e,t,n,i){var l=V.hasOwnProperty(t)?V[t]:null;(l!==null?l.type!==0:i||!(2<t.length)||t[0]!=="o"&&t[0]!=="O"||t[1]!=="n"&&t[1]!=="N")&&(L(t,n,l,i)&&(n=null),i||l===null?D(t)&&(n===null?e.removeAttribute(t):e.setAttribute(t,""+n)):l.mustUseProperty?e[l.propertyName]=n===null?l.type===3?!1:"":n:(t=l.attributeName,i=l.attributeNamespace,n===null?e.removeAttribute(t):(l=l.type,n=l===3||l===4&&n===!0?"":""+n,i?e.setAttributeNS(i,t,n):e.setAttribute(t,n))))}var G=a.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,ae=Symbol.for("react.element"),Se=Symbol.for("react.portal"),le=Symbol.for("react.fragment"),Ne=Symbol.for("react.strict_mode"),ye=Symbol.for("react.profiler"),pe=Symbol.for("react.provider"),Qe=Symbol.for("react.context"),te=Symbol.for("react.forward_ref"),W=Symbol.for("react.suspense"),Y=Symbol.for("react.suspense_list"),ue=Symbol.for("react.memo"),de=Symbol.for("react.lazy"),se=Symbol.for("react.offscreen"),T=Symbol.iterator;function Z(e){return e===null||typeof e!="object"?null:(e=T&&e[T]||e["@@iterator"],typeof e=="function"?e:null)}var B=Object.assign,S;function E(e){if(S===void 0)try{throw Error()}catch(n){var t=n.stack.trim().match(/\n( *(at )?)/);S=t&&t[1]||""}return`
|
|
34
|
+
`+S+e}var R=!1;function $(e,t){if(!e||R)return"";R=!0;var n=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{if(t)if(t=function(){throw Error()},Object.defineProperty(t.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(t,[])}catch(N){var i=N}Reflect.construct(e,[],t)}else{try{t.call()}catch(N){i=N}e.call(t.prototype)}else{try{throw Error()}catch(N){i=N}e()}}catch(N){if(N&&i&&typeof N.stack=="string"){for(var l=N.stack.split(`
|
|
35
|
+
`),c=i.stack.split(`
|
|
36
|
+
`),p=l.length-1,g=c.length-1;1<=p&&0<=g&&l[p]!==c[g];)g--;for(;1<=p&&0<=g;p--,g--)if(l[p]!==c[g]){if(p!==1||g!==1)do if(p--,g--,0>g||l[p]!==c[g]){var x=`
|
|
37
|
+
`+l[p].replace(" at new "," at ");return e.displayName&&x.includes("<anonymous>")&&(x=x.replace("<anonymous>",e.displayName)),x}while(1<=p&&0<=g);break}}}finally{R=!1,Error.prepareStackTrace=n}return(e=e?e.displayName||e.name:"")?E(e):""}function Q(e){switch(e.tag){case 5:return E(e.type);case 16:return E("Lazy");case 13:return E("Suspense");case 19:return E("SuspenseList");case 0:case 2:case 15:return e=$(e.type,!1),e;case 11:return e=$(e.type.render,!1),e;case 1:return e=$(e.type,!0),e;default:return""}}function ie(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 le:return"Fragment";case Se:return"Portal";case ye:return"Profiler";case Ne:return"StrictMode";case W:return"Suspense";case Y:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case Qe:return(e.displayName||"Context")+".Consumer";case pe:return(e._context.displayName||"Context")+".Provider";case te:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case ue:return t=e.displayName||null,t!==null?t:ie(e.type)||"Memo";case de:t=e._payload,e=e._init;try{return ie(e(t))}catch{}}return null}function ve(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 ie(t);case 8:return t===Ne?"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 ce(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function Ee(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function rt(e){var t=Ee(e)?"checked":"value",n=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),i=""+e[t];if(!e.hasOwnProperty(t)&&typeof n<"u"&&typeof n.get=="function"&&typeof n.set=="function"){var l=n.get,c=n.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return l.call(this)},set:function(p){i=""+p,c.call(this,p)}}),Object.defineProperty(e,t,{enumerable:n.enumerable}),{getValue:function(){return i},setValue:function(p){i=""+p},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function Wr(e){e._valueTracker||(e._valueTracker=rt(e))}function Ha(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),i="";return e&&(i=Ee(e)?e.checked?"true":"false":e.value),e=i,e!==n?(t.setValue(e),!0):!1}function Kr(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 wi(e,t){var n=t.checked;return B({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:n??e._wrapperState.initialChecked})}function Za(e,t){var n=t.defaultValue==null?"":t.defaultValue,i=t.checked!=null?t.checked:t.defaultChecked;n=ce(t.value!=null?t.value:n),e._wrapperState={initialChecked:i,initialValue:n,controlled:t.type==="checkbox"||t.type==="radio"?t.checked!=null:t.value!=null}}function Wa(e,t){t=t.checked,t!=null&&ge(e,"checked",t,!1)}function Si(e,t){Wa(e,t);var n=ce(t.value),i=t.type;if(n!=null)i==="number"?(n===0&&e.value===""||e.value!=n)&&(e.value=""+n):e.value!==""+n&&(e.value=""+n);else if(i==="submit"||i==="reset"){e.removeAttribute("value");return}t.hasOwnProperty("value")?Ci(e,t.type,n):t.hasOwnProperty("defaultValue")&&Ci(e,t.type,ce(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function Ka(e,t,n){if(t.hasOwnProperty("value")||t.hasOwnProperty("defaultValue")){var i=t.type;if(!(i!=="submit"&&i!=="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 Ci(e,t,n){(t!=="number"||Kr(e.ownerDocument)!==e)&&(n==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+n&&(e.defaultValue=""+n))}var Gn=Array.isArray;function kn(e,t,n,i){if(e=e.options,t){t={};for(var l=0;l<n.length;l++)t["$"+n[l]]=!0;for(n=0;n<e.length;n++)l=t.hasOwnProperty("$"+e[n].value),e[n].selected!==l&&(e[n].selected=l),l&&i&&(e[n].defaultSelected=!0)}else{for(n=""+ce(n),t=null,l=0;l<e.length;l++){if(e[l].value===n){e[l].selected=!0,i&&(e[l].defaultSelected=!0);return}t!==null||e[l].disabled||(t=e[l])}t!==null&&(t.selected=!0)}}function ki(e,t){if(t.dangerouslySetInnerHTML!=null)throw Error(s(91));return B({},t,{value:void 0,defaultValue:void 0,children:""+e._wrapperState.initialValue})}function qa(e,t){var n=t.value;if(n==null){if(n=t.children,t=t.defaultValue,n!=null){if(t!=null)throw Error(s(92));if(Gn(n)){if(1<n.length)throw Error(s(93));n=n[0]}t=n}t==null&&(t=""),n=t}e._wrapperState={initialValue:ce(n)}}function Qa(e,t){var n=ce(t.value),i=ce(t.defaultValue);n!=null&&(n=""+n,n!==e.value&&(e.value=n),t.defaultValue==null&&e.defaultValue!==n&&(e.defaultValue=n)),i!=null&&(e.defaultValue=""+i)}function Ya(e){var t=e.textContent;t===e._wrapperState.initialValue&&t!==""&&t!==null&&(e.value=t)}function Ja(e){switch(e){case"svg":return"http://www.w3.org/2000/svg";case"math":return"http://www.w3.org/1998/Math/MathML";default:return"http://www.w3.org/1999/xhtml"}}function Fi(e,t){return e==null||e==="http://www.w3.org/1999/xhtml"?Ja(t):e==="http://www.w3.org/2000/svg"&&t==="foreignObject"?"http://www.w3.org/1999/xhtml":e}var qr,Ga=(function(e){return typeof MSApp<"u"&&MSApp.execUnsafeLocalFunction?function(t,n,i,l){MSApp.execUnsafeLocalFunction(function(){return e(t,n,i,l)})}:e})(function(e,t){if(e.namespaceURI!=="http://www.w3.org/2000/svg"||"innerHTML"in e)e.innerHTML=t;else{for(qr=qr||document.createElement("div"),qr.innerHTML="<svg>"+t.valueOf().toString()+"</svg>",t=qr.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function er(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var tr={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},up=["Webkit","ms","Moz","O"];Object.keys(tr).forEach(function(e){up.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),tr[t]=tr[e]})});function el(e,t,n){return t==null||typeof t=="boolean"||t===""?"":n||typeof t!="number"||t===0||tr.hasOwnProperty(e)&&tr[e]?(""+t).trim():t+"px"}function tl(e,t){e=e.style;for(var n in t)if(t.hasOwnProperty(n)){var i=n.indexOf("--")===0,l=el(n,t[n],i);n==="float"&&(n="cssFloat"),i?e.setProperty(n,l):e[n]=l}}var cp=B({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 Ei(e,t){if(t){if(cp[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(s(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(s(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(s(61))}if(t.style!=null&&typeof t.style!="object")throw Error(s(62))}}function _i(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 Ni=null;function zi(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var Di=null,Fn=null,En=null;function nl(e){if(e=kr(e)){if(typeof Di!="function")throw Error(s(280));var t=e.stateNode;t&&(t=vs(t),Di(e.stateNode,e.type,t))}}function rl(e){Fn?En?En.push(e):En=[e]:Fn=e}function sl(){if(Fn){var e=Fn,t=En;if(En=Fn=null,nl(e),t)for(e=0;e<t.length;e++)nl(t[e])}}function il(e,t){return e(t)}function ol(){}var Li=!1;function al(e,t,n){if(Li)return e(t,n);Li=!0;try{return il(e,t,n)}finally{Li=!1,(Fn!==null||En!==null)&&(ol(),sl())}}function nr(e,t){var n=e.stateNode;if(n===null)return null;var i=vs(n);if(i===null)return null;n=i[t];e:switch(t){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(i=!i.disabled)||(e=e.type,i=!(e==="button"||e==="input"||e==="select"||e==="textarea")),e=!i;break e;default:e=!1}if(e)return null;if(n&&typeof n!="function")throw Error(s(231,t,typeof n));return n}var Oi=!1;if(h)try{var rr={};Object.defineProperty(rr,"passive",{get:function(){Oi=!0}}),window.addEventListener("test",rr,rr),window.removeEventListener("test",rr,rr)}catch{Oi=!1}function fp(e,t,n,i,l,c,p,g,x){var N=Array.prototype.slice.call(arguments,3);try{t.apply(n,N)}catch(A){this.onError(A)}}var sr=!1,Qr=null,Yr=!1,Ai=null,pp={onError:function(e){sr=!0,Qr=e}};function dp(e,t,n,i,l,c,p,g,x){sr=!1,Qr=null,fp.apply(pp,arguments)}function hp(e,t,n,i,l,c,p,g,x){if(dp.apply(this,arguments),sr){if(sr){var N=Qr;sr=!1,Qr=null}else throw Error(s(198));Yr||(Yr=!0,Ai=N)}}function an(e){var t=e,n=e;if(e.alternate)for(;t.return;)t=t.return;else{e=t;do t=e,(t.flags&4098)!==0&&(n=t.return),e=t.return;while(e)}return t.tag===3?n:null}function ll(e){if(e.tag===13){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function ul(e){if(an(e)!==e)throw Error(s(188))}function mp(e){var t=e.alternate;if(!t){if(t=an(e),t===null)throw Error(s(188));return t!==e?null:e}for(var n=e,i=t;;){var l=n.return;if(l===null)break;var c=l.alternate;if(c===null){if(i=l.return,i!==null){n=i;continue}break}if(l.child===c.child){for(c=l.child;c;){if(c===n)return ul(l),e;if(c===i)return ul(l),t;c=c.sibling}throw Error(s(188))}if(n.return!==i.return)n=l,i=c;else{for(var p=!1,g=l.child;g;){if(g===n){p=!0,n=l,i=c;break}if(g===i){p=!0,i=l,n=c;break}g=g.sibling}if(!p){for(g=c.child;g;){if(g===n){p=!0,n=c,i=l;break}if(g===i){p=!0,i=c,n=l;break}g=g.sibling}if(!p)throw Error(s(189))}}if(n.alternate!==i)throw Error(s(190))}if(n.tag!==3)throw Error(s(188));return n.stateNode.current===n?e:t}function cl(e){return e=mp(e),e!==null?fl(e):null}function fl(e){if(e.tag===5||e.tag===6)return e;for(e=e.child;e!==null;){var t=fl(e);if(t!==null)return t;e=e.sibling}return null}var pl=r.unstable_scheduleCallback,dl=r.unstable_cancelCallback,gp=r.unstable_shouldYield,yp=r.unstable_requestPaint,Oe=r.unstable_now,vp=r.unstable_getCurrentPriorityLevel,Pi=r.unstable_ImmediatePriority,hl=r.unstable_UserBlockingPriority,Jr=r.unstable_NormalPriority,xp=r.unstable_LowPriority,ml=r.unstable_IdlePriority,Gr=null,kt=null;function wp(e){if(kt&&typeof kt.onCommitFiberRoot=="function")try{kt.onCommitFiberRoot(Gr,e,void 0,(e.current.flags&128)===128)}catch{}}var mt=Math.clz32?Math.clz32:kp,Sp=Math.log,Cp=Math.LN2;function kp(e){return e>>>=0,e===0?32:31-(Sp(e)/Cp|0)|0}var es=64,ts=4194304;function ir(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 ns(e,t){var n=e.pendingLanes;if(n===0)return 0;var i=0,l=e.suspendedLanes,c=e.pingedLanes,p=n&268435455;if(p!==0){var g=p&~l;g!==0?i=ir(g):(c&=p,c!==0&&(i=ir(c)))}else p=n&~l,p!==0?i=ir(p):c!==0&&(i=ir(c));if(i===0)return 0;if(t!==0&&t!==i&&(t&l)===0&&(l=i&-i,c=t&-t,l>=c||l===16&&(c&4194240)!==0))return t;if((i&4)!==0&&(i|=n&16),t=e.entangledLanes,t!==0)for(e=e.entanglements,t&=i;0<t;)n=31-mt(t),l=1<<n,i|=e[n],t&=~l;return i}function Fp(e,t){switch(e){case 1:case 2:case 4:return t+250;case 8:case 16:case 32:case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t+5e3;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return-1;case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function Ep(e,t){for(var n=e.suspendedLanes,i=e.pingedLanes,l=e.expirationTimes,c=e.pendingLanes;0<c;){var p=31-mt(c),g=1<<p,x=l[p];x===-1?((g&n)===0||(g&i)!==0)&&(l[p]=Fp(g,t)):x<=t&&(e.expiredLanes|=g),c&=~g}}function ji(e){return e=e.pendingLanes&-1073741825,e!==0?e:e&1073741824?1073741824:0}function gl(){var e=es;return es<<=1,(es&4194240)===0&&(es=64),e}function Ri(e){for(var t=[],n=0;31>n;n++)t.push(e);return t}function or(e,t,n){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-mt(t),e[t]=n}function _p(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 i=e.eventTimes;for(e=e.expirationTimes;0<n;){var l=31-mt(n),c=1<<l;t[l]=0,i[l]=-1,e[l]=-1,n&=~c}}function Ti(e,t){var n=e.entangledLanes|=t;for(e=e.entanglements;n;){var i=31-mt(n),l=1<<i;l&t|e[i]&t&&(e[i]|=t),n&=~l}}var xe=0;function yl(e){return e&=-e,1<e?4<e?(e&268435455)!==0?16:536870912:4:1}var vl,Mi,xl,wl,Sl,Bi=!1,rs=[],Ut=null,It=null,bt=null,ar=new Map,lr=new Map,$t=[],Np="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset submit".split(" ");function Cl(e,t){switch(e){case"focusin":case"focusout":Ut=null;break;case"dragenter":case"dragleave":It=null;break;case"mouseover":case"mouseout":bt=null;break;case"pointerover":case"pointerout":ar.delete(t.pointerId);break;case"gotpointercapture":case"lostpointercapture":lr.delete(t.pointerId)}}function ur(e,t,n,i,l,c){return e===null||e.nativeEvent!==c?(e={blockedOn:t,domEventName:n,eventSystemFlags:i,nativeEvent:c,targetContainers:[l]},t!==null&&(t=kr(t),t!==null&&Mi(t)),e):(e.eventSystemFlags|=i,t=e.targetContainers,l!==null&&t.indexOf(l)===-1&&t.push(l),e)}function zp(e,t,n,i,l){switch(t){case"focusin":return Ut=ur(Ut,e,t,n,i,l),!0;case"dragenter":return It=ur(It,e,t,n,i,l),!0;case"mouseover":return bt=ur(bt,e,t,n,i,l),!0;case"pointerover":var c=l.pointerId;return ar.set(c,ur(ar.get(c)||null,e,t,n,i,l)),!0;case"gotpointercapture":return c=l.pointerId,lr.set(c,ur(lr.get(c)||null,e,t,n,i,l)),!0}return!1}function kl(e){var t=ln(e.target);if(t!==null){var n=an(t);if(n!==null){if(t=n.tag,t===13){if(t=ll(n),t!==null){e.blockedOn=t,Sl(e.priority,function(){xl(n)});return}}else if(t===3&&n.stateNode.current.memoizedState.isDehydrated){e.blockedOn=n.tag===3?n.stateNode.containerInfo:null;return}}}e.blockedOn=null}function ss(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var n=Ii(e.domEventName,e.eventSystemFlags,t[0],e.nativeEvent);if(n===null){n=e.nativeEvent;var i=new n.constructor(n.type,n);Ni=i,n.target.dispatchEvent(i),Ni=null}else return t=kr(n),t!==null&&Mi(t),e.blockedOn=n,!1;t.shift()}return!0}function Fl(e,t,n){ss(e)&&n.delete(t)}function Dp(){Bi=!1,Ut!==null&&ss(Ut)&&(Ut=null),It!==null&&ss(It)&&(It=null),bt!==null&&ss(bt)&&(bt=null),ar.forEach(Fl),lr.forEach(Fl)}function cr(e,t){e.blockedOn===t&&(e.blockedOn=null,Bi||(Bi=!0,r.unstable_scheduleCallback(r.unstable_NormalPriority,Dp)))}function fr(e){function t(l){return cr(l,e)}if(0<rs.length){cr(rs[0],e);for(var n=1;n<rs.length;n++){var i=rs[n];i.blockedOn===e&&(i.blockedOn=null)}}for(Ut!==null&&cr(Ut,e),It!==null&&cr(It,e),bt!==null&&cr(bt,e),ar.forEach(t),lr.forEach(t),n=0;n<$t.length;n++)i=$t[n],i.blockedOn===e&&(i.blockedOn=null);for(;0<$t.length&&(n=$t[0],n.blockedOn===null);)kl(n),n.blockedOn===null&&$t.shift()}var _n=G.ReactCurrentBatchConfig,is=!0;function Lp(e,t,n,i){var l=xe,c=_n.transition;_n.transition=null;try{xe=1,Ui(e,t,n,i)}finally{xe=l,_n.transition=c}}function Op(e,t,n,i){var l=xe,c=_n.transition;_n.transition=null;try{xe=4,Ui(e,t,n,i)}finally{xe=l,_n.transition=c}}function Ui(e,t,n,i){if(is){var l=Ii(e,t,n,i);if(l===null)ro(e,t,i,os,n),Cl(e,i);else if(zp(l,e,t,n,i))i.stopPropagation();else if(Cl(e,i),t&4&&-1<Np.indexOf(e)){for(;l!==null;){var c=kr(l);if(c!==null&&vl(c),c=Ii(e,t,n,i),c===null&&ro(e,t,i,os,n),c===l)break;l=c}l!==null&&i.stopPropagation()}else ro(e,t,i,null,n)}}var os=null;function Ii(e,t,n,i){if(os=null,e=zi(i),e=ln(e),e!==null)if(t=an(e),t===null)e=null;else if(n=t.tag,n===13){if(e=ll(t),e!==null)return e;e=null}else if(n===3){if(t.stateNode.current.memoizedState.isDehydrated)return t.tag===3?t.stateNode.containerInfo:null;e=null}else t!==e&&(e=null);return os=e,null}function El(e){switch(e){case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"resize":case"seeked":case"submit":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 1;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"toggle":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 4;case"message":switch(vp()){case Pi:return 1;case hl:return 4;case Jr:case xp:return 16;case ml:return 536870912;default:return 16}default:return 16}}var Xt=null,bi=null,as=null;function _l(){if(as)return as;var e,t=bi,n=t.length,i,l="value"in Xt?Xt.value:Xt.textContent,c=l.length;for(e=0;e<n&&t[e]===l[e];e++);var p=n-e;for(i=1;i<=p&&t[n-i]===l[c-i];i++);return as=l.slice(e,1<i?1-i:void 0)}function ls(e){var t=e.keyCode;return"charCode"in e?(e=e.charCode,e===0&&t===13&&(e=13)):e=t,e===10&&(e=13),32<=e||e===13?e:0}function us(){return!0}function Nl(){return!1}function st(e){function t(n,i,l,c,p){this._reactName=n,this._targetInst=l,this.type=i,this.nativeEvent=c,this.target=p,this.currentTarget=null;for(var g in e)e.hasOwnProperty(g)&&(n=e[g],this[g]=n?n(c):c[g]);return this.isDefaultPrevented=(c.defaultPrevented!=null?c.defaultPrevented:c.returnValue===!1)?us:Nl,this.isPropagationStopped=Nl,this}return B(t.prototype,{preventDefault:function(){this.defaultPrevented=!0;var n=this.nativeEvent;n&&(n.preventDefault?n.preventDefault():typeof n.returnValue!="unknown"&&(n.returnValue=!1),this.isDefaultPrevented=us)},stopPropagation:function(){var n=this.nativeEvent;n&&(n.stopPropagation?n.stopPropagation():typeof n.cancelBubble!="unknown"&&(n.cancelBubble=!0),this.isPropagationStopped=us)},persist:function(){},isPersistent:us}),t}var Nn={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},$i=st(Nn),pr=B({},Nn,{view:0,detail:0}),Ap=st(pr),Xi,Vi,dr,cs=B({},pr,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:Zi,button:0,buttons:0,relatedTarget:function(e){return e.relatedTarget===void 0?e.fromElement===e.srcElement?e.toElement:e.fromElement:e.relatedTarget},movementX:function(e){return"movementX"in e?e.movementX:(e!==dr&&(dr&&e.type==="mousemove"?(Xi=e.screenX-dr.screenX,Vi=e.screenY-dr.screenY):Vi=Xi=0,dr=e),Xi)},movementY:function(e){return"movementY"in e?e.movementY:Vi}}),zl=st(cs),Pp=B({},cs,{dataTransfer:0}),jp=st(Pp),Rp=B({},pr,{relatedTarget:0}),Hi=st(Rp),Tp=B({},Nn,{animationName:0,elapsedTime:0,pseudoElement:0}),Mp=st(Tp),Bp=B({},Nn,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),Up=st(Bp),Ip=B({},Nn,{data:0}),Dl=st(Ip),bp={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},$p={8:"Backspace",9:"Tab",12:"Clear",13:"Enter",16:"Shift",17:"Control",18:"Alt",19:"Pause",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",45:"Insert",46:"Delete",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"NumLock",145:"ScrollLock",224:"Meta"},Xp={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function Vp(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=Xp[e])?!!t[e]:!1}function Zi(){return Vp}var Hp=B({},pr,{key:function(e){if(e.key){var t=bp[e.key]||e.key;if(t!=="Unidentified")return t}return e.type==="keypress"?(e=ls(e),e===13?"Enter":String.fromCharCode(e)):e.type==="keydown"||e.type==="keyup"?$p[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:Zi,charCode:function(e){return e.type==="keypress"?ls(e):0},keyCode:function(e){return e.type==="keydown"||e.type==="keyup"?e.keyCode:0},which:function(e){return e.type==="keypress"?ls(e):e.type==="keydown"||e.type==="keyup"?e.keyCode:0}}),Zp=st(Hp),Wp=B({},cs,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),Ll=st(Wp),Kp=B({},pr,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:Zi}),qp=st(Kp),Qp=B({},Nn,{propertyName:0,elapsedTime:0,pseudoElement:0}),Yp=st(Qp),Jp=B({},cs,{deltaX:function(e){return"deltaX"in e?e.deltaX:"wheelDeltaX"in e?-e.wheelDeltaX:0},deltaY:function(e){return"deltaY"in e?e.deltaY:"wheelDeltaY"in e?-e.wheelDeltaY:"wheelDelta"in e?-e.wheelDelta:0},deltaZ:0,deltaMode:0}),Gp=st(Jp),ed=[9,13,27,32],Wi=h&&"CompositionEvent"in window,hr=null;h&&"documentMode"in document&&(hr=document.documentMode);var td=h&&"TextEvent"in window&&!hr,Ol=h&&(!Wi||hr&&8<hr&&11>=hr),Al=" ",Pl=!1;function jl(e,t){switch(e){case"keyup":return ed.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function Rl(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var zn=!1;function nd(e,t){switch(e){case"compositionend":return Rl(t);case"keypress":return t.which!==32?null:(Pl=!0,Al);case"textInput":return e=t.data,e===Al&&Pl?null:e;default:return null}}function rd(e,t){if(zn)return e==="compositionend"||!Wi&&jl(e,t)?(e=_l(),as=bi=Xt=null,zn=!1,e):null;switch(e){case"paste":return null;case"keypress":if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1<t.char.length)return t.char;if(t.which)return String.fromCharCode(t.which)}return null;case"compositionend":return Ol&&t.locale!=="ko"?null:t.data;default:return null}}var sd={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};function Tl(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t==="input"?!!sd[e.type]:t==="textarea"}function Ml(e,t,n,i){rl(i),t=ms(t,"onChange"),0<t.length&&(n=new $i("onChange","change",null,n,i),e.push({event:n,listeners:t}))}var mr=null,gr=null;function id(e){tu(e,0)}function fs(e){var t=Pn(e);if(Ha(t))return e}function od(e,t){if(e==="change")return t}var Bl=!1;if(h){var Ki;if(h){var qi="oninput"in document;if(!qi){var Ul=document.createElement("div");Ul.setAttribute("oninput","return;"),qi=typeof Ul.oninput=="function"}Ki=qi}else Ki=!1;Bl=Ki&&(!document.documentMode||9<document.documentMode)}function Il(){mr&&(mr.detachEvent("onpropertychange",bl),gr=mr=null)}function bl(e){if(e.propertyName==="value"&&fs(gr)){var t=[];Ml(t,gr,e,zi(e)),al(id,t)}}function ad(e,t,n){e==="focusin"?(Il(),mr=t,gr=n,mr.attachEvent("onpropertychange",bl)):e==="focusout"&&Il()}function ld(e){if(e==="selectionchange"||e==="keyup"||e==="keydown")return fs(gr)}function ud(e,t){if(e==="click")return fs(t)}function cd(e,t){if(e==="input"||e==="change")return fs(t)}function fd(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var gt=typeof Object.is=="function"?Object.is:fd;function yr(e,t){if(gt(e,t))return!0;if(typeof e!="object"||e===null||typeof t!="object"||t===null)return!1;var n=Object.keys(e),i=Object.keys(t);if(n.length!==i.length)return!1;for(i=0;i<n.length;i++){var l=n[i];if(!m.call(t,l)||!gt(e[l],t[l]))return!1}return!0}function $l(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function Xl(e,t){var n=$l(e);e=0;for(var i;n;){if(n.nodeType===3){if(i=e+n.textContent.length,e<=t&&i>=t)return{node:n,offset:t-e};e=i}e:{for(;n;){if(n.nextSibling){n=n.nextSibling;break e}n=n.parentNode}n=void 0}n=$l(n)}}function Vl(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?Vl(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function Hl(){for(var e=window,t=Kr();t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href=="string"}catch{n=!1}if(n)e=t.contentWindow;else break;t=Kr(e.document)}return t}function Qi(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 pd(e){var t=Hl(),n=e.focusedElem,i=e.selectionRange;if(t!==n&&n&&n.ownerDocument&&Vl(n.ownerDocument.documentElement,n)){if(i!==null&&Qi(n)){if(t=i.start,e=i.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,c=Math.min(i.start,l);i=i.end===void 0?c:Math.min(i.end,l),!e.extend&&c>i&&(l=i,i=c,c=l),l=Xl(n,c);var p=Xl(n,i);l&&p&&(e.rangeCount!==1||e.anchorNode!==l.node||e.anchorOffset!==l.offset||e.focusNode!==p.node||e.focusOffset!==p.offset)&&(t=t.createRange(),t.setStart(l.node,l.offset),e.removeAllRanges(),c>i?(e.addRange(t),e.extend(p.node,p.offset)):(t.setEnd(p.node,p.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<t.length;n++)e=t[n],e.element.scrollLeft=e.left,e.element.scrollTop=e.top}}var dd=h&&"documentMode"in document&&11>=document.documentMode,Dn=null,Yi=null,vr=null,Ji=!1;function Zl(e,t,n){var i=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;Ji||Dn==null||Dn!==Kr(i)||(i=Dn,"selectionStart"in i&&Qi(i)?i={start:i.selectionStart,end:i.selectionEnd}:(i=(i.ownerDocument&&i.ownerDocument.defaultView||window).getSelection(),i={anchorNode:i.anchorNode,anchorOffset:i.anchorOffset,focusNode:i.focusNode,focusOffset:i.focusOffset}),vr&&yr(vr,i)||(vr=i,i=ms(Yi,"onSelect"),0<i.length&&(t=new $i("onSelect","select",null,t,n),e.push({event:t,listeners:i}),t.target=Dn)))}function ps(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n["Webkit"+e]="webkit"+t,n["Moz"+e]="moz"+t,n}var Ln={animationend:ps("Animation","AnimationEnd"),animationiteration:ps("Animation","AnimationIteration"),animationstart:ps("Animation","AnimationStart"),transitionend:ps("Transition","TransitionEnd")},Gi={},Wl={};h&&(Wl=document.createElement("div").style,"AnimationEvent"in window||(delete Ln.animationend.animation,delete Ln.animationiteration.animation,delete Ln.animationstart.animation),"TransitionEvent"in window||delete Ln.transitionend.transition);function ds(e){if(Gi[e])return Gi[e];if(!Ln[e])return e;var t=Ln[e],n;for(n in t)if(t.hasOwnProperty(n)&&n in Wl)return Gi[e]=t[n];return e}var Kl=ds("animationend"),ql=ds("animationiteration"),Ql=ds("animationstart"),Yl=ds("transitionend"),Jl=new Map,Gl="abort auxClick cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel".split(" ");function Vt(e,t){Jl.set(e,t),f(t,[e])}for(var eo=0;eo<Gl.length;eo++){var to=Gl[eo],hd=to.toLowerCase(),md=to[0].toUpperCase()+to.slice(1);Vt(hd,"on"+md)}Vt(Kl,"onAnimationEnd"),Vt(ql,"onAnimationIteration"),Vt(Ql,"onAnimationStart"),Vt("dblclick","onDoubleClick"),Vt("focusin","onFocus"),Vt("focusout","onBlur"),Vt(Yl,"onTransitionEnd"),d("onMouseEnter",["mouseout","mouseover"]),d("onMouseLeave",["mouseout","mouseover"]),d("onPointerEnter",["pointerout","pointerover"]),d("onPointerLeave",["pointerout","pointerover"]),f("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),f("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),f("onBeforeInput",["compositionend","keypress","textInput","paste"]),f("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),f("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),f("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var xr="abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange resize seeked seeking stalled suspend timeupdate volumechange waiting".split(" "),gd=new Set("cancel close invalid load scroll toggle".split(" ").concat(xr));function eu(e,t,n){var i=e.type||"unknown-event";e.currentTarget=n,hp(i,t,void 0,e),e.currentTarget=null}function tu(e,t){t=(t&4)!==0;for(var n=0;n<e.length;n++){var i=e[n],l=i.event;i=i.listeners;e:{var c=void 0;if(t)for(var p=i.length-1;0<=p;p--){var g=i[p],x=g.instance,N=g.currentTarget;if(g=g.listener,x!==c&&l.isPropagationStopped())break e;eu(l,g,N),c=x}else for(p=0;p<i.length;p++){if(g=i[p],x=g.instance,N=g.currentTarget,g=g.listener,x!==c&&l.isPropagationStopped())break e;eu(l,g,N),c=x}}}if(Yr)throw e=Ai,Yr=!1,Ai=null,e}function ke(e,t){var n=t[uo];n===void 0&&(n=t[uo]=new Set);var i=e+"__bubble";n.has(i)||(nu(t,e,2,!1),n.add(i))}function no(e,t,n){var i=0;t&&(i|=4),nu(n,e,i,t)}var hs="_reactListening"+Math.random().toString(36).slice(2);function wr(e){if(!e[hs]){e[hs]=!0,o.forEach(function(n){n!=="selectionchange"&&(gd.has(n)||no(n,!1,e),no(n,!0,e))});var t=e.nodeType===9?e:e.ownerDocument;t===null||t[hs]||(t[hs]=!0,no("selectionchange",!1,t))}}function nu(e,t,n,i){switch(El(t)){case 1:var l=Lp;break;case 4:l=Op;break;default:l=Ui}n=l.bind(null,t,n,e),l=void 0,!Oi||t!=="touchstart"&&t!=="touchmove"&&t!=="wheel"||(l=!0),i?l!==void 0?e.addEventListener(t,n,{capture:!0,passive:l}):e.addEventListener(t,n,!0):l!==void 0?e.addEventListener(t,n,{passive:l}):e.addEventListener(t,n,!1)}function ro(e,t,n,i,l){var c=i;if((t&1)===0&&(t&2)===0&&i!==null)e:for(;;){if(i===null)return;var p=i.tag;if(p===3||p===4){var g=i.stateNode.containerInfo;if(g===l||g.nodeType===8&&g.parentNode===l)break;if(p===4)for(p=i.return;p!==null;){var x=p.tag;if((x===3||x===4)&&(x=p.stateNode.containerInfo,x===l||x.nodeType===8&&x.parentNode===l))return;p=p.return}for(;g!==null;){if(p=ln(g),p===null)return;if(x=p.tag,x===5||x===6){i=c=p;continue e}g=g.parentNode}}i=i.return}al(function(){var N=c,A=zi(n),P=[];e:{var O=Jl.get(e);if(O!==void 0){var U=$i,b=e;switch(e){case"keypress":if(ls(n)===0)break e;case"keydown":case"keyup":U=Zp;break;case"focusin":b="focus",U=Hi;break;case"focusout":b="blur",U=Hi;break;case"beforeblur":case"afterblur":U=Hi;break;case"click":if(n.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":U=zl;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":U=jp;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":U=qp;break;case Kl:case ql:case Ql:U=Mp;break;case Yl:U=Yp;break;case"scroll":U=Ap;break;case"wheel":U=Gp;break;case"copy":case"cut":case"paste":U=Up;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":U=Ll}var X=(t&4)!==0,Ae=!X&&e==="scroll",k=X?O!==null?O+"Capture":null:O;X=[];for(var w=N,_;w!==null;){_=w;var j=_.stateNode;if(_.tag===5&&j!==null&&(_=j,k!==null&&(j=nr(w,k),j!=null&&X.push(Sr(w,j,_)))),Ae)break;w=w.return}0<X.length&&(O=new U(O,b,null,n,A),P.push({event:O,listeners:X}))}}if((t&7)===0){e:{if(O=e==="mouseover"||e==="pointerover",U=e==="mouseout"||e==="pointerout",O&&n!==Ni&&(b=n.relatedTarget||n.fromElement)&&(ln(b)||b[Ot]))break e;if((U||O)&&(O=A.window===A?A:(O=A.ownerDocument)?O.defaultView||O.parentWindow:window,U?(b=n.relatedTarget||n.toElement,U=N,b=b?ln(b):null,b!==null&&(Ae=an(b),b!==Ae||b.tag!==5&&b.tag!==6)&&(b=null)):(U=null,b=N),U!==b)){if(X=zl,j="onMouseLeave",k="onMouseEnter",w="mouse",(e==="pointerout"||e==="pointerover")&&(X=Ll,j="onPointerLeave",k="onPointerEnter",w="pointer"),Ae=U==null?O:Pn(U),_=b==null?O:Pn(b),O=new X(j,w+"leave",U,n,A),O.target=Ae,O.relatedTarget=_,j=null,ln(A)===N&&(X=new X(k,w+"enter",b,n,A),X.target=_,X.relatedTarget=Ae,j=X),Ae=j,U&&b)t:{for(X=U,k=b,w=0,_=X;_;_=On(_))w++;for(_=0,j=k;j;j=On(j))_++;for(;0<w-_;)X=On(X),w--;for(;0<_-w;)k=On(k),_--;for(;w--;){if(X===k||k!==null&&X===k.alternate)break t;X=On(X),k=On(k)}X=null}else X=null;U!==null&&ru(P,O,U,X,!1),b!==null&&Ae!==null&&ru(P,Ae,b,X,!0)}}e:{if(O=N?Pn(N):window,U=O.nodeName&&O.nodeName.toLowerCase(),U==="select"||U==="input"&&O.type==="file")var H=od;else if(Tl(O))if(Bl)H=cd;else{H=ld;var K=ad}else(U=O.nodeName)&&U.toLowerCase()==="input"&&(O.type==="checkbox"||O.type==="radio")&&(H=ud);if(H&&(H=H(e,N))){Ml(P,H,n,A);break e}K&&K(e,O,N),e==="focusout"&&(K=O._wrapperState)&&K.controlled&&O.type==="number"&&Ci(O,"number",O.value)}switch(K=N?Pn(N):window,e){case"focusin":(Tl(K)||K.contentEditable==="true")&&(Dn=K,Yi=N,vr=null);break;case"focusout":vr=Yi=Dn=null;break;case"mousedown":Ji=!0;break;case"contextmenu":case"mouseup":case"dragend":Ji=!1,Zl(P,n,A);break;case"selectionchange":if(dd)break;case"keydown":case"keyup":Zl(P,n,A)}var q;if(Wi)e:{switch(e){case"compositionstart":var J="onCompositionStart";break e;case"compositionend":J="onCompositionEnd";break e;case"compositionupdate":J="onCompositionUpdate";break e}J=void 0}else zn?jl(e,n)&&(J="onCompositionEnd"):e==="keydown"&&n.keyCode===229&&(J="onCompositionStart");J&&(Ol&&n.locale!=="ko"&&(zn||J!=="onCompositionStart"?J==="onCompositionEnd"&&zn&&(q=_l()):(Xt=A,bi="value"in Xt?Xt.value:Xt.textContent,zn=!0)),K=ms(N,J),0<K.length&&(J=new Dl(J,e,null,n,A),P.push({event:J,listeners:K}),q?J.data=q:(q=Rl(n),q!==null&&(J.data=q)))),(q=td?nd(e,n):rd(e,n))&&(N=ms(N,"onBeforeInput"),0<N.length&&(A=new Dl("onBeforeInput","beforeinput",null,n,A),P.push({event:A,listeners:N}),A.data=q))}tu(P,t)})}function Sr(e,t,n){return{instance:e,listener:t,currentTarget:n}}function ms(e,t){for(var n=t+"Capture",i=[];e!==null;){var l=e,c=l.stateNode;l.tag===5&&c!==null&&(l=c,c=nr(e,n),c!=null&&i.unshift(Sr(e,c,l)),c=nr(e,t),c!=null&&i.push(Sr(e,c,l))),e=e.return}return i}function On(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5);return e||null}function ru(e,t,n,i,l){for(var c=t._reactName,p=[];n!==null&&n!==i;){var g=n,x=g.alternate,N=g.stateNode;if(x!==null&&x===i)break;g.tag===5&&N!==null&&(g=N,l?(x=nr(n,c),x!=null&&p.unshift(Sr(n,x,g))):l||(x=nr(n,c),x!=null&&p.push(Sr(n,x,g)))),n=n.return}p.length!==0&&e.push({event:t,listeners:p})}var yd=/\r\n?/g,vd=/\u0000|\uFFFD/g;function su(e){return(typeof e=="string"?e:""+e).replace(yd,`
|
|
38
|
+
`).replace(vd,"")}function gs(e,t,n){if(t=su(t),su(e)!==t&&n)throw Error(s(425))}function ys(){}var so=null,io=null;function oo(e,t){return e==="textarea"||e==="noscript"||typeof t.children=="string"||typeof t.children=="number"||typeof t.dangerouslySetInnerHTML=="object"&&t.dangerouslySetInnerHTML!==null&&t.dangerouslySetInnerHTML.__html!=null}var ao=typeof setTimeout=="function"?setTimeout:void 0,xd=typeof clearTimeout=="function"?clearTimeout:void 0,iu=typeof Promise=="function"?Promise:void 0,wd=typeof queueMicrotask=="function"?queueMicrotask:typeof iu<"u"?function(e){return iu.resolve(null).then(e).catch(Sd)}:ao;function Sd(e){setTimeout(function(){throw e})}function lo(e,t){var n=t,i=0;do{var l=n.nextSibling;if(e.removeChild(n),l&&l.nodeType===8)if(n=l.data,n==="/$"){if(i===0){e.removeChild(l),fr(t);return}i--}else n!=="$"&&n!=="$?"&&n!=="$!"||i++;n=l}while(n);fr(t)}function Ht(e){for(;e!=null;e=e.nextSibling){var t=e.nodeType;if(t===1||t===3)break;if(t===8){if(t=e.data,t==="$"||t==="$!"||t==="$?")break;if(t==="/$")return null}}return e}function ou(e){e=e.previousSibling;for(var t=0;e;){if(e.nodeType===8){var n=e.data;if(n==="$"||n==="$!"||n==="$?"){if(t===0)return e;t--}else n==="/$"&&t++}e=e.previousSibling}return null}var An=Math.random().toString(36).slice(2),Ft="__reactFiber$"+An,Cr="__reactProps$"+An,Ot="__reactContainer$"+An,uo="__reactEvents$"+An,Cd="__reactListeners$"+An,kd="__reactHandles$"+An;function ln(e){var t=e[Ft];if(t)return t;for(var n=e.parentNode;n;){if(t=n[Ot]||n[Ft]){if(n=t.alternate,t.child!==null||n!==null&&n.child!==null)for(e=ou(e);e!==null;){if(n=e[Ft])return n;e=ou(e)}return t}e=n,n=e.parentNode}return null}function kr(e){return e=e[Ft]||e[Ot],!e||e.tag!==5&&e.tag!==6&&e.tag!==13&&e.tag!==3?null:e}function Pn(e){if(e.tag===5||e.tag===6)return e.stateNode;throw Error(s(33))}function vs(e){return e[Cr]||null}var co=[],jn=-1;function Zt(e){return{current:e}}function Fe(e){0>jn||(e.current=co[jn],co[jn]=null,jn--)}function Ce(e,t){jn++,co[jn]=e.current,e.current=t}var Wt={},Xe=Zt(Wt),Ye=Zt(!1),un=Wt;function Rn(e,t){var n=e.type.contextTypes;if(!n)return Wt;var i=e.stateNode;if(i&&i.__reactInternalMemoizedUnmaskedChildContext===t)return i.__reactInternalMemoizedMaskedChildContext;var l={},c;for(c in n)l[c]=t[c];return i&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=l),l}function Je(e){return e=e.childContextTypes,e!=null}function xs(){Fe(Ye),Fe(Xe)}function au(e,t,n){if(Xe.current!==Wt)throw Error(s(168));Ce(Xe,t),Ce(Ye,n)}function lu(e,t,n){var i=e.stateNode;if(t=t.childContextTypes,typeof i.getChildContext!="function")return n;i=i.getChildContext();for(var l in i)if(!(l in t))throw Error(s(108,ve(e)||"Unknown",l));return B({},n,i)}function ws(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||Wt,un=Xe.current,Ce(Xe,e),Ce(Ye,Ye.current),!0}function uu(e,t,n){var i=e.stateNode;if(!i)throw Error(s(169));n?(e=lu(e,t,un),i.__reactInternalMemoizedMergedChildContext=e,Fe(Ye),Fe(Xe),Ce(Xe,e)):Fe(Ye),Ce(Ye,n)}var At=null,Ss=!1,fo=!1;function cu(e){At===null?At=[e]:At.push(e)}function Fd(e){Ss=!0,cu(e)}function Kt(){if(!fo&&At!==null){fo=!0;var e=0,t=xe;try{var n=At;for(xe=1;e<n.length;e++){var i=n[e];do i=i(!0);while(i!==null)}At=null,Ss=!1}catch(l){throw At!==null&&(At=At.slice(e+1)),pl(Pi,Kt),l}finally{xe=t,fo=!1}}return null}var Tn=[],Mn=0,Cs=null,ks=0,lt=[],ut=0,cn=null,Pt=1,jt="";function fn(e,t){Tn[Mn++]=ks,Tn[Mn++]=Cs,Cs=e,ks=t}function fu(e,t,n){lt[ut++]=Pt,lt[ut++]=jt,lt[ut++]=cn,cn=e;var i=Pt;e=jt;var l=32-mt(i)-1;i&=~(1<<l),n+=1;var c=32-mt(t)+l;if(30<c){var p=l-l%5;c=(i&(1<<p)-1).toString(32),i>>=p,l-=p,Pt=1<<32-mt(t)+l|n<<l|i,jt=c+e}else Pt=1<<c|n<<l|i,jt=e}function po(e){e.return!==null&&(fn(e,1),fu(e,1,0))}function ho(e){for(;e===Cs;)Cs=Tn[--Mn],Tn[Mn]=null,ks=Tn[--Mn],Tn[Mn]=null;for(;e===cn;)cn=lt[--ut],lt[ut]=null,jt=lt[--ut],lt[ut]=null,Pt=lt[--ut],lt[ut]=null}var it=null,ot=null,_e=!1,yt=null;function pu(e,t){var n=dt(5,null,null,0);n.elementType="DELETED",n.stateNode=t,n.return=e,t=e.deletions,t===null?(e.deletions=[n],e.flags|=16):t.push(n)}function du(e,t){switch(e.tag){case 5:var n=e.type;return t=t.nodeType!==1||n.toLowerCase()!==t.nodeName.toLowerCase()?null:t,t!==null?(e.stateNode=t,it=e,ot=Ht(t.firstChild),!0):!1;case 6:return t=e.pendingProps===""||t.nodeType!==3?null:t,t!==null?(e.stateNode=t,it=e,ot=null,!0):!1;case 13:return t=t.nodeType!==8?null:t,t!==null?(n=cn!==null?{id:Pt,overflow:jt}:null,e.memoizedState={dehydrated:t,treeContext:n,retryLane:1073741824},n=dt(18,null,null,0),n.stateNode=t,n.return=e,e.child=n,it=e,ot=null,!0):!1;default:return!1}}function mo(e){return(e.mode&1)!==0&&(e.flags&128)===0}function go(e){if(_e){var t=ot;if(t){var n=t;if(!du(e,t)){if(mo(e))throw Error(s(418));t=Ht(n.nextSibling);var i=it;t&&du(e,t)?pu(i,n):(e.flags=e.flags&-4097|2,_e=!1,it=e)}}else{if(mo(e))throw Error(s(418));e.flags=e.flags&-4097|2,_e=!1,it=e}}}function hu(e){for(e=e.return;e!==null&&e.tag!==5&&e.tag!==3&&e.tag!==13;)e=e.return;it=e}function Fs(e){if(e!==it)return!1;if(!_e)return hu(e),_e=!0,!1;var t;if((t=e.tag!==3)&&!(t=e.tag!==5)&&(t=e.type,t=t!=="head"&&t!=="body"&&!oo(e.type,e.memoizedProps)),t&&(t=ot)){if(mo(e))throw mu(),Error(s(418));for(;t;)pu(e,t),t=Ht(t.nextSibling)}if(hu(e),e.tag===13){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(s(317));e:{for(e=e.nextSibling,t=0;e;){if(e.nodeType===8){var n=e.data;if(n==="/$"){if(t===0){ot=Ht(e.nextSibling);break e}t--}else n!=="$"&&n!=="$!"&&n!=="$?"||t++}e=e.nextSibling}ot=null}}else ot=it?Ht(e.stateNode.nextSibling):null;return!0}function mu(){for(var e=ot;e;)e=Ht(e.nextSibling)}function Bn(){ot=it=null,_e=!1}function yo(e){yt===null?yt=[e]:yt.push(e)}var Ed=G.ReactCurrentBatchConfig;function Fr(e,t,n){if(e=n.ref,e!==null&&typeof e!="function"&&typeof e!="object"){if(n._owner){if(n=n._owner,n){if(n.tag!==1)throw Error(s(309));var i=n.stateNode}if(!i)throw Error(s(147,e));var l=i,c=""+e;return t!==null&&t.ref!==null&&typeof t.ref=="function"&&t.ref._stringRef===c?t.ref:(t=function(p){var g=l.refs;p===null?delete g[c]:g[c]=p},t._stringRef=c,t)}if(typeof e!="string")throw Error(s(284));if(!n._owner)throw Error(s(290,e))}return e}function Es(e,t){throw e=Object.prototype.toString.call(t),Error(s(31,e==="[object Object]"?"object with keys {"+Object.keys(t).join(", ")+"}":e))}function gu(e){var t=e._init;return t(e._payload)}function yu(e){function t(k,w){if(e){var _=k.deletions;_===null?(k.deletions=[w],k.flags|=16):_.push(w)}}function n(k,w){if(!e)return null;for(;w!==null;)t(k,w),w=w.sibling;return null}function i(k,w){for(k=new Map;w!==null;)w.key!==null?k.set(w.key,w):k.set(w.index,w),w=w.sibling;return k}function l(k,w){return k=nn(k,w),k.index=0,k.sibling=null,k}function c(k,w,_){return k.index=_,e?(_=k.alternate,_!==null?(_=_.index,_<w?(k.flags|=2,w):_):(k.flags|=2,w)):(k.flags|=1048576,w)}function p(k){return e&&k.alternate===null&&(k.flags|=2),k}function g(k,w,_,j){return w===null||w.tag!==6?(w=la(_,k.mode,j),w.return=k,w):(w=l(w,_),w.return=k,w)}function x(k,w,_,j){var H=_.type;return H===le?A(k,w,_.props.children,j,_.key):w!==null&&(w.elementType===H||typeof H=="object"&&H!==null&&H.$$typeof===de&&gu(H)===w.type)?(j=l(w,_.props),j.ref=Fr(k,w,_),j.return=k,j):(j=qs(_.type,_.key,_.props,null,k.mode,j),j.ref=Fr(k,w,_),j.return=k,j)}function N(k,w,_,j){return w===null||w.tag!==4||w.stateNode.containerInfo!==_.containerInfo||w.stateNode.implementation!==_.implementation?(w=ua(_,k.mode,j),w.return=k,w):(w=l(w,_.children||[]),w.return=k,w)}function A(k,w,_,j,H){return w===null||w.tag!==7?(w=xn(_,k.mode,j,H),w.return=k,w):(w=l(w,_),w.return=k,w)}function P(k,w,_){if(typeof w=="string"&&w!==""||typeof w=="number")return w=la(""+w,k.mode,_),w.return=k,w;if(typeof w=="object"&&w!==null){switch(w.$$typeof){case ae:return _=qs(w.type,w.key,w.props,null,k.mode,_),_.ref=Fr(k,null,w),_.return=k,_;case Se:return w=ua(w,k.mode,_),w.return=k,w;case de:var j=w._init;return P(k,j(w._payload),_)}if(Gn(w)||Z(w))return w=xn(w,k.mode,_,null),w.return=k,w;Es(k,w)}return null}function O(k,w,_,j){var H=w!==null?w.key:null;if(typeof _=="string"&&_!==""||typeof _=="number")return H!==null?null:g(k,w,""+_,j);if(typeof _=="object"&&_!==null){switch(_.$$typeof){case ae:return _.key===H?x(k,w,_,j):null;case Se:return _.key===H?N(k,w,_,j):null;case de:return H=_._init,O(k,w,H(_._payload),j)}if(Gn(_)||Z(_))return H!==null?null:A(k,w,_,j,null);Es(k,_)}return null}function U(k,w,_,j,H){if(typeof j=="string"&&j!==""||typeof j=="number")return k=k.get(_)||null,g(w,k,""+j,H);if(typeof j=="object"&&j!==null){switch(j.$$typeof){case ae:return k=k.get(j.key===null?_:j.key)||null,x(w,k,j,H);case Se:return k=k.get(j.key===null?_:j.key)||null,N(w,k,j,H);case de:var K=j._init;return U(k,w,_,K(j._payload),H)}if(Gn(j)||Z(j))return k=k.get(_)||null,A(w,k,j,H,null);Es(w,j)}return null}function b(k,w,_,j){for(var H=null,K=null,q=w,J=w=0,Ue=null;q!==null&&J<_.length;J++){q.index>J?(Ue=q,q=null):Ue=q.sibling;var he=O(k,q,_[J],j);if(he===null){q===null&&(q=Ue);break}e&&q&&he.alternate===null&&t(k,q),w=c(he,w,J),K===null?H=he:K.sibling=he,K=he,q=Ue}if(J===_.length)return n(k,q),_e&&fn(k,J),H;if(q===null){for(;J<_.length;J++)q=P(k,_[J],j),q!==null&&(w=c(q,w,J),K===null?H=q:K.sibling=q,K=q);return _e&&fn(k,J),H}for(q=i(k,q);J<_.length;J++)Ue=U(q,k,J,_[J],j),Ue!==null&&(e&&Ue.alternate!==null&&q.delete(Ue.key===null?J:Ue.key),w=c(Ue,w,J),K===null?H=Ue:K.sibling=Ue,K=Ue);return e&&q.forEach(function(rn){return t(k,rn)}),_e&&fn(k,J),H}function X(k,w,_,j){var H=Z(_);if(typeof H!="function")throw Error(s(150));if(_=H.call(_),_==null)throw Error(s(151));for(var K=H=null,q=w,J=w=0,Ue=null,he=_.next();q!==null&&!he.done;J++,he=_.next()){q.index>J?(Ue=q,q=null):Ue=q.sibling;var rn=O(k,q,he.value,j);if(rn===null){q===null&&(q=Ue);break}e&&q&&rn.alternate===null&&t(k,q),w=c(rn,w,J),K===null?H=rn:K.sibling=rn,K=rn,q=Ue}if(he.done)return n(k,q),_e&&fn(k,J),H;if(q===null){for(;!he.done;J++,he=_.next())he=P(k,he.value,j),he!==null&&(w=c(he,w,J),K===null?H=he:K.sibling=he,K=he);return _e&&fn(k,J),H}for(q=i(k,q);!he.done;J++,he=_.next())he=U(q,k,J,he.value,j),he!==null&&(e&&he.alternate!==null&&q.delete(he.key===null?J:he.key),w=c(he,w,J),K===null?H=he:K.sibling=he,K=he);return e&&q.forEach(function(sh){return t(k,sh)}),_e&&fn(k,J),H}function Ae(k,w,_,j){if(typeof _=="object"&&_!==null&&_.type===le&&_.key===null&&(_=_.props.children),typeof _=="object"&&_!==null){switch(_.$$typeof){case ae:e:{for(var H=_.key,K=w;K!==null;){if(K.key===H){if(H=_.type,H===le){if(K.tag===7){n(k,K.sibling),w=l(K,_.props.children),w.return=k,k=w;break e}}else if(K.elementType===H||typeof H=="object"&&H!==null&&H.$$typeof===de&&gu(H)===K.type){n(k,K.sibling),w=l(K,_.props),w.ref=Fr(k,K,_),w.return=k,k=w;break e}n(k,K);break}else t(k,K);K=K.sibling}_.type===le?(w=xn(_.props.children,k.mode,j,_.key),w.return=k,k=w):(j=qs(_.type,_.key,_.props,null,k.mode,j),j.ref=Fr(k,w,_),j.return=k,k=j)}return p(k);case Se:e:{for(K=_.key;w!==null;){if(w.key===K)if(w.tag===4&&w.stateNode.containerInfo===_.containerInfo&&w.stateNode.implementation===_.implementation){n(k,w.sibling),w=l(w,_.children||[]),w.return=k,k=w;break e}else{n(k,w);break}else t(k,w);w=w.sibling}w=ua(_,k.mode,j),w.return=k,k=w}return p(k);case de:return K=_._init,Ae(k,w,K(_._payload),j)}if(Gn(_))return b(k,w,_,j);if(Z(_))return X(k,w,_,j);Es(k,_)}return typeof _=="string"&&_!==""||typeof _=="number"?(_=""+_,w!==null&&w.tag===6?(n(k,w.sibling),w=l(w,_),w.return=k,k=w):(n(k,w),w=la(_,k.mode,j),w.return=k,k=w),p(k)):n(k,w)}return Ae}var Un=yu(!0),vu=yu(!1),_s=Zt(null),Ns=null,In=null,vo=null;function xo(){vo=In=Ns=null}function wo(e){var t=_s.current;Fe(_s),e._currentValue=t}function So(e,t,n){for(;e!==null;){var i=e.alternate;if((e.childLanes&t)!==t?(e.childLanes|=t,i!==null&&(i.childLanes|=t)):i!==null&&(i.childLanes&t)!==t&&(i.childLanes|=t),e===n)break;e=e.return}}function bn(e,t){Ns=e,vo=In=null,e=e.dependencies,e!==null&&e.firstContext!==null&&((e.lanes&t)!==0&&(Ge=!0),e.firstContext=null)}function ct(e){var t=e._currentValue;if(vo!==e)if(e={context:e,memoizedValue:t,next:null},In===null){if(Ns===null)throw Error(s(308));In=e,Ns.dependencies={lanes:0,firstContext:e}}else In=In.next=e;return t}var pn=null;function Co(e){pn===null?pn=[e]:pn.push(e)}function xu(e,t,n,i){var l=t.interleaved;return l===null?(n.next=n,Co(t)):(n.next=l.next,l.next=n),t.interleaved=n,Rt(e,i)}function Rt(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 qt=!1;function ko(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function wu(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 Tt(e,t){return{eventTime:e,lane:t,tag:0,payload:null,callback:null,next:null}}function Qt(e,t,n){var i=e.updateQueue;if(i===null)return null;if(i=i.shared,(fe&2)!==0){var l=i.pending;return l===null?t.next=t:(t.next=l.next,l.next=t),i.pending=t,Rt(e,n)}return l=i.interleaved,l===null?(t.next=t,Co(i)):(t.next=l.next,l.next=t),i.interleaved=t,Rt(e,n)}function zs(e,t,n){if(t=t.updateQueue,t!==null&&(t=t.shared,(n&4194240)!==0)){var i=t.lanes;i&=e.pendingLanes,n|=i,t.lanes=n,Ti(e,n)}}function Su(e,t){var n=e.updateQueue,i=e.alternate;if(i!==null&&(i=i.updateQueue,n===i)){var l=null,c=null;if(n=n.firstBaseUpdate,n!==null){do{var p={eventTime:n.eventTime,lane:n.lane,tag:n.tag,payload:n.payload,callback:n.callback,next:null};c===null?l=c=p:c=c.next=p,n=n.next}while(n!==null);c===null?l=c=t:c=c.next=t}else l=c=t;n={baseState:i.baseState,firstBaseUpdate:l,lastBaseUpdate:c,shared:i.shared,effects:i.effects},e.updateQueue=n;return}e=n.lastBaseUpdate,e===null?n.firstBaseUpdate=t:e.next=t,n.lastBaseUpdate=t}function Ds(e,t,n,i){var l=e.updateQueue;qt=!1;var c=l.firstBaseUpdate,p=l.lastBaseUpdate,g=l.shared.pending;if(g!==null){l.shared.pending=null;var x=g,N=x.next;x.next=null,p===null?c=N:p.next=N,p=x;var A=e.alternate;A!==null&&(A=A.updateQueue,g=A.lastBaseUpdate,g!==p&&(g===null?A.firstBaseUpdate=N:g.next=N,A.lastBaseUpdate=x))}if(c!==null){var P=l.baseState;p=0,A=N=x=null,g=c;do{var O=g.lane,U=g.eventTime;if((i&O)===O){A!==null&&(A=A.next={eventTime:U,lane:0,tag:g.tag,payload:g.payload,callback:g.callback,next:null});e:{var b=e,X=g;switch(O=t,U=n,X.tag){case 1:if(b=X.payload,typeof b=="function"){P=b.call(U,P,O);break e}P=b;break e;case 3:b.flags=b.flags&-65537|128;case 0:if(b=X.payload,O=typeof b=="function"?b.call(U,P,O):b,O==null)break e;P=B({},P,O);break e;case 2:qt=!0}}g.callback!==null&&g.lane!==0&&(e.flags|=64,O=l.effects,O===null?l.effects=[g]:O.push(g))}else U={eventTime:U,lane:O,tag:g.tag,payload:g.payload,callback:g.callback,next:null},A===null?(N=A=U,x=P):A=A.next=U,p|=O;if(g=g.next,g===null){if(g=l.shared.pending,g===null)break;O=g,g=O.next,O.next=null,l.lastBaseUpdate=O,l.shared.pending=null}}while(!0);if(A===null&&(x=P),l.baseState=x,l.firstBaseUpdate=N,l.lastBaseUpdate=A,t=l.shared.interleaved,t!==null){l=t;do p|=l.lane,l=l.next;while(l!==t)}else c===null&&(l.shared.lanes=0);mn|=p,e.lanes=p,e.memoizedState=P}}function Cu(e,t,n){if(e=t.effects,t.effects=null,e!==null)for(t=0;t<e.length;t++){var i=e[t],l=i.callback;if(l!==null){if(i.callback=null,i=n,typeof l!="function")throw Error(s(191,l));l.call(i)}}}var Er={},Et=Zt(Er),_r=Zt(Er),Nr=Zt(Er);function dn(e){if(e===Er)throw Error(s(174));return e}function Fo(e,t){switch(Ce(Nr,t),Ce(_r,e),Ce(Et,Er),e=t.nodeType,e){case 9:case 11:t=(t=t.documentElement)?t.namespaceURI:Fi(null,"");break;default:e=e===8?t.parentNode:t,t=e.namespaceURI||null,e=e.tagName,t=Fi(t,e)}Fe(Et),Ce(Et,t)}function $n(){Fe(Et),Fe(_r),Fe(Nr)}function ku(e){dn(Nr.current);var t=dn(Et.current),n=Fi(t,e.type);t!==n&&(Ce(_r,e),Ce(Et,n))}function Eo(e){_r.current===e&&(Fe(Et),Fe(_r))}var ze=Zt(0);function Ls(e){for(var t=e;t!==null;){if(t.tag===13){var n=t.memoizedState;if(n!==null&&(n=n.dehydrated,n===null||n.data==="$?"||n.data==="$!"))return t}else if(t.tag===19&&t.memoizedProps.revealOrder!==void 0){if((t.flags&128)!==0)return t}else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}var _o=[];function No(){for(var e=0;e<_o.length;e++)_o[e]._workInProgressVersionPrimary=null;_o.length=0}var Os=G.ReactCurrentDispatcher,zo=G.ReactCurrentBatchConfig,hn=0,De=null,Re=null,Me=null,As=!1,zr=!1,Dr=0,_d=0;function Ve(){throw Error(s(321))}function Do(e,t){if(t===null)return!1;for(var n=0;n<t.length&&n<e.length;n++)if(!gt(e[n],t[n]))return!1;return!0}function Lo(e,t,n,i,l,c){if(hn=c,De=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,Os.current=e===null||e.memoizedState===null?Ld:Od,e=n(i,l),zr){c=0;do{if(zr=!1,Dr=0,25<=c)throw Error(s(301));c+=1,Me=Re=null,t.updateQueue=null,Os.current=Ad,e=n(i,l)}while(zr)}if(Os.current=Rs,t=Re!==null&&Re.next!==null,hn=0,Me=Re=De=null,As=!1,t)throw Error(s(300));return e}function Oo(){var e=Dr!==0;return Dr=0,e}function _t(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return Me===null?De.memoizedState=Me=e:Me=Me.next=e,Me}function ft(){if(Re===null){var e=De.alternate;e=e!==null?e.memoizedState:null}else e=Re.next;var t=Me===null?De.memoizedState:Me.next;if(t!==null)Me=t,Re=e;else{if(e===null)throw Error(s(310));Re=e,e={memoizedState:Re.memoizedState,baseState:Re.baseState,baseQueue:Re.baseQueue,queue:Re.queue,next:null},Me===null?De.memoizedState=Me=e:Me=Me.next=e}return Me}function Lr(e,t){return typeof t=="function"?t(e):t}function Ao(e){var t=ft(),n=t.queue;if(n===null)throw Error(s(311));n.lastRenderedReducer=e;var i=Re,l=i.baseQueue,c=n.pending;if(c!==null){if(l!==null){var p=l.next;l.next=c.next,c.next=p}i.baseQueue=l=c,n.pending=null}if(l!==null){c=l.next,i=i.baseState;var g=p=null,x=null,N=c;do{var A=N.lane;if((hn&A)===A)x!==null&&(x=x.next={lane:0,action:N.action,hasEagerState:N.hasEagerState,eagerState:N.eagerState,next:null}),i=N.hasEagerState?N.eagerState:e(i,N.action);else{var P={lane:A,action:N.action,hasEagerState:N.hasEagerState,eagerState:N.eagerState,next:null};x===null?(g=x=P,p=i):x=x.next=P,De.lanes|=A,mn|=A}N=N.next}while(N!==null&&N!==c);x===null?p=i:x.next=g,gt(i,t.memoizedState)||(Ge=!0),t.memoizedState=i,t.baseState=p,t.baseQueue=x,n.lastRenderedState=i}if(e=n.interleaved,e!==null){l=e;do c=l.lane,De.lanes|=c,mn|=c,l=l.next;while(l!==e)}else l===null&&(n.lanes=0);return[t.memoizedState,n.dispatch]}function Po(e){var t=ft(),n=t.queue;if(n===null)throw Error(s(311));n.lastRenderedReducer=e;var i=n.dispatch,l=n.pending,c=t.memoizedState;if(l!==null){n.pending=null;var p=l=l.next;do c=e(c,p.action),p=p.next;while(p!==l);gt(c,t.memoizedState)||(Ge=!0),t.memoizedState=c,t.baseQueue===null&&(t.baseState=c),n.lastRenderedState=c}return[c,i]}function Fu(){}function Eu(e,t){var n=De,i=ft(),l=t(),c=!gt(i.memoizedState,l);if(c&&(i.memoizedState=l,Ge=!0),i=i.queue,jo(zu.bind(null,n,i,e),[e]),i.getSnapshot!==t||c||Me!==null&&Me.memoizedState.tag&1){if(n.flags|=2048,Or(9,Nu.bind(null,n,i,l,t),void 0,null),Be===null)throw Error(s(349));(hn&30)!==0||_u(n,t,l)}return l}function _u(e,t,n){e.flags|=16384,e={getSnapshot:t,value:n},t=De.updateQueue,t===null?(t={lastEffect:null,stores:null},De.updateQueue=t,t.stores=[e]):(n=t.stores,n===null?t.stores=[e]:n.push(e))}function Nu(e,t,n,i){t.value=n,t.getSnapshot=i,Du(t)&&Lu(e)}function zu(e,t,n){return n(function(){Du(t)&&Lu(e)})}function Du(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!gt(e,n)}catch{return!0}}function Lu(e){var t=Rt(e,1);t!==null&&St(t,e,1,-1)}function Ou(e){var t=_t();return typeof e=="function"&&(e=e()),t.memoizedState=t.baseState=e,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:Lr,lastRenderedState:e},t.queue=e,e=e.dispatch=Dd.bind(null,De,e),[t.memoizedState,e]}function Or(e,t,n,i){return e={tag:e,create:t,destroy:n,deps:i,next:null},t=De.updateQueue,t===null?(t={lastEffect:null,stores:null},De.updateQueue=t,t.lastEffect=e.next=e):(n=t.lastEffect,n===null?t.lastEffect=e.next=e:(i=n.next,n.next=e,e.next=i,t.lastEffect=e)),e}function Au(){return ft().memoizedState}function Ps(e,t,n,i){var l=_t();De.flags|=e,l.memoizedState=Or(1|t,n,void 0,i===void 0?null:i)}function js(e,t,n,i){var l=ft();i=i===void 0?null:i;var c=void 0;if(Re!==null){var p=Re.memoizedState;if(c=p.destroy,i!==null&&Do(i,p.deps)){l.memoizedState=Or(t,n,c,i);return}}De.flags|=e,l.memoizedState=Or(1|t,n,c,i)}function Pu(e,t){return Ps(8390656,8,e,t)}function jo(e,t){return js(2048,8,e,t)}function ju(e,t){return js(4,2,e,t)}function Ru(e,t){return js(4,4,e,t)}function Tu(e,t){if(typeof t=="function")return e=e(),t(e),function(){t(null)};if(t!=null)return e=e(),t.current=e,function(){t.current=null}}function Mu(e,t,n){return n=n!=null?n.concat([e]):null,js(4,4,Tu.bind(null,t,e),n)}function Ro(){}function Bu(e,t){var n=ft();t=t===void 0?null:t;var i=n.memoizedState;return i!==null&&t!==null&&Do(t,i[1])?i[0]:(n.memoizedState=[e,t],e)}function Uu(e,t){var n=ft();t=t===void 0?null:t;var i=n.memoizedState;return i!==null&&t!==null&&Do(t,i[1])?i[0]:(e=e(),n.memoizedState=[e,t],e)}function Iu(e,t,n){return(hn&21)===0?(e.baseState&&(e.baseState=!1,Ge=!0),e.memoizedState=n):(gt(n,t)||(n=gl(),De.lanes|=n,mn|=n,e.baseState=!0),t)}function Nd(e,t){var n=xe;xe=n!==0&&4>n?n:4,e(!0);var i=zo.transition;zo.transition={};try{e(!1),t()}finally{xe=n,zo.transition=i}}function bu(){return ft().memoizedState}function zd(e,t,n){var i=en(e);if(n={lane:i,action:n,hasEagerState:!1,eagerState:null,next:null},$u(e))Xu(t,n);else if(n=xu(e,t,n,i),n!==null){var l=Ke();St(n,e,i,l),Vu(n,t,i)}}function Dd(e,t,n){var i=en(e),l={lane:i,action:n,hasEagerState:!1,eagerState:null,next:null};if($u(e))Xu(t,l);else{var c=e.alternate;if(e.lanes===0&&(c===null||c.lanes===0)&&(c=t.lastRenderedReducer,c!==null))try{var p=t.lastRenderedState,g=c(p,n);if(l.hasEagerState=!0,l.eagerState=g,gt(g,p)){var x=t.interleaved;x===null?(l.next=l,Co(t)):(l.next=x.next,x.next=l),t.interleaved=l;return}}catch{}finally{}n=xu(e,t,l,i),n!==null&&(l=Ke(),St(n,e,i,l),Vu(n,t,i))}}function $u(e){var t=e.alternate;return e===De||t!==null&&t===De}function Xu(e,t){zr=As=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function Vu(e,t,n){if((n&4194240)!==0){var i=t.lanes;i&=e.pendingLanes,n|=i,t.lanes=n,Ti(e,n)}}var Rs={readContext:ct,useCallback:Ve,useContext:Ve,useEffect:Ve,useImperativeHandle:Ve,useInsertionEffect:Ve,useLayoutEffect:Ve,useMemo:Ve,useReducer:Ve,useRef:Ve,useState:Ve,useDebugValue:Ve,useDeferredValue:Ve,useTransition:Ve,useMutableSource:Ve,useSyncExternalStore:Ve,useId:Ve,unstable_isNewReconciler:!1},Ld={readContext:ct,useCallback:function(e,t){return _t().memoizedState=[e,t===void 0?null:t],e},useContext:ct,useEffect:Pu,useImperativeHandle:function(e,t,n){return n=n!=null?n.concat([e]):null,Ps(4194308,4,Tu.bind(null,t,e),n)},useLayoutEffect:function(e,t){return Ps(4194308,4,e,t)},useInsertionEffect:function(e,t){return Ps(4,2,e,t)},useMemo:function(e,t){var n=_t();return t=t===void 0?null:t,e=e(),n.memoizedState=[e,t],e},useReducer:function(e,t,n){var i=_t();return t=n!==void 0?n(t):t,i.memoizedState=i.baseState=t,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:t},i.queue=e,e=e.dispatch=zd.bind(null,De,e),[i.memoizedState,e]},useRef:function(e){var t=_t();return e={current:e},t.memoizedState=e},useState:Ou,useDebugValue:Ro,useDeferredValue:function(e){return _t().memoizedState=e},useTransition:function(){var e=Ou(!1),t=e[0];return e=Nd.bind(null,e[1]),_t().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,n){var i=De,l=_t();if(_e){if(n===void 0)throw Error(s(407));n=n()}else{if(n=t(),Be===null)throw Error(s(349));(hn&30)!==0||_u(i,t,n)}l.memoizedState=n;var c={value:n,getSnapshot:t};return l.queue=c,Pu(zu.bind(null,i,c,e),[e]),i.flags|=2048,Or(9,Nu.bind(null,i,c,n,t),void 0,null),n},useId:function(){var e=_t(),t=Be.identifierPrefix;if(_e){var n=jt,i=Pt;n=(i&~(1<<32-mt(i)-1)).toString(32)+n,t=":"+t+"R"+n,n=Dr++,0<n&&(t+="H"+n.toString(32)),t+=":"}else n=_d++,t=":"+t+"r"+n.toString(32)+":";return e.memoizedState=t},unstable_isNewReconciler:!1},Od={readContext:ct,useCallback:Bu,useContext:ct,useEffect:jo,useImperativeHandle:Mu,useInsertionEffect:ju,useLayoutEffect:Ru,useMemo:Uu,useReducer:Ao,useRef:Au,useState:function(){return Ao(Lr)},useDebugValue:Ro,useDeferredValue:function(e){var t=ft();return Iu(t,Re.memoizedState,e)},useTransition:function(){var e=Ao(Lr)[0],t=ft().memoizedState;return[e,t]},useMutableSource:Fu,useSyncExternalStore:Eu,useId:bu,unstable_isNewReconciler:!1},Ad={readContext:ct,useCallback:Bu,useContext:ct,useEffect:jo,useImperativeHandle:Mu,useInsertionEffect:ju,useLayoutEffect:Ru,useMemo:Uu,useReducer:Po,useRef:Au,useState:function(){return Po(Lr)},useDebugValue:Ro,useDeferredValue:function(e){var t=ft();return Re===null?t.memoizedState=e:Iu(t,Re.memoizedState,e)},useTransition:function(){var e=Po(Lr)[0],t=ft().memoizedState;return[e,t]},useMutableSource:Fu,useSyncExternalStore:Eu,useId:bu,unstable_isNewReconciler:!1};function vt(e,t){if(e&&e.defaultProps){t=B({},t),e=e.defaultProps;for(var n in e)t[n]===void 0&&(t[n]=e[n]);return t}return t}function To(e,t,n,i){t=e.memoizedState,n=n(i,t),n=n==null?t:B({},t,n),e.memoizedState=n,e.lanes===0&&(e.updateQueue.baseState=n)}var Ts={isMounted:function(e){return(e=e._reactInternals)?an(e)===e:!1},enqueueSetState:function(e,t,n){e=e._reactInternals;var i=Ke(),l=en(e),c=Tt(i,l);c.payload=t,n!=null&&(c.callback=n),t=Qt(e,c,l),t!==null&&(St(t,e,l,i),zs(t,e,l))},enqueueReplaceState:function(e,t,n){e=e._reactInternals;var i=Ke(),l=en(e),c=Tt(i,l);c.tag=1,c.payload=t,n!=null&&(c.callback=n),t=Qt(e,c,l),t!==null&&(St(t,e,l,i),zs(t,e,l))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var n=Ke(),i=en(e),l=Tt(n,i);l.tag=2,t!=null&&(l.callback=t),t=Qt(e,l,i),t!==null&&(St(t,e,i,n),zs(t,e,i))}};function Hu(e,t,n,i,l,c,p){return e=e.stateNode,typeof e.shouldComponentUpdate=="function"?e.shouldComponentUpdate(i,c,p):t.prototype&&t.prototype.isPureReactComponent?!yr(n,i)||!yr(l,c):!0}function Zu(e,t,n){var i=!1,l=Wt,c=t.contextType;return typeof c=="object"&&c!==null?c=ct(c):(l=Je(t)?un:Xe.current,i=t.contextTypes,c=(i=i!=null)?Rn(e,l):Wt),t=new t(n,c),e.memoizedState=t.state!==null&&t.state!==void 0?t.state:null,t.updater=Ts,e.stateNode=t,t._reactInternals=e,i&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=l,e.__reactInternalMemoizedMaskedChildContext=c),t}function Wu(e,t,n,i){e=t.state,typeof t.componentWillReceiveProps=="function"&&t.componentWillReceiveProps(n,i),typeof t.UNSAFE_componentWillReceiveProps=="function"&&t.UNSAFE_componentWillReceiveProps(n,i),t.state!==e&&Ts.enqueueReplaceState(t,t.state,null)}function Mo(e,t,n,i){var l=e.stateNode;l.props=n,l.state=e.memoizedState,l.refs={},ko(e);var c=t.contextType;typeof c=="object"&&c!==null?l.context=ct(c):(c=Je(t)?un:Xe.current,l.context=Rn(e,c)),l.state=e.memoizedState,c=t.getDerivedStateFromProps,typeof c=="function"&&(To(e,t,c,n),l.state=e.memoizedState),typeof t.getDerivedStateFromProps=="function"||typeof l.getSnapshotBeforeUpdate=="function"||typeof l.UNSAFE_componentWillMount!="function"&&typeof l.componentWillMount!="function"||(t=l.state,typeof l.componentWillMount=="function"&&l.componentWillMount(),typeof l.UNSAFE_componentWillMount=="function"&&l.UNSAFE_componentWillMount(),t!==l.state&&Ts.enqueueReplaceState(l,l.state,null),Ds(e,n,l,i),l.state=e.memoizedState),typeof l.componentDidMount=="function"&&(e.flags|=4194308)}function Xn(e,t){try{var n="",i=t;do n+=Q(i),i=i.return;while(i);var l=n}catch(c){l=`
|
|
39
|
+
Error generating stack: `+c.message+`
|
|
40
|
+
`+c.stack}return{value:e,source:t,stack:l,digest:null}}function Bo(e,t,n){return{value:e,source:null,stack:n??null,digest:t??null}}function Uo(e,t){try{console.error(t.value)}catch(n){setTimeout(function(){throw n})}}var Pd=typeof WeakMap=="function"?WeakMap:Map;function Ku(e,t,n){n=Tt(-1,n),n.tag=3,n.payload={element:null};var i=t.value;return n.callback=function(){Xs||(Xs=!0,ea=i),Uo(e,t)},n}function qu(e,t,n){n=Tt(-1,n),n.tag=3;var i=e.type.getDerivedStateFromError;if(typeof i=="function"){var l=t.value;n.payload=function(){return i(l)},n.callback=function(){Uo(e,t)}}var c=e.stateNode;return c!==null&&typeof c.componentDidCatch=="function"&&(n.callback=function(){Uo(e,t),typeof i!="function"&&(Jt===null?Jt=new Set([this]):Jt.add(this));var p=t.stack;this.componentDidCatch(t.value,{componentStack:p!==null?p:""})}),n}function Qu(e,t,n){var i=e.pingCache;if(i===null){i=e.pingCache=new Pd;var l=new Set;i.set(t,l)}else l=i.get(t),l===void 0&&(l=new Set,i.set(t,l));l.has(n)||(l.add(n),e=Wd.bind(null,e,t,n),t.then(e,e))}function Yu(e){do{var t;if((t=e.tag===13)&&(t=e.memoizedState,t=t!==null?t.dehydrated!==null:!0),t)return e;e=e.return}while(e!==null);return null}function Ju(e,t,n,i,l){return(e.mode&1)===0?(e===t?e.flags|=65536:(e.flags|=128,n.flags|=131072,n.flags&=-52805,n.tag===1&&(n.alternate===null?n.tag=17:(t=Tt(-1,1),t.tag=2,Qt(n,t,1))),n.lanes|=1),e):(e.flags|=65536,e.lanes=l,e)}var jd=G.ReactCurrentOwner,Ge=!1;function We(e,t,n,i){t.child=e===null?vu(t,null,n,i):Un(t,e.child,n,i)}function Gu(e,t,n,i,l){n=n.render;var c=t.ref;return bn(t,l),i=Lo(e,t,n,i,c,l),n=Oo(),e!==null&&!Ge?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~l,Mt(e,t,l)):(_e&&n&&po(t),t.flags|=1,We(e,t,i,l),t.child)}function ec(e,t,n,i,l){if(e===null){var c=n.type;return typeof c=="function"&&!aa(c)&&c.defaultProps===void 0&&n.compare===null&&n.defaultProps===void 0?(t.tag=15,t.type=c,tc(e,t,c,i,l)):(e=qs(n.type,null,i,t,t.mode,l),e.ref=t.ref,e.return=t,t.child=e)}if(c=e.child,(e.lanes&l)===0){var p=c.memoizedProps;if(n=n.compare,n=n!==null?n:yr,n(p,i)&&e.ref===t.ref)return Mt(e,t,l)}return t.flags|=1,e=nn(c,i),e.ref=t.ref,e.return=t,t.child=e}function tc(e,t,n,i,l){if(e!==null){var c=e.memoizedProps;if(yr(c,i)&&e.ref===t.ref)if(Ge=!1,t.pendingProps=i=c,(e.lanes&l)!==0)(e.flags&131072)!==0&&(Ge=!0);else return t.lanes=e.lanes,Mt(e,t,l)}return Io(e,t,n,i,l)}function nc(e,t,n){var i=t.pendingProps,l=i.children,c=e!==null?e.memoizedState:null;if(i.mode==="hidden")if((t.mode&1)===0)t.memoizedState={baseLanes:0,cachePool:null,transitions:null},Ce(Hn,at),at|=n;else{if((n&1073741824)===0)return e=c!==null?c.baseLanes|n:n,t.lanes=t.childLanes=1073741824,t.memoizedState={baseLanes:e,cachePool:null,transitions:null},t.updateQueue=null,Ce(Hn,at),at|=e,null;t.memoizedState={baseLanes:0,cachePool:null,transitions:null},i=c!==null?c.baseLanes:n,Ce(Hn,at),at|=i}else c!==null?(i=c.baseLanes|n,t.memoizedState=null):i=n,Ce(Hn,at),at|=i;return We(e,t,l,n),t.child}function rc(e,t){var n=t.ref;(e===null&&n!==null||e!==null&&e.ref!==n)&&(t.flags|=512,t.flags|=2097152)}function Io(e,t,n,i,l){var c=Je(n)?un:Xe.current;return c=Rn(t,c),bn(t,l),n=Lo(e,t,n,i,c,l),i=Oo(),e!==null&&!Ge?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~l,Mt(e,t,l)):(_e&&i&&po(t),t.flags|=1,We(e,t,n,l),t.child)}function sc(e,t,n,i,l){if(Je(n)){var c=!0;ws(t)}else c=!1;if(bn(t,l),t.stateNode===null)Bs(e,t),Zu(t,n,i),Mo(t,n,i,l),i=!0;else if(e===null){var p=t.stateNode,g=t.memoizedProps;p.props=g;var x=p.context,N=n.contextType;typeof N=="object"&&N!==null?N=ct(N):(N=Je(n)?un:Xe.current,N=Rn(t,N));var A=n.getDerivedStateFromProps,P=typeof A=="function"||typeof p.getSnapshotBeforeUpdate=="function";P||typeof p.UNSAFE_componentWillReceiveProps!="function"&&typeof p.componentWillReceiveProps!="function"||(g!==i||x!==N)&&Wu(t,p,i,N),qt=!1;var O=t.memoizedState;p.state=O,Ds(t,i,p,l),x=t.memoizedState,g!==i||O!==x||Ye.current||qt?(typeof A=="function"&&(To(t,n,A,i),x=t.memoizedState),(g=qt||Hu(t,n,g,i,O,x,N))?(P||typeof p.UNSAFE_componentWillMount!="function"&&typeof p.componentWillMount!="function"||(typeof p.componentWillMount=="function"&&p.componentWillMount(),typeof p.UNSAFE_componentWillMount=="function"&&p.UNSAFE_componentWillMount()),typeof p.componentDidMount=="function"&&(t.flags|=4194308)):(typeof p.componentDidMount=="function"&&(t.flags|=4194308),t.memoizedProps=i,t.memoizedState=x),p.props=i,p.state=x,p.context=N,i=g):(typeof p.componentDidMount=="function"&&(t.flags|=4194308),i=!1)}else{p=t.stateNode,wu(e,t),g=t.memoizedProps,N=t.type===t.elementType?g:vt(t.type,g),p.props=N,P=t.pendingProps,O=p.context,x=n.contextType,typeof x=="object"&&x!==null?x=ct(x):(x=Je(n)?un:Xe.current,x=Rn(t,x));var U=n.getDerivedStateFromProps;(A=typeof U=="function"||typeof p.getSnapshotBeforeUpdate=="function")||typeof p.UNSAFE_componentWillReceiveProps!="function"&&typeof p.componentWillReceiveProps!="function"||(g!==P||O!==x)&&Wu(t,p,i,x),qt=!1,O=t.memoizedState,p.state=O,Ds(t,i,p,l);var b=t.memoizedState;g!==P||O!==b||Ye.current||qt?(typeof U=="function"&&(To(t,n,U,i),b=t.memoizedState),(N=qt||Hu(t,n,N,i,O,b,x)||!1)?(A||typeof p.UNSAFE_componentWillUpdate!="function"&&typeof p.componentWillUpdate!="function"||(typeof p.componentWillUpdate=="function"&&p.componentWillUpdate(i,b,x),typeof p.UNSAFE_componentWillUpdate=="function"&&p.UNSAFE_componentWillUpdate(i,b,x)),typeof p.componentDidUpdate=="function"&&(t.flags|=4),typeof p.getSnapshotBeforeUpdate=="function"&&(t.flags|=1024)):(typeof p.componentDidUpdate!="function"||g===e.memoizedProps&&O===e.memoizedState||(t.flags|=4),typeof p.getSnapshotBeforeUpdate!="function"||g===e.memoizedProps&&O===e.memoizedState||(t.flags|=1024),t.memoizedProps=i,t.memoizedState=b),p.props=i,p.state=b,p.context=x,i=N):(typeof p.componentDidUpdate!="function"||g===e.memoizedProps&&O===e.memoizedState||(t.flags|=4),typeof p.getSnapshotBeforeUpdate!="function"||g===e.memoizedProps&&O===e.memoizedState||(t.flags|=1024),i=!1)}return bo(e,t,n,i,c,l)}function bo(e,t,n,i,l,c){rc(e,t);var p=(t.flags&128)!==0;if(!i&&!p)return l&&uu(t,n,!1),Mt(e,t,c);i=t.stateNode,jd.current=t;var g=p&&typeof n.getDerivedStateFromError!="function"?null:i.render();return t.flags|=1,e!==null&&p?(t.child=Un(t,e.child,null,c),t.child=Un(t,null,g,c)):We(e,t,g,c),t.memoizedState=i.state,l&&uu(t,n,!0),t.child}function ic(e){var t=e.stateNode;t.pendingContext?au(e,t.pendingContext,t.pendingContext!==t.context):t.context&&au(e,t.context,!1),Fo(e,t.containerInfo)}function oc(e,t,n,i,l){return Bn(),yo(l),t.flags|=256,We(e,t,n,i),t.child}var $o={dehydrated:null,treeContext:null,retryLane:0};function Xo(e){return{baseLanes:e,cachePool:null,transitions:null}}function ac(e,t,n){var i=t.pendingProps,l=ze.current,c=!1,p=(t.flags&128)!==0,g;if((g=p)||(g=e!==null&&e.memoizedState===null?!1:(l&2)!==0),g?(c=!0,t.flags&=-129):(e===null||e.memoizedState!==null)&&(l|=1),Ce(ze,l&1),e===null)return go(t),e=t.memoizedState,e!==null&&(e=e.dehydrated,e!==null)?((t.mode&1)===0?t.lanes=1:e.data==="$!"?t.lanes=8:t.lanes=1073741824,null):(p=i.children,e=i.fallback,c?(i=t.mode,c=t.child,p={mode:"hidden",children:p},(i&1)===0&&c!==null?(c.childLanes=0,c.pendingProps=p):c=Qs(p,i,0,null),e=xn(e,i,n,null),c.return=t,e.return=t,c.sibling=e,t.child=c,t.child.memoizedState=Xo(n),t.memoizedState=$o,e):Vo(t,p));if(l=e.memoizedState,l!==null&&(g=l.dehydrated,g!==null))return Rd(e,t,p,i,g,l,n);if(c){c=i.fallback,p=t.mode,l=e.child,g=l.sibling;var x={mode:"hidden",children:i.children};return(p&1)===0&&t.child!==l?(i=t.child,i.childLanes=0,i.pendingProps=x,t.deletions=null):(i=nn(l,x),i.subtreeFlags=l.subtreeFlags&14680064),g!==null?c=nn(g,c):(c=xn(c,p,n,null),c.flags|=2),c.return=t,i.return=t,i.sibling=c,t.child=i,i=c,c=t.child,p=e.child.memoizedState,p=p===null?Xo(n):{baseLanes:p.baseLanes|n,cachePool:null,transitions:p.transitions},c.memoizedState=p,c.childLanes=e.childLanes&~n,t.memoizedState=$o,i}return c=e.child,e=c.sibling,i=nn(c,{mode:"visible",children:i.children}),(t.mode&1)===0&&(i.lanes=n),i.return=t,i.sibling=null,e!==null&&(n=t.deletions,n===null?(t.deletions=[e],t.flags|=16):n.push(e)),t.child=i,t.memoizedState=null,i}function Vo(e,t){return t=Qs({mode:"visible",children:t},e.mode,0,null),t.return=e,e.child=t}function Ms(e,t,n,i){return i!==null&&yo(i),Un(t,e.child,null,n),e=Vo(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function Rd(e,t,n,i,l,c,p){if(n)return t.flags&256?(t.flags&=-257,i=Bo(Error(s(422))),Ms(e,t,p,i)):t.memoizedState!==null?(t.child=e.child,t.flags|=128,null):(c=i.fallback,l=t.mode,i=Qs({mode:"visible",children:i.children},l,0,null),c=xn(c,l,p,null),c.flags|=2,i.return=t,c.return=t,i.sibling=c,t.child=i,(t.mode&1)!==0&&Un(t,e.child,null,p),t.child.memoizedState=Xo(p),t.memoizedState=$o,c);if((t.mode&1)===0)return Ms(e,t,p,null);if(l.data==="$!"){if(i=l.nextSibling&&l.nextSibling.dataset,i)var g=i.dgst;return i=g,c=Error(s(419)),i=Bo(c,i,void 0),Ms(e,t,p,i)}if(g=(p&e.childLanes)!==0,Ge||g){if(i=Be,i!==null){switch(p&-p){case 4:l=2;break;case 16:l=8;break;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:l=32;break;case 536870912:l=268435456;break;default:l=0}l=(l&(i.suspendedLanes|p))!==0?0:l,l!==0&&l!==c.retryLane&&(c.retryLane=l,Rt(e,l),St(i,e,l,-1))}return oa(),i=Bo(Error(s(421))),Ms(e,t,p,i)}return l.data==="$?"?(t.flags|=128,t.child=e.child,t=Kd.bind(null,e),l._reactRetry=t,null):(e=c.treeContext,ot=Ht(l.nextSibling),it=t,_e=!0,yt=null,e!==null&&(lt[ut++]=Pt,lt[ut++]=jt,lt[ut++]=cn,Pt=e.id,jt=e.overflow,cn=t),t=Vo(t,i.children),t.flags|=4096,t)}function lc(e,t,n){e.lanes|=t;var i=e.alternate;i!==null&&(i.lanes|=t),So(e.return,t,n)}function Ho(e,t,n,i,l){var c=e.memoizedState;c===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:i,tail:n,tailMode:l}:(c.isBackwards=t,c.rendering=null,c.renderingStartTime=0,c.last=i,c.tail=n,c.tailMode=l)}function uc(e,t,n){var i=t.pendingProps,l=i.revealOrder,c=i.tail;if(We(e,t,i.children,n),i=ze.current,(i&2)!==0)i=i&1|2,t.flags|=128;else{if(e!==null&&(e.flags&128)!==0)e:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&lc(e,n,t);else if(e.tag===19)lc(e,n,t);else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break e;for(;e.sibling===null;){if(e.return===null||e.return===t)break e;e=e.return}e.sibling.return=e.return,e=e.sibling}i&=1}if(Ce(ze,i),(t.mode&1)===0)t.memoizedState=null;else switch(l){case"forwards":for(n=t.child,l=null;n!==null;)e=n.alternate,e!==null&&Ls(e)===null&&(l=n),n=n.sibling;n=l,n===null?(l=t.child,t.child=null):(l=n.sibling,n.sibling=null),Ho(t,!1,l,n,c);break;case"backwards":for(n=null,l=t.child,t.child=null;l!==null;){if(e=l.alternate,e!==null&&Ls(e)===null){t.child=l;break}e=l.sibling,l.sibling=n,n=l,l=e}Ho(t,!0,n,null,c);break;case"together":Ho(t,!1,null,null,void 0);break;default:t.memoizedState=null}return t.child}function Bs(e,t){(t.mode&1)===0&&e!==null&&(e.alternate=null,t.alternate=null,t.flags|=2)}function Mt(e,t,n){if(e!==null&&(t.dependencies=e.dependencies),mn|=t.lanes,(n&t.childLanes)===0)return null;if(e!==null&&t.child!==e.child)throw Error(s(153));if(t.child!==null){for(e=t.child,n=nn(e,e.pendingProps),t.child=n,n.return=t;e.sibling!==null;)e=e.sibling,n=n.sibling=nn(e,e.pendingProps),n.return=t;n.sibling=null}return t.child}function Td(e,t,n){switch(t.tag){case 3:ic(t),Bn();break;case 5:ku(t);break;case 1:Je(t.type)&&ws(t);break;case 4:Fo(t,t.stateNode.containerInfo);break;case 10:var i=t.type._context,l=t.memoizedProps.value;Ce(_s,i._currentValue),i._currentValue=l;break;case 13:if(i=t.memoizedState,i!==null)return i.dehydrated!==null?(Ce(ze,ze.current&1),t.flags|=128,null):(n&t.child.childLanes)!==0?ac(e,t,n):(Ce(ze,ze.current&1),e=Mt(e,t,n),e!==null?e.sibling:null);Ce(ze,ze.current&1);break;case 19:if(i=(n&t.childLanes)!==0,(e.flags&128)!==0){if(i)return uc(e,t,n);t.flags|=128}if(l=t.memoizedState,l!==null&&(l.rendering=null,l.tail=null,l.lastEffect=null),Ce(ze,ze.current),i)break;return null;case 22:case 23:return t.lanes=0,nc(e,t,n)}return Mt(e,t,n)}var cc,Zo,fc,pc;cc=function(e,t){for(var n=t.child;n!==null;){if(n.tag===5||n.tag===6)e.appendChild(n.stateNode);else if(n.tag!==4&&n.child!==null){n.child.return=n,n=n.child;continue}if(n===t)break;for(;n.sibling===null;){if(n.return===null||n.return===t)return;n=n.return}n.sibling.return=n.return,n=n.sibling}},Zo=function(){},fc=function(e,t,n,i){var l=e.memoizedProps;if(l!==i){e=t.stateNode,dn(Et.current);var c=null;switch(n){case"input":l=wi(e,l),i=wi(e,i),c=[];break;case"select":l=B({},l,{value:void 0}),i=B({},i,{value:void 0}),c=[];break;case"textarea":l=ki(e,l),i=ki(e,i),c=[];break;default:typeof l.onClick!="function"&&typeof i.onClick=="function"&&(e.onclick=ys)}Ei(n,i);var p;n=null;for(N in l)if(!i.hasOwnProperty(N)&&l.hasOwnProperty(N)&&l[N]!=null)if(N==="style"){var g=l[N];for(p in g)g.hasOwnProperty(p)&&(n||(n={}),n[p]="")}else N!=="dangerouslySetInnerHTML"&&N!=="children"&&N!=="suppressContentEditableWarning"&&N!=="suppressHydrationWarning"&&N!=="autoFocus"&&(u.hasOwnProperty(N)?c||(c=[]):(c=c||[]).push(N,null));for(N in i){var x=i[N];if(g=l!=null?l[N]:void 0,i.hasOwnProperty(N)&&x!==g&&(x!=null||g!=null))if(N==="style")if(g){for(p in g)!g.hasOwnProperty(p)||x&&x.hasOwnProperty(p)||(n||(n={}),n[p]="");for(p in x)x.hasOwnProperty(p)&&g[p]!==x[p]&&(n||(n={}),n[p]=x[p])}else n||(c||(c=[]),c.push(N,n)),n=x;else N==="dangerouslySetInnerHTML"?(x=x?x.__html:void 0,g=g?g.__html:void 0,x!=null&&g!==x&&(c=c||[]).push(N,x)):N==="children"?typeof x!="string"&&typeof x!="number"||(c=c||[]).push(N,""+x):N!=="suppressContentEditableWarning"&&N!=="suppressHydrationWarning"&&(u.hasOwnProperty(N)?(x!=null&&N==="onScroll"&&ke("scroll",e),c||g===x||(c=[])):(c=c||[]).push(N,x))}n&&(c=c||[]).push("style",n);var N=c;(t.updateQueue=N)&&(t.flags|=4)}},pc=function(e,t,n,i){n!==i&&(t.flags|=4)};function Ar(e,t){if(!_e)switch(e.tailMode){case"hidden":t=e.tail;for(var n=null;t!==null;)t.alternate!==null&&(n=t),t=t.sibling;n===null?e.tail=null:n.sibling=null;break;case"collapsed":n=e.tail;for(var i=null;n!==null;)n.alternate!==null&&(i=n),n=n.sibling;i===null?t||e.tail===null?e.tail=null:e.tail.sibling=null:i.sibling=null}}function He(e){var t=e.alternate!==null&&e.alternate.child===e.child,n=0,i=0;if(t)for(var l=e.child;l!==null;)n|=l.lanes|l.childLanes,i|=l.subtreeFlags&14680064,i|=l.flags&14680064,l.return=e,l=l.sibling;else for(l=e.child;l!==null;)n|=l.lanes|l.childLanes,i|=l.subtreeFlags,i|=l.flags,l.return=e,l=l.sibling;return e.subtreeFlags|=i,e.childLanes=n,t}function Md(e,t,n){var i=t.pendingProps;switch(ho(t),t.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return He(t),null;case 1:return Je(t.type)&&xs(),He(t),null;case 3:return i=t.stateNode,$n(),Fe(Ye),Fe(Xe),No(),i.pendingContext&&(i.context=i.pendingContext,i.pendingContext=null),(e===null||e.child===null)&&(Fs(t)?t.flags|=4:e===null||e.memoizedState.isDehydrated&&(t.flags&256)===0||(t.flags|=1024,yt!==null&&(ra(yt),yt=null))),Zo(e,t),He(t),null;case 5:Eo(t);var l=dn(Nr.current);if(n=t.type,e!==null&&t.stateNode!=null)fc(e,t,n,i,l),e.ref!==t.ref&&(t.flags|=512,t.flags|=2097152);else{if(!i){if(t.stateNode===null)throw Error(s(166));return He(t),null}if(e=dn(Et.current),Fs(t)){i=t.stateNode,n=t.type;var c=t.memoizedProps;switch(i[Ft]=t,i[Cr]=c,e=(t.mode&1)!==0,n){case"dialog":ke("cancel",i),ke("close",i);break;case"iframe":case"object":case"embed":ke("load",i);break;case"video":case"audio":for(l=0;l<xr.length;l++)ke(xr[l],i);break;case"source":ke("error",i);break;case"img":case"image":case"link":ke("error",i),ke("load",i);break;case"details":ke("toggle",i);break;case"input":Za(i,c),ke("invalid",i);break;case"select":i._wrapperState={wasMultiple:!!c.multiple},ke("invalid",i);break;case"textarea":qa(i,c),ke("invalid",i)}Ei(n,c),l=null;for(var p in c)if(c.hasOwnProperty(p)){var g=c[p];p==="children"?typeof g=="string"?i.textContent!==g&&(c.suppressHydrationWarning!==!0&&gs(i.textContent,g,e),l=["children",g]):typeof g=="number"&&i.textContent!==""+g&&(c.suppressHydrationWarning!==!0&&gs(i.textContent,g,e),l=["children",""+g]):u.hasOwnProperty(p)&&g!=null&&p==="onScroll"&&ke("scroll",i)}switch(n){case"input":Wr(i),Ka(i,c,!0);break;case"textarea":Wr(i),Ya(i);break;case"select":case"option":break;default:typeof c.onClick=="function"&&(i.onclick=ys)}i=l,t.updateQueue=i,i!==null&&(t.flags|=4)}else{p=l.nodeType===9?l:l.ownerDocument,e==="http://www.w3.org/1999/xhtml"&&(e=Ja(n)),e==="http://www.w3.org/1999/xhtml"?n==="script"?(e=p.createElement("div"),e.innerHTML="<script><\/script>",e=e.removeChild(e.firstChild)):typeof i.is=="string"?e=p.createElement(n,{is:i.is}):(e=p.createElement(n),n==="select"&&(p=e,i.multiple?p.multiple=!0:i.size&&(p.size=i.size))):e=p.createElementNS(e,n),e[Ft]=t,e[Cr]=i,cc(e,t,!1,!1),t.stateNode=e;e:{switch(p=_i(n,i),n){case"dialog":ke("cancel",e),ke("close",e),l=i;break;case"iframe":case"object":case"embed":ke("load",e),l=i;break;case"video":case"audio":for(l=0;l<xr.length;l++)ke(xr[l],e);l=i;break;case"source":ke("error",e),l=i;break;case"img":case"image":case"link":ke("error",e),ke("load",e),l=i;break;case"details":ke("toggle",e),l=i;break;case"input":Za(e,i),l=wi(e,i),ke("invalid",e);break;case"option":l=i;break;case"select":e._wrapperState={wasMultiple:!!i.multiple},l=B({},i,{value:void 0}),ke("invalid",e);break;case"textarea":qa(e,i),l=ki(e,i),ke("invalid",e);break;default:l=i}Ei(n,l),g=l;for(c in g)if(g.hasOwnProperty(c)){var x=g[c];c==="style"?tl(e,x):c==="dangerouslySetInnerHTML"?(x=x?x.__html:void 0,x!=null&&Ga(e,x)):c==="children"?typeof x=="string"?(n!=="textarea"||x!=="")&&er(e,x):typeof x=="number"&&er(e,""+x):c!=="suppressContentEditableWarning"&&c!=="suppressHydrationWarning"&&c!=="autoFocus"&&(u.hasOwnProperty(c)?x!=null&&c==="onScroll"&&ke("scroll",e):x!=null&&ge(e,c,x,p))}switch(n){case"input":Wr(e),Ka(e,i,!1);break;case"textarea":Wr(e),Ya(e);break;case"option":i.value!=null&&e.setAttribute("value",""+ce(i.value));break;case"select":e.multiple=!!i.multiple,c=i.value,c!=null?kn(e,!!i.multiple,c,!1):i.defaultValue!=null&&kn(e,!!i.multiple,i.defaultValue,!0);break;default:typeof l.onClick=="function"&&(e.onclick=ys)}switch(n){case"button":case"input":case"select":case"textarea":i=!!i.autoFocus;break e;case"img":i=!0;break e;default:i=!1}}i&&(t.flags|=4)}t.ref!==null&&(t.flags|=512,t.flags|=2097152)}return He(t),null;case 6:if(e&&t.stateNode!=null)pc(e,t,e.memoizedProps,i);else{if(typeof i!="string"&&t.stateNode===null)throw Error(s(166));if(n=dn(Nr.current),dn(Et.current),Fs(t)){if(i=t.stateNode,n=t.memoizedProps,i[Ft]=t,(c=i.nodeValue!==n)&&(e=it,e!==null))switch(e.tag){case 3:gs(i.nodeValue,n,(e.mode&1)!==0);break;case 5:e.memoizedProps.suppressHydrationWarning!==!0&&gs(i.nodeValue,n,(e.mode&1)!==0)}c&&(t.flags|=4)}else i=(n.nodeType===9?n:n.ownerDocument).createTextNode(i),i[Ft]=t,t.stateNode=i}return He(t),null;case 13:if(Fe(ze),i=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(_e&&ot!==null&&(t.mode&1)!==0&&(t.flags&128)===0)mu(),Bn(),t.flags|=98560,c=!1;else if(c=Fs(t),i!==null&&i.dehydrated!==null){if(e===null){if(!c)throw Error(s(318));if(c=t.memoizedState,c=c!==null?c.dehydrated:null,!c)throw Error(s(317));c[Ft]=t}else Bn(),(t.flags&128)===0&&(t.memoizedState=null),t.flags|=4;He(t),c=!1}else yt!==null&&(ra(yt),yt=null),c=!0;if(!c)return t.flags&65536?t:null}return(t.flags&128)!==0?(t.lanes=n,t):(i=i!==null,i!==(e!==null&&e.memoizedState!==null)&&i&&(t.child.flags|=8192,(t.mode&1)!==0&&(e===null||(ze.current&1)!==0?Te===0&&(Te=3):oa())),t.updateQueue!==null&&(t.flags|=4),He(t),null);case 4:return $n(),Zo(e,t),e===null&&wr(t.stateNode.containerInfo),He(t),null;case 10:return wo(t.type._context),He(t),null;case 17:return Je(t.type)&&xs(),He(t),null;case 19:if(Fe(ze),c=t.memoizedState,c===null)return He(t),null;if(i=(t.flags&128)!==0,p=c.rendering,p===null)if(i)Ar(c,!1);else{if(Te!==0||e!==null&&(e.flags&128)!==0)for(e=t.child;e!==null;){if(p=Ls(e),p!==null){for(t.flags|=128,Ar(c,!1),i=p.updateQueue,i!==null&&(t.updateQueue=i,t.flags|=4),t.subtreeFlags=0,i=n,n=t.child;n!==null;)c=n,e=i,c.flags&=14680066,p=c.alternate,p===null?(c.childLanes=0,c.lanes=e,c.child=null,c.subtreeFlags=0,c.memoizedProps=null,c.memoizedState=null,c.updateQueue=null,c.dependencies=null,c.stateNode=null):(c.childLanes=p.childLanes,c.lanes=p.lanes,c.child=p.child,c.subtreeFlags=0,c.deletions=null,c.memoizedProps=p.memoizedProps,c.memoizedState=p.memoizedState,c.updateQueue=p.updateQueue,c.type=p.type,e=p.dependencies,c.dependencies=e===null?null:{lanes:e.lanes,firstContext:e.firstContext}),n=n.sibling;return Ce(ze,ze.current&1|2),t.child}e=e.sibling}c.tail!==null&&Oe()>Zn&&(t.flags|=128,i=!0,Ar(c,!1),t.lanes=4194304)}else{if(!i)if(e=Ls(p),e!==null){if(t.flags|=128,i=!0,n=e.updateQueue,n!==null&&(t.updateQueue=n,t.flags|=4),Ar(c,!0),c.tail===null&&c.tailMode==="hidden"&&!p.alternate&&!_e)return He(t),null}else 2*Oe()-c.renderingStartTime>Zn&&n!==1073741824&&(t.flags|=128,i=!0,Ar(c,!1),t.lanes=4194304);c.isBackwards?(p.sibling=t.child,t.child=p):(n=c.last,n!==null?n.sibling=p:t.child=p,c.last=p)}return c.tail!==null?(t=c.tail,c.rendering=t,c.tail=t.sibling,c.renderingStartTime=Oe(),t.sibling=null,n=ze.current,Ce(ze,i?n&1|2:n&1),t):(He(t),null);case 22:case 23:return ia(),i=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==i&&(t.flags|=8192),i&&(t.mode&1)!==0?(at&1073741824)!==0&&(He(t),t.subtreeFlags&6&&(t.flags|=8192)):He(t),null;case 24:return null;case 25:return null}throw Error(s(156,t.tag))}function Bd(e,t){switch(ho(t),t.tag){case 1:return Je(t.type)&&xs(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return $n(),Fe(Ye),Fe(Xe),No(),e=t.flags,(e&65536)!==0&&(e&128)===0?(t.flags=e&-65537|128,t):null;case 5:return Eo(t),null;case 13:if(Fe(ze),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(s(340));Bn()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return Fe(ze),null;case 4:return $n(),null;case 10:return wo(t.type._context),null;case 22:case 23:return ia(),null;case 24:return null;default:return null}}var Us=!1,Ze=!1,Ud=typeof WeakSet=="function"?WeakSet:Set,I=null;function Vn(e,t){var n=e.ref;if(n!==null)if(typeof n=="function")try{n(null)}catch(i){Le(e,t,i)}else n.current=null}function Wo(e,t,n){try{n()}catch(i){Le(e,t,i)}}var dc=!1;function Id(e,t){if(so=is,e=Hl(),Qi(e)){if("selectionStart"in e)var n={start:e.selectionStart,end:e.selectionEnd};else e:{n=(n=e.ownerDocument)&&n.defaultView||window;var i=n.getSelection&&n.getSelection();if(i&&i.rangeCount!==0){n=i.anchorNode;var l=i.anchorOffset,c=i.focusNode;i=i.focusOffset;try{n.nodeType,c.nodeType}catch{n=null;break e}var p=0,g=-1,x=-1,N=0,A=0,P=e,O=null;t:for(;;){for(var U;P!==n||l!==0&&P.nodeType!==3||(g=p+l),P!==c||i!==0&&P.nodeType!==3||(x=p+i),P.nodeType===3&&(p+=P.nodeValue.length),(U=P.firstChild)!==null;)O=P,P=U;for(;;){if(P===e)break t;if(O===n&&++N===l&&(g=p),O===c&&++A===i&&(x=p),(U=P.nextSibling)!==null)break;P=O,O=P.parentNode}P=U}n=g===-1||x===-1?null:{start:g,end:x}}else n=null}n=n||{start:0,end:0}}else n=null;for(io={focusedElem:e,selectionRange:n},is=!1,I=t;I!==null;)if(t=I,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,I=e;else for(;I!==null;){t=I;try{var b=t.alternate;if((t.flags&1024)!==0)switch(t.tag){case 0:case 11:case 15:break;case 1:if(b!==null){var X=b.memoizedProps,Ae=b.memoizedState,k=t.stateNode,w=k.getSnapshotBeforeUpdate(t.elementType===t.type?X:vt(t.type,X),Ae);k.__reactInternalSnapshotBeforeUpdate=w}break;case 3:var _=t.stateNode.containerInfo;_.nodeType===1?_.textContent="":_.nodeType===9&&_.documentElement&&_.removeChild(_.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(s(163))}}catch(j){Le(t,t.return,j)}if(e=t.sibling,e!==null){e.return=t.return,I=e;break}I=t.return}return b=dc,dc=!1,b}function Pr(e,t,n){var i=t.updateQueue;if(i=i!==null?i.lastEffect:null,i!==null){var l=i=i.next;do{if((l.tag&e)===e){var c=l.destroy;l.destroy=void 0,c!==void 0&&Wo(t,n,c)}l=l.next}while(l!==i)}}function Is(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 i=n.create;n.destroy=i()}n=n.next}while(n!==t)}}function Ko(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 hc(e){var t=e.alternate;t!==null&&(e.alternate=null,hc(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[Ft],delete t[Cr],delete t[uo],delete t[Cd],delete t[kd])),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 mc(e){return e.tag===5||e.tag===3||e.tag===4}function gc(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||mc(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 qo(e,t,n){var i=e.tag;if(i===5||i===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=ys));else if(i!==4&&(e=e.child,e!==null))for(qo(e,t,n),e=e.sibling;e!==null;)qo(e,t,n),e=e.sibling}function Qo(e,t,n){var i=e.tag;if(i===5||i===6)e=e.stateNode,t?n.insertBefore(e,t):n.appendChild(e);else if(i!==4&&(e=e.child,e!==null))for(Qo(e,t,n),e=e.sibling;e!==null;)Qo(e,t,n),e=e.sibling}var Ie=null,xt=!1;function Yt(e,t,n){for(n=n.child;n!==null;)yc(e,t,n),n=n.sibling}function yc(e,t,n){if(kt&&typeof kt.onCommitFiberUnmount=="function")try{kt.onCommitFiberUnmount(Gr,n)}catch{}switch(n.tag){case 5:Ze||Vn(n,t);case 6:var i=Ie,l=xt;Ie=null,Yt(e,t,n),Ie=i,xt=l,Ie!==null&&(xt?(e=Ie,n=n.stateNode,e.nodeType===8?e.parentNode.removeChild(n):e.removeChild(n)):Ie.removeChild(n.stateNode));break;case 18:Ie!==null&&(xt?(e=Ie,n=n.stateNode,e.nodeType===8?lo(e.parentNode,n):e.nodeType===1&&lo(e,n),fr(e)):lo(Ie,n.stateNode));break;case 4:i=Ie,l=xt,Ie=n.stateNode.containerInfo,xt=!0,Yt(e,t,n),Ie=i,xt=l;break;case 0:case 11:case 14:case 15:if(!Ze&&(i=n.updateQueue,i!==null&&(i=i.lastEffect,i!==null))){l=i=i.next;do{var c=l,p=c.destroy;c=c.tag,p!==void 0&&((c&2)!==0||(c&4)!==0)&&Wo(n,t,p),l=l.next}while(l!==i)}Yt(e,t,n);break;case 1:if(!Ze&&(Vn(n,t),i=n.stateNode,typeof i.componentWillUnmount=="function"))try{i.props=n.memoizedProps,i.state=n.memoizedState,i.componentWillUnmount()}catch(g){Le(n,t,g)}Yt(e,t,n);break;case 21:Yt(e,t,n);break;case 22:n.mode&1?(Ze=(i=Ze)||n.memoizedState!==null,Yt(e,t,n),Ze=i):Yt(e,t,n);break;default:Yt(e,t,n)}}function vc(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var n=e.stateNode;n===null&&(n=e.stateNode=new Ud),t.forEach(function(i){var l=qd.bind(null,e,i);n.has(i)||(n.add(i),i.then(l,l))})}}function wt(e,t){var n=t.deletions;if(n!==null)for(var i=0;i<n.length;i++){var l=n[i];try{var c=e,p=t,g=p;e:for(;g!==null;){switch(g.tag){case 5:Ie=g.stateNode,xt=!1;break e;case 3:Ie=g.stateNode.containerInfo,xt=!0;break e;case 4:Ie=g.stateNode.containerInfo,xt=!0;break e}g=g.return}if(Ie===null)throw Error(s(160));yc(c,p,l),Ie=null,xt=!1;var x=l.alternate;x!==null&&(x.return=null),l.return=null}catch(N){Le(l,t,N)}}if(t.subtreeFlags&12854)for(t=t.child;t!==null;)xc(t,e),t=t.sibling}function xc(e,t){var n=e.alternate,i=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:if(wt(t,e),Nt(e),i&4){try{Pr(3,e,e.return),Is(3,e)}catch(X){Le(e,e.return,X)}try{Pr(5,e,e.return)}catch(X){Le(e,e.return,X)}}break;case 1:wt(t,e),Nt(e),i&512&&n!==null&&Vn(n,n.return);break;case 5:if(wt(t,e),Nt(e),i&512&&n!==null&&Vn(n,n.return),e.flags&32){var l=e.stateNode;try{er(l,"")}catch(X){Le(e,e.return,X)}}if(i&4&&(l=e.stateNode,l!=null)){var c=e.memoizedProps,p=n!==null?n.memoizedProps:c,g=e.type,x=e.updateQueue;if(e.updateQueue=null,x!==null)try{g==="input"&&c.type==="radio"&&c.name!=null&&Wa(l,c),_i(g,p);var N=_i(g,c);for(p=0;p<x.length;p+=2){var A=x[p],P=x[p+1];A==="style"?tl(l,P):A==="dangerouslySetInnerHTML"?Ga(l,P):A==="children"?er(l,P):ge(l,A,P,N)}switch(g){case"input":Si(l,c);break;case"textarea":Qa(l,c);break;case"select":var O=l._wrapperState.wasMultiple;l._wrapperState.wasMultiple=!!c.multiple;var U=c.value;U!=null?kn(l,!!c.multiple,U,!1):O!==!!c.multiple&&(c.defaultValue!=null?kn(l,!!c.multiple,c.defaultValue,!0):kn(l,!!c.multiple,c.multiple?[]:"",!1))}l[Cr]=c}catch(X){Le(e,e.return,X)}}break;case 6:if(wt(t,e),Nt(e),i&4){if(e.stateNode===null)throw Error(s(162));l=e.stateNode,c=e.memoizedProps;try{l.nodeValue=c}catch(X){Le(e,e.return,X)}}break;case 3:if(wt(t,e),Nt(e),i&4&&n!==null&&n.memoizedState.isDehydrated)try{fr(t.containerInfo)}catch(X){Le(e,e.return,X)}break;case 4:wt(t,e),Nt(e);break;case 13:wt(t,e),Nt(e),l=e.child,l.flags&8192&&(c=l.memoizedState!==null,l.stateNode.isHidden=c,!c||l.alternate!==null&&l.alternate.memoizedState!==null||(Go=Oe())),i&4&&vc(e);break;case 22:if(A=n!==null&&n.memoizedState!==null,e.mode&1?(Ze=(N=Ze)||A,wt(t,e),Ze=N):wt(t,e),Nt(e),i&8192){if(N=e.memoizedState!==null,(e.stateNode.isHidden=N)&&!A&&(e.mode&1)!==0)for(I=e,A=e.child;A!==null;){for(P=I=A;I!==null;){switch(O=I,U=O.child,O.tag){case 0:case 11:case 14:case 15:Pr(4,O,O.return);break;case 1:Vn(O,O.return);var b=O.stateNode;if(typeof b.componentWillUnmount=="function"){i=O,n=O.return;try{t=i,b.props=t.memoizedProps,b.state=t.memoizedState,b.componentWillUnmount()}catch(X){Le(i,n,X)}}break;case 5:Vn(O,O.return);break;case 22:if(O.memoizedState!==null){Cc(P);continue}}U!==null?(U.return=O,I=U):Cc(P)}A=A.sibling}e:for(A=null,P=e;;){if(P.tag===5){if(A===null){A=P;try{l=P.stateNode,N?(c=l.style,typeof c.setProperty=="function"?c.setProperty("display","none","important"):c.display="none"):(g=P.stateNode,x=P.memoizedProps.style,p=x!=null&&x.hasOwnProperty("display")?x.display:null,g.style.display=el("display",p))}catch(X){Le(e,e.return,X)}}}else if(P.tag===6){if(A===null)try{P.stateNode.nodeValue=N?"":P.memoizedProps}catch(X){Le(e,e.return,X)}}else if((P.tag!==22&&P.tag!==23||P.memoizedState===null||P===e)&&P.child!==null){P.child.return=P,P=P.child;continue}if(P===e)break e;for(;P.sibling===null;){if(P.return===null||P.return===e)break e;A===P&&(A=null),P=P.return}A===P&&(A=null),P.sibling.return=P.return,P=P.sibling}}break;case 19:wt(t,e),Nt(e),i&4&&vc(e);break;case 21:break;default:wt(t,e),Nt(e)}}function Nt(e){var t=e.flags;if(t&2){try{e:{for(var n=e.return;n!==null;){if(mc(n)){var i=n;break e}n=n.return}throw Error(s(160))}switch(i.tag){case 5:var l=i.stateNode;i.flags&32&&(er(l,""),i.flags&=-33);var c=gc(e);Qo(e,c,l);break;case 3:case 4:var p=i.stateNode.containerInfo,g=gc(e);qo(e,g,p);break;default:throw Error(s(161))}}catch(x){Le(e,e.return,x)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function bd(e,t,n){I=e,wc(e)}function wc(e,t,n){for(var i=(e.mode&1)!==0;I!==null;){var l=I,c=l.child;if(l.tag===22&&i){var p=l.memoizedState!==null||Us;if(!p){var g=l.alternate,x=g!==null&&g.memoizedState!==null||Ze;g=Us;var N=Ze;if(Us=p,(Ze=x)&&!N)for(I=l;I!==null;)p=I,x=p.child,p.tag===22&&p.memoizedState!==null?kc(l):x!==null?(x.return=p,I=x):kc(l);for(;c!==null;)I=c,wc(c),c=c.sibling;I=l,Us=g,Ze=N}Sc(e)}else(l.subtreeFlags&8772)!==0&&c!==null?(c.return=l,I=c):Sc(e)}}function Sc(e){for(;I!==null;){var t=I;if((t.flags&8772)!==0){var n=t.alternate;try{if((t.flags&8772)!==0)switch(t.tag){case 0:case 11:case 15:Ze||Is(5,t);break;case 1:var i=t.stateNode;if(t.flags&4&&!Ze)if(n===null)i.componentDidMount();else{var l=t.elementType===t.type?n.memoizedProps:vt(t.type,n.memoizedProps);i.componentDidUpdate(l,n.memoizedState,i.__reactInternalSnapshotBeforeUpdate)}var c=t.updateQueue;c!==null&&Cu(t,c,i);break;case 3:var p=t.updateQueue;if(p!==null){if(n=null,t.child!==null)switch(t.child.tag){case 5:n=t.child.stateNode;break;case 1:n=t.child.stateNode}Cu(t,p,n)}break;case 5:var g=t.stateNode;if(n===null&&t.flags&4){n=g;var x=t.memoizedProps;switch(t.type){case"button":case"input":case"select":case"textarea":x.autoFocus&&n.focus();break;case"img":x.src&&(n.src=x.src)}}break;case 6:break;case 4:break;case 12:break;case 13:if(t.memoizedState===null){var N=t.alternate;if(N!==null){var A=N.memoizedState;if(A!==null){var P=A.dehydrated;P!==null&&fr(P)}}}break;case 19:case 17:case 21:case 22:case 23:case 25:break;default:throw Error(s(163))}Ze||t.flags&512&&Ko(t)}catch(O){Le(t,t.return,O)}}if(t===e){I=null;break}if(n=t.sibling,n!==null){n.return=t.return,I=n;break}I=t.return}}function Cc(e){for(;I!==null;){var t=I;if(t===e){I=null;break}var n=t.sibling;if(n!==null){n.return=t.return,I=n;break}I=t.return}}function kc(e){for(;I!==null;){var t=I;try{switch(t.tag){case 0:case 11:case 15:var n=t.return;try{Is(4,t)}catch(x){Le(t,n,x)}break;case 1:var i=t.stateNode;if(typeof i.componentDidMount=="function"){var l=t.return;try{i.componentDidMount()}catch(x){Le(t,l,x)}}var c=t.return;try{Ko(t)}catch(x){Le(t,c,x)}break;case 5:var p=t.return;try{Ko(t)}catch(x){Le(t,p,x)}}}catch(x){Le(t,t.return,x)}if(t===e){I=null;break}var g=t.sibling;if(g!==null){g.return=t.return,I=g;break}I=t.return}}var $d=Math.ceil,bs=G.ReactCurrentDispatcher,Yo=G.ReactCurrentOwner,pt=G.ReactCurrentBatchConfig,fe=0,Be=null,Pe=null,be=0,at=0,Hn=Zt(0),Te=0,jr=null,mn=0,$s=0,Jo=0,Rr=null,et=null,Go=0,Zn=1/0,Bt=null,Xs=!1,ea=null,Jt=null,Vs=!1,Gt=null,Hs=0,Tr=0,ta=null,Zs=-1,Ws=0;function Ke(){return(fe&6)!==0?Oe():Zs!==-1?Zs:Zs=Oe()}function en(e){return(e.mode&1)===0?1:(fe&2)!==0&&be!==0?be&-be:Ed.transition!==null?(Ws===0&&(Ws=gl()),Ws):(e=xe,e!==0||(e=window.event,e=e===void 0?16:El(e.type)),e)}function St(e,t,n,i){if(50<Tr)throw Tr=0,ta=null,Error(s(185));or(e,n,i),((fe&2)===0||e!==Be)&&(e===Be&&((fe&2)===0&&($s|=n),Te===4&&tn(e,be)),tt(e,i),n===1&&fe===0&&(t.mode&1)===0&&(Zn=Oe()+500,Ss&&Kt()))}function tt(e,t){var n=e.callbackNode;Ep(e,t);var i=ns(e,e===Be?be:0);if(i===0)n!==null&&dl(n),e.callbackNode=null,e.callbackPriority=0;else if(t=i&-i,e.callbackPriority!==t){if(n!=null&&dl(n),t===1)e.tag===0?Fd(Ec.bind(null,e)):cu(Ec.bind(null,e)),wd(function(){(fe&6)===0&&Kt()}),n=null;else{switch(yl(i)){case 1:n=Pi;break;case 4:n=hl;break;case 16:n=Jr;break;case 536870912:n=ml;break;default:n=Jr}n=Pc(n,Fc.bind(null,e))}e.callbackPriority=t,e.callbackNode=n}}function Fc(e,t){if(Zs=-1,Ws=0,(fe&6)!==0)throw Error(s(327));var n=e.callbackNode;if(Wn()&&e.callbackNode!==n)return null;var i=ns(e,e===Be?be:0);if(i===0)return null;if((i&30)!==0||(i&e.expiredLanes)!==0||t)t=Ks(e,i);else{t=i;var l=fe;fe|=2;var c=Nc();(Be!==e||be!==t)&&(Bt=null,Zn=Oe()+500,yn(e,t));do try{Hd();break}catch(g){_c(e,g)}while(!0);xo(),bs.current=c,fe=l,Pe!==null?t=0:(Be=null,be=0,t=Te)}if(t!==0){if(t===2&&(l=ji(e),l!==0&&(i=l,t=na(e,l))),t===1)throw n=jr,yn(e,0),tn(e,i),tt(e,Oe()),n;if(t===6)tn(e,i);else{if(l=e.current.alternate,(i&30)===0&&!Xd(l)&&(t=Ks(e,i),t===2&&(c=ji(e),c!==0&&(i=c,t=na(e,c))),t===1))throw n=jr,yn(e,0),tn(e,i),tt(e,Oe()),n;switch(e.finishedWork=l,e.finishedLanes=i,t){case 0:case 1:throw Error(s(345));case 2:vn(e,et,Bt);break;case 3:if(tn(e,i),(i&130023424)===i&&(t=Go+500-Oe(),10<t)){if(ns(e,0)!==0)break;if(l=e.suspendedLanes,(l&i)!==i){Ke(),e.pingedLanes|=e.suspendedLanes&l;break}e.timeoutHandle=ao(vn.bind(null,e,et,Bt),t);break}vn(e,et,Bt);break;case 4:if(tn(e,i),(i&4194240)===i)break;for(t=e.eventTimes,l=-1;0<i;){var p=31-mt(i);c=1<<p,p=t[p],p>l&&(l=p),i&=~c}if(i=l,i=Oe()-i,i=(120>i?120:480>i?480:1080>i?1080:1920>i?1920:3e3>i?3e3:4320>i?4320:1960*$d(i/1960))-i,10<i){e.timeoutHandle=ao(vn.bind(null,e,et,Bt),i);break}vn(e,et,Bt);break;case 5:vn(e,et,Bt);break;default:throw Error(s(329))}}}return tt(e,Oe()),e.callbackNode===n?Fc.bind(null,e):null}function na(e,t){var n=Rr;return e.current.memoizedState.isDehydrated&&(yn(e,t).flags|=256),e=Ks(e,t),e!==2&&(t=et,et=n,t!==null&&ra(t)),e}function ra(e){et===null?et=e:et.push.apply(et,e)}function Xd(e){for(var t=e;;){if(t.flags&16384){var n=t.updateQueue;if(n!==null&&(n=n.stores,n!==null))for(var i=0;i<n.length;i++){var l=n[i],c=l.getSnapshot;l=l.value;try{if(!gt(c(),l))return!1}catch{return!1}}}if(n=t.child,t.subtreeFlags&16384&&n!==null)n.return=t,t=n;else{if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return!0;t=t.return}t.sibling.return=t.return,t=t.sibling}}return!0}function tn(e,t){for(t&=~Jo,t&=~$s,e.suspendedLanes|=t,e.pingedLanes&=~t,e=e.expirationTimes;0<t;){var n=31-mt(t),i=1<<n;e[n]=-1,t&=~i}}function Ec(e){if((fe&6)!==0)throw Error(s(327));Wn();var t=ns(e,0);if((t&1)===0)return tt(e,Oe()),null;var n=Ks(e,t);if(e.tag!==0&&n===2){var i=ji(e);i!==0&&(t=i,n=na(e,i))}if(n===1)throw n=jr,yn(e,0),tn(e,t),tt(e,Oe()),n;if(n===6)throw Error(s(345));return e.finishedWork=e.current.alternate,e.finishedLanes=t,vn(e,et,Bt),tt(e,Oe()),null}function sa(e,t){var n=fe;fe|=1;try{return e(t)}finally{fe=n,fe===0&&(Zn=Oe()+500,Ss&&Kt())}}function gn(e){Gt!==null&&Gt.tag===0&&(fe&6)===0&&Wn();var t=fe;fe|=1;var n=pt.transition,i=xe;try{if(pt.transition=null,xe=1,e)return e()}finally{xe=i,pt.transition=n,fe=t,(fe&6)===0&&Kt()}}function ia(){at=Hn.current,Fe(Hn)}function yn(e,t){e.finishedWork=null,e.finishedLanes=0;var n=e.timeoutHandle;if(n!==-1&&(e.timeoutHandle=-1,xd(n)),Pe!==null)for(n=Pe.return;n!==null;){var i=n;switch(ho(i),i.tag){case 1:i=i.type.childContextTypes,i!=null&&xs();break;case 3:$n(),Fe(Ye),Fe(Xe),No();break;case 5:Eo(i);break;case 4:$n();break;case 13:Fe(ze);break;case 19:Fe(ze);break;case 10:wo(i.type._context);break;case 22:case 23:ia()}n=n.return}if(Be=e,Pe=e=nn(e.current,null),be=at=t,Te=0,jr=null,Jo=$s=mn=0,et=Rr=null,pn!==null){for(t=0;t<pn.length;t++)if(n=pn[t],i=n.interleaved,i!==null){n.interleaved=null;var l=i.next,c=n.pending;if(c!==null){var p=c.next;c.next=l,i.next=p}n.pending=i}pn=null}return e}function _c(e,t){do{var n=Pe;try{if(xo(),Os.current=Rs,As){for(var i=De.memoizedState;i!==null;){var l=i.queue;l!==null&&(l.pending=null),i=i.next}As=!1}if(hn=0,Me=Re=De=null,zr=!1,Dr=0,Yo.current=null,n===null||n.return===null){Te=1,jr=t,Pe=null;break}e:{var c=e,p=n.return,g=n,x=t;if(t=be,g.flags|=32768,x!==null&&typeof x=="object"&&typeof x.then=="function"){var N=x,A=g,P=A.tag;if((A.mode&1)===0&&(P===0||P===11||P===15)){var O=A.alternate;O?(A.updateQueue=O.updateQueue,A.memoizedState=O.memoizedState,A.lanes=O.lanes):(A.updateQueue=null,A.memoizedState=null)}var U=Yu(p);if(U!==null){U.flags&=-257,Ju(U,p,g,c,t),U.mode&1&&Qu(c,N,t),t=U,x=N;var b=t.updateQueue;if(b===null){var X=new Set;X.add(x),t.updateQueue=X}else b.add(x);break e}else{if((t&1)===0){Qu(c,N,t),oa();break e}x=Error(s(426))}}else if(_e&&g.mode&1){var Ae=Yu(p);if(Ae!==null){(Ae.flags&65536)===0&&(Ae.flags|=256),Ju(Ae,p,g,c,t),yo(Xn(x,g));break e}}c=x=Xn(x,g),Te!==4&&(Te=2),Rr===null?Rr=[c]:Rr.push(c),c=p;do{switch(c.tag){case 3:c.flags|=65536,t&=-t,c.lanes|=t;var k=Ku(c,x,t);Su(c,k);break e;case 1:g=x;var w=c.type,_=c.stateNode;if((c.flags&128)===0&&(typeof w.getDerivedStateFromError=="function"||_!==null&&typeof _.componentDidCatch=="function"&&(Jt===null||!Jt.has(_)))){c.flags|=65536,t&=-t,c.lanes|=t;var j=qu(c,g,t);Su(c,j);break e}}c=c.return}while(c!==null)}Dc(n)}catch(H){t=H,Pe===n&&n!==null&&(Pe=n=n.return);continue}break}while(!0)}function Nc(){var e=bs.current;return bs.current=Rs,e===null?Rs:e}function oa(){(Te===0||Te===3||Te===2)&&(Te=4),Be===null||(mn&268435455)===0&&($s&268435455)===0||tn(Be,be)}function Ks(e,t){var n=fe;fe|=2;var i=Nc();(Be!==e||be!==t)&&(Bt=null,yn(e,t));do try{Vd();break}catch(l){_c(e,l)}while(!0);if(xo(),fe=n,bs.current=i,Pe!==null)throw Error(s(261));return Be=null,be=0,Te}function Vd(){for(;Pe!==null;)zc(Pe)}function Hd(){for(;Pe!==null&&!gp();)zc(Pe)}function zc(e){var t=Ac(e.alternate,e,at);e.memoizedProps=e.pendingProps,t===null?Dc(e):Pe=t,Yo.current=null}function Dc(e){var t=e;do{var n=t.alternate;if(e=t.return,(t.flags&32768)===0){if(n=Md(n,t,at),n!==null){Pe=n;return}}else{if(n=Bd(n,t),n!==null){n.flags&=32767,Pe=n;return}if(e!==null)e.flags|=32768,e.subtreeFlags=0,e.deletions=null;else{Te=6,Pe=null;return}}if(t=t.sibling,t!==null){Pe=t;return}Pe=t=e}while(t!==null);Te===0&&(Te=5)}function vn(e,t,n){var i=xe,l=pt.transition;try{pt.transition=null,xe=1,Zd(e,t,n,i)}finally{pt.transition=l,xe=i}return null}function Zd(e,t,n,i){do Wn();while(Gt!==null);if((fe&6)!==0)throw Error(s(327));n=e.finishedWork;var l=e.finishedLanes;if(n===null)return null;if(e.finishedWork=null,e.finishedLanes=0,n===e.current)throw Error(s(177));e.callbackNode=null,e.callbackPriority=0;var c=n.lanes|n.childLanes;if(_p(e,c),e===Be&&(Pe=Be=null,be=0),(n.subtreeFlags&2064)===0&&(n.flags&2064)===0||Vs||(Vs=!0,Pc(Jr,function(){return Wn(),null})),c=(n.flags&15990)!==0,(n.subtreeFlags&15990)!==0||c){c=pt.transition,pt.transition=null;var p=xe;xe=1;var g=fe;fe|=4,Yo.current=null,Id(e,n),xc(n,e),pd(io),is=!!so,io=so=null,e.current=n,bd(n),yp(),fe=g,xe=p,pt.transition=c}else e.current=n;if(Vs&&(Vs=!1,Gt=e,Hs=l),c=e.pendingLanes,c===0&&(Jt=null),wp(n.stateNode),tt(e,Oe()),t!==null)for(i=e.onRecoverableError,n=0;n<t.length;n++)l=t[n],i(l.value,{componentStack:l.stack,digest:l.digest});if(Xs)throw Xs=!1,e=ea,ea=null,e;return(Hs&1)!==0&&e.tag!==0&&Wn(),c=e.pendingLanes,(c&1)!==0?e===ta?Tr++:(Tr=0,ta=e):Tr=0,Kt(),null}function Wn(){if(Gt!==null){var e=yl(Hs),t=pt.transition,n=xe;try{if(pt.transition=null,xe=16>e?16:e,Gt===null)var i=!1;else{if(e=Gt,Gt=null,Hs=0,(fe&6)!==0)throw Error(s(331));var l=fe;for(fe|=4,I=e.current;I!==null;){var c=I,p=c.child;if((I.flags&16)!==0){var g=c.deletions;if(g!==null){for(var x=0;x<g.length;x++){var N=g[x];for(I=N;I!==null;){var A=I;switch(A.tag){case 0:case 11:case 15:Pr(8,A,c)}var P=A.child;if(P!==null)P.return=A,I=P;else for(;I!==null;){A=I;var O=A.sibling,U=A.return;if(hc(A),A===N){I=null;break}if(O!==null){O.return=U,I=O;break}I=U}}}var b=c.alternate;if(b!==null){var X=b.child;if(X!==null){b.child=null;do{var Ae=X.sibling;X.sibling=null,X=Ae}while(X!==null)}}I=c}}if((c.subtreeFlags&2064)!==0&&p!==null)p.return=c,I=p;else e:for(;I!==null;){if(c=I,(c.flags&2048)!==0)switch(c.tag){case 0:case 11:case 15:Pr(9,c,c.return)}var k=c.sibling;if(k!==null){k.return=c.return,I=k;break e}I=c.return}}var w=e.current;for(I=w;I!==null;){p=I;var _=p.child;if((p.subtreeFlags&2064)!==0&&_!==null)_.return=p,I=_;else e:for(p=w;I!==null;){if(g=I,(g.flags&2048)!==0)try{switch(g.tag){case 0:case 11:case 15:Is(9,g)}}catch(H){Le(g,g.return,H)}if(g===p){I=null;break e}var j=g.sibling;if(j!==null){j.return=g.return,I=j;break e}I=g.return}}if(fe=l,Kt(),kt&&typeof kt.onPostCommitFiberRoot=="function")try{kt.onPostCommitFiberRoot(Gr,e)}catch{}i=!0}return i}finally{xe=n,pt.transition=t}}return!1}function Lc(e,t,n){t=Xn(n,t),t=Ku(e,t,1),e=Qt(e,t,1),t=Ke(),e!==null&&(or(e,1,t),tt(e,t))}function Le(e,t,n){if(e.tag===3)Lc(e,e,n);else for(;t!==null;){if(t.tag===3){Lc(t,e,n);break}else if(t.tag===1){var i=t.stateNode;if(typeof t.type.getDerivedStateFromError=="function"||typeof i.componentDidCatch=="function"&&(Jt===null||!Jt.has(i))){e=Xn(n,e),e=qu(t,e,1),t=Qt(t,e,1),e=Ke(),t!==null&&(or(t,1,e),tt(t,e));break}}t=t.return}}function Wd(e,t,n){var i=e.pingCache;i!==null&&i.delete(t),t=Ke(),e.pingedLanes|=e.suspendedLanes&n,Be===e&&(be&n)===n&&(Te===4||Te===3&&(be&130023424)===be&&500>Oe()-Go?yn(e,0):Jo|=n),tt(e,t)}function Oc(e,t){t===0&&((e.mode&1)===0?t=1:(t=ts,ts<<=1,(ts&130023424)===0&&(ts=4194304)));var n=Ke();e=Rt(e,t),e!==null&&(or(e,t,n),tt(e,n))}function Kd(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),Oc(e,n)}function qd(e,t){var n=0;switch(e.tag){case 13:var i=e.stateNode,l=e.memoizedState;l!==null&&(n=l.retryLane);break;case 19:i=e.stateNode;break;default:throw Error(s(314))}i!==null&&i.delete(t),Oc(e,n)}var Ac;Ac=function(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps||Ye.current)Ge=!0;else{if((e.lanes&n)===0&&(t.flags&128)===0)return Ge=!1,Td(e,t,n);Ge=(e.flags&131072)!==0}else Ge=!1,_e&&(t.flags&1048576)!==0&&fu(t,ks,t.index);switch(t.lanes=0,t.tag){case 2:var i=t.type;Bs(e,t),e=t.pendingProps;var l=Rn(t,Xe.current);bn(t,n),l=Lo(null,t,i,e,l,n);var c=Oo();return t.flags|=1,typeof l=="object"&&l!==null&&typeof l.render=="function"&&l.$$typeof===void 0?(t.tag=1,t.memoizedState=null,t.updateQueue=null,Je(i)?(c=!0,ws(t)):c=!1,t.memoizedState=l.state!==null&&l.state!==void 0?l.state:null,ko(t),l.updater=Ts,t.stateNode=l,l._reactInternals=t,Mo(t,i,e,n),t=bo(null,t,i,!0,c,n)):(t.tag=0,_e&&c&&po(t),We(null,t,l,n),t=t.child),t;case 16:i=t.elementType;e:{switch(Bs(e,t),e=t.pendingProps,l=i._init,i=l(i._payload),t.type=i,l=t.tag=Yd(i),e=vt(i,e),l){case 0:t=Io(null,t,i,e,n);break e;case 1:t=sc(null,t,i,e,n);break e;case 11:t=Gu(null,t,i,e,n);break e;case 14:t=ec(null,t,i,vt(i.type,e),n);break e}throw Error(s(306,i,""))}return t;case 0:return i=t.type,l=t.pendingProps,l=t.elementType===i?l:vt(i,l),Io(e,t,i,l,n);case 1:return i=t.type,l=t.pendingProps,l=t.elementType===i?l:vt(i,l),sc(e,t,i,l,n);case 3:e:{if(ic(t),e===null)throw Error(s(387));i=t.pendingProps,c=t.memoizedState,l=c.element,wu(e,t),Ds(t,i,null,n);var p=t.memoizedState;if(i=p.element,c.isDehydrated)if(c={element:i,isDehydrated:!1,cache:p.cache,pendingSuspenseBoundaries:p.pendingSuspenseBoundaries,transitions:p.transitions},t.updateQueue.baseState=c,t.memoizedState=c,t.flags&256){l=Xn(Error(s(423)),t),t=oc(e,t,i,n,l);break e}else if(i!==l){l=Xn(Error(s(424)),t),t=oc(e,t,i,n,l);break e}else for(ot=Ht(t.stateNode.containerInfo.firstChild),it=t,_e=!0,yt=null,n=vu(t,null,i,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if(Bn(),i===l){t=Mt(e,t,n);break e}We(e,t,i,n)}t=t.child}return t;case 5:return ku(t),e===null&&go(t),i=t.type,l=t.pendingProps,c=e!==null?e.memoizedProps:null,p=l.children,oo(i,l)?p=null:c!==null&&oo(i,c)&&(t.flags|=32),rc(e,t),We(e,t,p,n),t.child;case 6:return e===null&&go(t),null;case 13:return ac(e,t,n);case 4:return Fo(t,t.stateNode.containerInfo),i=t.pendingProps,e===null?t.child=Un(t,null,i,n):We(e,t,i,n),t.child;case 11:return i=t.type,l=t.pendingProps,l=t.elementType===i?l:vt(i,l),Gu(e,t,i,l,n);case 7:return We(e,t,t.pendingProps,n),t.child;case 8:return We(e,t,t.pendingProps.children,n),t.child;case 12:return We(e,t,t.pendingProps.children,n),t.child;case 10:e:{if(i=t.type._context,l=t.pendingProps,c=t.memoizedProps,p=l.value,Ce(_s,i._currentValue),i._currentValue=p,c!==null)if(gt(c.value,p)){if(c.children===l.children&&!Ye.current){t=Mt(e,t,n);break e}}else for(c=t.child,c!==null&&(c.return=t);c!==null;){var g=c.dependencies;if(g!==null){p=c.child;for(var x=g.firstContext;x!==null;){if(x.context===i){if(c.tag===1){x=Tt(-1,n&-n),x.tag=2;var N=c.updateQueue;if(N!==null){N=N.shared;var A=N.pending;A===null?x.next=x:(x.next=A.next,A.next=x),N.pending=x}}c.lanes|=n,x=c.alternate,x!==null&&(x.lanes|=n),So(c.return,n,t),g.lanes|=n;break}x=x.next}}else if(c.tag===10)p=c.type===t.type?null:c.child;else if(c.tag===18){if(p=c.return,p===null)throw Error(s(341));p.lanes|=n,g=p.alternate,g!==null&&(g.lanes|=n),So(p,n,t),p=c.sibling}else p=c.child;if(p!==null)p.return=c;else for(p=c;p!==null;){if(p===t){p=null;break}if(c=p.sibling,c!==null){c.return=p.return,p=c;break}p=p.return}c=p}We(e,t,l.children,n),t=t.child}return t;case 9:return l=t.type,i=t.pendingProps.children,bn(t,n),l=ct(l),i=i(l),t.flags|=1,We(e,t,i,n),t.child;case 14:return i=t.type,l=vt(i,t.pendingProps),l=vt(i.type,l),ec(e,t,i,l,n);case 15:return tc(e,t,t.type,t.pendingProps,n);case 17:return i=t.type,l=t.pendingProps,l=t.elementType===i?l:vt(i,l),Bs(e,t),t.tag=1,Je(i)?(e=!0,ws(t)):e=!1,bn(t,n),Zu(t,i,l),Mo(t,i,l,n),bo(null,t,i,!0,e,n);case 19:return uc(e,t,n);case 22:return nc(e,t,n)}throw Error(s(156,t.tag))};function Pc(e,t){return pl(e,t)}function Qd(e,t,n,i){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=i,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function dt(e,t,n,i){return new Qd(e,t,n,i)}function aa(e){return e=e.prototype,!(!e||!e.isReactComponent)}function Yd(e){if(typeof e=="function")return aa(e)?1:0;if(e!=null){if(e=e.$$typeof,e===te)return 11;if(e===ue)return 14}return 2}function nn(e,t){var n=e.alternate;return n===null?(n=dt(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 qs(e,t,n,i,l,c){var p=2;if(i=e,typeof e=="function")aa(e)&&(p=1);else if(typeof e=="string")p=5;else e:switch(e){case le:return xn(n.children,l,c,t);case Ne:p=8,l|=8;break;case ye:return e=dt(12,n,t,l|2),e.elementType=ye,e.lanes=c,e;case W:return e=dt(13,n,t,l),e.elementType=W,e.lanes=c,e;case Y:return e=dt(19,n,t,l),e.elementType=Y,e.lanes=c,e;case se:return Qs(n,l,c,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case pe:p=10;break e;case Qe:p=9;break e;case te:p=11;break e;case ue:p=14;break e;case de:p=16,i=null;break e}throw Error(s(130,e==null?e:typeof e,""))}return t=dt(p,n,t,l),t.elementType=e,t.type=i,t.lanes=c,t}function xn(e,t,n,i){return e=dt(7,e,i,t),e.lanes=n,e}function Qs(e,t,n,i){return e=dt(22,e,i,t),e.elementType=se,e.lanes=n,e.stateNode={isHidden:!1},e}function la(e,t,n){return e=dt(6,e,null,t),e.lanes=n,e}function ua(e,t,n){return t=dt(4,e.children!==null?e.children:[],e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function Jd(e,t,n,i,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=Ri(0),this.expirationTimes=Ri(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Ri(0),this.identifierPrefix=i,this.onRecoverableError=l,this.mutableSourceEagerHydrationData=null}function ca(e,t,n,i,l,c,p,g,x){return e=new Jd(e,t,n,g,x),t===1?(t=1,c===!0&&(t|=8)):t=0,c=dt(3,null,null,t),e.current=c,c.stateNode=e,c.memoizedState={element:i,isDehydrated:n,cache:null,transitions:null,pendingSuspenseBoundaries:null},ko(c),e}function Gd(e,t,n){var i=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:Se,key:i==null?null:""+i,children:e,containerInfo:t,implementation:n}}function jc(e){if(!e)return Wt;e=e._reactInternals;e:{if(an(e)!==e||e.tag!==1)throw Error(s(170));var t=e;do{switch(t.tag){case 3:t=t.stateNode.context;break e;case 1:if(Je(t.type)){t=t.stateNode.__reactInternalMemoizedMergedChildContext;break e}}t=t.return}while(t!==null);throw Error(s(171))}if(e.tag===1){var n=e.type;if(Je(n))return lu(e,n,t)}return t}function Rc(e,t,n,i,l,c,p,g,x){return e=ca(n,i,!0,e,l,c,p,g,x),e.context=jc(null),n=e.current,i=Ke(),l=en(n),c=Tt(i,l),c.callback=t??null,Qt(n,c,l),e.current.lanes=l,or(e,l,i),tt(e,i),e}function Ys(e,t,n,i){var l=t.current,c=Ke(),p=en(l);return n=jc(n),t.context===null?t.context=n:t.pendingContext=n,t=Tt(c,p),t.payload={element:e},i=i===void 0?null:i,i!==null&&(t.callback=i),e=Qt(l,t,p),e!==null&&(St(e,l,p,c),zs(e,l,p)),p}function Js(e){if(e=e.current,!e.child)return null;switch(e.child.tag){case 5:return e.child.stateNode;default:return e.child.stateNode}}function Tc(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var n=e.retryLane;e.retryLane=n!==0&&n<t?n:t}}function fa(e,t){Tc(e,t),(e=e.alternate)&&Tc(e,t)}function eh(){return null}var Mc=typeof reportError=="function"?reportError:function(e){console.error(e)};function pa(e){this._internalRoot=e}Gs.prototype.render=pa.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(s(409));Ys(e,t,null,null)},Gs.prototype.unmount=pa.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;gn(function(){Ys(null,e,null,null)}),t[Ot]=null}};function Gs(e){this._internalRoot=e}Gs.prototype.unstable_scheduleHydration=function(e){if(e){var t=wl();e={blockedOn:null,target:e,priority:t};for(var n=0;n<$t.length&&t!==0&&t<$t[n].priority;n++);$t.splice(n,0,e),n===0&&kl(e)}};function da(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function ei(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11&&(e.nodeType!==8||e.nodeValue!==" react-mount-point-unstable "))}function Bc(){}function th(e,t,n,i,l){if(l){if(typeof i=="function"){var c=i;i=function(){var N=Js(p);c.call(N)}}var p=Rc(t,i,e,0,null,!1,!1,"",Bc);return e._reactRootContainer=p,e[Ot]=p.current,wr(e.nodeType===8?e.parentNode:e),gn(),p}for(;l=e.lastChild;)e.removeChild(l);if(typeof i=="function"){var g=i;i=function(){var N=Js(x);g.call(N)}}var x=ca(e,0,!1,null,null,!1,!1,"",Bc);return e._reactRootContainer=x,e[Ot]=x.current,wr(e.nodeType===8?e.parentNode:e),gn(function(){Ys(t,x,n,i)}),x}function ti(e,t,n,i,l){var c=n._reactRootContainer;if(c){var p=c;if(typeof l=="function"){var g=l;l=function(){var x=Js(p);g.call(x)}}Ys(t,p,e,l)}else p=th(n,t,e,l,i);return Js(p)}vl=function(e){switch(e.tag){case 3:var t=e.stateNode;if(t.current.memoizedState.isDehydrated){var n=ir(t.pendingLanes);n!==0&&(Ti(t,n|1),tt(t,Oe()),(fe&6)===0&&(Zn=Oe()+500,Kt()))}break;case 13:gn(function(){var i=Rt(e,1);if(i!==null){var l=Ke();St(i,e,1,l)}}),fa(e,1)}},Mi=function(e){if(e.tag===13){var t=Rt(e,134217728);if(t!==null){var n=Ke();St(t,e,134217728,n)}fa(e,134217728)}},xl=function(e){if(e.tag===13){var t=en(e),n=Rt(e,t);if(n!==null){var i=Ke();St(n,e,t,i)}fa(e,t)}},wl=function(){return xe},Sl=function(e,t){var n=xe;try{return xe=e,t()}finally{xe=n}},Di=function(e,t,n){switch(t){case"input":if(Si(e,n),t=n.name,n.type==="radio"&&t!=null){for(n=e;n.parentNode;)n=n.parentNode;for(n=n.querySelectorAll("input[name="+JSON.stringify(""+t)+'][type="radio"]'),t=0;t<n.length;t++){var i=n[t];if(i!==e&&i.form===e.form){var l=vs(i);if(!l)throw Error(s(90));Ha(i),Si(i,l)}}}break;case"textarea":Qa(e,n);break;case"select":t=n.value,t!=null&&kn(e,!!n.multiple,t,!1)}},il=sa,ol=gn;var nh={usingClientEntryPoint:!1,Events:[kr,Pn,vs,rl,sl,sa]},Mr={findFiberByHostInstance:ln,bundleType:0,version:"18.3.1",rendererPackageName:"react-dom"},rh={bundleType:Mr.bundleType,version:Mr.version,rendererPackageName:Mr.rendererPackageName,rendererConfig:Mr.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setErrorHandler:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:G.ReactCurrentDispatcher,findHostInstanceByFiber:function(e){return e=cl(e),e===null?null:e.stateNode},findFiberByHostInstance:Mr.findFiberByHostInstance||eh,findHostInstancesForRefresh:null,scheduleRefresh:null,scheduleRoot:null,setRefreshHandler:null,getCurrentFiber:null,reconcilerVersion:"18.3.1-next-f1338f8080-20240426"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var ni=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!ni.isDisabled&&ni.supportsFiber)try{Gr=ni.inject(rh),kt=ni}catch{}}return nt.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=nh,nt.createPortal=function(e,t){var n=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!da(t))throw Error(s(200));return Gd(e,t,null,n)},nt.createRoot=function(e,t){if(!da(e))throw Error(s(299));var n=!1,i="",l=Mc;return t!=null&&(t.unstable_strictMode===!0&&(n=!0),t.identifierPrefix!==void 0&&(i=t.identifierPrefix),t.onRecoverableError!==void 0&&(l=t.onRecoverableError)),t=ca(e,1,!1,null,null,n,!1,i,l),e[Ot]=t.current,wr(e.nodeType===8?e.parentNode:e),new pa(t)},nt.findDOMNode=function(e){if(e==null)return null;if(e.nodeType===1)return e;var t=e._reactInternals;if(t===void 0)throw typeof e.render=="function"?Error(s(188)):(e=Object.keys(e).join(","),Error(s(268,e)));return e=cl(t),e=e===null?null:e.stateNode,e},nt.flushSync=function(e){return gn(e)},nt.hydrate=function(e,t,n){if(!ei(t))throw Error(s(200));return ti(null,e,t,!0,n)},nt.hydrateRoot=function(e,t,n){if(!da(e))throw Error(s(405));var i=n!=null&&n.hydratedSources||null,l=!1,c="",p=Mc;if(n!=null&&(n.unstable_strictMode===!0&&(l=!0),n.identifierPrefix!==void 0&&(c=n.identifierPrefix),n.onRecoverableError!==void 0&&(p=n.onRecoverableError)),t=Rc(t,null,e,1,n??null,l,!1,c,p),e[Ot]=t.current,wr(e),i)for(e=0;e<i.length;e++)n=i[e],l=n._getVersion,l=l(n._source),t.mutableSourceEagerHydrationData==null?t.mutableSourceEagerHydrationData=[n,l]:t.mutableSourceEagerHydrationData.push(n,l);return new Gs(t)},nt.render=function(e,t,n){if(!ei(t))throw Error(s(200));return ti(null,e,t,!1,n)},nt.unmountComponentAtNode=function(e){if(!ei(e))throw Error(s(40));return e._reactRootContainer?(gn(function(){ti(null,null,e,!1,function(){e._reactRootContainer=null,e[Ot]=null})}),!0):!1},nt.unstable_batchedUpdates=sa,nt.unstable_renderSubtreeIntoContainer=function(e,t,n,i){if(!ei(n))throw Error(s(200));if(e==null||e._reactInternals===void 0)throw Error(s(38));return ti(e,t,n,!1,i)},nt.version="18.3.1-next-f1338f8080-20240426",nt}var Zc;function ph(){if(Zc)return ga.exports;Zc=1;function a(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(a)}catch(r){console.error(r)}}return a(),ga.exports=fh(),ga.exports}var Wc;function dh(){if(Wc)return si;Wc=1;var a=ph();return si.createRoot=a.createRoot,si.hydrateRoot=a.hydrateRoot,si}var hh=dh();const Kc=a=>{let r;const s=new Set,o=(y,F)=>{const v=typeof y=="function"?y(r):y;if(!Object.is(v,r)){const D=r;r=F??(typeof v!="object"||v===null)?v:Object.assign({},r,v),s.forEach(z=>z(r,D))}},u=()=>r,h={setState:o,getState:u,getInitialState:()=>m,subscribe:y=>(s.add(y),()=>s.delete(y))},m=r=a(o,u,h);return h},mh=(a=>a?Kc(a):Kc),gh=a=>a;function yh(a,r=gh){const s=ri.useSyncExternalStore(a.subscribe,ri.useCallback(()=>r(a.getState()),[a,r]),ri.useCallback(()=>r(a.getInitialState()),[a,r]));return ri.useDebugValue(s),s}const qc=a=>{const r=mh(a),s=o=>yh(r,o);return Object.assign(s,r),s},vh=(a=>a?qc(a):qc),Pf=vh(a=>({sessions:[],currentSessionId:null,messages:[],isLoading:!1,setSessions:r=>a({sessions:r}),removeSession:r=>a(s=>({sessions:s.sessions.filter(o=>o.id!==r)})),setCurrentSessionId:r=>a({currentSessionId:r}),setMessages:r=>a({messages:r}),addMessage:r=>a(s=>({messages:[...s.messages,r]})),setLoading:r=>a({isLoading:r})}));/**
|
|
41
|
+
* @license lucide-react v0.511.0 - ISC
|
|
42
|
+
*
|
|
43
|
+
* This source code is licensed under the ISC license.
|
|
44
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
45
|
+
*/const xh=a=>a.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),wh=a=>a.replace(/^([A-Z])|[\s-_]+(\w)/g,(r,s,o)=>o?o.toUpperCase():s.toLowerCase()),Qc=a=>{const r=wh(a);return r.charAt(0).toUpperCase()+r.slice(1)},jf=(...a)=>a.filter((r,s,o)=>!!r&&r.trim()!==""&&o.indexOf(r)===s).join(" ").trim(),Sh=a=>{for(const r in a)if(r.startsWith("aria-")||r==="role"||r==="title")return!0};/**
|
|
46
|
+
* @license lucide-react v0.511.0 - ISC
|
|
47
|
+
*
|
|
48
|
+
* This source code is licensed under the ISC license.
|
|
49
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
50
|
+
*/var Ch={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"};/**
|
|
51
|
+
* @license lucide-react v0.511.0 - ISC
|
|
52
|
+
*
|
|
53
|
+
* This source code is licensed under the ISC license.
|
|
54
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
55
|
+
*/const kh=ne.forwardRef(({color:a="currentColor",size:r=24,strokeWidth:s=2,absoluteStrokeWidth:o,className:u="",children:f,iconNode:d,...h},m)=>ne.createElement("svg",{ref:m,...Ch,width:r,height:r,stroke:a,strokeWidth:o?Number(s)*24/Number(r):s,className:jf("lucide",u),...!f&&!Sh(h)&&{"aria-hidden":"true"},...h},[...d.map(([y,F])=>ne.createElement(y,F)),...Array.isArray(f)?f:[f]]));/**
|
|
56
|
+
* @license lucide-react v0.511.0 - ISC
|
|
57
|
+
*
|
|
58
|
+
* This source code is licensed under the ISC license.
|
|
59
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
60
|
+
*/const $e=(a,r)=>{const s=ne.forwardRef(({className:o,...u},f)=>ne.createElement(kh,{ref:f,iconNode:r,className:jf(`lucide-${xh(Qc(a))}`,`lucide-${a}`,o),...u}));return s.displayName=Qc(a),s};/**
|
|
61
|
+
* @license lucide-react v0.511.0 - ISC
|
|
62
|
+
*
|
|
63
|
+
* This source code is licensed under the ISC license.
|
|
64
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
65
|
+
*/const Fh=[["path",{d:"m5 12 7-7 7 7",key:"hav0vg"}],["path",{d:"M12 19V5",key:"x0mq9r"}]],Eh=$e("arrow-up",Fh);/**
|
|
66
|
+
* @license lucide-react v0.511.0 - ISC
|
|
67
|
+
*
|
|
68
|
+
* This source code is licensed under the ISC license.
|
|
69
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
70
|
+
*/const _h=[["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"}]],Yc=$e("bot",_h);/**
|
|
71
|
+
* @license lucide-react v0.511.0 - ISC
|
|
72
|
+
*
|
|
73
|
+
* This source code is licensed under the ISC license.
|
|
74
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
75
|
+
*/const Nh=[["path",{d:"M12 5a3 3 0 1 0-5.997.125 4 4 0 0 0-2.526 5.77 4 4 0 0 0 .556 6.588A4 4 0 1 0 12 18Z",key:"l5xja"}],["path",{d:"M12 5a3 3 0 1 1 5.997.125 4 4 0 0 1 2.526 5.77 4 4 0 0 1-.556 6.588A4 4 0 1 1 12 18Z",key:"ep3f8r"}],["path",{d:"M15 13a4.5 4.5 0 0 1-3-4 4.5 4.5 0 0 1-3 4",key:"1p4c4q"}],["path",{d:"M17.599 6.5a3 3 0 0 0 .399-1.375",key:"tmeiqw"}],["path",{d:"M6.003 5.125A3 3 0 0 0 6.401 6.5",key:"105sqy"}],["path",{d:"M3.477 10.896a4 4 0 0 1 .585-.396",key:"ql3yin"}],["path",{d:"M19.938 10.5a4 4 0 0 1 .585.396",key:"1qfode"}],["path",{d:"M6 18a4 4 0 0 1-1.967-.516",key:"2e4loj"}],["path",{d:"M19.967 17.484A4 4 0 0 1 18 18",key:"159ez6"}]],zh=$e("brain",Nh);/**
|
|
76
|
+
* @license lucide-react v0.511.0 - ISC
|
|
77
|
+
*
|
|
78
|
+
* This source code is licensed under the ISC license.
|
|
79
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
80
|
+
*/const Dh=[["path",{d:"M8 2v4",key:"1cmpym"}],["path",{d:"M16 2v4",key:"4m81vk"}],["rect",{width:"18",height:"18",x:"3",y:"4",rx:"2",key:"1hopcy"}],["path",{d:"M3 10h18",key:"8toen8"}]],Lh=$e("calendar",Dh);/**
|
|
81
|
+
* @license lucide-react v0.511.0 - ISC
|
|
82
|
+
*
|
|
83
|
+
* This source code is licensed under the ISC license.
|
|
84
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
85
|
+
*/const Oh=[["path",{d:"m6 14 1.5-2.9A2 2 0 0 1 9.24 10H20a2 2 0 0 1 1.94 2.5l-1.54 6a2 2 0 0 1-1.95 1.5H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H18a2 2 0 0 1 2 2v2",key:"usdka0"}]],Jc=$e("folder-open",Oh);/**
|
|
86
|
+
* @license lucide-react v0.511.0 - ISC
|
|
87
|
+
*
|
|
88
|
+
* This source code is licensed under the ISC license.
|
|
89
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
90
|
+
*/const Ah=[["path",{d:"M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z",key:"1kt360"}]],Ph=$e("folder",Ah);/**
|
|
91
|
+
* @license lucide-react v0.511.0 - ISC
|
|
92
|
+
*
|
|
93
|
+
* This source code is licensed under the ISC license.
|
|
94
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
95
|
+
*/const jh=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 2a14.5 14.5 0 0 0 0 20 14.5 14.5 0 0 0 0-20",key:"13o1zl"}],["path",{d:"M2 12h20",key:"9i4pu4"}]],Rh=$e("globe",jh);/**
|
|
96
|
+
* @license lucide-react v0.511.0 - ISC
|
|
97
|
+
*
|
|
98
|
+
* This source code is licensed under the ISC license.
|
|
99
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
100
|
+
*/const Th=[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]],Mh=$e("loader-circle",Th);/**
|
|
101
|
+
* @license lucide-react v0.511.0 - ISC
|
|
102
|
+
*
|
|
103
|
+
* This source code is licensed under the ISC license.
|
|
104
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
105
|
+
*/const Bh=[["path",{d:"M21 15a2 2 0 0 1-2 2H7l-4 4V5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2z",key:"1lielz"}]],Uh=$e("message-square",Bh);/**
|
|
106
|
+
* @license lucide-react v0.511.0 - ISC
|
|
107
|
+
*
|
|
108
|
+
* This source code is licensed under the ISC license.
|
|
109
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
110
|
+
*/const Ih=[["polygon",{points:"6 3 20 12 6 21 6 3",key:"1oa8hb"}]],bh=$e("play",Ih);/**
|
|
111
|
+
* @license lucide-react v0.511.0 - ISC
|
|
112
|
+
*
|
|
113
|
+
* This source code is licensed under the ISC license.
|
|
114
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
115
|
+
*/const $h=[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]],Xh=$e("plus",$h);/**
|
|
116
|
+
* @license lucide-react v0.511.0 - ISC
|
|
117
|
+
*
|
|
118
|
+
* This source code is licensed under the ISC license.
|
|
119
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
120
|
+
*/const Vh=[["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"}]],Hh=$e("save",Vh);/**
|
|
121
|
+
* @license lucide-react v0.511.0 - ISC
|
|
122
|
+
*
|
|
123
|
+
* This source code is licensed under the ISC license.
|
|
124
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
125
|
+
*/const Zh=[["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"}]],Wh=$e("send",Zh);/**
|
|
126
|
+
* @license lucide-react v0.511.0 - ISC
|
|
127
|
+
*
|
|
128
|
+
* This source code is licensed under the ISC license.
|
|
129
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
130
|
+
*/const Kh=[["path",{d:"M12.22 2h-.44a2 2 0 0 0-2 2v.18a2 2 0 0 1-1 1.73l-.43.25a2 2 0 0 1-2 0l-.15-.08a2 2 0 0 0-2.73.73l-.22.38a2 2 0 0 0 .73 2.73l.15.1a2 2 0 0 1 1 1.72v.51a2 2 0 0 1-1 1.74l-.15.09a2 2 0 0 0-.73 2.73l.22.38a2 2 0 0 0 2.73.73l.15-.08a2 2 0 0 1 2 0l.43.25a2 2 0 0 1 1 1.73V20a2 2 0 0 0 2 2h.44a2 2 0 0 0 2-2v-.18a2 2 0 0 1 1-1.73l.43-.25a2 2 0 0 1 2 0l.15.08a2 2 0 0 0 2.73-.73l.22-.39a2 2 0 0 0-.73-2.73l-.15-.08a2 2 0 0 1-1-1.74v-.5a2 2 0 0 1 1-1.74l.15-.09a2 2 0 0 0 .73-2.73l-.22-.38a2 2 0 0 0-2.73-.73l-.15.08a2 2 0 0 1-2 0l-.43-.25a2 2 0 0 1-1-1.73V4a2 2 0 0 0-2-2z",key:"1qme2f"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]],Rf=$e("settings",Kh);/**
|
|
131
|
+
* @license lucide-react v0.511.0 - ISC
|
|
132
|
+
*
|
|
133
|
+
* This source code is licensed under the ISC license.
|
|
134
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
135
|
+
*/const qh=[["path",{d:"M3 6h18",key:"d0wm0j"}],["path",{d:"M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6",key:"4alrt4"}],["path",{d:"M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2",key:"v07s0e"}],["line",{x1:"10",x2:"10",y1:"11",y2:"17",key:"1uufr5"}],["line",{x1:"14",x2:"14",y1:"11",y2:"17",key:"xtxkd"}]],Qh=$e("trash-2",qh);/**
|
|
136
|
+
* @license lucide-react v0.511.0 - ISC
|
|
137
|
+
*
|
|
138
|
+
* This source code is licensed under the ISC license.
|
|
139
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
140
|
+
*/const Yh=[["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"}]],Jh=$e("user",Yh);/**
|
|
141
|
+
* @license lucide-react v0.511.0 - ISC
|
|
142
|
+
*
|
|
143
|
+
* This source code is licensed under the ISC license.
|
|
144
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
145
|
+
*/const Gh=[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]],Gc=$e("x",Gh),ee=a=>typeof a=="string",Ur=()=>{let a,r;const s=new Promise((o,u)=>{a=o,r=u});return s.resolve=a,s.reject=r,s},ef=a=>a==null?"":""+a,e2=(a,r,s)=>{a.forEach(o=>{r[o]&&(s[o]=r[o])})},t2=/###/g,tf=a=>a&&a.indexOf("###")>-1?a.replace(t2,"."):a,nf=a=>!a||ee(a),$r=(a,r,s)=>{const o=ee(r)?r.split("."):r;let u=0;for(;u<o.length-1;){if(nf(a))return{};const f=tf(o[u]);!a[f]&&s&&(a[f]=new s),Object.prototype.hasOwnProperty.call(a,f)?a=a[f]:a={},++u}return nf(a)?{}:{obj:a,k:tf(o[u])}},rf=(a,r,s)=>{const{obj:o,k:u}=$r(a,r,Object);if(o!==void 0||r.length===1){o[u]=s;return}let f=r[r.length-1],d=r.slice(0,r.length-1),h=$r(a,d,Object);for(;h.obj===void 0&&d.length;)f=`${d[d.length-1]}.${f}`,d=d.slice(0,d.length-1),h=$r(a,d,Object),h!=null&&h.obj&&typeof h.obj[`${h.k}.${f}`]<"u"&&(h.obj=void 0);h.obj[`${h.k}.${f}`]=s},n2=(a,r,s,o)=>{const{obj:u,k:f}=$r(a,r,Object);u[f]=u[f]||[],u[f].push(s)},pi=(a,r)=>{const{obj:s,k:o}=$r(a,r);if(s&&Object.prototype.hasOwnProperty.call(s,o))return s[o]},r2=(a,r,s)=>{const o=pi(a,s);return o!==void 0?o:pi(r,s)},Tf=(a,r,s)=>{for(const o in r)o!=="__proto__"&&o!=="constructor"&&(o in a?ee(a[o])||a[o]instanceof String||ee(r[o])||r[o]instanceof String?s&&(a[o]=r[o]):Tf(a[o],r[o],s):a[o]=r[o]);return a},wn=a=>a.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&");var s2={"&":"&","<":"<",">":">",'"':""","'":"'","/":"/"};const i2=a=>ee(a)?a.replace(/[&<>"'\/]/g,r=>s2[r]):a;class o2{constructor(r){this.capacity=r,this.regExpMap=new Map,this.regExpQueue=[]}getRegExp(r){const s=this.regExpMap.get(r);if(s!==void 0)return s;const o=new RegExp(r);return this.regExpQueue.length===this.capacity&&this.regExpMap.delete(this.regExpQueue.shift()),this.regExpMap.set(r,o),this.regExpQueue.push(r),o}}const a2=[" ",",","?","!",";"],l2=new o2(20),u2=(a,r,s)=>{r=r||"",s=s||"";const o=a2.filter(d=>r.indexOf(d)<0&&s.indexOf(d)<0);if(o.length===0)return!0;const u=l2.getRegExp(`(${o.map(d=>d==="?"?"\\?":d).join("|")})`);let f=!u.test(a);if(!f){const d=a.indexOf(s);d>0&&!u.test(a.substring(0,d))&&(f=!0)}return f},za=(a,r,s=".")=>{if(!a)return;if(a[r])return Object.prototype.hasOwnProperty.call(a,r)?a[r]:void 0;const o=r.split(s);let u=a;for(let f=0;f<o.length;){if(!u||typeof u!="object")return;let d,h="";for(let m=f;m<o.length;++m)if(m!==f&&(h+=s),h+=o[m],d=u[h],d!==void 0){if(["string","number","boolean"].indexOf(typeof d)>-1&&m<o.length-1)continue;f+=m-f+1;break}u=d}return u},Hr=a=>a==null?void 0:a.replace(/_/g,"-"),c2={type:"logger",log(a){this.output("log",a)},warn(a){this.output("warn",a)},error(a){this.output("error",a)},output(a,r){var s,o;(o=(s=console==null?void 0:console[a])==null?void 0:s.apply)==null||o.call(s,console,r)}};class di{constructor(r,s={}){this.init(r,s)}init(r,s={}){this.prefix=s.prefix||"i18next:",this.logger=r||c2,this.options=s,this.debug=s.debug}log(...r){return this.forward(r,"log","",!0)}warn(...r){return this.forward(r,"warn","",!0)}error(...r){return this.forward(r,"error","")}deprecate(...r){return this.forward(r,"warn","WARNING DEPRECATED: ",!0)}forward(r,s,o,u){return u&&!this.debug?null:(ee(r[0])&&(r[0]=`${o}${this.prefix} ${r[0]}`),this.logger[s](r))}create(r){return new di(this.logger,{prefix:`${this.prefix}:${r}:`,...this.options})}clone(r){return r=r||this.options,r.prefix=r.prefix||this.prefix,new di(this.logger,r)}}var zt=new di;class yi{constructor(){this.observers={}}on(r,s){return r.split(" ").forEach(o=>{this.observers[o]||(this.observers[o]=new Map);const u=this.observers[o].get(s)||0;this.observers[o].set(s,u+1)}),this}off(r,s){if(this.observers[r]){if(!s){delete this.observers[r];return}this.observers[r].delete(s)}}emit(r,...s){this.observers[r]&&Array.from(this.observers[r].entries()).forEach(([u,f])=>{for(let d=0;d<f;d++)u(...s)}),this.observers["*"]&&Array.from(this.observers["*"].entries()).forEach(([u,f])=>{for(let d=0;d<f;d++)u.apply(u,[r,...s])})}}class sf extends yi{constructor(r,s={ns:["translation"],defaultNS:"translation"}){super(),this.data=r||{},this.options=s,this.options.keySeparator===void 0&&(this.options.keySeparator="."),this.options.ignoreJSONStructure===void 0&&(this.options.ignoreJSONStructure=!0)}addNamespaces(r){this.options.ns.indexOf(r)<0&&this.options.ns.push(r)}removeNamespaces(r){const s=this.options.ns.indexOf(r);s>-1&&this.options.ns.splice(s,1)}getResource(r,s,o,u={}){var y,F;const f=u.keySeparator!==void 0?u.keySeparator:this.options.keySeparator,d=u.ignoreJSONStructure!==void 0?u.ignoreJSONStructure:this.options.ignoreJSONStructure;let h;r.indexOf(".")>-1?h=r.split("."):(h=[r,s],o&&(Array.isArray(o)?h.push(...o):ee(o)&&f?h.push(...o.split(f)):h.push(o)));const m=pi(this.data,h);return!m&&!s&&!o&&r.indexOf(".")>-1&&(r=h[0],s=h[1],o=h.slice(2).join(".")),m||!d||!ee(o)?m:za((F=(y=this.data)==null?void 0:y[r])==null?void 0:F[s],o,f)}addResource(r,s,o,u,f={silent:!1}){const d=f.keySeparator!==void 0?f.keySeparator:this.options.keySeparator;let h=[r,s];o&&(h=h.concat(d?o.split(d):o)),r.indexOf(".")>-1&&(h=r.split("."),u=s,s=h[1]),this.addNamespaces(s),rf(this.data,h,u),f.silent||this.emit("added",r,s,o,u)}addResources(r,s,o,u={silent:!1}){for(const f in o)(ee(o[f])||Array.isArray(o[f]))&&this.addResource(r,s,f,o[f],{silent:!0});u.silent||this.emit("added",r,s,o)}addResourceBundle(r,s,o,u,f,d={silent:!1,skipCopy:!1}){let h=[r,s];r.indexOf(".")>-1&&(h=r.split("."),u=o,o=s,s=h[1]),this.addNamespaces(s);let m=pi(this.data,h)||{};d.skipCopy||(o=JSON.parse(JSON.stringify(o))),u?Tf(m,o,f):m={...m,...o},rf(this.data,h,m),d.silent||this.emit("added",r,s,o)}removeResourceBundle(r,s){this.hasResourceBundle(r,s)&&delete this.data[r][s],this.removeNamespaces(s),this.emit("removed",r,s)}hasResourceBundle(r,s){return this.getResource(r,s)!==void 0}getResourceBundle(r,s){return s||(s=this.options.defaultNS),this.getResource(r,s)}getDataByLanguage(r){return this.data[r]}hasLanguageSomeTranslations(r){const s=this.getDataByLanguage(r);return!!(s&&Object.keys(s)||[]).find(u=>s[u]&&Object.keys(s[u]).length>0)}toJSON(){return this.data}}var Mf={processors:{},addPostProcessor(a){this.processors[a.name]=a},handle(a,r,s,o,u){return a.forEach(f=>{var d;r=((d=this.processors[f])==null?void 0:d.process(r,s,o,u))??r}),r}};const Bf=Symbol("i18next/PATH_KEY");function f2(){const a=[],r=Object.create(null);let s;return r.get=(o,u)=>{var f;return(f=s==null?void 0:s.revoke)==null||f.call(s),u===Bf?a:(a.push(u),s=Proxy.revocable(o,r),s.proxy)},Proxy.revocable(Object.create(null),r).proxy}function Xr(a,r){const{[Bf]:s}=a(f2()),o=(r==null?void 0:r.keySeparator)??".",u=(r==null?void 0:r.nsSeparator)??":";if(s.length>1&&u){const f=r==null?void 0:r.ns;if((f?Array.isArray(f)?f:[f]:[]).includes(s[0]))return`${s[0]}${u}${s.slice(1).join(o)}`}return s.join(o)}const of={},xa=a=>!ee(a)&&typeof a!="boolean"&&typeof a!="number";class hi extends yi{constructor(r,s={}){super(),e2(["resourceStore","languageUtils","pluralResolver","interpolator","backendConnector","i18nFormat","utils"],r,this),this.options=s,this.options.keySeparator===void 0&&(this.options.keySeparator="."),this.logger=zt.create("translator")}changeLanguage(r){r&&(this.language=r)}exists(r,s={interpolation:{}}){const o={...s};if(r==null)return!1;const u=this.resolve(r,o);if((u==null?void 0:u.res)===void 0)return!1;const f=xa(u.res);return!(o.returnObjects===!1&&f)}extractFromKey(r,s){let o=s.nsSeparator!==void 0?s.nsSeparator:this.options.nsSeparator;o===void 0&&(o=":");const u=s.keySeparator!==void 0?s.keySeparator:this.options.keySeparator;let f=s.ns||this.options.defaultNS||[];const d=o&&r.indexOf(o)>-1,h=!this.options.userDefinedKeySeparator&&!s.keySeparator&&!this.options.userDefinedNsSeparator&&!s.nsSeparator&&!u2(r,o,u);if(d&&!h){const m=r.match(this.interpolator.nestingRegexp);if(m&&m.length>0)return{key:r,namespaces:ee(f)?[f]:f};const y=r.split(o);(o!==u||o===u&&this.options.ns.indexOf(y[0])>-1)&&(f=y.shift()),r=y.join(u)}return{key:r,namespaces:ee(f)?[f]:f}}translate(r,s,o){let u=typeof s=="object"?{...s}:s;if(typeof u!="object"&&this.options.overloadTranslationOptionHandler&&(u=this.options.overloadTranslationOptionHandler(arguments)),typeof u=="object"&&(u={...u}),u||(u={}),r==null)return"";typeof r=="function"&&(r=Xr(r,{...this.options,...u})),Array.isArray(r)||(r=[String(r)]),r=r.map(W=>typeof W=="function"?Xr(W,{...this.options,...u}):String(W));const f=u.returnDetails!==void 0?u.returnDetails:this.options.returnDetails,d=u.keySeparator!==void 0?u.keySeparator:this.options.keySeparator,{key:h,namespaces:m}=this.extractFromKey(r[r.length-1],u),y=m[m.length-1];let F=u.nsSeparator!==void 0?u.nsSeparator:this.options.nsSeparator;F===void 0&&(F=":");const v=u.lng||this.language,D=u.appendNamespaceToCIMode||this.options.appendNamespaceToCIMode;if((v==null?void 0:v.toLowerCase())==="cimode")return D?f?{res:`${y}${F}${h}`,usedKey:h,exactUsedKey:h,usedLng:v,usedNS:y,usedParams:this.getUsedParamsDetails(u)}:`${y}${F}${h}`:f?{res:h,usedKey:h,exactUsedKey:h,usedLng:v,usedNS:y,usedParams:this.getUsedParamsDetails(u)}:h;const z=this.resolve(r,u);let L=z==null?void 0:z.res;const M=(z==null?void 0:z.usedKey)||h,V=(z==null?void 0:z.exactUsedKey)||h,we=["[object Number]","[object Function]","[object RegExp]"],me=u.joinArrays!==void 0?u.joinArrays:this.options.joinArrays,ge=!this.i18nFormat||this.i18nFormat.handleAsObject,G=u.count!==void 0&&!ee(u.count),ae=hi.hasDefaultValue(u),Se=G?this.pluralResolver.getSuffix(v,u.count,u):"",le=u.ordinal&&G?this.pluralResolver.getSuffix(v,u.count,{ordinal:!1}):"",Ne=G&&!u.ordinal&&u.count===0,ye=Ne&&u[`defaultValue${this.options.pluralSeparator}zero`]||u[`defaultValue${Se}`]||u[`defaultValue${le}`]||u.defaultValue;let pe=L;ge&&!L&&ae&&(pe=ye);const Qe=xa(pe),te=Object.prototype.toString.apply(pe);if(ge&&pe&&Qe&&we.indexOf(te)<0&&!(ee(me)&&Array.isArray(pe))){if(!u.returnObjects&&!this.options.returnObjects){this.options.returnedObjectHandler||this.logger.warn("accessing an object - but returnObjects options is not enabled!");const W=this.options.returnedObjectHandler?this.options.returnedObjectHandler(M,pe,{...u,ns:m}):`key '${h} (${this.language})' returned an object instead of string.`;return f?(z.res=W,z.usedParams=this.getUsedParamsDetails(u),z):W}if(d){const W=Array.isArray(pe),Y=W?[]:{},ue=W?V:M;for(const de in pe)if(Object.prototype.hasOwnProperty.call(pe,de)){const se=`${ue}${d}${de}`;ae&&!L?Y[de]=this.translate(se,{...u,defaultValue:xa(ye)?ye[de]:void 0,joinArrays:!1,ns:m}):Y[de]=this.translate(se,{...u,joinArrays:!1,ns:m}),Y[de]===se&&(Y[de]=pe[de])}L=Y}}else if(ge&&ee(me)&&Array.isArray(L))L=L.join(me),L&&(L=this.extendTranslation(L,r,u,o));else{let W=!1,Y=!1;!this.isValidLookup(L)&&ae&&(W=!0,L=ye),this.isValidLookup(L)||(Y=!0,L=h);const de=(u.missingKeyNoValueFallbackToKey||this.options.missingKeyNoValueFallbackToKey)&&Y?void 0:L,se=ae&&ye!==L&&this.options.updateMissing;if(Y||W||se){if(this.logger.log(se?"updateKey":"missingKey",v,y,h,se?ye:L),d){const S=this.resolve(h,{...u,keySeparator:!1});S&&S.res&&this.logger.warn("Seems the loaded translations were in flat JSON format instead of nested. Either set keySeparator: false on init or make sure your translations are published in nested format.")}let T=[];const Z=this.languageUtils.getFallbackCodes(this.options.fallbackLng,u.lng||this.language);if(this.options.saveMissingTo==="fallback"&&Z&&Z[0])for(let S=0;S<Z.length;S++)T.push(Z[S]);else this.options.saveMissingTo==="all"?T=this.languageUtils.toResolveHierarchy(u.lng||this.language):T.push(u.lng||this.language);const B=(S,E,R)=>{var Q;const $=ae&&R!==L?R:de;this.options.missingKeyHandler?this.options.missingKeyHandler(S,y,E,$,se,u):(Q=this.backendConnector)!=null&&Q.saveMissing&&this.backendConnector.saveMissing(S,y,E,$,se,u),this.emit("missingKey",S,y,E,L)};this.options.saveMissing&&(this.options.saveMissingPlurals&&G?T.forEach(S=>{const E=this.pluralResolver.getSuffixes(S,u);Ne&&u[`defaultValue${this.options.pluralSeparator}zero`]&&E.indexOf(`${this.options.pluralSeparator}zero`)<0&&E.push(`${this.options.pluralSeparator}zero`),E.forEach(R=>{B([S],h+R,u[`defaultValue${R}`]||ye)})}):B(T,h,ye))}L=this.extendTranslation(L,r,u,z,o),Y&&L===h&&this.options.appendNamespaceToMissingKey&&(L=`${y}${F}${h}`),(Y||W)&&this.options.parseMissingKeyHandler&&(L=this.options.parseMissingKeyHandler(this.options.appendNamespaceToMissingKey?`${y}${F}${h}`:h,W?L:void 0,u))}return f?(z.res=L,z.usedParams=this.getUsedParamsDetails(u),z):L}extendTranslation(r,s,o,u,f){var m,y;if((m=this.i18nFormat)!=null&&m.parse)r=this.i18nFormat.parse(r,{...this.options.interpolation.defaultVariables,...o},o.lng||this.language||u.usedLng,u.usedNS,u.usedKey,{resolved:u});else if(!o.skipInterpolation){o.interpolation&&this.interpolator.init({...o,interpolation:{...this.options.interpolation,...o.interpolation}});const F=ee(r)&&(((y=o==null?void 0:o.interpolation)==null?void 0:y.skipOnVariables)!==void 0?o.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables);let v;if(F){const z=r.match(this.interpolator.nestingRegexp);v=z&&z.length}let D=o.replace&&!ee(o.replace)?o.replace:o;if(this.options.interpolation.defaultVariables&&(D={...this.options.interpolation.defaultVariables,...D}),r=this.interpolator.interpolate(r,D,o.lng||this.language||u.usedLng,o),F){const z=r.match(this.interpolator.nestingRegexp),L=z&&z.length;v<L&&(o.nest=!1)}!o.lng&&u&&u.res&&(o.lng=this.language||u.usedLng),o.nest!==!1&&(r=this.interpolator.nest(r,(...z)=>(f==null?void 0:f[0])===z[0]&&!o.context?(this.logger.warn(`It seems you are nesting recursively key: ${z[0]} in key: ${s[0]}`),null):this.translate(...z,s),o)),o.interpolation&&this.interpolator.reset()}const d=o.postProcess||this.options.postProcess,h=ee(d)?[d]:d;return r!=null&&(h!=null&&h.length)&&o.applyPostProcessor!==!1&&(r=Mf.handle(h,r,s,this.options&&this.options.postProcessPassResolved?{i18nResolved:{...u,usedParams:this.getUsedParamsDetails(o)},...o}:o,this)),r}resolve(r,s={}){let o,u,f,d,h;return ee(r)&&(r=[r]),Array.isArray(r)&&(r=r.map(m=>typeof m=="function"?Xr(m,{...this.options,...s}):m)),r.forEach(m=>{if(this.isValidLookup(o))return;const y=this.extractFromKey(m,s),F=y.key;u=F;let v=y.namespaces;this.options.fallbackNS&&(v=v.concat(this.options.fallbackNS));const D=s.count!==void 0&&!ee(s.count),z=D&&!s.ordinal&&s.count===0,L=s.context!==void 0&&(ee(s.context)||typeof s.context=="number")&&s.context!=="",M=s.lngs?s.lngs:this.languageUtils.toResolveHierarchy(s.lng||this.language,s.fallbackLng);v.forEach(V=>{var we,me;this.isValidLookup(o)||(h=V,!of[`${M[0]}-${V}`]&&((we=this.utils)!=null&&we.hasLoadedNamespace)&&!((me=this.utils)!=null&&me.hasLoadedNamespace(h))&&(of[`${M[0]}-${V}`]=!0,this.logger.warn(`key "${u}" for languages "${M.join(", ")}" won't get resolved as namespace "${h}" was not yet loaded`,"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!")),M.forEach(ge=>{var Se;if(this.isValidLookup(o))return;d=ge;const G=[F];if((Se=this.i18nFormat)!=null&&Se.addLookupKeys)this.i18nFormat.addLookupKeys(G,F,ge,V,s);else{let le;D&&(le=this.pluralResolver.getSuffix(ge,s.count,s));const Ne=`${this.options.pluralSeparator}zero`,ye=`${this.options.pluralSeparator}ordinal${this.options.pluralSeparator}`;if(D&&(s.ordinal&&le.indexOf(ye)===0&&G.push(F+le.replace(ye,this.options.pluralSeparator)),G.push(F+le),z&&G.push(F+Ne)),L){const pe=`${F}${this.options.contextSeparator||"_"}${s.context}`;G.push(pe),D&&(s.ordinal&&le.indexOf(ye)===0&&G.push(pe+le.replace(ye,this.options.pluralSeparator)),G.push(pe+le),z&&G.push(pe+Ne))}}let ae;for(;ae=G.pop();)this.isValidLookup(o)||(f=ae,o=this.getResource(ge,V,ae,s))}))})}),{res:o,usedKey:u,exactUsedKey:f,usedLng:d,usedNS:h}}isValidLookup(r){return r!==void 0&&!(!this.options.returnNull&&r===null)&&!(!this.options.returnEmptyString&&r==="")}getResource(r,s,o,u={}){var f;return(f=this.i18nFormat)!=null&&f.getResource?this.i18nFormat.getResource(r,s,o,u):this.resourceStore.getResource(r,s,o,u)}getUsedParamsDetails(r={}){const s=["defaultValue","ordinal","context","replace","lng","lngs","fallbackLng","ns","keySeparator","nsSeparator","returnObjects","returnDetails","joinArrays","postProcess","interpolation"],o=r.replace&&!ee(r.replace);let u=o?r.replace:r;if(o&&typeof r.count<"u"&&(u.count=r.count),this.options.interpolation.defaultVariables&&(u={...this.options.interpolation.defaultVariables,...u}),!o){u={...u};for(const f of s)delete u[f]}return u}static hasDefaultValue(r){const s="defaultValue";for(const o in r)if(Object.prototype.hasOwnProperty.call(r,o)&&s===o.substring(0,s.length)&&r[o]!==void 0)return!0;return!1}}class af{constructor(r){this.options=r,this.supportedLngs=this.options.supportedLngs||!1,this.logger=zt.create("languageUtils")}getScriptPartFromCode(r){if(r=Hr(r),!r||r.indexOf("-")<0)return null;const s=r.split("-");return s.length===2||(s.pop(),s[s.length-1].toLowerCase()==="x")?null:this.formatLanguageCode(s.join("-"))}getLanguagePartFromCode(r){if(r=Hr(r),!r||r.indexOf("-")<0)return r;const s=r.split("-");return this.formatLanguageCode(s[0])}formatLanguageCode(r){if(ee(r)&&r.indexOf("-")>-1){let s;try{s=Intl.getCanonicalLocales(r)[0]}catch{}return s&&this.options.lowerCaseLng&&(s=s.toLowerCase()),s||(this.options.lowerCaseLng?r.toLowerCase():r)}return this.options.cleanCode||this.options.lowerCaseLng?r.toLowerCase():r}isSupportedCode(r){return(this.options.load==="languageOnly"||this.options.nonExplicitSupportedLngs)&&(r=this.getLanguagePartFromCode(r)),!this.supportedLngs||!this.supportedLngs.length||this.supportedLngs.indexOf(r)>-1}getBestMatchFromCodes(r){if(!r)return null;let s;return r.forEach(o=>{if(s)return;const u=this.formatLanguageCode(o);(!this.options.supportedLngs||this.isSupportedCode(u))&&(s=u)}),!s&&this.options.supportedLngs&&r.forEach(o=>{if(s)return;const u=this.getScriptPartFromCode(o);if(this.isSupportedCode(u))return s=u;const f=this.getLanguagePartFromCode(o);if(this.isSupportedCode(f))return s=f;s=this.options.supportedLngs.find(d=>{if(d===f)return d;if(!(d.indexOf("-")<0&&f.indexOf("-")<0)&&(d.indexOf("-")>0&&f.indexOf("-")<0&&d.substring(0,d.indexOf("-"))===f||d.indexOf(f)===0&&f.length>1))return d})}),s||(s=this.getFallbackCodes(this.options.fallbackLng)[0]),s}getFallbackCodes(r,s){if(!r)return[];if(typeof r=="function"&&(r=r(s)),ee(r)&&(r=[r]),Array.isArray(r))return r;if(!s)return r.default||[];let o=r[s];return o||(o=r[this.getScriptPartFromCode(s)]),o||(o=r[this.formatLanguageCode(s)]),o||(o=r[this.getLanguagePartFromCode(s)]),o||(o=r.default),o||[]}toResolveHierarchy(r,s){const o=this.getFallbackCodes((s===!1?[]:s)||this.options.fallbackLng||[],r),u=[],f=d=>{d&&(this.isSupportedCode(d)?u.push(d):this.logger.warn(`rejecting language code not found in supportedLngs: ${d}`))};return ee(r)&&(r.indexOf("-")>-1||r.indexOf("_")>-1)?(this.options.load!=="languageOnly"&&f(this.formatLanguageCode(r)),this.options.load!=="languageOnly"&&this.options.load!=="currentOnly"&&f(this.getScriptPartFromCode(r)),this.options.load!=="currentOnly"&&f(this.getLanguagePartFromCode(r))):ee(r)&&f(this.formatLanguageCode(r)),o.forEach(d=>{u.indexOf(d)<0&&f(this.formatLanguageCode(d))}),u}}const lf={zero:0,one:1,two:2,few:3,many:4,other:5},uf={select:a=>a===1?"one":"other",resolvedOptions:()=>({pluralCategories:["one","other"]})};class p2{constructor(r,s={}){this.languageUtils=r,this.options=s,this.logger=zt.create("pluralResolver"),this.pluralRulesCache={}}clearCache(){this.pluralRulesCache={}}getRule(r,s={}){const o=Hr(r==="dev"?"en":r),u=s.ordinal?"ordinal":"cardinal",f=JSON.stringify({cleanedCode:o,type:u});if(f in this.pluralRulesCache)return this.pluralRulesCache[f];let d;try{d=new Intl.PluralRules(o,{type:u})}catch{if(typeof Intl>"u")return this.logger.error("No Intl support, please use an Intl polyfill!"),uf;if(!r.match(/-|_/))return uf;const m=this.languageUtils.getLanguagePartFromCode(r);d=this.getRule(m,s)}return this.pluralRulesCache[f]=d,d}needsPlural(r,s={}){let o=this.getRule(r,s);return o||(o=this.getRule("dev",s)),(o==null?void 0:o.resolvedOptions().pluralCategories.length)>1}getPluralFormsOfKey(r,s,o={}){return this.getSuffixes(r,o).map(u=>`${s}${u}`)}getSuffixes(r,s={}){let o=this.getRule(r,s);return o||(o=this.getRule("dev",s)),o?o.resolvedOptions().pluralCategories.sort((u,f)=>lf[u]-lf[f]).map(u=>`${this.options.prepend}${s.ordinal?`ordinal${this.options.prepend}`:""}${u}`):[]}getSuffix(r,s,o={}){const u=this.getRule(r,o);return u?`${this.options.prepend}${o.ordinal?`ordinal${this.options.prepend}`:""}${u.select(s)}`:(this.logger.warn(`no plural rule found for: ${r}`),this.getSuffix("dev",s,o))}}const cf=(a,r,s,o=".",u=!0)=>{let f=r2(a,r,s);return!f&&u&&ee(s)&&(f=za(a,s,o),f===void 0&&(f=za(r,s,o))),f},wa=a=>a.replace(/\$/g,"$$$$");class ff{constructor(r={}){var s;this.logger=zt.create("interpolator"),this.options=r,this.format=((s=r==null?void 0:r.interpolation)==null?void 0:s.format)||(o=>o),this.init(r)}init(r={}){r.interpolation||(r.interpolation={escapeValue:!0});const{escape:s,escapeValue:o,useRawValueToEscape:u,prefix:f,prefixEscaped:d,suffix:h,suffixEscaped:m,formatSeparator:y,unescapeSuffix:F,unescapePrefix:v,nestingPrefix:D,nestingPrefixEscaped:z,nestingSuffix:L,nestingSuffixEscaped:M,nestingOptionsSeparator:V,maxReplaces:we,alwaysFormat:me}=r.interpolation;this.escape=s!==void 0?s:i2,this.escapeValue=o!==void 0?o:!0,this.useRawValueToEscape=u!==void 0?u:!1,this.prefix=f?wn(f):d||"{{",this.suffix=h?wn(h):m||"}}",this.formatSeparator=y||",",this.unescapePrefix=F?"":v||"-",this.unescapeSuffix=this.unescapePrefix?"":F||"",this.nestingPrefix=D?wn(D):z||wn("$t("),this.nestingSuffix=L?wn(L):M||wn(")"),this.nestingOptionsSeparator=V||",",this.maxReplaces=we||1e3,this.alwaysFormat=me!==void 0?me:!1,this.resetRegExp()}reset(){this.options&&this.init(this.options)}resetRegExp(){const r=(s,o)=>(s==null?void 0:s.source)===o?(s.lastIndex=0,s):new RegExp(o,"g");this.regexp=r(this.regexp,`${this.prefix}(.+?)${this.suffix}`),this.regexpUnescape=r(this.regexpUnescape,`${this.prefix}${this.unescapePrefix}(.+?)${this.unescapeSuffix}${this.suffix}`),this.nestingRegexp=r(this.nestingRegexp,`${this.nestingPrefix}((?:[^()"']+|"[^"]*"|'[^']*'|\\((?:[^()]|"[^"]*"|'[^']*')*\\))*?)${this.nestingSuffix}`)}interpolate(r,s,o,u){var z;let f,d,h;const m=this.options&&this.options.interpolation&&this.options.interpolation.defaultVariables||{},y=L=>{if(L.indexOf(this.formatSeparator)<0){const me=cf(s,m,L,this.options.keySeparator,this.options.ignoreJSONStructure);return this.alwaysFormat?this.format(me,void 0,o,{...u,...s,interpolationkey:L}):me}const M=L.split(this.formatSeparator),V=M.shift().trim(),we=M.join(this.formatSeparator).trim();return this.format(cf(s,m,V,this.options.keySeparator,this.options.ignoreJSONStructure),we,o,{...u,...s,interpolationkey:V})};this.resetRegExp();const F=(u==null?void 0:u.missingInterpolationHandler)||this.options.missingInterpolationHandler,v=((z=u==null?void 0:u.interpolation)==null?void 0:z.skipOnVariables)!==void 0?u.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables;return[{regex:this.regexpUnescape,safeValue:L=>wa(L)},{regex:this.regexp,safeValue:L=>this.escapeValue?wa(this.escape(L)):wa(L)}].forEach(L=>{for(h=0;f=L.regex.exec(r);){const M=f[1].trim();if(d=y(M),d===void 0)if(typeof F=="function"){const we=F(r,f,u);d=ee(we)?we:""}else if(u&&Object.prototype.hasOwnProperty.call(u,M))d="";else if(v){d=f[0];continue}else this.logger.warn(`missed to pass in variable ${M} for interpolating ${r}`),d="";else!ee(d)&&!this.useRawValueToEscape&&(d=ef(d));const V=L.safeValue(d);if(r=r.replace(f[0],V),v?(L.regex.lastIndex+=d.length,L.regex.lastIndex-=f[0].length):L.regex.lastIndex=0,h++,h>=this.maxReplaces)break}}),r}nest(r,s,o={}){let u,f,d;const h=(m,y)=>{const F=this.nestingOptionsSeparator;if(m.indexOf(F)<0)return m;const v=m.split(new RegExp(`${wn(F)}[ ]*{`));let D=`{${v[1]}`;m=v[0],D=this.interpolate(D,d);const z=D.match(/'/g),L=D.match(/"/g);(((z==null?void 0:z.length)??0)%2===0&&!L||((L==null?void 0:L.length)??0)%2!==0)&&(D=D.replace(/'/g,'"'));try{d=JSON.parse(D),y&&(d={...y,...d})}catch(M){return this.logger.warn(`failed parsing options string in nesting for key ${m}`,M),`${m}${F}${D}`}return d.defaultValue&&d.defaultValue.indexOf(this.prefix)>-1&&delete d.defaultValue,m};for(;u=this.nestingRegexp.exec(r);){let m=[];d={...o},d=d.replace&&!ee(d.replace)?d.replace:d,d.applyPostProcessor=!1,delete d.defaultValue;const y=/{.*}/.test(u[1])?u[1].lastIndexOf("}")+1:u[1].indexOf(this.formatSeparator);if(y!==-1&&(m=u[1].slice(y).split(this.formatSeparator).map(F=>F.trim()).filter(Boolean),u[1]=u[1].slice(0,y)),f=s(h.call(this,u[1].trim(),d),d),f&&u[0]===r&&!ee(f))return f;ee(f)||(f=ef(f)),f||(this.logger.warn(`missed to resolve ${u[1]} for nesting ${r}`),f=""),m.length&&(f=m.reduce((F,v)=>this.format(F,v,o.lng,{...o,interpolationkey:u[1].trim()}),f.trim())),r=r.replace(u[0],f),this.regexp.lastIndex=0}return r}}const d2=a=>{let r=a.toLowerCase().trim();const s={};if(a.indexOf("(")>-1){const o=a.split("(");r=o[0].toLowerCase().trim();const u=o[1].substring(0,o[1].length-1);r==="currency"&&u.indexOf(":")<0?s.currency||(s.currency=u.trim()):r==="relativetime"&&u.indexOf(":")<0?s.range||(s.range=u.trim()):u.split(";").forEach(d=>{if(d){const[h,...m]=d.split(":"),y=m.join(":").trim().replace(/^'+|'+$/g,""),F=h.trim();s[F]||(s[F]=y),y==="false"&&(s[F]=!1),y==="true"&&(s[F]=!0),isNaN(y)||(s[F]=parseInt(y,10))}})}return{formatName:r,formatOptions:s}},pf=a=>{const r={};return(s,o,u)=>{let f=u;u&&u.interpolationkey&&u.formatParams&&u.formatParams[u.interpolationkey]&&u[u.interpolationkey]&&(f={...f,[u.interpolationkey]:void 0});const d=o+JSON.stringify(f);let h=r[d];return h||(h=a(Hr(o),u),r[d]=h),h(s)}},h2=a=>(r,s,o)=>a(Hr(s),o)(r);class m2{constructor(r={}){this.logger=zt.create("formatter"),this.options=r,this.init(r)}init(r,s={interpolation:{}}){this.formatSeparator=s.interpolation.formatSeparator||",";const o=s.cacheInBuiltFormats?pf:h2;this.formats={number:o((u,f)=>{const d=new Intl.NumberFormat(u,{...f});return h=>d.format(h)}),currency:o((u,f)=>{const d=new Intl.NumberFormat(u,{...f,style:"currency"});return h=>d.format(h)}),datetime:o((u,f)=>{const d=new Intl.DateTimeFormat(u,{...f});return h=>d.format(h)}),relativetime:o((u,f)=>{const d=new Intl.RelativeTimeFormat(u,{...f});return h=>d.format(h,f.range||"day")}),list:o((u,f)=>{const d=new Intl.ListFormat(u,{...f});return h=>d.format(h)})}}add(r,s){this.formats[r.toLowerCase().trim()]=s}addCached(r,s){this.formats[r.toLowerCase().trim()]=pf(s)}format(r,s,o,u={}){const f=s.split(this.formatSeparator);if(f.length>1&&f[0].indexOf("(")>1&&f[0].indexOf(")")<0&&f.find(h=>h.indexOf(")")>-1)){const h=f.findIndex(m=>m.indexOf(")")>-1);f[0]=[f[0],...f.splice(1,h)].join(this.formatSeparator)}return f.reduce((h,m)=>{var v;const{formatName:y,formatOptions:F}=d2(m);if(this.formats[y]){let D=h;try{const z=((v=u==null?void 0:u.formatParams)==null?void 0:v[u.interpolationkey])||{},L=z.locale||z.lng||u.locale||u.lng||o;D=this.formats[y](h,L,{...F,...u,...z})}catch(z){this.logger.warn(z)}return D}else this.logger.warn(`there was no format function for ${y}`);return h},r)}}const g2=(a,r)=>{a.pending[r]!==void 0&&(delete a.pending[r],a.pendingCount--)};class y2 extends yi{constructor(r,s,o,u={}){var f,d;super(),this.backend=r,this.store=s,this.services=o,this.languageUtils=o.languageUtils,this.options=u,this.logger=zt.create("backendConnector"),this.waitingReads=[],this.maxParallelReads=u.maxParallelReads||10,this.readingCalls=0,this.maxRetries=u.maxRetries>=0?u.maxRetries:5,this.retryTimeout=u.retryTimeout>=1?u.retryTimeout:350,this.state={},this.queue=[],(d=(f=this.backend)==null?void 0:f.init)==null||d.call(f,o,u.backend,u)}queueLoad(r,s,o,u){const f={},d={},h={},m={};return r.forEach(y=>{let F=!0;s.forEach(v=>{const D=`${y}|${v}`;!o.reload&&this.store.hasResourceBundle(y,v)?this.state[D]=2:this.state[D]<0||(this.state[D]===1?d[D]===void 0&&(d[D]=!0):(this.state[D]=1,F=!1,d[D]===void 0&&(d[D]=!0),f[D]===void 0&&(f[D]=!0),m[v]===void 0&&(m[v]=!0)))}),F||(h[y]=!0)}),(Object.keys(f).length||Object.keys(d).length)&&this.queue.push({pending:d,pendingCount:Object.keys(d).length,loaded:{},errors:[],callback:u}),{toLoad:Object.keys(f),pending:Object.keys(d),toLoadLanguages:Object.keys(h),toLoadNamespaces:Object.keys(m)}}loaded(r,s,o){const u=r.split("|"),f=u[0],d=u[1];s&&this.emit("failedLoading",f,d,s),!s&&o&&this.store.addResourceBundle(f,d,o,void 0,void 0,{skipCopy:!0}),this.state[r]=s?-1:2,s&&o&&(this.state[r]=0);const h={};this.queue.forEach(m=>{n2(m.loaded,[f],d),g2(m,r),s&&m.errors.push(s),m.pendingCount===0&&!m.done&&(Object.keys(m.loaded).forEach(y=>{h[y]||(h[y]={});const F=m.loaded[y];F.length&&F.forEach(v=>{h[y][v]===void 0&&(h[y][v]=!0)})}),m.done=!0,m.errors.length?m.callback(m.errors):m.callback())}),this.emit("loaded",h),this.queue=this.queue.filter(m=>!m.done)}read(r,s,o,u=0,f=this.retryTimeout,d){if(!r.length)return d(null,{});if(this.readingCalls>=this.maxParallelReads){this.waitingReads.push({lng:r,ns:s,fcName:o,tried:u,wait:f,callback:d});return}this.readingCalls++;const h=(y,F)=>{if(this.readingCalls--,this.waitingReads.length>0){const v=this.waitingReads.shift();this.read(v.lng,v.ns,v.fcName,v.tried,v.wait,v.callback)}if(y&&F&&u<this.maxRetries){setTimeout(()=>{this.read.call(this,r,s,o,u+1,f*2,d)},f);return}d(y,F)},m=this.backend[o].bind(this.backend);if(m.length===2){try{const y=m(r,s);y&&typeof y.then=="function"?y.then(F=>h(null,F)).catch(h):h(null,y)}catch(y){h(y)}return}return m(r,s,h)}prepareLoading(r,s,o={},u){if(!this.backend)return this.logger.warn("No backend was added via i18next.use. Will not load resources."),u&&u();ee(r)&&(r=this.languageUtils.toResolveHierarchy(r)),ee(s)&&(s=[s]);const f=this.queueLoad(r,s,o,u);if(!f.toLoad.length)return f.pending.length||u(),null;f.toLoad.forEach(d=>{this.loadOne(d)})}load(r,s,o){this.prepareLoading(r,s,{},o)}reload(r,s,o){this.prepareLoading(r,s,{reload:!0},o)}loadOne(r,s=""){const o=r.split("|"),u=o[0],f=o[1];this.read(u,f,"read",void 0,void 0,(d,h)=>{d&&this.logger.warn(`${s}loading namespace ${f} for language ${u} failed`,d),!d&&h&&this.logger.log(`${s}loaded namespace ${f} for language ${u}`,h),this.loaded(r,d,h)})}saveMissing(r,s,o,u,f,d={},h=()=>{}){var m,y,F,v,D;if((y=(m=this.services)==null?void 0:m.utils)!=null&&y.hasLoadedNamespace&&!((v=(F=this.services)==null?void 0:F.utils)!=null&&v.hasLoadedNamespace(s))){this.logger.warn(`did not save key "${o}" as the namespace "${s}" was not yet loaded`,"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!");return}if(!(o==null||o==="")){if((D=this.backend)!=null&&D.create){const z={...d,isUpdate:f},L=this.backend.create.bind(this.backend);if(L.length<6)try{let M;L.length===5?M=L(r,s,o,u,z):M=L(r,s,o,u),M&&typeof M.then=="function"?M.then(V=>h(null,V)).catch(h):h(null,M)}catch(M){h(M)}else L(r,s,o,u,h,z)}!r||!r[0]||this.store.addResource(r[0],s,o,u)}}}const Sa=()=>({debug:!1,initAsync:!0,ns:["translation"],defaultNS:["translation"],fallbackLng:["dev"],fallbackNS:!1,supportedLngs:!1,nonExplicitSupportedLngs:!1,load:"all",preload:!1,simplifyPluralSuffix:!0,keySeparator:".",nsSeparator:":",pluralSeparator:"_",contextSeparator:"_",partialBundledLanguages:!1,saveMissing:!1,updateMissing:!1,saveMissingTo:"fallback",saveMissingPlurals:!0,missingKeyHandler:!1,missingInterpolationHandler:!1,postProcess:!1,postProcessPassResolved:!1,returnNull:!1,returnEmptyString:!0,returnObjects:!1,joinArrays:!1,returnedObjectHandler:!1,parseMissingKeyHandler:!1,appendNamespaceToMissingKey:!1,appendNamespaceToCIMode:!1,overloadTranslationOptionHandler:a=>{let r={};if(typeof a[1]=="object"&&(r=a[1]),ee(a[1])&&(r.defaultValue=a[1]),ee(a[2])&&(r.tDescription=a[2]),typeof a[2]=="object"||typeof a[3]=="object"){const s=a[3]||a[2];Object.keys(s).forEach(o=>{r[o]=s[o]})}return r},interpolation:{escapeValue:!0,format:a=>a,prefix:"{{",suffix:"}}",formatSeparator:",",unescapePrefix:"-",nestingPrefix:"$t(",nestingSuffix:")",nestingOptionsSeparator:",",maxReplaces:1e3,skipOnVariables:!0},cacheInBuiltFormats:!0}),df=a=>{var r,s;return ee(a.ns)&&(a.ns=[a.ns]),ee(a.fallbackLng)&&(a.fallbackLng=[a.fallbackLng]),ee(a.fallbackNS)&&(a.fallbackNS=[a.fallbackNS]),((s=(r=a.supportedLngs)==null?void 0:r.indexOf)==null?void 0:s.call(r,"cimode"))<0&&(a.supportedLngs=a.supportedLngs.concat(["cimode"])),typeof a.initImmediate=="boolean"&&(a.initAsync=a.initImmediate),a},ii=()=>{},v2=a=>{Object.getOwnPropertyNames(Object.getPrototypeOf(a)).forEach(s=>{typeof a[s]=="function"&&(a[s]=a[s].bind(a))})},Uf="__i18next_supportNoticeShown",x2=()=>typeof globalThis<"u"&&!!globalThis[Uf],w2=()=>{typeof globalThis<"u"&&(globalThis[Uf]=!0)},S2=a=>{var r,s,o,u,f,d,h,m,y,F,v,D,z;return!!(((o=(s=(r=a==null?void 0:a.modules)==null?void 0:r.backend)==null?void 0:s.name)==null?void 0:o.indexOf("Locize"))>0||((h=(d=(f=(u=a==null?void 0:a.modules)==null?void 0:u.backend)==null?void 0:f.constructor)==null?void 0:d.name)==null?void 0:h.indexOf("Locize"))>0||(y=(m=a==null?void 0:a.options)==null?void 0:m.backend)!=null&&y.backends&&a.options.backend.backends.some(L=>{var M,V,we;return((M=L==null?void 0:L.name)==null?void 0:M.indexOf("Locize"))>0||((we=(V=L==null?void 0:L.constructor)==null?void 0:V.name)==null?void 0:we.indexOf("Locize"))>0})||(v=(F=a==null?void 0:a.options)==null?void 0:F.backend)!=null&&v.projectId||(z=(D=a==null?void 0:a.options)==null?void 0:D.backend)!=null&&z.backendOptions&&a.options.backend.backendOptions.some(L=>L==null?void 0:L.projectId))};class Vr extends yi{constructor(r={},s){if(super(),this.options=df(r),this.services={},this.logger=zt,this.modules={external:[]},v2(this),s&&!this.isInitialized&&!r.isClone){if(!this.options.initAsync)return this.init(r,s),this;setTimeout(()=>{this.init(r,s)},0)}}init(r={},s){this.isInitializing=!0,typeof r=="function"&&(s=r,r={}),r.defaultNS==null&&r.ns&&(ee(r.ns)?r.defaultNS=r.ns:r.ns.indexOf("translation")<0&&(r.defaultNS=r.ns[0]));const o=Sa();this.options={...o,...this.options,...df(r)},this.options.interpolation={...o.interpolation,...this.options.interpolation},r.keySeparator!==void 0&&(this.options.userDefinedKeySeparator=r.keySeparator),r.nsSeparator!==void 0&&(this.options.userDefinedNsSeparator=r.nsSeparator),typeof this.options.overloadTranslationOptionHandler!="function"&&(this.options.overloadTranslationOptionHandler=o.overloadTranslationOptionHandler),this.options.showSupportNotice!==!1&&!S2(this)&&!x2()&&(typeof console<"u"&&typeof console.info<"u"&&console.info("🌐 i18next is made possible by our own product, Locize — consider powering your project with managed localization (AI, CDN, integrations): https://locize.com 💙"),w2());const u=y=>y?typeof y=="function"?new y:y:null;if(!this.options.isClone){this.modules.logger?zt.init(u(this.modules.logger),this.options):zt.init(null,this.options);let y;this.modules.formatter?y=this.modules.formatter:y=m2;const F=new af(this.options);this.store=new sf(this.options.resources,this.options);const v=this.services;v.logger=zt,v.resourceStore=this.store,v.languageUtils=F,v.pluralResolver=new p2(F,{prepend:this.options.pluralSeparator,simplifyPluralSuffix:this.options.simplifyPluralSuffix}),this.options.interpolation.format&&this.options.interpolation.format!==o.interpolation.format&&this.logger.deprecate("init: you are still using the legacy format function, please use the new approach: https://www.i18next.com/translation-function/formatting"),y&&(!this.options.interpolation.format||this.options.interpolation.format===o.interpolation.format)&&(v.formatter=u(y),v.formatter.init&&v.formatter.init(v,this.options),this.options.interpolation.format=v.formatter.format.bind(v.formatter)),v.interpolator=new ff(this.options),v.utils={hasLoadedNamespace:this.hasLoadedNamespace.bind(this)},v.backendConnector=new y2(u(this.modules.backend),v.resourceStore,v,this.options),v.backendConnector.on("*",(z,...L)=>{this.emit(z,...L)}),this.modules.languageDetector&&(v.languageDetector=u(this.modules.languageDetector),v.languageDetector.init&&v.languageDetector.init(v,this.options.detection,this.options)),this.modules.i18nFormat&&(v.i18nFormat=u(this.modules.i18nFormat),v.i18nFormat.init&&v.i18nFormat.init(this)),this.translator=new hi(this.services,this.options),this.translator.on("*",(z,...L)=>{this.emit(z,...L)}),this.modules.external.forEach(z=>{z.init&&z.init(this)})}if(this.format=this.options.interpolation.format,s||(s=ii),this.options.fallbackLng&&!this.services.languageDetector&&!this.options.lng){const y=this.services.languageUtils.getFallbackCodes(this.options.fallbackLng);y.length>0&&y[0]!=="dev"&&(this.options.lng=y[0])}!this.services.languageDetector&&!this.options.lng&&this.logger.warn("init: no languageDetector is used and no lng is defined"),["getResource","hasResourceBundle","getResourceBundle","getDataByLanguage"].forEach(y=>{this[y]=(...F)=>this.store[y](...F)}),["addResource","addResources","addResourceBundle","removeResourceBundle"].forEach(y=>{this[y]=(...F)=>(this.store[y](...F),this)});const h=Ur(),m=()=>{const y=(F,v)=>{this.isInitializing=!1,this.isInitialized&&!this.initializedStoreOnce&&this.logger.warn("init: i18next is already initialized. You should call init just once!"),this.isInitialized=!0,this.options.isClone||this.logger.log("initialized",this.options),this.emit("initialized",this.options),h.resolve(v),s(F,v)};if(this.languages&&!this.isInitialized)return y(null,this.t.bind(this));this.changeLanguage(this.options.lng,y)};return this.options.resources||!this.options.initAsync?m():setTimeout(m,0),h}loadResources(r,s=ii){var f,d;let o=s;const u=ee(r)?r:this.language;if(typeof r=="function"&&(o=r),!this.options.resources||this.options.partialBundledLanguages){if((u==null?void 0:u.toLowerCase())==="cimode"&&(!this.options.preload||this.options.preload.length===0))return o();const h=[],m=y=>{if(!y||y==="cimode")return;this.services.languageUtils.toResolveHierarchy(y).forEach(v=>{v!=="cimode"&&h.indexOf(v)<0&&h.push(v)})};u?m(u):this.services.languageUtils.getFallbackCodes(this.options.fallbackLng).forEach(F=>m(F)),(d=(f=this.options.preload)==null?void 0:f.forEach)==null||d.call(f,y=>m(y)),this.services.backendConnector.load(h,this.options.ns,y=>{!y&&!this.resolvedLanguage&&this.language&&this.setResolvedLanguage(this.language),o(y)})}else o(null)}reloadResources(r,s,o){const u=Ur();return typeof r=="function"&&(o=r,r=void 0),typeof s=="function"&&(o=s,s=void 0),r||(r=this.languages),s||(s=this.options.ns),o||(o=ii),this.services.backendConnector.reload(r,s,f=>{u.resolve(),o(f)}),u}use(r){if(!r)throw new Error("You are passing an undefined module! Please check the object you are passing to i18next.use()");if(!r.type)throw new Error("You are passing a wrong module! Please check the object you are passing to i18next.use()");return r.type==="backend"&&(this.modules.backend=r),(r.type==="logger"||r.log&&r.warn&&r.error)&&(this.modules.logger=r),r.type==="languageDetector"&&(this.modules.languageDetector=r),r.type==="i18nFormat"&&(this.modules.i18nFormat=r),r.type==="postProcessor"&&Mf.addPostProcessor(r),r.type==="formatter"&&(this.modules.formatter=r),r.type==="3rdParty"&&this.modules.external.push(r),this}setResolvedLanguage(r){if(!(!r||!this.languages)&&!(["cimode","dev"].indexOf(r)>-1)){for(let s=0;s<this.languages.length;s++){const o=this.languages[s];if(!(["cimode","dev"].indexOf(o)>-1)&&this.store.hasLanguageSomeTranslations(o)){this.resolvedLanguage=o;break}}!this.resolvedLanguage&&this.languages.indexOf(r)<0&&this.store.hasLanguageSomeTranslations(r)&&(this.resolvedLanguage=r,this.languages.unshift(r))}}changeLanguage(r,s){this.isLanguageChangingTo=r;const o=Ur();this.emit("languageChanging",r);const u=h=>{this.language=h,this.languages=this.services.languageUtils.toResolveHierarchy(h),this.resolvedLanguage=void 0,this.setResolvedLanguage(h)},f=(h,m)=>{m?this.isLanguageChangingTo===r&&(u(m),this.translator.changeLanguage(m),this.isLanguageChangingTo=void 0,this.emit("languageChanged",m),this.logger.log("languageChanged",m)):this.isLanguageChangingTo=void 0,o.resolve((...y)=>this.t(...y)),s&&s(h,(...y)=>this.t(...y))},d=h=>{var F,v;!r&&!h&&this.services.languageDetector&&(h=[]);const m=ee(h)?h:h&&h[0],y=this.store.hasLanguageSomeTranslations(m)?m:this.services.languageUtils.getBestMatchFromCodes(ee(h)?[h]:h);y&&(this.language||u(y),this.translator.language||this.translator.changeLanguage(y),(v=(F=this.services.languageDetector)==null?void 0:F.cacheUserLanguage)==null||v.call(F,y)),this.loadResources(y,D=>{f(D,y)})};return!r&&this.services.languageDetector&&!this.services.languageDetector.async?d(this.services.languageDetector.detect()):!r&&this.services.languageDetector&&this.services.languageDetector.async?this.services.languageDetector.detect.length===0?this.services.languageDetector.detect().then(d):this.services.languageDetector.detect(d):d(r),o}getFixedT(r,s,o){const u=(f,d,...h)=>{let m;typeof d!="object"?m=this.options.overloadTranslationOptionHandler([f,d].concat(h)):m={...d},m.lng=m.lng||u.lng,m.lngs=m.lngs||u.lngs,m.ns=m.ns||u.ns,m.keyPrefix!==""&&(m.keyPrefix=m.keyPrefix||o||u.keyPrefix);const y=this.options.keySeparator||".";let F;return m.keyPrefix&&Array.isArray(f)?F=f.map(v=>(typeof v=="function"&&(v=Xr(v,{...this.options,...d})),`${m.keyPrefix}${y}${v}`)):(typeof f=="function"&&(f=Xr(f,{...this.options,...d})),F=m.keyPrefix?`${m.keyPrefix}${y}${f}`:f),this.t(F,m)};return ee(r)?u.lng=r:u.lngs=r,u.ns=s,u.keyPrefix=o,u}t(...r){var s;return(s=this.translator)==null?void 0:s.translate(...r)}exists(...r){var s;return(s=this.translator)==null?void 0:s.exists(...r)}setDefaultNamespace(r){this.options.defaultNS=r}hasLoadedNamespace(r,s={}){if(!this.isInitialized)return this.logger.warn("hasLoadedNamespace: i18next was not initialized",this.languages),!1;if(!this.languages||!this.languages.length)return this.logger.warn("hasLoadedNamespace: i18n.languages were undefined or empty",this.languages),!1;const o=s.lng||this.resolvedLanguage||this.languages[0],u=this.options?this.options.fallbackLng:!1,f=this.languages[this.languages.length-1];if(o.toLowerCase()==="cimode")return!0;const d=(h,m)=>{const y=this.services.backendConnector.state[`${h}|${m}`];return y===-1||y===0||y===2};if(s.precheck){const h=s.precheck(this,d);if(h!==void 0)return h}return!!(this.hasResourceBundle(o,r)||!this.services.backendConnector.backend||this.options.resources&&!this.options.partialBundledLanguages||d(o,r)&&(!u||d(f,r)))}loadNamespaces(r,s){const o=Ur();return this.options.ns?(ee(r)&&(r=[r]),r.forEach(u=>{this.options.ns.indexOf(u)<0&&this.options.ns.push(u)}),this.loadResources(u=>{o.resolve(),s&&s(u)}),o):(s&&s(),Promise.resolve())}loadLanguages(r,s){const o=Ur();ee(r)&&(r=[r]);const u=this.options.preload||[],f=r.filter(d=>u.indexOf(d)<0&&this.services.languageUtils.isSupportedCode(d));return f.length?(this.options.preload=u.concat(f),this.loadResources(d=>{o.resolve(),s&&s(d)}),o):(s&&s(),Promise.resolve())}dir(r){var u,f;if(r||(r=this.resolvedLanguage||(((u=this.languages)==null?void 0:u.length)>0?this.languages[0]:this.language)),!r)return"rtl";try{const d=new Intl.Locale(r);if(d&&d.getTextInfo){const h=d.getTextInfo();if(h&&h.direction)return h.direction}}catch{}const s=["ar","shu","sqr","ssh","xaa","yhd","yud","aao","abh","abv","acm","acq","acw","acx","acy","adf","ads","aeb","aec","afb","ajp","apc","apd","arb","arq","ars","ary","arz","auz","avl","ayh","ayl","ayn","ayp","bbz","pga","he","iw","ps","pbt","pbu","pst","prp","prd","ug","ur","ydd","yds","yih","ji","yi","hbo","men","xmn","fa","jpr","peo","pes","prs","dv","sam","ckb"],o=((f=this.services)==null?void 0:f.languageUtils)||new af(Sa());return r.toLowerCase().indexOf("-latn")>1?"ltr":s.indexOf(o.getLanguagePartFromCode(r))>-1||r.toLowerCase().indexOf("-arab")>1?"rtl":"ltr"}static createInstance(r={},s){const o=new Vr(r,s);return o.createInstance=Vr.createInstance,o}cloneInstance(r={},s=ii){const o=r.forkResourceStore;o&&delete r.forkResourceStore;const u={...this.options,...r,isClone:!0},f=new Vr(u);if((r.debug!==void 0||r.prefix!==void 0)&&(f.logger=f.logger.clone(r)),["store","services","language"].forEach(h=>{f[h]=this[h]}),f.services={...this.services},f.services.utils={hasLoadedNamespace:f.hasLoadedNamespace.bind(f)},o){const h=Object.keys(this.store.data).reduce((m,y)=>(m[y]={...this.store.data[y]},m[y]=Object.keys(m[y]).reduce((F,v)=>(F[v]={...m[y][v]},F),m[y]),m),{});f.store=new sf(h,u),f.services.resourceStore=f.store}if(r.interpolation){const m={...Sa().interpolation,...this.options.interpolation,...r.interpolation},y={...u,interpolation:m};f.services.interpolator=new ff(y)}return f.translator=new hi(f.services,u),f.translator.on("*",(h,...m)=>{f.emit(h,...m)}),f.init(u,s),f.translator.options=u,f.translator.backendConnector.services.utils={hasLoadedNamespace:f.hasLoadedNamespace.bind(f)},f}toJSON(){return{options:this.options,store:this.store,language:this.language,languages:this.languages,resolvedLanguage:this.resolvedLanguage}}}const qe=Vr.createInstance();qe.createInstance;qe.dir;qe.init;qe.loadResources;qe.reloadResources;qe.use;qe.changeLanguage;qe.getFixedT;qe.t;qe.exists;qe.setDefaultNamespace;qe.hasLoadedNamespace;qe.loadNamespaces;qe.loadLanguages;const C2=(a,r,s,o)=>{var f,d,h,m;const u=[s,{code:r,...o||{}}];if((d=(f=a==null?void 0:a.services)==null?void 0:f.logger)!=null&&d.forward)return a.services.logger.forward(u,"warn","react-i18next::",!0);Sn(u[0])&&(u[0]=`react-i18next:: ${u[0]}`),(m=(h=a==null?void 0:a.services)==null?void 0:h.logger)!=null&&m.warn?a.services.logger.warn(...u):console!=null&&console.warn&&console.warn(...u)},hf={},If=(a,r,s,o)=>{Sn(s)&&hf[s]||(Sn(s)&&(hf[s]=new Date),C2(a,r,s,o))},bf=(a,r)=>()=>{if(a.isInitialized)r();else{const s=()=>{setTimeout(()=>{a.off("initialized",s)},0),r()};a.on("initialized",s)}},Da=(a,r,s)=>{a.loadNamespaces(r,bf(a,s))},mf=(a,r,s,o)=>{if(Sn(s)&&(s=[s]),a.options.preload&&a.options.preload.indexOf(r)>-1)return Da(a,s,o);s.forEach(u=>{a.options.ns.indexOf(u)<0&&a.options.ns.push(u)}),a.loadLanguages(r,bf(a,o))},k2=(a,r,s={})=>!r.languages||!r.languages.length?(If(r,"NO_LANGUAGES","i18n.languages were undefined or empty",{languages:r.languages}),!0):r.hasLoadedNamespace(a,{lng:s.lng,precheck:(o,u)=>{if(s.bindI18n&&s.bindI18n.indexOf("languageChanging")>-1&&o.services.backendConnector.backend&&o.isLanguageChangingTo&&!u(o.isLanguageChangingTo,a))return!1}}),Sn=a=>typeof a=="string",F2=a=>typeof a=="object"&&a!==null,E2=/&(?:amp|#38|lt|#60|gt|#62|apos|#39|quot|#34|nbsp|#160|copy|#169|reg|#174|hellip|#8230|#x2F|#47);/g,_2={"&":"&","&":"&","<":"<","<":"<",">":">",">":">","'":"'","'":"'",""":'"',""":'"'," ":" "," ":" ","©":"©","©":"©","®":"®","®":"®","…":"…","…":"…","/":"/","/":"/"},N2=a=>_2[a],z2=a=>a.replace(E2,N2);let La={bindI18n:"languageChanged",bindI18nStore:"",transEmptyNodeValue:"",transSupportBasicHtmlNodes:!0,transWrapTextNodes:"",transKeepBasicHtmlNodesFor:["br","strong","i","p"],useSuspense:!0,unescape:z2,transDefaultProps:void 0};const D2=(a={})=>{La={...La,...a}},L2=()=>La;let $f;const O2=a=>{$f=a},A2=()=>$f,P2={type:"3rdParty",init(a){D2(a.options.react),O2(a)}},j2=ne.createContext();class R2{constructor(){this.usedNamespaces={}}addUsedNamespaces(r){r.forEach(s=>{this.usedNamespaces[s]||(this.usedNamespaces[s]=!0)})}getUsedNamespaces(){return Object.keys(this.usedNamespaces)}}var Ca={exports:{}},ka={};/**
|
|
146
|
+
* @license React
|
|
147
|
+
* use-sync-external-store-shim.production.js
|
|
148
|
+
*
|
|
149
|
+
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
150
|
+
*
|
|
151
|
+
* This source code is licensed under the MIT license found in the
|
|
152
|
+
* LICENSE file in the root directory of this source tree.
|
|
153
|
+
*/var gf;function T2(){if(gf)return ka;gf=1;var a=gi();function r(v,D){return v===D&&(v!==0||1/v===1/D)||v!==v&&D!==D}var s=typeof Object.is=="function"?Object.is:r,o=a.useState,u=a.useEffect,f=a.useLayoutEffect,d=a.useDebugValue;function h(v,D){var z=D(),L=o({inst:{value:z,getSnapshot:D}}),M=L[0].inst,V=L[1];return f(function(){M.value=z,M.getSnapshot=D,m(M)&&V({inst:M})},[v,z,D]),u(function(){return m(M)&&V({inst:M}),v(function(){m(M)&&V({inst:M})})},[v]),d(z),z}function m(v){var D=v.getSnapshot;v=v.value;try{var z=D();return!s(v,z)}catch{return!0}}function y(v,D){return D()}var F=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?y:h;return ka.useSyncExternalStore=a.useSyncExternalStore!==void 0?a.useSyncExternalStore:F,ka}var yf;function M2(){return yf||(yf=1,Ca.exports=T2()),Ca.exports}var B2=M2();const U2=(a,r)=>{if(Sn(r))return r;if(F2(r)&&Sn(r.defaultValue))return r.defaultValue;if(typeof a=="function")return"";if(Array.isArray(a)){const s=a[a.length-1];return typeof s=="function"?"":s}return a},I2={t:U2,ready:!1},b2=()=>()=>{},Ua=(a,r={})=>{var ye,pe,Qe;const{i18n:s}=r,{i18n:o,defaultNS:u}=ne.useContext(j2)||{},f=s||o||A2();f&&!f.reportNamespaces&&(f.reportNamespaces=new R2),f||If(f,"NO_I18NEXT_INSTANCE","useTranslation: You will need to pass in an i18next instance by using initReactI18next");const d=ne.useMemo(()=>{var te;return{...L2(),...(te=f==null?void 0:f.options)==null?void 0:te.react,...r}},[f,r]),{useSuspense:h,keyPrefix:m}=d,y=u||((ye=f==null?void 0:f.options)==null?void 0:ye.defaultNS),F=Sn(y)?[y]:y||["translation"],v=ne.useMemo(()=>F,F);(Qe=(pe=f==null?void 0:f.reportNamespaces)==null?void 0:pe.addUsedNamespaces)==null||Qe.call(pe,v);const D=ne.useRef(0),z=ne.useCallback(te=>{if(!f)return b2;const{bindI18n:W,bindI18nStore:Y}=d,ue=()=>{D.current+=1,te()};return W&&f.on(W,ue),Y&&f.store.on(Y,ue),()=>{W&&W.split(" ").forEach(de=>f.off(de,ue)),Y&&Y.split(" ").forEach(de=>f.store.off(de,ue))}},[f,d]),L=ne.useRef(),M=ne.useCallback(()=>{if(!f)return I2;const te=!!(f.isInitialized||f.initializedStoreOnce)&&v.every(T=>k2(T,f,d)),W=r.lng||f.language,Y=D.current,ue=L.current;if(ue&&ue.ready===te&&ue.lng===W&&ue.keyPrefix===m&&ue.revision===Y)return ue;const se={t:f.getFixedT(W,d.nsMode==="fallback"?v:v[0],m),ready:te,lng:W,keyPrefix:m,revision:Y};return L.current=se,se},[f,v,m,d,r.lng]),[V,we]=ne.useState(0),{t:me,ready:ge}=B2.useSyncExternalStore(z,M,M);ne.useEffect(()=>{if(f&&!ge&&!h){const te=()=>we(W=>W+1);r.lng?mf(f,r.lng,v,te):Da(f,v,te)}},[f,r.lng,v,ge,h,V]);const G=f||{},ae=ne.useRef(null),Se=ne.useRef(),le=te=>{const W=Object.getOwnPropertyDescriptors(te);W.__original&&delete W.__original;const Y=Object.create(Object.getPrototypeOf(te),W);if(!Object.prototype.hasOwnProperty.call(Y,"__original"))try{Object.defineProperty(Y,"__original",{value:te,writable:!1,enumerable:!1,configurable:!1})}catch{}return Y},Ne=ne.useMemo(()=>{const te=G,W=te==null?void 0:te.language;let Y=te;te&&(ae.current&&ae.current.__original===te?Se.current!==W?(Y=le(te),ae.current=Y,Se.current=W):Y=ae.current:(Y=le(te),ae.current=Y,Se.current=W));const ue=[me,Y,ge];return ue.t=me,ue.i18n=Y,ue.ready=ge,ue},[me,G,ge,G.resolvedLanguage,G.language,G.languages]);if(f&&h&&!ge)throw new Promise(te=>{const W=()=>te();r.lng?mf(f,r.lng,v,W):Da(f,v,W)});return Ne},$2=({isOpen:a,onClose:r})=>{const{t:s,i18n:o}=Ua(),[u,f]=ne.useState("general"),[d,h]=ne.useState({provider:"openai",apiKey:"",baseURL:"",model:"",temperature:.7,systemPrompt:"",memoryMaintenanceCron:"0 0 * * *",workspace:""}),[m,y]=ne.useState(!1),[F,v]=ne.useState(null),[D,z]=ne.useState(!1),[L,M]=ne.useState([]),[V,we]=ne.useState(""),[me,ge]=ne.useState(""),[G,ae]=ne.useState("daily"),[Se,le]=ne.useState("00:00"),[Ne,ye]=ne.useState("1");ne.useEffect(()=>{a&&se()},[a]),ne.useEffect(()=>{d.memoryMaintenanceCron&&pe(d.memoryMaintenanceCron)},[d.memoryMaintenanceCron]);const pe=E=>{const R=E.split(" ");if(R.length!==5){ae("custom");return}const[$,Q,ie,ve,ce]=R;if(ie==="*"&&ve==="*"&&ce==="*"){ae("daily"),le(`${Q.padStart(2,"0")}:${$.padStart(2,"0")}`);return}if(ie==="*"&&ve==="*"&&ce!=="*"){ae("weekly"),le(`${Q.padStart(2,"0")}:${$.padStart(2,"0")}`),ye(ce);return}ae("custom")},Qe=E=>{ae(E),E==="daily"?(h(R=>({...R,memoryMaintenanceCron:"0 0 * * *"})),le("00:00")):E==="weekly"&&(h(R=>({...R,memoryMaintenanceCron:"0 0 * * 0"})),le("00:00"),ye("0"))},te=E=>{if(le(E),G==="daily"){const[R,$]=E.split(":");h(Q=>({...Q,memoryMaintenanceCron:`${parseInt($)} ${parseInt(R)} * * *`}))}else if(G==="weekly"){const[R,$]=E.split(":");h(Q=>({...Q,memoryMaintenanceCron:`${parseInt($)} ${parseInt(R)} * * ${Ne}`}))}},W=E=>{if(ye(E),G==="weekly"){const[R,$]=Se.split(":");h(Q=>({...Q,memoryMaintenanceCron:`${parseInt($)} ${parseInt(R)} * * ${E}`}))}},Y=async E=>{try{const $=await(await fetch("http://localhost:3001/api/fs/list",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({path:E})})).json();if($.error)throw new Error($.error);we($.current),ge($.parent),M($.items||[])}catch(R){console.error(R)}},ue=()=>{z(!0),Y(d.workspace||void 0)},de=E=>{h({...d,workspace:E}),z(!1)},se=async()=>{try{const R=await(await fetch("http://localhost:3001/api/config")).json();h({provider:R.provider||"openai",apiKey:R.apiKey||"",baseURL:R.baseURL||"",model:R.model||"",temperature:R.temperature||.7,systemPrompt:R.systemPrompt||"",memoryMaintenanceCron:R.memoryMaintenanceCron||"0 0 * * *",workspace:R.workspace||""})}catch(E){console.error("Failed to fetch config:",E)}},T=async()=>{y(!0),v(null);try{const R=await(await fetch("http://localhost:3001/api/config",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(d)})).json();R.status==="success"?(v({type:"success",text:s("messages.savedSuccess")}),setTimeout(()=>{v(null)},3e3)):v({type:"error",text:R.message||s("messages.saveFailed")})}catch{v({type:"error",text:s("messages.networkError")})}finally{y(!1)}},Z=async()=>{try{const R=await(await fetch("http://localhost:3001/api/scheduler/run",{method:"POST"})).json();R.status==="success"?v({type:"success",text:s("messages.maintenanceSuccess")}):v({type:"error",text:R.message})}catch{v({type:"error",text:s("messages.networkError")})}},B=()=>{const R=(o.resolvedLanguage||o.language).startsWith("en")?"zh":"en";o.changeLanguage(R)},S=()=>(o.resolvedLanguage||o.language).startsWith("en")?"English":"中文";return a?C.jsx("div",{"trae-inspector-start-line":"237","trae-inspector-start-column":"4","trae-inspector-end-line":"585","trae-inspector-end-column":"10","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"fixed inset-0 bg-black/50 backdrop-blur-sm flex items-center justify-center z-50",children:C.jsxs("div",{"trae-inspector-start-line":"238","trae-inspector-start-column":"6","trae-inspector-end-line":"584","trae-inspector-end-column":"12","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"bg-white rounded-2xl shadow-xl w-full max-w-2xl overflow-hidden animate-in fade-in zoom-in duration-200 flex flex-col max-h-[90vh]",children:[C.jsxs("div",{"trae-inspector-start-line":"239","trae-inspector-start-column":"8","trae-inspector-end-line":"247","trae-inspector-end-column":"14","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"p-6 border-b border-gray-100 flex justify-between items-center",children:[C.jsxs("div",{"trae-inspector-start-line":"240","trae-inspector-start-column":"10","trae-inspector-end-line":"243","trae-inspector-end-column":"16","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"flex items-center gap-2 text-gray-800",children:[C.jsx(Rf,{size:20,className:"text-blue-600"}),C.jsx("h2",{"trae-inspector-start-line":"242","trae-inspector-start-column":"12","trae-inspector-end-line":"242","trae-inspector-end-column":"76","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"text-lg font-semibold",children:s("settings.title")})]}),C.jsx("button",{"trae-inspector-start-line":"244","trae-inspector-start-column":"10","trae-inspector-end-line":"246","trae-inspector-end-column":"19","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",onClick:r,className:"text-gray-400 hover:text-gray-600 transition-colors",children:C.jsx(Gc,{size:20})})]}),C.jsxs("div",{"trae-inspector-start-line":"249","trae-inspector-start-column":"8","trae-inspector-end-line":"268","trae-inspector-end-column":"14","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"flex border-b border-gray-100",children:[C.jsx("button",{"trae-inspector-start-line":"250","trae-inspector-start-column":"12","trae-inspector-end-line":"255","trae-inspector-end-column":"21","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",onClick:()=>f("general"),className:`px-6 py-3 text-sm font-medium transition-colors ${u==="general"?"text-blue-600 border-b-2 border-blue-600":"text-gray-500 hover:text-gray-700"}`,children:s("settings.tabs.general")}),C.jsx("button",{"trae-inspector-start-line":"256","trae-inspector-start-column":"12","trae-inspector-end-line":"261","trae-inspector-end-column":"21","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",onClick:()=>f("prompt"),className:`px-6 py-3 text-sm font-medium transition-colors ${u==="prompt"?"text-blue-600 border-b-2 border-blue-600":"text-gray-500 hover:text-gray-700"}`,children:s("settings.tabs.systemPrompt")}),C.jsx("button",{"trae-inspector-start-line":"262","trae-inspector-start-column":"12","trae-inspector-end-line":"267","trae-inspector-end-column":"21","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",onClick:()=>f("scheduler"),className:`px-6 py-3 text-sm font-medium transition-colors ${u==="scheduler"?"text-blue-600 border-b-2 border-blue-600":"text-gray-500 hover:text-gray-700"}`,children:s("settings.tabs.scheduler")})]}),C.jsxs("div",{"trae-inspector-start-line":"270","trae-inspector-start-column":"8","trae-inspector-end-line":"562","trae-inspector-end-column":"14","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"p-6 overflow-y-auto flex-1",children:[F&&C.jsx("div",{"trae-inspector-start-line":"272","trae-inspector-start-column":"12","trae-inspector-end-line":"274","trae-inspector-end-column":"18","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:`p-3 mb-4 rounded-lg text-sm ${F.type==="success"?"bg-green-50 text-green-700 border border-green-200":"bg-red-50 text-red-700 border border-red-200"}`,children:F.text}),u==="general"&&C.jsxs("div",{"trae-inspector-start-line":"278","trae-inspector-start-column":"14","trae-inspector-end-line":"376","trae-inspector-end-column":"20","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"space-y-4",children:[C.jsxs("div",{"trae-inspector-start-line":"279","trae-inspector-start-column":"16","trae-inspector-end-line":"290","trae-inspector-end-column":"22","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"flex items-center justify-between p-3 bg-gray-50 rounded-lg border border-gray-200",children:[C.jsxs("div",{"trae-inspector-start-line":"280","trae-inspector-start-column":"20","trae-inspector-end-line":"283","trae-inspector-end-column":"26","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"flex items-center gap-2 text-sm font-medium text-gray-700",children:[C.jsx(Rh,{size:16}),s("settings.language")]}),C.jsx("button",{"trae-inspector-start-line":"284","trae-inspector-start-column":"20","trae-inspector-end-line":"289","trae-inspector-end-column":"29","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",onClick:B,className:"px-3 py-1.5 text-sm bg-white border border-gray-300 rounded-md shadow-sm hover:bg-gray-50 transition-colors",children:S()})]}),C.jsxs("div",{"trae-inspector-start-line":"292","trae-inspector-start-column":"16","trae-inspector-end-line":"329","trae-inspector-end-column":"22","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"space-y-2",children:[C.jsx("label",{"trae-inspector-start-line":"293","trae-inspector-start-column":"20","trae-inspector-end-line":"293","trae-inspector-end-column":"113","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"text-sm font-medium text-gray-700",children:s("settings.general.provider")}),C.jsxs("select",{"trae-inspector-start-line":"294","trae-inspector-start-column":"20","trae-inspector-end-line":"328","trae-inspector-end-column":"29","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",value:d.provider||"openai",onChange:E=>{const R=E.target.value;let $=d.baseURL,Q=d.model;R==="deepseek"?($="https://api.deepseek.com",Q="deepseek-chat"):R==="minimax"?($="https://api.minimax.chat/v1",Q="abab6.5s-chat"):R==="doubao"?($="https://ark.cn-beijing.volces.com/api/v3",Q=""):R==="qwen"?($="https://dashscope-intl.aliyuncs.com/compatible-mode/v1",Q="qwen-plus"):R==="openai"&&($="https://api.openai.com/v1"),h({...d,provider:R,baseURL:$,model:Q})},className:"w-full p-2.5 bg-gray-50 border border-gray-200 rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500 transition-all text-sm",children:[C.jsx("option",{"trae-inspector-start-line":"322","trae-inspector-start-column":"24","trae-inspector-end-line":"322","trae-inspector-end-column":"75","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22text%22%3A%22OpenAI%20%2F%20Compatible%22%2C%22textStartLine%22%3A%22322%22%2C%22textStartColumn%22%3A%2247%22%2C%22textEndLine%22%3A%22322%22%2C%22textEndColumn%22%3A%2266%22%2C%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",value:"openai",children:"OpenAI / Compatible"}),C.jsx("option",{"trae-inspector-start-line":"323","trae-inspector-start-column":"24","trae-inspector-end-line":"323","trae-inspector-end-column":"65","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22text%22%3A%22Qwen%20(%E9%80%9A%E4%B9%89%E5%8D%83%E9%97%AE)%22%2C%22textStartLine%22%3A%22323%22%2C%22textStartColumn%22%3A%2245%22%2C%22textEndLine%22%3A%22323%22%2C%22textEndColumn%22%3A%2256%22%2C%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",value:"qwen",children:"Qwen (通义千问)"}),C.jsx("option",{"trae-inspector-start-line":"324","trae-inspector-start-column":"24","trae-inspector-end-line":"324","trae-inspector-end-column":"73","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22text%22%3A%22DeepSeek%20(%E6%B7%B1%E5%BA%A6%E6%B1%82%E7%B4%A2)%22%2C%22textStartLine%22%3A%22324%22%2C%22textStartColumn%22%3A%2249%22%2C%22textEndLine%22%3A%22324%22%2C%22textEndColumn%22%3A%2264%22%2C%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",value:"deepseek",children:"DeepSeek (深度求索)"}),C.jsx("option",{"trae-inspector-start-line":"325","trae-inspector-start-column":"24","trae-inspector-end-line":"325","trae-inspector-end-column":"69","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22text%22%3A%22MiniMax%20(%E6%B5%B7%E8%9E%BA)%22%2C%22textStartLine%22%3A%22325%22%2C%22textStartColumn%22%3A%2248%22%2C%22textEndLine%22%3A%22325%22%2C%22textEndColumn%22%3A%2260%22%2C%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",value:"minimax",children:"MiniMax (海螺)"}),C.jsx("option",{"trae-inspector-start-line":"326","trae-inspector-start-column":"24","trae-inspector-end-line":"326","trae-inspector-end-column":"72","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22text%22%3A%22Doubao%20(%E8%B1%86%E5%8C%85%2F%E7%81%AB%E5%B1%B1%E5%BC%95%E6%93%8E)%22%2C%22textStartLine%22%3A%22326%22%2C%22textStartColumn%22%3A%2247%22%2C%22textEndLine%22%3A%22326%22%2C%22textEndColumn%22%3A%2263%22%2C%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",value:"doubao",children:"Doubao (豆包/火山引擎)"}),C.jsx("option",{"trae-inspector-start-line":"327","trae-inspector-start-column":"24","trae-inspector-end-line":"327","trae-inspector-end-column":"68","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22text%22%3A%22Custom%20(%E8%87%AA%E5%AE%9A%E4%B9%89)%22%2C%22textStartLine%22%3A%22327%22%2C%22textStartColumn%22%3A%2247%22%2C%22textEndLine%22%3A%22327%22%2C%22textEndColumn%22%3A%2259%22%2C%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",value:"custom",children:"Custom (自定义)"})]})]}),C.jsxs("div",{"trae-inspector-start-line":"331","trae-inspector-start-column":"16","trae-inspector-end-line":"340","trae-inspector-end-column":"22","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"space-y-2",children:[C.jsx("label",{"trae-inspector-start-line":"332","trae-inspector-start-column":"20","trae-inspector-end-line":"332","trae-inspector-end-column":"111","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"text-sm font-medium text-gray-700",children:s("settings.general.apiKey")}),C.jsx("input",{"trae-inspector-start-line":"333","trae-inspector-start-column":"20","trae-inspector-end-line":"339","trae-inspector-end-column":"22","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",type:"password",value:d.apiKey,onChange:E=>h({...d,apiKey:E.target.value}),placeholder:"sk-...",className:"w-full p-2.5 bg-gray-50 border border-gray-200 rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500 transition-all text-sm"})]}),C.jsxs("div",{"trae-inspector-start-line":"342","trae-inspector-start-column":"16","trae-inspector-end-line":"351","trae-inspector-end-column":"22","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"space-y-2",children:[C.jsx("label",{"trae-inspector-start-line":"343","trae-inspector-start-column":"20","trae-inspector-end-line":"343","trae-inspector-end-column":"112","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"text-sm font-medium text-gray-700",children:s("settings.general.baseURL")}),C.jsx("input",{"trae-inspector-start-line":"344","trae-inspector-start-column":"20","trae-inspector-end-line":"350","trae-inspector-end-column":"22","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",type:"text",value:d.baseURL,onChange:E=>h({...d,baseURL:E.target.value}),placeholder:"https://api.openai.com/v1",className:"w-full p-2.5 bg-gray-50 border border-gray-200 rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500 transition-all text-sm"})]}),C.jsxs("div",{"trae-inspector-start-line":"353","trae-inspector-start-column":"16","trae-inspector-end-line":"362","trae-inspector-end-column":"22","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"space-y-2",children:[C.jsx("label",{"trae-inspector-start-line":"354","trae-inspector-start-column":"20","trae-inspector-end-line":"354","trae-inspector-end-column":"114","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"text-sm font-medium text-gray-700",children:s("settings.general.modelName")}),C.jsx("input",{"trae-inspector-start-line":"355","trae-inspector-start-column":"20","trae-inspector-end-line":"361","trae-inspector-end-column":"22","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",type:"text",value:d.model,onChange:E=>h({...d,model:E.target.value}),placeholder:"gpt-3.5-turbo",className:"w-full p-2.5 bg-gray-50 border border-gray-200 rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500 transition-all text-sm"})]}),C.jsxs("div",{"trae-inspector-start-line":"364","trae-inspector-start-column":"16","trae-inspector-end-line":"375","trae-inspector-end-column":"22","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"space-y-2",children:[C.jsxs("label",{"trae-inspector-start-line":"365","trae-inspector-start-column":"20","trae-inspector-end-line":"365","trae-inspector-end-column":"139","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"text-sm font-medium text-gray-700",children:[s("settings.general.temperature")," (",d.temperature,")"]}),C.jsx("input",{"trae-inspector-start-line":"366","trae-inspector-start-column":"20","trae-inspector-end-line":"374","trae-inspector-end-column":"22","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",type:"range",min:"0",max:"1",step:"0.1",value:d.temperature,onChange:E=>h({...d,temperature:parseFloat(E.target.value)}),className:"w-full h-2 bg-gray-200 rounded-lg appearance-none cursor-pointer accent-blue-600"})]})]}),u==="prompt"&&C.jsxs("div",{"trae-inspector-start-line":"380","trae-inspector-start-column":"14","trae-inspector-end-line":"462","trae-inspector-end-column":"20","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"space-y-4 h-full flex flex-col",children:[C.jsxs("div",{"trae-inspector-start-line":"381","trae-inspector-start-column":"18","trae-inspector-end-line":"384","trae-inspector-end-column":"24","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"flex items-center gap-2 mb-2 text-gray-600 text-sm",children:[C.jsx(zh,{size:16}),C.jsx("span",{"trae-inspector-start-line":"383","trae-inspector-start-column":"22","trae-inspector-end-line":"383","trae-inspector-end-column":"69","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",children:s("settings.prompt.description")})]}),C.jsxs("div",{"trae-inspector-start-line":"386","trae-inspector-start-column":"18","trae-inspector-end-line":"406","trae-inspector-end-column":"24","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"space-y-2",children:[C.jsx("label",{"trae-inspector-start-line":"387","trae-inspector-start-column":"22","trae-inspector-end-line":"387","trae-inspector-end-column":"102","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22text%22%3A%22Workspace%20Directory%22%2C%22textStartLine%22%3A%22387%22%2C%22textStartColumn%22%3A%2275%22%2C%22textEndLine%22%3A%22387%22%2C%22textEndColumn%22%3A%2294%22%2C%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"text-sm font-medium text-gray-700",children:"Workspace Directory"}),C.jsxs("div",{"trae-inspector-start-line":"388","trae-inspector-start-column":"22","trae-inspector-end-line":"402","trae-inspector-end-column":"28","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"flex gap-2",children:[C.jsx("input",{"trae-inspector-start-line":"389","trae-inspector-start-column":"24","trae-inspector-end-line":"395","trae-inspector-end-column":"26","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",type:"text",value:d.workspace,readOnly:!0,placeholder:"/path/to/your/project",className:"flex-1 p-2.5 bg-gray-50 border border-gray-200 rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500 transition-all text-sm font-mono cursor-not-allowed"}),C.jsx("button",{"trae-inspector-start-line":"396","trae-inspector-start-column":"24","trae-inspector-end-line":"401","trae-inspector-end-column":"33","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",onClick:ue,className:"px-3 py-2 bg-gray-100 border border-gray-200 rounded-lg hover:bg-gray-200 text-gray-700 transition-colors",children:C.jsx(Jc,{size:18})})]}),C.jsx("p",{"trae-inspector-start-line":"403","trae-inspector-start-column":"22","trae-inspector-end-line":"405","trae-inspector-end-column":"26","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22text%22%3A%22xiaozuoAssistant%20will%20use%20this%20path%20to%20understand%20your%20project%20context.%20Saving%20will%20append%2Fupdate%20this%20path%20in%20the%20System%20Prompt.%22%2C%22textStartLine%22%3A%22403%22%2C%22textStartColumn%22%3A%2259%22%2C%22textEndLine%22%3A%22405%22%2C%22textEndColumn%22%3A%2222%22%2C%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"text-xs text-gray-500",children:"xiaozuoAssistant will use this path to understand your project context. Saving will append/update this path in the System Prompt."})]}),D&&C.jsx("div",{"trae-inspector-start-line":"409","trae-inspector-start-column":"22","trae-inspector-end-line":"453","trae-inspector-end-column":"28","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"fixed inset-0 bg-black/20 z-[60] flex items-center justify-center p-4",children:C.jsxs("div",{"trae-inspector-start-line":"410","trae-inspector-start-column":"26","trae-inspector-end-line":"452","trae-inspector-end-column":"32","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"bg-white rounded-xl shadow-2xl w-full max-w-lg overflow-hidden flex flex-col max-h-[70vh]",children:[C.jsxs("div",{"trae-inspector-start-line":"411","trae-inspector-start-column":"30","trae-inspector-end-line":"417","trae-inspector-end-column":"36","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"p-4 border-b border-gray-100 flex justify-between items-center bg-gray-50",children:[C.jsxs("h3",{"trae-inspector-start-line":"412","trae-inspector-start-column":"34","trae-inspector-end-line":"415","trae-inspector-end-column":"39","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"font-medium text-gray-800 flex items-center gap-2",children:[C.jsx(Jc,{size:18,className:"text-blue-600"}),"Select Workspace"]}),C.jsx("button",{"trae-inspector-start-line":"416","trae-inspector-start-column":"34","trae-inspector-end-line":"416","trae-inspector-end-column":"156","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",onClick:()=>z(!1),children:C.jsx(Gc,{size:18,className:"text-gray-400 hover:text-gray-600"})})]}),C.jsx("div",{"trae-inspector-start-line":"418","trae-inspector-start-column":"30","trae-inspector-end-line":"420","trae-inspector-end-column":"36","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"p-2 bg-gray-50 border-b border-gray-100 text-xs font-mono text-gray-500 truncate px-4",children:V}),C.jsxs("div",{"trae-inspector-start-line":"421","trae-inspector-start-column":"30","trae-inspector-end-line":"445","trae-inspector-end-column":"36","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"flex-1 overflow-y-auto p-2",children:[me&&C.jsxs("button",{"trae-inspector-start-line":"423","trae-inspector-start-column":"38","trae-inspector-end-line":"429","trae-inspector-end-column":"47","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",onClick:()=>Y(me),className:"w-full flex items-center gap-2 px-3 py-2 hover:bg-gray-100 rounded-lg text-sm text-left mb-1 text-gray-600",children:[C.jsx(Eh,{size:16}),".."]}),L.length>0?L.map(E=>C.jsxs("button",{"trae-inspector-start-line":"433","trae-inspector-start-column":"38","trae-inspector-end-line":"440","trae-inspector-end-column":"47","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",onClick:()=>Y(E.path),className:"w-full flex items-center gap-2 px-3 py-2 hover:bg-blue-50 hover:text-blue-700 rounded-lg text-sm text-left group",children:[C.jsx(Ph,{size:16,className:"text-yellow-500 group-hover:text-yellow-600 fill-current"}),C.jsx("span",{"trae-inspector-start-line":"439","trae-inspector-start-column":"42","trae-inspector-end-line":"439","trae-inspector-end-column":"87","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"truncate",children:E.name})]},E.path)):C.jsx("div",{"trae-inspector-start-line":"443","trae-inspector-start-column":"36","trae-inspector-end-line":"443","trae-inspector-end-column":"114","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22text%22%3A%22No%20folders%20found%22%2C%22textStartLine%22%3A%22443%22%2C%22textStartColumn%22%3A%2292%22%2C%22textEndLine%22%3A%22443%22%2C%22textEndColumn%22%3A%22108%22%2C%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"text-center py-4 text-gray-400 text-sm",children:"No folders found"})]}),C.jsxs("div",{"trae-inspector-start-line":"446","trae-inspector-start-column":"30","trae-inspector-end-line":"451","trae-inspector-end-column":"36","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"p-4 border-t border-gray-100 flex justify-end gap-2 bg-gray-50",children:[C.jsx("button",{"trae-inspector-start-line":"447","trae-inspector-start-column":"34","trae-inspector-end-line":"447","trae-inspector-end-column":"177","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22text%22%3A%22Cancel%22%2C%22textStartLine%22%3A%22447%22%2C%22textStartColumn%22%3A%22162%22%2C%22textEndLine%22%3A%22447%22%2C%22textEndColumn%22%3A%22168%22%2C%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",onClick:()=>z(!1),className:"px-3 py-1.5 text-sm text-gray-600 hover:bg-gray-200 rounded-md",children:"Cancel"}),C.jsx("button",{"trae-inspector-start-line":"448","trae-inspector-start-column":"34","trae-inspector-end-line":"450","trae-inspector-end-column":"43","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22text%22%3A%22Select%20Current%20Folder%22%2C%22textStartLine%22%3A%22448%22%2C%22textStartColumn%22%3A%22184%22%2C%22textEndLine%22%3A%22450%22%2C%22textEndColumn%22%3A%2234%22%2C%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",onClick:()=>de(V),className:"px-3 py-1.5 text-sm bg-blue-600 text-white hover:bg-blue-700 rounded-md shadow-sm",children:"Select Current Folder"})]})]})}),C.jsx("textarea",{"trae-inspector-start-line":"456","trae-inspector-start-column":"18","trae-inspector-end-line":"461","trae-inspector-end-column":"20","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",value:d.systemPrompt,onChange:E=>h({...d,systemPrompt:E.target.value}),placeholder:s("settings.prompt.placeholder"),className:"w-full flex-1 min-h-[300px] p-4 bg-gray-50 border border-gray-200 rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500 transition-all text-sm font-mono leading-relaxed resize-none"})]}),u==="scheduler"&&C.jsxs("div",{"trae-inspector-start-line":"466","trae-inspector-start-column":"14","trae-inspector-end-line":"560","trae-inspector-end-column":"20","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"space-y-6",children:[C.jsxs("div",{"trae-inspector-start-line":"467","trae-inspector-start-column":"18","trae-inspector-end-line":"545","trae-inspector-end-column":"24","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"bg-blue-50 p-4 rounded-lg border border-blue-100",children:[C.jsxs("h3",{"trae-inspector-start-line":"468","trae-inspector-start-column":"22","trae-inspector-end-line":"471","trae-inspector-end-column":"27","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"font-medium text-blue-800 mb-2 flex items-center gap-2",children:[C.jsx(Lh,{size:16}),s("settings.scheduler.memoryMaintenance")]}),C.jsx("p",{"trae-inspector-start-line":"472","trae-inspector-start-column":"22","trae-inspector-end-line":"474","trae-inspector-end-column":"26","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"text-sm text-blue-600 mb-4",children:s("settings.scheduler.description")}),C.jsxs("div",{"trae-inspector-start-line":"476","trae-inspector-start-column":"22","trae-inspector-end-line":"544","trae-inspector-end-column":"28","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"space-y-4",children:[C.jsx("label",{"trae-inspector-start-line":"477","trae-inspector-start-column":"24","trae-inspector-end-line":"477","trae-inspector-end-column":"123","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"text-sm font-medium text-gray-700",children:s("settings.scheduler.cronSchedule")}),C.jsxs("div",{"trae-inspector-start-line":"479","trae-inspector-start-column":"24","trae-inspector-end-line":"522","trae-inspector-end-column":"30","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"flex gap-4 items-center",children:[C.jsxs("select",{"trae-inspector-start-line":"480","trae-inspector-start-column":"28","trae-inspector-end-line":"488","trae-inspector-end-column":"37","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",value:G,onChange:E=>Qe(E.target.value),className:"p-2.5 bg-gray-50 border border-gray-200 rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500 text-sm",children:[C.jsx("option",{"trae-inspector-start-line":"485","trae-inspector-start-column":"32","trae-inspector-end-line":"485","trae-inspector-end-column":"94","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",value:"daily",children:s("settings.scheduler.daily")}),C.jsx("option",{"trae-inspector-start-line":"486","trae-inspector-start-column":"32","trae-inspector-end-line":"486","trae-inspector-end-column":"96","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",value:"weekly",children:s("settings.scheduler.weekly")}),C.jsx("option",{"trae-inspector-start-line":"487","trae-inspector-start-column":"32","trae-inspector-end-line":"487","trae-inspector-end-column":"96","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",value:"custom",children:s("settings.scheduler.custom")})]}),G==="daily"&&C.jsx("input",{"trae-inspector-start-line":"491","trae-inspector-start-column":"32","trae-inspector-end-line":"496","trae-inspector-end-column":"34","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",type:"time",value:Se,onChange:E=>te(E.target.value),className:"p-2.5 bg-gray-50 border border-gray-200 rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500 text-sm"}),G==="weekly"&&C.jsxs(C.Fragment,{children:[C.jsxs("select",{"trae-inspector-start-line":"501","trae-inspector-start-column":"36","trae-inspector-end-line":"513","trae-inspector-end-column":"45","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",value:Ne,onChange:E=>W(E.target.value),className:"p-2.5 bg-gray-50 border border-gray-200 rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500 text-sm",children:[C.jsx("option",{"trae-inspector-start-line":"506","trae-inspector-start-column":"40","trae-inspector-end-line":"506","trae-inspector-end-column":"89","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",value:"0",children:s("weekdays.sunday")}),C.jsx("option",{"trae-inspector-start-line":"507","trae-inspector-start-column":"40","trae-inspector-end-line":"507","trae-inspector-end-column":"89","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",value:"1",children:s("weekdays.monday")}),C.jsx("option",{"trae-inspector-start-line":"508","trae-inspector-start-column":"40","trae-inspector-end-line":"508","trae-inspector-end-column":"90","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",value:"2",children:s("weekdays.tuesday")}),C.jsx("option",{"trae-inspector-start-line":"509","trae-inspector-start-column":"40","trae-inspector-end-line":"509","trae-inspector-end-column":"92","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",value:"3",children:s("weekdays.wednesday")}),C.jsx("option",{"trae-inspector-start-line":"510","trae-inspector-start-column":"40","trae-inspector-end-line":"510","trae-inspector-end-column":"91","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",value:"4",children:s("weekdays.thursday")}),C.jsx("option",{"trae-inspector-start-line":"511","trae-inspector-start-column":"40","trae-inspector-end-line":"511","trae-inspector-end-column":"89","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",value:"5",children:s("weekdays.friday")}),C.jsx("option",{"trae-inspector-start-line":"512","trae-inspector-start-column":"40","trae-inspector-end-line":"512","trae-inspector-end-column":"91","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",value:"6",children:s("weekdays.saturday")})]}),C.jsx("input",{"trae-inspector-start-line":"514","trae-inspector-start-column":"36","trae-inspector-end-line":"519","trae-inspector-end-column":"38","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",type:"time",value:Se,onChange:E=>te(E.target.value),className:"p-2.5 bg-gray-50 border border-gray-200 rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500 text-sm"})]})]}),G==="custom"&&C.jsxs("div",{"trae-inspector-start-line":"525","trae-inspector-start-column":"28","trae-inspector-end-line":"536","trae-inspector-end-column":"34","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"space-y-1",children:[C.jsx("input",{"trae-inspector-start-line":"526","trae-inspector-start-column":"32","trae-inspector-end-line":"532","trae-inspector-end-column":"34","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",type:"text",value:d.memoryMaintenanceCron,onChange:E=>h({...d,memoryMaintenanceCron:E.target.value}),placeholder:"0 0 * * *",className:"w-full p-2.5 bg-white border border-gray-200 rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500 transition-all text-sm font-mono"}),C.jsx("p",{"trae-inspector-start-line":"533","trae-inspector-start-column":"32","trae-inspector-end-line":"535","trae-inspector-end-column":"36","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"text-xs text-gray-500",children:s("settings.scheduler.cronHint")})]}),G!=="custom"&&C.jsxs("p",{"trae-inspector-start-line":"540","trae-inspector-start-column":"28","trae-inspector-end-line":"542","trae-inspector-end-column":"32","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"text-xs text-gray-500 font-mono",children:["Cron Expression: ",d.memoryMaintenanceCron]})]})]}),C.jsxs("div",{"trae-inspector-start-line":"547","trae-inspector-start-column":"18","trae-inspector-end-line":"559","trae-inspector-end-column":"24","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"bg-gray-50 p-4 rounded-lg border border-gray-200",children:[C.jsx("h3",{"trae-inspector-start-line":"548","trae-inspector-start-column":"22","trae-inspector-end-line":"548","trae-inspector-end-column":"113","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"font-medium text-gray-800 mb-2",children:s("settings.scheduler.manualTrigger")}),C.jsx("p",{"trae-inspector-start-line":"549","trae-inspector-start-column":"22","trae-inspector-end-line":"551","trae-inspector-end-column":"26","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"text-sm text-gray-500 mb-4",children:s("settings.scheduler.manualDescription")}),C.jsxs("button",{"trae-inspector-start-line":"552","trae-inspector-start-column":"22","trae-inspector-end-line":"558","trae-inspector-end-column":"31","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",onClick:Z,className:"px-4 py-2 text-sm font-medium text-white bg-teal-600 hover:bg-teal-700 rounded-lg shadow-sm transition-all flex items-center gap-2",children:[C.jsx(bh,{size:16}),s("settings.scheduler.runNow")]})]})]})]}),C.jsxs("div",{"trae-inspector-start-line":"564","trae-inspector-start-column":"8","trae-inspector-end-line":"583","trae-inspector-end-column":"14","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"p-6 border-t border-gray-100 bg-gray-50 flex justify-end gap-3",children:[C.jsx("button",{"trae-inspector-start-line":"565","trae-inspector-start-column":"10","trae-inspector-end-line":"570","trae-inspector-end-column":"19","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",onClick:r,className:"px-4 py-2 text-sm font-medium text-gray-600 hover:bg-gray-200 rounded-lg transition-colors",children:s("settings.buttons.close")}),C.jsx("button",{"trae-inspector-start-line":"571","trae-inspector-start-column":"10","trae-inspector-end-line":"582","trae-inspector-end-column":"19","trae-inspector-file-path":"client/components/SettingsModal.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",onClick:T,disabled:m,className:"px-4 py-2 text-sm font-medium text-white bg-blue-600 hover:bg-blue-700 rounded-lg shadow-sm transition-all flex items-center gap-2 disabled:opacity-70 disabled:cursor-not-allowed",children:m?s("settings.buttons.saving"):C.jsxs(C.Fragment,{children:[C.jsx(Hh,{size:16}),s("settings.buttons.save")]})})]})]})}):null},X2=()=>{const{t:a}=Ua(),{sessions:r,currentSessionId:s,setSessions:o,removeSession:u,setCurrentSessionId:f,setMessages:d}=Pf(),[h,m]=ne.useState(!1),y=async()=>{try{const L=await(await fetch("http://localhost:3001/api/sessions")).json();o(L)}catch(z){console.error("Failed to fetch sessions:",z)}};ne.useEffect(()=>{y()},[]);const F=async()=>{try{const L=await(await fetch("http://localhost:3001/api/sessions",{method:"POST"})).json();o([L,...r]),f(L.id),d([])}catch(z){console.error("Failed to create session:",z)}},v=async(z,L)=>{if(z.stopPropagation(),!!window.confirm(a("sessionList.deleteConfirm")))try{await fetch(`http://localhost:3001/api/sessions/${L}`,{method:"DELETE"}),u(L),s===L&&(f(null),d([]))}catch(M){console.error("Failed to delete session:",M)}},D=async z=>{f(z);try{const M=await(await fetch(`http://localhost:3001/api/sessions/${z}`)).json();d(M.messages||[])}catch(L){console.error("Failed to fetch session details:",L)}};return C.jsxs("div",{"trae-inspector-start-line":"70","trae-inspector-start-column":"4","trae-inspector-end-line":"134","trae-inspector-end-column":"10","trae-inspector-file-path":"client/components/SessionList.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"w-[260px] bg-gray-900 text-gray-300 h-full flex flex-col border-r border-black/10 transition-all duration-300 ease-in-out",children:[C.jsxs("div",{"trae-inspector-start-line":"71","trae-inspector-start-column":"6","trae-inspector-end-line":"85","trae-inspector-end-column":"12","trae-inspector-file-path":"client/components/SessionList.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"p-4 pt-6",children:[C.jsxs("div",{"trae-inspector-start-line":"72","trae-inspector-start-column":"8","trae-inspector-end-line":"74","trae-inspector-end-column":"14","trae-inspector-file-path":"client/components/SessionList.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"flex items-center gap-2 px-2 mb-6 text-white font-semibold text-xl tracking-tight",children:[C.jsx("span",{"trae-inspector-start-line":"73","trae-inspector-start-column":"11","trae-inspector-end-line":"73","trae-inspector-end-column":"47","trae-inspector-file-path":"client/components/SessionList.tsx","trae-inspector-static-props":"%7B%22text%22%3A%22%F0%9F%8D%87%22%2C%22textStartLine%22%3A%2273%22%2C%22textStartColumn%22%3A%2238%22%2C%22textEndLine%22%3A%2273%22%2C%22textEndColumn%22%3A%2240%22%2C%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"text-2xl",children:"🍇"})," ",a("sessionList.title")]}),C.jsxs("button",{"trae-inspector-start-line":"76","trae-inspector-start-column":"8","trae-inspector-end-line":"84","trae-inspector-end-column":"17","trae-inspector-file-path":"client/components/SessionList.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",onClick:F,className:"w-full flex items-center gap-3 px-3 py-3 rounded-lg border border-gray-700 hover:bg-gray-800 transition-colors duration-200 text-sm text-white mb-2 text-left group",children:[C.jsx("div",{"trae-inspector-start-line":"80","trae-inspector-start-column":"10","trae-inspector-end-line":"82","trae-inspector-end-column":"16","trae-inspector-file-path":"client/components/SessionList.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"p-1 bg-white text-black rounded-full group-hover:rotate-90 transition-transform duration-300",children:C.jsx(Xh,{size:14,strokeWidth:3})}),C.jsx("span",{"trae-inspector-start-line":"83","trae-inspector-start-column":"10","trae-inspector-end-line":"83","trae-inspector-end-column":"73","trae-inspector-file-path":"client/components/SessionList.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"font-medium",children:a("sessionList.newChat")})]})]}),C.jsxs("div",{"trae-inspector-start-line":"87","trae-inspector-start-column":"6","trae-inspector-end-line":"119","trae-inspector-end-column":"12","trae-inspector-file-path":"client/components/SessionList.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"flex-1 overflow-y-auto px-2 pb-2 custom-scrollbar",children:[C.jsx("div",{"trae-inspector-start-line":"88","trae-inspector-start-column":"8","trae-inspector-end-line":"88","trae-inspector-end-column":"127","trae-inspector-file-path":"client/components/SessionList.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"text-xs font-semibold text-gray-500 px-3 mb-2 uppercase tracking-wider",children:a("sessionList.recent")}),C.jsx("div",{"trae-inspector-start-line":"89","trae-inspector-start-column":"8","trae-inspector-end-line":"118","trae-inspector-end-column":"14","trae-inspector-file-path":"client/components/SessionList.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"space-y-1",children:r.map(z=>C.jsxs("button",{"trae-inspector-start-line":"91","trae-inspector-start-column":"12","trae-inspector-end-line":"116","trae-inspector-end-column":"21","trae-inspector-file-path":"client/components/SessionList.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",onClick:()=>D(z.id),className:`w-full group relative flex items-center gap-3 px-3 py-3 rounded-lg text-sm transition-all duration-200 text-left ${s===z.id?"bg-gray-800 text-white shadow-sm":"hover:bg-gray-800/50 hover:text-white"}`,children:[C.jsx(Uh,{size:16,className:s===z.id?"text-blue-400":"text-gray-500 group-hover:text-gray-400"}),C.jsx("div",{"trae-inspector-start-line":"101","trae-inspector-start-column":"14","trae-inspector-end-line":"109","trae-inspector-end-column":"20","trae-inspector-file-path":"client/components/SessionList.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"flex-1 overflow-hidden",children:C.jsx("div",{"trae-inspector-start-line":"102","trae-inspector-start-column":"16","trae-inspector-end-line":"108","trae-inspector-end-column":"22","trae-inspector-file-path":"client/components/SessionList.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"truncate font-medium",children:z.id==="default-session"?a("sessionList.defaultSession"):z.messages.length>0?z.messages[z.messages.length-1].content:a("sessionList.newConversation")})}),C.jsx("button",{"trae-inspector-start-line":"110","trae-inspector-start-column":"14","trae-inspector-end-line":"115","trae-inspector-end-column":"23","trae-inspector-file-path":"client/components/SessionList.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",onClick:L=>v(L,z.id),className:`opacity-0 group-hover:opacity-100 p-1 hover:text-red-400 transition-opacity ${z.id==="default-session"?"hidden":""}`,children:C.jsx(Qh,{size:14})})]},z.id))})]}),C.jsx("div",{"trae-inspector-start-line":"121","trae-inspector-start-column":"6","trae-inspector-end-line":"131","trae-inspector-end-column":"12","trae-inspector-file-path":"client/components/SessionList.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"p-4 border-t border-gray-800",children:C.jsxs("div",{"trae-inspector-start-line":"122","trae-inspector-start-column":"8","trae-inspector-end-line":"130","trae-inspector-end-column":"14","trae-inspector-file-path":"client/components/SessionList.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",onClick:()=>m(!0),className:"flex items-center gap-3 px-2 py-2 rounded-lg hover:bg-gray-800 transition-colors cursor-pointer group",children:[C.jsx("div",{"trae-inspector-start-line":"126","trae-inspector-start-column":"12","trae-inspector-end-line":"128","trae-inspector-end-column":"18","trae-inspector-file-path":"client/components/SessionList.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"w-8 h-8 rounded-full bg-gray-800 border border-gray-700 flex items-center justify-center text-gray-400 group-hover:text-white group-hover:border-gray-600 transition-all",children:C.jsx(Rf,{size:16})}),C.jsx("div",{"trae-inspector-start-line":"129","trae-inspector-start-column":"12","trae-inspector-end-line":"129","trae-inspector-end-column":"137","trae-inspector-file-path":"client/components/SessionList.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"text-sm font-medium text-gray-400 group-hover:text-white transition-colors",children:a("sessionList.settings")})]})}),C.jsx($2,{isOpen:h,onClose:()=>m(!1)})]})},Lt=Object.create(null);Lt.open="0";Lt.close="1";Lt.ping="2";Lt.pong="3";Lt.message="4";Lt.upgrade="5";Lt.noop="6";const li=Object.create(null);Object.keys(Lt).forEach(a=>{li[Lt[a]]=a});const Oa={type:"error",data:"parser error"},Xf=typeof Blob=="function"||typeof Blob<"u"&&Object.prototype.toString.call(Blob)==="[object BlobConstructor]",Vf=typeof ArrayBuffer=="function",Hf=a=>typeof ArrayBuffer.isView=="function"?ArrayBuffer.isView(a):a&&a.buffer instanceof ArrayBuffer,Ia=({type:a,data:r},s,o)=>Xf&&r instanceof Blob?s?o(r):vf(r,o):Vf&&(r instanceof ArrayBuffer||Hf(r))?s?o(r):vf(new Blob([r]),o):o(Lt[a]+(r||"")),vf=(a,r)=>{const s=new FileReader;return s.onload=function(){const o=s.result.split(",")[1];r("b"+(o||""))},s.readAsDataURL(a)};function xf(a){return a instanceof Uint8Array?a:a instanceof ArrayBuffer?new Uint8Array(a):new Uint8Array(a.buffer,a.byteOffset,a.byteLength)}let Fa;function V2(a,r){if(Xf&&a.data instanceof Blob)return a.data.arrayBuffer().then(xf).then(r);if(Vf&&(a.data instanceof ArrayBuffer||Hf(a.data)))return r(xf(a.data));Ia(a,!1,s=>{Fa||(Fa=new TextEncoder),r(Fa.encode(s))})}const wf="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",br=typeof Uint8Array>"u"?[]:new Uint8Array(256);for(let a=0;a<wf.length;a++)br[wf.charCodeAt(a)]=a;const H2=a=>{let r=a.length*.75,s=a.length,o,u=0,f,d,h,m;a[a.length-1]==="="&&(r--,a[a.length-2]==="="&&r--);const y=new ArrayBuffer(r),F=new Uint8Array(y);for(o=0;o<s;o+=4)f=br[a.charCodeAt(o)],d=br[a.charCodeAt(o+1)],h=br[a.charCodeAt(o+2)],m=br[a.charCodeAt(o+3)],F[u++]=f<<2|d>>4,F[u++]=(d&15)<<4|h>>2,F[u++]=(h&3)<<6|m&63;return y},Z2=typeof ArrayBuffer=="function",ba=(a,r)=>{if(typeof a!="string")return{type:"message",data:Zf(a,r)};const s=a.charAt(0);return s==="b"?{type:"message",data:W2(a.substring(1),r)}:li[s]?a.length>1?{type:li[s],data:a.substring(1)}:{type:li[s]}:Oa},W2=(a,r)=>{if(Z2){const s=H2(a);return Zf(s,r)}else return{base64:!0,data:a}},Zf=(a,r)=>{switch(r){case"blob":return a instanceof Blob?a:new Blob([a]);case"arraybuffer":default:return a instanceof ArrayBuffer?a:a.buffer}},Wf="",K2=(a,r)=>{const s=a.length,o=new Array(s);let u=0;a.forEach((f,d)=>{Ia(f,!1,h=>{o[d]=h,++u===s&&r(o.join(Wf))})})},q2=(a,r)=>{const s=a.split(Wf),o=[];for(let u=0;u<s.length;u++){const f=ba(s[u],r);if(o.push(f),f.type==="error")break}return o};function Q2(){return new TransformStream({transform(a,r){V2(a,s=>{const o=s.length;let u;if(o<126)u=new Uint8Array(1),new DataView(u.buffer).setUint8(0,o);else if(o<65536){u=new Uint8Array(3);const f=new DataView(u.buffer);f.setUint8(0,126),f.setUint16(1,o)}else{u=new Uint8Array(9);const f=new DataView(u.buffer);f.setUint8(0,127),f.setBigUint64(1,BigInt(o))}a.data&&typeof a.data!="string"&&(u[0]|=128),r.enqueue(u),r.enqueue(s)})}})}let Ea;function oi(a){return a.reduce((r,s)=>r+s.length,0)}function ai(a,r){if(a[0].length===r)return a.shift();const s=new Uint8Array(r);let o=0;for(let u=0;u<r;u++)s[u]=a[0][o++],o===a[0].length&&(a.shift(),o=0);return a.length&&o<a[0].length&&(a[0]=a[0].slice(o)),s}function Y2(a,r){Ea||(Ea=new TextDecoder);const s=[];let o=0,u=-1,f=!1;return new TransformStream({transform(d,h){for(s.push(d);;){if(o===0){if(oi(s)<1)break;const m=ai(s,1);f=(m[0]&128)===128,u=m[0]&127,u<126?o=3:u===126?o=1:o=2}else if(o===1){if(oi(s)<2)break;const m=ai(s,2);u=new DataView(m.buffer,m.byteOffset,m.length).getUint16(0),o=3}else if(o===2){if(oi(s)<8)break;const m=ai(s,8),y=new DataView(m.buffer,m.byteOffset,m.length),F=y.getUint32(0);if(F>Math.pow(2,21)-1){h.enqueue(Oa);break}u=F*Math.pow(2,32)+y.getUint32(4),o=3}else{if(oi(s)<u)break;const m=ai(s,u);h.enqueue(ba(f?m:Ea.decode(m),r)),o=0}if(u===0||u>a){h.enqueue(Oa);break}}}})}const Kf=4;function je(a){if(a)return J2(a)}function J2(a){for(var r in je.prototype)a[r]=je.prototype[r];return a}je.prototype.on=je.prototype.addEventListener=function(a,r){return this._callbacks=this._callbacks||{},(this._callbacks["$"+a]=this._callbacks["$"+a]||[]).push(r),this};je.prototype.once=function(a,r){function s(){this.off(a,s),r.apply(this,arguments)}return s.fn=r,this.on(a,s),this};je.prototype.off=je.prototype.removeListener=je.prototype.removeAllListeners=je.prototype.removeEventListener=function(a,r){if(this._callbacks=this._callbacks||{},arguments.length==0)return this._callbacks={},this;var s=this._callbacks["$"+a];if(!s)return this;if(arguments.length==1)return delete this._callbacks["$"+a],this;for(var o,u=0;u<s.length;u++)if(o=s[u],o===r||o.fn===r){s.splice(u,1);break}return s.length===0&&delete this._callbacks["$"+a],this};je.prototype.emit=function(a){this._callbacks=this._callbacks||{};for(var r=new Array(arguments.length-1),s=this._callbacks["$"+a],o=1;o<arguments.length;o++)r[o-1]=arguments[o];if(s){s=s.slice(0);for(var o=0,u=s.length;o<u;++o)s[o].apply(this,r)}return this};je.prototype.emitReserved=je.prototype.emit;je.prototype.listeners=function(a){return this._callbacks=this._callbacks||{},this._callbacks["$"+a]||[]};je.prototype.hasListeners=function(a){return!!this.listeners(a).length};const vi=typeof Promise=="function"&&typeof Promise.resolve=="function"?r=>Promise.resolve().then(r):(r,s)=>s(r,0),ht=typeof self<"u"?self:typeof window<"u"?window:Function("return this")(),G2="arraybuffer";function qf(a,...r){return r.reduce((s,o)=>(a.hasOwnProperty(o)&&(s[o]=a[o]),s),{})}const em=ht.setTimeout,tm=ht.clearTimeout;function xi(a,r){r.useNativeTimers?(a.setTimeoutFn=em.bind(ht),a.clearTimeoutFn=tm.bind(ht)):(a.setTimeoutFn=ht.setTimeout.bind(ht),a.clearTimeoutFn=ht.clearTimeout.bind(ht))}const nm=1.33;function rm(a){return typeof a=="string"?sm(a):Math.ceil((a.byteLength||a.size)*nm)}function sm(a){let r=0,s=0;for(let o=0,u=a.length;o<u;o++)r=a.charCodeAt(o),r<128?s+=1:r<2048?s+=2:r<55296||r>=57344?s+=3:(o++,s+=4);return s}function Qf(){return Date.now().toString(36).substring(3)+Math.random().toString(36).substring(2,5)}function im(a){let r="";for(let s in a)a.hasOwnProperty(s)&&(r.length&&(r+="&"),r+=encodeURIComponent(s)+"="+encodeURIComponent(a[s]));return r}function om(a){let r={},s=a.split("&");for(let o=0,u=s.length;o<u;o++){let f=s[o].split("=");r[decodeURIComponent(f[0])]=decodeURIComponent(f[1])}return r}class am extends Error{constructor(r,s,o){super(r),this.description=s,this.context=o,this.type="TransportError"}}class $a extends je{constructor(r){super(),this.writable=!1,xi(this,r),this.opts=r,this.query=r.query,this.socket=r.socket,this.supportsBinary=!r.forceBase64}onError(r,s,o){return super.emitReserved("error",new am(r,s,o)),this}open(){return this.readyState="opening",this.doOpen(),this}close(){return(this.readyState==="opening"||this.readyState==="open")&&(this.doClose(),this.onClose()),this}send(r){this.readyState==="open"&&this.write(r)}onOpen(){this.readyState="open",this.writable=!0,super.emitReserved("open")}onData(r){const s=ba(r,this.socket.binaryType);this.onPacket(s)}onPacket(r){super.emitReserved("packet",r)}onClose(r){this.readyState="closed",super.emitReserved("close",r)}pause(r){}createUri(r,s={}){return r+"://"+this._hostname()+this._port()+this.opts.path+this._query(s)}_hostname(){const r=this.opts.hostname;return r.indexOf(":")===-1?r:"["+r+"]"}_port(){return this.opts.port&&(this.opts.secure&&Number(this.opts.port)!==443||!this.opts.secure&&Number(this.opts.port)!==80)?":"+this.opts.port:""}_query(r){const s=im(r);return s.length?"?"+s:""}}class lm extends $a{constructor(){super(...arguments),this._polling=!1}get name(){return"polling"}doOpen(){this._poll()}pause(r){this.readyState="pausing";const s=()=>{this.readyState="paused",r()};if(this._polling||!this.writable){let o=0;this._polling&&(o++,this.once("pollComplete",function(){--o||s()})),this.writable||(o++,this.once("drain",function(){--o||s()}))}else s()}_poll(){this._polling=!0,this.doPoll(),this.emitReserved("poll")}onData(r){const s=o=>{if(this.readyState==="opening"&&o.type==="open"&&this.onOpen(),o.type==="close")return this.onClose({description:"transport closed by the server"}),!1;this.onPacket(o)};q2(r,this.socket.binaryType).forEach(s),this.readyState!=="closed"&&(this._polling=!1,this.emitReserved("pollComplete"),this.readyState==="open"&&this._poll())}doClose(){const r=()=>{this.write([{type:"close"}])};this.readyState==="open"?r():this.once("open",r)}write(r){this.writable=!1,K2(r,s=>{this.doWrite(s,()=>{this.writable=!0,this.emitReserved("drain")})})}uri(){const r=this.opts.secure?"https":"http",s=this.query||{};return this.opts.timestampRequests!==!1&&(s[this.opts.timestampParam]=Qf()),!this.supportsBinary&&!s.sid&&(s.b64=1),this.createUri(r,s)}}let Yf=!1;try{Yf=typeof XMLHttpRequest<"u"&&"withCredentials"in new XMLHttpRequest}catch{}const um=Yf;function cm(){}class fm extends lm{constructor(r){if(super(r),typeof location<"u"){const s=location.protocol==="https:";let o=location.port;o||(o=s?"443":"80"),this.xd=typeof location<"u"&&r.hostname!==location.hostname||o!==r.port}}doWrite(r,s){const o=this.request({method:"POST",data:r});o.on("success",s),o.on("error",(u,f)=>{this.onError("xhr post error",u,f)})}doPoll(){const r=this.request();r.on("data",this.onData.bind(this)),r.on("error",(s,o)=>{this.onError("xhr poll error",s,o)}),this.pollXhr=r}}class Dt extends je{constructor(r,s,o){super(),this.createRequest=r,xi(this,o),this._opts=o,this._method=o.method||"GET",this._uri=s,this._data=o.data!==void 0?o.data:null,this._create()}_create(){var r;const s=qf(this._opts,"agent","pfx","key","passphrase","cert","ca","ciphers","rejectUnauthorized","autoUnref");s.xdomain=!!this._opts.xd;const o=this._xhr=this.createRequest(s);try{o.open(this._method,this._uri,!0);try{if(this._opts.extraHeaders){o.setDisableHeaderCheck&&o.setDisableHeaderCheck(!0);for(let u in this._opts.extraHeaders)this._opts.extraHeaders.hasOwnProperty(u)&&o.setRequestHeader(u,this._opts.extraHeaders[u])}}catch{}if(this._method==="POST")try{o.setRequestHeader("Content-type","text/plain;charset=UTF-8")}catch{}try{o.setRequestHeader("Accept","*/*")}catch{}(r=this._opts.cookieJar)===null||r===void 0||r.addCookies(o),"withCredentials"in o&&(o.withCredentials=this._opts.withCredentials),this._opts.requestTimeout&&(o.timeout=this._opts.requestTimeout),o.onreadystatechange=()=>{var u;o.readyState===3&&((u=this._opts.cookieJar)===null||u===void 0||u.parseCookies(o.getResponseHeader("set-cookie"))),o.readyState===4&&(o.status===200||o.status===1223?this._onLoad():this.setTimeoutFn(()=>{this._onError(typeof o.status=="number"?o.status:0)},0))},o.send(this._data)}catch(u){this.setTimeoutFn(()=>{this._onError(u)},0);return}typeof document<"u"&&(this._index=Dt.requestsCount++,Dt.requests[this._index]=this)}_onError(r){this.emitReserved("error",r,this._xhr),this._cleanup(!0)}_cleanup(r){if(!(typeof this._xhr>"u"||this._xhr===null)){if(this._xhr.onreadystatechange=cm,r)try{this._xhr.abort()}catch{}typeof document<"u"&&delete Dt.requests[this._index],this._xhr=null}}_onLoad(){const r=this._xhr.responseText;r!==null&&(this.emitReserved("data",r),this.emitReserved("success"),this._cleanup())}abort(){this._cleanup()}}Dt.requestsCount=0;Dt.requests={};if(typeof document<"u"){if(typeof attachEvent=="function")attachEvent("onunload",Sf);else if(typeof addEventListener=="function"){const a="onpagehide"in ht?"pagehide":"unload";addEventListener(a,Sf,!1)}}function Sf(){for(let a in Dt.requests)Dt.requests.hasOwnProperty(a)&&Dt.requests[a].abort()}const pm=(function(){const a=Jf({xdomain:!1});return a&&a.responseType!==null})();class dm extends fm{constructor(r){super(r);const s=r&&r.forceBase64;this.supportsBinary=pm&&!s}request(r={}){return Object.assign(r,{xd:this.xd},this.opts),new Dt(Jf,this.uri(),r)}}function Jf(a){const r=a.xdomain;try{if(typeof XMLHttpRequest<"u"&&(!r||um))return new XMLHttpRequest}catch{}if(!r)try{return new ht[["Active"].concat("Object").join("X")]("Microsoft.XMLHTTP")}catch{}}const Gf=typeof navigator<"u"&&typeof navigator.product=="string"&&navigator.product.toLowerCase()==="reactnative";class hm extends $a{get name(){return"websocket"}doOpen(){const r=this.uri(),s=this.opts.protocols,o=Gf?{}:qf(this.opts,"agent","perMessageDeflate","pfx","key","passphrase","cert","ca","ciphers","rejectUnauthorized","localAddress","protocolVersion","origin","maxPayload","family","checkServerIdentity");this.opts.extraHeaders&&(o.headers=this.opts.extraHeaders);try{this.ws=this.createSocket(r,s,o)}catch(u){return this.emitReserved("error",u)}this.ws.binaryType=this.socket.binaryType,this.addEventListeners()}addEventListeners(){this.ws.onopen=()=>{this.opts.autoUnref&&this.ws._socket.unref(),this.onOpen()},this.ws.onclose=r=>this.onClose({description:"websocket connection closed",context:r}),this.ws.onmessage=r=>this.onData(r.data),this.ws.onerror=r=>this.onError("websocket error",r)}write(r){this.writable=!1;for(let s=0;s<r.length;s++){const o=r[s],u=s===r.length-1;Ia(o,this.supportsBinary,f=>{try{this.doWrite(o,f)}catch{}u&&vi(()=>{this.writable=!0,this.emitReserved("drain")},this.setTimeoutFn)})}}doClose(){typeof this.ws<"u"&&(this.ws.onerror=()=>{},this.ws.close(),this.ws=null)}uri(){const r=this.opts.secure?"wss":"ws",s=this.query||{};return this.opts.timestampRequests&&(s[this.opts.timestampParam]=Qf()),this.supportsBinary||(s.b64=1),this.createUri(r,s)}}const _a=ht.WebSocket||ht.MozWebSocket;class mm extends hm{createSocket(r,s,o){return Gf?new _a(r,s,o):s?new _a(r,s):new _a(r)}doWrite(r,s){this.ws.send(s)}}class gm extends $a{get name(){return"webtransport"}doOpen(){try{this._transport=new WebTransport(this.createUri("https"),this.opts.transportOptions[this.name])}catch(r){return this.emitReserved("error",r)}this._transport.closed.then(()=>{this.onClose()}).catch(r=>{this.onError("webtransport error",r)}),this._transport.ready.then(()=>{this._transport.createBidirectionalStream().then(r=>{const s=Y2(Number.MAX_SAFE_INTEGER,this.socket.binaryType),o=r.readable.pipeThrough(s).getReader(),u=Q2();u.readable.pipeTo(r.writable),this._writer=u.writable.getWriter();const f=()=>{o.read().then(({done:h,value:m})=>{h||(this.onPacket(m),f())}).catch(h=>{})};f();const d={type:"open"};this.query.sid&&(d.data=`{"sid":"${this.query.sid}"}`),this._writer.write(d).then(()=>this.onOpen())})})}write(r){this.writable=!1;for(let s=0;s<r.length;s++){const o=r[s],u=s===r.length-1;this._writer.write(o).then(()=>{u&&vi(()=>{this.writable=!0,this.emitReserved("drain")},this.setTimeoutFn)})}}doClose(){var r;(r=this._transport)===null||r===void 0||r.close()}}const ym={websocket:mm,webtransport:gm,polling:dm},vm=/^(?:(?![^:@\/?#]+:[^:@\/]*@)(http|https|ws|wss):\/\/)?((?:(([^:@\/?#]*)(?::([^:@\/?#]*))?)?@)?((?:[a-f0-9]{0,4}:){2,7}[a-f0-9]{0,4}|[^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/,xm=["source","protocol","authority","userInfo","user","password","host","port","relative","path","directory","file","query","anchor"];function Aa(a){if(a.length>8e3)throw"URI too long";const r=a,s=a.indexOf("["),o=a.indexOf("]");s!=-1&&o!=-1&&(a=a.substring(0,s)+a.substring(s,o).replace(/:/g,";")+a.substring(o,a.length));let u=vm.exec(a||""),f={},d=14;for(;d--;)f[xm[d]]=u[d]||"";return s!=-1&&o!=-1&&(f.source=r,f.host=f.host.substring(1,f.host.length-1).replace(/;/g,":"),f.authority=f.authority.replace("[","").replace("]","").replace(/;/g,":"),f.ipv6uri=!0),f.pathNames=wm(f,f.path),f.queryKey=Sm(f,f.query),f}function wm(a,r){const s=/\/{2,9}/g,o=r.replace(s,"/").split("/");return(r.slice(0,1)=="/"||r.length===0)&&o.splice(0,1),r.slice(-1)=="/"&&o.splice(o.length-1,1),o}function Sm(a,r){const s={};return r.replace(/(?:^|&)([^&=]*)=?([^&]*)/g,function(o,u,f){u&&(s[u]=f)}),s}const Pa=typeof addEventListener=="function"&&typeof removeEventListener=="function",ui=[];Pa&&addEventListener("offline",()=>{ui.forEach(a=>a())},!1);class sn extends je{constructor(r,s){if(super(),this.binaryType=G2,this.writeBuffer=[],this._prevBufferLen=0,this._pingInterval=-1,this._pingTimeout=-1,this._maxPayload=-1,this._pingTimeoutTime=1/0,r&&typeof r=="object"&&(s=r,r=null),r){const o=Aa(r);s.hostname=o.host,s.secure=o.protocol==="https"||o.protocol==="wss",s.port=o.port,o.query&&(s.query=o.query)}else s.host&&(s.hostname=Aa(s.host).host);xi(this,s),this.secure=s.secure!=null?s.secure:typeof location<"u"&&location.protocol==="https:",s.hostname&&!s.port&&(s.port=this.secure?"443":"80"),this.hostname=s.hostname||(typeof location<"u"?location.hostname:"localhost"),this.port=s.port||(typeof location<"u"&&location.port?location.port:this.secure?"443":"80"),this.transports=[],this._transportsByName={},s.transports.forEach(o=>{const u=o.prototype.name;this.transports.push(u),this._transportsByName[u]=o}),this.opts=Object.assign({path:"/engine.io",agent:!1,withCredentials:!1,upgrade:!0,timestampParam:"t",rememberUpgrade:!1,addTrailingSlash:!0,rejectUnauthorized:!0,perMessageDeflate:{threshold:1024},transportOptions:{},closeOnBeforeunload:!1},s),this.opts.path=this.opts.path.replace(/\/$/,"")+(this.opts.addTrailingSlash?"/":""),typeof this.opts.query=="string"&&(this.opts.query=om(this.opts.query)),Pa&&(this.opts.closeOnBeforeunload&&(this._beforeunloadEventListener=()=>{this.transport&&(this.transport.removeAllListeners(),this.transport.close())},addEventListener("beforeunload",this._beforeunloadEventListener,!1)),this.hostname!=="localhost"&&(this._offlineEventListener=()=>{this._onClose("transport close",{description:"network connection lost"})},ui.push(this._offlineEventListener))),this.opts.withCredentials&&(this._cookieJar=void 0),this._open()}createTransport(r){const s=Object.assign({},this.opts.query);s.EIO=Kf,s.transport=r,this.id&&(s.sid=this.id);const o=Object.assign({},this.opts,{query:s,socket:this,hostname:this.hostname,secure:this.secure,port:this.port},this.opts.transportOptions[r]);return new this._transportsByName[r](o)}_open(){if(this.transports.length===0){this.setTimeoutFn(()=>{this.emitReserved("error","No transports available")},0);return}const r=this.opts.rememberUpgrade&&sn.priorWebsocketSuccess&&this.transports.indexOf("websocket")!==-1?"websocket":this.transports[0];this.readyState="opening";const s=this.createTransport(r);s.open(),this.setTransport(s)}setTransport(r){this.transport&&this.transport.removeAllListeners(),this.transport=r,r.on("drain",this._onDrain.bind(this)).on("packet",this._onPacket.bind(this)).on("error",this._onError.bind(this)).on("close",s=>this._onClose("transport close",s))}onOpen(){this.readyState="open",sn.priorWebsocketSuccess=this.transport.name==="websocket",this.emitReserved("open"),this.flush()}_onPacket(r){if(this.readyState==="opening"||this.readyState==="open"||this.readyState==="closing")switch(this.emitReserved("packet",r),this.emitReserved("heartbeat"),r.type){case"open":this.onHandshake(JSON.parse(r.data));break;case"ping":this._sendPacket("pong"),this.emitReserved("ping"),this.emitReserved("pong"),this._resetPingTimeout();break;case"error":const s=new Error("server error");s.code=r.data,this._onError(s);break;case"message":this.emitReserved("data",r.data),this.emitReserved("message",r.data);break}}onHandshake(r){this.emitReserved("handshake",r),this.id=r.sid,this.transport.query.sid=r.sid,this._pingInterval=r.pingInterval,this._pingTimeout=r.pingTimeout,this._maxPayload=r.maxPayload,this.onOpen(),this.readyState!=="closed"&&this._resetPingTimeout()}_resetPingTimeout(){this.clearTimeoutFn(this._pingTimeoutTimer);const r=this._pingInterval+this._pingTimeout;this._pingTimeoutTime=Date.now()+r,this._pingTimeoutTimer=this.setTimeoutFn(()=>{this._onClose("ping timeout")},r),this.opts.autoUnref&&this._pingTimeoutTimer.unref()}_onDrain(){this.writeBuffer.splice(0,this._prevBufferLen),this._prevBufferLen=0,this.writeBuffer.length===0?this.emitReserved("drain"):this.flush()}flush(){if(this.readyState!=="closed"&&this.transport.writable&&!this.upgrading&&this.writeBuffer.length){const r=this._getWritablePackets();this.transport.send(r),this._prevBufferLen=r.length,this.emitReserved("flush")}}_getWritablePackets(){if(!(this._maxPayload&&this.transport.name==="polling"&&this.writeBuffer.length>1))return this.writeBuffer;let s=1;for(let o=0;o<this.writeBuffer.length;o++){const u=this.writeBuffer[o].data;if(u&&(s+=rm(u)),o>0&&s>this._maxPayload)return this.writeBuffer.slice(0,o);s+=2}return this.writeBuffer}_hasPingExpired(){if(!this._pingTimeoutTime)return!0;const r=Date.now()>this._pingTimeoutTime;return r&&(this._pingTimeoutTime=0,vi(()=>{this._onClose("ping timeout")},this.setTimeoutFn)),r}write(r,s,o){return this._sendPacket("message",r,s,o),this}send(r,s,o){return this._sendPacket("message",r,s,o),this}_sendPacket(r,s,o,u){if(typeof s=="function"&&(u=s,s=void 0),typeof o=="function"&&(u=o,o=null),this.readyState==="closing"||this.readyState==="closed")return;o=o||{},o.compress=o.compress!==!1;const f={type:r,data:s,options:o};this.emitReserved("packetCreate",f),this.writeBuffer.push(f),u&&this.once("flush",u),this.flush()}close(){const r=()=>{this._onClose("forced close"),this.transport.close()},s=()=>{this.off("upgrade",s),this.off("upgradeError",s),r()},o=()=>{this.once("upgrade",s),this.once("upgradeError",s)};return(this.readyState==="opening"||this.readyState==="open")&&(this.readyState="closing",this.writeBuffer.length?this.once("drain",()=>{this.upgrading?o():r()}):this.upgrading?o():r()),this}_onError(r){if(sn.priorWebsocketSuccess=!1,this.opts.tryAllTransports&&this.transports.length>1&&this.readyState==="opening")return this.transports.shift(),this._open();this.emitReserved("error",r),this._onClose("transport error",r)}_onClose(r,s){if(this.readyState==="opening"||this.readyState==="open"||this.readyState==="closing"){if(this.clearTimeoutFn(this._pingTimeoutTimer),this.transport.removeAllListeners("close"),this.transport.close(),this.transport.removeAllListeners(),Pa&&(this._beforeunloadEventListener&&removeEventListener("beforeunload",this._beforeunloadEventListener,!1),this._offlineEventListener)){const o=ui.indexOf(this._offlineEventListener);o!==-1&&ui.splice(o,1)}this.readyState="closed",this.id=null,this.emitReserved("close",r,s),this.writeBuffer=[],this._prevBufferLen=0}}}sn.protocol=Kf;class Cm extends sn{constructor(){super(...arguments),this._upgrades=[]}onOpen(){if(super.onOpen(),this.readyState==="open"&&this.opts.upgrade)for(let r=0;r<this._upgrades.length;r++)this._probe(this._upgrades[r])}_probe(r){let s=this.createTransport(r),o=!1;sn.priorWebsocketSuccess=!1;const u=()=>{o||(s.send([{type:"ping",data:"probe"}]),s.once("packet",v=>{if(!o)if(v.type==="pong"&&v.data==="probe"){if(this.upgrading=!0,this.emitReserved("upgrading",s),!s)return;sn.priorWebsocketSuccess=s.name==="websocket",this.transport.pause(()=>{o||this.readyState!=="closed"&&(F(),this.setTransport(s),s.send([{type:"upgrade"}]),this.emitReserved("upgrade",s),s=null,this.upgrading=!1,this.flush())})}else{const D=new Error("probe error");D.transport=s.name,this.emitReserved("upgradeError",D)}}))};function f(){o||(o=!0,F(),s.close(),s=null)}const d=v=>{const D=new Error("probe error: "+v);D.transport=s.name,f(),this.emitReserved("upgradeError",D)};function h(){d("transport closed")}function m(){d("socket closed")}function y(v){s&&v.name!==s.name&&f()}const F=()=>{s.removeListener("open",u),s.removeListener("error",d),s.removeListener("close",h),this.off("close",m),this.off("upgrading",y)};s.once("open",u),s.once("error",d),s.once("close",h),this.once("close",m),this.once("upgrading",y),this._upgrades.indexOf("webtransport")!==-1&&r!=="webtransport"?this.setTimeoutFn(()=>{o||s.open()},200):s.open()}onHandshake(r){this._upgrades=this._filterUpgrades(r.upgrades),super.onHandshake(r)}_filterUpgrades(r){const s=[];for(let o=0;o<r.length;o++)~this.transports.indexOf(r[o])&&s.push(r[o]);return s}}let km=class extends Cm{constructor(r,s={}){const o=typeof r=="object"?r:s;(!o.transports||o.transports&&typeof o.transports[0]=="string")&&(o.transports=(o.transports||["polling","websocket","webtransport"]).map(u=>ym[u]).filter(u=>!!u)),super(r,o)}};function Fm(a,r="",s){let o=a;s=s||typeof location<"u"&&location,a==null&&(a=s.protocol+"//"+s.host),typeof a=="string"&&(a.charAt(0)==="/"&&(a.charAt(1)==="/"?a=s.protocol+a:a=s.host+a),/^(https?|wss?):\/\//.test(a)||(typeof s<"u"?a=s.protocol+"//"+a:a="https://"+a),o=Aa(a)),o.port||(/^(http|ws)$/.test(o.protocol)?o.port="80":/^(http|ws)s$/.test(o.protocol)&&(o.port="443")),o.path=o.path||"/";const f=o.host.indexOf(":")!==-1?"["+o.host+"]":o.host;return o.id=o.protocol+"://"+f+":"+o.port+r,o.href=o.protocol+"://"+f+(s&&s.port===o.port?"":":"+o.port),o}const Em=typeof ArrayBuffer=="function",_m=a=>typeof ArrayBuffer.isView=="function"?ArrayBuffer.isView(a):a.buffer instanceof ArrayBuffer,ep=Object.prototype.toString,Nm=typeof Blob=="function"||typeof Blob<"u"&&ep.call(Blob)==="[object BlobConstructor]",zm=typeof File=="function"||typeof File<"u"&&ep.call(File)==="[object FileConstructor]";function Xa(a){return Em&&(a instanceof ArrayBuffer||_m(a))||Nm&&a instanceof Blob||zm&&a instanceof File}function ci(a,r){if(!a||typeof a!="object")return!1;if(Array.isArray(a)){for(let s=0,o=a.length;s<o;s++)if(ci(a[s]))return!0;return!1}if(Xa(a))return!0;if(a.toJSON&&typeof a.toJSON=="function"&&arguments.length===1)return ci(a.toJSON(),!0);for(const s in a)if(Object.prototype.hasOwnProperty.call(a,s)&&ci(a[s]))return!0;return!1}function Dm(a){const r=[],s=a.data,o=a;return o.data=ja(s,r),o.attachments=r.length,{packet:o,buffers:r}}function ja(a,r){if(!a)return a;if(Xa(a)){const s={_placeholder:!0,num:r.length};return r.push(a),s}else if(Array.isArray(a)){const s=new Array(a.length);for(let o=0;o<a.length;o++)s[o]=ja(a[o],r);return s}else if(typeof a=="object"&&!(a instanceof Date)){const s={};for(const o in a)Object.prototype.hasOwnProperty.call(a,o)&&(s[o]=ja(a[o],r));return s}return a}function Lm(a,r){return a.data=Ra(a.data,r),delete a.attachments,a}function Ra(a,r){if(!a)return a;if(a&&a._placeholder===!0){if(typeof a.num=="number"&&a.num>=0&&a.num<r.length)return r[a.num];throw new Error("illegal attachments")}else if(Array.isArray(a))for(let s=0;s<a.length;s++)a[s]=Ra(a[s],r);else if(typeof a=="object")for(const s in a)Object.prototype.hasOwnProperty.call(a,s)&&(a[s]=Ra(a[s],r));return a}const Om=["connect","connect_error","disconnect","disconnecting","newListener","removeListener"];var oe;(function(a){a[a.CONNECT=0]="CONNECT",a[a.DISCONNECT=1]="DISCONNECT",a[a.EVENT=2]="EVENT",a[a.ACK=3]="ACK",a[a.CONNECT_ERROR=4]="CONNECT_ERROR",a[a.BINARY_EVENT=5]="BINARY_EVENT",a[a.BINARY_ACK=6]="BINARY_ACK"})(oe||(oe={}));class Am{constructor(r){this.replacer=r}encode(r){return(r.type===oe.EVENT||r.type===oe.ACK)&&ci(r)?this.encodeAsBinary({type:r.type===oe.EVENT?oe.BINARY_EVENT:oe.BINARY_ACK,nsp:r.nsp,data:r.data,id:r.id}):[this.encodeAsString(r)]}encodeAsString(r){let s=""+r.type;return(r.type===oe.BINARY_EVENT||r.type===oe.BINARY_ACK)&&(s+=r.attachments+"-"),r.nsp&&r.nsp!=="/"&&(s+=r.nsp+","),r.id!=null&&(s+=r.id),r.data!=null&&(s+=JSON.stringify(r.data,this.replacer)),s}encodeAsBinary(r){const s=Dm(r),o=this.encodeAsString(s.packet),u=s.buffers;return u.unshift(o),u}}class Va extends je{constructor(r){super(),this.reviver=r}add(r){let s;if(typeof r=="string"){if(this.reconstructor)throw new Error("got plaintext data when reconstructing a packet");s=this.decodeString(r);const o=s.type===oe.BINARY_EVENT;o||s.type===oe.BINARY_ACK?(s.type=o?oe.EVENT:oe.ACK,this.reconstructor=new Pm(s),s.attachments===0&&super.emitReserved("decoded",s)):super.emitReserved("decoded",s)}else if(Xa(r)||r.base64)if(this.reconstructor)s=this.reconstructor.takeBinaryData(r),s&&(this.reconstructor=null,super.emitReserved("decoded",s));else throw new Error("got binary data when not reconstructing a packet");else throw new Error("Unknown type: "+r)}decodeString(r){let s=0;const o={type:Number(r.charAt(0))};if(oe[o.type]===void 0)throw new Error("unknown packet type "+o.type);if(o.type===oe.BINARY_EVENT||o.type===oe.BINARY_ACK){const f=s+1;for(;r.charAt(++s)!=="-"&&s!=r.length;);const d=r.substring(f,s);if(d!=Number(d)||r.charAt(s)!=="-")throw new Error("Illegal attachments");o.attachments=Number(d)}if(r.charAt(s+1)==="/"){const f=s+1;for(;++s&&!(r.charAt(s)===","||s===r.length););o.nsp=r.substring(f,s)}else o.nsp="/";const u=r.charAt(s+1);if(u!==""&&Number(u)==u){const f=s+1;for(;++s;){const d=r.charAt(s);if(d==null||Number(d)!=d){--s;break}if(s===r.length)break}o.id=Number(r.substring(f,s+1))}if(r.charAt(++s)){const f=this.tryParse(r.substr(s));if(Va.isPayloadValid(o.type,f))o.data=f;else throw new Error("invalid payload")}return o}tryParse(r){try{return JSON.parse(r,this.reviver)}catch{return!1}}static isPayloadValid(r,s){switch(r){case oe.CONNECT:return Cf(s);case oe.DISCONNECT:return s===void 0;case oe.CONNECT_ERROR:return typeof s=="string"||Cf(s);case oe.EVENT:case oe.BINARY_EVENT:return Array.isArray(s)&&(typeof s[0]=="number"||typeof s[0]=="string"&&Om.indexOf(s[0])===-1);case oe.ACK:case oe.BINARY_ACK:return Array.isArray(s)}}destroy(){this.reconstructor&&(this.reconstructor.finishedReconstruction(),this.reconstructor=null)}}class Pm{constructor(r){this.packet=r,this.buffers=[],this.reconPack=r}takeBinaryData(r){if(this.buffers.push(r),this.buffers.length===this.reconPack.attachments){const s=Lm(this.reconPack,this.buffers);return this.finishedReconstruction(),s}return null}finishedReconstruction(){this.reconPack=null,this.buffers=[]}}function Cf(a){return Object.prototype.toString.call(a)==="[object Object]"}const jm=Object.freeze(Object.defineProperty({__proto__:null,Decoder:Va,Encoder:Am,get PacketType(){return oe}},Symbol.toStringTag,{value:"Module"}));function Ct(a,r,s){return a.on(r,s),function(){a.off(r,s)}}const Rm=Object.freeze({connect:1,connect_error:1,disconnect:1,disconnecting:1,newListener:1,removeListener:1});class tp extends je{constructor(r,s,o){super(),this.connected=!1,this.recovered=!1,this.receiveBuffer=[],this.sendBuffer=[],this._queue=[],this._queueSeq=0,this.ids=0,this.acks={},this.flags={},this.io=r,this.nsp=s,o&&o.auth&&(this.auth=o.auth),this._opts=Object.assign({},o),this.io._autoConnect&&this.open()}get disconnected(){return!this.connected}subEvents(){if(this.subs)return;const r=this.io;this.subs=[Ct(r,"open",this.onopen.bind(this)),Ct(r,"packet",this.onpacket.bind(this)),Ct(r,"error",this.onerror.bind(this)),Ct(r,"close",this.onclose.bind(this))]}get active(){return!!this.subs}connect(){return this.connected?this:(this.subEvents(),this.io._reconnecting||this.io.open(),this.io._readyState==="open"&&this.onopen(),this)}open(){return this.connect()}send(...r){return r.unshift("message"),this.emit.apply(this,r),this}emit(r,...s){var o,u,f;if(Rm.hasOwnProperty(r))throw new Error('"'+r.toString()+'" is a reserved event name');if(s.unshift(r),this._opts.retries&&!this.flags.fromQueue&&!this.flags.volatile)return this._addToQueue(s),this;const d={type:oe.EVENT,data:s};if(d.options={},d.options.compress=this.flags.compress!==!1,typeof s[s.length-1]=="function"){const F=this.ids++,v=s.pop();this._registerAckCallback(F,v),d.id=F}const h=(u=(o=this.io.engine)===null||o===void 0?void 0:o.transport)===null||u===void 0?void 0:u.writable,m=this.connected&&!(!((f=this.io.engine)===null||f===void 0)&&f._hasPingExpired());return this.flags.volatile&&!h||(m?(this.notifyOutgoingListeners(d),this.packet(d)):this.sendBuffer.push(d)),this.flags={},this}_registerAckCallback(r,s){var o;const u=(o=this.flags.timeout)!==null&&o!==void 0?o:this._opts.ackTimeout;if(u===void 0){this.acks[r]=s;return}const f=this.io.setTimeoutFn(()=>{delete this.acks[r];for(let h=0;h<this.sendBuffer.length;h++)this.sendBuffer[h].id===r&&this.sendBuffer.splice(h,1);s.call(this,new Error("operation has timed out"))},u),d=(...h)=>{this.io.clearTimeoutFn(f),s.apply(this,h)};d.withError=!0,this.acks[r]=d}emitWithAck(r,...s){return new Promise((o,u)=>{const f=(d,h)=>d?u(d):o(h);f.withError=!0,s.push(f),this.emit(r,...s)})}_addToQueue(r){let s;typeof r[r.length-1]=="function"&&(s=r.pop());const o={id:this._queueSeq++,tryCount:0,pending:!1,args:r,flags:Object.assign({fromQueue:!0},this.flags)};r.push((u,...f)=>(this._queue[0],u!==null?o.tryCount>this._opts.retries&&(this._queue.shift(),s&&s(u)):(this._queue.shift(),s&&s(null,...f)),o.pending=!1,this._drainQueue())),this._queue.push(o),this._drainQueue()}_drainQueue(r=!1){if(!this.connected||this._queue.length===0)return;const s=this._queue[0];s.pending&&!r||(s.pending=!0,s.tryCount++,this.flags=s.flags,this.emit.apply(this,s.args))}packet(r){r.nsp=this.nsp,this.io._packet(r)}onopen(){typeof this.auth=="function"?this.auth(r=>{this._sendConnectPacket(r)}):this._sendConnectPacket(this.auth)}_sendConnectPacket(r){this.packet({type:oe.CONNECT,data:this._pid?Object.assign({pid:this._pid,offset:this._lastOffset},r):r})}onerror(r){this.connected||this.emitReserved("connect_error",r)}onclose(r,s){this.connected=!1,delete this.id,this.emitReserved("disconnect",r,s),this._clearAcks()}_clearAcks(){Object.keys(this.acks).forEach(r=>{if(!this.sendBuffer.some(o=>String(o.id)===r)){const o=this.acks[r];delete this.acks[r],o.withError&&o.call(this,new Error("socket has been disconnected"))}})}onpacket(r){if(r.nsp===this.nsp)switch(r.type){case oe.CONNECT:r.data&&r.data.sid?this.onconnect(r.data.sid,r.data.pid):this.emitReserved("connect_error",new Error("It seems you are trying to reach a Socket.IO server in v2.x with a v3.x client, but they are not compatible (more information here: https://socket.io/docs/v3/migrating-from-2-x-to-3-0/)"));break;case oe.EVENT:case oe.BINARY_EVENT:this.onevent(r);break;case oe.ACK:case oe.BINARY_ACK:this.onack(r);break;case oe.DISCONNECT:this.ondisconnect();break;case oe.CONNECT_ERROR:this.destroy();const o=new Error(r.data.message);o.data=r.data.data,this.emitReserved("connect_error",o);break}}onevent(r){const s=r.data||[];r.id!=null&&s.push(this.ack(r.id)),this.connected?this.emitEvent(s):this.receiveBuffer.push(Object.freeze(s))}emitEvent(r){if(this._anyListeners&&this._anyListeners.length){const s=this._anyListeners.slice();for(const o of s)o.apply(this,r)}super.emit.apply(this,r),this._pid&&r.length&&typeof r[r.length-1]=="string"&&(this._lastOffset=r[r.length-1])}ack(r){const s=this;let o=!1;return function(...u){o||(o=!0,s.packet({type:oe.ACK,id:r,data:u}))}}onack(r){const s=this.acks[r.id];typeof s=="function"&&(delete this.acks[r.id],s.withError&&r.data.unshift(null),s.apply(this,r.data))}onconnect(r,s){this.id=r,this.recovered=s&&this._pid===s,this._pid=s,this.connected=!0,this.emitBuffered(),this._drainQueue(!0),this.emitReserved("connect")}emitBuffered(){this.receiveBuffer.forEach(r=>this.emitEvent(r)),this.receiveBuffer=[],this.sendBuffer.forEach(r=>{this.notifyOutgoingListeners(r),this.packet(r)}),this.sendBuffer=[]}ondisconnect(){this.destroy(),this.onclose("io server disconnect")}destroy(){this.subs&&(this.subs.forEach(r=>r()),this.subs=void 0),this.io._destroy(this)}disconnect(){return this.connected&&this.packet({type:oe.DISCONNECT}),this.destroy(),this.connected&&this.onclose("io client disconnect"),this}close(){return this.disconnect()}compress(r){return this.flags.compress=r,this}get volatile(){return this.flags.volatile=!0,this}timeout(r){return this.flags.timeout=r,this}onAny(r){return this._anyListeners=this._anyListeners||[],this._anyListeners.push(r),this}prependAny(r){return this._anyListeners=this._anyListeners||[],this._anyListeners.unshift(r),this}offAny(r){if(!this._anyListeners)return this;if(r){const s=this._anyListeners;for(let o=0;o<s.length;o++)if(r===s[o])return s.splice(o,1),this}else this._anyListeners=[];return this}listenersAny(){return this._anyListeners||[]}onAnyOutgoing(r){return this._anyOutgoingListeners=this._anyOutgoingListeners||[],this._anyOutgoingListeners.push(r),this}prependAnyOutgoing(r){return this._anyOutgoingListeners=this._anyOutgoingListeners||[],this._anyOutgoingListeners.unshift(r),this}offAnyOutgoing(r){if(!this._anyOutgoingListeners)return this;if(r){const s=this._anyOutgoingListeners;for(let o=0;o<s.length;o++)if(r===s[o])return s.splice(o,1),this}else this._anyOutgoingListeners=[];return this}listenersAnyOutgoing(){return this._anyOutgoingListeners||[]}notifyOutgoingListeners(r){if(this._anyOutgoingListeners&&this._anyOutgoingListeners.length){const s=this._anyOutgoingListeners.slice();for(const o of s)o.apply(this,r.data)}}}function Jn(a){a=a||{},this.ms=a.min||100,this.max=a.max||1e4,this.factor=a.factor||2,this.jitter=a.jitter>0&&a.jitter<=1?a.jitter:0,this.attempts=0}Jn.prototype.duration=function(){var a=this.ms*Math.pow(this.factor,this.attempts++);if(this.jitter){var r=Math.random(),s=Math.floor(r*this.jitter*a);a=(Math.floor(r*10)&1)==0?a-s:a+s}return Math.min(a,this.max)|0};Jn.prototype.reset=function(){this.attempts=0};Jn.prototype.setMin=function(a){this.ms=a};Jn.prototype.setMax=function(a){this.max=a};Jn.prototype.setJitter=function(a){this.jitter=a};class Ta extends je{constructor(r,s){var o;super(),this.nsps={},this.subs=[],r&&typeof r=="object"&&(s=r,r=void 0),s=s||{},s.path=s.path||"/socket.io",this.opts=s,xi(this,s),this.reconnection(s.reconnection!==!1),this.reconnectionAttempts(s.reconnectionAttempts||1/0),this.reconnectionDelay(s.reconnectionDelay||1e3),this.reconnectionDelayMax(s.reconnectionDelayMax||5e3),this.randomizationFactor((o=s.randomizationFactor)!==null&&o!==void 0?o:.5),this.backoff=new Jn({min:this.reconnectionDelay(),max:this.reconnectionDelayMax(),jitter:this.randomizationFactor()}),this.timeout(s.timeout==null?2e4:s.timeout),this._readyState="closed",this.uri=r;const u=s.parser||jm;this.encoder=new u.Encoder,this.decoder=new u.Decoder,this._autoConnect=s.autoConnect!==!1,this._autoConnect&&this.open()}reconnection(r){return arguments.length?(this._reconnection=!!r,r||(this.skipReconnect=!0),this):this._reconnection}reconnectionAttempts(r){return r===void 0?this._reconnectionAttempts:(this._reconnectionAttempts=r,this)}reconnectionDelay(r){var s;return r===void 0?this._reconnectionDelay:(this._reconnectionDelay=r,(s=this.backoff)===null||s===void 0||s.setMin(r),this)}randomizationFactor(r){var s;return r===void 0?this._randomizationFactor:(this._randomizationFactor=r,(s=this.backoff)===null||s===void 0||s.setJitter(r),this)}reconnectionDelayMax(r){var s;return r===void 0?this._reconnectionDelayMax:(this._reconnectionDelayMax=r,(s=this.backoff)===null||s===void 0||s.setMax(r),this)}timeout(r){return arguments.length?(this._timeout=r,this):this._timeout}maybeReconnectOnOpen(){!this._reconnecting&&this._reconnection&&this.backoff.attempts===0&&this.reconnect()}open(r){if(~this._readyState.indexOf("open"))return this;this.engine=new km(this.uri,this.opts);const s=this.engine,o=this;this._readyState="opening",this.skipReconnect=!1;const u=Ct(s,"open",function(){o.onopen(),r&&r()}),f=h=>{this.cleanup(),this._readyState="closed",this.emitReserved("error",h),r?r(h):this.maybeReconnectOnOpen()},d=Ct(s,"error",f);if(this._timeout!==!1){const h=this._timeout,m=this.setTimeoutFn(()=>{u(),f(new Error("timeout")),s.close()},h);this.opts.autoUnref&&m.unref(),this.subs.push(()=>{this.clearTimeoutFn(m)})}return this.subs.push(u),this.subs.push(d),this}connect(r){return this.open(r)}onopen(){this.cleanup(),this._readyState="open",this.emitReserved("open");const r=this.engine;this.subs.push(Ct(r,"ping",this.onping.bind(this)),Ct(r,"data",this.ondata.bind(this)),Ct(r,"error",this.onerror.bind(this)),Ct(r,"close",this.onclose.bind(this)),Ct(this.decoder,"decoded",this.ondecoded.bind(this)))}onping(){this.emitReserved("ping")}ondata(r){try{this.decoder.add(r)}catch(s){this.onclose("parse error",s)}}ondecoded(r){vi(()=>{this.emitReserved("packet",r)},this.setTimeoutFn)}onerror(r){this.emitReserved("error",r)}socket(r,s){let o=this.nsps[r];return o?this._autoConnect&&!o.active&&o.connect():(o=new tp(this,r,s),this.nsps[r]=o),o}_destroy(r){const s=Object.keys(this.nsps);for(const o of s)if(this.nsps[o].active)return;this._close()}_packet(r){const s=this.encoder.encode(r);for(let o=0;o<s.length;o++)this.engine.write(s[o],r.options)}cleanup(){this.subs.forEach(r=>r()),this.subs.length=0,this.decoder.destroy()}_close(){this.skipReconnect=!0,this._reconnecting=!1,this.onclose("forced close")}disconnect(){return this._close()}onclose(r,s){var o;this.cleanup(),(o=this.engine)===null||o===void 0||o.close(),this.backoff.reset(),this._readyState="closed",this.emitReserved("close",r,s),this._reconnection&&!this.skipReconnect&&this.reconnect()}reconnect(){if(this._reconnecting||this.skipReconnect)return this;const r=this;if(this.backoff.attempts>=this._reconnectionAttempts)this.backoff.reset(),this.emitReserved("reconnect_failed"),this._reconnecting=!1;else{const s=this.backoff.duration();this._reconnecting=!0;const o=this.setTimeoutFn(()=>{r.skipReconnect||(this.emitReserved("reconnect_attempt",r.backoff.attempts),!r.skipReconnect&&r.open(u=>{u?(r._reconnecting=!1,r.reconnect(),this.emitReserved("reconnect_error",u)):r.onreconnect()}))},s);this.opts.autoUnref&&o.unref(),this.subs.push(()=>{this.clearTimeoutFn(o)})}}onreconnect(){const r=this.backoff.attempts;this._reconnecting=!1,this.backoff.reset(),this.emitReserved("reconnect",r)}}const Ir={};function fi(a,r){typeof a=="object"&&(r=a,a=void 0),r=r||{};const s=Fm(a,r.path||"/socket.io"),o=s.source,u=s.id,f=s.path,d=Ir[u]&&f in Ir[u].nsps,h=r.forceNew||r["force new connection"]||r.multiplex===!1||d;let m;return h?m=new Ta(o,r):(Ir[u]||(Ir[u]=new Ta(o,r)),m=Ir[u]),s.query&&!r.query&&(r.query=s.queryKey),m.socket(s.path,r)}Object.assign(fi,{Manager:Ta,Socket:tp,io:fi,connect:fi});const Kn=fi("http://localhost:3001",{autoConnect:!1}),Tm=()=>{const{t:a}=Ua(),{currentSessionId:r,messages:s,addMessage:o,isLoading:u,setLoading:f}=Pf(),[d,h]=ne.useState(""),m=ne.useRef(null),y=()=>{var v;(v=m.current)==null||v.scrollIntoView({behavior:"smooth"})};ne.useEffect(()=>{y()},[s]),ne.useEffect(()=>{if(!r)return;Kn.connect(),Kn.emit("join_session",r);const v=D=>{D.role==="assistant"?(o(D),f(!1)):typeof D=="string"&&D.startsWith("Error:")&&(o({role:"assistant",content:D}),f(!1))};return Kn.on("message",v),()=>{Kn.off("message",v),Kn.disconnect()}},[r]);const F=()=>{if(!d.trim()||!r||u)return;const v={role:"user",content:d,timestamp:Date.now()};o(v),f(!0),Kn.emit("message",{sessionId:r,content:d}),h("")};return r?C.jsxs("div",{"trae-inspector-start-line":"77","trae-inspector-start-column":"4","trae-inspector-end-line":"187","trae-inspector-end-column":"10","trae-inspector-file-path":"client/components/ChatWindow.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"flex-1 flex flex-col h-full bg-white relative",children:[C.jsxs("header",{"trae-inspector-start-line":"79","trae-inspector-start-column":"6","trae-inspector-end-line":"88","trae-inspector-end-column":"15","trae-inspector-file-path":"client/components/ChatWindow.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"h-14 border-b border-gray-100 flex items-center justify-between px-4 sticky top-0 bg-white/80 backdrop-blur-md z-10",children:[C.jsxs("div",{"trae-inspector-start-line":"80","trae-inspector-start-column":"8","trae-inspector-end-line":"84","trae-inspector-end-column":"14","trae-inspector-file-path":"client/components/ChatWindow.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"flex items-center gap-2",children:[C.jsx("span",{"trae-inspector-start-line":"81","trae-inspector-start-column":"12","trae-inspector-end-line":"81","trae-inspector-end-column":"82","trae-inspector-file-path":"client/components/ChatWindow.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"font-semibold text-gray-700",children:a("chat.title")}),C.jsx("span",{"trae-inspector-start-line":"82","trae-inspector-start-column":"12","trae-inspector-end-line":"82","trae-inspector-end-column":"52","trae-inspector-file-path":"client/components/ChatWindow.tsx","trae-inspector-static-props":"%7B%22text%22%3A%22%2F%22%2C%22textStartLine%22%3A%2282%22%2C%22textStartColumn%22%3A%2244%22%2C%22textEndLine%22%3A%2282%22%2C%22textEndColumn%22%3A%2245%22%2C%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"text-gray-300",children:"/"}),C.jsxs("span",{"trae-inspector-start-line":"83","trae-inspector-start-column":"12","trae-inspector-end-line":"83","trae-inspector-end-column":"102","trae-inspector-file-path":"client/components/ChatWindow.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"text-sm text-gray-500 font-mono",children:[r.slice(0,8),"..."]})]}),C.jsx("div",{"trae-inspector-start-line":"85","trae-inspector-start-column":"8","trae-inspector-end-line":"87","trae-inspector-end-column":"14","trae-inspector-file-path":"client/components/ChatWindow.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"flex items-center gap-2"})]}),C.jsx("div",{"trae-inspector-start-line":"91","trae-inspector-start-column":"6","trae-inspector-end-line":"154","trae-inspector-end-column":"12","trae-inspector-file-path":"client/components/ChatWindow.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"flex-1 overflow-y-auto custom-scrollbar",children:C.jsxs("div",{"trae-inspector-start-line":"92","trae-inspector-start-column":"8","trae-inspector-end-line":"153","trae-inspector-end-column":"14","trae-inspector-file-path":"client/components/ChatWindow.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"max-w-3xl mx-auto py-8 px-4 space-y-6",children:[s.length===0&&C.jsxs("div",{"trae-inspector-start-line":"94","trae-inspector-start-column":"16","trae-inspector-end-line":"97","trae-inspector-end-column":"22","trae-inspector-file-path":"client/components/ChatWindow.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"text-center py-20 opacity-50",children:[C.jsx("div",{"trae-inspector-start-line":"95","trae-inspector-start-column":"20","trae-inspector-end-line":"95","trae-inspector-end-column":"59","trae-inspector-file-path":"client/components/ChatWindow.tsx","trae-inspector-static-props":"%7B%22text%22%3A%22%F0%9F%8D%87%22%2C%22textStartLine%22%3A%2295%22%2C%22textStartColumn%22%3A%2251%22%2C%22textEndLine%22%3A%2295%22%2C%22textEndColumn%22%3A%2253%22%2C%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"text-4xl mb-4",children:"🍇"}),C.jsx("p",{"trae-inspector-start-line":"96","trae-inspector-start-column":"20","trae-inspector-end-line":"96","trae-inspector-end-column":"44","trae-inspector-file-path":"client/components/ChatWindow.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",children:a("chat.empty")})]}),s.map((v,D)=>{const z=v.role==="user";return C.jsxs("div",{"trae-inspector-start-line":"102","trae-inspector-start-column":"16","trae-inspector-end-line":"134","trae-inspector-end-column":"22","trae-inspector-file-path":"client/components/ChatWindow.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:`flex w-full gap-4 ${z?"justify-end":"justify-start"}`,children:[!z&&C.jsx("div",{"trae-inspector-start-line":"107","trae-inspector-start-column":"20","trae-inspector-end-line":"109","trae-inspector-end-column":"26","trae-inspector-file-path":"client/components/ChatWindow.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"w-8 h-8 rounded-full bg-teal-600 flex items-center justify-center flex-shrink-0 shadow-sm mt-1",children:C.jsx(Yc,{size:16,className:"text-white"})}),C.jsxs("div",{"trae-inspector-start-line":"112","trae-inspector-start-column":"16","trae-inspector-end-line":"127","trae-inspector-end-column":"22","trae-inspector-file-path":"client/components/ChatWindow.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:`flex flex-col max-w-[85%] ${z?"items-end":"items-start"}`,children:[C.jsx("div",{"trae-inspector-start-line":"113","trae-inspector-start-column":"20","trae-inspector-end-line":"117","trae-inspector-end-column":"26","trae-inspector-file-path":"client/components/ChatWindow.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"flex items-baseline gap-2 mb-1",children:C.jsx("span",{"trae-inspector-start-line":"114","trae-inspector-start-column":"24","trae-inspector-end-line":"116","trae-inspector-end-column":"31","trae-inspector-file-path":"client/components/ChatWindow.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"text-xs font-medium text-gray-400",children:a(z?"chat.you":"chat.assistant")})}),C.jsx("div",{"trae-inspector-start-line":"118","trae-inspector-start-column":"20","trae-inspector-end-line":"126","trae-inspector-end-column":"26","trae-inspector-file-path":"client/components/ChatWindow.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:`px-4 py-3 rounded-2xl shadow-sm whitespace-pre-wrap text-[15px] leading-relaxed ${z?"bg-blue-600 text-white rounded-br-none":"bg-gray-50 text-gray-800 border border-gray-100 rounded-bl-none"}`,children:v.content})]}),z&&C.jsx("div",{"trae-inspector-start-line":"130","trae-inspector-start-column":"20","trae-inspector-end-line":"132","trae-inspector-end-column":"26","trae-inspector-file-path":"client/components/ChatWindow.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"w-8 h-8 rounded-full bg-gray-200 flex items-center justify-center flex-shrink-0 mt-1",children:C.jsx(Jh,{size:16,className:"text-gray-500"})})]},D)}),u&&C.jsxs("div",{"trae-inspector-start-line":"139","trae-inspector-start-column":"12","trae-inspector-end-line":"150","trae-inspector-end-column":"18","trae-inspector-file-path":"client/components/ChatWindow.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"flex w-full gap-4 justify-start",children:[C.jsx("div",{"trae-inspector-start-line":"140","trae-inspector-start-column":"16","trae-inspector-end-line":"142","trae-inspector-end-column":"22","trae-inspector-file-path":"client/components/ChatWindow.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"w-8 h-8 rounded-full bg-teal-600 flex items-center justify-center flex-shrink-0 shadow-sm mt-1",children:C.jsx(Yc,{size:16,className:"text-white"})}),C.jsxs("div",{"trae-inspector-start-line":"143","trae-inspector-start-column":"16","trae-inspector-end-line":"149","trae-inspector-end-column":"22","trae-inspector-file-path":"client/components/ChatWindow.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"flex flex-col items-start",children:[C.jsx("div",{"trae-inspector-start-line":"144","trae-inspector-start-column":"20","trae-inspector-end-line":"144","trae-inspector-end-column":"103","trae-inspector-file-path":"client/components/ChatWindow.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"text-xs font-medium text-gray-400 mb-1",children:a("chat.assistant")}),C.jsxs("div",{"trae-inspector-start-line":"145","trae-inspector-start-column":"20","trae-inspector-end-line":"148","trae-inspector-end-column":"26","trae-inspector-file-path":"client/components/ChatWindow.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"px-4 py-3 bg-gray-50 rounded-2xl rounded-bl-none border border-gray-100 flex items-center gap-2 text-gray-500",children:[C.jsx(Mh,{className:"animate-spin",size:16}),C.jsx("span",{"trae-inspector-start-line":"147","trae-inspector-start-column":"24","trae-inspector-end-line":"147","trae-inspector-end-column":"77","trae-inspector-file-path":"client/components/ChatWindow.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"text-sm",children:a("chat.thinking")})]})]})]}),C.jsx("div",{"trae-inspector-start-line":"152","trae-inspector-start-column":"12","trae-inspector-end-line":"152","trae-inspector-end-column":"56","trae-inspector-file-path":"client/components/ChatWindow.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",ref:m,className:"h-4"})]})}),C.jsx("div",{"trae-inspector-start-line":"157","trae-inspector-start-column":"6","trae-inspector-end-line":"186","trae-inspector-end-column":"12","trae-inspector-file-path":"client/components/ChatWindow.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"p-4 bg-white",children:C.jsxs("div",{"trae-inspector-start-line":"158","trae-inspector-start-column":"8","trae-inspector-end-line":"185","trae-inspector-end-column":"14","trae-inspector-file-path":"client/components/ChatWindow.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"max-w-3xl mx-auto relative",children:[C.jsxs("div",{"trae-inspector-start-line":"159","trae-inspector-start-column":"12","trae-inspector-end-line":"179","trae-inspector-end-column":"18","trae-inspector-file-path":"client/components/ChatWindow.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"relative flex items-end gap-2 p-2 bg-gray-50 border border-gray-200 rounded-xl shadow-sm focus-within:ring-2 focus-within:ring-blue-100 focus-within:border-blue-400 transition-all",children:[C.jsx("textarea",{"trae-inspector-start-line":"160","trae-inspector-start-column":"16","trae-inspector-end-line":"167","trae-inspector-end-column":"18","trae-inspector-file-path":"client/components/ChatWindow.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",value:d,onChange:v=>h(v.target.value),placeholder:a("chat.inputPlaceholder"),className:"flex-1 max-h-[200px] min-h-[50px] py-3 px-3 bg-transparent border-none focus:ring-0 resize-none text-gray-800 placeholder:text-gray-400",style:{height:"auto"},rows:1}),C.jsx("button",{"trae-inspector-start-line":"168","trae-inspector-start-column":"16","trae-inspector-end-line":"178","trae-inspector-end-column":"25","trae-inspector-file-path":"client/components/ChatWindow.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",onClick:F,disabled:!d.trim()||u,className:`p-2 rounded-lg mb-1 transition-all duration-200 ${d.trim()&&!u?"bg-blue-600 text-white hover:bg-blue-700 shadow-sm":"bg-gray-200 text-gray-400 cursor-not-allowed"}`,children:C.jsx(Wh,{size:18})})]}),C.jsx("div",{"trae-inspector-start-line":"180","trae-inspector-start-column":"12","trae-inspector-end-line":"184","trae-inspector-end-column":"18","trae-inspector-file-path":"client/components/ChatWindow.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"text-center mt-2",children:C.jsx("p",{"trae-inspector-start-line":"181","trae-inspector-start-column":"16","trae-inspector-end-line":"183","trae-inspector-end-column":"20","trae-inspector-file-path":"client/components/ChatWindow.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"text-xs text-gray-400",children:a("chat.disclaimer")})})]})})]}):C.jsxs("div",{"trae-inspector-start-line":"64","trae-inspector-start-column":"6","trae-inspector-end-line":"72","trae-inspector-end-column":"12","trae-inspector-file-path":"client/components/ChatWindow.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"flex-1 flex flex-col items-center justify-center bg-white text-gray-800 p-4",children:[C.jsx("div",{"trae-inspector-start-line":"65","trae-inspector-start-column":"8","trae-inspector-end-line":"67","trae-inspector-end-column":"14","trae-inspector-file-path":"client/components/ChatWindow.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"w-16 h-16 bg-gray-100 rounded-2xl flex items-center justify-center mb-6 shadow-sm",children:C.jsx("span",{"trae-inspector-start-line":"66","trae-inspector-start-column":"12","trae-inspector-end-line":"66","trae-inspector-end-column":"48","trae-inspector-file-path":"client/components/ChatWindow.tsx","trae-inspector-static-props":"%7B%22text%22%3A%22%F0%9F%8D%87%22%2C%22textStartLine%22%3A%2266%22%2C%22textStartColumn%22%3A%2239%22%2C%22textEndLine%22%3A%2266%22%2C%22textEndColumn%22%3A%2241%22%2C%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"text-4xl",children:"🍇"})}),C.jsx("h1",{"trae-inspector-start-line":"68","trae-inspector-start-column":"8","trae-inspector-end-line":"68","trae-inspector-end-column":"77","trae-inspector-file-path":"client/components/ChatWindow.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"text-2xl font-semibold mb-2",children:a("welcome.title")}),C.jsx("p",{"trae-inspector-start-line":"69","trae-inspector-start-column":"8","trae-inspector-end-line":"71","trae-inspector-end-column":"12","trae-inspector-file-path":"client/components/ChatWindow.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"text-gray-500 max-w-md text-center",children:a("welcome.subtitle")})]})};function Mm(){return C.jsxs("div",{"trae-inspector-start-line":"7","trae-inspector-start-column":"4","trae-inspector-end-line":"12","trae-inspector-end-column":"10","trae-inspector-file-path":"client/App.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"flex h-screen w-screen overflow-hidden bg-white text-gray-900 font-sans antialiased selection:bg-blue-100 selection:text-blue-900",children:[C.jsx(X2,{}),C.jsx("main",{"trae-inspector-start-line":"9","trae-inspector-start-column":"6","trae-inspector-end-line":"11","trae-inspector-end-column":"13","trae-inspector-file-path":"client/App.tsx","trae-inspector-static-props":"%7B%22cwd%22%3A%22%2FUsers%2Fzxz%2FDocuments%2FXiaoZuoClaw%22%7D",className:"flex-1 flex flex-col h-full relative",children:C.jsx(Tm,{})})]})}const{slice:Bm,forEach:Um}=[];function Im(a){return Um.call(Bm.call(arguments,1),r=>{if(r)for(const s in r)a[s]===void 0&&(a[s]=r[s])}),a}function bm(a){return typeof a!="string"?!1:[/<\s*script.*?>/i,/<\s*\/\s*script\s*>/i,/<\s*img.*?on\w+\s*=/i,/<\s*\w+\s*on\w+\s*=.*?>/i,/javascript\s*:/i,/vbscript\s*:/i,/expression\s*\(/i,/eval\s*\(/i,/alert\s*\(/i,/document\.cookie/i,/document\.write\s*\(/i,/window\.location/i,/innerHTML/i].some(s=>s.test(a))}const kf=/^[\u0009\u0020-\u007e\u0080-\u00ff]+$/,$m=function(a,r){const o=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{path:"/"},u=encodeURIComponent(r);let f=`${a}=${u}`;if(o.maxAge>0){const d=o.maxAge-0;if(Number.isNaN(d))throw new Error("maxAge should be a Number");f+=`; Max-Age=${Math.floor(d)}`}if(o.domain){if(!kf.test(o.domain))throw new TypeError("option domain is invalid");f+=`; Domain=${o.domain}`}if(o.path){if(!kf.test(o.path))throw new TypeError("option path is invalid");f+=`; Path=${o.path}`}if(o.expires){if(typeof o.expires.toUTCString!="function")throw new TypeError("option expires is invalid");f+=`; Expires=${o.expires.toUTCString()}`}if(o.httpOnly&&(f+="; HttpOnly"),o.secure&&(f+="; Secure"),o.sameSite)switch(typeof o.sameSite=="string"?o.sameSite.toLowerCase():o.sameSite){case!0:f+="; SameSite=Strict";break;case"lax":f+="; SameSite=Lax";break;case"strict":f+="; SameSite=Strict";break;case"none":f+="; SameSite=None";break;default:throw new TypeError("option sameSite is invalid")}return o.partitioned&&(f+="; Partitioned"),f},Ff={create(a,r,s,o){let u=arguments.length>4&&arguments[4]!==void 0?arguments[4]:{path:"/",sameSite:"strict"};s&&(u.expires=new Date,u.expires.setTime(u.expires.getTime()+s*60*1e3)),o&&(u.domain=o),document.cookie=$m(a,r,u)},read(a){const r=`${a}=`,s=document.cookie.split(";");for(let o=0;o<s.length;o++){let u=s[o];for(;u.charAt(0)===" ";)u=u.substring(1,u.length);if(u.indexOf(r)===0)return u.substring(r.length,u.length)}return null},remove(a,r){this.create(a,"",-1,r)}};var Xm={name:"cookie",lookup(a){let{lookupCookie:r}=a;if(r&&typeof document<"u")return Ff.read(r)||void 0},cacheUserLanguage(a,r){let{lookupCookie:s,cookieMinutes:o,cookieDomain:u,cookieOptions:f}=r;s&&typeof document<"u"&&Ff.create(s,a,o,u,f)}},Vm={name:"querystring",lookup(a){var o;let{lookupQuerystring:r}=a,s;if(typeof window<"u"){let{search:u}=window.location;!window.location.search&&((o=window.location.hash)==null?void 0:o.indexOf("?"))>-1&&(u=window.location.hash.substring(window.location.hash.indexOf("?")));const d=u.substring(1).split("&");for(let h=0;h<d.length;h++){const m=d[h].indexOf("=");m>0&&d[h].substring(0,m)===r&&(s=d[h].substring(m+1))}}return s}},Hm={name:"hash",lookup(a){var u;let{lookupHash:r,lookupFromHashIndex:s}=a,o;if(typeof window<"u"){const{hash:f}=window.location;if(f&&f.length>2){const d=f.substring(1);if(r){const h=d.split("&");for(let m=0;m<h.length;m++){const y=h[m].indexOf("=");y>0&&h[m].substring(0,y)===r&&(o=h[m].substring(y+1))}}if(o)return o;if(!o&&s>-1){const h=f.match(/\/([a-zA-Z-]*)/g);return Array.isArray(h)?(u=h[typeof s=="number"?s:0])==null?void 0:u.replace("/",""):void 0}}}return o}};let qn=null;const Ef=()=>{if(qn!==null)return qn;try{if(qn=typeof window<"u"&&window.localStorage!==null,!qn)return!1;const a="i18next.translate.boo";window.localStorage.setItem(a,"foo"),window.localStorage.removeItem(a)}catch{qn=!1}return qn};var Zm={name:"localStorage",lookup(a){let{lookupLocalStorage:r}=a;if(r&&Ef())return window.localStorage.getItem(r)||void 0},cacheUserLanguage(a,r){let{lookupLocalStorage:s}=r;s&&Ef()&&window.localStorage.setItem(s,a)}};let Qn=null;const _f=()=>{if(Qn!==null)return Qn;try{if(Qn=typeof window<"u"&&window.sessionStorage!==null,!Qn)return!1;const a="i18next.translate.boo";window.sessionStorage.setItem(a,"foo"),window.sessionStorage.removeItem(a)}catch{Qn=!1}return Qn};var Wm={name:"sessionStorage",lookup(a){let{lookupSessionStorage:r}=a;if(r&&_f())return window.sessionStorage.getItem(r)||void 0},cacheUserLanguage(a,r){let{lookupSessionStorage:s}=r;s&&_f()&&window.sessionStorage.setItem(s,a)}},Km={name:"navigator",lookup(a){const r=[];if(typeof navigator<"u"){const{languages:s,userLanguage:o,language:u}=navigator;if(s)for(let f=0;f<s.length;f++)r.push(s[f]);o&&r.push(o),u&&r.push(u)}return r.length>0?r:void 0}},qm={name:"htmlTag",lookup(a){let{htmlTag:r}=a,s;const o=r||(typeof document<"u"?document.documentElement:null);return o&&typeof o.getAttribute=="function"&&(s=o.getAttribute("lang")),s}},Qm={name:"path",lookup(a){var u;let{lookupFromPathIndex:r}=a;if(typeof window>"u")return;const s=window.location.pathname.match(/\/([a-zA-Z-]*)/g);return Array.isArray(s)?(u=s[typeof r=="number"?r:0])==null?void 0:u.replace("/",""):void 0}},Ym={name:"subdomain",lookup(a){var u,f;let{lookupFromSubdomainIndex:r}=a;const s=typeof r=="number"?r+1:1,o=typeof window<"u"&&((f=(u=window.location)==null?void 0:u.hostname)==null?void 0:f.match(/^(\w{2,5})\.(([a-z0-9-]{1,63}\.[a-z]{2,6})|localhost)/i));if(o)return o[s]}};let np=!1;try{document.cookie,np=!0}catch{}const rp=["querystring","cookie","localStorage","sessionStorage","navigator","htmlTag"];np||rp.splice(1,1);const Jm=()=>({order:rp,lookupQuerystring:"lng",lookupCookie:"i18next",lookupLocalStorage:"i18nextLng",lookupSessionStorage:"i18nextLng",caches:["localStorage"],excludeCacheFor:["cimode"],convertDetectedLanguage:a=>a});class sp{constructor(r){let s=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};this.type="languageDetector",this.detectors={},this.init(r,s)}init(){let r=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{languageUtils:{}},s=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},o=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};this.services=r,this.options=Im(s,this.options||{},Jm()),typeof this.options.convertDetectedLanguage=="string"&&this.options.convertDetectedLanguage.indexOf("15897")>-1&&(this.options.convertDetectedLanguage=u=>u.replace("-","_")),this.options.lookupFromUrlIndex&&(this.options.lookupFromPathIndex=this.options.lookupFromUrlIndex),this.i18nOptions=o,this.addDetector(Xm),this.addDetector(Vm),this.addDetector(Zm),this.addDetector(Wm),this.addDetector(Km),this.addDetector(qm),this.addDetector(Qm),this.addDetector(Ym),this.addDetector(Hm)}addDetector(r){return this.detectors[r.name]=r,this}detect(){let r=arguments.length>0&&arguments[0]!==void 0?arguments[0]:this.options.order,s=[];return r.forEach(o=>{if(this.detectors[o]){let u=this.detectors[o].lookup(this.options);u&&typeof u=="string"&&(u=[u]),u&&(s=s.concat(u))}}),s=s.filter(o=>o!=null&&!bm(o)).map(o=>this.options.convertDetectedLanguage(o)),this.services&&this.services.languageUtils&&this.services.languageUtils.getBestMatchFromCodes?s:s.length>0?s[0]:null}cacheUserLanguage(r){let s=arguments.length>1&&arguments[1]!==void 0?arguments[1]:this.options.caches;s&&(this.options.excludeCacheFor&&this.options.excludeCacheFor.indexOf(r)>-1||s.forEach(o=>{this.detectors[o]&&this.detectors[o].cacheUserLanguage(r,this.options)}))}}sp.type="languageDetector";function Ma(a){"@babel/helpers - typeof";return Ma=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(r){return typeof r}:function(r){return r&&typeof Symbol=="function"&&r.constructor===Symbol&&r!==Symbol.prototype?"symbol":typeof r},Ma(a)}function ip(){return typeof XMLHttpRequest=="function"||(typeof XMLHttpRequest>"u"?"undefined":Ma(XMLHttpRequest))==="object"}function Gm(a){return!!a&&typeof a.then=="function"}function eg(a){return Gm(a)?a:Promise.resolve(a)}const tg="modulepreload",ng=function(a){return"/"+a},Nf={},rg=function(r,s,o){let u=Promise.resolve();if(s&&s.length>0){let d=function(y){return Promise.all(y.map(F=>Promise.resolve(F).then(v=>({status:"fulfilled",value:v}),v=>({status:"rejected",reason:v}))))};document.getElementsByTagName("link");const h=document.querySelector("meta[property=csp-nonce]"),m=(h==null?void 0:h.nonce)||(h==null?void 0:h.getAttribute("nonce"));u=d(s.map(y=>{if(y=ng(y),y in Nf)return;Nf[y]=!0;const F=y.endsWith(".css"),v=F?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${y}"]${v}`))return;const D=document.createElement("link");if(D.rel=F?"stylesheet":tg,F||(D.as="script"),D.crossOrigin="",D.href=y,m&&D.setAttribute("nonce",m),document.head.appendChild(D),F)return new Promise((z,L)=>{D.addEventListener("load",z),D.addEventListener("error",()=>L(new Error(`Unable to preload CSS for ${y}`)))})}))}function f(d){const h=new Event("vite:preloadError",{cancelable:!0});if(h.payload=d,window.dispatchEvent(h),!h.defaultPrevented)throw d}return u.then(d=>{for(const h of d||[])h.status==="rejected"&&f(h.reason);return r().catch(f)})};function zf(a,r){var s=Object.keys(a);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(a);r&&(o=o.filter(function(u){return Object.getOwnPropertyDescriptor(a,u).enumerable})),s.push.apply(s,o)}return s}function Df(a){for(var r=1;r<arguments.length;r++){var s=arguments[r]!=null?arguments[r]:{};r%2?zf(Object(s),!0).forEach(function(o){sg(a,o,s[o])}):Object.getOwnPropertyDescriptors?Object.defineProperties(a,Object.getOwnPropertyDescriptors(s)):zf(Object(s)).forEach(function(o){Object.defineProperty(a,o,Object.getOwnPropertyDescriptor(s,o))})}return a}function sg(a,r,s){return(r=ig(r))in a?Object.defineProperty(a,r,{value:s,enumerable:!0,configurable:!0,writable:!0}):a[r]=s,a}function ig(a){var r=og(a,"string");return Cn(r)=="symbol"?r:r+""}function og(a,r){if(Cn(a)!="object"||!a)return a;var s=a[Symbol.toPrimitive];if(s!==void 0){var o=s.call(a,r);if(Cn(o)!="object")return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return(r==="string"?String:Number)(a)}function Cn(a){"@babel/helpers - typeof";return Cn=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(r){return typeof r}:function(r){return r&&typeof Symbol=="function"&&r.constructor===Symbol&&r!==Symbol.prototype?"symbol":typeof r},Cn(a)}var on=typeof fetch=="function"?fetch:void 0;typeof global<"u"&&global.fetch?on=global.fetch:typeof window<"u"&&window.fetch&&(on=window.fetch);var Zr;ip()&&(typeof global<"u"&&global.XMLHttpRequest?Zr=global.XMLHttpRequest:typeof window<"u"&&window.XMLHttpRequest&&(Zr=window.XMLHttpRequest));var mi;typeof ActiveXObject=="function"&&(typeof global<"u"&&global.ActiveXObject?mi=global.ActiveXObject:typeof window<"u"&&window.ActiveXObject&&(mi=window.ActiveXObject));typeof on!="function"&&(on=void 0);if(!on&&!Zr&&!mi)try{rg(()=>import("./browser-ponyfill-DNlTAU2D.js").then(a=>a.b),[]).then(function(a){on=a.default}).catch(function(){})}catch{}var Ba=function(r,s){if(s&&Cn(s)==="object"){var o="";for(var u in s)o+="&"+encodeURIComponent(u)+"="+encodeURIComponent(s[u]);if(!o)return r;r=r+(r.indexOf("?")!==-1?"&":"?")+o.slice(1)}return r},Lf=function(r,s,o,u){var f=function(m){if(!m.ok)return o(m.statusText||"Error",{status:m.status});m.text().then(function(y){o(null,{status:m.status,data:y})}).catch(o)};if(u){var d=u(r,s);if(d instanceof Promise){d.then(f).catch(o);return}}typeof fetch=="function"?fetch(r,s).then(f).catch(o):on(r,s).then(f).catch(o)},Of=!1,ag=function(r,s,o,u){r.queryStringParams&&(s=Ba(s,r.queryStringParams));var f=Df({},typeof r.customHeaders=="function"?r.customHeaders():r.customHeaders);typeof window>"u"&&typeof global<"u"&&typeof global.process<"u"&&global.process.versions&&global.process.versions.node&&(f["User-Agent"]="i18next-http-backend (node/".concat(global.process.version,"; ").concat(global.process.platform," ").concat(global.process.arch,")")),o&&(f["Content-Type"]="application/json");var d=typeof r.requestOptions=="function"?r.requestOptions(o):r.requestOptions,h=Df({method:o?"POST":"GET",body:o?r.stringify(o):void 0,headers:f},Of?{}:d),m=typeof r.alternateFetch=="function"&&r.alternateFetch.length>=1?r.alternateFetch:void 0;try{Lf(s,h,u,m)}catch(y){if(!d||Object.keys(d).length===0||!y.message||y.message.indexOf("not implemented")<0)return u(y);try{Object.keys(d).forEach(function(F){delete h[F]}),Lf(s,h,u,m),Of=!0}catch(F){u(F)}}},lg=function(r,s,o,u){o&&Cn(o)==="object"&&(o=Ba("",o).slice(1)),r.queryStringParams&&(s=Ba(s,r.queryStringParams));try{var f=Zr?new Zr:new mi("MSXML2.XMLHTTP.3.0");f.open(o?"POST":"GET",s,1),r.crossDomain||f.setRequestHeader("X-Requested-With","XMLHttpRequest"),f.withCredentials=!!r.withCredentials,o&&f.setRequestHeader("Content-Type","application/x-www-form-urlencoded"),f.overrideMimeType&&f.overrideMimeType("application/json");var d=r.customHeaders;if(d=typeof d=="function"?d():d,d)for(var h in d)f.setRequestHeader(h,d[h]);f.onreadystatechange=function(){f.readyState>3&&u(f.status>=400?f.statusText:null,{status:f.status,data:f.responseText})},f.send(o)}catch(m){console&&console.log(m)}},ug=function(r,s,o,u){if(typeof o=="function"&&(u=o,o=void 0),u=u||function(){},on&&s.indexOf("file:")!==0)return ag(r,s,o,u);if(ip()||typeof ActiveXObject=="function")return lg(r,s,o,u);u(new Error("No fetch and no xhr implementation found!"))};function Yn(a){"@babel/helpers - typeof";return Yn=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(r){return typeof r}:function(r){return r&&typeof Symbol=="function"&&r.constructor===Symbol&&r!==Symbol.prototype?"symbol":typeof r},Yn(a)}function Af(a,r){var s=Object.keys(a);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(a);r&&(o=o.filter(function(u){return Object.getOwnPropertyDescriptor(a,u).enumerable})),s.push.apply(s,o)}return s}function Na(a){for(var r=1;r<arguments.length;r++){var s=arguments[r]!=null?arguments[r]:{};r%2?Af(Object(s),!0).forEach(function(o){op(a,o,s[o])}):Object.getOwnPropertyDescriptors?Object.defineProperties(a,Object.getOwnPropertyDescriptors(s)):Af(Object(s)).forEach(function(o){Object.defineProperty(a,o,Object.getOwnPropertyDescriptor(s,o))})}return a}function cg(a,r){if(!(a instanceof r))throw new TypeError("Cannot call a class as a function")}function fg(a,r){for(var s=0;s<r.length;s++){var o=r[s];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(a,ap(o.key),o)}}function pg(a,r,s){return r&&fg(a.prototype,r),Object.defineProperty(a,"prototype",{writable:!1}),a}function op(a,r,s){return(r=ap(r))in a?Object.defineProperty(a,r,{value:s,enumerable:!0,configurable:!0,writable:!0}):a[r]=s,a}function ap(a){var r=dg(a,"string");return Yn(r)=="symbol"?r:r+""}function dg(a,r){if(Yn(a)!="object"||!a)return a;var s=a[Symbol.toPrimitive];if(s!==void 0){var o=s.call(a,r);if(Yn(o)!="object")return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}var hg=function(){return{loadPath:"/locales/{{lng}}/{{ns}}.json",addPath:"/locales/add/{{lng}}/{{ns}}",parse:function(s){return JSON.parse(s)},stringify:JSON.stringify,parsePayload:function(s,o,u){return op({},o,u||"")},parseLoadPayload:function(s,o){},request:ug,reloadInterval:typeof window<"u"?!1:3600*1e3,customHeaders:{},queryStringParams:{},crossDomain:!1,withCredentials:!1,overrideMimeType:!1,requestOptions:{mode:"cors",credentials:"same-origin",cache:"default"}}},lp=(function(){function a(r){var s=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},o=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};cg(this,a),this.services=r,this.options=s,this.allOptions=o,this.type="backend",this.init(r,s,o)}return pg(a,[{key:"init",value:function(s){var o=this,u=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},f=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};if(this.services=s,this.options=Na(Na(Na({},hg()),this.options||{}),u),this.allOptions=f,this.services&&this.options.reloadInterval){var d=setInterval(function(){return o.reload()},this.options.reloadInterval);Yn(d)==="object"&&typeof d.unref=="function"&&d.unref()}}},{key:"readMulti",value:function(s,o,u){this._readAny(s,s,o,o,u)}},{key:"read",value:function(s,o,u){this._readAny([s],s,[o],o,u)}},{key:"_readAny",value:function(s,o,u,f,d){var h=this,m=this.options.loadPath;typeof this.options.loadPath=="function"&&(m=this.options.loadPath(s,u)),m=eg(m),m.then(function(y){if(!y)return d(null,{});var F=h.services.interpolator.interpolate(y,{lng:s.join("+"),ns:u.join("+")});h.loadUrl(F,d,o,f)})}},{key:"loadUrl",value:function(s,o,u,f){var d=this,h=typeof u=="string"?[u]:u,m=typeof f=="string"?[f]:f,y=this.options.parseLoadPayload(h,m);this.options.request(this.options,s,y,function(F,v){if(v&&(v.status>=500&&v.status<600||!v.status))return o("failed loading "+s+"; status code: "+v.status,!0);if(v&&v.status>=400&&v.status<500)return o("failed loading "+s+"; status code: "+v.status,!1);if(!v&&F&&F.message){var D=F.message.toLowerCase(),z=["failed","fetch","network","load"].find(function(V){return D.indexOf(V)>-1});if(z)return o("failed loading "+s+": "+F.message,!0)}if(F)return o(F,!1);var L,M;try{typeof v.data=="string"?L=d.options.parse(v.data,u,f):L=v.data}catch{M="failed parsing "+s+" to json"}if(M)return o(M,!1);o(null,L)})}},{key:"create",value:function(s,o,u,f,d){var h=this;if(this.options.addPath){typeof s=="string"&&(s=[s]);var m=this.options.parsePayload(o,u,f),y=0,F=[],v=[];s.forEach(function(D){var z=h.options.addPath;typeof h.options.addPath=="function"&&(z=h.options.addPath(D,o));var L=h.services.interpolator.interpolate(z,{lng:D,ns:o});h.options.request(h.options,L,m,function(M,V){y+=1,F.push(M),v.push(V),y===s.length&&typeof d=="function"&&d(F,v)})})}}},{key:"reload",value:function(){var s=this,o=this.services,u=o.backendConnector,f=o.languageUtils,d=o.logger,h=u.language;if(!(h&&h.toLowerCase()==="cimode")){var m=[],y=function(v){var D=f.toResolveHierarchy(v);D.forEach(function(z){m.indexOf(z)<0&&m.push(z)})};y(h),this.allOptions.preload&&this.allOptions.preload.forEach(function(F){return y(F)}),m.forEach(function(F){s.allOptions.ns.forEach(function(v){u.read(F,v,"read",null,null,function(D,z){D&&d.warn("loading namespace ".concat(v," for language ").concat(F," failed"),D),!D&&z&&d.log("loaded namespace ".concat(v," for language ").concat(F),z),u.loaded("".concat(F,"|").concat(v),D,z)})})})}}}])})();lp.type="backend";qe.use(lp).use(sp).use(P2).init({fallbackLng:"en",debug:!0,interpolation:{escapeValue:!1},backend:{loadPath:"/locales/{{lng}}/translation.json"}});hh.createRoot(document.getElementById("root")).render(C.jsx(ne.StrictMode,{children:C.jsx(ne.Suspense,{fallback:"Loading...",children:C.jsx(Mm,{})})}));export{mg as c,ih as g};
|