@xpert-ai/chatkit-wps-addin 0.17.1 → 0.17.3
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 Rp=Object.defineProperty;var Qd=s=>{throw TypeError(s)};var Up=(s,u,c)=>u in s?Rp(s,u,{enumerable:!0,configurable:!0,writable:!0,value:c}):s[u]=c;var St=(s,u,c)=>Up(s,typeof u!="symbol"?u+"":u,c),Kd=(s,u,c)=>u.has(s)||Qd("Cannot "+c);var ei=(s,u,c)=>(Kd(s,u,"read from private field"),c?c.call(s):u.get(s)),Uu=(s,u,c)=>u.has(s)?Qd("Cannot add the same private member more than once"):u instanceof WeakSet?u.add(s):u.set(s,c),Nu=(s,u,c,r)=>(Kd(s,u,"write to private field"),r?r.call(s,c):u.set(s,c),c);import{g as ea,a as li,b as Np,r as Hp}from"./wps-api-DgiVmik0.js";function Bp(s){return s&&s.__esModule&&Object.prototype.hasOwnProperty.call(s,"default")?s.default:s}var dr={exports:{}},ni={};/**
|
|
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 Vd;function Lp(){if(Vd)return ni;Vd=1;var s=Symbol.for("react.transitional.element"),u=Symbol.for("react.fragment");function c(r,f,d){var y=null;if(d!==void 0&&(y=""+d),f.key!==void 0&&(y=""+f.key),"key"in f){d={};for(var p in f)p!=="key"&&(d[p]=f[p])}else d=f;return f=d.ref,{$$typeof:s,type:r,key:y,ref:f!==void 0?f:null,props:d}}return ni.Fragment=u,ni.jsx=c,ni.jsxs=c,ni}var Zd;function jp(){return Zd||(Zd=1,dr.exports=Lp()),dr.exports}var K=jp(),mr={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 Jd;function qp(){if(Jd)return V;Jd=1;var s=Symbol.for("react.transitional.element"),u=Symbol.for("react.portal"),c=Symbol.for("react.fragment"),r=Symbol.for("react.strict_mode"),f=Symbol.for("react.profiler"),d=Symbol.for("react.consumer"),y=Symbol.for("react.context"),p=Symbol.for("react.forward_ref"),E=Symbol.for("react.suspense"),b=Symbol.for("react.memo"),U=Symbol.for("react.lazy"),R=Symbol.for("react.activity"),W=Symbol.iterator;function ct(v){return v===null||typeof v!="object"?null:(v=W&&v[W]||v["@@iterator"],typeof v=="function"?v:null)}var Et={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},ut=Object.assign,Mt={};function Tt(v,w,H){this.props=v,this.context=w,this.refs=Mt,this.updater=H||Et}Tt.prototype.isReactComponent={},Tt.prototype.setState=function(v,w){if(typeof v!="object"&&typeof v!="function"&&v!=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,v,w,"setState")},Tt.prototype.forceUpdate=function(v){this.updater.enqueueForceUpdate(this,v,"forceUpdate")};function Ut(){}Ut.prototype=Tt.prototype;function Nt(v,w,H){this.props=v,this.context=w,this.refs=Mt,this.updater=H||Et}var le=Nt.prototype=new Ut;le.constructor=Nt,ut(le,Tt.prototype),le.isPureReactComponent=!0;var ne=Array.isArray;function Xt(){}var $={H:null,A:null,T:null,S:null},Ct=Object.prototype.hasOwnProperty;function Xe(v,w,H){var L=H.ref;return{$$typeof:s,type:v,key:w,ref:L!==void 0?L:null,props:H}}function gn(v,w){return Xe(v.type,w,v.props)}function Ge(v){return typeof v=="object"&&v!==null&&v.$$typeof===s}function ae(v){var w={"=":"=0",":":"=2"};return"$"+v.replace(/[=:]/g,function(H){return w[H]})}var Jl=/\/+/g;function $e(v,w){return typeof v=="object"&&v!==null&&v.key!=null?ae(""+v.key):w.toString(36)}function Le(v){switch(v.status){case"fulfilled":return v.value;case"rejected":throw v.reason;default:switch(typeof v.status=="string"?v.then(Xt,Xt):(v.status="pending",v.then(function(w){v.status==="pending"&&(v.status="fulfilled",v.value=w)},function(w){v.status==="pending"&&(v.status="rejected",v.reason=w)})),v.status){case"fulfilled":return v.value;case"rejected":throw v.reason}}throw v}function z(v,w,H,L,Z){var F=typeof v;(F==="undefined"||F==="boolean")&&(v=null);var rt=!1;if(v===null)rt=!0;else switch(F){case"bigint":case"string":case"number":rt=!0;break;case"object":switch(v.$$typeof){case s:case u:rt=!0;break;case U:return rt=v._init,z(rt(v._payload),w,H,L,Z)}}if(rt)return Z=Z(v),rt=L===""?"."+$e(v,0):L,ne(Z)?(H="",rt!=null&&(H=rt.replace(Jl,"$&/")+"/"),z(Z,w,H,"",function(ca){return ca})):Z!=null&&(Ge(Z)&&(Z=gn(Z,H+(Z.key==null||v&&v.key===Z.key?"":(""+Z.key).replace(Jl,"$&/")+"/")+rt)),w.push(Z)),1;rt=0;var Pt=L===""?".":L+":";if(ne(v))for(var Dt=0;Dt<v.length;Dt++)L=v[Dt],F=Pt+$e(L,Dt),rt+=z(L,w,H,F,Z);else if(Dt=ct(v),typeof Dt=="function")for(v=Dt.call(v),Dt=0;!(L=v.next()).done;)L=L.value,F=Pt+$e(L,Dt++),rt+=z(L,w,H,F,Z);else if(F==="object"){if(typeof v.then=="function")return z(Le(v),w,H,L,Z);throw w=String(v),Error("Objects are not valid as a React child (found: "+(w==="[object Object]"?"object with keys {"+Object.keys(v).join(", ")+"}":w)+"). If you meant to render a collection of children, use an array instead.")}return rt}function N(v,w,H){if(v==null)return v;var L=[],Z=0;return z(v,L,"","",function(F){return w.call(H,F,Z++)}),L}function Q(v){if(v._status===-1){var w=v._result;w=w(),w.then(function(H){(v._status===0||v._status===-1)&&(v._status=1,v._result=H)},function(H){(v._status===0||v._status===-1)&&(v._status=2,v._result=H)}),v._status===-1&&(v._status=0,v._result=w)}if(v._status===1)return v._result.default;throw v._result}var dt=typeof reportError=="function"?reportError:function(v){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var w=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof v=="object"&&v!==null&&typeof v.message=="string"?String(v.message):String(v),error:v});if(!window.dispatchEvent(w))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",v);return}console.error(v)},pt={map:N,forEach:function(v,w,H){N(v,function(){w.apply(this,arguments)},H)},count:function(v){var w=0;return N(v,function(){w++}),w},toArray:function(v){return N(v,function(w){return w})||[]},only:function(v){if(!Ge(v))throw Error("React.Children.only expected to receive a single React element child.");return v}};return V.Activity=R,V.Children=pt,V.Component=Tt,V.Fragment=c,V.Profiler=f,V.PureComponent=Nt,V.StrictMode=r,V.Suspense=E,V.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=$,V.__COMPILER_RUNTIME={__proto__:null,c:function(v){return $.H.useMemoCache(v)}},V.cache=function(v){return function(){return v.apply(null,arguments)}},V.cacheSignal=function(){return null},V.cloneElement=function(v,w,H){if(v==null)throw Error("The argument must be a React element, but you passed "+v+".");var L=ut({},v.props),Z=v.key;if(w!=null)for(F in w.key!==void 0&&(Z=""+w.key),w)!Ct.call(w,F)||F==="key"||F==="__self"||F==="__source"||F==="ref"&&w.ref===void 0||(L[F]=w[F]);var F=arguments.length-2;if(F===1)L.children=H;else if(1<F){for(var rt=Array(F),Pt=0;Pt<F;Pt++)rt[Pt]=arguments[Pt+2];L.children=rt}return Xe(v.type,Z,L)},V.createContext=function(v){return v={$$typeof:y,_currentValue:v,_currentValue2:v,_threadCount:0,Provider:null,Consumer:null},v.Provider=v,v.Consumer={$$typeof:d,_context:v},v},V.createElement=function(v,w,H){var L,Z={},F=null;if(w!=null)for(L in w.key!==void 0&&(F=""+w.key),w)Ct.call(w,L)&&L!=="key"&&L!=="__self"&&L!=="__source"&&(Z[L]=w[L]);var rt=arguments.length-2;if(rt===1)Z.children=H;else if(1<rt){for(var Pt=Array(rt),Dt=0;Dt<rt;Dt++)Pt[Dt]=arguments[Dt+2];Z.children=Pt}if(v&&v.defaultProps)for(L in rt=v.defaultProps,rt)Z[L]===void 0&&(Z[L]=rt[L]);return Xe(v,F,Z)},V.createRef=function(){return{current:null}},V.forwardRef=function(v){return{$$typeof:p,render:v}},V.isValidElement=Ge,V.lazy=function(v){return{$$typeof:U,_payload:{_status:-1,_result:v},_init:Q}},V.memo=function(v,w){return{$$typeof:b,type:v,compare:w===void 0?null:w}},V.startTransition=function(v){var w=$.T,H={};$.T=H;try{var L=v(),Z=$.S;Z!==null&&Z(H,L),typeof L=="object"&&L!==null&&typeof L.then=="function"&&L.then(Xt,dt)}catch(F){dt(F)}finally{w!==null&&H.types!==null&&(w.types=H.types),$.T=w}},V.unstable_useCacheRefresh=function(){return $.H.useCacheRefresh()},V.use=function(v){return $.H.use(v)},V.useActionState=function(v,w,H){return $.H.useActionState(v,w,H)},V.useCallback=function(v,w){return $.H.useCallback(v,w)},V.useContext=function(v){return $.H.useContext(v)},V.useDebugValue=function(){},V.useDeferredValue=function(v,w){return $.H.useDeferredValue(v,w)},V.useEffect=function(v,w){return $.H.useEffect(v,w)},V.useEffectEvent=function(v){return $.H.useEffectEvent(v)},V.useId=function(){return $.H.useId()},V.useImperativeHandle=function(v,w,H){return $.H.useImperativeHandle(v,w,H)},V.useInsertionEffect=function(v,w){return $.H.useInsertionEffect(v,w)},V.useLayoutEffect=function(v,w){return $.H.useLayoutEffect(v,w)},V.useMemo=function(v,w){return $.H.useMemo(v,w)},V.useOptimistic=function(v,w){return $.H.useOptimistic(v,w)},V.useReducer=function(v,w,H){return $.H.useReducer(v,w,H)},V.useRef=function(v){return $.H.useRef(v)},V.useState=function(v){return $.H.useState(v)},V.useSyncExternalStore=function(v,w,H){return $.H.useSyncExternalStore(v,w,H)},V.useTransition=function(){return $.H.useTransition()},V.version="19.2.3",V}var kd;function Rr(){return kd||(kd=1,mr.exports=qp()),mr.exports}var bt=Rr();const Wd=Bp(bt);var yr={exports:{}},ai={},gr={exports:{}},pr={};/**
|
|
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 $d;function Yp(){return $d||($d=1,(function(s){function u(z,N){var Q=z.length;z.push(N);t:for(;0<Q;){var dt=Q-1>>>1,pt=z[dt];if(0<f(pt,N))z[dt]=N,z[Q]=pt,Q=dt;else break t}}function c(z){return z.length===0?null:z[0]}function r(z){if(z.length===0)return null;var N=z[0],Q=z.pop();if(Q!==N){z[0]=Q;t:for(var dt=0,pt=z.length,v=pt>>>1;dt<v;){var w=2*(dt+1)-1,H=z[w],L=w+1,Z=z[L];if(0>f(H,Q))L<pt&&0>f(Z,H)?(z[dt]=Z,z[L]=Q,dt=L):(z[dt]=H,z[w]=Q,dt=w);else if(L<pt&&0>f(Z,Q))z[dt]=Z,z[L]=Q,dt=L;else break t}}return N}function f(z,N){var Q=z.sortIndex-N.sortIndex;return Q!==0?Q:z.id-N.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,p=y.now();s.unstable_now=function(){return y.now()-p}}var E=[],b=[],U=1,R=null,W=3,ct=!1,Et=!1,ut=!1,Mt=!1,Tt=typeof setTimeout=="function"?setTimeout:null,Ut=typeof clearTimeout=="function"?clearTimeout:null,Nt=typeof setImmediate<"u"?setImmediate:null;function le(z){for(var N=c(b);N!==null;){if(N.callback===null)r(b);else if(N.startTime<=z)r(b),N.sortIndex=N.expirationTime,u(E,N);else break;N=c(b)}}function ne(z){if(ut=!1,le(z),!Et)if(c(E)!==null)Et=!0,Xt||(Xt=!0,ae());else{var N=c(b);N!==null&&Le(ne,N.startTime-z)}}var Xt=!1,$=-1,Ct=5,Xe=-1;function gn(){return Mt?!0:!(s.unstable_now()-Xe<Ct)}function Ge(){if(Mt=!1,Xt){var z=s.unstable_now();Xe=z;var N=!0;try{t:{Et=!1,ut&&(ut=!1,Ut($),$=-1),ct=!0;var Q=W;try{e:{for(le(z),R=c(E);R!==null&&!(R.expirationTime>z&&gn());){var dt=R.callback;if(typeof dt=="function"){R.callback=null,W=R.priorityLevel;var pt=dt(R.expirationTime<=z);if(z=s.unstable_now(),typeof pt=="function"){R.callback=pt,le(z),N=!0;break e}R===c(E)&&r(E),le(z)}else r(E);R=c(E)}if(R!==null)N=!0;else{var v=c(b);v!==null&&Le(ne,v.startTime-z),N=!1}}break t}finally{R=null,W=Q,ct=!1}N=void 0}}finally{N?ae():Xt=!1}}}var ae;if(typeof Nt=="function")ae=function(){Nt(Ge)};else if(typeof MessageChannel<"u"){var Jl=new MessageChannel,$e=Jl.port2;Jl.port1.onmessage=Ge,ae=function(){$e.postMessage(null)}}else ae=function(){Tt(Ge,0)};function Le(z,N){$=Tt(function(){z(s.unstable_now())},N)}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"):Ct=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 N=3;break;default:N=W}var Q=W;W=N;try{return z()}finally{W=Q}},s.unstable_requestPaint=function(){Mt=!0},s.unstable_runWithPriority=function(z,N){switch(z){case 1:case 2:case 3:case 4:case 5:break;default:z=3}var Q=W;W=z;try{return N()}finally{W=Q}},s.unstable_scheduleCallback=function(z,N,Q){var dt=s.unstable_now();switch(typeof Q=="object"&&Q!==null?(Q=Q.delay,Q=typeof Q=="number"&&0<Q?dt+Q:dt):Q=dt,z){case 1:var pt=-1;break;case 2:pt=250;break;case 5:pt=1073741823;break;case 4:pt=1e4;break;default:pt=5e3}return pt=Q+pt,z={id:U++,callback:N,priorityLevel:z,startTime:Q,expirationTime:pt,sortIndex:-1},Q>dt?(z.sortIndex=Q,u(b,z),c(E)===null&&z===c(b)&&(ut?(Ut($),$=-1):ut=!0,Le(ne,Q-dt))):(z.sortIndex=pt,u(E,z),Et||ct||(Et=!0,Xt||(Xt=!0,ae()))),z},s.unstable_shouldYield=gn,s.unstable_wrapCallback=function(z){var N=W;return function(){var Q=W;W=N;try{return z.apply(this,arguments)}finally{W=Q}}}})(pr)),pr}var Fd;function Xp(){return Fd||(Fd=1,gr.exports=Yp()),gr.exports}var vr={exports:{}},Ft={};/**
|
|
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 Id;function Gp(){if(Id)return Ft;Id=1;var s=Rr();function u(E){var b="https://react.dev/errors/"+E;if(1<arguments.length){b+="?args[]="+encodeURIComponent(arguments[1]);for(var U=2;U<arguments.length;U++)b+="&args[]="+encodeURIComponent(arguments[U])}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 c(){}var r={d:{f:c,r:function(){throw Error(u(522))},D:c,C:c,L:c,m:c,X:c,S:c,M:c},p:0,findDOMNode:null},f=Symbol.for("react.portal");function d(E,b,U){var R=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:f,key:R==null?null:""+R,children:E,containerInfo:b,implementation:U}}var y=s.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function p(E,b){if(E==="font")return"";if(typeof b=="string")return b==="use-credentials"?b:""}return Ft.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=r,Ft.createPortal=function(E,b){var U=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,U)},Ft.flushSync=function(E){var b=y.T,U=r.p;try{if(y.T=null,r.p=2,E)return E()}finally{y.T=b,r.p=U,r.d.f()}},Ft.preconnect=function(E,b){typeof E=="string"&&(b?(b=b.crossOrigin,b=typeof b=="string"?b==="use-credentials"?b:"":void 0):b=null,r.d.C(E,b))},Ft.prefetchDNS=function(E){typeof E=="string"&&r.d.D(E)},Ft.preinit=function(E,b){if(typeof E=="string"&&b&&typeof b.as=="string"){var U=b.as,R=p(U,b.crossOrigin),W=typeof b.integrity=="string"?b.integrity:void 0,ct=typeof b.fetchPriority=="string"?b.fetchPriority:void 0;U==="style"?r.d.S(E,typeof b.precedence=="string"?b.precedence:void 0,{crossOrigin:R,integrity:W,fetchPriority:ct}):U==="script"&&r.d.X(E,{crossOrigin:R,integrity:W,fetchPriority:ct,nonce:typeof b.nonce=="string"?b.nonce:void 0})}},Ft.preinitModule=function(E,b){if(typeof E=="string")if(typeof b=="object"&&b!==null){if(b.as==null||b.as==="script"){var U=p(b.as,b.crossOrigin);r.d.M(E,{crossOrigin:U,integrity:typeof b.integrity=="string"?b.integrity:void 0,nonce:typeof b.nonce=="string"?b.nonce:void 0})}}else b==null&&r.d.M(E)},Ft.preload=function(E,b){if(typeof E=="string"&&typeof b=="object"&&b!==null&&typeof b.as=="string"){var U=b.as,R=p(U,b.crossOrigin);r.d.L(E,U,{crossOrigin:R,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})}},Ft.preloadModule=function(E,b){if(typeof E=="string")if(b){var U=p(b.as,b.crossOrigin);r.d.m(E,{as:typeof b.as=="string"&&b.as!=="script"?b.as:void 0,crossOrigin:U,integrity:typeof b.integrity=="string"?b.integrity:void 0})}else r.d.m(E)},Ft.requestFormReset=function(E){r.d.r(E)},Ft.unstable_batchedUpdates=function(E,b){return E(b)},Ft.useFormState=function(E,b,U){return y.H.useFormState(E,b,U)},Ft.useFormStatus=function(){return y.H.useHostTransitionStatus()},Ft.version="19.2.3",Ft}var Pd;function Qp(){if(Pd)return vr.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(),vr.exports=Gp(),vr.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 tm;function Kp(){if(tm)return ai;tm=1;var s=Xp(),u=Rr(),c=Qp();function r(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 f(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 p(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(r(188))}function b(t){var e=t.alternate;if(!e){if(e=d(t),e===null)throw Error(r(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(r(188))}if(l.return!==n.return)l=a,n=i;else{for(var o=!1,h=a.child;h;){if(h===l){o=!0,l=a,n=i;break}if(h===n){o=!0,n=a,l=i;break}h=h.sibling}if(!o){for(h=i.child;h;){if(h===l){o=!0,l=i,n=a;break}if(h===n){o=!0,n=i,l=a;break}h=h.sibling}if(!o)throw Error(r(189))}}if(l.alternate!==n)throw Error(r(190))}if(l.tag!==3)throw Error(r(188));return l.stateNode.current===l?t:e}function U(t){var e=t.tag;if(e===5||e===26||e===27||e===6)return t;for(t=t.child;t!==null;){if(e=U(t),e!==null)return e;t=t.sibling}return null}var R=Object.assign,W=Symbol.for("react.element"),ct=Symbol.for("react.transitional.element"),Et=Symbol.for("react.portal"),ut=Symbol.for("react.fragment"),Mt=Symbol.for("react.strict_mode"),Tt=Symbol.for("react.profiler"),Ut=Symbol.for("react.consumer"),Nt=Symbol.for("react.context"),le=Symbol.for("react.forward_ref"),ne=Symbol.for("react.suspense"),Xt=Symbol.for("react.suspense_list"),$=Symbol.for("react.memo"),Ct=Symbol.for("react.lazy"),Xe=Symbol.for("react.activity"),gn=Symbol.for("react.memo_cache_sentinel"),Ge=Symbol.iterator;function ae(t){return t===null||typeof t!="object"?null:(t=Ge&&t[Ge]||t["@@iterator"],typeof t=="function"?t:null)}var Jl=Symbol.for("react.client.reference");function $e(t){if(t==null)return null;if(typeof t=="function")return t.$$typeof===Jl?null:t.displayName||t.name||null;if(typeof t=="string")return t;switch(t){case ut:return"Fragment";case Tt:return"Profiler";case Mt:return"StrictMode";case ne:return"Suspense";case Xt:return"SuspenseList";case Xe:return"Activity"}if(typeof t=="object")switch(t.$$typeof){case Et:return"Portal";case Nt:return t.displayName||"Context";case Ut:return(t._context.displayName||"Context")+".Consumer";case le: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:$e(t.type)||"Memo";case Ct:e=t._payload,t=t._init;try{return $e(t(e))}catch{}}return null}var Le=Array.isArray,z=u.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,N=c.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,Q={pending:!1,data:null,method:null,action:null},dt=[],pt=-1;function v(t){return{current:t}}function w(t){0>pt||(t.current=dt[pt],dt[pt]=null,pt--)}function H(t,e){pt++,dt[pt]=t.current,t.current=e}var L=v(null),Z=v(null),F=v(null),rt=v(null);function Pt(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)?hd(t):0;break;default:if(t=e.tagName,e=e.namespaceURI)e=hd(e),t=dd(e,t);else switch(t){case"svg":t=1;break;case"math":t=2;break;default:t=0}}w(L),H(L,t)}function Dt(){w(L),w(Z),w(F)}function ca(t){t.memoizedState!==null&&H(rt,t);var e=L.current,l=dd(e,t.type);e!==l&&(H(Z,t),H(L,l))}function yi(t){Z.current===t&&(w(L),w(Z)),rt.current===t&&(w(rt),Fa._currentValue=Q)}var Wu,Yr;function kl(t){if(Wu===void 0)try{throw Error()}catch(l){var e=l.stack.trim().match(/\n( *(at )?)/);Wu=e&&e[1]||"",Yr=-1<l.stack.indexOf(`
|
|
42
|
-
at`)?" (<anonymous>)":-1<l.stack.indexOf("@")?"@unknown:0:0":""}return`
|
|
43
|
-
`+Wu+t+Yr}var $u=!1;function Fu(t,e){if(!t||$u)return"";$u=!0;var l=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var n={DetermineComponentFrameRoot:function(){try{if(e){var D=function(){throw Error()};if(Object.defineProperty(D.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(D,[])}catch(x){var _=x}Reflect.construct(t,[],D)}else{try{D.call()}catch(x){_=x}t.call(D.prototype)}}else{try{throw Error()}catch(x){_=x}(D=t())&&typeof D.catch=="function"&&D.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(),o=i[0],h=i[1];if(o&&h){var m=o.split(`
|
|
44
|
-
`),A=h.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 C=`
|
|
46
|
-
`+m[n].replace(" at new "," at ");return t.displayName&&C.includes("<anonymous>")&&(C=C.replace("<anonymous>",t.displayName)),C}while(1<=n&&0<=a);break}}}finally{$u=!1,Error.prepareStackTrace=l}return(l=t?t.displayName||t.name:"")?kl(l):""}function ry(t,e){switch(t.tag){case 26:case 27:case 5:return kl(t.type);case 16:return kl("Lazy");case 13:return t.child!==e&&e!==null?kl("Suspense Fallback"):kl("Suspense");case 19:return kl("SuspenseList");case 0:case 15:return Fu(t.type,!1);case 11:return Fu(t.type.render,!1);case 1:return Fu(t.type,!0);case 31:return kl("Activity");default:return""}}function Xr(t){try{var e="",l=null;do e+=ry(t,l),l=t,t=t.return;while(t);return e}catch(n){return`
|
|
47
|
-
Error generating stack: `+n.message+`
|
|
48
|
-
`+n.stack}}var Iu=Object.prototype.hasOwnProperty,Pu=s.unstable_scheduleCallback,ts=s.unstable_cancelCallback,oy=s.unstable_shouldYield,fy=s.unstable_requestPaint,de=s.unstable_now,hy=s.unstable_getCurrentPriorityLevel,Gr=s.unstable_ImmediatePriority,Qr=s.unstable_UserBlockingPriority,gi=s.unstable_NormalPriority,dy=s.unstable_LowPriority,Kr=s.unstable_IdlePriority,my=s.log,yy=s.unstable_setDisableYieldValue,ra=null,me=null;function pl(t){if(typeof my=="function"&&yy(t),me&&typeof me.setStrictMode=="function")try{me.setStrictMode(ra,t)}catch{}}var ye=Math.clz32?Math.clz32:vy,gy=Math.log,py=Math.LN2;function vy(t){return t>>>=0,t===0?32:31-(gy(t)/py|0)|0}var pi=256,vi=262144,Si=4194304;function Wl(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 bi(t,e,l){var n=t.pendingLanes;if(n===0)return 0;var a=0,i=t.suspendedLanes,o=t.pingedLanes;t=t.warmLanes;var h=n&134217727;return h!==0?(n=h&~i,n!==0?a=Wl(n):(o&=h,o!==0?a=Wl(o):l||(l=h&~t,l!==0&&(a=Wl(l))))):(h=n&~i,h!==0?a=Wl(h):o!==0?a=Wl(o):l||(l=n&~t,l!==0&&(a=Wl(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 oa(t,e){return(t.pendingLanes&~(t.suspendedLanes&~t.pingedLanes)&e)===0}function Sy(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 Vr(){var t=Si;return Si<<=1,(Si&62914560)===0&&(Si=4194304),t}function es(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 by(t,e,l,n,a,i){var o=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 h=t.entanglements,m=t.expirationTimes,A=t.hiddenUpdates;for(l=o&~l;0<l;){var C=31-ye(l),D=1<<C;h[C]=0,m[C]=-1;var _=A[C];if(_!==null)for(A[C]=null,C=0;C<_.length;C++){var x=_[C];x!==null&&(x.lane&=-536870913)}l&=~D}n!==0&&Zr(t,n,0),i!==0&&a===0&&t.tag!==0&&(t.suspendedLanes|=i&~(o&~e))}function Zr(t,e,l){t.pendingLanes|=e,t.suspendedLanes&=~e;var n=31-ye(e);t.entangledLanes|=e,t.entanglements[n]=t.entanglements[n]|1073741824|l&261930}function Jr(t,e){var l=t.entangledLanes|=e;for(t=t.entanglements;l;){var n=31-ye(l),a=1<<n;a&e|t[n]&e&&(t[n]|=e),l&=~a}}function kr(t,e){var l=e&-e;return l=(l&42)!==0?1:ls(l),(l&(t.suspendedLanes|e))!==0?0:l}function ls(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 ns(t){return t&=-t,2<t?8<t?(t&134217727)!==0?32:268435456:8:2}function Wr(){var t=N.p;return t!==0?t:(t=window.event,t===void 0?32:Bd(t.type))}function $r(t,e){var l=N.p;try{return N.p=t,e()}finally{N.p=l}}var vl=Math.random().toString(36).slice(2),Vt="__reactFiber$"+vl,ie="__reactProps$"+vl,pn="__reactContainer$"+vl,as="__reactEvents$"+vl,Ey="__reactListeners$"+vl,Ty="__reactHandles$"+vl,Fr="__reactResources$"+vl,ha="__reactMarker$"+vl;function is(t){delete t[Vt],delete t[ie],delete t[as],delete t[Ey],delete t[Ty]}function vn(t){var e=t[Vt];if(e)return e;for(var l=t.parentNode;l;){if(e=l[pn]||l[Vt]){if(l=e.alternate,e.child!==null||l!==null&&l.child!==null)for(t=bd(t);t!==null;){if(l=t[Vt])return l;t=bd(t)}return e}t=l,l=t.parentNode}return null}function Sn(t){if(t=t[Vt]||t[pn]){var e=t.tag;if(e===5||e===6||e===13||e===31||e===26||e===27||e===3)return t}return null}function da(t){var e=t.tag;if(e===5||e===26||e===27||e===6)return t.stateNode;throw Error(r(33))}function bn(t){var e=t[Fr];return e||(e=t[Fr]={hoistableStyles:new Map,hoistableScripts:new Map}),e}function Gt(t){t[ha]=!0}var Ir=new Set,Pr={};function $l(t,e){En(t,e),En(t+"Capture",e)}function En(t,e){for(Pr[t]=e,t=0;t<e.length;t++)Ir.add(e[t])}var Ay=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]*$"),to={},eo={};function _y(t){return Iu.call(eo,t)?!0:Iu.call(to,t)?!1:Ay.test(t)?eo[t]=!0:(to[t]=!0,!1)}function Ei(t,e,l){if(_y(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 Ti(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 Fe(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 Ae(t){switch(typeof t){case"bigint":case"boolean":case"number":case"string":case"undefined":return t;case"object":return t;default:return""}}function lo(t){var e=t.type;return(t=t.nodeName)&&t.toLowerCase()==="input"&&(e==="checkbox"||e==="radio")}function xy(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(o){l=""+o,i.call(this,o)}}),Object.defineProperty(t,e,{enumerable:n.enumerable}),{getValue:function(){return l},setValue:function(o){l=""+o},stopTracking:function(){t._valueTracker=null,delete t[e]}}}}function us(t){if(!t._valueTracker){var e=lo(t)?"checked":"value";t._valueTracker=xy(t,e,""+t[e])}}function no(t){if(!t)return!1;var e=t._valueTracker;if(!e)return!0;var l=e.getValue(),n="";return t&&(n=lo(t)?t.checked?"true":"false":t.value),t=n,t!==l?(e.setValue(t),!0):!1}function Ai(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 My=/[\n"\\]/g;function _e(t){return t.replace(My,function(e){return"\\"+e.charCodeAt(0).toString(16)+" "})}function ss(t,e,l,n,a,i,o,h){t.name="",o!=null&&typeof o!="function"&&typeof o!="symbol"&&typeof o!="boolean"?t.type=o:t.removeAttribute("type"),e!=null?o==="number"?(e===0&&t.value===""||t.value!=e)&&(t.value=""+Ae(e)):t.value!==""+Ae(e)&&(t.value=""+Ae(e)):o!=="submit"&&o!=="reset"||t.removeAttribute("value"),e!=null?cs(t,o,Ae(e)):l!=null?cs(t,o,Ae(l)):n!=null&&t.removeAttribute("value"),a==null&&i!=null&&(t.defaultChecked=!!i),a!=null&&(t.checked=a&&typeof a!="function"&&typeof a!="symbol"),h!=null&&typeof h!="function"&&typeof h!="symbol"&&typeof h!="boolean"?t.name=""+Ae(h):t.removeAttribute("name")}function ao(t,e,l,n,a,i,o,h){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)){us(t);return}l=l!=null?""+Ae(l):"",e=e!=null?""+Ae(e):l,h||e===t.value||(t.value=e),t.defaultValue=e}n=n??a,n=typeof n!="function"&&typeof n!="symbol"&&!!n,t.checked=h?t.checked:!!n,t.defaultChecked=!!n,o!=null&&typeof o!="function"&&typeof o!="symbol"&&typeof o!="boolean"&&(t.name=o),us(t)}function cs(t,e,l){e==="number"&&Ai(t.ownerDocument)===t||t.defaultValue===""+l||(t.defaultValue=""+l)}function Tn(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=""+Ae(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 io(t,e,l){if(e!=null&&(e=""+Ae(e),e!==t.value&&(t.value=e),l==null)){t.defaultValue!==e&&(t.defaultValue=e);return}t.defaultValue=l!=null?""+Ae(l):""}function uo(t,e,l,n){if(e==null){if(n!=null){if(l!=null)throw Error(r(92));if(Le(n)){if(1<n.length)throw Error(r(93));n=n[0]}l=n}l==null&&(l=""),e=l}l=Ae(e),t.defaultValue=l,n=t.textContent,n===l&&n!==""&&n!==null&&(t.value=n),us(t)}function An(t,e){if(e){var l=t.firstChild;if(l&&l===t.lastChild&&l.nodeType===3){l.nodeValue=e;return}}t.textContent=e}var Cy=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 so(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||Cy.has(e)?e==="float"?t.cssFloat=l:t[e]=(""+l).trim():t[e]=l+"px"}function co(t,e,l){if(e!=null&&typeof e!="object")throw Error(r(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&&so(t,a,n)}else for(var i in e)e.hasOwnProperty(i)&&so(t,i,e[i])}function rs(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 zy=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"]]),Oy=/^[\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 _i(t){return Oy.test(""+t)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":t}function Ie(){}var os=null;function fs(t){return t=t.target||t.srcElement||window,t.correspondingUseElement&&(t=t.correspondingUseElement),t.nodeType===3?t.parentNode:t}var _n=null,xn=null;function ro(t){var e=Sn(t);if(e&&(t=e.stateNode)){var l=t[ie]||null;t:switch(t=e.stateNode,e.type){case"input":if(ss(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="'+_e(""+e)+'"][type="radio"]'),e=0;e<l.length;e++){var n=l[e];if(n!==t&&n.form===t.form){var a=n[ie]||null;if(!a)throw Error(r(90));ss(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&&no(n)}break t;case"textarea":io(t,l.value,l.defaultValue);break t;case"select":e=l.value,e!=null&&Tn(t,!!l.multiple,e,!1)}}}var hs=!1;function oo(t,e,l){if(hs)return t(e,l);hs=!0;try{var n=t(e);return n}finally{if(hs=!1,(_n!==null||xn!==null)&&(fu(),_n&&(e=_n,t=xn,xn=_n=null,ro(e),t)))for(e=0;e<t.length;e++)ro(t[e])}}function ma(t,e){var l=t.stateNode;if(l===null)return null;var n=l[ie]||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(r(231,e,typeof l));return l}var Pe=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),ds=!1;if(Pe)try{var ya={};Object.defineProperty(ya,"passive",{get:function(){ds=!0}}),window.addEventListener("test",ya,ya),window.removeEventListener("test",ya,ya)}catch{ds=!1}var Sl=null,ms=null,xi=null;function fo(){if(xi)return xi;var t,e=ms,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 o=l-t;for(n=1;n<=o&&e[l-n]===a[i-n];n++);return xi=a.slice(t,1<n?1-n:void 0)}function Mi(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 Ci(){return!0}function ho(){return!1}function ue(t){function e(l,n,a,i,o){this._reactName=l,this._targetInst=a,this.type=n,this.nativeEvent=i,this.target=o,this.currentTarget=null;for(var h in t)t.hasOwnProperty(h)&&(l=t[h],this[h]=l?l(i):i[h]);return this.isDefaultPrevented=(i.defaultPrevented!=null?i.defaultPrevented:i.returnValue===!1)?Ci:ho,this.isPropagationStopped=ho,this}return R(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=Ci)},stopPropagation:function(){var l=this.nativeEvent;l&&(l.stopPropagation?l.stopPropagation():typeof l.cancelBubble!="unknown"&&(l.cancelBubble=!0),this.isPropagationStopped=Ci)},persist:function(){},isPersistent:Ci}),e}var Fl={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(t){return t.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},zi=ue(Fl),ga=R({},Fl,{view:0,detail:0}),Dy=ue(ga),ys,gs,pa,Oi=R({},ga,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:vs,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!==pa&&(pa&&t.type==="mousemove"?(ys=t.screenX-pa.screenX,gs=t.screenY-pa.screenY):gs=ys=0,pa=t),ys)},movementY:function(t){return"movementY"in t?t.movementY:gs}}),mo=ue(Oi),wy=R({},Oi,{dataTransfer:0}),Ry=ue(wy),Uy=R({},ga,{relatedTarget:0}),ps=ue(Uy),Ny=R({},Fl,{animationName:0,elapsedTime:0,pseudoElement:0}),Hy=ue(Ny),By=R({},Fl,{clipboardData:function(t){return"clipboardData"in t?t.clipboardData:window.clipboardData}}),Ly=ue(By),jy=R({},Fl,{data:0}),yo=ue(jy),qy={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},Yy={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"},Xy={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function Gy(t){var e=this.nativeEvent;return e.getModifierState?e.getModifierState(t):(t=Xy[t])?!!e[t]:!1}function vs(){return Gy}var Qy=R({},ga,{key:function(t){if(t.key){var e=qy[t.key]||t.key;if(e!=="Unidentified")return e}return t.type==="keypress"?(t=Mi(t),t===13?"Enter":String.fromCharCode(t)):t.type==="keydown"||t.type==="keyup"?Yy[t.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:vs,charCode:function(t){return t.type==="keypress"?Mi(t):0},keyCode:function(t){return t.type==="keydown"||t.type==="keyup"?t.keyCode:0},which:function(t){return t.type==="keypress"?Mi(t):t.type==="keydown"||t.type==="keyup"?t.keyCode:0}}),Ky=ue(Qy),Vy=R({},Oi,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),go=ue(Vy),Zy=R({},ga,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:vs}),Jy=ue(Zy),ky=R({},Fl,{propertyName:0,elapsedTime:0,pseudoElement:0}),Wy=ue(ky),$y=R({},Oi,{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}),Fy=ue($y),Iy=R({},Fl,{newState:0,oldState:0}),Py=ue(Iy),tg=[9,13,27,32],Ss=Pe&&"CompositionEvent"in window,va=null;Pe&&"documentMode"in document&&(va=document.documentMode);var eg=Pe&&"TextEvent"in window&&!va,po=Pe&&(!Ss||va&&8<va&&11>=va),vo=" ",So=!1;function bo(t,e){switch(t){case"keyup":return tg.indexOf(e.keyCode)!==-1;case"keydown":return e.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function Eo(t){return t=t.detail,typeof t=="object"&&"data"in t?t.data:null}var Mn=!1;function lg(t,e){switch(t){case"compositionend":return Eo(e);case"keypress":return e.which!==32?null:(So=!0,vo);case"textInput":return t=e.data,t===vo&&So?null:t;default:return null}}function ng(t,e){if(Mn)return t==="compositionend"||!Ss&&bo(t,e)?(t=fo(),xi=ms=Sl=null,Mn=!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 po&&e.locale!=="ko"?null:e.data;default:return null}}var ag={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 To(t){var e=t&&t.nodeName&&t.nodeName.toLowerCase();return e==="input"?!!ag[t.type]:e==="textarea"}function Ao(t,e,l,n){_n?xn?xn.push(n):xn=[n]:_n=n,e=vu(e,"onChange"),0<e.length&&(l=new zi("onChange","change",null,l,n),t.push({event:l,listeners:e}))}var Sa=null,ba=null;function ig(t){ud(t,0)}function Di(t){var e=da(t);if(no(e))return t}function _o(t,e){if(t==="change")return e}var xo=!1;if(Pe){var bs;if(Pe){var Es="oninput"in document;if(!Es){var Mo=document.createElement("div");Mo.setAttribute("oninput","return;"),Es=typeof Mo.oninput=="function"}bs=Es}else bs=!1;xo=bs&&(!document.documentMode||9<document.documentMode)}function Co(){Sa&&(Sa.detachEvent("onpropertychange",zo),ba=Sa=null)}function zo(t){if(t.propertyName==="value"&&Di(ba)){var e=[];Ao(e,ba,t,fs(t)),oo(ig,e)}}function ug(t,e,l){t==="focusin"?(Co(),Sa=e,ba=l,Sa.attachEvent("onpropertychange",zo)):t==="focusout"&&Co()}function sg(t){if(t==="selectionchange"||t==="keyup"||t==="keydown")return Di(ba)}function cg(t,e){if(t==="click")return Di(e)}function rg(t,e){if(t==="input"||t==="change")return Di(e)}function og(t,e){return t===e&&(t!==0||1/t===1/e)||t!==t&&e!==e}var ge=typeof Object.is=="function"?Object.is:og;function Ea(t,e){if(ge(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(!Iu.call(e,a)||!ge(t[a],e[a]))return!1}return!0}function Oo(t){for(;t&&t.firstChild;)t=t.firstChild;return t}function Do(t,e){var l=Oo(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=Oo(l)}}function wo(t,e){return t&&e?t===e?!0:t&&t.nodeType===3?!1:e&&e.nodeType===3?wo(t,e.parentNode):"contains"in t?t.contains(e):t.compareDocumentPosition?!!(t.compareDocumentPosition(e)&16):!1:!1}function Ro(t){t=t!=null&&t.ownerDocument!=null&&t.ownerDocument.defaultView!=null?t.ownerDocument.defaultView:window;for(var e=Ai(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=Ai(t.document)}return e}function Ts(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 fg=Pe&&"documentMode"in document&&11>=document.documentMode,Cn=null,As=null,Ta=null,_s=!1;function Uo(t,e,l){var n=l.window===l?l.document:l.nodeType===9?l:l.ownerDocument;_s||Cn==null||Cn!==Ai(n)||(n=Cn,"selectionStart"in n&&Ts(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}),Ta&&Ea(Ta,n)||(Ta=n,n=vu(As,"onSelect"),0<n.length&&(e=new zi("onSelect","select",null,e,l),t.push({event:e,listeners:n}),e.target=Cn)))}function Il(t,e){var l={};return l[t.toLowerCase()]=e.toLowerCase(),l["Webkit"+t]="webkit"+e,l["Moz"+t]="moz"+e,l}var zn={animationend:Il("Animation","AnimationEnd"),animationiteration:Il("Animation","AnimationIteration"),animationstart:Il("Animation","AnimationStart"),transitionrun:Il("Transition","TransitionRun"),transitionstart:Il("Transition","TransitionStart"),transitioncancel:Il("Transition","TransitionCancel"),transitionend:Il("Transition","TransitionEnd")},xs={},No={};Pe&&(No=document.createElement("div").style,"AnimationEvent"in window||(delete zn.animationend.animation,delete zn.animationiteration.animation,delete zn.animationstart.animation),"TransitionEvent"in window||delete zn.transitionend.transition);function Pl(t){if(xs[t])return xs[t];if(!zn[t])return t;var e=zn[t],l;for(l in e)if(e.hasOwnProperty(l)&&l in No)return xs[t]=e[l];return t}var Ho=Pl("animationend"),Bo=Pl("animationiteration"),Lo=Pl("animationstart"),hg=Pl("transitionrun"),dg=Pl("transitionstart"),mg=Pl("transitioncancel"),jo=Pl("transitionend"),qo=new Map,Ms="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(" ");Ms.push("scrollEnd");function je(t,e){qo.set(t,e),$l(e,[t])}var wi=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)},xe=[],On=0,Cs=0;function Ri(){for(var t=On,e=Cs=On=0;e<t;){var l=xe[e];xe[e++]=null;var n=xe[e];xe[e++]=null;var a=xe[e];xe[e++]=null;var i=xe[e];if(xe[e++]=null,n!==null&&a!==null){var o=n.pending;o===null?a.next=a:(a.next=o.next,o.next=a),n.pending=a}i!==0&&Yo(l,a,i)}}function Ui(t,e,l,n){xe[On++]=t,xe[On++]=e,xe[On++]=l,xe[On++]=n,Cs|=n,t.lanes|=n,t=t.alternate,t!==null&&(t.lanes|=n)}function zs(t,e,l,n){return Ui(t,e,l,n),Ni(t)}function tn(t,e){return Ui(t,null,null,e),Ni(t)}function Yo(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-ye(l),t=i.hiddenUpdates,n=t[a],n===null?t[a]=[e]:n.push(e),e.lane=l|536870912),i):null}function Ni(t){if(50<Ka)throw Ka=0,Lc=null,Error(r(185));for(var e=t.return;e!==null;)t=e,e=t.return;return t.tag===3?t.stateNode:null}var Dn={};function yg(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 pe(t,e,l,n){return new yg(t,e,l,n)}function Os(t){return t=t.prototype,!(!t||!t.isReactComponent)}function tl(t,e){var l=t.alternate;return l===null?(l=pe(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 Xo(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 Hi(t,e,l,n,a,i){var o=0;if(n=t,typeof t=="function")Os(t)&&(o=1);else if(typeof t=="string")o=bp(t,l,L.current)?26:t==="html"||t==="head"||t==="body"?27:5;else t:switch(t){case Xe:return t=pe(31,l,e,a),t.elementType=Xe,t.lanes=i,t;case ut:return en(l.children,a,i,e);case Mt:o=8,a|=24;break;case Tt:return t=pe(12,l,e,a|2),t.elementType=Tt,t.lanes=i,t;case ne:return t=pe(13,l,e,a),t.elementType=ne,t.lanes=i,t;case Xt:return t=pe(19,l,e,a),t.elementType=Xt,t.lanes=i,t;default:if(typeof t=="object"&&t!==null)switch(t.$$typeof){case Nt:o=10;break t;case Ut:o=9;break t;case le:o=11;break t;case $:o=14;break t;case Ct:o=16,n=null;break t}o=29,l=Error(r(130,t===null?"null":typeof t,"")),n=null}return e=pe(o,l,e,a),e.elementType=t,e.type=n,e.lanes=i,e}function en(t,e,l,n){return t=pe(7,t,n,e),t.lanes=l,t}function Ds(t,e,l){return t=pe(6,t,null,e),t.lanes=l,t}function Go(t){var e=pe(18,null,null,0);return e.stateNode=t,e}function ws(t,e,l){return e=pe(4,t.children!==null?t.children:[],t.key,e),e.lanes=l,e.stateNode={containerInfo:t.containerInfo,pendingChildren:null,implementation:t.implementation},e}var Qo=new WeakMap;function Me(t,e){if(typeof t=="object"&&t!==null){var l=Qo.get(t);return l!==void 0?l:(e={value:t,source:e,stack:Xr(e)},Qo.set(t,e),e)}return{value:t,source:e,stack:Xr(e)}}var wn=[],Rn=0,Bi=null,Aa=0,Ce=[],ze=0,bl=null,Qe=1,Ke="";function el(t,e){wn[Rn++]=Aa,wn[Rn++]=Bi,Bi=t,Aa=e}function Ko(t,e,l){Ce[ze++]=Qe,Ce[ze++]=Ke,Ce[ze++]=bl,bl=t;var n=Qe;t=Ke;var a=32-ye(n)-1;n&=~(1<<a),l+=1;var i=32-ye(e)+a;if(30<i){var o=a-a%5;i=(n&(1<<o)-1).toString(32),n>>=o,a-=o,Qe=1<<32-ye(e)+a|l<<a|n,Ke=i+t}else Qe=1<<i|l<<a|n,Ke=t}function Rs(t){t.return!==null&&(el(t,1),Ko(t,1,0))}function Us(t){for(;t===Bi;)Bi=wn[--Rn],wn[Rn]=null,Aa=wn[--Rn],wn[Rn]=null;for(;t===bl;)bl=Ce[--ze],Ce[ze]=null,Ke=Ce[--ze],Ce[ze]=null,Qe=Ce[--ze],Ce[ze]=null}function Vo(t,e){Ce[ze++]=Qe,Ce[ze++]=Ke,Ce[ze++]=bl,Qe=e.id,Ke=e.overflow,bl=t}var Zt=null,At=null,lt=!1,El=null,Oe=!1,Ns=Error(r(519));function Tl(t){var e=Error(r(418,1<arguments.length&&arguments[1]!==void 0&&arguments[1]?"text":"HTML",""));throw _a(Me(e,t)),Ns}function Zo(t){var e=t.stateNode,l=t.type,n=t.memoizedProps;switch(e[Vt]=t,e[ie]=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<Za.length;l++)P(Za[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),ao(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),uo(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||od(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=Ie),e=!0):e=!1,e||Tl(t,!0)}function Jo(t){for(Zt=t.return;Zt;)switch(Zt.tag){case 5:case 31:case 13:Oe=!1;return;case 27:case 3:Oe=!0;return;default:Zt=Zt.return}}function Un(t){if(t!==Zt)return!1;if(!lt)return Jo(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")||Ic(t.type,t.memoizedProps)),l=!l),l&&At&&Tl(t),Jo(t),e===13){if(t=t.memoizedState,t=t!==null?t.dehydrated:null,!t)throw Error(r(317));At=Sd(t)}else if(e===31){if(t=t.memoizedState,t=t!==null?t.dehydrated:null,!t)throw Error(r(317));At=Sd(t)}else e===27?(e=At,Bl(t.type)?(t=nr,nr=null,At=t):At=e):At=Zt?we(t.stateNode.nextSibling):null;return!0}function ln(){At=Zt=null,lt=!1}function Hs(){var t=El;return t!==null&&(oe===null?oe=t:oe.push.apply(oe,t),El=null),t}function _a(t){El===null?El=[t]:El.push(t)}var Bs=v(null),nn=null,ll=null;function Al(t,e,l){H(Bs,e._currentValue),e._currentValue=l}function nl(t){t._currentValue=Bs.current,w(Bs)}function Ls(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 js(t,e,l,n){var a=t.child;for(a!==null&&(a.return=t);a!==null;){var i=a.dependencies;if(i!==null){var o=a.child;i=i.firstContext;t:for(;i!==null;){var h=i;i=a;for(var m=0;m<e.length;m++)if(h.context===e[m]){i.lanes|=l,h=i.alternate,h!==null&&(h.lanes|=l),Ls(i.return,l,t),n||(o=null);break t}i=h.next}}else if(a.tag===18){if(o=a.return,o===null)throw Error(r(341));o.lanes|=l,i=o.alternate,i!==null&&(i.lanes|=l),Ls(o,l,t),o=null}else o=a.child;if(o!==null)o.return=a;else for(o=a;o!==null;){if(o===t){o=null;break}if(a=o.sibling,a!==null){a.return=o.return,o=a;break}o=o.return}a=o}}function Nn(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 o=a.alternate;if(o===null)throw Error(r(387));if(o=o.memoizedProps,o!==null){var h=a.type;ge(a.pendingProps.value,o.value)||(t!==null?t.push(h):t=[h])}}else if(a===rt.current){if(o=a.alternate,o===null)throw Error(r(387));o.memoizedState.memoizedState!==a.memoizedState.memoizedState&&(t!==null?t.push(Fa):t=[Fa])}a=a.return}t!==null&&js(e,t,l,n),e.flags|=262144}function Li(t){for(t=t.firstContext;t!==null;){if(!ge(t.context._currentValue,t.memoizedValue))return!0;t=t.next}return!1}function an(t){nn=t,ll=null,t=t.dependencies,t!==null&&(t.firstContext=null)}function Jt(t){return ko(nn,t)}function ji(t,e){return nn===null&&an(t),ko(t,e)}function ko(t,e){var l=e._currentValue;if(e={context:e,memoizedValue:l,next:null},ll===null){if(t===null)throw Error(r(308));ll=e,t.dependencies={lanes:0,firstContext:e},t.flags|=524288}else ll=ll.next=e;return l}var gg=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()})}},pg=s.unstable_scheduleCallback,vg=s.unstable_NormalPriority,Ht={$$typeof:Nt,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function qs(){return{controller:new gg,data:new Map,refCount:0}}function xa(t){t.refCount--,t.refCount===0&&pg(vg,function(){t.controller.abort()})}var Ma=null,Ys=0,Hn=0,Bn=null;function Sg(t,e){if(Ma===null){var l=Ma=[];Ys=0,Hn=Qc(),Bn={status:"pending",value:void 0,then:function(n){l.push(n)}}}return Ys++,e.then(Wo,Wo),e}function Wo(){if(--Ys===0&&Ma!==null){Bn!==null&&(Bn.status="fulfilled");var t=Ma;Ma=null,Hn=0,Bn=null;for(var e=0;e<t.length;e++)(0,t[e])()}}function bg(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 $o=z.S;z.S=function(t,e){Nh=de(),typeof e=="object"&&e!==null&&typeof e.then=="function"&&Sg(t,e),$o!==null&&$o(t,e)};var un=v(null);function Xs(){var t=un.current;return t!==null?t:vt.pooledCache}function qi(t,e){e===null?H(un,un.current):H(un,e.pool)}function Fo(){var t=Xs();return t===null?null:{parent:Ht._currentValue,pool:t}}var Ln=Error(r(460)),Gs=Error(r(474)),Yi=Error(r(542)),Xi={then:function(){}};function Io(t){return t=t.status,t==="fulfilled"||t==="rejected"}function Po(t,e,l){switch(l=t[l],l===void 0?t.push(e):l!==e&&(e.then(Ie,Ie),e=l),e.status){case"fulfilled":return e.value;case"rejected":throw t=e.reason,ef(t),t;default:if(typeof e.status=="string")e.then(Ie,Ie);else{if(t=vt,t!==null&&100<t.shellSuspendCounter)throw Error(r(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,ef(t),t}throw cn=e,Ln}}function sn(t){try{var e=t._init;return e(t._payload)}catch(l){throw l!==null&&typeof l=="object"&&typeof l.then=="function"?(cn=l,Ln):l}}var cn=null;function tf(){if(cn===null)throw Error(r(459));var t=cn;return cn=null,t}function ef(t){if(t===Ln||t===Yi)throw Error(r(483))}var jn=null,Ca=0;function Gi(t){var e=Ca;return Ca+=1,jn===null&&(jn=[]),Po(jn,t,e)}function za(t,e){e=e.props.ref,t.ref=e!==void 0?e:null}function Qi(t,e){throw e.$$typeof===W?Error(r(525)):(t=Object.prototype.toString.call(e),Error(r(31,t==="[object Object]"?"object with keys {"+Object.keys(e).join(", ")+"}":t)))}function lf(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=tl(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 o(S){return t&&S.alternate===null&&(S.flags|=67108866),S}function h(S,g,T,O){return g===null||g.tag!==6?(g=Ds(T,S.mode,O),g.return=S,g):(g=a(g,T),g.return=S,g)}function m(S,g,T,O){var q=T.type;return q===ut?C(S,g,T.props.children,O,T.key):g!==null&&(g.elementType===q||typeof q=="object"&&q!==null&&q.$$typeof===Ct&&sn(q)===g.type)?(g=a(g,T.props),za(g,T),g.return=S,g):(g=Hi(T.type,T.key,T.props,null,S.mode,O),za(g,T),g.return=S,g)}function A(S,g,T,O){return g===null||g.tag!==4||g.stateNode.containerInfo!==T.containerInfo||g.stateNode.implementation!==T.implementation?(g=ws(T,S.mode,O),g.return=S,g):(g=a(g,T.children||[]),g.return=S,g)}function C(S,g,T,O,q){return g===null||g.tag!==7?(g=en(T,S.mode,O,q),g.return=S,g):(g=a(g,T),g.return=S,g)}function D(S,g,T){if(typeof g=="string"&&g!==""||typeof g=="number"||typeof g=="bigint")return g=Ds(""+g,S.mode,T),g.return=S,g;if(typeof g=="object"&&g!==null){switch(g.$$typeof){case ct:return T=Hi(g.type,g.key,g.props,null,S.mode,T),za(T,g),T.return=S,T;case Et:return g=ws(g,S.mode,T),g.return=S,g;case Ct:return g=sn(g),D(S,g,T)}if(Le(g)||ae(g))return g=en(g,S.mode,T,null),g.return=S,g;if(typeof g.then=="function")return D(S,Gi(g),T);if(g.$$typeof===Nt)return D(S,ji(S,g),T);Qi(S,g)}return null}function _(S,g,T,O){var q=g!==null?g.key:null;if(typeof T=="string"&&T!==""||typeof T=="number"||typeof T=="bigint")return q!==null?null:h(S,g,""+T,O);if(typeof T=="object"&&T!==null){switch(T.$$typeof){case ct:return T.key===q?m(S,g,T,O):null;case Et:return T.key===q?A(S,g,T,O):null;case Ct:return T=sn(T),_(S,g,T,O)}if(Le(T)||ae(T))return q!==null?null:C(S,g,T,O,null);if(typeof T.then=="function")return _(S,g,Gi(T),O);if(T.$$typeof===Nt)return _(S,g,ji(S,T),O);Qi(S,T)}return null}function x(S,g,T,O,q){if(typeof O=="string"&&O!==""||typeof O=="number"||typeof O=="bigint")return S=S.get(T)||null,h(g,S,""+O,q);if(typeof O=="object"&&O!==null){switch(O.$$typeof){case ct:return S=S.get(O.key===null?T:O.key)||null,m(g,S,O,q);case Et:return S=S.get(O.key===null?T:O.key)||null,A(g,S,O,q);case Ct:return O=sn(O),x(S,g,T,O,q)}if(Le(O)||ae(O))return S=S.get(T)||null,C(g,S,O,q,null);if(typeof O.then=="function")return x(S,g,T,Gi(O),q);if(O.$$typeof===Nt)return x(S,g,T,ji(g,O),q);Qi(g,O)}return null}function B(S,g,T,O){for(var q=null,at=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 it=_(S,j,T[k],O);if(it===null){j===null&&(j=et);break}t&&j&&it.alternate===null&&e(S,j),g=i(it,g,k),at===null?q=it:at.sibling=it,at=it,j=et}if(k===T.length)return l(S,j),lt&&el(S,k),q;if(j===null){for(;k<T.length;k++)j=D(S,T[k],O),j!==null&&(g=i(j,g,k),at===null?q=j:at.sibling=j,at=j);return lt&&el(S,k),q}for(j=n(j);k<T.length;k++)et=x(j,S,k,T[k],O),et!==null&&(t&&et.alternate!==null&&j.delete(et.key===null?k:et.key),g=i(et,g,k),at===null?q=et:at.sibling=et,at=et);return t&&j.forEach(function(Xl){return e(S,Xl)}),lt&&el(S,k),q}function X(S,g,T,O){if(T==null)throw Error(r(151));for(var q=null,at=null,j=g,k=g=0,et=null,it=T.next();j!==null&&!it.done;k++,it=T.next()){j.index>k?(et=j,j=null):et=j.sibling;var Xl=_(S,j,it.value,O);if(Xl===null){j===null&&(j=et);break}t&&j&&Xl.alternate===null&&e(S,j),g=i(Xl,g,k),at===null?q=Xl:at.sibling=Xl,at=Xl,j=et}if(it.done)return l(S,j),lt&&el(S,k),q;if(j===null){for(;!it.done;k++,it=T.next())it=D(S,it.value,O),it!==null&&(g=i(it,g,k),at===null?q=it:at.sibling=it,at=it);return lt&&el(S,k),q}for(j=n(j);!it.done;k++,it=T.next())it=x(j,S,k,it.value,O),it!==null&&(t&&it.alternate!==null&&j.delete(it.key===null?k:it.key),g=i(it,g,k),at===null?q=it:at.sibling=it,at=it);return t&&j.forEach(function(wp){return e(S,wp)}),lt&&el(S,k),q}function gt(S,g,T,O){if(typeof T=="object"&&T!==null&&T.type===ut&&T.key===null&&(T=T.props.children),typeof T=="object"&&T!==null){switch(T.$$typeof){case ct:t:{for(var q=T.key;g!==null;){if(g.key===q){if(q=T.type,q===ut){if(g.tag===7){l(S,g.sibling),O=a(g,T.props.children),O.return=S,S=O;break t}}else if(g.elementType===q||typeof q=="object"&&q!==null&&q.$$typeof===Ct&&sn(q)===g.type){l(S,g.sibling),O=a(g,T.props),za(O,T),O.return=S,S=O;break t}l(S,g);break}else e(S,g);g=g.sibling}T.type===ut?(O=en(T.props.children,S.mode,O,T.key),O.return=S,S=O):(O=Hi(T.type,T.key,T.props,null,S.mode,O),za(O,T),O.return=S,S=O)}return o(S);case Et: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),O=a(g,T.children||[]),O.return=S,S=O;break t}else{l(S,g);break}else e(S,g);g=g.sibling}O=ws(T,S.mode,O),O.return=S,S=O}return o(S);case Ct:return T=sn(T),gt(S,g,T,O)}if(Le(T))return B(S,g,T,O);if(ae(T)){if(q=ae(T),typeof q!="function")throw Error(r(150));return T=q.call(T),X(S,g,T,O)}if(typeof T.then=="function")return gt(S,g,Gi(T),O);if(T.$$typeof===Nt)return gt(S,g,ji(S,T),O);Qi(S,T)}return typeof T=="string"&&T!==""||typeof T=="number"||typeof T=="bigint"?(T=""+T,g!==null&&g.tag===6?(l(S,g.sibling),O=a(g,T),O.return=S,S=O):(l(S,g),O=Ds(T,S.mode,O),O.return=S,S=O),o(S)):l(S,g)}return function(S,g,T,O){try{Ca=0;var q=gt(S,g,T,O);return jn=null,q}catch(j){if(j===Ln||j===Yi)throw j;var at=pe(29,j,null,S.mode);return at.lanes=O,at.return=S,at}finally{}}}var rn=lf(!0),nf=lf(!1),_l=!1;function Qs(t){t.updateQueue={baseState:t.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function Ks(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,(st&2)!==0){var a=n.pending;return a===null?e.next=e:(e.next=a.next,a.next=e),n.pending=e,e=Ni(t),Yo(t,null,l),e}return Ui(t,n,e,l),Ni(t)}function Oa(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,Jr(t,l)}}function Vs(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 o={lane:l.lane,tag:l.tag,payload:l.payload,callback:null,next:null};i===null?a=i=o:i=i.next=o,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 Zs=!1;function Da(){if(Zs){var t=Bn;if(t!==null)throw t}}function wa(t,e,l,n){Zs=!1;var a=t.updateQueue;_l=!1;var i=a.firstBaseUpdate,o=a.lastBaseUpdate,h=a.shared.pending;if(h!==null){a.shared.pending=null;var m=h,A=m.next;m.next=null,o===null?i=A:o.next=A,o=m;var C=t.alternate;C!==null&&(C=C.updateQueue,h=C.lastBaseUpdate,h!==o&&(h===null?C.firstBaseUpdate=A:h.next=A,C.lastBaseUpdate=m))}if(i!==null){var D=a.baseState;o=0,C=A=m=null,h=i;do{var _=h.lane&-536870913,x=_!==h.lane;if(x?(tt&_)===_:(n&_)===_){_!==0&&_===Hn&&(Zs=!0),C!==null&&(C=C.next={lane:0,tag:h.tag,payload:h.payload,callback:null,next:null});t:{var B=t,X=h;_=e;var gt=l;switch(X.tag){case 1:if(B=X.payload,typeof B=="function"){D=B.call(gt,D,_);break t}D=B;break t;case 3:B.flags=B.flags&-65537|128;case 0:if(B=X.payload,_=typeof B=="function"?B.call(gt,D,_):B,_==null)break t;D=R({},D,_);break t;case 2:_l=!0}}_=h.callback,_!==null&&(t.flags|=64,x&&(t.flags|=8192),x=a.callbacks,x===null?a.callbacks=[_]:x.push(_))}else x={lane:_,tag:h.tag,payload:h.payload,callback:h.callback,next:null},C===null?(A=C=x,m=D):C=C.next=x,o|=_;if(h=h.next,h===null){if(h=a.shared.pending,h===null)break;x=h,h=x.next,x.next=null,a.lastBaseUpdate=x,a.shared.pending=null}}while(!0);C===null&&(m=D),a.baseState=m,a.firstBaseUpdate=A,a.lastBaseUpdate=C,i===null&&(a.shared.lanes=0),wl|=o,t.lanes=o,t.memoizedState=D}}function af(t,e){if(typeof t!="function")throw Error(r(191,t));t.call(e)}function uf(t,e){var l=t.callbacks;if(l!==null)for(t.callbacks=null,t=0;t<l.length;t++)af(l[t],e)}var qn=v(null),Ki=v(0);function sf(t,e){t=hl,H(Ki,t),H(qn,e),hl=t|e.baseLanes}function Js(){H(Ki,hl),H(qn,qn.current)}function ks(){hl=Ki.current,w(qn),w(Ki)}var ve=v(null),De=null;function Cl(t){var e=t.alternate;H(wt,wt.current&1),H(ve,t),De===null&&(e===null||qn.current!==null||e.memoizedState!==null)&&(De=t)}function Ws(t){H(wt,wt.current),H(ve,t),De===null&&(De=t)}function cf(t){t.tag===22?(H(wt,wt.current),H(ve,t),De===null&&(De=t)):zl()}function zl(){H(wt,wt.current),H(ve,ve.current)}function Se(t){w(ve),De===t&&(De=null),w(wt)}var wt=v(0);function Vi(t){for(var e=t;e!==null;){if(e.tag===13){var l=e.memoizedState;if(l!==null&&(l=l.dehydrated,l===null||er(l)||lr(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 al=0,J=null,mt=null,Bt=null,Zi=!1,Yn=!1,on=!1,Ji=0,Ra=0,Xn=null,Eg=0;function zt(){throw Error(r(321))}function $s(t,e){if(e===null)return!1;for(var l=0;l<e.length&&l<t.length;l++)if(!ge(t[l],e[l]))return!1;return!0}function Fs(t,e,l,n,a,i){return al=i,J=e,e.memoizedState=null,e.updateQueue=null,e.lanes=0,z.H=t===null||t.memoizedState===null?Vf:hc,on=!1,i=l(n,a),on=!1,Yn&&(i=of(e,l,n,a)),rf(t),i}function rf(t){z.H=Ha;var e=mt!==null&&mt.next!==null;if(al=0,Bt=mt=J=null,Zi=!1,Ra=0,Xn=null,e)throw Error(r(300));t===null||Lt||(t=t.dependencies,t!==null&&Li(t)&&(Lt=!0))}function of(t,e,l,n){J=t;var a=0;do{if(Yn&&(Xn=null),Ra=0,Yn=!1,25<=a)throw Error(r(301));if(a+=1,Bt=mt=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=Zf,i=e(l,n)}while(Yn);return i}function Tg(){var t=z.H,e=t.useState()[0];return e=typeof e.then=="function"?Ua(e):e,t=t.useState()[0],(mt!==null?mt.memoizedState:null)!==t&&(J.flags|=1024),e}function Is(){var t=Ji!==0;return Ji=0,t}function Ps(t,e,l){e.updateQueue=t.updateQueue,e.flags&=-2053,t.lanes&=~l}function tc(t){if(Zi){for(t=t.memoizedState;t!==null;){var e=t.queue;e!==null&&(e.pending=null),t=t.next}Zi=!1}al=0,Bt=mt=J=null,Yn=!1,Ra=Ji=0,Xn=null}function te(){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 Rt(){if(mt===null){var t=J.alternate;t=t!==null?t.memoizedState:null}else t=mt.next;var e=Bt===null?J.memoizedState:Bt.next;if(e!==null)Bt=e,mt=t;else{if(t===null)throw J.alternate===null?Error(r(467)):Error(r(310));mt=t,t={memoizedState:mt.memoizedState,baseState:mt.baseState,baseQueue:mt.baseQueue,queue:mt.queue,next:null},Bt===null?J.memoizedState=Bt=t:Bt=Bt.next=t}return Bt}function ki(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function Ua(t){var e=Ra;return Ra+=1,Xn===null&&(Xn=[]),t=Po(Xn,t,e),e=J,(Bt===null?e.memoizedState:Bt.next)===null&&(e=e.alternate,z.H=e===null||e.memoizedState===null?Vf:hc),t}function Wi(t){if(t!==null&&typeof t=="object"){if(typeof t.then=="function")return Ua(t);if(t.$$typeof===Nt)return Jt(t)}throw Error(r(438,String(t)))}function ec(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=ki(),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]=gn;return e.index++,l}function il(t,e){return typeof e=="function"?e(t):e}function $i(t){var e=Rt();return lc(e,mt,t)}function lc(t,e,l){var n=t.queue;if(n===null)throw Error(r(311));n.lastRenderedReducer=l;var a=t.baseQueue,i=n.pending;if(i!==null){if(a!==null){var o=a.next;a.next=i.next,i.next=o}e.baseQueue=a=i,n.pending=null}if(i=t.baseState,a===null)t.memoizedState=i;else{e=a.next;var h=o=null,m=null,A=e,C=!1;do{var D=A.lane&-536870913;if(D!==A.lane?(tt&D)===D:(al&D)===D){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}),D===Hn&&(C=!0);else if((al&_)===_){A=A.next,_===Hn&&(C=!0);continue}else D={lane:0,revertLane:A.revertLane,gesture:null,action:A.action,hasEagerState:A.hasEagerState,eagerState:A.eagerState,next:null},m===null?(h=m=D,o=i):m=m.next=D,J.lanes|=_,wl|=_;D=A.action,on&&l(i,D),i=A.hasEagerState?A.eagerState:l(i,D)}else _={lane:D,revertLane:A.revertLane,gesture:A.gesture,action:A.action,hasEagerState:A.hasEagerState,eagerState:A.eagerState,next:null},m===null?(h=m=_,o=i):m=m.next=_,J.lanes|=D,wl|=D;A=A.next}while(A!==null&&A!==e);if(m===null?o=i:m.next=h,!ge(i,t.memoizedState)&&(Lt=!0,C&&(l=Bn,l!==null)))throw l;t.memoizedState=i,t.baseState=o,t.baseQueue=m,n.lastRenderedState=i}return a===null&&(n.lanes=0),[t.memoizedState,n.dispatch]}function nc(t){var e=Rt(),l=e.queue;if(l===null)throw Error(r(311));l.lastRenderedReducer=t;var n=l.dispatch,a=l.pending,i=e.memoizedState;if(a!==null){l.pending=null;var o=a=a.next;do i=t(i,o.action),o=o.next;while(o!==a);ge(i,e.memoizedState)||(Lt=!0),e.memoizedState=i,e.baseQueue===null&&(e.baseState=i),l.lastRenderedState=i}return[i,n]}function ff(t,e,l){var n=J,a=Rt(),i=lt;if(i){if(l===void 0)throw Error(r(407));l=l()}else l=e();var o=!ge((mt||a).memoizedState,l);if(o&&(a.memoizedState=l,Lt=!0),a=a.queue,uc(mf.bind(null,n,a,t),[t]),a.getSnapshot!==e||o||Bt!==null&&Bt.memoizedState.tag&1){if(n.flags|=2048,Gn(9,{destroy:void 0},df.bind(null,n,a,l,e),null),vt===null)throw Error(r(349));i||(al&127)!==0||hf(n,e,l)}return l}function hf(t,e,l){t.flags|=16384,t={getSnapshot:e,value:l},e=J.updateQueue,e===null?(e=ki(),J.updateQueue=e,e.stores=[t]):(l=e.stores,l===null?e.stores=[t]:l.push(t))}function df(t,e,l,n){e.value=l,e.getSnapshot=n,yf(e)&&gf(t)}function mf(t,e,l){return l(function(){yf(e)&&gf(t)})}function yf(t){var e=t.getSnapshot;t=t.value;try{var l=e();return!ge(t,l)}catch{return!0}}function gf(t){var e=tn(t,2);e!==null&&fe(e,t,2)}function ac(t){var e=te();if(typeof t=="function"){var l=t;if(t=l(),on){pl(!0);try{l()}finally{pl(!1)}}}return e.memoizedState=e.baseState=t,e.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:il,lastRenderedState:t},e}function pf(t,e,l,n){return t.baseState=l,lc(t,mt,typeof n=="function"?n:il)}function Ag(t,e,l,n,a){if(Pi(t))throw Error(r(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(o){i.listeners.push(o)}};z.T!==null?l(!0):i.isTransition=!1,n(i),l=e.pending,l===null?(i.next=e.pending=i,vf(e,i)):(i.next=l.next,e.pending=l.next=i)}}function vf(t,e){var l=e.action,n=e.payload,a=t.state;if(e.isTransition){var i=z.T,o={};z.T=o;try{var h=l(a,n),m=z.S;m!==null&&m(o,h),Sf(t,e,h)}catch(A){ic(t,e,A)}finally{i!==null&&o.types!==null&&(i.types=o.types),z.T=i}}else try{i=l(a,n),Sf(t,e,i)}catch(A){ic(t,e,A)}}function Sf(t,e,l){l!==null&&typeof l=="object"&&typeof l.then=="function"?l.then(function(n){bf(t,e,n)},function(n){return ic(t,e,n)}):bf(t,e,l)}function bf(t,e,l){e.status="fulfilled",e.value=l,Ef(e),t.state=l,e=t.pending,e!==null&&(l=e.next,l===e?t.pending=null:(l=l.next,e.next=l,vf(t,l)))}function ic(t,e,l){var n=t.pending;if(t.pending=null,n!==null){n=n.next;do e.status="rejected",e.reason=l,Ef(e),e=e.next;while(e!==n)}t.action=null}function Ef(t){t=t.listeners;for(var e=0;e<t.length;e++)(0,t[e])()}function Tf(t,e){return e}function Af(t,e){if(lt){var l=vt.formState;if(l!==null){t:{var n=J;if(lt){if(At){e:{for(var a=At,i=Oe;a.nodeType!==8;){if(!i){a=null;break e}if(a=we(a.nextSibling),a===null){a=null;break e}}i=a.data,a=i==="F!"||i==="F"?a:null}if(a){At=we(a.nextSibling),n=a.data==="F!";break t}}Tl(n)}n=!1}n&&(e=l[0])}}return l=te(),l.memoizedState=l.baseState=e,n={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Tf,lastRenderedState:e},l.queue=n,l=Gf.bind(null,J,n),n.dispatch=l,n=ac(!1),i=fc.bind(null,J,!1,n.queue),n=te(),a={state:e,dispatch:null,action:t,pending:null},n.queue=a,l=Ag.bind(null,J,a,i,l),a.dispatch=l,n.memoizedState=t,[e,l,!1]}function _f(t){var e=Rt();return xf(e,mt,t)}function xf(t,e,l){if(e=lc(t,e,Tf)[0],t=$i(il)[0],typeof e=="object"&&e!==null&&typeof e.then=="function")try{var n=Ua(e)}catch(o){throw o===Ln?Yi:o}else n=e;e=Rt();var a=e.queue,i=a.dispatch;return l!==e.memoizedState&&(J.flags|=2048,Gn(9,{destroy:void 0},_g.bind(null,a,l),null)),[n,i,t]}function _g(t,e){t.action=e}function Mf(t){var e=Rt(),l=mt;if(l!==null)return xf(e,l,t);Rt(),e=e.memoizedState,l=Rt();var n=l.queue.dispatch;return l.memoizedState=t,[e,n,!1]}function Gn(t,e,l,n){return t={tag:t,create:l,deps:n,inst:e,next:null},e=J.updateQueue,e===null&&(e=ki(),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 Cf(){return Rt().memoizedState}function Fi(t,e,l,n){var a=te();J.flags|=t,a.memoizedState=Gn(1|e,{destroy:void 0},l,n===void 0?null:n)}function Ii(t,e,l,n){var a=Rt();n=n===void 0?null:n;var i=a.memoizedState.inst;mt!==null&&n!==null&&$s(n,mt.memoizedState.deps)?a.memoizedState=Gn(e,i,l,n):(J.flags|=t,a.memoizedState=Gn(1|e,i,l,n))}function zf(t,e){Fi(8390656,8,t,e)}function uc(t,e){Ii(2048,8,t,e)}function xg(t){J.flags|=4;var e=J.updateQueue;if(e===null)e=ki(),J.updateQueue=e,e.events=[t];else{var l=e.events;l===null?e.events=[t]:l.push(t)}}function Of(t){var e=Rt().memoizedState;return xg({ref:e,nextImpl:t}),function(){if((st&2)!==0)throw Error(r(440));return e.impl.apply(void 0,arguments)}}function Df(t,e){return Ii(4,2,t,e)}function wf(t,e){return Ii(4,4,t,e)}function Rf(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 Uf(t,e,l){l=l!=null?l.concat([t]):null,Ii(4,4,Rf.bind(null,e,t),l)}function sc(){}function Nf(t,e){var l=Rt();e=e===void 0?null:e;var n=l.memoizedState;return e!==null&&$s(e,n[1])?n[0]:(l.memoizedState=[t,e],t)}function Hf(t,e){var l=Rt();e=e===void 0?null:e;var n=l.memoizedState;if(e!==null&&$s(e,n[1]))return n[0];if(n=t(),on){pl(!0);try{t()}finally{pl(!1)}}return l.memoizedState=[n,e],n}function cc(t,e,l){return l===void 0||(al&1073741824)!==0&&(tt&261930)===0?t.memoizedState=e:(t.memoizedState=l,t=Bh(),J.lanes|=t,wl|=t,l)}function Bf(t,e,l,n){return ge(l,e)?l:qn.current!==null?(t=cc(t,l,n),ge(t,e)||(Lt=!0),t):(al&42)===0||(al&1073741824)!==0&&(tt&261930)===0?(Lt=!0,t.memoizedState=l):(t=Bh(),J.lanes|=t,wl|=t,e)}function Lf(t,e,l,n,a){var i=N.p;N.p=i!==0&&8>i?i:8;var o=z.T,h={};z.T=h,fc(t,!1,e,l);try{var m=a(),A=z.S;if(A!==null&&A(h,m),m!==null&&typeof m=="object"&&typeof m.then=="function"){var C=bg(m,n);Na(t,e,C,Te(t))}else Na(t,e,n,Te(t))}catch(D){Na(t,e,{then:function(){},status:"rejected",reason:D},Te())}finally{N.p=i,o!==null&&h.types!==null&&(o.types=h.types),z.T=o}}function Mg(){}function rc(t,e,l,n){if(t.tag!==5)throw Error(r(476));var a=jf(t).queue;Lf(t,a,e,Q,l===null?Mg:function(){return qf(t),l(n)})}function jf(t){var e=t.memoizedState;if(e!==null)return e;e={memoizedState:Q,baseState:Q,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:il,lastRenderedState:Q},next:null};var l={};return e.next={memoizedState:l,baseState:l,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:il,lastRenderedState:l},next:null},t.memoizedState=e,t=t.alternate,t!==null&&(t.memoizedState=e),e}function qf(t){var e=jf(t);e.next===null&&(e=t.alternate.memoizedState),Na(t,e.next.queue,{},Te())}function oc(){return Jt(Fa)}function Yf(){return Rt().memoizedState}function Xf(){return Rt().memoizedState}function Cg(t){for(var e=t.return;e!==null;){switch(e.tag){case 24:case 3:var l=Te();t=xl(l);var n=Ml(e,t,l);n!==null&&(fe(n,e,l),Oa(n,e,l)),e={cache:qs()},t.payload=e;return}e=e.return}}function zg(t,e,l){var n=Te();l={lane:n,revertLane:0,gesture:null,action:l,hasEagerState:!1,eagerState:null,next:null},Pi(t)?Qf(e,l):(l=zs(t,e,l,n),l!==null&&(fe(l,t,n),Kf(l,e,n)))}function Gf(t,e,l){var n=Te();Na(t,e,l,n)}function Na(t,e,l,n){var a={lane:n,revertLane:0,gesture:null,action:l,hasEagerState:!1,eagerState:null,next:null};if(Pi(t))Qf(e,a);else{var i=t.alternate;if(t.lanes===0&&(i===null||i.lanes===0)&&(i=e.lastRenderedReducer,i!==null))try{var o=e.lastRenderedState,h=i(o,l);if(a.hasEagerState=!0,a.eagerState=h,ge(h,o))return Ui(t,e,a,0),vt===null&&Ri(),!1}catch{}finally{}if(l=zs(t,e,a,n),l!==null)return fe(l,t,n),Kf(l,e,n),!0}return!1}function fc(t,e,l,n){if(n={lane:2,revertLane:Qc(),gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null},Pi(t)){if(e)throw Error(r(479))}else e=zs(t,l,n,2),e!==null&&fe(e,t,2)}function Pi(t){var e=t.alternate;return t===J||e!==null&&e===J}function Qf(t,e){Yn=Zi=!0;var l=t.pending;l===null?e.next=e:(e.next=l.next,l.next=e),t.pending=e}function Kf(t,e,l){if((l&4194048)!==0){var n=e.lanes;n&=t.pendingLanes,l|=n,e.lanes=l,Jr(t,l)}}var Ha={readContext:Jt,use:Wi,useCallback:zt,useContext:zt,useEffect:zt,useImperativeHandle:zt,useLayoutEffect:zt,useInsertionEffect:zt,useMemo:zt,useReducer:zt,useRef:zt,useState:zt,useDebugValue:zt,useDeferredValue:zt,useTransition:zt,useSyncExternalStore:zt,useId:zt,useHostTransitionStatus:zt,useFormState:zt,useActionState:zt,useOptimistic:zt,useMemoCache:zt,useCacheRefresh:zt};Ha.useEffectEvent=zt;var Vf={readContext:Jt,use:Wi,useCallback:function(t,e){return te().memoizedState=[t,e===void 0?null:e],t},useContext:Jt,useEffect:zf,useImperativeHandle:function(t,e,l){l=l!=null?l.concat([t]):null,Fi(4194308,4,Rf.bind(null,e,t),l)},useLayoutEffect:function(t,e){return Fi(4194308,4,t,e)},useInsertionEffect:function(t,e){Fi(4,2,t,e)},useMemo:function(t,e){var l=te();e=e===void 0?null:e;var n=t();if(on){pl(!0);try{t()}finally{pl(!1)}}return l.memoizedState=[n,e],n},useReducer:function(t,e,l){var n=te();if(l!==void 0){var a=l(e);if(on){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=zg.bind(null,J,t),[n.memoizedState,t]},useRef:function(t){var e=te();return t={current:t},e.memoizedState=t},useState:function(t){t=ac(t);var e=t.queue,l=Gf.bind(null,J,e);return e.dispatch=l,[t.memoizedState,l]},useDebugValue:sc,useDeferredValue:function(t,e){var l=te();return cc(l,t,e)},useTransition:function(){var t=ac(!1);return t=Lf.bind(null,J,t.queue,!0,!1),te().memoizedState=t,[!1,t]},useSyncExternalStore:function(t,e,l){var n=J,a=te();if(lt){if(l===void 0)throw Error(r(407));l=l()}else{if(l=e(),vt===null)throw Error(r(349));(tt&127)!==0||hf(n,e,l)}a.memoizedState=l;var i={value:l,getSnapshot:e};return a.queue=i,zf(mf.bind(null,n,i,t),[t]),n.flags|=2048,Gn(9,{destroy:void 0},df.bind(null,n,i,l,e),null),l},useId:function(){var t=te(),e=vt.identifierPrefix;if(lt){var l=Ke,n=Qe;l=(n&~(1<<32-ye(n)-1)).toString(32)+l,e="_"+e+"R_"+l,l=Ji++,0<l&&(e+="H"+l.toString(32)),e+="_"}else l=Eg++,e="_"+e+"r_"+l.toString(32)+"_";return t.memoizedState=e},useHostTransitionStatus:oc,useFormState:Af,useActionState:Af,useOptimistic:function(t){var e=te();e.memoizedState=e.baseState=t;var l={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return e.queue=l,e=fc.bind(null,J,!0,l),l.dispatch=e,[t,e]},useMemoCache:ec,useCacheRefresh:function(){return te().memoizedState=Cg.bind(null,J)},useEffectEvent:function(t){var e=te(),l={impl:t};return e.memoizedState=l,function(){if((st&2)!==0)throw Error(r(440));return l.impl.apply(void 0,arguments)}}},hc={readContext:Jt,use:Wi,useCallback:Nf,useContext:Jt,useEffect:uc,useImperativeHandle:Uf,useInsertionEffect:Df,useLayoutEffect:wf,useMemo:Hf,useReducer:$i,useRef:Cf,useState:function(){return $i(il)},useDebugValue:sc,useDeferredValue:function(t,e){var l=Rt();return Bf(l,mt.memoizedState,t,e)},useTransition:function(){var t=$i(il)[0],e=Rt().memoizedState;return[typeof t=="boolean"?t:Ua(t),e]},useSyncExternalStore:ff,useId:Yf,useHostTransitionStatus:oc,useFormState:_f,useActionState:_f,useOptimistic:function(t,e){var l=Rt();return pf(l,mt,t,e)},useMemoCache:ec,useCacheRefresh:Xf};hc.useEffectEvent=Of;var Zf={readContext:Jt,use:Wi,useCallback:Nf,useContext:Jt,useEffect:uc,useImperativeHandle:Uf,useInsertionEffect:Df,useLayoutEffect:wf,useMemo:Hf,useReducer:nc,useRef:Cf,useState:function(){return nc(il)},useDebugValue:sc,useDeferredValue:function(t,e){var l=Rt();return mt===null?cc(l,t,e):Bf(l,mt.memoizedState,t,e)},useTransition:function(){var t=nc(il)[0],e=Rt().memoizedState;return[typeof t=="boolean"?t:Ua(t),e]},useSyncExternalStore:ff,useId:Yf,useHostTransitionStatus:oc,useFormState:Mf,useActionState:Mf,useOptimistic:function(t,e){var l=Rt();return mt!==null?pf(l,mt,t,e):(l.baseState=t,[t,l.queue.dispatch])},useMemoCache:ec,useCacheRefresh:Xf};Zf.useEffectEvent=Of;function dc(t,e,l,n){e=t.memoizedState,l=l(n,e),l=l==null?e:R({},e,l),t.memoizedState=l,t.lanes===0&&(t.updateQueue.baseState=l)}var mc={enqueueSetState:function(t,e,l){t=t._reactInternals;var n=Te(),a=xl(n);a.payload=e,l!=null&&(a.callback=l),e=Ml(t,a,n),e!==null&&(fe(e,t,n),Oa(e,t,n))},enqueueReplaceState:function(t,e,l){t=t._reactInternals;var n=Te(),a=xl(n);a.tag=1,a.payload=e,l!=null&&(a.callback=l),e=Ml(t,a,n),e!==null&&(fe(e,t,n),Oa(e,t,n))},enqueueForceUpdate:function(t,e){t=t._reactInternals;var l=Te(),n=xl(l);n.tag=2,e!=null&&(n.callback=e),e=Ml(t,n,l),e!==null&&(fe(e,t,l),Oa(e,t,l))}};function Jf(t,e,l,n,a,i,o){return t=t.stateNode,typeof t.shouldComponentUpdate=="function"?t.shouldComponentUpdate(n,i,o):e.prototype&&e.prototype.isPureReactComponent?!Ea(l,n)||!Ea(a,i):!0}function kf(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&&mc.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=R({},l));for(var a in t)l[a]===void 0&&(l[a]=t[a])}return l}function Wf(t){wi(t)}function $f(t){console.error(t)}function Ff(t){wi(t)}function tu(t,e){try{var l=t.onUncaughtError;l(e.value,{componentStack:e.stack})}catch(n){setTimeout(function(){throw n})}}function If(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 yc(t,e,l){return l=xl(l),l.tag=3,l.payload={element:null},l.callback=function(){tu(t,e)},l}function Pf(t){return t=xl(t),t.tag=3,t}function th(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(){If(e,l,n)}}var o=l.stateNode;o!==null&&typeof o.componentDidCatch=="function"&&(t.callback=function(){If(e,l,n),typeof a!="function"&&(Rl===null?Rl=new Set([this]):Rl.add(this));var h=n.stack;this.componentDidCatch(n.value,{componentStack:h!==null?h:""})})}function Og(t,e,l,n,a){if(l.flags|=32768,n!==null&&typeof n=="object"&&typeof n.then=="function"){if(e=l.alternate,e!==null&&Nn(e,l,a,!0),l=ve.current,l!==null){switch(l.tag){case 31:case 13:return De===null?hu():l.alternate===null&&Ot===0&&(Ot=3),l.flags&=-257,l.flags|=65536,l.lanes=a,n===Xi?l.flags|=16384:(e=l.updateQueue,e===null?l.updateQueue=new Set([n]):e.add(n),Yc(t,n,a)),!1;case 22:return l.flags|=65536,n===Xi?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)),Yc(t,n,a)),!1}throw Error(r(435,l.tag))}return Yc(t,n,a),hu(),!1}if(lt)return e=ve.current,e!==null?((e.flags&65536)===0&&(e.flags|=256),e.flags|=65536,e.lanes=a,n!==Ns&&(t=Error(r(422),{cause:n}),_a(Me(t,l)))):(n!==Ns&&(e=Error(r(423),{cause:n}),_a(Me(e,l))),t=t.current.alternate,t.flags|=65536,a&=-a,t.lanes|=a,n=Me(n,l),a=yc(t.stateNode,n,a),Vs(t,a),Ot!==4&&(Ot=2)),!1;var i=Error(r(520),{cause:n});if(i=Me(i,l),Qa===null?Qa=[i]:Qa.push(i),Ot!==4&&(Ot=2),e===null)return!0;n=Me(n,l),l=e;do{switch(l.tag){case 3:return l.flags|=65536,t=a&-a,l.lanes|=t,t=yc(l.stateNode,n,t),Vs(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"&&(Rl===null||!Rl.has(i))))return l.flags|=65536,a&=-a,l.lanes|=a,a=Pf(a),th(a,t,l,n),Vs(l,a),!1}l=l.return}while(l!==null);return!1}var gc=Error(r(461)),Lt=!1;function kt(t,e,l,n){e.child=t===null?nf(e,null,l,n):rn(e,t.child,l,n)}function eh(t,e,l,n,a){l=l.render;var i=e.ref;if("ref"in n){var o={};for(var h in n)h!=="ref"&&(o[h]=n[h])}else o=n;return an(e),n=Fs(t,e,l,o,i,a),h=Is(),t!==null&&!Lt?(Ps(t,e,a),ul(t,e,a)):(lt&&h&&Rs(e),e.flags|=1,kt(t,e,n,a),e.child)}function lh(t,e,l,n,a){if(t===null){var i=l.type;return typeof i=="function"&&!Os(i)&&i.defaultProps===void 0&&l.compare===null?(e.tag=15,e.type=i,nh(t,e,i,n,a)):(t=Hi(l.type,null,n,e,e.mode,a),t.ref=e.ref,t.return=e,e.child=t)}if(i=t.child,!_c(t,a)){var o=i.memoizedProps;if(l=l.compare,l=l!==null?l:Ea,l(o,n)&&t.ref===e.ref)return ul(t,e,a)}return e.flags|=1,t=tl(i,n),t.ref=e.ref,t.return=e,e.child=t}function nh(t,e,l,n,a){if(t!==null){var i=t.memoizedProps;if(Ea(i,n)&&t.ref===e.ref)if(Lt=!1,e.pendingProps=n=i,_c(t,a))(t.flags&131072)!==0&&(Lt=!0);else return e.lanes=t.lanes,ul(t,e,a)}return pc(t,e,l,n,a)}function ah(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 ih(t,e,i,l,n)}if((l&536870912)!==0)e.memoizedState={baseLanes:0,cachePool:null},t!==null&&qi(e,i!==null?i.cachePool:null),i!==null?sf(e,i):Js(),cf(e);else return n=e.lanes=536870912,ih(t,e,i!==null?i.baseLanes|l:l,l,n)}else i!==null?(qi(e,i.cachePool),sf(e,i),zl(),e.memoizedState=null):(t!==null&&qi(e,null),Js(),zl());return kt(t,e,a,l),e.child}function Ba(t,e){return t!==null&&t.tag===22||e.stateNode!==null||(e.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),e.sibling}function ih(t,e,l,n,a){var i=Xs();return i=i===null?null:{parent:Ht._currentValue,pool:i},e.memoizedState={baseLanes:l,cachePool:i},t!==null&&qi(e,null),Js(),cf(e),t!==null&&Nn(t,e,n,!0),e.childLanes=a,null}function eu(t,e){return e=nu({mode:e.mode,children:e.children},t.mode),e.ref=t.ref,t.child=e,e.return=t,e}function uh(t,e,l){return rn(e,t.child,null,l),t=eu(e,e.pendingProps),t.flags|=2,Se(e),e.memoizedState=null,t}function Dg(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=eu(e,n),e.lanes=536870912,Ba(null,t);if(Ws(e),(t=At)?(t=vd(t,Oe),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=Go(t),l.return=e,e.child=l,Zt=e,At=null)):t=null,t===null)throw Tl(e);return e.lanes=536870912,null}return eu(e,n)}var i=t.memoizedState;if(i!==null){var o=i.dehydrated;if(Ws(e),a)if(e.flags&256)e.flags&=-257,e=uh(t,e,l);else if(e.memoizedState!==null)e.child=t.child,e.flags|=128,e=null;else throw Error(r(558));else if(Lt||Nn(t,e,l,!1),a=(l&t.childLanes)!==0,Lt||a){if(n=vt,n!==null&&(o=kr(n,l),o!==0&&o!==i.retryLane))throw i.retryLane=o,tn(t,o),fe(n,t,o),gc;hu(),e=uh(t,e,l)}else t=i.treeContext,At=we(o.nextSibling),Zt=e,lt=!0,El=null,Oe=!1,t!==null&&Vo(e,t),e=eu(e,n),e.flags|=4096;return e}return t=tl(t.child,{mode:n.mode,children:n.children}),t.ref=e.ref,e.child=t,t.return=e,t}function lu(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(r(284));(t===null||t.ref!==l)&&(e.flags|=4194816)}}function pc(t,e,l,n,a){return an(e),l=Fs(t,e,l,n,void 0,a),n=Is(),t!==null&&!Lt?(Ps(t,e,a),ul(t,e,a)):(lt&&n&&Rs(e),e.flags|=1,kt(t,e,l,a),e.child)}function sh(t,e,l,n,a,i){return an(e),e.updateQueue=null,l=of(e,n,l,a),rf(t),n=Is(),t!==null&&!Lt?(Ps(t,e,i),ul(t,e,i)):(lt&&n&&Rs(e),e.flags|=1,kt(t,e,l,i),e.child)}function ch(t,e,l,n,a){if(an(e),e.stateNode===null){var i=Dn,o=l.contextType;typeof o=="object"&&o!==null&&(i=Jt(o)),i=new l(n,i),e.memoizedState=i.state!==null&&i.state!==void 0?i.state:null,i.updater=mc,e.stateNode=i,i._reactInternals=e,i=e.stateNode,i.props=n,i.state=e.memoizedState,i.refs={},Qs(e),o=l.contextType,i.context=typeof o=="object"&&o!==null?Jt(o):Dn,i.state=e.memoizedState,o=l.getDerivedStateFromProps,typeof o=="function"&&(dc(e,l,o,n),i.state=e.memoizedState),typeof l.getDerivedStateFromProps=="function"||typeof i.getSnapshotBeforeUpdate=="function"||typeof i.UNSAFE_componentWillMount!="function"&&typeof i.componentWillMount!="function"||(o=i.state,typeof i.componentWillMount=="function"&&i.componentWillMount(),typeof i.UNSAFE_componentWillMount=="function"&&i.UNSAFE_componentWillMount(),o!==i.state&&mc.enqueueReplaceState(i,i.state,null),wa(e,n,i,a),Da(),i.state=e.memoizedState),typeof i.componentDidMount=="function"&&(e.flags|=4194308),n=!0}else if(t===null){i=e.stateNode;var h=e.memoizedProps,m=fn(l,h);i.props=m;var A=i.context,C=l.contextType;o=Dn,typeof C=="object"&&C!==null&&(o=Jt(C));var D=l.getDerivedStateFromProps;C=typeof D=="function"||typeof i.getSnapshotBeforeUpdate=="function",h=e.pendingProps!==h,C||typeof i.UNSAFE_componentWillReceiveProps!="function"&&typeof i.componentWillReceiveProps!="function"||(h||A!==o)&&kf(e,i,n,o),_l=!1;var _=e.memoizedState;i.state=_,wa(e,n,i,a),Da(),A=e.memoizedState,h||_!==A||_l?(typeof D=="function"&&(dc(e,l,D,n),A=e.memoizedState),(m=_l||Jf(e,l,m,n,_,A,o))?(C||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=o,n=m):(typeof i.componentDidMount=="function"&&(e.flags|=4194308),n=!1)}else{i=e.stateNode,Ks(t,e),o=e.memoizedProps,C=fn(l,o),i.props=C,D=e.pendingProps,_=i.context,A=l.contextType,m=Dn,typeof A=="object"&&A!==null&&(m=Jt(A)),h=l.getDerivedStateFromProps,(A=typeof h=="function"||typeof i.getSnapshotBeforeUpdate=="function")||typeof i.UNSAFE_componentWillReceiveProps!="function"&&typeof i.componentWillReceiveProps!="function"||(o!==D||_!==m)&&kf(e,i,n,m),_l=!1,_=e.memoizedState,i.state=_,wa(e,n,i,a),Da();var x=e.memoizedState;o!==D||_!==x||_l||t!==null&&t.dependencies!==null&&Li(t.dependencies)?(typeof h=="function"&&(dc(e,l,h,n),x=e.memoizedState),(C=_l||Jf(e,l,C,n,_,x,m)||t!==null&&t.dependencies!==null&&Li(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"||o===t.memoizedProps&&_===t.memoizedState||(e.flags|=4),typeof i.getSnapshotBeforeUpdate!="function"||o===t.memoizedProps&&_===t.memoizedState||(e.flags|=1024),e.memoizedProps=n,e.memoizedState=x),i.props=n,i.state=x,i.context=m,n=C):(typeof i.componentDidUpdate!="function"||o===t.memoizedProps&&_===t.memoizedState||(e.flags|=4),typeof i.getSnapshotBeforeUpdate!="function"||o===t.memoizedProps&&_===t.memoizedState||(e.flags|=1024),n=!1)}return i=n,lu(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=rn(e,t.child,null,a),e.child=rn(e,null,l,a)):kt(t,e,l,a),e.memoizedState=i.state,t=e.child):t=ul(t,e,a),t}function rh(t,e,l,n){return ln(),e.flags|=256,kt(t,e,l,n),e.child}var vc={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function Sc(t){return{baseLanes:t,cachePool:Fo()}}function bc(t,e,l){return t=t!==null?t.childLanes&~l:0,e&&(t|=Ee),t}function oh(t,e,l){var n=e.pendingProps,a=!1,i=(e.flags&128)!==0,o;if((o=i)||(o=t!==null&&t.memoizedState===null?!1:(wt.current&2)!==0),o&&(a=!0,e.flags&=-129),o=(e.flags&32)!==0,e.flags&=-33,t===null){if(lt){if(a?Cl(e):zl(),(t=At)?(t=vd(t,Oe),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=Go(t),l.return=e,e.child=l,Zt=e,At=null)):t=null,t===null)throw Tl(e);return lr(t)?e.lanes=32:e.lanes=536870912,null}var h=n.children;return n=n.fallback,a?(zl(),a=e.mode,h=nu({mode:"hidden",children:h},a),n=en(n,a,l,null),h.return=e,n.return=e,h.sibling=n,e.child=h,n=e.child,n.memoizedState=Sc(l),n.childLanes=bc(t,o,l),e.memoizedState=vc,Ba(null,n)):(Cl(e),Ec(e,h))}var m=t.memoizedState;if(m!==null&&(h=m.dehydrated,h!==null)){if(i)e.flags&256?(Cl(e),e.flags&=-257,e=Tc(t,e,l)):e.memoizedState!==null?(zl(),e.child=t.child,e.flags|=128,e=null):(zl(),h=n.fallback,a=e.mode,n=nu({mode:"visible",children:n.children},a),h=en(h,a,l,null),h.flags|=2,n.return=e,h.return=e,n.sibling=h,e.child=n,rn(e,t.child,null,l),n=e.child,n.memoizedState=Sc(l),n.childLanes=bc(t,o,l),e.memoizedState=vc,e=Ba(null,n));else if(Cl(e),lr(h)){if(o=h.nextSibling&&h.nextSibling.dataset,o)var A=o.dgst;o=A,n=Error(r(419)),n.stack="",n.digest=o,_a({value:n,source:null,stack:null}),e=Tc(t,e,l)}else if(Lt||Nn(t,e,l,!1),o=(l&t.childLanes)!==0,Lt||o){if(o=vt,o!==null&&(n=kr(o,l),n!==0&&n!==m.retryLane))throw m.retryLane=n,tn(t,n),fe(o,t,n),gc;er(h)||hu(),e=Tc(t,e,l)}else er(h)?(e.flags|=192,e.child=t.child,e=null):(t=m.treeContext,At=we(h.nextSibling),Zt=e,lt=!0,El=null,Oe=!1,t!==null&&Vo(e,t),e=Ec(e,n.children),e.flags|=4096);return e}return a?(zl(),h=n.fallback,a=e.mode,m=t.child,A=m.sibling,n=tl(m,{mode:"hidden",children:n.children}),n.subtreeFlags=m.subtreeFlags&65011712,A!==null?h=tl(A,h):(h=en(h,a,l,null),h.flags|=2),h.return=e,n.return=e,n.sibling=h,e.child=n,Ba(null,n),n=e.child,h=t.child.memoizedState,h===null?h=Sc(l):(a=h.cachePool,a!==null?(m=Ht._currentValue,a=a.parent!==m?{parent:m,pool:m}:a):a=Fo(),h={baseLanes:h.baseLanes|l,cachePool:a}),n.memoizedState=h,n.childLanes=bc(t,o,l),e.memoizedState=vc,Ba(t.child,n)):(Cl(e),l=t.child,t=l.sibling,l=tl(l,{mode:"visible",children:n.children}),l.return=e,l.sibling=null,t!==null&&(o=e.deletions,o===null?(e.deletions=[t],e.flags|=16):o.push(t)),e.child=l,e.memoizedState=null,l)}function Ec(t,e){return e=nu({mode:"visible",children:e},t.mode),e.return=t,t.child=e}function nu(t,e){return t=pe(22,t,null,e),t.lanes=0,t}function Tc(t,e,l){return rn(e,t.child,null,l),t=Ec(e,e.pendingProps.children),t.flags|=2,e.memoizedState=null,t}function fh(t,e,l){t.lanes|=e;var n=t.alternate;n!==null&&(n.lanes|=e),Ls(t.return,e,l)}function Ac(t,e,l,n,a,i){var o=t.memoizedState;o===null?t.memoizedState={isBackwards:e,rendering:null,renderingStartTime:0,last:n,tail:l,tailMode:a,treeForkCount:i}:(o.isBackwards=e,o.rendering=null,o.renderingStartTime=0,o.last=n,o.tail=l,o.tailMode=a,o.treeForkCount=i)}function hh(t,e,l){var n=e.pendingProps,a=n.revealOrder,i=n.tail;n=n.children;var o=wt.current,h=(o&2)!==0;if(h?(o=o&1|2,e.flags|=128):o&=1,H(wt,o),kt(t,e,n,l),n=lt?Aa:0,!h&&t!==null&&(t.flags&128)!==0)t:for(t=e.child;t!==null;){if(t.tag===13)t.memoizedState!==null&&fh(t,l,e);else if(t.tag===19)fh(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&&Vi(t)===null&&(a=l),l=l.sibling;l=a,l===null?(a=e.child,e.child=null):(a=l.sibling,l.sibling=null),Ac(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&&Vi(t)===null){e.child=a;break}t=a.sibling,a.sibling=l,l=a,a=t}Ac(e,!0,l,null,i,n);break;case"together":Ac(e,!1,null,null,void 0,n);break;default:e.memoizedState=null}return e.child}function ul(t,e,l){if(t!==null&&(e.dependencies=t.dependencies),wl|=e.lanes,(l&e.childLanes)===0)if(t!==null){if(Nn(t,e,l,!1),(l&e.childLanes)===0)return null}else return null;if(t!==null&&e.child!==t.child)throw Error(r(153));if(e.child!==null){for(t=e.child,l=tl(t,t.pendingProps),e.child=l,l.return=e;t.sibling!==null;)t=t.sibling,l=l.sibling=tl(t,t.pendingProps),l.return=e;l.sibling=null}return e.child}function _c(t,e){return(t.lanes&e)!==0?!0:(t=t.dependencies,!!(t!==null&&Li(t)))}function wg(t,e,l){switch(e.tag){case 3:Pt(e,e.stateNode.containerInfo),Al(e,Ht,t.memoizedState.cache),ln();break;case 27:case 5:ca(e);break;case 4:Pt(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,Ws(e),null;break;case 13:var n=e.memoizedState;if(n!==null)return n.dehydrated!==null?(Cl(e),e.flags|=128,null):(l&e.child.childLanes)!==0?oh(t,e,l):(Cl(e),t=ul(t,e,l),t!==null?t.sibling:null);Cl(e);break;case 19:var a=(t.flags&128)!==0;if(n=(l&e.childLanes)!==0,n||(Nn(t,e,l,!1),n=(l&e.childLanes)!==0),a){if(n)return hh(t,e,l);e.flags|=128}if(a=e.memoizedState,a!==null&&(a.rendering=null,a.tail=null,a.lastEffect=null),H(wt,wt.current),n)break;return null;case 22:return e.lanes=0,ah(t,e,l,e.pendingProps);case 24:Al(e,Ht,t.memoizedState.cache)}return ul(t,e,l)}function dh(t,e,l){if(t!==null)if(t.memoizedProps!==e.pendingProps)Lt=!0;else{if(!_c(t,l)&&(e.flags&128)===0)return Lt=!1,wg(t,e,l);Lt=(t.flags&131072)!==0}else Lt=!1,lt&&(e.flags&1048576)!==0&&Ko(e,Aa,e.index);switch(e.lanes=0,e.tag){case 16:t:{var n=e.pendingProps;if(t=sn(e.elementType),e.type=t,typeof t=="function")Os(t)?(n=fn(t,n),e.tag=1,e=ch(null,e,t,n,l)):(e.tag=0,e=pc(null,e,t,n,l));else{if(t!=null){var a=t.$$typeof;if(a===le){e.tag=11,e=eh(null,e,t,n,l);break t}else if(a===$){e.tag=14,e=lh(null,e,t,n,l);break t}}throw e=$e(t)||t,Error(r(306,e,""))}}return e;case 0:return pc(t,e,e.type,e.pendingProps,l);case 1:return n=e.type,a=fn(n,e.pendingProps),ch(t,e,n,a,l);case 3:t:{if(Pt(e,e.stateNode.containerInfo),t===null)throw Error(r(387));n=e.pendingProps;var i=e.memoizedState;a=i.element,Ks(t,e),wa(e,n,null,l);var o=e.memoizedState;if(n=o.cache,Al(e,Ht,n),n!==i.cache&&js(e,[Ht],l,!0),Da(),n=o.element,i.isDehydrated)if(i={element:n,isDehydrated:!1,cache:o.cache},e.updateQueue.baseState=i,e.memoizedState=i,e.flags&256){e=rh(t,e,n,l);break t}else if(n!==a){a=Me(Error(r(424)),e),_a(a),e=rh(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(At=we(t.firstChild),Zt=e,lt=!0,El=null,Oe=!0,l=nf(e,null,n,l),e.child=l;l;)l.flags=l.flags&-3|4096,l=l.sibling}else{if(ln(),n===a){e=ul(t,e,l);break t}kt(t,e,n,l)}e=e.child}return e;case 26:return lu(t,e),t===null?(l=_d(e.type,null,e.pendingProps,null))?e.memoizedState=l:lt||(l=e.type,t=e.pendingProps,n=Su(F.current).createElement(l),n[Vt]=e,n[ie]=t,Wt(n,l,t),Gt(n),e.stateNode=n):e.memoizedState=_d(e.type,t.memoizedProps,e.pendingProps,t.memoizedState),null;case 27:return ca(e),t===null&<&&(n=e.stateNode=Ed(e.type,e.pendingProps,F.current),Zt=e,Oe=!0,a=At,Bl(e.type)?(nr=a,At=we(n.firstChild)):At=a),kt(t,e,e.pendingProps.children,l),lu(t,e),t===null&&(e.flags|=4194304),e.child;case 5:return t===null&<&&((a=n=At)&&(n=sp(n,e.type,e.pendingProps,Oe),n!==null?(e.stateNode=n,Zt=e,At=we(n.firstChild),Oe=!1,a=!0):a=!1),a||Tl(e)),ca(e),a=e.type,i=e.pendingProps,o=t!==null?t.memoizedProps:null,n=i.children,Ic(a,i)?n=null:o!==null&&Ic(a,o)&&(e.flags|=32),e.memoizedState!==null&&(a=Fs(t,e,Tg,null,null,l),Fa._currentValue=a),lu(t,e),kt(t,e,n,l),e.child;case 6:return t===null&<&&((t=l=At)&&(l=cp(l,e.pendingProps,Oe),l!==null?(e.stateNode=l,Zt=e,At=null,t=!0):t=!1),t||Tl(e)),null;case 13:return oh(t,e,l);case 4:return Pt(e,e.stateNode.containerInfo),n=e.pendingProps,t===null?e.child=rn(e,null,n,l):kt(t,e,n,l),e.child;case 11:return eh(t,e,e.type,e.pendingProps,l);case 7:return kt(t,e,e.pendingProps,l),e.child;case 8:return kt(t,e,e.pendingProps.children,l),e.child;case 12:return kt(t,e,e.pendingProps.children,l),e.child;case 10:return n=e.pendingProps,Al(e,e.type,n.value),kt(t,e,n.children,l),e.child;case 9:return a=e.type._context,n=e.pendingProps.children,an(e),a=Jt(a),n=n(a),e.flags|=1,kt(t,e,n,l),e.child;case 14:return lh(t,e,e.type,e.pendingProps,l);case 15:return nh(t,e,e.type,e.pendingProps,l);case 19:return hh(t,e,l);case 31:return Dg(t,e,l);case 22:return ah(t,e,l,e.pendingProps);case 24:return an(e),n=Jt(Ht),t===null?(a=Xs(),a===null&&(a=vt,i=qs(),a.pooledCache=i,i.refCount++,i!==null&&(a.pooledCacheLanes|=l),a=i),e.memoizedState={parent:n,cache:a},Qs(e),Al(e,Ht,a)):((t.lanes&l)!==0&&(Ks(t,e),wa(e,null,null,l),Da()),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,Ht,n)):(n=i.cache,Al(e,Ht,n),n!==a.cache&&js(e,[Ht],l,!0))),kt(t,e,e.pendingProps.children,l),e.child;case 29:throw e.pendingProps}throw Error(r(156,e.tag))}function sl(t){t.flags|=4}function xc(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(Yh())t.flags|=8192;else throw cn=Xi,Gs}else t.flags&=-16777217}function mh(t,e){if(e.type!=="stylesheet"||(e.state.loading&4)!==0)t.flags&=-16777217;else if(t.flags|=16777216,!Od(e))if(Yh())t.flags|=8192;else throw cn=Xi,Gs}function au(t,e){e!==null&&(t.flags|=4),t.flags&16384&&(e=t.tag!==22?Vr():536870912,t.lanes|=e,Zn|=e)}function La(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 _t(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 Rg(t,e,l){var n=e.pendingProps;switch(Us(e),e.tag){case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return _t(e),null;case 1:return _t(e),null;case 3:return l=e.stateNode,n=null,t!==null&&(n=t.memoizedState.cache),e.memoizedState.cache!==n&&(e.flags|=2048),nl(Ht),Dt(),l.pendingContext&&(l.context=l.pendingContext,l.pendingContext=null),(t===null||t.child===null)&&(Un(e)?sl(e):t===null||t.memoizedState.isDehydrated&&(e.flags&256)===0||(e.flags|=1024,Hs())),_t(e),null;case 26:var a=e.type,i=e.memoizedState;return t===null?(sl(e),i!==null?(_t(e),mh(e,i)):(_t(e),xc(e,a,null,n,l))):i?i!==t.memoizedState?(sl(e),_t(e),mh(e,i)):(_t(e),e.flags&=-16777217):(t=t.memoizedProps,t!==n&&sl(e),_t(e),xc(e,a,t,n,l)),null;case 27:if(yi(e),l=F.current,a=e.type,t!==null&&e.stateNode!=null)t.memoizedProps!==n&&sl(e);else{if(!n){if(e.stateNode===null)throw Error(r(166));return _t(e),null}t=L.current,Un(e)?Zo(e):(t=Ed(a,n,l),e.stateNode=t,sl(e))}return _t(e),null;case 5:if(yi(e),a=e.type,t!==null&&e.stateNode!=null)t.memoizedProps!==n&&sl(e);else{if(!n){if(e.stateNode===null)throw Error(r(166));return _t(e),null}if(i=L.current,Un(e))Zo(e);else{var o=Su(F.current);switch(i){case 1:i=o.createElementNS("http://www.w3.org/2000/svg",a);break;case 2:i=o.createElementNS("http://www.w3.org/1998/Math/MathML",a);break;default:switch(a){case"svg":i=o.createElementNS("http://www.w3.org/2000/svg",a);break;case"math":i=o.createElementNS("http://www.w3.org/1998/Math/MathML",a);break;case"script":i=o.createElement("div"),i.innerHTML="<script><\/script>",i=i.removeChild(i.firstChild);break;case"select":i=typeof n.is=="string"?o.createElement("select",{is:n.is}):o.createElement("select"),n.multiple?i.multiple=!0:n.size&&(i.size=n.size);break;default:i=typeof n.is=="string"?o.createElement(a,{is:n.is}):o.createElement(a)}}i[Vt]=e,i[ie]=n;t:for(o=e.child;o!==null;){if(o.tag===5||o.tag===6)i.appendChild(o.stateNode);else if(o.tag!==4&&o.tag!==27&&o.child!==null){o.child.return=o,o=o.child;continue}if(o===e)break t;for(;o.sibling===null;){if(o.return===null||o.return===e)break t;o=o.return}o.sibling.return=o.return,o=o.sibling}e.stateNode=i;t:switch(Wt(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&&sl(e)}}return _t(e),xc(e,e.type,t===null?null:t.memoizedProps,e.pendingProps,l),null;case 6:if(t&&e.stateNode!=null)t.memoizedProps!==n&&sl(e);else{if(typeof n!="string"&&e.stateNode===null)throw Error(r(166));if(t=F.current,Un(e)){if(t=e.stateNode,l=e.memoizedProps,n=null,a=Zt,a!==null)switch(a.tag){case 27:case 5:n=a.memoizedProps}t[Vt]=e,t=!!(t.nodeValue===l||n!==null&&n.suppressHydrationWarning===!0||od(t.nodeValue,l)),t||Tl(e,!0)}else t=Su(t).createTextNode(n),t[Vt]=e,e.stateNode=t}return _t(e),null;case 31:if(l=e.memoizedState,t===null||t.memoizedState!==null){if(n=Un(e),l!==null){if(t===null){if(!n)throw Error(r(318));if(t=e.memoizedState,t=t!==null?t.dehydrated:null,!t)throw Error(r(557));t[Vt]=e}else ln(),(e.flags&128)===0&&(e.memoizedState=null),e.flags|=4;_t(e),t=!1}else l=Hs(),t!==null&&t.memoizedState!==null&&(t.memoizedState.hydrationErrors=l),t=!0;if(!t)return e.flags&256?(Se(e),e):(Se(e),null);if((e.flags&128)!==0)throw Error(r(558))}return _t(e),null;case 13:if(n=e.memoizedState,t===null||t.memoizedState!==null&&t.memoizedState.dehydrated!==null){if(a=Un(e),n!==null&&n.dehydrated!==null){if(t===null){if(!a)throw Error(r(318));if(a=e.memoizedState,a=a!==null?a.dehydrated:null,!a)throw Error(r(317));a[Vt]=e}else ln(),(e.flags&128)===0&&(e.memoizedState=null),e.flags|=4;_t(e),a=!1}else a=Hs(),t!==null&&t.memoizedState!==null&&(t.memoizedState.hydrationErrors=a),a=!0;if(!a)return e.flags&256?(Se(e),e):(Se(e),null)}return Se(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),au(e,e.updateQueue),_t(e),null);case 4:return Dt(),t===null&&Jc(e.stateNode.containerInfo),_t(e),null;case 10:return nl(e.type),_t(e),null;case 19:if(w(wt),n=e.memoizedState,n===null)return _t(e),null;if(a=(e.flags&128)!==0,i=n.rendering,i===null)if(a)La(n,!1);else{if(Ot!==0||t!==null&&(t.flags&128)!==0)for(t=e.child;t!==null;){if(i=Vi(t),i!==null){for(e.flags|=128,La(n,!1),t=i.updateQueue,e.updateQueue=t,au(e,t),e.subtreeFlags=0,t=l,l=e.child;l!==null;)Xo(l,t),l=l.sibling;return H(wt,wt.current&1|2),lt&&el(e,n.treeForkCount),e.child}t=t.sibling}n.tail!==null&&de()>ru&&(e.flags|=128,a=!0,La(n,!1),e.lanes=4194304)}else{if(!a)if(t=Vi(i),t!==null){if(e.flags|=128,a=!0,t=t.updateQueue,e.updateQueue=t,au(e,t),La(n,!0),n.tail===null&&n.tailMode==="hidden"&&!i.alternate&&!lt)return _t(e),null}else 2*de()-n.renderingStartTime>ru&&l!==536870912&&(e.flags|=128,a=!0,La(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=de(),t.sibling=null,l=wt.current,H(wt,a?l&1|2:l&1),lt&&el(e,n.treeForkCount),t):(_t(e),null);case 22:case 23:return Se(e),ks(),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&&(_t(e),e.subtreeFlags&6&&(e.flags|=8192)):_t(e),l=e.updateQueue,l!==null&&au(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&&w(un),null;case 24:return l=null,t!==null&&(l=t.memoizedState.cache),e.memoizedState.cache!==l&&(e.flags|=2048),nl(Ht),_t(e),null;case 25:return null;case 30:return null}throw Error(r(156,e.tag))}function Ug(t,e){switch(Us(e),e.tag){case 1:return t=e.flags,t&65536?(e.flags=t&-65537|128,e):null;case 3:return nl(Ht),Dt(),t=e.flags,(t&65536)!==0&&(t&128)===0?(e.flags=t&-65537|128,e):null;case 26:case 27:case 5:return yi(e),null;case 31:if(e.memoizedState!==null){if(Se(e),e.alternate===null)throw Error(r(340));ln()}return t=e.flags,t&65536?(e.flags=t&-65537|128,e):null;case 13:if(Se(e),t=e.memoizedState,t!==null&&t.dehydrated!==null){if(e.alternate===null)throw Error(r(340));ln()}return t=e.flags,t&65536?(e.flags=t&-65537|128,e):null;case 19:return w(wt),null;case 4:return Dt(),null;case 10:return nl(e.type),null;case 22:case 23:return Se(e),ks(),t!==null&&w(un),t=e.flags,t&65536?(e.flags=t&-65537|128,e):null;case 24:return nl(Ht),null;case 25:return null;default:return null}}function yh(t,e){switch(Us(e),e.tag){case 3:nl(Ht),Dt();break;case 26:case 27:case 5:yi(e);break;case 4:Dt();break;case 31:e.memoizedState!==null&&Se(e);break;case 13:Se(e);break;case 19:w(wt);break;case 10:nl(e.type);break;case 22:case 23:Se(e),ks(),t!==null&&w(un);break;case 24:nl(Ht)}}function ja(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,o=l.inst;n=i(),o.destroy=n}l=l.next}while(l!==a)}}catch(h){ft(e,e.return,h)}}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 o=n.inst,h=o.destroy;if(h!==void 0){o.destroy=void 0,a=e;var m=l,A=h;try{A()}catch(C){ft(a,m,C)}}}n=n.next}while(n!==i)}}catch(C){ft(e,e.return,C)}}function gh(t){var e=t.updateQueue;if(e!==null){var l=t.stateNode;try{uf(e,l)}catch(n){ft(t,t.return,n)}}}function ph(t,e,l){l.props=fn(t.type,t.memoizedProps),l.state=t.memoizedState;try{l.componentWillUnmount()}catch(n){ft(t,e,n)}}function qa(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 vh(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 Mc(t,e,l){try{var n=t.stateNode;ep(n,t.type,l,e),n[ie]=e}catch(a){ft(t,t.return,a)}}function Sh(t){return t.tag===5||t.tag===3||t.tag===26||t.tag===27&&Bl(t.type)||t.tag===4}function Cc(t){t:for(;;){for(;t.sibling===null;){if(t.return===null||Sh(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 zc(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=Ie));else if(n!==4&&(n===27&&Bl(t.type)&&(l=t.stateNode,e=null),t=t.child,t!==null))for(zc(t,e,l),t=t.sibling;t!==null;)zc(t,e,l),t=t.sibling}function iu(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(iu(t,e,l),t=t.sibling;t!==null;)iu(t,e,l),t=t.sibling}function bh(t){var e=t.stateNode,l=t.memoizedProps;try{for(var n=t.type,a=e.attributes;a.length;)e.removeAttributeNode(a[0]);Wt(e,n,l),e[Vt]=t,e[ie]=l}catch(i){ft(t,t.return,i)}}var cl=!1,jt=!1,Oc=!1,Eh=typeof WeakSet=="function"?WeakSet:Set,Qt=null;function Ng(t,e){if(t=t.containerInfo,$c=Mu,t=Ro(t),Ts(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 o=0,h=-1,m=-1,A=0,C=0,D=t,_=null;e:for(;;){for(var x;D!==l||a!==0&&D.nodeType!==3||(h=o+a),D!==i||n!==0&&D.nodeType!==3||(m=o+n),D.nodeType===3&&(o+=D.nodeValue.length),(x=D.firstChild)!==null;)_=D,D=x;for(;;){if(D===t)break e;if(_===l&&++A===a&&(h=o),_===i&&++C===n&&(m=o),(x=D.nextSibling)!==null)break;D=_,_=D.parentNode}D=x}l=h===-1||m===-1?null:{start:h,end:m}}else l=null}l=l||{start:0,end:0}}else l=null;for(Fc={focusedElem:t,selectionRange:l},Mu=!1,Qt=e;Qt!==null;)if(e=Qt,t=e.child,(e.subtreeFlags&1028)!==0&&t!==null)t.return=e,Qt=t;else for(;Qt!==null;){switch(e=Qt,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(X){ft(l,l.return,X)}}break;case 3:if((t&1024)!==0){if(t=e.stateNode.containerInfo,l=t.nodeType,l===9)tr(t);else if(l===1)switch(t.nodeName){case"HEAD":case"HTML":case"BODY":tr(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(r(163))}if(t=e.sibling,t!==null){t.return=e.return,Qt=t;break}Qt=e.return}}function Th(t,e,l){var n=l.flags;switch(l.tag){case 0:case 11:case 15:ol(t,l),n&4&&ja(5,l);break;case 1:if(ol(t,l),n&4)if(t=l.stateNode,e===null)try{t.componentDidMount()}catch(o){ft(l,l.return,o)}else{var a=fn(l.type,e.memoizedProps);e=e.memoizedState;try{t.componentDidUpdate(a,e,t.__reactInternalSnapshotBeforeUpdate)}catch(o){ft(l,l.return,o)}}n&64&&gh(l),n&512&&qa(l,l.return);break;case 3:if(ol(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{uf(t,e)}catch(o){ft(l,l.return,o)}}break;case 27:e===null&&n&4&&bh(l);case 26:case 5:ol(t,l),e===null&&n&4&&vh(l),n&512&&qa(l,l.return);break;case 12:ol(t,l);break;case 31:ol(t,l),n&4&&xh(t,l);break;case 13:ol(t,l),n&4&&Mh(t,l),n&64&&(t=l.memoizedState,t!==null&&(t=t.dehydrated,t!==null&&(l=Qg.bind(null,l),rp(t,l))));break;case 22:if(n=l.memoizedState!==null||cl,!n){e=e!==null&&e.memoizedState!==null||jt,a=cl;var i=jt;cl=n,(jt=e)&&!i?fl(t,l,(l.subtreeFlags&8772)!==0):ol(t,l),cl=a,jt=i}break;case 30:break;default:ol(t,l)}}function Ah(t){var e=t.alternate;e!==null&&(t.alternate=null,Ah(e)),t.child=null,t.deletions=null,t.sibling=null,t.tag===5&&(e=t.stateNode,e!==null&&is(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 xt=null,se=!1;function rl(t,e,l){for(l=l.child;l!==null;)_h(t,e,l),l=l.sibling}function _h(t,e,l){if(me&&typeof me.onCommitFiberUnmount=="function")try{me.onCommitFiberUnmount(ra,l)}catch{}switch(l.tag){case 26:jt||Ve(l,e),rl(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=xt,a=se;Bl(l.type)&&(xt=l.stateNode,se=!1),rl(t,e,l),ka(l.stateNode),xt=n,se=a;break;case 5:jt||Ve(l,e);case 6:if(n=xt,a=se,xt=null,rl(t,e,l),xt=n,se=a,xt!==null)if(se)try{(xt.nodeType===9?xt.body:xt.nodeName==="HTML"?xt.ownerDocument.body:xt).removeChild(l.stateNode)}catch(i){ft(l,e,i)}else try{xt.removeChild(l.stateNode)}catch(i){ft(l,e,i)}break;case 18:xt!==null&&(se?(t=xt,gd(t.nodeType===9?t.body:t.nodeName==="HTML"?t.ownerDocument.body:t,l.stateNode),ta(t)):gd(xt,l.stateNode));break;case 4:n=xt,a=se,xt=l.stateNode.containerInfo,se=!0,rl(t,e,l),xt=n,se=a;break;case 0:case 11:case 14:case 15:Ol(2,l,e),jt||Ol(4,l,e),rl(t,e,l);break;case 1:jt||(Ve(l,e),n=l.stateNode,typeof n.componentWillUnmount=="function"&&ph(l,e,n)),rl(t,e,l);break;case 21:rl(t,e,l);break;case 22:jt=(n=jt)||l.memoizedState!==null,rl(t,e,l),jt=n;break;default:rl(t,e,l)}}function xh(t,e){if(e.memoizedState===null&&(t=e.alternate,t!==null&&(t=t.memoizedState,t!==null))){t=t.dehydrated;try{ta(t)}catch(l){ft(e,e.return,l)}}}function Mh(t,e){if(e.memoizedState===null&&(t=e.alternate,t!==null&&(t=t.memoizedState,t!==null&&(t=t.dehydrated,t!==null))))try{ta(t)}catch(l){ft(e,e.return,l)}}function Hg(t){switch(t.tag){case 31:case 13:case 19:var e=t.stateNode;return e===null&&(e=t.stateNode=new Eh),e;case 22:return t=t.stateNode,e=t._retryCache,e===null&&(e=t._retryCache=new Eh),e;default:throw Error(r(435,t.tag))}}function uu(t,e){var l=Hg(t);e.forEach(function(n){if(!l.has(n)){l.add(n);var a=Kg.bind(null,t,n);n.then(a,a)}})}function ce(t,e){var l=e.deletions;if(l!==null)for(var n=0;n<l.length;n++){var a=l[n],i=t,o=e,h=o;t:for(;h!==null;){switch(h.tag){case 27:if(Bl(h.type)){xt=h.stateNode,se=!1;break t}break;case 5:xt=h.stateNode,se=!1;break t;case 3:case 4:xt=h.stateNode.containerInfo,se=!0;break t}h=h.return}if(xt===null)throw Error(r(160));_h(i,o,a),xt=null,se=!1,i=a.alternate,i!==null&&(i.return=null),a.return=null}if(e.subtreeFlags&13886)for(e=e.child;e!==null;)Ch(e,t),e=e.sibling}var qe=null;function Ch(t,e){var l=t.alternate,n=t.flags;switch(t.tag){case 0:case 11:case 14:case 15:ce(e,t),re(t),n&4&&(Ol(3,t,t.return),ja(3,t),Ol(5,t,t.return));break;case 1:ce(e,t),re(t),n&512&&(jt||l===null||Ve(l,l.return)),n&64&&cl&&(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=qe;if(ce(e,t),re(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[ha]||i[Vt]||i.namespaceURI==="http://www.w3.org/2000/svg"||i.hasAttribute("itemprop"))&&(i=a.createElement(n),a.head.insertBefore(i,a.querySelector("head > title"))),Wt(i,n,l),i[Vt]=t,Gt(i),n=i;break t;case"link":var o=Cd("link","href",a).get(n+(l.href||""));if(o){for(var h=0;h<o.length;h++)if(i=o[h],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)){o.splice(h,1);break e}}i=a.createElement(n),Wt(i,n,l),a.head.appendChild(i);break;case"meta":if(o=Cd("meta","content",a).get(n+(l.content||""))){for(h=0;h<o.length;h++)if(i=o[h],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)){o.splice(h,1);break e}}i=a.createElement(n),Wt(i,n,l),a.head.appendChild(i);break;default:throw Error(r(468,n))}i[Vt]=t,Gt(i),n=i}t.stateNode=n}else zd(a,t.type,t.stateNode);else t.stateNode=Md(a,n,t.memoizedProps);else i!==n?(i===null?l.stateNode!==null&&(l=l.stateNode,l.parentNode.removeChild(l)):i.count--,n===null?zd(a,t.type,t.stateNode):Md(a,n,t.memoizedProps)):n===null&&t.stateNode!==null&&Mc(t,t.memoizedProps,l.memoizedProps)}break;case 27:ce(e,t),re(t),n&512&&(jt||l===null||Ve(l,l.return)),l!==null&&n&4&&Mc(t,t.memoizedProps,l.memoizedProps);break;case 5:if(ce(e,t),re(t),n&512&&(jt||l===null||Ve(l,l.return)),t.flags&32){a=t.stateNode;try{An(a,"")}catch(B){ft(t,t.return,B)}}n&4&&t.stateNode!=null&&(a=t.memoizedProps,Mc(t,a,l!==null?l.memoizedProps:a)),n&1024&&(Oc=!0);break;case 6:if(ce(e,t),re(t),n&4){if(t.stateNode===null)throw Error(r(162));n=t.memoizedProps,l=t.stateNode;try{l.nodeValue=n}catch(B){ft(t,t.return,B)}}break;case 3:if(Tu=null,a=qe,qe=bu(e.containerInfo),ce(e,t),qe=a,re(t),n&4&&l!==null&&l.memoizedState.isDehydrated)try{ta(e.containerInfo)}catch(B){ft(t,t.return,B)}Oc&&(Oc=!1,zh(t));break;case 4:n=qe,qe=bu(t.stateNode.containerInfo),ce(e,t),re(t),qe=n;break;case 12:ce(e,t),re(t);break;case 31:ce(e,t),re(t),n&4&&(n=t.updateQueue,n!==null&&(t.updateQueue=null,uu(t,n)));break;case 13:ce(e,t),re(t),t.child.flags&8192&&t.memoizedState!==null!=(l!==null&&l.memoizedState!==null)&&(cu=de()),n&4&&(n=t.updateQueue,n!==null&&(t.updateQueue=null,uu(t,n)));break;case 22:a=t.memoizedState!==null;var m=l!==null&&l.memoizedState!==null,A=cl,C=jt;if(cl=A||a,jt=C||m,ce(e,t),jt=C,cl=A,re(t),n&8192)t:for(e=t.stateNode,e._visibility=a?e._visibility&-2:e._visibility|1,a&&(l===null||m||cl||jt||hn(t)),l=null,e=t;;){if(e.tag===5||e.tag===26){if(l===null){m=l=e;try{if(i=m.stateNode,a)o=i.style,typeof o.setProperty=="function"?o.setProperty("display","none","important"):o.display="none";else{h=m.stateNode;var D=m.memoizedProps.style,_=D!=null&&D.hasOwnProperty("display")?D.display:null;h.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?pd(x,!0):pd(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,uu(t,l))));break;case 19:ce(e,t),re(t),n&4&&(n=t.updateQueue,n!==null&&(t.updateQueue=null,uu(t,n)));break;case 30:break;case 21:break;default:ce(e,t),re(t)}}function re(t){var e=t.flags;if(e&2){try{for(var l,n=t.return;n!==null;){if(Sh(n)){l=n;break}n=n.return}if(l==null)throw Error(r(160));switch(l.tag){case 27:var a=l.stateNode,i=Cc(t);iu(t,i,a);break;case 5:var o=l.stateNode;l.flags&32&&(An(o,""),l.flags&=-33);var h=Cc(t);iu(t,h,o);break;case 3:case 4:var m=l.stateNode.containerInfo,A=Cc(t);zc(t,A,m);break;default:throw Error(r(161))}}catch(C){ft(t,t.return,C)}t.flags&=-3}e&4096&&(t.flags&=-4097)}function zh(t){if(t.subtreeFlags&1024)for(t=t.child;t!==null;){var e=t;zh(e),e.tag===5&&e.flags&1024&&e.stateNode.reset(),t=t.sibling}}function ol(t,e){if(e.subtreeFlags&8772)for(e=e.child;e!==null;)Th(t,e.alternate,e),e=e.sibling}function hn(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),hn(e);break;case 1:Ve(e,e.return);var l=e.stateNode;typeof l.componentWillUnmount=="function"&&ph(e,e.return,l),hn(e);break;case 27:ka(e.stateNode);case 26:case 5:Ve(e,e.return),hn(e);break;case 22:e.memoizedState===null&&hn(e);break;case 30:hn(e);break;default:hn(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,o=i.flags;switch(i.tag){case 0:case 11:case 15:fl(a,i,l),ja(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 h=n.stateNode;try{var m=a.shared.hiddenCallbacks;if(m!==null)for(a.shared.hiddenCallbacks=null,a=0;a<m.length;a++)af(m[a],h)}catch(A){ft(n,n.return,A)}}l&&o&64&&gh(i),qa(i,i.return);break;case 27:bh(i);case 26:case 5:fl(a,i,l),l&&n===null&&o&4&&vh(i),qa(i,i.return);break;case 12:fl(a,i,l);break;case 31:fl(a,i,l),l&&o&4&&xh(a,i);break;case 13:fl(a,i,l),l&&o&4&&Mh(a,i);break;case 22:i.memoizedState===null&&fl(a,i,l),qa(i,i.return);break;case 30:break;default:fl(a,i,l)}e=e.sibling}}function Dc(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&&xa(l))}function wc(t,e){t=null,e.alternate!==null&&(t=e.alternate.memoizedState.cache),e=e.memoizedState.cache,e!==t&&(e.refCount++,t!=null&&xa(t))}function Ye(t,e,l,n){if(e.subtreeFlags&10256)for(e=e.child;e!==null;)Oh(t,e,l,n),e=e.sibling}function Oh(t,e,l,n){var a=e.flags;switch(e.tag){case 0:case 11:case 15:Ye(t,e,l,n),a&2048&&ja(9,e);break;case 1:Ye(t,e,l,n);break;case 3:Ye(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&&xa(t)));break;case 12:if(a&2048){Ye(t,e,l,n),t=e.stateNode;try{var i=e.memoizedProps,o=i.id,h=i.onPostCommit;typeof h=="function"&&h(o,e.alternate===null?"mount":"update",t.passiveEffectDuration,-0)}catch(m){ft(e,e.return,m)}}else Ye(t,e,l,n);break;case 31:Ye(t,e,l,n);break;case 13:Ye(t,e,l,n);break;case 23:break;case 22:i=e.stateNode,o=e.alternate,e.memoizedState!==null?i._visibility&2?Ye(t,e,l,n):Ya(t,e):i._visibility&2?Ye(t,e,l,n):(i._visibility|=2,Qn(t,e,l,n,(e.subtreeFlags&10256)!==0||!1)),a&2048&&Dc(o,e);break;case 24:Ye(t,e,l,n),a&2048&&wc(e.alternate,e);break;default:Ye(t,e,l,n)}}function Qn(t,e,l,n,a){for(a=a&&((e.subtreeFlags&10256)!==0||!1),e=e.child;e!==null;){var i=t,o=e,h=l,m=n,A=o.flags;switch(o.tag){case 0:case 11:case 15:Qn(i,o,h,m,a),ja(8,o);break;case 23:break;case 22:var C=o.stateNode;o.memoizedState!==null?C._visibility&2?Qn(i,o,h,m,a):Ya(i,o):(C._visibility|=2,Qn(i,o,h,m,a)),a&&A&2048&&Dc(o.alternate,o);break;case 24:Qn(i,o,h,m,a),a&&A&2048&&wc(o.alternate,o);break;default:Qn(i,o,h,m,a)}e=e.sibling}}function Ya(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:Ya(l,n),a&2048&&Dc(n.alternate,n);break;case 24:Ya(l,n),a&2048&&wc(n.alternate,n);break;default:Ya(l,n)}e=e.sibling}}var Xa=8192;function Kn(t,e,l){if(t.subtreeFlags&Xa)for(t=t.child;t!==null;)Dh(t,e,l),t=t.sibling}function Dh(t,e,l){switch(t.tag){case 26:Kn(t,e,l),t.flags&Xa&&t.memoizedState!==null&&Ep(l,qe,t.memoizedState,t.memoizedProps);break;case 5:Kn(t,e,l);break;case 3:case 4:var n=qe;qe=bu(t.stateNode.containerInfo),Kn(t,e,l),qe=n;break;case 22:t.memoizedState===null&&(n=t.alternate,n!==null&&n.memoizedState!==null?(n=Xa,Xa=16777216,Kn(t,e,l),Xa=n):Kn(t,e,l));break;default:Kn(t,e,l)}}function wh(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 Ga(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];Qt=n,Uh(n,t)}wh(t)}if(t.subtreeFlags&10256)for(t=t.child;t!==null;)Rh(t),t=t.sibling}function Rh(t){switch(t.tag){case 0:case 11:case 15:Ga(t),t.flags&2048&&Ol(9,t,t.return);break;case 3:Ga(t);break;case 12:Ga(t);break;case 22:var e=t.stateNode;t.memoizedState!==null&&e._visibility&2&&(t.return===null||t.return.tag!==13)?(e._visibility&=-3,su(t)):Ga(t);break;default:Ga(t)}}function su(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];Qt=n,Uh(n,t)}wh(t)}for(t=t.child;t!==null;){switch(e=t,e.tag){case 0:case 11:case 15:Ol(8,e,e.return),su(e);break;case 22:l=e.stateNode,l._visibility&2&&(l._visibility&=-3,su(e));break;default:su(e)}t=t.sibling}}function Uh(t,e){for(;Qt!==null;){var l=Qt;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:xa(l.memoizedState.cache)}if(n=l.child,n!==null)n.return=l,Qt=n;else t:for(l=t;Qt!==null;){n=Qt;var a=n.sibling,i=n.return;if(Ah(n),n===l){Qt=null;break t}if(a!==null){a.return=i,Qt=a;break t}Qt=i}}}var Bg={getCacheForType:function(t){var e=Jt(Ht),l=e.data.get(t);return l===void 0&&(l=t(),e.data.set(t,l)),l},cacheSignal:function(){return Jt(Ht).controller.signal}},Lg=typeof WeakMap=="function"?WeakMap:Map,st=0,vt=null,I=null,tt=0,ot=0,be=null,Dl=!1,Vn=!1,Rc=!1,hl=0,Ot=0,wl=0,dn=0,Uc=0,Ee=0,Zn=0,Qa=null,oe=null,Nc=!1,cu=0,Nh=0,ru=1/0,ou=null,Rl=null,Yt=0,Ul=null,Jn=null,dl=0,Hc=0,Bc=null,Hh=null,Ka=0,Lc=null;function Te(){return(st&2)!==0&&tt!==0?tt&-tt:z.T!==null?Qc():Wr()}function Bh(){if(Ee===0)if((tt&536870912)===0||lt){var t=vi;vi<<=1,(vi&3932160)===0&&(vi=262144),Ee=t}else Ee=536870912;return t=ve.current,t!==null&&(t.flags|=32),Ee}function fe(t,e,l){(t===vt&&(ot===2||ot===9)||t.cancelPendingCommit!==null)&&(kn(t,0),Nl(t,tt,Ee,!1)),fa(t,l),((st&2)===0||t!==vt)&&(t===vt&&((st&2)===0&&(dn|=l),Ot===4&&Nl(t,tt,Ee,!1)),Ze(t))}function Lh(t,e,l){if((st&6)!==0)throw Error(r(327));var n=!l&&(e&127)===0&&(e&t.expiredLanes)===0||oa(t,e),a=n?Yg(t,e):qc(t,e,!0),i=n;do{if(a===0){Vn&&!n&&Nl(t,e,0,!1);break}else{if(l=t.current.alternate,i&&!jg(l)){a=qc(t,e,!1),i=!1;continue}if(a===2){if(i=e,t.errorRecoveryDisabledLanes&i)var o=0;else o=t.pendingLanes&-536870913,o=o!==0?o:o&536870912?536870912:0;if(o!==0){e=o;t:{var h=t;a=Qa;var m=h.current.memoizedState.isDehydrated;if(m&&(kn(h,o).flags|=256),o=qc(h,o,!1),o!==2){if(Rc&&!m){h.errorRecoveryDisabledLanes|=i,dn|=i,a=4;break t}i=oe,oe=a,i!==null&&(oe===null?oe=i:oe.push.apply(oe,i))}a=o}if(i=!1,a!==2)continue}}if(a===1){kn(t,0),Nl(t,e,0,!0);break}t:{switch(n=t,i=a,i){case 0:case 1:throw Error(r(345));case 4:if((e&4194048)!==e)break;case 6:Nl(n,e,Ee,!Dl);break t;case 2:oe=null;break;case 3:case 5:break;default:throw Error(r(329))}if((e&62914560)===e&&(a=cu+300-de(),10<a)){if(Nl(n,e,Ee,!Dl),bi(n,0,!0)!==0)break t;dl=e,n.timeoutHandle=md(jh.bind(null,n,l,oe,ou,Nc,e,Ee,dn,Zn,Dl,i,"Throttled",-0,0),a);break t}jh(n,l,oe,ou,Nc,e,Ee,dn,Zn,Dl,i,null,-0,0)}}break}while(!0);Ze(t)}function jh(t,e,l,n,a,i,o,h,m,A,C,D,_,x){if(t.timeoutHandle=-1,D=e.subtreeFlags,D&8192||(D&16785408)===16785408){D={stylesheets:null,count:0,imgCount:0,imgBytes:0,suspenseyImages:[],waitingForImages:!0,waitingForViewTransition:!1,unsuspend:Ie},Dh(e,i,D);var B=(i&62914560)===i?cu-de():(i&4194048)===i?Nh-de():0;if(B=Tp(D,B),B!==null){dl=i,t.cancelPendingCommit=B(Zh.bind(null,t,e,i,l,n,a,o,h,m,C,D,null,_,x)),Nl(t,i,o,!A);return}}Zh(t,e,i,l,n,a,o,h,m)}function jg(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(!ge(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 Nl(t,e,l,n){e&=~Uc,e&=~dn,t.suspendedLanes|=e,t.pingedLanes&=~e,n&&(t.warmLanes|=e),n=t.expirationTimes;for(var a=e;0<a;){var i=31-ye(a),o=1<<i;n[i]=-1,a&=~o}l!==0&&Zr(t,l,e)}function fu(){return(st&6)===0?(Va(0),!1):!0}function jc(){if(I!==null){if(ot===0)var t=I.return;else t=I,ll=nn=null,tc(t),jn=null,Ca=0,t=I;for(;t!==null;)yh(t.alternate,t),t=t.return;I=null}}function kn(t,e){var l=t.timeoutHandle;l!==-1&&(t.timeoutHandle=-1,ap(l)),l=t.cancelPendingCommit,l!==null&&(t.cancelPendingCommit=null,l()),dl=0,jc(),vt=t,I=l=tl(t.current,null),tt=e,ot=0,be=null,Dl=!1,Vn=oa(t,e),Rc=!1,Zn=Ee=Uc=dn=wl=Ot=0,oe=Qa=null,Nc=!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-ye(n),i=1<<a;e|=t[a],n&=~i}return hl=e,Ri(),l}function qh(t,e){J=null,z.H=Ha,e===Ln||e===Yi?(e=tf(),ot=3):e===Gs?(e=tf(),ot=4):ot=e===gc?8:e!==null&&typeof e=="object"&&typeof e.then=="function"?6:1,be=e,I===null&&(Ot=1,tu(t,Me(e,t.current)))}function Yh(){var t=ve.current;return t===null?!0:(tt&4194048)===tt?De===null:(tt&62914560)===tt||(tt&536870912)!==0?t===De:!1}function Xh(){var t=z.H;return z.H=Ha,t===null?Ha:t}function Gh(){var t=z.A;return z.A=Bg,t}function hu(){Ot=4,Dl||(tt&4194048)!==tt&&ve.current!==null||(Vn=!0),(wl&134217727)===0&&(dn&134217727)===0||vt===null||Nl(vt,tt,Ee,!1)}function qc(t,e,l){var n=st;st|=2;var a=Xh(),i=Gh();(vt!==t||tt!==e)&&(ou=null,kn(t,e)),e=!1;var o=Ot;t:do try{if(ot!==0&&I!==null){var h=I,m=be;switch(ot){case 8:jc(),o=6;break t;case 3:case 2:case 9:case 6:ve.current===null&&(e=!0);var A=ot;if(ot=0,be=null,Wn(t,h,m,A),l&&Vn){o=0;break t}break;default:A=ot,ot=0,be=null,Wn(t,h,m,A)}}qg(),o=Ot;break}catch(C){qh(t,C)}while(!0);return e&&t.shellSuspendCounter++,ll=nn=null,st=n,z.H=a,z.A=i,I===null&&(vt=null,tt=0,Ri()),o}function qg(){for(;I!==null;)Qh(I)}function Yg(t,e){var l=st;st|=2;var n=Xh(),a=Gh();vt!==t||tt!==e?(ou=null,ru=de()+500,kn(t,e)):Vn=oa(t,e);t:do try{if(ot!==0&&I!==null){e=I;var i=be;e:switch(ot){case 1:ot=0,be=null,Wn(t,e,i,1);break;case 2:case 9:if(Io(i)){ot=0,be=null,Kh(e);break}e=function(){ot!==2&&ot!==9||vt!==t||(ot=7),Ze(t)},i.then(e,e);break t;case 3:ot=7;break t;case 4:ot=5;break t;case 7:Io(i)?(ot=0,be=null,Kh(e)):(ot=0,be=null,Wn(t,e,i,7));break;case 5:var o=null;switch(I.tag){case 26:o=I.memoizedState;case 5:case 27:var h=I;if(o?Od(o):h.stateNode.complete){ot=0,be=null;var m=h.sibling;if(m!==null)I=m;else{var A=h.return;A!==null?(I=A,du(A)):I=null}break e}}ot=0,be=null,Wn(t,e,i,5);break;case 6:ot=0,be=null,Wn(t,e,i,6);break;case 8:jc(),Ot=6;break t;default:throw Error(r(462))}}Xg();break}catch(C){qh(t,C)}while(!0);return ll=nn=null,z.H=n,z.A=a,st=l,I!==null?0:(vt=null,tt=0,Ri(),Ot)}function Xg(){for(;I!==null&&!oy();)Qh(I)}function Qh(t){var e=dh(t.alternate,t,hl);t.memoizedProps=t.pendingProps,e===null?du(t):I=e}function Kh(t){var e=t,l=e.alternate;switch(e.tag){case 15:case 0:e=sh(l,e,e.pendingProps,e.type,void 0,tt);break;case 11:e=sh(l,e,e.pendingProps,e.type.render,e.ref,tt);break;case 5:tc(e);default:yh(l,e),e=I=Xo(e,hl),e=dh(l,e,hl)}t.memoizedProps=t.pendingProps,e===null?du(t):I=e}function Wn(t,e,l,n){ll=nn=null,tc(e),jn=null,Ca=0;var a=e.return;try{if(Og(t,a,e,l,tt)){Ot=1,tu(t,Me(l,t.current)),I=null;return}}catch(i){if(a!==null)throw I=a,i;Ot=1,tu(t,Me(l,t.current)),I=null;return}e.flags&32768?(lt||n===1?t=!0:Vn||(tt&536870912)!==0?t=!1:(Dl=t=!0,(n===2||n===9||n===3||n===6)&&(n=ve.current,n!==null&&n.tag===13&&(n.flags|=16384))),Vh(e,t)):du(e)}function du(t){var e=t;do{if((e.flags&32768)!==0){Vh(e,Dl);return}t=e.return;var l=Rg(e.alternate,e,hl);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 Vh(t,e){do{var l=Ug(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 Zh(t,e,l,n,a,i,o,h,m){t.cancelPendingCommit=null;do mu();while(Yt!==0);if((st&6)!==0)throw Error(r(327));if(e!==null){if(e===t.current)throw Error(r(177));if(i=e.lanes|e.childLanes,i|=Cs,by(t,l,i,o,h,m),t===vt&&(I=vt=null,tt=0),Jn=e,Ul=t,dl=l,Hc=i,Bc=a,Hh=n,(e.subtreeFlags&10256)!==0||(e.flags&10256)!==0?(t.callbackNode=null,t.callbackPriority=0,Vg(gi,function(){return Fh(),null})):(t.callbackNode=null,t.callbackPriority=0),n=(e.flags&13878)!==0,(e.subtreeFlags&13878)!==0||n){n=z.T,z.T=null,a=N.p,N.p=2,o=st,st|=4;try{Ng(t,e,l)}finally{st=o,N.p=a,z.T=n}}Yt=1,Jh(),kh(),Wh()}}function Jh(){if(Yt===1){Yt=0;var t=Ul,e=Jn,l=(e.flags&13878)!==0;if((e.subtreeFlags&13878)!==0||l){l=z.T,z.T=null;var n=N.p;N.p=2;var a=st;st|=4;try{Ch(e,t);var i=Fc,o=Ro(t.containerInfo),h=i.focusedElem,m=i.selectionRange;if(o!==h&&h&&h.ownerDocument&&wo(h.ownerDocument.documentElement,h)){if(m!==null&&Ts(h)){var A=m.start,C=m.end;if(C===void 0&&(C=A),"selectionStart"in h)h.selectionStart=A,h.selectionEnd=Math.min(C,h.value.length);else{var D=h.ownerDocument||document,_=D&&D.defaultView||window;if(_.getSelection){var x=_.getSelection(),B=h.textContent.length,X=Math.min(m.start,B),gt=m.end===void 0?X:Math.min(m.end,B);!x.extend&&X>gt&&(o=gt,gt=X,X=o);var S=Do(h,X),g=Do(h,gt);if(S&&g&&(x.rangeCount!==1||x.anchorNode!==S.node||x.anchorOffset!==S.offset||x.focusNode!==g.node||x.focusOffset!==g.offset)){var T=D.createRange();T.setStart(S.node,S.offset),x.removeAllRanges(),X>gt?(x.addRange(T),x.extend(g.node,g.offset)):(T.setEnd(g.node,g.offset),x.addRange(T))}}}}for(D=[],x=h;x=x.parentNode;)x.nodeType===1&&D.push({element:x,left:x.scrollLeft,top:x.scrollTop});for(typeof h.focus=="function"&&h.focus(),h=0;h<D.length;h++){var O=D[h];O.element.scrollLeft=O.left,O.element.scrollTop=O.top}}Mu=!!$c,Fc=$c=null}finally{st=a,N.p=n,z.T=l}}t.current=e,Yt=2}}function kh(){if(Yt===2){Yt=0;var t=Ul,e=Jn,l=(e.flags&8772)!==0;if((e.subtreeFlags&8772)!==0||l){l=z.T,z.T=null;var n=N.p;N.p=2;var a=st;st|=4;try{Th(t,e.alternate,e)}finally{st=a,N.p=n,z.T=l}}Yt=3}}function Wh(){if(Yt===4||Yt===3){Yt=0,fy();var t=Ul,e=Jn,l=dl,n=Hh;(e.subtreeFlags&10256)!==0||(e.flags&10256)!==0?Yt=5:(Yt=0,Jn=Ul=null,$h(t,t.pendingLanes));var a=t.pendingLanes;if(a===0&&(Rl=null),ns(l),e=e.stateNode,me&&typeof me.onCommitFiberRoot=="function")try{me.onCommitFiberRoot(ra,e,void 0,(e.current.flags&128)===128)}catch{}if(n!==null){e=z.T,a=N.p,N.p=2,z.T=null;try{for(var i=t.onRecoverableError,o=0;o<n.length;o++){var h=n[o];i(h.value,{componentStack:h.stack})}}finally{z.T=e,N.p=a}}(dl&3)!==0&&mu(),Ze(t),a=t.pendingLanes,(l&261930)!==0&&(a&42)!==0?t===Lc?Ka++:(Ka=0,Lc=t):Ka=0,Va(0)}}function $h(t,e){(t.pooledCacheLanes&=e)===0&&(e=t.pooledCache,e!=null&&(t.pooledCache=null,xa(e)))}function mu(){return Jh(),kh(),Wh(),Fh()}function Fh(){if(Yt!==5)return!1;var t=Ul,e=Hc;Hc=0;var l=ns(dl),n=z.T,a=N.p;try{N.p=32>l?32:l,z.T=null,l=Bc,Bc=null;var i=Ul,o=dl;if(Yt=0,Jn=Ul=null,dl=0,(st&6)!==0)throw Error(r(331));var h=st;if(st|=4,Rh(i.current),Oh(i,i.current,o,l),st=h,Va(0,!1),me&&typeof me.onPostCommitFiberRoot=="function")try{me.onPostCommitFiberRoot(ra,i)}catch{}return!0}finally{N.p=a,z.T=n,$h(t,e)}}function Ih(t,e,l){e=Me(l,e),e=yc(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)Ih(t,t,l);else for(;e!==null;){if(e.tag===3){Ih(e,t,l);break}else if(e.tag===1){var n=e.stateNode;if(typeof e.type.getDerivedStateFromError=="function"||typeof n.componentDidCatch=="function"&&(Rl===null||!Rl.has(n))){t=Me(l,t),l=Pf(2),n=Ml(e,l,2),n!==null&&(th(l,n,e,t),fa(n,2),Ze(n));break}}e=e.return}}function Yc(t,e,l){var n=t.pingCache;if(n===null){n=t.pingCache=new Lg;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)||(Rc=!0,a.add(l),t=Gg.bind(null,t,e,l),e.then(t,t))}function Gg(t,e,l){var n=t.pingCache;n!==null&&n.delete(e),t.pingedLanes|=t.suspendedLanes&l,t.warmLanes&=~l,vt===t&&(tt&l)===l&&(Ot===4||Ot===3&&(tt&62914560)===tt&&300>de()-cu?(st&2)===0&&kn(t,0):Uc|=l,Zn===tt&&(Zn=0)),Ze(t)}function Ph(t,e){e===0&&(e=Vr()),t=tn(t,e),t!==null&&(fa(t,e),Ze(t))}function Qg(t){var e=t.memoizedState,l=0;e!==null&&(l=e.retryLane),Ph(t,l)}function Kg(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(r(314))}n!==null&&n.delete(e),Ph(t,l)}function Vg(t,e){return Pu(t,e)}var yu=null,$n=null,Xc=!1,gu=!1,Gc=!1,Hl=0;function Ze(t){t!==$n&&t.next===null&&($n===null?yu=$n=t:$n=$n.next=t),gu=!0,Xc||(Xc=!0,Jg())}function Va(t,e){if(!Gc&&gu){Gc=!0;do for(var l=!1,n=yu;n!==null;){if(t!==0){var a=n.pendingLanes;if(a===0)var i=0;else{var o=n.suspendedLanes,h=n.pingedLanes;i=(1<<31-ye(42|t)+1)-1,i&=a&~(o&~h),i=i&201326741?i&201326741|1:i?i|2:0}i!==0&&(l=!0,nd(n,i))}else i=tt,i=bi(n,n===vt?i:0,n.cancelPendingCommit!==null||n.timeoutHandle!==-1),(i&3)===0||oa(n,i)||(l=!0,nd(n,i));n=n.next}while(l);Gc=!1}}function Zg(){td()}function td(){gu=Xc=!1;var t=0;Hl!==0&&np()&&(t=Hl);for(var e=de(),l=null,n=yu;n!==null;){var a=n.next,i=ed(n,e);i===0?(n.next=null,l===null?yu=a:l.next=a,a===null&&($n=l)):(l=n,(t!==0||(i&3)!==0)&&(gu=!0)),n=a}Yt!==0&&Yt!==5||Va(t),Hl!==0&&(Hl=0)}function ed(t,e){for(var l=t.suspendedLanes,n=t.pingedLanes,a=t.expirationTimes,i=t.pendingLanes&-62914561;0<i;){var o=31-ye(i),h=1<<o,m=a[o];m===-1?((h&l)===0||(h&n)!==0)&&(a[o]=Sy(h,e)):m<=e&&(t.expiredLanes|=h),i&=~h}if(e=vt,l=tt,l=bi(t,t===e?l:0,t.cancelPendingCommit!==null||t.timeoutHandle!==-1),n=t.callbackNode,l===0||t===e&&(ot===2||ot===9)||t.cancelPendingCommit!==null)return n!==null&&n!==null&&ts(n),t.callbackNode=null,t.callbackPriority=0;if((l&3)===0||oa(t,l)){if(e=l&-l,e===t.callbackPriority)return e;switch(n!==null&&ts(n),ns(l)){case 2:case 8:l=Qr;break;case 32:l=gi;break;case 268435456:l=Kr;break;default:l=gi}return n=ld.bind(null,t),l=Pu(l,n),t.callbackPriority=e,t.callbackNode=l,e}return n!==null&&n!==null&&ts(n),t.callbackPriority=2,t.callbackNode=null,2}function ld(t,e){if(Yt!==0&&Yt!==5)return t.callbackNode=null,t.callbackPriority=0,null;var l=t.callbackNode;if(mu()&&t.callbackNode!==l)return null;var n=tt;return n=bi(t,t===vt?n:0,t.cancelPendingCommit!==null||t.timeoutHandle!==-1),n===0?null:(Lh(t,n,e),ed(t,de()),t.callbackNode!=null&&t.callbackNode===l?ld.bind(null,t):null)}function nd(t,e){if(mu())return null;Lh(t,e,!0)}function Jg(){ip(function(){(st&6)!==0?Pu(Gr,Zg):td()})}function Qc(){if(Hl===0){var t=Hn;t===0&&(t=pi,pi<<=1,(pi&261888)===0&&(pi=256)),Hl=t}return Hl}function ad(t){return t==null||typeof t=="symbol"||typeof t=="boolean"?null:typeof t=="function"?t:_i(""+t)}function id(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=ad((a[ie]||null).action),o=n.submitter;o&&(e=(e=o[ie]||null)?ad(e.formAction):o.getAttribute("formAction"),e!==null&&(i=e,o=null));var h=new zi("action","action",null,n,a);t.push({event:h,listeners:[{instance:null,listener:function(){if(n.defaultPrevented){if(Hl!==0){var m=o?id(a,o):new FormData(a);rc(l,{pending:!0,data:m,method:a.method,action:i},null,m)}}else typeof i=="function"&&(h.preventDefault(),m=o?id(a,o):new FormData(a),rc(l,{pending:!0,data:m,method:a.method,action:i},i,m))},currentTarget:a}]})}}for(var Kc=0;Kc<Ms.length;Kc++){var Vc=Ms[Kc],Wg=Vc.toLowerCase(),$g=Vc[0].toUpperCase()+Vc.slice(1);je(Wg,"on"+$g)}je(Ho,"onAnimationEnd"),je(Bo,"onAnimationIteration"),je(Lo,"onAnimationStart"),je("dblclick","onDoubleClick"),je("focusin","onFocus"),je("focusout","onBlur"),je(hg,"onTransitionRun"),je(dg,"onTransitionStart"),je(mg,"onTransitionCancel"),je(jo,"onTransitionEnd"),En("onMouseEnter",["mouseout","mouseover"]),En("onMouseLeave",["mouseout","mouseover"]),En("onPointerEnter",["pointerout","pointerover"]),En("onPointerLeave",["pointerout","pointerover"]),$l("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),$l("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),$l("onBeforeInput",["compositionend","keypress","textInput","paste"]),$l("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),$l("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),$l("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Za="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(" "),Fg=new Set("beforetoggle cancel close invalid load scroll scrollend toggle".split(" ").concat(Za));function ud(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 o=n.length-1;0<=o;o--){var h=n[o],m=h.instance,A=h.currentTarget;if(h=h.listener,m!==i&&a.isPropagationStopped())break t;i=h,a.currentTarget=A;try{i(a)}catch(C){wi(C)}a.currentTarget=null,i=m}else for(o=0;o<n.length;o++){if(h=n[o],m=h.instance,A=h.currentTarget,h=h.listener,m!==i&&a.isPropagationStopped())break t;i=h,a.currentTarget=A;try{i(a)}catch(C){wi(C)}a.currentTarget=null,i=m}}}}function P(t,e){var l=e[as];l===void 0&&(l=e[as]=new Set);var n=t+"__bubble";l.has(n)||(sd(e,t,2,!1),l.add(n))}function Zc(t,e,l){var n=0;e&&(n|=4),sd(l,t,n,e)}var pu="_reactListening"+Math.random().toString(36).slice(2);function Jc(t){if(!t[pu]){t[pu]=!0,Ir.forEach(function(l){l!=="selectionchange"&&(Fg.has(l)||Zc(l,!1,t),Zc(l,!0,t))});var e=t.nodeType===9?t:t.ownerDocument;e===null||e[pu]||(e[pu]=!0,Zc("selectionchange",!1,e))}}function sd(t,e,l,n){switch(Bd(e)){case 2:var a=xp;break;case 8:a=Mp;break;default:a=cr}l=a.bind(null,e,l,t),a=void 0,!ds||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 kc(t,e,l,n,a){var i=n;if((e&1)===0&&(e&2)===0&&n!==null)t:for(;;){if(n===null)return;var o=n.tag;if(o===3||o===4){var h=n.stateNode.containerInfo;if(h===a)break;if(o===4)for(o=n.return;o!==null;){var m=o.tag;if((m===3||m===4)&&o.stateNode.containerInfo===a)return;o=o.return}for(;h!==null;){if(o=vn(h),o===null)return;if(m=o.tag,m===5||m===6||m===26||m===27){n=i=o;continue t}h=h.parentNode}}n=n.return}oo(function(){var A=i,C=fs(l),D=[];t:{var _=qo.get(t);if(_!==void 0){var x=zi,B=t;switch(t){case"keypress":if(Mi(l)===0)break t;case"keydown":case"keyup":x=Ky;break;case"focusin":B="focus",x=ps;break;case"focusout":B="blur",x=ps;break;case"beforeblur":case"afterblur":x=ps;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=mo;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":x=Ry;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":x=Jy;break;case Ho:case Bo:case Lo:x=Hy;break;case jo:x=Wy;break;case"scroll":case"scrollend":x=Dy;break;case"wheel":x=Fy;break;case"copy":case"cut":case"paste":x=Ly;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":x=go;break;case"toggle":case"beforetoggle":x=Py}var X=(e&4)!==0,gt=!X&&(t==="scroll"||t==="scrollend"),S=X?_!==null?_+"Capture":null:_;X=[];for(var g=A,T;g!==null;){var O=g;if(T=O.stateNode,O=O.tag,O!==5&&O!==26&&O!==27||T===null||S===null||(O=ma(g,S),O!=null&&X.push(Ja(g,O,T))),gt)break;g=g.return}0<X.length&&(_=new x(_,B,null,l,C),D.push({event:_,listeners:X}))}}if((e&7)===0){t:{if(_=t==="mouseover"||t==="pointerover",x=t==="mouseout"||t==="pointerout",_&&l!==os&&(B=l.relatedTarget||l.fromElement)&&(vn(B)||B[pn]))break t;if((x||_)&&(_=C.window===C?C:(_=C.ownerDocument)?_.defaultView||_.parentWindow:window,x?(B=l.relatedTarget||l.toElement,x=A,B=B?vn(B):null,B!==null&&(gt=d(B),X=B.tag,B!==gt||X!==5&&X!==27&&X!==6)&&(B=null)):(x=null,B=A),x!==B)){if(X=mo,O="onMouseLeave",S="onMouseEnter",g="mouse",(t==="pointerout"||t==="pointerover")&&(X=go,O="onPointerLeave",S="onPointerEnter",g="pointer"),gt=x==null?_:da(x),T=B==null?_:da(B),_=new X(O,g+"leave",x,l,C),_.target=gt,_.relatedTarget=T,O=null,vn(C)===A&&(X=new X(S,g+"enter",B,l,C),X.target=T,X.relatedTarget=gt,O=X),gt=O,x&&B)e:{for(X=Ig,S=x,g=B,T=0,O=S;O;O=X(O))T++;O=0;for(var q=g;q;q=X(q))O++;for(;0<T-O;)S=X(S),T--;for(;0<O-T;)g=X(g),O--;for(;T--;){if(S===g||g!==null&&S===g.alternate){X=S;break e}S=X(S),g=X(g)}X=null}else X=null;x!==null&&cd(D,_,x,X,!1),B!==null&>!==null&&cd(D,gt,B,X,!0)}}t:{if(_=A?da(A):window,x=_.nodeName&&_.nodeName.toLowerCase(),x==="select"||x==="input"&&_.type==="file")var at=_o;else if(To(_))if(xo)at=rg;else{at=sg;var j=ug}else x=_.nodeName,!x||x.toLowerCase()!=="input"||_.type!=="checkbox"&&_.type!=="radio"?A&&rs(A.elementType)&&(at=_o):at=cg;if(at&&(at=at(t,A))){Ao(D,at,l,C);break t}j&&j(t,_,A),t==="focusout"&&A&&_.type==="number"&&A.memoizedProps.value!=null&&cs(_,"number",_.value)}switch(j=A?da(A):window,t){case"focusin":(To(j)||j.contentEditable==="true")&&(Cn=j,As=A,Ta=null);break;case"focusout":Ta=As=Cn=null;break;case"mousedown":_s=!0;break;case"contextmenu":case"mouseup":case"dragend":_s=!1,Uo(D,l,C);break;case"selectionchange":if(fg)break;case"keydown":case"keyup":Uo(D,l,C)}var k;if(Ss)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 Mn?bo(t,l)&&(et="onCompositionEnd"):t==="keydown"&&l.keyCode===229&&(et="onCompositionStart");et&&(po&&l.locale!=="ko"&&(Mn||et!=="onCompositionStart"?et==="onCompositionEnd"&&Mn&&(k=fo()):(Sl=C,ms="value"in Sl?Sl.value:Sl.textContent,Mn=!0)),j=vu(A,et),0<j.length&&(et=new yo(et,t,null,l,C),D.push({event:et,listeners:j}),k?et.data=k:(k=Eo(l),k!==null&&(et.data=k)))),(k=eg?lg(t,l):ng(t,l))&&(et=vu(A,"onBeforeInput"),0<et.length&&(j=new yo("onBeforeInput","beforeinput",null,l,C),D.push({event:j,listeners:et}),j.data=k)),kg(D,t,A,l,C)}ud(D,e)})}function Ja(t,e,l){return{instance:t,listener:e,currentTarget:l}}function vu(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=ma(t,l),a!=null&&n.unshift(Ja(t,a,i)),a=ma(t,e),a!=null&&n.push(Ja(t,a,i))),t.tag===3)return n;t=t.return}return[]}function Ig(t){if(t===null)return null;do t=t.return;while(t&&t.tag!==5&&t.tag!==27);return t||null}function cd(t,e,l,n,a){for(var i=e._reactName,o=[];l!==null&&l!==n;){var h=l,m=h.alternate,A=h.stateNode;if(h=h.tag,m!==null&&m===n)break;h!==5&&h!==26&&h!==27||A===null||(m=A,a?(A=ma(l,i),A!=null&&o.unshift(Ja(l,A,m))):a||(A=ma(l,i),A!=null&&o.push(Ja(l,A,m)))),l=l.return}o.length!==0&&t.push({event:e,listeners:o})}var Pg=/\r\n?/g,tp=/\u0000|\uFFFD/g;function rd(t){return(typeof t=="string"?t:""+t).replace(Pg,`
|
|
49
|
-
`).replace(tp,"")}function od(t,e){return e=rd(e),rd(t)===e}function yt(t,e,l,n,a,i){switch(l){case"children":typeof n=="string"?e==="body"||e==="textarea"&&n===""||An(t,n):(typeof n=="number"||typeof n=="bigint")&&e!=="body"&&An(t,""+n);break;case"className":Ti(t,"class",n);break;case"tabIndex":Ti(t,"tabindex",n);break;case"dir":case"role":case"viewBox":case"width":case"height":Ti(t,l,n);break;case"style":co(t,n,i);break;case"data":if(e!=="object"){Ti(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=_i(""+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"&&yt(t,e,"name",a.name,a,null),yt(t,e,"formEncType",a.formEncType,a,null),yt(t,e,"formMethod",a.formMethod,a,null),yt(t,e,"formTarget",a.formTarget,a,null)):(yt(t,e,"encType",a.encType,a,null),yt(t,e,"method",a.method,a,null),yt(t,e,"target",a.target,a,null)));if(n==null||typeof n=="symbol"||typeof n=="boolean"){t.removeAttribute(l);break}n=_i(""+n),t.setAttribute(l,n);break;case"onClick":n!=null&&(t.onclick=Ie);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(r(61));if(l=n.__html,l!=null){if(a.children!=null)throw Error(r(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=_i(""+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),Ei(t,"popover",n);break;case"xlinkActuate":Fe(t,"http://www.w3.org/1999/xlink","xlink:actuate",n);break;case"xlinkArcrole":Fe(t,"http://www.w3.org/1999/xlink","xlink:arcrole",n);break;case"xlinkRole":Fe(t,"http://www.w3.org/1999/xlink","xlink:role",n);break;case"xlinkShow":Fe(t,"http://www.w3.org/1999/xlink","xlink:show",n);break;case"xlinkTitle":Fe(t,"http://www.w3.org/1999/xlink","xlink:title",n);break;case"xlinkType":Fe(t,"http://www.w3.org/1999/xlink","xlink:type",n);break;case"xmlBase":Fe(t,"http://www.w3.org/XML/1998/namespace","xml:base",n);break;case"xmlLang":Fe(t,"http://www.w3.org/XML/1998/namespace","xml:lang",n);break;case"xmlSpace":Fe(t,"http://www.w3.org/XML/1998/namespace","xml:space",n);break;case"is":Ei(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=zy.get(l)||l,Ei(t,l,n))}}function Wc(t,e,l,n,a,i){switch(l){case"style":co(t,n,i);break;case"dangerouslySetInnerHTML":if(n!=null){if(typeof n!="object"||!("__html"in n))throw Error(r(61));if(l=n.__html,l!=null){if(a.children!=null)throw Error(r(60));t.innerHTML=l}}break;case"children":typeof n=="string"?An(t,n):(typeof n=="number"||typeof n=="bigint")&&An(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=Ie);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"innerHTML":case"ref":break;case"innerText":case"textContent":break;default:if(!Pr.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[ie]||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,""):Ei(t,l,n)}}}function Wt(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 o=l[i];if(o!=null)switch(i){case"src":n=!0;break;case"srcSet":a=!0;break;case"children":case"dangerouslySetInnerHTML":throw Error(r(137,e));default:yt(t,e,i,o,l,null)}}a&&yt(t,e,"srcSet",l.srcSet,l,null),n&&yt(t,e,"src",l.src,l,null);return;case"input":P("invalid",t);var h=i=o=a=null,m=null,A=null;for(n in l)if(l.hasOwnProperty(n)){var C=l[n];if(C!=null)switch(n){case"name":a=C;break;case"type":o=C;break;case"checked":m=C;break;case"defaultChecked":A=C;break;case"value":i=C;break;case"defaultValue":h=C;break;case"children":case"dangerouslySetInnerHTML":if(C!=null)throw Error(r(137,e));break;default:yt(t,e,n,C,l,null)}}ao(t,i,h,m,A,o,a,!1);return;case"select":P("invalid",t),n=o=i=null;for(a in l)if(l.hasOwnProperty(a)&&(h=l[a],h!=null))switch(a){case"value":i=h;break;case"defaultValue":o=h;break;case"multiple":n=h;default:yt(t,e,a,h,l,null)}e=i,l=o,t.multiple=!!n,e!=null?Tn(t,!!n,e,!1):l!=null&&Tn(t,!!n,l,!0);return;case"textarea":P("invalid",t),i=a=n=null;for(o in l)if(l.hasOwnProperty(o)&&(h=l[o],h!=null))switch(o){case"value":n=h;break;case"defaultValue":a=h;break;case"children":i=h;break;case"dangerouslySetInnerHTML":if(h!=null)throw Error(r(91));break;default:yt(t,e,o,h,l,null)}uo(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:yt(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<Za.length;n++)P(Za[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(r(137,e));default:yt(t,e,A,n,l,null)}return;default:if(rs(e)){for(C in l)l.hasOwnProperty(C)&&(n=l[C],n!==void 0&&Wc(t,e,C,n,l,void 0));return}}for(h in l)l.hasOwnProperty(h)&&(n=l[h],n!=null&&yt(t,e,h,n,l,null))}function ep(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,o=null,h=null,m=null,A=null,C=null;for(x in l){var D=l[x];if(l.hasOwnProperty(x)&&D!=null)switch(x){case"checked":break;case"value":break;case"defaultValue":m=D;default:n.hasOwnProperty(x)||yt(t,e,x,null,n,D)}}for(var _ in n){var x=n[_];if(D=l[_],n.hasOwnProperty(_)&&(x!=null||D!=null))switch(_){case"type":i=x;break;case"name":a=x;break;case"checked":A=x;break;case"defaultChecked":C=x;break;case"value":o=x;break;case"defaultValue":h=x;break;case"children":case"dangerouslySetInnerHTML":if(x!=null)throw Error(r(137,e));break;default:x!==D&&yt(t,e,_,x,n,D)}}ss(t,o,h,m,A,C,i,a);return;case"select":x=o=h=_=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)||yt(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":h=i;break;case"multiple":o=i;default:i!==m&&yt(t,e,a,i,n,m)}e=h,l=o,n=x,_!=null?Tn(t,!!l,_,!1):!!n!=!!l&&(e!=null?Tn(t,!!l,e,!0):Tn(t,!!l,l?[]:"",!1));return;case"textarea":x=_=null;for(h in l)if(a=l[h],l.hasOwnProperty(h)&&a!=null&&!n.hasOwnProperty(h))switch(h){case"value":break;case"children":break;default:yt(t,e,h,null,n,a)}for(o in n)if(a=n[o],i=l[o],n.hasOwnProperty(o)&&(a!=null||i!=null))switch(o){case"value":_=a;break;case"defaultValue":x=a;break;case"children":break;case"dangerouslySetInnerHTML":if(a!=null)throw Error(r(91));break;default:a!==i&&yt(t,e,o,a,n,i)}io(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:yt(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:yt(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 X in l)_=l[X],l.hasOwnProperty(X)&&_!=null&&!n.hasOwnProperty(X)&&yt(t,e,X,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(r(137,e));break;default:yt(t,e,A,_,n,x)}return;default:if(rs(e)){for(var gt in l)_=l[gt],l.hasOwnProperty(gt)&&_!==void 0&&!n.hasOwnProperty(gt)&&Wc(t,e,gt,void 0,n,_);for(C in n)_=n[C],x=l[C],!n.hasOwnProperty(C)||_===x||_===void 0&&x===void 0||Wc(t,e,C,_,n,x);return}}for(var S in l)_=l[S],l.hasOwnProperty(S)&&_!=null&&!n.hasOwnProperty(S)&&yt(t,e,S,null,n,_);for(D in n)_=n[D],x=l[D],!n.hasOwnProperty(D)||_===x||_==null&&x==null||yt(t,e,D,_,n,x)}function fd(t){switch(t){case"css":case"script":case"font":case"img":case"image":case"input":case"link":return!0;default:return!1}}function lp(){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,o=a.initiatorType,h=a.duration;if(i&&h&&fd(o)){for(o=0,h=a.responseEnd,n+=1;n<l.length;n++){var m=l[n],A=m.startTime;if(A>h)break;var C=m.transferSize,D=m.initiatorType;C&&fd(D)&&(m=m.responseEnd,o+=C*(m<h?1:(h-A)/(m-A)))}if(--n,e+=8*(i+o)/(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 $c=null,Fc=null;function Su(t){return t.nodeType===9?t:t.ownerDocument}function hd(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 dd(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 Ic(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 Pc=null;function np(){var t=window.event;return t&&t.type==="popstate"?t===Pc?!1:(Pc=t,!0):(Pc=null,!1)}var md=typeof setTimeout=="function"?setTimeout:void 0,ap=typeof clearTimeout=="function"?clearTimeout:void 0,yd=typeof Promise=="function"?Promise:void 0,ip=typeof queueMicrotask=="function"?queueMicrotask:typeof yd<"u"?function(t){return yd.resolve(null).then(t).catch(up)}:md;function up(t){setTimeout(function(){throw t})}function Bl(t){return t==="head"}function gd(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),ta(e);return}n--}else if(l==="$"||l==="$?"||l==="$~"||l==="$!"||l==="&")n++;else if(l==="html")ka(t.ownerDocument.documentElement);else if(l==="head"){l=t.ownerDocument.head,ka(l);for(var i=l.firstChild;i;){var o=i.nextSibling,h=i.nodeName;i[ha]||h==="SCRIPT"||h==="STYLE"||h==="LINK"&&i.rel.toLowerCase()==="stylesheet"||l.removeChild(i),i=o}}else l==="body"&&ka(t.ownerDocument.body);l=a}while(l);ta(e)}function pd(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 tr(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":tr(l),is(l);continue;case"SCRIPT":case"STYLE":continue;case"LINK":if(l.rel.toLowerCase()==="stylesheet")continue}t.removeChild(l)}}function sp(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[ha])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=we(t.nextSibling),t===null)break}return null}function cp(t,e,l){if(e==="")return null;for(;t.nodeType!==3;)if((t.nodeType!==1||t.nodeName!=="INPUT"||t.type!=="hidden")&&!l||(t=we(t.nextSibling),t===null))return null;return t}function vd(t,e){for(;t.nodeType!==8;)if((t.nodeType!==1||t.nodeName!=="INPUT"||t.type!=="hidden")&&!e||(t=we(t.nextSibling),t===null))return null;return t}function er(t){return t.data==="$?"||t.data==="$~"}function lr(t){return t.data==="$!"||t.data==="$?"&&t.ownerDocument.readyState!=="loading"}function rp(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 we(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 nr=null;function Sd(t){t=t.nextSibling;for(var e=0;t;){if(t.nodeType===8){var l=t.data;if(l==="/$"||l==="/&"){if(e===0)return we(t.nextSibling);e--}else l!=="$"&&l!=="$!"&&l!=="$?"&&l!=="$~"&&l!=="&"||e++}t=t.nextSibling}return null}function bd(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 Ed(t,e,l){switch(e=Su(l),t){case"html":if(t=e.documentElement,!t)throw Error(r(452));return t;case"head":if(t=e.head,!t)throw Error(r(453));return t;case"body":if(t=e.body,!t)throw Error(r(454));return t;default:throw Error(r(451))}}function ka(t){for(var e=t.attributes;e.length;)t.removeAttributeNode(e[0]);is(t)}var Re=new Map,Td=new Set;function bu(t){return typeof t.getRootNode=="function"?t.getRootNode():t.nodeType===9?t:t.ownerDocument}var ml=N.d;N.d={f:op,r:fp,D:hp,C:dp,L:mp,m:yp,X:pp,S:gp,M:vp};function op(){var t=ml.f(),e=fu();return t||e}function fp(t){var e=Sn(t);e!==null&&e.tag===5&&e.type==="form"?qf(e):ml.r(t)}var Fn=typeof document>"u"?null:document;function Ad(t,e,l){var n=Fn;if(n&&typeof e=="string"&&e){var a=_e(e);a='link[rel="'+t+'"][href="'+a+'"]',typeof l=="string"&&(a+='[crossorigin="'+l+'"]'),Td.has(a)||(Td.add(a),t={rel:t,crossOrigin:l,href:e},n.querySelector(a)===null&&(e=n.createElement("link"),Wt(e,"link",t),Gt(e),n.head.appendChild(e)))}}function hp(t){ml.D(t),Ad("dns-prefetch",t,null)}function dp(t,e){ml.C(t,e),Ad("preconnect",t,e)}function mp(t,e,l){ml.L(t,e,l);var n=Fn;if(n&&t&&e){var a='link[rel="preload"][as="'+_e(e)+'"]';e==="image"&&l&&l.imageSrcSet?(a+='[imagesrcset="'+_e(l.imageSrcSet)+'"]',typeof l.imageSizes=="string"&&(a+='[imagesizes="'+_e(l.imageSizes)+'"]')):a+='[href="'+_e(t)+'"]';var i=a;switch(e){case"style":i=In(t);break;case"script":i=Pn(t)}Re.has(i)||(t=R({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(Wa(i))||e==="script"&&n.querySelector($a(i))||(e=n.createElement("link"),Wt(e,"link",t),Gt(e),n.head.appendChild(e)))}}function yp(t,e){ml.m(t,e);var l=Fn;if(l&&t){var n=e&&typeof e.as=="string"?e.as:"script",a='link[rel="modulepreload"][as="'+_e(n)+'"][href="'+_e(t)+'"]',i=a;switch(n){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":i=Pn(t)}if(!Re.has(i)&&(t=R({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($a(i)))return}n=l.createElement("link"),Wt(n,"link",t),Gt(n),l.head.appendChild(n)}}}function gp(t,e,l){ml.S(t,e,l);var n=Fn;if(n&&t){var a=bn(n).hoistableStyles,i=In(t);e=e||"default";var o=a.get(i);if(!o){var h={loading:0,preload:null};if(o=n.querySelector(Wa(i)))h.loading=5;else{t=R({rel:"stylesheet",href:t,"data-precedence":e},l),(l=Re.get(i))&&ar(t,l);var m=o=n.createElement("link");Gt(m),Wt(m,"link",t),m._p=new Promise(function(A,C){m.onload=A,m.onerror=C}),m.addEventListener("load",function(){h.loading|=1}),m.addEventListener("error",function(){h.loading|=2}),h.loading|=4,Eu(o,e,n)}o={type:"stylesheet",instance:o,count:1,state:h},a.set(i,o)}}}function pp(t,e){ml.X(t,e);var l=Fn;if(l&&t){var n=bn(l).hoistableScripts,a=Pn(t),i=n.get(a);i||(i=l.querySelector($a(a)),i||(t=R({src:t,async:!0},e),(e=Re.get(a))&&ir(t,e),i=l.createElement("script"),Gt(i),Wt(i,"link",t),l.head.appendChild(i)),i={type:"script",instance:i,count:1,state:null},n.set(a,i))}}function vp(t,e){ml.M(t,e);var l=Fn;if(l&&t){var n=bn(l).hoistableScripts,a=Pn(t),i=n.get(a);i||(i=l.querySelector($a(a)),i||(t=R({src:t,async:!0,type:"module"},e),(e=Re.get(a))&&ir(t,e),i=l.createElement("script"),Gt(i),Wt(i,"link",t),l.head.appendChild(i)),i={type:"script",instance:i,count:1,state:null},n.set(a,i))}}function _d(t,e,l,n){var a=(a=F.current)?bu(a):null;if(!a)throw Error(r(446));switch(t){case"meta":case"title":return null;case"style":return typeof l.precedence=="string"&&typeof l.href=="string"?(e=In(l.href),l=bn(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=In(l.href);var i=bn(a).hoistableStyles,o=i.get(t);if(o||(a=a.ownerDocument||a,o={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},i.set(t,o),(i=a.querySelector(Wa(t)))&&!i._p&&(o.instance=i,o.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||Sp(a,t,l,o.state))),e&&n===null)throw Error(r(528,""));return o}if(e&&n!==null)throw Error(r(529,""));return null;case"script":return e=l.async,l=l.src,typeof l=="string"&&e&&typeof e!="function"&&typeof e!="symbol"?(e=Pn(l),l=bn(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(r(444,t))}}function In(t){return'href="'+_e(t)+'"'}function Wa(t){return'link[rel="stylesheet"]['+t+"]"}function xd(t){return R({},t,{"data-precedence":t.precedence,precedence:null})}function Sp(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}),Wt(e,"link",l),Gt(e),t.head.appendChild(e))}function Pn(t){return'[src="'+_e(t)+'"]'}function $a(t){return"script[async]"+t}function Md(t,e,l){if(e.count++,e.instance===null)switch(e.type){case"style":var n=t.querySelector('style[data-href~="'+_e(l.href)+'"]');if(n)return e.instance=n,Gt(n),n;var a=R({},l,{"data-href":l.href,"data-precedence":l.precedence,href:null,precedence:null});return n=(t.ownerDocument||t).createElement("style"),Gt(n),Wt(n,"style",a),Eu(n,l.precedence,t),e.instance=n;case"stylesheet":a=In(l.href);var i=t.querySelector(Wa(a));if(i)return e.state.loading|=4,e.instance=i,Gt(i),i;n=xd(l),(a=Re.get(a))&&ar(n,a),i=(t.ownerDocument||t).createElement("link"),Gt(i);var o=i;return o._p=new Promise(function(h,m){o.onload=h,o.onerror=m}),Wt(i,"link",n),e.state.loading|=4,Eu(i,l.precedence,t),e.instance=i;case"script":return i=Pn(l.src),(a=t.querySelector($a(i)))?(e.instance=a,Gt(a),a):(n=l,(a=Re.get(i))&&(n=R({},l),ir(n,a)),t=t.ownerDocument||t,a=t.createElement("script"),Gt(a),Wt(a,"link",n),t.head.appendChild(a),e.instance=a);case"void":return null;default:throw Error(r(443,e.type))}else e.type==="stylesheet"&&(e.state.loading&4)===0&&(n=e.instance,e.state.loading|=4,Eu(n,l.precedence,t));return e.instance}function Eu(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,o=0;o<n.length;o++){var h=n[o];if(h.dataset.precedence===e)i=h;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 ar(t,e){t.crossOrigin==null&&(t.crossOrigin=e.crossOrigin),t.referrerPolicy==null&&(t.referrerPolicy=e.referrerPolicy),t.title==null&&(t.title=e.title)}function ir(t,e){t.crossOrigin==null&&(t.crossOrigin=e.crossOrigin),t.referrerPolicy==null&&(t.referrerPolicy=e.referrerPolicy),t.integrity==null&&(t.integrity=e.integrity)}var Tu=null;function Cd(t,e,l){if(Tu===null){var n=new Map,a=Tu=new Map;a.set(l,n)}else a=Tu,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[ha]||i[Vt]||t==="link"&&i.getAttribute("rel")==="stylesheet")&&i.namespaceURI!=="http://www.w3.org/2000/svg"){var o=i.getAttribute(e)||"";o=t+o;var h=n.get(o);h?h.push(i):n.set(o,[i])}}return n}function zd(t,e,l){t=t.ownerDocument||t,t.head.insertBefore(l,e==="title"?t.querySelector("head > title"):null)}function bp(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 Od(t){return!(t.type==="stylesheet"&&(t.state.loading&3)===0)}function Ep(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=In(n.href),i=e.querySelector(Wa(a));if(i){e=i._p,e!==null&&typeof e=="object"&&typeof e.then=="function"&&(t.count++,t=Au.bind(t),e.then(t,t)),l.state.loading|=4,l.instance=i,Gt(i);return}i=e.ownerDocument||e,n=xd(n),(a=Re.get(a))&&ar(n,a),i=i.createElement("link"),Gt(i);var o=i;o._p=new Promise(function(h,m){o.onload=h,o.onerror=m}),Wt(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=Au.bind(t),e.addEventListener("load",l),e.addEventListener("error",l))}}var ur=0;function Tp(t,e){return t.stylesheets&&t.count===0&&xu(t,t.stylesheets),0<t.count||0<t.imgCount?function(l){var n=setTimeout(function(){if(t.stylesheets&&xu(t,t.stylesheets),t.unsuspend){var i=t.unsuspend;t.unsuspend=null,i()}},6e4+e);0<t.imgBytes&&ur===0&&(ur=62500*lp());var a=setTimeout(function(){if(t.waitingForImages=!1,t.count===0&&(t.stylesheets&&xu(t,t.stylesheets),t.unsuspend)){var i=t.unsuspend;t.unsuspend=null,i()}},(t.imgBytes>ur?50:800)+e);return t.unsuspend=l,function(){t.unsuspend=null,clearTimeout(n),clearTimeout(a)}}:null}function Au(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)xu(this,this.stylesheets);else if(this.unsuspend){var t=this.unsuspend;this.unsuspend=null,t()}}}var _u=null;function xu(t,e){t.stylesheets=null,t.unsuspend!==null&&(t.count++,_u=new Map,e.forEach(Ap,t),_u=null,Au.call(t))}function Ap(t,e){if(!(e.state.loading&4)){var l=_u.get(t);if(l)var n=l.get(null);else{l=new Map,_u.set(t,l);for(var a=t.querySelectorAll("link[data-precedence],style[data-precedence]"),i=0;i<a.length;i++){var o=a[i];(o.nodeName==="LINK"||o.getAttribute("media")!=="not all")&&(l.set(o.dataset.precedence,o),n=o)}n&&l.set(null,n)}a=e.instance,o=a.getAttribute("data-precedence"),i=l.get(o)||n,i===n&&l.set(null,a),l.set(o,a),this.count++,n=Au.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 Fa={$$typeof:Nt,Provider:null,Consumer:null,_currentValue:Q,_currentValue2:Q,_threadCount:0};function _p(t,e,l,n,a,i,o,h,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=es(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=es(0),this.hiddenUpdates=es(null),this.identifierPrefix=n,this.onUncaughtError=a,this.onCaughtError=i,this.onRecoverableError=o,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=m,this.incompleteTransitions=new Map}function Dd(t,e,l,n,a,i,o,h,m,A,C,D){return t=new _p(t,e,l,o,m,A,C,D,h),e=1,i===!0&&(e|=24),i=pe(3,null,null,e),t.current=i,i.stateNode=t,e=qs(),e.refCount++,t.pooledCache=e,e.refCount++,i.memoizedState={element:n,isDehydrated:l,cache:e},Qs(i),t}function wd(t){return t?(t=Dn,t):Dn}function Rd(t,e,l,n,a,i){a=wd(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&&(fe(l,t,e),Oa(l,t,e))}function Ud(t,e){if(t=t.memoizedState,t!==null&&t.dehydrated!==null){var l=t.retryLane;t.retryLane=l!==0&&l<e?l:e}}function sr(t,e){Ud(t,e),(t=t.alternate)&&Ud(t,e)}function Nd(t){if(t.tag===13||t.tag===31){var e=tn(t,67108864);e!==null&&fe(e,t,67108864),sr(t,67108864)}}function Hd(t){if(t.tag===13||t.tag===31){var e=Te();e=ls(e);var l=tn(t,e);l!==null&&fe(l,t,e),sr(t,e)}}var Mu=!0;function xp(t,e,l,n){var a=z.T;z.T=null;var i=N.p;try{N.p=2,cr(t,e,l,n)}finally{N.p=i,z.T=a}}function Mp(t,e,l,n){var a=z.T;z.T=null;var i=N.p;try{N.p=8,cr(t,e,l,n)}finally{N.p=i,z.T=a}}function cr(t,e,l,n){if(Mu){var a=rr(n);if(a===null)kc(t,e,n,Cu,l),Ld(t,n);else if(zp(a,t,e,l,n))n.stopPropagation();else if(Ld(t,n),e&4&&-1<Cp.indexOf(t)){for(;a!==null;){var i=Sn(a);if(i!==null)switch(i.tag){case 3:if(i=i.stateNode,i.current.memoizedState.isDehydrated){var o=Wl(i.pendingLanes);if(o!==0){var h=i;for(h.pendingLanes|=2,h.entangledLanes|=2;o;){var m=1<<31-ye(o);h.entanglements[1]|=m,o&=~m}Ze(i),(st&6)===0&&(ru=de()+500,Va(0))}}break;case 31:case 13:h=tn(i,2),h!==null&&fe(h,i,2),fu(),sr(i,2)}if(i=rr(n),i===null&&kc(t,e,n,Cu,l),i===a)break;a=i}a!==null&&n.stopPropagation()}else kc(t,e,n,null,l)}}function rr(t){return t=fs(t),or(t)}var Cu=null;function or(t){if(Cu=null,t=vn(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=p(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 Cu=t,null}function Bd(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(hy()){case Gr:return 2;case Qr:return 8;case gi:case dy:return 32;case Kr:return 268435456;default:return 32}default:return 32}}var fr=!1,Ll=null,jl=null,ql=null,Ia=new Map,Pa=new Map,Yl=[],Cp="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 Ld(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":Ia.delete(e.pointerId);break;case"gotpointercapture":case"lostpointercapture":Pa.delete(e.pointerId)}}function ti(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=Sn(e),e!==null&&Nd(e)),t):(t.eventSystemFlags|=n,e=t.targetContainers,a!==null&&e.indexOf(a)===-1&&e.push(a),t)}function zp(t,e,l,n,a){switch(e){case"focusin":return Ll=ti(Ll,t,e,l,n,a),!0;case"dragenter":return jl=ti(jl,t,e,l,n,a),!0;case"mouseover":return ql=ti(ql,t,e,l,n,a),!0;case"pointerover":var i=a.pointerId;return Ia.set(i,ti(Ia.get(i)||null,t,e,l,n,a)),!0;case"gotpointercapture":return i=a.pointerId,Pa.set(i,ti(Pa.get(i)||null,t,e,l,n,a)),!0}return!1}function jd(t){var e=vn(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,$r(t.priority,function(){Hd(l)});return}}else if(e===31){if(e=p(l),e!==null){t.blockedOn=e,$r(t.priority,function(){Hd(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 zu(t){if(t.blockedOn!==null)return!1;for(var e=t.targetContainers;0<e.length;){var l=rr(t.nativeEvent);if(l===null){l=t.nativeEvent;var n=new l.constructor(l.type,l);os=n,l.target.dispatchEvent(n),os=null}else return e=Sn(l),e!==null&&Nd(e),t.blockedOn=l,!1;e.shift()}return!0}function qd(t,e,l){zu(t)&&l.delete(e)}function Op(){fr=!1,Ll!==null&&zu(Ll)&&(Ll=null),jl!==null&&zu(jl)&&(jl=null),ql!==null&&zu(ql)&&(ql=null),Ia.forEach(qd),Pa.forEach(qd)}function Ou(t,e){t.blockedOn===e&&(t.blockedOn=null,fr||(fr=!0,s.unstable_scheduleCallback(s.unstable_NormalPriority,Op)))}var Du=null;function Yd(t){Du!==t&&(Du=t,s.unstable_scheduleCallback(s.unstable_NormalPriority,function(){Du===t&&(Du=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(or(n||l)===null)continue;break}var i=Sn(l);i!==null&&(t.splice(e,3),e-=3,rc(i,{pending:!0,data:a,method:l.method,action:n},n,a))}}))}function ta(t){function e(m){return Ou(m,t)}Ll!==null&&Ou(Ll,t),jl!==null&&Ou(jl,t),ql!==null&&Ou(ql,t),Ia.forEach(e),Pa.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);)jd(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],o=a[ie]||null;if(typeof i=="function")o||Yd(l);else if(o){var h=null;if(i&&i.hasAttribute("formAction")){if(a=i,o=i[ie]||null)h=o.formAction;else if(or(a)!==null)continue}else h=o.action;typeof h=="function"?l[n+1]=h:(l.splice(n,3),n-=3),Yd(l)}}}function Xd(){function t(i){i.canIntercept&&i.info==="react-transition"&&i.intercept({handler:function(){return new Promise(function(o){return a=o})},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 hr(t){this._internalRoot=t}wu.prototype.render=hr.prototype.render=function(t){var e=this._internalRoot;if(e===null)throw Error(r(409));var l=e.current,n=Te();Rd(l,n,t,e,null,null)},wu.prototype.unmount=hr.prototype.unmount=function(){var t=this._internalRoot;if(t!==null){this._internalRoot=null;var e=t.containerInfo;Rd(t.current,2,null,t,null,null),fu(),e[pn]=null}};function wu(t){this._internalRoot=t}wu.prototype.unstable_scheduleHydration=function(t){if(t){var e=Wr();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&&jd(t)}};var Gd=u.version;if(Gd!=="19.2.3")throw Error(r(527,Gd,"19.2.3"));N.findDOMNode=function(t){var e=t._reactInternals;if(e===void 0)throw typeof t.render=="function"?Error(r(188)):(t=Object.keys(t).join(","),Error(r(268,t)));return t=b(e),t=t!==null?U(t):null,t=t===null?null:t.stateNode,t};var Dp={bundleType:0,version:"19.2.3",rendererPackageName:"react-dom",currentDispatcherRef:z,reconcilerVersion:"19.2.3"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var Ru=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Ru.isDisabled&&Ru.supportsFiber)try{ra=Ru.inject(Dp),me=Ru}catch{}}return ai.createRoot=function(t,e){if(!f(t))throw Error(r(299));var l=!1,n="",a=Wf,i=$f,o=Ff;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&&(o=e.onRecoverableError)),e=Dd(t,1,!1,null,null,l,n,null,a,i,o,Xd),t[pn]=e.current,Jc(t),new hr(e)},ai.hydrateRoot=function(t,e,l){if(!f(t))throw Error(r(299));var n=!1,a="",i=Wf,o=$f,h=Ff,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&&(o=l.onCaughtError),l.onRecoverableError!==void 0&&(h=l.onRecoverableError),l.formState!==void 0&&(m=l.formState)),e=Dd(t,1,!0,e,l??null,n,a,m,i,o,h,Xd),e.context=wd(null),l=e.current,n=Te(),n=ls(n),a=xl(n),a.callback=null,Ml(l,a,n),l=n,e.current.lanes=l,fa(e,l),Ze(e),t[pn]=e.current,Jc(t),new wu(e)},ai.version="19.2.3",ai}var em;function Vp(){if(em)return yr.exports;em=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(),yr.exports=Kp(),yr.exports}var Zp=Vp();function lm(s){return s!==null&&typeof s=="object"&&[null,Object.prototype].includes(Object.getPrototypeOf(s))||Array.isArray(s)}function Ar(s,u,c=new WeakMap){if(Object.is(s,u))return!0;if(typeof s=="function"&&typeof u=="function")return typeof s==typeof u;if(!lm(s)||!lm(u))return!1;const r=c.get(s);if(r&&r===u)return!0;if(c.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(!Ar(s[y],u[y],c))return!1;return!0}const f=Object.keys(s),d=Object.keys(u);if(f.length!==d.length)return!1;for(let y=0;y<f.length;y++){const p=f[y];if(!Object.prototype.hasOwnProperty.call(u,p))return!1;const E=s[p],b=u[p];if(!Ar(E,b,c))return!1}return!0}function Jp(s){const u=[],c=(d,y)=>y.reduce((p,E)=>p==null?p:p[E],d),r=(d,y)=>(...p)=>{const E=c(s.current,d),b=E==null?void 0:E[y];if(typeof b=="function")return b.apply(E,p)},f=d=>{if(typeof d=="function"){const y=u[u.length-1],p=u.slice(0,-1);return r(p,y)}if(Array.isArray(d)){const y=u.length,p=new Array(d.length);for(let E=0;E<d.length;E++)u[y]=E,p[E]=f(d[E]);return u.length=y,p}if(d&&typeof d=="object"){const y=u.length,p={};for(const E of Object.keys(d))u[y]=E,p[E]=f(d[E]);return u.length=y,p}return d};return f(s.current)}function kp(s){const u=Wd.useRef(s);u.current=s;const c=Wd.useRef(null);return(!c.current||!Ar(c.current.snapshot,s))&&(c.current={snapshot:s,shaped:Jp(u)}),c.current.shaped}const Wp=Object.freeze(["focusComposer","setThreadId","focusMessage","sendUserMessage","setComposerValue","setRuntimeCapabilities","fetchUpdates","sendCustomAction"]);function $p(s){const u=bt.useRef(null),c=kp(s),r=bt.useMemo(()=>Wp.reduce((y,p)=>(y[p]=(...E)=>{if(!u.current){console.warn("ChatKit element is not mounted");return}return u.current[p](...E)},y),{}),[]),f=bt.useCallback(y=>{u.current=y},[]),d=bt.useMemo(()=>{const y={},p={};for(const[E,b]of Object.entries(c))/^on[A-Z]/.test(E)&&E!=="onClientTool"?p[E]=b:y[E]=b;return{setInstance:f,options:y,handlers:p}},[c,f]);return bt.useMemo(()=>({...r,control:d,ref:u}),[r,d])}class Fp{constructor(){St(this,"callbacks",new Map)}on(u,c){this.callbacks.has(u)||this.callbacks.set(u,new Set),this.callbacks.get(u).add(c)}emit(u,...c){var f;const r=c[0];(f=this.callbacks.get(u))==null||f.forEach(d=>d(r))}off(u,c){var r;c?(r=this.callbacks.get(u))==null||r.delete(c):this.callbacks.delete(u)}allOff(){this.callbacks.clear()}}async function Ip(s,u){const c=s.getReader();let r;for(;!(r=await c.read()).done;)u(r.value)}function Pp(s){let u,c,r,f=!1;return function(y){u===void 0?(u=y,c=0,r=-1):u=e0(u,y);const p=u.length;let E=0;for(;c<p;){f&&(u[c]===10&&(E=++c),f=!1);let b=-1;for(;c<p&&b===-1;++c)switch(u[c]){case 58:r===-1&&(r=c-E);break;case 13:f=!0;case 10:b=c;break}if(b===-1)break;s(u.subarray(E,b),r),E=c,r=-1}E===p?u=void 0:E!==0&&(u=u.subarray(E),c-=E)}}function t0(s,u,c){let r=nm();const f=new TextDecoder;return function(y,p){if(y.length===0)c==null||c(r),r=nm();else if(p>0){const E=f.decode(y.subarray(0,p)),b=p+(y[p+1]===32?2:1),U=f.decode(y.subarray(b));switch(E){case"data":r.data=r.data?r.data+`
|
|
50
|
-
`+U:U;break;case"event":r.event=U;break;case"id":s(r.id=U);break;case"retry":const R=parseInt(U,10);isNaN(R)||u(r.retry=R);break}}}}function e0(s,u){const c=new Uint8Array(s.length+u.length);return c.set(s),c.set(u,s.length),c}function nm(){return{data:"",event:"",id:"",retry:void 0}}var l0=function(s,u){var c={};for(var r in s)Object.prototype.hasOwnProperty.call(s,r)&&u.indexOf(r)<0&&(c[r]=s[r]);if(s!=null&&typeof Object.getOwnPropertySymbols=="function")for(var f=0,r=Object.getOwnPropertySymbols(s);f<r.length;f++)u.indexOf(r[f])<0&&Object.prototype.propertyIsEnumerable.call(s,r[f])&&(c[r[f]]=s[r[f]]);return c};const _r="text/event-stream",n0=1e3,am="last-event-id";function a0(s,u){var{signal:c,headers:r,onopen:f,onmessage:d,onclose:y,onerror:p,openWhenHidden:E,fetch:b}=u,U=l0(u,["signal","headers","onopen","onmessage","onclose","onerror","openWhenHidden","fetch"]);return new Promise((R,W)=>{const ct=Object.assign({},r);ct.accept||(ct.accept=_r);let Et;function ut(){Et.abort(),document.hidden||ne()}E||document.addEventListener("visibilitychange",ut);let Mt=n0,Tt=0;function Ut(){document.removeEventListener("visibilitychange",ut),window.clearTimeout(Tt),Et.abort()}c==null||c.addEventListener("abort",()=>{Ut(),R()});const Nt=b??window.fetch,le=f??i0;async function ne(){var Xt;Et=new AbortController;try{const $=await Nt(s,Object.assign(Object.assign({},U),{headers:ct,signal:Et.signal}));await le($),await Ip($.body,Pp(t0(Ct=>{Ct?ct[am]=Ct:delete ct[am]},Ct=>{Mt=Ct},d))),y==null||y(),Ut(),R()}catch($){if(!Et.signal.aborted)try{const Ct=(Xt=p==null?void 0:p($))!==null&&Xt!==void 0?Xt:Mt;window.clearTimeout(Tt),Tt=window.setTimeout(ne,Ct)}catch(Ct){Ut(),W(Ct)}}}ne()})}function i0(s){const u=s.headers.get("content-type");if(!(u!=null&&u.startsWith(_r)))throw new Error(`Expected content-type to be ${_r}, Actual: ${u}`)}const ia="__chatkit_error__";class Qu extends Error{constructor(c,r,f){super(c);St(this,"status");St(this,"statusText");St(this,"metadata");this.name="HttpError",this.statusText=r.statusText,this.status=r.status,this.metadata=f}static fromPossibleFrameSafeError(c){if(c instanceof Qu)return c;if(c&&typeof c=="object"&&ia in c&&c[ia]==="HttpError"){const r=c,f=new Qu(r.message,{status:r.status,statusText:r.statusText},r.metadata);return f.stack=r.stack,f}return null}}var Am;Am=ia;const qr=class qr{constructor(u,c,r){St(this,Am,"HttpError");St(this,"message");St(this,"stack");St(this,"status");St(this,"statusText");St(this,"metadata");this.message=u,this.stack=new Error(u).stack,this.status=c.status,this.statusText=c.statusText,this.metadata=r}static fromHttpError(u){return new qr(u.message,{status:u.status,statusText:u.statusText},u.metadata)}};let ci=qr;const u0=1e3,s0=1e4,c0=5,r0=(s,u=s0,c=u0)=>{const r=Math.min(u,c*2**s);return Math.floor(r*(.5+Math.random()*.5))};class im extends Error{constructor(u){super(),this.cause=u}}const o0=async(s,u)=>{let c=0;const{onopen:r,...f}=u;await a0(s,{...f,onopen:async d=>{var p;if(r==null||r(d),d.ok&&((p=d.headers.get("content-type"))!=null&&p.startsWith("text/event-stream"))){c=0;return}const y=new ci(`Streaming failed: ${d.statusText}`,d);throw d.status>=400&&d.status<500?y:new im(y)},onerror:d=>{if(d instanceof im){if(c>=c0)throw d.cause;return c+=1,r0(c)}throw d}})};function xm(){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(c=>c.toString(16).padStart(2,"0")).join("").replace(/^(.{8})(.{4})(.{4})(.{4})(.{12})$/,"$1-$2-$3-$4-$5")}return null}function Sr(){const s=xm();if(s===null)throw new Error("ChatKit requires crypto.randomUUID or crypto.getRandomValues to generate secure UUIDs.");return s}function f0(s,{channelId:u,expectedOrigin:c,expectedSource:r}){const f=s.data;if(!f||typeof f!="object"||!("__xpaiChatKit"in f)||f.__xpaiChatKit!==!0||c!=="*"&&s.origin!==c)return!1;if(s.source===r)return!0;const d=u==null?void 0:u.trim();return d?"channelId"in f&&f.channelId===d:!1}let h0=class Mm extends Error{constructor(c){super(c);St(this,"_name");this.name="IntegrationError",this._name=this.name}static fromPossibleFrameSafeError(c){if(c&&typeof c=="object"&&ia in c&&c[ia]==="IntegrationError"){const r=c,f=new Mm(r.message);return f.stack=r.stack,f}return null}};var _m;_m=ia;class d0{constructor(u){St(this,_m,"IntegrationError");St(this,"message");St(this,"stack");this.message=u,this.stack=new Error(u).stack}}function m0(s){try{return structuredClone(s)}catch{const u=s&&typeof s=="object"&&"message"in s&&typeof s.message=="string"?s.message:"ChatKit host request failed";return s&&typeof s=="object"&&"status"in s&&typeof s.status=="number"?new ci(u,{status:s.status,statusText:"statusText"in s&&typeof s.statusText=="string"?s.statusText:void 0}):new Error(u)}}class y0{constructor({handlers:u,target:c,targetOrigin:r,channelId:f,fetch:d=window.fetch}){St(this,"targetOrigin");St(this,"target");St(this,"channelId");St(this,"commandHandlers");St(this,"_fetch");St(this,"emitter",new Fp);St(this,"handlers",new Map);St(this,"fetchEventSourceHandlers",new Map);St(this,"abortControllers",new Map);St(this,"commands",new Proxy({},{get:(u,c)=>(r,f)=>new Promise((d,y)=>{const p=Sr();this.handlers.set(p,{resolve:d,reject:y,stack:new Error().stack||""}),this.sendMessage({type:"command",nonce:p,command:`on${c.charAt(0).toUpperCase()}${c.slice(1)}`,data:r},f)})}));St(this,"handleMessage",async u=>{var r,f,d,y;if(!f0(u,{channelId:this.channelId,expectedOrigin:this.targetOrigin,expectedSource:this.target()}))return;const c=u.data;switch(c.type){case"event":{this.emitter.emit(c.event,c.data);break}case"fetch":{try{if(c.formData){const U=new FormData;for(const[R,W]of Object.entries(c.formData))U.append(R,W);c.params.body=U}const p=new AbortController;this.abortControllers.set(c.nonce,p),c.params.signal=p.signal;const E=await this._fetch(c.url,c.params);if(!E.ok){const U=await E.json().then(R=>R.message||E.statusText).catch(()=>E.statusText);throw new ci(U,E)}const b=await E.json().catch(()=>({}));this.sendMessage({type:"response",response:b,nonce:c.nonce})}catch(p){this.sendMessage({type:"response",error:p,nonce:c.nonce})}break}case"fetchEventSource":{try{const p=new AbortController;this.abortControllers.set(c.nonce,p),await o0(c.url,{...c.params,signal:p.signal,fetch:this._fetch,onmessage:E=>{this.sendMessage({type:"fetchEventSourceMessage",message:E,nonce:c.nonce})}}),this.sendMessage({type:"response",response:void 0,nonce:c.nonce})}catch(p){this.sendMessage({type:"response",error:p,nonce:c.nonce})}break}case"command":{if(!this.canReceiveCommand(c.command)){this.sendMessage({type:"response",error:new d0(`Command ${c.command} not supported`),nonce:c.nonce});return}try{const p=await((f=(r=this.commandHandlers)[c.command])==null?void 0:f.call(r,c.data));this.sendMessage({type:"response",response:p,nonce:c.nonce})}catch(p){this.sendMessage({type:"response",error:p,nonce:c.nonce})}break}case"response":{const p=this.handlers.get(c.nonce);if(!p){console.error("No handler found for nonce",c.nonce);return}if(c.error){const E=h0.fromPossibleFrameSafeError(c.error),b=Qu.fromPossibleFrameSafeError(c.error);E?(E.stack=p.stack,p.reject(E)):b?p.reject(b):p.reject(c.error)}else p.resolve(c.response);this.handlers.delete(c.nonce);break}case"fetchEventSourceMessage":{if(!this.fetchEventSourceHandlers.get(c.nonce)){console.error("No handler found for nonce",c.nonce);return}(y=(d=this.fetchEventSourceHandlers.get(c.nonce))==null?void 0:d.onmessage)==null||y.call(d,c.message);break}case"abortSignal":{const p=this.abortControllers.get(c.nonce);p&&(p.abort(c.reason),this.abortControllers.delete(c.nonce));break}}});this.commandHandlers=u,this.target=c,this.targetOrigin=r,this.channelId=(f==null?void 0:f.trim())||void 0,this._fetch=((...y)=>d(...y))}setTargetOrigin(u){this.targetOrigin=u}sendMessage(u,c){var f;const r={__xpaiChatKit:!0,...this.channelId?{channelId:this.channelId}:{},...u,...u.type==="response"&&u.error!==void 0?{error:m0(u.error)}:{}};(f=this.target())==null||f.postMessage(r,this.targetOrigin,c)}connect(){window.addEventListener("message",this.handleMessage)}disconnect(){window.removeEventListener("message",this.handleMessage)}fetch(u,c){return new Promise((r,f)=>{const d=Sr();this.handlers.set(d,{resolve:r,reject:f,stack:new Error().stack||""});let y;if(c.body instanceof FormData){y={};for(const[p,E]of c.body.entries())y[p]=E;c.body=void 0}c.signal&&(c.signal.addEventListener("abort",()=>{var p;this.sendMessage({type:"abortSignal",nonce:d,reason:(p=c.signal)==null?void 0:p.reason})}),c.signal=void 0),this.sendMessage({type:"fetch",nonce:d,params:c,formData:y,url:u})})}fetchEventSource(u,c){return new Promise((r,f)=>{const{onmessage:d,signal:y,...p}=c,E=Sr();this.handlers.set(E,{resolve:r,reject:f,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:p,url:u})})}emit(...[u,c,r]){this.sendMessage({type:"event",event:u,data:c},r)}on(...[u,c]){this.emitter.on(u,c)}destroy(){window.removeEventListener("message",this.handleMessage),this.emitter.allOff(),this.handlers.clear()}}const g0=s=>btoa(s).replace(/\+/g,"-").replace(/\//g,"_").replace(/=+$/,""),p0=s=>{if(s===void 0)throw new TypeError("encodeBase64: `undefined` cannot be encoded to valid JSON. Pass null instead.");const u=JSON.stringify(s),c=new TextEncoder().encode(u);let r="";for(const f of c)r+=String.fromCharCode(f);return g0(r)};class It extends Error{}function v0(s){return s.message}const S0=["command.setOptions","command.sendUserMessage","command.setComposerValue","command.setRuntimeCapabilities","command.setThreadId","command.focusComposer","command.focusMessage","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.project.change","event.connectors.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"],b0=["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"],E0={chatkit:{allow:[...S0,"thread.item.image_generation"],deny:b0}},um=s=>{const u=E0[s],c=new Set(u.allow);for(const b of u.deny??[])c.delete(b);const r=new Set,f=new Set,d=new Set,y=new Set,p=new Set,E=new Set;for(const b of c){if(b.startsWith("command.")){r.add(b.slice(8));continue}if(b.startsWith("event.")){f.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.")){p.add(b.slice(6));continue}if(b.startsWith("widget.")){E.add(b.slice(7));continue}}return{commands:r,events:f,backend:d,threadItems:y,errors:p,widgets:E}};function T0(s){if(!s||typeof s!="object"||!("width"in s)||typeof s.width!="number"||!Number.isFinite(s.width)||s.width<=0||!("height"in s)||typeof s.height!="number"||!Number.isFinite(s.height)||s.height<=0||!("regions"in s)||!Array.isArray(s.regions)||s.regions.length>128)return null;const u=[];for(const c of s.regions){if(!c||typeof c!="object"||typeof c.x!="number"||!Number.isFinite(c.x)||c.x<0||typeof c.y!="number"||!Number.isFinite(c.y)||c.y<0||typeof c.width!="number"||!Number.isFinite(c.width)||c.width<=0||typeof c.height!="number"||!Number.isFinite(c.height)||c.height<=0||c.x+c.width>s.width+1||c.y+c.height>Math.min(s.height,96)+1)return null;u.push({x:c.x,y:c.y,width:c.width,height:c.height})}return{width:s.width,height:s.height,regions:u}}class A0{constructor(u,c){this.wrapper=u,this.enabled=c,this.size={width:0,height:0},this.layer=document.createElement("div"),this.layer.setAttribute("aria-hidden","true"),this.layer.dataset.slot="chatkit-window-drag",this.layer.style.cssText="position:absolute;inset:0;pointer-events:none;overflow:hidden;",u.append(this.layer),this.observer=new ResizeObserver(()=>{(this.wrapper.clientWidth!==this.size.width||this.wrapper.clientHeight!==this.size.height)&&this.clear()}),this.observer.observe(u)}update(u){if(this.clear(),!this.enabled())return;const c=T0(u);if(!(!c||Math.abs(c.width-this.wrapper.clientWidth)>1||Math.abs(c.height-this.wrapper.clientHeight)>1)){this.size={width:c.width,height:c.height};for(const r of c.regions){const f=document.createElement("div");f.style.cssText=`position:absolute;left:${r.x}px;top:${r.y}px;width:${r.width}px;height:${r.height}px;pointer-events:auto;user-select:none;-webkit-app-region:drag;`,this.layer.append(f)}}}clear(){this.layer.replaceChildren()}destroy(){this.observer.disconnect(),this.layer.remove()}}class _0 extends y0{canReceiveCommand(u){return!0}}const x0=["idle","running-right","running-left","waving","jumping","failed","waiting","running","review"],ii={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]}}},Hu={top:0,right:0,bottom:0,left:0},sm="chatkit:pet:position:v1",M0="/pets/boba/spritesheet.webp",xr={type:"sprite-atlas",src:M0},cm={pin:"bottom-right",draggable:!0,scale:.25,persist:!0,zIndex:40};function C0(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 z0(s,u=1){var r;const c={};for(const f of x0)c[f]=C0(ii.animations[f],(r=s==null?void 0:s.animations)==null?void 0:r[f]);return{columns:(s==null?void 0:s.columns)??ii.columns,rows:(s==null?void 0:s.rows)??(u===2?11:ii.rows),cellWidth:(s==null?void 0:s.cellWidth)??ii.cellWidth,cellHeight:(s==null?void 0:s.cellHeight)??ii.cellHeight,animations:c}}function O0(s){return s&&s.src?s:xr}function di(s){return s?s===!0?{character:xr,position:cm,behavior:"auto",ariaLabel:"Animated pet",imageRendering:"auto"}:s.enabled===!1?null:{character:O0(s.character),position:{...cm,...s.position},behavior:s.behavior??"auto",ariaLabel:s.ariaLabel??"Animated pet",imageRendering:s.imageRendering??"auto"}:null}function D0(s){return s.src?{kind:"atlas",src:s.src,atlas:z0(s.atlas,s.spriteVersionNumber)}:null}function br(s){return typeof s=="number"?{top:s,right:s,bottom:s,left:s}:{top:(s==null?void 0:s.top)??Hu.top,right:(s==null?void 0:s.right)??Hu.right,bottom:(s==null?void 0:s.bottom)??Hu.bottom,left:(s==null?void 0:s.left)??Hu.left}}function Ne(s,u,c,r){const f=r.left,d=r.top,y=Math.max(f,c.width-u.width-r.right),p=Math.max(d,c.height-u.height-r.bottom);return{x:Math.min(y,Math.max(f,s.x)),y:Math.min(p,Math.max(d,s.y))}}function w0(s,u,c,r){const f=(c.width-u.width)/2,d=(c.height-u.height)/2,y=c.width-u.width-r.right,p=c.height-u.height-r.bottom;switch(s){case"top-left":return Ne({x:r.left,y:r.top},u,c,r);case"top":return Ne({x:f,y:r.top},u,c,r);case"top-right":return Ne({x:y,y:r.top},u,c,r);case"left":return Ne({x:r.left,y:d},u,c,r);case"center":return Ne({x:f,y:d},u,c,r);case"right":return Ne({x:y,y:d},u,c,r);case"bottom-left":return Ne({x:r.left,y:p},u,c,r);case"bottom":return Ne({x:f,y:p},u,c,r);case"bottom-right":default:return Ne({x:y,y:p},u,c,r)}}const Mr=(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(r=>Mr(r,u));const c={};for(const[r,f]of Object.entries(s))typeof f!="function"?c[r]=Mr(f,u):c[r]="[ChatKitMethod]";return c},Bu=2,R0=.5,U0=1.5,N0=3,H0=2e3,rm=12,B0=320,Je=12,la=8,L0='system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif',om={"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 Lu(s){s.stopPropagation()}function na(){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 j0(s,u){if(!u)return null;try{const c=window.localStorage.getItem(s);if(!c)return null;const r=JSON.parse(c);return!r||typeof r!="object"||typeof r.x!="number"||typeof r.y!="number"?null:{x:r.x,y:r.y}}catch{return null}}function q0(s,u,c){if(u)try{window.localStorage.setItem(s,JSON.stringify(c))}catch{}}function Y0(s){return s.replace(/["\\]/g,"\\$&")}function fm(s){return Math.max(.1,s)*R0}function Ql(s,u,c){return Math.min(c,Math.max(u,s))}function X0(){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 hm(s){const u=(s??X0()??"").trim().toLowerCase();return u==="zh-cn"||u==="zh-hans"||u.startsWith("zh")?"zh-CN":"en-US"}function G0(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 Q0(s){switch(s){case"pill":return 24;case"round":return 16;case"sharp":return 0;case"soft":default:return 12}}function ui(s){var p,E;const u=typeof s=="string"?null:s,c=((p=u==null?void 0:u.typography)==null?void 0:p.baseSize)??16,r=(u==null?void 0:u.density)??"normal",f=r==="compact"?-1:r==="spacious"?1:0,d=Ql(c-2+f,11,17);return{...G0(r),bodySize:d,titleSize:d+1,iconSize:Ql(d+2,13,19),radius:Q0(u==null?void 0:u.radius),fontFamily:((E=u==null?void 0:u.typography)==null?void 0:E.fontFamily)??L0}}function K0(s){return s==="idle"||s==="running-right"||s==="running-left"||s==="waving"||s==="jumping"||s==="failed"||s==="waiting"||s==="running"||s==="review"}function V0(s){if(!s||typeof s!="object"||Array.isArray(s))return null;const u=s;return K0(u.state)?{state:u.state}:null}function Z0(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 J0(s){return s==="running"||s==="completed"||s==="failed"}function dm(s){return s?[s.threadId,s.messageId||s.updatedAt||s.message].join(":"):null}function mm(s){return s?[s.threadId,s.messageId??""].join(":"):null}function k0(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()||!J0(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 W0(s){if(!s||typeof s!="object"||Array.isArray(s))return null;const u=s;return u.name!=="thread.summary"?null:k0(u.data??null)}class $0{constructor(u,c){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=hm(),this.copy=om[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.activePointerId=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 r;this.prefersReducedMotion=!!((r=this.mediaQuery)!=null&&r.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=r=>{r.preventDefault(),r.stopPropagation(),this.openContextMenu({x:r.clientX,y:r.clientY})},this.handleContextMenuEvent=r=>{r.preventDefault(),r.stopPropagation()},this.handleContextMenuOutsidePointerDown=r=>{const f=this.contextMenuElement;f&&r.composedPath().includes(f)||this.closeContextMenu()},this.handleContextMenuKeyDown=r=>{r.key==="Escape"&&(r.preventDefault(),this.closeContextMenu())},this.handleClosePetMenuItemClick=r=>{var f;r.preventDefault(),r.stopPropagation(),this.closeContextMenu(),(f=this.onClose)==null||f.call(this)},this.handleSummaryPointerEnter=()=>{this.isSummaryHovering=!0,this.render()},this.handleSummaryPointerLeave=()=>{this.isSummaryHovering=!1,this.isReplyOpen||this.render()},this.handleSummaryClick=()=>{var f,d;const r=(f=this.summary)==null?void 0:f.threadId.trim();r&&((d=this.onThreadSummaryActivate)==null||d.call(this,r))},this.handleSummaryDelete=()=>{const r=dm(this.summary);r&&(this.dismissedSummaryKey=r),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=r=>{const f=r.currentTarget;f instanceof HTMLInputElement&&(this.replyDraft=f.value,this.replyError=null)},this.handleReplySubmit=r=>{r.preventDefault(),this.submitReply()},this.handleReplyKeyDown=r=>{r.key==="Escape"&&(r.preventDefault(),this.isReplyOpen=!1,this.replyError=null,this.render())},this.handlePointerDown=r=>{var y,p;if(r.button!==0||r.ctrlKey||this.isDragging||(this.closeContextMenu(),!((y=this.options)!=null&&y.position.draggable)))return;r.preventDefault();const f=(p=this.petElement)==null?void 0:p.getBoundingClientRect();if(!f)return;const d={x:f.left,y:f.top};this.dragOffset={x:r.clientX-f.left,y:r.clientY-f.top},this.lastDragPosition=d,this.lastDragClientX=r.clientX,this.dragAnimation=null,this.movedDuringDrag=!1,this.dragPosition=d,this.isDragging=!0,this.activePointerId=r.pointerId,this.clearRestingDelayTimer(),this.isHovering=!0,this.captureActivePointer(),this.installDragListeners(),this.rescheduleAnimation()},this.handlePointerMove=r=>{if(!this.isActiveDragPointer(r))return;const f=this.getNextDragPosition(r),d=this.lastDragPosition;if(d&&(Math.abs(d.x-f.x)>Bu||Math.abs(d.y-f.y)>Bu)&&(this.movedDuringDrag=!0),this.lastDragClientX!==null){const y=r.clientX-this.lastDragClientX;y>Bu?this.dragAnimation="running-right":y<-Bu&&(this.dragAnimation="running-left")}this.lastDragClientX=r.clientX,this.lastDragPosition=f,this.dragPosition=f,this.render()},this.handlePointerUp=r=>{if(!this.isActiveDragPointer(r))return;const f=this.lastDragPosition??this.getNextDragPosition(r);this.finishDrag(f,r)},this.handleLostPointerCapture=r=>{if(!this.isActiveDragPointer(r))return;const f=this.lastDragPosition??this.getNextDragPosition(r);this.finishDrag(f,r)},this.handleClick=()=>{var r;this.movedDuringDrag||((r=this.onActivate)==null||r.call(this),!this.prefersReducedMotion&&(this.transient={name:"waving"},this.render()))},this.root=u,this.onActivate=c==null?void 0:c.onActivate,this.onClose=c==null?void 0:c.onClose,this.onReply=c==null?void 0:c.onReply,this.onThreadSummaryActivate=c==null?void 0:c.onThreadSummaryActivate,this.connect()}connect(){this.connected||(this.connected=!0,this.installViewportListeners(),this.installReducedMotionListener(),this.render())}setOptions(u,c){this.closeContextMenu();const r=di(u);if(this.options=r,this.theme=c??null,!r){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=j0(sm,r.position.persist),r.behavior==="auto"&&!this.prefersReducedMotion&&(this.transient={name:"waving"}),this.resolveCharacter(),this.render()}setState(u){var r;const c=this.lastAutoState;this.lastAutoState=u,this.currentState=u,((r=this.options)==null?void 0:r.behavior)==="auto"&&!this.prefersReducedMotion&&u==="idle"&&(c==="running"||c==="review")&&!this.transient?this.transient={name:"jumping"}:u!=="idle"&&(this.transient=null),this.render()}setLocale(u){const c=hm(u);c!==this.copyLocale&&(this.copyLocale=c,this.copy=om[c],this.summaryRenderKey=null,this.closeContextMenu(),this.render())}setThreadSummary(u){const c=mm(this.summary),r=mm(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}c!==r&&(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,c,r,f;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),(c=window.visualViewport)==null||c.removeEventListener("scroll",this.handleViewportChange),(f=(r=this.mediaQuery)==null?void 0:r.removeEventListener)==null||f.call(r,"change",this.handleReducedMotionChange),this.mediaQuery=null)}installViewportListeners(){var u,c;window.addEventListener("resize",this.handleViewportChange),(u=window.visualViewport)==null||u.addEventListener("resize",this.handleViewportChange),(c=window.visualViewport)==null||c.addEventListener("scroll",this.handleViewportChange)}installReducedMotionListener(){var u,c;window.matchMedia&&(this.mediaQuery=window.matchMedia("(prefers-reduced-motion: reduce)"),this.prefersReducedMotion=this.mediaQuery.matches,(c=(u=this.mediaQuery).addEventListener)==null||c.call(u,"change",this.handleReducedMotionChange))}resolveCharacter(){if(!this.options){this.resolved=null;return}const u=this.options.character;this.resolved=D0(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 c=document.createElement("style");c.textContent=`
|
|
51
|
-
@keyframes chatkit-pet-summary-spin {
|
|
52
|
-
to { transform: rotate(360deg); }
|
|
53
|
-
}
|
|
54
|
-
`;const r=document.createElement("div");r.setAttribute("data-chatkit-host-pet",""),r.style.position="absolute",r.style.top="0",r.style.left="0",r.style.pointerEvents="auto",r.style.touchAction="none",r.style.userSelect="none",r.style.willChange="transform",r.addEventListener("pointerenter",this.handlePointerEnter),r.addEventListener("pointerleave",this.handlePointerLeave),r.addEventListener("pointerdown",this.handlePointerDown),r.addEventListener("lostpointercapture",this.handleLostPointerCapture),r.addEventListener("contextmenu",this.handleContextMenu),r.addEventListener("click",this.handleClick),u.append(c,r),this.root.append(u),this.overlayElement=u,this.petElement=r}removeOverlay(){var u;this.cancelActiveDrag(),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("lostpointercapture",this.handleLostPointerCapture),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,c;(u=this.summaryElement)==null||u.remove(),(c=this.summaryToggleElement)==null||c.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=fm(this.options.position.scale),c={width:this.resolved.atlas.cellWidth,height:this.resolved.atlas.cellHeight};return{width:c.width*u,height:c.height*u}}getCurrentPosition(u){const c=this.options;if(!c)return{x:0,y:0};const r=na(),f=br(c.position.boundsPadding),d=c.position.pin===void 0?"bottom-right":c.position.pin,y=d?w0(d,u,r,f):null;return Ne(this.dragPosition??this.position??y??{x:f.left,y:f.top},u,r,f)}persistPosition(u){if(!this.options)return;const c=this.getSize(),r=Ne(u,c,na(),br(this.options.position.boundsPadding));this.position=r,q0(sm,this.options.position.persist,r)}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,c){this.activeAnimationName===u&&this.activeAnimationMode===c||(this.clearTimers(),this.activeAnimationName=u,this.activeAnimationMode=c,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,c=this.petElement;if(!u||!c)return;const r=this.getSize(),f=this.getCurrentPosition(r),d=this.getActiveAnimationName(),y=this.getActiveAnimationMode();this.resetAnimationIfNeeded(d,y),u.style.zIndex=String(this.options.position.zIndex),c.style.width=`${r.width}px`,c.style.height=`${r.height}px`,c.style.transform=`translate3d(${f.x}px, ${f.y}px, 0)`,c.style.cursor=this.options.position.draggable?this.isDragging?"grabbing":"grab":"default",c.dataset.petAnimation=d,c.setAttribute("aria-label",this.options.ariaLabel),c.setAttribute("role","img"),this.renderAtlas(d,y),this.renderThreadSummary(f,r),this.scheduleNextFrame(d,y)}renderThreadSummary(u,c){var y,p,E;const r=this.summary,f=dm(r);if(!r||!f||this.dismissedSummaryKey===f){this.removeSummaryElements();return}if(this.isSummaryCollapsed){this.renderCollapsedSummary(u,c);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(),(p=this.summaryToggleElement)==null||p.remove(),this.summaryElement=this.createSummaryBubble(r),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(r),this.positionSummaryBubble(u,c)}renderCollapsedSummary(u,c){var r,f;(r=this.summaryElement)==null||r.remove(),this.summaryElement=null,this.summaryRenderKey=null,this.summaryToggleElement||(this.summaryToggleElement=this.createSummaryToggleButton("1"),(f=this.overlayElement)==null||f.append(this.summaryToggleElement)),this.summaryToggleElement.textContent="1",this.positionSummaryToggleBadge(u,c)}positionSummaryToggleBadge(u,c){const r=this.summaryToggleElement;if(!r)return;const f=na(),d=ui(this.theme).toggleSize,y=Ql(u.x+c.width-d*.35,Je,f.width-d-Je),p=Ql(u.y-d*.35,Je,f.height-d-Je);r.style.width=`${d}px`,r.style.height=`${d}px`,r.style.transform=`translate3d(${y}px, ${p}px, 0)`,r.style.borderRadius="999px"}positionSummaryBubble(u,c){const r=this.summaryElement,f=this.summaryToggleElement;if(!r||!f)return;const d=na(),y=Math.min(B0,d.width-Je*2);r.style.width=`${y}px`;const p=r.offsetHeight||96,E=u.y-p-rm,U=E>=Je?E:Ql(u.y+c.height+rm,Je,d.height-p-Je),R=Ql(u.x+c.width/2-y/2,Je,d.width-y-Je);r.style.transform=`translate3d(${R}px, ${U}px, 0)`,this.positionSummaryToggleBadge(u,c)}createSummaryBubble(u){const c=this.isSummaryHovering&&!this.isReplyOpen,r=ui(this.theme),f=document.createElement("div");f.setAttribute("data-chatkit-pet-summary",""),f.addEventListener("pointerenter",this.handleSummaryPointerEnter),f.addEventListener("pointerleave",this.handleSummaryPointerLeave),f.addEventListener("click",this.handleSummaryClick),f.style.position="absolute",f.style.top="0",f.style.left="0",f.style.boxSizing="border-box",f.style.pointerEvents="auto",f.style.padding=r.padding,f.style.border="1px solid rgba(148, 163, 184, 0.22)",f.style.borderRadius=`${r.radius}px`,f.style.background="rgba(255, 255, 255, 0.94)",f.style.color="#1f2937",f.style.boxShadow="0 8px 24px rgba(15, 23, 42, 0.1)",f.style.font=`500 ${r.bodySize}px/1.35 ${r.fontFamily}`,f.style.backdropFilter="blur(10px)";const d=document.createElement("div");d.style.display="flex",d.style.alignItems="center",d.style.gap=`${r.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=`${r.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 p=document.createElement("div");if(p.textContent=u.message,p.style.marginTop=`${r.marginTop}px`,p.style.fontWeight="400",p.style.color="#374151",p.style.overflow="hidden",this.isSummaryExpanded?(p.style.maxHeight="7em",p.style.overflowY="auto"):(p.style.display="-webkit-box",p.style.setProperty("-webkit-line-clamp","2"),p.style.setProperty("-webkit-box-orient","vertical")),p.dataset.chatkitPetSummaryMessage="",f.append(d,p),c){const E=this.createTextButton(this.copy.replyButton,this.handleReplyOpen);E.style.position="absolute",E.style.right="14px",E.style.bottom="10px",f.append(E)}return this.isReplyOpen&&f.append(this.createReplyForm()),f}updateSummaryBubbleContent(u){var d,y,p;const c=(d=this.summaryElement)==null?void 0:d.querySelector("[data-chatkit-pet-summary-title]");c&&c.textContent!==u.title&&(c.textContent=u.title);const r=(y=this.summaryElement)==null?void 0:y.querySelector("[data-chatkit-pet-summary-message]");r&&r.textContent!==u.message&&(r.textContent=u.message);const f=(p=this.summaryElement)==null?void 0:p.querySelector("[data-chatkit-pet-summary-status]");if(f&&f.dataset.chatkitPetSummaryStatus!==u.status){const E=this.createStatusIcon(u.status);f.replaceWith(E)}}createSummaryToggleButton(u){const c=ui(this.theme),r=document.createElement("button");return r.type="button",r.textContent=u,r.title=u==="1"?this.copy.restoreMessage:this.copy.collapseMessage,r.addEventListener("click",Lu),r.addEventListener("click",this.handleSummaryCollapseToggle),r.style.position="absolute",r.style.top="0",r.style.left="0",r.style.pointerEvents="auto",r.style.border="1px solid rgba(148, 163, 184, 0.28)",r.style.background="rgba(248, 250, 252, 0.94)",r.style.color="#475569",r.style.boxShadow="0 6px 18px rgba(15, 23, 42, 0.1)",r.style.cursor="pointer",r.style.font=`600 ${c.titleSize}px/1 ${c.fontFamily}`,r.style.display="flex",r.style.alignItems="center",r.style.justifyContent="center",r}createStatusIcon(u){const r=ui(this.theme).iconSize,f=document.createElement("span");if(f.setAttribute("aria-hidden","true"),f.dataset.chatkitPetSummaryStatus=u,f.style.display="inline-flex",f.style.width=`${r}px`,f.style.height=`${r}px`,f.style.alignItems="center",f.style.justifyContent="center",f.style.flex="0 0 auto",u==="running")return f.style.border="2px solid rgba(71, 85, 105, 0.32)",f.style.borderTopColor="#64748b",f.style.borderRadius="999px",f.style.animation="chatkit-pet-summary-spin 900ms linear infinite",f;if(f.style.borderRadius="999px",f.style.fontSize=`${Math.max(10,r-4)}px`,f.style.fontWeight="700",u==="failed")return f.textContent="!",f.style.background="#fee2e2",f.style.color="#b91c1c",f;f.textContent="",f.style.border="2px solid #22c55e",f.style.position="relative";const d=document.createElement("span");return d.style.width=`${Math.round(r*.44)}px`,d.style.height=`${Math.round(r*.25)}px`,d.style.borderLeft="2px solid #22c55e",d.style.borderBottom="2px solid #22c55e",d.style.transform="rotate(-45deg) translate(1px, -1px)",f.append(d),f}createSummaryActionButton(u,c,r){const f=ui(this.theme),d=document.createElement("button");return d.type="button",d.textContent=u,d.title=c,d.addEventListener("click",y=>{y.preventDefault(),y.stopPropagation(),r()}),d.style.width=`${f.actionSize}px`,d.style.height=`${f.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 ${f.titleSize}px/1 ${f.fontFamily}`,d}createTextButton(u,c){const r=document.createElement("button");return r.type="button",r.textContent=u,r.addEventListener("click",f=>{f.preventDefault(),f.stopPropagation(),c()}),r.style.border="1px solid rgba(148, 163, 184, 0.28)",r.style.borderRadius="999px",r.style.background="rgba(248, 250, 252, 0.95)",r.style.color="#334155",r.style.cursor="pointer",r.style.padding="3px 10px",r.style.font='600 12px/1.4 system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif',r}createReplyForm(){const u=document.createElement("form");u.addEventListener("click",Lu),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 c=document.createElement("input");c.type="text",c.value=this.replyDraft,c.disabled=this.isReplySubmitting,c.placeholder=this.copy.replyPlaceholder,c.addEventListener("input",this.handleReplyInput),c.style.minWidth="0",c.style.flex="1",c.style.border="1px solid rgba(148, 163, 184, 0.35)",c.style.borderRadius="999px",c.style.padding="6px 10px",c.style.font='400 13px/1.2 system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif',this.replyInputElement=c;const r=document.createElement("button");if(r.type="submit",r.textContent=this.isReplySubmitting?this.copy.sendingButton:this.copy.sendButton,r.disabled=this.isReplySubmitting,r.style.border="0",r.style.borderRadius="999px",r.style.background="#22c55e",r.style.color="#052e16",r.style.cursor=this.isReplySubmitting?"default":"pointer",r.style.padding="6px 10px",r.style.font='700 12px/1.2 system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif',u.append(c,r),this.replyError){const f=document.createElement("div");f.textContent=this.copy.sendFailed,f.style.flexBasis="100%",f.style.color="#b91c1c",f.style.fontSize="12px",u.style.flexWrap="wrap",u.append(f)}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",Lu),u.addEventListener("click",Lu),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 c=document.createElement("button");return c.type="button",c.textContent=this.copy.closePetMenuItem,c.setAttribute("role","menuitem"),c.addEventListener("click",this.handleClosePetMenuItemClick),c.style.display="block",c.style.width="100%",c.style.border="0",c.style.borderRadius="7px",c.style.background="transparent",c.style.color="inherit",c.style.cursor="pointer",c.style.padding="7px 10px",c.style.textAlign="left",c.style.font="inherit",u.append(c),u}openContextMenu(u){var f;const c=this.overlayElement;if(!c)return;this.closeContextMenu();const r=this.createContextMenu();c.append(r),this.contextMenuElement=r,this.positionContextMenu(u),(f=r.querySelector("button"))==null||f.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 c=this.contextMenuElement;if(!c)return;const r=na(),f=c.offsetWidth||132,d=c.offsetHeight||40,y=Math.max(la,r.width-f-la),p=Math.max(la,r.height-d-la),E=Ql(u.x,la,y),b=Ql(u.y,la,p);c.style.transform=`translate3d(${E}px, ${b}px, 0)`}renderAtlas(u,c){var W;if(!this.petElement||((W=this.resolved)==null?void 0:W.kind)!=="atlas"||!this.options)return;if(!(this.mediaElement instanceof HTMLDivElement)){const ct=document.createElement("div");ct.setAttribute("aria-hidden","true"),this.petElement.replaceChildren(ct),this.mediaElement=ct}const r=this.mediaElement,f=this.resolved.atlas,d=f.animations[u]??f.animations.idle,y=c==="once"&&this.completed?Math.max(0,d.frames-1):Math.min(this.frame,Math.max(0,d.frames-1)),p=fm(this.options.position.scale),E=f.cellWidth,b=f.cellHeight,U=f.columns*E,R=f.rows*b;r.style.width=`${E}px`,r.style.height=`${b}px`,r.style.overflow="hidden",r.style.transform=`scale(${p})`,r.style.transformOrigin="top left",r.style.pointerEvents="none",r.style.backgroundImage=`url("${Y0(this.resolved.src)}")`,r.style.backgroundRepeat="no-repeat",r.style.backgroundSize=`${U}px ${R}px`,r.style.backgroundPosition=`${-y*E}px ${-d.row*b}px`,r.style.imageRendering=this.options.imageRendering,r.dataset.petFrame=String(y)}scheduleNextFrame(u,c){if(this.prefersReducedMotion||this.completed||!this.resolved){this.clearTimers();return}if(this.frameTimer!==null)return;const r=this.resolved.atlas,f=r.animations[u]??r.animations.idle,y=(f.frameDurations[this.frame]??f.frameDurations[f.frameDurations.length-1]??150)*U0,p=this.isHovering||this.isDragging?y:y*N0;this.frameTimer=window.setTimeout(()=>{this.frameTimer=null;const E=this.frame+1;if(E>=f.frames){if(c==="once"){this.completed=!0,this.frame=Math.max(0,f.frames-1),this.finishTransient();return}this.frame=0,this.render();return}this.frame=E,this.render()},p)}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())},H0)}isPointOverPet(u,c){var f;const r=(f=this.petElement)==null?void 0:f.getBoundingClientRect();return r?u>=r.left&&u<=r.right&&c>=r.top&&c<=r.bottom:!1}isPointerOverPet(u){return this.isPointOverPet(u.clientX,u.clientY)}async submitReply(){var c;const u=this.replyDraft.trim();if(!(!u||this.isReplySubmitting)){this.isReplySubmitting=!0,this.replyError=null,this.render();try{await((c=this.onReply)==null?void 0:c.call(this,u)),this.replyDraft="",this.isReplyOpen=!1,this.isSummaryHovering=!1}catch{this.replyError="Failed to send"}finally{this.isReplySubmitting=!1,this.render()}}}captureActivePointer(){const u=this.activePointerId,c=this.petElement;if(!(u===null||typeof(c==null?void 0:c.setPointerCapture)!="function"))try{c.setPointerCapture(u)}catch{}}releaseActivePointer(){const u=this.activePointerId,c=this.petElement;if(this.activePointerId=null,!(u===null||typeof(c==null?void 0:c.hasPointerCapture)!="function"||typeof c.releasePointerCapture!="function"))try{c.hasPointerCapture(u)&&c.releasePointerCapture(u)}catch{}}isActiveDragPointer(u){return this.isDragging&&u.pointerId===this.activePointerId}getNextDragPosition(u){return this.options?Ne({x:u.clientX-this.dragOffset.x,y:u.clientY-this.dragOffset.y},this.getSize(),na(),br(this.options.position.boundsPadding)):{x:0,y:0}}finishDrag(u,c){this.isDragging=!1,this.dragPosition=null,this.dragAnimation=null,this.lastDragClientX=null,this.removeDragListeners(),this.releaseActivePointer(),this.persistPosition(u),c.pointerType==="mouse"&&this.isPointerOverPet(c)?(this.isHovering=!0,this.rescheduleAnimation()):(this.enterRestingAfterDelay(),this.rescheduleAnimation())}cancelActiveDrag(){this.isDragging=!1,this.dragPosition=null,this.dragAnimation=null,this.lastDragPosition=null,this.lastDragClientX=null,this.removeDragListeners(),this.releaseActivePointer()}installDragListeners(){window.addEventListener("pointermove",this.handlePointerMove),window.addEventListener("pointerup",this.handlePointerUp),window.addEventListener("pointercancel",this.handlePointerUp)}removeDragListeners(){window.removeEventListener("pointermove",this.handlePointerMove),window.removeEventListener("pointerup",this.handlePointerUp),window.removeEventListener("pointercancel",this.handlePointerUp)}}var F0=Object.create,Cm=Object.defineProperty,I0=Object.getOwnPropertyDescriptor,zm=(s,u)=>(u=Symbol[s])?u:Symbol.for("Symbol."+s),Vu=s=>{throw TypeError(s)},P0=(s,u,c)=>u in s?Cm(s,u,{enumerable:!0,configurable:!0,writable:!0,value:c}):s[u]=c,tv=s=>[,,,F0((s==null?void 0:s[zm("metadata")])??null)],Om=["class","method","getter","setter","accessor","field","value","get","set"],Dm=s=>s!==void 0&&typeof s!="function"?Vu("Function expected"):s,ev=(s,u,c,r,f)=>({kind:Om[s],name:u,metadata:r,addInitializer:d=>c._?Vu("Already initialized"):f.push(Dm(d||null))}),lv=(s,u)=>P0(u,zm("metadata"),s[3]),nv=(s,u,c,r)=>{for(var f=0,d=s[u>>1],y=d&&d.length;f<y;f++)d[f].call(c);return r},Be=(s,u,c,r,f,d)=>{for(var y,p,E,b,U=u&7,R=!1,W=!1,ct=2,Et=Om[U+5],ut=s[ct]||(s[ct]=[]),Mt=(f=f.prototype,I0(f,c)),Tt=r.length-1;Tt>=0;Tt--)E=ev(U,c,p={},s[3],ut),E.static=R,E.private=W,b=E.access={has:Ut=>c in Ut},b.get=Ut=>Ut[c],y=(0,r[Tt])(Mt[Et],E),p._=1,Dm(y)&&(Mt[Et]=y);return Mt&&Cm(f,c,Mt),f},Ur=(s,u,c)=>u.has(s)||Vu("Cannot "+c),M=(s,u,c)=>(Ur(s,u,"read from private field"),c?c.call(s):u.get(s)),qt=(s,u,c)=>u.has(s)?Vu("Cannot add the same private member more than once"):u instanceof WeakSet?u.add(s):u.set(s,c),$t=(s,u,c,r)=>(Ur(s,u,"write to private field"),u.set(s,c),c),G=(s,u,c)=>(Ur(s,u,"access private method"),c),wm,Rm,Um,Nm,Hm,Bm,Lm,jm,qm,Ym,Xm,Gm,Cr,nt,Vl,yl,gl,mn,qu,Nr,Zu,ua,yn,ke,He,Yu,Kt,ri,ht,Y,Gl,Hr,We,Ju,Qm,ku,Km,Vm,Br,Zl,mi,zr,Zm,Jm,km,Wm,Xu,$m,Fm,Im,Gu,sa,Or,ee;function Pm(s){return Mr(s)}function Ue(s,u){const c=String(u.name);return function(...r){if(!this.capabilities.commands.has(c))throw new It(`ChatKit command "${String(c)}" is not available for the "${this.profile}" profile.`);return s.apply(this,r)}}class he extends(Cr=HTMLElement,Gm=[Ue],Xm=[Ue],Ym=[Ue],qm=[Ue],jm=[Ue],Lm=[Ue],Bm=[Ue],Hm=[Ue],Nm=[Ue],Um=[Ue],Rm=[Ue],wm=[Ue],Cr){constructor({profile:u}){super(),nv(ee,5,this),qt(this,Y),this.profile=void 0,this.capabilities=void 0,qt(this,nt),qt(this,Vl),qt(this,yl),qt(this,gl),qt(this,mn),qt(this,qu),qt(this,Nr,!1),qt(this,Zu,!1),qt(this,ua),qt(this,yn,!1),qt(this,ke,this.attachShadow({mode:"open"})),qt(this,He,new $0(M(this,ke),{onActivate:()=>G(this,Y,Zm).call(this),onClose:()=>G(this,Y,Jm).call(this),onReply:c=>G(this,Y,km).call(this,c),onThreadSummaryActivate:c=>void G(this,Y,Wm).call(this,c)})),qt(this,Yu),qt(this,Kt,new Promise(c=>{$t(this,Yu,c)})),qt(this,ri,xm()),qt(this,ht,new _0({channelId:M(this,ri)??void 0,fetch:((...c)=>{var f;const r=((f=M(this,nt))==null?void 0:f.api)&&"fetch"in M(this,nt).api&&M(this,nt).api.fetch;return r?r(...c):fetch(...c)}),target:()=>{var c;return((c=M(this,yl))==null?void 0:c.contentWindow)??null},targetOrigin:window.location.origin,handlers:{onRealtimeVoiceCommand:c=>{var f;const r=(f=M(this,nt))==null?void 0:f.realtimeVoice;if(!r||c.type==="start"&&!r.enabled)throw new It("Realtime voice is unavailable.");return r.onCommand(c)},onFileInputClick:({inputAttributes:c})=>new Promise(r=>{const f=document.createElement("input");for(const[y,p]of Object.entries(c))f.setAttribute(y,String(p));const d=()=>{r(Array.from(f.files||[])),M(this,ke).contains(f)&&M(this,ke).removeChild(f)};f.addEventListener("cancel",d),f.addEventListener("change",d),M(this,ke).appendChild(f),f.click()}),onApprovalDecision:async c=>{var f,d;const r=(d=(f=M(this,nt))==null?void 0:f.approvals)==null?void 0:d.onDecision;if(!r)throw new It("Add approvals.onDecision to handle host approvals.");return r(c)},onApprovalAction:async c=>{var f,d;const r=(d=(f=M(this,nt))==null?void 0:f.approvals)==null?void 0:d.onAction;if(!r)throw new It("Add approvals.onAction to handle approval actions.");return r(c)},onClientToolCall:async({name:c,params:r,id:f,tool_call_id:d})=>{var p;const y=(p=M(this,nt))==null?void 0:p.onClientTool;return y||G(this,Y,Gl).call(this,new It("No handler for client tool calls. You'll need to add onClientTool to your ChatKit options.")),y({name:c,params:r,id:f,tool_call_id:d})},onToolOutputAttachmentPreview:async c=>{var f,d;const r=(d=(f=M(this,nt))==null?void 0:f.toolOutputAttachments)==null?void 0:d.onRequestPreview;return r||G(this,Y,Gl).call(this,new It("No handler for tool-output attachment previews. Add toolOutputAttachments.onRequestPreview to your ChatKit options.")),r(c)},onConnectWorkspaceConnector:async c=>{var f,d,y;const r=(y=(d=(f=M(this,nt))==null?void 0:f.composer)==null?void 0:d.resources)==null?void 0:y.onConnect;return r||G(this,Y,Gl).call(this,new It("Add composer.resources.onConnect to handle workspace Connector connections.")),r(c)},onWorkbenchNavigationChange:async c=>{var r,f,d;await((d=(f=(r=M(this,nt))==null?void 0:r.workbench)==null?void 0:f.onNavigationChange)==null?void 0:d.call(f,c))},onWorkbenchClientCommand:async({commandKey:c,payload:r,hostType:f,hostId:d,viewKey:y,userActivated:p})=>{var b,U;const E=(U=(b=M(this,nt))==null?void 0:b.workbench)==null?void 0:U.onClientCommand;return E?E({commandKey:c,payload:r,hostType:f,hostId:d,viewKey:y,...p!==void 0?{userActivated:p}:{}}):{success:!1,code:"unsupported",commandKey:c}},onWidgetAction:async({action:c,widgetItem:r})=>{var d,y;const f=(y=(d=M(this,nt))==null?void 0:d.widgets)==null?void 0:y.onAction;return f||G(this,Y,Gl).call(this,new It("No handler for widget actions. You'll need to add widgets.onAction to your ChatKit options.")),f(c,r)},onEntitySearch:async({query:c})=>{var r,f,d;return((d=(f=(r=M(this,nt))==null?void 0:r.entities)==null?void 0:f.onTagSearch)==null?void 0:d.call(f,c))??[]},onEntityClick:async({entity:c})=>{var r,f,d;return(d=(f=(r=M(this,nt))==null?void 0:r.entities)==null?void 0:f.onClick)==null?void 0:d.call(f,c)},onEntityPreview:async({entity:c})=>{var r,f,d;return((d=(f=(r=M(this,nt))==null?void 0:r.entities)==null?void 0:f.onRequestPreview)==null?void 0:d.call(f,c))??{preview:null}},onGetClientSecret:async c=>((!M(this,nt)||!("getClientSecret"in M(this,nt).api)||!M(this,nt).api.getClientSecret)&&G(this,Y,Gl).call(this,new It("Could not refresh the session because ChatKitOptions.api.getClientSecret is not configured.")),M(this,nt).api.getClientSecret(c??null)),onAddMetadataToRequest:({op:c,params:r})=>{throw new It("ChatKit: onAddMetadataToRequest is unimplemented.")}}})),qt(this,Xu,()=>{G(this,Y,Zl).call(this,!1)}),qt(this,Gu,()=>{var c;this.dataset.loaded="true",this.dispatchEvent(new CustomEvent("chatkit.ready",{bubbles:!0,composed:!0})),(c=M(this,Yu))==null||c.call(this)}),qt(this,sa,!1),this.profile=u,this.capabilities=um(u)}setProfile(u){this.profile=u,this.capabilities=um(u)}connectedCallback(){M(this,He).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 c=document.createElement("iframe");c.className="ck-iframe",c.name="chatkit",c.role="presentation",c.tabIndex=0,c.setAttribute("allowtransparency","true"),c.setAttribute("frameborder","0"),c.setAttribute("scrolling","no"),c.setAttribute("allow","clipboard-read; clipboard-write"),$t(this,yl,c);const r=document.createElement("div");r.className="ck-wrapper",r.appendChild(c),$t(this,gl,r);const f=document.createElement("button");f.className="ck-launcher-close",f.type="button",f.setAttribute("aria-label","Close chat"),f.addEventListener("click",M(this,Xu)),r.appendChild(f),$t(this,qu,f),$t(this,mn,new A0(r,()=>{var d,y;return((y=(d=M(this,nt))==null?void 0:d.header)==null?void 0:y.windowDrag)===!0})),M(this,ht).on("window_drag_regions",d=>{var y;return(y=M(this,mn))==null?void 0:y.update(d)}),M(this,ke).append(u),M(this,ht).on("left_header_icon_click",()=>{var d,y,p;(p=(y=(d=M(this,nt))==null?void 0:d.header)==null?void 0:y.leftAction)==null||p.onClick()}),M(this,ht).on("right_header_icon_click",()=>{var d,y,p;(p=(y=(d=M(this,nt))==null?void 0:d.header)==null?void 0:y.rightAction)==null||p.onClick()}),M(this,ht).on("public_event",([d,y])=>{if(d==="log"){const p=W0(y);p&&M(this,He).setThreadSummary(p.summary)}else d==="response.start"?M(this,He).setThreadSummaryStatus("running"):d==="response.end"?M(this,He).setThreadSummaryStatus("completed"):d==="response.stop"&&M(this,He).setThreadSummaryStatus("completed");if(this.capabilities.events.has(d)){if(d==="error"&&"error"in y){const p=v0(y.error);if(this.dispatchEvent(new CustomEvent("chatkit.error",{detail:{error:p}})),p instanceof It)throw p;return}this.dispatchEvent(new CustomEvent(`chatkit.${d}`,{detail:y}))}}),M(this,ht).on("pet_state_change",d=>{const y=V0(d);y&&M(this,He).setState(y.state)}),M(this,ht).on("pet_options_change",d=>{const y=Z0(d);y&&((!M(this,yn)||y.pet===null)&&$t(this,yn,!1),$t(this,ua,y.pet),G(this,Y,zr).call(this))}),M(this,ht).on("chat_minimize_change",d=>{const y=typeof d=="object"&&d!==null&&"minimized"in d&&d.minimized===!0;y&&!G(this,Y,ku).call(this)||(G(this,Y,mi).call(this,y),y&&G(this,Y,Zl).call(this,!1))}),M(this,ht).on("unmount",()=>{var d;(d=M(this,mn))==null||d.destroy(),M(this,gl)&&M(this,ke).contains(M(this,gl))&&(M(this,ke).removeChild(M(this,gl)),$t(this,gl,void 0),$t(this,yl,void 0))}),M(this,ht).on("capabilities_profile_change",({profile:d})=>{this.setProfile(d)}),c.addEventListener("load",M(this,Gu),{once:!0});try{G(this,Y,Or).call(this)}catch(d){console.error(d),G(this,Y,Gl).call(this,d instanceof Error?d:new It("Failed to initialize ChatKit"))}}disconnectedCallback(){var u,c,r;(u=M(this,mn))==null||u.destroy(),(c=M(this,yl))==null||c.removeEventListener("load",M(this,Gu)),(r=M(this,qu))==null||r.removeEventListener("click",M(this,Xu)),M(this,ht).disconnect(),M(this,He).destroy()}applySanitizedOptions(u){var c,r;$t(this,nt,u),(c=u.header)!=null&&c.windowDrag||(r=M(this,mn))==null||r.clear(),$t(this,yn,!1),M(this,He).setLocale(u.locale),G(this,Y,zr).call(this),M(this,sa)?(G(this,Y,Hr).call(this,M(this,nt)),M(this,Kt).then(()=>{M(this,ht).commands.setOptions(Pm(G(this,Y,Br).call(this,u)))})):G(this,Y,Or).call(this)}setOptions(u){try{const c=this.sanitizeOptions(u);G(this,Y,Im).call(this,c),this.applySanitizedOptions(c)}catch(c){G(this,Y,Gl).call(this,c instanceof Error?c:new It("Failed to parse options"))}}async focusComposer(){var u,c;await M(this,Kt),(u=M(this,yl))==null||u.focus(),await((c=M(this,ht))==null?void 0:c.commands.focusComposer())}async fetchUpdates(){var u;await M(this,Kt),await((u=M(this,ht))==null?void 0:u.commands.fetchUpdates())}async sendUserMessage(u){var c;await M(this,Kt),await((c=M(this,ht))==null?void 0:c.commands.sendUserMessage(u))}async setComposerValue(u){var c;await M(this,Kt),await((c=M(this,ht))==null?void 0:c.commands.setComposerValue(u))}async setRuntimeCapabilities(u){var c;await M(this,Kt),await((c=M(this,ht))==null?void 0:c.commands.setRuntimeCapabilities(u))}async setThreadId(u){var c;await M(this,Kt),await((c=M(this,ht))==null?void 0:c.commands.setThreadId({threadId:u}))}async focusMessage(u){return await M(this,Kt),M(this,ht)?M(this,ht).commands.focusMessage(u):{success:!1,code:"not_ready"}}async shareThread(){var u;return await M(this,Kt),(u=M(this,ht))==null?void 0:u.commands.shareThread()}async sendCustomAction(u,c){var r;return await M(this,Kt),(r=M(this,ht))==null?void 0:r.commands.sendCustomAction({action:u,itemId:c})}async showHistory(){var u;return await M(this,Kt),(u=M(this,ht))==null?void 0:u.commands.showHistory()}async hideHistory(){var u;return await M(this,Kt),(u=M(this,ht))==null?void 0:u.commands.hideHistory()}async setTrainingOptOut(u){var c;return await M(this,Kt),(c=M(this,ht))==null?void 0:c.commands.setTrainingOptOut({value:u})}}ee=tv(Cr);nt=new WeakMap;Vl=new WeakMap;yl=new WeakMap;gl=new WeakMap;mn=new WeakMap;qu=new WeakMap;Nr=new WeakMap;Zu=new WeakMap;ua=new WeakMap;yn=new WeakMap;ke=new WeakMap;He=new WeakMap;Yu=new WeakMap;Kt=new WeakMap;ri=new WeakMap;ht=new WeakMap;Y=new WeakSet;Gl=function(s){throw this.dispatchEvent(new CustomEvent("chatkit.error",{detail:{error:s}})),s};Hr=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=G(this,Y,We).call(this,s),G(this,Y,We).call(this,s)!=="pet"&&G(this,Y,Zl).call(this,!1)};We=function(s=M(this,nt)){return(s==null?void 0:s.displayMode)==="pet"?"pet":"chat"};Ju=function(s=M(this,nt)){return s?G(this,Y,We).call(this,s)==="pet"&&!di(s.pet??null)?!0:s.pet??null:null};Qm=function(s){if(!s)return s;const u=di(G(this,Y,Ju).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};ku=function(){var u;if(M(this,yn)||((u=M(this,nt))==null?void 0:u.pet)===!1&&G(this,Y,We).call(this)!=="pet")return null;let s;return M(this,ua)!==void 0?s=G(this,Y,Qm).call(this,M(this,ua)):s=G(this,Y,Ju).call(this),G(this,Y,We).call(this)==="pet"&&!di(s??null)&&(s=!0),G(this,Y,Vm).call(this,s)};Km=function(s){try{const u=new URL(M(this,Vl)??window.location.href,window.location.origin);return new URL(s,u).toString()}catch{return s}};Vm=function(s){const u=di(s??null);return u?{character:{...u.character,src:G(this,Y,Km).call(this,u.character.src)},position:u.position,behavior:u.behavior,ariaLabel:u.ariaLabel,imageRendering:u.imageRendering}:null};Br=function(s){const u=G(this,Y,Ju).call(this,s);if(u===(s.pet??null))return s;const c={...s};return u===null?delete c.pet:c.pet=u,c};Zl=function(s){$t(this,Nr,s),s?this.dataset.chatOpen="true":delete this.dataset.chatOpen};mi=function(s){const u=s&&!!G(this,Y,ku).call(this);$t(this,Zu,u),u?this.dataset.chatMinimizedToPet="true":delete this.dataset.chatMinimizedToPet};zr=function(){var u;const s=G(this,Y,ku).call(this);M(this,He).setOptions(s,(u=M(this,nt))==null?void 0:u.theme),s||G(this,Y,mi).call(this,!1)};Zm=function(){if(M(this,Zu)){G(this,Y,mi).call(this,!1),G(this,Y,We).call(this)==="pet"&&G(this,Y,Zl).call(this,!0),M(this,Kt).then(()=>this.focusComposer()).catch(()=>{});return}G(this,Y,We).call(this)==="pet"&&(G(this,Y,Zl).call(this,!0),M(this,Kt).then(()=>this.focusComposer()).catch(()=>{}))};Jm=function(){$t(this,yn,!0),$t(this,ua,null),G(this,Y,mi).call(this,!1),G(this,Y,Zl).call(this,!1),M(this,He).setOptions(null),G(this,Y,We).call(this)!=="pet"&&M(this,Kt).then(()=>M(this,ht).commands.setPetEnabled({enabled:!1})).catch(()=>{})};km=async function(s){await this.sendUserMessage({text:s})};Wm=async function(s){G(this,Y,We).call(this)==="pet"&&G(this,Y,Zl).call(this,!0),await this.setThreadId(s),await this.focusComposer()};Xu=new WeakMap;$m=function(){if(!M(this,Vl))throw new It("ChatKit frameUrl is not configured. Provide it via setOptions({ frameUrl }) before mounting.");return M(this,Vl)};Fm=function(s){if(M(this,sa)&&M(this,Vl)&&M(this,Vl)!==s)throw new It("ChatKit frameUrl cannot be changed after initialization. Create a new element to use a different URL.");$t(this,Vl,s)};Im=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 It("ChatKit frameUrl must be a non-empty string.");G(this,Y,Fm).call(this,u)}};Gu=new WeakMap;sa=new WeakMap;Or=function(){if(M(this,sa)||!M(this,yl)||!M(this,nt))return;$t(this,sa,!0),G(this,Y,Hr).call(this,M(this,nt));const s=new URL(G(this,Y,$m).call(this),window.location.origin);M(this,ht).setTargetOrigin(s.origin),s.hash=p0({options:Pm(G(this,Y,Br).call(this,M(this,nt))),referrer:window.location.origin,profile:this.profile,...M(this,ri)?{channelId:M(this,ri)}:{}}),M(this,ht).connect(),M(this,yl).src=s.toString(),M(this,gl)&&M(this,ke).append(M(this,gl))};Be(ee,1,"focusComposer",Gm,he);Be(ee,1,"fetchUpdates",Xm,he);Be(ee,1,"sendUserMessage",Ym,he);Be(ee,1,"setComposerValue",qm,he);Be(ee,1,"setRuntimeCapabilities",jm,he);Be(ee,1,"setThreadId",Lm,he);Be(ee,1,"focusMessage",Bm,he);Be(ee,1,"shareThread",Hm,he);Be(ee,1,"sendCustomAction",Nm,he);Be(ee,1,"showHistory",Um,he);Be(ee,1,"hideHistory",Rm,he);Be(ee,1,"setTrainingOptOut",wm,he);lv(ee,he);class av extends he{constructor(){super({profile:"chatkit"})}sanitizeOptions(u){var c;return(c=u.threadItemActions)==null||delete c.share,u}}function iv(s="xpertai-chatkit"){"customElements"in globalThis&&(customElements.get(s)||customElements.define(s,av))}iv();const ty={"chatkit.error":"onError","chatkit.response.end":"onResponseEnd","chatkit.response.start":"onResponseStart","chatkit.log":"onLog","chatkit.thread.change":"onThreadChange","chatkit.project.change":"onProjectChange","chatkit.connectors.change":"onConnectorsChange","chatkit.thread.load.start":"onThreadLoadStart","chatkit.thread.load.end":"onThreadLoadEnd","chatkit.ready":"onReady","chatkit.effect":"onEffect"},uv=Object.keys(ty),sv=bt.forwardRef(function({control:u,...c},r){const f=bt.useRef(null);return bt.useLayoutEffect(()=>{const d=f.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]),bt.useEffect(()=>{const d=f.current;if(!d)return;const y=new AbortController;for(const p of uv)d.addEventListener(p,E=>{const b=ty[p],U=u.handlers[b];typeof U=="function"&&U(E.detail)},{signal:y.signal});return()=>{y.abort()}},[u.handlers]),K.jsx("xpertai-chatkit",{ref:d=>{f.current=d,u.setInstance(d),typeof r=="function"?r(d):r&&(r.current=d),f.current},...c})}),cv=["office_word_snapshot","office_word_insert_text","office_word_replace_selection","office_word_insert_heading","office_word_insert_table","office_word_search_text"],rv=new Set(cv);function ov(s){return rv.has(s)}const fv=5e3,hv=20;function ey(s){return typeof s=="string"&&s.trim()?s.trim():void 0}function ju(s,u){const c=ey(s);if(!c)throw new Error(`${u} must be a non-empty string.`);return c}function ym(s){return typeof s=="boolean"?s:void 0}function oi(s){if(!(typeof s!="number"||!Number.isInteger(s)||s<=0))return s}function Dr(s,u){const c=oi(s);if(c===void 0)throw new Error(`${u} must be a positive integer.`);return c}function Er(s,u="End"){var r;const c=(r=ey(s))==null?void 0:r.toLowerCase();if(!c)return u;if(c==="start")return"Start";if(c==="end")return"End";throw new Error("location must be Start or End.")}function dv(s){if(s===void 0)return 1;const u=Dr(s,"level");if(u>9)throw new Error("level must be between 1 and 9.");return u}function mv(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 yv(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(mv)})}}function gv(s){const u=yv(s.values),c=oi(s.rowCount),r=oi(s.columnCount);if(!u)return{rowCount:Dr(s.rowCount,"rowCount"),columnCount:Dr(s.columnCount,"columnCount")};const f=u.length,d=u.reduce((E,b)=>Math.max(E,b.length),0),y=c??f,p=r??d;if(y<=0||p<=0)throw new Error("values must include at least one row and one column.");return{rowCount:y,columnCount:p,values:Array.from({length:y},(E,b)=>Array.from({length:p},(U,R)=>{var W;return((W=u[b])==null?void 0:W[R])??""}))}}function wr(s){var u;return((u=s.Content)==null?void 0:u.Text)??""}function ly(s,u){var y;const c=s.Content;if(!c)throw new Error("The active WPS document does not expose a content range.");const r=c.Start??0,f=c.End??wr(s).length,d=u==="Start"?r:f;return((y=s.Range)==null?void 0:y.call(s,d,d))??c}function gm(s,u,c){const r=ly(s,c);return c==="Start"&&r.InsertBefore?(r.InsertBefore(u),r):c==="End"&&r.InsertAfter?(r.InsertAfter(u),r):(r.Text=u,r)}function pv(s){return-(s+1)}function vv(s,u){s!=null&&s.Cell&&u.forEach((c,r)=>{c.forEach((f,d)=>{var p;const y=(p=s.Cell)==null?void 0:p.call(s,r+1,d+1);y!=null&&y.Range&&(y.Range.Text=f)})})}function Sv(s){return{name:s.Name??"WPS Writer",build:s.Build,version:s.Version}}function pm(s){return/^[\p{L}\p{N}_]$/u.test(s)}function bv(s,u,c){const r=u>0?s[u-1]:"",f=u+c<s.length?s[u+c]:"";return!pm(r)&&!pm(f)}function Ev(s,u,c){const r=c.matchCase?s:s.toLocaleLowerCase(),f=c.matchCase?u:u.toLocaleLowerCase(),d=[];let y=0;for(;y<=r.length;){const p=r.indexOf(f,y);if(p===-1)break;y=p+Math.max(f.length,1),!(c.matchWholeWord&&!bv(s,p,u.length))&&d.push({index:p+1,text:s.slice(p,p+u.length)})}return d}var fi,hi;class Tv{constructor(u={}){Uu(this,fi);Uu(this,hi);this.host="WPS Writer",Nu(this,fi,u.maxSnapshotCharacters??fv),Nu(this,hi,u.maxSearchResults??hv)}supports(u){return ov(u)}async execute(u,c){switch(u){case"office_word_snapshot":return this.snapshot(c);case"office_word_insert_text":return this.insertText(c);case"office_word_replace_selection":return this.replaceSelection(c);case"office_word_insert_heading":return this.insertHeading(c);case"office_word_insert_table":return this.insertTable(c);case"office_word_search_text":return this.searchText(c)}}snapshot(u){var y;const c=oi(u.maxCharacters)??ei(this,fi),r=ea(),f=li(r),d=wr(f);return{host:Sv(r),requirements:{wpsJsApi:!0},documentName:f.Name,bodyTextLength:d.length,bodyTextPreview:d.slice(0,c),bodyTextTruncated:d.length>c,selectionText:((y=r.Selection)==null?void 0:y.Text)??""}}insertText(u){const c=ju(u.text,"text"),r=Er(u.location),f=li(ea());return gm(f,c,r),{inserted:!0,location:r,textLength:c.length}}replaceSelection(u){const c=ju(u.text,"text"),r=Np(ea());return r.TypeText?r.TypeText(c):r.Text=c,{replaced:!0,textLength:c.length}}insertHeading(u){const c=ju(u.text,"text"),r=dv(u.level),f=Er(u.location),d=li(ea()),y=gm(d,`${c}\r`,f);return y.Style=pv(r),{inserted:!0,level:r,location:f,textLength:c.length}}insertTable(u){var p,E,b;const c=Er(u.location),r=gv(u),f=li(ea()),d=ly(f,c),y=(E=(p=f.Tables)==null?void 0:p.Add)==null?void 0:E.call(p,d,r.rowCount,r.columnCount);if(!((b=f.Tables)!=null&&b.Add))throw new Error("The active WPS document does not expose table insertion.");return r.values&&vv(y,r.values),{inserted:!0,location:c,rowCount:r.rowCount,columnCount:r.columnCount}}searchText(u){const c=ju(u.query,"query"),r=oi(u.maxResults)??ei(this,hi),f=ym(u.matchCase),d=ym(u.matchWholeWord),y=li(ea()),p=Ev(wr(y),c,{matchCase:f,matchWholeWord:d}),E=p.slice(0,r).map((b,U)=>({index:U+1,start:b.index,text:b.text}));return{query:c,count:p.length,results:E,truncated:p.length>E.length}}}fi=new WeakMap,hi=new WeakMap;function ny(s={}){return new Tv(s)}var aa;class Av{constructor(u){Uu(this,aa);Nu(this,aa,u)}supports(u){return ei(this,aa).some(c=>c.supports(u))}async execute(u,c){const r=ei(this,aa).find(f=>f.supports(u));if(!r)throw new Error(`Unknown Office tool: ${u}`);return r.execute(u,c)}}aa=new WeakMap;function _v(s){return new Av(s)}function xv(s){return typeof s=="object"&&s!==null&&!Array.isArray(s)?s:{}}function Tr(s,u,c){return{tool_call_id:s.tool_call_id??s.id,name:s.name,status:u,content:JSON.stringify(c)}}function Mv(s){return s instanceof Error?s.message:String(s)}function Cv(s={}){const u=s.registry??_v([s.adapter??ny()]);return async c=>{if(!u.supports(c.name))return Tr(c,"error",{ok:!1,error:`Unknown Office tool: ${c.name}`});try{const r=await u.execute(c.name,xv(c.params));return Tr(c,"success",{ok:!0,result:r})}catch(r){return Tr(c,"error",{ok:!1,error:Mv(r)})}}}const Lr="xpertai.chatkit.wps.config.v1",ay=600,zv="https://api.xpertai.cn/api/ai",Ov="https://app.xpertai.cn/chatkit/index.html",Dv="/api/create-session";function wv(s){return s.replace(/\/+$/,"")}function jr(s){if(typeof s!="string"&&typeof s!="number")return;const u=Number(s);return Number.isInteger(u)&&u>0?u:void 0}function Kl(s){return typeof s=="string"&&s.trim()?s.trim():void 0}function iy(){return typeof window>"u"?{}:window.XPERTAI_WPS_CONFIG??{}}function Rv(){if(typeof window>"u")return{};try{const s=window.localStorage.getItem(Lr);if(!s)return{};const u=JSON.parse(s);return u&&typeof u=="object"&&!Array.isArray(u)?u:{}}catch{return{}}}function Uv(...s){const u={};for(const c of s){const r=Kl(c.apiUrl),f=Kl(c.apiKey),d=Kl(c.xpertId),y=Kl(c.frameUrl),p=jr(c.expiresAfter);r&&(u.apiUrl=r),f&&(u.apiKey=f),d&&(u.xpertId=d),y&&(u.frameUrl=y),p&&(u.expiresAfter=p)}return u}function Nv(){const s=iy().sessionMode;return s==="proxy"||s==="user-api-key"?s:"user-api-key"}function uy(){return Uv({apiUrl:zv,frameUrl:Ov,xpertId:void 0,apiKey:void 0,expiresAfter:jr(void 0)},Rv(),iy())}function sy(s){const u=Kl(s.apiUrl),c=Kl(s.apiKey),r=Kl(s.xpertId),f=Kl(s.frameUrl);if(!u)throw new Error("XPERTAI_API_URL is required.");if(!c)throw new Error("XPERTAI_API_KEY is required.");if(!r)throw new Error("XPERTAI_XPERT_ID is required.");if(!f)throw new Error("XPERTAI_CHATKIT_FRAME_URL is required.");return{apiUrl:wv(u),apiKey:c,xpertId:r,frameUrl:f,expiresAfter:jr(s.expiresAfter)??ay}}function vm(){try{return sy(uy())}catch{return null}}function Hv(s){window.localStorage.setItem(Lr,JSON.stringify(s))}function Bv(){window.localStorage.removeItem(Lr)}async function Sm(s){const u=await fetch(Dv,{method:"POST",headers:{"Content-Type":"application/json"},credentials:"include",body:JSON.stringify(s?{currentClientSecret:s}:{})}),c=await u.json().catch(()=>({}));if(!u.ok)throw new Error(c.error||`HTTP ${u.status}`);if(!c.client_secret||!c.apiUrl||!c.frameUrl||!c.xpertId)throw new Error("ChatKit session response is missing required fields.");return c}async function bm(s){const u=`${s.apiUrl}/v1/chatkit/sessions`;let c;try{c=await fetch(u,{method:"POST",headers:{"Content-Type":"application/json","x-api-key":s.apiKey},body:JSON.stringify({expires_after:s.expiresAfter??ay})})}catch(f){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. ${f instanceof Error?f.message:String(f)}`)}const r=await c.json().catch(()=>({}));if(!c.ok)throw new Error(r.error||c.statusText||`HTTP ${c.status}`);if(!r.client_secret)throw new Error("Missing client_secret in Xpert ChatKit session response.");return{client_secret:r.client_secret,expires_at:r.expires_at,expires_after:r.expires_after??s.expiresAfter,apiUrl:s.apiUrl,frameUrl:s.frameUrl,xpertId:s.xpertId,organizationId:null}}async function Lv(){const s=Hp();return s?{host:s.Name,build:s.Build,version:s.Version,isWpsHost:!0}:{isWpsHost:!1}}function Ku(s){return s instanceof Error?s.message:String(s)}function jv(){return navigator.language.toLowerCase().startsWith("zh")?"zh-Hans":"en"}function qv({createSession:s,initialSession:u,onConfigure:c}){const[r,f]=bt.useState(u),[d,y]=bt.useState(null),p=bt.useMemo(()=>Cv({adapter:ny()}),[]),E=bt.useMemo(()=>({frameUrl:r.frameUrl,locale:jv(),api:{apiUrl:r.apiUrl,xpertId:r.xpertId,getClientSecret:async U=>{const R=U?await s(U):r;return f(R),R.organizationId?{secret:R.client_secret,organizationId:R.organizationId}:R.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 U=>{y(null);const R=await p(U);return R.status==="error"&&y(typeof R.content=="string"?R.content:"Office tool failed."),R},onError:U=>{y(Ku(U))}}),[s,p,r]),b=$p(E);return K.jsxs("main",{className:"taskpane",children:[d?K.jsxs("div",{className:"status-banner error",children:[K.jsx("span",{children:d}),c?K.jsx("button",{className:"link-button",type:"button",onClick:c,children:"Settings"}):null]}):null,K.jsx(sv,{control:b.control,className:"chatkit-shell"})]})}function si(s,u){const c=s.get(u);return typeof c=="string"?c:void 0}function Yv({error:s,initialConfig:u,isConnecting:c,onSave:r}){const[f,d]=bt.useState(null);function y(E){E.preventDefault();const b=new FormData(E.currentTarget);try{d(null),r(sy({apiUrl:si(b,"apiUrl"),apiKey:si(b,"apiKey"),xpertId:si(b,"xpertId"),frameUrl:si(b,"frameUrl"),expiresAfter:Number(si(b,"expiresAfter"))}))}catch(U){d(Ku(U))}}function p(){Bv(),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||f?K.jsx("div",{className:"settings-error",children:f??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:c,type:"submit",children:c?"Connecting...":"Save and Connect"}),K.jsx("button",{disabled:c,type:"button",onClick:p,children:"Clear"})]})]})})}function Em(){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 Tm({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 Xv(){const[s]=bt.useState(()=>Nv()),[u,c]=bt.useState(null),[r,f]=bt.useState(null),[d,y]=bt.useState(()=>vm()),[p,E]=bt.useState(!1),[b,U]=bt.useState(!0),[R,W]=bt.useState(null),ct=bt.useCallback(async ut=>{U(!0),W(null);try{const Mt=await bm(ut);Hv(ut),y(ut),f(Mt),E(!1)}catch(Mt){f(null),E(!0),W(Ku(Mt))}finally{U(!1)}},[]);bt.useEffect(()=>{let ut=!1;async function Mt(){try{const Tt=await Lv();if(ut)return;if(c(Tt),s==="proxy"){const Nt=await Sm();ut||(f(Nt),U(!1));return}const Ut=vm();if(y(Ut),!Ut){E(!0),U(!1);return}await ct(Ut)}catch(Tt){ut||(W(Ku(Tt)),E(s==="user-api-key"),U(!1))}}return Mt(),()=>{ut=!0}},[ct,s]);const Et=bt.useCallback(ut=>s==="proxy"?Sm(ut):d?bm(d):Promise.reject(new Error("XPERTAI_API_KEY is not configured.")),[s,d]);return!u&&!p?R?K.jsx(Tm,{message:R}):K.jsx(Em,{}):s==="user-api-key"&&(p||!r)?K.jsx(Yv,{error:R,initialConfig:uy(),isConnecting:b,onSave:ct}):R&&!r?K.jsx(Tm,{message:R}):r?K.jsx(qv,{createSession:Et,initialSession:r,onConfigure:s==="user-api-key"?()=>E(!0):void 0}):K.jsx(Em,{})}const cy=document.getElementById("root");if(!cy)throw new Error("Missing #root element.");function Gv(){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)})}Gv().then(()=>{Zp.createRoot(cy).render(K.jsx(bt.StrictMode,{children:K.jsx(Xv,{})}))});
|