@xpert-ai/chatkit-wps-addin 0.2.2 → 0.2.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -1,199 +0,0 @@
|
|
|
1
|
-
var Cp=Object.defineProperty;var Xd=s=>{throw TypeError(s)};var Op=(s,u,r)=>u in s?Cp(s,u,{enumerable:!0,configurable:!0,writable:!0,value:r}):s[u]=r;var At=(s,u,r)=>Op(s,typeof u!="symbol"?u+"":u,r),Gd=(s,u,r)=>u.has(s)||Xd("Cannot "+r);var ti=(s,u,r)=>(Gd(s,u,"read from private field"),r?r.call(s):u.get(s)),Du=(s,u,r)=>u.has(s)?Xd("Cannot add the same private member more than once"):u instanceof WeakSet?u.add(s):u.set(s,r),Ru=(s,u,r,c)=>(Gd(s,u,"write to private field"),c?c.call(s,r):u.set(s,r),r);import{g as Pn,a as ei,b as Dp,r as Rp}from"./wps-api-DgiVmik0.js";function Up(s){return s&&s.__esModule&&Object.prototype.hasOwnProperty.call(s,"default")?s.default:s}var or={exports:{}},li={};/**
|
|
2
|
-
* @license React
|
|
3
|
-
* react-jsx-runtime.production.js
|
|
4
|
-
*
|
|
5
|
-
* Copyright (c) Meta Platforms, Inc. and 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 Qd;function wp(){if(Qd)return li;Qd=1;var s=Symbol.for("react.transitional.element"),u=Symbol.for("react.fragment");function r(c,h,d){var y=null;if(d!==void 0&&(y=""+d),h.key!==void 0&&(y=""+h.key),"key"in h){d={};for(var v in h)v!=="key"&&(d[v]=h[v])}else d=h;return h=d.ref,{$$typeof:s,type:c,key:y,ref:h!==void 0?h:null,props:d}}return li.Fragment=u,li.jsx=r,li.jsxs=r,li}var Kd;function Hp(){return Kd||(Kd=1,or.exports=wp()),or.exports}var K=Hp(),hr={exports:{}},V={};/**
|
|
10
|
-
* @license React
|
|
11
|
-
* react.production.js
|
|
12
|
-
*
|
|
13
|
-
* Copyright (c) Meta Platforms, Inc. and 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 Vd;function Np(){if(Vd)return V;Vd=1;var s=Symbol.for("react.transitional.element"),u=Symbol.for("react.portal"),r=Symbol.for("react.fragment"),c=Symbol.for("react.strict_mode"),h=Symbol.for("react.profiler"),d=Symbol.for("react.consumer"),y=Symbol.for("react.context"),v=Symbol.for("react.forward_ref"),E=Symbol.for("react.suspense"),b=Symbol.for("react.memo"),N=Symbol.for("react.lazy"),U=Symbol.for("react.activity"),W=Symbol.iterator;function st(p){return p===null||typeof p!="object"?null:(p=W&&p[W]||p["@@iterator"],typeof p=="function"?p:null)}var St={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},it=Object.assign,Mt={};function bt(p,D,H){this.props=p,this.context=D,this.refs=Mt,this.updater=H||St}bt.prototype.isReactComponent={},bt.prototype.setState=function(p,D){if(typeof p!="object"&&typeof p!="function"&&p!=null)throw Error("takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,p,D,"setState")},bt.prototype.forceUpdate=function(p){this.updater.enqueueForceUpdate(this,p,"forceUpdate")};function wt(){}wt.prototype=bt.prototype;function Ht(p,D,H){this.props=p,this.context=D,this.refs=Mt,this.updater=H||St}var te=Ht.prototype=new wt;te.constructor=Ht,it(te,bt.prototype),te.isPureReactComponent=!0;var ee=Array.isArray;function Yt(){}var $={H:null,A:null,T:null,S:null},zt=Object.prototype.hasOwnProperty;function Xe(p,D,H){var L=H.ref;return{$$typeof:s,type:p,key:D,ref:L!==void 0?L:null,props:H}}function mn(p,D){return Xe(p.type,D,p.props)}function Ge(p){return typeof p=="object"&&p!==null&&p.$$typeof===s}function le(p){var D={"=":"=0",":":"=2"};return"$"+p.replace(/[=:]/g,function(H){return D[H]})}var Zl=/\/+/g;function We(p,D){return typeof p=="object"&&p!==null&&p.key!=null?le(""+p.key):D.toString(36)}function He(p){switch(p.status){case"fulfilled":return p.value;case"rejected":throw p.reason;default:switch(typeof p.status=="string"?p.then(Yt,Yt):(p.status="pending",p.then(function(D){p.status==="pending"&&(p.status="fulfilled",p.value=D)},function(D){p.status==="pending"&&(p.status="rejected",p.reason=D)})),p.status){case"fulfilled":return p.value;case"rejected":throw p.reason}}throw p}function z(p,D,H,L,Z){var F=typeof p;(F==="undefined"||F==="boolean")&&(p=null);var ct=!1;if(p===null)ct=!0;else switch(F){case"bigint":case"string":case"number":ct=!0;break;case"object":switch(p.$$typeof){case s:case u:ct=!0;break;case N:return ct=p._init,z(ct(p._payload),D,H,L,Z)}}if(ct)return Z=Z(p),ct=L===""?"."+We(p,0):L,ee(Z)?(H="",ct!=null&&(H=ct.replace(Zl,"$&/")+"/"),z(Z,D,H,"",function(sa){return sa})):Z!=null&&(Ge(Z)&&(Z=mn(Z,H+(Z.key==null||p&&p.key===Z.key?"":(""+Z.key).replace(Zl,"$&/")+"/")+ct)),D.push(Z)),1;ct=0;var It=L===""?".":L+":";if(ee(p))for(var Dt=0;Dt<p.length;Dt++)L=p[Dt],F=It+We(L,Dt),ct+=z(L,D,H,F,Z);else if(Dt=st(p),typeof Dt=="function")for(p=Dt.call(p),Dt=0;!(L=p.next()).done;)L=L.value,F=It+We(L,Dt++),ct+=z(L,D,H,F,Z);else if(F==="object"){if(typeof p.then=="function")return z(He(p),D,H,L,Z);throw D=String(p),Error("Objects are not valid as a React child (found: "+(D==="[object Object]"?"object with keys {"+Object.keys(p).join(", ")+"}":D)+"). If you meant to render a collection of children, use an array instead.")}return ct}function w(p,D,H){if(p==null)return p;var L=[],Z=0;return z(p,L,"","",function(F){return D.call(H,F,Z++)}),L}function G(p){if(p._status===-1){var D=p._result;D=D(),D.then(function(H){(p._status===0||p._status===-1)&&(p._status=1,p._result=H)},function(H){(p._status===0||p._status===-1)&&(p._status=2,p._result=H)}),p._status===-1&&(p._status=0,p._result=D)}if(p._status===1)return p._result.default;throw p._result}var ot=typeof reportError=="function"?reportError:function(p){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var D=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof p=="object"&&p!==null&&typeof p.message=="string"?String(p.message):String(p),error:p});if(!window.dispatchEvent(D))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",p);return}console.error(p)},yt={map:w,forEach:function(p,D,H){w(p,function(){D.apply(this,arguments)},H)},count:function(p){var D=0;return w(p,function(){D++}),D},toArray:function(p){return w(p,function(D){return D})||[]},only:function(p){if(!Ge(p))throw Error("React.Children.only expected to receive a single React element child.");return p}};return V.Activity=U,V.Children=yt,V.Component=bt,V.Fragment=r,V.Profiler=h,V.PureComponent=Ht,V.StrictMode=c,V.Suspense=E,V.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=$,V.__COMPILER_RUNTIME={__proto__:null,c:function(p){return $.H.useMemoCache(p)}},V.cache=function(p){return function(){return p.apply(null,arguments)}},V.cacheSignal=function(){return null},V.cloneElement=function(p,D,H){if(p==null)throw Error("The argument must be a React element, but you passed "+p+".");var L=it({},p.props),Z=p.key;if(D!=null)for(F in D.key!==void 0&&(Z=""+D.key),D)!zt.call(D,F)||F==="key"||F==="__self"||F==="__source"||F==="ref"&&D.ref===void 0||(L[F]=D[F]);var F=arguments.length-2;if(F===1)L.children=H;else if(1<F){for(var ct=Array(F),It=0;It<F;It++)ct[It]=arguments[It+2];L.children=ct}return Xe(p.type,Z,L)},V.createContext=function(p){return p={$$typeof:y,_currentValue:p,_currentValue2:p,_threadCount:0,Provider:null,Consumer:null},p.Provider=p,p.Consumer={$$typeof:d,_context:p},p},V.createElement=function(p,D,H){var L,Z={},F=null;if(D!=null)for(L in D.key!==void 0&&(F=""+D.key),D)zt.call(D,L)&&L!=="key"&&L!=="__self"&&L!=="__source"&&(Z[L]=D[L]);var ct=arguments.length-2;if(ct===1)Z.children=H;else if(1<ct){for(var It=Array(ct),Dt=0;Dt<ct;Dt++)It[Dt]=arguments[Dt+2];Z.children=It}if(p&&p.defaultProps)for(L in ct=p.defaultProps,ct)Z[L]===void 0&&(Z[L]=ct[L]);return Xe(p,F,Z)},V.createRef=function(){return{current:null}},V.forwardRef=function(p){return{$$typeof:v,render:p}},V.isValidElement=Ge,V.lazy=function(p){return{$$typeof:N,_payload:{_status:-1,_result:p},_init:G}},V.memo=function(p,D){return{$$typeof:b,type:p,compare:D===void 0?null:D}},V.startTransition=function(p){var D=$.T,H={};$.T=H;try{var L=p(),Z=$.S;Z!==null&&Z(H,L),typeof L=="object"&&L!==null&&typeof L.then=="function"&&L.then(Yt,ot)}catch(F){ot(F)}finally{D!==null&&H.types!==null&&(D.types=H.types),$.T=D}},V.unstable_useCacheRefresh=function(){return $.H.useCacheRefresh()},V.use=function(p){return $.H.use(p)},V.useActionState=function(p,D,H){return $.H.useActionState(p,D,H)},V.useCallback=function(p,D){return $.H.useCallback(p,D)},V.useContext=function(p){return $.H.useContext(p)},V.useDebugValue=function(){},V.useDeferredValue=function(p,D){return $.H.useDeferredValue(p,D)},V.useEffect=function(p,D){return $.H.useEffect(p,D)},V.useEffectEvent=function(p){return $.H.useEffectEvent(p)},V.useId=function(){return $.H.useId()},V.useImperativeHandle=function(p,D,H){return $.H.useImperativeHandle(p,D,H)},V.useInsertionEffect=function(p,D){return $.H.useInsertionEffect(p,D)},V.useLayoutEffect=function(p,D){return $.H.useLayoutEffect(p,D)},V.useMemo=function(p,D){return $.H.useMemo(p,D)},V.useOptimistic=function(p,D){return $.H.useOptimistic(p,D)},V.useReducer=function(p,D,H){return $.H.useReducer(p,D,H)},V.useRef=function(p){return $.H.useRef(p)},V.useState=function(p){return $.H.useState(p)},V.useSyncExternalStore=function(p,D,H){return $.H.useSyncExternalStore(p,D,H)},V.useTransition=function(){return $.H.useTransition()},V.version="19.2.3",V}var Zd;function Dr(){return Zd||(Zd=1,hr.exports=Np()),hr.exports}var vt=Dr();const Jd=Up(vt);var dr={exports:{}},ni={},mr={exports:{}},yr={};/**
|
|
18
|
-
* @license React
|
|
19
|
-
* scheduler.production.js
|
|
20
|
-
*
|
|
21
|
-
* Copyright (c) Meta Platforms, Inc. and 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 kd;function Bp(){return kd||(kd=1,(function(s){function u(z,w){var G=z.length;z.push(w);t:for(;0<G;){var ot=G-1>>>1,yt=z[ot];if(0<h(yt,w))z[ot]=w,z[G]=yt,G=ot;else break t}}function r(z){return z.length===0?null:z[0]}function c(z){if(z.length===0)return null;var w=z[0],G=z.pop();if(G!==w){z[0]=G;t:for(var ot=0,yt=z.length,p=yt>>>1;ot<p;){var D=2*(ot+1)-1,H=z[D],L=D+1,Z=z[L];if(0>h(H,G))L<yt&&0>h(Z,H)?(z[ot]=Z,z[L]=G,ot=L):(z[ot]=H,z[D]=G,ot=D);else if(L<yt&&0>h(Z,G))z[ot]=Z,z[L]=G,ot=L;else break t}}return w}function h(z,w){var G=z.sortIndex-w.sortIndex;return G!==0?G:z.id-w.id}if(s.unstable_now=void 0,typeof performance=="object"&&typeof performance.now=="function"){var d=performance;s.unstable_now=function(){return d.now()}}else{var y=Date,v=y.now();s.unstable_now=function(){return y.now()-v}}var E=[],b=[],N=1,U=null,W=3,st=!1,St=!1,it=!1,Mt=!1,bt=typeof setTimeout=="function"?setTimeout:null,wt=typeof clearTimeout=="function"?clearTimeout:null,Ht=typeof setImmediate<"u"?setImmediate:null;function te(z){for(var w=r(b);w!==null;){if(w.callback===null)c(b);else if(w.startTime<=z)c(b),w.sortIndex=w.expirationTime,u(E,w);else break;w=r(b)}}function ee(z){if(it=!1,te(z),!St)if(r(E)!==null)St=!0,Yt||(Yt=!0,le());else{var w=r(b);w!==null&&He(ee,w.startTime-z)}}var Yt=!1,$=-1,zt=5,Xe=-1;function mn(){return Mt?!0:!(s.unstable_now()-Xe<zt)}function Ge(){if(Mt=!1,Yt){var z=s.unstable_now();Xe=z;var w=!0;try{t:{St=!1,it&&(it=!1,wt($),$=-1),st=!0;var G=W;try{e:{for(te(z),U=r(E);U!==null&&!(U.expirationTime>z&&mn());){var ot=U.callback;if(typeof ot=="function"){U.callback=null,W=U.priorityLevel;var yt=ot(U.expirationTime<=z);if(z=s.unstable_now(),typeof yt=="function"){U.callback=yt,te(z),w=!0;break e}U===r(E)&&c(E),te(z)}else c(E);U=r(E)}if(U!==null)w=!0;else{var p=r(b);p!==null&&He(ee,p.startTime-z),w=!1}}break t}finally{U=null,W=G,st=!1}w=void 0}}finally{w?le():Yt=!1}}}var le;if(typeof Ht=="function")le=function(){Ht(Ge)};else if(typeof MessageChannel<"u"){var Zl=new MessageChannel,We=Zl.port2;Zl.port1.onmessage=Ge,le=function(){We.postMessage(null)}}else le=function(){bt(Ge,0)};function He(z,w){$=bt(function(){z(s.unstable_now())},w)}s.unstable_IdlePriority=5,s.unstable_ImmediatePriority=1,s.unstable_LowPriority=4,s.unstable_NormalPriority=3,s.unstable_Profiling=null,s.unstable_UserBlockingPriority=2,s.unstable_cancelCallback=function(z){z.callback=null},s.unstable_forceFrameRate=function(z){0>z||125<z?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):zt=0<z?Math.floor(1e3/z):5},s.unstable_getCurrentPriorityLevel=function(){return W},s.unstable_next=function(z){switch(W){case 1:case 2:case 3:var w=3;break;default:w=W}var G=W;W=w;try{return z()}finally{W=G}},s.unstable_requestPaint=function(){Mt=!0},s.unstable_runWithPriority=function(z,w){switch(z){case 1:case 2:case 3:case 4:case 5:break;default:z=3}var G=W;W=z;try{return w()}finally{W=G}},s.unstable_scheduleCallback=function(z,w,G){var ot=s.unstable_now();switch(typeof G=="object"&&G!==null?(G=G.delay,G=typeof G=="number"&&0<G?ot+G:ot):G=ot,z){case 1:var yt=-1;break;case 2:yt=250;break;case 5:yt=1073741823;break;case 4:yt=1e4;break;default:yt=5e3}return yt=G+yt,z={id:N++,callback:w,priorityLevel:z,startTime:G,expirationTime:yt,sortIndex:-1},G>ot?(z.sortIndex=G,u(b,z),r(E)===null&&z===r(b)&&(it?(wt($),$=-1):it=!0,He(ee,G-ot))):(z.sortIndex=yt,u(E,z),St||st||(St=!0,Yt||(Yt=!0,le()))),z},s.unstable_shouldYield=mn,s.unstable_wrapCallback=function(z){var w=W;return function(){var G=W;W=w;try{return z.apply(this,arguments)}finally{W=G}}}})(yr)),yr}var Wd;function Lp(){return Wd||(Wd=1,mr.exports=Bp()),mr.exports}var gr={exports:{}},$t={};/**
|
|
26
|
-
* @license React
|
|
27
|
-
* react-dom.production.js
|
|
28
|
-
*
|
|
29
|
-
* Copyright (c) Meta Platforms, Inc. and 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 $d;function jp(){if($d)return $t;$d=1;var s=Dr();function u(E){var b="https://react.dev/errors/"+E;if(1<arguments.length){b+="?args[]="+encodeURIComponent(arguments[1]);for(var N=2;N<arguments.length;N++)b+="&args[]="+encodeURIComponent(arguments[N])}return"Minified React error #"+E+"; visit "+b+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function r(){}var c={d:{f:r,r:function(){throw Error(u(522))},D:r,C:r,L:r,m:r,X:r,S:r,M:r},p:0,findDOMNode:null},h=Symbol.for("react.portal");function d(E,b,N){var U=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:h,key:U==null?null:""+U,children:E,containerInfo:b,implementation:N}}var y=s.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function v(E,b){if(E==="font")return"";if(typeof b=="string")return b==="use-credentials"?b:""}return $t.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=c,$t.createPortal=function(E,b){var N=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!b||b.nodeType!==1&&b.nodeType!==9&&b.nodeType!==11)throw Error(u(299));return d(E,b,null,N)},$t.flushSync=function(E){var b=y.T,N=c.p;try{if(y.T=null,c.p=2,E)return E()}finally{y.T=b,c.p=N,c.d.f()}},$t.preconnect=function(E,b){typeof E=="string"&&(b?(b=b.crossOrigin,b=typeof b=="string"?b==="use-credentials"?b:"":void 0):b=null,c.d.C(E,b))},$t.prefetchDNS=function(E){typeof E=="string"&&c.d.D(E)},$t.preinit=function(E,b){if(typeof E=="string"&&b&&typeof b.as=="string"){var N=b.as,U=v(N,b.crossOrigin),W=typeof b.integrity=="string"?b.integrity:void 0,st=typeof b.fetchPriority=="string"?b.fetchPriority:void 0;N==="style"?c.d.S(E,typeof b.precedence=="string"?b.precedence:void 0,{crossOrigin:U,integrity:W,fetchPriority:st}):N==="script"&&c.d.X(E,{crossOrigin:U,integrity:W,fetchPriority:st,nonce:typeof b.nonce=="string"?b.nonce:void 0})}},$t.preinitModule=function(E,b){if(typeof E=="string")if(typeof b=="object"&&b!==null){if(b.as==null||b.as==="script"){var N=v(b.as,b.crossOrigin);c.d.M(E,{crossOrigin:N,integrity:typeof b.integrity=="string"?b.integrity:void 0,nonce:typeof b.nonce=="string"?b.nonce:void 0})}}else b==null&&c.d.M(E)},$t.preload=function(E,b){if(typeof E=="string"&&typeof b=="object"&&b!==null&&typeof b.as=="string"){var N=b.as,U=v(N,b.crossOrigin);c.d.L(E,N,{crossOrigin:U,integrity:typeof b.integrity=="string"?b.integrity:void 0,nonce:typeof b.nonce=="string"?b.nonce:void 0,type:typeof b.type=="string"?b.type:void 0,fetchPriority:typeof b.fetchPriority=="string"?b.fetchPriority:void 0,referrerPolicy:typeof b.referrerPolicy=="string"?b.referrerPolicy:void 0,imageSrcSet:typeof b.imageSrcSet=="string"?b.imageSrcSet:void 0,imageSizes:typeof b.imageSizes=="string"?b.imageSizes:void 0,media:typeof b.media=="string"?b.media:void 0})}},$t.preloadModule=function(E,b){if(typeof E=="string")if(b){var N=v(b.as,b.crossOrigin);c.d.m(E,{as:typeof b.as=="string"&&b.as!=="script"?b.as:void 0,crossOrigin:N,integrity:typeof b.integrity=="string"?b.integrity:void 0})}else c.d.m(E)},$t.requestFormReset=function(E){c.d.r(E)},$t.unstable_batchedUpdates=function(E,b){return E(b)},$t.useFormState=function(E,b,N){return y.H.useFormState(E,b,N)},$t.useFormStatus=function(){return y.H.useHostTransitionStatus()},$t.version="19.2.3",$t}var Fd;function qp(){if(Fd)return gr.exports;Fd=1;function s(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(s)}catch(u){console.error(u)}}return s(),gr.exports=jp(),gr.exports}/**
|
|
34
|
-
* @license React
|
|
35
|
-
* react-dom-client.production.js
|
|
36
|
-
*
|
|
37
|
-
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
38
|
-
*
|
|
39
|
-
* This source code is licensed under the MIT license found in the
|
|
40
|
-
* LICENSE file in the root directory of this source tree.
|
|
41
|
-
*/var Id;function Yp(){if(Id)return ni;Id=1;var s=Lp(),u=Dr(),r=qp();function c(t){var e="https://react.dev/errors/"+t;if(1<arguments.length){e+="?args[]="+encodeURIComponent(arguments[1]);for(var l=2;l<arguments.length;l++)e+="&args[]="+encodeURIComponent(arguments[l])}return"Minified React error #"+t+"; visit "+e+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function h(t){return!(!t||t.nodeType!==1&&t.nodeType!==9&&t.nodeType!==11)}function d(t){var e=t,l=t;if(t.alternate)for(;e.return;)e=e.return;else{t=e;do e=t,(e.flags&4098)!==0&&(l=e.return),t=e.return;while(t)}return e.tag===3?l:null}function y(t){if(t.tag===13){var e=t.memoizedState;if(e===null&&(t=t.alternate,t!==null&&(e=t.memoizedState)),e!==null)return e.dehydrated}return null}function v(t){if(t.tag===31){var e=t.memoizedState;if(e===null&&(t=t.alternate,t!==null&&(e=t.memoizedState)),e!==null)return e.dehydrated}return null}function E(t){if(d(t)!==t)throw Error(c(188))}function b(t){var e=t.alternate;if(!e){if(e=d(t),e===null)throw Error(c(188));return e!==t?null:t}for(var l=t,n=e;;){var a=l.return;if(a===null)break;var i=a.alternate;if(i===null){if(n=a.return,n!==null){l=n;continue}break}if(a.child===i.child){for(i=a.child;i;){if(i===l)return E(a),t;if(i===n)return E(a),e;i=i.sibling}throw Error(c(188))}if(l.return!==n.return)l=a,n=i;else{for(var f=!1,o=a.child;o;){if(o===l){f=!0,l=a,n=i;break}if(o===n){f=!0,n=a,l=i;break}o=o.sibling}if(!f){for(o=i.child;o;){if(o===l){f=!0,l=i,n=a;break}if(o===n){f=!0,n=i,l=a;break}o=o.sibling}if(!f)throw Error(c(189))}}if(l.alternate!==n)throw Error(c(190))}if(l.tag!==3)throw Error(c(188));return l.stateNode.current===l?t:e}function N(t){var e=t.tag;if(e===5||e===26||e===27||e===6)return t;for(t=t.child;t!==null;){if(e=N(t),e!==null)return e;t=t.sibling}return null}var U=Object.assign,W=Symbol.for("react.element"),st=Symbol.for("react.transitional.element"),St=Symbol.for("react.portal"),it=Symbol.for("react.fragment"),Mt=Symbol.for("react.strict_mode"),bt=Symbol.for("react.profiler"),wt=Symbol.for("react.consumer"),Ht=Symbol.for("react.context"),te=Symbol.for("react.forward_ref"),ee=Symbol.for("react.suspense"),Yt=Symbol.for("react.suspense_list"),$=Symbol.for("react.memo"),zt=Symbol.for("react.lazy"),Xe=Symbol.for("react.activity"),mn=Symbol.for("react.memo_cache_sentinel"),Ge=Symbol.iterator;function le(t){return t===null||typeof t!="object"?null:(t=Ge&&t[Ge]||t["@@iterator"],typeof t=="function"?t:null)}var Zl=Symbol.for("react.client.reference");function We(t){if(t==null)return null;if(typeof t=="function")return t.$$typeof===Zl?null:t.displayName||t.name||null;if(typeof t=="string")return t;switch(t){case it:return"Fragment";case bt:return"Profiler";case Mt:return"StrictMode";case ee:return"Suspense";case Yt:return"SuspenseList";case Xe:return"Activity"}if(typeof t=="object")switch(t.$$typeof){case St:return"Portal";case Ht:return t.displayName||"Context";case wt:return(t._context.displayName||"Context")+".Consumer";case te:var e=t.render;return t=t.displayName,t||(t=e.displayName||e.name||"",t=t!==""?"ForwardRef("+t+")":"ForwardRef"),t;case $:return e=t.displayName||null,e!==null?e:We(t.type)||"Memo";case zt:e=t._payload,t=t._init;try{return We(t(e))}catch{}}return null}var He=Array.isArray,z=u.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,w=r.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,G={pending:!1,data:null,method:null,action:null},ot=[],yt=-1;function p(t){return{current:t}}function D(t){0>yt||(t.current=ot[yt],ot[yt]=null,yt--)}function H(t,e){yt++,ot[yt]=t.current,t.current=e}var L=p(null),Z=p(null),F=p(null),ct=p(null);function It(t,e){switch(H(F,e),H(Z,t),H(L,null),e.nodeType){case 9:case 11:t=(t=e.documentElement)&&(t=t.namespaceURI)?fd(t):0;break;default:if(t=e.tagName,e=e.namespaceURI)e=fd(e),t=od(e,t);else switch(t){case"svg":t=1;break;case"math":t=2;break;default:t=0}}D(L),H(L,t)}function Dt(){D(L),D(Z),D(F)}function sa(t){t.memoizedState!==null&&H(ct,t);var e=L.current,l=od(e,t.type);e!==l&&(H(Z,t),H(L,l))}function hi(t){Z.current===t&&(D(L),D(Z)),ct.current===t&&(D(ct),$a._currentValue=G)}var Ju,jr;function Jl(t){if(Ju===void 0)try{throw Error()}catch(l){var e=l.stack.trim().match(/\n( *(at )?)/);Ju=e&&e[1]||"",jr=-1<l.stack.indexOf(`
|
|
42
|
-
at`)?" (<anonymous>)":-1<l.stack.indexOf("@")?"@unknown:0:0":""}return`
|
|
43
|
-
`+Ju+t+jr}var ku=!1;function Wu(t,e){if(!t||ku)return"";ku=!0;var l=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var n={DetermineComponentFrameRoot:function(){try{if(e){var O=function(){throw Error()};if(Object.defineProperty(O.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(O,[])}catch(x){var _=x}Reflect.construct(t,[],O)}else{try{O.call()}catch(x){_=x}t.call(O.prototype)}}else{try{throw Error()}catch(x){_=x}(O=t())&&typeof O.catch=="function"&&O.catch(function(){})}}catch(x){if(x&&_&&typeof x.stack=="string")return[x.stack,_.stack]}return[null,null]}};n.DetermineComponentFrameRoot.displayName="DetermineComponentFrameRoot";var a=Object.getOwnPropertyDescriptor(n.DetermineComponentFrameRoot,"name");a&&a.configurable&&Object.defineProperty(n.DetermineComponentFrameRoot,"name",{value:"DetermineComponentFrameRoot"});var i=n.DetermineComponentFrameRoot(),f=i[0],o=i[1];if(f&&o){var m=f.split(`
|
|
44
|
-
`),A=o.split(`
|
|
45
|
-
`);for(a=n=0;n<m.length&&!m[n].includes("DetermineComponentFrameRoot");)n++;for(;a<A.length&&!A[a].includes("DetermineComponentFrameRoot");)a++;if(n===m.length||a===A.length)for(n=m.length-1,a=A.length-1;1<=n&&0<=a&&m[n]!==A[a];)a--;for(;1<=n&&0<=a;n--,a--)if(m[n]!==A[a]){if(n!==1||a!==1)do if(n--,a--,0>a||m[n]!==A[a]){var M=`
|
|
46
|
-
`+m[n].replace(" at new "," at ");return t.displayName&&M.includes("<anonymous>")&&(M=M.replace("<anonymous>",t.displayName)),M}while(1<=n&&0<=a);break}}}finally{ku=!1,Error.prepareStackTrace=l}return(l=t?t.displayName||t.name:"")?Jl(l):""}function iy(t,e){switch(t.tag){case 26:case 27:case 5:return Jl(t.type);case 16:return Jl("Lazy");case 13:return t.child!==e&&e!==null?Jl("Suspense Fallback"):Jl("Suspense");case 19:return Jl("SuspenseList");case 0:case 15:return Wu(t.type,!1);case 11:return Wu(t.type.render,!1);case 1:return Wu(t.type,!0);case 31:return Jl("Activity");default:return""}}function qr(t){try{var e="",l=null;do e+=iy(t,l),l=t,t=t.return;while(t);return e}catch(n){return`
|
|
47
|
-
Error generating stack: `+n.message+`
|
|
48
|
-
`+n.stack}}var $u=Object.prototype.hasOwnProperty,Fu=s.unstable_scheduleCallback,Iu=s.unstable_cancelCallback,uy=s.unstable_shouldYield,sy=s.unstable_requestPaint,oe=s.unstable_now,cy=s.unstable_getCurrentPriorityLevel,Yr=s.unstable_ImmediatePriority,Xr=s.unstable_UserBlockingPriority,di=s.unstable_NormalPriority,ry=s.unstable_LowPriority,Gr=s.unstable_IdlePriority,fy=s.log,oy=s.unstable_setDisableYieldValue,ca=null,he=null;function pl(t){if(typeof fy=="function"&&oy(t),he&&typeof he.setStrictMode=="function")try{he.setStrictMode(ca,t)}catch{}}var de=Math.clz32?Math.clz32:my,hy=Math.log,dy=Math.LN2;function my(t){return t>>>=0,t===0?32:31-(hy(t)/dy|0)|0}var mi=256,yi=262144,gi=4194304;function kl(t){var e=t&42;if(e!==0)return e;switch(t&-t){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:return t&261888;case 262144:case 524288:case 1048576:case 2097152:return t&3932160;case 4194304:case 8388608:case 16777216:case 33554432:return t&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return t}}function pi(t,e,l){var n=t.pendingLanes;if(n===0)return 0;var a=0,i=t.suspendedLanes,f=t.pingedLanes;t=t.warmLanes;var o=n&134217727;return o!==0?(n=o&~i,n!==0?a=kl(n):(f&=o,f!==0?a=kl(f):l||(l=o&~t,l!==0&&(a=kl(l))))):(o=n&~i,o!==0?a=kl(o):f!==0?a=kl(f):l||(l=n&~t,l!==0&&(a=kl(l)))),a===0?0:e!==0&&e!==a&&(e&i)===0&&(i=a&-a,l=e&-e,i>=l||i===32&&(l&4194048)!==0)?e:a}function ra(t,e){return(t.pendingLanes&~(t.suspendedLanes&~t.pingedLanes)&e)===0}function yy(t,e){switch(t){case 1:case 2:case 4:case 8:case 64:return e+250;case 16:case 32:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return e+5e3;case 4194304:case 8388608:case 16777216:case 33554432:return-1;case 67108864:case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function Qr(){var t=gi;return gi<<=1,(gi&62914560)===0&&(gi=4194304),t}function Pu(t){for(var e=[],l=0;31>l;l++)e.push(t);return e}function fa(t,e){t.pendingLanes|=e,e!==268435456&&(t.suspendedLanes=0,t.pingedLanes=0,t.warmLanes=0)}function gy(t,e,l,n,a,i){var f=t.pendingLanes;t.pendingLanes=l,t.suspendedLanes=0,t.pingedLanes=0,t.warmLanes=0,t.expiredLanes&=l,t.entangledLanes&=l,t.errorRecoveryDisabledLanes&=l,t.shellSuspendCounter=0;var o=t.entanglements,m=t.expirationTimes,A=t.hiddenUpdates;for(l=f&~l;0<l;){var M=31-de(l),O=1<<M;o[M]=0,m[M]=-1;var _=A[M];if(_!==null)for(A[M]=null,M=0;M<_.length;M++){var x=_[M];x!==null&&(x.lane&=-536870913)}l&=~O}n!==0&&Kr(t,n,0),i!==0&&a===0&&t.tag!==0&&(t.suspendedLanes|=i&~(f&~e))}function Kr(t,e,l){t.pendingLanes|=e,t.suspendedLanes&=~e;var n=31-de(e);t.entangledLanes|=e,t.entanglements[n]=t.entanglements[n]|1073741824|l&261930}function Vr(t,e){var l=t.entangledLanes|=e;for(t=t.entanglements;l;){var n=31-de(l),a=1<<n;a&e|t[n]&e&&(t[n]|=e),l&=~a}}function Zr(t,e){var l=e&-e;return l=(l&42)!==0?1:ts(l),(l&(t.suspendedLanes|e))!==0?0:l}function ts(t){switch(t){case 2:t=1;break;case 8:t=4;break;case 32:t=16;break;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:t=128;break;case 268435456:t=134217728;break;default:t=0}return t}function es(t){return t&=-t,2<t?8<t?(t&134217727)!==0?32:268435456:8:2}function Jr(){var t=w.p;return t!==0?t:(t=window.event,t===void 0?32:Hd(t.type))}function kr(t,e){var l=w.p;try{return w.p=t,e()}finally{w.p=l}}var vl=Math.random().toString(36).slice(2),Kt="__reactFiber$"+vl,ne="__reactProps$"+vl,yn="__reactContainer$"+vl,ls="__reactEvents$"+vl,py="__reactListeners$"+vl,vy="__reactHandles$"+vl,Wr="__reactResources$"+vl,oa="__reactMarker$"+vl;function ns(t){delete t[Kt],delete t[ne],delete t[ls],delete t[py],delete t[vy]}function gn(t){var e=t[Kt];if(e)return e;for(var l=t.parentNode;l;){if(e=l[yn]||l[Kt]){if(l=e.alternate,e.child!==null||l!==null&&l.child!==null)for(t=vd(t);t!==null;){if(l=t[Kt])return l;t=vd(t)}return e}t=l,l=t.parentNode}return null}function pn(t){if(t=t[Kt]||t[yn]){var e=t.tag;if(e===5||e===6||e===13||e===31||e===26||e===27||e===3)return t}return null}function ha(t){var e=t.tag;if(e===5||e===26||e===27||e===6)return t.stateNode;throw Error(c(33))}function vn(t){var e=t[Wr];return e||(e=t[Wr]={hoistableStyles:new Map,hoistableScripts:new Map}),e}function Xt(t){t[oa]=!0}var $r=new Set,Fr={};function Wl(t,e){Sn(t,e),Sn(t+"Capture",e)}function Sn(t,e){for(Fr[t]=e,t=0;t<e.length;t++)$r.add(e[t])}var Sy=RegExp("^[:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD][:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$"),Ir={},Pr={};function by(t){return $u.call(Pr,t)?!0:$u.call(Ir,t)?!1:Sy.test(t)?Pr[t]=!0:(Ir[t]=!0,!1)}function vi(t,e,l){if(by(e))if(l===null)t.removeAttribute(e);else{switch(typeof l){case"undefined":case"function":case"symbol":t.removeAttribute(e);return;case"boolean":var n=e.toLowerCase().slice(0,5);if(n!=="data-"&&n!=="aria-"){t.removeAttribute(e);return}}t.setAttribute(e,""+l)}}function Si(t,e,l){if(l===null)t.removeAttribute(e);else{switch(typeof l){case"undefined":case"function":case"symbol":case"boolean":t.removeAttribute(e);return}t.setAttribute(e,""+l)}}function $e(t,e,l,n){if(n===null)t.removeAttribute(l);else{switch(typeof n){case"undefined":case"function":case"symbol":case"boolean":t.removeAttribute(l);return}t.setAttributeNS(e,l,""+n)}}function Te(t){switch(typeof t){case"bigint":case"boolean":case"number":case"string":case"undefined":return t;case"object":return t;default:return""}}function tf(t){var e=t.type;return(t=t.nodeName)&&t.toLowerCase()==="input"&&(e==="checkbox"||e==="radio")}function Ey(t,e,l){var n=Object.getOwnPropertyDescriptor(t.constructor.prototype,e);if(!t.hasOwnProperty(e)&&typeof n<"u"&&typeof n.get=="function"&&typeof n.set=="function"){var a=n.get,i=n.set;return Object.defineProperty(t,e,{configurable:!0,get:function(){return a.call(this)},set:function(f){l=""+f,i.call(this,f)}}),Object.defineProperty(t,e,{enumerable:n.enumerable}),{getValue:function(){return l},setValue:function(f){l=""+f},stopTracking:function(){t._valueTracker=null,delete t[e]}}}}function as(t){if(!t._valueTracker){var e=tf(t)?"checked":"value";t._valueTracker=Ey(t,e,""+t[e])}}function ef(t){if(!t)return!1;var e=t._valueTracker;if(!e)return!0;var l=e.getValue(),n="";return t&&(n=tf(t)?t.checked?"true":"false":t.value),t=n,t!==l?(e.setValue(t),!0):!1}function bi(t){if(t=t||(typeof document<"u"?document:void 0),typeof t>"u")return null;try{return t.activeElement||t.body}catch{return t.body}}var Ty=/[\n"\\]/g;function Ae(t){return t.replace(Ty,function(e){return"\\"+e.charCodeAt(0).toString(16)+" "})}function is(t,e,l,n,a,i,f,o){t.name="",f!=null&&typeof f!="function"&&typeof f!="symbol"&&typeof f!="boolean"?t.type=f:t.removeAttribute("type"),e!=null?f==="number"?(e===0&&t.value===""||t.value!=e)&&(t.value=""+Te(e)):t.value!==""+Te(e)&&(t.value=""+Te(e)):f!=="submit"&&f!=="reset"||t.removeAttribute("value"),e!=null?us(t,f,Te(e)):l!=null?us(t,f,Te(l)):n!=null&&t.removeAttribute("value"),a==null&&i!=null&&(t.defaultChecked=!!i),a!=null&&(t.checked=a&&typeof a!="function"&&typeof a!="symbol"),o!=null&&typeof o!="function"&&typeof o!="symbol"&&typeof o!="boolean"?t.name=""+Te(o):t.removeAttribute("name")}function lf(t,e,l,n,a,i,f,o){if(i!=null&&typeof i!="function"&&typeof i!="symbol"&&typeof i!="boolean"&&(t.type=i),e!=null||l!=null){if(!(i!=="submit"&&i!=="reset"||e!=null)){as(t);return}l=l!=null?""+Te(l):"",e=e!=null?""+Te(e):l,o||e===t.value||(t.value=e),t.defaultValue=e}n=n??a,n=typeof n!="function"&&typeof n!="symbol"&&!!n,t.checked=o?t.checked:!!n,t.defaultChecked=!!n,f!=null&&typeof f!="function"&&typeof f!="symbol"&&typeof f!="boolean"&&(t.name=f),as(t)}function us(t,e,l){e==="number"&&bi(t.ownerDocument)===t||t.defaultValue===""+l||(t.defaultValue=""+l)}function bn(t,e,l,n){if(t=t.options,e){e={};for(var a=0;a<l.length;a++)e["$"+l[a]]=!0;for(l=0;l<t.length;l++)a=e.hasOwnProperty("$"+t[l].value),t[l].selected!==a&&(t[l].selected=a),a&&n&&(t[l].defaultSelected=!0)}else{for(l=""+Te(l),e=null,a=0;a<t.length;a++){if(t[a].value===l){t[a].selected=!0,n&&(t[a].defaultSelected=!0);return}e!==null||t[a].disabled||(e=t[a])}e!==null&&(e.selected=!0)}}function nf(t,e,l){if(e!=null&&(e=""+Te(e),e!==t.value&&(t.value=e),l==null)){t.defaultValue!==e&&(t.defaultValue=e);return}t.defaultValue=l!=null?""+Te(l):""}function af(t,e,l,n){if(e==null){if(n!=null){if(l!=null)throw Error(c(92));if(He(n)){if(1<n.length)throw Error(c(93));n=n[0]}l=n}l==null&&(l=""),e=l}l=Te(e),t.defaultValue=l,n=t.textContent,n===l&&n!==""&&n!==null&&(t.value=n),as(t)}function En(t,e){if(e){var l=t.firstChild;if(l&&l===t.lastChild&&l.nodeType===3){l.nodeValue=e;return}}t.textContent=e}var Ay=new Set("animationIterationCount aspectRatio borderImageOutset borderImageSlice borderImageWidth boxFlex boxFlexGroup boxOrdinalGroup columnCount columns flex flexGrow flexPositive flexShrink flexNegative flexOrder gridArea gridRow gridRowEnd gridRowSpan gridRowStart gridColumn gridColumnEnd gridColumnSpan gridColumnStart fontWeight lineClamp lineHeight opacity order orphans scale tabSize widows zIndex zoom fillOpacity floodOpacity stopOpacity strokeDasharray strokeDashoffset strokeMiterlimit strokeOpacity strokeWidth MozAnimationIterationCount MozBoxFlex MozBoxFlexGroup MozLineClamp msAnimationIterationCount msFlex msZoom msFlexGrow msFlexNegative msFlexOrder msFlexPositive msFlexShrink msGridColumn msGridColumnSpan msGridRow msGridRowSpan WebkitAnimationIterationCount WebkitBoxFlex WebKitBoxFlexGroup WebkitBoxOrdinalGroup WebkitColumnCount WebkitColumns WebkitFlex WebkitFlexGrow WebkitFlexPositive WebkitFlexShrink WebkitLineClamp".split(" "));function uf(t,e,l){var n=e.indexOf("--")===0;l==null||typeof l=="boolean"||l===""?n?t.setProperty(e,""):e==="float"?t.cssFloat="":t[e]="":n?t.setProperty(e,l):typeof l!="number"||l===0||Ay.has(e)?e==="float"?t.cssFloat=l:t[e]=(""+l).trim():t[e]=l+"px"}function sf(t,e,l){if(e!=null&&typeof e!="object")throw Error(c(62));if(t=t.style,l!=null){for(var n in l)!l.hasOwnProperty(n)||e!=null&&e.hasOwnProperty(n)||(n.indexOf("--")===0?t.setProperty(n,""):n==="float"?t.cssFloat="":t[n]="");for(var a in e)n=e[a],e.hasOwnProperty(a)&&l[a]!==n&&uf(t,a,n)}else for(var i in e)e.hasOwnProperty(i)&&uf(t,i,e[i])}function ss(t){if(t.indexOf("-")===-1)return!1;switch(t){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 _y=new Map([["acceptCharset","accept-charset"],["htmlFor","for"],["httpEquiv","http-equiv"],["crossOrigin","crossorigin"],["accentHeight","accent-height"],["alignmentBaseline","alignment-baseline"],["arabicForm","arabic-form"],["baselineShift","baseline-shift"],["capHeight","cap-height"],["clipPath","clip-path"],["clipRule","clip-rule"],["colorInterpolation","color-interpolation"],["colorInterpolationFilters","color-interpolation-filters"],["colorProfile","color-profile"],["colorRendering","color-rendering"],["dominantBaseline","dominant-baseline"],["enableBackground","enable-background"],["fillOpacity","fill-opacity"],["fillRule","fill-rule"],["floodColor","flood-color"],["floodOpacity","flood-opacity"],["fontFamily","font-family"],["fontSize","font-size"],["fontSizeAdjust","font-size-adjust"],["fontStretch","font-stretch"],["fontStyle","font-style"],["fontVariant","font-variant"],["fontWeight","font-weight"],["glyphName","glyph-name"],["glyphOrientationHorizontal","glyph-orientation-horizontal"],["glyphOrientationVertical","glyph-orientation-vertical"],["horizAdvX","horiz-adv-x"],["horizOriginX","horiz-origin-x"],["imageRendering","image-rendering"],["letterSpacing","letter-spacing"],["lightingColor","lighting-color"],["markerEnd","marker-end"],["markerMid","marker-mid"],["markerStart","marker-start"],["overlinePosition","overline-position"],["overlineThickness","overline-thickness"],["paintOrder","paint-order"],["panose-1","panose-1"],["pointerEvents","pointer-events"],["renderingIntent","rendering-intent"],["shapeRendering","shape-rendering"],["stopColor","stop-color"],["stopOpacity","stop-opacity"],["strikethroughPosition","strikethrough-position"],["strikethroughThickness","strikethrough-thickness"],["strokeDasharray","stroke-dasharray"],["strokeDashoffset","stroke-dashoffset"],["strokeLinecap","stroke-linecap"],["strokeLinejoin","stroke-linejoin"],["strokeMiterlimit","stroke-miterlimit"],["strokeOpacity","stroke-opacity"],["strokeWidth","stroke-width"],["textAnchor","text-anchor"],["textDecoration","text-decoration"],["textRendering","text-rendering"],["transformOrigin","transform-origin"],["underlinePosition","underline-position"],["underlineThickness","underline-thickness"],["unicodeBidi","unicode-bidi"],["unicodeRange","unicode-range"],["unitsPerEm","units-per-em"],["vAlphabetic","v-alphabetic"],["vHanging","v-hanging"],["vIdeographic","v-ideographic"],["vMathematical","v-mathematical"],["vectorEffect","vector-effect"],["vertAdvY","vert-adv-y"],["vertOriginX","vert-origin-x"],["vertOriginY","vert-origin-y"],["wordSpacing","word-spacing"],["writingMode","writing-mode"],["xmlnsXlink","xmlns:xlink"],["xHeight","x-height"]]),xy=/^[\u0000-\u001F ]*j[\r\n\t]*a[\r\n\t]*v[\r\n\t]*a[\r\n\t]*s[\r\n\t]*c[\r\n\t]*r[\r\n\t]*i[\r\n\t]*p[\r\n\t]*t[\r\n\t]*:/i;function Ei(t){return xy.test(""+t)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":t}function Fe(){}var cs=null;function rs(t){return t=t.target||t.srcElement||window,t.correspondingUseElement&&(t=t.correspondingUseElement),t.nodeType===3?t.parentNode:t}var Tn=null,An=null;function cf(t){var e=pn(t);if(e&&(t=e.stateNode)){var l=t[ne]||null;t:switch(t=e.stateNode,e.type){case"input":if(is(t,l.value,l.defaultValue,l.defaultValue,l.checked,l.defaultChecked,l.type,l.name),e=l.name,l.type==="radio"&&e!=null){for(l=t;l.parentNode;)l=l.parentNode;for(l=l.querySelectorAll('input[name="'+Ae(""+e)+'"][type="radio"]'),e=0;e<l.length;e++){var n=l[e];if(n!==t&&n.form===t.form){var a=n[ne]||null;if(!a)throw Error(c(90));is(n,a.value,a.defaultValue,a.defaultValue,a.checked,a.defaultChecked,a.type,a.name)}}for(e=0;e<l.length;e++)n=l[e],n.form===t.form&&ef(n)}break t;case"textarea":nf(t,l.value,l.defaultValue);break t;case"select":e=l.value,e!=null&&bn(t,!!l.multiple,e,!1)}}}var fs=!1;function rf(t,e,l){if(fs)return t(e,l);fs=!0;try{var n=t(e);return n}finally{if(fs=!1,(Tn!==null||An!==null)&&(cu(),Tn&&(e=Tn,t=An,An=Tn=null,cf(e),t)))for(e=0;e<t.length;e++)cf(t[e])}}function da(t,e){var l=t.stateNode;if(l===null)return null;var n=l[ne]||null;if(n===null)return null;l=n[e];t:switch(e){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(n=!n.disabled)||(t=t.type,n=!(t==="button"||t==="input"||t==="select"||t==="textarea")),t=!n;break t;default:t=!1}if(t)return null;if(l&&typeof l!="function")throw Error(c(231,e,typeof l));return l}var Ie=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),os=!1;if(Ie)try{var ma={};Object.defineProperty(ma,"passive",{get:function(){os=!0}}),window.addEventListener("test",ma,ma),window.removeEventListener("test",ma,ma)}catch{os=!1}var Sl=null,hs=null,Ti=null;function ff(){if(Ti)return Ti;var t,e=hs,l=e.length,n,a="value"in Sl?Sl.value:Sl.textContent,i=a.length;for(t=0;t<l&&e[t]===a[t];t++);var f=l-t;for(n=1;n<=f&&e[l-n]===a[i-n];n++);return Ti=a.slice(t,1<n?1-n:void 0)}function Ai(t){var e=t.keyCode;return"charCode"in t?(t=t.charCode,t===0&&e===13&&(t=13)):t=e,t===10&&(t=13),32<=t||t===13?t:0}function _i(){return!0}function of(){return!1}function ae(t){function e(l,n,a,i,f){this._reactName=l,this._targetInst=a,this.type=n,this.nativeEvent=i,this.target=f,this.currentTarget=null;for(var o in t)t.hasOwnProperty(o)&&(l=t[o],this[o]=l?l(i):i[o]);return this.isDefaultPrevented=(i.defaultPrevented!=null?i.defaultPrevented:i.returnValue===!1)?_i:of,this.isPropagationStopped=of,this}return U(e.prototype,{preventDefault:function(){this.defaultPrevented=!0;var l=this.nativeEvent;l&&(l.preventDefault?l.preventDefault():typeof l.returnValue!="unknown"&&(l.returnValue=!1),this.isDefaultPrevented=_i)},stopPropagation:function(){var l=this.nativeEvent;l&&(l.stopPropagation?l.stopPropagation():typeof l.cancelBubble!="unknown"&&(l.cancelBubble=!0),this.isPropagationStopped=_i)},persist:function(){},isPersistent:_i}),e}var $l={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(t){return t.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},xi=ae($l),ya=U({},$l,{view:0,detail:0}),My=ae(ya),ds,ms,ga,Mi=U({},ya,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:gs,button:0,buttons:0,relatedTarget:function(t){return t.relatedTarget===void 0?t.fromElement===t.srcElement?t.toElement:t.fromElement:t.relatedTarget},movementX:function(t){return"movementX"in t?t.movementX:(t!==ga&&(ga&&t.type==="mousemove"?(ds=t.screenX-ga.screenX,ms=t.screenY-ga.screenY):ms=ds=0,ga=t),ds)},movementY:function(t){return"movementY"in t?t.movementY:ms}}),hf=ae(Mi),zy=U({},Mi,{dataTransfer:0}),Cy=ae(zy),Oy=U({},ya,{relatedTarget:0}),ys=ae(Oy),Dy=U({},$l,{animationName:0,elapsedTime:0,pseudoElement:0}),Ry=ae(Dy),Uy=U({},$l,{clipboardData:function(t){return"clipboardData"in t?t.clipboardData:window.clipboardData}}),wy=ae(Uy),Hy=U({},$l,{data:0}),df=ae(Hy),Ny={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},By={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"},Ly={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function jy(t){var e=this.nativeEvent;return e.getModifierState?e.getModifierState(t):(t=Ly[t])?!!e[t]:!1}function gs(){return jy}var qy=U({},ya,{key:function(t){if(t.key){var e=Ny[t.key]||t.key;if(e!=="Unidentified")return e}return t.type==="keypress"?(t=Ai(t),t===13?"Enter":String.fromCharCode(t)):t.type==="keydown"||t.type==="keyup"?By[t.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:gs,charCode:function(t){return t.type==="keypress"?Ai(t):0},keyCode:function(t){return t.type==="keydown"||t.type==="keyup"?t.keyCode:0},which:function(t){return t.type==="keypress"?Ai(t):t.type==="keydown"||t.type==="keyup"?t.keyCode:0}}),Yy=ae(qy),Xy=U({},Mi,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),mf=ae(Xy),Gy=U({},ya,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:gs}),Qy=ae(Gy),Ky=U({},$l,{propertyName:0,elapsedTime:0,pseudoElement:0}),Vy=ae(Ky),Zy=U({},Mi,{deltaX:function(t){return"deltaX"in t?t.deltaX:"wheelDeltaX"in t?-t.wheelDeltaX:0},deltaY:function(t){return"deltaY"in t?t.deltaY:"wheelDeltaY"in t?-t.wheelDeltaY:"wheelDelta"in t?-t.wheelDelta:0},deltaZ:0,deltaMode:0}),Jy=ae(Zy),ky=U({},$l,{newState:0,oldState:0}),Wy=ae(ky),$y=[9,13,27,32],ps=Ie&&"CompositionEvent"in window,pa=null;Ie&&"documentMode"in document&&(pa=document.documentMode);var Fy=Ie&&"TextEvent"in window&&!pa,yf=Ie&&(!ps||pa&&8<pa&&11>=pa),gf=" ",pf=!1;function vf(t,e){switch(t){case"keyup":return $y.indexOf(e.keyCode)!==-1;case"keydown":return e.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function Sf(t){return t=t.detail,typeof t=="object"&&"data"in t?t.data:null}var _n=!1;function Iy(t,e){switch(t){case"compositionend":return Sf(e);case"keypress":return e.which!==32?null:(pf=!0,gf);case"textInput":return t=e.data,t===gf&&pf?null:t;default:return null}}function Py(t,e){if(_n)return t==="compositionend"||!ps&&vf(t,e)?(t=ff(),Ti=hs=Sl=null,_n=!1,t):null;switch(t){case"paste":return null;case"keypress":if(!(e.ctrlKey||e.altKey||e.metaKey)||e.ctrlKey&&e.altKey){if(e.char&&1<e.char.length)return e.char;if(e.which)return String.fromCharCode(e.which)}return null;case"compositionend":return yf&&e.locale!=="ko"?null:e.data;default:return null}}var tg={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 bf(t){var e=t&&t.nodeName&&t.nodeName.toLowerCase();return e==="input"?!!tg[t.type]:e==="textarea"}function Ef(t,e,l,n){Tn?An?An.push(n):An=[n]:Tn=n,e=yu(e,"onChange"),0<e.length&&(l=new xi("onChange","change",null,l,n),t.push({event:l,listeners:e}))}var va=null,Sa=null;function eg(t){ad(t,0)}function zi(t){var e=ha(t);if(ef(e))return t}function Tf(t,e){if(t==="change")return e}var Af=!1;if(Ie){var vs;if(Ie){var Ss="oninput"in document;if(!Ss){var _f=document.createElement("div");_f.setAttribute("oninput","return;"),Ss=typeof _f.oninput=="function"}vs=Ss}else vs=!1;Af=vs&&(!document.documentMode||9<document.documentMode)}function xf(){va&&(va.detachEvent("onpropertychange",Mf),Sa=va=null)}function Mf(t){if(t.propertyName==="value"&&zi(Sa)){var e=[];Ef(e,Sa,t,rs(t)),rf(eg,e)}}function lg(t,e,l){t==="focusin"?(xf(),va=e,Sa=l,va.attachEvent("onpropertychange",Mf)):t==="focusout"&&xf()}function ng(t){if(t==="selectionchange"||t==="keyup"||t==="keydown")return zi(Sa)}function ag(t,e){if(t==="click")return zi(e)}function ig(t,e){if(t==="input"||t==="change")return zi(e)}function ug(t,e){return t===e&&(t!==0||1/t===1/e)||t!==t&&e!==e}var me=typeof Object.is=="function"?Object.is:ug;function ba(t,e){if(me(t,e))return!0;if(typeof t!="object"||t===null||typeof e!="object"||e===null)return!1;var l=Object.keys(t),n=Object.keys(e);if(l.length!==n.length)return!1;for(n=0;n<l.length;n++){var a=l[n];if(!$u.call(e,a)||!me(t[a],e[a]))return!1}return!0}function zf(t){for(;t&&t.firstChild;)t=t.firstChild;return t}function Cf(t,e){var l=zf(t);t=0;for(var n;l;){if(l.nodeType===3){if(n=t+l.textContent.length,t<=e&&n>=e)return{node:l,offset:e-t};t=n}t:{for(;l;){if(l.nextSibling){l=l.nextSibling;break t}l=l.parentNode}l=void 0}l=zf(l)}}function Of(t,e){return t&&e?t===e?!0:t&&t.nodeType===3?!1:e&&e.nodeType===3?Of(t,e.parentNode):"contains"in t?t.contains(e):t.compareDocumentPosition?!!(t.compareDocumentPosition(e)&16):!1:!1}function Df(t){t=t!=null&&t.ownerDocument!=null&&t.ownerDocument.defaultView!=null?t.ownerDocument.defaultView:window;for(var e=bi(t.document);e instanceof t.HTMLIFrameElement;){try{var l=typeof e.contentWindow.location.href=="string"}catch{l=!1}if(l)t=e.contentWindow;else break;e=bi(t.document)}return e}function bs(t){var e=t&&t.nodeName&&t.nodeName.toLowerCase();return e&&(e==="input"&&(t.type==="text"||t.type==="search"||t.type==="tel"||t.type==="url"||t.type==="password")||e==="textarea"||t.contentEditable==="true")}var sg=Ie&&"documentMode"in document&&11>=document.documentMode,xn=null,Es=null,Ea=null,Ts=!1;function Rf(t,e,l){var n=l.window===l?l.document:l.nodeType===9?l:l.ownerDocument;Ts||xn==null||xn!==bi(n)||(n=xn,"selectionStart"in n&&bs(n)?n={start:n.selectionStart,end:n.selectionEnd}:(n=(n.ownerDocument&&n.ownerDocument.defaultView||window).getSelection(),n={anchorNode:n.anchorNode,anchorOffset:n.anchorOffset,focusNode:n.focusNode,focusOffset:n.focusOffset}),Ea&&ba(Ea,n)||(Ea=n,n=yu(Es,"onSelect"),0<n.length&&(e=new xi("onSelect","select",null,e,l),t.push({event:e,listeners:n}),e.target=xn)))}function Fl(t,e){var l={};return l[t.toLowerCase()]=e.toLowerCase(),l["Webkit"+t]="webkit"+e,l["Moz"+t]="moz"+e,l}var Mn={animationend:Fl("Animation","AnimationEnd"),animationiteration:Fl("Animation","AnimationIteration"),animationstart:Fl("Animation","AnimationStart"),transitionrun:Fl("Transition","TransitionRun"),transitionstart:Fl("Transition","TransitionStart"),transitioncancel:Fl("Transition","TransitionCancel"),transitionend:Fl("Transition","TransitionEnd")},As={},Uf={};Ie&&(Uf=document.createElement("div").style,"AnimationEvent"in window||(delete Mn.animationend.animation,delete Mn.animationiteration.animation,delete Mn.animationstart.animation),"TransitionEvent"in window||delete Mn.transitionend.transition);function Il(t){if(As[t])return As[t];if(!Mn[t])return t;var e=Mn[t],l;for(l in e)if(e.hasOwnProperty(l)&&l in Uf)return As[t]=e[l];return t}var wf=Il("animationend"),Hf=Il("animationiteration"),Nf=Il("animationstart"),cg=Il("transitionrun"),rg=Il("transitionstart"),fg=Il("transitioncancel"),Bf=Il("transitionend"),Lf=new Map,_s="abort auxClick beforeToggle cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel".split(" ");_s.push("scrollEnd");function Ne(t,e){Lf.set(t,e),Wl(e,[t])}var Ci=typeof reportError=="function"?reportError:function(t){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var e=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof t=="object"&&t!==null&&typeof t.message=="string"?String(t.message):String(t),error:t});if(!window.dispatchEvent(e))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",t);return}console.error(t)},_e=[],zn=0,xs=0;function Oi(){for(var t=zn,e=xs=zn=0;e<t;){var l=_e[e];_e[e++]=null;var n=_e[e];_e[e++]=null;var a=_e[e];_e[e++]=null;var i=_e[e];if(_e[e++]=null,n!==null&&a!==null){var f=n.pending;f===null?a.next=a:(a.next=f.next,f.next=a),n.pending=a}i!==0&&jf(l,a,i)}}function Di(t,e,l,n){_e[zn++]=t,_e[zn++]=e,_e[zn++]=l,_e[zn++]=n,xs|=n,t.lanes|=n,t=t.alternate,t!==null&&(t.lanes|=n)}function Ms(t,e,l,n){return Di(t,e,l,n),Ri(t)}function Pl(t,e){return Di(t,null,null,e),Ri(t)}function jf(t,e,l){t.lanes|=l;var n=t.alternate;n!==null&&(n.lanes|=l);for(var a=!1,i=t.return;i!==null;)i.childLanes|=l,n=i.alternate,n!==null&&(n.childLanes|=l),i.tag===22&&(t=i.stateNode,t===null||t._visibility&1||(a=!0)),t=i,i=i.return;return t.tag===3?(i=t.stateNode,a&&e!==null&&(a=31-de(l),t=i.hiddenUpdates,n=t[a],n===null?t[a]=[e]:n.push(e),e.lane=l|536870912),i):null}function Ri(t){if(50<Qa)throw Qa=0,Nc=null,Error(c(185));for(var e=t.return;e!==null;)t=e,e=t.return;return t.tag===3?t.stateNode:null}var Cn={};function og(t,e,l,n){this.tag=t,this.key=l,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=e,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=n,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function ye(t,e,l,n){return new og(t,e,l,n)}function zs(t){return t=t.prototype,!(!t||!t.isReactComponent)}function Pe(t,e){var l=t.alternate;return l===null?(l=ye(t.tag,e,t.key,t.mode),l.elementType=t.elementType,l.type=t.type,l.stateNode=t.stateNode,l.alternate=t,t.alternate=l):(l.pendingProps=e,l.type=t.type,l.flags=0,l.subtreeFlags=0,l.deletions=null),l.flags=t.flags&65011712,l.childLanes=t.childLanes,l.lanes=t.lanes,l.child=t.child,l.memoizedProps=t.memoizedProps,l.memoizedState=t.memoizedState,l.updateQueue=t.updateQueue,e=t.dependencies,l.dependencies=e===null?null:{lanes:e.lanes,firstContext:e.firstContext},l.sibling=t.sibling,l.index=t.index,l.ref=t.ref,l.refCleanup=t.refCleanup,l}function qf(t,e){t.flags&=65011714;var l=t.alternate;return l===null?(t.childLanes=0,t.lanes=e,t.child=null,t.subtreeFlags=0,t.memoizedProps=null,t.memoizedState=null,t.updateQueue=null,t.dependencies=null,t.stateNode=null):(t.childLanes=l.childLanes,t.lanes=l.lanes,t.child=l.child,t.subtreeFlags=0,t.deletions=null,t.memoizedProps=l.memoizedProps,t.memoizedState=l.memoizedState,t.updateQueue=l.updateQueue,t.type=l.type,e=l.dependencies,t.dependencies=e===null?null:{lanes:e.lanes,firstContext:e.firstContext}),t}function Ui(t,e,l,n,a,i){var f=0;if(n=t,typeof t=="function")zs(t)&&(f=1);else if(typeof t=="string")f=gp(t,l,L.current)?26:t==="html"||t==="head"||t==="body"?27:5;else t:switch(t){case Xe:return t=ye(31,l,e,a),t.elementType=Xe,t.lanes=i,t;case it:return tn(l.children,a,i,e);case Mt:f=8,a|=24;break;case bt:return t=ye(12,l,e,a|2),t.elementType=bt,t.lanes=i,t;case ee:return t=ye(13,l,e,a),t.elementType=ee,t.lanes=i,t;case Yt:return t=ye(19,l,e,a),t.elementType=Yt,t.lanes=i,t;default:if(typeof t=="object"&&t!==null)switch(t.$$typeof){case Ht:f=10;break t;case wt:f=9;break t;case te:f=11;break t;case $:f=14;break t;case zt:f=16,n=null;break t}f=29,l=Error(c(130,t===null?"null":typeof t,"")),n=null}return e=ye(f,l,e,a),e.elementType=t,e.type=n,e.lanes=i,e}function tn(t,e,l,n){return t=ye(7,t,n,e),t.lanes=l,t}function Cs(t,e,l){return t=ye(6,t,null,e),t.lanes=l,t}function Yf(t){var e=ye(18,null,null,0);return e.stateNode=t,e}function Os(t,e,l){return e=ye(4,t.children!==null?t.children:[],t.key,e),e.lanes=l,e.stateNode={containerInfo:t.containerInfo,pendingChildren:null,implementation:t.implementation},e}var Xf=new WeakMap;function xe(t,e){if(typeof t=="object"&&t!==null){var l=Xf.get(t);return l!==void 0?l:(e={value:t,source:e,stack:qr(e)},Xf.set(t,e),e)}return{value:t,source:e,stack:qr(e)}}var On=[],Dn=0,wi=null,Ta=0,Me=[],ze=0,bl=null,Qe=1,Ke="";function tl(t,e){On[Dn++]=Ta,On[Dn++]=wi,wi=t,Ta=e}function Gf(t,e,l){Me[ze++]=Qe,Me[ze++]=Ke,Me[ze++]=bl,bl=t;var n=Qe;t=Ke;var a=32-de(n)-1;n&=~(1<<a),l+=1;var i=32-de(e)+a;if(30<i){var f=a-a%5;i=(n&(1<<f)-1).toString(32),n>>=f,a-=f,Qe=1<<32-de(e)+a|l<<a|n,Ke=i+t}else Qe=1<<i|l<<a|n,Ke=t}function Ds(t){t.return!==null&&(tl(t,1),Gf(t,1,0))}function Rs(t){for(;t===wi;)wi=On[--Dn],On[Dn]=null,Ta=On[--Dn],On[Dn]=null;for(;t===bl;)bl=Me[--ze],Me[ze]=null,Ke=Me[--ze],Me[ze]=null,Qe=Me[--ze],Me[ze]=null}function Qf(t,e){Me[ze++]=Qe,Me[ze++]=Ke,Me[ze++]=bl,Qe=e.id,Ke=e.overflow,bl=t}var Vt=null,Et=null,lt=!1,El=null,Ce=!1,Us=Error(c(519));function Tl(t){var e=Error(c(418,1<arguments.length&&arguments[1]!==void 0&&arguments[1]?"text":"HTML",""));throw Aa(xe(e,t)),Us}function Kf(t){var e=t.stateNode,l=t.type,n=t.memoizedProps;switch(e[Kt]=t,e[ne]=n,l){case"dialog":P("cancel",e),P("close",e);break;case"iframe":case"object":case"embed":P("load",e);break;case"video":case"audio":for(l=0;l<Va.length;l++)P(Va[l],e);break;case"source":P("error",e);break;case"img":case"image":case"link":P("error",e),P("load",e);break;case"details":P("toggle",e);break;case"input":P("invalid",e),lf(e,n.value,n.defaultValue,n.checked,n.defaultChecked,n.type,n.name,!0);break;case"select":P("invalid",e);break;case"textarea":P("invalid",e),af(e,n.value,n.defaultValue,n.children)}l=n.children,typeof l!="string"&&typeof l!="number"&&typeof l!="bigint"||e.textContent===""+l||n.suppressHydrationWarning===!0||cd(e.textContent,l)?(n.popover!=null&&(P("beforetoggle",e),P("toggle",e)),n.onScroll!=null&&P("scroll",e),n.onScrollEnd!=null&&P("scrollend",e),n.onClick!=null&&(e.onclick=Fe),e=!0):e=!1,e||Tl(t,!0)}function Vf(t){for(Vt=t.return;Vt;)switch(Vt.tag){case 5:case 31:case 13:Ce=!1;return;case 27:case 3:Ce=!0;return;default:Vt=Vt.return}}function Rn(t){if(t!==Vt)return!1;if(!lt)return Vf(t),lt=!0,!1;var e=t.tag,l;if((l=e!==3&&e!==27)&&((l=e===5)&&(l=t.type,l=!(l!=="form"&&l!=="button")||$c(t.type,t.memoizedProps)),l=!l),l&&Et&&Tl(t),Vf(t),e===13){if(t=t.memoizedState,t=t!==null?t.dehydrated:null,!t)throw Error(c(317));Et=pd(t)}else if(e===31){if(t=t.memoizedState,t=t!==null?t.dehydrated:null,!t)throw Error(c(317));Et=pd(t)}else e===27?(e=Et,Bl(t.type)?(t=er,er=null,Et=t):Et=e):Et=Vt?De(t.stateNode.nextSibling):null;return!0}function en(){Et=Vt=null,lt=!1}function ws(){var t=El;return t!==null&&(ce===null?ce=t:ce.push.apply(ce,t),El=null),t}function Aa(t){El===null?El=[t]:El.push(t)}var Hs=p(null),ln=null,el=null;function Al(t,e,l){H(Hs,e._currentValue),e._currentValue=l}function ll(t){t._currentValue=Hs.current,D(Hs)}function Ns(t,e,l){for(;t!==null;){var n=t.alternate;if((t.childLanes&e)!==e?(t.childLanes|=e,n!==null&&(n.childLanes|=e)):n!==null&&(n.childLanes&e)!==e&&(n.childLanes|=e),t===l)break;t=t.return}}function Bs(t,e,l,n){var a=t.child;for(a!==null&&(a.return=t);a!==null;){var i=a.dependencies;if(i!==null){var f=a.child;i=i.firstContext;t:for(;i!==null;){var o=i;i=a;for(var m=0;m<e.length;m++)if(o.context===e[m]){i.lanes|=l,o=i.alternate,o!==null&&(o.lanes|=l),Ns(i.return,l,t),n||(f=null);break t}i=o.next}}else if(a.tag===18){if(f=a.return,f===null)throw Error(c(341));f.lanes|=l,i=f.alternate,i!==null&&(i.lanes|=l),Ns(f,l,t),f=null}else f=a.child;if(f!==null)f.return=a;else for(f=a;f!==null;){if(f===t){f=null;break}if(a=f.sibling,a!==null){a.return=f.return,f=a;break}f=f.return}a=f}}function Un(t,e,l,n){t=null;for(var a=e,i=!1;a!==null;){if(!i){if((a.flags&524288)!==0)i=!0;else if((a.flags&262144)!==0)break}if(a.tag===10){var f=a.alternate;if(f===null)throw Error(c(387));if(f=f.memoizedProps,f!==null){var o=a.type;me(a.pendingProps.value,f.value)||(t!==null?t.push(o):t=[o])}}else if(a===ct.current){if(f=a.alternate,f===null)throw Error(c(387));f.memoizedState.memoizedState!==a.memoizedState.memoizedState&&(t!==null?t.push($a):t=[$a])}a=a.return}t!==null&&Bs(e,t,l,n),e.flags|=262144}function Hi(t){for(t=t.firstContext;t!==null;){if(!me(t.context._currentValue,t.memoizedValue))return!0;t=t.next}return!1}function nn(t){ln=t,el=null,t=t.dependencies,t!==null&&(t.firstContext=null)}function Zt(t){return Zf(ln,t)}function Ni(t,e){return ln===null&&nn(t),Zf(t,e)}function Zf(t,e){var l=e._currentValue;if(e={context:e,memoizedValue:l,next:null},el===null){if(t===null)throw Error(c(308));el=e,t.dependencies={lanes:0,firstContext:e},t.flags|=524288}else el=el.next=e;return l}var hg=typeof AbortController<"u"?AbortController:function(){var t=[],e=this.signal={aborted:!1,addEventListener:function(l,n){t.push(n)}};this.abort=function(){e.aborted=!0,t.forEach(function(l){return l()})}},dg=s.unstable_scheduleCallback,mg=s.unstable_NormalPriority,Nt={$$typeof:Ht,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function Ls(){return{controller:new hg,data:new Map,refCount:0}}function _a(t){t.refCount--,t.refCount===0&&dg(mg,function(){t.controller.abort()})}var xa=null,js=0,wn=0,Hn=null;function yg(t,e){if(xa===null){var l=xa=[];js=0,wn=Xc(),Hn={status:"pending",value:void 0,then:function(n){l.push(n)}}}return js++,e.then(Jf,Jf),e}function Jf(){if(--js===0&&xa!==null){Hn!==null&&(Hn.status="fulfilled");var t=xa;xa=null,wn=0,Hn=null;for(var e=0;e<t.length;e++)(0,t[e])()}}function gg(t,e){var l=[],n={status:"pending",value:null,reason:null,then:function(a){l.push(a)}};return t.then(function(){n.status="fulfilled",n.value=e;for(var a=0;a<l.length;a++)(0,l[a])(e)},function(a){for(n.status="rejected",n.reason=a,a=0;a<l.length;a++)(0,l[a])(void 0)}),n}var kf=z.S;z.S=function(t,e){Uh=oe(),typeof e=="object"&&e!==null&&typeof e.then=="function"&&yg(t,e),kf!==null&&kf(t,e)};var an=p(null);function qs(){var t=an.current;return t!==null?t:gt.pooledCache}function Bi(t,e){e===null?H(an,an.current):H(an,e.pool)}function Wf(){var t=qs();return t===null?null:{parent:Nt._currentValue,pool:t}}var Nn=Error(c(460)),Ys=Error(c(474)),Li=Error(c(542)),ji={then:function(){}};function $f(t){return t=t.status,t==="fulfilled"||t==="rejected"}function Ff(t,e,l){switch(l=t[l],l===void 0?t.push(e):l!==e&&(e.then(Fe,Fe),e=l),e.status){case"fulfilled":return e.value;case"rejected":throw t=e.reason,Pf(t),t;default:if(typeof e.status=="string")e.then(Fe,Fe);else{if(t=gt,t!==null&&100<t.shellSuspendCounter)throw Error(c(482));t=e,t.status="pending",t.then(function(n){if(e.status==="pending"){var a=e;a.status="fulfilled",a.value=n}},function(n){if(e.status==="pending"){var a=e;a.status="rejected",a.reason=n}})}switch(e.status){case"fulfilled":return e.value;case"rejected":throw t=e.reason,Pf(t),t}throw sn=e,Nn}}function un(t){try{var e=t._init;return e(t._payload)}catch(l){throw l!==null&&typeof l=="object"&&typeof l.then=="function"?(sn=l,Nn):l}}var sn=null;function If(){if(sn===null)throw Error(c(459));var t=sn;return sn=null,t}function Pf(t){if(t===Nn||t===Li)throw Error(c(483))}var Bn=null,Ma=0;function qi(t){var e=Ma;return Ma+=1,Bn===null&&(Bn=[]),Ff(Bn,t,e)}function za(t,e){e=e.props.ref,t.ref=e!==void 0?e:null}function Yi(t,e){throw e.$$typeof===W?Error(c(525)):(t=Object.prototype.toString.call(e),Error(c(31,t==="[object Object]"?"object with keys {"+Object.keys(e).join(", ")+"}":t)))}function to(t){function e(S,g){if(t){var T=S.deletions;T===null?(S.deletions=[g],S.flags|=16):T.push(g)}}function l(S,g){if(!t)return null;for(;g!==null;)e(S,g),g=g.sibling;return null}function n(S){for(var g=new Map;S!==null;)S.key!==null?g.set(S.key,S):g.set(S.index,S),S=S.sibling;return g}function a(S,g){return S=Pe(S,g),S.index=0,S.sibling=null,S}function i(S,g,T){return S.index=T,t?(T=S.alternate,T!==null?(T=T.index,T<g?(S.flags|=67108866,g):T):(S.flags|=67108866,g)):(S.flags|=1048576,g)}function f(S){return t&&S.alternate===null&&(S.flags|=67108866),S}function o(S,g,T,C){return g===null||g.tag!==6?(g=Cs(T,S.mode,C),g.return=S,g):(g=a(g,T),g.return=S,g)}function m(S,g,T,C){var q=T.type;return q===it?M(S,g,T.props.children,C,T.key):g!==null&&(g.elementType===q||typeof q=="object"&&q!==null&&q.$$typeof===zt&&un(q)===g.type)?(g=a(g,T.props),za(g,T),g.return=S,g):(g=Ui(T.type,T.key,T.props,null,S.mode,C),za(g,T),g.return=S,g)}function A(S,g,T,C){return g===null||g.tag!==4||g.stateNode.containerInfo!==T.containerInfo||g.stateNode.implementation!==T.implementation?(g=Os(T,S.mode,C),g.return=S,g):(g=a(g,T.children||[]),g.return=S,g)}function M(S,g,T,C,q){return g===null||g.tag!==7?(g=tn(T,S.mode,C,q),g.return=S,g):(g=a(g,T),g.return=S,g)}function O(S,g,T){if(typeof g=="string"&&g!==""||typeof g=="number"||typeof g=="bigint")return g=Cs(""+g,S.mode,T),g.return=S,g;if(typeof g=="object"&&g!==null){switch(g.$$typeof){case st:return T=Ui(g.type,g.key,g.props,null,S.mode,T),za(T,g),T.return=S,T;case St:return g=Os(g,S.mode,T),g.return=S,g;case zt:return g=un(g),O(S,g,T)}if(He(g)||le(g))return g=tn(g,S.mode,T,null),g.return=S,g;if(typeof g.then=="function")return O(S,qi(g),T);if(g.$$typeof===Ht)return O(S,Ni(S,g),T);Yi(S,g)}return null}function _(S,g,T,C){var q=g!==null?g.key:null;if(typeof T=="string"&&T!==""||typeof T=="number"||typeof T=="bigint")return q!==null?null:o(S,g,""+T,C);if(typeof T=="object"&&T!==null){switch(T.$$typeof){case st:return T.key===q?m(S,g,T,C):null;case St:return T.key===q?A(S,g,T,C):null;case zt:return T=un(T),_(S,g,T,C)}if(He(T)||le(T))return q!==null?null:M(S,g,T,C,null);if(typeof T.then=="function")return _(S,g,qi(T),C);if(T.$$typeof===Ht)return _(S,g,Ni(S,T),C);Yi(S,T)}return null}function x(S,g,T,C,q){if(typeof C=="string"&&C!==""||typeof C=="number"||typeof C=="bigint")return S=S.get(T)||null,o(g,S,""+C,q);if(typeof C=="object"&&C!==null){switch(C.$$typeof){case st:return S=S.get(C.key===null?T:C.key)||null,m(g,S,C,q);case St:return S=S.get(C.key===null?T:C.key)||null,A(g,S,C,q);case zt:return C=un(C),x(S,g,T,C,q)}if(He(C)||le(C))return S=S.get(T)||null,M(g,S,C,q,null);if(typeof C.then=="function")return x(S,g,T,qi(C),q);if(C.$$typeof===Ht)return x(S,g,T,Ni(g,C),q);Yi(g,C)}return null}function B(S,g,T,C){for(var q=null,nt=null,j=g,k=g=0,et=null;j!==null&&k<T.length;k++){j.index>k?(et=j,j=null):et=j.sibling;var at=_(S,j,T[k],C);if(at===null){j===null&&(j=et);break}t&&j&&at.alternate===null&&e(S,j),g=i(at,g,k),nt===null?q=at:nt.sibling=at,nt=at,j=et}if(k===T.length)return l(S,j),lt&&tl(S,k),q;if(j===null){for(;k<T.length;k++)j=O(S,T[k],C),j!==null&&(g=i(j,g,k),nt===null?q=j:nt.sibling=j,nt=j);return lt&&tl(S,k),q}for(j=n(j);k<T.length;k++)et=x(j,S,k,T[k],C),et!==null&&(t&&et.alternate!==null&&j.delete(et.key===null?k:et.key),g=i(et,g,k),nt===null?q=et:nt.sibling=et,nt=et);return t&&j.forEach(function(Xl){return e(S,Xl)}),lt&&tl(S,k),q}function Y(S,g,T,C){if(T==null)throw Error(c(151));for(var q=null,nt=null,j=g,k=g=0,et=null,at=T.next();j!==null&&!at.done;k++,at=T.next()){j.index>k?(et=j,j=null):et=j.sibling;var Xl=_(S,j,at.value,C);if(Xl===null){j===null&&(j=et);break}t&&j&&Xl.alternate===null&&e(S,j),g=i(Xl,g,k),nt===null?q=Xl:nt.sibling=Xl,nt=Xl,j=et}if(at.done)return l(S,j),lt&&tl(S,k),q;if(j===null){for(;!at.done;k++,at=T.next())at=O(S,at.value,C),at!==null&&(g=i(at,g,k),nt===null?q=at:nt.sibling=at,nt=at);return lt&&tl(S,k),q}for(j=n(j);!at.done;k++,at=T.next())at=x(j,S,k,at.value,C),at!==null&&(t&&at.alternate!==null&&j.delete(at.key===null?k:at.key),g=i(at,g,k),nt===null?q=at:nt.sibling=at,nt=at);return t&&j.forEach(function(zp){return e(S,zp)}),lt&&tl(S,k),q}function mt(S,g,T,C){if(typeof T=="object"&&T!==null&&T.type===it&&T.key===null&&(T=T.props.children),typeof T=="object"&&T!==null){switch(T.$$typeof){case st:t:{for(var q=T.key;g!==null;){if(g.key===q){if(q=T.type,q===it){if(g.tag===7){l(S,g.sibling),C=a(g,T.props.children),C.return=S,S=C;break t}}else if(g.elementType===q||typeof q=="object"&&q!==null&&q.$$typeof===zt&&un(q)===g.type){l(S,g.sibling),C=a(g,T.props),za(C,T),C.return=S,S=C;break t}l(S,g);break}else e(S,g);g=g.sibling}T.type===it?(C=tn(T.props.children,S.mode,C,T.key),C.return=S,S=C):(C=Ui(T.type,T.key,T.props,null,S.mode,C),za(C,T),C.return=S,S=C)}return f(S);case St:t:{for(q=T.key;g!==null;){if(g.key===q)if(g.tag===4&&g.stateNode.containerInfo===T.containerInfo&&g.stateNode.implementation===T.implementation){l(S,g.sibling),C=a(g,T.children||[]),C.return=S,S=C;break t}else{l(S,g);break}else e(S,g);g=g.sibling}C=Os(T,S.mode,C),C.return=S,S=C}return f(S);case zt:return T=un(T),mt(S,g,T,C)}if(He(T))return B(S,g,T,C);if(le(T)){if(q=le(T),typeof q!="function")throw Error(c(150));return T=q.call(T),Y(S,g,T,C)}if(typeof T.then=="function")return mt(S,g,qi(T),C);if(T.$$typeof===Ht)return mt(S,g,Ni(S,T),C);Yi(S,T)}return typeof T=="string"&&T!==""||typeof T=="number"||typeof T=="bigint"?(T=""+T,g!==null&&g.tag===6?(l(S,g.sibling),C=a(g,T),C.return=S,S=C):(l(S,g),C=Cs(T,S.mode,C),C.return=S,S=C),f(S)):l(S,g)}return function(S,g,T,C){try{Ma=0;var q=mt(S,g,T,C);return Bn=null,q}catch(j){if(j===Nn||j===Li)throw j;var nt=ye(29,j,null,S.mode);return nt.lanes=C,nt.return=S,nt}finally{}}}var cn=to(!0),eo=to(!1),_l=!1;function Xs(t){t.updateQueue={baseState:t.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function Gs(t,e){t=t.updateQueue,e.updateQueue===t&&(e.updateQueue={baseState:t.baseState,firstBaseUpdate:t.firstBaseUpdate,lastBaseUpdate:t.lastBaseUpdate,shared:t.shared,callbacks:null})}function xl(t){return{lane:t,tag:0,payload:null,callback:null,next:null}}function Ml(t,e,l){var n=t.updateQueue;if(n===null)return null;if(n=n.shared,(ut&2)!==0){var a=n.pending;return a===null?e.next=e:(e.next=a.next,a.next=e),n.pending=e,e=Ri(t),jf(t,null,l),e}return Di(t,n,e,l),Ri(t)}function Ca(t,e,l){if(e=e.updateQueue,e!==null&&(e=e.shared,(l&4194048)!==0)){var n=e.lanes;n&=t.pendingLanes,l|=n,e.lanes=l,Vr(t,l)}}function Qs(t,e){var l=t.updateQueue,n=t.alternate;if(n!==null&&(n=n.updateQueue,l===n)){var a=null,i=null;if(l=l.firstBaseUpdate,l!==null){do{var f={lane:l.lane,tag:l.tag,payload:l.payload,callback:null,next:null};i===null?a=i=f:i=i.next=f,l=l.next}while(l!==null);i===null?a=i=e:i=i.next=e}else a=i=e;l={baseState:n.baseState,firstBaseUpdate:a,lastBaseUpdate:i,shared:n.shared,callbacks:n.callbacks},t.updateQueue=l;return}t=l.lastBaseUpdate,t===null?l.firstBaseUpdate=e:t.next=e,l.lastBaseUpdate=e}var Ks=!1;function Oa(){if(Ks){var t=Hn;if(t!==null)throw t}}function Da(t,e,l,n){Ks=!1;var a=t.updateQueue;_l=!1;var i=a.firstBaseUpdate,f=a.lastBaseUpdate,o=a.shared.pending;if(o!==null){a.shared.pending=null;var m=o,A=m.next;m.next=null,f===null?i=A:f.next=A,f=m;var M=t.alternate;M!==null&&(M=M.updateQueue,o=M.lastBaseUpdate,o!==f&&(o===null?M.firstBaseUpdate=A:o.next=A,M.lastBaseUpdate=m))}if(i!==null){var O=a.baseState;f=0,M=A=m=null,o=i;do{var _=o.lane&-536870913,x=_!==o.lane;if(x?(tt&_)===_:(n&_)===_){_!==0&&_===wn&&(Ks=!0),M!==null&&(M=M.next={lane:0,tag:o.tag,payload:o.payload,callback:null,next:null});t:{var B=t,Y=o;_=e;var mt=l;switch(Y.tag){case 1:if(B=Y.payload,typeof B=="function"){O=B.call(mt,O,_);break t}O=B;break t;case 3:B.flags=B.flags&-65537|128;case 0:if(B=Y.payload,_=typeof B=="function"?B.call(mt,O,_):B,_==null)break t;O=U({},O,_);break t;case 2:_l=!0}}_=o.callback,_!==null&&(t.flags|=64,x&&(t.flags|=8192),x=a.callbacks,x===null?a.callbacks=[_]:x.push(_))}else x={lane:_,tag:o.tag,payload:o.payload,callback:o.callback,next:null},M===null?(A=M=x,m=O):M=M.next=x,f|=_;if(o=o.next,o===null){if(o=a.shared.pending,o===null)break;x=o,o=x.next,x.next=null,a.lastBaseUpdate=x,a.shared.pending=null}}while(!0);M===null&&(m=O),a.baseState=m,a.firstBaseUpdate=A,a.lastBaseUpdate=M,i===null&&(a.shared.lanes=0),Rl|=f,t.lanes=f,t.memoizedState=O}}function lo(t,e){if(typeof t!="function")throw Error(c(191,t));t.call(e)}function no(t,e){var l=t.callbacks;if(l!==null)for(t.callbacks=null,t=0;t<l.length;t++)lo(l[t],e)}var Ln=p(null),Xi=p(0);function ao(t,e){t=ol,H(Xi,t),H(Ln,e),ol=t|e.baseLanes}function Vs(){H(Xi,ol),H(Ln,Ln.current)}function Zs(){ol=Xi.current,D(Ln),D(Xi)}var ge=p(null),Oe=null;function zl(t){var e=t.alternate;H(Rt,Rt.current&1),H(ge,t),Oe===null&&(e===null||Ln.current!==null||e.memoizedState!==null)&&(Oe=t)}function Js(t){H(Rt,Rt.current),H(ge,t),Oe===null&&(Oe=t)}function io(t){t.tag===22?(H(Rt,Rt.current),H(ge,t),Oe===null&&(Oe=t)):Cl()}function Cl(){H(Rt,Rt.current),H(ge,ge.current)}function pe(t){D(ge),Oe===t&&(Oe=null),D(Rt)}var Rt=p(0);function Gi(t){for(var e=t;e!==null;){if(e.tag===13){var l=e.memoizedState;if(l!==null&&(l=l.dehydrated,l===null||Pc(l)||tr(l)))return e}else if(e.tag===19&&(e.memoizedProps.revealOrder==="forwards"||e.memoizedProps.revealOrder==="backwards"||e.memoizedProps.revealOrder==="unstable_legacy-backwards"||e.memoizedProps.revealOrder==="together")){if((e.flags&128)!==0)return e}else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break;for(;e.sibling===null;){if(e.return===null||e.return===t)return null;e=e.return}e.sibling.return=e.return,e=e.sibling}return null}var nl=0,J=null,ht=null,Bt=null,Qi=!1,jn=!1,rn=!1,Ki=0,Ra=0,qn=null,pg=0;function Ct(){throw Error(c(321))}function ks(t,e){if(e===null)return!1;for(var l=0;l<e.length&&l<t.length;l++)if(!me(t[l],e[l]))return!1;return!0}function Ws(t,e,l,n,a,i){return nl=i,J=e,e.memoizedState=null,e.updateQueue=null,e.lanes=0,z.H=t===null||t.memoizedState===null?Qo:fc,rn=!1,i=l(n,a),rn=!1,jn&&(i=so(e,l,n,a)),uo(t),i}function uo(t){z.H=Ha;var e=ht!==null&&ht.next!==null;if(nl=0,Bt=ht=J=null,Qi=!1,Ra=0,qn=null,e)throw Error(c(300));t===null||Lt||(t=t.dependencies,t!==null&&Hi(t)&&(Lt=!0))}function so(t,e,l,n){J=t;var a=0;do{if(jn&&(qn=null),Ra=0,jn=!1,25<=a)throw Error(c(301));if(a+=1,Bt=ht=null,t.updateQueue!=null){var i=t.updateQueue;i.lastEffect=null,i.events=null,i.stores=null,i.memoCache!=null&&(i.memoCache.index=0)}z.H=Ko,i=e(l,n)}while(jn);return i}function vg(){var t=z.H,e=t.useState()[0];return e=typeof e.then=="function"?Ua(e):e,t=t.useState()[0],(ht!==null?ht.memoizedState:null)!==t&&(J.flags|=1024),e}function $s(){var t=Ki!==0;return Ki=0,t}function Fs(t,e,l){e.updateQueue=t.updateQueue,e.flags&=-2053,t.lanes&=~l}function Is(t){if(Qi){for(t=t.memoizedState;t!==null;){var e=t.queue;e!==null&&(e.pending=null),t=t.next}Qi=!1}nl=0,Bt=ht=J=null,jn=!1,Ra=Ki=0,qn=null}function Pt(){var t={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return Bt===null?J.memoizedState=Bt=t:Bt=Bt.next=t,Bt}function Ut(){if(ht===null){var t=J.alternate;t=t!==null?t.memoizedState:null}else t=ht.next;var e=Bt===null?J.memoizedState:Bt.next;if(e!==null)Bt=e,ht=t;else{if(t===null)throw J.alternate===null?Error(c(467)):Error(c(310));ht=t,t={memoizedState:ht.memoizedState,baseState:ht.baseState,baseQueue:ht.baseQueue,queue:ht.queue,next:null},Bt===null?J.memoizedState=Bt=t:Bt=Bt.next=t}return Bt}function Vi(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function Ua(t){var e=Ra;return Ra+=1,qn===null&&(qn=[]),t=Ff(qn,t,e),e=J,(Bt===null?e.memoizedState:Bt.next)===null&&(e=e.alternate,z.H=e===null||e.memoizedState===null?Qo:fc),t}function Zi(t){if(t!==null&&typeof t=="object"){if(typeof t.then=="function")return Ua(t);if(t.$$typeof===Ht)return Zt(t)}throw Error(c(438,String(t)))}function Ps(t){var e=null,l=J.updateQueue;if(l!==null&&(e=l.memoCache),e==null){var n=J.alternate;n!==null&&(n=n.updateQueue,n!==null&&(n=n.memoCache,n!=null&&(e={data:n.data.map(function(a){return a.slice()}),index:0})))}if(e==null&&(e={data:[],index:0}),l===null&&(l=Vi(),J.updateQueue=l),l.memoCache=e,l=e.data[e.index],l===void 0)for(l=e.data[e.index]=Array(t),n=0;n<t;n++)l[n]=mn;return e.index++,l}function al(t,e){return typeof e=="function"?e(t):e}function Ji(t){var e=Ut();return tc(e,ht,t)}function tc(t,e,l){var n=t.queue;if(n===null)throw Error(c(311));n.lastRenderedReducer=l;var a=t.baseQueue,i=n.pending;if(i!==null){if(a!==null){var f=a.next;a.next=i.next,i.next=f}e.baseQueue=a=i,n.pending=null}if(i=t.baseState,a===null)t.memoizedState=i;else{e=a.next;var o=f=null,m=null,A=e,M=!1;do{var O=A.lane&-536870913;if(O!==A.lane?(tt&O)===O:(nl&O)===O){var _=A.revertLane;if(_===0)m!==null&&(m=m.next={lane:0,revertLane:0,gesture:null,action:A.action,hasEagerState:A.hasEagerState,eagerState:A.eagerState,next:null}),O===wn&&(M=!0);else if((nl&_)===_){A=A.next,_===wn&&(M=!0);continue}else O={lane:0,revertLane:A.revertLane,gesture:null,action:A.action,hasEagerState:A.hasEagerState,eagerState:A.eagerState,next:null},m===null?(o=m=O,f=i):m=m.next=O,J.lanes|=_,Rl|=_;O=A.action,rn&&l(i,O),i=A.hasEagerState?A.eagerState:l(i,O)}else _={lane:O,revertLane:A.revertLane,gesture:A.gesture,action:A.action,hasEagerState:A.hasEagerState,eagerState:A.eagerState,next:null},m===null?(o=m=_,f=i):m=m.next=_,J.lanes|=O,Rl|=O;A=A.next}while(A!==null&&A!==e);if(m===null?f=i:m.next=o,!me(i,t.memoizedState)&&(Lt=!0,M&&(l=Hn,l!==null)))throw l;t.memoizedState=i,t.baseState=f,t.baseQueue=m,n.lastRenderedState=i}return a===null&&(n.lanes=0),[t.memoizedState,n.dispatch]}function ec(t){var e=Ut(),l=e.queue;if(l===null)throw Error(c(311));l.lastRenderedReducer=t;var n=l.dispatch,a=l.pending,i=e.memoizedState;if(a!==null){l.pending=null;var f=a=a.next;do i=t(i,f.action),f=f.next;while(f!==a);me(i,e.memoizedState)||(Lt=!0),e.memoizedState=i,e.baseQueue===null&&(e.baseState=i),l.lastRenderedState=i}return[i,n]}function co(t,e,l){var n=J,a=Ut(),i=lt;if(i){if(l===void 0)throw Error(c(407));l=l()}else l=e();var f=!me((ht||a).memoizedState,l);if(f&&(a.memoizedState=l,Lt=!0),a=a.queue,ac(oo.bind(null,n,a,t),[t]),a.getSnapshot!==e||f||Bt!==null&&Bt.memoizedState.tag&1){if(n.flags|=2048,Yn(9,{destroy:void 0},fo.bind(null,n,a,l,e),null),gt===null)throw Error(c(349));i||(nl&127)!==0||ro(n,e,l)}return l}function ro(t,e,l){t.flags|=16384,t={getSnapshot:e,value:l},e=J.updateQueue,e===null?(e=Vi(),J.updateQueue=e,e.stores=[t]):(l=e.stores,l===null?e.stores=[t]:l.push(t))}function fo(t,e,l,n){e.value=l,e.getSnapshot=n,ho(e)&&mo(t)}function oo(t,e,l){return l(function(){ho(e)&&mo(t)})}function ho(t){var e=t.getSnapshot;t=t.value;try{var l=e();return!me(t,l)}catch{return!0}}function mo(t){var e=Pl(t,2);e!==null&&re(e,t,2)}function lc(t){var e=Pt();if(typeof t=="function"){var l=t;if(t=l(),rn){pl(!0);try{l()}finally{pl(!1)}}}return e.memoizedState=e.baseState=t,e.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:al,lastRenderedState:t},e}function yo(t,e,l,n){return t.baseState=l,tc(t,ht,typeof n=="function"?n:al)}function Sg(t,e,l,n,a){if($i(t))throw Error(c(485));if(t=e.action,t!==null){var i={payload:a,action:t,next:null,isTransition:!0,status:"pending",value:null,reason:null,listeners:[],then:function(f){i.listeners.push(f)}};z.T!==null?l(!0):i.isTransition=!1,n(i),l=e.pending,l===null?(i.next=e.pending=i,go(e,i)):(i.next=l.next,e.pending=l.next=i)}}function go(t,e){var l=e.action,n=e.payload,a=t.state;if(e.isTransition){var i=z.T,f={};z.T=f;try{var o=l(a,n),m=z.S;m!==null&&m(f,o),po(t,e,o)}catch(A){nc(t,e,A)}finally{i!==null&&f.types!==null&&(i.types=f.types),z.T=i}}else try{i=l(a,n),po(t,e,i)}catch(A){nc(t,e,A)}}function po(t,e,l){l!==null&&typeof l=="object"&&typeof l.then=="function"?l.then(function(n){vo(t,e,n)},function(n){return nc(t,e,n)}):vo(t,e,l)}function vo(t,e,l){e.status="fulfilled",e.value=l,So(e),t.state=l,e=t.pending,e!==null&&(l=e.next,l===e?t.pending=null:(l=l.next,e.next=l,go(t,l)))}function nc(t,e,l){var n=t.pending;if(t.pending=null,n!==null){n=n.next;do e.status="rejected",e.reason=l,So(e),e=e.next;while(e!==n)}t.action=null}function So(t){t=t.listeners;for(var e=0;e<t.length;e++)(0,t[e])()}function bo(t,e){return e}function Eo(t,e){if(lt){var l=gt.formState;if(l!==null){t:{var n=J;if(lt){if(Et){e:{for(var a=Et,i=Ce;a.nodeType!==8;){if(!i){a=null;break e}if(a=De(a.nextSibling),a===null){a=null;break e}}i=a.data,a=i==="F!"||i==="F"?a:null}if(a){Et=De(a.nextSibling),n=a.data==="F!";break t}}Tl(n)}n=!1}n&&(e=l[0])}}return l=Pt(),l.memoizedState=l.baseState=e,n={pending:null,lanes:0,dispatch:null,lastRenderedReducer:bo,lastRenderedState:e},l.queue=n,l=Yo.bind(null,J,n),n.dispatch=l,n=lc(!1),i=rc.bind(null,J,!1,n.queue),n=Pt(),a={state:e,dispatch:null,action:t,pending:null},n.queue=a,l=Sg.bind(null,J,a,i,l),a.dispatch=l,n.memoizedState=t,[e,l,!1]}function To(t){var e=Ut();return Ao(e,ht,t)}function Ao(t,e,l){if(e=tc(t,e,bo)[0],t=Ji(al)[0],typeof e=="object"&&e!==null&&typeof e.then=="function")try{var n=Ua(e)}catch(f){throw f===Nn?Li:f}else n=e;e=Ut();var a=e.queue,i=a.dispatch;return l!==e.memoizedState&&(J.flags|=2048,Yn(9,{destroy:void 0},bg.bind(null,a,l),null)),[n,i,t]}function bg(t,e){t.action=e}function _o(t){var e=Ut(),l=ht;if(l!==null)return Ao(e,l,t);Ut(),e=e.memoizedState,l=Ut();var n=l.queue.dispatch;return l.memoizedState=t,[e,n,!1]}function Yn(t,e,l,n){return t={tag:t,create:l,deps:n,inst:e,next:null},e=J.updateQueue,e===null&&(e=Vi(),J.updateQueue=e),l=e.lastEffect,l===null?e.lastEffect=t.next=t:(n=l.next,l.next=t,t.next=n,e.lastEffect=t),t}function xo(){return Ut().memoizedState}function ki(t,e,l,n){var a=Pt();J.flags|=t,a.memoizedState=Yn(1|e,{destroy:void 0},l,n===void 0?null:n)}function Wi(t,e,l,n){var a=Ut();n=n===void 0?null:n;var i=a.memoizedState.inst;ht!==null&&n!==null&&ks(n,ht.memoizedState.deps)?a.memoizedState=Yn(e,i,l,n):(J.flags|=t,a.memoizedState=Yn(1|e,i,l,n))}function Mo(t,e){ki(8390656,8,t,e)}function ac(t,e){Wi(2048,8,t,e)}function Eg(t){J.flags|=4;var e=J.updateQueue;if(e===null)e=Vi(),J.updateQueue=e,e.events=[t];else{var l=e.events;l===null?e.events=[t]:l.push(t)}}function zo(t){var e=Ut().memoizedState;return Eg({ref:e,nextImpl:t}),function(){if((ut&2)!==0)throw Error(c(440));return e.impl.apply(void 0,arguments)}}function Co(t,e){return Wi(4,2,t,e)}function Oo(t,e){return Wi(4,4,t,e)}function Do(t,e){if(typeof e=="function"){t=t();var l=e(t);return function(){typeof l=="function"?l():e(null)}}if(e!=null)return t=t(),e.current=t,function(){e.current=null}}function Ro(t,e,l){l=l!=null?l.concat([t]):null,Wi(4,4,Do.bind(null,e,t),l)}function ic(){}function Uo(t,e){var l=Ut();e=e===void 0?null:e;var n=l.memoizedState;return e!==null&&ks(e,n[1])?n[0]:(l.memoizedState=[t,e],t)}function wo(t,e){var l=Ut();e=e===void 0?null:e;var n=l.memoizedState;if(e!==null&&ks(e,n[1]))return n[0];if(n=t(),rn){pl(!0);try{t()}finally{pl(!1)}}return l.memoizedState=[n,e],n}function uc(t,e,l){return l===void 0||(nl&1073741824)!==0&&(tt&261930)===0?t.memoizedState=e:(t.memoizedState=l,t=Hh(),J.lanes|=t,Rl|=t,l)}function Ho(t,e,l,n){return me(l,e)?l:Ln.current!==null?(t=uc(t,l,n),me(t,e)||(Lt=!0),t):(nl&42)===0||(nl&1073741824)!==0&&(tt&261930)===0?(Lt=!0,t.memoizedState=l):(t=Hh(),J.lanes|=t,Rl|=t,e)}function No(t,e,l,n,a){var i=w.p;w.p=i!==0&&8>i?i:8;var f=z.T,o={};z.T=o,rc(t,!1,e,l);try{var m=a(),A=z.S;if(A!==null&&A(o,m),m!==null&&typeof m=="object"&&typeof m.then=="function"){var M=gg(m,n);wa(t,e,M,be(t))}else wa(t,e,n,be(t))}catch(O){wa(t,e,{then:function(){},status:"rejected",reason:O},be())}finally{w.p=i,f!==null&&o.types!==null&&(f.types=o.types),z.T=f}}function Tg(){}function sc(t,e,l,n){if(t.tag!==5)throw Error(c(476));var a=Bo(t).queue;No(t,a,e,G,l===null?Tg:function(){return Lo(t),l(n)})}function Bo(t){var e=t.memoizedState;if(e!==null)return e;e={memoizedState:G,baseState:G,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:al,lastRenderedState:G},next:null};var l={};return e.next={memoizedState:l,baseState:l,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:al,lastRenderedState:l},next:null},t.memoizedState=e,t=t.alternate,t!==null&&(t.memoizedState=e),e}function Lo(t){var e=Bo(t);e.next===null&&(e=t.alternate.memoizedState),wa(t,e.next.queue,{},be())}function cc(){return Zt($a)}function jo(){return Ut().memoizedState}function qo(){return Ut().memoizedState}function Ag(t){for(var e=t.return;e!==null;){switch(e.tag){case 24:case 3:var l=be();t=xl(l);var n=Ml(e,t,l);n!==null&&(re(n,e,l),Ca(n,e,l)),e={cache:Ls()},t.payload=e;return}e=e.return}}function _g(t,e,l){var n=be();l={lane:n,revertLane:0,gesture:null,action:l,hasEagerState:!1,eagerState:null,next:null},$i(t)?Xo(e,l):(l=Ms(t,e,l,n),l!==null&&(re(l,t,n),Go(l,e,n)))}function Yo(t,e,l){var n=be();wa(t,e,l,n)}function wa(t,e,l,n){var a={lane:n,revertLane:0,gesture:null,action:l,hasEagerState:!1,eagerState:null,next:null};if($i(t))Xo(e,a);else{var i=t.alternate;if(t.lanes===0&&(i===null||i.lanes===0)&&(i=e.lastRenderedReducer,i!==null))try{var f=e.lastRenderedState,o=i(f,l);if(a.hasEagerState=!0,a.eagerState=o,me(o,f))return Di(t,e,a,0),gt===null&&Oi(),!1}catch{}finally{}if(l=Ms(t,e,a,n),l!==null)return re(l,t,n),Go(l,e,n),!0}return!1}function rc(t,e,l,n){if(n={lane:2,revertLane:Xc(),gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null},$i(t)){if(e)throw Error(c(479))}else e=Ms(t,l,n,2),e!==null&&re(e,t,2)}function $i(t){var e=t.alternate;return t===J||e!==null&&e===J}function Xo(t,e){jn=Qi=!0;var l=t.pending;l===null?e.next=e:(e.next=l.next,l.next=e),t.pending=e}function Go(t,e,l){if((l&4194048)!==0){var n=e.lanes;n&=t.pendingLanes,l|=n,e.lanes=l,Vr(t,l)}}var Ha={readContext:Zt,use:Zi,useCallback:Ct,useContext:Ct,useEffect:Ct,useImperativeHandle:Ct,useLayoutEffect:Ct,useInsertionEffect:Ct,useMemo:Ct,useReducer:Ct,useRef:Ct,useState:Ct,useDebugValue:Ct,useDeferredValue:Ct,useTransition:Ct,useSyncExternalStore:Ct,useId:Ct,useHostTransitionStatus:Ct,useFormState:Ct,useActionState:Ct,useOptimistic:Ct,useMemoCache:Ct,useCacheRefresh:Ct};Ha.useEffectEvent=Ct;var Qo={readContext:Zt,use:Zi,useCallback:function(t,e){return Pt().memoizedState=[t,e===void 0?null:e],t},useContext:Zt,useEffect:Mo,useImperativeHandle:function(t,e,l){l=l!=null?l.concat([t]):null,ki(4194308,4,Do.bind(null,e,t),l)},useLayoutEffect:function(t,e){return ki(4194308,4,t,e)},useInsertionEffect:function(t,e){ki(4,2,t,e)},useMemo:function(t,e){var l=Pt();e=e===void 0?null:e;var n=t();if(rn){pl(!0);try{t()}finally{pl(!1)}}return l.memoizedState=[n,e],n},useReducer:function(t,e,l){var n=Pt();if(l!==void 0){var a=l(e);if(rn){pl(!0);try{l(e)}finally{pl(!1)}}}else a=e;return n.memoizedState=n.baseState=a,t={pending:null,lanes:0,dispatch:null,lastRenderedReducer:t,lastRenderedState:a},n.queue=t,t=t.dispatch=_g.bind(null,J,t),[n.memoizedState,t]},useRef:function(t){var e=Pt();return t={current:t},e.memoizedState=t},useState:function(t){t=lc(t);var e=t.queue,l=Yo.bind(null,J,e);return e.dispatch=l,[t.memoizedState,l]},useDebugValue:ic,useDeferredValue:function(t,e){var l=Pt();return uc(l,t,e)},useTransition:function(){var t=lc(!1);return t=No.bind(null,J,t.queue,!0,!1),Pt().memoizedState=t,[!1,t]},useSyncExternalStore:function(t,e,l){var n=J,a=Pt();if(lt){if(l===void 0)throw Error(c(407));l=l()}else{if(l=e(),gt===null)throw Error(c(349));(tt&127)!==0||ro(n,e,l)}a.memoizedState=l;var i={value:l,getSnapshot:e};return a.queue=i,Mo(oo.bind(null,n,i,t),[t]),n.flags|=2048,Yn(9,{destroy:void 0},fo.bind(null,n,i,l,e),null),l},useId:function(){var t=Pt(),e=gt.identifierPrefix;if(lt){var l=Ke,n=Qe;l=(n&~(1<<32-de(n)-1)).toString(32)+l,e="_"+e+"R_"+l,l=Ki++,0<l&&(e+="H"+l.toString(32)),e+="_"}else l=pg++,e="_"+e+"r_"+l.toString(32)+"_";return t.memoizedState=e},useHostTransitionStatus:cc,useFormState:Eo,useActionState:Eo,useOptimistic:function(t){var e=Pt();e.memoizedState=e.baseState=t;var l={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return e.queue=l,e=rc.bind(null,J,!0,l),l.dispatch=e,[t,e]},useMemoCache:Ps,useCacheRefresh:function(){return Pt().memoizedState=Ag.bind(null,J)},useEffectEvent:function(t){var e=Pt(),l={impl:t};return e.memoizedState=l,function(){if((ut&2)!==0)throw Error(c(440));return l.impl.apply(void 0,arguments)}}},fc={readContext:Zt,use:Zi,useCallback:Uo,useContext:Zt,useEffect:ac,useImperativeHandle:Ro,useInsertionEffect:Co,useLayoutEffect:Oo,useMemo:wo,useReducer:Ji,useRef:xo,useState:function(){return Ji(al)},useDebugValue:ic,useDeferredValue:function(t,e){var l=Ut();return Ho(l,ht.memoizedState,t,e)},useTransition:function(){var t=Ji(al)[0],e=Ut().memoizedState;return[typeof t=="boolean"?t:Ua(t),e]},useSyncExternalStore:co,useId:jo,useHostTransitionStatus:cc,useFormState:To,useActionState:To,useOptimistic:function(t,e){var l=Ut();return yo(l,ht,t,e)},useMemoCache:Ps,useCacheRefresh:qo};fc.useEffectEvent=zo;var Ko={readContext:Zt,use:Zi,useCallback:Uo,useContext:Zt,useEffect:ac,useImperativeHandle:Ro,useInsertionEffect:Co,useLayoutEffect:Oo,useMemo:wo,useReducer:ec,useRef:xo,useState:function(){return ec(al)},useDebugValue:ic,useDeferredValue:function(t,e){var l=Ut();return ht===null?uc(l,t,e):Ho(l,ht.memoizedState,t,e)},useTransition:function(){var t=ec(al)[0],e=Ut().memoizedState;return[typeof t=="boolean"?t:Ua(t),e]},useSyncExternalStore:co,useId:jo,useHostTransitionStatus:cc,useFormState:_o,useActionState:_o,useOptimistic:function(t,e){var l=Ut();return ht!==null?yo(l,ht,t,e):(l.baseState=t,[t,l.queue.dispatch])},useMemoCache:Ps,useCacheRefresh:qo};Ko.useEffectEvent=zo;function oc(t,e,l,n){e=t.memoizedState,l=l(n,e),l=l==null?e:U({},e,l),t.memoizedState=l,t.lanes===0&&(t.updateQueue.baseState=l)}var hc={enqueueSetState:function(t,e,l){t=t._reactInternals;var n=be(),a=xl(n);a.payload=e,l!=null&&(a.callback=l),e=Ml(t,a,n),e!==null&&(re(e,t,n),Ca(e,t,n))},enqueueReplaceState:function(t,e,l){t=t._reactInternals;var n=be(),a=xl(n);a.tag=1,a.payload=e,l!=null&&(a.callback=l),e=Ml(t,a,n),e!==null&&(re(e,t,n),Ca(e,t,n))},enqueueForceUpdate:function(t,e){t=t._reactInternals;var l=be(),n=xl(l);n.tag=2,e!=null&&(n.callback=e),e=Ml(t,n,l),e!==null&&(re(e,t,l),Ca(e,t,l))}};function Vo(t,e,l,n,a,i,f){return t=t.stateNode,typeof t.shouldComponentUpdate=="function"?t.shouldComponentUpdate(n,i,f):e.prototype&&e.prototype.isPureReactComponent?!ba(l,n)||!ba(a,i):!0}function Zo(t,e,l,n){t=e.state,typeof e.componentWillReceiveProps=="function"&&e.componentWillReceiveProps(l,n),typeof e.UNSAFE_componentWillReceiveProps=="function"&&e.UNSAFE_componentWillReceiveProps(l,n),e.state!==t&&hc.enqueueReplaceState(e,e.state,null)}function fn(t,e){var l=e;if("ref"in e){l={};for(var n in e)n!=="ref"&&(l[n]=e[n])}if(t=t.defaultProps){l===e&&(l=U({},l));for(var a in t)l[a]===void 0&&(l[a]=t[a])}return l}function Jo(t){Ci(t)}function ko(t){console.error(t)}function Wo(t){Ci(t)}function Fi(t,e){try{var l=t.onUncaughtError;l(e.value,{componentStack:e.stack})}catch(n){setTimeout(function(){throw n})}}function $o(t,e,l){try{var n=t.onCaughtError;n(l.value,{componentStack:l.stack,errorBoundary:e.tag===1?e.stateNode:null})}catch(a){setTimeout(function(){throw a})}}function dc(t,e,l){return l=xl(l),l.tag=3,l.payload={element:null},l.callback=function(){Fi(t,e)},l}function Fo(t){return t=xl(t),t.tag=3,t}function Io(t,e,l,n){var a=l.type.getDerivedStateFromError;if(typeof a=="function"){var i=n.value;t.payload=function(){return a(i)},t.callback=function(){$o(e,l,n)}}var f=l.stateNode;f!==null&&typeof f.componentDidCatch=="function"&&(t.callback=function(){$o(e,l,n),typeof a!="function"&&(Ul===null?Ul=new Set([this]):Ul.add(this));var o=n.stack;this.componentDidCatch(n.value,{componentStack:o!==null?o:""})})}function xg(t,e,l,n,a){if(l.flags|=32768,n!==null&&typeof n=="object"&&typeof n.then=="function"){if(e=l.alternate,e!==null&&Un(e,l,a,!0),l=ge.current,l!==null){switch(l.tag){case 31:case 13:return Oe===null?ru():l.alternate===null&&Ot===0&&(Ot=3),l.flags&=-257,l.flags|=65536,l.lanes=a,n===ji?l.flags|=16384:(e=l.updateQueue,e===null?l.updateQueue=new Set([n]):e.add(n),jc(t,n,a)),!1;case 22:return l.flags|=65536,n===ji?l.flags|=16384:(e=l.updateQueue,e===null?(e={transitions:null,markerInstances:null,retryQueue:new Set([n])},l.updateQueue=e):(l=e.retryQueue,l===null?e.retryQueue=new Set([n]):l.add(n)),jc(t,n,a)),!1}throw Error(c(435,l.tag))}return jc(t,n,a),ru(),!1}if(lt)return e=ge.current,e!==null?((e.flags&65536)===0&&(e.flags|=256),e.flags|=65536,e.lanes=a,n!==Us&&(t=Error(c(422),{cause:n}),Aa(xe(t,l)))):(n!==Us&&(e=Error(c(423),{cause:n}),Aa(xe(e,l))),t=t.current.alternate,t.flags|=65536,a&=-a,t.lanes|=a,n=xe(n,l),a=dc(t.stateNode,n,a),Qs(t,a),Ot!==4&&(Ot=2)),!1;var i=Error(c(520),{cause:n});if(i=xe(i,l),Ga===null?Ga=[i]:Ga.push(i),Ot!==4&&(Ot=2),e===null)return!0;n=xe(n,l),l=e;do{switch(l.tag){case 3:return l.flags|=65536,t=a&-a,l.lanes|=t,t=dc(l.stateNode,n,t),Qs(l,t),!1;case 1:if(e=l.type,i=l.stateNode,(l.flags&128)===0&&(typeof e.getDerivedStateFromError=="function"||i!==null&&typeof i.componentDidCatch=="function"&&(Ul===null||!Ul.has(i))))return l.flags|=65536,a&=-a,l.lanes|=a,a=Fo(a),Io(a,t,l,n),Qs(l,a),!1}l=l.return}while(l!==null);return!1}var mc=Error(c(461)),Lt=!1;function Jt(t,e,l,n){e.child=t===null?eo(e,null,l,n):cn(e,t.child,l,n)}function Po(t,e,l,n,a){l=l.render;var i=e.ref;if("ref"in n){var f={};for(var o in n)o!=="ref"&&(f[o]=n[o])}else f=n;return nn(e),n=Ws(t,e,l,f,i,a),o=$s(),t!==null&&!Lt?(Fs(t,e,a),il(t,e,a)):(lt&&o&&Ds(e),e.flags|=1,Jt(t,e,n,a),e.child)}function th(t,e,l,n,a){if(t===null){var i=l.type;return typeof i=="function"&&!zs(i)&&i.defaultProps===void 0&&l.compare===null?(e.tag=15,e.type=i,eh(t,e,i,n,a)):(t=Ui(l.type,null,n,e,e.mode,a),t.ref=e.ref,t.return=e,e.child=t)}if(i=t.child,!Tc(t,a)){var f=i.memoizedProps;if(l=l.compare,l=l!==null?l:ba,l(f,n)&&t.ref===e.ref)return il(t,e,a)}return e.flags|=1,t=Pe(i,n),t.ref=e.ref,t.return=e,e.child=t}function eh(t,e,l,n,a){if(t!==null){var i=t.memoizedProps;if(ba(i,n)&&t.ref===e.ref)if(Lt=!1,e.pendingProps=n=i,Tc(t,a))(t.flags&131072)!==0&&(Lt=!0);else return e.lanes=t.lanes,il(t,e,a)}return yc(t,e,l,n,a)}function lh(t,e,l,n){var a=n.children,i=t!==null?t.memoizedState:null;if(t===null&&e.stateNode===null&&(e.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),n.mode==="hidden"){if((e.flags&128)!==0){if(i=i!==null?i.baseLanes|l:l,t!==null){for(n=e.child=t.child,a=0;n!==null;)a=a|n.lanes|n.childLanes,n=n.sibling;n=a&~i}else n=0,e.child=null;return nh(t,e,i,l,n)}if((l&536870912)!==0)e.memoizedState={baseLanes:0,cachePool:null},t!==null&&Bi(e,i!==null?i.cachePool:null),i!==null?ao(e,i):Vs(),io(e);else return n=e.lanes=536870912,nh(t,e,i!==null?i.baseLanes|l:l,l,n)}else i!==null?(Bi(e,i.cachePool),ao(e,i),Cl(),e.memoizedState=null):(t!==null&&Bi(e,null),Vs(),Cl());return Jt(t,e,a,l),e.child}function Na(t,e){return t!==null&&t.tag===22||e.stateNode!==null||(e.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),e.sibling}function nh(t,e,l,n,a){var i=qs();return i=i===null?null:{parent:Nt._currentValue,pool:i},e.memoizedState={baseLanes:l,cachePool:i},t!==null&&Bi(e,null),Vs(),io(e),t!==null&&Un(t,e,n,!0),e.childLanes=a,null}function Ii(t,e){return e=tu({mode:e.mode,children:e.children},t.mode),e.ref=t.ref,t.child=e,e.return=t,e}function ah(t,e,l){return cn(e,t.child,null,l),t=Ii(e,e.pendingProps),t.flags|=2,pe(e),e.memoizedState=null,t}function Mg(t,e,l){var n=e.pendingProps,a=(e.flags&128)!==0;if(e.flags&=-129,t===null){if(lt){if(n.mode==="hidden")return t=Ii(e,n),e.lanes=536870912,Na(null,t);if(Js(e),(t=Et)?(t=gd(t,Ce),t=t!==null&&t.data==="&"?t:null,t!==null&&(e.memoizedState={dehydrated:t,treeContext:bl!==null?{id:Qe,overflow:Ke}:null,retryLane:536870912,hydrationErrors:null},l=Yf(t),l.return=e,e.child=l,Vt=e,Et=null)):t=null,t===null)throw Tl(e);return e.lanes=536870912,null}return Ii(e,n)}var i=t.memoizedState;if(i!==null){var f=i.dehydrated;if(Js(e),a)if(e.flags&256)e.flags&=-257,e=ah(t,e,l);else if(e.memoizedState!==null)e.child=t.child,e.flags|=128,e=null;else throw Error(c(558));else if(Lt||Un(t,e,l,!1),a=(l&t.childLanes)!==0,Lt||a){if(n=gt,n!==null&&(f=Zr(n,l),f!==0&&f!==i.retryLane))throw i.retryLane=f,Pl(t,f),re(n,t,f),mc;ru(),e=ah(t,e,l)}else t=i.treeContext,Et=De(f.nextSibling),Vt=e,lt=!0,El=null,Ce=!1,t!==null&&Qf(e,t),e=Ii(e,n),e.flags|=4096;return e}return t=Pe(t.child,{mode:n.mode,children:n.children}),t.ref=e.ref,e.child=t,t.return=e,t}function Pi(t,e){var l=e.ref;if(l===null)t!==null&&t.ref!==null&&(e.flags|=4194816);else{if(typeof l!="function"&&typeof l!="object")throw Error(c(284));(t===null||t.ref!==l)&&(e.flags|=4194816)}}function yc(t,e,l,n,a){return nn(e),l=Ws(t,e,l,n,void 0,a),n=$s(),t!==null&&!Lt?(Fs(t,e,a),il(t,e,a)):(lt&&n&&Ds(e),e.flags|=1,Jt(t,e,l,a),e.child)}function ih(t,e,l,n,a,i){return nn(e),e.updateQueue=null,l=so(e,n,l,a),uo(t),n=$s(),t!==null&&!Lt?(Fs(t,e,i),il(t,e,i)):(lt&&n&&Ds(e),e.flags|=1,Jt(t,e,l,i),e.child)}function uh(t,e,l,n,a){if(nn(e),e.stateNode===null){var i=Cn,f=l.contextType;typeof f=="object"&&f!==null&&(i=Zt(f)),i=new l(n,i),e.memoizedState=i.state!==null&&i.state!==void 0?i.state:null,i.updater=hc,e.stateNode=i,i._reactInternals=e,i=e.stateNode,i.props=n,i.state=e.memoizedState,i.refs={},Xs(e),f=l.contextType,i.context=typeof f=="object"&&f!==null?Zt(f):Cn,i.state=e.memoizedState,f=l.getDerivedStateFromProps,typeof f=="function"&&(oc(e,l,f,n),i.state=e.memoizedState),typeof l.getDerivedStateFromProps=="function"||typeof i.getSnapshotBeforeUpdate=="function"||typeof i.UNSAFE_componentWillMount!="function"&&typeof i.componentWillMount!="function"||(f=i.state,typeof i.componentWillMount=="function"&&i.componentWillMount(),typeof i.UNSAFE_componentWillMount=="function"&&i.UNSAFE_componentWillMount(),f!==i.state&&hc.enqueueReplaceState(i,i.state,null),Da(e,n,i,a),Oa(),i.state=e.memoizedState),typeof i.componentDidMount=="function"&&(e.flags|=4194308),n=!0}else if(t===null){i=e.stateNode;var o=e.memoizedProps,m=fn(l,o);i.props=m;var A=i.context,M=l.contextType;f=Cn,typeof M=="object"&&M!==null&&(f=Zt(M));var O=l.getDerivedStateFromProps;M=typeof O=="function"||typeof i.getSnapshotBeforeUpdate=="function",o=e.pendingProps!==o,M||typeof i.UNSAFE_componentWillReceiveProps!="function"&&typeof i.componentWillReceiveProps!="function"||(o||A!==f)&&Zo(e,i,n,f),_l=!1;var _=e.memoizedState;i.state=_,Da(e,n,i,a),Oa(),A=e.memoizedState,o||_!==A||_l?(typeof O=="function"&&(oc(e,l,O,n),A=e.memoizedState),(m=_l||Vo(e,l,m,n,_,A,f))?(M||typeof i.UNSAFE_componentWillMount!="function"&&typeof i.componentWillMount!="function"||(typeof i.componentWillMount=="function"&&i.componentWillMount(),typeof i.UNSAFE_componentWillMount=="function"&&i.UNSAFE_componentWillMount()),typeof i.componentDidMount=="function"&&(e.flags|=4194308)):(typeof i.componentDidMount=="function"&&(e.flags|=4194308),e.memoizedProps=n,e.memoizedState=A),i.props=n,i.state=A,i.context=f,n=m):(typeof i.componentDidMount=="function"&&(e.flags|=4194308),n=!1)}else{i=e.stateNode,Gs(t,e),f=e.memoizedProps,M=fn(l,f),i.props=M,O=e.pendingProps,_=i.context,A=l.contextType,m=Cn,typeof A=="object"&&A!==null&&(m=Zt(A)),o=l.getDerivedStateFromProps,(A=typeof o=="function"||typeof i.getSnapshotBeforeUpdate=="function")||typeof i.UNSAFE_componentWillReceiveProps!="function"&&typeof i.componentWillReceiveProps!="function"||(f!==O||_!==m)&&Zo(e,i,n,m),_l=!1,_=e.memoizedState,i.state=_,Da(e,n,i,a),Oa();var x=e.memoizedState;f!==O||_!==x||_l||t!==null&&t.dependencies!==null&&Hi(t.dependencies)?(typeof o=="function"&&(oc(e,l,o,n),x=e.memoizedState),(M=_l||Vo(e,l,M,n,_,x,m)||t!==null&&t.dependencies!==null&&Hi(t.dependencies))?(A||typeof i.UNSAFE_componentWillUpdate!="function"&&typeof i.componentWillUpdate!="function"||(typeof i.componentWillUpdate=="function"&&i.componentWillUpdate(n,x,m),typeof i.UNSAFE_componentWillUpdate=="function"&&i.UNSAFE_componentWillUpdate(n,x,m)),typeof i.componentDidUpdate=="function"&&(e.flags|=4),typeof i.getSnapshotBeforeUpdate=="function"&&(e.flags|=1024)):(typeof i.componentDidUpdate!="function"||f===t.memoizedProps&&_===t.memoizedState||(e.flags|=4),typeof i.getSnapshotBeforeUpdate!="function"||f===t.memoizedProps&&_===t.memoizedState||(e.flags|=1024),e.memoizedProps=n,e.memoizedState=x),i.props=n,i.state=x,i.context=m,n=M):(typeof i.componentDidUpdate!="function"||f===t.memoizedProps&&_===t.memoizedState||(e.flags|=4),typeof i.getSnapshotBeforeUpdate!="function"||f===t.memoizedProps&&_===t.memoizedState||(e.flags|=1024),n=!1)}return i=n,Pi(t,e),n=(e.flags&128)!==0,i||n?(i=e.stateNode,l=n&&typeof l.getDerivedStateFromError!="function"?null:i.render(),e.flags|=1,t!==null&&n?(e.child=cn(e,t.child,null,a),e.child=cn(e,null,l,a)):Jt(t,e,l,a),e.memoizedState=i.state,t=e.child):t=il(t,e,a),t}function sh(t,e,l,n){return en(),e.flags|=256,Jt(t,e,l,n),e.child}var gc={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function pc(t){return{baseLanes:t,cachePool:Wf()}}function vc(t,e,l){return t=t!==null?t.childLanes&~l:0,e&&(t|=Se),t}function ch(t,e,l){var n=e.pendingProps,a=!1,i=(e.flags&128)!==0,f;if((f=i)||(f=t!==null&&t.memoizedState===null?!1:(Rt.current&2)!==0),f&&(a=!0,e.flags&=-129),f=(e.flags&32)!==0,e.flags&=-33,t===null){if(lt){if(a?zl(e):Cl(),(t=Et)?(t=gd(t,Ce),t=t!==null&&t.data!=="&"?t:null,t!==null&&(e.memoizedState={dehydrated:t,treeContext:bl!==null?{id:Qe,overflow:Ke}:null,retryLane:536870912,hydrationErrors:null},l=Yf(t),l.return=e,e.child=l,Vt=e,Et=null)):t=null,t===null)throw Tl(e);return tr(t)?e.lanes=32:e.lanes=536870912,null}var o=n.children;return n=n.fallback,a?(Cl(),a=e.mode,o=tu({mode:"hidden",children:o},a),n=tn(n,a,l,null),o.return=e,n.return=e,o.sibling=n,e.child=o,n=e.child,n.memoizedState=pc(l),n.childLanes=vc(t,f,l),e.memoizedState=gc,Na(null,n)):(zl(e),Sc(e,o))}var m=t.memoizedState;if(m!==null&&(o=m.dehydrated,o!==null)){if(i)e.flags&256?(zl(e),e.flags&=-257,e=bc(t,e,l)):e.memoizedState!==null?(Cl(),e.child=t.child,e.flags|=128,e=null):(Cl(),o=n.fallback,a=e.mode,n=tu({mode:"visible",children:n.children},a),o=tn(o,a,l,null),o.flags|=2,n.return=e,o.return=e,n.sibling=o,e.child=n,cn(e,t.child,null,l),n=e.child,n.memoizedState=pc(l),n.childLanes=vc(t,f,l),e.memoizedState=gc,e=Na(null,n));else if(zl(e),tr(o)){if(f=o.nextSibling&&o.nextSibling.dataset,f)var A=f.dgst;f=A,n=Error(c(419)),n.stack="",n.digest=f,Aa({value:n,source:null,stack:null}),e=bc(t,e,l)}else if(Lt||Un(t,e,l,!1),f=(l&t.childLanes)!==0,Lt||f){if(f=gt,f!==null&&(n=Zr(f,l),n!==0&&n!==m.retryLane))throw m.retryLane=n,Pl(t,n),re(f,t,n),mc;Pc(o)||ru(),e=bc(t,e,l)}else Pc(o)?(e.flags|=192,e.child=t.child,e=null):(t=m.treeContext,Et=De(o.nextSibling),Vt=e,lt=!0,El=null,Ce=!1,t!==null&&Qf(e,t),e=Sc(e,n.children),e.flags|=4096);return e}return a?(Cl(),o=n.fallback,a=e.mode,m=t.child,A=m.sibling,n=Pe(m,{mode:"hidden",children:n.children}),n.subtreeFlags=m.subtreeFlags&65011712,A!==null?o=Pe(A,o):(o=tn(o,a,l,null),o.flags|=2),o.return=e,n.return=e,n.sibling=o,e.child=n,Na(null,n),n=e.child,o=t.child.memoizedState,o===null?o=pc(l):(a=o.cachePool,a!==null?(m=Nt._currentValue,a=a.parent!==m?{parent:m,pool:m}:a):a=Wf(),o={baseLanes:o.baseLanes|l,cachePool:a}),n.memoizedState=o,n.childLanes=vc(t,f,l),e.memoizedState=gc,Na(t.child,n)):(zl(e),l=t.child,t=l.sibling,l=Pe(l,{mode:"visible",children:n.children}),l.return=e,l.sibling=null,t!==null&&(f=e.deletions,f===null?(e.deletions=[t],e.flags|=16):f.push(t)),e.child=l,e.memoizedState=null,l)}function Sc(t,e){return e=tu({mode:"visible",children:e},t.mode),e.return=t,t.child=e}function tu(t,e){return t=ye(22,t,null,e),t.lanes=0,t}function bc(t,e,l){return cn(e,t.child,null,l),t=Sc(e,e.pendingProps.children),t.flags|=2,e.memoizedState=null,t}function rh(t,e,l){t.lanes|=e;var n=t.alternate;n!==null&&(n.lanes|=e),Ns(t.return,e,l)}function Ec(t,e,l,n,a,i){var f=t.memoizedState;f===null?t.memoizedState={isBackwards:e,rendering:null,renderingStartTime:0,last:n,tail:l,tailMode:a,treeForkCount:i}:(f.isBackwards=e,f.rendering=null,f.renderingStartTime=0,f.last=n,f.tail=l,f.tailMode=a,f.treeForkCount=i)}function fh(t,e,l){var n=e.pendingProps,a=n.revealOrder,i=n.tail;n=n.children;var f=Rt.current,o=(f&2)!==0;if(o?(f=f&1|2,e.flags|=128):f&=1,H(Rt,f),Jt(t,e,n,l),n=lt?Ta:0,!o&&t!==null&&(t.flags&128)!==0)t:for(t=e.child;t!==null;){if(t.tag===13)t.memoizedState!==null&&rh(t,l,e);else if(t.tag===19)rh(t,l,e);else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break t;for(;t.sibling===null;){if(t.return===null||t.return===e)break t;t=t.return}t.sibling.return=t.return,t=t.sibling}switch(a){case"forwards":for(l=e.child,a=null;l!==null;)t=l.alternate,t!==null&&Gi(t)===null&&(a=l),l=l.sibling;l=a,l===null?(a=e.child,e.child=null):(a=l.sibling,l.sibling=null),Ec(e,!1,a,l,i,n);break;case"backwards":case"unstable_legacy-backwards":for(l=null,a=e.child,e.child=null;a!==null;){if(t=a.alternate,t!==null&&Gi(t)===null){e.child=a;break}t=a.sibling,a.sibling=l,l=a,a=t}Ec(e,!0,l,null,i,n);break;case"together":Ec(e,!1,null,null,void 0,n);break;default:e.memoizedState=null}return e.child}function il(t,e,l){if(t!==null&&(e.dependencies=t.dependencies),Rl|=e.lanes,(l&e.childLanes)===0)if(t!==null){if(Un(t,e,l,!1),(l&e.childLanes)===0)return null}else return null;if(t!==null&&e.child!==t.child)throw Error(c(153));if(e.child!==null){for(t=e.child,l=Pe(t,t.pendingProps),e.child=l,l.return=e;t.sibling!==null;)t=t.sibling,l=l.sibling=Pe(t,t.pendingProps),l.return=e;l.sibling=null}return e.child}function Tc(t,e){return(t.lanes&e)!==0?!0:(t=t.dependencies,!!(t!==null&&Hi(t)))}function zg(t,e,l){switch(e.tag){case 3:It(e,e.stateNode.containerInfo),Al(e,Nt,t.memoizedState.cache),en();break;case 27:case 5:sa(e);break;case 4:It(e,e.stateNode.containerInfo);break;case 10:Al(e,e.type,e.memoizedProps.value);break;case 31:if(e.memoizedState!==null)return e.flags|=128,Js(e),null;break;case 13:var n=e.memoizedState;if(n!==null)return n.dehydrated!==null?(zl(e),e.flags|=128,null):(l&e.child.childLanes)!==0?ch(t,e,l):(zl(e),t=il(t,e,l),t!==null?t.sibling:null);zl(e);break;case 19:var a=(t.flags&128)!==0;if(n=(l&e.childLanes)!==0,n||(Un(t,e,l,!1),n=(l&e.childLanes)!==0),a){if(n)return fh(t,e,l);e.flags|=128}if(a=e.memoizedState,a!==null&&(a.rendering=null,a.tail=null,a.lastEffect=null),H(Rt,Rt.current),n)break;return null;case 22:return e.lanes=0,lh(t,e,l,e.pendingProps);case 24:Al(e,Nt,t.memoizedState.cache)}return il(t,e,l)}function oh(t,e,l){if(t!==null)if(t.memoizedProps!==e.pendingProps)Lt=!0;else{if(!Tc(t,l)&&(e.flags&128)===0)return Lt=!1,zg(t,e,l);Lt=(t.flags&131072)!==0}else Lt=!1,lt&&(e.flags&1048576)!==0&&Gf(e,Ta,e.index);switch(e.lanes=0,e.tag){case 16:t:{var n=e.pendingProps;if(t=un(e.elementType),e.type=t,typeof t=="function")zs(t)?(n=fn(t,n),e.tag=1,e=uh(null,e,t,n,l)):(e.tag=0,e=yc(null,e,t,n,l));else{if(t!=null){var a=t.$$typeof;if(a===te){e.tag=11,e=Po(null,e,t,n,l);break t}else if(a===$){e.tag=14,e=th(null,e,t,n,l);break t}}throw e=We(t)||t,Error(c(306,e,""))}}return e;case 0:return yc(t,e,e.type,e.pendingProps,l);case 1:return n=e.type,a=fn(n,e.pendingProps),uh(t,e,n,a,l);case 3:t:{if(It(e,e.stateNode.containerInfo),t===null)throw Error(c(387));n=e.pendingProps;var i=e.memoizedState;a=i.element,Gs(t,e),Da(e,n,null,l);var f=e.memoizedState;if(n=f.cache,Al(e,Nt,n),n!==i.cache&&Bs(e,[Nt],l,!0),Oa(),n=f.element,i.isDehydrated)if(i={element:n,isDehydrated:!1,cache:f.cache},e.updateQueue.baseState=i,e.memoizedState=i,e.flags&256){e=sh(t,e,n,l);break t}else if(n!==a){a=xe(Error(c(424)),e),Aa(a),e=sh(t,e,n,l);break t}else{switch(t=e.stateNode.containerInfo,t.nodeType){case 9:t=t.body;break;default:t=t.nodeName==="HTML"?t.ownerDocument.body:t}for(Et=De(t.firstChild),Vt=e,lt=!0,El=null,Ce=!0,l=eo(e,null,n,l),e.child=l;l;)l.flags=l.flags&-3|4096,l=l.sibling}else{if(en(),n===a){e=il(t,e,l);break t}Jt(t,e,n,l)}e=e.child}return e;case 26:return Pi(t,e),t===null?(l=Td(e.type,null,e.pendingProps,null))?e.memoizedState=l:lt||(l=e.type,t=e.pendingProps,n=gu(F.current).createElement(l),n[Kt]=e,n[ne]=t,kt(n,l,t),Xt(n),e.stateNode=n):e.memoizedState=Td(e.type,t.memoizedProps,e.pendingProps,t.memoizedState),null;case 27:return sa(e),t===null&<&&(n=e.stateNode=Sd(e.type,e.pendingProps,F.current),Vt=e,Ce=!0,a=Et,Bl(e.type)?(er=a,Et=De(n.firstChild)):Et=a),Jt(t,e,e.pendingProps.children,l),Pi(t,e),t===null&&(e.flags|=4194304),e.child;case 5:return t===null&<&&((a=n=Et)&&(n=np(n,e.type,e.pendingProps,Ce),n!==null?(e.stateNode=n,Vt=e,Et=De(n.firstChild),Ce=!1,a=!0):a=!1),a||Tl(e)),sa(e),a=e.type,i=e.pendingProps,f=t!==null?t.memoizedProps:null,n=i.children,$c(a,i)?n=null:f!==null&&$c(a,f)&&(e.flags|=32),e.memoizedState!==null&&(a=Ws(t,e,vg,null,null,l),$a._currentValue=a),Pi(t,e),Jt(t,e,n,l),e.child;case 6:return t===null&<&&((t=l=Et)&&(l=ap(l,e.pendingProps,Ce),l!==null?(e.stateNode=l,Vt=e,Et=null,t=!0):t=!1),t||Tl(e)),null;case 13:return ch(t,e,l);case 4:return It(e,e.stateNode.containerInfo),n=e.pendingProps,t===null?e.child=cn(e,null,n,l):Jt(t,e,n,l),e.child;case 11:return Po(t,e,e.type,e.pendingProps,l);case 7:return Jt(t,e,e.pendingProps,l),e.child;case 8:return Jt(t,e,e.pendingProps.children,l),e.child;case 12:return Jt(t,e,e.pendingProps.children,l),e.child;case 10:return n=e.pendingProps,Al(e,e.type,n.value),Jt(t,e,n.children,l),e.child;case 9:return a=e.type._context,n=e.pendingProps.children,nn(e),a=Zt(a),n=n(a),e.flags|=1,Jt(t,e,n,l),e.child;case 14:return th(t,e,e.type,e.pendingProps,l);case 15:return eh(t,e,e.type,e.pendingProps,l);case 19:return fh(t,e,l);case 31:return Mg(t,e,l);case 22:return lh(t,e,l,e.pendingProps);case 24:return nn(e),n=Zt(Nt),t===null?(a=qs(),a===null&&(a=gt,i=Ls(),a.pooledCache=i,i.refCount++,i!==null&&(a.pooledCacheLanes|=l),a=i),e.memoizedState={parent:n,cache:a},Xs(e),Al(e,Nt,a)):((t.lanes&l)!==0&&(Gs(t,e),Da(e,null,null,l),Oa()),a=t.memoizedState,i=e.memoizedState,a.parent!==n?(a={parent:n,cache:n},e.memoizedState=a,e.lanes===0&&(e.memoizedState=e.updateQueue.baseState=a),Al(e,Nt,n)):(n=i.cache,Al(e,Nt,n),n!==a.cache&&Bs(e,[Nt],l,!0))),Jt(t,e,e.pendingProps.children,l),e.child;case 29:throw e.pendingProps}throw Error(c(156,e.tag))}function ul(t){t.flags|=4}function Ac(t,e,l,n,a){if((e=(t.mode&32)!==0)&&(e=!1),e){if(t.flags|=16777216,(a&335544128)===a)if(t.stateNode.complete)t.flags|=8192;else if(jh())t.flags|=8192;else throw sn=ji,Ys}else t.flags&=-16777217}function hh(t,e){if(e.type!=="stylesheet"||(e.state.loading&4)!==0)t.flags&=-16777217;else if(t.flags|=16777216,!zd(e))if(jh())t.flags|=8192;else throw sn=ji,Ys}function eu(t,e){e!==null&&(t.flags|=4),t.flags&16384&&(e=t.tag!==22?Qr():536870912,t.lanes|=e,Kn|=e)}function Ba(t,e){if(!lt)switch(t.tailMode){case"hidden":e=t.tail;for(var l=null;e!==null;)e.alternate!==null&&(l=e),e=e.sibling;l===null?t.tail=null:l.sibling=null;break;case"collapsed":l=t.tail;for(var n=null;l!==null;)l.alternate!==null&&(n=l),l=l.sibling;n===null?e||t.tail===null?t.tail=null:t.tail.sibling=null:n.sibling=null}}function Tt(t){var e=t.alternate!==null&&t.alternate.child===t.child,l=0,n=0;if(e)for(var a=t.child;a!==null;)l|=a.lanes|a.childLanes,n|=a.subtreeFlags&65011712,n|=a.flags&65011712,a.return=t,a=a.sibling;else for(a=t.child;a!==null;)l|=a.lanes|a.childLanes,n|=a.subtreeFlags,n|=a.flags,a.return=t,a=a.sibling;return t.subtreeFlags|=n,t.childLanes=l,e}function Cg(t,e,l){var n=e.pendingProps;switch(Rs(e),e.tag){case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return Tt(e),null;case 1:return Tt(e),null;case 3:return l=e.stateNode,n=null,t!==null&&(n=t.memoizedState.cache),e.memoizedState.cache!==n&&(e.flags|=2048),ll(Nt),Dt(),l.pendingContext&&(l.context=l.pendingContext,l.pendingContext=null),(t===null||t.child===null)&&(Rn(e)?ul(e):t===null||t.memoizedState.isDehydrated&&(e.flags&256)===0||(e.flags|=1024,ws())),Tt(e),null;case 26:var a=e.type,i=e.memoizedState;return t===null?(ul(e),i!==null?(Tt(e),hh(e,i)):(Tt(e),Ac(e,a,null,n,l))):i?i!==t.memoizedState?(ul(e),Tt(e),hh(e,i)):(Tt(e),e.flags&=-16777217):(t=t.memoizedProps,t!==n&&ul(e),Tt(e),Ac(e,a,t,n,l)),null;case 27:if(hi(e),l=F.current,a=e.type,t!==null&&e.stateNode!=null)t.memoizedProps!==n&&ul(e);else{if(!n){if(e.stateNode===null)throw Error(c(166));return Tt(e),null}t=L.current,Rn(e)?Kf(e):(t=Sd(a,n,l),e.stateNode=t,ul(e))}return Tt(e),null;case 5:if(hi(e),a=e.type,t!==null&&e.stateNode!=null)t.memoizedProps!==n&&ul(e);else{if(!n){if(e.stateNode===null)throw Error(c(166));return Tt(e),null}if(i=L.current,Rn(e))Kf(e);else{var f=gu(F.current);switch(i){case 1:i=f.createElementNS("http://www.w3.org/2000/svg",a);break;case 2:i=f.createElementNS("http://www.w3.org/1998/Math/MathML",a);break;default:switch(a){case"svg":i=f.createElementNS("http://www.w3.org/2000/svg",a);break;case"math":i=f.createElementNS("http://www.w3.org/1998/Math/MathML",a);break;case"script":i=f.createElement("div"),i.innerHTML="<script><\/script>",i=i.removeChild(i.firstChild);break;case"select":i=typeof n.is=="string"?f.createElement("select",{is:n.is}):f.createElement("select"),n.multiple?i.multiple=!0:n.size&&(i.size=n.size);break;default:i=typeof n.is=="string"?f.createElement(a,{is:n.is}):f.createElement(a)}}i[Kt]=e,i[ne]=n;t:for(f=e.child;f!==null;){if(f.tag===5||f.tag===6)i.appendChild(f.stateNode);else if(f.tag!==4&&f.tag!==27&&f.child!==null){f.child.return=f,f=f.child;continue}if(f===e)break t;for(;f.sibling===null;){if(f.return===null||f.return===e)break t;f=f.return}f.sibling.return=f.return,f=f.sibling}e.stateNode=i;t:switch(kt(i,a,n),a){case"button":case"input":case"select":case"textarea":n=!!n.autoFocus;break t;case"img":n=!0;break t;default:n=!1}n&&ul(e)}}return Tt(e),Ac(e,e.type,t===null?null:t.memoizedProps,e.pendingProps,l),null;case 6:if(t&&e.stateNode!=null)t.memoizedProps!==n&&ul(e);else{if(typeof n!="string"&&e.stateNode===null)throw Error(c(166));if(t=F.current,Rn(e)){if(t=e.stateNode,l=e.memoizedProps,n=null,a=Vt,a!==null)switch(a.tag){case 27:case 5:n=a.memoizedProps}t[Kt]=e,t=!!(t.nodeValue===l||n!==null&&n.suppressHydrationWarning===!0||cd(t.nodeValue,l)),t||Tl(e,!0)}else t=gu(t).createTextNode(n),t[Kt]=e,e.stateNode=t}return Tt(e),null;case 31:if(l=e.memoizedState,t===null||t.memoizedState!==null){if(n=Rn(e),l!==null){if(t===null){if(!n)throw Error(c(318));if(t=e.memoizedState,t=t!==null?t.dehydrated:null,!t)throw Error(c(557));t[Kt]=e}else en(),(e.flags&128)===0&&(e.memoizedState=null),e.flags|=4;Tt(e),t=!1}else l=ws(),t!==null&&t.memoizedState!==null&&(t.memoizedState.hydrationErrors=l),t=!0;if(!t)return e.flags&256?(pe(e),e):(pe(e),null);if((e.flags&128)!==0)throw Error(c(558))}return Tt(e),null;case 13:if(n=e.memoizedState,t===null||t.memoizedState!==null&&t.memoizedState.dehydrated!==null){if(a=Rn(e),n!==null&&n.dehydrated!==null){if(t===null){if(!a)throw Error(c(318));if(a=e.memoizedState,a=a!==null?a.dehydrated:null,!a)throw Error(c(317));a[Kt]=e}else en(),(e.flags&128)===0&&(e.memoizedState=null),e.flags|=4;Tt(e),a=!1}else a=ws(),t!==null&&t.memoizedState!==null&&(t.memoizedState.hydrationErrors=a),a=!0;if(!a)return e.flags&256?(pe(e),e):(pe(e),null)}return pe(e),(e.flags&128)!==0?(e.lanes=l,e):(l=n!==null,t=t!==null&&t.memoizedState!==null,l&&(n=e.child,a=null,n.alternate!==null&&n.alternate.memoizedState!==null&&n.alternate.memoizedState.cachePool!==null&&(a=n.alternate.memoizedState.cachePool.pool),i=null,n.memoizedState!==null&&n.memoizedState.cachePool!==null&&(i=n.memoizedState.cachePool.pool),i!==a&&(n.flags|=2048)),l!==t&&l&&(e.child.flags|=8192),eu(e,e.updateQueue),Tt(e),null);case 4:return Dt(),t===null&&Vc(e.stateNode.containerInfo),Tt(e),null;case 10:return ll(e.type),Tt(e),null;case 19:if(D(Rt),n=e.memoizedState,n===null)return Tt(e),null;if(a=(e.flags&128)!==0,i=n.rendering,i===null)if(a)Ba(n,!1);else{if(Ot!==0||t!==null&&(t.flags&128)!==0)for(t=e.child;t!==null;){if(i=Gi(t),i!==null){for(e.flags|=128,Ba(n,!1),t=i.updateQueue,e.updateQueue=t,eu(e,t),e.subtreeFlags=0,t=l,l=e.child;l!==null;)qf(l,t),l=l.sibling;return H(Rt,Rt.current&1|2),lt&&tl(e,n.treeForkCount),e.child}t=t.sibling}n.tail!==null&&oe()>uu&&(e.flags|=128,a=!0,Ba(n,!1),e.lanes=4194304)}else{if(!a)if(t=Gi(i),t!==null){if(e.flags|=128,a=!0,t=t.updateQueue,e.updateQueue=t,eu(e,t),Ba(n,!0),n.tail===null&&n.tailMode==="hidden"&&!i.alternate&&!lt)return Tt(e),null}else 2*oe()-n.renderingStartTime>uu&&l!==536870912&&(e.flags|=128,a=!0,Ba(n,!1),e.lanes=4194304);n.isBackwards?(i.sibling=e.child,e.child=i):(t=n.last,t!==null?t.sibling=i:e.child=i,n.last=i)}return n.tail!==null?(t=n.tail,n.rendering=t,n.tail=t.sibling,n.renderingStartTime=oe(),t.sibling=null,l=Rt.current,H(Rt,a?l&1|2:l&1),lt&&tl(e,n.treeForkCount),t):(Tt(e),null);case 22:case 23:return pe(e),Zs(),n=e.memoizedState!==null,t!==null?t.memoizedState!==null!==n&&(e.flags|=8192):n&&(e.flags|=8192),n?(l&536870912)!==0&&(e.flags&128)===0&&(Tt(e),e.subtreeFlags&6&&(e.flags|=8192)):Tt(e),l=e.updateQueue,l!==null&&eu(e,l.retryQueue),l=null,t!==null&&t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(l=t.memoizedState.cachePool.pool),n=null,e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(n=e.memoizedState.cachePool.pool),n!==l&&(e.flags|=2048),t!==null&&D(an),null;case 24:return l=null,t!==null&&(l=t.memoizedState.cache),e.memoizedState.cache!==l&&(e.flags|=2048),ll(Nt),Tt(e),null;case 25:return null;case 30:return null}throw Error(c(156,e.tag))}function Og(t,e){switch(Rs(e),e.tag){case 1:return t=e.flags,t&65536?(e.flags=t&-65537|128,e):null;case 3:return ll(Nt),Dt(),t=e.flags,(t&65536)!==0&&(t&128)===0?(e.flags=t&-65537|128,e):null;case 26:case 27:case 5:return hi(e),null;case 31:if(e.memoizedState!==null){if(pe(e),e.alternate===null)throw Error(c(340));en()}return t=e.flags,t&65536?(e.flags=t&-65537|128,e):null;case 13:if(pe(e),t=e.memoizedState,t!==null&&t.dehydrated!==null){if(e.alternate===null)throw Error(c(340));en()}return t=e.flags,t&65536?(e.flags=t&-65537|128,e):null;case 19:return D(Rt),null;case 4:return Dt(),null;case 10:return ll(e.type),null;case 22:case 23:return pe(e),Zs(),t!==null&&D(an),t=e.flags,t&65536?(e.flags=t&-65537|128,e):null;case 24:return ll(Nt),null;case 25:return null;default:return null}}function dh(t,e){switch(Rs(e),e.tag){case 3:ll(Nt),Dt();break;case 26:case 27:case 5:hi(e);break;case 4:Dt();break;case 31:e.memoizedState!==null&&pe(e);break;case 13:pe(e);break;case 19:D(Rt);break;case 10:ll(e.type);break;case 22:case 23:pe(e),Zs(),t!==null&&D(an);break;case 24:ll(Nt)}}function La(t,e){try{var l=e.updateQueue,n=l!==null?l.lastEffect:null;if(n!==null){var a=n.next;l=a;do{if((l.tag&t)===t){n=void 0;var i=l.create,f=l.inst;n=i(),f.destroy=n}l=l.next}while(l!==a)}}catch(o){ft(e,e.return,o)}}function Ol(t,e,l){try{var n=e.updateQueue,a=n!==null?n.lastEffect:null;if(a!==null){var i=a.next;n=i;do{if((n.tag&t)===t){var f=n.inst,o=f.destroy;if(o!==void 0){f.destroy=void 0,a=e;var m=l,A=o;try{A()}catch(M){ft(a,m,M)}}}n=n.next}while(n!==i)}}catch(M){ft(e,e.return,M)}}function mh(t){var e=t.updateQueue;if(e!==null){var l=t.stateNode;try{no(e,l)}catch(n){ft(t,t.return,n)}}}function yh(t,e,l){l.props=fn(t.type,t.memoizedProps),l.state=t.memoizedState;try{l.componentWillUnmount()}catch(n){ft(t,e,n)}}function ja(t,e){try{var l=t.ref;if(l!==null){switch(t.tag){case 26:case 27:case 5:var n=t.stateNode;break;case 30:n=t.stateNode;break;default:n=t.stateNode}typeof l=="function"?t.refCleanup=l(n):l.current=n}}catch(a){ft(t,e,a)}}function Ve(t,e){var l=t.ref,n=t.refCleanup;if(l!==null)if(typeof n=="function")try{n()}catch(a){ft(t,e,a)}finally{t.refCleanup=null,t=t.alternate,t!=null&&(t.refCleanup=null)}else if(typeof l=="function")try{l(null)}catch(a){ft(t,e,a)}else l.current=null}function gh(t){var e=t.type,l=t.memoizedProps,n=t.stateNode;try{t:switch(e){case"button":case"input":case"select":case"textarea":l.autoFocus&&n.focus();break t;case"img":l.src?n.src=l.src:l.srcSet&&(n.srcset=l.srcSet)}}catch(a){ft(t,t.return,a)}}function _c(t,e,l){try{var n=t.stateNode;Fg(n,t.type,l,e),n[ne]=e}catch(a){ft(t,t.return,a)}}function ph(t){return t.tag===5||t.tag===3||t.tag===26||t.tag===27&&Bl(t.type)||t.tag===4}function xc(t){t:for(;;){for(;t.sibling===null;){if(t.return===null||ph(t.return))return null;t=t.return}for(t.sibling.return=t.return,t=t.sibling;t.tag!==5&&t.tag!==6&&t.tag!==18;){if(t.tag===27&&Bl(t.type)||t.flags&2||t.child===null||t.tag===4)continue t;t.child.return=t,t=t.child}if(!(t.flags&2))return t.stateNode}}function Mc(t,e,l){var n=t.tag;if(n===5||n===6)t=t.stateNode,e?(l.nodeType===9?l.body:l.nodeName==="HTML"?l.ownerDocument.body:l).insertBefore(t,e):(e=l.nodeType===9?l.body:l.nodeName==="HTML"?l.ownerDocument.body:l,e.appendChild(t),l=l._reactRootContainer,l!=null||e.onclick!==null||(e.onclick=Fe));else if(n!==4&&(n===27&&Bl(t.type)&&(l=t.stateNode,e=null),t=t.child,t!==null))for(Mc(t,e,l),t=t.sibling;t!==null;)Mc(t,e,l),t=t.sibling}function lu(t,e,l){var n=t.tag;if(n===5||n===6)t=t.stateNode,e?l.insertBefore(t,e):l.appendChild(t);else if(n!==4&&(n===27&&Bl(t.type)&&(l=t.stateNode),t=t.child,t!==null))for(lu(t,e,l),t=t.sibling;t!==null;)lu(t,e,l),t=t.sibling}function vh(t){var e=t.stateNode,l=t.memoizedProps;try{for(var n=t.type,a=e.attributes;a.length;)e.removeAttributeNode(a[0]);kt(e,n,l),e[Kt]=t,e[ne]=l}catch(i){ft(t,t.return,i)}}var sl=!1,jt=!1,zc=!1,Sh=typeof WeakSet=="function"?WeakSet:Set,Gt=null;function Dg(t,e){if(t=t.containerInfo,kc=Au,t=Df(t),bs(t)){if("selectionStart"in t)var l={start:t.selectionStart,end:t.selectionEnd};else t:{l=(l=t.ownerDocument)&&l.defaultView||window;var n=l.getSelection&&l.getSelection();if(n&&n.rangeCount!==0){l=n.anchorNode;var a=n.anchorOffset,i=n.focusNode;n=n.focusOffset;try{l.nodeType,i.nodeType}catch{l=null;break t}var f=0,o=-1,m=-1,A=0,M=0,O=t,_=null;e:for(;;){for(var x;O!==l||a!==0&&O.nodeType!==3||(o=f+a),O!==i||n!==0&&O.nodeType!==3||(m=f+n),O.nodeType===3&&(f+=O.nodeValue.length),(x=O.firstChild)!==null;)_=O,O=x;for(;;){if(O===t)break e;if(_===l&&++A===a&&(o=f),_===i&&++M===n&&(m=f),(x=O.nextSibling)!==null)break;O=_,_=O.parentNode}O=x}l=o===-1||m===-1?null:{start:o,end:m}}else l=null}l=l||{start:0,end:0}}else l=null;for(Wc={focusedElem:t,selectionRange:l},Au=!1,Gt=e;Gt!==null;)if(e=Gt,t=e.child,(e.subtreeFlags&1028)!==0&&t!==null)t.return=e,Gt=t;else for(;Gt!==null;){switch(e=Gt,i=e.alternate,t=e.flags,e.tag){case 0:if((t&4)!==0&&(t=e.updateQueue,t=t!==null?t.events:null,t!==null))for(l=0;l<t.length;l++)a=t[l],a.ref.impl=a.nextImpl;break;case 11:case 15:break;case 1:if((t&1024)!==0&&i!==null){t=void 0,l=e,a=i.memoizedProps,i=i.memoizedState,n=l.stateNode;try{var B=fn(l.type,a);t=n.getSnapshotBeforeUpdate(B,i),n.__reactInternalSnapshotBeforeUpdate=t}catch(Y){ft(l,l.return,Y)}}break;case 3:if((t&1024)!==0){if(t=e.stateNode.containerInfo,l=t.nodeType,l===9)Ic(t);else if(l===1)switch(t.nodeName){case"HEAD":case"HTML":case"BODY":Ic(t);break;default:t.textContent=""}}break;case 5:case 26:case 27:case 6:case 4:case 17:break;default:if((t&1024)!==0)throw Error(c(163))}if(t=e.sibling,t!==null){t.return=e.return,Gt=t;break}Gt=e.return}}function bh(t,e,l){var n=l.flags;switch(l.tag){case 0:case 11:case 15:rl(t,l),n&4&&La(5,l);break;case 1:if(rl(t,l),n&4)if(t=l.stateNode,e===null)try{t.componentDidMount()}catch(f){ft(l,l.return,f)}else{var a=fn(l.type,e.memoizedProps);e=e.memoizedState;try{t.componentDidUpdate(a,e,t.__reactInternalSnapshotBeforeUpdate)}catch(f){ft(l,l.return,f)}}n&64&&mh(l),n&512&&ja(l,l.return);break;case 3:if(rl(t,l),n&64&&(t=l.updateQueue,t!==null)){if(e=null,l.child!==null)switch(l.child.tag){case 27:case 5:e=l.child.stateNode;break;case 1:e=l.child.stateNode}try{no(t,e)}catch(f){ft(l,l.return,f)}}break;case 27:e===null&&n&4&&vh(l);case 26:case 5:rl(t,l),e===null&&n&4&&gh(l),n&512&&ja(l,l.return);break;case 12:rl(t,l);break;case 31:rl(t,l),n&4&&Ah(t,l);break;case 13:rl(t,l),n&4&&_h(t,l),n&64&&(t=l.memoizedState,t!==null&&(t=t.dehydrated,t!==null&&(l=qg.bind(null,l),ip(t,l))));break;case 22:if(n=l.memoizedState!==null||sl,!n){e=e!==null&&e.memoizedState!==null||jt,a=sl;var i=jt;sl=n,(jt=e)&&!i?fl(t,l,(l.subtreeFlags&8772)!==0):rl(t,l),sl=a,jt=i}break;case 30:break;default:rl(t,l)}}function Eh(t){var e=t.alternate;e!==null&&(t.alternate=null,Eh(e)),t.child=null,t.deletions=null,t.sibling=null,t.tag===5&&(e=t.stateNode,e!==null&&ns(e)),t.stateNode=null,t.return=null,t.dependencies=null,t.memoizedProps=null,t.memoizedState=null,t.pendingProps=null,t.stateNode=null,t.updateQueue=null}var _t=null,ie=!1;function cl(t,e,l){for(l=l.child;l!==null;)Th(t,e,l),l=l.sibling}function Th(t,e,l){if(he&&typeof he.onCommitFiberUnmount=="function")try{he.onCommitFiberUnmount(ca,l)}catch{}switch(l.tag){case 26:jt||Ve(l,e),cl(t,e,l),l.memoizedState?l.memoizedState.count--:l.stateNode&&(l=l.stateNode,l.parentNode.removeChild(l));break;case 27:jt||Ve(l,e);var n=_t,a=ie;Bl(l.type)&&(_t=l.stateNode,ie=!1),cl(t,e,l),Ja(l.stateNode),_t=n,ie=a;break;case 5:jt||Ve(l,e);case 6:if(n=_t,a=ie,_t=null,cl(t,e,l),_t=n,ie=a,_t!==null)if(ie)try{(_t.nodeType===9?_t.body:_t.nodeName==="HTML"?_t.ownerDocument.body:_t).removeChild(l.stateNode)}catch(i){ft(l,e,i)}else try{_t.removeChild(l.stateNode)}catch(i){ft(l,e,i)}break;case 18:_t!==null&&(ie?(t=_t,md(t.nodeType===9?t.body:t.nodeName==="HTML"?t.ownerDocument.body:t,l.stateNode),In(t)):md(_t,l.stateNode));break;case 4:n=_t,a=ie,_t=l.stateNode.containerInfo,ie=!0,cl(t,e,l),_t=n,ie=a;break;case 0:case 11:case 14:case 15:Ol(2,l,e),jt||Ol(4,l,e),cl(t,e,l);break;case 1:jt||(Ve(l,e),n=l.stateNode,typeof n.componentWillUnmount=="function"&&yh(l,e,n)),cl(t,e,l);break;case 21:cl(t,e,l);break;case 22:jt=(n=jt)||l.memoizedState!==null,cl(t,e,l),jt=n;break;default:cl(t,e,l)}}function Ah(t,e){if(e.memoizedState===null&&(t=e.alternate,t!==null&&(t=t.memoizedState,t!==null))){t=t.dehydrated;try{In(t)}catch(l){ft(e,e.return,l)}}}function _h(t,e){if(e.memoizedState===null&&(t=e.alternate,t!==null&&(t=t.memoizedState,t!==null&&(t=t.dehydrated,t!==null))))try{In(t)}catch(l){ft(e,e.return,l)}}function Rg(t){switch(t.tag){case 31:case 13:case 19:var e=t.stateNode;return e===null&&(e=t.stateNode=new Sh),e;case 22:return t=t.stateNode,e=t._retryCache,e===null&&(e=t._retryCache=new Sh),e;default:throw Error(c(435,t.tag))}}function nu(t,e){var l=Rg(t);e.forEach(function(n){if(!l.has(n)){l.add(n);var a=Yg.bind(null,t,n);n.then(a,a)}})}function ue(t,e){var l=e.deletions;if(l!==null)for(var n=0;n<l.length;n++){var a=l[n],i=t,f=e,o=f;t:for(;o!==null;){switch(o.tag){case 27:if(Bl(o.type)){_t=o.stateNode,ie=!1;break t}break;case 5:_t=o.stateNode,ie=!1;break t;case 3:case 4:_t=o.stateNode.containerInfo,ie=!0;break t}o=o.return}if(_t===null)throw Error(c(160));Th(i,f,a),_t=null,ie=!1,i=a.alternate,i!==null&&(i.return=null),a.return=null}if(e.subtreeFlags&13886)for(e=e.child;e!==null;)xh(e,t),e=e.sibling}var Be=null;function xh(t,e){var l=t.alternate,n=t.flags;switch(t.tag){case 0:case 11:case 14:case 15:ue(e,t),se(t),n&4&&(Ol(3,t,t.return),La(3,t),Ol(5,t,t.return));break;case 1:ue(e,t),se(t),n&512&&(jt||l===null||Ve(l,l.return)),n&64&&sl&&(t=t.updateQueue,t!==null&&(n=t.callbacks,n!==null&&(l=t.shared.hiddenCallbacks,t.shared.hiddenCallbacks=l===null?n:l.concat(n))));break;case 26:var a=Be;if(ue(e,t),se(t),n&512&&(jt||l===null||Ve(l,l.return)),n&4){var i=l!==null?l.memoizedState:null;if(n=t.memoizedState,l===null)if(n===null)if(t.stateNode===null){t:{n=t.type,l=t.memoizedProps,a=a.ownerDocument||a;e:switch(n){case"title":i=a.getElementsByTagName("title")[0],(!i||i[oa]||i[Kt]||i.namespaceURI==="http://www.w3.org/2000/svg"||i.hasAttribute("itemprop"))&&(i=a.createElement(n),a.head.insertBefore(i,a.querySelector("head > title"))),kt(i,n,l),i[Kt]=t,Xt(i),n=i;break t;case"link":var f=xd("link","href",a).get(n+(l.href||""));if(f){for(var o=0;o<f.length;o++)if(i=f[o],i.getAttribute("href")===(l.href==null||l.href===""?null:l.href)&&i.getAttribute("rel")===(l.rel==null?null:l.rel)&&i.getAttribute("title")===(l.title==null?null:l.title)&&i.getAttribute("crossorigin")===(l.crossOrigin==null?null:l.crossOrigin)){f.splice(o,1);break e}}i=a.createElement(n),kt(i,n,l),a.head.appendChild(i);break;case"meta":if(f=xd("meta","content",a).get(n+(l.content||""))){for(o=0;o<f.length;o++)if(i=f[o],i.getAttribute("content")===(l.content==null?null:""+l.content)&&i.getAttribute("name")===(l.name==null?null:l.name)&&i.getAttribute("property")===(l.property==null?null:l.property)&&i.getAttribute("http-equiv")===(l.httpEquiv==null?null:l.httpEquiv)&&i.getAttribute("charset")===(l.charSet==null?null:l.charSet)){f.splice(o,1);break e}}i=a.createElement(n),kt(i,n,l),a.head.appendChild(i);break;default:throw Error(c(468,n))}i[Kt]=t,Xt(i),n=i}t.stateNode=n}else Md(a,t.type,t.stateNode);else t.stateNode=_d(a,n,t.memoizedProps);else i!==n?(i===null?l.stateNode!==null&&(l=l.stateNode,l.parentNode.removeChild(l)):i.count--,n===null?Md(a,t.type,t.stateNode):_d(a,n,t.memoizedProps)):n===null&&t.stateNode!==null&&_c(t,t.memoizedProps,l.memoizedProps)}break;case 27:ue(e,t),se(t),n&512&&(jt||l===null||Ve(l,l.return)),l!==null&&n&4&&_c(t,t.memoizedProps,l.memoizedProps);break;case 5:if(ue(e,t),se(t),n&512&&(jt||l===null||Ve(l,l.return)),t.flags&32){a=t.stateNode;try{En(a,"")}catch(B){ft(t,t.return,B)}}n&4&&t.stateNode!=null&&(a=t.memoizedProps,_c(t,a,l!==null?l.memoizedProps:a)),n&1024&&(zc=!0);break;case 6:if(ue(e,t),se(t),n&4){if(t.stateNode===null)throw Error(c(162));n=t.memoizedProps,l=t.stateNode;try{l.nodeValue=n}catch(B){ft(t,t.return,B)}}break;case 3:if(Su=null,a=Be,Be=pu(e.containerInfo),ue(e,t),Be=a,se(t),n&4&&l!==null&&l.memoizedState.isDehydrated)try{In(e.containerInfo)}catch(B){ft(t,t.return,B)}zc&&(zc=!1,Mh(t));break;case 4:n=Be,Be=pu(t.stateNode.containerInfo),ue(e,t),se(t),Be=n;break;case 12:ue(e,t),se(t);break;case 31:ue(e,t),se(t),n&4&&(n=t.updateQueue,n!==null&&(t.updateQueue=null,nu(t,n)));break;case 13:ue(e,t),se(t),t.child.flags&8192&&t.memoizedState!==null!=(l!==null&&l.memoizedState!==null)&&(iu=oe()),n&4&&(n=t.updateQueue,n!==null&&(t.updateQueue=null,nu(t,n)));break;case 22:a=t.memoizedState!==null;var m=l!==null&&l.memoizedState!==null,A=sl,M=jt;if(sl=A||a,jt=M||m,ue(e,t),jt=M,sl=A,se(t),n&8192)t:for(e=t.stateNode,e._visibility=a?e._visibility&-2:e._visibility|1,a&&(l===null||m||sl||jt||on(t)),l=null,e=t;;){if(e.tag===5||e.tag===26){if(l===null){m=l=e;try{if(i=m.stateNode,a)f=i.style,typeof f.setProperty=="function"?f.setProperty("display","none","important"):f.display="none";else{o=m.stateNode;var O=m.memoizedProps.style,_=O!=null&&O.hasOwnProperty("display")?O.display:null;o.style.display=_==null||typeof _=="boolean"?"":(""+_).trim()}}catch(B){ft(m,m.return,B)}}}else if(e.tag===6){if(l===null){m=e;try{m.stateNode.nodeValue=a?"":m.memoizedProps}catch(B){ft(m,m.return,B)}}}else if(e.tag===18){if(l===null){m=e;try{var x=m.stateNode;a?yd(x,!0):yd(m.stateNode,!1)}catch(B){ft(m,m.return,B)}}}else if((e.tag!==22&&e.tag!==23||e.memoizedState===null||e===t)&&e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break t;for(;e.sibling===null;){if(e.return===null||e.return===t)break t;l===e&&(l=null),e=e.return}l===e&&(l=null),e.sibling.return=e.return,e=e.sibling}n&4&&(n=t.updateQueue,n!==null&&(l=n.retryQueue,l!==null&&(n.retryQueue=null,nu(t,l))));break;case 19:ue(e,t),se(t),n&4&&(n=t.updateQueue,n!==null&&(t.updateQueue=null,nu(t,n)));break;case 30:break;case 21:break;default:ue(e,t),se(t)}}function se(t){var e=t.flags;if(e&2){try{for(var l,n=t.return;n!==null;){if(ph(n)){l=n;break}n=n.return}if(l==null)throw Error(c(160));switch(l.tag){case 27:var a=l.stateNode,i=xc(t);lu(t,i,a);break;case 5:var f=l.stateNode;l.flags&32&&(En(f,""),l.flags&=-33);var o=xc(t);lu(t,o,f);break;case 3:case 4:var m=l.stateNode.containerInfo,A=xc(t);Mc(t,A,m);break;default:throw Error(c(161))}}catch(M){ft(t,t.return,M)}t.flags&=-3}e&4096&&(t.flags&=-4097)}function Mh(t){if(t.subtreeFlags&1024)for(t=t.child;t!==null;){var e=t;Mh(e),e.tag===5&&e.flags&1024&&e.stateNode.reset(),t=t.sibling}}function rl(t,e){if(e.subtreeFlags&8772)for(e=e.child;e!==null;)bh(t,e.alternate,e),e=e.sibling}function on(t){for(t=t.child;t!==null;){var e=t;switch(e.tag){case 0:case 11:case 14:case 15:Ol(4,e,e.return),on(e);break;case 1:Ve(e,e.return);var l=e.stateNode;typeof l.componentWillUnmount=="function"&&yh(e,e.return,l),on(e);break;case 27:Ja(e.stateNode);case 26:case 5:Ve(e,e.return),on(e);break;case 22:e.memoizedState===null&&on(e);break;case 30:on(e);break;default:on(e)}t=t.sibling}}function fl(t,e,l){for(l=l&&(e.subtreeFlags&8772)!==0,e=e.child;e!==null;){var n=e.alternate,a=t,i=e,f=i.flags;switch(i.tag){case 0:case 11:case 15:fl(a,i,l),La(4,i);break;case 1:if(fl(a,i,l),n=i,a=n.stateNode,typeof a.componentDidMount=="function")try{a.componentDidMount()}catch(A){ft(n,n.return,A)}if(n=i,a=n.updateQueue,a!==null){var o=n.stateNode;try{var m=a.shared.hiddenCallbacks;if(m!==null)for(a.shared.hiddenCallbacks=null,a=0;a<m.length;a++)lo(m[a],o)}catch(A){ft(n,n.return,A)}}l&&f&64&&mh(i),ja(i,i.return);break;case 27:vh(i);case 26:case 5:fl(a,i,l),l&&n===null&&f&4&&gh(i),ja(i,i.return);break;case 12:fl(a,i,l);break;case 31:fl(a,i,l),l&&f&4&&Ah(a,i);break;case 13:fl(a,i,l),l&&f&4&&_h(a,i);break;case 22:i.memoizedState===null&&fl(a,i,l),ja(i,i.return);break;case 30:break;default:fl(a,i,l)}e=e.sibling}}function Cc(t,e){var l=null;t!==null&&t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(l=t.memoizedState.cachePool.pool),t=null,e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(t=e.memoizedState.cachePool.pool),t!==l&&(t!=null&&t.refCount++,l!=null&&_a(l))}function Oc(t,e){t=null,e.alternate!==null&&(t=e.alternate.memoizedState.cache),e=e.memoizedState.cache,e!==t&&(e.refCount++,t!=null&&_a(t))}function Le(t,e,l,n){if(e.subtreeFlags&10256)for(e=e.child;e!==null;)zh(t,e,l,n),e=e.sibling}function zh(t,e,l,n){var a=e.flags;switch(e.tag){case 0:case 11:case 15:Le(t,e,l,n),a&2048&&La(9,e);break;case 1:Le(t,e,l,n);break;case 3:Le(t,e,l,n),a&2048&&(t=null,e.alternate!==null&&(t=e.alternate.memoizedState.cache),e=e.memoizedState.cache,e!==t&&(e.refCount++,t!=null&&_a(t)));break;case 12:if(a&2048){Le(t,e,l,n),t=e.stateNode;try{var i=e.memoizedProps,f=i.id,o=i.onPostCommit;typeof o=="function"&&o(f,e.alternate===null?"mount":"update",t.passiveEffectDuration,-0)}catch(m){ft(e,e.return,m)}}else Le(t,e,l,n);break;case 31:Le(t,e,l,n);break;case 13:Le(t,e,l,n);break;case 23:break;case 22:i=e.stateNode,f=e.alternate,e.memoizedState!==null?i._visibility&2?Le(t,e,l,n):qa(t,e):i._visibility&2?Le(t,e,l,n):(i._visibility|=2,Xn(t,e,l,n,(e.subtreeFlags&10256)!==0||!1)),a&2048&&Cc(f,e);break;case 24:Le(t,e,l,n),a&2048&&Oc(e.alternate,e);break;default:Le(t,e,l,n)}}function Xn(t,e,l,n,a){for(a=a&&((e.subtreeFlags&10256)!==0||!1),e=e.child;e!==null;){var i=t,f=e,o=l,m=n,A=f.flags;switch(f.tag){case 0:case 11:case 15:Xn(i,f,o,m,a),La(8,f);break;case 23:break;case 22:var M=f.stateNode;f.memoizedState!==null?M._visibility&2?Xn(i,f,o,m,a):qa(i,f):(M._visibility|=2,Xn(i,f,o,m,a)),a&&A&2048&&Cc(f.alternate,f);break;case 24:Xn(i,f,o,m,a),a&&A&2048&&Oc(f.alternate,f);break;default:Xn(i,f,o,m,a)}e=e.sibling}}function qa(t,e){if(e.subtreeFlags&10256)for(e=e.child;e!==null;){var l=t,n=e,a=n.flags;switch(n.tag){case 22:qa(l,n),a&2048&&Cc(n.alternate,n);break;case 24:qa(l,n),a&2048&&Oc(n.alternate,n);break;default:qa(l,n)}e=e.sibling}}var Ya=8192;function Gn(t,e,l){if(t.subtreeFlags&Ya)for(t=t.child;t!==null;)Ch(t,e,l),t=t.sibling}function Ch(t,e,l){switch(t.tag){case 26:Gn(t,e,l),t.flags&Ya&&t.memoizedState!==null&&pp(l,Be,t.memoizedState,t.memoizedProps);break;case 5:Gn(t,e,l);break;case 3:case 4:var n=Be;Be=pu(t.stateNode.containerInfo),Gn(t,e,l),Be=n;break;case 22:t.memoizedState===null&&(n=t.alternate,n!==null&&n.memoizedState!==null?(n=Ya,Ya=16777216,Gn(t,e,l),Ya=n):Gn(t,e,l));break;default:Gn(t,e,l)}}function Oh(t){var e=t.alternate;if(e!==null&&(t=e.child,t!==null)){e.child=null;do e=t.sibling,t.sibling=null,t=e;while(t!==null)}}function Xa(t){var e=t.deletions;if((t.flags&16)!==0){if(e!==null)for(var l=0;l<e.length;l++){var n=e[l];Gt=n,Rh(n,t)}Oh(t)}if(t.subtreeFlags&10256)for(t=t.child;t!==null;)Dh(t),t=t.sibling}function Dh(t){switch(t.tag){case 0:case 11:case 15:Xa(t),t.flags&2048&&Ol(9,t,t.return);break;case 3:Xa(t);break;case 12:Xa(t);break;case 22:var e=t.stateNode;t.memoizedState!==null&&e._visibility&2&&(t.return===null||t.return.tag!==13)?(e._visibility&=-3,au(t)):Xa(t);break;default:Xa(t)}}function au(t){var e=t.deletions;if((t.flags&16)!==0){if(e!==null)for(var l=0;l<e.length;l++){var n=e[l];Gt=n,Rh(n,t)}Oh(t)}for(t=t.child;t!==null;){switch(e=t,e.tag){case 0:case 11:case 15:Ol(8,e,e.return),au(e);break;case 22:l=e.stateNode,l._visibility&2&&(l._visibility&=-3,au(e));break;default:au(e)}t=t.sibling}}function Rh(t,e){for(;Gt!==null;){var l=Gt;switch(l.tag){case 0:case 11:case 15:Ol(8,l,e);break;case 23:case 22:if(l.memoizedState!==null&&l.memoizedState.cachePool!==null){var n=l.memoizedState.cachePool.pool;n!=null&&n.refCount++}break;case 24:_a(l.memoizedState.cache)}if(n=l.child,n!==null)n.return=l,Gt=n;else t:for(l=t;Gt!==null;){n=Gt;var a=n.sibling,i=n.return;if(Eh(n),n===l){Gt=null;break t}if(a!==null){a.return=i,Gt=a;break t}Gt=i}}}var Ug={getCacheForType:function(t){var e=Zt(Nt),l=e.data.get(t);return l===void 0&&(l=t(),e.data.set(t,l)),l},cacheSignal:function(){return Zt(Nt).controller.signal}},wg=typeof WeakMap=="function"?WeakMap:Map,ut=0,gt=null,I=null,tt=0,rt=0,ve=null,Dl=!1,Qn=!1,Dc=!1,ol=0,Ot=0,Rl=0,hn=0,Rc=0,Se=0,Kn=0,Ga=null,ce=null,Uc=!1,iu=0,Uh=0,uu=1/0,su=null,Ul=null,qt=0,wl=null,Vn=null,hl=0,wc=0,Hc=null,wh=null,Qa=0,Nc=null;function be(){return(ut&2)!==0&&tt!==0?tt&-tt:z.T!==null?Xc():Jr()}function Hh(){if(Se===0)if((tt&536870912)===0||lt){var t=yi;yi<<=1,(yi&3932160)===0&&(yi=262144),Se=t}else Se=536870912;return t=ge.current,t!==null&&(t.flags|=32),Se}function re(t,e,l){(t===gt&&(rt===2||rt===9)||t.cancelPendingCommit!==null)&&(Zn(t,0),Hl(t,tt,Se,!1)),fa(t,l),((ut&2)===0||t!==gt)&&(t===gt&&((ut&2)===0&&(hn|=l),Ot===4&&Hl(t,tt,Se,!1)),Ze(t))}function Nh(t,e,l){if((ut&6)!==0)throw Error(c(327));var n=!l&&(e&127)===0&&(e&t.expiredLanes)===0||ra(t,e),a=n?Bg(t,e):Lc(t,e,!0),i=n;do{if(a===0){Qn&&!n&&Hl(t,e,0,!1);break}else{if(l=t.current.alternate,i&&!Hg(l)){a=Lc(t,e,!1),i=!1;continue}if(a===2){if(i=e,t.errorRecoveryDisabledLanes&i)var f=0;else f=t.pendingLanes&-536870913,f=f!==0?f:f&536870912?536870912:0;if(f!==0){e=f;t:{var o=t;a=Ga;var m=o.current.memoizedState.isDehydrated;if(m&&(Zn(o,f).flags|=256),f=Lc(o,f,!1),f!==2){if(Dc&&!m){o.errorRecoveryDisabledLanes|=i,hn|=i,a=4;break t}i=ce,ce=a,i!==null&&(ce===null?ce=i:ce.push.apply(ce,i))}a=f}if(i=!1,a!==2)continue}}if(a===1){Zn(t,0),Hl(t,e,0,!0);break}t:{switch(n=t,i=a,i){case 0:case 1:throw Error(c(345));case 4:if((e&4194048)!==e)break;case 6:Hl(n,e,Se,!Dl);break t;case 2:ce=null;break;case 3:case 5:break;default:throw Error(c(329))}if((e&62914560)===e&&(a=iu+300-oe(),10<a)){if(Hl(n,e,Se,!Dl),pi(n,0,!0)!==0)break t;hl=e,n.timeoutHandle=hd(Bh.bind(null,n,l,ce,su,Uc,e,Se,hn,Kn,Dl,i,"Throttled",-0,0),a);break t}Bh(n,l,ce,su,Uc,e,Se,hn,Kn,Dl,i,null,-0,0)}}break}while(!0);Ze(t)}function Bh(t,e,l,n,a,i,f,o,m,A,M,O,_,x){if(t.timeoutHandle=-1,O=e.subtreeFlags,O&8192||(O&16785408)===16785408){O={stylesheets:null,count:0,imgCount:0,imgBytes:0,suspenseyImages:[],waitingForImages:!0,waitingForViewTransition:!1,unsuspend:Fe},Ch(e,i,O);var B=(i&62914560)===i?iu-oe():(i&4194048)===i?Uh-oe():0;if(B=vp(O,B),B!==null){hl=i,t.cancelPendingCommit=B(Kh.bind(null,t,e,i,l,n,a,f,o,m,M,O,null,_,x)),Hl(t,i,f,!A);return}}Kh(t,e,i,l,n,a,f,o,m)}function Hg(t){for(var e=t;;){var l=e.tag;if((l===0||l===11||l===15)&&e.flags&16384&&(l=e.updateQueue,l!==null&&(l=l.stores,l!==null)))for(var n=0;n<l.length;n++){var a=l[n],i=a.getSnapshot;a=a.value;try{if(!me(i(),a))return!1}catch{return!1}}if(l=e.child,e.subtreeFlags&16384&&l!==null)l.return=e,e=l;else{if(e===t)break;for(;e.sibling===null;){if(e.return===null||e.return===t)return!0;e=e.return}e.sibling.return=e.return,e=e.sibling}}return!0}function Hl(t,e,l,n){e&=~Rc,e&=~hn,t.suspendedLanes|=e,t.pingedLanes&=~e,n&&(t.warmLanes|=e),n=t.expirationTimes;for(var a=e;0<a;){var i=31-de(a),f=1<<i;n[i]=-1,a&=~f}l!==0&&Kr(t,l,e)}function cu(){return(ut&6)===0?(Ka(0),!1):!0}function Bc(){if(I!==null){if(rt===0)var t=I.return;else t=I,el=ln=null,Is(t),Bn=null,Ma=0,t=I;for(;t!==null;)dh(t.alternate,t),t=t.return;I=null}}function Zn(t,e){var l=t.timeoutHandle;l!==-1&&(t.timeoutHandle=-1,tp(l)),l=t.cancelPendingCommit,l!==null&&(t.cancelPendingCommit=null,l()),hl=0,Bc(),gt=t,I=l=Pe(t.current,null),tt=e,rt=0,ve=null,Dl=!1,Qn=ra(t,e),Dc=!1,Kn=Se=Rc=hn=Rl=Ot=0,ce=Ga=null,Uc=!1,(e&8)!==0&&(e|=e&32);var n=t.entangledLanes;if(n!==0)for(t=t.entanglements,n&=e;0<n;){var a=31-de(n),i=1<<a;e|=t[a],n&=~i}return ol=e,Oi(),l}function Lh(t,e){J=null,z.H=Ha,e===Nn||e===Li?(e=If(),rt=3):e===Ys?(e=If(),rt=4):rt=e===mc?8:e!==null&&typeof e=="object"&&typeof e.then=="function"?6:1,ve=e,I===null&&(Ot=1,Fi(t,xe(e,t.current)))}function jh(){var t=ge.current;return t===null?!0:(tt&4194048)===tt?Oe===null:(tt&62914560)===tt||(tt&536870912)!==0?t===Oe:!1}function qh(){var t=z.H;return z.H=Ha,t===null?Ha:t}function Yh(){var t=z.A;return z.A=Ug,t}function ru(){Ot=4,Dl||(tt&4194048)!==tt&&ge.current!==null||(Qn=!0),(Rl&134217727)===0&&(hn&134217727)===0||gt===null||Hl(gt,tt,Se,!1)}function Lc(t,e,l){var n=ut;ut|=2;var a=qh(),i=Yh();(gt!==t||tt!==e)&&(su=null,Zn(t,e)),e=!1;var f=Ot;t:do try{if(rt!==0&&I!==null){var o=I,m=ve;switch(rt){case 8:Bc(),f=6;break t;case 3:case 2:case 9:case 6:ge.current===null&&(e=!0);var A=rt;if(rt=0,ve=null,Jn(t,o,m,A),l&&Qn){f=0;break t}break;default:A=rt,rt=0,ve=null,Jn(t,o,m,A)}}Ng(),f=Ot;break}catch(M){Lh(t,M)}while(!0);return e&&t.shellSuspendCounter++,el=ln=null,ut=n,z.H=a,z.A=i,I===null&&(gt=null,tt=0,Oi()),f}function Ng(){for(;I!==null;)Xh(I)}function Bg(t,e){var l=ut;ut|=2;var n=qh(),a=Yh();gt!==t||tt!==e?(su=null,uu=oe()+500,Zn(t,e)):Qn=ra(t,e);t:do try{if(rt!==0&&I!==null){e=I;var i=ve;e:switch(rt){case 1:rt=0,ve=null,Jn(t,e,i,1);break;case 2:case 9:if($f(i)){rt=0,ve=null,Gh(e);break}e=function(){rt!==2&&rt!==9||gt!==t||(rt=7),Ze(t)},i.then(e,e);break t;case 3:rt=7;break t;case 4:rt=5;break t;case 7:$f(i)?(rt=0,ve=null,Gh(e)):(rt=0,ve=null,Jn(t,e,i,7));break;case 5:var f=null;switch(I.tag){case 26:f=I.memoizedState;case 5:case 27:var o=I;if(f?zd(f):o.stateNode.complete){rt=0,ve=null;var m=o.sibling;if(m!==null)I=m;else{var A=o.return;A!==null?(I=A,fu(A)):I=null}break e}}rt=0,ve=null,Jn(t,e,i,5);break;case 6:rt=0,ve=null,Jn(t,e,i,6);break;case 8:Bc(),Ot=6;break t;default:throw Error(c(462))}}Lg();break}catch(M){Lh(t,M)}while(!0);return el=ln=null,z.H=n,z.A=a,ut=l,I!==null?0:(gt=null,tt=0,Oi(),Ot)}function Lg(){for(;I!==null&&!uy();)Xh(I)}function Xh(t){var e=oh(t.alternate,t,ol);t.memoizedProps=t.pendingProps,e===null?fu(t):I=e}function Gh(t){var e=t,l=e.alternate;switch(e.tag){case 15:case 0:e=ih(l,e,e.pendingProps,e.type,void 0,tt);break;case 11:e=ih(l,e,e.pendingProps,e.type.render,e.ref,tt);break;case 5:Is(e);default:dh(l,e),e=I=qf(e,ol),e=oh(l,e,ol)}t.memoizedProps=t.pendingProps,e===null?fu(t):I=e}function Jn(t,e,l,n){el=ln=null,Is(e),Bn=null,Ma=0;var a=e.return;try{if(xg(t,a,e,l,tt)){Ot=1,Fi(t,xe(l,t.current)),I=null;return}}catch(i){if(a!==null)throw I=a,i;Ot=1,Fi(t,xe(l,t.current)),I=null;return}e.flags&32768?(lt||n===1?t=!0:Qn||(tt&536870912)!==0?t=!1:(Dl=t=!0,(n===2||n===9||n===3||n===6)&&(n=ge.current,n!==null&&n.tag===13&&(n.flags|=16384))),Qh(e,t)):fu(e)}function fu(t){var e=t;do{if((e.flags&32768)!==0){Qh(e,Dl);return}t=e.return;var l=Cg(e.alternate,e,ol);if(l!==null){I=l;return}if(e=e.sibling,e!==null){I=e;return}I=e=t}while(e!==null);Ot===0&&(Ot=5)}function Qh(t,e){do{var l=Og(t.alternate,t);if(l!==null){l.flags&=32767,I=l;return}if(l=t.return,l!==null&&(l.flags|=32768,l.subtreeFlags=0,l.deletions=null),!e&&(t=t.sibling,t!==null)){I=t;return}I=t=l}while(t!==null);Ot=6,I=null}function Kh(t,e,l,n,a,i,f,o,m){t.cancelPendingCommit=null;do ou();while(qt!==0);if((ut&6)!==0)throw Error(c(327));if(e!==null){if(e===t.current)throw Error(c(177));if(i=e.lanes|e.childLanes,i|=xs,gy(t,l,i,f,o,m),t===gt&&(I=gt=null,tt=0),Vn=e,wl=t,hl=l,wc=i,Hc=a,wh=n,(e.subtreeFlags&10256)!==0||(e.flags&10256)!==0?(t.callbackNode=null,t.callbackPriority=0,Xg(di,function(){return Wh(),null})):(t.callbackNode=null,t.callbackPriority=0),n=(e.flags&13878)!==0,(e.subtreeFlags&13878)!==0||n){n=z.T,z.T=null,a=w.p,w.p=2,f=ut,ut|=4;try{Dg(t,e,l)}finally{ut=f,w.p=a,z.T=n}}qt=1,Vh(),Zh(),Jh()}}function Vh(){if(qt===1){qt=0;var t=wl,e=Vn,l=(e.flags&13878)!==0;if((e.subtreeFlags&13878)!==0||l){l=z.T,z.T=null;var n=w.p;w.p=2;var a=ut;ut|=4;try{xh(e,t);var i=Wc,f=Df(t.containerInfo),o=i.focusedElem,m=i.selectionRange;if(f!==o&&o&&o.ownerDocument&&Of(o.ownerDocument.documentElement,o)){if(m!==null&&bs(o)){var A=m.start,M=m.end;if(M===void 0&&(M=A),"selectionStart"in o)o.selectionStart=A,o.selectionEnd=Math.min(M,o.value.length);else{var O=o.ownerDocument||document,_=O&&O.defaultView||window;if(_.getSelection){var x=_.getSelection(),B=o.textContent.length,Y=Math.min(m.start,B),mt=m.end===void 0?Y:Math.min(m.end,B);!x.extend&&Y>mt&&(f=mt,mt=Y,Y=f);var S=Cf(o,Y),g=Cf(o,mt);if(S&&g&&(x.rangeCount!==1||x.anchorNode!==S.node||x.anchorOffset!==S.offset||x.focusNode!==g.node||x.focusOffset!==g.offset)){var T=O.createRange();T.setStart(S.node,S.offset),x.removeAllRanges(),Y>mt?(x.addRange(T),x.extend(g.node,g.offset)):(T.setEnd(g.node,g.offset),x.addRange(T))}}}}for(O=[],x=o;x=x.parentNode;)x.nodeType===1&&O.push({element:x,left:x.scrollLeft,top:x.scrollTop});for(typeof o.focus=="function"&&o.focus(),o=0;o<O.length;o++){var C=O[o];C.element.scrollLeft=C.left,C.element.scrollTop=C.top}}Au=!!kc,Wc=kc=null}finally{ut=a,w.p=n,z.T=l}}t.current=e,qt=2}}function Zh(){if(qt===2){qt=0;var t=wl,e=Vn,l=(e.flags&8772)!==0;if((e.subtreeFlags&8772)!==0||l){l=z.T,z.T=null;var n=w.p;w.p=2;var a=ut;ut|=4;try{bh(t,e.alternate,e)}finally{ut=a,w.p=n,z.T=l}}qt=3}}function Jh(){if(qt===4||qt===3){qt=0,sy();var t=wl,e=Vn,l=hl,n=wh;(e.subtreeFlags&10256)!==0||(e.flags&10256)!==0?qt=5:(qt=0,Vn=wl=null,kh(t,t.pendingLanes));var a=t.pendingLanes;if(a===0&&(Ul=null),es(l),e=e.stateNode,he&&typeof he.onCommitFiberRoot=="function")try{he.onCommitFiberRoot(ca,e,void 0,(e.current.flags&128)===128)}catch{}if(n!==null){e=z.T,a=w.p,w.p=2,z.T=null;try{for(var i=t.onRecoverableError,f=0;f<n.length;f++){var o=n[f];i(o.value,{componentStack:o.stack})}}finally{z.T=e,w.p=a}}(hl&3)!==0&&ou(),Ze(t),a=t.pendingLanes,(l&261930)!==0&&(a&42)!==0?t===Nc?Qa++:(Qa=0,Nc=t):Qa=0,Ka(0)}}function kh(t,e){(t.pooledCacheLanes&=e)===0&&(e=t.pooledCache,e!=null&&(t.pooledCache=null,_a(e)))}function ou(){return Vh(),Zh(),Jh(),Wh()}function Wh(){if(qt!==5)return!1;var t=wl,e=wc;wc=0;var l=es(hl),n=z.T,a=w.p;try{w.p=32>l?32:l,z.T=null,l=Hc,Hc=null;var i=wl,f=hl;if(qt=0,Vn=wl=null,hl=0,(ut&6)!==0)throw Error(c(331));var o=ut;if(ut|=4,Dh(i.current),zh(i,i.current,f,l),ut=o,Ka(0,!1),he&&typeof he.onPostCommitFiberRoot=="function")try{he.onPostCommitFiberRoot(ca,i)}catch{}return!0}finally{w.p=a,z.T=n,kh(t,e)}}function $h(t,e,l){e=xe(l,e),e=dc(t.stateNode,e,2),t=Ml(t,e,2),t!==null&&(fa(t,2),Ze(t))}function ft(t,e,l){if(t.tag===3)$h(t,t,l);else for(;e!==null;){if(e.tag===3){$h(e,t,l);break}else if(e.tag===1){var n=e.stateNode;if(typeof e.type.getDerivedStateFromError=="function"||typeof n.componentDidCatch=="function"&&(Ul===null||!Ul.has(n))){t=xe(l,t),l=Fo(2),n=Ml(e,l,2),n!==null&&(Io(l,n,e,t),fa(n,2),Ze(n));break}}e=e.return}}function jc(t,e,l){var n=t.pingCache;if(n===null){n=t.pingCache=new wg;var a=new Set;n.set(e,a)}else a=n.get(e),a===void 0&&(a=new Set,n.set(e,a));a.has(l)||(Dc=!0,a.add(l),t=jg.bind(null,t,e,l),e.then(t,t))}function jg(t,e,l){var n=t.pingCache;n!==null&&n.delete(e),t.pingedLanes|=t.suspendedLanes&l,t.warmLanes&=~l,gt===t&&(tt&l)===l&&(Ot===4||Ot===3&&(tt&62914560)===tt&&300>oe()-iu?(ut&2)===0&&Zn(t,0):Rc|=l,Kn===tt&&(Kn=0)),Ze(t)}function Fh(t,e){e===0&&(e=Qr()),t=Pl(t,e),t!==null&&(fa(t,e),Ze(t))}function qg(t){var e=t.memoizedState,l=0;e!==null&&(l=e.retryLane),Fh(t,l)}function Yg(t,e){var l=0;switch(t.tag){case 31:case 13:var n=t.stateNode,a=t.memoizedState;a!==null&&(l=a.retryLane);break;case 19:n=t.stateNode;break;case 22:n=t.stateNode._retryCache;break;default:throw Error(c(314))}n!==null&&n.delete(e),Fh(t,l)}function Xg(t,e){return Fu(t,e)}var hu=null,kn=null,qc=!1,du=!1,Yc=!1,Nl=0;function Ze(t){t!==kn&&t.next===null&&(kn===null?hu=kn=t:kn=kn.next=t),du=!0,qc||(qc=!0,Qg())}function Ka(t,e){if(!Yc&&du){Yc=!0;do for(var l=!1,n=hu;n!==null;){if(t!==0){var a=n.pendingLanes;if(a===0)var i=0;else{var f=n.suspendedLanes,o=n.pingedLanes;i=(1<<31-de(42|t)+1)-1,i&=a&~(f&~o),i=i&201326741?i&201326741|1:i?i|2:0}i!==0&&(l=!0,ed(n,i))}else i=tt,i=pi(n,n===gt?i:0,n.cancelPendingCommit!==null||n.timeoutHandle!==-1),(i&3)===0||ra(n,i)||(l=!0,ed(n,i));n=n.next}while(l);Yc=!1}}function Gg(){Ih()}function Ih(){du=qc=!1;var t=0;Nl!==0&&Pg()&&(t=Nl);for(var e=oe(),l=null,n=hu;n!==null;){var a=n.next,i=Ph(n,e);i===0?(n.next=null,l===null?hu=a:l.next=a,a===null&&(kn=l)):(l=n,(t!==0||(i&3)!==0)&&(du=!0)),n=a}qt!==0&&qt!==5||Ka(t),Nl!==0&&(Nl=0)}function Ph(t,e){for(var l=t.suspendedLanes,n=t.pingedLanes,a=t.expirationTimes,i=t.pendingLanes&-62914561;0<i;){var f=31-de(i),o=1<<f,m=a[f];m===-1?((o&l)===0||(o&n)!==0)&&(a[f]=yy(o,e)):m<=e&&(t.expiredLanes|=o),i&=~o}if(e=gt,l=tt,l=pi(t,t===e?l:0,t.cancelPendingCommit!==null||t.timeoutHandle!==-1),n=t.callbackNode,l===0||t===e&&(rt===2||rt===9)||t.cancelPendingCommit!==null)return n!==null&&n!==null&&Iu(n),t.callbackNode=null,t.callbackPriority=0;if((l&3)===0||ra(t,l)){if(e=l&-l,e===t.callbackPriority)return e;switch(n!==null&&Iu(n),es(l)){case 2:case 8:l=Xr;break;case 32:l=di;break;case 268435456:l=Gr;break;default:l=di}return n=td.bind(null,t),l=Fu(l,n),t.callbackPriority=e,t.callbackNode=l,e}return n!==null&&n!==null&&Iu(n),t.callbackPriority=2,t.callbackNode=null,2}function td(t,e){if(qt!==0&&qt!==5)return t.callbackNode=null,t.callbackPriority=0,null;var l=t.callbackNode;if(ou()&&t.callbackNode!==l)return null;var n=tt;return n=pi(t,t===gt?n:0,t.cancelPendingCommit!==null||t.timeoutHandle!==-1),n===0?null:(Nh(t,n,e),Ph(t,oe()),t.callbackNode!=null&&t.callbackNode===l?td.bind(null,t):null)}function ed(t,e){if(ou())return null;Nh(t,e,!0)}function Qg(){ep(function(){(ut&6)!==0?Fu(Yr,Gg):Ih()})}function Xc(){if(Nl===0){var t=wn;t===0&&(t=mi,mi<<=1,(mi&261888)===0&&(mi=256)),Nl=t}return Nl}function ld(t){return t==null||typeof t=="symbol"||typeof t=="boolean"?null:typeof t=="function"?t:Ei(""+t)}function nd(t,e){var l=e.ownerDocument.createElement("input");return l.name=e.name,l.value=e.value,t.id&&l.setAttribute("form",t.id),e.parentNode.insertBefore(l,e),t=new FormData(t),l.parentNode.removeChild(l),t}function Kg(t,e,l,n,a){if(e==="submit"&&l&&l.stateNode===a){var i=ld((a[ne]||null).action),f=n.submitter;f&&(e=(e=f[ne]||null)?ld(e.formAction):f.getAttribute("formAction"),e!==null&&(i=e,f=null));var o=new xi("action","action",null,n,a);t.push({event:o,listeners:[{instance:null,listener:function(){if(n.defaultPrevented){if(Nl!==0){var m=f?nd(a,f):new FormData(a);sc(l,{pending:!0,data:m,method:a.method,action:i},null,m)}}else typeof i=="function"&&(o.preventDefault(),m=f?nd(a,f):new FormData(a),sc(l,{pending:!0,data:m,method:a.method,action:i},i,m))},currentTarget:a}]})}}for(var Gc=0;Gc<_s.length;Gc++){var Qc=_s[Gc],Vg=Qc.toLowerCase(),Zg=Qc[0].toUpperCase()+Qc.slice(1);Ne(Vg,"on"+Zg)}Ne(wf,"onAnimationEnd"),Ne(Hf,"onAnimationIteration"),Ne(Nf,"onAnimationStart"),Ne("dblclick","onDoubleClick"),Ne("focusin","onFocus"),Ne("focusout","onBlur"),Ne(cg,"onTransitionRun"),Ne(rg,"onTransitionStart"),Ne(fg,"onTransitionCancel"),Ne(Bf,"onTransitionEnd"),Sn("onMouseEnter",["mouseout","mouseover"]),Sn("onMouseLeave",["mouseout","mouseover"]),Sn("onPointerEnter",["pointerout","pointerover"]),Sn("onPointerLeave",["pointerout","pointerover"]),Wl("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),Wl("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),Wl("onBeforeInput",["compositionend","keypress","textInput","paste"]),Wl("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),Wl("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),Wl("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Va="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(" "),Jg=new Set("beforetoggle cancel close invalid load scroll scrollend toggle".split(" ").concat(Va));function ad(t,e){e=(e&4)!==0;for(var l=0;l<t.length;l++){var n=t[l],a=n.event;n=n.listeners;t:{var i=void 0;if(e)for(var f=n.length-1;0<=f;f--){var o=n[f],m=o.instance,A=o.currentTarget;if(o=o.listener,m!==i&&a.isPropagationStopped())break t;i=o,a.currentTarget=A;try{i(a)}catch(M){Ci(M)}a.currentTarget=null,i=m}else for(f=0;f<n.length;f++){if(o=n[f],m=o.instance,A=o.currentTarget,o=o.listener,m!==i&&a.isPropagationStopped())break t;i=o,a.currentTarget=A;try{i(a)}catch(M){Ci(M)}a.currentTarget=null,i=m}}}}function P(t,e){var l=e[ls];l===void 0&&(l=e[ls]=new Set);var n=t+"__bubble";l.has(n)||(id(e,t,2,!1),l.add(n))}function Kc(t,e,l){var n=0;e&&(n|=4),id(l,t,n,e)}var mu="_reactListening"+Math.random().toString(36).slice(2);function Vc(t){if(!t[mu]){t[mu]=!0,$r.forEach(function(l){l!=="selectionchange"&&(Jg.has(l)||Kc(l,!1,t),Kc(l,!0,t))});var e=t.nodeType===9?t:t.ownerDocument;e===null||e[mu]||(e[mu]=!0,Kc("selectionchange",!1,e))}}function id(t,e,l,n){switch(Hd(e)){case 2:var a=Ep;break;case 8:a=Tp;break;default:a=ur}l=a.bind(null,e,l,t),a=void 0,!os||e!=="touchstart"&&e!=="touchmove"&&e!=="wheel"||(a=!0),n?a!==void 0?t.addEventListener(e,l,{capture:!0,passive:a}):t.addEventListener(e,l,!0):a!==void 0?t.addEventListener(e,l,{passive:a}):t.addEventListener(e,l,!1)}function Zc(t,e,l,n,a){var i=n;if((e&1)===0&&(e&2)===0&&n!==null)t:for(;;){if(n===null)return;var f=n.tag;if(f===3||f===4){var o=n.stateNode.containerInfo;if(o===a)break;if(f===4)for(f=n.return;f!==null;){var m=f.tag;if((m===3||m===4)&&f.stateNode.containerInfo===a)return;f=f.return}for(;o!==null;){if(f=gn(o),f===null)return;if(m=f.tag,m===5||m===6||m===26||m===27){n=i=f;continue t}o=o.parentNode}}n=n.return}rf(function(){var A=i,M=rs(l),O=[];t:{var _=Lf.get(t);if(_!==void 0){var x=xi,B=t;switch(t){case"keypress":if(Ai(l)===0)break t;case"keydown":case"keyup":x=Yy;break;case"focusin":B="focus",x=ys;break;case"focusout":B="blur",x=ys;break;case"beforeblur":case"afterblur":x=ys;break;case"click":if(l.button===2)break t;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":x=hf;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":x=Cy;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":x=Qy;break;case wf:case Hf:case Nf:x=Ry;break;case Bf:x=Vy;break;case"scroll":case"scrollend":x=My;break;case"wheel":x=Jy;break;case"copy":case"cut":case"paste":x=wy;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":x=mf;break;case"toggle":case"beforetoggle":x=Wy}var Y=(e&4)!==0,mt=!Y&&(t==="scroll"||t==="scrollend"),S=Y?_!==null?_+"Capture":null:_;Y=[];for(var g=A,T;g!==null;){var C=g;if(T=C.stateNode,C=C.tag,C!==5&&C!==26&&C!==27||T===null||S===null||(C=da(g,S),C!=null&&Y.push(Za(g,C,T))),mt)break;g=g.return}0<Y.length&&(_=new x(_,B,null,l,M),O.push({event:_,listeners:Y}))}}if((e&7)===0){t:{if(_=t==="mouseover"||t==="pointerover",x=t==="mouseout"||t==="pointerout",_&&l!==cs&&(B=l.relatedTarget||l.fromElement)&&(gn(B)||B[yn]))break t;if((x||_)&&(_=M.window===M?M:(_=M.ownerDocument)?_.defaultView||_.parentWindow:window,x?(B=l.relatedTarget||l.toElement,x=A,B=B?gn(B):null,B!==null&&(mt=d(B),Y=B.tag,B!==mt||Y!==5&&Y!==27&&Y!==6)&&(B=null)):(x=null,B=A),x!==B)){if(Y=hf,C="onMouseLeave",S="onMouseEnter",g="mouse",(t==="pointerout"||t==="pointerover")&&(Y=mf,C="onPointerLeave",S="onPointerEnter",g="pointer"),mt=x==null?_:ha(x),T=B==null?_:ha(B),_=new Y(C,g+"leave",x,l,M),_.target=mt,_.relatedTarget=T,C=null,gn(M)===A&&(Y=new Y(S,g+"enter",B,l,M),Y.target=T,Y.relatedTarget=mt,C=Y),mt=C,x&&B)e:{for(Y=kg,S=x,g=B,T=0,C=S;C;C=Y(C))T++;C=0;for(var q=g;q;q=Y(q))C++;for(;0<T-C;)S=Y(S),T--;for(;0<C-T;)g=Y(g),C--;for(;T--;){if(S===g||g!==null&&S===g.alternate){Y=S;break e}S=Y(S),g=Y(g)}Y=null}else Y=null;x!==null&&ud(O,_,x,Y,!1),B!==null&&mt!==null&&ud(O,mt,B,Y,!0)}}t:{if(_=A?ha(A):window,x=_.nodeName&&_.nodeName.toLowerCase(),x==="select"||x==="input"&&_.type==="file")var nt=Tf;else if(bf(_))if(Af)nt=ig;else{nt=ng;var j=lg}else x=_.nodeName,!x||x.toLowerCase()!=="input"||_.type!=="checkbox"&&_.type!=="radio"?A&&ss(A.elementType)&&(nt=Tf):nt=ag;if(nt&&(nt=nt(t,A))){Ef(O,nt,l,M);break t}j&&j(t,_,A),t==="focusout"&&A&&_.type==="number"&&A.memoizedProps.value!=null&&us(_,"number",_.value)}switch(j=A?ha(A):window,t){case"focusin":(bf(j)||j.contentEditable==="true")&&(xn=j,Es=A,Ea=null);break;case"focusout":Ea=Es=xn=null;break;case"mousedown":Ts=!0;break;case"contextmenu":case"mouseup":case"dragend":Ts=!1,Rf(O,l,M);break;case"selectionchange":if(sg)break;case"keydown":case"keyup":Rf(O,l,M)}var k;if(ps)t:{switch(t){case"compositionstart":var et="onCompositionStart";break t;case"compositionend":et="onCompositionEnd";break t;case"compositionupdate":et="onCompositionUpdate";break t}et=void 0}else _n?vf(t,l)&&(et="onCompositionEnd"):t==="keydown"&&l.keyCode===229&&(et="onCompositionStart");et&&(yf&&l.locale!=="ko"&&(_n||et!=="onCompositionStart"?et==="onCompositionEnd"&&_n&&(k=ff()):(Sl=M,hs="value"in Sl?Sl.value:Sl.textContent,_n=!0)),j=yu(A,et),0<j.length&&(et=new df(et,t,null,l,M),O.push({event:et,listeners:j}),k?et.data=k:(k=Sf(l),k!==null&&(et.data=k)))),(k=Fy?Iy(t,l):Py(t,l))&&(et=yu(A,"onBeforeInput"),0<et.length&&(j=new df("onBeforeInput","beforeinput",null,l,M),O.push({event:j,listeners:et}),j.data=k)),Kg(O,t,A,l,M)}ad(O,e)})}function Za(t,e,l){return{instance:t,listener:e,currentTarget:l}}function yu(t,e){for(var l=e+"Capture",n=[];t!==null;){var a=t,i=a.stateNode;if(a=a.tag,a!==5&&a!==26&&a!==27||i===null||(a=da(t,l),a!=null&&n.unshift(Za(t,a,i)),a=da(t,e),a!=null&&n.push(Za(t,a,i))),t.tag===3)return n;t=t.return}return[]}function kg(t){if(t===null)return null;do t=t.return;while(t&&t.tag!==5&&t.tag!==27);return t||null}function ud(t,e,l,n,a){for(var i=e._reactName,f=[];l!==null&&l!==n;){var o=l,m=o.alternate,A=o.stateNode;if(o=o.tag,m!==null&&m===n)break;o!==5&&o!==26&&o!==27||A===null||(m=A,a?(A=da(l,i),A!=null&&f.unshift(Za(l,A,m))):a||(A=da(l,i),A!=null&&f.push(Za(l,A,m)))),l=l.return}f.length!==0&&t.push({event:e,listeners:f})}var Wg=/\r\n?/g,$g=/\u0000|\uFFFD/g;function sd(t){return(typeof t=="string"?t:""+t).replace(Wg,`
|
|
49
|
-
`).replace($g,"")}function cd(t,e){return e=sd(e),sd(t)===e}function dt(t,e,l,n,a,i){switch(l){case"children":typeof n=="string"?e==="body"||e==="textarea"&&n===""||En(t,n):(typeof n=="number"||typeof n=="bigint")&&e!=="body"&&En(t,""+n);break;case"className":Si(t,"class",n);break;case"tabIndex":Si(t,"tabindex",n);break;case"dir":case"role":case"viewBox":case"width":case"height":Si(t,l,n);break;case"style":sf(t,n,i);break;case"data":if(e!=="object"){Si(t,"data",n);break}case"src":case"href":if(n===""&&(e!=="a"||l!=="href")){t.removeAttribute(l);break}if(n==null||typeof n=="function"||typeof n=="symbol"||typeof n=="boolean"){t.removeAttribute(l);break}n=Ei(""+n),t.setAttribute(l,n);break;case"action":case"formAction":if(typeof n=="function"){t.setAttribute(l,"javascript:throw new Error('A React form was unexpectedly submitted. If you called form.submit() manually, consider using form.requestSubmit() instead. If you\\'re trying to use event.stopPropagation() in a submit event handler, consider also calling event.preventDefault().')");break}else typeof i=="function"&&(l==="formAction"?(e!=="input"&&dt(t,e,"name",a.name,a,null),dt(t,e,"formEncType",a.formEncType,a,null),dt(t,e,"formMethod",a.formMethod,a,null),dt(t,e,"formTarget",a.formTarget,a,null)):(dt(t,e,"encType",a.encType,a,null),dt(t,e,"method",a.method,a,null),dt(t,e,"target",a.target,a,null)));if(n==null||typeof n=="symbol"||typeof n=="boolean"){t.removeAttribute(l);break}n=Ei(""+n),t.setAttribute(l,n);break;case"onClick":n!=null&&(t.onclick=Fe);break;case"onScroll":n!=null&&P("scroll",t);break;case"onScrollEnd":n!=null&&P("scrollend",t);break;case"dangerouslySetInnerHTML":if(n!=null){if(typeof n!="object"||!("__html"in n))throw Error(c(61));if(l=n.__html,l!=null){if(a.children!=null)throw Error(c(60));t.innerHTML=l}}break;case"multiple":t.multiple=n&&typeof n!="function"&&typeof n!="symbol";break;case"muted":t.muted=n&&typeof n!="function"&&typeof n!="symbol";break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":break;case"autoFocus":break;case"xlinkHref":if(n==null||typeof n=="function"||typeof n=="boolean"||typeof n=="symbol"){t.removeAttribute("xlink:href");break}l=Ei(""+n),t.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",l);break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":n!=null&&typeof n!="function"&&typeof n!="symbol"?t.setAttribute(l,""+n):t.removeAttribute(l);break;case"inert":case"allowFullScreen":case"async":case"autoPlay":case"controls":case"default":case"defer":case"disabled":case"disablePictureInPicture":case"disableRemotePlayback":case"formNoValidate":case"hidden":case"loop":case"noModule":case"noValidate":case"open":case"playsInline":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"itemScope":n&&typeof n!="function"&&typeof n!="symbol"?t.setAttribute(l,""):t.removeAttribute(l);break;case"capture":case"download":n===!0?t.setAttribute(l,""):n!==!1&&n!=null&&typeof n!="function"&&typeof n!="symbol"?t.setAttribute(l,n):t.removeAttribute(l);break;case"cols":case"rows":case"size":case"span":n!=null&&typeof n!="function"&&typeof n!="symbol"&&!isNaN(n)&&1<=n?t.setAttribute(l,n):t.removeAttribute(l);break;case"rowSpan":case"start":n==null||typeof n=="function"||typeof n=="symbol"||isNaN(n)?t.removeAttribute(l):t.setAttribute(l,n);break;case"popover":P("beforetoggle",t),P("toggle",t),vi(t,"popover",n);break;case"xlinkActuate":$e(t,"http://www.w3.org/1999/xlink","xlink:actuate",n);break;case"xlinkArcrole":$e(t,"http://www.w3.org/1999/xlink","xlink:arcrole",n);break;case"xlinkRole":$e(t,"http://www.w3.org/1999/xlink","xlink:role",n);break;case"xlinkShow":$e(t,"http://www.w3.org/1999/xlink","xlink:show",n);break;case"xlinkTitle":$e(t,"http://www.w3.org/1999/xlink","xlink:title",n);break;case"xlinkType":$e(t,"http://www.w3.org/1999/xlink","xlink:type",n);break;case"xmlBase":$e(t,"http://www.w3.org/XML/1998/namespace","xml:base",n);break;case"xmlLang":$e(t,"http://www.w3.org/XML/1998/namespace","xml:lang",n);break;case"xmlSpace":$e(t,"http://www.w3.org/XML/1998/namespace","xml:space",n);break;case"is":vi(t,"is",n);break;case"innerText":case"textContent":break;default:(!(2<l.length)||l[0]!=="o"&&l[0]!=="O"||l[1]!=="n"&&l[1]!=="N")&&(l=_y.get(l)||l,vi(t,l,n))}}function Jc(t,e,l,n,a,i){switch(l){case"style":sf(t,n,i);break;case"dangerouslySetInnerHTML":if(n!=null){if(typeof n!="object"||!("__html"in n))throw Error(c(61));if(l=n.__html,l!=null){if(a.children!=null)throw Error(c(60));t.innerHTML=l}}break;case"children":typeof n=="string"?En(t,n):(typeof n=="number"||typeof n=="bigint")&&En(t,""+n);break;case"onScroll":n!=null&&P("scroll",t);break;case"onScrollEnd":n!=null&&P("scrollend",t);break;case"onClick":n!=null&&(t.onclick=Fe);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"innerHTML":case"ref":break;case"innerText":case"textContent":break;default:if(!Fr.hasOwnProperty(l))t:{if(l[0]==="o"&&l[1]==="n"&&(a=l.endsWith("Capture"),e=l.slice(2,a?l.length-7:void 0),i=t[ne]||null,i=i!=null?i[l]:null,typeof i=="function"&&t.removeEventListener(e,i,a),typeof n=="function")){typeof i!="function"&&i!==null&&(l in t?t[l]=null:t.hasAttribute(l)&&t.removeAttribute(l)),t.addEventListener(e,n,a);break t}l in t?t[l]=n:n===!0?t.setAttribute(l,""):vi(t,l,n)}}}function kt(t,e,l){switch(e){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"img":P("error",t),P("load",t);var n=!1,a=!1,i;for(i in l)if(l.hasOwnProperty(i)){var f=l[i];if(f!=null)switch(i){case"src":n=!0;break;case"srcSet":a=!0;break;case"children":case"dangerouslySetInnerHTML":throw Error(c(137,e));default:dt(t,e,i,f,l,null)}}a&&dt(t,e,"srcSet",l.srcSet,l,null),n&&dt(t,e,"src",l.src,l,null);return;case"input":P("invalid",t);var o=i=f=a=null,m=null,A=null;for(n in l)if(l.hasOwnProperty(n)){var M=l[n];if(M!=null)switch(n){case"name":a=M;break;case"type":f=M;break;case"checked":m=M;break;case"defaultChecked":A=M;break;case"value":i=M;break;case"defaultValue":o=M;break;case"children":case"dangerouslySetInnerHTML":if(M!=null)throw Error(c(137,e));break;default:dt(t,e,n,M,l,null)}}lf(t,i,o,m,A,f,a,!1);return;case"select":P("invalid",t),n=f=i=null;for(a in l)if(l.hasOwnProperty(a)&&(o=l[a],o!=null))switch(a){case"value":i=o;break;case"defaultValue":f=o;break;case"multiple":n=o;default:dt(t,e,a,o,l,null)}e=i,l=f,t.multiple=!!n,e!=null?bn(t,!!n,e,!1):l!=null&&bn(t,!!n,l,!0);return;case"textarea":P("invalid",t),i=a=n=null;for(f in l)if(l.hasOwnProperty(f)&&(o=l[f],o!=null))switch(f){case"value":n=o;break;case"defaultValue":a=o;break;case"children":i=o;break;case"dangerouslySetInnerHTML":if(o!=null)throw Error(c(91));break;default:dt(t,e,f,o,l,null)}af(t,n,a,i);return;case"option":for(m in l)if(l.hasOwnProperty(m)&&(n=l[m],n!=null))switch(m){case"selected":t.selected=n&&typeof n!="function"&&typeof n!="symbol";break;default:dt(t,e,m,n,l,null)}return;case"dialog":P("beforetoggle",t),P("toggle",t),P("cancel",t),P("close",t);break;case"iframe":case"object":P("load",t);break;case"video":case"audio":for(n=0;n<Va.length;n++)P(Va[n],t);break;case"image":P("error",t),P("load",t);break;case"details":P("toggle",t);break;case"embed":case"source":case"link":P("error",t),P("load",t);case"area":case"base":case"br":case"col":case"hr":case"keygen":case"meta":case"param":case"track":case"wbr":case"menuitem":for(A in l)if(l.hasOwnProperty(A)&&(n=l[A],n!=null))switch(A){case"children":case"dangerouslySetInnerHTML":throw Error(c(137,e));default:dt(t,e,A,n,l,null)}return;default:if(ss(e)){for(M in l)l.hasOwnProperty(M)&&(n=l[M],n!==void 0&&Jc(t,e,M,n,l,void 0));return}}for(o in l)l.hasOwnProperty(o)&&(n=l[o],n!=null&&dt(t,e,o,n,l,null))}function Fg(t,e,l,n){switch(e){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"input":var a=null,i=null,f=null,o=null,m=null,A=null,M=null;for(x in l){var O=l[x];if(l.hasOwnProperty(x)&&O!=null)switch(x){case"checked":break;case"value":break;case"defaultValue":m=O;default:n.hasOwnProperty(x)||dt(t,e,x,null,n,O)}}for(var _ in n){var x=n[_];if(O=l[_],n.hasOwnProperty(_)&&(x!=null||O!=null))switch(_){case"type":i=x;break;case"name":a=x;break;case"checked":A=x;break;case"defaultChecked":M=x;break;case"value":f=x;break;case"defaultValue":o=x;break;case"children":case"dangerouslySetInnerHTML":if(x!=null)throw Error(c(137,e));break;default:x!==O&&dt(t,e,_,x,n,O)}}is(t,f,o,m,A,M,i,a);return;case"select":x=f=o=_=null;for(i in l)if(m=l[i],l.hasOwnProperty(i)&&m!=null)switch(i){case"value":break;case"multiple":x=m;default:n.hasOwnProperty(i)||dt(t,e,i,null,n,m)}for(a in n)if(i=n[a],m=l[a],n.hasOwnProperty(a)&&(i!=null||m!=null))switch(a){case"value":_=i;break;case"defaultValue":o=i;break;case"multiple":f=i;default:i!==m&&dt(t,e,a,i,n,m)}e=o,l=f,n=x,_!=null?bn(t,!!l,_,!1):!!n!=!!l&&(e!=null?bn(t,!!l,e,!0):bn(t,!!l,l?[]:"",!1));return;case"textarea":x=_=null;for(o in l)if(a=l[o],l.hasOwnProperty(o)&&a!=null&&!n.hasOwnProperty(o))switch(o){case"value":break;case"children":break;default:dt(t,e,o,null,n,a)}for(f in n)if(a=n[f],i=l[f],n.hasOwnProperty(f)&&(a!=null||i!=null))switch(f){case"value":_=a;break;case"defaultValue":x=a;break;case"children":break;case"dangerouslySetInnerHTML":if(a!=null)throw Error(c(91));break;default:a!==i&&dt(t,e,f,a,n,i)}nf(t,_,x);return;case"option":for(var B in l)if(_=l[B],l.hasOwnProperty(B)&&_!=null&&!n.hasOwnProperty(B))switch(B){case"selected":t.selected=!1;break;default:dt(t,e,B,null,n,_)}for(m in n)if(_=n[m],x=l[m],n.hasOwnProperty(m)&&_!==x&&(_!=null||x!=null))switch(m){case"selected":t.selected=_&&typeof _!="function"&&typeof _!="symbol";break;default:dt(t,e,m,_,n,x)}return;case"img":case"link":case"area":case"base":case"br":case"col":case"embed":case"hr":case"keygen":case"meta":case"param":case"source":case"track":case"wbr":case"menuitem":for(var Y in l)_=l[Y],l.hasOwnProperty(Y)&&_!=null&&!n.hasOwnProperty(Y)&&dt(t,e,Y,null,n,_);for(A in n)if(_=n[A],x=l[A],n.hasOwnProperty(A)&&_!==x&&(_!=null||x!=null))switch(A){case"children":case"dangerouslySetInnerHTML":if(_!=null)throw Error(c(137,e));break;default:dt(t,e,A,_,n,x)}return;default:if(ss(e)){for(var mt in l)_=l[mt],l.hasOwnProperty(mt)&&_!==void 0&&!n.hasOwnProperty(mt)&&Jc(t,e,mt,void 0,n,_);for(M in n)_=n[M],x=l[M],!n.hasOwnProperty(M)||_===x||_===void 0&&x===void 0||Jc(t,e,M,_,n,x);return}}for(var S in l)_=l[S],l.hasOwnProperty(S)&&_!=null&&!n.hasOwnProperty(S)&&dt(t,e,S,null,n,_);for(O in n)_=n[O],x=l[O],!n.hasOwnProperty(O)||_===x||_==null&&x==null||dt(t,e,O,_,n,x)}function rd(t){switch(t){case"css":case"script":case"font":case"img":case"image":case"input":case"link":return!0;default:return!1}}function Ig(){if(typeof performance.getEntriesByType=="function"){for(var t=0,e=0,l=performance.getEntriesByType("resource"),n=0;n<l.length;n++){var a=l[n],i=a.transferSize,f=a.initiatorType,o=a.duration;if(i&&o&&rd(f)){for(f=0,o=a.responseEnd,n+=1;n<l.length;n++){var m=l[n],A=m.startTime;if(A>o)break;var M=m.transferSize,O=m.initiatorType;M&&rd(O)&&(m=m.responseEnd,f+=M*(m<o?1:(o-A)/(m-A)))}if(--n,e+=8*(i+f)/(a.duration/1e3),t++,10<t)break}}if(0<t)return e/t/1e6}return navigator.connection&&(t=navigator.connection.downlink,typeof t=="number")?t:5}var kc=null,Wc=null;function gu(t){return t.nodeType===9?t:t.ownerDocument}function fd(t){switch(t){case"http://www.w3.org/2000/svg":return 1;case"http://www.w3.org/1998/Math/MathML":return 2;default:return 0}}function od(t,e){if(t===0)switch(e){case"svg":return 1;case"math":return 2;default:return 0}return t===1&&e==="foreignObject"?0:t}function $c(t,e){return t==="textarea"||t==="noscript"||typeof e.children=="string"||typeof e.children=="number"||typeof e.children=="bigint"||typeof e.dangerouslySetInnerHTML=="object"&&e.dangerouslySetInnerHTML!==null&&e.dangerouslySetInnerHTML.__html!=null}var Fc=null;function Pg(){var t=window.event;return t&&t.type==="popstate"?t===Fc?!1:(Fc=t,!0):(Fc=null,!1)}var hd=typeof setTimeout=="function"?setTimeout:void 0,tp=typeof clearTimeout=="function"?clearTimeout:void 0,dd=typeof Promise=="function"?Promise:void 0,ep=typeof queueMicrotask=="function"?queueMicrotask:typeof dd<"u"?function(t){return dd.resolve(null).then(t).catch(lp)}:hd;function lp(t){setTimeout(function(){throw t})}function Bl(t){return t==="head"}function md(t,e){var l=e,n=0;do{var a=l.nextSibling;if(t.removeChild(l),a&&a.nodeType===8)if(l=a.data,l==="/$"||l==="/&"){if(n===0){t.removeChild(a),In(e);return}n--}else if(l==="$"||l==="$?"||l==="$~"||l==="$!"||l==="&")n++;else if(l==="html")Ja(t.ownerDocument.documentElement);else if(l==="head"){l=t.ownerDocument.head,Ja(l);for(var i=l.firstChild;i;){var f=i.nextSibling,o=i.nodeName;i[oa]||o==="SCRIPT"||o==="STYLE"||o==="LINK"&&i.rel.toLowerCase()==="stylesheet"||l.removeChild(i),i=f}}else l==="body"&&Ja(t.ownerDocument.body);l=a}while(l);In(e)}function yd(t,e){var l=t;t=0;do{var n=l.nextSibling;if(l.nodeType===1?e?(l._stashedDisplay=l.style.display,l.style.display="none"):(l.style.display=l._stashedDisplay||"",l.getAttribute("style")===""&&l.removeAttribute("style")):l.nodeType===3&&(e?(l._stashedText=l.nodeValue,l.nodeValue=""):l.nodeValue=l._stashedText||""),n&&n.nodeType===8)if(l=n.data,l==="/$"){if(t===0)break;t--}else l!=="$"&&l!=="$?"&&l!=="$~"&&l!=="$!"||t++;l=n}while(l)}function Ic(t){var e=t.firstChild;for(e&&e.nodeType===10&&(e=e.nextSibling);e;){var l=e;switch(e=e.nextSibling,l.nodeName){case"HTML":case"HEAD":case"BODY":Ic(l),ns(l);continue;case"SCRIPT":case"STYLE":continue;case"LINK":if(l.rel.toLowerCase()==="stylesheet")continue}t.removeChild(l)}}function np(t,e,l,n){for(;t.nodeType===1;){var a=l;if(t.nodeName.toLowerCase()!==e.toLowerCase()){if(!n&&(t.nodeName!=="INPUT"||t.type!=="hidden"))break}else if(n){if(!t[oa])switch(e){case"meta":if(!t.hasAttribute("itemprop"))break;return t;case"link":if(i=t.getAttribute("rel"),i==="stylesheet"&&t.hasAttribute("data-precedence"))break;if(i!==a.rel||t.getAttribute("href")!==(a.href==null||a.href===""?null:a.href)||t.getAttribute("crossorigin")!==(a.crossOrigin==null?null:a.crossOrigin)||t.getAttribute("title")!==(a.title==null?null:a.title))break;return t;case"style":if(t.hasAttribute("data-precedence"))break;return t;case"script":if(i=t.getAttribute("src"),(i!==(a.src==null?null:a.src)||t.getAttribute("type")!==(a.type==null?null:a.type)||t.getAttribute("crossorigin")!==(a.crossOrigin==null?null:a.crossOrigin))&&i&&t.hasAttribute("async")&&!t.hasAttribute("itemprop"))break;return t;default:return t}}else if(e==="input"&&t.type==="hidden"){var i=a.name==null?null:""+a.name;if(a.type==="hidden"&&t.getAttribute("name")===i)return t}else return t;if(t=De(t.nextSibling),t===null)break}return null}function ap(t,e,l){if(e==="")return null;for(;t.nodeType!==3;)if((t.nodeType!==1||t.nodeName!=="INPUT"||t.type!=="hidden")&&!l||(t=De(t.nextSibling),t===null))return null;return t}function gd(t,e){for(;t.nodeType!==8;)if((t.nodeType!==1||t.nodeName!=="INPUT"||t.type!=="hidden")&&!e||(t=De(t.nextSibling),t===null))return null;return t}function Pc(t){return t.data==="$?"||t.data==="$~"}function tr(t){return t.data==="$!"||t.data==="$?"&&t.ownerDocument.readyState!=="loading"}function ip(t,e){var l=t.ownerDocument;if(t.data==="$~")t._reactRetry=e;else if(t.data!=="$?"||l.readyState!=="loading")e();else{var n=function(){e(),l.removeEventListener("DOMContentLoaded",n)};l.addEventListener("DOMContentLoaded",n),t._reactRetry=n}}function De(t){for(;t!=null;t=t.nextSibling){var e=t.nodeType;if(e===1||e===3)break;if(e===8){if(e=t.data,e==="$"||e==="$!"||e==="$?"||e==="$~"||e==="&"||e==="F!"||e==="F")break;if(e==="/$"||e==="/&")return null}}return t}var er=null;function pd(t){t=t.nextSibling;for(var e=0;t;){if(t.nodeType===8){var l=t.data;if(l==="/$"||l==="/&"){if(e===0)return De(t.nextSibling);e--}else l!=="$"&&l!=="$!"&&l!=="$?"&&l!=="$~"&&l!=="&"||e++}t=t.nextSibling}return null}function vd(t){t=t.previousSibling;for(var e=0;t;){if(t.nodeType===8){var l=t.data;if(l==="$"||l==="$!"||l==="$?"||l==="$~"||l==="&"){if(e===0)return t;e--}else l!=="/$"&&l!=="/&"||e++}t=t.previousSibling}return null}function Sd(t,e,l){switch(e=gu(l),t){case"html":if(t=e.documentElement,!t)throw Error(c(452));return t;case"head":if(t=e.head,!t)throw Error(c(453));return t;case"body":if(t=e.body,!t)throw Error(c(454));return t;default:throw Error(c(451))}}function Ja(t){for(var e=t.attributes;e.length;)t.removeAttributeNode(e[0]);ns(t)}var Re=new Map,bd=new Set;function pu(t){return typeof t.getRootNode=="function"?t.getRootNode():t.nodeType===9?t:t.ownerDocument}var dl=w.d;w.d={f:up,r:sp,D:cp,C:rp,L:fp,m:op,X:dp,S:hp,M:mp};function up(){var t=dl.f(),e=cu();return t||e}function sp(t){var e=pn(t);e!==null&&e.tag===5&&e.type==="form"?Lo(e):dl.r(t)}var Wn=typeof document>"u"?null:document;function Ed(t,e,l){var n=Wn;if(n&&typeof e=="string"&&e){var a=Ae(e);a='link[rel="'+t+'"][href="'+a+'"]',typeof l=="string"&&(a+='[crossorigin="'+l+'"]'),bd.has(a)||(bd.add(a),t={rel:t,crossOrigin:l,href:e},n.querySelector(a)===null&&(e=n.createElement("link"),kt(e,"link",t),Xt(e),n.head.appendChild(e)))}}function cp(t){dl.D(t),Ed("dns-prefetch",t,null)}function rp(t,e){dl.C(t,e),Ed("preconnect",t,e)}function fp(t,e,l){dl.L(t,e,l);var n=Wn;if(n&&t&&e){var a='link[rel="preload"][as="'+Ae(e)+'"]';e==="image"&&l&&l.imageSrcSet?(a+='[imagesrcset="'+Ae(l.imageSrcSet)+'"]',typeof l.imageSizes=="string"&&(a+='[imagesizes="'+Ae(l.imageSizes)+'"]')):a+='[href="'+Ae(t)+'"]';var i=a;switch(e){case"style":i=$n(t);break;case"script":i=Fn(t)}Re.has(i)||(t=U({rel:"preload",href:e==="image"&&l&&l.imageSrcSet?void 0:t,as:e},l),Re.set(i,t),n.querySelector(a)!==null||e==="style"&&n.querySelector(ka(i))||e==="script"&&n.querySelector(Wa(i))||(e=n.createElement("link"),kt(e,"link",t),Xt(e),n.head.appendChild(e)))}}function op(t,e){dl.m(t,e);var l=Wn;if(l&&t){var n=e&&typeof e.as=="string"?e.as:"script",a='link[rel="modulepreload"][as="'+Ae(n)+'"][href="'+Ae(t)+'"]',i=a;switch(n){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":i=Fn(t)}if(!Re.has(i)&&(t=U({rel:"modulepreload",href:t},e),Re.set(i,t),l.querySelector(a)===null)){switch(n){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(l.querySelector(Wa(i)))return}n=l.createElement("link"),kt(n,"link",t),Xt(n),l.head.appendChild(n)}}}function hp(t,e,l){dl.S(t,e,l);var n=Wn;if(n&&t){var a=vn(n).hoistableStyles,i=$n(t);e=e||"default";var f=a.get(i);if(!f){var o={loading:0,preload:null};if(f=n.querySelector(ka(i)))o.loading=5;else{t=U({rel:"stylesheet",href:t,"data-precedence":e},l),(l=Re.get(i))&&lr(t,l);var m=f=n.createElement("link");Xt(m),kt(m,"link",t),m._p=new Promise(function(A,M){m.onload=A,m.onerror=M}),m.addEventListener("load",function(){o.loading|=1}),m.addEventListener("error",function(){o.loading|=2}),o.loading|=4,vu(f,e,n)}f={type:"stylesheet",instance:f,count:1,state:o},a.set(i,f)}}}function dp(t,e){dl.X(t,e);var l=Wn;if(l&&t){var n=vn(l).hoistableScripts,a=Fn(t),i=n.get(a);i||(i=l.querySelector(Wa(a)),i||(t=U({src:t,async:!0},e),(e=Re.get(a))&&nr(t,e),i=l.createElement("script"),Xt(i),kt(i,"link",t),l.head.appendChild(i)),i={type:"script",instance:i,count:1,state:null},n.set(a,i))}}function mp(t,e){dl.M(t,e);var l=Wn;if(l&&t){var n=vn(l).hoistableScripts,a=Fn(t),i=n.get(a);i||(i=l.querySelector(Wa(a)),i||(t=U({src:t,async:!0,type:"module"},e),(e=Re.get(a))&&nr(t,e),i=l.createElement("script"),Xt(i),kt(i,"link",t),l.head.appendChild(i)),i={type:"script",instance:i,count:1,state:null},n.set(a,i))}}function Td(t,e,l,n){var a=(a=F.current)?pu(a):null;if(!a)throw Error(c(446));switch(t){case"meta":case"title":return null;case"style":return typeof l.precedence=="string"&&typeof l.href=="string"?(e=$n(l.href),l=vn(a).hoistableStyles,n=l.get(e),n||(n={type:"style",instance:null,count:0,state:null},l.set(e,n)),n):{type:"void",instance:null,count:0,state:null};case"link":if(l.rel==="stylesheet"&&typeof l.href=="string"&&typeof l.precedence=="string"){t=$n(l.href);var i=vn(a).hoistableStyles,f=i.get(t);if(f||(a=a.ownerDocument||a,f={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},i.set(t,f),(i=a.querySelector(ka(t)))&&!i._p&&(f.instance=i,f.state.loading=5),Re.has(t)||(l={rel:"preload",as:"style",href:l.href,crossOrigin:l.crossOrigin,integrity:l.integrity,media:l.media,hrefLang:l.hrefLang,referrerPolicy:l.referrerPolicy},Re.set(t,l),i||yp(a,t,l,f.state))),e&&n===null)throw Error(c(528,""));return f}if(e&&n!==null)throw Error(c(529,""));return null;case"script":return e=l.async,l=l.src,typeof l=="string"&&e&&typeof e!="function"&&typeof e!="symbol"?(e=Fn(l),l=vn(a).hoistableScripts,n=l.get(e),n||(n={type:"script",instance:null,count:0,state:null},l.set(e,n)),n):{type:"void",instance:null,count:0,state:null};default:throw Error(c(444,t))}}function $n(t){return'href="'+Ae(t)+'"'}function ka(t){return'link[rel="stylesheet"]['+t+"]"}function Ad(t){return U({},t,{"data-precedence":t.precedence,precedence:null})}function yp(t,e,l,n){t.querySelector('link[rel="preload"][as="style"]['+e+"]")?n.loading=1:(e=t.createElement("link"),n.preload=e,e.addEventListener("load",function(){return n.loading|=1}),e.addEventListener("error",function(){return n.loading|=2}),kt(e,"link",l),Xt(e),t.head.appendChild(e))}function Fn(t){return'[src="'+Ae(t)+'"]'}function Wa(t){return"script[async]"+t}function _d(t,e,l){if(e.count++,e.instance===null)switch(e.type){case"style":var n=t.querySelector('style[data-href~="'+Ae(l.href)+'"]');if(n)return e.instance=n,Xt(n),n;var a=U({},l,{"data-href":l.href,"data-precedence":l.precedence,href:null,precedence:null});return n=(t.ownerDocument||t).createElement("style"),Xt(n),kt(n,"style",a),vu(n,l.precedence,t),e.instance=n;case"stylesheet":a=$n(l.href);var i=t.querySelector(ka(a));if(i)return e.state.loading|=4,e.instance=i,Xt(i),i;n=Ad(l),(a=Re.get(a))&&lr(n,a),i=(t.ownerDocument||t).createElement("link"),Xt(i);var f=i;return f._p=new Promise(function(o,m){f.onload=o,f.onerror=m}),kt(i,"link",n),e.state.loading|=4,vu(i,l.precedence,t),e.instance=i;case"script":return i=Fn(l.src),(a=t.querySelector(Wa(i)))?(e.instance=a,Xt(a),a):(n=l,(a=Re.get(i))&&(n=U({},l),nr(n,a)),t=t.ownerDocument||t,a=t.createElement("script"),Xt(a),kt(a,"link",n),t.head.appendChild(a),e.instance=a);case"void":return null;default:throw Error(c(443,e.type))}else e.type==="stylesheet"&&(e.state.loading&4)===0&&(n=e.instance,e.state.loading|=4,vu(n,l.precedence,t));return e.instance}function vu(t,e,l){for(var n=l.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),a=n.length?n[n.length-1]:null,i=a,f=0;f<n.length;f++){var o=n[f];if(o.dataset.precedence===e)i=o;else if(i!==a)break}i?i.parentNode.insertBefore(t,i.nextSibling):(e=l.nodeType===9?l.head:l,e.insertBefore(t,e.firstChild))}function lr(t,e){t.crossOrigin==null&&(t.crossOrigin=e.crossOrigin),t.referrerPolicy==null&&(t.referrerPolicy=e.referrerPolicy),t.title==null&&(t.title=e.title)}function nr(t,e){t.crossOrigin==null&&(t.crossOrigin=e.crossOrigin),t.referrerPolicy==null&&(t.referrerPolicy=e.referrerPolicy),t.integrity==null&&(t.integrity=e.integrity)}var Su=null;function xd(t,e,l){if(Su===null){var n=new Map,a=Su=new Map;a.set(l,n)}else a=Su,n=a.get(l),n||(n=new Map,a.set(l,n));if(n.has(t))return n;for(n.set(t,null),l=l.getElementsByTagName(t),a=0;a<l.length;a++){var i=l[a];if(!(i[oa]||i[Kt]||t==="link"&&i.getAttribute("rel")==="stylesheet")&&i.namespaceURI!=="http://www.w3.org/2000/svg"){var f=i.getAttribute(e)||"";f=t+f;var o=n.get(f);o?o.push(i):n.set(f,[i])}}return n}function Md(t,e,l){t=t.ownerDocument||t,t.head.insertBefore(l,e==="title"?t.querySelector("head > title"):null)}function gp(t,e,l){if(l===1||e.itemProp!=null)return!1;switch(t){case"meta":case"title":return!0;case"style":if(typeof e.precedence!="string"||typeof e.href!="string"||e.href==="")break;return!0;case"link":if(typeof e.rel!="string"||typeof e.href!="string"||e.href===""||e.onLoad||e.onError)break;switch(e.rel){case"stylesheet":return t=e.disabled,typeof e.precedence=="string"&&t==null;default:return!0}case"script":if(e.async&&typeof e.async!="function"&&typeof e.async!="symbol"&&!e.onLoad&&!e.onError&&e.src&&typeof e.src=="string")return!0}return!1}function zd(t){return!(t.type==="stylesheet"&&(t.state.loading&3)===0)}function pp(t,e,l,n){if(l.type==="stylesheet"&&(typeof n.media!="string"||matchMedia(n.media).matches!==!1)&&(l.state.loading&4)===0){if(l.instance===null){var a=$n(n.href),i=e.querySelector(ka(a));if(i){e=i._p,e!==null&&typeof e=="object"&&typeof e.then=="function"&&(t.count++,t=bu.bind(t),e.then(t,t)),l.state.loading|=4,l.instance=i,Xt(i);return}i=e.ownerDocument||e,n=Ad(n),(a=Re.get(a))&&lr(n,a),i=i.createElement("link"),Xt(i);var f=i;f._p=new Promise(function(o,m){f.onload=o,f.onerror=m}),kt(i,"link",n),l.instance=i}t.stylesheets===null&&(t.stylesheets=new Map),t.stylesheets.set(l,e),(e=l.state.preload)&&(l.state.loading&3)===0&&(t.count++,l=bu.bind(t),e.addEventListener("load",l),e.addEventListener("error",l))}}var ar=0;function vp(t,e){return t.stylesheets&&t.count===0&&Tu(t,t.stylesheets),0<t.count||0<t.imgCount?function(l){var n=setTimeout(function(){if(t.stylesheets&&Tu(t,t.stylesheets),t.unsuspend){var i=t.unsuspend;t.unsuspend=null,i()}},6e4+e);0<t.imgBytes&&ar===0&&(ar=62500*Ig());var a=setTimeout(function(){if(t.waitingForImages=!1,t.count===0&&(t.stylesheets&&Tu(t,t.stylesheets),t.unsuspend)){var i=t.unsuspend;t.unsuspend=null,i()}},(t.imgBytes>ar?50:800)+e);return t.unsuspend=l,function(){t.unsuspend=null,clearTimeout(n),clearTimeout(a)}}:null}function bu(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)Tu(this,this.stylesheets);else if(this.unsuspend){var t=this.unsuspend;this.unsuspend=null,t()}}}var Eu=null;function Tu(t,e){t.stylesheets=null,t.unsuspend!==null&&(t.count++,Eu=new Map,e.forEach(Sp,t),Eu=null,bu.call(t))}function Sp(t,e){if(!(e.state.loading&4)){var l=Eu.get(t);if(l)var n=l.get(null);else{l=new Map,Eu.set(t,l);for(var a=t.querySelectorAll("link[data-precedence],style[data-precedence]"),i=0;i<a.length;i++){var f=a[i];(f.nodeName==="LINK"||f.getAttribute("media")!=="not all")&&(l.set(f.dataset.precedence,f),n=f)}n&&l.set(null,n)}a=e.instance,f=a.getAttribute("data-precedence"),i=l.get(f)||n,i===n&&l.set(null,a),l.set(f,a),this.count++,n=bu.bind(this),a.addEventListener("load",n),a.addEventListener("error",n),i?i.parentNode.insertBefore(a,i.nextSibling):(t=t.nodeType===9?t.head:t,t.insertBefore(a,t.firstChild)),e.state.loading|=4}}var $a={$$typeof:Ht,Provider:null,Consumer:null,_currentValue:G,_currentValue2:G,_threadCount:0};function bp(t,e,l,n,a,i,f,o,m){this.tag=1,this.containerInfo=t,this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.next=this.pendingContext=this.context=this.cancelPendingCommit=null,this.callbackPriority=0,this.expirationTimes=Pu(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Pu(0),this.hiddenUpdates=Pu(null),this.identifierPrefix=n,this.onUncaughtError=a,this.onCaughtError=i,this.onRecoverableError=f,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=m,this.incompleteTransitions=new Map}function Cd(t,e,l,n,a,i,f,o,m,A,M,O){return t=new bp(t,e,l,f,m,A,M,O,o),e=1,i===!0&&(e|=24),i=ye(3,null,null,e),t.current=i,i.stateNode=t,e=Ls(),e.refCount++,t.pooledCache=e,e.refCount++,i.memoizedState={element:n,isDehydrated:l,cache:e},Xs(i),t}function Od(t){return t?(t=Cn,t):Cn}function Dd(t,e,l,n,a,i){a=Od(a),n.context===null?n.context=a:n.pendingContext=a,n=xl(e),n.payload={element:l},i=i===void 0?null:i,i!==null&&(n.callback=i),l=Ml(t,n,e),l!==null&&(re(l,t,e),Ca(l,t,e))}function Rd(t,e){if(t=t.memoizedState,t!==null&&t.dehydrated!==null){var l=t.retryLane;t.retryLane=l!==0&&l<e?l:e}}function ir(t,e){Rd(t,e),(t=t.alternate)&&Rd(t,e)}function Ud(t){if(t.tag===13||t.tag===31){var e=Pl(t,67108864);e!==null&&re(e,t,67108864),ir(t,67108864)}}function wd(t){if(t.tag===13||t.tag===31){var e=be();e=ts(e);var l=Pl(t,e);l!==null&&re(l,t,e),ir(t,e)}}var Au=!0;function Ep(t,e,l,n){var a=z.T;z.T=null;var i=w.p;try{w.p=2,ur(t,e,l,n)}finally{w.p=i,z.T=a}}function Tp(t,e,l,n){var a=z.T;z.T=null;var i=w.p;try{w.p=8,ur(t,e,l,n)}finally{w.p=i,z.T=a}}function ur(t,e,l,n){if(Au){var a=sr(n);if(a===null)Zc(t,e,n,_u,l),Nd(t,n);else if(_p(a,t,e,l,n))n.stopPropagation();else if(Nd(t,n),e&4&&-1<Ap.indexOf(t)){for(;a!==null;){var i=pn(a);if(i!==null)switch(i.tag){case 3:if(i=i.stateNode,i.current.memoizedState.isDehydrated){var f=kl(i.pendingLanes);if(f!==0){var o=i;for(o.pendingLanes|=2,o.entangledLanes|=2;f;){var m=1<<31-de(f);o.entanglements[1]|=m,f&=~m}Ze(i),(ut&6)===0&&(uu=oe()+500,Ka(0))}}break;case 31:case 13:o=Pl(i,2),o!==null&&re(o,i,2),cu(),ir(i,2)}if(i=sr(n),i===null&&Zc(t,e,n,_u,l),i===a)break;a=i}a!==null&&n.stopPropagation()}else Zc(t,e,n,null,l)}}function sr(t){return t=rs(t),cr(t)}var _u=null;function cr(t){if(_u=null,t=gn(t),t!==null){var e=d(t);if(e===null)t=null;else{var l=e.tag;if(l===13){if(t=y(e),t!==null)return t;t=null}else if(l===31){if(t=v(e),t!==null)return t;t=null}else if(l===3){if(e.stateNode.current.memoizedState.isDehydrated)return e.tag===3?e.stateNode.containerInfo:null;t=null}else e!==t&&(t=null)}}return _u=t,null}function Hd(t){switch(t){case"beforetoggle":case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"resize":case"seeked":case"submit":case"toggle":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 2;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 8;case"message":switch(cy()){case Yr:return 2;case Xr:return 8;case di:case ry:return 32;case Gr:return 268435456;default:return 32}default:return 32}}var rr=!1,Ll=null,jl=null,ql=null,Fa=new Map,Ia=new Map,Yl=[],Ap="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset".split(" ");function Nd(t,e){switch(t){case"focusin":case"focusout":Ll=null;break;case"dragenter":case"dragleave":jl=null;break;case"mouseover":case"mouseout":ql=null;break;case"pointerover":case"pointerout":Fa.delete(e.pointerId);break;case"gotpointercapture":case"lostpointercapture":Ia.delete(e.pointerId)}}function Pa(t,e,l,n,a,i){return t===null||t.nativeEvent!==i?(t={blockedOn:e,domEventName:l,eventSystemFlags:n,nativeEvent:i,targetContainers:[a]},e!==null&&(e=pn(e),e!==null&&Ud(e)),t):(t.eventSystemFlags|=n,e=t.targetContainers,a!==null&&e.indexOf(a)===-1&&e.push(a),t)}function _p(t,e,l,n,a){switch(e){case"focusin":return Ll=Pa(Ll,t,e,l,n,a),!0;case"dragenter":return jl=Pa(jl,t,e,l,n,a),!0;case"mouseover":return ql=Pa(ql,t,e,l,n,a),!0;case"pointerover":var i=a.pointerId;return Fa.set(i,Pa(Fa.get(i)||null,t,e,l,n,a)),!0;case"gotpointercapture":return i=a.pointerId,Ia.set(i,Pa(Ia.get(i)||null,t,e,l,n,a)),!0}return!1}function Bd(t){var e=gn(t.target);if(e!==null){var l=d(e);if(l!==null){if(e=l.tag,e===13){if(e=y(l),e!==null){t.blockedOn=e,kr(t.priority,function(){wd(l)});return}}else if(e===31){if(e=v(l),e!==null){t.blockedOn=e,kr(t.priority,function(){wd(l)});return}}else if(e===3&&l.stateNode.current.memoizedState.isDehydrated){t.blockedOn=l.tag===3?l.stateNode.containerInfo:null;return}}}t.blockedOn=null}function xu(t){if(t.blockedOn!==null)return!1;for(var e=t.targetContainers;0<e.length;){var l=sr(t.nativeEvent);if(l===null){l=t.nativeEvent;var n=new l.constructor(l.type,l);cs=n,l.target.dispatchEvent(n),cs=null}else return e=pn(l),e!==null&&Ud(e),t.blockedOn=l,!1;e.shift()}return!0}function Ld(t,e,l){xu(t)&&l.delete(e)}function xp(){rr=!1,Ll!==null&&xu(Ll)&&(Ll=null),jl!==null&&xu(jl)&&(jl=null),ql!==null&&xu(ql)&&(ql=null),Fa.forEach(Ld),Ia.forEach(Ld)}function Mu(t,e){t.blockedOn===e&&(t.blockedOn=null,rr||(rr=!0,s.unstable_scheduleCallback(s.unstable_NormalPriority,xp)))}var zu=null;function jd(t){zu!==t&&(zu=t,s.unstable_scheduleCallback(s.unstable_NormalPriority,function(){zu===t&&(zu=null);for(var e=0;e<t.length;e+=3){var l=t[e],n=t[e+1],a=t[e+2];if(typeof n!="function"){if(cr(n||l)===null)continue;break}var i=pn(l);i!==null&&(t.splice(e,3),e-=3,sc(i,{pending:!0,data:a,method:l.method,action:n},n,a))}}))}function In(t){function e(m){return Mu(m,t)}Ll!==null&&Mu(Ll,t),jl!==null&&Mu(jl,t),ql!==null&&Mu(ql,t),Fa.forEach(e),Ia.forEach(e);for(var l=0;l<Yl.length;l++){var n=Yl[l];n.blockedOn===t&&(n.blockedOn=null)}for(;0<Yl.length&&(l=Yl[0],l.blockedOn===null);)Bd(l),l.blockedOn===null&&Yl.shift();if(l=(t.ownerDocument||t).$$reactFormReplay,l!=null)for(n=0;n<l.length;n+=3){var a=l[n],i=l[n+1],f=a[ne]||null;if(typeof i=="function")f||jd(l);else if(f){var o=null;if(i&&i.hasAttribute("formAction")){if(a=i,f=i[ne]||null)o=f.formAction;else if(cr(a)!==null)continue}else o=f.action;typeof o=="function"?l[n+1]=o:(l.splice(n,3),n-=3),jd(l)}}}function qd(){function t(i){i.canIntercept&&i.info==="react-transition"&&i.intercept({handler:function(){return new Promise(function(f){return a=f})},focusReset:"manual",scroll:"manual"})}function e(){a!==null&&(a(),a=null),n||setTimeout(l,20)}function l(){if(!n&&!navigation.transition){var i=navigation.currentEntry;i&&i.url!=null&&navigation.navigate(i.url,{state:i.getState(),info:"react-transition",history:"replace"})}}if(typeof navigation=="object"){var n=!1,a=null;return navigation.addEventListener("navigate",t),navigation.addEventListener("navigatesuccess",e),navigation.addEventListener("navigateerror",e),setTimeout(l,100),function(){n=!0,navigation.removeEventListener("navigate",t),navigation.removeEventListener("navigatesuccess",e),navigation.removeEventListener("navigateerror",e),a!==null&&(a(),a=null)}}}function fr(t){this._internalRoot=t}Cu.prototype.render=fr.prototype.render=function(t){var e=this._internalRoot;if(e===null)throw Error(c(409));var l=e.current,n=be();Dd(l,n,t,e,null,null)},Cu.prototype.unmount=fr.prototype.unmount=function(){var t=this._internalRoot;if(t!==null){this._internalRoot=null;var e=t.containerInfo;Dd(t.current,2,null,t,null,null),cu(),e[yn]=null}};function Cu(t){this._internalRoot=t}Cu.prototype.unstable_scheduleHydration=function(t){if(t){var e=Jr();t={blockedOn:null,target:t,priority:e};for(var l=0;l<Yl.length&&e!==0&&e<Yl[l].priority;l++);Yl.splice(l,0,t),l===0&&Bd(t)}};var Yd=u.version;if(Yd!=="19.2.3")throw Error(c(527,Yd,"19.2.3"));w.findDOMNode=function(t){var e=t._reactInternals;if(e===void 0)throw typeof t.render=="function"?Error(c(188)):(t=Object.keys(t).join(","),Error(c(268,t)));return t=b(e),t=t!==null?N(t):null,t=t===null?null:t.stateNode,t};var Mp={bundleType:0,version:"19.2.3",rendererPackageName:"react-dom",currentDispatcherRef:z,reconcilerVersion:"19.2.3"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var Ou=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Ou.isDisabled&&Ou.supportsFiber)try{ca=Ou.inject(Mp),he=Ou}catch{}}return ni.createRoot=function(t,e){if(!h(t))throw Error(c(299));var l=!1,n="",a=Jo,i=ko,f=Wo;return e!=null&&(e.unstable_strictMode===!0&&(l=!0),e.identifierPrefix!==void 0&&(n=e.identifierPrefix),e.onUncaughtError!==void 0&&(a=e.onUncaughtError),e.onCaughtError!==void 0&&(i=e.onCaughtError),e.onRecoverableError!==void 0&&(f=e.onRecoverableError)),e=Cd(t,1,!1,null,null,l,n,null,a,i,f,qd),t[yn]=e.current,Vc(t),new fr(e)},ni.hydrateRoot=function(t,e,l){if(!h(t))throw Error(c(299));var n=!1,a="",i=Jo,f=ko,o=Wo,m=null;return l!=null&&(l.unstable_strictMode===!0&&(n=!0),l.identifierPrefix!==void 0&&(a=l.identifierPrefix),l.onUncaughtError!==void 0&&(i=l.onUncaughtError),l.onCaughtError!==void 0&&(f=l.onCaughtError),l.onRecoverableError!==void 0&&(o=l.onRecoverableError),l.formState!==void 0&&(m=l.formState)),e=Cd(t,1,!0,e,l??null,n,a,m,i,f,o,qd),e.context=Od(null),l=e.current,n=be(),n=ts(n),a=xl(n),a.callback=null,Ml(l,a,n),l=n,e.current.lanes=l,fa(e,l),Ze(e),t[yn]=e.current,Vc(t),new Cu(e)},ni.version="19.2.3",ni}var Pd;function Xp(){if(Pd)return dr.exports;Pd=1;function s(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(s)}catch(u){console.error(u)}}return s(),dr.exports=Yp(),dr.exports}var Gp=Xp();function tm(s){return s!==null&&typeof s=="object"&&[null,Object.prototype].includes(Object.getPrototypeOf(s))||Array.isArray(s)}function Er(s,u,r=new WeakMap){if(Object.is(s,u))return!0;if(typeof s=="function"&&typeof u=="function")return typeof s==typeof u;if(!tm(s)||!tm(u))return!1;const c=r.get(s);if(c&&c===u)return!0;if(r.set(s,u),Array.isArray(s)||Array.isArray(u)){if(!Array.isArray(s)||!Array.isArray(u)||s.length!==u.length)return!1;for(let y=0;y<s.length;y++)if(!Er(s[y],u[y],r))return!1;return!0}const h=Object.keys(s),d=Object.keys(u);if(h.length!==d.length)return!1;for(let y=0;y<h.length;y++){const v=h[y];if(!Object.prototype.hasOwnProperty.call(u,v))return!1;const E=s[v],b=u[v];if(!Er(E,b,r))return!1}return!0}function Qp(s){const u=[],r=(d,y)=>y.reduce((v,E)=>v==null?v:v[E],d),c=(d,y)=>(...v)=>{const E=r(s.current,d),b=E==null?void 0:E[y];if(typeof b=="function")return b.apply(E,v)},h=d=>{if(typeof d=="function"){const y=u[u.length-1],v=u.slice(0,-1);return c(v,y)}if(Array.isArray(d)){const y=u.length,v=new Array(d.length);for(let E=0;E<d.length;E++)u[y]=E,v[E]=h(d[E]);return u.length=y,v}if(d&&typeof d=="object"){const y=u.length,v={};for(const E of Object.keys(d))u[y]=E,v[E]=h(d[E]);return u.length=y,v}return d};return h(s.current)}function Kp(s){const u=Jd.useRef(s);u.current=s;const r=Jd.useRef(null);return(!r.current||!Er(r.current.snapshot,s))&&(r.current={snapshot:s,shaped:Qp(u)}),r.current.shaped}const Vp=Object.freeze(["focusComposer","setThreadId","sendUserMessage","setComposerValue","setRuntimeCapabilities","fetchUpdates","sendCustomAction"]);function Zp(s){const u=vt.useRef(null),r=Kp(s),c=vt.useMemo(()=>Vp.reduce((y,v)=>(y[v]=(...E)=>{if(!u.current){console.warn("ChatKit element is not mounted");return}return u.current[v](...E)},y),{}),[]),h=vt.useCallback(y=>{u.current=y},[]),d=vt.useMemo(()=>{const y={},v={};for(const[E,b]of Object.entries(r))/^on[A-Z]/.test(E)&&E!=="onClientTool"?v[E]=b:y[E]=b;return{setInstance:h,options:y,handlers:v}},[r,h]);return vt.useMemo(()=>({...c,control:d,ref:u}),[c,d])}class Jp{constructor(){At(this,"callbacks",new Map)}on(u,r){this.callbacks.has(u)||this.callbacks.set(u,new Set),this.callbacks.get(u).add(r)}emit(u,...r){var h;const c=r[0];(h=this.callbacks.get(u))==null||h.forEach(d=>d(c))}off(u,r){var c;r?(c=this.callbacks.get(u))==null||c.delete(r):this.callbacks.delete(u)}allOff(){this.callbacks.clear()}}async function kp(s,u){const r=s.getReader();let c;for(;!(c=await r.read()).done;)u(c.value)}function Wp(s){let u,r,c,h=!1;return function(y){u===void 0?(u=y,r=0,c=-1):u=Fp(u,y);const v=u.length;let E=0;for(;r<v;){h&&(u[r]===10&&(E=++r),h=!1);let b=-1;for(;r<v&&b===-1;++r)switch(u[r]){case 58:c===-1&&(c=r-E);break;case 13:h=!0;case 10:b=r;break}if(b===-1)break;s(u.subarray(E,b),c),E=r,c=-1}E===v?u=void 0:E!==0&&(u=u.subarray(E),r-=E)}}function $p(s,u,r){let c=em();const h=new TextDecoder;return function(y,v){if(y.length===0)r==null||r(c),c=em();else if(v>0){const E=h.decode(y.subarray(0,v)),b=v+(y[v+1]===32?2:1),N=h.decode(y.subarray(b));switch(E){case"data":c.data=c.data?c.data+`
|
|
50
|
-
`+N:N;break;case"event":c.event=N;break;case"id":s(c.id=N);break;case"retry":const U=parseInt(N,10);isNaN(U)||u(c.retry=U);break}}}}function Fp(s,u){const r=new Uint8Array(s.length+u.length);return r.set(s),r.set(u,s.length),r}function em(){return{data:"",event:"",id:"",retry:void 0}}var Ip=function(s,u){var r={};for(var c in s)Object.prototype.hasOwnProperty.call(s,c)&&u.indexOf(c)<0&&(r[c]=s[c]);if(s!=null&&typeof Object.getOwnPropertySymbols=="function")for(var h=0,c=Object.getOwnPropertySymbols(s);h<c.length;h++)u.indexOf(c[h])<0&&Object.prototype.propertyIsEnumerable.call(s,c[h])&&(r[c[h]]=s[c[h]]);return r};const Tr="text/event-stream",Pp=1e3,lm="last-event-id";function t0(s,u){var{signal:r,headers:c,onopen:h,onmessage:d,onclose:y,onerror:v,openWhenHidden:E,fetch:b}=u,N=Ip(u,["signal","headers","onopen","onmessage","onclose","onerror","openWhenHidden","fetch"]);return new Promise((U,W)=>{const st=Object.assign({},c);st.accept||(st.accept=Tr);let St;function it(){St.abort(),document.hidden||ee()}E||document.addEventListener("visibilitychange",it);let Mt=Pp,bt=0;function wt(){document.removeEventListener("visibilitychange",it),window.clearTimeout(bt),St.abort()}r==null||r.addEventListener("abort",()=>{wt(),U()});const Ht=b??window.fetch,te=h??e0;async function ee(){var Yt;St=new AbortController;try{const $=await Ht(s,Object.assign(Object.assign({},N),{headers:st,signal:St.signal}));await te($),await kp($.body,Wp($p(zt=>{zt?st[lm]=zt:delete st[lm]},zt=>{Mt=zt},d))),y==null||y(),wt(),U()}catch($){if(!St.signal.aborted)try{const zt=(Yt=v==null?void 0:v($))!==null&&Yt!==void 0?Yt:Mt;window.clearTimeout(bt),bt=window.setTimeout(ee,zt)}catch(zt){wt(),W(zt)}}}ee()})}function e0(s){const u=s.headers.get("content-type");if(!(u!=null&&u.startsWith(Tr)))throw new Error(`Expected content-type to be ${Tr}, Actual: ${u}`)}const aa="__chatkit_error__";class Yu extends Error{constructor(r,c,h){super(r);At(this,"status");At(this,"statusText");At(this,"metadata");this.name="HttpError",this.statusText=c.statusText,this.status=c.status,this.metadata=h}static fromPossibleFrameSafeError(r){if(r instanceof Yu)return r;if(r&&typeof r=="object"&&aa in r&&r[aa]==="HttpError"){const c=r,h=new Yu(c.message,{status:c.status,statusText:c.statusText},c.metadata);return h.stack=c.stack,h}return null}}var Em;Em=aa;const Lr=class Lr{constructor(u,r,c){At(this,Em,"HttpError");At(this,"message");At(this,"stack");At(this,"status");At(this,"statusText");At(this,"metadata");this.message=u,this.stack=new Error(u).stack,this.status=r.status,this.statusText=r.statusText,this.metadata=c}static fromHttpError(u){return new Lr(u.message,{status:u.status,statusText:u.statusText},u.metadata)}};let Xu=Lr;const l0=1e3,n0=1e4,a0=5,i0=(s,u=n0,r=l0)=>{const c=Math.min(u,r*2**s);return Math.floor(c*(.5+Math.random()*.5))};class nm extends Error{constructor(u){super(),this.cause=u}}const u0=async(s,u)=>{let r=0;const{onopen:c,...h}=u;await t0(s,{...h,onopen:async d=>{var v;if(c==null||c(d),d.ok&&((v=d.headers.get("content-type"))!=null&&v.startsWith("text/event-stream"))){r=0;return}const y=new Xu(`Streaming failed: ${d.statusText}`,d);throw d.status>=400&&d.status<500?y:new nm(y)},onerror:d=>{if(d instanceof nm){if(r>=a0)throw d.cause;return r+=1,i0(r)}throw d}})};function pr(){const s=globalThis.crypto;if(typeof(s==null?void 0:s.randomUUID)=="function")return s.randomUUID();if(typeof(s==null?void 0:s.getRandomValues)=="function"){const u=new Uint8Array(16);return s.getRandomValues(u),u[6]=u[6]&15|64,u[8]=u[8]&63|128,[...u].map(r=>r.toString(16).padStart(2,"0")).join("").replace(/^(.{8})(.{4})(.{4})(.{4})(.{12})$/,"$1-$2-$3-$4-$5")}return`ck_${Date.now()}_${Math.random().toString(16).slice(2)}`}let s0=class Am extends Error{constructor(r){super(r);At(this,"_name");this.name="IntegrationError",this._name=this.name}static fromPossibleFrameSafeError(r){if(r&&typeof r=="object"&&aa in r&&r[aa]==="IntegrationError"){const c=r,h=new Am(c.message);return h.stack=c.stack,h}return null}};var Tm;Tm=aa;class c0{constructor(u){At(this,Tm,"IntegrationError");At(this,"message");At(this,"stack");this.message=u,this.stack=new Error(u).stack}}class r0{constructor({handlers:u,target:r,targetOrigin:c,fetch:h=window.fetch}){At(this,"targetOrigin");At(this,"target");At(this,"commandHandlers");At(this,"_fetch");At(this,"emitter",new Jp);At(this,"handlers",new Map);At(this,"fetchEventSourceHandlers",new Map);At(this,"abortControllers",new Map);At(this,"commands",new Proxy({},{get:(u,r)=>(c,h)=>new Promise((d,y)=>{const v=pr();this.handlers.set(v,{resolve:d,reject:y,stack:new Error().stack||""}),this.sendMessage({type:"command",nonce:v,command:`on${r.charAt(0).toUpperCase()}${r.slice(1)}`,data:c},h)})}));At(this,"handleMessage",async u=>{var c,h,d,y;if(!u.data||u.data.__xpaiChatKit!==!0||u.origin!==this.targetOrigin||u.source!==this.target())return;const r=u.data;switch(r.type){case"event":{this.emitter.emit(r.event,r.data);break}case"fetch":{try{if(r.formData){const N=new FormData;for(const[U,W]of Object.entries(r.formData))N.append(U,W);r.params.body=N}const v=new AbortController;this.abortControllers.set(r.nonce,v),r.params.signal=v.signal;const E=await this._fetch(r.url,r.params);if(!E.ok){const N=await E.json().then(U=>U.message||E.statusText).catch(()=>E.statusText);throw new Xu(N,E)}const b=await E.json().catch(()=>({}));this.sendMessage({type:"response",response:b,nonce:r.nonce})}catch(v){this.sendMessage({type:"response",error:v,nonce:r.nonce})}break}case"fetchEventSource":{try{const v=new AbortController;this.abortControllers.set(r.nonce,v),await u0(r.url,{...r.params,signal:v.signal,fetch:this._fetch,onmessage:E=>{this.sendMessage({type:"fetchEventSourceMessage",message:E,nonce:r.nonce})}}),this.sendMessage({type:"response",response:void 0,nonce:r.nonce})}catch(v){this.sendMessage({type:"response",error:v,nonce:r.nonce})}break}case"command":{if(!this.canReceiveCommand(r.command)){this.sendMessage({type:"response",error:new c0(`Command ${r.command} not supported`),nonce:r.nonce});return}try{const v=await((h=(c=this.commandHandlers)[r.command])==null?void 0:h.call(c,r.data));this.sendMessage({type:"response",response:v,nonce:r.nonce})}catch(v){this.sendMessage({type:"response",error:v,nonce:r.nonce})}break}case"response":{const v=this.handlers.get(r.nonce);if(!v){console.error("No handler found for nonce",r.nonce);return}if(r.error){const E=s0.fromPossibleFrameSafeError(r.error),b=Yu.fromPossibleFrameSafeError(r.error);E?(E.stack=v.stack,v.reject(E)):b?v.reject(b):v.reject(r.error)}else v.resolve(r.response);this.handlers.delete(r.nonce);break}case"fetchEventSourceMessage":{if(!this.fetchEventSourceHandlers.get(r.nonce)){console.error("No handler found for nonce",r.nonce);return}(y=(d=this.fetchEventSourceHandlers.get(r.nonce))==null?void 0:d.onmessage)==null||y.call(d,r.message);break}case"abortSignal":{const v=this.abortControllers.get(r.nonce);v&&(v.abort(r.reason),this.abortControllers.delete(r.nonce));break}}});this.commandHandlers=u,this.target=r,this.targetOrigin=c,this._fetch=((...d)=>h(...d))}setTargetOrigin(u){this.targetOrigin=u}sendMessage(u,r){var h;const c={__xpaiChatKit:!0,...u};(h=this.target())==null||h.postMessage(c,this.targetOrigin,r)}connect(){window.addEventListener("message",this.handleMessage)}disconnect(){window.removeEventListener("message",this.handleMessage)}fetch(u,r){return new Promise((c,h)=>{const d=pr();this.handlers.set(d,{resolve:c,reject:h,stack:new Error().stack||""});let y;if(r.body instanceof FormData){y={};for(const[v,E]of r.body.entries())y[v]=E;r.body=void 0}r.signal&&(r.signal.addEventListener("abort",()=>{var v;this.sendMessage({type:"abortSignal",nonce:d,reason:(v=r.signal)==null?void 0:v.reason})}),r.signal=void 0),this.sendMessage({type:"fetch",nonce:d,params:r,formData:y,url:u})})}fetchEventSource(u,r){return new Promise((c,h)=>{const{onmessage:d,signal:y,...v}=r,E=pr();this.handlers.set(E,{resolve:c,reject:h,stack:new Error().stack||""}),this.fetchEventSourceHandlers.set(E,{onmessage:d}),y&&y.addEventListener("abort",()=>{this.sendMessage({type:"abortSignal",nonce:E,reason:y.reason})}),this.sendMessage({type:"fetchEventSource",nonce:E,params:v,url:u})})}emit(...[u,r,c]){this.sendMessage({type:"event",event:u,data:r},c)}on(...[u,r]){this.emitter.on(u,r)}destroy(){window.removeEventListener("message",this.handleMessage),this.emitter.allOff(),this.handlers.clear()}}const f0=s=>btoa(s).replace(/\+/g,"-").replace(/\//g,"_").replace(/=+$/,""),o0=s=>{if(s===void 0)throw new TypeError("encodeBase64: `undefined` cannot be encoded to valid JSON. Pass null instead.");const u=JSON.stringify(s),r=new TextEncoder().encode(u);let c="";for(const h of r)c+=String.fromCharCode(h);return f0(c)};class qe extends Error{}function h0(s){return s.message}const d0=["command.setOptions","command.sendUserMessage","command.setComposerValue","command.setRuntimeCapabilities","command.setThreadId","command.focusComposer","command.fetchUpdates","command.sendCustomAction","command.showHistory","command.hideHistory","event.ready","event.error","event.log","event.response.start","event.response.end","event.response.stop","event.thread.change","event.tool.change","event.thread.load.start","event.thread.load.end","event.deeplink","event.effect","error.StreamError","error.StreamEventParsingError","error.WidgetItemError","error.InitialThreadLoadError","error.FileAttachmentError","error.HistoryViewError","error.FatalAppError","error.IntegrationError","error.EntitySearchError","error.DomainVerificationRequestError","backend.threads.get_by_id","backend.threads.list","backend.threads.update","backend.threads.delete","backend.threads.create","backend.threads.add_user_message","backend.threads.add_client_tool_output","backend.threads.retry_after_item","backend.threads.custom_action","backend.attachments.create","backend.attachments.get_preview","backend.attachments.delete","backend.items.list","backend.items.feedback","thread.item.generated_image","thread.item.user_message","thread.item.assistant_message","thread.item.client_tool_call","thread.item.widget","thread.item.task","thread.item.workflow","thread.item.end_of_turn","thread.item.image_generation","widget.Basic","widget.Card","widget.ListView","widget.ListViewItem","widget.Badge","widget.Box","widget.Row","widget.Col","widget.Button","widget.Caption","widget.Chart","widget.Checkbox","widget.DatePicker","widget.Divider","widget.Form","widget.Icon","widget.Image","widget.Input","widget.Label","widget.Markdown","widget.RadioGroup","widget.Select","widget.Spacer","widget.Text","widget.Textarea","widget.Title","widget.Transition"],m0=["command.shareThread","command.setTrainingOptOut","event.thread.restore","event.message.share","event.image.download","event.history.open","event.history.close","event.log.chatgpt","error.HttpError","error.NetworkError","error.UnhandledError","error.UnhandledPromiseRejectionError","error.StreamEventHandlingError","error.StreamStopError","error.ThreadRenderingError","error.IntlError","error.AppError","backend.threads.stop","backend.threads.share","backend.threads.create_from_shared","backend.threads.init","backend.attachments.process","widget.CardCarousel","widget.Favicon","widget.CardLinkItem","widget.Map"],y0={chatkit:{allow:[...d0,"thread.item.image_generation"],deny:m0}},am=s=>{const u=y0[s],r=new Set(u.allow);for(const b of u.deny??[])r.delete(b);const c=new Set,h=new Set,d=new Set,y=new Set,v=new Set,E=new Set;for(const b of r){if(b.startsWith("command.")){c.add(b.slice(8));continue}if(b.startsWith("event.")){h.add(b.slice(6));continue}if(b.startsWith("backend.")){d.add(b.slice(8));continue}if(b.startsWith("thread.item.")&&y.add(b.slice(12)),b.startsWith("error.")){v.add(b.slice(6));continue}if(b.startsWith("widget.")){E.add(b.slice(7));continue}}return{commands:c,events:h,backend:d,threadItems:y,errors:v,widgets:E}};class g0 extends r0{canReceiveCommand(u){return!0}}const p0=["idle","running-right","running-left","waving","jumping","failed","waiting","running","review"],ai={columns:8,rows:9,cellWidth:192,cellHeight:208,animations:{idle:{row:0,frames:6,frameDurations:[280,110,110,140,140,320]},"running-right":{row:1,frames:8,frameDurations:[120,120,120,120,120,120,120,220]},"running-left":{row:2,frames:8,frameDurations:[120,120,120,120,120,120,120,220]},waving:{row:3,frames:4,frameDurations:[140,140,140,280]},jumping:{row:4,frames:5,frameDurations:[140,140,140,140,280]},failed:{row:5,frames:8,frameDurations:[140,140,140,140,140,140,140,240]},waiting:{row:6,frames:6,frameDurations:[150,150,150,150,150,260]},running:{row:7,frames:6,frameDurations:[120,120,120,120,120,220]},review:{row:8,frames:6,frameDurations:[150,150,150,150,150,280]}}},Uu={top:0,right:0,bottom:0,left:0},im="chatkit:pet:position:v1",v0="/pets/boba/spritesheet.webp",Ar={type:"sprite-atlas",src:v0},um={pin:"bottom-right",draggable:!0,scale:.25,persist:!0,zIndex:40};function S0(s,u){return{row:(u==null?void 0:u.row)??s.row,frames:(u==null?void 0:u.frames)??s.frames,frameDurations:u!=null&&u.frameDurations&&u.frameDurations.length>0?u.frameDurations:s.frameDurations}}function b0(s){var r;const u={};for(const c of p0)u[c]=S0(ai.animations[c],(r=s==null?void 0:s.animations)==null?void 0:r[c]);return{columns:(s==null?void 0:s.columns)??ai.columns,rows:(s==null?void 0:s.rows)??ai.rows,cellWidth:(s==null?void 0:s.cellWidth)??ai.cellWidth,cellHeight:(s==null?void 0:s.cellHeight)??ai.cellHeight,animations:u}}function E0(s){return s&&s.src?s:Ar}function fi(s){return s?s===!0?{character:Ar,position:um,behavior:"auto",ariaLabel:"Animated pet",imageRendering:"auto"}:s.enabled===!1?null:{character:E0(s.character),position:{...um,...s.position},behavior:s.behavior??"auto",ariaLabel:s.ariaLabel??"Animated pet",imageRendering:s.imageRendering??"auto"}:null}function T0(s){return s.src?{kind:"atlas",src:s.src,atlas:b0(s.atlas)}:null}function vr(s){return typeof s=="number"?{top:s,right:s,bottom:s,left:s}:{top:(s==null?void 0:s.top)??Uu.top,right:(s==null?void 0:s.right)??Uu.right,bottom:(s==null?void 0:s.bottom)??Uu.bottom,left:(s==null?void 0:s.left)??Uu.left}}function Ue(s,u,r,c){const h=c.left,d=c.top,y=Math.max(h,r.width-u.width-c.right),v=Math.max(d,r.height-u.height-c.bottom);return{x:Math.min(y,Math.max(h,s.x)),y:Math.min(v,Math.max(d,s.y))}}function A0(s,u,r,c){const h=(r.width-u.width)/2,d=(r.height-u.height)/2,y=r.width-u.width-c.right,v=r.height-u.height-c.bottom;switch(s){case"top-left":return Ue({x:c.left,y:c.top},u,r,c);case"top":return Ue({x:h,y:c.top},u,r,c);case"top-right":return Ue({x:y,y:c.top},u,r,c);case"left":return Ue({x:c.left,y:d},u,r,c);case"center":return Ue({x:h,y:d},u,r,c);case"right":return Ue({x:y,y:d},u,r,c);case"bottom-left":return Ue({x:c.left,y:v},u,r,c);case"bottom":return Ue({x:h,y:v},u,r,c);case"bottom-right":default:return Ue({x:y,y:v},u,r,c)}}const _r=(s,u=new WeakSet)=>{if(typeof s=="function")return"[ChatKitMethod]";if(typeof s!="object"||s===null||u.has(s))return s;if(u.add(s),Array.isArray(s))return s.map(c=>_r(c,u));const r={};for(const[c,h]of Object.entries(s))typeof h!="function"?r[c]=_r(h,u):r[c]="[ChatKitMethod]";return r},wu=2,_0=.5,x0=1.5,M0=3,z0=2e3,sm=12,C0=320,Je=12,ta=8,O0='system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif',cm={"en-US":{closePetMenuItem:"Close pet",hideMessage:"Hide message",expandMessage:"Expand message",collapseMessage:"Collapse message",restoreMessage:"Show message",replyButton:"Reply",replyPlaceholder:"Reply...",sendButton:"Send",sendingButton:"Sending...",sendFailed:"Failed to send"},"zh-CN":{closePetMenuItem:"关闭宠物",hideMessage:"隐藏消息",expandMessage:"展开消息",collapseMessage:"收起消息",restoreMessage:"显示消息",replyButton:"回复",replyPlaceholder:"输入回复...",sendButton:"发送",sendingButton:"发送中...",sendFailed:"发送失败"}};function Hu(s){s.stopPropagation()}function ea(){const s=window.visualViewport;return{width:(s==null?void 0:s.width)||window.innerWidth||320,height:(s==null?void 0:s.height)||window.innerHeight||480}}function D0(s,u){if(!u)return null;try{const r=window.localStorage.getItem(s);if(!r)return null;const c=JSON.parse(r);return!c||typeof c!="object"||typeof c.x!="number"||typeof c.y!="number"?null:{x:c.x,y:c.y}}catch{return null}}function R0(s,u,r){if(u)try{window.localStorage.setItem(s,JSON.stringify(r))}catch{}}function U0(s){return s.replace(/["\\]/g,"\\$&")}function rm(s){return Math.max(.1,s)*_0}function Gl(s,u,r){return Math.min(r,Math.max(u,s))}function w0(){if(typeof window<"u")try{const s=window.localStorage.getItem("chatkit:locale");if(s)return s}catch{}return typeof navigator<"u"?navigator.language:null}function fm(s){const u=(s??w0()??"").trim().toLowerCase();return u==="zh-cn"||u==="zh-hans"||u.startsWith("zh")?"zh-CN":"en-US"}function H0(s){switch(s){case"compact":return{padding:"8px 10px",gap:6,marginTop:3,toggleSize:30,actionSize:22};case"spacious":return{padding:"14px 16px",gap:10,marginTop:6,toggleSize:38,actionSize:28};case"normal":default:return{padding:"12px 14px",gap:8,marginTop:4,toggleSize:34,actionSize:26}}}function N0(s){switch(s){case"pill":return 24;case"round":return 16;case"sharp":return 0;case"soft":default:return 12}}function ii(s){var v,E;const u=typeof s=="string"?null:s,r=((v=u==null?void 0:u.typography)==null?void 0:v.baseSize)??16,c=(u==null?void 0:u.density)??"normal",h=c==="compact"?-1:c==="spacious"?1:0,d=Gl(r-2+h,11,17);return{...H0(c),bodySize:d,titleSize:d+1,iconSize:Gl(d+2,13,19),radius:N0(u==null?void 0:u.radius),fontFamily:((E=u==null?void 0:u.typography)==null?void 0:E.fontFamily)??O0}}function B0(s){return s==="idle"||s==="running-right"||s==="running-left"||s==="waving"||s==="jumping"||s==="failed"||s==="waiting"||s==="running"||s==="review"}function L0(s){if(!s||typeof s!="object"||Array.isArray(s))return null;const u=s;return B0(u.state)?{state:u.state}:null}function j0(s){if(!s||typeof s!="object"||Array.isArray(s))return null;const u=s;return u.pet===null||typeof u.pet=="boolean"?{pet:u.pet}:u.pet&&typeof u.pet=="object"&&!Array.isArray(u.pet)?{pet:u.pet}:null}function q0(s){return s==="running"||s==="completed"||s==="failed"}function om(s){return s?[s.threadId,s.messageId||s.updatedAt||s.message].join(":"):null}function hm(s){return s?[s.threadId,s.messageId??""].join(":"):null}function Y0(s){if(s===null)return{summary:null};if(!s||typeof s!="object"||Array.isArray(s))return null;const u=s;return typeof u.threadId!="string"||!u.threadId.trim()||typeof u.title!="string"||!u.title.trim()||typeof u.message!="string"||!u.message.trim()||!q0(u.status)?null:{summary:{threadId:u.threadId,title:u.title,message:u.message,status:u.status,...typeof u.messageId=="string"&&u.messageId.trim()?{messageId:u.messageId}:{},...typeof u.updatedAt=="string"&&u.updatedAt.trim()?{updatedAt:u.updatedAt}:{}}}}function X0(s){if(!s||typeof s!="object"||Array.isArray(s))return null;const u=s;return u.name!=="thread.summary"?null:Y0(u.data??null)}class G0{constructor(u,r){this.overlayElement=null,this.petElement=null,this.contextMenuElement=null,this.summaryElement=null,this.summaryToggleElement=null,this.mediaElement=null,this.options=null,this.theme=null,this.resolved=null,this.summary=null,this.summaryRenderKey=null,this.dismissedSummaryKey=null,this.isSummaryCollapsed=!1,this.isSummaryExpanded=!1,this.isSummaryHovering=!1,this.isReplyOpen=!1,this.isReplySubmitting=!1,this.replyError=null,this.replyDraft="",this.replyInputElement=null,this.copyLocale=fm(),this.copy=cm[this.copyLocale],this.currentState="waiting",this.lastAutoState="waiting",this.transient=null,this.position=null,this.dragPosition=null,this.dragOffset={x:0,y:0},this.lastDragPosition=null,this.lastDragClientX=null,this.dragAnimation=null,this.isDragging=!1,this.isHovering=!1,this.movedDuringDrag=!1,this.prefersReducedMotion=!1,this.frame=0,this.completed=!1,this.activeAnimationName=null,this.activeAnimationMode=null,this.frameTimer=null,this.restingDelayTimer=null,this.mediaQuery=null,this.connected=!1,this.handleViewportChange=()=>{this.closeContextMenu(),this.render()},this.handleReducedMotionChange=()=>{var c;this.prefersReducedMotion=!!((c=this.mediaQuery)!=null&&c.matches),this.prefersReducedMotion&&(this.transient=null),this.render()},this.handlePointerEnter=()=>{this.clearRestingDelayTimer(),this.isHovering=!0,this.rescheduleAnimation()},this.handlePointerLeave=()=>{this.isDragging||this.enterRestingAfterDelay()},this.handleContextMenu=c=>{c.preventDefault(),c.stopPropagation(),this.openContextMenu({x:c.clientX,y:c.clientY})},this.handleContextMenuEvent=c=>{c.preventDefault(),c.stopPropagation()},this.handleContextMenuOutsidePointerDown=c=>{const h=this.contextMenuElement;h&&c.composedPath().includes(h)||this.closeContextMenu()},this.handleContextMenuKeyDown=c=>{c.key==="Escape"&&(c.preventDefault(),this.closeContextMenu())},this.handleClosePetMenuItemClick=c=>{var h;c.preventDefault(),c.stopPropagation(),this.closeContextMenu(),(h=this.onClose)==null||h.call(this)},this.handleSummaryPointerEnter=()=>{this.isSummaryHovering=!0,this.render()},this.handleSummaryPointerLeave=()=>{this.isSummaryHovering=!1,this.isReplyOpen||this.render()},this.handleSummaryClick=()=>{var h,d;const c=(h=this.summary)==null?void 0:h.threadId.trim();c&&((d=this.onThreadSummaryActivate)==null||d.call(this,c))},this.handleSummaryDelete=()=>{const c=om(this.summary);c&&(this.dismissedSummaryKey=c),this.isSummaryCollapsed=!1,this.isReplyOpen=!1,this.replyDraft="",this.replyError=null,this.removeSummaryElements()},this.handleSummaryCollapseToggle=()=>{this.isSummaryCollapsed=!this.isSummaryCollapsed,this.isSummaryExpanded=!1,this.isReplyOpen=!1,this.replyError=null,this.render()},this.handleSummaryExpandToggle=()=>{this.isSummaryExpanded=!this.isSummaryExpanded,this.render()},this.handleReplyOpen=()=>{this.isReplyOpen=!0,this.replyError=null,this.render()},this.handleReplyInput=c=>{const h=c.currentTarget;h instanceof HTMLInputElement&&(this.replyDraft=h.value,this.replyError=null)},this.handleReplySubmit=c=>{c.preventDefault(),this.submitReply()},this.handleReplyKeyDown=c=>{c.key==="Escape"&&(c.preventDefault(),this.isReplyOpen=!1,this.replyError=null,this.render())},this.handlePointerDown=c=>{var y,v;if(c.button!==0||c.ctrlKey||(this.closeContextMenu(),!((y=this.options)!=null&&y.position.draggable)))return;c.preventDefault();const h=(v=this.petElement)==null?void 0:v.getBoundingClientRect();if(!h)return;const d={x:h.left,y:h.top};this.dragOffset={x:c.clientX-h.left,y:c.clientY-h.top},this.lastDragPosition=d,this.lastDragClientX=c.clientX,this.dragAnimation=null,this.movedDuringDrag=!1,this.dragPosition=d,this.isDragging=!0,this.clearRestingDelayTimer(),this.isHovering=!0,this.installDragListeners(),this.rescheduleAnimation()},this.handlePointerMove=c=>{const h=this.getNextDragPosition(c),d=this.lastDragPosition;if(d&&(Math.abs(d.x-h.x)>wu||Math.abs(d.y-h.y)>wu)&&(this.movedDuringDrag=!0),this.lastDragClientX!==null){const y=c.clientX-this.lastDragClientX;y>wu?this.dragAnimation="running-right":y<-wu&&(this.dragAnimation="running-left")}this.lastDragClientX=c.clientX,this.lastDragPosition=h,this.dragPosition=h,this.render()},this.handlePointerUp=c=>{const h=this.lastDragPosition??this.getNextDragPosition(c);this.isDragging=!1,this.dragPosition=null,this.dragAnimation=null,this.lastDragClientX=null,this.removeDragListeners(),this.persistPosition(h),c.pointerType==="mouse"&&this.isPointerOverPet(c)?(this.isHovering=!0,this.rescheduleAnimation()):(this.enterRestingAfterDelay(),this.rescheduleAnimation())},this.handleClick=()=>{var c;this.movedDuringDrag||((c=this.onActivate)==null||c.call(this),!this.prefersReducedMotion&&(this.transient={name:"waving"},this.render()))},this.root=u,this.onActivate=r==null?void 0:r.onActivate,this.onClose=r==null?void 0:r.onClose,this.onReply=r==null?void 0:r.onReply,this.onThreadSummaryActivate=r==null?void 0:r.onThreadSummaryActivate,this.connect()}connect(){this.connected||(this.connected=!0,this.installViewportListeners(),this.installReducedMotionListener(),this.render())}setOptions(u,r){this.closeContextMenu();const c=fi(u);if(this.options=c,this.theme=r??null,!c){this.isDragging=!1,this.isHovering=!1,this.position=null,this.dragPosition=null,this.dragAnimation=null,this.lastDragPosition=null,this.lastDragClientX=null,this.transient=null,this.resolved=null,this.clearRestingDelayTimer(),this.removeDragListeners(),this.removeOverlay();return}this.position=D0(im,c.position.persist),c.behavior==="auto"&&!this.prefersReducedMotion&&(this.transient={name:"waving"}),this.resolveCharacter(),this.render()}setState(u){var c;const r=this.lastAutoState;this.lastAutoState=u,this.currentState=u,((c=this.options)==null?void 0:c.behavior)==="auto"&&!this.prefersReducedMotion&&u==="idle"&&(r==="running"||r==="review")&&!this.transient?this.transient={name:"jumping"}:u!=="idle"&&(this.transient=null),this.render()}setLocale(u){const r=fm(u);r!==this.copyLocale&&(this.copyLocale=r,this.copy=cm[r],this.summaryRenderKey=null,this.closeContextMenu(),this.render())}setThreadSummary(u){const r=hm(this.summary),c=hm(u);if(this.summary=u,!u){this.isSummaryCollapsed=!1,this.isSummaryExpanded=!1,this.isSummaryHovering=!1,this.isReplyOpen=!1,this.isReplySubmitting=!1,this.replyError=null,this.replyDraft="",this.summaryRenderKey=null,this.removeSummaryElements();return}r!==c&&(this.isSummaryCollapsed=!1,this.isSummaryExpanded=!1,this.isSummaryHovering=!1,this.isReplyOpen=!1,this.isReplySubmitting=!1,this.replyError=null,this.replyDraft=""),this.render()}setThreadSummaryStatus(u){!this.summary||this.summary.status===u||(this.summary={...this.summary,status:u},this.render())}destroy(){var u,r,c,h;this.connected&&(this.connected=!1,this.clearRestingDelayTimer(),this.clearTimers(),this.removeDragListeners(),this.removeOverlay(),window.removeEventListener("resize",this.handleViewportChange),(u=window.visualViewport)==null||u.removeEventListener("resize",this.handleViewportChange),(r=window.visualViewport)==null||r.removeEventListener("scroll",this.handleViewportChange),(h=(c=this.mediaQuery)==null?void 0:c.removeEventListener)==null||h.call(c,"change",this.handleReducedMotionChange),this.mediaQuery=null)}installViewportListeners(){var u,r;window.addEventListener("resize",this.handleViewportChange),(u=window.visualViewport)==null||u.addEventListener("resize",this.handleViewportChange),(r=window.visualViewport)==null||r.addEventListener("scroll",this.handleViewportChange)}installReducedMotionListener(){var u,r;window.matchMedia&&(this.mediaQuery=window.matchMedia("(prefers-reduced-motion: reduce)"),this.prefersReducedMotion=this.mediaQuery.matches,(r=(u=this.mediaQuery).addEventListener)==null||r.call(u,"change",this.handleReducedMotionChange))}resolveCharacter(){if(!this.options){this.resolved=null;return}const u=this.options.character;this.resolved=T0(u)}ensureOverlay(){if(this.overlayElement&&this.petElement)return;const u=document.createElement("div");u.setAttribute("data-chatkit-host-pet-layer",""),u.style.position="fixed",u.style.inset="0",u.style.pointerEvents="none",u.style.overflow="visible";const r=document.createElement("style");r.textContent=`
|
|
51
|
-
@keyframes chatkit-pet-summary-spin {
|
|
52
|
-
to { transform: rotate(360deg); }
|
|
53
|
-
}
|
|
54
|
-
`;const c=document.createElement("div");c.setAttribute("data-chatkit-host-pet",""),c.style.position="absolute",c.style.top="0",c.style.left="0",c.style.pointerEvents="auto",c.style.touchAction="none",c.style.userSelect="none",c.style.willChange="transform",c.addEventListener("pointerenter",this.handlePointerEnter),c.addEventListener("pointerleave",this.handlePointerLeave),c.addEventListener("pointerdown",this.handlePointerDown),c.addEventListener("contextmenu",this.handleContextMenu),c.addEventListener("click",this.handleClick),u.append(r,c),this.root.append(u),this.overlayElement=u,this.petElement=c}removeOverlay(){var u;this.clearRestingDelayTimer(),this.clearTimers(),this.closeContextMenu(),this.petElement&&(this.petElement.removeEventListener("pointerenter",this.handlePointerEnter),this.petElement.removeEventListener("pointerleave",this.handlePointerLeave),this.petElement.removeEventListener("pointerdown",this.handlePointerDown),this.petElement.removeEventListener("contextmenu",this.handleContextMenu),this.petElement.removeEventListener("click",this.handleClick)),this.isHovering=!1,this.removeSummaryElements(),(u=this.overlayElement)==null||u.remove(),this.overlayElement=null,this.petElement=null,this.mediaElement=null}removeSummaryElements(){var u,r;(u=this.summaryElement)==null||u.remove(),(r=this.summaryToggleElement)==null||r.remove(),this.summaryElement=null,this.summaryToggleElement=null,this.replyInputElement=null,this.summaryRenderKey=null}getSize(){if(!this.options||!this.resolved)return{width:0,height:0};const u=rm(this.options.position.scale),r={width:this.resolved.atlas.cellWidth,height:this.resolved.atlas.cellHeight};return{width:r.width*u,height:r.height*u}}getCurrentPosition(u){const r=this.options;if(!r)return{x:0,y:0};const c=ea(),h=vr(r.position.boundsPadding),d=r.position.pin===void 0?"bottom-right":r.position.pin,y=d?A0(d,u,c,h):null;return Ue(this.dragPosition??this.position??y??{x:h.left,y:h.top},u,c,h)}persistPosition(u){if(!this.options)return;const r=this.getSize(),c=Ue(u,r,ea(),vr(this.options.position.boundsPadding));this.position=c,R0(im,this.options.position.persist,c)}getActiveAnimationName(){return this.options?this.isDragging?this.dragAnimation??"running":this.transient?this.transient.name:this.options.behavior==="manual"?"idle":this.currentState:"idle"}getActiveAnimationMode(){return this.isDragging?"loop":this.transient?"once":"loop"}resetAnimationIfNeeded(u,r){this.activeAnimationName===u&&this.activeAnimationMode===r||(this.clearTimers(),this.activeAnimationName=u,this.activeAnimationMode=r,this.frame=0,this.completed=!1)}render(){if(!this.options||!this.resolved){this.clearTimers(),this.petElement&&this.petElement.replaceChildren(),this.removeSummaryElements(),this.mediaElement=null,this.activeAnimationName=null,this.activeAnimationMode=null,this.frame=0,this.completed=!1;return}this.ensureOverlay();const u=this.overlayElement,r=this.petElement;if(!u||!r)return;const c=this.getSize(),h=this.getCurrentPosition(c),d=this.getActiveAnimationName(),y=this.getActiveAnimationMode();this.resetAnimationIfNeeded(d,y),u.style.zIndex=String(this.options.position.zIndex),r.style.width=`${c.width}px`,r.style.height=`${c.height}px`,r.style.transform=`translate3d(${h.x}px, ${h.y}px, 0)`,r.style.cursor=this.options.position.draggable?this.isDragging?"grabbing":"grab":"default",r.dataset.petAnimation=d,r.setAttribute("aria-label",this.options.ariaLabel),r.setAttribute("role","img"),this.renderAtlas(d,y),this.renderThreadSummary(h,c),this.scheduleNextFrame(d,y)}renderThreadSummary(u,r){var y,v,E;const c=this.summary,h=om(c);if(!c||!h||this.dismissedSummaryKey===h){this.removeSummaryElements();return}if(this.isSummaryCollapsed){this.renderCollapsedSummary(u,r);return}const d=[this.copyLocale,this.isSummaryExpanded?"expanded":"compact",this.isSummaryHovering?"hover":"rest",this.isReplyOpen?"reply":"closed",this.isReplySubmitting?"submitting":"ready",this.replyError??""].join("|");(!this.summaryElement||this.summaryRenderKey!==d)&&((y=this.summaryElement)==null||y.remove(),(v=this.summaryToggleElement)==null||v.remove(),this.summaryElement=this.createSummaryBubble(c),this.summaryToggleElement=this.createSummaryToggleButton("v"),(E=this.overlayElement)==null||E.append(this.summaryElement,this.summaryToggleElement),this.summaryRenderKey=d,this.isReplyOpen&&!this.isReplySubmitting&&window.setTimeout(()=>{var b;return(b=this.replyInputElement)==null?void 0:b.focus()},0)),this.updateSummaryBubbleContent(c),this.positionSummaryBubble(u,r)}renderCollapsedSummary(u,r){var c,h;(c=this.summaryElement)==null||c.remove(),this.summaryElement=null,this.summaryRenderKey=null,this.summaryToggleElement||(this.summaryToggleElement=this.createSummaryToggleButton("1"),(h=this.overlayElement)==null||h.append(this.summaryToggleElement)),this.summaryToggleElement.textContent="1",this.positionSummaryToggleBadge(u,r)}positionSummaryToggleBadge(u,r){const c=this.summaryToggleElement;if(!c)return;const h=ea(),d=ii(this.theme).toggleSize,y=Gl(u.x+r.width-d*.35,Je,h.width-d-Je),v=Gl(u.y-d*.35,Je,h.height-d-Je);c.style.width=`${d}px`,c.style.height=`${d}px`,c.style.transform=`translate3d(${y}px, ${v}px, 0)`,c.style.borderRadius="999px"}positionSummaryBubble(u,r){const c=this.summaryElement,h=this.summaryToggleElement;if(!c||!h)return;const d=ea(),y=Math.min(C0,d.width-Je*2);c.style.width=`${y}px`;const v=c.offsetHeight||96,E=u.y-v-sm,N=E>=Je?E:Gl(u.y+r.height+sm,Je,d.height-v-Je),U=Gl(u.x+r.width/2-y/2,Je,d.width-y-Je);c.style.transform=`translate3d(${U}px, ${N}px, 0)`,this.positionSummaryToggleBadge(u,r)}createSummaryBubble(u){const r=this.isSummaryHovering&&!this.isReplyOpen,c=ii(this.theme),h=document.createElement("div");h.setAttribute("data-chatkit-pet-summary",""),h.addEventListener("pointerenter",this.handleSummaryPointerEnter),h.addEventListener("pointerleave",this.handleSummaryPointerLeave),h.addEventListener("click",this.handleSummaryClick),h.style.position="absolute",h.style.top="0",h.style.left="0",h.style.boxSizing="border-box",h.style.pointerEvents="auto",h.style.padding=c.padding,h.style.border="1px solid rgba(148, 163, 184, 0.22)",h.style.borderRadius=`${c.radius}px`,h.style.background="rgba(255, 255, 255, 0.94)",h.style.color="#1f2937",h.style.boxShadow="0 8px 24px rgba(15, 23, 42, 0.1)",h.style.font=`500 ${c.bodySize}px/1.35 ${c.fontFamily}`,h.style.backdropFilter="blur(10px)";const d=document.createElement("div");d.style.display="flex",d.style.alignItems="center",d.style.gap=`${c.gap}px`,(this.isSummaryHovering||this.isReplyOpen)&&d.append(this.createSummaryActionButton("x",this.copy.hideMessage,this.handleSummaryDelete));const y=document.createElement("div");y.textContent=u.title,y.style.minWidth="0",y.style.flex="1",y.style.overflow="hidden",y.style.textOverflow="ellipsis",y.style.whiteSpace="nowrap",y.style.fontWeight="700",y.style.fontSize=`${c.titleSize}px`,y.dataset.chatkitPetSummaryTitle="",d.append(y),this.isSummaryHovering||this.isReplyOpen?d.append(this.createSummaryActionButton(this.isSummaryExpanded?"-":">",this.isSummaryExpanded?this.copy.collapseMessage:this.copy.expandMessage,this.handleSummaryExpandToggle)):d.append(this.createStatusIcon(u.status));const v=document.createElement("div");if(v.textContent=u.message,v.style.marginTop=`${c.marginTop}px`,v.style.fontWeight="400",v.style.color="#374151",v.style.overflow="hidden",this.isSummaryExpanded?(v.style.maxHeight="7em",v.style.overflowY="auto"):(v.style.display="-webkit-box",v.style.setProperty("-webkit-line-clamp","2"),v.style.setProperty("-webkit-box-orient","vertical")),v.dataset.chatkitPetSummaryMessage="",h.append(d,v),r){const E=this.createTextButton(this.copy.replyButton,this.handleReplyOpen);E.style.position="absolute",E.style.right="14px",E.style.bottom="10px",h.append(E)}return this.isReplyOpen&&h.append(this.createReplyForm()),h}updateSummaryBubbleContent(u){var d,y,v;const r=(d=this.summaryElement)==null?void 0:d.querySelector("[data-chatkit-pet-summary-title]");r&&r.textContent!==u.title&&(r.textContent=u.title);const c=(y=this.summaryElement)==null?void 0:y.querySelector("[data-chatkit-pet-summary-message]");c&&c.textContent!==u.message&&(c.textContent=u.message);const h=(v=this.summaryElement)==null?void 0:v.querySelector("[data-chatkit-pet-summary-status]");if(h&&h.dataset.chatkitPetSummaryStatus!==u.status){const E=this.createStatusIcon(u.status);h.replaceWith(E)}}createSummaryToggleButton(u){const r=ii(this.theme),c=document.createElement("button");return c.type="button",c.textContent=u,c.title=u==="1"?this.copy.restoreMessage:this.copy.collapseMessage,c.addEventListener("click",Hu),c.addEventListener("click",this.handleSummaryCollapseToggle),c.style.position="absolute",c.style.top="0",c.style.left="0",c.style.pointerEvents="auto",c.style.border="1px solid rgba(148, 163, 184, 0.28)",c.style.background="rgba(248, 250, 252, 0.94)",c.style.color="#475569",c.style.boxShadow="0 6px 18px rgba(15, 23, 42, 0.1)",c.style.cursor="pointer",c.style.font=`600 ${r.titleSize}px/1 ${r.fontFamily}`,c.style.display="flex",c.style.alignItems="center",c.style.justifyContent="center",c}createStatusIcon(u){const c=ii(this.theme).iconSize,h=document.createElement("span");if(h.setAttribute("aria-hidden","true"),h.dataset.chatkitPetSummaryStatus=u,h.style.display="inline-flex",h.style.width=`${c}px`,h.style.height=`${c}px`,h.style.alignItems="center",h.style.justifyContent="center",h.style.flex="0 0 auto",u==="running")return h.style.border="2px solid rgba(71, 85, 105, 0.32)",h.style.borderTopColor="#64748b",h.style.borderRadius="999px",h.style.animation="chatkit-pet-summary-spin 900ms linear infinite",h;if(h.style.borderRadius="999px",h.style.fontSize=`${Math.max(10,c-4)}px`,h.style.fontWeight="700",u==="failed")return h.textContent="!",h.style.background="#fee2e2",h.style.color="#b91c1c",h;h.textContent="",h.style.border="2px solid #22c55e",h.style.position="relative";const d=document.createElement("span");return d.style.width=`${Math.round(c*.44)}px`,d.style.height=`${Math.round(c*.25)}px`,d.style.borderLeft="2px solid #22c55e",d.style.borderBottom="2px solid #22c55e",d.style.transform="rotate(-45deg) translate(1px, -1px)",h.append(d),h}createSummaryActionButton(u,r,c){const h=ii(this.theme),d=document.createElement("button");return d.type="button",d.textContent=u,d.title=r,d.addEventListener("click",y=>{y.preventDefault(),y.stopPropagation(),c()}),d.style.width=`${h.actionSize}px`,d.style.height=`${h.actionSize}px`,d.style.border="0",d.style.borderRadius="999px",d.style.background="rgba(241, 245, 249, 0.96)",d.style.color="#475569",d.style.cursor="pointer",d.style.font=`600 ${h.titleSize}px/1 ${h.fontFamily}`,d}createTextButton(u,r){const c=document.createElement("button");return c.type="button",c.textContent=u,c.addEventListener("click",h=>{h.preventDefault(),h.stopPropagation(),r()}),c.style.border="1px solid rgba(148, 163, 184, 0.28)",c.style.borderRadius="999px",c.style.background="rgba(248, 250, 252, 0.95)",c.style.color="#334155",c.style.cursor="pointer",c.style.padding="3px 10px",c.style.font='600 12px/1.4 system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif',c}createReplyForm(){const u=document.createElement("form");u.addEventListener("click",Hu),u.addEventListener("submit",this.handleReplySubmit),u.addEventListener("keydown",this.handleReplyKeyDown),u.style.display="flex",u.style.gap="6px",u.style.alignItems="center",u.style.marginTop="8px";const r=document.createElement("input");r.type="text",r.value=this.replyDraft,r.disabled=this.isReplySubmitting,r.placeholder=this.copy.replyPlaceholder,r.addEventListener("input",this.handleReplyInput),r.style.minWidth="0",r.style.flex="1",r.style.border="1px solid rgba(148, 163, 184, 0.35)",r.style.borderRadius="999px",r.style.padding="6px 10px",r.style.font='400 13px/1.2 system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif',this.replyInputElement=r;const c=document.createElement("button");if(c.type="submit",c.textContent=this.isReplySubmitting?this.copy.sendingButton:this.copy.sendButton,c.disabled=this.isReplySubmitting,c.style.border="0",c.style.borderRadius="999px",c.style.background="#22c55e",c.style.color="#052e16",c.style.cursor=this.isReplySubmitting?"default":"pointer",c.style.padding="6px 10px",c.style.font='700 12px/1.2 system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif',u.append(r,c),this.replyError){const h=document.createElement("div");h.textContent=this.copy.sendFailed,h.style.flexBasis="100%",h.style.color="#b91c1c",h.style.fontSize="12px",u.style.flexWrap="wrap",u.append(h)}return u}createContextMenu(){const u=document.createElement("div");u.setAttribute("data-chatkit-pet-context-menu",""),u.setAttribute("role","menu"),u.addEventListener("contextmenu",this.handleContextMenuEvent),u.addEventListener("pointerdown",Hu),u.addEventListener("click",Hu),u.style.position="absolute",u.style.top="0",u.style.left="0",u.style.boxSizing="border-box",u.style.minWidth="132px",u.style.padding="4px",u.style.pointerEvents="auto",u.style.border="1px solid rgba(148, 163, 184, 0.28)",u.style.borderRadius="10px",u.style.background="rgba(255, 255, 255, 0.96)",u.style.color="#1f2937",u.style.boxShadow="0 12px 28px rgba(15, 23, 42, 0.16)",u.style.font='500 13px/1.3 system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif',u.style.backdropFilter="blur(10px)";const r=document.createElement("button");return r.type="button",r.textContent=this.copy.closePetMenuItem,r.setAttribute("role","menuitem"),r.addEventListener("click",this.handleClosePetMenuItemClick),r.style.display="block",r.style.width="100%",r.style.border="0",r.style.borderRadius="7px",r.style.background="transparent",r.style.color="inherit",r.style.cursor="pointer",r.style.padding="7px 10px",r.style.textAlign="left",r.style.font="inherit",u.append(r),u}openContextMenu(u){var h;const r=this.overlayElement;if(!r)return;this.closeContextMenu();const c=this.createContextMenu();r.append(c),this.contextMenuElement=c,this.positionContextMenu(u),(h=c.querySelector("button"))==null||h.focus({preventScroll:!0}),window.addEventListener("pointerdown",this.handleContextMenuOutsidePointerDown,!0),window.addEventListener("keydown",this.handleContextMenuKeyDown)}closeContextMenu(){var u;(u=this.contextMenuElement)==null||u.remove(),this.contextMenuElement=null,window.removeEventListener("pointerdown",this.handleContextMenuOutsidePointerDown,!0),window.removeEventListener("keydown",this.handleContextMenuKeyDown)}positionContextMenu(u){const r=this.contextMenuElement;if(!r)return;const c=ea(),h=r.offsetWidth||132,d=r.offsetHeight||40,y=Math.max(ta,c.width-h-ta),v=Math.max(ta,c.height-d-ta),E=Gl(u.x,ta,y),b=Gl(u.y,ta,v);r.style.transform=`translate3d(${E}px, ${b}px, 0)`}renderAtlas(u,r){var W;if(!this.petElement||((W=this.resolved)==null?void 0:W.kind)!=="atlas"||!this.options)return;if(!(this.mediaElement instanceof HTMLDivElement)){const st=document.createElement("div");st.setAttribute("aria-hidden","true"),this.petElement.replaceChildren(st),this.mediaElement=st}const c=this.mediaElement,h=this.resolved.atlas,d=h.animations[u]??h.animations.idle,y=r==="once"&&this.completed?Math.max(0,d.frames-1):Math.min(this.frame,Math.max(0,d.frames-1)),v=rm(this.options.position.scale),E=h.cellWidth,b=h.cellHeight,N=h.columns*E,U=h.rows*b;c.style.width=`${E}px`,c.style.height=`${b}px`,c.style.overflow="hidden",c.style.transform=`scale(${v})`,c.style.transformOrigin="top left",c.style.pointerEvents="none",c.style.backgroundImage=`url("${U0(this.resolved.src)}")`,c.style.backgroundRepeat="no-repeat",c.style.backgroundSize=`${N}px ${U}px`,c.style.backgroundPosition=`${-y*E}px ${-d.row*b}px`,c.style.imageRendering=this.options.imageRendering,c.dataset.petFrame=String(y)}scheduleNextFrame(u,r){if(this.prefersReducedMotion||this.completed||!this.resolved){this.clearTimers();return}if(this.frameTimer!==null)return;const c=this.resolved.atlas,h=c.animations[u]??c.animations.idle,y=(h.frameDurations[this.frame]??h.frameDurations[h.frameDurations.length-1]??150)*x0,v=this.isHovering||this.isDragging?y:y*M0;this.frameTimer=window.setTimeout(()=>{this.frameTimer=null;const E=this.frame+1;if(E>=h.frames){if(r==="once"){this.completed=!0,this.frame=Math.max(0,h.frames-1),this.finishTransient();return}this.frame=0,this.render();return}this.frame=E,this.render()},v)}clearTimers(){this.frameTimer!==null&&(window.clearTimeout(this.frameTimer),this.frameTimer=null)}clearRestingDelayTimer(){this.restingDelayTimer!==null&&(window.clearTimeout(this.restingDelayTimer),this.restingDelayTimer=null)}finishTransient(){this.transient=null,this.activeAnimationName=null,this.activeAnimationMode=null,this.render()}rescheduleAnimation(){this.clearTimers(),this.render()}enterRestingAfterDelay(){this.clearRestingDelayTimer(),this.isHovering=!0,this.restingDelayTimer=window.setTimeout(()=>{this.restingDelayTimer=null,!this.isDragging&&(this.isHovering=!1,this.rescheduleAnimation())},z0)}isPointOverPet(u,r){var h;const c=(h=this.petElement)==null?void 0:h.getBoundingClientRect();return c?u>=c.left&&u<=c.right&&r>=c.top&&r<=c.bottom:!1}isPointerOverPet(u){return this.isPointOverPet(u.clientX,u.clientY)}async submitReply(){var r;const u=this.replyDraft.trim();if(!(!u||this.isReplySubmitting)){this.isReplySubmitting=!0,this.replyError=null,this.render();try{await((r=this.onReply)==null?void 0:r.call(this,u)),this.replyDraft="",this.isReplyOpen=!1,this.isSummaryHovering=!1}catch{this.replyError="Failed to send"}finally{this.isReplySubmitting=!1,this.render()}}}getNextDragPosition(u){return this.options?Ue({x:u.clientX-this.dragOffset.x,y:u.clientY-this.dragOffset.y},this.getSize(),ea(),vr(this.options.position.boundsPadding)):{x:0,y:0}}installDragListeners(){window.addEventListener("pointermove",this.handlePointerMove),window.addEventListener("pointerup",this.handlePointerUp,{once:!0}),window.addEventListener("pointercancel",this.handlePointerUp,{once:!0})}removeDragListeners(){window.removeEventListener("pointermove",this.handlePointerMove),window.removeEventListener("pointerup",this.handlePointerUp),window.removeEventListener("pointercancel",this.handlePointerUp)}}var Q0=Object.create,_m=Object.defineProperty,K0=Object.getOwnPropertyDescriptor,xm=(s,u)=>(u=Symbol[s])?u:Symbol.for("Symbol."+s),Qu=s=>{throw TypeError(s)},V0=(s,u,r)=>u in s?_m(s,u,{enumerable:!0,configurable:!0,writable:!0,value:r}):s[u]=r,Z0=s=>[,,,Q0((s==null?void 0:s[xm("metadata")])??null)],Mm=["class","method","getter","setter","accessor","field","value","get","set"],zm=s=>s!==void 0&&typeof s!="function"?Qu("Function expected"):s,J0=(s,u,r,c,h)=>({kind:Mm[s],name:u,metadata:c,addInitializer:d=>r._?Qu("Already initialized"):h.push(zm(d||null))}),k0=(s,u)=>V0(u,xm("metadata"),s[3]),W0=(s,u,r,c)=>{for(var h=0,d=s[u>>1],y=d&&d.length;h<y;h++)d[h].call(r);return c},Ye=(s,u,r,c,h,d)=>{for(var y,v,E,b,N=u&7,U=!1,W=!1,st=2,St=Mm[N+5],it=s[st]||(s[st]=[]),Mt=(h=h.prototype,K0(h,r)),bt=c.length-1;bt>=0;bt--)E=J0(N,r,v={},s[3],it),E.static=U,E.private=W,b=E.access={has:wt=>r in wt},b.get=wt=>wt[r],y=(0,c[bt])(Mt[St],E),v._=1,zm(y)&&(Mt[St]=y);return Mt&&_m(h,r,Mt),h},Rr=(s,u,r)=>u.has(s)||Qu("Cannot "+r),R=(s,u,r)=>(Rr(s,u,"read from private field"),r?r.call(s):u.get(s)),Qt=(s,u,r)=>u.has(s)?Qu("Cannot add the same private member more than once"):u instanceof WeakSet?u.add(s):u.set(s,r),Ft=(s,u,r,c)=>(Rr(s,u,"write to private field"),u.set(s,r),r),Q=(s,u,r)=>(Rr(s,u,"access private method"),r),Cm,Om,Dm,Rm,Um,wm,Hm,Nm,Bm,Lm,jm,xr,xt,Kl,ml,yl,Bu,Ur,Ku,ia,dn,ke,we,Lu,Wt,pt,X,la,wr,gl,Vu,qm,Zu,Ym,Xm,Hr,Vl,oi,Mr,Gm,Qm,Km,Vm,ju,Zm,Jm,km,qu,ua,zr,fe;function Wm(s){return _r(s)}function je(s,u){const r=String(u.name);return function(...c){if(!this.capabilities.commands.has(r))throw new qe(`ChatKit command "${String(r)}" is not available for the "${this.profile}" profile.`);return s.apply(this,c)}}class Ee extends(xr=HTMLElement,jm=[je],Lm=[je],Bm=[je],Nm=[je],Hm=[je],wm=[je],Um=[je],Rm=[je],Dm=[je],Om=[je],Cm=[je],xr){constructor({profile:u}){super(),W0(fe,5,this),Qt(this,X),this.profile=void 0,this.capabilities=void 0,Qt(this,xt),Qt(this,Kl),Qt(this,ml),Qt(this,yl),Qt(this,Bu),Qt(this,Ur,!1),Qt(this,Ku,!1),Qt(this,ia),Qt(this,dn,!1),Qt(this,ke,this.attachShadow({mode:"open"})),Qt(this,we,new G0(R(this,ke),{onActivate:()=>Q(this,X,Gm).call(this),onClose:()=>Q(this,X,Qm).call(this),onReply:r=>Q(this,X,Km).call(this,r),onThreadSummaryActivate:r=>void Q(this,X,Vm).call(this,r)})),Qt(this,Lu),Qt(this,Wt,new Promise(r=>{Ft(this,Lu,r)})),Qt(this,pt,new g0({fetch:((...r)=>{var h;const c=((h=R(this,xt))==null?void 0:h.api)&&"fetch"in R(this,xt).api&&R(this,xt).api.fetch;return c?c(...r):fetch(...r)}),target:()=>{var r;return((r=R(this,ml))==null?void 0:r.contentWindow)??null},targetOrigin:window.location.origin,handlers:{onFileInputClick:({inputAttributes:r})=>new Promise(c=>{const h=document.createElement("input");for(const[y,v]of Object.entries(r))h.setAttribute(y,String(v));const d=()=>{c(Array.from(h.files||[])),R(this,ke).contains(h)&&R(this,ke).removeChild(h)};h.addEventListener("cancel",d),h.addEventListener("change",d),R(this,ke).appendChild(h),h.click()}),onClientToolCall:async({name:r,params:c,id:h,tool_call_id:d})=>{var v;const y=(v=R(this,xt))==null?void 0:v.onClientTool;return y||Q(this,X,la).call(this,new qe("No handler for client tool calls. You'll need to add onClientTool to your ChatKit options.")),y({name:r,params:c,id:h,tool_call_id:d})},onWidgetAction:async({action:r,widgetItem:c})=>{var d,y;const h=(y=(d=R(this,xt))==null?void 0:d.widgets)==null?void 0:y.onAction;return h||Q(this,X,la).call(this,new qe("No handler for widget actions. You'll need to add widgets.onAction to your ChatKit options.")),h(r,c)},onEntitySearch:async({query:r})=>{var c,h,d;return((d=(h=(c=R(this,xt))==null?void 0:c.entities)==null?void 0:h.onTagSearch)==null?void 0:d.call(h,r))??[]},onEntityClick:async({entity:r})=>{var c,h,d;return(d=(h=(c=R(this,xt))==null?void 0:c.entities)==null?void 0:h.onClick)==null?void 0:d.call(h,r)},onEntityPreview:async({entity:r})=>{var c,h,d;return((d=(h=(c=R(this,xt))==null?void 0:c.entities)==null?void 0:h.onRequestPreview)==null?void 0:d.call(h,r))??{preview:null}},onGetClientSecret:async r=>((!R(this,xt)||!("getClientSecret"in R(this,xt).api)||!R(this,xt).api.getClientSecret)&&Q(this,X,la).call(this,new qe("Could not refresh the session because ChatKitOptions.api.getClientSecret is not configured.")),R(this,xt).api.getClientSecret(r??null)),onAddMetadataToRequest:({op:r,params:c})=>{throw new qe("ChatKit: onAddMetadataToRequest is unimplemented.")}}})),Qt(this,ju,()=>{Q(this,X,Vl).call(this,!1)}),Qt(this,qu,()=>{var r;this.dataset.loaded="true",this.dispatchEvent(new CustomEvent("chatkit.ready",{bubbles:!0,composed:!0})),(r=R(this,Lu))==null||r.call(this)}),Qt(this,ua,!1),this.profile=u,this.capabilities=am(u)}setProfile(u){this.profile=u,this.capabilities=am(u)}connectedCallback(){R(this,we).connect();const u=document.createElement("style");u.textContent=`
|
|
55
|
-
:host {
|
|
56
|
-
display: block;
|
|
57
|
-
position: relative;
|
|
58
|
-
height: 100%;
|
|
59
|
-
width: 100%;
|
|
60
|
-
overflow: visible;
|
|
61
|
-
}
|
|
62
|
-
:host([data-display-mode="pet"]) {
|
|
63
|
-
display: contents;
|
|
64
|
-
}
|
|
65
|
-
:host([data-chat-minimized-to-pet="true"]) {
|
|
66
|
-
display: contents;
|
|
67
|
-
}
|
|
68
|
-
.ck-iframe {
|
|
69
|
-
border: none;
|
|
70
|
-
position: absolute;
|
|
71
|
-
inset: 0;
|
|
72
|
-
width: 100%;
|
|
73
|
-
height: 100%;
|
|
74
|
-
overflow: hidden;
|
|
75
|
-
color-scheme: light only;
|
|
76
|
-
}
|
|
77
|
-
.ck-wrapper {
|
|
78
|
-
position: absolute;
|
|
79
|
-
inset: 0;
|
|
80
|
-
width: 100%;
|
|
81
|
-
height: 100%;
|
|
82
|
-
overflow: hidden;
|
|
83
|
-
opacity: 0;
|
|
84
|
-
}
|
|
85
|
-
.ck-launcher-close {
|
|
86
|
-
display: none;
|
|
87
|
-
}
|
|
88
|
-
:host([data-display-mode="pet"]) .ck-wrapper {
|
|
89
|
-
position: fixed;
|
|
90
|
-
inset: auto 16px 16px auto;
|
|
91
|
-
width: min(420px, calc(100vw - 32px));
|
|
92
|
-
height: min(720px, calc(100vh - 32px));
|
|
93
|
-
max-height: calc(100vh - 32px);
|
|
94
|
-
overflow: visible;
|
|
95
|
-
border: 1px solid rgba(148, 163, 184, 0.35);
|
|
96
|
-
border-radius: 18px;
|
|
97
|
-
background: Canvas;
|
|
98
|
-
box-shadow:
|
|
99
|
-
0 24px 80px rgba(15, 23, 42, 0.22),
|
|
100
|
-
0 0 0 1px rgba(15, 23, 42, 0.04);
|
|
101
|
-
opacity: 0;
|
|
102
|
-
pointer-events: none;
|
|
103
|
-
transform: translateY(12px) scale(0.98);
|
|
104
|
-
transition:
|
|
105
|
-
opacity 160ms ease,
|
|
106
|
-
transform 160ms ease;
|
|
107
|
-
z-index: 39;
|
|
108
|
-
}
|
|
109
|
-
:host([data-display-mode="pet"][data-chat-open="true"]) .ck-wrapper {
|
|
110
|
-
opacity: 1;
|
|
111
|
-
pointer-events: auto;
|
|
112
|
-
transform: translateY(0) scale(1);
|
|
113
|
-
}
|
|
114
|
-
:host([data-display-mode="pet"]) .ck-iframe {
|
|
115
|
-
border-radius: inherit;
|
|
116
|
-
}
|
|
117
|
-
:host([data-display-mode="pet"]) .ck-launcher-close {
|
|
118
|
-
display: inline-flex;
|
|
119
|
-
position: absolute;
|
|
120
|
-
top: -10px;
|
|
121
|
-
right: -10px;
|
|
122
|
-
z-index: 2;
|
|
123
|
-
width: 28px;
|
|
124
|
-
height: 28px;
|
|
125
|
-
align-items: center;
|
|
126
|
-
justify-content: center;
|
|
127
|
-
border: 1px solid rgba(148, 163, 184, 0.45);
|
|
128
|
-
border-radius: 999px;
|
|
129
|
-
background: rgba(255, 255, 255, 0.96);
|
|
130
|
-
color: #475569;
|
|
131
|
-
box-shadow: 0 8px 24px rgba(15, 23, 42, 0.18);
|
|
132
|
-
cursor: pointer;
|
|
133
|
-
font: inherit;
|
|
134
|
-
font-size: 0;
|
|
135
|
-
line-height: 1;
|
|
136
|
-
}
|
|
137
|
-
:host([data-display-mode="pet"]) .ck-launcher-close::before,
|
|
138
|
-
:host([data-display-mode="pet"]) .ck-launcher-close::after {
|
|
139
|
-
content: '';
|
|
140
|
-
position: absolute;
|
|
141
|
-
top: 50%;
|
|
142
|
-
left: 50%;
|
|
143
|
-
width: 14px;
|
|
144
|
-
height: 2px;
|
|
145
|
-
border-radius: 999px;
|
|
146
|
-
background: currentColor;
|
|
147
|
-
transform: translate(-50%, -50%) rotate(45deg);
|
|
148
|
-
}
|
|
149
|
-
:host([data-display-mode="pet"]) .ck-launcher-close::after {
|
|
150
|
-
transform: translate(-50%, -50%) rotate(-45deg);
|
|
151
|
-
}
|
|
152
|
-
:host([data-display-mode="pet"]) .ck-launcher-close:hover {
|
|
153
|
-
background: #fff;
|
|
154
|
-
color: #0f172a;
|
|
155
|
-
}
|
|
156
|
-
:host([data-color-scheme="dark"]) .ck-iframe {
|
|
157
|
-
color-scheme: dark only;
|
|
158
|
-
}
|
|
159
|
-
:host([data-color-scheme="dark"][data-display-mode="pet"]) .ck-wrapper {
|
|
160
|
-
border-color: rgba(148, 163, 184, 0.28);
|
|
161
|
-
background: #020617;
|
|
162
|
-
box-shadow:
|
|
163
|
-
0 24px 80px rgba(0, 0, 0, 0.5),
|
|
164
|
-
0 0 0 1px rgba(255, 255, 255, 0.06);
|
|
165
|
-
}
|
|
166
|
-
:host([data-color-scheme="dark"][data-display-mode="pet"]) .ck-launcher-close {
|
|
167
|
-
background: rgba(15, 23, 42, 0.88);
|
|
168
|
-
border-color: rgba(148, 163, 184, 0.32);
|
|
169
|
-
color: #cbd5e1;
|
|
170
|
-
}
|
|
171
|
-
:host([data-color-scheme="dark"][data-display-mode="pet"]) .ck-launcher-close:hover {
|
|
172
|
-
background: #1e293b;
|
|
173
|
-
color: #f8fafc;
|
|
174
|
-
}
|
|
175
|
-
:host([data-loaded="true"]) .ck-wrapper {
|
|
176
|
-
opacity: 1;
|
|
177
|
-
}
|
|
178
|
-
:host([data-chat-minimized-to-pet="true"]) .ck-wrapper {
|
|
179
|
-
opacity: 0;
|
|
180
|
-
pointer-events: none;
|
|
181
|
-
visibility: hidden;
|
|
182
|
-
}
|
|
183
|
-
:host([data-display-mode="pet"]:not([data-chat-open="true"])) .ck-wrapper {
|
|
184
|
-
opacity: 0;
|
|
185
|
-
}
|
|
186
|
-
@media (max-width: 520px) {
|
|
187
|
-
:host([data-display-mode="pet"]) .ck-wrapper {
|
|
188
|
-
inset: auto 8px 8px 8px;
|
|
189
|
-
width: auto;
|
|
190
|
-
height: min(680px, calc(100vh - 16px));
|
|
191
|
-
max-height: calc(100vh - 16px);
|
|
192
|
-
border-radius: 16px;
|
|
193
|
-
}
|
|
194
|
-
:host([data-display-mode="pet"]) .ck-launcher-close {
|
|
195
|
-
top: -8px;
|
|
196
|
-
right: 8px;
|
|
197
|
-
}
|
|
198
|
-
}
|
|
199
|
-
`;const r=document.createElement("iframe");r.className="ck-iframe",r.name="chatkit",r.role="presentation",r.tabIndex=0,r.setAttribute("allowtransparency","true"),r.setAttribute("frameborder","0"),r.setAttribute("scrolling","no"),r.setAttribute("allow","clipboard-read; clipboard-write"),Ft(this,ml,r);const c=document.createElement("div");c.className="ck-wrapper",c.appendChild(r),Ft(this,yl,c);const h=document.createElement("button");h.className="ck-launcher-close",h.type="button",h.setAttribute("aria-label","Close chat"),h.addEventListener("click",R(this,ju)),c.appendChild(h),Ft(this,Bu,h),R(this,ke).append(u),R(this,pt).on("left_header_icon_click",()=>{var d,y,v;(v=(y=(d=R(this,xt))==null?void 0:d.header)==null?void 0:y.leftAction)==null||v.onClick()}),R(this,pt).on("right_header_icon_click",()=>{var d,y,v;(v=(y=(d=R(this,xt))==null?void 0:d.header)==null?void 0:y.rightAction)==null||v.onClick()}),R(this,pt).on("public_event",([d,y])=>{if(d==="log"){const v=X0(y);v&&R(this,we).setThreadSummary(v.summary)}else d==="response.start"?R(this,we).setThreadSummaryStatus("running"):d==="response.end"?R(this,we).setThreadSummaryStatus("completed"):d==="response.stop"&&R(this,we).setThreadSummaryStatus("completed");if(this.capabilities.events.has(d)){if(d==="error"&&"error"in y){const v=h0(y.error);if(this.dispatchEvent(new CustomEvent("chatkit.error",{detail:{error:v}})),v instanceof qe)throw v;return}this.dispatchEvent(new CustomEvent(`chatkit.${d}`,{detail:y}))}}),R(this,pt).on("pet_state_change",d=>{const y=L0(d);y&&R(this,we).setState(y.state)}),R(this,pt).on("pet_options_change",d=>{const y=j0(d);y&&((!R(this,dn)||y.pet===null)&&Ft(this,dn,!1),Ft(this,ia,y.pet),Q(this,X,Mr).call(this))}),R(this,pt).on("chat_minimize_change",d=>{const y=typeof d=="object"&&d!==null&&"minimized"in d&&d.minimized===!0;y&&!Q(this,X,Zu).call(this)||(Q(this,X,oi).call(this,y),y&&Q(this,X,Vl).call(this,!1))}),R(this,pt).on("unmount",()=>{R(this,yl)&&R(this,ke).contains(R(this,yl))&&(R(this,ke).removeChild(R(this,yl)),Ft(this,yl,void 0),Ft(this,ml,void 0))}),R(this,pt).on("capabilities_profile_change",({profile:d})=>{this.setProfile(d)}),r.addEventListener("load",R(this,qu),{once:!0});try{Q(this,X,zr).call(this)}catch(d){console.error(d),Q(this,X,la).call(this,d instanceof Error?d:new qe("Failed to initialize ChatKit"))}}disconnectedCallback(){var u,r;(u=R(this,ml))==null||u.removeEventListener("load",R(this,qu)),(r=R(this,Bu))==null||r.removeEventListener("click",R(this,ju)),R(this,pt).disconnect(),R(this,we).destroy()}applySanitizedOptions(u){Ft(this,xt,u),Ft(this,dn,!1),R(this,we).setLocale(u.locale),Q(this,X,Mr).call(this),R(this,ua)?(Q(this,X,wr).call(this,R(this,xt)),R(this,Wt).then(()=>{R(this,pt).commands.setOptions(Wm(Q(this,X,Hr).call(this,u)))})):Q(this,X,zr).call(this)}setOptions(u){try{const r=this.sanitizeOptions(u);Q(this,X,km).call(this,r),this.applySanitizedOptions(r)}catch(r){Q(this,X,la).call(this,r instanceof Error?r:new qe("Failed to parse options"))}}async focusComposer(){var u,r;await R(this,Wt),(u=R(this,ml))==null||u.focus(),await((r=R(this,pt))==null?void 0:r.commands.focusComposer())}async fetchUpdates(){var u;await R(this,Wt),await((u=R(this,pt))==null?void 0:u.commands.fetchUpdates())}async sendUserMessage(u){var r;await R(this,Wt),await((r=R(this,pt))==null?void 0:r.commands.sendUserMessage(u))}async setComposerValue(u){var r;await R(this,Wt),await((r=R(this,pt))==null?void 0:r.commands.setComposerValue(u))}async setRuntimeCapabilities(u){var r;await R(this,Wt),await((r=R(this,pt))==null?void 0:r.commands.setRuntimeCapabilities(u))}async setThreadId(u){var r;await R(this,Wt),await((r=R(this,pt))==null?void 0:r.commands.setThreadId({threadId:u}))}async shareThread(){var u;return await R(this,Wt),(u=R(this,pt))==null?void 0:u.commands.shareThread()}async sendCustomAction(u,r){var c;return await R(this,Wt),(c=R(this,pt))==null?void 0:c.commands.sendCustomAction({action:u,itemId:r})}async showHistory(){var u;return await R(this,Wt),(u=R(this,pt))==null?void 0:u.commands.showHistory()}async hideHistory(){var u;return await R(this,Wt),(u=R(this,pt))==null?void 0:u.commands.hideHistory()}async setTrainingOptOut(u){var r;return await R(this,Wt),(r=R(this,pt))==null?void 0:r.commands.setTrainingOptOut({value:u})}}fe=Z0(xr);xt=new WeakMap;Kl=new WeakMap;ml=new WeakMap;yl=new WeakMap;Bu=new WeakMap;Ur=new WeakMap;Ku=new WeakMap;ia=new WeakMap;dn=new WeakMap;ke=new WeakMap;we=new WeakMap;Lu=new WeakMap;Wt=new WeakMap;pt=new WeakMap;X=new WeakSet;la=function(s){throw this.dispatchEvent(new CustomEvent("chatkit.error",{detail:{error:s}})),s};wr=function(s){var u;this.dataset.colorScheme=typeof s.theme=="string"?s.theme:((u=s.theme)==null?void 0:u.colorScheme)??"light",this.dataset.displayMode=Q(this,X,gl).call(this,s),Q(this,X,gl).call(this,s)!=="pet"&&Q(this,X,Vl).call(this,!1)};gl=function(s=R(this,xt)){return(s==null?void 0:s.displayMode)==="pet"?"pet":"chat"};Vu=function(s=R(this,xt)){return s?Q(this,X,gl).call(this,s)==="pet"&&!fi(s.pet??null)?!0:s.pet??null:null};qm=function(s){if(!s)return s;const u=fi(Q(this,X,Vu).call(this)??null);return u?s===!0?{position:u.position}:s.position?{...s,position:{...u.position,...s.position,boundsPadding:s.position.boundsPadding??u.position.boundsPadding,pin:"pin"in s.position?s.position.pin:u.position.pin}}:{...s,position:u.position}:s};Zu=function(){if(R(this,dn))return null;let s;return R(this,ia)!==void 0?s=Q(this,X,qm).call(this,R(this,ia)):s=Q(this,X,Vu).call(this),Q(this,X,gl).call(this)==="pet"&&!fi(s??null)&&(s=!0),Q(this,X,Xm).call(this,s)};Ym=function(s){try{const u=new URL(R(this,Kl)??window.location.href,window.location.origin);return new URL(s,u).toString()}catch{return s}};Xm=function(s){const u=fi(s??null);return u?{character:{...u.character,src:Q(this,X,Ym).call(this,u.character.src)},position:u.position,behavior:u.behavior,ariaLabel:u.ariaLabel,imageRendering:u.imageRendering}:null};Hr=function(s){const u=Q(this,X,Vu).call(this,s);if(u===(s.pet??null))return s;const r={...s};return u===null?delete r.pet:r.pet=u,r};Vl=function(s){Ft(this,Ur,s),s?this.dataset.chatOpen="true":delete this.dataset.chatOpen};oi=function(s){const u=s&&!!Q(this,X,Zu).call(this);Ft(this,Ku,u),u?this.dataset.chatMinimizedToPet="true":delete this.dataset.chatMinimizedToPet};Mr=function(){var u;const s=Q(this,X,Zu).call(this);R(this,we).setOptions(s,(u=R(this,xt))==null?void 0:u.theme),s||Q(this,X,oi).call(this,!1)};Gm=function(){if(R(this,Ku)){Q(this,X,oi).call(this,!1),Q(this,X,gl).call(this)==="pet"&&Q(this,X,Vl).call(this,!0),R(this,Wt).then(()=>this.focusComposer()).catch(()=>{});return}Q(this,X,gl).call(this)==="pet"&&(Q(this,X,Vl).call(this,!0),R(this,Wt).then(()=>this.focusComposer()).catch(()=>{}))};Qm=function(){Ft(this,dn,!0),Ft(this,ia,null),Q(this,X,oi).call(this,!1),Q(this,X,Vl).call(this,!1),R(this,we).setOptions(null),Q(this,X,gl).call(this)!=="pet"&&R(this,Wt).then(()=>R(this,pt).commands.setPetEnabled({enabled:!1})).catch(()=>{})};Km=async function(s){await this.sendUserMessage({text:s})};Vm=async function(s){Q(this,X,gl).call(this)==="pet"&&Q(this,X,Vl).call(this,!0),await this.setThreadId(s),await this.focusComposer()};ju=new WeakMap;Zm=function(){if(!R(this,Kl))throw new qe("ChatKit frameUrl is not configured. Provide it via setOptions({ frameUrl }) before mounting.");return R(this,Kl)};Jm=function(s){if(R(this,ua)&&R(this,Kl)&&R(this,Kl)!==s)throw new qe("ChatKit frameUrl cannot be changed after initialization. Create a new element to use a different URL.");Ft(this,Kl,s)};km=function(s){if(!("frameUrl"in s))return;const u=s.frameUrl;if(delete s.frameUrl,u!=null){if(typeof u!="string"||u.trim()==="")throw new qe("ChatKit frameUrl must be a non-empty string.");Q(this,X,Jm).call(this,u)}};qu=new WeakMap;ua=new WeakMap;zr=function(){if(R(this,ua)||!R(this,ml)||!R(this,xt))return;Ft(this,ua,!0),Q(this,X,wr).call(this,R(this,xt));const s=new URL(Q(this,X,Zm).call(this),window.location.origin);R(this,pt).setTargetOrigin(s.origin),s.hash=o0({options:Wm(Q(this,X,Hr).call(this,R(this,xt))),referrer:window.location.origin,profile:this.profile}),R(this,pt).connect(),R(this,ml).src=s.toString(),R(this,yl)&&R(this,ke).append(R(this,yl))};Ye(fe,1,"focusComposer",jm,Ee);Ye(fe,1,"fetchUpdates",Lm,Ee);Ye(fe,1,"sendUserMessage",Bm,Ee);Ye(fe,1,"setComposerValue",Nm,Ee);Ye(fe,1,"setRuntimeCapabilities",Hm,Ee);Ye(fe,1,"setThreadId",wm,Ee);Ye(fe,1,"shareThread",Um,Ee);Ye(fe,1,"sendCustomAction",Rm,Ee);Ye(fe,1,"showHistory",Dm,Ee);Ye(fe,1,"hideHistory",Om,Ee);Ye(fe,1,"setTrainingOptOut",Cm,Ee);k0(fe,Ee);class $0 extends Ee{constructor(){super({profile:"chatkit"})}sanitizeOptions(u){var r;return(r=u.threadItemActions)==null||delete r.share,u}}function F0(s="xpertai-chatkit"){"customElements"in globalThis&&(customElements.get(s)||customElements.define(s,$0))}F0();const $m={"chatkit.error":"onError","chatkit.response.end":"onResponseEnd","chatkit.response.start":"onResponseStart","chatkit.log":"onLog","chatkit.thread.change":"onThreadChange","chatkit.thread.load.start":"onThreadLoadStart","chatkit.thread.load.end":"onThreadLoadEnd","chatkit.ready":"onReady","chatkit.effect":"onEffect"},I0=Object.keys($m),P0=vt.forwardRef(function({control:u,...r},c){const h=vt.useRef(null);return vt.useLayoutEffect(()=>{const d=h.current;if(!d)return;if(customElements.get("xpertai-chatkit")){d.setOptions(u.options);return}let y=!0;return customElements.whenDefined("xpertai-chatkit").then(()=>{y&&d.setOptions(u.options)}),()=>{y=!1}},[u.options]),vt.useEffect(()=>{const d=h.current;if(!d)return;const y=new AbortController;for(const v of I0)d.addEventListener(v,E=>{const b=$m[v],N=u.handlers[b];typeof N=="function"&&N(E.detail)},{signal:y.signal});return()=>{y.abort()}},[u.handlers]),K.jsx("xpertai-chatkit",{ref:d=>{h.current=d,u.setInstance(d),typeof c=="function"?c(d):c&&(c.current=d),h.current},...r})}),tv=["office_word_snapshot","office_word_insert_text","office_word_replace_selection","office_word_insert_heading","office_word_insert_table","office_word_search_text"],ev=new Set(tv);function lv(s){return ev.has(s)}const nv=5e3,av=20;function Fm(s){return typeof s=="string"&&s.trim()?s.trim():void 0}function Nu(s,u){const r=Fm(s);if(!r)throw new Error(`${u} must be a non-empty string.`);return r}function dm(s){return typeof s=="boolean"?s:void 0}function si(s){if(!(typeof s!="number"||!Number.isInteger(s)||s<=0))return s}function Cr(s,u){const r=si(s);if(r===void 0)throw new Error(`${u} must be a positive integer.`);return r}function Sr(s,u="End"){var c;const r=(c=Fm(s))==null?void 0:c.toLowerCase();if(!r)return u;if(r==="start")return"Start";if(r==="end")return"End";throw new Error("location must be Start or End.")}function iv(s){if(s===void 0)return 1;const u=Cr(s,"level");if(u>9)throw new Error("level must be between 1 and 9.");return u}function uv(s){if(s==null)return"";if(typeof s=="string"||typeof s=="number"||typeof s=="boolean")return String(s);throw new Error("table values must contain only strings, numbers, booleans, or nulls.")}function sv(s){if(s!==void 0){if(!Array.isArray(s))throw new Error("values must be a two-dimensional array.");return s.map(u=>{if(!Array.isArray(u))throw new Error("values must be a two-dimensional array.");return u.map(uv)})}}function cv(s){const u=sv(s.values),r=si(s.rowCount),c=si(s.columnCount);if(!u)return{rowCount:Cr(s.rowCount,"rowCount"),columnCount:Cr(s.columnCount,"columnCount")};const h=u.length,d=u.reduce((E,b)=>Math.max(E,b.length),0),y=r??h,v=c??d;if(y<=0||v<=0)throw new Error("values must include at least one row and one column.");return{rowCount:y,columnCount:v,values:Array.from({length:y},(E,b)=>Array.from({length:v},(N,U)=>{var W;return((W=u[b])==null?void 0:W[U])??""}))}}function Or(s){var u;return((u=s.Content)==null?void 0:u.Text)??""}function Im(s,u){var y;const r=s.Content;if(!r)throw new Error("The active WPS document does not expose a content range.");const c=r.Start??0,h=r.End??Or(s).length,d=u==="Start"?c:h;return((y=s.Range)==null?void 0:y.call(s,d,d))??r}function mm(s,u,r){const c=Im(s,r);return r==="Start"&&c.InsertBefore?(c.InsertBefore(u),c):r==="End"&&c.InsertAfter?(c.InsertAfter(u),c):(c.Text=u,c)}function rv(s){return-(s+1)}function fv(s,u){s!=null&&s.Cell&&u.forEach((r,c)=>{r.forEach((h,d)=>{var v;const y=(v=s.Cell)==null?void 0:v.call(s,c+1,d+1);y!=null&&y.Range&&(y.Range.Text=h)})})}function ov(s){return{name:s.Name??"WPS Writer",build:s.Build,version:s.Version}}function ym(s){return/^[\p{L}\p{N}_]$/u.test(s)}function hv(s,u,r){const c=u>0?s[u-1]:"",h=u+r<s.length?s[u+r]:"";return!ym(c)&&!ym(h)}function dv(s,u,r){const c=r.matchCase?s:s.toLocaleLowerCase(),h=r.matchCase?u:u.toLocaleLowerCase(),d=[];let y=0;for(;y<=c.length;){const v=c.indexOf(h,y);if(v===-1)break;y=v+Math.max(h.length,1),!(r.matchWholeWord&&!hv(s,v,u.length))&&d.push({index:v+1,text:s.slice(v,v+u.length)})}return d}var ci,ri;class mv{constructor(u={}){Du(this,ci);Du(this,ri);this.host="WPS Writer",Ru(this,ci,u.maxSnapshotCharacters??nv),Ru(this,ri,u.maxSearchResults??av)}supports(u){return lv(u)}async execute(u,r){switch(u){case"office_word_snapshot":return this.snapshot(r);case"office_word_insert_text":return this.insertText(r);case"office_word_replace_selection":return this.replaceSelection(r);case"office_word_insert_heading":return this.insertHeading(r);case"office_word_insert_table":return this.insertTable(r);case"office_word_search_text":return this.searchText(r)}}snapshot(u){var y;const r=si(u.maxCharacters)??ti(this,ci),c=Pn(),h=ei(c),d=Or(h);return{host:ov(c),requirements:{wpsJsApi:!0},documentName:h.Name,bodyTextLength:d.length,bodyTextPreview:d.slice(0,r),bodyTextTruncated:d.length>r,selectionText:((y=c.Selection)==null?void 0:y.Text)??""}}insertText(u){const r=Nu(u.text,"text"),c=Sr(u.location),h=ei(Pn());return mm(h,r,c),{inserted:!0,location:c,textLength:r.length}}replaceSelection(u){const r=Nu(u.text,"text"),c=Dp(Pn());return c.TypeText?c.TypeText(r):c.Text=r,{replaced:!0,textLength:r.length}}insertHeading(u){const r=Nu(u.text,"text"),c=iv(u.level),h=Sr(u.location),d=ei(Pn()),y=mm(d,`${r}\r`,h);return y.Style=rv(c),{inserted:!0,level:c,location:h,textLength:r.length}}insertTable(u){var v,E,b;const r=Sr(u.location),c=cv(u),h=ei(Pn()),d=Im(h,r),y=(E=(v=h.Tables)==null?void 0:v.Add)==null?void 0:E.call(v,d,c.rowCount,c.columnCount);if(!((b=h.Tables)!=null&&b.Add))throw new Error("The active WPS document does not expose table insertion.");return c.values&&fv(y,c.values),{inserted:!0,location:r,rowCount:c.rowCount,columnCount:c.columnCount}}searchText(u){const r=Nu(u.query,"query"),c=si(u.maxResults)??ti(this,ri),h=dm(u.matchCase),d=dm(u.matchWholeWord),y=ei(Pn()),v=dv(Or(y),r,{matchCase:h,matchWholeWord:d}),E=v.slice(0,c).map((b,N)=>({index:N+1,start:b.index,text:b.text}));return{query:r,count:v.length,results:E,truncated:v.length>E.length}}}ci=new WeakMap,ri=new WeakMap;function Pm(s={}){return new mv(s)}var na;class yv{constructor(u){Du(this,na);Ru(this,na,u)}supports(u){return ti(this,na).some(r=>r.supports(u))}async execute(u,r){const c=ti(this,na).find(h=>h.supports(u));if(!c)throw new Error(`Unknown Office tool: ${u}`);return c.execute(u,r)}}na=new WeakMap;function gv(s){return new yv(s)}function pv(s){return typeof s=="object"&&s!==null&&!Array.isArray(s)?s:{}}function br(s,u,r){return{tool_call_id:s.tool_call_id??s.id,name:s.name,status:u,content:JSON.stringify(r)}}function vv(s){return s instanceof Error?s.message:String(s)}function Sv(s={}){const u=s.registry??gv([s.adapter??Pm()]);return async r=>{if(!u.supports(r.name))return br(r,"error",{ok:!1,error:`Unknown Office tool: ${r.name}`});try{const c=await u.execute(r.name,pv(r.params));return br(r,"success",{ok:!0,result:c})}catch(c){return br(r,"error",{ok:!1,error:vv(c)})}}}const Nr="xpertai.chatkit.wps.config.v1",ty=600,bv="https://api.xpertai.cn/api/ai",Ev="https://app.xpertai.cn/chatkit/index.html",Tv="/api/create-session";function Av(s){return s.replace(/\/+$/,"")}function Br(s){if(typeof s!="string"&&typeof s!="number")return;const u=Number(s);return Number.isInteger(u)&&u>0?u:void 0}function Ql(s){return typeof s=="string"&&s.trim()?s.trim():void 0}function ey(){return typeof window>"u"?{}:window.XPERTAI_WPS_CONFIG??{}}function _v(){if(typeof window>"u")return{};try{const s=window.localStorage.getItem(Nr);if(!s)return{};const u=JSON.parse(s);return u&&typeof u=="object"&&!Array.isArray(u)?u:{}}catch{return{}}}function xv(...s){const u={};for(const r of s){const c=Ql(r.apiUrl),h=Ql(r.apiKey),d=Ql(r.xpertId),y=Ql(r.frameUrl),v=Br(r.expiresAfter);c&&(u.apiUrl=c),h&&(u.apiKey=h),d&&(u.xpertId=d),y&&(u.frameUrl=y),v&&(u.expiresAfter=v)}return u}function Mv(){const s=ey().sessionMode;return s==="proxy"||s==="user-api-key"?s:"user-api-key"}function ly(){return xv({apiUrl:bv,frameUrl:Ev,xpertId:void 0,apiKey:void 0,expiresAfter:Br(void 0)},_v(),ey())}function ny(s){const u=Ql(s.apiUrl),r=Ql(s.apiKey),c=Ql(s.xpertId),h=Ql(s.frameUrl);if(!u)throw new Error("XPERTAI_API_URL is required.");if(!r)throw new Error("XPERTAI_API_KEY is required.");if(!c)throw new Error("XPERTAI_XPERT_ID is required.");if(!h)throw new Error("XPERTAI_CHATKIT_FRAME_URL is required.");return{apiUrl:Av(u),apiKey:r,xpertId:c,frameUrl:h,expiresAfter:Br(s.expiresAfter)??ty}}function gm(){try{return ny(ly())}catch{return null}}function zv(s){window.localStorage.setItem(Nr,JSON.stringify(s))}function Cv(){window.localStorage.removeItem(Nr)}async function pm(s){const u=await fetch(Tv,{method:"POST",headers:{"Content-Type":"application/json"},credentials:"include",body:JSON.stringify(s?{currentClientSecret:s}:{})}),r=await u.json().catch(()=>({}));if(!u.ok)throw new Error(r.error||`HTTP ${u.status}`);if(!r.client_secret||!r.apiUrl||!r.frameUrl||!r.xpertId)throw new Error("ChatKit session response is missing required fields.");return r}async function vm(s){const u=`${s.apiUrl}/v1/chatkit/sessions`;let r;try{r=await fetch(u,{method:"POST",headers:{"Content-Type":"application/json","x-api-key":s.apiKey},body:JSON.stringify({expires_after:s.expiresAfter??ty})})}catch(h){const d=typeof window>"u"?"unknown":window.location.origin;throw new Error(`Failed to fetch ${u}. Check network access and CORS. The API must allow origin ${d} and the x-api-key header. ${h instanceof Error?h.message:String(h)}`)}const c=await r.json().catch(()=>({}));if(!r.ok)throw new Error(c.error||r.statusText||`HTTP ${r.status}`);if(!c.client_secret)throw new Error("Missing client_secret in Xpert ChatKit session response.");return{client_secret:c.client_secret,expires_at:c.expires_at,expires_after:c.expires_after??s.expiresAfter,apiUrl:s.apiUrl,frameUrl:s.frameUrl,xpertId:s.xpertId,organizationId:null}}async function Ov(){const s=Rp();return s?{host:s.Name,build:s.Build,version:s.Version,isWpsHost:!0}:{isWpsHost:!1}}function Gu(s){return s instanceof Error?s.message:String(s)}function Dv(){return navigator.language.toLowerCase().startsWith("zh")?"zh-Hans":"en"}function Rv({createSession:s,initialSession:u,onConfigure:r}){const[c,h]=vt.useState(u),[d,y]=vt.useState(null),v=vt.useMemo(()=>Sv({adapter:Pm()}),[]),E=vt.useMemo(()=>({frameUrl:c.frameUrl,locale:Dv(),api:{apiUrl:c.apiUrl,xpertId:c.xpertId,getClientSecret:async N=>{const U=N?await s(N):c;return h(U),U.organizationId?{secret:U.client_secret,organizationId:U.organizationId}:U.client_secret}},theme:{colorScheme:"light",radius:"round",density:"compact",typography:{baseSize:14,fontFamily:'system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif'},color:{accent:{primary:"#0f766e",level:1}}},composer:{placeholder:"Ask XpertAI to edit this WPS document...",attachments:{enabled:!0}},startScreen:{greeting:"WPS Copilot is ready.",prompts:[{icon:"sparkle",label:"Draft an outline",prompt:"Create a structured outline for this document."},{icon:"square-text",label:"Improve selection",prompt:"Rewrite the selected paragraph to be clearer and more concise."}]},header:{enabled:!0,title:{enabled:!0,text:"XpertAI WPS Copilot"}},onClientTool:async N=>{y(null);const U=await v(N);return U.status==="error"&&y(typeof U.content=="string"?U.content:"Office tool failed."),U},onError:N=>{y(Gu(N))}}),[s,v,c]),b=Zp(E);return K.jsxs("main",{className:"taskpane",children:[d?K.jsxs("div",{className:"status-banner error",children:[K.jsx("span",{children:d}),r?K.jsx("button",{className:"link-button",type:"button",onClick:r,children:"Settings"}):null]}):null,K.jsx(P0,{control:b.control,className:"chatkit-shell"})]})}function ui(s,u){const r=s.get(u);return typeof r=="string"?r:void 0}function Uv({error:s,initialConfig:u,isConnecting:r,onSave:c}){const[h,d]=vt.useState(null);function y(E){E.preventDefault();const b=new FormData(E.currentTarget);try{d(null),c(ny({apiUrl:ui(b,"apiUrl"),apiKey:ui(b,"apiKey"),xpertId:ui(b,"xpertId"),frameUrl:ui(b,"frameUrl"),expiresAfter:Number(ui(b,"expiresAfter"))}))}catch(N){d(Gu(N))}}function v(){Cv(),window.location.reload()}return K.jsx("main",{className:"taskpane settings",children:K.jsxs("form",{className:"settings-panel",onSubmit:y,children:[K.jsxs("div",{className:"settings-header",children:[K.jsx("h1",{children:"XpertAI WPS Copilot"}),K.jsx("p",{children:"Use your own XpertAI API key on this device."})]}),s||h?K.jsx("div",{className:"settings-error",children:h??s}):null,K.jsxs("label",{children:[K.jsx("span",{children:"API URL"}),K.jsx("input",{name:"apiUrl",required:!0,defaultValue:u.apiUrl??"",autoComplete:"url"})]}),K.jsxs("label",{children:[K.jsx("span",{children:"API Key"}),K.jsx("input",{name:"apiKey",required:!0,type:"password",defaultValue:u.apiKey??"",autoComplete:"off"})]}),K.jsxs("label",{children:[K.jsx("span",{children:"Xpert ID"}),K.jsx("input",{name:"xpertId",required:!0,defaultValue:u.xpertId??"",autoComplete:"off"})]}),K.jsxs("label",{children:[K.jsx("span",{children:"ChatKit Frame URL"}),K.jsx("input",{name:"frameUrl",required:!0,defaultValue:u.frameUrl??"",autoComplete:"url"})]}),K.jsxs("label",{children:[K.jsx("span",{children:"Secret TTL Seconds"}),K.jsx("input",{name:"expiresAfter",inputMode:"numeric",defaultValue:u.expiresAfter??600})]}),K.jsxs("div",{className:"settings-actions",children:[K.jsx("button",{disabled:r,type:"submit",children:r?"Connecting...":"Save and Connect"}),K.jsx("button",{disabled:r,type:"button",onClick:v,children:"Clear"})]})]})})}function Sm(){return K.jsx("main",{className:"taskpane centered",children:K.jsxs("div",{className:"status-card",children:[K.jsx("h1",{children:"XpertAI WPS Copilot"}),K.jsx("p",{children:"Connecting..."})]})})}function bm({message:s}){return K.jsx("main",{className:"taskpane centered",children:K.jsxs("div",{className:"status-card",children:[K.jsx("h1",{children:"XpertAI WPS Copilot"}),K.jsx("p",{children:s})]})})}function wv(){const[s]=vt.useState(()=>Mv()),[u,r]=vt.useState(null),[c,h]=vt.useState(null),[d,y]=vt.useState(()=>gm()),[v,E]=vt.useState(!1),[b,N]=vt.useState(!0),[U,W]=vt.useState(null),st=vt.useCallback(async it=>{N(!0),W(null);try{const Mt=await vm(it);zv(it),y(it),h(Mt),E(!1)}catch(Mt){h(null),E(!0),W(Gu(Mt))}finally{N(!1)}},[]);vt.useEffect(()=>{let it=!1;async function Mt(){try{const bt=await Ov();if(it)return;if(r(bt),s==="proxy"){const Ht=await pm();it||(h(Ht),N(!1));return}const wt=gm();if(y(wt),!wt){E(!0),N(!1);return}await st(wt)}catch(bt){it||(W(Gu(bt)),E(s==="user-api-key"),N(!1))}}return Mt(),()=>{it=!0}},[st,s]);const St=vt.useCallback(it=>s==="proxy"?pm(it):d?vm(d):Promise.reject(new Error("XPERTAI_API_KEY is not configured.")),[s,d]);return!u&&!v?U?K.jsx(bm,{message:U}):K.jsx(Sm,{}):s==="user-api-key"&&(v||!c)?K.jsx(Uv,{error:U,initialConfig:ly(),isConnecting:b,onSave:st}):U&&!c?K.jsx(bm,{message:U}):c?K.jsx(Rv,{createSession:St,initialSession:c,onConfigure:s==="user-api-key"?()=>E(!0):void 0}):K.jsx(Sm,{})}const ay=document.getElementById("root");if(!ay)throw new Error("Missing #root element.");function Hv(){return new Promise(s=>{const u=document.createElement("script");u.src=new URL("config.js",window.location.href).toString(),u.onload=()=>s(),u.onerror=()=>s(),document.head.appendChild(u)})}Hv().then(()=>{Gp.createRoot(ay).render(K.jsx(vt.StrictMode,{children:K.jsx(wv,{})}))});
|